@idealyst/mcp-server 1.0.87 → 1.0.88

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.
Files changed (205) hide show
  1. package/ARCHITECTURE.md +313 -0
  2. package/README.md +292 -104
  3. package/TYPE-SYSTEM.md +397 -0
  4. package/dist/index.js +170 -1
  5. package/examples/components/Accordion.examples.tsx +147 -0
  6. package/examples/components/ActivityIndicator.examples.tsx +350 -0
  7. package/examples/components/Alert.examples.tsx +335 -0
  8. package/examples/components/Avatar.examples.tsx +188 -0
  9. package/examples/components/Badge.examples.tsx +242 -0
  10. package/examples/components/Breadcrumb.examples.tsx +303 -0
  11. package/examples/components/Button.examples.tsx +113 -0
  12. package/examples/components/Card.examples.tsx +131 -0
  13. package/examples/components/Checkbox.examples.tsx +195 -0
  14. package/examples/components/Chip.examples.tsx +87 -0
  15. package/examples/components/Dialog.examples.tsx +344 -0
  16. package/examples/components/Divider.examples.tsx +258 -0
  17. package/examples/components/Icon.examples.tsx +202 -0
  18. package/examples/components/Input.examples.tsx +205 -0
  19. package/examples/components/Menu.examples.tsx +321 -0
  20. package/examples/components/Popover.examples.tsx +439 -0
  21. package/examples/components/Progress.examples.tsx +340 -0
  22. package/examples/components/RadioButton.examples.tsx +443 -0
  23. package/examples/components/Screen.examples.tsx +347 -0
  24. package/examples/components/Select.examples.tsx +279 -0
  25. package/examples/components/Skeleton.examples.tsx +278 -0
  26. package/examples/components/Slider.examples.tsx +249 -0
  27. package/examples/components/Switch.examples.tsx +94 -0
  28. package/examples/components/TabBar.examples.tsx +356 -0
  29. package/examples/components/Text.examples.tsx +177 -0
  30. package/examples/components/TextArea.examples.tsx +203 -0
  31. package/examples/components/Tooltip.examples.tsx +318 -0
  32. package/examples/components/View.examples.tsx +307 -0
  33. package/package.json +15 -2
  34. package/scripts/extract-types.ts +71 -0
  35. package/scripts/type-extractor.ts +286 -0
  36. package/scripts/validate-examples.ts +142 -0
  37. package/src/data/components/Icon.ts +1 -1
  38. package/src/data/components/index.ts +2 -0
  39. package/src/index.ts +181 -1
  40. package/src/tools/get-types.ts +169 -0
  41. package/tsconfig.examples.json +14 -0
  42. package/dist/data/cli-commands.d.ts +0 -2
  43. package/dist/data/cli-commands.d.ts.map +0 -1
  44. package/dist/data/cli-commands.js +0 -100
  45. package/dist/data/cli-commands.js.map +0 -1
  46. package/dist/data/components/Accordion.d.ts +0 -15
  47. package/dist/data/components/Accordion.d.ts.map +0 -1
  48. package/dist/data/components/Accordion.js +0 -112
  49. package/dist/data/components/Accordion.js.map +0 -1
  50. package/dist/data/components/ActivityIndicator.d.ts +0 -15
  51. package/dist/data/components/ActivityIndicator.d.ts.map +0 -1
  52. package/dist/data/components/ActivityIndicator.js +0 -82
  53. package/dist/data/components/ActivityIndicator.js.map +0 -1
  54. package/dist/data/components/Alert.d.ts +0 -15
  55. package/dist/data/components/Alert.d.ts.map +0 -1
  56. package/dist/data/components/Alert.js +0 -132
  57. package/dist/data/components/Alert.js.map +0 -1
  58. package/dist/data/components/Avatar.d.ts +0 -15
  59. package/dist/data/components/Avatar.d.ts.map +0 -1
  60. package/dist/data/components/Avatar.js +0 -93
  61. package/dist/data/components/Avatar.js.map +0 -1
  62. package/dist/data/components/Badge.d.ts +0 -15
  63. package/dist/data/components/Badge.d.ts.map +0 -1
  64. package/dist/data/components/Badge.js +0 -64
  65. package/dist/data/components/Badge.js.map +0 -1
  66. package/dist/data/components/Breadcrumb.d.ts +0 -15
  67. package/dist/data/components/Breadcrumb.d.ts.map +0 -1
  68. package/dist/data/components/Breadcrumb.js +0 -96
  69. package/dist/data/components/Breadcrumb.js.map +0 -1
  70. package/dist/data/components/Button.d.ts +0 -15
  71. package/dist/data/components/Button.d.ts.map +0 -1
  72. package/dist/data/components/Button.js +0 -87
  73. package/dist/data/components/Button.js.map +0 -1
  74. package/dist/data/components/Card.d.ts +0 -15
  75. package/dist/data/components/Card.d.ts.map +0 -1
  76. package/dist/data/components/Card.js +0 -67
  77. package/dist/data/components/Card.js.map +0 -1
  78. package/dist/data/components/Checkbox.d.ts +0 -15
  79. package/dist/data/components/Checkbox.d.ts.map +0 -1
  80. package/dist/data/components/Checkbox.js +0 -118
  81. package/dist/data/components/Checkbox.js.map +0 -1
  82. package/dist/data/components/Chip.d.ts +0 -15
  83. package/dist/data/components/Chip.d.ts.map +0 -1
  84. package/dist/data/components/Chip.js +0 -76
  85. package/dist/data/components/Chip.js.map +0 -1
  86. package/dist/data/components/Dialog.d.ts +0 -15
  87. package/dist/data/components/Dialog.d.ts.map +0 -1
  88. package/dist/data/components/Dialog.js +0 -137
  89. package/dist/data/components/Dialog.js.map +0 -1
  90. package/dist/data/components/Divider.d.ts +0 -15
  91. package/dist/data/components/Divider.d.ts.map +0 -1
  92. package/dist/data/components/Divider.js +0 -71
  93. package/dist/data/components/Divider.js.map +0 -1
  94. package/dist/data/components/Icon.d.ts +0 -15
  95. package/dist/data/components/Icon.d.ts.map +0 -1
  96. package/dist/data/components/Icon.js +0 -70
  97. package/dist/data/components/Icon.js.map +0 -1
  98. package/dist/data/components/Image.d.ts +0 -15
  99. package/dist/data/components/Image.d.ts.map +0 -1
  100. package/dist/data/components/Image.js +0 -122
  101. package/dist/data/components/Image.js.map +0 -1
  102. package/dist/data/components/Input.d.ts +0 -15
  103. package/dist/data/components/Input.d.ts.map +0 -1
  104. package/dist/data/components/Input.js +0 -109
  105. package/dist/data/components/Input.js.map +0 -1
  106. package/dist/data/components/List.d.ts +0 -15
  107. package/dist/data/components/List.d.ts.map +0 -1
  108. package/dist/data/components/List.js +0 -113
  109. package/dist/data/components/List.js.map +0 -1
  110. package/dist/data/components/Menu.d.ts +0 -15
  111. package/dist/data/components/Menu.d.ts.map +0 -1
  112. package/dist/data/components/Menu.js +0 -132
  113. package/dist/data/components/Menu.js.map +0 -1
  114. package/dist/data/components/Popover.d.ts +0 -15
  115. package/dist/data/components/Popover.d.ts.map +0 -1
  116. package/dist/data/components/Popover.js +0 -159
  117. package/dist/data/components/Popover.js.map +0 -1
  118. package/dist/data/components/Pressable.d.ts +0 -15
  119. package/dist/data/components/Pressable.d.ts.map +0 -1
  120. package/dist/data/components/Pressable.js +0 -125
  121. package/dist/data/components/Pressable.js.map +0 -1
  122. package/dist/data/components/Progress.d.ts +0 -15
  123. package/dist/data/components/Progress.d.ts.map +0 -1
  124. package/dist/data/components/Progress.js +0 -95
  125. package/dist/data/components/Progress.js.map +0 -1
  126. package/dist/data/components/RadioButton.d.ts +0 -15
  127. package/dist/data/components/RadioButton.d.ts.map +0 -1
  128. package/dist/data/components/RadioButton.js +0 -140
  129. package/dist/data/components/RadioButton.js.map +0 -1
  130. package/dist/data/components/SVGImage.d.ts +0 -15
  131. package/dist/data/components/SVGImage.d.ts.map +0 -1
  132. package/dist/data/components/SVGImage.js +0 -112
  133. package/dist/data/components/SVGImage.js.map +0 -1
  134. package/dist/data/components/Screen.d.ts +0 -15
  135. package/dist/data/components/Screen.d.ts.map +0 -1
  136. package/dist/data/components/Screen.js +0 -99
  137. package/dist/data/components/Screen.js.map +0 -1
  138. package/dist/data/components/Select.d.ts +0 -15
  139. package/dist/data/components/Select.d.ts.map +0 -1
  140. package/dist/data/components/Select.js +0 -146
  141. package/dist/data/components/Select.js.map +0 -1
  142. package/dist/data/components/Skeleton.d.ts +0 -15
  143. package/dist/data/components/Skeleton.d.ts.map +0 -1
  144. package/dist/data/components/Skeleton.js +0 -110
  145. package/dist/data/components/Skeleton.js.map +0 -1
  146. package/dist/data/components/Slider.d.ts +0 -15
  147. package/dist/data/components/Slider.d.ts.map +0 -1
  148. package/dist/data/components/Slider.js +0 -129
  149. package/dist/data/components/Slider.js.map +0 -1
  150. package/dist/data/components/Switch.d.ts +0 -15
  151. package/dist/data/components/Switch.d.ts.map +0 -1
  152. package/dist/data/components/Switch.js +0 -127
  153. package/dist/data/components/Switch.js.map +0 -1
  154. package/dist/data/components/TabBar.d.ts +0 -15
  155. package/dist/data/components/TabBar.d.ts.map +0 -1
  156. package/dist/data/components/TabBar.js +0 -145
  157. package/dist/data/components/TabBar.js.map +0 -1
  158. package/dist/data/components/Table.d.ts +0 -15
  159. package/dist/data/components/Table.d.ts.map +0 -1
  160. package/dist/data/components/Table.js +0 -151
  161. package/dist/data/components/Table.js.map +0 -1
  162. package/dist/data/components/Tabs.d.ts +0 -15
  163. package/dist/data/components/Tabs.d.ts.map +0 -1
  164. package/dist/data/components/Tabs.js +0 -150
  165. package/dist/data/components/Tabs.js.map +0 -1
  166. package/dist/data/components/Text.d.ts +0 -15
  167. package/dist/data/components/Text.d.ts.map +0 -1
  168. package/dist/data/components/Text.js +0 -85
  169. package/dist/data/components/Text.js.map +0 -1
  170. package/dist/data/components/TextArea.d.ts +0 -15
  171. package/dist/data/components/TextArea.d.ts.map +0 -1
  172. package/dist/data/components/TextArea.js +0 -155
  173. package/dist/data/components/TextArea.js.map +0 -1
  174. package/dist/data/components/Tooltip.d.ts +0 -15
  175. package/dist/data/components/Tooltip.d.ts.map +0 -1
  176. package/dist/data/components/Tooltip.js +0 -105
  177. package/dist/data/components/Tooltip.js.map +0 -1
  178. package/dist/data/components/Video.d.ts +0 -15
  179. package/dist/data/components/Video.d.ts.map +0 -1
  180. package/dist/data/components/Video.js +0 -168
  181. package/dist/data/components/Video.js.map +0 -1
  182. package/dist/data/components/View.d.ts +0 -15
  183. package/dist/data/components/View.d.ts.map +0 -1
  184. package/dist/data/components/View.js +0 -126
  185. package/dist/data/components/View.js.map +0 -1
  186. package/dist/data/components/index.d.ts +0 -37
  187. package/dist/data/components/index.d.ts.map +0 -1
  188. package/dist/data/components/index.js +0 -110
  189. package/dist/data/components/index.js.map +0 -1
  190. package/dist/data/framework-guides.d.ts +0 -2
  191. package/dist/data/framework-guides.d.ts.map +0 -1
  192. package/dist/data/framework-guides.js +0 -589
  193. package/dist/data/framework-guides.js.map +0 -1
  194. package/dist/data/icon-guide.d.ts +0 -2
  195. package/dist/data/icon-guide.d.ts.map +0 -1
  196. package/dist/data/icon-guide.js +0 -285
  197. package/dist/data/icon-guide.js.map +0 -1
  198. package/dist/data/icons.json +0 -7452
  199. package/dist/data/navigation-guides.d.ts +0 -2
  200. package/dist/data/navigation-guides.d.ts.map +0 -1
  201. package/dist/data/navigation-guides.js +0 -1196
  202. package/dist/data/navigation-guides.js.map +0 -1
  203. package/dist/index.d.ts +0 -3
  204. package/dist/index.d.ts.map +0 -1
  205. package/dist/index.js.map +0 -1
@@ -0,0 +1,443 @@
1
+ /**
2
+ * RadioButton Component Examples
3
+ *
4
+ * These examples are type-checked against the actual RadioButtonProps interface
5
+ * to ensure accuracy and correctness.
6
+ */
7
+
8
+ import React from 'react';
9
+ import { RadioButton, View, Text } from '@idealyst/components';
10
+
11
+ // Example 1: Basic RadioButton
12
+ export function BasicRadioButton() {
13
+ const [selected, setSelected] = React.useState('option1');
14
+
15
+ return (
16
+ <View spacing="md">
17
+ <RadioButton
18
+ value="option1"
19
+ checked={selected === 'option1'}
20
+ onPress={() => setSelected('option1')}
21
+ label="Option 1"
22
+ />
23
+ <RadioButton
24
+ value="option2"
25
+ checked={selected === 'option2'}
26
+ onPress={() => setSelected('option2')}
27
+ label="Option 2"
28
+ />
29
+ <RadioButton
30
+ value="option3"
31
+ checked={selected === 'option3'}
32
+ onPress={() => setSelected('option3')}
33
+ label="Option 3"
34
+ />
35
+ </View>
36
+ );
37
+ }
38
+
39
+ // Example 2: RadioButton Sizes
40
+ export function RadioButtonSizes() {
41
+ const [selected, setSelected] = React.useState('md');
42
+
43
+ return (
44
+ <View spacing="md">
45
+ <RadioButton
46
+ value="xs"
47
+ checked={selected === 'xs'}
48
+ onPress={() => setSelected('xs')}
49
+ label="Extra Small"
50
+ size="xs"
51
+ />
52
+ <RadioButton
53
+ value="sm"
54
+ checked={selected === 'sm'}
55
+ onPress={() => setSelected('sm')}
56
+ label="Small"
57
+ size="sm"
58
+ />
59
+ <RadioButton
60
+ value="md"
61
+ checked={selected === 'md'}
62
+ onPress={() => setSelected('md')}
63
+ label="Medium"
64
+ size="md"
65
+ />
66
+ <RadioButton
67
+ value="lg"
68
+ checked={selected === 'lg'}
69
+ onPress={() => setSelected('lg')}
70
+ label="Large"
71
+ size="lg"
72
+ />
73
+ <RadioButton
74
+ value="xl"
75
+ checked={selected === 'xl'}
76
+ onPress={() => setSelected('xl')}
77
+ label="Extra Large"
78
+ size="xl"
79
+ />
80
+ </View>
81
+ );
82
+ }
83
+
84
+ // Example 3: RadioButton with Intent Colors
85
+ export function RadioButtonWithIntent() {
86
+ const [selected, setSelected] = React.useState('primary');
87
+
88
+ return (
89
+ <View spacing="md">
90
+ <RadioButton
91
+ value="primary"
92
+ checked={selected === 'primary'}
93
+ onPress={() => setSelected('primary')}
94
+ label="Primary"
95
+ intent="primary"
96
+ />
97
+ <RadioButton
98
+ value="success"
99
+ checked={selected === 'success'}
100
+ onPress={() => setSelected('success')}
101
+ label="Success"
102
+ intent="success"
103
+ />
104
+ <RadioButton
105
+ value="error"
106
+ checked={selected === 'error'}
107
+ onPress={() => setSelected('error')}
108
+ label="Error"
109
+ intent="error"
110
+ />
111
+ <RadioButton
112
+ value="warning"
113
+ checked={selected === 'warning'}
114
+ onPress={() => setSelected('warning')}
115
+ label="Warning"
116
+ intent="warning"
117
+ />
118
+ <RadioButton
119
+ value="info"
120
+ checked={selected === 'info'}
121
+ onPress={() => setSelected('info')}
122
+ label="Info"
123
+ intent="info"
124
+ />
125
+ <RadioButton
126
+ value="neutral"
127
+ checked={selected === 'neutral'}
128
+ onPress={() => setSelected('neutral')}
129
+ label="Neutral"
130
+ intent="neutral"
131
+ />
132
+ </View>
133
+ );
134
+ }
135
+
136
+ // Example 4: RadioButton Group with Header
137
+ export function RadioButtonGroup() {
138
+ const [preference, setPreference] = React.useState('email');
139
+
140
+ return (
141
+ <View spacing="md">
142
+ <Text weight="bold" size="md">
143
+ Contact Preference
144
+ </Text>
145
+ <View spacing="sm">
146
+ <RadioButton
147
+ value="email"
148
+ checked={preference === 'email'}
149
+ onPress={() => setPreference('email')}
150
+ label="Email"
151
+ />
152
+ <RadioButton
153
+ value="phone"
154
+ checked={preference === 'phone'}
155
+ onPress={() => setPreference('phone')}
156
+ label="Phone"
157
+ />
158
+ <RadioButton
159
+ value="sms"
160
+ checked={preference === 'sms'}
161
+ onPress={() => setPreference('sms')}
162
+ label="SMS"
163
+ />
164
+ <RadioButton
165
+ value="none"
166
+ checked={preference === 'none'}
167
+ onPress={() => setPreference('none')}
168
+ label="Do not contact me"
169
+ />
170
+ </View>
171
+ <Text size="sm" >
172
+ Selected: {preference}
173
+ </Text>
174
+ </View>
175
+ );
176
+ }
177
+
178
+ // Example 5: Disabled RadioButton
179
+ export function DisabledRadioButton() {
180
+ const [selected, setSelected] = React.useState('option1');
181
+
182
+ return (
183
+ <View spacing="md">
184
+ <RadioButton
185
+ value="option1"
186
+ checked={selected === 'option1'}
187
+ onPress={() => setSelected('option1')}
188
+ label="Available Option"
189
+ />
190
+ <RadioButton
191
+ value="option2"
192
+ checked={selected === 'option2'}
193
+ onPress={() => setSelected('option2')}
194
+ label="Disabled Unchecked"
195
+ disabled
196
+ />
197
+ <RadioButton
198
+ value="option3"
199
+ checked={true}
200
+ onPress={() => {}}
201
+ label="Disabled Checked"
202
+ disabled
203
+ />
204
+ </View>
205
+ );
206
+ }
207
+
208
+ // Example 6: Shipping Method Selection
209
+ export function ShippingMethodSelection() {
210
+ const [shipping, setShipping] = React.useState('standard');
211
+
212
+ const shippingOptions = [
213
+ { value: 'standard', label: 'Standard Shipping', price: 'Free', duration: '5-7 business days' },
214
+ { value: 'express', label: 'Express Shipping', price: '$9.99', duration: '2-3 business days' },
215
+ { value: 'overnight', label: 'Overnight Shipping', price: '$24.99', duration: '1 business day' },
216
+ ];
217
+
218
+ return (
219
+ <View spacing="lg">
220
+ <Text weight="bold" size="lg">
221
+ Select Shipping Method
222
+ </Text>
223
+ <View spacing="md">
224
+ {shippingOptions.map((option) => (
225
+ <View
226
+ key={option.value}
227
+ background="primary"
228
+ spacing="md"
229
+ radius="md"
230
+ border="thin"
231
+ style={{
232
+ borderColor: shipping === option.value ? 'blue' : 'gray',
233
+ }}
234
+ >
235
+ <RadioButton
236
+ value={option.value}
237
+ checked={shipping === option.value}
238
+ onPress={() => setShipping(option.value)}
239
+ label={option.label}
240
+ />
241
+ <View spacing="xs">
242
+ <Text size="sm" >
243
+ {option.price} • {option.duration}
244
+ </Text>
245
+ </View>
246
+ </View>
247
+ ))}
248
+ </View>
249
+ </View>
250
+ );
251
+ }
252
+
253
+ // Example 7: Payment Method Selection
254
+ export function PaymentMethodSelection() {
255
+ const [payment, setPayment] = React.useState('card');
256
+
257
+ return (
258
+ <View spacing="lg">
259
+ <Text weight="bold" size="lg">
260
+ Payment Method
261
+ </Text>
262
+ <View spacing="md">
263
+ <RadioButton
264
+ value="card"
265
+ checked={payment === 'card'}
266
+ onPress={() => setPayment('card')}
267
+ label="Credit or Debit Card"
268
+ />
269
+ <RadioButton
270
+ value="paypal"
271
+ checked={payment === 'paypal'}
272
+ onPress={() => setPayment('paypal')}
273
+ label="PayPal"
274
+ />
275
+ <RadioButton
276
+ value="bank"
277
+ checked={payment === 'bank'}
278
+ onPress={() => setPayment('bank')}
279
+ label="Bank Transfer"
280
+ />
281
+ <RadioButton
282
+ value="cash"
283
+ checked={payment === 'cash'}
284
+ onPress={() => setPayment('cash')}
285
+ label="Cash on Delivery"
286
+ />
287
+ </View>
288
+ </View>
289
+ );
290
+ }
291
+
292
+ // Example 8: Subscription Plan Selection
293
+ export function SubscriptionPlanSelection() {
294
+ const [plan, setPlan] = React.useState('pro');
295
+
296
+ const plans = [
297
+ { value: 'free', label: 'Free Plan', price: '$0/month', features: 'Basic features' },
298
+ { value: 'pro', label: 'Pro Plan', price: '$9.99/month', features: 'All features included' },
299
+ { value: 'enterprise', label: 'Enterprise Plan', price: '$29.99/month', features: 'Priority support' },
300
+ ];
301
+
302
+ return (
303
+ <View spacing="lg">
304
+ <Text weight="bold" size="lg">
305
+ Choose Your Plan
306
+ </Text>
307
+ <View spacing="md">
308
+ {plans.map((planOption) => (
309
+ <View
310
+ key={planOption.value}
311
+ background="primary"
312
+ spacing="lg"
313
+ radius="lg"
314
+ border="thin"
315
+ style={{
316
+ borderColor: plan === planOption.value ? 'blue' : 'gray',
317
+ }}
318
+ >
319
+ <RadioButton
320
+ value={planOption.value}
321
+ checked={plan === planOption.value}
322
+ onPress={() => setPlan(planOption.value)}
323
+ label={planOption.label}
324
+ intent={plan === planOption.value ? 'primary' : 'neutral'}
325
+ />
326
+ <View spacing="xs">
327
+ <Text weight="bold" size="lg">
328
+ {planOption.price}
329
+ </Text>
330
+ <Text size="sm" >
331
+ {planOption.features}
332
+ </Text>
333
+ </View>
334
+ </View>
335
+ ))}
336
+ </View>
337
+ </View>
338
+ );
339
+ }
340
+
341
+ // Example 9: Survey Question
342
+ export function SurveyQuestion() {
343
+ const [satisfaction, setSatisfaction] = React.useState<string>('');
344
+
345
+ return (
346
+ <View spacing="lg">
347
+ <View spacing="sm">
348
+ <Text weight="bold" size="md">
349
+ How satisfied are you with our service?
350
+ </Text>
351
+ <Text size="sm" >
352
+ Please select one option
353
+ </Text>
354
+ </View>
355
+ <View spacing="md">
356
+ <RadioButton
357
+ value="very-satisfied"
358
+ checked={satisfaction === 'very-satisfied'}
359
+ onPress={() => setSatisfaction('very-satisfied')}
360
+ label="Very Satisfied"
361
+ intent="success"
362
+ />
363
+ <RadioButton
364
+ value="satisfied"
365
+ checked={satisfaction === 'satisfied'}
366
+ onPress={() => setSatisfaction('satisfied')}
367
+ label="Satisfied"
368
+ />
369
+ <RadioButton
370
+ value="neutral"
371
+ checked={satisfaction === 'neutral'}
372
+ onPress={() => setSatisfaction('neutral')}
373
+ label="Neutral"
374
+ />
375
+ <RadioButton
376
+ value="dissatisfied"
377
+ checked={satisfaction === 'dissatisfied'}
378
+ onPress={() => setSatisfaction('dissatisfied')}
379
+ label="Dissatisfied"
380
+ intent="warning"
381
+ />
382
+ <RadioButton
383
+ value="very-dissatisfied"
384
+ checked={satisfaction === 'very-dissatisfied'}
385
+ onPress={() => setSatisfaction('very-dissatisfied')}
386
+ label="Very Dissatisfied"
387
+ intent="error"
388
+ />
389
+ </View>
390
+ </View>
391
+ );
392
+ }
393
+
394
+ // Example 10: Notification Frequency
395
+ export function NotificationFrequency() {
396
+ const [frequency, setFrequency] = React.useState('daily');
397
+
398
+ return (
399
+ <View spacing="lg">
400
+ <Text weight="bold" size="lg">
401
+ Notification Frequency
402
+ </Text>
403
+ <View spacing="md">
404
+ <RadioButton
405
+ value="realtime"
406
+ checked={frequency === 'realtime'}
407
+ onPress={() => setFrequency('realtime')}
408
+ label="Real-time"
409
+ />
410
+ <Text size="sm" style={{ marginLeft: 32 }}>
411
+ Get notified immediately when something happens
412
+ </Text>
413
+ <RadioButton
414
+ value="daily"
415
+ checked={frequency === 'daily'}
416
+ onPress={() => setFrequency('daily')}
417
+ label="Daily Digest"
418
+ />
419
+ <Text size="sm" style={{ marginLeft: 32 }}>
420
+ Receive a summary once per day
421
+ </Text>
422
+ <RadioButton
423
+ value="weekly"
424
+ checked={frequency === 'weekly'}
425
+ onPress={() => setFrequency('weekly')}
426
+ label="Weekly Digest"
427
+ />
428
+ <Text size="sm" style={{ marginLeft: 32 }}>
429
+ Receive a summary once per week
430
+ </Text>
431
+ <RadioButton
432
+ value="never"
433
+ checked={frequency === 'never'}
434
+ onPress={() => setFrequency('never')}
435
+ label="Never"
436
+ />
437
+ <Text size="sm" style={{ marginLeft: 32 }}>
438
+ Don't send me any notifications
439
+ </Text>
440
+ </View>
441
+ </View>
442
+ );
443
+ }