@godxjp/ui 19.0.0 → 19.2.0

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 (445) hide show
  1. package/README.md +25 -128
  2. package/dist/app/app-provider.d.ts +1 -1
  3. package/dist/app/app-provider.js +3 -0
  4. package/dist/app/theme-axes.d.ts +4 -15
  5. package/dist/app/timezones.d.ts +1 -4
  6. package/dist/components/charts/area-chart.d.ts +2 -3
  7. package/dist/components/charts/bar-chart.d.ts +2 -3
  8. package/dist/components/charts/chart-frame.d.ts +7 -16
  9. package/dist/components/charts/chart-summary.d.ts +2 -2
  10. package/dist/components/charts/compact-bar-trend.d.ts +9 -24
  11. package/dist/components/charts/index.d.ts +1 -6
  12. package/dist/components/data-display/badge.d.ts +2 -12
  13. package/dist/components/data-display/card.d.ts +21 -41
  14. package/dist/components/data-display/carousel.d.ts +1 -2
  15. package/dist/components/data-display/code-block.d.ts +4 -0
  16. package/dist/components/data-display/code-block.js +24 -0
  17. package/dist/components/data-display/data-table.d.ts +15 -37
  18. package/dist/components/data-display/data-table.js +1 -3
  19. package/dist/components/data-display/descriptions.d.ts +2 -6
  20. package/dist/components/data-display/descriptions.js +0 -2
  21. package/dist/components/data-display/index.d.ts +4 -0
  22. package/dist/components/data-display/index.js +4 -0
  23. package/dist/components/data-display/list-row.d.ts +3 -22
  24. package/dist/components/data-display/permission-matrix.d.ts +7 -20
  25. package/dist/components/data-display/progress.d.ts +1 -1
  26. package/dist/components/data-display/prose.d.ts +4 -0
  27. package/dist/components/data-display/prose.js +20 -0
  28. package/dist/components/data-display/service-launcher-card.d.ts +3 -10
  29. package/dist/components/data-display/table.d.ts +20 -80
  30. package/dist/components/data-display/table.js +0 -3
  31. package/dist/components/data-display/timeline.d.ts +3 -5
  32. package/dist/components/data-entry/branch-scope-picker.d.ts +2 -19
  33. package/dist/components/data-entry/branch-scope-picker.js +0 -1
  34. package/dist/components/data-entry/calendar.d.ts +3 -2
  35. package/dist/components/data-entry/calendar.js +58 -3
  36. package/dist/components/data-entry/cascader.js +3 -1
  37. package/dist/components/data-entry/checkbox-group.js +12 -5
  38. package/dist/components/data-entry/checkbox.js +30 -21
  39. package/dist/components/data-entry/command-palette.d.ts +8 -22
  40. package/dist/components/data-entry/date-picker.d.ts +4 -5
  41. package/dist/components/data-entry/date-picker.js +12 -3
  42. package/dist/components/data-entry/date-range-picker.d.ts +1 -1
  43. package/dist/components/data-entry/date-range-picker.js +17 -6
  44. package/dist/components/data-entry/form-errors.d.ts +7 -18
  45. package/dist/components/data-entry/form-field.d.ts +1 -1
  46. package/dist/components/data-entry/form-field.js +15 -6
  47. package/dist/components/data-entry/form.d.ts +1 -9
  48. package/dist/components/data-entry/input.d.ts +16 -14
  49. package/dist/components/data-entry/input.js +13 -3
  50. package/dist/components/data-entry/month-picker.js +6 -4
  51. package/dist/components/data-entry/month-range-picker.d.ts +4 -6
  52. package/dist/components/data-entry/month-range-picker.js +11 -5
  53. package/dist/components/data-entry/number-input.d.ts +1 -5
  54. package/dist/components/data-entry/number-input.js +1 -0
  55. package/dist/components/data-entry/radio.js +19 -6
  56. package/dist/components/data-entry/search-select.d.ts +3 -5
  57. package/dist/components/data-entry/search-select.js +8 -2
  58. package/dist/components/data-entry/select.d.ts +15 -2
  59. package/dist/components/data-entry/select.js +57 -10
  60. package/dist/components/data-entry/switch.js +9 -2
  61. package/dist/components/data-entry/textarea.d.ts +10 -16
  62. package/dist/components/data-entry/textarea.js +8 -1
  63. package/dist/components/data-entry/time-picker.d.ts +3 -5
  64. package/dist/components/data-entry/tree-select.js +3 -1
  65. package/dist/components/data-entry/upload-types.d.ts +1 -5
  66. package/dist/components/data-entry/use-upload-draft.d.ts +0 -4
  67. package/dist/components/feedback/dialog.d.ts +6 -15
  68. package/dist/components/feedback/overlay-header-tone.d.ts +1 -1
  69. package/dist/components/feedback/sheet.d.ts +3 -10
  70. package/dist/components/feedback/sheet.js +1 -1
  71. package/dist/components/feedback/sonner.js +2 -3
  72. package/dist/components/general/activity.d.ts +4 -30
  73. package/dist/components/general/button.js +1 -10
  74. package/dist/components/general/logo.d.ts +6 -28
  75. package/dist/components/general/reveal.d.ts +3 -9
  76. package/dist/components/general/typography.d.ts +1 -3
  77. package/dist/components/layout/account-chip.d.ts +8 -0
  78. package/dist/components/layout/account-chip.js +45 -0
  79. package/dist/components/layout/auth-divider.d.ts +2 -9
  80. package/dist/components/layout/auth-shell.d.ts +1 -14
  81. package/dist/components/layout/breadcrumb.d.ts +1 -5
  82. package/dist/components/layout/centered-shell.d.ts +4 -18
  83. package/dist/components/layout/error-surface.d.ts +11 -28
  84. package/dist/components/layout/error-surface.js +4 -1
  85. package/dist/components/layout/index.d.ts +2 -0
  86. package/dist/components/layout/index.js +2 -0
  87. package/dist/components/layout/legal-document-shell.d.ts +5 -28
  88. package/dist/components/layout/master-detail.d.ts +2 -18
  89. package/dist/components/layout/page-container.js +0 -1
  90. package/dist/components/layout/responsive-grid.d.ts +6 -1
  91. package/dist/components/layout/responsive-grid.js +9 -2
  92. package/dist/components/layout/service-role-panel.d.ts +7 -19
  93. package/dist/components/layout/sidebar.d.ts +5 -27
  94. package/dist/components/layout/sidebar.js +0 -1
  95. package/dist/components/layout/split-pane.d.ts +0 -7
  96. package/dist/components/layout/topbar.d.ts +1 -14
  97. package/dist/components/navigation/app-setting-picker.js +1 -3
  98. package/dist/components/navigation/filter-bar.d.ts +1 -6
  99. package/dist/components/navigation/pagination-utils.d.ts +2 -12
  100. package/dist/components/navigation/tabs-scroll.d.ts +2 -36
  101. package/dist/components/navigation/tabs.js +4 -8
  102. package/dist/components/query/data-state.d.ts +2 -2
  103. package/dist/components/ui/credential-reveal.d.ts +1 -4
  104. package/dist/components/ui/hover-card.d.ts +1 -2
  105. package/dist/components/ui/separator.d.ts +2 -15
  106. package/dist/components/ui/toggle-group.d.ts +1 -5
  107. package/dist/components/ui/toggle.d.ts +6 -31
  108. package/dist/email/brand-mark.d.ts +6 -34
  109. package/dist/email/color.d.ts +7 -17
  110. package/dist/email/geometry.d.ts +4 -8
  111. package/dist/email/index.d.ts +4 -48
  112. package/dist/email/inline-style.d.ts +3 -9
  113. package/dist/email/urgency.d.ts +2 -7
  114. package/dist/form/form-context.d.ts +2 -5
  115. package/dist/form/form-root.d.ts +1 -2
  116. package/dist/i18n/messages/en.json +4 -0
  117. package/dist/i18n/messages/ja.json +4 -0
  118. package/dist/i18n/messages/vi.json +4 -0
  119. package/dist/inertia/index.d.ts +2 -10
  120. package/dist/lib/control-styles.d.ts +10 -21
  121. package/dist/lib/control-styles.js +4 -6
  122. package/dist/lib/datetime/format-date.d.ts +1 -4
  123. package/dist/lib/field-a11y.d.ts +31 -36
  124. package/dist/lib/field-a11y.js +16 -2
  125. package/dist/lib/format.d.ts +4 -8
  126. package/dist/lib/hooks.d.ts +6 -12
  127. package/dist/lib/permission-grid.d.ts +3 -18
  128. package/dist/lib/query-error.d.ts +3 -3
  129. package/dist/props/components/app.prop.d.ts +19 -27
  130. package/dist/props/components/charts.prop.d.ts +2 -3
  131. package/dist/props/components/data-display.prop.d.ts +48 -72
  132. package/dist/props/components/data-entry.prop.d.ts +41 -30
  133. package/dist/props/components/form.prop.d.ts +2 -6
  134. package/dist/props/components/general.prop.d.ts +11 -27
  135. package/dist/props/components/layout.prop.d.ts +89 -260
  136. package/dist/props/components/navigation.prop.d.ts +27 -42
  137. package/dist/props/registry.d.ts +31 -0
  138. package/dist/props/registry.js +33 -0
  139. package/dist/props/vocabulary/data.prop.d.ts +18 -49
  140. package/dist/props/vocabulary/index.d.ts +1 -1
  141. package/dist/props/vocabulary/interaction.prop.d.ts +10 -12
  142. package/dist/props/vocabulary/layout.prop.d.ts +8 -30
  143. package/dist/props/vocabulary/shared.prop.d.ts +3 -2
  144. package/dist/styles/alert-layout.css +1 -32
  145. package/dist/styles/badge-layout.css +4 -18
  146. package/dist/styles/base.css +14 -113
  147. package/dist/styles/card-layout.css +6 -128
  148. package/dist/styles/chart-layout.css +2 -17
  149. package/dist/styles/control.css +380 -458
  150. package/dist/styles/core.css +21 -0
  151. package/dist/styles/data-display-layout.css +175 -94
  152. package/dist/styles/data-entry-layout.css +0 -45
  153. package/dist/styles/density.css +1 -30
  154. package/dist/styles/dialog-layout.css +5 -69
  155. package/dist/styles/focus-ring.css +13 -87
  156. package/dist/styles/fonts.css +1 -31
  157. package/dist/styles/form-layout.css +7 -91
  158. package/dist/styles/index.css +2 -20
  159. package/dist/styles/layout.css +38 -456
  160. package/dist/styles/logo-layout.css +1 -35
  161. package/dist/styles/motion.css +3 -42
  162. package/dist/styles/navigation-layout.css +3 -50
  163. package/dist/styles/shell-layout.css +37 -403
  164. package/dist/styles/table-layout.css +16 -274
  165. package/dist/styles/text-layout.css +7 -21
  166. package/dist/styles/toggle.css +1 -23
  167. package/dist/theme/dxs.canonical.css +1 -55
  168. package/dist/theme/example.service.css +1 -26
  169. package/dist/theme/famgia.service.css +5 -15
  170. package/dist/tokens/axes.css +3 -40
  171. package/dist/tokens/base.css +1 -4
  172. package/dist/tokens/components/activity.css +6 -42
  173. package/dist/tokens/components/badge.css +4 -13
  174. package/dist/tokens/components/banner.css +4 -9
  175. package/dist/tokens/components/card.css +32 -88
  176. package/dist/tokens/components/chart.css +9 -26
  177. package/dist/tokens/components/control.css +37 -222
  178. package/dist/tokens/components/data-display.css +28 -79
  179. package/dist/tokens/components/data-entry.css +5 -19
  180. package/dist/tokens/components/descriptions.css +7 -27
  181. package/dist/tokens/components/email.css +38 -84
  182. package/dist/tokens/components/error-surface.css +2 -18
  183. package/dist/tokens/components/feedback.css +27 -124
  184. package/dist/tokens/components/form.css +13 -45
  185. package/dist/tokens/components/legal-document.css +16 -41
  186. package/dist/tokens/components/list-row.css +11 -36
  187. package/dist/tokens/components/logo.css +2 -57
  188. package/dist/tokens/components/navigation.css +16 -94
  189. package/dist/tokens/components/scroll-area.css +2 -18
  190. package/dist/tokens/components/separator.css +8 -30
  191. package/dist/tokens/components/sheet.css +3 -14
  192. package/dist/tokens/components/shell.css +53 -307
  193. package/dist/tokens/components/sidebar.css +5 -22
  194. package/dist/tokens/components/table.css +19 -140
  195. package/dist/tokens/components/toggle.css +3 -65
  196. package/dist/tokens/components/upload.css +7 -43
  197. package/dist/tokens/foundation.css +108 -383
  198. package/dist/tokens/semantic/layout.css +33 -207
  199. package/docs/CANONICAL-CONTRACTS.md +206 -0
  200. package/docs/COMPONENTS.md +157 -0
  201. package/docs/COMPOSITION-VS-COMPONENT.md +105 -0
  202. package/docs/CONSUMER-RULES.md +14 -0
  203. package/docs/CUSTOMER-THEMING.md +162 -0
  204. package/docs/DATETIME.md +69 -0
  205. package/docs/DEVELOPMENT.md +173 -0
  206. package/docs/FORMS.md +143 -0
  207. package/docs/FRAME-A11Y-CI.md +267 -0
  208. package/docs/FRAME-COVERAGE-LEDGER.md +123 -0
  209. package/docs/FRAME-COVERAGE-REPORT.md +140 -0
  210. package/docs/FRAME-COVERAGE-STANDARD.md +65 -0
  211. package/docs/FRAME-COVERAGE.md +29 -0
  212. package/docs/PROPS-REGISTRY.md +61 -0
  213. package/docs/PROPS-VOCABULARY.md +100 -0
  214. package/docs/README.md +60 -0
  215. package/docs/REGISTRY.md +70 -0
  216. package/docs/SPACING.md +56 -0
  217. package/docs/STANDARDS-vocabulary-tokens.md +48 -0
  218. package/docs/TESTING.md +98 -0
  219. package/docs/TOKENS.md +347 -0
  220. package/docs/asset-modules.d.ts +46 -0
  221. package/docs/assets/cover-terrain.svg +6 -0
  222. package/docs/assets/portrait-amber.svg +5 -0
  223. package/docs/assets/portrait-clay.svg +5 -0
  224. package/docs/assets/portrait-indigo.svg +5 -0
  225. package/docs/assets/portrait-iris.svg +5 -0
  226. package/docs/assets/portrait-moss.svg +5 -0
  227. package/docs/assets/portrait-plum.svg +5 -0
  228. package/docs/assets/portrait-slate.svg +5 -0
  229. package/docs/charts/compact-bar-trend.tsx +328 -0
  230. package/docs/charts/size-tiers.tsx +192 -0
  231. package/docs/data-display/accordion.tsx +99 -0
  232. package/docs/data-display/avatar.tsx +355 -0
  233. package/docs/data-display/badge.tsx +247 -0
  234. package/docs/data-display/card/examples/detail-panel.tsx +106 -0
  235. package/docs/data-display/card/index.md +3 -0
  236. package/docs/data-display/card/index.tsx +285 -0
  237. package/docs/data-display/carousel.tsx +156 -0
  238. package/docs/data-display/charts.tsx +198 -0
  239. package/docs/data-display/code-block.tsx +90 -0
  240. package/docs/data-display/collapsible.tsx +162 -0
  241. package/docs/data-display/credential-reveal.tsx +145 -0
  242. package/docs/data-display/data-table/examples/approval-queue.tsx +212 -0
  243. package/docs/data-display/data-table/examples/grid-features.tsx +158 -0
  244. package/docs/data-display/data-table/examples/list-page.tsx +175 -0
  245. package/docs/data-display/data-table/index.md +5 -0
  246. package/docs/data-display/data-table/index.tsx +295 -0
  247. package/docs/data-display/descriptions.tsx +143 -0
  248. package/docs/data-display/empty-state.tsx +164 -0
  249. package/docs/data-display/hover-card.tsx +181 -0
  250. package/docs/data-display/list-row.tsx +420 -0
  251. package/docs/data-display/permission-matrix.tsx +184 -0
  252. package/docs/data-display/popover-touch.tsx +27 -0
  253. package/docs/data-display/popover.tsx +245 -0
  254. package/docs/data-display/progress.tsx +84 -0
  255. package/docs/data-display/prose.tsx +105 -0
  256. package/docs/data-display/qr-code.tsx +68 -0
  257. package/docs/data-display/scroll-area.tsx +271 -0
  258. package/docs/data-display/service-launcher-card.tsx +145 -0
  259. package/docs/data-display/stat-card.tsx +99 -0
  260. package/docs/data-display/table.tsx +251 -0
  261. package/docs/data-display/timeline.tsx +112 -0
  262. package/docs/data-display/touch-actions.tsx +36 -0
  263. package/docs/data-display/tree-list.tsx +107 -0
  264. package/docs/data-entry/branch-scope-picker.tsx +123 -0
  265. package/docs/data-entry/calendar.tsx +180 -0
  266. package/docs/data-entry/cascader.tsx +378 -0
  267. package/docs/data-entry/checkbox.tsx +256 -0
  268. package/docs/data-entry/color-picker.tsx +117 -0
  269. package/docs/data-entry/command-palette.tsx +179 -0
  270. package/docs/data-entry/command.tsx +262 -0
  271. package/docs/data-entry/country-picker-recipe.tsx +170 -0
  272. package/docs/data-entry/date-picker.tsx +191 -0
  273. package/docs/data-entry/date-range-picker.tsx +149 -0
  274. package/docs/data-entry/form/examples/employee-settings.tsx +267 -0
  275. package/docs/data-entry/form/examples/invoice-form.tsx +387 -0
  276. package/docs/data-entry/form-field/examples/a11y-contract.tsx +240 -0
  277. package/docs/data-entry/form-field/examples/create-form.tsx +105 -0
  278. package/docs/data-entry/form-field/index.md +8 -0
  279. package/docs/data-entry/form-field/index.tsx +326 -0
  280. package/docs/data-entry/form-inertia.tsx +80 -0
  281. package/docs/data-entry/form-root.tsx +102 -0
  282. package/docs/data-entry/form.tsx +724 -0
  283. package/docs/data-entry/input-otp.tsx +231 -0
  284. package/docs/data-entry/input.tsx +114 -0
  285. package/docs/data-entry/label.tsx +100 -0
  286. package/docs/data-entry/month-picker.tsx +101 -0
  287. package/docs/data-entry/month-range-picker.tsx +115 -0
  288. package/docs/data-entry/number-input.tsx +240 -0
  289. package/docs/data-entry/password-input.tsx +106 -0
  290. package/docs/data-entry/password-strength.tsx +97 -0
  291. package/docs/data-entry/radio-group.tsx +95 -0
  292. package/docs/data-entry/rating.tsx +87 -0
  293. package/docs/data-entry/search-input.tsx +120 -0
  294. package/docs/data-entry/select-async-contracts.tsx +108 -0
  295. package/docs/data-entry/select-matrix.tsx +204 -0
  296. package/docs/data-entry/select.tsx +369 -0
  297. package/docs/data-entry/slider.tsx +130 -0
  298. package/docs/data-entry/switch.tsx +67 -0
  299. package/docs/data-entry/tag-input.tsx +108 -0
  300. package/docs/data-entry/textarea.tsx +209 -0
  301. package/docs/data-entry/time-picker.tsx +99 -0
  302. package/docs/data-entry/toggle-count.tsx +293 -0
  303. package/docs/data-entry/toggle-group.tsx +225 -0
  304. package/docs/data-entry/toggle.tsx +127 -0
  305. package/docs/data-entry/transfer.tsx +97 -0
  306. package/docs/data-entry/tree-select.tsx +204 -0
  307. package/docs/data-entry/upload.tsx +184 -0
  308. package/docs/feedback/alert-dialog.tsx +270 -0
  309. package/docs/feedback/alert.tsx +248 -0
  310. package/docs/feedback/banner.tsx +183 -0
  311. package/docs/feedback/danger-confirm.tsx +88 -0
  312. package/docs/feedback/dialog-touch.tsx +24 -0
  313. package/docs/feedback/dialog.tsx +193 -0
  314. package/docs/feedback/sheet.tsx +410 -0
  315. package/docs/feedback/skeleton.tsx +111 -0
  316. package/docs/feedback/toast.tsx +135 -0
  317. package/docs/feedback/tooltip.tsx +171 -0
  318. package/docs/feedback/two-factor-setup.tsx +68 -0
  319. package/docs/foundation/_email-specimen.ts +274 -0
  320. package/docs/foundation/colors.tsx +202 -0
  321. package/docs/foundation/density.tsx +232 -0
  322. package/docs/foundation/email-tokens.tsx +306 -0
  323. package/docs/foundation/radius-shadow.tsx +152 -0
  324. package/docs/foundation/spacing.tsx +211 -0
  325. package/docs/foundation/typography.tsx +147 -0
  326. package/docs/general/activity.tsx +224 -0
  327. package/docs/general/button/examples/destructive-confirm.tsx +90 -0
  328. package/docs/general/button/examples/form-actions.tsx +85 -0
  329. package/docs/general/button/examples/toolbar.tsx +160 -0
  330. package/docs/general/button/index.md +12 -0
  331. package/docs/general/button/index.tsx +211 -0
  332. package/docs/general/logo.tsx +131 -0
  333. package/docs/general/reveal.tsx +41 -0
  334. package/docs/general/typography.tsx +152 -0
  335. package/docs/layout/account-chip.tsx +72 -0
  336. package/docs/layout/admin-collection.tsx +122 -0
  337. package/docs/layout/app-shell.tsx +374 -0
  338. package/docs/layout/aspect-ratio.tsx +119 -0
  339. package/docs/layout/auth-account-summary.tsx +103 -0
  340. package/docs/layout/auth-divider.tsx +28 -0
  341. package/docs/layout/auth-footer.tsx +37 -0
  342. package/docs/layout/auth-identity.tsx +36 -0
  343. package/docs/layout/auth-recovery/examples/mfa-challenge.md +41 -0
  344. package/docs/layout/auth-recovery/examples/mfa-challenge.tsx +254 -0
  345. package/docs/layout/auth-recovery/examples/mobile-390.md +25 -0
  346. package/docs/layout/auth-recovery/examples/mobile-390.tsx +82 -0
  347. package/docs/layout/auth-recovery/examples/password-recovery.md +24 -0
  348. package/docs/layout/auth-recovery/examples/password-recovery.tsx +197 -0
  349. package/docs/layout/auth-recovery/examples/wrapping-ja-en-vi.md +27 -0
  350. package/docs/layout/auth-recovery/examples/wrapping-ja-en-vi.tsx +156 -0
  351. package/docs/layout/auth-recovery/index.md +140 -0
  352. package/docs/layout/auth-recovery/index.tsx +96 -0
  353. package/docs/layout/auth-shell-context.tsx +103 -0
  354. package/docs/layout/auth-shell-device.tsx +112 -0
  355. package/docs/layout/auth-shell-registration.tsx +335 -0
  356. package/docs/layout/auth-shell-variants.tsx +139 -0
  357. package/docs/layout/auth-shell.tsx +59 -0
  358. package/docs/layout/auth-stack.tsx +40 -0
  359. package/docs/layout/centered-shell.tsx +102 -0
  360. package/docs/layout/error-surface/examples/application-403.tsx +84 -0
  361. package/docs/layout/error-surface/examples/application-404.tsx +77 -0
  362. package/docs/layout/error-surface/examples/system-500.tsx +47 -0
  363. package/docs/layout/error-surface/examples/system-503.tsx +48 -0
  364. package/docs/layout/error-surface/index.md +153 -0
  365. package/docs/layout/error-surface/index.tsx +239 -0
  366. package/docs/layout/flex.tsx +262 -0
  367. package/docs/layout/legal-document-shell/_data.ts +110 -0
  368. package/docs/layout/legal-document-shell/examples/desktop-1440.md +12 -0
  369. package/docs/layout/legal-document-shell/examples/desktop-1440.tsx +83 -0
  370. package/docs/layout/legal-document-shell/examples/mobile-390.md +22 -0
  371. package/docs/layout/legal-document-shell/examples/mobile-390.tsx +70 -0
  372. package/docs/layout/legal-document-shell/examples/tablet-1024.md +3 -0
  373. package/docs/layout/legal-document-shell/examples/tablet-1024.tsx +84 -0
  374. package/docs/layout/legal-document-shell/examples/wrapping-ja-en-vi.md +18 -0
  375. package/docs/layout/legal-document-shell/examples/wrapping-ja-en-vi.tsx +61 -0
  376. package/docs/layout/legal-document-shell/index.md +51 -0
  377. package/docs/layout/legal-document-shell/index.tsx +101 -0
  378. package/docs/layout/master-detail.tsx +387 -0
  379. package/docs/layout/org-switcher.tsx +131 -0
  380. package/docs/layout/page-container.tsx +946 -0
  381. package/docs/layout/resizable-panel.tsx +419 -0
  382. package/docs/layout/responsive-grid.tsx +235 -0
  383. package/docs/layout/separator.tsx +327 -0
  384. package/docs/layout/service-role-panel.tsx +144 -0
  385. package/docs/layout/sidebar.tsx +586 -0
  386. package/docs/layout/split-pane.tsx +451 -0
  387. package/docs/layout/topbar.tsx +347 -0
  388. package/docs/navigation/app-setting-picker.tsx +141 -0
  389. package/docs/navigation/breadcrumb.tsx +128 -0
  390. package/docs/navigation/context-menu.tsx +117 -0
  391. package/docs/navigation/dropdown-menu.tsx +213 -0
  392. package/docs/navigation/filter-bar.tsx +227 -0
  393. package/docs/navigation/menubar.tsx +141 -0
  394. package/docs/navigation/navigation-menu.tsx +165 -0
  395. package/docs/navigation/pagination.tsx +241 -0
  396. package/docs/navigation/steps.tsx +263 -0
  397. package/docs/navigation/tabs-rtl.tsx +28 -0
  398. package/docs/navigation/tabs.tsx +308 -0
  399. package/docs/navigation/toolbar.tsx +339 -0
  400. package/docs/providers/app-provider.tsx +191 -0
  401. package/docs/providers/format-date.tsx +230 -0
  402. package/docs/query/button-refetch.tsx +160 -0
  403. package/docs/query/data-state.tsx +192 -0
  404. package/docs/query/infinite-query-state.tsx +93 -0
  405. package/docs/query/mutation-feedback.tsx +70 -0
  406. package/docs/query/prefetch-link.tsx +262 -0
  407. package/docs/query/touch-actions.tsx +68 -0
  408. package/docs/showcase/acme-portal.tsx +441 -0
  409. package/docs/showcase/acme-website.tsx +455 -0
  410. package/docs/showcase/case1-warehouse-dashboard.tsx +343 -0
  411. package/docs/showcase/case2-employee-me.tsx +441 -0
  412. package/docs/showcase/case3-approval-workflow.tsx +527 -0
  413. package/docs/showcase/case4-login.tsx +307 -0
  414. package/docs/showcase/case5-shift-calendar.tsx +795 -0
  415. package/docs/showcase/case6-agency-handy.tsx +1072 -0
  416. package/docs/showcase/futurelastic-web.tsx +390 -0
  417. package/docs/showcase/org-switcher.tsx +313 -0
  418. package/docs/showcase/permission-matrix.tsx +343 -0
  419. package/docs/showcase/public-landing.tsx +210 -0
  420. package/docs/showcase/settings-account-sections.tsx +559 -0
  421. package/docs/showcase/settings-security-mfa.tsx +145 -0
  422. package/docs/showcase/table-approval-queue.tsx +199 -0
  423. package/docs/showcase/table-bulk-actions.tsx +460 -0
  424. package/docs/showcase/table-compact-kintone.tsx +438 -0
  425. package/docs/showcase/table-conditional-format.tsx +367 -0
  426. package/docs/showcase/table-crud-list.tsx +544 -0
  427. package/docs/showcase/table-density.tsx +340 -0
  428. package/docs/showcase/table-expandable-rows.tsx +471 -0
  429. package/docs/showcase/table-filter-chips.tsx +461 -0
  430. package/docs/showcase/table-footer-totals.tsx +311 -0
  431. package/docs/showcase/table-grouped-subtotals.tsx +388 -0
  432. package/docs/showcase/table-master-detail.tsx +479 -0
  433. package/docs/showcase/table-pagination.tsx +320 -0
  434. package/docs/showcase/table-states.tsx +363 -0
  435. package/docs/showcase/table-sticky-columns.tsx +373 -0
  436. package/docs/showcase/table-tree-rows.tsx +444 -0
  437. package/docs/showcase/table-view-tabs.tsx +488 -0
  438. package/package.json +10 -11
  439. package/scripts/_agent-setup.mjs +16 -2
  440. package/scripts/audit-hook.mjs +3 -13
  441. package/scripts/init-agent-kit.mjs +1 -14
  442. package/scripts/postinstall.mjs +12 -12
  443. package/scripts/ui-audit.mjs +93 -31
  444. package/scripts/visual-audit-rules.mjs +51 -7
  445. package/scripts/visual-audit.mjs +118 -47
@@ -1,37 +1,23 @@
1
- /*
2
- * STATUS BADGE — compact chip spacing + semantic tones (control-styles.ts maps tones).
3
- */
1
+
4
2
 
5
3
  @layer components {
6
4
  [data-slot="badge"] {
7
5
  display: inline-flex;
8
6
  align-items: center;
9
- /* Center on the text x-height when the badge sits INLINE with running text (an inline-flex box
10
- * defaults to baseline → it rides high / "valign top" next to a label). Ignored in flex/grid
11
- * containers, so table cells and Flex rows are unaffected. */
7
+
12
8
  vertical-align: middle;
13
9
  gap: var(--badge-space-gap);
14
10
  padding: var(--badge-space-y) var(--badge-space-x);
15
11
  border-radius: var(--radius-md);
16
12
  border-width: 1px;
17
13
  font-size: var(--badge-font-size);
18
- /* The cva used to carry `text-xs`, which set BOTH font-size and the Tailwind companion
19
- * line-height. It was dropped (gh#260) so this components-layer rule can own font-size —
20
- * so line-height must be restored here too, or the badge would inherit the ambient body
21
- * leading and grow taller. Default reproduces `text-xs` exactly. */
14
+
22
15
  line-height: var(--badge-line-height);
23
16
  font-weight: var(--font-weight-medium);
24
- /* A status chip must read as one unit — never wrap its label across lines,
25
- * especially inside narrow table cells. */
17
+
26
18
  white-space: nowrap;
27
19
  }
28
20
 
29
- /* Optical vertical centering. JP faces (Noto Sans JP / M PLUS 2) declare ascent ≫ descent
30
- * (~1.16em vs ~0.29em), so flex-centering the em box seats the label visibly LOW in the chip
31
- * (worst with short lowercase labels: "owner", "active"). Trimming the line box to
32
- * cap-height/alphabetic makes the INK the thing that gets centered, and drops the phantom
33
- * leading so the chip height comes from --badge-space-y + the glyphs, not the font's em box.
34
- * No-support browsers simply keep the legacy (slightly low) rendering. */
35
21
  @supports (text-box-trim: trim-both) and (text-box-edge: cap alphabetic) {
36
22
  [data-slot="badge-label"] {
37
23
  text-box-trim: trim-both;
@@ -1,68 +1,8 @@
1
- /* ─────────────────────────────────────────────────────────────────────────
2
- * FOUNDATION — Tailwind entry, design tokens, density, theme mapping, base
3
- * element styles. This is the minimum every consumer needs.
4
- *
5
- * Tree-shakeable CSS setup: import this ONCE, then add ONLY the component
6
- * layout layers you actually render:
7
- *
8
- * @import "@godxjp/ui/styles/base"; // this file (required)
9
- * @import "@godxjp/ui/styles/control"; // buttons, inputs, toggles
10
- * @import "@godxjp/ui/styles/form-layout";
11
- * @import "@godxjp/ui/styles/dialog-layout";
12
- * @import "@godxjp/ui/styles/card-layout";
13
- * // ...only the ones you use
14
- *
15
- * The layout files declare `@layer components` and use `@apply`, so base.css
16
- * (which pulls in Tailwind) MUST be imported before them, in the same
17
- * stylesheet.
18
- *
19
- * Bundled fonts are opt-in — add `@godxjp/ui/styles/fonts` if you want them, or
20
- * skip it and supply your own via the --font-family-* tokens. When you DO import
21
- * it, it MUST come AFTER this file: base.css pulls in tokens/foundation.css,
22
- * whose font-agnostic `:root { --font-sans-base: <system stack> }` sits at the
23
- * same specificity as the bundle's fill, so the later import wins. Imported
24
- * first, the bundle is dead weight (issue #210).
25
- *
26
- * Prefer the all-in-one `@godxjp/ui/styles` entry if you'd rather ship every
27
- * component's CSS + the bundled fonts and not think about it.
28
- * ───────────────────────────────────────────────────────────────────────── */
1
+
29
2
  @import "tailwindcss";
30
3
 
31
- /* ── THE LAYER CONTRACT (gh#412) ───────────────────────────────────────────
32
- * `@import "tailwindcss"` establishes `theme, base, components, utilities`. Everything this
33
- * package styles lives in `@layer components`, which is EARLIER than `utilities` — so a Tailwind
34
- * utility a component itself emits silently outranks the package rule that is supposed to own the
35
- * same property, no matter how specific that rule is. That is not a specificity bug you can fix
36
- * with another selector; layer order beats specificity outright.
37
- *
38
- * It shipped as a real defect: `<table class="… text-sm">` (utilities) vs the collection preset's
39
- * `font-size: var(--table-action-collection-font-size-compact)` (components) — the compact type
40
- * tier never applied at ANY width, so the documented token was dead and a 5–6 character Japanese
41
- * label could not fit the narrow-frame column measure (WCAG 2.2 SC 1.4.10, and only ever visible
42
- * in Japanese). Two independent consumers reported it.
43
- *
44
- * `godxjp-ui-responsive` is declared HERE, after Tailwind, so it is the LAST layer and outranks
45
- * `utilities`. It is reserved for one thing: RESPONSIVE RE-POINTS — the container/media blocks
46
- * that must win over a component's own static utility for the layout contract to hold. Nothing
47
- * static belongs in it; a rule that does not sit inside a `@container`/`@media` query goes in
48
- * `@layer components` like everything else.
49
- *
50
- * What this layer canNOT do — and the rule consumers must follow: an UNLAYERED consumer rule
51
- * outranks EVERY layer, including this one. So app CSS must theme this package through TOKENS on
52
- * a wrapper, never by writing its own selectors against `[data-slot]` / `[data-priority]`
53
- * elements. A consumer that does write such a rule must put it in a layer
54
- * (`@layer components { … }`), or it will silently kill the responsive re-points the package
55
- * makes — a column measured to 0px and wrapped one character per line is what that looks like.
56
- * See docs/TOKENS.md · "The layer contract". */
57
4
  @layer godxjp-ui-responsive;
58
5
 
59
- /* Per-language font wiring — token-only, NO hardcoded faces. Each locale reads
60
- * an OPTIONAL per-lang slot token (empty by default) and falls back to the
61
- * base sans. Consumers switch a locale's face by setting its slot, e.g.
62
- * :root { --font-sans-ja: "Noto Sans JP", var(--font-sans-base); }
63
- * without writing any [lang] selectors. The opt-in bundle styles/fonts fills
64
- * these slots for its Noto Sans JP + M PLUS 2 fallback. `--font-sans-base` is a
65
- * separate token (not --font-family-sans) so the fallback can't self-reference. */
66
6
  [lang="ja"] {
67
7
  --font-family-sans: var(--font-sans-ja, var(--font-sans-base));
68
8
  }
@@ -82,47 +22,27 @@
82
22
  --font-family-sans: var(--font-sans-zh-hant, var(--font-sans-base));
83
23
  }
84
24
 
85
- /* Guarantee the full set of semantic color utilities ships in the compiled CSS
86
- * even when the library itself only references a few — consumers (and the token
87
- * docs) must be able to use bg/text/border for EVERY semantic role. Without this
88
- * Tailwind's JIT drops unused roles (success/info/attention) → transparent. */
89
25
  @source inline(
90
26
  "{bg,text,border,ring}-{primary,secondary,muted,accent,destructive,success,warning,info,attention}"
91
27
  );
92
28
  @source inline(
93
29
  "{bg,text}-{primary,secondary,muted,accent,destructive,success,warning,info,attention}-foreground"
94
30
  );
95
- /* Extended text hierarchy + interaction-ramp utilities (library may not reference them directly). */
31
+
96
32
  @source inline("{text,bg,border}-{foreground-tertiary,foreground-disabled,link,brand}");
97
33
  @source inline("bg-{primary,secondary,destructive}-{hover,active}");
98
- /* Force the extended radius steps so Tailwind emits --radius-xs/-xl/-2xl to :root (consumers read
99
- * `var(--radius-2xl)` directly; without a generated utility Tailwind drops the unused var). */
34
+
100
35
  @source inline("rounded-{xs,xl,2xl}");
101
36
  @source inline("text-2xs");
102
37
  @source inline("text-{3xl,4xl,5xl}");
103
38
  @source inline("text-{primary,success,warning,info,error}-strong");
104
- /* `.js` matters: the published package ships only compiled JS under dist (no
105
- * .tsx sources), and this file is copied verbatim into dist/styles — without
106
- * it Tailwind finds no component classes in consumers (unstyled popovers and
107
- * selects, and Radix scroll-lock freezes the page because pointer-events-auto
108
- * is never emitted). In-repo the glob scans src; published, it scans dist. */
39
+
109
40
  @source "../**/*.{tsx,ts,js}";
110
41
  @import "../tokens/base.css";
111
- /* The focus ring is FOUNDATION, not a component layer: every focusable control in
112
- * every layer reads the same four tokens from ONE rule (styles/focus-ring.css).
113
- * Imported here — not left to index.css — so a consumer that tree-shakes down to
114
- * `styles/base` + two layout files still gets keyboard-focus affordance (WCAG
115
- * 2.4.7); shipping it as an optional layer would make a11y opt-in by accident. */
42
+
116
43
  @import "./focus-ring.css";
117
44
  @import "./density.css";
118
45
 
119
- /* `inline` (NOT a bare @theme): Tailwind inlines each expression — e.g. `hsl(var(--primary))` —
120
- * directly into every utility (`bg-primary` becomes `background-color: hsl(var(--primary))`) instead
121
- * of emitting `var(--color-primary)` computed once at :root. This is THE enabler for scoped /
122
- * multi-tenant theming: a `[data-tenant]{ --primary: … }` override now re-resolves at the element,
123
- * so colors and radius propagate into a subtree (a plain @theme froze them at :root, so scoped
124
- * overrides never reached the color utilities). Components read raw tokens like `hsl(var(--primary))`
125
- * directly in their own CSS, so they re-theme the same way. */
126
46
  @theme inline {
127
47
  --color-background: hsl(var(--background));
128
48
  --color-foreground: hsl(var(--foreground));
@@ -151,8 +71,7 @@
151
71
  --color-info-foreground: hsl(var(--info-foreground));
152
72
  --color-attention: hsl(var(--attention));
153
73
  --color-attention-foreground: hsl(var(--attention-foreground));
154
- /* AA-strong status TEXT colours (text-{success,warning,info,error}-strong) — darker than the
155
- * fills so small coloured labels clear WCAG AA on white; flip light on the dark theme. */
74
+
156
75
  --color-primary-strong: hsl(var(--text-primary));
157
76
  --color-success-strong: hsl(var(--text-success));
158
77
  --color-warning-strong: hsl(var(--text-warning));
@@ -164,8 +83,7 @@
164
83
  --color-chart-4: var(--chart-4);
165
84
  --color-chart-5: var(--chart-5);
166
85
  --color-chart-6: var(--chart-6);
167
- /* Golden-ratio radius scale — every step derives from --radius × (--radius-ratio = φ)ⁿ, so
168
- * overriding --radius alone rescales the whole scale proportionally (≈ 1.4/2.3/3.7/6/9.7/15.7px). */
86
+
169
87
  --radius-xs: calc(
170
88
  var(--radius) / var(--radius-ratio) / var(--radius-ratio) / var(--radius-ratio)
171
89
  );
@@ -174,22 +92,22 @@
174
92
  --radius-lg: var(--radius);
175
93
  --radius-xl: calc(var(--radius) * var(--radius-ratio));
176
94
  --radius-2xl: calc(var(--radius) * var(--radius-ratio) * var(--radius-ratio));
177
- /* Extended text-hierarchy roles (tertiary / disabled / link / brand) → text-* / bg-* utilities. */
95
+
178
96
  --color-foreground-tertiary: hsl(var(--text-tertiary));
179
97
  --color-foreground-disabled: hsl(var(--text-disabled));
180
98
  --color-link: hsl(var(--text-link));
181
99
  --color-brand: hsl(var(--text-brand));
182
- /* Interaction ramp (hover / active) → bg-primary-hover etc. */
100
+
183
101
  --color-primary-hover: hsl(var(--primary-hover));
184
102
  --color-primary-active: hsl(var(--primary-active));
185
103
  --color-secondary-hover: hsl(var(--secondary-hover));
186
104
  --color-secondary-active: hsl(var(--secondary-active));
187
105
  --color-destructive-hover: hsl(var(--destructive-hover));
188
106
  --color-destructive-active: hsl(var(--destructive-active));
189
- /* Wire Tailwind's font-sans/mono (and preflight) to the design-system fonts. */
107
+
190
108
  --font-sans: var(--font-family-sans);
191
109
  --font-mono: var(--font-family-mono);
192
- /* 和色 (wa-iro) accents → bg-wa / text-wa utilities (charts, tags, decoration). */
110
+
193
111
  --color-wa-ai: var(--wa-ai);
194
112
  --color-wa-gunjo: var(--wa-gunjo);
195
113
  --color-wa-ruri: var(--wa-ruri);
@@ -203,7 +121,7 @@
203
121
  --color-wa-sakura: var(--wa-sakura);
204
122
  --color-wa-sumi: var(--wa-sumi);
205
123
  --color-wa-nezu: var(--wa-nezu);
206
- /* Wire Tailwind text-* utilities to runtime typography tokens (fontSize toolbar). */
124
+
207
125
  --text-2xs: var(--font-size-2xs);
208
126
  --text-xs: var(--font-size-xs);
209
127
  --text-sm: var(--font-size-sm);
@@ -211,7 +129,7 @@
211
129
  --text-lg: var(--font-size-lg);
212
130
  --text-xl: var(--font-size-xl);
213
131
  --text-2xl: var(--font-size-2xl);
214
- /* Opt-in DISPLAY ramp (marketing/hero) — wired to the display tokens, unused by the admin scale. */
132
+
215
133
  --text-3xl: var(--font-size-3xl);
216
134
  --text-4xl: var(--font-size-4xl);
217
135
  --text-5xl: var(--font-size-5xl);
@@ -222,17 +140,6 @@
222
140
  border-color: hsl(var(--border));
223
141
  }
224
142
 
225
- /* Visually-hidden, absolutely-positioned helpers must never affect layout or scroll height.
226
- *
227
- * Radix renders a hidden native form-fallback (BubbleSelect/BubbleInput) for Select, Checkbox,
228
- * Switch and RadioGroup; it is `position:absolute` with NO top/left, so when the control has no
229
- * positioned ancestor its static box resolves far down the page and inflates
230
- * `document.scrollHeight` → phantom empty scroll space (gh#105). The same is true of the
231
- * `.sr-only` clamp (Tailwind / our own status + file-input nodes). These fallbacks are always
232
- * `aria-hidden` + `tabindex=-1`. Pinning every such node to the top-left of its containing block
233
- * makes it impossible for it to extend the scroll height, regardless of consumer markup — no DOM
234
- * wrapper or per-component positioning required. Inside the AppShell the `.app-main { contain:
235
- * paint }` boundary (gh#104) already contains these; this rule protects every other call site too. */
236
143
  :where(select, input)[aria-hidden="true"][tabindex="-1"],
237
144
  .sr-only {
238
145
  top: 0;
@@ -242,8 +149,7 @@
242
149
  body {
243
150
  background-color: hsl(var(--background));
244
151
  color: hsl(var(--foreground));
245
- /* Body reads --font-family-body (defaults to --font-family-sans → unchanged); a service that
246
- * wants a dual-font brand (display + body face) overrides --font-family-body alone. */
152
+
247
153
  font-family: var(--font-family-body);
248
154
  font-size: var(--font-size-base);
249
155
  line-height: var(--line-height-body);
@@ -256,11 +162,6 @@
256
162
  "calt" 1;
257
163
  }
258
164
 
259
- /* Semantic heading scale — SEO + accessibility: real <h1>–<h6> elements carry
260
- * the document outline (one <h1> per page, levels never skipped). Visual size
261
- * follows the reference-design scale; component titles override via their own class.
262
- * Headings read --font-family-display (defaults to --font-family-sans → unchanged) for dual-font
263
- * brands (display face on headings, body face on prose). */
264
165
  :where(h1, h2, h3, h4, h5, h6) {
265
166
  font-family: var(--font-family-display);
266
167
  }
@@ -1,48 +1,22 @@
1
- /*
2
- * CARD LAYOUT — canonical slot padding (@godxjp/ui)
3
- * -----------------------------------------------------------------
4
- * Card* components emit data-slot + data-* flags ONLY. All inset/gap padding lives here.
5
- *
6
- * Uses card component tokens from src/tokens/components/card.css.
7
- * Card tokens derive from foundation/layout primitives and are coordinated by tokens/base.css.
8
- *
9
- * Slot ownership — one token per vertical gap:
10
- * shell φ¹ title block top, card bottom, solo content
11
- * section φ⁰ header↔body (plain header pb=0; content owns gap)
12
- * band φ⁻¹ banded header, separated footer
13
- *
14
- * Modifiers (set on components, never Tailwind p-* in app/story code):
15
- * data-banded · data-flush · data-tight · data-solo · data-separated
16
- *
17
- * LAYER: wrapped in `@layer components` (like every other *-layout.css). Unlayered card CSS used to
18
- * BEAT Tailwind utilities, so a consumer `className="flex flex-row …"` on CardHeader was silently
19
- * ignored (flex-direction stayed `column`) — the documented CardAction pairing broke. In the
20
- * components layer, utilities win, so className overrides behave like every other component.
21
- */
1
+
22
2
 
23
3
  @layer components {
24
4
  [data-slot="card"] {
25
5
  min-width: 0;
26
- /* Base hairline border — width lives here (not a Tailwind `border` utility) so the
27
- * `[data-accent]` rail-width override below can win within the same cascade layer. */
6
+
28
7
  border-width: 1px;
29
8
  border-style: solid;
30
9
  border-color: hsl(var(--card-border, var(--border)));
31
10
  border-radius: var(--card-radius);
32
- /* Fill = base card colour with an opt-in role tint washed over it (--card-tint default
33
- * transparent → byte-identical at rest). Tint layer sits ABOVE the base colour.
34
- * --card-background defaults to the LIVE --card role at the call site (re-resolves under a
35
- * scoped theme); a service overrides --card-background to win. */
11
+
36
12
  background:
37
13
  linear-gradient(var(--card-tint), var(--card-tint)), hsl(var(--card-background, var(--card)));
38
14
  color: hsl(var(--card-foreground));
39
- /* Resting elevation + opt-in brand glow — both quiet no-ops by default so a service theme can
40
- * lift (--card-shadow) and/or glow (--card-glow) every card with no markup change. */
15
+
41
16
  box-shadow: var(--card-shadow), var(--card-glow);
42
17
  overflow: hidden;
43
18
  }
44
19
 
45
- /* ── Surface variants — fill only; retain the shared DXS surface elevation ──── */
46
20
  [data-slot="card"][data-variant="muted"] {
47
21
  background: hsl(var(--secondary));
48
22
  }
@@ -51,22 +25,12 @@
51
25
  background: transparent;
52
26
  }
53
27
 
54
- /* `featured` = the brand-toned perimeter. Its colour is a role-mirror knob (rule #45): declared
55
- * `initial` in the token layer so the --primary default resolves HERE, at the call site, and a
56
- * scoped [data-tenant]/.dark override of --primary still reaches it. A service that wants the
57
- * featured ring in a non-brand tone overrides --card-featured-border-color; a card that wants a
58
- * SEMANTIC perimeter (attention / destructive / success …) uses
59
- * `accent="…" accentPlacement="perimeter"` instead — same geometry, tone-owned. */
60
28
  [data-slot="card"][data-variant="featured"] {
61
29
  border-color: var(--card-featured-border-color, hsl(var(--primary)));
62
30
  box-shadow: 0 0 0 var(--card-featured-ring-width)
63
31
  var(--card-featured-border-color, hsl(var(--primary)));
64
32
  }
65
33
 
66
- /* ── Density — override the shell inset/body tokens ──────────────────────
67
- * `--card-space-shell-y: initial` re-arms the block axis to follow THIS card's inset again: the
68
- * `density` prop is an explicit per-instance decision and must beat an ambient shell-level block
69
- * override (e.g. AuthShell compact), exactly as it did when one inset owned both axes. */
70
34
  [data-slot="card"][data-density="tight"] {
71
35
  --card-space-inset: var(--space-3);
72
36
  --card-space-shell-y: initial;
@@ -79,11 +43,6 @@
79
43
  --card-space-body-y: var(--space-5);
80
44
  }
81
45
 
82
- /* ── Accent tone — ONE resolved colour per semantic accent ─────────────
83
- * `--card-accent-color` is RESOLVED from the card's own `data-accent`, so both placements read
84
- * the same value and a new tone is one line. It is deliberately NOT a service knob: it is set on
85
- * the element, so a :root / [data-tenant] override could never reach it. Retint the ROLE
86
- * (--attention, --success, …) — that is what a role is for. */
87
46
  [data-slot="card"][data-accent="primary"] {
88
47
  --card-accent-color: hsl(var(--primary));
89
48
  }
@@ -108,7 +67,6 @@
108
67
  --card-accent-color: hsl(var(--destructive));
109
68
  }
110
69
 
111
- /* ── Accent placement `edge` (DEFAULT) — semantic left stripe (token width), content on shell ─ */
112
70
  [data-slot="card"][data-accent] {
113
71
  border-inline-start-width: var(--card-accent-rail-width);
114
72
  border-inline-start-color: var(--card-accent-color);
@@ -120,12 +78,6 @@
120
78
  padding-inline-start: calc(var(--card-space-inset) - var(--card-accent-rail-width));
121
79
  }
122
80
 
123
- /* ── Accent placement `perimeter` — the full attention border (gh#12) ───
124
- * The whole edge carries the semantic tone instead of one rail, so a card can read as
125
- * "action required" / "failed" at a glance without borrowing `--primary` the way
126
- * `variant="featured"` does. Same optical weight as `featured` (border + 1px ring), tone-owned.
127
- * Because the rail is gone, the slot padding compensation above is undone — content returns to
128
- * the normal shell column, so switching placement never shifts the text. */
129
81
  [data-slot="card"][data-accent][data-accent-placement="perimeter"] {
130
82
  border-width: var(--card-accent-perimeter-width);
131
83
  border-color: var(--card-accent-color);
@@ -143,7 +95,6 @@
143
95
  padding-inline-start: var(--card-space-inset);
144
96
  }
145
97
 
146
- /* ── Header ──────────────────────────────────────────────────────────── */
147
98
  [data-slot="card-header"] {
148
99
  display: flex;
149
100
  flex-direction: column;
@@ -156,11 +107,6 @@
156
107
  padding-bottom: 0;
157
108
  }
158
109
 
159
- /* ── CardBar — positionable tab/toolbar strip (CardBar in card.tsx) ───────
160
- * Separators come from POSITION: a top bar gets a bottom border, a bottom
161
- * bar a top border, a middle bar both, a sole child none. `border-block` is
162
- * the block (top/bottom) axis — RTL-neutral. The card's own overflow:hidden
163
- * clips the bar to the rounded corners, so it needs no radius of its own. */
164
110
  [data-slot="card-bar"] {
165
111
  display: flex;
166
112
  align-items: center;
@@ -205,7 +151,7 @@
205
151
 
206
152
  [data-slot="card-header"][data-banded] {
207
153
  padding-inline: var(--card-space-inset);
208
- /* Divided band → symmetric vertical padding (border-aware). */
154
+
209
155
  padding-block: var(--card-space-divided-y);
210
156
  gap: var(--card-space-gap);
211
157
  }
@@ -250,28 +196,17 @@
250
196
  overflow: hidden;
251
197
  }
252
198
 
253
- /* A banded header gives a normal body a top gap — but NOT a flush body: a full-bleed table (or any
254
- * edge-to-edge content) must butt FLUSH against the card header's bottom border, with no empty
255
- * bordered gap between the two bands (the dialog/sheet no-gap principle). */
256
199
  [data-slot="card"]:has([data-slot="card-header"][data-banded])
257
200
  [data-slot="card-content"]:not([data-tight]):not([data-flush]) {
258
201
  padding-top: var(--card-space-body-y);
259
202
  }
260
203
 
261
- /* Flush / tight body — symmetric plain header band.
262
- *
263
- * NOT written as `:has(…[data-tight]:not(:has(tabs-list)))`: the Selectors 4 spec forbids
264
- * `:has()` anywhere inside `:has()`, and Chrome drops the WHOLE rule as invalid
265
- * (CSS.supports=false, measured on Chrome 151) — the symmetric band never applied. Same
266
- * failure class as the headerAlign selector (505f0e6): in the file, correct-looking, selects
267
- * nothing. So: apply to every tight body, then the tabs case below restores the shell top. */
268
204
  [data-slot="card"]:has([data-slot="card-content"][data-tight])
269
205
  [data-slot="card-header"]:not([data-banded]) {
270
206
  padding-top: var(--card-space-body-y);
271
207
  padding-bottom: var(--card-space-body-y);
272
208
  }
273
209
 
274
- /* Tabs in a tight body: only the bottom band is managed (rule below) — keep the shell top. */
275
210
  [data-slot="card"]:has([data-slot="card-content"][data-tight] [data-slot="tabs-list"])
276
211
  [data-slot="card-header"]:not([data-banded]) {
277
212
  padding-top: var(--card-space-shell-y, var(--card-space-inset));
@@ -282,7 +217,6 @@
282
217
  padding-bottom: var(--card-space-body-y);
283
218
  }
284
219
 
285
- /* Toolbar header — title + CardAction, no description */
286
220
  [data-slot="card-header"]:has([data-slot="card-action"]):not(
287
221
  :has([data-slot="card-description"])
288
222
  ) {
@@ -295,16 +229,6 @@
295
229
  padding-bottom: var(--card-space-body-y);
296
230
  }
297
231
 
298
- /* NOT `:has(header:has(action):not(:has(description)))` — nested `:has()` is spec-invalid
299
- * and Chrome drops the whole rule (measured, Chrome 151), so the toolbar body never lost its
300
- * top padding. Valid equivalent: zero it for any header-hosted action, then the described
301
- * (non-toolbar) header restores the gap in the equal-specificity rule after this one. */
302
- /* Both halves of the pair exclude [data-flush]: a flush body owns its block axis outright in
303
- * the flush rule below, so neither half has anything to say about it. Excluding it from the
304
- * DESCRIPTION half is what stops that half re-adding the gap a flush body just zeroed (gh#307);
305
- * excluding it from the ACTION half is only consistency — that half zeroes the same value the
306
- * flush rule already sets, and leaving it in place would let a service that retunes the flush
307
- * block axis be silently overridden in an action-headed card. */
308
232
  [data-slot="card"]:has([data-slot="card-header"] [data-slot="card-action"])
309
233
  [data-slot="card-content"]:not([data-tight]):not([data-flush]) {
310
234
  padding-top: 0;
@@ -315,31 +239,21 @@
315
239
  padding-top: var(--card-space-body-y);
316
240
  }
317
241
 
318
- /* Header-only card — terminal slot owns bottom shell */
319
242
  [data-slot="card"]:not(:has([data-slot="card-content"], [data-slot="card-footer"]))
320
243
  [data-slot="card-header"] {
321
244
  padding-bottom: var(--card-space-shell-y, var(--card-space-inset));
322
245
  }
323
246
 
324
- /* Cover — header below media uses section top, not shell */
325
247
  .ui-card-cover {
326
248
  display: block;
327
249
  width: 100%;
328
250
  overflow: hidden;
329
251
  }
330
252
 
331
- /* A header BELOW a cover gets a top gap to clear the media — but a BANDED header is a
332
- * self-contained divider band that must stay symmetric (border-aware), so it keeps its
333
- * own `--card-space-divided-y` block padding instead of this one-sided top gap. */
334
253
  [data-slot="card"]:has([data-slot="card-cover"]) [data-slot="card-header"]:not([data-banded]) {
335
254
  padding-top: var(--card-space-body-y);
336
255
  }
337
256
 
338
- /* ── Content ─────────────────────────────────────────────────────────────
339
- * The two axes are INDEPENDENT (gh#232): the inline column reads --card-space-inset, the block
340
- * shell edge reads --card-space-shell-y (default = the same inset, so the resting render is
341
- * unchanged). A shell that needs a shorter card without a narrower column — AuthShell compact —
342
- * now moves the block axis alone instead of hitting a wall at a uniform inset. */
343
257
  [data-slot="card-content"] {
344
258
  padding-inline: var(--card-space-inset);
345
259
  padding-bottom: var(--card-space-shell-y, var(--card-space-inset));
@@ -349,11 +263,6 @@
349
263
  padding-top: var(--card-space-body-y);
350
264
  }
351
265
 
352
- /* A solo body owns BOTH block edges (there is no header/footer to carry them), so this is
353
- * `padding-block`, not just `padding-top` — it overrides the generic bottom edge above.
354
- * The fallback chain solo-y → shell-y → inset means: a shell that tunes only the general block
355
- * knob still reaches a solo body, an explicit --card-space-solo-y wins over it, and with neither
356
- * set the render is the historical inset. */
357
266
  [data-slot="card-content"][data-solo] {
358
267
  padding-block: var(--card-space-solo-y, var(--card-space-shell-y, var(--card-space-inset)));
359
268
  }
@@ -362,27 +271,10 @@
362
271
  padding-inline: 0;
363
272
  }
364
273
 
365
- /* The flush body owns its BLOCK axis outright, and it does so for EVERY flush body — not only
366
- * one that happens to contain a `<table>` (gh#307). The `:has(table)` gate made the "flush has
367
- * no padding" contract accidental: a full-bleed body of anything else (a file list, a
368
- * DataTable rendering its empty state, a media strip) still took the generic body padding, so
369
- * it floated off the header — measured at 18.4px on a consumer's 関連ファイル section while the
370
- * 備考 section next to it, a flush TABLE, measured 0px. The narrow repair for that report
371
- * (`:not([data-flush])` on the describedBody pair) could not fix it: the padding was coming
372
- * from the generic `[data-slot="card-content"]` rules, not from the described one, and adding
373
- * the guard to the header-ACTION half of that pair even took the `padding-top: 0` those bodies
374
- * used to get. Owning the axis here at (0,4,0) settles all of it: this out-ranks every generic
375
- * content rule, and the two guarded pair-halves below no longer reach a flush body at all, so
376
- * neither can override the zero again. `tight` and `solo` own the block axis themselves. */
377
274
  [data-slot="card-content"][data-flush]:not([data-tight]):not([data-solo]) {
378
275
  padding-block: 0;
379
276
  }
380
277
 
381
- /* A plain header above ANY flush body therefore supplies its OWN bottom gap — the body's block
382
- * padding is zeroed above, so without this the title/subtitle butt against the first row. Match
383
- * the header's top inset so the header block reads balanced top↕bottom. The `:has()` argument
384
- * mirrors the flush rule's own guards exactly: a tight/solo body keeps its padding, so widening
385
- * this to it would double the gap. */
386
278
  [data-slot="card"]:has([data-slot="card-content"][data-flush]:not([data-tight]):not([data-solo]))
387
279
  [data-slot="card-header"]:not([data-banded]) {
388
280
  padding-bottom: var(--card-space-body-y);
@@ -396,7 +288,6 @@
396
288
  padding-bottom: var(--card-space-body-y);
397
289
  }
398
290
 
399
- /* Tabs in card */
400
291
  [data-slot="card"]:has([data-slot="tabs-list"]) [data-slot="card-content"][data-tight] {
401
292
  padding-top: 0;
402
293
  padding-inline: 0;
@@ -411,7 +302,6 @@
411
302
  padding: var(--card-space-body-y) var(--card-space-inset);
412
303
  }
413
304
 
414
- /* ── Footer ──────────────────────────────────────────────────────────── */
415
305
  [data-slot="card-footer"] {
416
306
  display: flex;
417
307
  flex-wrap: wrap;
@@ -435,7 +325,7 @@
435
325
 
436
326
  [data-slot="card-footer"][data-separated] {
437
327
  border-top: 1px solid hsl(var(--card-border, var(--border)));
438
- /* Divided band → symmetric vertical padding (border-aware), in sync with a banded header. */
328
+
439
329
  padding-block: var(--card-space-divided-y);
440
330
  justify-content: flex-end;
441
331
  }
@@ -445,7 +335,6 @@
445
335
  justify-content: stretch;
446
336
  }
447
337
 
448
- /* ── Nested insets (table cells, grid cells — align to shell, not slot padding) ─ */
449
338
  .ui-card-inset-x {
450
339
  padding-inline: var(--card-space-inset);
451
340
  }
@@ -466,7 +355,6 @@
466
355
  padding-block: var(--card-space-footer-y);
467
356
  }
468
357
 
469
- /* ── StatCard — KPI tile aligned to dashboard design ─────────────── */
470
358
  [data-slot="card"][data-stat-card] {
471
359
  padding: var(--card-space-header-y) var(--card-space-inset);
472
360
  }
@@ -482,8 +370,6 @@
482
370
  min-width: 0;
483
371
  }
484
372
 
485
- /* Optional leading icon medallion — tinted box above the metric. Tone via tokens (default a
486
- * soft brand-primary tint), so a service rethemes it with --primary or the icon tokens. */
487
373
  [data-slot="stat-card-icon"] {
488
374
  display: inline-flex;
489
375
  align-items: center;
@@ -501,7 +387,6 @@
501
387
  height: var(--stat-card-icon-glyph-size);
502
388
  }
503
389
 
504
- /* Inline layout: medallion floats to the trailing edge so label/value keep the start column. */
505
390
  [data-slot="card"][data-stat-layout="inline"] [data-slot="stat-card-icon"] {
506
391
  margin-bottom: 0;
507
392
  order: 1;
@@ -562,7 +447,6 @@
562
447
  line-height: var(--line-height-normal);
563
448
  }
564
449
 
565
- /* ── Service launcher — organization-scoped downstream app tile ─────── */
566
450
  [data-slot="card"][data-service-launcher] {
567
451
  display: flex;
568
452
  flex-direction: column;
@@ -590,9 +474,6 @@
590
474
  color: hsl(var(--card-service-launcher-icon-foreground, var(--primary)));
591
475
  }
592
476
 
593
- /* Unavailable tile (the consumer supplied a `disabledReason`): the medallion drops its brand
594
- * wash so an un-launchable service never reads as live. Role-mirror knobs default at the CALL
595
- * SITE, so a scoped [data-tenant]/.dark override of --muted still reaches it (docs/TOKENS.md). */
596
477
  [data-slot="card"][data-service-launcher][data-unavailable] [data-slot="service-launcher-icon"] {
597
478
  background: hsl(var(--card-service-launcher-unavailable-icon-background, var(--muted)));
598
479
  color: hsl(var(--card-service-launcher-unavailable-icon-foreground, var(--muted-foreground)));
@@ -624,7 +505,6 @@
624
505
  line-height: var(--card-service-launcher-description-line-height);
625
506
  }
626
507
 
627
- /* Mono metadata ONLY (hostname · plan) — machine identifiers, never prose. */
628
508
  [data-slot="service-launcher-metadata"] {
629
509
  overflow-wrap: anywhere;
630
510
  color: hsl(var(--muted-foreground));
@@ -633,8 +513,6 @@
633
513
  line-height: var(--card-service-launcher-metadata-line-height);
634
514
  }
635
515
 
636
- /* The disabled/unavailable reason is a localized SENTENCE — it takes the description's prose
637
- * rhythm, not the mono metadata treatment (a JA/VI sentence in monospace is unreadable). */
638
516
  [data-slot="service-launcher-disabled-reason"] {
639
517
  overflow-wrap: anywhere;
640
518
  color: hsl(var(--muted-foreground));
@@ -1,6 +1,4 @@
1
- /* Chart layout — the accessible figure chrome for `@godxjp/ui/charts`.
2
- * Colours come from the foundation `--chart-1..6` + semantic tokens; recharts
3
- * draws the SVG itself. Logical properties only (RTL-safe). */
1
+
4
2
 
5
3
  .ui-chart {
6
4
  display: flex;
@@ -22,7 +20,6 @@
22
20
  min-inline-size: 0;
23
21
  }
24
22
 
25
- /* recharts legend/axis text inherits the design typography + muted tone. */
26
23
  .ui-chart .recharts-text,
27
24
  .ui-chart .recharts-legend-item-text {
28
25
  font-size: var(--font-size-xs);
@@ -38,22 +35,12 @@
38
35
  font-size: var(--font-size-xs);
39
36
  }
40
37
 
41
- /* Content that sits BELOW the plot (the activity footer slot) — outside the
42
- * `role="img"` canvas so links/buttons in it stay reachable and announced. */
43
38
  .ui-chart-footer {
44
39
  margin-block-start: var(--chart-trend-footer-gap);
45
40
  font-size: var(--font-size-xs);
46
41
  color: hsl(var(--muted-foreground));
47
42
  }
48
43
 
49
- /* ─────────────────────────────────────────────────────────────────────────────
50
- * CompactBarTrend — a dependency-free (no recharts) vertical bar trend.
51
- * ALL geometry resolves from `--chart-trend-*` tokens; the only inline value is
52
- * the DATUM itself (`--chart-trend-bar-value`, a 0..1 ratio), so a consumer never
53
- * writes a height calculation or a colour of its own.
54
- * ─────────────────────────────────────────────────────────────────────────── */
55
-
56
- /* `size` → the active plot-height tier. Set on the <figure> as `data-size`. */
57
44
  .ui-chart-trend[data-size="xs"] {
58
45
  --chart-trend-plot-height: var(--chart-trend-plot-height-xs);
59
46
  }
@@ -85,8 +72,6 @@
85
72
  block-size: var(--chart-trend-plot-height);
86
73
  inline-size: 100%;
87
74
  min-inline-size: 0;
88
- /* Quiet by default (rule #44) — a service opts into a baseline rule with
89
- * `--chart-trend-baseline-border: 1px solid hsl(var(--border));`. */
90
75
  border-block-end: var(--chart-trend-baseline-border, none);
91
76
  }
92
77
 
@@ -102,7 +87,7 @@
102
87
  .ui-chart-trend-bar {
103
88
  inline-size: 100%;
104
89
  max-inline-size: var(--chart-trend-bar-max-width);
105
- /* Data-driven: the 0..1 ratio arrives as an inline custom property. */
90
+
106
91
  block-size: max(var(--chart-trend-bar-min-height), calc(var(--chart-trend-bar-value, 0) * 100%));
107
92
  border-start-start-radius: var(--chart-trend-bar-radius);
108
93
  border-start-end-radius: var(--chart-trend-bar-radius);