Commit graph

987 commits

Author SHA1 Message Date
Till JS
986f168d32 feat(manascore): add Lighthouse score integration
Add optional lighthouse scores (performance, accessibility, best
practices, SEO) to schema. Display as inline badges on overview
and circular gauges on detail page with average score.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-24 11:46:16 +01:00
Till JS
d3ae3841d9 feat(manascore): add score trend visualization with sparkline charts
Add history array to schema for tracking score changes over time.
Index page shows inline sparkline + delta, detail page shows larger
area chart with score labels on each data point.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-24 11:35:12 +01:00
Till JS
c21347351a fix(credit-operations): export TypeScript source directly
Allows Vite/SvelteKit to import the package without a prior build step,
matching the pattern used by other shared packages like shared-credit-ui.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-24 11:31:20 +01:00
Till JS
3c6253a84b fix(manacore): use --ignore-scripts in Dockerfile install step
Prevents postinstall from triggering premature builds before shared
packages are compiled.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-24 11:28:42 +01:00
Till JS
817ad841c6 fix(manacore): build credit-operations package in web Dockerfile
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-24 11:26:31 +01:00
Till JS
8e390395fd feat(citycorners): add photo gallery, nearby locations, and search history
1. Photo Gallery:
   - New `images` JSONB array field in locations schema
   - POST /locations/:id/images endpoint to add photos (auth required)
   - Gallery with thumbnail strip and image counter on detail page
   - Any authenticated user can add photos to any location
   - "Add photo" button inline with thumbnails

2. Nearby Locations:
   - GET /locations/:id/nearby endpoint with Haversine distance query
   - Configurable radius (default 2km, max 10km)
   - Returns up to 5 nearby locations sorted by distance
   - Horizontal scroll card strip on detail page showing distance

3. Search Suggestions + History:
   - GET /locations/suggestions endpoint (prefix matching, fast)
   - Search history stored in localStorage (max 8 entries)
   - Empty search shows recent history with clock icon
   - Selected locations automatically saved to history
   - Falls back to full-text search if no prefix matches

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-24 11:25:17 +01:00
Till JS
c4cc8529e3 fix(manacore): add credit-operations package to web Dockerfile
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-24 11:21:31 +01:00
Till JS
58fb3e8dff feat(citycorners): add owner tracking, edit/delete UI, and pagination
1. Owner tracking (createdBy):
   - Add createdBy field to locations schema
   - Set createdBy to userId on location creation
   - Only owners can edit/delete their own locations
   - Seed/unowned locations remain editable by anyone

2. Edit/Delete UI:
   - Edit button + full edit form at /locations/:id/edit
   - Delete button with confirmation dialog on detail page
   - Both only visible to the location owner
   - ForbiddenException (403) if non-owner tries to modify

3. Pagination:
   - Backend returns paginated results (page, limit, total, totalPages)
   - Frontend "Load more" button for infinite scroll
   - Category filter reloads from API with server-side filtering
   - Default 20 items per page, max 100

Tests updated: 36 tests passing (5 new for ownership + pagination).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-24 11:19:15 +01:00
Till JS
979564540a fix(manacore): fix @const syntax error in ContextDocsWidget
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-24 11:17:45 +01:00
Till JS
57a2841168 fix(manacore): fix syntax error in LandingEditor bind:value
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-24 11:15:39 +01:00
Till JS
5611f3824a feat(citycorners): UX quick wins for web app
- Lazy loading for location card images
- Category filter pills now show count (e.g. "Restaurants (3)")
- Better empty states with category-specific messages and emoji
- Share button on detail page (Web Share API with clipboard fallback)
- "On map" and "Directions" (Google Maps) buttons on detail page
- Geolocation "locate me" button on map page with user marker
- Image URL retry button on add form when image fails to load
- i18n keys for all new features (DE/EN)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-24 11:07:38 +01:00
Till JS
357fbb3d50 feat(manacore): rename audits to ManaScore + add methodology page
Rename content collection, pages, and routes from "audits" to
"manascore" for clearer branding. Add comprehensive about page
explaining the 8 scoring categories, weights, and methodology.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-24 10:43:07 +01:00
Till JS
fc7d2942d0 feat(picture): add local image generation via mana-image-gen
Add LocalImageGenService that routes to the self-hosted FLUX.2 klein
model on the Mac Mini, eliminating Replicate API dependency for basic
image generation.

Changes:
- LocalImageGenService: wraps mana-image-gen HTTP API (/generate)
  with health checking, timeout handling, and GenerationResult compat
- GenerateService: routes to local or Replicate based on model config
  (replicateId starting with "local/" → LocalImageGenService)
- Local models always use sync mode (no webhooks needed, ~0.8s)
- Seed: add "FLUX.2 Klein (Lokal)" model with sortOrder -1 (shown first)
  - costPerGeneration: 0 (free, runs locally)
  - estimatedTimeSeconds: 1
- docker-compose: add IMAGE_GEN_SERVICE_URL env var for picture backend

Replicate remains available for premium models (Seedream, Nano Banana).
Local FLUX.2 klein becomes the default free option.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-24 10:38:30 +01:00
Till JS
0ddbad9aed docs: update calendar and todo production readiness audits
Calendar: 94 → 97 (PWA, i18n complete, focus trapping, context menus,
ThrottlerGuard, error page, security headers, meta tags)

Todo: 94 → 96 (5 languages, PWA, focus trapping, context menus,
auto-save, notepad design, QuickInputBar, meta tags)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-24 10:37:07 +01:00
Till JS
6cab9a3c24 fix(infra): remove n8n and increase health check intervals to fix port exhaustion
Mac Mini had 25k+ TIME_WAIT sockets exhausting the 16k ephemeral port range,
blocking all outgoing TCP connections. Root cause: ~50 health checks at 30s
intervals + n8n automation creating excessive short-lived connections.

- Remove n8n service and volume (no longer needed)
- Increase health check intervals: 30s → 120s (app services), 10s → 30s (infra)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-24 10:35:45 +01:00
Till JS
490f8220dd docs(calendar,todo): add production readiness audit to CLAUDE.md
Document complete production readiness checklist, E2E test suites,
and current status for both apps.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-24 10:34:15 +01:00
Till JS
c4bdc6a9c2 feat(calendar): localize main settings page with i18n
Replace ~70 hardcoded German strings with i18n keys covering calendar
management, view options, reminders, birthdays, and account settings.
All 5 languages (DE/EN/FR/ES/IT).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-24 10:30:13 +01:00
Till JS
0110bff25d feat(calendar): localize sync and sharing settings pages
Replace ~70 hardcoded German strings with i18n keys in sync and
sharing settings pages. All 5 languages (DE/EN/FR/ES/IT).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-24 10:28:02 +01:00
Till JS
1a91bd7cfb test(calendar-web): add E2E test for 404 error page
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-24 10:22:56 +01:00
Till JS
44a9e02525 feat(manacore): add costs overview tab to credits page
Adds a "Kosten" tab showing all 40+ credit operations across all apps,
grouped by app with category filters (AI, Productivity, Premium) and
color-coded cost badges.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-24 10:10:44 +01:00
Till JS
d7cef38379 feat(calendar): localize all toast messages with i18n
Replace ~20 hardcoded German toast strings in events, shares, and
external-calendars stores with svelte-i18n keys (5 languages).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-24 10:06:41 +01:00
Till JS
5b77369547 feat(calendar,todo): add focus trapping to all modals
Apply shared focusTrap action to 7 app-specific modals for
improved keyboard accessibility and WCAG compliance.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-24 10:06:32 +01:00
Till JS
8bc52f4264 fix(calendar,todo): production readiness improvements
- Calendar: apply ThrottlerGuard globally (was registered but not used)
- Calendar: localize error page with i18n (5 languages)
- Calendar: add meta/OG tags and PWA meta improvements
- Todo: localize error page with i18n (5 languages)
- Todo: add meta/OG tags to root layout

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-24 09:57:24 +01:00
Till JS
52e9aa5889 docs: add devlog for evening session 2026-03-23
Context menus in 12 apps, shared-llm package, onboarding for 16 apps,
todo redesign, QuickInputBar rollout, and dashboard widgets.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-24 09:47:54 +01:00
Till JS
56ffcbac39 feat: add Ollama memory optimization, LLM metrics, and chat streaming
Three improvements to the unified LLM infrastructure:

1. Ollama memory optimization (scripts/mac-mini/configure-ollama.sh):
   - OLLAMA_KEEP_ALIVE=5m → models unload after 5min idle (saves 3-16GB RAM)
   - OLLAMA_NUM_PARALLEL=1 → predictable memory usage
   - OLLAMA_MAX_LOADED_MODELS=1 → max 1 model in RAM at a time

2. Request-level metrics in @manacore/shared-llm:
   - LlmRequestMetrics interface (model, latency, tokens, fallback detection)
   - LlmMetricsCollector class with summary stats (for health endpoints)
   - Optional onMetrics callback in LlmModuleOptions
   - Automatic metrics emission in chatMessages() (success + error)

3. Chat streaming (token-by-token SSE):
   - Backend: POST /chat/completions/stream SSE endpoint
   - OllamaService.createStreamingCompletion() via llm.chatStreamMessages()
   - ChatService.createStreamingCompletion() with upfront credit consumption
   - Web: chatApi.createStreamingCompletion() SSE consumer
   - Chat store: sendMessage() now streams tokens into assistant message
   - UI updates reactively as each token arrives

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-24 09:41:33 +01:00
Till JS
ecda4535d8 feat: add right-click context menus to calendar agenda, chat, contacts, and storage
- Calendar AgendaView: edit, duplicate, delete events (reuses WeekView i18n)
- Chat ConversationList: rename, archive, delete conversations
- Contacts ContactGridView: open, favorite, call, email, delete
- Storage FileCard: replace custom dropdown with shared ContextMenu

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-23 22:51:07 +01:00
Till JS
28286d126c feat: add right-click context menus to presi, manadeck, photos, and zitare
Use shared ContextMenu component across 4 more apps:
- Presi: open/delete decks
- ManaDeck: open/delete decks
- Photos: view/favorite/delete photos, open/delete albums
- Zitare: remove favorite, copy/share quotes

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-23 22:34:57 +01:00
Till JS
421ef55457 feat(manacore): implement mukke, presi, and context dashboard widgets
Add the 3 missing widget components that were registered but not implemented:

- MukkeLibraryWidget: shows library stats (songs, playlists, favorites),
  recent songs with artist/duration
- PresiDecksWidget: shows recent presentations with public/private
  indicator, descriptions, and update dates
- ContextDocsWidget: shows recent documents grouped by type (text,
  context, prompt) with space names, falls back to space list

All widgets follow the established pattern: APP_URLS for links,
WidgetSkeleton/WidgetError for loading/error, auto-retry on failure.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-23 22:34:56 +01:00
Till JS
7f7c6e6fde fix(manacore): replace hardcoded localhost URLs with APP_URLS in all widgets
All 6 remaining widgets now use APP_URLS from shared-branding for
dev/prod-aware URL resolution instead of hardcoded localhost ports:
- CalendarEventsWidget → APP_URLS.calendar
- ChatRecentWidget → APP_URLS.chat
- ClockTimersWidget → APP_URLS.clock
- ManadeckProgressWidget → APP_URLS.manadeck
- PictureRecentWidget → APP_URLS.picture
- StorageUsageWidget → APP_URLS.storage

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-23 22:09:24 +01:00
Till JS
e2f144962c feat: add unified @manacore/shared-llm package and migrate all backends
Create a shared LLM client package that provides a unified interface
to the mana-llm service, replacing 9 individual fetch-based integrations
with consistent error handling, retry logic, and JSON extraction.

Package (@manacore/shared-llm):
- LlmModule with forRoot/forRootAsync (NestJS dynamic module)
- LlmClientService: chat, json, vision, visionJson, embed, stream
- LlmClient standalone class for non-NestJS consumers
- extractJson utility (consolidates 3 markdown-stripping implementations)
- retryFetch with exponential backoff (429, 5xx, network errors)
- 44 unit tests (json-extractor, retry, llm-client)

Migrated backends:
- mana-core-auth: raw fetch → llm.json()
- planta: raw fetch + vision → llm.visionJson()
- nutriphi: raw fetch + regex → llm.visionJson() + llm.json()
- chat: custom OllamaService (175 LOC) → llm.chatMessages()
- context: raw fetch → llm.chat() (keeps token tracking)
- traces: 2x raw fetch → llm.chat()
- manadeck: @google/genai SDK → llm.json() + llm.visionJson()
- bot-services: raw Ollama API → LlmClient standalone
- matrix-ollama-bot: raw fetch → llm.chatMessages() + llm.vision()

New credit operations:
- AI_PLANT_ANALYSIS (2 credits, planta)
- AI_GUIDE_GENERATION (5 credits, traces)
- AI_CONTEXT_GENERATION (2 credits, context)
- AI_BOT_CHAT (0.1 credits, matrix)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-23 22:06:30 +01:00
Till JS
e7bf58c5b6 feat(calendar-web): add right-click context menu to events in week view
Use shared ContextMenu component on EventCard for quick actions:
edit, duplicate, and delete. Includes i18n for all 5 languages.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-23 22:02:46 +01:00
Till JS
250e0b20af feat: add onboarding to 6 new apps and feature intro step to all 16 apps
Add onboarding with feature overview, preference selection, and tips to
Zitare, Mukke, Photos, Planta, SkillTree, and Questions. Insert a new
first "features" info step into all 10 existing onboarding flows so every
app now starts with a core-features overview page.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-23 21:58:14 +01:00
Till JS
89ca3b0454 fix(manacore): update todo service test mock to match new Task type
Update mockTask to use labels/subtasks instead of removed labelIds field.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-23 21:57:52 +01:00
Till JS
0893e47ad3 feat(todo-web): add right-click context menu to task list
Use shared ContextMenu component for quick actions: edit, toggle
complete, change priority, move to project, and delete.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-23 21:56:58 +01:00
Till JS
3b883af064 feat(manacore): improve todo dashboard widgets and fix port mismatch
- Fix todo dev port in APP_URLS (5188, was swapped with inventory 5189)
- Use APP_URLS for all links instead of hardcoded localhost ports
- TasksTodayWidget: add priority dots, subtask progress, label tags,
  completed/total counter, clickable task links
- TasksUpcomingWidget: add priority dots, label tags, overdue/today
  date highlighting with colored badges, clickable task links
- Extend Task type with labels and subtasks for richer widget display

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-23 21:48:29 +01:00
Till JS
cb18384905 fix(contacts-web): add spiral-db to Dockerfile
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-23 21:28:23 +01:00
Till JS
ff419f069a feat: add QuickInputBar to 6 more apps (mukke, matrix, manadeck, planta, photos, presi)
- Mukke: search songs by title/artist/album via libraryStore
- Matrix: search rooms/contacts, select navigates to chat
- ManaDeck: search decks by title/description
- Planta: search plants by name/species via plantsApi
- Photos: search albums and tags
- Presi: search presentation decks

All with locale-aware syntax highlighting.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-23 21:25:51 +01:00
Till JS
49457c354a feat(todo-web): auto-save task edits, remove save/cancel buttons
Changes in the expanded inline task editor are now saved automatically
with a 500ms debounce. Removes the need to manually click "Speichern".
The delete button remains for intentional destructive actions.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-23 21:24:00 +01:00
Till JS
ee3e815f1d fix(contacts-web): add shared-app-onboarding to Dockerfile
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-23 21:19:20 +01:00
Till JS
08a7d2a097 fix(todo-web): clean up list design and make onboarding tip dismissable
- Remove spiral binding holes (ring elements) from notepad container
- Remove vertical red margin line from left side
- Add X close button to onboarding tip so users can dismiss it

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-23 21:19:14 +01:00
Till JS
dc372ee744 fix(contacts-web): add shared-pwa package to Dockerfile
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-23 21:07:20 +01:00
Till JS
436e92c560 feat: unify QuickInputBar across all apps with locale + deferSearch
- Add `locale` prop to all 6 apps using QuickInputBar
  (todo, contacts, zitare, citycorners, questions, calendar)
- Enable `deferSearch` on apps with create flow
  (contacts, zitare, questions) to match todo behavior
- Pass locale through Calendar's UnifiedBar wrapper
- Questions: default to 'en' locale (English-first app)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-23 21:06:58 +01:00
Till JS
534b55b566 test(todo-web): add tests for unified TaskFilters and viewStore filter state
- Extract applyTaskFilters as pure utility function for testability
- Add 21 tests for task filtering (priority, project, labels, search, combined)
- Add 13 tests for viewStore filter methods (setters, clearFilters, reset)
- All 87 tests passing

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-23 21:04:21 +01:00
Till JS
c1ca93b2f1 fix(contacts-web): add patches dir to Dockerfile for pnpm install
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-23 21:04:06 +01:00
Till JS
9edd1c6e2e feat(shared-ui): locale-aware highlighting + success feedback for InputBar
1. Extract hardcoded German highlight patterns into locale-specific sets
   (de, en, fr, it, es). InputBar accepts `locale` or custom
   `highlightPatterns` prop, defaulting to German for backward compat.

2. Add visual success feedback after creating: input bar flashes green
   with a checkmark icon for 1.2s, confirming the action was successful.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-23 20:55:31 +01:00
Till JS
45db42720c fix(todo): pixel-perfect skeleton loaders, PillNav tab group, and SSR head fix
- Rewrite TaskListSkeleton to match notepad design (spiral holes, red margin line, cream background)
- Rewrite TaskItemSkeleton as flat rows with border-bottom instead of card style
- Rewrite KanbanColumnSkeleton with glassmorphism and pill-shaped task cards
- Update KanbanBoardSkeleton with matching border-radius and dark mode support
- Group navigation pills (Liste/Kanban/Tags) into PillTabGroup for clear UX distinction from toggle pills (Filter)
- Add Phosphor icon support to PillTabGroup component
- Fix %sveltekit.head% appearing as literal text in production by removing duplicate placeholder from HTML comment
- Disable PWA service worker in dev mode

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-23 20:51:41 +01:00
Till JS
f5842ea50e refactor(todo-web): unify FilterStrip and KanbanFilters into TaskFilters
Replace two separate filter components with a single TaskFilters component
that supports both layouts via a variant prop ("strip" for bottom pill bar,
"bar" for inline kanban-style). Fixes a bug where FilterStrip's priority
and project filters were dead local state that never actually filtered tasks.

- Add filter state (priorities, project, labels, search) to viewStore
- Apply filters to all derived task lists in the list view
- Delete FilterStrip.svelte and KanbanFilters.svelte

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-23 20:48:34 +01:00
Till JS
92adabc8e2 feat(todo,contacts): add TagStrip above PillNav, unified with Calendar design
Add horizontal glass-morphism tag filter strip to Todo and Contacts apps,
matching the existing Calendar TagStrip pattern. Includes TagStripModal for
inline tag search/create/edit/delete. Contacts app gets a centralized
tagsStore replacing multiple independent tag-loading calls.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-23 20:47:41 +01:00
Till JS
1075e811f2 feat(todo-web): show QuickInputBar only on list and kanban views
Hide the task input bar on non-task pages (settings, mana, tags, etc.)
where creating tasks doesn't make contextual sense.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-23 20:39:26 +01:00
Till JS
97d6787d40 feat(todo-web): redesign task list as physical notepad
Adds notepad container with cream paper background, spiral binding holes,
red margin line, and lined rows instead of card-style task items.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-23 20:16:40 +01:00