@exxatdesignux/ui 0.1.0 → 0.2.7

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.
Files changed (155) hide show
  1. package/bin/cli.mjs +176 -0
  2. package/bin/init.mjs +15 -1
  3. package/bin/sync-extras.mjs +65 -0
  4. package/consumer-extras/README.md +21 -0
  5. package/consumer-extras/cursor-skills/exxat-accessibility/SKILL.md +282 -0
  6. package/consumer-extras/cursor-skills/exxat-board-cards/SKILL.md +68 -0
  7. package/consumer-extras/cursor-skills/exxat-centralized-list-dataset/SKILL.md +99 -0
  8. package/consumer-extras/cursor-skills/exxat-ds-skill/SKILL.md +713 -0
  9. package/consumer-extras/cursor-skills/exxat-fontawesome-icons/SKILL.md +31 -0
  10. package/consumer-extras/cursor-skills/exxat-list-page-view-shells/SKILL.md +36 -0
  11. package/consumer-extras/cursor-skills/exxat-primary-nav-secondary-panel/SKILL.md +27 -0
  12. package/consumer-extras/patterns/command-menu-pattern.md +45 -0
  13. package/consumer-extras/patterns/data-views-pattern.md +167 -0
  14. package/package.json +7 -3
  15. package/src/components/ui/sidebar.tsx +7 -2
  16. package/template/.agents/skills/shadcn/SKILL.md +242 -0
  17. package/template/.agents/skills/shadcn/agents/openai.yml +5 -0
  18. package/template/.agents/skills/shadcn/assets/shadcn-small.png +0 -0
  19. package/template/.agents/skills/shadcn/assets/shadcn.png +0 -0
  20. package/template/.agents/skills/shadcn/cli.md +257 -0
  21. package/template/.agents/skills/shadcn/customization.md +202 -0
  22. package/template/.agents/skills/shadcn/evals/evals.json +47 -0
  23. package/template/.agents/skills/shadcn/mcp.md +94 -0
  24. package/template/.agents/skills/shadcn/rules/base-vs-radix.md +306 -0
  25. package/template/.agents/skills/shadcn/rules/composition.md +195 -0
  26. package/template/.agents/skills/shadcn/rules/forms.md +192 -0
  27. package/template/.agents/skills/shadcn/rules/icons.md +101 -0
  28. package/template/.agents/skills/shadcn/rules/styling.md +162 -0
  29. package/template/.claude/skills/exxat-ds-skill/SKILL.md +712 -0
  30. package/template/.cursor/rules/exxat-accessibility.mdc +33 -0
  31. package/template/.cursor/rules/exxat-command-menu.mdc +23 -0
  32. package/template/.cursor/rules/exxat-dashboard-view-charts.mdc +53 -0
  33. package/template/.cursor/rules/exxat-data-tables.mdc +31 -0
  34. package/template/.cursor/rules/exxat-ds-agents.mdc +26 -0
  35. package/template/.cursor/rules/exxat-kbd-shortcuts.mdc +100 -0
  36. package/template/.cursor/rules/exxat-list-page-connected-views.mdc +16 -0
  37. package/template/.cursor/rules/exxat-no-toast.mdc +26 -0
  38. package/template/.cursor/rules/exxat-page-vs-drawer.mdc +22 -0
  39. package/template/.cursor/rules/exxat-table-properties-drawer.mdc +40 -0
  40. package/template/AGENTS.md +52 -11
  41. package/template/app/(app)/dashboard/page.tsx +1 -1
  42. package/template/app/(app)/data-list/[id]/page.tsx +24 -8
  43. package/template/app/(app)/data-list/new/page.tsx +7 -4
  44. package/template/app/(app)/data-list/page.tsx +1 -1
  45. package/template/app/(app)/examples/page.tsx +41 -0
  46. package/template/app/(app)/question-bank/page.tsx +3 -3
  47. package/template/app/globals.css +1 -1
  48. package/template/components/app-sidebar.tsx +52 -35
  49. package/template/components/compliance-table.tsx +79 -0
  50. package/template/components/data-list-client.tsx +36 -25
  51. package/template/components/data-list-table.tsx +797 -10
  52. package/template/components/data-views/finder-panel-view.tsx +405 -0
  53. package/template/components/data-views/folder-grid-view.tsx +86 -0
  54. package/template/components/data-views/index.ts +59 -0
  55. package/template/components/data-views/list-page-split-details-placeholder.tsx +39 -0
  56. package/template/components/data-views/list-page-split-hub-chrome.tsx +60 -0
  57. package/template/components/data-views/list-page-split-hub-tokens.ts +16 -0
  58. package/template/components/data-views/list-page-tree-column-header.tsx +31 -0
  59. package/template/components/data-views/list-page-tree-panel-shell.tsx +91 -0
  60. package/template/components/data-views/list-page-view-frame.tsx +53 -0
  61. package/template/components/data-views/os-folder-glyph.tsx +121 -0
  62. package/template/components/folder-details-shell.tsx +230 -0
  63. package/template/components/hub-tree-panel-view.tsx +672 -0
  64. package/template/components/list-hub-status-badge.tsx +17 -3
  65. package/template/components/page-header.tsx +149 -7
  66. package/template/components/placements-page-header.tsx +14 -8
  67. package/template/components/placements-table-columns.tsx +8 -8
  68. package/template/components/question-bank-client.tsx +157 -39
  69. package/template/components/question-bank-new-folder-sheet.tsx +248 -0
  70. package/template/components/question-bank-os-folder-view.tsx +648 -0
  71. package/template/components/question-bank-page-header.tsx +31 -2
  72. package/template/components/question-bank-panel-activator.tsx +9 -0
  73. package/template/components/question-bank-secondary-nav.tsx +226 -0
  74. package/template/components/question-bank-table.tsx +707 -22
  75. package/template/components/secondary-panel.tsx +41 -107
  76. package/template/components/sites-table.tsx +66 -0
  77. package/template/components/team-client.tsx +7 -0
  78. package/template/components/team-table.tsx +156 -1
  79. package/template/components/templates/list-page.tsx +2 -2
  80. package/template/components/ui/avatar.tsx +1 -1
  81. package/template/components/ui/badge.tsx +1 -1
  82. package/template/components/ui/banner.tsx +1 -1
  83. package/template/components/ui/breadcrumb.tsx +1 -1
  84. package/template/components/ui/button.tsx +1 -1
  85. package/template/components/ui/calendar.tsx +1 -1
  86. package/template/components/ui/card.tsx +1 -1
  87. package/template/components/ui/chart.tsx +1 -1
  88. package/template/components/ui/checkbox.tsx +1 -1
  89. package/template/components/ui/coach-mark.tsx +1 -1
  90. package/template/components/ui/collapsible.tsx +1 -1
  91. package/template/components/ui/command.tsx +1 -1
  92. package/template/components/ui/date-picker-field.tsx +1 -1
  93. package/template/components/ui/dialog.tsx +1 -1
  94. package/template/components/ui/drag-handle-grip.tsx +1 -1
  95. package/template/components/ui/drawer.tsx +1 -1
  96. package/template/components/ui/dropdown-menu.tsx +1 -1
  97. package/template/components/ui/field.tsx +1 -1
  98. package/template/components/ui/form.tsx +1 -1
  99. package/template/components/ui/input-group.tsx +1 -1
  100. package/template/components/ui/input-mask.tsx +1 -1
  101. package/template/components/ui/input.tsx +1 -1
  102. package/template/components/ui/kbd.tsx +1 -1
  103. package/template/components/ui/label.tsx +1 -1
  104. package/template/components/ui/payment-card-fields.tsx +1 -1
  105. package/template/components/ui/popover.tsx +1 -1
  106. package/template/components/ui/radio-group.tsx +1 -1
  107. package/template/components/ui/resizable.tsx +68 -0
  108. package/template/components/ui/select.tsx +1 -1
  109. package/template/components/ui/selection-tile-grid.tsx +1 -1
  110. package/template/components/ui/separator.tsx +1 -1
  111. package/template/components/ui/sheet.tsx +1 -1
  112. package/template/components/ui/sidebar.tsx +1 -1
  113. package/template/components/ui/skeleton.tsx +1 -1
  114. package/template/components/ui/sonner.tsx +1 -1
  115. package/template/components/ui/status-badge.tsx +1 -1
  116. package/template/components/ui/table.tsx +1 -1
  117. package/template/components/ui/tabs.tsx +1 -1
  118. package/template/components/ui/textarea.tsx +1 -1
  119. package/template/components/ui/tip.tsx +1 -1
  120. package/template/components/ui/toggle-group.tsx +1 -1
  121. package/template/components/ui/toggle-switch.tsx +1 -1
  122. package/template/components/ui/toggle.tsx +1 -1
  123. package/template/components/ui/tooltip.tsx +1 -1
  124. package/template/components/ui/view-segmented-control.tsx +1 -1
  125. package/template/docs/data-views-pattern.md +7 -0
  126. package/template/hooks/use-app-theme.ts +1 -1
  127. package/template/hooks/use-coach-mark.ts +1 -1
  128. package/template/hooks/use-location-hash.ts +15 -0
  129. package/template/hooks/use-mobile.ts +1 -1
  130. package/template/hooks/use-mod-key-label.ts +1 -1
  131. package/template/hooks/use-sidebar-reflow-zoom.ts +40 -0
  132. package/template/lib/ask-leo-route-context.ts +25 -57
  133. package/template/lib/coach-mark-registry.ts +13 -13
  134. package/template/lib/command-menu-config.ts +28 -23
  135. package/template/lib/command-menu-search-data.ts +10 -9
  136. package/template/lib/data-list-view-surface.ts +12 -1
  137. package/template/lib/data-list-view.ts +6 -3
  138. package/template/lib/date-filter.ts +1 -1
  139. package/template/lib/mock/dashboard.ts +11 -11
  140. package/template/lib/mock/navigation.tsx +22 -63
  141. package/template/lib/mock/placements-kpi.ts +19 -19
  142. package/template/lib/mock/question-bank-folders.ts +167 -0
  143. package/template/lib/mock/question-bank-header-collaborators.ts +14 -0
  144. package/template/lib/mock/question-bank-inspector.ts +109 -0
  145. package/template/lib/mock/question-bank-kpi.ts +1 -1
  146. package/template/lib/mock/question-bank.ts +80 -0
  147. package/template/lib/question-bank-nav.ts +91 -0
  148. package/template/lib/utils.ts +1 -1
  149. package/template/next.config.mjs +8 -0
  150. package/template/package.json +1 -0
  151. package/template/public/folders/icons8-folder-windows-11.svg +1 -0
  152. package/template/app/(app)/compliance/page.tsx +0 -10
  153. package/template/app/(app)/rotations/page.tsx +0 -15
  154. package/template/app/(app)/sites/all/page.tsx +0 -13
  155. package/template/app/(app)/team/page.tsx +0 -10
@@ -0,0 +1,101 @@
1
+ # Icons
2
+
3
+ **Always use the project's configured `iconLibrary` for imports.** Check the `iconLibrary` field from project context: `lucide` → `lucide-react`, `tabler` → `@tabler/icons-react`, etc. Never assume `lucide-react`.
4
+
5
+ ---
6
+
7
+ ## Icons in Button use data-icon attribute
8
+
9
+ Add `data-icon="inline-start"` (prefix) or `data-icon="inline-end"` (suffix) to the icon. No sizing classes on the icon.
10
+
11
+ **Incorrect:**
12
+
13
+ ```tsx
14
+ <Button>
15
+ <SearchIcon className="mr-2 size-4" />
16
+ Search
17
+ </Button>
18
+ ```
19
+
20
+ **Correct:**
21
+
22
+ ```tsx
23
+ <Button>
24
+ <SearchIcon data-icon="inline-start"/>
25
+ Search
26
+ </Button>
27
+
28
+ <Button>
29
+ Next
30
+ <ArrowRightIcon data-icon="inline-end"/>
31
+ </Button>
32
+ ```
33
+
34
+ ---
35
+
36
+ ## No sizing classes on icons inside components
37
+
38
+ Components handle icon sizing via CSS. Don't add `size-4`, `w-4 h-4`, or other sizing classes to icons inside `Button`, `DropdownMenuItem`, `Alert`, `Sidebar*`, or other shadcn components. Unless the user explicitly asks for custom icon sizes.
39
+
40
+ **Incorrect:**
41
+
42
+ ```tsx
43
+ <Button>
44
+ <SearchIcon className="size-4" data-icon="inline-start" />
45
+ Search
46
+ </Button>
47
+
48
+ <DropdownMenuItem>
49
+ <SettingsIcon className="mr-2 size-4" />
50
+ Settings
51
+ </DropdownMenuItem>
52
+ ```
53
+
54
+ **Correct:**
55
+
56
+ ```tsx
57
+ <Button>
58
+ <SearchIcon data-icon="inline-start" />
59
+ Search
60
+ </Button>
61
+
62
+ <DropdownMenuItem>
63
+ <SettingsIcon />
64
+ Settings
65
+ </DropdownMenuItem>
66
+ ```
67
+
68
+ ---
69
+
70
+ ## Pass icons as component objects, not string keys
71
+
72
+ Use `icon={CheckIcon}`, not a string key to a lookup map.
73
+
74
+ **Incorrect:**
75
+
76
+ ```tsx
77
+ const iconMap = {
78
+ check: CheckIcon,
79
+ alert: AlertIcon,
80
+ }
81
+
82
+ function StatusBadge({ icon }: { icon: string }) {
83
+ const Icon = iconMap[icon]
84
+ return <Icon />
85
+ }
86
+
87
+ <StatusBadge icon="check" />
88
+ ```
89
+
90
+ **Correct:**
91
+
92
+ ```tsx
93
+ // Import from the project's configured iconLibrary (e.g. lucide-react, @tabler/icons-react).
94
+ import { CheckIcon } from "lucide-react"
95
+
96
+ function StatusBadge({ icon: Icon }: { icon: React.ComponentType }) {
97
+ return <Icon />
98
+ }
99
+
100
+ <StatusBadge icon={CheckIcon} />
101
+ ```
@@ -0,0 +1,162 @@
1
+ # Styling & Customization
2
+
3
+ See [customization.md](../customization.md) for theming, CSS variables, and adding custom colors.
4
+
5
+ ## Contents
6
+
7
+ - Semantic colors
8
+ - Built-in variants first
9
+ - className for layout only
10
+ - No space-x-* / space-y-*
11
+ - Prefer size-* over w-* h-* when equal
12
+ - Prefer truncate shorthand
13
+ - No manual dark: color overrides
14
+ - Use cn() for conditional classes
15
+ - No manual z-index on overlay components
16
+
17
+ ---
18
+
19
+ ## Semantic colors
20
+
21
+ **Incorrect:**
22
+
23
+ ```tsx
24
+ <div className="bg-blue-500 text-white">
25
+ <p className="text-gray-600">Secondary text</p>
26
+ </div>
27
+ ```
28
+
29
+ **Correct:**
30
+
31
+ ```tsx
32
+ <div className="bg-primary text-primary-foreground">
33
+ <p className="text-muted-foreground">Secondary text</p>
34
+ </div>
35
+ ```
36
+
37
+ ---
38
+
39
+ ## No raw color values for status/state indicators
40
+
41
+ For positive, negative, or status indicators, use Badge variants, semantic tokens like `text-destructive`, or define custom CSS variables — don't reach for raw Tailwind colors.
42
+
43
+ **Incorrect:**
44
+
45
+ ```tsx
46
+ <span className="text-emerald-600">+20.1%</span>
47
+ <span className="text-green-500">Active</span>
48
+ <span className="text-red-600">-3.2%</span>
49
+ ```
50
+
51
+ **Correct:**
52
+
53
+ ```tsx
54
+ <Badge variant="secondary">+20.1%</Badge>
55
+ <Badge>Active</Badge>
56
+ <span className="text-destructive">-3.2%</span>
57
+ ```
58
+
59
+ If you need a success/positive color that doesn't exist as a semantic token, use a Badge variant or ask the user about adding a custom CSS variable to the theme (see [customization.md](../customization.md)).
60
+
61
+ ---
62
+
63
+ ## Built-in variants first
64
+
65
+ **Incorrect:**
66
+
67
+ ```tsx
68
+ <Button className="border border-input bg-transparent hover:bg-accent">
69
+ Click me
70
+ </Button>
71
+ ```
72
+
73
+ **Correct:**
74
+
75
+ ```tsx
76
+ <Button variant="outline">Click me</Button>
77
+ ```
78
+
79
+ ---
80
+
81
+ ## className for layout only
82
+
83
+ Use `className` for layout (e.g. `max-w-md`, `mx-auto`, `mt-4`), **not** for overriding component colors or typography. To change colors, use semantic tokens, built-in variants, or CSS variables.
84
+
85
+ **Incorrect:**
86
+
87
+ ```tsx
88
+ <Card className="bg-blue-100 text-blue-900 font-bold">
89
+ <CardContent>Dashboard</CardContent>
90
+ </Card>
91
+ ```
92
+
93
+ **Correct:**
94
+
95
+ ```tsx
96
+ <Card className="max-w-md mx-auto">
97
+ <CardContent>Dashboard</CardContent>
98
+ </Card>
99
+ ```
100
+
101
+ To customize a component's appearance, prefer these approaches in order:
102
+ 1. **Built-in variants** — `variant="outline"`, `variant="destructive"`, etc.
103
+ 2. **Semantic color tokens** — `bg-primary`, `text-muted-foreground`.
104
+ 3. **CSS variables** — define custom colors in the global CSS file (see [customization.md](../customization.md)).
105
+
106
+ ---
107
+
108
+ ## No space-x-* / space-y-*
109
+
110
+ Use `gap-*` instead. `space-y-4` → `flex flex-col gap-4`. `space-x-2` → `flex gap-2`.
111
+
112
+ ```tsx
113
+ <div className="flex flex-col gap-4">
114
+ <Input />
115
+ <Input />
116
+ <Button>Submit</Button>
117
+ </div>
118
+ ```
119
+
120
+ ---
121
+
122
+ ## Prefer size-* over w-* h-* when equal
123
+
124
+ `size-10` not `w-10 h-10`. Applies to icons, avatars, skeletons, etc.
125
+
126
+ ---
127
+
128
+ ## Prefer truncate shorthand
129
+
130
+ `truncate` not `overflow-hidden text-ellipsis whitespace-nowrap`.
131
+
132
+ ---
133
+
134
+ ## No manual dark: color overrides
135
+
136
+ Use semantic tokens — they handle light/dark via CSS variables. `bg-background text-foreground` not `bg-white dark:bg-gray-950`.
137
+
138
+ ---
139
+
140
+ ## Use cn() for conditional classes
141
+
142
+ Use the `cn()` utility from the project for conditional or merged class names. Don't write manual ternaries in className strings.
143
+
144
+ **Incorrect:**
145
+
146
+ ```tsx
147
+ <div className={`flex items-center ${isActive ? "bg-primary text-primary-foreground" : "bg-muted"}`}>
148
+ ```
149
+
150
+ **Correct:**
151
+
152
+ ```tsx
153
+ import { cn } from "@/lib/utils"
154
+
155
+ <div className={cn("flex items-center", isActive ? "bg-primary text-primary-foreground" : "bg-muted")}>
156
+ ```
157
+
158
+ ---
159
+
160
+ ## No manual z-index on overlay components
161
+
162
+ `Dialog`, `Sheet`, `Drawer`, `AlertDialog`, `DropdownMenu`, `Popover`, `Tooltip`, `HoverCard` handle their own stacking. Never add `z-50` or `z-[999]`.