Skip to content

feat(aggregator): Tailwind + DaisyUI overhaul, Datastar theme toggle, 60s idleTimeout (Phase C) - #6155

Merged
dezren39 merged 1 commit into
mainfrom
feat/pm-ui-tailwind-daisyui
Nov 5, 2026
Merged

dezren39 merged 1 commit into
mainfrom
feat/pm-ui-tailwind-daisyui

Conversation

@dezren39

@dezren39 dezren39 commented Nov 5, 2026 •

Copy link
Copy Markdown
Member

Phase C of the pm-stack overhaul (#6153): rebuild the aggregator dashboard's presentation as a modern website — Tailwind CSS v4 + DaisyUI v5 + Datastar-first interactivity — keeping every function and every Phase B §14 contract.

What changed

  • CSS pipeline: tailwindcss + @tailwindcss/cli + daisyui devDependencies; source stylesheet src/ui.css (Tailwind v4 syntax, DaisyUI dark-default + light themes); bun run build:css builds the committed static asset src/assets/app.css (deploy needs no build step — pm-git-sync just pulls). Regeneration documented in the aggregator README ("Styling" section).
  • Page shell: the ~330-line inline const CSS is gone from render.ts (its rules moved verbatim into ui.css below the imports — the semantic hooks are contract and the suite pins many of them). layout() now links /assets/app.css (new route in server.ts, served like datastar.js), puts data-theme="dark" on <html>, and runs a tiny localStorage bootstrap before the stylesheet so a stored theme choice never flashes.
  • Theme toggle (Datastar): navbar toggle driven by a $pmTheme signal + data-init + data-effect (single writer of data-theme + localStorage["pm-theme"]); click only flips the signal. Explicit light/dark scoped rules in ui.css make the choice win over the OS scheme in both directions.
  • Components (DaisyUI/Tailwind classes added alongside existing hooks — ids, form actions/methods, button values, and exact class hooks tests pin are unchanged): navbar (navbar bg-base-200), pages dropdown (select select-bordered), nav + page search (input input-bordered, btn), quota refresh button (btn btn-primary), 18 data tables (table table-zebra; the two test-pinned tables left bare), card radius/shadow refinement in CSS. DaisyUI's own card/badge components now also style the existing class="card"/class="badge …" markup.
  • Datastar-more: the Pages dropdown's inline onchange is now data-on-change; the theme toggle is signals/effect/click. Fragment contract untouched: /frag/* still returns one datastar-patch-elements event, mode outer, same selectors/ids, roots keep data-on-load + data-on-dashrefresh__window.
  • Latency fix (Phase B §13.1): Bun.serve now sets idleTimeout: 60 so slow overview/board/queue fragments are not killed at the 10s default mid-render.

Deliberately NOT migrated

  • The quota-refresh poll script (poll /api/quota.json until generatedAt advances, with failure surfacing) stays bespoke JS: its semantics are not expressible as a Datastar fragment patch without new endpoints, and its endpoints (POST /api/quota/refresh, POST /quota/refresh → 303) are unchanged. The button itself is DaisyUI-styled.
  • <meter> quota bars stay <meter> (DaisyUI progress is a different element; legacy meter styling moved with the stylesheet).
  • Exact class attributes pinned by tests (class="card", class="badge …", nav class="active", aform class="primary" buttons) were not renamed; DaisyUI classes were added only where no pin exists.

Contract preservation (Phase B §14)

  • Actions/comments APIs: untouched, shapes unchanged. Provider-display rule: call sites and semantics untouched (renderQuota/renderTodayBody/deriveOverview). Aggregator still never posts to GitHub. /sw.js, manifest, icons, freshness IPC: untouched.
  • Tests that read the stylesheet from render.ts source (nav, a11y-1215, mobile-targets) now read src/ui.css + render.ts; the one rendered-HTML CSS assertion in render.test.ts now asserts the stylesheet link + the rule's presence in ui.css. New test/ui-overhaul.test.ts (10 tests) pins the shell, pipeline, and server changes.

Tests

  • bun test: full suite green (2008 pass / 0 fail on the clean run; an earlier loaded run showed 4 flaky hook-timeout failures that did not reproduce).
  • bunx tsc --noEmit: clean.
  • Worktree smoke (fixtures, spare port): /, /today, /attention, /quota, /assets/app.css all 200; /frag/overview patch format intact.

Swap plan: direct merge → pm-git-sync deploys → verify against the Phase B checklist; rollback is a revert of the merge commit (previous UI restores on the next sync).


Autofix with [code]smith
Open in [code]smith · Need help on this PR? Tag @codesmith-bot with what you need.

@dezren39
dezren39 requested a review from a team as a code owner November 5, 2026 08:25
@dezren39
dezren39 merged commit 2ec7501 into main Nov 5, 2026
@coderabbitai

coderabbitai Bot commented Nov 5, 2026

Copy link
Copy Markdown

Warning

Review limit reached

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Next included review available in 30 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available.

Learn how review limits work.

Review configuration:

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: ceaea6df-6370-4bb4-ac77-7dff022f4c42
Commits

Reviewing files that changed from the base of the PR and between 7e7b418 and 9396529.

Files ignored due to path filters: 1

  • pm-stack/aggregator/bun.lock is excluded by !**/*.lock
Files selected for processing: 11

  • pm-stack/aggregator/README.md
  • pm-stack/aggregator/package.json
  • pm-stack/aggregator/src/assets/app.css
  • pm-stack/aggregator/src/render.ts
  • pm-stack/aggregator/src/server.ts
  • pm-stack/aggregator/src/ui.css
  • pm-stack/aggregator/test/a11y-1215.test.ts
  • pm-stack/aggregator/test/mobile-targets.test.ts
  • pm-stack/aggregator/test/nav.test.ts
  • pm-stack/aggregator/test/render.test.ts
  • pm-stack/aggregator/test/ui-overhaul.test.ts
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

@dezren39
dezren39 deleted the feat/pm-ui-tailwind-daisyui branch November 5, 2026 08:26
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 5, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-05T08:27:15.894386Z 9396529 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant