alouette 7.0.0-beta.2 → 7.0.0-beta.21

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 (180) hide show
  1. package/README.md +7 -1
  2. package/dist/createAlouetteTamagui-browser.es.js +105 -95
  3. package/dist/createAlouetteTamagui-browser.es.js.map +1 -1
  4. package/dist/createAlouetteTamagui-node18.mjs +105 -95
  5. package/dist/createAlouetteTamagui-node18.mjs.map +1 -1
  6. package/dist/createAlouetteTamagui-react-native.cjs.js +107 -94
  7. package/dist/createAlouetteTamagui-react-native.cjs.js.map +1 -1
  8. package/dist/definitions/components/actions/Button.d.ts +20 -0
  9. package/dist/definitions/components/actions/Button.d.ts.map +1 -0
  10. package/dist/definitions/components/actions/Button.stories.d.ts +10 -0
  11. package/dist/definitions/components/actions/Button.stories.d.ts.map +1 -0
  12. package/dist/definitions/components/actions/IconButton.d.ts +18 -0
  13. package/dist/definitions/components/actions/IconButton.d.ts.map +1 -0
  14. package/dist/definitions/components/actions/IconButton.stories.d.ts +10 -0
  15. package/dist/definitions/components/actions/IconButton.stories.d.ts.map +1 -0
  16. package/dist/definitions/components/containers/Box.d.ts +13 -0
  17. package/dist/definitions/components/containers/Box.d.ts.map +1 -0
  18. package/dist/definitions/components/containers/Box.stories.d.ts +18 -0
  19. package/dist/definitions/components/containers/Box.stories.d.ts.map +1 -0
  20. package/dist/definitions/components/containers/PressableBox.d.ts +12 -0
  21. package/dist/definitions/components/containers/PressableBox.d.ts.map +1 -0
  22. package/dist/definitions/components/containers/PressableBox.stories.d.ts +18 -0
  23. package/dist/definitions/components/containers/PressableBox.stories.d.ts.map +1 -0
  24. package/dist/definitions/components/containers/variants.d.ts +61 -0
  25. package/dist/definitions/components/containers/variants.d.ts.map +1 -0
  26. package/dist/definitions/components/feedback/FeedbackIcon.d.ts +8 -0
  27. package/dist/definitions/components/feedback/FeedbackIcon.d.ts.map +1 -0
  28. package/dist/definitions/components/feedback/Message.d.ts +25 -0
  29. package/dist/definitions/components/feedback/Message.d.ts.map +1 -0
  30. package/dist/definitions/components/feedback/Message.stories.d.ts +10 -0
  31. package/dist/definitions/components/feedback/Message.stories.d.ts.map +1 -0
  32. package/dist/definitions/components/forms/InputText.d.ts +23 -0
  33. package/dist/definitions/components/forms/InputText.d.ts.map +1 -0
  34. package/dist/definitions/components/forms/InputText.stories.d.ts +16 -0
  35. package/dist/definitions/components/forms/InputText.stories.d.ts.map +1 -0
  36. package/dist/definitions/components/layout/Separator.d.ts +6 -0
  37. package/dist/definitions/components/layout/Separator.d.ts.map +1 -0
  38. package/dist/definitions/components/layout/Separator.stories.d.ts +10 -0
  39. package/dist/definitions/components/layout/Separator.stories.d.ts.map +1 -0
  40. package/dist/definitions/components/layout/list.d.ts +7 -0
  41. package/dist/definitions/components/layout/list.d.ts.map +1 -0
  42. package/dist/definitions/components/layout/list.stories.d.ts +7 -0
  43. package/dist/definitions/components/layout/list.stories.d.ts.map +1 -0
  44. package/dist/definitions/components/primitives/Icon.d.ts +14 -0
  45. package/dist/definitions/components/primitives/Icon.d.ts.map +1 -0
  46. package/dist/definitions/components/primitives/Icon.stories.d.ts +9 -0
  47. package/dist/definitions/components/primitives/Icon.stories.d.ts.map +1 -0
  48. package/dist/definitions/components/primitives/ScrollView.d.ts +14 -0
  49. package/dist/definitions/components/primitives/ScrollView.d.ts.map +1 -0
  50. package/dist/definitions/components/primitives/View.d.ts +5 -0
  51. package/dist/definitions/components/primitives/View.d.ts.map +1 -0
  52. package/dist/definitions/components/primitives/View.stories.d.ts +10 -0
  53. package/dist/definitions/components/primitives/View.stories.d.ts.map +1 -0
  54. package/dist/definitions/components/primitives/createVariants.d.ts +54 -0
  55. package/dist/definitions/components/primitives/createVariants.d.ts.map +1 -0
  56. package/dist/definitions/components/primitives/stacks.d.ts +17 -0
  57. package/dist/definitions/components/primitives/stacks.d.ts.map +1 -0
  58. package/dist/definitions/components/primitives/stacks.stories.d.ts +10 -0
  59. package/dist/definitions/components/primitives/stacks.stories.d.ts.map +1 -0
  60. package/dist/definitions/components/story-components/Story.d.ts +21 -0
  61. package/dist/definitions/components/story-components/Story.d.ts.map +1 -0
  62. package/dist/definitions/components/story-components/StoryContainer.d.ts +7 -0
  63. package/dist/definitions/components/story-components/StoryContainer.d.ts.map +1 -0
  64. package/dist/definitions/components/story-components/StoryDecorator.d.ts +3 -0
  65. package/dist/definitions/components/story-components/StoryDecorator.d.ts.map +1 -0
  66. package/dist/definitions/components/story-components/StoryGrid.d.ts +19 -0
  67. package/dist/definitions/components/story-components/StoryGrid.d.ts.map +1 -0
  68. package/dist/definitions/components/story-components/StoryTitle.d.ts +10 -0
  69. package/dist/definitions/components/story-components/StoryTitle.d.ts.map +1 -0
  70. package/dist/definitions/components/story-components/WithTamaguiConfig.d.ts +7 -0
  71. package/dist/definitions/components/story-components/WithTamaguiConfig.d.ts.map +1 -0
  72. package/dist/definitions/components/typography/Typography.d.ts +38 -0
  73. package/dist/definitions/components/typography/Typography.d.ts.map +1 -0
  74. package/dist/definitions/components/typography/Typography.stories.d.ts +15 -0
  75. package/dist/definitions/components/typography/Typography.stories.d.ts.map +1 -0
  76. package/dist/definitions/components/windowSize/SwitchBreakpoints.d.ts +20 -0
  77. package/dist/definitions/components/windowSize/SwitchBreakpoints.d.ts.map +1 -0
  78. package/dist/definitions/components/windowSize/SwitchBreakpoints.stories.d.ts +10 -0
  79. package/dist/definitions/components/windowSize/SwitchBreakpoints.stories.d.ts.map +1 -0
  80. package/dist/definitions/components/windowSize/useCurrentBreakpointName.d.ts +5 -0
  81. package/dist/definitions/components/windowSize/useCurrentBreakpointName.d.ts.map +1 -0
  82. package/dist/definitions/config/Breakpoints.d.ts +32 -0
  83. package/dist/definitions/config/Breakpoints.d.ts.map +1 -0
  84. package/dist/definitions/config/animations.d.ts +15 -0
  85. package/dist/definitions/config/animations.d.ts.map +1 -0
  86. package/dist/definitions/config/animations.web.d.ts +5 -0
  87. package/dist/definitions/config/animations.web.d.ts.map +1 -0
  88. package/dist/definitions/config/colorScales.d.ts +13 -0
  89. package/dist/definitions/config/colorScales.d.ts.map +1 -0
  90. package/dist/definitions/config/createAlouetteFonts.d.ts +90 -0
  91. package/dist/definitions/config/createAlouetteFonts.d.ts.map +1 -0
  92. package/dist/definitions/config/createAlouetteTokens.d.ts +557 -0
  93. package/dist/definitions/config/createAlouetteTokens.d.ts.map +1 -0
  94. package/dist/definitions/config/media.d.ts +15 -0
  95. package/dist/definitions/config/media.d.ts.map +1 -0
  96. package/dist/definitions/config/themes.d.ts +247 -0
  97. package/dist/definitions/config/themes.d.ts.map +1 -0
  98. package/dist/definitions/config/themes.stories.d.ts +8 -0
  99. package/dist/definitions/config/themes.stories.d.ts.map +1 -0
  100. package/dist/definitions/config/tokens.stories.d.ts +8 -0
  101. package/dist/definitions/config/tokens.stories.d.ts.map +1 -0
  102. package/dist/definitions/config/utils/groupTokens.d.ts +7 -0
  103. package/dist/definitions/config/utils/groupTokens.d.ts.map +1 -0
  104. package/dist/definitions/core/AlouetteDecorator.d.ts +3 -0
  105. package/dist/definitions/core/AlouetteDecorator.d.ts.map +1 -0
  106. package/dist/definitions/core/AlouetteProvider.d.ts +8 -0
  107. package/dist/definitions/core/AlouetteProvider.d.ts.map +1 -0
  108. package/dist/definitions/createAlouetteTamagui.d.ts +136 -0
  109. package/dist/definitions/createAlouetteTamagui.d.ts.map +1 -0
  110. package/dist/definitions/index.d.ts +42 -0
  111. package/dist/definitions/index.d.ts.map +1 -0
  112. package/dist/index-browser.es.js +389 -60
  113. package/dist/index-browser.es.js.map +1 -1
  114. package/dist/index-node18.mjs +389 -60
  115. package/dist/index-node18.mjs.map +1 -1
  116. package/dist/index-react-native.cjs.js +403 -56
  117. package/dist/index-react-native.cjs.js.map +1 -1
  118. package/package.json +31 -24
  119. package/src/components/actions/Button.stories.tsx +4 -5
  120. package/src/components/actions/Button.tsx +3 -4
  121. package/src/components/actions/IconButton.stories.tsx +2 -3
  122. package/src/components/actions/IconButton.tsx +4 -4
  123. package/src/components/containers/{Frame.stories.tsx → Box.stories.tsx} +21 -21
  124. package/src/components/containers/{Frame.tsx → Box.tsx} +3 -3
  125. package/src/components/containers/{Pressable.stories.tsx → PressableBox.stories.tsx} +8 -8
  126. package/src/components/containers/PressableBox.tsx +9 -0
  127. package/src/components/containers/variants.ts +15 -12
  128. package/src/components/feedback/FeedbackIcon.tsx +2 -2
  129. package/src/components/feedback/Message.stories.tsx +2 -2
  130. package/src/components/feedback/Message.tsx +4 -4
  131. package/src/components/forms/InputText.stories.tsx +2 -2
  132. package/src/components/forms/InputText.tsx +5 -0
  133. package/src/components/layout/Separator.stories.tsx +39 -0
  134. package/src/components/layout/Separator.tsx +31 -0
  135. package/src/components/layout/list.stories.tsx +24 -0
  136. package/src/components/layout/list.tsx +30 -0
  137. package/src/components/primitives/Icon.stories.tsx +1 -1
  138. package/src/components/primitives/Icon.tsx +6 -12
  139. package/src/components/primitives/ScrollView.ts +2 -1
  140. package/src/components/primitives/createVariants.ts +7 -5
  141. package/src/components/primitives/stacks.stories.tsx +14 -14
  142. package/src/components/primitives/stacks.ts +2 -6
  143. package/src/components/story-components/Story.tsx +1 -1
  144. package/src/components/story-components/StoryGrid.tsx +0 -1
  145. package/src/components/story-components/StoryTitle.tsx +3 -0
  146. package/src/components/typography/Typography.tsx +2 -0
  147. package/src/components/windowSize/SwitchBreakpoints.stories.tsx +1 -1
  148. package/src/config/animations.ts +4 -0
  149. package/src/config/animations.web.ts +1 -0
  150. package/src/config/colorScales.ts +4 -4
  151. package/src/config/createAlouetteFonts.ts +6 -6
  152. package/src/config/createAlouetteTokens.ts +23 -18
  153. package/src/config/themes.stories.tsx +5 -9
  154. package/src/config/themes.ts +139 -68
  155. package/src/config/tokens.stories.tsx +7 -7
  156. package/src/core/AlouetteDecorator.tsx +1 -0
  157. package/src/createAlouetteTamagui.ts +32 -19
  158. package/src/index.ts +50 -3
  159. package/.editorconfig +0 -13
  160. package/.eslintrc.json +0 -5
  161. package/.yo-rc.json +0 -11
  162. package/dist/phosphor-icons-browser.es.js +0 -2497
  163. package/dist/phosphor-icons-browser.es.js.map +0 -1
  164. package/dist/phosphor-icons-node18.mjs +0 -2497
  165. package/dist/phosphor-icons-node18.mjs.map +0 -1
  166. package/dist/phosphor-icons-react-native.cjs.js +0 -4998
  167. package/dist/phosphor-icons-react-native.cjs.js.map +0 -1
  168. package/phosphor-icons.js +0 -1
  169. package/rollup.config.mjs +0 -8
  170. package/scripts/generate-phosphor-icons-legacy-withcopy.mjs +0 -64
  171. package/scripts/generate-phosphor-icons.mjs +0 -51
  172. package/src/.eslintrc.json +0 -32
  173. package/src/components/containers/Pressable.tsx +0 -9
  174. package/src/components/windowSize/__snapshots__/SwitchBreakpoints.stories.tsx.snap +0 -1032
  175. package/src/components/windowSize/__snapshots_web__/SwitchBreakpoints.stories.tsx.snap +0 -402
  176. package/src/phosphor-icons.cjs +0 -1254
  177. package/src/phosphor-icons.d.ts +0 -2501
  178. package/src/phosphor-icons.ts +0 -2499
  179. package/src/typings/bundler.d.ts +0 -10
  180. package/tsconfig.json +0 -20
@@ -2,8 +2,9 @@
2
2
 
3
3
  const jsxRuntime = require('react/jsx-runtime');
4
4
  const core = require('@tamagui/core');
5
- const reactNative = require('react-native');
6
5
  const react = require('react');
6
+ const phosphorIcons = require('alouette-icons/phosphor-icons');
7
+ const reactNative = require('react-native');
7
8
 
8
9
  const fullscreenStyle = {
9
10
  position: "absolute",
@@ -29,11 +30,11 @@ const getBorderAdditionalInteraction = ({
29
30
  return {
30
31
  borderColor: `$${prefix}.borderColor:hover`
31
32
  };
32
- case `press`:
33
+ case "press":
33
34
  return {
34
35
  borderColor: `$${prefix}.borderColor:press`
35
36
  };
36
- case `focus`:
37
+ case "focus":
37
38
  return {
38
39
  borderColor: `$${prefix}.borderColor:focus`
39
40
  };
@@ -58,7 +59,10 @@ const getBackgroundAdditionalInteraction = ({
58
59
  interactive,
59
60
  variant
60
61
  }) => {
61
- const prefix = interactive === "text" ? "interactive.forms" : `interactive.${variant || "contained"}`;
62
+ const prefix = interactive === "text" ? "interactive.forms" : (
63
+ // eslint-disable-next-line @typescript-eslint/restrict-template-expressions
64
+ `interactive.${variant || "contained"}`
65
+ );
62
66
  if (disabled) {
63
67
  return {
64
68
  backgroundColor: `$${prefix}.backgroundColor:disabled`
@@ -70,11 +74,11 @@ const getBackgroundAdditionalInteraction = ({
70
74
  return {
71
75
  backgroundColor: `$${prefix}.backgroundColor:hover`
72
76
  };
73
- case `press`:
77
+ case "press":
74
78
  return {
75
79
  backgroundColor: `$${prefix}.backgroundColor:press`
76
80
  };
77
- case `focus`:
81
+ case "focus":
78
82
  return {
79
83
  backgroundColor: `$${prefix}.backgroundColor:focus`
80
84
  };
@@ -109,7 +113,10 @@ const withBackground = (val, { props }) => {
109
113
  throw new Error("A role prop is required while using interactive");
110
114
  }
111
115
  return {
112
- backgroundColor: props.interactive ? `$interactive.${variant}.backgroundColor` : "$mainColor",
116
+ backgroundColor: props.interactive ? (
117
+ // eslint-disable-next-line @typescript-eslint/restrict-template-expressions
118
+ `$interactive.${variant}.backgroundColor`
119
+ ) : "$mainColor",
113
120
  ...props.interactive ? getBackgroundAdditionalInteraction(props) : void 0
114
121
  };
115
122
  };
@@ -138,9 +145,15 @@ const circular = {
138
145
  };
139
146
  }
140
147
  };
141
- const interactive = (isInteractiveOrInteractiveCursorType, { props }) => isInteractiveOrInteractiveCursorType ? {
142
- cursor: props.disabled ? "not-allowed" : isInteractiveOrInteractiveCursorType === true ? "pointer" : isInteractiveOrInteractiveCursorType
143
- } : null;
148
+ const interactive = (isInteractiveOrInteractiveCursorType, { props }) => {
149
+ if (!isInteractiveOrInteractiveCursorType) return null;
150
+ if (props.disabled) {
151
+ return { cursor: "not-allowed" };
152
+ }
153
+ return {
154
+ cursor: isInteractiveOrInteractiveCursorType === true ? "pointer" : isInteractiveOrInteractiveCursorType
155
+ };
156
+ };
144
157
  const centered = {
145
158
  true: {
146
159
  alignItems: "center",
@@ -159,12 +172,16 @@ const variants$1 = {
159
172
  withBorder: withBorder
160
173
  };
161
174
 
162
- const Frame = core.styled(core.View, {
163
- name: "Frame",
175
+ const Box = core.styled(core.View, {
176
+ name: "Box",
164
177
  variants: variants$1,
165
178
  animation: "fast"
166
179
  });
167
180
 
181
+ const PressableBox = core.styled(Box, {
182
+ interactive: true
183
+ });
184
+
168
185
  function Icon({
169
186
  icon,
170
187
  size = 20,
@@ -178,24 +195,10 @@ function Icon({
178
195
  // if needed for native
179
196
  // resolveValues: Platform.OS === 'web' ? undefined: 'value',
180
197
  });
181
- return /* @__PURE__ */ jsxRuntime.jsx(
182
- Frame,
183
- {
184
- ...props,
185
- centered: true,
186
- alignSelf: align,
187
- size,
188
- style,
189
- children: icon
190
- }
191
- );
198
+ return /* @__PURE__ */ jsxRuntime.jsx(Box, { ...props, centered: true, alignSelf: align, size, style, children: icon });
192
199
  }
193
200
 
194
- const Pressable = core.styled(Frame, {
195
- interactive: true
196
- });
197
-
198
- const IconButtonFrame = core.styled(Pressable, {
201
+ const IconButtonFrame = core.styled(PressableBox, {
199
202
  name: "IconButtonFrame",
200
203
  role: "button",
201
204
  centered: true,
@@ -222,24 +225,6 @@ function IconButton({
222
225
  ) });
223
226
  }
224
227
 
225
- const ScrollView = core.styled(
226
- reactNative.ScrollView,
227
- {
228
- name: "ScrollView",
229
- scrollEnabled: true,
230
- variants: {
231
- fullscreen: {
232
- true: fullscreenStyle
233
- }
234
- }
235
- },
236
- {
237
- accept: {
238
- contentContainerStyle: "style"
239
- }
240
- }
241
- );
242
-
243
228
  const variants = {
244
229
  fullscreen: {
245
230
  true: fullscreenStyle
@@ -250,12 +235,8 @@ const Stack = core.styled(core.View, {
250
235
  variants: {
251
236
  ...variants,
252
237
  type: {
253
- h: {
254
- flexDirection: "row"
255
- },
256
- v: {
257
- flexDirection: "column"
258
- }
238
+ h: { flexDirection: "row" },
239
+ v: { flexDirection: "column" }
259
240
  }
260
241
  }
261
242
  });
@@ -310,7 +291,7 @@ const TypographyParagraph = core.styled(Typography, {
310
291
  family: "body"
311
292
  });
312
293
  const TypographySizeContext = react.createContext(void 0);
313
- Typography.styleable(
294
+ const TypographyWithContext = Typography.styleable(
314
295
  ({ size, ...props }, ref) => {
315
296
  const ancestorSize = react.useContext(TypographySizeContext);
316
297
  const sizeOrAncestorSizeOrDefaultSize = size || ancestorSize;
@@ -320,7 +301,7 @@ Typography.styleable(
320
301
  return /* @__PURE__ */ jsxRuntime.jsx(Typography, { ref, size, ...props });
321
302
  }
322
303
  );
323
- TypographyParagraph.styleable(
304
+ const TypographyParagraphWithContext = TypographyParagraph.styleable(
324
305
  ({ size, ...props }, ref) => {
325
306
  const ancestorSize = react.useContext(TypographySizeContext);
326
307
  const sizeOrAncestorSizeOrDefaultSize = size || ancestorSize;
@@ -328,6 +309,307 @@ TypographyParagraph.styleable(
328
309
  }
329
310
  );
330
311
 
312
+ const ButtonFrame = core.styled(PressableBox, {
313
+ name: "ButtonFrame",
314
+ role: "button",
315
+ centered: true,
316
+ minHeight: 42,
317
+ borderRadius: "$sm",
318
+ paddingHorizontal: "$md",
319
+ variants: {
320
+ variant: {
321
+ contained: {
322
+ withBackground: true
323
+ },
324
+ outlined: {
325
+ withBackground: true,
326
+ withBorder: true
327
+ }
328
+ }
329
+ },
330
+ defaultVariants: {
331
+ variant: "contained"
332
+ }
333
+ });
334
+ function Button({
335
+ icon,
336
+ text,
337
+ disabled,
338
+ variant,
339
+ ...pressableProps
340
+ }) {
341
+ return /* @__PURE__ */ jsxRuntime.jsx(ButtonFrame, { disabled, variant, ...pressableProps, children: /* @__PURE__ */ jsxRuntime.jsxs(HStack, { gap: "$xs", alignItems: "center", children: [
342
+ icon && /* @__PURE__ */ jsxRuntime.jsx(
343
+ Icon,
344
+ {
345
+ color: disabled ? "$contrastDisabled" : void 0,
346
+ contrast: variant === "contained" && !disabled,
347
+ icon
348
+ }
349
+ ),
350
+ /* @__PURE__ */ jsxRuntime.jsx(
351
+ Typography,
352
+ {
353
+ size: "md",
354
+ weight: "bold",
355
+ paddingVertical: "$xs",
356
+ color: disabled ? "$contrastDisabled" : void 0,
357
+ contrast: variant === "contained" && !disabled,
358
+ children: text
359
+ }
360
+ )
361
+ ] }) });
362
+ }
363
+
364
+ function FeedbackIcon({ type }) {
365
+ switch (type) {
366
+ case "warning":
367
+ return /* @__PURE__ */ jsxRuntime.jsx(phosphorIcons.WarningCircleRegularIcon, {});
368
+ case "success":
369
+ return /* @__PURE__ */ jsxRuntime.jsx(phosphorIcons.CheckRegularIcon, {});
370
+ case "danger":
371
+ return /* @__PURE__ */ jsxRuntime.jsx(phosphorIcons.WarningRegularIcon, {});
372
+ default:
373
+ return /* @__PURE__ */ jsxRuntime.jsx(phosphorIcons.InfoRegularIcon, {});
374
+ }
375
+ }
376
+
377
+ const MessageFrame = core.styled(Box, {
378
+ name: "MessageFrame",
379
+ alignItems: "center",
380
+ withBackground: true,
381
+ borderRadius: "$md",
382
+ paddingHorizontal: "$4",
383
+ flexDirection: "row",
384
+ gap: "$4"
385
+ });
386
+ const MessageText = core.styled(Typography, {
387
+ name: "MessageText",
388
+ contrast: true,
389
+ size: "md",
390
+ flexGrow: 1,
391
+ paddingVertical: "$4",
392
+ variants: {
393
+ centered: {
394
+ true: {
395
+ textAlign: "center",
396
+ paddingHorizontal: "$4"
397
+ }
398
+ }
399
+ }
400
+ });
401
+ const MessageIconContainer = core.styled(core.View, {
402
+ name: "MessageIconContainer",
403
+ alignItems: "center"
404
+ });
405
+ const MessageDismissButtonContainer = core.styled(core.View, {
406
+ name: "MessageDismissButtonContainer",
407
+ marginRight: "$2"
408
+ });
409
+ function Message({
410
+ theme,
411
+ textCentered,
412
+ children,
413
+ onDismiss
414
+ }) {
415
+ return /* @__PURE__ */ jsxRuntime.jsxs(MessageFrame, { theme, children: [
416
+ textCentered ? null : /* @__PURE__ */ jsxRuntime.jsx(MessageIconContainer, { children: /* @__PURE__ */ jsxRuntime.jsx(Icon, { contrast: true, icon: /* @__PURE__ */ jsxRuntime.jsx(FeedbackIcon, { type: theme }) }) }),
417
+ /* @__PURE__ */ jsxRuntime.jsx(MessageText, { centered: textCentered, children }),
418
+ onDismiss ? /* @__PURE__ */ jsxRuntime.jsx(MessageDismissButtonContainer, { children: /* @__PURE__ */ jsxRuntime.jsx(IconButton, { icon: /* @__PURE__ */ jsxRuntime.jsx(phosphorIcons.XRegularIcon, {}), size: 40 }) }) : null
419
+ ] });
420
+ }
421
+
422
+ const StyledInputText = core.styled(reactNative.TextInput, {
423
+ variants: variants$1,
424
+ padding: "$xs",
425
+ borderRadius: "$sm",
426
+ // @ts-expect-error missing prop but seems to work
427
+ color: "$forms.textColor",
428
+ withBorder: true,
429
+ withBackground: true,
430
+ borderWidth: 1,
431
+ borderBottomWidth: 3,
432
+ // reset browser style
433
+ outlineStyle: "none"
434
+ });
435
+ const InputText = core.styled(StyledInputText, {
436
+ name: "InputText",
437
+ interactive: "text",
438
+ theme: "primary"
439
+ // animation: "formElement", // remove all style ?
440
+ });
441
+ const TextArea = core.styled(InputText, {
442
+ multiline: true
443
+ });
444
+
445
+ const ScrollView = core.styled(
446
+ reactNative.ScrollView,
447
+ {
448
+ name: "ScrollView",
449
+ scrollEnabled: true,
450
+ variants: {
451
+ fullscreen: {
452
+ true: fullscreenStyle
453
+ }
454
+ }
455
+ },
456
+ {
457
+ accept: {
458
+ contentContainerStyle: "style"
459
+ }
460
+ }
461
+ );
462
+
463
+ const StoryTitle = core.styled(Typography, {
464
+ family: "heading",
465
+ weight: "black",
466
+ variants: {
467
+ level: {
468
+ 1: { size: "xl", marginBottom: "$8" },
469
+ 2: { size: "lg", marginBottom: "$8" },
470
+ 3: { size: "md", marginBottom: "$3" },
471
+ 4: { size: "sm", marginBottom: "$3" }
472
+ }
473
+ },
474
+ defaultVariants: {
475
+ level: 1
476
+ }
477
+ });
478
+
479
+ const InternalStorySection = core.styled(VStack, {
480
+ marginBottom: "$8",
481
+ paddingHorizontal: "$4",
482
+ marginHorizontal: "$-4",
483
+ variants: {
484
+ withBackground: {
485
+ true: {
486
+ backgroundColor: "$backgroundColor"
487
+ }
488
+ }
489
+ }
490
+ });
491
+ function StorySection({
492
+ title,
493
+ children,
494
+ level = 1,
495
+ withBackground,
496
+ ...props
497
+ }) {
498
+ return /* @__PURE__ */ jsxRuntime.jsxs(InternalStorySection, { withBackground, ...props, children: [
499
+ /* @__PURE__ */ jsxRuntime.jsx(StoryTitle, { level: level + 1, children: title }),
500
+ children
501
+ ] });
502
+ }
503
+ function SubSection({
504
+ title,
505
+ children,
506
+ withBackground,
507
+ ...props
508
+ }) {
509
+ return /* @__PURE__ */ jsxRuntime.jsxs(
510
+ InternalStorySection,
511
+ {
512
+ marginBottom: "$4",
513
+ withBackground,
514
+ ...props,
515
+ children: [
516
+ /* @__PURE__ */ jsxRuntime.jsx(StoryTitle, { level: 3, children: title }),
517
+ children
518
+ ]
519
+ }
520
+ );
521
+ }
522
+ function Story({ preview, children }) {
523
+ return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
524
+ preview && /* @__PURE__ */ jsxRuntime.jsx(StorySection, { title: "Preview", paddingBottom: "$12", children: preview }),
525
+ children
526
+ ] });
527
+ }
528
+ Story.Section = StorySection;
529
+ Story.SubSection = SubSection;
530
+
531
+ function StoryContainer({
532
+ title,
533
+ children
534
+ }) {
535
+ return /* @__PURE__ */ jsxRuntime.jsxs(ScrollView, { theme: "light", background: "#fff", padding: "$4", children: [
536
+ /* @__PURE__ */ jsxRuntime.jsx(StoryTitle, { level: 1, children: title }),
537
+ children
538
+ ] });
539
+ }
540
+
541
+ const StoryDecorator = (storyFn, { name, container }) => {
542
+ if (container === false) return storyFn();
543
+ return /* @__PURE__ */ jsxRuntime.jsx(StoryContainer, { title: name, children: storyFn() });
544
+ };
545
+
546
+ function StoryGridRow({
547
+ children,
548
+ breakpoint = "small",
549
+ flexWrap
550
+ }) {
551
+ return /* @__PURE__ */ jsxRuntime.jsx(
552
+ core.View,
553
+ {
554
+ flexDirection: "column",
555
+ ...{
556
+ [`$${breakpoint}`]: {
557
+ flexDirection: "row",
558
+ marginVertical: "$-1",
559
+ marginBottom: "$4",
560
+ flexWrap: flexWrap ? "wrap" : void 0,
561
+ gap: flexWrap ? "$xs" : void 0
562
+ }
563
+ },
564
+ children: react.Children.map(children, (child) => /* @__PURE__ */ jsxRuntime.jsx(
565
+ core.View,
566
+ {
567
+ paddingTop: "$2",
568
+ paddingBottom: "$4",
569
+ ...{
570
+ [`$${breakpoint}`]: {
571
+ flexGrow: 1,
572
+ flexBasis: flexWrap ? void 0 : 0,
573
+ paddingTop: 0,
574
+ paddingBottom: 0,
575
+ marginVertical: "$2"
576
+ }
577
+ },
578
+ children: child
579
+ }
580
+ ))
581
+ }
582
+ );
583
+ }
584
+ function StoryGridCol({
585
+ title,
586
+ children,
587
+ platform = "all"
588
+ }) {
589
+ const isNative = reactNative.Platform.OS === "ios" || reactNative.Platform.OS === "android";
590
+ if (reactNative.Platform.OS === "web" && platform === "native") {
591
+ return null;
592
+ }
593
+ if (isNative && platform === "web") {
594
+ return null;
595
+ }
596
+ return title ? /* @__PURE__ */ jsxRuntime.jsxs(VStack, { children: [
597
+ /* @__PURE__ */ jsxRuntime.jsx(StoryTitle, { level: 4, numberOfLines: 1, children: title }),
598
+ children
599
+ ] }) : children;
600
+ }
601
+ const StoryGrid = {
602
+ Row: StoryGridRow,
603
+ Col: StoryGridCol
604
+ };
605
+
606
+ function WithTamaguiConfig({
607
+ render
608
+ }) {
609
+ const config = core.useConfiguration();
610
+ return render(config);
611
+ }
612
+
331
613
  var BreakpointNameEnum = /* @__PURE__ */ ((BreakpointNameEnum2) => {
332
614
  BreakpointNameEnum2["BASE"] = "base";
333
615
  BreakpointNameEnum2["SMALL"] = "small";
@@ -399,21 +681,86 @@ function AlouetteProvider({
399
681
  return /* @__PURE__ */ jsxRuntime.jsx(core.TamaguiProvider, { config: tamaguiConfig, defaultTheme: "light", children });
400
682
  }
401
683
 
402
- const AlouetteDecorator = (storyFn, context) => /* @__PURE__ */ jsxRuntime.jsx(AlouetteProvider, { tamaguiConfig: context.parameters.tamaguiConfig, children: storyFn(context) });
684
+ const AlouetteDecorator = (storyFn, context) => (
685
+ // eslint-disable-next-line react/destructuring-assignment
686
+ /* @__PURE__ */ jsxRuntime.jsx(AlouetteProvider, { tamaguiConfig: context.parameters.tamaguiConfig, children: storyFn(context) })
687
+ );
688
+
689
+ const Separator = core.styled(core.Stack, {
690
+ name: "Separator",
691
+ flexGrow: 1,
692
+ flexShrink: 0,
693
+ height: 0,
694
+ maxHeight: 0,
695
+ borderColor: "$borderColor",
696
+ borderWidth: 0,
697
+ borderBottomWidth: 1,
698
+ y: -0.5,
699
+ variants: {
700
+ vertical: {
701
+ true: {
702
+ height: "auto",
703
+ maxHeight: "auto",
704
+ width: 0,
705
+ maxWidth: 0,
706
+ borderBottomWidth: 0,
707
+ borderRightWidth: 1,
708
+ y: 0,
709
+ x: -0.5
710
+ }
711
+ }
712
+ }
713
+ });
714
+
715
+ function PressableListItem({
716
+ children,
717
+ onPress
718
+ }) {
719
+ return /* @__PURE__ */ jsxRuntime.jsx(reactNative.Pressable, { onPress, children: /* @__PURE__ */ jsxRuntime.jsxs(
720
+ HStack,
721
+ {
722
+ justifyContent: "space-between",
723
+ paddingHorizontal: "$4",
724
+ paddingVertical: "$3",
725
+ children: [
726
+ /* @__PURE__ */ jsxRuntime.jsx(core.View, { children }),
727
+ /* @__PURE__ */ jsxRuntime.jsx(Stack, { justifyContent: "center", children: /* @__PURE__ */ jsxRuntime.jsx(Icon, { icon: /* @__PURE__ */ jsxRuntime.jsx(phosphorIcons.CaretRightRegularIcon, {}), size: 20 }) })
728
+ ]
729
+ }
730
+ ) });
731
+ }
403
732
 
404
733
  exports.Theme = core.Theme;
405
734
  exports.View = core.View;
735
+ exports.styled = core.styled;
736
+ exports.withStaticProperties = core.withStaticProperties;
406
737
  exports.AlouetteDecorator = AlouetteDecorator;
407
738
  exports.AlouetteProvider = AlouetteProvider;
408
- exports.Frame = Frame;
739
+ exports.Box = Box;
740
+ exports.Button = Button;
409
741
  exports.HStack = HStack;
410
742
  exports.Icon = Icon;
411
743
  exports.IconButton = IconButton;
744
+ exports.InputText = InputText;
745
+ exports.Message = Message;
746
+ exports.PressableBox = PressableBox;
747
+ exports.PressableListItem = PressableListItem;
412
748
  exports.ScrollView = ScrollView;
749
+ exports.Separator = Separator;
413
750
  exports.Stack = Stack;
751
+ exports.Story = Story;
752
+ exports.StoryContainer = StoryContainer;
753
+ exports.StoryDecorator = StoryDecorator;
754
+ exports.StoryGrid = StoryGrid;
755
+ exports.StoryTitle = StoryTitle;
414
756
  exports.SwitchBreakpointsUsingDisplayNone = SwitchBreakpointsUsingDisplayNone;
415
757
  exports.SwitchBreakpointsUsingNull = SwitchBreakpointsUsingNull;
758
+ exports.TextArea = TextArea;
416
759
  exports.Typography = Typography;
760
+ exports.TypographyParagraph = TypographyParagraph;
761
+ exports.TypographyParagraphWithContext = TypographyParagraphWithContext;
762
+ exports.TypographyWithContext = TypographyWithContext;
417
763
  exports.VStack = VStack;
764
+ exports.WithTamaguiConfig = WithTamaguiConfig;
418
765
  exports.useCurrentBreakpointName = useCurrentBreakpointName;
419
766
  //# sourceMappingURL=index-react-native.cjs.js.map