Skip to content

Tailwind #57 — Admin asset CRUD

FieldValue
GitLabsourcecontrollers/safecall#57
Parent#52
Roadmaptailwind-roadmap.md
Depends on#55 (closed); prefer #56 done first
Workflowclosed

Goal

Migrate the repeated admin listing + modal CRUD pattern for users, devices, beacons, and gateways onto Tailwind catalog + utilities.

Design principles

  1. Shared listing/modal patterns should look consistent; extend catalog if the same structure repeats (listing toolbar, columns modal) rather than copy-paste utility walls.
  2. Forms: .field / .input / .select / .checkbox; buttons: .btn variants.
  3. Explicit soft/solid tags for status chips (online/offline, battery, etc.).

Acceptance criteria

  • [x] templates/admin/users/** + admin/pages/users.ts migrated
  • [x] templates/admin/devices/** + devices page / asset-replace modal migrated
  • [x] templates/admin/beacons/** + beacons page migrated
  • [x] templates/admin/gateways/** + gateways page migrated
  • [x] Columns modals / delete / edit / new modals in these areas use catalog modals
  • [x] Smoke: list + open edit modal for each entity type

Implementation notes

Largest shared pattern in the app (field/control/modal-card). Reuse helpers from #54. Dynamic tag/button class strings in TS must use catalog variants.

If this exceeds one context window, split into two child issues (e.g. users+devices vs beacons+gateways) and update the parent roadmap checklist.

Out of scope

WorkIssue
Locations / maps / zones / navigation#58
Eink / sensors overview#59
Admin tools#60

Key paths

  • web/src/templates/admin/{users,devices,beacons,gateways}/**
  • web/src/admin/pages/{users,devices,beacons,gateways,asset-replace-modal}.ts

Verification

  1. Web typecheck; run relevant E2E if specs cover these pages (bun test:e2e when practical).
  2. Smoke each listing + one modal flow.
  3. Grep those template dirs for button is-, columns, modal-card Bulma-only leftovers → 0.

Done when / handoff

  1. Operator verifies → commit with Closes #57 → push gitlab.
  2. Next: #58 admin spatial.