managarten/nutriphi/apps/mobile/components/ui/LoadingSpinner.tsx
Till-JS 6537863696 feat(nutriphi): migrate from Supabase to PostgreSQL + Hetzner S3
- Add nutriphi-database package with Drizzle ORM
  - meals and nutrition_goals schemas
  - PostgreSQL 16 Docker setup
  - Drizzle Kit configuration

- Migrate backend from Supabase to Drizzle
  - Add DatabaseModule with connection pooling
  - Add StorageService for Hetzner Object Storage (S3-compatible)
  - Update MealsService with Drizzle queries
  - Add /api/meals/upload endpoint for image upload + analysis

- Update web app to use backend for uploads
  - Remove Supabase Storage direct upload
  - Update uploadService to send images to backend
  - Remove Supabase dependencies from package.json
  - Simplify hooks.server.ts

- Add Coolify deployment configuration
  - Dockerfile for production build
  - docker-compose.coolify.yml

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-25 17:52:14 +01:00

32 lines
813 B
TypeScript

import React from 'react';
import { ActivityIndicator, View, Text } from 'react-native';
interface LoadingSpinnerProps {
size?: 'small' | 'large';
color?: string;
text?: string;
overlay?: boolean;
}
export const LoadingSpinner: React.FC<LoadingSpinnerProps> = ({
size = 'large',
color = '#6366f1',
text,
overlay = false,
}) => {
const Container = overlay ? View : React.Fragment;
const containerProps = overlay
? {
className: 'absolute inset-0 bg-black/20 flex-1 justify-center items-center z-50',
}
: {};
return (
<Container {...containerProps}>
<View className="items-center space-y-2">
<ActivityIndicator size={size} color={color} />
{text && <Text className="text-sm text-gray-600">{text}</Text>}
</View>
</Container>
);
};