@utopia-studio-design/design-system-cli 0.3.1 → 0.3.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -23,6 +23,55 @@ Guide pages are the operating layer of Ceramic. They define how humans and AI ag
23
23
  - Guide pages must not put Utopia Default visual philosophy into reusable core rules.
24
24
  - Guide pages must link AI agents back to manifests, package exports, foundations, and Arabic-friendly rules.
25
25
 
26
+ ## Navigation Composition
27
+
28
+ Ceramic owns the visual primitives for standard product navigation. Consumers provide route labels and destinations, while the design system provides icons, collapsed behavior, tooltips, current-state treatment, and surface-aware Breadcrumb colors.
29
+
30
+ ```tsx
31
+ import {
32
+ Breadcrumb,
33
+ BreadcrumbItem,
34
+ BreadcrumbLink,
35
+ BreadcrumbList,
36
+ BreadcrumbPage,
37
+ BreadcrumbSeparator,
38
+ NavigationIcon,
39
+ PanelIcon,
40
+ SideNavCollapseButton,
41
+ } from '@utopia-studio-design/design-system/Navigation'
42
+ import {
43
+ SidebarMenuButton,
44
+ SidebarMenuItem,
45
+ } from '@utopia-studio-design/design-system/Sidebar'
46
+
47
+ <SideNavCollapseButton aria-expanded={!collapsed} aria-label="Collapse navigation">
48
+ <PanelIcon />
49
+ </SideNavCollapseButton>
50
+
51
+ <SidebarMenuItem>
52
+ <SidebarMenuButton activeVariant="both" isActive tooltip="Projects">
53
+ <NavigationIcon name="projects" />
54
+ <span>Projects</span>
55
+ </SidebarMenuButton>
56
+ </SidebarMenuItem>
57
+
58
+ <div style={{ background: 'var(--surface-inverse)' }}>
59
+ <Breadcrumb aria-label="Current location" variant="inverse">
60
+ <BreadcrumbList>
61
+ <BreadcrumbItem><BreadcrumbLink href="/">Home</BreadcrumbLink></BreadcrumbItem>
62
+ <BreadcrumbSeparator />
63
+ <BreadcrumbItem><BreadcrumbPage>Projects</BreadcrumbPage></BreadcrumbItem>
64
+ </BreadcrumbList>
65
+ </Breadcrumb>
66
+ </div>
67
+ ```
68
+
69
+ - Use `NavigationIcon` instead of an app-owned icon package or raw SVG for standard destinations.
70
+ - Keep `tooltip` on collapsed Sidebar items; it also supplies an accessible name when no explicit `aria-label` is provided.
71
+ - Use `activeVariant="indicator"` or `"both"` when current navigation needs the logical inline-start accent. The default `"background"` variant remains backward compatible.
72
+ - `isActive` supplies `aria-current="page"` unless the consumer explicitly provides another valid value.
73
+ - Use `Breadcrumb variant="inverse"` on `--surface-inverse`; do not remap `--foreground` or add component selectors in the consuming app.
74
+
26
75
  ## AI Rule
27
76
 
28
77
  Before generating UI, read:
@@ -481,6 +481,11 @@
481
481
  "--foreground",
482
482
  "--muted-foreground",
483
483
  "--foreground-subtle",
484
+ "--inverse-foreground",
485
+ "--inverse-foreground-muted",
486
+ "--inverse-foreground-subtle",
487
+ "--inverse-hover",
488
+ "--inverse-focus-ring",
484
489
  "--surface-hover",
485
490
  "--radius-control",
486
491
  "--space-2",
@@ -493,7 +498,8 @@
493
498
  "useWhen": [
494
499
  "A deep page needs parent-page context",
495
500
  "Users need to understand where the current resource sits in a hierarchy",
496
- "A long path may need collapsed middle items or an overflow menu"
501
+ "A long path may need collapsed middle items or an overflow menu",
502
+ "A top bar on --surface-inverse needs Ceramic-owned link, separator, current-page, hover, and focus colors"
497
503
  ],
498
504
  "avoidWhen": [
499
505
  "Primary navigation is needed; use Top Nav, Side Nav, or Navigation Menu",
@@ -508,6 +514,7 @@
508
514
  "ai": {
509
515
  "props": {
510
516
  "aria-label": "Required localized label for the breadcrumb navigation landmark.",
517
+ "variant": "Use default for ordinary surfaces and inverse when the Breadcrumb is placed on --surface-inverse.",
511
518
  "Breadcrumb": "Root nav landmark. Keep aria-label descriptive and localized when needed.",
512
519
  "BreadcrumbList": "Ordered list wrapper for breadcrumb items and separators.",
513
520
  "BreadcrumbItem": "List item wrapper for link, current page, or collapsed menu trigger.",
@@ -3624,7 +3631,7 @@
3624
3631
  "name": "Side Nav",
3625
3632
  "category": "Navigation",
3626
3633
  "status": "available",
3627
- "packageImport": "import { PanelIcon, SideNav, SideNavAccount, SideNavAuxiliary, SideNavCollapseButton, SideNavCommand, SideNavContent, SideNavFooter, SideNavHeader, SideNavHeading, SideNavItem, SideNavMain, SideNavNestedGroup, SideNavNestedItems, SideNavSearch, SideNavSection, SideNavStatus, SideNavWorkspaceSwitcher } from '@utopia-studio-design/design-system/Navigation';",
3634
+ "packageImport": "import { NavigationIcon, PanelIcon, SideNav, SideNavAccount, SideNavAuxiliary, SideNavCollapseButton, SideNavCommand, SideNavContent, SideNavFooter, SideNavHeader, SideNavHeading, SideNavItem, SideNavMain, SideNavNestedGroup, SideNavNestedItems, SideNavSearch, SideNavSection, SideNavStatus, SideNavWorkspaceSwitcher } from '@utopia-studio-design/design-system/Navigation';",
3628
3635
  "sourcePath": "packages/design-system/src/components/Navigation.tsx",
3629
3636
  "shadcnFoundation": [
3630
3637
  "sidebar",
@@ -3683,6 +3690,7 @@
3683
3690
  "SideNavSearch": "Package-owned search field for filtering navigation lists without local input styling.",
3684
3691
  "SideNavNestedGroup": "Groups a parent SideNavItem and its nested child collection.",
3685
3692
  "SideNavNestedItems": "Indented child item collection using logical inline-start spacing and border.",
3693
+ "NavigationIcon": "Official Ceramic destination icon set. Use names such as dashboard, projects, tasks, inbox, files, analytics, team, settings, and help without importing an app icon package.",
3686
3694
  "PanelIcon": "Direction-neutral icon exported for SideNavCollapseButton examples. Prefer it over directional arrows unless the directional icon has an RTL mirror rule."
3687
3695
  },
3688
3696
  "arabicFriendly": "Use logical start/end spacing in nested items and let document direction control order. Closed disclosure indicators rotate toward the inline start in LTR and RTL. Preserve scroll position when the side nav collapses and expands, and do not use left/right naming in generated side navigation layouts."
@@ -3948,6 +3956,8 @@
3948
3956
  "--foreground",
3949
3957
  "--border",
3950
3958
  "--surface-hover",
3959
+ "--primary",
3960
+ "--font-size-supporting",
3951
3961
  "--popover-surface",
3952
3962
  "--radius-control",
3953
3963
  "--radius-surface",
@@ -3997,6 +4007,11 @@
3997
4007
  "SidebarTrigger",
3998
4008
  "useSidebar"
3999
4009
  ],
4010
+ "props": {
4011
+ "SidebarMenuButton.activeVariant": "Use background for backward compatibility, indicator for a logical inline-start current marker, or both for the marker plus background.",
4012
+ "SidebarMenuButton.isActive": "Marks the item active and supplies aria-current=page unless the consumer provides another aria-current value.",
4013
+ "SidebarMenuButton.tooltip": "Provides collapsed hover/focus help and an accessible name when aria-label is omitted."
4014
+ },
4000
4015
  "arabicFriendly": "Use dir=rtl at the shell boundary and provide localized collapseLabel, expandLabel, overlay labels, rail labels, and tooltip strings. Logical borders, alignment, off-canvas motion, submenus, and badges mirror without changing the component API."
4001
4016
  }
4002
4017
  },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@utopia-studio-design/design-system-cli",
3
- "version": "0.3.1",
3
+ "version": "0.3.2",
4
4
  "description": "AI-readable CLI and MCP server for Ceramic Design System",
5
5
  "type": "module",
6
6
  "license": "MIT",