Repository navigation
feat(ui): the app shell pieces (ui 0.11.0) - #13
Merged
Merged
Conversation
A second app needs the shell the first one built, so its router-free half moves here: labels, icons and links come in as props (`renderLink`), and nothing imports a router, a message catalogue or an icon set. - SidebarFrame, NavGroup, NavItem: the quiet column, its groups and entries; `current` marks the page for the eye and for screen readers, `shortcut` shows on hover and focus. - TopbarRow, Breadcrumb: the 48 px bar, the trail ending with the page itself, the actions on the right. Positioning and phone stacking stay the app shell's (pass them through `className`). - PageTitle: the title row with its facts and the controls that change what the page shows. - QuickViews: the segmented control from the tablet up, scrolling chips on a phone. - FilterButton, FilterChipBar: the one « Filtres » button with its count, and the active filters as chips. The popover stays the app's; the button passes trigger props through, refs included. - PaginationBar, EmptyState, ErrorState, AuthFrame: previous / next with the position, the empty list, an error in the page's place, the bare page outside the shell.
A limit nearly reached reads as a warning, and one reached as danger, rather than turning the success colour once complete. Without the prop the ring is unchanged.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
A second app is about to use the shell the main app built, so its router-free half moves into the library. Everything takes its labels, icons and links as props (
renderLink, asPeriodStepperalready does); nothing imports a router, a message catalogue or an icon set.What's new
SidebarFrame,NavGroup,NavItemcurrentmarks the page for the eye and for screen readers (aria-current="page");shortcutshows aKbdon hover and focus.TopbarRow,BreadcrumbclassName.PageTitlemeta), and the controls that change what the page shows.QuickViewsFilterButton,FilterChipBarasChildtrigger works.PaginationBarEmptyStateErrorStateAuthFrameNot here, on purpose
FilterButton.animate-fade-in-upis an app utility; pass it throughclassNamewhere wanted.Checked
pnpm test: 72 tests, including a behaviour test per new piece, and the existing check that nothing imports a router.pnpm test:typecheckandpnpm build.biome check.Release:
ui-v0.11.0once merged.