Commit Graph

2 Commits

Author SHA1 Message Date
Ilya Mukhortov d7f7b3ecdb Open cards: fit tabs to width (max 4) with an "ещё N" menu
PageTabs shows as many card tabs as fit the bar width, at most
MAX_VISIBLE_TABS (4), measured from an invisible copy of the row and
recomputed on resize. The rest go into an "ещё N" dropdown where a
card can be opened or closed; the active card is always visible.
The sidebar uses the same split: all cards when there are up to five,
otherwise four plus "ещё N" with the same menu.

The close button inside menu items stops only click, not pointerdown:
otherwise Radix treats pointerup as an outside press and selects the
item, opening the card instead of closing it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-24 20:18:40 +10:00
Ilya Mukhortov 6d1a8719be Extract reusable kit components and add /ui showcase
Kit (src/components/kit): PageTabs, ContentTabs, PatientPanel, DataTable
with sorting, Pagination, FileGallery (image lightbox, PDF preview),
StatusBadge, StatTile, InfoSection/Field, DateLeaf, PageFrame, CodeBlock.
Patient pages now use them; search results are sortable; documents show
attachments. Replace next-themes with a small ThemeProvider (React 19
warned about its inline script).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-23 21:49:10 +10:00