@genesislcap/design-system-configurator 15.73.0 → 15.74.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.
Files changed (36) hide show
  1. package/bin/dsconfig.js +2 -3
  2. package/dist/109.109.304cb4c7b85cb8baeaa2.js +10563 -0
  3. package/dist/109.1450c61cf63649d0a94343c00ff5d796.js.map +1 -0
  4. package/dist/226.226.154ada679a59dd90a30b.js +2 -0
  5. package/dist/226.562e410dac1cc0c909ff7bef5492b654.js.map +1 -0
  6. package/dist/65.65.a3a4822c2fb8e0015030.js +3564 -0
  7. package/dist/65.a6e8a28b67bf967793cd1557e33cc6c3.js.map +1 -0
  8. package/dist/75.75.e45671d4ee67765b5f58.js +3 -0
  9. package/dist/{396.396.064741f605da4a3b9550.js.LICENSE.txt → 75.75.e45671d4ee67765b5f58.js.LICENSE.txt} +2 -0
  10. package/dist/75.f76b3396fedb3303b9e99f588965999f.js.map +1 -0
  11. package/dist/762.57e38da8fc6d8c63e28dd1d8b7f74278.js.map +1 -0
  12. package/dist/762.762.f30f855615b9202dacbc.js +11 -0
  13. package/dist/{837.837.344e327df5ff8612b7b9.js → 837.837.623cffcbd1ed2682b2e9.js} +15 -15
  14. package/dist/{837.6f20c7b0bc873ae0d341a788449e41ba.js.map → 837.bd8b531ecedde7e743c2d7d53d7f6a70.js.map} +1 -1
  15. package/dist/{966.966.979cbe81946d62240f81.js → 966.966.69a3b4ebaf86fe48e7e0.js} +36 -47
  16. package/dist/966.caebc32b863e86d1b6e93a1113bd5f1a.js.map +1 -0
  17. package/dist/designSystemConfigurator.551fd56917b7f5872d075435d1bef1ae.js.map +1 -0
  18. package/dist/index.html +1 -1
  19. package/dist/main.1ac4250019eab0eb7578590805998204.js.map +1 -0
  20. package/dist/main.f438459d5a9d83ec9611.js +2 -0
  21. package/dist/remoteEntry.js +2 -2
  22. package/package.json +11 -16
  23. package/dist/15.15.13338deccc2ff091f4d2.js +0 -5765
  24. package/dist/15.34aab92e89d5fb3f735784dbde436993.js.map +0 -1
  25. package/dist/277.277.fb90861c519ac92bb5ed.js +0 -2
  26. package/dist/277.78fab82e461bc0b972645dcf39de59e8.js.map +0 -1
  27. package/dist/396.396.064741f605da4a3b9550.js +0 -3
  28. package/dist/396.cc1b698d4c1c70ce0560d5b300004fcc.js.map +0 -1
  29. package/dist/711.711.270914c8b4bcf09d0d25.js +0 -1328
  30. package/dist/711.87cc8c871c73a25e0cc0f697fa7b3fa7.js.map +0 -1
  31. package/dist/947.4e3e73555c70a7904fef3eeca00f20bc.js.map +0 -1
  32. package/dist/947.947.998c248494a5c31177d8.js +0 -9247
  33. package/dist/966.d53759b454c3d0def808697e409f92dd.js.map +0 -1
  34. package/dist/designSystemConfigurator.ea433ff8a3c2750582d5a41eee15978e.js.map +0 -1
  35. package/dist/main.4d9460a192c58fdb71fcd3a501de4ff8.js.map +0 -1
  36. package/dist/main.6f8d122fb00e0a9adb9c.js +0 -2
@@ -0,0 +1,3564 @@
1
+ "use strict";(self.webpackChunk_genesislcap_design_system_configurator=self.webpackChunk_genesislcap_design_system_configurator||[]).push([[65],{31274(e,t,o){o.d(t,{u:()=>i});var r=o(60416);const i=(e,t,o)=>{(0,r.u_)(e);const i=t.split("-")[0],a=document.createElement(`${i}-dialog`),n=o?(e=>{let t=e.querySelector("#dialog-container");return t||(t=document.createElement("div"),t.setAttribute("id","dialog-container"),t.style.position="relative",e.appendChild(t)),t})(o):(0,r.jE)("dialog-container",t);n.appendChild(a),a.notification=e,a.show()}},60416(e,t,o){o.d(t,{cL:()=>u,jE:()=>p,uP:()=>d,u_:()=>c});var r=o(66506),i=o(52945),a=o(68424);const n=(0,r.createLogger)("foundation-notifications");let s=null;const l=new Map,d=e=>{var t,o;return`${null!==(t=null==e?void 0:e.title)&&void 0!==t?t:"Error"}: ${null!==(o=null==e?void 0:e.body)&&void 0!==o?o:"Something went wrong"}`},c=e=>{var t,o;n.log({message:d(e),level:(t=e,(null==t?void 0:t.logLevel)||(null===(o=null==t?void 0:t.config)||void 0===o?void 0:o.logLevel)||r.LogLevels.debug)})},p=(e,t)=>{let o=document.querySelector(`#${e}`);if(!o)if(l.has(e))o=l.get(e);else{const t=(0,i.fI)(document).find(t=>t.id===e);t&&(o=t,l.set(e,t))}if(!o){o=document.createElement("div"),o.setAttribute("id",e),o.style.zIndex="9999";const{element:t,prefix:r}=(0,a.DW)(document.body,"rapid");if(t)t.appendChild(o),s=t;else if(s)s.appendChild(o);else{const e=document.createElement(`${r}-design-system-provider`);e.appendChild(o),document.body.appendChild(e),s=e}}return o},u=e=>{for(var t,o;e&&!(e instanceof ShadowRoot);){const r=null===(t=null==e?void 0:e.getRootNode())||void 0===t?void 0:t.getElementById("banner-anchor");if(r)return r.style.position="relative",r;e=null===(o=null==e?void 0:e.getRootNode())||void 0===o?void 0:o.host}return m()},m=()=>{const e=document.createElement("div");return e.setAttribute("id","banner-anchor"),e.style.position="relative",document.body.insertBefore(e,document.body.firstChild),e}},70997(e,t,o){function r(e,t,o){const r=e=>"function"==typeof e?e:()=>e,i=r(t),a=r(o);return(t,o)=>e(t,o)?i(t,o):a(t,o)}o.d(t,{q:()=>r})},80273(e,t,o){o.d(t,{Du:()=>l,IT:()=>n,WP:()=>i,f4:()=>s,zz:()=>a});var r=o(52945);const i=(e,t)=>{(0,r.O5)(e,t)};var a,n;!function(e){e.Italic="italic",e.Normal="normal"}(a||(a={})),function(e){e[e.Thin=100]="Thin",e[e.Light=300]="Light",e[e.Regular=400]="Regular",e[e.Medium=500]="Medium",e[e.Bold=700]="Bold",e[e.Black=900]="Black"}(n||(n={}));const s=(e,t=a.Normal,o=n.Regular)=>`\n font-family: ${e};\n font-style: ${t};\n font-weight: ${o};\n`,l={minusOne:-1,minusTwo:-2,plusOne:1,plusTwo:2,plusThree:3,plusFour:4,plusFive:5,plusSix:6}},80065(e,t,o){o.r(t),o.d(t,{ColorPalette:()=>mr,ColorToken:()=>gr,ColorTokens:()=>wr,DesignSystemEditor:()=>Qo,DesignSystemExport:()=>cr,DesignSystemPreview:()=>Hr,EventName:()=>jo,PreviewApp:()=>Mr,PreviewComponents:()=>sr,PreviewForm:()=>Nr,PreviewGrid:()=>Ur,TypographyTokens:()=>Cr,defaultBodyFont:()=>Yo,fontFamilies:()=>Ho});var r=o(55823),i=o(57963),a=o(21409),n=o(83453),s=o.n(n),l=o(60496),d=o(33681),c=o(38370),p=o(54634),u=o(85090),m=o(31679),h=o(66506);const v=(0,h.createLogger)("foundation-form"),g=(e,t,o,r)=>{var i,a,n;if(!e||!o)return"";const s=e.filter(e=>e&&"anyOf"===e.keyword);if(0===s.length)return"";const l=null===(i=null==t?void 0:t.errorMessage)||void 0===i?void 0:i.anyOf,d=r||l,c="/"+o.replace(/\./g,"/"),p=s.find(e=>{const t=e.instancePath||"",o=e.schema;if(t===c)return!0;if(Array.isArray(o)){return o.flatMap(e=>t+"/"+Object.keys(e).flatMap(t=>e[t])).includes(c)}return!1});if(p){const e=p.schema||(null===(a=p.parentSchema)||void 0===a?void 0:a.anyOf);if(Array.isArray(e)){const t=new Set;e.forEach(e=>{(e&&Array.isArray(e.required)?e.required:[]).forEach(e=>t.add(e))});const r=o.split(".").pop();if(!r||!t.has(r))return"";const i=(null===(n=p.parentSchema)||void 0===n?void 0:n.properties)||{},a=Array.from(t).map(e=>((e,t)=>{const o=t[e]||{},r=["required"];return"number"==typeof o.minLength&&r.push("minLength"),"number"==typeof o.maxLength&&r.push("maxLength"),"number"==typeof o.minimum&&r.push("minimum"),"number"==typeof o.maximum&&r.push("maximum"),"number"!=typeof o.exclusiveMinimum&&!0!==o.exclusiveMinimum||r.push("exclusiveMinimum"),"number"!=typeof o.exclusiveMaximum&&!0!==o.exclusiveMaximum||r.push("exclusiveMaximum"),"string"==typeof o.pattern&&r.push("pattern"),o.type&&r.push(`type:${o.type}`),`${e}${r.length>1?` (${r.join(", ")})`:""}`})(e,i));if(1===a.length)return d||`Field ${a[0]} is required.`;const s=2===a.length?`${a[0]} or ${a[1]}`:`${a.slice(0,-1).join(", ")}, or ${a[a.length-1]}`;return d||`One of ${s} must be provided.`}return d||p.message||""}return""},b=(y="foundation-form",d.css`
2
+ ${y} .foundation-control-wrapper-root {
3
+ margin-bottom: var(--wrapper-root-margin-bottom, calc(var(--design-unit) * 4px));
4
+ }
5
+ ${y} .foundation-control-wrapper-root.labelLeft {
6
+ display: flex;
7
+ flex-wrap: wrap;
8
+ }
9
+ ${y} .foundation-control-wrapper-label {
10
+ color: var(--neutral-foreground-hint);
11
+ margin-bottom: var(--control-label-margin, calc(var(--design-unit) * 2px));
12
+ display: flex;
13
+ justify-content: space-between;
14
+ font-weight: 700;
15
+ cursor: default;
16
+ font-size: var(--type-ramp-base-font-size);
17
+ }
18
+ ${y} .foundation-control-wrapper-label.visually-hidden {
19
+ position: absolute;
20
+ width: 1px;
21
+ height: 1px;
22
+ padding: 0;
23
+ margin: -1px;
24
+ overflow: hidden;
25
+ clip: rect(0, 0, 0, 0);
26
+ clip-path: inset(50%);
27
+ white-space: nowrap;
28
+ border: 0;
29
+ }
30
+ ${y} .labelLeft .foundation-control-wrapper {
31
+ flex: 1 1 auto;
32
+ width: auto;
33
+ align-items: flex-start;
34
+ flex-wrap: wrap;
35
+ }
36
+ ${y} .labelLeft .foundation-control-wrapper-label {
37
+ flex: 0 1 auto;
38
+ width: var(--form-label-left-width, calc(var(--design-unit) * 30px));
39
+ min-width: var(--form-label-left-width, calc(var(--design-unit) * 30px));
40
+ margin-right: calc(var(--design-unit) * 2px);
41
+ align-items: center;
42
+ margin-bottom: 0;
43
+ }
44
+ ${y} .labelLeft .foundation-control-wrapper-error {
45
+ margin-left: 0;
46
+ flex: 1 1 100%;
47
+ text-align: right;
48
+ }
49
+ ${y} .foundation-control-wrapper-error {
50
+ font-size: 12px;
51
+ color: #f9644d;
52
+ margin-left: 10px;
53
+ }
54
+ ${y} .foundation-control-wrapper {
55
+ display: flex;
56
+ width: 100%;
57
+ align-items: center;
58
+ }
59
+ `);var y;const f=e=>{const{innerTemplate:t,prefix:o,hideLabel:r=!1}=e;return d.html`
60
+ ${(0,d.when)(e=>{var t;return null===(t=e.control)||void 0===t?void 0:t.visible},d.html`
61
+ <div
62
+ class=${e=>{var t,o,r,i;const a=function(e){var t,o,r,i,a,n;const s=null===(r=null===(o=null===(t=null==e?void 0:e.control)||void 0===t?void 0:t.uischema)||void 0===o?void 0:o.options)||void 0===r?void 0:r.className;if("function"==typeof s)return null!==(n=s(null===(a=null===(i=e.jsonforms)||void 0===i?void 0:i.core)||void 0===a?void 0:a.data))&&void 0!==n?n:"";return null!=s?s:""}(e);return(0,m.x)(["foundation-control-wrapper-root",!0],["labelLeft","left"===(null===(i=null===(r=null===(o=null===(t=e.jsonforms)||void 0===t?void 0:t.core)||void 0===o?void 0:o.uischema)||void 0===r?void 0:r.options)||void 0===i?void 0:i.labelPlacement)],[a,!!a])}}
63
+ id=${e=>e.control.path+"-wrapper"}
64
+ data-test-id=${e=>e.control.path+"-wrapper"}
65
+ role="group"
66
+ aria-labelledby=${e=>$(e)?e.control.path+"-label":null}
67
+ >
68
+ ${(0,d.when)(e=>$(e),d.html`
69
+ <label
70
+ id="${e=>e.control.path+"-label"}"
71
+ for="${e=>e.control.path}"
72
+ class="${()=>(0,m.x)("foundation-control-wrapper-label",["visually-hidden",r])}"
73
+ >
74
+ <span>
75
+ ${e=>$(e)}${(0,d.when)(e=>{var t,o;return null===(o=null===(t=e.control.uischema)||void 0===t?void 0:t.options)||void 0===o?void 0:o.tooltip},d.html`
76
+ <${o}-icon
77
+ tooltip="${e=>{var t,o;return null===(o=null===(t=e.control.uischema)||void 0===t?void 0:t.options)||void 0===o?void 0:o.tooltip}}"
78
+ tooltip-id="${e=>e.control.path+"-tooltip"}"
79
+ ></${o}-icon>
80
+ `)}
81
+ </span>
82
+ </label>
83
+ `)}
84
+
85
+ <div class="foundation-control-wrapper" part="wrapper">${t}</div>
86
+ <div
87
+ class="${e=>(e.control.errors||w(e))&&e.touched?"foundation-control-wrapper-error":"foundation-control-wrapper-description"}"
88
+ >
89
+ ${e=>e.touched&&(e.control.errors||w(e))?[e.control.errors,w(e)].filter(Boolean).join(" "):function(e){var t;return!!(null==e?void 0:e.control)&&!(0,l.Pfe)(e.control.visible,e.control.description,e.control.isFocused,!!(null===(t=e.control.config)||void 0===t?void 0:t.showUnfocusedDescription))}(e)?e.control.description:""}
90
+ </div>
91
+ </div>
92
+ `)}
93
+ `};function $(e){var t,o,r;return(null==e?void 0:e.control)?(null===(o=null===(t=e.control.uischema)||void 0===t?void 0:t.options)||void 0===o?void 0:o.hideLabel)?"":(0,l.m25)(e.control.label,e.control.required,!!(null===(r=e.control.config)||void 0===r?void 0:r.hideRequiredAsterisk)):""}function w(e){var t,o,r,i,a,n,s,l;return g(null===(o=null===(t=e.jsonforms)||void 0===t?void 0:t.core)||void 0===o?void 0:o.errors,null===(i=null===(r=e.jsonforms)||void 0===r?void 0:r.core)||void 0===i?void 0:i.schema,null===(a=e.control)||void 0===a?void 0:a.path,null===(l=null===(s=null===(n=e.control)||void 0===n?void 0:n.uischema)||void 0===s?void 0:s.options)||void 0===l?void 0:l.anyOfErrorMessage)}const x=d.html`
94
+ <template>
95
+ ${(0,d.when)(e=>{var t;return null===(t=e.control)||void 0===t?void 0:t.visible},d.html`
96
+ <div
97
+ class=${e=>{var t,o,r,i;return(0,m.x)(["wrapperRoot",!0],["labelLeft","left"===(null===(i=null===(r=null===(o=null===(t=e.jsonForms)||void 0===t?void 0:t.core)||void 0===o?void 0:o.uischema)||void 0===r?void 0:r.options)||void 0===i?void 0:i.labelPlacement)])}}
98
+ id=${e=>e.control.path+"-wrapper"}
99
+ data-test-id=${e=>e.control.path+"-wrapper"}
100
+ role="group"
101
+ aria-labelledby=${e=>e.computedLabel?e.control.path+"-label":null}
102
+ >
103
+ ${(0,d.when)(e=>e.computedLabel,d.html`
104
+ <label
105
+ id="${e=>e.control.path+"-label"}"
106
+ for="${e=>e.control.path}"
107
+ class="${e=>(0,m.x)("label",["visually-hidden",e.hideLabel])}"
108
+ >
109
+ <span>
110
+ ${e=>e.computedLabel}${(0,d.when)(e=>{var t,o;return null===(o=null===(t=e.control.uischema)||void 0===t?void 0:t.options)||void 0===o?void 0:o.tooltip},e=>e.getPrefixedTooltip)}
111
+ </span>
112
+ </label>
113
+ `)}
114
+
115
+ <div class="wrapper" part="wrapper">
116
+ <slot></slot>
117
+ </div>
118
+ <div
119
+ class="${e=>(e.control.errors||e.anyOfError)&&e.touched?"error":"description"}"
120
+ >
121
+ ${e=>e.touched&&(e.control.errors||e.anyOfError)?[e.control.errors,e.anyOfError].filter(Boolean).join(" "):e.showDescription?e.control.description:""}
122
+ </div>
123
+ </div>
124
+ `)}
125
+ </template>
126
+ `,S=d.css`
127
+ .visually-hidden {
128
+ position: absolute;
129
+ width: 1px;
130
+ height: 1px;
131
+ padding: 0;
132
+ margin: -1px;
133
+ overflow: hidden;
134
+ clip: rect(0, 0, 0, 0);
135
+ clip-path: inset(50%);
136
+ white-space: nowrap;
137
+ border: 0;
138
+ }
139
+
140
+ .wrapperRoot {
141
+ margin-bottom: var(--wrapper-root-margin-bottom, calc(var(--design-unit) * 4px));
142
+ }
143
+
144
+ .wrapperRoot.labelLeft {
145
+ display: flex;
146
+ flex-wrap: wrap;
147
+ }
148
+
149
+ .label {
150
+ color: var(--neutral-foreground-hint);
151
+ margin-bottom: var(--control-label-margin, calc(var(--design-unit) * 2px));
152
+ display: flex;
153
+ justify-content: space-between;
154
+ font-weight: 700;
155
+ cursor: default;
156
+ }
157
+
158
+ .labelLeft .wrapper {
159
+ flex: 1 1 auto;
160
+ width: auto;
161
+ align-items: flex-start;
162
+ flex-wrap: wrap;
163
+ }
164
+
165
+ .labelLeft .label {
166
+ flex: 0 1 auto;
167
+ width: calc(var(--design-unit) * 30px);
168
+ margin-right: calc(var(--design-unit) * 2px);
169
+ align-items: center;
170
+ margin-bottom: 0;
171
+ }
172
+
173
+ .labelLeft .error {
174
+ margin-left: 0;
175
+ flex: 1 1 100%;
176
+ text-align: right;
177
+ }
178
+
179
+ .error {
180
+ font-size: 12px;
181
+ color: #f9644d;
182
+ margin-left: 10px;
183
+ }
184
+
185
+ .wrapper {
186
+ display: flex;
187
+ width: 100%;
188
+ align-items: center;
189
+ }
190
+ `;let C=class extends d.FASTElement{constructor(){super(...arguments),this.hideLabel=!1}connectedCallback(){super.connectedCallback(),v.warn("<control-wrapper> is deprecated and will be removed in a future major version. Migrate to the `controlWrapperTemplate` function for light-DOM rendering.")}get showDescription(){var e;return!(0,l.Pfe)(this.control.visible,this.control.description,this.control.isFocused,!!(null===(e=this.control.config)||void 0===e?void 0:e.showUnfocusedDescription))}get computedLabel(){var e,t,o,r;return(null===(o=null===(t=null===(e=this.control)||void 0===e?void 0:e.uischema)||void 0===t?void 0:t.options)||void 0===o?void 0:o.hideLabel)?"":(0,l.m25)(this.control.label,this.control.required,!!(null===(r=this.control.config)||void 0===r?void 0:r.hideRequiredAsterisk))}get getPrefixedTooltip(){var e,t;return d.html`
191
+ <${this.prefix}-icon tooltip="${null===(t=null===(e=this.control.uischema)||void 0===e?void 0:e.options)||void 0===t?void 0:t.tooltip}" tooltip-id="${this.control.path+"-tooltip"}"></${this.prefix}-icon>`}get anyOfError(){var e,t,o,r,i,a,n,s;return g(null===(t=null===(e=this.jsonForms)||void 0===e?void 0:e.core)||void 0===t?void 0:t.errors,null===(r=null===(o=this.jsonForms)||void 0===o?void 0:o.core)||void 0===r?void 0:r.schema,null===(i=this.control)||void 0===i?void 0:i.path,null===(s=null===(n=null===(a=this.control)||void 0===a?void 0:a.uischema)||void 0===n?void 0:n.options)||void 0===s?void 0:s.anyOfErrorMessage)}};(0,r.Cg)([d.observable],C.prototype,"control",void 0),(0,r.Cg)([d.observable],C.prototype,"jsonForms",void 0),(0,r.Cg)([d.observable],C.prototype,"touched",void 0),(0,r.Cg)([(0,d.attr)({mode:"boolean",attribute:"hide-label"})],C.prototype,"hideLabel",void 0),(0,r.Cg)([d.attr],C.prototype,"prefix",void 0),(0,r.Cg)([d.volatile],C.prototype,"showDescription",null),(0,r.Cg)([d.volatile],C.prototype,"computedLabel",null),(0,r.Cg)([d.volatile],C.prototype,"getPrefixedTooltip",null),(0,r.Cg)([d.volatile],C.prototype,"anyOfError",null),C=(0,r.Cg)([(0,d.customElement)({name:"control-wrapper",styles:S,template:x})],C);const A=(e="rapid")=>`\n ${e}-combobox::part(listbox) {\n max-height: 500%;\n overflow-y: scroll;\n }\n`,I=d.css`
192
+ ${b}
193
+
194
+ foundation-form {
195
+ border: calc(${p.strokeWidth} * 1px) solid transparent;
196
+ margin: 0;
197
+ border-radius: calc(${p.controlCornerRadius} * 1px);
198
+ padding: calc(${p.designUnit} * 1px);
199
+ min-width: 64px;
200
+ width: 100%;
201
+ height: 100%;
202
+ display: flex;
203
+ flex-direction: column;
204
+ overflow: hidden;
205
+ box-sizing: border-box;
206
+ }
207
+
208
+ foundation-form json-forms {
209
+ flex: 1;
210
+ overflow-y: auto;
211
+ min-height: 0;
212
+ scrollbar-color: var(--neutral-stroke-rest) transparent;
213
+ }
214
+
215
+ foundation-form .actions {
216
+ display: flex;
217
+ flex-direction: row;
218
+ align-items: flex-end;
219
+ justify-content: flex-end;
220
+ padding: calc(${p.designUnit} * 1px);
221
+ gap: 10px;
222
+ }
223
+
224
+ foundation-form .approval-message-actions {
225
+ display: flex;
226
+ justify-content: flex-end;
227
+ gap: calc(${p.designUnit} * 2px);
228
+ margin-top: calc(${p.designUnit} * 2px);
229
+ }
230
+
231
+ foundation-form .submit-button {
232
+ margin: 0;
233
+ }
234
+
235
+ foundation-form .reset-button {
236
+ margin-right: auto;
237
+ }
238
+
239
+ foundation-form .csv-upload-section {
240
+ display: flex;
241
+ align-items: center;
242
+ gap: calc(${p.designUnit} * 3px);
243
+ padding: calc(${p.designUnit} * 1px) 0;
244
+ margin-bottom: calc(${p.designUnit} * 2px);
245
+ }
246
+
247
+ foundation-form .csv-file-input {
248
+ display: none;
249
+ }
250
+
251
+ /* Card-like styling for CSV buttons - matches array item aesthetic */
252
+ foundation-form .csv-template-button,
253
+ foundation-form .csv-import-button {
254
+ display: flex;
255
+ align-items: center;
256
+ gap: calc(${p.designUnit} * 1px);
257
+ padding: calc(${p.designUnit} * 2px) calc(${p.designUnit} * 3px);
258
+ background-color: var(--neutral-layer-1, #fff);
259
+ border: 1px solid var(--neutral-stroke-rest, rgb(0 0 0 / 12%));
260
+ border-radius: calc(${p.designUnit} * 2px);
261
+ box-shadow:
262
+ 0 1px 2px rgb(0 0 0 / 4%),
263
+ 0 4px 8px rgb(0 0 0 / 6%);
264
+ transition:
265
+ box-shadow 0.2s ease,
266
+ border-color 0.15s ease;
267
+ }
268
+
269
+ foundation-form .csv-template-button:hover,
270
+ foundation-form .csv-import-button:hover {
271
+ box-shadow:
272
+ 0 2px 4px rgb(0 0 0 / 6%),
273
+ 0 6px 12px rgb(0 0 0 / 8%);
274
+ }
275
+
276
+ /* ── Layout wrappers ────────────────────────────────────────────────────── */
277
+
278
+ .fl-layout-label {
279
+ color: var(--neutral-foreground-hint);
280
+ }
281
+
282
+ .fl-vertical-layout {
283
+ display: flex;
284
+ flex-direction: column;
285
+ }
286
+
287
+ .fl-horizontal-layout {
288
+ display: flex;
289
+ flex-direction: row;
290
+ gap: calc(${p.designUnit} * 2px);
291
+ }
292
+
293
+ .fl-horizontal-layout-item {
294
+ flex: 1;
295
+ min-width: 0;
296
+ }
297
+
298
+ .fl-form-grid-layout {
299
+ display: grid;
300
+ grid-template-columns: repeat(4, 1fr);
301
+ gap: calc(${p.designUnit} * 2px);
302
+ }
303
+
304
+ .fl-2-column-layout {
305
+ display: flex;
306
+ flex-flow: row wrap;
307
+ justify-content: space-between;
308
+ }
309
+
310
+ .fl-2-column-item {
311
+ width: 49%;
312
+ }
313
+
314
+ .fl-group-label {
315
+ color: var(--neutral-foreground-rest);
316
+ padding-bottom: calc(${p.designUnit} * 1px);
317
+ margin-bottom: calc(${p.designUnit} * 2px);
318
+ font-weight: 600;
319
+ font-size: var(--type-ramp-base-font-size);
320
+ display: flex;
321
+ justify-content: space-between;
322
+ }
323
+ `.withBehaviors((0,c.forcedColorsStylesheetBehavior)(d.css`
324
+ foundation-form {
325
+ background: ${u.A.Canvas};
326
+ border-color: ${u.A.CanvasText};
327
+ }
328
+ `));var k=o(20633),M=o(40729);const L={"^[\\+]?[(]?[0-9]{3}[)]?[-\\s\\.]?[0-9]{3}[-\\s\\.]?[0-9]{4,6}$":"Invalid phone number. Must match +###-###-######"},E=e=>{var t,o;return"null"===e.type||Array.isArray(e.type)&&e.type.includes("null")||[...null!==(t=e.oneOf)&&void 0!==t?t:[],...null!==(o=e.anyOf)&&void 0!==o?o:[]].some(E)},T=e=>e&&E(e)?null:void 0,R=(e,t)=>"input"===e.type&&void 0!==(null==t?void 0:t.default)&&void 0===T(t)?"":void 0,_=d.html`
329
+ <template>
330
+ ${(0,d.when)(e=>!1,d.html`
331
+ <rapid-button class="clipboard-button" @click=${e=>e.copyUISchemaToClipboard()}>
332
+ Copy autogenerated UI Schema
333
+ </rapid-button>
334
+ `)}
335
+ ${(0,d.when)(e=>e.jsonforms&&e.dispatch&&e.props,d.html`
336
+ <dispatch-renderer
337
+ :jsonforms=${e=>e.jsonforms}
338
+ :dispatch=${e=>e.dispatch}
339
+ :props=${e=>e.props}
340
+ :prefix=${e=>e.prefix}
341
+ :submitted=${e=>e.submitted}
342
+ />
343
+ `)}
344
+ </template>
345
+ `,D=(e,t,o)=>{var r,i,a,n;return null!==(n=null===(a=null===(i=null===(r=null==o?void 0:o.options)||void 0===r?void 0:r.i18n)||void 0===i?void 0:i.error)||void 0===a?void 0:a[e.keyword])&&void 0!==n?n:((e,t,o)=>{var r;return"pattern"===(null==e?void 0:e.keyword)?null!==(r=L[e.params.pattern])&&void 0!==r?r:"Invalid pattern.":(0,l.mXY)(e,t,o)})(e,t,o)};let N=class extends d.FASTElement{constructor(){super(...arguments),this._submitted=!1,this.serverErrors=[],this.ajv=(0,l.grE)({useDefaults:!0,$data:!0}),this.rowSubmitStatuses=new Map,this.bulkInsert=!1,this.serverFieldErrors=[],this.dispatch=e=>{const t=(0,l.kkC)(this.jsonforms.core,((e,t)=>{if(e.type!==l.z$1||!e.path||!t)return e;const{path:o,updater:r}=e;return Object.assign(Object.assign({},e),{updater:e=>{var i;return null!==(i=r(e))&&void 0!==i?i:T(l.XKv.schema(t,["#",...o.replace(/^\//,"").split(/[./]/).map(e=>/^\d+$/.test(e)?"items":`properties/${e}`)].join("/"),t))}})})(e,this.schema));if(e.path){const t=e.path.startsWith("/")?e.path:`/${e.path.replace(/\./g,"/")}`;this.serverErrors=this.serverErrors.filter(e=>e.instancePath!==t)}this.applyAdditionalErrorsToCore(t,e.path)},this.validate=(e,t)=>{var o,r;void 0===t&&(t=null===(r=null===(o=this.jsonforms)||void 0===o?void 0:o.core)||void 0===r?void 0:r.data);const i=[],a=e=>{var o,r,n,s,d;const c=null===(o=null==e?void 0:e.options)||void 0===o?void 0:o.validateFn;if("function"==typeof c){const o=null===(n=null===(r=null==e?void 0:e.scope)||void 0===r?void 0:r.split("/"))||void 0===n?void 0:n.pop(),a=null==e?void 0:e.label;let d=null!==(s=c(t,o,a))&&void 0!==s?s:[];if(Array.isArray(d)||(d=[d]),(null==e?void 0:e.scope)&&this.schema&&d.length){const t=l.XKv.schema(this.schema,e.scope,this.schema);t&&(d=d.map(e=>{var o;return Object.assign(Object.assign({},e),{parentSchema:null!==(o=e.parentSchema)&&void 0!==o?o:t})}))}i.push(...d)}(null==e?void 0:e.elements)&&e.elements.forEach(e=>{a(e)}),(null===(d=null==e?void 0:e.options)||void 0===d?void 0:d.childElements)&&e.options.childElements.forEach(e=>{a(e)})};return a(e),i}}get submitted(){return d.Observable.track(this,"submitted"),this._submitted}set submitted(e){this._submitted=e,d.Observable.notify(this,"submitted")}prefixChanged(){this.schemaChanged()}schemaChanged(){var e,t,o,r,i,a;if(!this.schema)return;this.serverErrors=[],this.uichemaToUse=null!==(e=this.uischema)&&void 0!==e?e:l.wyb.uiSchema(this.schema),this.uischema||v.debug("UI schema not provided. Auto generated schema:",this.uichemaToUse);const n=null===(o=null===(t=this.jsonforms)||void 0===t?void 0:t.core)||void 0===o?void 0:o.data;this.jsonforms={core:(()=>{const e={data:this.data,schema:this.schema,uischema:this.uichemaToUse};return(0,l.kkC)(e,l.En0.init(this.data,this.schema,this.uichemaToUse,{validationMode:this.validationMode||"ValidateAndShow",ajv:this.ajv,additionalErrors:this.buildAdditionalErrors(this.uichemaToUse,this.data)}))})(),config:(0,l.tWo)(void 0,l.En0.setConfig(this.config)),i18n:(0,l.Fxm)(this.i18n,l.En0.updateI18n(null===(r=this.i18n)||void 0===r?void 0:r.locale,null===(i=this.i18n)||void 0===i?void 0:i.translate,(null===(a=this.i18n)||void 0===a?void 0:a.translateError)||D)),renderers:this.renderers,readonly:this.readonly,rowSubmitStatuses:this.rowSubmitStatuses,bulkInsert:this.bulkInsert};const s=this.buildAdditionalErrors(this.uichemaToUse,this.data);this.jsonforms.core.data!==n&&this.$emit("data-change",{data:this.jsonforms.core.data,errors:this.jsonforms.core.errors,additionalErrors:s})}uischemaChanged(){this.schemaChanged()}dataChanged(){var e;if(!(null===(e=this.jsonforms)||void 0===e?void 0:e.core))return void this.schemaChanged();if(this.jsonforms.core.data===this.data)return;const t=(0,l.kkC)(this.jsonforms.core,l.En0.updateCore(this.data,this.schema,this.uichemaToUse));this.applyAdditionalErrorsToCore(t)}renderersChanged(){this.schemaChanged()}validationModeChanged(){this.schemaChanged()}ajvChanged(){this.schemaChanged()}readonlyChanged(){this.schemaChanged()}configChanged(){this.schemaChanged()}rowSubmitStatusesChanged(){this.jsonforms&&(this.jsonforms=Object.assign(Object.assign({},this.jsonforms),{rowSubmitStatuses:this.rowSubmitStatuses}))}bulkInsertChanged(){this.jsonforms&&(this.jsonforms=Object.assign(Object.assign({},this.jsonforms),{bulkInsert:this.bulkInsert}))}serverFieldErrorsChanged(){this.setServerErrors(this.serverFieldErrors)}get props(){var e;if(!this.schema&&!this.uischema)return;const t=null!==(e=this.uischema)&&void 0!==e?e:l.wyb.uiSchema(this.schema);return{uischema:Object.assign(Object.assign({},t),{elements:t.elements.map(e=>"#/properties/TIMESTAMP"===e.scope?Object.assign(Object.assign({},e),{options:{hidden:!0}}):e)}),schema:this.schema,path:"",enabled:!0,visible:!0}}setServerErrors(e){this.serverErrors=null!=e?e:[],this.refreshAdditionalErrors()}clearServerErrors(){this.serverErrors=[],this.refreshAdditionalErrors()}buildAdditionalErrors(e,t){return[...this.validate(e,t),...this.serverErrors]}applyAdditionalErrorsToCore(e,t){const o=this.buildAdditionalErrors(this.uichemaToUse,e.data);this.jsonforms=Object.assign(Object.assign({},this.jsonforms),{core:Object.assign(Object.assign({},e),{additionalErrors:o})}),this.$emit("data-change",{data:this.jsonforms.core.data,errors:this.jsonforms.core.errors,additionalErrors:o,path:t})}refreshAdditionalErrors(){var e;(null===(e=this.jsonforms)||void 0===e?void 0:e.core)&&this.uichemaToUse&&this.applyAdditionalErrorsToCore(this.jsonforms.core)}copyUISchemaToClipboard(){return(0,r.sH)(this,void 0,void 0,function*(){try{yield navigator.clipboard.writeText(JSON.stringify(this.uichemaToUse)),v.debug("Autogenerated UI schema copied to clipboard")}catch(e){v.error("Failed to copy autogenerated UI schema: ",e)}})}};(0,r.Cg)([d.observable],N.prototype,"prefix",void 0),(0,r.Cg)([d.observable],N.prototype,"jsonforms",void 0),(0,r.Cg)([d.observable],N.prototype,"i18n",void 0),(0,r.Cg)([d.observable],N.prototype,"uichemaToUse",void 0),(0,r.Cg)([d.observable],N.prototype,"schema",void 0),(0,r.Cg)([d.observable],N.prototype,"uischema",void 0),(0,r.Cg)([d.observable],N.prototype,"data",void 0),(0,r.Cg)([d.observable],N.prototype,"renderers",void 0),(0,r.Cg)([d.observable],N.prototype,"validationMode",void 0),(0,r.Cg)([d.observable],N.prototype,"ajv",void 0),(0,r.Cg)([(0,d.attr)({mode:"boolean"})],N.prototype,"readonly",void 0),(0,r.Cg)([d.observable],N.prototype,"config",void 0),(0,r.Cg)([d.observable],N.prototype,"rowSubmitStatuses",void 0),(0,r.Cg)([d.observable],N.prototype,"bulkInsert",void 0),(0,r.Cg)([d.observable],N.prototype,"serverFieldErrors",void 0),N=(0,r.Cg)([(0,d.customElement)({name:"json-forms",template:_,styles:d.css`
346
+ .clipboard-button {
347
+ display: flex;
348
+ }
349
+ `,shadowOptions:null})],N);const P=e=>(null==e?void 0:e.elements)?Object.assign(Object.assign({},e),{elements:e.elements.map(e=>e.elements?P(e):Object.assign(Object.assign({},e),{label:!1,options:Object.assign(Object.assign({},e.options),{hideLabel:!0,tooltip:void 0})}))}):e,z=e=>{var t;const o=null===(t=e.parent.form.jsonforms)||void 0===t?void 0:t.rowSubmitStatuses;return null==o?void 0:o.get(e.index)},O=(e,t)=>{const o=z(e);return(null==o?void 0:o.status)===t},F=e=>O(e,"success"),j=(e="rapid")=>d.html`
350
+ <template>
351
+ ${(0,d.when)(e=>e.isGridView,d.html`
352
+ <div class="grid-header">
353
+ <span class="grid-header-status-spacer"></span>
354
+ ${(0,d.repeat)(e=>e.gridViewHeaderCells,d.html`
355
+ <span class="grid-header-cell">
356
+ <span class="grid-header-label-text">${e=>e.label}</span>
357
+ ${(0,d.when)(e=>e.required,d.html`
358
+ <span class="grid-header-required-indicator">*</span>
359
+ `)}
360
+ ${(0,d.when)(e=>e.tooltip,d.html`
361
+ <${e}-icon
362
+ class="grid-header-tooltip"
363
+ tooltip="${e=>e.tooltip}"
364
+ tooltip-id="${(e,t)=>`array-grid-header-${t.parent.control.path.replace(/[^a-zA-Z0-9]/g,"-")}-${t.index}-tooltip`}"
365
+ ></${e}-icon>
366
+ `)}
367
+ </span>
368
+ `)}
369
+ <span class="grid-header-actions">Actions</span>
370
+ </div>
371
+ `)}
372
+ ${(0,d.repeat)(e=>Array(e.control.data),d.html`
373
+ <div class="array-list ${(e,t)=>{const o=z(t);return[o?`row-status-${o.status}`:"",t.parent.isGridView?"grid-row":""].filter(Boolean).join(" ")}}"
374
+ data-row-index="${(e,t)=>t.index}"
375
+ >
376
+ ${(0,d.when)((e,t)=>{var o;return!1!==(null===(o=t.parent.control.uischema.options)||void 0===o?void 0:o.showRowStatusIndicator)},d.html`
377
+ <div class="row-status-indicator">
378
+ <${e}-progress-ring class="status-spinner"></${e}-progress-ring>
379
+ <${e}-icon name="check-circle" class="status-icon status-success"></${e}-icon>
380
+ <${e}-icon
381
+ name="times-circle"
382
+ class="status-icon status-failed"
383
+ title="${(e,t)=>{var o;const r=z(t);return(null===(o=null==r?void 0:r.errors)||void 0===o?void 0:o.map(e=>e.TEXT).join(", "))||"Failed"}}"
384
+ ></${e}-icon>
385
+ </div>
386
+ `)}
387
+ <dispatch-renderer
388
+ :submitted=${(e,t)=>t.parent.form.submitted}
389
+ :dispatch=${(e,t)=>t.parent.form.dispatch}
390
+ :jsonforms=${(e,t)=>t.parent.form.jsonforms}
391
+ :prefix=${(e,t)=>t.parent.form.prefix}
392
+ :props=${(e,t)=>{var o,r,i,a;const n=null===(o=t.parent.control.uischema.options)||void 0===o?void 0:o.childUiSchema,s=null===(i=null===(r=t.parent.form.jsonforms)||void 0===r?void 0:r.core)||void 0===i?void 0:i.data,d=null===(a=t.parent.control.data)||void 0===a?void 0:a[t.index];let c=((e,t,o,r,i)=>{if("function"==typeof e){const a=e(t,o,r);return null!=a?a:i}return i})(n,t.index,d,s,t.parent.uiSchema);return t.parent.isGridView&&(c=c===t.parent.uiSchema?t.parent.gridViewUiSchema:P(c)),{uischema:c,schema:t.parent.schema,renderers:t.parent.control.renderers,path:(0,l.HfV)(t.parent.control.path,`${t.index}`),enabled:t.parent.control.enabled&&!F(t)}}}
393
+ ></dispatch-renderer>
394
+ <div class="button-group">
395
+ <${e}-button
396
+ ?hidden=${(e,t)=>{var o;return!(null===(o=t.parent.form.jsonforms)||void 0===o?void 0:o.bulkInsert)||F(t)}}
397
+ ?disabled=${(e,t)=>(e=>O(e,"submitting"))(t)}
398
+ appearance="accent"
399
+ class="item-control-btn row-submit-btn"
400
+ data-test-id=${(e,t)=>`${t.parent.control.path}-${t.index}-submit-item`}
401
+ @click=${(e,t)=>t.parent.submitRow(t.index)}
402
+ >
403
+ <${e}-icon name="paper-plane"></${e}-icon>
404
+ </${e}-button>
405
+ <${e}-button
406
+ ?hidden=${(e,t)=>(e=>{var t,o,r;const i=null===(t=e.parent.control.uischema.options)||void 0===t?void 0:t.canDelete;if(!i)return!1;const a=null===(r=null===(o=e.parent.form.jsonforms)||void 0===o?void 0:o.core)||void 0===r?void 0:r.data;return!i(a[e.parent.control.path]&&a[e.parent.control.path][e.index])})(t)||F(t)}
407
+ appearance="stealth"
408
+ class="item-control-btn"
409
+ data-test-id=${(e,t)=>`${t.parent.control.path}-${t.index}-delete-item`}
410
+ @click=${(e,t)=>t.parent.deleteItem(t.index)}
411
+ >
412
+ <${e}-icon name="trash"></${e}-icon>
413
+ ${(e,t)=>{var o;return(null===(o=t.parent.control.uischema.options)||void 0===o?void 0:o.deleteLabel)||""}}
414
+ </${e}-button>
415
+ </div>
416
+ </div>
417
+ `,{positioning:!0})}
418
+ <${e}-button
419
+ ?hidden=${e=>(e=>{var t,o,r,i,a,n,s,l,d;const c=null===(r=null===(o=null===(t=e.control)||void 0===t?void 0:t.uischema)||void 0===o?void 0:o.options)||void 0===r?void 0:r.canAdd;if(void 0===c)return!1;if("boolean"==typeof c)return!c;const p=null===(n=null===(a=null===(i=e.form)||void 0===i?void 0:i.jsonforms)||void 0===a?void 0:a.core)||void 0===n?void 0:n.data,u=null!==(d=p&&(null===(s=e.control)||void 0===s?void 0:s.path)?p[e.control.path]:null===(l=e.control)||void 0===l?void 0:l.data)&&void 0!==d?d:[];return!c(Array.isArray(u)?u:[])})(e)}
420
+ appearance="lightweight"
421
+ class="item-control-btn"
422
+ data-test-id=${e=>`${e.control.path}-add-item`}
423
+ @click=${e=>e.addItem()}
424
+ >
425
+ <${e}-icon name="plus"></${e}-icon>
426
+ ${e=>{var t;return(null===(t=e.control.uischema.options)||void 0===t?void 0:t.addLabel)||"Add another"}}
427
+ </${e}-button>
428
+ </template>
429
+ `,U=d.css`
430
+ array-list-wrapper {
431
+ display: flex;
432
+ flex-direction: column;
433
+ gap: calc(${p.designUnit} * 3px);
434
+ --grid-status-track-width: calc(${p.designUnit} * 8px);
435
+ --grid-actions-track-width: calc(${p.designUnit} * 16px);
436
+
437
+ /* Row status color tokens - can be overridden via CSS custom properties */
438
+ --row-status-success-color: var(--success-foreground-rest, #28a745);
439
+ --row-status-failed-color: var(--error-foreground-rest, #dc3545);
440
+ --row-status-submitting-color: var(--accent-fill-rest, #0078d4);
441
+
442
+ /* Array item card styling - industrial/utilitarian aesthetic */
443
+ --array-item-shadow: 0 1px 2px rgba(0, 0, 0, 0.04), 0 4px 8px rgba(0, 0, 0, 0.06);
444
+ --array-item-shadow-hover: 0 2px 4px rgba(0, 0, 0, 0.06), 0 6px 12px rgba(0, 0, 0, 0.08);
445
+ --array-item-border: 1px solid var(--neutral-stroke-rest, rgba(0, 0, 0, 0.12));
446
+ --array-item-radius: calc(${p.designUnit} * 2px);
447
+ width: 100%;
448
+ }
449
+
450
+ array-list-wrapper .array-list {
451
+ display: flex;
452
+ align-items: flex-start;
453
+ position: relative;
454
+ padding: calc(${p.designUnit} * 3px);
455
+ padding-left: calc(${p.designUnit} * 2px + 3px); /* Extra space for left accent bar */
456
+ margin: 0;
457
+ background-color: var(--neutral-layer-1, #fff);
458
+ border: var(--array-item-border);
459
+ border-radius: var(--array-item-radius);
460
+ box-shadow: var(--array-item-shadow);
461
+ transition:
462
+ background-color 0.15s ease-in-out,
463
+ box-shadow 0.2s ease,
464
+ border-color 0.15s ease;
465
+ }
466
+
467
+ array-list-wrapper .array-list:hover {
468
+ box-shadow: var(--array-item-shadow-hover);
469
+ }
470
+
471
+ /* Content area grows to fill space; min-width prevents flex overflow */
472
+ array-list-wrapper .array-list > dispatch-renderer {
473
+ flex: 1;
474
+ min-width: 0;
475
+ }
476
+
477
+ /* Left accent bar for visual hierarchy - industrial form-slot feel */
478
+ array-list-wrapper .array-list::before {
479
+ content: '';
480
+ position: absolute;
481
+ left: 0;
482
+ top: 0;
483
+ bottom: 0;
484
+ width: 3px;
485
+ border-radius: var(--array-item-radius) 0 0 var(--array-item-radius);
486
+ background: var(--neutral-stroke-subtle, rgba(0, 0, 0, 0.06));
487
+ pointer-events: none;
488
+ }
489
+
490
+ array-list-wrapper .array-list.row-status-success::before {
491
+ background: var(--row-status-success-color);
492
+ }
493
+
494
+ array-list-wrapper .array-list.row-status-failed::before {
495
+ background: var(--row-status-failed-color);
496
+ }
497
+
498
+ array-list-wrapper .array-list.row-status-submitting::before {
499
+ background: var(--row-status-submitting-color);
500
+ }
501
+
502
+ array-list-wrapper .array-list.row-status-success {
503
+ background-color: color-mix(in srgb, var(--row-status-success-color), transparent 90%);
504
+ }
505
+
506
+ array-list-wrapper .array-list.row-status-failed {
507
+ background-color: color-mix(in srgb, var(--row-status-failed-color), transparent 90%);
508
+ }
509
+
510
+ array-list-wrapper .array-list.row-status-submitting {
511
+ background-color: color-mix(in srgb, var(--row-status-submitting-color), transparent 95%);
512
+ }
513
+
514
+ array-list-wrapper .row-status-indicator {
515
+ display: flex;
516
+ align-items: center;
517
+ justify-content: center;
518
+ min-width: calc(${p.designUnit} * 6px);
519
+ margin-right: calc(${p.designUnit} * 2px);
520
+ }
521
+
522
+ /* Hide all status indicators by default */
523
+ array-list-wrapper .row-status-indicator .status-spinner,
524
+ array-list-wrapper .row-status-indicator .status-success,
525
+ array-list-wrapper .row-status-indicator .status-failed {
526
+ display: none;
527
+ }
528
+
529
+ /* Show spinner when submitting */
530
+ array-list-wrapper .array-list.row-status-submitting .row-status-indicator .status-spinner {
531
+ display: flex;
532
+ }
533
+
534
+ /* Show success icon when successful */
535
+ array-list-wrapper .array-list.row-status-success .row-status-indicator .status-success {
536
+ display: flex;
537
+ }
538
+
539
+ /* Show failed icon when failed */
540
+ array-list-wrapper .array-list.row-status-failed .row-status-indicator .status-failed {
541
+ display: flex;
542
+ }
543
+
544
+ array-list-wrapper .status-icon {
545
+ width: calc(${p.designUnit} * 4px);
546
+ height: calc(${p.designUnit} * 4px);
547
+ }
548
+
549
+ array-list-wrapper .status-success {
550
+ color: var(--row-status-success-color);
551
+ }
552
+
553
+ array-list-wrapper .status-failed {
554
+ color: var(--row-status-failed-color);
555
+ cursor: help;
556
+ }
557
+
558
+ array-list-wrapper .status-spinner {
559
+ width: calc(${p.designUnit} * 4px);
560
+ height: calc(${p.designUnit} * 4px);
561
+ }
562
+
563
+ array-list-wrapper .item-control-btn {
564
+ color: var(--neutral-foreground-hint, rgb(135, 155, 166));
565
+ margin-left: calc(${p.designUnit} * 3px);
566
+ }
567
+
568
+ array-list-wrapper .item-control-btn:hover {
569
+ color: var(--accent-foreground-hover);
570
+ }
571
+
572
+ array-list-wrapper .row-submit-btn {
573
+ min-width: calc(${p.designUnit} * 8px);
574
+ }
575
+
576
+ array-list-wrapper .row-submit-btn[disabled] {
577
+ opacity: 0.5;
578
+ cursor: not-allowed;
579
+ }
580
+
581
+ array-list-wrapper .button-group {
582
+ display: flex;
583
+ flex-direction: column;
584
+ gap: 8px;
585
+ }
586
+
587
+ /* ── Grid view ────────────────────────────────────────────── */
588
+
589
+ array-list-wrapper .grid-header {
590
+ display: flex;
591
+ align-items: center;
592
+ gap: 10px;
593
+ padding: calc(${p.designUnit} * 2px) calc(${p.designUnit} * 3px);
594
+ padding-left: calc(${p.designUnit} * 2px + 3px);
595
+ border-bottom: 2px solid var(--neutral-stroke-rest, rgba(0, 0, 0, 0.12));
596
+ font-weight: 700;
597
+ font-size: 0.85em;
598
+ color: var(--neutral-foreground-hint, rgb(135, 155, 166));
599
+ text-transform: uppercase;
600
+ letter-spacing: 0.04em;
601
+ }
602
+
603
+ array-list-wrapper .grid-header-status-spacer {
604
+ width: var(--grid-status-track-width);
605
+ min-width: var(--grid-status-track-width);
606
+ flex: 0 0 var(--grid-status-track-width);
607
+ flex-shrink: 0;
608
+ }
609
+
610
+ array-list-wrapper .grid-header-cell {
611
+ flex: 1;
612
+ min-width: 0;
613
+ overflow: hidden;
614
+ text-overflow: ellipsis;
615
+ white-space: nowrap;
616
+ display: flex;
617
+ align-items: center;
618
+ gap: 4px;
619
+ }
620
+
621
+ array-list-wrapper .grid-header-actions {
622
+ width: var(--grid-actions-track-width);
623
+ min-width: var(--grid-actions-track-width);
624
+ flex: 0 0 var(--grid-actions-track-width);
625
+ text-align: center;
626
+ }
627
+
628
+ array-list-wrapper .grid-header-label-text {
629
+ overflow: hidden;
630
+ text-overflow: ellipsis;
631
+ }
632
+
633
+ array-list-wrapper .grid-header-required-indicator {
634
+ color: var(--accent-foreground-rest, #0078d4);
635
+ }
636
+
637
+ array-list-wrapper .grid-header-tooltip {
638
+ color: var(--neutral-foreground-rest, rgb(217, 223, 224));
639
+ cursor: help;
640
+ }
641
+
642
+ array-list-wrapper .array-list.grid-row {
643
+ border: none;
644
+ border-radius: 0;
645
+ box-shadow: none;
646
+ padding: calc(${p.designUnit} * 2px) calc(${p.designUnit} * 3px);
647
+ padding-left: calc(${p.designUnit} * 2px + 3px);
648
+ border-bottom: 1px solid var(--neutral-stroke-subtle, rgba(0, 0, 0, 0.06));
649
+ transition: background-color 0.1s ease;
650
+ --wrapper-root-margin-bottom: 0;
651
+ gap: 10px;
652
+ }
653
+
654
+ array-list-wrapper .array-list.grid-row::before {
655
+ display: none;
656
+ }
657
+
658
+ array-list-wrapper .array-list.grid-row:nth-child(odd) {
659
+ background-color: var(--neutral-layer-2, rgba(0, 0, 0, 0.02));
660
+ }
661
+
662
+ array-list-wrapper .array-list.grid-row:nth-child(even) {
663
+ background-color: var(--neutral-layer-1, #fff);
664
+ }
665
+
666
+ array-list-wrapper .array-list.grid-row:hover {
667
+ background-color: var(--neutral-fill-stealth-hover, rgba(0, 0, 0, 0.06));
668
+ box-shadow: none;
669
+ }
670
+
671
+ array-list-wrapper .array-list.grid-row > dispatch-renderer {
672
+ --control-label-margin: 0;
673
+ }
674
+
675
+ array-list-wrapper .array-list.grid-row .row-status-indicator {
676
+ width: var(--grid-status-track-width);
677
+ min-width: var(--grid-status-track-width);
678
+ margin-right: 0;
679
+ flex: 0 0 var(--grid-status-track-width);
680
+ }
681
+
682
+ array-list-wrapper .array-list.grid-row .button-group {
683
+ width: var(--grid-actions-track-width);
684
+ min-width: var(--grid-actions-track-width);
685
+ flex: 0 0 var(--grid-actions-track-width);
686
+ align-items: center;
687
+ }
688
+
689
+ array-list-wrapper .array-list.grid-row .item-control-btn {
690
+ margin-left: 0;
691
+ }
692
+
693
+ array-list-wrapper .array-list.grid-row.row-status-success {
694
+ background-color: color-mix(in srgb, var(--row-status-success-color), transparent 90%);
695
+ }
696
+
697
+ array-list-wrapper .array-list.grid-row.row-status-failed {
698
+ background-color: color-mix(in srgb, var(--row-status-failed-color), transparent 90%);
699
+ }
700
+
701
+ array-list-wrapper .array-list.grid-row.row-status-submitting {
702
+ background-color: color-mix(in srgb, var(--row-status-submitting-color), transparent 95%);
703
+ }
704
+ `;let B=class extends d.FASTElement{constructor(){super(...arguments),this.isGridView=!1,this.gridViewHeaderCells=[],this.gridViewUiSchema=null}controlChanged(){var e,t;this.schema=this.control.schema,this.isGridView=!!(null===(e=this.control.uischema.options)||void 0===e?void 0:e.gridView);const o=null===(t=this.control.uischema.options)||void 0===t?void 0:t.childUiSchema;if(o&&"function"!=typeof o)this.uiSchema=o;else{const e=l.wyb.uiSchema(this.schema);this.uiSchema=Object.assign(Object.assign({},e),{type:"HorizontalLayout"}),v.debug("Auto generated uiSchema for layout array:",this.uiSchema)}this.isGridView&&(this.gridViewHeaderCells=((e,t)=>{if(!(null==e?void 0:e.elements))return[];const o=Array.isArray(null==t?void 0:t.required)?t.required:[];return e.elements.map(e=>{var r,i,a,n;const s=(e=>{var t;return null!==(t=null==e?void 0:e.split("/").pop())&&void 0!==t?t:""})(e.scope);return{label:!1===e.label?"":"string"==typeof e.label?e.label:null!==(a=null===(i=null===(r=null==t?void 0:t.properties)||void 0===r?void 0:r[s])||void 0===i?void 0:i.title)&&void 0!==a?a:s.replace(/([A-Z])/g," $1").replace(/[_.-]+/g," ").trim().replace(/^./,e=>e.toUpperCase()),required:o.includes(s),tooltip:null===(n=null==e?void 0:e.options)||void 0===n?void 0:n.tooltip}})})(this.uiSchema,this.schema),this.gridViewUiSchema=P(this.uiSchema))}addItem(){this.control.addItem(this.control.path,(0,l.DmA)(this.control.schema,this.control.rootSchema))()}deleteItem(e){this.control.removeItems(this.control.path,[e])()}submitRow(e){this.$emit("submit-single-row",{index:e},{bubbles:!0,composed:!0})}};function H(e,t){var o;if(!e)return!1;const r=null===(o=e.options)||void 0===o?void 0:o.childElements,i=e.elements,a=Array.isArray(r)&&r.length>0,n=Array.isArray(i)&&i.length>0;if(a)for(const e of r)if(H(e,t))return!0;if(n)for(const e of i)if(H(e,t))return!0;const s=e.scope;if("string"!=typeof s||!t.includes(s))return!1;const l=t.some(e=>e.startsWith(`${s}/`));return!((a||n)&&l)}function Y(e,t){var o,r;const i=null===(o=null==e?void 0:e.options)||void 0===o?void 0:o.className;return"function"==typeof i?null!==(r=i(t))&&void 0!==r?r:"":null!=i?i:""}(0,r.Cg)([d.observable],B.prototype,"form",void 0),(0,r.Cg)([d.observable],B.prototype,"control",void 0),(0,r.Cg)([d.observable],B.prototype,"schema",void 0),(0,r.Cg)([d.observable],B.prototype,"uiSchema",void 0),(0,r.Cg)([d.observable],B.prototype,"isGridView",void 0),(0,r.Cg)([d.observable],B.prototype,"gridViewHeaderCells",void 0),(0,r.Cg)([d.observable],B.prototype,"gridViewUiSchema",void 0),B=(0,r.Cg)([(0,d.customElement)({name:"array-list-wrapper",styles:U,shadowOptions:null,template:d.html`
705
+ ${e=>j(e.form.prefix)}
706
+ `})],B);d.css`
707
+ .tab-control-icon {
708
+ margin-left: 3px;
709
+ color: #f9644d;
710
+ }
711
+ `;const G=d.css`
712
+ categorization-wrapper .tabs-container::part(tablist) {
713
+ background-color: transparent;
714
+ border-bottom: none;
715
+ }
716
+
717
+ categorization-wrapper .tab-control .tab-control-icon {
718
+ margin-left: 3px;
719
+ color: #f9644d;
720
+ }
721
+
722
+ categorization-wrapper .tab-panel-control {
723
+ margin-top: 10px;
724
+ }
725
+ `;let V=class extends d.FASTElement{constructor(){super(...arguments),this.mountedTabs=new Set([0]),this.activeTabIndex=0,this.touchedTabs=new Set,this.hasAppliedActiveCategory=!1,this.cachedErrorScopes=[]}controlChanged(){var e,t;if(!this.control||this.hasAppliedActiveCategory)return;const{uischema:o}=this.control,r=null===(e=null==o?void 0:o.options)||void 0===e?void 0:e.activeCategory;void 0!==r&&(this.hasAppliedActiveCategory=!0,this.activeTabIndex=function(e,t){return"number"==typeof e&&e>=0&&e<t.length?e:0}(r,null!==(t=null==o?void 0:o.elements)&&void 0!==t?t:[]),this.mountedTabs=new Set([this.activeTabIndex]))}connectedCallback(){super.connectedCallback();const e=d.Observable.binding(e=>{var t;return null===(t=e.form)||void 0===t?void 0:t.submitted},{handleChange:()=>{e.observe(this,d.defaultExecutionContext)||(this.touchedTabs=new Set)}});this.submittedObserver=e,e.observe(this,d.defaultExecutionContext)}disconnectedCallback(){var e;super.disconnectedCallback(),null===(e=this.submittedObserver)||void 0===e||e.disconnect(),this.submittedObserver=void 0}markTabTouched(e){this.touchedTabs.has(e)||(this.touchedTabs=new Set(this.touchedTabs).add(e))}isMounted(e){return this.mountedTabs.has(e)}handleTabChange(e){if(e.target!==e.currentTarget)return;const t=e.target.currentTabIndex;this.activeTabIndex=t,this.mountedTabs.has(t)||(this.mountedTabs=new Set(this.mountedTabs).add(t))}hasCategoryError(e){var t,o,r,i,a;if(!(null===(t=this.form)||void 0===t?void 0:t.submitted)&&!this.touchedTabs.has(e))return!1;const n=null===(r=null===(o=this.control)||void 0===o?void 0:o.uischema)||void 0===r?void 0:r.elements;if(!n)return!1;const s=this.getErrorScopes(null===(a=null===(i=this.form)||void 0===i?void 0:i.jsonforms)||void 0===a?void 0:a.core);return 0!==s.length&&H(n[e],s)}getErrorScopes(e){const t=null==e?void 0:e.errors,o=null==e?void 0:e.additionalErrors;return t===this.lastErrors&&o===this.lastAdditionalErrors||(this.lastErrors=t,this.lastAdditionalErrors=o,this.cachedErrorScopes=function(e){var t;const o=new Set;for(const r of e)if("required"===r.keyword&&(null===(t=r.params)||void 0===t?void 0:t.missingProperty)){const e=`#${r.instancePath?r.instancePath.replace(/\//g,"/properties/"):""}/properties/${r.params.missingProperty}`;o.add(e)}else if(r.instancePath){const e=`#${r.instancePath.replace(/\//g,"/properties/")}`;o.add(e)}return Array.from(o)}([...null!=t?t:[],...null!=o?o:[]])),this.cachedErrorScopes}};(0,r.Cg)([d.observable],V.prototype,"form",void 0),(0,r.Cg)([d.observable],V.prototype,"control",void 0),(0,r.Cg)([d.observable],V.prototype,"mountedTabs",void 0),(0,r.Cg)([d.observable],V.prototype,"activeTabIndex",void 0),(0,r.Cg)([d.observable],V.prototype,"touchedTabs",void 0),V=(0,r.Cg)([(0,d.customElement)({name:"categorization-wrapper",styles:G,shadowOptions:null,template:d.html`
726
+ ${e=>((e="rapid")=>d.html`
727
+ <template>
728
+ <${e}-tabs appearance="secondary" class="tabs-container" :activeid="${e=>"tab-"+e.activeTabIndex}" @change=${(e,t)=>e.handleTabChange(t.event)}>
729
+ ${(0,d.repeat)(e=>e.control.uischema.elements,d.html`
730
+ <${e}-tab
731
+ id="${(e,t)=>"tab-"+t.index}"
732
+ appearance="secondary"
733
+ class="${(e,t)=>{var o,r,i;const a=Y(e,null===(i=null===(r=null===(o=t.parent.form)||void 0===o?void 0:o.jsonforms)||void 0===r?void 0:r.core)||void 0===i?void 0:i.data);return(0,m.x)("tab-control",[a,!!a])}}"
734
+ >
735
+ ${(e,t)=>{var o;return null!==(o=e.label)&&void 0!==o?o:`Category ${t.index+1}`}}
736
+ ${(0,d.when)((e,t)=>t.parent.hasCategoryError(t.index),d.html`
737
+ <${e}-icon class="tab-control-icon" name="circle-exclamation"></${e}-icon>
738
+ `)}
739
+ </${e}-tab>
740
+ `,{positioning:!0})}
741
+ ${(0,d.repeat)(e=>e.control.uischema.elements,d.html`
742
+ <${e}-tab-panel
743
+ class="tab-panel-control"
744
+ @focusout=${(e,t)=>(t.parent.markTabTouched(t.index),!0)}
745
+ >
746
+ ${(0,d.when)((e,t)=>t.parent.isMounted(t.index),d.html`
747
+ ${(0,d.repeat)(e=>e.options.childElements,d.html`
748
+ <dispatch-renderer
749
+ class="fl-categorization-item"
750
+ :submitted=${(e,t)=>t.parentContext.parent.form.submitted}
751
+ :dispatch=${(e,t)=>t.parentContext.parent.form.dispatch}
752
+ :jsonforms=${(e,t)=>t.parentContext.parent.form.jsonforms}
753
+ :prefix=${(e,t)=>t.parentContext.parent.form.prefix}
754
+ :props=${(e,t)=>({uischema:e,schema:t.parentContext.parent.control.schema,renderers:t.parentContext.parent.control.renderers,path:t.parentContext.parent.control.path,enabled:t.parentContext.parent.control.enabled})}
755
+ ></dispatch-renderer>
756
+ `)}
757
+ `)}
758
+ </${e}-tab-panel>
759
+ `,{positioning:!0})}
760
+ </${e}-tabs>
761
+ </template>
762
+ `)(e.form.prefix)}
763
+ `})],V);var W=o(20469),Z=o.n(W);const q=d.html`
764
+ <template class="${e=>e.hostClasses}">${e=>e.determinedRenderer.renderer}</template>
765
+ `,X=d.css``;let J=class extends d.FASTElement{constructor(){super(...arguments),this._submitted=!1,this.depth=1,this.createRenderer=()=>{if(!this.jsonforms||!this.dispatch||!this.props)return;const e=(0,l.DWl)({jsonforms:this.jsonforms},this.props),{rootSchema:t}=e,o=(0,r.Tt)(e,["rootSchema"]);this.renderer=o,this.control=((e,t,o,r,i)=>{var a;const n=Object.assign({},r({jsonforms:t},e)),s=null===(a=i||l.XGy)||void 0===a?void 0:a(o);return Object.assign(Object.assign({},n),s)})(this.props,this.jsonforms,this.dispatch,this.determinedRenderer.mapper,this.determinedRenderer.dispatchMapper)}}jsonformsChanged(){this.createRenderer()}propsChanged(){this.createRenderer()}get submitted(){return d.Observable.track(this,"submitted"),this._submitted}set submitted(e){this._submitted=e,d.Observable.notify(this,"submitted"),this.submittedChanged()}submittedChanged(){this.touched=!!this._submitted}prefixChanged(){this.createRenderer()}onBlur(){this.touched=!0}get determinedRenderer(){const e=Z()(this.renderer.renderers,e=>e.tester(this.renderer.uischema,this.renderer.schema));return void 0===e||-1===e.tester(this.renderer.uischema,this.renderer.schema)?(v.error("UnknownRenderer this.renderer.uischema",this.renderer.uischema),{renderer:"UnknownRenderer"}):e}get hostClasses(){var e,t,o,r,i,a;const n=null===(e=this.props)||void 0===e?void 0:e.uischema,s=`dr-level-${this.depth}`;if(!n)return s;const l=null!==(o=null===(t=n.type)||void 0===t?void 0:t.toLowerCase())&&void 0!==o?o:"",d=null!==(a=null===(i=null===(r=n.scope)||void 0===r?void 0:r.split("/").pop())||void 0===i?void 0:i.toLowerCase())&&void 0!==a?a:"";return[l&&`dr-${l}`,d&&`dr-${d}`,s].filter(Boolean).join(" ")}connectedCallback(){super.connectedCallback();let e=1,t=this.parentElement;for(;t;)"dispatch-renderer"===t.tagName.toLowerCase()&&(e+=1),t=t.parentElement;this.depth=e}disconnectedCallback(){super.disconnectedCallback(),this.touched=!1,this._submitted=!1}};(0,r.Cg)([d.observable],J.prototype,"jsonforms",void 0),(0,r.Cg)([d.observable],J.prototype,"props",void 0),(0,r.Cg)([d.observable],J.prototype,"touched",void 0),(0,r.Cg)([d.observable],J.prototype,"dispatch",void 0),(0,r.Cg)([d.observable],J.prototype,"control",void 0),(0,r.Cg)([d.observable],J.prototype,"renderer",void 0),(0,r.Cg)([d.observable],J.prototype,"prefix",void 0),(0,r.Cg)([d.observable],J.prototype,"depth",void 0),J=(0,r.Cg)([(0,d.customElement)({name:"dispatch-renderer",template:q,styles:X,shadowOptions:null})],J);const Q=d.css`
766
+ stepper-wrapper .tabs-container::part(stepper-panel-container) {
767
+ display: flex;
768
+ justify-content: flex-start;
769
+ align-items: flex-start;
770
+ }
771
+ `;let K=class extends d.FASTElement{connectedCallback(){super.connectedCallback(),this.propertyNames=this.control.uischema.elements.map(e=>e.scope.split("/").pop()),this.validation=this.propertyNames.map((e,t)=>({isValid:()=>0===(0,l.L3M)(e,this.control.schema)(this.form).length&&Object.keys(this.control.data)[t]===e}))}submit(){this.$emit("submit-button-clicked")}nextStep(){this.$emit("submit-part");const e=this.propertyNames[this.stepper.activeTabIndex];this.control.data[e]||this.$emit("data-change",{data:Object.assign(Object.assign({},this.control.data),{[e]:{}})})}resetValidation(){this.$emit("reset-form")}};(0,r.Cg)([d.observable],K.prototype,"form",void 0),(0,r.Cg)([d.observable],K.prototype,"control",void 0),(0,r.Cg)([d.observable],K.prototype,"validation",void 0),(0,r.Cg)([d.observable],K.prototype,"stepper",void 0),(0,r.Cg)([d.observable],K.prototype,"propertyNames",void 0),K=(0,r.Cg)([(0,d.customElement)({name:"stepper-wrapper",styles:Q,shadowOptions:null,template:d.html`
772
+ ${e=>((e="rapid")=>d.html`
773
+ <template>
774
+ <${e}-stepper
775
+ class="tabs-container"
776
+ ${(0,d.ref)("stepper")}
777
+ orientation="${e=>{var t;return(null===(t=e.control.uischema.options)||void 0===t?void 0:t.orientation)?e.control.uischema.options.orientation:"vertical"}}"
778
+ @next-step=${e=>e.nextStep()}
779
+ @validation-success=${e=>e.resetValidation()}
780
+ @submit=${e=>e.submit()}
781
+ :validation=${e=>e.validation}>
782
+ ${(0,d.repeat)(e=>e.control.uischema.elements,d.html`
783
+ <${e}-stepper-tab class="tab-control">${(e,t)=>{var o;return null!==(o=e.label)&&void 0!==o?o:`Step ${t.index+1}`}}</${e}-stepper-tab>
784
+ `,{positioning:!0})}
785
+ ${(0,d.repeat)(e=>e.control.uischema.elements,d.html`
786
+ <${e}-stepper-tab-panel class="tab-panel-control">
787
+ ${(0,d.repeat)(e=>e.options.childElements,d.html`
788
+ <dispatch-renderer
789
+ :submitted=${(e,t)=>t.parentContext.parent.form.submitted}
790
+ :dispatch=${(e,t)=>t.parentContext.parent.form.dispatch}
791
+ :jsonforms=${(e,t)=>t.parentContext.parent.form.jsonforms}
792
+ :prefix=${(e,t)=>t.parentContext.parent.form.prefix}
793
+ :props=${(e,t)=>({uischema:e,schema:t.parentContext.parent.control.schema,renderers:t.parentContext.parent.control.renderers,path:t.parentContext.parent.control.path,enabled:t.parentContext.parent.control.enabled})}
794
+ ></dispatch-renderer>
795
+ `)}
796
+ </${e}-stepper-tab-panel>
797
+ `)}
798
+ </${e}-stepper>
799
+ </template>
800
+ `)(e.form.prefix)}
801
+ `})],K);const ee=d.css`
802
+ vertical-categorization-wrapper {
803
+ display: block;
804
+ height: var(--vertical-categorization-height, auto);
805
+ overflow: hidden;
806
+ > rapid-tabs {
807
+ border: 1px solid var(--neutral-stroke-rest);
808
+ border-radius: calc(var(--control-corner-radius) * 1px);
809
+ }
810
+ }
811
+ vertical-categorization-wrapper .tabs-container::part(tablist) {
812
+ display: flex;
813
+ flex-direction: column;
814
+ height: auto;
815
+ min-height: 100%;
816
+ width: var(--vertical-categorization-width, 160px);
817
+ background-color: transparent;
818
+ border-bottom: none;
819
+ border-right: calc(var(--stroke-width, 1) * 1px) solid
820
+ var(--neutral-stroke-rest, rgba(0, 0, 0, 0.12));
821
+ padding: 0;
822
+ }
823
+
824
+ /* Reset the column layout above on horizontal categorization-wrappers nested inside the vertical one (e.g. Detailed View). */
825
+ vertical-categorization-wrapper categorization-wrapper .tabs-container::part(tablist) {
826
+ display: grid;
827
+ border-right: 0;
828
+ width: 100%;
829
+ }
830
+
831
+ vertical-categorization-wrapper .tabs-container .tab-control {
832
+ padding: 0 calc((8 + var(--design-unit) * 2 * var(--density)) * 1px);
833
+ }
834
+
835
+ vertical-categorization-wrapper .tab-label {
836
+ display: flex;
837
+ align-items: center;
838
+ width: 100%;
839
+ border-left: 3px solid transparent;
840
+ padding: 5px;
841
+ border-radius: 0 3px 3px 0;
842
+ }
843
+
844
+ vertical-categorization-wrapper .tab-control[aria-selected='true'] .tab-label {
845
+ border-left-color: var(--accent-fill-rest);
846
+ background: var(--neutral-fill-active);
847
+ }
848
+
849
+ vertical-categorization-wrapper .tab-control-icon {
850
+ margin-left: 3px;
851
+ color: #f9644d;
852
+ }
853
+
854
+ vertical-categorization-wrapper .tabs-container::part(tabpanel) {
855
+ border: none;
856
+ overflow-y: auto;
857
+ height: 100%;
858
+ }
859
+
860
+ vertical-categorization-wrapper .tab-panel-control {
861
+ border: none;
862
+ padding-left: 16px;
863
+ }
864
+ `;let te=class extends V{constructor(){super(...arguments),this.height=""}heightChanged(e,t){this.isConnected&&this.style.setProperty("--vertical-categorization-height",t||"")}connectedCallback(){super.connectedCallback(),this.style.setProperty("--vertical-categorization-height",this.height||"")}};(0,r.Cg)([d.attr],te.prototype,"height",void 0),te=(0,r.Cg)([(0,d.customElement)({name:"vertical-categorization-wrapper",styles:ee,shadowOptions:null,template:d.html`
865
+ ${e=>((e="rapid")=>d.html`
866
+ <template>
867
+ <${e}-tabs
868
+ class="tabs-container"
869
+ orientation="vertical"
870
+ :activeid="${e=>"tab-"+e.activeTabIndex}"
871
+ @change=${(e,t)=>e.handleTabChange(t.event)}
872
+ >
873
+ ${(0,d.repeat)(e=>e.control.uischema.elements,d.html`
874
+ <${e}-tab
875
+ id="${(e,t)=>"tab-"+t.index}"
876
+ class="${(e,t)=>{var o,r,i;const a=Y(e,null===(i=null===(r=null===(o=t.parent.form)||void 0===o?void 0:o.jsonforms)||void 0===r?void 0:r.core)||void 0===i?void 0:i.data);return(0,m.x)("tab-control",[a,!!a])}}"
877
+ appearance="secondary"
878
+ >
879
+ <span class="tab-label">
880
+ ${(e,t)=>{var o;return null!==(o=e.label)&&void 0!==o?o:`Category ${t.index+1}`}}
881
+ ${(0,d.when)((e,t)=>t.parent.hasCategoryError(t.index),d.html`
882
+ <${e}-icon class="tab-control-icon" name="circle-exclamation"></${e}-icon>
883
+ `)}
884
+ </span>
885
+ </${e}-tab>
886
+ `,{positioning:!0})}
887
+ ${(0,d.repeat)(e=>e.control.uischema.elements,d.html`
888
+ <${e}-tab-panel
889
+ @focusout=${(e,t)=>(t.parent.markTabTouched(t.index),!0)}
890
+ class="${(e,t)=>{var o,r,i;const a=Y(e,null===(i=null===(r=null===(o=t.parent.form)||void 0===o?void 0:o.jsonforms)||void 0===r?void 0:r.core)||void 0===i?void 0:i.data);return(0,m.x)("tab-panel-control",[a,!!a])}}"
891
+ >
892
+ ${(0,d.when)((e,t)=>t.parent.isMounted(t.index),d.html`
893
+ ${(0,d.repeat)(e=>e.options.childElements,d.html`
894
+ <dispatch-renderer
895
+ class="fl-vertical-categorization-item"
896
+ :submitted=${(e,t)=>t.parentContext.parent.form.submitted}
897
+ :dispatch=${(e,t)=>t.parentContext.parent.form.dispatch}
898
+ :jsonforms=${(e,t)=>t.parentContext.parent.form.jsonforms}
899
+ :prefix=${(e,t)=>t.parentContext.parent.form.prefix}
900
+ :props=${(e,t)=>({uischema:e,schema:t.parentContext.parent.control.schema,renderers:t.parentContext.parent.control.renderers,path:t.parentContext.parent.control.path,enabled:t.parentContext.parent.control.enabled})}
901
+ ></dispatch-renderer>
902
+ `)}
903
+ `)}
904
+ </${e}-tab-panel>
905
+ `,{positioning:!0})}
906
+ </${e}-tabs>
907
+ </template>
908
+ `)(e.form.prefix)}
909
+ `})],te);const oe=d.css`
910
+ foundation-form-review {
911
+ display: flex;
912
+ flex-direction: column;
913
+ flex: 1;
914
+ min-height: 0;
915
+ overflow: hidden;
916
+ }
917
+
918
+ foundation-form-review .review-header {
919
+ display: flex;
920
+ align-items: baseline;
921
+ gap: calc(${p.designUnit} * 2px);
922
+ padding: calc(${p.designUnit} * 2px) calc(${p.designUnit} * 2px) calc(${p.designUnit} * 1px);
923
+ border-bottom: calc(${p.strokeWidth} * 1px) solid var(--neutral-stroke-rest, rgb(0 0 0 / 12%));
924
+ }
925
+
926
+ foundation-form-review .review-title {
927
+ font-size: var(--type-ramp-plus-1-font-size, 1rem);
928
+ line-height: var(--type-ramp-plus-1-line-height, 1.5rem);
929
+ font-weight: 600;
930
+ color: var(--neutral-foreground-rest);
931
+ }
932
+
933
+ foundation-form-review .review-id {
934
+ font-family: var(--mono-font-family, 'Courier New', Courier, monospace);
935
+ font-size: var(--type-ramp-base-font-size, 0.875rem);
936
+ color: var(--neutral-foreground-hint, rgb(0 0 0 / 60%));
937
+ }
938
+
939
+ foundation-form-review .review-filter {
940
+ padding: calc(${p.designUnit} * 2px);
941
+ }
942
+
943
+ foundation-form-review .review-filter-input {
944
+ width: 100%;
945
+ }
946
+
947
+ foundation-form-review .review-body {
948
+ flex: 1;
949
+ overflow-y: auto;
950
+ min-height: 0;
951
+ scrollbar-color: var(--neutral-stroke-rest) transparent;
952
+ }
953
+
954
+ foundation-form-review .review-section-header {
955
+ font-size: var(--type-ramp-minus-1-font-size, 0.75rem);
956
+ line-height: var(--type-ramp-minus-1-line-height, 1rem);
957
+ font-weight: 600;
958
+ letter-spacing: 0.04em;
959
+ text-transform: uppercase;
960
+ color: var(--neutral-foreground-hint, rgb(0 0 0 / 60%));
961
+ background-color: var(--neutral-layer-2, rgb(0 0 0 / 4%));
962
+ padding: calc(${p.designUnit} * 1px) calc(${p.designUnit} * 2px);
963
+ margin-top: calc(${p.designUnit} * 3px);
964
+ }
965
+
966
+ foundation-form-review .review-field {
967
+ display: flex;
968
+ align-items: baseline;
969
+ justify-content: space-between;
970
+ gap: calc(${p.designUnit} * 2px);
971
+ padding: calc(${p.designUnit} * 1.5px) calc(${p.designUnit} * 2px);
972
+ border-bottom: calc(${p.strokeWidth} * 1px) solid var(--neutral-stroke-rest, rgb(0 0 0 / 12%));
973
+ }
974
+
975
+ foundation-form-review .review-field:last-child {
976
+ border-bottom: none;
977
+ }
978
+
979
+ foundation-form-review .review-field-label {
980
+ color: var(--neutral-foreground-hint, rgb(0 0 0 / 60%));
981
+ font-size: var(--type-ramp-base-font-size, 0.875rem);
982
+ flex-shrink: 0;
983
+ }
984
+
985
+ foundation-form-review .review-field-value {
986
+ color: var(--neutral-foreground-rest);
987
+ font-size: var(--type-ramp-base-font-size, 0.875rem);
988
+ text-align: right;
989
+ word-break: break-word;
990
+ white-space: pre-wrap;
991
+ }
992
+ `.withBehaviors((0,c.forcedColorsStylesheetBehavior)(d.css`
993
+ foundation-form-review {
994
+ background: ${u.A.Canvas};
995
+ }
996
+ `)),re=d.html`
997
+ ${e=>{return t=e.prefix,d.html`
998
+ <template>
999
+ <div class="review-header">
1000
+ <span class="review-title">${e=>e.heading}</span>
1001
+ ${(0,d.when)(e=>e.recordId,d.html`
1002
+ <span class="review-id">${e=>e.recordId}</span>
1003
+ `)}
1004
+ </div>
1005
+ <div class="review-filter">
1006
+ <${t}-text-field
1007
+ value=${(0,M.O)(e=>e.filterText,"string","input")}
1008
+ placeholder="Filter fields..."
1009
+ aria-label="Filter fields"
1010
+ class="review-filter-input"
1011
+ data-test-id="review-filter-input"
1012
+ ></${t}-text-field>
1013
+ </div>
1014
+ <div class="review-body">
1015
+ ${(0,d.repeat)(e=>e.filteredSections,d.html`
1016
+ ${(0,d.when)(e=>e.fields.length>0,d.html`
1017
+ <div class="review-section-header">${e=>{var t;return null!==(t=e.title)&&void 0!==t?t:"—"}}</div>
1018
+ ${(0,d.repeat)(e=>e.fields,d.html`
1019
+ <div class="review-field">
1020
+ <span class="review-field-label">${e=>e.label}</span>
1021
+ <span class="review-field-value">${e=>e.value}</span>
1022
+ </div>
1023
+ `)}
1024
+ `)}
1025
+ `)}
1026
+ </div>
1027
+ </template>
1028
+ `;var t}}
1029
+ `;var ie,ae=o(49964),ne=o(14609),se=o(58749),le=o(20166),de=o(12066),ce=o(88047);!function(e){e.STRING="STRING",e.ENUM="ENUM",e.INT="INT",e.SHORT="SHORT",e.DOUBLE="DOUBLE",e.LONG="LONG",e.BOOLEAN="BOOLEAN",e.BIGDECIMAL="BIGDECIMAL",e.DATE="DATE",e.DATETIME="DATETIME",e.RAW="RAW"}(ie||(ie={}));const pe=(0,l.f4S)(e=>"org.joda.time.DateTime"===e.description),ue=e=>e.genesisType===ie.DATE||e.genesisType===ie.DATETIME,me=(0,l.f4S)(ue),he=(0,l.or)(pe,me,(0,l.f4S)(e=>e.hasOwnProperty("oneOf")&&e.oneOf.some(e=>"org.joda.time.DateTime"===e.description||ue(e)))),ve=e=>(0,l.dfR)(e,"number")||(0,l.dfR)(e,"integer"),ge=e=>e.genesisType===ie.DOUBLE||e.genesisType===ie.INT||e.genesisType===ie.SHORT||e.genesisType===ie.LONG||e.genesisType===ie.BIGDECIMAL,be=(0,l.f4S)(ge),ye=e=>"java.math.BigDecimal"===e.description||e.genesisType===ie.BIGDECIMAL,fe=(0,l.or)((0,l.f4S)(e=>ve(e)||e.hasOwnProperty("oneOf")&&e.oneOf.some(e=>ve(e))),be,(0,l.f4S)(e=>e.hasOwnProperty("oneOf")&&e.oneOf.some(e=>ge(e))),(0,l.f4S)(e=>ye(e)||e.hasOwnProperty("oneOf")&&e.oneOf.some(e=>ye(e))));function $e(e,t,o){return(0,r.sH)(this,void 0,void 0,function*(){const i=[],a=(e,t)=>{const o=i[i.length-1];o&&o.title===e?o.fields.push(t):i.push({title:e,fields:[t]})},n=(e,t,i)=>(0,r.sH)(this,void 0,void 0,function*(){var a,n,s,l;const d=null!==(l=null!==(s=null!==(n=null!==(a=function(e,t){var o,r,i;if(!Array.isArray(null==t?void 0:t.data))return null;const a=null!==(o=t.valueField)&&void 0!==o?o:"value",n=null!==(r=t.labelField)&&void 0!==r?r:"label",s=t.data.find(t=>t[a]===e);return s?t.labelRowFormatter?t.labelRowFormatter(s):null!==(i=s[n])&&void 0!==i?i:null:null}(e,i))&&void 0!==a?a:yield function(e,t){return(0,r.sH)(this,void 0,void 0,function*(){var o,r,i;const a=null==t?void 0:t.allOptionsResourceName;if(!a||null==e||""===e)return null;const n=null!==(o=t.valueField)&&void 0!==o?o:"value",s=null!==(r=t.labelField)&&void 0!==r?r:"label",l=t.labelRowFormatter,d=(0,ae.oy)();try{const o=(new ne.b).withExpression((new se.K).withField(n).withValue(e).build()).build();if(!(yield d.init(Object.assign(Object.assign(Object.assign({},t.datasourceConfig),{resourceName:a,criteria:o,isSnapshot:!0,maxRows:1}),l?{}:{fields:n===s?n:`${n} ${s}`}))))return null;const r=yield d.snapshotFiltered(),c=null==r?void 0:r[0];return c?l?l(c):null!==(i=c[s])&&void 0!==i?i:null:null}catch(e){return null}finally{d.destroy()}})}(e,i))&&void 0!==n?n:function(e,t,o){var r,i,a;if("string"!=typeof e)return null;const n=we(t,o);if(!n)return null;const s=null!==(r=n.enum)&&void 0!==r?r:null===(a=null===(i=n.oneOf)||void 0===i?void 0:i.find(e=>e.enum))||void 0===a?void 0:a.enum;if(Array.isArray(s)&&s.includes(e))return(0,ce.capitalCase)(e);return null}(e,t,o))&&void 0!==s?s:function(e,t,o,r){const i=we(t,o);if(!i||null==e||""===e||Number.isNaN(e))return null;if(Array.isArray(e)&&i.items)return e.map(e=>{var t;return null!==(t=Me(e,i.items,r))&&void 0!==t?t:e});return Me(e,i,r)}(e,t,o,i))&&void 0!==l?l:e;return Ee(d)}),s=(t,o)=>{var r,i,a;if(!t)return[];if("Control"===t.type&&t.scope){if(null===(r=t.options)||void 0===r?void 0:r.hidden)return[];const i=t.scope.match(/^#\/properties\/(.+)$/);if(!i)return[];const a=i[1],s=Le(e,a);if(null==s||""===s||Array.isArray(s)&&0===s.length)return[];const l=a.split("/properties/").pop();return[{groupTitle:o,label:t.label||(0,ce.capitalCase)(l),valuePromise:n(s,a,t.options)}]}const l="Group"===t.type&&t.label?t.label:o,d=null!==(i=t.elements)&&void 0!==i?i:null===(a=t.options)||void 0===a?void 0:a.childElements;return d?d.flatMap(e=>s(e,l)):[]};if(t){const e=s(t,null),o=yield Promise.all(e.map(e=>e.valuePromise));e.forEach((e,t)=>{a(e.groupTitle,{label:e.label,value:o[t]})})}else for(const[t,o]of Object.entries(null!=e?e:{}))null!=o&&""!==o&&a(null,{label:(0,ce.capitalCase)(t),value:Ee(o)});return i})}function we(e,t){var o;if(!(null==t?void 0:t.properties))return null;let r=t;for(const t of e.split("/properties/"))r=null===(o=null==r?void 0:r.properties)||void 0===o?void 0:o[t];return null!=r?r:null}const xe={type:"Control",scope:"#"},Se={config:{},rootSchema:{}},Ce={maximumFractionDigits:3,minimumFractionDigits:0},Ae=/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/,Ie={year:"numeric",month:"2-digit",day:"2-digit"},ke=Object.assign(Object.assign({},Ie),{hour:"2-digit",minute:"2-digit"});function Me(e,t,o){var r,i,a,n;if(!t)return null;if(he(xe,t,Se)){if(!e)return null;const o=t.hasOwnProperty("oneOf")?t.oneOf.some(e=>e.genesisType===ie.DATETIME):t.genesisType===ie.DATETIME;return(0,de.h5)((new Intl.DateTimeFormat).resolvedOptions().locale,o?ke:Ie)({value:e})||null}if(fe(xe,t,Se)){if((ye(t)||(null===(r=t.oneOf)||void 0===r?void 0:r.some(e=>ye(e))))&&("string"!=typeof e||!Ae.test(e)))return null;const s=!!(null==o?void 0:o.withoutFormatting),l=null!==(i=null==o?void 0:o.formatOptions)&&void 0!==i?i:Ce,d=s?String(e):(0,le.toIntlNumberFormat)(String(e),"en-US",l);return d?(a=d,[null==(n=o)?void 0:n.prefix,a,null==n?void 0:n.suffix].filter(Boolean).join(" ")):null}return null}function Le(e,t){return function(e,t){let o=e;for(const e of t){if(null==o)return;o=o[e]}return o}(e,t.split("/properties/"))}function Ee(e){return Array.isArray(e)?0===e.length?"":e.every(e=>null===e||"object"!=typeof e)?e.join(", "):e.map((e,t)=>`[${t+1}] ${Object.entries(null!=e?e:{}).filter(([,e])=>null!=e&&""!==e).map(([e,t])=>`${e}: ${t}`).join(", ")}`).join("\n"):null==e?"":"object"==typeof e?Object.entries(e).filter(([,e])=>null!=e&&""!==e).map(([e,t])=>`${e}: ${t}`).join(", "):String(e)}let Te=class extends d.FASTElement{constructor(){super(...arguments),this.prefix="rapid",this.heading="Review",this.sections=[],this.filterText=""}get filteredSections(){return function(e,t){const o=t.trim().toLowerCase();return o?e.map(e=>({title:e.title,fields:e.fields.filter(e=>e.label.toLowerCase().includes(o)||e.value.toLowerCase().includes(o))})).filter(e=>e.fields.length>0):e}(this.sections,this.filterText)}};(0,r.Cg)([(0,d.attr)({attribute:"design-system-prefix"})],Te.prototype,"prefix",void 0),(0,r.Cg)([d.attr],Te.prototype,"heading",void 0),(0,r.Cg)([(0,d.attr)({attribute:"record-id"})],Te.prototype,"recordId",void 0),(0,r.Cg)([d.observable],Te.prototype,"sections",void 0),(0,r.Cg)([d.observable],Te.prototype,"filterText",void 0),(0,r.Cg)([d.volatile],Te.prototype,"filteredSections",null),Te=(0,r.Cg)([(0,d.customElement)({name:"foundation-form-review",template:re,styles:oe,shadowOptions:null})],Te),(0,k.N)(N,B,V,te,J,K,Te);const Re=d.html`
1030
+ ${e=>{return t=e.prefix,d.html`
1031
+ <template>
1032
+ ${(0,d.when)(e=>!e.reviewMode&&e.bulkInsert,d.html`
1033
+ <div class="csv-upload-section" part="csv-upload">
1034
+ <input
1035
+ type="file"
1036
+ accept=".csv,text/csv"
1037
+ ${(0,d.ref)("csvFileInput")}
1038
+ @change=${(e,t)=>e.handleCsvFileSelected(t.event)}
1039
+ class="csv-file-input"
1040
+ />
1041
+ <${t}-button
1042
+ appearance="lightweight"
1043
+ @click=${e=>e.downloadCsvTemplate()}
1044
+ class="csv-template-button"
1045
+ data-test-id="csv-template-button"
1046
+ >
1047
+ <${t}-icon name="file-arrow-down"></${t}-icon>
1048
+ Download Template
1049
+ </${t}-button>
1050
+ <${t}-button
1051
+ appearance="lightweight"
1052
+ @click=${e=>{var t;return null===(t=e.csvFileInput)||void 0===t?void 0:t.click()}}
1053
+ class="csv-import-button"
1054
+ data-test-id="csv-import-button"
1055
+ >
1056
+ <${t}-icon name="file-arrow-up"></${t}-icon>
1057
+ Import CSV
1058
+ </${t}-button>
1059
+ </div>
1060
+ `)}
1061
+ ${(0,d.when)(e=>!e.reviewMode,d.html`
1062
+ <json-forms
1063
+ ${(0,d.ref)("jsonFormsEl")}
1064
+ @submit-button-clicked=${e=>e._submit()}
1065
+ @submit-part=${(e,t)=>e.submitPart(t.event)}
1066
+ @submit-single-row=${(e,t)=>e.submitSingleRow(t.event.detail.index)}
1067
+ @reset-form=${e=>e.reset(!1)}
1068
+ ?readonly=${e=>e.readonly}
1069
+ :submitted=${e=>e.submitted}
1070
+ :renderers=${e=>e.mergedRenderers}
1071
+ :uischema=${e=>e.uischema}
1072
+ :schema=${e=>e.jsonSchema}
1073
+ :data=${e=>e.data}
1074
+ :serverFieldErrors=${e=>e.serverFieldErrors}
1075
+ :prefix=${e=>e.prefix}
1076
+ :rowSubmitStatuses=${e=>e.rowSubmitStatuses}
1077
+ :bulkInsert=${e=>e.bulkInsert}
1078
+ @data-change=${(e,t)=>e.onChange(t.event)}
1079
+ ></json-forms>
1080
+ `)}
1081
+ ${(0,d.when)(e=>e.reviewMode,d.html`
1082
+ <foundation-form-review
1083
+ part="review-panel"
1084
+ design-system-prefix=${e=>e.prefix}
1085
+ heading=${e=>e.reviewHeading}
1086
+ :recordId=${e=>e.reviewRecordId}
1087
+ :sections=${e=>e.reviewSections}
1088
+ ></foundation-form-review>
1089
+ `)}
1090
+ ${(0,d.when)(e=>e.reviewMode||e.isSubmitHidden||e.isResetVisible,d.html`
1091
+ <slot name="userActions" part="userActions" class="actions">
1092
+ ${(0,d.when)(e=>!e.reviewMode&&e.isResetVisible,d.html`
1093
+ <${t}-button
1094
+ @click="${e=>e.handleResetClicked()}"
1095
+ class="reset-button"
1096
+ appearance="neutral"
1097
+ data-test-id="reset-button"
1098
+ >
1099
+ ${e=>e.resetButtonText}
1100
+ </${t}-button>
1101
+ `)}
1102
+ ${(0,d.when)(e=>e.reviewMode,d.html`
1103
+ <${t}-button
1104
+ @click="${e=>e.backFromReview()}"
1105
+ class="reset-button"
1106
+ appearance="neutral"
1107
+ data-test-id="review-back-button"
1108
+ >
1109
+ Back
1110
+ </${t}-button>
1111
+ `)}
1112
+ ${(0,d.when)(e=>!e.reviewMode&&e.isSubmitHidden,d.html`
1113
+ <${t}-button
1114
+ @click="${e=>e._submit()}"
1115
+ ?disabled=${e=>e.submitting}
1116
+ class="submit-button"
1117
+ appearance="accent"
1118
+ >
1119
+ ${e=>e.showSubmitReview?e.reviewButtonText:e.bulkInsert?e.bulkSubmitButtonText:e.submitButtonText}
1120
+ </${t}-button>
1121
+ `)}
1122
+ ${(0,d.when)(e=>e.reviewMode,d.html`
1123
+ <${t}-button
1124
+ @click="${e=>e._submitFromReview()}"
1125
+ ?disabled=${e=>e.submitting}
1126
+ class="submit-button"
1127
+ appearance="accent"
1128
+ data-test-id="review-submit-button"
1129
+ >
1130
+ ${e=>e.bulkInsert?e.bulkSubmitButtonText:e.submitButtonText}
1131
+ </${t}-button>
1132
+ `)}
1133
+ </slot>
1134
+ `)}
1135
+ <${t}-modal
1136
+ ${(0,d.ref)("approvalModal")}
1137
+ part="approval-modal"
1138
+ :onCloseCallback=${e=>e.closeApprovalModal.bind(e)}
1139
+ data-test-id="approval-message-modal"
1140
+ >
1141
+ <div slot="top">${e=>e.approvalMessageLabel} (required)</div>
1142
+ <div>
1143
+ <${t}-text-field
1144
+ value=${(0,M.O)(e=>e.approvalMessage,"string","input")}
1145
+ placeholder="Enter approval message..."
1146
+ ></${t}-text-field>
1147
+ </div>
1148
+ <div slot="bottom" class="approval-message-actions">
1149
+ <${t}-button
1150
+ appearance="neutral"
1151
+ @click="${e=>e.closeApprovalModal()}"
1152
+ >
1153
+ Cancel
1154
+ </${t}-button>
1155
+ <${t}-button
1156
+ appearance="accent"
1157
+ @click="${e=>e.submitWithApproval()}"
1158
+ ?disabled=${e=>!e.approvalMessage||!e.approvalMessage.trim()}
1159
+ >
1160
+ Submit
1161
+ </${t}-button>
1162
+ </div>
1163
+ </${t}-modal>
1164
+ </template>
1165
+ `;var t}}
1166
+ `,_e=(0,l.or)(l.uA2,(0,l.f4S)(e=>e.hasOwnProperty("oneOf")&&e.oneOf.some(e=>(0,l.dfR)(e,"boolean")))),De={renderer:d.html`
1167
+ ${e=>((e="rapid")=>d.html`
1168
+ <template>
1169
+ ${f({prefix:e,innerTemplate:d.html`
1170
+ <${e}-checkbox
1171
+ :checked=${e=>e.control.data}
1172
+ ?disabled=${e=>!e.control.enabled}
1173
+ :autofocus=${e=>e.control.config.focus}
1174
+ :placeholder=${e=>e.control.config.placeholder}
1175
+ tabindex="${e=>{var t,o;return null===(o=null===(t=e.control.uischema)||void 0===t?void 0:t.options)||void 0===o?void 0:o.tabIndex}}"
1176
+ @change=${(e,t)=>{e.control.handleChange(e.control.path,t.event.target.checked),e.onBlur()}}
1177
+ id=${e=>e.control.path}
1178
+ data-test-id=${e=>e.control.path}
1179
+ ></${e}-checkbox>
1180
+ `})}
1181
+ </template>
1182
+ `)(e.prefix)}
1183
+ `,tester:(0,l.Hc7)(3,_e),mapper:l.kOB},Ne=e=>t=>{if(!t||!(0,l.c0N)(t))return!1;const o=t.options;return!(!o||!o[e])},Pe=(0,l.Uo6)((0,l.or)(Ne("allOptionsResourceName"),Ne("data")),(0,l.or)(Ne("delimiter"),(0,l.f4S)(e=>(0,l.dfR)(e,"array")),(0,l.f4S)(e=>e.hasOwnProperty("oneOf")&&e.oneOf.some(e=>(0,l.dfR)(e,"array")))));le.MultiselectDatasource;const ze={renderer:d.html`
1184
+ ${e=>((e="rapid")=>d.html`
1185
+ <template>
1186
+ ${f({prefix:e,innerTemplate:d.html`
1187
+ <${e}-multiselect
1188
+ style="width: 100%"
1189
+ async=${e=>{var t;return null===(t=e.control.uischema.options)||void 0===t?void 0:t.async}}
1190
+ ?disabled=${e=>!e.control.enabled}
1191
+ :selectedOptions=${e=>(e=>{var t,o;const r=null===(o=null===(t=null==e?void 0:e.uischema)||void 0===t?void 0:t.options)||void 0===o?void 0:o.delimiter,i=null==e?void 0:e.data;return r?i?i.split(r):[]:i||[]})(e.control)}
1192
+ tabindex="${e=>{var t,o;return null===(o=null===(t=e.control.uischema)||void 0===t?void 0:t.options)||void 0===o?void 0:o.tabIndex}}"
1193
+ @selectionChange=${(e,t)=>{const o=((e,t)=>{var o,r;const i=null===(r=null===(o=null==e?void 0:e.uischema)||void 0===o?void 0:o.options)||void 0===r?void 0:r.delimiter;return i?t&&t.length?t.join(i):void 0:t})(e.control,t.event.detail);e.control.handleChange(e.control.path,o),e.$emit("change"),e.onBlur()}}
1194
+ id=${e=>e.control.path}
1195
+ data-test-id=${e=>e.control.path}
1196
+ >
1197
+ <multiselect-datasource
1198
+ resourceName=${e=>{var t;return null===(t=e.control.uischema.options)||void 0===t?void 0:t.allOptionsResourceName}}
1199
+ value-field=${e=>{var t;return null===(t=e.control.uischema.options)||void 0===t?void 0:t.valueField}}
1200
+ label-field=${e=>{var t;return null===(t=e.control.uischema.options)||void 0===t?void 0:t.labelField}}
1201
+ :data=${e=>{var t;return null===(t=e.control.uischema.options)||void 0===t?void 0:t.data}}
1202
+ :datasourceConfig=${e=>{var t;return null===(t=e.control.uischema.options)||void 0===t?void 0:t.datasourceConfig}}
1203
+ ></multiselect-datasource>
1204
+ </${e}-multiselect>
1205
+ `})}
1206
+ </template>
1207
+ `)(e.prefix)}
1208
+ `,tester:(0,l.Hc7)(4,Pe),mapper:l.kOB};le.OptionsDatasource;const Oe=new WeakMap,Fe=(e="rapid")=>d.html`
1209
+ <template>
1210
+ <style>
1211
+ ${A(e)}
1212
+ </style>
1213
+ ${f({prefix:e,innerTemplate:d.html`
1214
+ <${e}-combobox
1215
+ style="width: 100%;"
1216
+ async=${e=>{var t,o;return(null===(t=e.control.uischema.options)||void 0===t?void 0:t.async)||(null===(o=e.control.uischema.options)||void 0===o?void 0:o.infiniteScroll)}}
1217
+ placeholder=${e=>e.control.uischema.placeholder||e.control.label}
1218
+ autocomplete=${e=>{var t;return"startsWith"===(null===(t=e.control.uischema.options)||void 0===t?void 0:t.filterMode)?"both":"list"}}
1219
+ filter-mode=${e=>{var t;return(null===(t=e.control.uischema.options)||void 0===t?void 0:t.filterMode)||"contains"}}
1220
+ ?disabled=${e=>!e.control.enabled}
1221
+ :value=${e=>(e=>{var t;const o=e.control.data;if(!o)return"";const r=null===(t=e.control.uischema.options)||void 0===t?void 0:t.data;if(r){const e=r.find(e=>e.value===o);return String((null==e?void 0:e.label)||o)}const i=Oe.get(e),a=e.control.path,n="undefined"!=typeof CSS?CSS.escape(a):a,s=e.querySelector(`#${n}`);return((e,t,o)=>t===e&&!!o)(o,i,null==s?void 0:s.value)?s.value:(Oe.set(e,o),String(o))})(e)}
1222
+ tabindex="${e=>{var t,o;return null===(o=null===(t=e.control.uischema)||void 0===t?void 0:t.options)||void 0===o?void 0:o.tabIndex}}"
1223
+ @value-change=${(e,t)=>{var o;const r=null===(o=t.event.detail)||void 0===o?void 0:o.value;e.control.handleChange(e.control.path,r),e.onBlur()}}
1224
+ id=${e=>e.control.path}
1225
+ data-test-id=${e=>e.control.path}
1226
+ >
1227
+ <options-datasource
1228
+ resourceName=${e=>{var t;return null===(t=e.control.uischema.options)||void 0===t?void 0:t.allOptionsResourceName}}
1229
+ value-field=${e=>{var t;return null===(t=e.control.uischema.options)||void 0===t?void 0:t.valueField}}
1230
+ label-field=${e=>{var t;return null===(t=e.control.uischema.options)||void 0===t?void 0:t.labelField}}
1231
+ ?allow-custom-options=${e=>{var t;return null===(t=e.control.uischema.options)||void 0===t?void 0:t.allowCustomOptions}}
1232
+ ?infinite-scroll=${e=>{var t;return!!(null===(t=e.control.uischema.options)||void 0===t?void 0:t.infiniteScroll)}}
1233
+ page-size=${e=>{var t;return null===(t=e.control.uischema.options)||void 0===t?void 0:t.pageSize}}
1234
+ order-by=${e=>{var t;return null===(t=e.control.uischema.options)||void 0===t?void 0:t.orderBy}}
1235
+ option-element="${e}-option"
1236
+ :datasourceConfig=${e=>{var t;return null===(t=e.control.uischema.options)||void 0===t?void 0:t.datasourceConfig}}
1237
+ :data=${e=>{var t;return null===(t=e.control.uischema.options)||void 0===t?void 0:t.data}}
1238
+ :labelRowFormatter=${e=>{var t;return null===(t=e.control.uischema.options)||void 0===t?void 0:t.labelRowFormatter}}
1239
+ :initialSelectedValue=${e=>e.control.data}
1240
+ ></options-datasource>
1241
+ </${e}-combobox>
1242
+ `})}
1243
+ </template>
1244
+ `,je={renderer:d.html`
1245
+ ${e=>Fe(e.prefix)}
1246
+ `,tester:(0,l.Hc7)(4,(0,l.or)(Ne("allOptionsResourceName"),Ne("data"))),mapper:l.kOB},Ue=e=>{var t,o;return(null===(t=e.schema)||void 0===t?void 0:t.hasOwnProperty("oneOf"))?e.schema.oneOf.some(e=>e.genesisType===ie.DATETIME)?"datetime-local":"date":(null===(o=e.schema)||void 0===o?void 0:o.genesisType)===ie.DATETIME?"datetime-local":"date"};const Be=(e="rapid")=>d.html`
1247
+ <template>
1248
+ ${f({prefix:e,innerTemplate:d.html`
1249
+ <${e}-text-field
1250
+ :value=${e=>function(e){if(null==e.data||""===e.data)return"";const t=Ue(e),o=new Date(e.data),r=e=>e.toString().padStart(2,"0"),i="datetime-local"!==t,a=i?o.getUTCFullYear():o.getFullYear(),n=r((i?o.getUTCMonth():o.getMonth())+1),s=r(i?o.getUTCDate():o.getDate()),l=r(o.getHours()),d=r(o.getMinutes());return`${a}-${n}-${s}`+("datetime-local"===t?`T${l}:${d}`:"")}(e.control)}
1251
+ id=${e=>e.control.path}
1252
+ type="${e=>Ue(e.control)}"
1253
+ data-test-id=${e=>e.control.path}
1254
+ ?required=${e=>e.control.required}
1255
+ ?disabled=${e=>!e.control.enabled}
1256
+ tabindex="${e=>{var t,o;return null===(o=null===(t=e.control.uischema)||void 0===t?void 0:t.options)||void 0===o?void 0:o.tabIndex}}"
1257
+ @blur=${(e,t)=>{const o=t.event.target;var r;e.onBlur(),e.control.handleChange(e.control.path,(r=o.value)?new Date(r).getTime():void 0)}}"
1258
+ style="width: 100%"
1259
+ ></${e}-text-field>
1260
+ `})}
1261
+ </template>
1262
+ `,He={renderer:d.html`
1263
+ ${e=>Be(e.prefix)}
1264
+ `,tester:(0,l.Hc7)(4,he),mapper:l.kOB},Ye={renderer:d.html`
1265
+ ${e=>((e="rapid")=>d.html`
1266
+ <template>
1267
+ ${(0,d.when)(e=>e.control.visible,d.html`
1268
+ <${e}-divider
1269
+ style="margin-bottom: calc(var(--design-unit) * 4px); margin-top: 0;"
1270
+ ></${e}-divider>
1271
+ `)}
1272
+ </template>
1273
+ `)(e.prefix)}
1274
+ `,tester:(0,l.Hc7)(5,e=>{var t;return!0===(null===(t=e.options)||void 0===t?void 0:t.divider)}),mapper:l.kOB},Ge=(0,l.or)(l.pyz,(0,l.f4S)(e=>e.hasOwnProperty("oneOf")&&e.oneOf.some(e=>e.hasOwnProperty("enum")))),Ve=(e,t)=>t?t(e.label):(0,ce.capitalCase)(e.label),We=e=>{var t,o;let r=e.control.data;if(!r&&(r=(e=>{var t,o,r,i,a,n;const s=null===(r=null===(o=null===(t=e.control.schema)||void 0===t?void 0:t.oneOf)||void 0===o?void 0:o.find(e=>e.hasOwnProperty("default")))||void 0===r?void 0:r.default;if(!s)return;const l=(0,ce.capitalCase)(s),d=null===(a=null===(i=e.control.uischema)||void 0===i?void 0:i.options)||void 0===a?void 0:a.labelRowFormatter,c=null===(n=e.control.options.find(e=>Ve(e,d)===l))||void 0===n?void 0:n.value;return c?(e.control.handleChange(e.control.path,c),c):void 0})(e),!r))return"";const i=e.control.options.find(e=>e.value===r);if(!i)return"";const a=null===(o=null===(t=e.control.uischema)||void 0===t?void 0:t.options)||void 0===o?void 0:o.labelRowFormatter;return Ve(i,a)},Ze=(e="rapid")=>d.html`
1275
+ <template>
1276
+ <style>
1277
+ ${A(e)}
1278
+ </style>
1279
+ ${f({prefix:e,innerTemplate:d.html`
1280
+ <${e}-combobox
1281
+ style="width: 100%"
1282
+ autocomplete=${e=>{var t;return"startsWith"===(null===(t=e.control.uischema.options)||void 0===t?void 0:t.filterMode)?"both":"list"}}
1283
+ filter-mode=${e=>{var t;return(null===(t=e.control.uischema.options)||void 0===t?void 0:t.filterMode)||"contains"}}
1284
+ ?disabled=${e=>!e.control.enabled}
1285
+ :value=${e=>We(e)}
1286
+ tabindex="${e=>{var t,o;return null===(o=null===(t=e.control.uischema)||void 0===t?void 0:t.options)||void 0===o?void 0:o.tabIndex}}"
1287
+ @change=${(e,t)=>((e,t)=>{var o,r,i;const a=null===(r=null===(o=e.control.uischema)||void 0===o?void 0:o.options)||void 0===r?void 0:r.labelRowFormatter;e.control.handleChange(e.control.path,null===(i=e.control.options.find(e=>Ve(e,a)===t))||void 0===i?void 0:i.value),e.onBlur()})(e,t.event.target.value)}
1288
+ id=${e=>e.control.path}
1289
+ data-test-id=${e=>e.control.path}
1290
+ >
1291
+ ${(0,d.repeat)(e=>e.control.options,d.html`
1292
+ <${e}-option>${(e,t)=>{var o,r,i,a;return Ve(e,null===(a=null===(i=null===(r=null===(o=t.parent)||void 0===o?void 0:o.control)||void 0===r?void 0:r.uischema)||void 0===i?void 0:i.options)||void 0===a?void 0:a.labelRowFormatter)}}</${e}-option>
1293
+ `)}
1294
+ </${e}-combobox>
1295
+ `})}
1296
+ </template>
1297
+ `,qe={renderer:d.html`
1298
+ ${e=>Ze(e.prefix)}
1299
+ `,tester:(0,l.Hc7)(3,Ge),mapper:(e,t)=>{const o=(0,l.kOB)(e,t),r=t.options||(o.schema.enum||o.schema.oneOf.find(e=>e.hasOwnProperty("enum")).enum).map(t=>(0,l.Gem)(t,(0,l.tIO)()(e),(0,l.G9g)(o.schema,o.uischema,o.path)))||o.schema.const&&[(0,l.Gem)(o.schema.const,(0,l.tIO)()(e),(0,l.G9g)(o.schema,o.uischema,o.path))];return Object.assign(Object.assign({},o),{options:r})}},Xe={renderer:d.html`
1300
+ ${e=>((e="rapid")=>d.html`
1301
+ <template>
1302
+ <style>
1303
+ ${(e=>`\n ${e}-radio-group {\n display: block;\n width: 100%;\n }\n ${e}-radio-group::part(positioning-region) {\n display: flex;\n flex-wrap: wrap;\n align-items: center;\n gap: calc(var(--design-unit, 4) * 3px);\n }\n ${e}-radio-group[orientation="vertical"]::part(positioning-region) {\n flex-direction: column;\n align-items: flex-start;\n }\n`)(e)}
1304
+ </style>
1305
+ ${f({prefix:e,innerTemplate:d.html`
1306
+ <${e}-radio-group
1307
+ orientation="${e=>{var t,o,r;return null!==(r=null===(o=null===(t=e.control.uischema)||void 0===t?void 0:t.options)||void 0===o?void 0:o.orientation)&&void 0!==r?r:"horizontal"}}"
1308
+ value=${e=>{var t;return null!==(t=e.control.data)&&void 0!==t?t:""}}
1309
+ ?disabled=${e=>!e.control.enabled}
1310
+ id=${e=>e.control.path}
1311
+ data-test-id=${e=>e.control.path}
1312
+ @change=${(e,t)=>{const o=t.event.currentTarget;e.control.handleChange(e.control.path,o.value||void 0),e.onBlur()}}
1313
+ >
1314
+ ${(0,d.repeat)(e=>{var t,o,r,i;return null!==(i=null===(r=null===(o=null===(t=e.control)||void 0===t?void 0:t.uischema)||void 0===o?void 0:o.options)||void 0===r?void 0:r.data)&&void 0!==i?i:[]},d.html`
1315
+ <${e}-radio value=${e=>e.value}>${e=>e.label}</${e}-radio>
1316
+ `)}
1317
+ </${e}-radio-group>
1318
+ `})}
1319
+ </template>
1320
+ `)(e.prefix)}
1321
+ `,tester:(0,l.Hc7)(10,Ne("radio")),mapper:l.kOB},Je={renderer:d.html`
1322
+ <template>
1323
+ <pre
1324
+ :value=${e=>e.control.data||""}
1325
+ id=${e=>e.control.path}
1326
+ data-test-id=${e=>e.control.path}
1327
+ style="display: none"
1328
+ ></pre>
1329
+ </template>
1330
+ `,tester:(0,l.Hc7)(5,(e,t,o)=>{var r,i;return null!==(i=null===(r=null==e?void 0:e.options)||void 0===r?void 0:r.hidden)&&void 0!==i&&i}),mapper:l.kOB},Qe=e=>t=>(0,l.dfR)(t,"array")&&t.hasOwnProperty("items")&&t.items.type===e,Ke=e=>(0,l.f4S)(t=>t.hasOwnProperty("oneOf")&&t.oneOf.some(Qe(e))||Qe(e)(t)),et=d.html`
1331
+ <template>
1332
+ <div style="${e=>{var t;return(null===(t=e.control.uischema.options)||void 0===t?void 0:t.border)?"padding: 5px; border-radius: 3px; border: 1px solid var(--neutral-stroke-rest);":""}}">
1333
+ ${f({prefix:"rapid",innerTemplate:d.html`
1334
+ <array-list-wrapper :form=${e=>e} :control=${e=>e.control}></array-list-wrapper>
1335
+ `})}
1336
+ </div>
1337
+ </template>
1338
+ `,tt={renderer:et,tester:(0,l.Hc7)(2,Ke("object")),mapper:l.i8T,dispatchMapper:l.oid},ot={renderer:d.html`
1339
+ <template>
1340
+ <categorization-wrapper :form=${e=>e} :control=${e=>e.control}></categorization-wrapper>
1341
+ </template>
1342
+ `,tester:(0,l.Hc7)(2,e=>"Categorization"===e.type),mapper:l.n93},rt=e=>{const{innerTemplate:t,hideLabel:o=!1}=e;return d.html`
1343
+ ${(0,d.when)(e=>{var t;return!!(null===(t=e.control)||void 0===t?void 0:t.label)&&!o},d.html`
1344
+ <div class="fl-layout-label">${e=>e.control.label}</div>
1345
+ `)}
1346
+ ${(0,d.when)(e=>{var t;return null===(t=e.control)||void 0===t?void 0:t.visible},t)}
1347
+ `},it={renderer:d.html`
1348
+ <template>
1349
+ ${rt({innerTemplate:d.html`
1350
+ <div class="fl-vertical-layout">
1351
+ ${(0,d.repeat)(e=>e.control.uischema.elements,d.html`
1352
+ <dispatch-renderer
1353
+ :submitted=${(e,t)=>t.parent.submitted}
1354
+ :dispatch=${(e,t)=>t.parent.dispatch}
1355
+ :jsonforms=${(e,t)=>t.parent.jsonforms}
1356
+ :prefix=${(e,t)=>t.parent.prefix}
1357
+ :props=${(e,t)=>({uischema:e,schema:t.parent.control.schema,renderers:t.parent.control.renderers,path:t.parent.control.path,enabled:t.parent.control.enabled})}
1358
+ ></dispatch-renderer>
1359
+ `)}
1360
+ </div>
1361
+ `})}
1362
+ </template>
1363
+ `,tester:(0,l.Hc7)(2,l.nWz),mapper:l.n93};let at=class extends d.FASTElement{constructor(){super(...arguments),this.hideLabel=!1}connectedCallback(){super.connectedCallback(),v.warn("<layout-wrapper> is deprecated and will be removed in a future major version. Migrate to the `layoutWrapperTemplate` function for light-DOM rendering.")}};(0,r.Cg)([d.observable],at.prototype,"control",void 0),(0,r.Cg)([(0,d.attr)({mode:"boolean",attribute:"hide-label"})],at.prototype,"hideLabel",void 0),at=(0,r.Cg)([(0,d.customElement)({name:"layout-wrapper",template:d.html`
1364
+ ${(0,d.when)(e=>e.control.label&&!e.hideLabel,d.html`
1365
+ <div style="color: var(--neutral-foreground-hint);">${e=>e.control.label}</div>
1366
+ `)}
1367
+ ${(0,d.when)(e=>{var t;return null===(t=e.control)||void 0===t?void 0:t.visible},d.html`
1368
+ <slot></slot>
1369
+ `)}
1370
+ `})],at);const nt={renderer:d.html`
1371
+ <template>
1372
+ ${rt({innerTemplate:d.html`
1373
+ <div class="fl-form-grid-layout">
1374
+ ${(0,d.repeat)(e=>e.control.uischema.elements,d.html`
1375
+ <dispatch-renderer
1376
+ :submitted=${(e,t)=>t.parent.submitted}
1377
+ :dispatch=${(e,t)=>t.parent.dispatch}
1378
+ :jsonforms=${(e,t)=>t.parent.jsonforms}
1379
+ :prefix=${(e,t)=>t.parent.prefix}
1380
+ :props=${(e,t)=>({uischema:e,schema:t.parent.control.schema,renderers:t.parent.control.renderers,path:t.parent.control.path,enabled:t.parent.control.enabled})}
1381
+ ></dispatch-renderer>
1382
+ `)}
1383
+ </div>
1384
+ `})}
1385
+ </template>
1386
+ `,tester:(0,l.Hc7)(2,e=>"FormGridLayout"===e.type),mapper:l.n93},st={renderer:d.html`
1387
+ <template>
1388
+ ${rt({hideLabel:!0,innerTemplate:d.html`
1389
+ <div class="fl-group-layout">
1390
+ ${(0,d.when)(e=>e.control.label,d.html`
1391
+ <div for="${e=>e.control.path+"-wrapper"}" class="fl-group-label">
1392
+ ${e=>e.control.label}
1393
+ </div>
1394
+ `)}
1395
+ ${(0,d.repeat)(e=>e.control.uischema.options.childElements,d.html`
1396
+ <dispatch-renderer
1397
+ :submitted=${(e,t)=>t.parent.submitted}
1398
+ :dispatch=${(e,t)=>t.parent.dispatch}
1399
+ :jsonforms=${(e,t)=>t.parent.jsonforms}
1400
+ :prefix=${(e,t)=>t.parent.prefix}
1401
+ :props=${(e,t)=>({uischema:e,schema:t.parent.control.schema,renderers:t.parent.control.renderers,path:t.parent.control.path,enabled:t.parent.control.enabled})}
1402
+ ></dispatch-renderer>
1403
+ `)}
1404
+ </div>
1405
+ `})}
1406
+ </template>
1407
+ `,tester:(0,l.Hc7)(2,l.IZG),mapper:l.n93},lt={renderer:d.html`
1408
+ <template>
1409
+ ${rt({innerTemplate:d.html`
1410
+ <div class="fl-horizontal-layout">
1411
+ ${(0,d.repeat)(e=>e.control.uischema.elements,d.html`
1412
+ <dispatch-renderer
1413
+ class="fl-horizontal-layout-item"
1414
+ :submitted=${(e,t)=>t.parent.submitted}
1415
+ :dispatch=${(e,t)=>t.parent.dispatch}
1416
+ :jsonforms=${(e,t)=>t.parent.jsonforms}
1417
+ :prefix=${(e,t)=>t.parent.prefix}
1418
+ :props=${(e,t)=>({uischema:e,schema:t.parent.control.schema,renderers:t.parent.control.renderers,path:t.parent.control.path,enabled:t.parent.control.enabled})}
1419
+ ></dispatch-renderer>
1420
+ `)}
1421
+ </div>
1422
+ `})}
1423
+ </template>
1424
+ `,tester:(0,l.Hc7)(2,e=>"HorizontalLayout"===e.type),mapper:l.n93},dt={renderer:d.html`
1425
+ <template>
1426
+ <stepper-wrapper :form=${e=>e} :control=${e=>e.control}></stepper-wrapper>
1427
+ </template>
1428
+ `,tester:(0,l.Hc7)(3,e=>"Stepper"===e.type),mapper:l.n93},ct={renderer:d.html`
1429
+ <template>
1430
+ ${rt({innerTemplate:d.html`
1431
+ <div class="fl-2-column-layout">
1432
+ ${(0,d.repeat)(e=>e.control.uischema.elements,d.html`
1433
+ <div class="fl-2-column-item">
1434
+ <dispatch-renderer
1435
+ :submitted=${(e,t)=>t.parent.submitted}
1436
+ :dispatch=${(e,t)=>t.parent.dispatch}
1437
+ :jsonforms=${(e,t)=>t.parent.jsonforms}
1438
+ :prefix=${(e,t)=>t.parent.prefix}
1439
+ :props=${(e,t)=>({uischema:e,schema:t.parent.control.schema,renderers:t.parent.control.renderers,path:t.parent.control.path,enabled:t.parent.control.enabled})}
1440
+ ></dispatch-renderer>
1441
+ </div>
1442
+ `)}
1443
+ </div>
1444
+ `})}
1445
+ </template>
1446
+ `,tester:(0,l.Hc7)(2,e=>"LayoutVertical2Columns"===e.type),mapper:l.n93};const pt=d.html`
1447
+ <template>
1448
+ <vertical-categorization-wrapper
1449
+ :form=${e=>e}
1450
+ :control=${e=>e.control}
1451
+ height=${e=>{var t,o;return null!==(o=function(e){if("object"==typeof e&&null!==e&&"vertical"===e.type)return e.height}(null===(t=e.control.uischema.options)||void 0===t?void 0:t.layout))&&void 0!==o?o:""}}
1452
+ ></vertical-categorization-wrapper>
1453
+ </template>
1454
+ `,ut={renderer:pt,tester:(0,l.Hc7)(3,e=>{var t,o;return"Categorization"===e.type&&(void 0!==(o=null===(t=e.options)||void 0===t?void 0:t.layout)&&("vertical"===o||"object"==typeof o&&"vertical"===o.type))}),mapper:l.n93},mt=e=>e.control.uischema.options,ht={renderer:d.html`
1455
+ ${e=>((e="rapid")=>d.html`
1456
+ <template>
1457
+ ${f({prefix:e,innerTemplate:d.html`
1458
+ <${e}-multicolumn-dropdown
1459
+ style="width: 100%;"
1460
+ resource-name=${e=>mt(e).allOptionsResourceName}
1461
+ value-key=${e=>mt(e).valueField}
1462
+ label-key=${e=>mt(e).labelField}
1463
+ ?disabled=${e=>!e.control.enabled}
1464
+ ?dropdown-above=${e=>{var t,o;return null!==(o=null===(t=mt(e).dropdownPlacement)||void 0===t?void 0:t.startsWith("top"))&&void 0!==o&&o}}
1465
+ ?dropdown-left=${e=>{var t,o;return null!==(o=null===(t=mt(e).dropdownPlacement)||void 0===t?void 0:t.endsWith("left"))&&void 0!==o&&o}}
1466
+ ?advanced-search-req=${e=>!!mt(e).advancedSearchReq}
1467
+ :searchKey=${e=>mt(e).searchKey}
1468
+ :request=${e=>mt(e).request}
1469
+ :columnDefinitions=${e=>mt(e).columnDefinitions}
1470
+ :baseCriteria=${e=>mt(e).baseCriteria}
1471
+ :dropdownWidth=${e=>mt(e).dropdownWidth}
1472
+ :value=${e=>e.control.data}
1473
+ id=${e=>e.control.path}
1474
+ data-test-id=${e=>e.control.path}
1475
+ @change=${(e,t)=>{var o,r;const i=null!==(o=t.event.detail)&&void 0!==o?o:null;i!==(null!==(r=e.control.data)&&void 0!==r?r:null)&&(e.control.handleChange(e.control.path,i),e.onBlur())}}
1476
+ ></${e}-multicolumn-dropdown>
1477
+ `})}
1478
+ </template>
1479
+ `)(e.prefix)}
1480
+ `,tester:(0,l.Hc7)(5,Ne("columnDefinitions")),mapper:l.kOB},vt={maximumFractionDigits:3,minimumFractionDigits:0},gt=e=>e.schema,bt=(e,t)=>null!=(null==t?void 0:t.maximumInputPrecision)?t.maximumInputPrecision:(e=>{var t,o;return ye(e)||null!==(o=null===(t=e.oneOf)||void 0===t?void 0:t.some(e=>ye(e)))&&void 0!==o&&o})(e)?18:12;function yt(e,t){var o;const r=t.event.currentTarget,i=String(null!==(o=null==r?void 0:r.value)&&void 0!==o?o:"");if(""===i)return e.control.handleChange(e.control.path,R(t.event,e.control.schema));const a=parseFloat(i);if(isNaN(a))return;const n=(e=>{var t,o;return(0,l.dfR)(e,"string")||null!==(o=null===(t=e.oneOf)||void 0===t?void 0:t.some(e=>(0,l.dfR)(e,"string")))&&void 0!==o&&o})(gt(e.control))?i:a;return e.control.handleChange(e.control.path,n)}const ft={renderer:d.html`
1481
+ ${e=>((e="rapid")=>d.html`
1482
+ <template>
1483
+ ${f({prefix:e,innerTemplate:d.html`
1484
+ <${e}-number-field
1485
+ withFormatting=${e=>{var t;return!(null===(t=e.control.uischema.options)||void 0===t?void 0:t.withoutFormatting)}}
1486
+ :options=${e=>{var t;return(null===(t=e.control.uischema.options)||void 0===t?void 0:t.formatOptions)||vt}}
1487
+ autocomplete=${e=>{var t;return(null===(t=e.control.uischema.options)||void 0===t?void 0:t.autocomplete)||"off"}}
1488
+ prefix=${e=>{var t,o;return null===(o=null===(t=e.control.uischema)||void 0===t?void 0:t.options)||void 0===o?void 0:o.prefix}}
1489
+ suffix=${e=>{var t,o;return null===(o=null===(t=e.control.uischema)||void 0===t?void 0:t.options)||void 0===o?void 0:o.suffix}}
1490
+ ?hide-affix-from-screen-reader=${e=>{var t,o;return null===(o=null===(t=e.control.uischema)||void 0===t?void 0:t.options)||void 0===o?void 0:o.hideAffixFromScreenReader}}
1491
+ :value=${e=>null==e.control.data?"":String(e.control.data)}
1492
+ :maximumInputPrecision=${e=>bt(gt(e.control),e.control.uischema.options)}
1493
+ tabindex="${e=>{var t,o;return null===(o=null===(t=e.control.uischema)||void 0===t?void 0:t.options)||void 0===o?void 0:o.tabIndex}}"
1494
+ @change=${yt}
1495
+ @input=${(e,t)=>{var o;return(null===(o=e.control.uischema.options)||void 0===o?void 0:o.changeOnInput)?yt(e,t):void 0}}
1496
+ placeholder=${e=>e.control.uischema.placeholder||""}
1497
+ id=${e=>e.control.path}
1498
+ data-test-id=${e=>e.control.path}
1499
+ ?required=${e=>e.control.required}
1500
+ ?disabled=${e=>!e.control.enabled}
1501
+ hideStep
1502
+ @blur=${e=>e.onBlur()}
1503
+ style="width: 100%"
1504
+ ></${e}-number-field>
1505
+ `})}
1506
+ </template>
1507
+ `)(e.prefix)}
1508
+ `,tester:(0,l.Hc7)(3,fe),mapper:l.kOB},$t={renderer:d.html`
1509
+ ${e=>((e="rapid")=>d.html`
1510
+ <template>
1511
+ <style>
1512
+ ${e}-segmented-control {
1513
+ width: 100%;
1514
+ display: block;
1515
+ }
1516
+ ${e}-segmented-item {
1517
+ flex: 1;
1518
+ text-align: center;
1519
+ justify-content: center;
1520
+ }
1521
+ ${e}-segmented-item[aria-checked='true'],
1522
+ ${e}-segmented-item[aria-selected='true'] {
1523
+ background: var(--segmented-item-selected-bg);
1524
+ }
1525
+ </style>
1526
+ ${f({prefix:e,innerTemplate:d.html`
1527
+ <${e}-segmented-control
1528
+ :value=${e=>e.control.data}
1529
+ ?disabled=${e=>!e.control.enabled}
1530
+ id=${e=>e.control.path}
1531
+ data-test-id=${e=>e.control.path}
1532
+ @change=${(e,t)=>{e.control.handleChange(e.control.path,t.event.target.value),e.onBlur()}}
1533
+ >
1534
+ ${(0,d.repeat)(e=>{var t,o,r;return null!==(r=null===(o=null===(t=e.control.uischema)||void 0===t?void 0:t.options)||void 0===o?void 0:o.data)&&void 0!==r?r:[]},d.html`
1535
+ <${e}-segmented-item
1536
+ value=${e=>e.value}
1537
+ style=${e=>{var t;return`--segmented-item-selected-bg: ${null!==(t=e.color)&&void 0!==t?t:"var(--neutral-fill-rest)"}`}}
1538
+ >
1539
+ ${e=>e.label}
1540
+ </${e}-segmented-item>
1541
+ `)}
1542
+ </${e}-segmented-control>
1543
+ `})}
1544
+ </template>
1545
+ `)(e.prefix)}
1546
+ `,tester:(0,l.Hc7)(5,Ne("segmented")),mapper:l.kOB};function wt(e,t){const o=t.event.target.value;e.control.handleChange(e.control.path,""===o?[]:o.split(",").map(e=>e.trimStart()))}const xt={renderer:d.html`
1547
+ ${e=>((e="rapid")=>d.html`
1548
+ <template>
1549
+ ${f({prefix:e,innerTemplate:d.html`
1550
+ <${e}-text-field
1551
+ :value=${e=>(e=>{var t;const o=e.control.data;return"string"==typeof o&&e.control.handleChange(e.control.path,o.split(",")),(null===(t=e.control.data)||void 0===t?void 0:t.toString())||""})(e)}
1552
+ tabindex="${e=>{var t,o;return null===(o=null===(t=e.control.uischema)||void 0===t?void 0:t.options)||void 0===o?void 0:o.tabIndex}}"
1553
+ @change=${wt}
1554
+ placeholder=${e=>e.control.uischema.placeholder||e.control.label}
1555
+ id=${e=>e.control.path}
1556
+ data-test-id=${e=>e.control.path}
1557
+ ?required=${e=>e.control.required}
1558
+ ?disabled=${e=>!e.control.enabled}
1559
+ style="width: 100%"
1560
+ @blur=${e=>e.onBlur()}
1561
+ ></${e}-text-area>
1562
+ `})}
1563
+ </template>
1564
+ `)(e.prefix)}
1565
+ `,tester:(0,l.Hc7)(3,Ke("string")),mapper:l.kOB};var St=o(70997);function Ct(e,t){var o,r;const i=function(e,t="none"){const o="function"==typeof t?t(e):"uppercase"===t?e.toUpperCase():"lowercase"===t?e.toLowerCase():e;return""===o?void 0:o}(t.event.target.value,null===(r=null===(o=e.control.uischema)||void 0===o?void 0:o.options)||void 0===r?void 0:r.textTransform);e.control.handleChange(e.control.path,null!=i?i:R(t.event,e.control.schema))}const At=d.html`
1566
+ ${e=>((e="rapid")=>d.html`
1567
+ <template>
1568
+ ${f({prefix:e,innerTemplate:d.html`
1569
+ ${(0,St.q)(e=>{var t,o;return!(null===(o=null===(t=e.control.uischema)||void 0===t?void 0:t.options)||void 0===o?void 0:o.textarea)},d.html`
1570
+ <${e}-text-field
1571
+ part="text-field"
1572
+ autocomplete=${e=>{var t;return(null===(t=e.control.uischema.options)||void 0===t?void 0:t.autocomplete)||"off"}}
1573
+ prefix=${e=>{var t,o;return null===(o=null===(t=e.control.uischema)||void 0===t?void 0:t.options)||void 0===o?void 0:o.prefix}}
1574
+ suffix=${e=>{var t,o;return null===(o=null===(t=e.control.uischema)||void 0===t?void 0:t.options)||void 0===o?void 0:o.suffix}}
1575
+ ?hide-affix-from-screen-reader=${e=>{var t,o;return null===(o=null===(t=e.control.uischema)||void 0===t?void 0:t.options)||void 0===o?void 0:o.hideAffixFromScreenReader}}
1576
+ type=${e=>{var t,o;return(null===(o=null===(t=e.control.uischema)||void 0===t?void 0:t.options)||void 0===o?void 0:o.isPassword)?"password":"text"}}
1577
+ :value=${e=>e.control.data||""}
1578
+ @input=${(e,t)=>{var o;return(null===(o=e.control.uischema.options)||void 0===o?void 0:o.changeOnInput)?Ct(e,t):void 0}}
1579
+ @change=${Ct}
1580
+ placeholder=${e=>e.control.uischema.placeholder||""}
1581
+ id=${e=>e.control.path}
1582
+ data-test-id=${e=>e.control.path}
1583
+ tabindex="${e=>{var t,o;return null===(o=null===(t=e.control.uischema)||void 0===t?void 0:t.options)||void 0===o?void 0:o.tabIndex}}"
1584
+ ?required=${e=>e.control.required}
1585
+ ?disabled=${e=>!e.control.enabled}
1586
+ style="width: 100%"
1587
+ @blur=${e=>e.onBlur()}
1588
+ ></${e}-text-field>`,d.html`
1589
+ <${e}-text-area
1590
+ part="text-area"
1591
+ :value=${e=>e.control.data||""}
1592
+ @input=${(e,t)=>{var o;return(null===(o=e.control.uischema.options)||void 0===o?void 0:o.changeOnInput)?Ct(e,t):void 0}}
1593
+ @change=${Ct}
1594
+ placeholder=${e=>e.control.uischema.placeholder||""}
1595
+ id=${e=>e.control.path}
1596
+ data-test-id=${e=>e.control.path}
1597
+ ?required=${e=>e.control.required}
1598
+ ?disabled=${e=>!e.control.enabled}
1599
+ tabindex="${e=>{var t,o;return null===(o=null===(t=e.control.uischema)||void 0===t?void 0:t.options)||void 0===o?void 0:o.tabIndex}}"
1600
+ style="width: 100%"
1601
+ @blur=${e=>e.onBlur()}
1602
+ ></${e}-text-area>
1603
+ `)}
1604
+ `})}
1605
+ </template>
1606
+ `)(e.prefix)}
1607
+ `;var It=o(85031),kt=o.n(It);function Mt(e,t){if(""===e)return e;if(!t)return e;switch(Lt(t)){case"integer":case"number":{const t=parseFloat(e);return isNaN(t)?e:t}case"boolean":{const t=e.toLowerCase();return!!["true","yes","1"].includes(t)||!["false","no","0"].includes(t)&&e}default:return e}}function Lt(e){if(e.type)return Array.isArray(e.type)?e.type[0]:e.type;const t=e.oneOf||e.anyOf;if(t)for(const e of t)if("object"==typeof e&&e.type&&"null"!==e.type)return Array.isArray(e.type)?e.type[0]:e.type}function Et(e){const t=[];function o(e){var r,i,a;if("Control"===e.type&&e.scope){const o=function(e){const t=e.match(/^#\/properties\/(.+)$/);return t?t[1]:null}(e.scope);if(o){if("items"===o&&(null===(r=e.options)||void 0===r?void 0:r.childUiSchema)){const o=e.options.childUiSchema,r="function"==typeof o?o(0,void 0,void 0):o;if(r){const e=Et(r);t.push(...e)}return}const a=!0===(null===(i=e.options)||void 0===i?void 0:i.hidden),n=e.label;t.push({fieldName:o,label:n,isHidden:a})}}if(e.elements)for(const t of e.elements)o(t);if(null===(a=e.options)||void 0===a?void 0:a.childElements)for(const t of e.options.childElements)o(t)}if(e.elements)for(const t of e.elements)o(t);const r=e.options,i=null==r?void 0:r.childElements;if(i)for(const e of i)o(e);return t}function Tt(e,t,o){const r=Lt(t);if(t.enum&&t.enum.length>0)return String(t.enum[0]);if(void 0!==t.const)return String(t.const);if(void 0!==t.default)return String(t.default);if(t.examples&&Array.isArray(t.examples)&&t.examples.length>0)return String(t.examples[0]);switch(r){case"string":return function(e,t){const o=e.toLowerCase();if(t.format)switch(t.format){case"date":return"2024-01-15";case"date-time":return"2024-01-15T10:30:00Z";case"time":return"10:30:00";case"email":return"user@example.com";case"uri":case"url":return"https://example.com";case"uuid":return"550e8400-e29b-41d4-a716-446655440000";case"hostname":return"example.com";case"ipv4":return"192.168.1.1";case"ipv6":return"2001:0db8:85a3:0000:0000:8a2e:0370:7334"}if(o.includes("email"))return"user@example.com";if(o.includes("phone")||o.includes("tel"))return"+1234567890";if(o.includes("date")||o.includes("time"))return o.includes("time")&&!o.includes("date")?"10:30:00":"2024-01-15";if(o.includes("url")||o.includes("link")||o.includes("website"))return"https://example.com";if(o.includes("name"))return o.includes("first")?"John":o.includes("last")?"Doe":"Sample Name";if(o.includes("address"))return"123 Main Street";if(o.includes("city"))return"New York";if(o.includes("country"))return"USA";if(o.includes("description")||o.includes("comment")||o.includes("notes"))return"Sample description";if(o.includes("id")||o.includes("code"))return"ABC123";const r=t.minLength||0,i=50,a=t.maxLength||i;let n=`Sample ${e}`;n.length<r&&(n=n.padEnd(r,"_"));n.length>a&&(n=n.substring(0,a));return n}(e,t);case"integer":return function(e){var t,o;const r=null!==(t=e.minimum)&&void 0!==t?t:0,i=null!==(o=e.maximum)&&void 0!==o?o:100;if(void 0!==e.minimum)return String(Math.ceil(r));const a=Math.min(Math.max(1,r),i);return String(Math.floor(a))}(t);case"number":return function(e){var t,o;const r=null!==(t=e.minimum)&&void 0!==t?t:0,i=null!==(o=e.maximum)&&void 0!==o?o:100;if(void 0!==e.minimum)return String(r);const a=1.5,n=Math.min(Math.max(a,r),i);return String(n)}(t);case"boolean":return"true";case"array":case"object":return"";default:return o?`sample_${e.toLowerCase()}`:""}}function Rt(e){if(!e)return"";if(e.includes(",")||e.includes('"')||e.includes("\n")||e.includes("\r")){return`"${e.replace(/"/g,'""')}"`}return e}function _t(e){return e.replace(/^\$/,"").replace(/\[(\d+)\]/g,".$1").split(/[./]/).filter(Boolean)}function Dt(e,t,o){return(null==e?void 0:e.length)?e.map(e=>{const r=function(e,t,o){let r=null;if(t){const o=_t(t),i=e?_t(e):[];i.length<=o.length&&i.every((e,t)=>o[o.length-i.length+t]===e)||o.push(...i),"DETAILS"===o[0]&&o.shift(),r=o.length?`/${o.join("/")}`:null}else e&&(r=e.startsWith("/")?e:`/${e}`);if(!r)return null;if(o)return`${o.startsWith("/")?o.replace(/\/$/,""):`/${o.replace(/\/$/,"")}`}${r}`;return r}(e.FIELD,e.PATH,o);if(!r)return null;const i={keyword:"serverValidation",message:e.TEXT,instancePath:r,schemaPath:"",params:{code:e.CODE}};if(t)try{const e=function(e){const t=e.replace(/^\//,"").split("/").filter(Boolean);if(0===t.length)return"#";let o="#";for(let e=0;e<t.length;e+=1){const r=t[e];0===e?o+=`/properties/${r}`:/^\d+$/.test(r)?o+=`/items/${r}`:o+=`/properties/${r}`}return o}(r),o=t,a=l.XKv.schema(o,e,o);a&&(i.parentSchema=a)}catch(e){}return i}).filter(e=>null!==e):[]}var Nt=o(31274);const Pt=(e,t,o)=>new Promise(r=>{((e,t,o)=>{if(!e.title)throw new Error("Title is required");if(!e.body)throw new Error("Missing required param 'body'");let r={title:e.title,body:e.body},i={};null!=e.logLevel&&(r=Object.assign({logLevel:e.logLevel},r)),e.dialog&&(i=Object.assign({dialog:e.dialog},i),r=Object.assign({config:i},r)),(0,Nt.u)(r,t,o)})({title:"Confirm Submission",body:e,dialog:{confirmingActions:[{label:"Submit",action:()=>r(!0)}],dismissingAction:{label:"Cancel",action:()=>r(!1)}}},`${t}-form`,o)});const zt={renderer:At,tester:(0,l.Hc7)(2,l.Nyt),mapper:l.kOB},Ot=[{renderer:At,tester:(0,l.Hc7)(1,l.c0N),mapper:l.kOB},zt,De,xt,tt,ot,ut,st,lt,nt,ct,it,dt,ft,ze,qe,Xe,je,He,Je,Ye,ht,$t];let Ft=class extends((0,a.S)(c.FoundationElement)){constructor(){super(...arguments),this.prefix="rapid",this.approvalMessageLabel="Approval Message",this.serverFieldErrors=[],this.approvalMessage="",this.pendingPayload=null,this.renderers=Ot,this.additionalRenderers=[],this.mergedRenderers=Ot,this.errors=[],this.data={},this.submitButtonText="Submit",this.bulkSubmitButtonText="Submit All",this.resetButtonText="Reset",this.bulkInsertMinItems=1,this.reviewButtonText="Review",this.reviewHeading="Review",this.rowSubmitStatuses=new Map,this.reviewMode=!1,this.reviewSections=[]}resourceNameChanged(){return(0,r.sH)(this,void 0,void 0,function*(){var e,t;if(this.jsonSchema=void 0,this.originalDetailsSchema=void 0,this.resourceName){const o=yield this.connect.getJSONSchema(this.resourceName);if(!o)return;const r=new(s())(o.INBOUND),i=null===(e=(yield r.resolve()).properties)||void 0===e?void 0:e.DETAILS,a=null===(t=(yield r.resolve()).properties)||void 0===t?void 0:t.APPROVAL_MESSAGE;this.originalDetailsSchema=i,this.setApprovalMessage&&i?this.jsonSchema=Object.assign(Object.assign({},i),{properties:Object.assign(Object.assign({},i.properties),{APPROVAL_MESSAGE:a})}):this.jsonSchema=i,this.bulkInsert&&this.jsonSchema&&(this.transformSchemaForBulkInsert(),yield d.DOM.nextUpdate(),this.initializeBulkInsertData())}})}initializeBulkInsertData(){var e;if(!(null===(e=this.data)||void 0===e?void 0:e.items)||0===this.data.items.length){const e=[];for(let t=0;t<this.bulkInsertMinItems;t+=1)e.push({});this.data=Object.assign(Object.assign({},this.data),{items:e})}}transformSchemaForBulkInsert(){if(!this.originalDetailsSchema)return;const e={type:"array",items:this.originalDetailsSchema,minItems:this.bulkInsertMinItems};void 0!==this.bulkInsertMaxItems&&(e.maxItems=this.bulkInsertMaxItems),this.jsonSchema={type:"object",properties:{items:e},required:["items"]},this.userProvidedUiSchema||(this.userProvidedUiSchema=this.uischema),this.uischema&&function(e){var t;return null===(t=null==e?void 0:e.elements)||void 0===t?void 0:t.some(e=>"#/properties/items"===e.scope&&"Control"===e.type)}(this.uischema)||(this.uischema=function(e){const t={addLabel:"Add another",deleteLabel:""};return e&&(t.childUiSchema=e),{type:"VerticalLayout",elements:[{type:"Control",scope:"#/properties/items",options:t}]}}(this.userProvidedUiSchema))}renderersChanged(){this.updateMergedRenderers()}additionalRenderersChanged(){this.updateMergedRenderers()}updateMergedRenderers(){const{renderers:e=[],additionalRenderers:t=[]}=this;this.mergedRenderers=[...e,...t]}get reviewRecordId(){if(!this.reviewIdField)return;const e=Le(this.data,this.reviewIdField);return null==e?void 0:String(e)}_submit(){return(0,r.sH)(this,void 0,void 0,function*(){if(!this.submitting){if(this.confirmationMessage){const e=(e=>{let t=e.parentElement;for(;t;){if(t.tagName&&(t.tagName.toLowerCase().includes("modal")||t.classList.contains("edit-modal")))return t;t=t.parentElement}})(this);e||v.warn("No modal parent found for confirmation dialog. Dialog may not display as expected.");if(!(yield Pt(this.confirmationMessage,this.prefix,e)))return}if(function(e,t){if(!t||!e)return!1;const o=Object.keys(t.properties);let r=0;return Object.keys(e).forEach(t=>{o.includes(t)||(delete e[t],r+=1,v.debug("Removing key ",t,"from provided data because it is not part of the payload"))}),r>0}(this.data,this.jsonSchema)&&(this.data=Object.assign({},this.data),yield d.DOM.nextUpdate()),this.submitted=!0,!this.bulkInsert)return this.showSubmitReview&&!this.hasValidationErrors()?(this.reviewSections=yield $e(this.data||{},this.userProvidedUiSchema||this.uischema,this.originalDetailsSchema||this.jsonSchema),void(this.reviewMode=!0)):void(yield this._performSubmit());yield this._submitBulk()}})}backFromReview(){this.reviewMode=!1}_submitFromReview(){return(0,r.sH)(this,void 0,void 0,function*(){this.reviewMode=!1,yield this._performSubmit()})}hasValidationErrors(){var e,t,o,r,i,a,n,s;const l=this.jsonFormsEl;return l?(null!==(r=null===(o=null===(t=null===(e=l.jsonforms)||void 0===e?void 0:e.core)||void 0===t?void 0:t.errors)||void 0===o?void 0:o.length)&&void 0!==r?r:0)>0||(null!==(s=null===(n=null===(a=null===(i=l.jsonforms)||void 0===i?void 0:i.core)||void 0===a?void 0:a.additionalErrors)||void 0===n?void 0:n.length)&&void 0!==s?s:0)>0:this.errors.length>0}_performSubmit(){return(0,r.sH)(this,void 0,void 0,function*(){const e=Object.assign({},this.data),t=this.buildCommitPayload(e);if(v.debug({payload:e,errors:this.errors}),this.$emit("submit",{payload:e,errors:this.errors}),0!==Object.entries(e).length&&!this.hasValidationErrors()&&this.resourceName){let o;this.submitting=!0;try{o=yield this.connect.commitEvent(this.resourceName,t)}catch(t){const o=[{CODE:"SUBMIT_ERROR",TEXT:String(t)}];return this.submitting=!1,void this.$emit("submit-failure",{payload:e,errors:o})}if(this.submitting=!1,o.ERROR){o.ERROR.find(e=>"APPROVAL_MESSAGE_MISSING"===e.CODE)&&!this.setApprovalMessage?(this.pendingPayload=e,this.showApprovalModal()):(this.applyServerFieldErrors(o.ERROR),this.$emit("submit-failure",{payload:e,errors:o.ERROR}))}else this.$emit("submit-success",{payload:e,response:o})}})}_submitBulk(){return(0,r.sH)(this,void 0,void 0,function*(){var e;const t=(null===(e=this.data)||void 0===e?void 0:e.items)||[];if(t.length<this.bulkInsertMinItems){const e={CODE:"BULK_INSERT_MIN_ITEMS",TEXT:`At least ${this.bulkInsertMinItems} item(s) required`};return void this.$emit("submit-failure",{payload:this.data,errors:[e]})}if(void 0!==this.bulkInsertMaxItems&&t.length>this.bulkInsertMaxItems){const e={CODE:"BULK_INSERT_MAX_ITEMS",TEXT:`Maximum ${this.bulkInsertMaxItems} item(s) allowed`};return void this.$emit("submit-failure",{payload:this.data,errors:[e]})}if(v.debug({bulkItems:t,errors:this.errors}),this.$emit("submit",{payload:this.data,errors:this.errors}),0===t.length||this.errors.length||!this.resourceName)return;this.submitting=!0;const o={successful:[],failed:[]};try{for(let e=0;e<t.length;e+=1){const t=this.rowSubmitStatuses.get(e);"success"!==(null==t?void 0:t.status)&&this.rowSubmitStatuses.set(e,{status:"pending"})}this.rowSubmitStatuses=new Map(this.rowSubmitStatuses),this.$emit("row-status-changed",{statuses:this.rowSubmitStatuses});for(let e=0;e<t.length;e+=1){const r=this.rowSubmitStatuses.get(e);if("success"===(null==r?void 0:r.status))continue;const i=t[e],a=this.buildCommitPayload(i,!0);this.updateRowStatus(e,{status:"submitting"});try{const t=yield this.connect.commitEvent(this.resourceName,a);t.ERROR?(o.failed.push({item:i,index:e,errors:t.ERROR}),this.updateRowStatus(e,{status:"failed",errors:t.ERROR})):(o.successful.push({item:i,index:e,response:t}),this.updateRowStatus(e,{status:"success",response:t}))}catch(t){const r=[{CODE:"SUBMIT_ERROR",TEXT:String(t)}];o.failed.push({item:i,index:e,errors:r}),this.updateRowStatus(e,{status:"failed",errors:r})}}}finally{this.submitting=!1}this.$emit("bulk-submit-complete",o),0===o.failed.length?(this.serverFieldErrors=[],this.$emit("submit-success",{payload:this.data,results:o})):0===o.successful.length?(this.applyBulkServerFieldErrors(o.failed),this.$emit("submit-failure",{payload:this.data,errors:o.failed.flatMap(e=>e.errors)})):(this.applyBulkServerFieldErrors(o.failed),this.$emit("submit-partial-success",{payload:this.data,results:o}))})}updateRowStatus(e,t){this.rowSubmitStatuses.set(e,t),this.rowSubmitStatuses=new Map(this.rowSubmitStatuses),this.$emit("row-status-changed",{statuses:this.rowSubmitStatuses,index:e,status:t})}clearRowSubmitStatuses(){this.rowSubmitStatuses=new Map}submitSingleRow(e){return(0,r.sH)(this,void 0,void 0,function*(){var t;if(!this.bulkInsert)return void v.warn("submitSingleRow called but bulkInsert is not enabled");const o=((null===(t=this.data)||void 0===t?void 0:t.items)||[])[e];if(!o)return void v.warn(`submitSingleRow: No item found at index ${e}`);const r=this.rowSubmitStatuses.get(e);if("success"===(null==r?void 0:r.status))return void v.debug(`Row ${e} already submitted successfully`);if(!this.resourceName)return void v.warn("submitSingleRow: No resourceName configured");this.updateRowStatus(e,{status:"submitting"});const i=this.buildCommitPayload(o,!0);try{const t=yield this.connect.commitEvent(this.resourceName,i);t.ERROR?(this.updateRowStatus(e,{status:"failed",errors:t.ERROR}),this.applyServerFieldErrors(t.ERROR,`/items/${e}`),this.$emit("row-submit-failure",{index:e,item:o,errors:t.ERROR})):(this.updateRowStatus(e,{status:"success",response:t}),this.$emit("row-submit-success",{index:e,item:o,response:t}))}catch(t){const r=[{CODE:"SUBMIT_ERROR",TEXT:String(t)}];this.updateRowStatus(e,{status:"failed",errors:r}),this.$emit("row-submit-failure",{index:e,item:o,errors:r})}})}filterDataByUiSchema(e){if(!this.userProvidedUiSchema)return e;const t=Et(this.userProvidedUiSchema).filter(e=>!e.isHidden).map(e=>e.fieldName);if(0===t.length)return e;const o={};for(const r of t)r in e&&(o[r]=e[r]);return o}buildCommitPayload(e,t=!1){const o=t?this.filterDataByUiSchema(e):e;if(this.setApprovalMessage){const{APPROVAL_MESSAGE:e}=o;return{DETAILS:(0,r.Tt)(o,["APPROVAL_MESSAGE"]),APPROVAL_MESSAGE:e}}return{DETAILS:o}}get isSubmitHidden(){return!this.readonly&&!this.hideSubmit}get isResetVisible(){return!this.readonly&&this.showReset}deepClone(){const e=super.deepClone();try{e.uischema=structuredClone(this.uischema),e.jsonSchema=structuredClone(this.jsonSchema)}catch(e){v.error("Error cloning form",e)}return e}submitPart(e){this.submitted=!0}onChange(e){v.debug("Form data changed:",e.detail),e.detail&&(e.stopPropagation(),this.data=e.detail.data,this.errors=e.detail.errors,e.detail.additionalErrors.length&&(this.errors=[...this.errors,...e.detail.additionalErrors]),this.$emit("data-change",e.detail))}disconnectedCallback(){super.disconnectedCallback(),this.reset()}handleResetClicked(){this.reset(),this.$emit("reset-clicked")}reset(e=!0){this.submitted=!1,this.reviewMode=!1,this.reviewSections=[],this.clearRowSubmitStatuses(),this.serverFieldErrors=[],e&&(this.data={}),d.Observable.notify(this,"submitted")}applyServerFieldErrors(e,t){this.serverFieldErrors=Dt(e,this.jsonSchema,t)}applyBulkServerFieldErrors(e){this.serverFieldErrors=e.flatMap(({index:e,errors:t})=>Dt(t,this.jsonSchema,`/items/${e}`))}showApprovalModal(){this.approvalMessage="",this.approvalModal&&this.approvalModal.show()}closeApprovalModal(){this.approvalMessage="",this.pendingPayload=null,this.approvalModal&&this.approvalModal.close()}submitWithApproval(){return(0,r.sH)(this,void 0,void 0,function*(){if(!this.approvalMessage||!this.approvalMessage.trim())return void v.warn("Approval message is required");if(!this.pendingPayload)return v.error("No pending payload to submit"),void this.closeApprovalModal();this.submitting=!0;const e={DETAILS:this.pendingPayload,APPROVAL_MESSAGE:this.approvalMessage},t=this.pendingPayload;let o;try{o=yield this.connect.commitEvent(this.resourceName,e)}catch(e){const o=[{CODE:"SUBMIT_ERROR",TEXT:String(e)}];return this.submitting=!1,void this.$emit("submit-failure",{payload:t,errors:o})}this.submitting=!1,o.ERROR?(this.applyServerFieldErrors(o.ERROR),this.$emit("submit-failure",{payload:t,errors:o.ERROR})):(this.$emit("submit-success",{payload:t,response:o}),this.closeApprovalModal())})}handleCsvFileSelected(e){return(0,r.sH)(this,void 0,void 0,function*(){var t,o;const r=null===(t=e.target.files)||void 0===t?void 0:t[0];if(r){try{const e=function(e){var t,o,r;const i=[];if(!(null==e?void 0:e.trim()))return i.push("CSV file is empty"),{headers:[],rows:[],errors:i};const a=kt().parse(e,{header:!0,skipEmptyLines:!0,dynamicTyping:!1}),n=null!==(t=a.meta.fields)&&void 0!==t?t:[];if(0===n.length)return i.push("CSV file has no headers"),{headers:[],rows:[],errors:i};for(const e of a.errors)i.push(null!==(o=e.message)&&void 0!==o?o:`Parse error at row ${null!==(r=e.row)&&void 0!==r?r:"?"}`);const s=a.data.map(e=>{const t={};for(const o of n){const r=e[o];t[o]=null==r?"":String(r)}return t});return{headers:n,rows:s,errors:i}}(yield r.text());if(e.errors.length>0)return this.$emit("csv-parse-error",{errors:e.errors,fileName:r.name}),v.warn("CSV parse errors:",e.errors),void this.clearCsvFileInput();if(0===e.rows.length)return this.$emit("csv-parse-error",{errors:["CSV file contains no data rows"],fileName:r.name}),void this.clearCsvFileInput();const{mappedRows:t,unmappedColumns:i}=function(e,t,o){var r,i;if(!(null==t?void 0:t.properties)||0===e.length)return{mappedRows:[],unmappedColumns:[]};const a=Object.keys(t.properties),n=new Map;if(o){const e=Et(o);for(const{fieldName:o,label:r}of e)r&&r.trim()&&t.properties[o]&&n.set(r.trim().toLowerCase(),o)}const s=new Map,l=[];if(e.length>0){const t=Object.keys(null!==(r=e[0])&&void 0!==r?r:{});for(const e of t){const t=e.toUpperCase();let r=a.find(e=>e.toUpperCase()===t);!r&&o&&(r=null!==(i=n.get(e.trim().toLowerCase()))&&void 0!==i?i:void 0),r?s.set(e,r):l.push(e)}}const d=e.map(e=>{var o;const r={};for(const[i,a]of s){const n=e[i],s=null===(o=t.properties)||void 0===o?void 0:o[a];r[a]=Mt(n,s)}return r});return{mappedRows:d,unmappedColumns:l}}(e.rows,this.originalDetailsSchema,this.uischema);if(0===t.length)return this.$emit("csv-parse-error",{errors:["No CSV columns could be matched to form fields"],fileName:r.name}),void this.clearCsvFileInput();const a=(null===(o=this.data)||void 0===o?void 0:o.items)||[];let n=t;if(void 0!==this.bulkInsertMaxItems){const e=this.bulkInsertMaxItems-a.length;if(e<=0)return this.$emit("csv-parse-error",{errors:[`Maximum of ${this.bulkInsertMaxItems} items already reached`],fileName:r.name}),void this.clearCsvFileInput();t.length>e&&(n=t.slice(0,e),v.warn(`Truncated CSV import from ${t.length} to ${e} rows due to max items limit`))}this.data={items:[...a,...n]},this.$emit("csv-imported",{rowCount:n.length,totalRowsInFile:t.length,unmappedColumns:i,fileName:r.name}),v.debug("CSV imported successfully",{rowCount:n.length,unmappedColumns:i})}catch(e){this.$emit("csv-parse-error",{errors:[`Failed to read CSV file: ${String(e)}`],fileName:r.name}),v.error("CSV import error:",e)}this.clearCsvFileInput()}})}clearCsvFileInput(){this.csvFileInput&&(this.csvFileInput.value="")}downloadCsvTemplate(){if(!this.originalDetailsSchema)return v.warn("Cannot download CSV template: schema not available"),void this.$emit("csv-template-error",{error:"Schema not available"});const e=function(e,t,o=!0,r=!0){if(!(null==e?void 0:e.properties))return"";const i=new Set(e.required||[]),a=[],n=[],s=t?Et(t):null;if(s&&s.length>0)for(const{fieldName:t,label:o,isHidden:r}of s){if(r)continue;const s=e.properties[t];if(!s)continue;a.push(o&&o.trim()?o.trim():t);const l=Tt(t,s,i.has(t));n.push(Rt(l))}else for(const[t,r]of Object.entries(e.properties)){const e=i.has(t);if(!o&&!e)continue;a.push(t);const s=Tt(t,r,e);n.push(Rt(s))}if(0===a.length)return"";const l=`${a.map(e=>Rt(e)).join(",")}\n${n.join(",")}`;return r?"\ufeff"+l:l}(this.originalDetailsSchema,this.uischema);if(!e)return v.warn("Cannot download CSV template: no fields in schema"),void this.$emit("csv-template-error",{error:"No fields found in schema"});const t=`${this.resourceName?this.resourceName.replace(/^EVENT_/,"").toLowerCase():"bulk_insert"}_template.csv`;!function(e,t="template.csv"){const o=new Blob([e],{type:"text/csv;charset=utf-8;"}),r=URL.createObjectURL(o),i=document.createElement("a");i.href=r,i.download=t,i.style.display="none",document.body.appendChild(i),i.click(),document.body.removeChild(i),URL.revokeObjectURL(r)}(e,t),this.$emit("csv-template-downloaded",{fileName:t}),v.debug("CSV template downloaded:",t)}};(0,r.Cg)([(0,d.attr)({attribute:"design-system-prefix"})],Ft.prototype,"prefix",void 0),(0,r.Cg)([d.attr],Ft.prototype,"resourceName",void 0),(0,r.Cg)([(0,d.attr)({attribute:"confirmation-message"})],Ft.prototype,"confirmationMessage",void 0),(0,r.Cg)([(0,d.attr)({attribute:"set-approval-message",mode:"boolean"})],Ft.prototype,"setApprovalMessage",void 0),(0,r.Cg)([(0,d.attr)({attribute:"approval-message-label"})],Ft.prototype,"approvalMessageLabel",void 0),(0,r.Cg)([d.observable],Ft.prototype,"serverFieldErrors",void 0),(0,r.Cg)([d.observable],Ft.prototype,"approvalMessage",void 0),(0,r.Cg)([d.observable],Ft.prototype,"uischema",void 0),(0,r.Cg)([d.observable],Ft.prototype,"renderers",void 0),(0,r.Cg)([d.observable],Ft.prototype,"additionalRenderers",void 0),(0,r.Cg)([d.observable],Ft.prototype,"mergedRenderers",void 0),(0,r.Cg)([d.observable],Ft.prototype,"jsonSchema",void 0),(0,r.Cg)([i.dm],Ft.prototype,"connect",void 0),(0,r.Cg)([d.observable],Ft.prototype,"data",void 0),(0,r.Cg)([d.observable],Ft.prototype,"submitting",void 0),(0,r.Cg)([d.observable],Ft.prototype,"submitted",void 0),(0,r.Cg)([(0,d.attr)({mode:"boolean"})],Ft.prototype,"readonly",void 0),(0,r.Cg)([(0,d.attr)({attribute:"hide-submit-button",mode:"boolean"})],Ft.prototype,"hideSubmit",void 0),(0,r.Cg)([(0,d.attr)({attribute:"show-reset-button",mode:"boolean"})],Ft.prototype,"showReset",void 0),(0,r.Cg)([(0,d.attr)({attribute:"bulk-insert",mode:"boolean"})],Ft.prototype,"bulkInsert",void 0),(0,r.Cg)([(0,d.attr)({attribute:"submit-button-text"})],Ft.prototype,"submitButtonText",void 0),(0,r.Cg)([(0,d.attr)({attribute:"bulk-submit-button-text"})],Ft.prototype,"bulkSubmitButtonText",void 0),(0,r.Cg)([(0,d.attr)({attribute:"reset-button-text"})],Ft.prototype,"resetButtonText",void 0),(0,r.Cg)([(0,d.attr)({attribute:"bulk-insert-min-items",converter:{fromView:e=>parseInt(e,10)||1,toView:e=>String(e)}})],Ft.prototype,"bulkInsertMinItems",void 0),(0,r.Cg)([(0,d.attr)({attribute:"bulk-insert-max-items",converter:{fromView:e=>e?parseInt(e,10):void 0,toView:e=>void 0!==e?String(e):""}})],Ft.prototype,"bulkInsertMaxItems",void 0),(0,r.Cg)([(0,d.attr)({attribute:"show-submit-review",mode:"boolean"})],Ft.prototype,"showSubmitReview",void 0),(0,r.Cg)([(0,d.attr)({attribute:"review-button-text"})],Ft.prototype,"reviewButtonText",void 0),(0,r.Cg)([(0,d.attr)({attribute:"review-heading"})],Ft.prototype,"reviewHeading",void 0),(0,r.Cg)([(0,d.attr)({attribute:"review-id-field"})],Ft.prototype,"reviewIdField",void 0),(0,r.Cg)([d.observable],Ft.prototype,"rowSubmitStatuses",void 0),(0,r.Cg)([d.observable],Ft.prototype,"reviewMode",void 0),(0,r.Cg)([d.observable],Ft.prototype,"reviewSections",void 0),(0,r.Cg)([d.volatile],Ft.prototype,"isSubmitHidden",null),(0,r.Cg)([d.volatile],Ft.prototype,"isResetVisible",null),Ft=(0,r.Cg)([(0,d.customElement)({name:"foundation-form",template:Re,styles:I,shadowOptions:null})],Ft);const jt=Symbol("component-type"),Ut=Symbol("component-instance"),Bt="foundation-layout-autosave",Ht="f-layout-key",Yt="36px",Gt=()=>{const e=(0,le.designTokensMap)();if(!e.value)return Yt;const{style:t,space:o}=e.value.design_tokens;return(t.baseHeightMultiplier.$value+t.density.$value)*o.designUnit.$value-4+"px"},Vt=()=>{const e=(0,le.selectCustomToken)("rapid","layout","item","border","width");if(!(null==e?void 0:e.$value))return 0;const t=parseFloat(String(e.$value));return Number.isNaN(t)?0:t};class Wt extends Error{constructor(e){super(e)}}class Zt extends Error{constructor(e){super(e)}}const qt="first-loaded",Xt="item-added",Jt="item-removed",Qt="item-resized",Kt="state-changed",eo="change-title",to="autosave",oo=(0,h.createLogger)("foundation-layout");const ro=new Map;function io(e){return ro.get(e)}function ao(){const e=this.parentElement;switch(e[jt]){case"root":case"horizontal":case"vertical":case"tabs":return e;default:throw new Wt("Using layout region outside of layout root")}}const no=e=>({horizontal:"column",vertical:"row",tabs:"stack"}[e]),so=d.html`
1608
+ <template>
1609
+ <slot class="target"></slot>
1610
+ </template>
1611
+ `,lo=["horizontal","vertical","tabs"];var co;class po extends c.FoundationElement{constructor(){super(...arguments),this.closable=!1,this[co]="item"}connectedCallback(){var e;let t;super.connectedCallback();const o=io(this.registration);if(this.slottedElements=this.shadowRoot.querySelector("slot.target").assignedElements(),o&&this.slottedElements.length>0)throw new Wt(`Cannot use both factory registration and slotted content for registration "${this.registration}". Either register a factory via registerFactory() OR provide slotted content, but not both.`);t=o?this.cacheElementsAndRegister({factory:o,id:this.registration}):this.cacheElementsAndRegister({elements:this.slottedElements,id:this.registration});const r={type:"component",componentType:t,title:null!==(e=this.title)&&void 0!==e?e:`Item ${t}`,reorderEnabled:!0,isClosable:this.closable,size:this.size};this.getParentLayoutComponent().addItemFromChild(r),this.requestLayoutReload()}getParentLayoutComponent(){return ao.apply(this)}requestLayoutReload(){this.getParentLayoutComponent().requestLayoutReload()}cacheElementsAndRegister(e){return this.getParentLayoutComponent().cacheElementsAndRegister(e)}}co=jt,(0,r.Cg)([d.attr],po.prototype,"title",void 0),(0,r.Cg)([(0,d.attr)({mode:"boolean"})],po.prototype,"closable",void 0),(0,r.Cg)([d.attr],po.prototype,"size",void 0),(0,r.Cg)([d.attr],po.prototype,"registration",void 0);const uo=po.compose({baseName:"layout-item",template:so});var mo;const ho=lo[0];class vo extends c.FoundationElement{constructor(){super(...arguments),this.type=ho,this[mo]="horizontal"}connectedCallback(){super.connectedCallback(),lo.includes(this.type)||(this.type=ho,oo.warn(`Using invalid attribute "type", defaulting to ${ho}`)),this[jt]=this.type,this.setupLayoutRegion()}setupLayoutRegion(){this.layoutConfig=this.getParentLayoutComponent().addItemFromChild(this.constructLayoutConfig())}constructLayoutConfig(){return{type:no(this[jt]),content:[],size:this.size}}getParentLayoutComponent(){return ao.apply(this)}addItemFromChild(e){return this.layoutConfig.content.push(e),this.layoutConfig.content[this.layoutConfig.content.length-1]}requestLayoutReload(){this.getParentLayoutComponent().requestLayoutReload()}cacheElementsAndRegister(e){return this.getParentLayoutComponent().cacheElementsAndRegister(e)}}mo=jt,(0,r.Cg)([d.attr],vo.prototype,"size",void 0),(0,r.Cg)([d.attr],vo.prototype,"type",void 0);const go=vo.compose({baseName:"layout-region",template:so});var bo=o(37619),yo=o(34814),fo=o(79271),$o=o(98316),wo=o(32808);const xo="data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCA0NDggNTEyIj48IS0tISBGb250IEF3ZXNvbWUgUHJvIDYuMi4wIGJ5IEBmb250YXdlc29tZSAtIGh0dHBzOi8vZm9udGF3ZXNvbWUuY29tIExpY2Vuc2UgLSBodHRwczovL2ZvbnRhd2Vzb21lLmNvbS9saWNlbnNlIChDb21tZXJjaWFsIExpY2Vuc2UpIENvcHlyaWdodCAyMDIyIEZvbnRpY29ucywgSW5jLiAtLT48cGF0aCBkPSJNMTQ0IDMyaC0xMjhDNy4xNTYgMzIgMCAzOS4xNiAwIDQ4djEyOEMwIDE4NC44IDcuMTU2IDE5MiAxNiAxOTJTMzIgMTg0LjggMzIgMTc2VjY0aDExMkMxNTIuOCA2NCAxNjAgNTYuODQgMTYwIDQ4UzE1Mi44IDMyIDE0NCAzMnpNMTQ0IDQ0OEgzMnYtMTEyQzMyIDMyNy4yIDI0Ljg0IDMyMCAxNiAzMjBTMCAzMjcuMiAwIDMzNnYxMjhDMCA0NzIuOCA3LjE1NiA0ODAgMTYgNDgwaDEyOEMxNTIuOCA0ODAgMTYwIDQ3Mi44IDE2MCA0NjRTMTUyLjggNDQ4IDE0NCA0NDh6TTQzMiAzMjBjLTguODQ0IDAtMTYgNy4xNTYtMTYgMTZWNDQ4aC0xMTJjLTguODQ0IDAtMTYgNy4xNTYtMTYgMTZzNy4xNTYgMTYgMTYgMTZoMTI4YzguODQ0IDAgMTYtNy4xNTYgMTYtMTZ2LTEyOEM0NDggMzI3LjIgNDQwLjggMzIwIDQzMiAzMjB6TTQzMiAzMmgtMTI4QzI5NS4yIDMyIDI4OCAzOS4xNiAyODggNDhTMjk1LjIgNjQgMzA0IDY0SDQxNnYxMTJDNDE2IDE4NC44IDQyMy4yIDE5MiA0MzIgMTkyUzQ0OCAxODQuOCA0NDggMTc2di0xMjhDNDQ4IDM5LjE2IDQ0MC44IDMyIDQzMiAzMnoiIGZpbGw9IiM4NzliYTYiLz48L3N2Zz4=",So="data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCA1MTIgNTEyIj48IS0tISBGb250IEF3ZXNvbWUgUHJvIDYuMi4wIGJ5IEBmb250YXdlc29tZSAtIGh0dHBzOi8vZm9udGF3ZXNvbWUuY29tIExpY2Vuc2UgLSBodHRwczovL2ZvbnRhd2Vzb21lLmNvbS9saWNlbnNlIChDb21tZXJjaWFsIExpY2Vuc2UpIENvcHlyaWdodCAyMDIyIEZvbnRpY29ucywgSW5jLiAtLT48cGF0aCBkPSJNMCA0NjRDMCA0NTUuMiA3LjE2NCA0NDggMTYgNDQ4SDQ5NkM1MDQuOCA0NDggNTEyIDQ1NS4yIDUxMiA0NjRDNTEyIDQ3Mi44IDUwNC44IDQ4MCA0OTYgNDgwSDE2QzcuMTY0IDQ4MCAwIDQ3Mi44IDAgNDY0eiIgZmlsbD0iIzg3OWJhNiIvPjwvc3ZnPg==",Co="data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAzMjAgNTEyIj48IS0tISBGb250IEF3ZXNvbWUgUHJvIDYuMi4wIGJ5IEBmb250YXdlc29tZSAtIGh0dHBzOi8vZm9udGF3ZXNvbWUuY29tIExpY2Vuc2UgLSBodHRwczovL2ZvbnRhd2Vzb21lLmNvbS9saWNlbnNlIChDb21tZXJjaWFsIExpY2Vuc2UpIENvcHlyaWdodCAyMDIyIEZvbnRpY29ucywgSW5jLiAtLT48cGF0aCBkPSJNMzE1LjMgNDExLjNjLTYuMjUzIDYuMjUzLTE2LjM3IDYuMjUzLTIyLjYzIDBMMTYwIDI3OC42bC0xMzIuNyAxMzIuN2MtNi4yNTMgNi4yNTMtMTYuMzcgNi4yNTMtMjIuNjMgMGMtNi4yNTMtNi4yNTMtNi4yNTMtMTYuMzcgMC0yMi42M0wxMzcuNCAyNTZMNC42OSAxMjMuM2MtNi4yNTMtNi4yNTMtNi4yNTMtMTYuMzcgMC0yMi42M2M2LjI1My02LjI1MyAxNi4zNy02LjI1MyAyMi42MyAwTDE2MCAyMzMuNGwxMzIuNy0xMzIuN2M2LjI1My02LjI1MyAxNi4zNy02LjI1MyAyMi42MyAwYzYuMjUzIDYuMjUzIDYuMjUzIDE2LjM3IDAgMjIuNjNMMTgyLjYgMjU2bDEzMi43IDEzMi43QzMyMS42IDM5NC45IDMyMS42IDQwNS4xIDMxNS4zIDQxMS4zeiIgZmlsbD0iIzg3OWJhNiIvPjwvc3ZnPg==",Ao="data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCA0NDggNTEyIj48IS0tISBGb250IEF3ZXNvbWUgUHJvIDYuMi4wIGJ5IEBmb250YXdlc29tZSAtIGh0dHBzOi8vZm9udGF3ZXNvbWUuY29tIExpY2Vuc2UgLSBodHRwczovL2ZvbnRhd2Vzb21lLmNvbS9saWNlbnNlIChDb21tZXJjaWFsIExpY2Vuc2UpIENvcHlyaWdodCAyMDIyIEZvbnRpY29ucywgSW5jLiAtLT48cGF0aCBkPSJNNC4yNTEgMTgxLjFDNy4zOTIgMTc3LjcgMTEuNjkgMTc1LjEgMTYgMTc1LjFjMy44OTEgMCA3Ljc4MSAxLjQwNiAxMC44NiA0LjI1bDE5Ny4xIDE4MS4xbDE5Ny4xLTE4MS4xYzYuNS02IDE2LjY0LTUuNjI1IDIyLjYxIC45MDYyYzYgNi41IDUuNTk0IDE2LjU5LS44OTA2IDIyLjU5bC0yMDggMTkyYy02LjE1NiA1LjY4OC0xNS41NiA1LjY4OC0yMS43MiAwbC0yMDgtMTkyQy0xLjM0MyAxOTcuNy0xLjc0OSAxODcuNiA0LjI1MSAxODEuMXoiIGZpbGw9IiM4NzliYTYiLz48L3N2Zz4=",Io="data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB2ZXJzaW9uPSIxLjEiIHdpZHRoPSIxMDAwIiBoZWlnaHQ9IjEwMDAiIHZpZXdCb3g9IjAgMCAxMDAwIDEwMDAiIHhtbDpzcGFjZT0icHJlc2VydmUiPiA8cmVjdCB4PSIwIiB5PSIwIiB3aWR0aD0iMTAwJSIgaGVpZ2h0PSIxMDAlIiBmaWxsPSJyZ2JhKDI1NSwyNTUsMjU1LDApIi8+IDxnIHRyYW5zZm9ybT0ibWF0cml4KDEuNDY5MiAwIDAgMS40NjkyIDQ5OS45OTA2IDQ5OS45OTA2KSIgaWQ9IjE3OTM0MSI+IDxnIHN0eWxlPSIiIHZlY3Rvci1lZmZlY3Q9Im5vbi1zY2FsaW5nLXN0cm9rZSI+IDxnIHRyYW5zZm9ybT0ibWF0cml4KDIyLjIyMjIgMCAwIDIyLjIyMjIgLTQ0LjQ0NDcgNDQuNDQ0MSkiPiA8cGF0aCBzdHlsZT0ic3Ryb2tlOiBub25lOyBzdHJva2Utd2lkdGg6IDE7IHN0cm9rZS1kYXNoYXJyYXk6IG5vbmU7IHN0cm9rZS1saW5lY2FwOiBidXR0OyBzdHJva2UtZGFzaG9mZnNldDogMDsgc3Ryb2tlLWxpbmVqb2luOiBtaXRlcjsgc3Ryb2tlLW1pdGVybGltaXQ6IDQ7IGlzLWN1c3RvbS1mb250OiBub25lOyBmb250LWZpbGUtdXJsOiBub25lOyBmaWxsOiByZ2IoMTA5LDEyNywxMzgpOyBmaWxsLXJ1bGU6IG5vbnplcm87IG9wYWNpdHk6IDE7IiB0cmFuc2Zvcm09IiB0cmFuc2xhdGUoLTE2LCAtMjApIiBkPSJNIDI3IDMzIEggNSBhIDIgMiAwIDAgMSAtMiAtMiBWIDkgQSAyIDIgMCAwIDEgNSA3IEggMTUgViA5IEggNSBWIDMxIEggMjcgViAyMSBoIDIgViAzMSBBIDIgMiAwIDAgMSAyNyAzMyBaIiBzdHJva2UtbGluZWNhcD0icm91bmQiLz4gPC9nPiA8ZyB0cmFuc2Zvcm09Im1hdHJpeCgyMi4yMjIyIDAgMCAyMi4yMjIyIDEzNy42NzEyIC0xMzcuNjcxNSkiPiA8cGF0aCBzdHlsZT0ic3Ryb2tlOiBub25lOyBzdHJva2Utd2lkdGg6IDE7IHN0cm9rZS1kYXNoYXJyYXk6IG5vbmU7IHN0cm9rZS1saW5lY2FwOiBidXR0OyBzdHJva2UtZGFzaG9mZnNldDogMDsgc3Ryb2tlLWxpbmVqb2luOiBtaXRlcjsgc3Ryb2tlLW1pdGVybGltaXQ6IDQ7IGlzLWN1c3RvbS1mb250OiBub25lOyBmb250LWZpbGUtdXJsOiBub25lOyBmaWxsOiByZ2IoMTA5LDEyNywxMzgpOyBmaWxsLXJ1bGU6IG5vbnplcm87IG9wYWNpdHk6IDE7IiB0cmFuc2Zvcm09IiB0cmFuc2xhdGUoLTI0LjE5NTIsIC0xMS44MDQ4KSIgZD0iTSAxOCAzIGEgMSAxIDAgMCAwIDAgMiBIIDI5LjU5IEwgMTUuNzQgMTguODUgYSAxIDEgMCAxIDAgMS40MSAxLjQxIEwgMzEgNi40MSBWIDE4IGEgMSAxIDAgMCAwIDIgMCBWIDMgWiIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIi8+IDwvZz4gPGcgdHJhbnNmb3JtPSJtYXRyaXgoMjIuMjIyMiAwIDAgMjIuMjIyMiAtMC4wMDA0IC0wLjAwMDQpIj4gPHJlY3Qgc3R5bGU9InN0cm9rZTogbm9uZTsgc3Ryb2tlLXdpZHRoOiAxOyBzdHJva2UtZGFzaGFycmF5OiBub25lOyBzdHJva2UtbGluZWNhcDogYnV0dDsgc3Ryb2tlLWRhc2hvZmZzZXQ6IDA7IHN0cm9rZS1saW5lam9pbjogbWl0ZXI7IHN0cm9rZS1taXRlcmxpbWl0OiA0OyBpcy1jdXN0b20tZm9udDogbm9uZTsgZm9udC1maWxlLXVybDogbm9uZTsgZmlsbDogcmdiKDAsMCwwKTsgZmlsbC1vcGFjaXR5OiAwOyBmaWxsLXJ1bGU6IG5vbnplcm87IG9wYWNpdHk6IDE7IiB4PSItMTgiIHk9Ii0xOCIgcng9IjAiIHJ5PSIwIiB3aWR0aD0iMzYiIGhlaWdodD0iMzYiLz4gPC9nPiA8L2c+IDwvZz4gPC9zdmc+Cg==",ko=`\n .lm_dragProxy .lm_content {\n box-shadow: 2px 2px 4px rgba(0, 0, 0, 0.9);\n }\n .lm_dropTargetIndicator {\n outline: 1px dashed #cccccc;\n transition: all 200ms ease;\n }\n .lm_dropTargetIndicator .lm_inner {\n background: var(${p.neutralFillStealthRest.cssCustomProperty});\n opacity: 0.2;\n }\n .lm_dragProxy.lm_left .lm_header,\n .lm_dragProxy.lm_right .lm_header {\n width: 20px;\n float: left;\n vertical-align: top;\n }\n .lm_dragProxy.lm_left .lm_header .lm_tabs,\n .lm_dragProxy.lm_right .lm_header .lm_tabs {\n transform-origin: left top;\n top: 0;\n width: 1000px;\n }\n .lm_dragProxy.lm_left .lm_header .lm_controls,\n .lm_dragProxy.lm_right .lm_header .lm_controls {\n bottom: 0;\n }\n .lm_dragProxy.lm_left .lm_items,\n .lm_dragProxy.lm_right .lm_items {\n float: left;\n }\n .lm_dragProxy.lm_left .lm_header .lm_tabs {\n transform: rotate(-90deg) scaleX(-1);\n left: 0;\n }\n .lm_dragProxy.lm_left .lm_header .lm_tabs .lm_tab {\n transform: scaleX(-1);\n margin-top: 1px;\n }\n .lm_dragProxy.lm_left .lm_header .lm_tabdropdown_list {\n top: initial;\n right: initial;\n left: 20px;\n }\n .lm_dragProxy.lm_right .lm_content {\n float: left;\n }\n .lm_dragProxy.lm_right .lm_header .lm_tabs {\n transform: rotate(90deg) scaleX(1);\n left: 100%;\n margin-left: 0;\n }\n .lm_dragProxy.lm_right .lm_header .lm_controls {\n left: 3px;\n }\n .lm_dragProxy.lm_right .lm_header .lm_tabdropdown_list {\n top: initial;\n right: 20px;\n }\n .lm_dragProxy.lm_bottom .lm_header .lm_tab {\n margin-top: 0;\n border-top: none;\n }\n .lm_dragProxy.lm_bottom .lm_header .lm_controls,\n .lm_stack.lm_bottom .lm_header .lm_controls {\n top: 3px;\n }\n .lm_dragProxy.lm_bottom .lm_header .lm_tabdropdown_list,\n .lm_stack.lm_bottom .lm_header .lm_tabdropdown_list {\n top: initial;\n bottom: 20px;\n }\n .lm_dragProxy {\n cursor: move;\n position: absolute;\n top: 0;\n left: 0;\n z-index: 30;\n }\n .lm_dragProxy .lm_header {\n background: transparent;\n }\n .lm_dragProxy .lm_title {\n color: white;\n padding-left: 10px;\n }\n .lm_dragProxy .lm_content {\n border-top: none;\n overflow: hidden;\n }\n .lm_dropTargetIndicator {\n display: none;\n position: absolute;\n z-index: 20;\n }\n .lm_dropTargetIndicator .lm_inner {\n width: 100%;\n height: 100%;\n position: relative;\n top: 0;\n left: 0;\n }\n .lm_transition_indicator {\n display: none;\n width: 20px;\n height: 20px;\n position: absolute;\n top: 0;\n left: 0;\n z-index: 20;\n }\n`,Mo=d.css`
1612
+ * {
1613
+ --spinner-size: 50px;
1614
+ }
1615
+
1616
+ .html-spinner {
1617
+ width: var(--spinner-size);
1618
+ height: var(--spinner-size);
1619
+ border: 4px solid white;
1620
+ border-top: 4px solid var(--accent-fill-rest);
1621
+ border-radius: 50%;
1622
+ }
1623
+
1624
+ .html-spinner {
1625
+ -webkit-transition-property: -webkit-transform;
1626
+ -webkit-transition-duration: 1.2s;
1627
+ -webkit-animation-name: rotate;
1628
+ -webkit-animation-iteration-count: infinite;
1629
+ -webkit-animation-timing-function: linear;
1630
+
1631
+ -moz-transition-property: -moz-transform;
1632
+ -moz-animation-name: rotate;
1633
+ -moz-animation-duration: 1.2s;
1634
+ -moz-animation-iteration-count: infinite;
1635
+ -moz-animation-timing-function: linear;
1636
+
1637
+ transition-property: transform;
1638
+ animation-name: rotate;
1639
+ animation-duration: 1.2s;
1640
+ animation-iteration-count: infinite;
1641
+ animation-timing-function: linear;
1642
+ }
1643
+
1644
+ @-webkit-keyframes rotate {
1645
+ from {
1646
+ -webkit-transform: rotate(0deg);
1647
+ }
1648
+ to {
1649
+ -webkit-transform: rotate(360deg);
1650
+ }
1651
+ }
1652
+
1653
+ @-moz-keyframes rotate {
1654
+ from {
1655
+ -moz-transform: rotate(0deg);
1656
+ }
1657
+ to {
1658
+ -moz-transform: rotate(360deg);
1659
+ }
1660
+ }
1661
+
1662
+ @keyframes rotate {
1663
+ from {
1664
+ transform: rotate(0deg);
1665
+ }
1666
+ to {
1667
+ transform: rotate(360deg);
1668
+ }
1669
+ }
1670
+
1671
+ /* spinner positioning */
1672
+
1673
+ .html-spinner {
1674
+ position: absolute;
1675
+ z-index: 5;
1676
+ left: calc(50% - (calc(var(--spinner-size) / 2)));
1677
+ top: calc(50% - (calc(var(--spinner-size) / 2)));
1678
+ }
1679
+ `,Lo=d.css`
1680
+ ${"\n :host {\n display: block;\n position: relative;\n height: 100%;\n width: 100%;\n }\n .layout-container {\n position: absolute;\n height: 100%;\n width: 100%;\n }\n"}
1681
+ ${Mo}
1682
+
1683
+ :host {
1684
+ --foundation-tab-height: calc(
1685
+ (((var(--base-height-multiplier) + var(--density)) * var(--design-unit)) - 4) * 1px
1686
+ );
1687
+ }
1688
+
1689
+ .lm_goldenlayout {
1690
+ border-radius: calc(var(--control-corner-radius) * 1.5px);
1691
+ font-family: var(--body-font);
1692
+ box-sizing: border-box;
1693
+ }
1694
+
1695
+ .lm_goldenlayout * {
1696
+ box-sizing: border-box;
1697
+ }
1698
+
1699
+ .lm_stack.lm_item {
1700
+ background-color: var(--rapid-layout-item-background, var(--neutral-layer-3));
1701
+ border-style: solid;
1702
+ border-width: var(--rapid-layout-item-border-width, 0);
1703
+ border-color: var(--rapid-layout-item-border-color, var(--neutral-stroke-rest));
1704
+ border-radius: var(--card-corner-radius, calc(var(--control-corner-radius) * 1.5px));
1705
+ box-sizing: border-box;
1706
+ }
1707
+
1708
+ .lm_maximised .lm_header {
1709
+ border-bottom: var(--card-border, 0);
1710
+ position: unset;
1711
+ }
1712
+
1713
+ .lm_maximised .lm_header .lm_tabs {
1714
+ z-index: 3;
1715
+ }
1716
+
1717
+ .lm_content {
1718
+ background-color: var(--neutral-layer-card-container);
1719
+ border-radius: calc(var(--control-corner-radius) * 1.5px) calc(var(--control-corner-radius) * 1.5px)
1720
+ var(--card-corner-radius, calc(var(--control-corner-radius) * 1.5px))
1721
+ var(--card-corner-radius, calc(var(--control-corner-radius) * 1.5px));
1722
+ border: var(--rapid-layout-item-inner-border, 1px solid var(--neutral-stroke-rest));
1723
+ box-sizing: border-box;
1724
+ color: var(--neutral-foreground-rest);
1725
+ }
1726
+
1727
+ .lm_header .lm_tabs {
1728
+ padding: 0 16px;
1729
+ }
1730
+
1731
+ .lm_header .lm_tab.lm_active {
1732
+ background: var(--tab-active-background-color, var(--neutral-layer-card-container));
1733
+ color: var(--accent-foreground-rest);
1734
+ border-style: solid;
1735
+ border-width: var(--tab-active-border-width, 1px 1px 0 1px);
1736
+ border-color: var(--tab-active-border-color, var(--neutral-stroke-rest));
1737
+ }
1738
+
1739
+ .lm_header .lm_tab {
1740
+ align-items: center;
1741
+ background: var(--tab-rest-background-color, var(--neutral-layer-4));
1742
+ border-style: solid;
1743
+ border-width: var(--tab-rest-border-width, 1px);
1744
+ border-color: var(--tab-rest-border-color, transparent);
1745
+ border-radius: calc(var(--control-corner-radius) * 1.5px)
1746
+ calc(var(--control-corner-radius) * 1.5px) 0 0;
1747
+ color: var(--accent-foreground-rest);
1748
+ display: flex;
1749
+ font-family: inherit;
1750
+ font-size: var(--type-ramp-minus-1-font-size);
1751
+ font-weight: 400;
1752
+ height: var(--foundation-tab-height, ${Yt});
1753
+ margin-right: 2px;
1754
+ padding: 0 calc((12 + var(--design-unit) * 2 * var(--density)) * 1px);
1755
+ float: left;
1756
+ cursor: pointer;
1757
+ position: relative;
1758
+ }
1759
+
1760
+ .lm_header .lm_tab:not(.lm_active):hover {
1761
+ background-color: var(--neutral-layer-card-container);
1762
+ color: var(--accent-foreground-rest);
1763
+ }
1764
+
1765
+ .lm_header .lm_controls {
1766
+ top: 4px;
1767
+ display: flex;
1768
+ }
1769
+ .lm_header .lm_controls > * {
1770
+ width: calc(var(--foundation-tab-height, ${Yt}) - 8px);
1771
+ height: calc(var(--foundation-tab-height, ${Yt}) - 8px);
1772
+ background-repeat: no-repeat;
1773
+ background-position: center;
1774
+ background-size: calc(var(--foundation-tab-height, ${Yt}) * 0.45);
1775
+ background-color: var(
1776
+ --icon-button-background,
1777
+ color-mix(in srgb, var(--neutral-fill-strong-rest), transparent 90%)
1778
+ );
1779
+ border-radius: calc(var(--control-corner-radius) * 1.5px);
1780
+ margin-right: 4px;
1781
+ top: 3px;
1782
+ opacity: 1;
1783
+ }
1784
+ .lm_header .lm_controls > *:hover {
1785
+ background-color: color-mix(in srgb, var(--neutral-fill-strong-hover), transparent 75%);
1786
+ cursor: pointer;
1787
+ }
1788
+
1789
+ .lm_controls .lm_maximise {
1790
+ background-image: url('${xo}');
1791
+ }
1792
+ .lm_maximised .lm_controls .lm_maximise {
1793
+ background-image: url('${So}');
1794
+ }
1795
+ .lm_controls .lm_close {
1796
+ background-image: url('${Co}');
1797
+ }
1798
+ .lm_header .lm_tab .lm_close_tab {
1799
+ background-image: url('${Co}');
1800
+ background-size: calc(var(--foundation-tab-height, ${Yt}) * 0.2777);
1801
+ background-repeat: no-repeat;
1802
+ background-position: center;
1803
+ margin-left: calc((12 + var(--design-unit) * 2 * var(--density)) * 1px);
1804
+ position: relative;
1805
+ }
1806
+
1807
+ .lm_header .lm_tab:not(.lm_active) .lm_title {
1808
+ color: var(--neutral-foreground-hint);
1809
+ }
1810
+
1811
+ .lm_header .lm_controls .lm_tabdropdown::before {
1812
+ content: none;
1813
+ }
1814
+ .lm_header .lm_controls .lm_tabdropdown {
1815
+ background-image: url('${Ao}');
1816
+ }
1817
+ .lm_header .lm_tabdropdown_list {
1818
+ top: var(--foundation-tab-height, ${Yt});
1819
+ right: 108px;
1820
+ background-color: var(--neutral-layer-3);
1821
+ border: 1px solid;
1822
+ border-color: var(--neutral-stroke-rest);
1823
+ border-radius: calc(var(--control-corner-radius) * 1.5px);
1824
+ box-shadow: 0px 5px 15px rgba(0, 0, 0, 0.35);
1825
+ }
1826
+ .lm_header .lm_tabdropdown_list > .lm_tab {
1827
+ box-shadow: none;
1828
+ padding: 0 16px;
1829
+ white-space: nowrap;
1830
+ background-color: transparent;
1831
+ color: var(--neutral-foreground-rest);
1832
+ height: var(--foundation-tab-height, ${Yt});
1833
+ border-radius: 0;
1834
+ overflow: visible;
1835
+ text-overflow: unset;
1836
+ }
1837
+ .lm_header .lm_tabdropdown_list > .lm_tab:last-child {
1838
+ border-bottom: 0;
1839
+ }
1840
+
1841
+ /* gl base styles start */
1842
+ .lm_root {
1843
+ position: relative;
1844
+ }
1845
+ .lm_row > .lm_item {
1846
+ float: left;
1847
+ }
1848
+ .lm_content {
1849
+ overflow: hidden;
1850
+ position: relative;
1851
+ }
1852
+ .lm_dragging,
1853
+ .lm_dragging * {
1854
+ cursor: move !important;
1855
+ user-select: none;
1856
+ }
1857
+ .lm_maximised {
1858
+ left: 0;
1859
+ padding: 0;
1860
+ position: absolute;
1861
+ top: 0;
1862
+ z-index: 40;
1863
+ }
1864
+ .lm_maximise_placeholder {
1865
+ display: none;
1866
+ }
1867
+ .lm_splitter {
1868
+ position: relative;
1869
+ z-index: 20;
1870
+ }
1871
+ .lm_splitter:hover,
1872
+ .lm_splitter.lm_dragging {
1873
+ background: var(--accent-fill-rest);
1874
+ border-radius: calc(var(--control-corner-radius) * 4px);
1875
+ }
1876
+ .lm_splitter.lm_vertical .lm_drag_handle {
1877
+ width: 100%;
1878
+ height: 15px;
1879
+ position: absolute;
1880
+ top: -5px;
1881
+ cursor: ns-resize !important;
1882
+ }
1883
+ .lm_splitter.lm_horizontal {
1884
+ float: left;
1885
+ height: 100%;
1886
+ }
1887
+ .lm_splitter.lm_horizontal .lm_drag_handle {
1888
+ width: 15px;
1889
+ height: 100%;
1890
+ position: absolute;
1891
+ left: -5px;
1892
+ cursor: ew-resize !important;
1893
+ }
1894
+ .lm_header {
1895
+ overflow: visible;
1896
+ position: relative;
1897
+ border-bottom: var(--card-border, 0);
1898
+ }
1899
+ .lm_header .lm_controls {
1900
+ position: absolute;
1901
+ right: 3px;
1902
+ }
1903
+ .lm_header .lm_controls > li {
1904
+ cursor: pointer;
1905
+ float: left;
1906
+ width: 18px;
1907
+ height: 18px;
1908
+ text-align: center;
1909
+ }
1910
+ .lm_header ul {
1911
+ margin: 0;
1912
+ padding: 0;
1913
+ list-style-type: none;
1914
+ }
1915
+ .lm_header .lm_tabs {
1916
+ position: absolute;
1917
+ }
1918
+ .lm_header .lm_tab i {
1919
+ width: 2px;
1920
+ height: 19px;
1921
+ position: absolute;
1922
+ }
1923
+ .lm_header .lm_tab i.lm_left {
1924
+ top: 0;
1925
+ left: -2px;
1926
+ }
1927
+ .lm_header .lm_tab i.lm_right {
1928
+ top: 0;
1929
+ right: -2px;
1930
+ }
1931
+ .lm_header .lm_tab .lm_title {
1932
+ display: inline-block;
1933
+ overflow: hidden;
1934
+ text-overflow: ellipsis;
1935
+ user-select: none;
1936
+ }
1937
+ .lm_header .lm_tab .lm_close_tab {
1938
+ width: calc(var(--foundation-tab-height, ${Yt}) * 0.3888);
1939
+ height: calc(var(--foundation-tab-height, ${Yt}) * 0.3888);
1940
+ text-align: center;
1941
+ }
1942
+ .lm_stack.lm_left .lm_header,
1943
+ .lm_stack.lm_right .lm_header {
1944
+ height: 100%;
1945
+ }
1946
+ .lm_dragProxy.lm_left .lm_header,
1947
+ .lm_dragProxy.lm_right .lm_header,
1948
+ .lm_stack.lm_left .lm_header,
1949
+ .lm_stack.lm_right .lm_header {
1950
+ width: 20px;
1951
+ float: left;
1952
+ vertical-align: top;
1953
+ }
1954
+ .lm_dragProxy.lm_left .lm_header .lm_tabs,
1955
+ .lm_dragProxy.lm_right .lm_header .lm_tabs,
1956
+ .lm_stack.lm_left .lm_header .lm_tabs,
1957
+ .lm_stack.lm_right .lm_header .lm_tabs {
1958
+ transform-origin: left top;
1959
+ top: 0;
1960
+ width: 1000px;
1961
+ }
1962
+ .lm_dragProxy.lm_left .lm_header .lm_controls,
1963
+ .lm_dragProxy.lm_right .lm_header .lm_controls,
1964
+ .lm_stack.lm_left .lm_header .lm_controls,
1965
+ .lm_stack.lm_right .lm_header .lm_controls {
1966
+ bottom: 0;
1967
+ }
1968
+ .lm_dragProxy.lm_left .lm_items,
1969
+ .lm_dragProxy.lm_right .lm_items,
1970
+ .lm_stack.lm_left .lm_items,
1971
+ .lm_stack.lm_right .lm_items {
1972
+ float: left;
1973
+ }
1974
+ .lm_dragProxy.lm_left .lm_header .lm_tabs,
1975
+ .lm_stack.lm_left .lm_header .lm_tabs {
1976
+ transform: rotate(-90deg) scaleX(-1);
1977
+ left: 0;
1978
+ }
1979
+ .lm_dragProxy.lm_left .lm_header .lm_tabs .lm_tab,
1980
+ .lm_stack.lm_left .lm_header .lm_tabs .lm_tab {
1981
+ transform: scaleX(-1);
1982
+ margin-top: 1px;
1983
+ }
1984
+ .lm_dragProxy.lm_left .lm_header .lm_tabdropdown_list,
1985
+ .lm_stack.lm_left .lm_header .lm_tabdropdown_list {
1986
+ top: initial;
1987
+ right: initial;
1988
+ left: 20px;
1989
+ }
1990
+ .lm_dragProxy.lm_right .lm_content {
1991
+ float: left;
1992
+ }
1993
+ .lm_dragProxy.lm_right .lm_header .lm_tabs,
1994
+ .lm_stack.lm_right .lm_header .lm_tabs {
1995
+ transform: rotate(90deg) scaleX(1);
1996
+ left: 100%;
1997
+ margin-left: 0;
1998
+ }
1999
+ .lm_dragProxy.lm_right .lm_header .lm_controls,
2000
+ .lm_stack.lm_right .lm_header .lm_controls {
2001
+ left: 3px;
2002
+ }
2003
+ .lm_dragProxy.lm_right .lm_header .lm_tabdropdown_list,
2004
+ .lm_stack.lm_right .lm_header .lm_tabdropdown_list {
2005
+ top: initial;
2006
+ right: 20px;
2007
+ }
2008
+ .lm_dragProxy.lm_bottom .lm_header .lm_tab,
2009
+ .lm_stack.lm_bottom .lm_header .lm_tab {
2010
+ margin-top: 0;
2011
+ border-top: none;
2012
+ }
2013
+ .lm_dragProxy.lm_bottom .lm_header .lm_controls,
2014
+ .lm_stack.lm_bottom .lm_header .lm_controls {
2015
+ top: 3px;
2016
+ }
2017
+ .lm_dragProxy.lm_bottom .lm_header .lm_tabdropdown_list,
2018
+ .lm_stack.lm_bottom .lm_header .lm_tabdropdown_list {
2019
+ top: initial;
2020
+ bottom: 20px;
2021
+ }
2022
+ .lm_drop_tab_placeholder {
2023
+ float: left;
2024
+ width: 100px;
2025
+ height: 10px;
2026
+ visibility: hidden;
2027
+ }
2028
+ .lm_header .lm_tabdropdown_list {
2029
+ position: absolute;
2030
+ top: 20px;
2031
+ right: 0;
2032
+ z-index: 5;
2033
+ overflow: hidden;
2034
+ }
2035
+ .lm_header .lm_tabdropdown_list .lm_tab {
2036
+ clear: both;
2037
+ padding-right: 10px;
2038
+ margin: 0;
2039
+ }
2040
+ .lm_header .lm_tabdropdown_list .lm_tab .lm_title {
2041
+ width: 100px;
2042
+ }
2043
+ .lm_header .lm_tabdropdown_list .lm_close_tab {
2044
+ display: none !important;
2045
+ }
2046
+ .lm_dragProxy {
2047
+ position: absolute;
2048
+ top: 0;
2049
+ left: 0;
2050
+ z-index: 30;
2051
+ }
2052
+ .lm_dragProxy .lm_header {
2053
+ background: transparent;
2054
+ }
2055
+ .lm_dragProxy .lm_content {
2056
+ border-top: none;
2057
+ overflow: hidden;
2058
+ }
2059
+ .lm_dropTargetIndicator {
2060
+ display: none;
2061
+ position: absolute;
2062
+ z-index: 20;
2063
+ box-shadow: none;
2064
+ }
2065
+ .lm_dropTargetIndicator .lm_inner {
2066
+ width: 100%;
2067
+ height: 100%;
2068
+ position: relative;
2069
+ top: 0;
2070
+ left: 0;
2071
+ }
2072
+ .lm_transition_indicator {
2073
+ display: none;
2074
+ width: 20px;
2075
+ height: 20px;
2076
+ position: absolute;
2077
+ top: 0;
2078
+ left: 0;
2079
+ z-index: 20;
2080
+ }
2081
+ .lm_popin {
2082
+ width: 20px;
2083
+ height: 20px;
2084
+ position: absolute;
2085
+ bottom: 0;
2086
+ right: 0;
2087
+ z-index: 9999;
2088
+ }
2089
+ .lm_popin > * {
2090
+ width: 100%;
2091
+ height: 100%;
2092
+ position: absolute;
2093
+ top: 0;
2094
+ left: 0;
2095
+ }
2096
+ .lm_popin > .lm_bg {
2097
+ z-index: 10;
2098
+ }
2099
+ .lm_popin > .lm_icon {
2100
+ z-index: 20;
2101
+ } /*# sourceMappingURL=goldenlayout-base.css.map */
2102
+ `;var Eo=o(79780);let To=class extends d.FASTElement{constructor(){super(...arguments),this.popoutRegistry=new Map}connectedCallback(){super.connectedCallback(),this.layoutKey=new URLSearchParams(window.location.search).get(Ht),this.setupChannel(),this.setupUnloadListener(),this.layoutKey?(this.startPolling(),this.channel.postMessage("popout-handshake",{layoutKey:this.layoutKey})):this.setupListener()}disconnectedCallback(){super.disconnectedCallback(),this.channel&&this.channel.close(),this.stopPolling(),this.teardownUnloadListener(),this.layoutKey||this.closeAllPopouts()}setupChannel(){const e=this.channelName||"f-layout-popout-channel";this.channel=(0,Eo.vp)(e),this.layoutKey&&(this.channel.onmessage=e=>{if(this.channel.isMessageType("popout-sync",e)){const{layoutKey:t,state:o}=e.data.detail;t===this.layoutKey&&void 0!==o&&this.applyStateToParent(o)}})}setupListener(){this.channel&&(this.channel.onmessage=e=>{if(this.channel.isMessageType("popout-update",e)){const{layoutKey:t,geometry:o,state:r}=e.data.detail,i=this.popoutRegistry.get(t);this.popoutRegistry.set(t,Object.assign(Object.assign({},i),{geometry:o,state:r})),this.emitAutosave()}else if(this.channel.isMessageType("popout-closed",e)){const{layoutKey:t}=e.data.detail;this.popoutRegistry.delete(t),this.emitAutosave()}else if(this.channel.isMessageType("popout-handshake",e)){const{layoutKey:t}=e.data.detail,o=this.popoutRegistry.get(t);o&&this.channel.postMessage("popout-sync",{layoutKey:t,geometry:o.geometry,state:o.state})}})}applyStateToParent(e){if(!this.parentLayout)return;const t=this.parentLayout.getLayoutComponents();for(const o of t)for(const t of o)t&&"function"==typeof t.applyState&&t.applyState(e)}setupUnloadListener(){this.unloadHandler=()=>{this.layoutKey?this.channel&&this.channel.postMessage("popout-closed",{layoutKey:this.layoutKey}):this.closeAllPopouts()},window.addEventListener("beforeunload",this.unloadHandler)}teardownUnloadListener(){this.unloadHandler&&(window.removeEventListener("beforeunload",this.unloadHandler),this.unloadHandler=null)}emitAutosave(){this.$emit(to,void 0,{bubbles:!0,composed:!0})}startPolling(){this.pollInterval=setInterval(()=>(0,r.sH)(this,void 0,void 0,function*(){const e=yield this.getGeometry(),t=this.getComponentState(),o={geometry:e,state:t},r=JSON.stringify(o);r!==this.lastUpdate&&(this.broadcastUpdate(e,t),this.lastUpdate=r)}),1e3)}stopPolling(){this.pollInterval&&clearInterval(this.pollInterval)}getGeometry(){return(0,r.sH)(this,void 0,void 0,function*(){const e=yield(()=>(0,r.sH)(this,void 0,void 0,function*(){var e;if("getScreenDetails"in window)try{return null===(e=(yield window.getScreenDetails()).currentScreen)||void 0===e?void 0:e.label}catch(e){return}}))();return{screenX:window.screenX,screenY:window.screenY,outerWidth:window.outerWidth,outerHeight:window.outerHeight,screenId:e}})}getComponentState(){if(!this.parentLayout)return;const e=this.parentLayout.getLayoutComponents();for(const t of e)for(const e of t)if(e&&"function"==typeof e.getCurrentState)return e.getCurrentState()}broadcastUpdate(e,t){this.channel&&this.layoutKey&&this.channel.postMessage("popout-update",{layoutKey:this.layoutKey,geometry:e,state:t})}openPopout(e,t,o){return(0,r.sH)(this,void 0,void 0,function*(){const r=new URL(window.location.toString()),i=new URLSearchParams;i.append(Ht,e),r.search=i.toString();let a="popup";const n=null==t?void 0:t.geometry;let s=null==n?void 0:n.screenX,l=null==n?void 0:n.screenY;if((null==n?void 0:n.screenId)&&"getScreenDetails"in window)try{const e=(yield window.getScreenDetails()).screens.find(e=>e.label===n.screenId);if(e){s>=e.availLeft&&s<e.availLeft+e.availWidth&&l>=e.availTop&&l<e.availTop+e.availHeight||(s=e.availLeft,l=e.availTop)}else s=void 0,l=void 0}catch(e){}n?(a+=`,width=${n.outerWidth},height=${n.outerHeight}`,void 0!==s&&(a+=`,left=${s}`),void 0!==l&&(a+=`,top=${l}`)):a+=",width=800,height=600";const d=window.open(r,`popout-${e}-${(null==o?void 0:o.createId())||Date.now()}`,a);return d?(this.popoutRegistry.set(e,{geometry:n||{},state:null==t?void 0:t.state,window:d}),d):(console.warn(`Popout window for ${e} was blocked.`),null)})}getRegistry(){const e={};for(const[t,o]of this.popoutRegistry.entries())e[t]={geometry:o.geometry,state:o.state};return e}restorePopouts(e,t){return(0,r.sH)(this,void 0,void 0,function*(){this.closeAllPopouts();for(const[t,o]of Object.entries(e))this.popoutRegistry.set(t,{geometry:o.geometry,state:o.state});const o=Array.from(this.popoutRegistry.keys());0!==o.length&&(yield Promise.all(o.map(e=>{const o=this.popoutRegistry.get(e);return this.openPopout(e,o,t)})))})}closeAllPopouts(){for(const e of this.popoutRegistry.values())e.window&&!e.window.closed&&e.window.close();this.popoutRegistry.clear()}};var Ro,_o;(0,r.Cg)([(0,d.attr)({attribute:"channel-name"})],To.prototype,"channelName",void 0),(0,r.Cg)([d.observable],To.prototype,"parentLayout",void 0),To=(0,r.Cg)([(0,d.customElement)({name:"foundation-layout-popout-controller",template:null,styles:null})],To);let Do=!1;const No={area:"right",multiple:{type:"tabs",size:"33%"}};class Po extends c.FoundationElement{constructor(){super(),this.layoutConfig={root:void 0},this.defaultLayoutConfig={root:void 0},this[_o]="root",this.reloadBuffer=500,this.reloadPending=!1,this.registeredComponents=0,this.missingItemPlaceholder=e=>`"${e}" cannot be loaded as it isn't registered with the layout system`,this.hasFirstLoaded=!1,this.usingDeclerativeAPI=!1,this.customButtons=[],this.dragging=!1,this.class="FoundationLayoutMain",this.lifecycleUpdateToken=void 0,this.popupMode=!1,this.popoutConfig=void 0,Ro.set(this,void 0),this.customTokensMap=(0,le.designTokensMap)(),this.onDragStart=this.onDragStart.bind(this),this.onDragStop=this.onDragStop.bind(this),this.cacheAndSaveLayout=this.cacheAndSaveLayout.bind(this),this.onPostItemRemoved=this.onPostItemRemoved.bind(this),this.onPreItemRemoved=this.onPreItemRemoved.bind(this),this.onAutosaveRequest=this.onAutosaveRequest.bind(this),this.onPreItemMaximised=this.onPreItemMaximised.bind(this),this.onPreItemMinimised=this.onPreItemMinimised.bind(this)}connectedCallback(){super.connectedCallback(),oo.debug("FoundationLayout connected to the DOM"),this.updateLifecycleToken(),this.layout=new bo.C(this.layoutElement),this.layout.resizeWithContainerAutomatically=!0,Do||((new CSSStyleSheet).replace(ko).then(e=>document.adoptedStyleSheets.push(e)).catch(e=>oo.error("Failed to replace styles:",e)),Do=!0),this.shadowRoot.addEventListener("dragStart",this.onDragStart,!0),this.shadowRoot.addEventListener("dragStop",this.onDragStop,!0),this.shadowRoot.addEventListener("closeButtonPre",this.onPreItemRemoved,!0),this.shadowRoot.addEventListener("closeButtonPressed",this.onPostItemRemoved,!0),this.shadowRoot.addEventListener("maximised",this.onPreItemMaximised,!0),this.shadowRoot.addEventListener("minimised",this.onPreItemMinimised,!0),this.shadowRoot.addEventListener(to,this.onAutosaveRequest,!0),this.initPopoutModeIfEnabled(),this.setupCustomButtons()}disconnectedCallback(){this.shadowRoot.removeEventListener("dragStart",this.onDragStart),this.shadowRoot.removeEventListener("dragStop",this.onDragStop),this.shadowRoot.removeEventListener("closeButtonPre",this.onPreItemRemoved),this.shadowRoot.removeEventListener("closeButtonPressed",this.onPostItemRemoved),this.shadowRoot.removeEventListener("maximised",this.onPreItemMaximised),this.shadowRoot.removeEventListener("minimised",this.onPreItemMinimised),this.shadowRoot.addEventListener(to,this.onAutosaveRequest)}onDragStart(){this.dragging=!0}onDragStop(){this.dragging=!1,this.cacheAndSaveLayout(),this.attatchResizeEvents()}onPostItemAdded(){this.$emit(Xt),this.cacheAndSaveLayout()}onPreItemRemoved(){this.updateLifecycleToken()}onPostItemRemoved(){this.$emit(Jt),this.cacheAndSaveLayout()}onPostItemResized(){this.$emit(Qt),this.cacheAndSaveLayout()}onAutosaveRequest(){this.cacheAndSaveLayout()}onPreItemMaximised(){this.updateLifecycleToken()}onPreItemMinimised(){this.updateLifecycleToken()}customTokensMapChanged(){this.customTokensMap.value&&this.hasFirstLoaded&&this.loadGLConfigAndSetup(this.layoutConfig)}static layoutRequiredRegistrations(e){const{c:t}=e,o=yo.bP.fromResolved(fo.nh.unminifyConfig(t)),r=[];return JSON.stringify(o,(e,t)=>("componentType"===e&&r.push(t),t)),r.sort()}registeredItems(){return this.layout.getRegisteredComponentTypeNames()}getLayout(){var e,t;return this.getLayoutComponents().forEach(e=>{if(!e.length)return;const t=[...e].map(e=>{var t;return null===(t=e.getCurrentState)||void 0===t?void 0:t.call(e)}),o=e[0][Ut];o?o.container.setState({instance:o.instance,orderedStates:t}):oo.warn("Component instance container not found for items:",e)}),{v:"1",c:fo.nh.minifyConfig(this.layout.saveLayout()),popouts:null!==(t=null===(e=this.popoutController)||void 0===e?void 0:e.getRegistry())&&void 0!==t?t:{}}}tryActivatePopoutMode(){if(!this.popupMode)return!1;const e={root:{type:"component",componentType:new URLSearchParams(window.location.search).get(Ht),isClosable:!1},settings:{hasHeaders:!1}};this.loadGLConfigAndSetup(e);const t=e=>{if(e.classList.contains("f-layout-popout"))return e;if(null===e.parentElement){const o=e.getRootNode().host;return o?t(o):null}return t(e.parentElement)},o=t(this);if(o){o.appendChild(this);let e=this.previousElementSibling;for(;e;)e.remove(),e=this.previousElementSibling}return this.autoSaveKey=void 0,!0}tryLoadLayoutFromLocalStorage(){if(!this.autoSaveKey||this.popupMode)return!1;const e=JSON.parse(this.session.getLocalStorageItem(Bt)||"{}");if(!(this.autoSaveKey in e))return!1;const t=JSON.parse(e[this.autoSaveKey]);return this.loadLayout(t,"placeholder",!0),!0}clearAutosaveAndRevertToDefault(){if(!this.autoSaveKey||this.popupMode)return!1;const e=JSON.parse(this.session.getLocalStorageItem(Bt)||"{}");return this.autoSaveKey in e&&(delete e[this.autoSaveKey],this.session.setLocalStorageItem(Bt,JSON.stringify(e))),!!this.defaultLayoutConfig.root&&(this.updateLifecycleToken(),this.layoutConfig=JSON.parse(JSON.stringify(this.defaultLayoutConfig)),this.loadGLConfigAndSetup(this.layoutConfig),this.cacheAndSaveLayout(),!0)}loadLayout(e,t="error",o=!1){var r;const i=this.registeredItems(),a=Po.layoutRequiredRegistrations(e),n=(s=i,a.filter(e=>!s.includes(e)));var s;if(0!==n.length&&"error"===t)throw new Wt(`Trying to load layout with extra components. The component(s) not currently loaded are "${[...new Set(n)]}"`);const l=yo.bP.fromResolved(fo.nh.unminifyConfig(e.c));o&&this.removeConfigCacheInformation(l),!this.popupMode&&this.popoutController&&this.popoutController.restorePopouts(null!==(r=e.popouts)&&void 0!==r?r:{},this.uuid),0!==n.length&&"placeholder"===t&&this.registerPlaceholdersAndSetClosable(l,n),this.loadGLConfigAndSetup(l);this.getLayoutComponents().forEach(e=>{if(!e.length)return;const t=e[0][Ut].container.getState().orderedStates;t&&[...e].map((e,o)=>{var r,i;return null===(r=e.applyState)||void 0===r?void 0:r.call(e,null!==(i=t[o])&&void 0!==i?i:null)})}),this.cacheAndSaveLayout()}addItem(e,t=No){var o,r,i;if("area"in t&&"100%"===(null===(o=t.multiple)||void 0===o?void 0:o.size))throw new Wt("Adding an item taking up 100% size is not defined behaviour. The size attribute is a relative size of the item inside its layout stack. If you’re trying to set an initial layout with a single item, you can omit the size attribute as implicitly it takes up the full layout. If you already have layout items and you’re trying to add a new one that takes up the entire layout then you need to delete all of the other items and add this item only.");const a=Array.isArray(e)?e:[e],n=1===a.length,s=a.map(e=>{const{registration:t,title:o,size:r,closable:i,showMaximiseButton:a}=e;if(!this.layout.getRegisteredComponentTypeNames().includes(t))throw new Zt(`Cannot add item '${t}' which is not registered with the layout system.`);return{type:"component",componentType:t,title:null!=o?o:`Item ${t}`,reorderEnabled:!0,isClosable:i||!1,size:n?void 0:r,header:{maximise:!1!==a&&"maximise"}}});if(this.updateLifecycleToken(),"nearRegistration"in t){if(!n)throw new Wt("nearRegistration placement only supports adding a single item at a time. Pass one RegisteredElementConfig, not an array.");if(void 0===this.layoutConfig.root)return this.layoutConfig={root:{type:"stack",content:s}},this.loadGLConfigAndSetup(this.layoutConfig),void this.onPostItemAdded();const e=(Array.isArray(t.nearRegistration)?t.nearRegistration:[t.nearRegistration]).map(e=>({typeId:9,componentType:e}));return void 0!==this.layout.addItemAtLocation(s[0],e)?(this.cacheAndSaveLayout(),void this.onPostItemAdded()):(this.layoutConfig={root:{type:"row",content:[this.layoutConfig.root,{type:"stack",content:s}]}},this.loadGLConfigAndSetup(this.layoutConfig),void this.onPostItemAdded())}const l={type:no((null===(r=t.multiple)||void 0===r?void 0:r.type)||"tabs"),content:s,size:n?a[0].size:null===(i=t.multiple)||void 0===i?void 0:i.size};if(void 0===this.layoutConfig.root)return this.layoutConfig={root:l},this.loadGLConfigAndSetup(this.layoutConfig),void this.onPostItemAdded();this.cacheAndSaveLayout();const{area:d}=t;this.layoutConfig={root:{type:"top"===d||"bottom"===d?"column":"row",content:"right"===d||"bottom"===d?[this.layoutConfig.root,l]:[l,this.layoutConfig.root]}},this.loadGLConfigAndSetup(this.layoutConfig),this.onPostItemAdded()}removeItems(e,t=!1){let o=0;const r=r=>{var i;return!(0===(null===(i=r.content)||void 0===i?void 0:i.length)||"component"===r.type&&r.componentType===e&&(e=>t||e.isClosable)(r)&&(o+=1,1))},i=(e=>{var t,o;const i=e=>{var t,o;"component"!==e.type&&(null===(t=e.content)||void 0===t||t.forEach(i),e.content=null===(o=e.content)||void 0===o?void 0:o.filter(r),"stack"===e.type&&delete e.activeItemIndex)};return null===(t=null==e?void 0:e.content)||void 0===t||t.forEach(i),"stack"===e.type&&delete e.activeItemIndex,null===(o=null==e?void 0:e.content)||void 0===o?void 0:o.filter(r)})(this.layoutConfig.root);return 0===o?0:(this.layoutConfig=Object.assign(Object.assign({},this.layoutConfig),{root:i.length>0?Object.assign(Object.assign({},this.layoutConfig.root),{content:i}):void 0}),this.updateLifecycleToken(),this.loadGLConfigAndSetup(this.layoutConfig),this.onPostItemRemoved(),o)}registerItem(e,t){if(!this.layout.isInitialised)throw new Wt("Cannot add item via JS API until initialised");if(io(e))throw new Zt(`Registration "${e}" already has a factory registered via registerFactory(). Cannot register the same name via the JavaScript API. Use a different registration name or unregister the factory first.`);return"function"==typeof t?this.cacheElementsAndRegister({factory:t,id:e}):this.cacheElementsAndRegister({elements:t,id:e})}updateLifecycleToken(){this.lifecycleUpdateToken=this.uuid.createId()}requestLayoutReload(){this.reloadPending||(this.reloadPending=!0,setTimeout(()=>{var e;if(this.reloadPending=!1,this.hasFirstLoaded)this.loadGLConfigAndSetup(this.layoutConfig);else{this.hasFirstLoaded=!0,this.defaultLayoutConfig=JSON.parse(JSON.stringify(this.layoutConfig));this.tryLoadLayoutFromLocalStorage()||!1!==(null===(e=this.popoutConfig)||void 0===e?void 0:e.loadAutomatically)&&this.tryActivatePopoutMode()||this.loadGLConfigAndSetup(this.layoutConfig),this.$emit(qt)}},this.reloadBuffer))}addItemFromChild(e){if(void 0!==this.layoutConfig.root)throw new Wt("Cannot have multiple layout items as direct descendants of the layout root. You need to put the layout items within a layout region.");return this.usingDeclerativeAPI=!0,this.layoutConfig={root:e},this.layoutConfig.root}cacheElementsAndRegister(e){const t=e.id||`${this.registeredComponents+=1}`;if(this.layout.getRegisteredComponentTypeNames().includes(t))throw new Zt(`Cannot register item with already registered name: '${t}'`);const o=(()=>{if("factory"in e){const o=new Map,r=new Map,i=new Map;return(a,n)=>{var s;(null==n?void 0:n.instance)||(n.instance=this.uuid.createId()),a.state.instance=n.instance,a.state.originalTitle=null!==(s=n.originalTitle)&&void 0!==s?s:a.title;const l={container:a,instance:n.instance,registration:t},d=n.instance,c=i.get(d);if(c&&c!==a){oo.debug(`Recreating instance ${d} for registration ${t} due to container change`);const e=r.get(d);if(e&&"function"==typeof e)try{e()}catch(e){oo.error(`Error calling cleanup for instance ${d}:`,e)}o.delete(d),r.delete(d)}if(!o.has(d)){const t=document.createElement("div");t.style.width="100%",t.style.height="100%",t[Ut]=l;const i=e.factory(t);o.set(d,t),i&&r.set(d,i)}const p=o.get(d);p?(p[Ut]=l,a.element.appendChild(p),i.set(d,a),this.setupLayoutReceiveEvents(a,n)):oo.error(`Failed to get component container for instance ${d}`)}}{const o=document.createDocumentFragment();o[a.a]=!0,e.elements.forEach(e=>o.appendChild(e));const r=new Map;return(e,i)=>{var a;if((null==i?void 0:i.instance)||(i.instance=this.uuid.createId()),e.state.instance=i.instance,e.state.originalTitle=null!==(a=i.originalTitle)&&void 0!==a?a:e.title,!r.has(null==i?void 0:i.instance)){const e=document.createDocumentFragment();Array.from(o.children).forEach(t=>{e.appendChild(t.cloneNode(!0))}),r.set(i.instance,[...e.children])}const n={container:e,instance:i.instance,registration:t};r.get(i.instance).forEach(t=>{e.element.appendChild(t),t[Ut]=n}),this.setupLayoutReceiveEvents(e,i)}}})();return this.layout.registerComponentFactoryFunction(t,o),t}setupLayoutReceiveEvents(e,t){const o=e.state.originalTitle;e.element.addEventListener(eo,t=>{const r=null==t?void 0:t.detail;(null==r?void 0:r.title)&&(null==r?void 0:r.mode)||oo.error("Invalid change-title event.detail:",null==t?void 0:t.detail),e.setTitle(`${"suffix"===r.mode?o+" ":""}${r.title}`)})}cacheAndSaveLayout(){if(this.layoutConfig=yo.bP.fromResolved(this.layout.saveLayout()),this.autoSaveKey){const e=JSON.parse(this.session.getLocalStorageItem(Bt)||"{}");e[this.autoSaveKey]=JSON.stringify(this.getLayout()),this.session.setLocalStorageItem(Bt,JSON.stringify(e))}this.$emit(Kt)}registerPlaceholdersAndSetClosable(e,t){const o=document.createElement("p");o.style.textAlign="center",o.style.position="relative",o.style.top="50%";const r=e=>{var i;if("component"===e.type&&t.includes(e.componentType.toString())){const t=e.componentType.toString();e.isClosable=!0;const r=o.cloneNode();r.textContent=this.missingItemPlaceholder(t),this.registerItem(t,[r])}null===(i=e.content)||void 0===i||i.forEach(r)};r(e.root)}loadGLConfigAndSetup(e){const t={dimensions:{headerHeight:parseInt(Gt().replace("px","")),borderWidth:12,itemBorder:Vt()},header:{maximise:"maximise",minimise:"minimise",popout:!1}};this.hasFirstLoaded=!0;try{this.layout.loadLayout(Object.assign(Object.assign(Object.assign({},e),t),{dimensions:Object.assign(Object.assign({},t.dimensions),this.dimensionsConfig)}))}catch(e){this.handleGLRunErrors(e)}this.attatchResizeEvents()}handleGLRunErrors(e){if(e.message.includes("ROCCAS6692"))throw new Wt('Golden layout internal error ROCCAS6692. A maths error has accoured while calculating the layout item sizes. Verify you have not added an item with "size: 100%".');throw e}attatchResizeEvents(){void 0===(0,r.gn)(this,Ro,"f")&&(0,r.GG)(this,Ro,()=>this.onPostItemResized.bind(this)(),"f"),this.shadowRoot.querySelectorAll("div.lm_drag_handle").forEach(e=>{e.removeEventListener("click",(0,r.gn)(this,Ro,"f")),e.addEventListener("click",(0,r.gn)(this,Ro,"f"))})}setupCustomButtons(){this.layout.on("stackCreated",e=>{var t;const o=e.target.header.controlsContainerElement;null===(t=this.customButtons)||void 0===t||t.forEach(t=>{const r=document.createElement("div");r.classList.add("lm_custom_button"),r.style["background-image"]=`url('${t.svg}')`,r.addEventListener("click",()=>t.onClick(r,e.target.getActiveContentItem().container.element)),o.prepend(r)})})}getLayoutComponents(){return[...this.shadowRoot.querySelectorAll("div.lm_content")].map(e=>[...e.children])}removeConfigCacheInformation(e){const t=e=>{var o;null===(o=e.content)||void 0===o||o.forEach(e=>t(e)),"component"===e.type&&delete e.componentState.instance};return t(e.root),e}initPopoutModeIfEnabled(){if(!this.popoutConfig)return;oo.warn("Layout pop-out mode is enabled, this is an experimental feature and may change in future versions");const e=Object.assign(Object.assign({},this.popoutConfig),{loadAutomatically:!0,popoutDimension:Object.assign(Object.assign({},this.popoutConfig.popoutDimension),{width:960,height:720})});this.customButtons.push({svg:Io,onClick:(t,o)=>{var r,i;const a=o.firstChild[Ut].registration,n=o.firstChild,s=null===(r=null==n?void 0:n.getCurrentState)||void 0===r?void 0:r.call(n),l={screenX:void 0,screenY:void 0,outerWidth:e.popoutDimension.width,outerHeight:e.popoutDimension.height};null===(i=this.popoutController)||void 0===i||i.openPopout(a,{geometry:l,state:s},this.uuid),this.cacheAndSaveLayout()}}),this.popupMode=window.location.search.includes(Ht)}}Ro=new WeakMap,_o=jt,(0,r.Cg)([(0,d.attr)({attribute:"reload-buffer"})],Po.prototype,"reloadBuffer",void 0),(0,r.Cg)([wo.k],Po.prototype,"uuid",void 0),(0,r.Cg)([$o.N],Po.prototype,"session",void 0),(0,r.Cg)([(0,d.attr)({attribute:"auto-save-key"})],Po.prototype,"autoSaveKey",void 0),(0,r.Cg)([d.observable],Po.prototype,"missingItemPlaceholder",void 0),(0,r.Cg)([d.observable],Po.prototype,"hasFirstLoaded",void 0),(0,r.Cg)([d.observable],Po.prototype,"usingDeclerativeAPI",void 0),(0,r.Cg)([d.observable],Po.prototype,"dragging",void 0),(0,r.Cg)([d.observable],Po.prototype,"popupMode",void 0),(0,r.Cg)([d.observable],Po.prototype,"popoutConfig",void 0),(0,r.Cg)([d.observable],Po.prototype,"customTokensMap",void 0);const zo=d.html`
2103
+ <div class="html-spinner"></div>
2104
+ `,Oo=d.html`
2105
+ <template>
2106
+ ${(0,d.when)(e=>Boolean(e.popoutConfig),d.html`
2107
+ <foundation-layout-popout-controller
2108
+ ${(0,d.ref)("popoutController")}
2109
+ :parentLayout="${e=>e}"
2110
+ channel-name="${e=>{var t;return null===(t=e.popoutConfig)||void 0===t?void 0:t.channelName}}"
2111
+ ></foundation-layout-popout-controller>
2112
+ `)}
2113
+ ${(0,d.when)(e=>!e.hasFirstLoaded&&e.usingDeclerativeAPI,zo)}
2114
+ <div class="layout-container" ${(0,d.ref)("layoutElement")}></div>
2115
+ </template>
2116
+ `,Fo={foundationLayout:Po.compose({baseName:"layout",styles:Lo,template:Oo}),foundationLayoutRegion:go,foundationLayoutItem:uo,register(e,...t){if(e)for(const o in this)"register"!==o&&this[o]().register(e,...t)}};var jo,Uo=o(93188),Bo=o(4852);!function(e){e.STYLES_CHANGED="styles-changed",e.DS_CHANGED="design-system-changed",e.APPLY_CUSTOM_DESIGN="apply-custom-design"}(jo||(jo={}));const Ho={Roboto:Uo.robotoFontFamily,"Segoe UI":'"Segoe UI", Arial, Helvetica, sans-serif',Monospace:'Consolas, "Andale Mono WT", "Andale Mono", "Lucida Console", "Lucida Sans Typewriter", "DejaVu Sans Mono", "Bitstream Vera Sans Mono", "Liberation Mono", "Nimbus Mono L", Monaco, "Courier New", Courier, monospace',"Times New Roman":'Cambria, "Hoefler Text", Utopia, "Liberation Serif", "Nimbus Roman No9 L Regular", Times, "Times New Roman", serif',Garamond:'"Palatino Linotype", Palatino, Palladio, "URW Palladio L", "Book Antiqua", Baskerville, "Bookman Old Style", "Bitstream Charter", "Nimbus Roman No9 L", Garamond, "Apple Garamond", "ITC Garamond Narrow", "New Century Schoolbook", "Century Schoolbook", "Century Schoolbook L", Georgia, serif',Georgia:'Constantia, "Lucida Bright", Lucidabright, "Lucida Serif", Lucida, "DejaVu Serif", "Bitstream Vera Serif", "Liberation Serif", Georgia, serif',Helvetica:'Frutiger, "Frutiger Linotype", Univers, Calibri, "Gill Sans", "Gill Sans MT", "Myriad Pro", Myriad, "DejaVu Sans Condensed", "Liberation Sans", "Nimbus Sans L", Tahoma, Geneva, "Helvetica Neue", Helvetica, Arial, sans-serif',Verdana:'Candara, "Bitstream Vera Sans", "DejaVu Sans", "Bitstream Vera Sans", "Trebuchet MS", Verdana, "Verdana Ref", sans-serif'},Yo=Ho["Segoe UI"],Go=d.css`
2117
+ ${(0,c.display)("block")} :host {
2118
+ width: 100%;
2119
+ display: inline-flex;
2120
+ font-family: Roboto, 'Segoe UI', Arial, Helvetica, sans-serif;
2121
+ font-style: normal;
2122
+ font-weight: 400;
2123
+ }
2124
+
2125
+ .configuration {
2126
+ background: #333;
2127
+ color: #fafafa;
2128
+ width: 300px;
2129
+ flex: none;
2130
+ padding: 15px;
2131
+ font-size: 12px;
2132
+ }
2133
+
2134
+ input {
2135
+ font-size: 12px;
2136
+ }
2137
+
2138
+ .configuration .row {
2139
+ display: flex;
2140
+ min-height: 45px;
2141
+ justify-content: center;
2142
+ align-items: center;
2143
+ }
2144
+
2145
+ #bodyfont {
2146
+ align-items: center;
2147
+ margin-bottom: 8px;
2148
+ margin-top: 10px;
2149
+ }
2150
+
2151
+ #color {
2152
+ align-items: center;
2153
+ }
2154
+
2155
+ #darkmode {
2156
+ align-items: center;
2157
+ margin-bottom: 10px;
2158
+ }
2159
+
2160
+ .configuration .label {
2161
+ width: 100px;
2162
+ flex: none;
2163
+ padding-right: 10px;
2164
+ }
2165
+
2166
+ .configuration .input {
2167
+ flex: auto;
2168
+ }
2169
+
2170
+ .color-input-row {
2171
+ display: flex;
2172
+ flex-direction: row;
2173
+ }
2174
+
2175
+ input[type='color'] {
2176
+ border: none;
2177
+ padding: 0;
2178
+ margin-right: 8px;
2179
+ background: none;
2180
+ width: 30px;
2181
+ height: 30px;
2182
+ }
2183
+
2184
+ .preview {
2185
+ flex: auto;
2186
+ background: var(--fill-color);
2187
+ color: var(--neutral-foreground-rest);
2188
+ height: 100%;
2189
+ overflow: auto;
2190
+ }
2191
+
2192
+ rapid-select {
2193
+ min-width: 190px;
2194
+ }
2195
+
2196
+ rapid-combobox {
2197
+ min-width: 100px;
2198
+ }
2199
+
2200
+ rapid-slider-label {
2201
+ font-size: 10px;
2202
+ }
2203
+
2204
+ rapid-slider {
2205
+ margin-top: 12px;
2206
+ }
2207
+
2208
+ rapid-slider::part(thumb-container) {
2209
+ border: 1px solid var(--neutral-stroke-hover);
2210
+ border-radius: calc(var(--control-corner-radius) * 1px);
2211
+ }
2212
+
2213
+ rapid-checkbox::part(control) {
2214
+ width: 32px;
2215
+ }
2216
+
2217
+ rapid-checkbox::part(label) {
2218
+ color: #333;
2219
+ padding: 15px;
2220
+ font-size: 12px;
2221
+ font-family: Roboto, 'Segoe UI', Arial, Helvetica, sans-serif;
2222
+ }
2223
+
2224
+ .radio-button {
2225
+ height: 42px;
2226
+ padding: 0 10px;
2227
+ margin-bottom: 24px;
2228
+ }
2229
+
2230
+ .radio-button::part(label) {
2231
+ color: black;
2232
+ }
2233
+
2234
+ .footer-row {
2235
+ display: flex;
2236
+ flex-direction: row;
2237
+ justify-content: space-between;
2238
+ margin-top: 20px;
2239
+ }
2240
+
2241
+ rapid-text-field::part(root) {
2242
+ height: 30px;
2243
+ }
2244
+
2245
+ rapid-button {
2246
+ margin: 0;
2247
+ }
2248
+ `,Vo=d.html`
2249
+ <template>
2250
+ <div class="configuration">
2251
+ ${(0,d.when)(e=>!e.customDesignMode,d.html`
2252
+ <div class="row" id="designSystem">
2253
+ <div class="label">
2254
+ <label for="body-font">Design System</label>
2255
+ </div>
2256
+ <div class="input">
2257
+ <rapid-select
2258
+ name="ds"
2259
+ @change="${(e,t)=>e.changeHandler(t.event)}"
2260
+ >
2261
+ ${(0,d.repeat)(e=>e.designSystems,d.html`
2262
+ <rapid-option value="${e=>e.value}">${e=>e.name}</rapid-option>
2263
+ `)}
2264
+ </rapid-select>
2265
+ </div>
2266
+ </div>
2267
+ `)}
2268
+
2269
+ <div class="row" id="color">
2270
+ <div class="label">
2271
+ <label for="accent-color-pickers">Accent color</label>
2272
+ </div>
2273
+ <div class="color-input-row">
2274
+ <input
2275
+ name="accentColor"
2276
+ type="color"
2277
+ :value="${e=>e.accentColor}"
2278
+ @input="${(e,t)=>e.changeHandler(t.event)}"
2279
+ />
2280
+ <rapid-text-field
2281
+ name="accentColor"
2282
+ type="text"
2283
+ :value="${e=>e.accentColor}"
2284
+ @input="${(e,t)=>e.changeHandler(t.event)}"
2285
+ ></rapid-text-field>
2286
+ </div>
2287
+ </div>
2288
+
2289
+ <div class="row" id="color">
2290
+ <div class="label">
2291
+ <label for="neutral-color-pickers">Neutral color</label>
2292
+ </div>
2293
+ <div class="color-input-row">
2294
+ <input
2295
+ name="neutralColor"
2296
+ type="color"
2297
+ :value="${e=>e.neutralColor}"
2298
+ @input="${(e,t)=>e.changeHandler(t.event)}"
2299
+ />
2300
+ <rapid-text-field
2301
+ name="neutralColor"
2302
+ type="text"
2303
+ :value="${e=>e.neutralColor}"
2304
+ @input="${(e,t)=>e.changeHandler(t.event)}"
2305
+ ></rapid-text-field>
2306
+ </div>
2307
+ </div>
2308
+
2309
+ <div class="row" id="bodyfont">
2310
+ <div class="label">
2311
+ <label for="body-font">Body Font</label>
2312
+ </div>
2313
+ <div class="input">
2314
+ <rapid-combobox
2315
+ name="bodyFont"
2316
+ autocomplete="both"
2317
+ :value="${e=>e.bodyFont}"
2318
+ @change="${(e,t)=>e.changeHandler(t.event)}"
2319
+ >
2320
+ <rapid-option value="Roboto">Roboto</rapid-option>
2321
+ <rapid-option value="Segoe UI">Segoe UI</rapid-option>
2322
+ <rapid-option value="Monospace">Monospace</rapid-option>
2323
+ <rapid-option value="Times New Roman">Times New Roman</rapid-option>
2324
+ <rapid-option value="Helvetica">Helvetica</rapid-option>
2325
+ <rapid-option value="Garamond">Garamond</rapid-option>
2326
+ <rapid-option value="Georgia">Georgia</rapid-option>
2327
+ <rapid-option value="Verdana">Verdana</rapid-option>
2328
+ </rapid-combobox>
2329
+ </div>
2330
+ </div>
2331
+
2332
+ <div class="row" id="baseFontSize">
2333
+ <div class="label">
2334
+ <label for="base-font-size">Base Font Size</label>
2335
+ </div>
2336
+ <div class="input">
2337
+ <rapid-combobox
2338
+ name="baseFontSize"
2339
+ autocomplete="both"
2340
+ :value="${e=>e.baseFontSize}"
2341
+ @change="${(e,t)=>e.changeHandler(t.event)}"
2342
+ >
2343
+ <rapid-option value="8px">8px</rapid-option>
2344
+ <rapid-option value="10px">10px</rapid-option>
2345
+ <rapid-option value="12px">12px</rapid-option>
2346
+ <rapid-option value="14px">14px</rapid-option>
2347
+ <rapid-option value="16px">16px</rapid-option>
2348
+ <rapid-option value="20px">20px</rapid-option>
2349
+ <rapid-option value="24px">24px</rapid-option>
2350
+ </rapid-combobox>
2351
+ </div>
2352
+ </div>
2353
+
2354
+ <div class="row" id="baseLineHeight">
2355
+ <div class="label">
2356
+ <label for="base-line-height">Base Line Height</label>
2357
+ </div>
2358
+ <div class="input">
2359
+ <rapid-combobox
2360
+ name="baseLineHeight"
2361
+ autocomplete="both"
2362
+ :value="${e=>e.baseLineHeight}"
2363
+ @change="${(e,t)=>e.changeHandler(t.event)}"
2364
+ >
2365
+ <rapid-option value="12px">12px</rapid-option>
2366
+ <rapid-option value="14px">14px</rapid-option>
2367
+ <rapid-option value="16px">16px</rapid-option>
2368
+ <rapid-option value="20px">20px</rapid-option>
2369
+ <rapid-option value="24px">24px</rapid-option>
2370
+ <rapid-option value="28px">28px</rapid-option>
2371
+ </rapid-combobox>
2372
+ </div>
2373
+ </div>
2374
+
2375
+ <div class="row" id="darkmode">
2376
+ <div class="label">
2377
+ <label for="dark-mode-switch">Dark mode</label>
2378
+ </div>
2379
+ <div class="input">
2380
+ <rapid-switch
2381
+ name="darkMode"
2382
+ :checked="${e=>e.darkMode}"
2383
+ @change="${(e,t)=>e.modeChangeHandler(t.event)}
2384
+ "
2385
+ >
2386
+ <span slot="checked-message">On</span>
2387
+ <span slot="unchecked-message">Off</span>
2388
+ </rapid-switch>
2389
+ </div>
2390
+ </div>
2391
+
2392
+ <div class="row">
2393
+ <div class="label">
2394
+ <label for="density-slider">Density</label>
2395
+ </div>
2396
+ <div class="input">
2397
+ <rapid-slider
2398
+ name="density"
2399
+ min="-3"
2400
+ max="3"
2401
+ step="1"
2402
+ :value="${e=>e.density}"
2403
+ @change="${(e,t)=>e.changeHandler(t.event)}"
2404
+ ></rapid-slider>
2405
+ </div>
2406
+ </div>
2407
+
2408
+ <div class="row">
2409
+ <div class="label">
2410
+ <label for="design-unit-slider">Design Unit</label>
2411
+ </div>
2412
+ <div class="input">
2413
+ <rapid-slider
2414
+ name="designUnit"
2415
+ min="1"
2416
+ max="10"
2417
+ step="1"
2418
+ :value="${e=>e.designUnit}"
2419
+ @change="${(e,t)=>e.changeHandler(t.event)}"
2420
+ ></rapid-slider>
2421
+ </div>
2422
+ </div>
2423
+
2424
+ <div class="row">
2425
+ <div class="label">
2426
+ <label for="border-radius-slider">Border radius</label>
2427
+ </div>
2428
+ <div class="input">
2429
+ <rapid-slider
2430
+ name="borderRadius"
2431
+ min="0"
2432
+ max="20"
2433
+ step="1"
2434
+ :value="${e=>e.borderRadius}"
2435
+ @change="${(e,t)=>e.changeHandler(t.event)}"
2436
+ ></rapid-slider>
2437
+ </div>
2438
+ </div>
2439
+
2440
+ <div class="row">
2441
+ <div class="label">
2442
+ <label for="stroke-width-slider">Stroke width</label>
2443
+ </div>
2444
+ <div class="input">
2445
+ <rapid-slider
2446
+ name="strokeWidth"
2447
+ min="1"
2448
+ max="4"
2449
+ step="1"
2450
+ :value="${e=>e.strokeWidth}"
2451
+ @change="${(e,t)=>e.changeHandler(t.event)}"
2452
+ ></rapid-slider>
2453
+ </div>
2454
+ </div>
2455
+ ${(0,d.when)(e=>!e.customDesignMode,d.html`
2456
+ <rapid-checkbox :checked="${(0,M.O)(e=>e.preserveOptions,"boolean")}">
2457
+ Preserve selected options when changing design systems
2458
+ </rapid-checkbox>
2459
+ `)}
2460
+
2461
+ <div class="footer-row">
2462
+ <rapid-button appearance="accent" @click="${e=>e.resetChanges()}">Reset</rapid-button>
2463
+ <slot name="export"></slot>
2464
+ </div>
2465
+ </div>
2466
+
2467
+ <div class="preview">
2468
+ <slot></slot>
2469
+ </div>
2470
+ </template>
2471
+ `,Wo=({design_tokens:e})=>({accentColor:e.color.accent.$value,neutralColor:e.color.neutral.$value,luminance:e.mode.luminance.$value,density:e.style.density.$value,designUnit:e.space.designUnit.$value,borderRadius:e.style.borderRadius.$value,strokeWidth:e.style.strokeWidth.$value,baseHeightMultiplier:e.style.baseHeightMultiplier.$value,bodyFont:Object.keys(Ho).find(t=>Ho[t]===e.fontFamily.bodyFont.$value),baseFontSize:e.typography.baseFontSize.$value,baseLineHeight:e.typography.baseLineHeight.$value}),Zo=Wo(Uo.designTokens),qo={accent:"primary",neutral:"neutral",outline:"primary-outline",text:"link"},Xo={accent:"primary",neutral:"neutral",font:"text"},Jo={rapid:{prefix:"rapid",tokenDefaults:Zo,buttons:qo,badge:Xo},custom:{prefix:"rapid",tokenDefaults:null,buttons:qo,badge:Xo}};let Qo=class extends d.FASTElement{constructor(){super(...arguments),this.customDesignMode=!1,this.userSelections={},this.ds="rapid",this.darkMode=Zo.luminance===p.StandardLuminance.DarkMode,this.luminance=Zo.luminance,this.neutralColor=Zo.neutralColor,this.accentColor=Zo.accentColor,this.bodyFont=Zo.bodyFont,this.density=Zo.density,this.borderRadius=Zo.borderRadius,this.strokeWidth=Zo.strokeWidth,this.baseHeightMultiplier=Zo.baseHeightMultiplier,this.designUnit=Zo.designUnit,this.baseFontSize=Zo.baseFontSize,this.baseLineHeight=Zo.baseLineHeight,this.preserveOptions=!0,this.tokenUpdateInProgress=!1,this.changeHandler=e=>{if(e.target instanceof c.RadioGroup||e.target instanceof HTMLInputElement||e.target instanceof p.Combobox||e.target instanceof p.Select){const{name:t,value:o}=e.target;t&&o&&(this[t]=o,this.updateUserSelections(t,o),this.styleUpdate())}else if(e.target instanceof c.Slider){const t=parseInt(e.target.value),o=e.target.name;o&&Number.isInteger(t)&&(this[o]=t,this.updateUserSelections(o,t),this.styleUpdate())}},this.updateUserSelections=(e,t)=>{"ds"===e||this.tokenUpdateInProgress||(this.userSelections[e]=t)},this.modeChangeHandler=e=>{this.darkMode=e.target.checked,this.luminance=this.darkMode?p.StandardLuminance.DarkMode:p.StandardLuminance.LightMode,this.updateUserSelections("luminance",this.luminance),this.styleUpdate()},this.applyCustomDSTokens=e=>{const t=e.detail;t&&d.DOM.queueUpdate(()=>{const e=Wo(t);Jo.custom.tokenDefaults=e,this.setTokensFromDs(e),this.styleUpdate()})},this.resetChanges=()=>(0,r.sH)(this,void 0,void 0,function*(){this.userSelections={},this.setTokensFromDs(Jo[this.ds].tokenDefaults),this.styleUpdate()})}customDesignModeChanged(e,t){return(0,r.sH)(this,void 0,void 0,function*(){const e=[{name:"Rapid",value:"rapid"}];if(this.customDesignMode){const{appName:e="Custom Design",dsPrefix:t="custom"}=yield this.getAppDetails(),o={name:e,value:t};this.designSystems=[o],Jo.custom.prefix=t,Jo.custom.buttons=Jo[t].buttons,Jo.custom.badge=Jo[t].badge,this.ds="custom"}else this.designSystems=e})}dsChanged(e,t){const o={prefix:Jo[this.ds].prefix,buttonAppearanceAccent:Jo[this.ds].buttons.accent,buttonAppearanceNeutral:Jo[this.ds].buttons.neutral,buttonAppearanceOutline:Jo[this.ds].buttons.outline,buttonAppearanceText:Jo[this.ds].buttons.text,badgeAppearanceAccent:Jo[this.ds].badge.accent,badgeAppearanceNeutral:Jo[this.ds].badge.neutral,badgeText:Jo[this.ds].badge.font};this.$emit(jo.DS_CHANGED,o),this.preserveOptions||(this.userSelections={}),this.setTokensFromDs(Jo[this.ds].tokenDefaults),this.styleUpdate()}styleUpdate(){const e={accentColor:this.accentColor,neutralColor:this.neutralColor,bodyFont:Ho[this.bodyFont],luminance:this.luminance,density:this.density,designUnit:this.designUnit,borderRadius:this.borderRadius,strokeWidth:this.strokeWidth,baseHeightMultiplier:this.baseHeightMultiplier,baseFontSize:this.baseFontSize,baseLineHeight:this.baseLineHeight};this.$emit(jo.STYLES_CHANGED,e)}setTokensFromDs(e){this.tokenUpdateInProgress=!0,Object.keys(e).forEach(t=>{this.preserveOptions&&void 0!==this.userSelections[t]?this[t]=this.userSelections[t]:this[t]=e[t]}),this.darkMode=this.luminance===p.StandardLuminance.DarkMode,d.DOM.queueUpdate(()=>{this.tokenUpdateInProgress=!1})}getAppDetails(){return fetch("api/details").then(e=>e.ok&&e.json()).then(e=>e).catch(e=>{console.error("Error fetching tokens:",e)})}connectedCallback(){super.connectedCallback(),this.userSelections={},(0,Uo.loadRobotoFontFaces)(),d.DOM.queueUpdate(()=>{this.styleUpdate()}),document.body.addEventListener(jo.APPLY_CUSTOM_DESIGN,e=>{this.applyCustomDSTokens(e)})}};(0,r.Cg)([(0,d.attr)({mode:"boolean",attribute:"custom-design-mode"})],Qo.prototype,"customDesignMode",void 0),(0,r.Cg)([d.observable],Qo.prototype,"designSystems",void 0),(0,r.Cg)([d.observable],Qo.prototype,"ds",void 0),(0,r.Cg)([d.attr],Qo.prototype,"darkMode",void 0),(0,r.Cg)([d.observable],Qo.prototype,"neutralColor",void 0),(0,r.Cg)([d.observable],Qo.prototype,"accentColor",void 0),(0,r.Cg)([d.observable],Qo.prototype,"bodyFont",void 0),(0,r.Cg)([d.observable],Qo.prototype,"density",void 0),(0,r.Cg)([d.observable],Qo.prototype,"borderRadius",void 0),(0,r.Cg)([d.observable],Qo.prototype,"strokeWidth",void 0),(0,r.Cg)([d.observable],Qo.prototype,"baseHeightMultiplier",void 0),(0,r.Cg)([d.observable],Qo.prototype,"designUnit",void 0),(0,r.Cg)([d.observable],Qo.prototype,"baseFontSize",void 0),(0,r.Cg)([d.observable],Qo.prototype,"baseLineHeight",void 0),(0,r.Cg)([d.observable],Qo.prototype,"preserveOptions",void 0),Qo=(0,r.Cg)([(0,d.customElement)({name:"design-system-editor",template:Vo,styles:Go})],Qo);const Ko=(0,h.createLogger)("documentation-components");var er=o(80273),tr=o(83912);const or=e=>{const t=(e=>{const t=(0,tr.parseColorHexRGB)(e);return t?p.SwatchRGB.from(t):null})(e);return t?p.PaletteRGB.create(t):null},rr=(e,t,o)=>{const r=e.getValueFor(o).match(/^(\d+)([a-z]+)/i),i=r[1],a=r[2];return Number(i)+t+a},ir=(e,t)=>{const o=or(e.neutralColor);p.neutralPalette.setValueFor(t,o);const r=or(e.accentColor);p.accentPalette.setValueFor(t,r),p.baseLayerLuminance.setValueFor(t,e.luminance),p.density.setValueFor(t,e.density),p.controlCornerRadius.setValueFor(t,e.borderRadius),p.strokeWidth.setValueFor(t,e.strokeWidth),p.designUnit.setValueFor(t,e.designUnit),p.bodyFont.setValueFor(t,e.bodyFont),p.typeRampBaseFontSize.setValueFor(t,e.baseFontSize),p.typeRampBaseLineHeight.setValueFor(t,e.baseLineHeight),p.typeRampMinus1FontSize.setValueFor(t,rr(p.typeRampBaseFontSize,er.Du.minusOne,t)),p.typeRampMinus1LineHeight.setValueFor(t,rr(p.typeRampBaseLineHeight,er.Du.minusOne,t)),p.typeRampMinus2FontSize.setValueFor(t,rr(p.typeRampBaseFontSize,er.Du.minusTwo,t)),p.typeRampMinus2LineHeight.setValueFor(t,rr(p.typeRampBaseLineHeight,er.Du.minusTwo,t)),p.typeRampPlus1FontSize.setValueFor(t,rr(p.typeRampBaseFontSize,er.Du.plusOne,t)),p.typeRampPlus1LineHeight.setValueFor(t,rr(p.typeRampBaseLineHeight,er.Du.plusOne,t)),p.typeRampPlus2FontSize.setValueFor(t,rr(p.typeRampBaseFontSize,er.Du.plusTwo,t)),p.typeRampPlus2LineHeight.setValueFor(t,rr(p.typeRampBaseLineHeight,er.Du.plusTwo,t)),p.typeRampPlus3FontSize.setValueFor(t,rr(p.typeRampBaseFontSize,er.Du.plusThree,t)),p.typeRampPlus3LineHeight.setValueFor(t,rr(p.typeRampBaseLineHeight,er.Du.plusThree,t)),p.typeRampPlus4FontSize.setValueFor(t,rr(p.typeRampBaseFontSize,er.Du.plusFour,t)),p.typeRampPlus4LineHeight.setValueFor(t,rr(p.typeRampBaseLineHeight,er.Du.plusFour,t)),p.typeRampPlus5FontSize.setValueFor(t,rr(p.typeRampBaseFontSize,er.Du.plusFive,t)),p.typeRampPlus5LineHeight.setValueFor(t,rr(p.typeRampBaseLineHeight,er.Du.plusFive,t)),p.typeRampPlus6FontSize.setValueFor(t,rr(p.typeRampBaseFontSize,er.Du.plusSix,t)),p.typeRampPlus6LineHeight.setValueFor(t,rr(p.typeRampBaseLineHeight,er.Du.plusSix,t))},ar=d.css`
2472
+ :host {
2473
+ --badge-fill-primary: var(--accent-fill-rest);
2474
+ --badge-fill-neutral: var(--neutral-fill-rest);
2475
+
2476
+ background: var(--fill-color);
2477
+ color: var(--neutral-foreground-rest);
2478
+ flex-direction: column;
2479
+ flex: 1;
2480
+ }
2481
+
2482
+ .wrapper {
2483
+ background: var(--fill-color);
2484
+ display: flex;
2485
+ }
2486
+
2487
+ .column {
2488
+ flex: 1;
2489
+ padding: calc(var(--base-horizontal-spacing-multiplier) * 3px);
2490
+ }
2491
+
2492
+ .row {
2493
+ display: flex;
2494
+ }
2495
+
2496
+ .padded {
2497
+ padding: calc(var(--base-horizontal-spacing-multiplier) * 3px) 0;
2498
+ }
2499
+
2500
+ .row-padding {
2501
+ padding: 0 8px;
2502
+ }
2503
+
2504
+ rapid-button,
2505
+ rapid-flipper {
2506
+ margin-right: calc(var(--base-horizontal-spacing-multiplier) * 2px);
2507
+ }
2508
+
2509
+ rapid-progress-ring {
2510
+ margin: 0;
2511
+ }
2512
+
2513
+ rapid-accordion,
2514
+ rapid-text-field {
2515
+ width: 100%;
2516
+ }
2517
+
2518
+ rapid-design-system-provider {
2519
+ display: inline;
2520
+ }
2521
+
2522
+ rapid-card > rapid-card > rapid-card {
2523
+ background: var(--neutral-layer-1);
2524
+ }
2525
+
2526
+ .horizontal-scroll {
2527
+ width: 400px;
2528
+ padding: calc(var(--base-horizontal-spacing-multiplier) * 3px);
2529
+ }
2530
+
2531
+ .card-padding {
2532
+ padding: calc(var(--base-horizontal-spacing-multiplier) * 3px);
2533
+ }
2534
+
2535
+ .flex-row {
2536
+ display: flex;
2537
+ align-items: center;
2538
+ gap: calc(var(--base-horizontal-spacing-multiplier) * 3px);
2539
+ }
2540
+
2541
+ rapid-dialog,
2542
+ rapid-error-dialog {
2543
+ position: relative;
2544
+ z-index: 100;
2545
+ }
2546
+
2547
+ .actions-menu-container {
2548
+ display: flex;
2549
+ flex: 1;
2550
+ height: 400px;
2551
+ justify-content: center;
2552
+ }
2553
+
2554
+ .label {
2555
+ color: var(--neutral-foreground-hint);
2556
+ font-weight: 700;
2557
+ margin: calc(var(--design-unit) * 2px) 0;
2558
+ }
2559
+
2560
+ .flex-column {
2561
+ display: flex;
2562
+ flex-direction: column;
2563
+ }
2564
+ `,nr=d.html`
2565
+ ${e=>{return t=e.prefix,d.html`
2566
+ <template>
2567
+ <${t}-design-system-provider ${(0,d.ref)("provider")}>
2568
+ <div class="wrapper">
2569
+ <div class="column">
2570
+ <div class="row">
2571
+ <div class="column">
2572
+ <${t}-breadcrumb role="navigation">
2573
+ <${t}-breadcrumb-item href="#"><${t}-icon name="folder" size="md" variant="regular" slot="start"></${t}-icon></${t}-breadcrumb-item>
2574
+ <${t}-breadcrumb-item href="#">Item 1</${t}-breadcrumb-item>
2575
+ <${t}-breadcrumb-item href="#">Item 2</${t}-breadcrumb-item>
2576
+ <${t}-breadcrumb-item>Item 3</${t}-breadcrumb-item>
2577
+ </${t}-breadcrumb>
2578
+ <${t}-badge :fill="${e=>e.badgeAppearanceAccent}" color="${e=>e.badgeText}" class="row-padding">Badge</${t}-badge>
2579
+ <${t}-badge fill="${e=>e.badgeAppearanceNeutral}" color="${e=>e.badgeText}">Badge</${t}-badge>
2580
+ </div>
2581
+ <div class="column">
2582
+ <div class="flex-row">
2583
+ <${t}-button href="#" :appearance="${e=>e.buttonAppearanceAccent}">Button</${t}-button>
2584
+ <${t}-button href="#" :appearance="${e=>e.buttonAppearanceNeutral}">Button</${t}-button>
2585
+ <${t}-button href="#" :appearance="${e=>e.buttonAppearanceOutline}">Button</${t}-button>
2586
+ <${t}-button :appearance="${e=>e.buttonAppearanceAccent}">
2587
+ Button
2588
+ <${t}-icon name="edit" size="md" slot="start"></${t}-icon>
2589
+ </${t}-button>
2590
+ <${t}-flipper
2591
+ role="button"
2592
+ tabindex="-1"
2593
+ class="previous"
2594
+ aria-hidden="true"
2595
+ direction="previous"
2596
+ ></${t}-flipper>
2597
+ <${t}-flipper
2598
+ role="button"
2599
+ tabindex="-1"
2600
+ class="next"
2601
+ aria-hidden="true"
2602
+ direction="next"
2603
+ ></${t}-flipper>
2604
+ <${t}-switch
2605
+ role="switch"
2606
+ checked
2607
+ aria-checked="true"
2608
+ aria-disabled="false"
2609
+ tabindex="0"
2610
+ ></${t}-switch>
2611
+ </div>
2612
+
2613
+ </div>
2614
+ </div>
2615
+
2616
+ <div class="row">
2617
+ <div class="column">
2618
+ <div class="flex-row">
2619
+ <${t}-radio-group role="radiogroup" orientation="horizontal">
2620
+ <${t}-radio
2621
+ checked
2622
+ role="radio"
2623
+ aria-checked="true"
2624
+ aria-required="false"
2625
+ aria-disabled="false"
2626
+ tabindex="0"
2627
+ >
2628
+ Radio 1
2629
+ </${t}-radio>
2630
+ <${t}-radio
2631
+ role="radio"
2632
+ aria-checked="false"
2633
+ aria-required="false"
2634
+ aria-disabled="false"
2635
+ tabindex="-1"
2636
+ >
2637
+ Radio 2
2638
+ </${t}-radio>
2639
+ </${t}-radio-group>
2640
+ <${t}-checkbox
2641
+ role="checkbox"
2642
+ checked
2643
+ aria-checked="true"
2644
+ aria-required="false"
2645
+ aria-disabled="false"
2646
+ tabindex="0"
2647
+ >
2648
+ Checkbox
2649
+ </${t}-checkbox>
2650
+ <${t}-checkbox
2651
+ role="checkbox"
2652
+ aria-checked="false"
2653
+ aria-required="false"
2654
+ aria-disabled="false"
2655
+ tabindex="0"
2656
+ >
2657
+ Checkbox
2658
+ </${t}-checkbox>
2659
+ </div>
2660
+ </div>
2661
+ <div class="column">
2662
+ <${t}-disclosure appearance="accent" title="Open Disclosure">
2663
+ <div>Created by writer Gardner Fox and artist Harry Lampert, the original Flashfirst appeared
2664
+ in Flash Comics #1 (cover date January 1940/release monthNovember 1939). Nicknamed the
2665
+ "Scarlet Speedster", all incarnations of theFlash possess "super speed", which includes
2666
+ the ability to run, move, andthink extremely fast, use superhuman reflexes, and seemingly
2667
+ violatecertain laws of physics.</div>
2668
+ </${t}-disclosure>
2669
+ </div>
2670
+ </div>
2671
+
2672
+ <div class="row">
2673
+ <div class="column">
2674
+ <div class="flex-row">
2675
+ <div class="flex-column">
2676
+ <div class="label"> ComboBox</div>
2677
+ <${t}-combobox autocomplete="both">
2678
+ <${t}-option>Christopher Eccleston</${t}-option>
2679
+ <${t}-option>David Tenant</${t}-option>
2680
+ <${t}-option>Matt Smith</${t}-option>
2681
+ <${t}-option>Peter Capaldi</${t}-option>
2682
+ <${t}-option>Jodie Whittaker</${t}-option>
2683
+ </${t}-combobox>
2684
+ </div>
2685
+ <div class="flex-column">
2686
+ <div class="label"> Select</div>
2687
+ <${t}-select>
2688
+ <${t}-option>Christopher Eccleston</${t}-option>
2689
+ <${t}-option>David Tenant</${t}-option>
2690
+ <${t}-option>Matt Smith</${t}-option>
2691
+ <${t}-option>Peter Capaldi</${t}-option>
2692
+ <${t}-option>Jodie Whittaker</${t}-option>
2693
+ </${t}-select>
2694
+ </div>
2695
+ </div>
2696
+ </div>
2697
+ <div class="column">
2698
+ <${t}-segmented-control appearance="primary">
2699
+ <label slot="label">Primary Segment Control (label slot)</label>
2700
+ <${t}-segmented-item>Segmented Item</${t}-segmented-item>
2701
+ <${t}-segmented-item>Segmented Item</${t}-segmented-item>
2702
+ <${t}-segmented-item>Segmented Item</${t}-segmented-item>
2703
+ </${t}-segmented-control>
2704
+ </div>
2705
+ </div>
2706
+
2707
+
2708
+ <div class="row">
2709
+ <div class="column">
2710
+ <div class="row">
2711
+ <${t}-text-field
2712
+ placeholder="Text field"
2713
+ aria-label="Example text field"
2714
+ type="text"
2715
+ >
2716
+ Text Field Label
2717
+ </${t}-text-field>
2718
+ <${t}-number-field class="row-padding" placeholder="number" withFormatting>Number Field</${t}-number-field>
2719
+ <${t}-date-picker class="row-padding" label="Date Picker" value="01-01-2023"></${t}-date-picker>
2720
+ </div>
2721
+ </div>
2722
+ <div class="column">
2723
+ <div class="flex-row">
2724
+ <${t}-button appearance="${e=>e.buttonAppearanceAccent}" @click="${e=>e.showDialog("modal")}">Show Modal</${t}-button>
2725
+ <${t}-button appearance="${e=>e.buttonAppearanceAccent}" @click="${e=>e.showDialog("dialog")}">Show Dialog</${t}-button>
2726
+ <${t}-multiselect class="row-padding" name="Countries" :options="${e=>e.countries}" search=true>
2727
+ </${t}-multiselect>
2728
+ <${t}-modal ${(0,d.ref)("modal")} style="--dialog-max-width:557px;">
2729
+ <h5 slot="top">Modal Title</h5>
2730
+ <p>
2731
+ Lorem ipsum dolor sit amet consectetur adipisicing elit. Quis similique iste ab sed
2732
+ voluptatem ut suscipit tenetur distinctio? Quo est debitis pariatur qui quisquam
2733
+ repudiandae at atque et quibusdam rerum, reprehenderit sed laborum officiis
2734
+ distinctio dolorum temporibus aperiam dolor consequatur perferendis aspernatur fugit
2735
+ repellendus asperiores, voluptas illo? Voluptatum, atque quidem?
2736
+ </p>
2737
+ <${t}-button appearance="${e=>e.buttonAppearanceAccent}" slot="bottom" @click="${e=>e.closeDialog("modal")}">Close</${t}-button>
2738
+ </${t}-modal>
2739
+ <${t}-dialog ${(0,d.ref)("dialog")} style="--dialog-max-width:557px;">
2740
+ <div slot="top">Dialog Title</div>
2741
+ <p>Some Text in a Dialog</p>
2742
+ <p>Lorem ipsum dolor sit amet consectetur adipisicing elit. Quis similique iste ab sed
2743
+ voluptatem ut suscipit tenetur distinctio? Quo est debitis pariatur qui quisquam repudiandae
2744
+ at atque et quibusdam rerum, reprehenderit sed laborum officiis distinctio dolorum
2745
+ temporibus aperiam dolor consequatur perferendis aspernatur fugit repellendus asperiores,
2746
+ voluptas illo? Voluptatum, atque quidem?</p>
2747
+ <${t}-button appearance="${e=>e.buttonAppearanceAccent}" slot="bottom" @click="${e=>e.closeDialog("dialog")}">
2748
+ Close this dialog
2749
+ </${t}-button>
2750
+ <${t}-button appearance="${e=>e.buttonAppearanceAccent}" slot="bottom" >
2751
+ Confirm
2752
+ </${t}-button>
2753
+ </${t}-dialog>
2754
+ <div ${(0,d.ref)("errorDialogContainer")}></div>
2755
+ </div>
2756
+ </div>
2757
+ </div>
2758
+
2759
+ <div class="row">
2760
+ <div class="column">
2761
+ <${t}-text-area
2762
+ resize="both"
2763
+ placeholder="Text Area"
2764
+ aria-label="Example text field">
2765
+ Text Area Label
2766
+ </${t}-text-area>
2767
+ </div>
2768
+ <div class="column"></div>
2769
+ </div>
2770
+
2771
+ <div class="row">
2772
+ <div class="column">
2773
+ <${t}-slider
2774
+ style="margin-bottom: 20px;"
2775
+ role="slider"
2776
+ class="horizontal"
2777
+ tabindex="0"
2778
+ aria-valuenow="10"
2779
+ aria-valuemin="0"
2780
+ aria-valuemax="100"
2781
+ aria-orientation="horizontal"
2782
+ min="0"
2783
+ max="100"
2784
+ step="10"
2785
+ value="70"
2786
+ orientation="horizontal"
2787
+ mode="single-value"
2788
+ >
2789
+ <${t}-slider-label position="10">10%</${t}-slider-label>
2790
+ <${t}-slider-label position="50">50%</${t}-slider-label>
2791
+ <${t}-slider-label position="80">80%</${t}-slider-label>
2792
+ <${t}-slider-label position="100">100%</${t}-slider-label>
2793
+ </${t}-slider>
2794
+ </div>
2795
+ <div class="column">
2796
+ <div class="flex-row">
2797
+ <${t}-dropdown-menu name="Dropdown menu" :items="${e=>e.dropDownMenuItems}"></${t}-dropdown-menu>
2798
+
2799
+ <${t}-connection-indicator show-label></${t}-connection-indicator>
2800
+ </div>
2801
+ </div>
2802
+ </div>
2803
+
2804
+ <div class="row">
2805
+ <div class="column">
2806
+ <${t}-accordion>
2807
+ <${t}-accordion-item slot="item" id="accordion-1" class="expanded">
2808
+ Accordion one content
2809
+ <div slot="heading">Accordion one</div>
2810
+ </${t}-accordion-item>
2811
+ <${t}-accordion-item slot="item" id="accordion-2">
2812
+ Accordion two content
2813
+ <div slot="heading">Accordion two</div>
2814
+ </${t}-accordion-item>
2815
+ <${t}-accordion-item slot="item" id="accordion-3">
2816
+ Accordion three content
2817
+ <div slot="heading">Accordion three</div>
2818
+ </${t}-accordion-item>
2819
+ <${t}-accordion-item slot="item" id="accordion-4">
2820
+ Accordion four content
2821
+ <div slot="heading">Accordion four</div>
2822
+ </${t}-accordion-item>
2823
+ </${t}-accordion>
2824
+ </div>
2825
+
2826
+ <div class="column">
2827
+ <${t}-tree-view role="tree">
2828
+ <${t}-tree-item
2829
+ role="treeitem"
2830
+ tabindex="0"
2831
+ aria-expanded="true"
2832
+ expanded
2833
+ selected
2834
+ class="nested"
2835
+ >
2836
+ Tree item 1
2837
+ <${t}-tree-item slot="item" role="treeitem">Tree item 1 - 1</${t}-tree-item>
2838
+ </${t}-tree-item>
2839
+ <${t}-tree-item role="treeitem" tabindex="0" aria-expanded="false" class="nested">
2840
+ Tree item 2
2841
+ <${t}-tree-item slot="item" role="treeitem">Tree item 2 - 1</${t}-tree-item>
2842
+ </${t}-tree-item>
2843
+ <${t}-tree-item role="treeitem" class="nested">Tree item 3</${t}-tree-item>
2844
+ </${t}-tree-view>
2845
+ </div>
2846
+ </div>
2847
+
2848
+ <div class="row">
2849
+ <div class="column">
2850
+ <${t}-progress role="progressbar"></${t}-progress>
2851
+ </div>
2852
+ <div class="column">
2853
+ <${t}-progress-ring role="progressbar"></${t}-progress-ring>
2854
+ </div>
2855
+ </div>
2856
+ <div class="row">
2857
+ <div class="column">
2858
+ <${t}-menu>
2859
+ <${t}-menu-item>Menu item 1
2860
+ <${t}-menu slot="submenu">
2861
+ <${t}-menu-item>Menu item 1</${t}-menu-item>
2862
+ <${t}-menu-item>Menu item 2</${t}-menu-item>
2863
+ <${t}-menu-item>Menu item 3</${t}-menu-item>
2864
+ </${t}-menu>
2865
+ </${t}-menu-item>
2866
+ <${t}-menu-item>Menu item 2</${t}-menu-item>
2867
+ <${t}-menu-item>Menu item 3</${t}-menu-item>
2868
+ </${t}-menu>
2869
+ </div>
2870
+ <div class="column">
2871
+ <${t}-card>
2872
+ <${t}-tabs>
2873
+ <span part="start" class="start" slot="start">Blotter</span>
2874
+ <${t}-tab>Tab 1</${t}-tab>
2875
+ <${t}-tab slot="tab">Tab 2</${t}-tab>
2876
+ <${t}-tab slot="tab">Tab 3</${t}-tab>
2877
+ <${t}-tab slot="tab">Tab 4</${t}-tab>
2878
+ <${t}-tab-panel slot="tabpanel">
2879
+ <${t}-tabs appearance="secondary">
2880
+ <${t}-tab appearance="secondary" slot="tab">Nested Tab 1</${t}-tab>
2881
+ <${t}-tab appearance="secondary" slot="tab">Nested Tab 2</${t}-tab>
2882
+ <${t}-tab-panel slot="tabpanel">Nested Tab Panel 1</${t}-tab-panel>
2883
+ <${t}-tab-panel slot="tabpanel">Nested Tab Panel 2</${t}-tab-panel>
2884
+ </${t}-tabs>
2885
+ </${t}-tab-panel>
2886
+ <${t}-tab-panel slot="tabpanel">Tab Panel 2</${t}-tab-panel>
2887
+ <${t}-tab-panel slot="tabpanel">Tab Panel 3</${t}-tab-panel>
2888
+ <${t}-tab-panel slot="tabpanel">Tab Panel 4</${t}-tab-panel>
2889
+ </${t}-tabs>
2890
+ </${t}-card>
2891
+ </div>
2892
+ </div>
2893
+
2894
+ <div class="row">
2895
+ <div class="column">
2896
+ <${t}-card style="padding:20px;">
2897
+ <${t}-card style="padding:20px;">
2898
+ <${t}-card>
2899
+ <h3 style="padding-left: 8px;">Divider</h3>
2900
+ <${t}-divider></${t}-divider>
2901
+ </${t}-card>
2902
+ </${t}-card>
2903
+ </${t}-card>
2904
+ </div>
2905
+ <div class="column">
2906
+ <${t}-card style="padding:20px;">
2907
+ <h3>Skeleton</h3>
2908
+ <${t}-skeleton style="width: 50px; height: 50px;" shape="circle"></${t}-skeleton>
2909
+ <${t}-skeleton style="border-radius: 4px; margin-top: 10px; height: 10px;" shape="rect"></${t}-skeleton>
2910
+ <${t}-skeleton style="border-radius: 4px; margin-top: 10px; height: 10px;" shape="rect"></${t}-skeleton>
2911
+ <${t}-skeleton style="border-radius: 4px; margin-top: 10px; height: 10px;" shape="rect"></${t}-skeleton>
2912
+ <${t}-skeleton style="border-radius: 4px;width: 75px;height: 30px;margin-top: 20px;margin-bottom: 10px;"
2913
+ shape="rect"></${t}-skeleton>
2914
+ </${t}-card>
2915
+ </div>
2916
+ </div>
2917
+
2918
+ <div class="row">
2919
+ <div class="column">
2920
+ <${t}-horizontal-scroll class="horizontal-scroll">
2921
+ ${(0,d.repeat)(e=>e.cards,d.html`
2922
+ <${t}-card class="card-padding">
2923
+ Card number ${e=>e}
2924
+ <${t}-button>A button</${t}-button>
2925
+ </${t}-card>
2926
+ `)}
2927
+ </${t}-horizontal-scroll>
2928
+ </div>
2929
+ <div class="column">
2930
+ <${t}-listbox>
2931
+ <${t}-option>Option 1</${t}-option>
2932
+ <${t}-option>Option 2</${t}-option>
2933
+ <${t}-option>Option 3</${t}-option>
2934
+ </${t}-listbox>
2935
+ </div>
2936
+ </div>
2937
+ <div class="row">
2938
+ <div class="column">
2939
+ <${t}-toolbar>
2940
+ <span slot="label">Toolbar</span>
2941
+ <${t}-checkbox>Checkbox</${t}-checkbox>
2942
+ <${t}-checkbox>Checkbox</${t}-checkbox>
2943
+ <${t}-button slot="end"><${t}-icon name="power-off" slot="start"></${t}-icon> Sign Out</${t}-button>
2944
+ <${t}-select>
2945
+ <${t}-option value="1">Option 1</${t}-option>
2946
+ <${t}-option value="2">Option 2</${t}-option>
2947
+ <${t}-option value="3">Option 3</${t}-option>
2948
+ </${t}-select>
2949
+ </${t}-toolbar>
2950
+ </div>
2951
+ <div class="column">
2952
+ <${t}-banner ${(0,d.ref)("banner")}>
2953
+ <div slot="content">Lorem ipsum dolor sit amet consectetur adipisicing elit. Lorem ipsum dolor sit amet.
2954
+ Lorem, ipsum dolor.</div>
2955
+ <${t}-button slot="action" @click="${e=>e.dismissBanner()}" :appearance="${e=>e.buttonAppearanceText}">
2956
+ Ignore
2957
+ </${t}-button>
2958
+ <${t}-button slot="action" :appearance="${e=>e.buttonAppearanceText}">
2959
+ Diagnose
2960
+ </${t}-button>
2961
+ </${t}-banner>
2962
+ </div>
2963
+ </div>
2964
+ <div class="row">
2965
+ <div class="column">
2966
+ <${t}-stepper>
2967
+ <${t}-stepper-tab>stepper 1</${t}-stepper-tab>
2968
+ <${t}-stepper-tab>stepper 2</${t}-stepper-tab>
2969
+ <${t}-stepper-tab>stepper 3</${t}-stepper-tab>
2970
+ <${t}-stepper-tab>stepper 4</${t}-stepper-tab>
2971
+ <${t}-stepper-tab-panel>Stepper Panel 1</${t}-stepper-tab-panel>
2972
+ <${t}-stepper-tab-panel>Stepper Panel 2</${t}-stepper-tab-panel>
2973
+ <${t}-stepper-tab-panel>Stepper Panel 3</${t}-stepper-tab-panel>
2974
+ <${t}-stepper-tab-panel>Stepper Panel 4</${t}-stepper-tab-panel>
2975
+ </${t}-stepper>
2976
+ </div>
2977
+ <div class="column">
2978
+ <${t}-toast notify="critical">
2979
+ <h6 slot="top">Toast title</h6>
2980
+ <span slot="content">Lorem ipsum dolor sit amet consectetur adipisicing elit. Lorem ipsum dolor sit amet. Lorem, ipsum dolor.</span>
2981
+ <span slot="date">Today 14:28</span>
2982
+ <${t}-button :appearance="${e=>e.buttonAppearanceAccent}" slot="bottom">Close notification</${t}-button>
2983
+ </${t}-toast>
2984
+ </div>
2985
+ </div>
2986
+ </div>
2987
+ </div>
2988
+ </${t}-design-system-provider>
2989
+ </template>
2990
+ `;var t}}
2991
+ `;let sr=class extends d.FASTElement{constructor(){super(...arguments),this.prefix="rapid",this.buttonAppearanceAccent="primary-blue",this.buttonAppearanceNeutral="primary-grey",this.buttonAppearanceOutline="primary-gradient",this.buttonAppearanceText="lightweight",this.badgeAppearanceAccent="primary",this.badgeAppearanceNeutral="secondary",this.badgeText="white",this.cards=Array.from({length:8},(e,t)=>t+1),this.countries=["Afghanistan","Aland Islands","Albania","Algeria","American Samoa","Andorra","Angola","Aruba","Australia","Austria","Azerbaijan","Bahamas","Bahrain","Bangladesh","Barbados","Belarus","Belgium","Belize","Benin","Bhutan","Bolivia","Bonaire, Sint Eustatius and Saba","Cambodia","Cameroon","Canada"],this.menuActions=[{name:"View",callback:e=>Ko.debug("VIEWW!!!",e)},{name:"Delete",callback:e=>Ko.debug("DELETE!!!",e)},{name:"Edit",callback:e=>Ko.debug("EDIT!!!",e)},{name:"Wait",callback:e=>Ko.debug("WAIT???",e)}],this.menuDefinition={actions:this.menuActions,buttonAppearance:"stealth",data:{name:"test"}},this.dropDownMenuItems=[{name:"Menu item 1",callback:()=>alert("Menu item 1 clicked"),icon:{name:"glasses"}},{name:"Menu item 2",callback:()=>alert("Menu item 2 clicked")},{name:"Menu item 3",callback:()=>alert("Menu item 3 clicked"),submenu:[{name:"Menu item 5",callback:()=>alert("Menu item 5 clicked"),icon:{name:"address-card"}},{name:"Menu item 6",callback:()=>alert("Menu item 6 clicked"),submenu:[{name:"Menu item 7",callback:()=>alert("Menu item 7 clicked"),color:"red",icon:{name:"address-card"}},{name:"Menu item 8",callback:()=>alert("Menu item 8 clicked"),isDisabled:()=>!0}]}]}]}connectedCallback(){super.connectedCallback(),document.body.addEventListener(jo.STYLES_CHANGED,e=>{this.handleStyleChanges(e)}),document.body.addEventListener(jo.DS_CHANGED,e=>{this.handleDSChanges(e)}),d.DOM.queueUpdate(()=>{p.bodyFont.withDefault(Yo)})}handleStyleChanges(e){const t=e.detail;t&&d.DOM.queueUpdate(()=>{ir(t,this.provider)})}handleDSChanges(e){this.prefix=e.detail.prefix,this.buttonAppearanceAccent=e.detail.buttonAppearanceAccent,this.buttonAppearanceNeutral=e.detail.buttonAppearanceNeutral,this.buttonAppearanceOutline=e.detail.buttonAppearanceOutline,this.buttonAppearanceText=e.detail.buttonAppearanceText,this.badgeAppearanceAccent=e.detail.badgeAppearanceAccent,this.badgeAppearanceNeutral=e.detail.badgeAppearanceNeutral,this.badgeText=e.detail.badgeText}showDialog(e){this[e].show()}closeDialog(e){this[e].close()}dismissBanner(){this.banner.dismiss()}};(0,r.Cg)([d.observable],sr.prototype,"modal",void 0),(0,r.Cg)([d.attr],sr.prototype,"prefix",void 0),(0,r.Cg)([d.observable],sr.prototype,"buttonAppearanceAccent",void 0),(0,r.Cg)([d.observable],sr.prototype,"buttonAppearanceNeutral",void 0),(0,r.Cg)([d.observable],sr.prototype,"buttonAppearanceOutline",void 0),(0,r.Cg)([d.observable],sr.prototype,"buttonAppearanceText",void 0),(0,r.Cg)([d.observable],sr.prototype,"badgeAppearanceAccent",void 0),(0,r.Cg)([d.observable],sr.prototype,"badgeAppearanceNeutral",void 0),(0,r.Cg)([d.observable],sr.prototype,"badgeText",void 0),(0,r.Cg)([d.observable],sr.prototype,"cards",void 0),(0,r.Cg)([d.observable],sr.prototype,"countries",void 0),(0,r.Cg)([d.observable],sr.prototype,"menuActions",void 0),(0,r.Cg)([d.observable],sr.prototype,"menuDefinition",void 0),(0,r.Cg)([d.observable],sr.prototype,"dropDownMenuItems",void 0),(0,r.Cg)([d.observable],sr.prototype,"provider",void 0),sr=(0,r.Cg)([(0,d.customElement)({name:"preview-components",template:nr,styles:ar})],sr);const lr=d.css`
2992
+ .export {
2993
+ display: flex;
2994
+ justify-content: center;
2995
+ width: 100%;
2996
+ }
2997
+
2998
+ .buttons {
2999
+ display: flex;
3000
+ justify-content: space-between;
3001
+ }
3002
+ `,dr=d.html`
3003
+ <template>
3004
+ <div class="export">
3005
+ <rapid-button appearance="accent" @click="${e=>e.showModal()}">Save Changes</rapid-button>
3006
+ <rapid-modal ${(0,d.ref)("modal")}>
3007
+ <slot>
3008
+ <textarea rows="26" cols="34" class="textarea" :value=${e=>e.value}></textarea>
3009
+ </slot>
3010
+ <div class="buttons">
3011
+ <rapid-button appearance="accent" @click="${e=>e.closeModal()}" slot="bottom">
3012
+ Close
3013
+ </rapid-button>
3014
+ ${(0,d.when)(e=>e.tokensPath,d.html`
3015
+ <rapid-button appearance="accent" @click="${e=>e.updateTokens()}" slot="bottom">
3016
+ Save
3017
+ </rapid-button>
3018
+ `)}
3019
+ </div>
3020
+ </rapid-modal>
3021
+ </div>
3022
+ </template>
3023
+ `;let cr=class extends d.FASTElement{constructor(){super(...arguments),this.formatValues=e=>{const t={design_tokens:{color:{accent:{$value:e.accentColor,$type:"color"},neutral:{$value:e.neutralColor,$type:"color"}},fontFamily:{bodyFont:{$value:e.bodyFont,$type:"fontFamily"}},typography:{baseFontSize:{$value:e.baseFontSize,$type:"dimension"},baseLineHeight:{$value:e.baseLineHeight,$type:"dimension"}},mode:{luminance:{$value:e.luminance,$type:"number"}},style:{density:{$value:e.density,$type:"number"},baseHeightMultiplier:{$value:e.baseHeightMultiplier,$type:"number"},borderRadius:{$value:e.borderRadius,$type:"number"},strokeWidth:{$value:e.strokeWidth,$type:"number"}},space:{designUnit:{$value:e.designUnit,$type:"number"}}}};return JSON.stringify(t,null,3)},this.showModal=()=>this.modal.show(),this.closeModal=()=>this.modal.close(),this.updateTokens=()=>{fetch("api/tokens",{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({tokens:this.value})}).then(e=>{if(!e.ok)throw new Error(`API request failed with status ${e.status}`);return e.json()}).then(e=>{Ko.log("Tokens saved successfully:",e),this.$emit(jo.APPLY_CUSTOM_DESIGN,e.message)}).catch(e=>{Ko.error("Error saving tokens:",e)}),this.closeModal()}}connectedCallback(){super.connectedCallback(),document.body.addEventListener(jo.STYLES_CHANGED,e=>{const t=e;this.value=this.formatValues(t.detail)})}};(0,r.Cg)([d.attr],cr.prototype,"value",void 0),(0,r.Cg)([d.attr],cr.prototype,"tokensPath",void 0),cr=(0,r.Cg)([(0,d.customElement)({name:"design-system-export",template:dr,styles:lr})],cr);const pr=d.css`
3024
+ .colors {
3025
+ display: flex;
3026
+ flex-wrap: wrap;
3027
+ list-style-type: none;
3028
+ margin: 0;
3029
+ padding: 0;
3030
+ }
3031
+
3032
+ .color {
3033
+ flex-grow: 1;
3034
+ height: 20px;
3035
+ }
3036
+ `,ur=d.html`
3037
+ <ul class="colors">
3038
+ ${(0,d.repeat)(e=>e.swatches,d.html`
3039
+ <li class="color" style="background-color: ${e=>e.toColorString()}"></li>
3040
+ `)}
3041
+ </ul>
3042
+ `;let mr=class extends d.FASTElement{constructor(){super(...arguments),this.swatches=[]}typeChanged(){if(this.type){p[this.type+"Palette"].subscribe({handleChange:e=>{const t=e.token.getValueFor(this);this.swatches=[...t.swatches]}},this)}}handleStyleChanges(e){const t=e.detail;t&&d.DOM.queueUpdate(()=>{const e=or(t[`${this.type}Color`]);this.swatches=[...e.swatches]})}connectedCallback(){super.connectedCallback(),document.body.addEventListener(jo.STYLES_CHANGED,e=>{this.handleStyleChanges(e)})}};(0,r.Cg)([d.observable],mr.prototype,"swatches",void 0),(0,r.Cg)([d.attr],mr.prototype,"type",void 0),mr=(0,r.Cg)([(0,d.customElement)({name:"color-palette",styles:pr,template:ur})],mr);const hr=d.css`
3043
+ .preview {
3044
+ width: 40px;
3045
+ height: 40px;
3046
+ }
3047
+ `,vr=d.html`
3048
+ <div
3049
+ class="preview"
3050
+ style="background-color: ${e=>p[e.tokenName].createCSS()}"
3051
+ ></div>
3052
+ `;let gr=class extends d.FASTElement{};(0,r.Cg)([d.attr],gr.prototype,"tokenName",void 0),gr=(0,r.Cg)([(0,d.customElement)({name:"color-token",styles:hr,template:vr})],gr);const br=d.css`
3053
+ .container {
3054
+ display: flex;
3055
+ width: 100%;
3056
+ margin: 16px 0;
3057
+ }
3058
+
3059
+ .header-title {
3060
+ text-align: center;
3061
+ }
3062
+
3063
+ .column {
3064
+ display: flex;
3065
+ flex-direction: column;
3066
+ width: 100%;
3067
+ padding: 0 16px;
3068
+ }
3069
+
3070
+ .row {
3071
+ display: grid;
3072
+ grid-template-columns: auto 1fr auto;
3073
+ grid-template-rows: auto;
3074
+ place-items: center start;
3075
+ width: 100%;
3076
+ padding: 4px 0;
3077
+ box-sizing: border-box;
3078
+ font-size: 12px;
3079
+ column-gap: 16px;
3080
+ }
3081
+
3082
+ .preview {
3083
+ display: flex;
3084
+ align-items: center;
3085
+ justify-content: center;
3086
+ width: 20px;
3087
+ height: 20px;
3088
+ border-radius: 2px;
3089
+ box-sizing: border-box;
3090
+ }
3091
+
3092
+ .token-name {
3093
+ width: 100%;
3094
+ text-align: start;
3095
+ }
3096
+
3097
+ .container > div:not(:last-child) {
3098
+ border-right: 1px solid #fafafa;
3099
+ }
3100
+ `,yr=[{title:"Fill",subcategories:[{title:"Fill Colour",tokens:[{name:"fillColor",cssProperty:"--fill-color"}]},{title:"Accent Fill",tokens:[{name:"accentFillRest",cssProperty:"--accent-fill-rest"},{name:"accentFillHover",cssProperty:"--accent-fill-hover"},{name:"accentFillActive",cssProperty:"--accent-fill-active"},{name:"accentFillFocus",cssProperty:"--accent-fill-focus"}]},{title:"Neutral Fill",tokens:[{name:"neutralFillRest",cssProperty:"--neutral-fill-rest"},{name:"neutralFillHover",cssProperty:"--neutral-fill-hover"},{name:"neutralFillActive",cssProperty:"--neutral-fill-active"},{name:"neutralFillFocus",cssProperty:"--neutral-fill-focus"}]},{title:"Neutral Fill Input",tokens:[{name:"neutralFillInputRest",cssProperty:"--neutral-fill-input-rest"},{name:"neutralFillInputHover",cssProperty:"--neutral-fill-input-hover"},{name:"neutralFillInputActive",cssProperty:"--neutral-fill-input-active"},{name:"neutralFillInputFocus",cssProperty:"--neutral-fill-input-focus"}]},{title:"Neutral Fill Stealth",tokens:[{name:"neutralFillStealthRest",cssProperty:"--neutral-fill-stealth-rest"},{name:"neutralFillStealthHover",cssProperty:"--neutral-fill-stealth-hover"},{name:"neutralFillStealthActive",cssProperty:"--neutral-fill-stealth-active"},{name:"neutralFillStealthFocus",cssProperty:"--neutral-fill-stealth-focus"}]},{title:"Neutral Fill Strong",tokens:[{name:"neutralFillStrongRest",cssProperty:"--neutral-fill-strong-rest"},{name:"neutralFillStrongHover",cssProperty:"--neutral-fill-strong-hover"},{name:"neutralFillStrongActive",cssProperty:"--neutral-fill-strong-active"},{name:"neutralFillStrongFocus",cssProperty:"--neutral-fill-strong-focus"}]}]},{title:"Foreground",subcategories:[{title:"Neutral Foreground",tokens:[{name:"neutralForegroundRest",cssProperty:"--neutral-foreground-rest"},{name:"neutralForegroundHint",cssProperty:"--neutral-foreground-hint"}]},{title:"Accent Foreground",tokens:[{name:"accentForegroundRest",cssProperty:"--accent-foreground-rest"},{name:"accentForegroundHover",cssProperty:"--accent-foreground-hover"},{name:"accentForegroundActive",cssProperty:"--accent-foreground-active"},{name:"accentForegroundFocus",cssProperty:"--accent-foreground-focus"}]},{title:"Foreground on Accent",tokens:[{name:"foregroundOnAccentRest",cssProperty:"--foreground-on-accent-rest"},{name:"foregroundOnAccentHover",cssProperty:"--foreground-on-accent-hover"},{name:"foregroundOnAccentActive",cssProperty:"--foreground-on-accent-active"},{name:"foregroundOnAccentFocus",cssProperty:"--foreground-on-accent-focus"}]},{title:"Foreground on accent large",tokens:[{name:"foregroundOnAccentRestLarge",cssProperty:"--foreground-on-accent-rest-large"},{name:"foregroundOnAccentHoverLarge",cssProperty:"--foreground-on-accent-hover-large"},{name:"foregroundOnAccentActiveLarge",cssProperty:"--foreground-on-accent-active-large"},{name:"foregroundOnAccentFocusLarge",cssProperty:"--foreground-on-accent-focus-large"}]}]},{title:"Stroke",subcategories:[{title:"Focus Stroke",tokens:[{name:"focusStrokeOuter",cssProperty:"--focus-stroke-outer"},{name:"focusStrokeInner",cssProperty:"--focus-stroke-inner"}]},{title:"Neutral Stroke",tokens:[{name:"neutralStrokeRest",cssProperty:"---neutral-stroke-rest"},{name:"neutralStrokeHover",cssProperty:"--neutral-stroke-hover"},{name:"neutralStrokeActive",cssProperty:"--neutral-stroke-active"},{name:"neutralStrokeFocus",cssProperty:"--neutral-stroke-focus"}]},{title:"Neutral stroke divider",tokens:[{name:"neutralStrokeDividerRest",cssProperty:"--neutral-stroke-divider-rest"}]}]},{title:"Layer",subcategories:[{title:"Neutral Layers",tokens:[{name:"neutralLayer1",cssProperty:"--neutral-layer-1"},{name:"neutralLayer2",cssProperty:"--neutral-layer-2"},{name:"neutralLayer3",cssProperty:"--neutral-layer-3"},{name:"neutralLayer4",cssProperty:"--neutral-layer-4"}]},{title:"Neutral Layer Card Container",tokens:[{name:"neutralLayerCardContainer",cssProperty:"--neutral-layer-card-container"}]},{title:"Neutral Fill Layer",tokens:[{name:"neutralFillLayerRest",cssProperty:"--neutral-fill-layer-rest"}]},{title:"Neutral Layer Floating",tokens:[{name:"neutralLayerFloating",cssProperty:"--neutral-layer-floating"}]}]}],fr=d.html`
3101
+ <div class="row">
3102
+ <div
3103
+ class="preview"
3104
+ style="background-color: ${e=>p[e.name].createCSS()}"
3105
+ ></div>
3106
+ <!-- <div class="token-name" title=${e=>e.cssProperty}>${e=>e.cssProperty}</div> -->
3107
+ <div class="token-name" title=${e=>e.cssProperty}>${e=>e.name}</div>
3108
+ <div>
3109
+ ${(e,t)=>p[e.name].getValueFor(t.parentContext.parentContext.parent.provider).toColorString().toUpperCase()}
3110
+ </div>
3111
+ </div>
3112
+ `,$r=d.html`
3113
+ <div class="container" ${(0,d.ref)("provider")}>
3114
+ ${(0,d.repeat)(()=>yr,d.html`
3115
+ <div class="column">
3116
+ <h3 class="header-title">${e=>e.title}</h3>
3117
+ ${(0,d.repeat)(e=>e.subcategories,d.html`
3118
+ <h4>${e=>e.title}</h4>
3119
+ ${(0,d.repeat)(e=>e.tokens,fr)}
3120
+ `)}
3121
+ </div>
3122
+ `)}
3123
+ </div>
3124
+ `;let wr=class extends d.FASTElement{connectedCallback(){super.connectedCallback(),document.body.addEventListener(jo.STYLES_CHANGED,e=>{const t=e.detail;ir(t,this.provider)})}};(0,r.Cg)([d.observable],wr.prototype,"provider",void 0),wr=(0,r.Cg)([(0,d.customElement)({name:"color-tokens",template:$r,styles:br})],wr);const xr=d.css`
3125
+ table {
3126
+ background: var(--neutral-fill-rest);
3127
+ color: var(--neutral-foreground-rest);
3128
+ }
3129
+
3130
+ th {
3131
+ text-align: left;
3132
+ }
3133
+ `,Sr=d.html`
3134
+ <table ${(0,d.ref)("provider")} style="font-family: ${()=>p.bodyFont.createCSS()}">
3135
+ <colgroup>
3136
+ <col style="width: 15%;" />
3137
+ <col style="width: 30%;" />
3138
+ <col style="width: 30%;" />
3139
+ <col style="width: 5%;" />
3140
+ <col style="width: 20%;" />
3141
+ </colgroup>
3142
+ <thead>
3143
+ <tr>
3144
+ <th>Level</th>
3145
+ <th>Token</th>
3146
+ <th>CSS Custom Property</th>
3147
+ <th>Adjusted</th>
3148
+ <th>Preview</th>
3149
+ </tr>
3150
+ </thead>
3151
+ <tbody>
3152
+ <tr>
3153
+ <td>Minus 2 (smallest)</td>
3154
+ <td>
3155
+ typeRampMinus2FontSize
3156
+ <br />
3157
+ typeRampMinus2LineHeight
3158
+ </td>
3159
+ <td>
3160
+ ${()=>p.typeRampMinus2FontSize.cssCustomProperty}
3161
+ <br />
3162
+ ${()=>p.typeRampMinus2LineHeight.cssCustomProperty}
3163
+ </td>
3164
+ <td>
3165
+ ${e=>p.typeRampMinus2FontSize.getValueFor(e.provider)}
3166
+ <br />
3167
+ ${e=>p.typeRampMinus2LineHeight.getValueFor(e.provider)}
3168
+ </td>
3169
+ <td
3170
+ style="font-size: ${()=>p.typeRampMinus2FontSize.createCSS()}; line-height: ${()=>p.typeRampMinus2LineHeight.createCSS()};"
3171
+ >
3172
+ The quick brown fox jumps over a lazy dog
3173
+ </td>
3174
+ </tr>
3175
+ <tr>
3176
+ <td>Minus 1</td>
3177
+ <td>
3178
+ typeRampMinus1FontSize
3179
+ <br />
3180
+ typeRampMinus1LineHeight
3181
+ </td>
3182
+ <td>
3183
+ ${()=>p.typeRampMinus1FontSize.cssCustomProperty}
3184
+ <br />
3185
+ ${()=>p.typeRampMinus1LineHeight.cssCustomProperty}
3186
+ </td>
3187
+ <td>
3188
+ ${e=>p.typeRampMinus1FontSize.getValueFor(e.provider)}
3189
+ <br />
3190
+ ${e=>p.typeRampMinus1LineHeight.getValueFor(e.provider)}
3191
+ </td>
3192
+ <td
3193
+ style="font-size: ${()=>p.typeRampMinus1FontSize.createCSS()}; line-height: ${()=>p.typeRampMinus1LineHeight.createCSS()};"
3194
+ >
3195
+ The quick brown fox jumps over a lazy dog
3196
+ </td>
3197
+ </tr>
3198
+ <tr>
3199
+ <td>Base (body)</td>
3200
+ <td>
3201
+ typeRampBaseFontSize
3202
+ <br />
3203
+ typeRampBaseLineHeight
3204
+ </td>
3205
+ <td>
3206
+ ${()=>p.typeRampBaseFontSize.cssCustomProperty}
3207
+ <br />
3208
+ ${()=>p.typeRampBaseLineHeight.cssCustomProperty}
3209
+ </td>
3210
+ <td>
3211
+ ${e=>p.typeRampBaseFontSize.getValueFor(e.provider)}
3212
+ <br />
3213
+ ${e=>p.typeRampBaseLineHeight.getValueFor(e.provider)}
3214
+ </td>
3215
+ <td
3216
+ style="font-size: ${()=>p.typeRampBaseFontSize.createCSS()}; line-height: ${()=>p.typeRampBaseLineHeight.createCSS()};"
3217
+ >
3218
+ The quick brown fox jumps over a lazy dog
3219
+ </td>
3220
+ </tr>
3221
+ <tr>
3222
+ <td>Plus 1</td>
3223
+ <td>
3224
+ typeRampPlus1FontSize
3225
+ <br />
3226
+ typeRampPlus1LineHeight
3227
+ </td>
3228
+ <td>
3229
+ ${()=>p.typeRampPlus1FontSize.cssCustomProperty}
3230
+ <br />
3231
+ ${()=>p.typeRampPlus1LineHeight.cssCustomProperty}
3232
+ </td>
3233
+ <td>
3234
+ ${e=>p.typeRampPlus1FontSize.getValueFor(e.provider)}
3235
+ <br />
3236
+ ${e=>p.typeRampPlus1LineHeight.getValueFor(e.provider)}
3237
+ </td>
3238
+ <td
3239
+ style="font-size: ${()=>p.typeRampPlus1FontSize.createCSS()}; line-height: ${()=>p.typeRampPlus1LineHeight.createCSS()};"
3240
+ >
3241
+ The quick brown fox jumps over a lazy dog
3242
+ </td>
3243
+ </tr>
3244
+ <tr>
3245
+ <td>Plus 2</td>
3246
+ <td>
3247
+ typeRampPlus2FontSize
3248
+ <br />
3249
+ typeRampPlus2LineHeight
3250
+ </td>
3251
+ <td>
3252
+ ${()=>p.typeRampPlus2FontSize.cssCustomProperty}
3253
+ <br />
3254
+ ${()=>p.typeRampPlus2LineHeight.cssCustomProperty}
3255
+ </td>
3256
+ <td>
3257
+ ${e=>p.typeRampPlus2FontSize.getValueFor(e.provider)}
3258
+ <br />
3259
+ ${e=>p.typeRampPlus2LineHeight.getValueFor(e.provider)}
3260
+ </td>
3261
+ <td
3262
+ style="font-size: ${()=>p.typeRampPlus2FontSize.createCSS()}; line-height: ${()=>p.typeRampPlus2LineHeight.createCSS()};"
3263
+ >
3264
+ The quick brown fox jumps over a lazy dog
3265
+ </td>
3266
+ </tr>
3267
+ <tr>
3268
+ <td>Plus 3</td>
3269
+ <td>
3270
+ typeRampPlus3FontSize
3271
+ <br />
3272
+ typeRampPlus3LineHeight
3273
+ </td>
3274
+ <td>
3275
+ ${()=>p.typeRampPlus3FontSize.cssCustomProperty}
3276
+ <br />
3277
+ ${()=>p.typeRampPlus3LineHeight.cssCustomProperty}
3278
+ </td>
3279
+ <td>
3280
+ ${e=>p.typeRampPlus3FontSize.getValueFor(e.provider)}
3281
+ <br />
3282
+ ${e=>p.typeRampPlus3LineHeight.getValueFor(e.provider)}
3283
+ </td>
3284
+ <td
3285
+ style="font-size: ${()=>p.typeRampPlus3FontSize.createCSS()}; line-height: ${()=>p.typeRampPlus3LineHeight.createCSS()};"
3286
+ >
3287
+ The quick brown fox jumps over a lazy dog
3288
+ </td>
3289
+ </tr>
3290
+ <tr>
3291
+ <td>Plus 4</td>
3292
+ <td>
3293
+ typeRampPlus4FontSize
3294
+ <br />
3295
+ typeRampPlus4LineHeight
3296
+ </td>
3297
+ <td>
3298
+ ${()=>p.typeRampPlus4FontSize.cssCustomProperty}
3299
+ <br />
3300
+ ${()=>p.typeRampPlus4LineHeight.cssCustomProperty}
3301
+ </td>
3302
+ <td>
3303
+ ${e=>p.typeRampPlus4FontSize.getValueFor(e.provider)}
3304
+ <br />
3305
+ ${e=>p.typeRampPlus4LineHeight.getValueFor(e.provider)}
3306
+ </td>
3307
+ <td
3308
+ style="font-size: ${()=>p.typeRampPlus4FontSize.createCSS()}; line-height: ${()=>p.typeRampPlus4LineHeight.createCSS()};"
3309
+ >
3310
+ The quick brown fox jumps over a lazy dog
3311
+ </td>
3312
+ </tr>
3313
+ <tr>
3314
+ <td>Plus 5</td>
3315
+ <td>
3316
+ typeRampPlus5FontSize
3317
+ <br />
3318
+ typeRampPlus5LineHeight
3319
+ </td>
3320
+ <td>
3321
+ ${()=>p.typeRampPlus5FontSize.cssCustomProperty}
3322
+ <br />
3323
+ ${()=>p.typeRampPlus5LineHeight.cssCustomProperty}
3324
+ </td>
3325
+ <td>
3326
+ ${e=>p.typeRampPlus5FontSize.getValueFor(e.provider)}
3327
+ <br />
3328
+ ${e=>p.typeRampPlus5LineHeight.getValueFor(e.provider)}
3329
+ </td>
3330
+ <td
3331
+ style="font-size: ${()=>p.typeRampPlus5FontSize.createCSS()}; line-height: ${()=>p.typeRampPlus5LineHeight.createCSS()};"
3332
+ >
3333
+ The quick brown fox jumps over a lazy dog
3334
+ </td>
3335
+ </tr>
3336
+ <tr>
3337
+ <td>Plus 6 (largest)</td>
3338
+ <td>
3339
+ typeRampPlus6FontSize
3340
+ <br />
3341
+ typeRampPlus6LineHeight
3342
+ </td>
3343
+ <td>
3344
+ ${()=>p.typeRampPlus6FontSize.cssCustomProperty}
3345
+ <br />
3346
+ ${()=>p.typeRampPlus6LineHeight.cssCustomProperty}
3347
+ </td>
3348
+ <td>
3349
+ ${e=>p.typeRampPlus6FontSize.getValueFor(e.provider)}
3350
+ <br />
3351
+ ${e=>p.typeRampPlus6LineHeight.getValueFor(e.provider)}
3352
+ </td>
3353
+ <td
3354
+ style="font-size: ${()=>p.typeRampPlus6FontSize.createCSS()}; line-height: ${()=>p.typeRampPlus6LineHeight.createCSS()};"
3355
+ >
3356
+ The quick brown fox jumps over a lazy dog
3357
+ </td>
3358
+ </tr>
3359
+ </tbody>
3360
+ </table>
3361
+ `;let Cr=class extends d.FASTElement{connectedCallback(){super.connectedCallback(),document.body.addEventListener(jo.STYLES_CHANGED,e=>{const t=e.detail;ir(t,this.provider)})}};(0,r.Cg)([d.observable],Cr.prototype,"provider",void 0),Cr=(0,r.Cg)([(0,d.customElement)({name:"typography-tokens",template:Sr,styles:xr})],Cr);const Ar=d.css`
3362
+ :host {
3363
+ background: var(--fill-color);
3364
+ color: var(--neutral-foreground-rest);
3365
+ flex-direction: column;
3366
+ flex: 1;
3367
+ }
3368
+
3369
+ rapid-tab-panel {
3370
+ padding: 0;
3371
+ }
3372
+
3373
+ .wrapper {
3374
+ margin-top: 24px;
3375
+ padding: 0 calc((6 + (var(--design-unit) * 2 * var(--density))) * 1px);
3376
+ }
3377
+ `,Ir=d.css`
3378
+ :host {
3379
+ --badge-fill-primary: var(--accent-fill-rest);
3380
+ --badge-fill-neutral: var(--neutral-fill-rest);
3381
+
3382
+ background: var(--fill-color);
3383
+ color: var(--neutral-foreground-rest);
3384
+ flex-direction: column;
3385
+ flex: 1;
3386
+ font-family: var(--body-font);
3387
+ }
3388
+
3389
+ .app-container {
3390
+ display: grid;
3391
+ background: var(--fill-color);
3392
+ grid-template-columns: 3fr 1fr;
3393
+ grid-template-rows: repeat(2, 1fr);
3394
+ grid-gap: 12px;
3395
+ height: calc(100% - 24px);
3396
+ padding: 12px;
3397
+
3398
+ .div1 {
3399
+ grid-area: 1 / 1 / 2 / 2;
3400
+ }
3401
+
3402
+ .div2 {
3403
+ grid-area: 2 / 1 / 3 / 2;
3404
+ }
3405
+
3406
+ .div3 {
3407
+ grid-area: 1 / 2 / 3 / 3;
3408
+ }
3409
+ }
3410
+ `,kr=d.html`
3411
+ ${e=>{return t=e.prefix,d.html`
3412
+ <template>
3413
+ <${t}-design-system-provider ${(0,d.ref)("provider")}>
3414
+ <rapid-layout>
3415
+ <rapid-layout-region>
3416
+ <rapid-layout-region type="vertical">
3417
+ <rapid-layout-item title="Button">
3418
+ <preview-grid></preview-grid>
3419
+ </rapid-layout-item>
3420
+ <rapid-layout-item title="Checkbox">
3421
+ </rapid-layout-item>
3422
+ </rapid-layout-region>
3423
+ <rapid-layout-item title="Text">
3424
+ <preview-grid></preview-grid>
3425
+ </rapid-layout-item>
3426
+ </rapid-layout-region>
3427
+ </rapid-layout>
3428
+ </${t}-design-system-provider>
3429
+ </template>
3430
+ `;var t}}
3431
+ `;let Mr=class extends d.FASTElement{constructor(){super(...arguments),this.prefix="rapid",this.buttonAppearanceAccent="primary-blue",this.buttonAppearanceNeutral="primary-grey",this.buttonAppearanceOutline="primary-gradient",this.buttonAppearanceText="lightweight",this.badgeAppearanceAccent="primary",this.badgeAppearanceNeutral="secondary",this.badgeText="white",this.cards=Array.from({length:8},(e,t)=>t+1),this.countries=["Afghanistan","Aland Islands","Albania","Algeria","American Samoa","Andorra","Angola","Aruba","Australia","Austria","Azerbaijan","Bahamas","Bahrain","Bangladesh","Barbados","Belarus","Belgium","Belize","Benin","Bhutan","Bolivia","Bonaire, Sint Eustatius and Saba","Cambodia","Cameroon","Canada"],this.menuActions=[{name:"View",callback:e=>Ko.debug("VIEWW!!!",e)},{name:"Delete",callback:e=>Ko.debug("DELETE!!!",e)},{name:"Edit",callback:e=>Ko.debug("EDIT!!!",e)},{name:"Wait",callback:e=>Ko.debug("WAIT???",e)}],this.menuDefinition={actions:this.menuActions,buttonAppearance:"stealth",data:{name:"test"}},this.dropDownMenuItems=[{name:"Menu item 1",callback:()=>alert("Menu item 1 clicked"),icon:{name:"glasses"}},{name:"Menu item 2",callback:()=>alert("Menu item 2 clicked")},{name:"Menu item 3",callback:()=>alert("Menu item 3 clicked"),submenu:[{name:"Menu item 5",callback:()=>alert("Menu item 5 clicked"),icon:{name:"address-card"}},{name:"Menu item 6",callback:()=>alert("Menu item 6 clicked"),submenu:[{name:"Menu item 7",callback:()=>alert("Menu item 7 clicked"),color:"red",icon:{name:"address-card"}},{name:"Menu item 8",callback:()=>alert("Menu item 8 clicked"),isDisabled:()=>!0}]}]}]}connectedCallback(){super.connectedCallback(),document.body.addEventListener(jo.STYLES_CHANGED,e=>{this.handleStyleChanges(e)}),document.body.addEventListener(jo.DS_CHANGED,e=>{this.handleDSChanges(e)}),d.DOM.queueUpdate(()=>{p.bodyFont.withDefault(Yo)})}handleStyleChanges(e){const t=e.detail;t&&d.DOM.queueUpdate(()=>{ir(t,this.provider)})}handleDSChanges(e){this.prefix=e.detail.prefix,this.buttonAppearanceAccent=e.detail.buttonAppearanceAccent,this.buttonAppearanceNeutral=e.detail.buttonAppearanceNeutral,this.buttonAppearanceOutline=e.detail.buttonAppearanceOutline,this.buttonAppearanceText=e.detail.buttonAppearanceText,this.badgeAppearanceAccent=e.detail.badgeAppearanceAccent,this.badgeAppearanceNeutral=e.detail.badgeAppearanceNeutral,this.badgeText=e.detail.badgeText}showDialog(e){this[e].show()}closeDialog(e){this[e].close()}dismissBanner(){this.banner.dismiss()}};(0,r.Cg)([d.observable],Mr.prototype,"modal",void 0),(0,r.Cg)([d.attr],Mr.prototype,"prefix",void 0),(0,r.Cg)([d.observable],Mr.prototype,"buttonAppearanceAccent",void 0),(0,r.Cg)([d.observable],Mr.prototype,"buttonAppearanceNeutral",void 0),(0,r.Cg)([d.observable],Mr.prototype,"buttonAppearanceOutline",void 0),(0,r.Cg)([d.observable],Mr.prototype,"buttonAppearanceText",void 0),(0,r.Cg)([d.observable],Mr.prototype,"badgeAppearanceAccent",void 0),(0,r.Cg)([d.observable],Mr.prototype,"badgeAppearanceNeutral",void 0),(0,r.Cg)([d.observable],Mr.prototype,"badgeText",void 0),(0,r.Cg)([d.observable],Mr.prototype,"cards",void 0),(0,r.Cg)([d.observable],Mr.prototype,"countries",void 0),(0,r.Cg)([d.observable],Mr.prototype,"menuActions",void 0),(0,r.Cg)([d.observable],Mr.prototype,"menuDefinition",void 0),(0,r.Cg)([d.observable],Mr.prototype,"dropDownMenuItems",void 0),(0,r.Cg)([d.observable],Mr.prototype,"provider",void 0),Mr=(0,r.Cg)([(0,d.customElement)({name:"preview-app",template:kr,styles:Ir})],Mr);const Lr={type:"VerticalLayout",elements:[{type:"Group",label:"Group 1",scope:"#/properties/group1",options:{childElements:[{type:"VerticalLayout",elements:[{type:"Control",scope:"#/properties/group1/properties/NAME",label:"Name"}]}]}},{type:"Group",label:"Group 2",scope:"#/properties/group2",options:{childElements:[{type:"LayoutVertical2Columns",elements:[{type:"Control",scope:"#/properties/group2/properties/QUANTITY",label:"Quantity"},{type:"Control",scope:"#/properties/group2/properties/PRICE",label:"Price"},{type:"Control",scope:"#/properties/group2/properties/COUNTERPARTY_ID",options:{data:[{name:"Genesis Global",value:"GENESIS"},{name:"Acme Global",value:"ACME"}],valueField:"value",labelField:"name"},label:"Counterparty"},{type:"Control",scope:"#/properties/group2/properties/INSTRUMENT_ID",options:{data:[{name:"Bond",value:"BOND"},{name:"Equity",value:"EQUITY"}],valueField:"value",labelField:"name"},label:"Instrument"},{type:"Control",scope:"#/properties/group2/properties/SIDE",label:"Side"},{type:"Control",scope:"#/properties/group2/properties/TRADE_DATE",label:"Trade Date"},{type:"Control",scope:"#/properties/group2/properties/ACTIVE",label:"Active"}]}]}}]},Er={type:"object",properties:{group1:{type:"object",properties:{NAME:{type:"string"}}},group2:{type:"object",properties:{QUANTITY:{type:"number"},PRICE:{type:"number"},COUNTERPARTY_ID:{type:"string"},INSTRUMENT_ID:{type:"string"},SIDE:{type:"string",enum:["BUY","SELL"]},TRADE_DATE:{type:"number",format:"date",description:"org.joda.time.DateTime"},ACTIVE:{type:"boolean"}},required:["QUANTITY","PRICE"]}}},Tr={type:"VerticalLayout",elements:[{type:"Control",scope:"#/properties/users",options:{childUiSchema:{type:"HorizontalLayout",elements:[{type:"Control",scope:"#/properties/firstname",label:"First Name"},{type:"Control",scope:"#/properties/lastname",label:"Last Name"},{type:"Control",scope:"#/properties/email",label:"Email"}]}}}]},Rr={type:"object",properties:{users:{type:"array",items:{type:"object",title:"Users",properties:{firstname:{type:"string"},lastname:{type:"string"},email:{type:"string",format:"email"}},required:["firstname"]}}}},_r=d.css`
3432
+ :host {
3433
+ background: var(--fill-color);
3434
+ color: var(--neutral-foreground-rest);
3435
+ flex-direction: column;
3436
+ flex: 1;
3437
+ }
3438
+
3439
+ .wrapper {
3440
+ background: var(--fill-color);
3441
+ display: flex;
3442
+ align-items: center;
3443
+ justify-content: center;
3444
+ }
3445
+
3446
+ .form-container {
3447
+ display: flex;
3448
+ flex-direction: column;
3449
+ align-items: center;
3450
+ height: 100%;
3451
+ padding: 24px 0;
3452
+ }
3453
+
3454
+ foundation-form {
3455
+ min-width: 384px;
3456
+ padding: 24px 0;
3457
+ }
3458
+
3459
+ rapid-design-system-provider {
3460
+ display: inline;
3461
+ }
3462
+ `,Dr=d.html`
3463
+ ${e=>{return t=e.prefix,d.html`
3464
+ <template>
3465
+ <${t}-design-system-provider ${(0,d.ref)("provider")}>
3466
+ <div class="wrapper">
3467
+ <div class="form-container">
3468
+ <h2>Sample Form </h2>
3469
+ <foundation-form
3470
+ :jsonSchema=${e=>e.jsonSchema}
3471
+ :uischema=${e=>e.uischema}
3472
+ :data=${e=>e.editedEntity}
3473
+ design-system-prefix="${e=>e.prefix}"
3474
+ ></foundation-form>
3475
+ <foundation-form
3476
+ :jsonSchema=${e=>e.jsonSchemaArray}
3477
+ :uischema=${e=>e.uiSchemaArray}
3478
+ :data=${e=>e.editedEntityArray}
3479
+ design-system-prefix="${e=>e.prefix}"
3480
+ ></foundation-form>
3481
+ </div>
3482
+ </div>
3483
+ </${t}-design-system-provider>
3484
+ </template>
3485
+ `;var t}}
3486
+ `;let Nr=class extends d.FASTElement{constructor(){super(...arguments),this.jsonSchema=Er,this.uischema=Lr,this.jsonSchemaArray=Rr,this.uiSchemaArray=Tr,this.prefix="rapid",this.editedEntity={group1:{NAME:"Test Name"},group2:{COUNTERPARTY_ID:"GENESIS",INSTRUMENT_ID:"BOND"}},this.editedEntityArray={users:[{firstname:"Max",lastname:"Mustermann",age:25,email:"max@mustermann.com"},{firstname:"John",lastname:"Doe",age:35,email:"john@doe.com"}]}}connectedCallback(){super.connectedCallback(),document.body.addEventListener(jo.STYLES_CHANGED,e=>{this.handleStyleChanges(e)}),document.body.addEventListener(jo.DS_CHANGED,e=>{this.handleDSChanges(e)}),d.DOM.queueUpdate(()=>{p.bodyFont.withDefault(Yo)})}handleStyleChanges(e){const t=e.detail;t&&d.DOM.queueUpdate(()=>{ir(t,this.provider)})}handleDSChanges(e){this.prefix=e.detail.prefix}};(0,r.Cg)([d.observable],Nr.prototype,"jsonSchema",void 0),(0,r.Cg)([d.observable],Nr.prototype,"uischema",void 0),(0,r.Cg)([d.observable],Nr.prototype,"jsonSchemaArray",void 0),(0,r.Cg)([d.observable],Nr.prototype,"uiSchemaArray",void 0),(0,r.Cg)([d.attr],Nr.prototype,"prefix",void 0),(0,r.Cg)([d.observable],Nr.prototype,"provider",void 0),(0,r.Cg)([d.observable],Nr.prototype,"editedEntity",void 0),(0,r.Cg)([d.observable],Nr.prototype,"editedEntityArray",void 0),Nr=(0,r.Cg)([(0,d.customElement)({name:"preview-form",template:Dr,styles:_r})],Nr);var Pr=o(55365),zr=o(39604);const Or=[{athlete:"Michael Phelps",age:23,country:"United States",year:2008,date:"24/08/2008",sport:"Swimming",gold:8,silver:0,bronze:0,total:8,isActionDisabled:!0,BUY_SELL:"BUY"},{athlete:"Michael Phelps",age:19,country:"United States",year:2004,date:"29/08/2004",sport:"Swimming",gold:6,silver:0,bronze:2,total:8,BUY_SELL:"SELL"},{athlete:"Michael Phelps",age:27,country:"United States",year:2012,date:"12/08/2012",sport:"Swimming",gold:4,silver:2,bronze:0,total:6,BUY_SELL:"BUY"},{athlete:"Natalie Coughlin",age:25,country:"United States",year:2008,date:"24/08/2008",sport:"Swimming",gold:1,silver:2,bronze:3,total:6,isActionDisabled:!0,BUY_SELL:"SELL"},{athlete:"Aleksey Nemov",age:24,country:"Russia",year:2e3,date:"01/10/2000",sport:"Gymnastics",gold:2,silver:1,bronze:3,total:6,BUY_SELL:"BUY"},{athlete:"Alicia Coutts",age:24,country:"Australia",year:2012,date:"12/08/2012",sport:"Swimming",gold:1,silver:3,bronze:1,total:5,isActionDisabled:!0,BUY_SELL:"SELL"},{athlete:"Missy Franklin",age:17,country:"United States",year:2012,date:"12/08/2012",sport:"Swimming",gold:4,silver:0,bronze:1,total:5,BUY_SELL:"BUY"},{athlete:"Ryan Lochte",age:27,country:"United States",year:2012,date:"12/08/2012",sport:"Swimming",gold:2,silver:2,bronze:1,total:5,BUY_SELL:"SELL"},{athlete:"Allison Schmitt",age:22,country:"United States",year:2012,date:"12/08/2012",sport:"Swimming",gold:3,silver:1,bronze:1,total:5,BUY_SELL:"BUY"},{athlete:"Natalie Coughlin",age:21,country:"United States",year:2004,date:"29/08/2004",sport:"Swimming",gold:2,silver:2,bronze:1,total:5,BUY_SELL:"SELL"},{athlete:"Ian Thorpe",age:17,country:"Australia",year:2e3,date:"01/10/2000",sport:"Swimming",gold:3,silver:2,bronze:0,total:5,BUY_SELL:"BUY"},{athlete:"Dara Torres",age:33,country:"United States",year:2e3,date:"01/10/2000",sport:"Swimming",gold:2,silver:0,bronze:3,total:5,BUY_SELL:"SELL"},{athlete:"Cindy Klassen",age:26,country:"Canada",year:2006,date:"26/02/2006",sport:"Speed Skating",gold:1,silver:2,bronze:2,total:5,BUY_SELL:"BUY"},{athlete:"Nastia Liukin",age:18,country:"United States",year:2008,date:"24/08/2008",sport:"Gymnastics",gold:1,silver:3,bronze:1,total:5,BUY_SELL:"SELL"},{athlete:"Marit Bjørgen",age:29,country:"Norway",year:2010,date:"28/02/2010",sport:"Cross Country Skiing",gold:3,silver:1,bronze:1,total:5,BUY_SELL:"BUY"},{athlete:"Sun Yang",age:20,country:"China",year:2012,date:"12/08/2012",sport:"Swimming",gold:2,silver:1,bronze:1,total:4,BUY_SELL:"SELL"},{athlete:"Kirsty Coventry",age:24,country:"Zimbabwe",year:2008,date:"24/08/2008",sport:"Swimming",gold:1,silver:3,bronze:0,total:4,BUY_SELL:"BUY"},{athlete:"Libby Lenton-Trickett",age:23,country:"Australia",year:2008,date:"24/08/2008",sport:"Swimming",gold:2,silver:1,bronze:1,total:4,BUY_SELL:"SELL"},{athlete:"Ryan Lochte",age:24,country:"United States",year:2008,date:"24/08/2008",sport:"Swimming",gold:2,silver:0,bronze:2,total:4,BUY_SELL:"BUY"},{athlete:"Inge de Bruijn",age:30,country:"Netherlands",year:2004,date:"29/08/2004",sport:"Swimming",gold:1,silver:1,bronze:2,total:4,BUY_SELL:"SELL"},{athlete:"Petria Thomas",age:28,country:"Australia",year:2004,date:"29/08/2004",sport:"Swimming",gold:3,silver:1,bronze:0,total:4,BUY_SELL:"BUY"},{athlete:"Ian Thorpe",age:21,country:"Australia",year:2004,date:"29/08/2004",sport:"Swimming",gold:2,silver:1,bronze:1,total:4,BUY_SELL:"SELL"},{athlete:"Inge de Bruijn",age:27,country:"Netherlands",year:2e3,date:"01/10/2000",sport:"Swimming",gold:3,silver:1,bronze:0,total:4,BUY_SELL:"BUY"},{athlete:"Gary Hall Jr.",age:25,country:"United States",year:2e3,date:"01/10/2000",sport:"Swimming",gold:2,silver:1,bronze:1,total:4,BUY_SELL:"SELL"},{athlete:"Michael Klim",age:23,country:"Australia",year:2e3,date:"01/10/2000",sport:"Swimming",gold:2,silver:2,bronze:0,total:4,BUY_SELL:"BUY"},{athlete:"Susie O'Neill",age:27,country:"Australia",year:2e3,date:"01/10/2000",sport:"Swimming",gold:1,silver:3,bronze:0,total:4,BUY_SELL:"SELL"},{athlete:"Jenny Thompson",age:27,country:"United States",year:2e3,date:"01/10/2000",sport:"Swimming",gold:3,silver:0,bronze:1,total:4,BUY_SELL:"BUY"},{athlete:"Pieter van den Hoogenband",age:22,country:"Netherlands",year:2e3,date:"01/10/2000",sport:"Swimming",gold:2,silver:0,bronze:2,total:4,BUY_SELL:"SELL"},{athlete:"An Hyeon-Su",age:20,country:"South Korea",year:2006,date:"26/02/2006",sport:"Short-Track Speed Skating",gold:3,silver:0,bronze:1,total:4,BUY_SELL:"BUY"},{athlete:"Aliya Mustafina",age:17,country:"Russia",year:2012,date:"12/08/2012",sport:"Gymnastics",gold:1,silver:1,bronze:2,total:4,BUY_SELL:"SELL"},{athlete:"Shawn Johnson",age:16,country:"United States",year:2008,date:"24/08/2008",sport:"Gymnastics",gold:1,silver:3,bronze:0,total:4,BUY_SELL:"BUY"}],Fr=d.css`
3487
+ :host {
3488
+ background: var(--fill-color);
3489
+ color: var(--neutral-foreground-rest);
3490
+ flex-direction: column;
3491
+ flex: 1;
3492
+ }
3493
+
3494
+ rapid-design-system-provider {
3495
+ display: inline;
3496
+ }
3497
+
3498
+ .grid-height {
3499
+ height: 100%;
3500
+ }
3501
+ `,jr=d.html`
3502
+ ${e=>{return t=e.prefix,d.html`
3503
+ <template>
3504
+ <${t}-design-system-provider ${(0,d.ref)("provider")}>
3505
+ <div class="grid-height">
3506
+ <${t}-grid-pro
3507
+ ${(0,d.ref)("grid")}
3508
+ rowHeight="36"
3509
+ headerHeight="36"
3510
+ singleClickEdit="true"
3511
+ persist-column-state-key="${t}-grid-pro-state"
3512
+ >
3513
+ ${(0,d.repeat)(e=>e.multipleCustomFoundationColumnConfigs,d.html`
3514
+ <grid-pro-column :definition=${e=>e}>
3515
+ ${(0,d.when)(e=>e.cellRenderer,d.html`
3516
+ <grid-pro-cell
3517
+ :renderer=${e=>e.cellRenderer}
3518
+ :rendererParams=${e=>e.cellRendererParams}
3519
+ ></grid-pro-cell>
3520
+ `)}
3521
+ </grid-pro-column>
3522
+ `)}
3523
+ <grid-pro-column :definition=${e=>e.multipleActionsMenuSlottedConfig}></grid-pro-column>
3524
+ <grid-pro-column :definition=${e=>e.singleActionSlottedConfig}></grid-pro-column>
3525
+ </${t}-grid-pro>
3526
+ </div>
3527
+ </${t}-design-system-provider>
3528
+ </template>
3529
+ `;var t}}
3530
+ `;let Ur=class extends d.FASTElement{constructor(){super(...arguments),this.prefix="rapid",this.rowData=[...Or],this.columnDefs=[{headerName:"#",colId:"rowNum",valueGetter:"node.id",width:80,pinned:"left"},{headerName:"Athlete",field:"athlete",width:150,pinned:"left"},{headerName:"Age",field:"age",width:90,pinned:"left"},{headerName:"Country",field:"country",width:150},{headerName:"Year",field:"year",width:90},{field:"BUY_SELL",headerName:"B/S",width:100,cellRenderer:Pr.IX.statusPill,cellRendererParams:e=>({text:e.value,backgroundColor:"BUY"===e.value||"LONG"===e.value?"green":"red"})},{headerName:"Date",field:"date",width:110,filter:"agDateColumnFilter",filterParams:{buttons:["apply","reset"],browserDatePicker:!0,comparator:(e,t)=>{if(null==t)return-1;const o=t.split("/"),r=new Date(Number(o[2]),Number(o[1])-1,Number(o[0]));return e.getTime()===r.getTime()?0:r<e?-1:r>e?1:0}}},{headerName:"Sport",field:"sport",width:150,editable:!0},{headerName:"Gold",field:"gold",width:100},{headerName:"Silver",field:"silver",width:100},{headerName:"Bronze",field:"bronze",width:100},{headerName:"Total",field:"total",width:100,pinned:"right"}],this.gridOptions={defaultColDef:{resizable:!0,filter:!0},debug:!1,columnDefs:this.columnDefs,rowData:this.rowData},this.myCustomCheckboxRenderer=e=>2012===e.value?`<div><span style="color: var(--warning-color); font-weight: bold;">${e.value}</span></div>`:e.value,this.multipleCustomFoundationColumnConfigs=[{headerName:"Country",field:"country",cellRenderer:Pr.IX.boolean},{headerName:"Year",field:"year",cellRenderer:this.myCustomCheckboxRenderer}],this.multipleActions=[{name:"View",callback:e=>console.log("VIEWW!!!",e)},{name:"Delete",callback:e=>console.log("DELETE!!!",e)},{name:"Edit",callback:e=>console.log("EDIT!!!",e)},{name:"Wait",callback:e=>console.log("WHAT???",e)}],this.multipleActionsMenuSlottedConfig=(0,zr.Al)(this.multipleActions,{headerName:"Multiple Actions",width:140},"⋮",!0,"stealth"),this.singleActionSlottedConfig={headerName:"Single Action",width:200,cellRenderer:Pr.IX.action,cellRendererParams:{actionClick:e=>console.log("CLICKED ON SINGLE ACTION!!!!",e),actionName:"Single Action",appearance:"accent",isDisabled:e=>!!e.isActionDisabled,dataTestId:"singleActionTestId#",uniqueFieldName:"UNIQUE_ID"}}}setGridOptions(){this.grid.gridOptions=this.gridOptions}connectedCallback(){super.connectedCallback(),document.body.addEventListener(jo.STYLES_CHANGED,e=>{this.handleStyleChanges(e)}),document.body.addEventListener(jo.DS_CHANGED,e=>{this.handleDSChanges(e)}),d.DOM.queueUpdate(()=>{this.setGridOptions(),p.bodyFont.withDefault(Yo)})}handleStyleChanges(e){const t=e.detail;t&&d.DOM.queueUpdate(()=>{ir(t,this.provider)})}handleDSChanges(e){this.prefix=e.detail.prefix,d.DOM.queueUpdate(()=>{this.setGridOptions()})}};(0,r.Cg)([d.observable],Ur.prototype,"grid",void 0),(0,r.Cg)([d.attr],Ur.prototype,"prefix",void 0),(0,r.Cg)([d.observable],Ur.prototype,"provider",void 0),(0,r.Cg)([d.observable],Ur.prototype,"rowData",void 0),(0,r.Cg)([d.observable],Ur.prototype,"columnDefs",void 0),(0,r.Cg)([d.observable],Ur.prototype,"gridOptions",void 0),Ur=(0,r.Cg)([(0,d.customElement)({name:"preview-grid",template:jr,styles:Fr})],Ur);const Br=d.html`
3531
+ <template>
3532
+ <rapid-tabs>
3533
+ <rapid-tab slot="tab">Components</rapid-tab>
3534
+ <rapid-tab slot="tab">Typography</rapid-tab>
3535
+ <rapid-tab slot="tab">Colors</rapid-tab>
3536
+ <rapid-tab slot="tab">Form</rapid-tab>
3537
+ <rapid-tab slot="tab">Grid</rapid-tab>
3538
+ <rapid-tab slot="tab">Sample App</rapid-tab>
3539
+ <rapid-tab-panel slot="tabpanel">
3540
+ <preview-components></preview-components>
3541
+ </rapid-tab-panel>
3542
+ <rapid-tab-panel slot="tabpanel">
3543
+ <typography-tokens></typography-tokens>
3544
+ </rapid-tab-panel>
3545
+ <rapid-tab-panel slot="tabpanel">
3546
+ <div class="wrapper">
3547
+ <color-palette type="neutral"></color-palette>
3548
+ <color-palette type="accent"></color-palette>
3549
+ <color-tokens></color-tokens>
3550
+ </div>
3551
+ </rapid-tab-panel>
3552
+ <rapid-tab-panel slot="tabpanel">
3553
+ <preview-form></preview-form>
3554
+ </rapid-tab-panel>
3555
+ <rapid-tab-panel slot="tabpanel">
3556
+ <preview-grid></preview-grid>
3557
+ </rapid-tab-panel>
3558
+ <rapid-tab-panel slot="tabpanel">
3559
+ <preview-app></preview-app>
3560
+ </rapid-tab-panel>
3561
+ </rapid-tabs>
3562
+ </template>
3563
+ `;let Hr=class extends d.FASTElement{};Hr=(0,r.Cg)([(0,d.customElement)({name:"design-system-preview",template:Br,styles:Ar})],Hr),(0,Uo.provideDesignSystem)().register(Uo.baseComponents,Bo.rapidGridComponents,Fo)}}]);
3564
+ //# sourceMappingURL=65.a6e8a28b67bf967793cd1557e33cc6c3.js.map