@krizaka/ui 3.4.0 → 3.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -0
- package/dist/app-shell.d.ts +24 -22
- package/dist/app-shell.js +9 -3
- package/dist/app-shell.js.map +1 -1
- package/dist/argument-card.js +3 -3
- package/dist/chat.d.ts +187 -0
- package/dist/chat.js +132 -0
- package/dist/chat.js.map +1 -0
- package/dist/chunk-3GODX3D6.js +25 -0
- package/dist/chunk-3GODX3D6.js.map +1 -0
- package/dist/chunk-ECSCA3CN.js +128 -0
- package/dist/chunk-ECSCA3CN.js.map +1 -0
- package/dist/chunk-F2GKFIYK.js +47 -0
- package/dist/chunk-F2GKFIYK.js.map +1 -0
- package/dist/{chunk-R6SDS7JM.js → chunk-ND3L5VHT.js} +25 -2
- package/dist/chunk-ND3L5VHT.js.map +1 -0
- package/dist/command.js +1 -1
- package/dist/data-table.js +20 -134
- package/dist/data-table.js.map +1 -1
- package/dist/dialog.js +7 -3
- package/dist/dialog.js.map +1 -1
- package/dist/loader.d.ts +21 -1
- package/dist/loader.js +7 -3
- package/dist/loader.js.map +1 -1
- package/dist/map.js +7 -1
- package/dist/map.js.map +1 -1
- package/dist/marketing-layout.d.ts +3 -9
- package/dist/marketing-layout.js +24 -7
- package/dist/marketing-layout.js.map +1 -1
- package/dist/match-dialog.d.ts +32 -0
- package/dist/match-dialog.js +168 -0
- package/dist/match-dialog.js.map +1 -0
- package/dist/native.d.ts +484 -106
- package/dist/native.js +1967 -1323
- package/dist/native.js.map +1 -1
- package/dist/page-hero.js +3 -3
- package/dist/photo-grid.d.ts +122 -0
- package/dist/photo-grid.js +94 -0
- package/dist/photo-grid.js.map +1 -0
- package/dist/skip-link.d.ts +15 -0
- package/dist/skip-link.js +10 -0
- package/dist/skip-link.js.map +1 -0
- package/dist/step-progress.d.ts +20 -0
- package/dist/step-progress.js +17 -0
- package/dist/step-progress.js.map +1 -0
- package/dist/swipe-deck.d.ts +183 -0
- package/dist/swipe-deck.js +144 -0
- package/dist/swipe-deck.js.map +1 -0
- package/dist/tag-selector.d.ts +26 -0
- package/dist/tag-selector.js +21 -0
- package/dist/tag-selector.js.map +1 -0
- package/dist/tree-view.d.ts +2 -0
- package/dist/tree-view.js.map +1 -1
- package/dist/verified-badge.d.ts +16 -0
- package/dist/verified-badge.js +23 -0
- package/dist/verified-badge.js.map +1 -0
- package/package.json +120 -8
- package/registry/achievement.json +2 -1
- package/registry/action-bar.json +2 -1
- package/registry/action-sheet.json +1 -0
- package/registry/activity-feed.json +2 -1
- package/registry/alert.json +2 -1
- package/registry/app-shell.json +27 -5
- package/registry/argument-card.json +2 -1
- package/registry/audio-player.json +2 -1
- package/registry/auth-layout.json +7 -2
- package/registry/avatar.json +2 -1
- package/registry/badge.json +2 -1
- package/registry/button.json +2 -1
- package/registry/card-grid.json +2 -1
- package/registry/card.json +2 -1
- package/registry/catalogue-page.json +5 -2
- package/registry/changelog-page.json +5 -2
- package/registry/chat.json +918 -0
- package/registry/checkbox.json +2 -1
- package/registry/chip-link.json +2 -1
- package/registry/chip.json +2 -1
- package/registry/choice-grid.json +2 -1
- package/registry/cn.json +1 -0
- package/registry/code-block.json +2 -1
- package/registry/combobox.json +2 -1
- package/registry/command.json +2 -1
- package/registry/component-page.json +5 -2
- package/registry/confirm-button.json +2 -1
- package/registry/contact-page.json +5 -2
- package/registry/continue-prompt.json +2 -1
- package/registry/countdown.json +2 -1
- package/registry/cta-panel.json +2 -1
- package/registry/dashboard-layout.json +5 -2
- package/registry/data-table.json +2 -1
- package/registry/date-picker.json +3 -2
- package/registry/decision-list.json +2 -1
- package/registry/description-list.json +2 -1
- package/registry/detail-layout.json +16 -2
- package/registry/dialog.json +10 -4
- package/registry/docs-article-page.json +16 -2
- package/registry/docs-hub-page.json +5 -2
- package/registry/docs-layout.json +2 -1
- package/registry/dropdown-menu.json +2 -1
- package/registry/empty-state.json +14 -2
- package/registry/error-page.json +5 -2
- package/registry/examples/chat/conversation.d.ts +4 -0
- package/registry/examples/chat/conversation.js +22 -0
- package/registry/examples/chat/conversation.tsx +21 -0
- package/registry/examples/chat/inbox.d.ts +4 -0
- package/registry/examples/chat/inbox.js +15 -0
- package/registry/examples/chat/inbox.tsx +12 -0
- package/registry/examples/chat/native/conversation.d.ts +4 -0
- package/registry/examples/chat/native/conversation.dark.png +0 -0
- package/registry/examples/chat/native/conversation.js +23 -0
- package/registry/examples/chat/native/conversation.light.png +0 -0
- package/registry/examples/chat/native/conversation.tsx +20 -0
- package/registry/examples/chat/native/inbox.d.ts +4 -0
- package/registry/examples/chat/native/inbox.dark.png +0 -0
- package/registry/examples/chat/native/inbox.js +16 -0
- package/registry/examples/chat/native/inbox.light.png +0 -0
- package/registry/examples/chat/native/inbox.tsx +13 -0
- package/registry/examples/detail-layout/checkout.d.ts +4 -0
- package/registry/examples/detail-layout/checkout.js +37 -0
- package/registry/examples/detail-layout/checkout.tsx +44 -0
- package/registry/examples/docs-article-page/faq.d.ts +4 -0
- package/registry/examples/docs-article-page/faq.js +31 -0
- package/registry/examples/docs-article-page/faq.tsx +40 -0
- package/registry/examples/empty-state/library.d.ts +4 -0
- package/registry/examples/empty-state/library.js +25 -0
- package/registry/examples/empty-state/library.tsx +20 -0
- package/registry/examples/loader/branded.d.ts +4 -0
- package/registry/examples/loader/branded.js +12 -0
- package/registry/examples/loader/branded.tsx +7 -0
- package/registry/examples/loader/native/branded.d.ts +4 -0
- package/registry/examples/loader/native/branded.dark.png +0 -0
- package/registry/examples/loader/native/branded.js +12 -0
- package/registry/examples/loader/native/branded.light.png +0 -0
- package/registry/examples/loader/native/branded.tsx +11 -0
- package/registry/examples/longform-page/case-study.d.ts +4 -0
- package/registry/examples/longform-page/case-study.js +41 -0
- package/registry/examples/longform-page/case-study.tsx +40 -0
- package/registry/examples/match-dialog/its-a-match.d.ts +4 -0
- package/registry/examples/match-dialog/its-a-match.js +29 -0
- package/registry/examples/match-dialog/its-a-match.tsx +25 -0
- package/registry/examples/match-dialog/native/its-a-match.d.ts +4 -0
- package/registry/examples/match-dialog/native/its-a-match.dark.png +0 -0
- package/registry/examples/match-dialog/native/its-a-match.js +28 -0
- package/registry/examples/match-dialog/native/its-a-match.light.png +0 -0
- package/registry/examples/match-dialog/native/its-a-match.tsx +22 -0
- package/registry/examples/photo-grid/native/profile-photos.d.ts +4 -0
- package/registry/examples/photo-grid/native/profile-photos.dark.png +0 -0
- package/registry/examples/photo-grid/native/profile-photos.js +27 -0
- package/registry/examples/photo-grid/native/profile-photos.light.png +0 -0
- package/registry/examples/photo-grid/native/profile-photos.tsx +24 -0
- package/registry/examples/photo-grid/profile-photos.d.ts +4 -0
- package/registry/examples/photo-grid/profile-photos.js +28 -0
- package/registry/examples/photo-grid/profile-photos.tsx +25 -0
- package/registry/examples/pull-to-refresh/native/branded.d.ts +4 -0
- package/registry/examples/pull-to-refresh/native/branded.dark.png +0 -0
- package/registry/examples/pull-to-refresh/native/branded.js +14 -0
- package/registry/examples/pull-to-refresh/native/branded.light.png +0 -0
- package/registry/examples/pull-to-refresh/native/branded.tsx +23 -0
- package/registry/examples/screen/native/app-shell.d.ts +4 -0
- package/registry/examples/screen/native/app-shell.dark.png +0 -0
- package/registry/examples/screen/native/app-shell.js +25 -0
- package/registry/examples/screen/native/app-shell.light.png +0 -0
- package/registry/examples/screen/native/app-shell.tsx +33 -0
- package/registry/examples/screen/native/auth.d.ts +4 -0
- package/registry/examples/screen/native/auth.dark.png +0 -0
- package/registry/examples/screen/native/auth.js +24 -0
- package/registry/examples/screen/native/auth.light.png +0 -0
- package/registry/examples/screen/native/auth.tsx +20 -0
- package/registry/examples/screen/native/chat.d.ts +4 -0
- package/registry/examples/screen/native/chat.dark.png +0 -0
- package/registry/examples/screen/native/chat.js +27 -0
- package/registry/examples/screen/native/chat.light.png +0 -0
- package/registry/examples/screen/native/chat.tsx +22 -0
- package/registry/examples/screen/native/feed.d.ts +4 -0
- package/registry/examples/screen/native/feed.dark.png +0 -0
- package/registry/examples/screen/native/feed.js +24 -0
- package/registry/examples/screen/native/feed.light.png +0 -0
- package/registry/examples/screen/native/feed.tsx +34 -0
- package/registry/examples/screen/native/map.d.ts +4 -0
- package/registry/examples/screen/native/map.dark.png +0 -0
- package/registry/examples/screen/native/map.js +26 -0
- package/registry/examples/screen/native/map.light.png +0 -0
- package/registry/examples/screen/native/map.tsx +31 -0
- package/registry/examples/screen/native/notifications.d.ts +4 -0
- package/registry/examples/screen/native/notifications.dark.png +0 -0
- package/registry/examples/screen/native/notifications.js +21 -0
- package/registry/examples/screen/native/notifications.light.png +0 -0
- package/registry/examples/screen/native/notifications.tsx +21 -0
- package/registry/examples/screen/native/profile.d.ts +4 -0
- package/registry/examples/screen/native/profile.dark.png +0 -0
- package/registry/examples/screen/native/profile.js +29 -0
- package/registry/examples/screen/native/profile.light.png +0 -0
- package/registry/examples/screen/native/profile.tsx +27 -0
- package/registry/examples/screen/native/settings.d.ts +4 -0
- package/registry/examples/screen/native/settings.dark.png +0 -0
- package/registry/examples/screen/native/settings.js +20 -0
- package/registry/examples/screen/native/settings.light.png +0 -0
- package/registry/examples/screen/native/settings.tsx +19 -0
- package/registry/examples/skip-link/default.d.ts +4 -0
- package/registry/examples/skip-link/default.js +19 -0
- package/registry/examples/skip-link/default.tsx +12 -0
- package/registry/examples/splash-handoff/native/default.d.ts +4 -0
- package/registry/examples/splash-handoff/native/default.dark.png +0 -0
- package/registry/examples/splash-handoff/native/default.js +12 -0
- package/registry/examples/splash-handoff/native/default.light.png +0 -0
- package/registry/examples/splash-handoff/native/default.tsx +11 -0
- package/registry/examples/split-view/nearby.d.ts +4 -0
- package/registry/examples/split-view/nearby.js +33 -0
- package/registry/examples/split-view/nearby.tsx +45 -0
- package/registry/examples/split-view/notifications.d.ts +4 -0
- package/registry/examples/split-view/notifications.js +33 -0
- package/registry/examples/split-view/notifications.tsx +31 -0
- package/registry/examples/status-page/maintenance.d.ts +4 -0
- package/registry/examples/status-page/maintenance.js +29 -0
- package/registry/examples/status-page/maintenance.tsx +24 -0
- package/registry/examples/step-progress/native/sign-up.d.ts +4 -0
- package/registry/examples/step-progress/native/sign-up.dark.png +0 -0
- package/registry/examples/step-progress/native/sign-up.js +12 -0
- package/registry/examples/step-progress/native/sign-up.light.png +0 -0
- package/registry/examples/step-progress/native/sign-up.tsx +11 -0
- package/registry/examples/step-progress/sign-up.d.ts +4 -0
- package/registry/examples/step-progress/sign-up.js +22 -0
- package/registry/examples/step-progress/sign-up.tsx +16 -0
- package/registry/examples/swipe-deck/discover.d.ts +4 -0
- package/registry/examples/swipe-deck/discover.js +41 -0
- package/registry/examples/swipe-deck/discover.tsx +37 -0
- package/registry/examples/swipe-deck/native/discover.d.ts +4 -0
- package/registry/examples/swipe-deck/native/discover.dark.png +0 -0
- package/registry/examples/swipe-deck/native/discover.js +39 -0
- package/registry/examples/swipe-deck/native/discover.light.png +0 -0
- package/registry/examples/swipe-deck/native/discover.tsx +35 -0
- package/registry/examples/tag-selector/interests.d.ts +4 -0
- package/registry/examples/tag-selector/interests.js +14 -0
- package/registry/examples/tag-selector/interests.tsx +12 -0
- package/registry/examples/tag-selector/native/interests.d.ts +4 -0
- package/registry/examples/tag-selector/native/interests.dark.png +0 -0
- package/registry/examples/tag-selector/native/interests.js +15 -0
- package/registry/examples/tag-selector/native/interests.light.png +0 -0
- package/registry/examples/tag-selector/native/interests.tsx +15 -0
- package/registry/examples/verified-badge/native/verified.d.ts +4 -0
- package/registry/examples/verified-badge/native/verified.dark.png +0 -0
- package/registry/examples/verified-badge/native/verified.js +18 -0
- package/registry/examples/verified-badge/native/verified.light.png +0 -0
- package/registry/examples/verified-badge/native/verified.tsx +15 -0
- package/registry/examples/verified-badge/verified.d.ts +4 -0
- package/registry/examples/verified-badge/verified.js +17 -0
- package/registry/examples/verified-badge/verified.tsx +13 -0
- package/registry/fab.json +1 -0
- package/registry/field.json +2 -1
- package/registry/file-upload.json +3 -2
- package/registry/filter-bar.json +2 -1
- package/registry/form.json +3 -2
- package/registry/gallery-page.json +5 -2
- package/registry/glow-card.json +2 -1
- package/registry/goal-gauge.json +2 -1
- package/registry/header.json +1 -0
- package/registry/how-it-works-page.json +5 -2
- package/registry/image-cropper.json +2 -1
- package/registry/image-viewer.json +1 -0
- package/registry/index.json +608 -19
- package/registry/iso.json +2 -1
- package/registry/kanban.json +2 -1
- package/registry/kbd.json +2 -1
- package/registry/landing-page.json +5 -2
- package/registry/landscape.json +2 -1
- package/registry/legal-page.json +5 -2
- package/registry/link-card.json +2 -1
- package/registry/list.json +2 -1
- package/registry/loader.json +47 -3
- package/registry/longform-page.json +16 -2
- package/registry/map.json +4 -3
- package/registry/marketing-layout.json +13 -4
- package/registry/marquee.json +2 -1
- package/registry/mascot-quote.json +2 -1
- package/registry/mascot-state.json +2 -1
- package/registry/mascots.json +2 -1
- package/registry/match-dialog.json +315 -0
- package/registry/media-capture.json +2 -1
- package/registry/media-picker.json +1 -0
- package/registry/meter.json +2 -1
- package/registry/nav-bar.json +2 -1
- package/registry/number-ticker.json +2 -1
- package/registry/onboarding.json +1 -0
- package/registry/otp-input.json +1 -0
- package/registry/page-header.json +2 -1
- package/registry/page-hero.json +2 -1
- package/registry/page.json +2 -1
- package/registry/pagination.json +2 -1
- package/registry/permission-prompt.json +1 -0
- package/registry/photo-grid.json +303 -0
- package/registry/pointer-light.json +2 -1
- package/registry/popover.json +2 -1
- package/registry/pricing-page.json +5 -2
- package/registry/product-page.json +5 -2
- package/registry/profile-card.json +2 -1
- package/registry/progress.json +2 -1
- package/registry/promise-card.json +2 -1
- package/registry/pull-to-refresh.json +68 -4
- package/registry/radio-group.json +2 -1
- package/registry/screen.json +233 -0
- package/registry/scroll-stage.json +2 -1
- package/registry/search-field.json +2 -1
- package/registry/section-backdrop.json +2 -1
- package/registry/segmented.json +1 -0
- package/registry/separator.json +2 -1
- package/registry/settings-layout.json +5 -2
- package/registry/skeleton.json +2 -1
- package/registry/skip-link.json +122 -0
- package/registry/slider.json +2 -1
- package/registry/slot.json +2 -1
- package/registry/spinner.json +2 -1
- package/registry/splash-handoff.json +138 -0
- package/registry/split-view.json +27 -2
- package/registry/stage-banner.json +2 -1
- package/registry/stat.json +2 -1
- package/registry/status-page.json +18 -2
- package/registry/step-progress.json +256 -0
- package/registry/stepper.json +2 -1
- package/registry/swipe-deck.json +513 -0
- package/registry/swipeable-row.json +1 -0
- package/registry/switch.json +2 -1
- package/registry/tab-bar.json +1 -0
- package/registry/tabs.json +2 -1
- package/registry/tag-input.json +2 -1
- package/registry/tag-selector.json +277 -0
- package/registry/terminal-replay.json +2 -1
- package/registry/theme.json +2 -1
- package/registry/toast.json +2 -1
- package/registry/toc.json +2 -1
- package/registry/tooltip.json +2 -1
- package/registry/tree-view.json +10 -4
- package/registry/txt.json +1 -0
- package/registry/verified-badge.json +203 -0
- package/registry/video-player.json +2 -1
- package/registry/video-trimmer.json +2 -1
- package/registry/virtual.json +2 -1
- package/dist/chunk-R6SDS7JM.js.map +0 -1
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
// registry/examples/screen/native/profile.tsx
|
|
4
|
+
import { Avatar, Button, Chip, Screen, Txt, VerifiedBadge } from "@krizaka/ui/native";
|
|
5
|
+
import { View } from "react-native";
|
|
6
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
7
|
+
function NativeScreenProfile() {
|
|
8
|
+
return /* @__PURE__ */ jsx(View, { style: { width: 360, height: 640 }, children: /* @__PURE__ */ jsxs(Screen, { footer: /* @__PURE__ */ jsxs(View, { style: { flexDirection: "row", gap: 8, padding: 16 }, children: [
|
|
9
|
+
/* @__PURE__ */ jsx(Button, { label: "Edit profile", style: { flex: 1 } }),
|
|
10
|
+
/* @__PURE__ */ jsx(Button, { label: "Preview", variant: "outline", style: { flex: 1 } })
|
|
11
|
+
] }), children: [
|
|
12
|
+
/* @__PURE__ */ jsxs(View, { style: { alignItems: "center", gap: 6 }, children: [
|
|
13
|
+
/* @__PURE__ */ jsx(Avatar, { src: "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAwAAAAQCAIAAACtAwlQAAABaklEQVR42mWMy24UQQxF7arqlwLhIbJhwZZf5I/4IISEBIsIRSKTMOmZnp7uqrJ9zYIeIeCsrqzjw+vHDwYCCM6wbfy5gABKatsysJqLuoHciZ2dGE4ApSrbnyidVn06lVyQUrweur5pmAJAqVQGSEGnRb79mD5/H6dzuRq6929fv7t5MTSd+6VUK3Zj/XQ7frkblyJ926jwkIab6yZw3Eq58rzaz6nMq1RVA+3nMmd73nMMfCkJiRBA7u5O7g6QCFfhyLyVRJg89U3bxKiGJsQ+te6pCge+lETYPT3rujalotqkNLSdexRhJk6lshjOWXeH+WE6Z1HAi+p+Pr+czuxtG0PKlZesd+P09f5xd5iKqrlX1cfpGCiqhDdXr9Ja8DSX24f9/eG4VDGAiAzIIrvpwJ6C96FUXrId15Ivxm8MKCpzKUvRUCpXJTOHO/2Nu6uhqocqLMr4V9iAkxoHMzZjgP7XnMjBZvQLMEROG5iV3IMAAAAASUVORK5CYII=", alt: "Elena", size: 112, ring: "story" }),
|
|
14
|
+
/* @__PURE__ */ jsxs(View, { style: { flexDirection: "row", alignItems: "center", gap: 6 }, children: [
|
|
15
|
+
/* @__PURE__ */ jsx(Txt, { variant: "title", children: "Elena, 29" }),
|
|
16
|
+
/* @__PURE__ */ jsx(VerifiedBadge, { label: "Verified", size: 18 })
|
|
17
|
+
] }),
|
|
18
|
+
/* @__PURE__ */ jsx(Txt, { tone: "secondary", children: "Lisbon \xB7 Sound engineer" })
|
|
19
|
+
] }),
|
|
20
|
+
/* @__PURE__ */ jsxs(View, { style: { flexDirection: "row", justifyContent: "center", gap: 32 }, children: [
|
|
21
|
+
/* @__PURE__ */ jsx(Txt, { variant: "label", children: "128 likes" }),
|
|
22
|
+
/* @__PURE__ */ jsx(Txt, { variant: "label", children: "14 matches" })
|
|
23
|
+
] }),
|
|
24
|
+
/* @__PURE__ */ jsx(View, { style: { flexDirection: "row", flexWrap: "wrap", gap: 8 }, children: ["Music", "Surf", "Travel", "Vinyl"].map((t) => /* @__PURE__ */ jsx(Chip, { children: t }, t)) })
|
|
25
|
+
] }) });
|
|
26
|
+
}
|
|
27
|
+
export {
|
|
28
|
+
NativeScreenProfile as default
|
|
29
|
+
};
|
|
Binary file
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { Avatar, Button, Chip, Screen, Txt, VerifiedBadge } from "@krizaka/ui/native";
|
|
2
|
+
import { View } from "react-native";
|
|
3
|
+
|
|
4
|
+
// A profile: the photo with its story ring, the name and seal, the facts, the interests, the actions.
|
|
5
|
+
export default function NativeScreenProfile() {
|
|
6
|
+
return (
|
|
7
|
+
<View style={{ width: 360, height: 640 }}>
|
|
8
|
+
<Screen footer={<View style={{ flexDirection: "row", gap: 8, padding: 16 }}><Button label="Edit profile" style={{ flex: 1 }} /><Button label="Preview" variant="outline" style={{ flex: 1 }} /></View>}>
|
|
9
|
+
<View style={{ alignItems: "center", gap: 6 }}>
|
|
10
|
+
<Avatar src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAwAAAAQCAIAAACtAwlQAAABaklEQVR42mWMy24UQQxF7arqlwLhIbJhwZZf5I/4IISEBIsIRSKTMOmZnp7uqrJ9zYIeIeCsrqzjw+vHDwYCCM6wbfy5gABKatsysJqLuoHciZ2dGE4ApSrbnyidVn06lVyQUrweur5pmAJAqVQGSEGnRb79mD5/H6dzuRq6929fv7t5MTSd+6VUK3Zj/XQ7frkblyJ926jwkIab6yZw3Eq58rzaz6nMq1RVA+3nMmd73nMMfCkJiRBA7u5O7g6QCFfhyLyVRJg89U3bxKiGJsQ+te6pCge+lETYPT3rujalotqkNLSdexRhJk6lshjOWXeH+WE6Z1HAi+p+Pr+czuxtG0PKlZesd+P09f5xd5iKqrlX1cfpGCiqhDdXr9Ja8DSX24f9/eG4VDGAiAzIIrvpwJ6C96FUXrId15Ivxm8MKCpzKUvRUCpXJTOHO/2Nu6uhqocqLMr4V9iAkxoHMzZjgP7XnMjBZvQLMEROG5iV3IMAAAAASUVORK5CYII=" alt="Elena" size={112} ring="story" />
|
|
11
|
+
<View style={{ flexDirection: "row", alignItems: "center", gap: 6 }}>
|
|
12
|
+
<Txt variant="title">Elena, 29</Txt>
|
|
13
|
+
<VerifiedBadge label="Verified" size={18} />
|
|
14
|
+
</View>
|
|
15
|
+
<Txt tone="secondary">Lisbon · Sound engineer</Txt>
|
|
16
|
+
</View>
|
|
17
|
+
<View style={{ flexDirection: "row", justifyContent: "center", gap: 32 }}>
|
|
18
|
+
<Txt variant="label">128 likes</Txt>
|
|
19
|
+
<Txt variant="label">14 matches</Txt>
|
|
20
|
+
</View>
|
|
21
|
+
<View style={{ flexDirection: "row", flexWrap: "wrap", gap: 8 }}>
|
|
22
|
+
{["Music", "Surf", "Travel", "Vinyl"].map((t) => <Chip key={t}>{t}</Chip>)}
|
|
23
|
+
</View>
|
|
24
|
+
</Screen>
|
|
25
|
+
</View>
|
|
26
|
+
);
|
|
27
|
+
}
|
|
Binary file
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
// registry/examples/screen/native/settings.tsx
|
|
4
|
+
import { Header, Screen, Switch, Txt } from "@krizaka/ui/native";
|
|
5
|
+
import { View } from "react-native";
|
|
6
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
7
|
+
function NativeScreenSettings() {
|
|
8
|
+
return /* @__PURE__ */ jsx(View, { style: { width: 360, height: 640 }, children: /* @__PURE__ */ jsxs(Screen, { header: /* @__PURE__ */ jsx(Header, { size: "inline", title: "Settings", backLabel: "Me", onBack: () => void 0 }), children: [
|
|
9
|
+
/* @__PURE__ */ jsx(Txt, { variant: "caption", tone: "secondary", role: "heading", children: "DISCOVERY" }),
|
|
10
|
+
/* @__PURE__ */ jsx(Switch, { label: "Show me in Discover", defaultChecked: true }),
|
|
11
|
+
/* @__PURE__ */ jsx(Txt, { variant: "caption", tone: "secondary", role: "heading", children: "NOTIFICATIONS" }),
|
|
12
|
+
/* @__PURE__ */ jsx(Switch, { label: "New likes", defaultChecked: true }),
|
|
13
|
+
/* @__PURE__ */ jsx(Switch, { label: "Messages", description: "Even when the app is closed", defaultChecked: true }),
|
|
14
|
+
/* @__PURE__ */ jsx(Txt, { variant: "caption", tone: "secondary", role: "heading", children: "ACCOUNT" }),
|
|
15
|
+
/* @__PURE__ */ jsx(Switch, { label: "Show my distance", description: "Rounded to the kilometre" })
|
|
16
|
+
] }) });
|
|
17
|
+
}
|
|
18
|
+
export {
|
|
19
|
+
NativeScreenSettings as default
|
|
20
|
+
};
|
|
Binary file
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { Header, Screen, Switch, Txt } from "@krizaka/ui/native";
|
|
2
|
+
import { View } from "react-native";
|
|
3
|
+
|
|
4
|
+
// Settings: sections with their headings, switches that apply at once.
|
|
5
|
+
export default function NativeScreenSettings() {
|
|
6
|
+
return (
|
|
7
|
+
<View style={{ width: 360, height: 640 }}>
|
|
8
|
+
<Screen header={<Header size="inline" title="Settings" backLabel="Me" onBack={() => undefined} />}>
|
|
9
|
+
<Txt variant="caption" tone="secondary" role="heading">DISCOVERY</Txt>
|
|
10
|
+
<Switch label="Show me in Discover" defaultChecked />
|
|
11
|
+
<Txt variant="caption" tone="secondary" role="heading">NOTIFICATIONS</Txt>
|
|
12
|
+
<Switch label="New likes" defaultChecked />
|
|
13
|
+
<Switch label="Messages" description="Even when the app is closed" defaultChecked />
|
|
14
|
+
<Txt variant="caption" tone="secondary" role="heading">ACCOUNT</Txt>
|
|
15
|
+
<Switch label="Show my distance" description="Rounded to the kilometre" />
|
|
16
|
+
</Screen>
|
|
17
|
+
</View>
|
|
18
|
+
);
|
|
19
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
// registry/examples/skip-link/default.tsx
|
|
4
|
+
import { SkipLink } from "@krizaka/ui/skip-link";
|
|
5
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
6
|
+
function SkipLinkDefault() {
|
|
7
|
+
return /* @__PURE__ */ jsxs("div", { className: "flex flex-col gap-3", children: [
|
|
8
|
+
/* @__PURE__ */ jsx(SkipLink, { href: "#skip-link-content", children: "Skip to content" }),
|
|
9
|
+
/* @__PURE__ */ jsxs("nav", { "aria-label": "Main", className: "flex gap-4 text-sm", children: [
|
|
10
|
+
/* @__PURE__ */ jsx("a", { href: "#home", children: "Home" }),
|
|
11
|
+
/* @__PURE__ */ jsx("a", { href: "#docs", children: "Docs" }),
|
|
12
|
+
/* @__PURE__ */ jsx("a", { href: "#contact", children: "Contact" })
|
|
13
|
+
] }),
|
|
14
|
+
/* @__PURE__ */ jsx("main", { id: "skip-link-content", className: "rounded-lg border border-border-default p-4 text-sm text-fg-secondary", children: "The content starts here." })
|
|
15
|
+
] });
|
|
16
|
+
}
|
|
17
|
+
export {
|
|
18
|
+
SkipLinkDefault as default
|
|
19
|
+
};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { SkipLink } from "@krizaka/ui/skip-link";
|
|
2
|
+
|
|
3
|
+
// Press Tab: the link appears, Enter lands on the content. Put it first in the shell, label already translated.
|
|
4
|
+
export default function SkipLinkDefault() {
|
|
5
|
+
return (
|
|
6
|
+
<div className="flex flex-col gap-3">
|
|
7
|
+
<SkipLink href="#skip-link-content">Skip to content</SkipLink>
|
|
8
|
+
<nav aria-label="Main" className="flex gap-4 text-sm"><a href="#home">Home</a><a href="#docs">Docs</a><a href="#contact">Contact</a></nav>
|
|
9
|
+
<main id="skip-link-content" className="rounded-lg border border-border-default p-4 text-sm text-fg-secondary">The content starts here.</main>
|
|
10
|
+
</div>
|
|
11
|
+
);
|
|
12
|
+
}
|
|
Binary file
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
// registry/examples/splash-handoff/native/default.tsx
|
|
4
|
+
import { SplashHandoff } from "@krizaka/ui/native";
|
|
5
|
+
import { View } from "react-native";
|
|
6
|
+
import { jsx } from "react/jsx-runtime";
|
|
7
|
+
function NativeSplashHandoffDefault() {
|
|
8
|
+
return /* @__PURE__ */ jsx(View, { style: { width: 360, height: 640 }, children: /* @__PURE__ */ jsx(SplashHandoff, { product: "orochia", ready: false, label: "Orochia is opening" }) });
|
|
9
|
+
}
|
|
10
|
+
export {
|
|
11
|
+
NativeSplashHandoffDefault as default
|
|
12
|
+
};
|
|
Binary file
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { SplashHandoff } from "@krizaka/ui/native";
|
|
2
|
+
import { View } from "react-native";
|
|
3
|
+
|
|
4
|
+
// Over the app's root: the mark sits where the native splash icon was; `ready` (the session and fonts loaded) dissolves it.
|
|
5
|
+
export default function NativeSplashHandoffDefault() {
|
|
6
|
+
return (
|
|
7
|
+
<View style={{ width: 360, height: 640 }}>
|
|
8
|
+
<SplashHandoff product="orochia" ready={false} label="Orochia is opening" />
|
|
9
|
+
</View>
|
|
10
|
+
);
|
|
11
|
+
}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
// registry/examples/split-view/nearby.tsx
|
|
4
|
+
import { Map, Marker, StaticMap } from "@krizaka/ui/map";
|
|
5
|
+
import { SplitView } from "@krizaka/ui/split-view";
|
|
6
|
+
import * as React from "react";
|
|
7
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
8
|
+
var SPOTS = [
|
|
9
|
+
{ id: "olimpico", label: "Caf\xE9 Olimpico", where: "Mile End \xB7 450 m", position: [-73.6005, 45.5229] },
|
|
10
|
+
{ id: "jean-talon", label: "March\xE9 Jean-Talon", where: "Little Italy \xB7 1.2 km", position: [-73.6147, 45.5363] },
|
|
11
|
+
{ id: "parc", label: "Parc La Fontaine", where: "Plateau \xB7 2 km", position: [-73.5695, 45.5268] }
|
|
12
|
+
];
|
|
13
|
+
function SplitViewNearby() {
|
|
14
|
+
const [chosen, setChosen] = React.useState("olimpico");
|
|
15
|
+
return /* @__PURE__ */ jsx(
|
|
16
|
+
SplitView,
|
|
17
|
+
{
|
|
18
|
+
className: "w-full",
|
|
19
|
+
listTitle: "Pick-up points",
|
|
20
|
+
showDetail: true,
|
|
21
|
+
back: /* @__PURE__ */ jsx("a", { href: "#list", className: "text-sm font-medium text-fg-secondary", children: "\u2190 Pick-up points" }),
|
|
22
|
+
list: /* @__PURE__ */ jsx("ul", { children: SPOTS.map((s) => /* @__PURE__ */ jsx("li", { children: /* @__PURE__ */ jsxs("button", { type: "button", "aria-pressed": s.id === chosen, onClick: () => setChosen(s.id), className: "flex w-full flex-col items-start gap-0.5 border-b border-border-subtle px-4 py-3 text-left text-sm hover:bg-surface-2 aria-pressed:bg-accent-soft", children: [
|
|
23
|
+
/* @__PURE__ */ jsx("span", { className: "font-semibold text-fg", children: s.label }),
|
|
24
|
+
/* @__PURE__ */ jsx("span", { className: "text-fg-secondary", children: s.where })
|
|
25
|
+
] }) }, s.id)) }),
|
|
26
|
+
detailHead: /* @__PURE__ */ jsx("span", { className: "text-sm font-bold text-fg", children: "Map" }),
|
|
27
|
+
detail: /* @__PURE__ */ jsx(Map, { label: "Pick-up points in Montr\xE9al", center: [-73.592, 45.528], zoom: 12.5, className: "h-96 w-full", fallback: /* @__PURE__ */ jsx(StaticMap, { label: "Pick-up points in Montr\xE9al", center: [-73.592, 45.528], zoom: 12.5, places: SPOTS }), children: SPOTS.map((s) => /* @__PURE__ */ jsx(Marker, { position: s.position, label: s.label, selected: s.id === chosen, onPress: () => setChosen(s.id) }, s.id)) })
|
|
28
|
+
}
|
|
29
|
+
);
|
|
30
|
+
}
|
|
31
|
+
export {
|
|
32
|
+
SplitViewNearby as default
|
|
33
|
+
};
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
import { Map, Marker, StaticMap } from "@krizaka/ui/map";
|
|
4
|
+
import { SplitView } from "@krizaka/ui/split-view";
|
|
5
|
+
import * as React from "react";
|
|
6
|
+
|
|
7
|
+
const SPOTS = [
|
|
8
|
+
{ id: "olimpico", label: "Café Olimpico", where: "Mile End · 450 m", position: [-73.6005, 45.5229] as const },
|
|
9
|
+
{ id: "jean-talon", label: "Marché Jean-Talon", where: "Little Italy · 1.2 km", position: [-73.6147, 45.5363] as const },
|
|
10
|
+
{ id: "parc", label: "Parc La Fontaine", where: "Plateau · 2 km", position: [-73.5695, 45.5268] as const },
|
|
11
|
+
];
|
|
12
|
+
|
|
13
|
+
// TEMPLATE — find a place near you: the map is the page, the list beside it says the same in words (a screen reader reads
|
|
14
|
+
// the list); choosing in one moves the other. On a phone the list replaces the map with the way back.
|
|
15
|
+
export default function SplitViewNearby() {
|
|
16
|
+
const [chosen, setChosen] = React.useState("olimpico");
|
|
17
|
+
return (
|
|
18
|
+
<SplitView
|
|
19
|
+
className="w-full"
|
|
20
|
+
listTitle="Pick-up points"
|
|
21
|
+
showDetail
|
|
22
|
+
back={<a href="#list" className="text-sm font-medium text-fg-secondary">← Pick-up points</a>}
|
|
23
|
+
list={
|
|
24
|
+
<ul>
|
|
25
|
+
{SPOTS.map((s) => (
|
|
26
|
+
<li key={s.id}>
|
|
27
|
+
<button type="button" aria-pressed={s.id === chosen} onClick={() => setChosen(s.id)} className="flex w-full flex-col items-start gap-0.5 border-b border-border-subtle px-4 py-3 text-left text-sm hover:bg-surface-2 aria-pressed:bg-accent-soft">
|
|
28
|
+
<span className="font-semibold text-fg">{s.label}</span>
|
|
29
|
+
<span className="text-fg-secondary">{s.where}</span>
|
|
30
|
+
</button>
|
|
31
|
+
</li>
|
|
32
|
+
))}
|
|
33
|
+
</ul>
|
|
34
|
+
}
|
|
35
|
+
detailHead={<span className="text-sm font-bold text-fg">Map</span>}
|
|
36
|
+
detail={
|
|
37
|
+
<Map label="Pick-up points in Montréal" center={[-73.592, 45.528]} zoom={12.5} className="h-96 w-full" fallback={<StaticMap label="Pick-up points in Montréal" center={[-73.592, 45.528]} zoom={12.5} places={SPOTS} />}>
|
|
38
|
+
{SPOTS.map((s) => (
|
|
39
|
+
<Marker key={s.id} position={s.position} label={s.label} selected={s.id === chosen} onPress={() => setChosen(s.id)} />
|
|
40
|
+
))}
|
|
41
|
+
</Map>
|
|
42
|
+
}
|
|
43
|
+
/>
|
|
44
|
+
);
|
|
45
|
+
}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
// registry/examples/split-view/notifications.tsx
|
|
4
|
+
import { ActivityFeed } from "@krizaka/ui/activity-feed";
|
|
5
|
+
import { Button } from "@krizaka/ui/button";
|
|
6
|
+
import { SplitView } from "@krizaka/ui/split-view";
|
|
7
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
8
|
+
var NOW = /* @__PURE__ */ new Date("2026-10-13T10:00:00Z");
|
|
9
|
+
var EVENTS = [
|
|
10
|
+
{ id: "n1", at: "2026-10-13T09:40:00Z", title: "Mina unlocked \u201CNight shoot, part 2\u201D", tone: "success" },
|
|
11
|
+
{ id: "n2", at: "2026-10-13T08:15:00Z", title: "Your payout of \u20AC120 was sent", tone: "info" },
|
|
12
|
+
{ id: "n3", at: "2026-10-12T19:02:00Z", title: "L\xE9a bid \u20AC25 on the auction", tone: "accent" }
|
|
13
|
+
];
|
|
14
|
+
function SplitViewNotifications() {
|
|
15
|
+
return /* @__PURE__ */ jsx(
|
|
16
|
+
SplitView,
|
|
17
|
+
{
|
|
18
|
+
className: "brand-orochia w-full",
|
|
19
|
+
listTitle: "Notifications",
|
|
20
|
+
showDetail: false,
|
|
21
|
+
back: /* @__PURE__ */ jsx("a", { href: "#notifications", className: "text-sm font-medium text-fg-secondary", children: "\u2190 Notifications" }),
|
|
22
|
+
list: /* @__PURE__ */ jsxs("div", { className: "flex flex-col gap-3 p-3", children: [
|
|
23
|
+
/* @__PURE__ */ jsx(Button, { size: "sm", variant: "ghost", className: "w-fit", children: "Mark all as read" }),
|
|
24
|
+
/* @__PURE__ */ jsx(ActivityFeed, { "aria-label": "Notifications", events: EVENTS, now: NOW, ticking: false })
|
|
25
|
+
] }),
|
|
26
|
+
detailHead: /* @__PURE__ */ jsx("span", { className: "text-sm font-bold text-fg", children: "Mina unlocked \u201CNight shoot, part 2\u201D" }),
|
|
27
|
+
detail: /* @__PURE__ */ jsx("p", { className: "text-sm text-fg-secondary", children: "\u20AC4.99 unlocked at 09:40. Your share, \u20AC4.49, is paid out on Monday." })
|
|
28
|
+
}
|
|
29
|
+
);
|
|
30
|
+
}
|
|
31
|
+
export {
|
|
32
|
+
SplitViewNotifications as default
|
|
33
|
+
};
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { ActivityFeed } from "@krizaka/ui/activity-feed";
|
|
2
|
+
import { Button } from "@krizaka/ui/button";
|
|
3
|
+
import { SplitView } from "@krizaka/ui/split-view";
|
|
4
|
+
|
|
5
|
+
const NOW = new Date("2026-10-13T10:00:00Z");
|
|
6
|
+
const EVENTS = [
|
|
7
|
+
{ id: "n1", at: "2026-10-13T09:40:00Z", title: "Mina unlocked “Night shoot, part 2”", tone: "success" as const },
|
|
8
|
+
{ id: "n2", at: "2026-10-13T08:15:00Z", title: "Your payout of €120 was sent", tone: "info" as const },
|
|
9
|
+
{ id: "n3", at: "2026-10-12T19:02:00Z", title: "Léa bid €25 on the auction", tone: "accent" as const },
|
|
10
|
+
];
|
|
11
|
+
|
|
12
|
+
// TEMPLATE — a notifications centre: what happened, newest first, grouped by day; the selected one opens beside the list
|
|
13
|
+
// (a screen of its own on a phone). Marking all as read is one button, never a hidden gesture.
|
|
14
|
+
export default function SplitViewNotifications() {
|
|
15
|
+
return (
|
|
16
|
+
<SplitView
|
|
17
|
+
className="brand-orochia w-full"
|
|
18
|
+
listTitle="Notifications"
|
|
19
|
+
showDetail={false}
|
|
20
|
+
back={<a href="#notifications" className="text-sm font-medium text-fg-secondary">← Notifications</a>}
|
|
21
|
+
list={
|
|
22
|
+
<div className="flex flex-col gap-3 p-3">
|
|
23
|
+
<Button size="sm" variant="ghost" className="w-fit">Mark all as read</Button>
|
|
24
|
+
<ActivityFeed aria-label="Notifications" events={EVENTS} now={NOW} ticking={false} />
|
|
25
|
+
</div>
|
|
26
|
+
}
|
|
27
|
+
detailHead={<span className="text-sm font-bold text-fg">Mina unlocked “Night shoot, part 2”</span>}
|
|
28
|
+
detail={<p className="text-sm text-fg-secondary">€4.99 unlocked at 09:40. Your share, €4.49, is paid out on Monday.</p>}
|
|
29
|
+
/>
|
|
30
|
+
);
|
|
31
|
+
}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
// registry/examples/status-page/maintenance.tsx
|
|
4
|
+
import { Mascot } from "@krizaka/ui/mascots";
|
|
5
|
+
import { StatusPage } from "@krizaka/ui/status-page";
|
|
6
|
+
import { jsx } from "react/jsx-runtime";
|
|
7
|
+
function StatusPageMaintenance() {
|
|
8
|
+
return /* @__PURE__ */ jsx(
|
|
9
|
+
StatusPage,
|
|
10
|
+
{
|
|
11
|
+
eyebrow: "Maintenance",
|
|
12
|
+
title: "Back at 06:00",
|
|
13
|
+
lead: "We are moving the database to a bigger machine. Nothing is lost; writes are paused.",
|
|
14
|
+
aside: /* @__PURE__ */ jsx(Mascot, { bird: "pigeon", mood: "empty", size: 112 }),
|
|
15
|
+
state: "degraded",
|
|
16
|
+
stateLabel: "Planned maintenance",
|
|
17
|
+
checked: "Until 06:00 (Montr\xE9al)",
|
|
18
|
+
servicesLabel: "Services",
|
|
19
|
+
services: [
|
|
20
|
+
{ id: "watch", name: "Watching videos", state: "operational", label: "Works" },
|
|
21
|
+
{ id: "unlock", name: "Unlocks and tips", state: "degraded", label: "Paused" },
|
|
22
|
+
{ id: "upload", name: "Uploads", state: "degraded", label: "Paused" }
|
|
23
|
+
]
|
|
24
|
+
}
|
|
25
|
+
);
|
|
26
|
+
}
|
|
27
|
+
export {
|
|
28
|
+
StatusPageMaintenance as default
|
|
29
|
+
};
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { Mascot } from "@krizaka/ui/mascots";
|
|
2
|
+
import { StatusPage } from "@krizaka/ui/status-page";
|
|
3
|
+
|
|
4
|
+
// TEMPLATE — planned maintenance: what is paused, until when, and what still works — said before the visitor wonders.
|
|
5
|
+
// The state is in words and colour; the pigeon waits with the message.
|
|
6
|
+
export default function StatusPageMaintenance() {
|
|
7
|
+
return (
|
|
8
|
+
<StatusPage
|
|
9
|
+
eyebrow="Maintenance"
|
|
10
|
+
title="Back at 06:00"
|
|
11
|
+
lead="We are moving the database to a bigger machine. Nothing is lost; writes are paused."
|
|
12
|
+
aside={<Mascot bird="pigeon" mood="empty" size={112} />}
|
|
13
|
+
state="degraded"
|
|
14
|
+
stateLabel="Planned maintenance"
|
|
15
|
+
checked="Until 06:00 (Montréal)"
|
|
16
|
+
servicesLabel="Services"
|
|
17
|
+
services={[
|
|
18
|
+
{ id: "watch", name: "Watching videos", state: "operational", label: "Works" },
|
|
19
|
+
{ id: "unlock", name: "Unlocks and tips", state: "degraded", label: "Paused" },
|
|
20
|
+
{ id: "upload", name: "Uploads", state: "degraded", label: "Paused" },
|
|
21
|
+
]}
|
|
22
|
+
/>
|
|
23
|
+
);
|
|
24
|
+
}
|
|
Binary file
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
// registry/examples/step-progress/native/sign-up.tsx
|
|
4
|
+
import { Button, StepProgress } from "@krizaka/ui/native";
|
|
5
|
+
import { View } from "react-native";
|
|
6
|
+
import { jsx } from "react/jsx-runtime";
|
|
7
|
+
function NativeStepProgressSignUp() {
|
|
8
|
+
return /* @__PURE__ */ jsx(View, { style: { width: 360 }, children: /* @__PURE__ */ jsx(StepProgress, { step: 2, total: 5, label: (n, total) => `Step ${n} of ${total}`, backLabel: "Back", onBack: () => void 0, trailing: /* @__PURE__ */ jsx(Button, { label: "Skip", variant: "ghost", size: "sm" }) }) });
|
|
9
|
+
}
|
|
10
|
+
export {
|
|
11
|
+
NativeStepProgressSignUp as default
|
|
12
|
+
};
|
|
Binary file
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { Button, StepProgress } from "@krizaka/ui/native";
|
|
2
|
+
import { View } from "react-native";
|
|
3
|
+
|
|
4
|
+
// The head of the sign-up: back, five segments, the position in words, Skip.
|
|
5
|
+
export default function NativeStepProgressSignUp() {
|
|
6
|
+
return (
|
|
7
|
+
<View style={{ width: 360 }}>
|
|
8
|
+
<StepProgress step={2} total={5} label={(n, total) => `Step ${n} of ${total}`} backLabel="Back" onBack={() => undefined} trailing={<Button label="Skip" variant="ghost" size="sm" />} />
|
|
9
|
+
</View>
|
|
10
|
+
);
|
|
11
|
+
}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
// registry/examples/step-progress/sign-up.tsx
|
|
4
|
+
import { Button } from "@krizaka/ui/button";
|
|
5
|
+
import { StepProgress } from "@krizaka/ui/step-progress";
|
|
6
|
+
import { jsx } from "react/jsx-runtime";
|
|
7
|
+
function StepProgressSignUp() {
|
|
8
|
+
return /* @__PURE__ */ jsx(
|
|
9
|
+
StepProgress,
|
|
10
|
+
{
|
|
11
|
+
className: "max-w-md",
|
|
12
|
+
step: 2,
|
|
13
|
+
total: 5,
|
|
14
|
+
label: (n, total) => `Step ${n} of ${total}`,
|
|
15
|
+
back: /* @__PURE__ */ jsx(Button, { variant: "ghost", size: "sm", children: "Back" }),
|
|
16
|
+
trailing: /* @__PURE__ */ jsx(Button, { variant: "ghost", size: "sm", children: "Skip" })
|
|
17
|
+
}
|
|
18
|
+
);
|
|
19
|
+
}
|
|
20
|
+
export {
|
|
21
|
+
StepProgressSignUp as default
|
|
22
|
+
};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { Button } from "@krizaka/ui/button";
|
|
2
|
+
import { StepProgress } from "@krizaka/ui/step-progress";
|
|
3
|
+
|
|
4
|
+
// The head of the sign-up: back, five segments, the position in words, Skip.
|
|
5
|
+
export default function StepProgressSignUp() {
|
|
6
|
+
return (
|
|
7
|
+
<StepProgress
|
|
8
|
+
className="max-w-md"
|
|
9
|
+
step={2}
|
|
10
|
+
total={5}
|
|
11
|
+
label={(n, total) => `Step ${n} of ${total}`}
|
|
12
|
+
back={<Button variant="ghost" size="sm">Back</Button>}
|
|
13
|
+
trailing={<Button variant="ghost" size="sm">Skip</Button>}
|
|
14
|
+
/>
|
|
15
|
+
);
|
|
16
|
+
}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
// registry/examples/swipe-deck/discover.tsx
|
|
4
|
+
import { Badge } from "@krizaka/ui/badge";
|
|
5
|
+
import { PersonCard, SwipeDeck } from "@krizaka/ui/swipe-deck";
|
|
6
|
+
import { VerifiedBadge } from "@krizaka/ui/verified-badge";
|
|
7
|
+
import { useState } from "react";
|
|
8
|
+
import { jsx } from "react/jsx-runtime";
|
|
9
|
+
var png = (data) => `data:image/png;base64,${data}`;
|
|
10
|
+
var PEOPLE = [
|
|
11
|
+
{ id: "e", name: "Elena", age: 29, km: 3.2, bio: "Sunsets, vinyl and long walks.", tags: ["Music", "Surf"], photos: [png("iVBORw0KGgoAAAANSUhEUgAAAAwAAAAQCAIAAACtAwlQAAABaklEQVR42mWMy24UQQxF7arqlwLhIbJhwZZf5I/4IISEBIsIRSKTMOmZnp7uqrJ9zYIeIeCsrqzjw+vHDwYCCM6wbfy5gABKatsysJqLuoHciZ2dGE4ApSrbnyidVn06lVyQUrweur5pmAJAqVQGSEGnRb79mD5/H6dzuRq6929fv7t5MTSd+6VUK3Zj/XQ7frkblyJ926jwkIab6yZw3Eq58rzaz6nMq1RVA+3nMmd73nMMfCkJiRBA7u5O7g6QCFfhyLyVRJg89U3bxKiGJsQ+te6pCge+lETYPT3rujalotqkNLSdexRhJk6lshjOWXeH+WE6Z1HAi+p+Pr+czuxtG0PKlZesd+P09f5xd5iKqrlX1cfpGCiqhDdXr9Ja8DSX24f9/eG4VDGAiAzIIrvpwJ6C96FUXrId15Ivxm8MKCpzKUvRUCpXJTOHO/2Nu6uhqocqLMr4V9iAkxoHMzZjgP7XnMjBZvQLMEROG5iV3IMAAAAASUVORK5CYII="), png("iVBORw0KGgoAAAANSUhEUgAAAAwAAAAQCAIAAACtAwlQAAABZklEQVR42m3MzW4TUQyGYZ8zZzJpwp8UiQ0SEvfMLXETICqoKrXQdDohyZwZ258/FpPCAryyrUdv6j99ZDAiSALLFhFkULhcLAAWFEEA7ggEhYkiImQwWNx84WY+Vh0OZzVvcn657bq25MQIFlOLYCDOY/1+23/59uN0mrZX3Yf3u3dvX6+7VvhcMvXH/vT5+u7rzcM02XrVOvyqbXZvNjmlYmoMqtpY5+EwjqOae4CHX7XWWTerktOl5OYwR5AkKSSXp6sxP5fcPJHrVWlLA0Rpctc2iYQ5/5RgEHLTlbY0qt6WZrsuQrp5SlJMzRG16r4/98M4qyM4m/eH+mqzyilWTVNUfZr0bn+8vn16eDqqeZDm2A9jEgawe7Eu8zQPx+nmfrh/PNbZERQRBCf1n0NtkhQym/lU59N5nu0ilkFQDaeqddLsamZwB/+Cy5CEhzuym8M9KP8iEQkSjgwAAP9LhCQB/AYQ5Y+kAv/RXgAAAABJRU5ErkJggg==")] },
|
|
12
|
+
{ id: "n", name: "Noah", age: 31, km: 12, bio: "Cook, climber, bad puns.", tags: ["Climbing"], photos: [png("iVBORw0KGgoAAAANSUhEUgAAAAwAAAAQCAIAAACtAwlQAAABaUlEQVR42mWRzW5TQRSDZ+bOTdMoFMGCFWx4SR6OF0EgQVWECmqbNOnNvTPnHNssIn6kemVZn+yF84eP30mKFEWCZwMmnROKrAAIShSIAOECKaWUkhIlkTXMzxDdbT614z7M8jCsNi+G8UI5nyEjKKKfpuOP6931Z5uO4+X26t377Zu3w2otqYY5SZjNu/uHr5/2N1+it7paR0QZLy9evs651DAjCes2n9ph58uMcIH9+Njn07De5jL8bXJ4kJSUJEkU4BFmuQzVzUTCXUplXJdhJFCGWuqFlMIjJ1aYE0SEpLrelDpmtzKMw2ojJpinnGuYMcLavOzv2+MDrItAdHvatc3VKqUyjDV697YsD7fT7bf2eIewJCK8H+6VMoBx86paa/1pP/26WXY/oy+JSCklAt774U65kLm4mS/N5+k8lP5IBMJimaK1AnO6E5HOf/0vSQGElzBHhEilZ1ASRXgUAAD0vOYfhd832o14udpJswAAAABJRU5ErkJggg==")] }
|
|
13
|
+
];
|
|
14
|
+
function SwipeDeckDiscover() {
|
|
15
|
+
const [people, setPeople] = useState(PEOPLE);
|
|
16
|
+
return /* @__PURE__ */ jsx(
|
|
17
|
+
SwipeDeck,
|
|
18
|
+
{
|
|
19
|
+
items: people,
|
|
20
|
+
getId: (p) => p.id,
|
|
21
|
+
getName: (p) => p.name,
|
|
22
|
+
onSwipe: (p) => setPeople((all) => all.filter((x) => x.id !== p.id)),
|
|
23
|
+
labels: { like: "Like", pass: "Pass", deck: "Profiles. Right arrow to like, left arrow to pass.", likeStamp: "Like", passStamp: "Nope" },
|
|
24
|
+
renderCard: (p) => /* @__PURE__ */ jsx(
|
|
25
|
+
PersonCard,
|
|
26
|
+
{
|
|
27
|
+
photos: p.photos.map((src) => ({ src })),
|
|
28
|
+
name: p.name,
|
|
29
|
+
age: p.age,
|
|
30
|
+
badge: /* @__PURE__ */ jsx(VerifiedBadge, { label: "Verified", onMedia: true, size: "lg" }),
|
|
31
|
+
meta: /* @__PURE__ */ jsx("span", { className: "text-xs font-semibold", children: `${p.km} km away` }),
|
|
32
|
+
bio: p.bio,
|
|
33
|
+
footer: p.tags.map((t) => /* @__PURE__ */ jsx(Badge, { tone: "scrim", children: t }, t))
|
|
34
|
+
}
|
|
35
|
+
)
|
|
36
|
+
}
|
|
37
|
+
);
|
|
38
|
+
}
|
|
39
|
+
export {
|
|
40
|
+
SwipeDeckDiscover as default
|
|
41
|
+
};
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
import { Badge } from "@krizaka/ui/badge";
|
|
4
|
+
import { PersonCard, SwipeDeck } from "@krizaka/ui/swipe-deck";
|
|
5
|
+
import { VerifiedBadge } from "@krizaka/ui/verified-badge";
|
|
6
|
+
import { useState } from "react";
|
|
7
|
+
|
|
8
|
+
const png = (data: string) => `data:image/png;base64,${data}`;
|
|
9
|
+
const PEOPLE = [
|
|
10
|
+
{ id: "e", name: "Elena", age: 29, km: 3.2, bio: "Sunsets, vinyl and long walks.", tags: ["Music", "Surf"], photos: [png("iVBORw0KGgoAAAANSUhEUgAAAAwAAAAQCAIAAACtAwlQAAABaklEQVR42mWMy24UQQxF7arqlwLhIbJhwZZf5I/4IISEBIsIRSKTMOmZnp7uqrJ9zYIeIeCsrqzjw+vHDwYCCM6wbfy5gABKatsysJqLuoHciZ2dGE4ApSrbnyidVn06lVyQUrweur5pmAJAqVQGSEGnRb79mD5/H6dzuRq6929fv7t5MTSd+6VUK3Zj/XQ7frkblyJ926jwkIab6yZw3Eq58rzaz6nMq1RVA+3nMmd73nMMfCkJiRBA7u5O7g6QCFfhyLyVRJg89U3bxKiGJsQ+te6pCge+lETYPT3rujalotqkNLSdexRhJk6lshjOWXeH+WE6Z1HAi+p+Pr+czuxtG0PKlZesd+P09f5xd5iKqrlX1cfpGCiqhDdXr9Ja8DSX24f9/eG4VDGAiAzIIrvpwJ6C96FUXrId15Ivxm8MKCpzKUvRUCpXJTOHO/2Nu6uhqocqLMr4V9iAkxoHMzZjgP7XnMjBZvQLMEROG5iV3IMAAAAASUVORK5CYII="), png("iVBORw0KGgoAAAANSUhEUgAAAAwAAAAQCAIAAACtAwlQAAABZklEQVR42m3MzW4TUQyGYZ8zZzJpwp8UiQ0SEvfMLXETICqoKrXQdDohyZwZ258/FpPCAryyrUdv6j99ZDAiSALLFhFkULhcLAAWFEEA7ggEhYkiImQwWNx84WY+Vh0OZzVvcn657bq25MQIFlOLYCDOY/1+23/59uN0mrZX3Yf3u3dvX6+7VvhcMvXH/vT5+u7rzcM02XrVOvyqbXZvNjmlYmoMqtpY5+EwjqOae4CHX7XWWTerktOl5OYwR5AkKSSXp6sxP5fcPJHrVWlLA0Rpctc2iYQ5/5RgEHLTlbY0qt6WZrsuQrp5SlJMzRG16r4/98M4qyM4m/eH+mqzyilWTVNUfZr0bn+8vn16eDqqeZDm2A9jEgawe7Eu8zQPx+nmfrh/PNbZERQRBCf1n0NtkhQym/lU59N5nu0ilkFQDaeqddLsamZwB/+Cy5CEhzuym8M9KP8iEQkSjgwAAP9LhCQB/AYQ5Y+kAv/RXgAAAABJRU5ErkJggg==")] },
|
|
11
|
+
{ id: "n", name: "Noah", age: 31, km: 12, bio: "Cook, climber, bad puns.", tags: ["Climbing"], photos: [png("iVBORw0KGgoAAAANSUhEUgAAAAwAAAAQCAIAAACtAwlQAAABaUlEQVR42mWRzW5TQRSDZ+bOTdMoFMGCFWx4SR6OF0EgQVWECmqbNOnNvTPnHNssIn6kemVZn+yF84eP30mKFEWCZwMmnROKrAAIShSIAOECKaWUkhIlkTXMzxDdbT614z7M8jCsNi+G8UI5nyEjKKKfpuOP6931Z5uO4+X26t377Zu3w2otqYY5SZjNu/uHr5/2N1+it7paR0QZLy9evs651DAjCes2n9ph58uMcIH9+Njn07De5jL8bXJ4kJSUJEkU4BFmuQzVzUTCXUplXJdhJFCGWuqFlMIjJ1aYE0SEpLrelDpmtzKMw2ojJpinnGuYMcLavOzv2+MDrItAdHvatc3VKqUyjDV697YsD7fT7bf2eIewJCK8H+6VMoBx86paa/1pP/26WXY/oy+JSCklAt774U65kLm4mS/N5+k8lP5IBMJimaK1AnO6E5HOf/0vSQGElzBHhEilZ1ASRXgUAAD0vOYfhd832o14udpJswAAAABJRU5ErkJggg==")] },
|
|
12
|
+
];
|
|
13
|
+
|
|
14
|
+
// Discover: drag right to like, left to pass, the buttons, or ← → on the focused deck.
|
|
15
|
+
export default function SwipeDeckDiscover() {
|
|
16
|
+
const [people, setPeople] = useState(PEOPLE);
|
|
17
|
+
return (
|
|
18
|
+
<SwipeDeck
|
|
19
|
+
items={people}
|
|
20
|
+
getId={(p) => p.id}
|
|
21
|
+
getName={(p) => p.name}
|
|
22
|
+
onSwipe={(p) => setPeople((all) => all.filter((x) => x.id !== p.id))}
|
|
23
|
+
labels={{ like: "Like", pass: "Pass", deck: "Profiles. Right arrow to like, left arrow to pass.", likeStamp: "Like", passStamp: "Nope" }}
|
|
24
|
+
renderCard={(p) => (
|
|
25
|
+
<PersonCard
|
|
26
|
+
photos={p.photos.map((src) => ({ src }))}
|
|
27
|
+
name={p.name}
|
|
28
|
+
age={p.age}
|
|
29
|
+
badge={<VerifiedBadge label="Verified" onMedia size="lg" />}
|
|
30
|
+
meta={<span className="text-xs font-semibold">{`${p.km} km away`}</span>}
|
|
31
|
+
bio={p.bio}
|
|
32
|
+
footer={p.tags.map((t) => <Badge key={t} tone="scrim">{t}</Badge>)}
|
|
33
|
+
/>
|
|
34
|
+
)}
|
|
35
|
+
/>
|
|
36
|
+
);
|
|
37
|
+
}
|
|
Binary file
|