2.0 KiB
2.0 KiB
UI Style Guide
This project uses a simple, data-first interface style.
Principles
- Keep information dense but readable.
- Use neutral surfaces and one primary accent.
- Avoid decorative complexity in monitoring views.
- Prioritize fast scanning of status, trend, and incident state.
Tokens
- Text:
- Primary:
#0f172a - Secondary:
#64748b
- Surface:
- Page background:
#f8fafc - Card background:
#ffffff - Border:
#dbe2eaor#e5e7eb
- Accent:
- Primary action:
#0ea5a2 - Primary hover:
#0b8a87
- State colors:
- Success:
#166534on#dcfce7 - Warning:
#92400eon#fef3c7 - Danger:
#b91c1c
Typography
- Base family: Manrope, IBM Plex Sans, Segoe UI, sans-serif.
- Use clear hierarchy:
- Page title: 2.2rem
- Section title: 1.5rem
- Body: 1rem
- Meta labels: 0.84rem to 0.9rem
Components
- Buttons
.btn-primaryfor create/confirm actions..btn-secondaryfor neutral actions (paging, toggles)..btn-dangerfor destructive actions..btn-compactfor table-row actions.
- Tables
- Use
.data-tableand.obs-tablepatterns. - Header row uses uppercase small labels.
- Right-align numeric columns with utility class (
.text-rightor.obs-right).
- Filters and controls
- Use
.section-controls+.filter-controlin detail pages. - Keep pagination controls grouped in
.controls-pagination.
Spacing and layout
- Standard spacing increments: 0.5rem, 0.75rem, 1rem, 1.5rem, 2rem.
- Keep card radius between 8px and 12px.
- Use 1px borders and light shadows for separation.
Responsiveness
- Collapse toolbar and filter rows under 768px.
- Convert 4-column stat grids to 2 columns at tablet and 1 column on small phones.
- Ensure action menus and inputs expand to full width on mobile.
Usage notes
- Prefer CSS classes over inline styles.
- Add new styles to page stylesheet first, then extract to shared patterns when repeated.
- Keep UI changes visual only unless explicitly requested to change behavior.