@cloudflare/kumo 1.15.0 → 1.17.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 (266) hide show
  1. package/CHANGELOG.md +144 -0
  2. package/ai/USAGE.md +3 -1
  3. package/ai/component-registry.json +511 -66
  4. package/ai/component-registry.md +776 -59
  5. package/ai/schemas.ts +33 -7
  6. package/dist/.build-complete +1 -1
  7. package/dist/ai/schemas.d.ts +158 -39
  8. package/dist/ai/schemas.d.ts.map +1 -1
  9. package/dist/ai/schemas.js +456 -418
  10. package/dist/ai/schemas.js.map +1 -1
  11. package/dist/chunks/{Legend-mkh1v83sz972e29d.js → Legend-o0ntojbaplmszwk0.js} +115 -101
  12. package/dist/chunks/Legend-o0ntojbaplmszwk0.js.map +1 -0
  13. package/dist/chunks/badge-n80t3z8u9ttlxi20.js +120 -0
  14. package/dist/chunks/badge-n80t3z8u9ttlxi20.js.map +1 -0
  15. package/dist/chunks/banner-nz0eryqnz3qd86ln.js +79 -0
  16. package/dist/chunks/banner-nz0eryqnz3qd86ln.js.map +1 -0
  17. package/dist/chunks/{breadcrumbs-m79gm4gjwbfajpna.js → breadcrumbs-cjgn3w4drahvqnuj.js} +3 -3
  18. package/dist/chunks/{breadcrumbs-m79gm4gjwbfajpna.js.map → breadcrumbs-cjgn3w4drahvqnuj.js.map} +1 -1
  19. package/dist/chunks/{button-j0hi0afn33w9lxgi.js → button-odxi0hp4fvi5i2w3.js} +50 -48
  20. package/dist/chunks/button-odxi0hp4fvi5i2w3.js.map +1 -0
  21. package/dist/chunks/{checkbox-bvzuggmadtqawis4.js → checkbox-dx8x0rzv582yjv7n.js} +38 -47
  22. package/dist/chunks/{checkbox-bvzuggmadtqawis4.js.map → checkbox-dx8x0rzv582yjv7n.js.map} +1 -1
  23. package/dist/chunks/{clipboard-text-mwcknzn75qdvigrd.js → clipboard-text-kyk51d1ze7zvdn4q.js} +55 -54
  24. package/dist/chunks/clipboard-text-kyk51d1ze7zvdn4q.js.map +1 -0
  25. package/dist/chunks/{combobox-ndbaroqh1c0u49ye.js → combobox-9fhjzprab46csmon.js} +97 -82
  26. package/dist/chunks/combobox-9fhjzprab46csmon.js.map +1 -0
  27. package/dist/chunks/{command-palette-ejoszjfivybu9yi5.js → command-palette-kenx2bbdzd4kpx36.js} +158 -154
  28. package/dist/chunks/command-palette-kenx2bbdzd4kpx36.js.map +1 -0
  29. package/dist/chunks/{dialog-gkmecnx48ge38jrr.js → dialog-e05ysa8t2fklw065.js} +22 -20
  30. package/dist/chunks/dialog-e05ysa8t2fklw065.js.map +1 -0
  31. package/dist/chunks/{dropdown-i8n7nv3cvkvb1x3e.js → dropdown-g587px7zv3ssaxr4.js} +96 -90
  32. package/dist/chunks/dropdown-g587px7zv3ssaxr4.js.map +1 -0
  33. package/dist/chunks/{empty-hrwtammqp0b2nvtf.js → empty-fuz1un7r7mbz0kim.js} +2 -2
  34. package/dist/chunks/{empty-hrwtammqp0b2nvtf.js.map → empty-fuz1un7r7mbz0kim.js.map} +1 -1
  35. package/dist/chunks/{field-lweivfadxgpqhuqi.js → field-fq504lyu7ttsh5m9.js} +3 -3
  36. package/dist/chunks/{field-lweivfadxgpqhuqi.js.map → field-fq504lyu7ttsh5m9.js.map} +1 -1
  37. package/dist/chunks/hcl-hcu7d6ja6t540ijn.js +8 -0
  38. package/dist/chunks/hcl-hcu7d6ja6t540ijn.js.map +1 -0
  39. package/dist/chunks/{input-area-obli4ufvu40bfpgp.js → input-area-nq40szg9110on89c.js} +4 -4
  40. package/dist/chunks/{input-area-obli4ufvu40bfpgp.js.map → input-area-nq40szg9110on89c.js.map} +1 -1
  41. package/dist/chunks/{input-group-dwtsd04lzf2bcsdo.js → input-group-hbebbyh8fo6aqydn.js} +3 -3
  42. package/dist/chunks/{input-group-dwtsd04lzf2bcsdo.js.map → input-group-hbebbyh8fo6aqydn.js.map} +1 -1
  43. package/dist/chunks/{input-ko2dne1givlxq7sz.js → input-kvhyo3p4859bexvx.js} +4 -4
  44. package/dist/chunks/input-kvhyo3p4859bexvx.js.map +1 -0
  45. package/dist/chunks/{label-kjahhybc191quieo.js → label-j9owppbgnn35mebg.js} +3 -3
  46. package/dist/chunks/{label-kjahhybc191quieo.js.map → label-j9owppbgnn35mebg.js.map} +1 -1
  47. package/dist/chunks/{layer-card-mu2w82x6ko1nhhtr.js → layer-card-l5yjvrxry1dhte57.js} +8 -8
  48. package/dist/chunks/{layer-card-mu2w82x6ko1nhhtr.js.map → layer-card-l5yjvrxry1dhte57.js.map} +1 -1
  49. package/dist/chunks/{link-lpzl5s47pmobk361.js → link-hmmf3k1xn6rm72rt.js} +2 -2
  50. package/dist/chunks/{link-lpzl5s47pmobk361.js.map → link-hmmf3k1xn6rm72rt.js.map} +1 -1
  51. package/dist/chunks/{menubar-ifxxdoa35zz79z1q.js → menubar-abojnm0uwjuni8ok.js} +20 -20
  52. package/dist/chunks/menubar-abojnm0uwjuni8ok.js.map +1 -0
  53. package/dist/chunks/{meter-fbtqfg0okpwmaiju.js → meter-i84dte2f82qmvn7y.js} +2 -2
  54. package/dist/chunks/{meter-fbtqfg0okpwmaiju.js.map → meter-i84dte2f82qmvn7y.js.map} +1 -1
  55. package/dist/chunks/{pagination-eo0gzzm7v5w8niqe.js → pagination-pbd7qqik97ac0l7m.js} +3 -3
  56. package/dist/chunks/{pagination-eo0gzzm7v5w8niqe.js.map → pagination-pbd7qqik97ac0l7m.js.map} +1 -1
  57. package/dist/chunks/{popover-dd7hi5ajeoq9od1i.js → popover-i951xjcgezeqr4iv.js} +31 -28
  58. package/dist/chunks/popover-i951xjcgezeqr4iv.js.map +1 -0
  59. package/dist/chunks/portal-provider-hwmkdmkpvct0cb76.js +18 -0
  60. package/dist/chunks/portal-provider-hwmkdmkpvct0cb76.js.map +1 -0
  61. package/dist/chunks/{radio-oi9iw7ls1t04j377.js → radio-l2vkcue40d84fmo1.js} +13 -16
  62. package/dist/chunks/{radio-oi9iw7ls1t04j377.js.map → radio-l2vkcue40d84fmo1.js.map} +1 -1
  63. package/dist/chunks/{select-0m0xklfwdlx8dwba.js → select-paedwa3nlhpq82ua.js} +39 -37
  64. package/dist/chunks/select-paedwa3nlhpq82ua.js.map +1 -0
  65. package/dist/chunks/{sensitive-input-rjpykxn2llh0thx1.js → sensitive-input-kznmknpp5h1grc6k.js} +97 -91
  66. package/dist/chunks/sensitive-input-kznmknpp5h1grc6k.js.map +1 -0
  67. package/dist/chunks/sidebar-jepeq7gaf4issuw6.js +875 -0
  68. package/dist/chunks/sidebar-jepeq7gaf4issuw6.js.map +1 -0
  69. package/dist/chunks/skeleton-line-epxenksfesr2fkcv.js +33 -0
  70. package/dist/chunks/skeleton-line-epxenksfesr2fkcv.js.map +1 -0
  71. package/dist/chunks/surface-blo81kgy9g0sexgm.js +36 -0
  72. package/dist/chunks/surface-blo81kgy9g0sexgm.js.map +1 -0
  73. package/dist/chunks/{switch-lv4mrrkfl5uc99xo.js → switch-i0zwcp3wq6vsxm1c.js} +64 -64
  74. package/dist/chunks/{switch-lv4mrrkfl5uc99xo.js.map → switch-i0zwcp3wq6vsxm1c.js.map} +1 -1
  75. package/dist/chunks/table-nrcw19tlpduayukl.js +183 -0
  76. package/dist/chunks/table-nrcw19tlpduayukl.js.map +1 -0
  77. package/dist/chunks/tabs-bw92jb303zxw7w4f.js +92 -0
  78. package/dist/chunks/{tabs-hy6oa7xtf96d9mxt.js.map → tabs-bw92jb303zxw7w4f.js.map} +1 -1
  79. package/dist/chunks/{text-gzt92mlji1lug13d.js → text-nmyi1rkwdj37f30f.js} +24 -22
  80. package/dist/chunks/text-nmyi1rkwdj37f30f.js.map +1 -0
  81. package/dist/chunks/{toast-kswfqmjysxcrwij3.js → toast-lrnwby56drs7vtae.js} +61 -59
  82. package/dist/chunks/toast-lrnwby56drs7vtae.js.map +1 -0
  83. package/dist/chunks/toml-nczb2z9n0o23o3ci.js +8 -0
  84. package/dist/chunks/toml-nczb2z9n0o23o3ci.js.map +1 -0
  85. package/dist/chunks/{tooltip-k68wcv9mrigb7rcb.js → tooltip-cit9ltlxfuhwctuj.js} +24 -21
  86. package/dist/chunks/tooltip-cit9ltlxfuhwctuj.js.map +1 -0
  87. package/dist/chunks/{vendor-base-ui-cpvkrhz4zgw9nw2b.js → vendor-base-ui-n30qblevnpk9cc5c.js} +551 -549
  88. package/dist/chunks/{vendor-base-ui-cpvkrhz4zgw9nw2b.js.map → vendor-base-ui-n30qblevnpk9cc5c.js.map} +1 -1
  89. package/dist/code/server.js +11 -9
  90. package/dist/code/server.js.map +1 -1
  91. package/dist/code.js +16 -14
  92. package/dist/code.js.map +1 -1
  93. package/dist/components/badge.js +1 -1
  94. package/dist/components/banner.js +1 -1
  95. package/dist/components/breadcrumbs.js +1 -1
  96. package/dist/components/button.js +1 -1
  97. package/dist/components/chart.js +1 -1
  98. package/dist/components/checkbox.js +1 -1
  99. package/dist/components/clipboard-text.js +1 -1
  100. package/dist/components/combobox.js +1 -1
  101. package/dist/components/command-palette.js +1 -1
  102. package/dist/components/dialog.js +1 -1
  103. package/dist/components/dropdown.js +1 -1
  104. package/dist/components/empty.js +1 -1
  105. package/dist/components/field.js +1 -1
  106. package/dist/components/flow.js +2142 -2090
  107. package/dist/components/flow.js.map +1 -1
  108. package/dist/components/input.js +3 -3
  109. package/dist/components/label.js +1 -1
  110. package/dist/components/layer-card.js +1 -1
  111. package/dist/components/link.js +1 -1
  112. package/dist/components/loader.js +1 -1
  113. package/dist/components/menubar.js +1 -1
  114. package/dist/components/meter.js +1 -1
  115. package/dist/components/pagination.js +1 -1
  116. package/dist/components/popover.js +1 -1
  117. package/dist/components/radio.js +1 -1
  118. package/dist/components/select.js +1 -1
  119. package/dist/components/sensitive-input.js +1 -1
  120. package/dist/components/sidebar.js +35 -0
  121. package/dist/components/sidebar.js.map +1 -0
  122. package/dist/components/surface.js +1 -1
  123. package/dist/components/switch.js +1 -1
  124. package/dist/components/table.js +1 -1
  125. package/dist/components/tabs.js +1 -1
  126. package/dist/components/text.js +1 -1
  127. package/dist/components/toast.js +2 -2
  128. package/dist/components/tooltip.js +1 -1
  129. package/dist/index.js +192 -159
  130. package/dist/index.js.map +1 -1
  131. package/dist/primitives/accordion.js +1 -1
  132. package/dist/primitives/alert-dialog.js +1 -1
  133. package/dist/primitives/autocomplete.js +1 -1
  134. package/dist/primitives/avatar.js +1 -1
  135. package/dist/primitives/button.js +1 -1
  136. package/dist/primitives/checkbox-group.js +1 -1
  137. package/dist/primitives/checkbox.js +1 -1
  138. package/dist/primitives/collapsible.js +1 -1
  139. package/dist/primitives/combobox.js +1 -1
  140. package/dist/primitives/context-menu.js +1 -1
  141. package/dist/primitives/csp-provider.js +1 -1
  142. package/dist/primitives/dialog.js +1 -1
  143. package/dist/primitives/direction-provider.js +1 -1
  144. package/dist/primitives/drawer.js +1 -1
  145. package/dist/primitives/field.js +1 -1
  146. package/dist/primitives/fieldset.js +1 -1
  147. package/dist/primitives/form.js +1 -1
  148. package/dist/primitives/input.js +1 -1
  149. package/dist/primitives/menu.js +1 -1
  150. package/dist/primitives/menubar.js +1 -1
  151. package/dist/primitives/meter.js +1 -1
  152. package/dist/primitives/navigation-menu.js +1 -1
  153. package/dist/primitives/number-field.js +1 -1
  154. package/dist/primitives/popover.js +1 -1
  155. package/dist/primitives/preview-card.js +1 -1
  156. package/dist/primitives/progress.js +1 -1
  157. package/dist/primitives/radio-group.js +1 -1
  158. package/dist/primitives/radio.js +1 -1
  159. package/dist/primitives/scroll-area.js +1 -1
  160. package/dist/primitives/select.js +1 -1
  161. package/dist/primitives/separator.js +1 -1
  162. package/dist/primitives/slider.js +1 -1
  163. package/dist/primitives/switch.js +1 -1
  164. package/dist/primitives/tabs.js +1 -1
  165. package/dist/primitives/toast.js +1 -1
  166. package/dist/primitives/toggle-group.js +1 -1
  167. package/dist/primitives/toggle.js +1 -1
  168. package/dist/primitives/toolbar.js +1 -1
  169. package/dist/primitives/tooltip.js +1 -1
  170. package/dist/primitives.js +1 -1
  171. package/dist/scripts/theme-generator/config.d.ts.map +1 -1
  172. package/dist/scripts/theme-generator/config.js +288 -24
  173. package/dist/scripts/theme-generator/config.js.map +1 -1
  174. package/dist/src/code/provider.d.ts.map +1 -1
  175. package/dist/src/code/server.d.ts.map +1 -1
  176. package/dist/src/code/types.d.ts +1 -1
  177. package/dist/src/code/types.d.ts.map +1 -1
  178. package/dist/src/components/badge/badge.d.ts +95 -22
  179. package/dist/src/components/badge/badge.d.ts.map +1 -1
  180. package/dist/src/components/banner/banner.d.ts +2 -0
  181. package/dist/src/components/banner/banner.d.ts.map +1 -1
  182. package/dist/src/components/button/button.d.ts +2 -0
  183. package/dist/src/components/button/button.d.ts.map +1 -1
  184. package/dist/src/components/chart/EChart.d.ts.map +1 -1
  185. package/dist/src/components/chart/TimeseriesChart.d.ts +11 -1
  186. package/dist/src/components/chart/TimeseriesChart.d.ts.map +1 -1
  187. package/dist/src/components/checkbox/checkbox.d.ts.map +1 -1
  188. package/dist/src/components/clipboard-text/clipboard-text.d.ts +2 -0
  189. package/dist/src/components/clipboard-text/clipboard-text.d.ts.map +1 -1
  190. package/dist/src/components/combobox/combobox.d.ts +8 -1
  191. package/dist/src/components/combobox/combobox.d.ts.map +1 -1
  192. package/dist/src/components/command-palette/command-palette.d.ts +9 -2
  193. package/dist/src/components/command-palette/command-palette.d.ts.map +1 -1
  194. package/dist/src/components/command-palette/types.d.ts +7 -0
  195. package/dist/src/components/command-palette/types.d.ts.map +1 -1
  196. package/dist/src/components/dialog/dialog.d.ts +8 -1
  197. package/dist/src/components/dialog/dialog.d.ts.map +1 -1
  198. package/dist/src/components/dropdown/dropdown.d.ts +17 -2
  199. package/dist/src/components/dropdown/dropdown.d.ts.map +1 -1
  200. package/dist/src/components/flow/diagram.d.ts.map +1 -1
  201. package/dist/src/components/flow/node.d.ts.map +1 -1
  202. package/dist/src/components/flow/parallel.d.ts.map +1 -1
  203. package/dist/src/components/loader/skeleton-line.d.ts +2 -1
  204. package/dist/src/components/loader/skeleton-line.d.ts.map +1 -1
  205. package/dist/src/components/popover/popover.d.ts +8 -1
  206. package/dist/src/components/popover/popover.d.ts.map +1 -1
  207. package/dist/src/components/radio/radio.d.ts.map +1 -1
  208. package/dist/src/components/select/select.d.ts +8 -1
  209. package/dist/src/components/select/select.d.ts.map +1 -1
  210. package/dist/src/components/sensitive-input/sensitive-input.d.ts.map +1 -1
  211. package/dist/src/components/sidebar/index.d.ts +2 -0
  212. package/dist/src/components/sidebar/index.d.ts.map +1 -0
  213. package/dist/src/components/sidebar/sidebar.d.ts +556 -0
  214. package/dist/src/components/sidebar/sidebar.d.ts.map +1 -0
  215. package/dist/src/components/surface/surface.d.ts +23 -23
  216. package/dist/src/components/surface/surface.d.ts.map +1 -1
  217. package/dist/src/components/table/table.d.ts +34 -2
  218. package/dist/src/components/table/table.d.ts.map +1 -1
  219. package/dist/src/components/tabs/tabs.d.ts.map +1 -1
  220. package/dist/src/components/text/text.d.ts +5 -0
  221. package/dist/src/components/text/text.d.ts.map +1 -1
  222. package/dist/src/components/toast/toast.d.ts +16 -9
  223. package/dist/src/components/toast/toast.d.ts.map +1 -1
  224. package/dist/src/components/tooltip/tooltip.d.ts +11 -6
  225. package/dist/src/components/tooltip/tooltip.d.ts.map +1 -1
  226. package/dist/src/index.d.ts +2 -0
  227. package/dist/src/index.d.ts.map +1 -1
  228. package/dist/src/utils/index.d.ts +1 -0
  229. package/dist/src/utils/index.d.ts.map +1 -1
  230. package/dist/src/utils/portal-provider.d.ts +56 -0
  231. package/dist/src/utils/portal-provider.d.ts.map +1 -0
  232. package/dist/styles/kumo-binding.css +49 -46
  233. package/dist/styles/kumo-standalone.css +1 -1
  234. package/dist/styles/theme-fedramp.css +3 -3
  235. package/dist/styles/theme-kumo.css +202 -22
  236. package/dist/utils.js +8 -6
  237. package/dist/utils.js.map +1 -1
  238. package/package.json +7 -3
  239. package/scripts/component-registry/index.ts +12 -0
  240. package/scripts/theme-generator/config.ts +298 -24
  241. package/dist/chunks/Legend-mkh1v83sz972e29d.js.map +0 -1
  242. package/dist/chunks/badge-mrshucy2530o70cq.js +0 -56
  243. package/dist/chunks/badge-mrshucy2530o70cq.js.map +0 -1
  244. package/dist/chunks/banner-vzdjbqsb6em7tmdk.js +0 -75
  245. package/dist/chunks/banner-vzdjbqsb6em7tmdk.js.map +0 -1
  246. package/dist/chunks/button-j0hi0afn33w9lxgi.js.map +0 -1
  247. package/dist/chunks/clipboard-text-mwcknzn75qdvigrd.js.map +0 -1
  248. package/dist/chunks/combobox-ndbaroqh1c0u49ye.js.map +0 -1
  249. package/dist/chunks/command-palette-ejoszjfivybu9yi5.js.map +0 -1
  250. package/dist/chunks/dialog-gkmecnx48ge38jrr.js.map +0 -1
  251. package/dist/chunks/dropdown-i8n7nv3cvkvb1x3e.js.map +0 -1
  252. package/dist/chunks/input-ko2dne1givlxq7sz.js.map +0 -1
  253. package/dist/chunks/menubar-ifxxdoa35zz79z1q.js.map +0 -1
  254. package/dist/chunks/popover-dd7hi5ajeoq9od1i.js.map +0 -1
  255. package/dist/chunks/select-0m0xklfwdlx8dwba.js.map +0 -1
  256. package/dist/chunks/sensitive-input-rjpykxn2llh0thx1.js.map +0 -1
  257. package/dist/chunks/skeleton-line-1j5exu6vv07mmhfb.js +0 -28
  258. package/dist/chunks/skeleton-line-1j5exu6vv07mmhfb.js.map +0 -1
  259. package/dist/chunks/surface-dhshylwccuaz91d1.js +0 -21
  260. package/dist/chunks/surface-dhshylwccuaz91d1.js.map +0 -1
  261. package/dist/chunks/table-fh7jmfip27vdapxm.js +0 -155
  262. package/dist/chunks/table-fh7jmfip27vdapxm.js.map +0 -1
  263. package/dist/chunks/tabs-hy6oa7xtf96d9mxt.js +0 -86
  264. package/dist/chunks/text-gzt92mlji1lug13d.js.map +0 -1
  265. package/dist/chunks/toast-kswfqmjysxcrwij3.js.map +0 -1
  266. package/dist/chunks/tooltip-k68wcv9mrigb7rcb.js.map +0 -1
@@ -16,13 +16,28 @@ Small status label for categorizing or highlighting content.
16
16
 
17
17
  **Props:**
18
18
 
19
- - `variant`: enum [default: primary]
20
- - `"primary"`: Default high-emphasis badge for important labels
21
- - `"secondary"`: Subtle badge for secondary information
22
- - `"destructive"`: Error or danger state indicator
23
- - `"success"`: Success or positive state indicator
19
+ - `variant`: enum [default: neutral]
20
+ - `"red"`: Red badge
21
+ - `"red-subtle"`: Subtle red badge
22
+ - `"orange"`: Orange badge
23
+ - `"orange-subtle"`: Subtle orange badge
24
+ - `"yellow"`: Yellow badge
25
+ - `"yellow-subtle"`: Subtle yellow badge
26
+ - `"green"`: Green badge
27
+ - `"green-subtle"`: Subtle green badge
28
+ - `"teal"`: Teal badge
29
+ - `"teal-subtle"`: Subtle teal badge
30
+ - `"blue"`: Blue badge
31
+ - `"blue-subtle"`: Subtle blue badge
32
+ - `"neutral"`: Neutral badge
33
+ - `"neutral-subtle"`: Subtle neutral badge
34
+ - `"inverted"`: Inverted badge
24
35
  - `"outline"`: Bordered badge with transparent background
25
36
  - `"beta"`: Indicates beta or experimental features
37
+ - `"primary"`: Deprecated. Use inverted instead.
38
+ - `"secondary"`: Deprecated. Use neutral instead.
39
+ - `"destructive"`: Deprecated. Use red instead.
40
+ - `"success"`: Deprecated. Use green instead.
26
41
  - `className`: string
27
42
  Additional CSS classes merged via `cn()`.
28
43
  - `children`: ReactNode
@@ -30,29 +45,40 @@ Small status label for categorizing or highlighting content.
30
45
 
31
46
  **Colors (kumo tokens used):**
32
47
 
33
- `bg-kumo-contrast`, `bg-kumo-danger`, `bg-kumo-fill`, `bg-kumo-success`, `border-kumo-brand`, `border-kumo-fill`, `text-kumo-default`, `text-kumo-inverse`, `text-kumo-link`
48
+ `bg-kumo-badge-blue`, `bg-kumo-badge-blue-subtle`, `bg-kumo-badge-green`, `bg-kumo-badge-green-subtle`, `bg-kumo-badge-inverted`, `bg-kumo-badge-neutral`, `bg-kumo-badge-orange`, `bg-kumo-badge-orange-subtle`, `bg-kumo-badge-red`, `bg-kumo-badge-red-subtle`, `bg-kumo-badge-teal`, `bg-kumo-badge-teal-subtle`, `bg-kumo-badge-yellow`, `bg-kumo-badge-yellow-subtle`, `bg-kumo-fill`, `border-kumo-brand`, `border-kumo-fill`, `text-kumo-badge-blue-subtle`, `text-kumo-badge-green-subtle`, `text-kumo-badge-inverted`, `text-kumo-badge-neutral-subtle`, `text-kumo-badge-orange-subtle`, `text-kumo-badge-red-subtle`, `text-kumo-badge-teal-subtle`, `text-kumo-badge-yellow-subtle`, `text-kumo-default`, `text-kumo-link`
34
49
 
35
50
  **Examples:**
36
51
 
37
52
  ```tsx
38
53
  <div className="flex flex-wrap items-center gap-2">
39
- <Badge variant="primary">Primary</Badge>
40
- <Badge variant="secondary">Secondary</Badge>
41
- <Badge variant="destructive">Destructive</Badge>
42
- <Badge variant="success">Success</Badge>
54
+ <Badge variant="red">Red</Badge>
55
+ <Badge variant="orange">Orange</Badge>
56
+ <Badge variant="yellow">Yellow</Badge>
57
+ <Badge variant="green">Green</Badge>
58
+ <Badge variant="teal">Teal</Badge>
59
+ <Badge variant="blue">Blue</Badge>
60
+ <Badge variant="neutral">Neutral</Badge>
61
+ <Badge variant="inverted">Inverted</Badge>
43
62
  <Badge variant="outline">Outline</Badge>
44
63
  <Badge variant="beta">Beta</Badge>
64
+ <Badge variant="red-subtle">Red subtle</Badge>
65
+ <Badge variant="orange-subtle">Orange subtle</Badge>
66
+ <Badge variant="yellow-subtle">Yellow subtle</Badge>
67
+ <Badge variant="green-subtle">Green subtle</Badge>
68
+ <Badge variant="teal-subtle">Teal subtle</Badge>
69
+ <Badge variant="blue-subtle">Blue subtle</Badge>
70
+ <Badge variant="neutral-subtle">Neutral subtle</Badge>
45
71
  </div>
46
72
  ```
47
73
 
48
74
  ```tsx
49
- <Badge variant="primary">Primary</Badge>
75
+ <Badge variant="red">Red</Badge>
50
76
  ```
51
77
 
52
78
  ```tsx
53
79
  <p className="flex items-center gap-2">
54
80
  Workers
55
- <Badge variant="beta">Beta</Badge>
81
+ <Badge variant="blue">New</Badge>
56
82
  </p>
57
83
  ```
58
84
 
@@ -77,6 +103,8 @@ Full-width message bar for informational, warning, or error notices. Supports st
77
103
  Primary heading text for the banner. Use for i18n string injection.
78
104
  - `description`: ReactNode
79
105
  Secondary description text displayed below the title. Use for i18n string injection.
106
+ - `action`: ReactNode
107
+ Action slot rendered at the trailing end of the banner (e.g. a CTA button or link). Only used in structured mode (with `title` or `description`).
80
108
  - `text`: string
81
109
  - `children`: ReactNode
82
110
  - `variant`: enum [default: default]
@@ -93,7 +121,7 @@ Full-width message bar for informational, warning, or error notices. Supports st
93
121
  **Examples:**
94
122
 
95
123
  ```tsx
96
- <div className="space-y-3">
124
+ <div className="w-full space-y-3">
97
125
  <Banner
98
126
  icon={<Info weight="fill" />}
99
127
  title="Update available"
@@ -150,6 +178,48 @@ Full-width message bar for informational, warning, or error notices. Supports st
150
178
  />
151
179
  ```
152
180
 
181
+ ```tsx
182
+ <div className="w-full space-y-3">
183
+ <Banner
184
+ icon={<Info weight="fill" />}
185
+ title="Update available"
186
+ description="A new version is ready to install."
187
+ action={<Button size="sm">Update now</Button>}
188
+ />
189
+ <Banner
190
+ icon={<Info weight="fill" />}
191
+ title="Update available"
192
+ description="A new version is ready to install."
193
+ action={
194
+ <Button
195
+ size="sm"
196
+ variant="ghost"
197
+ shape="square"
198
+ icon={X}
199
+ aria-label="Dismiss"
200
+ />
201
+ }
202
+ />
203
+ </div>
204
+ ```
205
+
206
+ ```tsx
207
+ <Banner
208
+ icon={<Warning weight="fill" />}
209
+ variant="alert"
210
+ title="Session expiring"
211
+ description="Your session will expire in 5 minutes."
212
+ action={
213
+ <>
214
+ <Button size="sm" variant="secondary">
215
+ Dismiss
216
+ </Button>
217
+ <Button size="sm">Extend session</Button>
218
+ </>
219
+ }
220
+ />
221
+ ```
222
+
153
223
  ```tsx
154
224
  <Banner icon={<Info />}>This is a simple banner using children.</Banner>
155
225
  ```
@@ -308,9 +378,9 @@ Primary action trigger. Supports multiple variants, sizes, shapes, icons, and lo
308
378
  Icon from `@phosphor-icons/react` or a React element. Rendered before children.
309
379
  - `loading`: boolean
310
380
  Shows a loading spinner and disables interaction.
381
+ - `title`: string
311
382
  - `id`: string
312
383
  - `lang`: string
313
- - `title`: string
314
384
  - `disabled`: boolean
315
385
  - `name`: string
316
386
  - `type`: enum
@@ -378,6 +448,21 @@ Primary action trigger. Supports multiple variants, sizes, shapes, icons, and lo
378
448
  </div>
379
449
  ```
380
450
 
451
+ ```tsx
452
+ <div className="flex flex-wrap items-center gap-3">
453
+ <Button variant="secondary" title="Create a new Worker">
454
+ Create Worker
455
+ </Button>
456
+ <Button
457
+ variant="secondary"
458
+ shape="square"
459
+ icon={PlusIcon}
460
+ aria-label="Add item"
461
+ title="Add item"
462
+ />
463
+ </div>
464
+ ```
465
+
381
466
 
382
467
  ---
383
468
 
@@ -424,7 +509,7 @@ Checkbox component
424
509
 
425
510
  **Colors (kumo tokens used):**
426
511
 
427
- `bg-kumo-base`, `bg-kumo-contrast`, `border-kumo-line`, `ring-kumo-contrast`, `ring-kumo-danger`, `ring-kumo-line`, `ring-kumo-ring`, `text-kumo-danger`, `text-kumo-default`, `text-kumo-inverse`, `text-kumo-subtle`
512
+ `bg-kumo-base`, `bg-kumo-contrast`, `ring-kumo-contrast`, `ring-kumo-danger`, `ring-kumo-line`, `ring-kumo-ring`, `text-kumo-danger`, `text-kumo-default`, `text-kumo-inverse`, `text-kumo-subtle`
428
513
 
429
514
  **Styling:**
430
515
 
@@ -547,6 +632,8 @@ Read-only text field with a one-click copy-to-clipboard button.
547
632
  - `"lg"`: Large clipboard text for prominent display
548
633
  - `text`: string (required)
549
634
  The text to display and copy to clipboard.
635
+ - `textToCopy`: string
636
+ If provided, this text will be copied to clipboard instead of the `text` prop.
550
637
  - `className`: string
551
638
  Additional CSS classes merged via `cn()`.
552
639
  - `tooltip`: object
@@ -610,6 +697,13 @@ Read-only text field with a one-click copy-to-clipboard button.
610
697
  <ClipboardText text="0c239dd2" />
611
698
  ```
612
699
 
700
+ ```tsx
701
+ <ClipboardText
702
+ text="sk_live_***********"
703
+ textToCopy="sk_live_51H8_abc123"
704
+ />
705
+ ```
706
+
613
707
  ```tsx
614
708
  <ClipboardText
615
709
  text="npx kumo add button"
@@ -1077,27 +1171,6 @@ Props:
1077
1171
  - `lang`: CodeLang
1078
1172
 
1079
1173
 
1080
- **Examples:**
1081
-
1082
- ```tsx
1083
- <CodeBlock
1084
- lang="tsx"
1085
- code={`const greeting = "Hello, World!";
1086
- console.log(greeting);`}
1087
- />
1088
- ```
1089
-
1090
- ```tsx
1091
- <Code
1092
- lang="bash"
1093
- code="export API_KEY={{apiKey}}"
1094
- values={{
1095
- apiKey: { value: "sk_live_123", highlight: true },
1096
- }}
1097
- />
1098
- ```
1099
-
1100
-
1101
1174
  ---
1102
1175
 
1103
1176
  ### Collapsible
@@ -1225,6 +1298,7 @@ Props:
1225
1298
  - `alignOffset`: ComboboxBase.Positioner.Props["alignOffset"]
1226
1299
  - `side`: ComboboxBase.Positioner.Props["side"]
1227
1300
  - `sideOffset`: ComboboxBase.Positioner.Props["sideOffset"]
1301
+ - `container`: PortalContainer
1228
1302
 
1229
1303
  #### Combobox.TriggerValue
1230
1304
 
@@ -1419,6 +1493,42 @@ Usage:
1419
1493
  </div>
1420
1494
  ```
1421
1495
 
1496
+ ```tsx
1497
+ <div className="flex flex-wrap gap-4 items-start">
1498
+ <Combobox value="Apple" items={fruits} disabled>
1499
+ <Combobox.TriggerInput
1500
+ className="w-[200px]"
1501
+ placeholder="Select fruit"
1502
+ />
1503
+ <Combobox.Content>
1504
+ <Combobox.Empty />
1505
+ <Combobox.List>
1506
+ {(item: string) => (
1507
+ <Combobox.Item key={item} value={item}>
1508
+ {item}
1509
+ </Combobox.Item>
1510
+ )}
1511
+ </Combobox.List>
1512
+ </Combobox.Content>
1513
+ </Combobox>
1514
+
1515
+ <Combobox value={languages[0]} items={languages} disabled>
1516
+ <Combobox.TriggerValue className="w-[200px]" />
1517
+ <Combobox.Content>
1518
+ <Combobox.Input placeholder="Search" />
1519
+ <Combobox.Empty />
1520
+ <Combobox.List>
1521
+ {(item: Language) => (
1522
+ <Combobox.Item key={item.value} value={item}>
1523
+ {item.emoji} {item.label}
1524
+ </Combobox.Item>
1525
+ )}
1526
+ </Combobox.List>
1527
+ </Combobox.Content>
1528
+ </Combobox>
1529
+ </div>
1530
+ ```
1531
+
1422
1532
  ```tsx
1423
1533
  <div className="w-80">
1424
1534
  <Combobox
@@ -1546,6 +1656,8 @@ CommandPalette — accessible command palette / spotlight search overlay. Compo
1546
1656
  Whether the dialog is open
1547
1657
  - `children`: ReactNode
1548
1658
  Child content - typically one or more Panel components
1659
+ - `container`: PortalContainer
1660
+ Container element for the portal. Use this to render the command palette inside a Shadow DOM or custom container. Overrides `KumoPortalProvider` context.
1549
1661
 
1550
1662
  **Colors (kumo tokens used):**
1551
1663
 
@@ -2027,6 +2139,8 @@ Dialog component
2027
2139
  Additional CSS classes merged via `cn()`.
2028
2140
  - `children`: ReactNode
2029
2141
  Dialog content (typically Title, Description, Close, and action buttons).
2142
+ - `container`: PortalContainer
2143
+ Container element for the portal. Use this to render the dialog inside a Shadow DOM or custom container. Overrides `KumoPortalProvider` context.
2030
2144
  - `size`: enum [default: base]
2031
2145
  - `"base"`: Default dialog width
2032
2146
  - `"sm"`: Small dialog for simple confirmations
@@ -2035,7 +2149,7 @@ Dialog component
2035
2149
 
2036
2150
  **Colors (kumo tokens used):**
2037
2151
 
2038
- `bg-kumo-base`, `text-kumo-default`
2152
+ `bg-kumo-base`, `bg-kumo-recessed`, `text-kumo-default`
2039
2153
 
2040
2154
  **Styling:**
2041
2155
 
@@ -3100,7 +3214,7 @@ LayerCard component
3100
3214
 
3101
3215
  **Colors (kumo tokens used):**
3102
3216
 
3103
- `bg-kumo-base`, `bg-kumo-elevated`, `bg-kumo-recessed`, `ring-kumo-fill`, `ring-kumo-line`, `text-kumo-strong`
3217
+ `bg-kumo-base`, `bg-kumo-elevated`, `ring-kumo-fill`, `ring-kumo-line`, `text-kumo-strong`
3104
3218
 
3105
3219
  **Styling:**
3106
3220
 
@@ -3316,6 +3430,10 @@ Animated circular spinner for indicating loading states.
3316
3430
  <Loader size={24} />
3317
3431
  ```
3318
3432
 
3433
+ ```tsx
3434
+ <Loader className="text-kumo-subtle" />
3435
+ ```
3436
+
3319
3437
 
3320
3438
  ---
3321
3439
 
@@ -3342,7 +3460,7 @@ MenuBar — horizontal icon-button toolbar with keyboard arrow-key navigation.
3342
3460
 
3343
3461
  **Colors (kumo tokens used):**
3344
3462
 
3345
- `bg-kumo-base`, `bg-kumo-fill`, `border-kumo-fill`
3463
+ `bg-kumo-base`, `bg-kumo-recessed`, `border-kumo-fill`, `border-kumo-recessed`
3346
3464
 
3347
3465
  **Styling:**
3348
3466
 
@@ -3351,20 +3469,20 @@ MenuBar — horizontal icon-button toolbar with keyboard arrow-key navigation.
3351
3469
 
3352
3470
  ```tsx
3353
3471
  <MenuBar
3354
- isActive="bold"
3472
+ isActive={active}
3355
3473
  optionIds
3356
3474
  options={[
3357
3475
  {
3358
3476
  icon: <TextBolderIcon />,
3359
3477
  id: "bold",
3360
3478
  tooltip: "Bold",
3361
- onClick: () => {},
3479
+ onClick: () => setActive(active === "bold" ? undefined : "bold"),
3362
3480
  },
3363
3481
  {
3364
3482
  icon: <TextItalicIcon />,
3365
3483
  id: "italic",
3366
3484
  tooltip: "Italic",
3367
- onClick: () => {},
3485
+ onClick: () => setActive(active === "italic" ? undefined : "italic"),
3368
3486
  },
3369
3487
  ]}
3370
3488
  />
@@ -3424,7 +3542,7 @@ Progress bar showing a measured value within a known range (e.g. quota usage).
3424
3542
  <Meter
3425
3543
  label="Upload progress"
3426
3544
  value={80}
3427
- indicatorClassName="from-green-500 via-green-500 to-green-500"
3545
+ indicatorClassName="from-kumo-success via-kumo-success to-kumo-success"
3428
3546
  />
3429
3547
  ```
3430
3548
 
@@ -3839,7 +3957,7 @@ Radio — radio button group for single-select choices. Compound component: `Ra
3839
3957
 
3840
3958
  **Colors (kumo tokens used):**
3841
3959
 
3842
- `bg-kumo-base`, `bg-kumo-contrast`, `bg-kumo-tint`, `border-kumo-danger`, `border-kumo-interact`, `border-kumo-line`, `border-kumo-ring`, `ring-kumo-danger`, `ring-kumo-line`, `ring-kumo-ring`, `text-kumo-danger`, `text-kumo-default`, `text-kumo-subtle`
3960
+ `bg-kumo-base`, `bg-kumo-contrast`, `bg-kumo-tint`, `border-kumo-danger`, `border-kumo-interact`, `border-kumo-ring`, `ring-kumo-danger`, `ring-kumo-line`, `ring-kumo-ring`, `text-kumo-danger`, `text-kumo-default`, `text-kumo-subtle`
3843
3961
 
3844
3962
  **Sub-Components:**
3845
3963
 
@@ -4268,7 +4386,7 @@ Option sub-component
4268
4386
  <span className="flex items-center gap-2">
4269
4387
  <span>Issue Types</span>
4270
4388
  {selected.length > 0 && (
4271
- <Badge variant="secondary">{selected.length}</Badge>
4389
+ <Badge variant="neutral">{selected.length}</Badge>
4272
4390
  )}
4273
4391
  </span>
4274
4392
  )}
@@ -4433,11 +4551,486 @@ Password/secret input that masks its value by default and reveals on click. Incl
4433
4551
  ```
4434
4552
 
4435
4553
 
4554
+ ---
4555
+
4556
+ ### Sidebar
4557
+
4558
+ Sidebar — responsive navigation panel with expand/collapse support. Compound component: `Sidebar` (root `<aside>`), `.Provider`, `.Header`, `.Content`, `.Footer`, `.Group`, `.GroupLabel`, `.GroupContent`, `.Menu`, `.MenuItem`, `.MenuButton`, `.MenuAction`, `.MenuBadge`, `.MenuSub`, `.MenuSubItem`, `.MenuSubButton`, `.Separator`, `.Input`, `.Trigger`, `.Rail`, `.MenuChevron`, `.Collapsible`, `.CollapsibleTrigger`, `.CollapsibleContent`. Built on `@base-ui/react/collapsible` + `@base-ui/react/dialog`.
4559
+
4560
+ **Type:** component
4561
+
4562
+ **Import:** `import { Sidebar } from "@cloudflare/kumo";`
4563
+
4564
+ **Category:** Other
4565
+
4566
+ **Props:**
4567
+
4568
+ - `defaultOpen`: boolean
4569
+ Initial open state when uncontrolled.
4570
+ - `open`: boolean
4571
+ Controlled open state.
4572
+ - `variant`: enum [default: sidebar]
4573
+ - `"sidebar"`: Standard sidebar with border separator
4574
+ - `"floating"`: Floating sidebar with shadow and rounded corners
4575
+ - `"inset"`: Inset sidebar within the content area
4576
+ - `side`: enum [default: left]
4577
+ - `"left"`: Left-aligned sidebar
4578
+ - `"right"`: Right-aligned sidebar
4579
+ - `collapsible`: enum [default: icon]
4580
+ - `"icon"`: Collapses to show icons only
4581
+ - `"offcanvas"`: Slides off screen when collapsed
4582
+ - `"none"`: Cannot be collapsed
4583
+ - `resizable`: boolean
4584
+ Enable drag-to-resize on the sidebar edge.
4585
+ - `defaultWidth`: number
4586
+ Initial width in pixels when resizable.
4587
+ - `minWidth`: number
4588
+ Minimum width in pixels when resizing.
4589
+ - `maxWidth`: number
4590
+ Maximum width in pixels when resizing.
4591
+ - `children`: ReactNode
4592
+ Content — typically `<Sidebar>` + main content.
4593
+ - `className`: string
4594
+ Additional CSS classes for the wrapper div.
4595
+
4596
+ **Colors (kumo tokens used):**
4597
+
4598
+ `bg-kumo-base`, `bg-kumo-brand`, `bg-kumo-line`, `bg-kumo-overlay`, `bg-kumo-recessed`, `bg-kumo-tint`, `border-kumo-line`, `ring-kumo-line`, `ring-kumo-ring`, `text-kumo-default`, `text-kumo-strong`, `text-kumo-subtle`
4599
+
4600
+ **Styling:**
4601
+
4602
+
4603
+ **Sub-Components:**
4604
+
4605
+ This is a compound component. Use these sub-components:
4606
+
4607
+ #### Sidebar.Provider
4608
+
4609
+ Provider sub-component
4610
+
4611
+ Props:
4612
+ - `defaultOpen`: boolean
4613
+ - `open`: boolean
4614
+ - `variant`: SidebarVariant
4615
+ - `side`: SidebarSide
4616
+ - `collapsible`: "icon" | "offcanvas" | "none"
4617
+ - `resizable`: boolean
4618
+ - `defaultWidth`: number
4619
+ - `minWidth`: number
4620
+ - `maxWidth`: number
4621
+ - `children`: ReactNode (required)
4622
+ - `className`: string
4623
+
4624
+ #### Sidebar.Header
4625
+
4626
+ Header sub-component
4627
+
4628
+ #### Sidebar.Content
4629
+
4630
+ Content sub-component
4631
+
4632
+ #### Sidebar.Footer
4633
+
4634
+ Footer sub-component
4635
+
4636
+ #### Sidebar.Group
4637
+
4638
+ Group sub-component
4639
+
4640
+ #### Sidebar.GroupLabel
4641
+
4642
+ GroupLabel sub-component
4643
+
4644
+ #### Sidebar.GroupContent
4645
+
4646
+ GroupContent sub-component
4647
+
4648
+ #### Sidebar.Menu
4649
+
4650
+ Menu sub-component
4651
+
4652
+ #### Sidebar.MenuItem
4653
+
4654
+ MenuItem sub-component
4655
+
4656
+ #### Sidebar.MenuButton
4657
+
4658
+ MenuButton sub-component
4659
+
4660
+ #### Sidebar.MenuAction
4661
+
4662
+ MenuAction sub-component
4663
+
4664
+ #### Sidebar.MenuBadge
4665
+
4666
+ MenuBadge sub-component
4667
+
4668
+ #### Sidebar.MenuSub
4669
+
4670
+ MenuSub sub-component
4671
+
4672
+ #### Sidebar.MenuSubItem
4673
+
4674
+ MenuSubItem sub-component
4675
+
4676
+ #### Sidebar.MenuSubButton
4677
+
4678
+ MenuSubButton sub-component
4679
+
4680
+ #### Sidebar.Separator
4681
+
4682
+ Separator sub-component
4683
+
4684
+ #### Sidebar.Input
4685
+
4686
+ Input sub-component
4687
+
4688
+ #### Sidebar.Trigger
4689
+
4690
+ Trigger sub-component
4691
+
4692
+ #### Sidebar.Rail
4693
+
4694
+ Rail sub-component
4695
+
4696
+ #### Sidebar.ResizeHandle
4697
+
4698
+ ResizeHandle sub-component
4699
+
4700
+ #### Sidebar.MenuChevron
4701
+
4702
+ MenuChevron sub-component
4703
+
4704
+ #### Sidebar.Collapsible
4705
+
4706
+ Collapsible sub-component
4707
+
4708
+ #### Sidebar.CollapsibleTrigger
4709
+
4710
+ CollapsibleTrigger sub-component
4711
+
4712
+ #### Sidebar.CollapsibleContent
4713
+
4714
+ CollapsibleContent sub-component
4715
+
4716
+
4717
+ **Examples:**
4718
+
4719
+ ```tsx
4720
+ <DemoContainer>
4721
+ <Sidebar.Provider defaultOpen className="min-h-0! h-full">
4722
+ <Sidebar>
4723
+ <Sidebar.Content>
4724
+ <Sidebar.Group>
4725
+ <Sidebar.GroupLabel>Overview</Sidebar.GroupLabel>
4726
+ <Sidebar.Menu>
4727
+ <Sidebar.MenuButton icon={HouseIcon} active>
4728
+ Home
4729
+ </Sidebar.MenuButton>
4730
+ <Sidebar.MenuButton icon={ChartBarIcon}>
4731
+ Analytics
4732
+ </Sidebar.MenuButton>
4733
+ <Sidebar.MenuButton icon={GlobeIcon}>
4734
+ Domains
4735
+ </Sidebar.MenuButton>
4736
+ </Sidebar.Menu>
4737
+ </Sidebar.Group>
4738
+
4739
+ <Sidebar.Group>
4740
+ <Sidebar.GroupLabel>Build</Sidebar.GroupLabel>
4741
+ <Sidebar.Menu>
4742
+ <Sidebar.MenuItem>
4743
+ <Sidebar.Collapsible defaultOpen>
4744
+ <Sidebar.CollapsibleTrigger
4745
+ render={
4746
+ <Sidebar.MenuButton icon={CodeIcon}>
4747
+ Compute
4748
+ <Sidebar.MenuChevron />
4749
+ </Sidebar.MenuButton>
4750
+ }
4751
+ />
4752
+ <Sidebar.CollapsibleContent>
4753
+ <Sidebar.MenuSub>
4754
+ <Sidebar.MenuSubButton>
4755
+ Workers & Pages
4756
+ </Sidebar.MenuSubButton>
4757
+ <Sidebar.MenuSubButton>
4758
+ Durable Objects
4759
+ </Sidebar.MenuSubButton>
4760
+ </Sidebar.MenuSub>
4761
+ </Sidebar.CollapsibleContent>
4762
+ </Sidebar.Collapsible>
4763
+ </Sidebar.MenuItem>
4764
+ <Sidebar.MenuButton icon={DatabaseIcon}>
4765
+ Storage
4766
+ </Sidebar.MenuButton>
4767
+ </Sidebar.Menu>
4768
+ </Sidebar.Group>
4769
+ </Sidebar.Content>
4770
+ </Sidebar>
4771
+ <DemoMain />
4772
+ </Sidebar.Provider>
4773
+ </DemoContainer>
4774
+ ```
4775
+
4776
+ ```tsx
4777
+ <DemoContainer>
4778
+ <Sidebar.Provider defaultOpen className="min-h-0! h-full">
4779
+ <Sidebar>
4780
+ <Sidebar.Content>
4781
+ {/* GroupContent is required for collapsible groups (provides grid-rows animation) */}
4782
+ <Sidebar.Group collapsible defaultOpen>
4783
+ <Sidebar.GroupLabel>Overview</Sidebar.GroupLabel>
4784
+ <Sidebar.GroupContent>
4785
+ <Sidebar.Menu>
4786
+ <Sidebar.MenuButton icon={HouseIcon} active>
4787
+ Home
4788
+ </Sidebar.MenuButton>
4789
+ <Sidebar.MenuButton icon={ChartBarIcon}>
4790
+ Analytics
4791
+ </Sidebar.MenuButton>
4792
+ <Sidebar.MenuButton icon={GlobeIcon}>
4793
+ Domains
4794
+ </Sidebar.MenuButton>
4795
+ </Sidebar.Menu>
4796
+ </Sidebar.GroupContent>
4797
+ </Sidebar.Group>
4798
+
4799
+ <Sidebar.Group collapsible defaultOpen>
4800
+ <Sidebar.GroupLabel>Build</Sidebar.GroupLabel>
4801
+ <Sidebar.GroupContent>
4802
+ <Sidebar.Menu>
4803
+ <Sidebar.MenuButton icon={CodeIcon}>
4804
+ Compute
4805
+ </Sidebar.MenuButton>
4806
+ <Sidebar.MenuButton icon={DatabaseIcon}>
4807
+ Storage
4808
+ </Sidebar.MenuButton>
4809
+ </Sidebar.Menu>
4810
+ </Sidebar.GroupContent>
4811
+ </Sidebar.Group>
4812
+
4813
+ <Sidebar.Group collapsible defaultOpen={false}>
4814
+ <Sidebar.GroupLabel>Protect & Connect</Sidebar.GroupLabel>
4815
+ <Sidebar.GroupContent>
4816
+ <Sidebar.Menu>
4817
+ <Sidebar.MenuButton icon={ShieldCheckIcon}>
4818
+ Security
4819
+ </Sidebar.MenuButton>
4820
+ <Sidebar.MenuButton icon={LockIcon}>
4821
+ Zero Trust
4822
+ </Sidebar.MenuButton>
4823
+ </Sidebar.Menu>
4824
+ </Sidebar.GroupContent>
4825
+ </Sidebar.Group>
4826
+ </Sidebar.Content>
4827
+ </Sidebar>
4828
+ <DemoMain />
4829
+ </Sidebar.Provider>
4830
+ </DemoContainer>
4831
+ ```
4832
+
4833
+ ```tsx
4834
+ <DemoContainer>
4835
+ <Sidebar.Provider defaultOpen className="min-h-0! h-full">
4836
+ <Sidebar>
4837
+ <Sidebar.Header>
4838
+ <BrandLogo />
4839
+ </Sidebar.Header>
4840
+ <Sidebar.Content>
4841
+ <Sidebar.Group>
4842
+ <Sidebar.Menu>
4843
+ <Sidebar.MenuButton icon={HouseIcon} tooltip="Home" active>
4844
+ Home
4845
+ </Sidebar.MenuButton>
4846
+ <Sidebar.MenuButton icon={ChartBarIcon} tooltip="Analytics">
4847
+ Analytics
4848
+ </Sidebar.MenuButton>
4849
+ <Sidebar.MenuButton icon={CodeIcon} tooltip="Compute">
4850
+ Compute
4851
+ </Sidebar.MenuButton>
4852
+ <Sidebar.MenuButton icon={DatabaseIcon} tooltip="Storage">
4853
+ Storage
4854
+ </Sidebar.MenuButton>
4855
+ </Sidebar.Menu>
4856
+ </Sidebar.Group>
4857
+ </Sidebar.Content>
4858
+ <Sidebar.Footer>
4859
+ <Sidebar.Trigger />
4860
+ </Sidebar.Footer>
4861
+ </Sidebar>
4862
+ <DemoMain>
4863
+ <ToggleButton />
4864
+ <p className="text-sm">
4865
+ Click the button or the sidebar trigger to toggle
4866
+ </p>
4867
+ </DemoMain>
4868
+ </Sidebar.Provider>
4869
+ </DemoContainer>
4870
+ ```
4871
+
4872
+ ```tsx
4873
+ <DemoContainer>
4874
+ <Sidebar.Provider defaultOpen className="min-h-0! h-full">
4875
+ <Sidebar>
4876
+ <Sidebar.Header>
4877
+ <AccountSwitcher />
4878
+ </Sidebar.Header>
4879
+
4880
+ <Sidebar.Content>
4881
+ <div className="px-1 pb-2">
4882
+ <Sidebar.Input placeholder="Quick search..." shortcut="⌘K" />
4883
+ </div>
4884
+
4885
+ <Sidebar.Group>
4886
+ <Sidebar.GroupLabel>Overview</Sidebar.GroupLabel>
4887
+ <Sidebar.Menu>
4888
+ <Sidebar.MenuButton icon={HouseIcon} active>
4889
+ Home
4890
+ </Sidebar.MenuButton>
4891
+ <Sidebar.MenuButton icon={ChartBarIcon}>
4892
+ Analytics & Logs
4893
+ </Sidebar.MenuButton>
4894
+ <Sidebar.MenuButton icon={GlobeIcon}>
4895
+ Domains
4896
+ </Sidebar.MenuButton>
4897
+ </Sidebar.Menu>
4898
+ </Sidebar.Group>
4899
+
4900
+ <Sidebar.Separator />
4901
+
4902
+ <Sidebar.Group>
4903
+ <Sidebar.GroupLabel>Build</Sidebar.GroupLabel>
4904
+ <Sidebar.Menu>
4905
+ <Sidebar.MenuItem>
4906
+ <Sidebar.Collapsible defaultOpen>
4907
+ <Sidebar.CollapsibleTrigger
4908
+ render={
4909
+ <Sidebar.MenuButton icon={CodeIcon}>
4910
+ Compute
4911
+ <Sidebar.MenuChevron />
4912
+ </Sidebar.MenuButton>
4913
+ }
4914
+ />
4915
+ <Sidebar.CollapsibleContent>
4916
+ <Sidebar.MenuSub>
4917
+ <Sidebar.MenuSubButton>
4918
+ Workers & Pages
4919
+ </Sidebar.MenuSubButton>
4920
+ <Sidebar.MenuSubButton>
4921
+ Durable Objects
4922
+ </Sidebar.MenuSubButton>
4923
+ <Sidebar.MenuSubButton>
4924
+ Containers
4925
+ <Sidebar.MenuBadge>Beta</Sidebar.MenuBadge>
4926
+ </Sidebar.MenuSubButton>
4927
+ </Sidebar.MenuSub>
4928
+ </Sidebar.CollapsibleContent>
4929
+ </Sidebar.Collapsible>
4930
+ </Sidebar.MenuItem>
4931
+ <Sidebar.MenuButton icon={DatabaseIcon}>
4932
+ Storage
4933
+ </Sidebar.MenuButton>
4934
+ </Sidebar.Menu>
4935
+ </Sidebar.Group>
4936
+
4937
+ <Sidebar.Group>
4938
+ <Sidebar.GroupLabel>Protect & Connect</Sidebar.GroupLabel>
4939
+ <Sidebar.Menu>
4940
+ <Sidebar.MenuButton icon={ShieldCheckIcon}>
4941
+ Security
4942
+ </Sidebar.MenuButton>
4943
+ <Sidebar.MenuButton icon={LockIcon}>
4944
+ Zero Trust
4945
+ <Sidebar.MenuBadge>Beta</Sidebar.MenuBadge>
4946
+ </Sidebar.MenuButton>
4947
+ </Sidebar.Menu>
4948
+ </Sidebar.Group>
4949
+ </Sidebar.Content>
4950
+
4951
+ <Sidebar.Footer>
4952
+ <Sidebar.MenuButton icon={GearIcon}>
4953
+ Manage account
4954
+ </Sidebar.MenuButton>
4955
+ </Sidebar.Footer>
4956
+ </Sidebar>
4957
+ <DemoMain />
4958
+ </Sidebar.Provider>
4959
+ </DemoContainer>
4960
+ ```
4961
+
4962
+ ```tsx
4963
+ <DemoContainer>
4964
+ <Sidebar.Provider
4965
+ defaultOpen
4966
+ resizable
4967
+ defaultWidth={240}
4968
+ minWidth={180}
4969
+ maxWidth={400}
4970
+ className="min-h-0! h-full"
4971
+ >
4972
+ <Sidebar>
4973
+ <Sidebar.Header>
4974
+ <BrandLogo />
4975
+ </Sidebar.Header>
4976
+ <Sidebar.Content>
4977
+ <Sidebar.Group>
4978
+ <Sidebar.GroupLabel>Overview</Sidebar.GroupLabel>
4979
+ <Sidebar.Menu>
4980
+ <Sidebar.MenuButton icon={HouseIcon} active>
4981
+ Home
4982
+ </Sidebar.MenuButton>
4983
+ <Sidebar.MenuButton icon={ChartBarIcon}>
4984
+ Analytics
4985
+ </Sidebar.MenuButton>
4986
+ <Sidebar.MenuButton icon={DatabaseIcon}>
4987
+ Storage
4988
+ </Sidebar.MenuButton>
4989
+ </Sidebar.Menu>
4990
+ </Sidebar.Group>
4991
+ </Sidebar.Content>
4992
+ <Sidebar.Footer>
4993
+ <Sidebar.Trigger />
4994
+ </Sidebar.Footer>
4995
+ <Sidebar.ResizeHandle />
4996
+ </Sidebar>
4997
+ <DemoMain>
4998
+ <p className="text-sm">Drag the sidebar edge to resize</p>
4999
+ </DemoMain>
5000
+ </Sidebar.Provider>
5001
+ </DemoContainer>
5002
+ ```
5003
+
5004
+ ```tsx
5005
+ <DemoContainer>
5006
+ <Sidebar.Provider defaultOpen side="right" className="min-h-0! h-full">
5007
+ <DemoMain />
5008
+ <Sidebar>
5009
+ <Sidebar.Content>
5010
+ <Sidebar.Group>
5011
+ <Sidebar.GroupLabel>Details</Sidebar.GroupLabel>
5012
+ <Sidebar.Menu>
5013
+ <Sidebar.MenuButton icon={GearIcon} active>
5014
+ Properties
5015
+ </Sidebar.MenuButton>
5016
+ <Sidebar.MenuButton icon={ChartBarIcon}>
5017
+ Metrics
5018
+ </Sidebar.MenuButton>
5019
+ <Sidebar.MenuButton icon={BellIcon}>Alerts</Sidebar.MenuButton>
5020
+ </Sidebar.Menu>
5021
+ </Sidebar.Group>
5022
+ </Sidebar.Content>
5023
+ </Sidebar>
5024
+ </Sidebar.Provider>
5025
+ </DemoContainer>
5026
+ ```
5027
+
5028
+
4436
5029
  ---
4437
5030
 
4438
5031
  ### Surface
4439
5032
 
4440
- Surface component
5033
+ Polymorphic container with consistent background, shadow, and border styling. Use the `render` prop to change the underlying element: ```tsx <Surface render={<section />} className="rounded-lg p-4">Card content</Surface> ```
4441
5034
 
4442
5035
  **Type:** component
4443
5036
 
@@ -4448,11 +5041,15 @@ Surface component
4448
5041
  **Props:**
4449
5042
 
4450
5043
  - `as`: React.ElementType
4451
- The HTML element type to render as (e.g. `"div"`, `"section"`, `"article"`).
4452
- - `className`: string
4453
- Additional CSS classes merged via `cn()`.
5044
+ - `render`: ReactNode
5045
+ Allows you to replace the component’s HTML element with a different tag, or compose it with another component.
5046
+
5047
+ Accepts a `ReactElement` or a function that returns the element to render.
4454
5048
  - `children`: ReactNode
4455
- Content rendered inside the surface.
5049
+ - `className`: string
5050
+ - `id`: string
5051
+ - `lang`: string
5052
+ - `title`: string
4456
5053
 
4457
5054
  **Colors (kumo tokens used):**
4458
5055
 
@@ -4475,13 +5072,13 @@ Surface component
4475
5072
 
4476
5073
  ```tsx
4477
5074
  <div className="flex flex-col gap-4">
4478
- <Surface as="section" className="rounded-lg p-4">
5075
+ <Surface render={<section />} className="rounded-lg p-4">
4479
5076
  <Text bold>As section element</Text>
4480
5077
  </Surface>
4481
- <Surface as="article" className="rounded-lg p-4">
5078
+ <Surface render={<article />} className="rounded-lg p-4">
4482
5079
  <Text bold>As article element</Text>
4483
5080
  </Surface>
4484
- <Surface as="aside" className="rounded-lg p-4">
5081
+ <Surface render={<aside />} className="rounded-lg p-4">
4485
5082
  <Text bold>As aside element</Text>
4486
5083
  </Surface>
4487
5084
  </div>
@@ -4608,14 +5205,25 @@ Props:
4608
5205
  ```
4609
5206
 
4610
5207
  ```tsx
4611
- <div className="flex flex-col gap-4">
5208
+ <div className="grid grid-cols-2 gap-x-8 gap-y-4">
4612
5209
  <Switch
4613
- label="Default variant"
5210
+ label="Default off"
5211
+ checked={false}
5212
+ onCheckedChange={() => {}}
5213
+ />
5214
+ <Switch
5215
+ label="Default on"
4614
5216
  checked={true}
4615
5217
  onCheckedChange={() => {}}
4616
5218
  />
4617
5219
  <Switch
4618
- label="Neutral variant"
5220
+ label="Neutral off"
5221
+ variant="neutral"
5222
+ checked={false}
5223
+ onCheckedChange={() => {}}
5224
+ />
5225
+ <Switch
5226
+ label="Neutral on"
4619
5227
  variant="neutral"
4620
5228
  checked={true}
4621
5229
  onCheckedChange={() => {}}
@@ -4623,6 +5231,29 @@ Props:
4623
5231
  </div>
4624
5232
  ```
4625
5233
 
5234
+ ```tsx
5235
+ <div className="flex flex-col gap-4">
5236
+ <Switch
5237
+ label="Small"
5238
+ size="sm"
5239
+ checked={true}
5240
+ onCheckedChange={() => {}}
5241
+ />
5242
+ <Switch
5243
+ label="Base (default)"
5244
+ size="base"
5245
+ checked={true}
5246
+ onCheckedChange={() => {}}
5247
+ />
5248
+ <Switch
5249
+ label="Large"
5250
+ size="lg"
5251
+ checked={true}
5252
+ onCheckedChange={() => {}}
5253
+ />
5254
+ </div>
5255
+ ```
5256
+
4626
5257
 
4627
5258
  ---
4628
5259
 
@@ -4644,6 +5275,9 @@ Table — semantic HTML table with styled rows, cells, and selection support. C
4644
5275
  - `variant`: enum [default: default]
4645
5276
  - `"default"`: Default row variant
4646
5277
  - `"selected"`: Selected row variant
5278
+ - `sticky`: enum
5279
+ - `"left"`: Pin column to the left edge of the scroll container
5280
+ - `"right"`: Pin column to the right edge of the scroll container
4647
5281
  - `className`: string
4648
5282
  Additional CSS classes
4649
5283
  - `children`: ReactNode
@@ -4855,6 +5489,78 @@ ResizeHandle sub-component
4855
5489
  </LayerCard>
4856
5490
  ```
4857
5491
 
5492
+ ```tsx
5493
+ <LayerCard>
5494
+ <LayerCard.Primary className="w-full max-w-md overflow-x-auto p-0">
5495
+ <Table>
5496
+ <Table.Header>
5497
+ <Table.Row>
5498
+ <Table.Head>Subject</Table.Head>
5499
+ <Table.Head>From</Table.Head>
5500
+ <Table.Head>Date</Table.Head>
5501
+ <Table.Head>Tags</Table.Head>
5502
+ <Table.Head sticky="right">
5503
+ <span className="sr-only">Actions</span>
5504
+ </Table.Head>
5505
+ </Table.Row>
5506
+ </Table.Header>
5507
+ <Table.Body>
5508
+ {emailData.map((row) => (
5509
+ <Table.Row key={row.id}>
5510
+ <Table.Cell className="whitespace-nowrap">
5511
+ {row.subject}
5512
+ </Table.Cell>
5513
+ <Table.Cell className="whitespace-nowrap">
5514
+ {row.from}
5515
+ </Table.Cell>
5516
+ <Table.Cell className="whitespace-nowrap">
5517
+ {row.date}
5518
+ </Table.Cell>
5519
+ <Table.Cell className="whitespace-nowrap">
5520
+ {row.tags ? (
5521
+ <div className="inline-flex gap-1">
5522
+ {row.tags.map((tag) => (
5523
+ <Badge key={tag}>{tag}</Badge>
5524
+ ))}
5525
+ </div>
5526
+ ) : (
5527
+ "—"
5528
+ )}
5529
+ </Table.Cell>
5530
+ <Table.Cell sticky="right" className="text-right">
5531
+ <DropdownMenu>
5532
+ <DropdownMenu.Trigger
5533
+ render={
5534
+ <Button
5535
+ variant="ghost"
5536
+ size="sm"
5537
+ shape="square"
5538
+ aria-label="More options"
5539
+ >
5540
+ <DotsThree weight="bold" size={16} />
5541
+ </Button>
5542
+ }
5543
+ />
5544
+ <DropdownMenu.Content>
5545
+ <DropdownMenu.Item icon={Eye}>View</DropdownMenu.Item>
5546
+ <DropdownMenu.Item icon={PencilSimple}>
5547
+ Edit
5548
+ </DropdownMenu.Item>
5549
+ <DropdownMenu.Separator />
5550
+ <DropdownMenu.Item icon={Trash} variant="danger">
5551
+ Delete
5552
+ </DropdownMenu.Item>
5553
+ </DropdownMenu.Content>
5554
+ </DropdownMenu>
5555
+ </Table.Cell>
5556
+ </Table.Row>
5557
+ ))}
5558
+ </Table.Body>
5559
+ </Table>
5560
+ </LayerCard.Primary>
5561
+ </LayerCard>
5562
+ ```
5563
+
4858
5564
  ```tsx
4859
5565
  <LayerCard>
4860
5566
  <LayerCard.Primary className="w-full overflow-x-auto p-0">
@@ -4985,7 +5691,7 @@ Tab navigation component with segmented or underline style. Built on Base UI Tab
4985
5691
 
4986
5692
  **Colors (kumo tokens used):**
4987
5693
 
4988
- `bg-kumo-base`, `bg-kumo-brand`, `bg-kumo-recessed`, `bg-kumo-surface`, `bg-kumo-tint`, `border-kumo-ring`, `ring-kumo-ring`, `text-kumo-default`, `text-kumo-strong`, `text-kumo-subtle`
5694
+ `bg-kumo-base`, `bg-kumo-brand`, `bg-kumo-recessed`, `bg-kumo-tint`, `border-kumo-ring`, `ring-kumo-line`, `ring-kumo-ring`, `text-kumo-default`, `text-kumo-strong`, `text-kumo-subtle`
4989
5695
 
4990
5696
  **Styling:**
4991
5697
 
@@ -5120,6 +5826,8 @@ Text component
5120
5826
  - `"lg"`: Large text
5121
5827
  - `bold`: boolean
5122
5828
  Whether to use bold font weight (only applies to body variants).
5829
+ - `truncate`: boolean
5830
+ Whether to truncate overflowing text with an ellipsis. Adds `truncate min-w-0` classes.
5123
5831
  - `as`: React.ElementType
5124
5832
  The HTML element type to render as (e.g. `"span"`, `"p"`, `"h1"`). Auto-selected based on variant if omitted.
5125
5833
  - `children`: ReactNode
@@ -5197,6 +5905,15 @@ Text component
5197
5905
  </div>
5198
5906
  ```
5199
5907
 
5908
+ ```tsx
5909
+ <div className="w-64 rounded-lg border border-kumo-line bg-kumo-base p-4">
5910
+ <Text truncate>
5911
+ This is a long piece of text that will be truncated with an ellipsis
5912
+ when it overflows its container.
5913
+ </Text>
5914
+ </div>
5915
+ ```
5916
+
5200
5917
 
5201
5918
  ---
5202
5919
 
@@ -5225,7 +5942,7 @@ Toasty — toast notification provider and viewport. Renders a `Toast.Provider`
5225
5942
 
5226
5943
  **Colors (kumo tokens used):**
5227
5944
 
5228
- `bg-kumo-contrast`, `bg-kumo-control`, `bg-kumo-danger-tint`, `bg-kumo-fill-hover`, `bg-kumo-info-tint`, `bg-kumo-success-tint`, `bg-kumo-warning-tint`, `border-kumo-danger`, `border-kumo-fill`, `border-kumo-info`, `border-kumo-success`, `border-kumo-warning`, `text-kumo-danger`, `text-kumo-default`, `text-kumo-info`, `text-kumo-strong`, `text-kumo-subtle`, `text-kumo-success`, `text-kumo-warning`
5945
+ `bg-kumo-base`, `bg-kumo-contrast`, `bg-kumo-control`, `bg-kumo-danger-tint`, `bg-kumo-fill-hover`, `bg-kumo-info-tint`, `bg-kumo-success-tint`, `bg-kumo-warning-tint`, `border-kumo-fill`, `ring-kumo-danger`, `ring-kumo-info`, `ring-kumo-ring`, `ring-kumo-success`, `ring-kumo-warning`, `text-kumo-danger`, `text-kumo-default`, `text-kumo-info`, `text-kumo-strong`, `text-kumo-subtle`, `text-kumo-success`, `text-kumo-warning`
5229
5946
 
5230
5947
  **Styling:**
5231
5948
 
@@ -5330,7 +6047,7 @@ Multi-line textarea input with Input variants and InputArea-specific dimensions
5330
6047
  - **Feedback:** Banner, Loader, Toasty
5331
6048
  - **Action:** Button, ClipboardText
5332
6049
  - **Input:** Checkbox, Combobox, DateRangePicker, Field, Input, Radio, Select, Switch
5333
- - **Other:** CloudflareLogo, DatePicker, Label, Link, SensitiveInput, Table, DeleteResource
6050
+ - **Other:** CloudflareLogo, DatePicker, Label, Link, SensitiveInput, Sidebar, Table, DeleteResource
5334
6051
  - **Navigation:** CommandPalette, MenuBar, Pagination, Tabs
5335
6052
  - **Overlay:** Dialog, DropdownMenu, Popover, Tooltip
5336
6053
  - **Layout:** Grid, Surface, PageHeader, ResourceListPage