@orangelogic/design-system 2.86.0 → 2.89.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/library/chunks/{color-swatch-group.DPGjdQIL.js → color-swatch-group.BaMEIlzq.js} +1 -1
- package/library/chunks/{list-editor.DnLRd7ks.js → list-editor.DsI3-bUG.js} +1 -1
- package/library/chunks/{table.vctaA5cg.js → table.CGTmaN_x.js} +1887 -1879
- package/library/components/asset-link-format.js +151 -138
- package/library/components/atoms.js +1 -1
- package/library/components/color-swatch-group.js +2 -2
- package/library/components/drawer.js +55 -50
- package/library/components/list-editor.js +2 -2
- package/library/components/menu.js +25 -24
- package/library/components/molecules.js +1 -1
- package/library/components/organisms.js +1 -1
- package/library/components/select.js +17 -17
- package/library/components/table.js +1 -1
- package/library/components/types.js +4 -4
- package/library/package.json +1 -1
- package/library/packages/atoms/src/components/drawer/drawer.d.ts +1 -0
- package/library/packages/atoms/src/components/menu/menu.d.ts +2 -1
- package/library/packages/types/src/menu.d.ts +4 -0
- package/library/packages/types/src/table.d.ts +7 -1
- package/library/react-web-component.d.ts +2 -2
- package/package.json +1 -1
|
@@ -5,23 +5,23 @@ import { c as z } from "../chunks/custom-element.L4WJXn1j.js";
|
|
|
5
5
|
import { w as v } from "../chunks/event.mFzZi4sr.js";
|
|
6
6
|
import { L as O } from "../chunks/i18n.CgwQHLcP.js";
|
|
7
7
|
import { M as $ } from "../chunks/modal.U1QltQKe.js";
|
|
8
|
-
import { l as m, u
|
|
8
|
+
import { l as m, u } from "../chunks/scroll.xtO5yojm.js";
|
|
9
9
|
import { H as B } from "../chunks/slot.j5oheLJC.js";
|
|
10
10
|
import { w as _ } from "../chunks/watch.BCJD77bD.js";
|
|
11
11
|
import { i as P, x as y } from "../chunks/lit-element.jLBm65_O.js";
|
|
12
12
|
import { r as S } from "../chunks/state.CSDxrqLd.js";
|
|
13
|
-
import { e as
|
|
13
|
+
import { e as w } from "../chunks/query.BBf1UFkC.js";
|
|
14
14
|
import { e as g } from "../chunks/class-map.BiVq-cVR.js";
|
|
15
15
|
import { o as b } from "../chunks/if-defined.BRoBj_Rp.js";
|
|
16
16
|
import { n as A } from "../chunks/when.Dr1es41R.js";
|
|
17
17
|
import { c as x } from "../chunks/capitalize.CNStXZBq.js";
|
|
18
|
-
import { s as
|
|
18
|
+
import { s as r, g as c } from "../chunks/animation-registry.HmpwNuGH.js";
|
|
19
19
|
import { C as q } from "../chunks/icon-button.BpwPU4Vg.js";
|
|
20
20
|
const D = P`:host{--size:25rem;--header-spacing:var(--cx-spacing-large);--body-spacing:var(--cx-spacing-large);--footer-spacing:var(--cx-spacing-large);--font-family:var(--cx-font-sans);display:contents}.drawer{top:0;pointer-events:none;width:0;height:0;inset-inline-start:0;overflow:hidden}.drawer--open{width:100%;height:100%}.drawer--persistent.drawer--open{width:var(--size);min-width:var(--size)}.drawer--contained{z-index:initial;position:absolute}.drawer--persistent{position:relative}.drawer--fixed{z-index:var(--cx-z-index-drawer);position:fixed}.drawer__panel{z-index:2;background-color:var(--cx-panel-background-color);max-width:100%;max-height:100%;box-shadow:var(--cx-shadow-large);pointer-events:all;flex-direction:column;display:flex;position:absolute;overflow:auto}.drawer__panel:focus{outline:none}.drawer--top .drawer__panel{top:0;inset-inline-end:auto;bottom:auto;width:100%;height:var(--size);inset-inline-start:0}.drawer--end .drawer__panel{top:0;inset-inline-end:0;bottom:auto;width:var(--size);height:100%;inset-inline-start:auto}.drawer--bottom .drawer__panel{top:auto;inset-inline-end:auto;bottom:0;width:100%;height:var(--size);inset-inline-start:0}.drawer--start .drawer__panel{top:0;inset-inline-end:auto;bottom:auto;width:var(--size);height:100%;inset-inline-start:0}.drawer__header{gap:var(--cx-spacing-small);padding:var(--header-spacing);border-bottom:solid 1px var(--cx-input-border-color);font-family:var(--font-family);display:flex}.drawer__title{font:inherit;font-size:var(--cx-font-size-large);font-weight:var(--cx-font-weight-semibold);line-height:var(--cx-line-height-medium);flex:auto;align-items:center;margin:0;display:flex}.drawer__header-actions{justify-content:end;gap:var(--cx-spacing-2x-small);flex-wrap:wrap;flex-shrink:0;display:flex}.drawer__header-actions cx-icon-button,.drawer__header-actions ::slotted(cx-icon-button){font-size:var(--cx-font-size-medium);flex:none;align-items:center;display:flex}.drawer__body{padding:var(--body-spacing);-webkit-overflow-scrolling:touch;font-family:var(--font-family);flex:auto;display:block;overflow:auto}.drawer__footer{text-align:right;padding:var(--footer-spacing);font-family:var(--font-family)}.drawer__footer ::slotted(cx-button:not(:last-of-type)){margin-inline-end:var(--cx-spacing-x-small)}.drawer:not(.drawer--has-footer) .drawer__footer{display:none}.drawer__overlay{background-color:var(--cx-overlay-background-color);pointer-events:all;display:block;position:fixed;inset:0}.drawer--contained .drawer__overlay{opacity:0;position:absolute}.drawer__overlay--disabled{display:none}@media (forced-colors:active){.drawer__panel{border:solid 1px var(--cx-color-neutral-0)}}`;
|
|
21
|
-
var
|
|
22
|
-
for (var s = l > 1 ? void 0 : l ?
|
|
23
|
-
(f = e[h]) && (s = (l ? f(
|
|
24
|
-
return l && s &&
|
|
21
|
+
var E = Object.defineProperty, L = Object.getOwnPropertyDescriptor, i = (e, a, o, l) => {
|
|
22
|
+
for (var s = l > 1 ? void 0 : l ? L(a, o) : a, h = e.length - 1, f; h >= 0; h--)
|
|
23
|
+
(f = e[h]) && (s = (l ? f(a, o, s) : f(s)) || s);
|
|
24
|
+
return l && s && E(a, o, s), s;
|
|
25
25
|
};
|
|
26
26
|
let t = class extends C {
|
|
27
27
|
constructor() {
|
|
@@ -33,7 +33,7 @@ let t = class extends C {
|
|
|
33
33
|
this.drawer.hidden = !this.open, this.open && (this.addOpenListeners(), this.contained || (this.modal.activate(), m(this)));
|
|
34
34
|
}
|
|
35
35
|
disconnectedCallback() {
|
|
36
|
-
super.disconnectedCallback(),
|
|
36
|
+
super.disconnectedCallback(), u(this), this.removeOpenListeners();
|
|
37
37
|
}
|
|
38
38
|
willUpdate(e) {
|
|
39
39
|
if (super.willUpdate(e), !e.has("open"))
|
|
@@ -45,10 +45,10 @@ let t = class extends C {
|
|
|
45
45
|
cancelable: !0,
|
|
46
46
|
detail: { source: e }
|
|
47
47
|
}).defaultPrevented) {
|
|
48
|
-
const
|
|
48
|
+
const o = c(this, "drawer.denyClose", {
|
|
49
49
|
dir: this.localize.dir()
|
|
50
50
|
});
|
|
51
|
-
d(this.panel,
|
|
51
|
+
d(this.panel, o.keyframes, o.options);
|
|
52
52
|
return;
|
|
53
53
|
}
|
|
54
54
|
this.hide();
|
|
@@ -59,6 +59,11 @@ let t = class extends C {
|
|
|
59
59
|
removeOpenListeners() {
|
|
60
60
|
document.removeEventListener("keydown", this.handleDocumentKeyDown), this.closeWatcher?.destroy();
|
|
61
61
|
}
|
|
62
|
+
resetMultipleMenus() {
|
|
63
|
+
[...this.querySelectorAll("cx-menu")].forEach((a) => {
|
|
64
|
+
a.variant === "multiple" && a.resetActiveMenu();
|
|
65
|
+
});
|
|
66
|
+
}
|
|
62
67
|
async handleOpenChange() {
|
|
63
68
|
if (this.open) {
|
|
64
69
|
this.emit("cx-show"), this.addOpenListeners(), this.originalTrigger = document.activeElement, this.contained || (this.modal.activate(), m(this));
|
|
@@ -73,25 +78,25 @@ let t = class extends C {
|
|
|
73
78
|
preventScroll: !0
|
|
74
79
|
}) : this.panel.focus({ preventScroll: !0 })), e && e.setAttribute("autofocus", "");
|
|
75
80
|
});
|
|
76
|
-
const
|
|
81
|
+
const a = c(
|
|
77
82
|
this,
|
|
78
83
|
`drawer.show${x(this.placement)}`,
|
|
79
84
|
{
|
|
80
85
|
dir: this.localize.dir()
|
|
81
86
|
}
|
|
82
|
-
),
|
|
87
|
+
), o = c(this, "drawer.overlay.show", {
|
|
83
88
|
dir: this.localize.dir()
|
|
84
89
|
});
|
|
85
90
|
await Promise.all([
|
|
86
|
-
d(this.panel,
|
|
91
|
+
d(this.panel, a.keyframes, a.options),
|
|
87
92
|
this.contained ? Promise.resolve() : d(
|
|
88
93
|
this.overlay,
|
|
89
|
-
|
|
90
|
-
|
|
94
|
+
o.keyframes,
|
|
95
|
+
o.options
|
|
91
96
|
)
|
|
92
97
|
]), this.emit("cx-after-show");
|
|
93
98
|
} else {
|
|
94
|
-
this.emit("cx-hide"), this.removeOpenListeners(), this.contained || (this.modal.deactivate(),
|
|
99
|
+
this.emit("cx-hide"), this.removeOpenListeners(), this.contained || (this.modal.deactivate(), u(this)), await Promise.all([
|
|
95
100
|
p(this.drawer),
|
|
96
101
|
p(this.overlay)
|
|
97
102
|
]);
|
|
@@ -101,14 +106,14 @@ let t = class extends C {
|
|
|
101
106
|
{
|
|
102
107
|
dir: this.localize.dir()
|
|
103
108
|
}
|
|
104
|
-
),
|
|
109
|
+
), a = c(this, "drawer.overlay.hide", {
|
|
105
110
|
dir: this.localize.dir()
|
|
106
111
|
});
|
|
107
112
|
await Promise.all([
|
|
108
113
|
(this.contained ? Promise.resolve() : d(
|
|
109
114
|
this.overlay,
|
|
110
|
-
|
|
111
|
-
|
|
115
|
+
a.keyframes,
|
|
116
|
+
a.options
|
|
112
117
|
)).then(() => {
|
|
113
118
|
this.overlay.hidden = !0;
|
|
114
119
|
}),
|
|
@@ -120,12 +125,12 @@ let t = class extends C {
|
|
|
120
125
|
this.panel.hidden = !0;
|
|
121
126
|
})
|
|
122
127
|
]), this.drawer.hidden = !0, this.isClosing = !1, this.overlay.hidden = !1, this.panel.hidden = !1;
|
|
123
|
-
const
|
|
124
|
-
typeof
|
|
128
|
+
const o = this.originalTrigger;
|
|
129
|
+
typeof o?.focus == "function" && setTimeout(() => o.focus()), this.resetMultipleMenus(), this.emit("cx-after-hide");
|
|
125
130
|
}
|
|
126
131
|
}
|
|
127
132
|
handleNoModalChange() {
|
|
128
|
-
this.open && !this.contained && (this.modal.activate(), m(this)), this.open && this.contained && (this.modal.deactivate(),
|
|
133
|
+
this.open && !this.contained && (this.modal.activate(), m(this)), this.open && this.contained && (this.modal.deactivate(), u(this));
|
|
129
134
|
}
|
|
130
135
|
/** Shows the drawer. */
|
|
131
136
|
async show() {
|
|
@@ -168,63 +173,63 @@ let t = class extends C {
|
|
|
168
173
|
};
|
|
169
174
|
t.styles = [k, D];
|
|
170
175
|
t.dependencies = { "cx-icon-button": q };
|
|
171
|
-
|
|
172
|
-
|
|
176
|
+
i([
|
|
177
|
+
w(".drawer")
|
|
173
178
|
], t.prototype, "drawer", 2);
|
|
174
|
-
|
|
175
|
-
|
|
179
|
+
i([
|
|
180
|
+
w(".drawer__panel")
|
|
176
181
|
], t.prototype, "panel", 2);
|
|
177
|
-
|
|
178
|
-
|
|
182
|
+
i([
|
|
183
|
+
w(".drawer__overlay")
|
|
179
184
|
], t.prototype, "overlay", 2);
|
|
180
|
-
|
|
185
|
+
i([
|
|
181
186
|
S()
|
|
182
187
|
], t.prototype, "isClosing", 2);
|
|
183
|
-
|
|
188
|
+
i([
|
|
184
189
|
n({ reflect: !0, type: Boolean })
|
|
185
190
|
], t.prototype, "open", 2);
|
|
186
|
-
|
|
191
|
+
i([
|
|
187
192
|
n({ reflect: !0 })
|
|
188
193
|
], t.prototype, "label", 2);
|
|
189
|
-
|
|
194
|
+
i([
|
|
190
195
|
n({ reflect: !0 })
|
|
191
196
|
], t.prototype, "placement", 2);
|
|
192
|
-
|
|
197
|
+
i([
|
|
193
198
|
n({ reflect: !0, type: Boolean })
|
|
194
199
|
], t.prototype, "contained", 2);
|
|
195
|
-
|
|
200
|
+
i([
|
|
196
201
|
n({ attribute: "no-header", reflect: !0, type: Boolean })
|
|
197
202
|
], t.prototype, "noHeader", 2);
|
|
198
|
-
|
|
203
|
+
i([
|
|
199
204
|
n({ reflect: !0, type: String })
|
|
200
205
|
], t.prototype, "variant", 2);
|
|
201
|
-
|
|
206
|
+
i([
|
|
202
207
|
n({ attribute: "no-close-button", reflect: !0, type: Boolean })
|
|
203
208
|
], t.prototype, "noCloseButton", 2);
|
|
204
|
-
|
|
209
|
+
i([
|
|
205
210
|
_("open", { waitUntilFirstUpdate: !0 })
|
|
206
211
|
], t.prototype, "handleOpenChange", 1);
|
|
207
|
-
|
|
212
|
+
i([
|
|
208
213
|
_("contained", { waitUntilFirstUpdate: !0 })
|
|
209
214
|
], t.prototype, "handleNoModalChange", 1);
|
|
210
|
-
t =
|
|
215
|
+
t = i([
|
|
211
216
|
z("cx-drawer")
|
|
212
217
|
], t);
|
|
213
|
-
|
|
218
|
+
r("drawer.showTop", {
|
|
214
219
|
keyframes: [
|
|
215
220
|
{ opacity: 0, translate: "0 -100%" },
|
|
216
221
|
{ opacity: 1, translate: "0 0" }
|
|
217
222
|
],
|
|
218
223
|
options: { duration: 250, easing: "ease" }
|
|
219
224
|
});
|
|
220
|
-
|
|
225
|
+
r("drawer.hideTop", {
|
|
221
226
|
keyframes: [
|
|
222
227
|
{ opacity: 1, translate: "0 0" },
|
|
223
228
|
{ opacity: 0, translate: "0 -100%" }
|
|
224
229
|
],
|
|
225
230
|
options: { duration: 250, easing: "ease" }
|
|
226
231
|
});
|
|
227
|
-
|
|
232
|
+
r("drawer.showEnd", {
|
|
228
233
|
keyframes: [
|
|
229
234
|
{ opacity: 0, translate: "100%" },
|
|
230
235
|
{ opacity: 1, translate: "0" }
|
|
@@ -235,7 +240,7 @@ i("drawer.showEnd", {
|
|
|
235
240
|
{ opacity: 1, translate: "0" }
|
|
236
241
|
]
|
|
237
242
|
});
|
|
238
|
-
|
|
243
|
+
r("drawer.hideEnd", {
|
|
239
244
|
keyframes: [
|
|
240
245
|
{ opacity: 1, translate: "0" },
|
|
241
246
|
{ opacity: 0, translate: "100%" }
|
|
@@ -246,21 +251,21 @@ i("drawer.hideEnd", {
|
|
|
246
251
|
{ opacity: 0, translate: "-100%" }
|
|
247
252
|
]
|
|
248
253
|
});
|
|
249
|
-
|
|
254
|
+
r("drawer.showBottom", {
|
|
250
255
|
keyframes: [
|
|
251
256
|
{ opacity: 0, translate: "0 100%" },
|
|
252
257
|
{ opacity: 1, translate: "0 0" }
|
|
253
258
|
],
|
|
254
259
|
options: { duration: 250, easing: "ease" }
|
|
255
260
|
});
|
|
256
|
-
|
|
261
|
+
r("drawer.hideBottom", {
|
|
257
262
|
keyframes: [
|
|
258
263
|
{ opacity: 1, translate: "0 0" },
|
|
259
264
|
{ opacity: 0, translate: "0 100%" }
|
|
260
265
|
],
|
|
261
266
|
options: { duration: 250, easing: "ease" }
|
|
262
267
|
});
|
|
263
|
-
|
|
268
|
+
r("drawer.showStart", {
|
|
264
269
|
keyframes: [
|
|
265
270
|
{ opacity: 0, translate: "-100%" },
|
|
266
271
|
{ opacity: 1, translate: "0" }
|
|
@@ -271,7 +276,7 @@ i("drawer.showStart", {
|
|
|
271
276
|
{ opacity: 1, translate: "0" }
|
|
272
277
|
]
|
|
273
278
|
});
|
|
274
|
-
|
|
279
|
+
r("drawer.hideStart", {
|
|
275
280
|
keyframes: [
|
|
276
281
|
{ opacity: 1, translate: "0" },
|
|
277
282
|
{ opacity: 0, translate: "-100%" }
|
|
@@ -282,15 +287,15 @@ i("drawer.hideStart", {
|
|
|
282
287
|
{ opacity: 0, translate: "100%" }
|
|
283
288
|
]
|
|
284
289
|
});
|
|
285
|
-
|
|
290
|
+
r("drawer.denyClose", {
|
|
286
291
|
keyframes: [{ scale: 1 }, { scale: 1.01 }, { scale: 1 }],
|
|
287
292
|
options: { duration: 250 }
|
|
288
293
|
});
|
|
289
|
-
|
|
294
|
+
r("drawer.overlay.show", {
|
|
290
295
|
keyframes: [{ opacity: 0 }, { opacity: 1 }],
|
|
291
296
|
options: { duration: 250 }
|
|
292
297
|
});
|
|
293
|
-
|
|
298
|
+
r("drawer.overlay.hide", {
|
|
294
299
|
keyframes: [{ opacity: 1 }, { opacity: 0 }],
|
|
295
300
|
options: { duration: 250 }
|
|
296
301
|
});
|
|
@@ -9,7 +9,7 @@ import "./radio.js";
|
|
|
9
9
|
import "./radio-group.js";
|
|
10
10
|
import "./select.js";
|
|
11
11
|
import "./space.js";
|
|
12
|
-
import "../chunks/table.
|
|
12
|
+
import "../chunks/table.CGTmaN_x.js";
|
|
13
13
|
import "../chunks/typography.DJC_UXgs.js";
|
|
14
14
|
import "../chunks/lib-cortex-element.CVMmyPMC.js";
|
|
15
15
|
import "./dynamic-select.js";
|
|
@@ -18,7 +18,7 @@ import "../chunks/custom-element.L4WJXn1j.js";
|
|
|
18
18
|
import "../chunks/debounce.DaHuiSGU.js";
|
|
19
19
|
import "../chunks/i18n.CgwQHLcP.js";
|
|
20
20
|
import "../chunks/watch.BCJD77bD.js";
|
|
21
|
-
import { c as E, C as F } from "../chunks/list-editor.
|
|
21
|
+
import { c as E, C as F } from "../chunks/list-editor.DsI3-bUG.js";
|
|
22
22
|
import "../chunks/lit-element.jLBm65_O.js";
|
|
23
23
|
import "../chunks/state.CSDxrqLd.js";
|
|
24
24
|
import "../chunks/query.BBf1UFkC.js";
|
|
@@ -1,24 +1,25 @@
|
|
|
1
|
-
import { n as c, C as
|
|
2
|
-
import { c as
|
|
3
|
-
import { c as
|
|
4
|
-
import { L as
|
|
5
|
-
import { i as
|
|
6
|
-
import { r as
|
|
7
|
-
import { e as
|
|
8
|
-
import { n as
|
|
9
|
-
import
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
1
|
+
import { n as c, C as p } from "../chunks/lib-cortex-element.CVMmyPMC.js";
|
|
2
|
+
import { c as b } from "../chunks/component.styles.CRO4Odto.js";
|
|
3
|
+
import { c as g } from "../chunks/custom-element.L4WJXn1j.js";
|
|
4
|
+
import { L as v } from "../chunks/i18n.CgwQHLcP.js";
|
|
5
|
+
import { i as y, x as f } from "../chunks/lit-element.jLBm65_O.js";
|
|
6
|
+
import { r as w } from "../chunks/state.CSDxrqLd.js";
|
|
7
|
+
import { e as x } from "../chunks/query.BBf1UFkC.js";
|
|
8
|
+
import { n as M } from "../chunks/when.Dr1es41R.js";
|
|
9
|
+
import k from "./menu-item.js";
|
|
10
|
+
var d = /* @__PURE__ */ ((e) => (e.Default = "default", e.Multiple = "multiple", e))(d || {});
|
|
11
|
+
const A = y`:host{background:var(--cx-panel-background-color);border:solid var(--cx-panel-border-width) var(--cx-panel-border-color);border-radius:var(--cx-border-radius-large);padding:var(--cx-spacing-x-small) 0;--divider-color:var(--cx-panel-border-color);--divider-width:var(--cx-panel-border-width);--divider-spacing:var(--cx-spacing-x-small);display:block;position:relative;overflow:auto}:host([horizontal]){padding:0 var(--cx-spacing-x-small);flex-wrap:wrap;justify-content:space-between;display:flex}::slotted(cx-divider){--color:var(--divider-color);--width:var(--divider-width);--spacing:var(--divider-spacing)}::slotted([data-alternating-grouping]):before{content:" ";background-color:var(--divider-color);margin:var(--divider-spacing) 0;height:var(--divider-width);display:block}::slotted([data-alternating-grouping=horizontal]):before{height:100%;margin:0 var(--divider-spacing);width:var(--divider-width);display:inline-block}:host([horizontal]) ::slotted(cx-menu-section){flex-wrap:wrap;justify-content:space-between;display:flex}:host([horizontal]) ::slotted(cx-menu-item){display:flex}:host([variant=multiple]){position:relative;overflow:hidden}:host([variant=multiple]) ::slotted(cx-menu[name]){opacity:0;pointer-events:none;transition:opacity var(--cx-transition-fast) ease-in-out, transform var(--cx-transition-medium) ease-in-out;border:none;top:0;left:0;transform:translate(-50%);position:absolute!important}:host([variant=multiple]) ::slotted(cx-menu[active]){opacity:1;pointer-events:auto;transform:translate(0)}.back__button::part(checked-icon),.back__button::part(submenu-icon){display:none}.back__divider{--spacing:var(--cx-spacing-x-small)}`;
|
|
12
|
+
var I = Object.defineProperty, C = Object.getOwnPropertyDescriptor, u = (e, t, r, i) => {
|
|
13
|
+
for (var o = i > 1 ? void 0 : i ? C(t, r) : t, h = e.length - 1, n; h >= 0; h--)
|
|
13
14
|
(n = e[h]) && (o = (i ? n(t, r, o) : n(o)) || o);
|
|
14
|
-
return i && o &&
|
|
15
|
+
return i && o && I(t, r, o), o;
|
|
15
16
|
};
|
|
16
17
|
function m(e) {
|
|
17
18
|
return e.tagName.toLowerCase() === "cx-menu" && e instanceof l && e.getAttribute("role") === "menu";
|
|
18
19
|
}
|
|
19
|
-
let l = class extends
|
|
20
|
+
let l = class extends p {
|
|
20
21
|
constructor() {
|
|
21
|
-
super(...arguments), this.localize = new
|
|
22
|
+
super(...arguments), this.localize = new v(this), this.horizontal = !1, this.variant = d.Default, this.active = !1, this.name = "", this.back = "", this.default = !1, this.bubbleKeyDown = !1, this.ignoredKeys = [], this.disabledTabLoop = !1, this.resizeObserver = null, this.slotMutationObserver = null;
|
|
22
23
|
}
|
|
23
24
|
connectedCallback() {
|
|
24
25
|
super.connectedCallback(), this.setAttribute("role", "menu"), this.slotMutationObserver = new MutationObserver(() => this.handleSlotChange()), this.slotMutationObserver.observe(this, {
|
|
@@ -31,7 +32,7 @@ let l = class extends f {
|
|
|
31
32
|
super.disconnectedCallback(), this.resizeObserver && (this.resizeObserver.disconnect(), this.resizeObserver = null), this.slotMutationObserver && (this.slotMutationObserver.disconnect(), this.slotMutationObserver = null);
|
|
32
33
|
}
|
|
33
34
|
runFirstUpdated() {
|
|
34
|
-
if (this.variant ===
|
|
35
|
+
if (this.variant === d.Multiple) {
|
|
35
36
|
const e = this.getAllSubMenus();
|
|
36
37
|
this.setActiveMenu(e[0]?.name ?? ""), this.updateComplete.then(() => {
|
|
37
38
|
this.adjustMenuSize();
|
|
@@ -72,7 +73,7 @@ let l = class extends f {
|
|
|
72
73
|
].includes(e.key)) {
|
|
73
74
|
const t = this.getAllItems(), r = this.getCurrentItem();
|
|
74
75
|
let i = r ? t.indexOf(r) : 0;
|
|
75
|
-
if (["ArrowLeft", "ArrowRight"].includes(e.key) && !this.bubbleKeyDown && !(this.parentElement instanceof l) && !(this.parentElement instanceof
|
|
76
|
+
if (["ArrowLeft", "ArrowRight"].includes(e.key) && !this.bubbleKeyDown && !(this.parentElement instanceof l) && !(this.parentElement instanceof k) && e.stopPropagation(), t.length > 0) {
|
|
76
77
|
const o = this.horizontal ? e.key === "ArrowRight" || i === t.length - 1 && e.key === "ArrowDown" : e.key === "ArrowDown", h = this.horizontal ? e.key === "ArrowLeft" || i === 0 && e.key === "ArrowUp" : e.key === "ArrowUp";
|
|
77
78
|
if (["ArrowRight", "ArrowDown", "ArrowLeft", "ArrowUp"].includes(
|
|
78
79
|
e.key
|
|
@@ -265,16 +266,16 @@ let l = class extends f {
|
|
|
265
266
|
});
|
|
266
267
|
}
|
|
267
268
|
render() {
|
|
268
|
-
const e =
|
|
269
|
+
const e = M(
|
|
269
270
|
this.back,
|
|
270
|
-
() =>
|
|
271
|
+
() => f`<slot name="back-button" role="menuitem" menu=${this.back}><cx-menu-item part="back-button" class="back__button" menu=${this.back}><cx-icon slot="prefix" name="chevron_left"></cx-icon>${this.localize.term("back")}</cx-menu-item><cx-divider class="back__divider"></cx-divider></slot>`
|
|
271
272
|
);
|
|
272
|
-
return this.variant ===
|
|
273
|
+
return this.variant === d.Multiple ? f`${e}<slot @slotchange=${this.handleSlotChange} @click=${this.handleClick} @keydown=${this.handleKeyDown} @mousedown=${this.handleMouseDown}></slot>` : f`${e}<slot @slotchange=${this.handleSlotChange} @click=${this.handleClick} @keydown=${this.handleKeyDown} @mousedown=${this.handleMouseDown}></slot>`;
|
|
273
274
|
}
|
|
274
275
|
};
|
|
275
|
-
l.styles = [
|
|
276
|
+
l.styles = [b, A];
|
|
276
277
|
u([
|
|
277
|
-
|
|
278
|
+
x("slot")
|
|
278
279
|
], l.prototype, "defaultSlot", 2);
|
|
279
280
|
u([
|
|
280
281
|
c({ type: Boolean })
|
|
@@ -311,10 +312,10 @@ u([
|
|
|
311
312
|
c({ attribute: "disabled-tab-loop", reflect: !0, type: Boolean })
|
|
312
313
|
], l.prototype, "disabledTabLoop", 2);
|
|
313
314
|
u([
|
|
314
|
-
|
|
315
|
+
w()
|
|
315
316
|
], l.prototype, "resizeObserver", 2);
|
|
316
317
|
l = u([
|
|
317
|
-
|
|
318
|
+
g("cx-menu")
|
|
318
319
|
], l);
|
|
319
320
|
export {
|
|
320
321
|
l as default
|
|
@@ -6,7 +6,7 @@ import { default as u } from "./corner-position-input-group.js";
|
|
|
6
6
|
import { C as m } from "../chunks/cropper.DTokTzP9.js";
|
|
7
7
|
import { default as i } from "./dynamic-select.js";
|
|
8
8
|
import { C as c } from "../chunks/folder-select.BFme962J.js";
|
|
9
|
-
import { C as P } from "../chunks/list-editor.
|
|
9
|
+
import { C as P } from "../chunks/list-editor.DsI3-bUG.js";
|
|
10
10
|
import { default as I } from "./masonry.js";
|
|
11
11
|
import { default as y } from "./padding-input-group.js";
|
|
12
12
|
import { default as w } from "./position-picker.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { default as a } from "./asset-link-format.js";
|
|
2
|
-
import { C as t } from "../chunks/color-swatch-group.
|
|
2
|
+
import { C as t } from "../chunks/color-swatch-group.BaMEIlzq.js";
|
|
3
3
|
import { C } from "../chunks/file-on-demand.CTJQ6P_F.js";
|
|
4
4
|
export {
|
|
5
5
|
a as CxAssetLinkFormat,
|
|
@@ -9,11 +9,11 @@ import { d as L } from "../chunks/default-value.COZopaet.js";
|
|
|
9
9
|
import { w as v } from "../chunks/event.mFzZi4sr.js";
|
|
10
10
|
import { F as $ } from "../chunks/form.Bi8x0jbW.js";
|
|
11
11
|
import { L as I } from "../chunks/i18n.CgwQHLcP.js";
|
|
12
|
-
import { s as
|
|
13
|
-
import { H as
|
|
14
|
-
import { i as
|
|
12
|
+
import { s as F } from "../chunks/scroll.xtO5yojm.js";
|
|
13
|
+
import { H as V } from "../chunks/slot.j5oheLJC.js";
|
|
14
|
+
import { i as E } from "../chunks/user-agent.D9aPuOyL.js";
|
|
15
15
|
import { w as p } from "../chunks/watch.BCJD77bD.js";
|
|
16
|
-
import { i as
|
|
16
|
+
import { i as T, x as u, E as B } from "../chunks/lit-element.jLBm65_O.js";
|
|
17
17
|
import { r as g } from "../chunks/state.CSDxrqLd.js";
|
|
18
18
|
import { e as m } from "../chunks/query.BBf1UFkC.js";
|
|
19
19
|
import { e as b } from "../chunks/class-map.BiVq-cVR.js";
|
|
@@ -25,7 +25,7 @@ import { C as d } from "../chunks/option.T4KSh5qy.js";
|
|
|
25
25
|
import U from "./popup.js";
|
|
26
26
|
import M from "./spinner.js";
|
|
27
27
|
import N from "./tag.js";
|
|
28
|
-
const R = (t) => !(document.createElement(t.tagName).constructor === HTMLElement || customElements.get(t.tagName.toLowerCase())), W = B`:host{display:block}:host([data-user-invalid])::part(combobox){border-color:var(--cx-input-invalid-border-color)}:host([data-user-invalid]:focus-within)::part(combobox){border-color:var(--cx-input-invalid-border-color);box-shadow:var(--cx-input-invalid-shadow)}.select{vertical-align:middle;flex:auto;width:100%;display:inline-flex;position:relative}.select::part(popup){z-index:var(--cx-z-index-dropdown)}.select[data-current-placement^=top]::part(popup){transform-origin:bottom}.select[data-current-placement^=bottom]::part(popup){transform-origin:top}.select__combobox{font-family:var(--cx-input-font-family);font-weight:var(--cx-input-font-weight);letter-spacing:var(--cx-input-letter-spacing);vertical-align:middle;cursor:pointer;transition:var(--cx-transition-fast) color, var(--cx-transition-fast) border, var(--cx-transition-fast) box-shadow, var(--cx-transition-fast) background-color;flex:1;justify-content:start;align-items:center;width:20ch;min-width:0;display:flex;position:relative;overflow:hidden}.select__display-input{width:100%;font:inherit;color:var(--cx-input-color);cursor:inherit;-webkit-appearance:none;text-overflow:ellipsis;background:0 0;border:none;margin:0;padding:0;transition:padding-top .2s ease-in-out;position:relative;overflow:hidden}.select__tags+.select__display-input{padding-top:var(--cx-spacing-2x-small)}.select__display-input--small{line-height:var(--cx-line-height-small)}.select__display-input--medium{line-height:var(--cx-line-height-medium)}.select__display-input--large{line-height:var(--cx-line-height-large)}.select__display-input--hidden{visibility:hidden;height:0;padding-top:0!important}.form-control--has-label .select__display-input{padding-top:var(--cx-spacing-x-small);padding-bottom:var(--cx-spacing-2x-small)}.select__display-input::placeholder{color:var(--cx-input-placeholder-color)}.select:not(.select--disabled):hover .select__display-input{color:var(--cx-input-color-hover)}.select:not(.select--disabled):hover .select__combobox{border-color:var(--cx-input-border-color-hover)}.select__display-input:focus{outline:none}.select__value-input{opacity:0;z-index:-1;width:100%;height:100%;margin:0;padding:0;position:absolute;top:0;left:0}.select__tags{flex-wrap:wrap;align-items:center;max-width:100%;display:flex}.form-control--has-label .select__tags{margin-top:var(--cx-spacing-x-small)}.select--small:not(.select--placeholder-visible) .select__tags,.select--medium:not(.select--placeholder-visible) .select__tags,.select--large:not(.select--placeholder-visible) .select__tags{min-height:var(--cx-line-height-medium)}.select__tags::slotted(cx-tag){cursor:pointer!important}.select--disabled .select__tags,.select--disabled .select__tags::slotted(cx-tag){cursor:default!important}.select__tag-wrapper{line-height:1}.select--standard .select__combobox{background-color:var(--cx-input-background-color);border:solid var(--cx-input-border-width) var(--cx-input-border-color)}.select--standard.select--disabled .select__combobox{background-color:var(--cx-input-background-color-disabled);border-color:var(--cx-input-border-color-disabled);color:var(--cx-input-color-disabled);opacity:.5;cursor:default;outline:none}.select--standard:not(.select--disabled).select--open .select__combobox,.select--standard:not(.select--disabled).select--focused .select__combobox{background-color:var(--cx-input-background-color-focus);border-color:var(--cx-input-border-color-focus)}.select--filled .select__combobox{background-color:var(--cx-input-filled-background-color);color:var(--cx-input-color);border:none}.select--filled:hover:not(.select--disabled) .select__combobox{background-color:var(--cx-input-filled-background-color-hover)}.select--filled.select--disabled .select__combobox{background-color:var(--cx-input-filled-background-color-disabled);opacity:.5;cursor:default}.select--filled:not(.select--disabled).select--open .select__combobox,.select--filled:not(.select--disabled).select--focused .select__combobox{background-color:var(--cx-input-filled-background-color-focus);outline:var(--cx-focus-ring)}.select--small .select__combobox{border-radius:var(--cx-input-border-radius-small);font-size:var(--cx-input-font-size-small);min-height:var(--cx-input-height-small);padding-block:0;padding-inline:var(--cx-input-spacing-small)}.form-control:not(.form-control--has-label) .select--small.select--multiple .select__combobox{padding-block:2px}.form-control:not(.form-control--has-label) .select--multiple .select__display-input{margin-top:0}.form-control:not(.form-control--has-label) .input-container{justify-content:center}.form-control:not(.form-control--has-label) .input-container .select__display-input{margin-top:0}.select--small .select__clear{margin-inline-start:var(--cx-input-spacing-small)}.select--small .select__prefix::slotted(*){margin-inline-end:var(--cx-input-spacing-small)}.select--small .select__tags{gap:2px}.select--medium .select__combobox{border-radius:var(--cx-input-border-radius-medium);font-size:var(--cx-input-font-size-small);min-height:var(--cx-input-height-medium);padding-block:0;padding-inline:var(--cx-input-spacing-medium)}.form-control:not(.form-control--has-label) .select--medium.select--multiple .select__combobox{padding-block:3px}.select--medium .select__clear{margin-inline-start:var(--cx-input-spacing-medium)}.select--medium .select__prefix::slotted(*){margin-inline-end:var(--cx-input-spacing-medium)}.select--medium .select__tags{gap:3px}.select--large .select__combobox{border-radius:var(--cx-input-border-radius-large);font-size:var(--cx-input-font-size-small);min-height:var(--cx-input-height-large);padding-block:0;padding-inline:var(--cx-input-spacing-large)}.form-control:not(.form-control--has-label) .select--large.select--multiple .select__combobox{padding-block:4px}.select--large .select__clear{margin-inline-start:var(--cx-input-spacing-large)}.select--large .select__prefix::slotted(*){margin-inline-end:var(--cx-input-spacing-large)}.select--large .select__tags{gap:4px}.select--pill.select--small .select__combobox{border-radius:var(--cx-input-height-small)}.select--pill.select--medium .select__combobox{border-radius:var(--cx-input-height-medium)}.select--pill.select--large .select__combobox{border-radius:var(--cx-input-height-large)}.select__prefix,.select__suffix{color:var(--cx-input-placeholder-color);flex:0;align-items:center;display:inline-flex}.select__clear{font-size:inherit;color:var(--cx-input-icon-color);transition:var(--cx-transition-fast) color;cursor:pointer;z-index:1;background:0 0;border:none;justify-content:center;align-items:center;padding:0;display:inline-flex}.select__clear:hover{color:var(--cx-input-icon-color-hover)}.select__clear:focus{outline:none}.select__expand-icon{transition:var(--cx-transition-medium) rotate ease;rotate:0;font-size:var(--cx-font-size-large);flex:none;align-items:center;margin-inline-start:var(--cx-spacing-small);display:flex}.select--open .select__expand-icon{rotate:-180deg}.select__listbox{font-family:var(--cx-font-sans);font-size:var(--cx-font-size-medium);font-weight:var(--cx-font-weight-regular);box-shadow:var(--cx-shadow-large);background:var(--cx-panel-background-color);border:solid var(--cx-panel-border-width) var(--cx-panel-border-color);border-radius:var(--cx-border-radius-large);padding-block:var(--cx-spacing-x-small);overscroll-behavior:none;max-width:var(--auto-size-available-width);max-height:var(--auto-size-available-height);padding-inline:0;display:block;position:relative;overflow:auto}.select__listbox ::slotted(cx-divider){--spacing:var(--cx-spacing-x-small)}.select__listbox ::slotted(small){font-size:var(--cx-font-size-small);color:var(--cx-color-neutral-500);padding-block:var(--cx-spacing-2x-small);padding-inline:var(--cx-spacing-small);display:block}.select__no-options{font-size:var(--cx-font-size-small);color:var(--cx-color-neutral-500);padding-block:var(--cx-spacing-2x-small);padding-inline:var(--cx-spacing-small);text-align:left;cursor:default;user-select:none;display:block}.input-container{flex-direction:column;flex:1;align-self:stretch;width:0;display:inline-flex;position:relative}.input-container__display-value{column-gap:var(--cx-spacing-small);row-gap:var(--cx-spacing-3x-small);flex-flow:wrap;width:100%;height:100%;display:flex}.form-control__label{pointer-events:none;width:fit-content;line-height:1;-webkit-transition:transform .2s ease-in-out;-moz-transition:transform .2s ease-in-out;transition:transform .2s ease-in-out;position:relative}.select--small .form-control__label{transform:translateY(calc(( var(--cx-input-height-small) + 1.25rem - var(--cx-input-font-size-small) ) / 2));margin:0}.select--medium .form-control__label{transform:translateY(calc(( var(--cx-input-height-medium) / 2 + 1rem - var(--cx-input-font-size-medium) )));margin:0}.select--large .form-control__label{transform:translateY(calc(( var(--cx-input-height-large) + 1rem - var(--cx-input-font-size-large) ) / 2));margin:0}.form-control--has-label .select--small{min-height:calc(var(--cx-input-height-small) + 1rem)}.form-control--has-label .select--medium{min-height:calc(var(--cx-input-height-medium) + 1rem)}.form-control--has-label .select--large{min-height:calc(var(--cx-input-height-large) + 1rem)}.form-control--has-label .select--focused .form-control__label,.form-control--has-label .select--placeholder-visible .form-control__label,.form-control--has-label .select:not(.select--empty) .form-control__label{transform:translateY(calc(var(--cx-spacing-2x-small) + var(--cx-spacing-3x-small)))}.select__listbox slot{flex-direction:column;display:flex}:host([data-cx-input-group__input--first]:not([data-cx-input-group__input--last])) .select__combobox{border-start-end-radius:0;border-end-end-radius:0}:host([data-cx-input-group__input--inner]) .select__combobox{border-radius:0}:host([data-cx-input-group__input--last]:not([data-cx-input-group__input--first])) .select__combobox{border-start-start-radius:0;border-end-start-radius:0}:host([data-cx-input-group__input]:not([data-cx-input-group__input--first])){margin-inline-start:calc(-1 * var(--cx-input-border-width))}:host([data-cx-input-group__input--hover]){z-index:1}:host([data-cx-input-group__input--focus]),:host([data-cx-input-group__input][checked]){z-index:2}`;
|
|
28
|
+
const R = (t) => !(document.createElement(t.tagName).constructor === HTMLElement || customElements.get(t.tagName.toLowerCase())), W = T`:host{display:block}:host([data-user-invalid])::part(combobox){border-color:var(--cx-input-invalid-border-color)}:host([data-user-invalid]:focus-within)::part(combobox){border-color:var(--cx-input-invalid-border-color);box-shadow:var(--cx-input-invalid-shadow)}.select{vertical-align:middle;flex:auto;width:100%;display:inline-flex;position:relative}.select::part(popup){z-index:var(--cx-z-index-dropdown)}.select[data-current-placement^=top]::part(popup){transform-origin:bottom}.select[data-current-placement^=bottom]::part(popup){transform-origin:top}.select__combobox{font-family:var(--cx-input-font-family);font-weight:var(--cx-input-font-weight);letter-spacing:var(--cx-input-letter-spacing);vertical-align:middle;cursor:pointer;transition:var(--cx-transition-fast) color, var(--cx-transition-fast) border, var(--cx-transition-fast) box-shadow, var(--cx-transition-fast) background-color;flex:1;justify-content:start;align-items:center;width:20ch;min-width:0;display:flex;position:relative;overflow:hidden}.select__display-input{width:100%;font:inherit;color:var(--cx-input-color);cursor:inherit;-webkit-appearance:none;text-overflow:ellipsis;background:0 0;border:none;margin:0;padding:0;transition:padding-top .2s ease-in-out;position:relative;overflow:hidden}:host([allow-freetext]) .input-container,:host([allow-freetext]) .select__display-input{cursor:text}:host([allow-freetext]) .select--disabled .input-container,:host([allow-freetext]) .select--disabled .select__display-input{cursor:default}.select__tags+.select__display-input{padding-top:var(--cx-spacing-2x-small)}.select__display-input--small{line-height:var(--cx-line-height-small)}.select__display-input--medium{line-height:var(--cx-line-height-medium)}.select__display-input--large{line-height:var(--cx-line-height-large)}.select__display-input--hidden{visibility:hidden;height:0;padding-top:0!important}.form-control--has-label .select__display-input{padding-top:var(--cx-spacing-x-small);padding-bottom:var(--cx-spacing-2x-small)}.select__display-input::placeholder{color:var(--cx-input-placeholder-color)}.select:not(.select--disabled):hover .select__display-input{color:var(--cx-input-color-hover)}.select:not(.select--disabled):hover .select__combobox{border-color:var(--cx-input-border-color-hover)}.select__display-input:focus{outline:none}.select__value-input{opacity:0;z-index:-1;width:100%;height:100%;margin:0;padding:0;position:absolute;top:0;left:0}.select__tags{flex-wrap:wrap;align-items:center;max-width:100%;display:flex}.form-control--has-label .select__tags{margin-top:var(--cx-spacing-x-small)}.select--small:not(.select--placeholder-visible) .select__tags,.select--medium:not(.select--placeholder-visible) .select__tags,.select--large:not(.select--placeholder-visible) .select__tags{min-height:var(--cx-line-height-medium)}.select__tags::slotted(cx-tag){cursor:pointer!important}.select--disabled .select__tags,.select--disabled .select__tags::slotted(cx-tag){cursor:default!important}.select__tag-wrapper{line-height:1}.select--standard .select__combobox{background-color:var(--cx-input-background-color);border:solid var(--cx-input-border-width) var(--cx-input-border-color)}.select--standard.select--disabled .select__combobox{background-color:var(--cx-input-background-color-disabled);border-color:var(--cx-input-border-color-disabled);color:var(--cx-input-color-disabled);opacity:.5;cursor:default;outline:none}.select--standard:not(.select--disabled).select--open .select__combobox,.select--standard:not(.select--disabled).select--focused .select__combobox{background-color:var(--cx-input-background-color-focus);border-color:var(--cx-input-border-color-focus)}.select--filled .select__combobox{background-color:var(--cx-input-filled-background-color);color:var(--cx-input-color);border:none}.select--filled:hover:not(.select--disabled) .select__combobox{background-color:var(--cx-input-filled-background-color-hover)}.select--filled.select--disabled .select__combobox{background-color:var(--cx-input-filled-background-color-disabled);opacity:.5;cursor:default}.select--filled:not(.select--disabled).select--open .select__combobox,.select--filled:not(.select--disabled).select--focused .select__combobox{background-color:var(--cx-input-filled-background-color-focus);outline:var(--cx-focus-ring)}.select--small .select__combobox{border-radius:var(--cx-input-border-radius-small);font-size:var(--cx-input-font-size-small);min-height:var(--cx-input-height-small);padding-block:0;padding-inline:var(--cx-input-spacing-small)}.form-control:not(.form-control--has-label) .select--small.select--multiple .select__combobox{padding-block:2px}.form-control:not(.form-control--has-label) .select--multiple .select__display-input{margin-top:0}.form-control:not(.form-control--has-label) .input-container{justify-content:center}.form-control:not(.form-control--has-label) .input-container .select__display-input{margin-top:0}.select--small .select__clear{margin-inline-start:var(--cx-input-spacing-small)}.select--small .select__prefix::slotted(*){margin-inline-end:var(--cx-input-spacing-small)}.select--small .select__tags{gap:2px}.select--medium .select__combobox{border-radius:var(--cx-input-border-radius-medium);font-size:var(--cx-input-font-size-small);min-height:var(--cx-input-height-medium);padding-block:0;padding-inline:var(--cx-input-spacing-medium)}.form-control:not(.form-control--has-label) .select--medium.select--multiple .select__combobox{padding-block:3px}.select--medium .select__clear{margin-inline-start:var(--cx-input-spacing-medium)}.select--medium .select__prefix::slotted(*){margin-inline-end:var(--cx-input-spacing-medium)}.select--medium .select__tags{gap:3px}.select--large .select__combobox{border-radius:var(--cx-input-border-radius-large);font-size:var(--cx-input-font-size-small);min-height:var(--cx-input-height-large);padding-block:0;padding-inline:var(--cx-input-spacing-large)}.form-control:not(.form-control--has-label) .select--large.select--multiple .select__combobox{padding-block:4px}.select--large .select__clear{margin-inline-start:var(--cx-input-spacing-large)}.select--large .select__prefix::slotted(*){margin-inline-end:var(--cx-input-spacing-large)}.select--large .select__tags{gap:4px}.select--pill.select--small .select__combobox{border-radius:var(--cx-input-height-small)}.select--pill.select--medium .select__combobox{border-radius:var(--cx-input-height-medium)}.select--pill.select--large .select__combobox{border-radius:var(--cx-input-height-large)}.select__prefix,.select__suffix{color:var(--cx-input-placeholder-color);flex:0;align-items:center;display:inline-flex}.select__clear{font-size:inherit;color:var(--cx-input-icon-color);transition:var(--cx-transition-fast) color;cursor:pointer;z-index:1;background:0 0;border:none;justify-content:center;align-items:center;padding:0;display:inline-flex}.select__clear:hover{color:var(--cx-input-icon-color-hover)}.select__clear:focus{outline:none}.select__expand-icon{transition:var(--cx-transition-medium) rotate ease;rotate:0;font-size:var(--cx-font-size-large);flex:none;align-items:center;margin-inline-start:var(--cx-spacing-small);display:flex}.select--open .select__expand-icon{rotate:-180deg}.select__listbox{font-family:var(--cx-font-sans);font-size:var(--cx-font-size-medium);font-weight:var(--cx-font-weight-regular);box-shadow:var(--cx-shadow-large);background:var(--cx-panel-background-color);border:solid var(--cx-panel-border-width) var(--cx-panel-border-color);border-radius:var(--cx-border-radius-large);padding-block:var(--cx-spacing-x-small);overscroll-behavior:none;max-width:var(--auto-size-available-width);max-height:var(--auto-size-available-height);padding-inline:0;display:block;position:relative;overflow:auto}.select__listbox ::slotted(cx-divider){--spacing:var(--cx-spacing-x-small)}.select__listbox ::slotted(small){font-size:var(--cx-font-size-small);color:var(--cx-color-neutral-500);padding-block:var(--cx-spacing-2x-small);padding-inline:var(--cx-spacing-small);display:block}.select__no-options{font-size:var(--cx-font-size-small);color:var(--cx-color-neutral-500);padding-block:var(--cx-spacing-2x-small);padding-inline:var(--cx-spacing-small);text-align:left;cursor:default;user-select:none;display:block}.input-container{flex-direction:column;flex:1;align-self:stretch;width:0;display:inline-flex;position:relative}.input-container__display-value{column-gap:var(--cx-spacing-small);row-gap:var(--cx-spacing-3x-small);flex-flow:wrap;width:100%;height:100%;display:flex}.form-control__label{pointer-events:none;width:fit-content;line-height:1;-webkit-transition:transform .2s ease-in-out;-moz-transition:transform .2s ease-in-out;transition:transform .2s ease-in-out;position:relative}.select--small .form-control__label{transform:translateY(calc(( var(--cx-input-height-small) + 1.25rem - var(--cx-input-font-size-small) ) / 2));margin:0}.select--medium .form-control__label{transform:translateY(calc(( var(--cx-input-height-medium) / 2 + 1rem - var(--cx-input-font-size-medium) )));margin:0}.select--large .form-control__label{transform:translateY(calc(( var(--cx-input-height-large) + 1rem - var(--cx-input-font-size-large) ) / 2));margin:0}.form-control--has-label .select--small{min-height:calc(var(--cx-input-height-small) + 1rem)}.form-control--has-label .select--medium{min-height:calc(var(--cx-input-height-medium) + 1rem)}.form-control--has-label .select--large{min-height:calc(var(--cx-input-height-large) + 1rem)}.form-control--has-label .select--focused .form-control__label,.form-control--has-label .select--placeholder-visible .form-control__label,.form-control--has-label .select:not(.select--empty) .form-control__label{transform:translateY(calc(var(--cx-spacing-2x-small) + var(--cx-spacing-3x-small)))}.select__listbox slot{flex-direction:column;display:flex}:host([data-cx-input-group__input--first]:not([data-cx-input-group__input--last])) .select__combobox{border-start-end-radius:0;border-end-end-radius:0}:host([data-cx-input-group__input--inner]) .select__combobox{border-radius:0}:host([data-cx-input-group__input--last]:not([data-cx-input-group__input--first])) .select__combobox{border-start-start-radius:0;border-end-start-radius:0}:host([data-cx-input-group__input]:not([data-cx-input-group__input--first])){margin-inline-start:calc(-1 * var(--cx-input-border-width))}:host([data-cx-input-group__input--hover]){z-index:1}:host([data-cx-input-group__input--focus]),:host([data-cx-input-group__input][checked]){z-index:2}`;
|
|
29
29
|
var H = Object.defineProperty, q = Object.getOwnPropertyDescriptor, o = (t, e, l, n) => {
|
|
30
30
|
for (var s = n > 1 ? void 0 : n ? q(e, l) : e, r = t.length - 1, c; r >= 0; r--)
|
|
31
31
|
(c = t[r]) && (s = (n ? c(e, l, s) : c(s)) || s);
|
|
@@ -35,7 +35,7 @@ let i = class extends S {
|
|
|
35
35
|
constructor() {
|
|
36
36
|
super(...arguments), this.formControlController = new $(this, {
|
|
37
37
|
assumeInteractionOn: ["cx-input"]
|
|
38
|
-
}), this.hasSlotController = new
|
|
38
|
+
}), this.hasSlotController = new V(
|
|
39
39
|
this,
|
|
40
40
|
"help-text",
|
|
41
41
|
"label"
|
|
@@ -172,7 +172,7 @@ let i = class extends S {
|
|
|
172
172
|
super.connectedCallback(), this.stayOpenOnSelect || (this.open = !1);
|
|
173
173
|
}
|
|
174
174
|
runFirstUpdated() {
|
|
175
|
-
|
|
175
|
+
E() && (this.contentEditable = "true");
|
|
176
176
|
}
|
|
177
177
|
addOpenListeners() {
|
|
178
178
|
document.addEventListener(
|
|
@@ -207,7 +207,7 @@ let i = class extends S {
|
|
|
207
207
|
), this.closeWatcher?.destroy();
|
|
208
208
|
}
|
|
209
209
|
handleFocus() {
|
|
210
|
-
this.hasFocus = !0, this.displayInput.setSelectionRange(0, this.displayInput.value.length), this.emit("cx-focus"), setTimeout(() => this.displayInput.focus(), 0);
|
|
210
|
+
this.hasFocus = !0, this.allowFreetext || this.displayInput.setSelectionRange(0, this.displayInput.value.length), this.emit("cx-focus"), setTimeout(() => this.displayInput.focus(), 0);
|
|
211
211
|
}
|
|
212
212
|
handleBlur(t) {
|
|
213
213
|
const e = t.relatedTarget;
|
|
@@ -244,9 +244,9 @@ let i = class extends S {
|
|
|
244
244
|
return;
|
|
245
245
|
}
|
|
246
246
|
s instanceof HTMLElement && s.tagName.toLowerCase() === "cx-icon-button" && (l = !0);
|
|
247
|
-
}), !(this.disabled || l) && (n || this.inputBehavior !== "filter" || !this.open || !this.multiple && !this.useTag ? (this.allowDefaultMouseDown ? requestAnimationFrame(() => {
|
|
247
|
+
}), !(this.disabled || l) && (n || this.inputBehavior !== "filter" || !this.open || !this.multiple && !this.useTag ? (this.allowDefaultMouseDown || this.allowFreetext ? requestAnimationFrame(() => {
|
|
248
248
|
this.displayInput.focus({ preventScroll: !0 });
|
|
249
|
-
}) : (t.preventDefault(), this.displayInput.focus({ preventScroll: !0 })), this.open = !this.open) : (t.preventDefault(), this.displayInput.focus({ preventScroll: !0 })));
|
|
249
|
+
}) : (t.preventDefault(), this.displayInput.focus({ preventScroll: !0 })), this.open = !this.open) : (this.allowFreetext || t.preventDefault(), this.displayInput.focus({ preventScroll: !0 })));
|
|
250
250
|
}
|
|
251
251
|
handleComboboxKeyDown(t) {
|
|
252
252
|
t.key !== "Tab" && ((t.key !== "Escape" || this.open && (this.shouldShowNoOptionsMessage || this.getVisibleOptions().length > 0)) && t.stopPropagation(), this.handleDocumentKeyDown(t));
|
|
@@ -379,7 +379,7 @@ let i = class extends S {
|
|
|
379
379
|
} else if (s === this.maxOptionsVisible)
|
|
380
380
|
return u`<cx-tag ?pill=${this.pill} size=${l}>
|
|
381
381
|
+${this.selectedOptions.length - s}</cx-tag>`;
|
|
382
|
-
return
|
|
382
|
+
return B;
|
|
383
383
|
});
|
|
384
384
|
}
|
|
385
385
|
handleInvalid(t) {
|
|
@@ -408,7 +408,7 @@ let i = class extends S {
|
|
|
408
408
|
const { keyframes: t, options: e } = _(this, "select.show", {
|
|
409
409
|
dir: this.localize.dir()
|
|
410
410
|
});
|
|
411
|
-
await y(this.popup.popup, t, e), this.currentOption &&
|
|
411
|
+
await y(this.popup.popup, t, e), this.currentOption && F(this.currentOption, this.listbox, "vertical", "auto"), this.emit("cx-after-show");
|
|
412
412
|
} else {
|
|
413
413
|
this.emit("cx-hide"), this.removeOpenListeners(), await x(this);
|
|
414
414
|
const { keyframes: t, options: e } = _(this, "select.hide", {
|
|
@@ -667,22 +667,22 @@ o([
|
|
|
667
667
|
})
|
|
668
668
|
], i.prototype, "loading", 2);
|
|
669
669
|
o([
|
|
670
|
-
a({ attribute: "get-tag" })
|
|
670
|
+
a({ attribute: "get-tag", type: Function })
|
|
671
671
|
], i.prototype, "getTag", 2);
|
|
672
672
|
o([
|
|
673
673
|
a({ attribute: "input-behavior" })
|
|
674
674
|
], i.prototype, "inputBehavior", 2);
|
|
675
675
|
o([
|
|
676
|
-
a({ attribute: "get-option-value" })
|
|
676
|
+
a({ attribute: "get-option-value", type: Function })
|
|
677
677
|
], i.prototype, "getOptionValue", 2);
|
|
678
678
|
o([
|
|
679
|
-
a({ attribute: "get-option-label" })
|
|
679
|
+
a({ attribute: "get-option-label", type: Function })
|
|
680
680
|
], i.prototype, "getOptionLabel", 2);
|
|
681
681
|
o([
|
|
682
|
-
a({ attribute: "get-option-selected" })
|
|
682
|
+
a({ attribute: "get-option-selected", type: Function })
|
|
683
683
|
], i.prototype, "getOptionSelected", 2);
|
|
684
684
|
o([
|
|
685
|
-
a({ attribute: "get-option-disabled" })
|
|
685
|
+
a({ attribute: "get-option-disabled", type: Function })
|
|
686
686
|
], i.prototype, "getOptionDisabled", 2);
|
|
687
687
|
o([
|
|
688
688
|
a({ attribute: "stay-open-on-select", type: Boolean })
|
|
@@ -9,7 +9,7 @@ import "./spinner.js";
|
|
|
9
9
|
import "../chunks/lib-cortex-element.CVMmyPMC.js";
|
|
10
10
|
import "../chunks/component.styles.CRO4Odto.js";
|
|
11
11
|
import "../chunks/overlayscrollbars.BMav4RQ4.js";
|
|
12
|
-
import { A as F, i as P, j as S, d as g, g as v, b as y, k as A, l as D, c as I, a0 as f, a1 as h, D as E, m as G, E as j, n as H, F as K, o as L, p as V, q as k, G as q, r as B, s as J, t as N, I as O, u as Q, K as U, v as W, M as X, w as Y, x as Z, y as _, z as $, B as oo, J as eo, L as ao, P as so, e as lo, N as to, h as uo, O as ro, Q as Mo, U as io, V as po, f as mo, R as no, X as Co, W as Ro, S as co, Y as bo, Z as wo, T as To, a as xo, _ as zo, $ as Fo, C as Po } from "../chunks/table.
|
|
12
|
+
import { A as F, i as P, j as S, d as g, g as v, b as y, k as A, l as D, c as I, a0 as f, a1 as h, D as E, m as G, E as j, n as H, F as K, o as L, p as V, q as k, G as q, r as B, s as J, t as N, I as O, u as Q, K as U, v as W, M as X, w as Y, x as Z, y as _, z as $, B as oo, J as eo, L as ao, P as so, e as lo, N as to, h as uo, O as ro, Q as Mo, U as io, V as po, f as mo, R as no, X as Co, W as Ro, S as co, Y as bo, Z as wo, T as To, a as xo, _ as zo, $ as Fo, C as Po } from "../chunks/table.CGTmaN_x.js";
|
|
13
13
|
import "../chunks/pagination.DC9JIt4s.js";
|
|
14
14
|
import "../chunks/custom-element.L4WJXn1j.js";
|
|
15
15
|
import "../chunks/i18n.CgwQHLcP.js";
|
|
@@ -71,7 +71,7 @@ import { default as uqt } from "./stepper.js";
|
|
|
71
71
|
import Kb from "./switch.js";
|
|
72
72
|
import G2 from "./tab.js";
|
|
73
73
|
import { C as K2, T as e9, a as t9, b as n9, g as TO } from "../chunks/tab-group.B6olTWpV.js";
|
|
74
|
-
import { C as r9 } from "../chunks/table.
|
|
74
|
+
import { C as r9 } from "../chunks/table.CGTmaN_x.js";
|
|
75
75
|
import i9 from "./tab-panel.js";
|
|
76
76
|
import { default as hqt } from "./tag.js";
|
|
77
77
|
import uR from "./textarea.js";
|
|
@@ -112,7 +112,7 @@ import { H as wR } from "../chunks/slot.j5oheLJC.js";
|
|
|
112
112
|
import { a as lVt, g as dVt } from "../chunks/slot.j5oheLJC.js";
|
|
113
113
|
import { c as LO, G as mh, d as Yd, T as xR, h as fn, i as kR, j as nY, t as RO, u as rY, f as y1, k as iY, F as Cf, M as Vv } from "../chunks/string.B_mXTq0K.js";
|
|
114
114
|
import { b as pVt, a as hVt, e as gVt, g as mVt, p as fVt, r as vVt, s as yVt, n as bVt, l as wVt, m as xVt, o as kVt } from "../chunks/string.B_mXTq0K.js";
|
|
115
|
-
import { a as l9, u as tp, I as _R, C as oY } from "../chunks/list-editor.
|
|
115
|
+
import { a as l9, u as tp, I as _R, C as oY } from "../chunks/list-editor.DsI3-bUG.js";
|
|
116
116
|
import aY from "./bicolor-picker.js";
|
|
117
117
|
import CR from "./border-input-group.js";
|
|
118
118
|
import { C as CVt } from "../chunks/color-swatch.hsIcIXE-.js";
|
|
@@ -165,8 +165,8 @@ import { c as hg } from "../chunks/math.DqTA6ya4.js";
|
|
|
165
165
|
import { b as YO, e as $Y } from "../chunks/number.CjNxU7Xs.js";
|
|
166
166
|
import { a as rWt, c as iWt, f as oWt, r as aWt, s as sWt } from "../chunks/number.CjNxU7Xs.js";
|
|
167
167
|
import { t as LR } from "../chunks/event-options.CYHYGOd8.js";
|
|
168
|
-
import { a as Uw } from "../chunks/color-swatch-group.
|
|
169
|
-
import { C as lWt } from "../chunks/color-swatch-group.
|
|
168
|
+
import { a as Uw } from "../chunks/color-swatch-group.BaMEIlzq.js";
|
|
169
|
+
import { C as lWt } from "../chunks/color-swatch-group.BaMEIlzq.js";
|
|
170
170
|
import { t as jY } from "../chunks/converters.DkDtLstb.js";
|
|
171
171
|
import { i as HY } from "../chunks/user-agent.D9aPuOyL.js";
|
|
172
172
|
import { a as RR, U as f9, t as UY } from "../chunks/url.Cj9cIQXJ.js";
|
package/library/package.json
CHANGED
|
@@ -109,6 +109,7 @@ export default class CxDrawer extends CortexElement {
|
|
|
109
109
|
private requestClose;
|
|
110
110
|
private addOpenListeners;
|
|
111
111
|
private removeOpenListeners;
|
|
112
|
+
private resetMultipleMenus;
|
|
112
113
|
private handleDocumentKeyDown;
|
|
113
114
|
handleOpenChange(): Promise<void>;
|
|
114
115
|
handleNoModalChange(): void;
|