@krizaka/ui 2.2.0 → 2.4.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/README.md +33 -8
- package/dist/audio-player.d.ts +113 -0
- package/dist/audio-player.js +207 -0
- package/dist/audio-player.js.map +1 -0
- package/dist/{button-Cgfkg_3y.d.ts → button-BMAO7dKF.d.ts} +29 -2
- package/dist/button.d.ts +32 -5
- package/dist/button.js +62 -9
- package/dist/button.js.map +1 -1
- package/dist/chip-link.d.ts +53 -0
- package/dist/chip-link.js +32 -0
- package/dist/chip-link.js.map +1 -0
- package/dist/chunk-2USC2YT6.js +17 -0
- package/dist/chunk-2USC2YT6.js.map +1 -0
- package/dist/chunk-43PTCDTL.js +31 -0
- package/dist/chunk-43PTCDTL.js.map +1 -0
- package/dist/chunk-6ISW63JI.js +11 -0
- package/dist/chunk-6ISW63JI.js.map +1 -0
- package/dist/chunk-EUPTXKH7.js +95 -0
- package/dist/chunk-EUPTXKH7.js.map +1 -0
- package/dist/chunk-HAQWKORZ.js +117 -0
- package/dist/chunk-HAQWKORZ.js.map +1 -0
- package/dist/{chunk-FHYZSO2S.js → chunk-R6SDS7JM.js} +5 -3
- package/dist/chunk-R6SDS7JM.js.map +1 -0
- package/dist/chunk-RUPNPMP3.js +103 -0
- package/dist/chunk-RUPNPMP3.js.map +1 -0
- package/dist/chunk-RUPRYJ45.js +82 -0
- package/dist/chunk-RUPRYJ45.js.map +1 -0
- package/dist/chunk-VDR2EP6K.js +49 -0
- package/dist/chunk-VDR2EP6K.js.map +1 -0
- package/dist/chunk-WEVYKZIF.js +33 -0
- package/dist/chunk-WEVYKZIF.js.map +1 -0
- package/dist/chunk-XUMJA5ZI.js +283 -0
- package/dist/chunk-XUMJA5ZI.js.map +1 -0
- package/dist/chunk-YH4LMWRU.js +92 -0
- package/dist/chunk-YH4LMWRU.js.map +1 -0
- package/dist/chunk-YX6CNVJA.js +94 -0
- package/dist/chunk-YX6CNVJA.js.map +1 -0
- package/dist/chunk-ZIXB33X7.js +95 -0
- package/dist/chunk-ZIXB33X7.js.map +1 -0
- package/dist/combobox.d.ts +188 -0
- package/dist/combobox.js +16 -0
- package/dist/combobox.js.map +1 -0
- package/dist/command.d.ts +7 -7
- package/dist/command.js +3 -2
- package/dist/command.js.map +1 -1
- package/dist/confirm-button.d.ts +1 -1
- package/dist/confirm-button.js +2 -1
- package/dist/confirm-button.js.map +1 -1
- package/dist/data-table.d.ts +246 -0
- package/dist/data-table.js +290 -0
- package/dist/data-table.js.map +1 -0
- package/dist/date-picker.d.ts +288 -0
- package/dist/date-picker.js +364 -0
- package/dist/date-picker.js.map +1 -0
- package/dist/{dialog-GQ4Nvuyf.d.ts → dialog-D42QwYb_.d.ts} +11 -1
- package/dist/dialog.d.ts +1 -1
- package/dist/dialog.js +3 -2
- package/dist/dialog.js.map +1 -1
- package/dist/file-upload.d.ts +238 -0
- package/dist/file-upload.js +437 -0
- package/dist/file-upload.js.map +1 -0
- package/dist/filter-bar.d.ts +139 -0
- package/dist/filter-bar.js +155 -0
- package/dist/filter-bar.js.map +1 -0
- package/dist/glow-card.d.ts +20 -0
- package/dist/glow-card.js +30 -0
- package/dist/glow-card.js.map +1 -0
- package/dist/image-cropper.d.ts +115 -0
- package/dist/image-cropper.js +166 -0
- package/dist/image-cropper.js.map +1 -0
- package/dist/index.d.ts +2 -20
- package/dist/index.js +7 -64
- package/dist/index.js.map +1 -1
- package/dist/iso.d.ts +400 -0
- package/dist/iso.js +363 -0
- package/dist/iso.js.map +1 -0
- package/dist/loader.d.ts +206 -0
- package/dist/loader.js +138 -0
- package/dist/loader.js.map +1 -0
- package/dist/marquee.d.ts +33 -0
- package/dist/marquee.js +52 -0
- package/dist/marquee.js.map +1 -0
- package/dist/media-capture.d.ts +155 -0
- package/dist/media-capture.js +242 -0
- package/dist/media-capture.js.map +1 -0
- package/dist/meter.d.ts +146 -0
- package/dist/meter.js +107 -0
- package/dist/meter.js.map +1 -0
- package/dist/motion.css +394 -3
- package/dist/motion.d.ts +46 -0
- package/dist/motion.js +10 -0
- package/dist/motion.js.map +1 -0
- package/dist/native/media-capture.d.ts +49 -0
- package/dist/native/media-capture.js +113 -0
- package/dist/native/media-capture.js.map +1 -0
- package/dist/native/video-player.d.ts +50 -0
- package/dist/native/video-player.js +69 -0
- package/dist/native/video-player.js.map +1 -0
- package/dist/native.d.ts +66 -2
- package/dist/native.js +166 -68
- package/dist/native.js.map +1 -1
- package/dist/nav-bar.d.ts +178 -0
- package/dist/nav-bar.js +157 -0
- package/dist/nav-bar.js.map +1 -0
- package/dist/number-ticker.d.ts +32 -0
- package/dist/number-ticker.js +61 -0
- package/dist/number-ticker.js.map +1 -0
- package/dist/pagination.d.ts +141 -0
- package/dist/pagination.js +165 -0
- package/dist/pagination.js.map +1 -0
- package/dist/progress.d.ts +56 -1
- package/dist/progress.js +72 -25
- package/dist/progress.js.map +1 -1
- package/dist/search-field.d.ts +100 -0
- package/dist/search-field.js +167 -0
- package/dist/search-field.js.map +1 -0
- package/dist/skeleton.d.ts +18 -3
- package/dist/skeleton.js +9 -1
- package/dist/skeleton.js.map +1 -1
- package/dist/spinner.d.ts +21 -5
- package/dist/spinner.js +13 -12
- package/dist/spinner.js.map +1 -1
- package/dist/stepper.d.ts +112 -0
- package/dist/stepper.js +67 -0
- package/dist/stepper.js.map +1 -0
- package/dist/tabs.d.ts +1 -1
- package/dist/tabs.js +14 -8
- package/dist/tabs.js.map +1 -1
- package/dist/tag-input.d.ts +44 -0
- package/dist/tag-input.js +67 -0
- package/dist/tag-input.js.map +1 -0
- package/dist/theme.d.ts +1 -1
- package/dist/theme.js +2 -1
- package/dist/theme.js.map +1 -1
- package/dist/toast.d.ts +39 -4
- package/dist/toast.js +81 -7
- package/dist/toast.js.map +1 -1
- package/dist/video-player.d.ts +204 -0
- package/dist/video-player.js +371 -0
- package/dist/video-player.js.map +1 -0
- package/dist/video-trimmer.d.ts +142 -0
- package/dist/video-trimmer.js +193 -0
- package/dist/video-trimmer.js.map +1 -0
- package/package.json +375 -7
- package/registry/alert.json +1 -1
- package/registry/audio-player.json +282 -0
- package/registry/avatar.json +1 -1
- package/registry/badge.json +1 -1
- package/registry/button.json +232 -26
- package/registry/card.json +1 -1
- package/registry/checkbox.json +1 -1
- package/registry/chip-link.json +158 -0
- package/registry/chip.json +1 -1
- package/registry/combobox.json +475 -0
- package/registry/command.json +1 -1
- package/registry/confirm-button.json +91 -7
- package/registry/countdown.json +1 -1
- package/registry/data-table.json +500 -0
- package/registry/date-picker.json +978 -0
- package/registry/dialog.json +15 -7
- package/registry/dropdown-menu.json +1 -1
- package/registry/empty-state.json +1 -1
- package/registry/examples/audio-player/podcast.js +22 -0
- package/registry/examples/audio-player/podcast.tsx +19 -0
- package/registry/examples/audio-player/voice-note.d.ts +4 -0
- package/registry/examples/audio-player/voice-note.js +12 -0
- package/registry/examples/audio-player/voice-note.tsx +12 -0
- package/registry/examples/button/error.d.ts +4 -0
- package/registry/examples/button/error.js +11 -0
- package/registry/examples/button/error.tsx +10 -0
- package/registry/examples/button/loading.tsx +1 -1
- package/registry/examples/button/save-flow.d.ts +4 -0
- package/registry/examples/button/save-flow.js +28 -0
- package/registry/examples/button/save-flow.tsx +24 -0
- package/registry/examples/button/signature.d.ts +4 -0
- package/registry/examples/button/signature.js +17 -0
- package/registry/examples/button/signature.tsx +19 -0
- package/registry/examples/button/upload-progress.d.ts +4 -0
- package/registry/examples/button/upload-progress.js +23 -0
- package/registry/examples/button/upload-progress.tsx +26 -0
- package/registry/examples/chip-link/filters.d.ts +4 -0
- package/registry/examples/chip-link/filters.js +12 -0
- package/registry/examples/chip-link/filters.tsx +17 -0
- package/registry/examples/combobox/async.d.ts +4 -0
- package/registry/examples/combobox/async.js +23 -0
- package/registry/examples/combobox/async.tsx +22 -0
- package/registry/examples/combobox/creatable.d.ts +4 -0
- package/registry/examples/combobox/creatable.js +32 -0
- package/registry/examples/combobox/creatable.tsx +28 -0
- package/registry/examples/combobox/invalid.d.ts +4 -0
- package/registry/examples/combobox/invalid.js +23 -0
- package/registry/examples/combobox/invalid.tsx +17 -0
- package/registry/examples/combobox/multiple.d.ts +4 -0
- package/registry/examples/combobox/multiple.js +29 -0
- package/registry/examples/combobox/multiple.tsx +26 -0
- package/registry/examples/data-table/cards.d.ts +4 -0
- package/registry/examples/data-table/cards.js +21 -0
- package/registry/examples/data-table/cards.tsx +20 -0
- package/registry/examples/data-table/empty.d.ts +4 -0
- package/registry/examples/data-table/empty.js +26 -0
- package/registry/examples/data-table/empty.tsx +21 -0
- package/registry/examples/data-table/error.d.ts +4 -0
- package/registry/examples/data-table/error.js +28 -0
- package/registry/examples/data-table/error.tsx +29 -0
- package/registry/examples/data-table/jobs.d.ts +4 -0
- package/registry/examples/data-table/jobs.js +37 -0
- package/registry/examples/data-table/jobs.tsx +36 -0
- package/registry/examples/data-table/loading.d.ts +4 -0
- package/registry/examples/data-table/loading.js +16 -0
- package/registry/examples/data-table/loading.tsx +12 -0
- package/registry/examples/data-table/virtualized.d.ts +4 -0
- package/registry/examples/data-table/virtualized.js +21 -0
- package/registry/examples/data-table/virtualized.tsx +20 -0
- package/registry/examples/date-picker/calendar.d.ts +4 -0
- package/registry/examples/date-picker/calendar.js +14 -0
- package/registry/examples/date-picker/calendar.tsx +16 -0
- package/registry/examples/date-picker/french.d.ts +4 -0
- package/registry/examples/date-picker/french.js +20 -0
- package/registry/examples/date-picker/french.tsx +14 -0
- package/registry/examples/date-picker/open.d.ts +4 -0
- package/registry/examples/date-picker/open.js +11 -0
- package/registry/examples/date-picker/open.tsx +8 -0
- package/registry/examples/date-picker/range.d.ts +4 -0
- package/registry/examples/date-picker/range.js +29 -0
- package/registry/examples/date-picker/range.tsx +25 -0
- package/registry/examples/date-picker/schedule.d.ts +4 -0
- package/registry/examples/date-picker/schedule.js +26 -0
- package/registry/examples/date-picker/schedule.tsx +22 -0
- package/registry/examples/dialog/left.d.ts +4 -0
- package/registry/examples/dialog/left.js +22 -0
- package/registry/examples/dialog/left.tsx +32 -0
- package/registry/examples/file-upload/images.d.ts +4 -0
- package/registry/examples/file-upload/images.js +32 -0
- package/registry/examples/file-upload/images.tsx +25 -0
- package/registry/examples/file-upload/states.d.ts +4 -0
- package/registry/examples/file-upload/states.js +28 -0
- package/registry/examples/file-upload/states.tsx +23 -0
- package/registry/examples/file-upload/tus.d.ts +4 -0
- package/registry/examples/file-upload/tus.js +23 -0
- package/registry/examples/file-upload/tus.tsx +26 -0
- package/registry/examples/file-upload/video.d.ts +4 -0
- package/registry/examples/file-upload/video.js +39 -0
- package/registry/examples/file-upload/video.tsx +36 -0
- package/registry/examples/filter-bar/address.d.ts +4 -0
- package/registry/examples/filter-bar/address.js +29 -0
- package/registry/examples/filter-bar/address.tsx +27 -0
- package/registry/examples/filter-bar/jobs.d.ts +4 -0
- package/registry/examples/filter-bar/jobs.js +37 -0
- package/registry/examples/filter-bar/jobs.tsx +37 -0
- package/registry/examples/filter-bar/menu.d.ts +4 -0
- package/registry/examples/filter-bar/menu.js +27 -0
- package/registry/examples/filter-bar/menu.tsx +23 -0
- package/registry/examples/glow-card/link-card.d.ts +4 -0
- package/registry/examples/glow-card/link-card.js +14 -0
- package/registry/examples/glow-card/link-card.tsx +13 -0
- package/registry/examples/glow-card/plans.d.ts +4 -0
- package/registry/examples/glow-card/plans.js +25 -0
- package/registry/examples/glow-card/plans.tsx +26 -0
- package/registry/examples/glow-card/spotlight.d.ts +4 -0
- package/registry/examples/glow-card/spotlight.js +14 -0
- package/registry/examples/glow-card/spotlight.tsx +15 -0
- package/registry/examples/image-cropper/avatar.d.ts +4 -0
- package/registry/examples/image-cropper/avatar.js +13 -0
- package/registry/examples/image-cropper/avatar.tsx +14 -0
- package/registry/examples/image-cropper/banner.d.ts +4 -0
- package/registry/examples/image-cropper/banner.js +11 -0
- package/registry/examples/image-cropper/banner.tsx +10 -0
- package/registry/examples/image-cropper/vertical-video.d.ts +4 -0
- package/registry/examples/image-cropper/vertical-video.js +12 -0
- package/registry/examples/image-cropper/vertical-video.tsx +16 -0
- package/registry/examples/iso/compose.d.ts +4 -0
- package/registry/examples/iso/compose.js +22 -0
- package/registry/examples/iso/compose.tsx +19 -0
- package/registry/examples/iso/orazaka-hero.d.ts +4 -0
- package/registry/examples/iso/orazaka-hero.js +26 -0
- package/registry/examples/iso/orazaka-hero.tsx +21 -0
- package/registry/examples/iso/orochia-hero.d.ts +4 -0
- package/registry/examples/iso/orochia-hero.js +29 -0
- package/registry/examples/iso/orochia-hero.tsx +23 -0
- package/registry/examples/iso/still.d.ts +4 -0
- package/registry/examples/iso/still.js +21 -0
- package/registry/examples/iso/still.tsx +15 -0
- package/registry/examples/loader/endings.d.ts +4 -0
- package/registry/examples/loader/endings.js +14 -0
- package/registry/examples/loader/endings.tsx +11 -0
- package/registry/examples/loader/fetch-flow.d.ts +4 -0
- package/registry/examples/loader/fetch-flow.js +24 -0
- package/registry/examples/loader/fetch-flow.tsx +24 -0
- package/registry/examples/loader/minimal.d.ts +4 -0
- package/registry/examples/loader/minimal.js +11 -0
- package/registry/examples/loader/minimal.tsx +6 -0
- package/registry/examples/loader/overlay.d.ts +4 -0
- package/registry/examples/loader/overlay.js +16 -0
- package/registry/examples/loader/overlay.tsx +13 -0
- package/registry/examples/loader/region-handover.d.ts +4 -0
- package/registry/examples/loader/region-handover.js +42 -0
- package/registry/examples/loader/region-handover.tsx +29 -0
- package/registry/examples/loader/upload-eta.d.ts +4 -0
- package/registry/examples/loader/upload-eta.js +11 -0
- package/registry/examples/loader/upload-eta.tsx +10 -0
- package/registry/examples/marquee/cards.d.ts +4 -0
- package/registry/examples/marquee/cards.js +23 -0
- package/registry/examples/marquee/cards.tsx +21 -0
- package/registry/examples/marquee/logos.d.ts +4 -0
- package/registry/examples/marquee/logos.js +12 -0
- package/registry/examples/marquee/logos.tsx +17 -0
- package/registry/examples/media-capture/clip.d.ts +4 -0
- package/registry/examples/media-capture/clip.js +20 -0
- package/registry/examples/media-capture/clip.tsx +18 -0
- package/registry/examples/media-capture/native/photo.d.ts +4 -0
- package/registry/examples/media-capture/native/photo.dark.png +0 -0
- package/registry/examples/media-capture/native/photo.js +27 -0
- package/registry/examples/media-capture/native/photo.light.png +0 -0
- package/registry/examples/media-capture/native/photo.tsx +20 -0
- package/registry/examples/media-capture/profile-photo.d.ts +4 -0
- package/registry/examples/media-capture/profile-photo.js +24 -0
- package/registry/examples/media-capture/profile-photo.tsx +20 -0
- package/registry/examples/meter/balance.d.ts +4 -0
- package/registry/examples/meter/balance.js +14 -0
- package/registry/examples/meter/balance.tsx +15 -0
- package/registry/examples/meter/quota.d.ts +4 -0
- package/registry/examples/meter/quota.js +15 -0
- package/registry/examples/meter/quota.tsx +12 -0
- package/registry/examples/meter/split.d.ts +4 -0
- package/registry/examples/meter/split.js +18 -0
- package/registry/examples/meter/split.tsx +18 -0
- package/registry/examples/nav-bar/app-bar.d.ts +4 -0
- package/registry/examples/nav-bar/app-bar.js +22 -0
- package/registry/examples/nav-bar/app-bar.tsx +21 -0
- package/registry/examples/nav-bar/menu-open.d.ts +4 -0
- package/registry/examples/nav-bar/menu-open.js +26 -0
- package/registry/examples/nav-bar/menu-open.tsx +26 -0
- package/registry/examples/nav-bar/site.d.ts +4 -0
- package/registry/examples/nav-bar/site.js +31 -0
- package/registry/examples/nav-bar/site.tsx +36 -0
- package/registry/examples/number-ticker/gradient.d.ts +4 -0
- package/registry/examples/number-ticker/gradient.js +11 -0
- package/registry/examples/number-ticker/gradient.tsx +10 -0
- package/registry/examples/number-ticker/live-total.d.ts +4 -0
- package/registry/examples/number-ticker/live-total.js +17 -0
- package/registry/examples/number-ticker/live-total.tsx +21 -0
- package/registry/examples/number-ticker/stats.d.ts +4 -0
- package/registry/examples/number-ticker/stats.js +19 -0
- package/registry/examples/number-ticker/stats.tsx +23 -0
- package/registry/examples/pagination/cursor.d.ts +4 -0
- package/registry/examples/pagination/cursor.js +24 -0
- package/registry/examples/pagination/cursor.tsx +20 -0
- package/registry/examples/pagination/links.d.ts +4 -0
- package/registry/examples/pagination/links.js +11 -0
- package/registry/examples/pagination/links.tsx +6 -0
- package/registry/examples/pagination/native/cursor.d.ts +4 -0
- package/registry/examples/pagination/native/cursor.dark.png +0 -0
- package/registry/examples/pagination/native/cursor.js +19 -0
- package/registry/examples/pagination/native/cursor.light.png +0 -0
- package/registry/examples/pagination/native/cursor.tsx +13 -0
- package/registry/examples/pagination/native/pages.d.ts +4 -0
- package/registry/examples/pagination/native/pages.dark.png +0 -0
- package/registry/examples/pagination/native/pages.js +21 -0
- package/registry/examples/pagination/native/pages.light.png +0 -0
- package/registry/examples/pagination/native/pages.tsx +14 -0
- package/registry/examples/pagination/results.d.ts +4 -0
- package/registry/examples/pagination/results.js +23 -0
- package/registry/examples/pagination/results.tsx +19 -0
- package/registry/examples/pagination/table-footer.d.ts +4 -0
- package/registry/examples/pagination/table-footer.js +31 -0
- package/registry/examples/pagination/table-footer.tsx +27 -0
- package/registry/examples/progress/buffer.d.ts +4 -0
- package/registry/examples/progress/buffer.js +11 -0
- package/registry/examples/progress/buffer.tsx +10 -0
- package/registry/examples/progress/statuses.d.ts +4 -0
- package/registry/examples/progress/statuses.js +14 -0
- package/registry/examples/progress/statuses.tsx +11 -0
- package/registry/examples/progress/steps.d.ts +4 -0
- package/registry/examples/progress/steps.js +14 -0
- package/registry/examples/progress/steps.tsx +13 -0
- package/registry/examples/progress/upload.d.ts +4 -0
- package/registry/examples/progress/upload.js +11 -0
- package/registry/examples/progress/upload.tsx +10 -0
- package/registry/examples/search-field/global.d.ts +4 -0
- package/registry/examples/search-field/global.js +19 -0
- package/registry/examples/search-field/global.tsx +15 -0
- package/registry/examples/search-field/native/default.d.ts +4 -0
- package/registry/examples/search-field/native/default.dark.png +0 -0
- package/registry/examples/search-field/native/default.js +13 -0
- package/registry/examples/search-field/native/default.light.png +0 -0
- package/registry/examples/search-field/native/default.tsx +7 -0
- package/registry/examples/search-field/suggestions.d.ts +4 -0
- package/registry/examples/search-field/suggestions.js +30 -0
- package/registry/examples/search-field/suggestions.tsx +27 -0
- package/registry/examples/search-field/toolbar.d.ts +4 -0
- package/registry/examples/search-field/toolbar.js +17 -0
- package/registry/examples/search-field/toolbar.tsx +21 -0
- package/registry/examples/skeleton/paragraph.d.ts +4 -0
- package/registry/examples/skeleton/paragraph.js +14 -0
- package/registry/examples/skeleton/paragraph.tsx +12 -0
- package/registry/examples/skeleton/shape-of-content.d.ts +4 -0
- package/registry/examples/skeleton/shape-of-content.js +23 -0
- package/registry/examples/skeleton/shape-of-content.tsx +26 -0
- package/registry/examples/spinner/default.js +5 -2
- package/registry/examples/spinner/default.tsx +7 -1
- package/registry/examples/spinner/sizes.js +2 -1
- package/registry/examples/spinner/sizes.tsx +2 -0
- package/registry/examples/spinner/value.d.ts +4 -0
- package/registry/examples/spinner/value.js +11 -0
- package/registry/examples/spinner/value.tsx +12 -0
- package/registry/examples/stepper/checkout.d.ts +4 -0
- package/registry/examples/stepper/checkout.js +22 -0
- package/registry/examples/stepper/checkout.tsx +17 -0
- package/registry/examples/stepper/failed.d.ts +4 -0
- package/registry/examples/stepper/failed.js +26 -0
- package/registry/examples/stepper/failed.tsx +21 -0
- package/registry/examples/stepper/job.d.ts +4 -0
- package/registry/examples/stepper/job.js +32 -0
- package/registry/examples/stepper/job.tsx +28 -0
- package/registry/examples/tag-input/recipients.d.ts +4 -0
- package/registry/examples/tag-input/recipients.js +23 -0
- package/registry/examples/tag-input/recipients.tsx +20 -0
- package/registry/examples/tag-input/video-tags.d.ts +4 -0
- package/registry/examples/tag-input/video-tags.js +26 -0
- package/registry/examples/tag-input/video-tags.tsx +22 -0
- package/registry/examples/toast/grouped.d.ts +4 -0
- package/registry/examples/toast/grouped.js +21 -0
- package/registry/examples/toast/grouped.tsx +23 -0
- package/registry/examples/toast/undo.d.ts +4 -0
- package/registry/examples/toast/undo.js +29 -0
- package/registry/examples/toast/undo.tsx +30 -0
- package/registry/examples/toast/upload-progress.d.ts +4 -0
- package/registry/examples/toast/upload-progress.js +29 -0
- package/registry/examples/toast/upload-progress.tsx +31 -0
- package/registry/examples/video-player/default.d.ts +4 -0
- package/registry/examples/video-player/default.js +12 -0
- package/registry/examples/video-player/default.tsx +8 -0
- package/registry/examples/video-player/gated.d.ts +4 -0
- package/registry/examples/video-player/gated.js +26 -0
- package/registry/examples/video-player/gated.tsx +23 -0
- package/registry/examples/video-player/native/default.d.ts +4 -0
- package/registry/examples/video-player/native/default.dark.png +0 -0
- package/registry/examples/video-player/native/default.js +18 -0
- package/registry/examples/video-player/native/default.light.png +0 -0
- package/registry/examples/video-player/native/default.tsx +12 -0
- package/registry/examples/video-player/signed-source.d.ts +4 -0
- package/registry/examples/video-player/signed-source.js +16 -0
- package/registry/examples/video-player/signed-source.tsx +15 -0
- package/registry/examples/video-player/vertical.d.ts +4 -0
- package/registry/examples/video-player/vertical.js +12 -0
- package/registry/examples/video-player/vertical.tsx +12 -0
- package/registry/examples/video-trimmer/custom.d.ts +4 -0
- package/registry/examples/video-trimmer/custom.js +24 -0
- package/registry/examples/video-trimmer/custom.tsx +26 -0
- package/registry/examples/video-trimmer/filmstrip.d.ts +4 -0
- package/registry/examples/video-trimmer/filmstrip.js +15 -0
- package/registry/examples/video-trimmer/filmstrip.tsx +13 -0
- package/registry/examples/video-trimmer/playhead.d.ts +4 -0
- package/registry/examples/video-trimmer/playhead.js +15 -0
- package/registry/examples/video-trimmer/playhead.tsx +13 -0
- package/registry/field.json +1 -1
- package/registry/file-upload.json +471 -0
- package/registry/filter-bar.json +347 -0
- package/registry/glow-card.json +162 -0
- package/registry/image-cropper.json +313 -0
- package/registry/index.json +445 -20
- package/registry/iso.json +1355 -0
- package/registry/kbd.json +1 -1
- package/registry/loader.json +399 -0
- package/registry/marquee.json +225 -0
- package/registry/mascots.json +3 -3
- package/registry/media-capture.json +347 -0
- package/registry/meter.json +324 -0
- package/registry/nav-bar.json +480 -0
- package/registry/number-ticker.json +219 -0
- package/registry/page-header.json +1 -1
- package/registry/pagination.json +475 -0
- package/registry/popover.json +1 -1
- package/registry/progress.json +114 -9
- package/registry/radio-group.json +1 -1
- package/registry/search-field.json +436 -0
- package/registry/section-backdrop.json +1 -1
- package/registry/separator.json +1 -1
- package/registry/skeleton.json +69 -13
- package/registry/slider.json +1 -1
- package/registry/slot.json +1 -1
- package/registry/spinner.json +91 -27
- package/registry/stat.json +1 -1
- package/registry/stepper.json +174 -0
- package/registry/switch.json +1 -1
- package/registry/tabs.json +11 -7
- package/registry/tag-input.json +363 -0
- package/registry/theme.json +3 -3
- package/registry/toast.json +41 -13
- package/registry/tooltip.json +1 -1
- package/registry/video-player.json +598 -0
- package/registry/video-trimmer.json +385 -0
- package/dist/chunk-FHYZSO2S.js.map +0 -1
- package/dist/chunk-PESA2R4U.js +0 -51
- package/dist/chunk-PESA2R4U.js.map +0 -1
- package/registry/examples/spinner/muted.js +0 -11
- package/registry/examples/spinner/muted.tsx +0 -6
- /package/registry/examples/{spinner/muted.d.ts → audio-player/podcast.d.ts} +0 -0
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
// registry/examples/combobox/creatable.tsx
|
|
4
|
+
import { Combobox } from "@krizaka/ui/combobox";
|
|
5
|
+
import * as React from "react";
|
|
6
|
+
import { jsx } from "react/jsx-runtime";
|
|
7
|
+
function ComboboxCreatable() {
|
|
8
|
+
const [playlists, setPlaylists] = React.useState([
|
|
9
|
+
{ value: "p1", label: "Travel diaries" },
|
|
10
|
+
{ value: "p2", label: "Studio sessions" }
|
|
11
|
+
]);
|
|
12
|
+
const [value, setValue] = React.useState(playlists[1]);
|
|
13
|
+
return /* @__PURE__ */ jsx(
|
|
14
|
+
Combobox,
|
|
15
|
+
{
|
|
16
|
+
label: "Playlist",
|
|
17
|
+
options: playlists,
|
|
18
|
+
value,
|
|
19
|
+
onValueChange: setValue,
|
|
20
|
+
creatable: true,
|
|
21
|
+
onCreate: (name) => {
|
|
22
|
+
const created = { value: `p${playlists.length + 1}`, label: name };
|
|
23
|
+
setPlaylists((all) => [...all, created]);
|
|
24
|
+
return created;
|
|
25
|
+
},
|
|
26
|
+
labels: { create: (name) => `Create the playlist \u201C${name}\u201D` }
|
|
27
|
+
}
|
|
28
|
+
);
|
|
29
|
+
}
|
|
30
|
+
export {
|
|
31
|
+
ComboboxCreatable as default
|
|
32
|
+
};
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
import { Combobox, type ComboboxOption } from "@krizaka/ui/combobox";
|
|
4
|
+
import * as React from "react";
|
|
5
|
+
|
|
6
|
+
// Pick a playlist, or type a new name and create it.
|
|
7
|
+
export default function ComboboxCreatable() {
|
|
8
|
+
const [playlists, setPlaylists] = React.useState<ComboboxOption[]>([
|
|
9
|
+
{ value: "p1", label: "Travel diaries" },
|
|
10
|
+
{ value: "p2", label: "Studio sessions" },
|
|
11
|
+
]);
|
|
12
|
+
const [value, setValue] = React.useState<ComboboxOption | null>(playlists[1]!);
|
|
13
|
+
return (
|
|
14
|
+
<Combobox
|
|
15
|
+
label="Playlist"
|
|
16
|
+
options={playlists}
|
|
17
|
+
value={value}
|
|
18
|
+
onValueChange={setValue}
|
|
19
|
+
creatable
|
|
20
|
+
onCreate={(name) => {
|
|
21
|
+
const created = { value: `p${playlists.length + 1}`, label: name };
|
|
22
|
+
setPlaylists((all) => [...all, created]);
|
|
23
|
+
return created;
|
|
24
|
+
}}
|
|
25
|
+
labels={{ create: (name) => `Create the playlist “${name}”` }}
|
|
26
|
+
/>
|
|
27
|
+
);
|
|
28
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
// registry/examples/combobox/invalid.tsx
|
|
4
|
+
import { Combobox } from "@krizaka/ui/combobox";
|
|
5
|
+
import { jsx } from "react/jsx-runtime";
|
|
6
|
+
function ComboboxInvalid() {
|
|
7
|
+
return /* @__PURE__ */ jsx(
|
|
8
|
+
Combobox,
|
|
9
|
+
{
|
|
10
|
+
label: "Country of residence",
|
|
11
|
+
placeholder: "Choose a country",
|
|
12
|
+
options: [
|
|
13
|
+
{ value: "CA", label: "Canada" },
|
|
14
|
+
{ value: "FR", label: "France" },
|
|
15
|
+
{ value: "BE", label: "Belgium" }
|
|
16
|
+
],
|
|
17
|
+
error: "Choose your country to receive payouts."
|
|
18
|
+
}
|
|
19
|
+
);
|
|
20
|
+
}
|
|
21
|
+
export {
|
|
22
|
+
ComboboxInvalid as default
|
|
23
|
+
};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { Combobox } from "@krizaka/ui/combobox";
|
|
2
|
+
|
|
3
|
+
// A required choice left empty: the error is shown and read with the field.
|
|
4
|
+
export default function ComboboxInvalid() {
|
|
5
|
+
return (
|
|
6
|
+
<Combobox
|
|
7
|
+
label="Country of residence"
|
|
8
|
+
placeholder="Choose a country"
|
|
9
|
+
options={[
|
|
10
|
+
{ value: "CA", label: "Canada" },
|
|
11
|
+
{ value: "FR", label: "France" },
|
|
12
|
+
{ value: "BE", label: "Belgium" },
|
|
13
|
+
]}
|
|
14
|
+
error="Choose your country to receive payouts."
|
|
15
|
+
/>
|
|
16
|
+
);
|
|
17
|
+
}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
// registry/examples/combobox/multiple.tsx
|
|
4
|
+
import { Combobox } from "@krizaka/ui/combobox";
|
|
5
|
+
import { jsx } from "react/jsx-runtime";
|
|
6
|
+
var PEOPLE = [
|
|
7
|
+
{ value: "eric", label: "Eric" },
|
|
8
|
+
{ value: "ines", label: "In\xE8s" },
|
|
9
|
+
{ value: "jonas", label: "Jonas" },
|
|
10
|
+
{ value: "mia", label: "Mia" },
|
|
11
|
+
{ value: "noah", label: "Noah" }
|
|
12
|
+
];
|
|
13
|
+
function ComboboxMultiple() {
|
|
14
|
+
return /* @__PURE__ */ jsx(
|
|
15
|
+
Combobox,
|
|
16
|
+
{
|
|
17
|
+
multiple: true,
|
|
18
|
+
label: "Collaborators",
|
|
19
|
+
placeholder: "Add a collaborator",
|
|
20
|
+
options: PEOPLE,
|
|
21
|
+
defaultValue: [PEOPLE[0], PEOPLE[1]],
|
|
22
|
+
maxSelected: 3,
|
|
23
|
+
hint: "Up to three collaborators share the revenue of this video."
|
|
24
|
+
}
|
|
25
|
+
);
|
|
26
|
+
}
|
|
27
|
+
export {
|
|
28
|
+
ComboboxMultiple as default
|
|
29
|
+
};
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
import { Combobox } from "@krizaka/ui/combobox";
|
|
4
|
+
|
|
5
|
+
const PEOPLE = [
|
|
6
|
+
{ value: "eric", label: "Eric" },
|
|
7
|
+
{ value: "ines", label: "Inès" },
|
|
8
|
+
{ value: "jonas", label: "Jonas" },
|
|
9
|
+
{ value: "mia", label: "Mia" },
|
|
10
|
+
{ value: "noah", label: "Noah" },
|
|
11
|
+
];
|
|
12
|
+
|
|
13
|
+
// Several values as chips; Backspace in the empty input removes the last one.
|
|
14
|
+
export default function ComboboxMultiple() {
|
|
15
|
+
return (
|
|
16
|
+
<Combobox
|
|
17
|
+
multiple
|
|
18
|
+
label="Collaborators"
|
|
19
|
+
placeholder="Add a collaborator"
|
|
20
|
+
options={PEOPLE}
|
|
21
|
+
defaultValue={[PEOPLE[0]!, PEOPLE[1]!]}
|
|
22
|
+
maxSelected={3}
|
|
23
|
+
hint="Up to three collaborators share the revenue of this video."
|
|
24
|
+
/>
|
|
25
|
+
);
|
|
26
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
// registry/examples/data-table/cards.tsx
|
|
4
|
+
import { DataTable } from "@krizaka/ui/data-table";
|
|
5
|
+
import { jsx } from "react/jsx-runtime";
|
|
6
|
+
var videos = [
|
|
7
|
+
{ id: "v1", title: "Sunset over Montr\xE9al", views: 12840, tips: "$184.00", visibility: "Public" },
|
|
8
|
+
{ id: "v2", title: "Behind the scenes, part 2", views: 3120, tips: "$62.50", visibility: "Followers" }
|
|
9
|
+
];
|
|
10
|
+
var columns = [
|
|
11
|
+
{ id: "title", header: "Title", card: "title" },
|
|
12
|
+
{ id: "visibility", header: "Visibility" },
|
|
13
|
+
{ id: "views", header: "Views", align: "end", cell: (v) => v.views.toLocaleString("en") },
|
|
14
|
+
{ id: "tips", header: "Tips", align: "end" }
|
|
15
|
+
];
|
|
16
|
+
function DataTableCards() {
|
|
17
|
+
return /* @__PURE__ */ jsx(DataTable, { caption: "Your videos", rows: videos, columns, getRowId: (v) => v.id, layout: "cards" });
|
|
18
|
+
}
|
|
19
|
+
export {
|
|
20
|
+
DataTableCards as default
|
|
21
|
+
};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
import { DataTable, type DataTableColumn } from "@krizaka/ui/data-table";
|
|
4
|
+
|
|
5
|
+
type Video = { id: string; title: string; views: number; tips: string; visibility: string };
|
|
6
|
+
const videos: Video[] = [
|
|
7
|
+
{ id: "v1", title: "Sunset over Montréal", views: 12840, tips: "$184.00", visibility: "Public" },
|
|
8
|
+
{ id: "v2", title: "Behind the scenes, part 2", views: 3120, tips: "$62.50", visibility: "Followers" },
|
|
9
|
+
];
|
|
10
|
+
const columns: DataTableColumn<Video>[] = [
|
|
11
|
+
{ id: "title", header: "Title", card: "title" },
|
|
12
|
+
{ id: "visibility", header: "Visibility" },
|
|
13
|
+
{ id: "views", header: "Views", align: "end", cell: (v) => v.views.toLocaleString("en") },
|
|
14
|
+
{ id: "tips", header: "Tips", align: "end" },
|
|
15
|
+
];
|
|
16
|
+
|
|
17
|
+
// A studio's videos on a phone: one card per row, the title on top, every value labelled.
|
|
18
|
+
export default function DataTableCards() {
|
|
19
|
+
return <DataTable caption="Your videos" rows={videos} columns={columns} getRowId={(v) => v.id} layout="cards" />;
|
|
20
|
+
}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
// registry/examples/data-table/empty.tsx
|
|
4
|
+
import { Button } from "@krizaka/ui/button";
|
|
5
|
+
import { DataTable } from "@krizaka/ui/data-table";
|
|
6
|
+
import { EmptyState } from "@krizaka/ui/empty-state";
|
|
7
|
+
import { jsx } from "react/jsx-runtime";
|
|
8
|
+
var columns = [
|
|
9
|
+
{ id: "invoice", header: "Invoice", card: "title" },
|
|
10
|
+
{ id: "amount", header: "Amount", align: "end" }
|
|
11
|
+
];
|
|
12
|
+
function DataTableEmpty() {
|
|
13
|
+
return /* @__PURE__ */ jsx(
|
|
14
|
+
DataTable,
|
|
15
|
+
{
|
|
16
|
+
caption: "Invoices",
|
|
17
|
+
rows: [],
|
|
18
|
+
columns,
|
|
19
|
+
getRowId: () => "",
|
|
20
|
+
empty: /* @__PURE__ */ jsx(EmptyState, { title: "No invoice yet", description: "Your first invoice appears after your first payout.", action: /* @__PURE__ */ jsx(Button, { size: "sm", children: "Set up payouts" }) })
|
|
21
|
+
}
|
|
22
|
+
);
|
|
23
|
+
}
|
|
24
|
+
export {
|
|
25
|
+
DataTableEmpty as default
|
|
26
|
+
};
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { Button } from "@krizaka/ui/button";
|
|
2
|
+
import { DataTable } from "@krizaka/ui/data-table";
|
|
3
|
+
import { EmptyState } from "@krizaka/ui/empty-state";
|
|
4
|
+
|
|
5
|
+
const columns = [
|
|
6
|
+
{ id: "invoice", header: "Invoice", card: "title" as const },
|
|
7
|
+
{ id: "amount", header: "Amount", align: "end" as const },
|
|
8
|
+
];
|
|
9
|
+
|
|
10
|
+
// No record yet: say what to do next.
|
|
11
|
+
export default function DataTableEmpty() {
|
|
12
|
+
return (
|
|
13
|
+
<DataTable
|
|
14
|
+
caption="Invoices"
|
|
15
|
+
rows={[]}
|
|
16
|
+
columns={columns}
|
|
17
|
+
getRowId={() => ""}
|
|
18
|
+
empty={<EmptyState title="No invoice yet" description="Your first invoice appears after your first payout." action={<Button size="sm">Set up payouts</Button>} />}
|
|
19
|
+
/>
|
|
20
|
+
);
|
|
21
|
+
}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
// registry/examples/data-table/error.tsx
|
|
4
|
+
import { Button } from "@krizaka/ui/button";
|
|
5
|
+
import { DataTable } from "@krizaka/ui/data-table";
|
|
6
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
7
|
+
var columns = [
|
|
8
|
+
{ id: "event", header: "Event", card: "title" },
|
|
9
|
+
{ id: "at", header: "At", align: "end" }
|
|
10
|
+
];
|
|
11
|
+
function DataTableError() {
|
|
12
|
+
return /* @__PURE__ */ jsx(
|
|
13
|
+
DataTable,
|
|
14
|
+
{
|
|
15
|
+
caption: "Audit log",
|
|
16
|
+
rows: [],
|
|
17
|
+
columns,
|
|
18
|
+
getRowId: () => "",
|
|
19
|
+
error: /* @__PURE__ */ jsxs("div", { className: "flex flex-col items-center gap-3", children: [
|
|
20
|
+
/* @__PURE__ */ jsx("p", { className: "text-sm text-fg", children: "The audit log could not be loaded." }),
|
|
21
|
+
/* @__PURE__ */ jsx(Button, { size: "sm", variant: "outline", onClick: () => window.location.reload(), children: "Try again" })
|
|
22
|
+
] })
|
|
23
|
+
}
|
|
24
|
+
);
|
|
25
|
+
}
|
|
26
|
+
export {
|
|
27
|
+
DataTableError as default
|
|
28
|
+
};
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
import { Button } from "@krizaka/ui/button";
|
|
4
|
+
import { DataTable } from "@krizaka/ui/data-table";
|
|
5
|
+
|
|
6
|
+
const columns = [
|
|
7
|
+
{ id: "event", header: "Event", card: "title" as const },
|
|
8
|
+
{ id: "at", header: "At", align: "end" as const },
|
|
9
|
+
];
|
|
10
|
+
|
|
11
|
+
// The request failed: what happened, and a way to try again — announced, in place of the rows.
|
|
12
|
+
export default function DataTableError() {
|
|
13
|
+
return (
|
|
14
|
+
<DataTable
|
|
15
|
+
caption="Audit log"
|
|
16
|
+
rows={[]}
|
|
17
|
+
columns={columns}
|
|
18
|
+
getRowId={() => ""}
|
|
19
|
+
error={
|
|
20
|
+
<div className="flex flex-col items-center gap-3">
|
|
21
|
+
<p className="text-sm text-fg">The audit log could not be loaded.</p>
|
|
22
|
+
<Button size="sm" variant="outline" onClick={() => window.location.reload()}>
|
|
23
|
+
Try again
|
|
24
|
+
</Button>
|
|
25
|
+
</div>
|
|
26
|
+
}
|
|
27
|
+
/>
|
|
28
|
+
);
|
|
29
|
+
}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
// registry/examples/data-table/jobs.tsx
|
|
4
|
+
import { Badge } from "@krizaka/ui/badge";
|
|
5
|
+
import { DataTable } from "@krizaka/ui/data-table";
|
|
6
|
+
import { jsx } from "react/jsx-runtime";
|
|
7
|
+
var jobs = [
|
|
8
|
+
{ id: "job-4821", name: "Product shots, autumn", model: "Flux 1.1", status: "done", seconds: 42 },
|
|
9
|
+
{ id: "job-4822", name: "Podcast transcript", model: "Whisper large", status: "running", seconds: 318 },
|
|
10
|
+
{ id: "job-4823", name: "Trailer voice-over", model: "XTTS v2", status: "failed", seconds: 7 },
|
|
11
|
+
{ id: "job-4824", name: "Catalogue summaries", model: "Llama 3.3", status: "done", seconds: 96 }
|
|
12
|
+
];
|
|
13
|
+
var tone = { done: "success", running: "accent", failed: "danger" };
|
|
14
|
+
var columns = [
|
|
15
|
+
{ id: "name", header: "Job", sortable: true, card: "title" },
|
|
16
|
+
{ id: "model", header: "Model", sortable: true },
|
|
17
|
+
{ id: "status", header: "Status", cell: (job) => /* @__PURE__ */ jsx(Badge, { tone: tone[job.status], children: job.status }) },
|
|
18
|
+
{ id: "seconds", header: "Duration", sortable: true, align: "end", cell: (job) => `${job.seconds} s` }
|
|
19
|
+
];
|
|
20
|
+
function DataTableJobs() {
|
|
21
|
+
return /* @__PURE__ */ jsx(
|
|
22
|
+
DataTable,
|
|
23
|
+
{
|
|
24
|
+
caption: "Jobs",
|
|
25
|
+
rows: jobs,
|
|
26
|
+
columns,
|
|
27
|
+
getRowId: (job) => job.id,
|
|
28
|
+
rowLabel: (job) => job.name,
|
|
29
|
+
defaultSort: { column: "seconds", direction: "descending" },
|
|
30
|
+
selectable: true,
|
|
31
|
+
defaultSelected: ["job-4823"]
|
|
32
|
+
}
|
|
33
|
+
);
|
|
34
|
+
}
|
|
35
|
+
export {
|
|
36
|
+
DataTableJobs as default
|
|
37
|
+
};
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
import { Badge } from "@krizaka/ui/badge";
|
|
4
|
+
import { DataTable, type DataTableColumn } from "@krizaka/ui/data-table";
|
|
5
|
+
|
|
6
|
+
type Job = { id: string; name: string; model: string; status: "done" | "running" | "failed"; seconds: number };
|
|
7
|
+
const jobs: Job[] = [
|
|
8
|
+
{ id: "job-4821", name: "Product shots, autumn", model: "Flux 1.1", status: "done", seconds: 42 },
|
|
9
|
+
{ id: "job-4822", name: "Podcast transcript", model: "Whisper large", status: "running", seconds: 318 },
|
|
10
|
+
{ id: "job-4823", name: "Trailer voice-over", model: "XTTS v2", status: "failed", seconds: 7 },
|
|
11
|
+
{ id: "job-4824", name: "Catalogue summaries", model: "Llama 3.3", status: "done", seconds: 96 },
|
|
12
|
+
];
|
|
13
|
+
const tone = { done: "success", running: "accent", failed: "danger" } as const;
|
|
14
|
+
|
|
15
|
+
const columns: DataTableColumn<Job>[] = [
|
|
16
|
+
{ id: "name", header: "Job", sortable: true, card: "title" },
|
|
17
|
+
{ id: "model", header: "Model", sortable: true },
|
|
18
|
+
{ id: "status", header: "Status", cell: (job) => <Badge tone={tone[job.status]}>{job.status}</Badge> },
|
|
19
|
+
{ id: "seconds", header: "Duration", sortable: true, align: "end", cell: (job) => `${job.seconds} s` },
|
|
20
|
+
];
|
|
21
|
+
|
|
22
|
+
// Sort by a header, select rows for a bulk action; cards below 36rem of width.
|
|
23
|
+
export default function DataTableJobs() {
|
|
24
|
+
return (
|
|
25
|
+
<DataTable
|
|
26
|
+
caption="Jobs"
|
|
27
|
+
rows={jobs}
|
|
28
|
+
columns={columns}
|
|
29
|
+
getRowId={(job) => job.id}
|
|
30
|
+
rowLabel={(job) => job.name}
|
|
31
|
+
defaultSort={{ column: "seconds", direction: "descending" }}
|
|
32
|
+
selectable
|
|
33
|
+
defaultSelected={["job-4823"]}
|
|
34
|
+
/>
|
|
35
|
+
);
|
|
36
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
// registry/examples/data-table/loading.tsx
|
|
4
|
+
import { DataTable } from "@krizaka/ui/data-table";
|
|
5
|
+
import { jsx } from "react/jsx-runtime";
|
|
6
|
+
var columns = [
|
|
7
|
+
{ id: "user", header: "User", card: "title" },
|
|
8
|
+
{ id: "role", header: "Role" },
|
|
9
|
+
{ id: "joined", header: "Joined", align: "end" }
|
|
10
|
+
];
|
|
11
|
+
function DataTableLoading() {
|
|
12
|
+
return /* @__PURE__ */ jsx(DataTable, { caption: "Users", rows: [], columns, getRowId: () => "", loading: true, loadingRows: 4 });
|
|
13
|
+
}
|
|
14
|
+
export {
|
|
15
|
+
DataTableLoading as default
|
|
16
|
+
};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { DataTable } from "@krizaka/ui/data-table";
|
|
2
|
+
|
|
3
|
+
const columns = [
|
|
4
|
+
{ id: "user", header: "User", card: "title" as const },
|
|
5
|
+
{ id: "role", header: "Role" },
|
|
6
|
+
{ id: "joined", header: "Joined", align: "end" as const },
|
|
7
|
+
];
|
|
8
|
+
|
|
9
|
+
// The first page is on its way: skeleton rows, the table busy for screen readers.
|
|
10
|
+
export default function DataTableLoading() {
|
|
11
|
+
return <DataTable caption="Users" rows={[]} columns={columns} getRowId={() => ""} loading loadingRows={4} />;
|
|
12
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
// registry/examples/data-table/virtualized.tsx
|
|
4
|
+
import { DataTable } from "@krizaka/ui/data-table";
|
|
5
|
+
import { jsx } from "react/jsx-runtime";
|
|
6
|
+
var events = Array.from({ length: 5e3 }, (_, i) => ({
|
|
7
|
+
id: `evt-${i + 1}`,
|
|
8
|
+
kind: ["view", "tip", "follow", "comment"][i % 4],
|
|
9
|
+
at: `2026-10-${String(1 + i % 11).padStart(2, "0")} ${String(i % 24).padStart(2, "0")}:00`
|
|
10
|
+
}));
|
|
11
|
+
var columns = [
|
|
12
|
+
{ id: "id", header: "Event", sortable: true },
|
|
13
|
+
{ id: "kind", header: "Kind", sortable: true },
|
|
14
|
+
{ id: "at", header: "At", align: "end" }
|
|
15
|
+
];
|
|
16
|
+
function DataTableVirtualized() {
|
|
17
|
+
return /* @__PURE__ */ jsx(DataTable, { caption: "Events", rows: events, columns, getRowId: (e) => e.id, virtualize: { rowHeight: 44, height: 320 }, density: "compact" });
|
|
18
|
+
}
|
|
19
|
+
export {
|
|
20
|
+
DataTableVirtualized as default
|
|
21
|
+
};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
import { DataTable, type DataTableColumn } from "@krizaka/ui/data-table";
|
|
4
|
+
|
|
5
|
+
type Event = { id: string; kind: string; at: string };
|
|
6
|
+
const events: Event[] = Array.from({ length: 5000 }, (_, i) => ({
|
|
7
|
+
id: `evt-${i + 1}`,
|
|
8
|
+
kind: ["view", "tip", "follow", "comment"][i % 4]!,
|
|
9
|
+
at: `2026-10-${String(1 + (i % 11)).padStart(2, "0")} ${String(i % 24).padStart(2, "0")}:00`,
|
|
10
|
+
}));
|
|
11
|
+
const columns: DataTableColumn<Event>[] = [
|
|
12
|
+
{ id: "id", header: "Event", sortable: true },
|
|
13
|
+
{ id: "kind", header: "Kind", sortable: true },
|
|
14
|
+
{ id: "at", header: "At", align: "end" },
|
|
15
|
+
];
|
|
16
|
+
|
|
17
|
+
// 5,000 rows, ~20 rendered: the body scrolls, the header stays.
|
|
18
|
+
export default function DataTableVirtualized() {
|
|
19
|
+
return <DataTable caption="Events" rows={events} columns={columns} getRowId={(e) => e.id} virtualize={{ rowHeight: 44, height: 320 }} density="compact" />;
|
|
20
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
// registry/examples/date-picker/calendar.tsx
|
|
4
|
+
import { Calendar } from "@krizaka/ui/date-picker";
|
|
5
|
+
import * as React from "react";
|
|
6
|
+
import { jsx } from "react/jsx-runtime";
|
|
7
|
+
var weekend = (iso) => [0, 6].includes((/* @__PURE__ */ new Date(`${iso}T12:00:00`)).getDay());
|
|
8
|
+
function DatePickerCalendar() {
|
|
9
|
+
const [day, setDay] = React.useState("2026-10-15");
|
|
10
|
+
return /* @__PURE__ */ jsx("div", { className: "inline-block rounded-xl border border-border-default bg-surface-1 p-3", children: /* @__PURE__ */ jsx(Calendar, { locale: "en-GB", value: day, onSelect: setDay, isDateDisabled: weekend, min: "2026-10-12", today: "2026-10-11" }) });
|
|
11
|
+
}
|
|
12
|
+
export {
|
|
13
|
+
DatePickerCalendar as default
|
|
14
|
+
};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
import { Calendar } from "@krizaka/ui/date-picker";
|
|
4
|
+
import * as React from "react";
|
|
5
|
+
|
|
6
|
+
const weekend = (iso: string) => [0, 6].includes(new Date(`${iso}T12:00:00`).getDay());
|
|
7
|
+
|
|
8
|
+
// The month is the interface: pick a day for a call, weekends unavailable.
|
|
9
|
+
export default function DatePickerCalendar() {
|
|
10
|
+
const [day, setDay] = React.useState("2026-10-15");
|
|
11
|
+
return (
|
|
12
|
+
<div className="inline-block rounded-xl border border-border-default bg-surface-1 p-3">
|
|
13
|
+
<Calendar locale="en-GB" value={day} onSelect={setDay} isDateDisabled={weekend} min="2026-10-12" today="2026-10-11" />
|
|
14
|
+
</div>
|
|
15
|
+
);
|
|
16
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
// registry/examples/date-picker/french.tsx
|
|
4
|
+
import { DatePicker } from "@krizaka/ui/date-picker";
|
|
5
|
+
import { jsx } from "react/jsx-runtime";
|
|
6
|
+
function DatePickerFrench() {
|
|
7
|
+
return /* @__PURE__ */ jsx(
|
|
8
|
+
DatePicker,
|
|
9
|
+
{
|
|
10
|
+
label: "Date du rendez-vous",
|
|
11
|
+
locale: "fr-CA",
|
|
12
|
+
defaultValue: "2026-10-11",
|
|
13
|
+
today: "2026-10-11",
|
|
14
|
+
labels: { previousMonth: "Mois pr\xE9c\xE9dent", nextMonth: "Mois suivant", clear: "Effacer la date" }
|
|
15
|
+
}
|
|
16
|
+
);
|
|
17
|
+
}
|
|
18
|
+
export {
|
|
19
|
+
DatePickerFrench as default
|
|
20
|
+
};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { DatePicker } from "@krizaka/ui/date-picker";
|
|
2
|
+
|
|
3
|
+
// fr-CA: “11 oct. 2026”, the months and days in French, the week as Canada counts it.
|
|
4
|
+
export default function DatePickerFrench() {
|
|
5
|
+
return (
|
|
6
|
+
<DatePicker
|
|
7
|
+
label="Date du rendez-vous"
|
|
8
|
+
locale="fr-CA"
|
|
9
|
+
defaultValue="2026-10-11"
|
|
10
|
+
today="2026-10-11"
|
|
11
|
+
labels={{ previousMonth: "Mois précédent", nextMonth: "Mois suivant", clear: "Effacer la date" }}
|
|
12
|
+
/>
|
|
13
|
+
);
|
|
14
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
// registry/examples/date-picker/open.tsx
|
|
4
|
+
import { DatePicker } from "@krizaka/ui/date-picker";
|
|
5
|
+
import { jsx } from "react/jsx-runtime";
|
|
6
|
+
function DatePickerOpen({ defaultOpen }) {
|
|
7
|
+
return /* @__PURE__ */ jsx(DatePicker, { label: "Auction ends", locale: "en-US", defaultValue: "2026-10-18", min: "2026-10-11", today: "2026-10-11", defaultOpen });
|
|
8
|
+
}
|
|
9
|
+
export {
|
|
10
|
+
DatePickerOpen as default
|
|
11
|
+
};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
import { DatePicker } from "@krizaka/ui/date-picker";
|
|
4
|
+
|
|
5
|
+
// The calendar open: today marked, the chosen day filled, the past unavailable.
|
|
6
|
+
export default function DatePickerOpen({ defaultOpen }: { defaultOpen?: boolean }) {
|
|
7
|
+
return <DatePicker label="Auction ends" locale="en-US" defaultValue="2026-10-18" min="2026-10-11" today="2026-10-11" defaultOpen={defaultOpen} />;
|
|
8
|
+
}
|