@opengovsg/confetti 0.0.3 → 0.0.5
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/confetti.css +56 -4
- package/build/index.d.ts +47 -183
- package/build/index.js +271 -94
- package/build/internals.d.ts +14 -0
- package/build/internals.js +3 -0
- package/build/routing-DjtQKwsR.js +59 -0
- package/build/types-qVyTr8wu.d.ts +204 -0
- package/package.json +9 -4
package/build/confetti.css
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
:root {
|
|
2
2
|
--confetti-font-scale: 16px;
|
|
3
3
|
/* Define CSS Variables with defaults */
|
|
4
|
-
--confetti-box-padding:
|
|
4
|
+
--confetti-box-padding: 24px;
|
|
5
5
|
--confetti-max-width: 300px;
|
|
6
6
|
--confetti-z-index: 2147483647;
|
|
7
7
|
--confetti-border-color: #e4e4e7;
|
|
@@ -37,8 +37,8 @@
|
|
|
37
37
|
}
|
|
38
38
|
|
|
39
39
|
.confetti-dialog {
|
|
40
|
-
width:
|
|
41
|
-
max-width:
|
|
40
|
+
width: var(--confetti-max-width);
|
|
41
|
+
max-width: 100%;
|
|
42
42
|
background: transparent;
|
|
43
43
|
position: relative;
|
|
44
44
|
|
|
@@ -80,7 +80,7 @@
|
|
|
80
80
|
.confetti {
|
|
81
81
|
font-family: var(--confetti-font-family);
|
|
82
82
|
overflow: hidden;
|
|
83
|
-
padding:
|
|
83
|
+
padding: var(--confetti-box-padding);
|
|
84
84
|
border-radius: var(--confetti-border-radius);
|
|
85
85
|
border: 1px solid var(--confetti-border-color);
|
|
86
86
|
display: flex;
|
|
@@ -179,6 +179,45 @@
|
|
|
179
179
|
}
|
|
180
180
|
}
|
|
181
181
|
|
|
182
|
+
.cf-response-choices-tag {
|
|
183
|
+
flex-direction: row;
|
|
184
|
+
flex-wrap: wrap;
|
|
185
|
+
gap: 8px;
|
|
186
|
+
}
|
|
187
|
+
|
|
188
|
+
.cf-tag-input {
|
|
189
|
+
display: none;
|
|
190
|
+
|
|
191
|
+
&[data-visible='true'] {
|
|
192
|
+
display: inline;
|
|
193
|
+
}
|
|
194
|
+
}
|
|
195
|
+
|
|
196
|
+
.cf-tag {
|
|
197
|
+
border-radius: 8px;
|
|
198
|
+
padding: 6px 12px;
|
|
199
|
+
font-weight: 500;
|
|
200
|
+
font-size: 0.875em;
|
|
201
|
+
transition:
|
|
202
|
+
background 200ms ease-out,
|
|
203
|
+
border-color 200ms ease-out;
|
|
204
|
+
|
|
205
|
+
&[data-selected='true'] {
|
|
206
|
+
background: var(--confetti-indicator-active-bg-color);
|
|
207
|
+
border-color: var(--confetti-indicator-active-bg-color);
|
|
208
|
+
color: var(--confetti-indicator-active-dot-color);
|
|
209
|
+
}
|
|
210
|
+
|
|
211
|
+
&[data-focus-visible='true'] {
|
|
212
|
+
outline: 2px solid var(--confetti-outline-color);
|
|
213
|
+
outline-offset: 2px;
|
|
214
|
+
}
|
|
215
|
+
|
|
216
|
+
&:active {
|
|
217
|
+
scale: 0.96;
|
|
218
|
+
}
|
|
219
|
+
}
|
|
220
|
+
|
|
182
221
|
.cf-radio,
|
|
183
222
|
.cf-checkbox {
|
|
184
223
|
cursor: pointer;
|
|
@@ -335,6 +374,11 @@
|
|
|
335
374
|
font-weight: 500;
|
|
336
375
|
}
|
|
337
376
|
|
|
377
|
+
.cf-label-optional {
|
|
378
|
+
font-weight: 400;
|
|
379
|
+
color: var(--confetti-text-subtle-color);
|
|
380
|
+
}
|
|
381
|
+
|
|
338
382
|
.cf-description {
|
|
339
383
|
font-size: 0.875em;
|
|
340
384
|
line-height: 20px;
|
|
@@ -356,10 +400,17 @@
|
|
|
356
400
|
gap: 4px;
|
|
357
401
|
}
|
|
358
402
|
|
|
403
|
+
.cf-rating-tiff {
|
|
404
|
+
overflow: hidden;
|
|
405
|
+
border-radius: 100%;
|
|
406
|
+
}
|
|
407
|
+
|
|
408
|
+
.cf-rating-tiff,
|
|
359
409
|
.cf-rating-emoji {
|
|
360
410
|
opacity: 0.5;
|
|
361
411
|
}
|
|
362
412
|
|
|
413
|
+
.cf-rating-display-tiff,
|
|
363
414
|
.cf-rating-display-star,
|
|
364
415
|
.cf-rating-display-emoji {
|
|
365
416
|
display: grid;
|
|
@@ -367,6 +418,7 @@
|
|
|
367
418
|
justify-content: space-between;
|
|
368
419
|
gap: 8px;
|
|
369
420
|
|
|
421
|
+
.cf-rating-tiff,
|
|
370
422
|
.cf-rating-emoji,
|
|
371
423
|
.cf-rating-star {
|
|
372
424
|
font-size: 1em;
|
package/build/index.d.ts
CHANGED
|
@@ -1,169 +1,8 @@
|
|
|
1
|
+
import { a as MultiSelectQuestionProperties, c as StatementQuestionProperties, i as PublicGetSurveyOutput, l as TextQuestionProperties, n as ConfettiState, o as RatingQuestionProperties, r as Question, s as SingleSelectQuestionProperties, t as Answer } from "./types-qVyTr8wu.js";
|
|
1
2
|
import * as react0 from "react";
|
|
2
3
|
import { HTMLAttributes, PropsWithChildren } from "react";
|
|
3
|
-
import
|
|
4
|
-
import * as react_jsx_runtime3 from "react/jsx-runtime";
|
|
4
|
+
import * as react_jsx_runtime2 from "react/jsx-runtime";
|
|
5
5
|
|
|
6
|
-
//#region ../validators/src/questions/properties.d.ts
|
|
7
|
-
|
|
8
|
-
declare const ratingQuestionSchema: z.ZodMiniObject<{
|
|
9
|
-
type: z.ZodMiniLiteral<"rating">;
|
|
10
|
-
scale: z.ZodMiniNumber<number>;
|
|
11
|
-
labels: z.ZodMiniOptional<z.ZodMiniObject<{
|
|
12
|
-
lower: z.ZodMiniString<string>;
|
|
13
|
-
upper: z.ZodMiniString<string>;
|
|
14
|
-
}, z.core.$strip>>;
|
|
15
|
-
display: z.ZodMiniOptional<z.ZodMiniLiteral<"number" | "star" | "emoji">>;
|
|
16
|
-
}, z.core.$strip>;
|
|
17
|
-
type RatingQuestion = z.infer<typeof ratingQuestionSchema>;
|
|
18
|
-
declare const textQuestionSchema: z.ZodMiniObject<{
|
|
19
|
-
type: z.ZodMiniLiteral<"open-ended">;
|
|
20
|
-
max: z.ZodMiniNumber<number>;
|
|
21
|
-
}, z.core.$strip>;
|
|
22
|
-
type TextQuestion = z.infer<typeof textQuestionSchema>;
|
|
23
|
-
declare const singleSelectQuestionSchema: z.ZodMiniObject<{
|
|
24
|
-
type: z.ZodMiniLiteral<"single-select">;
|
|
25
|
-
options: z.ZodMiniArray<z.ZodMiniObject<{
|
|
26
|
-
value: z.ZodMiniString<string>;
|
|
27
|
-
description: z.ZodMiniOptional<z.ZodMiniString<string>>;
|
|
28
|
-
}, z.core.$strip>>;
|
|
29
|
-
editable: z.ZodMiniNullable<z.ZodMiniObject<{
|
|
30
|
-
label: z.ZodMiniString<string>;
|
|
31
|
-
max: z.ZodMiniNumber<number>;
|
|
32
|
-
description: z.ZodMiniOptional<z.ZodMiniString<string>>;
|
|
33
|
-
}, z.core.$strip>>;
|
|
34
|
-
}, z.core.$strip>;
|
|
35
|
-
type SingleSelectQuestion = z.infer<typeof singleSelectQuestionSchema>;
|
|
36
|
-
declare const multiSelectQuestionSchema: z.ZodMiniObject<{
|
|
37
|
-
type: z.ZodMiniLiteral<"multi-select">;
|
|
38
|
-
options: z.ZodMiniArray<z.ZodMiniObject<{
|
|
39
|
-
value: z.ZodMiniString<string>;
|
|
40
|
-
description: z.ZodMiniOptional<z.ZodMiniString<string>>;
|
|
41
|
-
}, z.core.$strip>>;
|
|
42
|
-
editable: z.ZodMiniNullable<z.ZodMiniObject<{
|
|
43
|
-
label: z.ZodMiniString<string>;
|
|
44
|
-
max: z.ZodMiniNumber<number>;
|
|
45
|
-
description: z.ZodMiniOptional<z.ZodMiniString<string>>;
|
|
46
|
-
}, z.core.$strip>>;
|
|
47
|
-
max: z.ZodMiniOptional<z.ZodMiniNumber<number>>;
|
|
48
|
-
}, z.core.$strip>;
|
|
49
|
-
type MultiSelectQuestion = z.infer<typeof multiSelectQuestionSchema>;
|
|
50
|
-
//#endregion
|
|
51
|
-
//#region ../validators/src/survey.d.ts
|
|
52
|
-
declare const publicGetSurveyOutputSchema: z.ZodMiniObject<{
|
|
53
|
-
title: z.ZodMiniString<string>;
|
|
54
|
-
description: z.ZodMiniNullable<z.ZodMiniString<string>>;
|
|
55
|
-
questions: z.ZodMiniArray<z.ZodMiniObject<{
|
|
56
|
-
id: z.ZodMiniString<string>;
|
|
57
|
-
title: z.ZodMiniString<string>;
|
|
58
|
-
description: z.ZodMiniNullable<z.ZodMiniString<string>>;
|
|
59
|
-
position: z.ZodMiniNumber<number>;
|
|
60
|
-
required: z.ZodMiniBoolean<boolean>;
|
|
61
|
-
properties: z.ZodMiniDiscriminatedUnion<[z.ZodMiniObject<{
|
|
62
|
-
type: z.ZodMiniLiteral<"rating">;
|
|
63
|
-
scale: z.ZodMiniNumber<number>;
|
|
64
|
-
labels: z.ZodMiniOptional<z.ZodMiniObject<{
|
|
65
|
-
lower: z.ZodMiniString<string>;
|
|
66
|
-
upper: z.ZodMiniString<string>;
|
|
67
|
-
}, z.core.$strip>>;
|
|
68
|
-
display: z.ZodMiniOptional<z.ZodMiniLiteral<"number" | "star" | "emoji">>;
|
|
69
|
-
}, z.core.$strip>, z.ZodMiniObject<{
|
|
70
|
-
type: z.ZodMiniLiteral<"single-select">;
|
|
71
|
-
options: z.ZodMiniArray<z.ZodMiniObject<{
|
|
72
|
-
value: z.ZodMiniString<string>;
|
|
73
|
-
description: z.ZodMiniOptional<z.ZodMiniString<string>>;
|
|
74
|
-
}, z.core.$strip>>;
|
|
75
|
-
editable: z.ZodMiniNullable<z.ZodMiniObject<{
|
|
76
|
-
label: z.ZodMiniString<string>;
|
|
77
|
-
max: z.ZodMiniNumber<number>;
|
|
78
|
-
description: z.ZodMiniOptional<z.ZodMiniString<string>>;
|
|
79
|
-
}, z.core.$strip>>;
|
|
80
|
-
}, z.core.$strip>, z.ZodMiniObject<{
|
|
81
|
-
type: z.ZodMiniLiteral<"open-ended">;
|
|
82
|
-
max: z.ZodMiniNumber<number>;
|
|
83
|
-
}, z.core.$strip>, z.ZodMiniObject<{
|
|
84
|
-
type: z.ZodMiniLiteral<"multi-select">;
|
|
85
|
-
options: z.ZodMiniArray<z.ZodMiniObject<{
|
|
86
|
-
value: z.ZodMiniString<string>;
|
|
87
|
-
description: z.ZodMiniOptional<z.ZodMiniString<string>>;
|
|
88
|
-
}, z.core.$strip>>;
|
|
89
|
-
editable: z.ZodMiniNullable<z.ZodMiniObject<{
|
|
90
|
-
label: z.ZodMiniString<string>;
|
|
91
|
-
max: z.ZodMiniNumber<number>;
|
|
92
|
-
description: z.ZodMiniOptional<z.ZodMiniString<string>>;
|
|
93
|
-
}, z.core.$strip>>;
|
|
94
|
-
max: z.ZodMiniOptional<z.ZodMiniNumber<number>>;
|
|
95
|
-
}, z.core.$strip>], "type">;
|
|
96
|
-
routingLogic: z.ZodMiniDiscriminatedUnion<[z.ZodMiniObject<{
|
|
97
|
-
type: z.ZodMiniLiteral<"always">;
|
|
98
|
-
target: z.ZodMiniDiscriminatedUnion<[z.ZodMiniObject<{
|
|
99
|
-
type: z.ZodMiniLiteral<"next">;
|
|
100
|
-
}, z.core.$strip>, z.ZodMiniObject<{
|
|
101
|
-
type: z.ZodMiniLiteral<"jump">;
|
|
102
|
-
target: z.ZodMiniNumber<number>;
|
|
103
|
-
}, z.core.$strip>, z.ZodMiniObject<{
|
|
104
|
-
type: z.ZodMiniLiteral<"end">;
|
|
105
|
-
}, z.core.$strip>], "type">;
|
|
106
|
-
}, z.core.$strip>, z.ZodMiniObject<{
|
|
107
|
-
type: z.ZodMiniLiteral<"switch">;
|
|
108
|
-
cases: z.ZodMiniArray<z.ZodMiniObject<{
|
|
109
|
-
type: z.ZodMiniLiteral<"binary-operator">;
|
|
110
|
-
operator: z.ZodMiniUnion<readonly [z.ZodMiniLiteral<"equal">, z.ZodMiniLiteral<"not-equal">, z.ZodMiniLiteral<"greater">, z.ZodMiniLiteral<"greater-or-equal">, z.ZodMiniLiteral<"less">, z.ZodMiniLiteral<"less-or-equal">, z.ZodMiniLiteral<"contains">, z.ZodMiniLiteral<"not-contains">]>;
|
|
111
|
-
value: z.ZodMiniObject<{
|
|
112
|
-
type: z.ZodMiniLiteral<"value">;
|
|
113
|
-
value: z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniNumber<number>]>;
|
|
114
|
-
}, z.core.$strip>;
|
|
115
|
-
target: z.ZodMiniDiscriminatedUnion<[z.ZodMiniObject<{
|
|
116
|
-
type: z.ZodMiniLiteral<"next">;
|
|
117
|
-
}, z.core.$strip>, z.ZodMiniObject<{
|
|
118
|
-
type: z.ZodMiniLiteral<"jump">;
|
|
119
|
-
target: z.ZodMiniNumber<number>;
|
|
120
|
-
}, z.core.$strip>, z.ZodMiniObject<{
|
|
121
|
-
type: z.ZodMiniLiteral<"end">;
|
|
122
|
-
}, z.core.$strip>], "type">;
|
|
123
|
-
}, z.core.$strip>>;
|
|
124
|
-
default: z.ZodMiniDiscriminatedUnion<[z.ZodMiniObject<{
|
|
125
|
-
type: z.ZodMiniLiteral<"next">;
|
|
126
|
-
}, z.core.$strip>, z.ZodMiniObject<{
|
|
127
|
-
type: z.ZodMiniLiteral<"jump">;
|
|
128
|
-
target: z.ZodMiniNumber<number>;
|
|
129
|
-
}, z.core.$strip>, z.ZodMiniObject<{
|
|
130
|
-
type: z.ZodMiniLiteral<"end">;
|
|
131
|
-
}, z.core.$strip>], "type">;
|
|
132
|
-
}, z.core.$strip>], "type">;
|
|
133
|
-
}, z.core.$strip>>;
|
|
134
|
-
confirmation: z.ZodMiniObject<{
|
|
135
|
-
title: z.ZodMiniString<string>;
|
|
136
|
-
description: z.ZodMiniString<string>;
|
|
137
|
-
buttonText: z.ZodMiniString<string>;
|
|
138
|
-
}, z.core.$strip>;
|
|
139
|
-
}, z.core.$strip>;
|
|
140
|
-
type PublicGetSurveyOutput = z.infer<typeof publicGetSurveyOutputSchema>;
|
|
141
|
-
//#endregion
|
|
142
|
-
//#region src/core/types.d.ts
|
|
143
|
-
type Question = {
|
|
144
|
-
visible: boolean;
|
|
145
|
-
error?: string;
|
|
146
|
-
} & PublicGetSurveyOutput['questions'][number];
|
|
147
|
-
type Answer = string | number | string[] | undefined;
|
|
148
|
-
interface ConfettiState {
|
|
149
|
-
questions: Question[];
|
|
150
|
-
current: number;
|
|
151
|
-
update: ({
|
|
152
|
-
question,
|
|
153
|
-
answer
|
|
154
|
-
}: {
|
|
155
|
-
question: number;
|
|
156
|
-
answer: Answer;
|
|
157
|
-
}) => {
|
|
158
|
-
next?: number;
|
|
159
|
-
error?: string;
|
|
160
|
-
};
|
|
161
|
-
submit: () => void;
|
|
162
|
-
isCompleted: boolean;
|
|
163
|
-
isSubmitted: boolean;
|
|
164
|
-
errors: Record<Question['id'], string>;
|
|
165
|
-
}
|
|
166
|
-
//#endregion
|
|
167
6
|
//#region src/core/ConfettiController.d.ts
|
|
168
7
|
interface ConfettiControllerProps {
|
|
169
8
|
children: (props: ConfettiState) => React.ReactElement;
|
|
@@ -180,7 +19,7 @@ declare const ConfettiController: ({
|
|
|
180
19
|
shouldAutoSubmit,
|
|
181
20
|
onFinished,
|
|
182
21
|
children
|
|
183
|
-
}: ConfettiControllerProps) =>
|
|
22
|
+
}: ConfettiControllerProps) => react_jsx_runtime2.JSX.Element;
|
|
184
23
|
//#endregion
|
|
185
24
|
//#region src/core/ConfettiProvider.d.ts
|
|
186
25
|
interface ConfettiContextValue {
|
|
@@ -214,7 +53,7 @@ declare const ConfettiProvider: ({
|
|
|
214
53
|
metadata,
|
|
215
54
|
isSurveyVisible: isSurveyVisibleInput,
|
|
216
55
|
apiBaseUrl
|
|
217
|
-
}: ConfettiProviderProps) =>
|
|
56
|
+
}: ConfettiProviderProps) => react_jsx_runtime2.JSX.Element | null;
|
|
218
57
|
declare const useConfetti: () => ConfettiContextValue;
|
|
219
58
|
//#endregion
|
|
220
59
|
//#region src/components/Confetti.d.ts
|
|
@@ -224,7 +63,7 @@ declare const Confetti: ({
|
|
|
224
63
|
onFinished,
|
|
225
64
|
shouldAutoSubmit,
|
|
226
65
|
...props
|
|
227
|
-
}: ConfettiProps & Pick<ConfettiControllerProps, "children" | "shouldAutoSubmit">) =>
|
|
66
|
+
}: ConfettiProps & Pick<ConfettiControllerProps, "children" | "shouldAutoSubmit">) => react_jsx_runtime2.JSX.Element;
|
|
228
67
|
//#endregion
|
|
229
68
|
//#region src/components/ThankYouMessage.d.ts
|
|
230
69
|
interface ThankYouMessageProps {
|
|
@@ -241,7 +80,7 @@ declare const ThankYouMessage: ({
|
|
|
241
80
|
title,
|
|
242
81
|
description,
|
|
243
82
|
classNames
|
|
244
|
-
}: ThankYouMessageProps) =>
|
|
83
|
+
}: ThankYouMessageProps) => react_jsx_runtime2.JSX.Element | null;
|
|
245
84
|
//#endregion
|
|
246
85
|
//#region src/components/container/PopoverContainer.d.ts
|
|
247
86
|
interface PopoverContainerProps {
|
|
@@ -263,7 +102,7 @@ declare const PopoverContainer: ({
|
|
|
263
102
|
containerProps,
|
|
264
103
|
onDismiss,
|
|
265
104
|
closeOnFinishMs
|
|
266
|
-
}: PopoverContainerProps) =>
|
|
105
|
+
}: PopoverContainerProps) => react_jsx_runtime2.JSX.Element;
|
|
267
106
|
//#endregion
|
|
268
107
|
//#region src/components/questions/types.d.ts
|
|
269
108
|
type Question$1 = PublicGetSurveyOutput['questions'][number];
|
|
@@ -286,16 +125,17 @@ declare const SurveyQuestionFactory: ({
|
|
|
286
125
|
question,
|
|
287
126
|
onChange,
|
|
288
127
|
error
|
|
289
|
-
}: SurveyQuestionFactoryProps) =>
|
|
128
|
+
}: SurveyQuestionFactoryProps) => react_jsx_runtime2.JSX.Element;
|
|
290
129
|
//#endregion
|
|
291
130
|
//#region src/components/questions/Rating.d.ts
|
|
292
131
|
interface RatingProps extends BaseFieldProps {
|
|
293
|
-
properties:
|
|
132
|
+
properties: RatingQuestionProperties;
|
|
294
133
|
classNames?: {
|
|
295
134
|
question?: string;
|
|
296
135
|
header?: string;
|
|
297
136
|
title?: string;
|
|
298
137
|
description?: string;
|
|
138
|
+
optionalLabel?: string;
|
|
299
139
|
ratingSection?: string;
|
|
300
140
|
ratingDisplay?: string;
|
|
301
141
|
ratingText?: string;
|
|
@@ -307,6 +147,7 @@ interface RatingProps extends BaseFieldProps {
|
|
|
307
147
|
ratingNumber?: string;
|
|
308
148
|
ratingDisplayEmoji?: string;
|
|
309
149
|
ratingEmoji?: string;
|
|
150
|
+
ratingTiff?: string;
|
|
310
151
|
error?: string;
|
|
311
152
|
};
|
|
312
153
|
}
|
|
@@ -319,15 +160,16 @@ declare const Rating: ({
|
|
|
319
160
|
id,
|
|
320
161
|
error,
|
|
321
162
|
required
|
|
322
|
-
}: RatingProps) =>
|
|
163
|
+
}: RatingProps) => react_jsx_runtime2.JSX.Element;
|
|
323
164
|
//#endregion
|
|
324
165
|
//#region src/components/questions/FreeText.d.ts
|
|
325
166
|
interface FreeTextProps extends BaseFieldProps {
|
|
326
|
-
properties:
|
|
167
|
+
properties: TextQuestionProperties;
|
|
327
168
|
classNames?: {
|
|
328
169
|
question?: string;
|
|
329
170
|
header?: string;
|
|
330
171
|
title?: string;
|
|
172
|
+
optionalLabel?: string;
|
|
331
173
|
description?: string;
|
|
332
174
|
textarea?: string;
|
|
333
175
|
error?: string;
|
|
@@ -342,17 +184,18 @@ declare const FreeText: ({
|
|
|
342
184
|
classNames,
|
|
343
185
|
required,
|
|
344
186
|
error
|
|
345
|
-
}: FreeTextProps) =>
|
|
187
|
+
}: FreeTextProps) => react_jsx_runtime2.JSX.Element;
|
|
346
188
|
//#endregion
|
|
347
189
|
//#region src/components/questions/SingleChoice.d.ts
|
|
348
190
|
interface SingleChoiceProps extends BaseFieldProps {
|
|
349
|
-
properties:
|
|
191
|
+
properties: SingleSelectQuestionProperties;
|
|
350
192
|
classNames?: {
|
|
351
193
|
question?: string;
|
|
352
194
|
header?: string;
|
|
353
195
|
label?: string;
|
|
354
196
|
title?: string;
|
|
355
197
|
description?: string;
|
|
198
|
+
optionalLabel?: string;
|
|
356
199
|
group?: string;
|
|
357
200
|
radio?: string;
|
|
358
201
|
indicator?: string;
|
|
@@ -371,20 +214,23 @@ declare const SingleChoice: ({
|
|
|
371
214
|
id,
|
|
372
215
|
required,
|
|
373
216
|
error
|
|
374
|
-
}: SingleChoiceProps) =>
|
|
217
|
+
}: SingleChoiceProps) => react_jsx_runtime2.JSX.Element;
|
|
375
218
|
//#endregion
|
|
376
219
|
//#region src/components/questions/MultiChoice.d.ts
|
|
377
220
|
interface MultiChoiceProps extends BaseFieldProps {
|
|
378
|
-
properties:
|
|
221
|
+
properties: MultiSelectQuestionProperties;
|
|
379
222
|
classNames?: {
|
|
380
223
|
question?: string;
|
|
381
224
|
header?: string;
|
|
382
225
|
label?: string;
|
|
383
226
|
title?: string;
|
|
384
227
|
description?: string;
|
|
228
|
+
optionalLabel?: string;
|
|
385
229
|
choiceDescription?: string;
|
|
386
230
|
group?: string;
|
|
387
231
|
checkbox?: string;
|
|
232
|
+
tag?: string;
|
|
233
|
+
tagLabel?: string;
|
|
388
234
|
indicator?: string;
|
|
389
235
|
svg?: string;
|
|
390
236
|
othersChoice?: string;
|
|
@@ -401,7 +247,25 @@ declare const MultiChoice: ({
|
|
|
401
247
|
id,
|
|
402
248
|
required,
|
|
403
249
|
error
|
|
404
|
-
}: MultiChoiceProps) =>
|
|
250
|
+
}: MultiChoiceProps) => react_jsx_runtime2.JSX.Element;
|
|
251
|
+
//#endregion
|
|
252
|
+
//#region src/components/questions/Statement.d.ts
|
|
253
|
+
interface StatementProps extends BaseFieldProps {
|
|
254
|
+
properties: StatementQuestionProperties;
|
|
255
|
+
classNames?: {
|
|
256
|
+
question?: string;
|
|
257
|
+
header?: string;
|
|
258
|
+
title?: string;
|
|
259
|
+
description?: string;
|
|
260
|
+
ctaButton?: string;
|
|
261
|
+
};
|
|
262
|
+
}
|
|
263
|
+
declare const Statement: ({
|
|
264
|
+
properties: _properties,
|
|
265
|
+
title,
|
|
266
|
+
description,
|
|
267
|
+
classNames
|
|
268
|
+
}: StatementProps) => react_jsx_runtime2.JSX.Element;
|
|
405
269
|
//#endregion
|
|
406
270
|
//#region src/components/presentation/Flow.d.ts
|
|
407
271
|
type ChildField = (_: {
|
|
@@ -420,7 +284,7 @@ declare const Flow: ({
|
|
|
420
284
|
children,
|
|
421
285
|
question,
|
|
422
286
|
isLastQuestion
|
|
423
|
-
}: FlowProps) =>
|
|
287
|
+
}: FlowProps) => react_jsx_runtime2.JSX.Element;
|
|
424
288
|
//#endregion
|
|
425
289
|
//#region src/components/presentation/Embed.d.ts
|
|
426
290
|
declare const Embed: ({
|
|
@@ -430,10 +294,10 @@ declare const Embed: ({
|
|
|
430
294
|
}: PropsWithChildren<{
|
|
431
295
|
isCompleted: boolean;
|
|
432
296
|
onSubmit: () => void;
|
|
433
|
-
}>) =>
|
|
297
|
+
}>) => react_jsx_runtime2.JSX.Element;
|
|
434
298
|
//#endregion
|
|
435
299
|
//#region src/templates/EmbeddedConfetti.d.ts
|
|
436
|
-
declare const EmbeddedConfetti: (props: ConfettiProps) =>
|
|
300
|
+
declare const EmbeddedConfetti: (props: ConfettiProps) => react_jsx_runtime2.JSX.Element;
|
|
437
301
|
//#endregion
|
|
438
302
|
//#region src/templates/PopoverConfetti.d.ts
|
|
439
303
|
interface PopoverConfettiProps extends ConfettiProps {
|
|
@@ -448,10 +312,10 @@ interface PopoverConfettiProps extends ConfettiProps {
|
|
|
448
312
|
declare const PopoverConfetti: ({
|
|
449
313
|
closeOnFinishMs,
|
|
450
314
|
...props
|
|
451
|
-
}: PopoverConfettiProps) =>
|
|
315
|
+
}: PopoverConfettiProps) => react_jsx_runtime2.JSX.Element;
|
|
452
316
|
//#endregion
|
|
453
317
|
//#region src/templates/StepperConfetti.d.ts
|
|
454
|
-
declare const StepperConfetti: (props: ConfettiProps) =>
|
|
318
|
+
declare const StepperConfetti: (props: ConfettiProps) => react_jsx_runtime2.JSX.Element;
|
|
455
319
|
//#endregion
|
|
456
320
|
//#region src/hooks/useVisibleAfterDelay.d.ts
|
|
457
321
|
interface UseVisibleAfterDelayOptions {
|
|
@@ -493,5 +357,5 @@ declare const useVisibleAfterScroll: ({
|
|
|
493
357
|
isVisible: boolean;
|
|
494
358
|
};
|
|
495
359
|
//#endregion
|
|
496
|
-
export { type Answer, Confetti, ConfettiContext, ConfettiController, type ConfettiControllerProps, type ConfettiProps, ConfettiProvider, type ConfettiProviderProps, type ConfettiState, Embed, EmbeddedConfetti, Flow, FreeText, type FreeTextProps, MultiChoice, type MultiChoiceProps, PopoverConfetti, PopoverContainer, type PopoverContainerProps, type Question, Rating, type RatingProps, SingleChoice, type SingleChoiceProps, StepperConfetti, SurveyQuestionFactory, type SurveyQuestionFactoryProps, ThankYouMessage, useConfetti, useVisibleAfterDelay, useVisibleAfterPageVisits, useVisibleAfterScroll, useVisibleAfterSessionPageVisits };
|
|
360
|
+
export { type Answer, Confetti, ConfettiContext, ConfettiController, type ConfettiControllerProps, type ConfettiProps, ConfettiProvider, type ConfettiProviderProps, type ConfettiState, Embed, EmbeddedConfetti, Flow, FreeText, type FreeTextProps, MultiChoice, type MultiChoiceProps, PopoverConfetti, PopoverContainer, type PopoverContainerProps, type Question, Rating, type RatingProps, SingleChoice, type SingleChoiceProps, Statement, type StatementProps, StepperConfetti, SurveyQuestionFactory, type SurveyQuestionFactoryProps, ThankYouMessage, useConfetti, useVisibleAfterDelay, useVisibleAfterPageVisits, useVisibleAfterScroll, useVisibleAfterSessionPageVisits };
|
|
497
361
|
//# sourceMappingURL=index.d.ts.map
|