Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
218 commits
Select commit Hold shift + click to select a range
9f8ee90
docs(rules): add mandatory branch strategy — never push/merge to main…
manfredsteger Apr 15, 2026
00725b7
fix(email): read V3 template colors directly from customization.theme
manfredsteger Apr 15, 2026
50e64a2
Transitioned from Plan to Build mode
Apr 16, 2026
5f47bf1
feat(footer): replace default copyright with rich MIT+GitHub+Bavaria …
manfredsteger Apr 16, 2026
40eb661
fix(footer): also inject POLLY_COPYRIGHT_TEXT in public customization…
manfredsteger Apr 16, 2026
9372f78
feat(footer): Neuer Standard-Footer mit MIT + GitHub + Bayern (Task #37)
Apr 16, 2026
bb7a15f
fix(footer): ENV PUT returns 400 + dangerouslySetInnerHTML for ENV co…
manfredsteger Apr 16, 2026
588caa4
feat(footer): Neuer Standard-Footer mit MIT + GitHub + Bayern (Task #37)
Apr 16, 2026
8b7ec19
fix(footer): silent strip copyrightText in PUT + omit from payload wh…
manfredsteger Apr 16, 2026
ea9db09
feat(footer): Neuer Standard-Footer mit MIT + GitHub + Bayern (Task #37)
Apr 16, 2026
159131f
fix(footer): restore HTTP 400 for copyrightText changes when POLLY_CO…
manfredsteger Apr 16, 2026
2079852
feat(footer): Neuer Standard-Footer mit MIT + GitHub + Bayern (Task #37)
Apr 16, 2026
9476322
fix(footer): preserve stored copyrightText when ENV lock active + oth…
manfredsteger Apr 16, 2026
6e32ed3
feat(footer): Neuer Standard-Footer mit MIT + GitHub + Bayern (Task #37)
Apr 16, 2026
57e1f83
fix(footer): align GitHub icon/text on same baseline as surrounding text
manfredsteger Apr 16, 2026
07658c9
Git commit prior to merge
Apr 17, 2026
23cbddd
Footer-Jahr dynamisch setzen
Apr 17, 2026
4f62964
feat(ai-settings): add KISSKI service partner block in admin AI panel
manfredsteger Apr 17, 2026
3aeec48
Transitioned from Plan to Build mode
Apr 17, 2026
aebca0c
fix(docker): move KISSKI logo into client/src/assets so Vite can find…
manfredsteger Apr 17, 2026
da8d2db
fix(docker): KISSKI-Logo in den Quellbaum verschieben (Task #39)
Apr 17, 2026
e4425b3
fix(auth): drop session cookie 'secure' flag on plain HTTP (Docker lo…
manfredsteger Apr 17, 2026
15d9258
test(auth): add unit tests for secure-cookie logic (Docker login regr…
manfredsteger Apr 17, 2026
ebfeff5
fix(auth): drop session cookie 'secure' flag on plain HTTP
manfredsteger Apr 17, 2026
f3ba8e1
fix(testRunner): set NODE_ENV=test in executeVitest spawn
manfredsteger Apr 17, 2026
c8993a9
test(emailTemplate): de-flake "reset theme using primary color" test
manfredsteger Apr 17, 2026
6ef47f3
fix(test-runner): reconcile final totalTests + preserve test data aft…
manfredsteger Apr 17, 2026
21c73aa
docs(env): document RUN_VIA_INAPP internal flag in .env.example
manfredsteger Apr 17, 2026
5396309
feat(admin): add "Test-Historie löschen" button to clear test run his…
manfredsteger Apr 17, 2026
d61deb3
fix(admin/tests): refresh test-data stats after a test run completes
manfredsteger Apr 17, 2026
81319c6
Transitioned from Plan to Build mode
May 12, 2026
6e28ae8
Update project documentation and remove unused dependencies
May 12, 2026
bb64df6
PWA-Readiness: dynamic manifest, service worker, maskable icons, iOS …
May 12, 2026
bb20964
PWA-Readiness: dynamic manifest, service worker, dynamic iOS branding
May 12, 2026
7d132a0
PWA-Readiness: dynamic manifest, service worker, dynamic iOS branding
May 12, 2026
0adbaa6
PWA-Readiness: dynamic manifest, service worker, dynamic iOS branding
May 12, 2026
6de2bd2
PWA-Readiness: dynamic manifest, service worker, dynamic iOS branding
May 12, 2026
e9a3416
Prevent race conditions in email template tests by stubbing data retr…
May 12, 2026
71d6d0d
Stabilize email template tests by preventing data races
May 13, 2026
36a7636
Transitioned from Plan to Build mode
May 15, 2026
a834475
Admin user management: fix dropdown bug + add password actions (Task …
May 15, 2026
4529809
Admin user management: fix dropdown bug + add password actions (Task …
May 15, 2026
0ab2a3c
Fix user management view to show correct lists after navigation
May 15, 2026
245161f
Transitioned from Plan to Build mode
May 15, 2026
bb9d922
Refactor user management: detail page as unified edit interface
May 15, 2026
a3c232e
Refactor user management: detail page as unified edit interface
May 15, 2026
f445f86
Refactor user management: detail page as unified edit interface
May 15, 2026
a9c57e7
Fix poll click in user detail view: open results page in new tab
May 15, 2026
460bce4
Remove unused poll click functionality and enhance link security
May 15, 2026
14cf5ff
Add tests to verify username updates and handle various error conditions
May 15, 2026
928afbd
feat(admin): show all user polls with expand/collapse toggle
May 15, 2026
44da0f7
Saved progress at the end of the loop
May 15, 2026
831e58e
Remove unnecessary session checks from admin poll routes
May 15, 2026
225808f
Improve the poll creation success page and route handling
May 15, 2026
40544bf
Update user roles to display immediately after changing
May 15, 2026
dedc876
Transitioned from Plan to Build mode
May 18, 2026
10c908c
Fix timezone bug: migrate all TIMESTAMP columns to TIMESTAMPTZ
May 18, 2026
9317726
Transitioned from Plan to Build mode
May 18, 2026
8de5e52
Fix test DB pollution: pwaManifest test left "AcmePolls" in live sett…
May 18, 2026
214a9fa
Fix test DB pollution: pwaManifest left "AcmePolls" in live settings
May 18, 2026
518d72d
Add database cleanup to prevent test interference
May 18, 2026
b731be7
Fix test isolation: email theme and footer state pollution in emailTe…
May 20, 2026
3593738
Apply crash-safe backup key pattern to wcagAudit and admin-comprehens…
May 20, 2026
7568e7a
feat(i18n,home): rename "Find Date" to "Schedule Poll" and move CTA g…
May 21, 2026
c9eae0e
fix(my-polls): route "Show results" action to /poll/:token#results in…
May 21, 2026
095e732
feat(admin-users): add role filter and last-login sorting, simplify s…
May 21, 2026
fb04511
refactor(my-polls): replace redundant create CTAs with single Home bu…
May 21, 2026
5e350b2
fix(create-poll): unify video URL validation across frontend/backend …
May 21, 2026
bfa77a7
fix: unify poll create/edit validation, block closed-poll vote edits,…
May 26, 2026
5b6a093
Update admin routes to correctly identify polls using public tokens
May 26, 2026
108ca8b
Implement automated poll expiration and reminder email notifications
May 26, 2026
1bb777c
fix: improve poll create/vote validation and error handling
May 26, 2026
838ad56
fix(poll-edit): add schedule video URL field and improve validation e…
May 26, 2026
2998ad5
feat(voting): add optional survey participant comments with admin-onl…
May 27, 2026
6780839
chore(create-poll): temporarily hide weekday template option
May 27, 2026
edde77a
refactor(poll): remove duplicate edit action in tools and align back …
May 27, 2026
655b662
feat(voting): persist and display participant comments for schedule/s…
May 28, 2026
bea19ea
fix(schedule): improve slot editing and reactivation safeguards
May 28, 2026
715d7fe
fix(admin): refresh dashboard stats and align poll metrics after admi…
May 28, 2026
4c1965c
feat(admin,polls): improve dashboard metrics/no-expiry labels and upd…
May 29, 2026
f7ef669
fix(schedule): block past slot creation, enforce INVALID_PAST_TIME_SL…
Jun 1, 2026
e6c4d5f
fix(create-poll): preserve expiry reminder settings across login-requ…
Jun 1, 2026
e24302f
improve results UI and prevent finalizing polls without votes
Jun 2, 2026
dfc46f6
fix(create-organization): remove optional hint from From/To slot time…
Jun 2, 2026
bb0a833
feat(create-organization): redesign slot builder with date groups, co…
Jun 5, 2026
11599b5
fix: add time editing, capacity warnings, and signup-safe deletion fo…
Jun 5, 2026
e29c22b
fix(orglist): add template preview and fix dialog slot editing
Jun 8, 2026
ae20c07
feat(orga): add sign-up confirmation flow for Orga-Listen polls
replit-agent Jun 8, 2026
c120a99
feat(orga): add sign-up confirmation flow for Orga-Listen polls
replit-agent Jun 8, 2026
1a0ff35
feat(orga): add sign-up confirmation flow for Orga-Listen polls
replit-agent Jun 8, 2026
4e8b1e8
feat(orga): add sign-up confirmation flow for Orga-Listen polls
replit-agent Jun 8, 2026
e1cfdf9
Add global test teardown for email_theme and email_footer in setup.ts
Jun 8, 2026
21add24
Automate database schema updates during post-merge setup
replit-agent Jun 8, 2026
0902295
feat: show selected options in vote confirmation email + spam hint on…
replit-agent Jun 8, 2026
3d0b309
Apply crash-safe backup key pattern to remaining test files that muta…
Jun 8, 2026
8f20bf7
Merged changes from dl58plta/main
Jun 8, 2026
a804d65
Fix pre-existing test failures in validation.test.ts
Jun 8, 2026
3b8f745
fix(polls): resolve voting, survey, results, and organization flow is…
Jun 9, 2026
73fd3fb
Polish organization slot builder layout
Jun 9, 2026
d07f9a8
Protect ICS export for private poll results
Jun 9, 2026
0686189
Preserve poll redirect after login and Keycloak SSO
Jun 11, 2026
d25d11a
Fix invalid poll results polling and add regression guard
Jun 12, 2026
a5b8574
Apply rate limiting to public poll read, results, and vote submission…
replit-agent Jun 12, 2026
8534334
fix(invites): use admin token for poll invite endpoints
Jun 12, 2026
024ca13
fix(email): include selected org poll slots in vote confirmations
Jun 12, 2026
bb1610c
fix(results): show tie state in most popular option banner
Jun 12, 2026
ce56e47
feat(email): preserve V3 poll-created layout for customized template …
Jun 12, 2026
51e0c22
feat(email): render custom poll_created templates with correct V3 sec…
manfredsteger Jun 13, 2026
7ad5307
Harden public poll helper and export endpoints with rate limiting
Jun 13, 2026
d9c5f49
Refine vote success page layout and simplify share actions
Jun 13, 2026
6001d6c
refactor navigation and admin poll management UX
Jun 15, 2026
d49d83f
improve(UI) poll metrics wording and navigation clarity
Jun 15, 2026
9ea3e92
chore: upgrade dependencies for security audit findings
Jun 15, 2026
e3dae61
Improve poll voting and validation logic
manfredsteger Jun 15, 2026
944bcb0
fix: resolve docker npm ci failure caused by bufferutil mismatch
Jun 15, 2026
2be09e1
Improve organization quick-template date selection and dialog usability
Jun 16, 2026
652d0e0
(UI): Refine admin overview styling and success page action colors
Jun 16, 2026
373927b
Remove email subject prefixes and improve template preview rendering
Jun 16, 2026
3e32c72
fix: repair voice overlay waveform colors and fallback bar flicker
Jun 16, 2026
003ee90
Enhance email templates with structured V3 styling and button creation
manfredsteger Jun 16, 2026
62803e4
Fix custom email template rendering and finalized template support
Jun 16, 2026
757fcbf
fix(ui): improve dark-mode results badges and localize results labels
Jun 17, 2026
3583a8a
fix(admin): make branding reset resilient in tests and docker
Jun 17, 2026
ccbb721
fix: restore vote confirmation email features and stabilize Docker an…
Jun 19, 2026
3bc882b
refactor(admin-polls): simplify creator display and label guest-creat…
Jun 19, 2026
725b086
fix(email): add vote_updated template, and harden custom template ren…
Jun 19, 2026
be57da4
fix(email): restore vote email flows and personalize participant remi…
Jun 19, 2026
57263ac
fix: resolve poll data inconsistencies and document email flows
manfredsteger Jun 19, 2026
fb9db60
Add docs/email-flows.md visualizing all email flows
manfredsteger Jun 22, 2026
9f33e3d
Add docs/email-flows.md visualizing all email flows
manfredsteger Jun 22, 2026
bc2f1c8
docs(email-flows): embed rendered Mermaid diagrams as PNG images
manfredsteger Jun 22, 2026
016e87c
Break down user actions into detailed, collapsible flow diagrams
manfredsteger Jun 22, 2026
b61cf74
Fix image rendering issues within collapsible sections
manfredsteger Jun 22, 2026
59acb1d
Update email workflows to correctly inform creators of new polls
manfredsteger Jun 22, 2026
fcc1e54
docs: release audit & prepare all docs for v0.1.0-beta.3
manfredsteger Jun 22, 2026
4ce266d
docs: release audit & prepare all docs for v0.1.0-beta.3
manfredsteger Jun 22, 2026
5c946a4
fix(voting): block repeat submissions on non-editable polls and remov…
Jun 25, 2026
7794bea
fix(email-template): correct finalized schedule time rendering text f…
Jun 25, 2026
5719a75
fix(auth): force logout after password reset and block IDM user deletion
Jun 25, 2026
aa55b7f
fix(ui): use AlertBanner for already-voted warning in VotingInterface
Jun 26, 2026
0bd014a
feat(auth): require login for Keycloak users without Polly account
Jun 26, 2026
da1695b
feat(auth): detect existing IDM accounts before allowing guest voting.
Jun 26, 2026
aab09f2
feat(voting): show IDM specific message and Make "or use a different …
Jun 26, 2026
3edbff2
chore(docker): expose KEYCLOAK_ADMIN_CLIENT_ID and KEYCLOAK_ADMIN_CLI…
Jun 26, 2026
0085090
Add tests for email confirmation and duplicate vote scenarios
manfredsteger Jun 25, 2026
80129aa
Add horizontal scroll indicator to ResultsChart matrix tables
manfredsteger Jun 25, 2026
e771a5c
Update documentation and changelog for environment variables
manfredsteger Jun 26, 2026
7c88d1a
Add creator notification email on new vote (Task #79)
replit-agent Jun 29, 2026
7c74f3f
Improve poll PDF export: letterhead, markdown description, Polly link
replit-agent Jun 29, 2026
a760b99
Improve poll PDF export: letterhead, markdown, Polly link, secure san…
replit-agent Jun 29, 2026
631e2d1
Fix emailTemplateService test isolation: save/restore customizationSe…
Jun 29, 2026
0d96fa5
Add voter matrix table to PDF export with optional participant list t…
Jun 29, 2026
3bd7c6b
Add robust password policy enforcement and customization options
manfredsteger Jul 22, 2026
3320fa7
Add comprehensive tests for password policy and update existing tests
manfredsteger Jul 22, 2026
a0c806d
Add multi-factor authentication for enhanced account security
manfredsteger Jul 22, 2026
8e47fa8
Add ability for admins to reset user multi-factor authentication
manfredsteger Jul 23, 2026
6aad53c
Add functionality to enforce multi-factor authentication for users
manfredsteger Jul 23, 2026
47cc061
Improve test reliability for MFA settings and admin setup
manfredsteger Jul 23, 2026
c1b7e1b
fix(security): harden image upload against LSI pentest finding 2.3
manfredsteger Jul 23, 2026
c90cd43
Block malicious scripts in admin-uploaded SVG logos via DOMPurify+JSDOM
manfredsteger Jul 23, 2026
9b78dd2
Add obfuscation-bypass tests for DOM-parser SVG sanitizer
manfredsteger Jul 23, 2026
5f7c34e
Block SVG uploads in poll option images: defense-in-depth test coverage
manfredsteger Jul 23, 2026
3f48d02
Add HTTP integration tests confirming SVG uploads are blocked at the …
manfredsteger Jul 23, 2026
52b3fe8
Add SVG sanitization defense-in-depth tests for poll option image upl…
manfredsteger Jul 23, 2026
344fa2e
Add Markdown closing message to poll end dialog
manfredsteger Jul 23, 2026
c99c1ff
Git commit prior to merge
manfredsteger Jul 23, 2026
27bd69a
Add closing_message column to polls table for durable persistence
manfredsteger Jul 23, 2026
878eb52
Enhance multi-factor authentication security and prevent token replay…
manfredsteger Jul 23, 2026
20b3d1a
Document findings of security and code audits
manfredsteger Jul 24, 2026
d63dbbd
feat(admin-tests): support multiple notification emails for test reports
Jul 27, 2026
e416d94
Align password change flows with active password policy UI
Jul 27, 2026
accc3d3
Update MFA test runner service and documentation
manfredsteger Jul 27, 2026
aa79d42
Add guest access control for poll creation and voting
manfredsteger Aug 21, 2026
ce5e16b
Admin MFA policy: pre-warning dialog + MFA_ADMIN_REQUIRED env override
manfredsteger Aug 21, 2026
02dc480
Merge feature/guest-access-control — restore guest access controls al…
manfredsteger Aug 21, 2026
06fdccb
Fix MFA dialog: defer adminMfaRequired state until explicit confirmation
manfredsteger Aug 21, 2026
2d6a9ed
Fix MFA override: bypass TOTP challenge for enrolled admins + fail-cl…
manfredsteger Aug 21, 2026
a9003c3
chore: prepare v0.1.0-beta.2 release
manfredsteger Aug 22, 2026
e756155
Remove unused code from image service
manfredsteger Aug 22, 2026
d61ceee
fix: release corrected image upload validation in beta.3
manfredsteger Aug 22, 2026
2195c67
docs: record immutable release tag workflow
manfredsteger Aug 22, 2026
eed1e43
fix: guard release tags against package version drift
manfredsteger Aug 22, 2026
832738f
feat: tag-exact release notes from changelog, disable duplicate auto …
manfredsteger Aug 22, 2026
d5a0883
Implement MFA enforcement and add supporting documentation and tests
manfredsteger Aug 23, 2026
dc357ba
Implement and test clamav service improvements and documentation updates
manfredsteger Aug 23, 2026
656bfa4
Add tests for clamavService
manfredsteger Aug 23, 2026
70178d1
Update voting interface and adjust corresponding end-to-end tests
manfredsteger Aug 23, 2026
8c6e077
chore: prepare v0.1.0-beta.4 release
manfredsteger Aug 23, 2026
5680943
Implement voting interface enhancements and update poll creation flow
manfredsteger Aug 24, 2026
7fe71f2
Implement mockup sandbox preview feature and update voting component
manfredsteger Aug 24, 2026
b575990
Refactor Vite configuration and document middleware stability
manfredsteger Aug 24, 2026
0152493
Implement CSS color variable support and add corresponding tests
manfredsteger Aug 24, 2026
8e1ccb4
chore: prepare v0.1.0-beta.5 release
manfredsteger Aug 24, 2026
234cd1e
chore: prepare v0.1.0-beta.6 release
manfredsteger Aug 24, 2026
b0a2337
chore: release v0.1.0-beta.7 (correct changelog history)
manfredsteger Aug 24, 2026
565968d
Fix self-hosted upgrade: apply all journal migrations at startup, han…
manfredsteger Aug 25, 2026
d08d81b
Implement OIDC issuer URL configuration and add supporting tests
manfredsteger Aug 25, 2026
c94e204
chore: release v0.1.0-beta.9
manfredsteger Aug 25, 2026
e741257
fix(docker-prod): avoid esbuild install race during npm ci
Aug 27, 2026
4aa8ef0
fix(email): harden email template service behavior and update tests
Aug 28, 2026
e59351d
feat(ai): add live model discovery and improve upstream error reporting
Aug 28, 2026
3628756
feat(ai): curate admin model selection and add manual provider checks
Aug 28, 2026
08799c6
feat(test-report): add result filters and failed-case summaries to te…
Aug 28, 2026
3cbc671
test: enable registration in test bootstrap
Sep 3, 2026
07dca0d
feat(test-report): show result counts on filter buttons
Sep 3, 2026
4db594f
feat(auth): add optional SSO auto-redirect and single logout
Sep 3, 2026
8c43ad4
fix: prevent sensitive data leaks in public poll responses
Sep 17, 2026
77046fa
fix: secure vote management and clarify editing and withdrawal permis…
Sep 18, 2026
93ec711
feat: confirm vote withdrawals in the UI and notify participants and …
Sep 18, 2026
725e457
fix: include yes, maybe and no answers in vote email summaries
Sep 18, 2026
af7a9d9
fix: hide results sections in participant emails for private polls
Sep 18, 2026
65ac123
fix: protect admin accounts and stabilize isolated test runs
Sep 21, 2026
03742e8
docs: explain isolated test database setup and release security fixes
Sep 21, 2026
d8d3d60
fix: show real database host, status and SSL state in admin dashboard
Sep 29, 2026
fa675e3
fix: make admin dashboard, poll page and calendar responsive on small…
Sep 29, 2026
33e731b
fix: log DATABASE_URL parse failures in database-status endpoint
Sep 30, 2026
0d04a18
test: add additional slot to capacity limit test
SK-tec Oct 1, 2026
266b1ce
fix(a11y): add accessible labels to organization slot-duration dropdowns
SK-tec Oct 2, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions .agents/memory/MEMORY.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
- [Mermaid diagram rendering](mermaid-rendering.md) — docs Mermaid diagrams committed as PNGs via `scripts/render-mermaid.mjs`; a stray ASCII `"` in an unquoted Mermaid label breaks Mermaid 11 parsing.
- [Test app singleton + MFA test setup](test-app-singleton-mfa.md) — createTestApp() is a module-level singleton; all describe blocks share the same MemoryStore; login BEFORE enabling MFA to avoid TOTP challenge in session setup.
- [SAST false positives](sast-false-positives.md) — image/whisper path-traversal, TOTP SHA-1, theme-cookie and CI postgres-string findings verified harmless; skip re-analysis unless code changed.
- [Immutable release tags](release-pipeline.md) — a failed public tag stays permanent; fix the branch and use the next prerelease identifier, then monitor all gated artifact jobs.
- [MFA enforcement boundary](mfa-enforcement-boundary.md) — enrolled app MFA is required after every browser primary login; setup policy and emergency recovery are separate decisions.
- [Simple choice response mode](simple-choice-mode.md) — simple-mode vote writes must use the advisory-locked atomic replacement in storage; route-level validation alone is race-prone.
- [Test vs dev database drift](test-db-drift.md) — vitest uses DATABASE_URL, dev server may use another DB; new columns must be applied to both, and drizzle push is interactive (prompts on ambiguous renames).
- [ClamAV configuration precedence](clamav-configuration-precedence.md) — explicit runtime scanner settings override Admin values; unknown scanner state blocks uploads rather than failing open.
- [Mockup sandbox dependency setup](mockup-sandbox-install.md) — a fresh sandbox can need a local dependency install before Vite resolves its declared Tailwind packages.
- [Vite middleware React stability](vite-middleware-react-stability.md) — keep Cartographer’s dev instrumentation out of this middleware-served app; it can split React’s runtime graph during startup.
- [CSS color variable wrapping](css-color-variable-wrapping.md) — --primary/--primary-foreground must be full hsl()/rgb() values, not bare "H S% L%" triplets; a bare triplet silently no-ops backgrounds.
10 changes: 10 additions & 0 deletions .agents/memory/clamav-configuration-precedence.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
---
name: ClamAV configuration precedence
description: Runtime, persisted scanner configuration, and fail-secure behavior for upload scanning.
---

An explicit non-empty ClamAV environment value overrides the corresponding persisted Admin scanner setting at runtime. Leave environment values unset when the Admin panel should control scanner configuration.

**Why:** A stale persisted enabled scanner setting can otherwise keep uploads blocked after an operator deliberately sets runtime scanning off. Conversely, an unavailable configuration must never turn an intended scanner off silently.

**How to apply:** Treat explicit `CLAMAV_ENABLED=false` as a deliberate no-scan choice. When scanning is enabled or its Admin-managed state cannot be determined, preserve the last known configuration when possible and block uploads fail-secure until the configuration/scanner is available.
10 changes: 10 additions & 0 deletions .agents/memory/css-color-variable-wrapping.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
---
name: CSS color variable wrapping convention
description: This project's CSS custom properties for theme colors must be full CSS color functions (hsl(...)/rgb(...)), never bare component triplets — relevant whenever touching client/src/index.css or code that calls root.style.setProperty on a themed color variable.
---

All theme color custom properties in `client/src/index.css` (both `:root` and `.dark`) are defined as full CSS color function values, e.g. `--border: hsl(220, 13%, 91%);`, and `tailwind.config.ts` consumes them directly as `var(--border)` (no extra `hsl()` wrap in the Tailwind config).

**Why:** `--primary` and `--primary-foreground` were once defined as bare "H S% L%" triplets (e.g. `--primary: 220 70% 45%;`), a leftover from a different shadcn convention (Tailwind wrapping `hsl(var(--x))`). Since this project's Tailwind config does NOT wrap in `hsl(...)`, a bare triplet is invalid as `background-color` and the browser silently drops it — the element renders with no background at all (looks "transparent"/unstyled) with no console error. The same bug was independently reintroduced by runtime branding code in `client/src/contexts/CustomizationContext.tsx`, which calls `root.style.setProperty('--primary', ...)` when a custom brand color is configured; that inline style has higher specificity than the stylesheet, so even a corrected CSS file gets silently overridden back to a bare triplet.

**How to apply:** Any new or edited CSS custom property intended for use as a Tailwind `bg-*`/`text-*`/`border-*` color must have its full value wrapped in `hsl(...)` (or another real CSS color function) at the point of definition. This applies both in `index.css` and in any JS that calls `.style.setProperty` on such a variable (e.g. branding/customization code) — grep `setProperty\(.*--` for all such call sites when auditing this class of bug. A regression test exists at `server/tests/unit/theme-css-variables.test.ts` that statically checks both the CSS file and `CustomizationContext.tsx` for this pattern; extend it if new theme variables are added.
28 changes: 28 additions & 0 deletions .agents/memory/mermaid-rendering.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
---
name: Mermaid diagram rendering in docs
description: How email-flow (and similar) Mermaid diagrams are turned into committed PNGs, plus a Mermaid 11 parsing gotcha.
---

# Mermaid diagram rendering in docs

## Decision
`docs/email-flows.md` embeds each diagram as a committed PNG (`docs/assets/email-flows/NN-slug.png`) AND keeps the Mermaid source in a collapsible `<details>` block as the editable source of truth. Regenerate with `node scripts/render-mermaid.mjs`.

**Why:** The Replit Markdown preview and simple Markdown viewers only show the raw ```mermaid code, not a rendered diagram. Static images make diagrams visible everywhere (Replit preview + GitHub) without an external viewer.

**How to apply:** The render script reuses Puppeteer + the system Chromium (same path-resolution as `server/services/pdfService.ts`, no Chromium re-download) and the local `mermaid` npm dependency (UMD build at `node_modules/mermaid/dist/mermaid.min.js`). It derives image filenames from the nearest preceding heading (slugified). If you rename/add a section heading, re-run the script AND update the `![...](...)` link(s) — the script does not rewrite the Markdown embeds or delete stale images.

## Mermaid 11 parsing gotcha
A stray **ASCII straight double-quote** (`"`, 0x22) inside an **unquoted** node label (e.g. a stadium `([...])` or rectangle `[...]`) makes Mermaid 11 emit a `STR` token and fail with a parse error. German typographic quotes were the trap here: an opening `„` (U+201E) paired with a straight `"` instead of the closing `“` (U+201C).

**Fix:** use matching typographic quotes (`„…“`), or wrap the whole label in straight double-quotes (`["…"]`). The `[/"…"/]` parallelogram form is already proper quoting and is fine.

**Why it matters:** GitHub's native Mermaid renderer hits the same error, so this is a latent rendering bug, not just a local-script issue.

## Replit renderer: images inside `<details>` blocks

Replit's Markdown renderer does **not** parse `![alt](path)` syntax inside HTML blocks (`<details>`, `<div>`, etc.) — it shows "Unsupported image" instead.

**Fix:** Use plain HTML `<img src="…" alt="…" style="max-width:100%;">` for any image that sits inside a `<details>` block. Top-level images (outside HTML blocks) keep their Markdown `![](…)` syntax, which works fine.

**How to apply:** If you add more diagram sub-sections inside `<details>`, always use `<img>` tags, not Markdown image syntax.
10 changes: 10 additions & 0 deletions .agents/memory/mfa-enforcement-boundary.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
---
name: MFA enforcement boundary
description: Product-security rule for the relationship between enrolled MFA, admin setup policy, and recovery.
---

An account that has enrolled app TOTP must complete it after every browser primary login, regardless of whether the admin-wide MFA setup policy is enabled. This applies consistently to local-password and browser SSO primary authentication.

**Why:** The setup policy answers whether an *unenrolled* administrator must configure MFA. Treating a disabled setup policy as permission to skip an already-enrolled factor silently downgrades the account to password-only authentication.

**How to apply:** Keep the emergency `MFA_ADMIN_REQUIRED=false` break-glass path narrowly limited to enrolled administrators who need recovery. It must not bypass MFA for ordinary users. Treat non-browser bearer-token assurance as an identity-provider concern unless a separate app-issued, post-MFA API credential flow is deliberately designed.
8 changes: 8 additions & 0 deletions .agents/memory/mockup-sandbox-install.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
name: Mockup sandbox dependency setup
description: Newly created mockup sandboxes can have an empty node_modules directory despite a complete package.json
---

- After creating a mockup sandbox, confirm its local dependencies exist before relying on the preview workflow.
- **Why:** the generated sandbox package can exist with an empty `node_modules`; Vite then reports that it cannot resolve `tailwindcss` even though the package is declared.
- **How to apply:** if the sandbox workflow reports a missing package immediately after artifact creation, run `npm install` from the sandbox directory, restart its preview workflow, and verify a real `/__mockup/preview/...` page with a screenshot. For a standalone production build, supply the workflow-provided `BASE_PATH` and `PORT` environment values.
10 changes: 10 additions & 0 deletions .agents/memory/release-pipeline.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
---
name: Immutable release tags and gated artifacts
description: Public tags are immutable and the release workflow gates Docker and release publication on validation.
---

Treat a pushed release tag as permanent, even when its workflow fails; repair the branch and use the next prerelease identifier rather than moving or overwriting the tag.

**Why:** A failed public tag remains visible to users, while the release workflow intentionally prevents Docker and GitHub artifacts from being created until validation succeeds.

**How to apply:** Verify the full validation locally before tagging, then monitor the tag workflow through Docker publication, README sync, GitHub release, and any mirror jobs.
14 changes: 14 additions & 0 deletions .agents/memory/sast-false-positives.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
---
name: SAST false positives (analyzed)
description: Recurring SAST findings that were manually verified as false positives — skip re-analysis
---

## Verified false positives (July 2026 audit)

- **Path traversal HIGH in `server/services/imageService.ts`**: file writes use server-generated names (`poll-image-${uniqueSuffix}`), deletes use `path.basename()` on the URL — no user-controlled path segments reach the filesystem.
- **Path traversal HIGH in `server/services/whisperService.ts`**: temp file extensions come from `getExtensionFromMimeType()`, a hardcoded whitelist map (webm/mp3/wav/ogg/flac/m4a/mp4); unknown MIME types get a fixed default. Filenames are timestamp-based. The ffmpeg shell command only interpolates these safe paths.
- **Weak crypto (SHA-1) in `server/lib/totpService.ts`**: TOTP per RFC 6238 mandates HMAC-SHA1 — standard-compliant, not a weakness.
- **Session fixation in `server/routes/system.ts`**: only a `theme_preference` cookie read/write, no session material.
- **Hardcoded postgres strings in `.gitlab-ci.yml` / `docker-compose.yml` / `docker-entrypoint.sh`**: CI/dev-container defaults, documented in SELF-HOSTING guide; not production secrets.

**How to apply:** When a security scanner re-flags these locations with the same rule, verify the code hasn't changed materially (quick grep), then classify as known false positive instead of re-auditing from scratch.
9 changes: 9 additions & 0 deletions .agents/memory/simple-choice-mode.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
---
name: Simple choice response mode
description: Design decisions for polls' responseMode classic/simple (ballot-style single/multiple choice)
---

- `responseMode: 'classic' | 'simple'` on polls applies only to survey/schedule; organization and free-text options must reject simple mode. `maxSelections` (default 1) only meaningful in simple mode.
- **Why:** simple mode is backwards-compatible ballot voting (only 'yes' votes exist); results scoring/emails work unchanged because they count yes votes.
- **How to apply:** all simple-mode write paths (bulk vote and edit-token replacement) must go through `storage.replaceSimpleModeVotes` — a transaction with a per-voter advisory lock that re-reads and re-checks maxSelections. Sequential route-level validation alone is race-prone (code review caught concurrent submits exceeding the limit).
- Client reuses the existing `votes` record with only 'yes' entries in simple mode, so prefill/change-detection/cancel logic works without parallel state.
29 changes: 29 additions & 0 deletions .agents/memory/test-app-singleton-mfa.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
---
name: Test app singleton + MFA test session setup
description: createTestApp() is a module-level singleton; login BEFORE enabling MFA in storage to avoid TOTP challenge during test session setup
---

## Rule
`createTestApp()` in `server/tests/testApp.ts` is a **module-level singleton** — all `describe` blocks in a test file share the exact same Express app instance and the same in-memory MemoryStore session store.

**Why:** This is intentional for test performance (one app startup per worker). Sessions created in one describe block persist in the shared MemoryStore and are accessible to agents in subsequent describe blocks.

## MFA test pattern: login BEFORE enabling MFA
When a test needs an authenticated admin session AND the admin must have MFA enabled:

1. Call `loginAsAdmin(app)` **first** — while the admin has `totpEnabled = false`
2. **Then** call `storage.updateUser(adminId, { totpSecret, totpEnabled: true })` directly
3. Set policy (`adminMfaRequired = true`) after login

**Why:** If you enable MFA first and then try to log in, the login endpoint returns `{ requiresMfa: true }` with `pendingMfaUserId` in session (not `userId`). The subsequent protected endpoint calls will then fail with 401 because `requireAuth` checks `req.session.userId` not `pendingMfaUserId`.

## How to apply
- Any test that calls `storage.updateUser(id, { totpEnabled: true })` to set up test state must establish the session (login) BEFORE making that storage call.
- Use `loginAsAdmin(app)` for admin-role scenarios; it is reliable because it goes through the normal login endpoint which sets `req.session.userId`.
- After the test, restore MFA state: `storage.updateUser(adminId, { totpSecret: orig, totpEnabled: origEnabled, lastUsedTotpToken: null })`.
- Reference: `server/tests/auth/mfa.test.ts` — "Admin policy blocks self-disable" describe block.

## Test-user registration gotchas
- `registerSchema` caps usernames at 30 chars. Test usernames built as `prefix_${Date.now()}` carry a 13-digit epoch suffix, so prefixes longer than ~16 chars make registration fail with 400 (zod) — assert every setup response so this surfaces at the right line.
- **Why:** a hermetic-test rewrite failed only because `mfa_replay_disable_` + epoch = 32 chars; un-asserted setup steps turn such failures into misleading downstream assertion errors (e.g. 401-vs-400 from requireAuth).
- **How to apply:** when creating per-test users, keep the username prefix short (`mfa_rd_` style) and `expect(...).toBe(200)` every registration/setup response.
8 changes: 8 additions & 0 deletions .agents/memory/test-db-drift.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
name: Test vs dev database drift
description: Schema changes must reach both the vitest DB (DATABASE_URL) and the dev DB; drizzle push is interactive
---

- The vitest suite connects via `DATABASE_URL` (server/db.ts); it can be a different database than the one the dev workflow uses. A schema change applied to one DB still 500s in the other ("column ... does not exist").
- **Why:** hit when adding poll columns — dev API worked while tests failed with a Drizzle insert error.
- **How to apply:** after editing shared/schema.ts, apply the ALTER to both DBs (a small node/pg script is reliable) and add a numbered SQL file in `migrations/` plus a `migrations/meta/_journal.json` entry for self-hosters. `npm run db:push` can hang on interactive rename prompts (there is pre-existing drift like a `show_winner` column not in schema), so prefer explicit SQL.
10 changes: 10 additions & 0 deletions .agents/memory/vite-middleware-react-stability.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
---
name: Vite middleware React stability
description: Dev-server constraint for the app’s Vite middleware and optional Replit design instrumentation.
---

Do not enable Cartographer’s Vite development instrumentation for this application while it is served through the Express Vite middleware.

**Why:** The instrumentation can cause Vite to serve conflicting optimized dependency revisions during initial rendering. React DOM and hooks then execute from different module graphs, resulting in intermittent invalid-hook and missing-provider failures.

**How to apply:** Keep the ordinary React plugin and React/React DOM deduplication. If visual-design tooling is needed, use the dedicated mockup sandbox rather than injecting Cartographer into the application’s Vite server.
3 changes: 3 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,10 @@ test-results
# Documentation (not needed in container)
*.md
!README.md
!CHANGELOG.md
docs
!docs/openapi.yaml
!docs/SELF-HOSTING.md
TESTING.md
SELF-HOSTING.md
CONTRIBUTING.md
Expand Down
Loading
Loading