@cloudflare/kumo 1.0.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.
- package/CHANGELOG.md +510 -0
- package/LICENSE +21 -0
- package/README.md +521 -0
- package/ai/component-registry.json +3754 -0
- package/ai/component-registry.md +4022 -0
- package/ai/schemas.ts +594 -0
- package/dist/badge-Dc99vsfo.js +51 -0
- package/dist/badge-Dc99vsfo.js.map +1 -0
- package/dist/banner-4fkH6Sbt.js +51 -0
- package/dist/banner-4fkH6Sbt.js.map +1 -0
- package/dist/breadcrumbs-B5SY2CWj.js +132 -0
- package/dist/breadcrumbs-B5SY2CWj.js.map +1 -0
- package/dist/button-E2-hZMZE.js +191 -0
- package/dist/button-E2-hZMZE.js.map +1 -0
- package/dist/catalog.js +229 -0
- package/dist/catalog.js.map +1 -0
- package/dist/checkbox-BexIU_lZ.js +224 -0
- package/dist/checkbox-BexIU_lZ.js.map +1 -0
- package/dist/clipboard-text-BFHWMjmr.js +108 -0
- package/dist/clipboard-text-BFHWMjmr.js.map +1 -0
- package/dist/cn-Bhsu1vx2.js +26 -0
- package/dist/cn-Bhsu1vx2.js.map +1 -0
- package/dist/code-T2wPDiM0.js +60 -0
- package/dist/code-T2wPDiM0.js.map +1 -0
- package/dist/collapsible-OBNkTO48.js +56 -0
- package/dist/collapsible-OBNkTO48.js.map +1 -0
- package/dist/combobox-Dld0kS0U.js +228 -0
- package/dist/combobox-Dld0kS0U.js.map +1 -0
- package/dist/command-line/cli.js +764 -0
- package/dist/command-line/commands/add.js +220 -0
- package/dist/command-line/commands/blocks.js +61 -0
- package/dist/command-line/commands/doc.js +167 -0
- package/dist/command-line/commands/init.js +95 -0
- package/dist/command-line/commands/ls.js +53 -0
- package/dist/command-palette-BgQ680BG.js +393 -0
- package/dist/command-palette-BgQ680BG.js.map +1 -0
- package/dist/components/badge.js +7 -0
- package/dist/components/badge.js.map +1 -0
- package/dist/components/banner.js +7 -0
- package/dist/components/banner.js.map +1 -0
- package/dist/components/breadcrumbs.js +9 -0
- package/dist/components/breadcrumbs.js.map +1 -0
- package/dist/components/button.js +9 -0
- package/dist/components/button.js.map +1 -0
- package/dist/components/checkbox.js +8 -0
- package/dist/components/checkbox.js.map +1 -0
- package/dist/components/clipboard-text.js +6 -0
- package/dist/components/clipboard-text.js.map +1 -0
- package/dist/components/code.js +7 -0
- package/dist/components/code.js.map +1 -0
- package/dist/components/collapsible.js +6 -0
- package/dist/components/collapsible.js.map +1 -0
- package/dist/components/combobox.js +6 -0
- package/dist/components/combobox.js.map +1 -0
- package/dist/components/command-palette.js +8 -0
- package/dist/components/command-palette.js.map +1 -0
- package/dist/components/date-range-picker.js +6 -0
- package/dist/components/date-range-picker.js.map +1 -0
- package/dist/components/dialog.js +11 -0
- package/dist/components/dialog.js.map +1 -0
- package/dist/components/dropdown.js +6 -0
- package/dist/components/dropdown.js.map +1 -0
- package/dist/components/empty.js +9 -0
- package/dist/components/empty.js.map +1 -0
- package/dist/components/field.js +9 -0
- package/dist/components/field.js.map +1 -0
- package/dist/components/grid.js +11 -0
- package/dist/components/grid.js.map +1 -0
- package/dist/components/input.js +11 -0
- package/dist/components/input.js.map +1 -0
- package/dist/components/label.js +10 -0
- package/dist/components/label.js.map +1 -0
- package/dist/components/layer-card.js +6 -0
- package/dist/components/layer-card.js.map +1 -0
- package/dist/components/link.js +9 -0
- package/dist/components/link.js.map +1 -0
- package/dist/components/loader.js +8 -0
- package/dist/components/loader.js.map +1 -0
- package/dist/components/menubar.js +7 -0
- package/dist/components/menubar.js.map +1 -0
- package/dist/components/meter.js +6 -0
- package/dist/components/meter.js.map +1 -0
- package/dist/components/pagination.js +6 -0
- package/dist/components/pagination.js.map +1 -0
- package/dist/components/popover.js +14 -0
- package/dist/components/popover.js.map +1 -0
- package/dist/components/radio.js +10 -0
- package/dist/components/radio.js.map +1 -0
- package/dist/components/select.js +6 -0
- package/dist/components/select.js.map +1 -0
- package/dist/components/sensitive-input.js +8 -0
- package/dist/components/sensitive-input.js.map +1 -0
- package/dist/components/surface.js +6 -0
- package/dist/components/surface.js.map +1 -0
- package/dist/components/switch.js +8 -0
- package/dist/components/switch.js.map +1 -0
- package/dist/components/table.js +8 -0
- package/dist/components/table.js.map +1 -0
- package/dist/components/tabs.js +6 -0
- package/dist/components/tabs.js.map +1 -0
- package/dist/components/text.js +6 -0
- package/dist/components/text.js.map +1 -0
- package/dist/components/toast.js +8 -0
- package/dist/components/toast.js.map +1 -0
- package/dist/components/tooltip.js +7 -0
- package/dist/components/tooltip.js.map +1 -0
- package/dist/date-range-picker-CbKEQ9pi.js +408 -0
- package/dist/date-range-picker-CbKEQ9pi.js.map +1 -0
- package/dist/dialog-B1TaN0oR.js +77 -0
- package/dist/dialog-B1TaN0oR.js.map +1 -0
- package/dist/dropdown-D0rhYKeG.js +263 -0
- package/dist/dropdown-D0rhYKeG.js.map +1 -0
- package/dist/empty-DzCqjea-.js +93 -0
- package/dist/empty-DzCqjea-.js.map +1 -0
- package/dist/field-V3J0Ql_V.js +71 -0
- package/dist/field-V3J0Ql_V.js.map +1 -0
- package/dist/grid-DKajRHh8.js +127 -0
- package/dist/grid-DKajRHh8.js.map +1 -0
- package/dist/index.js +125 -0
- package/dist/index.js.map +1 -0
- package/dist/input-Dqvc2AB_.js +109 -0
- package/dist/input-Dqvc2AB_.js.map +1 -0
- package/dist/input-area-B9qajxvZ.js +57 -0
- package/dist/input-area-B9qajxvZ.js.map +1 -0
- package/dist/input-group-Bl6tgD5-.js +111 -0
- package/dist/input-group-Bl6tgD5-.js.map +1 -0
- package/dist/label-87HQArUG.js +50 -0
- package/dist/label-87HQArUG.js.map +1 -0
- package/dist/layer-card-C8j5Hkkj.js +44 -0
- package/dist/layer-card-C8j5Hkkj.js.map +1 -0
- package/dist/link-6TIZ4JIw.js +73 -0
- package/dist/link-6TIZ4JIw.js.map +1 -0
- package/dist/link-provider-DPBGo-0n.js +22 -0
- package/dist/link-provider-DPBGo-0n.js.map +1 -0
- package/dist/loader-DHGMYlC6.js +105 -0
- package/dist/loader-DHGMYlC6.js.map +1 -0
- package/dist/menubar-DLwLRFB1.js +92 -0
- package/dist/menubar-DLwLRFB1.js.map +1 -0
- package/dist/meter-DKUuvXxS.js +51 -0
- package/dist/meter-DKUuvXxS.js.map +1 -0
- package/dist/pagination-C4HQqodz.js +99 -0
- package/dist/pagination-C4HQqodz.js.map +1 -0
- package/dist/popover-DhdIqrP7.js +178 -0
- package/dist/popover-DhdIqrP7.js.map +1 -0
- package/dist/primitives/accordion.js +6 -0
- package/dist/primitives/accordion.js.map +1 -0
- package/dist/primitives/alert-dialog.js +6 -0
- package/dist/primitives/alert-dialog.js.map +1 -0
- package/dist/primitives/autocomplete.js +6 -0
- package/dist/primitives/autocomplete.js.map +1 -0
- package/dist/primitives/avatar.js +6 -0
- package/dist/primitives/avatar.js.map +1 -0
- package/dist/primitives/button.js +6 -0
- package/dist/primitives/button.js.map +1 -0
- package/dist/primitives/checkbox-group.js +6 -0
- package/dist/primitives/checkbox-group.js.map +1 -0
- package/dist/primitives/checkbox.js +6 -0
- package/dist/primitives/checkbox.js.map +1 -0
- package/dist/primitives/collapsible.js +6 -0
- package/dist/primitives/collapsible.js.map +1 -0
- package/dist/primitives/combobox.js +6 -0
- package/dist/primitives/combobox.js.map +1 -0
- package/dist/primitives/context-menu.js +6 -0
- package/dist/primitives/context-menu.js.map +1 -0
- package/dist/primitives/dialog.js +6 -0
- package/dist/primitives/dialog.js.map +1 -0
- package/dist/primitives/direction-provider.js +7 -0
- package/dist/primitives/direction-provider.js.map +1 -0
- package/dist/primitives/field.js +6 -0
- package/dist/primitives/field.js.map +1 -0
- package/dist/primitives/fieldset.js +6 -0
- package/dist/primitives/fieldset.js.map +1 -0
- package/dist/primitives/form.js +6 -0
- package/dist/primitives/form.js.map +1 -0
- package/dist/primitives/input.js +6 -0
- package/dist/primitives/input.js.map +1 -0
- package/dist/primitives/menu.js +6 -0
- package/dist/primitives/menu.js.map +1 -0
- package/dist/primitives/menubar.js +6 -0
- package/dist/primitives/menubar.js.map +1 -0
- package/dist/primitives/meter.js +6 -0
- package/dist/primitives/meter.js.map +1 -0
- package/dist/primitives/navigation-menu.js +6 -0
- package/dist/primitives/navigation-menu.js.map +1 -0
- package/dist/primitives/number-field.js +6 -0
- package/dist/primitives/number-field.js.map +1 -0
- package/dist/primitives/popover.js +6 -0
- package/dist/primitives/popover.js.map +1 -0
- package/dist/primitives/preview-card.js +6 -0
- package/dist/primitives/preview-card.js.map +1 -0
- package/dist/primitives/progress.js +6 -0
- package/dist/primitives/progress.js.map +1 -0
- package/dist/primitives/radio-group.js +6 -0
- package/dist/primitives/radio-group.js.map +1 -0
- package/dist/primitives/radio.js +6 -0
- package/dist/primitives/radio.js.map +1 -0
- package/dist/primitives/scroll-area.js +6 -0
- package/dist/primitives/scroll-area.js.map +1 -0
- package/dist/primitives/select.js +6 -0
- package/dist/primitives/select.js.map +1 -0
- package/dist/primitives/separator.js +6 -0
- package/dist/primitives/separator.js.map +1 -0
- package/dist/primitives/slider.js +6 -0
- package/dist/primitives/slider.js.map +1 -0
- package/dist/primitives/switch.js +6 -0
- package/dist/primitives/switch.js.map +1 -0
- package/dist/primitives/tabs.js +6 -0
- package/dist/primitives/tabs.js.map +1 -0
- package/dist/primitives/toast.js +6 -0
- package/dist/primitives/toast.js.map +1 -0
- package/dist/primitives/toggle-group.js +6 -0
- package/dist/primitives/toggle-group.js.map +1 -0
- package/dist/primitives/toggle.js +6 -0
- package/dist/primitives/toggle.js.map +1 -0
- package/dist/primitives/toolbar.js +6 -0
- package/dist/primitives/toolbar.js.map +1 -0
- package/dist/primitives/tooltip.js +6 -0
- package/dist/primitives/tooltip.js.map +1 -0
- package/dist/primitives.js +43 -0
- package/dist/primitives.js.map +1 -0
- package/dist/radio-BVAG7hNp.js +125 -0
- package/dist/radio-BVAG7hNp.js.map +1 -0
- package/dist/registry.js +2 -0
- package/dist/registry.js.map +1 -0
- package/dist/schemas-BSdA0fz-.js +3210 -0
- package/dist/schemas-BSdA0fz-.js.map +1 -0
- package/dist/select-B5Vb3zou.js +122 -0
- package/dist/select-B5Vb3zou.js.map +1 -0
- package/dist/sensitive-input-D5HCV04N.js +258 -0
- package/dist/sensitive-input-D5HCV04N.js.map +1 -0
- package/dist/skeleton-line-CtpS1u1J.js +28 -0
- package/dist/skeleton-line-CtpS1u1J.js.map +1 -0
- package/dist/src/blocks/page-header/index.d.ts +2 -0
- package/dist/src/blocks/page-header/index.d.ts.map +1 -0
- package/dist/src/blocks/page-header/page-header.d.ts +38 -0
- package/dist/src/blocks/page-header/page-header.d.ts.map +1 -0
- package/dist/src/blocks/resource-list/index.d.ts +2 -0
- package/dist/src/blocks/resource-list/index.d.ts.map +1 -0
- package/dist/src/blocks/resource-list/resource-list.d.ts +18 -0
- package/dist/src/blocks/resource-list/resource-list.d.ts.map +1 -0
- package/dist/src/catalog/catalog.d.ts +75 -0
- package/dist/src/catalog/catalog.d.ts.map +1 -0
- package/dist/src/catalog/data.d.ts +44 -0
- package/dist/src/catalog/data.d.ts.map +1 -0
- package/dist/src/catalog/index.d.ts +39 -0
- package/dist/src/catalog/index.d.ts.map +1 -0
- package/dist/src/catalog/types.d.ts +226 -0
- package/dist/src/catalog/types.d.ts.map +1 -0
- package/dist/src/catalog/visibility.d.ts +37 -0
- package/dist/src/catalog/visibility.d.ts.map +1 -0
- package/dist/src/command-line/build-cli.d.ts +7 -0
- package/dist/src/command-line/build-cli.d.ts.map +1 -0
- package/dist/src/command-line/cli.d.ts +13 -0
- package/dist/src/command-line/cli.d.ts.map +1 -0
- package/dist/src/command-line/commands/add.d.ts +10 -0
- package/dist/src/command-line/commands/add.d.ts.map +1 -0
- package/dist/src/command-line/commands/blocks.d.ts +10 -0
- package/dist/src/command-line/commands/blocks.d.ts.map +1 -0
- package/dist/src/command-line/commands/doc.d.ts +14 -0
- package/dist/src/command-line/commands/doc.d.ts.map +1 -0
- package/dist/src/command-line/commands/init.d.ts +18 -0
- package/dist/src/command-line/commands/init.d.ts.map +1 -0
- package/dist/src/command-line/commands/ls.d.ts +10 -0
- package/dist/src/command-line/commands/ls.d.ts.map +1 -0
- package/dist/src/command-line/commands/migrate.d.ts +10 -0
- package/dist/src/command-line/commands/migrate.d.ts.map +1 -0
- package/dist/src/command-line/utils/config.d.ts +42 -0
- package/dist/src/command-line/utils/config.d.ts.map +1 -0
- package/dist/src/command-line/utils/transformer.d.ts +17 -0
- package/dist/src/command-line/utils/transformer.d.ts.map +1 -0
- package/dist/src/components/badge/badge.d.ts +46 -0
- package/dist/src/components/badge/badge.d.ts.map +1 -0
- package/dist/src/components/badge/index.d.ts +2 -0
- package/dist/src/components/badge/index.d.ts.map +1 -0
- package/dist/src/components/banner/banner.d.ts +45 -0
- package/dist/src/components/banner/banner.d.ts.map +1 -0
- package/dist/src/components/banner/index.d.ts +2 -0
- package/dist/src/components/banner/index.d.ts.map +1 -0
- package/dist/src/components/breadcrumbs/breadcrumbs.d.ts +43 -0
- package/dist/src/components/breadcrumbs/breadcrumbs.d.ts.map +1 -0
- package/dist/src/components/breadcrumbs/index.d.ts +2 -0
- package/dist/src/components/breadcrumbs/index.d.ts.map +1 -0
- package/dist/src/components/button/button.d.ts +118 -0
- package/dist/src/components/button/button.d.ts.map +1 -0
- package/dist/src/components/button/index.d.ts +2 -0
- package/dist/src/components/button/index.d.ts.map +1 -0
- package/dist/src/components/checkbox/checkbox.d.ts +167 -0
- package/dist/src/components/checkbox/checkbox.d.ts.map +1 -0
- package/dist/src/components/checkbox/index.d.ts +2 -0
- package/dist/src/components/checkbox/index.d.ts.map +1 -0
- package/dist/src/components/clipboard-text/clipboard-text.d.ts +38 -0
- package/dist/src/components/clipboard-text/clipboard-text.d.ts.map +1 -0
- package/dist/src/components/clipboard-text/index.d.ts +2 -0
- package/dist/src/components/clipboard-text/index.d.ts.map +1 -0
- package/dist/src/components/code/code.d.ts +138 -0
- package/dist/src/components/code/code.d.ts.map +1 -0
- package/dist/src/components/code/index.d.ts +4 -0
- package/dist/src/components/code/index.d.ts.map +1 -0
- package/dist/src/components/collapsible/collapsible.d.ts +62 -0
- package/dist/src/components/collapsible/collapsible.d.ts.map +1 -0
- package/dist/src/components/collapsible/index.d.ts +2 -0
- package/dist/src/components/collapsible/index.d.ts.map +1 -0
- package/dist/src/components/combobox/combobox.d.ts +124 -0
- package/dist/src/components/combobox/combobox.d.ts.map +1 -0
- package/dist/src/components/combobox/index.d.ts +2 -0
- package/dist/src/components/combobox/index.d.ts.map +1 -0
- package/dist/src/components/command-palette/command-palette.d.ts +225 -0
- package/dist/src/components/command-palette/command-palette.d.ts.map +1 -0
- package/dist/src/components/command-palette/index.d.ts +3 -0
- package/dist/src/components/command-palette/index.d.ts.map +1 -0
- package/dist/src/components/command-palette/types.d.ts +149 -0
- package/dist/src/components/command-palette/types.d.ts.map +1 -0
- package/dist/src/components/date-range-picker/date-range-picker.d.ts +65 -0
- package/dist/src/components/date-range-picker/date-range-picker.d.ts.map +1 -0
- package/dist/src/components/date-range-picker/index.d.ts +2 -0
- package/dist/src/components/date-range-picker/index.d.ts.map +1 -0
- package/dist/src/components/dialog/dialog.d.ts +121 -0
- package/dist/src/components/dialog/dialog.d.ts.map +1 -0
- package/dist/src/components/dialog/index.d.ts +2 -0
- package/dist/src/components/dialog/index.d.ts.map +1 -0
- package/dist/src/components/dropdown/dropdown.d.ts +58 -0
- package/dist/src/components/dropdown/dropdown.d.ts.map +1 -0
- package/dist/src/components/dropdown/index.d.ts +2 -0
- package/dist/src/components/dropdown/index.d.ts.map +1 -0
- package/dist/src/components/empty/empty.d.ts +34 -0
- package/dist/src/components/empty/empty.d.ts.map +1 -0
- package/dist/src/components/empty/index.d.ts +2 -0
- package/dist/src/components/empty/index.d.ts.map +1 -0
- package/dist/src/components/field/field.d.ts +38 -0
- package/dist/src/components/field/field.d.ts.map +1 -0
- package/dist/src/components/field/index.d.ts +2 -0
- package/dist/src/components/field/index.d.ts.map +1 -0
- package/dist/src/components/grid/grid.d.ts +107 -0
- package/dist/src/components/grid/grid.d.ts.map +1 -0
- package/dist/src/components/grid/index.d.ts +2 -0
- package/dist/src/components/grid/index.d.ts.map +1 -0
- package/dist/src/components/input/index.d.ts +4 -0
- package/dist/src/components/input/index.d.ts.map +1 -0
- package/dist/src/components/input/input-area.d.ts +46 -0
- package/dist/src/components/input/input-area.d.ts.map +1 -0
- package/dist/src/components/input/input-group.d.ts +39 -0
- package/dist/src/components/input/input-group.d.ts.map +1 -0
- package/dist/src/components/input/input.d.ts +157 -0
- package/dist/src/components/input/input.d.ts.map +1 -0
- package/dist/src/components/label/index.d.ts +2 -0
- package/dist/src/components/label/index.d.ts.map +1 -0
- package/dist/src/components/label/label.d.ts +54 -0
- package/dist/src/components/label/label.d.ts.map +1 -0
- package/dist/src/components/layer-card/index.d.ts +2 -0
- package/dist/src/components/layer-card/index.d.ts.map +1 -0
- package/dist/src/components/layer-card/layer-card.d.ts +16 -0
- package/dist/src/components/layer-card/layer-card.d.ts.map +1 -0
- package/dist/src/components/link/index.d.ts +2 -0
- package/dist/src/components/link/index.d.ts.map +1 -0
- package/dist/src/components/link/link.d.ts +35 -0
- package/dist/src/components/link/link.d.ts.map +1 -0
- package/dist/src/components/loader/index.d.ts +3 -0
- package/dist/src/components/loader/index.d.ts.map +1 -0
- package/dist/src/components/loader/loader.d.ts +30 -0
- package/dist/src/components/loader/loader.d.ts.map +1 -0
- package/dist/src/components/loader/skeleton-line.d.ts +10 -0
- package/dist/src/components/loader/skeleton-line.d.ts.map +1 -0
- package/dist/src/components/menubar/index.d.ts +3 -0
- package/dist/src/components/menubar/index.d.ts.map +1 -0
- package/dist/src/components/menubar/menubar.d.ts +22 -0
- package/dist/src/components/menubar/menubar.d.ts.map +1 -0
- package/dist/src/components/menubar/use-menu-navigation.d.ts +8 -0
- package/dist/src/components/menubar/use-menu-navigation.d.ts.map +1 -0
- package/dist/src/components/meter/index.d.ts +2 -0
- package/dist/src/components/meter/index.d.ts.map +1 -0
- package/dist/src/components/meter/meter.d.ts +18 -0
- package/dist/src/components/meter/meter.d.ts.map +1 -0
- package/dist/src/components/pagination/index.d.ts +2 -0
- package/dist/src/components/pagination/index.d.ts.map +1 -0
- package/dist/src/components/pagination/pagination.d.ts +28 -0
- package/dist/src/components/pagination/pagination.d.ts.map +1 -0
- package/dist/src/components/popover/index.d.ts +3 -0
- package/dist/src/components/popover/index.d.ts.map +1 -0
- package/dist/src/components/popover/popover.d.ts +110 -0
- package/dist/src/components/popover/popover.d.ts.map +1 -0
- package/dist/src/components/radio/index.d.ts +2 -0
- package/dist/src/components/radio/index.d.ts.map +1 -0
- package/dist/src/components/radio/radio.d.ts +141 -0
- package/dist/src/components/radio/radio.d.ts.map +1 -0
- package/dist/src/components/select/index.d.ts +2 -0
- package/dist/src/components/select/index.d.ts.map +1 -0
- package/dist/src/components/select/select.d.ts +128 -0
- package/dist/src/components/select/select.d.ts.map +1 -0
- package/dist/src/components/sensitive-input/index.d.ts +2 -0
- package/dist/src/components/sensitive-input/index.d.ts.map +1 -0
- package/dist/src/components/sensitive-input/sensitive-input.d.ts +70 -0
- package/dist/src/components/sensitive-input/sensitive-input.d.ts.map +1 -0
- package/dist/src/components/surface/index.d.ts +2 -0
- package/dist/src/components/surface/index.d.ts.map +1 -0
- package/dist/src/components/surface/surface.d.ts +48 -0
- package/dist/src/components/surface/surface.d.ts.map +1 -0
- package/dist/src/components/switch/index.d.ts +2 -0
- package/dist/src/components/switch/index.d.ts.map +1 -0
- package/dist/src/components/switch/switch.d.ts +155 -0
- package/dist/src/components/switch/switch.d.ts.map +1 -0
- package/dist/src/components/table/index.d.ts +2 -0
- package/dist/src/components/table/index.d.ts.map +1 -0
- package/dist/src/components/table/table.d.ts +54 -0
- package/dist/src/components/table/table.d.ts.map +1 -0
- package/dist/src/components/tabs/index.d.ts +3 -0
- package/dist/src/components/tabs/index.d.ts.map +1 -0
- package/dist/src/components/tabs/tabs.d.ts +64 -0
- package/dist/src/components/tabs/tabs.d.ts.map +1 -0
- package/dist/src/components/text/index.d.ts +2 -0
- package/dist/src/components/text/index.d.ts.map +1 -0
- package/dist/src/components/text/text.d.ts +153 -0
- package/dist/src/components/text/text.d.ts.map +1 -0
- package/dist/src/components/toast/index.d.ts +3 -0
- package/dist/src/components/toast/index.d.ts.map +1 -0
- package/dist/src/components/toast/toast.d.ts +66 -0
- package/dist/src/components/toast/toast.d.ts.map +1 -0
- package/dist/src/components/tooltip/index.d.ts +2 -0
- package/dist/src/components/tooltip/index.d.ts.map +1 -0
- package/dist/src/components/tooltip/tooltip.d.ts +43 -0
- package/dist/src/components/tooltip/tooltip.d.ts.map +1 -0
- package/dist/src/index.d.ts +39 -0
- package/dist/src/index.d.ts.map +1 -0
- package/dist/src/primitives/accordion.d.ts +13 -0
- package/dist/src/primitives/accordion.d.ts.map +1 -0
- package/dist/src/primitives/alert-dialog.d.ts +13 -0
- package/dist/src/primitives/alert-dialog.d.ts.map +1 -0
- package/dist/src/primitives/autocomplete.d.ts +13 -0
- package/dist/src/primitives/autocomplete.d.ts.map +1 -0
- package/dist/src/primitives/avatar.d.ts +13 -0
- package/dist/src/primitives/avatar.d.ts.map +1 -0
- package/dist/src/primitives/button.d.ts +13 -0
- package/dist/src/primitives/button.d.ts.map +1 -0
- package/dist/src/primitives/checkbox-group.d.ts +13 -0
- package/dist/src/primitives/checkbox-group.d.ts.map +1 -0
- package/dist/src/primitives/checkbox.d.ts +13 -0
- package/dist/src/primitives/checkbox.d.ts.map +1 -0
- package/dist/src/primitives/collapsible.d.ts +13 -0
- package/dist/src/primitives/collapsible.d.ts.map +1 -0
- package/dist/src/primitives/combobox.d.ts +13 -0
- package/dist/src/primitives/combobox.d.ts.map +1 -0
- package/dist/src/primitives/context-menu.d.ts +13 -0
- package/dist/src/primitives/context-menu.d.ts.map +1 -0
- package/dist/src/primitives/dialog.d.ts +13 -0
- package/dist/src/primitives/dialog.d.ts.map +1 -0
- package/dist/src/primitives/direction-provider.d.ts +13 -0
- package/dist/src/primitives/direction-provider.d.ts.map +1 -0
- package/dist/src/primitives/field.d.ts +13 -0
- package/dist/src/primitives/field.d.ts.map +1 -0
- package/dist/src/primitives/fieldset.d.ts +13 -0
- package/dist/src/primitives/fieldset.d.ts.map +1 -0
- package/dist/src/primitives/form.d.ts +13 -0
- package/dist/src/primitives/form.d.ts.map +1 -0
- package/dist/src/primitives/index.d.ts +52 -0
- package/dist/src/primitives/index.d.ts.map +1 -0
- package/dist/src/primitives/input.d.ts +13 -0
- package/dist/src/primitives/input.d.ts.map +1 -0
- package/dist/src/primitives/menu.d.ts +13 -0
- package/dist/src/primitives/menu.d.ts.map +1 -0
- package/dist/src/primitives/menubar.d.ts +13 -0
- package/dist/src/primitives/menubar.d.ts.map +1 -0
- package/dist/src/primitives/meter.d.ts +13 -0
- package/dist/src/primitives/meter.d.ts.map +1 -0
- package/dist/src/primitives/navigation-menu.d.ts +13 -0
- package/dist/src/primitives/navigation-menu.d.ts.map +1 -0
- package/dist/src/primitives/number-field.d.ts +13 -0
- package/dist/src/primitives/number-field.d.ts.map +1 -0
- package/dist/src/primitives/popover.d.ts +13 -0
- package/dist/src/primitives/popover.d.ts.map +1 -0
- package/dist/src/primitives/preview-card.d.ts +13 -0
- package/dist/src/primitives/preview-card.d.ts.map +1 -0
- package/dist/src/primitives/progress.d.ts +13 -0
- package/dist/src/primitives/progress.d.ts.map +1 -0
- package/dist/src/primitives/radio-group.d.ts +13 -0
- package/dist/src/primitives/radio-group.d.ts.map +1 -0
- package/dist/src/primitives/radio.d.ts +13 -0
- package/dist/src/primitives/radio.d.ts.map +1 -0
- package/dist/src/primitives/scroll-area.d.ts +13 -0
- package/dist/src/primitives/scroll-area.d.ts.map +1 -0
- package/dist/src/primitives/select.d.ts +13 -0
- package/dist/src/primitives/select.d.ts.map +1 -0
- package/dist/src/primitives/separator.d.ts +13 -0
- package/dist/src/primitives/separator.d.ts.map +1 -0
- package/dist/src/primitives/slider.d.ts +13 -0
- package/dist/src/primitives/slider.d.ts.map +1 -0
- package/dist/src/primitives/switch.d.ts +13 -0
- package/dist/src/primitives/switch.d.ts.map +1 -0
- package/dist/src/primitives/tabs.d.ts +13 -0
- package/dist/src/primitives/tabs.d.ts.map +1 -0
- package/dist/src/primitives/toast.d.ts +13 -0
- package/dist/src/primitives/toast.d.ts.map +1 -0
- package/dist/src/primitives/toggle-group.d.ts +13 -0
- package/dist/src/primitives/toggle-group.d.ts.map +1 -0
- package/dist/src/primitives/toggle.d.ts +13 -0
- package/dist/src/primitives/toggle.d.ts.map +1 -0
- package/dist/src/primitives/toolbar.d.ts +13 -0
- package/dist/src/primitives/toolbar.d.ts.map +1 -0
- package/dist/src/primitives/tooltip.d.ts +13 -0
- package/dist/src/primitives/tooltip.d.ts.map +1 -0
- package/dist/src/registry/index.d.ts +8 -0
- package/dist/src/registry/index.d.ts.map +1 -0
- package/dist/src/registry/types.d.ts +191 -0
- package/dist/src/registry/types.d.ts.map +1 -0
- package/dist/src/utils/cn.d.ts +4 -0
- package/dist/src/utils/cn.d.ts.map +1 -0
- package/dist/src/utils/index.d.ts +3 -0
- package/dist/src/utils/index.d.ts.map +1 -0
- package/dist/src/utils/link-provider.d.ts +12 -0
- package/dist/src/utils/link-provider.d.ts.map +1 -0
- package/dist/src/utils/prop-examples.d.ts +36 -0
- package/dist/src/utils/prop-examples.d.ts.map +1 -0
- package/dist/styles/kumo-binding.css +190 -0
- package/dist/styles/kumo-standalone.css +2 -0
- package/dist/styles/kumo.css +55 -0
- package/dist/styles/theme-fedramp.css +20 -0
- package/dist/styles/theme-kumo.css +186 -0
- package/dist/surface-BIC6CXiz.js +21 -0
- package/dist/surface-BIC6CXiz.js.map +1 -0
- package/dist/switch-D4duMhJ0.js +257 -0
- package/dist/switch-D4duMhJ0.js.map +1 -0
- package/dist/table-KuvHGpL8.js +153 -0
- package/dist/table-KuvHGpL8.js.map +1 -0
- package/dist/tabs-lQup-IbT.js +85 -0
- package/dist/tabs-lQup-IbT.js.map +1 -0
- package/dist/text-BEhqwMfe.js +97 -0
- package/dist/text-BEhqwMfe.js.map +1 -0
- package/dist/toast-8YyyQuqZ.js +69 -0
- package/dist/toast-8YyyQuqZ.js.map +1 -0
- package/dist/tooltip-DJWsDTWJ.js +85 -0
- package/dist/tooltip-DJWsDTWJ.js.map +1 -0
- package/dist/utils.js +10 -0
- package/dist/utils.js.map +1 -0
- package/dist/vendor-base-ui-DWIDNgE1.js +20446 -0
- package/dist/vendor-base-ui-DWIDNgE1.js.map +1 -0
- package/dist/vendor-floating-ui-BgbEw62H.js +1286 -0
- package/dist/vendor-floating-ui-BgbEw62H.js.map +1 -0
- package/dist/vendor-styling-BQbxAbdS.js +2775 -0
- package/dist/vendor-styling-BQbxAbdS.js.map +1 -0
- package/dist/vendor-utils-DD8jNJwD.js +741 -0
- package/dist/vendor-utils-DD8jNJwD.js.map +1 -0
- package/package.json +444 -0
- package/scripts/component-registry/cache.ts +123 -0
- package/scripts/component-registry/discovery.ts +469 -0
- package/scripts/component-registry/example-cleanup.ts +168 -0
- package/scripts/component-registry/index.test.ts +680 -0
- package/scripts/component-registry/index.ts +874 -0
- package/scripts/component-registry/markdown-generator.ts +222 -0
- package/scripts/component-registry/metadata.ts +643 -0
- package/scripts/component-registry/props-filter.ts +310 -0
- package/scripts/component-registry/schema-generator.ts +326 -0
- package/scripts/component-registry/sub-components.ts +349 -0
- package/scripts/component-registry/types.ts +156 -0
- package/scripts/component-registry/utils.ts +280 -0
- package/scripts/component-registry/variant-parser.ts +261 -0
- package/scripts/css-build.ts +55 -0
- package/scripts/generate-primitives.ts +178 -0
- package/scripts/theme-generator/config.ts +392 -0
- package/scripts/theme-generator/generate-css.ts +250 -0
- package/scripts/theme-generator/index.ts +159 -0
- package/scripts/theme-generator/migrate.ts +560 -0
- package/scripts/theme-generator/types.ts +86 -0
|
@@ -0,0 +1,3754 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": "1.0.0",
|
|
3
|
+
"components": {
|
|
4
|
+
"Badge": {
|
|
5
|
+
"name": "Badge",
|
|
6
|
+
"type": "component",
|
|
7
|
+
"description": "Badge component",
|
|
8
|
+
"importPath": "@cloudflare/kumo",
|
|
9
|
+
"category": "Display",
|
|
10
|
+
"props": {
|
|
11
|
+
"variant": {
|
|
12
|
+
"type": "enum",
|
|
13
|
+
"optional": true,
|
|
14
|
+
"values": [
|
|
15
|
+
"primary",
|
|
16
|
+
"secondary",
|
|
17
|
+
"destructive",
|
|
18
|
+
"outline",
|
|
19
|
+
"beta"
|
|
20
|
+
],
|
|
21
|
+
"descriptions": {
|
|
22
|
+
"primary": "Default high-emphasis badge for important labels",
|
|
23
|
+
"secondary": "Subtle badge for secondary information",
|
|
24
|
+
"destructive": "Error or danger state indicator",
|
|
25
|
+
"outline": "Bordered badge with transparent background",
|
|
26
|
+
"beta": "Indicates beta or experimental features"
|
|
27
|
+
},
|
|
28
|
+
"classes": {
|
|
29
|
+
"primary": "bg-kumo-contrast text-kumo-inverse",
|
|
30
|
+
"secondary": "bg-kumo-fill text-kumo-default",
|
|
31
|
+
"destructive": "bg-kumo-danger text-white",
|
|
32
|
+
"outline": "border border-kumo-fill bg-transparent text-kumo-default",
|
|
33
|
+
"beta": "border border-dashed border-kumo-brand bg-transparent text-kumo-link"
|
|
34
|
+
},
|
|
35
|
+
"default": "primary"
|
|
36
|
+
},
|
|
37
|
+
"className": {
|
|
38
|
+
"type": "string",
|
|
39
|
+
"optional": true
|
|
40
|
+
},
|
|
41
|
+
"children": {
|
|
42
|
+
"type": "ReactNode",
|
|
43
|
+
"optional": true
|
|
44
|
+
}
|
|
45
|
+
},
|
|
46
|
+
"examples": [
|
|
47
|
+
"<div className=\"flex flex-wrap items-center gap-2\">\n <Badge variant=\"primary\">Primary</Badge>\n <Badge variant=\"secondary\">Secondary</Badge>\n <Badge variant=\"destructive\">Destructive</Badge>\n <Badge variant=\"outline\">Outline</Badge>\n <Badge variant=\"beta\">Beta</Badge>\n </div>",
|
|
48
|
+
"<Badge variant=\"primary\">Primary</Badge>",
|
|
49
|
+
"<Badge variant=\"secondary\">Secondary</Badge>",
|
|
50
|
+
"<Badge variant=\"destructive\">Destructive</Badge>",
|
|
51
|
+
"<Badge variant=\"outline\">Outline</Badge>",
|
|
52
|
+
"<Badge variant=\"beta\">Beta</Badge>",
|
|
53
|
+
"<p className=\"flex items-center gap-2\">\n Workers\n <Badge variant=\"beta\">Beta</Badge>\n </p>"
|
|
54
|
+
],
|
|
55
|
+
"colors": [
|
|
56
|
+
"bg-kumo-contrast",
|
|
57
|
+
"bg-kumo-danger",
|
|
58
|
+
"bg-kumo-fill",
|
|
59
|
+
"border-kumo-brand",
|
|
60
|
+
"border-kumo-fill",
|
|
61
|
+
"text-kumo-default",
|
|
62
|
+
"text-kumo-inverse",
|
|
63
|
+
"text-kumo-link"
|
|
64
|
+
],
|
|
65
|
+
"baseStyles": "inline-flex w-fit flex-none shrink-0 items-center justify-self-start rounded-full px-2 py-0.5 text-xs font-medium whitespace-nowrap"
|
|
66
|
+
},
|
|
67
|
+
"Banner": {
|
|
68
|
+
"name": "Banner",
|
|
69
|
+
"type": "component",
|
|
70
|
+
"description": "Banner component",
|
|
71
|
+
"importPath": "@cloudflare/kumo",
|
|
72
|
+
"category": "Feedback",
|
|
73
|
+
"props": {
|
|
74
|
+
"icon": {
|
|
75
|
+
"type": "ReactNode",
|
|
76
|
+
"optional": true
|
|
77
|
+
},
|
|
78
|
+
"text": {
|
|
79
|
+
"type": "string",
|
|
80
|
+
"optional": true
|
|
81
|
+
},
|
|
82
|
+
"children": {
|
|
83
|
+
"type": "ReactNode",
|
|
84
|
+
"optional": true
|
|
85
|
+
},
|
|
86
|
+
"variant": {
|
|
87
|
+
"type": "enum",
|
|
88
|
+
"optional": true,
|
|
89
|
+
"values": [
|
|
90
|
+
"default",
|
|
91
|
+
"alert",
|
|
92
|
+
"error"
|
|
93
|
+
],
|
|
94
|
+
"descriptions": {
|
|
95
|
+
"default": "Informational banner for general messages",
|
|
96
|
+
"alert": "Warning banner for cautionary messages",
|
|
97
|
+
"error": "Error banner for critical issues"
|
|
98
|
+
},
|
|
99
|
+
"classes": {
|
|
100
|
+
"default": "bg-kumo-info/20 border-kumo-info text-kumo-link selection:bg-kumo-info-tint",
|
|
101
|
+
"alert": "bg-kumo-warning/20 border-kumo-warning text-kumo-warning selection:bg-kumo-warning-tint",
|
|
102
|
+
"error": "bg-kumo-danger/20 border-kumo-danger text-kumo-danger selection:bg-kumo-danger-tint"
|
|
103
|
+
},
|
|
104
|
+
"default": "default"
|
|
105
|
+
},
|
|
106
|
+
"className": {
|
|
107
|
+
"type": "string",
|
|
108
|
+
"optional": true
|
|
109
|
+
}
|
|
110
|
+
},
|
|
111
|
+
"examples": [
|
|
112
|
+
"<div className=\"space-y-3\">\n <Banner>This is an informational banner.</Banner>\n <Banner variant=\"alert\">This is an alert banner.</Banner>\n <Banner variant=\"error\">This is an error banner.</Banner>\n </div>",
|
|
113
|
+
"<Banner>This is an informational banner.</Banner>",
|
|
114
|
+
"<Banner variant=\"alert\">Your session will expire soon.</Banner>",
|
|
115
|
+
"<Banner variant=\"error\">We couldn't save your changes.</Banner>",
|
|
116
|
+
"<Banner icon={<WarningCircle />} variant=\"alert\">\n Review your billing information.\n </Banner>",
|
|
117
|
+
"<Banner icon={<Info />}>\n <Text DANGEROUS_className=\"text-inherit\">\n This banner supports <strong>custom content</strong> with Text.\n </Text>\n </Banner>"
|
|
118
|
+
],
|
|
119
|
+
"colors": [
|
|
120
|
+
"bg-kumo-danger",
|
|
121
|
+
"bg-kumo-danger-tint",
|
|
122
|
+
"bg-kumo-info",
|
|
123
|
+
"bg-kumo-info-tint",
|
|
124
|
+
"bg-kumo-warning",
|
|
125
|
+
"bg-kumo-warning-tint",
|
|
126
|
+
"border-kumo-danger",
|
|
127
|
+
"border-kumo-info",
|
|
128
|
+
"border-kumo-warning",
|
|
129
|
+
"text-kumo-danger",
|
|
130
|
+
"text-kumo-link",
|
|
131
|
+
"text-kumo-warning"
|
|
132
|
+
],
|
|
133
|
+
"baseStyles": "flex w-full items-center gap-2 rounded-lg border px-4 py-1.5 text-base"
|
|
134
|
+
},
|
|
135
|
+
"Breadcrumbs": {
|
|
136
|
+
"name": "Breadcrumbs",
|
|
137
|
+
"type": "component",
|
|
138
|
+
"description": "Breadcrumbs component",
|
|
139
|
+
"importPath": "@cloudflare/kumo",
|
|
140
|
+
"category": "Display",
|
|
141
|
+
"props": {
|
|
142
|
+
"size": {
|
|
143
|
+
"type": "enum",
|
|
144
|
+
"optional": true,
|
|
145
|
+
"values": [
|
|
146
|
+
"sm",
|
|
147
|
+
"base"
|
|
148
|
+
],
|
|
149
|
+
"descriptions": {
|
|
150
|
+
"sm": "Compact breadcrumbs for dense UIs",
|
|
151
|
+
"base": "Default breadcrumbs size"
|
|
152
|
+
},
|
|
153
|
+
"classes": {
|
|
154
|
+
"sm": "text-sm h-10 gap-0.5",
|
|
155
|
+
"base": "text-base h-12 gap-1"
|
|
156
|
+
},
|
|
157
|
+
"default": "base"
|
|
158
|
+
},
|
|
159
|
+
"children": {
|
|
160
|
+
"type": "ReactNode",
|
|
161
|
+
"optional": true
|
|
162
|
+
},
|
|
163
|
+
"className": {
|
|
164
|
+
"type": "string",
|
|
165
|
+
"optional": true
|
|
166
|
+
}
|
|
167
|
+
},
|
|
168
|
+
"examples": [
|
|
169
|
+
"<Breadcrumbs>\n <Breadcrumbs.Link href=\"#\">Home</Breadcrumbs.Link>\n <Breadcrumbs.Separator />\n <Breadcrumbs.Link href=\"#\">Docs</Breadcrumbs.Link>\n <Breadcrumbs.Separator />\n <Breadcrumbs.Current>Breadcrumbs</Breadcrumbs.Current>\n </Breadcrumbs>",
|
|
170
|
+
"<Breadcrumbs>\n <Breadcrumbs.Link href=\"#\" icon={<House size={16} />}>\n Home\n </Breadcrumbs.Link>\n <Breadcrumbs.Separator />\n <Breadcrumbs.Link href=\"#\">Projects</Breadcrumbs.Link>\n <Breadcrumbs.Separator />\n <Breadcrumbs.Current>Current Project</Breadcrumbs.Current>\n </Breadcrumbs>",
|
|
171
|
+
"<Breadcrumbs>\n <Breadcrumbs.Link href=\"#\" icon={<House size={16} />}>\n Home\n </Breadcrumbs.Link>\n <Breadcrumbs.Separator />\n <Breadcrumbs.Link href=\"#\">Docs</Breadcrumbs.Link>\n <Breadcrumbs.Separator />\n <Breadcrumbs.Current loading></Breadcrumbs.Current>\n </Breadcrumbs>",
|
|
172
|
+
"<Breadcrumbs>\n <Breadcrumbs.Current icon={<House size={16} />}>\n Worker Analytics\n </Breadcrumbs.Current>\n </Breadcrumbs>",
|
|
173
|
+
"<Breadcrumbs>\n <Breadcrumbs.Link href=\"#\">Home</Breadcrumbs.Link>\n <Breadcrumbs.Separator />\n <Breadcrumbs.Current>Breadcrumbs</Breadcrumbs.Current>\n <Breadcrumbs.Clipboard text=\"#\" />\n </Breadcrumbs>"
|
|
174
|
+
],
|
|
175
|
+
"colors": [
|
|
176
|
+
"text-kumo-inactive",
|
|
177
|
+
"text-kumo-subtle",
|
|
178
|
+
"text-kumo-success"
|
|
179
|
+
],
|
|
180
|
+
"subComponents": {
|
|
181
|
+
"Link": {
|
|
182
|
+
"name": "Link",
|
|
183
|
+
"description": "Link sub-component",
|
|
184
|
+
"props": {
|
|
185
|
+
"href": {
|
|
186
|
+
"type": "string",
|
|
187
|
+
"required": true
|
|
188
|
+
},
|
|
189
|
+
"icon": {
|
|
190
|
+
"type": "React.ReactNode",
|
|
191
|
+
"optional": true
|
|
192
|
+
}
|
|
193
|
+
}
|
|
194
|
+
},
|
|
195
|
+
"Current": {
|
|
196
|
+
"name": "Current",
|
|
197
|
+
"description": "Current sub-component",
|
|
198
|
+
"props": {
|
|
199
|
+
"loading": {
|
|
200
|
+
"type": "boolean",
|
|
201
|
+
"optional": true
|
|
202
|
+
},
|
|
203
|
+
"icon": {
|
|
204
|
+
"type": "React.ReactNode",
|
|
205
|
+
"optional": true
|
|
206
|
+
}
|
|
207
|
+
}
|
|
208
|
+
},
|
|
209
|
+
"Separator": {
|
|
210
|
+
"name": "Separator",
|
|
211
|
+
"description": "Separator sub-component",
|
|
212
|
+
"props": {}
|
|
213
|
+
},
|
|
214
|
+
"Clipboard": {
|
|
215
|
+
"name": "Clipboard",
|
|
216
|
+
"description": "Clipboard sub-component",
|
|
217
|
+
"props": {
|
|
218
|
+
"text": {
|
|
219
|
+
"type": "string",
|
|
220
|
+
"required": true
|
|
221
|
+
}
|
|
222
|
+
}
|
|
223
|
+
}
|
|
224
|
+
}
|
|
225
|
+
},
|
|
226
|
+
"Button": {
|
|
227
|
+
"name": "Button",
|
|
228
|
+
"type": "component",
|
|
229
|
+
"description": "Button component",
|
|
230
|
+
"importPath": "@cloudflare/kumo",
|
|
231
|
+
"category": "Action",
|
|
232
|
+
"props": {
|
|
233
|
+
"children": {
|
|
234
|
+
"type": "ReactNode",
|
|
235
|
+
"optional": true
|
|
236
|
+
},
|
|
237
|
+
"className": {
|
|
238
|
+
"type": "string",
|
|
239
|
+
"optional": true
|
|
240
|
+
},
|
|
241
|
+
"icon": {
|
|
242
|
+
"type": "ReactNode",
|
|
243
|
+
"optional": true
|
|
244
|
+
},
|
|
245
|
+
"loading": {
|
|
246
|
+
"type": "boolean",
|
|
247
|
+
"optional": true
|
|
248
|
+
},
|
|
249
|
+
"shape": {
|
|
250
|
+
"type": "enum",
|
|
251
|
+
"optional": true,
|
|
252
|
+
"values": [
|
|
253
|
+
"base",
|
|
254
|
+
"square",
|
|
255
|
+
"circle"
|
|
256
|
+
],
|
|
257
|
+
"descriptions": {
|
|
258
|
+
"base": "Default rectangular button shape",
|
|
259
|
+
"square": "Square button for icon-only actions",
|
|
260
|
+
"circle": "Circular button for icon-only actions"
|
|
261
|
+
},
|
|
262
|
+
"classes": {
|
|
263
|
+
"square": "items-center justify-center p-0",
|
|
264
|
+
"circle": "items-center justify-center p-0 rounded-full"
|
|
265
|
+
},
|
|
266
|
+
"default": "base"
|
|
267
|
+
},
|
|
268
|
+
"size": {
|
|
269
|
+
"type": "enum",
|
|
270
|
+
"optional": true,
|
|
271
|
+
"values": [
|
|
272
|
+
"xs",
|
|
273
|
+
"sm",
|
|
274
|
+
"base",
|
|
275
|
+
"lg"
|
|
276
|
+
],
|
|
277
|
+
"descriptions": {
|
|
278
|
+
"xs": "Extra small button for compact UIs",
|
|
279
|
+
"sm": "Small button for secondary actions",
|
|
280
|
+
"base": "Default button size",
|
|
281
|
+
"lg": "Large button for primary CTAs"
|
|
282
|
+
},
|
|
283
|
+
"classes": {
|
|
284
|
+
"xs": "h-5 gap-1 rounded-sm px-1.5 text-xs",
|
|
285
|
+
"sm": "h-6.5 gap-1 rounded-md px-2 text-xs",
|
|
286
|
+
"base": "h-9 gap-1.5 rounded-lg px-3 text-base",
|
|
287
|
+
"lg": "h-10 gap-2 rounded-lg px-4 text-base"
|
|
288
|
+
},
|
|
289
|
+
"default": "base"
|
|
290
|
+
},
|
|
291
|
+
"variant": {
|
|
292
|
+
"type": "enum",
|
|
293
|
+
"optional": true,
|
|
294
|
+
"values": [
|
|
295
|
+
"primary",
|
|
296
|
+
"secondary",
|
|
297
|
+
"ghost",
|
|
298
|
+
"destructive",
|
|
299
|
+
"secondary-destructive",
|
|
300
|
+
"outline"
|
|
301
|
+
],
|
|
302
|
+
"descriptions": {
|
|
303
|
+
"primary": "High-emphasis button for primary actions",
|
|
304
|
+
"secondary": "Default button style for most actions",
|
|
305
|
+
"ghost": "Minimal button with no background",
|
|
306
|
+
"destructive": "Danger button for destructive actions like delete",
|
|
307
|
+
"secondary-destructive": "Secondary button with destructive text for less prominent dangerous actions",
|
|
308
|
+
"outline": "Bordered button with transparent background"
|
|
309
|
+
},
|
|
310
|
+
"classes": {
|
|
311
|
+
"primary": "bg-kumo-brand !text-white hover:bg-kumo-brand-hover focus:bg-kumo-brand-hover disabled:bg-kumo-brand/50",
|
|
312
|
+
"secondary": "bg-kumo-control !text-kumo-default ring not-disabled:hover:border-secondary! not-disabled:hover:bg-kumo-control disabled:bg-kumo-control/50 disabled:!text-kumo-default/70 ring-kumo-line data-[state=open]:bg-kumo-control",
|
|
313
|
+
"ghost": "text-kumo-default hover:bg-kumo-tint shadow-none bg-inherit",
|
|
314
|
+
"destructive": "bg-kumo-danger !text-white hover:bg-kumo-danger/70",
|
|
315
|
+
"secondary-destructive": "bg-kumo-control !text-kumo-danger ring not-disabled:hover:border-secondary! not-disabled:hover:bg-kumo-control disabled:bg-kumo-control/50 disabled:!text-kumo-danger/70 ring-kumo-line data-[state=open]:bg-kumo-control",
|
|
316
|
+
"outline": "bg-kumo-base text-kumo-default ring ring-kumo-line"
|
|
317
|
+
},
|
|
318
|
+
"stateClasses": {
|
|
319
|
+
"primary": {
|
|
320
|
+
"hover": "hover:bg-kumo-brand-hover",
|
|
321
|
+
"focus": "focus:bg-kumo-brand-hover",
|
|
322
|
+
"disabled": "disabled:bg-kumo-brand/50"
|
|
323
|
+
},
|
|
324
|
+
"secondary": {
|
|
325
|
+
"not-disabled": "not-disabled:hover:border-secondary! not-disabled:hover:bg-kumo-control",
|
|
326
|
+
"disabled": "disabled:bg-kumo-control/50 disabled:!text-kumo-default/70",
|
|
327
|
+
"data-state": "data-[state=open]:bg-kumo-control"
|
|
328
|
+
},
|
|
329
|
+
"ghost": {
|
|
330
|
+
"hover": "hover:bg-kumo-tint"
|
|
331
|
+
},
|
|
332
|
+
"destructive": {
|
|
333
|
+
"hover": "hover:bg-kumo-danger/70"
|
|
334
|
+
},
|
|
335
|
+
"secondary-destructive": {
|
|
336
|
+
"not-disabled": "not-disabled:hover:border-secondary! not-disabled:hover:bg-kumo-control",
|
|
337
|
+
"disabled": "disabled:bg-kumo-control/50 disabled:!text-kumo-danger/70",
|
|
338
|
+
"data-state": "data-[state=open]:bg-kumo-control"
|
|
339
|
+
}
|
|
340
|
+
},
|
|
341
|
+
"default": "secondary"
|
|
342
|
+
},
|
|
343
|
+
"id": {
|
|
344
|
+
"type": "string",
|
|
345
|
+
"optional": true
|
|
346
|
+
},
|
|
347
|
+
"lang": {
|
|
348
|
+
"type": "string",
|
|
349
|
+
"optional": true
|
|
350
|
+
},
|
|
351
|
+
"title": {
|
|
352
|
+
"type": "string",
|
|
353
|
+
"optional": true
|
|
354
|
+
},
|
|
355
|
+
"disabled": {
|
|
356
|
+
"type": "boolean",
|
|
357
|
+
"optional": true
|
|
358
|
+
},
|
|
359
|
+
"name": {
|
|
360
|
+
"type": "string",
|
|
361
|
+
"optional": true
|
|
362
|
+
},
|
|
363
|
+
"type": {
|
|
364
|
+
"type": "enum",
|
|
365
|
+
"optional": true,
|
|
366
|
+
"values": [
|
|
367
|
+
"submit",
|
|
368
|
+
"reset",
|
|
369
|
+
"button"
|
|
370
|
+
]
|
|
371
|
+
},
|
|
372
|
+
"value": {
|
|
373
|
+
"type": "string | string[] | number",
|
|
374
|
+
"optional": true
|
|
375
|
+
}
|
|
376
|
+
},
|
|
377
|
+
"examples": [
|
|
378
|
+
"<div className=\"flex flex-wrap items-center gap-2\">\n <Button variant=\"secondary\">Button</Button>\n <Button variant=\"secondary\" shape=\"square\" icon={PlusIcon} />\n </div>",
|
|
379
|
+
"<Button variant=\"primary\">Primary</Button>",
|
|
380
|
+
"<Button variant=\"secondary\">Secondary</Button>",
|
|
381
|
+
"<Button variant=\"ghost\">Ghost</Button>",
|
|
382
|
+
"<Button variant=\"destructive\">Destructive</Button>",
|
|
383
|
+
"<Button variant=\"outline\">Outline</Button>",
|
|
384
|
+
"<Button variant=\"secondary-destructive\">Secondary Destructive</Button>",
|
|
385
|
+
"<div className=\"flex flex-wrap items-center gap-3\">\n <Button size=\"xs\" variant=\"secondary\">\n Extra Small\n </Button>\n <Button size=\"sm\" variant=\"secondary\">\n Small\n </Button>\n <Button size=\"base\" variant=\"secondary\">\n Base\n </Button>\n <Button size=\"lg\" variant=\"secondary\">\n Large\n </Button>\n </div>",
|
|
386
|
+
"<Button variant=\"secondary\" icon={PlusIcon}>\n Create Worker\n </Button>",
|
|
387
|
+
"<div className=\"flex flex-wrap items-center gap-3\">\n <Button variant=\"secondary\" shape=\"square\" icon={PlusIcon} />\n <Button variant=\"secondary\" shape=\"circle\" icon={PlusIcon} />\n </div>",
|
|
388
|
+
"<Button variant=\"primary\" loading>\n Loading...\n </Button>",
|
|
389
|
+
"<Button variant=\"secondary\" disabled>\n Disabled\n </Button>"
|
|
390
|
+
],
|
|
391
|
+
"colors": [
|
|
392
|
+
"bg-kumo-base",
|
|
393
|
+
"bg-kumo-brand",
|
|
394
|
+
"bg-kumo-brand-hover",
|
|
395
|
+
"bg-kumo-control",
|
|
396
|
+
"bg-kumo-danger",
|
|
397
|
+
"bg-kumo-tint",
|
|
398
|
+
"ring-kumo-line",
|
|
399
|
+
"ring-kumo-ring",
|
|
400
|
+
"text-kumo-danger",
|
|
401
|
+
"text-kumo-default",
|
|
402
|
+
"text-kumo-subtle"
|
|
403
|
+
]
|
|
404
|
+
},
|
|
405
|
+
"Checkbox": {
|
|
406
|
+
"name": "Checkbox",
|
|
407
|
+
"type": "component",
|
|
408
|
+
"description": "Checkbox component",
|
|
409
|
+
"importPath": "@cloudflare/kumo",
|
|
410
|
+
"category": "Input",
|
|
411
|
+
"props": {
|
|
412
|
+
"variant": {
|
|
413
|
+
"type": "enum",
|
|
414
|
+
"optional": true,
|
|
415
|
+
"description": "Visual variant: \"default\" or \"error\" for validation failures (visual only, no error text)",
|
|
416
|
+
"values": [
|
|
417
|
+
"default",
|
|
418
|
+
"error"
|
|
419
|
+
],
|
|
420
|
+
"descriptions": {
|
|
421
|
+
"default": "Default checkbox appearance",
|
|
422
|
+
"error": "Error state for validation failures"
|
|
423
|
+
},
|
|
424
|
+
"classes": {
|
|
425
|
+
"default": "[&:focus-within>span]:ring-kumo-ring [&:hover>span]:ring-kumo-ring",
|
|
426
|
+
"error": "[&>span]:ring-kumo-danger"
|
|
427
|
+
},
|
|
428
|
+
"stateClasses": {
|
|
429
|
+
"default": {
|
|
430
|
+
"focus": "[&:focus-within>span]:ring-kumo-ring",
|
|
431
|
+
"hover": "[&:hover>span]:ring-kumo-ring"
|
|
432
|
+
}
|
|
433
|
+
},
|
|
434
|
+
"default": "default"
|
|
435
|
+
},
|
|
436
|
+
"label": {
|
|
437
|
+
"type": "ReactNode",
|
|
438
|
+
"optional": true,
|
|
439
|
+
"description": "Label content for the checkbox (enables built-in Field wrapper) - can be a string or any React node"
|
|
440
|
+
},
|
|
441
|
+
"labelTooltip": {
|
|
442
|
+
"type": "ReactNode",
|
|
443
|
+
"optional": true,
|
|
444
|
+
"description": "Tooltip content to display next to the label via an info icon"
|
|
445
|
+
},
|
|
446
|
+
"controlFirst": {
|
|
447
|
+
"type": "boolean",
|
|
448
|
+
"optional": true,
|
|
449
|
+
"description": "When true (default), checkbox appears before label. When false, label appears before checkbox."
|
|
450
|
+
},
|
|
451
|
+
"checked": {
|
|
452
|
+
"type": "boolean",
|
|
453
|
+
"optional": true,
|
|
454
|
+
"description": "Whether the checkbox is checked (controlled)"
|
|
455
|
+
},
|
|
456
|
+
"indeterminate": {
|
|
457
|
+
"type": "boolean",
|
|
458
|
+
"optional": true,
|
|
459
|
+
"description": "Whether the checkbox is in indeterminate state"
|
|
460
|
+
},
|
|
461
|
+
"disabled": {
|
|
462
|
+
"type": "boolean",
|
|
463
|
+
"optional": true,
|
|
464
|
+
"description": "Whether the checkbox is disabled"
|
|
465
|
+
},
|
|
466
|
+
"name": {
|
|
467
|
+
"type": "string",
|
|
468
|
+
"optional": true,
|
|
469
|
+
"description": "Name for form submission"
|
|
470
|
+
},
|
|
471
|
+
"required": {
|
|
472
|
+
"type": "boolean",
|
|
473
|
+
"optional": true,
|
|
474
|
+
"description": "Whether the field is required"
|
|
475
|
+
},
|
|
476
|
+
"className": {
|
|
477
|
+
"type": "string",
|
|
478
|
+
"optional": true,
|
|
479
|
+
"description": "Additional class name"
|
|
480
|
+
},
|
|
481
|
+
"onValueChange": {
|
|
482
|
+
"type": "(checked: boolean) => void",
|
|
483
|
+
"description": "Callback when checkbox value changes"
|
|
484
|
+
}
|
|
485
|
+
},
|
|
486
|
+
"examples": [
|
|
487
|
+
"<Checkbox\n label=\"Accept terms and conditions\"\n checked={checked}\n onCheckedChange={setChecked}\n />",
|
|
488
|
+
"<Checkbox\n label=\"Enable notifications\"\n checked={checked}\n onCheckedChange={setChecked}\n />",
|
|
489
|
+
"<Checkbox label=\"I agree\" checked={checked} onCheckedChange={setChecked} />",
|
|
490
|
+
"<Checkbox\n label=\"Select all\"\n indeterminate={indeterminate}\n onCheckedChange={setIndeterminate}\n />",
|
|
491
|
+
"<Checkbox\n label=\"Remember me\"\n controlFirst={false}\n checked={checked}\n onCheckedChange={setChecked}\n />",
|
|
492
|
+
"<Checkbox label=\"Disabled option\" disabled />",
|
|
493
|
+
"<Checkbox label=\"Invalid option\" variant=\"error\" />",
|
|
494
|
+
"<Checkbox.Group\n legend=\"Email preferences\"\n description=\"Choose how you'd like to receive updates\"\n value={preferences}\n onValueChange={setPreferences}\n >\n <Checkbox.Item value=\"email\" label=\"Email notifications\" />\n <Checkbox.Item value=\"sms\" label=\"SMS notifications\" />\n <Checkbox.Item value=\"push\" label=\"Push notifications\" />\n </Checkbox.Group>",
|
|
495
|
+
"<Checkbox.Group\n legend=\"Required preferences\"\n error=\"Please select at least one notification method\"\n value={[]}\n onValueChange={() => {}}\n >\n <Checkbox.Item value=\"email\" label=\"Email\" variant=\"error\" />\n <Checkbox.Item value=\"sms\" label=\"SMS\" variant=\"error\" />\n </Checkbox.Group>"
|
|
496
|
+
],
|
|
497
|
+
"colors": [
|
|
498
|
+
"bg-kumo-base",
|
|
499
|
+
"bg-kumo-contrast",
|
|
500
|
+
"border-kumo-line",
|
|
501
|
+
"ring-kumo-danger",
|
|
502
|
+
"ring-kumo-line",
|
|
503
|
+
"ring-kumo-ring",
|
|
504
|
+
"text-kumo-danger",
|
|
505
|
+
"text-kumo-default",
|
|
506
|
+
"text-kumo-inverse",
|
|
507
|
+
"text-kumo-subtle"
|
|
508
|
+
],
|
|
509
|
+
"subComponents": {
|
|
510
|
+
"Item": {
|
|
511
|
+
"name": "Item",
|
|
512
|
+
"description": "Item sub-component",
|
|
513
|
+
"props": {}
|
|
514
|
+
},
|
|
515
|
+
"Group": {
|
|
516
|
+
"name": "Group",
|
|
517
|
+
"description": "Group sub-component",
|
|
518
|
+
"props": {
|
|
519
|
+
"legend": {
|
|
520
|
+
"type": "string",
|
|
521
|
+
"required": true
|
|
522
|
+
},
|
|
523
|
+
"children": {
|
|
524
|
+
"type": "ReactNode",
|
|
525
|
+
"required": true
|
|
526
|
+
},
|
|
527
|
+
"error": {
|
|
528
|
+
"type": "string",
|
|
529
|
+
"optional": true
|
|
530
|
+
},
|
|
531
|
+
"description": {
|
|
532
|
+
"type": "ReactNode",
|
|
533
|
+
"optional": true
|
|
534
|
+
},
|
|
535
|
+
"value": {
|
|
536
|
+
"type": "string[]",
|
|
537
|
+
"optional": true
|
|
538
|
+
},
|
|
539
|
+
"allValues": {
|
|
540
|
+
"type": "string[]",
|
|
541
|
+
"optional": true
|
|
542
|
+
},
|
|
543
|
+
"disabled": {
|
|
544
|
+
"type": "boolean",
|
|
545
|
+
"optional": true
|
|
546
|
+
},
|
|
547
|
+
"controlFirst": {
|
|
548
|
+
"type": "boolean",
|
|
549
|
+
"optional": true
|
|
550
|
+
},
|
|
551
|
+
"className": {
|
|
552
|
+
"type": "string",
|
|
553
|
+
"optional": true
|
|
554
|
+
}
|
|
555
|
+
}
|
|
556
|
+
}
|
|
557
|
+
},
|
|
558
|
+
"styling": {
|
|
559
|
+
"dimensions": "h-4 w-4",
|
|
560
|
+
"borderRadius": "rounded-sm",
|
|
561
|
+
"baseTokens": [
|
|
562
|
+
"bg-kumo-base",
|
|
563
|
+
"ring-kumo-line"
|
|
564
|
+
],
|
|
565
|
+
"states": {
|
|
566
|
+
"checked": [
|
|
567
|
+
"bg-kumo-contrast",
|
|
568
|
+
"text-kumo-inverse"
|
|
569
|
+
],
|
|
570
|
+
"indeterminate": [
|
|
571
|
+
"bg-kumo-contrast",
|
|
572
|
+
"text-kumo-inverse"
|
|
573
|
+
],
|
|
574
|
+
"error": [
|
|
575
|
+
"ring-kumo-danger"
|
|
576
|
+
],
|
|
577
|
+
"hover": [
|
|
578
|
+
"ring-kumo-ring"
|
|
579
|
+
],
|
|
580
|
+
"focus": [
|
|
581
|
+
"ring-kumo-ring"
|
|
582
|
+
],
|
|
583
|
+
"disabled": [
|
|
584
|
+
"opacity-50",
|
|
585
|
+
"cursor-not-allowed"
|
|
586
|
+
]
|
|
587
|
+
},
|
|
588
|
+
"icons": [
|
|
589
|
+
{
|
|
590
|
+
"name": "ph-check",
|
|
591
|
+
"state": "checked",
|
|
592
|
+
"size": 12
|
|
593
|
+
},
|
|
594
|
+
{
|
|
595
|
+
"name": "ph-minus",
|
|
596
|
+
"state": "indeterminate",
|
|
597
|
+
"size": 12
|
|
598
|
+
}
|
|
599
|
+
]
|
|
600
|
+
}
|
|
601
|
+
},
|
|
602
|
+
"ClipboardText": {
|
|
603
|
+
"name": "ClipboardText",
|
|
604
|
+
"type": "component",
|
|
605
|
+
"description": "ClipboardText component",
|
|
606
|
+
"importPath": "@cloudflare/kumo",
|
|
607
|
+
"category": "Action",
|
|
608
|
+
"props": {
|
|
609
|
+
"size": {
|
|
610
|
+
"type": "enum",
|
|
611
|
+
"optional": true,
|
|
612
|
+
"values": [
|
|
613
|
+
"sm",
|
|
614
|
+
"base",
|
|
615
|
+
"lg"
|
|
616
|
+
],
|
|
617
|
+
"descriptions": {
|
|
618
|
+
"sm": "Small clipboard text for compact UIs",
|
|
619
|
+
"base": "Default clipboard text size",
|
|
620
|
+
"lg": "Large clipboard text for prominent display"
|
|
621
|
+
},
|
|
622
|
+
"classes": {
|
|
623
|
+
"sm": "text-xs",
|
|
624
|
+
"base": "text-sm",
|
|
625
|
+
"lg": "text-sm"
|
|
626
|
+
},
|
|
627
|
+
"default": "lg"
|
|
628
|
+
},
|
|
629
|
+
"text": {
|
|
630
|
+
"type": "string",
|
|
631
|
+
"required": true,
|
|
632
|
+
"description": "The text to display and copy to clipboard"
|
|
633
|
+
},
|
|
634
|
+
"className": {
|
|
635
|
+
"type": "string",
|
|
636
|
+
"optional": true,
|
|
637
|
+
"description": "Additional CSS classes"
|
|
638
|
+
}
|
|
639
|
+
},
|
|
640
|
+
"examples": [
|
|
641
|
+
"<ClipboardText text=\"0c239dd2\" />",
|
|
642
|
+
"<ClipboardText text=\"abc123\" />",
|
|
643
|
+
"<ClipboardText text=\"sk_live_51H8...\" />",
|
|
644
|
+
"<ClipboardText text=\"https://example.com/very/long/url/path\" />"
|
|
645
|
+
],
|
|
646
|
+
"colors": [
|
|
647
|
+
"bg-kumo-base",
|
|
648
|
+
"border-kumo-line"
|
|
649
|
+
],
|
|
650
|
+
"styling": {
|
|
651
|
+
"baseTokens": [
|
|
652
|
+
"bg-kumo-base",
|
|
653
|
+
"text-kumo-default",
|
|
654
|
+
"ring-kumo-line",
|
|
655
|
+
"border-kumo-fill"
|
|
656
|
+
],
|
|
657
|
+
"states": {
|
|
658
|
+
"input": [
|
|
659
|
+
"bg-kumo-control",
|
|
660
|
+
"text-kumo-default",
|
|
661
|
+
"ring-kumo-line"
|
|
662
|
+
],
|
|
663
|
+
"text": [
|
|
664
|
+
"bg-kumo-base",
|
|
665
|
+
"font-mono"
|
|
666
|
+
],
|
|
667
|
+
"button": [
|
|
668
|
+
"border-kumo-fill"
|
|
669
|
+
]
|
|
670
|
+
},
|
|
671
|
+
"inputStyles": {
|
|
672
|
+
"base": "bg-kumo-control text-kumo-default ring ring-kumo-line",
|
|
673
|
+
"sizes": {
|
|
674
|
+
"xs": "h-5 gap-1 rounded-sm px-1.5 text-xs",
|
|
675
|
+
"sm": "h-6.5 gap-1 rounded-md px-2 text-xs",
|
|
676
|
+
"base": "h-9 gap-1.5 rounded-lg px-3 text-base",
|
|
677
|
+
"lg": "h-10 gap-2 rounded-lg px-4 text-base"
|
|
678
|
+
}
|
|
679
|
+
},
|
|
680
|
+
"sizeVariants": {
|
|
681
|
+
"sm": {
|
|
682
|
+
"height": 26,
|
|
683
|
+
"classes": "text-xs",
|
|
684
|
+
"buttonSize": "sm",
|
|
685
|
+
"dimensions": {
|
|
686
|
+
"paddingX": 8,
|
|
687
|
+
"gap": 1,
|
|
688
|
+
"borderRadius": 6,
|
|
689
|
+
"fontSize": 12
|
|
690
|
+
}
|
|
691
|
+
},
|
|
692
|
+
"base": {
|
|
693
|
+
"height": 36,
|
|
694
|
+
"classes": "text-sm",
|
|
695
|
+
"buttonSize": "base",
|
|
696
|
+
"dimensions": {
|
|
697
|
+
"paddingX": 12,
|
|
698
|
+
"gap": 6,
|
|
699
|
+
"borderRadius": 8,
|
|
700
|
+
"fontSize": 14
|
|
701
|
+
}
|
|
702
|
+
},
|
|
703
|
+
"lg": {
|
|
704
|
+
"height": 40,
|
|
705
|
+
"classes": "text-sm",
|
|
706
|
+
"buttonSize": "lg",
|
|
707
|
+
"dimensions": {
|
|
708
|
+
"paddingX": 16,
|
|
709
|
+
"gap": 8,
|
|
710
|
+
"borderRadius": 8,
|
|
711
|
+
"fontSize": 14
|
|
712
|
+
}
|
|
713
|
+
}
|
|
714
|
+
},
|
|
715
|
+
"icons": [
|
|
716
|
+
{
|
|
717
|
+
"name": "ph-clipboard",
|
|
718
|
+
"state": "default",
|
|
719
|
+
"size": 16
|
|
720
|
+
},
|
|
721
|
+
{
|
|
722
|
+
"name": "ph-check",
|
|
723
|
+
"state": "copied",
|
|
724
|
+
"size": 16
|
|
725
|
+
}
|
|
726
|
+
]
|
|
727
|
+
}
|
|
728
|
+
},
|
|
729
|
+
"Code": {
|
|
730
|
+
"name": "Code",
|
|
731
|
+
"type": "component",
|
|
732
|
+
"description": "Code component",
|
|
733
|
+
"importPath": "@cloudflare/kumo",
|
|
734
|
+
"category": "Display",
|
|
735
|
+
"props": {
|
|
736
|
+
"lang": {
|
|
737
|
+
"type": "enum",
|
|
738
|
+
"optional": true,
|
|
739
|
+
"values": [
|
|
740
|
+
"ts",
|
|
741
|
+
"tsx",
|
|
742
|
+
"jsonc",
|
|
743
|
+
"bash",
|
|
744
|
+
"css"
|
|
745
|
+
],
|
|
746
|
+
"descriptions": {
|
|
747
|
+
"ts": "TypeScript code",
|
|
748
|
+
"tsx": "TypeScript JSX code",
|
|
749
|
+
"jsonc": "JSON with comments",
|
|
750
|
+
"bash": "Shell/Bash commands",
|
|
751
|
+
"css": "CSS styles"
|
|
752
|
+
},
|
|
753
|
+
"default": "ts"
|
|
754
|
+
},
|
|
755
|
+
"code": {
|
|
756
|
+
"type": "string",
|
|
757
|
+
"required": true,
|
|
758
|
+
"description": "The code content to display"
|
|
759
|
+
},
|
|
760
|
+
"values": {
|
|
761
|
+
"type": "Record<string, { value: string; highlight?: boolean }>",
|
|
762
|
+
"optional": true,
|
|
763
|
+
"description": "Template values for interpolation"
|
|
764
|
+
},
|
|
765
|
+
"className": {
|
|
766
|
+
"type": "string",
|
|
767
|
+
"optional": true,
|
|
768
|
+
"description": "Additional CSS classes"
|
|
769
|
+
}
|
|
770
|
+
},
|
|
771
|
+
"examples": [
|
|
772
|
+
"<CodeBlock\n lang=\"tsx\"\n code={`const greeting = \"Hello, World!\";\nconsole.log(greeting);`}\n />",
|
|
773
|
+
"<CodeBlock\n lang=\"tsx\"\n code={`interface User {\n id: string;\n name: string;\n email: string;\n}\n\nconst user: User = {\n id: \"1\",\n name: \"John Doe\",\n email: \"john@example.com\"\n};`}\n />",
|
|
774
|
+
"<CodeBlock\n lang=\"bash\"\n code={`npm install @cloudflare/kumo\npnpm add @cloudflare/kumo`}\n />",
|
|
775
|
+
"<CodeBlock\n lang=\"jsonc\"\n code={`{\n \"name\": \"kumo\",\n \"version\": \"1.0.0\",\n \"dependencies\": {\n \"react\": \"^19.0.0\"\n }\n}`}\n />",
|
|
776
|
+
"<Code\n lang=\"bash\"\n code=\"export API_KEY={{apiKey}}\"\n values={{\n apiKey: { value: \"sk_live_123\", highlight: true },\n }}\n />"
|
|
777
|
+
],
|
|
778
|
+
"colors": [
|
|
779
|
+
"bg-kumo-base",
|
|
780
|
+
"border-kumo-fill",
|
|
781
|
+
"text-kumo-strong"
|
|
782
|
+
],
|
|
783
|
+
"subComponents": {
|
|
784
|
+
"Block": {
|
|
785
|
+
"name": "Block",
|
|
786
|
+
"description": "Block sub-component",
|
|
787
|
+
"props": {
|
|
788
|
+
"code": {
|
|
789
|
+
"type": "string",
|
|
790
|
+
"required": true
|
|
791
|
+
},
|
|
792
|
+
"lang": {
|
|
793
|
+
"type": "CodeLang",
|
|
794
|
+
"optional": true
|
|
795
|
+
}
|
|
796
|
+
}
|
|
797
|
+
}
|
|
798
|
+
},
|
|
799
|
+
"styling": {
|
|
800
|
+
"baseTokens": [
|
|
801
|
+
"text-kumo-strong"
|
|
802
|
+
],
|
|
803
|
+
"typography": {
|
|
804
|
+
"fontFamily": "font-mono",
|
|
805
|
+
"fontSize": "text-sm",
|
|
806
|
+
"lineHeight": "leading-[20px]"
|
|
807
|
+
},
|
|
808
|
+
"dimensions": {
|
|
809
|
+
"margin": "m-0",
|
|
810
|
+
"padding": "p-0",
|
|
811
|
+
"width": "w-auto"
|
|
812
|
+
},
|
|
813
|
+
"appearance": {
|
|
814
|
+
"borderRadius": "rounded-none",
|
|
815
|
+
"border": "border-none",
|
|
816
|
+
"background": "bg-transparent"
|
|
817
|
+
}
|
|
818
|
+
}
|
|
819
|
+
},
|
|
820
|
+
"Collapsible": {
|
|
821
|
+
"name": "Collapsible",
|
|
822
|
+
"type": "component",
|
|
823
|
+
"description": "Collapsible component for showing/hiding content. Features: - Animated chevron indicator (rotates 180° when open) - Accessible with aria-expanded and aria-controls - Content panel with left border accent",
|
|
824
|
+
"importPath": "@cloudflare/kumo",
|
|
825
|
+
"category": "Display",
|
|
826
|
+
"props": {
|
|
827
|
+
"children": {
|
|
828
|
+
"type": "ReactNode",
|
|
829
|
+
"optional": true
|
|
830
|
+
},
|
|
831
|
+
"label": {
|
|
832
|
+
"type": "string",
|
|
833
|
+
"required": true,
|
|
834
|
+
"description": "Text label displayed in the trigger button"
|
|
835
|
+
},
|
|
836
|
+
"open": {
|
|
837
|
+
"type": "boolean",
|
|
838
|
+
"optional": true,
|
|
839
|
+
"description": "Whether the collapsible content is visible"
|
|
840
|
+
},
|
|
841
|
+
"className": {
|
|
842
|
+
"type": "string",
|
|
843
|
+
"optional": true,
|
|
844
|
+
"description": "Additional CSS classes for the content panel"
|
|
845
|
+
},
|
|
846
|
+
"onOpenChange": {
|
|
847
|
+
"type": "(open: boolean) => void",
|
|
848
|
+
"description": "Callback when collapsed state changes"
|
|
849
|
+
}
|
|
850
|
+
},
|
|
851
|
+
"examples": [
|
|
852
|
+
"<div className=\"w-full\">\n <Collapsible label=\"What is Kumo?\" open={isOpen} onOpenChange={setIsOpen}>\n Kumo is Cloudflare's new design system.\n </Collapsible>\n </div>",
|
|
853
|
+
"<div className=\"w-full\">\n <Collapsible label=\"What is Kumo?\" open={isOpen} onOpenChange={setIsOpen}>\n Kumo is Cloudflare's new design system.\n </Collapsible>\n </div>",
|
|
854
|
+
"<div className=\"w-full space-y-2\">\n <Collapsible label=\"What is Kumo?\" open={open1} onOpenChange={setOpen1}>\n Kumo is Cloudflare's new design system.\n </Collapsible>\n <Collapsible\n label=\"How do I use it?\"\n open={open2}\n onOpenChange={setOpen2}\n >\n Install the components and import them into your project.\n </Collapsible>\n <Collapsible\n label=\"Is it open source?\"\n open={open3}\n onOpenChange={setOpen3}\n >\n Check the repository for license information.\n </Collapsible>\n </div>"
|
|
855
|
+
],
|
|
856
|
+
"colors": [
|
|
857
|
+
"border-kumo-fill",
|
|
858
|
+
"text-kumo-link"
|
|
859
|
+
]
|
|
860
|
+
},
|
|
861
|
+
"Combobox": {
|
|
862
|
+
"name": "Combobox",
|
|
863
|
+
"type": "component",
|
|
864
|
+
"description": "Combobox component",
|
|
865
|
+
"importPath": "@cloudflare/kumo",
|
|
866
|
+
"category": "Input",
|
|
867
|
+
"props": {
|
|
868
|
+
"inputSide": {
|
|
869
|
+
"type": "enum",
|
|
870
|
+
"optional": true,
|
|
871
|
+
"values": [
|
|
872
|
+
"right",
|
|
873
|
+
"top"
|
|
874
|
+
],
|
|
875
|
+
"descriptions": {
|
|
876
|
+
"right": "Input positioned inline to the right of chips",
|
|
877
|
+
"top": "Input positioned above chips"
|
|
878
|
+
},
|
|
879
|
+
"default": "right"
|
|
880
|
+
},
|
|
881
|
+
"items": {
|
|
882
|
+
"type": "T[]",
|
|
883
|
+
"required": true,
|
|
884
|
+
"description": "Array of items to display in the dropdown"
|
|
885
|
+
},
|
|
886
|
+
"value": {
|
|
887
|
+
"type": "T | T[]",
|
|
888
|
+
"optional": true,
|
|
889
|
+
"description": "Currently selected value(s)"
|
|
890
|
+
},
|
|
891
|
+
"children": {
|
|
892
|
+
"type": "ReactNode",
|
|
893
|
+
"optional": true,
|
|
894
|
+
"description": "Combobox content (trigger, content, items)"
|
|
895
|
+
},
|
|
896
|
+
"className": {
|
|
897
|
+
"type": "string",
|
|
898
|
+
"optional": true,
|
|
899
|
+
"description": "Additional CSS classes"
|
|
900
|
+
},
|
|
901
|
+
"label": {
|
|
902
|
+
"type": "ReactNode",
|
|
903
|
+
"optional": true,
|
|
904
|
+
"description": "Label content for the combobox (enables Field wrapper) - can be a string or any React node"
|
|
905
|
+
},
|
|
906
|
+
"required": {
|
|
907
|
+
"type": "boolean",
|
|
908
|
+
"optional": true,
|
|
909
|
+
"description": "Whether the combobox is required"
|
|
910
|
+
},
|
|
911
|
+
"labelTooltip": {
|
|
912
|
+
"type": "ReactNode",
|
|
913
|
+
"optional": true,
|
|
914
|
+
"description": "Tooltip content to display next to the label via an info icon"
|
|
915
|
+
},
|
|
916
|
+
"description": {
|
|
917
|
+
"type": "ReactNode",
|
|
918
|
+
"optional": true,
|
|
919
|
+
"description": "Helper text displayed below the combobox"
|
|
920
|
+
},
|
|
921
|
+
"error": {
|
|
922
|
+
"type": "string | object",
|
|
923
|
+
"optional": true,
|
|
924
|
+
"description": "Error message or validation error object"
|
|
925
|
+
},
|
|
926
|
+
"onValueChange": {
|
|
927
|
+
"type": "(value: T | T[]) => void",
|
|
928
|
+
"description": "Callback when selection changes"
|
|
929
|
+
},
|
|
930
|
+
"multiple": {
|
|
931
|
+
"type": "boolean",
|
|
932
|
+
"description": "Allow multiple selections"
|
|
933
|
+
},
|
|
934
|
+
"isItemEqualToValue": {
|
|
935
|
+
"type": "(item: T, value: T) => boolean",
|
|
936
|
+
"description": "Custom equality function for comparing items"
|
|
937
|
+
}
|
|
938
|
+
},
|
|
939
|
+
"examples": [
|
|
940
|
+
"<Combobox\n value={value}\n onValueChange={(v) => setValue(v as string | null)}\n items={fruits}\n >\n <Combobox.TriggerInput placeholder=\"Please select\" />\n <Combobox.Content>\n <Combobox.Empty />\n <Combobox.List>\n {(item: string) => (\n <Combobox.Item key={item} value={item}>\n {item}\n </Combobox.Item>\n )}\n </Combobox.List>\n </Combobox.Content>\n </Combobox>",
|
|
941
|
+
"<Combobox\n value={value}\n onValueChange={(v) => setValue(v as Language)}\n items={languages}\n >\n <Combobox.TriggerValue className=\"w-[200px]\" />\n <Combobox.Content>\n <Combobox.Input placeholder=\"Search languages\" />\n <Combobox.Empty />\n <Combobox.List>\n {(item: Language) => (\n <Combobox.Item key={item.value} value={item}>\n {item.emoji} {item.label}\n </Combobox.Item>\n )}\n </Combobox.List>\n </Combobox.Content>\n </Combobox>",
|
|
942
|
+
"<Combobox\n value={value}\n onValueChange={(v) => setValue(v as ServerLocation | null)}\n items={servers}\n >\n <Combobox.TriggerInput\n className=\"w-[200px]\"\n placeholder=\"Select server\"\n />\n <Combobox.Content>\n <Combobox.Empty />\n <Combobox.List>\n {(group: ServerLocationGroup) => (\n <Combobox.Group key={group.value} items={group.items}>\n <Combobox.GroupLabel>{group.value}</Combobox.GroupLabel>\n <Combobox.Collection>\n {(item: ServerLocation) => (\n <Combobox.Item key={item.value} value={item}>\n {item.label}\n </Combobox.Item>\n )}\n </Combobox.Collection>\n </Combobox.Group>\n )}\n </Combobox.List>\n </Combobox.Content>\n </Combobox>",
|
|
943
|
+
"<div className=\"flex gap-2\">\n <Combobox\n value={value}\n onValueChange={setValue}\n items={bots}\n isItemEqualToValue={(bot: BotItem, selected: BotItem) =>\n bot.value === selected.value\n }\n multiple\n >\n <Combobox.TriggerMultipleWithInput\n className=\"w-[400px]\"\n placeholder=\"Select bots\"\n renderItem={(selected: BotItem) => (\n <Combobox.Chip key={selected.value}>{selected.label}</Combobox.Chip>\n )}\n inputSide=\"right\"\n />\n <Combobox.Content className=\"max-h-[200px] min-w-auto overflow-y-auto\">\n <Combobox.Empty />\n <Combobox.List>\n {(item: BotItem) => (\n <Combobox.Item key={item.value} value={item}>\n <div className=\"flex gap-2\">\n <Text>{item.label}</Text>\n <Text variant=\"secondary\">{item.author}</Text>\n </div>\n </Combobox.Item>\n )}\n </Combobox.List>\n </Combobox.Content>\n </Combobox>\n <Button variant=\"primary\">Submit</Button>\n </div>",
|
|
944
|
+
"<div className=\"w-80\">\n <Combobox\n items={databases}\n value={value}\n onValueChange={setValue}\n label=\"Database\"\n description=\"Select your preferred database\"\n >\n <Combobox.TriggerInput placeholder=\"Select database\" />\n <Combobox.Content>\n <Combobox.Empty />\n <Combobox.List>\n {(item: DatabaseItem) => (\n <Combobox.Item key={item.value} value={item}>\n {item.label}\n </Combobox.Item>\n )}\n </Combobox.List>\n </Combobox.Content>\n </Combobox>\n </div>",
|
|
945
|
+
"<div className=\"w-80\">\n <Combobox\n items={databases}\n value={value}\n onValueChange={setValue}\n label=\"Database\"\n error={{ message: \"Please select a database\", match: true }}\n >\n <Combobox.TriggerInput placeholder=\"Select database\" />\n <Combobox.Content>\n <Combobox.Empty />\n <Combobox.List>\n {(item: DatabaseItem) => (\n <Combobox.Item key={item.value} value={item}>\n {item.label}\n </Combobox.Item>\n )}\n </Combobox.List>\n </Combobox.Content>\n </Combobox>\n </div>"
|
|
946
|
+
],
|
|
947
|
+
"colors": [
|
|
948
|
+
"bg-kumo-control",
|
|
949
|
+
"bg-kumo-fill-hover",
|
|
950
|
+
"bg-kumo-overlay",
|
|
951
|
+
"fill-kumo-ring",
|
|
952
|
+
"ring-kumo-line",
|
|
953
|
+
"text-kumo-default",
|
|
954
|
+
"text-kumo-subtle"
|
|
955
|
+
],
|
|
956
|
+
"subComponents": {
|
|
957
|
+
"Content": {
|
|
958
|
+
"name": "Content",
|
|
959
|
+
"description": "Content sub-component",
|
|
960
|
+
"props": {
|
|
961
|
+
"className": {
|
|
962
|
+
"type": "string",
|
|
963
|
+
"optional": true
|
|
964
|
+
},
|
|
965
|
+
"align": {
|
|
966
|
+
"type": "ComboboxBase.Positioner.Props[\"align\"]",
|
|
967
|
+
"optional": true
|
|
968
|
+
},
|
|
969
|
+
"alignOffset": {
|
|
970
|
+
"type": "ComboboxBase.Positioner.Props[\"alignOffset\"]",
|
|
971
|
+
"optional": true
|
|
972
|
+
},
|
|
973
|
+
"side": {
|
|
974
|
+
"type": "ComboboxBase.Positioner.Props[\"side\"]",
|
|
975
|
+
"optional": true
|
|
976
|
+
},
|
|
977
|
+
"sideOffset": {
|
|
978
|
+
"type": "ComboboxBase.Positioner.Props[\"sideOffset\"]",
|
|
979
|
+
"optional": true
|
|
980
|
+
}
|
|
981
|
+
}
|
|
982
|
+
},
|
|
983
|
+
"TriggerValue": {
|
|
984
|
+
"name": "TriggerValue",
|
|
985
|
+
"description": "TriggerValue sub-component",
|
|
986
|
+
"props": {}
|
|
987
|
+
},
|
|
988
|
+
"TriggerInput": {
|
|
989
|
+
"name": "TriggerInput",
|
|
990
|
+
"description": "TriggerInput sub-component",
|
|
991
|
+
"props": {}
|
|
992
|
+
},
|
|
993
|
+
"TriggerMultipleWithInput": {
|
|
994
|
+
"name": "TriggerMultipleWithInput",
|
|
995
|
+
"description": "TriggerMultipleWithInput sub-component",
|
|
996
|
+
"props": {}
|
|
997
|
+
},
|
|
998
|
+
"Chip": {
|
|
999
|
+
"name": "Chip",
|
|
1000
|
+
"description": "Chip sub-component",
|
|
1001
|
+
"props": {}
|
|
1002
|
+
},
|
|
1003
|
+
"Item": {
|
|
1004
|
+
"name": "Item",
|
|
1005
|
+
"description": "Item sub-component",
|
|
1006
|
+
"props": {}
|
|
1007
|
+
},
|
|
1008
|
+
"Input": {
|
|
1009
|
+
"name": "Input",
|
|
1010
|
+
"description": "Input sub-component",
|
|
1011
|
+
"props": {}
|
|
1012
|
+
},
|
|
1013
|
+
"Empty": {
|
|
1014
|
+
"name": "Empty",
|
|
1015
|
+
"description": "Empty sub-component",
|
|
1016
|
+
"props": {}
|
|
1017
|
+
},
|
|
1018
|
+
"GroupLabel": {
|
|
1019
|
+
"name": "GroupLabel",
|
|
1020
|
+
"description": "GroupLabel sub-component",
|
|
1021
|
+
"props": {}
|
|
1022
|
+
},
|
|
1023
|
+
"Group": {
|
|
1024
|
+
"name": "Group",
|
|
1025
|
+
"description": "Group sub-component",
|
|
1026
|
+
"props": {}
|
|
1027
|
+
},
|
|
1028
|
+
"List": {
|
|
1029
|
+
"name": "List",
|
|
1030
|
+
"description": "A container for combobox items. Supports render prop for custom item rendering.",
|
|
1031
|
+
"props": {
|
|
1032
|
+
"children": {
|
|
1033
|
+
"type": "ReactNode | ((item: T, index: number) => ReactNode)",
|
|
1034
|
+
"description": "Items to render, or a function that receives each item and returns a node"
|
|
1035
|
+
}
|
|
1036
|
+
},
|
|
1037
|
+
"isPassThrough": true,
|
|
1038
|
+
"baseComponent": "ComboboxBase.List",
|
|
1039
|
+
"usageExamples": [
|
|
1040
|
+
"<Combobox.List>\n {(item) => <Combobox.Item value={item}>{item.label}</Combobox.Item>}\n</Combobox.List>"
|
|
1041
|
+
],
|
|
1042
|
+
"renderElement": "<div>"
|
|
1043
|
+
},
|
|
1044
|
+
"Collection": {
|
|
1045
|
+
"name": "Collection",
|
|
1046
|
+
"description": "Renders filtered list items. Use when you need more control over item rendering.",
|
|
1047
|
+
"props": {
|
|
1048
|
+
"children": {
|
|
1049
|
+
"type": "(item: T, index: number) => ReactNode",
|
|
1050
|
+
"required": true,
|
|
1051
|
+
"description": "Function that receives each filtered item and returns a node"
|
|
1052
|
+
}
|
|
1053
|
+
},
|
|
1054
|
+
"isPassThrough": true,
|
|
1055
|
+
"baseComponent": "ComboboxBase.Collection",
|
|
1056
|
+
"usageExamples": [
|
|
1057
|
+
"<Combobox.Collection>\n {(item, index) => (\n <Combobox.Item key={index} value={item}>\n {item.label}\n </Combobox.Item>\n )}\n</Combobox.Collection>"
|
|
1058
|
+
]
|
|
1059
|
+
}
|
|
1060
|
+
}
|
|
1061
|
+
},
|
|
1062
|
+
"CommandPalette": {
|
|
1063
|
+
"name": "CommandPalette",
|
|
1064
|
+
"type": "component",
|
|
1065
|
+
"description": "CommandPalette component",
|
|
1066
|
+
"importPath": "@cloudflare/kumo",
|
|
1067
|
+
"category": "Navigation",
|
|
1068
|
+
"props": {
|
|
1069
|
+
"open": {
|
|
1070
|
+
"type": "boolean",
|
|
1071
|
+
"required": true,
|
|
1072
|
+
"description": "Whether the dialog is open"
|
|
1073
|
+
},
|
|
1074
|
+
"children": {
|
|
1075
|
+
"type": "ReactNode",
|
|
1076
|
+
"optional": true,
|
|
1077
|
+
"description": "Child content - typically one or more Panel components"
|
|
1078
|
+
}
|
|
1079
|
+
},
|
|
1080
|
+
"examples": [
|
|
1081
|
+
"<div className=\"flex flex-col items-start gap-4\">\n <Button onClick={() => setOpen(true)}>Open Command Palette</Button>\n {selectedItem && (\n <p className=\"text-sm text-kumo-subtle\">\n Last selected:{\" \"}\n <span className=\"text-kumo-default\">{selectedItem}</span>\n </p>\n )}\n\n <CommandPalette.Root\n open={open}\n onOpenChange={setOpen}\n items={sampleGroups}\n value={search}\n onValueChange={setSearch}\n itemToStringValue={(group) => group.label}\n onSelect={(item, { newTab }) => {\n console.log(\"Selected:\", item.title, newTab ? \"(new tab)\" : \"\");\n handleSelect(item);\n }}\n getSelectableItems={getSelectableItems}\n >\n <CommandPalette.Input placeholder=\"Type a command or search...\" />\n <CommandPalette.List>\n <CommandPalette.Results>\n {(group: CommandGroup) => (\n <CommandPalette.Group key={group.id}>\n <CommandPalette.GroupLabel>\n {group.label}\n </CommandPalette.GroupLabel>\n <CommandPalette.Items>\n {(item: CommandItem) => (\n <CommandPalette.Item\n key={item.id}\n value={item}\n onClick={() => handleSelect(item)}\n >\n <span className=\"flex items-center gap-3\">\n {item.icon && (\n <span className=\"text-kumo-subtle\">{item.icon}</span>\n )}\n <span>{item.title}</span>\n </span>\n </CommandPalette.Item>\n )}\n </CommandPalette.Items>\n </CommandPalette.Group>\n )}\n </CommandPalette.Results>\n <CommandPalette.Empty>No commands found</CommandPalette.Empty>\n </CommandPalette.List>\n <CommandPalette.Footer>\n <span className=\"flex items-center gap-2\">\n <kbd className=\"rounded border border-kumo-line bg-kumo-base px-1.5 py-0.5 text-[10px]\">\n ↑↓\n </kbd>\n <span>Navigate</span>\n </span>\n <span className=\"flex items-center gap-2\">\n <kbd className=\"rounded border border-kumo-line bg-kumo-base px-1.5 py-0.5 text-[10px]\">\n ↵\n </kbd>\n <span>Select</span>\n </span>\n </CommandPalette.Footer>\n </CommandPalette.Root>\n </div>",
|
|
1082
|
+
"<div>\n <Button onClick={() => setOpen(true)}>Open Simple Palette</Button>\n\n <CommandPalette.Root\n open={open}\n onOpenChange={setOpen}\n items={simpleItems}\n value={search}\n onValueChange={setSearch}\n itemToStringValue={(item) => item.title}\n onSelect={(item) => {\n console.log(\"Selected:\", item.title);\n setOpen(false);\n }}\n getSelectableItems={(items) => items}\n >\n <CommandPalette.Input placeholder=\"Search actions...\" />\n <CommandPalette.List>\n <CommandPalette.Results>\n {(item: SimpleItem) => (\n <CommandPalette.Item\n key={item.id}\n value={item}\n onClick={() => {\n console.log(\"Clicked:\", item.title);\n setOpen(false);\n }}\n >\n {item.title}\n </CommandPalette.Item>\n )}\n </CommandPalette.Results>\n <CommandPalette.Empty>No actions found</CommandPalette.Empty>\n </CommandPalette.List>\n </CommandPalette.Root>\n </div>",
|
|
1083
|
+
"<div>\n <Button onClick={handleOpen}>Open with Loading</Button>\n\n <CommandPalette.Root\n open={open}\n onOpenChange={setOpen}\n items={loading ? [] : sampleGroups}\n value={search}\n onValueChange={setSearch}\n itemToStringValue={(group) => group.label}\n getSelectableItems={getSelectableItems}\n >\n <CommandPalette.Input placeholder=\"Search...\" />\n <CommandPalette.List>\n {loading ? (\n <CommandPalette.Loading />\n ) : (\n <>\n <CommandPalette.Results>\n {(group: CommandGroup) => (\n <CommandPalette.Group key={group.id}>\n <CommandPalette.GroupLabel>\n {group.label}\n </CommandPalette.GroupLabel>\n <CommandPalette.Items>\n {(item: CommandItem) => (\n <CommandPalette.Item\n key={item.id}\n value={item}\n onClick={() => setOpen(false)}\n >\n <span className=\"flex items-center gap-3\">\n {item.icon && (\n <span className=\"text-kumo-subtle\">\n {item.icon}\n </span>\n )}\n <span>{item.title}</span>\n </span>\n </CommandPalette.Item>\n )}\n </CommandPalette.Items>\n </CommandPalette.Group>\n )}\n </CommandPalette.Results>\n <CommandPalette.Empty>No results found</CommandPalette.Empty>\n </>\n )}\n </CommandPalette.List>\n </CommandPalette.Root>\n </div>",
|
|
1084
|
+
"<div>\n <Button onClick={() => setOpen(true)}>Open with ResultItem</Button>\n\n <CommandPalette.Root\n open={open}\n onOpenChange={setOpen}\n items={searchResults}\n value={search}\n onValueChange={setSearch}\n itemToStringValue={(item) => item.title}\n getSelectableItems={(items) => items}\n >\n <CommandPalette.Input placeholder=\"Search documentation...\" />\n <CommandPalette.List>\n <CommandPalette.Results>\n {(item: SearchResult) => (\n <CommandPalette.ResultItem\n key={item.id}\n value={item}\n title={item.title}\n breadcrumbs={item.breadcrumbs}\n icon={item.icon}\n onClick={() => {\n console.log(\"Navigate to:\", item.title);\n setOpen(false);\n }}\n />\n )}\n </CommandPalette.Results>\n <CommandPalette.Empty>No pages found</CommandPalette.Empty>\n </CommandPalette.List>\n <CommandPalette.Footer>\n <span className=\"flex items-center gap-2\">\n <kbd className=\"rounded border border-kumo-line bg-kumo-base px-1.5 py-0.5 text-[10px]\">\n ↑↓\n </kbd>\n <span>Navigate</span>\n </span>\n <span className=\"flex items-center gap-2\">\n <kbd className=\"rounded border border-kumo-line bg-kumo-base px-1.5 py-0.5 text-[10px]\">\n ⌘↵\n </kbd>\n <span>Open in new tab</span>\n </span>\n </CommandPalette.Footer>\n </CommandPalette.Root>\n </div>"
|
|
1085
|
+
],
|
|
1086
|
+
"colors": [
|
|
1087
|
+
"bg-kumo-base",
|
|
1088
|
+
"bg-kumo-elevated",
|
|
1089
|
+
"bg-kumo-overlay",
|
|
1090
|
+
"bg-kumo-warning",
|
|
1091
|
+
"ring-kumo-line",
|
|
1092
|
+
"text-kumo-default",
|
|
1093
|
+
"text-kumo-strong",
|
|
1094
|
+
"text-kumo-subtle"
|
|
1095
|
+
]
|
|
1096
|
+
},
|
|
1097
|
+
"DateRangePicker": {
|
|
1098
|
+
"name": "DateRangePicker",
|
|
1099
|
+
"type": "component",
|
|
1100
|
+
"description": "DateRangePicker component",
|
|
1101
|
+
"importPath": "@cloudflare/kumo",
|
|
1102
|
+
"category": "Input",
|
|
1103
|
+
"props": {
|
|
1104
|
+
"size": {
|
|
1105
|
+
"type": "enum",
|
|
1106
|
+
"optional": true,
|
|
1107
|
+
"values": [
|
|
1108
|
+
"sm",
|
|
1109
|
+
"base",
|
|
1110
|
+
"lg"
|
|
1111
|
+
],
|
|
1112
|
+
"descriptions": {
|
|
1113
|
+
"sm": "Compact calendar for tight spaces",
|
|
1114
|
+
"base": "Default calendar size",
|
|
1115
|
+
"lg": "Large calendar for prominent date selection"
|
|
1116
|
+
},
|
|
1117
|
+
"classes": {
|
|
1118
|
+
"sm": "p-3 gap-2",
|
|
1119
|
+
"base": "p-4 gap-2.5",
|
|
1120
|
+
"lg": "p-5 gap-3"
|
|
1121
|
+
},
|
|
1122
|
+
"default": "base"
|
|
1123
|
+
},
|
|
1124
|
+
"variant": {
|
|
1125
|
+
"type": "enum",
|
|
1126
|
+
"optional": true,
|
|
1127
|
+
"values": [
|
|
1128
|
+
"default",
|
|
1129
|
+
"subtle"
|
|
1130
|
+
],
|
|
1131
|
+
"descriptions": {
|
|
1132
|
+
"default": "Default calendar appearance",
|
|
1133
|
+
"subtle": "Subtle calendar with minimal background"
|
|
1134
|
+
},
|
|
1135
|
+
"classes": {
|
|
1136
|
+
"default": "bg-kumo-overlay",
|
|
1137
|
+
"subtle": "bg-kumo-base"
|
|
1138
|
+
},
|
|
1139
|
+
"default": "default"
|
|
1140
|
+
},
|
|
1141
|
+
"timezone": {
|
|
1142
|
+
"type": "string",
|
|
1143
|
+
"optional": true,
|
|
1144
|
+
"description": "Display timezone (display only)"
|
|
1145
|
+
},
|
|
1146
|
+
"className": {
|
|
1147
|
+
"type": "string",
|
|
1148
|
+
"optional": true,
|
|
1149
|
+
"description": "Additional CSS classes"
|
|
1150
|
+
},
|
|
1151
|
+
"onStartDateChange": {
|
|
1152
|
+
"type": "(date: Date | null) => void",
|
|
1153
|
+
"description": "Callback when start date changes"
|
|
1154
|
+
},
|
|
1155
|
+
"onEndDateChange": {
|
|
1156
|
+
"type": "(date: Date | null) => void",
|
|
1157
|
+
"description": "Callback when end date changes"
|
|
1158
|
+
}
|
|
1159
|
+
},
|
|
1160
|
+
"examples": [
|
|
1161
|
+
"<div className=\"flex flex-col gap-4\">\n <DateRangePicker\n onStartDateChange={setStartDate}\n onEndDateChange={setEndDate}\n />\n <div className=\"text-sm text-kumo-subtle\">\n {startDate && endDate ? (\n <span>\n Selected: {startDate.toLocaleDateString()} -{\" \"}\n {endDate.toLocaleDateString()}\n </span>\n ) : startDate ? (\n <span>Start: {startDate.toLocaleDateString()} (select end date)</span>\n ) : (\n <span>Select a date range</span>\n )}\n </div>\n </div>",
|
|
1162
|
+
"<div className=\"flex flex-col gap-8\">\n <div>\n <p className=\"mb-2 text-sm font-medium text-kumo-default\">Small</p>\n <DateRangePicker\n size=\"sm\"\n onStartDateChange={() => {}}\n onEndDateChange={() => {}}\n />\n </div>\n <div>\n <p className=\"mb-2 text-sm font-medium text-kumo-default\">\n Base (default)\n </p>\n <DateRangePicker\n size=\"base\"\n onStartDateChange={() => {}}\n onEndDateChange={() => {}}\n />\n </div>\n <div>\n <p className=\"mb-2 text-sm font-medium text-kumo-default\">Large</p>\n <DateRangePicker\n size=\"lg\"\n onStartDateChange={() => {}}\n onEndDateChange={() => {}}\n />\n </div>\n </div>",
|
|
1163
|
+
"<div className=\"flex flex-col gap-8\">\n <div>\n <p className=\"mb-2 text-sm font-medium text-kumo-default\">\n Default variant\n </p>\n <DateRangePicker\n variant=\"default\"\n onStartDateChange={() => {}}\n onEndDateChange={() => {}}\n />\n </div>\n <div>\n <p className=\"mb-2 text-sm font-medium text-kumo-default\">\n Subtle variant\n </p>\n <DateRangePicker\n variant=\"subtle\"\n onStartDateChange={() => {}}\n onEndDateChange={() => {}}\n />\n </div>\n </div>",
|
|
1164
|
+
"<DateRangePicker\n timezone=\"London, UK (GMT+0)\"\n onStartDateChange={() => {}}\n onEndDateChange={() => {}}\n />",
|
|
1165
|
+
"<div className=\"flex flex-col gap-4\">\n <DateRangePicker\n onStartDateChange={setStartDate}\n onEndDateChange={setEndDate}\n />\n <div className=\"rounded-lg bg-kumo-control p-3 text-sm text-kumo-default\">\n <strong>Selection:</strong> {formatDateRange()}\n </div>\n </div>"
|
|
1166
|
+
],
|
|
1167
|
+
"colors": [
|
|
1168
|
+
"bg-kumo-base",
|
|
1169
|
+
"bg-kumo-contrast",
|
|
1170
|
+
"bg-kumo-fill",
|
|
1171
|
+
"bg-kumo-interact",
|
|
1172
|
+
"bg-kumo-overlay",
|
|
1173
|
+
"text-kumo-default",
|
|
1174
|
+
"text-kumo-inverse",
|
|
1175
|
+
"text-kumo-strong",
|
|
1176
|
+
"text-kumo-subtle"
|
|
1177
|
+
],
|
|
1178
|
+
"styling": {
|
|
1179
|
+
"sizeVariants": {
|
|
1180
|
+
"sm": {
|
|
1181
|
+
"height": 0,
|
|
1182
|
+
"classes": "p-3 gap-2",
|
|
1183
|
+
"dimensions": {
|
|
1184
|
+
"calendarWidth": 168,
|
|
1185
|
+
"cellHeight": 22,
|
|
1186
|
+
"cellWidth": 24,
|
|
1187
|
+
"textSize": 12,
|
|
1188
|
+
"iconSize": 14,
|
|
1189
|
+
"padding": 12,
|
|
1190
|
+
"gap": 8
|
|
1191
|
+
}
|
|
1192
|
+
},
|
|
1193
|
+
"base": {
|
|
1194
|
+
"height": 0,
|
|
1195
|
+
"classes": "p-4 gap-2.5",
|
|
1196
|
+
"dimensions": {
|
|
1197
|
+
"calendarWidth": 196,
|
|
1198
|
+
"cellHeight": 26,
|
|
1199
|
+
"cellWidth": 28,
|
|
1200
|
+
"textSize": 14,
|
|
1201
|
+
"iconSize": 16,
|
|
1202
|
+
"padding": 16,
|
|
1203
|
+
"gap": 10
|
|
1204
|
+
}
|
|
1205
|
+
},
|
|
1206
|
+
"lg": {
|
|
1207
|
+
"height": 0,
|
|
1208
|
+
"classes": "p-5 gap-3",
|
|
1209
|
+
"dimensions": {
|
|
1210
|
+
"calendarWidth": 252,
|
|
1211
|
+
"cellHeight": 32,
|
|
1212
|
+
"cellWidth": 36,
|
|
1213
|
+
"textSize": 16,
|
|
1214
|
+
"iconSize": 18,
|
|
1215
|
+
"padding": 20,
|
|
1216
|
+
"gap": 12
|
|
1217
|
+
}
|
|
1218
|
+
}
|
|
1219
|
+
}
|
|
1220
|
+
}
|
|
1221
|
+
},
|
|
1222
|
+
"Dialog": {
|
|
1223
|
+
"name": "Dialog",
|
|
1224
|
+
"type": "component",
|
|
1225
|
+
"description": "Dialog component",
|
|
1226
|
+
"importPath": "@cloudflare/kumo",
|
|
1227
|
+
"category": "Overlay",
|
|
1228
|
+
"props": {
|
|
1229
|
+
"className": {
|
|
1230
|
+
"type": "string",
|
|
1231
|
+
"optional": true
|
|
1232
|
+
},
|
|
1233
|
+
"children": {
|
|
1234
|
+
"type": "ReactNode",
|
|
1235
|
+
"optional": true
|
|
1236
|
+
},
|
|
1237
|
+
"size": {
|
|
1238
|
+
"type": "enum",
|
|
1239
|
+
"optional": true,
|
|
1240
|
+
"values": [
|
|
1241
|
+
"base",
|
|
1242
|
+
"sm",
|
|
1243
|
+
"lg",
|
|
1244
|
+
"xl"
|
|
1245
|
+
],
|
|
1246
|
+
"descriptions": {
|
|
1247
|
+
"base": "Default dialog width",
|
|
1248
|
+
"sm": "Small dialog for simple confirmations",
|
|
1249
|
+
"lg": "Large dialog for complex content",
|
|
1250
|
+
"xl": "Extra large dialog for detailed views"
|
|
1251
|
+
},
|
|
1252
|
+
"classes": {
|
|
1253
|
+
"base": "min-w-96",
|
|
1254
|
+
"sm": "min-w-72",
|
|
1255
|
+
"lg": "min-w-[32rem]",
|
|
1256
|
+
"xl": "min-w-[48rem]"
|
|
1257
|
+
},
|
|
1258
|
+
"default": "base"
|
|
1259
|
+
}
|
|
1260
|
+
},
|
|
1261
|
+
"examples": [
|
|
1262
|
+
"<Dialog.Root>\n <Dialog.Trigger render={(p) => <Button {...p}>Click me</Button>} />\n <Dialog className=\"p-8\">\n <div className=\"mb-4 flex items-start justify-between gap-4\">\n <Dialog.Title className=\"text-2xl font-semibold\">\n Modal Title\n </Dialog.Title>\n <Dialog.Close\n aria-label=\"Close\"\n render={(props) => (\n <Button\n {...props}\n variant=\"secondary\"\n shape=\"square\"\n icon={<X />}\n />\n )}\n />\n </div>\n <Dialog.Description className=\"text-kumo-subtle\">\n Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do\n eiusmod tempor incididunt ut labore et dolore magna aliqua.\n </Dialog.Description>\n </Dialog>\n </Dialog.Root>",
|
|
1263
|
+
"<Dialog.Root>\n <Dialog.Trigger render={(p) => <Button {...p}>Delete</Button>} />\n <Dialog className=\"p-8\">\n <div className=\"mb-4 flex items-start justify-between gap-4\">\n <Dialog.Title className=\"text-2xl font-semibold\">\n Modal Title\n </Dialog.Title>\n <Dialog.Close\n aria-label=\"Close\"\n render={(props) => (\n <Button\n {...props}\n variant=\"secondary\"\n shape=\"square\"\n icon={<X />}\n />\n )}\n />\n </div>\n <Dialog.Description className=\"text-kumo-subtle\">\n Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do\n eiusmod tempor incididunt ut labore et dolore magna aliqua.\n </Dialog.Description>\n <div className=\"mt-8 flex justify-end gap-2\">\n <Button variant=\"secondary\">Cancel</Button>\n <Dialog.Close\n render={(props) => (\n <Button variant=\"destructive\" {...props}>\n Delete\n </Button>\n )}\n />\n </div>\n </Dialog>\n </Dialog.Root>"
|
|
1264
|
+
],
|
|
1265
|
+
"colors": [
|
|
1266
|
+
"bg-kumo-base",
|
|
1267
|
+
"bg-kumo-overlay",
|
|
1268
|
+
"text-kumo-default"
|
|
1269
|
+
],
|
|
1270
|
+
"subComponents": {
|
|
1271
|
+
"Root": {
|
|
1272
|
+
"name": "Root",
|
|
1273
|
+
"description": "Controls the open state of the dialog. Doesn't render its own HTML element.",
|
|
1274
|
+
"props": {
|
|
1275
|
+
"open": {
|
|
1276
|
+
"type": "boolean",
|
|
1277
|
+
"description": "Whether the dialog is currently open (controlled mode)"
|
|
1278
|
+
},
|
|
1279
|
+
"defaultOpen": {
|
|
1280
|
+
"type": "boolean",
|
|
1281
|
+
"description": "Whether the dialog is initially open (uncontrolled mode)",
|
|
1282
|
+
"default": "false"
|
|
1283
|
+
},
|
|
1284
|
+
"onOpenChange": {
|
|
1285
|
+
"type": "(open: boolean, event: Event) => void",
|
|
1286
|
+
"description": "Callback fired when the dialog opens or closes"
|
|
1287
|
+
},
|
|
1288
|
+
"modal": {
|
|
1289
|
+
"type": "boolean | 'trap-focus'",
|
|
1290
|
+
"description": "Whether the dialog is modal. When true, focus is trapped and page scroll is locked",
|
|
1291
|
+
"default": "true"
|
|
1292
|
+
},
|
|
1293
|
+
"dismissible": {
|
|
1294
|
+
"type": "boolean",
|
|
1295
|
+
"description": "Whether clicking outside closes the dialog",
|
|
1296
|
+
"default": "true"
|
|
1297
|
+
}
|
|
1298
|
+
},
|
|
1299
|
+
"isPassThrough": true,
|
|
1300
|
+
"baseComponent": "DialogBase.Root",
|
|
1301
|
+
"usageExamples": [
|
|
1302
|
+
"<Dialog.Root open={isOpen} onOpenChange={setIsOpen}>",
|
|
1303
|
+
"<Dialog.Root defaultOpen={false}>"
|
|
1304
|
+
]
|
|
1305
|
+
},
|
|
1306
|
+
"Trigger": {
|
|
1307
|
+
"name": "Trigger",
|
|
1308
|
+
"description": "A button that opens the dialog when clicked.",
|
|
1309
|
+
"props": {
|
|
1310
|
+
"render": {
|
|
1311
|
+
"type": "ReactElement | ((props, state) => ReactElement)",
|
|
1312
|
+
"description": "Custom element to render instead of the default button"
|
|
1313
|
+
},
|
|
1314
|
+
"disabled": {
|
|
1315
|
+
"type": "boolean",
|
|
1316
|
+
"description": "Whether the trigger is disabled"
|
|
1317
|
+
}
|
|
1318
|
+
},
|
|
1319
|
+
"isPassThrough": true,
|
|
1320
|
+
"baseComponent": "DialogBase.Trigger",
|
|
1321
|
+
"usageExamples": [
|
|
1322
|
+
"<Dialog.Trigger render={<Button>Open</Button>} />",
|
|
1323
|
+
"<Dialog.Trigger>Open Dialog</Dialog.Trigger>"
|
|
1324
|
+
],
|
|
1325
|
+
"renderElement": "<button>"
|
|
1326
|
+
},
|
|
1327
|
+
"Title": {
|
|
1328
|
+
"name": "Title",
|
|
1329
|
+
"description": "A heading that labels the dialog for accessibility.",
|
|
1330
|
+
"props": {
|
|
1331
|
+
"render": {
|
|
1332
|
+
"type": "ReactElement | ((props, state) => ReactElement)",
|
|
1333
|
+
"description": "Custom element to render instead of the default h2"
|
|
1334
|
+
}
|
|
1335
|
+
},
|
|
1336
|
+
"isPassThrough": true,
|
|
1337
|
+
"baseComponent": "DialogBase.Title",
|
|
1338
|
+
"usageExamples": [
|
|
1339
|
+
"<Dialog.Title>Confirm Action</Dialog.Title>",
|
|
1340
|
+
"<Dialog.Title render={<h3 />}>Custom Heading</Dialog.Title>"
|
|
1341
|
+
],
|
|
1342
|
+
"renderElement": "<h2>"
|
|
1343
|
+
},
|
|
1344
|
+
"Description": {
|
|
1345
|
+
"name": "Description",
|
|
1346
|
+
"description": "A paragraph providing additional context about the dialog.",
|
|
1347
|
+
"props": {
|
|
1348
|
+
"render": {
|
|
1349
|
+
"type": "ReactElement | ((props, state) => ReactElement)",
|
|
1350
|
+
"description": "Custom element to render instead of the default p"
|
|
1351
|
+
}
|
|
1352
|
+
},
|
|
1353
|
+
"isPassThrough": true,
|
|
1354
|
+
"baseComponent": "DialogBase.Description",
|
|
1355
|
+
"usageExamples": [
|
|
1356
|
+
"<Dialog.Description>Are you sure you want to proceed?</Dialog.Description>"
|
|
1357
|
+
],
|
|
1358
|
+
"renderElement": "<p>"
|
|
1359
|
+
},
|
|
1360
|
+
"Close": {
|
|
1361
|
+
"name": "Close",
|
|
1362
|
+
"description": "A button that closes the dialog when clicked.",
|
|
1363
|
+
"props": {
|
|
1364
|
+
"render": {
|
|
1365
|
+
"type": "ReactElement | ((props, state) => ReactElement)",
|
|
1366
|
+
"description": "Custom element to render instead of the default button"
|
|
1367
|
+
},
|
|
1368
|
+
"disabled": {
|
|
1369
|
+
"type": "boolean",
|
|
1370
|
+
"description": "Whether the close button is disabled"
|
|
1371
|
+
}
|
|
1372
|
+
},
|
|
1373
|
+
"isPassThrough": true,
|
|
1374
|
+
"baseComponent": "DialogBase.Close",
|
|
1375
|
+
"usageExamples": [
|
|
1376
|
+
"<Dialog.Close render={<Button>Cancel</Button>} />",
|
|
1377
|
+
"<Dialog.Close>×</Dialog.Close>"
|
|
1378
|
+
],
|
|
1379
|
+
"renderElement": "<button>"
|
|
1380
|
+
}
|
|
1381
|
+
},
|
|
1382
|
+
"styling": {
|
|
1383
|
+
"dimensions": {
|
|
1384
|
+
"sm": {
|
|
1385
|
+
"width": 350,
|
|
1386
|
+
"titleSize": 20,
|
|
1387
|
+
"descSize": 16,
|
|
1388
|
+
"padding": 16,
|
|
1389
|
+
"gap": 8,
|
|
1390
|
+
"buttonSize": "sm"
|
|
1391
|
+
},
|
|
1392
|
+
"base": {
|
|
1393
|
+
"width": 384,
|
|
1394
|
+
"titleSize": 20,
|
|
1395
|
+
"descSize": 16,
|
|
1396
|
+
"padding": 24,
|
|
1397
|
+
"gap": 16,
|
|
1398
|
+
"buttonSize": "base"
|
|
1399
|
+
},
|
|
1400
|
+
"lg": {
|
|
1401
|
+
"width": 512,
|
|
1402
|
+
"titleSize": 20,
|
|
1403
|
+
"descSize": 16,
|
|
1404
|
+
"padding": 24,
|
|
1405
|
+
"gap": 16,
|
|
1406
|
+
"buttonSize": "base"
|
|
1407
|
+
},
|
|
1408
|
+
"xl": {
|
|
1409
|
+
"width": 768,
|
|
1410
|
+
"titleSize": 20,
|
|
1411
|
+
"descSize": 16,
|
|
1412
|
+
"padding": 24,
|
|
1413
|
+
"gap": 16,
|
|
1414
|
+
"buttonSize": "base"
|
|
1415
|
+
}
|
|
1416
|
+
},
|
|
1417
|
+
"baseTokens": {
|
|
1418
|
+
"background": "color-surface",
|
|
1419
|
+
"text": "text-color-surface",
|
|
1420
|
+
"borderRadius": 12,
|
|
1421
|
+
"shadow": "shadow-m"
|
|
1422
|
+
},
|
|
1423
|
+
"backdrop": {
|
|
1424
|
+
"background": "color-surface-secondary",
|
|
1425
|
+
"opacity": 0.8
|
|
1426
|
+
},
|
|
1427
|
+
"header": {
|
|
1428
|
+
"title": {
|
|
1429
|
+
"fontWeight": 600,
|
|
1430
|
+
"color": "text-color-surface"
|
|
1431
|
+
},
|
|
1432
|
+
"closeIcon": {
|
|
1433
|
+
"name": "ph-x",
|
|
1434
|
+
"size": 20,
|
|
1435
|
+
"color": "text-color-muted"
|
|
1436
|
+
}
|
|
1437
|
+
},
|
|
1438
|
+
"description": {
|
|
1439
|
+
"fontWeight": 400,
|
|
1440
|
+
"color": "text-color-muted"
|
|
1441
|
+
},
|
|
1442
|
+
"buttons": {
|
|
1443
|
+
"primary": {
|
|
1444
|
+
"background": "color-primary",
|
|
1445
|
+
"text": "white"
|
|
1446
|
+
},
|
|
1447
|
+
"secondary": {
|
|
1448
|
+
"ring": "color-border",
|
|
1449
|
+
"text": "text-color-surface"
|
|
1450
|
+
}
|
|
1451
|
+
}
|
|
1452
|
+
}
|
|
1453
|
+
},
|
|
1454
|
+
"DropdownMenu": {
|
|
1455
|
+
"name": "DropdownMenu",
|
|
1456
|
+
"type": "component",
|
|
1457
|
+
"description": "DropdownMenu component",
|
|
1458
|
+
"importPath": "@cloudflare/kumo",
|
|
1459
|
+
"category": "Overlay",
|
|
1460
|
+
"props": {
|
|
1461
|
+
"variant": {
|
|
1462
|
+
"type": "enum",
|
|
1463
|
+
"optional": true,
|
|
1464
|
+
"values": [
|
|
1465
|
+
"default",
|
|
1466
|
+
"danger"
|
|
1467
|
+
],
|
|
1468
|
+
"descriptions": {
|
|
1469
|
+
"default": "Default dropdown item appearance",
|
|
1470
|
+
"danger": "Destructive action item"
|
|
1471
|
+
},
|
|
1472
|
+
"classes": {
|
|
1473
|
+
"danger": "text-kumo-danger data-highlighted:bg-kumo-danger/5 data-highlighted:text-kumo-danger"
|
|
1474
|
+
},
|
|
1475
|
+
"default": "default"
|
|
1476
|
+
}
|
|
1477
|
+
},
|
|
1478
|
+
"examples": [],
|
|
1479
|
+
"colors": [
|
|
1480
|
+
"bg-kumo-control",
|
|
1481
|
+
"bg-kumo-danger",
|
|
1482
|
+
"bg-kumo-line",
|
|
1483
|
+
"bg-kumo-overlay",
|
|
1484
|
+
"bg-kumo-tint",
|
|
1485
|
+
"ring-kumo-line",
|
|
1486
|
+
"text-kumo-danger",
|
|
1487
|
+
"text-kumo-default"
|
|
1488
|
+
],
|
|
1489
|
+
"subComponents": {
|
|
1490
|
+
"Trigger": {
|
|
1491
|
+
"name": "Trigger",
|
|
1492
|
+
"description": "Trigger sub-component",
|
|
1493
|
+
"props": {}
|
|
1494
|
+
},
|
|
1495
|
+
"Portal": {
|
|
1496
|
+
"name": "Portal",
|
|
1497
|
+
"description": "Portal sub-component (wraps DropdownMenuPrimitive)",
|
|
1498
|
+
"props": {},
|
|
1499
|
+
"isPassThrough": true,
|
|
1500
|
+
"baseComponent": "DropdownMenuPrimitive.Portal"
|
|
1501
|
+
},
|
|
1502
|
+
"Sub": {
|
|
1503
|
+
"name": "Sub",
|
|
1504
|
+
"description": "Sub sub-component (wraps DropdownMenuPrimitive)",
|
|
1505
|
+
"props": {},
|
|
1506
|
+
"isPassThrough": true,
|
|
1507
|
+
"baseComponent": "DropdownMenuPrimitive.SubmenuRoot"
|
|
1508
|
+
},
|
|
1509
|
+
"SubTrigger": {
|
|
1510
|
+
"name": "SubTrigger",
|
|
1511
|
+
"description": "SubTrigger sub-component",
|
|
1512
|
+
"props": {}
|
|
1513
|
+
},
|
|
1514
|
+
"SubContent": {
|
|
1515
|
+
"name": "SubContent",
|
|
1516
|
+
"description": "SubContent sub-component",
|
|
1517
|
+
"props": {}
|
|
1518
|
+
},
|
|
1519
|
+
"Content": {
|
|
1520
|
+
"name": "Content",
|
|
1521
|
+
"description": "Content sub-component",
|
|
1522
|
+
"props": {}
|
|
1523
|
+
},
|
|
1524
|
+
"Item": {
|
|
1525
|
+
"name": "Item",
|
|
1526
|
+
"description": "Item sub-component",
|
|
1527
|
+
"props": {}
|
|
1528
|
+
},
|
|
1529
|
+
"CheckboxItem": {
|
|
1530
|
+
"name": "CheckboxItem",
|
|
1531
|
+
"description": "CheckboxItem sub-component",
|
|
1532
|
+
"props": {}
|
|
1533
|
+
},
|
|
1534
|
+
"RadioGroup": {
|
|
1535
|
+
"name": "RadioGroup",
|
|
1536
|
+
"description": "RadioGroup sub-component (wraps DropdownMenuPrimitive)",
|
|
1537
|
+
"props": {},
|
|
1538
|
+
"isPassThrough": true,
|
|
1539
|
+
"baseComponent": "DropdownMenuPrimitive.RadioGroup"
|
|
1540
|
+
},
|
|
1541
|
+
"RadioItem": {
|
|
1542
|
+
"name": "RadioItem",
|
|
1543
|
+
"description": "RadioItem sub-component",
|
|
1544
|
+
"props": {}
|
|
1545
|
+
},
|
|
1546
|
+
"RadioItemIndicator": {
|
|
1547
|
+
"name": "RadioItemIndicator",
|
|
1548
|
+
"description": "RadioItemIndicator sub-component",
|
|
1549
|
+
"props": {}
|
|
1550
|
+
},
|
|
1551
|
+
"Label": {
|
|
1552
|
+
"name": "Label",
|
|
1553
|
+
"description": "Label sub-component",
|
|
1554
|
+
"props": {}
|
|
1555
|
+
},
|
|
1556
|
+
"Separator": {
|
|
1557
|
+
"name": "Separator",
|
|
1558
|
+
"description": "Separator sub-component",
|
|
1559
|
+
"props": {}
|
|
1560
|
+
},
|
|
1561
|
+
"Shortcut": {
|
|
1562
|
+
"name": "Shortcut",
|
|
1563
|
+
"description": "Shortcut sub-component",
|
|
1564
|
+
"props": {}
|
|
1565
|
+
},
|
|
1566
|
+
"Group": {
|
|
1567
|
+
"name": "Group",
|
|
1568
|
+
"description": "Group sub-component (wraps DropdownMenuPrimitive)",
|
|
1569
|
+
"props": {},
|
|
1570
|
+
"isPassThrough": true,
|
|
1571
|
+
"baseComponent": "DropdownMenuPrimitive.Group"
|
|
1572
|
+
}
|
|
1573
|
+
}
|
|
1574
|
+
},
|
|
1575
|
+
"Empty": {
|
|
1576
|
+
"name": "Empty",
|
|
1577
|
+
"type": "component",
|
|
1578
|
+
"description": "Empty component",
|
|
1579
|
+
"importPath": "@cloudflare/kumo",
|
|
1580
|
+
"category": "Display",
|
|
1581
|
+
"props": {
|
|
1582
|
+
"size": {
|
|
1583
|
+
"type": "enum",
|
|
1584
|
+
"optional": true,
|
|
1585
|
+
"values": [
|
|
1586
|
+
"sm",
|
|
1587
|
+
"base",
|
|
1588
|
+
"lg"
|
|
1589
|
+
],
|
|
1590
|
+
"descriptions": {
|
|
1591
|
+
"sm": "Compact empty state for smaller containers",
|
|
1592
|
+
"base": "Default empty state size",
|
|
1593
|
+
"lg": "Large empty state for prominent placement"
|
|
1594
|
+
},
|
|
1595
|
+
"classes": {
|
|
1596
|
+
"sm": "px-6 py-8 gap-4",
|
|
1597
|
+
"base": "px-10 py-16 gap-6",
|
|
1598
|
+
"lg": "px-12 py-20 gap-8"
|
|
1599
|
+
},
|
|
1600
|
+
"default": "base"
|
|
1601
|
+
},
|
|
1602
|
+
"icon": {
|
|
1603
|
+
"type": "ReactNode",
|
|
1604
|
+
"optional": true
|
|
1605
|
+
},
|
|
1606
|
+
"title": {
|
|
1607
|
+
"type": "string",
|
|
1608
|
+
"required": true
|
|
1609
|
+
},
|
|
1610
|
+
"description": {
|
|
1611
|
+
"type": "string",
|
|
1612
|
+
"optional": true
|
|
1613
|
+
},
|
|
1614
|
+
"commandLine": {
|
|
1615
|
+
"type": "string",
|
|
1616
|
+
"optional": true
|
|
1617
|
+
},
|
|
1618
|
+
"contents": {
|
|
1619
|
+
"type": "ReactNode",
|
|
1620
|
+
"optional": true
|
|
1621
|
+
},
|
|
1622
|
+
"className": {
|
|
1623
|
+
"type": "string",
|
|
1624
|
+
"optional": true
|
|
1625
|
+
}
|
|
1626
|
+
},
|
|
1627
|
+
"examples": [
|
|
1628
|
+
"<Empty\n icon={<PackageIcon size={48} />}\n title=\"No packages found\"\n description=\"Get started by installing your first package.\"\n commandLine=\"npm install @cloudflare/kumo\"\n contents={\n <div className=\"flex items-center gap-2\">\n <Button icon={<CodeIcon />}>See examples</Button>\n <Button icon={<GlobeIcon />} variant=\"primary\">\n View documentation\n </Button>\n </div>\n }\n />",
|
|
1629
|
+
"<div className=\"flex flex-col gap-8\">\n <div>\n <p className=\"mb-2 text-sm text-kumo-subtle\">Small</p>\n <Empty\n size=\"sm\"\n icon={<Database size={32} className=\"text-kumo-inactive\" />}\n title=\"No data available\"\n description=\"There is no data to display.\"\n />\n </div>\n <div>\n <p className=\"mb-2 text-sm text-kumo-subtle\">Base</p>\n <Empty\n size=\"base\"\n icon={<Database size={48} className=\"text-kumo-inactive\" />}\n title=\"No data available\"\n description=\"There is no data to display.\"\n />\n </div>\n <div>\n <p className=\"mb-2 text-sm text-kumo-subtle\">Large</p>\n <Empty\n size=\"lg\"\n icon={<Database size={64} className=\"text-kumo-inactive\" />}\n title=\"No data available\"\n description=\"There is no data to display.\"\n />\n </div>\n </div>",
|
|
1630
|
+
"<Empty\n icon={<FolderOpen size={48} className=\"text-kumo-inactive\" />}\n title=\"No projects found\"\n description=\"Get started by creating your first project using the command below.\"\n commandLine=\"npm create kumo-project\"\n />",
|
|
1631
|
+
"<Empty\n icon={<CloudSlash size={48} className=\"text-kumo-inactive\" />}\n title=\"No connection\"\n description=\"Unable to connect to the server. Please check your connection and try again.\"\n contents={\n <div className=\"flex gap-2\">\n <Button variant=\"primary\">Retry</Button>\n <Button variant=\"secondary\">Go Back</Button>\n </div>\n }\n />",
|
|
1632
|
+
"<Empty title=\"Nothing here\" />",
|
|
1633
|
+
"<Empty\n title=\"No results found\"\n description=\"Try adjusting your search or filter to find what you're looking for.\"\n />"
|
|
1634
|
+
],
|
|
1635
|
+
"colors": [
|
|
1636
|
+
"bg-kumo-control",
|
|
1637
|
+
"bg-kumo-overlay",
|
|
1638
|
+
"border-kumo-fill",
|
|
1639
|
+
"border-kumo-interact",
|
|
1640
|
+
"text-kumo-brand",
|
|
1641
|
+
"text-kumo-default",
|
|
1642
|
+
"text-kumo-inactive",
|
|
1643
|
+
"text-kumo-strong",
|
|
1644
|
+
"text-kumo-success"
|
|
1645
|
+
]
|
|
1646
|
+
},
|
|
1647
|
+
"Field": {
|
|
1648
|
+
"name": "Field",
|
|
1649
|
+
"type": "component",
|
|
1650
|
+
"description": "Field component",
|
|
1651
|
+
"importPath": "@cloudflare/kumo",
|
|
1652
|
+
"category": "Input",
|
|
1653
|
+
"props": {
|
|
1654
|
+
"controlFirst": {
|
|
1655
|
+
"type": "boolean",
|
|
1656
|
+
"optional": true,
|
|
1657
|
+
"description": "When true, places the control (checkbox/switch) before the label visually. When false (default), places the label before the control. Used to support different layout patterns (e.g., iOS-style toggles on the right)."
|
|
1658
|
+
},
|
|
1659
|
+
"children": {
|
|
1660
|
+
"type": "ReactNode",
|
|
1661
|
+
"optional": true
|
|
1662
|
+
},
|
|
1663
|
+
"label": {
|
|
1664
|
+
"type": "ReactNode",
|
|
1665
|
+
"optional": true,
|
|
1666
|
+
"description": "The label content - can be a string or any React node"
|
|
1667
|
+
},
|
|
1668
|
+
"required": {
|
|
1669
|
+
"type": "boolean",
|
|
1670
|
+
"optional": true,
|
|
1671
|
+
"description": "When explicitly false, shows gray \"(optional)\" text after the label. When true or undefined, no indicator is shown."
|
|
1672
|
+
},
|
|
1673
|
+
"labelTooltip": {
|
|
1674
|
+
"type": "ReactNode",
|
|
1675
|
+
"optional": true,
|
|
1676
|
+
"description": "Tooltip content to display next to the label via an info icon"
|
|
1677
|
+
},
|
|
1678
|
+
"error": {
|
|
1679
|
+
"type": "object",
|
|
1680
|
+
"optional": true
|
|
1681
|
+
},
|
|
1682
|
+
"description": {
|
|
1683
|
+
"type": "ReactNode",
|
|
1684
|
+
"optional": true
|
|
1685
|
+
}
|
|
1686
|
+
},
|
|
1687
|
+
"examples": [],
|
|
1688
|
+
"colors": [
|
|
1689
|
+
"text-kumo-danger",
|
|
1690
|
+
"text-kumo-default",
|
|
1691
|
+
"text-kumo-subtle"
|
|
1692
|
+
]
|
|
1693
|
+
},
|
|
1694
|
+
"Grid": {
|
|
1695
|
+
"name": "Grid",
|
|
1696
|
+
"type": "component",
|
|
1697
|
+
"description": "Grid component",
|
|
1698
|
+
"importPath": "@cloudflare/kumo",
|
|
1699
|
+
"category": "Layout",
|
|
1700
|
+
"props": {
|
|
1701
|
+
"children": {
|
|
1702
|
+
"type": "ReactNode",
|
|
1703
|
+
"optional": true,
|
|
1704
|
+
"description": "Child node(s) that can be nested inside component"
|
|
1705
|
+
},
|
|
1706
|
+
"className": {
|
|
1707
|
+
"type": "string",
|
|
1708
|
+
"optional": true,
|
|
1709
|
+
"description": "CSS class names that can be appended to the component"
|
|
1710
|
+
},
|
|
1711
|
+
"id": {
|
|
1712
|
+
"type": "string",
|
|
1713
|
+
"optional": true
|
|
1714
|
+
},
|
|
1715
|
+
"lang": {
|
|
1716
|
+
"type": "string",
|
|
1717
|
+
"optional": true
|
|
1718
|
+
},
|
|
1719
|
+
"title": {
|
|
1720
|
+
"type": "string",
|
|
1721
|
+
"optional": true
|
|
1722
|
+
},
|
|
1723
|
+
"mobileDivider": {
|
|
1724
|
+
"type": "boolean",
|
|
1725
|
+
"optional": true,
|
|
1726
|
+
"description": "Show dividers between grid items on mobile (only works with 4up variant)"
|
|
1727
|
+
},
|
|
1728
|
+
"gap": {
|
|
1729
|
+
"type": "enum",
|
|
1730
|
+
"optional": true,
|
|
1731
|
+
"description": "Gap size between grid items",
|
|
1732
|
+
"values": [
|
|
1733
|
+
"none",
|
|
1734
|
+
"sm",
|
|
1735
|
+
"base",
|
|
1736
|
+
"lg"
|
|
1737
|
+
],
|
|
1738
|
+
"descriptions": {
|
|
1739
|
+
"none": "No gap between grid items",
|
|
1740
|
+
"sm": "Small gap between grid items",
|
|
1741
|
+
"base": "Default responsive gap between grid items",
|
|
1742
|
+
"lg": "Large gap between grid items"
|
|
1743
|
+
},
|
|
1744
|
+
"classes": {
|
|
1745
|
+
"none": "gap-0",
|
|
1746
|
+
"sm": "gap-3",
|
|
1747
|
+
"base": "gap-2 md:gap-6 lg:gap-8",
|
|
1748
|
+
"lg": "gap-8"
|
|
1749
|
+
},
|
|
1750
|
+
"default": "base"
|
|
1751
|
+
},
|
|
1752
|
+
"variant": {
|
|
1753
|
+
"type": "enum",
|
|
1754
|
+
"optional": true,
|
|
1755
|
+
"description": "Stylistic variations of the Grid layout",
|
|
1756
|
+
"values": [
|
|
1757
|
+
"2up",
|
|
1758
|
+
"side-by-side",
|
|
1759
|
+
"2-1",
|
|
1760
|
+
"1-2",
|
|
1761
|
+
"1-3up",
|
|
1762
|
+
"3up",
|
|
1763
|
+
"4up",
|
|
1764
|
+
"6up",
|
|
1765
|
+
"1-2-4up"
|
|
1766
|
+
],
|
|
1767
|
+
"descriptions": {
|
|
1768
|
+
"2up": "Grid items stack on small screens, display side-by-side on medium screens and up",
|
|
1769
|
+
"side-by-side": "Grid items always displayed side-by-side",
|
|
1770
|
+
"2-1": "Two-thirds / one-third split (66%/33%) on medium screens and up",
|
|
1771
|
+
"1-2": "One-third / two-thirds split (33%/66%) on medium screens and up",
|
|
1772
|
+
"1-3up": "Grid items stack on small screens, expand to 3 across on large screens",
|
|
1773
|
+
"3up": "Grid items stack on small screens, 2 across on medium, 3 across on large",
|
|
1774
|
+
"4up": "Grid items stack on small screens, progressively increase columns at larger breakpoints",
|
|
1775
|
+
"6up": "Grid items start at 2 across, expand to 6 across on XL",
|
|
1776
|
+
"1-2-4up": "Grid items stack on small screens, 2 across on medium, 4 across on large"
|
|
1777
|
+
},
|
|
1778
|
+
"classes": {
|
|
1779
|
+
"2up": "grid-cols-1 md:grid-cols-2",
|
|
1780
|
+
"side-by-side": "grid-cols-2",
|
|
1781
|
+
"2-1": "grid-cols-1 md:grid-cols-[2fr_1fr]",
|
|
1782
|
+
"1-2": "grid-cols-1 md:grid-cols-[1fr_2fr]",
|
|
1783
|
+
"1-3up": "grid-cols-1 lg:grid-cols-3",
|
|
1784
|
+
"3up": "grid-cols-1 md:grid-cols-2 lg:grid-cols-3",
|
|
1785
|
+
"4up": "grid-cols-1 md:grid-cols-2 lg:grid-cols-3 xl:grid-cols-4",
|
|
1786
|
+
"6up": "grid-cols-2 md:grid-cols-3 lg:grid-cols-4 xl:grid-cols-6",
|
|
1787
|
+
"1-2-4up": "grid-cols-1 md:grid-cols-2 lg:grid-cols-4"
|
|
1788
|
+
}
|
|
1789
|
+
}
|
|
1790
|
+
},
|
|
1791
|
+
"examples": [
|
|
1792
|
+
"<Grid variant=\"2up\" gap=\"base\">\n <GridItem>\n <Surface className=\"rounded-lg p-4\">\n <Text bold>Item 1</Text>\n <div className=\"mt-1\">\n <Text variant=\"secondary\">First grid item</Text>\n </div>\n </Surface>\n </GridItem>\n <GridItem>\n <Surface className=\"rounded-lg p-4\">\n <Text bold>Item 2</Text>\n <div className=\"mt-1\">\n <Text variant=\"secondary\">Second grid item</Text>\n </div>\n </Surface>\n </GridItem>\n </Grid>",
|
|
1793
|
+
"<div className=\"flex flex-col gap-8\">\n <div>\n <p className=\"mb-2 text-kumo-subtle\">variant=\"2up\"</p>\n <Grid variant=\"2up\" gap=\"sm\">\n <GridItem>\n <Surface className=\"rounded-lg p-4 text-center\">\n <Text>1</Text>\n </Surface>\n </GridItem>\n <GridItem>\n <Surface className=\"rounded-lg p-4 text-center\">\n <Text>2</Text>\n </Surface>\n </GridItem>\n </Grid>\n </div>\n\n <div>\n <p className=\"mb-2 text-kumo-subtle\">variant=\"3up\"</p>\n <Grid variant=\"3up\" gap=\"sm\">\n <GridItem>\n <Surface className=\"rounded-lg p-4 text-center\">\n <Text>1</Text>\n </Surface>\n </GridItem>\n <GridItem>\n <Surface className=\"rounded-lg p-4 text-center\">\n <Text>2</Text>\n </Surface>\n </GridItem>\n <GridItem>\n <Surface className=\"rounded-lg p-4 text-center\">\n <Text>3</Text>\n </Surface>\n </GridItem>\n </Grid>\n </div>\n\n <div>\n <p className=\"mb-2 text-kumo-subtle\">variant=\"4up\"</p>\n <Grid variant=\"4up\" gap=\"sm\">\n <GridItem>\n <Surface className=\"rounded-lg p-4 text-center\">\n <Text>1</Text>\n </Surface>\n </GridItem>\n <GridItem>\n <Surface className=\"rounded-lg p-4 text-center\">\n <Text>2</Text>\n </Surface>\n </GridItem>\n <GridItem>\n <Surface className=\"rounded-lg p-4 text-center\">\n <Text>3</Text>\n </Surface>\n </GridItem>\n <GridItem>\n <Surface className=\"rounded-lg p-4 text-center\">\n <Text>4</Text>\n </Surface>\n </GridItem>\n </Grid>\n </div>\n </div>",
|
|
1794
|
+
"<div className=\"flex flex-col gap-8\">\n <div>\n <p className=\"mb-2 text-kumo-subtle\">variant=\"2-1\" (66% / 33%)</p>\n <Grid variant=\"2-1\" gap=\"sm\">\n <GridItem>\n <Surface className=\"rounded-lg p-4\">\n <Text bold>Main Content</Text>\n <div className=\"mt-1\">\n <Text variant=\"secondary\">Two-thirds width</Text>\n </div>\n </Surface>\n </GridItem>\n <GridItem>\n <Surface className=\"rounded-lg p-4\">\n <Text bold>Sidebar</Text>\n <div className=\"mt-1\">\n <Text variant=\"secondary\">One-third width</Text>\n </div>\n </Surface>\n </GridItem>\n </Grid>\n </div>\n\n <div>\n <p className=\"mb-2 text-kumo-subtle\">variant=\"1-2\" (33% / 66%)</p>\n <Grid variant=\"1-2\" gap=\"sm\">\n <GridItem>\n <Surface className=\"rounded-lg p-4\">\n <Text bold>Sidebar</Text>\n <div className=\"mt-1\">\n <Text variant=\"secondary\">One-third width</Text>\n </div>\n </Surface>\n </GridItem>\n <GridItem>\n <Surface className=\"rounded-lg p-4\">\n <Text bold>Main Content</Text>\n <div className=\"mt-1\">\n <Text variant=\"secondary\">Two-thirds width</Text>\n </div>\n </Surface>\n </GridItem>\n </Grid>\n </div>\n </div>",
|
|
1795
|
+
"<div className=\"flex flex-col gap-8\">\n <div>\n <p className=\"mb-2 text-kumo-subtle\">gap=\"none\"</p>\n <Grid variant=\"side-by-side\" gap=\"none\">\n <GridItem>\n <Surface className=\"rounded-lg p-4 text-center\">\n <Text>1</Text>\n </Surface>\n </GridItem>\n <GridItem>\n <Surface className=\"rounded-lg p-4 text-center\">\n <Text>2</Text>\n </Surface>\n </GridItem>\n </Grid>\n </div>\n\n <div>\n <p className=\"mb-2 text-kumo-subtle\">gap=\"sm\"</p>\n <Grid variant=\"side-by-side\" gap=\"sm\">\n <GridItem>\n <Surface className=\"rounded-lg p-4 text-center\">\n <Text>1</Text>\n </Surface>\n </GridItem>\n <GridItem>\n <Surface className=\"rounded-lg p-4 text-center\">\n <Text>2</Text>\n </Surface>\n </GridItem>\n </Grid>\n </div>\n\n <div>\n <p className=\"mb-2 text-kumo-subtle\">\n gap=\"base\" (default, responsive)\n </p>\n <Grid variant=\"side-by-side\" gap=\"base\">\n <GridItem>\n <Surface className=\"rounded-lg p-4 text-center\">\n <Text>1</Text>\n </Surface>\n </GridItem>\n <GridItem>\n <Surface className=\"rounded-lg p-4 text-center\">\n <Text>2</Text>\n </Surface>\n </GridItem>\n </Grid>\n </div>\n\n <div>\n <p className=\"mb-2 text-kumo-subtle\">gap=\"lg\"</p>\n <Grid variant=\"side-by-side\" gap=\"lg\">\n <GridItem>\n <Surface className=\"rounded-lg p-4 text-center\">\n <Text>1</Text>\n </Surface>\n </GridItem>\n <GridItem>\n <Surface className=\"rounded-lg p-4 text-center\">\n <Text>2</Text>\n </Surface>\n </GridItem>\n </Grid>\n </div>\n </div>",
|
|
1796
|
+
"<Grid variant=\"4up\" gap=\"base\" mobileDivider>\n <GridItem>\n <Surface className=\"rounded-lg p-4\">\n <Text bold>Item 1</Text>\n <div className=\"mt-1\">\n <Text variant=\"secondary\">Has divider on mobile</Text>\n </div>\n </Surface>\n </GridItem>\n <GridItem>\n <Surface className=\"rounded-lg p-4\">\n <Text bold>Item 2</Text>\n <div className=\"mt-1\">\n <Text variant=\"secondary\">Has divider on mobile</Text>\n </div>\n </Surface>\n </GridItem>\n <GridItem>\n <Surface className=\"rounded-lg p-4\">\n <Text bold>Item 3</Text>\n <div className=\"mt-1\">\n <Text variant=\"secondary\">Has divider on mobile</Text>\n </div>\n </Surface>\n </GridItem>\n <GridItem>\n <Surface className=\"rounded-lg p-4\">\n <Text bold>Item 4</Text>\n <div className=\"mt-1\">\n <Text variant=\"secondary\">Has divider on mobile</Text>\n </div>\n </Surface>\n </GridItem>\n </Grid>"
|
|
1797
|
+
],
|
|
1798
|
+
"colors": [
|
|
1799
|
+
"border-kumo-line"
|
|
1800
|
+
]
|
|
1801
|
+
},
|
|
1802
|
+
"Input": {
|
|
1803
|
+
"name": "Input",
|
|
1804
|
+
"type": "component",
|
|
1805
|
+
"description": "Input component",
|
|
1806
|
+
"importPath": "@cloudflare/kumo",
|
|
1807
|
+
"category": "Input",
|
|
1808
|
+
"props": {
|
|
1809
|
+
"label": {
|
|
1810
|
+
"type": "ReactNode",
|
|
1811
|
+
"optional": true,
|
|
1812
|
+
"description": "Label content for the input (enables Field wrapper) - can be a string or any React node"
|
|
1813
|
+
},
|
|
1814
|
+
"labelTooltip": {
|
|
1815
|
+
"type": "ReactNode",
|
|
1816
|
+
"optional": true,
|
|
1817
|
+
"description": "Tooltip content to display next to the label via an info icon"
|
|
1818
|
+
},
|
|
1819
|
+
"description": {
|
|
1820
|
+
"type": "ReactNode",
|
|
1821
|
+
"optional": true,
|
|
1822
|
+
"description": "Helper text displayed below the input"
|
|
1823
|
+
},
|
|
1824
|
+
"error": {
|
|
1825
|
+
"type": "string | object",
|
|
1826
|
+
"optional": true,
|
|
1827
|
+
"description": "Error message or validation error object"
|
|
1828
|
+
},
|
|
1829
|
+
"size": {
|
|
1830
|
+
"type": "enum",
|
|
1831
|
+
"optional": true,
|
|
1832
|
+
"values": [
|
|
1833
|
+
"xs",
|
|
1834
|
+
"sm",
|
|
1835
|
+
"base",
|
|
1836
|
+
"lg"
|
|
1837
|
+
],
|
|
1838
|
+
"descriptions": {
|
|
1839
|
+
"xs": "Extra small input for compact UIs",
|
|
1840
|
+
"sm": "Small input for secondary fields",
|
|
1841
|
+
"base": "Default input size",
|
|
1842
|
+
"lg": "Large input for prominent fields"
|
|
1843
|
+
},
|
|
1844
|
+
"classes": {
|
|
1845
|
+
"xs": "h-5 gap-1 rounded-sm px-1.5 text-xs",
|
|
1846
|
+
"sm": "h-6.5 gap-1 rounded-md px-2 text-xs",
|
|
1847
|
+
"base": "h-9 gap-1.5 rounded-lg px-3 text-base",
|
|
1848
|
+
"lg": "h-10 gap-2 rounded-lg px-4 text-base"
|
|
1849
|
+
},
|
|
1850
|
+
"default": "base"
|
|
1851
|
+
},
|
|
1852
|
+
"variant": {
|
|
1853
|
+
"type": "enum",
|
|
1854
|
+
"optional": true,
|
|
1855
|
+
"values": [
|
|
1856
|
+
"default",
|
|
1857
|
+
"error"
|
|
1858
|
+
],
|
|
1859
|
+
"descriptions": {
|
|
1860
|
+
"default": "Default input appearance",
|
|
1861
|
+
"error": "Error state for validation failures"
|
|
1862
|
+
},
|
|
1863
|
+
"classes": {
|
|
1864
|
+
"default": "focus:ring-kumo-ring",
|
|
1865
|
+
"error": "!ring-kumo-danger focus:ring-kumo-danger"
|
|
1866
|
+
},
|
|
1867
|
+
"stateClasses": {
|
|
1868
|
+
"default": {
|
|
1869
|
+
"focus": "focus:ring-kumo-ring"
|
|
1870
|
+
},
|
|
1871
|
+
"error": {
|
|
1872
|
+
"focus": "focus:ring-kumo-danger"
|
|
1873
|
+
}
|
|
1874
|
+
},
|
|
1875
|
+
"default": "default"
|
|
1876
|
+
}
|
|
1877
|
+
},
|
|
1878
|
+
"examples": [
|
|
1879
|
+
"<Input\n label=\"Email\"\n placeholder=\"you@example.com\"\n description=\"We'll never share your email\"\n />",
|
|
1880
|
+
"<Input\n label=\"Username\"\n placeholder=\"Choose a username\"\n description=\"3-20 characters, alphanumeric only\"\n />",
|
|
1881
|
+
"<Input\n label=\"Email\"\n placeholder=\"you@example.com\"\n value=\"invalid-email\"\n variant=\"error\"\n error=\"Please enter a valid email address\"\n />",
|
|
1882
|
+
"<Input\n label=\"Password\"\n type=\"password\"\n value=\"short\"\n variant=\"error\"\n error={{\n message: \"Password must be at least 8 characters\",\n match: \"tooShort\",\n }}\n minLength={8}\n />",
|
|
1883
|
+
"<div className=\"flex flex-col gap-4\">\n <Input size=\"xs\" label=\"Extra Small\" placeholder=\"Extra small input\" />\n <Input size=\"sm\" label=\"Small\" placeholder=\"Small input\" />\n <Input label=\"Base\" placeholder=\"Base input (default)\" />\n <Input size=\"lg\" label=\"Large\" placeholder=\"Large input\" />\n </div>",
|
|
1884
|
+
"<Input label=\"Disabled field\" placeholder=\"Cannot edit\" disabled />",
|
|
1885
|
+
"<Input placeholder=\"Search...\" aria-label=\"Search products\" />",
|
|
1886
|
+
"<div className=\"flex flex-col gap-4\">\n <Input type=\"email\" label=\"Email\" placeholder=\"you@example.com\" />\n <Input type=\"password\" label=\"Password\" placeholder=\"••••••••\" />\n <Input type=\"number\" label=\"Age\" placeholder=\"18\" />\n <Input type=\"tel\" label=\"Phone\" placeholder=\"+1 (555) 000-0000\" />\n </div>",
|
|
1887
|
+
"<Input\n label=\"Phone Number\"\n required={false}\n placeholder=\"+1 (555) 000-0000\"\n />",
|
|
1888
|
+
"<Input\n label=\"API Key\"\n labelTooltip=\"Find this in your dashboard under Settings > API Keys\"\n placeholder=\"sk_live_...\"\n />",
|
|
1889
|
+
"<Input\n label={\n <span>\n Email for <strong>billing</strong>\n </span>\n }\n required\n placeholder=\"billing@company.com\"\n type=\"email\"\n />"
|
|
1890
|
+
],
|
|
1891
|
+
"colors": [
|
|
1892
|
+
"bg-kumo-control",
|
|
1893
|
+
"ring-kumo-danger",
|
|
1894
|
+
"ring-kumo-line",
|
|
1895
|
+
"ring-kumo-ring",
|
|
1896
|
+
"text-kumo-default",
|
|
1897
|
+
"text-kumo-subtle"
|
|
1898
|
+
],
|
|
1899
|
+
"styling": {
|
|
1900
|
+
"dimensions": {
|
|
1901
|
+
"xs": {
|
|
1902
|
+
"height": 20,
|
|
1903
|
+
"paddingX": 6,
|
|
1904
|
+
"fontSize": 12,
|
|
1905
|
+
"borderRadius": 2,
|
|
1906
|
+
"width": 160
|
|
1907
|
+
},
|
|
1908
|
+
"sm": {
|
|
1909
|
+
"height": 26,
|
|
1910
|
+
"paddingX": 8,
|
|
1911
|
+
"fontSize": 12,
|
|
1912
|
+
"borderRadius": 6,
|
|
1913
|
+
"width": 200
|
|
1914
|
+
},
|
|
1915
|
+
"base": {
|
|
1916
|
+
"height": 36,
|
|
1917
|
+
"paddingX": 12,
|
|
1918
|
+
"fontSize": 16,
|
|
1919
|
+
"borderRadius": 8,
|
|
1920
|
+
"width": 280
|
|
1921
|
+
},
|
|
1922
|
+
"lg": {
|
|
1923
|
+
"height": 40,
|
|
1924
|
+
"paddingX": 16,
|
|
1925
|
+
"fontSize": 16,
|
|
1926
|
+
"borderRadius": 8,
|
|
1927
|
+
"width": 320
|
|
1928
|
+
}
|
|
1929
|
+
},
|
|
1930
|
+
"baseTokens": {
|
|
1931
|
+
"background": "color-secondary",
|
|
1932
|
+
"text": "text-color-surface",
|
|
1933
|
+
"placeholder": "text-color-muted",
|
|
1934
|
+
"ring": "color-border"
|
|
1935
|
+
},
|
|
1936
|
+
"stateTokens": {
|
|
1937
|
+
"focus": {
|
|
1938
|
+
"ring": "color-active"
|
|
1939
|
+
},
|
|
1940
|
+
"error": {
|
|
1941
|
+
"ring": "color-error"
|
|
1942
|
+
},
|
|
1943
|
+
"disabled": {
|
|
1944
|
+
"opacity": 0.5,
|
|
1945
|
+
"text": "text-color-muted"
|
|
1946
|
+
}
|
|
1947
|
+
}
|
|
1948
|
+
}
|
|
1949
|
+
},
|
|
1950
|
+
"Label": {
|
|
1951
|
+
"name": "Label",
|
|
1952
|
+
"type": "component",
|
|
1953
|
+
"description": "Label component for form fields. Provides a standardized way to display labels with optional indicators: - Optional indicator: gray \"(optional)\" text when `showOptional={true}` - Tooltip: info icon with hover tooltip for additional context",
|
|
1954
|
+
"importPath": "@cloudflare/kumo",
|
|
1955
|
+
"category": "Other",
|
|
1956
|
+
"props": {
|
|
1957
|
+
"children": {
|
|
1958
|
+
"type": "ReactNode",
|
|
1959
|
+
"optional": true,
|
|
1960
|
+
"description": "The label content - can be a string or any React node"
|
|
1961
|
+
},
|
|
1962
|
+
"showOptional": {
|
|
1963
|
+
"type": "boolean",
|
|
1964
|
+
"optional": true,
|
|
1965
|
+
"description": "When true (and required is false), shows gray \"(optional)\" text after the label"
|
|
1966
|
+
},
|
|
1967
|
+
"tooltip": {
|
|
1968
|
+
"type": "ReactNode",
|
|
1969
|
+
"optional": true,
|
|
1970
|
+
"description": "Tooltip content to display next to the label via an info icon"
|
|
1971
|
+
},
|
|
1972
|
+
"className": {
|
|
1973
|
+
"type": "string",
|
|
1974
|
+
"optional": true,
|
|
1975
|
+
"description": "Additional CSS classes"
|
|
1976
|
+
},
|
|
1977
|
+
"asContent": {
|
|
1978
|
+
"type": "boolean",
|
|
1979
|
+
"optional": true,
|
|
1980
|
+
"description": "When true, only renders the inline content (indicators, tooltip) without the outer span with font styling. Useful when composed inside another label element that already provides the text styling."
|
|
1981
|
+
}
|
|
1982
|
+
},
|
|
1983
|
+
"examples": [
|
|
1984
|
+
"<div className=\"flex flex-col gap-4\">\n <Label>Default Label</Label>\n <Label showOptional>Optional Label</Label>\n <Label tooltip=\"More information about this field\">\n Label with Tooltip\n </Label>\n </div>",
|
|
1985
|
+
"<Input label=\"Phone Number\" required={false} placeholder=\"+1 555-0000\" />",
|
|
1986
|
+
"<Input\n label=\"API Key\"\n labelTooltip=\"Find this in your dashboard settings under API > Keys\"\n placeholder=\"sk_live_...\"\n />",
|
|
1987
|
+
"<Checkbox\n label={\n <span>\n I agree to the <strong>Terms of Service</strong>\n </span>\n }\n />",
|
|
1988
|
+
"<div className=\"flex max-w-md flex-col gap-4\">\n <Input label=\"Full Name\" placeholder=\"John Doe\" />\n <Input\n label=\"Email\"\n labelTooltip=\"We'll send your receipt here\"\n placeholder=\"john@example.com\"\n type=\"email\"\n />\n <Input label=\"Company\" required={false} placeholder=\"Acme Inc.\" />\n <Select label=\"Country\" hideLabel={false} placeholder=\"Select a country\">\n <Select.Option value=\"us\">United States</Select.Option>\n <Select.Option value=\"uk\">United Kingdom</Select.Option>\n <Select.Option value=\"ca\">Canada</Select.Option>\n </Select>\n </div>",
|
|
1989
|
+
"<div className=\"flex flex-col gap-3\">\n <Label>Default</Label>\n <Label showOptional>Optional</Label>\n <Label tooltip=\"Important field\">With Tooltip</Label>\n </div>"
|
|
1990
|
+
],
|
|
1991
|
+
"colors": [
|
|
1992
|
+
"text-kumo-default",
|
|
1993
|
+
"text-kumo-strong"
|
|
1994
|
+
]
|
|
1995
|
+
},
|
|
1996
|
+
"LayerCard": {
|
|
1997
|
+
"name": "LayerCard",
|
|
1998
|
+
"type": "component",
|
|
1999
|
+
"description": "LayerCard component",
|
|
2000
|
+
"importPath": "@cloudflare/kumo",
|
|
2001
|
+
"category": "Display",
|
|
2002
|
+
"props": {
|
|
2003
|
+
"children": {
|
|
2004
|
+
"type": "ReactNode",
|
|
2005
|
+
"optional": true
|
|
2006
|
+
},
|
|
2007
|
+
"className": {
|
|
2008
|
+
"type": "string",
|
|
2009
|
+
"optional": true
|
|
2010
|
+
}
|
|
2011
|
+
},
|
|
2012
|
+
"examples": [
|
|
2013
|
+
"<LayerCard>\n <LayerCard.Secondary className=\"flex items-center justify-between\">\n <div>Next Steps</div>\n <Button variant=\"ghost\" size=\"sm\" shape=\"square\">\n <ArrowRightIcon size={16} />\n </Button>\n </LayerCard.Secondary>\n\n <LayerCard.Primary>Get started with Kumo</LayerCard.Primary>\n </LayerCard>",
|
|
2014
|
+
"<LayerCard className=\"w-[250px]\">\n <LayerCard.Secondary>Getting Started</LayerCard.Secondary>\n <LayerCard.Primary>\n <p className=\"text-sm text-kumo-subtle\">\n Quick start guide for new users\n </p>\n </LayerCard.Primary>\n </LayerCard>",
|
|
2015
|
+
"<div className=\"flex gap-4\">\n <LayerCard className=\"w-[200px]\">\n <LayerCard.Secondary>Components</LayerCard.Secondary>\n <LayerCard.Primary>\n <p className=\"text-sm\">Browse all components</p>\n </LayerCard.Primary>\n </LayerCard>\n <LayerCard className=\"w-[200px]\">\n <LayerCard.Secondary>Examples</LayerCard.Secondary>\n <LayerCard.Primary>\n <p className=\"text-sm\">View code examples</p>\n </LayerCard.Primary>\n </LayerCard>\n </div>"
|
|
2016
|
+
],
|
|
2017
|
+
"colors": [
|
|
2018
|
+
"bg-kumo-base",
|
|
2019
|
+
"bg-kumo-elevated",
|
|
2020
|
+
"ring-kumo-fill",
|
|
2021
|
+
"ring-kumo-line",
|
|
2022
|
+
"text-kumo-strong"
|
|
2023
|
+
],
|
|
2024
|
+
"subComponents": {
|
|
2025
|
+
"Primary": {
|
|
2026
|
+
"name": "Primary",
|
|
2027
|
+
"description": "Primary sub-component",
|
|
2028
|
+
"props": {}
|
|
2029
|
+
},
|
|
2030
|
+
"Secondary": {
|
|
2031
|
+
"name": "Secondary",
|
|
2032
|
+
"description": "Secondary sub-component",
|
|
2033
|
+
"props": {}
|
|
2034
|
+
}
|
|
2035
|
+
},
|
|
2036
|
+
"styling": {
|
|
2037
|
+
"container": {
|
|
2038
|
+
"width": 280,
|
|
2039
|
+
"borderRadius": 8
|
|
2040
|
+
},
|
|
2041
|
+
"secondary": {
|
|
2042
|
+
"paddingX": 8,
|
|
2043
|
+
"paddingY": 8,
|
|
2044
|
+
"gap": 8,
|
|
2045
|
+
"fontSize": 16,
|
|
2046
|
+
"fontWeight": 500
|
|
2047
|
+
},
|
|
2048
|
+
"primary": {
|
|
2049
|
+
"paddingX": 16,
|
|
2050
|
+
"paddingY": 16,
|
|
2051
|
+
"paddingRight": 12,
|
|
2052
|
+
"gap": 8,
|
|
2053
|
+
"fontSize": 16,
|
|
2054
|
+
"fontWeight": 400,
|
|
2055
|
+
"borderRadius": 8
|
|
2056
|
+
}
|
|
2057
|
+
}
|
|
2058
|
+
},
|
|
2059
|
+
"Link": {
|
|
2060
|
+
"name": "Link",
|
|
2061
|
+
"type": "component",
|
|
2062
|
+
"description": "Link component",
|
|
2063
|
+
"importPath": "@cloudflare/kumo",
|
|
2064
|
+
"category": "Other",
|
|
2065
|
+
"props": {
|
|
2066
|
+
"variant": {
|
|
2067
|
+
"type": "enum",
|
|
2068
|
+
"optional": true,
|
|
2069
|
+
"values": [
|
|
2070
|
+
"inline",
|
|
2071
|
+
"current",
|
|
2072
|
+
"plain"
|
|
2073
|
+
],
|
|
2074
|
+
"descriptions": {
|
|
2075
|
+
"inline": "Inline text link that flows with content",
|
|
2076
|
+
"current": "Link that inherits color from parent text",
|
|
2077
|
+
"plain": "Link without underline decoration"
|
|
2078
|
+
},
|
|
2079
|
+
"classes": {
|
|
2080
|
+
"inline": "text-primary underline underline-offset-[0.15em] decoration-[0.0625em] link-current transition-colors",
|
|
2081
|
+
"current": "text-current underline underline-offset-[0.15em] decoration-[0.0625em] link-current transition-colors",
|
|
2082
|
+
"plain": "text-primary hover:text-primary/70 transition-colors"
|
|
2083
|
+
},
|
|
2084
|
+
"stateClasses": {
|
|
2085
|
+
"plain": {
|
|
2086
|
+
"hover": "hover:text-primary/70"
|
|
2087
|
+
}
|
|
2088
|
+
},
|
|
2089
|
+
"default": "inline"
|
|
2090
|
+
},
|
|
2091
|
+
"to": {
|
|
2092
|
+
"type": "string",
|
|
2093
|
+
"optional": true
|
|
2094
|
+
},
|
|
2095
|
+
"children": {
|
|
2096
|
+
"type": "ReactNode",
|
|
2097
|
+
"optional": true
|
|
2098
|
+
},
|
|
2099
|
+
"className": {
|
|
2100
|
+
"type": "string",
|
|
2101
|
+
"optional": true
|
|
2102
|
+
},
|
|
2103
|
+
"id": {
|
|
2104
|
+
"type": "string",
|
|
2105
|
+
"optional": true
|
|
2106
|
+
},
|
|
2107
|
+
"lang": {
|
|
2108
|
+
"type": "string",
|
|
2109
|
+
"optional": true
|
|
2110
|
+
},
|
|
2111
|
+
"title": {
|
|
2112
|
+
"type": "string",
|
|
2113
|
+
"optional": true
|
|
2114
|
+
},
|
|
2115
|
+
"download": {
|
|
2116
|
+
"type": "unknown",
|
|
2117
|
+
"optional": true
|
|
2118
|
+
},
|
|
2119
|
+
"href": {
|
|
2120
|
+
"type": "string",
|
|
2121
|
+
"optional": true
|
|
2122
|
+
},
|
|
2123
|
+
"hrefLang": {
|
|
2124
|
+
"type": "string",
|
|
2125
|
+
"optional": true
|
|
2126
|
+
},
|
|
2127
|
+
"media": {
|
|
2128
|
+
"type": "string",
|
|
2129
|
+
"optional": true
|
|
2130
|
+
},
|
|
2131
|
+
"ping": {
|
|
2132
|
+
"type": "string",
|
|
2133
|
+
"optional": true
|
|
2134
|
+
},
|
|
2135
|
+
"target": {
|
|
2136
|
+
"type": "React.HTMLAttributeAnchorTarget",
|
|
2137
|
+
"optional": true
|
|
2138
|
+
},
|
|
2139
|
+
"type": {
|
|
2140
|
+
"type": "string",
|
|
2141
|
+
"optional": true
|
|
2142
|
+
},
|
|
2143
|
+
"referrerPolicy": {
|
|
2144
|
+
"type": "enum",
|
|
2145
|
+
"optional": true,
|
|
2146
|
+
"values": [
|
|
2147
|
+
"",
|
|
2148
|
+
"no-referrer",
|
|
2149
|
+
"no-referrer-when-downgrade",
|
|
2150
|
+
"origin",
|
|
2151
|
+
"origin-when-cross-origin",
|
|
2152
|
+
"same-origin",
|
|
2153
|
+
"strict-origin",
|
|
2154
|
+
"strict-origin-when-cross-origin",
|
|
2155
|
+
"unsafe-url"
|
|
2156
|
+
]
|
|
2157
|
+
},
|
|
2158
|
+
"render": {
|
|
2159
|
+
"type": "ReactNode",
|
|
2160
|
+
"optional": true,
|
|
2161
|
+
"description": "Allows you to replace the component’s HTML element with a different tag, or compose it with another component.\n\nAccepts a `ReactElement` or a function that returns the element to render."
|
|
2162
|
+
}
|
|
2163
|
+
},
|
|
2164
|
+
"examples": [
|
|
2165
|
+
"<div className=\"grid gap-x-6 gap-y-4 text-base md:grid-cols-3\">\n <Link href=\"#\">Default inline link</Link>\n <Link href=\"#\" variant=\"current\">\n Current color link\n </Link>\n <Link href=\"#\" variant=\"plain\">\n Plain inline link\n </Link>\n </div>",
|
|
2166
|
+
"<p className=\"mx-auto max-w-md text-base leading-relaxed text-kumo-default\">\n This is a paragraph with an <Link href=\"#\">inline link</Link> that flows\n naturally with the surrounding text. Links maintain proper underline\n offset for readability.\n </p>",
|
|
2167
|
+
"<Link\n href=\"https://cloudflare.com\"\n target=\"_blank\"\n rel=\"noopener noreferrer\"\n className=\"text-base\"\n >\n Visit Cloudflare <Link.ExternalIcon />\n </Link>",
|
|
2168
|
+
"<p className=\"text-base text-kumo-danger\">\n This error message contains a{\" \"}\n <Link href=\"#\" variant=\"current\">\n link\n </Link>{\" \"}\n that inherits the red color from its parent.\n </p>",
|
|
2169
|
+
"<div className=\"flex flex-col gap-x-6 gap-y-4 text-base md:flex-row\">\n <Link render={<CustomRouterLink href=\"/dashboard\" />} variant=\"inline\">\n Dashboard (via render)\n </Link>\n <Link\n render={\n <CustomRouterLink\n href=\"https://developers.cloudflare.com\"\n target=\"_blank\"\n rel=\"noopener noreferrer\"\n />\n }\n variant=\"inline\"\n >\n Cloudflare Docs <Link.ExternalIcon />\n </Link>\n </div>"
|
|
2170
|
+
],
|
|
2171
|
+
"colors": [],
|
|
2172
|
+
"subComponents": {
|
|
2173
|
+
"ExternalIcon": {
|
|
2174
|
+
"name": "ExternalIcon",
|
|
2175
|
+
"description": "ExternalIcon sub-component",
|
|
2176
|
+
"props": {}
|
|
2177
|
+
}
|
|
2178
|
+
}
|
|
2179
|
+
},
|
|
2180
|
+
"Loader": {
|
|
2181
|
+
"name": "Loader",
|
|
2182
|
+
"type": "component",
|
|
2183
|
+
"description": "Loader component",
|
|
2184
|
+
"importPath": "@cloudflare/kumo",
|
|
2185
|
+
"category": "Feedback",
|
|
2186
|
+
"props": {
|
|
2187
|
+
"className": {
|
|
2188
|
+
"type": "string",
|
|
2189
|
+
"optional": true
|
|
2190
|
+
},
|
|
2191
|
+
"size": {
|
|
2192
|
+
"type": "enum",
|
|
2193
|
+
"optional": true,
|
|
2194
|
+
"values": [
|
|
2195
|
+
"sm",
|
|
2196
|
+
"base",
|
|
2197
|
+
"lg"
|
|
2198
|
+
],
|
|
2199
|
+
"descriptions": {
|
|
2200
|
+
"sm": "Small loader for inline use",
|
|
2201
|
+
"base": "Default loader size",
|
|
2202
|
+
"lg": "Large loader for prominent loading states"
|
|
2203
|
+
},
|
|
2204
|
+
"default": "base"
|
|
2205
|
+
}
|
|
2206
|
+
},
|
|
2207
|
+
"examples": [
|
|
2208
|
+
"<Loader />",
|
|
2209
|
+
"<div className=\"flex items-center gap-4\">\n <Loader size=\"sm\" />\n <Loader size=\"base\" />\n <Loader size=\"lg\" />\n </div>",
|
|
2210
|
+
"<Loader size={24} />"
|
|
2211
|
+
],
|
|
2212
|
+
"colors": []
|
|
2213
|
+
},
|
|
2214
|
+
"MenuBar": {
|
|
2215
|
+
"name": "MenuBar",
|
|
2216
|
+
"type": "component",
|
|
2217
|
+
"description": "MenuBar component",
|
|
2218
|
+
"importPath": "@cloudflare/kumo",
|
|
2219
|
+
"category": "Navigation",
|
|
2220
|
+
"props": {
|
|
2221
|
+
"className": {
|
|
2222
|
+
"type": "string",
|
|
2223
|
+
"optional": true
|
|
2224
|
+
},
|
|
2225
|
+
"isActive": {
|
|
2226
|
+
"type": "number | boolean | string",
|
|
2227
|
+
"optional": true
|
|
2228
|
+
},
|
|
2229
|
+
"options": {
|
|
2230
|
+
"type": "MenuOptionProps[]",
|
|
2231
|
+
"required": true
|
|
2232
|
+
},
|
|
2233
|
+
"optionIds": {
|
|
2234
|
+
"type": "boolean",
|
|
2235
|
+
"optional": true
|
|
2236
|
+
}
|
|
2237
|
+
},
|
|
2238
|
+
"examples": [
|
|
2239
|
+
"<MenuBar\n isActive=\"bold\"\n optionIds\n options={[\n {\n icon: <TextBolderIcon />,\n id: \"bold\",\n tooltip: \"Bold\",\n onClick: () => {},\n },\n {\n icon: <TextItalicIcon />,\n id: \"italic\",\n tooltip: \"Italic\",\n onClick: () => {},\n },\n ]}\n />",
|
|
2240
|
+
"<MenuBar\n isActive=\"bold\"\n optionIds\n options={[\n {\n icon: <TextBolderIcon />,\n id: \"bold\",\n tooltip: \"Bold\",\n onClick: () => {},\n },\n {\n icon: <TextItalicIcon />,\n id: \"italic\",\n tooltip: \"Italic\",\n onClick: () => {},\n },\n ]}\n />",
|
|
2241
|
+
"<MenuBar\n isActive=\"\"\n optionIds\n options={[\n {\n icon: <TextBolderIcon />,\n id: \"bold\",\n tooltip: \"Bold\",\n onClick: () => {},\n },\n {\n icon: <TextItalicIcon />,\n id: \"italic\",\n tooltip: \"Italic\",\n onClick: () => {},\n },\n ]}\n />"
|
|
2242
|
+
],
|
|
2243
|
+
"colors": [
|
|
2244
|
+
"bg-kumo-base",
|
|
2245
|
+
"bg-kumo-fill",
|
|
2246
|
+
"border-kumo-fill"
|
|
2247
|
+
],
|
|
2248
|
+
"styling": {
|
|
2249
|
+
"container": {
|
|
2250
|
+
"height": 32,
|
|
2251
|
+
"borderRadius": 8,
|
|
2252
|
+
"padding": 2,
|
|
2253
|
+
"gap": 2
|
|
2254
|
+
},
|
|
2255
|
+
"button": {
|
|
2256
|
+
"width": 36,
|
|
2257
|
+
"borderRadius": 6,
|
|
2258
|
+
"iconSize": 18
|
|
2259
|
+
}
|
|
2260
|
+
}
|
|
2261
|
+
},
|
|
2262
|
+
"Meter": {
|
|
2263
|
+
"name": "Meter",
|
|
2264
|
+
"type": "component",
|
|
2265
|
+
"description": "Meter component",
|
|
2266
|
+
"importPath": "@cloudflare/kumo",
|
|
2267
|
+
"category": "Display",
|
|
2268
|
+
"props": {
|
|
2269
|
+
"customValue": {
|
|
2270
|
+
"type": "string",
|
|
2271
|
+
"optional": true
|
|
2272
|
+
},
|
|
2273
|
+
"label": {
|
|
2274
|
+
"type": "string",
|
|
2275
|
+
"required": true
|
|
2276
|
+
},
|
|
2277
|
+
"showValue": {
|
|
2278
|
+
"type": "boolean",
|
|
2279
|
+
"optional": true
|
|
2280
|
+
},
|
|
2281
|
+
"trackClassName": {
|
|
2282
|
+
"type": "string",
|
|
2283
|
+
"optional": true
|
|
2284
|
+
},
|
|
2285
|
+
"indicatorClassName": {
|
|
2286
|
+
"type": "string",
|
|
2287
|
+
"optional": true
|
|
2288
|
+
},
|
|
2289
|
+
"value": {
|
|
2290
|
+
"type": "number",
|
|
2291
|
+
"description": "Current value of the meter"
|
|
2292
|
+
},
|
|
2293
|
+
"max": {
|
|
2294
|
+
"type": "number",
|
|
2295
|
+
"description": "Maximum value of the meter (default: 100)"
|
|
2296
|
+
},
|
|
2297
|
+
"min": {
|
|
2298
|
+
"type": "number",
|
|
2299
|
+
"description": "Minimum value of the meter (default: 0)"
|
|
2300
|
+
}
|
|
2301
|
+
},
|
|
2302
|
+
"examples": [
|
|
2303
|
+
"<Meter label=\"Storage used\" value={65} />",
|
|
2304
|
+
"<Meter label=\"API requests\" value={75} customValue=\"750 / 1,000\" />",
|
|
2305
|
+
"<Meter label=\"Progress\" value={40} showValue={false} />",
|
|
2306
|
+
"<Meter label=\"Quota reached\" value={100} />",
|
|
2307
|
+
"<Meter label=\"Memory usage\" value={15} />",
|
|
2308
|
+
"<Meter\n label=\"Upload progress\"\n value={80}\n indicatorClassName=\"from-green-500 via-green-500 to-green-500\"\n />"
|
|
2309
|
+
],
|
|
2310
|
+
"colors": [
|
|
2311
|
+
"bg-kumo-fill",
|
|
2312
|
+
"text-kumo-default",
|
|
2313
|
+
"text-kumo-strong"
|
|
2314
|
+
]
|
|
2315
|
+
},
|
|
2316
|
+
"Pagination": {
|
|
2317
|
+
"name": "Pagination",
|
|
2318
|
+
"type": "component",
|
|
2319
|
+
"description": "Pagination component",
|
|
2320
|
+
"importPath": "@cloudflare/kumo",
|
|
2321
|
+
"category": "Navigation",
|
|
2322
|
+
"props": {
|
|
2323
|
+
"controls": {
|
|
2324
|
+
"type": "enum",
|
|
2325
|
+
"optional": true,
|
|
2326
|
+
"values": [
|
|
2327
|
+
"full",
|
|
2328
|
+
"simple"
|
|
2329
|
+
],
|
|
2330
|
+
"descriptions": {
|
|
2331
|
+
"full": "Full pagination controls with first, previous, page input, next, and last buttons",
|
|
2332
|
+
"simple": "Simple pagination controls with only previous and next buttons"
|
|
2333
|
+
},
|
|
2334
|
+
"default": "full"
|
|
2335
|
+
},
|
|
2336
|
+
"setPage": {
|
|
2337
|
+
"type": "(page: number) => void",
|
|
2338
|
+
"required": true,
|
|
2339
|
+
"description": "Callback when page changes"
|
|
2340
|
+
},
|
|
2341
|
+
"page": {
|
|
2342
|
+
"type": "number",
|
|
2343
|
+
"optional": true
|
|
2344
|
+
},
|
|
2345
|
+
"perPage": {
|
|
2346
|
+
"type": "number",
|
|
2347
|
+
"optional": true
|
|
2348
|
+
},
|
|
2349
|
+
"totalCount": {
|
|
2350
|
+
"type": "number",
|
|
2351
|
+
"optional": true
|
|
2352
|
+
}
|
|
2353
|
+
},
|
|
2354
|
+
"examples": [
|
|
2355
|
+
"<Pagination page={page} setPage={setPage} perPage={10} totalCount={100} />",
|
|
2356
|
+
"<Pagination\n page={page}\n setPage={setPage}\n perPage={10}\n totalCount={100}\n controls=\"simple\"\n />",
|
|
2357
|
+
"<Pagination\n page={page}\n setPage={setPage}\n perPage={10}\n totalCount={100}\n controls=\"full\"\n />",
|
|
2358
|
+
"<Pagination page={page} setPage={setPage} perPage={10} totalCount={100} />",
|
|
2359
|
+
"<Pagination page={page} setPage={setPage} perPage={25} totalCount={1250} />"
|
|
2360
|
+
],
|
|
2361
|
+
"colors": [
|
|
2362
|
+
"text-kumo-strong"
|
|
2363
|
+
],
|
|
2364
|
+
"styling": {
|
|
2365
|
+
"layout": {
|
|
2366
|
+
"height": 36,
|
|
2367
|
+
"buttonSize": 36,
|
|
2368
|
+
"inputWidth": 50,
|
|
2369
|
+
"iconSize": 16,
|
|
2370
|
+
"gap": 8,
|
|
2371
|
+
"borderRadius": 6
|
|
2372
|
+
}
|
|
2373
|
+
}
|
|
2374
|
+
},
|
|
2375
|
+
"Popover": {
|
|
2376
|
+
"name": "Popover",
|
|
2377
|
+
"type": "component",
|
|
2378
|
+
"description": "Popover component for displaying accessible popup content anchored to a trigger.",
|
|
2379
|
+
"importPath": "@cloudflare/kumo",
|
|
2380
|
+
"category": "Overlay",
|
|
2381
|
+
"props": {
|
|
2382
|
+
"side": {
|
|
2383
|
+
"type": "enum",
|
|
2384
|
+
"optional": true,
|
|
2385
|
+
"values": [
|
|
2386
|
+
"top",
|
|
2387
|
+
"bottom",
|
|
2388
|
+
"left",
|
|
2389
|
+
"right"
|
|
2390
|
+
],
|
|
2391
|
+
"descriptions": {
|
|
2392
|
+
"top": "Popover appears above the trigger",
|
|
2393
|
+
"bottom": "Popover appears below the trigger",
|
|
2394
|
+
"left": "Popover appears to the left of the trigger",
|
|
2395
|
+
"right": "Popover appears to the right of the trigger"
|
|
2396
|
+
},
|
|
2397
|
+
"default": "bottom"
|
|
2398
|
+
}
|
|
2399
|
+
},
|
|
2400
|
+
"examples": [
|
|
2401
|
+
"<Popover>\n <Popover.Trigger asChild>\n <Button shape=\"square\" icon={BellIcon} />\n </Popover.Trigger>\n <Popover.Content>\n <Popover.Title>Notifications</Popover.Title>\n <Popover.Description>\n You are all caught up. Good job!\n </Popover.Description>\n </Popover.Content>\n </Popover>",
|
|
2402
|
+
"<Popover>\n <Popover.Trigger asChild>\n <Button>Open Popover</Button>\n </Popover.Trigger>\n <Popover.Content>\n <Popover.Title>Popover Title</Popover.Title>\n <Popover.Description>\n This is a basic popover with a title and description.\n </Popover.Description>\n </Popover.Content>\n </Popover>",
|
|
2403
|
+
"<Popover>\n <Popover.Trigger asChild>\n <Button>Open Settings</Button>\n </Popover.Trigger>\n <Popover.Content>\n <Popover.Title>Settings</Popover.Title>\n <Popover.Description>\n Configure your preferences below.\n </Popover.Description>\n <div className=\"mt-3\">\n <Popover.Close asChild>\n <Button variant=\"secondary\" size=\"sm\">\n Close\n </Button>\n </Popover.Close>\n </div>\n </Popover.Content>\n </Popover>",
|
|
2404
|
+
"<div className=\"flex flex-wrap gap-4\">\n <Popover>\n <Popover.Trigger asChild>\n <Button variant=\"secondary\">Bottom</Button>\n </Popover.Trigger>\n <Popover.Content side=\"bottom\">\n <Popover.Title>Bottom</Popover.Title>\n <Popover.Description>\n Popover on bottom (default).\n </Popover.Description>\n </Popover.Content>\n </Popover>\n\n <Popover>\n <Popover.Trigger asChild>\n <Button variant=\"secondary\">Top</Button>\n </Popover.Trigger>\n <Popover.Content side=\"top\">\n <Popover.Title>Top</Popover.Title>\n <Popover.Description>Popover on top.</Popover.Description>\n </Popover.Content>\n </Popover>\n\n <Popover>\n <Popover.Trigger asChild>\n <Button variant=\"secondary\">Left</Button>\n </Popover.Trigger>\n <Popover.Content side=\"left\">\n <Popover.Title>Left</Popover.Title>\n <Popover.Description>Popover on left.</Popover.Description>\n </Popover.Content>\n </Popover>\n\n <Popover>\n <Popover.Trigger asChild>\n <Button variant=\"secondary\">Right</Button>\n </Popover.Trigger>\n <Popover.Content side=\"right\">\n <Popover.Title>Right</Popover.Title>\n <Popover.Description>Popover on right.</Popover.Description>\n </Popover.Content>\n </Popover>\n </div>",
|
|
2405
|
+
"<Popover>\n <Popover.Trigger asChild>\n <Button>User Profile</Button>\n </Popover.Trigger>\n <Popover.Content className=\"w-64\">\n <div className=\"flex items-center gap-3\">\n <div className=\"size-10 rounded-full bg-kumo-recessed\" />\n <div>\n <Popover.Title>Jane Doe</Popover.Title>\n <p className=\"text-sm text-kumo-subtle\">jane@example.com</p>\n </div>\n </div>\n <div className=\"mt-3 flex gap-2 border-t border-kumo-line pt-3\">\n <Button variant=\"secondary\" size=\"sm\" className=\"flex-1\">\n Profile\n </Button>\n <Popover.Close asChild>\n <Button variant=\"ghost\" size=\"sm\" className=\"flex-1\">\n Sign Out\n </Button>\n </Popover.Close>\n </div>\n </Popover.Content>\n </Popover>",
|
|
2406
|
+
"<Popover>\n <Popover.Trigger openOnHover delay={200} asChild>\n <Button variant=\"secondary\">Hover Me</Button>\n </Popover.Trigger>\n <Popover.Content>\n <Popover.Title>Hover Triggered</Popover.Title>\n <Popover.Description>\n This popover opens on hover with a 200ms delay. It can still contain\n interactive content like buttons and links.\n </Popover.Description>\n <div className=\"mt-3\">\n <Popover.Close asChild>\n <Button variant=\"secondary\" size=\"sm\">\n Got it\n </Button>\n </Popover.Close>\n </div>\n </Popover.Content>\n </Popover>"
|
|
2407
|
+
],
|
|
2408
|
+
"colors": [
|
|
2409
|
+
"bg-kumo-base",
|
|
2410
|
+
"fill-kumo-base",
|
|
2411
|
+
"fill-kumo-tip-shadow",
|
|
2412
|
+
"fill-kumo-tip-stroke",
|
|
2413
|
+
"outline-kumo-fill",
|
|
2414
|
+
"text-kumo-default",
|
|
2415
|
+
"text-kumo-subtle"
|
|
2416
|
+
],
|
|
2417
|
+
"subComponents": {
|
|
2418
|
+
"Trigger": {
|
|
2419
|
+
"name": "Trigger",
|
|
2420
|
+
"description": "Trigger sub-component",
|
|
2421
|
+
"props": {}
|
|
2422
|
+
},
|
|
2423
|
+
"Content": {
|
|
2424
|
+
"name": "Content",
|
|
2425
|
+
"description": "Content sub-component",
|
|
2426
|
+
"props": {}
|
|
2427
|
+
},
|
|
2428
|
+
"Title": {
|
|
2429
|
+
"name": "Title",
|
|
2430
|
+
"description": "Title sub-component",
|
|
2431
|
+
"props": {}
|
|
2432
|
+
},
|
|
2433
|
+
"Description": {
|
|
2434
|
+
"name": "Description",
|
|
2435
|
+
"description": "Description sub-component",
|
|
2436
|
+
"props": {}
|
|
2437
|
+
},
|
|
2438
|
+
"Close": {
|
|
2439
|
+
"name": "Close",
|
|
2440
|
+
"description": "Close sub-component",
|
|
2441
|
+
"props": {}
|
|
2442
|
+
}
|
|
2443
|
+
}
|
|
2444
|
+
},
|
|
2445
|
+
"Radio": {
|
|
2446
|
+
"name": "Radio",
|
|
2447
|
+
"type": "component",
|
|
2448
|
+
"description": "Radio component",
|
|
2449
|
+
"importPath": "@cloudflare/kumo",
|
|
2450
|
+
"category": "Input",
|
|
2451
|
+
"props": {
|
|
2452
|
+
"legend": {
|
|
2453
|
+
"type": "string",
|
|
2454
|
+
"required": true,
|
|
2455
|
+
"description": "Legend text for the group (required for accessibility)"
|
|
2456
|
+
},
|
|
2457
|
+
"children": {
|
|
2458
|
+
"type": "ReactNode",
|
|
2459
|
+
"optional": true,
|
|
2460
|
+
"description": "Child Radio.Item components"
|
|
2461
|
+
},
|
|
2462
|
+
"orientation": {
|
|
2463
|
+
"type": "enum",
|
|
2464
|
+
"optional": true,
|
|
2465
|
+
"description": "Layout direction of the radio items",
|
|
2466
|
+
"values": [
|
|
2467
|
+
"vertical",
|
|
2468
|
+
"horizontal"
|
|
2469
|
+
]
|
|
2470
|
+
},
|
|
2471
|
+
"error": {
|
|
2472
|
+
"type": "string",
|
|
2473
|
+
"optional": true,
|
|
2474
|
+
"description": "Error message for the group"
|
|
2475
|
+
},
|
|
2476
|
+
"description": {
|
|
2477
|
+
"type": "ReactNode",
|
|
2478
|
+
"optional": true,
|
|
2479
|
+
"description": "Helper text for the group"
|
|
2480
|
+
},
|
|
2481
|
+
"value": {
|
|
2482
|
+
"type": "string",
|
|
2483
|
+
"optional": true,
|
|
2484
|
+
"description": "Value of the radio that should be selected (controlled)"
|
|
2485
|
+
},
|
|
2486
|
+
"disabled": {
|
|
2487
|
+
"type": "boolean",
|
|
2488
|
+
"optional": true,
|
|
2489
|
+
"description": "Whether all radios in the group are disabled"
|
|
2490
|
+
},
|
|
2491
|
+
"controlPosition": {
|
|
2492
|
+
"type": "enum",
|
|
2493
|
+
"optional": true,
|
|
2494
|
+
"description": "Position of radio control relative to label: \"start\" (default) puts radio before label, \"end\" puts label before radio",
|
|
2495
|
+
"values": [
|
|
2496
|
+
"start",
|
|
2497
|
+
"end"
|
|
2498
|
+
]
|
|
2499
|
+
},
|
|
2500
|
+
"name": {
|
|
2501
|
+
"type": "string",
|
|
2502
|
+
"optional": true,
|
|
2503
|
+
"description": "Form submission name for the radio group"
|
|
2504
|
+
},
|
|
2505
|
+
"className": {
|
|
2506
|
+
"type": "string",
|
|
2507
|
+
"optional": true,
|
|
2508
|
+
"description": "Additional CSS classes"
|
|
2509
|
+
}
|
|
2510
|
+
},
|
|
2511
|
+
"examples": [
|
|
2512
|
+
"<Radio.Group\n legend=\"Notification preference\"\n value={value}\n onValueChange={setValue}\n >\n <Radio.Item label=\"Email\" value=\"email\" />\n <Radio.Item label=\"SMS\" value=\"sms\" />\n <Radio.Item label=\"Push notification\" value=\"push\" />\n </Radio.Group>",
|
|
2513
|
+
"<Radio.Group legend=\"Account type\" value={value} onValueChange={setValue}>\n <Radio.Item label=\"Personal\" value=\"personal\" />\n <Radio.Item label=\"Business\" value=\"business\" />\n <Radio.Item label=\"Enterprise\" value=\"enterprise\" />\n </Radio.Group>",
|
|
2514
|
+
"<Radio.Group\n legend=\"Size\"\n orientation=\"horizontal\"\n value={value}\n onValueChange={setValue}\n >\n <Radio.Item label=\"Small\" value=\"sm\" />\n <Radio.Item label=\"Medium\" value=\"md\" />\n <Radio.Item label=\"Large\" value=\"lg\" />\n </Radio.Group>",
|
|
2515
|
+
"<Radio.Group\n legend=\"Shipping method\"\n description=\"Choose how you'd like to receive your order\"\n value={value}\n onValueChange={setValue}\n >\n <Radio.Item label=\"Standard (5-7 days)\" value=\"standard\" />\n <Radio.Item label=\"Express (2-3 days)\" value=\"express\" />\n <Radio.Item label=\"Overnight\" value=\"overnight\" />\n </Radio.Group>",
|
|
2516
|
+
"<Radio.Group\n legend=\"Payment method\"\n error=\"Please select a payment method to continue\"\n >\n <Radio.Item label=\"Credit Card\" value=\"card\" variant=\"error\" />\n <Radio.Item label=\"PayPal\" value=\"paypal\" variant=\"error\" />\n <Radio.Item label=\"Bank Transfer\" value=\"bank\" variant=\"error\" />\n </Radio.Group>",
|
|
2517
|
+
"<div className=\"flex flex-col gap-6\">\n <Radio.Group legend=\"Disabled group\" disabled defaultValue=\"a\">\n <Radio.Item label=\"Option A\" value=\"a\" />\n <Radio.Item label=\"Option B\" value=\"b\" />\n </Radio.Group>\n <Radio.Group legend=\"Individual disabled\" defaultValue=\"available\">\n <Radio.Item label=\"Available\" value=\"available\" />\n <Radio.Item label=\"Unavailable\" value=\"unavailable\" disabled />\n </Radio.Group>\n </div>",
|
|
2518
|
+
"<Radio.Group legend=\"Preferences\" controlPosition=\"end\" defaultValue=\"a\">\n <Radio.Item label=\"Label before radio\" value=\"a\" />\n <Radio.Item label=\"Another option\" value=\"b\" />\n </Radio.Group>"
|
|
2519
|
+
],
|
|
2520
|
+
"colors": [
|
|
2521
|
+
"bg-kumo-base",
|
|
2522
|
+
"bg-kumo-contrast",
|
|
2523
|
+
"border-kumo-line",
|
|
2524
|
+
"ring-kumo-danger",
|
|
2525
|
+
"ring-kumo-line",
|
|
2526
|
+
"ring-kumo-ring",
|
|
2527
|
+
"text-kumo-danger",
|
|
2528
|
+
"text-kumo-default",
|
|
2529
|
+
"text-kumo-subtle"
|
|
2530
|
+
]
|
|
2531
|
+
},
|
|
2532
|
+
"Select": {
|
|
2533
|
+
"name": "Select",
|
|
2534
|
+
"type": "component",
|
|
2535
|
+
"description": "Select component",
|
|
2536
|
+
"importPath": "@cloudflare/kumo",
|
|
2537
|
+
"category": "Input",
|
|
2538
|
+
"props": {
|
|
2539
|
+
"className": {
|
|
2540
|
+
"type": "string",
|
|
2541
|
+
"optional": true,
|
|
2542
|
+
"description": "Additional CSS classes"
|
|
2543
|
+
},
|
|
2544
|
+
"label": {
|
|
2545
|
+
"type": "ReactNode",
|
|
2546
|
+
"optional": true,
|
|
2547
|
+
"description": "Label content for the select (enables Field wrapper) - can be a string or any React node"
|
|
2548
|
+
},
|
|
2549
|
+
"hideLabel": {
|
|
2550
|
+
"type": "boolean",
|
|
2551
|
+
"optional": true,
|
|
2552
|
+
"description": "Whether to visually hide the label (still accessible to screen readers)"
|
|
2553
|
+
},
|
|
2554
|
+
"placeholder": {
|
|
2555
|
+
"type": "string",
|
|
2556
|
+
"optional": true,
|
|
2557
|
+
"description": "Placeholder text when no value is selected"
|
|
2558
|
+
},
|
|
2559
|
+
"loading": {
|
|
2560
|
+
"type": "boolean",
|
|
2561
|
+
"optional": true,
|
|
2562
|
+
"description": "Whether the select is in a loading state"
|
|
2563
|
+
},
|
|
2564
|
+
"disabled": {
|
|
2565
|
+
"type": "boolean",
|
|
2566
|
+
"optional": true,
|
|
2567
|
+
"description": "Whether the select is disabled"
|
|
2568
|
+
},
|
|
2569
|
+
"required": {
|
|
2570
|
+
"type": "boolean",
|
|
2571
|
+
"optional": true,
|
|
2572
|
+
"description": "Whether the select is required"
|
|
2573
|
+
},
|
|
2574
|
+
"labelTooltip": {
|
|
2575
|
+
"type": "ReactNode",
|
|
2576
|
+
"optional": true,
|
|
2577
|
+
"description": "Tooltip content to display next to the label via an info icon"
|
|
2578
|
+
},
|
|
2579
|
+
"value": {
|
|
2580
|
+
"type": "string",
|
|
2581
|
+
"optional": true,
|
|
2582
|
+
"description": "The currently selected value"
|
|
2583
|
+
},
|
|
2584
|
+
"children": {
|
|
2585
|
+
"type": "ReactNode",
|
|
2586
|
+
"optional": true,
|
|
2587
|
+
"description": "Child elements (Select.Option components)"
|
|
2588
|
+
},
|
|
2589
|
+
"description": {
|
|
2590
|
+
"type": "ReactNode",
|
|
2591
|
+
"optional": true,
|
|
2592
|
+
"description": "Helper text displayed below the select"
|
|
2593
|
+
},
|
|
2594
|
+
"error": {
|
|
2595
|
+
"type": "string | object",
|
|
2596
|
+
"optional": true,
|
|
2597
|
+
"description": "Error message or validation error object"
|
|
2598
|
+
},
|
|
2599
|
+
"onValueChange": {
|
|
2600
|
+
"type": "(value: string) => void",
|
|
2601
|
+
"description": "Callback when selection changes"
|
|
2602
|
+
},
|
|
2603
|
+
"defaultValue": {
|
|
2604
|
+
"type": "string",
|
|
2605
|
+
"description": "Initial value for uncontrolled mode"
|
|
2606
|
+
}
|
|
2607
|
+
},
|
|
2608
|
+
"examples": [
|
|
2609
|
+
"<Select\n className=\"w-[200px]\"\n value={value}\n onValueChange={(v) => setValue(v ?? \"Apple\")}\n placeholder=\"Please select\"\n >\n <Select.Option value=\"Apple\">Apple</Select.Option>\n <Select.Option value=\"Banana\">Banana</Select.Option>\n <Select.Option value=\"Cherry\">Cherry</Select.Option>\n </Select>",
|
|
2610
|
+
"<Select\n className=\"w-[200px]\"\n value={value}\n onValueChange={(v) => setValue(v as string)}\n items={{\n bug: \"Bug\",\n documentation: \"Documentation\",\n feature: \"Feature\",\n }}\n >\n <Select.Option value=\"bug\">Bug</Select.Option>\n <Select.Option value=\"documentation\">Documentation</Select.Option>\n <Select.Option value=\"feature\">Feature</Select.Option>\n </Select>",
|
|
2611
|
+
"<Select\n className=\"w-[200px]\"\n value={value}\n onValueChange={(v) => setValue(v as string | null)}\n items={[\n { value: null, label: \"Please select\" },\n { value: \"bug\", label: \"Bug\" },\n { value: \"documentation\", label: \"Documentation\" },\n { value: \"feature\", label: \"Feature\" },\n ]}\n >\n <Select.Option value=\"bug\">Bug</Select.Option>\n <Select.Option value=\"documentation\">Documentation</Select.Option>\n <Select.Option value=\"feature\">Feature</Select.Option>\n </Select>",
|
|
2612
|
+
"<Select\n className=\"w-[200px]\"\n renderValue={(v) => (\n <span>\n {v.emoji} {v.label}\n </span>\n )}\n value={value}\n onValueChange={(v) => setValue(v as (typeof languages)[0])}\n >\n {languages.map((language) => (\n <Select.Option key={language.value} value={language}>\n {language.emoji} {language.label}\n </Select.Option>\n ))}\n </Select>",
|
|
2613
|
+
"<Select className=\"w-[200px]\" loading />",
|
|
2614
|
+
"<Select\n className=\"w-[200px]\"\n loading={loading}\n value={value}\n onValueChange={(v) => setValue(v as string | null)}\n placeholder=\"Please select\"\n >\n {data?.map((item) => (\n <Select.Option key={item} value={item}>\n {item}\n </Select.Option>\n ))}\n </Select>",
|
|
2615
|
+
"<Select\n className=\"w-[250px]\"\n multiple\n renderValue={(value) => {\n if (value.length > 3) {\n return (\n <span className=\"line-clamp-1\">\n {value.slice(2).join(\", \") + ` and ${value.length - 2} more`}\n </span>\n );\n }\n return <span>{value.join(\", \")}</span>;\n }}\n value={value}\n onValueChange={(v) => setValue(v as string[])}\n >\n <Select.Option value=\"Name\">Name</Select.Option>\n <Select.Option value=\"Location\">Location</Select.Option>\n <Select.Option value=\"Size\">Size</Select.Option>\n <Select.Option value=\"Read\">Read</Select.Option>\n <Select.Option value=\"Write\">Write</Select.Option>\n <Select.Option value=\"CreatedAt\">Created At</Select.Option>\n </Select>",
|
|
2616
|
+
"<Select\n className=\"w-[200px]\"\n onValueChange={(v) => setValue(v as (typeof authors)[0] | null)}\n value={value}\n isItemEqualToValue={(item, value) => item?.id === value?.id}\n renderValue={(author) => {\n return author?.name ?? \"Please select author\";\n }}\n >\n {authors.map((author) => (\n <Select.Option key={author.id} value={author}>\n <div className=\"flex w-[300px] items-center justify-between gap-2\">\n <Text>{author.name}</Text>\n <Text variant=\"secondary\">{author.title}</Text>\n </div>\n </Select.Option>\n ))}\n </Select>"
|
|
2617
|
+
],
|
|
2618
|
+
"colors": [
|
|
2619
|
+
"bg-kumo-control",
|
|
2620
|
+
"bg-kumo-overlay",
|
|
2621
|
+
"ring-kumo-line",
|
|
2622
|
+
"ring-kumo-ring",
|
|
2623
|
+
"text-kumo-default"
|
|
2624
|
+
],
|
|
2625
|
+
"subComponents": {
|
|
2626
|
+
"Option": {
|
|
2627
|
+
"name": "Option",
|
|
2628
|
+
"description": "Option sub-component",
|
|
2629
|
+
"props": {}
|
|
2630
|
+
}
|
|
2631
|
+
},
|
|
2632
|
+
"styling": {
|
|
2633
|
+
"trigger": {
|
|
2634
|
+
"height": 36,
|
|
2635
|
+
"paddingX": 12,
|
|
2636
|
+
"borderRadius": 8,
|
|
2637
|
+
"background": "color-secondary",
|
|
2638
|
+
"text": "text-color-surface",
|
|
2639
|
+
"ring": "color-border",
|
|
2640
|
+
"fontSize": 16,
|
|
2641
|
+
"fontWeight": 400
|
|
2642
|
+
},
|
|
2643
|
+
"stateTokens": {
|
|
2644
|
+
"focus": {
|
|
2645
|
+
"ring": "color-active"
|
|
2646
|
+
},
|
|
2647
|
+
"disabled": {
|
|
2648
|
+
"opacity": 0.5
|
|
2649
|
+
}
|
|
2650
|
+
},
|
|
2651
|
+
"icons": {
|
|
2652
|
+
"caret": {
|
|
2653
|
+
"name": "ph-caret-up-down",
|
|
2654
|
+
"size": 20
|
|
2655
|
+
},
|
|
2656
|
+
"check": {
|
|
2657
|
+
"name": "ph-check",
|
|
2658
|
+
"size": 20
|
|
2659
|
+
}
|
|
2660
|
+
},
|
|
2661
|
+
"popup": {
|
|
2662
|
+
"background": "color-secondary",
|
|
2663
|
+
"ring": "color-border",
|
|
2664
|
+
"borderRadius": 8,
|
|
2665
|
+
"padding": 6
|
|
2666
|
+
},
|
|
2667
|
+
"option": {
|
|
2668
|
+
"paddingX": 8,
|
|
2669
|
+
"paddingY": 6,
|
|
2670
|
+
"borderRadius": 4,
|
|
2671
|
+
"fontSize": 16,
|
|
2672
|
+
"highlightBackground": "color-surface-secondary"
|
|
2673
|
+
}
|
|
2674
|
+
}
|
|
2675
|
+
},
|
|
2676
|
+
"SensitiveInput": {
|
|
2677
|
+
"name": "SensitiveInput",
|
|
2678
|
+
"type": "component",
|
|
2679
|
+
"description": "SensitiveInput component",
|
|
2680
|
+
"importPath": "@cloudflare/kumo",
|
|
2681
|
+
"category": "Other",
|
|
2682
|
+
"props": {
|
|
2683
|
+
"alt": {
|
|
2684
|
+
"type": "string",
|
|
2685
|
+
"optional": true
|
|
2686
|
+
},
|
|
2687
|
+
"autoComplete": {
|
|
2688
|
+
"type": "React.HTMLInputAutoCompleteAttribute",
|
|
2689
|
+
"optional": true
|
|
2690
|
+
},
|
|
2691
|
+
"checked": {
|
|
2692
|
+
"type": "boolean",
|
|
2693
|
+
"optional": true
|
|
2694
|
+
},
|
|
2695
|
+
"disabled": {
|
|
2696
|
+
"type": "boolean",
|
|
2697
|
+
"optional": true
|
|
2698
|
+
},
|
|
2699
|
+
"height": {
|
|
2700
|
+
"type": "number | string",
|
|
2701
|
+
"optional": true
|
|
2702
|
+
},
|
|
2703
|
+
"list": {
|
|
2704
|
+
"type": "string",
|
|
2705
|
+
"optional": true
|
|
2706
|
+
},
|
|
2707
|
+
"name": {
|
|
2708
|
+
"type": "string",
|
|
2709
|
+
"optional": true
|
|
2710
|
+
},
|
|
2711
|
+
"placeholder": {
|
|
2712
|
+
"type": "string",
|
|
2713
|
+
"optional": true
|
|
2714
|
+
},
|
|
2715
|
+
"readOnly": {
|
|
2716
|
+
"type": "boolean",
|
|
2717
|
+
"optional": true
|
|
2718
|
+
},
|
|
2719
|
+
"required": {
|
|
2720
|
+
"type": "boolean",
|
|
2721
|
+
"optional": true
|
|
2722
|
+
},
|
|
2723
|
+
"width": {
|
|
2724
|
+
"type": "number | string",
|
|
2725
|
+
"optional": true
|
|
2726
|
+
},
|
|
2727
|
+
"className": {
|
|
2728
|
+
"type": "string",
|
|
2729
|
+
"optional": true
|
|
2730
|
+
},
|
|
2731
|
+
"id": {
|
|
2732
|
+
"type": "string",
|
|
2733
|
+
"optional": true
|
|
2734
|
+
},
|
|
2735
|
+
"lang": {
|
|
2736
|
+
"type": "string",
|
|
2737
|
+
"optional": true
|
|
2738
|
+
},
|
|
2739
|
+
"title": {
|
|
2740
|
+
"type": "string",
|
|
2741
|
+
"optional": true
|
|
2742
|
+
},
|
|
2743
|
+
"children": {
|
|
2744
|
+
"type": "ReactNode",
|
|
2745
|
+
"optional": true
|
|
2746
|
+
},
|
|
2747
|
+
"value": {
|
|
2748
|
+
"type": "string",
|
|
2749
|
+
"optional": true,
|
|
2750
|
+
"description": "Controlled value"
|
|
2751
|
+
},
|
|
2752
|
+
"size": {
|
|
2753
|
+
"type": "enum",
|
|
2754
|
+
"optional": true,
|
|
2755
|
+
"description": "Size variant",
|
|
2756
|
+
"values": [
|
|
2757
|
+
"xs",
|
|
2758
|
+
"sm",
|
|
2759
|
+
"base",
|
|
2760
|
+
"lg"
|
|
2761
|
+
],
|
|
2762
|
+
"default": "base"
|
|
2763
|
+
},
|
|
2764
|
+
"variant": {
|
|
2765
|
+
"type": "enum",
|
|
2766
|
+
"optional": true,
|
|
2767
|
+
"description": "Style variant",
|
|
2768
|
+
"values": [
|
|
2769
|
+
"default",
|
|
2770
|
+
"error"
|
|
2771
|
+
],
|
|
2772
|
+
"default": "default"
|
|
2773
|
+
},
|
|
2774
|
+
"label": {
|
|
2775
|
+
"type": "ReactNode",
|
|
2776
|
+
"optional": true,
|
|
2777
|
+
"description": "Label content for the input (enables Field wrapper and sets masked state label) - can be a string or any React node"
|
|
2778
|
+
},
|
|
2779
|
+
"labelTooltip": {
|
|
2780
|
+
"type": "ReactNode",
|
|
2781
|
+
"optional": true,
|
|
2782
|
+
"description": "Tooltip content to display next to the label via an info icon"
|
|
2783
|
+
},
|
|
2784
|
+
"description": {
|
|
2785
|
+
"type": "ReactNode",
|
|
2786
|
+
"optional": true,
|
|
2787
|
+
"description": "Helper text displayed below the input"
|
|
2788
|
+
},
|
|
2789
|
+
"error": {
|
|
2790
|
+
"type": "string | object",
|
|
2791
|
+
"optional": true,
|
|
2792
|
+
"description": "Error message or validation error object"
|
|
2793
|
+
}
|
|
2794
|
+
},
|
|
2795
|
+
"examples": [
|
|
2796
|
+
"<div className=\"w-80\">\n <SensitiveInput label=\"API Key\" defaultValue=\"sk_live_abc123xyz789\" />\n </div>",
|
|
2797
|
+
"<div className=\"flex flex-col gap-4\">\n {sizes.map((size) => (\n <div key={size} className=\"flex items-center gap-2\">\n <span className=\"w-12 text-sm text-kumo-subtle\">{size}</span>\n <SensitiveInput\n label={`${size} size`}\n size={size}\n defaultValue=\"secret-api-key-123\"\n />\n </div>\n ))}\n </div>",
|
|
2798
|
+
"<div className=\"flex w-80 flex-col gap-4\">\n <SensitiveInput\n label=\"Controlled Secret\"\n value={value}\n onValueChange={setValue}\n />\n <div className=\"text-sm text-kumo-subtle\">\n Current value: <code className=\"text-kumo-default\">{value}</code>\n </div>\n <div className=\"flex gap-2\">\n <Button\n onClick={() => setValue(\"new-secret-\" + Date.now())}\n variant=\"primary\"\n size=\"sm\"\n >\n Change value\n </Button>\n <Button onClick={() => setValue(\"\")} variant=\"secondary\" size=\"sm\">\n Clear\n </Button>\n </div>\n </div>",
|
|
2799
|
+
"<div className=\"flex w-80 flex-col gap-4\">\n <SensitiveInput\n label=\"Error State\"\n variant=\"error\"\n defaultValue=\"invalid-key\"\n error=\"This API key is not valid\"\n />\n <SensitiveInput label=\"Disabled\" defaultValue=\"cannot-edit\" disabled />\n <SensitiveInput\n label=\"Read-only\"\n defaultValue=\"view-only-secret-key\"\n readOnly\n />\n <SensitiveInput\n label=\"With Description\"\n defaultValue=\"my-secret-value\"\n description=\"Keep this value secure and don't share it\"\n />\n </div>"
|
|
2800
|
+
],
|
|
2801
|
+
"colors": [
|
|
2802
|
+
"bg-kumo-brand",
|
|
2803
|
+
"bg-kumo-control",
|
|
2804
|
+
"outline-kumo-ring",
|
|
2805
|
+
"text-kumo-default",
|
|
2806
|
+
"text-kumo-subtle"
|
|
2807
|
+
]
|
|
2808
|
+
},
|
|
2809
|
+
"Surface": {
|
|
2810
|
+
"name": "Surface",
|
|
2811
|
+
"type": "component",
|
|
2812
|
+
"description": "Surface component",
|
|
2813
|
+
"importPath": "@cloudflare/kumo",
|
|
2814
|
+
"category": "Layout",
|
|
2815
|
+
"props": {
|
|
2816
|
+
"as": {
|
|
2817
|
+
"type": "React.ElementType",
|
|
2818
|
+
"optional": true,
|
|
2819
|
+
"description": "The element type to render as (default: \"div\")"
|
|
2820
|
+
},
|
|
2821
|
+
"className": {
|
|
2822
|
+
"type": "string",
|
|
2823
|
+
"optional": true,
|
|
2824
|
+
"description": "Additional CSS classes"
|
|
2825
|
+
},
|
|
2826
|
+
"children": {
|
|
2827
|
+
"type": "ReactNode",
|
|
2828
|
+
"optional": true,
|
|
2829
|
+
"description": "Child elements"
|
|
2830
|
+
}
|
|
2831
|
+
},
|
|
2832
|
+
"examples": [
|
|
2833
|
+
"<Surface className=\"rounded-lg p-6\">\n <Text size=\"lg\" bold>\n Surface Component\n </Text>\n <div className=\"mt-2\">\n <Text variant=\"secondary\">\n A container with consistent elevation and border styling.\n </Text>\n </div>\n </Surface>",
|
|
2834
|
+
"<div className=\"flex flex-col gap-4\">\n <Surface as=\"section\" className=\"rounded-lg p-4\">\n <Text bold>As section element</Text>\n </Surface>\n <Surface as=\"article\" className=\"rounded-lg p-4\">\n <Text bold>As article element</Text>\n </Surface>\n <Surface as=\"aside\" className=\"rounded-lg p-4\">\n <Text bold>As aside element</Text>\n </Surface>\n </div>",
|
|
2835
|
+
"<Surface className=\"rounded-lg p-6\">\n <Text bold>Outer Surface</Text>\n <Surface className=\"mt-4 rounded-md bg-kumo-elevated p-4\">\n <Text variant=\"secondary\">Nested Surface</Text>\n </Surface>\n </Surface>"
|
|
2836
|
+
],
|
|
2837
|
+
"colors": [
|
|
2838
|
+
"bg-kumo-base",
|
|
2839
|
+
"ring-kumo-line"
|
|
2840
|
+
]
|
|
2841
|
+
},
|
|
2842
|
+
"Switch": {
|
|
2843
|
+
"name": "Switch",
|
|
2844
|
+
"type": "component",
|
|
2845
|
+
"description": "Switch component",
|
|
2846
|
+
"importPath": "@cloudflare/kumo",
|
|
2847
|
+
"category": "Input",
|
|
2848
|
+
"props": {
|
|
2849
|
+
"variant": {
|
|
2850
|
+
"type": "enum",
|
|
2851
|
+
"optional": true,
|
|
2852
|
+
"description": "Visual variant: \"default\" or \"error\" for validation failures (visual only, no error text)",
|
|
2853
|
+
"values": [
|
|
2854
|
+
"default",
|
|
2855
|
+
"error"
|
|
2856
|
+
],
|
|
2857
|
+
"descriptions": {
|
|
2858
|
+
"default": "Default switch appearance",
|
|
2859
|
+
"error": "Error state for validation failures"
|
|
2860
|
+
},
|
|
2861
|
+
"classes": {
|
|
2862
|
+
"error": "ring-kumo-danger"
|
|
2863
|
+
},
|
|
2864
|
+
"default": "default"
|
|
2865
|
+
},
|
|
2866
|
+
"label": {
|
|
2867
|
+
"type": "ReactNode",
|
|
2868
|
+
"optional": true,
|
|
2869
|
+
"description": "Label content for the switch (Field wrapper is built-in) - can be a string or any React node. Optional when used standalone for visual-only purposes."
|
|
2870
|
+
},
|
|
2871
|
+
"labelTooltip": {
|
|
2872
|
+
"type": "ReactNode",
|
|
2873
|
+
"optional": true,
|
|
2874
|
+
"description": "Tooltip content to display next to the label via an info icon"
|
|
2875
|
+
},
|
|
2876
|
+
"required": {
|
|
2877
|
+
"type": "boolean",
|
|
2878
|
+
"optional": true,
|
|
2879
|
+
"description": "Whether the switch is required. When explicitly false, shows \"(optional)\" text after the label."
|
|
2880
|
+
},
|
|
2881
|
+
"controlFirst": {
|
|
2882
|
+
"type": "boolean",
|
|
2883
|
+
"optional": true,
|
|
2884
|
+
"description": "When true (default), switch appears before label. When false, label appears before switch."
|
|
2885
|
+
},
|
|
2886
|
+
"size": {
|
|
2887
|
+
"type": "enum",
|
|
2888
|
+
"optional": true,
|
|
2889
|
+
"values": [
|
|
2890
|
+
"sm",
|
|
2891
|
+
"base",
|
|
2892
|
+
"lg"
|
|
2893
|
+
],
|
|
2894
|
+
"descriptions": {
|
|
2895
|
+
"sm": "Small switch for compact UIs",
|
|
2896
|
+
"base": "Default switch size",
|
|
2897
|
+
"lg": "Large switch for prominent toggles"
|
|
2898
|
+
},
|
|
2899
|
+
"classes": {
|
|
2900
|
+
"sm": "h-5.5 w-8.5",
|
|
2901
|
+
"base": "h-6.5 w-10.5",
|
|
2902
|
+
"lg": "h-7.5 w-12.5"
|
|
2903
|
+
},
|
|
2904
|
+
"default": "base"
|
|
2905
|
+
},
|
|
2906
|
+
"checked": {
|
|
2907
|
+
"type": "boolean",
|
|
2908
|
+
"optional": true
|
|
2909
|
+
},
|
|
2910
|
+
"disabled": {
|
|
2911
|
+
"type": "boolean",
|
|
2912
|
+
"optional": true
|
|
2913
|
+
},
|
|
2914
|
+
"transitioning": {
|
|
2915
|
+
"type": "boolean",
|
|
2916
|
+
"optional": true
|
|
2917
|
+
},
|
|
2918
|
+
"name": {
|
|
2919
|
+
"type": "string",
|
|
2920
|
+
"optional": true
|
|
2921
|
+
},
|
|
2922
|
+
"type": {
|
|
2923
|
+
"type": "enum",
|
|
2924
|
+
"optional": true,
|
|
2925
|
+
"values": [
|
|
2926
|
+
"submit",
|
|
2927
|
+
"reset",
|
|
2928
|
+
"button"
|
|
2929
|
+
]
|
|
2930
|
+
},
|
|
2931
|
+
"value": {
|
|
2932
|
+
"type": "string | string[] | number",
|
|
2933
|
+
"optional": true
|
|
2934
|
+
},
|
|
2935
|
+
"className": {
|
|
2936
|
+
"type": "string",
|
|
2937
|
+
"optional": true
|
|
2938
|
+
},
|
|
2939
|
+
"id": {
|
|
2940
|
+
"type": "string",
|
|
2941
|
+
"optional": true
|
|
2942
|
+
},
|
|
2943
|
+
"lang": {
|
|
2944
|
+
"type": "string",
|
|
2945
|
+
"optional": true
|
|
2946
|
+
},
|
|
2947
|
+
"title": {
|
|
2948
|
+
"type": "string",
|
|
2949
|
+
"optional": true
|
|
2950
|
+
},
|
|
2951
|
+
"onClick": {
|
|
2952
|
+
"type": "(event: React.MouseEvent) => void",
|
|
2953
|
+
"required": true,
|
|
2954
|
+
"description": "Callback when switch is clicked"
|
|
2955
|
+
}
|
|
2956
|
+
},
|
|
2957
|
+
"examples": [
|
|
2958
|
+
"<Switch label=\"Switch\" checked={checked} onCheckedChange={setChecked} />",
|
|
2959
|
+
"<Switch label=\"Switch\" checked={false} onCheckedChange={() => {}} />",
|
|
2960
|
+
"<Switch label=\"Switch\" checked={true} onCheckedChange={() => {}} />",
|
|
2961
|
+
"<Switch label=\"Disabled\" checked={false} disabled />"
|
|
2962
|
+
],
|
|
2963
|
+
"colors": [
|
|
2964
|
+
"bg-kumo-brand",
|
|
2965
|
+
"bg-kumo-brand-hover",
|
|
2966
|
+
"bg-kumo-danger",
|
|
2967
|
+
"bg-kumo-interact",
|
|
2968
|
+
"bg-kumo-recessed",
|
|
2969
|
+
"border-kumo-line",
|
|
2970
|
+
"ring-kumo-danger",
|
|
2971
|
+
"text-kumo-danger",
|
|
2972
|
+
"text-kumo-default",
|
|
2973
|
+
"text-kumo-subtle"
|
|
2974
|
+
],
|
|
2975
|
+
"subComponents": {
|
|
2976
|
+
"Item": {
|
|
2977
|
+
"name": "Item",
|
|
2978
|
+
"description": "Item sub-component",
|
|
2979
|
+
"props": {}
|
|
2980
|
+
},
|
|
2981
|
+
"Group": {
|
|
2982
|
+
"name": "Group",
|
|
2983
|
+
"description": "Group sub-component",
|
|
2984
|
+
"props": {
|
|
2985
|
+
"legend": {
|
|
2986
|
+
"type": "string",
|
|
2987
|
+
"required": true
|
|
2988
|
+
},
|
|
2989
|
+
"children": {
|
|
2990
|
+
"type": "ReactNode",
|
|
2991
|
+
"required": true
|
|
2992
|
+
},
|
|
2993
|
+
"error": {
|
|
2994
|
+
"type": "string",
|
|
2995
|
+
"optional": true
|
|
2996
|
+
},
|
|
2997
|
+
"description": {
|
|
2998
|
+
"type": "ReactNode",
|
|
2999
|
+
"optional": true
|
|
3000
|
+
},
|
|
3001
|
+
"disabled": {
|
|
3002
|
+
"type": "boolean",
|
|
3003
|
+
"optional": true
|
|
3004
|
+
},
|
|
3005
|
+
"controlFirst": {
|
|
3006
|
+
"type": "boolean",
|
|
3007
|
+
"optional": true
|
|
3008
|
+
},
|
|
3009
|
+
"className": {
|
|
3010
|
+
"type": "string",
|
|
3011
|
+
"optional": true
|
|
3012
|
+
}
|
|
3013
|
+
}
|
|
3014
|
+
}
|
|
3015
|
+
}
|
|
3016
|
+
},
|
|
3017
|
+
"Table": {
|
|
3018
|
+
"name": "Table",
|
|
3019
|
+
"type": "component",
|
|
3020
|
+
"description": "Table component",
|
|
3021
|
+
"importPath": "@cloudflare/kumo",
|
|
3022
|
+
"category": "Other",
|
|
3023
|
+
"props": {
|
|
3024
|
+
"layout": {
|
|
3025
|
+
"type": "enum",
|
|
3026
|
+
"values": [
|
|
3027
|
+
"auto",
|
|
3028
|
+
"fixed"
|
|
3029
|
+
],
|
|
3030
|
+
"default": "auto",
|
|
3031
|
+
"descriptions": {
|
|
3032
|
+
"auto": "Auto table layout - columns resize based on content",
|
|
3033
|
+
"fixed": "Fixed table layout - columns have equal width, controlled via colgroup"
|
|
3034
|
+
}
|
|
3035
|
+
},
|
|
3036
|
+
"variant": {
|
|
3037
|
+
"type": "enum",
|
|
3038
|
+
"values": [
|
|
3039
|
+
"default",
|
|
3040
|
+
"selected"
|
|
3041
|
+
],
|
|
3042
|
+
"default": "default",
|
|
3043
|
+
"descriptions": {
|
|
3044
|
+
"default": "Default row variant",
|
|
3045
|
+
"selected": "Selected row variant"
|
|
3046
|
+
}
|
|
3047
|
+
},
|
|
3048
|
+
"className": {
|
|
3049
|
+
"type": "string",
|
|
3050
|
+
"description": "Additional CSS classes"
|
|
3051
|
+
},
|
|
3052
|
+
"children": {
|
|
3053
|
+
"type": "ReactNode",
|
|
3054
|
+
"description": "Child elements"
|
|
3055
|
+
}
|
|
3056
|
+
},
|
|
3057
|
+
"examples": [
|
|
3058
|
+
"<LayerCard>\n <LayerCard.Primary className=\"p-0\">\n <Table>\n <Table.Header>\n <Table.Row>\n <Table.Head>Subject</Table.Head>\n <Table.Head>From</Table.Head>\n <Table.Head>Date</Table.Head>\n </Table.Row>\n </Table.Header>\n <Table.Body>\n {emailData.slice(0, 3).map((row) => (\n <Table.Row key={row.id}>\n <Table.Cell>{row.subject}</Table.Cell>\n <Table.Cell>{row.from}</Table.Cell>\n <Table.Cell>{row.date}</Table.Cell>\n </Table.Row>\n ))}\n </Table.Body>\n </Table>\n </LayerCard.Primary>\n </LayerCard>",
|
|
3059
|
+
"<LayerCard>\n <LayerCard.Primary className=\"p-0\">\n <Table>\n <Table.Header>\n <Table.Row>\n <Table.CheckHead aria-label=\"Select all rows\" />\n <Table.Head>Subject</Table.Head>\n <Table.Head>From</Table.Head>\n <Table.Head>Date</Table.Head>\n </Table.Row>\n </Table.Header>\n <Table.Body>\n {emailData.slice(0, 3).map((row) => (\n <Table.Row key={row.id}>\n <Table.CheckCell aria-label={`Select ${row.subject}`} />\n <Table.Cell>{row.subject}</Table.Cell>\n <Table.Cell>{row.from}</Table.Cell>\n <Table.Cell>{row.date}</Table.Cell>\n </Table.Row>\n ))}\n </Table.Body>\n </Table>\n </LayerCard.Primary>\n </LayerCard>",
|
|
3060
|
+
"<LayerCard>\n <LayerCard.Primary className=\"p-0\">\n <Table>\n <Table.Header>\n <Table.Row>\n <Table.CheckHead aria-label=\"Select all rows\" />\n <Table.Head>Subject</Table.Head>\n <Table.Head>From</Table.Head>\n <Table.Head>Date</Table.Head>\n </Table.Row>\n </Table.Header>\n <Table.Body>\n <Table.Row>\n <Table.CheckCell aria-label=\"Select row 1\" />\n <Table.Cell>Kumo v1.0.0 released</Table.Cell>\n <Table.Cell>Visal In</Table.Cell>\n <Table.Cell>5 seconds ago</Table.Cell>\n </Table.Row>\n <Table.Row variant=\"selected\">\n <Table.CheckCell checked aria-label=\"Select row 2\" />\n <Table.Cell>New Job Offer</Table.Cell>\n <Table.Cell>Cloudflare</Table.Cell>\n <Table.Cell>10 minutes ago</Table.Cell>\n </Table.Row>\n <Table.Row>\n <Table.CheckCell aria-label=\"Select row 3\" />\n <Table.Cell>Daily Email Digest</Table.Cell>\n <Table.Cell>Cloudflare</Table.Cell>\n <Table.Cell>1 hour ago</Table.Cell>\n </Table.Row>\n </Table.Body>\n </Table>\n </LayerCard.Primary>\n </LayerCard>",
|
|
3061
|
+
"<LayerCard>\n <LayerCard.Primary className=\"p-0\">\n <Table layout=\"fixed\">\n <colgroup>\n <col />\n <col className=\"w-[150px]\" />\n <col className=\"w-[150px]\" />\n </colgroup>\n <Table.Header>\n <Table.Row>\n <Table.Head>Subject</Table.Head>\n <Table.Head>From</Table.Head>\n <Table.Head>Date</Table.Head>\n </Table.Row>\n </Table.Header>\n <Table.Body>\n {emailData.map((row) => (\n <Table.Row key={row.id}>\n <Table.Cell>{row.subject}</Table.Cell>\n <Table.Cell>{row.from}</Table.Cell>\n <Table.Cell>{row.date}</Table.Cell>\n </Table.Row>\n ))}\n </Table.Body>\n </Table>\n </LayerCard.Primary>\n </LayerCard>",
|
|
3062
|
+
"<LayerCard>\n <LayerCard.Primary className=\"w-full overflow-x-auto p-0\">\n <Table layout=\"fixed\">\n <colgroup>\n <col style={{ width: \"40px\" }} />\n <col />\n <col style={{ width: \"150px\" }} />\n <col style={{ width: \"120px\" }} />\n <col style={{ width: \"50px\" }} />\n </colgroup>\n <Table.Header>\n <Table.Row>\n <Table.CheckHead aria-label=\"Select all rows\" />\n <Table.Head>Subject</Table.Head>\n <Table.Head>From</Table.Head>\n <Table.Head>Date</Table.Head>\n <Table.Head></Table.Head>\n </Table.Row>\n </Table.Header>\n <Table.Body>\n {emailData.map((row, index) => (\n <Table.Row\n key={row.id}\n variant={index === 1 ? \"selected\" : \"default\"}\n >\n <Table.CheckCell\n checked={index === 1}\n aria-label={`Select ${row.subject}`}\n />\n <Table.Cell>\n <div className=\"flex items-center gap-2\">\n <EnvelopeSimple size={16} />\n <span className=\"truncate\">{row.subject}</span>\n {row.tags && (\n <div className=\"ml-2 inline-flex gap-1\">\n {row.tags.map((tag) => (\n <Badge key={tag}>{tag}</Badge>\n ))}\n </div>\n )}\n </div>\n </Table.Cell>\n <Table.Cell>\n <span className=\"truncate\">{row.from}</span>\n </Table.Cell>\n <Table.Cell>\n <span className=\"truncate\">{row.date}</span>\n </Table.Cell>\n <Table.Cell className=\"text-right\">\n <Button\n variant=\"ghost\"\n size=\"sm\"\n shape=\"square\"\n aria-label=\"More options\"\n >\n <DotsThree weight=\"bold\" size={16} />\n </Button>\n </Table.Cell>\n </Table.Row>\n ))}\n </Table.Body>\n </Table>\n </LayerCard.Primary>\n </LayerCard>"
|
|
3063
|
+
],
|
|
3064
|
+
"colors": [
|
|
3065
|
+
"bg-kumo-base",
|
|
3066
|
+
"bg-kumo-ring",
|
|
3067
|
+
"bg-kumo-tint",
|
|
3068
|
+
"border-kumo-fill",
|
|
3069
|
+
"text-kumo-default"
|
|
3070
|
+
],
|
|
3071
|
+
"subComponents": {
|
|
3072
|
+
"Header": {
|
|
3073
|
+
"name": "Header",
|
|
3074
|
+
"description": "Header sub-component",
|
|
3075
|
+
"props": {}
|
|
3076
|
+
},
|
|
3077
|
+
"Head": {
|
|
3078
|
+
"name": "Head",
|
|
3079
|
+
"description": "Head sub-component",
|
|
3080
|
+
"props": {}
|
|
3081
|
+
},
|
|
3082
|
+
"Row": {
|
|
3083
|
+
"name": "Row",
|
|
3084
|
+
"description": "Row sub-component",
|
|
3085
|
+
"props": {}
|
|
3086
|
+
},
|
|
3087
|
+
"Body": {
|
|
3088
|
+
"name": "Body",
|
|
3089
|
+
"description": "Body sub-component",
|
|
3090
|
+
"props": {}
|
|
3091
|
+
},
|
|
3092
|
+
"Cell": {
|
|
3093
|
+
"name": "Cell",
|
|
3094
|
+
"description": "Cell sub-component",
|
|
3095
|
+
"props": {}
|
|
3096
|
+
},
|
|
3097
|
+
"CheckCell": {
|
|
3098
|
+
"name": "CheckCell",
|
|
3099
|
+
"description": "CheckCell sub-component",
|
|
3100
|
+
"props": {}
|
|
3101
|
+
},
|
|
3102
|
+
"CheckHead": {
|
|
3103
|
+
"name": "CheckHead",
|
|
3104
|
+
"description": "CheckHead sub-component",
|
|
3105
|
+
"props": {}
|
|
3106
|
+
},
|
|
3107
|
+
"Footer": {
|
|
3108
|
+
"name": "Footer",
|
|
3109
|
+
"description": "Footer sub-component",
|
|
3110
|
+
"props": {}
|
|
3111
|
+
},
|
|
3112
|
+
"ResizeHandle": {
|
|
3113
|
+
"name": "ResizeHandle",
|
|
3114
|
+
"description": "ResizeHandle sub-component",
|
|
3115
|
+
"props": {}
|
|
3116
|
+
}
|
|
3117
|
+
}
|
|
3118
|
+
},
|
|
3119
|
+
"Tabs": {
|
|
3120
|
+
"name": "Tabs",
|
|
3121
|
+
"type": "component",
|
|
3122
|
+
"description": "Tabs component",
|
|
3123
|
+
"importPath": "@cloudflare/kumo",
|
|
3124
|
+
"category": "Navigation",
|
|
3125
|
+
"props": {
|
|
3126
|
+
"tabs": {
|
|
3127
|
+
"type": "TabsItem[]",
|
|
3128
|
+
"optional": true,
|
|
3129
|
+
"description": "Array of tab items to render"
|
|
3130
|
+
},
|
|
3131
|
+
"value": {
|
|
3132
|
+
"type": "string",
|
|
3133
|
+
"optional": true,
|
|
3134
|
+
"description": "Controlled value. When set, component becomes controlled."
|
|
3135
|
+
},
|
|
3136
|
+
"selectedValue": {
|
|
3137
|
+
"type": "string",
|
|
3138
|
+
"optional": true,
|
|
3139
|
+
"description": "Default selected value for uncontrolled mode. Ignored when `value` is set."
|
|
3140
|
+
},
|
|
3141
|
+
"activateOnFocus": {
|
|
3142
|
+
"type": "boolean",
|
|
3143
|
+
"optional": true,
|
|
3144
|
+
"description": "When true, tabs are activated immediately upon receiving focus via arrow keys. When false (default), tabs receive focus but require Enter/Space to activate. Set to true for better keyboard UX in most cases."
|
|
3145
|
+
},
|
|
3146
|
+
"className": {
|
|
3147
|
+
"type": "string",
|
|
3148
|
+
"optional": true,
|
|
3149
|
+
"description": "Additional class name for the root element"
|
|
3150
|
+
},
|
|
3151
|
+
"listClassName": {
|
|
3152
|
+
"type": "string",
|
|
3153
|
+
"optional": true,
|
|
3154
|
+
"description": "Additional class name for the tab list element"
|
|
3155
|
+
},
|
|
3156
|
+
"indicatorClassName": {
|
|
3157
|
+
"type": "string",
|
|
3158
|
+
"optional": true,
|
|
3159
|
+
"description": "Additional class name for the indicator element"
|
|
3160
|
+
},
|
|
3161
|
+
"variant": {
|
|
3162
|
+
"type": "enum",
|
|
3163
|
+
"optional": true,
|
|
3164
|
+
"values": [
|
|
3165
|
+
"segmented",
|
|
3166
|
+
"underline"
|
|
3167
|
+
],
|
|
3168
|
+
"default": "segmented"
|
|
3169
|
+
},
|
|
3170
|
+
"onValueChange": {
|
|
3171
|
+
"type": "(value: string) => void",
|
|
3172
|
+
"description": "Callback when active tab changes"
|
|
3173
|
+
}
|
|
3174
|
+
},
|
|
3175
|
+
"examples": [
|
|
3176
|
+
"<div className=\"flex flex-col gap-6\">\n <div>\n <p className=\"mb-2 text-sm text-kumo-subtle\">Segmented (default)</p>\n <Tabs\n variant=\"segmented\"\n tabs={[\n { value: \"tab1\", label: \"Tab 1\" },\n { value: \"tab2\", label: \"Tab 2\" },\n { value: \"tab3\", label: \"Tab 3\" },\n ]}\n selectedValue=\"tab1\"\n />\n </div>\n <div>\n <p className=\"mb-2 text-sm text-kumo-subtle\">Underline</p>\n <Tabs\n variant=\"underline\"\n tabs={[\n { value: \"tab1\", label: \"Tab 1\" },\n { value: \"tab2\", label: \"Tab 2\" },\n { value: \"tab3\", label: \"Tab 3\" },\n ]}\n selectedValue=\"tab1\"\n />\n </div>\n </div>",
|
|
3177
|
+
"<Tabs\n variant=\"segmented\"\n tabs={[\n { value: \"tab1\", label: \"Tab 1\" },\n { value: \"tab2\", label: \"Tab 2\" },\n { value: \"tab3\", label: \"Tab 3\" },\n ]}\n selectedValue=\"tab1\"\n />",
|
|
3178
|
+
"<Tabs\n variant=\"underline\"\n tabs={[\n { value: \"tab1\", label: \"Tab 1\" },\n { value: \"tab2\", label: \"Tab 2\" },\n { value: \"tab3\", label: \"Tab 3\" },\n ]}\n selectedValue=\"tab1\"\n />",
|
|
3179
|
+
"<div className=\"space-y-4\">\n <Tabs\n tabs={[\n { value: \"tab1\", label: \"Tab 1\" },\n { value: \"tab2\", label: \"Tab 2\" },\n { value: \"tab3\", label: \"Tab 3\" },\n ]}\n value={activeTab}\n onValueChange={setActiveTab}\n />\n <p className=\"text-sm text-kumo-subtle\">\n Active tab: <code className=\"text-sm\">{activeTab}</code>\n </p>\n </div>",
|
|
3180
|
+
"<Tabs\n tabs={[\n { value: \"overview\", label: \"Overview\" },\n { value: \"analytics\", label: \"Analytics\" },\n { value: \"reports\", label: \"Reports\" },\n { value: \"notifications\", label: \"Notifications\" },\n { value: \"settings\", label: \"Settings\" },\n { value: \"billing\", label: \"Billing\" },\n ]}\n selectedValue=\"overview\"\n />",
|
|
3181
|
+
"<Tabs\n tabs={[\n {\n value: \"tab1\",\n label: \"Regular Tab\",\n },\n {\n value: \"tab2\",\n label: \"Link Tab\",\n render: (props) => <a {...props} href=\"#tab2\" />,\n },\n {\n value: \"tab3\",\n label: \"Another Link\",\n render: (props) => <a {...props} href=\"#tab3\" />,\n },\n ]}\n selectedValue=\"tab1\"\n />"
|
|
3182
|
+
],
|
|
3183
|
+
"colors": [
|
|
3184
|
+
"bg-kumo-brand",
|
|
3185
|
+
"bg-kumo-overlay",
|
|
3186
|
+
"bg-kumo-tint",
|
|
3187
|
+
"border-kumo-line",
|
|
3188
|
+
"border-kumo-tint",
|
|
3189
|
+
"ring-kumo-fill-hover",
|
|
3190
|
+
"ring-kumo-ring",
|
|
3191
|
+
"text-kumo-default",
|
|
3192
|
+
"text-kumo-strong",
|
|
3193
|
+
"text-kumo-subtle"
|
|
3194
|
+
],
|
|
3195
|
+
"styling": {
|
|
3196
|
+
"container": {
|
|
3197
|
+
"height": 34,
|
|
3198
|
+
"borderRadius": 8,
|
|
3199
|
+
"background": "color-accent",
|
|
3200
|
+
"padding": 1
|
|
3201
|
+
},
|
|
3202
|
+
"tab": {
|
|
3203
|
+
"paddingX": 10,
|
|
3204
|
+
"verticalMargin": 1,
|
|
3205
|
+
"fontSize": 16,
|
|
3206
|
+
"fontWeight": 500,
|
|
3207
|
+
"borderRadius": 8,
|
|
3208
|
+
"activeColor": "text-color-surface",
|
|
3209
|
+
"inactiveColor": "text-color-label"
|
|
3210
|
+
},
|
|
3211
|
+
"indicator": {
|
|
3212
|
+
"background": "color-surface-secondary",
|
|
3213
|
+
"ring": "color-color-2",
|
|
3214
|
+
"borderRadius": 6,
|
|
3215
|
+
"shadow": "shadow-sm"
|
|
3216
|
+
}
|
|
3217
|
+
}
|
|
3218
|
+
},
|
|
3219
|
+
"Text": {
|
|
3220
|
+
"name": "Text",
|
|
3221
|
+
"type": "component",
|
|
3222
|
+
"description": "Text component",
|
|
3223
|
+
"importPath": "@cloudflare/kumo",
|
|
3224
|
+
"category": "Display",
|
|
3225
|
+
"props": {
|
|
3226
|
+
"variant": {
|
|
3227
|
+
"type": "enum",
|
|
3228
|
+
"optional": true,
|
|
3229
|
+
"description": "Text style variant",
|
|
3230
|
+
"values": [
|
|
3231
|
+
"heading1",
|
|
3232
|
+
"heading2",
|
|
3233
|
+
"heading3",
|
|
3234
|
+
"body",
|
|
3235
|
+
"secondary",
|
|
3236
|
+
"success",
|
|
3237
|
+
"error",
|
|
3238
|
+
"mono",
|
|
3239
|
+
"mono-secondary"
|
|
3240
|
+
],
|
|
3241
|
+
"descriptions": {
|
|
3242
|
+
"heading1": "Large heading for page titles",
|
|
3243
|
+
"heading2": "Medium heading for section titles",
|
|
3244
|
+
"heading3": "Small heading for subsections",
|
|
3245
|
+
"body": "Default body text",
|
|
3246
|
+
"secondary": "Muted text for secondary information",
|
|
3247
|
+
"success": "Success state text",
|
|
3248
|
+
"error": "Error state text",
|
|
3249
|
+
"mono": "Monospace text for code",
|
|
3250
|
+
"mono-secondary": "Muted monospace text"
|
|
3251
|
+
},
|
|
3252
|
+
"classes": {
|
|
3253
|
+
"heading1": "text-3xl font-semibold",
|
|
3254
|
+
"heading2": "text-2xl font-semibold",
|
|
3255
|
+
"heading3": "text-lg font-semibold",
|
|
3256
|
+
"body": "text-kumo-default",
|
|
3257
|
+
"secondary": "text-kumo-subtle",
|
|
3258
|
+
"success": "text-kumo-link",
|
|
3259
|
+
"error": "text-kumo-danger",
|
|
3260
|
+
"mono": "font-mono",
|
|
3261
|
+
"mono-secondary": "font-mono text-kumo-subtle"
|
|
3262
|
+
},
|
|
3263
|
+
"default": "body"
|
|
3264
|
+
},
|
|
3265
|
+
"size": {
|
|
3266
|
+
"type": "enum",
|
|
3267
|
+
"optional": true,
|
|
3268
|
+
"description": "Text size (only applies to body/secondary/success/error variants)",
|
|
3269
|
+
"values": [
|
|
3270
|
+
"xs",
|
|
3271
|
+
"sm",
|
|
3272
|
+
"base",
|
|
3273
|
+
"lg"
|
|
3274
|
+
],
|
|
3275
|
+
"descriptions": {
|
|
3276
|
+
"xs": "Extra small text",
|
|
3277
|
+
"sm": "Small text",
|
|
3278
|
+
"base": "Default text size",
|
|
3279
|
+
"lg": "Large text"
|
|
3280
|
+
},
|
|
3281
|
+
"classes": {
|
|
3282
|
+
"xs": "text-xs",
|
|
3283
|
+
"sm": "text-sm",
|
|
3284
|
+
"base": "text-base",
|
|
3285
|
+
"lg": "text-lg"
|
|
3286
|
+
},
|
|
3287
|
+
"default": "base"
|
|
3288
|
+
},
|
|
3289
|
+
"bold": {
|
|
3290
|
+
"type": "boolean",
|
|
3291
|
+
"optional": true,
|
|
3292
|
+
"description": "Whether to use bold font weight (only applies to body variants)"
|
|
3293
|
+
},
|
|
3294
|
+
"as": {
|
|
3295
|
+
"type": "React.ElementType",
|
|
3296
|
+
"optional": true,
|
|
3297
|
+
"description": "The element type to render as"
|
|
3298
|
+
},
|
|
3299
|
+
"children": {
|
|
3300
|
+
"type": "ReactNode",
|
|
3301
|
+
"optional": true,
|
|
3302
|
+
"description": "Child text content"
|
|
3303
|
+
}
|
|
3304
|
+
},
|
|
3305
|
+
"examples": [
|
|
3306
|
+
"<div className=\"grid w-full grid-cols-1 gap-4 md:grid-cols-2 lg:grid-cols-3\">\n <div className=\"flex flex-col justify-end gap-1 rounded-lg border border-kumo-line bg-kumo-base p-4\">\n <Text variant=\"heading1\">Heading 1</Text>\n <p className=\"font-mono text-xs text-kumo-subtle\">text-3xl (30px)</p>\n </div>\n <div className=\"flex flex-col justify-end gap-1 rounded-lg border border-kumo-line bg-kumo-base p-4\">\n <Text variant=\"heading2\">Heading 2</Text>\n <p className=\"font-mono text-xs text-kumo-subtle\">text-2xl (24px)</p>\n </div>\n <div className=\"flex flex-col justify-end gap-1 rounded-lg border border-kumo-line bg-kumo-base p-4\">\n <Text variant=\"heading3\">Heading 3</Text>\n <p className=\"font-mono text-xs text-kumo-subtle\">text-lg (16px)</p>\n </div>\n <div className=\"flex flex-col justify-end gap-1 rounded-lg border border-kumo-line bg-kumo-base p-4\">\n <Text>Body</Text>\n <p className=\"font-mono text-xs text-kumo-subtle\">text-base (14px)</p>\n </div>\n <div className=\"flex flex-col justify-end gap-1 rounded-lg border border-kumo-line bg-kumo-base p-4\">\n <Text bold>Body bold</Text>\n <p className=\"font-mono text-xs text-kumo-subtle\">text-base (14px)</p>\n </div>\n <div className=\"flex flex-col justify-end gap-1 rounded-lg border border-kumo-line bg-kumo-base p-4\">\n <Text size=\"lg\">Body lg</Text>\n <p className=\"font-mono text-xs text-kumo-subtle\">text-lg (16px)</p>\n </div>\n <div className=\"flex flex-col justify-end gap-1 rounded-lg border border-kumo-line bg-kumo-base p-4\">\n <Text size=\"sm\">Body sm</Text>\n <p className=\"font-mono text-xs text-kumo-subtle\">text-sm (13px)</p>\n </div>\n <div className=\"flex flex-col justify-end gap-1 rounded-lg border border-kumo-line bg-kumo-base p-4\">\n <Text size=\"xs\">Body xs</Text>\n <p className=\"font-mono text-xs text-kumo-subtle\">text-xs (12px)</p>\n </div>\n <div className=\"flex flex-col justify-end gap-1 rounded-lg border border-kumo-line bg-kumo-base p-4\">\n <Text variant=\"secondary\">Body secondary</Text>\n <p className=\"font-mono text-xs text-kumo-subtle\">text-base (14px)</p>\n </div>\n <div className=\"flex flex-col justify-end gap-1 rounded-lg border border-kumo-line bg-kumo-base p-4\">\n <Text variant=\"mono\">Monospace</Text>\n <p className=\"font-mono text-xs text-kumo-subtle\">text-sm (13px)</p>\n </div>\n <div className=\"flex flex-col justify-end gap-1 rounded-lg border border-kumo-line bg-kumo-base p-4\">\n <Text variant=\"mono\" size=\"lg\">\n Monospace lg\n </Text>\n <p className=\"font-mono text-xs text-kumo-subtle\">text-base (14px)</p>\n </div>\n <div className=\"flex flex-col justify-end gap-1 rounded-lg border border-kumo-line bg-kumo-base p-4\">\n <Text variant=\"mono-secondary\">Monospace secondary</Text>\n <p className=\"font-mono text-xs text-kumo-subtle\">text-sm (13px)</p>\n </div>\n <div className=\"flex flex-col justify-end gap-1 rounded-lg border border-kumo-line bg-kumo-base p-4\">\n <Text variant=\"success\">Success</Text>\n <p className=\"font-mono text-xs text-kumo-subtle\">text-base (14px)</p>\n </div>\n <div className=\"flex flex-col justify-end gap-1 rounded-lg border border-kumo-line bg-kumo-base p-4\">\n <Text variant=\"error\">Error</Text>\n <p className=\"font-mono text-xs text-kumo-subtle\">text-base (14px)</p>\n </div>\n </div>"
|
|
3307
|
+
],
|
|
3308
|
+
"colors": [
|
|
3309
|
+
"text-kumo-danger",
|
|
3310
|
+
"text-kumo-default",
|
|
3311
|
+
"text-kumo-link",
|
|
3312
|
+
"text-kumo-subtle"
|
|
3313
|
+
],
|
|
3314
|
+
"styling": {
|
|
3315
|
+
"fontSizes": {
|
|
3316
|
+
"xs": 12,
|
|
3317
|
+
"sm": 14,
|
|
3318
|
+
"base": 16,
|
|
3319
|
+
"lg": 18,
|
|
3320
|
+
"xl": 20,
|
|
3321
|
+
"2xl": 24,
|
|
3322
|
+
"3xl": 30
|
|
3323
|
+
},
|
|
3324
|
+
"fontWeights": {
|
|
3325
|
+
"normal": 400,
|
|
3326
|
+
"medium": 500,
|
|
3327
|
+
"semibold": 600
|
|
3328
|
+
},
|
|
3329
|
+
"baseColor": "text-kumo-default",
|
|
3330
|
+
"variantColors": {
|
|
3331
|
+
"body": "text-kumo-default",
|
|
3332
|
+
"secondary": "text-kumo-subtle",
|
|
3333
|
+
"success": "text-kumo-link",
|
|
3334
|
+
"error": "text-kumo-danger",
|
|
3335
|
+
"mono": "text-kumo-default",
|
|
3336
|
+
"mono-secondary": "text-kumo-subtle"
|
|
3337
|
+
},
|
|
3338
|
+
"fontFamilies": {
|
|
3339
|
+
"default": "sans-serif",
|
|
3340
|
+
"mono": "monospace"
|
|
3341
|
+
}
|
|
3342
|
+
}
|
|
3343
|
+
},
|
|
3344
|
+
"Toasty": {
|
|
3345
|
+
"name": "Toasty",
|
|
3346
|
+
"type": "component",
|
|
3347
|
+
"description": "Toasty component",
|
|
3348
|
+
"importPath": "@cloudflare/kumo",
|
|
3349
|
+
"category": "Feedback",
|
|
3350
|
+
"props": {
|
|
3351
|
+
"children": {
|
|
3352
|
+
"type": "ReactNode",
|
|
3353
|
+
"optional": true
|
|
3354
|
+
}
|
|
3355
|
+
},
|
|
3356
|
+
"examples": [],
|
|
3357
|
+
"colors": [
|
|
3358
|
+
"bg-kumo-control",
|
|
3359
|
+
"bg-kumo-fill-hover",
|
|
3360
|
+
"border-kumo-fill",
|
|
3361
|
+
"text-kumo-default",
|
|
3362
|
+
"text-kumo-strong",
|
|
3363
|
+
"text-kumo-subtle"
|
|
3364
|
+
],
|
|
3365
|
+
"styling": {
|
|
3366
|
+
"container": {
|
|
3367
|
+
"width": 300,
|
|
3368
|
+
"padding": 16,
|
|
3369
|
+
"borderRadius": 8,
|
|
3370
|
+
"background": "color-secondary",
|
|
3371
|
+
"border": "color-color",
|
|
3372
|
+
"shadow": "shadow-lg",
|
|
3373
|
+
"gap": 4
|
|
3374
|
+
},
|
|
3375
|
+
"title": {
|
|
3376
|
+
"fontSize": 16,
|
|
3377
|
+
"fontWeight": 500,
|
|
3378
|
+
"color": "text-color-surface"
|
|
3379
|
+
},
|
|
3380
|
+
"description": {
|
|
3381
|
+
"fontSize": 15,
|
|
3382
|
+
"fontWeight": 400,
|
|
3383
|
+
"color": "text-color-muted"
|
|
3384
|
+
},
|
|
3385
|
+
"closeButton": {
|
|
3386
|
+
"size": 20,
|
|
3387
|
+
"iconSize": 16,
|
|
3388
|
+
"iconName": "ph-x",
|
|
3389
|
+
"iconColor": "text-color-muted",
|
|
3390
|
+
"hoverBackground": "color-color-2",
|
|
3391
|
+
"hoverColor": "text-color-label",
|
|
3392
|
+
"borderRadius": 4
|
|
3393
|
+
}
|
|
3394
|
+
}
|
|
3395
|
+
},
|
|
3396
|
+
"Tooltip": {
|
|
3397
|
+
"name": "Tooltip",
|
|
3398
|
+
"type": "component",
|
|
3399
|
+
"description": "Tooltip component",
|
|
3400
|
+
"importPath": "@cloudflare/kumo",
|
|
3401
|
+
"category": "Overlay",
|
|
3402
|
+
"props": {
|
|
3403
|
+
"align": {
|
|
3404
|
+
"type": "enum",
|
|
3405
|
+
"optional": true,
|
|
3406
|
+
"values": [
|
|
3407
|
+
"start",
|
|
3408
|
+
"center",
|
|
3409
|
+
"end"
|
|
3410
|
+
]
|
|
3411
|
+
},
|
|
3412
|
+
"asChild": {
|
|
3413
|
+
"type": "boolean",
|
|
3414
|
+
"optional": true
|
|
3415
|
+
},
|
|
3416
|
+
"className": {
|
|
3417
|
+
"type": "string",
|
|
3418
|
+
"optional": true
|
|
3419
|
+
},
|
|
3420
|
+
"side": {
|
|
3421
|
+
"type": "enum",
|
|
3422
|
+
"optional": true,
|
|
3423
|
+
"values": [
|
|
3424
|
+
"top",
|
|
3425
|
+
"bottom",
|
|
3426
|
+
"left",
|
|
3427
|
+
"right"
|
|
3428
|
+
],
|
|
3429
|
+
"descriptions": {
|
|
3430
|
+
"top": "Tooltip appears above the trigger",
|
|
3431
|
+
"bottom": "Tooltip appears below the trigger",
|
|
3432
|
+
"left": "Tooltip appears to the left of the trigger",
|
|
3433
|
+
"right": "Tooltip appears to the right of the trigger"
|
|
3434
|
+
},
|
|
3435
|
+
"default": "top"
|
|
3436
|
+
},
|
|
3437
|
+
"content": {
|
|
3438
|
+
"type": "ReactNode",
|
|
3439
|
+
"required": true,
|
|
3440
|
+
"description": "Content to display in the tooltip"
|
|
3441
|
+
}
|
|
3442
|
+
},
|
|
3443
|
+
"examples": [
|
|
3444
|
+
"<TooltipProvider>\n <Tooltip content=\"Add new item\" asChild>\n <Button shape=\"square\" icon={PlusIcon} />\n </Tooltip>\n </TooltipProvider>",
|
|
3445
|
+
"<TooltipProvider>\n <Tooltip content=\"Add\" asChild>\n <Button shape=\"square\" icon={PlusIcon} />\n </Tooltip>\n </TooltipProvider>",
|
|
3446
|
+
"<TooltipProvider>\n <div className=\"flex gap-2\">\n <Tooltip content=\"Add\" asChild>\n <Button shape=\"square\" icon={PlusIcon} />\n </Tooltip>\n <Tooltip content=\"Change language\" asChild>\n <Button shape=\"square\" icon={TranslateIcon} />\n </Tooltip>\n </div>\n </TooltipProvider>"
|
|
3447
|
+
],
|
|
3448
|
+
"colors": [
|
|
3449
|
+
"bg-kumo-base",
|
|
3450
|
+
"fill-kumo-base",
|
|
3451
|
+
"fill-kumo-tip-shadow",
|
|
3452
|
+
"fill-kumo-tip-stroke",
|
|
3453
|
+
"outline-kumo-fill",
|
|
3454
|
+
"text-kumo-default"
|
|
3455
|
+
]
|
|
3456
|
+
},
|
|
3457
|
+
"InputArea": {
|
|
3458
|
+
"name": "InputArea",
|
|
3459
|
+
"type": "component",
|
|
3460
|
+
"description": "Multi-line textarea input with Input variants and InputArea-specific dimensions",
|
|
3461
|
+
"importPath": "@cloudflare/kumo (synthetic - uses Input component)",
|
|
3462
|
+
"category": "Input",
|
|
3463
|
+
"props": {},
|
|
3464
|
+
"styling": {
|
|
3465
|
+
"sizeVariants": {
|
|
3466
|
+
"xs": {
|
|
3467
|
+
"minHeight": 60,
|
|
3468
|
+
"width": 200
|
|
3469
|
+
},
|
|
3470
|
+
"sm": {
|
|
3471
|
+
"minHeight": 72,
|
|
3472
|
+
"width": 240
|
|
3473
|
+
},
|
|
3474
|
+
"base": {
|
|
3475
|
+
"minHeight": 88,
|
|
3476
|
+
"width": 320
|
|
3477
|
+
},
|
|
3478
|
+
"lg": {
|
|
3479
|
+
"minHeight": 100,
|
|
3480
|
+
"width": 360
|
|
3481
|
+
}
|
|
3482
|
+
}
|
|
3483
|
+
},
|
|
3484
|
+
"examples": [],
|
|
3485
|
+
"colors": []
|
|
3486
|
+
}
|
|
3487
|
+
},
|
|
3488
|
+
"blocks": {
|
|
3489
|
+
"PageHeader": {
|
|
3490
|
+
"name": "PageHeader",
|
|
3491
|
+
"type": "block",
|
|
3492
|
+
"description": "PageHeader component",
|
|
3493
|
+
"importPath": "@cloudflare/kumo",
|
|
3494
|
+
"category": "Layout",
|
|
3495
|
+
"props": {
|
|
3496
|
+
"spacing": {
|
|
3497
|
+
"type": "enum",
|
|
3498
|
+
"optional": true,
|
|
3499
|
+
"values": [
|
|
3500
|
+
"compact",
|
|
3501
|
+
"base",
|
|
3502
|
+
"relaxed"
|
|
3503
|
+
],
|
|
3504
|
+
"descriptions": {
|
|
3505
|
+
"compact": "Compact spacing between header elements",
|
|
3506
|
+
"base": "Default spacing between header elements",
|
|
3507
|
+
"relaxed": "Relaxed spacing for more prominent headers"
|
|
3508
|
+
},
|
|
3509
|
+
"classes": {
|
|
3510
|
+
"compact": "gap-1",
|
|
3511
|
+
"base": "gap-2",
|
|
3512
|
+
"relaxed": "gap-4"
|
|
3513
|
+
},
|
|
3514
|
+
"default": "base"
|
|
3515
|
+
},
|
|
3516
|
+
"breadcrumbs": {
|
|
3517
|
+
"type": "ReactNode",
|
|
3518
|
+
"optional": true
|
|
3519
|
+
},
|
|
3520
|
+
"title": {
|
|
3521
|
+
"type": "string",
|
|
3522
|
+
"optional": true
|
|
3523
|
+
},
|
|
3524
|
+
"description": {
|
|
3525
|
+
"type": "string",
|
|
3526
|
+
"optional": true
|
|
3527
|
+
},
|
|
3528
|
+
"tabs": {
|
|
3529
|
+
"type": "TabsItem[]",
|
|
3530
|
+
"optional": true
|
|
3531
|
+
},
|
|
3532
|
+
"defaultTab": {
|
|
3533
|
+
"type": "string",
|
|
3534
|
+
"optional": true
|
|
3535
|
+
},
|
|
3536
|
+
"className": {
|
|
3537
|
+
"type": "string",
|
|
3538
|
+
"optional": true
|
|
3539
|
+
},
|
|
3540
|
+
"children": {
|
|
3541
|
+
"type": "ReactNode",
|
|
3542
|
+
"optional": true
|
|
3543
|
+
}
|
|
3544
|
+
},
|
|
3545
|
+
"examples": [
|
|
3546
|
+
"<PageHeader\n className=\"w-full\"\n breadcrumbs={\n <Breadcrumbs>\n <Breadcrumbs.Link icon={<HouseIcon size={16} />} href=\"#\">\n Workers & Pages\n </Breadcrumbs.Link>\n <Breadcrumbs.Separator />\n <Breadcrumbs.Current>cloudflare-dev-platform</Breadcrumbs.Current>\n </Breadcrumbs>\n }\n tabs={[\n { label: \"Overview\", value: \"overview\" },\n { label: \"Metrics\", value: \"metrics\" },\n { label: \"Deployments\", value: \"deployments\" },\n { label: \"Bindings\", value: \"bindings\" },\n { label: \"Observability\", value: \"observability\" },\n { label: \"Settings\", value: \"settings\" },\n ]}\n defaultTab=\"overview\"\n onValueChange={(v) => console.log(v)}\n >\n <Button icon={<CodeIcon />} className=\"h-8\">\n Edit code\n </Button>\n <Button icon={<GlobeIcon />} variant=\"primary\" className=\"h-8\">\n Visit\n </Button>\n </PageHeader>",
|
|
3547
|
+
"<PageHeader\n breadcrumbs={\n <Breadcrumbs>\n <Breadcrumbs.Link href=\"#\">Home</Breadcrumbs.Link>\n <Breadcrumbs.Separator />\n <Breadcrumbs.Current>Dashboard</Breadcrumbs.Current>\n </Breadcrumbs>\n }\n />",
|
|
3548
|
+
"<PageHeader\n breadcrumbs={\n <Breadcrumbs>\n <Breadcrumbs.Link icon={<HouseIcon size={16} />} href=\"#\">\n Home\n </Breadcrumbs.Link>\n <Breadcrumbs.Separator />\n <Breadcrumbs.Current icon={<GearIcon size={16} />}>\n Settings\n </Breadcrumbs.Current>\n </Breadcrumbs>\n }\n />",
|
|
3549
|
+
"<PageHeader\n breadcrumbs={\n <Breadcrumbs>\n <Breadcrumbs.Link href=\"#\">Home</Breadcrumbs.Link>\n <Breadcrumbs.Separator />\n <Breadcrumbs.Current>Settings</Breadcrumbs.Current>\n </Breadcrumbs>\n }\n tabs={[\n { label: \"General\", value: \"general\" },\n { label: \"Security\", value: \"security\" },\n { label: \"Notifications\", value: \"notifications\" },\n ]}\n defaultTab=\"general\"\n />",
|
|
3550
|
+
"<PageHeader\n breadcrumbs={\n <Breadcrumbs>\n <Breadcrumbs.Link href=\"#\">Home</Breadcrumbs.Link>\n <Breadcrumbs.Separator />\n <Breadcrumbs.Link href=\"#\">Projects</Breadcrumbs.Link>\n <Breadcrumbs.Separator />\n <Breadcrumbs.Current>My Project</Breadcrumbs.Current>\n </Breadcrumbs>\n }\n tabs={[\n { label: \"Overview\", value: \"overview\" },\n { label: \"Settings\", value: \"settings\" },\n ]}\n defaultTab=\"overview\"\n >\n <Button variant=\"primary\" size=\"base\">\n Deploy\n </Button>\n </PageHeader>",
|
|
3551
|
+
"<PageHeader\n breadcrumbs={\n <Breadcrumbs>\n <Breadcrumbs.Link href=\"#\">Home</Breadcrumbs.Link>\n <Breadcrumbs.Separator />\n <Breadcrumbs.Link href=\"#\">Products</Breadcrumbs.Link>\n <Breadcrumbs.Separator />\n <Breadcrumbs.Current>Page title</Breadcrumbs.Current>\n </Breadcrumbs>\n }\n title=\"Page title\"\n />",
|
|
3552
|
+
"<PageHeader\n breadcrumbs={\n <Breadcrumbs>\n <Breadcrumbs.Link href=\"#\">Home</Breadcrumbs.Link>\n <Breadcrumbs.Separator />\n <Breadcrumbs.Link href=\"#\">Products</Breadcrumbs.Link>\n <Breadcrumbs.Separator />\n <Breadcrumbs.Current>Page title</Breadcrumbs.Current>\n </Breadcrumbs>\n }\n title=\"Page title\"\n description=\"Action-led, value-oriented description of what this page does. Optional second sentence with use cases or prerequisites.\"\n />",
|
|
3553
|
+
"<PageHeader\n breadcrumbs={\n <Breadcrumbs>\n <Breadcrumbs.Link href=\"#\">Home</Breadcrumbs.Link>\n <Breadcrumbs.Separator />\n <Breadcrumbs.Link href=\"#\">Products</Breadcrumbs.Link>\n <Breadcrumbs.Separator />\n <Breadcrumbs.Current>Page title</Breadcrumbs.Current>\n </Breadcrumbs>\n }\n title=\"Page title\"\n description=\"Action-led, value-oriented description of what this page does.\"\n tabs={[\n { label: \"Overview\", value: \"overview\" },\n { label: \"Analytics\", value: \"analytics\" },\n { label: \"Settings\", value: \"settings\" },\n ]}\n defaultTab=\"overview\"\n >\n <Button variant=\"outline\" size=\"sm\">\n Export\n </Button>\n <Button variant=\"primary\" size=\"sm\" icon={<PlusIcon size={16} />}>\n New Item\n </Button>\n </PageHeader>"
|
|
3554
|
+
],
|
|
3555
|
+
"colors": [
|
|
3556
|
+
"border-kumo-line",
|
|
3557
|
+
"text-kumo-default",
|
|
3558
|
+
"text-kumo-subtle"
|
|
3559
|
+
],
|
|
3560
|
+
"files": [
|
|
3561
|
+
"page-header/page-header.tsx"
|
|
3562
|
+
],
|
|
3563
|
+
"dependencies": [
|
|
3564
|
+
"Tabs"
|
|
3565
|
+
]
|
|
3566
|
+
},
|
|
3567
|
+
"ResourceListPage": {
|
|
3568
|
+
"name": "ResourceListPage",
|
|
3569
|
+
"type": "block",
|
|
3570
|
+
"description": "ResourceListPage - A layout component for resource list pages Layouts are page-level components that provide consistent structure for common page patterns like resource lists, dashboards, and settings.",
|
|
3571
|
+
"importPath": "@cloudflare/kumo",
|
|
3572
|
+
"category": "Layout",
|
|
3573
|
+
"props": {
|
|
3574
|
+
"title": {
|
|
3575
|
+
"type": "string",
|
|
3576
|
+
"optional": true
|
|
3577
|
+
},
|
|
3578
|
+
"description": {
|
|
3579
|
+
"type": "string",
|
|
3580
|
+
"optional": true
|
|
3581
|
+
},
|
|
3582
|
+
"icon": {
|
|
3583
|
+
"type": "ReactNode",
|
|
3584
|
+
"optional": true
|
|
3585
|
+
},
|
|
3586
|
+
"usage": {
|
|
3587
|
+
"type": "ReactNode",
|
|
3588
|
+
"optional": true
|
|
3589
|
+
},
|
|
3590
|
+
"additionalContent": {
|
|
3591
|
+
"type": "ReactNode",
|
|
3592
|
+
"optional": true
|
|
3593
|
+
},
|
|
3594
|
+
"children": {
|
|
3595
|
+
"type": "ReactNode",
|
|
3596
|
+
"optional": true
|
|
3597
|
+
},
|
|
3598
|
+
"className": {
|
|
3599
|
+
"type": "string",
|
|
3600
|
+
"optional": true
|
|
3601
|
+
}
|
|
3602
|
+
},
|
|
3603
|
+
"examples": [],
|
|
3604
|
+
"colors": [
|
|
3605
|
+
"bg-kumo-overlay",
|
|
3606
|
+
"text-kumo-strong"
|
|
3607
|
+
],
|
|
3608
|
+
"files": [
|
|
3609
|
+
"resource-list/resource-list.tsx",
|
|
3610
|
+
"resource-list/resource-list.test.tsx"
|
|
3611
|
+
],
|
|
3612
|
+
"dependencies": []
|
|
3613
|
+
}
|
|
3614
|
+
},
|
|
3615
|
+
"search": {
|
|
3616
|
+
"byCategory": {
|
|
3617
|
+
"Display": [
|
|
3618
|
+
"Badge",
|
|
3619
|
+
"Breadcrumbs",
|
|
3620
|
+
"Code",
|
|
3621
|
+
"Collapsible",
|
|
3622
|
+
"Empty",
|
|
3623
|
+
"LayerCard",
|
|
3624
|
+
"Meter",
|
|
3625
|
+
"Text"
|
|
3626
|
+
],
|
|
3627
|
+
"Feedback": [
|
|
3628
|
+
"Banner",
|
|
3629
|
+
"Loader",
|
|
3630
|
+
"Toasty"
|
|
3631
|
+
],
|
|
3632
|
+
"Action": [
|
|
3633
|
+
"Button",
|
|
3634
|
+
"ClipboardText"
|
|
3635
|
+
],
|
|
3636
|
+
"Input": [
|
|
3637
|
+
"Checkbox",
|
|
3638
|
+
"Combobox",
|
|
3639
|
+
"DateRangePicker",
|
|
3640
|
+
"Field",
|
|
3641
|
+
"Input",
|
|
3642
|
+
"Radio",
|
|
3643
|
+
"Select",
|
|
3644
|
+
"Switch"
|
|
3645
|
+
],
|
|
3646
|
+
"Navigation": [
|
|
3647
|
+
"CommandPalette",
|
|
3648
|
+
"MenuBar",
|
|
3649
|
+
"Pagination",
|
|
3650
|
+
"Tabs"
|
|
3651
|
+
],
|
|
3652
|
+
"Overlay": [
|
|
3653
|
+
"Dialog",
|
|
3654
|
+
"DropdownMenu",
|
|
3655
|
+
"Popover",
|
|
3656
|
+
"Tooltip"
|
|
3657
|
+
],
|
|
3658
|
+
"Layout": [
|
|
3659
|
+
"Grid",
|
|
3660
|
+
"Surface",
|
|
3661
|
+
"PageHeader",
|
|
3662
|
+
"ResourceListPage"
|
|
3663
|
+
],
|
|
3664
|
+
"Other": [
|
|
3665
|
+
"Label",
|
|
3666
|
+
"Link",
|
|
3667
|
+
"SensitiveInput",
|
|
3668
|
+
"Table"
|
|
3669
|
+
]
|
|
3670
|
+
},
|
|
3671
|
+
"byName": [
|
|
3672
|
+
"Badge",
|
|
3673
|
+
"Banner",
|
|
3674
|
+
"Breadcrumbs",
|
|
3675
|
+
"Button",
|
|
3676
|
+
"Checkbox",
|
|
3677
|
+
"ClipboardText",
|
|
3678
|
+
"Code",
|
|
3679
|
+
"Collapsible",
|
|
3680
|
+
"Combobox",
|
|
3681
|
+
"CommandPalette",
|
|
3682
|
+
"DateRangePicker",
|
|
3683
|
+
"Dialog",
|
|
3684
|
+
"DropdownMenu",
|
|
3685
|
+
"Empty",
|
|
3686
|
+
"Field",
|
|
3687
|
+
"Grid",
|
|
3688
|
+
"Input",
|
|
3689
|
+
"Label",
|
|
3690
|
+
"LayerCard",
|
|
3691
|
+
"Link",
|
|
3692
|
+
"Loader",
|
|
3693
|
+
"MenuBar",
|
|
3694
|
+
"Meter",
|
|
3695
|
+
"PageHeader",
|
|
3696
|
+
"Pagination",
|
|
3697
|
+
"Popover",
|
|
3698
|
+
"Radio",
|
|
3699
|
+
"ResourceListPage",
|
|
3700
|
+
"Select",
|
|
3701
|
+
"SensitiveInput",
|
|
3702
|
+
"Surface",
|
|
3703
|
+
"Switch",
|
|
3704
|
+
"Table",
|
|
3705
|
+
"Tabs",
|
|
3706
|
+
"Text",
|
|
3707
|
+
"Toasty",
|
|
3708
|
+
"Tooltip"
|
|
3709
|
+
],
|
|
3710
|
+
"byType": {
|
|
3711
|
+
"component": [
|
|
3712
|
+
"Badge",
|
|
3713
|
+
"Banner",
|
|
3714
|
+
"Breadcrumbs",
|
|
3715
|
+
"Button",
|
|
3716
|
+
"Checkbox",
|
|
3717
|
+
"ClipboardText",
|
|
3718
|
+
"Code",
|
|
3719
|
+
"Collapsible",
|
|
3720
|
+
"Combobox",
|
|
3721
|
+
"CommandPalette",
|
|
3722
|
+
"DateRangePicker",
|
|
3723
|
+
"Dialog",
|
|
3724
|
+
"DropdownMenu",
|
|
3725
|
+
"Empty",
|
|
3726
|
+
"Field",
|
|
3727
|
+
"Grid",
|
|
3728
|
+
"Input",
|
|
3729
|
+
"Label",
|
|
3730
|
+
"LayerCard",
|
|
3731
|
+
"Link",
|
|
3732
|
+
"Loader",
|
|
3733
|
+
"MenuBar",
|
|
3734
|
+
"Meter",
|
|
3735
|
+
"Pagination",
|
|
3736
|
+
"Popover",
|
|
3737
|
+
"Radio",
|
|
3738
|
+
"Select",
|
|
3739
|
+
"SensitiveInput",
|
|
3740
|
+
"Surface",
|
|
3741
|
+
"Switch",
|
|
3742
|
+
"Table",
|
|
3743
|
+
"Tabs",
|
|
3744
|
+
"Text",
|
|
3745
|
+
"Toasty",
|
|
3746
|
+
"Tooltip"
|
|
3747
|
+
],
|
|
3748
|
+
"block": [
|
|
3749
|
+
"PageHeader",
|
|
3750
|
+
"ResourceListPage"
|
|
3751
|
+
]
|
|
3752
|
+
}
|
|
3753
|
+
}
|
|
3754
|
+
}
|