@golemui/gui-shared 1.6.0 → 2.0.0-rc.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/CHANGELOG.md +76 -0
- package/forms.css +106 -0
- package/index.js +1 -1
- package/index.umd.cjs +1 -1
- package/internals.d.ts +2 -1
- package/internals.js +215 -182
- package/internals.umd.cjs +1 -1
- package/lib/dx/gui.d.ts +6 -0
- package/lib/dx/shortcuts/layouts/guiFlex.impl.d.ts +6 -0
- package/lib/dx/shortcuts/layouts/layouts.domain.d.ts +8 -3
- package/lib/golem-form.d.ts +1 -1
- package/lib/shared.d.ts +3 -56
- package/lib/utils/grid.d.ts +29 -0
- package/lib/widget.factory.d.ts +1 -0
- package/lib/widget.props.d.ts +34 -39
- package/lib/widgets.d.ts +1 -1
- package/package.json +9 -6
- package/{resolveFormInput-Bi4buDf0.cjs → resolveFormInput-B7fb-g3v.cjs} +1 -1
- package/{resolveFormInput-DM2I_8nF.js → resolveFormInput-Bs-iyptu.js} +44 -46
package/lib/shared.d.ts
CHANGED
|
@@ -1,56 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
* `error` items block submission while `blockPendingUploads` is on (the
|
|
4
|
-
* default) so a half-finished upload can never be submitted silently.
|
|
5
|
-
*/
|
|
6
|
-
export type FileStatus = 'uploading' | 'uploaded' | 'error';
|
|
7
|
-
/**
|
|
8
|
-
* The value held by the `fileUpload` (one item or `null`) and
|
|
9
|
-
* `multiFileUpload` (an array) widgets. It is plain JSON: the `File` object
|
|
10
|
-
* never enters the form state, only this envelope does. `data` is whatever the
|
|
11
|
-
* host's `uploadService.upload` resolved with, stored verbatim, so a submit
|
|
12
|
-
* payload carries exactly what the host's own endpoint returned.
|
|
13
|
-
*/
|
|
14
|
-
export type FileItem<TData = unknown> = {
|
|
15
|
-
/** Synthetic id generated when the file is added; stable across progress/retry. */
|
|
16
|
-
id: string;
|
|
17
|
-
name: string;
|
|
18
|
-
/** Size in bytes. */
|
|
19
|
-
size: number;
|
|
20
|
-
/** Best-effort MIME type as reported by the browser. */
|
|
21
|
-
type: string;
|
|
22
|
-
status: FileStatus;
|
|
23
|
-
/** Human-readable reason when `status === 'error'`. */
|
|
24
|
-
error?: string;
|
|
25
|
-
/** The server response, verbatim. */
|
|
26
|
-
data?: TData;
|
|
27
|
-
};
|
|
28
|
-
/**
|
|
29
|
-
* Transport for the file upload widgets, provided by the host. The widget
|
|
30
|
-
* calls `upload` as soon as a file is picked and stores the resolved value in
|
|
31
|
-
* `FileItem.data`; `remove` (optional) is awaited when the user removes an
|
|
32
|
-
* uploaded file so the server can delete it.
|
|
33
|
-
*
|
|
34
|
-
* Server file cleanup is the host's job. `remove` runs only on that explicit
|
|
35
|
-
* user removal and when the single-file widget replaces its file with a new
|
|
36
|
-
* pick (not awaited, a failure is only logged). A deleted repeater row, a
|
|
37
|
-
* field pruned by a state, `setData`, a config replacement or an abandoned
|
|
38
|
-
* form all leave the file on the server: the widget cannot know which of
|
|
39
|
-
* those makes it unwanted. Treat every `upload` result as provisional and
|
|
40
|
-
* reconcile server files against the submitted value.
|
|
41
|
-
*
|
|
42
|
-
* Keep the object reference stable (module level or memoized): a new form
|
|
43
|
-
* `config` identity re-initializes the form.
|
|
44
|
-
*/
|
|
45
|
-
export type UploadService = {
|
|
46
|
-
upload(file: File, ctx: {
|
|
47
|
-
id: string;
|
|
48
|
-
path: string;
|
|
49
|
-
onProgress?: (percentage: number) => void;
|
|
50
|
-
signal: AbortSignal;
|
|
51
|
-
}): Promise<unknown>;
|
|
52
|
-
remove?(item: FileItem): Promise<void>;
|
|
53
|
-
};
|
|
1
|
+
import { MarkdownParser, UploadService } from '@golemui/gui-components';
|
|
2
|
+
export type { FileItem, FileStatus, UploadService } from '@golemui/gui-components';
|
|
54
3
|
/**
|
|
55
4
|
* Dependencies are any 3rd party service components may need internally.
|
|
56
5
|
* e.g. a markdown parser for the Markdown component
|
|
@@ -63,9 +12,7 @@ export type Dependencies = {
|
|
|
63
12
|
* The markdown parser used by the markdown component
|
|
64
13
|
* Popular options are Snarkdown, Micromark and Marked.
|
|
65
14
|
*/
|
|
66
|
-
markdown?:
|
|
67
|
-
parse: (markdown: string) => string;
|
|
68
|
-
};
|
|
15
|
+
markdown?: MarkdownParser;
|
|
69
16
|
/**
|
|
70
17
|
* The upload transport used by the fileUpload and multiFileUpload components.
|
|
71
18
|
*/
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { FlexProps, GridGap, GridJustify, GridProps } from '../widget.props';
|
|
2
|
+
/** A grid's props once the deprecated ones are mapped. */
|
|
3
|
+
export type ResolvedGrid = {
|
|
4
|
+
mode: 'stack' | 'row' | 'columns' | 'auto';
|
|
5
|
+
/** The number of columns, in `columns` mode. */
|
|
6
|
+
columns?: number;
|
|
7
|
+
gap: GridGap;
|
|
8
|
+
justify: GridJustify;
|
|
9
|
+
};
|
|
10
|
+
/** The gap step nearest to a number of pixels, for the deprecated pixel gaps. */
|
|
11
|
+
export declare function gapFromPixels(pixels: number): GridGap;
|
|
12
|
+
/**
|
|
13
|
+
* Resolves a grid's props, mapping the deprecated ones, and those of a deprecated flex layout.
|
|
14
|
+
*
|
|
15
|
+
* @param type - The layout widget's type: `grid`, or `flex` for the deprecated alias.
|
|
16
|
+
* @example
|
|
17
|
+
* resolveGrid('grid', { direction: 'row', gap: 'lg' });
|
|
18
|
+
* // { mode: 'row', gap: 'lg', justify: 'stretch' }
|
|
19
|
+
* resolveGrid('flex', { direction: 'row', align: 'end', gap: 12 });
|
|
20
|
+
* // { mode: 'row', gap: 'sm', justify: 'end' }
|
|
21
|
+
*/
|
|
22
|
+
export declare function resolveGrid(type: string, props?: GridProps | FlexProps): ResolvedGrid;
|
|
23
|
+
/** The classes of a grid's container. */
|
|
24
|
+
export declare function gridClasses(grid: ResolvedGrid): string;
|
|
25
|
+
/**
|
|
26
|
+
* The classes of the cell around a grid's child. A stretched row shares its width by the
|
|
27
|
+
* children's `size` and numbered columns are spanned by it; the other grids ignore it.
|
|
28
|
+
*/
|
|
29
|
+
export declare function gridCellClasses(grid: ResolvedGrid, size: number | undefined): string;
|
package/lib/widget.factory.d.ts
CHANGED
|
@@ -32,6 +32,7 @@ export declare const GolemWidgets: {
|
|
|
32
32
|
props?: SelectProps;
|
|
33
33
|
validator?: V;
|
|
34
34
|
}) => InputWidget<string, StateKeys>;
|
|
35
|
+
/** @deprecated Use `grid`; a flex layout renders as a grid. */
|
|
35
36
|
flex: <StateKeys extends UiState = string>(config: LayoutWidgetConfig, props?: FlexProps) => LayoutWidget<StateKeys>;
|
|
36
37
|
grid: <StateKeys extends UiState = string>(config: LayoutWidgetConfig, props?: GridProps) => LayoutWidget<StateKeys>;
|
|
37
38
|
tabs: <StateKeys extends UiState = string>(config: LayoutWidgetConfig, props?: TabsProps) => LayoutWidget<StateKeys>;
|
package/lib/widget.props.d.ts
CHANGED
|
@@ -1,16 +1,6 @@
|
|
|
1
1
|
import { Localizable, WidgetPropertyFunctionParams } from '@golemui/core';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
end?: string;
|
|
5
|
-
}
|
|
6
|
-
/**
|
|
7
|
-
* A selected date-time range value. Both ends are local ISO date-time strings
|
|
8
|
-
* (`YYYY-MM-DDTHH:mm:ss`).
|
|
9
|
-
*/
|
|
10
|
-
export interface DateTimeRange {
|
|
11
|
-
start: string;
|
|
12
|
-
end: string;
|
|
13
|
-
}
|
|
2
|
+
import { DateRange, DateTimeRange, DisabledTimeRange, ListItem, Option, TimeRange } from '@golemui/gui-components';
|
|
3
|
+
export type { DateRange, DateTimeRange, DisabledTimeRange, ListItem, Option, OptionValue, TimeRange, } from '@golemui/gui-components';
|
|
14
4
|
export type AccordionProps = {
|
|
15
5
|
singleOpen?: boolean;
|
|
16
6
|
defaultOpen?: {
|
|
@@ -248,6 +238,8 @@ export type DateTimeCalendarProps = CalendarProps & IncompleteMessageProps & {
|
|
|
248
238
|
disabledTimeRanges?: DisabledTimeRange[];
|
|
249
239
|
/** Allows typing a time in the input; when false (default) times come only from the grid. */
|
|
250
240
|
allowCustomTime?: boolean;
|
|
241
|
+
/** Visible heading on the time picker. Defaults to "Time". */
|
|
242
|
+
timeLabel?: Localizable;
|
|
251
243
|
minTimeMessage?: Localizable;
|
|
252
244
|
maxTimeMessage?: Localizable;
|
|
253
245
|
disabledTimeRangeMessage?: Localizable;
|
|
@@ -411,19 +403,6 @@ export type TimeInputProps = IncompleteMessageProps & {
|
|
|
411
403
|
minTimeMessage?: Localizable;
|
|
412
404
|
maxTimeMessage?: Localizable;
|
|
413
405
|
};
|
|
414
|
-
/**
|
|
415
|
-
* A time range value (also the base of {@link DisabledTimeRange}).
|
|
416
|
-
*/
|
|
417
|
-
export type TimeRange = {
|
|
418
|
-
start: string;
|
|
419
|
-
end: string;
|
|
420
|
-
};
|
|
421
|
-
export type DisabledTimeRange = TimeRange & {
|
|
422
|
-
/** ISO date (YYYY-MM-DD): the range only applies on that date. */
|
|
423
|
-
date?: string;
|
|
424
|
-
/** Weekday numbers as returned by Date.prototype.getDay(): 0=Sunday … 6=Saturday. */
|
|
425
|
-
weekdays?: number[];
|
|
426
|
-
};
|
|
427
406
|
export type TimePickerProps = TimeInputProps & PickerToggleProps & {
|
|
428
407
|
/** Times inside these ranges (both ends inclusive) render disabled. */
|
|
429
408
|
disabledRanges?: TimeRange[];
|
|
@@ -609,11 +588,6 @@ export type RepeaterProps<Template> = {
|
|
|
609
588
|
addButtonIcon?: string;
|
|
610
589
|
removeButtonIcon?: string;
|
|
611
590
|
};
|
|
612
|
-
export type OptionValue = string | number;
|
|
613
|
-
export type Option = {
|
|
614
|
-
label: string;
|
|
615
|
-
value: OptionValue;
|
|
616
|
-
};
|
|
617
591
|
export type SelectProps = {
|
|
618
592
|
hint?: string;
|
|
619
593
|
icon?: string;
|
|
@@ -624,12 +598,6 @@ export type SelectProps = {
|
|
|
624
598
|
valueField?: string;
|
|
625
599
|
invalidOptionMessage?: Localizable;
|
|
626
600
|
};
|
|
627
|
-
export type ListItem<T> = {
|
|
628
|
-
template: T;
|
|
629
|
-
value: OptionValue;
|
|
630
|
-
/** Disabled items render greyed out, are skipped by keyboard navigation and cannot be selected */
|
|
631
|
-
disabled?: boolean;
|
|
632
|
-
};
|
|
633
601
|
type ItemKeys<T> = T extends Record<string, any> ? keyof T : string;
|
|
634
602
|
export type DropdownProps<T> = PickerToggleProps & {
|
|
635
603
|
placeholder?: string;
|
|
@@ -728,19 +696,47 @@ export type OneOfProps = {
|
|
|
728
696
|
labelField?: string;
|
|
729
697
|
valueField?: string;
|
|
730
698
|
};
|
|
699
|
+
/**
|
|
700
|
+
* @deprecated Use a grid (`GridProps`). A flex layout still renders, as a grid: `row` and
|
|
701
|
+
* `row-reverse` become a row, `column` and `column-reverse` a stack, `align` becomes `justify`
|
|
702
|
+
* and `gap` the nearest `GridGap`. `justify` is dropped.
|
|
703
|
+
*/
|
|
731
704
|
export type FlexProps = {
|
|
732
705
|
direction?: 'row' | 'row-reverse' | 'column' | 'column-reverse';
|
|
733
706
|
justify?: 'center' | 'start' | 'end' | 'stretch';
|
|
734
707
|
align?: 'center' | 'start' | 'end' | 'space-between' | 'space-around' | 'space-evenly';
|
|
735
708
|
gap?: number;
|
|
736
709
|
};
|
|
710
|
+
/** The steps of a grid's `gap`. Each one is a `--gui-layout-gap-*` CSS variable. */
|
|
711
|
+
export type GridGap = 'none' | 'xs' | 'sm' | 'md' | 'lg' | 'xl';
|
|
712
|
+
/** How a grid row's children use its width. */
|
|
713
|
+
export type GridJustify = 'stretch' | 'start' | 'center' | 'end' | 'space-between';
|
|
737
714
|
export type GridProps = {
|
|
715
|
+
/**
|
|
716
|
+
* `column`, the default, stacks the children. `row` puts them on one line, sharing the width by
|
|
717
|
+
* their `size`. Both stack below a 480px wide container.
|
|
718
|
+
*/
|
|
738
719
|
direction?: 'row' | 'column';
|
|
720
|
+
/**
|
|
721
|
+
* Wraps the children in columns, and overrides `direction`: that many equal columns, which a
|
|
722
|
+
* child spans by its `size`, or with `'auto'` as many columns as fit.
|
|
723
|
+
*/
|
|
724
|
+
columns?: number | 'auto';
|
|
725
|
+
/** The space between the children. Defaults to `md`. */
|
|
726
|
+
gap?: GridGap;
|
|
727
|
+
/**
|
|
728
|
+
* How a row's children use its width. `stretch`, the default, shares it by `size`. Any other
|
|
729
|
+
* value keeps each child at its own width, ignores `size`, and places the children on the row.
|
|
730
|
+
*/
|
|
731
|
+
justify?: GridJustify;
|
|
732
|
+
/** @deprecated Use `columns`. `false` is `columns: 12`; `true`, the old default, is a row. */
|
|
733
|
+
autoFit?: boolean;
|
|
734
|
+
/** @deprecated Use `gap`. Pixels become the nearest `GridGap`. */
|
|
739
735
|
columnGap?: number;
|
|
736
|
+
/** @deprecated Use `gap`. Pixels become the nearest `GridGap`. */
|
|
740
737
|
rowGap?: number;
|
|
741
|
-
|
|
738
|
+
/** @deprecated Use `justify`, which places the children along the row as `align` did. */
|
|
742
739
|
align?: 'center' | 'start' | 'end' | 'space-between' | 'space-around' | 'space-evenly' | 'stretch';
|
|
743
|
-
justify?: 'center' | 'start' | 'end' | 'stretch';
|
|
744
740
|
};
|
|
745
741
|
export type TabsProps = {
|
|
746
742
|
defaultOpen?: string;
|
|
@@ -750,4 +746,3 @@ export type TabsProps = {
|
|
|
750
746
|
uid: string;
|
|
751
747
|
}[];
|
|
752
748
|
};
|
|
753
|
-
export {};
|
package/lib/widgets.d.ts
CHANGED
|
@@ -2,7 +2,7 @@ export declare const inputWidgets: readonly ["calendar", "dateTimeCalendar", "ch
|
|
|
2
2
|
export declare const layoutWidgets: readonly ["accordion", "flex", "grid", "tabs"];
|
|
3
3
|
export declare const displayWidgets: readonly ["alert", "markdownText", "renderer"];
|
|
4
4
|
export declare const actionWidgets: readonly ["button"];
|
|
5
|
-
export declare const golemWidgets: ("number" | "button" | "repeater" | "
|
|
5
|
+
export declare const golemWidgets: ("number" | "button" | "repeater" | "grid" | "tags" | "alert" | "select" | "textarea" | "toggle" | "calendar" | "currency" | "datePicker" | "timePicker" | "password" | "rangeTimePicker" | "textinput" | "renderer" | "dateTimeCalendar" | "dateTimePicker" | "checkbox" | "dateInput" | "timeInput" | "dateTimeInput" | "rangeCalendar" | "radiogroup" | "tabs" | "list" | "markdownText" | "dropdown" | "multiDropdown" | "multiList" | "fileUpload" | "multiFileUpload" | "accordion" | "markdown" | "rangeDateInput" | "rangeTimeInput" | "rangeDateTimeInput" | "rangeDateTimeCalendar" | "rangeDateTimePicker" | "rangeDatePicker" | "flex")[];
|
|
6
6
|
export type GolemInputWidget = (typeof inputWidgets)[number];
|
|
7
7
|
export type GolemLayoutWidget = (typeof layoutWidgets)[number];
|
|
8
8
|
export type GolemDisplayWidget = (typeof displayWidgets)[number];
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@golemui/gui-shared",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "2.0.0-rc.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
@@ -19,7 +19,8 @@
|
|
|
19
19
|
"types": "./internals.d.ts",
|
|
20
20
|
"import": "./internals.js",
|
|
21
21
|
"require": "./internals.umd.cjs"
|
|
22
|
-
}
|
|
22
|
+
},
|
|
23
|
+
"./forms.css": "./forms.css"
|
|
23
24
|
},
|
|
24
25
|
"files": [
|
|
25
26
|
"lib",
|
|
@@ -31,12 +32,14 @@
|
|
|
31
32
|
"internals.umd.cjs",
|
|
32
33
|
"*.js",
|
|
33
34
|
"*.cjs",
|
|
34
|
-
"*.md"
|
|
35
|
+
"*.md",
|
|
36
|
+
"forms.css"
|
|
35
37
|
],
|
|
36
38
|
"dependencies": {
|
|
37
|
-
"@golemui/core": "
|
|
38
|
-
"@golemui/dx": "
|
|
39
|
-
"@golemui/gui-validators": "
|
|
39
|
+
"@golemui/core": "2.0.0-rc.0",
|
|
40
|
+
"@golemui/dx": "2.0.0-rc.0",
|
|
41
|
+
"@golemui/gui-validators": "2.0.0-rc.0",
|
|
42
|
+
"@golemui/gui-components": "2.0.0-rc.0"
|
|
40
43
|
},
|
|
41
44
|
"repository": {
|
|
42
45
|
"type": "git",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const i=require("@golemui/dx");require("@golemui/core");function wi(e){switch(e.type){case"text":return Fi(e);case"number":return Vi(e);case"boolean":return Gi(e);default:throw new Error(`Unsupported field type "${e.type}"`)}}function Gi(e){const t=i.extractWidgetProps(e);return{uid:e.uid??"",kind:"input",type:"toggle",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"boolean")}:{},props:t}}function Fi(e){const t=i.extractWidgetProps(e);return{uid:e.uid??"",kind:"input",type:"textinput",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},props:{placeholder:t.placeholder??"",...t},validator:i.buildTypedValidator(e.validator,"string")}}function Vi(e){const t=i.extractWidgetProps(e);return{uid:e.uid??"",kind:"input",type:"number",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},props:{placeholder:t.placeholder??"",...t},validator:i.buildTypedValidator(e.validator,"number")}}const _=i.createShortcutType({itemType:"INPUTS",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1,suppressAutomaticPlaceholders:!1},fields:["suppressAutomaticLabels","suppressAutomaticPlaceholders"],apply:(e,t)=>{let s=i.processAutoLabel(e,t);return s=i.processAutoPlaceholder(s,t),s}},mapToWidget:wi}),d=_.gsl,ye=_.gslByUid;function Ki(e){const{uid:t,label:s,actionType:a,disabled:l,on:n,onClick:o,data:u,type:r,tags:p,size:c,include:xi,exclude:Ni,states:pe,...g}=e;return{uid:t??"",kind:"action",type:"button",disabled:l,actionType:a,label:s,...n!=null?{on:n}:{},props:g}}const I=i.createShortcutType({itemType:"ACTIONS",kind:"action",entryShape:"bare",mapToWidget:Ki,afterMerge:(e,t)=>i.eventWiringService.extractOnClickFromMergeResult(e,t.eventRegistry,t.eventIdGenerator)}),me=I.gsl,Te=I.gslByUid;function Yi(e){const{uid:t,widgetName:s,tags:a,size:l,onChange:n,include:o,exclude:u,...r}=e,{on:p,...c}=r;return{uid:t??"",kind:"layout",type:s??"flex",props:{direction:c.direction??"column",...c},children:[]}}function $i(e,t){const s=t.walkChildren(t.children??[]);if(e.kind==="static")return{...t.mapStaticDef(e.def,"LAYOUTS"),children:s};const a=e.fn;return(l=>{const n=a(l);return{...t.mapStaticDef(n,"LAYOUTS"),children:s}})}function zi(e){return e.children}const A=i.createShortcutType({itemType:"LAYOUTS",kind:"layout",entryShape:"compound",mapToWidget:Yi,buildCustomWidget:$i,getChildren:zi}),ge=A.gsl,be=A.gslByUid;function Oi(e){return{uid:"",kind:"display",type:"renderer",props:{render:e.render}}}function Hi(e,t){if(e.kind==="static"){const a=e.def;return(l=>({uid:"",kind:"display",type:"renderer",...a.include!=null?{include:a.include}:{},...a.exclude!=null?{exclude:a.exclude}:{},props:{render:a.render(i.withForm(l))}}))}const s=e.fn;return(a=>{const l=s(a);return{uid:"",kind:"display",type:"renderer",...l.include!=null?{include:l.include}:{},...l.exclude!=null?{exclude:l.exclude}:{},props:{render:l.render(i.withForm(a))}}})}const S=i.createShortcutType({itemType:"DISPLAYS",kind:"display",entryShape:"bare",mapToWidget:Oi,buildCustomWidget:Hi}),_e=S.gsl,Ie=S.gslByUid,h=i.createShortcutType({itemType:"CALENDAR",kind:"input",entryShape:"bare",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"calendar",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"string")}:{},props:i.extractWidgetProps(e)})}),Ae=h.gsl,Se=h.gslByUid,k=i.createShortcutType({itemType:"DATE_TIME_CALENDAR",kind:"input",entryShape:"bare",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"dateTimeCalendar",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"string")}:{},props:i.extractWidgetProps(e)})}),he=k.gsl,ke=k.gslByUid,U=i.createShortcutType({itemType:"DATE_TIME_PICKER",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1,suppressAutomaticPlaceholders:!1},fields:["suppressAutomaticLabels","suppressAutomaticPlaceholders"],apply:(e,t)=>i.processAutoPlaceholder(i.processAutoLabel(e,t),t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"dateTimePicker",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"string")}:{},props:i.extractWidgetProps(e)})}),Ue=U.gsl,Ee=U.gslByUid,E=i.createShortcutType({itemType:"TEXTAREA",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1,suppressAutomaticPlaceholders:!1},fields:["suppressAutomaticLabels","suppressAutomaticPlaceholders"],apply:(e,t)=>i.processAutoPlaceholder(i.processAutoLabel(e,t),t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"textarea",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"string")}:{},props:i.extractWidgetProps(e)})}),Pe=E.gsl,De=E.gslByUid,P=i.createShortcutType({itemType:"PASSWORD",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1,suppressAutomaticPlaceholders:!1},fields:["suppressAutomaticLabels","suppressAutomaticPlaceholders"],apply:(e,t)=>i.processAutoPlaceholder(i.processAutoLabel(e,t),t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"password",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"string")}:{},props:i.extractWidgetProps(e)})}),Le=P.gsl,Be=P.gslByUid,D=i.createShortcutType({itemType:"CHECKBOX",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"checkbox",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"boolean")}:{},props:i.extractWidgetProps(e)})}),Me=D.gsl,Re=D.gslByUid,L=i.createShortcutType({itemType:"DATE_INPUT",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"dateInput",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"string")}:{},props:i.extractWidgetProps(e)})}),ve=L.gsl,fe=L.gslByUid,B=i.createShortcutType({itemType:"TIME_INPUT",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"timeInput",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"string")}:{},props:i.extractWidgetProps(e)})}),Ce=B.gsl,We=B.gslByUid,M=i.createShortcutType({itemType:"TIME_PICKER",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1,suppressAutomaticPlaceholders:!1},fields:["suppressAutomaticLabels","suppressAutomaticPlaceholders"],apply:(e,t)=>i.processAutoPlaceholder(i.processAutoLabel(e,t),t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"timePicker",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"string")}:{},props:i.extractWidgetProps(e)})}),xe=M.gsl,Ne=M.gslByUid,R=i.createShortcutType({itemType:"DATE_TIME_INPUT",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"dateTimeInput",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"string")}:{},props:i.extractWidgetProps(e)})}),we=R.gsl,Ge=R.gslByUid,v=i.createShortcutType({itemType:"CURRENCY",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1,suppressAutomaticPlaceholders:!1},fields:["suppressAutomaticLabels","suppressAutomaticPlaceholders"],apply:(e,t)=>i.processAutoPlaceholder(i.processAutoLabel(e,t),t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"currency",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"number")}:{},props:i.extractWidgetProps(e)})}),Fe=v.gsl,Ve=v.gslByUid,f=i.createShortcutType({itemType:"RANGE_CALENDAR",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"rangeCalendar",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"array")}:{},props:i.extractWidgetProps(e)})}),Ke=f.gsl,Ye=f.gslByUid,C=i.createShortcutType({itemType:"SELECT",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1,suppressAutomaticPlaceholders:!1},fields:["suppressAutomaticLabels","suppressAutomaticPlaceholders"],apply:(e,t)=>i.processAutoPlaceholder(i.processAutoLabel(e,t),t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"select",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:e.validator}:{},props:i.extractWidgetProps(e)})}),$e=C.gsl,ze=C.gslByUid,W=i.createShortcutType({itemType:"RADIOGROUP",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"radiogroup",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:e.validator}:{},props:i.extractWidgetProps(e)})}),Oe=W.gsl,He=W.gslByUid;function Xi(e){return{uid:e.uid??"",kind:"layout",type:"tabs",props:{tabs:e.tabs,renderMode:e.renderMode??"all",...e.defaultOpen!=null?{defaultOpen:e.defaultOpen}:{}},children:[]}}function qi(e,t){const s=t.walkChildren(t.children??[]);if(e.kind==="static")return{...t.mapStaticDef(e.def,"TABS"),children:s};const a=e.fn;return(l=>{const n=a(l);return{...t.mapStaticDef(n,"TABS"),children:s}})}function ji(e){return e.children}const x=i.createShortcutType({itemType:"TABS",kind:"layout",entryShape:"compound",mapToWidget:Xi,buildCustomWidget:qi,getChildren:ji}),Xe=x.gsl,qe=x.gslByUid,N=i.createShortcutType({itemType:"LIST",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"list",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:e.validator}:{},props:i.extractWidgetProps(e)})}),je=N.gsl,Je=N.gslByUid,w=i.createShortcutType({itemType:"TAGS",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1,suppressAutomaticPlaceholders:!1},fields:["suppressAutomaticLabels","suppressAutomaticPlaceholders"],apply:(e,t)=>i.processAutoPlaceholder(i.processAutoLabel(e,t),t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"tags",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"array")}:{},props:i.extractWidgetProps(e)})}),Ji=w.gsl,Qi=w.gslByUid,G=i.createShortcutType({itemType:"ALERTS",kind:"display",entryShape:"bare",mapToWidget:e=>({uid:e.uid??"",kind:"display",type:"alert",props:{text:e.text,...e.level!=null?{level:e.level}:{}}})}),Qe=G.gsl,Ze=G.gslByUid,F=i.createShortcutType({itemType:"MARKDOWN_TEXTS",kind:"display",entryShape:"bare",mapToWidget:e=>({uid:e.uid??"",kind:"display",type:"markdownText",props:{md:e.md}})}),et=F.gsl,tt=F.gslByUid,V=i.createShortcutType({itemType:"DATE_PICKER",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1,suppressAutomaticPlaceholders:!1},fields:["suppressAutomaticLabels","suppressAutomaticPlaceholders"],apply:(e,t)=>i.processAutoPlaceholder(i.processAutoLabel(e,t),t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"datePicker",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"string")}:{},props:i.extractWidgetProps(e)})}),it=V.gsl,st=V.gslByUid,K=i.createShortcutType({itemType:"DROPDOWN",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1,suppressAutomaticPlaceholders:!1},fields:["suppressAutomaticLabels","suppressAutomaticPlaceholders"],apply:(e,t)=>i.processAutoPlaceholder(i.processAutoLabel(e,t),t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"dropdown",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:e.validator}:{},props:i.extractWidgetProps(e)})}),at=K.gsl,lt=K.gslByUid,Y=i.createShortcutType({itemType:"MULTI_DROPDOWN",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1,suppressAutomaticPlaceholders:!1},fields:["suppressAutomaticLabels","suppressAutomaticPlaceholders"],apply:(e,t)=>i.processAutoPlaceholder(i.processAutoLabel(e,t),t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"multiDropdown",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:e.validator}:{},props:i.extractWidgetProps(e)})}),nt=Y.gsl,ot=Y.gslByUid,$=i.createShortcutType({itemType:"MULTI_LIST",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"multiList",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:e.validator}:{},props:i.extractWidgetProps(e)})}),rt=$.gsl,ut=$.gslByUid,z=i.createShortcutType({itemType:"FILE_UPLOAD",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"fileUpload",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"file")}:{},props:i.extractWidgetProps(e)})}),pt=z.gsl,dt=z.gslByUid,O=i.createShortcutType({itemType:"MULTI_FILE_UPLOAD",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"multiFileUpload",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"files")}:{},props:i.extractWidgetProps(e)})}),ct=O.gsl,yt=O.gslByUid;function Zi(e){return{uid:e.uid??"",kind:"layout",type:"accordion",props:{sections:e.sections,renderMode:e.renderMode??"all",...e.singleOpen!=null?{singleOpen:e.singleOpen}:{},...e.defaultOpen!=null?{defaultOpen:e.defaultOpen}:{}},children:[]}}function es(e,t){const s=t.walkChildren(t.children??[]);if(e.kind==="static")return{...t.mapStaticDef(e.def,"ACCORDION"),children:s};const a=e.fn;return(l=>{const n=a(l);return{...t.mapStaticDef(n,"ACCORDION"),children:s}})}function ts(e){return e.children}const H=i.createShortcutType({itemType:"ACCORDION",kind:"layout",entryShape:"compound",mapToWidget:Zi,buildCustomWidget:es,getChildren:ts}),mt=H.gsl,Tt=H.gslByUid;function is(e){const t={};return e.addLabel!=null&&(t.addLabel=e.addLabel),e.removeLabel!=null&&(t.removeLabel=e.removeLabel),e.limit!=null&&(t.limit=e.limit),e.title!=null&&(t.title=e.title),e.addButtonIcon!=null&&(t.addButtonIcon=e.addButtonIcon),e.removeButtonIcon!=null&&(t.removeButtonIcon=e.removeButtonIcon),t}function ss(e){return{uid:e.uid??"",kind:"input",type:"repeater",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"array")}:{},props:{...is(e),template:{kind:"layout",type:"flex",children:[],props:{direction:"column"}}}}}function b(e,t){for(const s of e){if(typeof s=="function")continue;const a=s;typeof a.path=="string"&&a.path&&!a.path.startsWith(t)&&(a.path=t+a.path),"children"in a&&Array.isArray(a.children)&&b(a.children,t);const l=a.props;l?.template?.children&&Array.isArray(l.template.children)&&b(l.template.children,t)}}function as(e,t){const s=t.walkChildren(t.children??[]),a=e.kind==="static"?e.def.path??"":e.fn({})?.path??"";a&&b(s,a+".items.");const l={kind:"layout",type:"flex",uid:"",children:s,props:{direction:"column"}};if(e.kind==="static"){const o=t.mapStaticDef(e.def,"REPEATER");return{...o,props:{...o.props,template:l}}}const n=e.fn;return(o=>{const u=n(o),r=t.mapStaticDef(u,"REPEATER");return{...r,props:{...r.props,template:l}}})}function ls(e){return{baseDef:e.def,path:e.key,children:e.children}}function ns(e){return e.children}const os={parseEntry:ls,rollUpSensibleDefaults:()=>({}),applySensibleDefaults:e=>e,mapToWidget:ss,buildCustomWidget:as,getChildren:ns},y=i.createGslSelector("REPEATER"),X=(e,t)=>y(t,(s=>s.uid===e)),rs={itemType:"REPEATER",kind:"input",handler:os,gsl:y,gslByUid:X},q=i.createShortcutType({itemType:"MARKDOWN",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1,suppressAutomaticPlaceholders:!1},fields:["suppressAutomaticLabels","suppressAutomaticPlaceholders"],apply:(e,t)=>i.processAutoPlaceholder(i.processAutoLabel(e,t),t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"markdown",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"string")}:{},props:i.extractWidgetProps(e)})}),gt=q.gsl,bt=q.gslByUid,j=i.createShortcutType({itemType:"RANGE_DATE_INPUT",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"rangeDateInput",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"array")}:{},props:i.extractWidgetProps(e)})}),_t=j.gsl,It=j.gslByUid,J=i.createShortcutType({itemType:"RANGE_TIME_INPUT",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"rangeTimeInput",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"array")}:{},props:i.extractWidgetProps(e)})}),At=J.gsl,St=J.gslByUid,Q=i.createShortcutType({itemType:"RANGE_DATE_TIME_INPUT",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"rangeDateTimeInput",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"array")}:{},props:i.extractWidgetProps(e)})}),ht=Q.gsl,kt=Q.gslByUid,Z=i.createShortcutType({itemType:"RANGE_DATE_TIME_CALENDAR",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"rangeDateTimeCalendar",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"array")}:{},props:i.extractWidgetProps(e)})}),Ut=Z.gsl,Et=Z.gslByUid,ee=i.createShortcutType({itemType:"RANGE_DATE_TIME_PICKER",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"rangeDateTimePicker",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"array")}:{},props:i.extractWidgetProps(e)})}),Pt=ee.gsl,Dt=ee.gslByUid,te=i.createShortcutType({itemType:"RANGE_DATE_PICKER",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1,suppressAutomaticPlaceholders:!1},fields:["suppressAutomaticLabels","suppressAutomaticPlaceholders"],apply:(e,t)=>i.processAutoPlaceholder(i.processAutoLabel(e,t),t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"rangeDatePicker",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"array")}:{},props:i.extractWidgetProps(e)})}),Lt=te.gsl,Bt=te.gslByUid,ie=i.createShortcutType({itemType:"RANGE_TIME_PICKER",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"rangeTimePicker",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"array")}:{},props:i.extractWidgetProps(e)})}),Mt=ie.gsl,Rt=ie.gslByUid,se=i.createShortcutType({itemType:"CUSTOM_DISPLAY",kind:"display",entryShape:"bare",mapToWidget:e=>({uid:e.uid??"",kind:"display",type:e.customType,props:e.props??{}})}),vt=se.gsl,ft=se.gslByUid,ae=i.createShortcutType({itemType:"CUSTOM_INPUT",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:e.customType,path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.defaultValue!=null?{defaultValue:e.defaultValue}:{},...e.validator!=null?{validator:e.validator}:{},props:e.props??{}})}),Ct=ae.gsl,Wt=ae.gslByUid,le=i.createShortcutType({itemType:"CUSTOM_ACTION",kind:"action",entryShape:"bare",mapToWidget:e=>{const{uid:t,label:s,disabled:a,on:l,onClick:n,data:o,customType:u,tags:r,size:p,include:c,exclude:xi,states:Ni,props:pe,...g}=e;return{uid:t??"",kind:"action",type:e.customType,label:s,disabled:a,...l!=null?{on:l}:{},props:{...pe,...g}}},afterMerge:(e,t)=>i.eventWiringService.extractOnClickFromMergeResult(e,t.eventRegistry,t.eventIdGenerator)}),xt=le.gsl,Nt=le.gslByUid;function us(e){return{uid:e.uid??"",kind:"layout",type:e.customType,props:e.props??{},children:[]}}function ps(e,t){const s=t.walkChildren(t.children??[]);if(e.kind==="static")return{...t.mapStaticDef(e.def,"CUSTOM_LAYOUT"),children:s};const a=e.fn;return(l=>{const n=a(l);return{...t.mapStaticDef(n,"CUSTOM_LAYOUT"),children:s}})}function ds(e){return e.children}const ne=i.createShortcutType({itemType:"CUSTOM_LAYOUT",kind:"layout",entryShape:"compound",mapToWidget:us,buildCustomWidget:ps,getChildren:ds}),wt=ne.gsl,Gt=ne.gslByUid,cs=[_,I,A,S,h,k,U,E,P,D,L,B,M,R,v,f,C,W,x,N,w,G,F,V,K,Y,$,z,O,H,rs,q,j,J,Q,Z,ee,te,ie,se,ae,le,ne],oe=i.createItemTypeRegistry();for(const e of cs)i.registerShortcutType(oe,e);function ys(e){return i.defineShortcutType(oe,e)}function Ft(e,t,s){if(typeof t=="function"){const l=t;return{items:[{key:e,def:o=>({type:"text",...l(o)})}],type:"ITEMS",itemType:i.GuiItemTypes.INPUTS,tags:s??[]}}const a={type:"text",...t};return{items:[{key:e,def:a}],type:"ITEMS",itemType:i.GuiItemTypes.INPUTS,tags:s??[]}}function Vt(e,t,s){if(typeof t=="function"){const l=t;return{items:[{key:e,def:o=>({type:"number",...l(o)})}],type:"ITEMS",itemType:i.GuiItemTypes.INPUTS,tags:s??[]}}const a={type:"number",...t};return{items:[{key:e,def:a}],type:"ITEMS",itemType:i.GuiItemTypes.INPUTS,tags:s??[]}}function Kt(e,t,s){if(typeof t=="function"){const l=t;return{items:[{key:e,def:o=>({type:"boolean",...l(o)})}],type:"ITEMS",itemType:i.GuiItemTypes.INPUTS,tags:s??[]}}const a={type:"boolean",...t};return{items:[{key:e,def:a}],type:"ITEMS",itemType:i.GuiItemTypes.INPUTS,tags:s??[]}}function Yt(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"SELECT",items:[{key:e,def:r=>({type:"select",...n(r)})}],tags:s??[]}}const a={type:"select",...t};return{type:"ITEMS",itemType:"SELECT",items:[{key:e,def:a}],tags:s??[]}}function $t(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"DROPDOWN",items:[{key:e,def:r=>({type:"dropdown",...n(r)})}],tags:s??[]}}const a={type:"dropdown",...t};return{type:"ITEMS",itemType:"DROPDOWN",items:[{key:e,def:a}],tags:s??[]}}function zt(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"RADIOGROUP",items:[{key:e,def:r=>({type:"radiogroup",...n(r)})}],tags:s??[]}}const a={type:"radiogroup",...t};return{type:"ITEMS",itemType:"RADIOGROUP",items:[{key:e,def:a}],tags:s??[]}}function Ot(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"CHECKBOX",items:[{key:e,def:r=>({type:"checkbox",...n(r)})}],tags:s??[]}}const a={type:"checkbox",...t};return{type:"ITEMS",itemType:"CHECKBOX",items:[{key:e,def:a}],tags:s??[]}}function Ht(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"TEXTAREA",items:[{key:e,def:r=>({type:"textarea",...n(r)})}],tags:s??[]}}const a={type:"textarea",...t};return{type:"ITEMS",itemType:"TEXTAREA",items:[{key:e,def:a}],tags:s??[]}}function Xt(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"PASSWORD",items:[{key:e,def:r=>({type:"password",...n(r)})}],tags:s??[]}}const a={type:"password",...t};return{type:"ITEMS",itemType:"PASSWORD",items:[{key:e,def:a}],tags:s??[]}}function qt(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"CURRENCY",items:[{key:e,def:r=>({type:"currency",...n(r)})}],tags:s??[]}}const a={type:"currency",...t};return{type:"ITEMS",itemType:"CURRENCY",items:[{key:e,def:a}],tags:s??[]}}function jt(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"MARKDOWN",items:[{key:e,def:r=>({type:"markdown",...n(r)})}],tags:s??[]}}const a={type:"markdown",...t};return{type:"ITEMS",itemType:"MARKDOWN",items:[{key:e,def:a}],tags:s??[]}}function Jt(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"LIST",items:[{key:e,def:r=>({type:"list",...n(r)})}],tags:s??[]}}const a={type:"list",...t};return{type:"ITEMS",itemType:"LIST",items:[{key:e,def:a}],tags:s??[]}}function Qt(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"MULTI_DROPDOWN",items:[{key:e,def:r=>({type:"multiDropdown",...n(r)})}],tags:s??[]}}const a={type:"multiDropdown",...t};return{type:"ITEMS",itemType:"MULTI_DROPDOWN",items:[{key:e,def:a}],tags:s??[]}}function Zt(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"MULTI_LIST",items:[{key:e,def:r=>({type:"multiList",...n(r)})}],tags:s??[]}}const a={type:"multiList",...t};return{type:"ITEMS",itemType:"MULTI_LIST",items:[{key:e,def:a}],tags:s??[]}}function ei(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"FILE_UPLOAD",items:[{key:e,def:r=>({type:"fileUpload",...n(r)})}],tags:s??[]}}const a={type:"fileUpload",...t};return{type:"ITEMS",itemType:"FILE_UPLOAD",items:[{key:e,def:a}],tags:s??[]}}function ti(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"MULTI_FILE_UPLOAD",items:[{key:e,def:r=>({type:"multiFileUpload",...n(r)})}],tags:s??[]}}const a={type:"multiFileUpload",...t};return{type:"ITEMS",itemType:"MULTI_FILE_UPLOAD",items:[{key:e,def:a}],tags:s??[]}}function ii(e,t,s){if(typeof t=="function"){const l=t;return{items:[o=>({type:"calendar",path:e,...l(o)})],type:"ITEMS",itemType:"CALENDAR",tags:s??[]}}return{items:[{type:"calendar",path:e,...t}],type:"ITEMS",itemType:"CALENDAR",tags:s??[]}}function si(e,t,s){if(typeof t=="function"){const l=t;return{items:[o=>({type:"dateTimeCalendar",path:e,...l(o)})],type:"ITEMS",itemType:"DATE_TIME_CALENDAR",tags:s??[]}}return{items:[{type:"dateTimeCalendar",path:e,...t}],type:"ITEMS",itemType:"DATE_TIME_CALENDAR",tags:s??[]}}function ai(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"DATE_INPUT",items:[{key:e,def:r=>({type:"dateInput",...n(r)})}],tags:s??[]}}const a={type:"dateInput",...t};return{type:"ITEMS",itemType:"DATE_INPUT",items:[{key:e,def:a}],tags:s??[]}}function li(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"DATE_PICKER",items:[{key:e,def:r=>({type:"datePicker",...n(r)})}],tags:s??[]}}const a={type:"datePicker",...t};return{type:"ITEMS",itemType:"DATE_PICKER",items:[{key:e,def:a}],tags:s??[]}}function ni(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"DATE_TIME_PICKER",items:[{key:e,def:r=>({type:"dateTimePicker",...n(r)})}],tags:s??[]}}const a={type:"dateTimePicker",...t};return{type:"ITEMS",itemType:"DATE_TIME_PICKER",items:[{key:e,def:a}],tags:s??[]}}function oi(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"RANGE_CALENDAR",items:[{key:e,def:r=>({type:"rangeCalendar",...n(r)})}],tags:s??[]}}const a={type:"rangeCalendar",...t};return{type:"ITEMS",itemType:"RANGE_CALENDAR",items:[{key:e,def:a}],tags:s??[]}}function ri(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"RANGE_DATE_INPUT",items:[{key:e,def:r=>({type:"rangeDateInput",...n(r)})}],tags:s??[]}}const a={type:"rangeDateInput",...t};return{type:"ITEMS",itemType:"RANGE_DATE_INPUT",items:[{key:e,def:a}],tags:s??[]}}function ui(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"RANGE_DATE_TIME_INPUT",items:[{key:e,def:r=>({type:"rangeDateTimeInput",...n(r)})}],tags:s??[]}}const a={type:"rangeDateTimeInput",...t};return{type:"ITEMS",itemType:"RANGE_DATE_TIME_INPUT",items:[{key:e,def:a}],tags:s??[]}}function pi(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"RANGE_DATE_TIME_CALENDAR",items:[{key:e,def:r=>({type:"rangeDateTimeCalendar",...n(r)})}],tags:s??[]}}const a={type:"rangeDateTimeCalendar",...t};return{type:"ITEMS",itemType:"RANGE_DATE_TIME_CALENDAR",items:[{key:e,def:a}],tags:s??[]}}function di(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"RANGE_DATE_TIME_PICKER",items:[{key:e,def:r=>({type:"rangeDateTimePicker",...n(r)})}],tags:s??[]}}const a={type:"rangeDateTimePicker",...t};return{type:"ITEMS",itemType:"RANGE_DATE_TIME_PICKER",items:[{key:e,def:a}],tags:s??[]}}function ci(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"RANGE_TIME_INPUT",items:[{key:e,def:r=>({type:"rangeTimeInput",...n(r)})}],tags:s??[]}}const a={type:"rangeTimeInput",...t};return{type:"ITEMS",itemType:"RANGE_TIME_INPUT",items:[{key:e,def:a}],tags:s??[]}}function yi(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"RANGE_DATE_PICKER",items:[{key:e,def:r=>({type:"rangeDatePicker",...n(r)})}],tags:s??[]}}const a={type:"rangeDatePicker",...t};return{type:"ITEMS",itemType:"RANGE_DATE_PICKER",items:[{key:e,def:a}],tags:s??[]}}function mi(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"RANGE_TIME_PICKER",items:[{key:e,def:r=>({type:"rangeTimePicker",...n(r)})}],tags:s??[]}}const a={type:"rangeTimePicker",...t};return{type:"ITEMS",itemType:"RANGE_TIME_PICKER",items:[{key:e,def:a}],tags:s??[]}}function Ti(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"TIME_INPUT",items:[{key:e,def:r=>({type:"timeInput",...n(r)})}],tags:s??[]}}const a={type:"timeInput",...t};return{type:"ITEMS",itemType:"TIME_INPUT",items:[{key:e,def:a}],tags:s??[]}}function gi(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"TIME_PICKER",items:[{key:e,def:r=>({type:"timePicker",...n(r)})}],tags:s??[]}}const a={type:"timePicker",...t};return{type:"ITEMS",itemType:"TIME_PICKER",items:[{key:e,def:a}],tags:s??[]}}function bi(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"DATE_TIME_INPUT",items:[{key:e,def:r=>({type:"dateTimeInput",...n(r)})}],tags:s??[]}}const a={type:"dateTimeInput",...t};return{type:"ITEMS",itemType:"DATE_TIME_INPUT",items:[{key:e,def:a}],tags:s??[]}}function _i(e,t,s,a){if(typeof s=="function"){const o=s;return{type:"ITEMS",itemType:"CUSTOM_INPUT",items:[{key:t,def:p=>({customType:e,...o(p)})}],tags:a??[]}}const l={customType:e,...s};return{type:"ITEMS",itemType:"CUSTOM_INPUT",items:[{key:t,def:l}],tags:a??[]}}function Ii(e,t){return{items:[e],type:"ITEMS",itemType:i.GuiItemTypes.ACTIONS,tags:t??[]}}function Ai(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"CUSTOM_ACTION",items:[u=>({customType:e,...n(u)})],tags:s??[]}}return{type:"ITEMS",itemType:"CUSTOM_ACTION",items:[{customType:e,...t}],tags:s??[]}}const re=(e,t)=>({type:"ITEMS",itemType:i.GuiItemTypes.DISPLAYS,items:[{render:e}],tags:t??[]});function Si(e,t){return{type:"ITEMS",itemType:"ALERTS",items:[e],tags:t??[]}}function hi(e,t){return{type:"ITEMS",itemType:"MARKDOWN_TEXTS",items:[e],tags:t??[]}}function ki(e,t,s){if(typeof t=="function"){const u=t;return{type:"ITEMS",itemType:"CUSTOM_DISPLAY",items:[p=>({customType:e,...u(p)})],tags:s??[]}}const{uid:a,...l}=t??{};return{type:"ITEMS",itemType:"CUSTOM_DISPLAY",items:[{customType:e,...a!=null?{uid:a}:{},props:Object.keys(l).length>0?l:void 0}],tags:s??[]}}const m=(e,t,s)=>({type:"ITEMS",itemType:i.GuiItemTypes.LAYOUTS,items:[{def:{widgetName:"flex",...t??{}},children:e}],tags:s??[]}),Ui=(e,t,s)=>m(e,{direction:"row",...t??{}},s),Ei=(e,t,s)=>m(e,{direction:"column",...t??{}},s),T=(e,t,s)=>({type:"ITEMS",itemType:i.GuiItemTypes.LAYOUTS,items:[{def:{widgetName:"grid",direction:"row",autoFit:!0,...t??{}},children:e}],tags:s??[]}),Pi=(e,t,s)=>T(e,{direction:"row",...t??{}},s),Di=(e,t,s)=>T(e,{direction:"column",...t??{}},s);function de(e){return e.toLowerCase().replace(/[^a-z0-9]+/g,"-").replace(/(^-|-$)/g,"")}function Li(e,t,s){const a=e.map(o=>({label:o.label,uid:o.uid??de(o.label)})),l=e.map(o=>({type:"ITEMS",itemType:i.GuiItemTypes.LAYOUTS,items:[{def:{uid:o.uid??de(o.label),direction:"column",widgetName:"flex"},children:o.children}],tags:[]}));return{type:"ITEMS",itemType:"TABS",items:[{def:{tabs:a,...t},children:l}],tags:s??[]}}function ce(e){return e.toLowerCase().replace(/[^a-z0-9]+/g,"-").replace(/(^-|-$)/g,"")}function Bi(e,t,s){const a=e.map(o=>({label:o.label,uid:o.uid??ce(o.label)})),l=e.map(o=>({type:"ITEMS",itemType:i.GuiItemTypes.LAYOUTS,items:[{def:{uid:o.uid??ce(o.label),direction:"column",widgetName:"flex"},children:o.children}],tags:[]}));return{type:"ITEMS",itemType:"ACCORDION",items:[{def:{sections:a,...t},children:l}],tags:s??[]}}function Mi(e,t,s,a){if(typeof s=="function"){const o=s;return{type:"ITEMS",itemType:"CUSTOM_LAYOUT",items:[{def:p=>({customType:e,...o(p)}),children:t}],tags:a??[]}}return{type:"ITEMS",itemType:"CUSTOM_LAYOUT",items:[{def:{customType:e,...s},children:t}],tags:a??[]}}function Ri(e,t,s){const{template:a,...l}=t;return{type:"ITEMS",itemType:"REPEATER",items:[{key:e,def:l,children:a}],tags:s??[]}}function vi(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"TAGS",items:[{key:e,def:r=>({type:"tags",...n(r)})}],tags:s??[]}}const a={type:"tags",...t};return{type:"ITEMS",itemType:"TAGS",items:[{key:e,def:a}],tags:s??[]}}const fi=e=>d(e,t=>t.type==="text"),Ci=e=>d(e,t=>t.type==="number"),Wi=e=>d(e,t=>t.type==="boolean"),ms=i.createSelectors({inputs:d,inputByUid:ye,textInputs:fi,numberInputs:Ci,booleanInputs:Wi,selects:$e,selectByUid:ze,dropdowns:at,dropdownByUid:lt,radiogroups:Oe,radiogroupByUid:He,checkboxes:Me,checkboxByUid:Re,textareas:Pe,textareaByUid:De,passwords:Le,passwordByUid:Be,currencies:Fe,currencyByUid:Ve,markdowns:gt,markdownByUid:bt,lists:je,listByUid:Je,multiDropdowns:nt,multiDropdownByUid:ot,multiLists:rt,multiListByUid:ut,fileUploads:pt,fileUploadByUid:dt,multiFileUploads:ct,multiFileUploadByUid:yt,calendars:Ae,calendarByUid:Se,dateTimeCalendars:he,dateTimeCalendarByUid:ke,dateInputs:ve,dateInputByUid:fe,timeInputs:Ce,timeInputByUid:We,timePickers:xe,timePickerByUid:Ne,dateTimeInputs:we,dateTimeInputByUid:Ge,datePickers:it,datePickerByUid:st,dateTimePickers:Ue,dateTimePickerByUid:Ee,rangeCalendars:Ke,rangeCalendarByUid:Ye,rangeDateInputs:_t,rangeDateInputByUid:It,rangeTimeInputs:At,rangeTimeInputByUid:St,rangeDateTimeInputs:ht,rangeDateTimeInputByUid:kt,rangeDateTimeCalendars:Ut,rangeDateTimeCalendarByUid:Et,rangeDateTimePickers:Pt,rangeDateTimePickerByUid:Dt,rangeDatePickers:Lt,rangeDatePickerByUid:Bt,rangeTimePickers:Mt,rangeTimePickerByUid:Rt,repeaters:y,repeaterByUid:X,actions:me,actionByUid:Te,layouts:ge,layoutByUid:be,displays:_e,displayByUid:Ie,alerts:Qe,alertByUid:Ze,markdownTexts:et,markdownTextByUid:tt,tabs:Xe,tabsByUid:qe,accordions:mt,accordionByUid:Tt,customInputs:Ct,customInputByUid:Wt,customActions:xt,customActionByUid:Nt,customDisplays:vt,customDisplayByUid:ft,customLayouts:wt,customLayoutByUid:Gt}),Ts={bareItemToWidget:e=>re(e),rootEntry:e=>{const t={def:{uid:"#root",direction:"column",widgetName:"flex"},children:e};return{type:"ITEMS",itemType:i.GuiItemTypes.LAYOUTS,items:[t],tags:[]}}},gs={inputs:{textInput:Ft,numberInput:Vt,booleanInput:Kt,select:Yt,dropdown:$t,radiogroup:zt,checkbox:Ot,textarea:Ht,password:Xt,currency:qt,markdown:jt,list:Jt,multiDropdown:Qt,multiList:Zt,fileUpload:ei,multiFileUpload:ti,calendar:ii,dateTimeCalendar:si,dateInput:ai,datePicker:li,dateTimePicker:ni,timeInput:Ti,timePicker:gi,dateTimeInput:bi,rangeCalendar:oi,rangeDateInput:ri,rangeDateTimeInput:ui,rangeDateTimeCalendar:pi,rangeDateTimePicker:di,rangeTimeInput:ci,rangeDatePicker:yi,rangeTimePicker:mi,repeater:Ri,tags:vi,custom:_i},actions:{button:Ii,custom:Ai},displays:{display:re,alert:Si,markdownText:hi,custom:ki},layouts:{flex:m,horizontalFlex:Ui,verticalFlex:Ei,grid:T,horizontalGrid:Pi,verticalGrid:Di,tabs:Li,accordion:Bi,custom:Mi}},ue=i.createImplementation({name:"gui",registry:oe,facade:gs,selectors:ms,adapter:Ts}),bs=ue.namespace,_s=ue.formDefs,Is=ue.resolveFormInput;exports._gslAccordionByUid=Tt;exports._gslAccordions=mt;exports._gslActionByUid=Te;exports._gslActions=me;exports._gslAlertByUid=Ze;exports._gslAlerts=Qe;exports._gslBooleanInputs=Wi;exports._gslCalendarByUid=Se;exports._gslCalendars=Ae;exports._gslCheckboxByUid=Re;exports._gslCheckboxes=Me;exports._gslCurrencies=Fe;exports._gslCurrencyByUid=Ve;exports._gslCustomActionByUid=Nt;exports._gslCustomActions=xt;exports._gslCustomDisplayByUid=ft;exports._gslCustomDisplays=vt;exports._gslCustomInputByUid=Wt;exports._gslCustomInputs=Ct;exports._gslCustomLayoutByUid=Gt;exports._gslCustomLayouts=wt;exports._gslDateInputByUid=fe;exports._gslDateInputs=ve;exports._gslDatePickerByUid=st;exports._gslDatePickers=it;exports._gslDateTimeCalendarByUid=ke;exports._gslDateTimeCalendars=he;exports._gslDateTimeInputByUid=Ge;exports._gslDateTimeInputs=we;exports._gslDateTimePickerByUid=Ee;exports._gslDateTimePickers=Ue;exports._gslDisplayByUid=Ie;exports._gslDisplays=_e;exports._gslDropdownByUid=lt;exports._gslDropdowns=at;exports._gslFileUploadByUid=dt;exports._gslFileUploads=pt;exports._gslInputByUid=ye;exports._gslInputs=d;exports._gslLayoutByUid=be;exports._gslLayouts=ge;exports._gslListByUid=Je;exports._gslLists=je;exports._gslMarkdownByUid=bt;exports._gslMarkdownTextByUid=tt;exports._gslMarkdownTexts=et;exports._gslMarkdowns=gt;exports._gslMultiDropdownByUid=ot;exports._gslMultiDropdowns=nt;exports._gslMultiFileUploadByUid=yt;exports._gslMultiFileUploads=ct;exports._gslMultiListByUid=ut;exports._gslMultiLists=rt;exports._gslNumberInputs=Ci;exports._gslPasswordByUid=Be;exports._gslPasswords=Le;exports._gslRadiogroupByUid=He;exports._gslRadiogroups=Oe;exports._gslRangeCalendarByUid=Ye;exports._gslRangeCalendars=Ke;exports._gslRangeDateInputByUid=It;exports._gslRangeDateInputs=_t;exports._gslRangeDatePickerByUid=Bt;exports._gslRangeDatePickers=Lt;exports._gslRangeDateTimeCalendarByUid=Et;exports._gslRangeDateTimeCalendars=Ut;exports._gslRangeDateTimeInputByUid=kt;exports._gslRangeDateTimeInputs=ht;exports._gslRangeDateTimePickerByUid=Dt;exports._gslRangeDateTimePickers=Pt;exports._gslRangeTimeInputByUid=St;exports._gslRangeTimeInputs=At;exports._gslRangeTimePickerByUid=Rt;exports._gslRangeTimePickers=Mt;exports._gslRepeaterByUid=X;exports._gslRepeaters=y;exports._gslSelectByUid=ze;exports._gslSelects=$e;exports._gslTabs=Xe;exports._gslTabsByUid=qe;exports._gslTags=Ji;exports._gslTagsByUid=Qi;exports._gslTextInputs=fi;exports._gslTextareaByUid=De;exports._gslTextareas=Pe;exports._gslTimeInputByUid=We;exports._gslTimeInputs=Ce;exports._gslTimePickerByUid=Ne;exports._gslTimePickers=xe;exports._guiAccordion=Bi;exports._guiAlert=Si;exports._guiBooleanInput=Kt;exports._guiButton=Ii;exports._guiCalendar=ii;exports._guiCheckbox=Ot;exports._guiCurrency=qt;exports._guiCustomAction=Ai;exports._guiCustomDisplay=ki;exports._guiCustomInput=_i;exports._guiCustomLayout=Mi;exports._guiDateInput=ai;exports._guiDatePicker=li;exports._guiDateTimeCalendar=si;exports._guiDateTimeInput=bi;exports._guiDateTimePicker=ni;exports._guiDisplay=re;exports._guiDropdown=$t;exports._guiFileUpload=ei;exports._guiFlex=m;exports._guiGrid=T;exports._guiHorizontalFlex=Ui;exports._guiHorizontalGrid=Pi;exports._guiList=Jt;exports._guiMarkdown=jt;exports._guiMarkdownText=hi;exports._guiMultiDropdown=Qt;exports._guiMultiFileUpload=ti;exports._guiMultiList=Zt;exports._guiNumberInput=Vt;exports._guiPassword=Xt;exports._guiRadiogroup=zt;exports._guiRangeCalendar=oi;exports._guiRangeDateInput=ri;exports._guiRangeDatePicker=yi;exports._guiRangeDateTimeCalendar=pi;exports._guiRangeDateTimeInput=ui;exports._guiRangeDateTimePicker=di;exports._guiRangeTimeInput=ci;exports._guiRangeTimePicker=mi;exports._guiRepeater=Ri;exports._guiSelect=Yt;exports._guiTabs=Li;exports._guiTags=vi;exports._guiTextInput=Ft;exports._guiTextarea=Ht;exports._guiTimeInput=Ti;exports._guiTimePicker=gi;exports._guiVerticalFlex=Ei;exports._guiVerticalGrid=Di;exports.defineShortcutType=ys;exports.formDefs=_s;exports.gui=bs;exports.resolveFormInput=Is;
|
|
1
|
+
"use strict";const i=require("@golemui/dx");require("@golemui/core");function wi(e){switch(e.type){case"text":return Fi(e);case"number":return Vi(e);case"boolean":return Gi(e);default:throw new Error(`Unsupported field type "${e.type}"`)}}function Gi(e){const t=i.extractWidgetProps(e);return{uid:e.uid??"",kind:"input",type:"toggle",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"boolean")}:{},props:t}}function Fi(e){const t=i.extractWidgetProps(e);return{uid:e.uid??"",kind:"input",type:"textinput",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},props:{placeholder:t.placeholder??"",...t},validator:i.buildTypedValidator(e.validator,"string")}}function Vi(e){const t=i.extractWidgetProps(e);return{uid:e.uid??"",kind:"input",type:"number",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},props:{placeholder:t.placeholder??"",...t},validator:i.buildTypedValidator(e.validator,"number")}}const _=i.createShortcutType({itemType:"INPUTS",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1,suppressAutomaticPlaceholders:!1},fields:["suppressAutomaticLabels","suppressAutomaticPlaceholders"],apply:(e,t)=>{let s=i.processAutoLabel(e,t);return s=i.processAutoPlaceholder(s,t),s}},mapToWidget:wi}),d=_.gsl,ye=_.gslByUid;function Ki(e){const{uid:t,label:s,actionType:a,disabled:l,on:n,onClick:o,data:u,type:r,tags:p,size:c,include:Ni,exclude:xi,states:pe,...g}=e;return{uid:t??"",kind:"action",type:"button",disabled:l,actionType:a,label:s,...n!=null?{on:n}:{},props:g}}const I=i.createShortcutType({itemType:"ACTIONS",kind:"action",entryShape:"bare",mapToWidget:Ki,afterMerge:(e,t)=>i.eventWiringService.extractOnClickFromMergeResult(e,t.eventRegistry,t.eventIdGenerator)}),me=I.gsl,Te=I.gslByUid;function Yi(e){const{uid:t,widgetName:s,tags:a,size:l,onChange:n,include:o,exclude:u,...r}=e,{on:p,...c}=r;return{uid:t??"",kind:"layout",type:s??"grid",props:{direction:c.direction??"column",...c},children:[]}}function $i(e,t){const s=t.walkChildren(t.children??[]);if(e.kind==="static")return{...t.mapStaticDef(e.def,"LAYOUTS"),children:s};const a=e.fn;return(l=>{const n=a(l);return{...t.mapStaticDef(n,"LAYOUTS"),children:s}})}function zi(e){return e.children}const A=i.createShortcutType({itemType:"LAYOUTS",kind:"layout",entryShape:"compound",mapToWidget:Yi,buildCustomWidget:$i,getChildren:zi}),ge=A.gsl,be=A.gslByUid;function Oi(e){return{uid:"",kind:"display",type:"renderer",props:{render:e.render}}}function Hi(e,t){if(e.kind==="static"){const a=e.def;return(l=>({uid:"",kind:"display",type:"renderer",...a.include!=null?{include:a.include}:{},...a.exclude!=null?{exclude:a.exclude}:{},props:{render:a.render(i.withForm(l))}}))}const s=e.fn;return(a=>{const l=s(a);return{uid:"",kind:"display",type:"renderer",...l.include!=null?{include:l.include}:{},...l.exclude!=null?{exclude:l.exclude}:{},props:{render:l.render(i.withForm(a))}}})}const S=i.createShortcutType({itemType:"DISPLAYS",kind:"display",entryShape:"bare",mapToWidget:Oi,buildCustomWidget:Hi}),_e=S.gsl,Ie=S.gslByUid,h=i.createShortcutType({itemType:"CALENDAR",kind:"input",entryShape:"bare",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"calendar",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"string")}:{},props:i.extractWidgetProps(e)})}),Ae=h.gsl,Se=h.gslByUid,k=i.createShortcutType({itemType:"DATE_TIME_CALENDAR",kind:"input",entryShape:"bare",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"dateTimeCalendar",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"string")}:{},props:i.extractWidgetProps(e)})}),he=k.gsl,ke=k.gslByUid,U=i.createShortcutType({itemType:"DATE_TIME_PICKER",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1,suppressAutomaticPlaceholders:!1},fields:["suppressAutomaticLabels","suppressAutomaticPlaceholders"],apply:(e,t)=>i.processAutoPlaceholder(i.processAutoLabel(e,t),t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"dateTimePicker",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"string")}:{},props:i.extractWidgetProps(e)})}),Ue=U.gsl,Ee=U.gslByUid,E=i.createShortcutType({itemType:"TEXTAREA",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1,suppressAutomaticPlaceholders:!1},fields:["suppressAutomaticLabels","suppressAutomaticPlaceholders"],apply:(e,t)=>i.processAutoPlaceholder(i.processAutoLabel(e,t),t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"textarea",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"string")}:{},props:i.extractWidgetProps(e)})}),Pe=E.gsl,De=E.gslByUid,P=i.createShortcutType({itemType:"PASSWORD",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1,suppressAutomaticPlaceholders:!1},fields:["suppressAutomaticLabels","suppressAutomaticPlaceholders"],apply:(e,t)=>i.processAutoPlaceholder(i.processAutoLabel(e,t),t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"password",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"string")}:{},props:i.extractWidgetProps(e)})}),Le=P.gsl,Be=P.gslByUid,D=i.createShortcutType({itemType:"CHECKBOX",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"checkbox",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"boolean")}:{},props:i.extractWidgetProps(e)})}),Me=D.gsl,Re=D.gslByUid,L=i.createShortcutType({itemType:"DATE_INPUT",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"dateInput",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"string")}:{},props:i.extractWidgetProps(e)})}),ve=L.gsl,fe=L.gslByUid,B=i.createShortcutType({itemType:"TIME_INPUT",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"timeInput",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"string")}:{},props:i.extractWidgetProps(e)})}),Ce=B.gsl,We=B.gslByUid,M=i.createShortcutType({itemType:"TIME_PICKER",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1,suppressAutomaticPlaceholders:!1},fields:["suppressAutomaticLabels","suppressAutomaticPlaceholders"],apply:(e,t)=>i.processAutoPlaceholder(i.processAutoLabel(e,t),t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"timePicker",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"string")}:{},props:i.extractWidgetProps(e)})}),Ne=M.gsl,xe=M.gslByUid,R=i.createShortcutType({itemType:"DATE_TIME_INPUT",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"dateTimeInput",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"string")}:{},props:i.extractWidgetProps(e)})}),we=R.gsl,Ge=R.gslByUid,v=i.createShortcutType({itemType:"CURRENCY",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1,suppressAutomaticPlaceholders:!1},fields:["suppressAutomaticLabels","suppressAutomaticPlaceholders"],apply:(e,t)=>i.processAutoPlaceholder(i.processAutoLabel(e,t),t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"currency",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"number")}:{},props:i.extractWidgetProps(e)})}),Fe=v.gsl,Ve=v.gslByUid,f=i.createShortcutType({itemType:"RANGE_CALENDAR",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"rangeCalendar",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"array")}:{},props:i.extractWidgetProps(e)})}),Ke=f.gsl,Ye=f.gslByUid,C=i.createShortcutType({itemType:"SELECT",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1,suppressAutomaticPlaceholders:!1},fields:["suppressAutomaticLabels","suppressAutomaticPlaceholders"],apply:(e,t)=>i.processAutoPlaceholder(i.processAutoLabel(e,t),t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"select",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:e.validator}:{},props:i.extractWidgetProps(e)})}),$e=C.gsl,ze=C.gslByUid,W=i.createShortcutType({itemType:"RADIOGROUP",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"radiogroup",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:e.validator}:{},props:i.extractWidgetProps(e)})}),Oe=W.gsl,He=W.gslByUid;function Xi(e){return{uid:e.uid??"",kind:"layout",type:"tabs",props:{tabs:e.tabs,renderMode:e.renderMode??"all",...e.defaultOpen!=null?{defaultOpen:e.defaultOpen}:{}},children:[]}}function qi(e,t){const s=t.walkChildren(t.children??[]);if(e.kind==="static")return{...t.mapStaticDef(e.def,"TABS"),children:s};const a=e.fn;return(l=>{const n=a(l);return{...t.mapStaticDef(n,"TABS"),children:s}})}function ji(e){return e.children}const N=i.createShortcutType({itemType:"TABS",kind:"layout",entryShape:"compound",mapToWidget:Xi,buildCustomWidget:qi,getChildren:ji}),Xe=N.gsl,qe=N.gslByUid,x=i.createShortcutType({itemType:"LIST",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"list",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:e.validator}:{},props:i.extractWidgetProps(e)})}),je=x.gsl,Je=x.gslByUid,w=i.createShortcutType({itemType:"TAGS",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1,suppressAutomaticPlaceholders:!1},fields:["suppressAutomaticLabels","suppressAutomaticPlaceholders"],apply:(e,t)=>i.processAutoPlaceholder(i.processAutoLabel(e,t),t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"tags",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"array")}:{},props:i.extractWidgetProps(e)})}),Ji=w.gsl,Qi=w.gslByUid,G=i.createShortcutType({itemType:"ALERTS",kind:"display",entryShape:"bare",mapToWidget:e=>({uid:e.uid??"",kind:"display",type:"alert",props:{text:e.text,...e.level!=null?{level:e.level}:{}}})}),Qe=G.gsl,Ze=G.gslByUid,F=i.createShortcutType({itemType:"MARKDOWN_TEXTS",kind:"display",entryShape:"bare",mapToWidget:e=>({uid:e.uid??"",kind:"display",type:"markdownText",props:{md:e.md}})}),et=F.gsl,tt=F.gslByUid,V=i.createShortcutType({itemType:"DATE_PICKER",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1,suppressAutomaticPlaceholders:!1},fields:["suppressAutomaticLabels","suppressAutomaticPlaceholders"],apply:(e,t)=>i.processAutoPlaceholder(i.processAutoLabel(e,t),t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"datePicker",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"string")}:{},props:i.extractWidgetProps(e)})}),it=V.gsl,st=V.gslByUid,K=i.createShortcutType({itemType:"DROPDOWN",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1,suppressAutomaticPlaceholders:!1},fields:["suppressAutomaticLabels","suppressAutomaticPlaceholders"],apply:(e,t)=>i.processAutoPlaceholder(i.processAutoLabel(e,t),t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"dropdown",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:e.validator}:{},props:i.extractWidgetProps(e)})}),at=K.gsl,lt=K.gslByUid,Y=i.createShortcutType({itemType:"MULTI_DROPDOWN",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1,suppressAutomaticPlaceholders:!1},fields:["suppressAutomaticLabels","suppressAutomaticPlaceholders"],apply:(e,t)=>i.processAutoPlaceholder(i.processAutoLabel(e,t),t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"multiDropdown",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:e.validator}:{},props:i.extractWidgetProps(e)})}),nt=Y.gsl,ot=Y.gslByUid,$=i.createShortcutType({itemType:"MULTI_LIST",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"multiList",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:e.validator}:{},props:i.extractWidgetProps(e)})}),rt=$.gsl,ut=$.gslByUid,z=i.createShortcutType({itemType:"FILE_UPLOAD",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"fileUpload",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"file")}:{},props:i.extractWidgetProps(e)})}),pt=z.gsl,dt=z.gslByUid,O=i.createShortcutType({itemType:"MULTI_FILE_UPLOAD",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"multiFileUpload",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"files")}:{},props:i.extractWidgetProps(e)})}),ct=O.gsl,yt=O.gslByUid;function Zi(e){return{uid:e.uid??"",kind:"layout",type:"accordion",props:{sections:e.sections,renderMode:e.renderMode??"all",...e.singleOpen!=null?{singleOpen:e.singleOpen}:{},...e.defaultOpen!=null?{defaultOpen:e.defaultOpen}:{}},children:[]}}function es(e,t){const s=t.walkChildren(t.children??[]);if(e.kind==="static")return{...t.mapStaticDef(e.def,"ACCORDION"),children:s};const a=e.fn;return(l=>{const n=a(l);return{...t.mapStaticDef(n,"ACCORDION"),children:s}})}function ts(e){return e.children}const H=i.createShortcutType({itemType:"ACCORDION",kind:"layout",entryShape:"compound",mapToWidget:Zi,buildCustomWidget:es,getChildren:ts}),mt=H.gsl,Tt=H.gslByUid;function is(e){const t={};return e.addLabel!=null&&(t.addLabel=e.addLabel),e.removeLabel!=null&&(t.removeLabel=e.removeLabel),e.limit!=null&&(t.limit=e.limit),e.title!=null&&(t.title=e.title),e.addButtonIcon!=null&&(t.addButtonIcon=e.addButtonIcon),e.removeButtonIcon!=null&&(t.removeButtonIcon=e.removeButtonIcon),t}function ss(e){return{uid:e.uid??"",kind:"input",type:"repeater",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"array")}:{},props:{...is(e),template:{kind:"layout",type:"grid",children:[],props:{direction:"column"}}}}}function b(e,t){for(const s of e){if(typeof s=="function")continue;const a=s;typeof a.path=="string"&&a.path&&!a.path.startsWith(t)&&(a.path=t+a.path),"children"in a&&Array.isArray(a.children)&&b(a.children,t);const l=a.props;l?.template?.children&&Array.isArray(l.template.children)&&b(l.template.children,t)}}function as(e,t){const s=t.walkChildren(t.children??[]),a=e.kind==="static"?e.def.path??"":e.fn({})?.path??"";a&&b(s,a+".items.");const l={kind:"layout",type:"grid",uid:"",children:s,props:{direction:"column"}};if(e.kind==="static"){const o=t.mapStaticDef(e.def,"REPEATER");return{...o,props:{...o.props,template:l}}}const n=e.fn;return(o=>{const u=n(o),r=t.mapStaticDef(u,"REPEATER");return{...r,props:{...r.props,template:l}}})}function ls(e){return{baseDef:e.def,path:e.key,children:e.children}}function ns(e){return e.children}const os={parseEntry:ls,rollUpSensibleDefaults:()=>({}),applySensibleDefaults:e=>e,mapToWidget:ss,buildCustomWidget:as,getChildren:ns},y=i.createGslSelector("REPEATER"),X=(e,t)=>y(t,(s=>s.uid===e)),rs={itemType:"REPEATER",kind:"input",handler:os,gsl:y,gslByUid:X},q=i.createShortcutType({itemType:"MARKDOWN",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1,suppressAutomaticPlaceholders:!1},fields:["suppressAutomaticLabels","suppressAutomaticPlaceholders"],apply:(e,t)=>i.processAutoPlaceholder(i.processAutoLabel(e,t),t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"markdown",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"string")}:{},props:i.extractWidgetProps(e)})}),gt=q.gsl,bt=q.gslByUid,j=i.createShortcutType({itemType:"RANGE_DATE_INPUT",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"rangeDateInput",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"array")}:{},props:i.extractWidgetProps(e)})}),_t=j.gsl,It=j.gslByUid,J=i.createShortcutType({itemType:"RANGE_TIME_INPUT",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"rangeTimeInput",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"array")}:{},props:i.extractWidgetProps(e)})}),At=J.gsl,St=J.gslByUid,Q=i.createShortcutType({itemType:"RANGE_DATE_TIME_INPUT",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"rangeDateTimeInput",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"array")}:{},props:i.extractWidgetProps(e)})}),ht=Q.gsl,kt=Q.gslByUid,Z=i.createShortcutType({itemType:"RANGE_DATE_TIME_CALENDAR",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"rangeDateTimeCalendar",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"array")}:{},props:i.extractWidgetProps(e)})}),Ut=Z.gsl,Et=Z.gslByUid,ee=i.createShortcutType({itemType:"RANGE_DATE_TIME_PICKER",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"rangeDateTimePicker",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"array")}:{},props:i.extractWidgetProps(e)})}),Pt=ee.gsl,Dt=ee.gslByUid,te=i.createShortcutType({itemType:"RANGE_DATE_PICKER",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1,suppressAutomaticPlaceholders:!1},fields:["suppressAutomaticLabels","suppressAutomaticPlaceholders"],apply:(e,t)=>i.processAutoPlaceholder(i.processAutoLabel(e,t),t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"rangeDatePicker",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"array")}:{},props:i.extractWidgetProps(e)})}),Lt=te.gsl,Bt=te.gslByUid,ie=i.createShortcutType({itemType:"RANGE_TIME_PICKER",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:"rangeTimePicker",path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.validator!=null?{validator:i.buildTypedValidator(e.validator,"array")}:{},props:i.extractWidgetProps(e)})}),Mt=ie.gsl,Rt=ie.gslByUid,se=i.createShortcutType({itemType:"CUSTOM_DISPLAY",kind:"display",entryShape:"bare",mapToWidget:e=>({uid:e.uid??"",kind:"display",type:e.customType,props:e.props??{}})}),vt=se.gsl,ft=se.gslByUid,ae=i.createShortcutType({itemType:"CUSTOM_INPUT",kind:"input",entryShape:"keyed",sensibleDefaults:{base:{suppressAutomaticLabels:!1},fields:["suppressAutomaticLabels"],apply:(e,t)=>i.processAutoLabel(e,t)},mapToWidget:e=>({uid:e.uid??"",kind:"input",type:e.customType,path:e.path??"",...e.label!=null?{label:e.label}:{},...e.disabled!=null?{disabled:e.disabled}:{},...e.readonly!=null?{readonly:e.readonly}:{},...e.defaultValue!=null?{defaultValue:e.defaultValue}:{},...e.validator!=null?{validator:e.validator}:{},props:e.props??{}})}),Ct=ae.gsl,Wt=ae.gslByUid,le=i.createShortcutType({itemType:"CUSTOM_ACTION",kind:"action",entryShape:"bare",mapToWidget:e=>{const{uid:t,label:s,disabled:a,on:l,onClick:n,data:o,customType:u,tags:r,size:p,include:c,exclude:Ni,states:xi,props:pe,...g}=e;return{uid:t??"",kind:"action",type:e.customType,label:s,disabled:a,...l!=null?{on:l}:{},props:{...pe,...g}}},afterMerge:(e,t)=>i.eventWiringService.extractOnClickFromMergeResult(e,t.eventRegistry,t.eventIdGenerator)}),Nt=le.gsl,xt=le.gslByUid;function us(e){return{uid:e.uid??"",kind:"layout",type:e.customType,props:e.props??{},children:[]}}function ps(e,t){const s=t.walkChildren(t.children??[]);if(e.kind==="static")return{...t.mapStaticDef(e.def,"CUSTOM_LAYOUT"),children:s};const a=e.fn;return(l=>{const n=a(l);return{...t.mapStaticDef(n,"CUSTOM_LAYOUT"),children:s}})}function ds(e){return e.children}const ne=i.createShortcutType({itemType:"CUSTOM_LAYOUT",kind:"layout",entryShape:"compound",mapToWidget:us,buildCustomWidget:ps,getChildren:ds}),wt=ne.gsl,Gt=ne.gslByUid,cs=[_,I,A,S,h,k,U,E,P,D,L,B,M,R,v,f,C,W,N,x,w,G,F,V,K,Y,$,z,O,H,rs,q,j,J,Q,Z,ee,te,ie,se,ae,le,ne],oe=i.createItemTypeRegistry();for(const e of cs)i.registerShortcutType(oe,e);function ys(e){return i.defineShortcutType(oe,e)}function Ft(e,t,s){if(typeof t=="function"){const l=t;return{items:[{key:e,def:o=>({type:"text",...l(o)})}],type:"ITEMS",itemType:i.GuiItemTypes.INPUTS,tags:s??[]}}const a={type:"text",...t};return{items:[{key:e,def:a}],type:"ITEMS",itemType:i.GuiItemTypes.INPUTS,tags:s??[]}}function Vt(e,t,s){if(typeof t=="function"){const l=t;return{items:[{key:e,def:o=>({type:"number",...l(o)})}],type:"ITEMS",itemType:i.GuiItemTypes.INPUTS,tags:s??[]}}const a={type:"number",...t};return{items:[{key:e,def:a}],type:"ITEMS",itemType:i.GuiItemTypes.INPUTS,tags:s??[]}}function Kt(e,t,s){if(typeof t=="function"){const l=t;return{items:[{key:e,def:o=>({type:"boolean",...l(o)})}],type:"ITEMS",itemType:i.GuiItemTypes.INPUTS,tags:s??[]}}const a={type:"boolean",...t};return{items:[{key:e,def:a}],type:"ITEMS",itemType:i.GuiItemTypes.INPUTS,tags:s??[]}}function Yt(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"SELECT",items:[{key:e,def:r=>({type:"select",...n(r)})}],tags:s??[]}}const a={type:"select",...t};return{type:"ITEMS",itemType:"SELECT",items:[{key:e,def:a}],tags:s??[]}}function $t(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"DROPDOWN",items:[{key:e,def:r=>({type:"dropdown",...n(r)})}],tags:s??[]}}const a={type:"dropdown",...t};return{type:"ITEMS",itemType:"DROPDOWN",items:[{key:e,def:a}],tags:s??[]}}function zt(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"RADIOGROUP",items:[{key:e,def:r=>({type:"radiogroup",...n(r)})}],tags:s??[]}}const a={type:"radiogroup",...t};return{type:"ITEMS",itemType:"RADIOGROUP",items:[{key:e,def:a}],tags:s??[]}}function Ot(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"CHECKBOX",items:[{key:e,def:r=>({type:"checkbox",...n(r)})}],tags:s??[]}}const a={type:"checkbox",...t};return{type:"ITEMS",itemType:"CHECKBOX",items:[{key:e,def:a}],tags:s??[]}}function Ht(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"TEXTAREA",items:[{key:e,def:r=>({type:"textarea",...n(r)})}],tags:s??[]}}const a={type:"textarea",...t};return{type:"ITEMS",itemType:"TEXTAREA",items:[{key:e,def:a}],tags:s??[]}}function Xt(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"PASSWORD",items:[{key:e,def:r=>({type:"password",...n(r)})}],tags:s??[]}}const a={type:"password",...t};return{type:"ITEMS",itemType:"PASSWORD",items:[{key:e,def:a}],tags:s??[]}}function qt(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"CURRENCY",items:[{key:e,def:r=>({type:"currency",...n(r)})}],tags:s??[]}}const a={type:"currency",...t};return{type:"ITEMS",itemType:"CURRENCY",items:[{key:e,def:a}],tags:s??[]}}function jt(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"MARKDOWN",items:[{key:e,def:r=>({type:"markdown",...n(r)})}],tags:s??[]}}const a={type:"markdown",...t};return{type:"ITEMS",itemType:"MARKDOWN",items:[{key:e,def:a}],tags:s??[]}}function Jt(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"LIST",items:[{key:e,def:r=>({type:"list",...n(r)})}],tags:s??[]}}const a={type:"list",...t};return{type:"ITEMS",itemType:"LIST",items:[{key:e,def:a}],tags:s??[]}}function Qt(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"MULTI_DROPDOWN",items:[{key:e,def:r=>({type:"multiDropdown",...n(r)})}],tags:s??[]}}const a={type:"multiDropdown",...t};return{type:"ITEMS",itemType:"MULTI_DROPDOWN",items:[{key:e,def:a}],tags:s??[]}}function Zt(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"MULTI_LIST",items:[{key:e,def:r=>({type:"multiList",...n(r)})}],tags:s??[]}}const a={type:"multiList",...t};return{type:"ITEMS",itemType:"MULTI_LIST",items:[{key:e,def:a}],tags:s??[]}}function ei(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"FILE_UPLOAD",items:[{key:e,def:r=>({type:"fileUpload",...n(r)})}],tags:s??[]}}const a={type:"fileUpload",...t};return{type:"ITEMS",itemType:"FILE_UPLOAD",items:[{key:e,def:a}],tags:s??[]}}function ti(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"MULTI_FILE_UPLOAD",items:[{key:e,def:r=>({type:"multiFileUpload",...n(r)})}],tags:s??[]}}const a={type:"multiFileUpload",...t};return{type:"ITEMS",itemType:"MULTI_FILE_UPLOAD",items:[{key:e,def:a}],tags:s??[]}}function ii(e,t,s){if(typeof t=="function"){const l=t;return{items:[o=>({type:"calendar",path:e,...l(o)})],type:"ITEMS",itemType:"CALENDAR",tags:s??[]}}return{items:[{type:"calendar",path:e,...t}],type:"ITEMS",itemType:"CALENDAR",tags:s??[]}}function si(e,t,s){if(typeof t=="function"){const l=t;return{items:[o=>({type:"dateTimeCalendar",path:e,...l(o)})],type:"ITEMS",itemType:"DATE_TIME_CALENDAR",tags:s??[]}}return{items:[{type:"dateTimeCalendar",path:e,...t}],type:"ITEMS",itemType:"DATE_TIME_CALENDAR",tags:s??[]}}function ai(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"DATE_INPUT",items:[{key:e,def:r=>({type:"dateInput",...n(r)})}],tags:s??[]}}const a={type:"dateInput",...t};return{type:"ITEMS",itemType:"DATE_INPUT",items:[{key:e,def:a}],tags:s??[]}}function li(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"DATE_PICKER",items:[{key:e,def:r=>({type:"datePicker",...n(r)})}],tags:s??[]}}const a={type:"datePicker",...t};return{type:"ITEMS",itemType:"DATE_PICKER",items:[{key:e,def:a}],tags:s??[]}}function ni(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"DATE_TIME_PICKER",items:[{key:e,def:r=>({type:"dateTimePicker",...n(r)})}],tags:s??[]}}const a={type:"dateTimePicker",...t};return{type:"ITEMS",itemType:"DATE_TIME_PICKER",items:[{key:e,def:a}],tags:s??[]}}function oi(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"RANGE_CALENDAR",items:[{key:e,def:r=>({type:"rangeCalendar",...n(r)})}],tags:s??[]}}const a={type:"rangeCalendar",...t};return{type:"ITEMS",itemType:"RANGE_CALENDAR",items:[{key:e,def:a}],tags:s??[]}}function ri(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"RANGE_DATE_INPUT",items:[{key:e,def:r=>({type:"rangeDateInput",...n(r)})}],tags:s??[]}}const a={type:"rangeDateInput",...t};return{type:"ITEMS",itemType:"RANGE_DATE_INPUT",items:[{key:e,def:a}],tags:s??[]}}function ui(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"RANGE_DATE_TIME_INPUT",items:[{key:e,def:r=>({type:"rangeDateTimeInput",...n(r)})}],tags:s??[]}}const a={type:"rangeDateTimeInput",...t};return{type:"ITEMS",itemType:"RANGE_DATE_TIME_INPUT",items:[{key:e,def:a}],tags:s??[]}}function pi(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"RANGE_DATE_TIME_CALENDAR",items:[{key:e,def:r=>({type:"rangeDateTimeCalendar",...n(r)})}],tags:s??[]}}const a={type:"rangeDateTimeCalendar",...t};return{type:"ITEMS",itemType:"RANGE_DATE_TIME_CALENDAR",items:[{key:e,def:a}],tags:s??[]}}function di(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"RANGE_DATE_TIME_PICKER",items:[{key:e,def:r=>({type:"rangeDateTimePicker",...n(r)})}],tags:s??[]}}const a={type:"rangeDateTimePicker",...t};return{type:"ITEMS",itemType:"RANGE_DATE_TIME_PICKER",items:[{key:e,def:a}],tags:s??[]}}function ci(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"RANGE_TIME_INPUT",items:[{key:e,def:r=>({type:"rangeTimeInput",...n(r)})}],tags:s??[]}}const a={type:"rangeTimeInput",...t};return{type:"ITEMS",itemType:"RANGE_TIME_INPUT",items:[{key:e,def:a}],tags:s??[]}}function yi(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"RANGE_DATE_PICKER",items:[{key:e,def:r=>({type:"rangeDatePicker",...n(r)})}],tags:s??[]}}const a={type:"rangeDatePicker",...t};return{type:"ITEMS",itemType:"RANGE_DATE_PICKER",items:[{key:e,def:a}],tags:s??[]}}function mi(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"RANGE_TIME_PICKER",items:[{key:e,def:r=>({type:"rangeTimePicker",...n(r)})}],tags:s??[]}}const a={type:"rangeTimePicker",...t};return{type:"ITEMS",itemType:"RANGE_TIME_PICKER",items:[{key:e,def:a}],tags:s??[]}}function Ti(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"TIME_INPUT",items:[{key:e,def:r=>({type:"timeInput",...n(r)})}],tags:s??[]}}const a={type:"timeInput",...t};return{type:"ITEMS",itemType:"TIME_INPUT",items:[{key:e,def:a}],tags:s??[]}}function gi(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"TIME_PICKER",items:[{key:e,def:r=>({type:"timePicker",...n(r)})}],tags:s??[]}}const a={type:"timePicker",...t};return{type:"ITEMS",itemType:"TIME_PICKER",items:[{key:e,def:a}],tags:s??[]}}function bi(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"DATE_TIME_INPUT",items:[{key:e,def:r=>({type:"dateTimeInput",...n(r)})}],tags:s??[]}}const a={type:"dateTimeInput",...t};return{type:"ITEMS",itemType:"DATE_TIME_INPUT",items:[{key:e,def:a}],tags:s??[]}}function _i(e,t,s,a){if(typeof s=="function"){const o=s;return{type:"ITEMS",itemType:"CUSTOM_INPUT",items:[{key:t,def:p=>({customType:e,...o(p)})}],tags:a??[]}}const l={customType:e,...s};return{type:"ITEMS",itemType:"CUSTOM_INPUT",items:[{key:t,def:l}],tags:a??[]}}function Ii(e,t){return{items:[e],type:"ITEMS",itemType:i.GuiItemTypes.ACTIONS,tags:t??[]}}function Ai(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"CUSTOM_ACTION",items:[u=>({customType:e,...n(u)})],tags:s??[]}}return{type:"ITEMS",itemType:"CUSTOM_ACTION",items:[{customType:e,...t}],tags:s??[]}}const re=(e,t)=>({type:"ITEMS",itemType:i.GuiItemTypes.DISPLAYS,items:[{render:e}],tags:t??[]});function Si(e,t){return{type:"ITEMS",itemType:"ALERTS",items:[e],tags:t??[]}}function hi(e,t){return{type:"ITEMS",itemType:"MARKDOWN_TEXTS",items:[e],tags:t??[]}}function ki(e,t,s){if(typeof t=="function"){const u=t;return{type:"ITEMS",itemType:"CUSTOM_DISPLAY",items:[p=>({customType:e,...u(p)})],tags:s??[]}}const{uid:a,...l}=t??{};return{type:"ITEMS",itemType:"CUSTOM_DISPLAY",items:[{customType:e,...a!=null?{uid:a}:{},props:Object.keys(l).length>0?l:void 0}],tags:s??[]}}const m=(e,t,s)=>({type:"ITEMS",itemType:i.GuiItemTypes.LAYOUTS,items:[{def:{widgetName:"flex",...t??{}},children:e}],tags:s??[]}),Ui=(e,t,s)=>m(e,{direction:"row",...t??{}},s),Ei=(e,t,s)=>m(e,{direction:"column",...t??{}},s),T=(e,t,s)=>({type:"ITEMS",itemType:i.GuiItemTypes.LAYOUTS,items:[{def:{widgetName:"grid",...t??{}},children:e}],tags:s??[]}),Pi=(e,t,s)=>T(e,{direction:"row",...t??{}},s),Di=(e,t,s)=>T(e,{direction:"column",...t??{}},s);function de(e){return e.toLowerCase().replace(/[^a-z0-9]+/g,"-").replace(/(^-|-$)/g,"")}function Li(e,t,s){const a=e.map(o=>({label:o.label,uid:o.uid??de(o.label)})),l=e.map(o=>({type:"ITEMS",itemType:i.GuiItemTypes.LAYOUTS,items:[{def:{uid:o.uid??de(o.label),direction:"column",widgetName:"grid"},children:o.children}],tags:[]}));return{type:"ITEMS",itemType:"TABS",items:[{def:{tabs:a,...t},children:l}],tags:s??[]}}function ce(e){return e.toLowerCase().replace(/[^a-z0-9]+/g,"-").replace(/(^-|-$)/g,"")}function Bi(e,t,s){const a=e.map(o=>({label:o.label,uid:o.uid??ce(o.label)})),l=e.map(o=>({type:"ITEMS",itemType:i.GuiItemTypes.LAYOUTS,items:[{def:{uid:o.uid??ce(o.label),direction:"column",widgetName:"grid"},children:o.children}],tags:[]}));return{type:"ITEMS",itemType:"ACCORDION",items:[{def:{sections:a,...t},children:l}],tags:s??[]}}function Mi(e,t,s,a){if(typeof s=="function"){const o=s;return{type:"ITEMS",itemType:"CUSTOM_LAYOUT",items:[{def:p=>({customType:e,...o(p)}),children:t}],tags:a??[]}}return{type:"ITEMS",itemType:"CUSTOM_LAYOUT",items:[{def:{customType:e,...s},children:t}],tags:a??[]}}function Ri(e,t,s){const{template:a,...l}=t;return{type:"ITEMS",itemType:"REPEATER",items:[{key:e,def:l,children:a}],tags:s??[]}}function vi(e,t,s){if(typeof t=="function"){const n=t;return{type:"ITEMS",itemType:"TAGS",items:[{key:e,def:r=>({type:"tags",...n(r)})}],tags:s??[]}}const a={type:"tags",...t};return{type:"ITEMS",itemType:"TAGS",items:[{key:e,def:a}],tags:s??[]}}const fi=e=>d(e,t=>t.type==="text"),Ci=e=>d(e,t=>t.type==="number"),Wi=e=>d(e,t=>t.type==="boolean"),ms=i.createSelectors({inputs:d,inputByUid:ye,textInputs:fi,numberInputs:Ci,booleanInputs:Wi,selects:$e,selectByUid:ze,dropdowns:at,dropdownByUid:lt,radiogroups:Oe,radiogroupByUid:He,checkboxes:Me,checkboxByUid:Re,textareas:Pe,textareaByUid:De,passwords:Le,passwordByUid:Be,currencies:Fe,currencyByUid:Ve,markdowns:gt,markdownByUid:bt,lists:je,listByUid:Je,multiDropdowns:nt,multiDropdownByUid:ot,multiLists:rt,multiListByUid:ut,fileUploads:pt,fileUploadByUid:dt,multiFileUploads:ct,multiFileUploadByUid:yt,calendars:Ae,calendarByUid:Se,dateTimeCalendars:he,dateTimeCalendarByUid:ke,dateInputs:ve,dateInputByUid:fe,timeInputs:Ce,timeInputByUid:We,timePickers:Ne,timePickerByUid:xe,dateTimeInputs:we,dateTimeInputByUid:Ge,datePickers:it,datePickerByUid:st,dateTimePickers:Ue,dateTimePickerByUid:Ee,rangeCalendars:Ke,rangeCalendarByUid:Ye,rangeDateInputs:_t,rangeDateInputByUid:It,rangeTimeInputs:At,rangeTimeInputByUid:St,rangeDateTimeInputs:ht,rangeDateTimeInputByUid:kt,rangeDateTimeCalendars:Ut,rangeDateTimeCalendarByUid:Et,rangeDateTimePickers:Pt,rangeDateTimePickerByUid:Dt,rangeDatePickers:Lt,rangeDatePickerByUid:Bt,rangeTimePickers:Mt,rangeTimePickerByUid:Rt,repeaters:y,repeaterByUid:X,actions:me,actionByUid:Te,layouts:ge,layoutByUid:be,displays:_e,displayByUid:Ie,alerts:Qe,alertByUid:Ze,markdownTexts:et,markdownTextByUid:tt,tabs:Xe,tabsByUid:qe,accordions:mt,accordionByUid:Tt,customInputs:Ct,customInputByUid:Wt,customActions:Nt,customActionByUid:xt,customDisplays:vt,customDisplayByUid:ft,customLayouts:wt,customLayoutByUid:Gt}),Ts={bareItemToWidget:e=>re(e),rootEntry:e=>{const t={def:{uid:"#root",direction:"column",widgetName:"grid"},children:e};return{type:"ITEMS",itemType:i.GuiItemTypes.LAYOUTS,items:[t],tags:[]}}},gs={inputs:{textInput:Ft,numberInput:Vt,booleanInput:Kt,select:Yt,dropdown:$t,radiogroup:zt,checkbox:Ot,textarea:Ht,password:Xt,currency:qt,markdown:jt,list:Jt,multiDropdown:Qt,multiList:Zt,fileUpload:ei,multiFileUpload:ti,calendar:ii,dateTimeCalendar:si,dateInput:ai,datePicker:li,dateTimePicker:ni,timeInput:Ti,timePicker:gi,dateTimeInput:bi,rangeCalendar:oi,rangeDateInput:ri,rangeDateTimeInput:ui,rangeDateTimeCalendar:pi,rangeDateTimePicker:di,rangeTimeInput:ci,rangeDatePicker:yi,rangeTimePicker:mi,repeater:Ri,tags:vi,custom:_i},actions:{button:Ii,custom:Ai},displays:{display:re,alert:Si,markdownText:hi,custom:ki},layouts:{flex:m,horizontalFlex:Ui,verticalFlex:Ei,grid:T,horizontalGrid:Pi,verticalGrid:Di,tabs:Li,accordion:Bi,custom:Mi}},ue=i.createImplementation({name:"gui",registry:oe,facade:gs,selectors:ms,adapter:Ts}),bs=ue.namespace,_s=ue.formDefs,Is=ue.resolveFormInput;exports._gslAccordionByUid=Tt;exports._gslAccordions=mt;exports._gslActionByUid=Te;exports._gslActions=me;exports._gslAlertByUid=Ze;exports._gslAlerts=Qe;exports._gslBooleanInputs=Wi;exports._gslCalendarByUid=Se;exports._gslCalendars=Ae;exports._gslCheckboxByUid=Re;exports._gslCheckboxes=Me;exports._gslCurrencies=Fe;exports._gslCurrencyByUid=Ve;exports._gslCustomActionByUid=xt;exports._gslCustomActions=Nt;exports._gslCustomDisplayByUid=ft;exports._gslCustomDisplays=vt;exports._gslCustomInputByUid=Wt;exports._gslCustomInputs=Ct;exports._gslCustomLayoutByUid=Gt;exports._gslCustomLayouts=wt;exports._gslDateInputByUid=fe;exports._gslDateInputs=ve;exports._gslDatePickerByUid=st;exports._gslDatePickers=it;exports._gslDateTimeCalendarByUid=ke;exports._gslDateTimeCalendars=he;exports._gslDateTimeInputByUid=Ge;exports._gslDateTimeInputs=we;exports._gslDateTimePickerByUid=Ee;exports._gslDateTimePickers=Ue;exports._gslDisplayByUid=Ie;exports._gslDisplays=_e;exports._gslDropdownByUid=lt;exports._gslDropdowns=at;exports._gslFileUploadByUid=dt;exports._gslFileUploads=pt;exports._gslInputByUid=ye;exports._gslInputs=d;exports._gslLayoutByUid=be;exports._gslLayouts=ge;exports._gslListByUid=Je;exports._gslLists=je;exports._gslMarkdownByUid=bt;exports._gslMarkdownTextByUid=tt;exports._gslMarkdownTexts=et;exports._gslMarkdowns=gt;exports._gslMultiDropdownByUid=ot;exports._gslMultiDropdowns=nt;exports._gslMultiFileUploadByUid=yt;exports._gslMultiFileUploads=ct;exports._gslMultiListByUid=ut;exports._gslMultiLists=rt;exports._gslNumberInputs=Ci;exports._gslPasswordByUid=Be;exports._gslPasswords=Le;exports._gslRadiogroupByUid=He;exports._gslRadiogroups=Oe;exports._gslRangeCalendarByUid=Ye;exports._gslRangeCalendars=Ke;exports._gslRangeDateInputByUid=It;exports._gslRangeDateInputs=_t;exports._gslRangeDatePickerByUid=Bt;exports._gslRangeDatePickers=Lt;exports._gslRangeDateTimeCalendarByUid=Et;exports._gslRangeDateTimeCalendars=Ut;exports._gslRangeDateTimeInputByUid=kt;exports._gslRangeDateTimeInputs=ht;exports._gslRangeDateTimePickerByUid=Dt;exports._gslRangeDateTimePickers=Pt;exports._gslRangeTimeInputByUid=St;exports._gslRangeTimeInputs=At;exports._gslRangeTimePickerByUid=Rt;exports._gslRangeTimePickers=Mt;exports._gslRepeaterByUid=X;exports._gslRepeaters=y;exports._gslSelectByUid=ze;exports._gslSelects=$e;exports._gslTabs=Xe;exports._gslTabsByUid=qe;exports._gslTags=Ji;exports._gslTagsByUid=Qi;exports._gslTextInputs=fi;exports._gslTextareaByUid=De;exports._gslTextareas=Pe;exports._gslTimeInputByUid=We;exports._gslTimeInputs=Ce;exports._gslTimePickerByUid=xe;exports._gslTimePickers=Ne;exports._guiAccordion=Bi;exports._guiAlert=Si;exports._guiBooleanInput=Kt;exports._guiButton=Ii;exports._guiCalendar=ii;exports._guiCheckbox=Ot;exports._guiCurrency=qt;exports._guiCustomAction=Ai;exports._guiCustomDisplay=ki;exports._guiCustomInput=_i;exports._guiCustomLayout=Mi;exports._guiDateInput=ai;exports._guiDatePicker=li;exports._guiDateTimeCalendar=si;exports._guiDateTimeInput=bi;exports._guiDateTimePicker=ni;exports._guiDisplay=re;exports._guiDropdown=$t;exports._guiFileUpload=ei;exports._guiFlex=m;exports._guiGrid=T;exports._guiHorizontalFlex=Ui;exports._guiHorizontalGrid=Pi;exports._guiList=Jt;exports._guiMarkdown=jt;exports._guiMarkdownText=hi;exports._guiMultiDropdown=Qt;exports._guiMultiFileUpload=ti;exports._guiMultiList=Zt;exports._guiNumberInput=Vt;exports._guiPassword=Xt;exports._guiRadiogroup=zt;exports._guiRangeCalendar=oi;exports._guiRangeDateInput=ri;exports._guiRangeDatePicker=yi;exports._guiRangeDateTimeCalendar=pi;exports._guiRangeDateTimeInput=ui;exports._guiRangeDateTimePicker=di;exports._guiRangeTimeInput=ci;exports._guiRangeTimePicker=mi;exports._guiRepeater=Ri;exports._guiSelect=Yt;exports._guiTabs=Li;exports._guiTags=vi;exports._guiTextInput=Ft;exports._guiTextarea=Ht;exports._guiTimeInput=Ti;exports._guiTimePicker=gi;exports._guiVerticalFlex=Ei;exports._guiVerticalGrid=Di;exports.defineShortcutType=ys;exports.formDefs=_s;exports.gui=bs;exports.resolveFormInput=Is;
|