@wise/dynamic-flow-types 3.2.0 → 3.3.1
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/build/main.js +54 -24
- package/build/main.mjs +54 -24
- package/build/next/index.d.ts +20 -18
- package/build/next/layout/DecisionLayoutOption.d.ts +18 -0
- package/build/next/layout/ListLayoutItem.d.ts +26 -5
- package/build/next/layout/ReviewLayoutField.d.ts +30 -0
- package/build/next/misc/AdditionalInfo.d.ts +18 -0
- package/build/next/misc/InlineAlert.d.ts +14 -0
- package/build/next/misc/SupportingValues.d.ts +14 -0
- package/build/renderers/DecisionRendererProps.d.ts +7 -1
- package/build/renderers/ExternalConfirmationRendererProps.d.ts +9 -0
- package/build/renderers/{SectionRendererProps.d.ts → FormSectionRendererProps.d.ts} +2 -2
- package/build/renderers/ListRendererProps.d.ts +12 -1
- package/build/renderers/RendererProps.d.ts +4 -3
- package/build/renderers/ReviewRendererProps.d.ts +13 -1
- package/build/renderers/RootRendererProps.d.ts +2 -2
- package/build/renderers/constants.d.ts +13 -0
- package/build/renderers/index.d.ts +13 -12
- package/build/zod/schemas.d.ts +31 -113
- package/build/zod/schemas.ts +391 -355
- package/package.json +1 -1
|
@@ -1,4 +1,6 @@
|
|
|
1
|
-
import { Margin } from './constants';
|
|
1
|
+
import { AdditionalInfo, InlineAlert, Margin } from './constants';
|
|
2
|
+
import { Icon } from './Icon';
|
|
3
|
+
import { Image } from './Image';
|
|
2
4
|
import { BaseRendererProps } from './RendererProps';
|
|
3
5
|
export type ReviewRendererProps = BaseRendererProps & {
|
|
4
6
|
type: 'review';
|
|
@@ -14,6 +16,16 @@ export type ReviewField = {
|
|
|
14
16
|
value: string;
|
|
15
17
|
rawValue?: string;
|
|
16
18
|
tag?: string;
|
|
19
|
+
/** @experimental This feature may be changed in the future without notice. */
|
|
20
|
+
additionalInfo?: AdditionalInfo;
|
|
21
|
+
/** @experimental This feature may be changed in the future without notice. */
|
|
22
|
+
inlineAlert?: InlineAlert;
|
|
23
|
+
/** @experimental This feature may be changed in the future without notice. */
|
|
24
|
+
callToAction?: ReviewCallToAction;
|
|
25
|
+
/** @experimental This feature may be changed in the future without notice. */
|
|
26
|
+
icon?: Icon;
|
|
27
|
+
/** @experimental This feature may be changed in the future without notice. */
|
|
28
|
+
image?: Image;
|
|
17
29
|
};
|
|
18
30
|
export type ReviewCallToAction = {
|
|
19
31
|
accessibilityDescription?: string;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
|
-
import { RendererProps } from './RendererProps';
|
|
3
|
-
export type RootRendererProps = {
|
|
2
|
+
import { BaseRendererProps, RendererProps } from './RendererProps';
|
|
3
|
+
export type RootRendererProps = BaseRendererProps & {
|
|
4
4
|
type: 'root';
|
|
5
5
|
uid: string;
|
|
6
6
|
children: ReactNode;
|
|
@@ -2,3 +2,16 @@ export type Align = 'start' | 'center' | 'end';
|
|
|
2
2
|
export type Autocapitalization = 'none' | 'sentences' | 'words' | 'characters';
|
|
3
3
|
export type Context = 'positive' | 'negative' | 'warning' | 'neutral';
|
|
4
4
|
export type { Margin, Size } from '../next';
|
|
5
|
+
export type AdditionalInfo = {
|
|
6
|
+
text: string;
|
|
7
|
+
accessibilityDescription?: string;
|
|
8
|
+
onClick?: () => void;
|
|
9
|
+
};
|
|
10
|
+
export type InlineAlert = {
|
|
11
|
+
content: string;
|
|
12
|
+
context?: Context;
|
|
13
|
+
};
|
|
14
|
+
export type SupportingValues = {
|
|
15
|
+
value?: string;
|
|
16
|
+
subvalue?: string;
|
|
17
|
+
};
|
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
export type {
|
|
2
|
-
export type { CheckboxInputRendererProps } from './CheckboxInputRendererProps';
|
|
1
|
+
export type { AlertCallToAction, AlertRendererProps } from './AlertRendererProps';
|
|
3
2
|
export type { BoxRendererProps } from './BoxRendererProps';
|
|
4
3
|
export type { ButtonRendererProps } from './ButtonRendererProps';
|
|
4
|
+
export type { CheckboxInputRendererProps } from './CheckboxInputRendererProps';
|
|
5
5
|
export type { ColumnsRendererProps } from './ColumnsRendererProps';
|
|
6
6
|
export type { CoreContainerRendererProps } from './CoreContainerRendererProps';
|
|
7
7
|
export type { DateInputRendererProps } from './DateInputRendererProps';
|
|
8
|
-
export type {
|
|
8
|
+
export type { DecisionOption, DecisionRendererProps } from './DecisionRendererProps';
|
|
9
9
|
export type { DividerRendererProps } from './DividerRendererProps';
|
|
10
|
+
export type { ExternalConfirmationRendererProps } from './ExternalConfirmationRendererProps';
|
|
10
11
|
export type { FormRendererProps } from './FormRendererProps';
|
|
11
|
-
export type { SectionRendererProps } from './SectionRendererProps';
|
|
12
12
|
export type { HeadingRendererProps } from './HeadingRendererProps';
|
|
13
13
|
export type { HiddenRendererProps } from './HiddenRendererProps';
|
|
14
14
|
export type { ImageRendererProps } from './ImageRendererProps';
|
|
15
|
-
export type {
|
|
15
|
+
export type { InstructionItem, InstructionsRendererProps } from './InstructionsRendererProps';
|
|
16
16
|
export type { IntegerInputRendererProps } from './IntegerInputRendererProps';
|
|
17
17
|
export type { ListRendererProps } from './ListRendererProps';
|
|
18
18
|
export type { LoadingIndicatorRendererProps } from './LoadingIndicatorRendererProps';
|
|
@@ -23,17 +23,18 @@ export type { MultiSelectInputRendererProps } from './MultiSelectInputRendererPr
|
|
|
23
23
|
export type { MultiUploadInputRendererProps } from './MultiUploadInputRendererProps';
|
|
24
24
|
export type { NumberInputRendererProps } from './NumberInputRendererProps';
|
|
25
25
|
export type { ParagraphRendererProps } from './ParagraphRendererProps';
|
|
26
|
-
export type {
|
|
27
|
-
export type {
|
|
26
|
+
export type { RepeatableItemRendererProps, RepeatableRendererProps } from './RepeatableRendererProps';
|
|
27
|
+
export type { ReviewCallToAction, ReviewField, ReviewRendererProps } from './ReviewRendererProps';
|
|
28
28
|
export type { RootRendererProps } from './RootRendererProps';
|
|
29
|
-
export type {
|
|
30
|
-
export type {
|
|
31
|
-
export type {
|
|
32
|
-
export type {
|
|
29
|
+
export type { ErrorSearchState, NoResultsSearchState, PendingSearchState, ResultsSearchState, SearchRendererProps, SearchResult, SearchState } from './SearchRendererProps';
|
|
30
|
+
export type { FormSectionRendererProps } from './FormSectionRendererProps';
|
|
31
|
+
export type { SelectInputRendererOption, SelectInputRendererProps } from './SelectInputRendererProps';
|
|
32
|
+
export type { StatusListItem, StatusListItemCallToAction, StatusListItemStatus, StatusListRendererProps } from './StatusListRendererProps';
|
|
33
|
+
export type { AnalyticsEventDispatcher, LoadingState, StepRendererProps } from './StepRendererProps';
|
|
33
34
|
export type { TextInputRendererProps } from './TextInputRendererProps';
|
|
34
35
|
export type { UploadInputRendererProps } from './UploadInputRendererProps';
|
|
35
36
|
export type { ValidationResult } from './BaseInputRendererProps';
|
|
36
37
|
export type { Align, Context, Margin, Size } from './constants';
|
|
37
38
|
export type { Icon } from './Icon';
|
|
38
39
|
export type { Image } from './Image';
|
|
39
|
-
export type {
|
|
40
|
+
export type { Renderer, RendererProps, Renderers, RenderFunction } from './RendererProps';
|
package/build/zod/schemas.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
-
import type { JsonElement,
|
|
2
|
+
import type { JsonElement, AdditionalInfo, Behavior, ReviewLayoutCallToAction, AlertLayout, AlertLayoutCallToAction, ListLayout, ListLayoutCallToAction, ListLayoutItem, DecisionLayout, DecisionLayoutOption, StatusListLayout, StatusListLayoutItem, ItemCallToAction, Layout, BoxLayout, ButtonLayout, ColumnsLayout, ModalLayout, ReviewLayout, ReviewLayoutField, ModalLayoutContent, ModalResponseBody, Step, Schema, Polling, LinkHandler, AllOfSchema, ArraySchema, BlobSchema, BooleanSchema, ConstSchema, IntegerSchema, NumberSchema, ObjectSchema, OneOfSchema, StringSchema, ArraySchemaList, PersistAsync, ArraySchemaTuple, PollingOnError, ModalBehavior } from '../next';
|
|
3
3
|
export declare const imageSchema: z.ZodObject<{
|
|
4
4
|
text: z.ZodOptional<z.ZodString>;
|
|
5
5
|
url: z.ZodOptional<z.ZodString>;
|
|
@@ -24,7 +24,27 @@ export declare const iconNamedSchema: z.ZodObject<{
|
|
|
24
24
|
}, {
|
|
25
25
|
name: string;
|
|
26
26
|
}>;
|
|
27
|
+
export declare const supportingValuesSchema: z.ZodObject<{
|
|
28
|
+
value: z.ZodOptional<z.ZodString>;
|
|
29
|
+
subvalue: z.ZodOptional<z.ZodString>;
|
|
30
|
+
}, "strip", z.ZodTypeAny, {
|
|
31
|
+
value?: string | undefined;
|
|
32
|
+
subvalue?: string | undefined;
|
|
33
|
+
}, {
|
|
34
|
+
value?: string | undefined;
|
|
35
|
+
subvalue?: string | undefined;
|
|
36
|
+
}>;
|
|
27
37
|
export declare const contextSchema: z.ZodUnion<[z.ZodLiteral<"positive">, z.ZodLiteral<"neutral">, z.ZodLiteral<"warning">, z.ZodLiteral<"negative">, z.ZodLiteral<"success">, z.ZodLiteral<"failure">, z.ZodLiteral<"info">, z.ZodLiteral<"primary">]>;
|
|
38
|
+
export declare const inlineAlertSchema: z.ZodObject<{
|
|
39
|
+
content: z.ZodString;
|
|
40
|
+
context: z.ZodOptional<z.ZodUnion<[z.ZodLiteral<"positive">, z.ZodLiteral<"neutral">, z.ZodLiteral<"warning">, z.ZodLiteral<"negative">, z.ZodLiteral<"success">, z.ZodLiteral<"failure">, z.ZodLiteral<"info">, z.ZodLiteral<"primary">]>>;
|
|
41
|
+
}, "strip", z.ZodTypeAny, {
|
|
42
|
+
content: string;
|
|
43
|
+
context?: "neutral" | "warning" | "positive" | "negative" | "success" | "failure" | "info" | "primary" | undefined;
|
|
44
|
+
}, {
|
|
45
|
+
content: string;
|
|
46
|
+
context?: "neutral" | "warning" | "positive" | "negative" | "success" | "failure" | "info" | "primary" | undefined;
|
|
47
|
+
}>;
|
|
28
48
|
export declare const iconTextSchema: z.ZodObject<{
|
|
29
49
|
text: z.ZodString;
|
|
30
50
|
}, "strip", z.ZodTypeAny, {
|
|
@@ -136,30 +156,30 @@ export declare const imageLayoutSchema: z.ZodObject<{
|
|
|
136
156
|
control?: string | undefined;
|
|
137
157
|
text?: string | undefined;
|
|
138
158
|
accessibilityDescription?: string | undefined;
|
|
139
|
-
size?: "xs" | "sm" | "md" | "lg" | "xl" | undefined;
|
|
140
|
-
margin?: "xs" | "sm" | "md" | "lg" | "xl" | undefined;
|
|
141
|
-
align?: "left" | "right" | "center" | undefined;
|
|
142
159
|
content?: {
|
|
143
160
|
url?: string | undefined;
|
|
144
161
|
text?: string | undefined;
|
|
145
162
|
uri?: string | undefined;
|
|
146
163
|
accessibilityDescription?: string | undefined;
|
|
147
164
|
} | undefined;
|
|
165
|
+
size?: "xs" | "sm" | "md" | "lg" | "xl" | undefined;
|
|
166
|
+
margin?: "xs" | "sm" | "md" | "lg" | "xl" | undefined;
|
|
167
|
+
align?: "left" | "right" | "center" | undefined;
|
|
148
168
|
}, {
|
|
149
169
|
type: "image";
|
|
150
170
|
url?: string | undefined;
|
|
151
171
|
control?: string | undefined;
|
|
152
172
|
text?: string | undefined;
|
|
153
173
|
accessibilityDescription?: string | undefined;
|
|
154
|
-
size?: "xs" | "sm" | "md" | "lg" | "xl" | undefined;
|
|
155
|
-
margin?: "xs" | "sm" | "md" | "lg" | "xl" | undefined;
|
|
156
|
-
align?: "left" | "right" | "center" | undefined;
|
|
157
174
|
content?: {
|
|
158
175
|
url?: string | undefined;
|
|
159
176
|
text?: string | undefined;
|
|
160
177
|
uri?: string | undefined;
|
|
161
178
|
accessibilityDescription?: string | undefined;
|
|
162
179
|
} | undefined;
|
|
180
|
+
size?: "xs" | "sm" | "md" | "lg" | "xl" | undefined;
|
|
181
|
+
margin?: "xs" | "sm" | "md" | "lg" | "xl" | undefined;
|
|
182
|
+
align?: "left" | "right" | "center" | undefined;
|
|
163
183
|
}>;
|
|
164
184
|
export declare const statusListLayoutStatusSchema: z.ZodUnion<[z.ZodLiteral<"not-done">, z.ZodLiteral<"pending">, z.ZodLiteral<"done">]>;
|
|
165
185
|
export declare const instructionsLayoutItemSchema: z.ZodObject<{
|
|
@@ -666,82 +686,6 @@ export declare const actionSchema: z.ZodObject<{
|
|
|
666
686
|
data?: JsonElement | undefined;
|
|
667
687
|
skipValidation?: boolean | undefined;
|
|
668
688
|
}>;
|
|
669
|
-
export declare const listLayoutItemSchema: z.ZodObject<{
|
|
670
|
-
description: z.ZodOptional<z.ZodString>;
|
|
671
|
-
status: z.ZodOptional<z.ZodUnion<[z.ZodLiteral<"warning">, z.ZodLiteral<"neutral">, z.ZodLiteral<"positive">]>>;
|
|
672
|
-
icon: z.ZodOptional<z.ZodUnion<[z.ZodObject<{
|
|
673
|
-
name: z.ZodString;
|
|
674
|
-
}, "strip", z.ZodTypeAny, {
|
|
675
|
-
name: string;
|
|
676
|
-
}, {
|
|
677
|
-
name: string;
|
|
678
|
-
}>, z.ZodObject<{
|
|
679
|
-
text: z.ZodString;
|
|
680
|
-
}, "strip", z.ZodTypeAny, {
|
|
681
|
-
text: string;
|
|
682
|
-
}, {
|
|
683
|
-
text: string;
|
|
684
|
-
}>]>>;
|
|
685
|
-
image: z.ZodOptional<z.ZodObject<{
|
|
686
|
-
text: z.ZodOptional<z.ZodString>;
|
|
687
|
-
url: z.ZodOptional<z.ZodString>;
|
|
688
|
-
uri: z.ZodOptional<z.ZodString>;
|
|
689
|
-
accessibilityDescription: z.ZodOptional<z.ZodString>;
|
|
690
|
-
}, "strip", z.ZodTypeAny, {
|
|
691
|
-
url?: string | undefined;
|
|
692
|
-
text?: string | undefined;
|
|
693
|
-
uri?: string | undefined;
|
|
694
|
-
accessibilityDescription?: string | undefined;
|
|
695
|
-
}, {
|
|
696
|
-
url?: string | undefined;
|
|
697
|
-
text?: string | undefined;
|
|
698
|
-
uri?: string | undefined;
|
|
699
|
-
accessibilityDescription?: string | undefined;
|
|
700
|
-
}>>;
|
|
701
|
-
title: z.ZodOptional<z.ZodString>;
|
|
702
|
-
subtitle: z.ZodOptional<z.ZodString>;
|
|
703
|
-
value: z.ZodOptional<z.ZodString>;
|
|
704
|
-
subvalue: z.ZodOptional<z.ZodString>;
|
|
705
|
-
tag: z.ZodOptional<z.ZodString>;
|
|
706
|
-
}, "strip", z.ZodTypeAny, {
|
|
707
|
-
image?: {
|
|
708
|
-
url?: string | undefined;
|
|
709
|
-
text?: string | undefined;
|
|
710
|
-
uri?: string | undefined;
|
|
711
|
-
accessibilityDescription?: string | undefined;
|
|
712
|
-
} | undefined;
|
|
713
|
-
description?: string | undefined;
|
|
714
|
-
icon?: {
|
|
715
|
-
name: string;
|
|
716
|
-
} | {
|
|
717
|
-
text: string;
|
|
718
|
-
} | undefined;
|
|
719
|
-
title?: string | undefined;
|
|
720
|
-
value?: string | undefined;
|
|
721
|
-
status?: "neutral" | "warning" | "positive" | undefined;
|
|
722
|
-
tag?: string | undefined;
|
|
723
|
-
subtitle?: string | undefined;
|
|
724
|
-
subvalue?: string | undefined;
|
|
725
|
-
}, {
|
|
726
|
-
image?: {
|
|
727
|
-
url?: string | undefined;
|
|
728
|
-
text?: string | undefined;
|
|
729
|
-
uri?: string | undefined;
|
|
730
|
-
accessibilityDescription?: string | undefined;
|
|
731
|
-
} | undefined;
|
|
732
|
-
description?: string | undefined;
|
|
733
|
-
icon?: {
|
|
734
|
-
name: string;
|
|
735
|
-
} | {
|
|
736
|
-
text: string;
|
|
737
|
-
} | undefined;
|
|
738
|
-
title?: string | undefined;
|
|
739
|
-
value?: string | undefined;
|
|
740
|
-
status?: "neutral" | "warning" | "positive" | undefined;
|
|
741
|
-
tag?: string | undefined;
|
|
742
|
-
subtitle?: string | undefined;
|
|
743
|
-
subvalue?: string | undefined;
|
|
744
|
-
}>;
|
|
745
689
|
export declare const instructionsLayoutSchema: z.ZodObject<{
|
|
746
690
|
type: z.ZodLiteral<"instructions">;
|
|
747
691
|
title: z.ZodOptional<z.ZodString>;
|
|
@@ -781,35 +725,6 @@ export declare const instructionsLayoutSchema: z.ZodObject<{
|
|
|
781
725
|
control?: string | undefined;
|
|
782
726
|
margin?: "xs" | "sm" | "md" | "lg" | "xl" | undefined;
|
|
783
727
|
}>;
|
|
784
|
-
export declare const reviewLayoutFieldSchema: z.ZodObject<{
|
|
785
|
-
label: z.ZodString;
|
|
786
|
-
value: z.ZodString;
|
|
787
|
-
rawValue: z.ZodOptional<z.ZodString>;
|
|
788
|
-
help: z.ZodOptional<z.ZodObject<{
|
|
789
|
-
markdown: z.ZodString;
|
|
790
|
-
}, "strip", z.ZodTypeAny, {
|
|
791
|
-
markdown: string;
|
|
792
|
-
}, {
|
|
793
|
-
markdown: string;
|
|
794
|
-
}>>;
|
|
795
|
-
tag: z.ZodOptional<z.ZodString>;
|
|
796
|
-
}, "strip", z.ZodTypeAny, {
|
|
797
|
-
value: string;
|
|
798
|
-
label: string;
|
|
799
|
-
help?: {
|
|
800
|
-
markdown: string;
|
|
801
|
-
} | undefined;
|
|
802
|
-
tag?: string | undefined;
|
|
803
|
-
rawValue?: string | undefined;
|
|
804
|
-
}, {
|
|
805
|
-
value: string;
|
|
806
|
-
label: string;
|
|
807
|
-
help?: {
|
|
808
|
-
markdown: string;
|
|
809
|
-
} | undefined;
|
|
810
|
-
tag?: string | undefined;
|
|
811
|
-
rawValue?: string | undefined;
|
|
812
|
-
}>;
|
|
813
728
|
export declare const searchResultSearchSchema: z.ZodObject<{
|
|
814
729
|
type: z.ZodLiteral<"search">;
|
|
815
730
|
title: z.ZodString;
|
|
@@ -2288,12 +2203,14 @@ export declare const searchResponseBodySchema: z.ZodObject<{
|
|
|
2288
2203
|
} | undefined;
|
|
2289
2204
|
})[];
|
|
2290
2205
|
}>;
|
|
2291
|
-
export declare const
|
|
2206
|
+
export declare const additionalInfoSchema: z.ZodSchema<AdditionalInfo>;
|
|
2292
2207
|
export declare const behaviorSchema: z.ZodSchema<Behavior>;
|
|
2208
|
+
export declare const reviewLayoutCallToActionSchema: z.ZodSchema<ReviewLayoutCallToAction>;
|
|
2293
2209
|
export declare const alertLayoutSchema: z.ZodSchema<AlertLayout>;
|
|
2294
2210
|
export declare const alertLayoutCallToActionSchema: z.ZodSchema<AlertLayoutCallToAction>;
|
|
2295
2211
|
export declare const listLayoutSchema: z.ZodSchema<ListLayout>;
|
|
2296
2212
|
export declare const listLayoutCallToActionSchema: z.ZodSchema<ListLayoutCallToAction>;
|
|
2213
|
+
export declare const listLayoutItemSchema: z.ZodSchema<ListLayoutItem>;
|
|
2297
2214
|
export declare const decisionLayoutSchema: z.ZodSchema<DecisionLayout>;
|
|
2298
2215
|
export declare const decisionLayoutOptionSchema: z.ZodSchema<DecisionLayoutOption>;
|
|
2299
2216
|
export declare const statusListLayoutSchema: z.ZodSchema<StatusListLayout>;
|
|
@@ -2305,6 +2222,7 @@ export declare const buttonLayoutSchema: z.ZodSchema<ButtonLayout>;
|
|
|
2305
2222
|
export declare const columnsLayoutSchema: z.ZodSchema<ColumnsLayout>;
|
|
2306
2223
|
export declare const modalLayoutSchema: z.ZodSchema<ModalLayout>;
|
|
2307
2224
|
export declare const reviewLayoutSchema: z.ZodSchema<ReviewLayout>;
|
|
2225
|
+
export declare const reviewLayoutFieldSchema: z.ZodSchema<ReviewLayoutField>;
|
|
2308
2226
|
export declare const modalLayoutContentSchema: z.ZodSchema<ModalLayoutContent>;
|
|
2309
2227
|
export declare const modalResponseBodySchema: z.ZodSchema<ModalResponseBody>;
|
|
2310
2228
|
export declare const stepSchema: z.ZodSchema<Step>;
|