@expokit/cli 0.2.0 → 0.3.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 +14 -0
- package/bin/expo-kit.js +86 -24
- package/bin/mcp.mjs +8 -1
- package/package.json +8 -3
- package/registry/_docs/accordion.json +16 -0
- package/registry/_docs/action-sheet.json +28 -0
- package/registry/_docs/alert.json +28 -0
- package/registry/_docs/avatar.json +24 -0
- package/registry/_docs/badge.json +35 -4
- package/registry/_docs/bottom-nav.json +24 -0
- package/registry/_docs/bottom-sheet.json +28 -0
- package/registry/_docs/bullet.json +3 -0
- package/registry/_docs/button-3d.json +16 -0
- package/registry/_docs/button.json +16 -0
- package/registry/_docs/calendar.json +16 -0
- package/registry/_docs/card-stack.json +16 -0
- package/registry/_docs/card.json +20 -0
- package/registry/_docs/carousel.json +20 -0
- package/registry/_docs/chat.json +184 -0
- package/registry/_docs/checkbox.json +16 -0
- package/registry/_docs/checkout.json +3 -0
- package/registry/_docs/chip-group.json +16 -0
- package/registry/_docs/color-swatch.json +16 -0
- package/registry/_docs/confetti.json +20 -0
- package/registry/_docs/coupon.json +16 -0
- package/registry/_docs/cube-pager.json +16 -0
- package/registry/_docs/dashboard.json +3 -0
- package/registry/_docs/date-picker.json +20 -0
- package/registry/_docs/dialog.json +24 -0
- package/registry/_docs/drawer.json +28 -0
- package/registry/_docs/fab.json +24 -0
- package/registry/_docs/flip-card.json +16 -0
- package/registry/_docs/floating-input.json +20 -0
- package/registry/_docs/gift-card.json +16 -0
- package/registry/_docs/glass-button.json +24 -0
- package/registry/_docs/glass-nav-bar.json +24 -0
- package/registry/_docs/glass-search-bar.json +24 -0
- package/registry/_docs/glass-segmented.json +28 -0
- package/registry/_docs/glass-sheet.json +28 -0
- package/registry/_docs/glass-tab-bar.json +24 -0
- package/registry/_docs/glass.json +16 -0
- package/registry/_docs/inbox.json +3 -0
- package/registry/_docs/isometric-bar.json +3 -0
- package/registry/_docs/kit.json +3 -0
- package/registry/_docs/kpi-card.json +3 -0
- package/registry/_docs/like-button.json +20 -0
- package/registry/_docs/liquidglass-tab.json +3 -0
- package/registry/_docs/list-item.json +16 -0
- package/registry/_docs/loyalty-card.json +16 -0
- package/registry/_docs/morph-button.json +20 -0
- package/registry/_docs/number-ticker.json +16 -0
- package/registry/_docs/offers.json +3 -0
- package/registry/_docs/onboarding.json +3 -0
- package/registry/_docs/otp-input.json +24 -0
- package/registry/_docs/pagination-dots.json +20 -0
- package/registry/_docs/parallax-layers.json +20 -0
- package/registry/_docs/parallax-scroll.json +24 -0
- package/registry/_docs/password-input.json +20 -0
- package/registry/_docs/payment-card.json +16 -0
- package/registry/_docs/pixel-bar.json +3 -0
- package/registry/_docs/polar-area.json +3 -0
- package/registry/_docs/profile.json +3 -0
- package/registry/_docs/progress-steps.json +24 -0
- package/registry/_docs/progress.json +20 -0
- package/registry/_docs/radio-group.json +20 -0
- package/registry/_docs/rating.json +24 -0
- package/registry/_docs/ring-carousel.json +20 -0
- package/registry/_docs/scratch-card.json +20 -0
- package/registry/_docs/search-bar.json +20 -0
- package/registry/_docs/search-results.json +3 -0
- package/registry/_docs/segmented-control.json +20 -0
- package/registry/_docs/select.json +26 -1
- package/registry/_docs/settings.json +3 -0
- package/registry/_docs/shimmer-button.json +20 -0
- package/registry/_docs/sign-in.json +3 -0
- package/registry/_docs/skeleton.json +20 -0
- package/registry/_docs/slide-to-confirm.json +24 -0
- package/registry/_docs/slider.json +21 -1
- package/registry/_docs/spin-wheel.json +24 -0
- package/registry/_docs/spinner.json +41 -11
- package/registry/_docs/stateful-button.json +184 -0
- package/registry/_docs/stepper.json +16 -0
- package/registry/_docs/swipe-deck.json +16 -0
- package/registry/_docs/swipeable-row.json +24 -1
- package/registry/_docs/switch.json +20 -0
- package/registry/_docs/tabs.json +24 -0
- package/registry/_docs/tag-input.json +20 -0
- package/registry/_docs/text-animation.json +141 -0
- package/registry/_docs/textarea.json +16 -0
- package/registry/_docs/ticket-card.json +20 -0
- package/registry/_docs/ticket-shape.json +3 -0
- package/registry/_docs/tilt-card.json +16 -0
- package/registry/_docs/time-picker.json +16 -0
- package/registry/_docs/timeline-chart.json +3 -0
- package/registry/_docs/timeline.json +16 -0
- package/registry/_docs/toast.json +24 -0
- package/registry/_docs/treemap.json +3 -0
- package/registry/_docs/waterfall.json +3 -0
- package/registry/_docs/wheel-list.json +20 -0
- package/registry/badge/files/src/components/ui/badge.tsx +327 -17
- package/registry/badge.json +1 -1
- package/registry/chat.json +18 -0
- package/registry/spinner/files/src/components/ui/spinner.tsx +435 -22
- package/registry/spinner.json +1 -1
- package/registry/stateful-button/files/src/components/ui/stateful-button.tsx +532 -0
- package/registry/stateful-button/files/src/lib/kit.tsx +219 -0
- package/registry/stateful-button.json +18 -0
- package/registry/text-animation/files/src/components/ui/text-animation.tsx +650 -0
- package/registry/text-animation/files/src/lib/kit.tsx +219 -0
- package/registry/text-animation.json +15 -0
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
"files": [
|
|
7
7
|
"src/components/ui/number-ticker.tsx"
|
|
8
8
|
],
|
|
9
|
+
"summary": "Each digit rolls like an odometer, flashing green or red as it changes.",
|
|
9
10
|
"props": [
|
|
10
11
|
[
|
|
11
12
|
"value",
|
|
@@ -92,5 +93,20 @@
|
|
|
92
93
|
"Style for the row of digits."
|
|
93
94
|
]
|
|
94
95
|
],
|
|
96
|
+
"behavior": [
|
|
97
|
+
[
|
|
98
|
+
"Motion",
|
|
99
|
+
"Each digit springs along its own 0–9 strip, up when the value grows and down when it shrinks, staggered right to left. The text briefly tints green or red on every change."
|
|
100
|
+
],
|
|
101
|
+
[
|
|
102
|
+
"Screen readers",
|
|
103
|
+
"The whole number is one text element, read with its prefix and suffix instead of digit by digit."
|
|
104
|
+
],
|
|
105
|
+
[
|
|
106
|
+
"Platforms",
|
|
107
|
+
"Plain Animated views on iOS, Android and web. The digit rolls use the native driver; only the colour flash runs in JS."
|
|
108
|
+
]
|
|
109
|
+
],
|
|
110
|
+
"usage": null,
|
|
95
111
|
"examples": []
|
|
96
112
|
}
|
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
"files": [
|
|
7
7
|
"src/components/ui/otp-input.tsx"
|
|
8
8
|
],
|
|
9
|
+
"summary": "Digits pop into cells that size themselves, with SMS autofill and paste.",
|
|
9
10
|
"props": [
|
|
10
11
|
[
|
|
11
12
|
"length",
|
|
@@ -104,6 +105,29 @@
|
|
|
104
105
|
"Style for the root view around the cells and message."
|
|
105
106
|
]
|
|
106
107
|
],
|
|
108
|
+
"behavior": [
|
|
109
|
+
[
|
|
110
|
+
"Touch",
|
|
111
|
+
"Tapping the row focuses one hidden number-pad input. Pasting a code like 123-456 strips the non-digits and fills every cell."
|
|
112
|
+
],
|
|
113
|
+
[
|
|
114
|
+
"Motion",
|
|
115
|
+
"Digits pop in on a bouncy spring and the active cell glows with a halo and a blinking caret. Errors shake the row; success pulses across the cells."
|
|
116
|
+
],
|
|
117
|
+
[
|
|
118
|
+
"Platforms",
|
|
119
|
+
"Sets textContentType 'oneTimeCode' and autoComplete 'one-time-code', so codes from SMS can autofill."
|
|
120
|
+
],
|
|
121
|
+
[
|
|
122
|
+
"Screen readers",
|
|
123
|
+
"The cells are hidden; the input is labelled 'One-time code, 6 digits' with a hint. Helper, error and success messages are a polite live region."
|
|
124
|
+
],
|
|
125
|
+
[
|
|
126
|
+
"Web",
|
|
127
|
+
"The browser focus outline is removed; the border and halo show focus instead."
|
|
128
|
+
]
|
|
129
|
+
],
|
|
130
|
+
"usage": "import { useState } from 'react';\nimport { OtpInput } from '@/components/ui/otp-input';\n\nconst [code, setCode] = useState('');\n<OtpInput value={code} onChangeText={setCode} helperText=\"Sent to +1 415 555 0132\" />",
|
|
107
131
|
"examples": [
|
|
108
132
|
{
|
|
109
133
|
"name": "VerifyPhone",
|
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
"files": [
|
|
7
7
|
"src/components/ui/pagination-dots.tsx"
|
|
8
8
|
],
|
|
9
|
+
"summary": "The active dot stretches into a pill that follows your swipe live.",
|
|
9
10
|
"props": [
|
|
10
11
|
[
|
|
11
12
|
"count",
|
|
@@ -68,6 +69,25 @@
|
|
|
68
69
|
"Style for the row of dots (the numbers pill or line track in those variants)."
|
|
69
70
|
]
|
|
70
71
|
],
|
|
72
|
+
"behavior": [
|
|
73
|
+
[
|
|
74
|
+
"Motion",
|
|
75
|
+
"Pass a live progress value (scroll offset ÷ page width) and the indicator tracks the finger; with index alone it springs across. Variants stretch a pill, scale a dot, fill line segments or roll the page number."
|
|
76
|
+
],
|
|
77
|
+
[
|
|
78
|
+
"Touch",
|
|
79
|
+
"With onPress, each dot becomes a button with an enlarged hit area that reports its page."
|
|
80
|
+
],
|
|
81
|
+
[
|
|
82
|
+
"Screen readers",
|
|
83
|
+
"Read as one element with 'N of M'. With onPress it is adjustable, so swiping up or down changes the page."
|
|
84
|
+
],
|
|
85
|
+
[
|
|
86
|
+
"Platforms",
|
|
87
|
+
"The 'dots' variant animates widths, so drive its progress with useNativeDriver: false. The other variants work with either driver."
|
|
88
|
+
]
|
|
89
|
+
],
|
|
90
|
+
"usage": "import { useState } from 'react';\nimport { PaginationDots } from '@/components/ui/pagination-dots';\n\nconst [page, setPage] = useState(0);\n<PaginationDots count={4} index={page} onPress={setPage} />",
|
|
71
91
|
"examples": [
|
|
72
92
|
{
|
|
73
93
|
"name": "Onboarding",
|
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
"files": [
|
|
7
7
|
"src/components/ui/parallax-layers.tsx"
|
|
8
8
|
],
|
|
9
|
+
"summary": "Drag across a layered scene: near layers slide further while it tilts in 3D.",
|
|
9
10
|
"props": [
|
|
10
11
|
[
|
|
11
12
|
"children",
|
|
@@ -80,5 +81,24 @@
|
|
|
80
81
|
"Style for the layer (it fills the scene)."
|
|
81
82
|
]
|
|
82
83
|
],
|
|
84
|
+
"behavior": [
|
|
85
|
+
[
|
|
86
|
+
"Touch",
|
|
87
|
+
"The finger position steers the scene and release springs it back to centre. A parent ScrollView can still take over a scroll that starts on it."
|
|
88
|
+
],
|
|
89
|
+
[
|
|
90
|
+
"Motion",
|
|
91
|
+
"Each layer moves by its depth times travel while the whole scene tilts in perspective. Left alone, it drifts slowly on a loop."
|
|
92
|
+
],
|
|
93
|
+
[
|
|
94
|
+
"Screen readers",
|
|
95
|
+
"With accessibilityLabel the scene is one image element with that label; without it, it is not exposed."
|
|
96
|
+
],
|
|
97
|
+
[
|
|
98
|
+
"Platforms",
|
|
99
|
+
"Transforms run on the native driver with PanResponder, so it works on iOS, Android and web with no native modules."
|
|
100
|
+
]
|
|
101
|
+
],
|
|
102
|
+
"usage": null,
|
|
83
103
|
"examples": []
|
|
84
104
|
}
|
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
"files": [
|
|
7
7
|
"src/components/ui/parallax-scroll.tsx"
|
|
8
8
|
],
|
|
9
|
+
"summary": "A photo header glides slower than the content, then a title bar fades in.",
|
|
9
10
|
"props": [
|
|
10
11
|
[
|
|
11
12
|
"children",
|
|
@@ -182,5 +183,28 @@
|
|
|
182
183
|
"The live scroll offset (native-driver friendly), viewport size and content size for your own effects; null outside a ParallaxScrollView."
|
|
183
184
|
]
|
|
184
185
|
],
|
|
186
|
+
"behavior": [
|
|
187
|
+
[
|
|
188
|
+
"Motion",
|
|
189
|
+
"The header lags behind the scroll and darkens as it leaves. The bar, title and button bubbles fade in once it has scrolled under the bar."
|
|
190
|
+
],
|
|
191
|
+
[
|
|
192
|
+
"Touch",
|
|
193
|
+
"On iOS, pulling down past the top stretches the header to fill the gap. Set stretch to false when you use a refreshControl."
|
|
194
|
+
],
|
|
195
|
+
[
|
|
196
|
+
"Reduced motion",
|
|
197
|
+
"With Reduce Motion on, the header, ParallaxImage and ParallaxView parallax offsets switch off; the stretch and the fades stay."
|
|
198
|
+
],
|
|
199
|
+
[
|
|
200
|
+
"Screen readers",
|
|
201
|
+
"The bar comes first in reading order and its title is a header. Header and ParallaxImage photos are labelled images only when you give them a label."
|
|
202
|
+
],
|
|
203
|
+
[
|
|
204
|
+
"Platforms",
|
|
205
|
+
"The scroll offset drives everything through a native Animated.event, so there is no JS work while scrolling."
|
|
206
|
+
]
|
|
207
|
+
],
|
|
208
|
+
"usage": null,
|
|
185
209
|
"examples": []
|
|
186
210
|
}
|
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
"files": [
|
|
7
7
|
"src/components/ui/password-input.tsx"
|
|
8
8
|
],
|
|
9
|
+
"summary": "An eye toggle that twists between states, and a strength meter that springs full.",
|
|
9
10
|
"props": [
|
|
10
11
|
[
|
|
11
12
|
"strength",
|
|
@@ -62,6 +63,25 @@
|
|
|
62
63
|
"Every Floating Input prop (error, success, size, variant, …)."
|
|
63
64
|
]
|
|
64
65
|
],
|
|
66
|
+
"behavior": [
|
|
67
|
+
[
|
|
68
|
+
"Touch",
|
|
69
|
+
"The eye button has a 44pt hit area and toggles secureTextEntry. With confirmOf, a match or mismatch message appears as soon as the typing diverges."
|
|
70
|
+
],
|
|
71
|
+
[
|
|
72
|
+
"Motion",
|
|
73
|
+
"Eye and eye-off cross-fade with a spring twist. The four meter segments fill left to right in a stagger, and checklist ticks pop in as rules are met."
|
|
74
|
+
],
|
|
75
|
+
[
|
|
76
|
+
"Keyboard",
|
|
77
|
+
"Auto-capitalisation and autocorrect are turned off for the field."
|
|
78
|
+
],
|
|
79
|
+
[
|
|
80
|
+
"Screen readers",
|
|
81
|
+
"The toggle is a button labelled 'Show password' or 'Hide password'. The meter reads 'Password strength: Strong' and each requirement reads as done or not yet."
|
|
82
|
+
]
|
|
83
|
+
],
|
|
84
|
+
"usage": "import { useState } from 'react';\nimport { PasswordInput } from '@/components/ui/password-input';\n\nconst [password, setPassword] = useState('');\n<PasswordInput label=\"New password\" value={password} onChangeText={setPassword} requirements />",
|
|
65
85
|
"examples": [
|
|
66
86
|
{
|
|
67
87
|
"name": "CreatePassword",
|
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
"files": [
|
|
7
7
|
"src/components/ui/payment-card.tsx"
|
|
8
8
|
],
|
|
9
|
+
"summary": "A bank card that tilts toward your finger and flips on tap to its back.",
|
|
9
10
|
"props": [
|
|
10
11
|
[
|
|
11
12
|
"number",
|
|
@@ -128,6 +129,21 @@
|
|
|
128
129
|
"Style for the root (width, margins)."
|
|
129
130
|
]
|
|
130
131
|
],
|
|
132
|
+
"behavior": [
|
|
133
|
+
[
|
|
134
|
+
"Touch",
|
|
135
|
+
"A tap flips the card to its back (stripe, signature panel, CVV, hologram); frozen cards ignore taps. flippable={false} makes a still card for use inside something tappable."
|
|
136
|
+
],
|
|
137
|
+
[
|
|
138
|
+
"Motion",
|
|
139
|
+
"With tilt on, the card leans toward the finger with a soft glare, and its shadow narrows as it turns edge-on mid-flip."
|
|
140
|
+
],
|
|
141
|
+
[
|
|
142
|
+
"Screen readers",
|
|
143
|
+
"Read as '{bank} card ending {last4}', plus 'Frozen' when frozen. The number is masked to the last four digits by default."
|
|
144
|
+
]
|
|
145
|
+
],
|
|
146
|
+
"usage": "import { PaymentCard } from '@/components/ui/payment-card';\n\n<PaymentCard\n bank=\"Northwind\"\n number=\"5412 7590 1234 0317\"\n name=\"Maya Patel\"\n expiry=\"09/29\"\n brand=\"mastercard\"\n/>",
|
|
131
147
|
"examples": [
|
|
132
148
|
{
|
|
133
149
|
"name": "WalletScreen",
|
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
"files": [
|
|
7
7
|
"src/components/ui/progress-steps.tsx"
|
|
8
8
|
],
|
|
9
|
+
"summary": "Finished steps pop and draw a check while the line pours into the next one.",
|
|
9
10
|
"props": [
|
|
10
11
|
[
|
|
11
12
|
"steps",
|
|
@@ -62,6 +63,29 @@
|
|
|
62
63
|
"Style for the step row / column (the bar container in the bar variant)."
|
|
63
64
|
]
|
|
64
65
|
],
|
|
66
|
+
"behavior": [
|
|
67
|
+
[
|
|
68
|
+
"Motion",
|
|
69
|
+
"When current changes, the finished node pops and draws its check, the connector fills toward the next step and the new step lights up. The current step's ring pulses."
|
|
70
|
+
],
|
|
71
|
+
[
|
|
72
|
+
"Touch",
|
|
73
|
+
"With onStepPress, steps become buttons that squish on press; pressableSteps='completed' limits taps to finished steps."
|
|
74
|
+
],
|
|
75
|
+
[
|
|
76
|
+
"Haptics",
|
|
77
|
+
"A selection tick plays whenever current changes (haptics, on by default)."
|
|
78
|
+
],
|
|
79
|
+
[
|
|
80
|
+
"Reduced motion",
|
|
81
|
+
"Steps move with a short timing instead of springs, the ring stops pulsing and the done node appears without the overshoot pop."
|
|
82
|
+
],
|
|
83
|
+
[
|
|
84
|
+
"Screen readers",
|
|
85
|
+
"Each step reads like 'Step 2 of 4, Shipping, current'. The bar variant is a progressbar labelled 'Step N of M' with the step name."
|
|
86
|
+
]
|
|
87
|
+
],
|
|
88
|
+
"usage": "import { useState } from 'react';\nimport { ProgressSteps } from '@/components/ui/progress-steps';\n\nconst [step, setStep] = useState(1);\n<ProgressSteps steps={['Cart', 'Shipping', 'Payment', 'Review']} current={step} onStepPress={setStep} pressableSteps=\"completed\" />",
|
|
65
89
|
"examples": [
|
|
66
90
|
{
|
|
67
91
|
"name": "Checkout",
|
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
"files": [
|
|
7
7
|
"src/components/ui/progress.tsx"
|
|
8
8
|
],
|
|
9
|
+
"summary": "A bar, ring or segments with a glowing head; finishing flashes and draws a check.",
|
|
9
10
|
"props": [
|
|
10
11
|
[
|
|
11
12
|
"variant",
|
|
@@ -92,6 +93,25 @@
|
|
|
92
93
|
"Style for the root view of the bar, ring or step row."
|
|
93
94
|
]
|
|
94
95
|
],
|
|
96
|
+
"behavior": [
|
|
97
|
+
[
|
|
98
|
+
"Motion",
|
|
99
|
+
"The fill springs to each value with a glow riding its head, and the ring's percentage counts up. Reaching max flashes the fill and morphs the value into a drawn check."
|
|
100
|
+
],
|
|
101
|
+
[
|
|
102
|
+
"Reduced motion",
|
|
103
|
+
"The completion flash, moving stripes and segment pop and pulse are skipped. The fill still springs and indeterminate loops still run."
|
|
104
|
+
],
|
|
105
|
+
[
|
|
106
|
+
"Screen readers",
|
|
107
|
+
"A progressbar with your label and its min, max and current value. Indeterminate progress is marked busy."
|
|
108
|
+
],
|
|
109
|
+
[
|
|
110
|
+
"Platforms",
|
|
111
|
+
"Transforms and opacity use the native driver; only the ring's SVG stroke and the check drawing use the JS driver."
|
|
112
|
+
]
|
|
113
|
+
],
|
|
114
|
+
"usage": "import { Progress } from '@/components/ui/progress';\n\n<Progress value={64} label=\"Uploading trip-to-lisbon.mov\" showValue />\n<Progress variant=\"circular\" value={64} />",
|
|
95
115
|
"examples": [
|
|
96
116
|
{
|
|
97
117
|
"name": "Linear",
|
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
"files": [
|
|
7
7
|
"src/components/ui/radio-group.tsx"
|
|
8
8
|
],
|
|
9
|
+
"summary": "The dot springs in with a ripple; cards light up and draw a check badge.",
|
|
9
10
|
"props": [
|
|
10
11
|
[
|
|
11
12
|
"options",
|
|
@@ -62,6 +63,25 @@
|
|
|
62
63
|
"Style for the group container (the bordered card in the segmented-list variant)."
|
|
63
64
|
]
|
|
64
65
|
],
|
|
66
|
+
"behavior": [
|
|
67
|
+
[
|
|
68
|
+
"Touch",
|
|
69
|
+
"Rows squish on press in the default and card variants, and the default dot has extra hitSlop. Disabled options are dimmed and ignore taps."
|
|
70
|
+
],
|
|
71
|
+
[
|
|
72
|
+
"Motion",
|
|
73
|
+
"The selected dot pops on a bouncy spring with a ripple ring. Cards tint their border and pop a self-drawing check; the list variant draws a tick."
|
|
74
|
+
],
|
|
75
|
+
[
|
|
76
|
+
"Haptics",
|
|
77
|
+
"A selection tick plays on each change (haptics, on by default)."
|
|
78
|
+
],
|
|
79
|
+
[
|
|
80
|
+
"Screen readers",
|
|
81
|
+
"The group is a radiogroup and each option a radio with checked and disabled state. Descriptions are read as hints."
|
|
82
|
+
]
|
|
83
|
+
],
|
|
84
|
+
"usage": "import { RadioGroup } from '@/components/ui/radio-group';\n\n<RadioGroup\n defaultValue=\"standard\"\n options={[\n { value: 'standard', label: 'Standard shipping', description: '4–6 business days · Free' },\n { value: 'express', label: 'Express', description: '1–2 business days · $9' },\n ]}\n/>",
|
|
65
85
|
"examples": [
|
|
66
86
|
{
|
|
67
87
|
"name": "Default",
|
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
"files": [
|
|
7
7
|
"src/components/ui/rating.tsx"
|
|
8
8
|
],
|
|
9
|
+
"summary": "Drag across the stars to rate; the top one throws a little spark burst.",
|
|
9
10
|
"props": [
|
|
10
11
|
[
|
|
11
12
|
"value / onValueChange",
|
|
@@ -86,5 +87,28 @@
|
|
|
86
87
|
"Style for the row of icons."
|
|
87
88
|
]
|
|
88
89
|
],
|
|
90
|
+
"behavior": [
|
|
91
|
+
[
|
|
92
|
+
"Touch",
|
|
93
|
+
"Tap or drag across the row to set the value, to half-icon precision with allowHalf. With clearable, tapping the current value clears it."
|
|
94
|
+
],
|
|
95
|
+
[
|
|
96
|
+
"Motion",
|
|
97
|
+
"Icons fill smoothly and pop in a quick stagger with a wobble. When you raise the rating, the top icon throws a spark burst."
|
|
98
|
+
],
|
|
99
|
+
[
|
|
100
|
+
"Haptics",
|
|
101
|
+
"A selection tick plays for every step while tapping or dragging."
|
|
102
|
+
],
|
|
103
|
+
[
|
|
104
|
+
"Screen readers",
|
|
105
|
+
"One adjustable element read as 'N of 5'. Swipe up or down to change it by one step."
|
|
106
|
+
],
|
|
107
|
+
[
|
|
108
|
+
"Web",
|
|
109
|
+
"Works with the mouse too, and shows a pointer cursor while interactive."
|
|
110
|
+
]
|
|
111
|
+
],
|
|
112
|
+
"usage": null,
|
|
89
113
|
"examples": []
|
|
90
114
|
}
|
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
"files": [
|
|
7
7
|
"src/components/ui/ring-carousel.tsx"
|
|
8
8
|
],
|
|
9
|
+
"summary": "Cards on a 3D ring you spin with a swipe; it snaps and loops forever.",
|
|
9
10
|
"props": [
|
|
10
11
|
[
|
|
11
12
|
"data",
|
|
@@ -98,5 +99,24 @@
|
|
|
98
99
|
"Style for the root view."
|
|
99
100
|
]
|
|
100
101
|
],
|
|
102
|
+
"behavior": [
|
|
103
|
+
[
|
|
104
|
+
"Touch",
|
|
105
|
+
"Horizontal drags spin the ring and a flick carries it a little further before snapping. Tapping a side card turns to it; tapping the front card calls onPress."
|
|
106
|
+
],
|
|
107
|
+
[
|
|
108
|
+
"Motion",
|
|
109
|
+
"Neighbours turn, shrink and fall into shadow as they go round the back. With autoplay it advances every 3s by default and pauses while touched."
|
|
110
|
+
],
|
|
111
|
+
[
|
|
112
|
+
"Screen readers",
|
|
113
|
+
"The ring is one adjustable element ('2 / 7'): swipe up or down to turn it, double-tap to press the front card. Side cards are hidden."
|
|
114
|
+
],
|
|
115
|
+
[
|
|
116
|
+
"Platforms",
|
|
117
|
+
"The loop runs on the native driver via Animated.modulo. Each card turns in its own flat layer so iOS never slices a side card into the front one."
|
|
118
|
+
]
|
|
119
|
+
],
|
|
120
|
+
"usage": null,
|
|
101
121
|
"examples": []
|
|
102
122
|
}
|
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
"files": [
|
|
7
7
|
"src/components/ui/scratch-card.tsx"
|
|
8
8
|
],
|
|
9
|
+
"summary": "Rub a shimmering foil away; past a threshold the rest clears with a haptic tap.",
|
|
9
10
|
"props": [
|
|
10
11
|
[
|
|
11
12
|
"children",
|
|
@@ -86,5 +87,24 @@
|
|
|
86
87
|
"Width, margins."
|
|
87
88
|
]
|
|
88
89
|
],
|
|
90
|
+
"behavior": [
|
|
91
|
+
[
|
|
92
|
+
"Touch",
|
|
93
|
+
"Your finger scratches the foil away with a round brush, and once threshold of it is gone the rest clears by itself. The card keeps the touch, so a parent ScrollView cannot steal it mid-rub."
|
|
94
|
+
],
|
|
95
|
+
[
|
|
96
|
+
"Motion",
|
|
97
|
+
"A light band sweeps across the foil until the first touch. On reveal the foil fades out while scaling up slightly."
|
|
98
|
+
],
|
|
99
|
+
[
|
|
100
|
+
"Haptics",
|
|
101
|
+
"A success notification plays when the foil clears."
|
|
102
|
+
],
|
|
103
|
+
[
|
|
104
|
+
"Screen readers",
|
|
105
|
+
"The foil is a button labelled with label and sublabel, with the hint 'Double-tap to reveal'."
|
|
106
|
+
]
|
|
107
|
+
],
|
|
108
|
+
"usage": null,
|
|
89
109
|
"examples": []
|
|
90
110
|
}
|
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
"files": [
|
|
7
7
|
"src/components/ui/search-bar.tsx"
|
|
8
8
|
],
|
|
9
|
+
"summary": "Focus pops the magnifier and springs in Cancel; suggestions drop down below.",
|
|
9
10
|
"props": [
|
|
10
11
|
[
|
|
11
12
|
"variant",
|
|
@@ -110,6 +111,25 @@
|
|
|
110
111
|
"placeholder, onSubmitEditing, autoFocus, …"
|
|
111
112
|
]
|
|
112
113
|
],
|
|
114
|
+
"behavior": [
|
|
115
|
+
[
|
|
116
|
+
"Motion",
|
|
117
|
+
"On focus a halo glows and the magnifier pops; Cancel slides in as the field springs narrower and the clear button scales in. loading swaps the magnifier for a spinning arc."
|
|
118
|
+
],
|
|
119
|
+
[
|
|
120
|
+
"Touch",
|
|
121
|
+
"The 'minimal' variant rests as a round icon and expands into a full field when tapped. Picking a suggestion fills the query and dismisses the keyboard."
|
|
122
|
+
],
|
|
123
|
+
[
|
|
124
|
+
"Screen readers",
|
|
125
|
+
"The input has the search role, labelled by its placeholder. 'Clear search', Cancel and each suggestion are labelled buttons."
|
|
126
|
+
],
|
|
127
|
+
[
|
|
128
|
+
"Web",
|
|
129
|
+
"The browser outline is replaced by the border and halo, and the suggestion panel stays open a beat after blur so clicks land."
|
|
130
|
+
]
|
|
131
|
+
],
|
|
132
|
+
"usage": "import { useState } from 'react';\nimport { SearchBar } from '@/components/ui/search-bar';\n\nconst [query, setQuery] = useState('');\n<SearchBar value={query} onChangeText={setQuery} placeholder=\"Search products\" />",
|
|
113
133
|
"examples": [
|
|
114
134
|
{
|
|
115
135
|
"name": "WithSuggestions",
|
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
"files": [
|
|
7
7
|
"src/components/ui/segmented-control.tsx"
|
|
8
8
|
],
|
|
9
|
+
"summary": "A liquid indicator that stretches as it slides; drag it to scrub.",
|
|
9
10
|
"props": [
|
|
10
11
|
[
|
|
11
12
|
"options",
|
|
@@ -68,6 +69,25 @@
|
|
|
68
69
|
"Style for the track holding the segments."
|
|
69
70
|
]
|
|
70
71
|
],
|
|
72
|
+
"behavior": [
|
|
73
|
+
[
|
|
74
|
+
"Motion",
|
|
75
|
+
"The leading edge of the indicator springs ahead and the trailing edge catches up, so it stretches as it travels. Labels squish on press and bounce when selected."
|
|
76
|
+
],
|
|
77
|
+
[
|
|
78
|
+
"Touch",
|
|
79
|
+
"A sideways drag that starts on the selected segment scrubs across the others; drags that start elsewhere are left to a parent ScrollView. Short segments get hitSlop up to 44pt."
|
|
80
|
+
],
|
|
81
|
+
[
|
|
82
|
+
"Haptics",
|
|
83
|
+
"A selection tick plays on each change (haptics, on by default)."
|
|
84
|
+
],
|
|
85
|
+
[
|
|
86
|
+
"Screen readers",
|
|
87
|
+
"A tablist of tabs with selected and disabled state, labelled by each option's label or accessibilityLabel."
|
|
88
|
+
]
|
|
89
|
+
],
|
|
90
|
+
"usage": "import { useState } from 'react';\nimport { SegmentedControl } from '@/components/ui/segmented-control';\n\nconst [range, setRange] = useState('Week');\n<SegmentedControl options={['Day', 'Week', 'Month', 'Year']} value={range} onValueChange={setRange} />",
|
|
71
91
|
"examples": [
|
|
72
92
|
{
|
|
73
93
|
"name": "Pill",
|
|
@@ -1,11 +1,17 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "select",
|
|
3
3
|
"category": "Inputs",
|
|
4
|
-
"aliases": [
|
|
4
|
+
"aliases": [
|
|
5
|
+
"multi-select",
|
|
6
|
+
"multiselect",
|
|
7
|
+
"combobox",
|
|
8
|
+
"dropdown"
|
|
9
|
+
],
|
|
5
10
|
"exportName": "Select",
|
|
6
11
|
"files": [
|
|
7
12
|
"src/components/ui/select.tsx"
|
|
8
13
|
],
|
|
14
|
+
"summary": "A dropdown or sheet picker with a floating label; multi-select shows removable chips.",
|
|
9
15
|
"props": [
|
|
10
16
|
[
|
|
11
17
|
"options",
|
|
@@ -212,6 +218,25 @@
|
|
|
212
218
|
"Each option's label text."
|
|
213
219
|
]
|
|
214
220
|
],
|
|
221
|
+
"behavior": [
|
|
222
|
+
[
|
|
223
|
+
"Touch",
|
|
224
|
+
"Tapping the field opens a dropdown anchored under it, flipping above when there's no room. presentation='sheet' slides up a bottom sheet you drag down to dismiss (a centred dialog on wide screens)."
|
|
225
|
+
],
|
|
226
|
+
[
|
|
227
|
+
"Motion",
|
|
228
|
+
"The label floats onto the border, a focus halo glows and the chevron turns. In multiple mode chips pop in and collapse out, overflowing into a '+N' chip."
|
|
229
|
+
],
|
|
230
|
+
[
|
|
231
|
+
"Keyboard",
|
|
232
|
+
"On web, arrow keys move the highlight, Home and End jump, Enter picks, and Escape or Tab close the menu."
|
|
233
|
+
],
|
|
234
|
+
[
|
|
235
|
+
"Screen readers",
|
|
236
|
+
"The field is a combobox whose value lists the selection, with an expanded state. Options are menu items, or checkboxes in multiple mode."
|
|
237
|
+
]
|
|
238
|
+
],
|
|
239
|
+
"usage": "import { useState } from 'react';\nimport { Select } from '@/components/ui/select';\n\nconst [team, setTeam] = useState<string[]>([]);\n<Select multiple label=\"Assignees\" options={['Amelia', 'Ravi', 'Sofia', 'Kenji']} values={team} onValuesChange={setTeam} />",
|
|
215
240
|
"examples": [
|
|
216
241
|
{
|
|
217
242
|
"name": "Validation",
|