@wikicasa-dev/components 2.1.2-alpha.3 → 2.1.2
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/UIKit/AccessibleSelect.js +1 -1
- package/dist/UIKit/Accordion/BaseAccordion.js +1 -1
- package/dist/UIKit/Accordion/BaseAccordionBtn.js +1 -1
- package/dist/UIKit/Accordion/BaseAccordionContent.js +1 -1
- package/dist/UIKit/Accordion/BaseAccordionItem.js +1 -1
- package/dist/UIKit/BaseAlert.js +2 -3
- package/dist/UIKit/BaseAutocomplete.js +1 -1
- package/dist/UIKit/BaseBadge.js +2 -3
- package/dist/UIKit/BaseBreadcrumb.js +1 -1
- package/dist/UIKit/BaseButton.js +1 -1
- package/dist/UIKit/BaseCard.js +36 -5
- package/dist/UIKit/BaseComplexToggle.js +105 -5
- package/dist/UIKit/BaseDropDown.js +1 -1
- package/dist/UIKit/BaseFloatingLabel.js +39 -5
- package/dist/UIKit/BaseIcon.js +25 -4
- package/dist/UIKit/BaseInput.js +210 -5
- package/dist/UIKit/BaseModal.js +2 -3
- package/dist/UIKit/BasePagination.js +1 -1
- package/dist/UIKit/BasePaper.js +9 -9
- package/dist/UIKit/BaseSelect/SelectItem.js +1 -1
- package/dist/UIKit/BaseSlider.js +206 -5
- package/dist/UIKit/BaseSnackbar.js +80 -5
- package/dist/UIKit/BaseTextarea.js +126 -5
- package/dist/UIKit/BaseToggle.js +41 -5
- package/dist/UIKit/BaseTooltip.js +40 -5
- package/dist/UIKit/BaseUploadFile.js +1 -1
- package/dist/UIKit/Checkbox/CheckboxBtn.js +74 -5
- package/dist/UIKit/Checkbox/CheckboxGroup.js +1 -1
- package/dist/UIKit/Radio/RadioButton.js +1 -1
- package/dist/UIKit/Radio/RadioGroup.js +1 -1
- package/dist/UIKit/ShimmerLoader/BaseShimmerLoader.js +20 -5
- package/dist/UIKit/ShimmerLoader/ShimmerMultiLine.js +1 -1
- package/dist/UIKit/Slider/SimpleSlider.js +81 -5
- package/dist/UIKit/StaticSpinner.js +26 -5
- package/dist/UIKit/Tab/BaseTab.js +1 -1
- package/dist/UIKit/Tab/BaseTabList.js +1 -1
- package/dist/UIKit/Tab/BaseTabPanel.js +1 -1
- package/dist/UIKit/Tab/BaseTabView.js +1 -1
- package/dist/assets/SwiperCarousel.css +1 -0
- package/dist/chart/DoughnutChart.js +1 -1
- package/dist/chart/LineChart.js +1 -1
- package/dist/chunks/AccessibleSelect.vue_vue_type_script_setup_true_lang.gRPd8LaO.js +246 -0
- package/dist/{node_modules/.pnpm/@wikicasa-dev_svg-icons@1.2.11_typescript@5.8.3/node_modules/@wikicasa-dev/svg-icons/dist/ArrowIcon.js → chunks/ArrowIcon.Bq6Xr3uH.js} +3 -3
- package/dist/chunks/BaseAccordion.vue_vue_type_script_setup_true_lang.BJW28Y_i.js +32 -0
- package/dist/{packages/components/lib/UIKit/Accordion/BaseAccordionBtn.vue.js → chunks/BaseAccordionBtn.vue_vue_type_script_setup_true_lang.APN3hif2.js} +8 -8
- package/dist/{packages/components/lib/UIKit/Accordion/BaseAccordionContent.vue.js → chunks/BaseAccordionContent.vue_vue_type_script_setup_true_lang.Dn4qNu2R.js} +1 -1
- package/dist/{packages/components/lib/UIKit/Accordion/BaseAccordionItem.vue.js → chunks/BaseAccordionItem.vue_vue_type_script_setup_true_lang.Dpjir3yq.js} +21 -21
- package/dist/{packages/components/lib/UIKit/BaseAlert.vue.js → chunks/BaseAlert.vue_vue_type_style_index_0_lang.DUWb9d9_.js} +2 -2
- package/dist/{packages/components/lib/UIKit/BaseAutocomplete.vue.js → chunks/BaseAutocomplete.vue_vue_type_script_setup_true_lang.Ol7Hmb-E.js} +74 -64
- package/dist/chunks/BaseBadge.vue_vue_type_style_index_0_lang.D2PAy8_x.js +19 -0
- package/dist/{packages/components/lib/UIKit/BaseBreadcrumb.vue.js → chunks/BaseBreadcrumb.vue_vue_type_script_setup_true_lang.DlSPjwQe.js} +5 -5
- package/dist/{packages/components/lib/UIKit/BaseButton.vue.js → chunks/BaseButton.vue_vue_type_script_setup_true_lang.BPSr-Zxr.js} +6 -6
- package/dist/{packages/components/lib/UIKit/BaseDropDown.vue.js → chunks/BaseDropDown.vue_vue_type_script_setup_true_lang.Cb0-JXG0.js} +25 -25
- package/dist/{packages/components/lib/UIKit/BaseModal.vue.js → chunks/BaseModal.vue_vue_type_style_index_0_lang.CCb032YN.js} +61 -56
- package/dist/{packages/components/lib/UIKit/BasePagination.vue.js → chunks/BasePagination.vue_vue_type_script_setup_true_lang.Cbo8eLhz.js} +83 -71
- package/dist/{packages/components/lib/UIKit/Tab/BaseTab.vue.js → chunks/BaseTab.vue_vue_type_script_setup_true_lang.Cu67jd8K.js} +3 -3
- package/dist/{packages/components/lib/UIKit/Tab/BaseTabList.vue.js → chunks/BaseTabList.vue_vue_type_script_setup_true_lang.CHOGs5d-.js} +1 -1
- package/dist/{packages/components/lib/UIKit/Tab/BaseTabPanel.vue.js → chunks/BaseTabPanel.vue_vue_type_script_setup_true_lang.CVJUssBq.js} +1 -1
- package/dist/{packages/components/lib/UIKit/Tab/BaseTabView.vue.js → chunks/BaseTabView.vue_vue_type_script_setup_true_lang.CUgJNst9.js} +17 -17
- package/dist/{packages/components/lib/UIKit/BaseUploadFile.vue.js → chunks/BaseUploadFile.vue_vue_type_script_setup_true_lang.CdwKhQoc.js} +2 -2
- package/dist/chunks/CheckboxGroup.vue_vue_type_script_setup_true_lang.C9gKO-hI.js +111 -0
- package/dist/{node_modules/.pnpm/@wikicasa-dev_svg-icons@1.2.11_typescript@5.8.3/node_modules/@wikicasa-dev/svg-icons/dist/CloseIcon.js → chunks/CloseIcon.BZ4U3aiI.js} +11 -11
- package/dist/chunks/DoughnutChart.vue_vue_type_script_setup_true_lang.M0NEigw0.js +27 -0
- package/dist/{packages/components/lib/components/IntersectionObserver/IntersectionObservable.vue.js → chunks/IntersectionObservable.vue_vue_type_script_setup_true_lang.DC17cx-h.js} +5 -5
- package/dist/{packages/components/lib/components/IntersectionObserver/IntersectionObserver.vue.js → chunks/IntersectionObserver.vue_vue_type_script_setup_true_lang.BKewKDXG.js} +4 -4
- package/dist/{packages/components/lib/chart/LineChart.vue.js → chunks/LineChart.vue_vue_type_script_setup_true_lang.ByrHxeZr.js} +2 -2
- package/dist/chunks/ObjectUtils.DwkJjVq1.js +10 -0
- package/dist/chunks/PharmacyIcon.DEQ8mOEJ.js +11 -0
- package/dist/{packages/components/lib/UIKit/Radio/RadioButton.vue.js → chunks/RadioButton.vue_vue_type_script_setup_true_lang.DRQnjRA7.js} +9 -9
- package/dist/{packages/components/lib/UIKit/Radio/RadioGroup.vue.js → chunks/RadioGroup.vue_vue_type_script_setup_true_lang.CpsMf2PN.js} +6 -6
- package/dist/{packages/components/lib/UIKit/BaseSelect/SelectItem.vue.js → chunks/SelectItem.vue_vue_type_script_setup_true_lang.Drq_K7Vx.js} +1 -1
- package/dist/{packages/components/lib/UIKit/ShimmerLoader/ShimmerMultiLine.vue.js → chunks/ShimmerMultiLine.vue_vue_type_script_setup_true_lang.BoEMYLem.js} +8 -8
- package/dist/chunks/_plugin-vue_export-helper.CHgC5LLL.js +9 -0
- package/dist/chunks/polyline.tNTK3v2u.js +129 -0
- package/dist/chunks/useKeyboardController.Cs_5GQTJ.js +41 -0
- package/dist/components/IntersectionObserver/IntersectionObservable.js +1 -1
- package/dist/components/IntersectionObserver/IntersectionObserver.js +1 -1
- package/dist/components/carousel/SwiperCarousel.js +1593 -6
- package/dist/components/carousel/SwiperSlide.js +1 -1
- package/dist/index.js +85 -89
- package/package.json +1 -1
- package/dist/_virtual/_plugin-vue_export-helper.js +0 -9
- package/dist/_virtual/polyline.js +0 -2
- package/dist/assets/node_modules/.pnpm/swiper@11.2.6/node_modules/swiper/modules/free-mode.css +0 -1
- package/dist/assets/node_modules/.pnpm/swiper@11.2.6/node_modules/swiper/modules/navigation.css +0 -1
- package/dist/assets/node_modules/.pnpm/swiper@11.2.6/node_modules/swiper/modules/pagination.css +0 -1
- package/dist/assets/node_modules/.pnpm/swiper@11.2.6/node_modules/swiper/modules/zoom.css +0 -1
- package/dist/assets/node_modules/.pnpm/swiper@11.2.6/node_modules/swiper/swiper.css +0 -1
- package/dist/assets/packages/components/lib/components/carousel/SwiperCarousel.css +0 -1
- package/dist/assets/packages/components/lib/components/carousel/SwiperCarousel2.css +0 -1
- package/dist/node_modules/.pnpm/@wikicasa-dev_svg-icons@1.2.11_typescript@5.8.3/node_modules/@wikicasa-dev/svg-icons/dist/DefaultValues-CpabIgVz.js +0 -9
- package/dist/node_modules/.pnpm/@wikicasa-dev_svg-icons@1.2.11_typescript@5.8.3/node_modules/@wikicasa-dev/svg-icons/dist/PharmacyIcon.js +0 -2
- package/dist/node_modules/.pnpm/@wikicasa-dev_svg-icons@1.2.11_typescript@5.8.3/node_modules/@wikicasa-dev/svg-icons/dist/WarningIconRounded.js +0 -40
- package/dist/node_modules/.pnpm/@wikicasa-dev_utilities@1.1.21/node_modules/@wikicasa-dev/utilities/dist/utils/ArrayUtils.js +0 -4
- package/dist/node_modules/.pnpm/@wikicasa-dev_utilities@1.1.21/node_modules/@wikicasa-dev/utilities/dist/utils/DeviceDetectionUtils.js +0 -4
- package/dist/node_modules/.pnpm/@wikicasa-dev_utilities@1.1.21/node_modules/@wikicasa-dev/utilities/dist/utils/FunctionUtils.js +0 -15
- package/dist/node_modules/.pnpm/@wikicasa-dev_utilities@1.1.21/node_modules/@wikicasa-dev/utilities/dist/utils/GenericUtils.js +0 -12
- package/dist/node_modules/.pnpm/@wikicasa-dev_utilities@1.1.21/node_modules/@wikicasa-dev/utilities/dist/utils/NumberUtils.js +0 -18
- package/dist/node_modules/.pnpm/@wikicasa-dev_utilities@1.1.21/node_modules/@wikicasa-dev/utilities/dist/utils/ObjectUtils.js +0 -10
- package/dist/node_modules/.pnpm/@wikicasa-dev_utilities@1.1.21/node_modules/@wikicasa-dev/utilities/dist/utils/StringUtils.js +0 -4
- package/dist/node_modules/.pnpm/@wikicasa-dev_vue-composables@0.0.23_typescript@5.8.3/node_modules/@wikicasa-dev/vue-composables/dist/useKeyboardController.js +0 -41
- package/dist/node_modules/.pnpm/google-polyline@1.0.3/node_modules/google-polyline/lib/decode.js +0 -22
- package/dist/node_modules/.pnpm/google-polyline@1.0.3/node_modules/google-polyline/lib/encode.js +0 -34
- package/dist/node_modules/.pnpm/google-polyline@1.0.3/node_modules/google-polyline/lib/polyline.js +0 -12
- package/dist/node_modules/.pnpm/js-cookie@3.0.5/node_modules/js-cookie/dist/js.cookie.js +0 -71
- package/dist/node_modules/.pnpm/swiper@11.2.6/node_modules/swiper/modules/autoplay.css.js +0 -1
- package/dist/node_modules/.pnpm/swiper@11.2.6/node_modules/swiper/modules/autoplay.js +0 -129
- package/dist/node_modules/.pnpm/swiper@11.2.6/node_modules/swiper/modules/controller.css.js +0 -1
- package/dist/node_modules/.pnpm/swiper@11.2.6/node_modules/swiper/modules/controller.js +0 -101
- package/dist/node_modules/.pnpm/swiper@11.2.6/node_modules/swiper/modules/free-mode.js +0 -125
- package/dist/node_modules/.pnpm/swiper@11.2.6/node_modules/swiper/modules/keyboard.css.js +0 -1
- package/dist/node_modules/.pnpm/swiper@11.2.6/node_modules/swiper/modules/keyboard.js +0 -67
- package/dist/node_modules/.pnpm/swiper@11.2.6/node_modules/swiper/modules/navigation.js +0 -127
- package/dist/node_modules/.pnpm/swiper@11.2.6/node_modules/swiper/modules/pagination.js +0 -227
- package/dist/node_modules/.pnpm/swiper@11.2.6/node_modules/swiper/modules/thumbs.css.js +0 -1
- package/dist/node_modules/.pnpm/swiper@11.2.6/node_modules/swiper/modules/thumbs.js +0 -121
- package/dist/node_modules/.pnpm/swiper@11.2.6/node_modules/swiper/modules/zoom.js +0 -310
- package/dist/node_modules/.pnpm/swiper@11.2.6/node_modules/swiper/shared/classes-to-selector.js +0 -6
- package/dist/node_modules/.pnpm/swiper@11.2.6/node_modules/swiper/shared/create-element-if-not-defined.js +0 -12
- package/dist/node_modules/.pnpm/swiper@11.2.6/node_modules/swiper/shared/ssr-window.esm.js +0 -135
- package/dist/node_modules/.pnpm/swiper@11.2.6/node_modules/swiper/shared/utils.js +0 -85
- package/dist/packages/components/lazyModules/Swiper/autoplay.js +0 -5
- package/dist/packages/components/lazyModules/Swiper/controller.js +0 -5
- package/dist/packages/components/lazyModules/Swiper/free-mode.js +0 -5
- package/dist/packages/components/lazyModules/Swiper/keyboard.js +0 -5
- package/dist/packages/components/lazyModules/Swiper/navigation.js +0 -5
- package/dist/packages/components/lazyModules/Swiper/pagination.js +0 -5
- package/dist/packages/components/lazyModules/Swiper/thumbs.js +0 -5
- package/dist/packages/components/lib/UIKit/AccessibleSelect.vue.js +0 -213
- package/dist/packages/components/lib/UIKit/Accordion/BaseAccordion.vue.js +0 -33
- package/dist/packages/components/lib/UIKit/BaseBadge.vue.js +0 -19
- package/dist/packages/components/lib/UIKit/BaseCard.vue.js +0 -37
- package/dist/packages/components/lib/UIKit/BaseComplexToggle.vue.js +0 -106
- package/dist/packages/components/lib/UIKit/BaseFloatingLabel.vue.js +0 -40
- package/dist/packages/components/lib/UIKit/BaseIcon.vue.js +0 -27
- package/dist/packages/components/lib/UIKit/BaseInput.vue.js +0 -211
- package/dist/packages/components/lib/UIKit/BasePaper.vue.js +0 -7
- package/dist/packages/components/lib/UIKit/BaseSlider.vue.js +0 -207
- package/dist/packages/components/lib/UIKit/BaseSnackbar.vue.js +0 -81
- package/dist/packages/components/lib/UIKit/BaseTextarea.vue.js +0 -127
- package/dist/packages/components/lib/UIKit/BaseToggle.vue.js +0 -42
- package/dist/packages/components/lib/UIKit/BaseTooltip.vue.js +0 -41
- package/dist/packages/components/lib/UIKit/Checkbox/CheckboxBtn.vue.js +0 -75
- package/dist/packages/components/lib/UIKit/Checkbox/CheckboxGroup.vue.js +0 -114
- package/dist/packages/components/lib/UIKit/ShimmerLoader/BaseShimmerLoader.vue.js +0 -21
- package/dist/packages/components/lib/UIKit/Slider/SimpleSlider.vue.js +0 -82
- package/dist/packages/components/lib/UIKit/StaticSpinner.vue.js +0 -27
- package/dist/packages/components/lib/chart/DoughnutChart.vue.js +0 -27
- package/dist/packages/components/lib/components/carousel/SwiperCarousel.vue.js +0 -242
- /package/dist/assets/{packages/components/lib/UIKit/BaseAlert.css → BaseAlert.css} +0 -0
- /package/dist/assets/{packages/components/lib/UIKit/BaseBadge.css → BaseBadge.css} +0 -0
- /package/dist/assets/{packages/components/lib/UIKit/BaseCard.css → BaseCard.css} +0 -0
- /package/dist/assets/{packages/components/lib/UIKit/BaseComplexToggle.css → BaseComplexToggle.css} +0 -0
- /package/dist/assets/{packages/components/lib/UIKit/BaseFloatingLabel.css → BaseFloatingLabel.css} +0 -0
- /package/dist/assets/{packages/components/lib/UIKit/BaseIcon.css → BaseIcon.css} +0 -0
- /package/dist/assets/{packages/components/lib/UIKit/BaseInput.css → BaseInput.css} +0 -0
- /package/dist/assets/{packages/components/lib/UIKit/BaseModal.css → BaseModal.css} +0 -0
- /package/dist/assets/{packages/components/lib/UIKit/BasePaper.css → BasePaper.css} +0 -0
- /package/dist/assets/{packages/components/lib/UIKit/ShimmerLoader/BaseShimmerLoader.css → BaseShimmerLoader.css} +0 -0
- /package/dist/assets/{packages/components/lib/UIKit/BaseSlider.css → BaseSlider.css} +0 -0
- /package/dist/assets/{packages/components/lib/UIKit/BaseSnackbar.css → BaseSnackbar.css} +0 -0
- /package/dist/assets/{packages/components/lib/UIKit/BaseTextarea.css → BaseTextarea.css} +0 -0
- /package/dist/assets/{packages/components/lib/UIKit/BaseToggle.css → BaseToggle.css} +0 -0
- /package/dist/assets/{packages/components/lib/UIKit/BaseTooltip.css → BaseTooltip.css} +0 -0
- /package/dist/assets/{packages/components/lib/UIKit/Checkbox/CheckboxBtn.css → CheckboxBtn.css} +0 -0
- /package/dist/assets/{packages/components/lib/UIKit/Slider/SimpleSlider.css → SimpleSlider.css} +0 -0
- /package/dist/assets/{packages/components/lib/UIKit/StaticSpinner.css → StaticSpinner.css} +0 -0
- /package/dist/assets/{packages/components/src/tailwind.css → index.css} +0 -0
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
import { defineComponent as y, ref as v, computed as i, watch as x, renderSlot as m, createElementVNode as D, normalizeClass as E, createElementBlock as $, createCommentVNode as B, openBlock as b, Fragment as I, renderList as R, createBlock as A, unref as K } from "vue";
|
|
2
|
+
import "./polyline.tNTK3v2u.js";
|
|
3
|
+
import L from "../UIKit/Checkbox/CheckboxBtn.js";
|
|
4
|
+
const V = (a) => !a?.length, w = (a = "") => !a || !a.trim() ? "" : (a = a.trim(), a.replace(" ", "-").toLowerCase()), G = ["id", "data-cy"], j = /* @__PURE__ */ y({
|
|
5
|
+
inheritAttrs: !1,
|
|
6
|
+
__name: "CheckboxGroup",
|
|
7
|
+
props: {
|
|
8
|
+
checkboxData: { default() {
|
|
9
|
+
return [];
|
|
10
|
+
} },
|
|
11
|
+
formCheckInline: { type: Boolean, default: !1 },
|
|
12
|
+
reset: { type: Boolean, default: !1 },
|
|
13
|
+
checkboxContainerClasses: { default: "" },
|
|
14
|
+
autoCheckResetAll: { type: Boolean, default: !1 },
|
|
15
|
+
autoCheckResetEmpty: { type: Boolean, default: !1 },
|
|
16
|
+
manualToggleResetButton: { type: Boolean, default: !1 },
|
|
17
|
+
getKey: { default() {
|
|
18
|
+
return (a) => typeof a == "string" || typeof a == "number" ? `${a}` : `${a.id}`;
|
|
19
|
+
} },
|
|
20
|
+
groupId: { default: "" },
|
|
21
|
+
dataCy: { default: "" }
|
|
22
|
+
},
|
|
23
|
+
emits: ["resetted", "update:modelValue", "checkedGroup"],
|
|
24
|
+
setup(a, { emit: C }) {
|
|
25
|
+
const c = a, s = C, l = v(/* @__PURE__ */ new Map()), r = i(() => {
|
|
26
|
+
for (const e of c.checkboxData)
|
|
27
|
+
if (e.reset) return e;
|
|
28
|
+
return null;
|
|
29
|
+
}), g = i(() => c.checkboxData.length), f = i(() => {
|
|
30
|
+
let e = 0;
|
|
31
|
+
return l.value.forEach((t) => {
|
|
32
|
+
t.checked && e++;
|
|
33
|
+
}), e;
|
|
34
|
+
});
|
|
35
|
+
(() => {
|
|
36
|
+
const e = [];
|
|
37
|
+
for (const t of c.checkboxData)
|
|
38
|
+
t.checked = !!t.checked, l.value.set(
|
|
39
|
+
`${t.id}`,
|
|
40
|
+
t
|
|
41
|
+
), t.checked && e.push(t);
|
|
42
|
+
s("update:modelValue", e);
|
|
43
|
+
})();
|
|
44
|
+
const u = (e, t) => {
|
|
45
|
+
const o = l.value.get(e);
|
|
46
|
+
if (o) {
|
|
47
|
+
if (t) {
|
|
48
|
+
l.value.set(e, { ...o, ...t });
|
|
49
|
+
return;
|
|
50
|
+
}
|
|
51
|
+
l.value.set(e, { ...o, checked: !o.checked });
|
|
52
|
+
}
|
|
53
|
+
}, k = () => {
|
|
54
|
+
l.value.forEach((e) => {
|
|
55
|
+
e.checked = !1;
|
|
56
|
+
});
|
|
57
|
+
}, p = () => {
|
|
58
|
+
k(), s("update:modelValue", []), s("resetted");
|
|
59
|
+
}, d = (e) => l.value.get(c.getKey(e))?.checked ?? !1, h = (e) => {
|
|
60
|
+
if (V(c.checkboxData)) return;
|
|
61
|
+
const t = l.value.get(e.id);
|
|
62
|
+
t?.reset && e.checked ? k() : r.value && !t?.reset && u(c.getKey(r.value), { checked: !1 }), u(`${e.id}`), c.autoCheckResetAll && r.value && f.value === g.value - 1 && l.value.forEach((n) => {
|
|
63
|
+
n.checked = !!n.reset;
|
|
64
|
+
}), c.autoCheckResetEmpty && r.value && !f.value && (!c.manualToggleResetButton || !t?.reset) && u(c.getKey(r.value), { checked: !0 });
|
|
65
|
+
const o = [];
|
|
66
|
+
l.value.forEach((n) => {
|
|
67
|
+
n.checked && o.push(n);
|
|
68
|
+
}), s("update:modelValue", o), s("checkedGroup", c.groupId);
|
|
69
|
+
};
|
|
70
|
+
return x(
|
|
71
|
+
() => c.reset,
|
|
72
|
+
(e) => {
|
|
73
|
+
e && p();
|
|
74
|
+
}
|
|
75
|
+
), (e, t) => m(e.$slots, "default", {
|
|
76
|
+
isActive: d,
|
|
77
|
+
handleChange: h,
|
|
78
|
+
checkboxesData: e.checkboxData
|
|
79
|
+
}, () => [
|
|
80
|
+
D("div", {
|
|
81
|
+
id: e.groupId,
|
|
82
|
+
class: E(["checkbox-group-container", e.$attrs.class || ""]),
|
|
83
|
+
"data-cy": e.dataCy
|
|
84
|
+
}, [
|
|
85
|
+
m(e.$slots, "checkbox_elements", {
|
|
86
|
+
isActive: d,
|
|
87
|
+
handleChange: h,
|
|
88
|
+
checkboxesData: e.checkboxData,
|
|
89
|
+
reset: p
|
|
90
|
+
}, () => [
|
|
91
|
+
e.checkboxData ? (b(!0), $(I, { key: 0 }, R(e.checkboxData, (o, n) => (b(), A(L, {
|
|
92
|
+
id: e.getKey(o),
|
|
93
|
+
key: n,
|
|
94
|
+
"data-cy": o.dataCy ?? `checkbox_${K(w)(`${o.label}`)}`,
|
|
95
|
+
label: o.label,
|
|
96
|
+
inline: e.formCheckInline,
|
|
97
|
+
"model-value": d(o),
|
|
98
|
+
"container-class": [
|
|
99
|
+
e.formCheckInline ? "uikit-mr-10px" : "uikit-mb-10px",
|
|
100
|
+
e.checkboxContainerClasses
|
|
101
|
+
],
|
|
102
|
+
onChange: h
|
|
103
|
+
}, null, 8, ["id", "data-cy", "label", "inline", "model-value", "container-class"]))), 128)) : B("", !0)
|
|
104
|
+
])
|
|
105
|
+
], 10, G)
|
|
106
|
+
]);
|
|
107
|
+
}
|
|
108
|
+
});
|
|
109
|
+
export {
|
|
110
|
+
j as _
|
|
111
|
+
};
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { h as
|
|
2
|
-
import {
|
|
3
|
-
const
|
|
1
|
+
import { h as r } from "vue";
|
|
2
|
+
import { e } from "./PharmacyIcon.DEQ8mOEJ.js";
|
|
3
|
+
const d = (t, { attrs: o }) => {
|
|
4
4
|
t = { ...e(), ...t };
|
|
5
5
|
const { width: i, height: s } = t;
|
|
6
|
-
return
|
|
6
|
+
return r(
|
|
7
7
|
"svg",
|
|
8
8
|
{
|
|
9
9
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -11,22 +11,22 @@ const a = (t, { attrs: r }) => {
|
|
|
11
11
|
width: `${i}`,
|
|
12
12
|
height: `${s}`,
|
|
13
13
|
class: t.class ?? "",
|
|
14
|
-
"aria-hidden":
|
|
14
|
+
"aria-hidden": o["aria-hidden"] ?? "true"
|
|
15
15
|
},
|
|
16
|
-
|
|
16
|
+
r(
|
|
17
17
|
"g",
|
|
18
18
|
{
|
|
19
19
|
fill: "none",
|
|
20
20
|
stroke: `${t["stroke-color"] ?? "#222"}`,
|
|
21
|
-
"stroke-linecap": `${
|
|
22
|
-
"stroke-linejoin": `${
|
|
21
|
+
"stroke-linecap": `${o["stroke-linecap"] ?? "round"}`,
|
|
22
|
+
"stroke-linejoin": `${o["stroke-linejoin"] ?? "round"}`,
|
|
23
23
|
"stroke-width": `${t["stroke-width"] ?? "3"}`
|
|
24
24
|
},
|
|
25
25
|
[
|
|
26
|
-
|
|
26
|
+
r("path", {
|
|
27
27
|
d: "m2.121 2.121 14.316 14.316"
|
|
28
28
|
}),
|
|
29
|
-
|
|
29
|
+
r("path", {
|
|
30
30
|
d: "M2.121 16.437 16.244 2.121"
|
|
31
31
|
})
|
|
32
32
|
]
|
|
@@ -34,5 +34,5 @@ const a = (t, { attrs: r }) => {
|
|
|
34
34
|
);
|
|
35
35
|
};
|
|
36
36
|
export {
|
|
37
|
-
|
|
37
|
+
d as l
|
|
38
38
|
};
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { defineComponent as i, onBeforeMount as p, createBlock as u, createCommentVNode as m, unref as t, openBlock as c } from "vue";
|
|
2
|
+
import { Doughnut as l } from "vue-chartjs";
|
|
3
|
+
import { Chart as d, DoughnutController as f, ArcElement as g } from "chart.js";
|
|
4
|
+
import { useChartJsModules as h } from "../chart/composables/useChartjsModules.js";
|
|
5
|
+
const y = /* @__PURE__ */ i({
|
|
6
|
+
__name: "DoughnutChart",
|
|
7
|
+
props: {
|
|
8
|
+
options: {},
|
|
9
|
+
data: {}
|
|
10
|
+
},
|
|
11
|
+
setup(e) {
|
|
12
|
+
d.register(f, g);
|
|
13
|
+
const r = e, { registerPlugins: n, resolved: s, executeRegistration: a } = h(
|
|
14
|
+
r.options
|
|
15
|
+
);
|
|
16
|
+
return p(async () => {
|
|
17
|
+
await a(n);
|
|
18
|
+
}), (o, C) => t(s) ? (c(), u(t(l), {
|
|
19
|
+
key: 0,
|
|
20
|
+
options: o.options,
|
|
21
|
+
data: o.data
|
|
22
|
+
}, null, 8, ["options", "data"])) : m("", !0);
|
|
23
|
+
}
|
|
24
|
+
});
|
|
25
|
+
export {
|
|
26
|
+
y as _
|
|
27
|
+
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { defineComponent as t, ref as n, onMounted as a, createElementBlock as
|
|
2
|
-
const
|
|
1
|
+
import { defineComponent as t, ref as n, onMounted as a, createElementBlock as i, renderSlot as s, openBlock as u, normalizeClass as f } from "vue";
|
|
2
|
+
const b = /* @__PURE__ */ t({
|
|
3
3
|
__name: "IntersectionObservable",
|
|
4
4
|
props: {
|
|
5
5
|
observer: { default: null },
|
|
@@ -9,16 +9,16 @@ const d = /* @__PURE__ */ t({
|
|
|
9
9
|
const r = l, o = n(null);
|
|
10
10
|
return a(() => {
|
|
11
11
|
!r.observer || !o.value || r.observer.observe(o.value);
|
|
12
|
-
}), (e, p) => e.isVisible ? s(e.$slots, "default", { key: 1 }) : (
|
|
12
|
+
}), (e, p) => e.isVisible ? s(e.$slots, "default", { key: 1 }) : (u(), i("div", {
|
|
13
13
|
key: 0,
|
|
14
14
|
ref_key: "root",
|
|
15
15
|
ref: o,
|
|
16
|
-
class:
|
|
16
|
+
class: f(e.$attrs["root-classes"])
|
|
17
17
|
}, [
|
|
18
18
|
s(e.$slots, "default")
|
|
19
19
|
], 2));
|
|
20
20
|
}
|
|
21
21
|
});
|
|
22
22
|
export {
|
|
23
|
-
|
|
23
|
+
b as _
|
|
24
24
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
const
|
|
1
|
+
import { defineComponent as p, reactive as d, ref as m, onBeforeMount as h, onBeforeUnmount as V, createElementBlock as k, renderSlot as l, unref as t, openBlock as B, normalizeClass as O } from "vue";
|
|
2
|
+
const _ = /* @__PURE__ */ p({
|
|
3
3
|
__name: "IntersectionObserver",
|
|
4
4
|
props: {
|
|
5
5
|
observeOnce: { type: Boolean, default: !0 },
|
|
@@ -9,7 +9,7 @@ const E = /* @__PURE__ */ d({
|
|
|
9
9
|
emits: ["intersection"],
|
|
10
10
|
setup(a, { emit: u }) {
|
|
11
11
|
const c = u, o = a;
|
|
12
|
-
let r =
|
|
12
|
+
let r = d({ root: null, isVisible: !1 });
|
|
13
13
|
const e = m(null), v = (s) => {
|
|
14
14
|
s.forEach(({ target: n, isIntersecting: i }) => {
|
|
15
15
|
i && (r.isVisible = !0, c("intersection")), o.observeOnce && i && b(n);
|
|
@@ -48,5 +48,5 @@ const E = /* @__PURE__ */ d({
|
|
|
48
48
|
}
|
|
49
49
|
});
|
|
50
50
|
export {
|
|
51
|
-
|
|
51
|
+
_
|
|
52
52
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { defineComponent as m, onBeforeMount as u, useTemplateRef as f, computed as d, createBlock as h, createCommentVNode as C, unref as t, openBlock as g } from "vue";
|
|
2
2
|
import { Line as L } from "vue-chartjs";
|
|
3
3
|
import { Chart as _, LineController as k, LineElement as x, Filler as y, PointElement as B, CategoryScale as E, LinearScale as v } from "chart.js";
|
|
4
|
-
import { useChartJsModules as M } from "
|
|
4
|
+
import { useChartJsModules as M } from "../chart/composables/useChartjsModules.js";
|
|
5
5
|
const A = /* @__PURE__ */ m({
|
|
6
6
|
__name: "LineChart",
|
|
7
7
|
props: {
|
|
@@ -38,5 +38,5 @@ const A = /* @__PURE__ */ m({
|
|
|
38
38
|
}
|
|
39
39
|
});
|
|
40
40
|
export {
|
|
41
|
-
A as
|
|
41
|
+
A as _
|
|
42
42
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as k, useId as m, computed as c, createElementBlock as
|
|
1
|
+
import { defineComponent as k, useId as m, computed as c, createElementBlock as p, openBlock as b, withModifiers as l, createElementVNode as n, normalizeClass as u, createTextVNode as f, toDisplayString as h } from "vue";
|
|
2
2
|
const C = ["id", "name", "checked"], V = ["for"], y = /* @__PURE__ */ k({
|
|
3
3
|
__name: "RadioButton",
|
|
4
4
|
props: {
|
|
@@ -11,7 +11,7 @@ const C = ["id", "name", "checked"], V = ["for"], y = /* @__PURE__ */ k({
|
|
|
11
11
|
},
|
|
12
12
|
emits: ["change", "update:modelValue"],
|
|
13
13
|
setup(i, { emit: d }) {
|
|
14
|
-
const o = d, a = m(),
|
|
14
|
+
const o = d, a = m(), s = c(() => `${i.id ?? a}`), r = () => {
|
|
15
15
|
if (i.modelValue) return;
|
|
16
16
|
const e = {
|
|
17
17
|
id: i.id ?? a,
|
|
@@ -20,12 +20,12 @@ const C = ["id", "name", "checked"], V = ["for"], y = /* @__PURE__ */ k({
|
|
|
20
20
|
};
|
|
21
21
|
o("change", e), o("update:modelValue", !i.modelValue);
|
|
22
22
|
};
|
|
23
|
-
return (e, t) => (
|
|
23
|
+
return (e, t) => (b(), p("div", {
|
|
24
24
|
class: "uikit-inline-block",
|
|
25
25
|
onClick: l(r, ["stop"])
|
|
26
26
|
}, [
|
|
27
27
|
n("input", {
|
|
28
|
-
id:
|
|
28
|
+
id: s.value,
|
|
29
29
|
ref: "checkbox",
|
|
30
30
|
type: "radio",
|
|
31
31
|
class: "uikit-pointer-events-none uikit-hidden",
|
|
@@ -37,22 +37,22 @@ const C = ["id", "name", "checked"], V = ["for"], y = /* @__PURE__ */ k({
|
|
|
37
37
|
}, ["prevent"]))
|
|
38
38
|
}, null, 40, C),
|
|
39
39
|
n("label", {
|
|
40
|
-
class:
|
|
41
|
-
for:
|
|
40
|
+
class: u([e.labelClasses, "uikit-flex uikit-cursor-pointer uikit-items-center uikit-text-sm"]),
|
|
41
|
+
for: s.value
|
|
42
42
|
}, [
|
|
43
43
|
n("span", {
|
|
44
|
-
class:
|
|
44
|
+
class: u(["uikit-flex-no-shrink uikit-mr-2 uikit-inline-block uikit-h-4 uikit-w-4 uikit-transform uikit-rounded-full uikit-border uikit-border-solid uikit-border-w-secondary uikit-transition-colors uikit-duration-200", [
|
|
45
45
|
{
|
|
46
46
|
"checked uikit-border-w-primary uikit-bg-w-primary uikit-shadow-[0_0_0_2px_white_inset]": e.modelValue
|
|
47
47
|
},
|
|
48
48
|
e.inputClasses
|
|
49
49
|
]])
|
|
50
50
|
}, null, 2),
|
|
51
|
-
|
|
51
|
+
f(" " + h(e.label), 1)
|
|
52
52
|
], 10, V)
|
|
53
53
|
]));
|
|
54
54
|
}
|
|
55
55
|
});
|
|
56
56
|
export {
|
|
57
|
-
y as
|
|
57
|
+
y as _
|
|
58
58
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { defineComponent as p, mergeModels as d, useModel as C, ref as h, watch as $, renderSlot as u, createElementVNode as V, normalizeClass as c, createElementBlock as k, openBlock as m, Fragment as R, renderList as g, createBlock as y } from "vue";
|
|
2
|
-
import
|
|
3
|
-
const
|
|
2
|
+
import { _ } from "./RadioButton.vue_vue_type_script_setup_true_lang.DRQnjRA7.js";
|
|
3
|
+
const b = ["data-cy"], w = /* @__PURE__ */ p({
|
|
4
4
|
inheritAttrs: !1,
|
|
5
5
|
__name: "RadioGroup",
|
|
6
6
|
props: /* @__PURE__ */ d({
|
|
@@ -28,7 +28,7 @@ const B = ["data-cy"], w = /* @__PURE__ */ p({
|
|
|
28
28
|
}
|
|
29
29
|
})(), $(n, (e) => {
|
|
30
30
|
e && t();
|
|
31
|
-
}), (e,
|
|
31
|
+
}), (e, M) => u(e.$slots, "default", {
|
|
32
32
|
handleClick: l,
|
|
33
33
|
activeValue: a.value,
|
|
34
34
|
reset: t,
|
|
@@ -44,7 +44,7 @@ const B = ["data-cy"], w = /* @__PURE__ */ p({
|
|
|
44
44
|
reset: t,
|
|
45
45
|
isActive: r
|
|
46
46
|
}, () => [
|
|
47
|
-
(m(!0), k(R, null, g(e.radioValues, (s, v) => (m(), y(
|
|
47
|
+
(m(!0), k(R, null, g(e.radioValues, (s, v) => (m(), y(_, {
|
|
48
48
|
id: s.id,
|
|
49
49
|
key: v,
|
|
50
50
|
class: c(e.radioContainerClasses),
|
|
@@ -53,10 +53,10 @@ const B = ["data-cy"], w = /* @__PURE__ */ p({
|
|
|
53
53
|
onChange: l
|
|
54
54
|
}, null, 8, ["id", "class", "label", "model-value"]))), 128))
|
|
55
55
|
])
|
|
56
|
-
], 10,
|
|
56
|
+
], 10, b)
|
|
57
57
|
]);
|
|
58
58
|
}
|
|
59
59
|
});
|
|
60
60
|
export {
|
|
61
|
-
w as
|
|
61
|
+
w as _
|
|
62
62
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import
|
|
3
|
-
const c = /* @__PURE__ */
|
|
1
|
+
import { defineComponent as t, createElementBlock as n, openBlock as r, Fragment as s, renderList as l, createBlock as m, normalizeStyle as a, normalizeClass as o } from "vue";
|
|
2
|
+
import h from "../UIKit/ShimmerLoader/BaseShimmerLoader.js";
|
|
3
|
+
const c = /* @__PURE__ */ t({
|
|
4
4
|
__name: "ShimmerMultiLine",
|
|
5
5
|
props: {
|
|
6
6
|
lines: { default: 1 },
|
|
@@ -8,8 +8,8 @@ const c = /* @__PURE__ */ i({
|
|
|
8
8
|
shimmerClasses: {},
|
|
9
9
|
inheritHeight: { type: Boolean, default: !1 }
|
|
10
10
|
},
|
|
11
|
-
setup(
|
|
12
|
-
return (e, d) => (r(!0), n(s, null, l(e.lines, (
|
|
11
|
+
setup(u) {
|
|
12
|
+
return (e, d) => (r(!0), n(s, null, l(e.lines, (i) => (r(), m(h, {
|
|
13
13
|
ref_for: !0,
|
|
14
14
|
ref: "shimmerLines",
|
|
15
15
|
class: o(["shimmer-line", [
|
|
@@ -17,13 +17,13 @@ const c = /* @__PURE__ */ i({
|
|
|
17
17
|
e.inheritHeight ? "uikit-h-[1em]" : "uikit-h-8",
|
|
18
18
|
"uikit-mb-2 uikit-rounded-xs"
|
|
19
19
|
]]),
|
|
20
|
-
key: `sml-${
|
|
21
|
-
style:
|
|
20
|
+
key: `sml-${i}`,
|
|
21
|
+
style: a({
|
|
22
22
|
marginRight: e.randomLength ? `${Math.round(Math.random() * 5) * 10}%` : 0
|
|
23
23
|
})
|
|
24
24
|
}, null, 8, ["class", "style"]))), 128));
|
|
25
25
|
}
|
|
26
26
|
});
|
|
27
27
|
export {
|
|
28
|
-
c as
|
|
28
|
+
c as _
|
|
29
29
|
};
|
|
@@ -0,0 +1,129 @@
|
|
|
1
|
+
/*! js-cookie v3.0.5 | MIT */
|
|
2
|
+
function h(t) {
|
|
3
|
+
for (var i = 1; i < arguments.length; i++) {
|
|
4
|
+
var u = arguments[i];
|
|
5
|
+
for (var a in u)
|
|
6
|
+
t[a] = u[a];
|
|
7
|
+
}
|
|
8
|
+
return t;
|
|
9
|
+
}
|
|
10
|
+
var w = {
|
|
11
|
+
read: function(t) {
|
|
12
|
+
return t[0] === '"' && (t = t.slice(1, -1)), t.replace(/(%[\dA-F]{2})+/gi, decodeURIComponent);
|
|
13
|
+
},
|
|
14
|
+
write: function(t) {
|
|
15
|
+
return encodeURIComponent(t).replace(
|
|
16
|
+
/%(2[346BF]|3[AC-F]|40|5[BDE]|60|7[BCD])/g,
|
|
17
|
+
decodeURIComponent
|
|
18
|
+
);
|
|
19
|
+
}
|
|
20
|
+
};
|
|
21
|
+
function C(t, i) {
|
|
22
|
+
function u(r, f, n) {
|
|
23
|
+
if (!(typeof document > "u")) {
|
|
24
|
+
n = h({}, i, n), typeof n.expires == "number" && (n.expires = new Date(Date.now() + n.expires * 864e5)), n.expires && (n.expires = n.expires.toUTCString()), r = encodeURIComponent(r).replace(/%(2[346B]|5E|60|7C)/g, decodeURIComponent).replace(/[()]/g, escape);
|
|
25
|
+
var e = "";
|
|
26
|
+
for (var o in n)
|
|
27
|
+
n[o] && (e += "; " + o, n[o] !== !0 && (e += "=" + n[o].split(";")[0]));
|
|
28
|
+
return document.cookie = r + "=" + t.write(f, r) + e;
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
function a(r) {
|
|
32
|
+
if (!(typeof document > "u" || arguments.length && !r)) {
|
|
33
|
+
for (var f = document.cookie ? document.cookie.split("; ") : [], n = {}, e = 0; e < f.length; e++) {
|
|
34
|
+
var o = f[e].split("="), c = o.slice(1).join("=");
|
|
35
|
+
try {
|
|
36
|
+
var d = decodeURIComponent(o[0]);
|
|
37
|
+
if (n[d] = t.read(c, d), r === d)
|
|
38
|
+
break;
|
|
39
|
+
} catch {
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
return r ? n[r] : n;
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
return Object.create(
|
|
46
|
+
{
|
|
47
|
+
set: u,
|
|
48
|
+
get: a,
|
|
49
|
+
remove: function(r, f) {
|
|
50
|
+
u(
|
|
51
|
+
r,
|
|
52
|
+
"",
|
|
53
|
+
h({}, f, {
|
|
54
|
+
expires: -1
|
|
55
|
+
})
|
|
56
|
+
);
|
|
57
|
+
},
|
|
58
|
+
withAttributes: function(r) {
|
|
59
|
+
return C(this.converter, h({}, this.attributes, r));
|
|
60
|
+
},
|
|
61
|
+
withConverter: function(r) {
|
|
62
|
+
return C(h({}, this.converter, r), this.attributes);
|
|
63
|
+
}
|
|
64
|
+
},
|
|
65
|
+
{
|
|
66
|
+
attributes: { value: Object.freeze(i) },
|
|
67
|
+
converter: { value: Object.freeze(t) }
|
|
68
|
+
}
|
|
69
|
+
);
|
|
70
|
+
}
|
|
71
|
+
C(w, { path: "/" });
|
|
72
|
+
var g, R;
|
|
73
|
+
function U() {
|
|
74
|
+
if (R) return g;
|
|
75
|
+
R = 1;
|
|
76
|
+
for (var t = {}, i = 32; i < 127; i++)
|
|
77
|
+
t[i] = String.fromCharCode(i);
|
|
78
|
+
function u(e) {
|
|
79
|
+
var o = 0, c = 0;
|
|
80
|
+
return a(e, function(d, s, p) {
|
|
81
|
+
var v = Math.round(s * 1e5), y = Math.round(p * 1e5);
|
|
82
|
+
return d += n(r(v - o)) + n(r(y - c)), o = v, c = y, d;
|
|
83
|
+
});
|
|
84
|
+
}
|
|
85
|
+
function a(e, o) {
|
|
86
|
+
for (var c = null, d = 0, s = 0, p = "", v = 0; v < e.length; v++)
|
|
87
|
+
c = e[v], d = c.lat || c.x || c[0], s = c.lng || c.y || c[1], p = o(p, d, s);
|
|
88
|
+
return p;
|
|
89
|
+
}
|
|
90
|
+
function r(e) {
|
|
91
|
+
return e < 0 ? ~(e << 1) : e << 1;
|
|
92
|
+
}
|
|
93
|
+
function f(e) {
|
|
94
|
+
return (e & 31 | 32) + 63;
|
|
95
|
+
}
|
|
96
|
+
function n(e) {
|
|
97
|
+
for (var o = ""; e >= 32; )
|
|
98
|
+
o += t[f(e)], e = e >> 5;
|
|
99
|
+
return o += t[e + 63], o;
|
|
100
|
+
}
|
|
101
|
+
return g = u, g;
|
|
102
|
+
}
|
|
103
|
+
var l, m;
|
|
104
|
+
function q() {
|
|
105
|
+
if (m) return l;
|
|
106
|
+
m = 1;
|
|
107
|
+
var t = 1e5;
|
|
108
|
+
function i(u) {
|
|
109
|
+
var a = [], r = 0, f = 0;
|
|
110
|
+
return i.integers(u, function(n, e) {
|
|
111
|
+
r += n, f += e, a.push([r / t, f / t]);
|
|
112
|
+
}), a;
|
|
113
|
+
}
|
|
114
|
+
return i.sign = function(u) {
|
|
115
|
+
return u & 1 ? ~(u >>> 1) : u >>> 1;
|
|
116
|
+
}, i.integers = function(u, a) {
|
|
117
|
+
for (var r = 0, f = 0, n = 0, e = 0, o = 0, c = 0, d = 0; d < u.length; d++)
|
|
118
|
+
e = u.charCodeAt(d) - 63, o = o | (e & 31) << c, c = c + 5, e < 32 && (++r & 1 ? f = i.sign(o) : (n = i.sign(o), a(f, n)), o = 0, c = 0);
|
|
119
|
+
return r;
|
|
120
|
+
}, l = i, l;
|
|
121
|
+
}
|
|
122
|
+
var x, I;
|
|
123
|
+
function A() {
|
|
124
|
+
return I || (I = 1, x = {
|
|
125
|
+
encode: U(),
|
|
126
|
+
decode: q()
|
|
127
|
+
}), x;
|
|
128
|
+
}
|
|
129
|
+
A();
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { ref as p, onMounted as w, onUnmounted as E, unref as x } from "vue";
|
|
2
|
+
const D = (t) => {
|
|
3
|
+
const { isDropdownOpen: o, disableSpaceHandler: m } = t, n = p(-1), a = p(-1);
|
|
4
|
+
if (!(t.activate === void 0 || t.activate)) return { activeIdx: n, selectedIdx: a };
|
|
5
|
+
const l = (e) => {
|
|
6
|
+
const v = "ArrowUp", d = "ArrowDown", s = "Enter", i = "Escape", u = " ", c = "PageUp", y = "Home", f = "PageDown", k = "End";
|
|
7
|
+
if (!o.value || ![
|
|
8
|
+
v,
|
|
9
|
+
d,
|
|
10
|
+
s,
|
|
11
|
+
i,
|
|
12
|
+
u,
|
|
13
|
+
c,
|
|
14
|
+
y,
|
|
15
|
+
f,
|
|
16
|
+
k
|
|
17
|
+
].includes(e.key))
|
|
18
|
+
return;
|
|
19
|
+
const r = x(t.optionsLength);
|
|
20
|
+
if (e.key === v)
|
|
21
|
+
n.value = n.value === 0 ? r - 1 : n.value - 1;
|
|
22
|
+
else if (e.key === d)
|
|
23
|
+
n.value = (n.value + 1) % r;
|
|
24
|
+
else if (e.key === s || e.key === u) {
|
|
25
|
+
if (e.key === u && m) return;
|
|
26
|
+
a.value = n.value, o.value = !1;
|
|
27
|
+
} else e.key === i ? (n.value = a.value, o.value = !1) : e.key === c || e.key === y ? n.value = 0 : (e.key === f || e.key === k) && (n.value = r - 1);
|
|
28
|
+
e.stopPropagation(), e.preventDefault();
|
|
29
|
+
};
|
|
30
|
+
return w(() => {
|
|
31
|
+
document && document.addEventListener("keydown", l);
|
|
32
|
+
}), E(() => {
|
|
33
|
+
document && document.removeEventListener("keydown", l);
|
|
34
|
+
}), {
|
|
35
|
+
activeIdx: n,
|
|
36
|
+
selectedIdx: a
|
|
37
|
+
};
|
|
38
|
+
};
|
|
39
|
+
export {
|
|
40
|
+
D as A
|
|
41
|
+
};
|