From fce954b096eda1f8ed93dcfb7eb3fb543f00f235 Mon Sep 17 00:00:00 2001 From: "Dennis (via Claude+Gemma)" Date: Sat, 23 May 2026 08:35:42 +0200 Subject: [PATCH] feat(workspace-switcher-stub): Workspace-Switcher-Dropdown (Stub mit single workspace) [tsc:fail] --- .phase24-state.json | 7 ++- GENERATION_LOG.md | 17 +++++ apps/web/src/components/WorkspaceSwitcher.tsx | 63 +++++++++++++++++++ 3 files changed, 85 insertions(+), 2 deletions(-) create mode 100644 apps/web/src/components/WorkspaceSwitcher.tsx diff --git a/.phase24-state.json b/.phase24-state.json index d461f45..335f79f 100644 --- a/.phase24-state.json +++ b/.phase24-state.json @@ -1,5 +1,8 @@ { "completed_features": [], - "current_feature": "notification-bell", - "started_at": "2026-05-23T08:33:42.059540" + "current_feature": "workspace-switcher-stub", + "started_at": "2026-05-23T08:33:42.059540", + "attempted_features": [ + "notification-bell" + ] } \ No newline at end of file diff --git a/GENERATION_LOG.md b/GENERATION_LOG.md index 39d154e..cc51c1b 100644 --- a/GENERATION_LOG.md +++ b/GENERATION_LOG.md @@ -2804,3 +2804,20 @@ src/index.ts(27,25): error TS2769: No overload matches this call. Overload 2 of 3, '(plugin: FastifyPluginAsync<{ limits: { fileSize: number; }; }, RawServerDefault, FastifyTypeProvider, FastifyBaseLogger>, opts?: FastifyRegisterOptions<...> | undefined): FastifyInstance<...> & PromiseLike<...>', gave the following error. Argument of type 'Promise' is not assignable to parameter of type 'FastifyPluginAsync<{ limits: { fileSize: number; }; }, RawServerDefault, FastifyTypeProvider, FastifyBaseLogger>'. Type 'Promise' provides no match for the signature '(instance: FastifyInstance, FastifyBaseLogger, FastifyTy +- `08:35:21` **INFO** Committed feature notification-bell +- `08:35:21` **INFO** Pushed: rc=0 + +## Phase-3 Feature: workspace-switcher-stub (2026-05-23 08:35:21) + +- `08:35:21` **INFO** Description: Workspace-Switcher-Dropdown (Stub mit single workspace) +- `08:35:21` **INFO** Generating apps/web/src/components/WorkspaceSwitcher.tsx (WorkspaceSwitcher-Dropdown. Zeigt aktuellen workspace.name (aus api.ge…) +- `08:35:40` **INFO** wrote 2387 chars in 19.3s (attempt 1) +- `08:35:40` **INFO** Running tsc --noEmit on api… +- `08:35:42` **WARN** tsc errors: +src/index.ts(27,25): error TS2769: No overload matches this call. + Overload 1 of 3, '(plugin: FastifyPluginCallback<{ limits: { fileSize: number; }; }, RawServerDefault, FastifyTypeProvider, FastifyBaseLogger>, opts?: FastifyRegisterOptions<...> | undefined): FastifyInstance<...> & PromiseLike<...>', gave the following error. + Argument of type 'Promise' is not assignable to parameter of type 'FastifyPluginCallback<{ limits: { fileSize: number; }; }, RawServerDefault, FastifyTypeProvider, FastifyBaseLogger>'. + Type 'Promise' provides no match for the signature '(instance: FastifyInstance, FastifyBaseLogger, FastifyTypeProvider>, opts: { ...; }, done: (err?: Error | undefined) => void): void'. + Overload 2 of 3, '(plugin: FastifyPluginAsync<{ limits: { fileSize: number; }; }, RawServerDefault, FastifyTypeProvider, FastifyBaseLogger>, opts?: FastifyRegisterOptions<...> | undefined): FastifyInstance<...> & PromiseLike<...>', gave the following error. + Argument of type 'Promise' is not assignable to parameter of type 'FastifyPluginAsync<{ limits: { fileSize: number; }; }, RawServerDefault, FastifyTypeProvider, FastifyBaseLogger>'. + Type 'Promise' provides no match for the signature '(instance: FastifyInstance, FastifyBaseLogger, FastifyTy diff --git a/apps/web/src/components/WorkspaceSwitcher.tsx b/apps/web/src/components/WorkspaceSwitcher.tsx new file mode 100644 index 0000000..eee9f25 --- /dev/null +++ b/apps/web/src/components/WorkspaceSwitcher.tsx @@ -0,0 +1,63 @@ +import React, { useState } from 'react'; +import { useQuery } from '@tanstack/react-query'; +import { ChevronDown } from 'lucide-react'; +import { toast } from 'sonner'; +import { api } from '@emberclone/shared/api'; +import type { Workspace } from '@emberclone/shared/types'; + +export default function WorkspaceSwitcher() { + const [isOpen, setIsOpen] = useState(false); + + const { data: settings, isLoading } = useQuery({ + queryKey: ['settings'], + queryFn: () => api.getSettings(), + }); + + const currentWorkspace = settings?.workspace; + + return ( +
+ + + {isOpen && ( + <> +
setIsOpen(false)} + /> +
+
+ + +
+ + +
+
+ + )} +
+ ); +} \ No newline at end of file