@krizaka/ui 3.54.0 → 3.59.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 +1 -0
- package/dist/{RotatingWord-D9s7FXFD.d.ts → RotatingWord-COSabR2c.d.ts} +2 -1
- package/dist/account-menu.d.ts +8 -3
- package/dist/account-menu.js +8 -1
- package/dist/account-menu.js.map +1 -1
- package/dist/account-settings.d.ts +153 -61
- package/dist/account-settings.js +243 -160
- package/dist/account-settings.js.map +1 -1
- package/dist/achievement.d.ts +2 -1
- package/dist/action-bar.d.ts +3 -2
- package/dist/activity-feed.d.ts +2 -1
- package/dist/agenda.d.ts +2 -1
- package/dist/alert.d.ts +2 -1
- package/dist/anatomy-plate.d.ts +6 -2
- package/dist/anatomy-plate.js +4 -0
- package/dist/anatomy-plate.js.map +1 -1
- package/dist/app-header/search.d.ts +64 -0
- package/dist/app-header/search.js +70 -0
- package/dist/app-header/search.js.map +1 -0
- package/dist/app-header.d.ts +89 -4
- package/dist/app-header.js +63 -5
- package/dist/app-header.js.map +1 -1
- package/dist/app-shell.d.ts +26 -25
- package/dist/app-shell.js +31 -40
- package/dist/app-shell.js.map +1 -1
- package/dist/argument-card.d.ts +3 -2
- package/dist/argument-card.js +3 -3
- package/dist/audio-player.d.ts +2 -1
- package/dist/auth-layout.d.ts +11 -10
- package/dist/avatar/defaults.d.ts +2 -1
- package/dist/avatar.d.ts +2 -1
- package/dist/badge.d.ts +2 -1
- package/dist/bird-plate.d.ts +7 -3
- package/dist/bird-plate.js +2 -2
- package/dist/bird-plate.js.map +1 -1
- package/dist/blocks.css +235 -27
- package/dist/button.d.ts +2 -1
- package/dist/captcha.d.ts +2 -1
- package/dist/captcha.js +1 -0
- package/dist/captcha.js.map +1 -1
- package/dist/card-grid.d.ts +2 -1
- package/dist/card.d.ts +2 -1
- package/dist/catalogue-page.d.ts +82 -2
- package/dist/catalogue-page.js +156 -13
- package/dist/catalogue-page.js.map +1 -1
- package/dist/changelog-page.d.ts +2 -1
- package/dist/chapter.d.ts +2 -1
- package/dist/chat.d.ts +14 -13
- package/dist/chat.js +2 -2
- package/dist/chat.js.map +1 -1
- package/dist/checkbox.d.ts +2 -1
- package/dist/checkbox.js +1 -1
- package/dist/checkbox.js.map +1 -1
- package/dist/chip-link.d.ts +2 -1
- package/dist/chip-row.d.ts +8 -7
- package/dist/chip.d.ts +55 -1
- package/dist/chip.js +14 -98
- package/dist/chip.js.map +1 -1
- package/dist/choice-grid.d.ts +3 -2
- package/dist/choice-grid.js +28 -88
- package/dist/choice-grid.js.map +1 -1
- package/dist/chunk-27AWSJTK.js +46 -0
- package/dist/chunk-27AWSJTK.js.map +1 -0
- package/dist/{chunk-YGIN2YIY.js → chunk-3X3OF4TI.js} +2 -2
- package/dist/chunk-3X3OF4TI.js.map +1 -0
- package/dist/{chunk-KBQD6HE3.js → chunk-4GQH27IT.js} +3 -3
- package/dist/{chunk-KBQD6HE3.js.map → chunk-4GQH27IT.js.map} +1 -1
- package/dist/{chunk-YHKTYFOQ.js → chunk-5LANVCK7.js} +383 -107
- package/dist/chunk-5LANVCK7.js.map +1 -0
- package/dist/{chunk-KDXRYUD3.js → chunk-5QEXOGO2.js} +3 -1
- package/dist/{chunk-KDXRYUD3.js.map → chunk-5QEXOGO2.js.map} +1 -1
- package/dist/chunk-5VEVYDVC.js +11 -0
- package/dist/chunk-5VEVYDVC.js.map +1 -0
- package/dist/chunk-7J2L4HOD.js +340 -0
- package/dist/chunk-7J2L4HOD.js.map +1 -0
- package/dist/chunk-BDIU5LZB.js +18 -0
- package/dist/chunk-BDIU5LZB.js.map +1 -0
- package/dist/chunk-BQ4EOR2O.js +177 -0
- package/dist/chunk-BQ4EOR2O.js.map +1 -0
- package/dist/chunk-CSRKYZ53.js +39 -0
- package/dist/chunk-CSRKYZ53.js.map +1 -0
- package/dist/chunk-F6JTHPHE.js +399 -0
- package/dist/chunk-F6JTHPHE.js.map +1 -0
- package/dist/chunk-HEKDKM5Y.js +128 -0
- package/dist/chunk-HEKDKM5Y.js.map +1 -0
- package/dist/chunk-KGLRZMCY.js +16 -0
- package/dist/chunk-KGLRZMCY.js.map +1 -0
- package/dist/chunk-KID32IRJ.js +18 -0
- package/dist/chunk-KID32IRJ.js.map +1 -0
- package/dist/chunk-OGWB76BR.js +90 -0
- package/dist/chunk-OGWB76BR.js.map +1 -0
- package/dist/{chunk-4LYKBSOG.js → chunk-USPOIQV5.js} +2 -2
- package/dist/chunk-USPOIQV5.js.map +1 -0
- package/dist/chunk-UYGUSYIC.js +173 -0
- package/dist/chunk-UYGUSYIC.js.map +1 -0
- package/dist/{chunk-7NRSPHAF.js → chunk-VB7MWE2N.js} +2 -2
- package/dist/{chunk-7NRSPHAF.js.map → chunk-VB7MWE2N.js.map} +1 -1
- package/dist/chunk-WOZP3JLW.js +51 -0
- package/dist/chunk-WOZP3JLW.js.map +1 -0
- package/dist/chunk-XVXFMVG3.js +27 -0
- package/dist/chunk-XVXFMVG3.js.map +1 -0
- package/dist/chunk-YCZ7N6Q6.js +385 -0
- package/dist/chunk-YCZ7N6Q6.js.map +1 -0
- package/dist/code-block.d.ts +2 -1
- package/dist/code-block.js +81 -98
- package/dist/code-block.js.map +1 -1
- package/dist/combobox.d.ts +20 -19
- package/dist/combobox.js +3 -2
- package/dist/command.d.ts +21 -20
- package/dist/comparison-table.d.ts +2 -1
- package/dist/component-page.d.ts +6 -2
- package/dist/component-page.js +5 -0
- package/dist/component-page.js.map +1 -1
- package/dist/confirm-button.d.ts +2 -1
- package/dist/contact-page.d.ts +2 -1
- package/dist/continue-prompt.d.ts +6 -2
- package/dist/continue-prompt.js +4 -0
- package/dist/continue-prompt.js.map +1 -1
- package/dist/countdown.d.ts +2 -1
- package/dist/cover-hero.d.ts +20 -19
- package/dist/cover-hero.js +25 -42
- package/dist/cover-hero.js.map +1 -1
- package/dist/cta-panel.d.ts +2 -1
- package/dist/dashboard-layout.d.ts +50 -2
- package/dist/dashboard-layout.js +66 -11
- package/dist/dashboard-layout.js.map +1 -1
- package/dist/data-table.d.ts +103 -4
- package/dist/data-table.js +23 -7
- package/dist/date-picker.d.ts +29 -28
- package/dist/date-picker.js +2 -2
- package/dist/date-picker.js.map +1 -1
- package/dist/decision-list.d.ts +2 -1
- package/dist/description-list.d.ts +2 -1
- package/dist/detail-layout.d.ts +147 -3
- package/dist/detail-layout.js +143 -17
- package/dist/detail-layout.js.map +1 -1
- package/dist/{dialog-D42QwYb_.d.ts → dialog-DpUwec2g.d.ts} +2 -1
- package/dist/dialog.d.ts +3 -2
- package/dist/docs-article-page.d.ts +2 -1
- package/dist/docs-hub-page.d.ts +2 -1
- package/dist/docs-layout.d.ts +2 -1
- package/dist/docs-nav.d.ts +3 -10
- package/dist/document-viewer.d.ts +5 -4
- package/dist/doodle.d.ts +32 -0
- package/dist/doodle.js +70 -0
- package/dist/doodle.js.map +1 -0
- package/dist/drop-overlay.d.ts +14 -5
- package/dist/drop-overlay.js +16 -6
- package/dist/drop-overlay.js.map +1 -1
- package/dist/dropdown-menu.d.ts +2 -1
- package/dist/dropdown-menu.js +13 -74
- package/dist/dropdown-menu.js.map +1 -1
- package/dist/elephant.d.ts +4 -1
- package/dist/elephant.js +4 -0
- package/dist/elephant.js.map +1 -1
- package/dist/empty-state.d.ts +2 -1
- package/dist/engine-flow.d.ts +2 -1
- package/dist/error-page.d.ts +2 -1
- package/dist/field.js +1 -1
- package/dist/field.js.map +1 -1
- package/dist/file-upload.d.ts +14 -13
- package/dist/filter-bar.d.ts +84 -11
- package/dist/filter-bar.js +6 -2
- package/dist/flock.d.ts +3 -2
- package/dist/footnote.d.ts +2 -1
- package/dist/force-update-screen.d.ts +13 -8
- package/dist/force-update-screen.js +4 -0
- package/dist/force-update-screen.js.map +1 -1
- package/dist/form/server.d.ts +2 -1
- package/dist/form.d.ts +2 -1
- package/dist/gallery-page.d.ts +6 -2
- package/dist/gallery-page.js +4 -0
- package/dist/gallery-page.js.map +1 -1
- package/dist/genui.d.ts +2 -1
- package/dist/genui.js +5 -5
- package/dist/{geometry-DX-W-Yyf.d.ts → geometry-DZ4Q3hDQ.d.ts} +2 -1
- package/dist/glossary-term.d.ts +2 -1
- package/dist/glossary.d.ts +2 -1
- package/dist/glow-card.d.ts +2 -1
- package/dist/goal-gauge.d.ts +2 -1
- package/dist/grade-stamp.d.ts +23 -0
- package/dist/grade-stamp.js +42 -0
- package/dist/grade-stamp.js.map +1 -0
- package/dist/how-it-works-page.d.ts +2 -1
- package/dist/image-cropper.d.ts +15 -6
- package/dist/image-cropper.js +4 -0
- package/dist/image-cropper.js.map +1 -1
- package/dist/index.d.ts +3 -2
- package/dist/index.js +4 -4
- package/dist/iso.d.ts +2 -1
- package/dist/kanban.d.ts +5 -1
- package/dist/kanban.js +4 -0
- package/dist/kanban.js.map +1 -1
- package/dist/kbd.d.ts +2 -1
- package/dist/kind-config-editor.d.ts +152 -0
- package/dist/kind-config-editor.js +574 -0
- package/dist/kind-config-editor.js.map +1 -0
- package/dist/kpi-explained.d.ts +2 -1
- package/dist/landing-page.d.ts +2 -1
- package/dist/landscape.d.ts +6 -2
- package/dist/landscape.js +4 -0
- package/dist/landscape.js.map +1 -1
- package/dist/language-switch/server.d.ts +2 -1
- package/dist/language-switch.d.ts +11 -10
- package/dist/legal-page.d.ts +2 -1
- package/dist/link-card.d.ts +2 -1
- package/dist/list.d.ts +2 -1
- package/dist/list.js +1 -1
- package/dist/loader.d.ts +2 -1
- package/dist/longform-page.d.ts +2 -1
- package/dist/maintenance-screen.d.ts +10 -5
- package/dist/maintenance-screen.js +4 -0
- package/dist/maintenance-screen.js.map +1 -1
- package/dist/map.d.ts +8 -7
- package/dist/map.js +30 -0
- package/dist/map.js.map +1 -1
- package/dist/markdown.d.ts +7 -2
- package/dist/markdown.js +12 -5
- package/dist/markdown.js.map +1 -1
- package/dist/marketing-layout.d.ts +5 -4
- package/dist/marquee.d.ts +2 -1
- package/dist/mascot-quote.d.ts +2 -1
- package/dist/mascot-state.d.ts +3 -2
- package/dist/mascots.d.ts +4 -3
- package/dist/match-dialog.d.ts +6 -2
- package/dist/match-dialog.js +4 -0
- package/dist/match-dialog.js.map +1 -1
- package/dist/media-capture.d.ts +11 -5
- package/dist/media-capture.js +4 -0
- package/dist/media-capture.js.map +1 -1
- package/dist/media-gallery.d.ts +2 -1
- package/dist/media-grid.d.ts +3 -10
- package/dist/meta-row.d.ts +2 -1
- package/dist/meter.d.ts +2 -1
- package/dist/meter.js +5 -121
- package/dist/meter.js.map +1 -1
- package/dist/motion.d.ts +3 -2
- package/dist/native/form.d.ts +2 -1
- package/dist/native/list.d.ts +2 -1
- package/dist/native/map.d.ts +2 -1
- package/dist/native/map.js +30 -0
- package/dist/native/map.js.map +1 -1
- package/dist/native/markdown.d.ts +11 -3
- package/dist/native/markdown.js +46 -7
- package/dist/native/markdown.js.map +1 -1
- package/dist/native/media-capture.d.ts +3 -1
- package/dist/native/media-capture.js +5 -0
- package/dist/native/media-capture.js.map +1 -1
- package/dist/native/media-picker.d.ts +2 -1
- package/dist/native/vertical-video.d.ts +10 -3
- package/dist/native/vertical-video.js +6 -0
- package/dist/native/vertical-video.js.map +1 -1
- package/dist/native/video-player.d.ts +2 -1
- package/dist/native.d.ts +323 -4
- package/dist/native.js +1974 -1348
- package/dist/native.js.map +1 -1
- package/dist/nav-bar/me.d.ts +33 -0
- package/dist/nav-bar/me.js +23 -0
- package/dist/nav-bar/me.js.map +1 -0
- package/dist/nav-bar.d.ts +61 -2
- package/dist/nav-bar.js +92 -48
- package/dist/nav-bar.js.map +1 -1
- package/dist/next-actions.d.ts +2 -1
- package/dist/notification-preferences.d.ts +152 -0
- package/dist/notification-preferences.js +78 -0
- package/dist/notification-preferences.js.map +1 -0
- package/dist/number-ticker.d.ts +2 -1
- package/dist/opening-hours.d.ts +2 -1
- package/dist/page-header.d.ts +2 -1
- package/dist/page-header.js +1 -1
- package/dist/page-header.js.map +1 -1
- package/dist/page-hero.d.ts +2 -1
- package/dist/page-index.d.ts +2 -1
- package/dist/page.d.ts +2 -1
- package/dist/pagination.d.ts +2 -1
- package/dist/photo-grid.d.ts +2 -1
- package/dist/pointer-light.d.ts +2 -1
- package/dist/pointer-light.js +5 -0
- package/dist/pointer-light.js.map +1 -1
- package/dist/popover.d.ts +2 -1
- package/dist/pricing-page.d.ts +2 -1
- package/dist/product-page.d.ts +6 -2
- package/dist/product-page.js +4 -0
- package/dist/product-page.js.map +1 -1
- package/dist/profile-card.d.ts +120 -1
- package/dist/profile-card.js +68 -21
- package/dist/profile-card.js.map +1 -1
- package/dist/progress.d.ts +2 -1
- package/dist/promise-card.d.ts +6 -2
- package/dist/promise-card.js +4 -0
- package/dist/promise-card.js.map +1 -1
- package/dist/quota-meter.d.ts +114 -0
- package/dist/quota-meter.js +58 -0
- package/dist/quota-meter.js.map +1 -0
- package/dist/radio-group.d.ts +2 -1
- package/dist/radio-group.js +7 -9
- package/dist/radio-group.js.map +1 -1
- package/dist/rail-nav.d.ts +35 -18
- package/dist/rail-nav.js +45 -56
- package/dist/rail-nav.js.map +1 -1
- package/dist/recipes.d.ts +2 -1
- package/dist/retro-tv.d.ts +31 -0
- package/dist/retro-tv.js +124 -0
- package/dist/retro-tv.js.map +1 -0
- package/dist/router.d.ts +13 -1
- package/dist/router.js +85 -8
- package/dist/router.js.map +1 -1
- package/dist/scroll-stage.d.ts +7 -2
- package/dist/scroll-stage.js +5 -0
- package/dist/scroll-stage.js.map +1 -1
- package/dist/search-field.d.ts +2 -1
- package/dist/search-field.js +1 -1
- package/dist/section-backdrop.d.ts +2 -1
- package/dist/separator.d.ts +2 -1
- package/dist/service-card.d.ts +9 -8
- package/dist/settings-layout.d.ts +2 -1
- package/dist/settings-layout.js +10 -324
- package/dist/settings-layout.js.map +1 -1
- package/dist/showcase.d.ts +11 -3
- package/dist/showcase.js +5 -0
- package/dist/showcase.js.map +1 -1
- package/dist/signature.d.ts +20 -0
- package/dist/signature.js +39 -0
- package/dist/signature.js.map +1 -0
- package/dist/site-cahier.d.ts +187 -0
- package/dist/site-cahier.js +844 -0
- package/dist/site-cahier.js.map +1 -0
- package/dist/site-footer.d.ts +2 -1
- package/dist/site-footer.js +1 -1
- package/dist/sites.d.ts +2 -1
- package/dist/sites.js +1 -1
- package/dist/sites.js.map +1 -1
- package/dist/skeleton.d.ts +2 -1
- package/dist/skip-link.d.ts +2 -1
- package/dist/slider.d.ts +2 -1
- package/dist/slot-picker.d.ts +86 -13
- package/dist/slot-picker.js +98 -16
- package/dist/slot-picker.js.map +1 -1
- package/dist/slot.d.ts +1 -1
- package/dist/specimen-tag.d.ts +2 -1
- package/dist/speed-lines.d.ts +19 -0
- package/dist/speed-lines.js +45 -0
- package/dist/speed-lines.js.map +1 -0
- package/dist/spinner.d.ts +2 -1
- package/dist/split-view.d.ts +2 -1
- package/dist/stage-banner.d.ts +2 -1
- package/dist/stat.d.ts +2 -1
- package/dist/stat.js +1 -1
- package/dist/stat.js.map +1 -1
- package/dist/status-chip.d.ts +44 -0
- package/dist/status-chip.js +137 -0
- package/dist/status-chip.js.map +1 -0
- package/dist/status-page.d.ts +6 -2
- package/dist/status-page.js +5 -0
- package/dist/status-page.js.map +1 -1
- package/dist/step-progress.d.ts +2 -1
- package/dist/step-showcase.d.ts +2 -1
- package/dist/stepper.d.ts +2 -1
- package/dist/sticky-action.d.ts +28 -5
- package/dist/sticky-action.js +10 -4
- package/dist/sticky-action.js.map +1 -1
- package/dist/stuck.d.ts +28 -0
- package/dist/stuck.js +26 -0
- package/dist/stuck.js.map +1 -0
- package/dist/swipe-deck.d.ts +11 -3
- package/dist/swipe-deck.js +5 -0
- package/dist/swipe-deck.js.map +1 -1
- package/dist/switch.d.ts +2 -1
- package/dist/switch.js +4 -32
- package/dist/switch.js.map +1 -1
- package/dist/tabs.d.ts +48 -8
- package/dist/tabs.js +62 -12
- package/dist/tabs.js.map +1 -1
- package/dist/tag-input.d.ts +2 -1
- package/dist/tag-input.js +3 -2
- package/dist/tag-input.js.map +1 -1
- package/dist/tag-selector.d.ts +30 -4
- package/dist/tag-selector.js +90 -8
- package/dist/tag-selector.js.map +1 -1
- package/dist/taped-photo.d.ts +2 -1
- package/dist/taped-photo.js +3 -20
- package/dist/taped-photo.js.map +1 -1
- package/dist/terminal-replay.d.ts +6 -2
- package/dist/terminal-replay.js +5 -1
- package/dist/terminal-replay.js.map +1 -1
- package/dist/text-style/server.d.ts +2 -1
- package/dist/text-style.d.ts +2 -1
- package/dist/theme.d.ts +21 -1
- package/dist/theme.js +37 -1
- package/dist/theme.js.map +1 -1
- package/dist/toast.d.ts +2 -1
- package/dist/toc.d.ts +2 -1
- package/dist/tooltip.d.ts +2 -1
- package/dist/tree-view.d.ts +2 -1
- package/dist/tree-view.js +4 -0
- package/dist/tree-view.js.map +1 -1
- package/dist/update-prompt.d.ts +16 -11
- package/dist/update-prompt.js +4 -0
- package/dist/update-prompt.js.map +1 -1
- package/dist/upload-queue.d.ts +2 -1
- package/dist/verified-badge.d.ts +2 -1
- package/dist/versus-card.d.ts +40 -0
- package/dist/versus-card.js +40 -0
- package/dist/versus-card.js.map +1 -0
- package/dist/vertical-video.d.ts +2 -1
- package/dist/video-player.d.ts +20 -19
- package/dist/video-player.js +7 -376
- package/dist/video-player.js.map +1 -1
- package/dist/video-trimmer.d.ts +8 -2
- package/dist/video-trimmer.js +4 -0
- package/dist/video-trimmer.js.map +1 -1
- package/dist/virtual.d.ts +8 -7
- package/dist/waveform.d.ts +2 -1
- package/package.json +249 -52
- package/registry/account-menu.json +9 -8
- package/registry/account-settings.json +258 -6
- package/registry/achievement.json +3 -4
- package/registry/action-bar.json +3 -3
- package/registry/action-sheet.json +1 -0
- package/registry/activity-feed.json +2 -1
- package/registry/agenda.json +1 -1
- package/registry/alert.json +1 -1
- package/registry/anatomy-plate.json +13 -5
- package/registry/app-header.json +470 -23
- package/registry/app-shell.json +2 -2
- package/registry/argument-card.json +1 -1
- package/registry/audio-player.json +1 -1
- package/registry/auth-layout.json +1 -1
- package/registry/avatar.json +3 -2
- package/registry/badge.json +2 -1
- package/registry/bird-plate.json +16 -2
- package/registry/button.json +7 -6
- package/registry/captcha.json +1 -1
- package/registry/card-grid.json +1 -1
- package/registry/card.json +7 -6
- package/registry/catalogue-page.json +117 -8
- package/registry/changelog-page.json +3 -5
- package/registry/chapter.json +1 -1
- package/registry/chat.json +3 -2
- package/registry/checkbox.json +4 -3
- package/registry/chip-link.json +2 -2
- package/registry/chip-row.json +2 -2
- package/registry/chip.json +388 -12
- package/registry/choice-grid.json +3 -4
- package/registry/code-block.json +1 -1
- package/registry/combobox.json +3 -2
- package/registry/command.json +2 -2
- package/registry/comparison-table.json +1 -1
- package/registry/component-page.json +14 -5
- package/registry/confirm-button.json +4 -4
- package/registry/contact-page.json +1 -1
- package/registry/continue-prompt.json +13 -5
- package/registry/countdown.json +4 -3
- package/registry/cover-hero.json +3 -4
- package/registry/cta-panel.json +1 -1
- package/registry/dashboard-layout.json +91 -5
- package/registry/data-table.json +215 -8
- package/registry/date-picker.json +5 -4
- package/registry/decision-list.json +1 -1
- package/registry/description-list.json +2 -1
- package/registry/detail-layout.json +226 -8
- package/registry/dialog.json +7 -6
- package/registry/docs-article-page.json +3 -4
- package/registry/docs-hub-page.json +1 -1
- package/registry/docs-layout.json +1 -1
- package/registry/docs-nav.json +1 -1
- package/registry/document-viewer.json +3 -5
- package/registry/doodle.json +302 -0
- package/registry/drop-overlay.json +30 -16
- package/registry/dropdown-menu.json +2 -2
- package/registry/elephant.json +15 -7
- package/registry/empty-state.json +2 -1
- package/registry/engine-flow.json +1 -1
- package/registry/error-page.json +3 -5
- package/registry/examples/account-settings/appearance.d.ts +4 -0
- package/registry/examples/account-settings/appearance.js +40 -0
- package/registry/examples/account-settings/appearance.tsx +30 -0
- package/registry/examples/app-header/family.d.ts +4 -0
- package/registry/examples/app-header/family.js +41 -0
- package/registry/examples/app-header/family.tsx +37 -0
- package/registry/examples/app-header/native/family.d.ts +4 -0
- package/registry/examples/app-header/native/family.dark.png +0 -0
- package/registry/examples/app-header/native/family.js +25 -0
- package/registry/examples/app-header/native/family.light.png +0 -0
- package/registry/examples/app-header/native/family.tsx +33 -0
- package/registry/examples/catalogue-page/clients.d.ts +4 -0
- package/registry/examples/catalogue-page/clients.js +49 -0
- package/registry/examples/catalogue-page/clients.tsx +61 -0
- package/registry/examples/chip/marker-picker.d.ts +4 -0
- package/registry/examples/chip/marker-picker.js +17 -0
- package/registry/examples/chip/marker-picker.tsx +17 -0
- package/registry/examples/chip/native/marker-picker.d.ts +4 -0
- package/registry/examples/chip/native/marker-picker.dark.png +0 -0
- package/registry/examples/chip/native/marker-picker.js +18 -0
- package/registry/examples/chip/native/marker-picker.light.png +0 -0
- package/registry/examples/chip/native/marker-picker.tsx +16 -0
- package/registry/examples/chip/native/tags.d.ts +4 -0
- package/registry/examples/chip/native/tags.dark.png +0 -0
- package/registry/examples/chip/native/tags.js +22 -0
- package/registry/examples/chip/native/tags.light.png +0 -0
- package/registry/examples/chip/native/tags.tsx +20 -0
- package/registry/examples/chip/tags.d.ts +4 -0
- package/registry/examples/chip/tags.js +26 -0
- package/registry/examples/chip/tags.tsx +23 -0
- package/registry/examples/dashboard-layout/today.d.ts +4 -0
- package/registry/examples/dashboard-layout/today.js +54 -0
- package/registry/examples/dashboard-layout/today.tsx +63 -0
- package/registry/examples/data-table/applicant-files.d.ts +4 -0
- package/registry/examples/data-table/applicant-files.js +24 -0
- package/registry/examples/data-table/applicant-files.tsx +23 -0
- package/registry/examples/data-table/bulk.d.ts +4 -0
- package/registry/examples/data-table/bulk.js +45 -0
- package/registry/examples/data-table/bulk.tsx +34 -0
- package/registry/examples/data-table/checks.d.ts +4 -0
- package/registry/examples/data-table/checks.js +25 -0
- package/registry/examples/data-table/checks.tsx +24 -0
- package/registry/examples/detail-layout/client.d.ts +4 -0
- package/registry/examples/detail-layout/client.js +40 -0
- package/registry/examples/detail-layout/client.tsx +39 -0
- package/registry/examples/detail-layout/new-invoice.d.ts +4 -0
- package/registry/examples/detail-layout/new-invoice.js +44 -0
- package/registry/examples/detail-layout/new-invoice.tsx +34 -0
- package/registry/examples/detail-layout/profile.d.ts +4 -0
- package/registry/examples/detail-layout/profile.js +26 -0
- package/registry/examples/detail-layout/profile.tsx +21 -0
- package/registry/examples/doodle/bird-sketch.d.ts +4 -0
- package/registry/examples/doodle/bird-sketch.js +11 -0
- package/registry/examples/doodle/bird-sketch.tsx +12 -0
- package/registry/examples/doodle/kinds.d.ts +4 -0
- package/registry/examples/doodle/kinds.js +17 -0
- package/registry/examples/doodle/kinds.tsx +14 -0
- package/registry/examples/doodle/margin-marks.d.ts +4 -0
- package/registry/examples/doodle/margin-marks.js +27 -0
- package/registry/examples/doodle/margin-marks.tsx +19 -0
- package/registry/examples/doodle/margin.d.ts +4 -0
- package/registry/examples/doodle/margin.js +17 -0
- package/registry/examples/doodle/margin.tsx +17 -0
- package/registry/examples/filter-bar/views.d.ts +4 -0
- package/registry/examples/filter-bar/views.js +39 -0
- package/registry/examples/filter-bar/views.tsx +30 -0
- package/registry/examples/grade-stamp/coverage.d.ts +4 -0
- package/registry/examples/grade-stamp/coverage.js +12 -0
- package/registry/examples/grade-stamp/coverage.tsx +8 -0
- package/registry/examples/grade-stamp/lighthouse.d.ts +4 -0
- package/registry/examples/grade-stamp/lighthouse.js +12 -0
- package/registry/examples/grade-stamp/lighthouse.tsx +14 -0
- package/registry/examples/kind-config-editor/derived.d.ts +4 -0
- package/registry/examples/kind-config-editor/derived.js +26 -0
- package/registry/examples/kind-config-editor/derived.tsx +16 -0
- package/registry/examples/kind-config-editor/native/status-set.d.ts +4 -0
- package/registry/examples/kind-config-editor/native/status-set.dark.png +0 -0
- package/registry/examples/kind-config-editor/native/status-set.js +22 -0
- package/registry/examples/kind-config-editor/native/status-set.light.png +0 -0
- package/registry/examples/kind-config-editor/native/status-set.tsx +19 -0
- package/registry/examples/kind-config-editor/native/tag-set.d.ts +4 -0
- package/registry/examples/kind-config-editor/native/tag-set.dark.png +0 -0
- package/registry/examples/kind-config-editor/native/tag-set.js +20 -0
- package/registry/examples/kind-config-editor/native/tag-set.light.png +0 -0
- package/registry/examples/kind-config-editor/native/tag-set.tsx +18 -0
- package/registry/examples/kind-config-editor/status-set.d.ts +4 -0
- package/registry/examples/kind-config-editor/status-set.js +29 -0
- package/registry/examples/kind-config-editor/status-set.tsx +25 -0
- package/registry/examples/kind-config-editor/tag-set.d.ts +4 -0
- package/registry/examples/kind-config-editor/tag-set.js +20 -0
- package/registry/examples/kind-config-editor/tag-set.tsx +18 -0
- package/registry/examples/markdown/native/basic.dark.png +0 -0
- package/registry/examples/markdown/native/basic.light.png +0 -0
- package/registry/examples/markdown/native/wide-table.d.ts +4 -0
- package/registry/examples/markdown/native/wide-table.dark.png +0 -0
- package/registry/examples/markdown/native/wide-table.js +23 -0
- package/registry/examples/markdown/native/wide-table.light.png +0 -0
- package/registry/examples/markdown/native/wide-table.tsx +22 -0
- package/registry/examples/markdown/wide-table.d.ts +4 -0
- package/registry/examples/markdown/wide-table.js +28 -0
- package/registry/examples/markdown/wide-table.tsx +23 -0
- package/registry/examples/nav-bar/family-product.js +2 -4
- package/registry/examples/nav-bar/family-product.tsx +3 -5
- package/registry/examples/notification-preferences/default.d.ts +4 -0
- package/registry/examples/notification-preferences/default.js +29 -0
- package/registry/examples/notification-preferences/default.tsx +28 -0
- package/registry/examples/profile-card/banner.d.ts +4 -0
- package/registry/examples/profile-card/banner.js +28 -0
- package/registry/examples/profile-card/banner.tsx +24 -0
- package/registry/examples/profile-card/native/banner.d.ts +4 -0
- package/registry/examples/profile-card/native/banner.dark.png +0 -0
- package/registry/examples/profile-card/native/banner.js +22 -0
- package/registry/examples/profile-card/native/banner.light.png +0 -0
- package/registry/examples/profile-card/native/banner.tsx +18 -0
- package/registry/examples/quota-meter/default.d.ts +4 -0
- package/registry/examples/quota-meter/default.js +26 -0
- package/registry/examples/quota-meter/default.tsx +20 -0
- package/registry/examples/quota-meter/full.d.ts +4 -0
- package/registry/examples/quota-meter/full.js +25 -0
- package/registry/examples/quota-meter/full.tsx +18 -0
- package/registry/examples/rail-nav/shortcuts.d.ts +4 -0
- package/registry/examples/rail-nav/shortcuts.js +49 -0
- package/registry/examples/rail-nav/shortcuts.tsx +40 -0
- package/registry/examples/retro-tv/cabinet.d.ts +4 -0
- package/registry/examples/retro-tv/cabinet.js +12 -0
- package/registry/examples/retro-tv/cabinet.tsx +7 -0
- package/registry/examples/retro-tv/portable.d.ts +4 -0
- package/registry/examples/retro-tv/portable.js +12 -0
- package/registry/examples/retro-tv/portable.tsx +7 -0
- package/registry/examples/signature/both.d.ts +4 -0
- package/registry/examples/signature/both.js +11 -0
- package/registry/examples/signature/both.tsx +6 -0
- package/registry/examples/signature/variants.d.ts +4 -0
- package/registry/examples/signature/variants.js +14 -0
- package/registry/examples/signature/variants.tsx +11 -0
- package/registry/examples/site-cahier/java-releases.d.ts +4 -0
- package/registry/examples/site-cahier/java-releases.js +33 -0
- package/registry/examples/site-cahier/java-releases.tsx +32 -0
- package/registry/examples/site-cahier/motion-lab.d.ts +4 -0
- package/registry/examples/site-cahier/motion-lab.js +32 -0
- package/registry/examples/site-cahier/motion-lab.tsx +29 -0
- package/registry/examples/site-cahier/ts-changelog.d.ts +4 -0
- package/registry/examples/site-cahier/ts-changelog.js +24 -0
- package/registry/examples/site-cahier/ts-changelog.tsx +20 -0
- package/registry/examples/site-cahier/ts-doc.d.ts +4 -0
- package/registry/examples/site-cahier/ts-doc.js +38 -0
- package/registry/examples/site-cahier/ts-doc.tsx +27 -0
- package/registry/examples/site-cahier/ui-home.d.ts +4 -0
- package/registry/examples/site-cahier/ui-home.js +46 -0
- package/registry/examples/site-cahier/ui-home.tsx +40 -0
- package/registry/examples/slot-picker/weeks.d.ts +4 -0
- package/registry/examples/slot-picker/weeks.js +45 -0
- package/registry/examples/slot-picker/weeks.tsx +28 -0
- package/registry/examples/speed-lines/hero.d.ts +4 -0
- package/registry/examples/speed-lines/hero.js +11 -0
- package/registry/examples/speed-lines/hero.tsx +12 -0
- package/registry/examples/speed-lines/streaks.d.ts +4 -0
- package/registry/examples/speed-lines/streaks.js +11 -0
- package/registry/examples/speed-lines/streaks.tsx +12 -0
- package/registry/examples/status-chip/default.d.ts +4 -0
- package/registry/examples/status-chip/default.js +35 -0
- package/registry/examples/status-chip/default.tsx +32 -0
- package/registry/examples/status-chip/native/default.d.ts +4 -0
- package/registry/examples/status-chip/native/default.dark.png +0 -0
- package/registry/examples/status-chip/native/default.js +26 -0
- package/registry/examples/status-chip/native/default.light.png +0 -0
- package/registry/examples/status-chip/native/default.tsx +20 -0
- package/registry/examples/stuck/card.d.ts +4 -0
- package/registry/examples/stuck/card.js +13 -0
- package/registry/examples/stuck/card.tsx +14 -0
- package/registry/examples/stuck/holds.d.ts +4 -0
- package/registry/examples/stuck/holds.js +12 -0
- package/registry/examples/stuck/holds.tsx +16 -0
- package/registry/examples/stuck/tag.d.ts +4 -0
- package/registry/examples/stuck/tag.js +12 -0
- package/registry/examples/stuck/tag.tsx +13 -0
- package/registry/examples/tabs/binder.d.ts +4 -0
- package/registry/examples/tabs/binder.js +22 -0
- package/registry/examples/tabs/binder.tsx +20 -0
- package/registry/examples/tabs/native/binder.d.ts +4 -0
- package/registry/examples/tabs/native/binder.dark.png +0 -0
- package/registry/examples/tabs/native/binder.js +26 -0
- package/registry/examples/tabs/native/binder.light.png +0 -0
- package/registry/examples/tabs/native/binder.tsx +22 -0
- package/registry/examples/tag-selector/creatable.d.ts +4 -0
- package/registry/examples/tag-selector/creatable.js +41 -0
- package/registry/examples/tag-selector/creatable.tsx +29 -0
- package/registry/examples/tag-selector/native/tags.d.ts +4 -0
- package/registry/examples/tag-selector/native/tags.dark.png +0 -0
- package/registry/examples/tag-selector/native/tags.js +19 -0
- package/registry/examples/tag-selector/native/tags.light.png +0 -0
- package/registry/examples/tag-selector/native/tags.tsx +19 -0
- package/registry/examples/versus-card/alternatives.d.ts +4 -0
- package/registry/examples/versus-card/alternatives.js +20 -0
- package/registry/examples/versus-card/alternatives.tsx +14 -0
- package/registry/examples/versus-card/releases.d.ts +4 -0
- package/registry/examples/versus-card/releases.js +35 -0
- package/registry/examples/versus-card/releases.tsx +29 -0
- package/registry/fab.json +1 -0
- package/registry/field.json +3 -2
- package/registry/file-upload.json +6 -11
- package/registry/filter-bar.json +209 -9
- package/registry/flock.json +3 -4
- package/registry/footnote.json +2 -3
- package/registry/force-update-screen.json +14 -5
- package/registry/form.json +5 -4
- package/registry/gallery-page.json +14 -5
- package/registry/genui.json +2 -2
- package/registry/glossary-term.json +1 -1
- package/registry/glossary.json +1 -1
- package/registry/glow-card.json +2 -2
- package/registry/goal-gauge.json +2 -1
- package/registry/grade-stamp.json +227 -0
- package/registry/header.json +1 -0
- package/registry/how-it-works-page.json +3 -5
- package/registry/image-cropper.json +13 -5
- package/registry/image-viewer.json +3 -4
- package/registry/index.json +612 -105
- package/registry/iso.json +1 -1
- package/registry/kanban.json +13 -5
- package/registry/kbd.json +1 -1
- package/registry/kind-config-editor.json +565 -0
- package/registry/kpi-explained.json +2 -2
- package/registry/landing-page.json +3 -5
- package/registry/landscape.json +13 -5
- package/registry/language-switch.json +1 -1
- package/registry/legal-page.json +1 -1
- package/registry/link-card.json +1 -1
- package/registry/list.json +2 -1
- package/registry/loader.json +2 -1
- package/registry/longform-page.json +1 -1
- package/registry/maintenance-screen.json +14 -5
- package/registry/map.json +3 -2
- package/registry/markdown.json +86 -9
- package/registry/marketing-layout.json +1 -1
- package/registry/marquee.json +1 -1
- package/registry/mascot-quote.json +1 -1
- package/registry/mascot-state.json +12 -11
- package/registry/mascots.json +2 -1
- package/registry/match-dialog.json +14 -5
- package/registry/media-capture.json +14 -5
- package/registry/media-gallery.json +3 -5
- package/registry/media-grid.json +1 -1
- package/registry/media-picker.json +2 -3
- package/registry/meta-row.json +2 -1
- package/registry/meter.json +4 -3
- package/registry/nav-bar.json +100 -9
- package/registry/next-actions.json +1 -1
- package/registry/notification-preferences.json +250 -0
- package/registry/number-ticker.json +2 -1
- package/registry/onboarding.json +1 -0
- package/registry/opening-hours.json +1 -1
- package/registry/otp-input.json +1 -0
- package/registry/page-header.json +2 -2
- package/registry/page-hero.json +1 -1
- package/registry/page-index.json +1 -1
- package/registry/page.json +3 -3
- package/registry/pagination.json +2 -1
- package/registry/permission-prompt.json +2 -2
- package/registry/photo-grid.json +4 -4
- package/registry/pointer-light.json +6 -2
- package/registry/popover.json +2 -2
- package/registry/pricing-page.json +4 -6
- package/registry/product-page.json +14 -5
- package/registry/profile-card.json +232 -8
- package/registry/progress.json +4 -3
- package/registry/promise-card.json +13 -5
- package/registry/pull-to-refresh.json +1 -0
- package/registry/quota-meter.json +308 -0
- package/registry/radio-group.json +4 -3
- package/registry/rail-nav.json +48 -10
- package/registry/recipes.json +1 -1
- package/registry/retro-tv.json +478 -0
- package/registry/router.json +3 -3
- package/registry/screen.json +1 -0
- package/registry/scroll-stage.json +14 -5
- package/registry/search-field.json +3 -2
- package/registry/section-backdrop.json +1 -1
- package/registry/segmented.json +1 -0
- package/registry/separator.json +2 -2
- package/registry/service-card.json +1 -1
- package/registry/settings-layout.json +2 -1
- package/registry/showcase.json +14 -5
- package/registry/signature.json +185 -0
- package/registry/site-cahier.json +548 -0
- package/registry/site-footer.json +3 -3
- package/registry/sites.json +2 -2
- package/registry/skeleton.json +2 -1
- package/registry/skip-link.json +1 -1
- package/registry/slider.json +5 -4
- package/registry/slot-picker.json +156 -10
- package/registry/slot.json +2 -2
- package/registry/specimen-tag.json +1 -1
- package/registry/speed-lines.json +174 -0
- package/registry/spinner.json +4 -3
- package/registry/splash-handoff.json +1 -0
- package/registry/split-view.json +1 -1
- package/registry/stage-banner.json +2 -3
- package/registry/stat.json +2 -2
- package/registry/status-chip.json +350 -0
- package/registry/status-page.json +13 -5
- package/registry/step-progress.json +2 -1
- package/registry/step-showcase.json +3 -5
- package/registry/stepper.json +2 -1
- package/registry/sticky-action.json +38 -8
- package/registry/stuck.json +219 -0
- package/registry/swipe-deck.json +14 -5
- package/registry/swipeable-row.json +1 -0
- package/registry/switch.json +3 -2
- package/registry/tab-bar.json +1 -0
- package/registry/tabs.json +154 -22
- package/registry/tag-input.json +1 -1
- package/registry/tag-selector.json +190 -12
- package/registry/taped-photo.json +1 -1
- package/registry/terminal-replay.json +14 -5
- package/registry/text-style.json +5 -5
- package/registry/theme.json +4 -3
- package/registry/toast.json +2 -1
- package/registry/toc.json +1 -1
- package/registry/tooltip.json +2 -2
- package/registry/tree-view.json +6 -2
- package/registry/txt.json +1 -0
- package/registry/update-prompt.json +14 -5
- package/registry/upload-queue.json +1 -1
- package/registry/verified-badge.json +6 -6
- package/registry/versus-card.json +194 -0
- package/registry/vertical-video.json +8 -3
- package/registry/video-player.json +5 -6
- package/registry/video-trimmer.json +13 -5
- package/registry/virtual.json +2 -2
- package/registry/waveform.json +4 -3
- package/dist/chunk-4LYKBSOG.js.map +0 -1
- package/dist/chunk-HHFWK2HH.js +0 -163
- package/dist/chunk-HHFWK2HH.js.map +0 -1
- package/dist/chunk-R3LTSMS5.js +0 -75
- package/dist/chunk-R3LTSMS5.js.map +0 -1
- package/dist/chunk-YGIN2YIY.js.map +0 -1
- package/dist/chunk-YHKTYFOQ.js.map +0 -1
- package/dist/chunk-ZQW7LF4Y.js +0 -179
- package/dist/chunk-ZQW7LF4Y.js.map +0 -1
|
@@ -44,6 +44,7 @@
|
|
|
44
44
|
"`AvatarPicker` is one radiogroup — never a row of circles with loose radios; keep the upload inside its grid, after the pictures.",
|
|
45
45
|
"Name every language in its own language and label the control: « Langue », never an unlabelled switch.",
|
|
46
46
|
"Pass every word translated; the member-since date is formatted by the app in the viewer's language.",
|
|
47
|
+
"Appearance: pass the themes the product offers (system, light, dark, then Blueprint and Carbone if wanted — never a paper theme inside a signed-in product) from `appearance` of @krizaka/tokens, and only the accents that read on all of them (`appearance.passes`). The change applies at once (`useAppearance()` of `@krizaka/ui/theme`, restored before paint by `ThemeScript`); save it in the account too so it follows the person. Sound is opt-in, off by default, never under reduced motion; density is `html[data-density]`.",
|
|
47
48
|
"Section patterns (security, subscription, storage, my data) are flat sections of `SettingsRow`s: the billing portal is one link, the export one button, the delete a `ConfirmButton`."
|
|
48
49
|
],
|
|
49
50
|
"accessibility": {
|
|
@@ -77,7 +78,7 @@
|
|
|
77
78
|
],
|
|
78
79
|
"web": {
|
|
79
80
|
"entry": "@krizaka/ui/account-settings",
|
|
80
|
-
"import": "import { AccountProfileCard, AvatarPicker, ChoiceCards, LanguagePicker } from \"@krizaka/ui/account-settings\";",
|
|
81
|
+
"import": "import { AccountProfileCard, AvatarPicker, ChoiceCards, LanguagePicker, AppearanceSettings } from \"@krizaka/ui/account-settings\";",
|
|
81
82
|
"props": [
|
|
82
83
|
{
|
|
83
84
|
"component": "AccountProfileCard",
|
|
@@ -148,6 +149,124 @@
|
|
|
148
149
|
}
|
|
149
150
|
]
|
|
150
151
|
},
|
|
152
|
+
{
|
|
153
|
+
"component": "AppearanceSettings",
|
|
154
|
+
"description": "The appearance rows of a settings page: theme cards, accent, density, language, sound.",
|
|
155
|
+
"props": [
|
|
156
|
+
{
|
|
157
|
+
"name": "onThemeChange",
|
|
158
|
+
"type": "(id: string) => void",
|
|
159
|
+
"default": null,
|
|
160
|
+
"description": "Called with the id chosen.",
|
|
161
|
+
"required": true
|
|
162
|
+
},
|
|
163
|
+
{
|
|
164
|
+
"name": "theme",
|
|
165
|
+
"type": "string",
|
|
166
|
+
"default": null,
|
|
167
|
+
"description": "The id of the theme chosen.",
|
|
168
|
+
"required": true
|
|
169
|
+
},
|
|
170
|
+
{
|
|
171
|
+
"name": "themes",
|
|
172
|
+
"type": "readonly ThemeCardOption[]",
|
|
173
|
+
"default": null,
|
|
174
|
+
"description": "The themes offered: at least system, light and dark.",
|
|
175
|
+
"required": true
|
|
176
|
+
},
|
|
177
|
+
{
|
|
178
|
+
"name": "accent",
|
|
179
|
+
"type": "string | null",
|
|
180
|
+
"default": null,
|
|
181
|
+
"description": "The id of the accent chosen; null for the product's own.",
|
|
182
|
+
"required": false
|
|
183
|
+
},
|
|
184
|
+
{
|
|
185
|
+
"name": "accents",
|
|
186
|
+
"type": "readonly AccentOption[]",
|
|
187
|
+
"default": null,
|
|
188
|
+
"description": "The accents offered (the product's own first). Without it the row is not shown.",
|
|
189
|
+
"required": false
|
|
190
|
+
},
|
|
191
|
+
{
|
|
192
|
+
"name": "className",
|
|
193
|
+
"type": "string",
|
|
194
|
+
"default": null,
|
|
195
|
+
"description": "Classes merged on the root.",
|
|
196
|
+
"required": false
|
|
197
|
+
},
|
|
198
|
+
{
|
|
199
|
+
"name": "densities",
|
|
200
|
+
"type": "readonly { value: string; label: string; }[]",
|
|
201
|
+
"default": null,
|
|
202
|
+
"description": "The densities offered, with their names (`standard`, `compact`).",
|
|
203
|
+
"required": false
|
|
204
|
+
},
|
|
205
|
+
{
|
|
206
|
+
"name": "density",
|
|
207
|
+
"type": "string",
|
|
208
|
+
"default": null,
|
|
209
|
+
"description": "The density chosen.",
|
|
210
|
+
"required": false
|
|
211
|
+
},
|
|
212
|
+
{
|
|
213
|
+
"name": "labels",
|
|
214
|
+
"type": "Partial<AppearanceLabels>",
|
|
215
|
+
"default": null,
|
|
216
|
+
"description": "The words, passed translated (English by default).",
|
|
217
|
+
"required": false
|
|
218
|
+
},
|
|
219
|
+
{
|
|
220
|
+
"name": "language",
|
|
221
|
+
"type": "string",
|
|
222
|
+
"default": null,
|
|
223
|
+
"description": "The code of the language chosen.",
|
|
224
|
+
"required": false
|
|
225
|
+
},
|
|
226
|
+
{
|
|
227
|
+
"name": "languages",
|
|
228
|
+
"type": "readonly LanguageOption[]",
|
|
229
|
+
"default": null,
|
|
230
|
+
"description": "The languages offered, each named in its own language.",
|
|
231
|
+
"required": false
|
|
232
|
+
},
|
|
233
|
+
{
|
|
234
|
+
"name": "onAccentChange",
|
|
235
|
+
"type": "((id: string) => void)",
|
|
236
|
+
"default": null,
|
|
237
|
+
"description": "Called with the id chosen.",
|
|
238
|
+
"required": false
|
|
239
|
+
},
|
|
240
|
+
{
|
|
241
|
+
"name": "onDensityChange",
|
|
242
|
+
"type": "((density: string) => void)",
|
|
243
|
+
"default": null,
|
|
244
|
+
"description": "Called with the density chosen.",
|
|
245
|
+
"required": false
|
|
246
|
+
},
|
|
247
|
+
{
|
|
248
|
+
"name": "onLanguageChange",
|
|
249
|
+
"type": "((code: string) => void)",
|
|
250
|
+
"default": null,
|
|
251
|
+
"description": "Called with the code chosen.",
|
|
252
|
+
"required": false
|
|
253
|
+
},
|
|
254
|
+
{
|
|
255
|
+
"name": "onSoundChange",
|
|
256
|
+
"type": "((on: boolean) => void)",
|
|
257
|
+
"default": null,
|
|
258
|
+
"description": "Called with the new state.",
|
|
259
|
+
"required": false
|
|
260
|
+
},
|
|
261
|
+
{
|
|
262
|
+
"name": "sound",
|
|
263
|
+
"type": "boolean",
|
|
264
|
+
"default": null,
|
|
265
|
+
"description": "Shown only when given: the sound is opt-in.",
|
|
266
|
+
"required": false
|
|
267
|
+
}
|
|
268
|
+
]
|
|
269
|
+
},
|
|
151
270
|
{
|
|
152
271
|
"component": "AvatarPicker",
|
|
153
272
|
"description": "A grid of pictures to choose from, with an upload beside them: a radio group, never a row of loose radios.",
|
|
@@ -385,6 +504,14 @@
|
|
|
385
504
|
"module": "@krizaka/ui/registry/examples/account-settings/language-picker",
|
|
386
505
|
"code": "import { LanguagePicker } from \"@krizaka/ui/account-settings\";\nimport * as React from \"react\";\n\n// The account's language, labelled, each language in its own language.\nexport default function LanguagePickerExample() {\n const [value, setValue] = React.useState(\"fr\");\n return (\n <div className=\"w-full max-w-sm\">\n <LanguagePicker\n label=\"Langue\"\n description=\"La langue de l'application et des courriels.\"\n value={value}\n onValueChange={setValue}\n languages={[\n { code: \"fr\", name: \"Français\" },\n { code: \"en\", name: \"English\" },\n ]}\n />\n </div>\n );\n}\n"
|
|
387
506
|
},
|
|
507
|
+
{
|
|
508
|
+
"name": "appearance",
|
|
509
|
+
"title": "Appearance",
|
|
510
|
+
"description": "Theme cards (live miniatures, one check), accent, density and language as settings rows; applied at once with `useAppearance()`.",
|
|
511
|
+
"path": "examples/account-settings/appearance.tsx",
|
|
512
|
+
"module": "@krizaka/ui/registry/examples/account-settings/appearance",
|
|
513
|
+
"code": "\"use client\";\n\nimport { AppearanceSettings, type ThemeCardOption } from \"@krizaka/ui/account-settings\";\nimport * as React from \"react\";\n\nconst dark = { surface0: \"#111318\", surface1: \"#171a21\", surface2: \"#1e222b\", text: \"#e8ebf1\", muted: \"#959eae\" };\nconst light = { surface0: \"#fbfbfa\", surface1: \"#ffffff\", surface2: \"#f4f4f2\", text: \"#242c3d\", muted: \"#646d80\" };\n// In an app these come from `appearance.themes` of @krizaka/tokens; the product passes the subset it offers.\nconst THEMES: ThemeCardOption[] = [\n { id: \"system\", label: \"System\", description: \"Follows your device\", preview: null, halves: [light, dark] },\n { id: \"light\", label: \"Light\", preview: light },\n { id: \"dark\", label: \"Dark\", preview: dark },\n { id: \"blueprint\", label: \"Blueprint\", description: \"Navy\", preview: { surface0: \"hsl(222 40% 9%)\", surface1: \"hsl(222 38% 12%)\", surface2: \"hsl(222 36% 15%)\", text: \"hsl(215 40% 93%)\", muted: \"hsl(215 18% 69%)\" } },\n];\n\n// Applied at once, nothing to save: `useAppearance()` of @krizaka/ui/theme does it in a real app.\nexport default function AppearanceExample() {\n const [theme, setTheme] = React.useState(\"system\");\n const [accent, setAccent] = React.useState(\"akinaza\");\n const [density, setDensity] = React.useState(\"standard\");\n const [language, setLanguage] = React.useState(\"en\");\n return (\n <AppearanceSettings\n themes={THEMES} theme={theme} onThemeChange={setTheme}\n accents={[{ id: \"akinaza\", label: \"Forest green\", color: \"#4fa04f\" }, { id: \"krizaka\", label: \"Steel blue\", color: \"#3f78ab\" }]} accent={accent} onAccentChange={setAccent}\n densities={[{ value: \"standard\", label: \"Standard\" }, { value: \"compact\", label: \"Compact\" }]} density={density} onDensityChange={setDensity}\n languages={[{ code: \"en\", name: \"English\" }, { code: \"fr\", name: \"Français\" }]} language={language} onLanguageChange={setLanguage}\n />\n );\n}\n"
|
|
514
|
+
},
|
|
388
515
|
{
|
|
389
516
|
"name": "patterns",
|
|
390
517
|
"title": "Section patterns",
|
|
@@ -401,6 +528,10 @@
|
|
|
401
528
|
"path": "account-settings/account-profile-card.tsx",
|
|
402
529
|
"content": "// Server-safe. Who the account is, at a glance: the picture with its change action, the name, the e-mail and whether it is\n// verified, since when. The head of a profile section.\nimport type * as React from \"react\";\n\nimport { Avatar, type AvatarProps } from \"../avatar/avatar\";\nimport { Badge } from \"../badge/badge\";\nimport { cn } from \"../cn\";\n\nexport type AccountProfileCardProps = Omit<React.ComponentProps<\"section\">, \"title\"> & {\n /** The name (the card's heading). */\n name: string;\n /** The e-mail address. */\n email: string;\n /** Whether the address is verified. */\n verified: boolean;\n /** “Verified” — passed translated. */\n verifiedLabel: string;\n /** “Not verified” — passed translated. */\n unverifiedLabel: string;\n /** “Member since October 2026” — formatted by the app, in the viewer's language. */\n memberSince?: string;\n /** The picture: the person's photo, or the default avatar of the brand. */\n avatar?: Pick<AvatarProps, \"src\" | \"defaultAvatar\" | \"fallback\">;\n /** Beside the picture: the change action (a `Button`). */\n action?: React.ReactNode;\n /**\n * One calm line for a settings row: a medium picture beside the name and the e-mail, no wrapping.\n * @default false\n */\n compact?: boolean;\n};\n\n/** The account's identity card: picture, name, verified e-mail, member since. */\nexport function AccountProfileCard({ name, email, verified, verifiedLabel, unverifiedLabel, memberSince, avatar, action, compact, className, ...props }: AccountProfileCardProps) {\n return (\n <section aria-label={name} className={cn(\"flex items-center gap-3\", !compact && \"flex-col items-start gap-4 sm:flex-row sm:gap-5\", className)} {...props}>\n <div className=\"flex shrink-0 flex-col items-center gap-2\">\n <Avatar size={compact ? \"md\" : \"xl\"} alt=\"\" fallback={name.slice(0, 1)} {...avatar} />\n {action}\n </div>\n <div className=\"flex min-w-0 flex-col gap-1\">\n <h2 className={cn(\"m-0 truncate font-bold text-fg\", compact ? \"text-sm font-medium\" : \"text-lg\")}>{name}</h2>\n <p className=\"m-0 flex flex-wrap items-center gap-2 text-sm text-fg-secondary\">\n <span className=\"min-w-0 truncate\">{email}</span>\n <Badge tone={verified ? \"success\" : \"warning\"} dot>\n {verified ? verifiedLabel : unverifiedLabel}\n </Badge>\n </p>\n {memberSince ? <p className=\"text-sm text-fg-secondary\">{memberSince}</p> : null}\n </div>\n </section>\n );\n}\n"
|
|
403
530
|
},
|
|
531
|
+
{
|
|
532
|
+
"path": "account-settings/appearance-settings.tsx",
|
|
533
|
+
"content": "// Client (radio groups). How the workspace looks (ADR-006 §4, krizaka-ui#657): theme cards — a radio group of live miniatures\n// drawn from the tokens' own colours, one check on the chosen card —, then rows for the accent, the density, the language and, when the\n// product offers it, the sound (off by default, never under reduced motion). Driven by data: the product passes the themes it offers\n// (a subset of `appearance.themes` of @krizaka/tokens, at least system · light · dark), the accents that read on all of them, the values\n// and `onChange`s. It changes nothing by itself: `useAppearance()` of `@krizaka/ui/theme` applies the choice at once and keeps it in\n// the browser; the product saves it in the account too. Paper themes never belong here.\nimport * as React from \"react\";\n\nimport { Field } from \"../field\";\nimport { RadioGroup } from \"../radio-group\";\nimport { SettingsRow } from \"../settings-layout\";\nimport { Switch } from \"../switch\";\nimport { type LanguageOption, LanguagePicker } from \"./language-picker\";\n\n/** The colours a theme's miniature is drawn with (`appearance.themes[i].preview` of @krizaka/tokens). */\nexport type ThemePreview = { surface0: string; surface1: string; surface2: string; text: string; muted: string };\n\nexport type ThemeCardOption = {\n /** `system`, `light`, `dark`, `blueprint`, `carbone`. */\n id: string;\n /** Its name, passed translated. */\n label: string;\n /** One line: what it is, passed translated. */\n description?: string;\n /** Its colours; null for `system`, whose miniature is half light, half dark. */\n preview: ThemePreview | null;\n /** The two halves of the System miniature (`appearance.themes` light and dark previews). */\n halves?: readonly [ThemePreview, ThemePreview];\n};\n\nexport type AccentOption = {\n /** The brand id (`data-accent`). */\n id: string;\n /** Its name, passed translated (\"Forest green\"). */\n label: string;\n /** Its fill, for the swatch (`appearance.accents[i].dark.accent`). */\n color: string;\n};\n\nexport type AppearanceLabels = {\n /** The theme row: its name. */\n theme: string;\n /** One line under it. */\n themeHint: string;\n /** The accent row: its name. */\n accent: string;\n /** One line under it. */\n accentHint: string;\n /** The density row: its name. */\n density: string;\n /** One line under it. */\n densityHint: string;\n /** The language row: its name. */\n language: string;\n /** One line under it. */\n languageHint: string;\n /** The sound row: its name. */\n sound: string;\n /** One line under it. */\n soundHint: string;\n};\n\nexport const appearanceLabels: AppearanceLabels = {\n theme: \"Theme\",\n themeHint: \"The look of the workspace. System follows your device.\",\n accent: \"Accent colour\",\n accentHint: \"The colour of buttons and highlights.\",\n density: \"Density\",\n densityHint: \"How much fits on a screen.\",\n language: \"Language\",\n languageHint: \"The whole interface.\",\n sound: \"Sound\",\n soundHint: \"Small sounds when something is done. Off unless you turn it on, and never with reduced motion.\",\n};\n\nexport type AppearanceSettingsProps = {\n /** The themes offered: at least system, light and dark. */\n themes: readonly ThemeCardOption[];\n /** The id of the theme chosen. */\n theme: string;\n /** Called with the id chosen. */\n onThemeChange: (id: string) => void;\n /** The accents offered (the product's own first). Without it the row is not shown. */\n accents?: readonly AccentOption[];\n /** The id of the accent chosen; null for the product's own. */\n accent?: string | null;\n /** Called with the id chosen. */\n onAccentChange?: (id: string) => void;\n /** The densities offered, with their names (`standard`, `compact`). */\n densities?: readonly { value: string; label: string }[];\n /** The density chosen. */\n density?: string;\n /** Called with the density chosen. */\n onDensityChange?: (density: string) => void;\n /** The languages offered, each named in its own language. */\n languages?: readonly LanguageOption[];\n /** The code of the language chosen. */\n language?: string;\n /** Called with the code chosen. */\n onLanguageChange?: (code: string) => void;\n /** Shown only when given: the sound is opt-in. */\n sound?: boolean;\n /** Called with the new state. */\n onSoundChange?: (on: boolean) => void;\n /** The words, passed translated (English by default). */\n labels?: Partial<AppearanceLabels>;\n /** Classes merged on the root. */\n className?: string;\n};\n\nfunction Miniature({ preview }: { preview: ThemePreview }) {\n return (\n <span\n aria-hidden\n className=\"flex h-16 w-full overflow-hidden rounded-md border border-border-default\"\n style={{ background: preview.surface0 }}\n >\n <span className=\"m-1.5 flex w-1/3 flex-col gap-1 rounded-sm p-1\" style={{ background: preview.surface1 }}>\n <span className=\"h-1 w-3/4 rounded-full\" style={{ background: preview.text }} />\n <span className=\"h-1 w-1/2 rounded-full\" style={{ background: preview.muted }} />\n </span>\n <span className=\"my-1.5 mr-1.5 flex flex-1 flex-col gap-1 rounded-sm p-1.5\" style={{ background: preview.surface2 }}>\n <span className=\"h-1.5 w-2/3 rounded-full\" style={{ background: preview.text }} />\n <span className=\"h-1 w-full rounded-full\" style={{ background: preview.muted }} />\n <span className=\"h-1 w-5/6 rounded-full\" style={{ background: preview.muted }} />\n <span className=\"mt-auto h-2 w-1/3 rounded-sm bg-accent\" />\n </span>\n </span>\n );\n}\n\n/** The appearance rows of a settings page: theme cards, accent, density, language, sound. */\nexport function AppearanceSettings({\n themes,\n theme,\n onThemeChange,\n accents,\n accent,\n onAccentChange,\n densities,\n density,\n onDensityChange,\n languages,\n language,\n onLanguageChange,\n sound,\n onSoundChange,\n labels: given,\n className,\n}: AppearanceSettingsProps) {\n const labels = { ...appearanceLabels, ...given };\n const id = React.useId();\n return (\n <div className={className}>\n <SettingsRow label={labels.theme} description={labels.themeHint}>\n <RadioGroup.Root variant=\"cards\" label={labels.theme} value={theme} onValueChange={onThemeChange} className=\"grid w-full grid-cols-2 gap-3 sm:grid-cols-3\">\n {themes.map((option) => (\n <RadioGroup.Card key={option.id} value={option.id} aria-describedby={option.description ? `${id}-${option.id}` : undefined}>\n {option.preview ? (\n <Miniature preview={option.preview} />\n ) : option.halves ? (\n <span aria-hidden className=\"grid h-16 w-full grid-cols-2 overflow-hidden rounded-md border border-border-default\">\n <Miniature preview={option.halves[0]} />\n <Miniature preview={option.halves[1]} />\n </span>\n ) : null}\n <span className=\"font-semibold text-fg\">{option.label}</span>\n {option.description ? (\n <span id={`${id}-${option.id}`} className=\"text-xs font-normal text-fg-secondary\">\n {option.description}\n </span>\n ) : null}\n </RadioGroup.Card>\n ))}\n </RadioGroup.Root>\n </SettingsRow>\n {accents && accents.length > 0 && onAccentChange ? (\n <SettingsRow label={labels.accent} description={labels.accentHint} htmlFor={`${id}-accent`}>\n <span className=\"flex items-center gap-2\">\n <span aria-hidden className=\"h-4 w-4 rounded-full border border-border-default\" style={{ background: accents.find((a) => a.id === accent)?.color ?? accents[0]?.color }} />\n <Field.Root>\n <select\n id={`${id}-accent`}\n value={accent ?? accents[0]?.id}\n onChange={(event) => onAccentChange(event.target.value)}\n className=\"h-10 rounded-lg border border-border-control bg-surface-2 px-3 text-sm text-fg focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-ring\"\n >\n {accents.map((option) => (\n <option key={option.id} value={option.id}>\n {option.label}\n </option>\n ))}\n </select>\n </Field.Root>\n </span>\n </SettingsRow>\n ) : null}\n {densities && densities.length > 0 && onDensityChange ? (\n <SettingsRow label={labels.density} description={labels.densityHint}>\n <RadioGroup.Root variant=\"segmented\" label={labels.density} value={density} onValueChange={onDensityChange}>\n {densities.map((option) => (\n <RadioGroup.Segment key={option.value} value={option.value}>\n {option.label}\n </RadioGroup.Segment>\n ))}\n </RadioGroup.Root>\n </SettingsRow>\n ) : null}\n {languages && languages.length > 0 && onLanguageChange ? (\n <SettingsRow label={labels.language} description={labels.languageHint}>\n <LanguagePicker label={labels.language} showLabel={false} languages={languages} value={language ?? \"\"} onValueChange={onLanguageChange} />\n </SettingsRow>\n ) : null}\n {onSoundChange ? (\n <SettingsRow label={labels.sound} description={labels.soundHint}>\n <Switch label={labels.sound} checked={Boolean(sound)} onCheckedChange={onSoundChange} />\n </SettingsRow>\n ) : null}\n </div>\n );\n}\n"
|
|
534
|
+
},
|
|
404
535
|
{
|
|
405
536
|
"path": "account-settings/avatar-picker.tsx",
|
|
406
537
|
"content": "// Client (a radio group). The pictures of a person to choose from — the family's default avatars, a few photos — as a grid of\n// round tiles: one named radiogroup, one tab stop, the arrows choose, a ring and a check on the chosen one.\nimport { RadioGroup as RadioGroupPrimitive } from \"radix-ui\";\nimport * as React from \"react\";\n\nimport { type DefaultAvatar, defaultAvatarUrl } from \"../avatar/default-avatar\";\nimport { cn } from \"../cn\";\nimport { CheckGlyph } from \"../glyphs\";\nimport { GroupHead } from \"./group-head\";\n\nexport interface AvatarOption {\n /** The value of the choice. */\n id: string;\n /** Its name for assistive technology (“Teinte 3”) — passed translated. */\n label: string;\n /** A picture's address; otherwise `defaultAvatar` draws one of the family's pictures. */\n src?: string;\n /** One of Krizaka's default pictures (`{ brand, tone }`). */\n defaultAvatar?: DefaultAvatar;\n}\n\nexport type AvatarPickerProps = Omit<React.ComponentProps<typeof RadioGroupPrimitive.Root>, \"children\" | \"onChange\" | \"dir\"> & {\n /** The group's accessible name (“Profile picture”) — passed translated. */\n label: string;\n /**\n * Smaller tiles, for a settings row.\n * @default false\n */\n dense?: boolean;\n /** Shows the label above the grid, with `description` under it. */\n showLabel?: boolean;\n /** One line under the visible label: what it changes. */\n description?: React.ReactNode;\n /** The pictures. */\n options: readonly AvatarOption[];\n /** The chosen id (controlled). */\n value?: string;\n /** The viewer chooses another picture. */\n onValueChange?: (id: string) => void;\n /** After the pictures, in the grid: the upload action (a `Button`, a file input's label). Not a radio. */\n upload?: React.ReactNode;\n};\n\nconst pictureOf = (option: AvatarOption) => option.src ?? (option.defaultAvatar ? defaultAvatarUrl(option.defaultAvatar, { size: 256 }) : undefined);\n\n/** A grid of pictures to choose from, with an upload beside them: a radio group, never a row of loose radios. */\nexport function AvatarPicker({ label, showLabel, description, dense, options, upload, className, ...props }: AvatarPickerProps) {\n const id = React.useId();\n const group = (\n <RadioGroupPrimitive.Root aria-label={label} aria-labelledby={showLabel ? id : undefined} className={cn(dense ? \"flex flex-wrap gap-2.5\" : \"grid grid-cols-[repeat(auto-fill,minmax(4.25rem,1fr))] gap-3\", !showLabel && className)} {...props}>\n {options.map((option) => (\n <RadioGroupPrimitive.Item\n key={option.id}\n value={option.id}\n aria-label={option.label}\n className={cn(\n \"group/avatar relative shrink-0 rounded-full\", dense ? \"h-12 w-12\" : \"aspect-square w-full\",\n \" outline-none transition-shadow duration-200 motion-reduce:transition-none\",\n \"ring-1 ring-border-default hover:ring-border-strong focus-visible:focus-ring data-[state=checked]:ring-2 data-[state=checked]:ring-accent\",\n )}\n >\n <img src={pictureOf(option)} alt=\"\" draggable={false} className=\"h-full w-full rounded-full bg-surface-3 object-cover\" />\n <span\n aria-hidden\n className=\"absolute -bottom-0.5 -right-0.5 hidden h-5 w-5 items-center justify-center rounded-full border-2 border-surface-1 bg-accent text-on-accent group-data-[state=checked]/avatar:inline-flex\"\n >\n <CheckGlyph className=\"h-3 w-3\" />\n </span>\n </RadioGroupPrimitive.Item>\n ))}\n {upload ? <div className=\"flex aspect-square w-full items-center justify-center\">{upload}</div> : null}\n </RadioGroupPrimitive.Root>\n );\n if (!showLabel) return group;\n return (\n <div className={cn(\"flex flex-col gap-3\", className)}>\n <GroupHead id={id} label={label} description={description} />\n {group}\n </div>\n );\n}\n"
|
|
@@ -415,7 +546,7 @@
|
|
|
415
546
|
},
|
|
416
547
|
{
|
|
417
548
|
"path": "account-settings/index.ts",
|
|
418
|
-
"content": "/** @krizaka/ui/account-settings — the blocks of an account page: `AccountProfileCard`, `AvatarPicker`, `ChoiceCards`, `LanguagePicker`. Client. The inline save of a section is `SettingsSection`'s `save` with `useSaveStatus` (`@krizaka/ui/settings-layout`). */\nexport { AccountProfileCard, type AccountProfileCardProps } from \"./account-profile-card\";\nexport { type AvatarOption, AvatarPicker, type AvatarPickerProps } from \"./avatar-picker\";\nexport { type ChoiceCardOption, ChoiceCards, type ChoiceCardsProps } from \"./choice-cards\";\nexport { type LanguageOption, LanguagePicker, type LanguagePickerProps } from \"./language-picker\";\n"
|
|
549
|
+
"content": "/** @krizaka/ui/account-settings — the blocks of an account page: `AccountProfileCard`, `AvatarPicker`, `ChoiceCards`, `LanguagePicker`. Client. The inline save of a section is `SettingsSection`'s `save` with `useSaveStatus` (`@krizaka/ui/settings-layout`). */\nexport { AccountProfileCard, type AccountProfileCardProps } from \"./account-profile-card\";\nexport {\n type AccentOption,\n type AppearanceLabels,\n appearanceLabels,\n AppearanceSettings,\n type AppearanceSettingsProps,\n type ThemeCardOption,\n type ThemePreview,\n} from \"./appearance-settings\";\nexport { type AvatarOption, AvatarPicker, type AvatarPickerProps } from \"./avatar-picker\";\nexport { type ChoiceCardOption, ChoiceCards, type ChoiceCardsProps } from \"./choice-cards\";\nexport { type LanguageOption, LanguagePicker, type LanguagePickerProps } from \"./language-picker\";\n"
|
|
419
550
|
},
|
|
420
551
|
{
|
|
421
552
|
"path": "account-settings/language-picker.tsx",
|
|
@@ -423,7 +554,7 @@
|
|
|
423
554
|
},
|
|
424
555
|
{
|
|
425
556
|
"path": "account-settings/meta.ts",
|
|
426
|
-
"content": "import type { ComponentMeta } from \"../meta\";\n\nexport const meta = {\n title: \"Account settings\",\n summary:\n \"The blocks of an account page, so every app has the same polished one: the identity card (picture, name, verified e-mail, member since), a picture grid to choose from, a labelled language control, selectable cards for a single choice — beside `SettingsSection`'s one inline save.\",\n status: \"beta\",\n category: \"forms\",\n platforms: \"web\",\n parity: {\n native: { status: \"gap\", issue: \"krizaka/krizaka-ui#503\", reason: \"The Expo apps get the same blocks on @krizaka/ui/native.\" },\n desktop: \"web\",\n },\n whenToUse: [\n \"The profile page of any Krizaka app (a product's `/settings/profile`, the future `@krizaka/auth`).\",\n \"`ChoiceCards` for any single choice that deserves a sentence each: a side, a plan, a way to be answered.\",\n ],\n whenNotToUse: [\n { when: \"A choice between a few short words (a view, a size).\", use: \"radio-group\" },\n { when: \"A set of tiles that lead somewhere or show a line-up.\", use: \"choice-grid\" },\n { when: \"The language of a public page: it is a link to the same page in the other language.\", use: \"language-switch\" },\n ],\n bestPractices: [\n \"One save per section (`SettingsSection` `save`): enabled while the section is dirty, « Saved » and Undo after it, the failure as an alert. Never a save above the fields.\",\n \"`AvatarPicker` is one radiogroup — never a row of circles with loose radios; keep the upload inside its grid, after the pictures.\",\n \"Name every language in its own language and label the control: « Langue », never an unlabelled switch.\",\n \"Pass every word translated; the member-since date is formatted by the app in the viewer's language.\",\n \"Section patterns (security, subscription, storage, my data) are flat sections of `SettingsRow`s: the billing portal is one link, the export one button, the delete a `ConfirmButton`.\",\n ],\n accessibility: {\n keyboard: [\n { keys: \"← → ↑ ↓\", action: \"Moves to the next picture, card or language and chooses it (one tab stop per group).\" },\n { keys: \"Space\", action: \"Chooses the focused one.\" },\n { keys: \"Enter (in a field)\", action: \"Submits the section's form: saves when it is dirty.\" },\n ],\n notes: [\n \"Each group is a named `radiogroup`; the chosen item says `aria-checked`, shows a ring and a check (not colour alone).\",\n \"A card's description is its `aria-describedby`; a picture is named by its `label`, not its image.\",\n \"The save result is a polite live region that stays mounted; a failure is `role=\\\"alert\\\"`.\",\n ],\n },\n related: [\"settings-layout\", \"radio-group\", \"avatar\", \"choice-grid\", \"confirm-button\", \"meter\"],\n web: {\n imports: [\"AccountProfileCard\", \"AvatarPicker\", \"ChoiceCards\", \"LanguagePicker\"],\n examples: [\n { name: \"profile\", title: \"Profile page\", description: \"A whole profile section: identity, name, pictures, language, side — one save, dirty then saved with Undo.\", template: true, purpose: \"operate\", why: \"A person changes who they are in the app in one place, and sees at once that it was kept.\" },\n { name: \"avatar-picker\", title: \"Avatar picker\", description: \"The family's default pictures as one radio group, the upload beside them.\" },\n { name: \"choice-cards\", title: \"Choice cards\", description: \"A single choice as two cards with an icon, a title and a line.\" },\n { name: \"language-picker\", title: \"Language picker\", description: \"Labelled, native names.\" },\n { name: \"patterns\", title: \"Section patterns\", description: \"Security, subscription, storage and my data as flat sections of rows.\" },\n ],\n },\n} satisfies ComponentMeta;\n"
|
|
557
|
+
"content": "import type { ComponentMeta } from \"../meta\";\n\nexport const meta = {\n title: \"Account settings\",\n summary:\n \"The blocks of an account page, so every app has the same polished one: the identity card (picture, name, verified e-mail, member since), a picture grid to choose from, a labelled language control, selectable cards for a single choice — beside `SettingsSection`'s one inline save.\",\n status: \"beta\",\n category: \"forms\",\n platforms: \"web\",\n parity: {\n native: { status: \"gap\", issue: \"krizaka/krizaka-ui#503\", reason: \"The Expo apps get the same blocks on @krizaka/ui/native.\" },\n desktop: \"web\",\n },\n whenToUse: [\n \"The profile page of any Krizaka app (a product's `/settings/profile`, the future `@krizaka/auth`).\",\n \"`ChoiceCards` for any single choice that deserves a sentence each: a side, a plan, a way to be answered.\",\n ],\n whenNotToUse: [\n { when: \"A choice between a few short words (a view, a size).\", use: \"radio-group\" },\n { when: \"A set of tiles that lead somewhere or show a line-up.\", use: \"choice-grid\" },\n { when: \"The language of a public page: it is a link to the same page in the other language.\", use: \"language-switch\" },\n ],\n bestPractices: [\n \"One save per section (`SettingsSection` `save`): enabled while the section is dirty, « Saved » and Undo after it, the failure as an alert. Never a save above the fields.\",\n \"`AvatarPicker` is one radiogroup — never a row of circles with loose radios; keep the upload inside its grid, after the pictures.\",\n \"Name every language in its own language and label the control: « Langue », never an unlabelled switch.\",\n \"Pass every word translated; the member-since date is formatted by the app in the viewer's language.\",\n \"Appearance: pass the themes the product offers (system, light, dark, then Blueprint and Carbone if wanted — never a paper theme inside a signed-in product) from `appearance` of @krizaka/tokens, and only the accents that read on all of them (`appearance.passes`). The change applies at once (`useAppearance()` of `@krizaka/ui/theme`, restored before paint by `ThemeScript`); save it in the account too so it follows the person. Sound is opt-in, off by default, never under reduced motion; density is `html[data-density]`.\",\n \"Section patterns (security, subscription, storage, my data) are flat sections of `SettingsRow`s: the billing portal is one link, the export one button, the delete a `ConfirmButton`.\",\n ],\n accessibility: {\n keyboard: [\n { keys: \"← → ↑ ↓\", action: \"Moves to the next picture, card or language and chooses it (one tab stop per group).\" },\n { keys: \"Space\", action: \"Chooses the focused one.\" },\n { keys: \"Enter (in a field)\", action: \"Submits the section's form: saves when it is dirty.\" },\n ],\n notes: [\n \"Each group is a named `radiogroup`; the chosen item says `aria-checked`, shows a ring and a check (not colour alone).\",\n \"A card's description is its `aria-describedby`; a picture is named by its `label`, not its image.\",\n \"The save result is a polite live region that stays mounted; a failure is `role=\\\"alert\\\"`.\",\n ],\n },\n related: [\"settings-layout\", \"radio-group\", \"avatar\", \"choice-grid\", \"confirm-button\", \"meter\"],\n web: {\n imports: [\"AccountProfileCard\", \"AvatarPicker\", \"ChoiceCards\", \"LanguagePicker\", \"AppearanceSettings\"],\n examples: [\n { name: \"profile\", title: \"Profile page\", description: \"A whole profile section: identity, name, pictures, language, side — one save, dirty then saved with Undo.\", template: true, purpose: \"operate\", why: \"A person changes who they are in the app in one place, and sees at once that it was kept.\" },\n { name: \"avatar-picker\", title: \"Avatar picker\", description: \"The family's default pictures as one radio group, the upload beside them.\" },\n { name: \"choice-cards\", title: \"Choice cards\", description: \"A single choice as two cards with an icon, a title and a line.\" },\n { name: \"language-picker\", title: \"Language picker\", description: \"Labelled, native names.\" },\n { name: \"appearance\", title: \"Appearance\", description: \"Theme cards (live miniatures, one check), accent, density and language as settings rows; applied at once with `useAppearance()`.\" },\n { name: \"patterns\", title: \"Section patterns\", description: \"Security, subscription, storage and my data as flat sections of rows.\" },\n ],\n },\n} satisfies ComponentMeta;\n"
|
|
427
558
|
},
|
|
428
559
|
{
|
|
429
560
|
"path": "glyphs.tsx",
|
|
@@ -431,17 +562,20 @@
|
|
|
431
562
|
},
|
|
432
563
|
{
|
|
433
564
|
"path": "meta.ts",
|
|
434
|
-
"content": "// The documentation of a component, carried by its code: each primitive has a `meta.ts` beside its source\n// (`src/<name>/meta.ts`; a component that exists only in React Native: `src/native/meta/<name>.ts`). Never built into\n// the package: `scripts/build-registry.mjs` reads them into `registry/<name>.json`, which ui.krizaka.com (apps/site) renders as\n// ui.krizaka.com/components/<name>, and `scripts/registry.test.mjs` fails when one is missing or incomplete.\n//\n// Why a typed module and not JSDoc tags: the fields are lists and links (`related`, `whenNotToUse[].use`, examples),\n// which a type checks and a comment does not; the file is plain data (erasable TypeScript), so Node reads it without a\n// compiler, and an editor completes it.\n\n/** Every documented component: the web primitives (one entry of the package each) and the native-only ones. */\nexport type ComponentName =\n | \"agenda\"\n | \"account-settings\"\n | \"drop-overlay\"\n | \"upload-queue\"\n | \"achievement\"\n | \"anatomy-plate\"\n | \"bird-plate\"\n | \"taped-photo\"\n | \"text-style\"\n | \"flock\"\n | \"elephant\"\n | \"footnote\"\n | \"page-index\"\n | \"chapter\"\n | \"specimen-tag\"\n | \"action-bar\"\n | \"action-sheet\"\n | \"activity-feed\"\n | \"alert\"\n | \"app-header\"\n | \"app-shell\"\n | \"argument-card\"\n | \"audio-player\"\n | \"auth-layout\"\n | \"avatar\"\n | \"badge\"\n | \"button\"\n | \"captcha\"\n | \"card\"\n | \"card-grid\"\n | \"catalogue-page\"\n | \"changelog-page\"\n | \"chat\"\n | \"checkbox\"\n | \"chip\"\n | \"chip-link\"\n | \"chip-row\"\n | \"choice-grid\"\n | \"cn\"\n | \"code-block\"\n | \"combobox\"\n | \"comparison-table\"\n | \"command\"\n | \"component-page\"\n | \"confirm-button\"\n | \"contact-page\"\n | \"continue-prompt\"\n | \"countdown\"\n | \"cover-hero\"\n | \"cta-panel\"\n | \"dashboard-layout\"\n | \"data-table\"\n | \"date-picker\"\n | \"decision-list\"\n | \"description-list\"\n | \"detail-layout\"\n | \"dialog\"\n | \"docs-article-page\"\n | \"docs-hub-page\"\n | \"docs-layout\"\n | \"docs-nav\"\n | \"document-viewer\"\n | \"dropdown-menu\"\n | \"empty-state\"\n | \"engine-flow\"\n | \"error-page\"\n | \"fab\"\n | \"field\"\n | \"file-upload\"\n | \"filter-bar\"\n | \"force-update-screen\"\n | \"form\"\n | \"gallery-page\"\n | \"genui\"\n | \"glossary\"\n | \"glossary-term\"\n | \"glow-card\"\n | \"goal-gauge\"\n | \"header\"\n | \"how-it-works-page\"\n | \"image-cropper\"\n | \"image-viewer\"\n | \"iso\"\n | \"kanban\"\n | \"kbd\"\n | \"kpi-explained\"\n | \"landing-page\"\n | \"landscape\"\n | \"legal-page\"\n | \"link-card\"\n | \"list\"\n | \"loader\"\n | \"longform-page\"\n | \"maintenance-screen\"\n | \"map\"\n | \"markdown\"\n | \"meta-row\"\n | \"waveform\"\n | \"marketing-layout\"\n | \"marquee\"\n | \"mascot-quote\"\n | \"mascot-state\"\n | \"mascots\"\n | \"match-dialog\"\n | \"media-capture\"\n | \"media-grid\"\n | \"language-switch\"\n | \"media-gallery\"\n | \"media-picker\"\n | \"meter\"\n | \"nav-bar\"\n | \"number-ticker\"\n | \"onboarding\"\n | \"opening-hours\"\n | \"otp-input\"\n | \"page\"\n | \"page-header\"\n | \"page-hero\"\n | \"pagination\"\n | \"permission-prompt\"\n | \"photo-grid\"\n | \"pointer-light\"\n | \"popover\"\n | \"pricing-page\"\n | \"product-page\"\n | \"profile-card\"\n | \"progress\"\n | \"promise-card\"\n | \"pull-to-refresh\"\n | \"radio-group\"\n | \"router\"\n | \"rail-nav\"\n | \"recipes\"\n | \"screen\"\n | \"scroll-stage\"\n | \"search-field\"\n | \"section-backdrop\"\n | \"segmented\"\n | \"separator\"\n | \"service-card\"\n | \"settings-layout\"\n | \"account-menu\"\n | \"showcase\"\n | \"step-showcase\"\n | \"site-footer\"\n | \"sites\"\n | \"skeleton\"\n | \"skip-link\"\n | \"slider\"\n | \"slot-picker\"\n | \"slot\"\n | \"spinner\"\n | \"sticky-action\"\n | \"splash-handoff\"\n | \"split-view\"\n | \"stage-banner\"\n | \"stat\"\n | \"status-page\"\n | \"step-progress\"\n | \"stepper\"\n | \"swipe-deck\"\n | \"swipeable-row\"\n | \"switch\"\n | \"tab-bar\"\n | \"tabs\"\n | \"tag-input\"\n | \"tag-selector\"\n | \"terminal-replay\"\n | \"theme\"\n | \"toast\"\n | \"toc\"\n | \"tooltip\"\n | \"tree-view\"\n | \"txt\"\n | \"update-prompt\"\n | \"verified-badge\"\n | \"vertical-video\"\n | \"video-player\"\n | \"video-trimmer\"\n | \"virtual\";\n\n/** Where a component exists: `@krizaka/ui/<name>` (web), `@krizaka/ui/native` (React Native), or both. */\nexport type Platform = \"web\" | \"native\" | \"both\";\n\n/**\n * Why a component is not on a platform — a decision, never a silence (the parity matrix of ui.krizaka.com/platforms):\n * - `gap` (✗): it belongs there and is not built yet; `issue` is the issue that tracks it (`krizaka/krizaka-ui#275`);\n * - `n/a`: it is not meant for that platform (a site's page block on a phone, a swipe on a desktop); `use` names the\n * component that answers there, when one does.\n */\nexport type Absence =\n | { readonly status: \"gap\"; readonly issue: string; readonly reason: string; readonly use?: undefined }\n | { readonly status: \"n/a\"; readonly reason: string; readonly use?: ComponentName; readonly issue?: undefined };\n\n/**\n * Desktop is the Orazaka Mac app (Tauri 2: the system WebView renders the web components — ADR-002). `web`: the web\n * component runs there as it is; `desktop`: it also has a desktop form (a window's title bar, a denser layout…), said in\n * its documentation; otherwise the absence and why.\n */\nexport type DesktopSupport = \"web\" | \"desktop\" | Absence;\n\n/**\n * The three platforms of Krizaka UI — web · native (React Native, Expo) · desktop — for one component. The side a\n * component has is `platforms`; the side it lacks says why here: `native` is required for (and only for) a web-only\n * component, `web` for a native-only one; `desktop` always. `scripts/registry.test.mjs` fails on a missing decision.\n */\nexport interface Parity {\n readonly web?: Absence;\n readonly native?: Absence;\n readonly desktop: DesktopSupport;\n}\n\n/**\n * `stable`: its API only changes in a major. `beta`: it may still change in a minor. `deprecated`: no product uses it and\n * no work plans to — it still works, says what replaces it, and goes in the major named by `deprecated.removedIn`.\n */\nexport type Status = \"stable\" | \"beta\" | \"deprecated\";\n\n/** What a deprecated component says (required when `status` is `deprecated`, absent otherwise). */\nexport interface Deprecation {\n /** The version that deprecated it (`3.6.0`). */\n readonly since: string;\n /** The major that removes it (`4.0.0`). */\n readonly removedIn: string;\n /** What replaces it, when a component does. */\n readonly use?: ComponentName;\n /** Why it goes: no product uses it, no planned work needs it. */\n readonly reason: string;\n}\n\n/**\n * The group of the catalogue. `media`: video, sound, camera, files, cropping. `blocks`: the page blocks — the frame,\n * the hero, sections, cards that lead or argue, decisions, code, calls to act — that every page of a site is made of.\n * `layouts`: the shells of whole screens — an application, a dashboard, settings, sign-in, an object, a list and its\n * item, a site's page, a documentation page — each with its screens. `templates`: the page templates — whole pages of a\n * site (a landing, a product, a docs hub, a long read, a changelog, pricing, status, an error…), each a distinct\n * composition of the blocks, words and content as props.\n */\nexport type Category = \"actions\" | \"forms\" | \"navigation\" | \"overlays\" | \"feedback\" | \"data-display\" | \"media\" | \"blocks\" | \"layouts\" | \"templates\" | \"layout\" | \"foundations\";\n\n/** Why a reader needs a template: the seven intents the templates are grouped by (sidebar sub-headings, catalogue filter). */\nexport type TemplatePurpose = \"convince\" | \"explain\" | \"show\" | \"act\" | \"operate\" | \"converse\" | \"recover\";\n\n/** The groups of templates, in reading order: the title, and the one line that says when to come to that group. */\nexport const templatePurposes = {\n convince: { title: \"Convince\", useWhen: \"You come here when a visitor must decide: a landing, a product, a price, a comparison, a proof.\" },\n explain: { title: \"Explain\", useWhen: \"You come here when a reader must understand: how it works, a documentation hub or article, a changelog, a FAQ, a policy.\" },\n show: { title: \"Show\", useWhen: \"You come here when the work itself is the argument: a gallery, a story, a case study, an object and its details.\" },\n act: { title: \"Act\", useWhen: \"You come here when a person must do something once: reach the team, sign in or up, set up, pay.\" },\n operate: { title: \"Operate\", useWhen: \"You come here when a person works every day: a dashboard, a console with a table, settings, an app shell.\" },\n converse: { title: \"Converse\", useWhen: \"You come here when people talk: an inbox, a chat, comments, a notifications centre.\" },\n recover: { title: \"Recover\", useWhen: \"You come here when the way is blocked: an empty list, an error, a missing page, maintenance, a product still being built.\" },\n} as const satisfies Record<TemplatePurpose, { readonly title: string; readonly useWhen: string }>;\n\n/**\n * A named example: the file `registry/examples/<component>/<name>.tsx` (web) or\n * `registry/examples/<component>/native/<name>.tsx` (React Native) — at most 40 lines, imported by the stories and\n * shown (live, with its code) by the documentation.\n */\ninterface ExampleBase {\n /** The file name, kebab-case (`primary`, `icon-button`). */\n readonly name: string;\n /** A short title (`Primary`, `Icon button`). */\n readonly title: string;\n /** One or two sentences: when this variant is the right one. */\n readonly description: string;\n}\n\n/** A plain example, or a template: a whole screen with its intent (`purpose`) and the user goal its layout serves (`why`). */\nexport type Example =\n | (ExampleBase & { readonly template?: false; readonly purpose?: undefined; readonly why?: undefined })\n | (ExampleBase & {\n /**\n * A template: a whole screen of a product composed from the platform (a layout and its blocks, real words, its\n * phone version thought out), copied as a starting point — at most 160 lines, listed on ui.krizaka.com/templates.\n */\n readonly template: true;\n /** The intent that groups it: why you need this block. */\n readonly purpose: TemplatePurpose;\n /** Why this layout: the user goal it serves, in one sentence. */\n readonly why: string;\n });\n\n/** One platform's side of a component. */\nexport interface PlatformDocs {\n /** The names to import (`[\"Button\", \"IconButton\"]`): from `@krizaka/ui/<name>` on the web, `@krizaka/ui/native` in React Native. */\n readonly imports: readonly string[];\n /** The examples, in reading order; the first one is the component's preview. */\n readonly examples: readonly Example[];\n}\n\n/** The React Native side: the same concept, and what differs from the web API. */\nexport interface NativeDocs extends PlatformDocs {\n /**\n * The entry to import from when it is not `@krizaka/ui/native`: a component that needs an Expo module (an optional\n * peer) has its own, `@krizaka/ui/native/<name>`, so an app that does not use it never installs the module.\n */\n readonly entry?: string;\n /** What differs from the web API (`label` instead of children…); empty for a native-only component. */\n readonly differences: readonly string[];\n}\n\nexport interface KeyboardInteraction {\n /** The keys, as written on a keyboard: `Space`, `Enter`, `Arrow keys`, `Esc`, `Tab`. */\n readonly keys: string;\n /** What they do. */\n readonly action: string;\n}\n\nexport interface ComponentMeta {\n /** The display name: `Button`, `Dropdown menu`. */\n readonly title: string;\n /** One sentence: what it is. */\n readonly summary: string;\n readonly status: Status;\n /** Required for, and only for, a `deprecated` component. */\n readonly deprecated?: Deprecation;\n readonly category: Category;\n /** Must match the sides below: `both` ⇔ `web` and `native`. */\n readonly platforms: Platform;\n /** The platforms it is not on, and why; and its desktop form (see `Parity`). */\n readonly parity: Parity;\n /** When to reach for it: concrete situations, one per item. */\n readonly whenToUse: readonly string[];\n /** When not to — and what to use instead (`use`), when another component is the answer. */\n readonly whenNotToUse: readonly { readonly when: string; readonly use?: ComponentName }[];\n /** How to use it well: wording, placement, composition. */\n readonly bestPractices: readonly string[];\n readonly accessibility: {\n /** The keyboard, when it does more than Tab and Enter. */\n readonly keyboard: readonly KeyboardInteraction[];\n /** Roles, names and announcements: what the component does, what the app must provide. */\n readonly notes: readonly string[];\n };\n /** The components a reader of this page should know about. */\n readonly related: readonly ComponentName[];\n readonly web?: PlatformDocs;\n readonly native?: NativeDocs;\n}\n"
|
|
565
|
+
"content": "// The documentation of a component, carried by its code: each primitive has a `meta.ts` beside its source\n// (`src/<name>/meta.ts`; a component that exists only in React Native: `src/native/meta/<name>.ts`). Never built into\n// the package: `scripts/build-registry.mjs` reads them into `registry/<name>.json`, which ui.krizaka.com (apps/site) renders as\n// ui.krizaka.com/components/<name>, and `scripts/registry.test.mjs` fails when one is missing or incomplete.\n//\n// Why a typed module and not JSDoc tags: the fields are lists and links (`related`, `whenNotToUse[].use`, examples),\n// which a type checks and a comment does not; the file is plain data (erasable TypeScript), so Node reads it without a\n// compiler, and an editor completes it.\n\n/** Every documented component: the web primitives (one entry of the package each) and the native-only ones. */\nexport type ComponentName =\n | \"notification-preferences\"\n | \"quota-meter\"\n | \"status-chip\"\n | \"kind-config-editor\"\n | \"agenda\"\n | \"account-settings\"\n | \"drop-overlay\"\n | \"upload-queue\"\n | \"achievement\"\n | \"anatomy-plate\"\n | \"bird-plate\"\n | \"taped-photo\"\n | \"stuck\"\n | \"doodle\"\n | \"signature\"\n | \"grade-stamp\"\n | \"versus-card\"\n | \"speed-lines\"\n | \"site-cahier\"\n | \"text-style\"\n | \"flock\"\n | \"elephant\"\n | \"footnote\"\n | \"page-index\"\n | \"chapter\"\n | \"specimen-tag\"\n | \"action-bar\"\n | \"action-sheet\"\n | \"activity-feed\"\n | \"alert\"\n | \"app-header\"\n | \"app-shell\"\n | \"argument-card\"\n | \"audio-player\"\n | \"auth-layout\"\n | \"avatar\"\n | \"badge\"\n | \"button\"\n | \"captcha\"\n | \"card\"\n | \"card-grid\"\n | \"catalogue-page\"\n | \"changelog-page\"\n | \"chat\"\n | \"checkbox\"\n | \"chip\"\n | \"chip-link\"\n | \"chip-row\"\n | \"choice-grid\"\n | \"cn\"\n | \"code-block\"\n | \"combobox\"\n | \"comparison-table\"\n | \"command\"\n | \"component-page\"\n | \"confirm-button\"\n | \"contact-page\"\n | \"continue-prompt\"\n | \"countdown\"\n | \"cover-hero\"\n | \"cta-panel\"\n | \"dashboard-layout\"\n | \"data-table\"\n | \"date-picker\"\n | \"decision-list\"\n | \"description-list\"\n | \"detail-layout\"\n | \"dialog\"\n | \"docs-article-page\"\n | \"docs-hub-page\"\n | \"docs-layout\"\n | \"docs-nav\"\n | \"document-viewer\"\n | \"dropdown-menu\"\n | \"empty-state\"\n | \"engine-flow\"\n | \"error-page\"\n | \"fab\"\n | \"field\"\n | \"file-upload\"\n | \"filter-bar\"\n | \"force-update-screen\"\n | \"form\"\n | \"gallery-page\"\n | \"genui\"\n | \"glossary\"\n | \"glossary-term\"\n | \"glow-card\"\n | \"goal-gauge\"\n | \"header\"\n | \"how-it-works-page\"\n | \"image-cropper\"\n | \"image-viewer\"\n | \"iso\"\n | \"kanban\"\n | \"kbd\"\n | \"kpi-explained\"\n | \"landing-page\"\n | \"landscape\"\n | \"legal-page\"\n | \"link-card\"\n | \"list\"\n | \"loader\"\n | \"longform-page\"\n | \"maintenance-screen\"\n | \"map\"\n | \"markdown\"\n | \"meta-row\"\n | \"waveform\"\n | \"marketing-layout\"\n | \"marquee\"\n | \"mascot-quote\"\n | \"mascot-state\"\n | \"mascots\"\n | \"match-dialog\"\n | \"media-capture\"\n | \"media-grid\"\n | \"language-switch\"\n | \"media-gallery\"\n | \"media-picker\"\n | \"meter\"\n | \"nav-bar\"\n | \"number-ticker\"\n | \"onboarding\"\n | \"opening-hours\"\n | \"otp-input\"\n | \"page\"\n | \"page-header\"\n | \"page-hero\"\n | \"pagination\"\n | \"permission-prompt\"\n | \"photo-grid\"\n | \"pointer-light\"\n | \"popover\"\n | \"pricing-page\"\n | \"product-page\"\n | \"profile-card\"\n | \"progress\"\n | \"promise-card\"\n | \"pull-to-refresh\"\n | \"retro-tv\"\n | \"radio-group\"\n | \"router\"\n | \"rail-nav\"\n | \"recipes\"\n | \"screen\"\n | \"scroll-stage\"\n | \"search-field\"\n | \"section-backdrop\"\n | \"segmented\"\n | \"separator\"\n | \"service-card\"\n | \"settings-layout\"\n | \"account-menu\"\n | \"showcase\"\n | \"step-showcase\"\n | \"site-footer\"\n | \"sites\"\n | \"skeleton\"\n | \"skip-link\"\n | \"slider\"\n | \"slot-picker\"\n | \"slot\"\n | \"spinner\"\n | \"sticky-action\"\n | \"splash-handoff\"\n | \"split-view\"\n | \"stage-banner\"\n | \"stat\"\n | \"status-page\"\n | \"step-progress\"\n | \"stepper\"\n | \"swipe-deck\"\n | \"swipeable-row\"\n | \"switch\"\n | \"tab-bar\"\n | \"tabs\"\n | \"tag-input\"\n | \"tag-selector\"\n | \"terminal-replay\"\n | \"theme\"\n | \"toast\"\n | \"toc\"\n | \"tooltip\"\n | \"tree-view\"\n | \"txt\"\n | \"update-prompt\"\n | \"verified-badge\"\n | \"vertical-video\"\n | \"video-player\"\n | \"video-trimmer\"\n | \"virtual\";\n\n/** Where a component exists: `@krizaka/ui/<name>` (web), `@krizaka/ui/native` (React Native), or both. */\nexport type Platform = \"web\" | \"native\" | \"both\";\n\n/**\n * Why a component is not on a platform — a decision, never a silence (the parity matrix of ui.krizaka.com/platforms):\n * - `gap` (✗): it belongs there and is not built yet; `issue` is the issue that tracks it (`krizaka/krizaka-ui#275`);\n * - `n/a`: it is not meant for that platform (a site's page block on a phone, a swipe on a desktop); `use` names the\n * component that answers there, when one does.\n */\nexport type Absence =\n | { readonly status: \"gap\"; readonly issue: string; readonly reason: string; readonly use?: undefined }\n | { readonly status: \"n/a\"; readonly reason: string; readonly use?: ComponentName; readonly issue?: undefined };\n\n/**\n * Desktop is the Orazaka Mac app (Tauri 2: the system WebView renders the web components — ADR-002). `web`: the web\n * component runs there as it is; `desktop`: it also has a desktop form (a window's title bar, a denser layout…), said in\n * its documentation; otherwise the absence and why.\n */\nexport type DesktopSupport = \"web\" | \"desktop\" | Absence;\n\n/**\n * The three platforms of Krizaka UI — web · native (React Native, Expo) · desktop — for one component. The side a\n * component has is `platforms`; the side it lacks says why here: `native` is required for (and only for) a web-only\n * component, `web` for a native-only one; `desktop` always. `scripts/registry.test.mjs` fails on a missing decision.\n */\nexport interface Parity {\n readonly web?: Absence;\n readonly native?: Absence;\n readonly desktop: DesktopSupport;\n}\n\n/**\n * `stable`: its API only changes in a major. `beta`: it may still change in a minor. `deprecated`: no product uses it and\n * no work plans to — it still works, says what replaces it, and goes in the major named by `deprecated.removedIn`.\n */\nexport type Status = \"stable\" | \"beta\" | \"deprecated\";\n\n/** What a deprecated component says (required when `status` is `deprecated`, absent otherwise). */\nexport interface Deprecation {\n /** The version that deprecated it (`3.6.0`). */\n readonly since: string;\n /** The major that removes it (`4.0.0`). */\n readonly removedIn: string;\n /** What replaces it, when a component does. */\n readonly use?: ComponentName;\n /** Why it goes: no product uses it, no planned work needs it. */\n readonly reason: string;\n}\n\n/**\n * The group of the catalogue. `media`: video, sound, camera, files, cropping. `blocks`: the page blocks — the frame,\n * the hero, sections, cards that lead or argue, decisions, code, calls to act — that every page of a site is made of.\n * `layouts`: the shells of whole screens — an application, a dashboard, settings, sign-in, an object, a list and its\n * item, a site's page, a documentation page — each with its screens. `templates`: the page templates — whole pages of a\n * site (a landing, a product, a docs hub, a long read, a changelog, pricing, status, an error…), each a distinct\n * composition of the blocks, words and content as props.\n */\nexport type Category = \"actions\" | \"forms\" | \"navigation\" | \"overlays\" | \"feedback\" | \"data-display\" | \"media\" | \"blocks\" | \"layouts\" | \"templates\" | \"layout\" | \"foundations\";\n\n/** Why a reader needs a template: the seven intents the templates are grouped by (sidebar sub-headings, catalogue filter). */\nexport type TemplatePurpose = \"convince\" | \"explain\" | \"show\" | \"act\" | \"operate\" | \"converse\" | \"recover\";\n\n/** The groups of templates, in reading order: the title, and the one line that says when to come to that group. */\nexport const templatePurposes = {\n convince: { title: \"Convince\", useWhen: \"You come here when a visitor must decide: a landing, a product, a price, a comparison, a proof.\" },\n explain: { title: \"Explain\", useWhen: \"You come here when a reader must understand: how it works, a documentation hub or article, a changelog, a FAQ, a policy.\" },\n show: { title: \"Show\", useWhen: \"You come here when the work itself is the argument: a gallery, a story, a case study, an object and its details.\" },\n act: { title: \"Act\", useWhen: \"You come here when a person must do something once: reach the team, sign in or up, set up, pay.\" },\n operate: { title: \"Operate\", useWhen: \"You come here when a person works every day: a dashboard, a console with a table, settings, an app shell.\" },\n converse: { title: \"Converse\", useWhen: \"You come here when people talk: an inbox, a chat, comments, a notifications centre.\" },\n recover: { title: \"Recover\", useWhen: \"You come here when the way is blocked: an empty list, an error, a missing page, maintenance, a product still being built.\" },\n} as const satisfies Record<TemplatePurpose, { readonly title: string; readonly useWhen: string }>;\n\n/**\n * A named example: the file `registry/examples/<component>/<name>.tsx` (web) or\n * `registry/examples/<component>/native/<name>.tsx` (React Native) — at most 40 lines, imported by the stories and\n * shown (live, with its code) by the documentation.\n */\ninterface ExampleBase {\n /** The file name, kebab-case (`primary`, `icon-button`). */\n readonly name: string;\n /** A short title (`Primary`, `Icon button`). */\n readonly title: string;\n /** One or two sentences: when this variant is the right one. */\n readonly description: string;\n}\n\n/** A plain example, or a template: a whole screen with its intent (`purpose`) and the user goal its layout serves (`why`). */\nexport type Example =\n | (ExampleBase & { readonly template?: false; readonly purpose?: undefined; readonly why?: undefined })\n | (ExampleBase & {\n /**\n * A template: a whole screen of a product composed from the platform (a layout and its blocks, real words, its\n * phone version thought out), copied as a starting point — at most 160 lines, listed on ui.krizaka.com/templates.\n */\n readonly template: true;\n /** The intent that groups it: why you need this block. */\n readonly purpose: TemplatePurpose;\n /** Why this layout: the user goal it serves, in one sentence. */\n readonly why: string;\n });\n\n/** One platform's side of a component. */\nexport interface PlatformDocs {\n /** The names to import (`[\"Button\", \"IconButton\"]`): from `@krizaka/ui/<name>` on the web, `@krizaka/ui/native` in React Native. */\n readonly imports: readonly string[];\n /** The examples, in reading order; the first one is the component's preview. */\n readonly examples: readonly Example[];\n}\n\n/** The React Native side: the same concept, and what differs from the web API. */\nexport interface NativeDocs extends PlatformDocs {\n /**\n * The entry to import from when it is not `@krizaka/ui/native`: a component that needs an Expo module (an optional\n * peer) has its own, `@krizaka/ui/native/<name>`, so an app that does not use it never installs the module.\n */\n readonly entry?: string;\n /** What differs from the web API (`label` instead of children…); empty for a native-only component. */\n readonly differences: readonly string[];\n /** The React Native entry alone is deprecated while the web one stays (ADR-006 §7); a deprecated component says it once, above. */\n readonly deprecated?: Deprecation;\n}\n\nexport interface KeyboardInteraction {\n /** The keys, as written on a keyboard: `Space`, `Enter`, `Arrow keys`, `Esc`, `Tab`. */\n readonly keys: string;\n /** What they do. */\n readonly action: string;\n}\n\nexport interface ComponentMeta {\n /** The display name: `Button`, `Dropdown menu`. */\n readonly title: string;\n /** One sentence: what it is. */\n readonly summary: string;\n readonly status: Status;\n /** Required for, and only for, a `deprecated` component. */\n readonly deprecated?: Deprecation;\n readonly category: Category;\n /** Must match the sides below: `both` ⇔ `web` and `native`. */\n readonly platforms: Platform;\n /** The platforms it is not on, and why; and its desktop form (see `Parity`). */\n readonly parity: Parity;\n /** When to reach for it: concrete situations, one per item. */\n readonly whenToUse: readonly string[];\n /** When not to — and what to use instead (`use`), when another component is the answer. */\n readonly whenNotToUse: readonly { readonly when: string; readonly use?: ComponentName }[];\n /** How to use it well: wording, placement, composition. */\n readonly bestPractices: readonly string[];\n readonly accessibility: {\n /** The keyboard, when it does more than Tab and Enter. */\n readonly keyboard: readonly KeyboardInteraction[];\n /** Roles, names and announcements: what the component does, what the app must provide. */\n readonly notes: readonly string[];\n };\n /** The components a reader of this page should know about. */\n readonly related: readonly ComponentName[];\n readonly web?: PlatformDocs;\n readonly native?: NativeDocs;\n}\n"
|
|
435
566
|
}
|
|
436
567
|
],
|
|
437
568
|
"dependencies": [
|
|
438
|
-
"radix-ui@^1.
|
|
569
|
+
"radix-ui@^1.8.1"
|
|
439
570
|
],
|
|
440
571
|
"registryDependencies": [
|
|
441
572
|
"avatar",
|
|
442
573
|
"badge",
|
|
443
574
|
"cn",
|
|
444
|
-
"
|
|
575
|
+
"field",
|
|
576
|
+
"radio-group",
|
|
577
|
+
"settings-layout",
|
|
578
|
+
"switch"
|
|
445
579
|
],
|
|
446
580
|
"demo": {
|
|
447
581
|
"path": "examples/account-settings/profile.tsx",
|
|
@@ -517,6 +651,124 @@
|
|
|
517
651
|
}
|
|
518
652
|
]
|
|
519
653
|
},
|
|
654
|
+
{
|
|
655
|
+
"component": "AppearanceSettings",
|
|
656
|
+
"description": "The appearance rows of a settings page: theme cards, accent, density, language, sound.",
|
|
657
|
+
"props": [
|
|
658
|
+
{
|
|
659
|
+
"name": "onThemeChange",
|
|
660
|
+
"type": "(id: string) => void",
|
|
661
|
+
"default": null,
|
|
662
|
+
"description": "Called with the id chosen.",
|
|
663
|
+
"required": true
|
|
664
|
+
},
|
|
665
|
+
{
|
|
666
|
+
"name": "theme",
|
|
667
|
+
"type": "string",
|
|
668
|
+
"default": null,
|
|
669
|
+
"description": "The id of the theme chosen.",
|
|
670
|
+
"required": true
|
|
671
|
+
},
|
|
672
|
+
{
|
|
673
|
+
"name": "themes",
|
|
674
|
+
"type": "readonly ThemeCardOption[]",
|
|
675
|
+
"default": null,
|
|
676
|
+
"description": "The themes offered: at least system, light and dark.",
|
|
677
|
+
"required": true
|
|
678
|
+
},
|
|
679
|
+
{
|
|
680
|
+
"name": "accent",
|
|
681
|
+
"type": "string | null",
|
|
682
|
+
"default": null,
|
|
683
|
+
"description": "The id of the accent chosen; null for the product's own.",
|
|
684
|
+
"required": false
|
|
685
|
+
},
|
|
686
|
+
{
|
|
687
|
+
"name": "accents",
|
|
688
|
+
"type": "readonly AccentOption[]",
|
|
689
|
+
"default": null,
|
|
690
|
+
"description": "The accents offered (the product's own first). Without it the row is not shown.",
|
|
691
|
+
"required": false
|
|
692
|
+
},
|
|
693
|
+
{
|
|
694
|
+
"name": "className",
|
|
695
|
+
"type": "string",
|
|
696
|
+
"default": null,
|
|
697
|
+
"description": "Classes merged on the root.",
|
|
698
|
+
"required": false
|
|
699
|
+
},
|
|
700
|
+
{
|
|
701
|
+
"name": "densities",
|
|
702
|
+
"type": "readonly { value: string; label: string; }[]",
|
|
703
|
+
"default": null,
|
|
704
|
+
"description": "The densities offered, with their names (`standard`, `compact`).",
|
|
705
|
+
"required": false
|
|
706
|
+
},
|
|
707
|
+
{
|
|
708
|
+
"name": "density",
|
|
709
|
+
"type": "string",
|
|
710
|
+
"default": null,
|
|
711
|
+
"description": "The density chosen.",
|
|
712
|
+
"required": false
|
|
713
|
+
},
|
|
714
|
+
{
|
|
715
|
+
"name": "labels",
|
|
716
|
+
"type": "Partial<AppearanceLabels>",
|
|
717
|
+
"default": null,
|
|
718
|
+
"description": "The words, passed translated (English by default).",
|
|
719
|
+
"required": false
|
|
720
|
+
},
|
|
721
|
+
{
|
|
722
|
+
"name": "language",
|
|
723
|
+
"type": "string",
|
|
724
|
+
"default": null,
|
|
725
|
+
"description": "The code of the language chosen.",
|
|
726
|
+
"required": false
|
|
727
|
+
},
|
|
728
|
+
{
|
|
729
|
+
"name": "languages",
|
|
730
|
+
"type": "readonly LanguageOption[]",
|
|
731
|
+
"default": null,
|
|
732
|
+
"description": "The languages offered, each named in its own language.",
|
|
733
|
+
"required": false
|
|
734
|
+
},
|
|
735
|
+
{
|
|
736
|
+
"name": "onAccentChange",
|
|
737
|
+
"type": "((id: string) => void)",
|
|
738
|
+
"default": null,
|
|
739
|
+
"description": "Called with the id chosen.",
|
|
740
|
+
"required": false
|
|
741
|
+
},
|
|
742
|
+
{
|
|
743
|
+
"name": "onDensityChange",
|
|
744
|
+
"type": "((density: string) => void)",
|
|
745
|
+
"default": null,
|
|
746
|
+
"description": "Called with the density chosen.",
|
|
747
|
+
"required": false
|
|
748
|
+
},
|
|
749
|
+
{
|
|
750
|
+
"name": "onLanguageChange",
|
|
751
|
+
"type": "((code: string) => void)",
|
|
752
|
+
"default": null,
|
|
753
|
+
"description": "Called with the code chosen.",
|
|
754
|
+
"required": false
|
|
755
|
+
},
|
|
756
|
+
{
|
|
757
|
+
"name": "onSoundChange",
|
|
758
|
+
"type": "((on: boolean) => void)",
|
|
759
|
+
"default": null,
|
|
760
|
+
"description": "Called with the new state.",
|
|
761
|
+
"required": false
|
|
762
|
+
},
|
|
763
|
+
{
|
|
764
|
+
"name": "sound",
|
|
765
|
+
"type": "boolean",
|
|
766
|
+
"default": null,
|
|
767
|
+
"description": "Shown only when given: the sound is opt-in.",
|
|
768
|
+
"required": false
|
|
769
|
+
}
|
|
770
|
+
]
|
|
771
|
+
},
|
|
520
772
|
{
|
|
521
773
|
"component": "AvatarPicker",
|
|
522
774
|
"description": "A grid of pictures to choose from, with an upload beside them: a radio group, never a row of loose radios.",
|
|
@@ -56,8 +56,7 @@
|
|
|
56
56
|
"related": [
|
|
57
57
|
"goal-gauge",
|
|
58
58
|
"badge",
|
|
59
|
-
"argument-card"
|
|
60
|
-
"scroll-stage"
|
|
59
|
+
"argument-card"
|
|
61
60
|
],
|
|
62
61
|
"web": {
|
|
63
62
|
"entry": "@krizaka/ui/achievement",
|
|
@@ -204,11 +203,11 @@
|
|
|
204
203
|
},
|
|
205
204
|
{
|
|
206
205
|
"path": "achievement/meta.ts",
|
|
207
|
-
"content": "import type { ComponentMeta } from \"../meta\";\n\nexport const meta = {\n title: \"Achievement\",\n summary:\n \"Something done, and what it replaced: a milestone reached, a dare completed, a problem out of the way — on one grid of hairlines in a list, their badges arriving one by one; with three line emblems.\",\n status: \"beta\",\n category: \"data-display\",\n platforms: \"web\",\n parity: { native: { status: \"n/a\", reason: \"Part of the storytelling kit of scroll-driven site pages; a phone app tells its first steps with Onboarding.\", use: \"mascot-state\" }, desktop: { status: \"n/a\", reason: \"A public site's page, not a window of the Mac app.\" } },\n whenToUse: [\n \"Milestones of a creator or a member: what is done, what is next (`locked`).\",\n \"What a product removed for its users (“Paying 30 % to a platform” → “90 % to you”).\",\n \"Problems sealed one by one on a told page, in time with a `GoalGauge` (the arcade flavour).\",\n ],\n whenNotToUse: [\n { when: \"A notification that something just happened.\", use: \"toast\" },\n { when: \"A status of an object (published, pending).\", use: \"badge\" },\n { when: \"An argument with its reasons and a link.\", use: \"argument-card\" },\n ],\n bestPractices: [\n \"The title is the outcome in a few words; `replaced` what it removed — struck through, so the change reads at a glance.\",\n \"Say a locked step in its badge (“Locked”), not only by the muted colour.\",\n \"Use `Emblem` (`sword`, `mirror`, `jewel`) as the glyphs of a set, or your own icons from @krizaka/icons.\",\n ],\n accessibility: {\n keyboard: [],\n notes: [\n \"`AchievementList` is an ordered list; `replaced` is a `del` element, read as removed text.\",\n \"Emblems and icons are decorative. The badges arrive once in a stage and never under `prefers-reduced-motion`.\",\n ],\n },\n related: [\"goal-gauge\", \"badge\", \"argument-card\"
|
|
206
|
+
"content": "import type { ComponentMeta } from \"../meta\";\n\nexport const meta = {\n title: \"Achievement\",\n summary:\n \"Something done, and what it replaced: a milestone reached, a dare completed, a problem out of the way — on one grid of hairlines in a list, their badges arriving one by one; with three line emblems.\",\n status: \"beta\",\n category: \"data-display\",\n platforms: \"web\",\n parity: { native: { status: \"n/a\", reason: \"Part of the storytelling kit of scroll-driven site pages; a phone app tells its first steps with Onboarding.\", use: \"mascot-state\" }, desktop: { status: \"n/a\", reason: \"A public site's page, not a window of the Mac app.\" } },\n whenToUse: [\n \"Milestones of a creator or a member: what is done, what is next (`locked`).\",\n \"What a product removed for its users (“Paying 30 % to a platform” → “90 % to you”).\",\n \"Problems sealed one by one on a told page, in time with a `GoalGauge` (the arcade flavour).\",\n ],\n whenNotToUse: [\n { when: \"A notification that something just happened.\", use: \"toast\" },\n { when: \"A status of an object (published, pending).\", use: \"badge\" },\n { when: \"An argument with its reasons and a link.\", use: \"argument-card\" },\n ],\n bestPractices: [\n \"The title is the outcome in a few words; `replaced` what it removed — struck through, so the change reads at a glance.\",\n \"Say a locked step in its badge (“Locked”), not only by the muted colour.\",\n \"Use `Emblem` (`sword`, `mirror`, `jewel`) as the glyphs of a set, or your own icons from @krizaka/icons.\",\n ],\n accessibility: {\n keyboard: [],\n notes: [\n \"`AchievementList` is an ordered list; `replaced` is a `del` element, read as removed text.\",\n \"Emblems and icons are decorative. The badges arrive once in a stage and never under `prefers-reduced-motion`.\",\n ],\n },\n related: [\"goal-gauge\", \"badge\", \"argument-card\"],\n web: {\n imports: [\"Achievement\", \"AchievementList\", \"Emblem\"],\n examples: [\n { name: \"milestones\", title: \"Milestones\", description: \"Two milestones done, with what they replaced; the next one locked.\" },\n { name: \"arcade\", title: \"Arcade flavour\", description: \"Heads sealed one by one, each stamp slamming in, with the three emblems.\" },\n ],\n },\n} satisfies ComponentMeta;\n"
|
|
208
207
|
},
|
|
209
208
|
{
|
|
210
209
|
"path": "meta.ts",
|
|
211
|
-
"content": "// The documentation of a component, carried by its code: each primitive has a `meta.ts` beside its source\n// (`src/<name>/meta.ts`; a component that exists only in React Native: `src/native/meta/<name>.ts`). Never built into\n// the package: `scripts/build-registry.mjs` reads them into `registry/<name>.json`, which ui.krizaka.com (apps/site) renders as\n// ui.krizaka.com/components/<name>, and `scripts/registry.test.mjs` fails when one is missing or incomplete.\n//\n// Why a typed module and not JSDoc tags: the fields are lists and links (`related`, `whenNotToUse[].use`, examples),\n// which a type checks and a comment does not; the file is plain data (erasable TypeScript), so Node reads it without a\n// compiler, and an editor completes it.\n\n/** Every documented component: the web primitives (one entry of the package each) and the native-only ones. */\nexport type ComponentName =\n | \"agenda\"\n | \"account-settings\"\n | \"drop-overlay\"\n | \"upload-queue\"\n | \"achievement\"\n | \"anatomy-plate\"\n | \"bird-plate\"\n | \"taped-photo\"\n | \"text-style\"\n | \"flock\"\n | \"elephant\"\n | \"footnote\"\n | \"page-index\"\n | \"chapter\"\n | \"specimen-tag\"\n | \"action-bar\"\n | \"action-sheet\"\n | \"activity-feed\"\n | \"alert\"\n | \"app-header\"\n | \"app-shell\"\n | \"argument-card\"\n | \"audio-player\"\n | \"auth-layout\"\n | \"avatar\"\n | \"badge\"\n | \"button\"\n | \"captcha\"\n | \"card\"\n | \"card-grid\"\n | \"catalogue-page\"\n | \"changelog-page\"\n | \"chat\"\n | \"checkbox\"\n | \"chip\"\n | \"chip-link\"\n | \"chip-row\"\n | \"choice-grid\"\n | \"cn\"\n | \"code-block\"\n | \"combobox\"\n | \"comparison-table\"\n | \"command\"\n | \"component-page\"\n | \"confirm-button\"\n | \"contact-page\"\n | \"continue-prompt\"\n | \"countdown\"\n | \"cover-hero\"\n | \"cta-panel\"\n | \"dashboard-layout\"\n | \"data-table\"\n | \"date-picker\"\n | \"decision-list\"\n | \"description-list\"\n | \"detail-layout\"\n | \"dialog\"\n | \"docs-article-page\"\n | \"docs-hub-page\"\n | \"docs-layout\"\n | \"docs-nav\"\n | \"document-viewer\"\n | \"dropdown-menu\"\n | \"empty-state\"\n | \"engine-flow\"\n | \"error-page\"\n | \"fab\"\n | \"field\"\n | \"file-upload\"\n | \"filter-bar\"\n | \"force-update-screen\"\n | \"form\"\n | \"gallery-page\"\n | \"genui\"\n | \"glossary\"\n | \"glossary-term\"\n | \"glow-card\"\n | \"goal-gauge\"\n | \"header\"\n | \"how-it-works-page\"\n | \"image-cropper\"\n | \"image-viewer\"\n | \"iso\"\n | \"kanban\"\n | \"kbd\"\n | \"kpi-explained\"\n | \"landing-page\"\n | \"landscape\"\n | \"legal-page\"\n | \"link-card\"\n | \"list\"\n | \"loader\"\n | \"longform-page\"\n | \"maintenance-screen\"\n | \"map\"\n | \"markdown\"\n | \"meta-row\"\n | \"waveform\"\n | \"marketing-layout\"\n | \"marquee\"\n | \"mascot-quote\"\n | \"mascot-state\"\n | \"mascots\"\n | \"match-dialog\"\n | \"media-capture\"\n | \"media-grid\"\n | \"language-switch\"\n | \"media-gallery\"\n | \"media-picker\"\n | \"meter\"\n | \"nav-bar\"\n | \"number-ticker\"\n | \"onboarding\"\n | \"opening-hours\"\n | \"otp-input\"\n | \"page\"\n | \"page-header\"\n | \"page-hero\"\n | \"pagination\"\n | \"permission-prompt\"\n | \"photo-grid\"\n | \"pointer-light\"\n | \"popover\"\n | \"pricing-page\"\n | \"product-page\"\n | \"profile-card\"\n | \"progress\"\n | \"promise-card\"\n | \"pull-to-refresh\"\n | \"radio-group\"\n | \"router\"\n | \"rail-nav\"\n | \"recipes\"\n | \"screen\"\n | \"scroll-stage\"\n | \"search-field\"\n | \"section-backdrop\"\n | \"segmented\"\n | \"separator\"\n | \"service-card\"\n | \"settings-layout\"\n | \"account-menu\"\n | \"showcase\"\n | \"step-showcase\"\n | \"site-footer\"\n | \"sites\"\n | \"skeleton\"\n | \"skip-link\"\n | \"slider\"\n | \"slot-picker\"\n | \"slot\"\n | \"spinner\"\n | \"sticky-action\"\n | \"splash-handoff\"\n | \"split-view\"\n | \"stage-banner\"\n | \"stat\"\n | \"status-page\"\n | \"step-progress\"\n | \"stepper\"\n | \"swipe-deck\"\n | \"swipeable-row\"\n | \"switch\"\n | \"tab-bar\"\n | \"tabs\"\n | \"tag-input\"\n | \"tag-selector\"\n | \"terminal-replay\"\n | \"theme\"\n | \"toast\"\n | \"toc\"\n | \"tooltip\"\n | \"tree-view\"\n | \"txt\"\n | \"update-prompt\"\n | \"verified-badge\"\n | \"vertical-video\"\n | \"video-player\"\n | \"video-trimmer\"\n | \"virtual\";\n\n/** Where a component exists: `@krizaka/ui/<name>` (web), `@krizaka/ui/native` (React Native), or both. */\nexport type Platform = \"web\" | \"native\" | \"both\";\n\n/**\n * Why a component is not on a platform — a decision, never a silence (the parity matrix of ui.krizaka.com/platforms):\n * - `gap` (✗): it belongs there and is not built yet; `issue` is the issue that tracks it (`krizaka/krizaka-ui#275`);\n * - `n/a`: it is not meant for that platform (a site's page block on a phone, a swipe on a desktop); `use` names the\n * component that answers there, when one does.\n */\nexport type Absence =\n | { readonly status: \"gap\"; readonly issue: string; readonly reason: string; readonly use?: undefined }\n | { readonly status: \"n/a\"; readonly reason: string; readonly use?: ComponentName; readonly issue?: undefined };\n\n/**\n * Desktop is the Orazaka Mac app (Tauri 2: the system WebView renders the web components — ADR-002). `web`: the web\n * component runs there as it is; `desktop`: it also has a desktop form (a window's title bar, a denser layout…), said in\n * its documentation; otherwise the absence and why.\n */\nexport type DesktopSupport = \"web\" | \"desktop\" | Absence;\n\n/**\n * The three platforms of Krizaka UI — web · native (React Native, Expo) · desktop — for one component. The side a\n * component has is `platforms`; the side it lacks says why here: `native` is required for (and only for) a web-only\n * component, `web` for a native-only one; `desktop` always. `scripts/registry.test.mjs` fails on a missing decision.\n */\nexport interface Parity {\n readonly web?: Absence;\n readonly native?: Absence;\n readonly desktop: DesktopSupport;\n}\n\n/**\n * `stable`: its API only changes in a major. `beta`: it may still change in a minor. `deprecated`: no product uses it and\n * no work plans to — it still works, says what replaces it, and goes in the major named by `deprecated.removedIn`.\n */\nexport type Status = \"stable\" | \"beta\" | \"deprecated\";\n\n/** What a deprecated component says (required when `status` is `deprecated`, absent otherwise). */\nexport interface Deprecation {\n /** The version that deprecated it (`3.6.0`). */\n readonly since: string;\n /** The major that removes it (`4.0.0`). */\n readonly removedIn: string;\n /** What replaces it, when a component does. */\n readonly use?: ComponentName;\n /** Why it goes: no product uses it, no planned work needs it. */\n readonly reason: string;\n}\n\n/**\n * The group of the catalogue. `media`: video, sound, camera, files, cropping. `blocks`: the page blocks — the frame,\n * the hero, sections, cards that lead or argue, decisions, code, calls to act — that every page of a site is made of.\n * `layouts`: the shells of whole screens — an application, a dashboard, settings, sign-in, an object, a list and its\n * item, a site's page, a documentation page — each with its screens. `templates`: the page templates — whole pages of a\n * site (a landing, a product, a docs hub, a long read, a changelog, pricing, status, an error…), each a distinct\n * composition of the blocks, words and content as props.\n */\nexport type Category = \"actions\" | \"forms\" | \"navigation\" | \"overlays\" | \"feedback\" | \"data-display\" | \"media\" | \"blocks\" | \"layouts\" | \"templates\" | \"layout\" | \"foundations\";\n\n/** Why a reader needs a template: the seven intents the templates are grouped by (sidebar sub-headings, catalogue filter). */\nexport type TemplatePurpose = \"convince\" | \"explain\" | \"show\" | \"act\" | \"operate\" | \"converse\" | \"recover\";\n\n/** The groups of templates, in reading order: the title, and the one line that says when to come to that group. */\nexport const templatePurposes = {\n convince: { title: \"Convince\", useWhen: \"You come here when a visitor must decide: a landing, a product, a price, a comparison, a proof.\" },\n explain: { title: \"Explain\", useWhen: \"You come here when a reader must understand: how it works, a documentation hub or article, a changelog, a FAQ, a policy.\" },\n show: { title: \"Show\", useWhen: \"You come here when the work itself is the argument: a gallery, a story, a case study, an object and its details.\" },\n act: { title: \"Act\", useWhen: \"You come here when a person must do something once: reach the team, sign in or up, set up, pay.\" },\n operate: { title: \"Operate\", useWhen: \"You come here when a person works every day: a dashboard, a console with a table, settings, an app shell.\" },\n converse: { title: \"Converse\", useWhen: \"You come here when people talk: an inbox, a chat, comments, a notifications centre.\" },\n recover: { title: \"Recover\", useWhen: \"You come here when the way is blocked: an empty list, an error, a missing page, maintenance, a product still being built.\" },\n} as const satisfies Record<TemplatePurpose, { readonly title: string; readonly useWhen: string }>;\n\n/**\n * A named example: the file `registry/examples/<component>/<name>.tsx` (web) or\n * `registry/examples/<component>/native/<name>.tsx` (React Native) — at most 40 lines, imported by the stories and\n * shown (live, with its code) by the documentation.\n */\ninterface ExampleBase {\n /** The file name, kebab-case (`primary`, `icon-button`). */\n readonly name: string;\n /** A short title (`Primary`, `Icon button`). */\n readonly title: string;\n /** One or two sentences: when this variant is the right one. */\n readonly description: string;\n}\n\n/** A plain example, or a template: a whole screen with its intent (`purpose`) and the user goal its layout serves (`why`). */\nexport type Example =\n | (ExampleBase & { readonly template?: false; readonly purpose?: undefined; readonly why?: undefined })\n | (ExampleBase & {\n /**\n * A template: a whole screen of a product composed from the platform (a layout and its blocks, real words, its\n * phone version thought out), copied as a starting point — at most 160 lines, listed on ui.krizaka.com/templates.\n */\n readonly template: true;\n /** The intent that groups it: why you need this block. */\n readonly purpose: TemplatePurpose;\n /** Why this layout: the user goal it serves, in one sentence. */\n readonly why: string;\n });\n\n/** One platform's side of a component. */\nexport interface PlatformDocs {\n /** The names to import (`[\"Button\", \"IconButton\"]`): from `@krizaka/ui/<name>` on the web, `@krizaka/ui/native` in React Native. */\n readonly imports: readonly string[];\n /** The examples, in reading order; the first one is the component's preview. */\n readonly examples: readonly Example[];\n}\n\n/** The React Native side: the same concept, and what differs from the web API. */\nexport interface NativeDocs extends PlatformDocs {\n /**\n * The entry to import from when it is not `@krizaka/ui/native`: a component that needs an Expo module (an optional\n * peer) has its own, `@krizaka/ui/native/<name>`, so an app that does not use it never installs the module.\n */\n readonly entry?: string;\n /** What differs from the web API (`label` instead of children…); empty for a native-only component. */\n readonly differences: readonly string[];\n}\n\nexport interface KeyboardInteraction {\n /** The keys, as written on a keyboard: `Space`, `Enter`, `Arrow keys`, `Esc`, `Tab`. */\n readonly keys: string;\n /** What they do. */\n readonly action: string;\n}\n\nexport interface ComponentMeta {\n /** The display name: `Button`, `Dropdown menu`. */\n readonly title: string;\n /** One sentence: what it is. */\n readonly summary: string;\n readonly status: Status;\n /** Required for, and only for, a `deprecated` component. */\n readonly deprecated?: Deprecation;\n readonly category: Category;\n /** Must match the sides below: `both` ⇔ `web` and `native`. */\n readonly platforms: Platform;\n /** The platforms it is not on, and why; and its desktop form (see `Parity`). */\n readonly parity: Parity;\n /** When to reach for it: concrete situations, one per item. */\n readonly whenToUse: readonly string[];\n /** When not to — and what to use instead (`use`), when another component is the answer. */\n readonly whenNotToUse: readonly { readonly when: string; readonly use?: ComponentName }[];\n /** How to use it well: wording, placement, composition. */\n readonly bestPractices: readonly string[];\n readonly accessibility: {\n /** The keyboard, when it does more than Tab and Enter. */\n readonly keyboard: readonly KeyboardInteraction[];\n /** Roles, names and announcements: what the component does, what the app must provide. */\n readonly notes: readonly string[];\n };\n /** The components a reader of this page should know about. */\n readonly related: readonly ComponentName[];\n readonly web?: PlatformDocs;\n readonly native?: NativeDocs;\n}\n"
|
|
210
|
+
"content": "// The documentation of a component, carried by its code: each primitive has a `meta.ts` beside its source\n// (`src/<name>/meta.ts`; a component that exists only in React Native: `src/native/meta/<name>.ts`). Never built into\n// the package: `scripts/build-registry.mjs` reads them into `registry/<name>.json`, which ui.krizaka.com (apps/site) renders as\n// ui.krizaka.com/components/<name>, and `scripts/registry.test.mjs` fails when one is missing or incomplete.\n//\n// Why a typed module and not JSDoc tags: the fields are lists and links (`related`, `whenNotToUse[].use`, examples),\n// which a type checks and a comment does not; the file is plain data (erasable TypeScript), so Node reads it without a\n// compiler, and an editor completes it.\n\n/** Every documented component: the web primitives (one entry of the package each) and the native-only ones. */\nexport type ComponentName =\n | \"notification-preferences\"\n | \"quota-meter\"\n | \"status-chip\"\n | \"kind-config-editor\"\n | \"agenda\"\n | \"account-settings\"\n | \"drop-overlay\"\n | \"upload-queue\"\n | \"achievement\"\n | \"anatomy-plate\"\n | \"bird-plate\"\n | \"taped-photo\"\n | \"stuck\"\n | \"doodle\"\n | \"signature\"\n | \"grade-stamp\"\n | \"versus-card\"\n | \"speed-lines\"\n | \"site-cahier\"\n | \"text-style\"\n | \"flock\"\n | \"elephant\"\n | \"footnote\"\n | \"page-index\"\n | \"chapter\"\n | \"specimen-tag\"\n | \"action-bar\"\n | \"action-sheet\"\n | \"activity-feed\"\n | \"alert\"\n | \"app-header\"\n | \"app-shell\"\n | \"argument-card\"\n | \"audio-player\"\n | \"auth-layout\"\n | \"avatar\"\n | \"badge\"\n | \"button\"\n | \"captcha\"\n | \"card\"\n | \"card-grid\"\n | \"catalogue-page\"\n | \"changelog-page\"\n | \"chat\"\n | \"checkbox\"\n | \"chip\"\n | \"chip-link\"\n | \"chip-row\"\n | \"choice-grid\"\n | \"cn\"\n | \"code-block\"\n | \"combobox\"\n | \"comparison-table\"\n | \"command\"\n | \"component-page\"\n | \"confirm-button\"\n | \"contact-page\"\n | \"continue-prompt\"\n | \"countdown\"\n | \"cover-hero\"\n | \"cta-panel\"\n | \"dashboard-layout\"\n | \"data-table\"\n | \"date-picker\"\n | \"decision-list\"\n | \"description-list\"\n | \"detail-layout\"\n | \"dialog\"\n | \"docs-article-page\"\n | \"docs-hub-page\"\n | \"docs-layout\"\n | \"docs-nav\"\n | \"document-viewer\"\n | \"dropdown-menu\"\n | \"empty-state\"\n | \"engine-flow\"\n | \"error-page\"\n | \"fab\"\n | \"field\"\n | \"file-upload\"\n | \"filter-bar\"\n | \"force-update-screen\"\n | \"form\"\n | \"gallery-page\"\n | \"genui\"\n | \"glossary\"\n | \"glossary-term\"\n | \"glow-card\"\n | \"goal-gauge\"\n | \"header\"\n | \"how-it-works-page\"\n | \"image-cropper\"\n | \"image-viewer\"\n | \"iso\"\n | \"kanban\"\n | \"kbd\"\n | \"kpi-explained\"\n | \"landing-page\"\n | \"landscape\"\n | \"legal-page\"\n | \"link-card\"\n | \"list\"\n | \"loader\"\n | \"longform-page\"\n | \"maintenance-screen\"\n | \"map\"\n | \"markdown\"\n | \"meta-row\"\n | \"waveform\"\n | \"marketing-layout\"\n | \"marquee\"\n | \"mascot-quote\"\n | \"mascot-state\"\n | \"mascots\"\n | \"match-dialog\"\n | \"media-capture\"\n | \"media-grid\"\n | \"language-switch\"\n | \"media-gallery\"\n | \"media-picker\"\n | \"meter\"\n | \"nav-bar\"\n | \"number-ticker\"\n | \"onboarding\"\n | \"opening-hours\"\n | \"otp-input\"\n | \"page\"\n | \"page-header\"\n | \"page-hero\"\n | \"pagination\"\n | \"permission-prompt\"\n | \"photo-grid\"\n | \"pointer-light\"\n | \"popover\"\n | \"pricing-page\"\n | \"product-page\"\n | \"profile-card\"\n | \"progress\"\n | \"promise-card\"\n | \"pull-to-refresh\"\n | \"retro-tv\"\n | \"radio-group\"\n | \"router\"\n | \"rail-nav\"\n | \"recipes\"\n | \"screen\"\n | \"scroll-stage\"\n | \"search-field\"\n | \"section-backdrop\"\n | \"segmented\"\n | \"separator\"\n | \"service-card\"\n | \"settings-layout\"\n | \"account-menu\"\n | \"showcase\"\n | \"step-showcase\"\n | \"site-footer\"\n | \"sites\"\n | \"skeleton\"\n | \"skip-link\"\n | \"slider\"\n | \"slot-picker\"\n | \"slot\"\n | \"spinner\"\n | \"sticky-action\"\n | \"splash-handoff\"\n | \"split-view\"\n | \"stage-banner\"\n | \"stat\"\n | \"status-page\"\n | \"step-progress\"\n | \"stepper\"\n | \"swipe-deck\"\n | \"swipeable-row\"\n | \"switch\"\n | \"tab-bar\"\n | \"tabs\"\n | \"tag-input\"\n | \"tag-selector\"\n | \"terminal-replay\"\n | \"theme\"\n | \"toast\"\n | \"toc\"\n | \"tooltip\"\n | \"tree-view\"\n | \"txt\"\n | \"update-prompt\"\n | \"verified-badge\"\n | \"vertical-video\"\n | \"video-player\"\n | \"video-trimmer\"\n | \"virtual\";\n\n/** Where a component exists: `@krizaka/ui/<name>` (web), `@krizaka/ui/native` (React Native), or both. */\nexport type Platform = \"web\" | \"native\" | \"both\";\n\n/**\n * Why a component is not on a platform — a decision, never a silence (the parity matrix of ui.krizaka.com/platforms):\n * - `gap` (✗): it belongs there and is not built yet; `issue` is the issue that tracks it (`krizaka/krizaka-ui#275`);\n * - `n/a`: it is not meant for that platform (a site's page block on a phone, a swipe on a desktop); `use` names the\n * component that answers there, when one does.\n */\nexport type Absence =\n | { readonly status: \"gap\"; readonly issue: string; readonly reason: string; readonly use?: undefined }\n | { readonly status: \"n/a\"; readonly reason: string; readonly use?: ComponentName; readonly issue?: undefined };\n\n/**\n * Desktop is the Orazaka Mac app (Tauri 2: the system WebView renders the web components — ADR-002). `web`: the web\n * component runs there as it is; `desktop`: it also has a desktop form (a window's title bar, a denser layout…), said in\n * its documentation; otherwise the absence and why.\n */\nexport type DesktopSupport = \"web\" | \"desktop\" | Absence;\n\n/**\n * The three platforms of Krizaka UI — web · native (React Native, Expo) · desktop — for one component. The side a\n * component has is `platforms`; the side it lacks says why here: `native` is required for (and only for) a web-only\n * component, `web` for a native-only one; `desktop` always. `scripts/registry.test.mjs` fails on a missing decision.\n */\nexport interface Parity {\n readonly web?: Absence;\n readonly native?: Absence;\n readonly desktop: DesktopSupport;\n}\n\n/**\n * `stable`: its API only changes in a major. `beta`: it may still change in a minor. `deprecated`: no product uses it and\n * no work plans to — it still works, says what replaces it, and goes in the major named by `deprecated.removedIn`.\n */\nexport type Status = \"stable\" | \"beta\" | \"deprecated\";\n\n/** What a deprecated component says (required when `status` is `deprecated`, absent otherwise). */\nexport interface Deprecation {\n /** The version that deprecated it (`3.6.0`). */\n readonly since: string;\n /** The major that removes it (`4.0.0`). */\n readonly removedIn: string;\n /** What replaces it, when a component does. */\n readonly use?: ComponentName;\n /** Why it goes: no product uses it, no planned work needs it. */\n readonly reason: string;\n}\n\n/**\n * The group of the catalogue. `media`: video, sound, camera, files, cropping. `blocks`: the page blocks — the frame,\n * the hero, sections, cards that lead or argue, decisions, code, calls to act — that every page of a site is made of.\n * `layouts`: the shells of whole screens — an application, a dashboard, settings, sign-in, an object, a list and its\n * item, a site's page, a documentation page — each with its screens. `templates`: the page templates — whole pages of a\n * site (a landing, a product, a docs hub, a long read, a changelog, pricing, status, an error…), each a distinct\n * composition of the blocks, words and content as props.\n */\nexport type Category = \"actions\" | \"forms\" | \"navigation\" | \"overlays\" | \"feedback\" | \"data-display\" | \"media\" | \"blocks\" | \"layouts\" | \"templates\" | \"layout\" | \"foundations\";\n\n/** Why a reader needs a template: the seven intents the templates are grouped by (sidebar sub-headings, catalogue filter). */\nexport type TemplatePurpose = \"convince\" | \"explain\" | \"show\" | \"act\" | \"operate\" | \"converse\" | \"recover\";\n\n/** The groups of templates, in reading order: the title, and the one line that says when to come to that group. */\nexport const templatePurposes = {\n convince: { title: \"Convince\", useWhen: \"You come here when a visitor must decide: a landing, a product, a price, a comparison, a proof.\" },\n explain: { title: \"Explain\", useWhen: \"You come here when a reader must understand: how it works, a documentation hub or article, a changelog, a FAQ, a policy.\" },\n show: { title: \"Show\", useWhen: \"You come here when the work itself is the argument: a gallery, a story, a case study, an object and its details.\" },\n act: { title: \"Act\", useWhen: \"You come here when a person must do something once: reach the team, sign in or up, set up, pay.\" },\n operate: { title: \"Operate\", useWhen: \"You come here when a person works every day: a dashboard, a console with a table, settings, an app shell.\" },\n converse: { title: \"Converse\", useWhen: \"You come here when people talk: an inbox, a chat, comments, a notifications centre.\" },\n recover: { title: \"Recover\", useWhen: \"You come here when the way is blocked: an empty list, an error, a missing page, maintenance, a product still being built.\" },\n} as const satisfies Record<TemplatePurpose, { readonly title: string; readonly useWhen: string }>;\n\n/**\n * A named example: the file `registry/examples/<component>/<name>.tsx` (web) or\n * `registry/examples/<component>/native/<name>.tsx` (React Native) — at most 40 lines, imported by the stories and\n * shown (live, with its code) by the documentation.\n */\ninterface ExampleBase {\n /** The file name, kebab-case (`primary`, `icon-button`). */\n readonly name: string;\n /** A short title (`Primary`, `Icon button`). */\n readonly title: string;\n /** One or two sentences: when this variant is the right one. */\n readonly description: string;\n}\n\n/** A plain example, or a template: a whole screen with its intent (`purpose`) and the user goal its layout serves (`why`). */\nexport type Example =\n | (ExampleBase & { readonly template?: false; readonly purpose?: undefined; readonly why?: undefined })\n | (ExampleBase & {\n /**\n * A template: a whole screen of a product composed from the platform (a layout and its blocks, real words, its\n * phone version thought out), copied as a starting point — at most 160 lines, listed on ui.krizaka.com/templates.\n */\n readonly template: true;\n /** The intent that groups it: why you need this block. */\n readonly purpose: TemplatePurpose;\n /** Why this layout: the user goal it serves, in one sentence. */\n readonly why: string;\n });\n\n/** One platform's side of a component. */\nexport interface PlatformDocs {\n /** The names to import (`[\"Button\", \"IconButton\"]`): from `@krizaka/ui/<name>` on the web, `@krizaka/ui/native` in React Native. */\n readonly imports: readonly string[];\n /** The examples, in reading order; the first one is the component's preview. */\n readonly examples: readonly Example[];\n}\n\n/** The React Native side: the same concept, and what differs from the web API. */\nexport interface NativeDocs extends PlatformDocs {\n /**\n * The entry to import from when it is not `@krizaka/ui/native`: a component that needs an Expo module (an optional\n * peer) has its own, `@krizaka/ui/native/<name>`, so an app that does not use it never installs the module.\n */\n readonly entry?: string;\n /** What differs from the web API (`label` instead of children…); empty for a native-only component. */\n readonly differences: readonly string[];\n /** The React Native entry alone is deprecated while the web one stays (ADR-006 §7); a deprecated component says it once, above. */\n readonly deprecated?: Deprecation;\n}\n\nexport interface KeyboardInteraction {\n /** The keys, as written on a keyboard: `Space`, `Enter`, `Arrow keys`, `Esc`, `Tab`. */\n readonly keys: string;\n /** What they do. */\n readonly action: string;\n}\n\nexport interface ComponentMeta {\n /** The display name: `Button`, `Dropdown menu`. */\n readonly title: string;\n /** One sentence: what it is. */\n readonly summary: string;\n readonly status: Status;\n /** Required for, and only for, a `deprecated` component. */\n readonly deprecated?: Deprecation;\n readonly category: Category;\n /** Must match the sides below: `both` ⇔ `web` and `native`. */\n readonly platforms: Platform;\n /** The platforms it is not on, and why; and its desktop form (see `Parity`). */\n readonly parity: Parity;\n /** When to reach for it: concrete situations, one per item. */\n readonly whenToUse: readonly string[];\n /** When not to — and what to use instead (`use`), when another component is the answer. */\n readonly whenNotToUse: readonly { readonly when: string; readonly use?: ComponentName }[];\n /** How to use it well: wording, placement, composition. */\n readonly bestPractices: readonly string[];\n readonly accessibility: {\n /** The keyboard, when it does more than Tab and Enter. */\n readonly keyboard: readonly KeyboardInteraction[];\n /** Roles, names and announcements: what the component does, what the app must provide. */\n readonly notes: readonly string[];\n };\n /** The components a reader of this page should know about. */\n readonly related: readonly ComponentName[];\n readonly web?: PlatformDocs;\n readonly native?: NativeDocs;\n}\n"
|
|
212
211
|
},
|
|
213
212
|
{
|
|
214
213
|
"path": "story-variant.ts",
|