@viamedici-spc/configurator-framer 0.1.0-alpha0000
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.cjs +437 -0
- package/dist/index.d.ts +391 -0
- package/dist/index.js +5100 -0
- package/package.json +86 -0
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,391 @@
|
|
|
1
|
+
import { ChoiceValue } from '@viamedici-spc/configurator-ts';
|
|
2
|
+
import { ChoiceValueId } from '@viamedici-spc/configurator-ts';
|
|
3
|
+
import { ComponentType } from 'react';
|
|
4
|
+
import { CSSProperties } from 'react';
|
|
5
|
+
import { GlobalAttributeId } from '@viamedici-spc/configurator-ts';
|
|
6
|
+
import { JSX as JSX_2 } from 'react/jsx-runtime';
|
|
7
|
+
import NumericFormat from 'react-number-format';
|
|
8
|
+
import { PropsWithChildren } from 'react';
|
|
9
|
+
import { PropsWithoutRef } from 'react';
|
|
10
|
+
import { default as React_2 } from 'react';
|
|
11
|
+
import { ReactNode } from 'react';
|
|
12
|
+
import { RefAttributes } from 'react';
|
|
13
|
+
|
|
14
|
+
declare type AttributeIdProps = {
|
|
15
|
+
attributeId: string;
|
|
16
|
+
componentPath: string;
|
|
17
|
+
sharedConfigurationModel: string;
|
|
18
|
+
};
|
|
19
|
+
|
|
20
|
+
/**
|
|
21
|
+
* @framerIntrinsicWidth 300
|
|
22
|
+
* @framerIntrinsicHeight 35
|
|
23
|
+
*
|
|
24
|
+
* @framerSupportedLayoutWidth any
|
|
25
|
+
* @framerSupportedLayoutHeight fixed
|
|
26
|
+
*/
|
|
27
|
+
export declare const BooleanSelect: ComponentType<Omit<Omit<Omit<AttributeIdProps & PaddingProps & BorderProps & {
|
|
28
|
+
fill: string;
|
|
29
|
+
} & TextProps & ExplainProps & {
|
|
30
|
+
style: CSSProperties;
|
|
31
|
+
implicitLabelPrefix: string;
|
|
32
|
+
unsatisfiedColors: InputStateColors;
|
|
33
|
+
implicitSelectedColors: InputStateColors;
|
|
34
|
+
} & {
|
|
35
|
+
resetLabel: string;
|
|
36
|
+
appearance: "none" | "auto";
|
|
37
|
+
textAlign: "center" | "end" | "start" | "initial";
|
|
38
|
+
} & {
|
|
39
|
+
trueLabel?: string;
|
|
40
|
+
falseLabel?: string;
|
|
41
|
+
} & RefAttributes<HTMLSelectElement>, "ref"> & RefAttributes<unknown>, "ref"> & RefAttributes<unknown>, "ref"> & RefAttributes<unknown>>;
|
|
42
|
+
|
|
43
|
+
declare type BorderProps = {
|
|
44
|
+
radius: number;
|
|
45
|
+
border: {
|
|
46
|
+
color: string;
|
|
47
|
+
width: number;
|
|
48
|
+
isMixedWidth: boolean;
|
|
49
|
+
widthTop: number;
|
|
50
|
+
widthRight: number;
|
|
51
|
+
widthBottom: number;
|
|
52
|
+
widthLeft: number;
|
|
53
|
+
};
|
|
54
|
+
};
|
|
55
|
+
|
|
56
|
+
/**
|
|
57
|
+
* @framerIntrinsicWidth 300
|
|
58
|
+
* @framerIntrinsicHeight 35
|
|
59
|
+
*
|
|
60
|
+
* @framerSupportedLayoutWidth any
|
|
61
|
+
* @framerSupportedLayoutHeight fixed
|
|
62
|
+
*/
|
|
63
|
+
export declare const ChoiceSelect: ComponentType<Omit<Omit<Omit<AttributeIdProps & PaddingProps & BorderProps & {
|
|
64
|
+
fill: string;
|
|
65
|
+
} & TextProps & ExplainProps & {
|
|
66
|
+
style: CSSProperties;
|
|
67
|
+
implicitLabelPrefix: string;
|
|
68
|
+
unsatisfiedColors: InputStateColors;
|
|
69
|
+
implicitSelectedColors: InputStateColors;
|
|
70
|
+
} & {
|
|
71
|
+
resetLabel: string;
|
|
72
|
+
appearance: "none" | "auto";
|
|
73
|
+
textAlign: "center" | "end" | "start" | "initial";
|
|
74
|
+
} & {
|
|
75
|
+
noOptionsAvailableColors: InputStateColors;
|
|
76
|
+
} & RefAttributes<HTMLSelectElement>, "ref"> & RefAttributes<unknown>, "ref"> & RefAttributes<unknown>, "ref"> & RefAttributes<unknown>>;
|
|
77
|
+
|
|
78
|
+
declare type ChoiceValueIdProps = {
|
|
79
|
+
choiceValueId: string;
|
|
80
|
+
};
|
|
81
|
+
|
|
82
|
+
/**
|
|
83
|
+
* @framerSupportedLayoutWidth any
|
|
84
|
+
* @framerSupportedLayoutHeight any
|
|
85
|
+
*/
|
|
86
|
+
export declare const ChoiceValueListRenderer: React_2.ComponentType<Omit<AttributeIdProps & {
|
|
87
|
+
itemTemplate: ReactNode;
|
|
88
|
+
style: CSSProperties;
|
|
89
|
+
} & React_2.RefAttributes<unknown>, "ref"> & React_2.RefAttributes<unknown>>;
|
|
90
|
+
|
|
91
|
+
declare type ChoiceValueSorting = {
|
|
92
|
+
defaultRules: SortingRule[];
|
|
93
|
+
attributes: Array<AttributeIdProps & {
|
|
94
|
+
choiceValues: ChoiceValueId[];
|
|
95
|
+
rules: SortingRule[];
|
|
96
|
+
}>;
|
|
97
|
+
};
|
|
98
|
+
|
|
99
|
+
declare type ChoiceValueSortingProps = {
|
|
100
|
+
choiceValueSorting: ChoiceValueSorting & {
|
|
101
|
+
jsonDefinition: string;
|
|
102
|
+
};
|
|
103
|
+
};
|
|
104
|
+
|
|
105
|
+
/**
|
|
106
|
+
* @framerSupportedLayoutWidth any
|
|
107
|
+
* @framerSupportedLayoutHeight any
|
|
108
|
+
*/
|
|
109
|
+
export declare const Colorize: ComponentType<Props_2 & {
|
|
110
|
+
children?: ReactNode;
|
|
111
|
+
} & RefAttributes<unknown>>;
|
|
112
|
+
|
|
113
|
+
/**
|
|
114
|
+
* @framerIntrinsicWidth 300
|
|
115
|
+
* @framerIntrinsicHeight 35
|
|
116
|
+
*
|
|
117
|
+
* @framerSupportedLayoutWidth any
|
|
118
|
+
* @framerSupportedLayoutHeight fixed
|
|
119
|
+
*/
|
|
120
|
+
export declare const ComponentSelect: ComponentType<Omit<Omit<Omit<AttributeIdProps & PaddingProps & BorderProps & {
|
|
121
|
+
fill: string;
|
|
122
|
+
} & TextProps & ExplainProps & {
|
|
123
|
+
style: CSSProperties;
|
|
124
|
+
implicitLabelPrefix: string;
|
|
125
|
+
unsatisfiedColors: InputStateColors;
|
|
126
|
+
implicitSelectedColors: InputStateColors;
|
|
127
|
+
} & {
|
|
128
|
+
resetLabel: string;
|
|
129
|
+
appearance: "none" | "auto";
|
|
130
|
+
textAlign: "center" | "end" | "start" | "initial";
|
|
131
|
+
} & {
|
|
132
|
+
includedLabel?: string;
|
|
133
|
+
excludedLabel?: string;
|
|
134
|
+
} & RefAttributes<HTMLSelectElement>, "ref"> & RefAttributes<unknown>, "ref"> & RefAttributes<unknown>, "ref"> & RefAttributes<unknown>>;
|
|
135
|
+
|
|
136
|
+
declare type Condition = "none" | "explicit" | "implicit" | "blocked";
|
|
137
|
+
|
|
138
|
+
/**
|
|
139
|
+
* These annotations control how your component sizes
|
|
140
|
+
* Learn more: https://www.framer.com/developers/#code-components-auto-sizing
|
|
141
|
+
*
|
|
142
|
+
* @framerSupportedLayoutWidth any
|
|
143
|
+
* @framerSupportedLayoutHeight any
|
|
144
|
+
*/
|
|
145
|
+
export declare const Configuration: ComponentType<{
|
|
146
|
+
configurationModelNotFoundContent?: ReactNode;
|
|
147
|
+
accessTokenInvalidContent?: ReactNode;
|
|
148
|
+
accessTokenRestrictionContent?: ReactNode;
|
|
149
|
+
errorContent?: ReactNode;
|
|
150
|
+
} & ChoiceValueSortingProps & {
|
|
151
|
+
hcaBaseUrl: string;
|
|
152
|
+
sessionCreation: "client-side" | "server-side";
|
|
153
|
+
accessToken?: string;
|
|
154
|
+
sessionCreateUrl?: string;
|
|
155
|
+
sessionDeleteUrl?: string;
|
|
156
|
+
deploymentName: string;
|
|
157
|
+
channel: string;
|
|
158
|
+
explainDialogProps: ExplainDialogProps;
|
|
159
|
+
explainPopoverProps: ExplainPopoverProps;
|
|
160
|
+
explainConstraints: boolean;
|
|
161
|
+
attributeRelations: {
|
|
162
|
+
jsonDefinition: string;
|
|
163
|
+
};
|
|
164
|
+
} & {
|
|
165
|
+
children?: ReactNode;
|
|
166
|
+
} & RefAttributes<unknown>>;
|
|
167
|
+
|
|
168
|
+
declare type DisplayMode = "dialog" | "popover";
|
|
169
|
+
|
|
170
|
+
declare type ExplainDialogProps = {
|
|
171
|
+
attributeValueFill: string;
|
|
172
|
+
attributeValueAddFill: string;
|
|
173
|
+
attributeValueAddColor: string;
|
|
174
|
+
attributeValueRemoveFill: string;
|
|
175
|
+
attributeValueRemoveColor: string;
|
|
176
|
+
headerValueColor: string;
|
|
177
|
+
fill: string;
|
|
178
|
+
color: string;
|
|
179
|
+
closeButtonOutline: string;
|
|
180
|
+
applySolutionButtonFill: string;
|
|
181
|
+
applySolutionButtonColor: string;
|
|
182
|
+
applySolutionButtonOutline: string;
|
|
183
|
+
explanationCard: string;
|
|
184
|
+
scrollShadowBorder: string;
|
|
185
|
+
backdropFilter: string;
|
|
186
|
+
};
|
|
187
|
+
|
|
188
|
+
declare type ExplainPopoverProps = {
|
|
189
|
+
attributeValueFill: string;
|
|
190
|
+
attributeValueAddFill: string;
|
|
191
|
+
attributeValueAddColor: string;
|
|
192
|
+
attributeValueRemoveFill: string;
|
|
193
|
+
attributeValueRemoveColor: string;
|
|
194
|
+
headerValueColor: string;
|
|
195
|
+
fill: string;
|
|
196
|
+
color: string;
|
|
197
|
+
closeButtonOutline: string;
|
|
198
|
+
listSeparator: string;
|
|
199
|
+
applySolutionButtonFill: string;
|
|
200
|
+
applySolutionButtonColor: string;
|
|
201
|
+
applySolutionButtonOutline: string;
|
|
202
|
+
showMoreButtonOutline: string;
|
|
203
|
+
};
|
|
204
|
+
|
|
205
|
+
declare type ExplainProps = {
|
|
206
|
+
explain: DisplayMode | "disabled";
|
|
207
|
+
};
|
|
208
|
+
|
|
209
|
+
/**
|
|
210
|
+
* @framerSupportedLayoutWidth any
|
|
211
|
+
* @framerSupportedLayoutHeight any
|
|
212
|
+
*/
|
|
213
|
+
export declare const InitializationRetry: ComponentType<{
|
|
214
|
+
children?: ReactNode;
|
|
215
|
+
} & RefAttributes<unknown>>;
|
|
216
|
+
|
|
217
|
+
declare type InputStateColors = {
|
|
218
|
+
fill: string;
|
|
219
|
+
color: string;
|
|
220
|
+
borderColor: string;
|
|
221
|
+
};
|
|
222
|
+
|
|
223
|
+
/**
|
|
224
|
+
* @framerIntrinsicWidth 300
|
|
225
|
+
* @framerIntrinsicHeight 35
|
|
226
|
+
*
|
|
227
|
+
* @framerSupportedLayoutWidth any
|
|
228
|
+
* @framerSupportedLayoutHeight fixed
|
|
229
|
+
*/
|
|
230
|
+
export declare const NumericInput: ComponentType<Omit<Omit<Omit<AttributeIdProps & PaddingProps & BorderProps & {
|
|
231
|
+
fill: string;
|
|
232
|
+
} & TextProps & ExplainProps & {
|
|
233
|
+
style: CSSProperties;
|
|
234
|
+
implicitLabelPrefix: string;
|
|
235
|
+
unsatisfiedColors: InputStateColors;
|
|
236
|
+
implicitSelectedColors: InputStateColors;
|
|
237
|
+
} & {
|
|
238
|
+
wait: number;
|
|
239
|
+
decimalSeparator: string;
|
|
240
|
+
thousandSeparator: string;
|
|
241
|
+
placeholder: string;
|
|
242
|
+
} & RefAttributes<NumericFormat<unknown>>, "ref"> & RefAttributes<unknown>, "ref"> & RefAttributes<unknown>, "ref"> & RefAttributes<unknown>>;
|
|
243
|
+
|
|
244
|
+
declare type PaddingProps = {
|
|
245
|
+
padding: number;
|
|
246
|
+
paddingTop: number;
|
|
247
|
+
paddingRight: number;
|
|
248
|
+
paddingBottom: number;
|
|
249
|
+
paddingLeft: number;
|
|
250
|
+
isMixedPadding: boolean;
|
|
251
|
+
};
|
|
252
|
+
|
|
253
|
+
declare type Props = {
|
|
254
|
+
enabledChildren: ReactNode;
|
|
255
|
+
disabledChildren: ReactNode;
|
|
256
|
+
};
|
|
257
|
+
|
|
258
|
+
declare type Props_2 = {
|
|
259
|
+
color: string;
|
|
260
|
+
style?: CSSProperties;
|
|
261
|
+
};
|
|
262
|
+
|
|
263
|
+
declare type Props_3 = {
|
|
264
|
+
delay: number;
|
|
265
|
+
};
|
|
266
|
+
|
|
267
|
+
/**
|
|
268
|
+
* @framerSupportedLayoutWidth any
|
|
269
|
+
* @framerSupportedLayoutHeight any
|
|
270
|
+
*/
|
|
271
|
+
export declare const ResetConfiguration: ComponentType<Props & RefAttributes<unknown>>;
|
|
272
|
+
|
|
273
|
+
/**
|
|
274
|
+
* @framerSupportedLayoutWidth any
|
|
275
|
+
* @framerSupportedLayoutHeight any
|
|
276
|
+
*/
|
|
277
|
+
export declare const SatisfactionIndicator: ComponentType<Omit<Omit<Omit<AttributeIdProps & ExplainProps & {
|
|
278
|
+
satisfiedChildren: ReactNode;
|
|
279
|
+
unsatisfiedChildren: ReactNode;
|
|
280
|
+
attributes: AttributeIdProps[];
|
|
281
|
+
} & {
|
|
282
|
+
children?: ReactNode;
|
|
283
|
+
} & RefAttributes<HTMLElement>, "ref"> & RefAttributes<unknown>, "ref"> & RefAttributes<unknown>, "ref"> & RefAttributes<unknown>>;
|
|
284
|
+
|
|
285
|
+
/**
|
|
286
|
+
* @framerSupportedLayoutWidth any
|
|
287
|
+
* @framerSupportedLayoutHeight any
|
|
288
|
+
*/
|
|
289
|
+
export declare function ScrollIntoView(props: Props_3): JSX_2.Element;
|
|
290
|
+
|
|
291
|
+
/**
|
|
292
|
+
* @framerSupportedLayoutWidth any
|
|
293
|
+
* @framerSupportedLayoutHeight any
|
|
294
|
+
*/
|
|
295
|
+
export declare const SelectionIndicator: ComponentType<Omit<AttributeIdProps & ChoiceValueIdProps & {
|
|
296
|
+
variants: Variant[];
|
|
297
|
+
content1: ReactNode;
|
|
298
|
+
content2: ReactNode;
|
|
299
|
+
content3: ReactNode;
|
|
300
|
+
content4: ReactNode;
|
|
301
|
+
content5: ReactNode;
|
|
302
|
+
content6: ReactNode;
|
|
303
|
+
content7: ReactNode;
|
|
304
|
+
content8: ReactNode;
|
|
305
|
+
content9: ReactNode;
|
|
306
|
+
content10: ReactNode;
|
|
307
|
+
} & RefAttributes<HTMLElement>, "ref"> & RefAttributes<unknown>>;
|
|
308
|
+
|
|
309
|
+
declare type SelectionState = "undefined" | "included" | "excluded" | "true" | "false";
|
|
310
|
+
|
|
311
|
+
declare type SelectionState_2 = "undefined" | "included" | "excluded" | "true" | "false" | "numeric";
|
|
312
|
+
|
|
313
|
+
declare type SelectionState_3 = "undefined" | "included" | "excluded" | "true" | "false" | "numeric";
|
|
314
|
+
|
|
315
|
+
declare type SelectionState_4 = "undefined" | "included" | "excluded" | "true" | "false" | "numeric";
|
|
316
|
+
|
|
317
|
+
/**
|
|
318
|
+
* @framerSupportedLayoutWidth any
|
|
319
|
+
* @framerSupportedLayoutHeight any
|
|
320
|
+
*/
|
|
321
|
+
export declare const SelectionToggle: ComponentType<Omit<Omit<Omit<AttributeIdProps & ChoiceValueIdProps & ExplainProps & {
|
|
322
|
+
toggleFrom: SelectionState;
|
|
323
|
+
toggleTo: SelectionState;
|
|
324
|
+
} & {
|
|
325
|
+
children?: ReactNode;
|
|
326
|
+
} & RefAttributes<HTMLElement>, "ref"> & RefAttributes<unknown>, "ref"> & RefAttributes<unknown>, "ref"> & RefAttributes<unknown>>;
|
|
327
|
+
|
|
328
|
+
/**
|
|
329
|
+
* @framerSupportedLayoutWidth any
|
|
330
|
+
* @framerSupportedLayoutHeight any
|
|
331
|
+
*/
|
|
332
|
+
export declare const SetSelection: ComponentType<Omit<Omit<Omit<AttributeIdProps & ChoiceValueIdProps & ExplainProps & {
|
|
333
|
+
setSelection: SelectionState_2;
|
|
334
|
+
numericValue: number;
|
|
335
|
+
attributeIds: [];
|
|
336
|
+
} & {
|
|
337
|
+
children?: ReactNode;
|
|
338
|
+
} & RefAttributes<HTMLElement>, "ref"> & RefAttributes<unknown>, "ref"> & RefAttributes<unknown>, "ref"> & RefAttributes<unknown>>;
|
|
339
|
+
|
|
340
|
+
/**
|
|
341
|
+
* @framerSupportedLayoutWidth any
|
|
342
|
+
* @framerSupportedLayoutHeight any
|
|
343
|
+
*/
|
|
344
|
+
export declare const SetSelections: ComponentType<Omit<Omit<Omit<ExplainProps & {
|
|
345
|
+
attributes: (AttributeIdProps & ChoiceValueIdProps & {
|
|
346
|
+
setSelection: SelectionState_3;
|
|
347
|
+
numericValue: number;
|
|
348
|
+
})[];
|
|
349
|
+
existingSelections: "keep" | "drop";
|
|
350
|
+
autoResolveConflicts: boolean;
|
|
351
|
+
trigger: "click" | "auto";
|
|
352
|
+
} & {
|
|
353
|
+
children?: ReactNode;
|
|
354
|
+
} & RefAttributes<HTMLElement>, "ref"> & RefAttributes<unknown>, "ref"> & RefAttributes<unknown>, "ref"> & RefAttributes<unknown>>;
|
|
355
|
+
|
|
356
|
+
export declare function Singleton(props: PropsWithChildren<{
|
|
357
|
+
singletonId: string;
|
|
358
|
+
}>): JSX_2.Element;
|
|
359
|
+
|
|
360
|
+
declare type SortingRule = {
|
|
361
|
+
regex: string;
|
|
362
|
+
direction: "asc" | "desc";
|
|
363
|
+
mode: "isMatch" | "string" | "numeric";
|
|
364
|
+
description?: string;
|
|
365
|
+
};
|
|
366
|
+
|
|
367
|
+
declare type TextProps = {
|
|
368
|
+
color: string;
|
|
369
|
+
fontSize: number;
|
|
370
|
+
};
|
|
371
|
+
|
|
372
|
+
export declare function useDebounceValue<TValue>(sourceValue: TValue, setSourceValue: (value: TValue) => void, inputValue: TValue, setInputValue: (value: TValue) => void, wait?: number): {
|
|
373
|
+
flush: () => void;
|
|
374
|
+
};
|
|
375
|
+
|
|
376
|
+
export declare function useRenderPlaceholder(): boolean;
|
|
377
|
+
|
|
378
|
+
export declare function useSortedChoiceValues(attributeId: GlobalAttributeId, choiceValues?: ReadonlyArray<ChoiceValue>): ReadonlyArray<ChoiceValue>;
|
|
379
|
+
|
|
380
|
+
declare type Variant = {
|
|
381
|
+
selection: SelectionState_4;
|
|
382
|
+
condition: Condition;
|
|
383
|
+
content: 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10;
|
|
384
|
+
useInDesignTime: boolean;
|
|
385
|
+
};
|
|
386
|
+
|
|
387
|
+
export declare function withFullSize<T, TProps extends {
|
|
388
|
+
style?: CSSProperties;
|
|
389
|
+
}>(Component: ComponentType<TProps>): ComponentType<PropsWithoutRef<TProps> & RefAttributes<T>>;
|
|
390
|
+
|
|
391
|
+
export { }
|