@krizaka/ui 3.34.0 → 3.36.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/dist/account-menu.js +1 -1
- package/dist/account-menu.js.map +1 -1
- package/dist/activity-feed.js +1 -1
- package/dist/activity-feed.js.map +1 -1
- package/dist/anatomy-plate.d.ts +26 -0
- package/dist/anatomy-plate.js +32 -0
- package/dist/anatomy-plate.js.map +1 -0
- package/dist/app-header.js +1 -1
- package/dist/app-header.js.map +1 -1
- package/dist/app-shell.js +3 -3
- package/dist/app-shell.js.map +1 -1
- package/dist/argument-card.js +1 -1
- package/dist/bird-plate.d.ts +38 -0
- package/dist/bird-plate.js +39 -0
- package/dist/bird-plate.js.map +1 -0
- package/dist/blocks.css +243 -46
- package/dist/checkbox.js +1 -1
- package/dist/checkbox.js.map +1 -1
- package/dist/chip-row.js +1 -1
- package/dist/chip-row.js.map +1 -1
- package/dist/{chunk-3S4GHSPZ.js → chunk-63KCDMX2.js} +3 -3
- package/dist/chunk-63KCDMX2.js.map +1 -0
- package/dist/{chunk-NJFCSVPT.js → chunk-6EAHUURY.js} +2 -2
- package/dist/chunk-6EAHUURY.js.map +1 -0
- package/dist/{chunk-REPTKUJ6.js → chunk-7NRSPHAF.js} +2 -2
- package/dist/chunk-7NRSPHAF.js.map +1 -0
- package/dist/{chunk-2AJ4NJUF.js → chunk-IANSFIVC.js} +5 -1
- package/dist/chunk-IANSFIVC.js.map +1 -0
- package/dist/chunk-JFJECOZ2.js +338 -0
- package/dist/chunk-JFJECOZ2.js.map +1 -0
- package/dist/{chunk-KIBICUZK.js → chunk-K2ZYB4HP.js} +4 -4
- package/dist/{chunk-7Z4KHPFC.js → chunk-YGIN2YIY.js} +2 -2
- package/dist/{chunk-7Z4KHPFC.js.map → chunk-YGIN2YIY.js.map} +1 -1
- package/dist/{chunk-LZNZLCOE.js → chunk-YKEIOYJ5.js} +20 -6
- package/dist/chunk-YKEIOYJ5.js.map +1 -0
- package/dist/{chunk-2PNLHZLT.js → chunk-YOTQD7JD.js} +2 -2
- package/dist/chunk-YOTQD7JD.js.map +1 -0
- package/dist/command.js +3 -3
- package/dist/command.js.map +1 -1
- package/dist/comparison-table.js +2 -2
- package/dist/comparison-table.js.map +1 -1
- package/dist/countdown.js +1 -1
- package/dist/countdown.js.map +1 -1
- package/dist/cover-hero.js +15 -6
- package/dist/cover-hero.js.map +1 -1
- package/dist/dashboard-layout.js +1 -1
- package/dist/dashboard-layout.js.map +1 -1
- package/dist/data-table.js +4 -4
- package/dist/date-picker.js +3 -3
- package/dist/date-picker.js.map +1 -1
- package/dist/description-list.js +1 -1
- package/dist/description-list.js.map +1 -1
- package/dist/detail-layout.js +1 -1
- package/dist/detail-layout.js.map +1 -1
- package/dist/dialog.js +1 -1
- package/dist/docs-nav.js +1 -1
- package/dist/docs-nav.js.map +1 -1
- package/dist/dropdown-menu.js +1 -1
- package/dist/dropdown-menu.js.map +1 -1
- package/dist/filter-bar.js +1 -1
- package/dist/footnote.d.ts +32 -0
- package/dist/footnote.js +29 -0
- package/dist/footnote.js.map +1 -0
- package/dist/genui.js +4 -4
- package/dist/geometry-DncHaYP8.d.ts +22 -0
- package/dist/language-switch.js +1 -1
- package/dist/list.js +1 -1
- package/dist/loader.js +2 -2
- package/dist/loader.js.map +1 -1
- package/dist/map.js +95 -83
- package/dist/map.js.map +1 -1
- package/dist/mascot-quote.d.ts +2 -21
- package/dist/mascot-quote.js +9 -338
- package/dist/mascot-quote.js.map +1 -1
- package/dist/match-dialog.js +1 -1
- package/dist/match-dialog.js.map +1 -1
- package/dist/meter.js +1 -1
- package/dist/meter.js.map +1 -1
- package/dist/motion.css +28 -41
- package/dist/native/map.js +94 -82
- package/dist/native/map.js.map +1 -1
- package/dist/native.d.ts +8 -1
- package/dist/native.js +53 -41
- package/dist/native.js.map +1 -1
- package/dist/nav-bar.d.ts +1 -1
- package/dist/nav-bar.js +9 -9
- package/dist/nav-bar.js.map +1 -1
- package/dist/page-hero.js +1 -1
- package/dist/page-index.d.ts +30 -0
- package/dist/page-index.js +23 -0
- package/dist/page-index.js.map +1 -0
- package/dist/page.d.ts +19 -7
- package/dist/page.js +1 -1
- package/dist/photo-grid.js +2 -2
- package/dist/photo-grid.js.map +1 -1
- package/dist/radio-group.js +1 -1
- package/dist/radio-group.js.map +1 -1
- package/dist/rail-nav.js +1 -1
- package/dist/rail-nav.js.map +1 -1
- package/dist/search-field.js +1 -1
- package/dist/service-card.js +2 -2
- package/dist/service-card.js.map +1 -1
- package/dist/site-footer.d.ts +1 -1
- package/dist/site-footer.js +3 -3
- package/dist/site-footer.js.map +1 -1
- package/dist/{sites-B4prB793.d.ts → sites-B4sYlfPQ.d.ts} +1 -1
- package/dist/sites.d.ts +1 -1
- package/dist/sites.js +4 -0
- package/dist/sites.js.map +1 -1
- package/dist/specimen-tag.d.ts +52 -0
- package/dist/specimen-tag.js +33 -0
- package/dist/specimen-tag.js.map +1 -0
- package/dist/stat.js +1 -1
- package/dist/stat.js.map +1 -1
- package/dist/sticky-action.d.ts +1 -1
- package/dist/sticky-action.js +1 -1
- package/dist/sticky-action.js.map +1 -1
- package/dist/swipe-deck.js +1 -1
- package/dist/swipe-deck.js.map +1 -1
- package/package.json +78 -8
- package/registry/account-menu.json +1 -1
- package/registry/achievement.json +1 -1
- package/registry/action-bar.json +1 -1
- package/registry/activity-feed.json +2 -2
- package/registry/alert.json +1 -1
- package/registry/anatomy-plate.json +168 -0
- package/registry/app-header.json +2 -2
- 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 +1 -1
- package/registry/badge.json +1 -1
- package/registry/bird-plate.json +221 -0
- package/registry/button.json +1 -1
- package/registry/captcha.json +1 -1
- package/registry/card-grid.json +1 -1
- package/registry/card.json +1 -1
- package/registry/catalogue-page.json +1 -1
- package/registry/changelog-page.json +1 -1
- package/registry/chat.json +3 -3
- package/registry/checkbox.json +2 -2
- package/registry/chip-link.json +1 -1
- package/registry/chip-row.json +2 -2
- package/registry/chip.json +1 -1
- package/registry/choice-grid.json +1 -1
- package/registry/code-block.json +1 -1
- package/registry/combobox.json +1 -1
- package/registry/command.json +2 -2
- package/registry/comparison-table.json +2 -2
- package/registry/component-page.json +1 -1
- package/registry/confirm-button.json +1 -1
- package/registry/contact-page.json +1 -1
- package/registry/continue-prompt.json +1 -1
- package/registry/countdown.json +2 -2
- package/registry/cover-hero.json +2 -2
- package/registry/cta-panel.json +1 -1
- package/registry/dashboard-layout.json +2 -2
- package/registry/data-table.json +1 -1
- package/registry/date-picker.json +4 -4
- package/registry/decision-list.json +1 -1
- package/registry/description-list.json +2 -2
- package/registry/detail-layout.json +2 -2
- package/registry/dialog.json +2 -2
- package/registry/docs-article-page.json +1 -1
- package/registry/docs-hub-page.json +1 -1
- package/registry/docs-layout.json +1 -1
- package/registry/docs-nav.json +2 -2
- package/registry/document-viewer.json +1 -1
- package/registry/dropdown-menu.json +2 -2
- package/registry/empty-state.json +1 -1
- package/registry/engine-flow.json +1 -1
- package/registry/error-page.json +1 -1
- package/registry/examples/action-sheet/native/video-actions.dark.png +0 -0
- package/registry/examples/action-sheet/native/video-actions.light.png +0 -0
- package/registry/examples/activity-feed/native/notifications.dark.png +0 -0
- package/registry/examples/activity-feed/native/notifications.light.png +0 -0
- package/registry/examples/anatomy-plate/button.d.ts +4 -0
- package/registry/examples/anatomy-plate/button.js +25 -0
- package/registry/examples/anatomy-plate/button.tsx +20 -0
- package/registry/examples/avatar/native/group.dark.png +0 -0
- package/registry/examples/avatar/native/group.light.png +0 -0
- package/registry/examples/avatar/native/presence.dark.png +0 -0
- package/registry/examples/avatar/native/presence.light.png +0 -0
- package/registry/examples/avatar/native/sizes.dark.png +0 -0
- package/registry/examples/avatar/native/sizes.light.png +0 -0
- package/registry/examples/badge/native/dot.dark.png +0 -0
- package/registry/examples/badge/native/dot.light.png +0 -0
- package/registry/examples/badge/native/scrim.dark.png +0 -0
- package/registry/examples/badge/native/scrim.light.png +0 -0
- package/registry/examples/badge/native/tones.dark.png +0 -0
- package/registry/examples/badge/native/tones.light.png +0 -0
- package/registry/examples/bird-plate/flock.d.ts +4 -0
- package/registry/examples/bird-plate/flock.js +24 -0
- package/registry/examples/bird-plate/flock.tsx +18 -0
- package/registry/examples/bird-plate/single.d.ts +4 -0
- package/registry/examples/bird-plate/single.js +19 -0
- package/registry/examples/bird-plate/single.tsx +13 -0
- package/registry/examples/button/native/danger.dark.png +0 -0
- package/registry/examples/button/native/danger.light.png +0 -0
- package/registry/examples/button/native/disabled.dark.png +0 -0
- package/registry/examples/button/native/disabled.light.png +0 -0
- package/registry/examples/button/native/ghost.dark.png +0 -0
- package/registry/examples/button/native/ghost.light.png +0 -0
- package/registry/examples/button/native/gradient.dark.png +0 -0
- package/registry/examples/button/native/gradient.light.png +0 -0
- package/registry/examples/button/native/icon-only.dark.png +0 -0
- package/registry/examples/button/native/icon-only.light.png +0 -0
- package/registry/examples/button/native/icon.dark.png +0 -0
- package/registry/examples/button/native/icon.light.png +0 -0
- package/registry/examples/button/native/loading.dark.png +0 -0
- package/registry/examples/button/native/loading.light.png +0 -0
- package/registry/examples/button/native/outline.dark.png +0 -0
- package/registry/examples/button/native/outline.light.png +0 -0
- package/registry/examples/button/native/primary.dark.png +0 -0
- package/registry/examples/button/native/primary.light.png +0 -0
- package/registry/examples/button/native/secondary.dark.png +0 -0
- package/registry/examples/button/native/secondary.light.png +0 -0
- package/registry/examples/button/native/sizes.dark.png +0 -0
- package/registry/examples/button/native/sizes.light.png +0 -0
- package/registry/examples/card/native/body.dark.png +0 -0
- package/registry/examples/card/native/body.light.png +0 -0
- package/registry/examples/card/native/default.dark.png +0 -0
- package/registry/examples/card/native/default.light.png +0 -0
- package/registry/examples/card/native/elevated.dark.png +0 -0
- package/registry/examples/card/native/elevated.light.png +0 -0
- package/registry/examples/card/native/pressable.dark.png +0 -0
- package/registry/examples/card/native/pressable.light.png +0 -0
- package/registry/examples/chat/native/assistant.dark.png +0 -0
- package/registry/examples/chat/native/assistant.light.png +0 -0
- package/registry/examples/chat/native/conversation.dark.png +0 -0
- package/registry/examples/chat/native/conversation.light.png +0 -0
- package/registry/examples/chat/native/inbox.dark.png +0 -0
- package/registry/examples/chat/native/inbox.light.png +0 -0
- package/registry/examples/checkbox/native/terms.dark.png +0 -0
- package/registry/examples/checkbox/native/terms.light.png +0 -0
- package/registry/examples/chip/native/multiple.dark.png +0 -0
- package/registry/examples/chip/native/multiple.light.png +0 -0
- package/registry/examples/chip/native/removable.dark.png +0 -0
- package/registry/examples/chip/native/removable.light.png +0 -0
- package/registry/examples/chip/native/single.dark.png +0 -0
- package/registry/examples/chip/native/single.light.png +0 -0
- package/registry/examples/chip/native/toggle.dark.png +0 -0
- package/registry/examples/chip/native/toggle.light.png +0 -0
- package/registry/examples/combobox/native/multiple.dark.png +0 -0
- package/registry/examples/combobox/native/multiple.light.png +0 -0
- package/registry/examples/combobox/native/search.dark.png +0 -0
- package/registry/examples/combobox/native/search.light.png +0 -0
- package/registry/examples/countdown/native/days.dark.png +0 -0
- package/registry/examples/countdown/native/days.light.png +0 -0
- package/registry/examples/countdown/native/hours.dark.png +0 -0
- package/registry/examples/countdown/native/hours.light.png +0 -0
- package/registry/examples/countdown/native/sizes.dark.png +0 -0
- package/registry/examples/countdown/native/sizes.light.png +0 -0
- package/registry/examples/countdown/native/urgent.dark.png +0 -0
- package/registry/examples/countdown/native/urgent.light.png +0 -0
- package/registry/examples/countdown/native/with-label.dark.png +0 -0
- package/registry/examples/countdown/native/with-label.light.png +0 -0
- package/registry/examples/date-picker/native/birth-date-wheel.dark.png +0 -0
- package/registry/examples/date-picker/native/birth-date-wheel.light.png +0 -0
- package/registry/examples/date-picker/native/birth-date.dark.png +0 -0
- package/registry/examples/date-picker/native/birth-date.light.png +0 -0
- package/registry/examples/date-picker/native/calendar.dark.png +0 -0
- package/registry/examples/date-picker/native/calendar.light.png +0 -0
- package/registry/examples/date-picker/native/day-strip.dark.png +0 -0
- package/registry/examples/date-picker/native/day-strip.light.png +0 -0
- package/registry/examples/date-picker/native/month-year.dark.png +0 -0
- package/registry/examples/date-picker/native/month-year.light.png +0 -0
- package/registry/examples/date-picker/native/time-slots.dark.png +0 -0
- package/registry/examples/date-picker/native/time-slots.light.png +0 -0
- package/registry/examples/date-picker/native/time-wheel.dark.png +0 -0
- package/registry/examples/date-picker/native/time-wheel.light.png +0 -0
- package/registry/examples/description-list/native/job-details.dark.png +0 -0
- package/registry/examples/description-list/native/job-details.light.png +0 -0
- package/registry/examples/dialog/native/sheet.dark.png +0 -0
- package/registry/examples/dialog/native/sheet.light.png +0 -0
- package/registry/examples/empty-state/native/default.dark.png +0 -0
- package/registry/examples/empty-state/native/default.light.png +0 -0
- package/registry/examples/fab/native/extended.dark.png +0 -0
- package/registry/examples/fab/native/extended.light.png +0 -0
- package/registry/examples/field/native/default.dark.png +0 -0
- package/registry/examples/field/native/default.light.png +0 -0
- package/registry/examples/field/native/select.dark.png +0 -0
- package/registry/examples/field/native/select.light.png +0 -0
- package/registry/examples/footnote/notes.d.ts +4 -0
- package/registry/examples/footnote/notes.js +24 -0
- package/registry/examples/footnote/notes.tsx +19 -0
- package/registry/examples/force-update-screen/native/default.dark.png +0 -0
- package/registry/examples/force-update-screen/native/default.light.png +0 -0
- package/registry/examples/form/native/amount.dark.png +0 -0
- package/registry/examples/form/native/amount.light.png +0 -0
- package/registry/examples/form/native/audience.dark.png +0 -0
- package/registry/examples/form/native/audience.light.png +0 -0
- package/registry/examples/form/native/profile.dark.png +0 -0
- package/registry/examples/form/native/profile.light.png +0 -0
- package/registry/examples/form/native/settings.dark.png +0 -0
- package/registry/examples/form/native/settings.light.png +0 -0
- package/registry/examples/form/native/sign-up.dark.png +0 -0
- package/registry/examples/form/native/sign-up.light.png +0 -0
- package/registry/examples/form/native/upload.dark.png +0 -0
- package/registry/examples/form/native/upload.light.png +0 -0
- package/registry/examples/goal-gauge/native/default.dark.png +0 -0
- package/registry/examples/goal-gauge/native/default.light.png +0 -0
- package/registry/examples/header/native/large-title.dark.png +0 -0
- package/registry/examples/header/native/large-title.light.png +0 -0
- package/registry/examples/image-viewer/native/gallery.dark.png +0 -0
- package/registry/examples/image-viewer/native/gallery.light.png +0 -0
- package/registry/examples/list/native/default.dark.png +0 -0
- package/registry/examples/list/native/default.light.png +0 -0
- package/registry/examples/list/native/infinite.dark.png +0 -0
- package/registry/examples/list/native/infinite.light.png +0 -0
- package/registry/examples/list/native/states.dark.png +0 -0
- package/registry/examples/list/native/states.light.png +0 -0
- package/registry/examples/loader/native/block.dark.png +0 -0
- package/registry/examples/loader/native/block.light.png +0 -0
- package/registry/examples/loader/native/branded.dark.png +0 -0
- package/registry/examples/loader/native/branded.light.png +0 -0
- package/registry/examples/loader/native/job-wait.dark.png +0 -0
- package/registry/examples/loader/native/job-wait.light.png +0 -0
- package/registry/examples/maintenance-screen/native/default.dark.png +0 -0
- package/registry/examples/maintenance-screen/native/default.light.png +0 -0
- package/registry/examples/map/native/location-picker.dark.png +0 -0
- package/registry/examples/map/native/location-picker.light.png +0 -0
- package/registry/examples/map/native/places.dark.png +0 -0
- package/registry/examples/map/native/places.light.png +0 -0
- package/registry/examples/markdown/native/ai-stream.dark.png +0 -0
- package/registry/examples/markdown/native/ai-stream.light.png +0 -0
- package/registry/examples/markdown/native/basic.dark.png +0 -0
- package/registry/examples/markdown/native/basic.light.png +0 -0
- package/registry/examples/mascot-state/native/default.dark.png +0 -0
- package/registry/examples/mascot-state/native/default.light.png +0 -0
- package/registry/examples/mascots/native/crane.dark.png +0 -0
- package/registry/examples/mascots/native/crane.light.png +0 -0
- package/registry/examples/mascots/native/default.dark.png +0 -0
- package/registry/examples/mascots/native/default.light.png +0 -0
- package/registry/examples/mascots/native/lovebird.dark.png +0 -0
- package/registry/examples/mascots/native/lovebird.light.png +0 -0
- package/registry/examples/mascots/native/phoenix.dark.png +0 -0
- package/registry/examples/mascots/native/phoenix.light.png +0 -0
- package/registry/examples/match-dialog/native/its-a-match.dark.png +0 -0
- package/registry/examples/match-dialog/native/its-a-match.light.png +0 -0
- package/registry/examples/media-capture/native/photo.dark.png +0 -0
- package/registry/examples/media-capture/native/photo.light.png +0 -0
- package/registry/examples/media-picker/native/story.dark.png +0 -0
- package/registry/examples/media-picker/native/story.light.png +0 -0
- package/registry/examples/meta-row/native/video.dark.png +0 -0
- package/registry/examples/meta-row/native/video.light.png +0 -0
- package/registry/examples/meter/native/credits.dark.png +0 -0
- package/registry/examples/meter/native/credits.light.png +0 -0
- package/registry/examples/meter/native/split-ring.dark.png +0 -0
- package/registry/examples/meter/native/split-ring.light.png +0 -0
- package/registry/examples/number-ticker/native/balance.dark.png +0 -0
- package/registry/examples/number-ticker/native/balance.light.png +0 -0
- package/registry/examples/onboarding/native/first-launch.dark.png +0 -0
- package/registry/examples/onboarding/native/first-launch.light.png +0 -0
- package/registry/examples/otp-input/native/invalid.dark.png +0 -0
- package/registry/examples/otp-input/native/invalid.light.png +0 -0
- package/registry/examples/otp-input/native/verify.dark.png +0 -0
- package/registry/examples/otp-input/native/verify.light.png +0 -0
- package/registry/examples/page-index/docs.d.ts +4 -0
- package/registry/examples/page-index/docs.js +33 -0
- package/registry/examples/page-index/docs.tsx +27 -0
- package/registry/examples/pagination/native/cursor.dark.png +0 -0
- package/registry/examples/pagination/native/cursor.light.png +0 -0
- package/registry/examples/pagination/native/pages.dark.png +0 -0
- package/registry/examples/pagination/native/pages.light.png +0 -0
- package/registry/examples/permission-prompt/native/blocked.dark.png +0 -0
- package/registry/examples/permission-prompt/native/blocked.light.png +0 -0
- package/registry/examples/permission-prompt/native/camera.dark.png +0 -0
- package/registry/examples/permission-prompt/native/camera.light.png +0 -0
- package/registry/examples/photo-grid/native/profile-photos.dark.png +0 -0
- package/registry/examples/photo-grid/native/profile-photos.light.png +0 -0
- package/registry/examples/profile-card/native/default.dark.png +0 -0
- package/registry/examples/profile-card/native/default.light.png +0 -0
- package/registry/examples/progress/native/bar.dark.png +0 -0
- package/registry/examples/progress/native/bar.light.png +0 -0
- package/registry/examples/progress/native/indeterminate.dark.png +0 -0
- package/registry/examples/progress/native/indeterminate.light.png +0 -0
- package/registry/examples/progress/native/ring.dark.png +0 -0
- package/registry/examples/progress/native/ring.light.png +0 -0
- package/registry/examples/pull-to-refresh/native/branded.dark.png +0 -0
- package/registry/examples/pull-to-refresh/native/branded.light.png +0 -0
- package/registry/examples/pull-to-refresh/native/feed.dark.png +0 -0
- package/registry/examples/pull-to-refresh/native/feed.light.png +0 -0
- package/registry/examples/radio-group/native/buttons.dark.png +0 -0
- package/registry/examples/radio-group/native/buttons.light.png +0 -0
- package/registry/examples/radio-group/native/cards.dark.png +0 -0
- package/registry/examples/radio-group/native/cards.light.png +0 -0
- package/registry/examples/radio-group/native/list.dark.png +0 -0
- package/registry/examples/radio-group/native/list.light.png +0 -0
- package/registry/examples/radio-group/native/segmented.dark.png +0 -0
- package/registry/examples/radio-group/native/segmented.light.png +0 -0
- package/registry/examples/screen/native/app-shell.dark.png +0 -0
- package/registry/examples/screen/native/app-shell.light.png +0 -0
- package/registry/examples/screen/native/auth.dark.png +0 -0
- package/registry/examples/screen/native/auth.light.png +0 -0
- package/registry/examples/screen/native/chat.dark.png +0 -0
- package/registry/examples/screen/native/chat.light.png +0 -0
- package/registry/examples/screen/native/feed.dark.png +0 -0
- package/registry/examples/screen/native/feed.light.png +0 -0
- package/registry/examples/screen/native/map.dark.png +0 -0
- package/registry/examples/screen/native/map.light.png +0 -0
- package/registry/examples/screen/native/notifications.dark.png +0 -0
- package/registry/examples/screen/native/notifications.light.png +0 -0
- package/registry/examples/screen/native/profile.dark.png +0 -0
- package/registry/examples/screen/native/profile.light.png +0 -0
- package/registry/examples/screen/native/settings.dark.png +0 -0
- package/registry/examples/screen/native/settings.light.png +0 -0
- package/registry/examples/search-field/native/cancel.dark.png +0 -0
- package/registry/examples/search-field/native/cancel.light.png +0 -0
- package/registry/examples/search-field/native/default.dark.png +0 -0
- package/registry/examples/search-field/native/default.light.png +0 -0
- package/registry/examples/segmented/native/default.dark.png +0 -0
- package/registry/examples/segmented/native/default.light.png +0 -0
- package/registry/examples/segmented/native/small.dark.png +0 -0
- package/registry/examples/segmented/native/small.light.png +0 -0
- package/registry/examples/settings-layout/native/account.dark.png +0 -0
- package/registry/examples/settings-layout/native/account.light.png +0 -0
- package/registry/examples/showcase/native/slides.dark.png +0 -0
- package/registry/examples/showcase/native/slides.light.png +0 -0
- package/registry/examples/skeleton/native/shapes.dark.png +0 -0
- package/registry/examples/skeleton/native/shapes.light.png +0 -0
- package/registry/examples/slider/native/default.dark.png +0 -0
- package/registry/examples/slider/native/default.light.png +0 -0
- package/registry/examples/slider/native/range.dark.png +0 -0
- package/registry/examples/slider/native/range.light.png +0 -0
- package/registry/examples/slider/native/stepped.dark.png +0 -0
- package/registry/examples/slider/native/stepped.light.png +0 -0
- package/registry/examples/slider/native/vertical.dark.png +0 -0
- package/registry/examples/slider/native/vertical.light.png +0 -0
- package/registry/examples/specimen-tag/product.d.ts +4 -0
- package/registry/examples/specimen-tag/product.js +28 -0
- package/registry/examples/specimen-tag/product.tsx +25 -0
- package/registry/examples/specimen-tag/stamps.d.ts +4 -0
- package/registry/examples/specimen-tag/stamps.js +16 -0
- package/registry/examples/specimen-tag/stamps.tsx +13 -0
- package/registry/examples/specimen-tag/wire.d.ts +4 -0
- package/registry/examples/specimen-tag/wire.js +16 -0
- package/registry/examples/specimen-tag/wire.tsx +20 -0
- package/registry/examples/spinner/native/sizes.dark.png +0 -0
- package/registry/examples/spinner/native/sizes.light.png +0 -0
- package/registry/examples/splash-handoff/native/default.dark.png +0 -0
- package/registry/examples/splash-handoff/native/default.light.png +0 -0
- package/registry/examples/step-progress/native/sign-up.dark.png +0 -0
- package/registry/examples/step-progress/native/sign-up.light.png +0 -0
- package/registry/examples/stepper/native/run.dark.png +0 -0
- package/registry/examples/stepper/native/run.light.png +0 -0
- package/registry/examples/swipe-deck/native/discover.dark.png +0 -0
- package/registry/examples/swipe-deck/native/discover.light.png +0 -0
- package/registry/examples/swipeable-row/native/conversation.dark.png +0 -0
- package/registry/examples/swipeable-row/native/conversation.light.png +0 -0
- package/registry/examples/switch/native/default.dark.png +0 -0
- package/registry/examples/switch/native/default.light.png +0 -0
- package/registry/examples/switch/native/settings.dark.png +0 -0
- package/registry/examples/switch/native/settings.light.png +0 -0
- package/registry/examples/tab-bar/native/main-sections.dark.png +0 -0
- package/registry/examples/tab-bar/native/main-sections.light.png +0 -0
- package/registry/examples/tabs/native/sections.dark.png +0 -0
- package/registry/examples/tabs/native/sections.light.png +0 -0
- package/registry/examples/tabs/native/segmented.dark.png +0 -0
- package/registry/examples/tabs/native/segmented.light.png +0 -0
- package/registry/examples/tag-selector/native/interests.dark.png +0 -0
- package/registry/examples/tag-selector/native/interests.light.png +0 -0
- package/registry/examples/toast/native/notification.dark.png +0 -0
- package/registry/examples/toast/native/notification.light.png +0 -0
- package/registry/examples/toast/native/snackbar.dark.png +0 -0
- package/registry/examples/toast/native/snackbar.light.png +0 -0
- package/registry/examples/toast/native/tones.dark.png +0 -0
- package/registry/examples/toast/native/tones.light.png +0 -0
- package/registry/examples/txt/native/tones.dark.png +0 -0
- package/registry/examples/txt/native/tones.light.png +0 -0
- package/registry/examples/txt/native/variants.dark.png +0 -0
- package/registry/examples/txt/native/variants.light.png +0 -0
- package/registry/examples/update-prompt/native/default.dark.png +0 -0
- package/registry/examples/update-prompt/native/default.light.png +0 -0
- package/registry/examples/verified-badge/native/verified.dark.png +0 -0
- package/registry/examples/verified-badge/native/verified.light.png +0 -0
- package/registry/examples/vertical-video/native/rail.dark.png +0 -0
- package/registry/examples/vertical-video/native/rail.light.png +0 -0
- package/registry/examples/video-player/native/default.dark.png +0 -0
- package/registry/examples/video-player/native/default.light.png +0 -0
- package/registry/examples/waveform/native/card.dark.png +0 -0
- package/registry/examples/waveform/native/card.light.png +0 -0
- package/registry/field.json +1 -1
- package/registry/file-upload.json +1 -1
- package/registry/filter-bar.json +1 -1
- package/registry/footnote.json +220 -0
- package/registry/force-update-screen.json +1 -1
- package/registry/form.json +3 -3
- package/registry/gallery-page.json +1 -1
- package/registry/genui.json +1 -1
- package/registry/glow-card.json +1 -1
- package/registry/goal-gauge.json +1 -1
- package/registry/how-it-works-page.json +1 -1
- package/registry/image-cropper.json +1 -1
- package/registry/index.json +160 -5
- package/registry/iso.json +1 -1
- package/registry/kanban.json +1 -1
- package/registry/kbd.json +1 -1
- package/registry/landing-page.json +1 -1
- package/registry/landscape.json +1 -1
- package/registry/language-switch.json +2 -2
- package/registry/legal-page.json +1 -1
- package/registry/link-card.json +1 -1
- package/registry/list.json +1 -1
- package/registry/loader.json +2 -2
- package/registry/longform-page.json +1 -1
- package/registry/maintenance-screen.json +1 -1
- package/registry/map.json +3 -3
- package/registry/markdown.json +1 -1
- 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 +1 -1
- package/registry/mascots.json +1 -1
- package/registry/match-dialog.json +1 -1
- package/registry/media-capture.json +1 -1
- package/registry/media-gallery.json +1 -1
- package/registry/media-grid.json +1 -1
- package/registry/meta-row.json +1 -1
- package/registry/meter.json +2 -2
- package/registry/nav-bar.json +3 -3
- package/registry/number-ticker.json +1 -1
- package/registry/opening-hours.json +1 -1
- package/registry/page-header.json +1 -1
- package/registry/page-hero.json +1 -1
- package/registry/page-index.json +168 -0
- package/registry/page.json +89 -5
- package/registry/pagination.json +1 -1
- package/registry/photo-grid.json +2 -2
- package/registry/pointer-light.json +1 -1
- package/registry/popover.json +1 -1
- package/registry/pricing-page.json +1 -1
- package/registry/product-page.json +1 -1
- package/registry/profile-card.json +1 -1
- package/registry/progress.json +1 -1
- package/registry/promise-card.json +1 -1
- package/registry/radio-group.json +2 -2
- package/registry/rail-nav.json +3 -3
- package/registry/recipes.json +1 -1
- package/registry/scroll-stage.json +1 -1
- package/registry/search-field.json +2 -2
- package/registry/section-backdrop.json +1 -1
- package/registry/separator.json +1 -1
- package/registry/service-card.json +2 -2
- package/registry/settings-layout.json +1 -1
- package/registry/showcase.json +1 -1
- package/registry/site-footer.json +3 -3
- package/registry/sites.json +2 -2
- package/registry/skeleton.json +1 -1
- package/registry/skip-link.json +1 -1
- package/registry/slider.json +1 -1
- package/registry/slot-picker.json +1 -1
- package/registry/slot.json +1 -1
- package/registry/specimen-tag.json +269 -0
- package/registry/spinner.json +1 -1
- package/registry/split-view.json +1 -1
- package/registry/stage-banner.json +1 -1
- package/registry/stat.json +2 -2
- package/registry/status-page.json +1 -1
- package/registry/step-progress.json +1 -1
- package/registry/step-showcase.json +1 -1
- package/registry/stepper.json +1 -1
- package/registry/sticky-action.json +2 -2
- package/registry/swipe-deck.json +2 -2
- package/registry/switch.json +1 -1
- package/registry/tabs.json +1 -1
- package/registry/tag-input.json +1 -1
- package/registry/tag-selector.json +1 -1
- package/registry/terminal-replay.json +1 -1
- package/registry/theme.json +1 -1
- package/registry/toast.json +1 -1
- package/registry/toc.json +1 -1
- package/registry/tooltip.json +1 -1
- package/registry/tree-view.json +1 -1
- package/registry/update-prompt.json +1 -1
- package/registry/verified-badge.json +1 -1
- package/registry/vertical-video.json +1 -1
- package/registry/video-player.json +1 -1
- package/registry/video-trimmer.json +1 -1
- package/registry/virtual.json +1 -1
- package/registry/waveform.json +1 -1
- package/dist/chunk-2AJ4NJUF.js.map +0 -1
- package/dist/chunk-2PNLHZLT.js.map +0 -1
- package/dist/chunk-3S4GHSPZ.js.map +0 -1
- package/dist/chunk-LZNZLCOE.js.map +0 -1
- package/dist/chunk-NJFCSVPT.js.map +0 -1
- package/dist/chunk-REPTKUJ6.js.map +0 -1
- /package/dist/{chunk-KIBICUZK.js.map → chunk-K2ZYB4HP.js.map} +0 -0
package/dist/mascot-quote.d.ts
CHANGED
|
@@ -1,25 +1,6 @@
|
|
|
1
|
+
import { M as MascotBird, a as MascotMood } from './geometry-DncHaYP8.js';
|
|
1
2
|
import * as React from 'react';
|
|
2
3
|
|
|
3
|
-
/**
|
|
4
|
-
* The Krizaka flock — the geometry of the mascots, drawn by the web `Mascot` (`./mascot.tsx`) and the native one
|
|
5
|
-
* (`../native/mascots.tsx`). Five birds that have carried the Krizaka story since the first site (the sentry falcon,
|
|
6
|
-
* the owl that reads, the developer duck, the flamingo that answers, the carrier pigeon), the lovebird that
|
|
7
|
-
* introduces (2026-10, with Yasakia: "l'inséparable présente") and the crane that listens (2026-10, with Yororis:
|
|
8
|
-
* "la grue écoute"), the magpie that keeps the score (2026-10, with Kachizaka: "la pie compte les points") and the
|
|
9
|
-
* beaver that builds the shop (2026-10, with Akinaza: "le castor artisan" — the one figure of the flock without
|
|
10
|
-
* feathers: its paws are drawn as wings, its paddle tail behind it), redrawn on one 120 × 120 grid so that any figure
|
|
11
|
-
* can wear any mood.
|
|
12
|
-
*
|
|
13
|
-
* Colours are roles, never fixed: `brand` (the default) paints a bird in the host's accent (`--kz-accent`,
|
|
14
|
-
* `--kz-accent-2`), so the same falcon is blue on krizaka.com, orange in Orazaka and violet in Orochia; `own` gives
|
|
15
|
-
* each bird the signature palette it has in the Krizaka story (the brand layer's exception, like the marks). Shades
|
|
16
|
-
* and highlights are black and white at a low opacity over the role, so they hold in both themes.
|
|
17
|
-
*/
|
|
18
|
-
declare const MASCOT_BIRDS: readonly ["falcon", "owl", "duck", "flamingo", "pigeon", "lovebird", "crane", "magpie", "beaver"];
|
|
19
|
-
type MascotBird = (typeof MASCOT_BIRDS)[number];
|
|
20
|
-
declare const MASCOT_MOODS: readonly ["welcome", "thinking", "success", "empty", "error"];
|
|
21
|
-
type MascotMood = (typeof MASCOT_MOODS)[number];
|
|
22
|
-
|
|
23
4
|
type MascotQuoteProps = Omit<React.HTMLAttributes<HTMLElement>, "children"> & {
|
|
24
5
|
/** The bird that speaks — the one whose idea it is. */
|
|
25
6
|
bird: MascotBird;
|
|
@@ -43,4 +24,4 @@ type MascotQuoteProps = Omit<React.HTMLAttributes<HTMLElement>, "children"> & {
|
|
|
43
24
|
/** A sentence told by a bird: a speech bubble, the bird under its tail, who speaks. The bird is decorative. */
|
|
44
25
|
declare function MascotQuote({ bird, mood, label, children, variant, animated, className, ...props }: MascotQuoteProps): React.JSX.Element;
|
|
45
26
|
|
|
46
|
-
export {
|
|
27
|
+
export { MascotBird, MascotMood, MascotQuote, type MascotQuoteProps };
|
package/dist/mascot-quote.js
CHANGED
|
@@ -1,349 +1,20 @@
|
|
|
1
1
|
"use client";
|
|
2
|
+
import {
|
|
3
|
+
Mascot
|
|
4
|
+
} from "./chunk-JFJECOZ2.js";
|
|
2
5
|
import {
|
|
3
6
|
cn
|
|
4
7
|
} from "./chunk-WU4VLSEA.js";
|
|
5
8
|
|
|
6
|
-
// src/mascots/mascot.tsx
|
|
7
|
-
import { useId } from "react";
|
|
8
|
-
|
|
9
|
-
// src/mascots/geometry.ts
|
|
10
|
-
var mirror = (d) => d.replace(/(-?\d+(?:\.\d+)?) (-?\d+(?:\.\d+)?)/g, (_, x, y) => `${120 - Number(x)} ${y}`);
|
|
11
|
-
var falconWing = "M29 58 C17 68 19 88 37 86 C31 76 31 66 29 58 Z";
|
|
12
|
-
var pigeonWing = "M36 58 C20 50 16 80 38 84 C34 74 34 66 36 58 Z";
|
|
13
|
-
var BIRDS = {
|
|
14
|
-
falcon: {
|
|
15
|
-
shadow: [60, 110, 26, 3.5],
|
|
16
|
-
legs: ["M51 94 L48 108 M44 108 L52 108", "M69 94 L72 108 M68 108 L76 108"],
|
|
17
|
-
body: "M30 62 C30 42 90 42 90 62 C90 88 78 98 60 98 C42 98 30 88 30 62 Z",
|
|
18
|
-
belly: "M41 66 C41 55 79 55 79 66 C79 82 71 90 60 90 C49 90 41 82 41 66 Z",
|
|
19
|
-
wings: [
|
|
20
|
-
{ d: falconWing, pivot: [29, 58] },
|
|
21
|
-
{ d: mirror(falconWing), pivot: [91, 58] }
|
|
22
|
-
],
|
|
23
|
-
head: { cx: 60, cy: 38, r: 22 },
|
|
24
|
-
details: ["M46 20 L52 10 L56 19 Z", "M74 20 L68 10 L64 19 Z"],
|
|
25
|
-
visor: { x: 41, y: 29, w: 38, h: 13 },
|
|
26
|
-
beak: "M54 45 L66 45 L60 57 Z",
|
|
27
|
-
eyes: { at: [[50, 35.5], [70, 35.5]], white: 0, pupil: 3.2 }
|
|
28
|
-
},
|
|
29
|
-
owl: {
|
|
30
|
-
shadow: [60, 110, 24, 3.5],
|
|
31
|
-
legs: ["M53 100 L51 107 M47 107 L55 107", "M67 100 L69 107 M65 107 L73 107"],
|
|
32
|
-
body: "M28 52 C28 20 92 20 92 52 C92 86 82 102 60 102 C38 102 28 86 28 52 Z",
|
|
33
|
-
belly: "M42 66 C42 52 78 52 78 66 C78 86 72 94 60 94 C48 94 42 86 42 66 Z",
|
|
34
|
-
wings: [
|
|
35
|
-
{ d: "M29 58 C18 68 20 88 36 90 C32 78 32 68 29 58 Z", pivot: [29, 58] },
|
|
36
|
-
{ d: mirror("M29 58 C18 68 20 88 36 90 C32 78 32 68 29 58 Z"), pivot: [91, 58] }
|
|
37
|
-
],
|
|
38
|
-
head: { cx: 60, cy: 42, r: 0 },
|
|
39
|
-
details: ["M31 20 L47 31 L31 41 Z", "M89 20 L73 31 L89 41 Z"],
|
|
40
|
-
beak: "M55 50 L65 50 L60 59 Z",
|
|
41
|
-
eyes: { at: [[47, 41], [73, 41]], white: 10, pupil: 4 }
|
|
42
|
-
},
|
|
43
|
-
duck: {
|
|
44
|
-
shadow: [60, 110, 30, 3.5],
|
|
45
|
-
legs: [],
|
|
46
|
-
back: ["M88 80 C100 76 104 66 96 62 C98 70 94 74 88 74 Z"],
|
|
47
|
-
body: "M26 80 C26 62 94 62 94 80 C94 100 82 106 60 106 C38 106 26 100 26 80 Z",
|
|
48
|
-
belly: "M38 84 C38 72 82 72 82 84 C82 96 74 101 60 101 C46 101 38 96 38 84 Z",
|
|
49
|
-
wings: [
|
|
50
|
-
{ d: "M27 74 C14 80 18 98 35 96 C31 88 29 80 27 74 Z", pivot: [27, 74] },
|
|
51
|
-
{ d: mirror("M27 74 C14 80 18 98 35 96 C31 88 29 80 27 74 Z"), pivot: [93, 74] }
|
|
52
|
-
],
|
|
53
|
-
head: { cx: 60, cy: 42, r: 23 },
|
|
54
|
-
details: ["M57 20 C54 11 63 8 66 14 C62 13 60 16 61 20 Z"],
|
|
55
|
-
glasses: true,
|
|
56
|
-
beak: "M43 51 C43 46 55 45 60 45 C65 45 77 46 77 51 C77 56 66 60 60 60 C54 60 43 56 43 51 Z",
|
|
57
|
-
eyes: { at: [[51, 37], [69, 37]], white: 0, pupil: 2.6 }
|
|
58
|
-
},
|
|
59
|
-
flamingo: {
|
|
60
|
-
shadow: [60, 110, 20, 3],
|
|
61
|
-
legs: ["M56 86 L55 97 L58 108 M53 108 L62 108", "M65 86 L66 108 M62 108 L71 108"],
|
|
62
|
-
body: "M38 70 C38 54 88 54 88 70 C88 86 76 90 62 90 C48 90 38 86 38 70 Z",
|
|
63
|
-
belly: "M46 72 C46 63 80 63 80 72 C80 82 72 85 63 85 C54 85 46 82 46 72 Z",
|
|
64
|
-
wings: [
|
|
65
|
-
{ d: "M42 64 C30 68 32 84 47 84 C43 76 43 70 42 64 Z", pivot: [42, 64] },
|
|
66
|
-
{ d: "M84 64 C96 68 94 84 79 84 C83 76 83 70 84 64 Z", pivot: [84, 64] }
|
|
67
|
-
],
|
|
68
|
-
neck: { d: "M58 60 C58 42 40 34 46 22", width: 7 },
|
|
69
|
-
head: { cx: 48, cy: 18, r: 11 },
|
|
70
|
-
details: [],
|
|
71
|
-
beak: "M38 16 C28 18 29 28 24 33 C33 28 38 23 40 20 Z",
|
|
72
|
-
eyes: { at: [[46, 15]], white: 3.2, pupil: 1.8 }
|
|
73
|
-
},
|
|
74
|
-
pigeon: {
|
|
75
|
-
shadow: [60, 112, 22, 3],
|
|
76
|
-
legs: ["M52 94 L51 99 M48 99 L54 99", "M68 94 L69 99 M66 99 L72 99"],
|
|
77
|
-
back: ["M53 98 L52 103", "M67 98 L68 103", "M30 68 C16 72 14 62 28 56 C17 57 15 49 32 48 Z"],
|
|
78
|
-
body: "M34 64 C34 44 86 44 86 64 C86 86 74 96 60 96 C46 96 34 86 34 64 Z",
|
|
79
|
-
belly: "M43 68 C43 57 77 57 77 68 C77 82 70 88 60 88 C50 88 43 82 43 68 Z",
|
|
80
|
-
wings: [
|
|
81
|
-
{ d: pigeonWing, pivot: [36, 58] },
|
|
82
|
-
{ d: mirror(pigeonWing), pivot: [84, 58] }
|
|
83
|
-
],
|
|
84
|
-
head: { cx: 60, cy: 36, r: 19 },
|
|
85
|
-
details: ["M54 18 C56 12 64 12 66 18 C63 16 57 16 54 18 Z"],
|
|
86
|
-
beak: "M55 41 L65 41 L60 50 Z",
|
|
87
|
-
eyes: { at: [[52, 33], [68, 33]], white: 5, pupil: 2.4 },
|
|
88
|
-
parcel: ["M60 100 L71 105 L60 110 L49 105 Z", "M49 105 L60 110 L60 118 L49 113 Z", "M71 105 L60 110 L60 118 L71 113 Z"]
|
|
89
|
-
},
|
|
90
|
-
/**
|
|
91
|
-
* The lovebird — the inseparable that introduces two people. A plump little parrot: a short tail, a round head
|
|
92
|
-
* with its coloured face (the detail colour), the white eye-rings of the species and a short hooked beak.
|
|
93
|
-
*/
|
|
94
|
-
lovebird: {
|
|
95
|
-
shadow: [60, 110, 23, 3.5],
|
|
96
|
-
legs: ["M53 96 L52 106 M48 106 L56 106", "M67 96 L68 106 M64 106 L72 106"],
|
|
97
|
-
back: ["M74 90 C82 98 88 104 95 103 C91 98 86 91 82 84 Z"],
|
|
98
|
-
body: "M32 66 C32 46 88 46 88 66 C88 90 76 100 60 100 C44 100 32 90 32 66 Z",
|
|
99
|
-
belly: "M42 70 C42 59 78 59 78 70 C78 85 70 92 60 92 C50 92 42 85 42 70 Z",
|
|
100
|
-
wings: [
|
|
101
|
-
{ d: "M33 60 C20 68 22 88 40 90 C35 80 34 70 33 60 Z", pivot: [33, 60] },
|
|
102
|
-
{ d: mirror("M33 60 C20 68 22 88 40 90 C35 80 34 70 33 60 Z"), pivot: [87, 60] }
|
|
103
|
-
],
|
|
104
|
-
head: { cx: 60, cy: 38, r: 21 },
|
|
105
|
-
details: ["M43 40 C42 28 51 22 60 22 C69 22 78 28 77 40 C76 50 68 55 60 55 C52 55 44 50 43 40 Z"],
|
|
106
|
-
beak: "M55 44 C55 40 65 40 65 44 C65 50 62 54 60 55 C58 54 55 50 55 44 Z",
|
|
107
|
-
eyes: { at: [[51, 36], [69, 36]], white: 4.6, pupil: 2.4 }
|
|
108
|
-
},
|
|
109
|
-
/**
|
|
110
|
-
* The crane — the one that listens: posed, unhurried, drawn in one line. A tall wader seen in profile, standing still
|
|
111
|
-
* on two straight legs, the neck a single stroke up to a small head with its crown (the detail colour) and a long,
|
|
112
|
-
* straight beak; the folded wings low on its back. The flamingo bends and answers; the crane stands and listens.
|
|
113
|
-
*/
|
|
114
|
-
crane: {
|
|
115
|
-
shadow: [62, 110, 20, 3],
|
|
116
|
-
legs: ["M56 87 L55 108 M51 108 L59 108", "M67 87 L68 108 M64 108 L73 108"],
|
|
117
|
-
body: "M40 66 C38 54 84 54 86 68 C88 82 76 88 62 88 C48 88 40 80 40 66 Z",
|
|
118
|
-
belly: "M48 70 C48 62 78 62 79 70 C80 79 72 84 63 84 C54 84 48 79 48 70 Z",
|
|
119
|
-
wings: [
|
|
120
|
-
{ d: "M44 62 C33 68 35 82 49 83 C45 76 45 69 44 62 Z", pivot: [44, 62] },
|
|
121
|
-
{ d: "M82 62 C93 67 96 82 80 84 C83 76 83 69 82 62 Z", pivot: [82, 62] }
|
|
122
|
-
],
|
|
123
|
-
neck: { d: "M52 62 C48 47 52 37 48 26", width: 6 },
|
|
124
|
-
head: { cx: 47, cy: 21, r: 8.5 },
|
|
125
|
-
details: ["M41 16.5 C42 11 52 11 53 16.5 C50 14.6 44 14.6 41 16.5 Z"],
|
|
126
|
-
beak: "M40.5 18.5 L19 22.5 L40.5 25.5 Z",
|
|
127
|
-
eyes: { at: [[45.5, 19.5]], white: 2.8, pupil: 1.6 }
|
|
128
|
-
},
|
|
129
|
-
/**
|
|
130
|
-
* The magpie — the one that keeps the score: it counts the points, remembers every trophy and chatters with the
|
|
131
|
-
* league. A sleek pied bird: a dark cap (the detail colour) over a round head, a white belly, a long tail behind it
|
|
132
|
-
* (the detail colour), a short straight beak. It watches no one (that is the falcon): it counts.
|
|
133
|
-
*/
|
|
134
|
-
magpie: {
|
|
135
|
-
shadow: [58, 110, 24, 3.5],
|
|
136
|
-
legs: ["M53 95 L51 107 M47 107 L55 107", "M65 95 L67 107 M63 107 L71 107"],
|
|
137
|
-
back: ["M72 88 C84 94 96 102 106 108 C104 111 100 112 97 110 C88 104 78 98 68 94 Z"],
|
|
138
|
-
body: "M34 64 C34 44 84 44 84 64 C84 88 72 98 58 98 C44 98 34 88 34 64 Z",
|
|
139
|
-
belly: "M43 70 C43 60 73 60 73 70 C73 84 67 90 58 90 C49 90 43 84 43 70 Z",
|
|
140
|
-
wings: [
|
|
141
|
-
{ d: "M35 58 C22 64 22 84 40 88 C36 78 35 68 35 58 Z", pivot: [35, 58] },
|
|
142
|
-
{ d: "M83 58 C96 64 96 84 78 88 C82 78 83 68 83 58 Z", pivot: [83, 58] }
|
|
143
|
-
],
|
|
144
|
-
head: { cx: 58, cy: 36, r: 19 },
|
|
145
|
-
details: ["M40 34 C40 22 48 16 58 16 C68 16 76 22 76 34 C70 29 64 28 58 28 C52 28 46 29 40 34 Z"],
|
|
146
|
-
beak: "M53 42 L63 42 L58 50 Z",
|
|
147
|
-
eyes: { at: [[50, 35], [66, 35]], white: 4.4, pupil: 2.3 }
|
|
148
|
-
},
|
|
149
|
-
/**
|
|
150
|
-
* The beaver — the artisan that builds the shop, Akinaza's figure (and Canada's). Round and sturdy, sitting up: two
|
|
151
|
-
* round ears and a nose (the detail colour), the two front teeth (the beak colour), small paws drawn as its wings,
|
|
152
|
-
* and its flat paddle tail lying behind it. No feathers, the same moods.
|
|
153
|
-
*/
|
|
154
|
-
beaver: {
|
|
155
|
-
shadow: [62, 110, 30, 3.5],
|
|
156
|
-
legs: ["M50 100 L48 106 M43 106 L53 106", "M70 100 L72 106 M67 106 L77 106"],
|
|
157
|
-
back: ["M74 94 C86 92 104 96 108 103 C106 110 90 111 76 104 Z"],
|
|
158
|
-
body: "M30 72 C30 48 90 48 90 72 C90 96 78 104 60 104 C42 104 30 96 30 72 Z",
|
|
159
|
-
belly: "M42 76 C42 64 78 64 78 76 C78 92 70 98 60 98 C50 98 42 92 42 76 Z",
|
|
160
|
-
wings: [
|
|
161
|
-
{ d: "M38 66 C28 70 30 84 42 84 C44 78 42 72 38 66 Z", pivot: [38, 66] },
|
|
162
|
-
{ d: "M82 66 C92 70 90 84 78 84 C76 78 78 72 82 66 Z", pivot: [82, 66] }
|
|
163
|
-
],
|
|
164
|
-
head: { cx: 60, cy: 40, r: 22 },
|
|
165
|
-
details: ["M37 30 C33 23 39 16 46 20 C43 23 40 26 37 30 Z", "M83 30 C87 23 81 16 74 20 C77 23 80 26 83 30 Z", "M55 45 C55 42 65 42 65 45 C65 48 62 49 60 49 C58 49 55 48 55 45 Z"],
|
|
166
|
-
beak: "M56 51 H64 V58 C64 59.5 63 60 62 60 H58 C57 60 56 59.5 56 58 Z",
|
|
167
|
-
eyes: { at: [[51, 36], [69, 36]], white: 4.6, pupil: 2.4 }
|
|
168
|
-
}
|
|
169
|
-
};
|
|
170
|
-
var MOOD_PARTS = {
|
|
171
|
-
/** The badge of `success` and `error`, top right. */
|
|
172
|
-
badge: { cx: 98, cy: 22, r: 11 },
|
|
173
|
-
check: "M92.5 22.5 L96.8 26.6 L103.6 18.4",
|
|
174
|
-
bang: { line: "M98 15.5 L98 23.5", dot: [98, 28] },
|
|
175
|
-
/** `thinking`: three dots rising to the right of the head. */
|
|
176
|
-
dots: [
|
|
177
|
-
[88, 26, 2.6],
|
|
178
|
-
[96, 19, 3.2],
|
|
179
|
-
[105, 11, 3.8]
|
|
180
|
-
],
|
|
181
|
-
/** `empty`: an open tray beside the bird. */
|
|
182
|
-
tray: "M90 96 L110 96 L107 108 L93 108 Z",
|
|
183
|
-
/** `success`: two sparkles. */
|
|
184
|
-
sparkles: ["M16 26 L18 31 L23 33 L18 35 L16 40 L14 35 L9 33 L14 31 Z", "M104 52 L105.2 55 L108 56 L105.2 57 L104 60 L102.8 57 L100 56 L102.8 55 Z"]
|
|
185
|
-
};
|
|
186
|
-
var archEye = ([x, y], r) => `M${x - r} ${y + r * 0.45} Q${x} ${y - r * 1.15} ${x + r} ${y + r * 0.45}`;
|
|
187
|
-
var lidEye = ([x, y], r) => `M${x - r} ${y + 0.4} L${x + r} ${y + 0.4}`;
|
|
188
|
-
var upperLid = ([x, y], r) => `M${x - r} ${y} A${r} ${r} 0 0 1 ${x + r} ${y} Z`;
|
|
189
|
-
var brow = ([x, y], r, side) => `M${x - r * 1.1} ${y - r * 1.25 - (side < 0 ? 0 : r * 0.7)} L${x + r * 1.1} ${y - r * 1.5 - (side < 0 ? r * 0.7 : 0)}`;
|
|
190
|
-
var OWN_PALETTES = {
|
|
191
|
-
falcon: { from: "#ff9f00", to: "#ff2a00", wing: "#d84315", detail: "#b4320d", beak: "#ffb300", eye: "#00c8d4" },
|
|
192
|
-
owl: { from: "#a78bfa", to: "#6d28d9", wing: "#7c3aed", detail: "#5b21b6", beak: "#fbbf24", eye: "#1f2937" },
|
|
193
|
-
duck: { from: "#f43f5e", to: "#be123c", wing: "#db2777", detail: "#9f1239", beak: "#fbbf24", eye: "#1f2937" },
|
|
194
|
-
flamingo: { from: "#f9a8d4", to: "#db2777", wing: "#ec4899", detail: "#be185d", beak: "#fbbf24", eye: "#1f2937" },
|
|
195
|
-
pigeon: { from: "#22d3ee", to: "#6366f1", wing: "#a855f7", detail: "#4338ca", beak: "#f59e0b", eye: "#1f2937" },
|
|
196
|
-
lovebird: { from: "#6ee7b7", to: "#059669", wing: "#047857", detail: "#fb7185", beak: "#f97316", eye: "#1f2937" },
|
|
197
|
-
// The sandhill crane (grue du Canada): sand-grey plumage, its red crown, dark legs and beak.
|
|
198
|
-
crane: { from: "#ebe3d6", to: "#9c8f80", wing: "#7d7266", detail: "#dc2626", beak: "#44403c", eye: "#1f2937" },
|
|
199
|
-
// The Eurasian magpie (pie bavarde): slate and ink, the cobalt sheen of its wings, a dark beak.
|
|
200
|
-
magpie: { from: "#64748b", to: "#1e293b", wing: "#1d4ed8", detail: "#0f172a", beak: "#334155", eye: "#1f2937" },
|
|
201
|
-
// The North American beaver (castor du Canada): warm brown fur, a dark nose and tail, its orange front teeth.
|
|
202
|
-
beaver: { from: "#b07a4a", to: "#6b4226", wing: "#5c3a21", detail: "#3f2716", beak: "#f59e0b", eye: "#1f2937" }
|
|
203
|
-
};
|
|
204
|
-
var LIGHT = "#ffffff";
|
|
205
|
-
var SHADE = "#000000";
|
|
206
|
-
var PARCEL = ["#f59e0b", "#d97706", "#b45309"];
|
|
207
|
-
|
|
208
|
-
// src/mascots/mascot.tsx
|
|
209
|
-
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
210
|
-
var CSS = `
|
|
211
|
-
.kzb-bird { transform-box: view-box; transform-origin: 60px 108px; }
|
|
212
|
-
.kzb-eye { transform-box: fill-box; transform-origin: center; }
|
|
213
|
-
.kzb-wing { transform-box: view-box; }
|
|
214
|
-
[data-animated] .kzb-bird { animation: kzb-bob 3.6s ease-in-out infinite; }
|
|
215
|
-
[data-animated] .kzb-blink { animation: kzb-blink 5.2s ease-in-out infinite; }
|
|
216
|
-
[data-animated][data-mood="welcome"] .kzb-wing-r { animation: kzb-wave 1.1s ease-in-out infinite alternate; }
|
|
217
|
-
[data-animated][data-mood="thinking"] .kzb-dot { animation: kzb-dot 1.5s ease-in-out infinite; }
|
|
218
|
-
[data-animated][data-mood="thinking"] .kzb-dot:nth-child(2) { animation-delay: .2s; }
|
|
219
|
-
[data-animated][data-mood="thinking"] .kzb-dot:nth-child(3) { animation-delay: .4s; }
|
|
220
|
-
[data-animated][data-mood="success"] .kzb-bird { animation: kzb-hop 1.6s cubic-bezier(.3,1.6,.5,1) 1, kzb-bob 3.6s ease-in-out 1.6s infinite; }
|
|
221
|
-
[data-animated][data-mood="success"] .kzb-badge { animation: kzb-pop .5s cubic-bezier(.3,1.6,.5,1) .3s both; }
|
|
222
|
-
[data-animated][data-mood="success"] .kzb-sparkle { animation: kzb-twinkle 2.4s ease-in-out infinite; }
|
|
223
|
-
[data-animated][data-mood="error"] .kzb-bird { animation: kzb-shake .5s ease-in-out .2s 2, kzb-bob 3.6s ease-in-out 1.2s infinite; }
|
|
224
|
-
[data-animated][data-mood="empty"] .kzb-bird { animation: kzb-sway 5s ease-in-out infinite; }
|
|
225
|
-
.kzb-badge, .kzb-sparkle, .kzb-dot { transform-box: fill-box; transform-origin: center; }
|
|
226
|
-
@keyframes kzb-bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-2.5px); } }
|
|
227
|
-
@keyframes kzb-blink { 0%, 92%, 100% { transform: scaleY(1); } 95% { transform: scaleY(.1); } }
|
|
228
|
-
@keyframes kzb-wave { from { transform: rotate(-8deg); } to { transform: rotate(-38deg); } }
|
|
229
|
-
@keyframes kzb-dot { 0%, 100% { opacity: .35; transform: translateY(0); } 50% { opacity: 1; transform: translateY(-2px); } }
|
|
230
|
-
@keyframes kzb-hop { 0% { transform: translateY(0); } 30% { transform: translateY(-9px); } 60% { transform: translateY(0); } 100% { transform: translateY(0); } }
|
|
231
|
-
@keyframes kzb-pop { from { transform: scale(0); } to { transform: scale(1); } }
|
|
232
|
-
@keyframes kzb-twinkle { 0%, 100% { opacity: .25; transform: scale(.7); } 50% { opacity: 1; transform: scale(1); } }
|
|
233
|
-
@keyframes kzb-shake { 0%, 100% { transform: translateX(0); } 25% { transform: translateX(-3px); } 75% { transform: translateX(3px); } }
|
|
234
|
-
@keyframes kzb-sway { 0%, 100% { transform: rotate(0); } 50% { transform: rotate(-2deg); } }
|
|
235
|
-
@media (prefers-reduced-motion: reduce) {
|
|
236
|
-
.kzb-bird, .kzb-blink, .kzb-wing-r, .kzb-dot, .kzb-badge, .kzb-sparkle { animation: none !important; }
|
|
237
|
-
}
|
|
238
|
-
`;
|
|
239
|
-
var BRAND = {
|
|
240
|
-
from: "var(--kz-accent-2, var(--kz-accent))",
|
|
241
|
-
to: "var(--kz-accent)",
|
|
242
|
-
wing: "var(--kz-accent)",
|
|
243
|
-
detail: "var(--kz-accent-2, var(--kz-accent))",
|
|
244
|
-
beak: "var(--kz-warning)",
|
|
245
|
-
eye: "var(--kz-text-primary)"
|
|
246
|
-
};
|
|
247
|
-
var OUTLINE = "var(--kz-border-strong, color-mix(in srgb, currentColor 35%, transparent))";
|
|
248
|
-
var SURFACE = "var(--kz-surface-0)";
|
|
249
|
-
function Mascot({ bird = "owl", mood = "welcome", tone = "brand", size = 96, animated = true, title, className, ...props }) {
|
|
250
|
-
const uid = useId().replace(/[^a-zA-Z0-9_-]/g, "");
|
|
251
|
-
const g = BIRDS[bird];
|
|
252
|
-
const p = tone === "own" ? OWN_PALETTES[bird] : BRAND;
|
|
253
|
-
const body = `url(#kzb-${uid})`;
|
|
254
|
-
const line = { stroke: OUTLINE, strokeWidth: 1.4, strokeLinejoin: "round" };
|
|
255
|
-
const eyeR = g.eyes.white || g.eyes.pupil * 1.2;
|
|
256
|
-
const eyes = g.eyes.at.map((at, i) => {
|
|
257
|
-
const look = mood === "thinking" ? 1.4 : 0;
|
|
258
|
-
if (mood === "success") return /* @__PURE__ */ jsx("path", { d: archEye(at, eyeR * 0.85), stroke: g.visor ? p.eye : OUTLINE, strokeWidth: 2.2, strokeLinecap: "round", fill: "none" }, i);
|
|
259
|
-
if (mood === "empty" && g.eyes.white > 0)
|
|
260
|
-
return /* @__PURE__ */ jsxs("g", { children: [
|
|
261
|
-
/* @__PURE__ */ jsx("circle", { cx: at[0], cy: at[1], r: g.eyes.white, fill: LIGHT, ...line }),
|
|
262
|
-
/* @__PURE__ */ jsx("circle", { cx: at[0], cy: at[1] + g.eyes.pupil * 0.7, r: g.eyes.pupil, fill: SHADE }),
|
|
263
|
-
/* @__PURE__ */ jsx("path", { d: upperLid(at, g.eyes.white), fill: p.detail, ...line })
|
|
264
|
-
] }, i);
|
|
265
|
-
if (mood === "empty") return /* @__PURE__ */ jsx("path", { d: lidEye(at, eyeR * 0.8), stroke: g.visor ? p.eye : OUTLINE, strokeWidth: 2.2, strokeLinecap: "round", fill: "none" }, i);
|
|
266
|
-
return /* @__PURE__ */ jsxs("g", { className: "kzb-eye kzb-blink", children: [
|
|
267
|
-
g.eyes.white > 0 && /* @__PURE__ */ jsx("circle", { cx: at[0], cy: at[1], r: g.eyes.white, fill: LIGHT, ...line }),
|
|
268
|
-
/* @__PURE__ */ jsx("circle", { cx: at[0] + look, cy: at[1] - look, r: g.eyes.pupil, fill: g.visor ? p.eye : SHADE }),
|
|
269
|
-
g.eyes.white > 0 && /* @__PURE__ */ jsx("circle", { cx: at[0] + look - g.eyes.pupil * 0.35, cy: at[1] - look - g.eyes.pupil * 0.35, r: g.eyes.pupil * 0.35, fill: LIGHT })
|
|
270
|
-
] }, i);
|
|
271
|
-
});
|
|
272
|
-
const [wl, wr] = g.wings;
|
|
273
|
-
return /* @__PURE__ */ jsxs(
|
|
274
|
-
"svg",
|
|
275
|
-
{
|
|
276
|
-
width: size,
|
|
277
|
-
height: size,
|
|
278
|
-
viewBox: "0 0 120 120",
|
|
279
|
-
fill: "none",
|
|
280
|
-
xmlns: "http://www.w3.org/2000/svg",
|
|
281
|
-
"data-bird": bird,
|
|
282
|
-
"data-mood": mood,
|
|
283
|
-
"data-animated": animated ? "" : void 0,
|
|
284
|
-
className,
|
|
285
|
-
...title ? { role: "img", "aria-label": title } : { "aria-hidden": true },
|
|
286
|
-
...props,
|
|
287
|
-
children: [
|
|
288
|
-
/* @__PURE__ */ jsx("style", { children: CSS }),
|
|
289
|
-
/* @__PURE__ */ jsx("defs", { children: /* @__PURE__ */ jsxs("linearGradient", { id: `kzb-${uid}`, x1: "0", y1: "0", x2: "0", y2: "1", children: [
|
|
290
|
-
/* @__PURE__ */ jsx("stop", { offset: "0%", style: { stopColor: p.from } }),
|
|
291
|
-
/* @__PURE__ */ jsx("stop", { offset: "100%", style: { stopColor: p.to } })
|
|
292
|
-
] }) }),
|
|
293
|
-
/* @__PURE__ */ jsx("ellipse", { cx: g.shadow[0], cy: g.shadow[1], rx: g.shadow[2], ry: g.shadow[3], fill: SHADE, opacity: 0.14 }),
|
|
294
|
-
mood === "empty" && /* @__PURE__ */ jsx("path", { d: MOOD_PARTS.tray, stroke: OUTLINE, strokeWidth: 1.6, strokeDasharray: "3 3", strokeLinejoin: "round" }),
|
|
295
|
-
/* @__PURE__ */ jsxs("g", { className: "kzb-bird", children: [
|
|
296
|
-
g.legs.map((d) => /* @__PURE__ */ jsx("path", { d, stroke: p.beak, strokeWidth: 2.6, strokeLinecap: "round" }, d)),
|
|
297
|
-
g.back?.map((d) => d.endsWith("Z") ? /* @__PURE__ */ jsx("path", { d, fill: p.detail, ...line }, d) : /* @__PURE__ */ jsx("path", { d, stroke: OUTLINE, strokeWidth: 1.4 }, d)),
|
|
298
|
-
g.parcel && /* @__PURE__ */ jsx("g", { ...line, children: g.parcel.map((d, i) => /* @__PURE__ */ jsx("path", { d, fill: PARCEL[i] }, d)) }),
|
|
299
|
-
/* @__PURE__ */ jsx("path", { d: g.body, fill: body, ...line }),
|
|
300
|
-
/* @__PURE__ */ jsx("path", { d: g.belly, fill: LIGHT, opacity: 0.28 }),
|
|
301
|
-
[wl, wr].map((w, i) => {
|
|
302
|
-
const turn = mood === "success" ? i === 0 ? 28 : -28 : mood === "welcome" && i === 1 ? -20 : 0;
|
|
303
|
-
return /* @__PURE__ */ jsxs("g", { className: i === 1 ? "kzb-wing kzb-wing-r" : "kzb-wing", style: { transformOrigin: `${w.pivot[0]}px ${w.pivot[1]}px`, transform: turn ? `rotate(${turn}deg)` : void 0 }, children: [
|
|
304
|
-
/* @__PURE__ */ jsx("path", { d: w.d, fill: p.wing, ...line }),
|
|
305
|
-
/* @__PURE__ */ jsx("path", { d: w.d, fill: SHADE, opacity: 0.16 })
|
|
306
|
-
] }, i);
|
|
307
|
-
}),
|
|
308
|
-
g.neck && /* @__PURE__ */ jsx("path", { d: g.neck.d, stroke: body, strokeWidth: g.neck.width, strokeLinecap: "round" }),
|
|
309
|
-
g.head.r > 0 && /* @__PURE__ */ jsx("circle", { cx: g.head.cx, cy: g.head.cy, r: g.head.r, fill: body, ...line }),
|
|
310
|
-
g.details.map((d) => /* @__PURE__ */ jsx("path", { d, fill: p.detail, ...line }, d)),
|
|
311
|
-
g.visor && /* @__PURE__ */ jsx("rect", { x: g.visor.x, y: g.visor.y, width: g.visor.w, height: g.visor.h, rx: 4, fill: SURFACE, ...line }),
|
|
312
|
-
eyes,
|
|
313
|
-
g.glasses && /* @__PURE__ */ jsxs("g", { stroke: OUTLINE, strokeWidth: 1.3, children: [
|
|
314
|
-
g.eyes.at.map(([x, y]) => /* @__PURE__ */ jsx("circle", { cx: x, cy: y, r: 6.5, fill: LIGHT, fillOpacity: 0.12 }, x)),
|
|
315
|
-
/* @__PURE__ */ jsx("path", { d: `M${g.eyes.at[0][0] + 6.5} ${g.eyes.at[0][1]} L${g.eyes.at[1][0] - 6.5} ${g.eyes.at[1][1]}` })
|
|
316
|
-
] }),
|
|
317
|
-
mood === "error" && g.eyes.at.map((at, i) => /* @__PURE__ */ jsx("path", { d: brow(at, eyeR, g.eyes.at.length === 1 ? 1 : i === 0 ? -1 : 1), stroke: OUTLINE, strokeWidth: 2, strokeLinecap: "round" }, i)),
|
|
318
|
-
/* @__PURE__ */ jsx("path", { d: g.beak, fill: p.beak, ...line })
|
|
319
|
-
] }),
|
|
320
|
-
mood === "thinking" && /* @__PURE__ */ jsx("g", { children: MOOD_PARTS.dots.map(([cx, cy, r]) => /* @__PURE__ */ jsx("circle", { className: "kzb-dot", cx, cy, r, fill: "var(--kz-text-secondary)" }, cx)) }),
|
|
321
|
-
mood === "success" && /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
322
|
-
MOOD_PARTS.sparkles.map((d) => /* @__PURE__ */ jsx("path", { className: "kzb-sparkle", d, fill: p.from }, d)),
|
|
323
|
-
/* @__PURE__ */ jsxs("g", { className: "kzb-badge", children: [
|
|
324
|
-
/* @__PURE__ */ jsx("circle", { cx: MOOD_PARTS.badge.cx, cy: MOOD_PARTS.badge.cy, r: MOOD_PARTS.badge.r, fill: "var(--kz-success)" }),
|
|
325
|
-
/* @__PURE__ */ jsx("path", { d: MOOD_PARTS.check, stroke: SURFACE, strokeWidth: 2.6, strokeLinecap: "round", strokeLinejoin: "round" })
|
|
326
|
-
] })
|
|
327
|
-
] }),
|
|
328
|
-
mood === "error" && /* @__PURE__ */ jsxs("g", { className: "kzb-badge", children: [
|
|
329
|
-
/* @__PURE__ */ jsx("circle", { cx: MOOD_PARTS.badge.cx, cy: MOOD_PARTS.badge.cy, r: MOOD_PARTS.badge.r, fill: "var(--kz-danger)" }),
|
|
330
|
-
/* @__PURE__ */ jsx("path", { d: MOOD_PARTS.bang.line, stroke: SURFACE, strokeWidth: 2.8, strokeLinecap: "round" }),
|
|
331
|
-
/* @__PURE__ */ jsx("circle", { cx: MOOD_PARTS.bang.dot[0], cy: MOOD_PARTS.bang.dot[1], r: 1.6, fill: SURFACE })
|
|
332
|
-
] })
|
|
333
|
-
]
|
|
334
|
-
}
|
|
335
|
-
);
|
|
336
|
-
}
|
|
337
|
-
|
|
338
9
|
// src/mascot-quote/mascot-quote.tsx
|
|
339
|
-
import { jsx
|
|
10
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
340
11
|
function MascotQuote({ bird, mood = "thinking", label, children, variant = "inline", animated, className, ...props }) {
|
|
341
12
|
const callout = variant === "callout";
|
|
342
|
-
return /* @__PURE__ */
|
|
343
|
-
/* @__PURE__ */
|
|
344
|
-
/* @__PURE__ */
|
|
345
|
-
/* @__PURE__ */
|
|
346
|
-
/* @__PURE__ */
|
|
13
|
+
return /* @__PURE__ */ jsxs("figure", { className: cn("kz-quote", className), "data-variant": callout ? "callout" : void 0, ...props, children: [
|
|
14
|
+
/* @__PURE__ */ jsx("blockquote", { children: /* @__PURE__ */ jsx("p", { children }) }),
|
|
15
|
+
/* @__PURE__ */ jsxs("figcaption", { children: [
|
|
16
|
+
/* @__PURE__ */ jsx(Mascot, { bird, mood, size: callout ? 72 : 44, animated: animated ?? callout, className: "kz-quote-bird", "aria-hidden": true }),
|
|
17
|
+
/* @__PURE__ */ jsx("span", { children: label })
|
|
347
18
|
] })
|
|
348
19
|
] });
|
|
349
20
|
}
|
package/dist/mascot-quote.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/mascots/mascot.tsx","../src/mascots/geometry.ts","../src/mascot-quote/mascot-quote.tsx"],"sourcesContent":["// The Krizaka flock on the web: one bird, one mood, drawn from ./geometry in the host's brand colours.\nimport type * as React from \"react\";\nimport { useId } from \"react\";\n\nimport { archEye, BIRDS, brow, lidEye, LIGHT, type MascotBird, type MascotMood, type MascotPalette, type MascotTone, MOOD_PARTS, OWN_PALETTES, PARCEL, SHADE, upperLid } from \"./geometry\";\n\nconst CSS = `\n.kzb-bird { transform-box: view-box; transform-origin: 60px 108px; }\n.kzb-eye { transform-box: fill-box; transform-origin: center; }\n.kzb-wing { transform-box: view-box; }\n[data-animated] .kzb-bird { animation: kzb-bob 3.6s ease-in-out infinite; }\n[data-animated] .kzb-blink { animation: kzb-blink 5.2s ease-in-out infinite; }\n[data-animated][data-mood=\"welcome\"] .kzb-wing-r { animation: kzb-wave 1.1s ease-in-out infinite alternate; }\n[data-animated][data-mood=\"thinking\"] .kzb-dot { animation: kzb-dot 1.5s ease-in-out infinite; }\n[data-animated][data-mood=\"thinking\"] .kzb-dot:nth-child(2) { animation-delay: .2s; }\n[data-animated][data-mood=\"thinking\"] .kzb-dot:nth-child(3) { animation-delay: .4s; }\n[data-animated][data-mood=\"success\"] .kzb-bird { animation: kzb-hop 1.6s cubic-bezier(.3,1.6,.5,1) 1, kzb-bob 3.6s ease-in-out 1.6s infinite; }\n[data-animated][data-mood=\"success\"] .kzb-badge { animation: kzb-pop .5s cubic-bezier(.3,1.6,.5,1) .3s both; }\n[data-animated][data-mood=\"success\"] .kzb-sparkle { animation: kzb-twinkle 2.4s ease-in-out infinite; }\n[data-animated][data-mood=\"error\"] .kzb-bird { animation: kzb-shake .5s ease-in-out .2s 2, kzb-bob 3.6s ease-in-out 1.2s infinite; }\n[data-animated][data-mood=\"empty\"] .kzb-bird { animation: kzb-sway 5s ease-in-out infinite; }\n.kzb-badge, .kzb-sparkle, .kzb-dot { transform-box: fill-box; transform-origin: center; }\n@keyframes kzb-bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-2.5px); } }\n@keyframes kzb-blink { 0%, 92%, 100% { transform: scaleY(1); } 95% { transform: scaleY(.1); } }\n@keyframes kzb-wave { from { transform: rotate(-8deg); } to { transform: rotate(-38deg); } }\n@keyframes kzb-dot { 0%, 100% { opacity: .35; transform: translateY(0); } 50% { opacity: 1; transform: translateY(-2px); } }\n@keyframes kzb-hop { 0% { transform: translateY(0); } 30% { transform: translateY(-9px); } 60% { transform: translateY(0); } 100% { transform: translateY(0); } }\n@keyframes kzb-pop { from { transform: scale(0); } to { transform: scale(1); } }\n@keyframes kzb-twinkle { 0%, 100% { opacity: .25; transform: scale(.7); } 50% { opacity: 1; transform: scale(1); } }\n@keyframes kzb-shake { 0%, 100% { transform: translateX(0); } 25% { transform: translateX(-3px); } 75% { transform: translateX(3px); } }\n@keyframes kzb-sway { 0%, 100% { transform: rotate(0); } 50% { transform: rotate(-2deg); } }\n@media (prefers-reduced-motion: reduce) {\n .kzb-bird, .kzb-blink, .kzb-wing-r, .kzb-dot, .kzb-badge, .kzb-sparkle { animation: none !important; }\n}\n`;\n\n/** The host's roles (`tone=\"brand\"`): the accent paints the bird, so it wears the product it is shown in. */\nconst BRAND: MascotPalette = {\n from: \"var(--kz-accent-2, var(--kz-accent))\",\n to: \"var(--kz-accent)\",\n wing: \"var(--kz-accent)\",\n detail: \"var(--kz-accent-2, var(--kz-accent))\",\n beak: \"var(--kz-warning)\",\n eye: \"var(--kz-text-primary)\",\n};\nconst OUTLINE = \"var(--kz-border-strong, color-mix(in srgb, currentColor 35%, transparent))\";\nconst SURFACE = \"var(--kz-surface-0)\";\n\nexport type MascotProps = Omit<React.ComponentProps<\"svg\">, \"children\"> & {\n /** Which bird of the flock: `falcon` (watch, security), `owl` (reading, documents), `duck` (building, code), `flamingo` (answers, support), `pigeon` (delivery, notifications), `lovebird` (introductions, two people who meet), `crane` (listening, a calm moment), `magpie` (the score: points, standings, trophies), `beaver` (the shop: a small business at work). */\n bird?: MascotBird;\n /** What the moment is: `welcome` (onboarding), `thinking` (a long task running), `success` (it is done), `empty` (nothing here yet), `error` (it failed). */\n mood?: MascotMood;\n /** `brand` (default): the host's accent, so the bird wears the product it is in. `own`: the bird's signature colours of the Krizaka story. */\n tone?: MascotTone;\n /** Width and height in pixels. */\n size?: number;\n /** A light idle motion and the mood's gesture. Off with `false`; always off under `prefers-reduced-motion`. */\n animated?: boolean;\n /** An accessible name (the bird becomes an image); without it the mascot is decorative. */\n title?: string;\n};\n\n/**\n * One of the nine Krizaka figures in one mood — for the moments a product speaks to a person: a welcome, a long wait,\n * a success, an empty list, an error. Drawn in the host's brand colours by default (`tone=\"own\"` for the story's).\n */\nexport function Mascot({ bird = \"owl\", mood = \"welcome\", tone = \"brand\", size = 96, animated = true, title, className, ...props }: MascotProps) {\n const uid = useId().replace(/[^a-zA-Z0-9_-]/g, \"\");\n const g = BIRDS[bird];\n const p = tone === \"own\" ? OWN_PALETTES[bird] : BRAND;\n const body = `url(#kzb-${uid})`;\n const line = { stroke: OUTLINE, strokeWidth: 1.4, strokeLinejoin: \"round\" as const };\n const eyeR = g.eyes.white || g.eyes.pupil * 1.2;\n const eyes = g.eyes.at.map((at, i) => {\n const look = mood === \"thinking\" ? 1.4 : 0;\n if (mood === \"success\") return <path key={i} d={archEye(at, eyeR * 0.85)} stroke={g.visor ? p.eye : OUTLINE} strokeWidth={2.2} strokeLinecap=\"round\" fill=\"none\" />;\n if (mood === \"empty\" && g.eyes.white > 0)\n return (\n <g key={i}>\n <circle cx={at[0]} cy={at[1]} r={g.eyes.white} fill={LIGHT} {...line} />\n <circle cx={at[0]} cy={at[1] + g.eyes.pupil * 0.7} r={g.eyes.pupil} fill={SHADE} />\n <path d={upperLid(at, g.eyes.white)} fill={p.detail} {...line} />\n </g>\n );\n if (mood === \"empty\") return <path key={i} d={lidEye(at, eyeR * 0.8)} stroke={g.visor ? p.eye : OUTLINE} strokeWidth={2.2} strokeLinecap=\"round\" fill=\"none\" />;\n return (\n <g key={i} className=\"kzb-eye kzb-blink\">\n {g.eyes.white > 0 && <circle cx={at[0]} cy={at[1]} r={g.eyes.white} fill={LIGHT} {...line} />}\n <circle cx={at[0] + look} cy={at[1] - look} r={g.eyes.pupil} fill={g.visor ? p.eye : SHADE} />\n {g.eyes.white > 0 && <circle cx={at[0] + look - g.eyes.pupil * 0.35} cy={at[1] - look - g.eyes.pupil * 0.35} r={g.eyes.pupil * 0.35} fill={LIGHT} />}\n </g>\n );\n });\n const [wl, wr] = g.wings;\n return (\n <svg\n width={size}\n height={size}\n viewBox=\"0 0 120 120\"\n fill=\"none\"\n xmlns=\"http://www.w3.org/2000/svg\"\n data-bird={bird}\n data-mood={mood}\n data-animated={animated ? \"\" : undefined}\n className={className}\n {...(title ? { role: \"img\", \"aria-label\": title } : { \"aria-hidden\": true })}\n {...props}\n >\n <style>{CSS}</style>\n <defs>\n <linearGradient id={`kzb-${uid}`} x1=\"0\" y1=\"0\" x2=\"0\" y2=\"1\">\n <stop offset=\"0%\" style={{ stopColor: p.from }} />\n <stop offset=\"100%\" style={{ stopColor: p.to }} />\n </linearGradient>\n </defs>\n <ellipse cx={g.shadow[0]} cy={g.shadow[1]} rx={g.shadow[2]} ry={g.shadow[3]} fill={SHADE} opacity={0.14} />\n {mood === \"empty\" && <path d={MOOD_PARTS.tray} stroke={OUTLINE} strokeWidth={1.6} strokeDasharray=\"3 3\" strokeLinejoin=\"round\" />}\n <g className=\"kzb-bird\">\n {g.legs.map((d) => (\n <path key={d} d={d} stroke={p.beak} strokeWidth={2.6} strokeLinecap=\"round\" />\n ))}\n {g.back?.map((d) => (d.endsWith(\"Z\") ? <path key={d} d={d} fill={p.detail} {...line} /> : <path key={d} d={d} stroke={OUTLINE} strokeWidth={1.4} />))}\n {g.parcel && (\n <g {...line}>\n {g.parcel.map((d, i) => (\n <path key={d} d={d} fill={PARCEL[i]} />\n ))}\n </g>\n )}\n <path d={g.body} fill={body} {...line} />\n <path d={g.belly} fill={LIGHT} opacity={0.28} />\n {[wl, wr].map((w, i) => {\n const turn = mood === \"success\" ? (i === 0 ? 28 : -28) : mood === \"welcome\" && i === 1 ? -20 : 0;\n return (\n <g key={i} className={i === 1 ? \"kzb-wing kzb-wing-r\" : \"kzb-wing\"} style={{ transformOrigin: `${w.pivot[0]}px ${w.pivot[1]}px`, transform: turn ? `rotate(${turn}deg)` : undefined }}>\n <path d={w.d} fill={p.wing} {...line} />\n <path d={w.d} fill={SHADE} opacity={0.16} />\n </g>\n );\n })}\n {g.neck && <path d={g.neck.d} stroke={body} strokeWidth={g.neck.width} strokeLinecap=\"round\" />}\n {g.head.r > 0 && <circle cx={g.head.cx} cy={g.head.cy} r={g.head.r} fill={body} {...line} />}\n {g.details.map((d) => (\n <path key={d} d={d} fill={p.detail} {...line} />\n ))}\n {g.visor && <rect x={g.visor.x} y={g.visor.y} width={g.visor.w} height={g.visor.h} rx={4} fill={SURFACE} {...line} />}\n {eyes}\n {g.glasses && (\n <g stroke={OUTLINE} strokeWidth={1.3}>\n {g.eyes.at.map(([x, y]) => (\n <circle key={x} cx={x} cy={y} r={6.5} fill={LIGHT} fillOpacity={0.12} />\n ))}\n <path d={`M${g.eyes.at[0][0] + 6.5} ${g.eyes.at[0][1]} L${g.eyes.at[1][0] - 6.5} ${g.eyes.at[1][1]}`} />\n </g>\n )}\n {mood === \"error\" &&\n g.eyes.at.map((at, i) => <path key={i} d={brow(at, eyeR, g.eyes.at.length === 1 ? 1 : i === 0 ? -1 : 1)} stroke={OUTLINE} strokeWidth={2} strokeLinecap=\"round\" />)}\n <path d={g.beak} fill={p.beak} {...line} />\n </g>\n {mood === \"thinking\" && (\n <g>\n {MOOD_PARTS.dots.map(([cx, cy, r]) => (\n <circle key={cx} className=\"kzb-dot\" cx={cx} cy={cy} r={r} fill=\"var(--kz-text-secondary)\" />\n ))}\n </g>\n )}\n {mood === \"success\" && (\n <>\n {MOOD_PARTS.sparkles.map((d) => (\n <path key={d} className=\"kzb-sparkle\" d={d} fill={p.from} />\n ))}\n <g className=\"kzb-badge\">\n <circle cx={MOOD_PARTS.badge.cx} cy={MOOD_PARTS.badge.cy} r={MOOD_PARTS.badge.r} fill=\"var(--kz-success)\" />\n <path d={MOOD_PARTS.check} stroke={SURFACE} strokeWidth={2.6} strokeLinecap=\"round\" strokeLinejoin=\"round\" />\n </g>\n </>\n )}\n {mood === \"error\" && (\n <g className=\"kzb-badge\">\n <circle cx={MOOD_PARTS.badge.cx} cy={MOOD_PARTS.badge.cy} r={MOOD_PARTS.badge.r} fill=\"var(--kz-danger)\" />\n <path d={MOOD_PARTS.bang.line} stroke={SURFACE} strokeWidth={2.8} strokeLinecap=\"round\" />\n <circle cx={MOOD_PARTS.bang.dot[0]} cy={MOOD_PARTS.bang.dot[1]} r={1.6} fill={SURFACE} />\n </g>\n )}\n </svg>\n );\n}\n","/**\n * The Krizaka flock — the geometry of the mascots, drawn by the web `Mascot` (`./mascot.tsx`) and the native one\n * (`../native/mascots.tsx`). Five birds that have carried the Krizaka story since the first site (the sentry falcon,\n * the owl that reads, the developer duck, the flamingo that answers, the carrier pigeon), the lovebird that\n * introduces (2026-10, with Yasakia: \"l'inséparable présente\") and the crane that listens (2026-10, with Yororis:\n * \"la grue écoute\"), the magpie that keeps the score (2026-10, with Kachizaka: \"la pie compte les points\") and the\n * beaver that builds the shop (2026-10, with Akinaza: \"le castor artisan\" — the one figure of the flock without\n * feathers: its paws are drawn as wings, its paddle tail behind it), redrawn on one 120 × 120 grid so that any figure\n * can wear any mood.\n *\n * Colours are roles, never fixed: `brand` (the default) paints a bird in the host's accent (`--kz-accent`,\n * `--kz-accent-2`), so the same falcon is blue on krizaka.com, orange in Orazaka and violet in Orochia; `own` gives\n * each bird the signature palette it has in the Krizaka story (the brand layer's exception, like the marks). Shades\n * and highlights are black and white at a low opacity over the role, so they hold in both themes.\n */\n\nexport const MASCOT_BIRDS = [\"falcon\", \"owl\", \"duck\", \"flamingo\", \"pigeon\", \"lovebird\", \"crane\", \"magpie\", \"beaver\"] as const;\nexport type MascotBird = (typeof MASCOT_BIRDS)[number];\n\nexport const MASCOT_MOODS = [\"welcome\", \"thinking\", \"success\", \"empty\", \"error\"] as const;\nexport type MascotMood = (typeof MASCOT_MOODS)[number];\n\nexport type MascotTone = \"brand\" | \"own\";\n\ntype Point = readonly [number, number];\n\nexport interface BirdGeometry {\n /** The ground shadow: centre x, y and radii. */\n readonly shadow: readonly [number, number, number, number];\n /** Legs and feet, stroked in the beak colour. */\n readonly legs: readonly string[];\n /** Drawn behind the body (tail, parcel strings). */\n readonly back?: readonly string[];\n readonly body: string;\n readonly belly: string;\n /** Left then right wing, and the point each one turns around. */\n readonly wings: readonly [{ readonly d: string; readonly pivot: Point }, { readonly d: string; readonly pivot: Point }];\n /** A neck, stroked in the body colour with this width (the flamingo). */\n readonly neck?: { readonly d: string; readonly width: number };\n /** The head: a circle. */\n readonly head: { readonly cx: number; readonly cy: number; readonly r: number };\n /** Ear tufts, a crest, a visor's frame: filled with the detail colour. */\n readonly details: readonly string[];\n /** A band behind the eyes (the falcon's visor), in the page's surface. */\n readonly visor?: { readonly x: number; readonly y: number; readonly w: number; readonly h: number };\n /** Glasses (the duck): stroked rings around the eyes. */\n readonly glasses?: boolean;\n readonly beak: string;\n /** The eyes: centres, the radius of the white, the radius of the pupil (no white when `white` is 0). */\n readonly eyes: { readonly at: readonly Point[]; readonly white: number; readonly pupil: number };\n /** The parcel the pigeon carries: its three faces. */\n readonly parcel?: readonly [string, string, string];\n}\n\nconst mirror = (d: string) => d.replace(/(-?\\d+(?:\\.\\d+)?) (-?\\d+(?:\\.\\d+)?)/g, (_, x: string, y: string) => `${120 - Number(x)} ${y}`);\n\nconst falconWing = \"M29 58 C17 68 19 88 37 86 C31 76 31 66 29 58 Z\";\nconst pigeonWing = \"M36 58 C20 50 16 80 38 84 C34 74 34 66 36 58 Z\";\n\nexport const BIRDS: Readonly<Record<MascotBird, BirdGeometry>> = {\n falcon: {\n shadow: [60, 110, 26, 3.5],\n legs: [\"M51 94 L48 108 M44 108 L52 108\", \"M69 94 L72 108 M68 108 L76 108\"],\n body: \"M30 62 C30 42 90 42 90 62 C90 88 78 98 60 98 C42 98 30 88 30 62 Z\",\n belly: \"M41 66 C41 55 79 55 79 66 C79 82 71 90 60 90 C49 90 41 82 41 66 Z\",\n wings: [\n { d: falconWing, pivot: [29, 58] },\n { d: mirror(falconWing), pivot: [91, 58] },\n ],\n head: { cx: 60, cy: 38, r: 22 },\n details: [\"M46 20 L52 10 L56 19 Z\", \"M74 20 L68 10 L64 19 Z\"],\n visor: { x: 41, y: 29, w: 38, h: 13 },\n beak: \"M54 45 L66 45 L60 57 Z\",\n eyes: { at: [[50, 35.5], [70, 35.5]], white: 0, pupil: 3.2 },\n },\n owl: {\n shadow: [60, 110, 24, 3.5],\n legs: [\"M53 100 L51 107 M47 107 L55 107\", \"M67 100 L69 107 M65 107 L73 107\"],\n body: \"M28 52 C28 20 92 20 92 52 C92 86 82 102 60 102 C38 102 28 86 28 52 Z\",\n belly: \"M42 66 C42 52 78 52 78 66 C78 86 72 94 60 94 C48 94 42 86 42 66 Z\",\n wings: [\n { d: \"M29 58 C18 68 20 88 36 90 C32 78 32 68 29 58 Z\", pivot: [29, 58] },\n { d: mirror(\"M29 58 C18 68 20 88 36 90 C32 78 32 68 29 58 Z\"), pivot: [91, 58] },\n ],\n head: { cx: 60, cy: 42, r: 0 },\n details: [\"M31 20 L47 31 L31 41 Z\", \"M89 20 L73 31 L89 41 Z\"],\n beak: \"M55 50 L65 50 L60 59 Z\",\n eyes: { at: [[47, 41], [73, 41]], white: 10, pupil: 4 },\n },\n duck: {\n shadow: [60, 110, 30, 3.5],\n legs: [],\n back: [\"M88 80 C100 76 104 66 96 62 C98 70 94 74 88 74 Z\"],\n body: \"M26 80 C26 62 94 62 94 80 C94 100 82 106 60 106 C38 106 26 100 26 80 Z\",\n belly: \"M38 84 C38 72 82 72 82 84 C82 96 74 101 60 101 C46 101 38 96 38 84 Z\",\n wings: [\n { d: \"M27 74 C14 80 18 98 35 96 C31 88 29 80 27 74 Z\", pivot: [27, 74] },\n { d: mirror(\"M27 74 C14 80 18 98 35 96 C31 88 29 80 27 74 Z\"), pivot: [93, 74] },\n ],\n head: { cx: 60, cy: 42, r: 23 },\n details: [\"M57 20 C54 11 63 8 66 14 C62 13 60 16 61 20 Z\"],\n glasses: true,\n beak: \"M43 51 C43 46 55 45 60 45 C65 45 77 46 77 51 C77 56 66 60 60 60 C54 60 43 56 43 51 Z\",\n eyes: { at: [[51, 37], [69, 37]], white: 0, pupil: 2.6 },\n },\n flamingo: {\n shadow: [60, 110, 20, 3],\n legs: [\"M56 86 L55 97 L58 108 M53 108 L62 108\", \"M65 86 L66 108 M62 108 L71 108\"],\n body: \"M38 70 C38 54 88 54 88 70 C88 86 76 90 62 90 C48 90 38 86 38 70 Z\",\n belly: \"M46 72 C46 63 80 63 80 72 C80 82 72 85 63 85 C54 85 46 82 46 72 Z\",\n wings: [\n { d: \"M42 64 C30 68 32 84 47 84 C43 76 43 70 42 64 Z\", pivot: [42, 64] },\n { d: \"M84 64 C96 68 94 84 79 84 C83 76 83 70 84 64 Z\", pivot: [84, 64] },\n ],\n neck: { d: \"M58 60 C58 42 40 34 46 22\", width: 7 },\n head: { cx: 48, cy: 18, r: 11 },\n details: [],\n beak: \"M38 16 C28 18 29 28 24 33 C33 28 38 23 40 20 Z\",\n eyes: { at: [[46, 15]], white: 3.2, pupil: 1.8 },\n },\n pigeon: {\n shadow: [60, 112, 22, 3],\n legs: [\"M52 94 L51 99 M48 99 L54 99\", \"M68 94 L69 99 M66 99 L72 99\"],\n back: [\"M53 98 L52 103\", \"M67 98 L68 103\", \"M30 68 C16 72 14 62 28 56 C17 57 15 49 32 48 Z\"],\n body: \"M34 64 C34 44 86 44 86 64 C86 86 74 96 60 96 C46 96 34 86 34 64 Z\",\n belly: \"M43 68 C43 57 77 57 77 68 C77 82 70 88 60 88 C50 88 43 82 43 68 Z\",\n wings: [\n { d: pigeonWing, pivot: [36, 58] },\n { d: mirror(pigeonWing), pivot: [84, 58] },\n ],\n head: { cx: 60, cy: 36, r: 19 },\n details: [\"M54 18 C56 12 64 12 66 18 C63 16 57 16 54 18 Z\"],\n beak: \"M55 41 L65 41 L60 50 Z\",\n eyes: { at: [[52, 33], [68, 33]], white: 5, pupil: 2.4 },\n parcel: [\"M60 100 L71 105 L60 110 L49 105 Z\", \"M49 105 L60 110 L60 118 L49 113 Z\", \"M71 105 L60 110 L60 118 L71 113 Z\"],\n },\n /**\n * The lovebird — the inseparable that introduces two people. A plump little parrot: a short tail, a round head\n * with its coloured face (the detail colour), the white eye-rings of the species and a short hooked beak.\n */\n lovebird: {\n shadow: [60, 110, 23, 3.5],\n legs: [\"M53 96 L52 106 M48 106 L56 106\", \"M67 96 L68 106 M64 106 L72 106\"],\n back: [\"M74 90 C82 98 88 104 95 103 C91 98 86 91 82 84 Z\"],\n body: \"M32 66 C32 46 88 46 88 66 C88 90 76 100 60 100 C44 100 32 90 32 66 Z\",\n belly: \"M42 70 C42 59 78 59 78 70 C78 85 70 92 60 92 C50 92 42 85 42 70 Z\",\n wings: [\n { d: \"M33 60 C20 68 22 88 40 90 C35 80 34 70 33 60 Z\", pivot: [33, 60] },\n { d: mirror(\"M33 60 C20 68 22 88 40 90 C35 80 34 70 33 60 Z\"), pivot: [87, 60] },\n ],\n head: { cx: 60, cy: 38, r: 21 },\n details: [\"M43 40 C42 28 51 22 60 22 C69 22 78 28 77 40 C76 50 68 55 60 55 C52 55 44 50 43 40 Z\"],\n beak: \"M55 44 C55 40 65 40 65 44 C65 50 62 54 60 55 C58 54 55 50 55 44 Z\",\n eyes: { at: [[51, 36], [69, 36]], white: 4.6, pupil: 2.4 },\n },\n /**\n * The crane — the one that listens: posed, unhurried, drawn in one line. A tall wader seen in profile, standing still\n * on two straight legs, the neck a single stroke up to a small head with its crown (the detail colour) and a long,\n * straight beak; the folded wings low on its back. The flamingo bends and answers; the crane stands and listens.\n */\n crane: {\n shadow: [62, 110, 20, 3],\n legs: [\"M56 87 L55 108 M51 108 L59 108\", \"M67 87 L68 108 M64 108 L73 108\"],\n body: \"M40 66 C38 54 84 54 86 68 C88 82 76 88 62 88 C48 88 40 80 40 66 Z\",\n belly: \"M48 70 C48 62 78 62 79 70 C80 79 72 84 63 84 C54 84 48 79 48 70 Z\",\n wings: [\n { d: \"M44 62 C33 68 35 82 49 83 C45 76 45 69 44 62 Z\", pivot: [44, 62] },\n { d: \"M82 62 C93 67 96 82 80 84 C83 76 83 69 82 62 Z\", pivot: [82, 62] },\n ],\n neck: { d: \"M52 62 C48 47 52 37 48 26\", width: 6 },\n head: { cx: 47, cy: 21, r: 8.5 },\n details: [\"M41 16.5 C42 11 52 11 53 16.5 C50 14.6 44 14.6 41 16.5 Z\"],\n beak: \"M40.5 18.5 L19 22.5 L40.5 25.5 Z\",\n eyes: { at: [[45.5, 19.5]], white: 2.8, pupil: 1.6 },\n },\n /**\n * The magpie — the one that keeps the score: it counts the points, remembers every trophy and chatters with the\n * league. A sleek pied bird: a dark cap (the detail colour) over a round head, a white belly, a long tail behind it\n * (the detail colour), a short straight beak. It watches no one (that is the falcon): it counts.\n */\n magpie: {\n shadow: [58, 110, 24, 3.5],\n legs: [\"M53 95 L51 107 M47 107 L55 107\", \"M65 95 L67 107 M63 107 L71 107\"],\n back: [\"M72 88 C84 94 96 102 106 108 C104 111 100 112 97 110 C88 104 78 98 68 94 Z\"],\n body: \"M34 64 C34 44 84 44 84 64 C84 88 72 98 58 98 C44 98 34 88 34 64 Z\",\n belly: \"M43 70 C43 60 73 60 73 70 C73 84 67 90 58 90 C49 90 43 84 43 70 Z\",\n wings: [\n { d: \"M35 58 C22 64 22 84 40 88 C36 78 35 68 35 58 Z\", pivot: [35, 58] },\n { d: \"M83 58 C96 64 96 84 78 88 C82 78 83 68 83 58 Z\", pivot: [83, 58] },\n ],\n head: { cx: 58, cy: 36, r: 19 },\n details: [\"M40 34 C40 22 48 16 58 16 C68 16 76 22 76 34 C70 29 64 28 58 28 C52 28 46 29 40 34 Z\"],\n beak: \"M53 42 L63 42 L58 50 Z\",\n eyes: { at: [[50, 35], [66, 35]], white: 4.4, pupil: 2.3 },\n },\n /**\n * The beaver — the artisan that builds the shop, Akinaza's figure (and Canada's). Round and sturdy, sitting up: two\n * round ears and a nose (the detail colour), the two front teeth (the beak colour), small paws drawn as its wings,\n * and its flat paddle tail lying behind it. No feathers, the same moods.\n */\n beaver: {\n shadow: [62, 110, 30, 3.5],\n legs: [\"M50 100 L48 106 M43 106 L53 106\", \"M70 100 L72 106 M67 106 L77 106\"],\n back: [\"M74 94 C86 92 104 96 108 103 C106 110 90 111 76 104 Z\"],\n body: \"M30 72 C30 48 90 48 90 72 C90 96 78 104 60 104 C42 104 30 96 30 72 Z\",\n belly: \"M42 76 C42 64 78 64 78 76 C78 92 70 98 60 98 C50 98 42 92 42 76 Z\",\n wings: [\n { d: \"M38 66 C28 70 30 84 42 84 C44 78 42 72 38 66 Z\", pivot: [38, 66] },\n { d: \"M82 66 C92 70 90 84 78 84 C76 78 78 72 82 66 Z\", pivot: [82, 66] },\n ],\n head: { cx: 60, cy: 40, r: 22 },\n details: [\"M37 30 C33 23 39 16 46 20 C43 23 40 26 37 30 Z\", \"M83 30 C87 23 81 16 74 20 C77 23 80 26 83 30 Z\", \"M55 45 C55 42 65 42 65 45 C65 48 62 49 60 49 C58 49 55 48 55 45 Z\"],\n beak: \"M56 51 H64 V58 C64 59.5 63 60 62 60 H58 C57 60 56 59.5 56 58 Z\",\n eyes: { at: [[51, 36], [69, 36]], white: 4.6, pupil: 2.4 },\n },\n};\n\n/** What a mood adds around the bird: a badge, a thought, an empty tray. */\nexport const MOOD_PARTS = {\n /** The badge of `success` and `error`, top right. */\n badge: { cx: 98, cy: 22, r: 11 },\n check: \"M92.5 22.5 L96.8 26.6 L103.6 18.4\",\n bang: { line: \"M98 15.5 L98 23.5\", dot: [98, 28] as Point },\n /** `thinking`: three dots rising to the right of the head. */\n dots: [\n [88, 26, 2.6],\n [96, 19, 3.2],\n [105, 11, 3.8],\n ] as const,\n /** `empty`: an open tray beside the bird. */\n tray: \"M90 96 L110 96 L107 108 L93 108 Z\",\n /** `success`: two sparkles. */\n sparkles: [\"M16 26 L18 31 L23 33 L18 35 L16 40 L14 35 L9 33 L14 31 Z\", \"M104 52 L105.2 55 L108 56 L105.2 57 L104 60 L102.8 57 L100 56 L102.8 55 Z\"],\n} as const;\n\n/** The happy eye of `success`: an arch. */\nexport const archEye = ([x, y]: Point, r: number) => `M${x - r} ${y + r * 0.45} Q${x} ${y - r * 1.15} ${x + r} ${y + r * 0.45}`;\n/** The lowered lid of `empty`: a line across the eye. */\nexport const lidEye = ([x, y]: Point, r: number) => `M${x - r} ${y + 0.4} L${x + r} ${y + 0.4}`;\n/** The heavy lid of `empty` over an eye with a white: its upper half. */\nexport const upperLid = ([x, y]: Point, r: number) => `M${x - r} ${y} A${r} ${r} 0 0 1 ${x + r} ${y} Z`;\n/** The worried brow of `error`, above one eye (`side` -1 left, 1 right). */\nexport const brow = ([x, y]: Point, r: number, side: number) =>\n `M${x - r * 1.1} ${y - r * 1.25 - (side < 0 ? 0 : r * 0.7)} L${x + r * 1.1} ${y - r * 1.5 - (side < 0 ? r * 0.7 : 0)}`;\n\nexport interface MascotPalette {\n /** Top and bottom of the body gradient. */\n readonly from: string;\n readonly to: string;\n /** Wings and details (tufts, crest). */\n readonly wing: string;\n readonly detail: string;\n /** Beak and feet. */\n readonly beak: string;\n /** The pupils (and the falcon's visor lights). */\n readonly eye: string;\n}\n\n/** The signature palettes of the Krizaka story (`tone=\"own\"`), from the first drawings of each bird. */\nexport const OWN_PALETTES: Readonly<Record<MascotBird, MascotPalette>> = {\n falcon: { from: \"#ff9f00\", to: \"#ff2a00\", wing: \"#d84315\", detail: \"#b4320d\", beak: \"#ffb300\", eye: \"#00c8d4\" },\n owl: { from: \"#a78bfa\", to: \"#6d28d9\", wing: \"#7c3aed\", detail: \"#5b21b6\", beak: \"#fbbf24\", eye: \"#1f2937\" },\n duck: { from: \"#f43f5e\", to: \"#be123c\", wing: \"#db2777\", detail: \"#9f1239\", beak: \"#fbbf24\", eye: \"#1f2937\" },\n flamingo: { from: \"#f9a8d4\", to: \"#db2777\", wing: \"#ec4899\", detail: \"#be185d\", beak: \"#fbbf24\", eye: \"#1f2937\" },\n pigeon: { from: \"#22d3ee\", to: \"#6366f1\", wing: \"#a855f7\", detail: \"#4338ca\", beak: \"#f59e0b\", eye: \"#1f2937\" },\n lovebird: { from: \"#6ee7b7\", to: \"#059669\", wing: \"#047857\", detail: \"#fb7185\", beak: \"#f97316\", eye: \"#1f2937\" },\n // The sandhill crane (grue du Canada): sand-grey plumage, its red crown, dark legs and beak.\n crane: { from: \"#ebe3d6\", to: \"#9c8f80\", wing: \"#7d7266\", detail: \"#dc2626\", beak: \"#44403c\", eye: \"#1f2937\" },\n // The Eurasian magpie (pie bavarde): slate and ink, the cobalt sheen of its wings, a dark beak.\n magpie: { from: \"#64748b\", to: \"#1e293b\", wing: \"#1d4ed8\", detail: \"#0f172a\", beak: \"#334155\", eye: \"#1f2937\" },\n // The North American beaver (castor du Canada): warm brown fur, a dark nose and tail, its orange front teeth.\n beaver: { from: \"#b07a4a\", to: \"#6b4226\", wing: \"#5c3a21\", detail: \"#3f2716\", beak: \"#f59e0b\", eye: \"#1f2937\" },\n};\n\n/** Fixed light and shade, laid at a low opacity over a role (they read on both themes). */\nexport const LIGHT = \"#ffffff\";\nexport const SHADE = \"#000000\";\n/** The parcel's faces (pigeon). */\nexport const PARCEL = [\"#f59e0b\", \"#d97706\", \"#b45309\"] as const;\n","// Client (the bird has an id per instance). A rule, a promise or a decision told by a bird (blocks.css): the sentence in\n// a speech bubble — an opening quote mark, the hue around it — and under its tail the bird and who speaks. One bird per\n// idea (Mascot's rule): the falcon watches, the owl reads, the duck builds, the flamingo answers or gets paid, the\n// pigeon delivers, the lovebird introduces, the crane listens, the magpie keeps the score, the beaver builds the shop.\nimport type * as React from \"react\";\n\nimport { cn } from \"../cn\";\nimport { type MascotBird, type MascotMood } from \"../mascots/geometry\";\nimport { Mascot } from \"../mascots/mascot\";\n\nexport type MascotQuoteProps = Omit<React.HTMLAttributes<HTMLElement>, \"children\"> & {\n /** The bird that speaks — the one whose idea it is. */\n bird: MascotBird;\n /**\n * Its mood.\n * @default \"thinking\"\n */\n mood?: MascotMood;\n /** Who speaks, under the bubble: `The falcon's rule`. */\n label: React.ReactNode;\n /** The sentence: the rule, the promise. */\n children: React.ReactNode;\n /**\n * `inline` inside a card (small, the bird answers the pointer); `callout` alone in a section (larger, the bird alive).\n * @default \"inline\"\n */\n variant?: \"inline\" | \"callout\";\n /** The bird's idle loop (it pauses off screen and stops under reduced motion). Defaults to `true` for a callout. */\n animated?: boolean;\n};\n\n/** A sentence told by a bird: a speech bubble, the bird under its tail, who speaks. The bird is decorative. */\nexport function MascotQuote({ bird, mood = \"thinking\", label, children, variant = \"inline\", animated, className, ...props }: MascotQuoteProps) {\n const callout = variant === \"callout\";\n return (\n <figure className={cn(\"kz-quote\", className)} data-variant={callout ? \"callout\" : undefined} {...props}>\n <blockquote>\n <p>{children}</p>\n </blockquote>\n <figcaption>\n <Mascot bird={bird} mood={mood} size={callout ? 72 : 44} animated={animated ?? callout} className=\"kz-quote-bird\" aria-hidden />\n <span>{label}</span>\n </figcaption>\n </figure>\n );\n}\n"],"mappings":";;;;;;AAEA,SAAS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an id per instance). A rule, a promise or a decision told by a bird (blocks.css): the sentence in\n// a speech bubble — an opening quote mark, the hue around it — and under its tail the bird and who speaks. One bird per\n// idea (Mascot's rule): the falcon watches, the owl reads, the duck builds, the flamingo answers or gets paid, the\n// pigeon delivers, the lovebird introduces, the crane listens, the magpie keeps the score, the beaver builds the shop.\nimport type * as React from \"react\";\n\nimport { cn } from \"../cn\";\nimport { type MascotBird, type MascotMood } from \"../mascots/geometry\";\nimport { Mascot } from \"../mascots/mascot\";\n\nexport type MascotQuoteProps = Omit<React.HTMLAttributes<HTMLElement>, \"children\"> & {\n /** The bird that speaks — the one whose idea it is. */\n bird: MascotBird;\n /**\n * Its mood.\n * @default \"thinking\"\n */\n mood?: MascotMood;\n /** Who speaks, under the bubble: `The falcon's rule`. */\n label: React.ReactNode;\n /** The sentence: the rule, the promise. */\n children: React.ReactNode;\n /**\n * `inline` inside a card (small, the bird answers the pointer); `callout` alone in a section (larger, the bird alive).\n * @default \"inline\"\n */\n variant?: \"inline\" | \"callout\";\n /** The bird's idle loop (it pauses off screen and stops under reduced motion). Defaults to `true` for a callout. */\n animated?: boolean;\n};\n\n/** A sentence told by a bird: a speech bubble, the bird under its tail, who speaks. The bird is decorative. */\nexport function MascotQuote({ bird, mood = \"thinking\", label, children, variant = \"inline\", animated, className, ...props }: MascotQuoteProps) {\n const callout = variant === \"callout\";\n return (\n <figure className={cn(\"kz-quote\", className)} data-variant={callout ? \"callout\" : undefined} {...props}>\n <blockquote>\n <p>{children}</p>\n </blockquote>\n <figcaption>\n <Mascot bird={bird} mood={mood} size={callout ? 72 : 44} animated={animated ?? callout} className=\"kz-quote-bird\" aria-hidden />\n <span>{label}</span>\n </figcaption>\n </figure>\n );\n}\n"],"mappings":";;;;;;;;;AAqCQ,cAEF,YAFE;AALD,SAAS,YAAY,EAAE,MAAM,OAAO,YAAY,OAAO,UAAU,UAAU,UAAU,UAAU,WAAW,GAAG,MAAM,GAAqB;AAC7I,QAAM,UAAU,YAAY;AAC5B,SACE,qBAAC,YAAO,WAAW,GAAG,YAAY,SAAS,GAAG,gBAAc,UAAU,YAAY,QAAY,GAAG,OAC/F;AAAA,wBAAC,gBACC,8BAAC,OAAG,UAAS,GACf;AAAA,IACA,qBAAC,gBACC;AAAA,0BAAC,UAAO,MAAY,MAAY,MAAM,UAAU,KAAK,IAAI,UAAU,YAAY,SAAS,WAAU,iBAAgB,eAAW,MAAC;AAAA,MAC9H,oBAAC,UAAM,iBAAM;AAAA,OACf;AAAA,KACF;AAEJ;","names":[]}
|
package/dist/match-dialog.js
CHANGED
|
@@ -36,7 +36,7 @@ function useReturnFocus(onCloseAutoFocus) {
|
|
|
36
36
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
37
37
|
var dialog = tv({
|
|
38
38
|
slots: {
|
|
39
|
-
overlay: "kz-overlay fixed inset-0 z-50 bg-overlay
|
|
39
|
+
overlay: "kz-overlay fixed inset-0 z-50 bg-overlay",
|
|
40
40
|
content: "kz-dialog fixed z-50 flex flex-col overflow-hidden border border-border-default bg-surface-1 text-fg shadow-lg focus:outline-hidden",
|
|
41
41
|
close: "absolute right-3 top-3 h-9 w-9",
|
|
42
42
|
header: "flex flex-col gap-1 px-5 pb-2 pr-14 pt-5",
|
package/dist/match-dialog.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/dialog/dialog.tsx","../src/dialog/return-focus.ts","../src/match-dialog/match-dialog.tsx"],"sourcesContent":["// Client (a portal). Radix does the focus trap, the scroll lock, Escape, the outside click, aria-modal, the\n// aria-labelledby / aria-describedby wiring and the focus return: this file only holds the shape.\nimport { Dialog as DialogPrimitive } from \"radix-ui\";\nimport type * as React from \"react\";\nimport { tv, type VariantProps } from \"tailwind-variants\";\n\nimport { IconButton } from \"../button/button\";\nimport { useReturnFocus } from \"./return-focus\";\n\nexport const dialog = tv({\n slots: {\n overlay: \"kz-overlay fixed inset-0 z-50 bg-overlay backdrop-blur-xs\",\n content:\n \"kz-dialog fixed z-50 flex flex-col overflow-hidden border border-border-default bg-surface-1 text-fg shadow-lg focus:outline-hidden\",\n close: \"absolute right-3 top-3 h-9 w-9\",\n header: \"flex flex-col gap-1 px-5 pb-2 pr-14 pt-5\",\n title: \"text-base font-bold text-fg\",\n description: \"text-sm text-fg-secondary\",\n body: \"min-h-0 flex-1 overflow-y-auto px-5 pb-5\",\n footer:\n \"flex flex-wrap items-center justify-end gap-2 border-t border-border-subtle px-5 py-4 pb-[max(1rem,env(safe-area-inset-bottom))]\",\n },\n variants: {\n placement: {\n center: { content: \"left-1/2 top-1/2 max-h-[85dvh] w-[calc(100%-2rem)] -translate-x-1/2 -translate-y-1/2 rounded-xl\" },\n /* A sheet: anchored at the bottom on a phone, centred from `sm` up. */\n bottom: {\n content:\n \"inset-x-0 bottom-0 max-h-[92dvh] rounded-t-[1.75rem] sm:bottom-auto sm:left-1/2 sm:top-1/2 sm:w-full \" +\n \"sm:-translate-x-1/2 sm:-translate-y-1/2 sm:rounded-[1.75rem]\",\n },\n right: { content: \"inset-y-0 right-0 h-full w-full max-w-md rounded-none border-y-0 border-r-0\" },\n /* A navigation drawer: full height, from the left, clear of the notch. */\n left: { content: \"inset-y-0 left-0 h-full w-full max-w-md rounded-none border-y-0 border-l-0 pl-[env(safe-area-inset-left)]\" },\n },\n size: { sm: { content: \"sm:max-w-sm\" }, md: { content: \"sm:max-w-md\" }, lg: { content: \"sm:max-w-2xl\" } },\n },\n defaultVariants: { placement: \"center\", size: \"md\" },\n});\nconst s = dialog();\n\nexport type DialogVariants = VariantProps<typeof dialog>;\n\nfunction CloseIcon() {\n return (\n <svg viewBox=\"0 0 24 24\" className=\"h-4 w-4\" fill=\"none\" stroke=\"currentColor\" strokeWidth=\"2\" strokeLinecap=\"round\" aria-hidden>\n <path d=\"M18 6 6 18M6 6l12 12\" />\n </svg>\n );\n}\n\ntype CloseButtonProps =\n | {\n /** The accessible name of the close button — passed translated. */\n closeLabel: string;\n /** Leaves the close button out (the content brings its own way out, or none: see `dismissible`). */\n hideClose?: false;\n }\n | { closeLabel?: string; hideClose: true };\n\nexport type DialogContentProps = React.ComponentProps<typeof DialogPrimitive.Content> &\n DialogVariants &\n CloseButtonProps & {\n /**\n * center · bottom (a sheet on a phone, centred from `sm` up) · right (a side panel, full height) · left (a\n * navigation drawer, full height).\n * @default \"center\"\n */\n placement?: DialogVariants[\"placement\"];\n /**\n * sm · md · lg: the width of the dialog.\n * @default \"md\"\n */\n size?: DialogVariants[\"size\"];\n /**\n * `false`: Escape and a click outside do not close it (a gate the user must answer: age, terms). It still closes\n * through `open` / `onOpenChange` and any `Dialog.Close` inside. Default `true`.\n */\n dismissible?: boolean;\n /** The element the portal renders into (default: document.body). */\n container?: HTMLElement | null;\n };\n\nconst prevent = (event: Event) => event.preventDefault();\n\n/** Radix's content, mounted only while open: it remembers the opener then and gives focus back on close (WCAG 2.4.3). */\nfunction ReturnFocusContent({ onCloseAutoFocus, ...props }: React.ComponentProps<typeof DialogPrimitive.Content>) {\n return <DialogPrimitive.Content onCloseAutoFocus={useReturnFocus(onCloseAutoFocus)} {...props} />;\n}\n\n/** The dialog itself, portalled over a dimmed overlay, with a close button. Give it a `Dialog.Title`. */\nexport function DialogContent({\n placement,\n size,\n closeLabel,\n hideClose,\n dismissible = true,\n container,\n className,\n children,\n onEscapeKeyDown,\n onPointerDownOutside,\n onInteractOutside,\n ...props\n}: DialogContentProps) {\n const v = dialog({ placement, size });\n return (\n <DialogPrimitive.Portal container={container}>\n <DialogPrimitive.Overlay className={v.overlay()} />\n <ReturnFocusContent\n data-placement={placement ?? \"center\"}\n data-dismissible={dismissible ? undefined : \"false\"}\n className={v.content({ className })}\n onEscapeKeyDown={dismissible ? onEscapeKeyDown : chain(onEscapeKeyDown, prevent)}\n onPointerDownOutside={dismissible ? onPointerDownOutside : chain(onPointerDownOutside, prevent)}\n onInteractOutside={dismissible ? onInteractOutside : chain(onInteractOutside, prevent)}\n {...props}\n >\n {children}\n {!hideClose && (\n <DialogPrimitive.Close asChild>\n <IconButton label={closeLabel as string} variant=\"ghost\" shape=\"pill\" className={v.close()}>\n <CloseIcon />\n </IconButton>\n </DialogPrimitive.Close>\n )}\n </ReturnFocusContent>\n </DialogPrimitive.Portal>\n );\n}\n\nfunction chain<E extends Event>(handler: ((event: E) => void) | undefined, then: (event: E) => void) {\n return (event: E) => {\n handler?.(event);\n then(event);\n };\n}\n\nexport function DialogHeader({ className, ...props }: React.ComponentProps<\"div\">) {\n return <div className={s.header({ className })} {...props} />;\n}\n\nexport function DialogTitle({ className, ...props }: React.ComponentProps<typeof DialogPrimitive.Title>) {\n return <DialogPrimitive.Title className={s.title({ className })} {...props} />;\n}\n\nexport function DialogDescription({ className, ...props }: React.ComponentProps<typeof DialogPrimitive.Description>) {\n return <DialogPrimitive.Description className={s.description({ className })} {...props} />;\n}\n\nexport function DialogBody({ className, ...props }: React.ComponentProps<\"div\">) {\n return <div className={s.body({ className })} {...props} />;\n}\n\nexport function DialogFooter({ className, ...props }: React.ComponentProps<\"div\">) {\n return <div className={s.footer({ className })} {...props} />;\n}\n\n/** `Dialog.Root/Trigger/Content/Header/Title/Description/Body/Footer/Close`. `open`/`defaultOpen` + `onOpenChange`. */\nexport const Dialog = {\n Root: DialogPrimitive.Root,\n Trigger: DialogPrimitive.Trigger,\n Close: DialogPrimitive.Close,\n Content: DialogContent,\n Header: DialogHeader,\n Title: DialogTitle,\n Description: DialogDescription,\n Body: DialogBody,\n Footer: DialogFooter,\n};\n\n/** `Omit` that keeps the close-button union (`closeLabel` required unless `hideClose`). */\ntype DistributiveOmit<T, K extends PropertyKey> = T extends unknown ? Omit<T, K> : never;\n\nexport type SheetProps = DistributiveOmit<DialogContentProps, \"placement\">;\n\n/** A sheet is a dialog anchored at the bottom (centred from `sm` up): `Dialog.Content placement=\"bottom\"`. */\nexport function Sheet(props: SheetProps) {\n return <DialogContent placement=\"bottom\" {...props} />;\n}\n","// Client. WCAG 2.4.3: when a dialog closes, focus goes back to what opened it. Radix only does it for `Dialog.Trigger`;\n// most app dialogs are controlled (`open` / `onOpenChange`) and opened by a plain button, so on Escape focus fell to\n// <body>. The content remembers the focused element when it mounts (it is still the opener: Radix moves focus in an\n// effect) and gives it back on close, unless the consumer's `onCloseAutoFocus` prevented the default.\nimport * as React from \"react\";\n\n/** The handler for `onCloseAutoFocus`: yours first, then focus back on the opener if it is still on the page. */\nexport function useReturnFocus(onCloseAutoFocus?: (event: Event) => void) {\n const [opener] = React.useState<Element | null>(() => (typeof document === \"undefined\" ? null : document.activeElement));\n return React.useCallback(\n (event: Event) => {\n onCloseAutoFocus?.(event);\n if (event.defaultPrevented) return;\n if (opener instanceof HTMLElement && opener !== document.body && opener.isConnected) {\n event.preventDefault();\n opener.focus();\n }\n },\n [opener, onCloseAutoFocus],\n );\n}\n","// Client (a portal). The moment two people choose each other — a match, a pair, a deal: a dialog in the brand\n// gradient, the two avatars meeting at a heart, the next step. The entrance plays once; still under reduced motion.\nimport * as React from \"react\";\n\nimport { Avatar } from \"../avatar\";\nimport { Button } from \"../button\";\nimport { Dialog } from \"../dialog\";\n\nexport type MatchDialogProps = {\n /** Shown (controlled). */\n open: boolean;\n /** Called when it closes. */\n onOpenChange: (open: boolean) => void;\n /** The headline (“It's a match!”) — passed translated; the dialog's name. */\n title: string;\n /** A line under it. */\n description?: string;\n /** The two people: avatar URLs and names. */\n people: readonly [{ src?: string | null; name: string }, { src?: string | null; name: string }];\n /** The main action (“Send a message”). */\n primaryLabel: string;\n /** What it does. */\n onPrimary: () => void;\n /** The way back (“Keep swiping”). */\n secondaryLabel: string;\n /** Where it is drawn (the page's body by default): give an element inside a brand scope (`.brand-…`) so the dialog wears the brand too. */\n container?: HTMLElement | null;\n};\n\n/** Two people choose each other: the avatars meet at a heart in the brand gradient, the next step under them. */\nexport function MatchDialog({ open, onOpenChange, title, description, people, primaryLabel, onPrimary, secondaryLabel, container }: MatchDialogProps) {\n return (\n <Dialog.Root open={open} onOpenChange={onOpenChange}>\n <Dialog.Content hideClose size=\"sm\" container={container} className=\"overflow-hidden border-0 bg-gradient-to-br from-accent to-accent-2 text-center text-on-accent\">\n <style href=\"krizaka-match\" precedence=\"default\">\n {\"@media (prefers-reduced-motion:no-preference){[data-kz-match] [data-side=a]{animation:kz-match-a .55s cubic-bezier(.3,1.6,.5,1) both}[data-kz-match] [data-side=b]{animation:kz-match-b .55s cubic-bezier(.3,1.6,.5,1) both}[data-kz-match] [data-heart]{animation:kz-match-heart .45s .25s cubic-bezier(.3,1.6,.5,1) both}}@keyframes kz-match-a{from{transform:translateX(-60px) rotate(-8deg);opacity:0}}@keyframes kz-match-b{from{transform:translateX(60px) rotate(8deg);opacity:0}}@keyframes kz-match-heart{from{transform:scale(0)}}\"}\n </style>\n <div data-kz-match=\"\" className=\"flex flex-col items-center gap-3 px-2 pb-2 pt-6\">\n <Dialog.Title className=\"font-display text-4xl font-black text-on-accent\">{title}</Dialog.Title>\n {description ? <Dialog.Description className=\"max-w-xs text-sm text-on-accent\">{description}</Dialog.Description> : null}\n <div className=\"relative my-6 flex h-36 w-64 items-center justify-center\" aria-hidden>\n <span data-side=\"a\" className=\"absolute left-6 -rotate-6 rounded-full ring-4 ring-on-accent\">\n <Avatar src={people[0].src ?? null} alt=\"\" fallback={people[0].name.charAt(0)} className=\"h-28 w-28 text-3xl\" />\n </span>\n <span data-side=\"b\" className=\"absolute right-6 rotate-6 rounded-full ring-4 ring-on-accent\">\n <Avatar src={people[1].src ?? null} alt=\"\" fallback={people[1].name.charAt(0)} className=\"h-28 w-28 text-3xl\" />\n </span>\n <span data-heart=\"\" className=\"absolute -bottom-1 flex h-12 w-12 items-center justify-center rounded-full bg-on-accent text-accent shadow-lg\">\n <svg viewBox=\"0 0 24 24\" className=\"h-6 w-6\" fill=\"currentColor\">\n <path d=\"M12 20s-7-4.4-7-10a4 4 0 0 1 7-2.6A4 4 0 0 1 19 10c0 5.6-7 10-7 10z\" />\n </svg>\n </span>\n </div>\n <div className=\"flex w-full flex-col gap-2\">\n <Button\n size=\"lg\"\n onClick={() => {\n onOpenChange(false);\n onPrimary();\n }}\n >\n {primaryLabel}\n </Button>\n <Dialog.Close asChild>\n <Button size=\"lg\" variant=\"ghost\" className=\"text-on-accent hover:bg-on-accent/15\">\n {secondaryLabel}\n </Button>\n </Dialog.Close>\n </div>\n </div>\n </Dialog.Content>\n </Dialog.Root>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;AAEA,SAAS,UAAU,uBAAuB;AAE1C,SAAS,UAA6B;;;ACAtC,YAAY,WAAW;AAGhB,SAAS,eAAe,kBAA2C;AACxE,QAAM,CAAC,MAAM,IAAU,eAAyB,MAAO,OAAO,aAAa,cAAc,OAAO,SAAS,aAAc;AACvH,SAAa;AAAA,IACX,CAAC,UAAiB;AAChB,yBAAmB,KAAK;AACxB,UAAI,MAAM,iBAAkB;AAC5B,UAAI,kBAAkB,eAAe,WAAW,SAAS,QAAQ,OAAO,aAAa;AACnF,cAAM,eAAe;AACrB,eAAO,MAAM;AAAA,MACf;AAAA,IACF;AAAA,IACA,CAAC,QAAQ,gBAAgB;AAAA,EAC3B;AACF;;;AD0BM,cA+DA,YA/DA;AArCC,IAAM,SAAS,GAAG;AAAA,EACvB,OAAO;AAAA,IACL,SAAS;AAAA,IACT,SACE;AAAA,IACF,OAAO;AAAA,IACP,QAAQ;AAAA,IACR,OAAO;AAAA,IACP,aAAa;AAAA,IACb,MAAM;AAAA,IACN,QACE;AAAA,EACJ;AAAA,EACA,UAAU;AAAA,IACR,WAAW;AAAA,MACT,QAAQ,EAAE,SAAS,kGAAkG;AAAA;AAAA,MAErH,QAAQ;AAAA,QACN,SACE;AAAA,MAEJ;AAAA,MACA,OAAO,EAAE,SAAS,8EAA8E;AAAA;AAAA,MAEhG,MAAM,EAAE,SAAS,4GAA4G;AAAA,IAC/H;AAAA,IACA,MAAM,EAAE,IAAI,EAAE,SAAS,cAAc,GAAG,IAAI,EAAE,SAAS,cAAc,GAAG,IAAI,EAAE,SAAS,eAAe,EAAE;AAAA,EAC1G;AA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BAAAA,KAAC,OAAO,OAAP,EAAa,SAAO,MACnB,0BAAAA,KAAC,UAAO,MAAK,MAAK,SAAQ,SAAQ,WAAU,wCACzC,0BACH,GACF;AAAA,SACF;AAAA,OACF;AAAA,KACF,GACF;AAEJ;","names":["jsx","jsxs"]}
|
|
1
|
+
{"version":3,"sources":["../src/dialog/dialog.tsx","../src/dialog/return-focus.ts","../src/match-dialog/match-dialog.tsx"],"sourcesContent":["// Client (a portal). Radix does the focus trap, the scroll lock, Escape, the outside click, aria-modal, the\n// aria-labelledby / aria-describedby wiring and the focus return: this file only holds the shape.\nimport { Dialog as DialogPrimitive } from \"radix-ui\";\nimport type * as React from \"react\";\nimport { tv, type VariantProps } from \"tailwind-variants\";\n\nimport { IconButton } from \"../button/button\";\nimport { useReturnFocus } from \"./return-focus\";\n\nexport const dialog = tv({\n slots: {\n overlay: \"kz-overlay fixed inset-0 z-50 bg-overlay\",\n content:\n \"kz-dialog fixed z-50 flex flex-col overflow-hidden border border-border-default bg-surface-1 text-fg shadow-lg focus:outline-hidden\",\n close: \"absolute right-3 top-3 h-9 w-9\",\n header: \"flex flex-col gap-1 px-5 pb-2 pr-14 pt-5\",\n title: \"text-base font-bold text-fg\",\n description: \"text-sm text-fg-secondary\",\n body: \"min-h-0 flex-1 overflow-y-auto px-5 pb-5\",\n footer:\n \"flex flex-wrap items-center justify-end gap-2 border-t border-border-subtle px-5 py-4 pb-[max(1rem,env(safe-area-inset-bottom))]\",\n },\n variants: {\n placement: {\n center: { content: \"left-1/2 top-1/2 max-h-[85dvh] w-[calc(100%-2rem)] -translate-x-1/2 -translate-y-1/2 rounded-xl\" },\n /* A sheet: anchored at the bottom on a phone, centred from `sm` up. */\n bottom: {\n content:\n \"inset-x-0 bottom-0 max-h-[92dvh] rounded-t-[1.75rem] sm:bottom-auto sm:left-1/2 sm:top-1/2 sm:w-full \" +\n \"sm:-translate-x-1/2 sm:-translate-y-1/2 sm:rounded-[1.75rem]\",\n },\n right: { content: \"inset-y-0 right-0 h-full w-full max-w-md rounded-none border-y-0 border-r-0\" },\n /* A navigation drawer: full height, from the left, clear of the notch. */\n left: { content: \"inset-y-0 left-0 h-full w-full max-w-md rounded-none border-y-0 border-l-0 pl-[env(safe-area-inset-left)]\" },\n },\n size: { sm: { content: \"sm:max-w-sm\" }, md: { content: \"sm:max-w-md\" }, lg: { content: \"sm:max-w-2xl\" } },\n },\n defaultVariants: { placement: \"center\", size: \"md\" },\n});\nconst s = dialog();\n\nexport type DialogVariants = VariantProps<typeof dialog>;\n\nfunction CloseIcon() {\n return (\n <svg viewBox=\"0 0 24 24\" className=\"h-4 w-4\" fill=\"none\" stroke=\"currentColor\" strokeWidth=\"2\" strokeLinecap=\"round\" aria-hidden>\n <path d=\"M18 6 6 18M6 6l12 12\" />\n </svg>\n );\n}\n\ntype CloseButtonProps =\n | {\n /** The accessible name of the close button — passed translated. */\n closeLabel: string;\n /** Leaves the close button out (the content brings its own way out, or none: see `dismissible`). */\n hideClose?: false;\n }\n | { closeLabel?: string; hideClose: true };\n\nexport type DialogContentProps = React.ComponentProps<typeof DialogPrimitive.Content> &\n DialogVariants &\n CloseButtonProps & {\n /**\n * center · bottom (a sheet on a phone, centred from `sm` up) · right (a side panel, full height) · left (a\n * navigation drawer, full height).\n * @default \"center\"\n */\n placement?: DialogVariants[\"placement\"];\n /**\n * sm · md · lg: the width of the dialog.\n * @default \"md\"\n */\n size?: DialogVariants[\"size\"];\n /**\n * `false`: Escape and a click outside do not close it (a gate the user must answer: age, terms). It still closes\n * through `open` / `onOpenChange` and any `Dialog.Close` inside. Default `true`.\n */\n dismissible?: boolean;\n /** The element the portal renders into (default: document.body). */\n container?: HTMLElement | null;\n };\n\nconst prevent = (event: Event) => event.preventDefault();\n\n/** Radix's content, mounted only while open: it remembers the opener then and gives focus back on close (WCAG 2.4.3). */\nfunction ReturnFocusContent({ onCloseAutoFocus, ...props }: React.ComponentProps<typeof DialogPrimitive.Content>) {\n return <DialogPrimitive.Content onCloseAutoFocus={useReturnFocus(onCloseAutoFocus)} {...props} />;\n}\n\n/** The dialog itself, portalled over a dimmed overlay, with a close button. Give it a `Dialog.Title`. */\nexport function DialogContent({\n placement,\n size,\n closeLabel,\n hideClose,\n dismissible = true,\n container,\n className,\n children,\n onEscapeKeyDown,\n onPointerDownOutside,\n onInteractOutside,\n ...props\n}: DialogContentProps) {\n const v = dialog({ placement, size });\n return (\n <DialogPrimitive.Portal container={container}>\n <DialogPrimitive.Overlay className={v.overlay()} />\n <ReturnFocusContent\n data-placement={placement ?? \"center\"}\n data-dismissible={dismissible ? undefined : \"false\"}\n className={v.content({ className })}\n onEscapeKeyDown={dismissible ? onEscapeKeyDown : chain(onEscapeKeyDown, prevent)}\n onPointerDownOutside={dismissible ? onPointerDownOutside : chain(onPointerDownOutside, prevent)}\n onInteractOutside={dismissible ? onInteractOutside : chain(onInteractOutside, prevent)}\n {...props}\n >\n {children}\n {!hideClose && (\n <DialogPrimitive.Close asChild>\n <IconButton label={closeLabel as string} variant=\"ghost\" shape=\"pill\" className={v.close()}>\n <CloseIcon />\n </IconButton>\n </DialogPrimitive.Close>\n )}\n </ReturnFocusContent>\n </DialogPrimitive.Portal>\n );\n}\n\nfunction chain<E extends Event>(handler: ((event: E) => void) | undefined, then: (event: E) => void) {\n return (event: E) => {\n handler?.(event);\n then(event);\n };\n}\n\nexport function DialogHeader({ className, ...props }: React.ComponentProps<\"div\">) {\n return <div className={s.header({ className })} {...props} />;\n}\n\nexport function DialogTitle({ className, ...props }: React.ComponentProps<typeof DialogPrimitive.Title>) {\n return <DialogPrimitive.Title className={s.title({ className })} {...props} />;\n}\n\nexport function DialogDescription({ className, ...props }: React.ComponentProps<typeof DialogPrimitive.Description>) {\n return <DialogPrimitive.Description className={s.description({ className })} {...props} />;\n}\n\nexport function DialogBody({ className, ...props }: React.ComponentProps<\"div\">) {\n return <div className={s.body({ className })} {...props} />;\n}\n\nexport function DialogFooter({ className, ...props }: React.ComponentProps<\"div\">) {\n return <div className={s.footer({ className })} {...props} />;\n}\n\n/** `Dialog.Root/Trigger/Content/Header/Title/Description/Body/Footer/Close`. `open`/`defaultOpen` + `onOpenChange`. */\nexport const Dialog = {\n Root: DialogPrimitive.Root,\n Trigger: DialogPrimitive.Trigger,\n Close: DialogPrimitive.Close,\n Content: DialogContent,\n Header: DialogHeader,\n Title: DialogTitle,\n Description: DialogDescription,\n Body: DialogBody,\n Footer: DialogFooter,\n};\n\n/** `Omit` that keeps the close-button union (`closeLabel` required unless `hideClose`). */\ntype DistributiveOmit<T, K extends PropertyKey> = T extends unknown ? Omit<T, K> : never;\n\nexport type SheetProps = DistributiveOmit<DialogContentProps, \"placement\">;\n\n/** A sheet is a dialog anchored at the bottom (centred from `sm` up): `Dialog.Content placement=\"bottom\"`. */\nexport function Sheet(props: SheetProps) {\n return <DialogContent placement=\"bottom\" {...props} />;\n}\n","// Client. WCAG 2.4.3: when a dialog closes, focus goes back to what opened it. Radix only does it for `Dialog.Trigger`;\n// most app dialogs are controlled (`open` / `onOpenChange`) and opened by a plain button, so on Escape focus fell to\n// <body>. The content remembers the focused element when it mounts (it is still the opener: Radix moves focus in an\n// effect) and gives it back on close, unless the consumer's `onCloseAutoFocus` prevented the default.\nimport * as React from \"react\";\n\n/** The handler for `onCloseAutoFocus`: yours first, then focus back on the opener if it is still on the page. */\nexport function useReturnFocus(onCloseAutoFocus?: (event: Event) => void) {\n const [opener] = React.useState<Element | null>(() => (typeof document === \"undefined\" ? null : document.activeElement));\n return React.useCallback(\n (event: Event) => {\n onCloseAutoFocus?.(event);\n if (event.defaultPrevented) return;\n if (opener instanceof HTMLElement && opener !== document.body && opener.isConnected) {\n event.preventDefault();\n opener.focus();\n }\n },\n [opener, onCloseAutoFocus],\n );\n}\n","// Client (a portal). The moment two people choose each other — a match, a pair, a deal: a dialog in the brand\n// gradient, the two avatars meeting at a heart, the next step. The entrance plays once; still under reduced motion.\nimport * as React from \"react\";\n\nimport { Avatar } from \"../avatar\";\nimport { Button } from \"../button\";\nimport { Dialog } from \"../dialog\";\n\nexport type MatchDialogProps = {\n /** Shown (controlled). */\n open: boolean;\n /** Called when it closes. */\n onOpenChange: (open: boolean) => void;\n /** The headline (“It's a match!”) — passed translated; the dialog's name. */\n title: string;\n /** A line under it. */\n description?: string;\n /** The two people: avatar URLs and names. */\n people: readonly [{ src?: string | null; name: string }, { src?: string | null; name: string }];\n /** The main action (“Send a message”). */\n primaryLabel: string;\n /** What it does. */\n onPrimary: () => void;\n /** The way back (“Keep swiping”). */\n secondaryLabel: string;\n /** Where it is drawn (the page's body by default): give an element inside a brand scope (`.brand-…`) so the dialog wears the brand too. */\n container?: HTMLElement | null;\n};\n\n/** Two people choose each other: the avatars meet at a heart in the brand gradient, the next step under them. */\nexport function MatchDialog({ open, onOpenChange, title, description, people, primaryLabel, onPrimary, secondaryLabel, container }: MatchDialogProps) {\n return (\n <Dialog.Root open={open} onOpenChange={onOpenChange}>\n <Dialog.Content hideClose size=\"sm\" container={container} className=\"overflow-hidden border-0 bg-gradient-to-br from-accent to-accent-2 text-center text-on-accent\">\n <style href=\"krizaka-match\" precedence=\"default\">\n {\"@media (prefers-reduced-motion:no-preference){[data-kz-match] [data-side=a]{animation:kz-match-a .55s cubic-bezier(.3,1.6,.5,1) both}[data-kz-match] [data-side=b]{animation:kz-match-b .55s cubic-bezier(.3,1.6,.5,1) both}[data-kz-match] [data-heart]{animation:kz-match-heart .45s .25s cubic-bezier(.3,1.6,.5,1) both}}@keyframes kz-match-a{from{transform:translateX(-60px) rotate(-8deg);opacity:0}}@keyframes kz-match-b{from{transform:translateX(60px) rotate(8deg);opacity:0}}@keyframes kz-match-heart{from{transform:scale(0)}}\"}\n </style>\n <div data-kz-match=\"\" className=\"flex flex-col items-center gap-3 px-2 pb-2 pt-6\">\n <Dialog.Title className=\"font-display text-4xl font-black text-on-accent\">{title}</Dialog.Title>\n {description ? <Dialog.Description className=\"max-w-xs text-sm text-on-accent\">{description}</Dialog.Description> : null}\n <div className=\"relative my-6 flex h-36 w-64 items-center justify-center\" aria-hidden>\n <span data-side=\"a\" className=\"absolute left-6 -rotate-6 rounded-full ring-4 ring-on-accent\">\n <Avatar src={people[0].src ?? null} alt=\"\" fallback={people[0].name.charAt(0)} className=\"h-28 w-28 text-3xl\" />\n </span>\n <span data-side=\"b\" className=\"absolute right-6 rotate-6 rounded-full ring-4 ring-on-accent\">\n <Avatar src={people[1].src ?? null} alt=\"\" fallback={people[1].name.charAt(0)} className=\"h-28 w-28 text-3xl\" />\n </span>\n <span data-heart=\"\" className=\"absolute -bottom-1 flex h-12 w-12 items-center justify-center rounded-full bg-on-accent text-accent shadow-lg\">\n <svg viewBox=\"0 0 24 24\" className=\"h-6 w-6\" fill=\"currentColor\">\n <path d=\"M12 20s-7-4.4-7-10a4 4 0 0 1 7-2.6A4 4 0 0 1 19 10c0 5.6-7 10-7 10z\" />\n </svg>\n </span>\n </div>\n <div className=\"flex w-full flex-col gap-2\">\n <Button\n size=\"lg\"\n onClick={() => {\n onOpenChange(false);\n onPrimary();\n }}\n >\n {primaryLabel}\n </Button>\n <Dialog.Close asChild>\n <Button size=\"lg\" variant=\"ghost\" className=\"text-on-accent hover:bg-on-accent/15\">\n {secondaryLabel}\n </Button>\n </Dialog.Close>\n </div>\n </div>\n </Dialog.Content>\n </Dialog.Root>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;AAEA,SAAS,UAAU,uBAAuB;AAE1C,SAAS,UAA6B;;;ACAtC,YAAY,WAAW;AAGhB,SAAS,eAAe,kBAA2C;AACxE,QAAM,CAAC,MAAM,IAAU,eAAyB,MAAO,OAAO,aAAa,cAAc,OAAO,SAAS,aAAc;AACvH,SAAa;AAAA,IACX,CAAC,UAAiB;AAChB,yBAAmB,KAAK;AACxB,UAAI,MAAM,iBAAkB;AAC5B,UAAI,kBAAkB,eAAe,WAAW,SAAS,QAAQ,OAAO,aAAa;AACnF,cAAM,eAAe;AACrB,eAAO,MAAM;AAAA,MACf;AAAA,IACF;AAAA,IACA,CAAC,QAAQ,g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WAAU,sBAAqB,GAChH;AAAA,QACA,gBAAAA,KAAC,UAAK,aAAU,KAAI,WAAU,gEAC5B,0BAAAA,KAAC,UAAO,KAAK,OAAO,CAAC,EAAE,OAAO,MAAM,KAAI,IAAG,UAAU,OAAO,CAAC,EAAE,KAAK,OAAO,CAAC,GAAG,WAAU,sBAAqB,GAChH;AAAA,QACA,gBAAAA,KAAC,UAAK,cAAW,IAAG,WAAU,iHAC5B,0BAAAA,KAAC,SAAI,SAAQ,aAAY,WAAU,WAAU,MAAK,gBAChD,0BAAAA,KAAC,UAAK,GAAE,uEAAsE,GAChF,GACF;AAAA,SACF;AAAA,MACA,gBAAAC,MAAC,SAAI,WAAU,8BACb;AAAA,wBAAAD;AAAA,UAAC;AAAA;AAAA,YACC,MAAK;AAAA,YACL,SAAS,MAAM;AACb,2BAAa,KAAK;AAClB,wBAAU;AAAA,YACZ;AAAA,YAEC;AAAA;AAAA,QACH;AAAA,QACA,gBAAAA,KAAC,OAAO,OAAP,EAAa,SAAO,MACnB,0BAAAA,KAAC,UAAO,MAAK,MAAK,SAAQ,SAAQ,WAAU,wCACzC,0BACH,GACF;AAAA,SACF;AAAA,OACF;AAAA,KACF,GACF;AAEJ;","names":["jsx","jsxs"]}
|
package/dist/meter.js
CHANGED
|
@@ -96,7 +96,7 @@ function Meter({
|
|
|
96
96
|
function MeterValue({ value, caption }) {
|
|
97
97
|
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
98
98
|
/* @__PURE__ */ jsx("span", { className: "font-display text-lg font-semibold text-fg tabular-nums", children: value }),
|
|
99
|
-
caption && /* @__PURE__ */ jsx("span", { className: "text-[10px]
|
|
99
|
+
caption && /* @__PURE__ */ jsx("span", { className: "text-[10px] text-fg-secondary", children: caption })
|
|
100
100
|
] });
|
|
101
101
|
}
|
|
102
102
|
export {
|