app-studio 0.7.18 → 0.8.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.
Files changed (103) hide show
  1. package/README.md +11 -1
  2. package/dist/native/index.cjs +3360 -0
  3. package/dist/native/index.cjs.map +1 -0
  4. package/dist/native/index.d.mts +251 -0
  5. package/dist/native/index.d.ts +251 -0
  6. package/dist/native/index.js +3268 -0
  7. package/dist/native/index.js.map +1 -0
  8. package/dist/viewAnimation-B4BIoOwQ.d.mts +2246 -0
  9. package/dist/viewAnimation-B4BIoOwQ.d.ts +2246 -0
  10. package/dist/web/app-studio.umd.production.min.global.js +28 -0
  11. package/dist/web/app-studio.umd.production.min.global.js.map +1 -0
  12. package/dist/web/index.cjs +6109 -0
  13. package/dist/web/index.cjs.map +1 -0
  14. package/dist/web/index.d.mts +624 -0
  15. package/dist/web/index.d.ts +624 -0
  16. package/dist/web/index.js +6008 -0
  17. package/dist/web/index.js.map +1 -0
  18. package/docs/README.md +10 -0
  19. package/package.json +76 -14
  20. package/dist/app-studio.cjs.development.js +0 -6754
  21. package/dist/app-studio.cjs.development.js.map +0 -1
  22. package/dist/app-studio.cjs.production.min.js +0 -2
  23. package/dist/app-studio.cjs.production.min.js.map +0 -1
  24. package/dist/app-studio.esm.js +0 -6650
  25. package/dist/app-studio.esm.js.map +0 -1
  26. package/dist/app-studio.umd.development.js +0 -6757
  27. package/dist/app-studio.umd.development.js.map +0 -1
  28. package/dist/app-studio.umd.production.min.js +0 -2
  29. package/dist/app-studio.umd.production.min.js.map +0 -1
  30. package/dist/components/Form.d.ts +0 -17
  31. package/dist/components/Image.d.ts +0 -7
  32. package/dist/components/Skeleton.d.ts +0 -3
  33. package/dist/components/Text/Text.props.d.ts +0 -27
  34. package/dist/components/Text/Text.type.d.ts +0 -3
  35. package/dist/components/Text/Text.utils.d.ts +0 -2
  36. package/dist/components/Text/Text.view.d.ts +0 -20
  37. package/dist/components/Text.d.ts +0 -5
  38. package/dist/components/View.d.ts +0 -16
  39. package/dist/components/Wrapper.d.ts +0 -4
  40. package/dist/element/Animation.d.ts +0 -1164
  41. package/dist/element/Element.d.ts +0 -4
  42. package/dist/element/Element.types.d.ts +0 -123
  43. package/dist/element/css.d.ts +0 -50
  44. package/dist/element/utils.d.ts +0 -4
  45. package/dist/hooks/useActive.d.ts +0 -2
  46. package/dist/hooks/useClickOutside.d.ts +0 -6
  47. package/dist/hooks/useElementPosition.d.ts +0 -39
  48. package/dist/hooks/useFocus.d.ts +0 -2
  49. package/dist/hooks/useHover.d.ts +0 -2
  50. package/dist/hooks/useIframeStyles.d.ts +0 -41
  51. package/dist/hooks/useInView.d.ts +0 -11
  52. package/dist/hooks/useKeyPress.d.ts +0 -1
  53. package/dist/hooks/useMount.d.ts +0 -1
  54. package/dist/hooks/useOnScreen.d.ts +0 -6
  55. package/dist/hooks/useResponsive.d.ts +0 -59
  56. package/dist/hooks/useScroll.d.ts +0 -49
  57. package/dist/hooks/useWindowSize.d.ts +0 -4
  58. package/dist/index.d.ts +0 -33
  59. package/dist/index.js +0 -8
  60. package/dist/providers/Analytics.d.ts +0 -9
  61. package/dist/providers/Responsive.d.ts +0 -58
  62. package/dist/providers/StyleRegistry.d.ts +0 -32
  63. package/dist/providers/Theme.d.ts +0 -46
  64. package/dist/providers/WindowSize.d.ts +0 -11
  65. package/dist/stories/AnimateOn.stories.d.ts +0 -30
  66. package/dist/stories/Animation.stories.d.ts +0 -35
  67. package/dist/stories/BorderColor.stories.d.ts +0 -4
  68. package/dist/stories/Color.stories.d.ts +0 -4
  69. package/dist/stories/ColorAlpha.stories.d.ts +0 -5
  70. package/dist/stories/Component.stories.d.ts +0 -7
  71. package/dist/stories/CrossBrowserCompatibility.stories.d.ts +0 -6
  72. package/dist/stories/CssCascadeOrder.stories.d.ts +0 -10
  73. package/dist/stories/EmptyBeforeExample.stories.d.ts +0 -7
  74. package/dist/stories/EventHandlers.stories.d.ts +0 -6
  75. package/dist/stories/GradientColors.stories.d.ts +0 -6
  76. package/dist/stories/GroupPeer.stories.d.ts +0 -7
  77. package/dist/stories/Hooks.stories.d.ts +0 -17
  78. package/dist/stories/IframeCSSSupport.stories.d.ts +0 -28
  79. package/dist/stories/IframeSupport.stories.d.ts +0 -20
  80. package/dist/stories/Image.stories.d.ts +0 -6
  81. package/dist/stories/Scroll.stories.d.ts +0 -9
  82. package/dist/stories/ScrollAnimation.stories.d.ts +0 -36
  83. package/dist/stories/ScrollTimeline.stories.d.ts +0 -6
  84. package/dist/stories/Skeleton.stories.d.ts +0 -5
  85. package/dist/stories/Text.stories.d.ts +0 -18
  86. package/dist/stories/VendorPrefix.stories.d.ts +0 -6
  87. package/dist/stories/View.stories.d.ts +0 -10
  88. package/dist/stories/ViewAnimation.stories.d.ts +0 -33
  89. package/dist/test/CssVariablesTest.d.ts +0 -3
  90. package/dist/test/LowercaseVendorPrefixTest.d.ts +0 -3
  91. package/dist/test/VendorPrefixTest.d.ts +0 -3
  92. package/dist/test/WebkitTextStrokeTest.d.ts +0 -3
  93. package/dist/types/scrollAnimation.types.d.ts +0 -75
  94. package/dist/utils/colors.d.ts +0 -21
  95. package/dist/utils/constants.d.ts +0 -24
  96. package/dist/utils/cssProperties.d.ts +0 -8
  97. package/dist/utils/env.d.ts +0 -15
  98. package/dist/utils/hash.d.ts +0 -4
  99. package/dist/utils/shadow.d.ts +0 -10
  100. package/dist/utils/style.d.ts +0 -22
  101. package/dist/utils/typography.d.ts +0 -45
  102. package/dist/utils/vendorPrefixes.d.ts +0 -19
  103. package/dist/utils/viewAnimation.d.ts +0 -138
@@ -0,0 +1,3360 @@
1
+ "use strict";
2
+ var __create = Object.create;
3
+ var __defProp = Object.defineProperty;
4
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
5
+ var __getOwnPropNames = Object.getOwnPropertyNames;
6
+ var __getProtoOf = Object.getPrototypeOf;
7
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
8
+ var __export = (target, all) => {
9
+ for (var name in all)
10
+ __defProp(target, name, { get: all[name], enumerable: true });
11
+ };
12
+ var __copyProps = (to, from, except, desc) => {
13
+ if (from && typeof from === "object" || typeof from === "function") {
14
+ for (let key of __getOwnPropNames(from))
15
+ if (!__hasOwnProp.call(to, key) && key !== except)
16
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
17
+ }
18
+ return to;
19
+ };
20
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
21
+ // If the importer is in node compatibility mode or this is not an ESM
22
+ // file that has been converted to a CommonJS file using a Babel-
23
+ // compatible transform (i.e. "__esModule" has not been set), then set
24
+ // "default" to the CommonJS "module.exports" for node compatibility.
25
+ isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
26
+ mod
27
+ ));
28
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
29
+
30
+ // src/native/index.tsx
31
+ var native_exports = {};
32
+ __export(native_exports, {
33
+ AnalyticsContext: () => AnalyticsContext,
34
+ AnalyticsProvider: () => AnalyticsProvider,
35
+ Animation: () => Animation_exports,
36
+ BreakpointContext: () => BreakpointContext,
37
+ Button: () => Button,
38
+ Center: () => Center,
39
+ Div: () => Div,
40
+ Element: () => Element,
41
+ Form: () => Form,
42
+ Horizontal: () => Horizontal,
43
+ HorizontalResponsive: () => HorizontalResponsive,
44
+ Image: () => Image,
45
+ ImageBackground: () => ImageBackground,
46
+ Input: () => Input,
47
+ ResponsiveContext: () => ResponsiveContext,
48
+ ResponsiveProvider: () => ResponsiveProvider,
49
+ SafeArea: () => SafeArea,
50
+ Scroll: () => Scroll,
51
+ Shadows: () => Shadows,
52
+ Skeleton: () => Skeleton,
53
+ Span: () => Span,
54
+ StyleRegistry: () => StyleRegistry,
55
+ Text: () => Text,
56
+ ThemeContext: () => ThemeContext,
57
+ ThemeProvider: () => ThemeProvider,
58
+ Typography: () => Typography,
59
+ Vertical: () => Vertical,
60
+ VerticalResponsive: () => VerticalResponsive,
61
+ View: () => View,
62
+ WindowDimensionsContext: () => WindowDimensionsContext,
63
+ WindowSizeContext: () => WindowSizeContext,
64
+ WindowSizeProvider: () => WindowSizeProvider,
65
+ animateOnView: () => animateOnView,
66
+ blurInOnView: () => blurInOnView,
67
+ blurOutOnView: () => blurOutOnView,
68
+ createStyleRegistry: () => createStyleRegistry,
69
+ createViewAnimation: () => createViewAnimation,
70
+ defaultColors: () => defaultColors,
71
+ defaultDarkColors: () => defaultDarkColors,
72
+ defaultDarkPalette: () => defaultDarkPalette,
73
+ defaultLightColors: () => defaultLightColors,
74
+ defaultLightPalette: () => defaultLightPalette,
75
+ fadeInOnView: () => fadeInOnView,
76
+ fadeOutOnView: () => fadeOutOnView,
77
+ flipXOnView: () => flipXOnView,
78
+ flipYOnView: () => flipYOnView,
79
+ getBreakpointFromWidth: () => getBreakpointFromWidth,
80
+ getDeviceFromBreakpoint: () => getDeviceFromBreakpoint,
81
+ getWindowInitialProps: () => getWindowInitialProps,
82
+ hasColorToken: () => hasColorToken,
83
+ isBrowser: () => isBrowser,
84
+ isDev: () => isDev,
85
+ isMobile: () => isMobile,
86
+ isProd: () => isProd,
87
+ isSSR: () => isSSR,
88
+ replaceColorTokens: () => replaceColorTokens,
89
+ revealOnView: () => revealOnView,
90
+ rotateInOnView: () => rotateInOnView,
91
+ scaleDownOnView: () => scaleDownOnView,
92
+ scaleUpOnView: () => scaleUpOnView,
93
+ slideDownOnView: () => slideDownOnView,
94
+ slideLeftOnView: () => slideLeftOnView,
95
+ slideRightOnView: () => slideRightOnView,
96
+ slideUpOnView: () => slideUpOnView,
97
+ useActive: () => useActive,
98
+ useAnalytics: () => useAnalytics,
99
+ useBreakpoint: () => useBreakpoint,
100
+ useBreakpointContext: () => useBreakpointContext,
101
+ useClickOutside: () => useClickOutside,
102
+ useElementPosition: () => useElementPosition,
103
+ useFocus: () => useFocus,
104
+ useHover: () => useHover,
105
+ useIframeStyles: () => useIframeStyles,
106
+ useInView: () => useInView,
107
+ useKeyPress: () => useKeyPress,
108
+ useMount: () => useMount,
109
+ useOnScreen: () => useOnScreen,
110
+ useResponsive: () => useResponsive,
111
+ useResponsiveContext: () => useResponsiveContext,
112
+ useScroll: () => useScroll,
113
+ useServerInsertedHTML: () => useServerInsertedHTML,
114
+ useStyleRegistry: () => useStyleRegistry,
115
+ useTheme: () => useTheme,
116
+ useWindowDimensions: () => useWindowDimensions2,
117
+ useWindowDimensionsContext: () => useWindowDimensionsContext,
118
+ useWindowSize: () => useWindowSize,
119
+ viewAnimationPresets: () => viewAnimationPresets
120
+ });
121
+ module.exports = __toCommonJS(native_exports);
122
+
123
+ // src/native/components.tsx
124
+ var import_react4 = __toESM(require("react"));
125
+ var import_react_native3 = require("react-native");
126
+
127
+ // src/native/style.ts
128
+ var import_react3 = require("react");
129
+ var import_react_native2 = require("react-native");
130
+
131
+ // src/native/providers/Responsive.tsx
132
+ var import_react = __toESM(require("react"));
133
+ var import_react_native = require("react-native");
134
+ var defaultBreakpointsConfig = {
135
+ xs: 0,
136
+ sm: 340,
137
+ md: 560,
138
+ lg: 1080,
139
+ xl: 1300
140
+ };
141
+ var defaultDeviceConfig = {
142
+ mobile: ["xs", "sm"],
143
+ tablet: ["md", "lg"],
144
+ desktop: ["lg", "xl"]
145
+ };
146
+ function getMediaQueries(breakpoints) {
147
+ const sorted = Object.keys(breakpoints).map((breakpoint) => ({
148
+ breakpoint,
149
+ min: breakpoints[breakpoint],
150
+ max: void 0
151
+ })).sort((a, b) => a.min - b.min);
152
+ for (let i = 0; i < sorted.length - 1; i++) {
153
+ sorted[i].max = sorted[i + 1].min - 1;
154
+ }
155
+ return sorted.reduce((queries, item) => {
156
+ queries[item.breakpoint] = `only screen${item.min > 0 ? ` and (min-width: ${item.min}px)` : ""}${item.max !== void 0 ? ` and (max-width: ${item.max}px)` : ""}`;
157
+ return queries;
158
+ }, {});
159
+ }
160
+ function getBreakpointFromWidth(width, breakpoints) {
161
+ const sorted = Object.entries(breakpoints).sort(([, a], [, b]) => b - a);
162
+ const match = sorted.find(([, min]) => width >= min);
163
+ return match?.[0] || sorted[sorted.length - 1]?.[0] || "xs";
164
+ }
165
+ function getDeviceFromBreakpoint(breakpoint, devices) {
166
+ const device = Object.keys(devices).find(
167
+ (key) => devices[key].includes(breakpoint)
168
+ );
169
+ return device || "desktop";
170
+ }
171
+ var defaultBreakpointConfig = {
172
+ breakpoints: defaultBreakpointsConfig,
173
+ devices: defaultDeviceConfig,
174
+ mediaQueries: getMediaQueries(defaultBreakpointsConfig),
175
+ currentBreakpoint: "xs",
176
+ currentDevice: "mobile",
177
+ orientation: "portrait"
178
+ };
179
+ var defaultWindowDimensions = {
180
+ width: 0,
181
+ height: 0
182
+ };
183
+ var BreakpointContext = (0, import_react.createContext)(
184
+ defaultBreakpointConfig
185
+ );
186
+ var WindowDimensionsContext = (0, import_react.createContext)(
187
+ defaultWindowDimensions
188
+ );
189
+ var ResponsiveContext = (0, import_react.createContext)({
190
+ ...defaultBreakpointConfig,
191
+ currentWidth: 0,
192
+ currentHeight: 0
193
+ });
194
+ var useBreakpointContext = () => (0, import_react.useContext)(BreakpointContext);
195
+ var useWindowDimensionsContext = () => (0, import_react.useContext)(WindowDimensionsContext);
196
+ var useResponsiveContext = () => (0, import_react.useContext)(ResponsiveContext);
197
+ var ResponsiveProvider = ({
198
+ breakpoints = defaultBreakpointsConfig,
199
+ devices = defaultDeviceConfig,
200
+ children
201
+ }) => {
202
+ const dimensions = (0, import_react_native.useWindowDimensions)();
203
+ const width = dimensions.width || 0;
204
+ const height = dimensions.height || 0;
205
+ const currentBreakpoint = getBreakpointFromWidth(width, breakpoints);
206
+ const currentDevice = getDeviceFromBreakpoint(currentBreakpoint, devices);
207
+ const orientation = width >= height ? "landscape" : "portrait";
208
+ const breakpointValue = (0, import_react.useMemo)(
209
+ () => ({
210
+ breakpoints,
211
+ devices,
212
+ mediaQueries: getMediaQueries(breakpoints),
213
+ currentBreakpoint,
214
+ currentDevice,
215
+ orientation
216
+ }),
217
+ [breakpoints, devices, currentBreakpoint, currentDevice, orientation]
218
+ );
219
+ const windowValue = (0, import_react.useMemo)(
220
+ () => ({ width, height }),
221
+ [width, height]
222
+ );
223
+ const responsiveValue = (0, import_react.useMemo)(
224
+ () => ({
225
+ ...breakpointValue,
226
+ currentWidth: width,
227
+ currentHeight: height
228
+ }),
229
+ [breakpointValue, width, height]
230
+ );
231
+ return /* @__PURE__ */ import_react.default.createElement(BreakpointContext.Provider, { value: breakpointValue }, /* @__PURE__ */ import_react.default.createElement(WindowDimensionsContext.Provider, { value: windowValue }, /* @__PURE__ */ import_react.default.createElement(ResponsiveContext.Provider, { value: responsiveValue }, children)));
232
+ };
233
+
234
+ // src/native/providers/Theme.tsx
235
+ var import_react2 = __toESM(require("react"));
236
+
237
+ // src/utils/colors.ts
238
+ var defaultLightPalette = {
239
+ white: {
240
+ 50: "rgba(255, 255, 255, 0.04)",
241
+ 100: "rgba(255, 255, 255, 0.08)",
242
+ 200: "rgba(255, 255, 255, 0.16)",
243
+ 300: "rgba(255, 255, 255, 0.24)",
244
+ 400: "rgba(255, 255, 255, 0.36)",
245
+ 500: "rgba(255, 255, 255, 0.48)",
246
+ 600: "rgba(255, 255, 255, 0.64)",
247
+ 700: "rgba(255, 255, 255, 0.80)",
248
+ 800: "rgba(255, 255, 255, 0.92)",
249
+ 900: "rgba(255, 255, 255, 1)"
250
+ },
251
+ black: {
252
+ 50: "rgba(0, 0, 0, 0.04)",
253
+ 100: "rgba(0, 0, 0, 0.08)",
254
+ 200: "rgba(0, 0, 0, 0.16)",
255
+ 300: "rgba(0, 0, 0, 0.24)",
256
+ 400: "rgba(0, 0, 0, 0.36)",
257
+ 500: "rgba(0, 0, 0, 0.48)",
258
+ 600: "rgba(0, 0, 0, 0.64)",
259
+ 700: "rgba(0, 0, 0, 0.80)",
260
+ 800: "rgba(0, 0, 0, 0.92)",
261
+ 900: "rgba(0, 0, 0, 1)"
262
+ },
263
+ rose: {
264
+ 50: "#fff1f2",
265
+ 100: "#ffe4e6",
266
+ 200: "#fecdd3",
267
+ 300: "#fda4af",
268
+ 400: "#fb7185",
269
+ 500: "#f43f5e",
270
+ 600: "#e11d48",
271
+ 700: "#be123c",
272
+ 800: "#9f1239",
273
+ 900: "#881337"
274
+ },
275
+ pink: {
276
+ 50: "#fdf2f8",
277
+ 100: "#fce7f3",
278
+ 200: "#fbcfe8",
279
+ 300: "#f9a8d4",
280
+ 400: "#f472b6",
281
+ 500: "#ec4899",
282
+ 600: "#db2777",
283
+ 700: "#be185d",
284
+ 800: "#9d174d",
285
+ 900: "#831843"
286
+ },
287
+ fuchsia: {
288
+ 50: "#fdf4ff",
289
+ 100: "#fae8ff",
290
+ 200: "#f5d0fe",
291
+ 300: "#f0abfc",
292
+ 400: "#e879f9",
293
+ 500: "#d946ef",
294
+ 600: "#c026d3",
295
+ 700: "#a21caf",
296
+ 800: "#86198f",
297
+ 900: "#701a75"
298
+ },
299
+ purple: {
300
+ 50: "#faf5ff",
301
+ 100: "#f3e8ff",
302
+ 200: "#e9d5ff",
303
+ 300: "#d8b4fe",
304
+ 400: "#c084fc",
305
+ 500: "#a855f7",
306
+ 600: "#9333ea",
307
+ 700: "#7e22ce",
308
+ 800: "#6b21a8",
309
+ 900: "#581c87"
310
+ },
311
+ violet: {
312
+ 50: "#f5f3ff",
313
+ 100: "#ede9fe",
314
+ 200: "#ddd6fe",
315
+ 300: "#c4b5fd",
316
+ 400: "#a78bfa",
317
+ 500: "#8b5cf6",
318
+ 600: "#7c3aed",
319
+ 700: "#6d28d9",
320
+ 800: "#5b21b6",
321
+ 900: "#4c1d95"
322
+ },
323
+ indigo: {
324
+ 50: "#eef2ff",
325
+ 100: "#e0e7ff",
326
+ 200: "#c7d2fe",
327
+ 300: "#a5b4fc",
328
+ 400: "#818cf8",
329
+ 500: "#6366f1",
330
+ 600: "#4f46e5",
331
+ 700: "#4338ca",
332
+ 800: "#3730a3",
333
+ 900: "#312e81"
334
+ },
335
+ blue: {
336
+ 50: "#eff6ff",
337
+ 100: "#dbeafe",
338
+ 200: "#bfdbfe",
339
+ 300: "#93c5fd",
340
+ 400: "#60a5fa",
341
+ 500: "#3b82f6",
342
+ 600: "#2563eb",
343
+ 700: "#1d4ed8",
344
+ 800: "#1e40af",
345
+ 900: "#1e3a8a"
346
+ },
347
+ lightBlue: {
348
+ 50: "#f0f9ff",
349
+ 100: "#e0f2fe",
350
+ 200: "#bae6fd",
351
+ 300: "#7dd3fc",
352
+ 400: "#38bdf8",
353
+ 500: "#0ea5e9",
354
+ 600: "#0284c7",
355
+ 700: "#0369a1",
356
+ 800: "#075985",
357
+ 900: "#0c4a6e"
358
+ },
359
+ cyan: {
360
+ 50: "#ecfeff",
361
+ 100: "#cffafe",
362
+ 200: "#a5f3fc",
363
+ 300: "#67e8f9",
364
+ 400: "#22d3ee",
365
+ 500: "#06b6d4",
366
+ 600: "#0891b2",
367
+ 700: "#0e7490",
368
+ 800: "#155e75",
369
+ 900: "#164e63"
370
+ },
371
+ teal: {
372
+ 50: "#f0fdfa",
373
+ 100: "#ccfbf1",
374
+ 200: "#99f6e4",
375
+ 300: "#5eead4",
376
+ 400: "#2dd4bf",
377
+ 500: "#14b8a6",
378
+ 600: "#0d9488",
379
+ 700: "#0f766e",
380
+ 800: "#115e59",
381
+ 900: "#134e4a"
382
+ },
383
+ emerald: {
384
+ 50: "#ecfdf5",
385
+ 100: "#d1fae5",
386
+ 200: "#a7f3d0",
387
+ 300: "#6ee7b7",
388
+ 400: "#34d399",
389
+ 500: "#10b981",
390
+ 600: "#059669",
391
+ 700: "#047857",
392
+ 800: "#065f46",
393
+ 900: "#064e3b"
394
+ },
395
+ green: {
396
+ 50: "#f0fdf4",
397
+ 100: "#dcfce7",
398
+ 200: "#bbf7d0",
399
+ 300: "#86efac",
400
+ 400: "#4ade80",
401
+ 500: "#22c55e",
402
+ 600: "#16a34a",
403
+ 700: "#15803d",
404
+ 800: "#166534",
405
+ 900: "#14532d"
406
+ },
407
+ lime: {
408
+ 50: "#f7fee7",
409
+ 100: "#ecfccb",
410
+ 200: "#d9f99d",
411
+ 300: "#bef264",
412
+ 400: "#a3e635",
413
+ 500: "#84cc16",
414
+ 600: "#65a30d",
415
+ 700: "#4d7c0f",
416
+ 800: "#3f6212",
417
+ 900: "#365314"
418
+ },
419
+ yellow: {
420
+ 50: "#fefce8",
421
+ 100: "#fef9c3",
422
+ 200: "#fef08a",
423
+ 300: "#fde047",
424
+ 400: "#facc15",
425
+ 500: "#eab308",
426
+ 600: "#ca8a04",
427
+ 700: "#a16207",
428
+ 800: "#854d0e",
429
+ 900: "#713f12"
430
+ },
431
+ amber: {
432
+ 50: "#fffbeb",
433
+ 100: "#fef3c7",
434
+ 200: "#fde68a",
435
+ 300: "#fcd34d",
436
+ 400: "#fbbf24",
437
+ 500: "#f59e0b",
438
+ 600: "#d97706",
439
+ 700: "#b45309",
440
+ 800: "#92400e",
441
+ 900: "#78350f"
442
+ },
443
+ orange: {
444
+ 50: "#fff7ed",
445
+ 100: "#ffedd5",
446
+ 200: "#fed7aa",
447
+ 300: "#fdba74",
448
+ 400: "#fb923c",
449
+ 500: "#f97316",
450
+ 600: "#ea580c",
451
+ 700: "#c2410c",
452
+ 800: "#9a3412",
453
+ 900: "#7c2d12"
454
+ },
455
+ red: {
456
+ 50: "#fef2f2",
457
+ 100: "#fee2e2",
458
+ 200: "#fecaca",
459
+ 300: "#fca5a5",
460
+ 400: "#f87171",
461
+ 500: "#ef4444",
462
+ 600: "#dc2626",
463
+ 700: "#b91c1c",
464
+ 800: "#991b1b",
465
+ 900: "#7f1d1d"
466
+ },
467
+ warmGray: {
468
+ 50: "#fafaf9",
469
+ 100: "#f5f5f4",
470
+ 200: "#e7e5e4",
471
+ 300: "#d6d3d1",
472
+ 400: "#a8a29e",
473
+ 500: "#78716c",
474
+ 600: "#57534e",
475
+ 700: "#44403c",
476
+ 800: "#292524",
477
+ 900: "#1c1917"
478
+ },
479
+ trueGray: {
480
+ 50: "#fafafa",
481
+ 100: "#f5f5f5",
482
+ 200: "#e5e5e5",
483
+ 300: "#d4d4d4",
484
+ 400: "#a3a3a3",
485
+ 500: "#737373",
486
+ 600: "#525252",
487
+ 700: "#404040",
488
+ 800: "#262626",
489
+ 900: "#171717"
490
+ },
491
+ gray: {
492
+ 50: "#fafafa",
493
+ 100: "#f4f4f5",
494
+ 200: "#e4e4e7",
495
+ 300: "#d4d4d8",
496
+ 400: "#a1a1aa",
497
+ 500: "#71717a",
498
+ 600: "#52525b",
499
+ 700: "#3f3f46",
500
+ 800: "#27272a",
501
+ 900: "#18181b"
502
+ },
503
+ dark: {
504
+ 50: "#18181b",
505
+ 100: "#27272a",
506
+ 200: "#3f3f46",
507
+ 300: "#52525b",
508
+ 400: "#71717a",
509
+ 500: "#a1a1aa",
510
+ 600: "#d4d4d8",
511
+ 700: "#e4e4e7",
512
+ 800: "#f4f4f5",
513
+ 900: "#fafafa"
514
+ },
515
+ light: {
516
+ 50: "#f8f9fa",
517
+ 100: "#f1f3f5",
518
+ 200: "#e9ecef",
519
+ 300: "#dee2e6",
520
+ 400: "#ced4da",
521
+ 500: "#adb5bd",
522
+ 600: "#868e96",
523
+ 700: "#495057",
524
+ 800: "#343a40",
525
+ 900: "#212529"
526
+ },
527
+ coolGray: {
528
+ 50: "#f9fafb",
529
+ 100: "#f3f4f6",
530
+ 200: "#e5e7eb",
531
+ 300: "#d1d5db",
532
+ 400: "#9ca3af",
533
+ 500: "#6b7280",
534
+ 600: "#4b5563",
535
+ 700: "#374151",
536
+ 800: "#1f2937",
537
+ 900: "#111827"
538
+ },
539
+ blueGray: {
540
+ 50: "#f8fafc",
541
+ 100: "#f1f5f9",
542
+ 200: "#e2e8f0",
543
+ 300: "#cbd5e1",
544
+ 400: "#94a3b8",
545
+ 500: "#64748b",
546
+ 600: "#475569",
547
+ 700: "#334155",
548
+ 800: "#1e293b",
549
+ 900: "#0f172a"
550
+ },
551
+ slate: {
552
+ 50: "#f8fafc",
553
+ 100: "#f1f5f9",
554
+ 200: "#e2e8f0",
555
+ 300: "#cbd5e1",
556
+ 400: "#94a3b8",
557
+ 500: "#64748b",
558
+ 600: "#475569",
559
+ 700: "#334155",
560
+ 800: "#1e293b",
561
+ 900: "#0f172a"
562
+ },
563
+ zinc: {
564
+ 50: "#fafafa",
565
+ 100: "#f4f4f5",
566
+ 200: "#e4e4e7",
567
+ 300: "#d4d4d8",
568
+ 400: "#a1a1aa",
569
+ 500: "#71717a",
570
+ 600: "#52525b",
571
+ 700: "#3f3f46",
572
+ 800: "#27272a",
573
+ 900: "#18181b"
574
+ },
575
+ neutral: {
576
+ 50: "#fafafa",
577
+ 100: "#f5f5f5",
578
+ 200: "#e5e5e5",
579
+ 300: "#d4d4d4",
580
+ 400: "#a3a3a3",
581
+ 500: "#737373",
582
+ 600: "#525252",
583
+ 700: "#404040",
584
+ 800: "#262626",
585
+ 900: "#171717"
586
+ },
587
+ stone: {
588
+ 50: "#fafaf9",
589
+ 100: "#f5f5f4",
590
+ 200: "#e7e5e4",
591
+ 300: "#d6d3d1",
592
+ 400: "#a8a29e",
593
+ 500: "#78716c",
594
+ 600: "#57534e",
595
+ 700: "#44403c",
596
+ 800: "#292524",
597
+ 900: "#1c1917"
598
+ }
599
+ };
600
+ var defaultDarkPalette = {
601
+ white: {
602
+ 50: "rgba(0, 0, 0, 0.04)",
603
+ 100: "rgba(0, 0, 0, 0.08)",
604
+ 200: "rgba(0, 0, 0, 0.16)",
605
+ 300: "rgba(0, 0, 0, 0.24)",
606
+ 400: "rgba(0, 0, 0, 0.36)",
607
+ 500: "rgba(0, 0, 0, 0.48)",
608
+ 600: "rgba(0, 0, 0, 0.64)",
609
+ 700: "rgba(0, 0, 0, 0.80)",
610
+ 800: "rgba(0, 0, 0, 0.92)",
611
+ 900: "rgba(0, 0, 0, 1)"
612
+ },
613
+ black: {
614
+ 50: "rgba(255, 255, 255, 0.04)",
615
+ 100: "rgba(255, 255, 255, 0.08)",
616
+ 200: "rgba(255, 255, 255, 0.16)",
617
+ 300: "rgba(255, 255, 255, 0.24)",
618
+ 400: "rgba(255, 255, 255, 0.36)",
619
+ 500: "rgba(255, 255, 255, 0.48)",
620
+ 600: "rgba(255, 255, 255, 0.64)",
621
+ 700: "rgba(255, 255, 255, 0.80)",
622
+ 800: "rgba(255, 255, 255, 0.92)",
623
+ 900: "rgba(255, 255, 255, 1)"
624
+ },
625
+ rose: {
626
+ 50: "#330517",
627
+ 100: "#4a031e",
628
+ 200: "#6b112f",
629
+ 300: "#9f1239",
630
+ 400: "#c81e5b",
631
+ 500: "#e11d48",
632
+ 600: "#be123c",
633
+ 700: "#9f1239",
634
+ 800: "#7f1235",
635
+ 900: "#581c87"
636
+ },
637
+ pink: {
638
+ 50: "#fce7f3",
639
+ 100: "#fbcfe8",
640
+ 200: "#f9a8d4",
641
+ 300: "#f472b6",
642
+ 400: "#ec4899",
643
+ 500: "#db2777",
644
+ 600: "#be185d",
645
+ 700: "#9d174d",
646
+ 800: "#831843",
647
+ 900: "#581c87"
648
+ },
649
+ fuchsia: {
650
+ 50: "#c026d3",
651
+ 100: "#a21caf",
652
+ 200: "#86198f",
653
+ 300: "#701a75",
654
+ 400: "#9333ea",
655
+ 500: "#d946ef",
656
+ 600: "#e879f9",
657
+ 700: "#f0abfc",
658
+ 800: "#f5d0fe",
659
+ 900: "#fae8ff"
660
+ },
661
+ purple: {
662
+ 50: "#6b21a8",
663
+ 100: "#7e22ce",
664
+ 200: "#9333ea",
665
+ 300: "#a855f7",
666
+ 400: "#c084fc",
667
+ 500: "#d8b4fe",
668
+ 600: "#e9d5ff",
669
+ 700: "#f3e8ff",
670
+ 800: "#faf5ff",
671
+ 900: "#fef4ff"
672
+ },
673
+ violet: {
674
+ 50: "#4c1d95",
675
+ 100: "#701a75",
676
+ 200: "#86198f",
677
+ 300: "#a21caf",
678
+ 400: "#c026d3",
679
+ 500: "#d946ef",
680
+ 600: "#e879f9",
681
+ 700: "#f0abfc",
682
+ 800: "#f5d0fe",
683
+ 900: "#fae8ff"
684
+ },
685
+ indigo: {
686
+ 50: "#312e81",
687
+ 100: "#3730a3",
688
+ 200: "#1e40af",
689
+ 300: "#1d4ed8",
690
+ 400: "#2563eb",
691
+ 500: "#3b82f6",
692
+ 600: "#60a5fa",
693
+ 700: "#93c5fd",
694
+ 800: "#bfdbfe",
695
+ 900: "#dbeafe"
696
+ },
697
+ blue: {
698
+ 50: "#1e3a8a",
699
+ 100: "#1e40af",
700
+ 200: "#1d4ed8",
701
+ 300: "#2563eb",
702
+ 400: "#3b82f6",
703
+ 500: "#60a5fa",
704
+ 600: "#93c5fd",
705
+ 700: "#bfdbfe",
706
+ 800: "#dbeafe",
707
+ 900: "#eff6ff"
708
+ },
709
+ lightBlue: {
710
+ 50: "#0c4a6e",
711
+ 100: "#075985",
712
+ 200: "#0369a1",
713
+ 300: "#0284c7",
714
+ 400: "#0ea5e9",
715
+ 500: "#38bdf8",
716
+ 600: "#7dd3fc",
717
+ 700: "#bae6fd",
718
+ 800: "#e0f2fe",
719
+ 900: "#f0f9ff"
720
+ },
721
+ cyan: {
722
+ 50: "#164e63",
723
+ 100: "#155e75",
724
+ 200: "#0e7490",
725
+ 300: "#0891b2",
726
+ 400: "#22d3ee",
727
+ 500: "#67e8f9",
728
+ 600: "#a5f3fc",
729
+ 700: "#cffafe",
730
+ 800: "#ecfeff",
731
+ 900: "#f0fefe"
732
+ },
733
+ teal: {
734
+ 50: "#134e4a",
735
+ 100: "#166534",
736
+ 200: "#15803d",
737
+ 300: "#16a34a",
738
+ 400: "#22c55e",
739
+ 500: "#4ade80",
740
+ 600: "#5eead4",
741
+ 700: "#99f6e4",
742
+ 800: "#ccfbf1",
743
+ 900: "#f0fdfa"
744
+ },
745
+ emerald: {
746
+ 50: "#064e3b",
747
+ 100: "#065f46",
748
+ 200: "#047857",
749
+ 300: "#059669",
750
+ 400: "#10b981",
751
+ 500: "#34d399",
752
+ 600: "#6ee7b7",
753
+ 700: "#a7f3d0",
754
+ 800: "#d1fae5",
755
+ 900: "#ecfdf5"
756
+ },
757
+ green: {
758
+ 50: "#14532d",
759
+ 100: "#166534",
760
+ 200: "#15803d",
761
+ 300: "#16a34a",
762
+ 400: "#22c55e",
763
+ 500: "#4ade80",
764
+ 600: "#86efac",
765
+ 700: "#bbf7d0",
766
+ 800: "#dcfce7",
767
+ 900: "#f0fdf4"
768
+ },
769
+ lime: {
770
+ 50: "#365314",
771
+ 100: "#3f6212",
772
+ 200: "#4d7c0f",
773
+ 300: "#65a30d",
774
+ 400: "#84cc16",
775
+ 500: "#a3e635",
776
+ 600: "#bef264",
777
+ 700: "#d9f99d",
778
+ 800: "#ecfccb",
779
+ 900: "#f7fee7"
780
+ },
781
+ yellow: {
782
+ 50: "#713f12",
783
+ 100: "#854d0e",
784
+ 200: "#a16207",
785
+ 300: "#ca8a04",
786
+ 400: "#eab308",
787
+ 500: "#facc15",
788
+ 600: "#fde047",
789
+ 700: "#fef08a",
790
+ 800: "#fef9c3",
791
+ 900: "#fefce8"
792
+ },
793
+ amber: {
794
+ 50: "#78350f",
795
+ 100: "#92400e",
796
+ 200: "#b45309",
797
+ 300: "#d97706",
798
+ 400: "#f59e0b",
799
+ 500: "#fbbf24",
800
+ 600: "#fcd34d",
801
+ 700: "#fde68a",
802
+ 800: "#fef3c7",
803
+ 900: "#fffbeb"
804
+ },
805
+ orange: {
806
+ 50: "#7c2d12",
807
+ 100: "#9a3412",
808
+ 200: "#c2410c",
809
+ 300: "#ea580c",
810
+ 400: "#f97316",
811
+ 500: "#fb923c",
812
+ 600: "#fdba74",
813
+ 700: "#fed7aa",
814
+ 800: "#ffedd5",
815
+ 900: "#fff7ed"
816
+ },
817
+ red: {
818
+ 50: "#7f1d1d",
819
+ 100: "#991b1b",
820
+ 200: "#b91c1c",
821
+ 300: "#dc2626",
822
+ 400: "#ef4444",
823
+ 500: "#f87171",
824
+ 600: "#fca5a5",
825
+ 700: "#fecaca",
826
+ 800: "#fee2e2",
827
+ 900: "#fef2f2"
828
+ },
829
+ warmGray: {
830
+ 50: "#1c1917",
831
+ 100: "#292524",
832
+ 200: "#44403c",
833
+ 300: "#57534e",
834
+ 400: "#78716c",
835
+ 500: "#a8a29e",
836
+ 600: "#d6d3d1",
837
+ 700: "#e7e5e4",
838
+ 800: "#f5f5f4",
839
+ 900: "#fafaf9"
840
+ },
841
+ trueGray: {
842
+ 50: "#171717",
843
+ 100: "#262626",
844
+ 200: "#404040",
845
+ 300: "#525252",
846
+ 400: "#737373",
847
+ 500: "#a3a3a3",
848
+ 600: "#d4d4d4",
849
+ 700: "#e5e5e5",
850
+ 800: "#f5f5f5",
851
+ 900: "#fafafa"
852
+ },
853
+ gray: {
854
+ 50: "#18181b",
855
+ 100: "#27272a",
856
+ 200: "#3f3f46",
857
+ 300: "#52525b",
858
+ 400: "#71717a",
859
+ 500: "#a1a1aa",
860
+ 600: "#d4d4d8",
861
+ 700: "#e4e4e7",
862
+ 800: "#f4f4f5",
863
+ 900: "#fafafa"
864
+ },
865
+ dark: {
866
+ 50: "#212529",
867
+ 100: "#343a40",
868
+ 200: "#495057",
869
+ 300: "#868e96",
870
+ 400: "#adb5bd",
871
+ 500: "#ced4da",
872
+ 600: "#dee2e6",
873
+ 700: "#f1f3f5",
874
+ 800: "#f8f9fa",
875
+ 900: "#ffffff"
876
+ },
877
+ light: {
878
+ 50: "#fafafa",
879
+ 100: "#f4f4f5",
880
+ 200: "#e4e4e7",
881
+ 300: "#d4d4d8",
882
+ 400: "#a1a1aa",
883
+ 500: "#71717a",
884
+ 600: "#52525b",
885
+ 700: "#3f3f46",
886
+ 800: "#27272a",
887
+ 900: "#18181b"
888
+ },
889
+ coolGray: {
890
+ 50: "#111827",
891
+ 100: "#1f2937",
892
+ 200: "#374151",
893
+ 300: "#4b5563",
894
+ 400: "#6b7280",
895
+ 500: "#9ca3af",
896
+ 600: "#d1d5db",
897
+ 700: "#e5e7eb",
898
+ 800: "#f3f4f6",
899
+ 900: "#f9fafb"
900
+ },
901
+ blueGray: {
902
+ 50: "#0f172a",
903
+ 100: "#1e293b",
904
+ 200: "#334155",
905
+ 300: "#475569",
906
+ 400: "#64748b",
907
+ 500: "#94a3b8",
908
+ 600: "#cbd5e1",
909
+ 700: "#e2e8f0",
910
+ 800: "#f1f5f9",
911
+ 900: "#f8fafc"
912
+ },
913
+ slate: {
914
+ 50: "#0f172a",
915
+ 100: "#1e293b",
916
+ 200: "#334155",
917
+ 300: "#475569",
918
+ 400: "#64748b",
919
+ 500: "#94a3b8",
920
+ 600: "#cbd5e1",
921
+ 700: "#e2e8f0",
922
+ 800: "#f1f5f9",
923
+ 900: "#f8fafc"
924
+ },
925
+ zinc: {
926
+ 50: "#18181b",
927
+ 100: "#27272a",
928
+ 200: "#3f3f46",
929
+ 300: "#52525b",
930
+ 400: "#71717a",
931
+ 500: "#a1a1aa",
932
+ 600: "#d4d4d8",
933
+ 700: "#e4e4e7",
934
+ 800: "#f4f4f5",
935
+ 900: "#fafafa"
936
+ },
937
+ neutral: {
938
+ 50: "#171717",
939
+ 100: "#262626",
940
+ 200: "#404040",
941
+ 300: "#525252",
942
+ 400: "#737373",
943
+ 500: "#a3a3a3",
944
+ 600: "#d4d4d4",
945
+ 700: "#e5e5e5",
946
+ 800: "#f5f5f5",
947
+ 900: "#fafafa"
948
+ },
949
+ stone: {
950
+ 50: "#1c1917",
951
+ 100: "#292524",
952
+ 200: "#44403c",
953
+ 300: "#57534e",
954
+ 400: "#78716c",
955
+ 500: "#a8a29e",
956
+ 600: "#d6d3d1",
957
+ 700: "#e7e5e4",
958
+ 800: "#f5f5f4",
959
+ 900: "#fafaf9"
960
+ }
961
+ };
962
+ var defaultColors = {
963
+ white: "#FFFFFF",
964
+ black: "#000000",
965
+ red: "#FF0000",
966
+ green: "#00FF00",
967
+ blue: "#0000FF",
968
+ yellow: "#FFFF00",
969
+ cyan: "#00FFFF",
970
+ magenta: "#FF00FF",
971
+ grey: "#808080",
972
+ orange: "#FFA500",
973
+ brown: "#A52A2A",
974
+ purple: "#800080",
975
+ pink: "#FFC0CB"
976
+ };
977
+ var defaultLightColors = { ...defaultColors };
978
+ var defaultDarkColors = {
979
+ ...defaultColors,
980
+ white: "#000000",
981
+ black: "#FFFFFF"
982
+ };
983
+ var COLOR_TOKEN_REGEX = /(color-[a-zA-Z0-9-]+|theme-[a-zA-Z0-9-]+)/g;
984
+ var hasColorToken = (value) => {
985
+ return value.includes("color-") || value.includes("theme-");
986
+ };
987
+ var replaceColorTokens = (value, resolver) => {
988
+ if (!hasColorToken(value)) {
989
+ return value;
990
+ }
991
+ return value.replace(COLOR_TOKEN_REGEX, (token) => {
992
+ return resolver(token);
993
+ });
994
+ };
995
+
996
+ // src/shared/theme.ts
997
+ var COLOR_PREFIX = "color-";
998
+ var THEME_PREFIX = "theme-";
999
+ var LIGHT_PREFIX = "light-";
1000
+ var DARK_PREFIX = "dark-";
1001
+ var TRANSPARENT = "transparent";
1002
+ var defaultThemeMain = {
1003
+ primary: "color-black",
1004
+ secondary: "color-blue",
1005
+ success: "color-green-500",
1006
+ error: "color-red-500",
1007
+ warning: "color-orange-500",
1008
+ disabled: "color-gray-500",
1009
+ loading: "color-dark-500"
1010
+ };
1011
+ var defaultThemeColors = {
1012
+ light: {
1013
+ main: defaultLightColors,
1014
+ palette: defaultLightPalette
1015
+ },
1016
+ dark: {
1017
+ main: defaultDarkColors,
1018
+ palette: defaultDarkPalette
1019
+ }
1020
+ };
1021
+ function deepMerge(target, source) {
1022
+ if (!source) return target;
1023
+ const output = { ...target };
1024
+ Object.keys(source).forEach((key) => {
1025
+ const sourceValue = source[key];
1026
+ const targetValue = target[key];
1027
+ if (sourceValue && typeof sourceValue === "object" && !Array.isArray(sourceValue) && targetValue && typeof targetValue === "object" && !Array.isArray(targetValue)) {
1028
+ output[key] = deepMerge(targetValue, sourceValue);
1029
+ } else if (sourceValue !== void 0) {
1030
+ output[key] = sourceValue;
1031
+ }
1032
+ });
1033
+ return output;
1034
+ }
1035
+ function applyAlpha(color, alpha) {
1036
+ const normalized = Math.max(0, Math.min(1e3, alpha)) / 1e3;
1037
+ if (color.startsWith("#")) {
1038
+ let hex = color.slice(1);
1039
+ if (hex.length === 3) {
1040
+ hex = hex.split("").map((char) => char + char).join("");
1041
+ }
1042
+ if (hex.length >= 6) {
1043
+ const r = parseInt(hex.slice(0, 2), 16);
1044
+ const g = parseInt(hex.slice(2, 4), 16);
1045
+ const b = parseInt(hex.slice(4, 6), 16);
1046
+ return `rgba(${r}, ${g}, ${b}, ${normalized})`;
1047
+ }
1048
+ }
1049
+ if (color.startsWith("rgb")) {
1050
+ const rgbMatch = color.match(/rgba?\(([^)]+)\)/);
1051
+ if (rgbMatch) {
1052
+ const values = rgbMatch[1].split(",").map((value) => value.trim());
1053
+ return `rgba(${values[0]}, ${values[1]}, ${values[2]}, ${normalized})`;
1054
+ }
1055
+ }
1056
+ return color;
1057
+ }
1058
+ function resolveThemeColor(token, options, depth = 0) {
1059
+ if (!token || typeof token !== "string") return String(token);
1060
+ if (token === TRANSPARENT) return token;
1061
+ if (depth > 25) return token;
1062
+ if (token.startsWith(THEME_PREFIX)) {
1063
+ const parts = token.substring(THEME_PREFIX.length).split("-");
1064
+ const lastPart = parts[parts.length - 1];
1065
+ const maybeAlpha = parseInt(lastPart, 10);
1066
+ const hasAlpha = parts.length >= 2 && !isNaN(maybeAlpha) && maybeAlpha >= 0 && maybeAlpha <= 1e3;
1067
+ const themeKey = hasAlpha ? parts.slice(0, -1).join("-") : parts.join("-");
1068
+ const themeValue = options.theme[themeKey];
1069
+ if (typeof themeValue !== "string") return token;
1070
+ const resolved = resolveThemeColor(themeValue, options, depth + 1);
1071
+ return hasAlpha ? applyAlpha(resolved, maybeAlpha) : resolved;
1072
+ }
1073
+ if (token.startsWith(COLOR_PREFIX)) {
1074
+ const parts = token.substring(COLOR_PREFIX.length).split("-");
1075
+ const colors = options.colors[options.themeMode];
1076
+ if (parts.length >= 3) {
1077
+ const maybeAlpha = parseInt(parts[parts.length - 1], 10);
1078
+ if (!isNaN(maybeAlpha) && maybeAlpha >= 0 && maybeAlpha <= 1e3) {
1079
+ const colorName = parts[0];
1080
+ const shade = Number(parts[1]);
1081
+ const value = colors.palette[colorName]?.[shade];
1082
+ return typeof value === "string" ? applyAlpha(value, maybeAlpha) : token;
1083
+ }
1084
+ }
1085
+ if (parts.length === 2) {
1086
+ const value = colors.palette[parts[0]]?.[Number(parts[1])];
1087
+ return typeof value === "string" ? value : token;
1088
+ }
1089
+ if (parts.length === 1) {
1090
+ const value = colors.main[parts[0]];
1091
+ return typeof value === "string" ? value : token;
1092
+ }
1093
+ return token;
1094
+ }
1095
+ if (token.startsWith(LIGHT_PREFIX) || token.startsWith(DARK_PREFIX)) {
1096
+ const themeMode = token.startsWith(LIGHT_PREFIX) ? "light" : "dark";
1097
+ const prefix = token.startsWith(LIGHT_PREFIX) ? LIGHT_PREFIX : DARK_PREFIX;
1098
+ return resolveThemeColor(
1099
+ `${COLOR_PREFIX}${token.substring(prefix.length)}`,
1100
+ { ...options, themeMode },
1101
+ depth + 1
1102
+ );
1103
+ }
1104
+ return token;
1105
+ }
1106
+ function normalizeHex(color) {
1107
+ if (!color || typeof color !== "string") return String(color);
1108
+ if (color === TRANSPARENT) return "#00000000";
1109
+ if (color.startsWith("#")) {
1110
+ const hex = color.slice(1);
1111
+ if (hex.length === 3) {
1112
+ return `#${hex.split("").map((char) => char + char).join("")}`.toLowerCase();
1113
+ }
1114
+ return color.toLowerCase();
1115
+ }
1116
+ const rgbMatch = color.match(/rgba?\(([^)]+)\)/);
1117
+ if (!rgbMatch) return color;
1118
+ const values = rgbMatch[1].split(",").map((value) => Number(value.trim()));
1119
+ if (values.length < 3 || values.some((value) => Number.isNaN(value))) {
1120
+ return color;
1121
+ }
1122
+ const [r, g, b] = values;
1123
+ return `#${[r, g, b].map(
1124
+ (value) => Math.max(0, Math.min(255, Math.round(value))).toString(16).padStart(2, "0")
1125
+ ).join("")}`;
1126
+ }
1127
+
1128
+ // src/native/providers/Theme.tsx
1129
+ var defaultContext = {
1130
+ getColor: (name) => name,
1131
+ getColorHex: (name) => name,
1132
+ getColorRGBA: (name) => name,
1133
+ getColorScheme: () => void 0,
1134
+ getContrastColor: () => "black",
1135
+ theme: defaultThemeMain,
1136
+ colors: defaultThemeColors.light,
1137
+ themeMode: "light",
1138
+ setThemeMode: () => {
1139
+ }
1140
+ };
1141
+ var ThemeContext = (0, import_react2.createContext)(defaultContext);
1142
+ var useTheme = () => (0, import_react2.useContext)(ThemeContext);
1143
+ function toRgba(color, alpha) {
1144
+ if (typeof alpha !== "number") return color;
1145
+ const normalized = Math.max(0, Math.min(1e3, alpha)) / 1e3;
1146
+ const hex = normalizeHex(color);
1147
+ if (!hex.startsWith("#") || hex.length < 7) return color;
1148
+ const r = parseInt(hex.slice(1, 3), 16);
1149
+ const g = parseInt(hex.slice(3, 5), 16);
1150
+ const b = parseInt(hex.slice(5, 7), 16);
1151
+ return `rgba(${r}, ${g}, ${b}, ${normalized})`;
1152
+ }
1153
+ function contrastColor(hex) {
1154
+ const normalized = normalizeHex(hex);
1155
+ if (!normalized.startsWith("#") || normalized.length < 7) return "black";
1156
+ const r = parseInt(normalized.slice(1, 3), 16);
1157
+ const g = parseInt(normalized.slice(3, 5), 16);
1158
+ const b = parseInt(normalized.slice(5, 7), 16);
1159
+ const luminance = (0.299 * r + 0.587 * g + 0.114 * b) / 255;
1160
+ return luminance > 0.58 ? "black" : "white";
1161
+ }
1162
+ var ThemeProvider = ({
1163
+ colors,
1164
+ lightColors,
1165
+ darkColors,
1166
+ theme,
1167
+ initialMode = "light",
1168
+ children
1169
+ }) => {
1170
+ const [themeMode, setThemeMode] = (0, import_react2.useState)(initialMode);
1171
+ const mergedTheme = (0, import_react2.useMemo)(
1172
+ () => deepMerge(defaultThemeMain, theme),
1173
+ [theme]
1174
+ );
1175
+ const mergedColors = (0, import_react2.useMemo)(
1176
+ () => ({
1177
+ light: deepMerge(
1178
+ defaultThemeColors.light,
1179
+ deepMerge(colors || {}, lightColors || {})
1180
+ ),
1181
+ dark: deepMerge(
1182
+ defaultThemeColors.dark,
1183
+ deepMerge(colors || {}, darkColors || {})
1184
+ )
1185
+ }),
1186
+ [colors, lightColors, darkColors]
1187
+ );
1188
+ const getColor = (0, import_react2.useCallback)(
1189
+ (name) => resolveThemeColor(name, {
1190
+ colors: mergedColors,
1191
+ theme: mergedTheme,
1192
+ themeMode
1193
+ }),
1194
+ [mergedColors, mergedTheme, themeMode]
1195
+ );
1196
+ const getColorHex = (0, import_react2.useCallback)(
1197
+ (name) => normalizeHex(getColor(name)),
1198
+ [getColor]
1199
+ );
1200
+ const getColorRGBA = (0, import_react2.useCallback)(
1201
+ (name, alpha) => toRgba(getColor(name), alpha),
1202
+ [getColor]
1203
+ );
1204
+ const getColorScheme = (0, import_react2.useCallback)((name) => {
1205
+ if (name.startsWith("theme-")) return name.slice("theme-".length);
1206
+ if (name.startsWith("color-")) return name.split("-")[1];
1207
+ return void 0;
1208
+ }, []);
1209
+ const getContrastColor = (0, import_react2.useCallback)(
1210
+ (name) => contrastColor(getColorHex(name)),
1211
+ [getColorHex]
1212
+ );
1213
+ const value = (0, import_react2.useMemo)(
1214
+ () => ({
1215
+ getColor,
1216
+ getColorHex,
1217
+ getColorRGBA,
1218
+ getColorScheme,
1219
+ getContrastColor,
1220
+ theme: mergedTheme,
1221
+ colors: mergedColors[themeMode],
1222
+ themeMode,
1223
+ setThemeMode
1224
+ }),
1225
+ [
1226
+ getColor,
1227
+ getColorHex,
1228
+ getColorRGBA,
1229
+ getColorScheme,
1230
+ getContrastColor,
1231
+ mergedTheme,
1232
+ mergedColors,
1233
+ themeMode
1234
+ ]
1235
+ );
1236
+ return /* @__PURE__ */ import_react2.default.createElement(ThemeContext.Provider, { value }, children);
1237
+ };
1238
+
1239
+ // src/native/style.ts
1240
+ var stylePropNames = /* @__PURE__ */ new Set([
1241
+ "alignContent",
1242
+ "alignItems",
1243
+ "alignSelf",
1244
+ "aspectRatio",
1245
+ "backfaceVisibility",
1246
+ "backgroundColor",
1247
+ "borderBottomColor",
1248
+ "borderBottomEndRadius",
1249
+ "borderBottomLeftRadius",
1250
+ "borderBottomRightRadius",
1251
+ "borderBottomStartRadius",
1252
+ "borderBottomWidth",
1253
+ "borderColor",
1254
+ "borderCurve",
1255
+ "borderEndColor",
1256
+ "borderEndWidth",
1257
+ "borderLeftColor",
1258
+ "borderLeftWidth",
1259
+ "borderRadius",
1260
+ "borderRightColor",
1261
+ "borderRightWidth",
1262
+ "borderStartColor",
1263
+ "borderStartWidth",
1264
+ "borderStyle",
1265
+ "borderTopColor",
1266
+ "borderTopEndRadius",
1267
+ "borderTopLeftRadius",
1268
+ "borderTopRightRadius",
1269
+ "borderTopStartRadius",
1270
+ "borderTopWidth",
1271
+ "borderWidth",
1272
+ "bottom",
1273
+ "boxShadow",
1274
+ "color",
1275
+ "columnGap",
1276
+ "direction",
1277
+ "display",
1278
+ "elevation",
1279
+ "end",
1280
+ "flex",
1281
+ "flexBasis",
1282
+ "flexDirection",
1283
+ "flexGrow",
1284
+ "flexShrink",
1285
+ "flexWrap",
1286
+ "fontFamily",
1287
+ "fontSize",
1288
+ "fontStyle",
1289
+ "fontVariant",
1290
+ "fontWeight",
1291
+ "gap",
1292
+ "height",
1293
+ "includeFontPadding",
1294
+ "justifyContent",
1295
+ "left",
1296
+ "letterSpacing",
1297
+ "lineHeight",
1298
+ "margin",
1299
+ "marginBottom",
1300
+ "marginEnd",
1301
+ "marginHorizontal",
1302
+ "marginLeft",
1303
+ "marginRight",
1304
+ "marginStart",
1305
+ "marginTop",
1306
+ "marginVertical",
1307
+ "maxHeight",
1308
+ "maxWidth",
1309
+ "minHeight",
1310
+ "minWidth",
1311
+ "objectFit",
1312
+ "opacity",
1313
+ "overflow",
1314
+ "overlayColor",
1315
+ "padding",
1316
+ "paddingBottom",
1317
+ "paddingEnd",
1318
+ "paddingHorizontal",
1319
+ "paddingLeft",
1320
+ "paddingRight",
1321
+ "paddingStart",
1322
+ "paddingTop",
1323
+ "paddingVertical",
1324
+ "position",
1325
+ "resizeMode",
1326
+ "right",
1327
+ "rowGap",
1328
+ "shadowColor",
1329
+ "shadowOffset",
1330
+ "shadowOpacity",
1331
+ "shadowRadius",
1332
+ "start",
1333
+ "textAlign",
1334
+ "textAlignVertical",
1335
+ "textDecorationColor",
1336
+ "textDecorationLine",
1337
+ "textDecorationStyle",
1338
+ "textShadowColor",
1339
+ "textShadowOffset",
1340
+ "textShadowRadius",
1341
+ "textTransform",
1342
+ "tintColor",
1343
+ "top",
1344
+ "transform",
1345
+ "transformOrigin",
1346
+ "verticalAlign",
1347
+ "width",
1348
+ "writingDirection",
1349
+ "zIndex"
1350
+ ]);
1351
+ var controlProps = /* @__PURE__ */ new Set([
1352
+ "children",
1353
+ "style",
1354
+ "css",
1355
+ "media",
1356
+ "on",
1357
+ "onPress",
1358
+ "onClick",
1359
+ "className",
1360
+ "as",
1361
+ "animate",
1362
+ "animateIn",
1363
+ "animateOut",
1364
+ "animateOn",
1365
+ "blend",
1366
+ "before",
1367
+ "after",
1368
+ "theme",
1369
+ "widthHeight",
1370
+ "shadow"
1371
+ ]);
1372
+ var webOnlyProps = /* @__PURE__ */ new Set([
1373
+ "_hover",
1374
+ "_active",
1375
+ "_focus",
1376
+ "_visited",
1377
+ "_disabled",
1378
+ "_enabled",
1379
+ "_checked",
1380
+ "_unchecked",
1381
+ "_invalid",
1382
+ "_valid",
1383
+ "_required",
1384
+ "_optional",
1385
+ "_selected",
1386
+ "_target",
1387
+ "_firstChild",
1388
+ "_lastChild",
1389
+ "_onlyChild",
1390
+ "_firstOfType",
1391
+ "_lastOfType",
1392
+ "_empty",
1393
+ "_focusVisible",
1394
+ "_focusWithin",
1395
+ "_placeholder",
1396
+ "_groupHover",
1397
+ "_groupFocus",
1398
+ "_groupActive",
1399
+ "_groupDisabled",
1400
+ "_peerHover",
1401
+ "_peerFocus",
1402
+ "_peerActive",
1403
+ "_peerDisabled",
1404
+ "_peerChecked",
1405
+ "_before",
1406
+ "_after",
1407
+ "_firstLetter",
1408
+ "_firstLine",
1409
+ "_selection",
1410
+ "_backdrop",
1411
+ "_marker"
1412
+ ]);
1413
+ function isColorStyle(property) {
1414
+ return property === "color" || property.toLowerCase().includes("color");
1415
+ }
1416
+ function normalizeValue(property, value, getColor) {
1417
+ if (typeof value === "string" && isColorStyle(property)) {
1418
+ return getColor(value);
1419
+ }
1420
+ return value;
1421
+ }
1422
+ function applyShadow(style, value) {
1423
+ if (!value) return;
1424
+ const opacity = typeof value === "number" ? value : 0.2;
1425
+ style.shadowColor = "#000000";
1426
+ style.shadowOpacity = opacity;
1427
+ style.shadowRadius = 4;
1428
+ style.shadowOffset = { width: 0, height: 1 };
1429
+ style.elevation = Math.max(1, Math.round(opacity * 25));
1430
+ }
1431
+ function appendStyleProps(input, output, getColor) {
1432
+ if (!input) return;
1433
+ Object.keys(input).forEach((property) => {
1434
+ const value = input[property];
1435
+ if (value === void 0 || value === null || value === "") return;
1436
+ if (property === "widthHeight") {
1437
+ output.width = value;
1438
+ output.height = value;
1439
+ return;
1440
+ }
1441
+ if (property === "shadow") {
1442
+ applyShadow(output, value);
1443
+ return;
1444
+ }
1445
+ if (stylePropNames.has(property)) {
1446
+ output[property] = normalizeValue(property, value, getColor);
1447
+ }
1448
+ });
1449
+ }
1450
+ function matchesMedia(target, width, breakpoints, devices) {
1451
+ const ordered = Object.entries(breakpoints).sort(([, a], [, b]) => b - a);
1452
+ const breakpoint = ordered.find(([, min]) => width >= min)?.[0] || "xs";
1453
+ if (target === breakpoint) return true;
1454
+ if (devices[target]?.includes(breakpoint)) return true;
1455
+ return false;
1456
+ }
1457
+ function splitNativeProps(props) {
1458
+ const nativeProps = {};
1459
+ Object.keys(props).forEach((key) => {
1460
+ if (controlProps.has(key) || stylePropNames.has(key) || webOnlyProps.has(key)) {
1461
+ return;
1462
+ }
1463
+ if (key === "data-testid") {
1464
+ nativeProps.testID = props[key];
1465
+ return;
1466
+ }
1467
+ if (key === "aria-label") {
1468
+ nativeProps.accessibilityLabel = props[key];
1469
+ return;
1470
+ }
1471
+ nativeProps[key] = props[key];
1472
+ });
1473
+ return nativeProps;
1474
+ }
1475
+ function useNativeStyle(props) {
1476
+ const { getColor, theme } = useTheme();
1477
+ const responsive = useResponsiveContext();
1478
+ const dimensions = (0, import_react_native2.useWindowDimensions)();
1479
+ const scopedGetColor = (0, import_react3.useMemo)(() => {
1480
+ if (!props.theme) return getColor;
1481
+ return (token) => {
1482
+ if (!token.startsWith("theme-")) return getColor(token);
1483
+ const themeKey = token.slice("theme-".length).split("-")[0];
1484
+ const override = props.theme?.[themeKey];
1485
+ return override ? getColor(override) : getColor(token);
1486
+ };
1487
+ }, [getColor, props.theme]);
1488
+ const style = (0, import_react3.useMemo)(() => {
1489
+ const next = {};
1490
+ appendStyleProps(props, next, scopedGetColor);
1491
+ if (props.media) {
1492
+ Object.keys(props.media).forEach((target) => {
1493
+ if (matchesMedia(
1494
+ target,
1495
+ dimensions.width || responsive.currentWidth,
1496
+ responsive.breakpoints,
1497
+ responsive.devices
1498
+ )) {
1499
+ appendStyleProps(props.media?.[target], next, scopedGetColor);
1500
+ }
1501
+ });
1502
+ }
1503
+ if (props.css && typeof props.css === "object") {
1504
+ appendStyleProps(props.css, next, scopedGetColor);
1505
+ }
1506
+ const flattened = import_react_native2.StyleSheet.flatten(props.style) || {};
1507
+ return { ...next, ...flattened };
1508
+ }, [
1509
+ props,
1510
+ scopedGetColor,
1511
+ dimensions.width,
1512
+ responsive.currentWidth,
1513
+ responsive.breakpoints,
1514
+ responsive.devices,
1515
+ theme
1516
+ ]);
1517
+ return style;
1518
+ }
1519
+
1520
+ // src/native/components.tsx
1521
+ function renderChildren(children, textProps) {
1522
+ if (!textProps?.toUpperCase) return children;
1523
+ return import_react4.default.Children.map(
1524
+ children,
1525
+ (child) => typeof child === "string" ? child.toUpperCase() : child
1526
+ );
1527
+ }
1528
+ function sourceFromProps({ source, src }) {
1529
+ if (source) return source;
1530
+ if (src) return { uri: src };
1531
+ return void 0;
1532
+ }
1533
+ var Element = import_react4.default.forwardRef((props, ref) => {
1534
+ const style = useNativeStyle(props);
1535
+ const nativeProps = splitNativeProps(props);
1536
+ const onPress = props.onPress || props.onClick;
1537
+ const Component = onPress ? import_react_native3.Pressable : import_react_native3.View;
1538
+ return /* @__PURE__ */ import_react4.default.createElement(Component, { ...nativeProps, ref, onPress, style }, props.before, props.children, props.after);
1539
+ });
1540
+ Element.displayName = "Element";
1541
+ var View = import_react4.default.forwardRef((props, ref) => /* @__PURE__ */ import_react4.default.createElement(Element, { ...props, ref }));
1542
+ View.displayName = "View";
1543
+ var Horizontal = import_react4.default.forwardRef((props, ref) => /* @__PURE__ */ import_react4.default.createElement(Element, { flexDirection: "row", ...props, ref }));
1544
+ Horizontal.displayName = "Horizontal";
1545
+ var Vertical = import_react4.default.forwardRef((props, ref) => /* @__PURE__ */ import_react4.default.createElement(Element, { flexDirection: "column", ...props, ref }));
1546
+ Vertical.displayName = "Vertical";
1547
+ var Center = import_react4.default.forwardRef((props, ref) => /* @__PURE__ */ import_react4.default.createElement(Element, { justifyContent: "center", alignItems: "center", ...props, ref }));
1548
+ Center.displayName = "Center";
1549
+ var HorizontalResponsive = import_react4.default.forwardRef(
1550
+ ({ media = {}, ...props }, ref) => /* @__PURE__ */ import_react4.default.createElement(
1551
+ Horizontal,
1552
+ {
1553
+ media: {
1554
+ ...media,
1555
+ mobile: {
1556
+ ...media.mobile,
1557
+ flexDirection: "column"
1558
+ }
1559
+ },
1560
+ ...props,
1561
+ ref
1562
+ }
1563
+ )
1564
+ );
1565
+ HorizontalResponsive.displayName = "HorizontalResponsive";
1566
+ var VerticalResponsive = import_react4.default.forwardRef(
1567
+ ({ media = {}, ...props }, ref) => /* @__PURE__ */ import_react4.default.createElement(
1568
+ Vertical,
1569
+ {
1570
+ media: {
1571
+ ...media,
1572
+ mobile: {
1573
+ ...media.mobile,
1574
+ flexDirection: "row"
1575
+ }
1576
+ },
1577
+ ...props,
1578
+ ref
1579
+ }
1580
+ )
1581
+ );
1582
+ VerticalResponsive.displayName = "VerticalResponsive";
1583
+ var Scroll = import_react4.default.forwardRef((props, ref) => {
1584
+ const style = useNativeStyle(props);
1585
+ const nativeProps = splitNativeProps(props);
1586
+ return /* @__PURE__ */ import_react4.default.createElement(import_react_native3.ScrollView, { ...nativeProps, ref, style }, props.children);
1587
+ });
1588
+ Scroll.displayName = "Scroll";
1589
+ var SafeArea = import_react4.default.forwardRef((props, ref) => {
1590
+ const style = useNativeStyle(props);
1591
+ const nativeProps = splitNativeProps(props);
1592
+ return /* @__PURE__ */ import_react4.default.createElement(import_react_native3.SafeAreaView, { ...nativeProps, ref, style }, props.children);
1593
+ });
1594
+ SafeArea.displayName = "SafeArea";
1595
+ var Div = View;
1596
+ var Span = View;
1597
+ var Text = import_react4.default.forwardRef(
1598
+ ({
1599
+ children,
1600
+ toUpperCase,
1601
+ isItalic,
1602
+ isStriked,
1603
+ isUnderlined,
1604
+ isSub,
1605
+ isSup,
1606
+ maxLines,
1607
+ ...props
1608
+ }, ref) => {
1609
+ const style = useNativeStyle({
1610
+ ...props,
1611
+ fontStyle: isItalic ? "italic" : props.fontStyle,
1612
+ textDecorationLine: isStriked ? "line-through" : isUnderlined ? "underline" : props.textDecorationLine,
1613
+ fontSize: isSub || isSup ? props.fontSize || 12 : props.fontSize
1614
+ });
1615
+ const nativeProps = splitNativeProps(props);
1616
+ return /* @__PURE__ */ import_react4.default.createElement(import_react_native3.Text, { ...nativeProps, ref, numberOfLines: maxLines, style }, renderChildren(children, { toUpperCase }));
1617
+ }
1618
+ );
1619
+ Text.displayName = "Text";
1620
+ var Image = import_react4.default.forwardRef((props, ref) => {
1621
+ const style = useNativeStyle(props);
1622
+ const nativeProps = splitNativeProps(props);
1623
+ return /* @__PURE__ */ import_react4.default.createElement(
1624
+ import_react_native3.Image,
1625
+ {
1626
+ ...nativeProps,
1627
+ ref,
1628
+ source: sourceFromProps(props),
1629
+ accessibilityLabel: props.alt || nativeProps.accessibilityLabel,
1630
+ style
1631
+ }
1632
+ );
1633
+ });
1634
+ Image.displayName = "Image";
1635
+ var ImageBackground = import_react4.default.forwardRef(
1636
+ (props, ref) => {
1637
+ const style = useNativeStyle(props);
1638
+ const nativeProps = splitNativeProps(props);
1639
+ return /* @__PURE__ */ import_react4.default.createElement(
1640
+ import_react_native3.ImageBackground,
1641
+ {
1642
+ ...nativeProps,
1643
+ ref,
1644
+ source: sourceFromProps(props),
1645
+ accessibilityLabel: props.alt || nativeProps.accessibilityLabel,
1646
+ style
1647
+ },
1648
+ props.children
1649
+ );
1650
+ }
1651
+ );
1652
+ ImageBackground.displayName = "ImageBackground";
1653
+ var Form = View;
1654
+ var Input = import_react4.default.forwardRef((props, ref) => {
1655
+ const style = useNativeStyle(props);
1656
+ const nativeProps = splitNativeProps(props);
1657
+ return /* @__PURE__ */ import_react4.default.createElement(import_react_native3.TextInput, { ...nativeProps, ref, style });
1658
+ });
1659
+ Input.displayName = "Input";
1660
+ var Button = import_react4.default.forwardRef(
1661
+ ({ children, disabled, ...props }, ref) => {
1662
+ const style = useNativeStyle(props);
1663
+ const nativeProps = splitNativeProps(props);
1664
+ const onPress = disabled ? void 0 : props.onPress || props.onClick;
1665
+ return /* @__PURE__ */ import_react4.default.createElement(
1666
+ import_react_native3.Pressable,
1667
+ {
1668
+ ...nativeProps,
1669
+ ref,
1670
+ accessibilityRole: "button",
1671
+ disabled,
1672
+ onPress,
1673
+ style
1674
+ },
1675
+ typeof children === "string" || typeof children === "number" ? /* @__PURE__ */ import_react4.default.createElement(import_react_native3.Text, null, children) : children
1676
+ );
1677
+ }
1678
+ );
1679
+ Button.displayName = "Button";
1680
+ var Skeleton = import_react4.default.forwardRef(
1681
+ ({ backgroundColor = "color-gray-200", ...props }, ref) => /* @__PURE__ */ import_react4.default.createElement(
1682
+ View,
1683
+ {
1684
+ accessibilityRole: "progressbar",
1685
+ backgroundColor,
1686
+ ...props,
1687
+ ref
1688
+ }
1689
+ )
1690
+ );
1691
+ Skeleton.displayName = "Skeleton";
1692
+
1693
+ // src/native/providers/WindowSize.tsx
1694
+ var import_react5 = __toESM(require("react"));
1695
+ var import_react_native4 = require("react-native");
1696
+ var WindowSizeContext = (0, import_react5.createContext)({ width: 0, height: 0 });
1697
+ var WindowSizeProvider = ({ children }) => {
1698
+ const { width, height } = (0, import_react_native4.useWindowDimensions)();
1699
+ return /* @__PURE__ */ import_react5.default.createElement(WindowSizeContext.Provider, { value: { width, height } }, children);
1700
+ };
1701
+
1702
+ // src/native/providers/StyleRegistry.tsx
1703
+ var import_react6 = __toESM(require("react"));
1704
+ var useStyleRegistry = () => ({ manager: void 0 });
1705
+ var StyleRegistry = ({ children }) => /* @__PURE__ */ import_react6.default.createElement(import_react6.default.Fragment, null, children);
1706
+ var createStyleRegistry = () => void 0;
1707
+ var useServerInsertedHTML = () => () => null;
1708
+
1709
+ // src/providers/Analytics.tsx
1710
+ var import_react7 = __toESM(require("react"));
1711
+ var AnalyticsContext = (0, import_react7.createContext)({});
1712
+ var useAnalytics = () => (0, import_react7.useContext)(AnalyticsContext);
1713
+ var AnalyticsProvider = ({
1714
+ trackEvent,
1715
+ children
1716
+ }) => {
1717
+ const value = (0, import_react7.useMemo)(() => ({ trackEvent }), [trackEvent]);
1718
+ return /* @__PURE__ */ import_react7.default.createElement(AnalyticsContext.Provider, { value }, children);
1719
+ };
1720
+
1721
+ // src/native/hooks.ts
1722
+ var import_react8 = require("react");
1723
+ var useWindowSize = () => (0, import_react8.useContext)(WindowSizeContext);
1724
+ var useBreakpoint = () => {
1725
+ const context = useBreakpointContext();
1726
+ const { currentBreakpoint: screen, devices, orientation } = context;
1727
+ const on = (0, import_react8.useCallback)(
1728
+ (target) => devices[target] ? devices[target].includes(screen) : target === screen,
1729
+ [devices, screen]
1730
+ );
1731
+ return (0, import_react8.useMemo)(
1732
+ () => ({ ...context, screen, orientation, on, is: on }),
1733
+ [context, screen, orientation, on]
1734
+ );
1735
+ };
1736
+ var useWindowDimensions2 = () => useWindowDimensionsContext();
1737
+ var useResponsive = () => {
1738
+ const context = useResponsiveContext();
1739
+ const { currentBreakpoint: screen, devices, orientation } = context;
1740
+ const on = (0, import_react8.useCallback)(
1741
+ (target) => devices[target] ? devices[target].includes(screen) : target === screen,
1742
+ [devices, screen]
1743
+ );
1744
+ return (0, import_react8.useMemo)(
1745
+ () => ({ ...context, screen, orientation, on, is: on }),
1746
+ [context, screen, orientation, on]
1747
+ );
1748
+ };
1749
+ var useMount = (callback) => {
1750
+ (0, import_react8.useEffect)(() => {
1751
+ callback();
1752
+ }, [callback]);
1753
+ };
1754
+ var useHover = () => {
1755
+ const [isHovered] = (0, import_react8.useState)(false);
1756
+ return { isHovered, hoverProps: {} };
1757
+ };
1758
+ var useActive = () => {
1759
+ const [isActive] = (0, import_react8.useState)(false);
1760
+ return { isActive, activeProps: {} };
1761
+ };
1762
+ var useFocus = () => {
1763
+ const [isFocused] = (0, import_react8.useState)(false);
1764
+ return { isFocused, focusProps: {} };
1765
+ };
1766
+ var useClickOutside = () => ({ ref: (0, import_react8.useRef)(null), isOutside: false });
1767
+ var useElementPosition = () => ({ ref: (0, import_react8.useRef)(null), position: null });
1768
+ var useKeyPress = () => false;
1769
+ var useOnScreen = () => ({ ref: (0, import_react8.useRef)(null), isOnScreen: true });
1770
+ var useInView = () => ({ ref: (0, import_react8.useRef)(null), inView: true });
1771
+ var useIframeStyles = () => ({ iframeRef: (0, import_react8.useRef)(null) });
1772
+ var useScroll = () => ({
1773
+ scrollY: 0,
1774
+ scrollX: 0,
1775
+ scrollDirection: null,
1776
+ scrollTo: () => {
1777
+ },
1778
+ scrollToTop: () => {
1779
+ },
1780
+ scrollToBottom: () => {
1781
+ }
1782
+ });
1783
+
1784
+ // src/element/Animation.tsx
1785
+ var Animation_exports = {};
1786
+ __export(Animation_exports, {
1787
+ backInDown: () => backInDown,
1788
+ backOutUp: () => backOutUp,
1789
+ blinkCursor: () => blinkCursor,
1790
+ bounce: () => bounce,
1791
+ bounceIn: () => bounceIn,
1792
+ bounceOut: () => bounceOut,
1793
+ ctaCollapseScroll: () => ctaCollapseScroll,
1794
+ fadeBlurScroll: () => fadeBlurScroll,
1795
+ fadeIn: () => fadeIn,
1796
+ fadeInDown: () => fadeInDown,
1797
+ fadeInScroll: () => fadeInScroll,
1798
+ fadeInUp: () => fadeInUp,
1799
+ fadeOut: () => fadeOut,
1800
+ fillTextScroll: () => fillTextScroll,
1801
+ flash: () => flash,
1802
+ flip: () => flip,
1803
+ flipInX: () => flipInX,
1804
+ flipInY: () => flipInY,
1805
+ handWaveScroll: () => handWaveScroll,
1806
+ headShake: () => headShake,
1807
+ heartBeat: () => heartBeat,
1808
+ hinge: () => hinge,
1809
+ jackInTheBox: () => jackInTheBox,
1810
+ jello: () => jello,
1811
+ lightSpeedIn: () => lightSpeedIn,
1812
+ lightSpeedOut: () => lightSpeedOut,
1813
+ listItemScaleScroll: () => listItemScaleScroll,
1814
+ progress: () => progress,
1815
+ pulse: () => pulse,
1816
+ rollIn: () => rollIn,
1817
+ rollOut: () => rollOut,
1818
+ rotate: () => rotate,
1819
+ rubberBand: () => rubberBand,
1820
+ scale: () => scale,
1821
+ scaleDownArticleScroll: () => scaleDownArticleScroll,
1822
+ scaleDownScroll: () => scaleDownScroll,
1823
+ shake: () => shake,
1824
+ shimmer: () => shimmer,
1825
+ slideInDown: () => slideInDown,
1826
+ slideInLeft: () => slideInLeft,
1827
+ slideInLeftScroll: () => slideInLeftScroll,
1828
+ slideInRight: () => slideInRight,
1829
+ slideInUp: () => slideInUp,
1830
+ slideOutLeft: () => slideOutLeft,
1831
+ slideOutRight: () => slideOutRight,
1832
+ swing: () => swing,
1833
+ tada: () => tada,
1834
+ typewriter: () => typewriter,
1835
+ unclipScroll: () => unclipScroll,
1836
+ wobble: () => wobble,
1837
+ zoomIn: () => zoomIn,
1838
+ zoomInDown: () => zoomInDown,
1839
+ zoomOut: () => zoomOut,
1840
+ zoomOutUp: () => zoomOutUp
1841
+ });
1842
+ var fadeIn = ({ duration = "1s", timingFunction = "ease", ...props } = {
1843
+ duration: "1s",
1844
+ timingFunction: "ease"
1845
+ }) => ({
1846
+ from: { opacity: 0 },
1847
+ to: { opacity: 1 },
1848
+ duration,
1849
+ timingFunction,
1850
+ ...props
1851
+ });
1852
+ var fadeOut = ({ duration = "1s", timingFunction = "ease", ...props } = {
1853
+ duration: "1s",
1854
+ timingFunction: "ease"
1855
+ }) => ({
1856
+ from: { opacity: 1 },
1857
+ to: { opacity: 0 },
1858
+ duration,
1859
+ timingFunction,
1860
+ ...props
1861
+ });
1862
+ var slideInLeft = ({
1863
+ duration = "0.5s",
1864
+ timingFunction = "ease-out",
1865
+ ...props
1866
+ } = {
1867
+ duration: "0.5s",
1868
+ timingFunction: "ease-out"
1869
+ }) => ({
1870
+ from: { transform: "translateX(-100%)" },
1871
+ to: { transform: "translateX(0)" },
1872
+ duration,
1873
+ timingFunction,
1874
+ ...props
1875
+ });
1876
+ var slideInRight = ({
1877
+ duration = "0.5s",
1878
+ timingFunction = "ease-out",
1879
+ ...props
1880
+ } = {
1881
+ duration: "0.5s",
1882
+ timingFunction: "ease-out"
1883
+ }) => ({
1884
+ from: { transform: "translateX(100%)" },
1885
+ to: { transform: "translateX(0)" },
1886
+ duration,
1887
+ timingFunction,
1888
+ ...props
1889
+ });
1890
+ var slideInDown = ({
1891
+ duration = "0.5s",
1892
+ timingFunction = "ease-out",
1893
+ ...props
1894
+ } = {
1895
+ duration: "0.5s",
1896
+ timingFunction: "ease-out"
1897
+ }) => ({
1898
+ from: { transform: "translateY(-100%)" },
1899
+ to: { transform: "translateY(0)" },
1900
+ duration,
1901
+ timingFunction,
1902
+ ...props
1903
+ });
1904
+ var slideInUp = ({
1905
+ duration = "0.5s",
1906
+ timingFunction = "ease-out",
1907
+ ...props
1908
+ } = {
1909
+ duration: "0.5s",
1910
+ timingFunction: "ease-out"
1911
+ }) => ({
1912
+ from: { transform: "translateY(100%)" },
1913
+ to: { transform: "translateY(0)" },
1914
+ duration,
1915
+ timingFunction,
1916
+ ...props
1917
+ });
1918
+ var bounce = ({
1919
+ duration = "2s",
1920
+ timingFunction = "ease",
1921
+ iterationCount = "infinite",
1922
+ ...props
1923
+ } = {
1924
+ duration: "2s",
1925
+ timingFunction: "ease",
1926
+ iterationCount: "infinite"
1927
+ }) => ({
1928
+ from: { transform: "translateY(0)" },
1929
+ "20%": { transform: "translateY(-30px)" },
1930
+ "40%": { transform: "translateY(0)" },
1931
+ "60%": { transform: "translateY(-15px)" },
1932
+ "80%": { transform: "translateY(0)" },
1933
+ to: { transform: "translateY(0)" },
1934
+ duration,
1935
+ timingFunction,
1936
+ iterationCount,
1937
+ ...props
1938
+ });
1939
+ var rotate = ({
1940
+ duration = "1s",
1941
+ timingFunction = "linear",
1942
+ iterationCount = "infinite",
1943
+ ...props
1944
+ } = {
1945
+ duration: "1s",
1946
+ timingFunction: "linear",
1947
+ iterationCount: "infinite"
1948
+ }) => ({
1949
+ from: { transform: "rotate(0deg)" },
1950
+ to: { transform: "rotate(360deg)" },
1951
+ duration,
1952
+ timingFunction,
1953
+ iterationCount,
1954
+ ...props
1955
+ });
1956
+ var pulse = ({
1957
+ duration = "1s",
1958
+ timingFunction = "ease-in-out",
1959
+ iterationCount = "infinite",
1960
+ ...props
1961
+ } = {
1962
+ duration: "1s",
1963
+ timingFunction: "ease-in-out",
1964
+ iterationCount: "infinite"
1965
+ }) => ({
1966
+ from: { transform: "scale(1)" },
1967
+ "50%": { transform: "scale(1.05)" },
1968
+ to: { transform: "scale(1)" },
1969
+ duration,
1970
+ timingFunction,
1971
+ iterationCount,
1972
+ ...props
1973
+ });
1974
+ var zoomIn = ({
1975
+ duration = "0.5s",
1976
+ timingFunction = "ease-out",
1977
+ ...props
1978
+ } = {
1979
+ duration: "0.5s",
1980
+ timingFunction: "ease-out"
1981
+ }) => ({
1982
+ from: { transform: "scale(0)" },
1983
+ to: { transform: "scale(1)" },
1984
+ duration,
1985
+ timingFunction,
1986
+ ...props
1987
+ });
1988
+ var zoomOut = ({
1989
+ duration = "0.5s",
1990
+ timingFunction = "ease-out",
1991
+ ...props
1992
+ } = {
1993
+ duration: "0.5s",
1994
+ timingFunction: "ease-out"
1995
+ }) => ({
1996
+ from: { transform: "scale(1)" },
1997
+ to: { transform: "scale(0)" },
1998
+ duration,
1999
+ timingFunction,
2000
+ ...props
2001
+ });
2002
+ var flash = ({ duration = "1s", iterationCount = "infinite", ...props } = {
2003
+ duration: "1s",
2004
+ iterationCount: "infinite"
2005
+ }) => ({
2006
+ from: { opacity: 1 },
2007
+ "50%": { opacity: 0 },
2008
+ to: { opacity: 1 },
2009
+ duration,
2010
+ iterationCount,
2011
+ ...props
2012
+ });
2013
+ var scale = ({
2014
+ duration = "1s",
2015
+ timingFunction = "ease-in-out",
2016
+ iterationCount = "infinite",
2017
+ ...props
2018
+ } = {
2019
+ duration: "1s",
2020
+ timingFunction: "ease-in-out",
2021
+ iterationCount: "infinite"
2022
+ }) => ({
2023
+ from: { transform: "scale(1)" },
2024
+ "50%": { transform: "scale(1.05)" },
2025
+ to: { transform: "scale(1)" },
2026
+ duration,
2027
+ timingFunction,
2028
+ iterationCount,
2029
+ ...props
2030
+ });
2031
+ var shake = ({
2032
+ duration = "0.5s",
2033
+ iterationCount = "infinite",
2034
+ ...props
2035
+ } = {
2036
+ duration: "0.5s",
2037
+ iterationCount: "infinite"
2038
+ }) => ({
2039
+ from: { transform: "translateX(0)" },
2040
+ "10%": { transform: "translateX(-10px)" },
2041
+ "20%": { transform: "translateX(10px)" },
2042
+ "30%": { transform: "translateX(-10px)" },
2043
+ "40%": { transform: "translateX(10px)" },
2044
+ "50%": { transform: "translateX(-10px)" },
2045
+ "60%": { transform: "translateX(10px)" },
2046
+ "70%": { transform: "translateX(-10px)" },
2047
+ "80%": { transform: "translateX(10px)" },
2048
+ "90%": { transform: "translateX(-10px)" },
2049
+ to: { transform: "translateX(0)" },
2050
+ duration,
2051
+ iterationCount,
2052
+ ...props
2053
+ });
2054
+ var swing = ({ duration = "1s", iterationCount = "infinite", ...props } = {
2055
+ duration: "1s",
2056
+ iterationCount: "infinite"
2057
+ }) => ({
2058
+ from: { transform: "rotate(0deg)" },
2059
+ "20%": { transform: "rotate(15deg)" },
2060
+ "40%": { transform: "rotate(-10deg)" },
2061
+ "60%": { transform: "rotate(5deg)" },
2062
+ "80%": { transform: "rotate(-5deg)" },
2063
+ to: { transform: "rotate(0deg)" },
2064
+ duration,
2065
+ iterationCount,
2066
+ ...props
2067
+ });
2068
+ var rubberBand = ({
2069
+ duration = "1s",
2070
+ timingFunction = "ease-in-out",
2071
+ ...props
2072
+ } = {
2073
+ duration: "1s",
2074
+ timingFunction: "ease-in-out"
2075
+ }) => ({
2076
+ from: { transform: "scale3d(1, 1, 1)" },
2077
+ "30%": { transform: "scale3d(1.25, 0.75, 1)" },
2078
+ "40%": { transform: "scale3d(0.75, 1.25, 1)" },
2079
+ "50%": { transform: "scale3d(1.15, 0.85, 1)" },
2080
+ "65%": { transform: "scale3d(0.95, 1.05, 1)" },
2081
+ "75%": { transform: "scale3d(1.05, 0.95, 1)" },
2082
+ to: { transform: "scale3d(1, 1, 1)" },
2083
+ duration,
2084
+ timingFunction,
2085
+ ...props
2086
+ });
2087
+ var wobble = ({ duration = "1s", ...props } = {
2088
+ duration: "1s"
2089
+ }) => ({
2090
+ from: { transform: "translateX(0%)" },
2091
+ "15%": { transform: "translateX(-25%) rotate(-5deg)" },
2092
+ "30%": { transform: "translateX(20%) rotate(3deg)" },
2093
+ "45%": { transform: "translateX(-15%) rotate(-3deg)" },
2094
+ "60%": { transform: "translateX(10%) rotate(2deg)" },
2095
+ "75%": { transform: "translateX(-5%) rotate(-1deg)" },
2096
+ to: { transform: "translateX(0%)" },
2097
+ duration,
2098
+ ...props
2099
+ });
2100
+ var flip = ({ duration = "1s", ...props } = {
2101
+ duration: "1s"
2102
+ }) => ({
2103
+ from: {
2104
+ transform: "perspective(400px) rotateY(0deg)"
2105
+ },
2106
+ "40%": {
2107
+ transform: "perspective(400px) rotateY(-180deg)"
2108
+ },
2109
+ to: {
2110
+ transform: "perspective(400px) rotateY(-360deg)"
2111
+ },
2112
+ duration,
2113
+ ...props
2114
+ });
2115
+ var heartBeat = ({
2116
+ duration = "1.3s",
2117
+ iterationCount = "infinite",
2118
+ ...props
2119
+ } = {
2120
+ duration: "1.3s",
2121
+ iterationCount: "infinite"
2122
+ }) => ({
2123
+ from: { transform: "scale(1)" },
2124
+ "14%": { transform: "scale(1.3)" },
2125
+ "28%": { transform: "scale(1)" },
2126
+ "42%": { transform: "scale(1.3)" },
2127
+ "70%": { transform: "scale(1)" },
2128
+ to: { transform: "scale(1)" },
2129
+ duration,
2130
+ iterationCount,
2131
+ ...props
2132
+ });
2133
+ var rollIn = ({ duration = "1s", ...props } = {
2134
+ duration: "1s"
2135
+ }) => ({
2136
+ from: {
2137
+ opacity: 0,
2138
+ transform: "translateX(-100%) rotate(-120deg)"
2139
+ },
2140
+ to: {
2141
+ opacity: 1,
2142
+ transform: "translateX(0px) rotate(0deg)"
2143
+ },
2144
+ duration,
2145
+ ...props
2146
+ });
2147
+ var rollOut = ({ duration = "1s", ...props } = {
2148
+ duration: "1s"
2149
+ }) => ({
2150
+ from: {
2151
+ opacity: 1,
2152
+ transform: "translateX(0px) rotate(0deg)"
2153
+ },
2154
+ to: {
2155
+ opacity: 0,
2156
+ transform: "translateX(100%) rotate(120deg)"
2157
+ },
2158
+ duration,
2159
+ ...props
2160
+ });
2161
+ var lightSpeedIn = ({ duration = "1s", timingFunction = "ease-out", ...props } = {
2162
+ duration: "1s",
2163
+ timingFunction: "ease-out"
2164
+ }) => ({
2165
+ from: {
2166
+ transform: "translateX(100%) skewX(-30deg)",
2167
+ opacity: 0
2168
+ },
2169
+ "60%": {
2170
+ transform: "skewX(20deg)",
2171
+ opacity: 1
2172
+ },
2173
+ "80%": {
2174
+ transform: "skewX(-5deg)"
2175
+ },
2176
+ to: {
2177
+ transform: "translateX(0)",
2178
+ opacity: 1
2179
+ },
2180
+ duration,
2181
+ timingFunction,
2182
+ ...props
2183
+ });
2184
+ var lightSpeedOut = ({ duration = "1s", timingFunction = "ease-in", ...props } = {
2185
+ duration: "1s",
2186
+ timingFunction: "ease-in"
2187
+ }) => ({
2188
+ from: {
2189
+ opacity: 1
2190
+ },
2191
+ "20%": {
2192
+ opacity: 1,
2193
+ transform: "translateX(-20%) skewX(20deg)"
2194
+ },
2195
+ to: {
2196
+ opacity: 0,
2197
+ transform: "translateX(-100%) skewX(30deg)"
2198
+ },
2199
+ duration,
2200
+ timingFunction,
2201
+ ...props
2202
+ });
2203
+ var hinge = ({
2204
+ duration = "2s",
2205
+ timingFunction = "ease-in-out",
2206
+ ...props
2207
+ } = {
2208
+ duration: "2s",
2209
+ timingFunction: "ease-in-out"
2210
+ }) => ({
2211
+ from: {
2212
+ transform: "rotate(0deg)",
2213
+ transformOrigin: "top left",
2214
+ opacity: 1
2215
+ },
2216
+ "20%": {
2217
+ transform: "rotate(80deg)",
2218
+ opacity: 1
2219
+ },
2220
+ "40%": {
2221
+ transform: "rotate(60deg)",
2222
+ opacity: 1
2223
+ },
2224
+ "60%": {
2225
+ transform: "rotate(80deg)",
2226
+ opacity: 1
2227
+ },
2228
+ "80%": {
2229
+ transform: "rotate(60deg)",
2230
+ opacity: 1
2231
+ },
2232
+ to: {
2233
+ transform: "translateY(700px)",
2234
+ opacity: 0
2235
+ },
2236
+ duration,
2237
+ timingFunction,
2238
+ ...props
2239
+ });
2240
+ var jackInTheBox = ({ duration = "1s", timingFunction = "ease", ...props } = {
2241
+ duration: "1s",
2242
+ timingFunction: "ease"
2243
+ }) => ({
2244
+ from: {
2245
+ opacity: 0,
2246
+ transform: "scale(0.1) rotate(30deg)",
2247
+ transformOrigin: "center bottom"
2248
+ },
2249
+ "50%": {
2250
+ transform: "rotate(-10deg)"
2251
+ },
2252
+ "70%": {
2253
+ transform: "rotate(3deg)"
2254
+ },
2255
+ to: {
2256
+ opacity: 1,
2257
+ transform: "scale(1) rotate(0deg)"
2258
+ },
2259
+ duration,
2260
+ timingFunction,
2261
+ ...props
2262
+ });
2263
+ var flipInX = ({ duration = "1s", timingFunction = "ease-in", ...props } = {
2264
+ duration: "1s",
2265
+ timingFunction: "ease-in"
2266
+ }) => ({
2267
+ from: {
2268
+ transform: "perspective(400px) rotateX(90deg)",
2269
+ opacity: 0
2270
+ },
2271
+ "40%": {
2272
+ transform: "perspective(400px) rotateX(-10deg)",
2273
+ opacity: 1
2274
+ },
2275
+ to: {
2276
+ transform: "perspective(400px) rotateX(0deg)"
2277
+ },
2278
+ duration,
2279
+ timingFunction,
2280
+ ...props
2281
+ });
2282
+ var flipInY = ({ duration = "1s", timingFunction = "ease-in", ...props } = {
2283
+ duration: "1s",
2284
+ timingFunction: "ease-in"
2285
+ }) => ({
2286
+ from: {
2287
+ transform: "perspective(400px) rotateY(90deg)",
2288
+ opacity: 0
2289
+ },
2290
+ "40%": {
2291
+ transform: "perspective(400px) rotateY(-10deg)",
2292
+ opacity: 1
2293
+ },
2294
+ to: {
2295
+ transform: "perspective(400px) rotateY(0deg)"
2296
+ },
2297
+ duration,
2298
+ timingFunction,
2299
+ ...props
2300
+ });
2301
+ var headShake = ({ duration = "1s", iterationCount = "infinite", ...props } = {
2302
+ duration: "1s",
2303
+ iterationCount: "infinite"
2304
+ }) => ({
2305
+ from: {
2306
+ transform: "translateX(0)"
2307
+ },
2308
+ "6.5%": {
2309
+ transform: "translateX(-6px) rotateY(-9deg)"
2310
+ },
2311
+ "18.5%": {
2312
+ transform: "translateX(5px) rotateY(7deg)"
2313
+ },
2314
+ "31.5%": {
2315
+ transform: "translateX(-3px) rotateY(-5deg)"
2316
+ },
2317
+ "43.5%": {
2318
+ transform: "translateX(2px) rotateY(3deg)"
2319
+ },
2320
+ "50%": {
2321
+ transform: "translateX(0)"
2322
+ },
2323
+ duration,
2324
+ iterationCount,
2325
+ ...props
2326
+ });
2327
+ var tada = ({ duration = "1s", iterationCount = "infinite", ...props } = {
2328
+ duration: "1s",
2329
+ iterationCount: "infinite"
2330
+ }) => ({
2331
+ from: { transform: "scale3d(1, 1, 1)", opacity: 1 },
2332
+ "10%, 20%": {
2333
+ transform: "scale3d(0.9, 0.9, 0.9) rotate(-3deg)"
2334
+ },
2335
+ "30%, 50%, 70%, 90%": {
2336
+ transform: "scale3d(1.1, 1.1, 1.1) rotate(3deg)"
2337
+ },
2338
+ "40%, 60%, 80%": {
2339
+ transform: "scale3d(1.1, 1.1, 1.1) rotate(-3deg)"
2340
+ },
2341
+ to: { transform: "scale3d(1, 1, 1)", opacity: 1 },
2342
+ duration,
2343
+ iterationCount,
2344
+ ...props
2345
+ });
2346
+ var jello = ({ duration = "1s", iterationCount = "infinite", ...props } = {
2347
+ duration: "1s",
2348
+ iterationCount: "infinite"
2349
+ }) => ({
2350
+ from: { transform: "none" },
2351
+ "11.1%": { transform: "skewX(-12.5deg) skewY(-12.5deg)" },
2352
+ "22.2%": { transform: "skewX(6.25deg) skewY(6.25deg)" },
2353
+ "33.3%": { transform: "skewX(-3.125deg) skewY(-3.125deg)" },
2354
+ "44.4%": { transform: "skewX(1.5625deg) skewY(1.5625deg)" },
2355
+ "55.5%": { transform: "skewX(-0.78125deg) skewY(-0.78125deg)" },
2356
+ "66.6%": { transform: "skewX(0.390625deg) skewY(0.390625deg)" },
2357
+ "77.7%": { transform: "skewX(-0.1953125deg) skewY(-0.1953125deg)" },
2358
+ "88.8%": { transform: "skewX(0.09765625deg) skewY(0.09765625deg)" },
2359
+ to: { transform: "none" },
2360
+ duration,
2361
+ iterationCount,
2362
+ ...props
2363
+ });
2364
+ var fadeInDown = ({ duration = "1s", timingFunction = "ease-out", ...props } = {
2365
+ duration: "1s",
2366
+ timingFunction: "ease-out"
2367
+ }) => ({
2368
+ from: {
2369
+ opacity: 0,
2370
+ transform: "translateY(-100%)"
2371
+ },
2372
+ to: {
2373
+ opacity: 1,
2374
+ transform: "translateY(0)"
2375
+ },
2376
+ duration,
2377
+ timingFunction,
2378
+ ...props
2379
+ });
2380
+ var fadeInUp = ({ duration = "1s", timingFunction = "ease-out", ...props } = {
2381
+ duration: "1s",
2382
+ timingFunction: "ease-out"
2383
+ }) => ({
2384
+ from: {
2385
+ opacity: 0,
2386
+ transform: "translateY(100%)"
2387
+ },
2388
+ to: {
2389
+ opacity: 1,
2390
+ transform: "translateY(0)"
2391
+ },
2392
+ duration,
2393
+ timingFunction,
2394
+ ...props
2395
+ });
2396
+ var bounceIn = ({
2397
+ duration = "0.75s",
2398
+ timingFunction = "ease-in",
2399
+ ...props
2400
+ } = {
2401
+ duration: "0.75s",
2402
+ timingFunction: "ease-in"
2403
+ }) => ({
2404
+ from: {
2405
+ opacity: 0,
2406
+ transform: "scale(0.3)"
2407
+ },
2408
+ "50%": {
2409
+ opacity: 1,
2410
+ transform: "scale(1.05)"
2411
+ },
2412
+ "70%": {
2413
+ transform: "scale(0.9)"
2414
+ },
2415
+ to: {
2416
+ transform: "scale(1)"
2417
+ },
2418
+ duration,
2419
+ timingFunction,
2420
+ ...props
2421
+ });
2422
+ var bounceOut = ({
2423
+ duration = "0.75s",
2424
+ timingFunction = "ease-out",
2425
+ ...props
2426
+ } = {
2427
+ duration: "0.75s",
2428
+ timingFunction: "ease-out"
2429
+ }) => ({
2430
+ from: {
2431
+ transform: "scale(1)"
2432
+ },
2433
+ "20%": {
2434
+ transform: "scale(0.9)"
2435
+ },
2436
+ "50%, 55%": {
2437
+ opacity: 1,
2438
+ transform: "scale(1.1)"
2439
+ },
2440
+ to: {
2441
+ opacity: 0,
2442
+ transform: "scale(0.3)"
2443
+ },
2444
+ duration,
2445
+ timingFunction,
2446
+ ...props
2447
+ });
2448
+ var slideOutLeft = ({
2449
+ duration = "0.5s",
2450
+ timingFunction = "ease-in",
2451
+ ...props
2452
+ } = {
2453
+ duration: "0.5s",
2454
+ timingFunction: "ease-in"
2455
+ }) => ({
2456
+ from: {
2457
+ transform: "translateX(0)"
2458
+ },
2459
+ to: {
2460
+ transform: "translateX(-100%)"
2461
+ },
2462
+ duration,
2463
+ timingFunction,
2464
+ ...props
2465
+ });
2466
+ var slideOutRight = ({
2467
+ duration = "0.5s",
2468
+ timingFunction = "ease-in",
2469
+ ...props
2470
+ } = {
2471
+ duration: "0.5s",
2472
+ timingFunction: "ease-in"
2473
+ }) => ({
2474
+ from: {
2475
+ transform: "translateX(0)"
2476
+ },
2477
+ to: {
2478
+ transform: "translateX(100%)"
2479
+ },
2480
+ duration,
2481
+ timingFunction,
2482
+ ...props
2483
+ });
2484
+ var zoomInDown = ({ duration = "1s", timingFunction = "ease-out", ...props } = {
2485
+ duration: "1s",
2486
+ timingFunction: "ease-out"
2487
+ }) => ({
2488
+ from: {
2489
+ opacity: 0,
2490
+ transform: "scale(0.1) translateY(-1000px)"
2491
+ },
2492
+ "60%": {
2493
+ opacity: 1,
2494
+ transform: "scale(0.475) translateY(60px)"
2495
+ },
2496
+ to: {
2497
+ transform: "scale(1) translateY(0)"
2498
+ },
2499
+ duration,
2500
+ timingFunction,
2501
+ ...props
2502
+ });
2503
+ var zoomOutUp = ({ duration = "1s", timingFunction = "ease-in", ...props } = {
2504
+ duration: "1s",
2505
+ timingFunction: "ease-in"
2506
+ }) => ({
2507
+ from: {
2508
+ opacity: 1,
2509
+ transform: "scale(1) translateY(0)"
2510
+ },
2511
+ "40%": {
2512
+ opacity: 1,
2513
+ transform: "scale(0.475) translateY(-60px)"
2514
+ },
2515
+ to: {
2516
+ opacity: 0,
2517
+ transform: "scale(0.1) translateY(-1000px)"
2518
+ },
2519
+ duration,
2520
+ timingFunction,
2521
+ ...props
2522
+ });
2523
+ var backInDown = ({ duration = "1s", timingFunction = "ease-in", ...props } = {
2524
+ duration: "1s",
2525
+ timingFunction: "ease-in"
2526
+ }) => ({
2527
+ from: {
2528
+ opacity: 0.7,
2529
+ transform: "translateY(-2000px) scaleY(2.5) scaleX(0.2)"
2530
+ },
2531
+ to: {
2532
+ opacity: 1,
2533
+ transform: "translateY(0) scaleY(1) scaleX(1)"
2534
+ },
2535
+ duration,
2536
+ timingFunction,
2537
+ ...props
2538
+ });
2539
+ var backOutUp = ({ duration = "1s", timingFunction = "ease-in", ...props } = {
2540
+ duration: "1s",
2541
+ timingFunction: "ease-in"
2542
+ }) => ({
2543
+ from: {
2544
+ opacity: 1,
2545
+ transform: "translateY(0)"
2546
+ },
2547
+ "80%": {
2548
+ opacity: 0.7,
2549
+ transform: "translateY(-20px)"
2550
+ },
2551
+ to: {
2552
+ opacity: 0,
2553
+ transform: "translateY(-2000px)"
2554
+ },
2555
+ duration,
2556
+ timingFunction,
2557
+ ...props
2558
+ });
2559
+ var shimmer = ({
2560
+ duration = "2s",
2561
+ timingFunction = "linear",
2562
+ iterationCount = "infinite",
2563
+ ...props
2564
+ } = {
2565
+ duration: "2s",
2566
+ timingFunction: "linear",
2567
+ iterationCount: "infinite"
2568
+ }) => ({
2569
+ from: { transform: "translateX(-100%)" },
2570
+ "50%": { transform: "translateX(100%)" },
2571
+ to: { transform: "translateX(100%)" },
2572
+ duration,
2573
+ timingFunction,
2574
+ iterationCount,
2575
+ ...props
2576
+ });
2577
+ var progress = ({
2578
+ duration = "2s",
2579
+ timingFunction = "linear",
2580
+ direction = "forwards",
2581
+ from = { width: "0%" },
2582
+ to = { width: "100%" },
2583
+ ...props
2584
+ } = {
2585
+ duration: "2s",
2586
+ timingFunction: "linear",
2587
+ direction: "forwards",
2588
+ from: { width: "0%" },
2589
+ to: { width: "100%" }
2590
+ }) => ({
2591
+ from,
2592
+ to,
2593
+ duration,
2594
+ timingFunction,
2595
+ direction,
2596
+ ...props
2597
+ });
2598
+ var typewriter = ({
2599
+ duration = "10s",
2600
+ steps = 10,
2601
+ iterationCount = 1,
2602
+ width = 0,
2603
+ ...props
2604
+ } = {
2605
+ duration: "10s",
2606
+ steps: 10,
2607
+ iterationCount: 1,
2608
+ width: 0
2609
+ }) => ({
2610
+ from: { width: "0px" },
2611
+ to: { width: `${width}px` },
2612
+ timingFunction: `steps(${steps})`,
2613
+ duration,
2614
+ iterationCount,
2615
+ ...props
2616
+ });
2617
+ var blinkCursor = ({
2618
+ duration = "0.75s",
2619
+ timingFunction = "step-end",
2620
+ iterationCount = "infinite",
2621
+ color = "black",
2622
+ ...props
2623
+ } = {
2624
+ duration: "0.75s",
2625
+ timingFunction: "step-end",
2626
+ iterationCount: "infinite",
2627
+ color: "black"
2628
+ }) => ({
2629
+ from: { color },
2630
+ to: { color },
2631
+ "0%": { color },
2632
+ "50%": { color: "transparent" },
2633
+ "100%": { color },
2634
+ duration,
2635
+ timingFunction,
2636
+ iterationCount,
2637
+ ...props
2638
+ });
2639
+ var fadeInScroll = ({
2640
+ duration = "0.5s",
2641
+ timingFunction = "ease",
2642
+ timeline = "scroll()",
2643
+ range = "cover",
2644
+ ...props
2645
+ } = {
2646
+ duration: "0.5s",
2647
+ timingFunction: "ease",
2648
+ timeline: "scroll()",
2649
+ range: "cover"
2650
+ }) => ({
2651
+ from: { opacity: 0 },
2652
+ to: { opacity: 1 },
2653
+ duration,
2654
+ timingFunction,
2655
+ timeline,
2656
+ range,
2657
+ ...props
2658
+ });
2659
+ var slideInLeftScroll = ({
2660
+ duration = "0.5s",
2661
+ timingFunction = "ease-out",
2662
+ timeline = "scroll()",
2663
+ range = "cover",
2664
+ ...props
2665
+ } = {
2666
+ duration: "0.5s",
2667
+ timingFunction: "ease-out",
2668
+ timeline: "scroll()",
2669
+ range: "cover"
2670
+ }) => ({
2671
+ from: { transform: "translateX(-200%)" },
2672
+ to: { transform: "translateX(0)" },
2673
+ duration,
2674
+ timingFunction,
2675
+ timeline,
2676
+ range,
2677
+ ...props
2678
+ });
2679
+ var scaleDownScroll = ({
2680
+ duration = "0.8s",
2681
+ timingFunction = "ease",
2682
+ timeline = "scroll()",
2683
+ range = "cover",
2684
+ ...props
2685
+ } = {
2686
+ duration: "0.8s",
2687
+ timingFunction: "ease",
2688
+ timeline: "scroll()",
2689
+ range: "cover"
2690
+ }) => ({
2691
+ from: { transform: "scale(3)" },
2692
+ to: { transform: "scale(1)" },
2693
+ duration,
2694
+ timingFunction,
2695
+ timeline,
2696
+ range,
2697
+ ...props
2698
+ });
2699
+ var fillTextScroll = ({
2700
+ duration = "1s",
2701
+ timingFunction = "linear",
2702
+ timeline = "--section",
2703
+ range = "entry 100% cover 50%, cover 50% exit 0%",
2704
+ ...props
2705
+ } = {
2706
+ duration: "1s",
2707
+ timingFunction: "linear",
2708
+ timeline: "--section",
2709
+ range: "entry 100% cover 50%, cover 50% exit 0%"
2710
+ }) => ({
2711
+ from: {
2712
+ "--fill": 0,
2713
+ color: "transparent",
2714
+ backgroundPositionX: "calc(var(--underline-block-width) * -1), calc(var(--underline-block-width) * -1), 0"
2715
+ },
2716
+ "50%": { "--fill": 0.5 },
2717
+ to: {
2718
+ "--fill": 1,
2719
+ backgroundPositionX: "0, 0, 0",
2720
+ color: "var(--finish-fill)"
2721
+ },
2722
+ duration,
2723
+ timingFunction,
2724
+ timeline,
2725
+ range,
2726
+ ...props
2727
+ });
2728
+ var ctaCollapseScroll = ({
2729
+ duration = "1s",
2730
+ timingFunction = "linear",
2731
+ timeline = "scroll()",
2732
+ range = "0 400px",
2733
+ ...props
2734
+ } = {
2735
+ duration: "1s",
2736
+ timingFunction: "linear",
2737
+ timeline: "scroll()",
2738
+ range: "0 400px"
2739
+ }) => ({
2740
+ from: { width: "calc(48px + 120px)" },
2741
+ to: { width: "48px" },
2742
+ duration,
2743
+ timingFunction,
2744
+ timeline,
2745
+ range,
2746
+ ...props
2747
+ });
2748
+ var handWaveScroll = ({
2749
+ duration = "2s",
2750
+ timingFunction = "linear",
2751
+ timeline = "scroll()",
2752
+ range = "10vh 60vh",
2753
+ ...props
2754
+ } = {
2755
+ duration: "2s",
2756
+ timingFunction: "linear",
2757
+ timeline: "scroll()",
2758
+ range: "10vh 60vh"
2759
+ }) => ({
2760
+ from: { transform: "rotate(0deg)" },
2761
+ "50%": { transform: "rotate(20deg)" },
2762
+ to: { transform: "rotate(0deg)" },
2763
+ duration,
2764
+ timingFunction,
2765
+ timeline,
2766
+ range,
2767
+ ...props
2768
+ });
2769
+ var fadeBlurScroll = ({
2770
+ duration = "1s",
2771
+ timingFunction = "linear",
2772
+ timeline = "view()",
2773
+ range = "cover 40% cover 85%",
2774
+ ...props
2775
+ } = {
2776
+ duration: "1s",
2777
+ timingFunction: "linear",
2778
+ timeline: "view()",
2779
+ range: "cover 40% cover 85%"
2780
+ }) => ({
2781
+ to: { opacity: 0, filter: "blur(2rem)" },
2782
+ duration,
2783
+ timingFunction,
2784
+ timeline,
2785
+ range,
2786
+ ...props
2787
+ });
2788
+ var unclipScroll = ({
2789
+ duration = "1s",
2790
+ timingFunction = "linear",
2791
+ timeline = "--article",
2792
+ range = "entry",
2793
+ ...props
2794
+ } = {
2795
+ duration: "1s",
2796
+ timingFunction: "linear",
2797
+ timeline: "--article",
2798
+ range: "entry"
2799
+ }) => ({
2800
+ to: { clipPath: "ellipse(220% 200% at 50% 175%)" },
2801
+ duration,
2802
+ timingFunction,
2803
+ timeline,
2804
+ range,
2805
+ ...props
2806
+ });
2807
+ var scaleDownArticleScroll = ({
2808
+ duration = "1s",
2809
+ timingFunction = "linear",
2810
+ timeline = "--article",
2811
+ range = "entry",
2812
+ ...props
2813
+ } = {
2814
+ duration: "1s",
2815
+ timingFunction: "linear",
2816
+ timeline: "--article",
2817
+ range: "entry"
2818
+ }) => ({
2819
+ "0%": { transform: "scale(5)" },
2820
+ to: { transform: "scale(1)" },
2821
+ duration,
2822
+ timingFunction,
2823
+ timeline,
2824
+ range,
2825
+ ...props
2826
+ });
2827
+ var listItemScaleScroll = ({
2828
+ duration = "0.5s",
2829
+ timingFunction = "ease",
2830
+ timeline = "--i",
2831
+ range = "cover 40% cover 60%",
2832
+ ...props
2833
+ } = {
2834
+ duration: "0.5s",
2835
+ timingFunction: "ease",
2836
+ timeline: "--i",
2837
+ range: "cover 40% cover 60%"
2838
+ }) => ({
2839
+ from: { transform: "scale(0.8)" },
2840
+ "50%": { transform: "scale(1)" },
2841
+ duration,
2842
+ timingFunction,
2843
+ timeline,
2844
+ range,
2845
+ ...props
2846
+ });
2847
+
2848
+ // src/utils/typography.ts
2849
+ var Typography = {
2850
+ letterSpacings: {
2851
+ tighter: -0.08,
2852
+ tight: -0.4,
2853
+ normal: 0,
2854
+ wide: 0.4,
2855
+ wider: 0.8,
2856
+ widest: 1.6
2857
+ },
2858
+ lineHeights: {
2859
+ xs: 10,
2860
+ sm: 12,
2861
+ md: 14,
2862
+ lg: 16,
2863
+ xl: 20,
2864
+ "2xl": 24,
2865
+ "3xl": 30,
2866
+ "4xl": 36,
2867
+ "5xl": 48,
2868
+ "6xl": 64
2869
+ },
2870
+ fontWeights: {
2871
+ hairline: 100,
2872
+ thin: 200,
2873
+ light: 300,
2874
+ normal: 400,
2875
+ medium: 500,
2876
+ semiBold: 600,
2877
+ bold: 700,
2878
+ extraBold: 800,
2879
+ black: 900
2880
+ },
2881
+ fontSizes: {
2882
+ xs: 10,
2883
+ sm: 12,
2884
+ md: 14,
2885
+ lg: 16,
2886
+ xl: 20,
2887
+ "2xl": 24,
2888
+ "3xl": 30,
2889
+ "4xl": 36,
2890
+ "5xl": 48,
2891
+ "6xl": 64
2892
+ }
2893
+ };
2894
+
2895
+ // src/utils/shadow.ts
2896
+ var Shadows = {
2897
+ 0: {
2898
+ shadowColor: "#000",
2899
+ shadowOffset: {
2900
+ width: 1,
2901
+ height: 2
2902
+ },
2903
+ shadowOpacity: 0.18,
2904
+ shadowRadius: 1
2905
+ },
2906
+ 1: {
2907
+ shadowColor: "#000",
2908
+ shadowOffset: {
2909
+ width: 2,
2910
+ height: 2
2911
+ },
2912
+ shadowOpacity: 0.2,
2913
+ shadowRadius: 1.41
2914
+ },
2915
+ 2: {
2916
+ shadowColor: "#000",
2917
+ shadowOffset: {
2918
+ width: 3,
2919
+ height: 3
2920
+ },
2921
+ shadowOpacity: 0.22,
2922
+ shadowRadius: 2.22
2923
+ },
2924
+ 3: {
2925
+ shadowColor: "#000",
2926
+ shadowOffset: {
2927
+ width: 4,
2928
+ height: 4
2929
+ },
2930
+ shadowOpacity: 0.23,
2931
+ shadowRadius: 2.62
2932
+ },
2933
+ 4: {
2934
+ shadowColor: "#000",
2935
+ shadowOffset: {
2936
+ width: 5,
2937
+ height: 5
2938
+ },
2939
+ shadowOpacity: 0.25,
2940
+ shadowRadius: 3.84
2941
+ },
2942
+ 5: {
2943
+ shadowColor: "#000",
2944
+ shadowOffset: {
2945
+ width: 6,
2946
+ height: 6
2947
+ },
2948
+ shadowOpacity: 0.27,
2949
+ shadowRadius: 4.65
2950
+ },
2951
+ 6: {
2952
+ shadowColor: "#000",
2953
+ shadowOffset: {
2954
+ width: 7,
2955
+ height: 7
2956
+ },
2957
+ shadowOpacity: 0.29,
2958
+ shadowRadius: 4.65
2959
+ },
2960
+ 7: {
2961
+ shadowColor: "#000",
2962
+ shadowOffset: {
2963
+ width: 8,
2964
+ height: 8
2965
+ },
2966
+ shadowOpacity: 0.3,
2967
+ shadowRadius: 4.65
2968
+ },
2969
+ 8: {
2970
+ shadowColor: "#000",
2971
+ shadowOffset: {
2972
+ width: 9,
2973
+ height: 9
2974
+ },
2975
+ shadowOpacity: 0.32,
2976
+ shadowRadius: 5.46
2977
+ },
2978
+ 9: {
2979
+ shadowColor: "#000",
2980
+ shadowOffset: {
2981
+ width: 10,
2982
+ height: 10
2983
+ },
2984
+ shadowOpacity: 0.34,
2985
+ shadowRadius: 6.27
2986
+ }
2987
+ };
2988
+
2989
+ // src/utils/env.ts
2990
+ var isBrowser = () => typeof window !== "undefined" && typeof window.document !== "undefined" && typeof window.document.createElement !== "undefined";
2991
+ var getWindowInitialProps = () => isBrowser() ? window.g_initialProps : void 0;
2992
+ var isSSR = !isBrowser();
2993
+ function isDev() {
2994
+ let dev = false;
2995
+ if (isBrowser()) {
2996
+ dev = !(window.location.hostname.indexOf("localhost") === -1);
2997
+ }
2998
+ return dev;
2999
+ }
3000
+ function isProd() {
3001
+ if (isBrowser()) {
3002
+ if (window && window.location && window.location.hostname) {
3003
+ return window.location.hostname.includes("localhost") || window.location.hostname.includes("develop");
3004
+ }
3005
+ }
3006
+ return false;
3007
+ }
3008
+ function isMobile() {
3009
+ return navigator.userAgent.match(/(iPhone|iPod|Android|ios|iPad)/i);
3010
+ }
3011
+
3012
+ // src/utils/viewAnimation.ts
3013
+ var createViewAnimation = (config) => {
3014
+ const { keyframes, timing = {}, range = "entry" } = config;
3015
+ return {
3016
+ ...keyframes,
3017
+ duration: timing.duration || "0.6s",
3018
+ timingFunction: timing.timingFunction || "ease",
3019
+ fillMode: timing.fillMode || "both",
3020
+ delay: timing.delay,
3021
+ timeline: "view()",
3022
+ // CSS view() timeline - pure CSS, no JS!
3023
+ range
3024
+ };
3025
+ };
3026
+ var animateOnView = (config) => {
3027
+ return createViewAnimation(config);
3028
+ };
3029
+ var fadeInOnView = (options = {}) => animateOnView({
3030
+ keyframes: { from: { opacity: 0 }, to: { opacity: 1 } },
3031
+ timing: {
3032
+ duration: options.duration || "0.5s",
3033
+ timingFunction: options.timingFunction || "ease",
3034
+ delay: options.delay
3035
+ },
3036
+ range: options.range || "entry"
3037
+ });
3038
+ var fadeOutOnView = (options = {}) => animateOnView({
3039
+ keyframes: { from: { opacity: 1 }, to: { opacity: 0 } },
3040
+ timing: {
3041
+ duration: options.duration || "0.5s",
3042
+ timingFunction: options.timingFunction || "ease",
3043
+ delay: options.delay
3044
+ },
3045
+ range: options.range || "exit"
3046
+ });
3047
+ var slideUpOnView = (options = {}) => animateOnView({
3048
+ keyframes: {
3049
+ from: {
3050
+ opacity: 0,
3051
+ transform: `translateY(${options.distance || "30px"})`
3052
+ },
3053
+ to: { opacity: 1, transform: "translateY(0)" }
3054
+ },
3055
+ timing: {
3056
+ duration: options.duration || "0.6s",
3057
+ timingFunction: options.timingFunction || "ease-out",
3058
+ delay: options.delay
3059
+ },
3060
+ range: options.range || "entry"
3061
+ });
3062
+ var slideDownOnView = (options = {}) => animateOnView({
3063
+ keyframes: {
3064
+ from: {
3065
+ opacity: 0,
3066
+ transform: `translateY(-${options.distance || "30px"})`
3067
+ },
3068
+ to: { opacity: 1, transform: "translateY(0)" }
3069
+ },
3070
+ timing: {
3071
+ duration: options.duration || "0.6s",
3072
+ timingFunction: options.timingFunction || "ease-out",
3073
+ delay: options.delay
3074
+ },
3075
+ range: options.range || "entry"
3076
+ });
3077
+ var slideLeftOnView = (options = {}) => animateOnView({
3078
+ keyframes: {
3079
+ from: {
3080
+ opacity: 0,
3081
+ transform: `translateX(-${options.distance || "50px"})`
3082
+ },
3083
+ to: { opacity: 1, transform: "translateX(0)" }
3084
+ },
3085
+ timing: {
3086
+ duration: options.duration || "0.6s",
3087
+ timingFunction: options.timingFunction || "ease-out",
3088
+ delay: options.delay
3089
+ },
3090
+ range: options.range || "entry"
3091
+ });
3092
+ var slideRightOnView = (options = {}) => animateOnView({
3093
+ keyframes: {
3094
+ from: {
3095
+ opacity: 0,
3096
+ transform: `translateX(${options.distance || "50px"})`
3097
+ },
3098
+ to: { opacity: 1, transform: "translateX(0)" }
3099
+ },
3100
+ timing: {
3101
+ duration: options.duration || "0.6s",
3102
+ timingFunction: options.timingFunction || "ease-out",
3103
+ delay: options.delay
3104
+ },
3105
+ range: options.range || "entry"
3106
+ });
3107
+ var scaleUpOnView = (options = {}) => animateOnView({
3108
+ keyframes: {
3109
+ from: { opacity: 0, transform: `scale(${options.scale || 0.9})` },
3110
+ to: { opacity: 1, transform: "scale(1)" }
3111
+ },
3112
+ timing: {
3113
+ duration: options.duration || "0.5s",
3114
+ timingFunction: options.timingFunction || "ease",
3115
+ delay: options.delay
3116
+ },
3117
+ range: options.range || "entry"
3118
+ });
3119
+ var scaleDownOnView = (options = {}) => animateOnView({
3120
+ keyframes: {
3121
+ from: { opacity: 0, transform: `scale(${options.scale || 1.1})` },
3122
+ to: { opacity: 1, transform: "scale(1)" }
3123
+ },
3124
+ timing: {
3125
+ duration: options.duration || "0.5s",
3126
+ timingFunction: options.timingFunction || "ease",
3127
+ delay: options.delay
3128
+ },
3129
+ range: options.range || "entry"
3130
+ });
3131
+ var blurInOnView = (options = {}) => animateOnView({
3132
+ keyframes: {
3133
+ from: { opacity: 0, filter: `blur(${options.blur || "10px"})` },
3134
+ to: { opacity: 1, filter: "blur(0)" }
3135
+ },
3136
+ timing: {
3137
+ duration: options.duration || "0.6s",
3138
+ timingFunction: options.timingFunction || "ease-out",
3139
+ delay: options.delay
3140
+ },
3141
+ range: options.range || "entry"
3142
+ });
3143
+ var blurOutOnView = (options = {}) => animateOnView({
3144
+ keyframes: {
3145
+ from: { opacity: 1, filter: "blur(0)" },
3146
+ to: { opacity: 0, filter: `blur(${options.blur || "10px"})` }
3147
+ },
3148
+ timing: {
3149
+ duration: options.duration || "0.5s",
3150
+ timingFunction: options.timingFunction || "ease-in",
3151
+ delay: options.delay
3152
+ },
3153
+ range: options.range || "exit"
3154
+ });
3155
+ var rotateInOnView = (options = {}) => animateOnView({
3156
+ keyframes: {
3157
+ from: {
3158
+ opacity: 0,
3159
+ transform: `rotate(${options.angle || "-10deg"}) scale(0.9)`
3160
+ },
3161
+ to: { opacity: 1, transform: "rotate(0) scale(1)" }
3162
+ },
3163
+ timing: {
3164
+ duration: options.duration || "0.6s",
3165
+ timingFunction: options.timingFunction || "ease-out",
3166
+ delay: options.delay
3167
+ },
3168
+ range: options.range || "entry"
3169
+ });
3170
+ var revealOnView = (options = {}) => animateOnView({
3171
+ keyframes: {
3172
+ from: { clipPath: "inset(100% 0 0 0)" },
3173
+ to: { clipPath: "inset(0 0 0 0)" }
3174
+ },
3175
+ timing: {
3176
+ duration: options.duration || "0.7s",
3177
+ timingFunction: options.timingFunction || "ease-out",
3178
+ delay: options.delay
3179
+ },
3180
+ range: options.range || "entry 0% entry 80%"
3181
+ });
3182
+ var flipXOnView = (options = {}) => animateOnView({
3183
+ keyframes: {
3184
+ from: {
3185
+ opacity: 0,
3186
+ transform: "perspective(400px) rotateX(90deg)"
3187
+ },
3188
+ to: {
3189
+ opacity: 1,
3190
+ transform: "perspective(400px) rotateX(0)"
3191
+ }
3192
+ },
3193
+ timing: {
3194
+ duration: options.duration || "0.6s",
3195
+ timingFunction: options.timingFunction || "ease-out",
3196
+ delay: options.delay
3197
+ },
3198
+ range: options.range || "entry"
3199
+ });
3200
+ var flipYOnView = (options = {}) => animateOnView({
3201
+ keyframes: {
3202
+ from: {
3203
+ opacity: 0,
3204
+ transform: "perspective(400px) rotateY(90deg)"
3205
+ },
3206
+ to: {
3207
+ opacity: 1,
3208
+ transform: "perspective(400px) rotateY(0)"
3209
+ }
3210
+ },
3211
+ timing: {
3212
+ duration: options.duration || "0.6s",
3213
+ timingFunction: options.timingFunction || "ease-out",
3214
+ delay: options.delay
3215
+ },
3216
+ range: options.range || "entry"
3217
+ });
3218
+ var viewAnimationPresets = {
3219
+ fadeIn: {
3220
+ keyframes: { from: { opacity: 0 }, to: { opacity: 1 } },
3221
+ timing: { duration: "0.5s", timingFunction: "ease" },
3222
+ range: "entry"
3223
+ },
3224
+ fadeOut: {
3225
+ keyframes: { from: { opacity: 1 }, to: { opacity: 0 } },
3226
+ timing: { duration: "0.5s", timingFunction: "ease" },
3227
+ range: "exit"
3228
+ },
3229
+ slideUp: {
3230
+ keyframes: {
3231
+ from: { opacity: 0, transform: "translateY(30px)" },
3232
+ to: { opacity: 1, transform: "translateY(0)" }
3233
+ },
3234
+ timing: { duration: "0.6s", timingFunction: "ease-out" },
3235
+ range: "entry"
3236
+ },
3237
+ slideDown: {
3238
+ keyframes: {
3239
+ from: { opacity: 0, transform: "translateY(-30px)" },
3240
+ to: { opacity: 1, transform: "translateY(0)" }
3241
+ },
3242
+ timing: { duration: "0.6s", timingFunction: "ease-out" },
3243
+ range: "entry"
3244
+ },
3245
+ scaleUp: {
3246
+ keyframes: {
3247
+ from: { opacity: 0, transform: "scale(0.9)" },
3248
+ to: { opacity: 1, transform: "scale(1)" }
3249
+ },
3250
+ timing: { duration: "0.5s", timingFunction: "ease" },
3251
+ range: "entry"
3252
+ },
3253
+ blurIn: {
3254
+ keyframes: {
3255
+ from: { opacity: 0, filter: "blur(10px)" },
3256
+ to: { opacity: 1, filter: "blur(0)" }
3257
+ },
3258
+ timing: { duration: "0.6s", timingFunction: "ease-out" },
3259
+ range: "entry"
3260
+ },
3261
+ reveal: {
3262
+ keyframes: {
3263
+ from: { clipPath: "inset(100% 0 0 0)" },
3264
+ to: { clipPath: "inset(0 0 0 0)" }
3265
+ },
3266
+ timing: { duration: "0.7s", timingFunction: "ease-out" },
3267
+ range: "entry 0% entry 80%"
3268
+ }
3269
+ };
3270
+ // Annotate the CommonJS export names for ESM import in node:
3271
+ 0 && (module.exports = {
3272
+ AnalyticsContext,
3273
+ AnalyticsProvider,
3274
+ Animation,
3275
+ BreakpointContext,
3276
+ Button,
3277
+ Center,
3278
+ Div,
3279
+ Element,
3280
+ Form,
3281
+ Horizontal,
3282
+ HorizontalResponsive,
3283
+ Image,
3284
+ ImageBackground,
3285
+ Input,
3286
+ ResponsiveContext,
3287
+ ResponsiveProvider,
3288
+ SafeArea,
3289
+ Scroll,
3290
+ Shadows,
3291
+ Skeleton,
3292
+ Span,
3293
+ StyleRegistry,
3294
+ Text,
3295
+ ThemeContext,
3296
+ ThemeProvider,
3297
+ Typography,
3298
+ Vertical,
3299
+ VerticalResponsive,
3300
+ View,
3301
+ WindowDimensionsContext,
3302
+ WindowSizeContext,
3303
+ WindowSizeProvider,
3304
+ animateOnView,
3305
+ blurInOnView,
3306
+ blurOutOnView,
3307
+ createStyleRegistry,
3308
+ createViewAnimation,
3309
+ defaultColors,
3310
+ defaultDarkColors,
3311
+ defaultDarkPalette,
3312
+ defaultLightColors,
3313
+ defaultLightPalette,
3314
+ fadeInOnView,
3315
+ fadeOutOnView,
3316
+ flipXOnView,
3317
+ flipYOnView,
3318
+ getBreakpointFromWidth,
3319
+ getDeviceFromBreakpoint,
3320
+ getWindowInitialProps,
3321
+ hasColorToken,
3322
+ isBrowser,
3323
+ isDev,
3324
+ isMobile,
3325
+ isProd,
3326
+ isSSR,
3327
+ replaceColorTokens,
3328
+ revealOnView,
3329
+ rotateInOnView,
3330
+ scaleDownOnView,
3331
+ scaleUpOnView,
3332
+ slideDownOnView,
3333
+ slideLeftOnView,
3334
+ slideRightOnView,
3335
+ slideUpOnView,
3336
+ useActive,
3337
+ useAnalytics,
3338
+ useBreakpoint,
3339
+ useBreakpointContext,
3340
+ useClickOutside,
3341
+ useElementPosition,
3342
+ useFocus,
3343
+ useHover,
3344
+ useIframeStyles,
3345
+ useInView,
3346
+ useKeyPress,
3347
+ useMount,
3348
+ useOnScreen,
3349
+ useResponsive,
3350
+ useResponsiveContext,
3351
+ useScroll,
3352
+ useServerInsertedHTML,
3353
+ useStyleRegistry,
3354
+ useTheme,
3355
+ useWindowDimensions,
3356
+ useWindowDimensionsContext,
3357
+ useWindowSize,
3358
+ viewAnimationPresets
3359
+ });
3360
+ //# sourceMappingURL=index.cjs.map