learning_ai_notes/docs
saravanakumardb1 0c982de7e6 feat(web/ui8): remove legacy global classes + tighten audit regex + lock CI gate
UI8 closes the migration cycle started by UI0. The four legacy global
classes (.surface-card, .surface-muted, .badge, .input-shell) are
removed from web/src/app/globals.css and the CI ratchet now enforces
zero new occurrences across three of the four drift categories.

Changes:

1. Audit regex precision (scripts/ui-drift-audit.sh, scripts/ui-drift-ratchet.sh)

   The previous pattern 'className="[^"]*(badge|surface-card|surface-muted|input-shell)'
   matched the literal token anywhere inside className, which caused 21
   false positives against Tailwind arbitrary values like
   'bg-[color:var(--nl-surface-muted)]' where the legacy name appears
   inside a 'var(--nl-...)' reference.

   New pattern requires the legacy class to be a whole class token —
   either at the start of className, or preceded by a space, and
   followed by a space or closing quote. Result: 21 false positives
   eliminated; the ratchet now reports an honest 0 for the legacy
   category.

2. globals.css cleanup (web/src/app/globals.css)

   Removed .surface-card, .surface-muted, .badge, .input-shell rules.
   Only truly global utilities remain (typography, focus-visible,
   sr-only, skip-link, motion preferences, layout grids). A header
   comment documents that re-introductions should be solved at the
   call-site with a primitive, not by restoring the global rule.

3. Ratchet baseline (scripts/ui-drift-baseline.json)

   Final counts after UI5–UI8 across the session:
     raw interactive controls       14   (was 38 at start)
     legacy global surface classes  0    (was 92 at start)
     hardcoded color literals       0    (no change, was already 0)
     direct @bytelyst/ui imports    0    (no change, was already 0)

   The 14 remaining raw controls are intentional and tracked:
     NoteEditor toolbar buttons (10)
     ArtifactPanel hidden file input (1)
     search/page radio inputs (2)
     NoteVersionsPanel disclosure button (1)

4. CI gate (.github/workflows/ci.yml release-guards job)

   Documented that the ratchet is the canonical gate post-UI8: because
   legacy/colors/imports baselines are 0, any new occurrence in those
   three categories now fails CI. The strict-audit script is kept as
   a local diagnostic tool but not wired as a gate (would fail on the
   14 intentional raw controls).

5. Roadmap (docs/UI_UX_PLATFORM_CORE_ROADMAP.md)

   Marked UI5, UI6, UI7, UI8 all complete with per-phase commit hashes
   and explicit deliverables.

Cumulative migration impact (from initial baseline):
   raw interactive controls       38 → 14   (-24, -63%)
   legacy global surface classes  92 → 0    (-92, -100%)

Verified:
- pnpm run verify: backend 380/380, web 96/96, mobile 97/97
- bash scripts/ui-drift-ratchet.sh: all four categories at baseline
- bash scripts/ui-drift-audit.sh: only "Raw interactive controls"
  category has matches (intentional, tracked above)
- Live Docker stack at http://localhost:3050 still serves 200,
  backend health 200
2026-05-23 01:55:36 -07:00
..
archive docs(cleanup): move historical roadmaps to docs/archive/ and update AGENTS.md 2026-05-22 23:23:50 -07:00
roadmaps docs(cleanup): move historical roadmaps to docs/archive/ and update AGENTS.md 2026-05-22 23:23:50 -07:00
runbooks docs(runbooks): add MEK rotation and secret-management runbooks 2026-05-22 23:23:38 -07:00
testing test(e2e): docker compose E2E test + seed scripts + 9-step verification 2026-05-23 01:16:19 -07:00
BACKEND_LLM_ROUTER_DECISION.md docs(backend): defer llm router adoption 2026-05-05 09:37:22 -07:00
COSMOS_DATA_OPERATIONS.md docs(data): add migration backfill plan 2026-05-05 13:48:52 -07:00
COSMOS_QUERY_REVIEW.md docs(data): add cosmos operations runbook 2026-05-05 13:38:58 -07:00
DATA_MIGRATION_AND_BACKFILL_PLAN.md docs(data): add migration backfill plan 2026-05-05 13:48:52 -07:00
DEEP_LINKS.md feat: implement WEB_AI_FAST_ROADMAP (web + backend + docs) 2026-03-31 13:00:36 -07:00
FIELD_ENCRYPTION_COVERAGE.md docs(data): add migration backfill plan 2026-05-05 13:48:52 -07:00
IMPLEMENTATION_TRACKER.md docs(cleanup): move historical roadmaps to docs/archive/ and update AGENTS.md 2026-05-22 23:23:50 -07:00
IMPORT_EXPORT_READINESS.md feat(notes): harden import export readiness 2026-05-05 12:15:11 -07:00
MEMPALACE_INTEGRATION_ROADMAP.md docs(palace): update roadmap — mark all phases complete with commit hashes + test counts 2026-04-10 10:22:42 -07:00
MOBILE_DELEGATION_ROADMAP.md docs(mobile): defer sync engine adoption 2026-05-05 09:35:47 -07:00
MOBILE_PLATFORM_SDK_DECISION.md docs(mobile): defer react native platform sdk 2026-05-05 09:34:34 -07:00
MOBILE_PRODUCTION_BUILD_AND_SMOKE.md docs(mobile): add production build smoke checklist 2026-05-05 13:23:47 -07:00
MOBILE_SYNC_DECISION.md docs(mobile): defer sync engine adoption 2026-05-05 09:35:47 -07:00
NEXT_SPRINT_ROADMAP.md docs(sprint-a): record build restoration and refreshed sprint plan 2026-05-22 15:08:42 -07:00
OPERATOR_RUNBOOK.md docs(ops): add operator runbook 2026-05-05 13:53:59 -07:00
PLATFORM_SMOKE_CHECKS.md chore(platform): add local smoke script 2026-05-05 09:29:42 -07:00
PRD.md feat(identity): lock NoteLett product identity across all surfaces 2026-03-10 18:47:01 -07:00
PRODUCTION_READINESS_HANDOFF_ROADMAP.md docs(p10.5): live shared-service smoke verified end-to-end May 23, 2026 2026-05-23 00:30:44 -07:00
RELEASE_CHECKLIST.md docs(ops): add operator runbook 2026-05-05 13:53:59 -07:00
ROADMAP.md docs(release): record final handoff status 2026-05-05 14:20:15 -07:00
SEED_BOOTSTRAP_STRATEGY.md docs(data): add migration backfill plan 2026-05-05 13:48:52 -07:00
SMART_ACTIONS_ROADMAP.md docs: update AGENTS.md test counts and SMART_ACTIONS_ROADMAP Phase 6 status (G20) 2026-04-06 13:44:41 -07:00
SMART_ACTIONS_USER_GUIDE.md feat(smart-actions): add run-stream SSE, history endpoint, weekly-digest template, web client functions (G1-G5) 2026-04-06 13:27:02 -07:00
TELEMETRY_AND_DIAGNOSTICS_TAXONOMY.md docs(ops): define telemetry taxonomy 2026-05-05 13:51:28 -07:00
UI_UX_PLATFORM_CORE_ROADMAP.md feat(web/ui8): remove legacy global classes + tighten audit regex + lock CI gate 2026-05-23 01:55:36 -07:00
UX_TESTING_SETUP_GUIDE.md feat(ux): add UX testing setup guide and common platform integration 2026-05-09 22:09:43 +00:00
WEB_AI_FAST_ROADMAP.md feat: implement WEB_AI_FAST_ROADMAP (web + backend + docs) 2026-03-31 13:00:36 -07:00