@mlightcad/ribbon 0.1.2 → 0.1.4

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.
@@ -1,59 +1,75 @@
1
- import { Fragment as e, computed as t, createBlock as n, createCommentVNode as r, createElementBlock as i, createElementVNode as a, createSlots as o, createTextVNode as s, createVNode as c, defineComponent as l, inject as u, markRaw as d, mergeProps as f, nextTick as p, normalizeClass as m, normalizeStyle as h, onMounted as g, onUnmounted as _, openBlock as v, provide as y, ref as b, renderList as x, renderSlot as S, resolveDynamicComponent as C, toDisplayString as w, toRaw as T, unref as E, watch as D, withCtx as O, withModifiers as k } from "vue";
2
- import { ElButton as ee, ElButtonGroup as A, ElCheckbox as te, ElColorPicker as ne, ElConfigProvider as re, ElDrawer as j, ElDropdown as M, ElDropdownItem as N, ElDropdownMenu as P, ElIcon as F, ElInputNumber as I, ElOption as ie, ElPopover as ae, ElSegmented as L, ElSelect as oe, ElSwitch as R, ElTooltip as z, useGlobalConfig as se } from "element-plus";
3
- import { ArrowDown as B, ArrowDownBold as V, ArrowUp as H, ArrowUpBold as ce, Grid as le, Menu as ue, Promotion as de } from "@element-plus/icons-vue";
1
+ import { Fragment as e, computed as t, createBlock as n, createCommentVNode as r, createElementBlock as i, createElementVNode as a, createSlots as o, createTextVNode as s, createVNode as c, defineComponent as l, inject as u, markRaw as d, mergeProps as f, nextTick as p, normalizeClass as m, normalizeStyle as h, onMounted as g, onUnmounted as _, openBlock as v, provide as y, ref as b, renderList as x, renderSlot as S, resolveDynamicComponent as C, toDisplayString as w, toRaw as T, unref as E, watch as D, withCtx as O, withKeys as k, withModifiers as ee } from "vue";
2
+ import { ElButton as te, ElButtonGroup as A, ElCheckbox as ne, ElColorPicker as j, ElConfigProvider as re, ElDrawer as M, ElDropdown as N, ElDropdownItem as P, ElDropdownMenu as F, ElIcon as I, ElInputNumber as ie, ElOption as L, ElPopover as R, ElSegmented as z, ElSelect as B, ElSwitch as V, ElTooltip as ae, useGlobalConfig as oe } from "element-plus";
3
+ import { ArrowDown as H, ArrowDownBold as se, ArrowUp as ce, ArrowUpBold as le, Bottom as ue, Grid as de, Menu as fe, Promotion as U } from "@element-plus/icons-vue";
4
4
  //#region src/ribbon/context.ts
5
- var fe = Symbol("RibbonContext");
5
+ var pe = Symbol("RibbonContext");
6
6
  //#endregion
7
7
  //#region src/ribbon/composables/useRibbonState.ts
8
- function U(e) {
8
+ function W(e) {
9
9
  return e == null || typeof e == "string" ? e : typeof e == "object" || typeof e == "function" ? d(T(e)) : e;
10
10
  }
11
- function W(e) {
11
+ function G(e) {
12
12
  if (!e) return;
13
13
  let t = { ...e };
14
- return "component" in t && (t.component = U(t.component)), "icon" in t && (t.icon = U(t.icon)), "activeIcon" in t && (t.activeIcon = U(t.activeIcon)), "inactiveIcon" in t && (t.inactiveIcon = U(t.inactiveIcon)), Array.isArray(t.options) && (t.options = t.options.map((e) => {
14
+ return "component" in t && (t.component = W(t.component)), "icon" in t && (t.icon = W(t.icon)), "activeIcon" in t && (t.activeIcon = W(t.activeIcon)), "inactiveIcon" in t && (t.inactiveIcon = W(t.inactiveIcon)), Array.isArray(t.options) && (t.options = t.options.map((e) => {
15
15
  if (!e || typeof e != "object") return e;
16
16
  let t = e;
17
17
  return "icon" in t ? {
18
18
  ...t,
19
- icon: U(t.icon)
19
+ icon: W(t.icon)
20
20
  } : t;
21
+ })), Array.isArray(t.categories) && (t.categories = t.categories.map((e) => {
22
+ if (!e || typeof e != "object") return e;
23
+ let t = e;
24
+ return {
25
+ ...t,
26
+ items: Array.isArray(t.items) ? t.items.map((e) => {
27
+ if (!e || typeof e != "object") return e;
28
+ let t = e;
29
+ return {
30
+ ...t,
31
+ preview: W(t.preview),
32
+ icon: W(t.icon),
33
+ component: W(t.component)
34
+ };
35
+ }) : t.items
36
+ };
21
37
  })), t;
22
38
  }
23
- function G(e) {
39
+ function me(e) {
24
40
  return {
25
41
  ...e,
26
- icon: U(e.icon),
27
- props: W(e.props)
42
+ icon: W(e.icon),
43
+ props: G(e.props)
28
44
  };
29
45
  }
30
- function K(e) {
46
+ function he(e) {
31
47
  return {
32
48
  ...e,
33
- icon: U(e.icon),
34
- footerMenuItems: e.footerMenuItems?.map(G),
49
+ icon: W(e.icon),
50
+ footerMenuItems: e.footerMenuItems?.map(me),
35
51
  collections: e.collections?.map((e) => ({
36
52
  ...e,
37
- items: e.items.map(G)
53
+ items: e.items.map(me)
38
54
  }))
39
55
  };
40
56
  }
41
- function pe(e) {
57
+ function K(e) {
42
58
  return {
43
59
  ...e,
44
- groups: e.groups?.map(K)
60
+ groups: e.groups?.map(he)
45
61
  };
46
62
  }
47
- function me(e) {
48
- return e.map(pe);
63
+ function ge(e) {
64
+ return e.map(K);
49
65
  }
50
- function q(e) {
66
+ function _e(e) {
51
67
  (!e.collections || e.collections.length === 0) && (e.collections = [{
52
68
  id: `${e.id}-collection-1`,
53
69
  items: []
54
70
  }]);
55
71
  }
56
- function J(e, t, n, r, i) {
72
+ function q(e, t, n, r, i) {
57
73
  let a = e.find((e) => e.id === t);
58
74
  if (!a?.groups) return;
59
75
  let o = a.groups.find((e) => e.id === n);
@@ -61,10 +77,10 @@ function J(e, t, n, r, i) {
61
77
  let s = o.collections.find((e) => e.id === r);
62
78
  s && i(s.items);
63
79
  }
64
- function he(e, n, r, i, a, o, s, c) {
65
- let l = b(r), u = b(i), d = b(a), f = b(o), p = b(me(n)), m = b(!1), h = b(!1), g = b(!1), _ = b([]), v = b(""), y = b(s), x = b(c), S = t(() => p.value.filter((e) => e.visible !== !1)), C = {
80
+ function ve(e, n, r, i, a, o, s, c) {
81
+ let l = b(r), u = b(i), d = b(a), f = b(o), p = b(ge(n)), m = b(!1), h = b(!1), g = b(!1), _ = b([]), v = b(""), y = b(s), x = b(c), S = t(() => p.value.filter((e) => e.visible !== !1)), C = {
66
82
  addTab(e) {
67
- p.value.push(pe(e)), f.value ||= e.id;
83
+ p.value.push(K(e)), f.value ||= e.id;
68
84
  },
69
85
  removeTab(e) {
70
86
  p.value = p.value.filter((t) => t.id !== e), f.value === e && (f.value = S.value[0]?.id ?? "");
@@ -82,7 +98,7 @@ function he(e, n, r, i, a, o, s, c) {
82
98
  },
83
99
  addGroup(e, t) {
84
100
  let n = p.value.find((t) => t.id === e);
85
- n && (n.groups ??= [], q(t), n.groups.push(K(t)));
101
+ n && (n.groups ??= [], _e(t), n.groups.push(he(t)));
86
102
  },
87
103
  removeGroup(e, t) {
88
104
  let n = p.value.find((t) => t.id === e);
@@ -97,16 +113,16 @@ function he(e, n, r, i, a, o, s, c) {
97
113
  n && (n.visible = !1);
98
114
  },
99
115
  addItem(e, t, n, r) {
100
- J(p.value, e, t, n, (e) => e.push(G(r)));
116
+ q(p.value, e, t, n, (e) => e.push(me(r)));
101
117
  },
102
118
  removeItem(e, t, n, r) {
103
- J(p.value, e, t, n, (e) => {
119
+ q(p.value, e, t, n, (e) => {
104
120
  let t = e.findIndex((e) => e.id === r);
105
121
  t >= 0 && e.splice(t, 1);
106
122
  });
107
123
  },
108
124
  updateItem(e, t, n, r, i) {
109
- J(p.value, e, t, n, (e) => {
125
+ q(p.value, e, t, n, (e) => {
110
126
  let t = e.find((e) => e.id === r);
111
127
  t && Object.assign(t, i);
112
128
  });
@@ -155,7 +171,7 @@ function he(e, n, r, i, a, o, s, c) {
155
171
  }
156
172
  //#endregion
157
173
  //#region src/ribbon/modules/RibbonBackstage.vue?vue&type=script&setup=true&lang.ts
158
- var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backstage__content" }, ve = { key: 0 }, ye = { key: 1 }, Y = /* @__PURE__ */ l({
174
+ var ye = { class: "ml-ribbon-backstage__nav" }, be = { class: "ml-ribbon-backstage__content" }, J = { key: 0 }, Y = { key: 1 }, X = /* @__PURE__ */ l({
159
175
  __name: "RibbonBackstage",
160
176
  props: {
161
177
  open: { type: Boolean },
@@ -170,7 +186,7 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
170
186
  function d() {
171
187
  u("close");
172
188
  }
173
- return (t, o) => (v(), n(E(j), {
189
+ return (t, o) => (v(), n(E(M), {
174
190
  "model-value": l.open,
175
191
  size: "100%",
176
192
  "with-header": !1,
@@ -184,20 +200,20 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
184
200
  title: l.title,
185
201
  description: l.description,
186
202
  size: l.size
187
- }) : (v(), i(e, { key: 1 }, [a("aside", ge, [c(E(ee), {
203
+ }) : (v(), i(e, { key: 1 }, [a("aside", ye, [c(E(te), {
188
204
  type: "primary",
189
205
  onClick: d
190
206
  }, {
191
207
  default: O(() => [s(w(l.backLabel), 1)]),
192
208
  _: 1
193
- })]), a("section", _e, [l.title ? (v(), i("h2", ve, w(l.title), 1)) : r("", !0), l.description ? (v(), i("p", ye, w(l.description), 1)) : r("", !0)])], 64))], 2)]),
209
+ })]), a("section", be, [l.title ? (v(), i("h2", J, w(l.title), 1)) : r("", !0), l.description ? (v(), i("p", Y, w(l.description), 1)) : r("", !0)])], 64))], 2)]),
194
210
  _: 3
195
211
  }, 8, ["model-value"]));
196
212
  }
197
- }), be = {
213
+ }), Z = {
198
214
  class: "ml-ribbon-tabs",
199
215
  role: "tablist"
200
- }, X = [
216
+ }, Q = [
201
217
  "aria-selected",
202
218
  "disabled",
203
219
  "onClick"
@@ -217,7 +233,7 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
217
233
  triggerEl: t.currentTarget instanceof HTMLElement ? t.currentTarget : null
218
234
  });
219
235
  }
220
- return (t, r) => (v(), i("div", be, [(v(!0), i(e, null, x(s.value, (e) => (v(), i("button", {
236
+ return (t, r) => (v(), i("div", Z, [(v(!0), i(e, null, x(s.value, (e) => (v(), i("button", {
221
237
  key: e.id,
222
238
  type: "button",
223
239
  class: m(["ml-ribbon-tab", { "is-active": n.activeTab === e.id }]),
@@ -225,7 +241,7 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
225
241
  "aria-selected": n.activeTab === e.id,
226
242
  disabled: a.disabled,
227
243
  onClick: (t) => c(e.id, t)
228
- }, w(e.title), 11, X))), 128))]));
244
+ }, w(e.title), 11, Q))), 128))]));
229
245
  }
230
246
  }), Se = { class: "ml-ribbon-contextual-tabs" }, Ce = { class: "ml-ribbon-contextual-tabs__normal" }, we = { class: "ml-ribbon-contextual-tabs__ctx" }, Te = /* @__PURE__ */ l({
231
247
  __name: "RibbonContextualTabs",
@@ -273,7 +289,7 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
273
289
  },
274
290
  emits: ["select", "open-backstage"],
275
291
  setup(o, { emit: l }) {
276
- let u = o, d = l, f = b(!1), p = se("size", ""), h = t(() => p.value || "default"), g = t(() => `ml-ribbon-file-menu-dropdown ml-ribbon-popper ml-ribbon-popper--size-${h.value}`);
292
+ let u = o, d = l, f = b(!1), p = oe("size", ""), h = t(() => p.value || "default"), g = t(() => `ml-ribbon-file-menu-dropdown ml-ribbon-popper ml-ribbon-popper--size-${h.value}`);
277
293
  function _(e) {
278
294
  f.value = e;
279
295
  }
@@ -286,21 +302,21 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
286
302
  }
287
303
  return D(() => u.disabled, (e) => {
288
304
  e && (f.value = !1);
289
- }), (t, o) => (v(), n(E(M), {
305
+ }), (t, o) => (v(), n(E(N), {
290
306
  trigger: "click",
291
307
  disabled: u.disabled,
292
308
  "popper-class": g.value,
293
309
  onCommand: y,
294
310
  onVisibleChange: _
295
311
  }, {
296
- dropdown: O(() => [c(E(P), null, {
297
- default: O(() => [u.showOpenBackstage === !1 ? r("", !0) : (v(), n(E(N), {
312
+ dropdown: O(() => [c(E(F), null, {
313
+ default: O(() => [u.showOpenBackstage === !1 ? r("", !0) : (v(), n(E(P), {
298
314
  key: 0,
299
315
  command: "__backstage"
300
316
  }, {
301
317
  default: O(() => [s(w(u.openBackstageLabel), 1)]),
302
318
  _: 1
303
- })), (v(!0), i(e, null, x(u.items, (e, t) => (v(), n(E(N), {
319
+ })), (v(!0), i(e, null, x(u.items, (e, t) => (v(), n(E(P), {
304
320
  key: e.id,
305
321
  divided: u.showOpenBackstage !== !1 && t === 0,
306
322
  command: e.id,
@@ -373,7 +389,7 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
373
389
  function y(e) {
374
390
  o.disabled || c("click", e);
375
391
  }
376
- return (t, a) => (v(), n(E(ee), {
392
+ return (t, a) => (v(), n(E(te), {
377
393
  class: "ml-ribbon-button",
378
394
  "data-ribbon-button-id": e.id,
379
395
  type: e.buttonType,
@@ -389,7 +405,7 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
389
405
  class: m(["ml-ribbon-item-host__icon ml-ribbon-button__icon", g.value]),
390
406
  style: h(_.value),
391
407
  "aria-hidden": "true"
392
- }, [S(t.$slots, "icon")], 6)) : f.value ? (v(), n(E(F), {
408
+ }, [S(t.$slots, "icon")], 6)) : f.value ? (v(), n(E(I), {
393
409
  key: 1,
394
410
  class: m(["ml-ribbon-item-host__icon ml-ribbon-button__icon", g.value]),
395
411
  style: h(_.value)
@@ -476,7 +492,7 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
476
492
  }]),
477
493
  "data-id": t.id
478
494
  }, [!t.hideLabel && t.label ? (v(), i("div", Me, w(t.label), 1)) : r("", !0), c(E(A), null, {
479
- default: O(() => [(v(!0), i(e, null, x(t.options, (e) => (v(), n(E(z), {
495
+ default: O(() => [(v(!0), i(e, null, x(t.options, (e) => (v(), n(E(ae), {
480
496
  key: String(e.value),
481
497
  content: g(e),
482
498
  disabled: !g(e),
@@ -524,7 +540,7 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
524
540
  }), Fe = { class: "ml-ribbon-item-host__content ml-ribbon-dropdown__content" }, Ie = { class: "ml-ribbon-item-host__text-row ml-ribbon-dropdown__text-row" }, Le = {
525
541
  key: 0,
526
542
  class: "ml-ribbon-item-host__label ml-ribbon-dropdown__label"
527
- }, Z = { class: "ml-ribbon-dropdown-item__content" }, Re = { class: "ml-ribbon-dropdown-item__label" }, ze = /* @__PURE__ */ l({
543
+ }, Re = { class: "ml-ribbon-dropdown-item__content" }, ze = { class: "ml-ribbon-dropdown-item__label" }, Be = /* @__PURE__ */ l({
528
544
  name: "MlRibbonDropdown",
529
545
  __name: "RibbonDropdown",
530
546
  props: {
@@ -556,33 +572,33 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
556
572
  "tooltip-change"
557
573
  ],
558
574
  setup(o, { emit: l }) {
559
- let u = o, d = l, f = se("size", ""), p = t(() => f.value || "default"), h = b(!1), g = b(void 0), _ = t(() => Array.isArray(u.options) ? u.options : []), y = t(() => _.value.find((e) => V(e) === g.value) ?? null), T = t(() => {
575
+ let u = o, d = l, f = oe("size", ""), p = t(() => f.value || "default"), h = b(!1), g = b(void 0), _ = t(() => Array.isArray(u.options) ? u.options : []), y = t(() => _.value.find((e) => V(e) === g.value) ?? null), T = t(() => {
560
576
  if (y.value && u.syncLabelWithSelection) {
561
577
  let e = le(y.value);
562
578
  if (e) return e;
563
579
  }
564
580
  return fe(u.label) ?? u.id;
565
- }), D = t(() => !u.hideLabel && T.value.length > 0), A = t(() => {
581
+ }), D = t(() => !u.hideLabel && T.value.length > 0), k = t(() => {
566
582
  if (y.value) {
567
- let e = oe(y.value);
583
+ let e = z(y.value);
568
584
  if (e) return e;
569
585
  }
570
586
  return !u.icon || typeof u.icon == "string" ? null : u.icon;
571
- }), te = t(() => {
587
+ }), A = t(() => {
572
588
  if (y.value) {
573
- let e = R(y.value);
589
+ let e = B(y.value);
574
590
  if (e) return e;
575
591
  }
576
592
  if (typeof u.icon != "string") return null;
577
593
  let e = u.icon.trim();
578
594
  return e.length > 0 ? e : null;
579
- }), ne = t(() => !!(A.value || te.value)), re = t(() => de(y.value) ?? fe(u.tooltip) ?? fe(T.value) ?? fe(u.label) ?? U(u.id)), j = t(() => [
595
+ }), ne = t(() => !!(k.value || A.value)), j = t(() => de(y.value) ?? fe(u.tooltip) ?? fe(T.value) ?? fe(u.label) ?? U(u.id)), re = t(() => [
580
596
  "ml-ribbon-dropdown-menu",
581
597
  "ml-ribbon-popper",
582
598
  `ml-ribbon-popper--size-${p.value}`,
583
599
  u.popperClass
584
600
  ].filter(Boolean).join(" "));
585
- function I(e) {
601
+ function M(e) {
586
602
  if (u.disabled) {
587
603
  h.value = !1;
588
604
  return;
@@ -592,10 +608,10 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
592
608
  function ie() {
593
609
  u.disabled || (h.value = !h.value);
594
610
  }
595
- function ae(e) {
596
- u.disabled || (g.value = e, d("tooltip-change", de(y.value) ?? re.value), d("command", e), h.value = !1);
611
+ function L(e) {
612
+ u.disabled || (g.value = e, d("tooltip-change", de(y.value) ?? j.value), d("command", e), h.value = !1);
597
613
  }
598
- function L() {
614
+ function R() {
599
615
  if (u.disabled) return;
600
616
  let e = y.value;
601
617
  if (!e) {
@@ -604,12 +620,12 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
604
620
  }
605
621
  d("command", V(e));
606
622
  }
607
- function oe(e) {
623
+ function z(e) {
608
624
  if (!e || typeof e != "object") return null;
609
625
  let t = e.icon;
610
626
  return !t || typeof t == "string" ? null : t;
611
627
  }
612
- function R(e) {
628
+ function B(e) {
613
629
  if (!e || typeof e != "object") return null;
614
630
  let t = e.icon;
615
631
  return typeof t != "string" || t.trim().length === 0 ? null : t;
@@ -617,7 +633,7 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
617
633
  function V(e) {
618
634
  if (!(!e || typeof e != "object")) return e.value;
619
635
  }
620
- function ce(e) {
636
+ function se(e) {
621
637
  let t = V(e);
622
638
  if (typeof t == "string" || typeof t == "number" || t && typeof t == "object") return t;
623
639
  }
@@ -642,21 +658,21 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
642
658
  let t = e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " ").trim();
643
659
  return t ? t.replace(/\b\w/g, (e) => e.toUpperCase()) : e;
644
660
  }
645
- return (t, l) => (v(), n(E(M), {
661
+ return (t, l) => (v(), n(E(N), {
646
662
  class: m(["ml-ribbon-dropdown", [`ml-ribbon-dropdown--item-${o.itemSize}`, { "is-label-hidden": o.hideLabel }]]),
647
663
  trigger: "click",
648
664
  disabled: o.disabled,
649
- "popper-class": j.value,
650
- onVisibleChange: I,
651
- onCommand: ae
665
+ "popper-class": re.value,
666
+ onVisibleChange: M,
667
+ onCommand: L
652
668
  }, {
653
- dropdown: O(() => [c(E(P), null, {
654
- default: O(() => [(v(!0), i(e, null, x(_.value, (e) => (v(), n(E(N), {
669
+ dropdown: O(() => [c(E(F), null, {
670
+ default: O(() => [(v(!0), i(e, null, x(_.value, (e) => (v(), n(E(P), {
655
671
  key: String(V(e)),
656
- command: ce(e),
672
+ command: se(e),
657
673
  disabled: e.disabled === !0
658
674
  }, {
659
- default: O(() => [c(E(z), {
675
+ default: O(() => [c(E(ae), {
660
676
  content: de(e),
661
677
  disabled: !de(e),
662
678
  "show-after": o.tooltipShowAfter,
@@ -664,17 +680,17 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
664
680
  placement: "top",
665
681
  effect: "dark"
666
682
  }, {
667
- default: O(() => [a("span", Z, [S(t.$slots, "option", { option: e }, () => [oe(e) ? (v(), n(E(F), {
683
+ default: O(() => [a("span", Re, [S(t.$slots, "option", { option: e }, () => [z(e) ? (v(), n(E(I), {
668
684
  key: 0,
669
685
  class: "ml-ribbon-dropdown-item__icon"
670
686
  }, {
671
- default: O(() => [(v(), n(C(oe(e))))]),
687
+ default: O(() => [(v(), n(C(z(e))))]),
672
688
  _: 2
673
- }, 1024)) : R(e) ? (v(), i("i", {
689
+ }, 1024)) : B(e) ? (v(), i("i", {
674
690
  key: 1,
675
- class: m(["ml-ribbon-dropdown-item__icon ml-ribbon-dropdown-item__icon--class", R(e)]),
691
+ class: m(["ml-ribbon-dropdown-item__icon ml-ribbon-dropdown-item__icon--class", B(e)]),
676
692
  "aria-hidden": "true"
677
- }, null, 2)) : r("", !0), a("span", Re, w(le(e)), 1)])])]),
693
+ }, null, 2)) : r("", !0), a("span", ze, w(le(e)), 1)])])]),
678
694
  _: 2
679
695
  }, 1032, [
680
696
  "content",
@@ -686,28 +702,28 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
686
702
  }, 1032, ["command", "disabled"]))), 128))]),
687
703
  _: 3
688
704
  })]),
689
- default: O(() => [c(E(ee), {
705
+ default: O(() => [c(E(te), {
690
706
  type: "default",
691
707
  disabled: o.disabled,
692
- "aria-label": re.value,
708
+ "aria-label": j.value,
693
709
  onClick: ie
694
710
  }, {
695
711
  default: O(() => [a("span", Fe, [t.$slots.icon || ne.value ? (v(), i("span", {
696
712
  key: 0,
697
- class: m(["ml-ribbon-item-host__icon ml-ribbon-item-host__icon--dropdown-primary ml-ribbon-dropdown__icon", { "ml-ribbon-item-host__icon--class": te.value && !A.value && !t.$slots.icon }]),
698
- onClick: k(L, ["stop"])
699
- }, [S(t.$slots, "icon", { selectedOption: y.value }, () => [A.value ? (v(), n(E(F), { key: 0 }, {
700
- default: O(() => [(v(), n(C(A.value)))]),
713
+ class: m(["ml-ribbon-item-host__icon ml-ribbon-item-host__icon--dropdown-primary ml-ribbon-dropdown__icon", { "ml-ribbon-item-host__icon--class": A.value && !k.value && !t.$slots.icon }]),
714
+ onClick: ee(R, ["stop"])
715
+ }, [S(t.$slots, "icon", { selectedOption: y.value }, () => [k.value ? (v(), n(E(I), { key: 0 }, {
716
+ default: O(() => [(v(), n(C(k.value)))]),
701
717
  _: 1
702
- })) : te.value ? (v(), i("i", {
718
+ })) : A.value ? (v(), i("i", {
703
719
  key: 1,
704
- class: m(te.value),
720
+ class: m(A.value),
705
721
  "aria-hidden": "true"
706
722
  }, null, 2)) : r("", !0)])], 2)) : r("", !0), a("span", Ie, [D.value ? (v(), i("span", Le, [S(t.$slots, "label", {
707
723
  selectedOption: y.value,
708
724
  label: T.value
709
- }, () => [s(w(T.value), 1)])])) : r("", !0), c(E(F), { class: m(["ml-ribbon-item-host__dropdown-arrow ml-ribbon-dropdown__arrow", { "is-open": h.value }]) }, {
710
- default: O(() => [(v(), n(C(h.value ? E(H) : E(B))))]),
725
+ }, () => [s(w(T.value), 1)])])) : r("", !0), c(E(I), { class: m(["ml-ribbon-item-host__dropdown-arrow ml-ribbon-dropdown__arrow", { "is-open": h.value }]) }, {
726
+ default: O(() => [(v(), n(C(h.value ? E(ce) : E(H))))]),
711
727
  _: 1
712
728
  }, 8, ["class"])])])]),
713
729
  _: 3
@@ -719,13 +735,51 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
719
735
  "popper-class"
720
736
  ]));
721
737
  }
722
- }), Be = {
738
+ }), Ve = ["disabled"], He = ["src"], Ue = {
739
+ key: 3,
740
+ class: "ml-ribbon-gallery__preview-svg",
741
+ role: "presentation",
742
+ "aria-hidden": "true"
743
+ }, We = ["href"], Ge = { class: "ml-ribbon-gallery__label ml-ribbon-gallery__collapsed-label" }, Ke = { class: "ml-ribbon-gallery__panel" }, qe = {
723
744
  key: 0,
745
+ class: "ml-ribbon-gallery__panel-category-title"
746
+ }, Je = ["disabled", "onClick"], Ye = ["src"], Xe = {
747
+ key: 3,
748
+ class: "ml-ribbon-gallery__preview-svg",
749
+ role: "presentation",
750
+ "aria-hidden": "true"
751
+ }, Ze = ["href"], $ = { class: "ml-ribbon-gallery__label" }, Qe = {
752
+ key: 1,
724
753
  class: "ml-ribbon-gallery__title"
725
- }, Ve = { class: "ml-ribbon-gallery__categories" }, He = {
754
+ }, $e = {
755
+ key: 2,
756
+ class: "ml-ribbon-gallery__categories"
757
+ }, et = {
726
758
  key: 0,
727
759
  class: "ml-ribbon-gallery__category-title"
728
- }, Ue = { class: "ml-ribbon-gallery__grid" }, We = ["disabled", "onClick"], Q = { class: "ml-ribbon-gallery__preview" }, Ge = { class: "ml-ribbon-gallery__label" }, Ke = /* @__PURE__ */ l({
760
+ }, tt = ["disabled", "onClick"], nt = ["src"], rt = {
761
+ key: 3,
762
+ class: "ml-ribbon-gallery__preview-svg",
763
+ role: "presentation",
764
+ "aria-hidden": "true"
765
+ }, it = ["href"], at = { class: "ml-ribbon-gallery__label" }, ot = {
766
+ key: 0,
767
+ class: "ml-ribbon-gallery__controls",
768
+ "aria-label": "Gallery navigation"
769
+ }, st = ["disabled"], ct = ["disabled"], lt = ["disabled"], ut = {
770
+ key: 0,
771
+ class: "ml-ribbon-gallery__panel-category-title"
772
+ }, dt = [
773
+ "data-gallery-row-index",
774
+ "disabled",
775
+ "onClick"
776
+ ], ft = ["src"], pt = {
777
+ key: 3,
778
+ class: "ml-ribbon-gallery__preview-svg",
779
+ role: "presentation",
780
+ "aria-hidden": "true"
781
+ }, mt = ["href"], ht = { class: "ml-ribbon-gallery__label" }, gt = 6, _t = 64, vt = 4, yt = 16, bt = 4, xt = 22, St = /* @__PURE__ */ l({
782
+ name: "MlRibbonGallery",
729
783
  __name: "RibbonGallery",
730
784
  props: {
731
785
  id: {},
@@ -735,39 +789,474 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
735
789
  type: Boolean,
736
790
  default: !1
737
791
  },
792
+ modelValue: {},
793
+ collapsed: {
794
+ type: Boolean,
795
+ default: !1
796
+ },
797
+ inlineItemLimit: { default: 4 },
738
798
  previewFallback: {}
739
799
  },
740
800
  emits: ["select"],
741
- setup(n, { emit: o }) {
742
- let s = n, c = o, l = b(""), u = t(() => s.categories.filter((e) => e.items.length > 0).length);
743
- function d(e) {
744
- let t = s.label.trim().toLowerCase(), n = e.title.trim().toLowerCase();
745
- return u.value > 1 || !t || n !== t;
801
+ setup(o, { emit: l }) {
802
+ let u = o, g = l, _ = b(""), y = b(!1), k = b(0), ee = b(null), te = b(null), A = b(null), ne = b(0), j = oe("size", ""), re = t(() => j.value || "default"), M = t(() => re.value === "small" ? .92 : re.value === "large" ? 1.08 : 1), N = t(() => Math.round(_t * M.value)), P = t(() => Math.round(xt * M.value)), F = t(() => u.label?.trim() ?? ""), ie = t(() => u.categories.filter((e) => e.items.length > 0).length), L = t(() => u.categories.flatMap((e) => e.items)), z = t(() => L.value.find((e) => e.id === _.value) ?? L.value[0]), B = t(() => !Number.isFinite(u.inlineItemLimit) || u.inlineItemLimit <= 0 ? 4 : Math.floor(u.inlineItemLimit)), V = t(() => Math.max(1, Math.ceil(L.value.length / B.value))), ae = t(() => Math.min(k.value, V.value - 1)), se = t(() => U.value && ae.value > 0), le = t(() => U.value && ae.value < V.value - 1), de = t(() => {
803
+ let e = ae.value * B.value;
804
+ return L.value.slice(e, e + B.value);
805
+ }), fe = t(() => new Set(de.value.map((e) => e.id))), U = t(() => L.value.length > B.value), pe = t(() => `ml-ribbon-gallery-panel ml-ribbon-gallery-panel--${u.collapsed ? "collapsed" : "inline"} ml-ribbon-gallery-panel--size-${re.value}`), W = t(() => ({
806
+ "--ml-ribbon-gallery-panel-columns": String(B.value),
807
+ "--ml-ribbon-gallery-panel-item-width": `${N.value}px`
808
+ })), G = t(() => B.value * N.value + Math.max(0, B.value - 1) * vt + gt * 2 + (u.collapsed ? yt : bt + P.value)), me = t(() => ({ modifiers: [{
809
+ name: "offset",
810
+ options: { offset: [ne.value, 0] }
811
+ }] }));
812
+ D(() => u.modelValue, (e) => {
813
+ typeof e == "string" && (_.value = e, ve(e));
814
+ }, { immediate: !0 }), D(() => [
815
+ L.value.map((e) => e.id).join("\0"),
816
+ B.value,
817
+ _.value
818
+ ], () => {
819
+ ve() || (k.value = Math.min(k.value, V.value - 1));
820
+ }), D(y, async (e) => {
821
+ !e || u.collapsed || (ye(), await p(), await p(), be());
822
+ });
823
+ function he(e) {
824
+ return e == null || typeof e == "string" ? e : typeof e == "object" || typeof e == "function" ? d(T(e)) : e;
746
825
  }
747
- function f(e) {
748
- s.disabled || (l.value = e, c("select", e));
826
+ function K(e) {
827
+ let t = F.value.toLowerCase(), n = e.title.trim().toLowerCase();
828
+ return ie.value > 1 || !t || n !== t;
749
829
  }
750
- return (t, o) => (v(), i("div", { class: m(["ml-ribbon-gallery", { "is-disabled": n.disabled }]) }, [n.label ? (v(), i("div", Be, w(n.label), 1)) : r("", !0), a("div", Ve, [(v(!0), i(e, null, x(n.categories, (t) => (v(), i("section", {
751
- key: t.id,
752
- class: "ml-ribbon-gallery__category"
753
- }, [d(t) ? (v(), i("h4", He, w(t.title), 1)) : r("", !0), a("div", Ue, [(v(!0), i(e, null, x(t.items, (e) => (v(), i("button", {
754
- key: e.id,
755
- type: "button",
756
- class: m(["ml-ribbon-gallery__item", { "is-selected": l.value === e.id }]),
757
- disabled: n.disabled,
758
- onClick: (t) => f(e.id)
759
- }, [a("div", Q, w(e.preview ?? s.previewFallback), 1), a("div", Ge, w(e.label), 1)], 10, We))), 128))])]))), 128))])], 2));
830
+ function ge(e) {
831
+ return U.value ? e.items.filter((e) => fe.value.has(e.id)) : e.items;
832
+ }
833
+ function _e(e) {
834
+ if (u.disabled || !U.value) return;
835
+ let t = ae.value + e;
836
+ k.value = Math.min(Math.max(t, 0), V.value - 1);
837
+ }
838
+ function q(e) {
839
+ let t = L.value.findIndex((t) => t.id === e.id);
840
+ return t < 0 ? 0 : Math.floor(t / B.value);
841
+ }
842
+ function ve(e = _.value) {
843
+ let t = L.value.find((t) => t.id === e);
844
+ return t ? (k.value = q(t), !0) : !1;
845
+ }
846
+ function ye() {
847
+ let e = ee.value, t = te.value;
848
+ if (!e || !t) {
849
+ ne.value = 0;
850
+ return;
851
+ }
852
+ let n = e.querySelector(".ml-ribbon-gallery__grid .ml-ribbon-gallery__item")?.getBoundingClientRect().left ?? e.getBoundingClientRect().left;
853
+ ne.value = Math.round(n - t.getBoundingClientRect().left - gt);
854
+ }
855
+ function be() {
856
+ let e = A.value;
857
+ e && e.querySelector(`[data-gallery-row-index="${ae.value}"]`)?.scrollIntoView?.({ block: "start" });
858
+ }
859
+ function J(e) {
860
+ return e.preview && typeof e.preview != "string" ? he(e.preview) : e.icon && typeof e.icon != "string" ? he(e.icon) : null;
861
+ }
862
+ function Y(e) {
863
+ return e.component ? he(e.component) : null;
864
+ }
865
+ function X(e) {
866
+ return u.disabled || e.disabled === !0;
867
+ }
868
+ function Z(e) {
869
+ if (typeof e.icon != "string") return null;
870
+ let t = e.icon.trim();
871
+ return t.length > 0 ? t : null;
872
+ }
873
+ function Q(e) {
874
+ let t = e.previewSvg ?? e.svg;
875
+ if (typeof t != "string") return null;
876
+ let n = t.trim();
877
+ return n.length > 0 ? n : null;
878
+ }
879
+ function xe(e) {
880
+ return e.startsWith("data:image/svg+xml") || e.endsWith(".svg");
881
+ }
882
+ function Se(e) {
883
+ let t = Q(e);
884
+ return t ? xe(t) : !1;
885
+ }
886
+ function Ce(e) {
887
+ return typeof e.preview == "string" ? e.preview : u.previewFallback;
888
+ }
889
+ function we(e) {
890
+ X(e) || (_.value = e.id, k.value = q(e), y.value = !1, g("select", e.id));
891
+ }
892
+ return (t, l) => (v(), i("div", {
893
+ ref_key: "galleryRef",
894
+ ref: ee,
895
+ class: m(["ml-ribbon-gallery", {
896
+ "is-disabled": o.disabled,
897
+ "is-collapsed": o.collapsed,
898
+ "is-unlabeled": !o.collapsed && !F.value
899
+ }])
900
+ }, [
901
+ o.collapsed && z.value ? (v(), n(E(R), {
902
+ key: 0,
903
+ visible: y.value,
904
+ "onUpdate:visible": l[0] ||= (e) => y.value = e,
905
+ trigger: "click",
906
+ placement: "bottom-start",
907
+ disabled: o.disabled,
908
+ width: G.value,
909
+ "popper-class": pe.value
910
+ }, {
911
+ reference: O(() => [a("button", {
912
+ type: "button",
913
+ class: m(["ml-ribbon-gallery__collapsed-button", {
914
+ "is-selected": _.value === z.value.id,
915
+ "is-open": y.value
916
+ }]),
917
+ disabled: X(z.value)
918
+ }, [Y(z.value) ? (v(), n(C(Y(z.value)), f({ key: 0 }, z.value.componentProps, {
919
+ item: z.value,
920
+ selected: _.value === z.value.id,
921
+ disabled: X(z.value)
922
+ }), null, 16, [
923
+ "item",
924
+ "selected",
925
+ "disabled"
926
+ ])) : (v(), i(e, { key: 1 }, [a("div", { class: m(["ml-ribbon-gallery__preview ml-ribbon-gallery__collapsed-preview", {
927
+ "ml-ribbon-gallery__preview--icon": J(z.value) || Z(z.value),
928
+ "ml-ribbon-gallery__preview--svg": Q(z.value)
929
+ }]) }, [J(z.value) ? (v(), n(E(I), {
930
+ key: 0,
931
+ class: "ml-ribbon-gallery__preview-icon"
932
+ }, {
933
+ default: O(() => [(v(), n(C(J(z.value))))]),
934
+ _: 1
935
+ })) : Z(z.value) ? (v(), i("i", {
936
+ key: 1,
937
+ class: m(["ml-ribbon-gallery__preview-icon ml-ribbon-gallery__preview-icon--class", Z(z.value)]),
938
+ "aria-hidden": "true"
939
+ }, null, 2)) : Q(z.value) && Se(z.value) ? (v(), i("img", {
940
+ key: 2,
941
+ class: "ml-ribbon-gallery__preview-svg",
942
+ src: Q(z.value) ?? "",
943
+ alt: ""
944
+ }, null, 8, He)) : Q(z.value) ? (v(), i("svg", Ue, [a("use", { href: Q(z.value) ?? "" }, null, 8, We)])) : (v(), i(e, { key: 4 }, [s(w(Ce(z.value)), 1)], 64))], 2), a("div", Ge, w(z.value.label), 1)], 64))], 10, Ve)]),
945
+ default: O(() => [a("div", Ke, [(v(!0), i(e, null, x(o.categories, (o) => (v(), i("section", {
946
+ key: o.id,
947
+ class: "ml-ribbon-gallery__panel-category"
948
+ }, [K(o) ? (v(), i("h4", qe, w(o.title), 1)) : r("", !0), a("div", {
949
+ class: "ml-ribbon-gallery__panel-grid",
950
+ style: h(W.value)
951
+ }, [(v(!0), i(e, null, x(o.items, (r) => (v(), i("button", {
952
+ key: r.id,
953
+ type: "button",
954
+ class: m(["ml-ribbon-gallery__item ml-ribbon-gallery__panel-item", { "is-selected": _.value === r.id }]),
955
+ disabled: X(r),
956
+ onClick: (e) => we(r)
957
+ }, [S(t.$slots, "item", {
958
+ item: r,
959
+ category: o,
960
+ selected: _.value === r.id,
961
+ disabled: X(r),
962
+ select: () => we(r)
963
+ }, () => [Y(r) ? (v(), n(C(Y(r)), f({
964
+ key: 0,
965
+ ref_for: !0
966
+ }, r.componentProps, {
967
+ item: r,
968
+ category: o,
969
+ selected: _.value === r.id,
970
+ disabled: X(r)
971
+ }), null, 16, [
972
+ "item",
973
+ "category",
974
+ "selected",
975
+ "disabled"
976
+ ])) : (v(), i(e, { key: 1 }, [a("div", { class: m(["ml-ribbon-gallery__preview", {
977
+ "ml-ribbon-gallery__preview--icon": J(r) || Z(r),
978
+ "ml-ribbon-gallery__preview--svg": Q(r)
979
+ }]) }, [J(r) ? (v(), n(E(I), {
980
+ key: 0,
981
+ class: "ml-ribbon-gallery__preview-icon"
982
+ }, {
983
+ default: O(() => [(v(), n(C(J(r))))]),
984
+ _: 2
985
+ }, 1024)) : Z(r) ? (v(), i("i", {
986
+ key: 1,
987
+ class: m(["ml-ribbon-gallery__preview-icon ml-ribbon-gallery__preview-icon--class", Z(r)]),
988
+ "aria-hidden": "true"
989
+ }, null, 2)) : Q(r) && Se(r) ? (v(), i("img", {
990
+ key: 2,
991
+ class: "ml-ribbon-gallery__preview-svg",
992
+ src: Q(r) ?? "",
993
+ alt: ""
994
+ }, null, 8, Ye)) : Q(r) ? (v(), i("svg", Xe, [a("use", { href: Q(r) ?? "" }, null, 8, Ze)])) : (v(), i(e, { key: 4 }, [s(w(Ce(r)), 1)], 64))], 2), a("div", $, w(r.label), 1)], 64))])], 10, Je))), 128))], 4)]))), 128))])]),
995
+ _: 3
996
+ }, 8, [
997
+ "visible",
998
+ "disabled",
999
+ "width",
1000
+ "popper-class"
1001
+ ])) : r("", !0),
1002
+ !o.collapsed && F.value ? (v(), i("div", Qe, w(F.value), 1)) : r("", !0),
1003
+ o.collapsed ? r("", !0) : (v(), i("div", $e, [(v(!0), i(e, null, x(o.categories, (o) => (v(), i("section", {
1004
+ key: o.id,
1005
+ class: "ml-ribbon-gallery__category"
1006
+ }, [F.value && K(o) ? (v(), i("h4", et, w(o.title), 1)) : r("", !0), a("div", {
1007
+ class: "ml-ribbon-gallery__grid",
1008
+ style: h({ "--ml-ribbon-gallery-inline-columns": String(B.value) })
1009
+ }, [(v(!0), i(e, null, x(ge(o), (r) => (v(), i("button", {
1010
+ key: r.id,
1011
+ type: "button",
1012
+ class: m(["ml-ribbon-gallery__item", { "is-selected": _.value === r.id }]),
1013
+ disabled: X(r),
1014
+ onClick: (e) => we(r)
1015
+ }, [S(t.$slots, "item", {
1016
+ item: r,
1017
+ category: o,
1018
+ selected: _.value === r.id,
1019
+ disabled: X(r),
1020
+ select: () => we(r)
1021
+ }, () => [Y(r) ? (v(), n(C(Y(r)), f({
1022
+ key: 0,
1023
+ ref_for: !0
1024
+ }, r.componentProps, {
1025
+ item: r,
1026
+ category: o,
1027
+ selected: _.value === r.id,
1028
+ disabled: X(r)
1029
+ }), null, 16, [
1030
+ "item",
1031
+ "category",
1032
+ "selected",
1033
+ "disabled"
1034
+ ])) : (v(), i(e, { key: 1 }, [a("div", { class: m(["ml-ribbon-gallery__preview", {
1035
+ "ml-ribbon-gallery__preview--icon": J(r) || Z(r),
1036
+ "ml-ribbon-gallery__preview--svg": Q(r)
1037
+ }]) }, [J(r) ? (v(), n(E(I), {
1038
+ key: 0,
1039
+ class: "ml-ribbon-gallery__preview-icon"
1040
+ }, {
1041
+ default: O(() => [(v(), n(C(J(r))))]),
1042
+ _: 2
1043
+ }, 1024)) : Z(r) ? (v(), i("i", {
1044
+ key: 1,
1045
+ class: m(["ml-ribbon-gallery__preview-icon ml-ribbon-gallery__preview-icon--class", Z(r)]),
1046
+ "aria-hidden": "true"
1047
+ }, null, 2)) : Q(r) && Se(r) ? (v(), i("img", {
1048
+ key: 2,
1049
+ class: "ml-ribbon-gallery__preview-svg",
1050
+ src: Q(r) ?? "",
1051
+ alt: ""
1052
+ }, null, 8, nt)) : Q(r) ? (v(), i("svg", rt, [a("use", { href: Q(r) ?? "" }, null, 8, it)])) : (v(), i(e, { key: 4 }, [s(w(Ce(r)), 1)], 64))], 2), a("div", at, w(r.label), 1)], 64))])], 10, tt))), 128))], 4)]))), 128)), U.value ? (v(), i("div", ot, [
1053
+ a("button", {
1054
+ type: "button",
1055
+ class: "ml-ribbon-gallery__control-button",
1056
+ disabled: o.disabled || !se.value,
1057
+ "aria-label": "Show previous gallery row",
1058
+ onClick: l[1] ||= (e) => _e(-1)
1059
+ }, [c(E(I), null, {
1060
+ default: O(() => [c(E(ce))]),
1061
+ _: 1
1062
+ })], 8, st),
1063
+ a("button", {
1064
+ type: "button",
1065
+ class: "ml-ribbon-gallery__control-button",
1066
+ disabled: o.disabled || !le.value,
1067
+ "aria-label": "Show next gallery row",
1068
+ onClick: l[2] ||= (e) => _e(1)
1069
+ }, [c(E(I), null, {
1070
+ default: O(() => [c(E(H))]),
1071
+ _: 1
1072
+ })], 8, ct),
1073
+ c(E(R), {
1074
+ visible: y.value,
1075
+ "onUpdate:visible": l[3] ||= (e) => y.value = e,
1076
+ trigger: "click",
1077
+ placement: "bottom-start",
1078
+ disabled: o.disabled,
1079
+ width: G.value,
1080
+ "popper-class": pe.value,
1081
+ "popper-options": me.value
1082
+ }, {
1083
+ reference: O(() => [a("button", {
1084
+ ref_key: "inlineMoreButtonRef",
1085
+ ref: te,
1086
+ type: "button",
1087
+ class: m(["ml-ribbon-gallery__control-button ml-ribbon-gallery__more-button", { "is-open": y.value }]),
1088
+ disabled: o.disabled,
1089
+ "aria-label": "Show more gallery items",
1090
+ onClick: ye
1091
+ }, [c(E(I), null, {
1092
+ default: O(() => [c(E(ue))]),
1093
+ _: 1
1094
+ })], 10, lt)]),
1095
+ default: O(() => [a("div", {
1096
+ ref_key: "inlinePanelRef",
1097
+ ref: A,
1098
+ class: "ml-ribbon-gallery__panel"
1099
+ }, [(v(!0), i(e, null, x(o.categories, (o) => (v(), i("section", {
1100
+ key: o.id,
1101
+ class: "ml-ribbon-gallery__panel-category"
1102
+ }, [K(o) ? (v(), i("h4", ut, w(o.title), 1)) : r("", !0), a("div", {
1103
+ class: "ml-ribbon-gallery__panel-grid",
1104
+ style: h(W.value)
1105
+ }, [(v(!0), i(e, null, x(o.items, (r) => (v(), i("button", {
1106
+ key: r.id,
1107
+ type: "button",
1108
+ class: m(["ml-ribbon-gallery__item ml-ribbon-gallery__panel-item", { "is-selected": _.value === r.id }]),
1109
+ "data-gallery-row-index": q(r),
1110
+ disabled: X(r),
1111
+ onClick: (e) => we(r)
1112
+ }, [S(t.$slots, "item", {
1113
+ item: r,
1114
+ category: o,
1115
+ selected: _.value === r.id,
1116
+ disabled: X(r),
1117
+ select: () => we(r)
1118
+ }, () => [Y(r) ? (v(), n(C(Y(r)), f({
1119
+ key: 0,
1120
+ ref_for: !0
1121
+ }, r.componentProps, {
1122
+ item: r,
1123
+ category: o,
1124
+ selected: _.value === r.id,
1125
+ disabled: X(r)
1126
+ }), null, 16, [
1127
+ "item",
1128
+ "category",
1129
+ "selected",
1130
+ "disabled"
1131
+ ])) : (v(), i(e, { key: 1 }, [a("div", { class: m(["ml-ribbon-gallery__preview", {
1132
+ "ml-ribbon-gallery__preview--icon": J(r) || Z(r),
1133
+ "ml-ribbon-gallery__preview--svg": Q(r)
1134
+ }]) }, [J(r) ? (v(), n(E(I), {
1135
+ key: 0,
1136
+ class: "ml-ribbon-gallery__preview-icon"
1137
+ }, {
1138
+ default: O(() => [(v(), n(C(J(r))))]),
1139
+ _: 2
1140
+ }, 1024)) : Z(r) ? (v(), i("i", {
1141
+ key: 1,
1142
+ class: m(["ml-ribbon-gallery__preview-icon ml-ribbon-gallery__preview-icon--class", Z(r)]),
1143
+ "aria-hidden": "true"
1144
+ }, null, 2)) : Q(r) && Se(r) ? (v(), i("img", {
1145
+ key: 2,
1146
+ class: "ml-ribbon-gallery__preview-svg",
1147
+ src: Q(r) ?? "",
1148
+ alt: ""
1149
+ }, null, 8, ft)) : Q(r) ? (v(), i("svg", pt, [a("use", { href: Q(r) ?? "" }, null, 8, mt)])) : (v(), i(e, { key: 4 }, [s(w(Ce(r)), 1)], 64))], 2), a("div", ht, w(r.label), 1)], 64))])], 10, dt))), 128))], 4)]))), 128))], 512)]),
1150
+ _: 3
1151
+ }, 8, [
1152
+ "visible",
1153
+ "disabled",
1154
+ "width",
1155
+ "popper-class",
1156
+ "popper-options"
1157
+ ])
1158
+ ])) : r("", !0)]))
1159
+ ], 2));
1160
+ }
1161
+ }), Ct = ["data-id", "onKeydown"], wt = {
1162
+ key: 0,
1163
+ class: "ml-ribbon-input-number__prefix"
1164
+ }, Tt = {
1165
+ key: 2,
1166
+ class: "ml-ribbon-input-number__prefix-label"
1167
+ }, Et = /* @__PURE__ */ l({
1168
+ name: "MlRibbonInputNumber",
1169
+ __name: "RibbonInputNumber",
1170
+ props: {
1171
+ id: {},
1172
+ modelValue: { default: void 0 },
1173
+ width: { default: "96px" },
1174
+ prefixLabel: { default: void 0 },
1175
+ prefixIcon: { default: void 0 },
1176
+ prefixIconClass: { default: void 0 },
1177
+ controlProps: { default: () => ({}) },
1178
+ disabled: {
1179
+ type: Boolean,
1180
+ default: !1
1181
+ }
1182
+ },
1183
+ emits: ["change"],
1184
+ setup(e, { emit: a }) {
1185
+ let o = e, s = a, l = t(() => re(o.width, "96px")), u = t(() => l.value === "100%"), d = t(() => u.value ? { width: "100%" } : {}), p = t(() => u.value ? {} : { width: l.value }), g = t(() => j(o.prefixLabel)), _ = t(() => !o.prefixIcon || typeof o.prefixIcon == "string" ? null : o.prefixIcon), y = t(() => j(o.prefixIconClass ?? (typeof o.prefixIcon == "string" ? o.prefixIcon : void 0)) ?? null), x = t(() => !!(g.value || _.value || y.value)), S = t(() => g.value ?? o.id), T = b(void 0);
1186
+ function D(e) {
1187
+ A(e);
1188
+ }
1189
+ function te(e) {
1190
+ e.preventDefault(), e.stopPropagation();
1191
+ let t = e.target;
1192
+ if (!(t instanceof HTMLInputElement)) return;
1193
+ let n = ne(t.value);
1194
+ n === void 0 && t.value.trim().length > 0 || A(n);
1195
+ }
1196
+ function A(e) {
1197
+ Object.is(T.value, e) || (T.value = e, s("change", e));
1198
+ }
1199
+ function ne(e) {
1200
+ let t = e.trim();
1201
+ if (!t) return;
1202
+ let n = Number(t);
1203
+ return Number.isFinite(n) ? n : void 0;
1204
+ }
1205
+ function j(e) {
1206
+ if (typeof e != "string") return;
1207
+ let t = e.trim();
1208
+ return t.length > 0 ? t : void 0;
1209
+ }
1210
+ function re(e, t) {
1211
+ if (typeof e == "number" && Number.isFinite(e) && e > 0) return `${e}px`;
1212
+ if (typeof e == "string") {
1213
+ let n = e.trim();
1214
+ return n ? n.toLowerCase() === "full" ? "100%" : n : t;
1215
+ }
1216
+ return t;
1217
+ }
1218
+ return (t, a) => (v(), i("div", {
1219
+ class: m(["ml-ribbon-input-number", {
1220
+ "has-prefix": x.value,
1221
+ "is-full": u.value
1222
+ }]),
1223
+ style: h(d.value),
1224
+ "data-id": e.id,
1225
+ onKeydown: k(ee(te, ["stop", "prevent"]), ["enter"])
1226
+ }, [x.value ? (v(), i("span", wt, [_.value ? (v(), n(E(I), {
1227
+ key: 0,
1228
+ class: "ml-ribbon-input-number__prefix-icon",
1229
+ "aria-hidden": "true"
1230
+ }, {
1231
+ default: O(() => [(v(), n(C(_.value)))]),
1232
+ _: 1
1233
+ })) : y.value ? (v(), i("i", {
1234
+ key: 1,
1235
+ class: m(["ml-ribbon-input-number__prefix-icon ml-ribbon-input-number__prefix-icon--class", y.value]),
1236
+ "aria-hidden": "true"
1237
+ }, null, 2)) : r("", !0), g.value ? (v(), i("span", Tt, w(g.value), 1)) : r("", !0)])) : r("", !0), c(E(ie), f(e.controlProps, {
1238
+ "model-value": e.modelValue,
1239
+ disabled: e.disabled,
1240
+ style: p.value,
1241
+ "aria-label": S.value,
1242
+ onChange: D
1243
+ }), null, 16, [
1244
+ "model-value",
1245
+ "disabled",
1246
+ "style",
1247
+ "aria-label"
1248
+ ])], 46, Ct));
760
1249
  }
761
- }), qe = ["data-id"], Je = {
1250
+ }), Dt = ["data-id"], Ot = {
762
1251
  key: 0,
763
1252
  class: "ml-ribbon-segmented__label"
764
- }, Ye = ["data-option-value"], Xe = {
1253
+ }, kt = ["data-option-value"], At = {
765
1254
  key: 2,
766
1255
  class: "ml-ribbon-segmented__option-label"
767
- }, Ze = {
1256
+ }, jt = {
768
1257
  key: 3,
769
1258
  class: "ml-ribbon-segmented__option-sr-label"
770
- }, $ = /* @__PURE__ */ l({
1259
+ }, Mt = /* @__PURE__ */ l({
771
1260
  __name: "RibbonSegmented",
772
1261
  props: {
773
1262
  id: {},
@@ -823,7 +1312,7 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
823
1312
  return (t, o) => (v(), i("div", {
824
1313
  class: "ml-ribbon-segmented",
825
1314
  "data-id": e.id
826
- }, [d.value ? (v(), i("div", Je, w(u.value), 1)) : r("", !0), c(E(L), {
1315
+ }, [d.value ? (v(), i("div", Ot, w(u.value), 1)) : r("", !0), c(E(z), {
827
1316
  class: "ml-ribbon-segmented__control",
828
1317
  options: e.options,
829
1318
  "model-value": e.modelValue,
@@ -836,7 +1325,7 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
836
1325
  default: O(({ item: e }) => [a("span", {
837
1326
  class: "ml-ribbon-segmented__option",
838
1327
  "data-option-value": y(e)
839
- }, [h(e) ? (v(), n(E(F), {
1328
+ }, [h(e) ? (v(), n(E(I), {
840
1329
  key: 0,
841
1330
  class: "ml-ribbon-segmented__option-icon",
842
1331
  "aria-hidden": "true"
@@ -847,7 +1336,7 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
847
1336
  key: 1,
848
1337
  class: m(["ml-ribbon-segmented__option-icon ml-ribbon-item-host__icon--class", g(e)]),
849
1338
  "aria-hidden": "true"
850
- }, null, 2)) : r("", !0), _(e) ? (v(), i("span", Xe, w(p(e)), 1)) : (v(), i("span", Ze, w(p(e)), 1))], 8, Ye)]),
1339
+ }, null, 2)) : r("", !0), _(e) ? (v(), i("span", At, w(p(e)), 1)) : (v(), i("span", jt, w(p(e)), 1))], 8, kt)]),
851
1340
  _: 1
852
1341
  }, 8, [
853
1342
  "options",
@@ -856,9 +1345,9 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
856
1345
  "block",
857
1346
  "disabled",
858
1347
  "aria-label"
859
- ])], 8, qe));
1348
+ ])], 8, Dt));
860
1349
  }
861
- }), Qe = /* @__PURE__ */ l({
1350
+ }), Nt = /* @__PURE__ */ l({
862
1351
  __name: "RibbonToggleButton",
863
1352
  props: {
864
1353
  id: {},
@@ -913,7 +1402,7 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
913
1402
  "aria-pressed"
914
1403
  ]));
915
1404
  }
916
- }), $e = ["data-template-id", "aria-disabled"], et = /* @__PURE__ */ l({
1405
+ }), Pt = ["data-template-id", "aria-disabled"], Ft = /* @__PURE__ */ l({
917
1406
  __name: "RibbonTemplateItem",
918
1407
  props: {
919
1408
  id: {},
@@ -928,12 +1417,12 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
928
1417
  }, [S(t.$slots, "default", {
929
1418
  item: e.item,
930
1419
  disabled: e.disabled
931
- }, () => [a("span", null, w(e.item.label ?? e.item.id), 1)])], 8, $e));
1420
+ }, () => [a("span", null, w(e.item.label ?? e.item.id), 1)])], 8, Pt));
932
1421
  }
933
- }), tt = ["data-item-id"], nt = {
1422
+ }), It = ["data-item-id"], Lt = {
934
1423
  key: 0,
935
1424
  class: "ml-ribbon-item-host__keytip"
936
- }, rt = /* @__PURE__ */ l({
1425
+ }, Rt = /* @__PURE__ */ l({
937
1426
  __name: "RibbonItemHost",
938
1427
  props: {
939
1428
  id: {},
@@ -944,43 +1433,49 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
944
1433
  },
945
1434
  emits: ["item-click"],
946
1435
  setup(o, { emit: c }) {
947
- let l = o, p = c, g = u(fe, null), _ = t(() => Array.isArray(l.item.props?.options) ? l.item.props.options : []), y = se("size", ""), k = t(() => y.value || "default"), ee = t(() => je(g?.tooltipShowAfter.value, 1e3)), A = t(() => je(g?.tooltipHideAfter.value, 0)), re = t(() => `ml-ribbon-select-dropdown ml-ribbon-popper ml-ribbon-popper--size-${k.value}`), j = t(() => l.item.props?.icon || l.item.icon), M = t(() => l.item.hideLabel !== !0), N = b(void 0), P = t(() => l.item.type === "dropdown" && N.value ? N.value : ke(l.item.tooltip) ?? ke(l.item.label) ?? Le(l.item) ?? Z(l.item.id)), F = t(() => l.item.type !== "buttonGroup"), ae = t(() => !F.value || !P.value), L = t(() => P.value ?? l.item.id), R = t(() => l.item.keyTip?.trim().toUpperCase() ?? ""), B = t(() => {
1436
+ let l = o, p = c, g = u(pe, null), _ = t(() => Array.isArray(l.item.props?.options) ? l.item.props.options : []), y = oe("size", ""), k = t(() => y.value || "default"), ee = t(() => je(g?.tooltipShowAfter.value, 1e3)), te = t(() => je(g?.tooltipHideAfter.value, 0)), A = t(() => `ml-ribbon-select-dropdown ml-ribbon-popper ml-ribbon-popper--size-${k.value}`), re = t(() => l.item.props?.icon || l.item.icon), M = t(() => l.item.hideLabel !== !0), N = b(void 0), P = t(() => l.item.type === "dropdown" && N.value ? N.value : ke(l.item.tooltip) ?? ke(l.item.label) ?? Le(l.item) ?? Re(l.item.id)), F = t(() => l.item.type !== "buttonGroup"), I = t(() => !F.value || !P.value), ie = t(() => P.value ?? l.item.id), R = t(() => l.item.keyTip?.trim().toUpperCase() ?? ""), z = t(() => {
948
1437
  if (!g?.keyTipsOpen.value || g?.disabled.value || l.disabled === !0 || !R.value) return !1;
949
1438
  let e = g.keyTipsSequence.value.toLowerCase();
950
1439
  return e ? R.value.toLowerCase().startsWith(e) : !0;
951
- }), V = t(() => l.disabled === !0 || l.item.disabled === !0 || g?.disabled.value === !0), H = t(() => l.item.props?.modelValue), ce = t(() => l.item.props?.activeLabel), le = t(() => l.item.props?.inactiveLabel), ue = t(() => {
1440
+ }), V = t(() => l.disabled === !0 || l.item.disabled === !0 || g?.disabled.value === !0), H = t(() => l.item.props?.modelValue), se = t(() => l.item.props?.activeLabel), ce = t(() => l.item.props?.inactiveLabel), le = t(() => Array.isArray(l.item.props?.categories) ? l.item.props.categories : []), ue = t(() => {
1441
+ let e = l.item.props?.modelValue;
1442
+ return typeof e == "string" ? e : void 0;
1443
+ }), de = t(() => {
1444
+ let e = l.item.props?.inlineItemLimit;
1445
+ return typeof e == "number" ? e : void 0;
1446
+ }), fe = t(() => {
952
1447
  let e = l.item.props?.component;
953
1448
  return !e || typeof e == "string" ? null : d(T(e));
954
- }), de = t(() => {
1449
+ }), U = t(() => {
955
1450
  let e = l.item.props?.componentProps;
956
1451
  return !e || typeof e != "object" || Array.isArray(e) ? {} : e;
957
- }), U = t(() => l.item.props?.wrap !== !1), W = t(() => l.item.props?.equalWidth === !0), G = t(() => {
1452
+ }), W = t(() => l.item.props?.wrap !== !1), G = t(() => l.item.props?.equalWidth === !0), me = t(() => {
958
1453
  let e = l.item.props?.buttonSize;
959
1454
  if (e === "large" || e === "default" || e === "small") return e;
960
- }), K = t(() => Fe(l.item.props?.iconSize)), pe = t(() => Me(l.item.props?.width ?? l.item.props?.comboWidth, "92px")), me = t(() => l.item.props?.modelValue), q = t(() => Me(l.item.props?.width ?? l.item.props?.inputNumberWidth, "96px")), J = t(() => l.item.props?.modelValue), he = t(() => {
1455
+ }), he = t(() => Fe(l.item.props?.iconSize)), K = t(() => Me(l.item.props?.width ?? l.item.props?.comboWidth, "92px")), ge = t(() => l.item.props?.modelValue), _e = t(() => Me(l.item.props?.width ?? l.item.props?.inputNumberWidth, "96px")), q = t(() => l.item.props?.modelValue), ve = t(() => {
961
1456
  let e = { ...l.item.props ?? {} };
962
- return delete e.modelValue, delete e.width, delete e.inputNumberWidth, delete e.emitValueOnChange, delete e.options, delete e.component, delete e.componentProps, e;
963
- }), ge = t(() => Ie(l.item.props?.labelWrapLines)), _e = t(() => Ne(l.item.props?.labelWrapWidth)), ve = t(() => l.item.type === "button" && l.item.size === "large" && M.value && (ge.value ?? 0) > 1), ye = t(() => {
964
- if (!ve.value) return {};
965
- let e = { "--ml-rb-item-label-max-lines": String(ge.value ?? 2) };
966
- return _e.value && (e["--ml-rb-item-label-wrap-width"] = _e.value), e;
1457
+ return delete e.modelValue, delete e.width, delete e.inputNumberWidth, delete e.prefixLabel, delete e.prefixIcon, delete e.prefixIconClass, delete e.emitValueOnChange, delete e.valuePrefix, delete e.options, delete e.component, delete e.componentProps, e;
1458
+ }), ye = t(() => Ie(l.item.props?.labelWrapLines)), be = t(() => Ne(l.item.props?.labelWrapWidth)), J = t(() => l.item.type === "button" && l.item.size === "large" && M.value && (ye.value ?? 0) > 1), Y = t(() => {
1459
+ if (!J.value) return {};
1460
+ let e = { "--ml-rb-item-label-max-lines": String(ye.value ?? 2) };
1461
+ return be.value && (e["--ml-rb-item-label-wrap-width"] = be.value), e;
967
1462
  });
968
1463
  D(() => l.item.id, () => {
969
1464
  N.value = void 0;
970
1465
  });
971
- function Y() {
1466
+ function X() {
972
1467
  V.value || p("item-click", l.id);
973
1468
  }
974
- function be(e) {
1469
+ function Z(e) {
975
1470
  if (!V.value) {
976
1471
  if (typeof e == "string" || typeof e == "number") {
977
1472
  p("item-click", String(e));
978
1473
  return;
979
1474
  }
980
- Y();
1475
+ X();
981
1476
  }
982
1477
  }
983
- function X(e) {
1478
+ function Q(e) {
984
1479
  N.value = e;
985
1480
  }
986
1481
  function xe(e) {
@@ -989,7 +1484,7 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
989
1484
  p("item-click", String(e));
990
1485
  return;
991
1486
  }
992
- Y();
1487
+ X();
993
1488
  }
994
1489
  }
995
1490
  function Se(e) {
@@ -1007,7 +1502,7 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
1007
1502
  p("item-click", String(e));
1008
1503
  return;
1009
1504
  }
1010
- Y();
1505
+ X();
1011
1506
  }
1012
1507
  }
1013
1508
  function we(e) {
@@ -1019,16 +1514,17 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
1019
1514
  p("item-click", String(e));
1020
1515
  return;
1021
1516
  }
1022
- Y();
1517
+ X();
1023
1518
  }
1024
1519
  }
1025
1520
  function Ee(e) {
1026
1521
  if (!V.value) {
1027
1522
  if (l.item.props?.emitValueOnChange === !0 && typeof e == "number" && Number.isFinite(e)) {
1028
- p("item-click", String(e));
1523
+ let t = l.item.props?.valuePrefix;
1524
+ p("item-click", `${typeof t == "string" ? t : ""}${e}`);
1029
1525
  return;
1030
1526
  }
1031
- Y();
1527
+ X();
1032
1528
  }
1033
1529
  }
1034
1530
  function De(e) {
@@ -1037,7 +1533,7 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
1037
1533
  p("item-click", String(e));
1038
1534
  return;
1039
1535
  }
1040
- Y();
1536
+ X();
1041
1537
  }
1042
1538
  }
1043
1539
  function Oe(e) {
@@ -1081,15 +1577,15 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
1081
1577
  let t = _.value.map((e) => Oe(e)).filter((e) => !!e);
1082
1578
  if (t.length) return e.type === "buttonGroup" ? t.join(" / ") : t[0];
1083
1579
  }
1084
- function Z(e) {
1580
+ function Re(e) {
1085
1581
  let t = e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " ").trim();
1086
1582
  return t ? t.replace(/\b\w/g, (e) => e.toUpperCase()) : e;
1087
1583
  }
1088
- return (t, c) => (v(), n(E(z), {
1584
+ return (t, c) => (v(), n(E(ae), {
1089
1585
  content: P.value,
1090
- disabled: ae.value,
1586
+ disabled: I.value,
1091
1587
  "show-after": ee.value,
1092
- "hide-after": A.value,
1588
+ "hide-after": te.value,
1093
1589
  placement: "top",
1094
1590
  effect: "dark"
1095
1591
  }, {
@@ -1099,24 +1595,24 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
1099
1595
  `type-${o.item.type}`,
1100
1596
  {
1101
1597
  "is-label-hidden": o.item.hideLabel === !0,
1102
- "is-label-wrap": ve.value
1598
+ "is-label-wrap": J.value
1103
1599
  }
1104
1600
  ]]),
1105
- style: h(ye.value),
1601
+ style: h(Y.value),
1106
1602
  "data-item-id": o.id,
1107
1603
  role: "group"
1108
- }, [B.value ? (v(), i("span", nt, w(R.value), 1)) : r("", !0), o.item.type === "buttonGroup" ? (v(), n(Pe, {
1604
+ }, [z.value ? (v(), i("span", Lt, w(R.value), 1)) : r("", !0), o.item.type === "buttonGroup" ? (v(), n(Pe, {
1109
1605
  key: 1,
1110
1606
  id: o.item.id,
1111
1607
  label: o.item.label ?? "",
1112
1608
  options: o.item.props?.options ?? [],
1113
1609
  "hide-label": o.item.hideLabel === !0,
1114
- wrap: U.value,
1115
- "equal-width": W.value,
1116
- "button-size": G.value,
1117
- "icon-size": K.value,
1610
+ wrap: W.value,
1611
+ "equal-width": G.value,
1612
+ "button-size": me.value,
1613
+ "icon-size": he.value,
1118
1614
  "tooltip-show-after": ee.value,
1119
- "tooltip-hide-after": A.value,
1615
+ "tooltip-hide-after": te.value,
1120
1616
  disabled: V.value,
1121
1617
  onChange: Ce
1122
1618
  }, null, 8, [
@@ -1131,7 +1627,7 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
1131
1627
  "tooltip-show-after",
1132
1628
  "tooltip-hide-after",
1133
1629
  "disabled"
1134
- ])) : o.item.type === "segmented" ? (v(), n($, {
1630
+ ])) : o.item.type === "segmented" ? (v(), n(Mt, {
1135
1631
  key: 2,
1136
1632
  id: o.item.id,
1137
1633
  label: o.item.label ?? o.item.id,
@@ -1151,15 +1647,15 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
1151
1647
  "block",
1152
1648
  "disabled",
1153
1649
  "hide-label"
1154
- ])) : o.item.type === "toggle" ? (v(), n(Qe, {
1650
+ ])) : o.item.type === "toggle" ? (v(), n(Nt, {
1155
1651
  key: 3,
1156
1652
  id: o.item.id,
1157
1653
  label: o.item.label ?? o.item.id,
1158
1654
  "model-value": H.value,
1159
1655
  "active-icon": o.item.props?.activeIcon ?? o.item.props?.icon ?? o.item.icon,
1160
1656
  "inactive-icon": o.item.props?.inactiveIcon ?? o.item.props?.icon ?? o.item.icon,
1161
- "active-label": ce.value,
1162
- "inactive-label": le.value,
1657
+ "active-label": se.value,
1658
+ "inactive-label": ce.value,
1163
1659
  disabled: V.value,
1164
1660
  "hide-label": o.item.hideLabel === !0,
1165
1661
  onChange: Se
@@ -1173,11 +1669,14 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
1173
1669
  "inactive-label",
1174
1670
  "disabled",
1175
1671
  "hide-label"
1176
- ])) : o.item.type === "gallery" ? (v(), n(Ke, {
1672
+ ])) : o.item.type === "gallery" ? (v(), n(St, {
1177
1673
  key: 4,
1178
1674
  id: o.item.id,
1179
1675
  label: o.item.label ?? "",
1180
- categories: o.item.props?.categories ?? [],
1676
+ categories: le.value,
1677
+ "model-value": ue.value,
1678
+ collapsed: o.item.props?.collapsed === !0,
1679
+ "inline-item-limit": de.value,
1181
1680
  "preview-fallback": l.galleryPreviewFallback,
1182
1681
  disabled: V.value,
1183
1682
  onSelect: we
@@ -1185,15 +1684,18 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
1185
1684
  "id",
1186
1685
  "label",
1187
1686
  "categories",
1687
+ "model-value",
1688
+ "collapsed",
1689
+ "inline-item-limit",
1188
1690
  "preview-fallback",
1189
1691
  "disabled"
1190
- ])) : o.item.type === "custom" || o.item.type === "template" ? (v(), n(et, {
1692
+ ])) : o.item.type === "custom" || o.item.type === "template" ? (v(), n(Ft, {
1191
1693
  key: 5,
1192
1694
  id: o.item.id,
1193
1695
  item: o.item,
1194
1696
  disabled: V.value
1195
1697
  }, {
1196
- default: O(() => [ue.value ? (v(), n(C(ue.value), f({ key: 0 }, de.value, {
1698
+ default: O(() => [fe.value ? (v(), n(C(fe.value), f({ key: 0 }, U.value, {
1197
1699
  item: o.item,
1198
1700
  "group-id": o.groupId,
1199
1701
  disabled: V.value,
@@ -1212,22 +1714,22 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
1212
1714
  "id",
1213
1715
  "item",
1214
1716
  "disabled"
1215
- ])) : o.item.type === "dropdown" ? (v(), n(ze, {
1717
+ ])) : o.item.type === "dropdown" ? (v(), n(Be, {
1216
1718
  key: 6,
1217
1719
  id: o.item.id,
1218
1720
  label: o.item.label ?? o.item.id,
1219
1721
  tooltip: o.item.tooltip,
1220
- icon: j.value,
1722
+ icon: re.value,
1221
1723
  options: o.item.props?.options ?? [],
1222
1724
  disabled: V.value,
1223
1725
  "hide-label": o.item.hideLabel === !0,
1224
1726
  "item-size": o.item.size ?? "medium",
1225
1727
  "sync-label-with-selection": o.item.props?.syncLabelWithSelection === !0,
1226
1728
  "tooltip-show-after": ee.value,
1227
- "tooltip-hide-after": A.value,
1228
- onCommand: be,
1229
- onTooltipChange: X,
1230
- onClick: Y
1729
+ "tooltip-hide-after": te.value,
1730
+ onCommand: Z,
1731
+ onTooltipChange: Q,
1732
+ onClick: X
1231
1733
  }, null, 8, [
1232
1734
  "id",
1233
1735
  "label",
@@ -1240,26 +1742,26 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
1240
1742
  "sync-label-with-selection",
1241
1743
  "tooltip-show-after",
1242
1744
  "tooltip-hide-after"
1243
- ])) : o.item.type === "checkbox" ? (v(), n(E(te), {
1745
+ ])) : o.item.type === "checkbox" ? (v(), n(E(ne), {
1244
1746
  key: 7,
1245
1747
  disabled: V.value,
1246
- onChange: Y
1748
+ onChange: X
1247
1749
  }, {
1248
1750
  default: O(() => [s(w(o.item.label), 1)]),
1249
1751
  _: 1
1250
- }, 8, ["disabled"])) : o.item.type === "colorPicker" ? (v(), n(E(ne), {
1752
+ }, 8, ["disabled"])) : o.item.type === "colorPicker" ? (v(), n(E(j), {
1251
1753
  key: 8,
1252
1754
  disabled: V.value,
1253
- onChange: Y
1254
- }, null, 8, ["disabled"])) : o.item.type === "comboBox" ? (v(), n(E(oe), {
1755
+ onChange: X
1756
+ }, null, 8, ["disabled"])) : o.item.type === "comboBox" ? (v(), n(E(B), {
1255
1757
  key: 9,
1256
- "model-value": me.value,
1758
+ "model-value": ge.value,
1257
1759
  disabled: V.value,
1258
- "popper-class": re.value,
1259
- style: h({ width: pe.value }),
1760
+ "popper-class": A.value,
1761
+ style: h({ width: K.value }),
1260
1762
  onChange: Te
1261
1763
  }, {
1262
- default: O(() => [(v(!0), i(e, null, x(_.value, (e) => (v(), n(E(ie), {
1764
+ default: O(() => [(v(!0), i(e, null, x(_.value, (e) => (v(), n(E(L), {
1263
1765
  key: String(e.value),
1264
1766
  label: String(e.label),
1265
1767
  value: e.value
@@ -1270,25 +1772,35 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
1270
1772
  "disabled",
1271
1773
  "popper-class",
1272
1774
  "style"
1273
- ])) : o.item.type === "inputNumber" ? (v(), n(E(I), f({ key: 10 }, he.value, {
1274
- class: "ml-ribbon-input-number",
1275
- "model-value": J.value,
1775
+ ])) : o.item.type === "inputNumber" ? (v(), n(Et, {
1776
+ key: 10,
1777
+ id: o.item.id,
1778
+ "model-value": q.value,
1779
+ width: _e.value,
1780
+ "prefix-label": o.item.props?.prefixLabel,
1781
+ "prefix-icon": o.item.props?.prefixIcon ?? o.item.props?.icon ?? o.item.icon,
1782
+ "prefix-icon-class": o.item.props?.prefixIconClass,
1783
+ "control-props": ve.value,
1276
1784
  disabled: V.value,
1277
- style: { width: q.value },
1278
1785
  onChange: Ee
1279
- }), null, 16, [
1786
+ }, null, 8, [
1787
+ "id",
1280
1788
  "model-value",
1281
- "disabled",
1282
- "style"
1789
+ "width",
1790
+ "prefix-label",
1791
+ "prefix-icon",
1792
+ "prefix-icon-class",
1793
+ "control-props",
1794
+ "disabled"
1283
1795
  ])) : (v(), n(Ae, {
1284
1796
  key: 11,
1285
1797
  id: o.item.id,
1286
1798
  label: o.item.label ?? o.item.id,
1287
- icon: j.value,
1799
+ icon: re.value,
1288
1800
  disabled: V.value,
1289
1801
  "hide-label": !M.value,
1290
- "aria-label": L.value,
1291
- onClick: Y
1802
+ "aria-label": ie.value,
1803
+ onClick: X
1292
1804
  }, null, 8, [
1293
1805
  "id",
1294
1806
  "label",
@@ -1296,7 +1808,7 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
1296
1808
  "disabled",
1297
1809
  "hide-label",
1298
1810
  "aria-label"
1299
- ]))], 14, tt)]),
1811
+ ]))], 14, It)]),
1300
1812
  _: 3
1301
1813
  }, 8, [
1302
1814
  "content",
@@ -1305,7 +1817,7 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
1305
1817
  "hide-after"
1306
1818
  ]));
1307
1819
  }
1308
- }), it = /* @__PURE__ */ l({
1820
+ }), zt = /* @__PURE__ */ l({
1309
1821
  __name: "RibbonGroupContent",
1310
1822
  props: {
1311
1823
  group: {},
@@ -1321,7 +1833,7 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
1321
1833
  layout: t.layout ?? (a.group.orientation === "row" ? "row" : "column"),
1322
1834
  rows: t.rows
1323
1835
  }, {
1324
- default: O(() => [(v(!0), i(e, null, x(t.items, (e) => (v(), n(rt, {
1836
+ default: O(() => [(v(!0), i(e, null, x(t.items, (e) => (v(), n(Rt, {
1325
1837
  id: e.id,
1326
1838
  key: e.id,
1327
1839
  item: e,
@@ -1346,15 +1858,15 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
1346
1858
  "rows"
1347
1859
  ]))), 128))], 2));
1348
1860
  }
1349
- }), at = ["data-priority"], ot = { class: "ml-ribbon-group__body" }, st = { class: "ml-ribbon-group__footer" }, ct = { class: "ml-ribbon-group__title" }, lt = [
1861
+ }), Bt = ["data-priority"], Vt = { class: "ml-ribbon-group__body" }, Ht = { class: "ml-ribbon-group__footer" }, Ut = { class: "ml-ribbon-group__title" }, Wt = [
1350
1862
  "aria-label",
1351
1863
  "aria-expanded",
1352
1864
  "disabled"
1353
- ], ut = { class: "ml-ribbon-group__overflow-content" }, dt = [
1865
+ ], Gt = { class: "ml-ribbon-group__overflow-content" }, Kt = [
1354
1866
  "aria-label",
1355
1867
  "aria-expanded",
1356
1868
  "disabled"
1357
- ], ft = { class: "ml-ribbon-group__overflow-content" }, pt = /* @__PURE__ */ l({
1869
+ ], qt = { class: "ml-ribbon-group__overflow-content" }, Jt = /* @__PURE__ */ l({
1358
1870
  __name: "RibbonGroup",
1359
1871
  props: {
1360
1872
  id: {},
@@ -1373,7 +1885,7 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
1373
1885
  },
1374
1886
  emits: ["item-click"],
1375
1887
  setup(e, { emit: o }) {
1376
- let s = e, l = o, d = u(fe, null), f = t(() => s.width == null), y = t(() => {
1888
+ let s = e, l = o, d = u(pe, null), f = t(() => s.width == null), y = t(() => {
1377
1889
  if (typeof s.width != "number" || Number.isNaN(s.width) || s.width <= 0) return;
1378
1890
  let e = `${s.width}px`;
1379
1891
  return {
@@ -1382,13 +1894,13 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
1382
1894
  maxWidth: e,
1383
1895
  flex: `0 0 ${e}`
1384
1896
  };
1385
- }), x = t(() => s.disabled === !0 || d?.disabled.value === !0), T = b(null), k = b([]), A = b(null), te = b(null), ne = b(0), re = b(0), j = se("size", ""), M = t(() => j.value || "default"), N = t(() => `ml-ribbon-group__overflow-popover ml-ribbon-group__overflow-popover--size-${M.value}`), P = t(() => ({ modifiers: [{
1897
+ }), x = t(() => s.disabled === !0 || d?.disabled.value === !0), T = b(null), k = b([]), ee = b(null), A = b(null), ne = b(0), j = b(0), re = oe("size", ""), M = t(() => re.value || "default"), N = t(() => `ml-ribbon-group__overflow-popover ml-ribbon-group__overflow-popover--size-${M.value}`), P = t(() => ({ modifiers: [{
1386
1898
  name: "offset",
1387
1899
  options: { offset: [ne.value, 8] }
1388
- }] })), I = t(() => ({ modifiers: [{
1900
+ }] })), F = t(() => ({ modifiers: [{
1389
1901
  name: "offset",
1390
- options: { offset: [re.value, 8] }
1391
- }] })), ie = t(() => !s.icon || typeof s.icon == "string" ? null : s.icon), L = t(() => k.value.length > 0), oe = t(() => (s.groupModel?.footerMenuItems?.length ?? 0) > 0), R = b(!1), z = b(!1), V = t(() => {
1902
+ options: { offset: [j.value, 8] }
1903
+ }] })), ie = t(() => !s.icon || typeof s.icon == "string" ? null : s.icon), L = t(() => k.value.length > 0), z = t(() => (s.groupModel?.footerMenuItems?.length ?? 0) > 0), B = b(!1), V = b(!1), ae = t(() => {
1392
1904
  if (!s.groupModel || !k.value.length) return null;
1393
1905
  let e = new Set(k.value), t = s.groupModel.collections?.map((t) => ({
1394
1906
  ...t,
@@ -1398,7 +1910,7 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
1398
1910
  ...s.groupModel,
1399
1911
  collections: t
1400
1912
  } : null;
1401
- }), ce = t(() => s.groupModel?.footerMenuItems?.length ? {
1913
+ }), se = t(() => s.groupModel?.footerMenuItems?.length ? {
1402
1914
  id: `${s.groupModel.id}-footer-menu`,
1403
1915
  title: "",
1404
1916
  orientation: "row",
@@ -1429,11 +1941,11 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
1429
1941
  }
1430
1942
  function ue() {
1431
1943
  p(() => {
1432
- he(), U(), W(), le();
1944
+ _e(), de(), fe(), le();
1433
1945
  });
1434
1946
  }
1435
- function U() {
1436
- let e = T.value?.getBoundingClientRect(), t = A.value?.getBoundingClientRect();
1947
+ function de() {
1948
+ let e = T.value?.getBoundingClientRect(), t = ee.value?.getBoundingClientRect();
1437
1949
  if (!e || !t) {
1438
1950
  ne.value !== 0 && (ne.value = 0);
1439
1951
  return;
@@ -1441,83 +1953,83 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
1441
1953
  let n = Math.round(e.left - t.left);
1442
1954
  ne.value !== n && (ne.value = n);
1443
1955
  }
1444
- function W() {
1445
- let e = T.value?.getBoundingClientRect(), t = te.value?.getBoundingClientRect();
1956
+ function fe() {
1957
+ let e = T.value?.getBoundingClientRect(), t = A.value?.getBoundingClientRect();
1446
1958
  if (!e || !t) {
1447
- re.value !== 0 && (re.value = 0);
1959
+ j.value !== 0 && (j.value = 0);
1448
1960
  return;
1449
1961
  }
1450
1962
  let n = Math.round(e.left - t.left);
1451
- re.value !== n && (re.value = n);
1963
+ j.value !== n && (j.value = n);
1452
1964
  }
1453
- function G(e) {
1454
- R.value = e;
1965
+ function W(e) {
1966
+ B.value = e;
1455
1967
  }
1456
- function K(e) {
1457
- z.value = e;
1458
- }
1459
- function pe() {
1460
- x.value || (R.value = !R.value);
1968
+ function G(e) {
1969
+ V.value = e;
1461
1970
  }
1462
1971
  function me() {
1463
- x.value || (z.value = !z.value);
1972
+ x.value || (B.value = !B.value);
1464
1973
  }
1465
- let q = null, J = null;
1466
1974
  function he() {
1467
- if (!q) return;
1975
+ x.value || (V.value = !V.value);
1976
+ }
1977
+ let K = null, ge = null;
1978
+ function _e() {
1979
+ if (!K) return;
1468
1980
  let e = T.value?.querySelector(".ml-ribbon-group__content") ?? null;
1469
- J !== e && (J && q.unobserve(J), e && q.observe(e), J = e);
1981
+ ge !== e && (ge && K.unobserve(ge), e && K.observe(e), ge = e);
1470
1982
  }
1471
1983
  return D(() => s.groupModel, () => {
1472
1984
  ue();
1473
1985
  }, { deep: !0 }), D(x, (e) => {
1474
- e && (R.value = !1, z.value = !1);
1986
+ e && (B.value = !1, V.value = !1);
1475
1987
  }), g(() => {
1476
- typeof ResizeObserver < "u" && (q = new ResizeObserver(() => {
1477
- U(), W(), le();
1478
- }), T.value && q.observe(T.value), he()), ue();
1988
+ typeof ResizeObserver < "u" && (K = new ResizeObserver(() => {
1989
+ de(), fe(), le();
1990
+ }), T.value && K.observe(T.value), _e()), ue();
1479
1991
  }), _(() => {
1480
- q?.disconnect();
1992
+ K?.disconnect();
1481
1993
  }), (t, o) => (v(), i("section", {
1482
1994
  ref_key: "groupSectionRef",
1483
1995
  ref: T,
1484
1996
  class: m(["ml-ribbon-group", { "ml-ribbon-group--auto-width": f.value }]),
1485
1997
  "data-priority": e.priority ?? 100,
1486
1998
  style: h(y.value)
1487
- }, [a("div", ot, [S(t.$slots, "default")]), a("footer", st, [
1488
- ie.value ? (v(), n(E(F), {
1999
+ }, [a("div", Vt, [S(t.$slots, "default")]), a("footer", Ht, [
2000
+ ie.value ? (v(), n(E(I), {
1489
2001
  key: 0,
1490
2002
  class: "ml-ribbon-group__icon"
1491
2003
  }, {
1492
2004
  default: O(() => [(v(), n(C(ie.value)))]),
1493
2005
  _: 1
1494
2006
  })) : r("", !0),
1495
- a("span", ct, w(e.title), 1),
1496
- oe.value && ce.value ? (v(), n(E(ae), {
2007
+ a("span", Ut, w(e.title), 1),
2008
+ z.value && se.value ? (v(), n(E(R), {
1497
2009
  key: 1,
1498
2010
  trigger: "click",
1499
2011
  placement: "bottom-start",
1500
2012
  disabled: x.value,
1501
2013
  "popper-class": N.value,
1502
- "popper-options": I.value,
1503
- onShow: o[1] ||= (e) => G(!0),
1504
- onHide: o[2] ||= (e) => G(!1)
2014
+ "popper-options": F.value,
2015
+ onShow: o[1] ||= (e) => W(!0),
2016
+ onHide: o[2] ||= (e) => W(!1)
1505
2017
  }, {
1506
2018
  reference: O(() => [a("button", {
1507
2019
  ref_key: "footerTriggerRef",
1508
- ref: te,
2020
+ ref: A,
1509
2021
  type: "button",
1510
- class: m(["ml-ribbon-group__footer-trigger", { "is-open": R.value }]),
2022
+ class: m(["ml-ribbon-group__footer-trigger", { "is-open": B.value }]),
1511
2023
  "aria-label": e.overflowTriggerAriaLabel,
1512
- "aria-expanded": R.value,
2024
+ "aria-expanded": B.value,
1513
2025
  disabled: x.value,
1514
- onClick: pe
1515
- }, [c(E(F), null, {
1516
- default: O(() => [(v(), n(C(R.value ? E(H) : E(B))))]),
2026
+ onClick: me
2027
+ }, [c(E(I), null, {
2028
+ default: O(() => [(v(), n(C(B.value ? E(ce) : E(H))))]),
1517
2029
  _: 1
1518
- })], 10, lt)]),
1519
- default: O(() => [a("div", ut, [c(it, {
1520
- group: ce.value,
2030
+ })], 10, Wt)]),
2031
+ default: O(() => [a("div", Gt, [c(zt, {
2032
+ group: se.value,
1521
2033
  "gallery-preview-fallback": e.galleryPreviewFallback,
1522
2034
  disabled: x.value,
1523
2035
  onItemClick: o[0] ||= (e) => l("item-click", e)
@@ -1532,31 +2044,31 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
1532
2044
  "popper-class",
1533
2045
  "popper-options"
1534
2046
  ])) : r("", !0),
1535
- L.value && V.value ? (v(), n(E(ae), {
2047
+ L.value && ae.value ? (v(), n(E(R), {
1536
2048
  key: 2,
1537
2049
  trigger: "click",
1538
2050
  placement: "bottom-start",
1539
2051
  disabled: x.value,
1540
2052
  "popper-class": N.value,
1541
2053
  "popper-options": P.value,
1542
- onShow: o[4] ||= (e) => K(!0),
1543
- onHide: o[5] ||= (e) => K(!1)
2054
+ onShow: o[4] ||= (e) => G(!0),
2055
+ onHide: o[5] ||= (e) => G(!1)
1544
2056
  }, {
1545
2057
  reference: O(() => [a("button", {
1546
2058
  ref_key: "overflowTriggerRef",
1547
- ref: A,
2059
+ ref: ee,
1548
2060
  type: "button",
1549
- class: m(["ml-ribbon-group__overflow-trigger", { "is-open": z.value }]),
2061
+ class: m(["ml-ribbon-group__overflow-trigger", { "is-open": V.value }]),
1550
2062
  "aria-label": e.overflowTriggerAriaLabel,
1551
- "aria-expanded": z.value,
2063
+ "aria-expanded": V.value,
1552
2064
  disabled: x.value,
1553
- onClick: me
1554
- }, [c(E(F), null, {
1555
- default: O(() => [(v(), n(C(z.value ? E(H) : E(B))))]),
2065
+ onClick: he
2066
+ }, [c(E(I), null, {
2067
+ default: O(() => [(v(), n(C(V.value ? E(ce) : E(H))))]),
1556
2068
  _: 1
1557
- })], 10, dt)]),
1558
- default: O(() => [a("div", ft, [c(it, {
1559
- group: V.value,
2069
+ })], 10, Kt)]),
2070
+ default: O(() => [a("div", qt, [c(zt, {
2071
+ group: ae.value,
1560
2072
  "gallery-preview-fallback": e.galleryPreviewFallback,
1561
2073
  disabled: x.value,
1562
2074
  onItemClick: o[3] ||= (e) => l("item-click", e)
@@ -1571,30 +2083,30 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
1571
2083
  "popper-class",
1572
2084
  "popper-options"
1573
2085
  ])) : r("", !0),
1574
- e.showLauncherIcon ?? e.launcher ? (v(), n(E(ee), {
2086
+ e.showLauncherIcon ?? e.launcher ? (v(), n(E(te), {
1575
2087
  key: 3,
1576
2088
  link: "",
1577
2089
  class: "ml-ribbon-group__launcher",
1578
2090
  disabled: x.value
1579
2091
  }, {
1580
- default: O(() => [c(E(F), null, {
1581
- default: O(() => [c(E(de))]),
2092
+ default: O(() => [c(E(I), null, {
2093
+ default: O(() => [c(E(U))]),
1582
2094
  _: 1
1583
2095
  })]),
1584
2096
  _: 1
1585
2097
  }, 8, ["disabled"])) : r("", !0)
1586
- ])], 14, at));
2098
+ ])], 14, Bt));
1587
2099
  }
1588
- }), mt = ["inert", "aria-disabled"], ht = { class: "ml-ribbon__head-left" }, gt = { class: "ml-ribbon__head-right" }, _t = {
2100
+ }), Yt = ["inert", "aria-disabled"], Xt = { class: "ml-ribbon__head-left" }, Zt = { class: "ml-ribbon__head-right" }, Qt = {
1589
2101
  key: 2,
1590
2102
  class: "ml-ribbon__tabs-extra"
1591
- }, vt = ["data-active-tab"], yt = {
2103
+ }, $t = ["data-active-tab"], en = {
1592
2104
  key: 0,
1593
2105
  class: "ml-ribbon-group ml-ribbon-group--overflow"
1594
- }, bt = { class: "ml-ribbon-group__body ml-ribbon-group__body--overflow" }, xt = ["aria-label", "disabled"], St = { class: "ml-ribbon-overflow-list" }, Ct = { class: "ml-ribbon-overflow-group__header" }, wt = ["data-active-tab"], Tt = ["disabled"], Et = { class: "ml-ribbon-simplified-group__panel" }, Dt = ["data-active-tab"], Ot = {
2106
+ }, tn = { class: "ml-ribbon-group__body ml-ribbon-group__body--overflow" }, nn = ["aria-label", "disabled"], rn = { class: "ml-ribbon-overflow-list" }, an = { class: "ml-ribbon-overflow-group__header" }, on = ["data-active-tab"], sn = ["disabled"], cn = { class: "ml-ribbon-simplified-group__panel" }, ln = ["data-active-tab"], un = {
1595
2107
  key: 0,
1596
2108
  class: "ml-ribbon-group ml-ribbon-group--overflow"
1597
- }, kt = { class: "ml-ribbon-group__body ml-ribbon-group__body--overflow" }, At = ["aria-label", "disabled"], jt = { class: "ml-ribbon-overflow-list" }, Mt = { class: "ml-ribbon-overflow-group__header" }, Nt = ["data-active-tab"], Pt = ["disabled"], Ft = { class: "ml-ribbon-simplified-group__panel" }, It = 40, Lt = /* @__PURE__ */ l({
2109
+ }, dn = { class: "ml-ribbon-group__body ml-ribbon-group__body--overflow" }, fn = ["aria-label", "disabled"], pn = { class: "ml-ribbon-overflow-list" }, mn = { class: "ml-ribbon-overflow-group__header" }, hn = ["data-active-tab"], gn = ["disabled"], _n = { class: "ml-ribbon-simplified-group__panel" }, vn = 40, yn = /* @__PURE__ */ l({
1598
2110
  __name: "Ribbon",
1599
2111
  props: {
1600
2112
  id: { default: "ml-ribbon-root" },
@@ -1663,30 +2175,46 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
1663
2175
  ...t,
1664
2176
  icon: f(t.icon)
1665
2177
  } : t;
2178
+ })), Array.isArray(t.categories) && (t.categories = t.categories.map((e) => {
2179
+ if (!e || typeof e != "object") return e;
2180
+ let t = e;
2181
+ return {
2182
+ ...t,
2183
+ items: Array.isArray(t.items) ? t.items.map((e) => {
2184
+ if (!e || typeof e != "object") return e;
2185
+ let t = e;
2186
+ return {
2187
+ ...t,
2188
+ preview: f(t.preview),
2189
+ icon: f(t.icon),
2190
+ component: f(t.component)
2191
+ };
2192
+ }) : t.items
2193
+ };
1666
2194
  })), t;
1667
2195
  }
1668
- function A(e) {
2196
+ function ee(e) {
1669
2197
  return {
1670
2198
  ...e,
1671
2199
  icon: f(e.icon),
1672
2200
  props: k(e.props)
1673
2201
  };
1674
2202
  }
1675
- function te(e) {
2203
+ function A(e) {
1676
2204
  return {
1677
2205
  ...e,
1678
2206
  icon: f(e.icon),
1679
- footerMenuItems: e.footerMenuItems?.map(A),
2207
+ footerMenuItems: e.footerMenuItems?.map(ee),
1680
2208
  collections: e.collections?.map((e) => ({
1681
2209
  ...e,
1682
- items: e.items?.map(A)
2210
+ items: e.items?.map(ee)
1683
2211
  }))
1684
2212
  };
1685
2213
  }
1686
2214
  function ne(e) {
1687
2215
  return e.map((e) => ({
1688
2216
  ...e,
1689
- groups: e.groups?.map(te)
2217
+ groups: e.groups?.map(A)
1690
2218
  }));
1691
2219
  }
1692
2220
  function j(e, t) {
@@ -1707,44 +2235,44 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
1707
2235
  keyTipsEmptySequence: "No key sequence",
1708
2236
  contextualTabDefaultTitle: "Contextual",
1709
2237
  galleryPreviewFallback: "Preview unavailable"
1710
- }, N = s, P = u, { context: I, visibleTabs: ie } = he(N.id, N.tabs, N.disabled, N.activeLayout ? String(N.activeLayout).toLowerCase() === "simplified" ? "simplified" : "classic" : N.layout, N.minimized, N.activeTab || N.tabs[0]?.id || "", j(N.tooltipShowAfter, 1e3), j(N.tooltipHideAfter, 0));
1711
- y(fe, I), D(() => N.tabs, (e) => {
1712
- I.tabs.value = ne(e), I.tabs.value.some((e) => e.id === I.activeTab.value) || (I.activeTab.value = I.tabs.value[0]?.id || "");
2238
+ }, N = s, P = u, { context: F, visibleTabs: ie } = ve(N.id, N.tabs, N.disabled, N.activeLayout ? String(N.activeLayout).toLowerCase() === "simplified" ? "simplified" : "classic" : N.layout, N.minimized, N.activeTab || N.tabs[0]?.id || "", j(N.tooltipShowAfter, 1e3), j(N.tooltipHideAfter, 0));
2239
+ y(pe, F), D(() => N.tabs, (e) => {
2240
+ F.tabs.value = ne(e), F.tabs.value.some((e) => e.id === F.activeTab.value) || (F.activeTab.value = F.tabs.value[0]?.id || "");
1713
2241
  }, { deep: !0 }), D(() => N.layout, (e) => {
1714
- e !== I.layout.value && (I.layout.value = e);
2242
+ e !== F.layout.value && (F.layout.value = e);
1715
2243
  }), D(() => N.activeLayout, (e) => {
1716
2244
  if (!e) return;
1717
2245
  let t = String(e).toLowerCase() === "simplified" ? "simplified" : "classic";
1718
- t !== I.layout.value && (I.layout.value = t);
2246
+ t !== F.layout.value && (F.layout.value = t);
1719
2247
  }), D(() => N.minimized, (e) => {
1720
- e !== I.minimized.value && (I.minimized.value = e);
2248
+ e !== F.minimized.value && (F.minimized.value = e);
1721
2249
  }), D(() => N.disabled, (e) => {
1722
- e !== I.disabled.value && (I.disabled.value = e);
2250
+ e !== F.disabled.value && (F.disabled.value = e);
1723
2251
  }), D(() => N.activeTab, (e) => {
1724
- e && e !== I.activeTab.value && (I.activeTab.value = e);
2252
+ e && e !== F.activeTab.value && (F.activeTab.value = e);
1725
2253
  }), D(() => N.tooltipShowAfter, (e) => {
1726
2254
  let t = j(e, 1e3);
1727
- t !== I.tooltipShowAfter.value && (I.tooltipShowAfter.value = t);
2255
+ t !== F.tooltipShowAfter.value && (F.tooltipShowAfter.value = t);
1728
2256
  }), D(() => N.tooltipHideAfter, (e) => {
1729
2257
  let t = j(e, 0);
1730
- t !== I.tooltipHideAfter.value && (I.tooltipHideAfter.value = t);
1731
- }), D(I.activeTab, (e) => {
2258
+ t !== F.tooltipHideAfter.value && (F.tooltipHideAfter.value = t);
2259
+ }), D(F.activeTab, (e) => {
1732
2260
  P("update:activeTab", e), P("tabChange", e);
1733
- }), D(I.layout, (e) => {
2261
+ }), D(F.layout, (e) => {
1734
2262
  P("update:layout", e), P("layoutChange", e);
1735
- }), D(I.minimized, (e) => {
2263
+ }), D(F.minimized, (e) => {
1736
2264
  P("update:minimized", e);
1737
- }), D(I.overflowOpen, (e) => {
2265
+ }), D(F.overflowOpen, (e) => {
1738
2266
  P(e ? "overflowOpen" : "overflowClose");
1739
- }), D(I.backdropOpen, (e) => {
2267
+ }), D(F.backdropOpen, (e) => {
1740
2268
  P(e ? "backstageOpen" : "backstageClose");
1741
2269
  });
1742
- let L = t(() => ie.value.find((e) => e.id === I.activeTab.value)), oe = t(() => new Set(ie.value.filter((e) => e.contextual && e.contextualMode === "exclusive").map((e) => e.id))), B = t(() => Re(L.value)), H = t(() => L.value?.groups?.filter((e) => e.visible !== !1) ?? []), de = b(null), U = b(null), W = b(null), G = b(null), K = b(!1), pe = b(0), me = b({
2270
+ let L = t(() => ie.value.find((e) => e.id === F.activeTab.value)), z = t(() => new Set(ie.value.filter((e) => e.contextual && e.contextualMode === "exclusive").map((e) => e.id))), B = t(() => Le(L.value)), H = t(() => L.value?.groups?.filter((e) => e.visible !== !1) ?? []), ce = b(null), ue = b(null), U = b(null), W = b(null), G = b(!1), me = b(0), he = b({
1743
2271
  left: "0px",
1744
2272
  top: "0px",
1745
2273
  width: "1px",
1746
2274
  height: "0px"
1747
- }), q = b(/* @__PURE__ */ new Set()), J = b({}), ge = se("size", ""), _e = t(() => N.size || ge.value || "default"), ve = t(() => `ml-ribbon-group-popover ml-ribbon-group-popover--size-${_e.value}`), ye = t(() => `ml-ribbon-overflow-popover ml-ribbon-overflow-popover--size-${_e.value}`), be = t(() => `ml-ribbon-tab-panel-popover ml-ribbon-tab-panel-popover--size-${_e.value}`), X = t(() => ({
2275
+ }), K = b(/* @__PURE__ */ new Set()), ge = b({}), _e = oe("size", ""), q = t(() => N.size || _e.value || "default"), ye = t(() => `ml-ribbon-group-popover ml-ribbon-group-popover--size-${q.value}`), be = t(() => `ml-ribbon-overflow-popover ml-ribbon-overflow-popover--size-${q.value}`), J = t(() => `ml-ribbon-tab-panel-popover ml-ribbon-tab-panel-popover--size-${q.value}`), Y = t(() => ({
1748
2276
  layoutSwitcherTooltip: N.texts.layoutSwitcherTooltip || M.layoutSwitcherTooltip,
1749
2277
  minimizeTooltip: N.texts.minimizeTooltip || M.minimizeTooltip,
1750
2278
  keyTipsToggleText: N.texts.keyTipsToggleText || M.keyTipsToggleText,
@@ -1759,17 +2287,17 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
1759
2287
  keyTipsEmptySequence: N.texts.keyTipsEmptySequence || M.keyTipsEmptySequence,
1760
2288
  contextualTabDefaultTitle: N.texts.contextualTabDefaultTitle || M.contextualTabDefaultTitle,
1761
2289
  galleryPreviewFallback: N.texts.galleryPreviewFallback || M.galleryPreviewFallback
1762
- })), xe = t(() => j(N.tooltipShowAfter, 1e3)), Se = t(() => j(N.tooltipHideAfter, 0)), Ce = t(() => I.minimized.value ? ce : V), we = t(() => H.value.filter((e) => !q.value.has(e.id))), Ee = t(() => H.value.filter((e) => q.value.has(e.id))), Oe = t(() => {
1763
- if (!Ee.value.length) return 220;
1764
- let e = Ee.value.reduce((e, t) => {
1765
- let n = J.value[t.id] ?? je(t);
2290
+ })), Z = t(() => j(N.tooltipShowAfter, 1e3)), Q = t(() => j(N.tooltipHideAfter, 0)), xe = t(() => F.minimized.value ? le : se), Se = t(() => H.value.filter((e) => !K.value.has(e.id))), Ce = t(() => H.value.filter((e) => K.value.has(e.id))), we = t(() => {
2291
+ if (!Ce.value.length) return 220;
2292
+ let e = Ce.value.reduce((e, t) => {
2293
+ let n = ge.value[t.id] ?? ke(t);
1766
2294
  return Math.max(e, n);
1767
2295
  }, 0), t = Math.ceil(e + 40);
1768
2296
  return Math.max(220, Math.min(720, t));
1769
2297
  });
1770
- function ke(e) {
2298
+ function Ee(e) {
1771
2299
  let t = (e.collections ?? []).flatMap((e) => (e.items ?? []).map((e) => ({
1772
- ...A(e),
2300
+ ...ee(e),
1773
2301
  size: "medium"
1774
2302
  })));
1775
2303
  return {
@@ -1782,13 +2310,13 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
1782
2310
  }]
1783
2311
  };
1784
2312
  }
1785
- function Ae(e) {
2313
+ function Oe(e) {
1786
2314
  return e.priority ?? 100;
1787
2315
  }
1788
- function je(e) {
2316
+ function ke(e) {
1789
2317
  return typeof e.width == "number" && Number.isFinite(e.width) && e.width > 0 ? e.width : 140;
1790
2318
  }
1791
- function Me(e) {
2319
+ function Ae(e) {
1792
2320
  let t = {};
1793
2321
  return e.querySelectorAll(".ml-ribbon-group").forEach((e) => {
1794
2322
  let n = e.dataset.groupId;
@@ -1797,109 +2325,109 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
1797
2325
  r > 0 && (t[n] = r);
1798
2326
  }), t;
1799
2327
  }
1800
- function Ne() {
2328
+ function je() {
1801
2329
  let e = H.value.reduce((e, t) => {
1802
- let n = J.value[t.id] ?? je(t);
1803
- return e + Math.max(n, je(t));
2330
+ let n = ge.value[t.id] ?? ke(t);
2331
+ return e + Math.max(n, ke(t));
1804
2332
  }, 0);
1805
2333
  return Math.max(220, e);
1806
2334
  }
1807
- function Pe(e) {
2335
+ function Me(e) {
1808
2336
  let t = Number.parseFloat(getComputedStyle(e).getPropertyValue("--ml-rb-overflow-slot-width"));
1809
- return Number.isFinite(t) && t > 0 ? t : It;
2337
+ return Number.isFinite(t) && t > 0 ? t : vn;
1810
2338
  }
1811
- function Fe() {
1812
- if (I.layout.value !== "classic") {
1813
- q.value = /* @__PURE__ */ new Set();
2339
+ function Ne() {
2340
+ if (F.layout.value !== "classic") {
2341
+ K.value = /* @__PURE__ */ new Set();
1814
2342
  return;
1815
2343
  }
1816
- let e = I.minimized.value ? G.value : W.value;
2344
+ let e = F.minimized.value ? W.value : U.value;
1817
2345
  if (!e) return;
1818
2346
  let t = H.value;
1819
2347
  if (!t.length) {
1820
- q.value = /* @__PURE__ */ new Set();
2348
+ K.value = /* @__PURE__ */ new Set();
1821
2349
  return;
1822
2350
  }
1823
- let n = Math.round(e.getBoundingClientRect().width), r = Pe(e), i = Me(e);
1824
- J.value = {
1825
- ...J.value,
2351
+ let n = Math.round(e.getBoundingClientRect().width), r = Me(e), i = Ae(e);
2352
+ ge.value = {
2353
+ ...ge.value,
1826
2354
  ...i
1827
2355
  };
1828
2356
  let a = t.filter((e) => e.enableGroupOverflow === !1), o = t.filter((e) => e.enableGroupOverflow !== !1).map((e, t) => ({
1829
2357
  group: e,
1830
2358
  index: t
1831
2359
  })), s = /* @__PURE__ */ new Set(), c = [...o].sort((e, t) => {
1832
- let n = Ae(t.group) - Ae(e.group);
2360
+ let n = Oe(t.group) - Oe(e.group);
1833
2361
  return n === 0 ? t.index - e.index : n;
1834
- }), l = (e) => i[e.id] ?? je(e), u = a.reduce((e, t) => e + l(t), 0), d = (e) => o.filter(({ group: t }) => !e.has(t.id)).reduce((e, { group: t }) => e + l(t), 0), f = (e) => u + d(e) + (e.size > 0 ? r : 0), p = 0;
2362
+ }), l = (e) => i[e.id] ?? ke(e), u = a.reduce((e, t) => e + l(t), 0), d = (e) => o.filter(({ group: t }) => !e.has(t.id)).reduce((e, { group: t }) => e + l(t), 0), f = (e) => u + d(e) + (e.size > 0 ? r : 0), p = 0;
1835
2363
  for (; f(s) > n && p < c.length;) {
1836
2364
  let e = c[p].group;
1837
2365
  s.add(e.id), p += 1;
1838
2366
  }
1839
- q.value = s;
2367
+ K.value = s;
1840
2368
  }
1841
- function Ie() {
2369
+ function Pe() {
1842
2370
  p(() => {
1843
- if (I.layout.value !== "classic" || I.minimized.value) {
1844
- Fe();
2371
+ if (F.layout.value !== "classic" || F.minimized.value) {
2372
+ Ne();
1845
2373
  return;
1846
2374
  }
1847
- if (q.value.size === 0) {
1848
- Fe();
2375
+ if (K.value.size === 0) {
2376
+ Ne();
1849
2377
  return;
1850
2378
  }
1851
- q.value = /* @__PURE__ */ new Set(), p(() => {
1852
- Fe();
2379
+ K.value = /* @__PURE__ */ new Set(), p(() => {
2380
+ Ne();
1853
2381
  });
1854
2382
  });
1855
2383
  }
1856
- function Le() {
1857
- let e = de.value, t = U.value;
2384
+ function Fe() {
2385
+ let e = ce.value, t = ue.value;
1858
2386
  if (!e || !t) return;
1859
2387
  let n = e.getBoundingClientRect(), r = t.getBoundingClientRect(), i = Number.parseFloat(getComputedStyle(e).borderLeftWidth || "0") || 0, a = Math.max(n.width - i * 2, e.clientWidth, r.width, t.clientWidth);
1860
- pe.value = Math.round(a > 0 ? a : I.layout.value === "classic" ? Ne() : Math.max(360, H.value.length * 120)), me.value = {
2388
+ me.value = Math.round(a > 0 ? a : F.layout.value === "classic" ? je() : Math.max(360, H.value.length * 120)), he.value = {
1861
2389
  left: `${Math.round(n.left - r.left + i)}px`,
1862
2390
  top: "0px",
1863
2391
  width: "1px",
1864
2392
  height: `${Math.round(r.height)}px`
1865
2393
  };
1866
2394
  }
1867
- function Z() {
1868
- K.value = !1;
2395
+ function Ie() {
2396
+ G.value = !1;
1869
2397
  }
1870
- function Re(e) {
1871
- return I.disabled.value ? !0 : !e || oe.value.size === 0 ? !1 : !oe.value.has(e.id);
2398
+ function Le(e) {
2399
+ return F.disabled.value ? !0 : !e || z.value.size === 0 ? !1 : !z.value.has(e.id);
1872
2400
  }
1873
- function ze(e) {
1874
- if (I.disabled.value) return;
1875
- let t = I.activeTab.value === e.id;
1876
- if (I.activeTab.value = e.id, !I.minimized.value) {
1877
- Z();
2401
+ function Re(e) {
2402
+ if (F.disabled.value) return;
2403
+ let t = F.activeTab.value === e.id;
2404
+ if (F.activeTab.value = e.id, !F.minimized.value) {
2405
+ Ie();
1878
2406
  return;
1879
2407
  }
1880
- Le(), K.value = t ? !K.value : !0;
2408
+ Fe(), G.value = t ? !G.value : !0;
2409
+ }
2410
+ function ze() {
2411
+ F.disabled.value || F.api.toggleSimplified();
1881
2412
  }
1882
2413
  function Be() {
1883
- I.disabled.value || I.api.toggleSimplified();
2414
+ F.disabled.value || (F.minimized.value || Ie(), F.minimized.value = !F.minimized.value);
1884
2415
  }
1885
- function Ve() {
1886
- I.disabled.value || (I.minimized.value || Z(), I.minimized.value = !I.minimized.value);
2416
+ function Ve(e) {
2417
+ F.disabled.value || (Ie(), P("fileMenuSelect", e));
1887
2418
  }
1888
- function He(e) {
1889
- I.disabled.value || (Z(), P("fileMenuSelect", e));
2419
+ function He() {
2420
+ F.disabled.value || (Ie(), F.backdropOpen.value = !0);
1890
2421
  }
1891
2422
  function Ue() {
1892
- I.disabled.value || (Z(), I.backdropOpen.value = !0);
2423
+ F.disabled.value || (F.backdropOpen.value = !1);
1893
2424
  }
1894
- function We() {
1895
- I.disabled.value || (I.backdropOpen.value = !1);
1896
- }
1897
- function Q(e, t) {
2425
+ function We(e, t) {
1898
2426
  B.value || (P("itemClick", {
1899
- tabId: I.activeTab.value,
2427
+ tabId: F.activeTab.value,
1900
2428
  groupId: e,
1901
2429
  itemId: t
1902
- }), I.minimized.value && Z());
2430
+ }), F.minimized.value && Ie());
1903
2431
  }
1904
2432
  function Ge(e) {
1905
2433
  if (!(e instanceof HTMLElement)) return !1;
@@ -1909,12 +2437,12 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
1909
2437
  }
1910
2438
  function Ke() {
1911
2439
  if (B.value) {
1912
- I.keyTips.value = [];
2440
+ F.keyTips.value = [];
1913
2441
  return;
1914
2442
  }
1915
2443
  let e = L.value;
1916
2444
  if (!e?.groups?.length) {
1917
- I.keyTips.value = [];
2445
+ F.keyTips.value = [];
1918
2446
  return;
1919
2447
  }
1920
2448
  let t = e.groups.filter((e) => e.visible !== !1).flatMap((t) => (t.collections ?? []).flatMap((n) => n.items.filter((e) => e.keyTip && e.disabled !== !0).map((n) => {
@@ -1927,134 +2455,134 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
1927
2455
  scope: "item"
1928
2456
  } : null;
1929
2457
  }).filter((e) => !!e)));
1930
- I.keyTips.value = t;
2458
+ F.keyTips.value = t;
1931
2459
  }
1932
2460
  function qe(e) {
1933
- if (I.disabled.value) return;
2461
+ if (F.disabled.value) return;
1934
2462
  let t = L.value;
1935
2463
  if (t?.groups?.length) {
1936
2464
  for (let n of t.groups) if (n.visible !== !1) for (let t of n.collections ?? []) {
1937
2465
  let r = t.items.find((t) => t.id === e.targetId && t.disabled !== !0);
1938
2466
  if (r) {
1939
- Q(n.id, r.id), I.keyTipsOpen.value = !1, I.keyTipsSequence.value = "";
2467
+ We(n.id, r.id), F.keyTipsOpen.value = !1, F.keyTipsSequence.value = "";
1940
2468
  return;
1941
2469
  }
1942
2470
  }
1943
2471
  }
1944
2472
  }
1945
2473
  function Je() {
1946
- I.keyTipsSequence.value = "";
2474
+ F.keyTipsSequence.value = "";
1947
2475
  }
1948
2476
  function Ye(e) {
1949
- if (!I.disabled.value && !Ge(e.target)) {
2477
+ if (!F.disabled.value && !Ge(e.target)) {
1950
2478
  if (e.altKey && !e.ctrlKey && !e.metaKey && e.key === "Alt") {
1951
- e.preventDefault(), I.keyTipsOpen.value = !I.keyTipsOpen.value, I.keyTipsOpen.value || Je();
2479
+ e.preventDefault(), F.keyTipsOpen.value = !F.keyTipsOpen.value, F.keyTipsOpen.value || Je();
1952
2480
  return;
1953
2481
  }
1954
- if (I.keyTipsOpen.value && !(e.altKey || e.ctrlKey || e.metaKey)) {
2482
+ if (F.keyTipsOpen.value && !(e.altKey || e.ctrlKey || e.metaKey)) {
1955
2483
  if (e.key === "Escape") {
1956
- e.preventDefault(), I.keyTipsOpen.value = !1, Je();
2484
+ e.preventDefault(), F.keyTipsOpen.value = !1, Je();
1957
2485
  return;
1958
2486
  }
1959
2487
  if (e.key === "Backspace") {
1960
- e.preventDefault(), I.keyTipsSequence.value = I.keyTipsSequence.value.slice(0, -1);
2488
+ e.preventDefault(), F.keyTipsSequence.value = F.keyTipsSequence.value.slice(0, -1);
1961
2489
  return;
1962
2490
  }
1963
2491
  if (/^[a-z0-9]$/i.test(e.key)) {
1964
2492
  e.preventDefault();
1965
- let t = `${I.keyTipsSequence.value}${e.key.toUpperCase()}`;
1966
- I.keyTipsSequence.value = t;
1967
- let n = t.toLowerCase(), r = I.keyTips.value.find((e) => e.key.toLowerCase() === n);
2493
+ let t = `${F.keyTipsSequence.value}${e.key.toUpperCase()}`;
2494
+ F.keyTipsSequence.value = t;
2495
+ let n = t.toLowerCase(), r = F.keyTips.value.find((e) => e.key.toLowerCase() === n);
1968
2496
  if (r) {
1969
2497
  qe(r);
1970
2498
  return;
1971
2499
  }
1972
- I.keyTips.value.some((e) => e.key.toLowerCase().startsWith(n)) || Je();
2500
+ F.keyTips.value.some((e) => e.key.toLowerCase().startsWith(n)) || Je();
1973
2501
  }
1974
2502
  }
1975
2503
  }
1976
2504
  }
1977
2505
  function Xe(e) {
1978
- return e.icon && typeof e.icon != "string" ? e.icon : e.groupIconCss ? le : null;
2506
+ return e.icon && typeof e.icon != "string" ? e.icon : e.groupIconCss ? de : null;
1979
2507
  }
1980
2508
  function Ze(e) {
1981
- K.value = e;
2509
+ G.value = e;
1982
2510
  }
1983
2511
  D([
1984
2512
  H,
1985
- () => I.layout.value,
1986
- () => I.minimized.value
2513
+ () => F.layout.value,
2514
+ () => F.minimized.value
1987
2515
  ], () => {
1988
- Ie();
2516
+ Pe();
1989
2517
  }), D([
1990
2518
  L,
1991
- () => I.tabs.value,
1992
- () => I.disabled.value
2519
+ () => F.tabs.value,
2520
+ () => F.disabled.value
1993
2521
  ], () => {
1994
2522
  Ke(), Je();
1995
2523
  }, {
1996
2524
  deep: !0,
1997
2525
  immediate: !0
1998
- }), D(() => I.keyTipsOpen.value, (e) => {
2526
+ }), D(() => F.keyTipsOpen.value, (e) => {
1999
2527
  e || Je();
2000
- }), D(() => I.disabled.value, (e) => {
2001
- e && (I.overflowOpen.value = !1, I.backdropOpen.value = !1, I.keyTipsOpen.value = !1, Z(), Je());
2528
+ }), D(() => F.disabled.value, (e) => {
2529
+ e && (F.overflowOpen.value = !1, F.backdropOpen.value = !1, F.keyTipsOpen.value = !1, Ie(), Je());
2002
2530
  }), D([
2003
- () => I.minimized.value,
2004
- () => I.layout.value,
2531
+ () => F.minimized.value,
2532
+ () => F.layout.value,
2005
2533
  L
2006
2534
  ], ([e, , t]) => {
2007
- (!e || !t) && Z();
2008
- }), D([W, G], ([e, t], [n, r]) => {
2009
- n && $ && $.unobserve(n), r && $ && $.unobserve(r), e && $ && $.observe(e), t && $ && $.observe(t), (e || t) && Ie();
2010
- }, { flush: "post" }), D(K, (e) => {
2535
+ (!e || !t) && Ie();
2536
+ }), D([U, W], ([e, t], [n, r]) => {
2537
+ n && $ && $.unobserve(n), r && $ && $.unobserve(r), e && $ && $.observe(e), t && $ && $.observe(t), (e || t) && Pe();
2538
+ }, { flush: "post" }), D(G, (e) => {
2011
2539
  e && p(() => {
2012
- Le(), Ie();
2540
+ Fe(), Pe();
2013
2541
  });
2014
2542
  });
2015
2543
  let $ = null;
2016
2544
  g(() => {
2017
2545
  window.addEventListener("keydown", Ye), window.addEventListener("resize", Qe), typeof ResizeObserver < "u" && ($ = new ResizeObserver(() => {
2018
- Le(), Ie();
2019
- }), W.value && $.observe(W.value), G.value && $.observe(G.value)), Le(), Ie();
2546
+ Fe(), Pe();
2547
+ }), U.value && $.observe(U.value), W.value && $.observe(W.value)), Fe(), Pe();
2020
2548
  }), _(() => {
2021
2549
  window.removeEventListener("keydown", Ye), window.removeEventListener("resize", Qe), $?.disconnect();
2022
2550
  });
2023
2551
  function Qe() {
2024
- K.value && Le();
2552
+ G.value && Fe();
2025
2553
  }
2026
- return l(I.api), (t, l) => (v(), n(E(re), { size: N.size }, {
2554
+ return l(F.api), (t, l) => (v(), n(E(re), { size: N.size }, {
2027
2555
  default: O(() => [(v(), i("section", {
2028
2556
  ref_key: "ribbonRootRef",
2029
- ref: de,
2030
- key: E(I).disabled.value ? "ml-ribbon-disabled" : "ml-ribbon-enabled",
2557
+ ref: ce,
2558
+ key: E(F).disabled.value ? "ml-ribbon-disabled" : "ml-ribbon-enabled",
2031
2559
  class: m(["ml-ribbon", [
2032
- `ml-ribbon--${E(I).layout.value}`,
2033
- `ml-ribbon--size-${_e.value}`,
2560
+ `ml-ribbon--${E(F).layout.value}`,
2561
+ `ml-ribbon--size-${q.value}`,
2034
2562
  {
2035
- "ml-ribbon--disabled": E(I).disabled.value,
2036
- "ml-ribbon--minimized": E(I).minimized.value,
2037
- "ml-ribbon--keytips-open": E(I).keyTipsOpen.value
2563
+ "ml-ribbon--disabled": E(F).disabled.value,
2564
+ "ml-ribbon--minimized": E(F).minimized.value,
2565
+ "ml-ribbon--keytips-open": E(F).keyTipsOpen.value
2038
2566
  }
2039
2567
  ]]),
2040
- inert: E(I).disabled.value,
2041
- "aria-disabled": E(I).disabled.value
2568
+ inert: E(F).disabled.value,
2569
+ "aria-disabled": E(F).disabled.value
2042
2570
  }, [
2043
2571
  a("header", {
2044
2572
  ref_key: "ribbonHeaderRef",
2045
- ref: U,
2573
+ ref: ue,
2046
2574
  class: "ml-ribbon__header"
2047
2575
  }, [
2048
- a("div", ht, [
2576
+ a("div", Xt, [
2049
2577
  s.showFileMenu ? (v(), n(De, {
2050
2578
  key: 0,
2051
2579
  items: s.fileMenuItems,
2052
- disabled: E(I).disabled.value,
2053
- label: X.value.fileMenuLabel,
2054
- "open-backstage-label": X.value.fileMenuOpenBackstageLabel,
2580
+ disabled: E(F).disabled.value,
2581
+ label: Y.value.fileMenuLabel,
2582
+ "open-backstage-label": Y.value.fileMenuOpenBackstageLabel,
2055
2583
  "show-open-backstage": s.showOpenBackstage,
2056
- onSelect: He,
2057
- onOpenBackstage: Ue
2584
+ onSelect: Ve,
2585
+ onOpenBackstage: He
2058
2586
  }, null, 8, [
2059
2587
  "items",
2060
2588
  "disabled",
@@ -2064,31 +2592,31 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
2064
2592
  ])) : r("", !0),
2065
2593
  c(Te, {
2066
2594
  tabs: E(ie),
2067
- "active-tab": E(I).activeTab.value,
2068
- disabled: E(I).disabled.value,
2069
- "default-contextual-title": X.value.contextualTabDefaultTitle,
2070
- onSelect: ze
2595
+ "active-tab": E(F).activeTab.value,
2596
+ disabled: E(F).disabled.value,
2597
+ "default-contextual-title": Y.value.contextualTabDefaultTitle,
2598
+ onSelect: Re
2071
2599
  }, null, 8, [
2072
2600
  "tabs",
2073
2601
  "active-tab",
2074
2602
  "disabled",
2075
2603
  "default-contextual-title"
2076
2604
  ]),
2077
- N.hideMinimizeButton ? r("", !0) : (v(), n(E(z), {
2605
+ N.hideMinimizeButton ? r("", !0) : (v(), n(E(ae), {
2078
2606
  key: 1,
2079
- content: X.value.minimizeTooltip,
2080
- "show-after": xe.value,
2081
- "hide-after": Se.value
2607
+ content: Y.value.minimizeTooltip,
2608
+ "show-after": Z.value,
2609
+ "hide-after": Q.value
2082
2610
  }, {
2083
- default: O(() => [c(E(ee), {
2611
+ default: O(() => [c(E(te), {
2084
2612
  class: m([
2085
2613
  "ml-ribbon__control",
2086
2614
  "ml-ribbon__control--minimize",
2087
- E(I).minimized.value ? "ml-ribbon__control--minimize-up" : "ml-ribbon__control--minimize-down"
2615
+ E(F).minimized.value ? "ml-ribbon__control--minimize-up" : "ml-ribbon__control--minimize-down"
2088
2616
  ]),
2089
- icon: Ce.value,
2090
- disabled: E(I).disabled.value,
2091
- onClick: Ve
2617
+ icon: xe.value,
2618
+ disabled: E(F).disabled.value,
2619
+ onClick: Be
2092
2620
  }, null, 8, [
2093
2621
  "class",
2094
2622
  "icon",
@@ -2101,19 +2629,19 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
2101
2629
  "hide-after"
2102
2630
  ]))
2103
2631
  ]),
2104
- a("div", gt, [
2105
- N.hideLayoutSwitcher ? r("", !0) : (v(), n(E(z), {
2632
+ a("div", Zt, [
2633
+ N.hideLayoutSwitcher ? r("", !0) : (v(), n(E(ae), {
2106
2634
  key: 0,
2107
- content: X.value.layoutSwitcherTooltip,
2108
- "show-after": xe.value,
2109
- "hide-after": Se.value
2635
+ content: Y.value.layoutSwitcherTooltip,
2636
+ "show-after": Z.value,
2637
+ "hide-after": Q.value
2110
2638
  }, {
2111
- default: O(() => [c(E(ee), {
2639
+ default: O(() => [c(E(te), {
2112
2640
  circle: "",
2113
2641
  class: "ml-ribbon__control ml-ribbon__control--layout",
2114
- icon: E(ue),
2115
- disabled: E(I).disabled.value,
2116
- onClick: Be
2642
+ icon: E(fe),
2643
+ disabled: E(F).disabled.value,
2644
+ onClick: ze
2117
2645
  }, null, 8, ["icon", "disabled"])]),
2118
2646
  _: 1
2119
2647
  }, 8, [
@@ -2121,51 +2649,51 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
2121
2649
  "show-after",
2122
2650
  "hide-after"
2123
2651
  ])),
2124
- N.hideKeyTipsToggle ? r("", !0) : (v(), n(E(R), {
2652
+ N.hideKeyTipsToggle ? r("", !0) : (v(), n(E(V), {
2125
2653
  key: 1,
2126
2654
  "inline-prompt": "",
2127
2655
  class: "ml-ribbon__control ml-ribbon__control--keytips",
2128
- "active-text": X.value.keyTipsToggleText,
2129
- "inactive-text": X.value.keyTipsToggleText,
2130
- "model-value": E(I).keyTipsOpen.value,
2131
- disabled: E(I).disabled.value,
2132
- onChange: l[0] ||= (e) => E(I).keyTipsOpen.value = !E(I).keyTipsOpen.value
2656
+ "active-text": Y.value.keyTipsToggleText,
2657
+ "inactive-text": Y.value.keyTipsToggleText,
2658
+ "model-value": E(F).keyTipsOpen.value,
2659
+ disabled: E(F).disabled.value,
2660
+ onChange: l[0] ||= (e) => E(F).keyTipsOpen.value = !E(F).keyTipsOpen.value
2133
2661
  }, null, 8, [
2134
2662
  "active-text",
2135
2663
  "inactive-text",
2136
2664
  "model-value",
2137
2665
  "disabled"
2138
2666
  ])),
2139
- t.$slots["tabs-extra"] ? (v(), i("div", _t, [S(t.$slots, "tabs-extra", {
2140
- activeTab: E(I).activeTab.value,
2141
- layout: E(I).layout.value,
2142
- minimized: E(I).minimized.value,
2143
- disabled: E(I).disabled.value
2667
+ t.$slots["tabs-extra"] ? (v(), i("div", Qt, [S(t.$slots, "tabs-extra", {
2668
+ activeTab: E(F).activeTab.value,
2669
+ layout: E(F).layout.value,
2670
+ minimized: E(F).minimized.value,
2671
+ disabled: E(F).disabled.value
2144
2672
  })])) : r("", !0)
2145
2673
  ]),
2146
- L.value ? (v(), n(E(ae), {
2674
+ L.value ? (v(), n(E(R), {
2147
2675
  key: 0,
2148
2676
  placement: "bottom-start",
2149
- visible: K.value,
2150
- width: pe.value || void 0,
2151
- disabled: E(I).disabled.value || !E(I).minimized.value,
2677
+ visible: G.value,
2678
+ width: me.value || void 0,
2679
+ disabled: E(F).disabled.value || !E(F).minimized.value,
2152
2680
  "show-arrow": !1,
2153
2681
  offset: 0,
2154
- "popper-class": be.value,
2682
+ "popper-class": J.value,
2155
2683
  "onUpdate:visible": Ze
2156
2684
  }, {
2157
2685
  reference: O(() => [a("span", {
2158
2686
  "aria-hidden": "true",
2159
2687
  class: "ml-ribbon__minimized-anchor",
2160
- style: h(me.value)
2688
+ style: h(he.value)
2161
2689
  }, null, 4)]),
2162
- default: O(() => [E(I).layout.value === "classic" ? (v(), i("main", {
2690
+ default: O(() => [E(F).layout.value === "classic" ? (v(), i("main", {
2163
2691
  key: 0,
2164
2692
  ref_key: "minimizedClassicPanelRef",
2165
- ref: G,
2693
+ ref: W,
2166
2694
  class: "ml-ribbon__panel ml-ribbon__panel--floating",
2167
2695
  "data-active-tab": L.value.id
2168
- }, [(v(!0), i(e, null, x(we.value, (e) => (v(), n(pt, {
2696
+ }, [(v(!0), i(e, null, x(Se.value, (e) => (v(), n(Jt, {
2169
2697
  id: e.id,
2170
2698
  key: e.id,
2171
2699
  "data-group-id": e.id,
@@ -2178,16 +2706,16 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
2178
2706
  launcher: e.launcher,
2179
2707
  "show-launcher-icon": e.showLauncherIcon,
2180
2708
  "group-model": e,
2181
- "overflow-trigger-aria-label": X.value.groupOverflowTriggerAriaLabel,
2182
- "gallery-preview-fallback": X.value.galleryPreviewFallback,
2709
+ "overflow-trigger-aria-label": Y.value.groupOverflowTriggerAriaLabel,
2710
+ "gallery-preview-fallback": Y.value.galleryPreviewFallback,
2183
2711
  disabled: B.value,
2184
- onItemClick: l[2] ||= (e) => Q(e.groupId, e.itemId)
2712
+ onItemClick: l[2] ||= (e) => We(e.groupId, e.itemId)
2185
2713
  }, {
2186
- default: O(() => [c(it, {
2714
+ default: O(() => [c(zt, {
2187
2715
  group: e,
2188
- "gallery-preview-fallback": X.value.galleryPreviewFallback,
2716
+ "gallery-preview-fallback": Y.value.galleryPreviewFallback,
2189
2717
  disabled: B.value,
2190
- onItemClick: l[1] ||= (e) => Q(e.groupId, e.itemId)
2718
+ onItemClick: l[1] ||= (e) => We(e.groupId, e.itemId)
2191
2719
  }, null, 8, [
2192
2720
  "group",
2193
2721
  "gallery-preview-fallback",
@@ -2209,30 +2737,30 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
2209
2737
  "overflow-trigger-aria-label",
2210
2738
  "gallery-preview-fallback",
2211
2739
  "disabled"
2212
- ]))), 128)), Ee.value.length ? (v(), i("section", yt, [a("div", bt, [c(E(ae), {
2740
+ ]))), 128)), Ce.value.length ? (v(), i("section", en, [a("div", tn, [c(E(R), {
2213
2741
  trigger: "click",
2214
2742
  placement: "bottom-end",
2215
- width: Oe.value,
2743
+ width: we.value,
2216
2744
  disabled: B.value,
2217
2745
  "show-arrow": !1,
2218
- "popper-class": ye.value,
2219
- onShow: l[4] ||= (e) => E(I).overflowOpen.value = !0,
2220
- onHide: l[5] ||= (e) => E(I).overflowOpen.value = !1
2746
+ "popper-class": be.value,
2747
+ onShow: l[4] ||= (e) => E(F).overflowOpen.value = !0,
2748
+ onHide: l[5] ||= (e) => E(F).overflowOpen.value = !1
2221
2749
  }, {
2222
2750
  reference: O(() => [a("button", {
2223
2751
  type: "button",
2224
2752
  class: "ml-ribbon-overflow-trigger",
2225
- "aria-label": X.value.overflowTriggerAriaLabel,
2753
+ "aria-label": Y.value.overflowTriggerAriaLabel,
2226
2754
  disabled: B.value
2227
- }, [...l[13] ||= [a("span", { class: "ml-ribbon-overflow-trigger__dots" }, "...", -1)]], 8, xt)]),
2228
- default: O(() => [a("div", St, [(v(!0), i(e, null, x(Ee.value, (e) => (v(), i("section", {
2755
+ }, [...l[13] ||= [a("span", { class: "ml-ribbon-overflow-trigger__dots" }, "...", -1)]], 8, nn)]),
2756
+ default: O(() => [a("div", rn, [(v(!0), i(e, null, x(Ce.value, (e) => (v(), i("section", {
2229
2757
  key: e.id,
2230
2758
  class: "ml-ribbon-overflow-group"
2231
- }, [a("header", Ct, w(e.title), 1), c(it, {
2759
+ }, [a("header", an, w(e.title), 1), c(zt, {
2232
2760
  group: e,
2233
- "gallery-preview-fallback": X.value.galleryPreviewFallback,
2761
+ "gallery-preview-fallback": Y.value.galleryPreviewFallback,
2234
2762
  disabled: B.value,
2235
- onItemClick: l[3] ||= (e) => Q(e.groupId, e.itemId)
2763
+ onItemClick: l[3] ||= (e) => We(e.groupId, e.itemId)
2236
2764
  }, null, 8, [
2237
2765
  "group",
2238
2766
  "gallery-preview-fallback",
@@ -2243,42 +2771,42 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
2243
2771
  "width",
2244
2772
  "disabled",
2245
2773
  "popper-class"
2246
- ])]), l[14] ||= a("footer", { class: "ml-ribbon-group__footer ml-ribbon-group__footer--overflow" }, null, -1)])) : r("", !0)], 8, vt)) : (v(), i("main", {
2774
+ ])]), l[14] ||= a("footer", { class: "ml-ribbon-group__footer ml-ribbon-group__footer--overflow" }, null, -1)])) : r("", !0)], 8, $t)) : (v(), i("main", {
2247
2775
  key: 1,
2248
2776
  class: "ml-ribbon__panel ml-ribbon__panel--simplified ml-ribbon__panel--floating",
2249
2777
  "data-active-tab": L.value.id
2250
- }, [(v(!0), i(e, null, x(H.value, (e) => (v(), n(E(ae), {
2778
+ }, [(v(!0), i(e, null, x(H.value, (e) => (v(), n(E(R), {
2251
2779
  key: e.id,
2252
2780
  trigger: "click",
2253
2781
  placement: "bottom-start",
2254
2782
  width: 340,
2255
2783
  disabled: B.value,
2256
2784
  "show-arrow": !1,
2257
- "popper-class": ve.value
2785
+ "popper-class": ye.value
2258
2786
  }, {
2259
2787
  reference: O(() => [a("button", {
2260
2788
  class: "ml-ribbon-simplified-group",
2261
2789
  type: "button",
2262
2790
  disabled: B.value
2263
- }, [Xe(e) ? (v(), n(E(F), {
2791
+ }, [Xe(e) ? (v(), n(E(I), {
2264
2792
  key: 0,
2265
2793
  class: "ml-ribbon-simplified-group__icon"
2266
2794
  }, {
2267
2795
  default: O(() => [(v(), n(C(Xe(e))))]),
2268
2796
  _: 2
2269
- }, 1024)) : r("", !0), a("span", null, w(e.title), 1)], 8, Tt)]),
2270
- default: O(() => [a("div", Et, [c(it, {
2271
- group: ke(e),
2272
- "gallery-preview-fallback": X.value.galleryPreviewFallback,
2797
+ }, 1024)) : r("", !0), a("span", null, w(e.title), 1)], 8, sn)]),
2798
+ default: O(() => [a("div", cn, [c(zt, {
2799
+ group: Ee(e),
2800
+ "gallery-preview-fallback": Y.value.galleryPreviewFallback,
2273
2801
  disabled: B.value,
2274
- onItemClick: l[6] ||= (e) => Q(e.groupId, e.itemId)
2802
+ onItemClick: l[6] ||= (e) => We(e.groupId, e.itemId)
2275
2803
  }, null, 8, [
2276
2804
  "group",
2277
2805
  "gallery-preview-fallback",
2278
2806
  "disabled"
2279
2807
  ])])]),
2280
2808
  _: 2
2281
- }, 1032, ["disabled", "popper-class"]))), 128))], 8, wt))]),
2809
+ }, 1032, ["disabled", "popper-class"]))), 128))], 8, on))]),
2282
2810
  _: 1
2283
2811
  }, 8, [
2284
2812
  "visible",
@@ -2287,13 +2815,13 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
2287
2815
  "popper-class"
2288
2816
  ])) : r("", !0)
2289
2817
  ], 512),
2290
- !E(I).minimized.value && L.value && E(I).layout.value === "classic" ? (v(), i("main", {
2818
+ !E(F).minimized.value && L.value && E(F).layout.value === "classic" ? (v(), i("main", {
2291
2819
  key: 0,
2292
2820
  class: "ml-ribbon__panel",
2293
2821
  "data-active-tab": L.value.id,
2294
2822
  ref_key: "classicPanelRef",
2295
- ref: W
2296
- }, [(v(!0), i(e, null, x(we.value, (e) => (v(), n(pt, {
2823
+ ref: U
2824
+ }, [(v(!0), i(e, null, x(Se.value, (e) => (v(), n(Jt, {
2297
2825
  id: e.id,
2298
2826
  key: e.id,
2299
2827
  "data-group-id": e.id,
@@ -2306,16 +2834,16 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
2306
2834
  launcher: e.launcher,
2307
2835
  "show-launcher-icon": e.showLauncherIcon,
2308
2836
  "group-model": e,
2309
- "overflow-trigger-aria-label": X.value.groupOverflowTriggerAriaLabel,
2310
- "gallery-preview-fallback": X.value.galleryPreviewFallback,
2837
+ "overflow-trigger-aria-label": Y.value.groupOverflowTriggerAriaLabel,
2838
+ "gallery-preview-fallback": Y.value.galleryPreviewFallback,
2311
2839
  disabled: B.value,
2312
- onItemClick: l[8] ||= (e) => Q(e.groupId, e.itemId)
2840
+ onItemClick: l[8] ||= (e) => We(e.groupId, e.itemId)
2313
2841
  }, {
2314
- default: O(() => [c(it, {
2842
+ default: O(() => [c(zt, {
2315
2843
  group: e,
2316
- "gallery-preview-fallback": X.value.galleryPreviewFallback,
2844
+ "gallery-preview-fallback": Y.value.galleryPreviewFallback,
2317
2845
  disabled: B.value,
2318
- onItemClick: l[7] ||= (e) => Q(e.groupId, e.itemId)
2846
+ onItemClick: l[7] ||= (e) => We(e.groupId, e.itemId)
2319
2847
  }, null, 8, [
2320
2848
  "group",
2321
2849
  "gallery-preview-fallback",
@@ -2337,29 +2865,29 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
2337
2865
  "overflow-trigger-aria-label",
2338
2866
  "gallery-preview-fallback",
2339
2867
  "disabled"
2340
- ]))), 128)), Ee.value.length ? (v(), i("section", Ot, [a("div", kt, [c(E(ae), {
2868
+ ]))), 128)), Ce.value.length ? (v(), i("section", un, [a("div", dn, [c(E(R), {
2341
2869
  trigger: "click",
2342
2870
  placement: "bottom-end",
2343
- width: Oe.value,
2871
+ width: we.value,
2344
2872
  disabled: B.value,
2345
- "popper-class": ye.value,
2346
- onShow: l[10] ||= (e) => E(I).overflowOpen.value = !0,
2347
- onHide: l[11] ||= (e) => E(I).overflowOpen.value = !1
2873
+ "popper-class": be.value,
2874
+ onShow: l[10] ||= (e) => E(F).overflowOpen.value = !0,
2875
+ onHide: l[11] ||= (e) => E(F).overflowOpen.value = !1
2348
2876
  }, {
2349
2877
  reference: O(() => [a("button", {
2350
2878
  type: "button",
2351
2879
  class: "ml-ribbon-overflow-trigger",
2352
- "aria-label": X.value.overflowTriggerAriaLabel,
2880
+ "aria-label": Y.value.overflowTriggerAriaLabel,
2353
2881
  disabled: B.value
2354
- }, [...l[15] ||= [a("span", { class: "ml-ribbon-overflow-trigger__dots" }, "...", -1)]], 8, At)]),
2355
- default: O(() => [a("div", jt, [(v(!0), i(e, null, x(Ee.value, (e) => (v(), i("section", {
2882
+ }, [...l[15] ||= [a("span", { class: "ml-ribbon-overflow-trigger__dots" }, "...", -1)]], 8, fn)]),
2883
+ default: O(() => [a("div", pn, [(v(!0), i(e, null, x(Ce.value, (e) => (v(), i("section", {
2356
2884
  key: e.id,
2357
2885
  class: "ml-ribbon-overflow-group"
2358
- }, [a("header", Mt, w(e.title), 1), c(it, {
2886
+ }, [a("header", mn, w(e.title), 1), c(zt, {
2359
2887
  group: e,
2360
- "gallery-preview-fallback": X.value.galleryPreviewFallback,
2888
+ "gallery-preview-fallback": Y.value.galleryPreviewFallback,
2361
2889
  disabled: B.value,
2362
- onItemClick: l[9] ||= (e) => Q(e.groupId, e.itemId)
2890
+ onItemClick: l[9] ||= (e) => We(e.groupId, e.itemId)
2363
2891
  }, null, 8, [
2364
2892
  "group",
2365
2893
  "gallery-preview-fallback",
@@ -2370,59 +2898,59 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
2370
2898
  "width",
2371
2899
  "disabled",
2372
2900
  "popper-class"
2373
- ])]), l[16] ||= a("footer", { class: "ml-ribbon-group__footer ml-ribbon-group__footer--overflow" }, null, -1)])) : r("", !0)], 8, Dt)) : r("", !0),
2374
- !E(I).minimized.value && L.value && E(I).layout.value === "simplified" ? (v(), i("main", {
2901
+ ])]), l[16] ||= a("footer", { class: "ml-ribbon-group__footer ml-ribbon-group__footer--overflow" }, null, -1)])) : r("", !0)], 8, ln)) : r("", !0),
2902
+ !E(F).minimized.value && L.value && E(F).layout.value === "simplified" ? (v(), i("main", {
2375
2903
  key: 1,
2376
2904
  class: "ml-ribbon__panel ml-ribbon__panel--simplified",
2377
2905
  "data-active-tab": L.value.id
2378
- }, [(v(!0), i(e, null, x(H.value, (e) => (v(), n(E(ae), {
2906
+ }, [(v(!0), i(e, null, x(H.value, (e) => (v(), n(E(R), {
2379
2907
  key: e.id,
2380
2908
  trigger: "click",
2381
2909
  placement: "bottom-start",
2382
2910
  width: 340,
2383
2911
  disabled: B.value,
2384
- "popper-class": ve.value
2912
+ "popper-class": ye.value
2385
2913
  }, {
2386
2914
  reference: O(() => [a("button", {
2387
2915
  class: "ml-ribbon-simplified-group",
2388
2916
  type: "button",
2389
2917
  disabled: B.value
2390
- }, [Xe(e) ? (v(), n(E(F), {
2918
+ }, [Xe(e) ? (v(), n(E(I), {
2391
2919
  key: 0,
2392
2920
  class: "ml-ribbon-simplified-group__icon"
2393
2921
  }, {
2394
2922
  default: O(() => [(v(), n(C(Xe(e))))]),
2395
2923
  _: 2
2396
- }, 1024)) : r("", !0), a("span", null, w(e.title), 1)], 8, Pt)]),
2397
- default: O(() => [a("div", Ft, [c(it, {
2398
- group: ke(e),
2399
- "gallery-preview-fallback": X.value.galleryPreviewFallback,
2924
+ }, 1024)) : r("", !0), a("span", null, w(e.title), 1)], 8, gn)]),
2925
+ default: O(() => [a("div", _n, [c(zt, {
2926
+ group: Ee(e),
2927
+ "gallery-preview-fallback": Y.value.galleryPreviewFallback,
2400
2928
  disabled: B.value,
2401
- onItemClick: l[12] ||= (e) => Q(e.groupId, e.itemId)
2929
+ onItemClick: l[12] ||= (e) => We(e.groupId, e.itemId)
2402
2930
  }, null, 8, [
2403
2931
  "group",
2404
2932
  "gallery-preview-fallback",
2405
2933
  "disabled"
2406
2934
  ])])]),
2407
2935
  _: 2
2408
- }, 1032, ["disabled", "popper-class"]))), 128))], 8, Nt)) : r("", !0),
2409
- c(Y, {
2410
- open: E(I).backdropOpen.value,
2411
- size: _e.value,
2412
- "back-label": X.value.backstageBackLabel,
2413
- title: X.value.backstageTitle,
2414
- description: X.value.backstageDescription,
2415
- onClose: We
2936
+ }, 1032, ["disabled", "popper-class"]))), 128))], 8, hn)) : r("", !0),
2937
+ c(X, {
2938
+ open: E(F).backdropOpen.value,
2939
+ size: q.value,
2940
+ "back-label": Y.value.backstageBackLabel,
2941
+ title: Y.value.backstageTitle,
2942
+ description: Y.value.backstageDescription,
2943
+ onClose: Ue
2416
2944
  }, o({ _: 2 }, [t.$slots.backstage ? {
2417
2945
  name: "default",
2418
2946
  fn: O(() => [S(t.$slots, "backstage", {
2419
- close: We,
2420
- open: E(I).backdropOpen.value,
2421
- size: _e.value,
2422
- backLabel: X.value.backstageBackLabel,
2423
- title: X.value.backstageTitle,
2424
- description: X.value.backstageDescription,
2425
- disabled: E(I).disabled.value
2947
+ close: Ue,
2948
+ open: E(F).backdropOpen.value,
2949
+ size: q.value,
2950
+ backLabel: Y.value.backstageBackLabel,
2951
+ title: Y.value.backstageTitle,
2952
+ description: Y.value.backstageDescription,
2953
+ disabled: E(F).disabled.value
2426
2954
  })]),
2427
2955
  key: "0"
2428
2956
  } : void 0]), 1032, [
@@ -2432,14 +2960,14 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
2432
2960
  "title",
2433
2961
  "description"
2434
2962
  ])
2435
- ], 10, mt))]),
2963
+ ], 10, Yt))]),
2436
2964
  _: 3
2437
2965
  }, 8, ["size"]));
2438
2966
  }
2439
- }), Rt = {
2967
+ }), bn = {
2440
2968
  class: "ml-ribbon-tab-definition",
2441
2969
  hidden: ""
2442
- }, zt = /* @__PURE__ */ l({
2970
+ }, xn = /* @__PURE__ */ l({
2443
2971
  __name: "RibbonTab",
2444
2972
  props: {
2445
2973
  id: {},
@@ -2450,13 +2978,13 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
2450
2978
  contextualTitle: {}
2451
2979
  },
2452
2980
  setup(e) {
2453
- return (e, t) => (v(), i("div", Rt, [S(e.$slots, "default")]));
2981
+ return (e, t) => (v(), i("div", bn, [S(e.$slots, "default")]));
2454
2982
  }
2455
- }), Bt = {
2983
+ }), Sn = {
2456
2984
  key: 0,
2457
2985
  class: "ml-ribbon-keytips",
2458
2986
  "aria-live": "polite"
2459
- }, Vt = { class: "ml-ribbon-keytips__hint" }, Ht = /* @__PURE__ */ l({
2987
+ }, Cn = { class: "ml-ribbon-keytips__hint" }, wn = /* @__PURE__ */ l({
2460
2988
  __name: "RibbonKeyTips",
2461
2989
  props: {
2462
2990
  open: { type: Boolean },
@@ -2491,11 +3019,11 @@ var ge = { class: "ml-ribbon-backstage__nav" }, _e = { class: "ml-ribbon-backsta
2491
3019
  }
2492
3020
  return g(() => window.addEventListener("keydown", S)), _(() => window.removeEventListener("keydown", S)), D(() => s.open, (e) => {
2493
3021
  e || y();
2494
- }), (t, o) => n.open ? (v(), i("div", Bt, [a("div", Vt, w(f.value), 1), (v(!0), i(e, null, x(u.value, (e) => (v(), i("span", {
3022
+ }), (t, o) => n.open ? (v(), i("div", Sn, [a("div", Cn, w(f.value), 1), (v(!0), i(e, null, x(u.value, (e) => (v(), i("span", {
2495
3023
  key: e.id,
2496
3024
  class: "ml-ribbon-keytip"
2497
3025
  }, w(e.key), 1))), 128))])) : r("", !0);
2498
3026
  }
2499
3027
  });
2500
3028
  //#endregion
2501
- export { Lt as MlRibbon, Y as MlRibbonBackstage, Ae as MlRibbonButton, Pe as MlRibbonButtonGroup, Oe as MlRibbonCollection, Te as MlRibbonContextualTabs, ze as MlRibbonDropdown, De as MlRibbonFileMenu, Ke as MlRibbonGallery, pt as MlRibbonGroup, rt as MlRibbonItemHost, Ht as MlRibbonKeyTips, $ as MlRibbonSegmented, zt as MlRibbonTab, xe as MlRibbonTabs, et as MlRibbonTemplateItem, Qe as MlRibbonToggleButton };
3029
+ export { yn as MlRibbon, X as MlRibbonBackstage, Ae as MlRibbonButton, Pe as MlRibbonButtonGroup, Oe as MlRibbonCollection, Te as MlRibbonContextualTabs, Be as MlRibbonDropdown, De as MlRibbonFileMenu, St as MlRibbonGallery, Jt as MlRibbonGroup, Et as MlRibbonInputNumber, Rt as MlRibbonItemHost, wn as MlRibbonKeyTips, Mt as MlRibbonSegmented, xn as MlRibbonTab, xe as MlRibbonTabs, Ft as MlRibbonTemplateItem, Nt as MlRibbonToggleButton };