65 Commits
Author SHA1 Message Date
CatoandClaude Opus 5.5 9dde8fbee9 feat(forms): prose fields on chatkit DictationField, with a working microphone (#330)
* wip: prose fields on chatkit DictationField (awaits chatkit 0.45)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmuMRAXYWNkfowAXVfi

* feat(forms): prose fields on chatkit DictationField, with a working microphone

- Bump @bitbaum/chatkit to ^0.45.0.
- One app wrapper, components/forms/TextBox, around DictationField. Used by
  the bot builder (name, description, knowledge topic and content, system
  prompt), the custom-bot edit page (name, description, system prompt,
  greeting), the contact message, the demo intake questions, quick-create
  (name, relationship, memories) and the consultation form's
  react-hook-form message field ({...register('message')}).
- app/api/transcribe: dictation server leg on ai-kit's speechChain and
  transcribe(), rate limited, recordings and transcripts neither stored nor
  logged. Every field and every in-page chat points voice at it, so the
  microphone works where the browser has no recogniser of its own.
- Permissions-Policy allowed no microphone at all (microphone=()), which
  blocked every mic on the site; it now allows the site itself.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmuMRAXYWNkfowAXVfi

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-19 14:23:42 +01:00
CatoandClaude 9d5c25a26f feat(chat): run every in-page chat on chatkit's thread and composer (#328)
Seven hand-built chats (/demo, the professional demos, quick-create, /try,
/my-data documents, custom bots and the guided demo) now share one
EmbeddedChat panel: chatkit's ChatThread and Composer with the microphone,
Copy/Listen, Stop, Retry on a failed turn, starters and suggested replies.
Each surface keeps its own prompt, route and persistence through a small
useChatTurns hook.

Also fixes /demo and the /my-data document chat reading the answer from the
wrong level of the jsonSuccess envelope, which showed empty answers.


Claude-Session: https://claude.ai/code/session_019MDtmuMRAXYWNkfowAXVfi

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-15 18:48:44 +01:00
8582b92f90 refactor(deps): Tailwind 4 (CSS-first) + Zod 4 + ESLint 10 + types/node 26 + ai-kit 0.6.2 (#168)
Tailwind 3.4 -> 4.3:
- tailwind.config.js DELETED; tokens now live in an @theme inline block in
  app/globals.css (semantic names unchanged: action, paper, edge, ink...)
- postcss.config.js -> @tailwindcss/postcss; autoprefixer dropped (built in)
- @tailwind directives -> @import 'tailwindcss'; forms/typography via @plugin
- daisyui removed (no daisyui class used anywhere)
- next/font vars renamed --font-inter/--font-fraunces to break the circular
  var() the old --font-sans binding would create inside @theme
- v4 deleted *-opacity-* utilities: every bg/text/ring-opacity-N rewritten to
  slash syntax (bg-action/90, ring-black/5, ...); dynamic accent tint gets a
  literal class map in lib/config/colors.ts so the scanner sees each class
- dead v3-era aspect-w/h custom utilities removed (unused; v4 has aspect-*)

Zod 3.24 -> 4.5:
- .errors -> .issues everywhere
- z.string().uuid( -> .guid( (v4 uuid() is RFC-variant-strict; DB ids aren't)
- z.record(z.unknown()) -> z.record(z.string(), z.unknown())
- object .default({}) -> .prefault({}) (v4 default takes the full output value)

ESLint 9 -> 10: eslint-plugin-react's version:'detect' calls the removed
context.getFilename; pin settings.react.version='19' AFTER the next configs.

Verify (format+lint+typecheck+selfhost+test+build) green: 272 tests pass.


Claude-Session: https://claude.ai/code/session_01WqKqMnHQHSmkGFfc5t7Rxn

Co-authored-by: Mao Nakamoto <41178744+maonakamoto@users.noreply.github.com>
Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
2026-08-31 12:45:49 +00:00
346a3ff744 refactor(design): the bot demo was the sixth colour system (#150)
#144 branded the bot page sections. It did not reach the demo underneath
them, so every first-party bot still ran the per-colour palette in its
interactive step -- the buttons, focus rings, progress dots, message bubbles,
dropzone and context panel -- plus the bot switcher in the nav.

The colour came from lib/demo/botDemoConfigs.ts, which carried its own
accentColor per bot (blue, green, red, indigo, amber). That is the sixth
place a colour was chosen, after: globals.css, lib/config/colors.ts,
lib/hooks/navigationConfig.ts, ACCENT_HERO_CLASSES, and data/professionals.ts.

DemoSection and BotSwitcher are used ONLY by the first-party bot pages
(verified: no custom-bot page imports either), so both are now brand:
BRAND_BUTTON, BRAND_FOCUS_RING, BRAND_STARTER, BRAND_CHECKBOX, BRAND_PROGRESS,
BRAND_MESSAGE, BRAND_DROPZONE, BRAND_CONTEXT_PANEL, BRAND_SWITCHER.

accentColor is gone from the demo config, its type, and the whole prop chain.

What still emits raw palette, correctly:
  VISION_STATUS_CONFIG   roadmap status -- completed green, in-progress blue,
                         planned amber, vision purple. Four states that have to
                         stay tellable apart; collapsing them to ochre would
                         destroy the information.
  the /personal templates per-template identity in the memorial/legends
                         product, chosen from an allowlisted surface.

Both live behind lib/config/colors.ts, which the guard already documents as an
exception -- so the guard passing while those classes ship is correct, not a
blind spot. The blind spot was data/professionals.ts, fixed in #149.

verify: format, lint, typecheck, 256 tests, build -- all green. Bot demo
confirmed ochre end to end against a local production build.


Claude-Session: https://claude.ai/code/session_01HVwg8DKHQktxJuHeLM3xpG

Co-authored-by: Mao Nakamoto <41178744+maonakamoto@users.noreply.github.com>
Co-authored-by: Claude Opus 5 <noreply@anthropic.com>
2026-08-28 10:21:48 +00:00
f04d13bf39 refactor(design): finish the colour sweep, and make it enforceable (#148)
#144 put the bot pages on the brand. This does the other 60 files, so the
whole product reads as one thing, and adds the guard that keeps it that way.

~410 raw palette classes became semantic tokens across the public marketing
surface (/try, /enterprise, /about, /knowledge, /personal, /professionals,
/bots, blog, navigation) and the app internals (dashboard, documents, chat,
conversations, onboarding, auth, settings, profile).

Gradient text is gone. Fifteen headings were
`bg-gradient-to-r from-X to-Y bg-clip-text text-transparent`; they are now
solid text-ink or text-action. globals.css says the identity is carried by
typography, and a serif display does not need a gradient to do that.

The 'B' mark was still a blue/purple gradient in BotNavigation's MOBILE menu.
#144 only fixed the desktop header. Both now render the shared <Logo>.

Three defects introduced mid-sweep and corrected, all caught by reading the
diff rather than trusting the regex:
  - degenerate gradients (`from-action-tint to-action-tint`) collapsed to solid
  - dead hovers (tint on tint) rebased to bg-surface + hover:bg-action-tint
  - `to-action\b` matched the prefix of `to-action-hover`, so a collapse left a
    stray `bg-action-hover` as a BASE background in 11 places -- those are the
    primary, not the hover shade

Deliberately NOT changed:
  - components/knowledge/Callout.tsx -- its blue is the `info` half of an
    info/warning/error triad. Semantic status colour is a separate scale from
    the brand accent, and warning is amber, so ochre-ing info would make the
    two nearly indistinguishable.
  - the custom-bot surfaces -- custom_bots.accent_color is a real column with
    a CHECK constraint and the owner picks it. User data, not a design token.

Never-twice: tests/__tests__/lib/design-tokens.test.ts refuses any raw
brand-palette class, and any bg-clip-text, outside those two documented
exceptions. Mutation-verified -- swap one token back to bg-blue-600 and it
fails and names the file. No allowlist debt: every other file was swept rather
than excused.

verify: format, lint, typecheck, 256 tests, build -- all green. Twelve pages
smoke-tested and checked visually against a local production build.


Claude-Session: https://claude.ai/code/session_01HVwg8DKHQktxJuHeLM3xpG

Co-authored-by: Mao Nakamoto <41178744+maonakamoto@users.noreply.github.com>
Co-authored-by: Claude Opus 5 <noreply@anthropic.com>
2026-08-28 09:53:41 +00:00
bb9d9490d0 refactor(design): one colour system on the bot pages (#144)
app/globals.css defines the identity -- editorial ink, one ochre accent --
and says so in a comment: "No generic AI gradient blue/purple." The bot
pages ignored it and ran a parallel palette, so a single viewport of
/bots/legal-expert showed a blue logo, a blue nav button and an ochre CTA
at the same time.

There were four colour sources, not two:
  lib/config/colors.ts        16-colour accent sets
  lib/hooks/navigationConfig  its own 5-colour NAV_COLOR_CLASSES
  ACCENT_HERO_CLASSES         a fifth set (whose green and indigo entries
                              both set chatBg to 'bg-blue-50' -- it was not
                              even self-consistent)
  raw Tailwind greys          text-gray-900 / bg-white / border-gray-200

The six professional bots are Botsmann, so they now wear the brand:
BRAND_ACCENT and BRAND_HERO, plus a single NAV_COLORS scheme. 113 raw
grey/white classes became semantic tokens (text-ink, text-ink-muted,
bg-surface, bg-paper, border-edge). The page ground is bg-paper, matching
the homepage instead of flat white.

The 'B' mark in BotNavigation was literally
`bg-gradient-to-r from-blue-600 to-purple-600` -- the exact thing globals.css
forbids by name. It now renders the shared <Logo>, so it cannot drift again.

Per-bot accentColor is gone from the first-party config and its plumbing.
The per-colour sets STAY for user-created bots: custom_bots.accent_color is
a real column with a CHECK constraint and the owner picks it. That is user
data, not a design token.

Also deleted components/shared/BotPageTemplate.tsx -- nothing imported it.

Not in this change: /try, /enterprise, /bots and /knowledge still carry
blue/purple gradients (72 files match the raw palette). Same class, separate
pass, so this one stays reviewable.

verify: format, lint, typecheck, 240 tests, build -- all green. Verified
visually against a local production build.


Claude-Session: https://claude.ai/code/session_01HVwg8DKHQktxJuHeLM3xpG

Co-authored-by: Mao Nakamoto <41178744+maonakamoto@users.noreply.github.com>
Co-authored-by: Claude Opus 5 <noreply@anthropic.com>
2026-08-28 08:16:47 +00:00
g-butandClaude Opus 4.5 ea7baec755 refactor(bots): make bots.ts SSOT for footer, menu, and bots page
Reduces files needed to add a new bot from 7-8 to 3-4 by eliminating
hardcoded bot lists in multiple locations:

- Add `display` field to Bot interface for bots list page metadata
- Footer.tsx: Generate AI Assistants links from bots array
- app/bots/page.tsx: Remove 100-line botDetails Record, derive from bot.display
- menuItems.ts: Generate Professionals menu children from bots array

Adding a new bot now automatically updates the footer, navigation menu,
and bots list page without any additional code changes.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-28 21:08:04 +01:00
g-butandClaude Opus 4.5 4600019eb3 refactor(bots): config-driven bot pages architecture
Replace individual static bot pages with a single dynamic [slug]/page.tsx
that renders from centralized configuration. This makes adding new bots
a matter of editing config files only - no new page files needed.

Architecture changes:
- Add lib/config/bot-pages.ts as SSOT for all bot page content
- Add components/shared/sections/ with generic section components
- Add app/bots/[slug]/page.tsx as single dynamic page
- Remove 100+ files from individual bot directories

New section components:
- DisclaimerSection, FeaturesSection, HowItWorksSection
- BenefitsSection, TestimonialsSection, VisionSection
- TechnologySection, CTASection, DemoSectionWrapper

To add a new bot now:
1. Add entry to lib/config/bot-pages.ts (sections + content)
2. Add hero config to data/botHeroConfigs.ts
3. Add demo config to lib/demo/botDemoConfigs.ts
4. Add basic info to data/bots.ts
Done - no new page.tsx files needed!

Files deleted: ~100+ (bot-specific pages/components)
Files added: 11 (config + generic sections)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-28 18:57:33 +01:00
g-butandClaude Opus 4.5 ea710cbe6b chore: cleanup orphaned bot files, restore needed utils
Removed orphaned files:
- app/bots/medical-expert/types/index.ts (92 lines, never imported)
- app/bots/product-manager/metadata.ts (18 lines, never used)

Restored utils needed by swiss-german-teacher components:
- utils/constants.ts (used by EmailGenerator, TextGenerator, SwissContentSection)
- utils/navigation.ts (used by EmailGenerator)

Note: Previous commit incorrectly removed these as orphaned.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-28 17:05:21 +01:00
g-butandClaude Opus 4.5 a69152ae5c chore: remove orphaned swiss-german-teacher support files
Removed dead code that was never imported:
- hooks/useDemoMode.ts (101 lines)
- data/conversation.ts (28 lines)
- types/index.ts (44 lines)
- utils/constants.ts (34 lines)
- utils/navigation.ts (22 lines)
- utils/validation.ts (8 lines)

Total: 237 lines removed

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-28 16:53:21 +01:00
g-butandClaude Opus 4.5 a445cb848f chore: remove orphaned styles and empty folders
- Remove swiss-german-teacher/styles/ (CSS file not imported anywhere)
- Remove empty lib/models/ directory

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-28 16:05:56 +01:00
g-butandClaude Opus 4.5 db5cde7ff6 chore: remove empty/orphaned files
- Remove empty stub files (mdx-provider.tsx, events.ts, route.d.ts)
- Remove orphaned components/auth/ folder (EmailVerificationBanner never imported)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-28 15:58:49 +01:00
g-butandClaude Opus 4.5 37f193b226 chore: remove orphaned bot navigation components
- Remove swiss-german-teacher/components/shared/ (unused DemoModeOverlay, DemoPopup, Navigation)
- Remove swiss-german-teacher/components/navigation/ (unused Navigation)
- Remove medical-expert/components/navigation/ (unused Navigation)
- Remove product-manager/components/navigation/ (unused Navigation)
- Remove research-assistant/components/navigation/ (unused Navigation)
- Fix test to use valid ErrorCode type

All bots now use BotPageTemplate's shared navigation.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-28 14:57:32 +01:00
g-butandClaude Opus 4.5 425b3880be refactor: consolidate formatFileSize duplicates to shared formatBytes
- Update app/documents/page.tsx to use formatBytes from lib/format
- Update app/my-data/page.tsx to use formatBytes from lib/format
- Update components/shared/demo/DemoFileUpload.tsx to use formatBytes
- Update workspaceUtils.ts to re-export formatBytes as formatFileSize

DRY: 4 duplicate formatFileSize implementations → 1 SSOT (lib/format.ts)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-28 11:37:25 +01:00
g-butandClaude Opus 4.5 d46568bd90 chore: remove unused duplicate components
- Delete example-section/ folder (duplicate of parent components)
- Delete unused ClientErrorBoundary wrapper component

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-28 09:13:45 +01:00
g-butandClaude Opus 4.5 d10360c231 refactor: code quality improvements (DRY, SSOT, inline styles)
- Remove duplicate MAX_FILE_SIZE constant, use VALIDATION.MAX_FILE_SIZE (SSOT)
- Refactor CustomBotPage sendMessage logic to eliminate code duplication (DRY)
- Convert inline animation-delay styles to Tailwind arbitrary values
- Add development-only check to ErrorBoundary console.error
- Remove deprecated MAX_FILE_SIZE export from types/document.ts

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-28 01:06:06 +01:00
g-butandClaude Opus 4.5 7d9621c624 refactor(legal-expert): remove duplicate workspace components
- Remove unused workspace-dashboard/ folder (duplicate of workspace/)
- Remove unused ClientPortalProps and LawyerPortalProps from types.ts

DRY cleanup: workspace/ folder is the active one used by
WorkspaceDashboard.tsx and DemoSection.tsx

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-28 00:58:20 +01:00
g-butandClaude Opus 4.5 6c25dc8dfe refactor: comprehensive code quality improvements (DRY, SSOT, SoC)
## Broken Links Fixed
- Fix /projects/governance/build link to /contact in HeroSection.tsx

## Console Statements Removed (production code)
- Remove console.log/error from client components
- Replace with silent error handling or UI feedback
- Files: documents/page.tsx, try/page.tsx, settings/page.tsx,
  ConversationList.tsx, ProfessionalDemo.tsx, and more

## Inline Styles Converted to Tailwind
- Replace animation-delay inline styles with Tailwind arbitrary values
- Files: DemoMessage.tsx, DemoChat.tsx, ProfessionalDemo.tsx,
  QuickChat.tsx, demo/page.tsx, HeroSection.tsx

## Governance Types Consolidated (SSOT)
- Create app/projects/governance/types.ts as single source of truth
- Create app/projects/governance/utils.ts for formatting functions
- Remove duplicate EnhancedTransaction from TransactionWithTraceability.tsx
- Update component type files to re-export from SSOT

## Colors Config Extended
- Extend COLOR_CLASSES to support all 16 accent colors
- Fix type mismatch in custom bot pages

## Magic Numbers Extracted
- Add formatBytes utility to lib/format.ts (DRY)
- Add DEMO_MAX_FILE_SIZE to VALIDATION constants
- Update try/page.tsx to use centralized constants

## Minor Fixes
- Fix unused variable warning in CollaborationForm.tsx

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-28 00:24:27 +01:00
g-butandClaude Opus 4.5 86aa6bc4d7 refactor: consolidate color constants to lib/config/colors.ts (SSOT)
- Extended colors.ts with ACCENT_COLOR_OPTIONS and COLOR_CLASSES
- Updated colors from purple/orange/yellow to indigo/amber to match usage
- Added composite color classes for themed UI components
- Removed duplicated color definitions from:
  - app/bots/custom/[slug]/page.tsx
  - app/bots/custom/[slug]/edit/page.tsx
  - components/bot-builder/StepPersonality.tsx
  - components/bot-builder/StepReview.tsx

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-23 18:38:10 +01:00
g-butandClaude Opus 4.5 99b1bed9c2 refactor: migrate remaining files to shared LoadingSpinner
Replace inline loading spinners with PageLoading, InlineLoading, and
LoadingSpinner components across 10 more files:

- app/dashboard/page.tsx
- app/documents/page.tsx
- app/bots/mine/page.tsx
- app/bots/custom/[slug]/page.tsx
- app/bots/custom/[slug]/edit/page.tsx
- app/infrastructure/page.tsx
- app/my-data/page.tsx
- app/auth/callback/page.tsx
- components/conversations/ConversationList.tsx
- components/documents/AddToBotModal.tsx

This completes the DRY refactoring for loading spinners. The
LoadingSpinner component is now the SSOT for all loading states.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-23 17:13:30 +01:00
g-butandClaude Opus 4.5 a75b27bf5c fix: resolve lint warnings and build errors
- Remove unused @ts-expect-error directive in jest.setup.ts
- Fix useCallback dependency in custom bot page (remove unused 'messages')
- Fix useEffect/useCallback pattern in ConversationList

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-23 15:22:37 +01:00
g-butandClaude Opus 4.5 1c7abeebac docs(claude): add global standards reference and update date
- Add @~/.claude/CLAUDE.md import for global engineering standards
- Update Last Updated date to 2026-01-23

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-23 15:22:36 +01:00
g-butandClaude Opus 4.5 b09e776a89 chore: Remove swiss-german-teacher waitlist and update nav
- Remove WaitlistForm component and useWaitlistForm hook
- Remove waitlist types from types/index.ts
- Update buttons to link to demo section instead of removed waitlist
- Update nav menu items to match actual page sections

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-23 11:46:27 +01:00
g-butandClaude Opus 4.5 0c2b798cb8 refactor: modularize large components and centralize email config
Component splits (all >400 lines to modular directories):
- AICaseAnalysis.tsx → ai-case-analysis/ (utils, states, report)
- DemoSection.tsx → demo-section/ (steps, navigation, progress)
- WorkspaceDashboard.tsx → workspace-dashboard/ (sections, UI)
- ExampleSection.tsx → example-section/ (tabs for different views)
- AgencyProfile.tsx → agency-profile/ (tabs for overview, etc)
- CitizenProfile.tsx → citizen-profile/ (sections, tabs)
- TransactionWithTraceability.tsx → transaction-traceability/

Email configuration:
- Created lib/config/email.ts with centralized settings
- Replaced hardcoded emails with environment variables
- Added EmailServiceError class for proper error handling
- Updated templates to use centralized config

Added Zod validation schemas for API input validation

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-23 08:39:31 +01:00
g-butandClaude Opus 4.5 1f66587422 refactor: create shared BotHeroSection component (DRY principle)
- Create reusable BotHeroSection, BotFeatureCard, BotStepsSection components
- Add centralized botHeroConfigs.ts for hero section data (SSOT)
- Update all 5 bot pages to use shared BotHeroSection
- Delete duplicated HeroSection files from individual bot directories

This eliminates ~650 lines of duplicated code across bot pages while
maintaining flexibility through configuration-driven rendering.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-21 00:28:58 +01:00
g-butandClaude Opus 4.5 e1e2a54227 fix(medical-expert): remove unverified GPT link from navigation
- Replace external GPT link with scroll to "Vision & Join" section
- Change button text from "Chat Now" to "Join Waitlist"
- Remove unused Link import

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-19 23:15:40 +01:00
g-butandClaude Opus 4.5 07ff182efd fix(research-assistant): remove broken GPT links
- Replace invalid chatgpt.com/g/research-assistant URLs
- Navigation "Join Waitlist" now scrolls to roadmap section
- Custom field button now scrolls to roadmap instead of broken link
- Remove unused Link import

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-19 22:36:03 +01:00
g-butandClaude Sonnet 4.5 9aa417e273 refactor: clean up API routes and components, add shared utilities
Refactored multiple API routes and components to improve code organization and reduce duplication:
- Simplified API route implementations across chat, documents, consultations, and other endpoints
- Reorganized navigation components for better maintainability
- Added shared utility functions and hooks
- Created reusable Avatar and Logo components
- Added validation schemas and API utilities
- Improved type definitions and constants management

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-01-16 11:04:19 +01:00
g-butandClaude Opus 4.5 ddec243147 feat: add Swiss German RAG demo with keyword-based search
- Add RAG search module with TF-IDF-like scoring (lib/rag/)
- Create Swiss German knowledge base with 10+ chunks
- Build demo chat UI with suggested questions and source citations
- Add /api/demo/chat endpoint with Zod validation
- Update homepage with "Try the Demo" CTA and honest messaging
- Add /api/contact endpoint for consultation form
- Fix ConsultationForm to use real API endpoint
- Update bot cards to show accurate live/coming-soon status
- Remove legacy api/consultations.js (caused Vercel conflicts)
- Add nodemailer dependency for email functionality

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-14 08:38:43 +01:00
g-butandClaude Opus 4.5 59a6c9de3c refactor: consolidate CSS scroll-behavior and remove duplicates
- Add scroll-behavior: smooth to globals.css with reduced-motion support
- Remove duplicate scroll-behavior from medical-expert/styles.css
- Remove duplicate scroll-behavior from legal-expert/styles.css
- Remove duplicate @keyframes fadeIn from legal-expert/styles.css

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-13 21:56:18 +01:00
g-butandClaude Opus 4.5 5951943cfe refactor: deduplicate validation and formatting utilities
- Create lib/validation.ts with shared email validation, text helpers
- Create lib/format.ts with currency, number, date, percent formatters
- Refactor api/waitlist/route.ts to use shared isValidEmail
- Update swiss-german-teacher validation to re-export from shared lib
- Update governance utils to re-export formatCurrency from shared lib
- Remove duplicate formatCurrency from 4 governance components

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-13 21:32:22 +01:00
g-butandClaude Opus 4.5 dac7217e90 refactor: split ExampleSection into focused tab components
Extract ExampleSection.tsx (515→66 lines) into separate components:
- ProjectPlanTab: project timeline and resource allocation
- TechnicalStrategyTab: architecture and tech stack
- SprintPlanningTab: sprint tasks and team capacity
- ImplementationGuideTab: API design and best practices
- index.ts: barrel exports

Part of P2 - Large Component Breakdown

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-13 20:44:19 +01:00
g-butandClaude Opus 4.5 757b28650b refactor: split WorkspaceDashboard into focused sub-components
Extract WorkspaceDashboard.tsx (642→219 lines) into workspace/ directory:
- WorkspaceHeader: header with lawyer info and close button
- WorkspaceSidebar: navigation with stats
- OverviewView: welcome banner, case summary, quick actions
- FilesView: file management with categories
- ChatView: live chat interface
- TimelineView: activity timeline
- SettingsView: privacy and notification settings
- workspaceUtils: helper functions (formatFileSize, getAIResponse)

Part of P2 - Large Component Breakdown

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-13 20:38:22 +01:00
g-butandClaude Opus 4.5 0bc5ed26f8 refactor: complete bot page deduplication with BotPageTemplate
Refactored remaining 3 bot pages to use shared BotPageTemplate:
- legal-expert: simplified imports, uses template wrapper
- swiss-german-teacher: enabled hashScrolling and showFooter options
- product-manager: preserved page-specific scrollToTryIt function

All 6 bot pages now use consistent template pattern.
Updated @fix_plan.md to mark P1 as completed.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-13 20:08:06 +01:00
g-butandClaude Opus 4.5 c10748ceff refactor: add BotPageTemplate and fix MDX sanitization
- Add sanitizeMdxContent() in lib/knowledge.ts to escape < followed by
  numbers (fixes MDX compilation error in production-deployment guide)
- Create BotPageTemplate component for bot page deduplication
- Refactor medical-expert, research-assistant, artistic-advisor pages
  to use new template pattern
- Template handles: bot lookup, fallback, navigation, layout

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-13 19:49:20 +01:00
g-butandClaude Opus 4.5 72c1b947d5 refactor: improve navigation architecture and add knowledge center
- Create useScrollNavigation hook for shared scroll logic (DRY)
- Add centralized navigation color config (SSOT)
- Convert components to named exports (Header, Footer, Navigation, MegaMenu)
- Fix dropdown overlay positioning with Portal pattern
- Add consulting section to homepage
- Create Knowledge Center page with guides and FAQ
- Add Knowledge menu item to navigation

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-12 00:28:45 +01:00
g-butandClaude Opus 4.5 35d34c1706 feat: improve bot page navigation with switcher and site menu
- Add BotSwitcher dropdown component for switching between bots
- Add SiteMenuDropdown hamburger menu for main site navigation
- Update BotNavigation layout with Botsmann logo, bot switcher, and site menu
- Add botSlug prop to all 6 bot page files
- Export new navigation components from index.ts

Navigation now provides:
- Botsmann 'B' logo always visible, links to home
- Bot switcher dropdown showing all other bots
- Site menu dropdown with Solutions, Bots, Projects, Blog, About links
- Mobile slide-out menu with both site nav and bot sections

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-11 23:41:40 +01:00
g-butandClaude Opus 4.5 a192ca24a0 refactor: centralize bot page configuration and add shared components
- Add BotSection and BotNotFoundFallback shared components
- Centralize menuItems and navigation config in data/bots.ts
- Add getBotBySlug and getBotTryLink helper functions
- Add BotMenuItem, BotAccentColor, and BotNavConfig types
- Refactor all 6 bot pages to use centralized configuration
- Remove ~180 lines of duplicated code across bot pages
- Improve consistency in error handling and section spacing

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-11 21:24:47 +01:00
g-butandClaude Opus 4.5 2e39380356 feat: add strict ESLint config and fix all lint issues
- Add .eslintrc.json with strict TypeScript and React rules
- Fix all unused imports and variables (prefix with _ or remove)
- Replace all `any` types with `unknown` or specific types
- Fix React hooks rule violations (conditional hooks, deps)
- Change console.log to console.info per project standards
- Add eslint-disable comments for legitimate img element uses
- Fix anonymous default exports
- Update package.json with ESLint 8 and proper lint scripts

Lint: 0 warnings, 0 errors
Build: passes successfully

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-11 16:47:56 +01:00
g-butandClaude Opus 4.5 532457299e refactor: major codebase cleanup and consolidation
## Dead Code Removed
- lib/nlp.ts (418 lines - unused duplicate)
- DemoSection.old.tsx (obsolete file)
- src/components/bots/BotPage.tsx (never imported)
- TextGenerator.tsx & EmailGenerator.tsx duplicates

## Unused Packages Removed
- @sendgrid/mail (not used - only AWS SES active)
- mailgun.js (not used)
- form-data (not used)

## Structure Consolidated
- Moved all src/lib/* to lib/ (SSOT)
- Moved src/components/navigation/* to components/
- Removed empty src/ directory
- Updated all imports to use @/lib/

## Type Fixes
- Fixed implicit any types in WorkspaceDashboard.tsx
- Fixed type union in AICaseAnalysis.tsx
- Fixed typed routes issue in page.tsx
- Fixed MongoDB module load-time error

## Build
- npm run build passes successfully

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

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-08 00:01:42 +01:00
Your Name 8a55e4fb9e feat: Complete deployment automation and modern design overhaul
- Fix header layout to prevent movement when megamenu opens
- Redesign homepage with modern, futuristic aesthetic
- Implement automated deployment with GitHub Actions
- Optimize build process for production deployment
- Add deployment monitoring and verification scripts
- Update README with comprehensive deployment documentation

Breaking changes:
- Header now uses fixed positioning with backdrop blur
- Homepage features gradient backgrounds and glassmorphism effects
- Automated CI/CD pipeline with comprehensive testing and monitoring
2025-10-02 23:46:03 +02:00
G bd70b9172d fix: use anchor for external link 2025-07-02 16:00:49 +02:00
G c2551b35b3 Revamp Lex legal assistant page 2025-06-14 16:34:11 +02:00
cato 65ace53260 Fix: Update all bot pages to use tryLink instead of hardcoded URLs 2025-03-19 09:47:32 +01:00
cato c923df4c5c Fix: Update chatLink to use tryLink in bot pages 2025-03-19 09:45:24 +01:00
cato a3fc5f09a6 Fix: Use tryLink instead of chatLink in legal-expert page 2025-03-19 09:43:17 +01:00
cato b8280c1eec Fix: Update route path in artistic-advisor bot page 2025-03-19 09:39:44 +01:00
cato d0ae27b3eb Update bot pages and add product manager bot 2025-03-19 09:35:51 +01:00
cato 3191eeff3e Fix: Add className prop to Swiss German Teacher Navigation component 2025-03-17 14:10:31 +01:00
cato 0fac605421 Update Nerd AI Research Assistant components and documentation 2025-03-17 14:06:13 +01:00