@mintplayer/vue-bootstrap 3.24.0 → 3.25.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (41) hide show
  1. package/accordion/index.mjs +54 -64
  2. package/calendar/index.mjs +27 -28
  3. package/card/index.mjs +104 -145
  4. package/carousel/index.mjs +74 -58
  5. package/charts/hierarchy/index.mjs +44 -43
  6. package/charts/sparkline/index.mjs +25 -24
  7. package/charts/trend/index.mjs +25 -24
  8. package/checkbox/index.mjs +27 -28
  9. package/code-snippet/index.mjs +34 -32
  10. package/datatable/index.mjs +84 -70
  11. package/datepicker/index.mjs +27 -28
  12. package/datetime-picker/index.mjs +27 -28
  13. package/dock/index.mjs +27 -28
  14. package/dropdown-menu/index.mjs +69 -69
  15. package/file-manager/index.mjs +18 -19
  16. package/index.mjs +0 -1
  17. package/input-group/index.mjs +11 -12
  18. package/multi-range/index.mjs +27 -26
  19. package/navbar/index.mjs +77 -80
  20. package/otp-input/index.mjs +27 -26
  21. package/package.json +2 -2
  22. package/pagination/index.mjs +27 -26
  23. package/phone-input/index.mjs +35 -34
  24. package/query-builder/index.mjs +45 -41
  25. package/radio/index.mjs +27 -28
  26. package/radio-group/index.mjs +27 -28
  27. package/ribbon/index.mjs +28 -47
  28. package/scheduler/index.mjs +45 -42
  29. package/select/index.mjs +33 -34
  30. package/shell/index.mjs +37 -33
  31. package/signature-pad/index.mjs +26 -25
  32. package/splitter/index.mjs +12 -14
  33. package/tab-control/index.mjs +28 -31
  34. package/theming/index.mjs +37 -55
  35. package/tile-manager/index.mjs +18 -21
  36. package/timeline/index.mjs +151 -146
  37. package/timepicker/index.mjs +49 -53
  38. package/toggle-button/index.mjs +27 -28
  39. package/tree-select/index.mjs +105 -97
  40. package/treeview/index.mjs +56 -55
  41. package/vue-bootstrap.css +2 -1
@@ -1,27 +1,28 @@
1
- import { defineComponent as r, useModel as s, ref as u, onMounted as i, watch as m, openBlock as d, createElementBlock as c, mergeProps as p } from "vue";
1
+ import { createElementBlock as e, defineComponent as t, mergeProps as n, onMounted as r, openBlock as i, ref as a, useModel as o, watch as s } from "vue";
2
2
  import "@mintplayer/web-components/signature-pad";
3
- const h = /* @__PURE__ */ r({
4
- inheritAttrs: !1,
5
- __name: "BsSignaturePad",
6
- props: {
7
- modelValue: {},
8
- modelModifiers: {}
9
- },
10
- emits: ["update:modelValue"],
11
- setup(a) {
12
- const t = s(a, "modelValue"), n = u(null), o = (e) => {
13
- n.value && (n.value.signature = e ?? { strokes: [] });
14
- };
15
- i(() => o(t.value)), m(t, o);
16
- function l(e) {
17
- t.value = e.detail;
18
- }
19
- return (e, f) => (d(), c("mp-signature-pad", p({
20
- ref_key: "el",
21
- ref: n
22
- }, e.$attrs, { onSignatureChange: l }), null, 16));
23
- }
3
+ //#endregion
4
+ //#region libs/mintplayer-vue-bootstrap/signature-pad/src/BsSignaturePad.vue
5
+ var c = /* @__PURE__ */ t({
6
+ inheritAttrs: !1,
7
+ __name: "BsSignaturePad",
8
+ props: {
9
+ modelValue: {},
10
+ modelModifiers: {}
11
+ },
12
+ emits: ["update:modelValue"],
13
+ setup(t) {
14
+ let c = o(t, "modelValue"), l = a(null), u = (e) => {
15
+ l.value && (l.value.signature = e ?? { strokes: [] });
16
+ };
17
+ r(() => u(c.value)), s(c, u);
18
+ function d(e) {
19
+ c.value = e.detail;
20
+ }
21
+ return (t, r) => (i(), e("mp-signature-pad", n({
22
+ ref_key: "el",
23
+ ref: l
24
+ }, t.$attrs, { onSignatureChange: d }), null, 16));
25
+ }
24
26
  });
25
- export {
26
- h as BsSignaturePad
27
- };
27
+ //#endregion
28
+ export { c as BsSignaturePad };
@@ -1,15 +1,13 @@
1
- import { MpSplitter as _ } from "@mintplayer/web-components/splitter";
2
- import { defineComponent as t, openBlock as r, createElementBlock as o, normalizeProps as p, guardReactiveProps as s, renderSlot as n } from "vue";
3
- const m = /* @__PURE__ */ t({
4
- inheritAttrs: !1,
5
- __name: "BsSplitter",
6
- setup(l) {
7
- return (e, a) => (r(), o("mp-splitter", p(s(e.$attrs)), [
8
- n(e.$slots, "default")
9
- ], 16));
10
- }
1
+ import { createElementBlock as e, defineComponent as t, guardReactiveProps as n, normalizeProps as r, openBlock as i, renderSlot as a } from "vue";
2
+ import { MpSplitter as o } from "@mintplayer/web-components/splitter";
3
+ //#endregion
4
+ //#region libs/mintplayer-vue-bootstrap/splitter/src/BsSplitter.vue
5
+ var s = /* @__PURE__ */ t({
6
+ inheritAttrs: !1,
7
+ __name: "BsSplitter",
8
+ setup(t) {
9
+ return (t, o) => (i(), e("mp-splitter", r(n(t.$attrs)), [a(t.$slots, "default")], 16));
10
+ }
11
11
  });
12
- export {
13
- m as BsSplitter,
14
- _ as MpSplitter
15
- };
12
+ //#endregion
13
+ export { s as BsSplitter, o as MpSplitter };
@@ -1,32 +1,29 @@
1
- import { MpTabControl as B, MpTabPage as C } from "@mintplayer/web-components/tab-control";
2
- import { defineComponent as s, useModel as u, ref as i, onMounted as c, watch as d, openBlock as m, createElementBlock as f, mergeProps as p, renderSlot as b } from "vue";
3
- const T = /* @__PURE__ */ s({
4
- inheritAttrs: !1,
5
- __name: "BsTabControl",
6
- props: {
7
- modelValue: {},
8
- modelModifiers: {}
9
- },
10
- emits: ["update:modelValue"],
11
- setup(n) {
12
- const t = u(n, "modelValue"), o = i(null), a = (e) => {
13
- o.value && e !== void 0 && o.value.setAttribute("active-tab", e);
14
- };
15
- c(() => a(t.value)), d(t, a);
16
- function r(e) {
17
- const l = e.detail;
18
- l && (t.value = l.tabId);
19
- }
20
- return (e, l) => (m(), f("mp-tab-control", p({
21
- ref_key: "el",
22
- ref: o
23
- }, e.$attrs, { onTabActivate: r }), [
24
- b(e.$slots, "default")
25
- ], 16));
26
- }
1
+ import { createElementBlock as e, defineComponent as t, mergeProps as n, onMounted as r, openBlock as i, ref as a, renderSlot as o, useModel as s, watch as c } from "vue";
2
+ import { MpTabControl as l, MpTabPage as u } from "@mintplayer/web-components/tab-control";
3
+ //#endregion
4
+ //#region libs/mintplayer-vue-bootstrap/tab-control/src/BsTabControl.vue
5
+ var d = /* @__PURE__ */ t({
6
+ inheritAttrs: !1,
7
+ __name: "BsTabControl",
8
+ props: {
9
+ modelValue: {},
10
+ modelModifiers: {}
11
+ },
12
+ emits: ["update:modelValue"],
13
+ setup(t) {
14
+ let l = s(t, "modelValue"), u = a(null), d = (e) => {
15
+ u.value && e !== void 0 && u.value.setAttribute("active-tab", e);
16
+ };
17
+ r(() => d(l.value)), c(l, d);
18
+ function f(e) {
19
+ let t = e.detail;
20
+ t && (l.value = t.tabId);
21
+ }
22
+ return (t, r) => (i(), e("mp-tab-control", n({
23
+ ref_key: "el",
24
+ ref: u
25
+ }, t.$attrs, { onTabActivate: f }), [o(t.$slots, "default")], 16));
26
+ }
27
27
  });
28
- export {
29
- T as BsTabControl,
30
- B as MpTabControl,
31
- C as MpTabPage
32
- };
28
+ //#endregion
29
+ export { d as BsTabControl, l as MpTabControl, u as MpTabPage };
package/theming/index.mjs CHANGED
@@ -1,57 +1,39 @@
1
- import { defineComponent as u, ref as a, onMounted as f, watch as M, openBlock as T, createElementBlock as p, mergeProps as _, shallowRef as i, getCurrentScope as E, onScopeDispose as h, getCurrentInstance as g, readonly as l } from "vue";
2
- import { BS_THEME_DEFAULT_MODES as B, resolveMode as v, getBsThemeStore as m } from "@mintplayer/web-components/theming";
3
- import { BS_THEME_COOKIE_NAME as y, BS_THEME_DEFAULT_MODES as O, BS_THEME_DEFAULT_MODE_META as H, configureBsTheme as F, getBsThemeStore as L, injectThemeAttribute as U, isValidThemeMode as x, readDefaultModeMeta as I, readThemeCookie as j, resolveMode as K, resolveServerTheme as N, writeThemeCookie as P } from "@mintplayer/web-components/theming";
4
- const w = /* @__PURE__ */ u({
5
- inheritAttrs: !1,
6
- __name: "BsThemeToggle",
7
- props: {
8
- modes: {}
9
- },
10
- setup(o) {
11
- const s = o, e = a(null), t = () => {
12
- e.value && (e.value.modes = s.modes ?? B);
13
- };
14
- return f(t), M(() => s.modes, t), (r, n) => (T(), p("mp-theme-toggle", _({
15
- ref_key: "el",
16
- ref: e
17
- }, r.$attrs), null, 16));
18
- }
19
- }), d = () => typeof window < "u", S = (o) => {
20
- d() && m().setMode(o);
1
+ import { createElementBlock as e, defineComponent as t, getCurrentInstance as n, getCurrentScope as r, mergeProps as i, onMounted as a, onScopeDispose as o, openBlock as s, readonly as c, ref as l, shallowRef as u, watch as d } from "vue";
2
+ import { BS_THEME_COOKIE_NAME as f, BS_THEME_DEFAULT_MODES as p, BS_THEME_DEFAULT_MODES as m, BS_THEME_DEFAULT_MODE_META as h, configureBsTheme as g, getBsThemeStore as _, getBsThemeStore as v, injectThemeAttribute as y, isValidThemeMode as b, readDefaultModeMeta as x, readThemeCookie as S, resolveMode as C, resolveMode as w, resolveServerTheme as T, writeThemeCookie as E } from "@mintplayer/web-components/theming";
3
+ //#endregion
4
+ //#region libs/mintplayer-vue-bootstrap/theming/src/BsThemeToggle.vue
5
+ var D = /* @__PURE__ */ t({
6
+ inheritAttrs: !1,
7
+ __name: "BsThemeToggle",
8
+ props: { modes: {} },
9
+ setup(t) {
10
+ let n = t, r = l(null), o = () => {
11
+ r.value && (r.value.modes = n.modes ?? m);
12
+ };
13
+ return a(o), d(() => n.modes, o), (t, n) => (s(), e("mp-theme-toggle", i({
14
+ ref_key: "el",
15
+ ref: r
16
+ }, t.$attrs), null, 16));
17
+ }
18
+ }), O = () => typeof window < "u", k = (e) => {
19
+ O() && v().setMode(e);
21
20
  };
22
- function C() {
23
- const o = i("auto"), s = i(v("auto", !1));
24
- let e = () => {
25
- };
26
- if (d()) {
27
- const t = m(), r = () => {
28
- o.value = t.getMode(), s.value = t.effectiveMode();
29
- }, n = t.subscribe(r);
30
- let c = !1;
31
- e = () => {
32
- c || (c = !0, n());
33
- }, E() && h(e), g() ? f(r) : r();
34
- }
35
- return {
36
- mode: l(o),
37
- effectiveMode: l(s),
38
- setMode: S,
39
- stop: e
40
- };
21
+ function A() {
22
+ let e = u("auto"), t = u(w("auto", !1)), i = () => void 0;
23
+ if (O()) {
24
+ let s = v(), c = () => {
25
+ e.value = s.getMode(), t.value = s.effectiveMode();
26
+ }, l = s.subscribe(c), u = !1;
27
+ i = () => {
28
+ u || (u = !0, l());
29
+ }, r() && o(i), n() ? a(c) : c();
30
+ }
31
+ return {
32
+ mode: c(e),
33
+ effectiveMode: c(t),
34
+ setMode: k,
35
+ stop: i
36
+ };
41
37
  }
42
- export {
43
- y as BS_THEME_COOKIE_NAME,
44
- O as BS_THEME_DEFAULT_MODES,
45
- H as BS_THEME_DEFAULT_MODE_META,
46
- w as BsThemeToggle,
47
- F as configureBsTheme,
48
- L as getBsThemeStore,
49
- U as injectThemeAttribute,
50
- x as isValidThemeMode,
51
- I as readDefaultModeMeta,
52
- j as readThemeCookie,
53
- K as resolveMode,
54
- N as resolveServerTheme,
55
- C as useBsTheme,
56
- P as writeThemeCookie
57
- };
38
+ //#endregion
39
+ export { f as BS_THEME_COOKIE_NAME, p as BS_THEME_DEFAULT_MODES, h as BS_THEME_DEFAULT_MODE_META, D as BsThemeToggle, g as configureBsTheme, _ as getBsThemeStore, y as injectThemeAttribute, b as isValidThemeMode, x as readDefaultModeMeta, S as readThemeCookie, C as resolveMode, T as resolveServerTheme, A as useBsTheme, E as writeThemeCookie };
@@ -1,23 +1,20 @@
1
- import { defineComponent as l, ref as o, onMounted as a, watch as i, openBlock as p, createElementBlock as c, mergeProps as m, renderSlot as f } from "vue";
1
+ import { createElementBlock as e, defineComponent as t, mergeProps as n, onMounted as r, openBlock as i, ref as a, renderSlot as o, watch as s } from "vue";
2
2
  import "@mintplayer/web-components/tile-manager";
3
- const g = /* @__PURE__ */ l({
4
- inheritAttrs: !1,
5
- __name: "BsTileManager",
6
- props: {
7
- tiles: {}
8
- },
9
- setup(n) {
10
- const t = n, e = o(null), r = () => {
11
- e.value && (e.value.tiles = t.tiles ?? []);
12
- };
13
- return a(r), i(() => t.tiles, r), (s, u) => (p(), c("mp-tile-manager", m({
14
- ref_key: "el",
15
- ref: e
16
- }, s.$attrs), [
17
- f(s.$slots, "default")
18
- ], 16));
19
- }
3
+ //#endregion
4
+ //#region libs/mintplayer-vue-bootstrap/tile-manager/src/BsTileManager.vue
5
+ var c = /* @__PURE__ */ t({
6
+ inheritAttrs: !1,
7
+ __name: "BsTileManager",
8
+ props: { tiles: {} },
9
+ setup(t) {
10
+ let c = t, l = a(null), u = () => {
11
+ l.value && (l.value.tiles = c.tiles ?? []);
12
+ };
13
+ return r(u), s(() => c.tiles, u), (t, r) => (i(), e("mp-tile-manager", n({
14
+ ref_key: "el",
15
+ ref: l
16
+ }, t.$attrs), [o(t.$slots, "default")], 16));
17
+ }
20
18
  });
21
- export {
22
- g as BsTileManager
23
- };
19
+ //#endregion
20
+ export { c as BsTileManager };
@@ -1,147 +1,152 @@
1
- import { resolveSides as x } from "@mintplayer/web-components/timeline";
2
- import { MpTimeline as _, MpTimelineItem as ee } from "@mintplayer/web-components/timeline";
3
- import { defineComponent as L, useSlots as M, ref as w, computed as F, onMounted as A, onBeforeUnmount as D, watch as b, onUpdated as U, openBlock as a, createElementBlock as d, mergeProps as N, Fragment as O, renderList as P, renderSlot as m, createCommentVNode as u } from "vue";
4
- const V = ["orientation", "align", "reverse", "selectable"], j = ["item-id", "title", "description", "time", "icon", "color", "item-class", "disabled"], q = {
5
- key: 0,
6
- slot: "marker"
7
- }, z = {
8
- key: 1,
9
- slot: "title"
10
- }, G = {
11
- key: 2,
12
- slot: "opposite"
13
- }, H = {
14
- key: 3,
15
- slot: "opposite"
16
- }, J = {
17
- key: 4,
18
- slot: "content"
19
- }, W = /* @__PURE__ */ L({
20
- inheritAttrs: !1,
21
- __name: "BsTimeline",
22
- props: {
23
- items: {},
24
- orientation: { default: "vertical" },
25
- align: { default: "start" },
26
- reverse: { type: Boolean, default: !1 },
27
- selectable: { default: "none" },
28
- selection: {}
29
- },
30
- emits: ["item-click", "update:selection"],
31
- setup(s, { emit: p }) {
32
- const i = s, f = p, l = M(), S = () => !!(l.marker || l.title || l.timestamp || l.opposite || l.content), y = () => S() && !!i.items?.length, c = w(null), B = (t, o) => t.id ?? o, C = F(() => x(i.items?.length ?? 0, i.align, i.reverse)), v = (t, o) => {
33
- const e = i.items?.length ?? 0, n = i.reverse ? e - 1 - o : o;
34
- return {
35
- index: o,
36
- visualIndex: n,
37
- isFirst: n === 0,
38
- isLast: n === e - 1,
39
- orientation: i.orientation,
40
- side: C.value[o] ?? "start"
41
- };
42
- }, T = (t) => t.time instanceof Date ? t.time.toLocaleDateString() : t.time, I = (t) => f("item-click", t.detail), $ = (t) => {
43
- const o = t.detail, e = i.items;
44
- if (e && e.length) {
45
- const n = c.value?.selectedIds ?? o.selected.map((r, g) => r.id ?? g), E = new Map(e.map((r, g) => [B(r, g), r]));
46
- f(
47
- "update:selection",
48
- n.map((r) => E.get(r)).filter((r) => r !== void 0)
49
- );
50
- } else
51
- f("update:selection", o.selected);
52
- }, h = () => {
53
- c.value && (c.value.items = !y() && i.items ? i.items : []);
54
- }, k = () => {
55
- !c.value || i.selectable === "none" || (c.value.selectedIds = (i.selection ?? []).map((t, o) => B(t, o)));
56
- };
57
- return A(() => {
58
- c.value?.addEventListener("item-click", I), c.value?.addEventListener("selection-change", $), h(), k();
59
- }), D(() => {
60
- c.value?.removeEventListener("item-click", I), c.value?.removeEventListener("selection-change", $);
61
- }), b(() => i.items, h), U(h), b(() => i.selection, k, { deep: !0 }), b(() => i.selectable, k), (t, o) => (a(), d("mp-timeline", N({
62
- ref_key: "el",
63
- ref: c,
64
- orientation: s.orientation,
65
- align: s.align,
66
- reverse: s.reverse,
67
- selectable: s.selectable
68
- }, t.$attrs), [
69
- y() ? (a(!0), d(O, { key: 0 }, P(s.items ?? [], (e, n) => (a(), d("mp-timeline-item", {
70
- key: e.id ?? n,
71
- "item-id": e.id ?? void 0,
72
- title: e.title ?? void 0,
73
- description: e.description ?? void 0,
74
- time: T(e) ?? void 0,
75
- icon: e.icon ?? void 0,
76
- color: e.color ?? void 0,
77
- "item-class": e.cssClass ?? void 0,
78
- disabled: !!e.disabled
79
- }, [
80
- l.marker ? (a(), d("span", q, [
81
- m(t.$slots, "marker", {
82
- item: e,
83
- ctx: v(e, n)
84
- })
85
- ])) : u("", !0),
86
- l.title ? (a(), d("span", z, [
87
- m(t.$slots, "title", {
88
- item: e,
89
- ctx: v(e, n)
90
- })
91
- ])) : u("", !0),
92
- l.timestamp ? (a(), d("span", G, [
93
- m(t.$slots, "timestamp", {
94
- item: e,
95
- ctx: v(e, n)
96
- })
97
- ])) : u("", !0),
98
- l.opposite ? (a(), d("span", H, [
99
- m(t.$slots, "opposite", {
100
- item: e,
101
- ctx: v(e, n)
102
- })
103
- ])) : u("", !0),
104
- l.content ? (a(), d("div", J, [
105
- m(t.$slots, "content", {
106
- item: e,
107
- ctx: v(e, n)
108
- })
109
- ])) : u("", !0)
110
- ], 8, j))), 128)) : m(t.$slots, "default", {}, void 0, void 0, 1)
111
- ], 16, V));
112
- }
113
- }), K = ["item-id", "title", "description", "time", "icon", "color", "item-class", "disabled", "selected"], X = /* @__PURE__ */ L({
114
- __name: "BsTimelineItem",
115
- props: {
116
- itemId: {},
117
- title: {},
118
- description: {},
119
- time: {},
120
- icon: {},
121
- color: {},
122
- cssClass: {},
123
- disabled: { type: Boolean },
124
- selected: { type: Boolean }
125
- },
126
- setup(s) {
127
- return (p, i) => (a(), d("mp-timeline-item", {
128
- "item-id": s.itemId ?? void 0,
129
- title: s.title ?? void 0,
130
- description: s.description ?? void 0,
131
- time: s.time ?? void 0,
132
- icon: s.icon ?? void 0,
133
- color: s.color ?? void 0,
134
- "item-class": s.cssClass ?? void 0,
135
- disabled: !!s.disabled,
136
- selected: !!s.selected
137
- }, [
138
- m(p.$slots, "default")
139
- ], 8, K));
140
- }
1
+ import { Fragment as e, computed as t, createCommentVNode as n, createElementBlock as r, defineComponent as i, mergeProps as a, onBeforeUnmount as o, onMounted as s, onUpdated as c, openBlock as l, ref as u, renderList as d, renderSlot as f, useSlots as p, watch as m } from "vue";
2
+ import { MpTimeline as h, MpTimelineItem as g, resolveSides as _ } from "@mintplayer/web-components/timeline";
3
+ //#region libs/mintplayer-vue-bootstrap/timeline/src/BsTimeline.vue?vue&type=script&setup=true&lang.ts
4
+ var v = [
5
+ "orientation",
6
+ "align",
7
+ "reverse",
8
+ "selectable"
9
+ ], y = [
10
+ "item-id",
11
+ "title",
12
+ "description",
13
+ "time",
14
+ "icon",
15
+ "color",
16
+ "item-class",
17
+ "disabled"
18
+ ], b = {
19
+ key: 0,
20
+ slot: "marker"
21
+ }, x = {
22
+ key: 1,
23
+ slot: "title"
24
+ }, S = {
25
+ key: 2,
26
+ slot: "opposite"
27
+ }, C = {
28
+ key: 3,
29
+ slot: "opposite"
30
+ }, w = {
31
+ key: 4,
32
+ slot: "content"
33
+ }, T = /* @__PURE__ */ i({
34
+ inheritAttrs: !1,
35
+ __name: "BsTimeline",
36
+ props: {
37
+ items: {},
38
+ orientation: { default: "vertical" },
39
+ align: { default: "start" },
40
+ reverse: {
41
+ type: Boolean,
42
+ default: !1
43
+ },
44
+ selectable: { default: "none" },
45
+ selection: {}
46
+ },
47
+ emits: ["item-click", "update:selection"],
48
+ setup(i, { emit: h }) {
49
+ let g = i, T = h, E = p(), D = () => !!(E.marker || E.title || E.timestamp || E.opposite || E.content), O = () => D() && !!g.items?.length, k = u(null), A = (e, t) => e.id ?? t, j = t(() => _(g.items?.length ?? 0, g.align, g.reverse)), M = (e, t) => {
50
+ let n = g.items?.length ?? 0, r = g.reverse ? n - 1 - t : t;
51
+ return {
52
+ index: t,
53
+ visualIndex: r,
54
+ isFirst: r === 0,
55
+ isLast: r === n - 1,
56
+ orientation: g.orientation,
57
+ side: j.value[t] ?? "start"
58
+ };
59
+ }, N = (e) => e.time instanceof Date ? e.time.toLocaleDateString() : e.time, P = (e) => T("item-click", e.detail), F = (e) => {
60
+ let t = e.detail, n = g.items;
61
+ if (n && n.length) {
62
+ let e = k.value?.selectedIds ?? t.selected.map((e, t) => e.id ?? t), r = new Map(n.map((e, t) => [A(e, t), e]));
63
+ T("update:selection", e.map((e) => r.get(e)).filter((e) => e !== void 0));
64
+ } else T("update:selection", t.selected);
65
+ }, I = () => {
66
+ k.value && (k.value.items = !O() && g.items ? g.items : []);
67
+ }, L = () => {
68
+ k.value && g.selectable !== "none" && (k.value.selectedIds = (g.selection ?? []).map((e, t) => A(e, t)));
69
+ };
70
+ return s(() => {
71
+ k.value?.addEventListener("item-click", P), k.value?.addEventListener("selection-change", F), I(), L();
72
+ }), o(() => {
73
+ k.value?.removeEventListener("item-click", P), k.value?.removeEventListener("selection-change", F);
74
+ }), m(() => g.items, I), c(I), m(() => g.selection, L, { deep: !0 }), m(() => g.selectable, L), (t, o) => (l(), r("mp-timeline", a({
75
+ ref_key: "el",
76
+ ref: k,
77
+ orientation: i.orientation,
78
+ align: i.align,
79
+ reverse: i.reverse,
80
+ selectable: i.selectable
81
+ }, t.$attrs), [O() ? (l(!0), r(e, { key: 0 }, d(i.items ?? [], (e, i) => (l(), r("mp-timeline-item", {
82
+ key: e.id ?? i,
83
+ "item-id": e.id ?? void 0,
84
+ title: e.title ?? void 0,
85
+ description: e.description ?? void 0,
86
+ time: N(e) ?? void 0,
87
+ icon: e.icon ?? void 0,
88
+ color: e.color ?? void 0,
89
+ "item-class": e.cssClass ?? void 0,
90
+ disabled: !!e.disabled
91
+ }, [
92
+ E.marker ? (l(), r("span", b, [f(t.$slots, "marker", {
93
+ item: e,
94
+ ctx: M(e, i)
95
+ })])) : n("", !0),
96
+ E.title ? (l(), r("span", x, [f(t.$slots, "title", {
97
+ item: e,
98
+ ctx: M(e, i)
99
+ })])) : n("", !0),
100
+ E.timestamp ? (l(), r("span", S, [f(t.$slots, "timestamp", {
101
+ item: e,
102
+ ctx: M(e, i)
103
+ })])) : n("", !0),
104
+ E.opposite ? (l(), r("span", C, [f(t.$slots, "opposite", {
105
+ item: e,
106
+ ctx: M(e, i)
107
+ })])) : n("", !0),
108
+ E.content ? (l(), r("div", w, [f(t.$slots, "content", {
109
+ item: e,
110
+ ctx: M(e, i)
111
+ })])) : n("", !0)
112
+ ], 8, y))), 128)) : f(t.$slots, "default", {}, void 0, void 0, 1)], 16, v));
113
+ }
114
+ }), E = [
115
+ "item-id",
116
+ "title",
117
+ "description",
118
+ "time",
119
+ "icon",
120
+ "color",
121
+ "item-class",
122
+ "disabled",
123
+ "selected"
124
+ ], D = /* @__PURE__ */ i({
125
+ __name: "BsTimelineItem",
126
+ props: {
127
+ itemId: {},
128
+ title: {},
129
+ description: {},
130
+ time: {},
131
+ icon: {},
132
+ color: {},
133
+ cssClass: {},
134
+ disabled: { type: Boolean },
135
+ selected: { type: Boolean }
136
+ },
137
+ setup(e) {
138
+ return (t, n) => (l(), r("mp-timeline-item", {
139
+ "item-id": e.itemId ?? void 0,
140
+ title: e.title ?? void 0,
141
+ description: e.description ?? void 0,
142
+ time: e.time ?? void 0,
143
+ icon: e.icon ?? void 0,
144
+ color: e.color ?? void 0,
145
+ "item-class": e.cssClass ?? void 0,
146
+ disabled: !!e.disabled,
147
+ selected: !!e.selected
148
+ }, [f(t.$slots, "default")], 8, E));
149
+ }
141
150
  });
142
- export {
143
- W as BsTimeline,
144
- X as BsTimelineItem,
145
- _ as MpTimeline,
146
- ee as MpTimelineItem
147
- };
151
+ //#endregion
152
+ export { T as BsTimeline, D as BsTimelineItem, h as MpTimeline, g as MpTimelineItem };