first draft

This commit is contained in:
Bruno Fargnoli 2026-04-10 15:35:32 +02:00
commit 0d7ff1d7b0
28 changed files with 6193 additions and 0 deletions

24
.gitignore vendored Normal file
View file

@ -0,0 +1,24 @@
# Logs
logs
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*
pnpm-debug.log*
lerna-debug.log*
node_modules
dist
dist-ssr
*.local
# Editor directories and files
.vscode/*
!.vscode/extensions.json
.idea
.DS_Store
*.suo
*.ntvs*
*.njsproj
*.sln
*.sw?

16
README.md Normal file
View file

@ -0,0 +1,16 @@
# React + Vite
This template provides a minimal setup to get React working in Vite with HMR and some ESLint rules.
Currently, two official plugins are available:
- [@vitejs/plugin-react](https://github.com/vitejs/vite-plugin-react/blob/main/packages/plugin-react) uses [Oxc](https://oxc.rs)
- [@vitejs/plugin-react-swc](https://github.com/vitejs/vite-plugin-react/blob/main/packages/plugin-react-swc) uses [SWC](https://swc.rs/)
## React Compiler
The React Compiler is not enabled on this template because of its impact on dev & build performances. To add it, see [this documentation](https://react.dev/learn/react-compiler/installation).
## Expanding the ESLint configuration
If you are developing a production application, we recommend using TypeScript with type-aware lint rules enabled. Check out the [TS template](https://github.com/vitejs/vite/tree/main/packages/create-vite/template-react-ts) for information on how to integrate TypeScript and [`typescript-eslint`](https://typescript-eslint.io) in your project.

29
eslint.config.js Normal file
View file

@ -0,0 +1,29 @@
import js from '@eslint/js'
import globals from 'globals'
import reactHooks from 'eslint-plugin-react-hooks'
import reactRefresh from 'eslint-plugin-react-refresh'
import { defineConfig, globalIgnores } from 'eslint/config'
export default defineConfig([
globalIgnores(['dist']),
{
files: ['**/*.{js,jsx}'],
extends: [
js.configs.recommended,
reactHooks.configs.flat.recommended,
reactRefresh.configs.vite,
],
languageOptions: {
ecmaVersion: 2020,
globals: globals.browser,
parserOptions: {
ecmaVersion: 'latest',
ecmaFeatures: { jsx: true },
sourceType: 'module',
},
},
rules: {
'no-unused-vars': ['error', { varsIgnorePattern: '^[A-Z_]' }],
},
},
])

18
index.html Normal file
View file

@ -0,0 +1,18 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<link rel="icon" type="image/svg+xml" href="/vite.svg" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<meta name="description" content="3D Gen Studio — Generate 3D meshes from images using a powerful kanban workspace. AI-driven mesh generation, editing, and texturing pipeline." />
<title>3D Gen Studio</title>
<link rel="preconnect" href="https://fonts.googleapis.com" />
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
<link href="https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@300;400;500;600;700&family=Inter:wght@300;400;500;600;700&family=Manrope:wght@300;400;500;600;700&display=swap" rel="stylesheet" />
<link href="https://fonts.googleapis.com/css2?family=Material+Symbols+Outlined:opsz,wght,FILL,GRAD@20..48,100..700,0..1,-50..200&display=swap" rel="stylesheet" />
</head>
<body>
<div id="root"></div>
<script type="module" src="/src/main.jsx"></script>
</body>
</html>

2691
package-lock.json generated Normal file

File diff suppressed because it is too large Load diff

28
package.json Normal file
View file

@ -0,0 +1,28 @@
{
"name": "app",
"private": true,
"version": "0.0.0",
"type": "module",
"scripts": {
"dev": "vite",
"build": "vite build",
"lint": "eslint .",
"preview": "vite preview"
},
"dependencies": {
"react": "^19.2.4",
"react-dom": "^19.2.4",
"react-router-dom": "^7.14.0"
},
"devDependencies": {
"@eslint/js": "^9.39.4",
"@types/react": "^19.2.14",
"@types/react-dom": "^19.2.3",
"@vitejs/plugin-react": "^6.0.1",
"eslint": "^9.39.4",
"eslint-plugin-react-hooks": "^7.0.1",
"eslint-plugin-react-refresh": "^0.5.2",
"globals": "^17.4.0",
"vite": "^8.0.4"
}
}

1
public/favicon.svg Normal file

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 9.3 KiB

24
public/icons.svg Normal file
View file

@ -0,0 +1,24 @@
<svg xmlns="http://www.w3.org/2000/svg">
<symbol id="bluesky-icon" viewBox="0 0 16 17">
<g clip-path="url(#bluesky-clip)"><path fill="#08060d" d="M7.75 7.735c-.693-1.348-2.58-3.86-4.334-5.097-1.68-1.187-2.32-.981-2.74-.79C.188 2.065.1 2.812.1 3.251s.241 3.602.398 4.13c.52 1.744 2.367 2.333 4.07 2.145-2.495.37-4.71 1.278-1.805 4.512 3.196 3.309 4.38-.71 4.987-2.746.608 2.036 1.307 5.91 4.93 2.746 2.72-2.746.747-4.143-1.747-4.512 1.702.189 3.55-.4 4.07-2.145.156-.528.397-3.691.397-4.13s-.088-1.186-.575-1.406c-.42-.19-1.06-.395-2.741.79-1.755 1.24-3.64 3.752-4.334 5.099"/></g>
<defs><clipPath id="bluesky-clip"><path fill="#fff" d="M.1.85h15.3v15.3H.1z"/></clipPath></defs>
</symbol>
<symbol id="discord-icon" viewBox="0 0 20 19">
<path fill="#08060d" d="M16.224 3.768a14.5 14.5 0 0 0-3.67-1.153c-.158.286-.343.67-.47.976a13.5 13.5 0 0 0-4.067 0c-.128-.306-.317-.69-.476-.976A14.4 14.4 0 0 0 3.868 3.77C1.546 7.28.916 10.703 1.231 14.077a14.7 14.7 0 0 0 4.5 2.306q.545-.748.965-1.587a9.5 9.5 0 0 1-1.518-.74q.191-.14.372-.293c2.927 1.369 6.107 1.369 8.999 0q.183.152.372.294-.723.437-1.52.74.418.838.963 1.588a14.6 14.6 0 0 0 4.504-2.308c.37-3.911-.63-7.302-2.644-10.309m-9.13 8.234c-.878 0-1.599-.82-1.599-1.82 0-.998.705-1.82 1.6-1.82.894 0 1.614.82 1.599 1.82.001 1-.705 1.82-1.6 1.82m5.91 0c-.878 0-1.599-.82-1.599-1.82 0-.998.705-1.82 1.6-1.82.893 0 1.614.82 1.599 1.82 0 1-.706 1.82-1.6 1.82"/>
</symbol>
<symbol id="documentation-icon" viewBox="0 0 21 20">
<path fill="none" stroke="#aa3bff" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.35" d="m15.5 13.333 1.533 1.322c.645.555.967.833.967 1.178s-.322.623-.967 1.179L15.5 18.333m-3.333-5-1.534 1.322c-.644.555-.966.833-.966 1.178s.322.623.966 1.179l1.534 1.321"/>
<path fill="none" stroke="#aa3bff" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.35" d="M17.167 10.836v-4.32c0-1.41 0-2.117-.224-2.68-.359-.906-1.118-1.621-2.08-1.96-.599-.21-1.349-.21-2.848-.21-2.623 0-3.935 0-4.983.369-1.684.591-3.013 1.842-3.641 3.428C3 6.449 3 7.684 3 10.154v2.122c0 2.558 0 3.838.706 4.726q.306.383.713.671c.76.536 1.79.64 3.581.66"/>
<path fill="none" stroke="#aa3bff" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.35" d="M3 10a2.78 2.78 0 0 1 2.778-2.778c.555 0 1.209.097 1.748-.047.48-.129.854-.503.982-.982.145-.54.048-1.194.048-1.749a2.78 2.78 0 0 1 2.777-2.777"/>
</symbol>
<symbol id="github-icon" viewBox="0 0 19 19">
<path fill="#08060d" fill-rule="evenodd" d="M9.356 1.85C5.05 1.85 1.57 5.356 1.57 9.694a7.84 7.84 0 0 0 5.324 7.44c.387.079.528-.168.528-.376 0-.182-.013-.805-.013-1.454-2.165.467-2.616-.935-2.616-.935-.349-.91-.864-1.143-.864-1.143-.71-.48.051-.48.051-.48.787.051 1.2.805 1.2.805.695 1.194 1.817.857 2.268.649.064-.507.27-.857.49-1.052-1.728-.182-3.545-.857-3.545-3.87 0-.857.31-1.558.8-2.104-.078-.195-.349-1 .077-2.078 0 0 .657-.208 2.14.805a7.5 7.5 0 0 1 1.946-.26c.657 0 1.328.092 1.946.26 1.483-1.013 2.14-.805 2.14-.805.426 1.078.155 1.883.078 2.078.502.546.799 1.247.799 2.104 0 3.013-1.818 3.675-3.558 3.87.284.247.528.714.528 1.454 0 1.052-.012 1.896-.012 2.156 0 .208.142.455.528.377a7.84 7.84 0 0 0 5.324-7.441c.013-4.338-3.48-7.844-7.773-7.844" clip-rule="evenodd"/>
</symbol>
<symbol id="social-icon" viewBox="0 0 20 20">
<path fill="none" stroke="#aa3bff" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.35" d="M12.5 6.667a4.167 4.167 0 1 0-8.334 0 4.167 4.167 0 0 0 8.334 0"/>
<path fill="none" stroke="#aa3bff" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.35" d="M2.5 16.667a5.833 5.833 0 0 1 8.75-5.053m3.837.474.513 1.035c.07.144.257.282.414.309l.93.155c.596.1.736.536.307.965l-.723.73a.64.64 0 0 0-.152.531l.207.903c.164.715-.213.991-.84.618l-.872-.52a.63.63 0 0 0-.577 0l-.872.52c-.624.373-1.003.094-.84-.618l.207-.903a.64.64 0 0 0-.152-.532l-.723-.729c-.426-.43-.289-.864.306-.964l.93-.156a.64.64 0 0 0 .412-.31l.513-1.034c.28-.562.735-.562 1.012 0"/>
</symbol>
<symbol id="x-icon" viewBox="0 0 19 19">
<path fill="#08060d" fill-rule="evenodd" d="M1.893 1.98c.052.072 1.245 1.769 2.653 3.77l2.892 4.114c.183.261.333.48.333.486s-.068.089-.152.183l-.522.593-.765.867-3.597 4.087c-.375.426-.734.834-.798.905a1 1 0 0 0-.118.148c0 .01.236.017.664.017h.663l.729-.83c.4-.457.796-.906.879-.999a692 692 0 0 0 1.794-2.038c.034-.037.301-.34.594-.675l.551-.624.345-.392a7 7 0 0 1 .34-.374c.006 0 .93 1.306 2.052 2.903l2.084 2.965.045.063h2.275c1.87 0 2.273-.003 2.266-.021-.008-.02-1.098-1.572-3.894-5.547-2.013-2.862-2.28-3.246-2.273-3.266.008-.019.282-.332 2.085-2.38l2-2.274 1.567-1.782c.022-.028-.016-.03-.65-.03h-.674l-.3.342a871 871 0 0 1-1.782 2.025c-.067.075-.405.458-.75.852a100 100 0 0 1-.803.91c-.148.172-.299.344-.99 1.127-.304.343-.32.358-.345.327-.015-.019-.904-1.282-1.976-2.808L6.365 1.85H1.8zm1.782.91 8.078 11.294c.772 1.08 1.413 1.973 1.425 1.984.016.017.241.02 1.05.017l1.03-.004-2.694-3.766L7.796 5.75 5.722 2.852l-1.039-.004-1.039-.004z" clip-rule="evenodd"/>
</symbol>
</svg>

After

Width:  |  Height:  |  Size: 4.9 KiB

55
src/App.jsx Normal file
View file

@ -0,0 +1,55 @@
import { Routes, Route, Navigate } from 'react-router-dom'
import { AuthProvider, useAuth } from './context/AuthContext'
import { ProjectProvider } from './context/ProjectContext'
import ProtectedRoute from './components/ProtectedRoute'
import LoginPage from './pages/LoginPage'
import ProjectsPage from './pages/ProjectsPage'
import KanbanPage from './pages/KanbanPage'
function AppRoutes() {
const { isAuthenticated } = useAuth()
return (
<Routes>
<Route
path="/"
element={isAuthenticated ? <Navigate to="/projects" replace /> : <LoginPage />}
/>
<Route
path="/projects"
element={
<ProtectedRoute>
<ProjectsPage />
</ProtectedRoute>
}
/>
<Route
path="/projects/new"
element={
<ProtectedRoute>
<ProjectsPage />
</ProtectedRoute>
}
/>
<Route
path="/projects/:projectId"
element={
<ProtectedRoute>
<KanbanPage />
</ProtectedRoute>
}
/>
<Route path="*" element={<Navigate to="/" replace />} />
</Routes>
)
}
export default function App() {
return (
<AuthProvider>
<ProjectProvider>
<AppRoutes />
</ProjectProvider>
</AuthProvider>
)
}

BIN
src/assets/hero.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 44 KiB

1
src/assets/react.svg Normal file
View file

@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" class="iconify iconify--logos" width="35.93" height="32" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 228"><path fill="#00D8FF" d="M210.483 73.824a171.49 171.49 0 0 0-8.24-2.597c.465-1.9.893-3.777 1.273-5.621c6.238-30.281 2.16-54.676-11.769-62.708c-13.355-7.7-35.196.329-57.254 19.526a171.23 171.23 0 0 0-6.375 5.848a155.866 155.866 0 0 0-4.241-3.917C100.759 3.829 77.587-4.822 63.673 3.233C50.33 10.957 46.379 33.89 51.995 62.588a170.974 170.974 0 0 0 1.892 8.48c-3.28.932-6.445 1.924-9.474 2.98C17.309 83.498 0 98.307 0 113.668c0 15.865 18.582 31.778 46.812 41.427a145.52 145.52 0 0 0 6.921 2.165a167.467 167.467 0 0 0-2.01 9.138c-5.354 28.2-1.173 50.591 12.134 58.266c13.744 7.926 36.812-.22 59.273-19.855a145.567 145.567 0 0 0 5.342-4.923a168.064 168.064 0 0 0 6.92 6.314c21.758 18.722 43.246 26.282 56.54 18.586c13.731-7.949 18.194-32.003 12.4-61.268a145.016 145.016 0 0 0-1.535-6.842c1.62-.48 3.21-.974 4.76-1.488c29.348-9.723 48.443-25.443 48.443-41.52c0-15.417-17.868-30.326-45.517-39.844Zm-6.365 70.984c-1.4.463-2.836.91-4.3 1.345c-3.24-10.257-7.612-21.163-12.963-32.432c5.106-11 9.31-21.767 12.459-31.957c2.619.758 5.16 1.557 7.61 2.4c23.69 8.156 38.14 20.213 38.14 29.504c0 9.896-15.606 22.743-40.946 31.14Zm-10.514 20.834c2.562 12.94 2.927 24.64 1.23 33.787c-1.524 8.219-4.59 13.698-8.382 15.893c-8.067 4.67-25.32-1.4-43.927-17.412a156.726 156.726 0 0 1-6.437-5.87c7.214-7.889 14.423-17.06 21.459-27.246c12.376-1.098 24.068-2.894 34.671-5.345a134.17 134.17 0 0 1 1.386 6.193ZM87.276 214.515c-7.882 2.783-14.16 2.863-17.955.675c-8.075-4.657-11.432-22.636-6.853-46.752a156.923 156.923 0 0 1 1.869-8.499c10.486 2.32 22.093 3.988 34.498 4.994c7.084 9.967 14.501 19.128 21.976 27.15a134.668 134.668 0 0 1-4.877 4.492c-9.933 8.682-19.886 14.842-28.658 17.94ZM50.35 144.747c-12.483-4.267-22.792-9.812-29.858-15.863c-6.35-5.437-9.555-10.836-9.555-15.216c0-9.322 13.897-21.212 37.076-29.293c2.813-.98 5.757-1.905 8.812-2.773c3.204 10.42 7.406 21.315 12.477 32.332c-5.137 11.18-9.399 22.249-12.634 32.792a134.718 134.718 0 0 1-6.318-1.979Zm12.378-84.26c-4.811-24.587-1.616-43.134 6.425-47.789c8.564-4.958 27.502 2.111 47.463 19.835a144.318 144.318 0 0 1 3.841 3.545c-7.438 7.987-14.787 17.08-21.808 26.988c-12.04 1.116-23.565 2.908-34.161 5.309a160.342 160.342 0 0 1-1.76-7.887Zm110.427 27.268a347.8 347.8 0 0 0-7.785-12.803c8.168 1.033 15.994 2.404 23.343 4.08c-2.206 7.072-4.956 14.465-8.193 22.045a381.151 381.151 0 0 0-7.365-13.322Zm-45.032-43.861c5.044 5.465 10.096 11.566 15.065 18.186a322.04 322.04 0 0 0-30.257-.006c4.974-6.559 10.069-12.652 15.192-18.18ZM82.802 87.83a323.167 323.167 0 0 0-7.227 13.238c-3.184-7.553-5.909-14.98-8.134-22.152c7.304-1.634 15.093-2.97 23.209-3.984a321.524 321.524 0 0 0-7.848 12.897Zm8.081 65.352c-8.385-.936-16.291-2.203-23.593-3.793c2.26-7.3 5.045-14.885 8.298-22.6a321.187 321.187 0 0 0 7.257 13.246c2.594 4.48 5.28 8.868 8.038 13.147Zm37.542 31.03c-5.184-5.592-10.354-11.779-15.403-18.433c4.902.192 9.899.29 14.978.29c5.218 0 10.376-.117 15.453-.343c-4.985 6.774-10.018 12.97-15.028 18.486Zm52.198-57.817c3.422 7.8 6.306 15.345 8.596 22.52c-7.422 1.694-15.436 3.058-23.88 4.071a382.417 382.417 0 0 0 7.859-13.026a347.403 347.403 0 0 0 7.425-13.565Zm-16.898 8.101a358.557 358.557 0 0 1-12.281 19.815a329.4 329.4 0 0 1-23.444.823c-7.967 0-15.716-.248-23.178-.732a310.202 310.202 0 0 1-12.513-19.846h.001a307.41 307.41 0 0 1-10.923-20.627a310.278 310.278 0 0 1 10.89-20.637l-.001.001a307.318 307.318 0 0 1 12.413-19.761c7.613-.576 15.42-.876 23.31-.876H128c7.926 0 15.743.303 23.354.883a329.357 329.357 0 0 1 12.335 19.695a358.489 358.489 0 0 1 11.036 20.54a329.472 329.472 0 0 1-11 20.722Zm22.56-122.124c8.572 4.944 11.906 24.881 6.52 51.026c-.344 1.668-.73 3.367-1.15 5.09c-10.622-2.452-22.155-4.275-34.23-5.408c-7.034-10.017-14.323-19.124-21.64-27.008a160.789 160.789 0 0 1 5.888-5.4c18.9-16.447 36.564-22.941 44.612-18.3ZM128 90.808c12.625 0 22.86 10.235 22.86 22.86s-10.235 22.86-22.86 22.86s-22.86-10.235-22.86-22.86s10.235-22.86 22.86-22.86Z"></path></svg>

After

Width:  |  Height:  |  Size: 4 KiB

1
src/assets/vite.svg Normal file

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 8.5 KiB

98
src/components/Footer.css Normal file
View file

@ -0,0 +1,98 @@
.footer {
flex-shrink: 0;
display: flex;
align-items: center;
justify-content: space-between;
padding: 0 1.5rem;
height: 40px;
border-top: 1px solid rgba(71, 72, 74, 0.1);
font-family: var(--font-label);
font-size: 10px;
text-transform: uppercase;
letter-spacing: 0.1em;
color: var(--outline);
background: var(--surface-container-low);
}
.footer--kanban {
background: var(--surface-container-low);
border-top: 1px solid rgba(71, 72, 74, 0.15);
}
.footer__left {
display: flex;
align-items: center;
gap: 1.5rem;
}
.footer__right {
display: flex;
align-items: center;
gap: 1.5rem;
}
.footer__text {
color: var(--outline);
}
.footer__text--success {
color: var(--tertiary);
}
.footer__link {
color: var(--outline);
transition: color var(--transition-base);
}
.footer__link:hover {
color: var(--primary);
}
.footer__status {
display: flex;
align-items: center;
gap: 0.5rem;
}
.footer__status-dot {
width: 6px;
height: 6px;
border-radius: 50%;
}
.footer__status-dot--online {
background: var(--tertiary);
animation: pulse-glow 2s ease-in-out infinite;
}
.footer__status-text {
color: var(--on-surface-variant);
}
.footer__metrics {
display: flex;
align-items: center;
gap: 1rem;
font-family: monospace;
font-size: 10px;
color: rgba(171, 171, 173, 0.6);
}
.footer__action-btn {
display: flex;
align-items: center;
gap: 0.375rem;
background: none;
border: none;
color: var(--on-surface-variant);
font-family: var(--font-label);
font-size: 10px;
text-transform: uppercase;
letter-spacing: 0.05em;
cursor: pointer;
transition: color var(--transition-base);
}
.footer__action-btn:hover {
color: var(--primary);
}

46
src/components/Footer.jsx Normal file
View file

@ -0,0 +1,46 @@
import './Footer.css'
export default function Footer({ variant = 'default' }) {
if (variant === 'kanban') {
return (
<footer className="footer footer--kanban" id="status-bar">
<div className="footer__left">
<div className="footer__status">
<div className="footer__status-dot footer__status-dot--online" />
<span className="footer__status-text">System Online</span>
</div>
<div className="footer__metrics">
<span>GPU: RTX 4090 (82%)</span>
<span>MEM: 14.2 GB / 24 GB</span>
<span>LATENCY: 42ms</span>
</div>
</div>
<div className="footer__right">
<button className="footer__action-btn" id="action-log-btn">
<span className="material-symbols-outlined" style={{ fontSize: '14px' }}>history</span>
ACTION LOG
</button>
<button className="footer__action-btn" id="export-queue-btn">
<span className="material-symbols-outlined" style={{ fontSize: '14px' }}>layers</span>
EXPORT QUEUE (2)
</button>
</div>
</footer>
)
}
return (
<footer className="footer" id="main-footer">
<div className="footer__left">
<span className="footer__text">
Server Status: <span className="footer__text--success">Optimal</span>
</span>
<span className="footer__text">Latency: 14ms</span>
</div>
<div className="footer__right">
<a href="#" className="footer__link">Documentation</a>
<a href="#" className="footer__link">Terms of Service</a>
</div>
</footer>
)
}

165
src/components/Header.css Normal file
View file

@ -0,0 +1,165 @@
.header {
position: sticky;
top: 0;
z-index: 50;
display: flex;
align-items: center;
justify-content: space-between;
padding: 0 1.5rem;
height: 52px;
background: var(--surface-container-low);
box-shadow: 0 0 20px rgba(143, 245, 255, 0.05);
flex-shrink: 0;
}
.header__left {
display: flex;
align-items: center;
gap: 2rem;
}
.header__logo {
font-family: var(--font-headline);
font-size: 1.25rem;
font-weight: 700;
color: var(--primary);
letter-spacing: -0.02em;
white-space: nowrap;
}
.header__nav {
display: flex;
align-items: center;
gap: 1.5rem;
}
.header__nav-link {
font-family: var(--font-headline);
font-size: 0.875rem;
color: var(--on-surface-variant);
letter-spacing: -0.01em;
transition: color var(--transition-base);
white-space: nowrap;
}
.header__nav-link:hover {
color: var(--on-surface);
}
.header__nav-link--active {
color: var(--primary);
border-bottom: 2px solid var(--primary);
padding-bottom: 2px;
}
.header__right {
display: flex;
align-items: center;
gap: 1rem;
}
.header__search-btn {
display: flex;
align-items: center;
gap: 0.5rem;
padding: 0.375rem 1rem;
background: var(--surface-container-highest);
border: 1px solid rgba(71, 72, 74, 0.15);
border-radius: var(--radius-lg);
color: var(--on-surface-variant);
cursor: pointer;
transition: color var(--transition-base);
font-family: var(--font-label);
}
.header__search-btn:hover {
color: var(--on-surface);
}
.header__search-text {
font-size: 0.75rem;
text-transform: uppercase;
letter-spacing: 0.08em;
}
.header__actions {
display: flex;
align-items: center;
gap: 0.25rem;
}
.header__icon-btn {
display: flex;
align-items: center;
justify-content: center;
width: 36px;
height: 36px;
border: none;
background: transparent;
color: var(--on-surface-variant);
border-radius: var(--radius-lg);
cursor: pointer;
transition: all var(--transition-base);
}
.header__icon-btn:hover {
background: var(--surface-container-high);
color: var(--primary);
}
.header__icon-btn:active {
transform: scale(0.95);
}
.header__avatar {
width: 32px;
height: 32px;
border-radius: 50%;
overflow: hidden;
border: 1px solid rgba(143, 245, 255, 0.2);
cursor: pointer;
background: var(--secondary-container);
display: flex;
align-items: center;
justify-content: center;
transition: border-color var(--transition-base);
flex-shrink: 0;
}
.header__avatar:hover {
border-color: var(--primary);
}
.header__avatar-letter {
font-family: var(--font-headline);
font-weight: 700;
font-size: 0.8rem;
color: var(--on-surface);
}
.header__create-btn {
padding: 0.375rem 1rem;
background: var(--primary);
color: var(--on-primary);
font-family: var(--font-headline);
font-weight: 600;
font-size: 0.875rem;
border-radius: var(--radius-md);
border: none;
cursor: pointer;
transition: all var(--transition-fast);
white-space: nowrap;
}
.header__create-btn:hover {
filter: brightness(1.1);
}
.header__create-btn:active {
transform: scale(0.95);
}
@media (max-width: 768px) {
.header__nav { display: none; }
.header__search-btn { display: none; }
}

66
src/components/Header.jsx Normal file
View file

@ -0,0 +1,66 @@
import { Link, useLocation, useNavigate } from 'react-router-dom'
import { useAuth } from '../context/AuthContext'
import './Header.css'
export default function Header({ showSearch = false, showCreateNew = false }) {
const { user, logout } = useAuth()
const location = useLocation()
const navigate = useNavigate()
const isActive = (path) => location.pathname.startsWith(path)
const handleLogout = () => {
logout()
navigate('/')
}
return (
<header className="header" id="main-header">
<div className="header__left">
<Link to="/projects" className="header__logo">
3D Gen Studio
</Link>
<nav className="header__nav">
<Link
to="/projects"
className={`header__nav-link ${isActive('/projects') ? 'header__nav-link--active' : ''}`}
>
Projects
</Link>
<a href="#" className="header__nav-link">Assets</a>
<a href="#" className="header__nav-link">Library</a>
</nav>
</div>
<div className="header__right">
{showSearch && (
<button className="header__search-btn" id="search-assets-btn">
<span className="material-symbols-outlined" style={{ fontSize: '16px' }}>search</span>
<span className="header__search-text">Search Assets</span>
</button>
)}
<div className="header__actions">
<button className="header__icon-btn" id="notifications-btn" title="Notifications">
<span className="material-symbols-outlined">notifications</span>
</button>
<button className="header__icon-btn" id="settings-btn" title="Settings">
<span className="material-symbols-outlined">settings</span>
</button>
</div>
<button className="header__avatar" onClick={handleLogout} title="Logout">
<span className="header__avatar-letter">
{user?.name?.charAt(0)?.toUpperCase() || 'U'}
</span>
</button>
{showCreateNew && (
<Link to="/projects/new" className="header__create-btn" id="create-new-btn">
Create New
</Link>
)}
</div>
</header>
)
}

View file

@ -0,0 +1,12 @@
import { Navigate } from 'react-router-dom'
import { useAuth } from '../context/AuthContext'
export default function ProtectedRoute({ children }) {
const { isAuthenticated } = useAuth()
if (!isAuthenticated) {
return <Navigate to="/" replace />
}
return children
}

View file

@ -0,0 +1,40 @@
import { createContext, useContext, useState, useCallback } from 'react'
const AuthContext = createContext(null)
export function AuthProvider({ children }) {
const [user, setUser] = useState(() => {
const saved = localStorage.getItem('3dgs_user')
return saved ? JSON.parse(saved) : null
})
const login = useCallback((email, password) => {
// Mock authentication — replace with real API later
const mockUser = {
id: '1',
email,
name: email.split('@')[0],
avatar: null,
}
setUser(mockUser)
localStorage.setItem('3dgs_user', JSON.stringify(mockUser))
return true
}, [])
const logout = useCallback(() => {
setUser(null)
localStorage.removeItem('3dgs_user')
}, [])
return (
<AuthContext.Provider value={{ user, login, logout, isAuthenticated: !!user }}>
{children}
</AuthContext.Provider>
)
}
export function useAuth() {
const ctx = useContext(AuthContext)
if (!ctx) throw new Error('useAuth must be used within AuthProvider')
return ctx
}

View file

@ -0,0 +1,81 @@
import { createContext, useContext, useState, useCallback } from 'react'
const ProjectContext = createContext(null)
const SAMPLE_PROJECTS = [
{
id: 'proj_001',
name: 'Cyberpunk_District_V1',
description: 'High-fidelity urban environment with neon-lit architecture and volumetric fog.',
preset: 'Photorealistic ArchViz',
createdAt: '2026-04-01T10:30:00Z',
imageCount: 4,
meshCount: 2,
status: 'active',
},
{
id: 'proj_002',
name: 'Organic_Creature_Alpha',
description: 'Stylized creature design for real-time game engine integration.',
preset: 'Stylized Game Asset',
createdAt: '2026-03-28T14:15:00Z',
imageCount: 8,
meshCount: 5,
status: 'complete',
},
{
id: 'proj_003',
name: 'Mech_Prototype_03',
description: 'Hard-surface mechanical design — rapid concept iteration.',
preset: 'Rapid Concept Sculpt',
createdAt: '2026-04-05T09:00:00Z',
imageCount: 2,
meshCount: 0,
status: 'processing',
},
]
export function ProjectProvider({ children }) {
const [projects, setProjects] = useState(() => {
const saved = localStorage.getItem('3dgs_projects')
return saved ? JSON.parse(saved) : SAMPLE_PROJECTS
})
const persist = useCallback((updated) => {
setProjects(updated)
localStorage.setItem('3dgs_projects', JSON.stringify(updated))
}, [])
const createProject = useCallback((project) => {
const newProject = {
...project,
id: 'proj_' + Date.now(),
createdAt: new Date().toISOString(),
imageCount: 0,
meshCount: 0,
status: 'active',
}
persist([newProject, ...projects])
return newProject
}, [projects, persist])
const getProject = useCallback((id) => {
return projects.find(p => p.id === id) || null
}, [projects])
const deleteProject = useCallback((id) => {
persist(projects.filter(p => p.id !== id))
}, [projects, persist])
return (
<ProjectContext.Provider value={{ projects, createProject, getProject, deleteProject }}>
{children}
</ProjectContext.Provider>
)
}
export function useProjects() {
const ctx = useContext(ProjectContext)
if (!ctx) throw new Error('useProjects must be used within ProjectProvider')
return ctx
}

259
src/index.css Normal file
View file

@ -0,0 +1,259 @@
/* ═══════════════════════════════════════════════════════════
3D Gen Studio — Design System
"The Synthetic Architect" — Cinematic Precision Tool
═══════════════════════════════════════════════════════════ */
/* ── Reset ── */
*, *::before, *::after {
margin: 0;
padding: 0;
box-sizing: border-box;
}
/* ── Design Tokens ── */
:root {
/* Surface Hierarchy */
--background: #0d0e10;
--surface: #0d0e10;
--surface-dim: #0d0e10;
--surface-bright: #2b2c2f;
--surface-container-lowest: #000000;
--surface-container-low: #121316;
--surface-container: #181a1c;
--surface-container-high: #1e2022;
--surface-container-highest: #242629;
--surface-variant: #242629;
--surface-tint: #8ff5ff;
/* Primary — Cyan */
--primary: #8ff5ff;
--primary-dim: #00deec;
--primary-container: #00eefc;
--primary-fixed: #00eefc;
--primary-fixed-dim: #00deec;
--on-primary: #005d63;
--on-primary-container: #005359;
--on-primary-fixed: #003f43;
--on-primary-fixed-variant: #005e64;
--inverse-primary: #006a71;
/* Secondary — Purple */
--secondary: #ac89ff;
--secondary-dim: #874cff;
--secondary-container: #7000ff;
--secondary-fixed: #dac9ff;
--secondary-fixed-dim: #ceb9ff;
--on-secondary: #290067;
--on-secondary-container: #f8f1ff;
--on-secondary-fixed: #41009a;
--on-secondary-fixed-variant: #6300e2;
/* Tertiary — Lime */
--tertiary: #dcffb2;
--tertiary-dim: #93ef00;
--tertiary-container: #9dff00;
--tertiary-fixed: #9dff00;
--tertiary-fixed-dim: #93ef00;
--on-tertiary: #3c6700;
--on-tertiary-container: #375d00;
--on-tertiary-fixed: #2a4900;
--on-tertiary-fixed-variant: #3e6800;
/* Error */
--error: #ff716c;
--error-dim: #d7383b;
--error-container: #9f0519;
--on-error: #490006;
--on-error-container: #ffa8a3;
/* Neutral / Text */
--on-surface: #fdfbfe;
--on-surface-variant: #ababad;
--on-background: #fdfbfe;
--outline: #757578;
--outline-variant: #47484a;
--inverse-surface: #faf9fb;
--inverse-on-surface: #555557;
/* Shape Scale */
--radius-xs: 0.125rem;
--radius-sm: 0.25rem;
--radius-md: 0.375rem;
--radius-lg: 0.5rem;
--radius-xl: 0.75rem;
--radius-full: 9999px;
/* Typography */
--font-headline: 'Space Grotesk', sans-serif;
--font-body: 'Inter', sans-serif;
--font-label: 'Manrope', sans-serif;
/* Transitions */
--transition-fast: 150ms ease;
--transition-base: 200ms ease;
--transition-slow: 300ms ease;
}
/* ── Base ── */
html, body, #root {
height: 100%;
width: 100%;
overflow: hidden;
}
body {
background-color: var(--background);
color: var(--on-surface);
font-family: var(--font-body);
font-size: 14px;
line-height: 1.5;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}
/* ── Typography Classes ── */
.font-headline { font-family: var(--font-headline); }
.font-body { font-family: var(--font-body); }
.font-label { font-family: var(--font-label); }
/* ── Scrollbar ── */
::-webkit-scrollbar { width: 4px; height: 4px; }
::-webkit-scrollbar-track { background: var(--background); }
::-webkit-scrollbar-thumb { background: var(--outline-variant); border-radius: 10px; }
::-webkit-scrollbar-thumb:hover { background: var(--primary); }
/* ── Material Symbols ── */
.material-symbols-outlined {
font-variation-settings: 'FILL' 0, 'wght' 400, 'GRAD' 0, 'opsz' 24;
display: inline-flex;
align-items: center;
justify-content: center;
line-height: 1;
text-transform: none;
letter-spacing: normal;
word-wrap: normal;
white-space: nowrap;
direction: ltr;
vertical-align: middle;
user-select: none;
}
.material-symbols-outlined.filled {
font-variation-settings: 'FILL' 1, 'wght' 400, 'GRAD' 0, 'opsz' 24;
}
/* ── Utility ── */
.ghost-border {
border: 1px solid rgba(71, 72, 74, 0.15);
}
.glass {
background: rgba(36, 38, 41, 0.6);
backdrop-filter: blur(20px);
-webkit-backdrop-filter: blur(20px);
}
.gradient-primary {
background: linear-gradient(45deg, var(--primary), var(--primary-container));
}
.gradient-secondary {
background: linear-gradient(45deg, var(--secondary), var(--secondary-container));
}
/* ── Ambient Glow Shadows ── */
.glow-primary {
box-shadow: 0 0 32px rgba(143, 245, 255, 0.06);
}
.glow-secondary {
box-shadow: 0 0 32px rgba(172, 137, 255, 0.06);
}
/* ── Animations ── */
@keyframes fadeIn {
from { opacity: 0; transform: translateY(8px); }
to { opacity: 1; transform: translateY(0); }
}
@keyframes fadeInUp {
from { opacity: 0; transform: translateY(20px); }
to { opacity: 1; transform: translateY(0); }
}
@keyframes slideInLeft {
from { opacity: 0; transform: translateX(-20px); }
to { opacity: 1; transform: translateX(0); }
}
@keyframes pulse-glow {
0%, 100% { opacity: 0.4; }
50% { opacity: 1; }
}
@keyframes shimmer {
0% { background-position: -200% 0; }
100% { background-position: 200% 0; }
}
@keyframes float {
0%, 100% { transform: translateY(0px); }
50% { transform: translateY(-6px); }
}
@keyframes orb-drift {
0% { transform: translate(0, 0) scale(1); }
33% { transform: translate(30px, -20px) scale(1.05); }
66% { transform: translate(-20px, 15px) scale(0.95); }
100% { transform: translate(0, 0) scale(1); }
}
.animate-fade-in {
animation: fadeIn 0.4s ease forwards;
}
.animate-fade-in-up {
animation: fadeInUp 0.5s ease forwards;
}
.animate-slide-in-left {
animation: slideInLeft 0.4s ease forwards;
}
/* ── Selection ── */
::selection {
background: rgba(143, 245, 255, 0.25);
color: var(--on-surface);
}
/* ── Focus Visible ── */
:focus-visible {
outline: 2px solid var(--primary);
outline-offset: 2px;
}
/* ── Links ── */
a {
color: inherit;
text-decoration: none;
}
/* Input reset for dark theme */
input, textarea, select {
font-family: var(--font-body);
color: var(--on-surface);
}
input::placeholder, textarea::placeholder {
color: var(--outline);
}
/* Remove input number spinners */
input[type="number"]::-webkit-inner-spin-button,
input[type="number"]::-webkit-outer-spin-button {
-webkit-appearance: none;
margin: 0;
}
input[type="number"] {
-moz-appearance: textfield;
}

13
src/main.jsx Normal file
View file

@ -0,0 +1,13 @@
import { StrictMode } from 'react'
import { createRoot } from 'react-dom/client'
import { BrowserRouter } from 'react-router-dom'
import './index.css'
import App from './App.jsx'
createRoot(document.getElementById('root')).render(
<StrictMode>
<BrowserRouter>
<App />
</BrowserRouter>
</StrictMode>,
)

772
src/pages/KanbanPage.css Normal file
View file

@ -0,0 +1,772 @@
.kanban-layout {
display: flex;
flex-direction: column;
height: 100%;
width: 100%;
overflow: hidden;
}
.kanban-body {
display: flex;
flex: 1;
overflow: hidden;
}
/* ══════════════════════════════════
Sidebar
══════════════════════════════════ */
.kanban-sidebar {
width: 240px;
flex-shrink: 0;
display: flex;
flex-direction: column;
padding: 1rem;
gap: 0.5rem;
background: var(--surface-container-low);
border-right: 1px solid rgba(71, 72, 74, 0.15);
overflow-y: auto;
animation: slideInLeft 0.3s ease forwards;
}
.kanban-sidebar__workspace {
display: flex;
align-items: center;
gap: 0.75rem;
padding: 0.5rem;
background: rgba(30, 32, 34, 0.4);
border-radius: var(--radius-xl);
margin-bottom: 1rem;
}
.kanban-sidebar__ws-icon {
width: 40px;
height: 40px;
display: flex;
align-items: center;
justify-content: center;
background: rgba(172, 137, 255, 0.2);
border-radius: var(--radius-lg);
flex-shrink: 0;
}
.kanban-sidebar__ws-info {
display: flex;
flex-direction: column;
min-width: 0;
}
.kanban-sidebar__ws-name {
font-weight: 600;
font-size: 0.9rem;
color: var(--on-surface);
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
.kanban-sidebar__ws-version {
font-size: 0.6rem;
color: var(--on-surface-variant);
}
.kanban-sidebar__nav {
flex: 1;
display: flex;
flex-direction: column;
gap: 0.25rem;
}
.kanban-sidebar__nav-item {
display: flex;
align-items: center;
gap: 0.75rem;
padding: 0.625rem 0.75rem;
border: none;
background: transparent;
color: var(--on-surface-variant);
font-family: var(--font-body);
font-size: 0.875rem;
border-radius: var(--radius-md);
cursor: pointer;
transition: all var(--transition-base);
text-align: left;
width: 100%;
}
.kanban-sidebar__nav-item:hover {
background: rgba(30, 32, 34, 0.5);
color: var(--primary);
transform: translateX(4px);
}
.kanban-sidebar__nav-item--active {
background: var(--surface-container-high);
color: var(--primary);
font-weight: 700;
}
.kanban-sidebar__divider {
height: 1px;
background: rgba(71, 72, 74, 0.15);
margin: 1.5rem 0.75rem 0.5rem;
}
.kanban-sidebar__new-asset {
display: flex;
align-items: center;
justify-content: center;
gap: 0.5rem;
padding: 0.5rem;
margin: 0 0.75rem;
background: var(--surface-container-highest);
border: 1px solid rgba(71, 72, 74, 0.1);
border-radius: var(--radius-md);
color: var(--on-surface);
font-size: 0.7rem;
letter-spacing: 0.1em;
cursor: pointer;
transition: all var(--transition-base);
}
.kanban-sidebar__new-asset:hover {
background: var(--surface-variant);
}
.kanban-sidebar__bottom {
border-top: 1px solid rgba(71, 72, 74, 0.15);
padding-top: 1rem;
display: flex;
flex-direction: column;
gap: 0.25rem;
}
.kanban-sidebar__link {
display: flex;
align-items: center;
gap: 0.75rem;
padding: 0.5rem 0.75rem;
color: var(--on-surface-variant);
font-size: 0.875rem;
border-radius: var(--radius-md);
transition: all var(--transition-base);
}
.kanban-sidebar__link:hover {
color: var(--primary);
}
/* ══════════════════════════════════
Main Kanban Area
══════════════════════════════════ */
.kanban-main {
flex: 1;
overflow-x: auto;
overflow-y: hidden;
padding: 1.5rem;
background: var(--background);
}
.kanban-columns {
display: flex;
gap: 1.5rem;
height: 100%;
min-width: max-content;
}
/* ══════════════════════════════════
Column
══════════════════════════════════ */
.kanban-col {
display: flex;
flex-direction: column;
width: 320px;
min-width: 300px;
flex-shrink: 0;
animation: fadeIn 0.4s ease forwards;
}
.kanban-col:nth-child(2) { animation-delay: 0.06s; }
.kanban-col:nth-child(3) { animation-delay: 0.12s; }
.kanban-col:nth-child(4) { animation-delay: 0.18s; }
.kanban-col__header {
display: flex;
align-items: center;
justify-content: space-between;
padding: 0 0.5rem;
margin-bottom: 1rem;
}
.kanban-col__title-group {
display: flex;
align-items: center;
gap: 0.5rem;
}
.kanban-col__title {
font-size: 1rem;
font-weight: 700;
letter-spacing: 0.02em;
text-transform: uppercase;
}
.kanban-col__badge {
font-size: 0.6rem;
letter-spacing: 0.05em;
padding: 0.2rem 0.5rem;
border-radius: var(--radius-full);
background: var(--surface-container-high);
color: var(--on-surface-variant);
}
.kanban-col__badge--secondary {
background: rgba(172, 137, 255, 0.1);
color: var(--secondary);
}
.kanban-col__content {
flex: 1;
background: var(--surface-container-low);
padding: 0.75rem;
display: flex;
flex-direction: column;
gap: 1rem;
overflow-y: auto;
border-radius: var(--radius-sm);
}
/* ══════════════════════════════════
Image Cards
══════════════════════════════════ */
.image-card {
background: var(--surface-container-high);
border-radius: var(--radius-lg);
overflow: hidden;
border: 1px solid rgba(71, 72, 74, 0.05);
transition: all var(--transition-base);
cursor: pointer;
}
.image-card:hover {
border-color: rgba(143, 245, 255, 0.2);
}
.image-card__thumb {
height: 120px;
background: var(--surface-container-lowest);
overflow: hidden;
}
.image-card__thumb-placeholder {
width: 100%;
height: 100%;
display: flex;
align-items: center;
justify-content: center;
background:
radial-gradient(ellipse at 30% 50%, rgba(143, 245, 255, 0.04) 0%, transparent 60%),
radial-gradient(ellipse at 70% 30%, rgba(172, 137, 255, 0.03) 0%, transparent 50%);
}
.image-card__info {
padding: 0.75rem;
}
.image-card__row {
display: flex;
justify-content: space-between;
align-items: flex-start;
margin-bottom: 0.25rem;
}
.image-card__name {
font-size: 0.8125rem;
font-weight: 500;
}
.image-card__source {
font-size: 0.6rem;
padding: 0.125rem 0.375rem;
border-radius: var(--radius-xs);
white-space: nowrap;
}
.image-card__meta {
font-size: 0.6875rem;
color: var(--on-surface-variant);
}
/* ── Add Button ── */
.kanban-col__add-btn {
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
gap: 0.5rem;
padding: 1.25rem;
border: 2px dashed rgba(71, 72, 74, 0.1);
border-radius: var(--radius-lg);
background: transparent;
color: var(--on-surface-variant);
cursor: pointer;
transition: all var(--transition-base);
font-size: 0.6rem;
letter-spacing: 0.12em;
font-weight: 700;
}
.kanban-col__add-btn:hover {
background: var(--surface-container-high);
border-color: rgba(143, 245, 255, 0.3);
color: var(--primary);
}
/* ══════════════════════════════════
Parameters Card
══════════════════════════════════ */
.params-card {
background: var(--surface-container-highest);
padding: 1rem;
border-radius: var(--radius-lg);
box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}
.params-card--secondary {
border-left: 2px solid var(--secondary);
}
.params-card--tertiary {
border-left: 2px solid var(--tertiary);
}
.params-card__header {
display: flex;
align-items: center;
gap: 0.5rem;
margin-bottom: 1rem;
color: var(--on-surface-variant);
}
.params-card__title {
font-size: 0.7rem;
font-weight: 700;
letter-spacing: 0.12em;
}
.params-card__body {
display: flex;
flex-direction: column;
gap: 1rem;
}
.params-card__field {
display: flex;
flex-direction: column;
gap: 0.375rem;
}
.params-card__label {
font-size: 0.6rem;
text-transform: uppercase;
letter-spacing: 0.05em;
color: var(--on-surface-variant);
}
.params-card__input {
width: 100%;
padding: 0.5rem 0.75rem;
background: var(--surface-container-lowest);
border: none;
border-radius: var(--radius-lg);
font-size: 0.8125rem;
color: var(--on-surface);
outline: none;
transition: box-shadow var(--transition-base);
}
.params-card__input:focus {
box-shadow: 0 0 0 1px rgba(172, 137, 255, 0.5);
}
.params-card__input--seed {
color: var(--secondary);
font-family: monospace;
}
.params-card__select {
width: 100%;
padding: 0.5rem 0.75rem;
background: var(--surface-container-lowest);
border: none;
border-radius: var(--radius-lg);
font-size: 0.8125rem;
color: var(--on-surface);
outline: none;
appearance: none;
cursor: pointer;
}
.params-card__row {
display: grid;
grid-template-columns: 1fr 1fr;
gap: 0.75rem;
}
.params-card__engine {
display: flex;
align-items: center;
justify-content: space-between;
padding: 0.5rem;
background: rgba(13, 14, 16, 0.5);
border-radius: var(--radius-sm);
}
.params-card__engine-label {
font-size: 0.75rem;
color: var(--on-surface-variant);
}
.params-card__toggle-group {
display: flex;
background: var(--surface-container-lowest);
border-radius: var(--radius-sm);
padding: 0.125rem;
gap: 0.125rem;
}
.params-card__toggle {
padding: 0.25rem 0.5rem;
font-size: 0.6rem;
font-weight: 700;
background: transparent;
border: none;
border-radius: var(--radius-xs);
color: var(--on-surface-variant);
cursor: pointer;
transition: all var(--transition-fast);
}
.params-card__toggle--active-secondary {
background: var(--secondary);
color: var(--on-secondary);
}
.params-card__engine-grid {
display: grid;
grid-template-columns: 1fr 1fr;
gap: 0.5rem;
}
.params-card__engine-btn {
padding: 0.5rem;
font-size: 0.7rem;
font-weight: 700;
background: var(--surface-container-lowest);
border: 1px solid rgba(71, 72, 74, 0.1);
border-radius: var(--radius-sm);
color: var(--on-surface-variant);
cursor: pointer;
transition: all var(--transition-base);
}
.params-card__engine-btn:hover {
background: var(--surface-variant);
}
.params-card__engine-btn--active-tertiary {
border-color: rgba(220, 255, 178, 0.4);
color: var(--tertiary);
}
.params-card__checkboxes {
display: flex;
flex-direction: column;
gap: 0.5rem;
padding-top: 0.5rem;
}
.params-card__checkbox-label {
display: flex;
align-items: center;
gap: 0.5rem;
cursor: pointer;
font-size: 0.7rem;
color: var(--on-surface-variant);
}
.params-card__checkbox-label--dim {
opacity: 0.6;
}
.params-card__checkbox {
width: 16px;
height: 16px;
border-radius: var(--radius-xs);
display: flex;
align-items: center;
justify-content: center;
cursor: pointer;
flex-shrink: 0;
}
.params-card__checkbox--checked {
background: var(--tertiary);
}
.params-card__checkbox--unchecked {
background: var(--surface-container-lowest);
border: 1px solid rgba(71, 72, 74, 0.3);
}
.params-card__action {
display: flex;
align-items: center;
justify-content: center;
gap: 0.5rem;
width: 100%;
margin-top: 1.5rem;
padding: 0.75rem;
font-family: var(--font-headline);
font-weight: 700;
font-size: 0.8125rem;
border: none;
border-radius: var(--radius-sm);
cursor: pointer;
transition: all var(--transition-base);
}
.params-card__action:hover {
filter: brightness(1.1);
}
.params-card__action:active {
transform: scale(0.98);
}
.params-card__action--secondary {
background: var(--secondary);
color: var(--on-secondary);
}
.params-card__action--tertiary {
background: var(--tertiary);
color: var(--on-tertiary);
}
/* ══════════════════════════════════
Task Card
══════════════════════════════════ */
.task-card {
position: relative;
background: var(--surface-container-high);
padding: 1rem;
border-radius: var(--radius-lg);
border: 1px solid rgba(172, 137, 255, 0.2);
overflow: hidden;
}
.task-card__progress-bar {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 3px;
background: var(--surface-container-highest);
}
.task-card__progress-fill {
height: 100%;
background: var(--secondary);
transition: width 0.5s ease;
}
.task-card__header {
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 0.375rem;
}
.task-card__name {
font-size: 0.75rem;
font-weight: 500;
}
.task-card__pct {
font-size: 0.6rem;
font-family: monospace;
color: var(--secondary);
}
.task-card__status {
font-size: 0.625rem;
color: var(--on-surface-variant);
margin-bottom: 0.75rem;
}
.task-card__preview {
height: 48px;
background: var(--surface-container-lowest);
border-radius: var(--radius-sm);
display: flex;
align-items: center;
justify-content: center;
background: linear-gradient(90deg, rgba(172,137,255,0.03) 0%, rgba(172,137,255,0.15) 50%, rgba(172,137,255,0.03) 100%);
}
.task-card__preview-icon {
color: rgba(172, 137, 255, 0.4);
animation: pulse-glow 2s ease-in-out infinite;
}
/* ══════════════════════════════════
Tool Cards
══════════════════════════════════ */
.tool-card {
background: var(--surface-container-high);
padding: 1rem;
border-radius: var(--radius-lg);
border: 1px solid rgba(71, 72, 74, 0.1);
transition: all var(--transition-base);
cursor: pointer;
}
.tool-card:hover {
background: var(--surface-variant);
}
.tool-card--hoverable-tertiary:hover {
border-color: rgba(220, 255, 178, 0.4);
}
.tool-card--hoverable-primary:hover {
border-color: rgba(143, 245, 255, 0.4);
}
.tool-card__header {
display: flex;
align-items: center;
gap: 0.75rem;
margin-bottom: 0.5rem;
}
.tool-card__inline-header {
display: flex;
align-items: center;
justify-content: space-between;
width: 100%;
}
.tool-card__inline-left {
display: flex;
align-items: center;
gap: 0.75rem;
}
.tool-card__icon {
width: 40px;
height: 40px;
display: flex;
align-items: center;
justify-content: center;
border-radius: var(--radius-lg);
flex-shrink: 0;
}
.tool-card__icon--primary {
background: rgba(143, 245, 255, 0.1);
color: var(--primary);
}
.tool-card__name {
font-size: 0.8125rem;
font-weight: 500;
}
.tool-card__desc {
font-size: 0.625rem;
color: var(--on-surface-variant);
}
.tool-card__body-text {
font-size: 0.7rem;
color: var(--on-surface-variant);
line-height: 1.5;
}
.tool-card__api-badge {
font-size: 0.55rem;
font-family: monospace;
padding: 0.125rem 0.375rem;
border-radius: var(--radius-xs);
}
.tool-card__api-badge--tertiary {
background: rgba(220, 255, 178, 0.1);
color: var(--tertiary);
}
.tool-card__viewport {
height: 96px;
background: var(--surface-container-lowest);
border-radius: var(--radius-sm);
border: 1px solid rgba(71, 72, 74, 0.05);
display: flex;
align-items: center;
justify-content: center;
position: relative;
overflow: hidden;
margin-bottom: 0.5rem;
}
.tool-card__viewport-label {
position: absolute;
bottom: 0.5rem;
right: 0.5rem;
padding: 0.25rem 0.5rem;
background: rgba(30, 32, 34, 0.8);
backdrop-filter: blur(8px);
border-radius: var(--radius-xs);
font-family: monospace;
font-size: 0.55rem;
color: var(--primary);
}
/* ══════════════════════════════════
Presets Card
══════════════════════════════════ */
.presets-card {
padding: 0.75rem;
background: var(--surface-container-low);
border-radius: var(--radius-lg);
border: 1px solid rgba(71, 72, 74, 0.1);
}
.presets-card__title {
display: block;
font-size: 0.6rem;
letter-spacing: 0.12em;
color: var(--on-surface-variant);
margin-bottom: 0.75rem;
}
.presets-card__tags {
display: flex;
flex-wrap: wrap;
gap: 0.5rem;
}
.presets-card__tag {
padding: 0.25rem 0.5rem;
background: var(--surface-container-high);
border: 1px solid rgba(71, 72, 74, 0.1);
border-radius: var(--radius-sm);
font-size: 0.625rem;
color: var(--on-surface);
cursor: pointer;
transition: border-color var(--transition-base);
}
.presets-card__tag:hover {
border-color: rgba(220, 255, 178, 0.3);
}

383
src/pages/KanbanPage.jsx Normal file
View file

@ -0,0 +1,383 @@
import { useState } from 'react'
import { useParams, Link } from 'react-router-dom'
import { useProjects } from '../context/ProjectContext'
import Header from '../components/Header'
import Footer from '../components/Footer'
import './KanbanPage.css'
const SIDEBAR_ITEMS = [
{ id: 'images', icon: 'image', label: 'Images' },
{ id: 'meshgen', icon: 'deployed_code', label: 'Mesh Gen', filled: true },
{ id: 'meshedit', icon: 'edit_square', label: 'Mesh Edit' },
{ id: 'texturing', icon: 'texture', label: 'Texturing' },
]
const SAMPLE_IMAGES = [
{
id: 'img_1',
name: 'Neon Fractal_01',
resolution: '2048 x 2048',
format: 'PNG',
source: 'AI GEN',
color: 'var(--primary)',
},
{
id: 'img_2',
name: 'Reference_Plate_A',
resolution: '1024 x 1024',
format: 'JPG',
source: 'IMPORT',
color: 'var(--on-surface-variant)',
},
]
export default function KanbanPage() {
const { projectId } = useParams()
const { getProject } = useProjects()
const project = getProject(projectId)
const [activeTab, setActiveTab] = useState('meshgen')
const [genSeed, setGenSeed] = useState('8841295201')
const [faceCount, setFaceCount] = useState('15000')
const [meshBatch, setMeshBatch] = useState('1')
const [processEngine, setProcessEngine] = useState('api')
const [texResolution, setTexResolution] = useState('2048 x 2048 (2K)')
const [texEngine, setTexEngine] = useState('stable')
const [pbrEnabled, setPbrEnabled] = useState(true)
const [aoEnabled, setAoEnabled] = useState(false)
return (
<div className="kanban-layout">
<Header showSearch showCreateNew />
<div className="kanban-body">
{/* ── Sidebar ── */}
<aside className="kanban-sidebar" id="kanban-sidebar">
<div className="kanban-sidebar__workspace">
<div className="kanban-sidebar__ws-icon">
<span className="material-symbols-outlined" style={{ color: 'var(--secondary)' }}>token</span>
</div>
<div className="kanban-sidebar__ws-info">
<span className="kanban-sidebar__ws-name">{project?.name || 'Workspace'}</span>
<span className="kanban-sidebar__ws-version font-label">V0.4.2 Prototype</span>
</div>
</div>
<nav className="kanban-sidebar__nav">
{SIDEBAR_ITEMS.map(item => (
<button
key={item.id}
className={`kanban-sidebar__nav-item ${activeTab === item.id ? 'kanban-sidebar__nav-item--active' : ''}`}
onClick={() => setActiveTab(item.id)}
id={`sidebar-${item.id}`}
>
<span className={`material-symbols-outlined ${item.filled && activeTab === item.id ? 'filled' : ''}`} style={{ fontSize: '18px' }}>
{item.icon}
</span>
{item.label}
</button>
))}
<div className="kanban-sidebar__divider" />
<button className="kanban-sidebar__new-asset" id="new-asset-btn">
<span className="material-symbols-outlined" style={{ fontSize: '14px' }}>add</span>
<span className="font-label">NEW ASSET</span>
</button>
</nav>
<div className="kanban-sidebar__bottom">
<a href="#" className="kanban-sidebar__link">
<span className="material-symbols-outlined" style={{ fontSize: '18px' }}>menu_book</span>
Docs
</a>
<a href="#" className="kanban-sidebar__link">
<span className="material-symbols-outlined" style={{ fontSize: '18px' }}>help</span>
Support
</a>
</div>
</aside>
{/* ── Main Kanban Area ── */}
<main className="kanban-main" id="kanban-main">
<div className="kanban-columns">
{/* ═══ Column 1: Images ═══ */}
<div className="kanban-col" id="col-images">
<div className="kanban-col__header">
<div className="kanban-col__title-group">
<span className="material-symbols-outlined" style={{ fontSize: '18px', color: 'var(--primary)' }}>image</span>
<h2 className="kanban-col__title font-headline">IMAGES</h2>
</div>
<span className="kanban-col__badge font-label">04 ITEMS</span>
</div>
<div className="kanban-col__content">
{SAMPLE_IMAGES.map(img => (
<div key={img.id} className="image-card" id={`image-card-${img.id}`}>
<div className="image-card__thumb">
<div className="image-card__thumb-placeholder">
<span className="material-symbols-outlined" style={{ fontSize: '32px', color: 'rgba(143,245,255,0.08)' }}>image</span>
</div>
</div>
<div className="image-card__info">
<div className="image-card__row">
<h3 className="image-card__name">{img.name}</h3>
<span
className="image-card__source"
style={{
color: img.source === 'AI GEN' ? 'var(--primary)' : 'var(--on-surface-variant)',
background: img.source === 'AI GEN' ? 'rgba(143,245,255,0.1)' : 'rgba(71,72,74,0.2)',
}}
>
{img.source}
</span>
</div>
<p className="image-card__meta font-label">{img.resolution} • {img.format}</p>
</div>
</div>
))}
<button className="kanban-col__add-btn" id="add-image-btn">
<span className="material-symbols-outlined">upload_file</span>
<span className="font-label">ADD NEW IMAGE</span>
</button>
</div>
</div>
{/* ═══ Column 2: Mesh Generation ═══ */}
<div className="kanban-col" id="col-meshgen">
<div className="kanban-col__header">
<div className="kanban-col__title-group">
<span className="material-symbols-outlined" style={{ fontSize: '18px', color: 'var(--secondary)' }}>deployed_code</span>
<h2 className="kanban-col__title font-headline">MESH GEN</h2>
</div>
<span className="kanban-col__badge kanban-col__badge--secondary font-label">PROCESSING</span>
</div>
<div className="kanban-col__content">
{/* Parameters Card */}
<div className="params-card params-card--secondary" id="meshgen-params">
<div className="params-card__header">
<span className="material-symbols-outlined" style={{ fontSize: '14px' }}>settings_input_component</span>
<span className="params-card__title font-label">PARAMETERS</span>
</div>
<div className="params-card__body">
<div className="params-card__field">
<label className="params-card__label font-label">Generation Seed</label>
<input
type="text"
className="params-card__input params-card__input--seed"
value={genSeed}
onChange={(e) => setGenSeed(e.target.value)}
id="gen-seed-input"
/>
</div>
<div className="params-card__row">
<div className="params-card__field">
<label className="params-card__label font-label">Face Count</label>
<input
type="number"
className="params-card__input"
value={faceCount}
onChange={(e) => setFaceCount(e.target.value)}
id="face-count-input"
/>
</div>
<div className="params-card__field">
<label className="params-card__label font-label">Mesh Batch</label>
<input
type="number"
className="params-card__input"
value={meshBatch}
onChange={(e) => setMeshBatch(e.target.value)}
id="mesh-batch-input"
/>
</div>
</div>
<div className="params-card__engine">
<span className="params-card__engine-label">Processing Engine</span>
<div className="params-card__toggle-group">
<button
className={`params-card__toggle ${processEngine === 'api' ? 'params-card__toggle--active-secondary' : ''}`}
onClick={() => setProcessEngine('api')}
id="engine-api-btn"
>API</button>
<button
className={`params-card__toggle ${processEngine === 'comfy' ? 'params-card__toggle--active-secondary' : ''}`}
onClick={() => setProcessEngine('comfy')}
id="engine-comfy-btn"
>COMFY</button>
</div>
</div>
</div>
<button className="params-card__action params-card__action--secondary" id="generate-mesh-btn">
<span className="material-symbols-outlined" style={{ fontSize: '18px' }}>bolt</span>
GENERATE MESH
</button>
</div>
{/* Active Task */}
<div className="task-card" id="active-task">
<div className="task-card__progress-bar">
<div className="task-card__progress-fill" style={{ width: '64%' }} />
</div>
<div className="task-card__header">
<span className="task-card__name">Task: Mesh_Synth_4</span>
<span className="task-card__pct">64%</span>
</div>
<p className="task-card__status">Initializing vertex buffers...</p>
<div className="task-card__preview">
<span className="material-symbols-outlined task-card__preview-icon">hourglass_top</span>
</div>
</div>
</div>
</div>
{/* ═══ Column 3: Mesh Edit ═══ */}
<div className="kanban-col" id="col-meshedit">
<div className="kanban-col__header">
<div className="kanban-col__title-group">
<span className="material-symbols-outlined" style={{ fontSize: '18px' }}>edit_square</span>
<h2 className="kanban-col__title font-headline">MESH EDIT</h2>
</div>
<span className="kanban-col__badge font-label">3 TOOLS</span>
</div>
<div className="kanban-col__content">
{/* 3D Editor */}
<div className="tool-card" id="tool-3d-editor">
<div className="tool-card__header">
<div className="tool-card__icon tool-card__icon--primary">
<span className="material-symbols-outlined">view_in_ar</span>
</div>
<div>
<h3 className="tool-card__name">3D Editor</h3>
<p className="tool-card__desc">Native vertex manipulator</p>
</div>
</div>
<div className="tool-card__viewport">
<span className="material-symbols-outlined" style={{ fontSize: '40px', color: 'rgba(253,251,254,0.06)' }}>grid_view</span>
<div className="tool-card__viewport-label">
OPEN VIEWPORT
</div>
</div>
</div>
{/* AI Simplify */}
<div className="tool-card tool-card--hoverable-tertiary" id="tool-ai-simplify">
<div className="tool-card__header">
<div className="tool-card__inline-header">
<div className="tool-card__inline-left">
<span className="material-symbols-outlined" style={{ color: 'var(--tertiary)' }}>compress</span>
<h3 className="tool-card__name">AI Simplify</h3>
</div>
<span className="tool-card__api-badge tool-card__api-badge--tertiary">API</span>
</div>
</div>
<p className="tool-card__body-text">Intelligent decimation preserving silhouette topology. Best for game assets.</p>
</div>
{/* Remeshing */}
<div className="tool-card tool-card--hoverable-primary" id="tool-remeshing">
<div className="tool-card__header">
<span className="material-symbols-outlined">rebase_edit</span>
<h3 className="tool-card__name">Remeshing</h3>
</div>
<p className="tool-card__body-text">Quadriflow or Instant Meshes conversion logic.</p>
</div>
</div>
</div>
{/* ═══ Column 4: Texturing ═══ */}
<div className="kanban-col" id="col-texturing">
<div className="kanban-col__header">
<div className="kanban-col__title-group">
<span className="material-symbols-outlined" style={{ fontSize: '18px', color: 'var(--tertiary)' }}>texture</span>
<h2 className="kanban-col__title font-headline">TEXTURING</h2>
</div>
<span className="kanban-col__badge font-label">READY</span>
</div>
<div className="kanban-col__content">
{/* Texture Params Card */}
<div className="params-card params-card--tertiary" id="texturing-params">
<div className="params-card__header">
<span className="material-symbols-outlined" style={{ fontSize: '14px', color: 'var(--tertiary)' }}>palette</span>
<span className="params-card__title font-label">MAP GENERATION</span>
</div>
<div className="params-card__body">
<div className="params-card__field">
<label className="params-card__label font-label">Output Resolution</label>
<select
className="params-card__select"
value={texResolution}
onChange={(e) => setTexResolution(e.target.value)}
id="tex-resolution-select"
>
<option>1024 x 1024 (1K)</option>
<option>2048 x 2048 (2K)</option>
<option>4096 x 4096 (4K)</option>
</select>
</div>
<div className="params-card__field">
<label className="params-card__label font-label">Engine Configuration</label>
<div className="params-card__engine-grid">
<button
className={`params-card__engine-btn ${texEngine === 'stable' ? 'params-card__engine-btn--active-tertiary' : ''}`}
onClick={() => setTexEngine('stable')}
id="tex-engine-stable"
>STABLE API</button>
<button
className={`params-card__engine-btn ${texEngine === 'comfy' ? 'params-card__engine-btn--active-tertiary' : ''}`}
onClick={() => setTexEngine('comfy')}
id="tex-engine-comfy"
>COMFYUI</button>
</div>
</div>
<div className="params-card__checkboxes">
<label className="params-card__checkbox-label">
<div className={`params-card__checkbox ${pbrEnabled ? 'params-card__checkbox--checked' : ''}`} onClick={() => setPbrEnabled(!pbrEnabled)}>
{pbrEnabled && <span className="material-symbols-outlined" style={{ fontSize: '10px', color: 'var(--on-tertiary)', fontWeight: 700 }}>check</span>}
</div>
<span>PBR Map Set (Diff, Norm, Rough)</span>
</label>
<label className={`params-card__checkbox-label ${!aoEnabled ? 'params-card__checkbox-label--dim' : ''}`}>
<div className={`params-card__checkbox ${aoEnabled ? 'params-card__checkbox--checked' : 'params-card__checkbox--unchecked'}`} onClick={() => setAoEnabled(!aoEnabled)}>
{aoEnabled && <span className="material-symbols-outlined" style={{ fontSize: '10px', color: 'var(--on-tertiary)', fontWeight: 700 }}>check</span>}
</div>
<span>Bake Ambient Occlusion</span>
</label>
</div>
</div>
<button className="params-card__action params-card__action--tertiary" id="start-texturing-btn">
<span className="material-symbols-outlined" style={{ fontSize: '18px' }}>brush</span>
START TEXTURING
</button>
</div>
{/* Recent Presets */}
<div className="presets-card" id="recent-presets">
<span className="presets-card__title font-label">RECENT PRESETS</span>
<div className="presets-card__tags">
<div className="presets-card__tag">Cybermetal_01</div>
<div className="presets-card__tag">Procedural_Grip</div>
<div className="presets-card__tag">Organic_Skin_v2</div>
</div>
</div>
</div>
</div>
</div>
</main>
</div>
<Footer variant="kanban" />
</div>
)
}

436
src/pages/LoginPage.css Normal file
View file

@ -0,0 +1,436 @@
.login-page {
width: 100%;
height: 100%;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
position: relative;
overflow: hidden;
background: var(--background);
}
/* ── Background Orbs ── */
.login-page__bg {
position: absolute;
inset: 0;
z-index: 0;
pointer-events: none;
overflow: hidden;
}
.login-page__orb {
position: absolute;
border-radius: 50%;
filter: blur(100px);
opacity: 0.12;
}
.login-page__orb--1 {
width: 600px;
height: 600px;
background: var(--primary);
top: 20%;
left: 50%;
transform: translate(-50%, -50%);
animation: orb-drift 15s ease-in-out infinite;
}
.login-page__orb--2 {
width: 400px;
height: 400px;
background: var(--secondary);
bottom: 10%;
right: 10%;
animation: orb-drift 20s ease-in-out infinite reverse;
opacity: 0.08;
}
.login-page__orb--3 {
width: 300px;
height: 300px;
background: var(--tertiary);
bottom: 30%;
left: 5%;
animation: orb-drift 18s ease-in-out infinite;
animation-delay: -5s;
opacity: 0.06;
}
/* ── Content ── */
.login-page__content {
position: relative;
z-index: 1;
width: 100%;
max-width: 420px;
padding: 0 1.5rem;
animation: fadeInUp 0.6s ease forwards;
}
/* ── Brand ── */
.login-page__brand {
text-align: center;
margin-bottom: 2rem;
}
.login-page__logo-icon {
display: inline-flex;
align-items: center;
justify-content: center;
width: 56px;
height: 56px;
background: rgba(143, 245, 255, 0.08);
border-radius: var(--radius-xl);
margin-bottom: 1rem;
animation: float 4s ease-in-out infinite;
}
.login-page__title {
font-family: var(--font-headline);
font-size: 2rem;
font-weight: 700;
color: var(--primary);
letter-spacing: -0.03em;
margin-bottom: 0.25rem;
}
.login-page__subtitle {
font-family: var(--font-body);
font-size: 0.85rem;
color: var(--on-surface-variant);
}
/* ── Card ── */
.login-page__card {
background: var(--surface-container-low);
padding: 2rem;
border-radius: var(--radius-xl);
border: 1px solid rgba(71, 72, 74, 0.1);
box-shadow: 0 24px 64px rgba(0, 0, 0, 0.4);
}
.login-page__card-header {
text-align: center;
margin-bottom: 1.75rem;
}
.login-page__card-title {
font-family: var(--font-headline);
font-size: 1.5rem;
font-weight: 700;
color: var(--on-surface);
margin-bottom: 0.25rem;
}
.login-page__card-desc {
font-size: 0.8rem;
color: var(--on-surface-variant);
}
/* ── Form ── */
.login-page__form {
display: flex;
flex-direction: column;
gap: 1.25rem;
}
.login-page__error {
display: flex;
align-items: center;
gap: 0.5rem;
padding: 0.625rem 0.875rem;
background: rgba(255, 113, 108, 0.08);
border-radius: var(--radius-sm);
color: var(--error);
font-size: 0.8rem;
}
.login-page__field {
display: flex;
flex-direction: column;
gap: 0.375rem;
}
.login-page__label {
font-family: var(--font-label);
font-size: 0.65rem;
font-weight: 600;
text-transform: uppercase;
letter-spacing: 0.1em;
color: var(--on-surface-variant);
}
.login-page__input-wrap {
position: relative;
}
.login-page__input-icon {
position: absolute;
left: 0.875rem;
top: 50%;
transform: translateY(-50%);
font-size: 18px;
color: var(--outline);
pointer-events: none;
transition: color var(--transition-base);
z-index: 1;
}
.login-page__input {
width: 100%;
padding: 0.75rem 0.875rem 0.75rem 2.75rem;
background: var(--surface-container-highest);
border: none;
border-radius: var(--radius-lg);
font-size: 0.875rem;
color: var(--on-surface);
outline: none;
transition: all var(--transition-base);
}
.login-page__input:focus {
box-shadow: 0 0 0 2px var(--primary);
}
.login-page__input:focus ~ .login-page__input-glow {
opacity: 1;
width: 100%;
}
.login-page__input-wrap:focus-within .login-page__input-icon {
color: var(--primary);
}
.login-page__input-glow {
position: absolute;
bottom: 0;
left: 0;
height: 2px;
width: 0;
background: var(--primary);
border-radius: 1px;
transition: all var(--transition-slow);
opacity: 0;
}
/* ── Options ── */
.login-page__options {
display: flex;
align-items: center;
justify-content: space-between;
}
.login-page__remember {
display: flex;
align-items: center;
gap: 0.5rem;
font-size: 0.75rem;
color: var(--on-surface-variant);
cursor: pointer;
}
.login-page__checkbox {
width: 14px;
height: 14px;
accent-color: var(--primary);
cursor: pointer;
}
.login-page__forgot {
font-size: 0.75rem;
color: var(--primary);
opacity: 0.8;
transition: opacity var(--transition-base);
}
.login-page__forgot:hover {
opacity: 1;
}
/* ── Submit ── */
.login-page__submit {
display: flex;
align-items: center;
justify-content: center;
gap: 0.5rem;
width: 100%;
padding: 0.875rem;
background: var(--primary);
color: var(--on-primary);
font-family: var(--font-headline);
font-weight: 700;
font-size: 0.9375rem;
border: none;
border-radius: var(--radius-lg);
cursor: pointer;
transition: all var(--transition-base);
margin-top: 0.5rem;
}
.login-page__submit:hover:not(:disabled) {
background: var(--primary-dim);
transform: translateY(-1px);
box-shadow: 0 4px 20px rgba(143, 245, 255, 0.2);
}
.login-page__submit:active:not(:disabled) {
transform: scale(0.98);
}
.login-page__submit:disabled {
opacity: 0.7;
cursor: not-allowed;
}
.login-page__submit--loading {
background: var(--surface-container-high);
color: var(--primary);
}
.login-page__spinner {
font-size: 18px;
animation: spin 1s linear infinite;
}
@keyframes spin {
from { transform: rotate(0deg); }
to { transform: rotate(360deg); }
}
/* ── Divider ── */
.login-page__divider {
display: flex;
align-items: center;
gap: 1rem;
margin: 1.25rem 0;
color: var(--outline);
font-size: 0.7rem;
text-transform: uppercase;
letter-spacing: 0.08em;
}
.login-page__divider::before,
.login-page__divider::after {
content: '';
flex: 1;
height: 1px;
background: rgba(71, 72, 74, 0.2);
}
/* ── Alt Button ── */
.login-page__alt-btn {
display: flex;
align-items: center;
justify-content: center;
gap: 0.5rem;
width: 100%;
padding: 0.75rem;
background: transparent;
border: 1px solid rgba(71, 72, 74, 0.3);
border-radius: var(--radius-lg);
color: var(--secondary);
font-family: var(--font-headline);
font-weight: 600;
font-size: 0.875rem;
cursor: pointer;
transition: all var(--transition-base);
}
.login-page__alt-btn:hover {
background: var(--surface-container-high);
border-color: var(--secondary);
color: var(--on-surface);
}
/* ── System Info ── */
.login-page__sys-info {
display: grid;
grid-template-columns: 1fr 1fr;
gap: 1rem;
margin-top: 1.5rem;
}
.login-page__sys-item {
display: flex;
align-items: center;
gap: 0.75rem;
padding: 0.75rem;
background: rgba(18, 19, 22, 0.5);
border-radius: var(--radius-lg);
border: 1px solid rgba(71, 72, 74, 0.05);
}
.login-page__sys-icon {
display: flex;
align-items: center;
justify-content: center;
width: 32px;
height: 32px;
border-radius: var(--radius-lg);
flex-shrink: 0;
}
.login-page__sys-icon--secondary {
background: rgba(172, 137, 255, 0.1);
color: var(--secondary);
}
.login-page__sys-icon--tertiary {
background: rgba(220, 255, 178, 0.1);
color: var(--tertiary);
}
.login-page__sys-label {
display: block;
font-family: var(--font-label);
font-size: 0.55rem;
text-transform: uppercase;
letter-spacing: 0.05em;
color: var(--on-surface-variant);
}
.login-page__sys-value {
display: block;
font-family: var(--font-body);
font-size: 0.75rem;
font-weight: 500;
color: var(--on-surface);
}
/* ── Footer ── */
.login-page__footer {
position: absolute;
bottom: 0;
left: 0;
right: 0;
display: flex;
align-items: center;
justify-content: space-between;
padding: 1rem 1.5rem;
font-family: var(--font-label);
font-size: 10px;
text-transform: uppercase;
letter-spacing: 0.1em;
color: var(--outline);
border-top: 1px solid rgba(71, 72, 74, 0.1);
z-index: 1;
}
.login-page__footer-left,
.login-page__footer-right {
display: flex;
gap: 1rem;
}
.login-page__footer-status {
color: var(--tertiary);
}
.login-page__footer-right a {
color: var(--outline);
transition: color var(--transition-base);
}
.login-page__footer-right a:hover {
color: var(--primary);
}

184
src/pages/LoginPage.jsx Normal file
View file

@ -0,0 +1,184 @@
import { useState } from 'react'
import { useNavigate } from 'react-router-dom'
import { useAuth } from '../context/AuthContext'
import './LoginPage.css'
export default function LoginPage() {
const [email, setEmail] = useState('')
const [password, setPassword] = useState('')
const [isLoading, setIsLoading] = useState(false)
const [error, setError] = useState('')
const { login } = useAuth()
const navigate = useNavigate()
const handleSubmit = async (e) => {
e.preventDefault()
setError('')
if (!email || !password) {
setError('Please enter both email and password.')
return
}
setIsLoading(true)
// Simulate network delay
await new Promise(r => setTimeout(r, 800))
const success = login(email, password)
if (success) {
navigate('/projects')
} else {
setError('Invalid credentials.')
}
setIsLoading(false)
}
return (
<div className="login-page">
{/* Animated background orbs */}
<div className="login-page__bg">
<div className="login-page__orb login-page__orb--1" />
<div className="login-page__orb login-page__orb--2" />
<div className="login-page__orb login-page__orb--3" />
</div>
<div className="login-page__content">
{/* Logo & Tagline */}
<div className="login-page__brand">
<div className="login-page__logo-icon">
<span className="material-symbols-outlined filled" style={{ fontSize: '32px', color: 'var(--primary)' }}>
deployed_code
</span>
</div>
<h1 className="login-page__title">3D Gen Studio</h1>
<p className="login-page__subtitle">AI-Powered 3D Mesh Generation Pipeline</p>
</div>
{/* Login Card */}
<div className="login-page__card">
<div className="login-page__card-header">
<h2 className="login-page__card-title">Sign In</h2>
<p className="login-page__card-desc">Access your workspace and generation pipeline.</p>
</div>
<form className="login-page__form" onSubmit={handleSubmit} id="login-form">
{error && (
<div className="login-page__error" id="login-error">
<span className="material-symbols-outlined" style={{ fontSize: '16px' }}>error</span>
{error}
</div>
)}
<div className="login-page__field">
<label className="login-page__label" htmlFor="login-email">Email Address</label>
<div className="login-page__input-wrap">
<span className="material-symbols-outlined login-page__input-icon">mail</span>
<input
id="login-email"
type="email"
className="login-page__input"
placeholder="architect@studio.io"
value={email}
onChange={(e) => setEmail(e.target.value)}
autoComplete="email"
/>
<div className="login-page__input-glow" />
</div>
</div>
<div className="login-page__field">
<label className="login-page__label" htmlFor="login-password">Password</label>
<div className="login-page__input-wrap">
<span className="material-symbols-outlined login-page__input-icon">lock</span>
<input
id="login-password"
type="password"
className="login-page__input"
placeholder="••••••••••"
value={password}
onChange={(e) => setPassword(e.target.value)}
autoComplete="current-password"
/>
<div className="login-page__input-glow" />
</div>
</div>
<div className="login-page__options">
<label className="login-page__remember">
<input type="checkbox" className="login-page__checkbox" />
<span>Remember this device</span>
</label>
<a href="#" className="login-page__forgot">Forgot password?</a>
</div>
<button
type="submit"
className={`login-page__submit ${isLoading ? 'login-page__submit--loading' : ''}`}
id="login-submit-btn"
disabled={isLoading}
>
{isLoading ? (
<>
<span className="material-symbols-outlined login-page__spinner">progress_activity</span>
Authenticating...
</>
) : (
<>
<span className="material-symbols-outlined" style={{ fontSize: '18px' }}>login</span>
Sign In
</>
)}
</button>
</form>
<div className="login-page__divider">
<span>or</span>
</div>
<button className="login-page__alt-btn" id="demo-access-btn" onClick={() => {
setEmail('demo@3dgenstudio.io')
setPassword('demo')
}}>
<span className="material-symbols-outlined" style={{ fontSize: '18px' }}>science</span>
Try Demo Access
</button>
</div>
{/* System Info */}
<div className="login-page__sys-info">
<div className="login-page__sys-item">
<div className="login-page__sys-icon login-page__sys-icon--secondary">
<span className="material-symbols-outlined filled" style={{ fontSize: '16px' }}>deployed_code</span>
</div>
<div>
<span className="login-page__sys-label">Engine</span>
<span className="login-page__sys-value">Synthesis V4.2</span>
</div>
</div>
<div className="login-page__sys-item">
<div className="login-page__sys-icon login-page__sys-icon--tertiary">
<span className="material-symbols-outlined filled" style={{ fontSize: '16px' }}>memory</span>
</div>
<div>
<span className="login-page__sys-label">Allocated GPU</span>
<span className="login-page__sys-value">24GB VRAM</span>
</div>
</div>
</div>
</div>
{/* Footer */}
<footer className="login-page__footer">
<div className="login-page__footer-left">
<span>Server Status: <span className="login-page__footer-status">Optimal</span></span>
<span>Latency: 14ms</span>
</div>
<div className="login-page__footer-right">
<a href="#">Documentation</a>
<a href="#">Terms of Service</a>
</div>
</footer>
</div>
)
}

510
src/pages/ProjectsPage.css Normal file
View file

@ -0,0 +1,510 @@
.projects-layout {
display: flex;
flex-direction: column;
height: 100%;
width: 100%;
overflow: hidden;
}
.projects-page {
flex: 1;
overflow-y: auto;
padding: 2rem 2.5rem;
position: relative;
}
/* ── Container ── */
.projects-page__container {
max-width: 1200px;
margin: 0 auto;
}
.projects-page__header {
display: flex;
align-items: flex-end;
justify-content: space-between;
margin-bottom: 2rem;
animation: fadeIn 0.4s ease forwards;
}
.projects-page__page-title {
font-size: 1.75rem;
font-weight: 700;
letter-spacing: -0.02em;
color: var(--on-surface);
}
.projects-page__page-desc {
font-size: 0.8rem;
color: var(--on-surface-variant);
margin-top: 0.25rem;
}
.projects-page__new-btn {
display: flex;
align-items: center;
gap: 0.5rem;
padding: 0.625rem 1.25rem;
background: var(--primary);
color: var(--on-primary);
font-family: var(--font-headline);
font-weight: 600;
font-size: 0.875rem;
border: none;
border-radius: var(--radius-md);
cursor: pointer;
transition: all var(--transition-base);
}
.projects-page__new-btn:hover {
filter: brightness(1.1);
transform: translateY(-1px);
box-shadow: 0 4px 16px rgba(143, 245, 255, 0.15);
}
.projects-page__new-btn:active {
transform: scale(0.98);
}
/* ── Grid ── */
.projects-page__grid {
display: grid;
grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
gap: 1.25rem;
}
/* ── Project Card ── */
.project-card {
position: relative;
background: var(--surface-container-low);
border-radius: var(--radius-xl);
overflow: hidden;
cursor: pointer;
transition: all var(--transition-base);
animation: fadeInUp 0.5s ease forwards;
opacity: 0;
}
.project-card:hover {
background: var(--surface-container);
transform: translateY(-2px);
box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}
.project-card__thumb {
position: relative;
height: 140px;
background: var(--surface-container-lowest);
overflow: hidden;
}
.project-card__thumb-inner {
width: 100%;
height: 100%;
display: flex;
align-items: center;
justify-content: center;
background:
radial-gradient(circle at 30% 60%, rgba(143, 245, 255, 0.04) 0%, transparent 60%),
radial-gradient(circle at 70% 30%, rgba(172, 137, 255, 0.03) 0%, transparent 50%);
}
.project-card__status {
position: absolute;
top: 0.75rem;
right: 0.75rem;
font-family: var(--font-label);
font-size: 0.6rem;
font-weight: 700;
text-transform: uppercase;
letter-spacing: 0.08em;
padding: 0.25rem 0.625rem;
border-radius: var(--radius-full);
}
.project-card__status--active {
background: rgba(143, 245, 255, 0.1);
color: var(--primary);
}
.project-card__status--processing {
background: rgba(172, 137, 255, 0.1);
color: var(--secondary);
animation: pulse-glow 2s ease-in-out infinite;
}
.project-card__status--complete {
background: rgba(220, 255, 178, 0.1);
color: var(--tertiary);
}
.project-card__info {
padding: 1rem 1.25rem 1.25rem;
}
.project-card__name {
font-size: 1rem;
font-weight: 600;
letter-spacing: -0.01em;
color: var(--on-surface);
margin-bottom: 0.375rem;
}
.project-card__desc {
font-size: 0.75rem;
color: var(--on-surface-variant);
line-height: 1.5;
display: -webkit-box;
-webkit-line-clamp: 2;
-webkit-box-orient: vertical;
overflow: hidden;
margin-bottom: 1rem;
}
.project-card__meta {
display: flex;
gap: 1rem;
margin-bottom: 0.75rem;
}
.project-card__meta-item {
display: flex;
align-items: center;
gap: 0.375rem;
font-size: 0.7rem;
color: var(--on-surface-variant);
}
.project-card__footer {
display: flex;
align-items: center;
justify-content: space-between;
padding-top: 0.75rem;
}
.project-card__preset {
font-size: 0.6rem;
text-transform: uppercase;
letter-spacing: 0.05em;
color: var(--secondary);
background: rgba(172, 137, 255, 0.08);
padding: 0.2rem 0.5rem;
border-radius: var(--radius-sm);
}
.project-card__date {
font-size: 0.65rem;
color: var(--outline);
font-family: var(--font-label);
}
.project-card__delete {
position: absolute;
top: 0.75rem;
left: 0.75rem;
width: 28px;
height: 28px;
display: flex;
align-items: center;
justify-content: center;
background: rgba(0, 0, 0, 0.6);
backdrop-filter: blur(8px);
border: none;
border-radius: var(--radius-sm);
color: var(--on-surface-variant);
cursor: pointer;
opacity: 0;
transition: all var(--transition-base);
}
.project-card:hover .project-card__delete {
opacity: 1;
}
.project-card__delete:hover {
background: var(--error-container);
color: var(--error);
}
/* ── Empty State ── */
.projects-page__empty {
grid-column: 1 / -1;
display: flex;
flex-direction: column;
align-items: center;
gap: 1rem;
padding: 4rem 2rem;
color: var(--on-surface-variant);
font-size: 0.875rem;
animation: fadeIn 0.4s ease forwards;
}
/* ── Modal ── */
.projects-page__modal-overlay {
position: fixed;
inset: 0;
z-index: 100;
background: rgba(0, 0, 0, 0.7);
backdrop-filter: blur(8px);
display: flex;
align-items: center;
justify-content: center;
animation: fadeIn 0.2s ease forwards;
}
.projects-page__modal {
position: relative;
width: 100%;
max-width: 520px;
background: var(--surface-container-low);
border-radius: var(--radius-xl);
border: 1px solid rgba(71, 72, 74, 0.1);
box-shadow: 0 32px 80px rgba(0, 0, 0, 0.5);
padding: 2.5rem;
animation: fadeInUp 0.3s ease forwards;
overflow: hidden;
}
.projects-page__modal-glow {
position: absolute;
top: -200px;
left: 50%;
transform: translateX(-50%);
width: 500px;
height: 500px;
background: radial-gradient(circle, rgba(143, 245, 255, 0.06) 0%, transparent 70%);
pointer-events: none;
}
.projects-page__modal-header {
text-align: center;
margin-bottom: 2rem;
position: relative;
}
.projects-page__modal-title {
font-size: 1.75rem;
font-weight: 700;
letter-spacing: -0.02em;
color: var(--on-surface);
margin-bottom: 0.375rem;
}
.projects-page__modal-desc {
font-size: 0.8rem;
color: var(--on-surface-variant);
}
/* ── Form ── */
.projects-page__form {
display: flex;
flex-direction: column;
gap: 1.5rem;
position: relative;
}
.projects-page__field {
display: flex;
flex-direction: column;
gap: 0.5rem;
}
.projects-page__label {
font-size: 0.65rem;
font-weight: 600;
text-transform: uppercase;
letter-spacing: 0.12em;
color: var(--on-surface-variant);
}
.projects-page__input-wrap {
position: relative;
}
.projects-page__input {
width: 100%;
padding: 0.75rem 1rem;
background: var(--surface-container-highest);
border: none;
border-radius: var(--radius-lg);
font-size: 0.875rem;
color: var(--on-surface);
outline: none;
transition: all var(--transition-base);
}
.projects-page__input:focus {
box-shadow: 0 0 0 2px var(--primary);
}
.projects-page__input-underline {
position: absolute;
bottom: 0;
left: 0;
height: 2px;
width: 0;
background: var(--primary);
transition: width var(--transition-slow);
}
.projects-page__input-wrap:focus-within .projects-page__input-underline {
width: 100%;
}
.projects-page__textarea {
width: 100%;
padding: 0.75rem 1rem;
background: var(--surface-container-highest);
border: none;
border-radius: var(--radius-lg);
font-size: 0.875rem;
color: var(--on-surface);
outline: none;
resize: none;
transition: all var(--transition-base);
}
.projects-page__textarea:focus {
box-shadow: 0 0 0 2px var(--primary);
}
.projects-page__select-wrap {
position: relative;
}
.projects-page__select {
width: 100%;
padding: 0.75rem 1rem;
padding-right: 2.5rem;
background: var(--surface-container-highest);
border: none;
border-radius: var(--radius-lg);
font-size: 0.875rem;
color: var(--on-surface);
outline: none;
appearance: none;
cursor: pointer;
transition: all var(--transition-base);
}
.projects-page__select:focus {
box-shadow: 0 0 0 2px var(--primary);
}
.projects-page__select-icon {
position: absolute;
right: 0.75rem;
top: 50%;
transform: translateY(-50%);
color: var(--outline);
pointer-events: none;
font-size: 20px;
}
.projects-page__form-actions {
display: flex;
flex-direction: column;
gap: 0.75rem;
padding-top: 0.5rem;
}
.projects-page__btn-primary {
display: flex;
align-items: center;
justify-content: center;
gap: 0.5rem;
width: 100%;
padding: 1rem;
background: var(--primary);
color: var(--on-primary);
font-family: var(--font-headline);
font-weight: 700;
font-size: 0.9375rem;
border: none;
border-radius: var(--radius-lg);
cursor: pointer;
transition: all var(--transition-base);
}
.projects-page__btn-primary:hover {
background: var(--primary-dim);
transform: translateY(-1px);
box-shadow: 0 4px 20px rgba(143, 245, 255, 0.2);
}
.projects-page__btn-primary:active {
transform: scale(0.98);
}
.projects-page__btn-secondary {
width: 100%;
padding: 1rem;
background: transparent;
border: 1px solid rgba(71, 72, 74, 0.3);
border-radius: var(--radius-lg);
color: var(--on-surface-variant);
font-family: var(--font-headline);
font-weight: 600;
font-size: 0.9375rem;
cursor: pointer;
transition: all var(--transition-base);
}
.projects-page__btn-secondary:hover {
background: var(--surface-container-high);
color: var(--on-surface);
}
/* ── System Info ── */
.projects-page__sys-info {
display: grid;
grid-template-columns: 1fr 1fr;
gap: 0.75rem;
margin-top: 1.5rem;
position: relative;
}
.projects-page__sys-item {
display: flex;
align-items: center;
gap: 0.75rem;
padding: 0.75rem;
background: rgba(18, 19, 22, 0.5);
border-radius: var(--radius-lg);
border: 1px solid rgba(71, 72, 74, 0.05);
}
.projects-page__sys-icon {
display: flex;
align-items: center;
justify-content: center;
width: 32px;
height: 32px;
border-radius: var(--radius-lg);
flex-shrink: 0;
}
.projects-page__sys-icon--secondary {
background: rgba(172, 137, 255, 0.1);
color: var(--secondary);
}
.projects-page__sys-icon--tertiary {
background: rgba(220, 255, 178, 0.1);
color: var(--tertiary);
}
.projects-page__sys-label {
display: block;
font-size: 0.55rem;
text-transform: uppercase;
letter-spacing: 0.05em;
color: var(--on-surface-variant);
}
.projects-page__sys-value {
display: block;
font-size: 0.75rem;
font-weight: 500;
color: var(--on-surface);
}

233
src/pages/ProjectsPage.jsx Normal file
View file

@ -0,0 +1,233 @@
import { useState } from 'react'
import { useNavigate } from 'react-router-dom'
import { useProjects } from '../context/ProjectContext'
import Header from '../components/Header'
import Footer from '../components/Footer'
import './ProjectsPage.css'
const PRESETS = [
'Photorealistic ArchViz',
'Stylized Game Asset',
'Rapid Concept Sculpt',
'Raw Voxel Mesh',
]
const STATUS_MAP = {
active: { label: 'Active', className: 'project-card__status--active' },
processing: { label: 'Processing', className: 'project-card__status--processing' },
complete: { label: 'Complete', className: 'project-card__status--complete' },
}
export default function ProjectsPage() {
const { projects, createProject, deleteProject } = useProjects()
const navigate = useNavigate()
const [showCreate, setShowCreate] = useState(false)
const [formData, setFormData] = useState({
name: '',
description: '',
preset: PRESETS[0],
})
const handleCreate = (e) => {
e.preventDefault()
if (!formData.name.trim()) return
const created = createProject(formData)
setFormData({ name: '', description: '', preset: PRESETS[0] })
setShowCreate(false)
navigate(`/projects/${created.id}`)
}
const formatDate = (isoStr) => {
const d = new Date(isoStr)
return d.toLocaleDateString('en-US', { month: 'short', day: 'numeric', year: 'numeric' })
}
return (
<div className="projects-layout">
<Header showSearch showCreateNew />
<main className="projects-page">
{/* Hero / Create Modal */}
{showCreate && (
<div className="projects-page__modal-overlay" onClick={() => setShowCreate(false)}>
<div className="projects-page__modal" onClick={(e) => e.stopPropagation()}>
{/* Glow */}
<div className="projects-page__modal-glow" />
<div className="projects-page__modal-header">
<h1 className="projects-page__modal-title font-headline">Create New Project</h1>
<p className="projects-page__modal-desc">Initialize a new 3D workspace and generation pipeline.</p>
</div>
<form className="projects-page__form" onSubmit={handleCreate} id="create-project-form">
<div className="projects-page__field">
<label className="projects-page__label font-label" htmlFor="project-name">Project Name</label>
<div className="projects-page__input-wrap">
<input
id="project-name"
type="text"
className="projects-page__input"
placeholder="e.g. Cyberpunk_District_V1"
value={formData.name}
onChange={(e) => setFormData({ ...formData, name: e.target.value })}
autoFocus
/>
<div className="projects-page__input-underline" />
</div>
</div>
<div className="projects-page__field">
<label className="projects-page__label font-label" htmlFor="project-desc">Description</label>
<textarea
id="project-desc"
className="projects-page__textarea"
placeholder="Define the creative scope..."
rows="3"
value={formData.description}
onChange={(e) => setFormData({ ...formData, description: e.target.value })}
/>
</div>
<div className="projects-page__field">
<label className="projects-page__label font-label" htmlFor="project-preset">Select Preset</label>
<div className="projects-page__select-wrap">
<select
id="project-preset"
className="projects-page__select"
value={formData.preset}
onChange={(e) => setFormData({ ...formData, preset: e.target.value })}
>
{PRESETS.map(p => <option key={p} value={p}>{p}</option>)}
</select>
<span className="material-symbols-outlined projects-page__select-icon">expand_more</span>
</div>
</div>
<div className="projects-page__form-actions">
<button type="submit" className="projects-page__btn-primary" id="submit-create-project">
<span className="material-symbols-outlined" style={{ fontSize: '18px' }}>add_circle</span>
Create Project
</button>
<button
type="button"
className="projects-page__btn-secondary"
onClick={() => setShowCreate(false)}
>
Cancel
</button>
</div>
</form>
{/* System Info */}
<div className="projects-page__sys-info">
<div className="projects-page__sys-item">
<div className="projects-page__sys-icon projects-page__sys-icon--secondary">
<span className="material-symbols-outlined filled" style={{ fontSize: '16px' }}>deployed_code</span>
</div>
<div>
<span className="projects-page__sys-label font-label">Engine</span>
<span className="projects-page__sys-value">Synthesis V4.2</span>
</div>
</div>
<div className="projects-page__sys-item">
<div className="projects-page__sys-icon projects-page__sys-icon--tertiary">
<span className="material-symbols-outlined filled" style={{ fontSize: '16px' }}>memory</span>
</div>
<div>
<span className="projects-page__sys-label font-label">Allocated GPU</span>
<span className="projects-page__sys-value">24GB VRAM</span>
</div>
</div>
</div>
</div>
</div>
)}
{/* Projects Grid */}
<div className="projects-page__container">
<div className="projects-page__header">
<div>
<h1 className="projects-page__page-title font-headline">Your Projects</h1>
<p className="projects-page__page-desc">{projects.length} workspace{projects.length !== 1 ? 's' : ''} available</p>
</div>
<button className="projects-page__new-btn" onClick={() => setShowCreate(true)} id="open-create-modal">
<span className="material-symbols-outlined" style={{ fontSize: '18px' }}>add</span>
New Project
</button>
</div>
<div className="projects-page__grid">
{projects.map((project, i) => (
<div
key={project.id}
className="project-card"
style={{ animationDelay: `${i * 0.08}s` }}
onClick={() => navigate(`/projects/${project.id}`)}
id={`project-card-${project.id}`}
>
{/* Thumbnail area */}
<div className="project-card__thumb">
<div className="project-card__thumb-inner">
<span className="material-symbols-outlined" style={{ fontSize: '40px', color: 'rgba(143, 245, 255, 0.15)' }}>
view_in_ar
</span>
</div>
<div className={`project-card__status ${STATUS_MAP[project.status]?.className || ''}`}>
{STATUS_MAP[project.status]?.label || project.status}
</div>
</div>
{/* Info */}
<div className="project-card__info">
<h3 className="project-card__name font-headline">{project.name}</h3>
<p className="project-card__desc">{project.description}</p>
<div className="project-card__meta">
<div className="project-card__meta-item">
<span className="material-symbols-outlined" style={{ fontSize: '14px' }}>image</span>
<span>{project.imageCount} images</span>
</div>
<div className="project-card__meta-item">
<span className="material-symbols-outlined" style={{ fontSize: '14px' }}>deployed_code</span>
<span>{project.meshCount} meshes</span>
</div>
</div>
<div className="project-card__footer">
<span className="project-card__preset font-label">{project.preset}</span>
<span className="project-card__date">{formatDate(project.createdAt)}</span>
</div>
</div>
{/* Delete button */}
<button
className="project-card__delete"
onClick={(e) => { e.stopPropagation(); deleteProject(project.id) }}
title="Delete project"
>
<span className="material-symbols-outlined" style={{ fontSize: '16px' }}>delete</span>
</button>
</div>
))}
{/* Empty state */}
{projects.length === 0 && (
<div className="projects-page__empty">
<span className="material-symbols-outlined" style={{ fontSize: '48px', color: 'var(--outline-variant)' }}>
folder_off
</span>
<p>No projects yet. Create your first workspace.</p>
<button className="projects-page__new-btn" onClick={() => setShowCreate(true)}>
<span className="material-symbols-outlined" style={{ fontSize: '18px' }}>add</span>
Create Project
</button>
</div>
)}
</div>
</div>
</main>
<Footer />
</div>
)
}

7
vite.config.js Normal file
View file

@ -0,0 +1,7 @@
import { defineConfig } from 'vite'
import react from '@vitejs/plugin-react'
// https://vite.dev/config/
export default defineConfig({
plugins: [react()],
})