@orangelogic/design-system 2.207.0 → 2.209.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/{document-viewer.CfH1u-Ds.js → document-viewer.CgSEgZ5S.js} +1 -1
- package/library/chunks/{header.Dkkj1ztq.js → header.DcEskmXD.js} +58 -30
- package/library/components/atoms.js +2 -2
- package/library/components/document-viewer.js +1 -1
- package/library/components/dropdown.js +63 -59
- package/library/components/header.js +1 -1
- package/library/components/menu-item.js +1 -1
- package/library/components/menu.js +198 -191
- package/library/components/types.js +21601 -21489
- package/library/package.json +1 -1
- package/library/packages/atoms/src/components/dropdown/dropdown.d.ts +1 -0
- package/library/packages/atoms/src/components/menu/menu.d.ts +8 -15
- package/library/packages/organisms/src/content-builder-viewer/content-builder-viewer.d.ts +13 -0
- package/library/packages/organisms/src/downloader/data/core/WorkerProxy.d.ts +1 -0
- package/library/packages/organisms/src/downloader/data/core/worker/app/DownloadManager.d.ts +6 -0
- package/library/packages/organisms/src/downloader/downloader.d.ts +2 -0
- package/library/packages/tools/src/tiptap/extensions/link/helpers/active-link-range.d.ts +10 -0
- package/library/packages/tools/src/tiptap/extensions/table/index.d.ts +14 -1
- package/library/packages/types/src/content-builder.d.ts +2 -0
- package/library/react-web-component.d.ts +2 -2
- package/package.json +1 -1
|
@@ -1,29 +1,37 @@
|
|
|
1
|
-
import { n 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
|
-
var
|
|
11
|
-
const
|
|
12
|
-
var
|
|
13
|
-
for (var
|
|
14
|
-
(
|
|
15
|
-
return
|
|
1
|
+
import { n as u, C as g } from "../chunks/lib-cortex-element.CVMmyPMC.js";
|
|
2
|
+
import { c as v } from "../chunks/component.styles.CRO4Odto.js";
|
|
3
|
+
import { c as y } from "../chunks/custom-element.L4WJXn1j.js";
|
|
4
|
+
import { L as x } from "../chunks/i18n.DbXTTLXx.js";
|
|
5
|
+
import { i as w, x as b } from "../chunks/lit-element.jLBm65_O.js";
|
|
6
|
+
import { r as k } from "../chunks/state.CSDxrqLd.js";
|
|
7
|
+
import { e as M } from "../chunks/query.BBf1UFkC.js";
|
|
8
|
+
import { n as A } from "../chunks/when.Dr1es41R.js";
|
|
9
|
+
import I from "./menu-item.js";
|
|
10
|
+
var p = /* @__PURE__ */ ((e) => (e.Default = "default", e.Multiple = "multiple", e))(p || {});
|
|
11
|
+
const S = w`:host{background:var(--cx-panel-background-color);border:solid var(--cx-panel-border-width) var(--cx-panel-border-color);border-radius:var(--cx-panel-border-radius,var(--cx-border-radius-large));padding:var(--cx-panel-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 E = Object.defineProperty, C = Object.getOwnPropertyDescriptor, c = (e, t, i, s) => {
|
|
13
|
+
for (var a = s > 1 ? void 0 : s ? C(t, i) : t, o = e.length - 1, h; o >= 0; o--)
|
|
14
|
+
(h = e[o]) && (a = (s ? h(t, i, a) : h(a)) || a);
|
|
15
|
+
return s && a && E(t, i, a), a;
|
|
16
16
|
};
|
|
17
|
-
function
|
|
17
|
+
function f(e) {
|
|
18
18
|
return e.tagName.toLowerCase() === "cx-menu" && e instanceof l && e.getAttribute("role") === "menu";
|
|
19
19
|
}
|
|
20
|
-
let l = class extends
|
|
20
|
+
let l = class extends g {
|
|
21
21
|
constructor() {
|
|
22
|
-
super(...arguments), this.localize = new
|
|
22
|
+
super(...arguments), this.localize = new x(this), this.horizontal = !1, this.variant = p.Default, this.active = !1, this.name = "", this.back = "", this.default = !1, this.bubbleKeyDown = !1, this.ignoredKeys = [], this.disabledTabLoop = !1, this.noUncheck = !1, this.resizeObserver = null, this.slotMutationObserver = null;
|
|
23
23
|
}
|
|
24
24
|
connectedCallback() {
|
|
25
|
-
super.connectedCallback(), this.slotMutationObserver = new MutationObserver(() =>
|
|
26
|
-
|
|
25
|
+
super.connectedCallback(), this.slotMutationObserver = new MutationObserver((e) => {
|
|
26
|
+
if (e.every(
|
|
27
|
+
(i) => i.type === "attributes" && (i.attributeName === "checked" || i.attributeName === "active")
|
|
28
|
+
)) {
|
|
29
|
+
this.syncTabIndexToSelection();
|
|
30
|
+
return;
|
|
31
|
+
}
|
|
32
|
+
this.handleSlotChange();
|
|
33
|
+
}), this.slotMutationObserver.observe(this, {
|
|
34
|
+
attributeFilter: ["active", "checked", "inert", "is-empty"],
|
|
27
35
|
attributes: !0,
|
|
28
36
|
subtree: !0
|
|
29
37
|
});
|
|
@@ -32,7 +40,7 @@ let l = class extends p {
|
|
|
32
40
|
super.disconnectedCallback(), this.resizeObserver && (this.resizeObserver.disconnect(), this.resizeObserver = null), this.slotMutationObserver && (this.slotMutationObserver.disconnect(), this.slotMutationObserver = null);
|
|
33
41
|
}
|
|
34
42
|
runFirstUpdated() {
|
|
35
|
-
if (this.setAttribute("role", "menu"), this.variant ===
|
|
43
|
+
if (this.setAttribute("role", "menu"), this.variant === p.Multiple) {
|
|
36
44
|
const e = this.getAllSubMenus();
|
|
37
45
|
this.setActiveMenu(e[0]?.name ?? ""), this.updateComplete.then(() => {
|
|
38
46
|
this.adjustMenuSize();
|
|
@@ -40,132 +48,129 @@ let l = class extends p {
|
|
|
40
48
|
}
|
|
41
49
|
}
|
|
42
50
|
handleClick(e) {
|
|
43
|
-
const t = ["menuitem", "menuitemcheckbox"],
|
|
44
|
-
(
|
|
51
|
+
const t = ["menuitem", "menuitemcheckbox"], i = e.composedPath(), s = i.find(
|
|
52
|
+
(n) => t.includes(n?.getAttribute?.("role") || "")
|
|
45
53
|
);
|
|
46
|
-
if (!
|
|
54
|
+
if (!s)
|
|
47
55
|
return;
|
|
48
|
-
const
|
|
49
|
-
if (
|
|
50
|
-
this.setActiveMenu(
|
|
56
|
+
const a = s.menu;
|
|
57
|
+
if (a) {
|
|
58
|
+
this.setActiveMenu(a);
|
|
51
59
|
return;
|
|
52
60
|
}
|
|
53
|
-
if (
|
|
54
|
-
(
|
|
61
|
+
if (i.find(
|
|
62
|
+
(n) => n?.getAttribute?.("role") === "menu"
|
|
55
63
|
) !== this)
|
|
56
64
|
return;
|
|
57
|
-
const
|
|
58
|
-
|
|
65
|
+
const d = s;
|
|
66
|
+
d.type === "checkbox" && (d.checked && (this.noUncheck || d.noUncheck) || (d.checked = !d.checked)), this.emit("cx-select", { detail: { item: d } });
|
|
59
67
|
}
|
|
60
68
|
handleKeyDown(e) {
|
|
61
|
-
if (
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
}
|
|
69
|
+
if (this.ignoredKeys.includes(e.key))
|
|
70
|
+
return;
|
|
71
|
+
const t = e.target, i = this.isMenuItem(t) ? t : void 0;
|
|
72
|
+
if (i && (e.key === "Enter" || e.key === " "))
|
|
73
|
+
e.preventDefault(), this.bubbleKeyDown || e.stopPropagation(), i.click();
|
|
74
|
+
else if ([
|
|
75
|
+
"Home",
|
|
76
|
+
"End",
|
|
77
|
+
"ArrowDown",
|
|
78
|
+
"ArrowUp",
|
|
79
|
+
"ArrowLeft",
|
|
80
|
+
"ArrowRight"
|
|
81
|
+
].includes(e.key)) {
|
|
82
|
+
const s = this.getAllItems(), a = i ? s.indexOf(i) : -1;
|
|
83
|
+
let o = a === -1 ? s.findIndex((h) => h.getAttribute("tabindex") === "0") : a;
|
|
84
|
+
if (o === -1 && (o = 0), ["ArrowLeft", "ArrowRight"].includes(e.key) && !this.bubbleKeyDown && !(this.parentElement instanceof l) && !(this.parentElement instanceof I) && e.stopPropagation(), s.length > 0) {
|
|
85
|
+
const h = this.horizontal ? e.key === "ArrowRight" || o === s.length - 1 && e.key === "ArrowDown" : e.key === "ArrowDown", d = this.horizontal ? e.key === "ArrowLeft" || o === 0 && e.key === "ArrowUp" : e.key === "ArrowUp";
|
|
86
|
+
if (["ArrowRight", "ArrowDown", "ArrowLeft", "ArrowUp"].includes(
|
|
87
|
+
e.key
|
|
88
|
+
) && !h && !d)
|
|
89
|
+
return;
|
|
90
|
+
if (this.bubbleKeyDown || e.stopPropagation(), h)
|
|
91
|
+
o++;
|
|
92
|
+
else if (d)
|
|
93
|
+
o--;
|
|
94
|
+
else if (e.key === "Home") {
|
|
95
|
+
e.preventDefault();
|
|
96
|
+
let n = this.parentElement?.firstElementChild;
|
|
97
|
+
for (; n && !f(n); )
|
|
98
|
+
n = n.nextElementSibling;
|
|
99
|
+
if (n) {
|
|
100
|
+
const r = n.getAllItems();
|
|
101
|
+
if (r.length > 0) {
|
|
102
|
+
r[0].focus();
|
|
103
|
+
return;
|
|
97
104
|
}
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
105
|
+
}
|
|
106
|
+
o = 0;
|
|
107
|
+
} else if (e.key === "End") {
|
|
108
|
+
e.preventDefault();
|
|
109
|
+
let n = this.parentElement?.lastElementChild;
|
|
110
|
+
for (; n && !f(n); )
|
|
111
|
+
n = n.previousElementSibling;
|
|
112
|
+
if (n) {
|
|
113
|
+
const r = n.getAllItems();
|
|
114
|
+
if (r.length > 0) {
|
|
115
|
+
r[r.length - 1].focus();
|
|
116
|
+
return;
|
|
110
117
|
}
|
|
111
|
-
i = 0;
|
|
112
118
|
}
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
119
|
+
o = 0;
|
|
120
|
+
}
|
|
121
|
+
if (o < 0 && !this.disabledTabLoop) {
|
|
122
|
+
e.preventDefault();
|
|
123
|
+
let n = this.previousElementSibling;
|
|
124
|
+
for (; n && !f(n); )
|
|
125
|
+
n = n.previousElementSibling;
|
|
126
|
+
if (n) {
|
|
127
|
+
const r = n.getAllItems();
|
|
128
|
+
if (r.length > 0) {
|
|
129
|
+
r[r.length - 1].focus();
|
|
130
|
+
return;
|
|
131
|
+
}
|
|
132
|
+
} else {
|
|
133
|
+
let r = this.parentElement?.lastElementChild;
|
|
134
|
+
for (; r && !f(r); )
|
|
135
|
+
r = r.previousElementSibling;
|
|
136
|
+
if (r) {
|
|
137
|
+
const m = r.getAllItems();
|
|
138
|
+
if (m.length > 0) {
|
|
139
|
+
m[m.length - 1].focus();
|
|
124
140
|
return;
|
|
125
141
|
}
|
|
126
|
-
} else {
|
|
127
|
-
let s = this.parentElement?.lastElementChild;
|
|
128
|
-
for (; s && !m(s); )
|
|
129
|
-
s = s.previousElementSibling;
|
|
130
|
-
if (s) {
|
|
131
|
-
const a = s.getAllItems();
|
|
132
|
-
if (a.length > 0) {
|
|
133
|
-
s.setCurrentItem(a[a.length - 1]), a[a.length - 1].focus();
|
|
134
|
-
return;
|
|
135
|
-
}
|
|
136
|
-
}
|
|
137
|
-
i = 0;
|
|
138
142
|
}
|
|
143
|
+
o = 0;
|
|
139
144
|
}
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
145
|
+
}
|
|
146
|
+
if (o > s.length - 1 && !this.disabledTabLoop) {
|
|
147
|
+
e.preventDefault();
|
|
148
|
+
let n = this.nextElementSibling;
|
|
149
|
+
for (; n && !f(n); )
|
|
150
|
+
n = n.nextElementSibling;
|
|
151
|
+
if (n) {
|
|
152
|
+
const r = n.getAllItems();
|
|
153
|
+
if (r.length > 0) {
|
|
154
|
+
r[0].focus();
|
|
155
|
+
return;
|
|
156
|
+
}
|
|
157
|
+
} else {
|
|
158
|
+
let r = this.parentElement?.firstElementChild;
|
|
159
|
+
for (; r && !f(r); )
|
|
160
|
+
r = r.nextElementSibling;
|
|
161
|
+
if (r) {
|
|
162
|
+
const m = r.getAllItems();
|
|
163
|
+
if (m.length > 0) {
|
|
164
|
+
m[0].focus();
|
|
149
165
|
return;
|
|
150
166
|
}
|
|
151
|
-
} else {
|
|
152
|
-
let s = this.parentElement?.firstElementChild;
|
|
153
|
-
for (; s && !m(s); )
|
|
154
|
-
s = s.nextElementSibling;
|
|
155
|
-
if (s) {
|
|
156
|
-
const a = s.getAllItems();
|
|
157
|
-
if (a.length > 0) {
|
|
158
|
-
s.setCurrentItem(a[0]), a[0].focus();
|
|
159
|
-
return;
|
|
160
|
-
}
|
|
161
|
-
}
|
|
162
|
-
i = 0;
|
|
163
167
|
}
|
|
168
|
+
o = 0;
|
|
164
169
|
}
|
|
165
|
-
if (i < 0 || i > t.length - 1)
|
|
166
|
-
return;
|
|
167
|
-
e.preventDefault(), this.setCurrentItem(t[i]), t[i].focus();
|
|
168
170
|
}
|
|
171
|
+
if (o < 0 || o > s.length - 1)
|
|
172
|
+
return;
|
|
173
|
+
e.preventDefault(), s[o].focus();
|
|
169
174
|
}
|
|
170
175
|
}
|
|
171
176
|
}
|
|
@@ -174,20 +179,34 @@ let l = class extends p {
|
|
|
174
179
|
this.isMenuItem(t) && this.setCurrentItem(t);
|
|
175
180
|
}
|
|
176
181
|
handleSlotChange() {
|
|
177
|
-
|
|
178
|
-
e
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
const i = r;
|
|
182
|
+
this.syncTabIndexToSelection();
|
|
183
|
+
let e = null;
|
|
184
|
+
this.defaultSlot.assignedElements().filter((t) => {
|
|
185
|
+
const i = t;
|
|
182
186
|
return this.isMenuItem(i) || this.isMenuSection(i);
|
|
183
|
-
}).forEach((
|
|
184
|
-
const i =
|
|
185
|
-
|
|
187
|
+
}).forEach((t) => {
|
|
188
|
+
const i = t, s = !i.inert && !i.hasAttribute("is-empty");
|
|
189
|
+
e && s && (this.isMenuSection(e) && this.isMenuItem(i) || this.isMenuSection(i) && i.childElementCount > 0) ? i.setAttribute(
|
|
186
190
|
"data-alternating-grouping",
|
|
187
191
|
this.horizontal ? "horizontal" : ""
|
|
188
|
-
) : i.removeAttribute("data-alternating-grouping"),
|
|
192
|
+
) : i.removeAttribute("data-alternating-grouping"), s && (e = i);
|
|
189
193
|
});
|
|
190
194
|
}
|
|
195
|
+
/** Sets `tabindex="0"` on the selected item (`checked`/`active`), or the first item if none is selected. */
|
|
196
|
+
syncTabIndexToSelection() {
|
|
197
|
+
const e = this.getAllItems();
|
|
198
|
+
if (e.length === 0)
|
|
199
|
+
return;
|
|
200
|
+
let t;
|
|
201
|
+
for (const i of e)
|
|
202
|
+
i.setAttribute("tabindex", "-1"), !t && (i.checked || i.active) && (t = i);
|
|
203
|
+
(t ?? e[0]).setAttribute("tabindex", "0");
|
|
204
|
+
}
|
|
205
|
+
/** Moves `tabindex="0"` directly to `item`; used by `setCurrentItem()` for explicit external placement. */
|
|
206
|
+
setRovingTabIndex(e) {
|
|
207
|
+
for (const t of this.getAllItems())
|
|
208
|
+
t.setAttribute("tabindex", t === e ? "0" : "-1");
|
|
209
|
+
}
|
|
191
210
|
isMenuSection(e) {
|
|
192
211
|
return e instanceof HTMLElement ? e.tagName.toLowerCase() === "cx-menu-section" : !1;
|
|
193
212
|
}
|
|
@@ -200,8 +219,8 @@ let l = class extends p {
|
|
|
200
219
|
getAllItems() {
|
|
201
220
|
return this.defaultSlot.assignedElements({ flatten: !0 }).flatMap((t) => {
|
|
202
221
|
if (this.isMenuSection(t)) {
|
|
203
|
-
const
|
|
204
|
-
return
|
|
222
|
+
const i = t.shadowRoot?.querySelector("slot");
|
|
223
|
+
return i ? [...i.assignedElements({ flatten: !0 })] : [];
|
|
205
224
|
}
|
|
206
225
|
return t;
|
|
207
226
|
}).filter((t) => !(t.inert || !this.isMenuItem(t)));
|
|
@@ -212,25 +231,25 @@ let l = class extends p {
|
|
|
212
231
|
}
|
|
213
232
|
setActiveMenu(e) {
|
|
214
233
|
const t = this.getAllSubMenus();
|
|
215
|
-
let
|
|
216
|
-
t.forEach((
|
|
217
|
-
|
|
218
|
-
}), this.adjustMenuSize(),
|
|
234
|
+
let i = null;
|
|
235
|
+
t.forEach((s) => {
|
|
236
|
+
s.name === e ? (s.active = !0, i = s) : s.active = !1;
|
|
237
|
+
}), this.adjustMenuSize(), i && (this.resizeObserver && (this.resizeObserver.disconnect(), this.resizeObserver = null), this.resizeObserver = new ResizeObserver(() => {
|
|
219
238
|
this.adjustMenuSize();
|
|
220
|
-
}), this.resizeObserver.observe(
|
|
239
|
+
}), this.resizeObserver.observe(i));
|
|
221
240
|
}
|
|
222
241
|
async adjustMenuSize(e = 250) {
|
|
223
242
|
const t = this.getActiveMenu();
|
|
224
243
|
if (t) {
|
|
225
244
|
await t.updateComplete;
|
|
226
|
-
const
|
|
245
|
+
const i = t.offsetWidth, s = t.offsetHeight;
|
|
227
246
|
this.animate(
|
|
228
247
|
[
|
|
229
248
|
{
|
|
230
|
-
height: this.style.height ?? `${
|
|
231
|
-
width: this.style.width ?? `${
|
|
249
|
+
height: this.style.height ?? `${s}px`,
|
|
250
|
+
width: this.style.width ?? `${i}px`
|
|
232
251
|
},
|
|
233
|
-
{ height: `${
|
|
252
|
+
{ height: `${s}px`, width: `${i}px` }
|
|
234
253
|
// Fade out
|
|
235
254
|
],
|
|
236
255
|
{
|
|
@@ -249,57 +268,45 @@ let l = class extends p {
|
|
|
249
268
|
getActiveMenu() {
|
|
250
269
|
return this.getAllSubMenus().find((t) => t.active) || void 0;
|
|
251
270
|
}
|
|
252
|
-
/**
|
|
253
|
-
* @internal Gets the current menu item, which is the menu item that has `tabindex="0"` within the roving tab index.
|
|
254
|
-
* The menu item may or may not have focus, but for keyboard interaction purposes it's considered the "active" item.
|
|
255
|
-
*/
|
|
256
|
-
getCurrentItem() {
|
|
257
|
-
return this.getAllItems().find((e) => e.getAttribute("tabindex") === "0");
|
|
258
|
-
}
|
|
259
|
-
/**
|
|
260
|
-
* @internal Sets the current menu item to the specified element. This sets `tabindex="0"` on the target element and
|
|
261
|
-
* `tabindex="-1"` to all other items. This method must be called prior to setting focus on a menu item.
|
|
262
|
-
*/
|
|
271
|
+
/** @internal Sets `tabindex="0"` on `item` and `tabindex="-1"` on all others. Call before focusing a menu item. */
|
|
263
272
|
setCurrentItem(e) {
|
|
264
|
-
this.
|
|
265
|
-
r.setAttribute("tabindex", r === e ? "0" : "-1");
|
|
266
|
-
});
|
|
273
|
+
this.setRovingTabIndex(e);
|
|
267
274
|
}
|
|
268
275
|
render() {
|
|
269
|
-
const e =
|
|
276
|
+
const e = A(
|
|
270
277
|
this.back,
|
|
271
|
-
() =>
|
|
278
|
+
() => b`<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>`
|
|
272
279
|
);
|
|
273
|
-
return this.variant ===
|
|
280
|
+
return this.variant === p.Multiple ? b`${e}<slot @slotchange=${this.handleSlotChange} @click=${this.handleClick} @keydown=${this.handleKeyDown} @mousedown=${this.handleMouseDown}></slot>` : b`${e}<slot @slotchange=${this.handleSlotChange} @click=${this.handleClick} @keydown=${this.handleKeyDown} @mousedown=${this.handleMouseDown}></slot>`;
|
|
274
281
|
}
|
|
275
282
|
};
|
|
276
|
-
l.styles = [
|
|
277
|
-
|
|
278
|
-
|
|
283
|
+
l.styles = [v, S];
|
|
284
|
+
c([
|
|
285
|
+
M("slot:not([name])")
|
|
279
286
|
], l.prototype, "defaultSlot", 2);
|
|
280
|
-
|
|
281
|
-
|
|
287
|
+
c([
|
|
288
|
+
u({ type: Boolean })
|
|
282
289
|
], l.prototype, "horizontal", 2);
|
|
283
|
-
|
|
284
|
-
|
|
290
|
+
c([
|
|
291
|
+
u({ reflect: !0 })
|
|
285
292
|
], l.prototype, "variant", 2);
|
|
286
|
-
|
|
287
|
-
|
|
293
|
+
c([
|
|
294
|
+
u({ reflect: !0, type: Boolean })
|
|
288
295
|
], l.prototype, "active", 2);
|
|
289
|
-
|
|
290
|
-
|
|
296
|
+
c([
|
|
297
|
+
u({ reflect: !0 })
|
|
291
298
|
], l.prototype, "name", 2);
|
|
292
|
-
|
|
293
|
-
|
|
299
|
+
c([
|
|
300
|
+
u({ reflect: !0 })
|
|
294
301
|
], l.prototype, "back", 2);
|
|
295
|
-
|
|
296
|
-
|
|
302
|
+
c([
|
|
303
|
+
u({ reflect: !0, type: Boolean })
|
|
297
304
|
], l.prototype, "default", 2);
|
|
298
|
-
|
|
299
|
-
|
|
305
|
+
c([
|
|
306
|
+
u({ attribute: "bubble-keydown", reflect: !0, type: Boolean })
|
|
300
307
|
], l.prototype, "bubbleKeyDown", 2);
|
|
301
|
-
|
|
302
|
-
|
|
308
|
+
c([
|
|
309
|
+
u({
|
|
303
310
|
attribute: "ignored-keys",
|
|
304
311
|
converter: {
|
|
305
312
|
fromAttribute: (e) => e?.split(" ") ?? [],
|
|
@@ -308,17 +315,17 @@ u([
|
|
|
308
315
|
type: String
|
|
309
316
|
})
|
|
310
317
|
], l.prototype, "ignoredKeys", 2);
|
|
311
|
-
|
|
312
|
-
|
|
318
|
+
c([
|
|
319
|
+
u({ attribute: "disabled-tab-loop", reflect: !0, type: Boolean })
|
|
313
320
|
], l.prototype, "disabledTabLoop", 2);
|
|
314
|
-
|
|
315
|
-
|
|
321
|
+
c([
|
|
322
|
+
u({ attribute: "no-uncheck", reflect: !0, type: Boolean })
|
|
316
323
|
], l.prototype, "noUncheck", 2);
|
|
317
|
-
|
|
318
|
-
|
|
324
|
+
c([
|
|
325
|
+
k()
|
|
319
326
|
], l.prototype, "resizeObserver", 2);
|
|
320
|
-
l =
|
|
321
|
-
|
|
327
|
+
l = c([
|
|
328
|
+
y("cx-menu")
|
|
322
329
|
], l);
|
|
323
330
|
export {
|
|
324
331
|
l as default
|