ruvector/studio/components/interfaces/ProjectCreation/InitialStep.tsx
rUv 814f595995 feat(studio): Add complete RuVector Studio application
Major additions:
- Complete Next.js studio application with 1600+ components
- Docker support (Dockerfile.combined, docker-compose.yml)
- GCP deployment documentation and benchmarks
- SQL benchmark scripts for performance testing
- Sentry integration for monitoring
- Comprehensive test suite and mocks

Studio features:
- Dashboard and admin interfaces
- Data visualization components
- Authentication and user management
- API integration with RuVector backend
- Static data and public assets

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

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-06 23:04:48 +00:00

82 lines
2.6 KiB
TypeScript

import { Database, Import } from 'lucide-react'
import { cn } from 'ui'
import { SchemaGenerator } from './SchemaGenerator'
interface SupabaseService {
name: 'Auth' | 'Storage' | 'Database' | 'Edge Function' | 'Cron' | 'Queues' | 'Vector'
reason: string
}
export const InitialStep = ({
onSubmit,
onStartBlank,
onMigrate,
onSqlGenerated,
onServicesUpdated,
onTitleUpdated,
}: {
onSubmit: (value: string) => void
onStartBlank: () => void
onMigrate: () => void
onSqlGenerated: (sql: string) => void
onServicesUpdated: (services: SupabaseService[]) => void
onTitleUpdated: (title: string) => void
}) => {
return (
<div className="w-full">
<h3>What are you building?</h3>
<p className="text-sm text-foreground-lighter mb-4">
We can generate a schema for you to kick start your project.
</p>
<SchemaGenerator
isOneOff
step="initial"
onSqlGenerated={(sql) => {
onSqlGenerated(sql)
onSubmit(sql)
}}
onServicesUpdated={onServicesUpdated}
onTitleUpdated={onTitleUpdated}
/>
<div
className={cn(
'relative text-center text-sm text-foreground-lighter my-4 before:absolute before:inset-y-1/2 before:left-0 before:w-[calc(50%-24px)]',
'before:h-px before:bg-border after:absolute after:inset-y-1/2 after:right-0 after:w-[calc(50%-24px)] after:h-px after:bg-border'
)}
>
or
</div>
<div className="grid grid-cols-2 gap-4">
<div
className="p-4 h-auto block border rounded-md cursor text-sm border-strong hover:border-foreground-muted cursor-pointer flex items-center gap-4"
role="button"
onClick={onStartBlank}
>
<Database strokeWidth={1.5} size={16} className="text-foreground-lighter shrink-0" />
<div>
<span className="block">Start blank</span>
<span className="text-foreground-lighter">Configure a database and dive right in</span>
</div>
</div>
<div
className="p-4 h-auto block border rounded-md cursor text-sm border-strong hover:border-foreground-muted cursor-pointer flex items-center gap-4"
role="button"
onClick={onMigrate}
>
<Import
strokeWidth={1.5}
size={16}
className="text-foreground-lighter mx-auto shrink-0"
/>
<div>
<span className="mb-1 block">Migrate</span>
<span className="text-foreground-lighter">
Import your database from another provider
</span>
</div>
</div>
</div>
</div>
)
}