Files
denshooter 9e6ae866d0
CI / CD / test-build (push) Successful in 11m13s
CI / CD / deploy-dev (push) Successful in 2m25s
CI / CD / deploy-production (push) Has been skipped
feat: plakat redesign phase 4 (chat window, contact, footer, cleanup) (#77)
- AI chat moves into a window/sheet, opened from a new speech-bubble card on
  the desk; it now respects the chatbot consent and asks before sending
  anything to n8n (previously it ignored the consent)
- Contact as red poster section with big mail address and the form on a paper
  card; validation errors are finally shown inline (aria-invalid, role=alert)
- Footer as ink strip with dk0 wordmark, legal links and a button to reopen
  the privacy settings
- "About me" in the header opens the about window on the home page
- Remove the old About section and its parts (BentoChat, ActivityFeed,
  CurrentlyReading, ReadBooks), the unused ChatWidget, Projects and BentoGrid,
  their tests, wrappers, loaders, types and texts
- scripts/directus-cleanup-redesign.mjs: dry run by default, --apply archives
  hobbies, tech stack categories and old content pages and deletes four
  unused message overrides after a full JSON backup; run only after the
  redesign is live on production

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-15 23:49:56 +02:00

42 lines
1.1 KiB
TypeScript

import type { WindowRequest } from "../fenster/types";
import type { TischLabels, TischObject } from "./types";
/** Welches Fenster ein Objekt auf dem Tisch öffnet */
export function windowFor(obj: TischObject): WindowRequest {
switch (obj.kind) {
case "project":
return { kind: "project", project: obj };
case "ticket":
return { kind: "now" };
case "server":
case "sticker":
return { kind: "server" };
case "book":
return { kind: "read" };
case "photo":
return { kind: "about" };
case "chat":
return { kind: "chat" };
}
}
/** Vorlesetext für das Objekt als Knopf */
export function labelFor(obj: TischObject, labels: TischLabels): string {
switch (obj.kind) {
case "project":
return obj.title;
case "ticket":
return labels.ticketTitle;
case "server":
return labels.serverTitle;
case "book":
return labels.bookLabel;
case "photo":
return labels.photoCaption;
case "chat":
return labels.chatCard;
case "sticker":
return labels.sticker;
}
}