@avakhula/ui 0.1.12 → 0.1.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { openBlock as G, createElementBlock as ne, normalizeStyle as wn, normalizeClass as ve, resolveComponent as fe, createElementVNode as ae, withModifiers as
|
|
1
|
+
import { openBlock as G, createElementBlock as ne, normalizeStyle as wn, normalizeClass as ve, resolveComponent as fe, createElementVNode as ae, withModifiers as et, renderSlot as Ee, createVNode as ge, Transition as wi, withCtx as ye, withDirectives as De, vShow as Ke, createBlock as ke, resolveDynamicComponent as Oi, mergeProps as Tt, Fragment as tt, renderList as Ht, createCommentVNode as he, toDisplayString as $e, resolveDirective as On, createSlots as Ao, Teleport as ha, createTextVNode as Ge, createApp as pa, vModelDynamic as No, withKeys as $t, vModelCheckbox as ga, pushScopeId as wr, popScopeId as Or, vModelText as Io, defineComponent as ma, onMounted as va, onBeforeUnmount as ya, ref as jr, watch as er, nextTick as qr, h as ba, createStaticVNode as _a } from "vue";
|
|
2
2
|
const Ae = (t, n) => {
|
|
3
3
|
const e = t.__vccOpts || t;
|
|
4
4
|
for (const [r, o] of n)
|
|
@@ -35,7 +35,7 @@ function Oa(t, n, e, r, o, i) {
|
|
|
35
35
|
ref: "icon"
|
|
36
36
|
}, null, 14, wa);
|
|
37
37
|
}
|
|
38
|
-
const
|
|
38
|
+
const Xe = /* @__PURE__ */ Ae($a, [["render", Oa]]);
|
|
39
39
|
function At() {
|
|
40
40
|
return "_" + Math.random().toString(36).substr(2, 9);
|
|
41
41
|
}
|
|
@@ -86,7 +86,7 @@ const ka = {
|
|
|
86
86
|
}
|
|
87
87
|
},
|
|
88
88
|
components: {
|
|
89
|
-
IbIcon:
|
|
89
|
+
IbIcon: Xe
|
|
90
90
|
}
|
|
91
91
|
}, Ca = ["id", "aria-controls", "aria-expanded"], Ea = ["id", "aria-labelledby"], Ta = { class: "accordion-content-wrapper" };
|
|
92
92
|
function Sa(t, n, e, r, o, i) {
|
|
@@ -100,7 +100,7 @@ function Sa(t, n, e, r, o, i) {
|
|
|
100
100
|
"aria-controls": "accordion-section-" + o.uuid,
|
|
101
101
|
"aria-expanded": o.isActive,
|
|
102
102
|
type: "button",
|
|
103
|
-
onClick: n[0] || (n[0] =
|
|
103
|
+
onClick: n[0] || (n[0] = et((...s) => i.onClick && i.onClick(...s), ["prevent"]))
|
|
104
104
|
}, [
|
|
105
105
|
Ee(t.$slots, "title", {}, void 0, !0),
|
|
106
106
|
ge(l, {
|
|
@@ -538,7 +538,7 @@ const Ua = {
|
|
|
538
538
|
(t = this.contentObserver) == null || t.disconnect(), window.removeEventListener("resize", () => this.checkHeight());
|
|
539
539
|
},
|
|
540
540
|
components: {
|
|
541
|
-
IbIcon:
|
|
541
|
+
IbIcon: Xe,
|
|
542
542
|
IbIconButton: It
|
|
543
543
|
}
|
|
544
544
|
}, za = {
|
|
@@ -629,7 +629,7 @@ const Xa = {
|
|
|
629
629
|
}
|
|
630
630
|
},
|
|
631
631
|
components: {
|
|
632
|
-
IbIcon:
|
|
632
|
+
IbIcon: Xe
|
|
633
633
|
}
|
|
634
634
|
}, Qa = ["src", "alt"];
|
|
635
635
|
function el(t, n, e, r, o, i) {
|
|
@@ -729,7 +729,7 @@ const al = {
|
|
|
729
729
|
}
|
|
730
730
|
}
|
|
731
731
|
},
|
|
732
|
-
components: { IbIcon:
|
|
732
|
+
components: { IbIcon: Xe }
|
|
733
733
|
};
|
|
734
734
|
function ll(t, n, e, r, o, i) {
|
|
735
735
|
const l = fe("ib-icon");
|
|
@@ -805,7 +805,7 @@ const ul = {
|
|
|
805
805
|
},
|
|
806
806
|
components: {
|
|
807
807
|
IbIconButton: It,
|
|
808
|
-
IbIcon:
|
|
808
|
+
IbIcon: Xe
|
|
809
809
|
}
|
|
810
810
|
}, dl = { class: "ib-toggle-tip-head" }, cl = { class: "ib-toggle-tip-content" }, fl = { class: "ib-toggle-tip-button-set" };
|
|
811
811
|
function hl(t, n, e, r, o, i) {
|
|
@@ -820,7 +820,7 @@ function hl(t, n, e, r, o, i) {
|
|
|
820
820
|
ge(s, {
|
|
821
821
|
class: "close-button",
|
|
822
822
|
kind: "ghost",
|
|
823
|
-
onClick:
|
|
823
|
+
onClick: et(i.close, ["prevent"])
|
|
824
824
|
}, {
|
|
825
825
|
default: ye(() => [
|
|
826
826
|
ge(l, { name: "close-outline" })
|
|
@@ -998,7 +998,7 @@ function Sl(t, n, e, r, o, i) {
|
|
|
998
998
|
class: ve(["dropdown-trigger", i.triggerClasses]),
|
|
999
999
|
ref: "dropdown",
|
|
1000
1000
|
onKeydown: n[0] || (n[0] = (...s) => i.onKeydown && i.onKeydown(...s)),
|
|
1001
|
-
onClick: n[1] || (n[1] =
|
|
1001
|
+
onClick: n[1] || (n[1] = et((...s) => i.toggle && i.toggle(...s), ["prevent", "stop"]))
|
|
1002
1002
|
}, [
|
|
1003
1003
|
Ee(t.$slots, "trigger", { isOpened: o.isOpenedState }, void 0, !0)
|
|
1004
1004
|
], 34)) : he("", !0),
|
|
@@ -1264,7 +1264,7 @@ const Bl = {
|
|
|
1264
1264
|
};
|
|
1265
1265
|
},
|
|
1266
1266
|
components: {
|
|
1267
|
-
IbIcon:
|
|
1267
|
+
IbIcon: Xe,
|
|
1268
1268
|
IbDropdownList: Sr
|
|
1269
1269
|
},
|
|
1270
1270
|
methods: {
|
|
@@ -1459,7 +1459,7 @@ const Kl = {
|
|
|
1459
1459
|
},
|
|
1460
1460
|
components: {
|
|
1461
1461
|
IbIconButton: It,
|
|
1462
|
-
IbIcon:
|
|
1462
|
+
IbIcon: Xe
|
|
1463
1463
|
},
|
|
1464
1464
|
beforeUnmount() {
|
|
1465
1465
|
this.isActive && this.close(), document.removeEventListener("keydown", this.onKeydown), document.removeEventListener("blur", this.setFocusOnModal, !0);
|
|
@@ -1567,7 +1567,7 @@ const Zl = {
|
|
|
1567
1567
|
components: {
|
|
1568
1568
|
IbDropdownList: Sr,
|
|
1569
1569
|
IbDropdownItem: Ro,
|
|
1570
|
-
IbIcon:
|
|
1570
|
+
IbIcon: Xe
|
|
1571
1571
|
}
|
|
1572
1572
|
}, Jl = { class: "wrapper-tab-link dropdown-tab" }, Xl = ["tabindex"];
|
|
1573
1573
|
function Ql(t, n, e, r, o, i) {
|
|
@@ -1989,7 +1989,7 @@ const ps = {
|
|
|
1989
1989
|
},
|
|
1990
1990
|
directives: { Tooltip: qo },
|
|
1991
1991
|
components: {
|
|
1992
|
-
IbIcon:
|
|
1992
|
+
IbIcon: Xe,
|
|
1993
1993
|
IbIconButton: It,
|
|
1994
1994
|
IbToggleTip: pl
|
|
1995
1995
|
}
|
|
@@ -2091,7 +2091,7 @@ const bs = {
|
|
|
2091
2091
|
}
|
|
2092
2092
|
},
|
|
2093
2093
|
components: {
|
|
2094
|
-
IbIcon:
|
|
2094
|
+
IbIcon: Xe,
|
|
2095
2095
|
IbIconButton: It,
|
|
2096
2096
|
IbDropdownItem: Ro,
|
|
2097
2097
|
IbDropdownList: Sr,
|
|
@@ -2187,7 +2187,7 @@ const Es = {
|
|
|
2187
2187
|
},
|
|
2188
2188
|
components: {
|
|
2189
2189
|
IbIconButton: It,
|
|
2190
|
-
IbIcon:
|
|
2190
|
+
IbIcon: Xe,
|
|
2191
2191
|
IbTooltip: kn
|
|
2192
2192
|
}
|
|
2193
2193
|
}, Ts = ["for"], Ss = {
|
|
@@ -2374,7 +2374,7 @@ const As = {
|
|
|
2374
2374
|
components: {
|
|
2375
2375
|
IbAlert: cn,
|
|
2376
2376
|
IbIconButton: It,
|
|
2377
|
-
IbIcon:
|
|
2377
|
+
IbIcon: Xe,
|
|
2378
2378
|
IbDropdown: Er
|
|
2379
2379
|
},
|
|
2380
2380
|
inheritAttrs: !1
|
|
@@ -2437,7 +2437,7 @@ function Ps(t, n, e, r, o, i) {
|
|
|
2437
2437
|
type: "button",
|
|
2438
2438
|
disabled: e.readonly || e.disabled,
|
|
2439
2439
|
"help-text": o.showPassword ? e.hidePasswordMessage : e.showPasswordMessage,
|
|
2440
|
-
onClick:
|
|
2440
|
+
onClick: et(i.toggleShowPassword, ["prevent"])
|
|
2441
2441
|
}, {
|
|
2442
2442
|
default: ye(() => [
|
|
2443
2443
|
ge(s, {
|
|
@@ -2541,8 +2541,12 @@ const Ms = {
|
|
|
2541
2541
|
};
|
|
2542
2542
|
},
|
|
2543
2543
|
methods: {
|
|
2544
|
-
onChange() {
|
|
2545
|
-
|
|
2544
|
+
onChange(t) {
|
|
2545
|
+
if (this.readonly) {
|
|
2546
|
+
t.preventDefault();
|
|
2547
|
+
return;
|
|
2548
|
+
}
|
|
2549
|
+
this.checked = !this.checked, this.$emit("update:modelValue", this.checked), this.$emit("input", this.checked);
|
|
2546
2550
|
}
|
|
2547
2551
|
},
|
|
2548
2552
|
computed: {
|
|
@@ -2565,7 +2569,7 @@ const Ms = {
|
|
|
2565
2569
|
}
|
|
2566
2570
|
},
|
|
2567
2571
|
components: {
|
|
2568
|
-
IbIcon:
|
|
2572
|
+
IbIcon: Xe
|
|
2569
2573
|
},
|
|
2570
2574
|
inheritAttrs: !1
|
|
2571
2575
|
}, Ds = ["aria-checked"], Ls = ["for", "tabindex"], Rs = ["name", "id", "value", "disabled", "required"], Bs = { class: "ib-checkbox-body" }, js = {
|
|
@@ -2589,7 +2593,7 @@ function Vs(t, n, e, r, o, i) {
|
|
|
2589
2593
|
ae("label", Tt(i.attrs, {
|
|
2590
2594
|
for: e.id,
|
|
2591
2595
|
tabindex: e.disabled | e.disableFocus ? -1 : 0,
|
|
2592
|
-
onKeypress: n[2] || (n[2] =
|
|
2596
|
+
onKeypress: n[2] || (n[2] = et((...d) => i.onChange && i.onChange(...d), ["prevent"]))
|
|
2593
2597
|
}), [
|
|
2594
2598
|
De(ae("input", {
|
|
2595
2599
|
tabindex: "-1",
|
|
@@ -2600,7 +2604,7 @@ function Vs(t, n, e, r, o, i) {
|
|
|
2600
2604
|
disabled: e.disabled,
|
|
2601
2605
|
required: e.required,
|
|
2602
2606
|
"onUpdate:modelValue": n[0] || (n[0] = (d) => o.checked = d),
|
|
2603
|
-
onClick: n[1] || (n[1] =
|
|
2607
|
+
onClick: n[1] || (n[1] = (...d) => i.onChange && i.onChange(...d))
|
|
2604
2608
|
}, null, 8, Rs), [
|
|
2605
2609
|
[ga, o.checked]
|
|
2606
2610
|
]),
|
|
@@ -2702,7 +2706,7 @@ const Us = {
|
|
|
2702
2706
|
};
|
|
2703
2707
|
}
|
|
2704
2708
|
},
|
|
2705
|
-
components: { IbIcon:
|
|
2709
|
+
components: { IbIcon: Xe, IbTooltip: kn }
|
|
2706
2710
|
}, zs = ["aria-checked", "tabindex"], Ks = {
|
|
2707
2711
|
class: "toggle-wrapper",
|
|
2708
2712
|
ref: "wrapper"
|
|
@@ -2721,8 +2725,8 @@ function Js(t, n, e, r, o, i) {
|
|
|
2721
2725
|
tabindex: e.disabled ? -1 : 0,
|
|
2722
2726
|
class: ve(i.classes),
|
|
2723
2727
|
onKeypress: [
|
|
2724
|
-
n[2] || (n[2] = $t(
|
|
2725
|
-
n[3] || (n[3] = $t(
|
|
2728
|
+
n[2] || (n[2] = $t(et((...d) => i.onChange && i.onChange(...d), ["prevent"]), ["space"])),
|
|
2729
|
+
n[3] || (n[3] = $t(et((...d) => i.onChange && i.onChange(...d), ["prevent"]), ["enter"]))
|
|
2726
2730
|
]
|
|
2727
2731
|
}, [
|
|
2728
2732
|
ae("div", Ks, [
|
|
@@ -2736,7 +2740,7 @@ function Js(t, n, e, r, o, i) {
|
|
|
2736
2740
|
id: e.id,
|
|
2737
2741
|
disabled: e.disabled,
|
|
2738
2742
|
onClick: n[0] || (n[0] = (...d) => i.onChange && i.onChange(...d)),
|
|
2739
|
-
onInput: n[1] || (n[1] =
|
|
2743
|
+
onInput: n[1] || (n[1] = et(() => {
|
|
2740
2744
|
}, ["stop"]))
|
|
2741
2745
|
}, null, 40, Ys),
|
|
2742
2746
|
Ws,
|
|
@@ -2895,7 +2899,7 @@ const Qs = {
|
|
|
2895
2899
|
}
|
|
2896
2900
|
},
|
|
2897
2901
|
components: {
|
|
2898
|
-
IbIcon:
|
|
2902
|
+
IbIcon: Xe,
|
|
2899
2903
|
List: Tr,
|
|
2900
2904
|
IbIconButton: It
|
|
2901
2905
|
},
|
|
@@ -2927,7 +2931,7 @@ function au(t, n, e, r, o, i) {
|
|
|
2927
2931
|
"aria-selected": i.isChecked(e.option),
|
|
2928
2932
|
"aria-label": e.option.title,
|
|
2929
2933
|
id: "option-" + i.id,
|
|
2930
|
-
onKeydown: n[3] || (n[3] =
|
|
2934
|
+
onKeydown: n[3] || (n[3] = et((...c) => i.onKeydown && i.onKeydown(...c), ["self"])),
|
|
2931
2935
|
onFocus: n[4] || (n[4] = (c) => t.$emit("onFocus", `option-${i.id}`))
|
|
2932
2936
|
}, [
|
|
2933
2937
|
De(ge(s, {
|
|
@@ -2944,7 +2948,7 @@ function au(t, n, e, r, o, i) {
|
|
|
2944
2948
|
[Ke, i.hasVisibleChildren]
|
|
2945
2949
|
]),
|
|
2946
2950
|
ae("div", {
|
|
2947
|
-
onClick: n[1] || (n[1] =
|
|
2951
|
+
onClick: n[1] || (n[1] = et((...c) => i.onChange && i.onChange(...c), ["prevent"])),
|
|
2948
2952
|
class: ve({
|
|
2949
2953
|
disabled: e.option.isDisabled,
|
|
2950
2954
|
"tree-select-option-label": !0,
|
|
@@ -2981,7 +2985,7 @@ function au(t, n, e, r, o, i) {
|
|
|
2981
2985
|
Ge($e(e.option.title) + " ", 1),
|
|
2982
2986
|
ge(l, {
|
|
2983
2987
|
name: "star",
|
|
2984
|
-
onClick: n[0] || (n[0] =
|
|
2988
|
+
onClick: n[0] || (n[0] = et((c) => t.$emit("toggle-bookmark", e.option), ["stop", "prevent"]))
|
|
2985
2989
|
})
|
|
2986
2990
|
]))
|
|
2987
2991
|
], 2)) : e.htmlTitle ? (G(), ne(tt, { key: 1 }, [
|
|
@@ -3558,10 +3562,10 @@ const du = {
|
|
|
3558
3562
|
type: Boolean,
|
|
3559
3563
|
default: !1
|
|
3560
3564
|
},
|
|
3561
|
-
|
|
3562
|
-
|
|
3563
|
-
|
|
3564
|
-
|
|
3565
|
+
vertical: {
|
|
3566
|
+
type: String
|
|
3567
|
+
// default: "bottom"
|
|
3568
|
+
},
|
|
3565
3569
|
emptyMessage: {
|
|
3566
3570
|
type: String,
|
|
3567
3571
|
default: ""
|
|
@@ -3677,7 +3681,7 @@ const du = {
|
|
|
3677
3681
|
actualBookmarkedOptions: {},
|
|
3678
3682
|
selected: [],
|
|
3679
3683
|
isOpen: !1,
|
|
3680
|
-
|
|
3684
|
+
verticalVal: this.vertical ?? "bottom",
|
|
3681
3685
|
allOptionsIsChecked: !0,
|
|
3682
3686
|
hasTreeChildren: !1,
|
|
3683
3687
|
uid: `f${(~~(Math.random() * 1e8)).toString(16)}`,
|
|
@@ -3879,12 +3883,12 @@ const du = {
|
|
|
3879
3883
|
}), this.filter(this.filterString, t);
|
|
3880
3884
|
},
|
|
3881
3885
|
onClose() {
|
|
3882
|
-
this.isOpen = !1, this.filter("", this.actualOptions), this.isMultiple ? this.$emit("close", Object.keys(this.selected)) : this.$emit("close", Object.keys(this.selected)[0]), this.$emit("blur"), this.
|
|
3886
|
+
this.isOpen = !1, this.filter("", this.actualOptions), this.isMultiple ? this.$emit("close", Object.keys(this.selected)) : this.$emit("close", Object.keys(this.selected)[0]), this.$emit("blur"), this.verticalVal = this.vertical ?? "bottom";
|
|
3883
3887
|
},
|
|
3884
3888
|
onOpen() {
|
|
3885
3889
|
const t = document.documentElement.scrollHeight;
|
|
3886
|
-
this.isOpen = !0, this.$nextTick(() => {
|
|
3887
|
-
document.documentElement.scrollHeight > t && (this.
|
|
3890
|
+
this.isOpen = !0, this.vertical !== "bottom" && this.$nextTick(() => {
|
|
3891
|
+
document.documentElement.scrollHeight > t && (this.verticalVal = "top");
|
|
3888
3892
|
});
|
|
3889
3893
|
}
|
|
3890
3894
|
},
|
|
@@ -3950,7 +3954,7 @@ const du = {
|
|
|
3950
3954
|
components: {
|
|
3951
3955
|
IbAlert: cn,
|
|
3952
3956
|
IbIconButton: It,
|
|
3953
|
-
IbIcon:
|
|
3957
|
+
IbIcon: Xe,
|
|
3954
3958
|
IbDropdown: Er,
|
|
3955
3959
|
IbInput: Fo,
|
|
3956
3960
|
List: Tr,
|
|
@@ -3987,7 +3991,7 @@ function hu(t, n, e, r, o, i) {
|
|
|
3987
3991
|
ge(a, {
|
|
3988
3992
|
disabled: o.isLoading,
|
|
3989
3993
|
"is-resizable": e.isResizable,
|
|
3990
|
-
vertical: o.
|
|
3994
|
+
vertical: o.verticalVal,
|
|
3991
3995
|
ref: "dropdown",
|
|
3992
3996
|
onClose: i.onClose,
|
|
3993
3997
|
onOpen: i.onOpen
|
|
@@ -4147,7 +4151,7 @@ function hu(t, n, e, r, o, i) {
|
|
|
4147
4151
|
"tree-choice-error": e.errorMessage
|
|
4148
4152
|
}]),
|
|
4149
4153
|
ref: "combobox",
|
|
4150
|
-
onClick: n[2] || (n[2] =
|
|
4154
|
+
onClick: n[2] || (n[2] = et(() => {
|
|
4151
4155
|
}, ["prevent"])),
|
|
4152
4156
|
onBlur: n[3] || (n[3] = (...b) => i.onBlur && i.onBlur(...b)),
|
|
4153
4157
|
onKeyup: [
|
|
@@ -4174,12 +4178,12 @@ function hu(t, n, e, r, o, i) {
|
|
|
4174
4178
|
key: 2,
|
|
4175
4179
|
kind: "ghost",
|
|
4176
4180
|
class: "button-clear",
|
|
4177
|
-
onClick:
|
|
4178
|
-
onKeypress: n[0] || (n[0] = $t(
|
|
4181
|
+
onClick: et(i.clearValue, ["prevent"]),
|
|
4182
|
+
onKeypress: n[0] || (n[0] = $t(et(() => {
|
|
4179
4183
|
}, ["stop", "prevent"]), ["enter"])),
|
|
4180
|
-
onKeydown: n[1] || (n[1] = $t(
|
|
4184
|
+
onKeydown: n[1] || (n[1] = $t(et(() => {
|
|
4181
4185
|
}, ["stop", "prevent"]), ["enter"])),
|
|
4182
|
-
onKeyup: $t(
|
|
4186
|
+
onKeyup: $t(et(i.clearValue, ["prevent"]), ["enter"]),
|
|
4183
4187
|
"help-text": e.clearButtonMessage
|
|
4184
4188
|
}, {
|
|
4185
4189
|
default: ye(() => [
|
|
@@ -4361,7 +4365,7 @@ const bu = {
|
|
|
4361
4365
|
},
|
|
4362
4366
|
components: {
|
|
4363
4367
|
IbIconButton: It,
|
|
4364
|
-
IbIcon:
|
|
4368
|
+
IbIcon: Xe,
|
|
4365
4369
|
IbInput: Fo,
|
|
4366
4370
|
IbLabel: Ci,
|
|
4367
4371
|
IbLimitSelector: yu,
|
|
@@ -4475,7 +4479,7 @@ const Tu = {
|
|
|
4475
4479
|
}
|
|
4476
4480
|
},
|
|
4477
4481
|
components: {
|
|
4478
|
-
IbIcon:
|
|
4482
|
+
IbIcon: Xe
|
|
4479
4483
|
}
|
|
4480
4484
|
}, zo = (t) => (wr("data-v-a0217859"), t = t(), Or(), t), Su = { class: "ib-progress-bar-wrapper" }, xu = ["aria-label", "aria-valuenow"], Au = /* @__PURE__ */ zo(() => /* @__PURE__ */ ae("div", { class: "gradient" }, null, -1)), Nu = [
|
|
4481
4485
|
Au
|
|
@@ -4773,7 +4777,7 @@ function od(t, n, e, r, o, i) {
|
|
|
4773
4777
|
class: ve(i.classes),
|
|
4774
4778
|
for: e.id,
|
|
4775
4779
|
"aria-checked": o.checked,
|
|
4776
|
-
onClick: n[2] || (n[2] =
|
|
4780
|
+
onClick: n[2] || (n[2] = et((...d) => i.onClick && i.onClick(...d), ["prevent"]))
|
|
4777
4781
|
}, [
|
|
4778
4782
|
ae("input", {
|
|
4779
4783
|
type: "radio",
|
|
@@ -4783,7 +4787,7 @@ function od(t, n, e, r, o, i) {
|
|
|
4783
4787
|
checked: o.checked,
|
|
4784
4788
|
disabled: e.disabled,
|
|
4785
4789
|
ref: "radio",
|
|
4786
|
-
onInput: n[0] || (n[0] =
|
|
4790
|
+
onInput: n[0] || (n[0] = et(() => {
|
|
4787
4791
|
}, ["stop"])),
|
|
4788
4792
|
onChange: n[1] || (n[1] = (...d) => i.onChange && i.onChange(...d))
|
|
4789
4793
|
}, null, 40, nd),
|
|
@@ -6564,7 +6568,7 @@ const Ed = "single", lr = "range", Td = {
|
|
|
6564
6568
|
document.removeEventListener("keyup", this.onDocumentKeyDown);
|
|
6565
6569
|
},
|
|
6566
6570
|
components: {
|
|
6567
|
-
IbIcon:
|
|
6571
|
+
IbIcon: Xe,
|
|
6568
6572
|
IbLabel: Ci,
|
|
6569
6573
|
IbAlert: cn
|
|
6570
6574
|
}
|
|
@@ -10316,7 +10320,7 @@ function oh(t, n, e, r, o, i) {
|
|
|
10316
10320
|
placeholder: i.sortedCountries.length ? i.sortedCountries[0].name : "",
|
|
10317
10321
|
type: "text",
|
|
10318
10322
|
"onUpdate:modelValue": n[0] || (n[0] = (s) => o.searchQuery = s),
|
|
10319
|
-
onClick: n[1] || (n[1] =
|
|
10323
|
+
onClick: n[1] || (n[1] = et(() => {
|
|
10320
10324
|
}, ["stop"]))
|
|
10321
10325
|
}, null, 8, th)), [
|
|
10322
10326
|
[Io, o.searchQuery]
|
|
@@ -10403,7 +10407,7 @@ const lh = {
|
|
|
10403
10407
|
components: {
|
|
10404
10408
|
VueTelInput: ah,
|
|
10405
10409
|
IbAlert: cn,
|
|
10406
|
-
IbIcon:
|
|
10410
|
+
IbIcon: Xe
|
|
10407
10411
|
},
|
|
10408
10412
|
data() {
|
|
10409
10413
|
return {
|
|
@@ -18344,9 +18348,9 @@ _i.exports;
|
|
|
18344
18348
|
if (bt)
|
|
18345
18349
|
return bt;
|
|
18346
18350
|
if (Re.set(_, je), !Ze)
|
|
18347
|
-
var
|
|
18348
|
-
return J(
|
|
18349
|
-
|
|
18351
|
+
var Qe = F ? zi(_) : Bn(_);
|
|
18352
|
+
return J(Qe || _, function(ct, at) {
|
|
18353
|
+
Qe && (at = ct, ct = _[at]), Zn(je, at, Pn(ct, N, F, ee, at, _, Re));
|
|
18350
18354
|
}), je;
|
|
18351
18355
|
}
|
|
18352
18356
|
function Di(_) {
|
|
@@ -18790,13 +18794,13 @@ $i.exports;
|
|
|
18790
18794
|
function qi(_, N, F, ee, Ne, be) {
|
|
18791
18795
|
var Re = mn(_), je = mn(N), Ze = Re ? d : Bt(_), Ve = je ? d : Bt(N);
|
|
18792
18796
|
Ze = Ze == s ? m : Ze, Ve = Ve == s ? m : Ve;
|
|
18793
|
-
var dt = Ze == m, bt = Ve == m,
|
|
18794
|
-
if (
|
|
18797
|
+
var dt = Ze == m, bt = Ve == m, Qe = Ze == Ve;
|
|
18798
|
+
if (Qe && vn(_)) {
|
|
18795
18799
|
if (!vn(N))
|
|
18796
18800
|
return !1;
|
|
18797
18801
|
Re = !0, dt = !1;
|
|
18798
18802
|
}
|
|
18799
|
-
if (
|
|
18803
|
+
if (Qe && !dt)
|
|
18800
18804
|
return be || (be = new Rt()), Re || ri(_) ? Dn(_, N, F, ee, Ne, be) : Ui(_, N, Ze, F, ee, Ne, be);
|
|
18801
18805
|
if (!(F & o)) {
|
|
18802
18806
|
var ct = dt && Le.call(_, "__wrapped__"), at = bt && Le.call(N, "__wrapped__");
|
|
@@ -18805,7 +18809,7 @@ $i.exports;
|
|
|
18805
18809
|
return be || (be = new Rt()), Ne(Qt, Yt, F, ee, be);
|
|
18806
18810
|
}
|
|
18807
18811
|
}
|
|
18808
|
-
return
|
|
18812
|
+
return Qe ? (be || (be = new Rt()), zi(_, N, F, ee, Ne, be)) : !1;
|
|
18809
18813
|
}
|
|
18810
18814
|
function Fi(_) {
|
|
18811
18815
|
if (!ii(_) || Wi(_))
|
|
@@ -18831,7 +18835,7 @@ $i.exports;
|
|
|
18831
18835
|
var Ve = be.get(_);
|
|
18832
18836
|
if (Ve && be.get(N))
|
|
18833
18837
|
return Ve == N;
|
|
18834
|
-
var dt = -1, bt = !0,
|
|
18838
|
+
var dt = -1, bt = !0, Qe = F & i ? new hn() : void 0;
|
|
18835
18839
|
for (be.set(_, N), be.set(N, _); ++dt < je; ) {
|
|
18836
18840
|
var ct = _[dt], at = N[dt];
|
|
18837
18841
|
if (ee)
|
|
@@ -18842,10 +18846,10 @@ $i.exports;
|
|
|
18842
18846
|
bt = !1;
|
|
18843
18847
|
break;
|
|
18844
18848
|
}
|
|
18845
|
-
if (
|
|
18849
|
+
if (Qe) {
|
|
18846
18850
|
if (!ze(N, function(Yt, ln) {
|
|
18847
|
-
if (!se(
|
|
18848
|
-
return
|
|
18851
|
+
if (!se(Qe, ln) && (ct === Yt || Ne(ct, Yt, F, ee, be)))
|
|
18852
|
+
return Qe.push(ln);
|
|
18849
18853
|
})) {
|
|
18850
18854
|
bt = !1;
|
|
18851
18855
|
break;
|
|
@@ -18897,8 +18901,8 @@ $i.exports;
|
|
|
18897
18901
|
if (Ze != dt && !Re)
|
|
18898
18902
|
return !1;
|
|
18899
18903
|
for (var bt = Ze; bt--; ) {
|
|
18900
|
-
var
|
|
18901
|
-
if (!(Re ?
|
|
18904
|
+
var Qe = je[bt];
|
|
18905
|
+
if (!(Re ? Qe in N : Le.call(N, Qe)))
|
|
18902
18906
|
return !1;
|
|
18903
18907
|
}
|
|
18904
18908
|
var ct = be.get(_);
|
|
@@ -18907,15 +18911,15 @@ $i.exports;
|
|
|
18907
18911
|
var at = !0;
|
|
18908
18912
|
be.set(_, N), be.set(N, _);
|
|
18909
18913
|
for (var Qt = Re; ++bt < Ze; ) {
|
|
18910
|
-
|
|
18911
|
-
var Yt = _[
|
|
18914
|
+
Qe = je[bt];
|
|
18915
|
+
var Yt = _[Qe], ln = N[Qe];
|
|
18912
18916
|
if (ee)
|
|
18913
|
-
var Br = Re ? ee(ln, Yt,
|
|
18917
|
+
var Br = Re ? ee(ln, Yt, Qe, N, _, be) : ee(Yt, ln, Qe, _, N, be);
|
|
18914
18918
|
if (!(Br === void 0 ? Yt === ln || Ne(Yt, ln, F, ee, be) : Br)) {
|
|
18915
18919
|
at = !1;
|
|
18916
18920
|
break;
|
|
18917
18921
|
}
|
|
18918
|
-
Qt || (Qt =
|
|
18922
|
+
Qt || (Qt = Qe == "constructor");
|
|
18919
18923
|
}
|
|
18920
18924
|
if (at && !Qt) {
|
|
18921
18925
|
var oi = _.constructor, ai = N.constructor;
|
|
@@ -20081,7 +20085,7 @@ export {
|
|
|
20081
20085
|
Ro as IbDropdownItem,
|
|
20082
20086
|
Sr as IbDropdownList,
|
|
20083
20087
|
E1 as IbFormGroup,
|
|
20084
|
-
|
|
20088
|
+
Xe as IbIcon,
|
|
20085
20089
|
It as IbIconButton,
|
|
20086
20090
|
Fo as IbInput,
|
|
20087
20091
|
Ci as IbLabel,
|
package/dist/index.umd.cjs
CHANGED
|
@@ -18,12 +18,12 @@
|
|
|
18
18
|
top: ${a-h-u/2+f+12}px!important`;break;case"rightCenter":l=l+`left: ${s+5}px!important;
|
|
19
19
|
top: ${a+f-h/2-u/2}px!important;`;break;case"rightBottom":l=l+`left: ${s+5}px!important;
|
|
20
20
|
top: ${a+f-u/2-12}px!important`;break;default:l=l+`left: ${r+d/2-p/2}px!important;
|
|
21
|
-
top: ${o-h+f-5}px!important`;break}return l}getClassList(n){return n?hr[n]:hr.topCenter}}const Vt=new xi,ql=(t,n)=>{var a;Vt.getTooltipContainer()&&Vt.destroyTooltip();const e=Object.keys(n.modifiers)[0]||n.arg,o={title:((a=n.value)==null?void 0:a.title)||"",text:typeof n.value=="object"?n.value.text:n.value};Vt.createTooltip(t,o,e)},Fl=(t,n)=>{const e=Vt.getId();if(n.getAttribute("aria-describedby")!==e)return;const o=Vt.getTooltipContainer(),a=n!==t.target&&!n.contains(t.target),r=o!==t.target&&!(o!=null&&o.contains(t.target));a&&r&&Vt.destroyTooltip(n)},Ai=(t,n)=>{t.__tooltip_create=()=>ql(t,n),t.__tooltip_destroy=e=>Fl(e,t),t.addEventListener("mouseenter",t.__tooltip_create),document.addEventListener("mousemove",t.__tooltip_destroy)},Di=t=>{Vt.destroyTooltip(t),t.removeEventListener("mouseenter",t.__tooltip_create),document.removeEventListener("mousemove",t.__tooltip_destroy)},yr={mounted(t,n){Ai(t,n)},updated(t,n){Di(t),Ai(t,n)},beforeUnmount(t){Di(t)}},$1="",Hl={name:"IbSorting",props:{tooltipTitle:{type:String,default:""},hideSortingButton:{type:Boolean,default:!1},tooltipText:{type:String},tooltipPosition:{type:String},tooltipIconPosition:{type:String},tooltipIconSorting:{type:String},toggleTipTitle:{type:String},title:{type:String,default:""},sort:{type:String,default:null},view:{type:String,required:!0},disable:{type:Boolean,default:!1},tableName:{type:String,required:!0}},mounted(){this.$globalEvents.$on(`sorting:update:${this.tableName}`,t=>{this.$el.contains(t.$el)||(this.currentTypeSort=null)})},data(){return{isOpenToggleTip:!1,sortingTypes:Vl,sortingTypesView:jl,currentTypeSort:this.sort}},methods:{clickHandler(){this.currentTypeSort?this.currentTypeSort===this.sortingTypes.TYPE_ASC?this.currentTypeSort=this.sortingTypes.TYPE_DESC:this.currentTypeSort=null:this.currentTypeSort=this.sortingTypes.TYPE_ASC,this.updateTypeSorting()},updateTypeSorting(){this.$globalEvents.$emit(`sorting:update:${this.tableName}`,this),this.$emit("update-sorting",this.currentTypeSort)}},computed:{iconType(){return this.currentTypeSort===this.sortingTypes.TYPE_ASC?"arrow-up":this.currentTypeSort===this.sortingTypes.TYPE_DESC?"arrow-down":this.view!==this.sortingTypesView.GRID_VIEW?"swap-vertical":null},sortingTooltipPosition(){return this.hasToggleTip?"bottomCenter":this.tooltipPosition},sortingTooltipContent(){var t;return this.hasToggleTip?lang("click_to_view_details",(t=this.langComponents)==null?void 0:t.COMPONENT_SYSTEM):this.tooltipContent},tooltipIconText(){var t,n,e;return this.currentTypeSort===this.sortingTypes.TYPE_ASC?lang("sort_descending",(t=this.langComponents)==null?void 0:t.COMPONENT_SELECT):this.currentTypeSort===this.sortingTypes.TYPE_DESC?lang("reset_sorting",(n=this.langComponents)==null?void 0:n.COMPONENT_SELECT):this.view!==this.sortingTypesView.GRID_VIEW?lang("sort_ascending",(e=this.langComponents)==null?void 0:e.COMPONENT_SELECT):""},tooltipContent(){return this.tooltipTitle.length?{title:this.tooltipTitle,text:this.tooltipText}:this.tooltipText},hasToggleTip(){return this.toggleTipTitle&&this.$slots.toggleTipBody&&this.$slots.toggleTipButtons}},directives:{Tooltip:yr},components:{IbIcon:Le,IbIconButton:ut,IbToggleTip:ki}},zl={class:"sorting-wrapper"},Ul=["name"],Kl=["aria-label"];function Gl(t,n,e,o,a,r){var h;const s=i.resolveComponent("ib-toggle-tip"),d=i.resolveComponent("ib-icon-button"),u=i.resolveComponent("ib-icon"),p=i.resolveDirective("tooltip");return i.openBlock(),i.createElementBlock("div",zl,[e.view===a.sortingTypesView.TABLE_VIEW?(i.openBlock(),i.createElementBlock("div",{key:0,class:i.normalizeClass(["table-sorting-wrapper",{active:a.currentTypeSort,disabled:e.disable}])},[i.createElementVNode("div",null,[i.withDirectives((i.openBlock(),i.createElementBlock("button",{class:i.normalizeClass(["sorting-label",{"sorting-label-active":a.isOpenToggleTip&&r.hasToggleTip,"has-action":((h=e.tooltipText)==null?void 0:h.length)||r.hasToggleTip}]),type:"button",onClick:n[0]||(n[0]=f=>a.isOpenToggleTip=!a.isOpenToggleTip)},[i.createTextVNode(i.toDisplayString(e.title),1)],2)),[[p,r.sortingTooltipContent,r.sortingTooltipPosition]]),r.hasToggleTip?(i.openBlock(),i.createBlock(s,{key:0,position:"bottom-center","is-open":a.isOpenToggleTip,title:e.toggleTipTitle,onClose:n[1]||(n[1]=f=>a.isOpenToggleTip=!1)},{buttons:i.withCtx(()=>[i.renderSlot(t.$slots,"toggleTipButtons",{},void 0,!0)]),default:i.withCtx(()=>[i.renderSlot(t.$slots,"toggleTipBody",{},void 0,!0)]),_:3},8,["is-open","title"])):i.createCommentVNode("",!0)]),e.hideSortingButton?i.createCommentVNode("",!0):i.withDirectives((i.openBlock(),i.createBlock(d,{key:0,kind:"white",size:"s",onClick:r.clickHandler},{default:i.withCtx(()=>[i.createElementVNode("ion-icon",{name:r.iconType},null,8,Ul)]),_:1},8,["onClick"])),[[p,r.tooltipIconText,e.tooltipIconPosition]])],2)):i.withDirectives((i.openBlock(),i.createElementBlock("button",{key:1,class:i.normalizeClass(["sorting-button",{active:a.currentTypeSort,disabled:e.disable}]),type:"button",onClick:n[2]||(n[2]=(...f)=>r.clickHandler&&r.clickHandler(...f)),"aria-label":e.sort},[i.createTextVNode(i.toDisplayString(e.title)+" ",1),r.iconType?(i.openBlock(),i.createBlock(u,{key:0,name:r.iconType},null,8,["name"])):i.createCommentVNode("",!0)],10,Kl)),[[p,e.tooltipText,e.tooltipPosition]])])}const Yl=_e(Hl,[["render",Gl],["__scopeId","data-v-a4394881"]]),w1="",Wl={name:"IbBreadcrumbs",props:{items:{type:Array,default:()=>[]},tooltipTextContext:{type:String}},computed:{last(){return this.items.length?this.items.length-1:null},initContextMenu(){return this.items.length>4},setItemsContextMenu(){return this.items.slice(0,-3)}},components:{IbIcon:Le,IbIconButton:ut,IbDropdownItem:gr,IbDropdownList:Rn,IbTooltip:jt}},Zl={"aria-label":"breadcrumb"},Jl={class:"breadcrumb"},Xl=["href"],Ql={key:1},es=["href"];function ts(t,n,e,o,a,r){const s=i.resolveComponent("ib-icon"),d=i.resolveComponent("ib-tooltip"),u=i.resolveComponent("ib-icon-button"),p=i.resolveComponent("ib-dropdown-item"),h=i.resolveComponent("ib-dropdown-list");return i.openBlock(),i.createElementBlock("nav",Zl,[i.createElementVNode("ul",Jl,[(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(e.items,(f,l)=>(i.openBlock(),i.createElementBlock("li",{class:i.normalizeClass(["breadcrumb-item",l===r.last?"active":""]),"aria-current":"page",key:l},[l!==r.last&&l>e.items.length-4||l===0?(i.openBlock(),i.createElementBlock("a",{key:0,class:"ib-link",href:f.url},i.toDisplayString(f.title),9,Xl)):i.createCommentVNode("",!0),l===r.last?(i.openBlock(),i.createElementBlock("p",Ql,i.toDisplayString(f.title),1)):i.createCommentVNode("",!0),r.initContextMenu&&l===e.items.length-4?(i.openBlock(),i.createBlock(h,{key:2,horizontal:"center"},{trigger:i.withCtx(()=>[i.createVNode(u,{kind:"ghost"},{default:i.withCtx(()=>[i.createVNode(s,{name:"ellipsis-horizontal-sharp"}),e.tooltipTextContext?(i.openBlock(),i.createBlock(d,{key:0,text:e.tooltipTextContext},null,8,["text"])):i.createCommentVNode("",!0)]),_:1})]),body:i.withCtx(()=>[(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(r.setItemsContextMenu,(c,_)=>(i.openBlock(),i.createBlock(p,{key:_},{default:i.withCtx(()=>[i.createElementVNode("a",{class:"context-breadcrums",href:c.url},i.toDisplayString(c.title),9,es)]),_:2},1024))),128))]),_:2},1024)):i.createCommentVNode("",!0),l!==r.last&&l>e.items.length-5||l===0?(i.openBlock(),i.createBlock(s,{key:3,name:"chevron-forward-outline"})):i.createCommentVNode("",!0)],2))),128))])])}const ns=_e(Wl,[["render",ts],["__scopeId","data-v-5ef772a9"]]),k1="",rs={name:"IbLabel",props:{for:{type:String},required:{type:Boolean,default:!1},infoText:{type:String,default:""},tooltipPosition:{type:String}},mounted(){this.$globalEvents.$on(`label:disabled:${this.for}`,t=>{this.disabled=t})},data(){return{disabled:!1}},computed:{classes(){const t=["ib-label"];return this.infoText.length&&t.push("has-info-text"),this.disabled&&t.push("label-disabled"),t}},components:{IbIconButton:ut,IbIcon:Le,IbTooltip:jt}},is=["for"],os={key:0,class:"required"};function as(t,n,e,o,a,r){const s=i.resolveComponent("ib-icon"),d=i.resolveComponent("ib-tooltip"),u=i.resolveComponent("ib-icon-button");return i.openBlock(),i.createElementBlock("label",{class:i.normalizeClass(r.classes),for:e.for},[e.required?(i.openBlock(),i.createElementBlock("span",os,"* ")):i.createCommentVNode("",!0),i.renderSlot(t.$slots,"default",{},void 0,!0),e.infoText.length?(i.openBlock(),i.createBlock(u,{key:1,size:"xs",class:"info-button",kind:"ghost",type:"button"},{default:i.withCtx(()=>[i.createVNode(s,{name:"information-circle-outline"}),i.createVNode(d,{text:e.infoText,position:e.tooltipPosition},null,8,["text","position"])]),_:1})):i.createCommentVNode("",!0)],10,is)}const dn=_e(rs,[["render",as],["__scopeId","data-v-3e867259"]]),vr={text:"text",password:"password",email:"email",number:"number"},C1="",ls={name:"IbInput",props:{type:{type:String,default:vr.text,validator:t=>Object.keys(vr).includes(t)},disabled:{type:Boolean,required:!1,default:!1},error:{type:Boolean,default:!1},errorMessage:{type:String,default:""},id:{type:[String],default(){return ht()}},debounce:{type:[Number,String]},showIcon:{type:Boolean,default:!1},showClearButton:{type:Boolean,default:!0},clearButtonMessage:{type:String,default:""},settingsButtonMessage:{type:String,default:""},showPasswordMessage:{type:String,default:""},hidePasswordMessage:{type:String,default:""},value:{type:[String,Number],default:""},modelValue:{type:[String,Number]},settingsVerticalPosition:{type:String,default:Bn.bottom},settingsHorizontalPosition:{type:String,default:sn.right},readonly:{type:Boolean,default:!1}},data(){return{actualValue:this.modelValue||this.value,showPassword:!1}},mounted(){setTimeout(()=>{this.$globalEvents.$emit(`label:disabled:${this.id}`,this.disabled)},10)},methods:{toggleShowPassword(){this.showPassword=!this.showPassword},clearInput(){this.actualValue="",this.$emit("update:modelValue",this.actualValue),this.$emit("input",this.actualValue),this.$emit("clear")},onBlur(){this.$emit("blur",this.actualValue)},onFocus(){this.$emit("focus",this.actualValue)},onInput(){this.debounce?this.delayedInput(this.actualValue):(this.$emit("update:modelValue",this.actualValue),this.$emit("input",this.actualValue))},delayedInput(t){this.timer&&(clearTimeout(this.timer),this.timer=null),this.timer=setTimeout(()=>{this.$emit("update:modelValue",t),this.$emit("input",t)},this.debounce)},focus(){this.$refs.field.focus()}},computed:{hasSettings(){return!!this.$slots.settings},classes(){const t=["ib-input"];return this.hasErrorState&&t.push("ib-error"),this.showIcon&&t.push("ib-input-has-icon"),t},attrs(){let t=Dn({...this.$attrs},["onInput","onBlur"]);return t.type=this.type===vr.password?this.showPassword?"text":"password":this.type,t},hasErrorState(){return this.error||this.errorMessage.length}},watch:{value(t){this.actualValue=t},modelValue(t){this.actualValue=t},disabled(t){this.$globalEvents.$emit(`label:disabled:${this.id}`,t)}},emits:["input","blur","focus","clear","update:modelValue",`label:disabled:${globalThis==null?void 0:globalThis.id}`],components:{IbAlert:Pt,IbIconButton:ut,IbIcon:Le,IbDropdown:Ln},inheritAttrs:!1},ss=["aria-invalid","readonly","disabled","id"],ds={class:"settings-wrapper"};function cs(t,n,e,o,a,r){var h,f;const s=i.resolveComponent("ib-alert"),d=i.resolveComponent("ib-icon"),u=i.resolveComponent("ib-icon-button"),p=i.resolveComponent("ib-dropdown");return i.openBlock(),i.createElementBlock("div",null,[e.errorMessage?(i.openBlock(),i.createBlock(s,{key:0},{default:i.withCtx(()=>[i.createTextVNode(i.toDisplayString(e.errorMessage),1)]),_:1})):i.createCommentVNode("",!0),i.createElementVNode("div",{class:i.normalizeClass(["ib-input-wrapper",{"has-settings":r.hasSettings}])},[e.showIcon?(i.openBlock(),i.createBlock(d,{key:0,class:"icon-search",name:"search-outline"})):i.createCommentVNode("",!0),i.withDirectives(i.createElementVNode("input",i.mergeProps(r.attrs,{"onUpdate:modelValue":n[0]||(n[0]=l=>a.actualValue=l),ref:"field","aria-invalid":!!r.hasErrorState,readonly:e.readonly,disabled:e.disabled,id:e.id,class:r.classes,onInput:n[1]||(n[1]=l=>r.onInput(l)),onBlur:n[2]||(n[2]=l=>r.onBlur(l)),onFocus:n[3]||(n[3]=l=>r.onFocus(l))}),null,16,ss),[[i.vModelDynamic,a.actualValue]]),e.type!=="password"&&e.showClearButton?i.withDirectives((i.openBlock(),i.createBlock(u,{key:1,kind:"ghost",class:"button-clear",disabled:e.readonly||e.disabled,"help-text":e.clearButtonMessage,"prevent-default":"",type:"button",onClick:r.clearInput,onKeypress:i.withKeys(r.clearInput,["enter"])},{default:i.withCtx(()=>[i.createVNode(d,{name:"close-outline"})]),_:1},8,["disabled","help-text","onClick","onKeypress"])),[[i.vShow,(h=a.actualValue)==null?void 0:h.length]]):i.createCommentVNode("",!0),e.type==="password"?i.withDirectives((i.openBlock(),i.createBlock(u,{key:2,kind:"ghost",class:"toggle-password","prevent-default":"",type:"button",disabled:e.readonly||e.disabled,"help-text":a.showPassword?e.hidePasswordMessage:e.showPasswordMessage,onClick:i.withModifiers(r.toggleShowPassword,["prevent"])},{default:i.withCtx(()=>[i.createVNode(d,{name:a.showPassword?"eye-off-outline":"eye-outline"},null,8,["name"])]),_:1},8,["disabled","help-text","onClick"])),[[i.vShow,(f=a.actualValue)==null?void 0:f.length]]):i.createCommentVNode("",!0),r.hasSettings?(i.openBlock(),i.createBlock(p,{key:3,class:"settings-dropdown-wrapper",horizontal:e.settingsHorizontalPosition,vertical:e.settingsVerticalPosition},{trigger:i.withCtx(()=>[i.createVNode(u,{"prevent-default":"","help-text":e.settingsButtonMessage,class:"options-trigger",kind:"ghost"},{default:i.withCtx(()=>[i.createVNode(d,{name:"options"})]),_:1},8,["help-text"])]),body:i.withCtx(()=>[i.createElementVNode("div",ds,[i.renderSlot(t.$slots,"settings",{},void 0,!0)])]),_:3},8,["horizontal","vertical"])):i.createCommentVNode("",!0)],2)])}const br=_e(ls,[["render",cs],["__scopeId","data-v-ea1e952e"]]),O1="",us={name:"IbCheckbox",model:{event:"input"},props:{label:String,error:{type:[Boolean,null],default:!1},name:String,id:{type:String,default(){return ht()}},value:{default:1},modelValue:{type:Boolean},isChecked:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},disableFocus:{type:Boolean,default:!1},required:{type:Boolean,default:!1},labelPosition:{type:String,default:"right"}},watch:{isChecked(t){this.checked=t},modelValue(t){this.$emit("update:modelValue",this.modelValue),this.checked=t}},data(){return{checked:this.modelValue?this.modelValue:this.isChecked}},methods:{onChange(){this.readonly||(this.checked=!this.checked,this.$emit("update:modelValue",this.checked),this.$emit("input",this.checked))}},computed:{classes(){return{"ib-checkbox":!0,"ib-has-error":this.error,"ib-checkbox-filled":this.checked,"ib-checkbox-disabled":this.disabled,"ib-checkbox-readonly":this.readonly,"ib-checkbox-indeterminate":this.indeterminate}},indeterminate(){return this.isChecked===null},attrs(){const t={...Dn({...this.$attrs})};return delete t.class,t.class=this.classes,t}},components:{IbIcon:Le},inheritAttrs:!1},fs=["aria-checked"],hs=["for","tabindex"],ps=["name","id","value","disabled","required"],ms={class:"ib-checkbox-body"},gs={key:0,class:"required"},ys={class:"ib-checkbox-input"},vs={key:1,class:"ib-checkbox-label"},bs={key:0,class:"required"};function _s(t,n,e,o,a,r){var d;const s=i.resolveComponent("ib-icon");return i.openBlock(),i.createElementBlock("div",{role:"checkbox",class:i.normalizeClass(["ib-checkbox-wrapper",this.$attrs.class]),"aria-checked":!!a.checked},[i.createElementVNode("label",i.mergeProps(r.attrs,{for:e.id,tabindex:e.disabled|e.disableFocus?-1:0,onKeypress:n[2]||(n[2]=i.withModifiers((...u)=>r.onChange&&r.onChange(...u),["prevent"]))}),[i.withDirectives(i.createElementVNode("input",{tabindex:"-1",type:"checkbox",name:e.name,id:e.id,value:e.value,disabled:e.disabled,required:e.required,"onUpdate:modelValue":n[0]||(n[0]=u=>a.checked=u),onClick:n[1]||(n[1]=i.withModifiers((...u)=>r.onChange&&r.onChange(...u),["prevent"]))},null,8,ps),[[i.vModelCheckbox,a.checked]]),i.createElementVNode("div",ms,[e.labelPosition==="left"&&e.label.length?(i.openBlock(),i.createElementBlock("span",{key:0,class:i.normalizeClass(["ib-checkbox-label",{"ib-checkbox-label-left":e.labelPosition==="left"}])},[e.required?(i.openBlock(),i.createElementBlock("span",gs,"*")):i.createCommentVNode("",!0),i.createTextVNode(" "+i.toDisplayString(e.label),1)],2)):i.createCommentVNode("",!0),i.createElementVNode("span",ys,[i.withDirectives(i.createVNode(s,{name:"checkmark-sharp"},null,512),[[i.vShow,a.checked&&!r.indeterminate]]),i.withDirectives(i.createVNode(s,{class:i.normalizeClass("checkbox-undeterminate-icon"),name:"remove-sharp"},null,512),[[i.vShow,r.indeterminate]])]),e.labelPosition==="right"&&((d=e.label)!=null&&d.length)?(i.openBlock(),i.createElementBlock("span",vs,[e.required?(i.openBlock(),i.createElementBlock("span",bs,"*")):i.createCommentVNode("",!0),i.createTextVNode(" "+i.toDisplayString(e.label),1)])):i.createCommentVNode("",!0)])],16,hs)],10,fs)}const _r=_e(us,[["render",_s]]),E1="",$s={name:"IbToggle",model:{prop:"isChecked",event:"input"},props:{isChecked:{type:Boolean,required:!1},id:{type:String,default:()=>ht()},disabled:{type:Boolean,default:!1},name:{type:String,default:"active"},label:{type:String,default:""},error:{type:Boolean,default:!1},labelPosition:{type:String,default:"right"},helpMessage:{type:String,default:""},helpMessageOff:{type:String,default:""}},watch:{isChecked(t){this.checked=t}},data(){return{checked:this.isChecked}},methods:{onChange(){this.disabled||(this.checked=!this.checked,this.$emit("input",this.checked))}},computed:{classes(){return{"ib-toggle-container":!0,"has-error":this.error,"toggle-on":this.checked,"toggle-disabled":this.disabled,"label-position-left":this.labelPosition==="left"}}},components:{IbIcon:Le,IbTooltip:jt}},ws=["aria-checked","tabindex"],ks={class:"toggle-wrapper",ref:"wrapper"},Cs={class:"toggle",ref:"toggle"},Os=["name","checked","id","disabled"],Es=i.createElementVNode("span",{class:"toggle-slider round"},null,-1),Ss={key:0,class:"toggle-label"};function Ts(t,n,e,o,a,r){const s=i.resolveComponent("ib-icon"),d=i.resolveComponent("ib-tooltip");return i.openBlock(),i.createElementBlock("label",{role:"switch","aria-checked":a.checked,tabindex:e.disabled?-1:0,class:i.normalizeClass(r.classes),onKeypress:[n[2]||(n[2]=i.withKeys(i.withModifiers((...u)=>r.onChange&&r.onChange(...u),["prevent"]),["space"])),n[3]||(n[3]=i.withKeys(i.withModifiers((...u)=>r.onChange&&r.onChange(...u),["prevent"]),["enter"]))]},[i.createElementVNode("div",ks,[i.createElementVNode("div",Cs,[i.createElementVNode("input",{tabindex:"-1",type:"checkbox",value:"1",name:e.name,checked:a.checked,id:e.id,disabled:e.disabled,onClick:n[0]||(n[0]=(...u)=>r.onChange&&r.onChange(...u)),onInput:n[1]||(n[1]=i.withModifiers(()=>{},["stop"]))},null,40,Os),Es,i.createVNode(s,{class:"checked-icon",name:"checkmark"}),i.createVNode(s,{class:"unchecked-icon",name:"close"})],512)],512),e.label.length?(i.openBlock(),i.createElementBlock("span",Ss,i.toDisplayString(e.label),1)):i.createCommentVNode("",!0),e.helpMessage.length?(i.openBlock(),i.createBlock(d,{key:1,text:a.checked?e.helpMessage:e.helpMessageOff.length?e.helpMessageOff:e.helpMessage},null,8,["text"])):i.createCommentVNode("",!0)],42,ws)}const Ii=_e($s,[["render",Ts]]);function Mi(t){return t.scrollHeight>t.clientHeight}const S1="",Ns={name:"select-option",props:{option:{type:Object},name:String,parentAutoCheck:{type:Boolean,default:!1},isMultiple:{type:Boolean,default:!0},uid:{type:String,default:""},onlyEndNodes:{type:Boolean,default:!1},htmlTitle:{type:Boolean,default:!1},showInput:{type:Boolean,default:!0},isBookmarkable:{type:Boolean,default:!1},isBookmarked:{type:Boolean,default:!1},isToggle:{type:Boolean,default:!1}},mounted(){this.option.hasOwnProperty("children")&&this.option.children&&this.checkParent()},updated(){this.$nextTick(()=>{Mi(this.$el.querySelector(".option-label"))&&(this.showTooltip=!0)})},data(){return{showTooltip:!1}},methods:{onKeydown(t){t.keyCode===Ci&&(t.preventDefault(),this.onChange()),this.hasVisibleChildren&&(t.keyCode===Ua&&(this.option.isChildrenVisible=!0),t.keyCode===za&&(this.option.isChildrenVisible=!1))},onChange(){var t,n;!this.isMultiple&&!this.isChecked(this.option)&&((t=this.$refs.component)==null||t.onChange()),this.isMultiple&&((n=this.$refs.component)==null||n.onChange())},toggle(t,n=!0){this.check(this.option,t,!0,n)},check(t,n,e,o){this.$emit("check",t,n,e),o&&t.children&&t.children.forEach(a=>{this.check(a,n,!1,!0)})},toggleChildrenVisibility(){this.option.isChildrenVisible=!this.option.isChildrenVisible},checkChildren(t,n,e){e&&this.isMultiple&&this.$nextTick(()=>{this.checkParent()}),this.$emit("check",t,n,!1)},checkParent(){const t=this.option.children.filter(e=>e.checked).length,n=t>=this.option.children.length;(!this.option.checked&&n&&this.parentAutoCheck||this.option.checked&&!n)&&this.toggle(!this.option.checked,!1)},calculateChildren(t,n,e=!1){let o=0;return t.children&&t.children.forEach(a=>{(!n||n(a))&&o++,e&&(o+=this.calculateChildren(a,n,e))}),o},isChecked(t){if(this.hasChildren)if(this.childrenSelectedCount){if(this.childrenSelectedCount>0&&this.countOfAllChildren>this.childrenSelectedCount)return null}else return!1;return t.checked?!0:t.isIndeterminate?null:!1}},computed:{component(){return this.isMultiple&&this.isToggle?Ii:_r},hasChildren(){return!!(this.option.children&&this.option.children.length)},hasVisibleChildren(){return this.calculateChildren(this.option,t=>t.visible)},iconName(){return this.option.isChildrenVisible?"chevron-down":"chevron-forward"},id(){return this.uid+"_"+this.option.id},actualName(){return this.onlyEndNodes&&this.option.children&&this.option.children.length?"":this.name},childrenSelectedCount(){return this.calculateChildren(this.option,t=>t.checked,!0)},countOfAllChildren(){return this.calculateChildren(this.option,()=>!0,!0)}},components:{IbIcon:Le,List:mr,IbIconButton:ut},directives:{Tooltip:yr}},xs=["aria-selected","aria-label","id"],As={key:0,class:"option-label"},Ds={key:1,class:"option-label"},Is=["innerHTML"],Ms=["innerHTML"],Ps={key:2,class:"option-label"};function Bs(t,n,e,o,a,r){const s=i.resolveComponent("ib-icon"),d=i.resolveComponent("ib-icon-button"),u=i.resolveComponent("select-option"),p=i.resolveComponent("list"),h=i.resolveDirective("tooltip");return i.openBlock(),i.createElementBlock("li",null,[i.withDirectives((i.openBlock(),i.createElementBlock("div",{class:i.normalizeClass(["tree-select-option",{"tree-select-option-checked":r.isChecked(e.option),"tree-select-option-margin":r.hasVisibleChildren,active:e.option.isChildrenVisible,"is-multiple":e.isMultiple,"is-not-multiple":!e.isMultiple,"tree-select-option-toggle":this.isToggle&&this.isMultiple}]),tabindex:"0",role:"option","aria-selected":r.isChecked(e.option),"aria-label":e.option.title,id:"option-"+r.id,onKeydown:n[3]||(n[3]=i.withModifiers((...f)=>r.onKeydown&&r.onKeydown(...f),["self"])),onFocus:n[4]||(n[4]=f=>t.$emit("onFocus",`option-${r.id}`))},[i.withDirectives(i.createVNode(d,{"disabled-focus":!0,kind:"ghost",class:"toggle-children",onClick:r.toggleChildrenVisibility},{default:i.withCtx(()=>[i.createVNode(s,{name:r.iconName},null,8,["name"])]),_:1},8,["onClick"]),[[i.vShow,r.hasVisibleChildren]]),i.createElementVNode("div",{onClick:n[1]||(n[1]=i.withModifiers((...f)=>r.onChange&&r.onChange(...f),["prevent"])),class:i.normalizeClass({disabled:e.option.isDisabled,"tree-select-option-label":!0,"tree-select-option-has-children":r.hasVisibleChildren,active:!e.showInput&&e.option.checked})},[i.withDirectives((i.openBlock(),i.createBlock(i.resolveDynamicComponent(r.component),{ref:"component",tabindex:"-1","disable-focus":"","aria-label":e.option.title,name:r.actualName,value:e.option.id,id:"input"+r.id,"is-checked":r.isChecked(e.option),disabled:e.option.isDisabled,readonly:e.option.readonly,autocomplete:"off",autocorrect:"off",autocapitalize:"off",spellcheck:"false",onInput:r.toggle},null,40,["aria-label","name","value","id","is-checked","disabled","readonly","onInput"])),[[i.vShow,e.showInput]]),e.isBookmarkable?(i.openBlock(),i.createElementBlock("span",{key:0,class:i.normalizeClass("bookmarkable-option-title "+(e.isBookmarked?"bookmarked":""))},[r.hasChildren?(i.openBlock(),i.createElementBlock("span",Ds,i.toDisplayString(e.option.title),1)):(i.openBlock(),i.createElementBlock("span",As,[i.createTextVNode(i.toDisplayString(e.option.title)+" ",1),i.createVNode(s,{name:"star",onClick:n[0]||(n[0]=i.withModifiers(f=>t.$emit("toggle-bookmark",e.option),["stop","prevent"]))})]))],2)):e.htmlTitle?(i.openBlock(),i.createElementBlock(i.Fragment,{key:1},[r.hasChildren?(i.openBlock(),i.createElementBlock("span",{key:1,class:"option-label",innerHTML:e.option.title},null,8,Ms)):(i.openBlock(),i.createElementBlock("span",{key:0,class:"option-label",innerHTML:e.option.title},null,8,Is))],64)):(i.openBlock(),i.createElementBlock("span",Ps,i.toDisplayString(e.option.title),1))],2),r.hasChildren?i.withDirectives((i.openBlock(),i.createBlock(p,{key:0},{default:i.withCtx(()=>[(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(e.option.children,f=>i.withDirectives((i.openBlock(),i.createBlock(u,{key:f.value,option:f,name:e.name,"parent-auto-check":e.parentAutoCheck,"is-multiple":e.isMultiple,"show-input":e.showInput,onCheck:r.checkChildren,onToggleBookmark:n[2]||(n[2]=l=>t.$emit("toggle-bookmark",l)),uid:e.uid,"is-bookmarkable":e.isBookmarkable},null,8,["option","name","parent-auto-check","is-multiple","show-input","onCheck","uid","is-bookmarkable"])),[[i.vShow,f.visible]])),128))]),_:1},512)),[[i.vShow,r.hasVisibleChildren&&e.option.isChildrenVisible]]):i.createCommentVNode("",!0)],42,xs)),[[h,a.showTooltip?e.option.title:""]])])}const Ls=_e(Ns,[["render",Bs]]);var qe=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function jn(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var Pi={exports:{}};/*!***************************************************
|
|
21
|
+
top: ${o-h+f-5}px!important`;break}return l}getClassList(n){return n?hr[n]:hr.topCenter}}const Vt=new xi,ql=(t,n)=>{var a;Vt.getTooltipContainer()&&Vt.destroyTooltip();const e=Object.keys(n.modifiers)[0]||n.arg,o={title:((a=n.value)==null?void 0:a.title)||"",text:typeof n.value=="object"?n.value.text:n.value};Vt.createTooltip(t,o,e)},Fl=(t,n)=>{const e=Vt.getId();if(n.getAttribute("aria-describedby")!==e)return;const o=Vt.getTooltipContainer(),a=n!==t.target&&!n.contains(t.target),r=o!==t.target&&!(o!=null&&o.contains(t.target));a&&r&&Vt.destroyTooltip(n)},Ai=(t,n)=>{t.__tooltip_create=()=>ql(t,n),t.__tooltip_destroy=e=>Fl(e,t),t.addEventListener("mouseenter",t.__tooltip_create),document.addEventListener("mousemove",t.__tooltip_destroy)},Di=t=>{Vt.destroyTooltip(t),t.removeEventListener("mouseenter",t.__tooltip_create),document.removeEventListener("mousemove",t.__tooltip_destroy)},yr={mounted(t,n){Ai(t,n)},updated(t,n){Di(t),Ai(t,n)},beforeUnmount(t){Di(t)}},$1="",Hl={name:"IbSorting",props:{tooltipTitle:{type:String,default:""},hideSortingButton:{type:Boolean,default:!1},tooltipText:{type:String},tooltipPosition:{type:String},tooltipIconPosition:{type:String},tooltipIconSorting:{type:String},toggleTipTitle:{type:String},title:{type:String,default:""},sort:{type:String,default:null},view:{type:String,required:!0},disable:{type:Boolean,default:!1},tableName:{type:String,required:!0}},mounted(){this.$globalEvents.$on(`sorting:update:${this.tableName}`,t=>{this.$el.contains(t.$el)||(this.currentTypeSort=null)})},data(){return{isOpenToggleTip:!1,sortingTypes:Vl,sortingTypesView:jl,currentTypeSort:this.sort}},methods:{clickHandler(){this.currentTypeSort?this.currentTypeSort===this.sortingTypes.TYPE_ASC?this.currentTypeSort=this.sortingTypes.TYPE_DESC:this.currentTypeSort=null:this.currentTypeSort=this.sortingTypes.TYPE_ASC,this.updateTypeSorting()},updateTypeSorting(){this.$globalEvents.$emit(`sorting:update:${this.tableName}`,this),this.$emit("update-sorting",this.currentTypeSort)}},computed:{iconType(){return this.currentTypeSort===this.sortingTypes.TYPE_ASC?"arrow-up":this.currentTypeSort===this.sortingTypes.TYPE_DESC?"arrow-down":this.view!==this.sortingTypesView.GRID_VIEW?"swap-vertical":null},sortingTooltipPosition(){return this.hasToggleTip?"bottomCenter":this.tooltipPosition},sortingTooltipContent(){var t;return this.hasToggleTip?lang("click_to_view_details",(t=this.langComponents)==null?void 0:t.COMPONENT_SYSTEM):this.tooltipContent},tooltipIconText(){var t,n,e;return this.currentTypeSort===this.sortingTypes.TYPE_ASC?lang("sort_descending",(t=this.langComponents)==null?void 0:t.COMPONENT_SELECT):this.currentTypeSort===this.sortingTypes.TYPE_DESC?lang("reset_sorting",(n=this.langComponents)==null?void 0:n.COMPONENT_SELECT):this.view!==this.sortingTypesView.GRID_VIEW?lang("sort_ascending",(e=this.langComponents)==null?void 0:e.COMPONENT_SELECT):""},tooltipContent(){return this.tooltipTitle.length?{title:this.tooltipTitle,text:this.tooltipText}:this.tooltipText},hasToggleTip(){return this.toggleTipTitle&&this.$slots.toggleTipBody&&this.$slots.toggleTipButtons}},directives:{Tooltip:yr},components:{IbIcon:Le,IbIconButton:ut,IbToggleTip:ki}},zl={class:"sorting-wrapper"},Ul=["name"],Kl=["aria-label"];function Gl(t,n,e,o,a,r){var h;const s=i.resolveComponent("ib-toggle-tip"),d=i.resolveComponent("ib-icon-button"),u=i.resolveComponent("ib-icon"),p=i.resolveDirective("tooltip");return i.openBlock(),i.createElementBlock("div",zl,[e.view===a.sortingTypesView.TABLE_VIEW?(i.openBlock(),i.createElementBlock("div",{key:0,class:i.normalizeClass(["table-sorting-wrapper",{active:a.currentTypeSort,disabled:e.disable}])},[i.createElementVNode("div",null,[i.withDirectives((i.openBlock(),i.createElementBlock("button",{class:i.normalizeClass(["sorting-label",{"sorting-label-active":a.isOpenToggleTip&&r.hasToggleTip,"has-action":((h=e.tooltipText)==null?void 0:h.length)||r.hasToggleTip}]),type:"button",onClick:n[0]||(n[0]=f=>a.isOpenToggleTip=!a.isOpenToggleTip)},[i.createTextVNode(i.toDisplayString(e.title),1)],2)),[[p,r.sortingTooltipContent,r.sortingTooltipPosition]]),r.hasToggleTip?(i.openBlock(),i.createBlock(s,{key:0,position:"bottom-center","is-open":a.isOpenToggleTip,title:e.toggleTipTitle,onClose:n[1]||(n[1]=f=>a.isOpenToggleTip=!1)},{buttons:i.withCtx(()=>[i.renderSlot(t.$slots,"toggleTipButtons",{},void 0,!0)]),default:i.withCtx(()=>[i.renderSlot(t.$slots,"toggleTipBody",{},void 0,!0)]),_:3},8,["is-open","title"])):i.createCommentVNode("",!0)]),e.hideSortingButton?i.createCommentVNode("",!0):i.withDirectives((i.openBlock(),i.createBlock(d,{key:0,kind:"white",size:"s",onClick:r.clickHandler},{default:i.withCtx(()=>[i.createElementVNode("ion-icon",{name:r.iconType},null,8,Ul)]),_:1},8,["onClick"])),[[p,r.tooltipIconText,e.tooltipIconPosition]])],2)):i.withDirectives((i.openBlock(),i.createElementBlock("button",{key:1,class:i.normalizeClass(["sorting-button",{active:a.currentTypeSort,disabled:e.disable}]),type:"button",onClick:n[2]||(n[2]=(...f)=>r.clickHandler&&r.clickHandler(...f)),"aria-label":e.sort},[i.createTextVNode(i.toDisplayString(e.title)+" ",1),r.iconType?(i.openBlock(),i.createBlock(u,{key:0,name:r.iconType},null,8,["name"])):i.createCommentVNode("",!0)],10,Kl)),[[p,e.tooltipText,e.tooltipPosition]])])}const Yl=_e(Hl,[["render",Gl],["__scopeId","data-v-a4394881"]]),w1="",Wl={name:"IbBreadcrumbs",props:{items:{type:Array,default:()=>[]},tooltipTextContext:{type:String}},computed:{last(){return this.items.length?this.items.length-1:null},initContextMenu(){return this.items.length>4},setItemsContextMenu(){return this.items.slice(0,-3)}},components:{IbIcon:Le,IbIconButton:ut,IbDropdownItem:gr,IbDropdownList:Rn,IbTooltip:jt}},Zl={"aria-label":"breadcrumb"},Jl={class:"breadcrumb"},Xl=["href"],Ql={key:1},es=["href"];function ts(t,n,e,o,a,r){const s=i.resolveComponent("ib-icon"),d=i.resolveComponent("ib-tooltip"),u=i.resolveComponent("ib-icon-button"),p=i.resolveComponent("ib-dropdown-item"),h=i.resolveComponent("ib-dropdown-list");return i.openBlock(),i.createElementBlock("nav",Zl,[i.createElementVNode("ul",Jl,[(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(e.items,(f,l)=>(i.openBlock(),i.createElementBlock("li",{class:i.normalizeClass(["breadcrumb-item",l===r.last?"active":""]),"aria-current":"page",key:l},[l!==r.last&&l>e.items.length-4||l===0?(i.openBlock(),i.createElementBlock("a",{key:0,class:"ib-link",href:f.url},i.toDisplayString(f.title),9,Xl)):i.createCommentVNode("",!0),l===r.last?(i.openBlock(),i.createElementBlock("p",Ql,i.toDisplayString(f.title),1)):i.createCommentVNode("",!0),r.initContextMenu&&l===e.items.length-4?(i.openBlock(),i.createBlock(h,{key:2,horizontal:"center"},{trigger:i.withCtx(()=>[i.createVNode(u,{kind:"ghost"},{default:i.withCtx(()=>[i.createVNode(s,{name:"ellipsis-horizontal-sharp"}),e.tooltipTextContext?(i.openBlock(),i.createBlock(d,{key:0,text:e.tooltipTextContext},null,8,["text"])):i.createCommentVNode("",!0)]),_:1})]),body:i.withCtx(()=>[(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(r.setItemsContextMenu,(c,_)=>(i.openBlock(),i.createBlock(p,{key:_},{default:i.withCtx(()=>[i.createElementVNode("a",{class:"context-breadcrums",href:c.url},i.toDisplayString(c.title),9,es)]),_:2},1024))),128))]),_:2},1024)):i.createCommentVNode("",!0),l!==r.last&&l>e.items.length-5||l===0?(i.openBlock(),i.createBlock(s,{key:3,name:"chevron-forward-outline"})):i.createCommentVNode("",!0)],2))),128))])])}const ns=_e(Wl,[["render",ts],["__scopeId","data-v-5ef772a9"]]),k1="",rs={name:"IbLabel",props:{for:{type:String},required:{type:Boolean,default:!1},infoText:{type:String,default:""},tooltipPosition:{type:String}},mounted(){this.$globalEvents.$on(`label:disabled:${this.for}`,t=>{this.disabled=t})},data(){return{disabled:!1}},computed:{classes(){const t=["ib-label"];return this.infoText.length&&t.push("has-info-text"),this.disabled&&t.push("label-disabled"),t}},components:{IbIconButton:ut,IbIcon:Le,IbTooltip:jt}},is=["for"],os={key:0,class:"required"};function as(t,n,e,o,a,r){const s=i.resolveComponent("ib-icon"),d=i.resolveComponent("ib-tooltip"),u=i.resolveComponent("ib-icon-button");return i.openBlock(),i.createElementBlock("label",{class:i.normalizeClass(r.classes),for:e.for},[e.required?(i.openBlock(),i.createElementBlock("span",os,"* ")):i.createCommentVNode("",!0),i.renderSlot(t.$slots,"default",{},void 0,!0),e.infoText.length?(i.openBlock(),i.createBlock(u,{key:1,size:"xs",class:"info-button",kind:"ghost",type:"button"},{default:i.withCtx(()=>[i.createVNode(s,{name:"information-circle-outline"}),i.createVNode(d,{text:e.infoText,position:e.tooltipPosition},null,8,["text","position"])]),_:1})):i.createCommentVNode("",!0)],10,is)}const dn=_e(rs,[["render",as],["__scopeId","data-v-3e867259"]]),vr={text:"text",password:"password",email:"email",number:"number"},C1="",ls={name:"IbInput",props:{type:{type:String,default:vr.text,validator:t=>Object.keys(vr).includes(t)},disabled:{type:Boolean,required:!1,default:!1},error:{type:Boolean,default:!1},errorMessage:{type:String,default:""},id:{type:[String],default(){return ht()}},debounce:{type:[Number,String]},showIcon:{type:Boolean,default:!1},showClearButton:{type:Boolean,default:!0},clearButtonMessage:{type:String,default:""},settingsButtonMessage:{type:String,default:""},showPasswordMessage:{type:String,default:""},hidePasswordMessage:{type:String,default:""},value:{type:[String,Number],default:""},modelValue:{type:[String,Number]},settingsVerticalPosition:{type:String,default:Bn.bottom},settingsHorizontalPosition:{type:String,default:sn.right},readonly:{type:Boolean,default:!1}},data(){return{actualValue:this.modelValue||this.value,showPassword:!1}},mounted(){setTimeout(()=>{this.$globalEvents.$emit(`label:disabled:${this.id}`,this.disabled)},10)},methods:{toggleShowPassword(){this.showPassword=!this.showPassword},clearInput(){this.actualValue="",this.$emit("update:modelValue",this.actualValue),this.$emit("input",this.actualValue),this.$emit("clear")},onBlur(){this.$emit("blur",this.actualValue)},onFocus(){this.$emit("focus",this.actualValue)},onInput(){this.debounce?this.delayedInput(this.actualValue):(this.$emit("update:modelValue",this.actualValue),this.$emit("input",this.actualValue))},delayedInput(t){this.timer&&(clearTimeout(this.timer),this.timer=null),this.timer=setTimeout(()=>{this.$emit("update:modelValue",t),this.$emit("input",t)},this.debounce)},focus(){this.$refs.field.focus()}},computed:{hasSettings(){return!!this.$slots.settings},classes(){const t=["ib-input"];return this.hasErrorState&&t.push("ib-error"),this.showIcon&&t.push("ib-input-has-icon"),t},attrs(){let t=Dn({...this.$attrs},["onInput","onBlur"]);return t.type=this.type===vr.password?this.showPassword?"text":"password":this.type,t},hasErrorState(){return this.error||this.errorMessage.length}},watch:{value(t){this.actualValue=t},modelValue(t){this.actualValue=t},disabled(t){this.$globalEvents.$emit(`label:disabled:${this.id}`,t)}},emits:["input","blur","focus","clear","update:modelValue",`label:disabled:${globalThis==null?void 0:globalThis.id}`],components:{IbAlert:Pt,IbIconButton:ut,IbIcon:Le,IbDropdown:Ln},inheritAttrs:!1},ss=["aria-invalid","readonly","disabled","id"],ds={class:"settings-wrapper"};function cs(t,n,e,o,a,r){var h,f;const s=i.resolveComponent("ib-alert"),d=i.resolveComponent("ib-icon"),u=i.resolveComponent("ib-icon-button"),p=i.resolveComponent("ib-dropdown");return i.openBlock(),i.createElementBlock("div",null,[e.errorMessage?(i.openBlock(),i.createBlock(s,{key:0},{default:i.withCtx(()=>[i.createTextVNode(i.toDisplayString(e.errorMessage),1)]),_:1})):i.createCommentVNode("",!0),i.createElementVNode("div",{class:i.normalizeClass(["ib-input-wrapper",{"has-settings":r.hasSettings}])},[e.showIcon?(i.openBlock(),i.createBlock(d,{key:0,class:"icon-search",name:"search-outline"})):i.createCommentVNode("",!0),i.withDirectives(i.createElementVNode("input",i.mergeProps(r.attrs,{"onUpdate:modelValue":n[0]||(n[0]=l=>a.actualValue=l),ref:"field","aria-invalid":!!r.hasErrorState,readonly:e.readonly,disabled:e.disabled,id:e.id,class:r.classes,onInput:n[1]||(n[1]=l=>r.onInput(l)),onBlur:n[2]||(n[2]=l=>r.onBlur(l)),onFocus:n[3]||(n[3]=l=>r.onFocus(l))}),null,16,ss),[[i.vModelDynamic,a.actualValue]]),e.type!=="password"&&e.showClearButton?i.withDirectives((i.openBlock(),i.createBlock(u,{key:1,kind:"ghost",class:"button-clear",disabled:e.readonly||e.disabled,"help-text":e.clearButtonMessage,"prevent-default":"",type:"button",onClick:r.clearInput,onKeypress:i.withKeys(r.clearInput,["enter"])},{default:i.withCtx(()=>[i.createVNode(d,{name:"close-outline"})]),_:1},8,["disabled","help-text","onClick","onKeypress"])),[[i.vShow,(h=a.actualValue)==null?void 0:h.length]]):i.createCommentVNode("",!0),e.type==="password"?i.withDirectives((i.openBlock(),i.createBlock(u,{key:2,kind:"ghost",class:"toggle-password","prevent-default":"",type:"button",disabled:e.readonly||e.disabled,"help-text":a.showPassword?e.hidePasswordMessage:e.showPasswordMessage,onClick:i.withModifiers(r.toggleShowPassword,["prevent"])},{default:i.withCtx(()=>[i.createVNode(d,{name:a.showPassword?"eye-off-outline":"eye-outline"},null,8,["name"])]),_:1},8,["disabled","help-text","onClick"])),[[i.vShow,(f=a.actualValue)==null?void 0:f.length]]):i.createCommentVNode("",!0),r.hasSettings?(i.openBlock(),i.createBlock(p,{key:3,class:"settings-dropdown-wrapper",horizontal:e.settingsHorizontalPosition,vertical:e.settingsVerticalPosition},{trigger:i.withCtx(()=>[i.createVNode(u,{"prevent-default":"","help-text":e.settingsButtonMessage,class:"options-trigger",kind:"ghost"},{default:i.withCtx(()=>[i.createVNode(d,{name:"options"})]),_:1},8,["help-text"])]),body:i.withCtx(()=>[i.createElementVNode("div",ds,[i.renderSlot(t.$slots,"settings",{},void 0,!0)])]),_:3},8,["horizontal","vertical"])):i.createCommentVNode("",!0)],2)])}const br=_e(ls,[["render",cs],["__scopeId","data-v-ea1e952e"]]),O1="",us={name:"IbCheckbox",model:{event:"input"},props:{label:String,error:{type:[Boolean,null],default:!1},name:String,id:{type:String,default(){return ht()}},value:{default:1},modelValue:{type:Boolean},isChecked:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},disableFocus:{type:Boolean,default:!1},required:{type:Boolean,default:!1},labelPosition:{type:String,default:"right"}},watch:{isChecked(t){this.checked=t},modelValue(t){this.$emit("update:modelValue",this.modelValue),this.checked=t}},data(){return{checked:this.modelValue?this.modelValue:this.isChecked}},methods:{onChange(t){if(this.readonly){t.preventDefault();return}this.checked=!this.checked,this.$emit("update:modelValue",this.checked),this.$emit("input",this.checked)}},computed:{classes(){return{"ib-checkbox":!0,"ib-has-error":this.error,"ib-checkbox-filled":this.checked,"ib-checkbox-disabled":this.disabled,"ib-checkbox-readonly":this.readonly,"ib-checkbox-indeterminate":this.indeterminate}},indeterminate(){return this.isChecked===null},attrs(){const t={...Dn({...this.$attrs})};return delete t.class,t.class=this.classes,t}},components:{IbIcon:Le},inheritAttrs:!1},fs=["aria-checked"],hs=["for","tabindex"],ps=["name","id","value","disabled","required"],ms={class:"ib-checkbox-body"},gs={key:0,class:"required"},ys={class:"ib-checkbox-input"},vs={key:1,class:"ib-checkbox-label"},bs={key:0,class:"required"};function _s(t,n,e,o,a,r){var d;const s=i.resolveComponent("ib-icon");return i.openBlock(),i.createElementBlock("div",{role:"checkbox",class:i.normalizeClass(["ib-checkbox-wrapper",this.$attrs.class]),"aria-checked":!!a.checked},[i.createElementVNode("label",i.mergeProps(r.attrs,{for:e.id,tabindex:e.disabled|e.disableFocus?-1:0,onKeypress:n[2]||(n[2]=i.withModifiers((...u)=>r.onChange&&r.onChange(...u),["prevent"]))}),[i.withDirectives(i.createElementVNode("input",{tabindex:"-1",type:"checkbox",name:e.name,id:e.id,value:e.value,disabled:e.disabled,required:e.required,"onUpdate:modelValue":n[0]||(n[0]=u=>a.checked=u),onClick:n[1]||(n[1]=(...u)=>r.onChange&&r.onChange(...u))},null,8,ps),[[i.vModelCheckbox,a.checked]]),i.createElementVNode("div",ms,[e.labelPosition==="left"&&e.label.length?(i.openBlock(),i.createElementBlock("span",{key:0,class:i.normalizeClass(["ib-checkbox-label",{"ib-checkbox-label-left":e.labelPosition==="left"}])},[e.required?(i.openBlock(),i.createElementBlock("span",gs,"*")):i.createCommentVNode("",!0),i.createTextVNode(" "+i.toDisplayString(e.label),1)],2)):i.createCommentVNode("",!0),i.createElementVNode("span",ys,[i.withDirectives(i.createVNode(s,{name:"checkmark-sharp"},null,512),[[i.vShow,a.checked&&!r.indeterminate]]),i.withDirectives(i.createVNode(s,{class:i.normalizeClass("checkbox-undeterminate-icon"),name:"remove-sharp"},null,512),[[i.vShow,r.indeterminate]])]),e.labelPosition==="right"&&((d=e.label)!=null&&d.length)?(i.openBlock(),i.createElementBlock("span",vs,[e.required?(i.openBlock(),i.createElementBlock("span",bs,"*")):i.createCommentVNode("",!0),i.createTextVNode(" "+i.toDisplayString(e.label),1)])):i.createCommentVNode("",!0)])],16,hs)],10,fs)}const _r=_e(us,[["render",_s]]),E1="",$s={name:"IbToggle",model:{prop:"isChecked",event:"input"},props:{isChecked:{type:Boolean,required:!1},id:{type:String,default:()=>ht()},disabled:{type:Boolean,default:!1},name:{type:String,default:"active"},label:{type:String,default:""},error:{type:Boolean,default:!1},labelPosition:{type:String,default:"right"},helpMessage:{type:String,default:""},helpMessageOff:{type:String,default:""}},watch:{isChecked(t){this.checked=t}},data(){return{checked:this.isChecked}},methods:{onChange(){this.disabled||(this.checked=!this.checked,this.$emit("input",this.checked))}},computed:{classes(){return{"ib-toggle-container":!0,"has-error":this.error,"toggle-on":this.checked,"toggle-disabled":this.disabled,"label-position-left":this.labelPosition==="left"}}},components:{IbIcon:Le,IbTooltip:jt}},ws=["aria-checked","tabindex"],ks={class:"toggle-wrapper",ref:"wrapper"},Cs={class:"toggle",ref:"toggle"},Os=["name","checked","id","disabled"],Es=i.createElementVNode("span",{class:"toggle-slider round"},null,-1),Ss={key:0,class:"toggle-label"};function Ts(t,n,e,o,a,r){const s=i.resolveComponent("ib-icon"),d=i.resolveComponent("ib-tooltip");return i.openBlock(),i.createElementBlock("label",{role:"switch","aria-checked":a.checked,tabindex:e.disabled?-1:0,class:i.normalizeClass(r.classes),onKeypress:[n[2]||(n[2]=i.withKeys(i.withModifiers((...u)=>r.onChange&&r.onChange(...u),["prevent"]),["space"])),n[3]||(n[3]=i.withKeys(i.withModifiers((...u)=>r.onChange&&r.onChange(...u),["prevent"]),["enter"]))]},[i.createElementVNode("div",ks,[i.createElementVNode("div",Cs,[i.createElementVNode("input",{tabindex:"-1",type:"checkbox",value:"1",name:e.name,checked:a.checked,id:e.id,disabled:e.disabled,onClick:n[0]||(n[0]=(...u)=>r.onChange&&r.onChange(...u)),onInput:n[1]||(n[1]=i.withModifiers(()=>{},["stop"]))},null,40,Os),Es,i.createVNode(s,{class:"checked-icon",name:"checkmark"}),i.createVNode(s,{class:"unchecked-icon",name:"close"})],512)],512),e.label.length?(i.openBlock(),i.createElementBlock("span",Ss,i.toDisplayString(e.label),1)):i.createCommentVNode("",!0),e.helpMessage.length?(i.openBlock(),i.createBlock(d,{key:1,text:a.checked?e.helpMessage:e.helpMessageOff.length?e.helpMessageOff:e.helpMessage},null,8,["text"])):i.createCommentVNode("",!0)],42,ws)}const Ii=_e($s,[["render",Ts]]);function Mi(t){return t.scrollHeight>t.clientHeight}const S1="",Ns={name:"select-option",props:{option:{type:Object},name:String,parentAutoCheck:{type:Boolean,default:!1},isMultiple:{type:Boolean,default:!0},uid:{type:String,default:""},onlyEndNodes:{type:Boolean,default:!1},htmlTitle:{type:Boolean,default:!1},showInput:{type:Boolean,default:!0},isBookmarkable:{type:Boolean,default:!1},isBookmarked:{type:Boolean,default:!1},isToggle:{type:Boolean,default:!1}},mounted(){this.option.hasOwnProperty("children")&&this.option.children&&this.checkParent()},updated(){this.$nextTick(()=>{Mi(this.$el.querySelector(".option-label"))&&(this.showTooltip=!0)})},data(){return{showTooltip:!1}},methods:{onKeydown(t){t.keyCode===Ci&&(t.preventDefault(),this.onChange()),this.hasVisibleChildren&&(t.keyCode===Ua&&(this.option.isChildrenVisible=!0),t.keyCode===za&&(this.option.isChildrenVisible=!1))},onChange(){var t,n;!this.isMultiple&&!this.isChecked(this.option)&&((t=this.$refs.component)==null||t.onChange()),this.isMultiple&&((n=this.$refs.component)==null||n.onChange())},toggle(t,n=!0){this.check(this.option,t,!0,n)},check(t,n,e,o){this.$emit("check",t,n,e),o&&t.children&&t.children.forEach(a=>{this.check(a,n,!1,!0)})},toggleChildrenVisibility(){this.option.isChildrenVisible=!this.option.isChildrenVisible},checkChildren(t,n,e){e&&this.isMultiple&&this.$nextTick(()=>{this.checkParent()}),this.$emit("check",t,n,!1)},checkParent(){const t=this.option.children.filter(e=>e.checked).length,n=t>=this.option.children.length;(!this.option.checked&&n&&this.parentAutoCheck||this.option.checked&&!n)&&this.toggle(!this.option.checked,!1)},calculateChildren(t,n,e=!1){let o=0;return t.children&&t.children.forEach(a=>{(!n||n(a))&&o++,e&&(o+=this.calculateChildren(a,n,e))}),o},isChecked(t){if(this.hasChildren)if(this.childrenSelectedCount){if(this.childrenSelectedCount>0&&this.countOfAllChildren>this.childrenSelectedCount)return null}else return!1;return t.checked?!0:t.isIndeterminate?null:!1}},computed:{component(){return this.isMultiple&&this.isToggle?Ii:_r},hasChildren(){return!!(this.option.children&&this.option.children.length)},hasVisibleChildren(){return this.calculateChildren(this.option,t=>t.visible)},iconName(){return this.option.isChildrenVisible?"chevron-down":"chevron-forward"},id(){return this.uid+"_"+this.option.id},actualName(){return this.onlyEndNodes&&this.option.children&&this.option.children.length?"":this.name},childrenSelectedCount(){return this.calculateChildren(this.option,t=>t.checked,!0)},countOfAllChildren(){return this.calculateChildren(this.option,()=>!0,!0)}},components:{IbIcon:Le,List:mr,IbIconButton:ut},directives:{Tooltip:yr}},xs=["aria-selected","aria-label","id"],As={key:0,class:"option-label"},Ds={key:1,class:"option-label"},Is=["innerHTML"],Ms=["innerHTML"],Ps={key:2,class:"option-label"};function Bs(t,n,e,o,a,r){const s=i.resolveComponent("ib-icon"),d=i.resolveComponent("ib-icon-button"),u=i.resolveComponent("select-option"),p=i.resolveComponent("list"),h=i.resolveDirective("tooltip");return i.openBlock(),i.createElementBlock("li",null,[i.withDirectives((i.openBlock(),i.createElementBlock("div",{class:i.normalizeClass(["tree-select-option",{"tree-select-option-checked":r.isChecked(e.option),"tree-select-option-margin":r.hasVisibleChildren,active:e.option.isChildrenVisible,"is-multiple":e.isMultiple,"is-not-multiple":!e.isMultiple,"tree-select-option-toggle":this.isToggle&&this.isMultiple}]),tabindex:"0",role:"option","aria-selected":r.isChecked(e.option),"aria-label":e.option.title,id:"option-"+r.id,onKeydown:n[3]||(n[3]=i.withModifiers((...f)=>r.onKeydown&&r.onKeydown(...f),["self"])),onFocus:n[4]||(n[4]=f=>t.$emit("onFocus",`option-${r.id}`))},[i.withDirectives(i.createVNode(d,{"disabled-focus":!0,kind:"ghost",class:"toggle-children",onClick:r.toggleChildrenVisibility},{default:i.withCtx(()=>[i.createVNode(s,{name:r.iconName},null,8,["name"])]),_:1},8,["onClick"]),[[i.vShow,r.hasVisibleChildren]]),i.createElementVNode("div",{onClick:n[1]||(n[1]=i.withModifiers((...f)=>r.onChange&&r.onChange(...f),["prevent"])),class:i.normalizeClass({disabled:e.option.isDisabled,"tree-select-option-label":!0,"tree-select-option-has-children":r.hasVisibleChildren,active:!e.showInput&&e.option.checked})},[i.withDirectives((i.openBlock(),i.createBlock(i.resolveDynamicComponent(r.component),{ref:"component",tabindex:"-1","disable-focus":"","aria-label":e.option.title,name:r.actualName,value:e.option.id,id:"input"+r.id,"is-checked":r.isChecked(e.option),disabled:e.option.isDisabled,readonly:e.option.readonly,autocomplete:"off",autocorrect:"off",autocapitalize:"off",spellcheck:"false",onInput:r.toggle},null,40,["aria-label","name","value","id","is-checked","disabled","readonly","onInput"])),[[i.vShow,e.showInput]]),e.isBookmarkable?(i.openBlock(),i.createElementBlock("span",{key:0,class:i.normalizeClass("bookmarkable-option-title "+(e.isBookmarked?"bookmarked":""))},[r.hasChildren?(i.openBlock(),i.createElementBlock("span",Ds,i.toDisplayString(e.option.title),1)):(i.openBlock(),i.createElementBlock("span",As,[i.createTextVNode(i.toDisplayString(e.option.title)+" ",1),i.createVNode(s,{name:"star",onClick:n[0]||(n[0]=i.withModifiers(f=>t.$emit("toggle-bookmark",e.option),["stop","prevent"]))})]))],2)):e.htmlTitle?(i.openBlock(),i.createElementBlock(i.Fragment,{key:1},[r.hasChildren?(i.openBlock(),i.createElementBlock("span",{key:1,class:"option-label",innerHTML:e.option.title},null,8,Ms)):(i.openBlock(),i.createElementBlock("span",{key:0,class:"option-label",innerHTML:e.option.title},null,8,Is))],64)):(i.openBlock(),i.createElementBlock("span",Ps,i.toDisplayString(e.option.title),1))],2),r.hasChildren?i.withDirectives((i.openBlock(),i.createBlock(p,{key:0},{default:i.withCtx(()=>[(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(e.option.children,f=>i.withDirectives((i.openBlock(),i.createBlock(u,{key:f.value,option:f,name:e.name,"parent-auto-check":e.parentAutoCheck,"is-multiple":e.isMultiple,"show-input":e.showInput,onCheck:r.checkChildren,onToggleBookmark:n[2]||(n[2]=l=>t.$emit("toggle-bookmark",l)),uid:e.uid,"is-bookmarkable":e.isBookmarkable},null,8,["option","name","parent-auto-check","is-multiple","show-input","onCheck","uid","is-bookmarkable"])),[[i.vShow,f.visible]])),128))]),_:1},512)),[[i.vShow,r.hasVisibleChildren&&e.option.isChildrenVisible]]):i.createCommentVNode("",!0)],42,xs)),[[h,a.showTooltip?e.option.title:""]])])}const Ls=_e(Ns,[["render",Bs]]);var qe=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function jn(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var Pi={exports:{}};/*!***************************************************
|
|
22
22
|
* mark.js v8.11.1
|
|
23
23
|
* https://markjs.io/
|
|
24
24
|
* Copyright (c) 2014–2018, Julian Kühnel
|
|
25
25
|
* Released under the MIT license https://git.io/vwTVl
|
|
26
|
-
*****************************************************/(function(t,n){(function(e,o){t.exports=o()})(qe,function(){class e{constructor(r,s=!0,d=[],u=5e3){this.ctx=r,this.iframes=s,this.exclude=d,this.iframesTimeout=u}static matches(r,s){const d=typeof s=="string"?[s]:s,u=r.matches||r.matchesSelector||r.msMatchesSelector||r.mozMatchesSelector||r.oMatchesSelector||r.webkitMatchesSelector;if(u){let p=!1;return d.every(h=>!u.call(r,h)||(p=!0,!1)),p}return!1}getContexts(){let r=[];return(this.ctx!==void 0&&this.ctx?NodeList.prototype.isPrototypeOf(this.ctx)?Array.prototype.slice.call(this.ctx):Array.isArray(this.ctx)?this.ctx:typeof this.ctx=="string"?Array.prototype.slice.call(document.querySelectorAll(this.ctx)):[this.ctx]:[]).forEach(s=>{const d=r.filter(u=>u.contains(s)).length>0;r.indexOf(s)!==-1||d||r.push(s)}),r}getIframeContents(r,s,d=()=>{}){let u;try{const p=r.contentWindow;if(u=p.document,!p||!u)throw new Error("iframe inaccessible")}catch{d()}u&&s(u)}isIframeBlank(r){const s="about:blank",d=r.getAttribute("src").trim();return r.contentWindow.location.href===s&&d!==s&&d}observeIframeLoad(r,s,d){let u=!1,p=null;const h=()=>{if(!u){u=!0,clearTimeout(p);try{this.isIframeBlank(r)||(r.removeEventListener("load",h),this.getIframeContents(r,s,d))}catch{d()}}};r.addEventListener("load",h),p=setTimeout(h,this.iframesTimeout)}onIframeReady(r,s,d){try{r.contentWindow.document.readyState==="complete"?this.isIframeBlank(r)?this.observeIframeLoad(r,s,d):this.getIframeContents(r,s,d):this.observeIframeLoad(r,s,d)}catch{d()}}waitForIframes(r,s){let d=0;this.forEachIframe(r,()=>!0,u=>{d++,this.waitForIframes(u.querySelector("html"),()=>{--d||s()})},u=>{u||s()})}forEachIframe(r,s,d,u=()=>{}){let p=r.querySelectorAll("iframe"),h=p.length,f=0;p=Array.prototype.slice.call(p);const l=()=>{--h<=0&&u(f)};h||l(),p.forEach(c=>{e.matches(c,this.exclude)?l():this.onIframeReady(c,_=>{s(c)&&(f++,d(_)),l()},l)})}createIterator(r,s,d){return document.createNodeIterator(r,s,d,!1)}createInstanceOnIframe(r){return new e(r.querySelector("html"),this.iframes)}compareNodeIframe(r,s,d){const u=r.compareDocumentPosition(d),p=Node.DOCUMENT_POSITION_PRECEDING;return!!(u&p&&(s===null||s.compareDocumentPosition(d)&Node.DOCUMENT_POSITION_FOLLOWING))}getIteratorNode(r){const s=r.previousNode();return{prevNode:s,node:(s===null||r.nextNode())&&r.nextNode()}}checkIframeFilter(r,s,d,u){let p=!1,h=!1;return u.forEach((f,l)=>{f.val===d&&(p=l,h=f.handled)}),this.compareNodeIframe(r,s,d)?(p!==!1||h?p===!1||h||(u[p].handled=!0):u.push({val:d,handled:!0}),!0):(p===!1&&u.push({val:d,handled:!1}),!1)}handleOpenIframes(r,s,d,u){r.forEach(p=>{p.handled||this.getIframeContents(p.val,h=>{this.createInstanceOnIframe(h).forEachNode(s,d,u)})})}iterateThroughNodes(r,s,d,u,p){const h=this.createIterator(s,r,u);let f,l,c=[],_=[],v=()=>({prevNode:l,node:f}=this.getIteratorNode(h),f);for(;v();)this.iframes&&this.forEachIframe(s,b=>this.checkIframeFilter(f,l,b,c),b=>{this.createInstanceOnIframe(b).forEachNode(r,g=>_.push(g),u)}),_.push(f);_.forEach(b=>{d(b)}),this.iframes&&this.handleOpenIframes(c,r,d,u),p()}forEachNode(r,s,d,u=()=>{}){const p=this.getContexts();let h=p.length;h||u(),p.forEach(f=>{const l=()=>{this.iterateThroughNodes(r,f,s,d,()=>{--h<=0&&u()})};this.iframes?this.waitForIframes(f,l):l()})}}class o{constructor(r){this.ctx=r,this.ie=!1;const s=window.navigator.userAgent;(s.indexOf("MSIE")>-1||s.indexOf("Trident")>-1)&&(this.ie=!0)}set opt(r){this._opt=Object.assign({},{element:"",className:"",exclude:[],iframes:!1,iframesTimeout:5e3,separateWordSearch:!0,diacritics:!0,synonyms:{},accuracy:"partially",acrossElements:!1,caseSensitive:!1,ignoreJoiners:!1,ignoreGroups:0,ignorePunctuation:[],wildcards:"disabled",each:()=>{},noMatch:()=>{},filter:()=>!0,done:()=>{},debug:!1,log:window.console},r)}get opt(){return this._opt}get iterator(){return new e(this.ctx,this.opt.iframes,this.opt.exclude,this.opt.iframesTimeout)}log(r,s="debug"){const d=this.opt.log;this.opt.debug&&typeof d=="object"&&typeof d[s]=="function"&&d[s](`mark.js: ${r}`)}escapeStr(r){return r.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&")}createRegExp(r){return this.opt.wildcards!=="disabled"&&(r=this.setupWildcardsRegExp(r)),r=this.escapeStr(r),Object.keys(this.opt.synonyms).length&&(r=this.createSynonymsRegExp(r)),(this.opt.ignoreJoiners||this.opt.ignorePunctuation.length)&&(r=this.setupIgnoreJoinersRegExp(r)),this.opt.diacritics&&(r=this.createDiacriticsRegExp(r)),r=this.createMergedBlanksRegExp(r),(this.opt.ignoreJoiners||this.opt.ignorePunctuation.length)&&(r=this.createJoinersRegExp(r)),this.opt.wildcards!=="disabled"&&(r=this.createWildcardsRegExp(r)),r=this.createAccuracyRegExp(r)}createSynonymsRegExp(r){const s=this.opt.synonyms,d=this.opt.caseSensitive?"":"i",u=this.opt.ignoreJoiners||this.opt.ignorePunctuation.length?"\0":"";for(let p in s)if(s.hasOwnProperty(p)){const h=s[p],f=this.opt.wildcards!=="disabled"?this.setupWildcardsRegExp(p):this.escapeStr(p),l=this.opt.wildcards!=="disabled"?this.setupWildcardsRegExp(h):this.escapeStr(h);f!==""&&l!==""&&(r=r.replace(new RegExp(`(${this.escapeStr(f)}|${this.escapeStr(l)})`,`gm${d}`),u+`(${this.processSynomyms(f)}|${this.processSynomyms(l)})`+u))}return r}processSynomyms(r){return(this.opt.ignoreJoiners||this.opt.ignorePunctuation.length)&&(r=this.setupIgnoreJoinersRegExp(r)),r}setupWildcardsRegExp(r){return(r=r.replace(/(?:\\)*\?/g,s=>s.charAt(0)==="\\"?"?":"")).replace(/(?:\\)*\*/g,s=>s.charAt(0)==="\\"?"*":"")}createWildcardsRegExp(r){let s=this.opt.wildcards==="withSpaces";return r.replace(/\u0001/g,s?"[\\S\\s]?":"\\S?").replace(/\u0002/g,s?"[\\S\\s]*?":"\\S*")}setupIgnoreJoinersRegExp(r){return r.replace(/[^(|)\\]/g,(s,d,u)=>{let p=u.charAt(d+1);return/[(|)\\]/.test(p)||p===""?s:s+"\0"})}createJoinersRegExp(r){let s=[];const d=this.opt.ignorePunctuation;return Array.isArray(d)&&d.length&&s.push(this.escapeStr(d.join(""))),this.opt.ignoreJoiners&&s.push("\\u00ad\\u200b\\u200c\\u200d"),s.length?r.split(/\u0000+/).join(`[${s.join("")}]*`):r}createDiacriticsRegExp(r){const s=this.opt.caseSensitive?"":"i",d=this.opt.caseSensitive?["aàáảãạăằắẳẵặâầấẩẫậäåāą","AÀÁẢÃẠĂẰẮẲẴẶÂẦẤẨẪẬÄÅĀĄ","cçćč","CÇĆČ","dđď","DĐĎ","eèéẻẽẹêềếểễệëěēę","EÈÉẺẼẸÊỀẾỂỄỆËĚĒĘ","iìíỉĩịîïī","IÌÍỈĨỊÎÏĪ","lł","LŁ","nñňń","NÑŇŃ","oòóỏõọôồốổỗộơởỡớờợöøō","OÒÓỎÕỌÔỒỐỔỖỘƠỞỠỚỜỢÖØŌ","rř","RŘ","sšśșş","SŠŚȘŞ","tťțţ","TŤȚŢ","uùúủũụưừứửữựûüůū","UÙÚỦŨỤƯỪỨỬỮỰÛÜŮŪ","yýỳỷỹỵÿ","YÝỲỶỸỴŸ","zžżź","ZŽŻŹ"]:["aàáảãạăằắẳẵặâầấẩẫậäåāąAÀÁẢÃẠĂẰẮẲẴẶÂẦẤẨẪẬÄÅĀĄ","cçćčCÇĆČ","dđďDĐĎ","eèéẻẽẹêềếểễệëěēęEÈÉẺẼẸÊỀẾỂỄỆËĚĒĘ","iìíỉĩịîïīIÌÍỈĨỊÎÏĪ","lłLŁ","nñňńNÑŇŃ","oòóỏõọôồốổỗộơởỡớờợöøōOÒÓỎÕỌÔỒỐỔỖỘƠỞỠỚỜỢÖØŌ","rřRŘ","sšśșşSŠŚȘŞ","tťțţTŤȚŢ","uùúủũụưừứửữựûüůūUÙÚỦŨỤƯỪỨỬỮỰÛÜŮŪ","yýỳỷỹỵÿYÝỲỶỸỴŸ","zžżźZŽŻŹ"];let u=[];return r.split("").forEach(p=>{d.every(h=>{if(h.indexOf(p)!==-1){if(u.indexOf(h)>-1)return!1;r=r.replace(new RegExp(`[${h}]`,`gm${s}`),`[${h}]`),u.push(h)}return!0})}),r}createMergedBlanksRegExp(r){return r.replace(/[\s]+/gim,"[\\s]+")}createAccuracyRegExp(r){const s="!\"#$%&'()*+,-./:;<=>?@[\\]^_`{|}~¡¿";let d=this.opt.accuracy,u=typeof d=="string"?d:d.value,p=typeof d=="string"?[]:d.limiters,h="";switch(p.forEach(f=>{h+=`|${this.escapeStr(f)}`}),u){case"partially":default:return`()(${r})`;case"complementary":return`()([^${h="\\s"+(h||this.escapeStr(s))}]*${r}[^${h}]*)`;case"exactly":return`(^|\\s${h})(${r})(?=$|\\s${h})`}}getSeparatedKeywords(r){let s=[];return r.forEach(d=>{this.opt.separateWordSearch?d.split(" ").forEach(u=>{u.trim()&&s.indexOf(u)===-1&&s.push(u)}):d.trim()&&s.indexOf(d)===-1&&s.push(d)}),{keywords:s.sort((d,u)=>u.length-d.length),length:s.length}}isNumeric(r){return Number(parseFloat(r))==r}checkRanges(r){if(!Array.isArray(r)||Object.prototype.toString.call(r[0])!=="[object Object]")return this.log("markRanges() will only accept an array of objects"),this.opt.noMatch(r),[];const s=[];let d=0;return r.sort((u,p)=>u.start-p.start).forEach(u=>{let{start:p,end:h,valid:f}=this.callNoMatchOnInvalidRanges(u,d);f&&(u.start=p,u.length=h-p,s.push(u),d=h)}),s}callNoMatchOnInvalidRanges(r,s){let d,u,p=!1;return r&&r.start!==void 0?(u=(d=parseInt(r.start,10))+parseInt(r.length,10),this.isNumeric(r.start)&&this.isNumeric(r.length)&&u-s>0&&u-d>0?p=!0:(this.log(`Ignoring invalid or overlapping range: ${JSON.stringify(r)}`),this.opt.noMatch(r))):(this.log(`Ignoring invalid range: ${JSON.stringify(r)}`),this.opt.noMatch(r)),{start:d,end:u,valid:p}}checkWhitespaceRanges(r,s,d){let u,p=!0,h=d.length,f=s-h,l=parseInt(r.start,10)-f;return(u=(l=l>h?h:l)+parseInt(r.length,10))>h&&(u=h,this.log(`End range automatically set to the max value of ${h}`)),l<0||u-l<0||l>h||u>h?(p=!1,this.log(`Invalid range: ${JSON.stringify(r)}`),this.opt.noMatch(r)):d.substring(l,u).replace(/\s+/g,"")===""&&(p=!1,this.log("Skipping whitespace only range: "+JSON.stringify(r)),this.opt.noMatch(r)),{start:l,end:u,valid:p}}getTextNodes(r){let s="",d=[];this.iterator.forEachNode(NodeFilter.SHOW_TEXT,u=>{d.push({start:s.length,end:(s+=u.textContent).length,node:u})},u=>this.matchesExclude(u.parentNode)?NodeFilter.FILTER_REJECT:NodeFilter.FILTER_ACCEPT,()=>{r({value:s,nodes:d})})}matchesExclude(r){return e.matches(r,this.opt.exclude.concat(["script","style","title","head","html"]))}wrapRangeInTextNode(r,s,d){const u=this.opt.element?this.opt.element:"mark",p=r.splitText(s),h=p.splitText(d-s);let f=document.createElement(u);return f.setAttribute("data-markjs","true"),this.opt.className&&f.setAttribute("class",this.opt.className),f.textContent=p.textContent,p.parentNode.replaceChild(f,p),h}wrapRangeInMappedTextNode(r,s,d,u,p){r.nodes.every((h,f)=>{const l=r.nodes[f+1];if(l===void 0||l.start>s){if(!u(h.node))return!1;const c=s-h.start,_=(d>h.end?h.end:d)-h.start,v=r.value.substr(0,h.start),b=r.value.substr(_+h.start);if(h.node=this.wrapRangeInTextNode(h.node,c,_),r.value=v+b,r.nodes.forEach((g,y)=>{y>=f&&(r.nodes[y].start>0&&y!==f&&(r.nodes[y].start-=_),r.nodes[y].end-=_)}),d-=_,p(h.node.previousSibling,h.start),!(d>h.end))return!1;s=h.end}return!0})}wrapMatches(r,s,d,u,p){const h=s===0?0:s+1;this.getTextNodes(f=>{f.nodes.forEach(l=>{let c;for(l=l.node;(c=r.exec(l.textContent))!==null&&c[h]!=="";){if(!d(c[h],l))continue;let _=c.index;if(h!==0)for(let v=1;v<h;v++)_+=c[v].length;l=this.wrapRangeInTextNode(l,_,_+c[h].length),u(l.previousSibling),r.lastIndex=0}}),p()})}wrapMatchesAcrossElements(r,s,d,u,p){const h=s===0?0:s+1;this.getTextNodes(f=>{let l;for(;(l=r.exec(f.value))!==null&&l[h]!=="";){let c=l.index;if(h!==0)for(let v=1;v<h;v++)c+=l[v].length;const _=c+l[h].length;this.wrapRangeInMappedTextNode(f,c,_,v=>d(l[h],v),(v,b)=>{r.lastIndex=b,u(v)})}p()})}wrapRangeFromIndex(r,s,d,u){this.getTextNodes(p=>{const h=p.value.length;r.forEach((f,l)=>{let{start:c,end:_,valid:v}=this.checkWhitespaceRanges(f,h,p.value);v&&this.wrapRangeInMappedTextNode(p,c,_,b=>s(b,f,p.value.substring(c,_),l),b=>{d(b,f)})}),u()})}unwrapMatches(r){const s=r.parentNode;let d=document.createDocumentFragment();for(;r.firstChild;)d.appendChild(r.removeChild(r.firstChild));s.replaceChild(d,r),this.ie?this.normalizeTextNode(s):s.normalize()}normalizeTextNode(r){if(r){if(r.nodeType===3)for(;r.nextSibling&&r.nextSibling.nodeType===3;)r.nodeValue+=r.nextSibling.nodeValue,r.parentNode.removeChild(r.nextSibling);else this.normalizeTextNode(r.firstChild);this.normalizeTextNode(r.nextSibling)}}markRegExp(r,s){this.opt=s,this.log(`Searching with expression "${r}"`);let d=0,u="wrapMatches";const p=h=>{d++,this.opt.each(h)};this.opt.acrossElements&&(u="wrapMatchesAcrossElements"),this[u](r,this.opt.ignoreGroups,(h,f)=>this.opt.filter(f,h,d),p,()=>{d===0&&this.opt.noMatch(r),this.opt.done(d)})}mark(r,s){this.opt=s;let d=0,u="wrapMatches";const{keywords:p,length:h}=this.getSeparatedKeywords(typeof r=="string"?[r]:r),f=this.opt.caseSensitive?"":"i",l=c=>{let _=new RegExp(this.createRegExp(c),`gm${f}`),v=0;this.log(`Searching with expression "${_}"`),this[u](_,1,(b,g)=>this.opt.filter(g,c,d,v),b=>{v++,d++,this.opt.each(b)},()=>{v===0&&this.opt.noMatch(c),p[h-1]===c?this.opt.done(d):l(p[p.indexOf(c)+1])})};this.opt.acrossElements&&(u="wrapMatchesAcrossElements"),h===0?this.opt.done(d):l(p[0])}markRanges(r,s){this.opt=s;let d=0,u=this.checkRanges(r);u&&u.length?(this.log("Starting to mark with the following ranges: "+JSON.stringify(u)),this.wrapRangeFromIndex(u,(p,h,f,l)=>this.opt.filter(p,h,f,l),(p,h)=>{d++,this.opt.each(p,h)},()=>{this.opt.done(d)})):this.opt.done(d)}unmark(r){this.opt=r;let s=this.opt.element?this.opt.element:"*";s+="[data-markjs]",this.opt.className&&(s+=`.${this.opt.className}`),this.log(`Removal selector "${s}"`),this.iterator.forEachNode(NodeFilter.SHOW_ELEMENT,d=>{this.unwrapMatches(d)},d=>{const u=e.matches(d,s),p=this.matchesExclude(d);return!u||p?NodeFilter.FILTER_REJECT:NodeFilter.FILTER_ACCEPT},this.opt.done)}}return function(a){const r=new o(a);return this.mark=(s,d)=>(r.mark(s,d),this),this.markRegExp=(s,d)=>(r.markRegExp(s,d),this),this.markRanges=(s,d)=>(r.markRanges(s,d),this),this.unmark=s=>(r.unmark(s),this),this}})})(Pi);var Rs=Pi.exports;const js=jn(Rs),T1="";function Bi(t){return JSON.parse(JSON.stringify(t))}const Vs={name:"IbTreeSelect",inject:["LANG_COMPONENTS"],props:{classList:[String,Array],placeholder:{type:String,default:""},searchPlaceholderText:{type:String,default:""},clearButtonMessage:{type:String,default:""},showClearButton:{type:Boolean,default:!0},isResizable:{type:Boolean,default:!1},menuSize:{type:[String,Number]},initialSize:{left:0,right:0},ariaLabel:{type:String,default:""},name:String,id:{type:String,default(){return ht()}},options:{default(){return[]}},modelValue:{type:[Number,String,Array]},value:{type:[Number,String,Array],default(){return[]}},maxSelectedNames:{type:Number,default:2},isMultiple:{type:Boolean,default:!0},parentAutoCheck:{type:Boolean,default:!0},strings:{type:Object,default(){return{}}},onlyEndNodes:{type:Boolean,default:!1},isRequired:{type:Boolean,default:!0},htmlOptionTitle:{type:Boolean,default:!1},isBookmarkable:{type:Boolean,default:!1},initBookmarks:{type:Array,default:()=>[]},showInputs:{type:Boolean,default(t){return t.isMultiple}},dependency:{type:String},filterId:{type:String,default(){return ht()}},staticPlaceholder:{type:Boolean,default:!1},useSearch:{type:Boolean,default:!1},isWatching:{type:Boolean,default:!1},emptyMessage:{type:String,default:""},errorMessage:{type:String,default:""},allOptions:{type:Boolean,default:!0},watchClearValue:{type:Boolean,default:!1},isToggle:{type:Boolean,default:!1},alphabetSort:{type:Boolean,default:!1}},emits:["close","input","blur","search","resize","submit","clearValue","update:modelValue"],watch:{value(t){this.val=t,(!Array.isArray(t)||t.join(",")!==Object.keys(this.selected).join(","))&&this.setPreparedValues(this.actualOptions,!1)},modelValue:{handler(t){this.val=t,this.actualOptions=[],this.setPreparedValues()},deep:!0},val(t){this.watchClearValue&&(!t||Array.isArray(t)&&!t.length)&&this.setPreparedValues(this.actualOptions).then(()=>{const n=Object.keys(this.selected);this.$globalEvents.$emit("select-"+this.filterId+":update",{values:n,filter:this.filterId})})},options:{handler(t){this.initialOptions=Bi(t)},deep:!0},initialOptions(t){let n=!0;if(typeof t=="function")n=!1;else{const e=[],o=t;Array.prototype.forEach.call(o,a=>{a.id!==void 0&&e.push(a.id)}),n=JSON.stringify(e)===JSON.stringify(this.optionsIdsWatch),this.optionsIdsWatch=e}(this.isInitialized&&!n||this.isWatching)&&this.setPreparedValues().then(()=>{const e=Object.keys(this.selected);this.$globalEvents.$emit("select-"+this.filterId+":update",{values:e,filter:this.filterId})})},dependency(t,n){this.$nextTick(()=>{this.registerDependency(n)})},initBookmarks(){this.actualBookmarkedOptions={},this.setBookmarkedOptions(this.actualOptions)}},mounted(){this.marker=new js(this.$refs.list.$el),this.registerDependency(),this.$globalEvents.$on("select:refresh",()=>{this.setPreparedValues()}),document.addEventListener("mousemove",this.onResize),document.addEventListener("mouseup",this.endResizing)},data(){var t,n,e,o,a,r,s,d;return this.defaultFilter=u=>{this.marker.unmark();const p=this.filterString.toLowerCase().trim();this.filterFunc.call(this,u,p),p&&this.marker.mark(p)},{initialOptions:Bi(this.options),val:this.modelValue?this.modelValue:this.value,size:{left:this.initialSize&&this.initialSize.left||0,right:this.initialSize&&this.initialSize.right||0},resizingProp:null,isInitialized:!1,optionsIdsWatch:[],isLoading:!1,actualName:this.isMultiple?this.name+"[]":this.name,filterString:"",actualOptions:[],actualBookmarkedOptions:{},selected:[],isOpen:!1,vertical:"bottom",allOptionsIsChecked:!0,hasTreeChildren:!1,uid:`f${(~~(Math.random()*1e8)).toString(16)}`,focusedOptionId:"",actualStrings:{searchPlaceholder:lang(this.searchPlaceholderText.length?this.searchPlaceholderText:"search_placeholder",(t=this.LANG_COMPONENTS)==null?void 0:t.COMPONENT_SELECT),emptyTitle:lang("empty_title",(n=this.LANG_COMPONENTS)==null?void 0:n.COMPONENT_SELECT),selectAllOptions:lang("all_options",(e=this.LANG_COMPONENTS)==null?void 0:e.COMPONENT_SELECT),allSelected:lang("all_selected",(o=this.LANG_COMPONENTS)==null?void 0:o.COMPONENT_SELECT),loading:lang("loading",(a=this.LANG_COMPONENTS)==null?void 0:a.COMPONENT_SELECT)+"...",selectedCount:lang("selected_count",(r=this.LANG_COMPONENTS)==null?void 0:r.COMPONENT_SELECT),buttonTitle:this.buttonTitle||lang("button_title",(s=this.LANG_COMPONENTS)==null?void 0:s.COMPONENT_SELECT),requiredDependencyNotFilled:this.requiredDependencyNotFilled||lang("required_dependency_are_not_filled",(d=this.LANG_COMPONENTS)==null?void 0:d.COMPONENT_SELECT),...this.strings},dependencyValue:null}},methods:{onBlur(){setTimeout(()=>{this.isOpen||this.$emit("blur")},200)},inputKeyupDown(){this.focusOnFirstOptions()},comboboxKeyupDown(){if(this.showSearch){this.$refs.search.focus();return}this.focusOnFirstOptions()},focus(){this.$refs.combobox.focus()},focusOnFirstOptions(){this.$refs.list.$el.querySelector("[tabindex]:not(hidden)").focus()},startResizing(t){this.resizingProp=t},endResizing(){this.resizingProp&&(this.resizingProp=null,this.$emit("resize",this.size))},onResize(t){switch(this.resizingProp){case"left":this.size.left=Math.max(this.size.left-t.movementX,0);break;case"right":this.size.right=Math.max(this.size.right+t.movementX,0);break}},registerDependency(t){this.dependency?(this.$globalEvents.$on("select-"+this.dependency+":update",n=>{this.clear(),this.dependencyValue=n,this.dependencyValue&&this.dependencyValue.values&&(!Array.isArray(this.dependencyValue.values)||this.dependencyValue.values.length)&&this.setPreparedValues()}),this.isLoading=!1):(this.$globalEvents.$off("select-"+t+":update"),this.setPreparedValues().then(()=>{const n=Object.keys(this.selected);this.$globalEvents.$emit("select-"+this.filterId+":update",{values:n,filter:this.filterId})}))},filter(t,n){this.filterString=t,this.$emit("search",{search:this.filterString}),this.defaultFilter(n)},setPreparedValues(t){let n=t||this.initialOptions;return this.alphabetSort&&(n=n.sort((e,o)=>e.title.toLowerCase().localeCompare(o.title.toLowerCase()))),this.prepare(n).then(([e,o])=>{this.actualOptions=e,this.allOptionsIsChecked=this.checkIfOptionsChecked(e),this.isInitialized=!0,this.selected=o,this.setBookmarkedOptions(e)})},clear(){this.setPreparedValues(),this.allOptionsIsChecked=!1,this.selected=[],this.isMultiple?(this.$emit("update:modelValue",null),this.$emit("input",null),this.$emit("clear-value",null)):(this.$emit("update:modelValue",[]),this.$emit("input",[]),this.$emit("clear-value",[])),this.setPreparedValues()},clearValue(){this.clear(),this.setPreparedValues()},prepare(t){return new Promise(n=>{const e={},o=[];let a=Promise.resolve();typeof t=="function"?(this.isLoading=!0,this.dependency&&(t=t.bind(null,this.dependencyValue)),a=a.then(t)):a=a.then(()=>t),a.then(r=>(this.isLoading=!1,r.forEach(s=>{s.initiallyVisible=typeof s.visible>"u"?!0:s.visible,s.visible=s.initiallyVisible,s.readonly=!!s.readonly,s.isDisabled=!1,s.checked=this.isMultiple?this.val!==null&&this.val.findIndex(d=>s.id==d)>-1:this.val!==null&&this.val==s.id,s.checked&&(!this.onlyEndNodes||!s.children)&&(e[s.id]=s),s.children&&(this.hasTreeChildren=!0,s.isChildrenVisible=!1),o.push(new Promise(d=>{s.children?this.prepare(s.children).then(([u,p])=>{s.children=u,Object.assign(e,p),d(s)}):d(s)}))}),Promise.all(o).then(s=>{n([s,e])}))).catch(r=>{throw this.isLoading=!1,r})})},filterFunc(t,n){let e=0;return t.forEach(o=>{let a=o.initiallyVisible&&o.title&&o.title.toString().toLowerCase().includes(n)&&!this.actualBookmarkedOptions[o.id];if(o.children&&o.children.length){let r=this.filterFunc(o.children,n);e+=r,r&&(o.isChildrenVisible=!!n||!!Object.keys(this.actualBookmarkedOptions).length,o.isDisabled=r<o.children.length&&!this.isBookmarkable),a?r||(a=!1):a=!!r}o.visible=a,a&&e++}),e},submit(){this.change();const t=Object.keys(this.selected);this.$globalEvents.$emit("select-"+this.filterId+":submit",{values:t,filter:this.filterId}),this.$emit("submit")},change(){const t=Object.keys(this.selected);this.isMultiple?(this.$emit("update:modelValue",t),this.$emit("input",t)):(this.$emit("update:modelValue",t[0]),this.$emit("input",t[0])),this.$globalEvents.$emit("select-"+this.filterId+":update",{values:t,filter:this.filterId}),this.$refs.dropdown.close()},checkIfOptionsChecked(t){return t.every(n=>n.checked||n.readonly)},registerCheck(t,n,e){if(n)if(t.checked=!0,this.isMultiple)this.onlyEndNodes&&t.children&&t.children.length||(this.selected[t.id]=t,this.$emit("update:modelValue",Object.keys(this.selected)),this.$emit("input",Object.keys(this.selected)));else{const o=Object.keys(this.selected)[0];o&&(this.selected[o].checked=!1),this.selected={[t.id]:t},this.change()}else delete this.selected[t.id],t.checked=!1,this.$emit("update:modelValue",Object.keys(this.selected)),this.$emit("input",Object.keys(this.selected));this.toggleDuplicateOptions(this.actualOptions,t.id,n),e&&(this.allOptionsIsChecked=this.checkIfOptionsChecked(this.actualOptions))},toggleDuplicateOptions(t,n,e){for(let o of t)o.id===n&&(o.checked=e),o.children&&this.toggleDuplicateOptions(o.children,n,e)},manageAll(){this.allOptionsIsChecked=!this.allOptionsIsChecked,this.traverseTree(this.actualOptions,t=>{t.readonly||this.registerCheck(t,this.allOptionsIsChecked,!1)})},traverseTree(t,n){t.forEach(e=>{n(e),e.children&&e.children.length&&this.traverseTree(e.children,n)})},getArrayOptions(t){let n=[];for(let e of t)n.push(e),e.children&&(n=n.concat(this.getArrayOptions(e.children)));return n},toggleBookmark(t){this.actualBookmarkedOptions[t.id]?delete this.actualBookmarkedOptions[t.id]:this.actualBookmarkedOptions[t.id]=t,this.$emit("toggle-bookmarked-option",t.id),this.filter(this.filterString,this.actualOptions)},setBookmarkedOptions(t){t.forEach(n=>{n.children&&n.children.length?this.setBookmarkedOptions(n.children):this.initBookmarks.includes(n.id)&&(this.actualBookmarkedOptions[n.id]=n)}),this.filter(this.filterString,t)},onClose(){this.isOpen=!1,this.filter("",this.actualOptions),this.isMultiple?this.$emit("close",Object.keys(this.selected)):this.$emit("close",Object.keys(this.selected)[0]),this.$emit("blur"),this.vertical="bottom"},onOpen(){const t=document.documentElement.scrollHeight;this.isOpen=!0,this.$nextTick(()=>{document.documentElement.scrollHeight>t&&(this.vertical="top")})}},computed:{hasTrigger(){return!!this.$slots.trigger},hasTriggerContent(){return!!this.$slots.triggerContent},hasEmptyMessage(){return!!this.$slots.emptyMessage},treeDropPos(){return this.menuSize?{width:this.menuSize+"px",maxWidth:this.menuSize+"px",minWidth:this.menuSize+"px"}:{width:"auto",position:"absolute",left:-this.size.left+"px",right:-this.size.right+"px"}},hasHierarchy(){return this.actualOptions.some(t=>t.children)},selectedKeys(){return Object.keys(this.selected).filter(t=>{if(!this.onlyEndNodes||!this.selected[t].children)return!0})},selectStatus(){return this.staticPlaceholder?this.placeholder:this.isLoading?this.actualStrings.loading:this.selectedKeys.length?this.selectedKeys.length<this.maxSelectedNames?this.selectedKeys.map(t=>this.selected[t].title).join(","):this.selectedKeys.length<this.optionsCount?this.actualStrings.selectedCount.replace("{selected}",this.selectedKeys.length).replace("{all}",this.optionsCount):this.actualStrings.allSelected:this.emptyMessage},isEmpty(){return Array.isArray(this.value)?!this.value.length:!this.value},requiredDependencyNotFilled(){return this.dependency&&(!this.dependencyValue||!this.dependencyValue.values||!this.dependencyValue.values.length)},showSearch(){return this.useSearch||this.optionsCount>10},arrayOfOptions(){return this.getArrayOptions(this.actualOptions)},optionsCount(){let t=[];for(let n of this.arrayOfOptions)(!this.onlyEndNodes||!n.children)&&!t.includes(n.id)&&t.push(n.id);return t.length},visibleOptionsCount(){let t=[];return this.traverseTree(this.actualOptions,n=>{(!this.onlyEndNodes||!n.children)&&!t.includes(n.id)&&n.visible&&t.push(n.id)}),t.length+(this.isBookmarkable?Object.keys(this.actualBookmarkedOptions).length:0)}},components:{IbAlert:Pt,IbIconButton:ut,IbIcon:Le,IbDropdown:Ln,IbInput:br,List:mr,"select-option":Ls},beforeUnmount(){document.removeEventListener("mousemove",this.onResize),document.removeEventListener("mouseup",this.endResizing)}},qs={key:0,class:"tree-select-empty"},Fs={key:1,class:"tree-select-default-empty tree-select-empty"};function Hs(t,n,e,o,a,r){const s=i.resolveComponent("ib-alert"),d=i.resolveComponent("ib-icon"),u=i.resolveComponent("ib-icon-button"),p=i.resolveComponent("select-option"),h=i.resolveComponent("list"),f=i.resolveComponent("ib-input"),l=i.resolveComponent("ib-dropdown");return i.openBlock(),i.createElementBlock(i.Fragment,null,[e.errorMessage?(i.openBlock(),i.createBlock(s,{key:0,class:"tree-select-error"},{default:i.withCtx(()=>[i.createTextVNode(i.toDisplayString(e.errorMessage),1)]),_:1})):i.createCommentVNode("",!0),i.createElementVNode("div",{class:i.normalizeClass(["tree-select",{...e.classList,"tree-select-custom-trigger-content":r.hasTriggerContent}])},[i.createVNode(l,{disabled:a.isLoading,"is-resizable":e.isResizable,vertical:a.vertical,ref:"dropdown",onClose:r.onClose,onOpen:r.onOpen},i.createSlots({body:i.withCtx(()=>[i.createElementVNode("div",{class:i.normalizeClass(["tree-drop",{"not-tree-child":!a.hasTreeChildren}]),style:i.normalizeStyle(r.treeDropPos)},[e.isResizable?(i.openBlock(),i.createElementBlock("div",{key:0,class:"ib-dropdown-resizer ib-dropdown-resizer-left",onMousedown:n[6]||(n[6]=c=>r.startResizing("left"))},null,32)):i.createCommentVNode("",!0),e.isResizable?(i.openBlock(),i.createElementBlock("div",{key:1,class:"ib-dropdown-resizer ib-dropdown-resizer-right",onMousedown:n[7]||(n[7]=c=>r.startResizing("right"))},null,32)):i.createCommentVNode("",!0),Object.keys(a.actualBookmarkedOptions).length>0?(i.openBlock(),i.createBlock(h,{key:2,class:i.normalizeClass({"has-hierarchy":r.hasHierarchy})},{default:i.withCtx(()=>[(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(a.actualBookmarkedOptions,c=>(i.openBlock(),i.createBlock(p,{key:"bookmark"+c.id,option:c,"parent-auto-check":!1,"is-multiple":e.isMultiple,"is-bookmarkable":!0,"is-bookmarked":!0,onCheck:r.registerCheck,onToggleBookmark:r.toggleBookmark,uid:a.uid,"only-end-nodes":e.onlyEndNodes,"html-title":e.htmlOptionTitle,"show-input":e.showInputs},null,8,["option","is-multiple","onCheck","onToggleBookmark","uid","only-end-nodes","html-title","show-input"]))),128))]),_:1},8,["class"])):i.createCommentVNode("",!0),r.showSearch?(i.openBlock(),i.createBlock(f,{key:3,class:"tree-search",ref:"search","show-icon":!0,value:a.filterString,"aria-label":e.searchPlaceholderText?e.searchPlaceholderText:a.actualStrings.searchPlaceholder,placeholder:e.searchPlaceholderText?e.searchPlaceholderText:a.actualStrings.searchPlaceholder,onInput:n[8]||(n[8]=c=>r.filter(c,a.actualOptions)),onKeyup:i.withKeys(r.inputKeyupDown,["down"])},null,8,["value","aria-label","placeholder","onKeyup"])):i.createCommentVNode("",!0),i.createVNode(h,{ref:"list",role:"listbox",class:i.normalizeClass({"tree-select-list":!0,"has-hierarchy":r.hasHierarchy})},{default:i.withCtx(()=>[!r.requiredDependencyNotFilled&&!r.visibleOptionsCount&&r.hasEmptyMessage?(i.openBlock(),i.createElementBlock("div",qs,[i.renderSlot(t.$slots,"emptyMessage")])):!r.requiredDependencyNotFilled&&!r.visibleOptionsCount?(i.openBlock(),i.createElementBlock("div",Fs,i.toDisplayString(a.actualStrings.emptyTitle),1)):i.createCommentVNode("",!0),i.withDirectives(i.createElementVNode("div",{class:"tree-select-empty"},i.toDisplayString(a.actualStrings.requiredDependencyNotFilled),513),[[i.vShow,r.requiredDependencyNotFilled]]),!e.isMultiple&&!e.isRequired&&a.actualOptions.length>0?(i.openBlock(),i.createBlock(p,{key:2,option:{title:t.lang("none","select"),id:null,checked:r.isEmpty},name:a.actualName,"parent-auto-check":e.parentAutoCheck,"is-multiple":e.isMultiple,onCheck:r.registerCheck,onToggleBookmark:r.toggleBookmark,uid:a.uid,"only-end-nodes":e.onlyEndNodes,"show-input":e.showInputs},null,8,["option","name","parent-auto-check","is-multiple","onCheck","onToggleBookmark","uid","only-end-nodes","show-input"])):i.createCommentVNode("",!0),r.requiredDependencyNotFilled?i.createCommentVNode("",!0):(i.openBlock(),i.createElementBlock(i.Fragment,{key:3},[e.allOptions&&e.isMultiple&&r.visibleOptionsCount&&!r.requiredDependencyNotFilled?(i.openBlock(),i.createBlock(p,{key:0,option:{title:a.actualStrings.selectAllOptions,id:"!all!",initiallyVisible:!0,visible:!0,isDisabled:r.visibleOptionsCount<r.optionsCount,checked:a.allOptionsIsChecked,isIndeterminate:!!Object.keys(a.selected).length},"is-toggle":e.isToggle,name:a.actualName,"parent-auto-check":!1,"is-multiple":e.isMultiple,"is-bookmarkable":!1,uid:a.uid,"only-end-nodes":e.onlyEndNodes,"show-input":e.showInputs,onCheck:r.manageAll,onOnFocus:n[9]||(n[9]=c=>a.focusedOptionId=c)},null,8,["option","is-toggle","name","is-multiple","uid","only-end-nodes","show-input","onCheck"])):i.createCommentVNode("",!0),(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(a.actualOptions,c=>i.renderSlot(t.$slots,a.actualName,{key:e.name+c.value,option:c,parentAutoCheck:e.parentAutoCheck,isMultiple:e.isMultiple,uid:a.uid,onlyEndNodes:e.onlyEndNodes,htmlTitle:e.htmlOptionTitle,showInput:e.showInputs},()=>[i.withDirectives(i.createVNode(p,{option:c,"is-toggle":e.isToggle,name:a.actualName,"parent-auto-check":e.parentAutoCheck,"is-multiple":e.isMultiple,"is-bookmarkable":e.isBookmarkable,uid:a.uid,"only-end-nodes":e.onlyEndNodes,"html-title":e.htmlOptionTitle,"show-input":e.showInputs,onCheck:r.registerCheck,onToggleBookmark:r.toggleBookmark,onOnFocus:n[10]||(n[10]=_=>a.focusedOptionId=_)},null,8,["option","is-toggle","name","parent-auto-check","is-multiple","is-bookmarkable","uid","only-end-nodes","html-title","show-input","onCheck","onToggleBookmark"]),[[i.vShow,c.visible]])])),128))],64))]),_:3},8,["class"])],6)]),_:2},[r.hasTrigger?{name:"trigger",fn:i.withCtx(()=>[i.renderSlot(t.$slots,"trigger",{selectedCount:r.selectedKeys.length})]),key:"0"}:{name:"trigger",fn:i.withCtx(({isOpened:c})=>[i.createElementVNode("div",{role:"combobox",tabindex:"0",class:i.normalizeClass(["tree-choice",{"tree-choice-opened":c,"has-clear-button":e.showClearButton,"tree-choice-error":e.errorMessage}]),ref:"combobox",onClick:n[2]||(n[2]=i.withModifiers(()=>{},["prevent"])),onBlur:n[3]||(n[3]=(..._)=>r.onBlur&&r.onBlur(..._)),onKeyup:[n[4]||(n[4]=i.withKeys((..._)=>r.comboboxKeyupDown&&r.comboboxKeyupDown(..._),["down"])),n[5]||(n[5]=i.withKeys((..._)=>r.comboboxKeyupDown&&r.comboboxKeyupDown(..._),["up"]))],"aria-label":e.ariaLabel,"aria-activedescendant":a.focusedOptionId},[r.hasTriggerContent?i.renderSlot(t.$slots,"triggerContent",{key:0,selectedCount:r.selectedKeys.length}):(i.openBlock(),i.createElementBlock(i.Fragment,{key:1},[e.htmlOptionTitle?(i.openBlock(),i.createElementBlock("span",{key:0,class:i.normalizeClass({placeholder:!r.selectStatus}),innerHTML:r.selectStatus||e.placeholder},null,10,["innerHTML"])):(i.openBlock(),i.createElementBlock("span",{key:1,class:i.normalizeClass({placeholder:!r.selectStatus})},i.toDisplayString(r.selectStatus||e.placeholder),3))],64)),e.showClearButton?i.withDirectives((i.openBlock(),i.createBlock(u,{key:2,kind:"ghost",class:"button-clear",onClick:i.withModifiers(r.clearValue,["prevent"]),onKeypress:n[0]||(n[0]=i.withKeys(i.withModifiers(()=>{},["stop","prevent"]),["enter"])),onKeydown:n[1]||(n[1]=i.withKeys(i.withModifiers(()=>{},["stop","prevent"]),["enter"])),onKeyup:i.withKeys(i.withModifiers(r.clearValue,["prevent"]),["enter"]),"help-text":e.clearButtonMessage},{default:i.withCtx(()=>[i.createVNode(d,{name:"close-outline"})]),_:1},8,["onClick","onKeyup","help-text"])),[[i.vShow,Object.keys(a.selected).length]]):i.createCommentVNode("",!0),i.createVNode(d,{name:c?"chevron-up-outline":"chevron-down-outline",classes:"tree-select-caret"},null,8,["name"])],42,["aria-label","aria-activedescendant"])]),key:"1"}]),1032,["disabled","is-resizable","vertical","onClose","onOpen"])],2)],64)}const Li=_e(Vs,[["render",Hs]]),N1="",zs={name:"IbLimitSelector",props:{labelSelect:{type:String,required:!0},value:{type:Number},options:{type:Array,default:()=>[10,25,50,100]}},watch(t){this.selected=t},data(){return{selected:this.value}},methods:{selectItem(t){this.selected=t,this.onChange(t)},onChange(t){Number.isInteger(+t)&&this.$emit("select",+t)}},computed:{prepareOptions(){return this.options.map(t=>({id:t,title:t}))}},components:{IbLabel:dn,IbSelect:Li}},Us={class:"report-limit-selector"};function Ks(t,n,e,o,a,r){const s=i.resolveComponent("ib-label"),d=i.resolveComponent("ib-select");return i.openBlock(),i.createElementBlock("div",Us,[i.createVNode(s,null,{default:i.withCtx(()=>[i.createTextVNode(i.toDisplayString(e.labelSelect),1)]),_:1}),i.createVNode(d,{classList:"report-limit-selector-select",value:e.value,options:r.prepareOptions,"is-multiple":!1,"show-clear-button":!1,onInput:r.selectItem},null,8,["value","options","onInput"])])}const Ri=_e(zs,[["render",Ks]]),x1="",Gs={name:"IbPagination",props:{tooltipTextPrev:{type:String},tooltipTextNext:{type:String},labelInput:{type:String},labelSelect:{type:String,required:!0},countRows:{type:Number,required:!0},pageCount:{type:Number,default:null},current:{type:Number,default:1},limitSelector:{type:Number,default:10},showPaginationInput:{type:Boolean,default:!0}},data(){return{currentPage:this.current,indexSpaceLeft:null,indexSpaceRight:null,limitValue:this.limitSelector}},watch:{current(t){this.onSelect(t)},limitValue(){this.currentPage=1}},methods:{changeLimit(t){Number.isInteger(t)&&(this.limitValue=t,this.$emit("set-limit",t))},onInput(t){if(t<1){this.onSelect(1);return}if(t>this.countPagePagination){this.onSelect(this.countPagePagination);return}this.onSelect(Number(t))},onSelect(t){Number.isInteger(t)&&(this.currentPage=t,this.$emit("select",t))},showItem(t){if(this.countPagePagination<=5)return this.indexSpaceLeft=null,this.indexSpaceRight=null,!0;if(t===1||t===this.countPagePagination)return!0;if(this.countPagePagination>=7){if(this.currentPage<=3&&t<=5)return this.indexSpaceLeft=this.countPagePagination,this.indexSpaceRight=null,!0;if(this.currentPage>=this.countPagePagination-2&&t>=this.countPagePagination-4)return this.indexSpaceLeft=null,this.indexSpaceRight=1,!0;if(3<this.currentPage<this.countPagePagination-3&&(t===this.currentPage+1||t===this.currentPage-1||t===this.currentPage))return this.indexSpaceLeft=this.countPagePagination,this.indexSpaceRight=1,!0}else return!0;return!1}},computed:{setCountOfRows(){return this.currentPage===1||this.countPagePagination===1?"1 - "+(this.countPagePagination>1?this.limitValue:this.countRows):this.countPagePagination===this.currentPage?(this.currentPage-1)*this.limitValue+" - "+this.countRows:(this.currentPage-1)*this.limitValue+1+" - "+this.currentPage*this.limitValue},countPagePagination(){return Math.ceil(this.countRows/this.limitValue)}},components:{IbIconButton:ut,IbIcon:Le,IbInput:br,IbLabel:dn,IbLimitSelector:Ri,IbTooltip:jt}},Ys={class:"report-controls"},Ws={class:"repot-pagination"},Zs={class:"pagination-input"},Js={class:"row-count"},Xs={class:"pagination-wrapper"},Qs=["onClick"];function ed(t,n,e,o,a,r){const s=i.resolveComponent("ib-limit-selector"),d=i.resolveComponent("ib-label"),u=i.resolveComponent("ib-input"),p=i.resolveComponent("ib-icon"),h=i.resolveComponent("ib-tooltip"),f=i.resolveComponent("ib-icon-button");return i.openBlock(),i.createElementBlock("div",Ys,[i.createVNode(s,{onSelect:r.changeLimit,value:a.limitValue,"label-select":e.labelSelect},null,8,["onSelect","value","label-select"]),i.createElementVNode("div",Ws,[e.showPaginationInput?(i.openBlock(),i.createElementBlock(i.Fragment,{key:0},[i.createVNode(d,null,{default:i.withCtx(()=>[i.createTextVNode(i.toDisplayString(e.labelInput),1)]),_:1}),i.createElementVNode("div",Zs,[i.createVNode(u,{type:"number",debounce:500,onInput:r.onInput},null,8,["onInput"])])],64)):i.createCommentVNode("",!0),i.createElementVNode("div",Js,i.toDisplayString(r.setCountOfRows+" of "+e.countRows),1),i.createVNode(f,{kind:"tertiary",size:"m",class:"toggle-children button-prev",disabled:a.currentPage===1,onClick:n[0]||(n[0]=l=>r.onSelect(a.currentPage-1))},{default:i.withCtx(()=>[i.createVNode(p,{name:"chevron-back-outline"}),e.tooltipTextPrev?(i.openBlock(),i.createBlock(h,{key:0,text:e.tooltipTextPrev},null,8,["text"])):i.createCommentVNode("",!0)]),_:1},8,["disabled"]),i.createElementVNode("ul",Xs,[(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(r.countPagePagination,(l,c)=>i.withDirectives((i.openBlock(),i.createElementBlock("li",{key:c,class:i.normalizeClass(["pagination-item",{active:c+1===a.currentPage,"dots-left":a.indexSpaceLeft===c+1,"dots-right":a.indexSpaceRight===c+1}]),onClick:_=>r.onSelect(c+1)},[i.createElementVNode("button",null,i.toDisplayString(c+1),1)],10,Qs)),[[i.vShow,r.showItem(c+1)]])),128))]),i.createVNode(f,{kind:"tertiary",size:"m",class:"toggle-children button-next",disabled:a.currentPage===r.countPagePagination,onClick:n[1]||(n[1]=l=>r.onSelect(a.currentPage+1))},{default:i.withCtx(()=>[i.createVNode(p,{name:"chevron-forward-outline"}),e.tooltipTextNext?(i.openBlock(),i.createBlock(h,{key:0,text:e.tooltipTextNext},null,8,["text"])):i.createCommentVNode("",!0)]),_:1},8,["disabled"])])])}const td=_e(Gs,[["render",ed]]),cn={PROGRESS:"progress",SUCCESS:"success",FAILED:"failed",CANCELING:"canceling",CANCELED:"canceled"},A1="",nd={props:{states:{type:String,default:cn.PROGRESS},progress:{type:[String,Number],default:0},ariaLabel:{type:String,required:!0}},computed:{classes(){const t=["ib-progress-bar"];return t.push(`progress-bar-${this.states}`),t},iconName(){return this.states===cn.SUCCESS?"checkmark-circle":this.states===cn.FAILED||this.states===cn.CANCELING||this.states===cn.CANCELED?"close-circle":""}},components:{IbIcon:Le}},ji=t=>(i.pushScopeId("data-v-a0217859"),t=t(),i.popScopeId(),t),rd={class:"ib-progress-bar-wrapper"},id=["aria-label","aria-valuenow"],od=[ji(()=>i.createElementVNode("div",{class:"gradient"},null,-1))],ad=ji(()=>i.createElementVNode("div",null,null,-1));function ld(t,n,e,o,a,r){const s=i.resolveComponent("ib-icon");return i.openBlock(),i.createElementBlock("div",rd,[i.createElementVNode("div",{class:i.normalizeClass(r.classes)},[i.createElementVNode("div",{class:"progress",role:"meter","aria-label":e.ariaLabel,"aria-valuemin":"0","aria-valuemax":"100","aria-valuenow":e.progress,style:i.normalizeStyle({width:e.progress+"%"})},od,12,id),ad],2),i.withDirectives(i.createVNode(s,{class:"status-icon",name:r.iconName},null,8,["name"]),[[i.vShow,r.iconName.length]])])}const sd=_e(nd,[["render",ld],["__scopeId","data-v-a0217859"]]),dd={new:`<svg width="11" height="11" viewBox="0 0 11 11" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
26
|
+
*****************************************************/(function(t,n){(function(e,o){t.exports=o()})(qe,function(){class e{constructor(r,s=!0,d=[],u=5e3){this.ctx=r,this.iframes=s,this.exclude=d,this.iframesTimeout=u}static matches(r,s){const d=typeof s=="string"?[s]:s,u=r.matches||r.matchesSelector||r.msMatchesSelector||r.mozMatchesSelector||r.oMatchesSelector||r.webkitMatchesSelector;if(u){let p=!1;return d.every(h=>!u.call(r,h)||(p=!0,!1)),p}return!1}getContexts(){let r=[];return(this.ctx!==void 0&&this.ctx?NodeList.prototype.isPrototypeOf(this.ctx)?Array.prototype.slice.call(this.ctx):Array.isArray(this.ctx)?this.ctx:typeof this.ctx=="string"?Array.prototype.slice.call(document.querySelectorAll(this.ctx)):[this.ctx]:[]).forEach(s=>{const d=r.filter(u=>u.contains(s)).length>0;r.indexOf(s)!==-1||d||r.push(s)}),r}getIframeContents(r,s,d=()=>{}){let u;try{const p=r.contentWindow;if(u=p.document,!p||!u)throw new Error("iframe inaccessible")}catch{d()}u&&s(u)}isIframeBlank(r){const s="about:blank",d=r.getAttribute("src").trim();return r.contentWindow.location.href===s&&d!==s&&d}observeIframeLoad(r,s,d){let u=!1,p=null;const h=()=>{if(!u){u=!0,clearTimeout(p);try{this.isIframeBlank(r)||(r.removeEventListener("load",h),this.getIframeContents(r,s,d))}catch{d()}}};r.addEventListener("load",h),p=setTimeout(h,this.iframesTimeout)}onIframeReady(r,s,d){try{r.contentWindow.document.readyState==="complete"?this.isIframeBlank(r)?this.observeIframeLoad(r,s,d):this.getIframeContents(r,s,d):this.observeIframeLoad(r,s,d)}catch{d()}}waitForIframes(r,s){let d=0;this.forEachIframe(r,()=>!0,u=>{d++,this.waitForIframes(u.querySelector("html"),()=>{--d||s()})},u=>{u||s()})}forEachIframe(r,s,d,u=()=>{}){let p=r.querySelectorAll("iframe"),h=p.length,f=0;p=Array.prototype.slice.call(p);const l=()=>{--h<=0&&u(f)};h||l(),p.forEach(c=>{e.matches(c,this.exclude)?l():this.onIframeReady(c,_=>{s(c)&&(f++,d(_)),l()},l)})}createIterator(r,s,d){return document.createNodeIterator(r,s,d,!1)}createInstanceOnIframe(r){return new e(r.querySelector("html"),this.iframes)}compareNodeIframe(r,s,d){const u=r.compareDocumentPosition(d),p=Node.DOCUMENT_POSITION_PRECEDING;return!!(u&p&&(s===null||s.compareDocumentPosition(d)&Node.DOCUMENT_POSITION_FOLLOWING))}getIteratorNode(r){const s=r.previousNode();return{prevNode:s,node:(s===null||r.nextNode())&&r.nextNode()}}checkIframeFilter(r,s,d,u){let p=!1,h=!1;return u.forEach((f,l)=>{f.val===d&&(p=l,h=f.handled)}),this.compareNodeIframe(r,s,d)?(p!==!1||h?p===!1||h||(u[p].handled=!0):u.push({val:d,handled:!0}),!0):(p===!1&&u.push({val:d,handled:!1}),!1)}handleOpenIframes(r,s,d,u){r.forEach(p=>{p.handled||this.getIframeContents(p.val,h=>{this.createInstanceOnIframe(h).forEachNode(s,d,u)})})}iterateThroughNodes(r,s,d,u,p){const h=this.createIterator(s,r,u);let f,l,c=[],_=[],v=()=>({prevNode:l,node:f}=this.getIteratorNode(h),f);for(;v();)this.iframes&&this.forEachIframe(s,b=>this.checkIframeFilter(f,l,b,c),b=>{this.createInstanceOnIframe(b).forEachNode(r,g=>_.push(g),u)}),_.push(f);_.forEach(b=>{d(b)}),this.iframes&&this.handleOpenIframes(c,r,d,u),p()}forEachNode(r,s,d,u=()=>{}){const p=this.getContexts();let h=p.length;h||u(),p.forEach(f=>{const l=()=>{this.iterateThroughNodes(r,f,s,d,()=>{--h<=0&&u()})};this.iframes?this.waitForIframes(f,l):l()})}}class o{constructor(r){this.ctx=r,this.ie=!1;const s=window.navigator.userAgent;(s.indexOf("MSIE")>-1||s.indexOf("Trident")>-1)&&(this.ie=!0)}set opt(r){this._opt=Object.assign({},{element:"",className:"",exclude:[],iframes:!1,iframesTimeout:5e3,separateWordSearch:!0,diacritics:!0,synonyms:{},accuracy:"partially",acrossElements:!1,caseSensitive:!1,ignoreJoiners:!1,ignoreGroups:0,ignorePunctuation:[],wildcards:"disabled",each:()=>{},noMatch:()=>{},filter:()=>!0,done:()=>{},debug:!1,log:window.console},r)}get opt(){return this._opt}get iterator(){return new e(this.ctx,this.opt.iframes,this.opt.exclude,this.opt.iframesTimeout)}log(r,s="debug"){const d=this.opt.log;this.opt.debug&&typeof d=="object"&&typeof d[s]=="function"&&d[s](`mark.js: ${r}`)}escapeStr(r){return r.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&")}createRegExp(r){return this.opt.wildcards!=="disabled"&&(r=this.setupWildcardsRegExp(r)),r=this.escapeStr(r),Object.keys(this.opt.synonyms).length&&(r=this.createSynonymsRegExp(r)),(this.opt.ignoreJoiners||this.opt.ignorePunctuation.length)&&(r=this.setupIgnoreJoinersRegExp(r)),this.opt.diacritics&&(r=this.createDiacriticsRegExp(r)),r=this.createMergedBlanksRegExp(r),(this.opt.ignoreJoiners||this.opt.ignorePunctuation.length)&&(r=this.createJoinersRegExp(r)),this.opt.wildcards!=="disabled"&&(r=this.createWildcardsRegExp(r)),r=this.createAccuracyRegExp(r)}createSynonymsRegExp(r){const s=this.opt.synonyms,d=this.opt.caseSensitive?"":"i",u=this.opt.ignoreJoiners||this.opt.ignorePunctuation.length?"\0":"";for(let p in s)if(s.hasOwnProperty(p)){const h=s[p],f=this.opt.wildcards!=="disabled"?this.setupWildcardsRegExp(p):this.escapeStr(p),l=this.opt.wildcards!=="disabled"?this.setupWildcardsRegExp(h):this.escapeStr(h);f!==""&&l!==""&&(r=r.replace(new RegExp(`(${this.escapeStr(f)}|${this.escapeStr(l)})`,`gm${d}`),u+`(${this.processSynomyms(f)}|${this.processSynomyms(l)})`+u))}return r}processSynomyms(r){return(this.opt.ignoreJoiners||this.opt.ignorePunctuation.length)&&(r=this.setupIgnoreJoinersRegExp(r)),r}setupWildcardsRegExp(r){return(r=r.replace(/(?:\\)*\?/g,s=>s.charAt(0)==="\\"?"?":"")).replace(/(?:\\)*\*/g,s=>s.charAt(0)==="\\"?"*":"")}createWildcardsRegExp(r){let s=this.opt.wildcards==="withSpaces";return r.replace(/\u0001/g,s?"[\\S\\s]?":"\\S?").replace(/\u0002/g,s?"[\\S\\s]*?":"\\S*")}setupIgnoreJoinersRegExp(r){return r.replace(/[^(|)\\]/g,(s,d,u)=>{let p=u.charAt(d+1);return/[(|)\\]/.test(p)||p===""?s:s+"\0"})}createJoinersRegExp(r){let s=[];const d=this.opt.ignorePunctuation;return Array.isArray(d)&&d.length&&s.push(this.escapeStr(d.join(""))),this.opt.ignoreJoiners&&s.push("\\u00ad\\u200b\\u200c\\u200d"),s.length?r.split(/\u0000+/).join(`[${s.join("")}]*`):r}createDiacriticsRegExp(r){const s=this.opt.caseSensitive?"":"i",d=this.opt.caseSensitive?["aàáảãạăằắẳẵặâầấẩẫậäåāą","AÀÁẢÃẠĂẰẮẲẴẶÂẦẤẨẪẬÄÅĀĄ","cçćč","CÇĆČ","dđď","DĐĎ","eèéẻẽẹêềếểễệëěēę","EÈÉẺẼẸÊỀẾỂỄỆËĚĒĘ","iìíỉĩịîïī","IÌÍỈĨỊÎÏĪ","lł","LŁ","nñňń","NÑŇŃ","oòóỏõọôồốổỗộơởỡớờợöøō","OÒÓỎÕỌÔỒỐỔỖỘƠỞỠỚỜỢÖØŌ","rř","RŘ","sšśșş","SŠŚȘŞ","tťțţ","TŤȚŢ","uùúủũụưừứửữựûüůū","UÙÚỦŨỤƯỪỨỬỮỰÛÜŮŪ","yýỳỷỹỵÿ","YÝỲỶỸỴŸ","zžżź","ZŽŻŹ"]:["aàáảãạăằắẳẵặâầấẩẫậäåāąAÀÁẢÃẠĂẰẮẲẴẶÂẦẤẨẪẬÄÅĀĄ","cçćčCÇĆČ","dđďDĐĎ","eèéẻẽẹêềếểễệëěēęEÈÉẺẼẸÊỀẾỂỄỆËĚĒĘ","iìíỉĩịîïīIÌÍỈĨỊÎÏĪ","lłLŁ","nñňńNÑŇŃ","oòóỏõọôồốổỗộơởỡớờợöøōOÒÓỎÕỌÔỒỐỔỖỘƠỞỠỚỜỢÖØŌ","rřRŘ","sšśșşSŠŚȘŞ","tťțţTŤȚŢ","uùúủũụưừứửữựûüůūUÙÚỦŨỤƯỪỨỬỮỰÛÜŮŪ","yýỳỷỹỵÿYÝỲỶỸỴŸ","zžżźZŽŻŹ"];let u=[];return r.split("").forEach(p=>{d.every(h=>{if(h.indexOf(p)!==-1){if(u.indexOf(h)>-1)return!1;r=r.replace(new RegExp(`[${h}]`,`gm${s}`),`[${h}]`),u.push(h)}return!0})}),r}createMergedBlanksRegExp(r){return r.replace(/[\s]+/gim,"[\\s]+")}createAccuracyRegExp(r){const s="!\"#$%&'()*+,-./:;<=>?@[\\]^_`{|}~¡¿";let d=this.opt.accuracy,u=typeof d=="string"?d:d.value,p=typeof d=="string"?[]:d.limiters,h="";switch(p.forEach(f=>{h+=`|${this.escapeStr(f)}`}),u){case"partially":default:return`()(${r})`;case"complementary":return`()([^${h="\\s"+(h||this.escapeStr(s))}]*${r}[^${h}]*)`;case"exactly":return`(^|\\s${h})(${r})(?=$|\\s${h})`}}getSeparatedKeywords(r){let s=[];return r.forEach(d=>{this.opt.separateWordSearch?d.split(" ").forEach(u=>{u.trim()&&s.indexOf(u)===-1&&s.push(u)}):d.trim()&&s.indexOf(d)===-1&&s.push(d)}),{keywords:s.sort((d,u)=>u.length-d.length),length:s.length}}isNumeric(r){return Number(parseFloat(r))==r}checkRanges(r){if(!Array.isArray(r)||Object.prototype.toString.call(r[0])!=="[object Object]")return this.log("markRanges() will only accept an array of objects"),this.opt.noMatch(r),[];const s=[];let d=0;return r.sort((u,p)=>u.start-p.start).forEach(u=>{let{start:p,end:h,valid:f}=this.callNoMatchOnInvalidRanges(u,d);f&&(u.start=p,u.length=h-p,s.push(u),d=h)}),s}callNoMatchOnInvalidRanges(r,s){let d,u,p=!1;return r&&r.start!==void 0?(u=(d=parseInt(r.start,10))+parseInt(r.length,10),this.isNumeric(r.start)&&this.isNumeric(r.length)&&u-s>0&&u-d>0?p=!0:(this.log(`Ignoring invalid or overlapping range: ${JSON.stringify(r)}`),this.opt.noMatch(r))):(this.log(`Ignoring invalid range: ${JSON.stringify(r)}`),this.opt.noMatch(r)),{start:d,end:u,valid:p}}checkWhitespaceRanges(r,s,d){let u,p=!0,h=d.length,f=s-h,l=parseInt(r.start,10)-f;return(u=(l=l>h?h:l)+parseInt(r.length,10))>h&&(u=h,this.log(`End range automatically set to the max value of ${h}`)),l<0||u-l<0||l>h||u>h?(p=!1,this.log(`Invalid range: ${JSON.stringify(r)}`),this.opt.noMatch(r)):d.substring(l,u).replace(/\s+/g,"")===""&&(p=!1,this.log("Skipping whitespace only range: "+JSON.stringify(r)),this.opt.noMatch(r)),{start:l,end:u,valid:p}}getTextNodes(r){let s="",d=[];this.iterator.forEachNode(NodeFilter.SHOW_TEXT,u=>{d.push({start:s.length,end:(s+=u.textContent).length,node:u})},u=>this.matchesExclude(u.parentNode)?NodeFilter.FILTER_REJECT:NodeFilter.FILTER_ACCEPT,()=>{r({value:s,nodes:d})})}matchesExclude(r){return e.matches(r,this.opt.exclude.concat(["script","style","title","head","html"]))}wrapRangeInTextNode(r,s,d){const u=this.opt.element?this.opt.element:"mark",p=r.splitText(s),h=p.splitText(d-s);let f=document.createElement(u);return f.setAttribute("data-markjs","true"),this.opt.className&&f.setAttribute("class",this.opt.className),f.textContent=p.textContent,p.parentNode.replaceChild(f,p),h}wrapRangeInMappedTextNode(r,s,d,u,p){r.nodes.every((h,f)=>{const l=r.nodes[f+1];if(l===void 0||l.start>s){if(!u(h.node))return!1;const c=s-h.start,_=(d>h.end?h.end:d)-h.start,v=r.value.substr(0,h.start),b=r.value.substr(_+h.start);if(h.node=this.wrapRangeInTextNode(h.node,c,_),r.value=v+b,r.nodes.forEach((g,y)=>{y>=f&&(r.nodes[y].start>0&&y!==f&&(r.nodes[y].start-=_),r.nodes[y].end-=_)}),d-=_,p(h.node.previousSibling,h.start),!(d>h.end))return!1;s=h.end}return!0})}wrapMatches(r,s,d,u,p){const h=s===0?0:s+1;this.getTextNodes(f=>{f.nodes.forEach(l=>{let c;for(l=l.node;(c=r.exec(l.textContent))!==null&&c[h]!=="";){if(!d(c[h],l))continue;let _=c.index;if(h!==0)for(let v=1;v<h;v++)_+=c[v].length;l=this.wrapRangeInTextNode(l,_,_+c[h].length),u(l.previousSibling),r.lastIndex=0}}),p()})}wrapMatchesAcrossElements(r,s,d,u,p){const h=s===0?0:s+1;this.getTextNodes(f=>{let l;for(;(l=r.exec(f.value))!==null&&l[h]!=="";){let c=l.index;if(h!==0)for(let v=1;v<h;v++)c+=l[v].length;const _=c+l[h].length;this.wrapRangeInMappedTextNode(f,c,_,v=>d(l[h],v),(v,b)=>{r.lastIndex=b,u(v)})}p()})}wrapRangeFromIndex(r,s,d,u){this.getTextNodes(p=>{const h=p.value.length;r.forEach((f,l)=>{let{start:c,end:_,valid:v}=this.checkWhitespaceRanges(f,h,p.value);v&&this.wrapRangeInMappedTextNode(p,c,_,b=>s(b,f,p.value.substring(c,_),l),b=>{d(b,f)})}),u()})}unwrapMatches(r){const s=r.parentNode;let d=document.createDocumentFragment();for(;r.firstChild;)d.appendChild(r.removeChild(r.firstChild));s.replaceChild(d,r),this.ie?this.normalizeTextNode(s):s.normalize()}normalizeTextNode(r){if(r){if(r.nodeType===3)for(;r.nextSibling&&r.nextSibling.nodeType===3;)r.nodeValue+=r.nextSibling.nodeValue,r.parentNode.removeChild(r.nextSibling);else this.normalizeTextNode(r.firstChild);this.normalizeTextNode(r.nextSibling)}}markRegExp(r,s){this.opt=s,this.log(`Searching with expression "${r}"`);let d=0,u="wrapMatches";const p=h=>{d++,this.opt.each(h)};this.opt.acrossElements&&(u="wrapMatchesAcrossElements"),this[u](r,this.opt.ignoreGroups,(h,f)=>this.opt.filter(f,h,d),p,()=>{d===0&&this.opt.noMatch(r),this.opt.done(d)})}mark(r,s){this.opt=s;let d=0,u="wrapMatches";const{keywords:p,length:h}=this.getSeparatedKeywords(typeof r=="string"?[r]:r),f=this.opt.caseSensitive?"":"i",l=c=>{let _=new RegExp(this.createRegExp(c),`gm${f}`),v=0;this.log(`Searching with expression "${_}"`),this[u](_,1,(b,g)=>this.opt.filter(g,c,d,v),b=>{v++,d++,this.opt.each(b)},()=>{v===0&&this.opt.noMatch(c),p[h-1]===c?this.opt.done(d):l(p[p.indexOf(c)+1])})};this.opt.acrossElements&&(u="wrapMatchesAcrossElements"),h===0?this.opt.done(d):l(p[0])}markRanges(r,s){this.opt=s;let d=0,u=this.checkRanges(r);u&&u.length?(this.log("Starting to mark with the following ranges: "+JSON.stringify(u)),this.wrapRangeFromIndex(u,(p,h,f,l)=>this.opt.filter(p,h,f,l),(p,h)=>{d++,this.opt.each(p,h)},()=>{this.opt.done(d)})):this.opt.done(d)}unmark(r){this.opt=r;let s=this.opt.element?this.opt.element:"*";s+="[data-markjs]",this.opt.className&&(s+=`.${this.opt.className}`),this.log(`Removal selector "${s}"`),this.iterator.forEachNode(NodeFilter.SHOW_ELEMENT,d=>{this.unwrapMatches(d)},d=>{const u=e.matches(d,s),p=this.matchesExclude(d);return!u||p?NodeFilter.FILTER_REJECT:NodeFilter.FILTER_ACCEPT},this.opt.done)}}return function(a){const r=new o(a);return this.mark=(s,d)=>(r.mark(s,d),this),this.markRegExp=(s,d)=>(r.markRegExp(s,d),this),this.markRanges=(s,d)=>(r.markRanges(s,d),this),this.unmark=s=>(r.unmark(s),this),this}})})(Pi);var Rs=Pi.exports;const js=jn(Rs),T1="";function Bi(t){return JSON.parse(JSON.stringify(t))}const Vs={name:"IbTreeSelect",inject:["LANG_COMPONENTS"],props:{classList:[String,Array],placeholder:{type:String,default:""},searchPlaceholderText:{type:String,default:""},clearButtonMessage:{type:String,default:""},showClearButton:{type:Boolean,default:!0},isResizable:{type:Boolean,default:!1},menuSize:{type:[String,Number]},initialSize:{left:0,right:0},ariaLabel:{type:String,default:""},name:String,id:{type:String,default(){return ht()}},options:{default(){return[]}},modelValue:{type:[Number,String,Array]},value:{type:[Number,String,Array],default(){return[]}},maxSelectedNames:{type:Number,default:2},isMultiple:{type:Boolean,default:!0},parentAutoCheck:{type:Boolean,default:!0},strings:{type:Object,default(){return{}}},onlyEndNodes:{type:Boolean,default:!1},isRequired:{type:Boolean,default:!0},htmlOptionTitle:{type:Boolean,default:!1},isBookmarkable:{type:Boolean,default:!1},initBookmarks:{type:Array,default:()=>[]},showInputs:{type:Boolean,default(t){return t.isMultiple}},dependency:{type:String},filterId:{type:String,default(){return ht()}},staticPlaceholder:{type:Boolean,default:!1},useSearch:{type:Boolean,default:!1},isWatching:{type:Boolean,default:!1},vertical:{type:String},emptyMessage:{type:String,default:""},errorMessage:{type:String,default:""},allOptions:{type:Boolean,default:!0},watchClearValue:{type:Boolean,default:!1},isToggle:{type:Boolean,default:!1},alphabetSort:{type:Boolean,default:!1}},emits:["close","input","blur","search","resize","submit","clearValue","update:modelValue"],watch:{value(t){this.val=t,(!Array.isArray(t)||t.join(",")!==Object.keys(this.selected).join(","))&&this.setPreparedValues(this.actualOptions,!1)},modelValue:{handler(t){this.val=t,this.actualOptions=[],this.setPreparedValues()},deep:!0},val(t){this.watchClearValue&&(!t||Array.isArray(t)&&!t.length)&&this.setPreparedValues(this.actualOptions).then(()=>{const n=Object.keys(this.selected);this.$globalEvents.$emit("select-"+this.filterId+":update",{values:n,filter:this.filterId})})},options:{handler(t){this.initialOptions=Bi(t)},deep:!0},initialOptions(t){let n=!0;if(typeof t=="function")n=!1;else{const e=[],o=t;Array.prototype.forEach.call(o,a=>{a.id!==void 0&&e.push(a.id)}),n=JSON.stringify(e)===JSON.stringify(this.optionsIdsWatch),this.optionsIdsWatch=e}(this.isInitialized&&!n||this.isWatching)&&this.setPreparedValues().then(()=>{const e=Object.keys(this.selected);this.$globalEvents.$emit("select-"+this.filterId+":update",{values:e,filter:this.filterId})})},dependency(t,n){this.$nextTick(()=>{this.registerDependency(n)})},initBookmarks(){this.actualBookmarkedOptions={},this.setBookmarkedOptions(this.actualOptions)}},mounted(){this.marker=new js(this.$refs.list.$el),this.registerDependency(),this.$globalEvents.$on("select:refresh",()=>{this.setPreparedValues()}),document.addEventListener("mousemove",this.onResize),document.addEventListener("mouseup",this.endResizing)},data(){var t,n,e,o,a,r,s,d;return this.defaultFilter=u=>{this.marker.unmark();const p=this.filterString.toLowerCase().trim();this.filterFunc.call(this,u,p),p&&this.marker.mark(p)},{initialOptions:Bi(this.options),val:this.modelValue?this.modelValue:this.value,size:{left:this.initialSize&&this.initialSize.left||0,right:this.initialSize&&this.initialSize.right||0},resizingProp:null,isInitialized:!1,optionsIdsWatch:[],isLoading:!1,actualName:this.isMultiple?this.name+"[]":this.name,filterString:"",actualOptions:[],actualBookmarkedOptions:{},selected:[],isOpen:!1,verticalVal:this.vertical??"bottom",allOptionsIsChecked:!0,hasTreeChildren:!1,uid:`f${(~~(Math.random()*1e8)).toString(16)}`,focusedOptionId:"",actualStrings:{searchPlaceholder:lang(this.searchPlaceholderText.length?this.searchPlaceholderText:"search_placeholder",(t=this.LANG_COMPONENTS)==null?void 0:t.COMPONENT_SELECT),emptyTitle:lang("empty_title",(n=this.LANG_COMPONENTS)==null?void 0:n.COMPONENT_SELECT),selectAllOptions:lang("all_options",(e=this.LANG_COMPONENTS)==null?void 0:e.COMPONENT_SELECT),allSelected:lang("all_selected",(o=this.LANG_COMPONENTS)==null?void 0:o.COMPONENT_SELECT),loading:lang("loading",(a=this.LANG_COMPONENTS)==null?void 0:a.COMPONENT_SELECT)+"...",selectedCount:lang("selected_count",(r=this.LANG_COMPONENTS)==null?void 0:r.COMPONENT_SELECT),buttonTitle:this.buttonTitle||lang("button_title",(s=this.LANG_COMPONENTS)==null?void 0:s.COMPONENT_SELECT),requiredDependencyNotFilled:this.requiredDependencyNotFilled||lang("required_dependency_are_not_filled",(d=this.LANG_COMPONENTS)==null?void 0:d.COMPONENT_SELECT),...this.strings},dependencyValue:null}},methods:{onBlur(){setTimeout(()=>{this.isOpen||this.$emit("blur")},200)},inputKeyupDown(){this.focusOnFirstOptions()},comboboxKeyupDown(){if(this.showSearch){this.$refs.search.focus();return}this.focusOnFirstOptions()},focus(){this.$refs.combobox.focus()},focusOnFirstOptions(){this.$refs.list.$el.querySelector("[tabindex]:not(hidden)").focus()},startResizing(t){this.resizingProp=t},endResizing(){this.resizingProp&&(this.resizingProp=null,this.$emit("resize",this.size))},onResize(t){switch(this.resizingProp){case"left":this.size.left=Math.max(this.size.left-t.movementX,0);break;case"right":this.size.right=Math.max(this.size.right+t.movementX,0);break}},registerDependency(t){this.dependency?(this.$globalEvents.$on("select-"+this.dependency+":update",n=>{this.clear(),this.dependencyValue=n,this.dependencyValue&&this.dependencyValue.values&&(!Array.isArray(this.dependencyValue.values)||this.dependencyValue.values.length)&&this.setPreparedValues()}),this.isLoading=!1):(this.$globalEvents.$off("select-"+t+":update"),this.setPreparedValues().then(()=>{const n=Object.keys(this.selected);this.$globalEvents.$emit("select-"+this.filterId+":update",{values:n,filter:this.filterId})}))},filter(t,n){this.filterString=t,this.$emit("search",{search:this.filterString}),this.defaultFilter(n)},setPreparedValues(t){let n=t||this.initialOptions;return this.alphabetSort&&(n=n.sort((e,o)=>e.title.toLowerCase().localeCompare(o.title.toLowerCase()))),this.prepare(n).then(([e,o])=>{this.actualOptions=e,this.allOptionsIsChecked=this.checkIfOptionsChecked(e),this.isInitialized=!0,this.selected=o,this.setBookmarkedOptions(e)})},clear(){this.setPreparedValues(),this.allOptionsIsChecked=!1,this.selected=[],this.isMultiple?(this.$emit("update:modelValue",null),this.$emit("input",null),this.$emit("clear-value",null)):(this.$emit("update:modelValue",[]),this.$emit("input",[]),this.$emit("clear-value",[])),this.setPreparedValues()},clearValue(){this.clear(),this.setPreparedValues()},prepare(t){return new Promise(n=>{const e={},o=[];let a=Promise.resolve();typeof t=="function"?(this.isLoading=!0,this.dependency&&(t=t.bind(null,this.dependencyValue)),a=a.then(t)):a=a.then(()=>t),a.then(r=>(this.isLoading=!1,r.forEach(s=>{s.initiallyVisible=typeof s.visible>"u"?!0:s.visible,s.visible=s.initiallyVisible,s.readonly=!!s.readonly,s.isDisabled=!1,s.checked=this.isMultiple?this.val!==null&&this.val.findIndex(d=>s.id==d)>-1:this.val!==null&&this.val==s.id,s.checked&&(!this.onlyEndNodes||!s.children)&&(e[s.id]=s),s.children&&(this.hasTreeChildren=!0,s.isChildrenVisible=!1),o.push(new Promise(d=>{s.children?this.prepare(s.children).then(([u,p])=>{s.children=u,Object.assign(e,p),d(s)}):d(s)}))}),Promise.all(o).then(s=>{n([s,e])}))).catch(r=>{throw this.isLoading=!1,r})})},filterFunc(t,n){let e=0;return t.forEach(o=>{let a=o.initiallyVisible&&o.title&&o.title.toString().toLowerCase().includes(n)&&!this.actualBookmarkedOptions[o.id];if(o.children&&o.children.length){let r=this.filterFunc(o.children,n);e+=r,r&&(o.isChildrenVisible=!!n||!!Object.keys(this.actualBookmarkedOptions).length,o.isDisabled=r<o.children.length&&!this.isBookmarkable),a?r||(a=!1):a=!!r}o.visible=a,a&&e++}),e},submit(){this.change();const t=Object.keys(this.selected);this.$globalEvents.$emit("select-"+this.filterId+":submit",{values:t,filter:this.filterId}),this.$emit("submit")},change(){const t=Object.keys(this.selected);this.isMultiple?(this.$emit("update:modelValue",t),this.$emit("input",t)):(this.$emit("update:modelValue",t[0]),this.$emit("input",t[0])),this.$globalEvents.$emit("select-"+this.filterId+":update",{values:t,filter:this.filterId}),this.$refs.dropdown.close()},checkIfOptionsChecked(t){return t.every(n=>n.checked||n.readonly)},registerCheck(t,n,e){if(n)if(t.checked=!0,this.isMultiple)this.onlyEndNodes&&t.children&&t.children.length||(this.selected[t.id]=t,this.$emit("update:modelValue",Object.keys(this.selected)),this.$emit("input",Object.keys(this.selected)));else{const o=Object.keys(this.selected)[0];o&&(this.selected[o].checked=!1),this.selected={[t.id]:t},this.change()}else delete this.selected[t.id],t.checked=!1,this.$emit("update:modelValue",Object.keys(this.selected)),this.$emit("input",Object.keys(this.selected));this.toggleDuplicateOptions(this.actualOptions,t.id,n),e&&(this.allOptionsIsChecked=this.checkIfOptionsChecked(this.actualOptions))},toggleDuplicateOptions(t,n,e){for(let o of t)o.id===n&&(o.checked=e),o.children&&this.toggleDuplicateOptions(o.children,n,e)},manageAll(){this.allOptionsIsChecked=!this.allOptionsIsChecked,this.traverseTree(this.actualOptions,t=>{t.readonly||this.registerCheck(t,this.allOptionsIsChecked,!1)})},traverseTree(t,n){t.forEach(e=>{n(e),e.children&&e.children.length&&this.traverseTree(e.children,n)})},getArrayOptions(t){let n=[];for(let e of t)n.push(e),e.children&&(n=n.concat(this.getArrayOptions(e.children)));return n},toggleBookmark(t){this.actualBookmarkedOptions[t.id]?delete this.actualBookmarkedOptions[t.id]:this.actualBookmarkedOptions[t.id]=t,this.$emit("toggle-bookmarked-option",t.id),this.filter(this.filterString,this.actualOptions)},setBookmarkedOptions(t){t.forEach(n=>{n.children&&n.children.length?this.setBookmarkedOptions(n.children):this.initBookmarks.includes(n.id)&&(this.actualBookmarkedOptions[n.id]=n)}),this.filter(this.filterString,t)},onClose(){this.isOpen=!1,this.filter("",this.actualOptions),this.isMultiple?this.$emit("close",Object.keys(this.selected)):this.$emit("close",Object.keys(this.selected)[0]),this.$emit("blur"),this.verticalVal=this.vertical??"bottom"},onOpen(){const t=document.documentElement.scrollHeight;this.isOpen=!0,this.vertical!=="bottom"&&this.$nextTick(()=>{document.documentElement.scrollHeight>t&&(this.verticalVal="top")})}},computed:{hasTrigger(){return!!this.$slots.trigger},hasTriggerContent(){return!!this.$slots.triggerContent},hasEmptyMessage(){return!!this.$slots.emptyMessage},treeDropPos(){return this.menuSize?{width:this.menuSize+"px",maxWidth:this.menuSize+"px",minWidth:this.menuSize+"px"}:{width:"auto",position:"absolute",left:-this.size.left+"px",right:-this.size.right+"px"}},hasHierarchy(){return this.actualOptions.some(t=>t.children)},selectedKeys(){return Object.keys(this.selected).filter(t=>{if(!this.onlyEndNodes||!this.selected[t].children)return!0})},selectStatus(){return this.staticPlaceholder?this.placeholder:this.isLoading?this.actualStrings.loading:this.selectedKeys.length?this.selectedKeys.length<this.maxSelectedNames?this.selectedKeys.map(t=>this.selected[t].title).join(","):this.selectedKeys.length<this.optionsCount?this.actualStrings.selectedCount.replace("{selected}",this.selectedKeys.length).replace("{all}",this.optionsCount):this.actualStrings.allSelected:this.emptyMessage},isEmpty(){return Array.isArray(this.value)?!this.value.length:!this.value},requiredDependencyNotFilled(){return this.dependency&&(!this.dependencyValue||!this.dependencyValue.values||!this.dependencyValue.values.length)},showSearch(){return this.useSearch||this.optionsCount>10},arrayOfOptions(){return this.getArrayOptions(this.actualOptions)},optionsCount(){let t=[];for(let n of this.arrayOfOptions)(!this.onlyEndNodes||!n.children)&&!t.includes(n.id)&&t.push(n.id);return t.length},visibleOptionsCount(){let t=[];return this.traverseTree(this.actualOptions,n=>{(!this.onlyEndNodes||!n.children)&&!t.includes(n.id)&&n.visible&&t.push(n.id)}),t.length+(this.isBookmarkable?Object.keys(this.actualBookmarkedOptions).length:0)}},components:{IbAlert:Pt,IbIconButton:ut,IbIcon:Le,IbDropdown:Ln,IbInput:br,List:mr,"select-option":Ls},beforeUnmount(){document.removeEventListener("mousemove",this.onResize),document.removeEventListener("mouseup",this.endResizing)}},qs={key:0,class:"tree-select-empty"},Fs={key:1,class:"tree-select-default-empty tree-select-empty"};function Hs(t,n,e,o,a,r){const s=i.resolveComponent("ib-alert"),d=i.resolveComponent("ib-icon"),u=i.resolveComponent("ib-icon-button"),p=i.resolveComponent("select-option"),h=i.resolveComponent("list"),f=i.resolveComponent("ib-input"),l=i.resolveComponent("ib-dropdown");return i.openBlock(),i.createElementBlock(i.Fragment,null,[e.errorMessage?(i.openBlock(),i.createBlock(s,{key:0,class:"tree-select-error"},{default:i.withCtx(()=>[i.createTextVNode(i.toDisplayString(e.errorMessage),1)]),_:1})):i.createCommentVNode("",!0),i.createElementVNode("div",{class:i.normalizeClass(["tree-select",{...e.classList,"tree-select-custom-trigger-content":r.hasTriggerContent}])},[i.createVNode(l,{disabled:a.isLoading,"is-resizable":e.isResizable,vertical:a.verticalVal,ref:"dropdown",onClose:r.onClose,onOpen:r.onOpen},i.createSlots({body:i.withCtx(()=>[i.createElementVNode("div",{class:i.normalizeClass(["tree-drop",{"not-tree-child":!a.hasTreeChildren}]),style:i.normalizeStyle(r.treeDropPos)},[e.isResizable?(i.openBlock(),i.createElementBlock("div",{key:0,class:"ib-dropdown-resizer ib-dropdown-resizer-left",onMousedown:n[6]||(n[6]=c=>r.startResizing("left"))},null,32)):i.createCommentVNode("",!0),e.isResizable?(i.openBlock(),i.createElementBlock("div",{key:1,class:"ib-dropdown-resizer ib-dropdown-resizer-right",onMousedown:n[7]||(n[7]=c=>r.startResizing("right"))},null,32)):i.createCommentVNode("",!0),Object.keys(a.actualBookmarkedOptions).length>0?(i.openBlock(),i.createBlock(h,{key:2,class:i.normalizeClass({"has-hierarchy":r.hasHierarchy})},{default:i.withCtx(()=>[(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(a.actualBookmarkedOptions,c=>(i.openBlock(),i.createBlock(p,{key:"bookmark"+c.id,option:c,"parent-auto-check":!1,"is-multiple":e.isMultiple,"is-bookmarkable":!0,"is-bookmarked":!0,onCheck:r.registerCheck,onToggleBookmark:r.toggleBookmark,uid:a.uid,"only-end-nodes":e.onlyEndNodes,"html-title":e.htmlOptionTitle,"show-input":e.showInputs},null,8,["option","is-multiple","onCheck","onToggleBookmark","uid","only-end-nodes","html-title","show-input"]))),128))]),_:1},8,["class"])):i.createCommentVNode("",!0),r.showSearch?(i.openBlock(),i.createBlock(f,{key:3,class:"tree-search",ref:"search","show-icon":!0,value:a.filterString,"aria-label":e.searchPlaceholderText?e.searchPlaceholderText:a.actualStrings.searchPlaceholder,placeholder:e.searchPlaceholderText?e.searchPlaceholderText:a.actualStrings.searchPlaceholder,onInput:n[8]||(n[8]=c=>r.filter(c,a.actualOptions)),onKeyup:i.withKeys(r.inputKeyupDown,["down"])},null,8,["value","aria-label","placeholder","onKeyup"])):i.createCommentVNode("",!0),i.createVNode(h,{ref:"list",role:"listbox",class:i.normalizeClass({"tree-select-list":!0,"has-hierarchy":r.hasHierarchy})},{default:i.withCtx(()=>[!r.requiredDependencyNotFilled&&!r.visibleOptionsCount&&r.hasEmptyMessage?(i.openBlock(),i.createElementBlock("div",qs,[i.renderSlot(t.$slots,"emptyMessage")])):!r.requiredDependencyNotFilled&&!r.visibleOptionsCount?(i.openBlock(),i.createElementBlock("div",Fs,i.toDisplayString(a.actualStrings.emptyTitle),1)):i.createCommentVNode("",!0),i.withDirectives(i.createElementVNode("div",{class:"tree-select-empty"},i.toDisplayString(a.actualStrings.requiredDependencyNotFilled),513),[[i.vShow,r.requiredDependencyNotFilled]]),!e.isMultiple&&!e.isRequired&&a.actualOptions.length>0?(i.openBlock(),i.createBlock(p,{key:2,option:{title:t.lang("none","select"),id:null,checked:r.isEmpty},name:a.actualName,"parent-auto-check":e.parentAutoCheck,"is-multiple":e.isMultiple,onCheck:r.registerCheck,onToggleBookmark:r.toggleBookmark,uid:a.uid,"only-end-nodes":e.onlyEndNodes,"show-input":e.showInputs},null,8,["option","name","parent-auto-check","is-multiple","onCheck","onToggleBookmark","uid","only-end-nodes","show-input"])):i.createCommentVNode("",!0),r.requiredDependencyNotFilled?i.createCommentVNode("",!0):(i.openBlock(),i.createElementBlock(i.Fragment,{key:3},[e.allOptions&&e.isMultiple&&r.visibleOptionsCount&&!r.requiredDependencyNotFilled?(i.openBlock(),i.createBlock(p,{key:0,option:{title:a.actualStrings.selectAllOptions,id:"!all!",initiallyVisible:!0,visible:!0,isDisabled:r.visibleOptionsCount<r.optionsCount,checked:a.allOptionsIsChecked,isIndeterminate:!!Object.keys(a.selected).length},"is-toggle":e.isToggle,name:a.actualName,"parent-auto-check":!1,"is-multiple":e.isMultiple,"is-bookmarkable":!1,uid:a.uid,"only-end-nodes":e.onlyEndNodes,"show-input":e.showInputs,onCheck:r.manageAll,onOnFocus:n[9]||(n[9]=c=>a.focusedOptionId=c)},null,8,["option","is-toggle","name","is-multiple","uid","only-end-nodes","show-input","onCheck"])):i.createCommentVNode("",!0),(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(a.actualOptions,c=>i.renderSlot(t.$slots,a.actualName,{key:e.name+c.value,option:c,parentAutoCheck:e.parentAutoCheck,isMultiple:e.isMultiple,uid:a.uid,onlyEndNodes:e.onlyEndNodes,htmlTitle:e.htmlOptionTitle,showInput:e.showInputs},()=>[i.withDirectives(i.createVNode(p,{option:c,"is-toggle":e.isToggle,name:a.actualName,"parent-auto-check":e.parentAutoCheck,"is-multiple":e.isMultiple,"is-bookmarkable":e.isBookmarkable,uid:a.uid,"only-end-nodes":e.onlyEndNodes,"html-title":e.htmlOptionTitle,"show-input":e.showInputs,onCheck:r.registerCheck,onToggleBookmark:r.toggleBookmark,onOnFocus:n[10]||(n[10]=_=>a.focusedOptionId=_)},null,8,["option","is-toggle","name","parent-auto-check","is-multiple","is-bookmarkable","uid","only-end-nodes","html-title","show-input","onCheck","onToggleBookmark"]),[[i.vShow,c.visible]])])),128))],64))]),_:3},8,["class"])],6)]),_:2},[r.hasTrigger?{name:"trigger",fn:i.withCtx(()=>[i.renderSlot(t.$slots,"trigger",{selectedCount:r.selectedKeys.length})]),key:"0"}:{name:"trigger",fn:i.withCtx(({isOpened:c})=>[i.createElementVNode("div",{role:"combobox",tabindex:"0",class:i.normalizeClass(["tree-choice",{"tree-choice-opened":c,"has-clear-button":e.showClearButton,"tree-choice-error":e.errorMessage}]),ref:"combobox",onClick:n[2]||(n[2]=i.withModifiers(()=>{},["prevent"])),onBlur:n[3]||(n[3]=(..._)=>r.onBlur&&r.onBlur(..._)),onKeyup:[n[4]||(n[4]=i.withKeys((..._)=>r.comboboxKeyupDown&&r.comboboxKeyupDown(..._),["down"])),n[5]||(n[5]=i.withKeys((..._)=>r.comboboxKeyupDown&&r.comboboxKeyupDown(..._),["up"]))],"aria-label":e.ariaLabel,"aria-activedescendant":a.focusedOptionId},[r.hasTriggerContent?i.renderSlot(t.$slots,"triggerContent",{key:0,selectedCount:r.selectedKeys.length}):(i.openBlock(),i.createElementBlock(i.Fragment,{key:1},[e.htmlOptionTitle?(i.openBlock(),i.createElementBlock("span",{key:0,class:i.normalizeClass({placeholder:!r.selectStatus}),innerHTML:r.selectStatus||e.placeholder},null,10,["innerHTML"])):(i.openBlock(),i.createElementBlock("span",{key:1,class:i.normalizeClass({placeholder:!r.selectStatus})},i.toDisplayString(r.selectStatus||e.placeholder),3))],64)),e.showClearButton?i.withDirectives((i.openBlock(),i.createBlock(u,{key:2,kind:"ghost",class:"button-clear",onClick:i.withModifiers(r.clearValue,["prevent"]),onKeypress:n[0]||(n[0]=i.withKeys(i.withModifiers(()=>{},["stop","prevent"]),["enter"])),onKeydown:n[1]||(n[1]=i.withKeys(i.withModifiers(()=>{},["stop","prevent"]),["enter"])),onKeyup:i.withKeys(i.withModifiers(r.clearValue,["prevent"]),["enter"]),"help-text":e.clearButtonMessage},{default:i.withCtx(()=>[i.createVNode(d,{name:"close-outline"})]),_:1},8,["onClick","onKeyup","help-text"])),[[i.vShow,Object.keys(a.selected).length]]):i.createCommentVNode("",!0),i.createVNode(d,{name:c?"chevron-up-outline":"chevron-down-outline",classes:"tree-select-caret"},null,8,["name"])],42,["aria-label","aria-activedescendant"])]),key:"1"}]),1032,["disabled","is-resizable","vertical","onClose","onOpen"])],2)],64)}const Li=_e(Vs,[["render",Hs]]),N1="",zs={name:"IbLimitSelector",props:{labelSelect:{type:String,required:!0},value:{type:Number},options:{type:Array,default:()=>[10,25,50,100]}},watch(t){this.selected=t},data(){return{selected:this.value}},methods:{selectItem(t){this.selected=t,this.onChange(t)},onChange(t){Number.isInteger(+t)&&this.$emit("select",+t)}},computed:{prepareOptions(){return this.options.map(t=>({id:t,title:t}))}},components:{IbLabel:dn,IbSelect:Li}},Us={class:"report-limit-selector"};function Ks(t,n,e,o,a,r){const s=i.resolveComponent("ib-label"),d=i.resolveComponent("ib-select");return i.openBlock(),i.createElementBlock("div",Us,[i.createVNode(s,null,{default:i.withCtx(()=>[i.createTextVNode(i.toDisplayString(e.labelSelect),1)]),_:1}),i.createVNode(d,{classList:"report-limit-selector-select",value:e.value,options:r.prepareOptions,"is-multiple":!1,"show-clear-button":!1,onInput:r.selectItem},null,8,["value","options","onInput"])])}const Ri=_e(zs,[["render",Ks]]),x1="",Gs={name:"IbPagination",props:{tooltipTextPrev:{type:String},tooltipTextNext:{type:String},labelInput:{type:String},labelSelect:{type:String,required:!0},countRows:{type:Number,required:!0},pageCount:{type:Number,default:null},current:{type:Number,default:1},limitSelector:{type:Number,default:10},showPaginationInput:{type:Boolean,default:!0}},data(){return{currentPage:this.current,indexSpaceLeft:null,indexSpaceRight:null,limitValue:this.limitSelector}},watch:{current(t){this.onSelect(t)},limitValue(){this.currentPage=1}},methods:{changeLimit(t){Number.isInteger(t)&&(this.limitValue=t,this.$emit("set-limit",t))},onInput(t){if(t<1){this.onSelect(1);return}if(t>this.countPagePagination){this.onSelect(this.countPagePagination);return}this.onSelect(Number(t))},onSelect(t){Number.isInteger(t)&&(this.currentPage=t,this.$emit("select",t))},showItem(t){if(this.countPagePagination<=5)return this.indexSpaceLeft=null,this.indexSpaceRight=null,!0;if(t===1||t===this.countPagePagination)return!0;if(this.countPagePagination>=7){if(this.currentPage<=3&&t<=5)return this.indexSpaceLeft=this.countPagePagination,this.indexSpaceRight=null,!0;if(this.currentPage>=this.countPagePagination-2&&t>=this.countPagePagination-4)return this.indexSpaceLeft=null,this.indexSpaceRight=1,!0;if(3<this.currentPage<this.countPagePagination-3&&(t===this.currentPage+1||t===this.currentPage-1||t===this.currentPage))return this.indexSpaceLeft=this.countPagePagination,this.indexSpaceRight=1,!0}else return!0;return!1}},computed:{setCountOfRows(){return this.currentPage===1||this.countPagePagination===1?"1 - "+(this.countPagePagination>1?this.limitValue:this.countRows):this.countPagePagination===this.currentPage?(this.currentPage-1)*this.limitValue+" - "+this.countRows:(this.currentPage-1)*this.limitValue+1+" - "+this.currentPage*this.limitValue},countPagePagination(){return Math.ceil(this.countRows/this.limitValue)}},components:{IbIconButton:ut,IbIcon:Le,IbInput:br,IbLabel:dn,IbLimitSelector:Ri,IbTooltip:jt}},Ys={class:"report-controls"},Ws={class:"repot-pagination"},Zs={class:"pagination-input"},Js={class:"row-count"},Xs={class:"pagination-wrapper"},Qs=["onClick"];function ed(t,n,e,o,a,r){const s=i.resolveComponent("ib-limit-selector"),d=i.resolveComponent("ib-label"),u=i.resolveComponent("ib-input"),p=i.resolveComponent("ib-icon"),h=i.resolveComponent("ib-tooltip"),f=i.resolveComponent("ib-icon-button");return i.openBlock(),i.createElementBlock("div",Ys,[i.createVNode(s,{onSelect:r.changeLimit,value:a.limitValue,"label-select":e.labelSelect},null,8,["onSelect","value","label-select"]),i.createElementVNode("div",Ws,[e.showPaginationInput?(i.openBlock(),i.createElementBlock(i.Fragment,{key:0},[i.createVNode(d,null,{default:i.withCtx(()=>[i.createTextVNode(i.toDisplayString(e.labelInput),1)]),_:1}),i.createElementVNode("div",Zs,[i.createVNode(u,{type:"number",debounce:500,onInput:r.onInput},null,8,["onInput"])])],64)):i.createCommentVNode("",!0),i.createElementVNode("div",Js,i.toDisplayString(r.setCountOfRows+" of "+e.countRows),1),i.createVNode(f,{kind:"tertiary",size:"m",class:"toggle-children button-prev",disabled:a.currentPage===1,onClick:n[0]||(n[0]=l=>r.onSelect(a.currentPage-1))},{default:i.withCtx(()=>[i.createVNode(p,{name:"chevron-back-outline"}),e.tooltipTextPrev?(i.openBlock(),i.createBlock(h,{key:0,text:e.tooltipTextPrev},null,8,["text"])):i.createCommentVNode("",!0)]),_:1},8,["disabled"]),i.createElementVNode("ul",Xs,[(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(r.countPagePagination,(l,c)=>i.withDirectives((i.openBlock(),i.createElementBlock("li",{key:c,class:i.normalizeClass(["pagination-item",{active:c+1===a.currentPage,"dots-left":a.indexSpaceLeft===c+1,"dots-right":a.indexSpaceRight===c+1}]),onClick:_=>r.onSelect(c+1)},[i.createElementVNode("button",null,i.toDisplayString(c+1),1)],10,Qs)),[[i.vShow,r.showItem(c+1)]])),128))]),i.createVNode(f,{kind:"tertiary",size:"m",class:"toggle-children button-next",disabled:a.currentPage===r.countPagePagination,onClick:n[1]||(n[1]=l=>r.onSelect(a.currentPage+1))},{default:i.withCtx(()=>[i.createVNode(p,{name:"chevron-forward-outline"}),e.tooltipTextNext?(i.openBlock(),i.createBlock(h,{key:0,text:e.tooltipTextNext},null,8,["text"])):i.createCommentVNode("",!0)]),_:1},8,["disabled"])])])}const td=_e(Gs,[["render",ed]]),cn={PROGRESS:"progress",SUCCESS:"success",FAILED:"failed",CANCELING:"canceling",CANCELED:"canceled"},A1="",nd={props:{states:{type:String,default:cn.PROGRESS},progress:{type:[String,Number],default:0},ariaLabel:{type:String,required:!0}},computed:{classes(){const t=["ib-progress-bar"];return t.push(`progress-bar-${this.states}`),t},iconName(){return this.states===cn.SUCCESS?"checkmark-circle":this.states===cn.FAILED||this.states===cn.CANCELING||this.states===cn.CANCELED?"close-circle":""}},components:{IbIcon:Le}},ji=t=>(i.pushScopeId("data-v-a0217859"),t=t(),i.popScopeId(),t),rd={class:"ib-progress-bar-wrapper"},id=["aria-label","aria-valuenow"],od=[ji(()=>i.createElementVNode("div",{class:"gradient"},null,-1))],ad=ji(()=>i.createElementVNode("div",null,null,-1));function ld(t,n,e,o,a,r){const s=i.resolveComponent("ib-icon");return i.openBlock(),i.createElementBlock("div",rd,[i.createElementVNode("div",{class:i.normalizeClass(r.classes)},[i.createElementVNode("div",{class:"progress",role:"meter","aria-label":e.ariaLabel,"aria-valuemin":"0","aria-valuemax":"100","aria-valuenow":e.progress,style:i.normalizeStyle({width:e.progress+"%"})},od,12,id),ad],2),i.withDirectives(i.createVNode(s,{class:"status-icon",name:r.iconName},null,8,["name"]),[[i.vShow,r.iconName.length]])])}const sd=_e(nd,[["render",ld],["__scopeId","data-v-a0217859"]]),dd={new:`<svg width="11" height="11" viewBox="0 0 11 11" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
27
27
|
<circle id="Ellipse" cx="5.5" cy="5.5" r="5" fill="#0369E8"/>
|
|
28
28
|
</svg>
|
|
29
29
|
`,success:`
|
package/package.json
CHANGED
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
:disabled="disabled"
|
|
16
16
|
:required="required"
|
|
17
17
|
v-model="checked"
|
|
18
|
-
@click
|
|
18
|
+
@click="onChange"
|
|
19
19
|
/>
|
|
20
20
|
<div class="ib-checkbox-body">
|
|
21
21
|
<span
|
|
@@ -116,8 +116,11 @@ export default {
|
|
|
116
116
|
};
|
|
117
117
|
},
|
|
118
118
|
methods: {
|
|
119
|
-
onChange() {
|
|
120
|
-
if (this.readonly)
|
|
119
|
+
onChange(e) {
|
|
120
|
+
if (this.readonly) {
|
|
121
|
+
e.preventDefault();
|
|
122
|
+
return;
|
|
123
|
+
};
|
|
121
124
|
|
|
122
125
|
this.checked = !this.checked;
|
|
123
126
|
this.$emit("update:modelValue", this.checked);
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
<ib-dropdown
|
|
13
13
|
:disabled="isLoading"
|
|
14
14
|
:is-resizable="isResizable"
|
|
15
|
-
:vertical="
|
|
15
|
+
:vertical="verticalVal"
|
|
16
16
|
ref="dropdown"
|
|
17
17
|
@close="onClose"
|
|
18
18
|
@open="onOpen"
|
|
@@ -393,10 +393,10 @@ export default {
|
|
|
393
393
|
type: Boolean,
|
|
394
394
|
default: false,
|
|
395
395
|
},
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
396
|
+
vertical: {
|
|
397
|
+
type: String,
|
|
398
|
+
// default: "bottom"
|
|
399
|
+
},
|
|
400
400
|
emptyMessage: {
|
|
401
401
|
type: String,
|
|
402
402
|
default: "",
|
|
@@ -545,7 +545,7 @@ export default {
|
|
|
545
545
|
actualBookmarkedOptions: {},
|
|
546
546
|
selected: [],
|
|
547
547
|
isOpen: false,
|
|
548
|
-
|
|
548
|
+
verticalVal: this.vertical ?? "bottom",
|
|
549
549
|
allOptionsIsChecked: true,
|
|
550
550
|
hasTreeChildren: false,
|
|
551
551
|
uid: `f${(~~(Math.random() * 1e8)).toString(16)}`,
|
|
@@ -942,16 +942,18 @@ export default {
|
|
|
942
942
|
this.$emit("close", Object.keys(this.selected)[0]);
|
|
943
943
|
}
|
|
944
944
|
this.$emit("blur");
|
|
945
|
-
this.
|
|
945
|
+
this.verticalVal = this.vertical ?? "bottom";
|
|
946
946
|
},
|
|
947
947
|
onOpen() {
|
|
948
948
|
const screenHeight = document.documentElement.scrollHeight;
|
|
949
949
|
this.isOpen = true;
|
|
950
950
|
|
|
951
|
+
if (this.vertical === "bottom") return;
|
|
952
|
+
|
|
951
953
|
this.$nextTick(() => {
|
|
952
954
|
const newScreenHeight = document.documentElement.scrollHeight
|
|
953
955
|
if(newScreenHeight > screenHeight) {
|
|
954
|
-
this.
|
|
956
|
+
this.verticalVal = "top";
|
|
955
957
|
}
|
|
956
958
|
})
|
|
957
959
|
}
|