@squadbase/vantage 0.6.2 → 0.7.0-dev1.3b0e616

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 (355) hide show
  1. package/dist/add-4GHF2TX2.js +6 -0
  2. package/dist/add-4GHF2TX2.js.map +1 -0
  3. package/dist/{build-O5TVNH4E.js → build-U7GO26HR.js} +9 -9
  4. package/dist/{build-O5TVNH4E.js.map → build-U7GO26HR.js.map} +1 -1
  5. package/dist/{check-WFBEDHDR.js → check-MRVAIHG5.js} +7 -7
  6. package/dist/{check-WFBEDHDR.js.map → check-MRVAIHG5.js.map} +1 -1
  7. package/dist/chunk-2IAPIOPS.js +152 -0
  8. package/dist/chunk-2IAPIOPS.js.map +1 -0
  9. package/dist/chunk-3RJEOP3J.js +174 -0
  10. package/dist/chunk-3RJEOP3J.js.map +1 -0
  11. package/dist/{chunk-QDZA5JSL.js → chunk-AABMKHEU.js} +4 -4
  12. package/dist/{chunk-QDZA5JSL.js.map → chunk-AABMKHEU.js.map} +1 -1
  13. package/dist/{chunk-PVTHHV7X.js → chunk-ANZLVSEP.js} +28 -7
  14. package/dist/chunk-ANZLVSEP.js.map +1 -0
  15. package/dist/chunk-CKWPK4RO.js +50 -0
  16. package/dist/chunk-CKWPK4RO.js.map +1 -0
  17. package/dist/chunk-EG4PX726.js +678 -0
  18. package/dist/chunk-EG4PX726.js.map +1 -0
  19. package/dist/{chunk-3G43C6OL.js → chunk-GNXCX4WE.js} +46 -3
  20. package/dist/chunk-GNXCX4WE.js.map +1 -0
  21. package/dist/chunk-NYQJ5UY4.js +9028 -0
  22. package/dist/chunk-NYQJ5UY4.js.map +1 -0
  23. package/dist/chunk-NZ5QIIG4.js +74 -0
  24. package/dist/chunk-NZ5QIIG4.js.map +1 -0
  25. package/dist/{chunk-BCE22JSM.js → chunk-PJ4SPXHS.js} +52 -16
  26. package/dist/chunk-PJ4SPXHS.js.map +1 -0
  27. package/dist/{chunk-RPZAALCX.js → chunk-QNOX7WLZ.js} +256 -165
  28. package/dist/chunk-QNOX7WLZ.js.map +1 -0
  29. package/dist/{chunk-ZVANIULZ.js → chunk-RNTDBX6S.js} +4 -4
  30. package/dist/{chunk-ZVANIULZ.js.map → chunk-RNTDBX6S.js.map} +1 -1
  31. package/dist/{chunk-PXRX5PEC.js → chunk-ROHNXP7J.js} +73 -4
  32. package/dist/chunk-ROHNXP7J.js.map +1 -0
  33. package/dist/chunk-S5MDTHH7.js +466 -0
  34. package/dist/chunk-S5MDTHH7.js.map +1 -0
  35. package/dist/chunk-SDJTTMLK.js +1877 -0
  36. package/dist/chunk-SDJTTMLK.js.map +1 -0
  37. package/dist/{chunk-EP6JHXSR.js → chunk-SHZM3EXB.js} +68 -12
  38. package/dist/chunk-SHZM3EXB.js.map +1 -0
  39. package/dist/chunk-TRMHNMMZ.js +61 -0
  40. package/dist/chunk-TRMHNMMZ.js.map +1 -0
  41. package/dist/{chunk-A2UUGASH.js → chunk-U736PVHY.js} +2 -2
  42. package/dist/chunk-U736PVHY.js.map +1 -0
  43. package/dist/{chunk-JGRMRXXZ.js → chunk-UWSQUHX6.js} +4 -99
  44. package/dist/chunk-UWSQUHX6.js.map +1 -0
  45. package/dist/cli.js +15 -11
  46. package/dist/cli.js.map +1 -1
  47. package/dist/client/index.d.ts +34 -3
  48. package/dist/client/index.js +211 -12
  49. package/dist/client/index.js.map +1 -1
  50. package/dist/components/index.d.ts +2113 -30
  51. package/dist/components/index.js +7 -4
  52. package/dist/delta-text-CbrOaW83.d.ts +17 -0
  53. package/dist/{dev-NZRLOQCL.js → dev-O42JFQ64.js} +24 -13
  54. package/dist/dev-O42JFQ64.js.map +1 -0
  55. package/dist/doc/index.d.ts +215 -2
  56. package/dist/doc/index.js +423 -5
  57. package/dist/doc/index.js.map +1 -1
  58. package/dist/{docs-ZGDJUHJI.js → docs-JVP4RPKT.js} +3 -3
  59. package/dist/{docs-ZGDJUHJI.js.map → docs-JVP4RPKT.js.map} +1 -1
  60. package/dist/{doctor-VFKEMR54.js → doctor-YD3XAAOT.js} +8 -8
  61. package/dist/doctor-YD3XAAOT.js.map +1 -0
  62. package/dist/format-DihQkL1N.d.ts +249 -0
  63. package/dist/geo-japan-7BMSOJRX.js +8 -0
  64. package/dist/geo-japan-7BMSOJRX.js.map +1 -0
  65. package/dist/geo-us-GVOG7VXH.js +8 -0
  66. package/dist/geo-us-GVOG7VXH.js.map +1 -0
  67. package/dist/geo-world-35HL56UU.js +8 -0
  68. package/dist/geo-world-35HL56UU.js.map +1 -0
  69. package/dist/markdown/index.js +1 -1
  70. package/dist/markdown/index.js.map +1 -1
  71. package/dist/{preview-QDCIVVSR.js → preview-T6CLSQVX.js} +12 -4
  72. package/dist/preview-T6CLSQVX.js.map +1 -0
  73. package/dist/query/index.d.ts +0 -11
  74. package/dist/query/index.js +2 -2
  75. package/dist/{routes-RHP5FVGD.js → routes-PVKNT777.js} +6 -6
  76. package/dist/{routes-RHP5FVGD.js.map → routes-PVKNT777.js.map} +1 -1
  77. package/dist/{search-RFBELGY7.js → search-5LC4XPB5.js} +3 -3
  78. package/dist/{search-RFBELGY7.js.map → search-5LC4XPB5.js.map} +1 -1
  79. package/dist/slide/index.d.ts +272 -1
  80. package/dist/slide/index.js +1086 -19
  81. package/dist/slide/index.js.map +1 -1
  82. package/dist/table/index.js +14 -10
  83. package/dist/table/index.js.map +1 -1
  84. package/dist/ui/index.d.ts +148 -12
  85. package/dist/ui/index.js +1340 -88
  86. package/dist/ui/index.js.map +1 -1
  87. package/dist/{upgrade-GF2P67M6.js → upgrade-6DT7ADRP.js} +7 -7
  88. package/dist/{upgrade-GF2P67M6.js.map → upgrade-6DT7ADRP.js.map} +1 -1
  89. package/dist/vite/index.d.ts +10 -0
  90. package/dist/vite/index.js +4 -4
  91. package/docs/en/agent-skills.md +1 -1
  92. package/docs/en/changelog.md +82 -0
  93. package/docs/en/cli-reference.md +30 -0
  94. package/docs/en/components.md +42 -17
  95. package/docs/en/doc/delta-text.md +40 -0
  96. package/docs/en/doc/doc-action-items.md +49 -0
  97. package/docs/en/doc/doc-callout.md +38 -0
  98. package/docs/en/doc/doc-data-table.md +60 -0
  99. package/docs/en/doc/doc-executive-summary.md +64 -0
  100. package/docs/en/doc/doc-figure.md +56 -0
  101. package/docs/en/doc/doc-key-findings.md +61 -0
  102. package/docs/en/doc/doc-kpi-scorecard.md +80 -0
  103. package/docs/en/doc/doc-notes-and-sources.md +43 -0
  104. package/docs/en/doc/doc-report-header.md +46 -0
  105. package/docs/en/pages-and-metadata.md +15 -0
  106. package/docs/en/parts/area-chart.md +99 -0
  107. package/docs/en/parts/bar-chart.md +91 -0
  108. package/docs/en/parts/bar-list.md +50 -0
  109. package/docs/en/parts/category-bar.md +37 -0
  110. package/docs/en/parts/chart-frame.md +39 -0
  111. package/docs/en/parts/data-table.md +22 -0
  112. package/docs/en/parts/delta.md +51 -0
  113. package/docs/en/parts/donut-chart.md +72 -0
  114. package/docs/en/parts/format.md +43 -0
  115. package/docs/en/parts/funnel-steps.md +2 -1
  116. package/docs/en/parts/heatmap.md +53 -0
  117. package/docs/en/parts/kpi-card.md +58 -0
  118. package/docs/en/parts/legend.md +35 -0
  119. package/docs/en/parts/line-chart.md +94 -0
  120. package/docs/en/parts/metric-value.md +3 -2
  121. package/docs/en/parts/page-shell.md +1 -1
  122. package/docs/en/parts/progress-circle.md +33 -0
  123. package/docs/en/parts/sample-data.md +39 -0
  124. package/docs/en/parts/scatter-chart.md +56 -0
  125. package/docs/en/parts/sparkline.md +1 -1
  126. package/docs/en/parts/tracker.md +36 -0
  127. package/docs/en/parts/trend-indicator.md +17 -1
  128. package/docs/en/parts/updated-at.md +30 -0
  129. package/docs/en/parts/waterfall-chart.md +56 -0
  130. package/docs/en/slide/slide-chart-full.md +48 -0
  131. package/docs/en/slide/slide-chart-insight.md +52 -0
  132. package/docs/en/slide/slide-columns.md +46 -0
  133. package/docs/en/slide/slide-comparison.md +68 -0
  134. package/docs/en/slide/slide-cover.md +39 -0
  135. package/docs/en/slide/slide-exec-summary.md +47 -0
  136. package/docs/en/slide/slide-heading.md +38 -0
  137. package/docs/en/slide/slide-kpi-grid.md +55 -0
  138. package/docs/en/slide/slide-kpi-hero.md +58 -0
  139. package/docs/en/slide/slide-next-actions.md +49 -0
  140. package/docs/en/slide/slide-scorecard-table.md +54 -0
  141. package/docs/en/slide/slide-section.md +44 -0
  142. package/docs/en/slide/slide-source-line.md +34 -0
  143. package/docs/en/ui/alert-dialog.md +42 -0
  144. package/docs/en/ui/avatar.md +31 -0
  145. package/docs/en/ui/combobox.md +74 -0
  146. package/docs/en/ui/drawer.md +41 -0
  147. package/docs/en/ui/empty.md +1 -1
  148. package/docs/en/ui/error-state.md +4 -3
  149. package/docs/en/ui/field.md +42 -0
  150. package/docs/en/ui/hover-card.md +21 -0
  151. package/docs/en/ui/kbd.md +17 -0
  152. package/docs/en/ui/loading.md +1 -1
  153. package/docs/en/ui/pagination.md +36 -0
  154. package/docs/en/ui/radio-group.md +21 -0
  155. package/docs/en/ui/toast.md +44 -0
  156. package/docs/en/ui/toggle-group.md +4 -3
  157. package/docs/en/ui-and-theming.md +1 -1
  158. package/docs/index.json +1184 -114
  159. package/docs/ja/agent-skills.md +1 -1
  160. package/docs/ja/changelog.md +84 -0
  161. package/docs/ja/cli-reference.md +29 -0
  162. package/docs/ja/components.md +68 -101
  163. package/docs/ja/doc/delta-text.md +40 -0
  164. package/docs/ja/doc/doc-action-items.md +49 -0
  165. package/docs/ja/doc/doc-callout.md +38 -0
  166. package/docs/ja/doc/doc-data-table.md +60 -0
  167. package/docs/ja/doc/doc-executive-summary.md +64 -0
  168. package/docs/ja/doc/doc-figure.md +56 -0
  169. package/docs/ja/doc/doc-key-findings.md +61 -0
  170. package/docs/ja/doc/doc-kpi-scorecard.md +80 -0
  171. package/docs/ja/doc/doc-notes-and-sources.md +43 -0
  172. package/docs/ja/doc/doc-report-header.md +46 -0
  173. package/docs/ja/page-types/csv.md +83 -0
  174. package/docs/ja/page-types/doc.md +83 -0
  175. package/docs/ja/page-types/excel.md +82 -0
  176. package/docs/ja/page-types/slide.md +133 -0
  177. package/docs/ja/page-types.md +47 -0
  178. package/docs/ja/pages-and-metadata.md +15 -0
  179. package/docs/ja/parts/area-chart.md +85 -0
  180. package/docs/ja/parts/bar-chart.md +95 -0
  181. package/docs/ja/parts/bar-list.md +58 -0
  182. package/docs/ja/parts/category-bar.md +36 -0
  183. package/docs/ja/parts/chart-frame.md +36 -0
  184. package/docs/ja/parts/data-table.md +22 -0
  185. package/docs/ja/parts/delta.md +51 -0
  186. package/docs/ja/parts/donut-chart.md +66 -0
  187. package/docs/ja/parts/echart.md +3 -0
  188. package/docs/ja/parts/format.md +44 -0
  189. package/docs/ja/parts/funnel-steps.md +27 -8
  190. package/docs/ja/parts/heatmap.md +45 -0
  191. package/docs/ja/parts/kpi-card.md +56 -0
  192. package/docs/ja/parts/legend.md +36 -0
  193. package/docs/ja/parts/line-chart.md +84 -0
  194. package/docs/ja/parts/metric-value.md +3 -2
  195. package/docs/ja/parts/page-shell.md +1 -1
  196. package/docs/ja/parts/progress-circle.md +34 -0
  197. package/docs/ja/parts/sample-data.md +61 -0
  198. package/docs/ja/parts/scatter-chart.md +69 -0
  199. package/docs/ja/parts/sparkline.md +2 -2
  200. package/docs/ja/parts/tracker.md +32 -0
  201. package/docs/ja/parts/trend-indicator.md +17 -1
  202. package/docs/ja/parts/updated-at.md +27 -0
  203. package/docs/ja/parts/waterfall-chart.md +61 -0
  204. package/docs/ja/routing.md +8 -86
  205. package/docs/ja/slide/slide-chart-full.md +48 -0
  206. package/docs/ja/slide/slide-chart-insight.md +52 -0
  207. package/docs/ja/slide/slide-columns.md +46 -0
  208. package/docs/ja/slide/slide-comparison.md +68 -0
  209. package/docs/ja/slide/slide-cover.md +39 -0
  210. package/docs/ja/slide/slide-exec-summary.md +47 -0
  211. package/docs/ja/slide/slide-heading.md +38 -0
  212. package/docs/ja/slide/slide-kpi-grid.md +55 -0
  213. package/docs/ja/slide/slide-kpi-hero.md +58 -0
  214. package/docs/ja/slide/slide-next-actions.md +49 -0
  215. package/docs/ja/slide/slide-scorecard-table.md +54 -0
  216. package/docs/ja/slide/slide-section.md +44 -0
  217. package/docs/ja/slide/slide-source-line.md +34 -0
  218. package/docs/ja/ui/alert-dialog.md +41 -0
  219. package/docs/ja/ui/avatar.md +31 -0
  220. package/docs/ja/ui/combobox.md +74 -0
  221. package/docs/ja/ui/drawer.md +41 -0
  222. package/docs/ja/ui/empty.md +1 -1
  223. package/docs/ja/ui/error-state.md +4 -3
  224. package/docs/ja/ui/field.md +42 -0
  225. package/docs/ja/ui/hover-card.md +21 -0
  226. package/docs/ja/ui/kbd.md +16 -0
  227. package/docs/ja/ui/loading.md +1 -1
  228. package/docs/ja/ui/pagination.md +36 -0
  229. package/docs/ja/ui/radio-group.md +21 -0
  230. package/docs/ja/ui/toast.md +46 -0
  231. package/docs/ja/ui/toggle-group.md +4 -3
  232. package/docs/ja/ui-and-theming.md +14 -7
  233. package/package.json +43 -29
  234. package/registry/ui/accordion.tsx +76 -0
  235. package/registry/ui/alert-dialog.tsx +189 -0
  236. package/registry/ui/alert.tsx +80 -0
  237. package/registry/ui/app-shell.tsx +424 -0
  238. package/registry/ui/area-chart.tsx +3960 -0
  239. package/registry/ui/attention-list.tsx +465 -0
  240. package/registry/ui/avatar.tsx +110 -0
  241. package/registry/ui/badge.tsx +56 -0
  242. package/registry/ui/bar-chart.tsx +3954 -0
  243. package/registry/ui/bar-list.tsx +3998 -0
  244. package/registry/ui/box-plot-chart.tsx +4214 -0
  245. package/registry/ui/breadcrumb.tsx +128 -0
  246. package/registry/ui/button.tsx +62 -0
  247. package/registry/ui/calendar.tsx +223 -0
  248. package/registry/ui/card.tsx +107 -0
  249. package/registry/ui/category-bar.tsx +1498 -0
  250. package/registry/ui/chart-frame.tsx +1604 -0
  251. package/registry/ui/checkbox.tsx +30 -0
  252. package/registry/ui/collapsible.tsx +23 -0
  253. package/registry/ui/combo-chart.tsx +1851 -0
  254. package/registry/ui/combobox.tsx +310 -0
  255. package/registry/ui/command.tsx +198 -0
  256. package/registry/ui/dashboard-card.tsx +217 -0
  257. package/registry/ui/data-table.tsx +896 -157
  258. package/registry/ui/date-range-picker.tsx +544 -0
  259. package/registry/ui/delta.tsx +350 -0
  260. package/registry/ui/dialog.tsx +161 -0
  261. package/registry/ui/donut-chart.tsx +4006 -0
  262. package/registry/ui/drawer.tsx +229 -0
  263. package/registry/ui/dropdown-menu.tsx +274 -0
  264. package/registry/ui/echart.tsx +1178 -0
  265. package/registry/ui/field.tsx +240 -0
  266. package/registry/ui/filter-bar.tsx +551 -0
  267. package/registry/ui/funnel-steps.tsx +3843 -0
  268. package/registry/ui/heatmap.tsx +2027 -0
  269. package/registry/ui/histogram-chart.tsx +4284 -0
  270. package/registry/ui/hover-card.tsx +52 -0
  271. package/registry/ui/input-group.tsx +160 -0
  272. package/registry/ui/input.tsx +24 -0
  273. package/registry/ui/kbd.tsx +30 -0
  274. package/registry/ui/kpi-card.tsx +905 -0
  275. package/registry/ui/label.tsx +22 -0
  276. package/registry/ui/legend.tsx +3817 -0
  277. package/registry/ui/line-chart.tsx +3958 -0
  278. package/registry/ui/metric-value.tsx +62 -0
  279. package/registry/ui/multi-select.tsx +382 -0
  280. package/registry/ui/page-shell.tsx +420 -0
  281. package/registry/ui/pagination.tsx +140 -0
  282. package/registry/ui/paired-chart.tsx +4086 -0
  283. package/registry/ui/pivot-table.tsx +1259 -0
  284. package/registry/ui/placeholder.tsx +36 -0
  285. package/registry/ui/popover.tsx +92 -0
  286. package/registry/ui/progress-circle.tsx +1033 -0
  287. package/registry/ui/progress.tsx +85 -0
  288. package/registry/ui/radio-group.tsx +39 -0
  289. package/registry/ui/sample-data.tsx +230 -0
  290. package/registry/ui/scatter-chart.tsx +4503 -0
  291. package/registry/ui/scroll-area.tsx +56 -0
  292. package/registry/ui/searchable-select.tsx +352 -0
  293. package/registry/ui/section-header.tsx +43 -0
  294. package/registry/ui/segmented-control.tsx +76 -0
  295. package/registry/ui/select.tsx +255 -0
  296. package/registry/ui/separator.tsx +27 -0
  297. package/registry/ui/sheet.tsx +139 -0
  298. package/registry/ui/sidebar.tsx +725 -0
  299. package/registry/ui/skeleton.tsx +17 -0
  300. package/registry/ui/slider.tsx +56 -0
  301. package/registry/ui/sparkline.tsx +230 -0
  302. package/registry/ui/spinner.tsx +14 -0
  303. package/registry/ui/states.tsx +247 -0
  304. package/registry/ui/status-badge.tsx +286 -0
  305. package/registry/ui/switch.tsx +34 -0
  306. package/registry/ui/table.tsx +118 -0
  307. package/registry/ui/tabs.tsx +84 -0
  308. package/registry/ui/textarea.tsx +22 -0
  309. package/registry/ui/toast.tsx +250 -0
  310. package/registry/ui/toggle-group.tsx +91 -0
  311. package/registry/ui/toggle.tsx +47 -0
  312. package/registry/ui/tooltip.tsx +72 -0
  313. package/registry/ui/tracker.tsx +1015 -0
  314. package/registry/ui/treemap.tsx +1916 -0
  315. package/registry/ui/trend-indicator.tsx +217 -0
  316. package/registry/ui/updated-at.tsx +276 -0
  317. package/registry/ui/waterfall-chart.tsx +4561 -0
  318. package/skills/vantage-add-feature/SKILL.md +14 -7
  319. package/skills/vantage-design/SKILL.md +62 -52
  320. package/skills/vantage-design/references/extract.md +26 -27
  321. package/skills/vantage-design/references/format.md +12 -172
  322. package/skills/vantage-design/references/presets.md +50 -110
  323. package/skills/vantage-pitfalls/SKILL.md +10 -1
  324. package/skills/vantage-slide/SKILL.md +71 -36
  325. package/templates/AGENTS.md +54 -16
  326. package/templates/agents/api.md +36 -0
  327. package/templates/agents/csv.md +2 -1
  328. package/templates/agents/doc.md +52 -3
  329. package/templates/agents/page.md +91 -10
  330. package/templates/agents/slide.md +90 -4
  331. package/templates/agents/xlsx.md +2 -1
  332. package/theme.css +247 -132
  333. package/dist/add-EISGSZAH.js +0 -6
  334. package/dist/add-EISGSZAH.js.map +0 -1
  335. package/dist/chunk-3G43C6OL.js.map +0 -1
  336. package/dist/chunk-5ZOP4SQR.js +0 -47
  337. package/dist/chunk-5ZOP4SQR.js.map +0 -1
  338. package/dist/chunk-A2UUGASH.js.map +0 -1
  339. package/dist/chunk-BCE22JSM.js.map +0 -1
  340. package/dist/chunk-DTDVSFRY.js +0 -29
  341. package/dist/chunk-DTDVSFRY.js.map +0 -1
  342. package/dist/chunk-EP6JHXSR.js.map +0 -1
  343. package/dist/chunk-JGRMRXXZ.js.map +0 -1
  344. package/dist/chunk-KLEIVDUV.js +0 -165
  345. package/dist/chunk-KLEIVDUV.js.map +0 -1
  346. package/dist/chunk-LSRMRIXA.js +0 -2227
  347. package/dist/chunk-LSRMRIXA.js.map +0 -1
  348. package/dist/chunk-PVTHHV7X.js.map +0 -1
  349. package/dist/chunk-PXRX5PEC.js.map +0 -1
  350. package/dist/chunk-RPZAALCX.js.map +0 -1
  351. package/dist/chunk-T3FLAGI6.js +0 -316
  352. package/dist/chunk-T3FLAGI6.js.map +0 -1
  353. package/dist/dev-NZRLOQCL.js.map +0 -1
  354. package/dist/doctor-VFKEMR54.js.map +0 -1
  355. package/dist/preview-QDCIVVSR.js.map +0 -1
@@ -0,0 +1,85 @@
1
+ // Copied by `vantage add ui progress`. This file is yours to edit.
2
+ // Generated from @squadbase/squadkit registry/ui/progress.tsx by `pnpm run registry` (in Vantage, edit packages/squadkit, not registry/).
3
+ "use client"
4
+
5
+ import { Progress as ProgressPrimitive } from "@base-ui/react/progress"
6
+
7
+ import { cn } from "@squadbase/vantage/ui"
8
+
9
+ function Progress({
10
+ className,
11
+ children,
12
+ value,
13
+ ...props
14
+ }: ProgressPrimitive.Root.Props) {
15
+ return (
16
+ <ProgressPrimitive.Root
17
+ value={value}
18
+ data-slot="progress"
19
+ className={cn("flex flex-wrap gap-3", className)}
20
+ {...props}
21
+ >
22
+ {children}
23
+ <ProgressTrack>
24
+ <ProgressIndicator />
25
+ </ProgressTrack>
26
+ </ProgressPrimitive.Root>
27
+ )
28
+ }
29
+
30
+ function ProgressTrack({ className, ...props }: ProgressPrimitive.Track.Props) {
31
+ return (
32
+ <ProgressPrimitive.Track
33
+ className={cn(
34
+ "relative flex h-1 w-full items-center overflow-x-hidden rounded-full bg-muted",
35
+ className
36
+ )}
37
+ data-slot="progress-track"
38
+ {...props}
39
+ />
40
+ )
41
+ }
42
+
43
+ function ProgressIndicator({
44
+ className,
45
+ ...props
46
+ }: ProgressPrimitive.Indicator.Props) {
47
+ return (
48
+ <ProgressPrimitive.Indicator
49
+ data-slot="progress-indicator"
50
+ className={cn("h-full bg-primary transition-all", className)}
51
+ {...props}
52
+ />
53
+ )
54
+ }
55
+
56
+ function ProgressLabel({ className, ...props }: ProgressPrimitive.Label.Props) {
57
+ return (
58
+ <ProgressPrimitive.Label
59
+ className={cn("text-sm font-medium", className)}
60
+ data-slot="progress-label"
61
+ {...props}
62
+ />
63
+ )
64
+ }
65
+
66
+ function ProgressValue({ className, ...props }: ProgressPrimitive.Value.Props) {
67
+ return (
68
+ <ProgressPrimitive.Value
69
+ className={cn(
70
+ "ml-auto text-sm text-muted-foreground tabular-nums",
71
+ className
72
+ )}
73
+ data-slot="progress-value"
74
+ {...props}
75
+ />
76
+ )
77
+ }
78
+
79
+ export {
80
+ Progress,
81
+ ProgressTrack,
82
+ ProgressIndicator,
83
+ ProgressLabel,
84
+ ProgressValue,
85
+ }
@@ -0,0 +1,39 @@
1
+ // Copied by `vantage add ui radio-group`. This file is yours to edit.
2
+ // Generated from @squadbase/squadkit registry/ui/radio-group.tsx by `pnpm run registry` (in Vantage, edit packages/squadkit, not registry/).
3
+ "use client"
4
+
5
+ import { Radio as RadioPrimitive } from "@base-ui/react/radio"
6
+ import { RadioGroup as RadioGroupPrimitive } from "@base-ui/react/radio-group"
7
+ import { cn } from "@squadbase/vantage/ui"
8
+
9
+ function RadioGroup({ className, ...props }: RadioGroupPrimitive.Props) {
10
+ return (
11
+ <RadioGroupPrimitive
12
+ data-slot="radio-group"
13
+ className={cn("grid w-full gap-2", className)}
14
+ {...props}
15
+ />
16
+ )
17
+ }
18
+
19
+ function RadioGroupItem({ className, ...props }: RadioPrimitive.Root.Props) {
20
+ return (
21
+ <RadioPrimitive.Root
22
+ data-slot="radio-group-item"
23
+ className={cn(
24
+ "group/radio-group-item peer relative flex aspect-square size-4 shrink-0 rounded-full border border-input outline-none group-has-[:focus-visible]/field-label:ring-0 group-has-[:focus-visible]/field-label:not-data-checked:border-input after:absolute after:-inset-x-3 after:-inset-y-2 focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 aria-invalid:aria-checked:border-primary dark:bg-input/30 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 data-checked:border-primary data-checked:bg-primary data-checked:text-primary-foreground group-has-[:focus-visible]/field-label:data-checked:border-primary dark:data-checked:bg-primary",
25
+ className
26
+ )}
27
+ {...props}
28
+ >
29
+ <RadioPrimitive.Indicator
30
+ data-slot="radio-group-indicator"
31
+ className="flex size-4 items-center justify-center"
32
+ >
33
+ <span className="absolute top-1/2 left-1/2 size-2 -translate-x-1/2 -translate-y-1/2 rounded-full bg-primary-foreground" />
34
+ </RadioPrimitive.Indicator>
35
+ </RadioPrimitive.Root>
36
+ )
37
+ }
38
+
39
+ export { RadioGroup, RadioGroupItem }
@@ -0,0 +1,230 @@
1
+ // Copied by `vantage add ui sample-data`. This file is yours to edit.
2
+ // Generated from @squadbase/squadkit registry/components/sample-data.tsx by `pnpm run registry` (in Vantage, edit packages/squadkit, not registry/).
3
+ "use client"
4
+
5
+ /**
6
+ * SampleData — marks the values inside it as a sample: they are not connected to real data yet
7
+ * (a draft laid out before its queries are wired, a screen built from column definitions only).
8
+ * Not the same as `provisional` on KpiCard and the charts, which means 速報 — real values that are
9
+ * not final yet. For a single value in running text or a heading, use `Placeholder` instead.
10
+ *
11
+ * - **No box of its own.** It renders `display: contents`, so the grid / subgrid of the parent
12
+ * still sees the cards inside as its direct children (KpiCard rows keep lining up).
13
+ * - **The card shows the mark.** The nearest `KpiCard` or `DashboardCardPreset` inside it puts a
14
+ * `SampleBadge` in its header, once (also while loading): a card claims the mark, so the parts
15
+ * anywhere inside that card (body, actions, footer) do not repeat it. Put a bare chart in a
16
+ * `DashboardCardPreset` to have it marked.
17
+ * - The mark is a word, not only a colour (`--warning` on `--warning-subtle`), and its
18
+ * `title` says what it means.
19
+ *
20
+ * @example
21
+ * import { SampleData } from "@/components/sample-data"
22
+ * // Vantage: import { SampleData } from "@squadbase/vantage/components"
23
+ * <SampleData>
24
+ * <KpiCard label="売上" value={12400000} format={{ type: "currency", currency: "JPY" }} />
25
+ * </SampleData>
26
+ */
27
+ import { createContext, useContext, useMemo, type HTMLAttributes, type ReactNode } from "react"
28
+
29
+ import { cn } from "@squadbase/vantage/ui"
30
+ import { Badge } from "@squadbase/vantage/ui"
31
+ import { useSyncExternalStore } from "react"
32
+
33
+ /* ---------- inlined from @squadbase/squadkit registry/lib/locale.ts (internal to @squadbase/vantage) ---------- */
34
+
35
+ /**
36
+ * The display language of the parts and the defaults that follow it.
37
+ *
38
+ * The language comes from `<html lang>`: a tag starting with `ja` reads Japanese, anything else English.
39
+ * Without a usable `lang` (missing, invalid, or no `document` — SSR, Node) the locale is `FALLBACK_LOCALE`
40
+ * (`en-US`). A `locale` passed explicitly (a prop, an argument) always wins.
41
+ *
42
+ * Parts read the locale through `useLocale` (`hooks/use-locale`) and pass it down; the pure helpers here
43
+ * and in `format` / `comparison` / `chart-*` take it as an argument and fall back to `documentLocale()`.
44
+ */
45
+
46
+ /** The language of the built-in wording: Japanese or English. */
47
+ type UiLanguage = "ja" | "en"
48
+
49
+ /** The locale used when `<html lang>` gives none (and on the server). */
50
+ const FALLBACK_LOCALE = "en-US"
51
+
52
+ /** `"ja"` when `locale` starts with `ja` (`ja`, `ja-JP`), else `"en"`. A missing locale is `"en"`. */
53
+ function uiLanguage(locale: string | null | undefined): UiLanguage {
54
+ return typeof locale === "string" && locale.trim().toLowerCase().startsWith("ja") ? "ja" : "en"
55
+ }
56
+
57
+ /** A BCP 47 tag in its canonical form (`en-gb` → `en-GB`), or `FALLBACK_LOCALE` when it is empty or invalid. */
58
+ function normalizeLocale(tag: string | null | undefined): string {
59
+ const value = tag?.trim()
60
+ if (!value) return FALLBACK_LOCALE
61
+ try {
62
+ return Intl.getCanonicalLocales(value)[0] ?? FALLBACK_LOCALE
63
+ } catch {
64
+ return FALLBACK_LOCALE
65
+ }
66
+ }
67
+
68
+ /**
69
+ * The locale of the page: `document.documentElement.lang`, canonicalized. `FALLBACK_LOCALE` when it is empty or
70
+ * invalid, or there is no `document`. Parts read it through `useLocale`, never while rendering.
71
+ */
72
+ function documentLocale(): string {
73
+ if (typeof document === "undefined") return FALLBACK_LOCALE
74
+ return normalizeLocale(document.documentElement?.getAttribute("lang"))
75
+ }
76
+
77
+ /** `locale` when given, else the page's locale (`documentLocale()`). */
78
+ function resolveLocale(locale?: string | null): string {
79
+ return locale || documentLocale()
80
+ }
81
+
82
+ /** Picks the wording table of the locale's language. */
83
+ function pickLocale<T>(table: { ja: T; en: T }, locale?: string | null): T {
84
+ return table[uiLanguage(resolveLocale(locale))]
85
+ }
86
+
87
+ /** The currency `format="currency"` uses without a `currency`: JPY for Japanese, USD otherwise. */
88
+ function defaultCurrency(locale?: string | null): string {
89
+ return uiLanguage(resolveLocale(locale)) === "ja" ? "JPY" : "USD"
90
+ }
91
+
92
+ /** The month a fiscal year starts in (1–12) when none is given: April for Japanese, January otherwise. */
93
+ function defaultFiscalYearStartMonth(locale?: string | null): number {
94
+ return uiLanguage(resolveLocale(locale)) === "ja" ? 4 : 1
95
+ }
96
+
97
+ /** A day of the week, 0 = Sunday … 6 = Saturday (the `Date#getDay` / date-fns numbering). */
98
+ type WeekDay = 0 | 1 | 2 | 3 | 4 | 5 | 6
99
+
100
+ /** Locales whose week starts on Sunday when the runtime has no week data. */
101
+ const SUNDAY_FIRST = new Set(["en", "en-US", "en-CA"])
102
+
103
+ /**
104
+ * The first day of the week: Monday for Japanese; otherwise the locale's convention from `Intl.Locale`
105
+ * (`en-US` Sunday, `en-GB` Monday). Without week data in the runtime: Sunday for `en` / `en-US` / `en-CA`,
106
+ * Monday for the rest.
107
+ */
108
+ function weekStartsOn(locale?: string | null): WeekDay {
109
+ const tag = normalizeLocale(resolveLocale(locale))
110
+ if (uiLanguage(tag) === "ja") return 1
111
+ try {
112
+ const info = new Intl.Locale(tag) as Intl.Locale & {
113
+ getWeekInfo?: () => { firstDay: number }
114
+ weekInfo?: { firstDay: number }
115
+ }
116
+ const firstDay = info.getWeekInfo?.().firstDay ?? info.weekInfo?.firstDay
117
+ if (typeof firstDay === "number" && firstDay >= 1 && firstDay <= 7) return (firstDay % 7) as WeekDay
118
+ } catch {
119
+ // Fall through to the table below.
120
+ }
121
+ return SUNDAY_FIRST.has(tag) ? 0 : 1
122
+ }
123
+
124
+ /* ---------- inlined from @squadbase/squadkit registry/hooks/use-locale.ts (internal to @squadbase/vantage) ---------- */
125
+
126
+ const listeners = new Set<() => void>()
127
+ let observer: MutationObserver | null = null
128
+
129
+ /** One observer on `<html lang>` for every subscribed part. */
130
+ function subscribe(onChange: () => void): () => void {
131
+ if (typeof document === "undefined" || typeof MutationObserver === "undefined") return () => {}
132
+ listeners.add(onChange)
133
+ if (!observer) {
134
+ observer = new MutationObserver(() => {
135
+ for (const listener of [...listeners]) listener()
136
+ })
137
+ observer.observe(document.documentElement, { attributes: true, attributeFilter: ["lang"] })
138
+ }
139
+ return () => {
140
+ listeners.delete(onChange)
141
+ if (listeners.size === 0 && observer) {
142
+ observer.disconnect()
143
+ observer = null
144
+ }
145
+ }
146
+ }
147
+
148
+ const serverLocale = () => FALLBACK_LOCALE
149
+
150
+ /**
151
+ * The page's locale (`<html lang>`), following changes made while the page runs. On the server and during
152
+ * hydration it is `FALLBACK_LOCALE` (`en-US`), so the markup matches; it switches right after.
153
+ */
154
+ function useDocumentLocale(): string {
155
+ return useSyncExternalStore(subscribe, documentLocale, serverLocale)
156
+ }
157
+
158
+ /** The locale a part renders in: its `locale` prop when given, else the page's (`useDocumentLocale`). */
159
+ function useLocale(locale?: string | null): string {
160
+ const page = useDocumentLocale()
161
+ return locale || page
162
+ }
163
+
164
+ /* ---------- end of inlined code ---------- */
165
+
166
+ const TEXT = {
167
+ ja: { label: "見本の値", title: "実データにまだつながっていない見本の値です" },
168
+ en: { label: "Sample data", title: "Sample values, not connected to real data yet" },
169
+ }
170
+
171
+ /**
172
+ * The mark's wording in English (the fallback language). Without a `label`, the mark follows the page's
173
+ * language (`<html lang>`): ja reads「見本の値」.
174
+ */
175
+ export const DEFAULT_SAMPLE_LABEL = TEXT.en.label
176
+
177
+ interface SampleState {
178
+ label: string
179
+ }
180
+
181
+ const SampleContext = createContext<SampleState | null>(null)
182
+
183
+ /**
184
+ * The mark a card inside `SampleData` should show, or null. A card that shows it wraps its
185
+ * content in `<SampleClaim>` so the parts inside do not show it again.
186
+ */
187
+ export function useSampleMark(): SampleState | null {
188
+ return useContext(SampleContext)
189
+ }
190
+
191
+ /** Ends the `SampleData` scope for the parts inside a card that already shows the mark. */
192
+ export function SampleClaim({ children }: { children?: ReactNode }) {
193
+ return <SampleContext.Provider value={null}>{children}</SampleContext.Provider>
194
+ }
195
+
196
+ export interface SampleBadgeProps extends HTMLAttributes<HTMLSpanElement> {
197
+ /** 印の文言。既定はページの言語で「見本の値」(英語は "Sample data")。 */
198
+ label?: string
199
+ }
200
+
201
+ export function SampleBadge({ label, className, ...props }: SampleBadgeProps) {
202
+ const t = TEXT[uiLanguage(useLocale())]
203
+ return (
204
+ <Badge
205
+ data-slot="sample-badge"
206
+ title={t.title}
207
+ className={cn("border-warning/20 dark:border-warning/25 bg-warning-subtle text-warning align-middle", className)}
208
+ {...props}
209
+ >
210
+ {label ?? t.label}
211
+ </Badge>
212
+ )
213
+ }
214
+
215
+ export interface SampleDataProps {
216
+ /** 印の文言。既定はページの言語で「見本の値」(英語は "Sample data")。 */
217
+ label?: string
218
+ children?: ReactNode
219
+ }
220
+
221
+ export function SampleData({ label, children }: SampleDataProps) {
222
+ const shown = label ?? TEXT[uiLanguage(useLocale())].label
223
+ // A stable value, so the cards inside do not re-render when only the parent does.
224
+ const state = useMemo(() => ({ label: shown }), [shown])
225
+ return (
226
+ <div data-slot="sample-data" style={{ display: "contents" }}>
227
+ <SampleContext.Provider value={state}>{children}</SampleContext.Provider>
228
+ </div>
229
+ )
230
+ }