@rocapine/react-native-onboarding 1.59.2 → 1.61.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -0
- package/dist/index.js.map +1 -1
- package/dist/infra/navigation/expoRouterAdapter.js +1 -1
- package/dist/infra/navigation/expoRouterAdapter.js.map +1 -1
- package/dist/infra/provider/OnboardingProvider.d.ts +12 -1
- package/dist/infra/provider/OnboardingProvider.d.ts.map +1 -1
- package/dist/infra/provider/OnboardingProvider.js +15 -1
- package/dist/infra/provider/OnboardingProvider.js.map +1 -1
- package/dist/products/adapters/expoIap.d.ts +4 -0
- package/dist/products/adapters/expoIap.d.ts.map +1 -0
- package/dist/products/adapters/expoIap.js +95 -0
- package/dist/products/adapters/expoIap.js.map +1 -0
- package/dist/products/adapters/revenueCat.d.ts +7 -0
- package/dist/products/adapters/revenueCat.d.ts.map +1 -0
- package/dist/products/adapters/revenueCat.js +116 -0
- package/dist/products/adapters/revenueCat.js.map +1 -0
- package/dist/products/adapters/stub.d.ts +8 -0
- package/dist/products/adapters/stub.d.ts.map +1 -0
- package/dist/products/adapters/stub.js +21 -0
- package/dist/products/adapters/stub.js.map +1 -0
- package/dist/products/derive.d.ts +19 -0
- package/dist/products/derive.d.ts.map +1 -0
- package/dist/products/derive.js +79 -0
- package/dist/products/derive.js.map +1 -0
- package/dist/products/duration.d.ts +3 -0
- package/dist/products/duration.d.ts.map +1 -0
- package/dist/products/duration.js +25 -0
- package/dist/products/duration.js.map +1 -0
- package/dist/products/index.d.ts +9 -0
- package/dist/products/index.d.ts.map +1 -0
- package/dist/products/index.js +20 -0
- package/dist/products/index.js.map +1 -0
- package/dist/products/toVariables.d.ts +18 -0
- package/dist/products/toVariables.d.ts.map +1 -0
- package/dist/products/toVariables.js +52 -0
- package/dist/products/toVariables.js.map +1 -0
- package/dist/products/types.d.ts +96 -0
- package/dist/products/types.d.ts.map +1 -0
- package/dist/products/types.js +3 -0
- package/dist/products/types.js.map +1 -0
- package/dist/products/useProducts.d.ts +12 -0
- package/dist/products/useProducts.d.ts.map +1 -0
- package/dist/products/useProducts.js +90 -0
- package/dist/products/useProducts.js.map +1 -0
- package/dist/{steps/ComposableScreen → screens}/elements/AnimatedTextElement.d.ts +1 -24
- package/dist/screens/elements/AnimatedTextElement.d.ts.map +1 -0
- package/dist/screens/elements/AnimatedTextElement.js.map +1 -0
- package/dist/{steps/ComposableScreen → screens}/elements/BaseBoxProps.d.ts +2 -25
- package/dist/screens/elements/BaseBoxProps.d.ts.map +1 -0
- package/dist/{steps/ComposableScreen → screens}/elements/BaseBoxProps.js +1 -1
- package/dist/screens/elements/BaseBoxProps.js.map +1 -0
- package/dist/{steps/ComposableScreen → screens}/elements/ButtonElement.d.ts +8 -123
- package/dist/screens/elements/ButtonElement.d.ts.map +1 -0
- package/dist/{steps/ComposableScreen → screens}/elements/ButtonElement.js +2 -2
- package/dist/screens/elements/ButtonElement.js.map +1 -0
- package/dist/{steps/ComposableScreen → screens}/elements/CarouselElement.d.ts +1 -24
- package/dist/screens/elements/CarouselElement.d.ts.map +1 -0
- package/dist/screens/elements/CarouselElement.js.map +1 -0
- package/dist/{steps/ComposableScreen → screens}/elements/CheckboxGroupElement.d.ts +2 -25
- package/dist/screens/elements/CheckboxGroupElement.d.ts.map +1 -0
- package/dist/{steps/ComposableScreen → screens}/elements/CheckboxGroupElement.js +1 -1
- package/dist/screens/elements/CheckboxGroupElement.js.map +1 -0
- package/dist/{steps/ComposableScreen → screens}/elements/DatePickerElement.d.ts +1 -24
- package/dist/screens/elements/DatePickerElement.d.ts.map +1 -0
- package/dist/screens/elements/DatePickerElement.js.map +1 -0
- package/dist/{steps/ComposableScreen → screens}/elements/DrawingPadElement.d.ts +1 -24
- package/dist/screens/elements/DrawingPadElement.d.ts.map +1 -0
- package/dist/screens/elements/DrawingPadElement.js.map +1 -0
- package/dist/{steps/ComposableScreen → screens}/elements/IconElement.d.ts +1 -24
- package/dist/screens/elements/IconElement.d.ts.map +1 -0
- package/dist/screens/elements/IconElement.js.map +1 -0
- package/dist/{steps/ComposableScreen → screens}/elements/ImageElement.d.ts +1 -24
- package/dist/screens/elements/ImageElement.d.ts.map +1 -0
- package/dist/screens/elements/ImageElement.js.map +1 -0
- package/dist/{steps/ComposableScreen → screens}/elements/InputElement.d.ts +1 -24
- package/dist/screens/elements/InputElement.d.ts.map +1 -0
- package/dist/screens/elements/InputElement.js.map +1 -0
- package/dist/{steps/ComposableScreen → screens}/elements/KeyboardAvoidingViewElement.d.ts +1 -24
- package/dist/screens/elements/KeyboardAvoidingViewElement.d.ts.map +1 -0
- package/dist/screens/elements/KeyboardAvoidingViewElement.js.map +1 -0
- package/dist/{steps/ComposableScreen → screens}/elements/LottieElement.d.ts +1 -24
- package/dist/screens/elements/LottieElement.d.ts.map +1 -0
- package/dist/screens/elements/LottieElement.js.map +1 -0
- package/dist/{steps/ComposableScreen → screens}/elements/ProgressIndicatorElement.d.ts +1 -24
- package/dist/screens/elements/ProgressIndicatorElement.d.ts.map +1 -0
- package/dist/screens/elements/ProgressIndicatorElement.js.map +1 -0
- package/dist/{steps/ComposableScreen → screens}/elements/ProgressiveBlurImageElement.d.ts +1 -24
- package/dist/screens/elements/ProgressiveBlurImageElement.d.ts.map +1 -0
- package/dist/screens/elements/ProgressiveBlurImageElement.js.map +1 -0
- package/dist/{steps/ComposableScreen → screens}/elements/RadioGroupElement.d.ts +2 -25
- package/dist/screens/elements/RadioGroupElement.d.ts.map +1 -0
- package/dist/{steps/ComposableScreen → screens}/elements/RadioGroupElement.js +1 -1
- package/dist/screens/elements/RadioGroupElement.js.map +1 -0
- package/dist/{steps/ComposableScreen → screens}/elements/RichTextElement.d.ts +1 -24
- package/dist/screens/elements/RichTextElement.d.ts.map +1 -0
- package/dist/screens/elements/RichTextElement.js.map +1 -0
- package/dist/{steps/ComposableScreen → screens}/elements/RiveElement.d.ts +1 -24
- package/dist/screens/elements/RiveElement.d.ts.map +1 -0
- package/dist/screens/elements/RiveElement.js.map +1 -0
- package/dist/{steps/ComposableScreen → screens}/elements/SafeAreaViewElement.d.ts +1 -24
- package/dist/screens/elements/SafeAreaViewElement.d.ts.map +1 -0
- package/dist/screens/elements/SafeAreaViewElement.js.map +1 -0
- package/dist/{steps/ComposableScreen → screens}/elements/ScrollViewElement.d.ts +1 -24
- package/dist/screens/elements/ScrollViewElement.d.ts.map +1 -0
- package/dist/screens/elements/ScrollViewElement.js.map +1 -0
- package/dist/{steps/ComposableScreen → screens}/elements/SliderElement.d.ts +1 -24
- package/dist/screens/elements/SliderElement.d.ts.map +1 -0
- package/dist/screens/elements/SliderElement.js.map +1 -0
- package/dist/{steps/ComposableScreen → screens}/elements/StackElement.d.ts +1 -24
- package/dist/screens/elements/StackElement.d.ts.map +1 -0
- package/dist/screens/elements/StackElement.js.map +1 -0
- package/dist/{steps/ComposableScreen → screens}/elements/TextElement.d.ts +1 -24
- package/dist/screens/elements/TextElement.d.ts.map +1 -0
- package/dist/screens/elements/TextElement.js.map +1 -0
- package/dist/{steps/ComposableScreen → screens}/elements/TypewriterTextElement.d.ts +1 -24
- package/dist/screens/elements/TypewriterTextElement.d.ts.map +1 -0
- package/dist/screens/elements/TypewriterTextElement.js.map +1 -0
- package/dist/{steps/ComposableScreen → screens}/elements/VideoElement.d.ts +1 -24
- package/dist/screens/elements/VideoElement.d.ts.map +1 -0
- package/dist/screens/elements/VideoElement.js.map +1 -0
- package/dist/{steps/ComposableScreen → screens}/elements/WheelPickerElement.d.ts +1 -24
- package/dist/screens/elements/WheelPickerElement.d.ts.map +1 -0
- package/dist/screens/elements/WheelPickerElement.js.map +1 -0
- package/dist/{steps/ComposableScreen → screens}/elements/ZStackElement.d.ts +1 -24
- package/dist/screens/elements/ZStackElement.d.ts.map +1 -0
- package/dist/screens/elements/ZStackElement.js.map +1 -0
- package/dist/screens/types.d.ts +242 -0
- package/dist/screens/types.d.ts.map +1 -0
- package/dist/screens/types.js +272 -0
- package/dist/screens/types.js.map +1 -0
- package/dist/steps/Carousel/types.d.ts +1 -1
- package/dist/steps/Commitment/types.d.ts +1 -1
- package/dist/steps/ComposableScreen/types.d.ts +5 -236
- package/dist/steps/ComposableScreen/types.d.ts.map +1 -1
- package/dist/steps/ComposableScreen/types.js +23 -262
- package/dist/steps/ComposableScreen/types.js.map +1 -1
- package/dist/steps/Loader/types.d.ts +1 -1
- package/dist/steps/MediaContent/types.d.ts +1 -1
- package/dist/steps/Picker/types.d.ts +1 -1
- package/dist/steps/Question/types.d.ts +1 -1
- package/dist/steps/Ratings/types.d.ts +1 -1
- package/dist/steps/common.types.d.ts +23 -30
- package/dist/steps/common.types.d.ts.map +1 -1
- package/dist/steps/common.types.js +18 -3
- package/dist/steps/common.types.js.map +1 -1
- package/package.json +3 -3
- package/src/__tests__/productAdapters.test.ts +58 -0
- package/src/__tests__/productDerive.test.ts +111 -0
- package/src/__tests__/productVariables.test.ts +109 -0
- package/src/__tests__/screenTypesBackCompat.test.ts +58 -0
- package/src/index.ts +2 -0
- package/src/infra/navigation/expoRouterAdapter.ts +1 -1
- package/src/infra/provider/OnboardingProvider.tsx +29 -0
- package/src/products/adapters/expoIap.ts +93 -0
- package/src/products/adapters/revenueCat.ts +108 -0
- package/src/products/adapters/stub.ts +20 -0
- package/src/products/derive.ts +93 -0
- package/src/products/duration.ts +21 -0
- package/src/products/index.ts +19 -0
- package/src/products/toVariables.ts +54 -0
- package/src/products/types.ts +88 -0
- package/src/products/useProducts.ts +106 -0
- package/src/{steps/ComposableScreen → screens}/elements/BaseBoxProps.ts +1 -1
- package/src/{steps/ComposableScreen → screens}/elements/ButtonElement.ts +2 -2
- package/src/{steps/ComposableScreen → screens}/elements/CheckboxGroupElement.ts +1 -1
- package/src/{steps/ComposableScreen → screens}/elements/RadioGroupElement.ts +1 -1
- package/src/screens/types.ts +535 -0
- package/src/steps/ComposableScreen/types.ts +9 -528
- package/src/steps/common.types.ts +50 -6
- package/dist/steps/ComposableScreen/elements/AnimatedTextElement.d.ts.map +0 -1
- package/dist/steps/ComposableScreen/elements/AnimatedTextElement.js.map +0 -1
- package/dist/steps/ComposableScreen/elements/BaseBoxProps.d.ts.map +0 -1
- package/dist/steps/ComposableScreen/elements/BaseBoxProps.js.map +0 -1
- package/dist/steps/ComposableScreen/elements/ButtonElement.d.ts.map +0 -1
- package/dist/steps/ComposableScreen/elements/ButtonElement.js.map +0 -1
- package/dist/steps/ComposableScreen/elements/CarouselElement.d.ts.map +0 -1
- package/dist/steps/ComposableScreen/elements/CarouselElement.js.map +0 -1
- package/dist/steps/ComposableScreen/elements/CheckboxGroupElement.d.ts.map +0 -1
- package/dist/steps/ComposableScreen/elements/CheckboxGroupElement.js.map +0 -1
- package/dist/steps/ComposableScreen/elements/DatePickerElement.d.ts.map +0 -1
- package/dist/steps/ComposableScreen/elements/DatePickerElement.js.map +0 -1
- package/dist/steps/ComposableScreen/elements/DrawingPadElement.d.ts.map +0 -1
- package/dist/steps/ComposableScreen/elements/DrawingPadElement.js.map +0 -1
- package/dist/steps/ComposableScreen/elements/IconElement.d.ts.map +0 -1
- package/dist/steps/ComposableScreen/elements/IconElement.js.map +0 -1
- package/dist/steps/ComposableScreen/elements/ImageElement.d.ts.map +0 -1
- package/dist/steps/ComposableScreen/elements/ImageElement.js.map +0 -1
- package/dist/steps/ComposableScreen/elements/InputElement.d.ts.map +0 -1
- package/dist/steps/ComposableScreen/elements/InputElement.js.map +0 -1
- package/dist/steps/ComposableScreen/elements/KeyboardAvoidingViewElement.d.ts.map +0 -1
- package/dist/steps/ComposableScreen/elements/KeyboardAvoidingViewElement.js.map +0 -1
- package/dist/steps/ComposableScreen/elements/LottieElement.d.ts.map +0 -1
- package/dist/steps/ComposableScreen/elements/LottieElement.js.map +0 -1
- package/dist/steps/ComposableScreen/elements/ProgressIndicatorElement.d.ts.map +0 -1
- package/dist/steps/ComposableScreen/elements/ProgressIndicatorElement.js.map +0 -1
- package/dist/steps/ComposableScreen/elements/ProgressiveBlurImageElement.d.ts.map +0 -1
- package/dist/steps/ComposableScreen/elements/ProgressiveBlurImageElement.js.map +0 -1
- package/dist/steps/ComposableScreen/elements/RadioGroupElement.d.ts.map +0 -1
- package/dist/steps/ComposableScreen/elements/RadioGroupElement.js.map +0 -1
- package/dist/steps/ComposableScreen/elements/RichTextElement.d.ts.map +0 -1
- package/dist/steps/ComposableScreen/elements/RichTextElement.js.map +0 -1
- package/dist/steps/ComposableScreen/elements/RiveElement.d.ts.map +0 -1
- package/dist/steps/ComposableScreen/elements/RiveElement.js.map +0 -1
- package/dist/steps/ComposableScreen/elements/SafeAreaViewElement.d.ts.map +0 -1
- package/dist/steps/ComposableScreen/elements/SafeAreaViewElement.js.map +0 -1
- package/dist/steps/ComposableScreen/elements/ScrollViewElement.d.ts.map +0 -1
- package/dist/steps/ComposableScreen/elements/ScrollViewElement.js.map +0 -1
- package/dist/steps/ComposableScreen/elements/SliderElement.d.ts.map +0 -1
- package/dist/steps/ComposableScreen/elements/SliderElement.js.map +0 -1
- package/dist/steps/ComposableScreen/elements/StackElement.d.ts.map +0 -1
- package/dist/steps/ComposableScreen/elements/StackElement.js.map +0 -1
- package/dist/steps/ComposableScreen/elements/TextElement.d.ts.map +0 -1
- package/dist/steps/ComposableScreen/elements/TextElement.js.map +0 -1
- package/dist/steps/ComposableScreen/elements/TypewriterTextElement.d.ts.map +0 -1
- package/dist/steps/ComposableScreen/elements/TypewriterTextElement.js.map +0 -1
- package/dist/steps/ComposableScreen/elements/VideoElement.d.ts.map +0 -1
- package/dist/steps/ComposableScreen/elements/VideoElement.js.map +0 -1
- package/dist/steps/ComposableScreen/elements/WheelPickerElement.d.ts.map +0 -1
- package/dist/steps/ComposableScreen/elements/WheelPickerElement.js.map +0 -1
- package/dist/steps/ComposableScreen/elements/ZStackElement.d.ts.map +0 -1
- package/dist/steps/ComposableScreen/elements/ZStackElement.js.map +0 -1
- /package/dist/{steps/ComposableScreen → screens}/elements/AnimatedTextElement.js +0 -0
- /package/dist/{steps/ComposableScreen → screens}/elements/CarouselElement.js +0 -0
- /package/dist/{steps/ComposableScreen → screens}/elements/DatePickerElement.js +0 -0
- /package/dist/{steps/ComposableScreen → screens}/elements/DrawingPadElement.js +0 -0
- /package/dist/{steps/ComposableScreen → screens}/elements/IconElement.js +0 -0
- /package/dist/{steps/ComposableScreen → screens}/elements/ImageElement.js +0 -0
- /package/dist/{steps/ComposableScreen → screens}/elements/InputElement.js +0 -0
- /package/dist/{steps/ComposableScreen → screens}/elements/KeyboardAvoidingViewElement.js +0 -0
- /package/dist/{steps/ComposableScreen → screens}/elements/LottieElement.js +0 -0
- /package/dist/{steps/ComposableScreen → screens}/elements/ProgressIndicatorElement.js +0 -0
- /package/dist/{steps/ComposableScreen → screens}/elements/ProgressiveBlurImageElement.js +0 -0
- /package/dist/{steps/ComposableScreen → screens}/elements/RichTextElement.js +0 -0
- /package/dist/{steps/ComposableScreen → screens}/elements/RiveElement.js +0 -0
- /package/dist/{steps/ComposableScreen → screens}/elements/SafeAreaViewElement.js +0 -0
- /package/dist/{steps/ComposableScreen → screens}/elements/ScrollViewElement.js +0 -0
- /package/dist/{steps/ComposableScreen → screens}/elements/SliderElement.js +0 -0
- /package/dist/{steps/ComposableScreen → screens}/elements/StackElement.js +0 -0
- /package/dist/{steps/ComposableScreen → screens}/elements/TextElement.js +0 -0
- /package/dist/{steps/ComposableScreen → screens}/elements/TypewriterTextElement.js +0 -0
- /package/dist/{steps/ComposableScreen → screens}/elements/VideoElement.js +0 -0
- /package/dist/{steps/ComposableScreen → screens}/elements/WheelPickerElement.js +0 -0
- /package/dist/{steps/ComposableScreen → screens}/elements/ZStackElement.js +0 -0
- /package/src/{steps/ComposableScreen → screens}/elements/AnimatedTextElement.ts +0 -0
- /package/src/{steps/ComposableScreen → screens}/elements/CarouselElement.ts +0 -0
- /package/src/{steps/ComposableScreen → screens}/elements/DatePickerElement.ts +0 -0
- /package/src/{steps/ComposableScreen → screens}/elements/DrawingPadElement.ts +0 -0
- /package/src/{steps/ComposableScreen → screens}/elements/IconElement.ts +0 -0
- /package/src/{steps/ComposableScreen → screens}/elements/ImageElement.ts +0 -0
- /package/src/{steps/ComposableScreen → screens}/elements/InputElement.ts +0 -0
- /package/src/{steps/ComposableScreen → screens}/elements/KeyboardAvoidingViewElement.ts +0 -0
- /package/src/{steps/ComposableScreen → screens}/elements/LottieElement.ts +0 -0
- /package/src/{steps/ComposableScreen → screens}/elements/ProgressIndicatorElement.ts +0 -0
- /package/src/{steps/ComposableScreen → screens}/elements/ProgressiveBlurImageElement.ts +0 -0
- /package/src/{steps/ComposableScreen → screens}/elements/RichTextElement.ts +0 -0
- /package/src/{steps/ComposableScreen → screens}/elements/RiveElement.ts +0 -0
- /package/src/{steps/ComposableScreen → screens}/elements/SafeAreaViewElement.ts +0 -0
- /package/src/{steps/ComposableScreen → screens}/elements/ScrollViewElement.ts +0 -0
- /package/src/{steps/ComposableScreen → screens}/elements/SliderElement.ts +0 -0
- /package/src/{steps/ComposableScreen → screens}/elements/StackElement.ts +0 -0
- /package/src/{steps/ComposableScreen → screens}/elements/TextElement.ts +0 -0
- /package/src/{steps/ComposableScreen → screens}/elements/TypewriterTextElement.ts +0 -0
- /package/src/{steps/ComposableScreen → screens}/elements/VideoElement.ts +0 -0
- /package/src/{steps/ComposableScreen → screens}/elements/WheelPickerElement.ts +0 -0
- /package/src/{steps/ComposableScreen → screens}/elements/ZStackElement.ts +0 -0
|
@@ -1,238 +1,7 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
|
-
|
|
3
|
-
import { type StackElementProps } from "./elements/StackElement";
|
|
4
|
-
import { type TextElementProps } from "./elements/TextElement";
|
|
5
|
-
import { type RichTextElementProps } from "./elements/RichTextElement";
|
|
6
|
-
import { type ImageElementProps } from "./elements/ImageElement";
|
|
7
|
-
import { type ProgressiveBlurImageElementProps } from "./elements/ProgressiveBlurImageElement";
|
|
8
|
-
import { type LottieElementProps } from "./elements/LottieElement";
|
|
9
|
-
import { type RiveElementProps } from "./elements/RiveElement";
|
|
10
|
-
import { type IconElementProps } from "./elements/IconElement";
|
|
11
|
-
import { type VideoElementProps } from "./elements/VideoElement";
|
|
12
|
-
import { type InputElementProps } from "./elements/InputElement";
|
|
13
|
-
import { type ButtonElementProps } from "./elements/ButtonElement";
|
|
14
|
-
import { type RadioGroupElementProps } from "./elements/RadioGroupElement";
|
|
15
|
-
import { type CheckboxGroupElementProps } from "./elements/CheckboxGroupElement";
|
|
16
|
-
import { type DatePickerElementProps } from "./elements/DatePickerElement";
|
|
17
|
-
import { type WheelPickerElementProps } from "./elements/WheelPickerElement";
|
|
18
|
-
import { type CarouselElementProps } from "./elements/CarouselElement";
|
|
19
|
-
import { type ZStackElementProps } from "./elements/ZStackElement";
|
|
20
|
-
import { type SafeAreaViewElementProps } from "./elements/SafeAreaViewElement";
|
|
21
|
-
import { type ScrollViewElementProps } from "./elements/ScrollViewElement";
|
|
22
|
-
import { type KeyboardAvoidingViewElementProps } from "./elements/KeyboardAvoidingViewElement";
|
|
23
|
-
import { type ProgressIndicatorElementProps } from "./elements/ProgressIndicatorElement";
|
|
24
|
-
import { type AnimatedTextElementProps } from "./elements/AnimatedTextElement";
|
|
25
|
-
import { type TypewriterTextElementProps } from "./elements/TypewriterTextElement";
|
|
26
|
-
import { type DrawingPadElementProps } from "./elements/DrawingPadElement";
|
|
27
|
-
import { type SliderElementProps } from "./elements/SliderElement";
|
|
28
|
-
export type { BaseBoxProps, GradientBackground, GradientEdge, GradientStop, LinearGradientConfig } from "./elements/BaseBoxProps";
|
|
29
|
-
export type { AnimationEasing, SpringConfig, EnteringPreset, ExitingPreset, LayoutPreset, EffectPreset, EnteringAnimation, ExitingAnimation, LayoutAnimation, ElementEffect, ElementAnimation, ElementTransform, } from "./elements/BaseBoxProps";
|
|
30
|
-
export { BaseBoxPropsSchema, GradientBackgroundSchema } from "./elements/BaseBoxProps";
|
|
31
|
-
export type { StackElementProps } from "./elements/StackElement";
|
|
32
|
-
export type { TextElementProps, TextSpan } from "./elements/TextElement";
|
|
33
|
-
export { TextSpanSchema } from "./elements/TextElement";
|
|
34
|
-
export type { RichTextElementProps } from "./elements/RichTextElement";
|
|
35
|
-
export type { ImageElementProps } from "./elements/ImageElement";
|
|
36
|
-
export type { ProgressiveBlurImageElementProps, BlurMask, LinearBlurMask, RadialBlurMask, BlurMaskStop, BlurAppear, } from "./elements/ProgressiveBlurImageElement";
|
|
37
|
-
export type { LottieElementProps } from "./elements/LottieElement";
|
|
38
|
-
export type { RiveElementProps } from "./elements/RiveElement";
|
|
39
|
-
export type { IconElementProps } from "./elements/IconElement";
|
|
40
|
-
export type { VideoElementProps } from "./elements/VideoElement";
|
|
41
|
-
export type { InputElementProps } from "./elements/InputElement";
|
|
42
|
-
export type { ButtonElementProps, ButtonAction, CustomButtonAction, SetVariableButtonAction } from "./elements/ButtonElement";
|
|
43
|
-
export { ButtonActionSchema, CustomButtonActionSchema, SetVariableButtonActionSchema } from "./elements/ButtonElement";
|
|
44
|
-
export type { RadioGroupElementProps } from "./elements/RadioGroupElement";
|
|
45
|
-
export type { CheckboxGroupElementProps } from "./elements/CheckboxGroupElement";
|
|
46
|
-
export type { DatePickerElementProps } from "./elements/DatePickerElement";
|
|
47
|
-
export type { WheelPickerElementProps, WheelPickerItem, WheelPickerRange } from "./elements/WheelPickerElement";
|
|
48
|
-
export { WheelPickerElementPropsSchema, generateWheelPickerRangeItems, resolveWheelPickerItems } from "./elements/WheelPickerElement";
|
|
49
|
-
export type { CarouselElementProps } from "./elements/CarouselElement";
|
|
50
|
-
export type { ZStackElementProps } from "./elements/ZStackElement";
|
|
51
|
-
export type { SafeAreaViewElementProps, SafeAreaEdge, SafeAreaEdgeMode } from "./elements/SafeAreaViewElement";
|
|
52
|
-
export type { ScrollViewElementProps, ScrollViewContentInset } from "./elements/ScrollViewElement";
|
|
53
|
-
export type { KeyboardAvoidingViewElementProps, KeyboardAvoidingBehavior, } from "./elements/KeyboardAvoidingViewElement";
|
|
54
|
-
export type { ProgressIndicatorElementProps, ProgressEasing } from "./elements/ProgressIndicatorElement";
|
|
55
|
-
export type { AnimatedTextElementProps } from "./elements/AnimatedTextElement";
|
|
56
|
-
export type { TypewriterTextElementProps } from "./elements/TypewriterTextElement";
|
|
57
|
-
export type { DrawingPadElementProps } from "./elements/DrawingPadElement";
|
|
58
|
-
export type { SliderElementProps } from "./elements/SliderElement";
|
|
59
|
-
/**
|
|
60
|
-
* Type tag for a ComposableScreen variable. Drives expression-mode coercion
|
|
61
|
-
* in `setVariable` action evaluation (int/float math vs string concat).
|
|
62
|
-
*/
|
|
63
|
-
export type ComposableVariableKind = "int" | "float" | "string";
|
|
64
|
-
/**
|
|
65
|
-
* A variable entry stored in the ComposableScreen variables map.
|
|
66
|
-
* `value` is the canonical value (always a string), `label` is an optional
|
|
67
|
-
* display label, `kind` optionally tags the underlying type.
|
|
68
|
-
*/
|
|
69
|
-
export type ComposableVariableEntry = {
|
|
70
|
-
value: string;
|
|
71
|
-
label?: string;
|
|
72
|
-
kind?: ComposableVariableKind;
|
|
73
|
-
};
|
|
74
|
-
type UIElement = {
|
|
75
|
-
id: string;
|
|
76
|
-
name?: string;
|
|
77
|
-
renderWhen?: LeafCondition | ConditionGroup;
|
|
78
|
-
type: "YStack" | "XStack";
|
|
79
|
-
props: StackElementProps;
|
|
80
|
-
children: UIElement[];
|
|
81
|
-
} | {
|
|
82
|
-
id: string;
|
|
83
|
-
name?: string;
|
|
84
|
-
renderWhen?: LeafCondition | ConditionGroup;
|
|
85
|
-
type: "Text";
|
|
86
|
-
props: TextElementProps;
|
|
87
|
-
} | {
|
|
88
|
-
id: string;
|
|
89
|
-
name?: string;
|
|
90
|
-
renderWhen?: LeafCondition | ConditionGroup;
|
|
91
|
-
type: "RichText";
|
|
92
|
-
props: RichTextElementProps;
|
|
93
|
-
children: Array<Extract<UIElement, {
|
|
94
|
-
type: "Text";
|
|
95
|
-
}>>;
|
|
96
|
-
} | {
|
|
97
|
-
id: string;
|
|
98
|
-
name?: string;
|
|
99
|
-
renderWhen?: LeafCondition | ConditionGroup;
|
|
100
|
-
type: "Image";
|
|
101
|
-
props: ImageElementProps;
|
|
102
|
-
} | {
|
|
103
|
-
id: string;
|
|
104
|
-
name?: string;
|
|
105
|
-
renderWhen?: LeafCondition | ConditionGroup;
|
|
106
|
-
type: "ProgressiveBlurImage";
|
|
107
|
-
props: ProgressiveBlurImageElementProps;
|
|
108
|
-
} | {
|
|
109
|
-
id: string;
|
|
110
|
-
name?: string;
|
|
111
|
-
renderWhen?: LeafCondition | ConditionGroup;
|
|
112
|
-
type: "Lottie";
|
|
113
|
-
props: LottieElementProps;
|
|
114
|
-
} | {
|
|
115
|
-
id: string;
|
|
116
|
-
name?: string;
|
|
117
|
-
renderWhen?: LeafCondition | ConditionGroup;
|
|
118
|
-
type: "Rive";
|
|
119
|
-
props: RiveElementProps;
|
|
120
|
-
} | {
|
|
121
|
-
id: string;
|
|
122
|
-
name?: string;
|
|
123
|
-
renderWhen?: LeafCondition | ConditionGroup;
|
|
124
|
-
type: "Icon";
|
|
125
|
-
props: IconElementProps;
|
|
126
|
-
} | {
|
|
127
|
-
id: string;
|
|
128
|
-
name?: string;
|
|
129
|
-
renderWhen?: LeafCondition | ConditionGroup;
|
|
130
|
-
type: "Video";
|
|
131
|
-
props: VideoElementProps;
|
|
132
|
-
} | {
|
|
133
|
-
id: string;
|
|
134
|
-
name?: string;
|
|
135
|
-
renderWhen?: LeafCondition | ConditionGroup;
|
|
136
|
-
type: "Input";
|
|
137
|
-
props: InputElementProps;
|
|
138
|
-
} | {
|
|
139
|
-
id: string;
|
|
140
|
-
name?: string;
|
|
141
|
-
renderWhen?: LeafCondition | ConditionGroup;
|
|
142
|
-
type: "Button";
|
|
143
|
-
props: ButtonElementProps;
|
|
144
|
-
} | {
|
|
145
|
-
id: string;
|
|
146
|
-
name?: string;
|
|
147
|
-
renderWhen?: LeafCondition | ConditionGroup;
|
|
148
|
-
type: "RadioGroup";
|
|
149
|
-
props: RadioGroupElementProps;
|
|
150
|
-
} | {
|
|
151
|
-
id: string;
|
|
152
|
-
name?: string;
|
|
153
|
-
renderWhen?: LeafCondition | ConditionGroup;
|
|
154
|
-
type: "CheckboxGroup";
|
|
155
|
-
props: CheckboxGroupElementProps;
|
|
156
|
-
} | {
|
|
157
|
-
id: string;
|
|
158
|
-
name?: string;
|
|
159
|
-
renderWhen?: LeafCondition | ConditionGroup;
|
|
160
|
-
type: "DatePicker";
|
|
161
|
-
props: DatePickerElementProps;
|
|
162
|
-
} | {
|
|
163
|
-
id: string;
|
|
164
|
-
name?: string;
|
|
165
|
-
renderWhen?: LeafCondition | ConditionGroup;
|
|
166
|
-
type: "WheelPicker";
|
|
167
|
-
props: WheelPickerElementProps;
|
|
168
|
-
} | {
|
|
169
|
-
id: string;
|
|
170
|
-
name?: string;
|
|
171
|
-
renderWhen?: LeafCondition | ConditionGroup;
|
|
172
|
-
type: "Carousel";
|
|
173
|
-
props: CarouselElementProps;
|
|
174
|
-
children: UIElement[];
|
|
175
|
-
} | {
|
|
176
|
-
id: string;
|
|
177
|
-
name?: string;
|
|
178
|
-
renderWhen?: LeafCondition | ConditionGroup;
|
|
179
|
-
type: "ZStack";
|
|
180
|
-
props: ZStackElementProps;
|
|
181
|
-
children: UIElement[];
|
|
182
|
-
} | {
|
|
183
|
-
id: string;
|
|
184
|
-
name?: string;
|
|
185
|
-
renderWhen?: LeafCondition | ConditionGroup;
|
|
186
|
-
type: "SafeAreaView";
|
|
187
|
-
props: SafeAreaViewElementProps;
|
|
188
|
-
children: UIElement[];
|
|
189
|
-
} | {
|
|
190
|
-
id: string;
|
|
191
|
-
name?: string;
|
|
192
|
-
renderWhen?: LeafCondition | ConditionGroup;
|
|
193
|
-
type: "ScrollView";
|
|
194
|
-
props: ScrollViewElementProps;
|
|
195
|
-
children: UIElement[];
|
|
196
|
-
} | {
|
|
197
|
-
id: string;
|
|
198
|
-
name?: string;
|
|
199
|
-
renderWhen?: LeafCondition | ConditionGroup;
|
|
200
|
-
type: "KeyboardAvoidingView";
|
|
201
|
-
props: KeyboardAvoidingViewElementProps;
|
|
202
|
-
children: UIElement[];
|
|
203
|
-
} | {
|
|
204
|
-
id: string;
|
|
205
|
-
name?: string;
|
|
206
|
-
renderWhen?: LeafCondition | ConditionGroup;
|
|
207
|
-
type: "ProgressIndicator";
|
|
208
|
-
props: ProgressIndicatorElementProps;
|
|
209
|
-
} | {
|
|
210
|
-
id: string;
|
|
211
|
-
name?: string;
|
|
212
|
-
renderWhen?: LeafCondition | ConditionGroup;
|
|
213
|
-
type: "AnimatedText";
|
|
214
|
-
props: AnimatedTextElementProps;
|
|
215
|
-
} | {
|
|
216
|
-
id: string;
|
|
217
|
-
name?: string;
|
|
218
|
-
renderWhen?: LeafCondition | ConditionGroup;
|
|
219
|
-
type: "TypewriterText";
|
|
220
|
-
props: TypewriterTextElementProps;
|
|
221
|
-
} | {
|
|
222
|
-
id: string;
|
|
223
|
-
name?: string;
|
|
224
|
-
renderWhen?: LeafCondition | ConditionGroup;
|
|
225
|
-
type: "DrawingPad";
|
|
226
|
-
props: DrawingPadElementProps;
|
|
227
|
-
} | {
|
|
228
|
-
id: string;
|
|
229
|
-
name?: string;
|
|
230
|
-
renderWhen?: LeafCondition | ConditionGroup;
|
|
231
|
-
type: "Slider";
|
|
232
|
-
props: SliderElementProps;
|
|
233
|
-
};
|
|
2
|
+
export * from "../../screens/types";
|
|
234
3
|
export declare const ComposableScreenStepPayloadSchema: z.ZodObject<{
|
|
235
|
-
elements: z.ZodArray<z.ZodType<UIElement, unknown, z.core.$ZodTypeInternals<UIElement, unknown>>>;
|
|
4
|
+
elements: z.ZodArray<z.ZodType<import("../../screens/types").UIElement, unknown, z.core.$ZodTypeInternals<import("../../screens/types").UIElement, unknown>>>;
|
|
236
5
|
}, z.core.$strip>;
|
|
237
6
|
export declare const ComposableScreenStepTypeSchema: z.ZodObject<{
|
|
238
7
|
id: z.ZodString;
|
|
@@ -251,6 +20,7 @@ export declare const ComposableScreenStepTypeSchema: z.ZodObject<{
|
|
|
251
20
|
condition: z.ZodDefault<z.ZodNullable<z.ZodUnion<readonly [z.ZodObject<{
|
|
252
21
|
variable: z.ZodString;
|
|
253
22
|
operator: z.ZodEnum<{
|
|
23
|
+
in: "in";
|
|
254
24
|
eq: "eq";
|
|
255
25
|
neq: "neq";
|
|
256
26
|
gt: "gt";
|
|
@@ -258,7 +28,6 @@ export declare const ComposableScreenStepTypeSchema: z.ZodObject<{
|
|
|
258
28
|
gte: "gte";
|
|
259
29
|
lte: "lte";
|
|
260
30
|
contains: "contains";
|
|
261
|
-
in: "in";
|
|
262
31
|
not_in: "not_in";
|
|
263
32
|
is_empty: "is_empty";
|
|
264
33
|
is_not_empty: "is_not_empty";
|
|
@@ -266,13 +35,13 @@ export declare const ComposableScreenStepTypeSchema: z.ZodObject<{
|
|
|
266
35
|
is_not_null: "is_not_null";
|
|
267
36
|
}>;
|
|
268
37
|
value: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>]>>;
|
|
269
|
-
}, z.core.$strip>, z.ZodType<ConditionGroup, unknown, z.core.$ZodTypeInternals<ConditionGroup, unknown>>]>>>;
|
|
38
|
+
}, z.core.$strip>, z.ZodType<import("../common.types").ConditionGroup, unknown, z.core.$ZodTypeInternals<import("../common.types").ConditionGroup, unknown>>]>>>;
|
|
270
39
|
targetStepId: z.ZodString;
|
|
271
40
|
}, z.core.$strip>>>;
|
|
272
41
|
}, z.core.$strip>>>;
|
|
273
42
|
type: z.ZodLiteral<"ComposableScreen">;
|
|
274
43
|
payload: z.ZodObject<{
|
|
275
|
-
elements: z.ZodArray<z.ZodType<UIElement, unknown, z.core.$ZodTypeInternals<UIElement, unknown>>>;
|
|
44
|
+
elements: z.ZodArray<z.ZodType<import("../../screens/types").UIElement, unknown, z.core.$ZodTypeInternals<import("../../screens/types").UIElement, unknown>>>;
|
|
276
45
|
}, z.core.$strip>;
|
|
277
46
|
}, z.core.$strip>;
|
|
278
47
|
export type ComposableScreenStepType = z.infer<typeof ComposableScreenStepTypeSchema>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/steps/ComposableScreen/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/steps/ComposableScreen/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAQxB,cAAc,qBAAqB,CAAC;AAEpC,eAAO,MAAM,iCAAiC;;iBAE5C,CAAC;AAEH,eAAO,MAAM,8BAA8B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAGzC,CAAC;AAEH,MAAM,MAAM,wBAAwB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,8BAA8B,CAAC,CAAC"}
|
|
@@ -1,269 +1,30 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
2
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.ComposableScreenStepTypeSchema = exports.ComposableScreenStepPayloadSchema =
|
|
17
|
+
exports.ComposableScreenStepTypeSchema = exports.ComposableScreenStepPayloadSchema = void 0;
|
|
4
18
|
const zod_1 = require("zod");
|
|
5
19
|
const common_types_1 = require("../common.types");
|
|
6
|
-
const
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
const VideoElement_1 = require("./elements/VideoElement");
|
|
15
|
-
const InputElement_1 = require("./elements/InputElement");
|
|
16
|
-
const ButtonElement_1 = require("./elements/ButtonElement");
|
|
17
|
-
const RadioGroupElement_1 = require("./elements/RadioGroupElement");
|
|
18
|
-
const CheckboxGroupElement_1 = require("./elements/CheckboxGroupElement");
|
|
19
|
-
const DatePickerElement_1 = require("./elements/DatePickerElement");
|
|
20
|
-
const WheelPickerElement_1 = require("./elements/WheelPickerElement");
|
|
21
|
-
const CarouselElement_1 = require("./elements/CarouselElement");
|
|
22
|
-
const ZStackElement_1 = require("./elements/ZStackElement");
|
|
23
|
-
const SafeAreaViewElement_1 = require("./elements/SafeAreaViewElement");
|
|
24
|
-
const ScrollViewElement_1 = require("./elements/ScrollViewElement");
|
|
25
|
-
const KeyboardAvoidingViewElement_1 = require("./elements/KeyboardAvoidingViewElement");
|
|
26
|
-
const ProgressIndicatorElement_1 = require("./elements/ProgressIndicatorElement");
|
|
27
|
-
const AnimatedTextElement_1 = require("./elements/AnimatedTextElement");
|
|
28
|
-
const TypewriterTextElement_1 = require("./elements/TypewriterTextElement");
|
|
29
|
-
const DrawingPadElement_1 = require("./elements/DrawingPadElement");
|
|
30
|
-
const SliderElement_1 = require("./elements/SliderElement");
|
|
31
|
-
var BaseBoxProps_1 = require("./elements/BaseBoxProps");
|
|
32
|
-
Object.defineProperty(exports, "BaseBoxPropsSchema", { enumerable: true, get: function () { return BaseBoxProps_1.BaseBoxPropsSchema; } });
|
|
33
|
-
Object.defineProperty(exports, "GradientBackgroundSchema", { enumerable: true, get: function () { return BaseBoxProps_1.GradientBackgroundSchema; } });
|
|
34
|
-
var TextElement_2 = require("./elements/TextElement");
|
|
35
|
-
Object.defineProperty(exports, "TextSpanSchema", { enumerable: true, get: function () { return TextElement_2.TextSpanSchema; } });
|
|
36
|
-
var ButtonElement_2 = require("./elements/ButtonElement");
|
|
37
|
-
Object.defineProperty(exports, "ButtonActionSchema", { enumerable: true, get: function () { return ButtonElement_2.ButtonActionSchema; } });
|
|
38
|
-
Object.defineProperty(exports, "CustomButtonActionSchema", { enumerable: true, get: function () { return ButtonElement_2.CustomButtonActionSchema; } });
|
|
39
|
-
Object.defineProperty(exports, "SetVariableButtonActionSchema", { enumerable: true, get: function () { return ButtonElement_2.SetVariableButtonActionSchema; } });
|
|
40
|
-
var WheelPickerElement_2 = require("./elements/WheelPickerElement");
|
|
41
|
-
Object.defineProperty(exports, "WheelPickerElementPropsSchema", { enumerable: true, get: function () { return WheelPickerElement_2.WheelPickerElementPropsSchema; } });
|
|
42
|
-
Object.defineProperty(exports, "generateWheelPickerRangeItems", { enumerable: true, get: function () { return WheelPickerElement_2.generateWheelPickerRangeItems; } });
|
|
43
|
-
Object.defineProperty(exports, "resolveWheelPickerItems", { enumerable: true, get: function () { return WheelPickerElement_2.resolveWheelPickerItems; } });
|
|
44
|
-
// The `Text` variant, extracted so `RichText` can restrict its children to
|
|
45
|
-
// Text-only (children: z.array(TextUIElementSchema)) while the union references
|
|
46
|
-
// the same object.
|
|
47
|
-
const TextUIElementSchema = zod_1.z.object({
|
|
48
|
-
id: zod_1.z.string(),
|
|
49
|
-
name: zod_1.z.string().optional(),
|
|
50
|
-
renderWhen: zod_1.z.union([common_types_1.LeafConditionSchema, common_types_1.ConditionGroupSchema]).optional(),
|
|
51
|
-
type: zod_1.z.literal("Text"),
|
|
52
|
-
props: TextElement_1.TextElementPropsSchema,
|
|
53
|
-
});
|
|
54
|
-
const UIElementSchema = zod_1.z.lazy(() => zod_1.z.union([
|
|
55
|
-
zod_1.z.object({
|
|
56
|
-
id: zod_1.z.string(),
|
|
57
|
-
name: zod_1.z.string().optional(),
|
|
58
|
-
renderWhen: zod_1.z.union([common_types_1.LeafConditionSchema, common_types_1.ConditionGroupSchema]).optional(),
|
|
59
|
-
type: zod_1.z.union([zod_1.z.literal("YStack"), zod_1.z.literal("XStack")]),
|
|
60
|
-
props: StackElement_1.StackElementPropsSchema,
|
|
61
|
-
children: zod_1.z.array(UIElementSchema),
|
|
62
|
-
}),
|
|
63
|
-
TextUIElementSchema,
|
|
64
|
-
zod_1.z.object({
|
|
65
|
-
id: zod_1.z.string(),
|
|
66
|
-
name: zod_1.z.string().optional(),
|
|
67
|
-
renderWhen: zod_1.z.union([common_types_1.LeafConditionSchema, common_types_1.ConditionGroupSchema]).optional(),
|
|
68
|
-
type: zod_1.z.literal("RichText"),
|
|
69
|
-
props: RichTextElement_1.RichTextElementPropsSchema,
|
|
70
|
-
children: zod_1.z.array(TextUIElementSchema),
|
|
71
|
-
}),
|
|
72
|
-
zod_1.z.object({
|
|
73
|
-
id: zod_1.z.string(),
|
|
74
|
-
name: zod_1.z.string().optional(),
|
|
75
|
-
renderWhen: zod_1.z.union([common_types_1.LeafConditionSchema, common_types_1.ConditionGroupSchema]).optional(),
|
|
76
|
-
type: zod_1.z.literal("Image"),
|
|
77
|
-
props: ImageElement_1.ImageElementPropsSchema,
|
|
78
|
-
}),
|
|
79
|
-
zod_1.z.object({
|
|
80
|
-
id: zod_1.z.string(),
|
|
81
|
-
name: zod_1.z.string().optional(),
|
|
82
|
-
renderWhen: zod_1.z.union([common_types_1.LeafConditionSchema, common_types_1.ConditionGroupSchema]).optional(),
|
|
83
|
-
type: zod_1.z.literal("ProgressiveBlurImage"),
|
|
84
|
-
props: ProgressiveBlurImageElement_1.ProgressiveBlurImageElementPropsSchema,
|
|
85
|
-
}),
|
|
86
|
-
zod_1.z.object({
|
|
87
|
-
id: zod_1.z.string(),
|
|
88
|
-
name: zod_1.z.string().optional(),
|
|
89
|
-
renderWhen: zod_1.z.union([common_types_1.LeafConditionSchema, common_types_1.ConditionGroupSchema]).optional(),
|
|
90
|
-
type: zod_1.z.literal("Lottie"),
|
|
91
|
-
props: LottieElement_1.LottieElementPropsSchema,
|
|
92
|
-
}),
|
|
93
|
-
zod_1.z.object({
|
|
94
|
-
id: zod_1.z.string(),
|
|
95
|
-
name: zod_1.z.string().optional(),
|
|
96
|
-
renderWhen: zod_1.z.union([common_types_1.LeafConditionSchema, common_types_1.ConditionGroupSchema]).optional(),
|
|
97
|
-
type: zod_1.z.literal("Rive"),
|
|
98
|
-
props: RiveElement_1.RiveElementPropsSchema,
|
|
99
|
-
}),
|
|
100
|
-
zod_1.z.object({
|
|
101
|
-
id: zod_1.z.string(),
|
|
102
|
-
name: zod_1.z.string().optional(),
|
|
103
|
-
renderWhen: zod_1.z.union([common_types_1.LeafConditionSchema, common_types_1.ConditionGroupSchema]).optional(),
|
|
104
|
-
type: zod_1.z.literal("Icon"),
|
|
105
|
-
props: IconElement_1.IconElementPropsSchema,
|
|
106
|
-
}),
|
|
107
|
-
zod_1.z.object({
|
|
108
|
-
id: zod_1.z.string(),
|
|
109
|
-
name: zod_1.z.string().optional(),
|
|
110
|
-
renderWhen: zod_1.z.union([common_types_1.LeafConditionSchema, common_types_1.ConditionGroupSchema]).optional(),
|
|
111
|
-
type: zod_1.z.literal("Video"),
|
|
112
|
-
props: VideoElement_1.VideoElementPropsSchema,
|
|
113
|
-
}),
|
|
114
|
-
zod_1.z.object({
|
|
115
|
-
id: zod_1.z.string(),
|
|
116
|
-
name: zod_1.z.string().optional(),
|
|
117
|
-
renderWhen: zod_1.z.union([common_types_1.LeafConditionSchema, common_types_1.ConditionGroupSchema]).optional(),
|
|
118
|
-
type: zod_1.z.literal("Input"),
|
|
119
|
-
props: InputElement_1.InputElementPropsSchema,
|
|
120
|
-
}),
|
|
121
|
-
zod_1.z.object({
|
|
122
|
-
id: zod_1.z.string(),
|
|
123
|
-
name: zod_1.z.string().optional(),
|
|
124
|
-
renderWhen: zod_1.z.union([common_types_1.LeafConditionSchema, common_types_1.ConditionGroupSchema]).optional(),
|
|
125
|
-
type: zod_1.z.literal("Button"),
|
|
126
|
-
props: ButtonElement_1.ButtonElementPropsSchema,
|
|
127
|
-
}),
|
|
128
|
-
zod_1.z.object({
|
|
129
|
-
id: zod_1.z.string(),
|
|
130
|
-
name: zod_1.z.string().optional(),
|
|
131
|
-
renderWhen: zod_1.z.union([common_types_1.LeafConditionSchema, common_types_1.ConditionGroupSchema]).optional(),
|
|
132
|
-
type: zod_1.z.literal("RadioGroup"),
|
|
133
|
-
props: RadioGroupElement_1.RadioGroupElementPropsSchema,
|
|
134
|
-
}),
|
|
135
|
-
zod_1.z.object({
|
|
136
|
-
id: zod_1.z.string(),
|
|
137
|
-
name: zod_1.z.string().optional(),
|
|
138
|
-
renderWhen: zod_1.z.union([common_types_1.LeafConditionSchema, common_types_1.ConditionGroupSchema]).optional(),
|
|
139
|
-
type: zod_1.z.literal("CheckboxGroup"),
|
|
140
|
-
props: CheckboxGroupElement_1.CheckboxGroupElementPropsSchema,
|
|
141
|
-
}),
|
|
142
|
-
zod_1.z.object({
|
|
143
|
-
id: zod_1.z.string(),
|
|
144
|
-
name: zod_1.z.string().optional(),
|
|
145
|
-
renderWhen: zod_1.z.union([common_types_1.LeafConditionSchema, common_types_1.ConditionGroupSchema]).optional(),
|
|
146
|
-
type: zod_1.z.literal("DatePicker"),
|
|
147
|
-
props: DatePickerElement_1.DatePickerElementPropsSchema,
|
|
148
|
-
}),
|
|
149
|
-
zod_1.z.object({
|
|
150
|
-
id: zod_1.z.string(),
|
|
151
|
-
name: zod_1.z.string().optional(),
|
|
152
|
-
renderWhen: zod_1.z.union([common_types_1.LeafConditionSchema, common_types_1.ConditionGroupSchema]).optional(),
|
|
153
|
-
type: zod_1.z.literal("WheelPicker"),
|
|
154
|
-
props: WheelPickerElement_1.WheelPickerElementPropsSchema,
|
|
155
|
-
}),
|
|
156
|
-
zod_1.z.object({
|
|
157
|
-
id: zod_1.z.string(),
|
|
158
|
-
name: zod_1.z.string().optional(),
|
|
159
|
-
renderWhen: zod_1.z.union([common_types_1.LeafConditionSchema, common_types_1.ConditionGroupSchema]).optional(),
|
|
160
|
-
type: zod_1.z.literal("Carousel"),
|
|
161
|
-
props: CarouselElement_1.CarouselElementPropsSchema,
|
|
162
|
-
children: zod_1.z.array(UIElementSchema),
|
|
163
|
-
}),
|
|
164
|
-
zod_1.z.object({
|
|
165
|
-
id: zod_1.z.string(),
|
|
166
|
-
name: zod_1.z.string().optional(),
|
|
167
|
-
renderWhen: zod_1.z.union([common_types_1.LeafConditionSchema, common_types_1.ConditionGroupSchema]).optional(),
|
|
168
|
-
type: zod_1.z.literal("ZStack"),
|
|
169
|
-
props: ZStackElement_1.ZStackElementPropsSchema,
|
|
170
|
-
children: zod_1.z.array(UIElementSchema),
|
|
171
|
-
}),
|
|
172
|
-
zod_1.z.object({
|
|
173
|
-
id: zod_1.z.string(),
|
|
174
|
-
name: zod_1.z.string().optional(),
|
|
175
|
-
renderWhen: zod_1.z.union([common_types_1.LeafConditionSchema, common_types_1.ConditionGroupSchema]).optional(),
|
|
176
|
-
type: zod_1.z.literal("SafeAreaView"),
|
|
177
|
-
props: SafeAreaViewElement_1.SafeAreaViewElementPropsSchema,
|
|
178
|
-
children: zod_1.z.array(UIElementSchema),
|
|
179
|
-
}),
|
|
180
|
-
zod_1.z.object({
|
|
181
|
-
id: zod_1.z.string(),
|
|
182
|
-
name: zod_1.z.string().optional(),
|
|
183
|
-
renderWhen: zod_1.z.union([common_types_1.LeafConditionSchema, common_types_1.ConditionGroupSchema]).optional(),
|
|
184
|
-
type: zod_1.z.literal("ScrollView"),
|
|
185
|
-
props: ScrollViewElement_1.ScrollViewElementPropsSchema,
|
|
186
|
-
children: zod_1.z.array(UIElementSchema),
|
|
187
|
-
}),
|
|
188
|
-
zod_1.z.object({
|
|
189
|
-
id: zod_1.z.string(),
|
|
190
|
-
name: zod_1.z.string().optional(),
|
|
191
|
-
renderWhen: zod_1.z.union([common_types_1.LeafConditionSchema, common_types_1.ConditionGroupSchema]).optional(),
|
|
192
|
-
type: zod_1.z.literal("KeyboardAvoidingView"),
|
|
193
|
-
props: KeyboardAvoidingViewElement_1.KeyboardAvoidingViewElementPropsSchema,
|
|
194
|
-
children: zod_1.z.array(UIElementSchema),
|
|
195
|
-
}),
|
|
196
|
-
zod_1.z.object({
|
|
197
|
-
id: zod_1.z.string(),
|
|
198
|
-
name: zod_1.z.string().optional(),
|
|
199
|
-
renderWhen: zod_1.z.union([common_types_1.LeafConditionSchema, common_types_1.ConditionGroupSchema]).optional(),
|
|
200
|
-
type: zod_1.z.literal("ProgressIndicator"),
|
|
201
|
-
props: ProgressIndicatorElement_1.ProgressIndicatorElementPropsSchema,
|
|
202
|
-
}),
|
|
203
|
-
zod_1.z.object({
|
|
204
|
-
id: zod_1.z.string(),
|
|
205
|
-
name: zod_1.z.string().optional(),
|
|
206
|
-
renderWhen: zod_1.z.union([common_types_1.LeafConditionSchema, common_types_1.ConditionGroupSchema]).optional(),
|
|
207
|
-
type: zod_1.z.literal("AnimatedText"),
|
|
208
|
-
props: AnimatedTextElement_1.AnimatedTextElementPropsSchema,
|
|
209
|
-
}),
|
|
210
|
-
zod_1.z.object({
|
|
211
|
-
id: zod_1.z.string(),
|
|
212
|
-
name: zod_1.z.string().optional(),
|
|
213
|
-
renderWhen: zod_1.z.union([common_types_1.LeafConditionSchema, common_types_1.ConditionGroupSchema]).optional(),
|
|
214
|
-
type: zod_1.z.literal("TypewriterText"),
|
|
215
|
-
props: TypewriterTextElement_1.TypewriterTextElementPropsSchema,
|
|
216
|
-
}),
|
|
217
|
-
zod_1.z.object({
|
|
218
|
-
id: zod_1.z.string(),
|
|
219
|
-
name: zod_1.z.string().optional(),
|
|
220
|
-
renderWhen: zod_1.z.union([common_types_1.LeafConditionSchema, common_types_1.ConditionGroupSchema]).optional(),
|
|
221
|
-
type: zod_1.z.literal("DrawingPad"),
|
|
222
|
-
props: DrawingPadElement_1.DrawingPadElementPropsSchema,
|
|
223
|
-
}),
|
|
224
|
-
zod_1.z.object({
|
|
225
|
-
id: zod_1.z.string(),
|
|
226
|
-
name: zod_1.z.string().optional(),
|
|
227
|
-
renderWhen: zod_1.z.union([common_types_1.LeafConditionSchema, common_types_1.ConditionGroupSchema]).optional(),
|
|
228
|
-
type: zod_1.z.literal("Slider"),
|
|
229
|
-
props: SliderElement_1.SliderElementPropsSchema,
|
|
230
|
-
}),
|
|
231
|
-
]));
|
|
232
|
-
// Walk a UIElement tree; flag any KeyboardAvoidingView descendant of another KeyboardAvoidingView.
|
|
233
|
-
// RN behavior is undefined when a KAV nests another; KAV adjusts the layout of the host view, and
|
|
234
|
-
// stacking adjusters produces drift and clip artifacts on iOS + double height insets on Android.
|
|
235
|
-
const collectNestedKeyboardAvoidingViews = (nodes, insideKav, out) => {
|
|
236
|
-
for (const node of nodes) {
|
|
237
|
-
if (node.type === "KeyboardAvoidingView") {
|
|
238
|
-
if (insideKav)
|
|
239
|
-
out.push(node.id);
|
|
240
|
-
collectNestedKeyboardAvoidingViews(node.children, true, out);
|
|
241
|
-
continue;
|
|
242
|
-
}
|
|
243
|
-
if (node.type === "YStack" ||
|
|
244
|
-
node.type === "XStack" ||
|
|
245
|
-
node.type === "ZStack" ||
|
|
246
|
-
node.type === "SafeAreaView" ||
|
|
247
|
-
node.type === "ScrollView" ||
|
|
248
|
-
node.type === "Carousel") {
|
|
249
|
-
collectNestedKeyboardAvoidingViews(node.children, insideKav, out);
|
|
250
|
-
}
|
|
251
|
-
}
|
|
252
|
-
};
|
|
253
|
-
exports.ComposableScreenStepPayloadSchema = zod_1.z
|
|
254
|
-
.object({
|
|
255
|
-
elements: zod_1.z.array(UIElementSchema),
|
|
256
|
-
})
|
|
257
|
-
.superRefine((payload, ctx) => {
|
|
258
|
-
const offenders = [];
|
|
259
|
-
collectNestedKeyboardAvoidingViews(payload.elements, false, offenders);
|
|
260
|
-
for (const id of offenders) {
|
|
261
|
-
ctx.addIssue({
|
|
262
|
-
code: zod_1.z.ZodIssueCode.custom,
|
|
263
|
-
path: ["elements"],
|
|
264
|
-
message: `KeyboardAvoidingView (id="${id}") cannot be nested inside another KeyboardAvoidingView.`,
|
|
265
|
-
});
|
|
266
|
-
}
|
|
20
|
+
const types_1 = require("../../screens/types");
|
|
21
|
+
// Everything screen-agnostic now lives in src/screens/types.ts. Re-exported here
|
|
22
|
+
// so every existing import path — including host apps, onboarding-studio, and the
|
|
23
|
+
// documented `dist/steps/ComposableScreen/types.js` validation recipe in
|
|
24
|
+
// CLAUDE.md — keeps resolving.
|
|
25
|
+
__exportStar(require("../../screens/types"), exports);
|
|
26
|
+
exports.ComposableScreenStepPayloadSchema = zod_1.z.object({
|
|
27
|
+
elements: types_1.ScreenElementsSchema,
|
|
267
28
|
});
|
|
268
29
|
exports.ComposableScreenStepTypeSchema = common_types_1.BaseStepTypeSchema.extend({
|
|
269
30
|
type: zod_1.z.literal("ComposableScreen"),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../src/steps/ComposableScreen/types.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../src/steps/ComposableScreen/types.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;AAAA,6BAAwB;AACxB,kDAAqD;AACrD,+CAA2D;AAE3D,iFAAiF;AACjF,kFAAkF;AAClF,yEAAyE;AACzE,+BAA+B;AAC/B,sDAAoC;AAEvB,QAAA,iCAAiC,GAAG,OAAC,CAAC,MAAM,CAAC;IACxD,QAAQ,EAAE,4BAAoB;CAC/B,CAAC,CAAC;AAEU,QAAA,8BAA8B,GAAG,iCAAkB,CAAC,MAAM,CAAC;IACtE,IAAI,EAAE,OAAC,CAAC,OAAO,CAAC,kBAAkB,CAAC;IACnC,OAAO,EAAE,yCAAiC;CAC3C,CAAC,CAAC"}
|
|
@@ -40,6 +40,7 @@ export declare const LoaderStepTypeSchema: z.ZodObject<{
|
|
|
40
40
|
condition: z.ZodDefault<z.ZodNullable<z.ZodUnion<readonly [z.ZodObject<{
|
|
41
41
|
variable: z.ZodString;
|
|
42
42
|
operator: z.ZodEnum<{
|
|
43
|
+
in: "in";
|
|
43
44
|
eq: "eq";
|
|
44
45
|
neq: "neq";
|
|
45
46
|
gt: "gt";
|
|
@@ -47,7 +48,6 @@ export declare const LoaderStepTypeSchema: z.ZodObject<{
|
|
|
47
48
|
gte: "gte";
|
|
48
49
|
lte: "lte";
|
|
49
50
|
contains: "contains";
|
|
50
|
-
in: "in";
|
|
51
51
|
not_in: "not_in";
|
|
52
52
|
is_empty: "is_empty";
|
|
53
53
|
is_not_empty: "is_not_empty";
|
|
@@ -42,6 +42,7 @@ export declare const MediaContentStepTypeSchema: z.ZodObject<{
|
|
|
42
42
|
condition: z.ZodDefault<z.ZodNullable<z.ZodUnion<readonly [z.ZodObject<{
|
|
43
43
|
variable: z.ZodString;
|
|
44
44
|
operator: z.ZodEnum<{
|
|
45
|
+
in: "in";
|
|
45
46
|
eq: "eq";
|
|
46
47
|
neq: "neq";
|
|
47
48
|
gt: "gt";
|
|
@@ -49,7 +50,6 @@ export declare const MediaContentStepTypeSchema: z.ZodObject<{
|
|
|
49
50
|
gte: "gte";
|
|
50
51
|
lte: "lte";
|
|
51
52
|
contains: "contains";
|
|
52
|
-
in: "in";
|
|
53
53
|
not_in: "not_in";
|
|
54
54
|
is_empty: "is_empty";
|
|
55
55
|
is_not_empty: "is_not_empty";
|
|
@@ -38,6 +38,7 @@ export declare const PickerStepTypeSchema: z.ZodObject<{
|
|
|
38
38
|
condition: z.ZodDefault<z.ZodNullable<z.ZodUnion<readonly [z.ZodObject<{
|
|
39
39
|
variable: z.ZodString;
|
|
40
40
|
operator: z.ZodEnum<{
|
|
41
|
+
in: "in";
|
|
41
42
|
eq: "eq";
|
|
42
43
|
neq: "neq";
|
|
43
44
|
gt: "gt";
|
|
@@ -45,7 +46,6 @@ export declare const PickerStepTypeSchema: z.ZodObject<{
|
|
|
45
46
|
gte: "gte";
|
|
46
47
|
lte: "lte";
|
|
47
48
|
contains: "contains";
|
|
48
|
-
in: "in";
|
|
49
49
|
not_in: "not_in";
|
|
50
50
|
is_empty: "is_empty";
|
|
51
51
|
is_not_empty: "is_not_empty";
|