bitboss-ui 0.2.30 → 0.2.32
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/components/BaseButton/BaseButton.vue.d.ts +6 -6
- package/dist/components/BaseCheckbox/BaseCheckbox.vue.d.ts +16 -16
- package/dist/components/BaseCheckboxGroup/BaseCheckboxGroup.vue.d.ts +36 -36
- package/dist/components/BaseDatePicker/BaseDatePicker.vue.d.ts +20 -20
- package/dist/components/BaseDatePickerInput/BaseDatePickerInput.vue.d.ts +21 -21
- package/dist/components/BaseDialog/BaseDialog.vue.d.ts +8 -8
- package/dist/components/BaseInputContainer/BaseInputContainer.vue.d.ts +6 -6
- package/dist/components/BaseNumberInput/BaseNumberInput.vue.d.ts +20 -20
- package/dist/components/BaseRadio/BaseRadio.vue.d.ts +20 -20
- package/dist/components/BaseRadioGroup/BaseRadioGroup.vue.d.ts +36 -36
- package/dist/components/BaseRating/BaseRating.vue.d.ts +17 -17
- package/dist/components/BaseSelect/BaseSelect.vue.d.ts +23 -23
- package/dist/components/BaseSlider/BaseSlider.vue.d.ts +15 -15
- package/dist/components/BaseSwitch/BaseSwitch.vue.d.ts +1 -1
- package/dist/components/BaseSwitchGroup/BaseSwitchGroup.vue.d.ts +20 -20
- package/dist/components/BaseTag/BaseTag.vue.d.ts +20 -20
- package/dist/components/BaseTextInput/BaseTextInput.vue.d.ts +19 -19
- package/dist/components/BaseTextarea/BaseTextarea.vue.d.ts +18 -18
- package/dist/components/BbAccordion/BbAccordion.vue.d.ts +3 -3
- package/dist/components/BbAlert/BbAlert.vue.d.ts +3 -3
- package/dist/components/BbAvatar/BbAvatar.vue.d.ts +8 -8
- package/dist/components/BbBadge/BbBadge.vue.d.ts +1 -1
- package/dist/components/BbBreadcrumbs/BbBreadcrumbs.vue.d.ts +6 -6
- package/dist/components/BbButton/BbButton.vue.d.ts +1 -1
- package/dist/components/BbCheckbox/BbCheckbox.vue.d.ts +11 -11
- package/dist/components/BbCheckboxGroup/BbCheckboxGroup.vue.d.ts +27 -27
- package/dist/components/BbChip/BbChip.vue.d.ts +2 -2
- package/dist/components/BbConfirm/BbConfirm.vue.d.ts +4 -4
- package/dist/components/BbDatePickerInput/BbDatePickerInput.vue.d.ts +16 -24
- package/dist/components/BbDialog/BbDialog.vue.d.ts +2 -2
- package/dist/components/BbDropdown/BbDropdown.vue.d.ts +11 -11
- package/dist/components/BbDropdownButton/BbDropdownButton.vue.d.ts +14 -14
- package/dist/components/BbDropzone/BbDropzone.vue.d.ts +4 -4
- package/dist/components/BbIntersection/BbIntersection.vue.d.ts +3 -3
- package/dist/components/BbNumberInput/BbNumberInput.vue.d.ts +10 -10
- package/dist/components/BbOffCanvas/BbOffCanvas.vue.d.ts +9 -9
- package/dist/components/BbPagination/BbPagination.vue.d.ts +1 -1
- package/dist/components/BbPopover/BbPopover.vue.d.ts +8 -8
- package/dist/components/BbRadio/BbRadio.vue.d.ts +10 -10
- package/dist/components/BbRadioGroup/BbRadioGroup.vue.d.ts +27 -27
- package/dist/components/BbRating/BbRating.vue.d.ts +10 -10
- package/dist/components/BbSelect/BbSelect.vue.d.ts +19 -19
- package/dist/components/BbSlider/BbSlider.vue.d.ts +8 -8
- package/dist/components/BbSmoothHeight/BbSmoothHeight.vue.d.ts +1 -1
- package/dist/components/BbSpinner/BbSpinner.vue.d.ts +2 -2
- package/dist/components/BbSwitch/BbSwitch.vue.d.ts +2 -2
- package/dist/components/BbSwitchGroup/BbSwitchGroup.vue.d.ts +20 -20
- package/dist/components/BbTab/BbTab.vue.d.ts +5 -5
- package/dist/components/BbTable/BbTable.vue.d.ts +12 -12
- package/dist/components/BbTable/types.d.ts +108 -108
- package/dist/components/BbTag/BbTag.vue.d.ts +13 -13
- package/dist/components/BbTextInput/BbTextInput.vue.d.ts +11 -11
- package/dist/components/BbTextarea/BbTextarea.vue.d.ts +10 -10
- package/dist/components/BbToast/BbToast.vue.d.ts +1 -1
- package/dist/components/BbToast/BbToastMessage.vue.d.ts +1 -1
- package/dist/components/BbTooltip/BbTooltip.vue.d.ts +3 -3
- package/dist/components/BbTree/BbTree.vue.d.ts +1 -1
- package/dist/composables/useConfirm.d.ts +10 -10
- package/dist/composables/useOptions.d.ts +2 -2
- package/dist/composables/useRoute.d.ts +2 -2
- package/dist/composables/useRouter.d.ts +1 -1
- package/dist/composables/useToast.d.ts +5 -5
- package/dist/composables/useWizard.d.ts +1 -1
- package/dist/index.d.ts +126 -126
- package/dist/index101.js +53 -58
- package/dist/index101.js.map +1 -1
- package/dist/index103.js +18 -18
- package/dist/index103.js.map +1 -1
- package/dist/index105.js +16 -16
- package/dist/index105.js.map +1 -1
- package/dist/index107.js +15 -15
- package/dist/index107.js.map +1 -1
- package/dist/index109.js.map +1 -1
- package/dist/index11.js +7 -7
- package/dist/index11.js.map +1 -1
- package/dist/index111.js +16 -16
- package/dist/index111.js.map +1 -1
- package/dist/index113.js +2 -2
- package/dist/index113.js.map +1 -1
- package/dist/index115.js +6 -6
- package/dist/index115.js.map +1 -1
- package/dist/index116.js +1 -1
- package/dist/index116.js.map +1 -1
- package/dist/index117.js +1 -1
- package/dist/index117.js.map +1 -1
- package/dist/index118.js +4 -4
- package/dist/index118.js.map +1 -1
- package/dist/index119.js +5 -5
- package/dist/index119.js.map +1 -1
- package/dist/index120.js.map +1 -1
- package/dist/index121.js +1 -1
- package/dist/index121.js.map +1 -1
- package/dist/index122.js.map +1 -1
- package/dist/index124.js.map +1 -1
- package/dist/index125.js +4 -4
- package/dist/index125.js.map +1 -1
- package/dist/index126.js +1 -1
- package/dist/index126.js.map +1 -1
- package/dist/index127.js +1 -1
- package/dist/index128.js +4 -1
- package/dist/index128.js.map +1 -1
- package/dist/index129.js.map +1 -1
- package/dist/index13.js +11 -11
- package/dist/index13.js.map +1 -1
- package/dist/index130.js.map +1 -1
- package/dist/index131.js +2 -2
- package/dist/index15.js +229 -227
- package/dist/index15.js.map +1 -1
- package/dist/index17.js +61 -62
- package/dist/index17.js.map +1 -1
- package/dist/index19.js +22 -22
- package/dist/index19.js.map +1 -1
- package/dist/index196.js +2 -5
- package/dist/index196.js.map +1 -1
- package/dist/index197.js +2 -16
- package/dist/index197.js.map +1 -1
- package/dist/index198.js +4 -16
- package/dist/index198.js.map +1 -1
- package/dist/index199.js +294 -18
- package/dist/index199.js.map +1 -1
- package/dist/index2.js +23 -23
- package/dist/index2.js.map +1 -1
- package/dist/index200.js +13 -17
- package/dist/index200.js.map +1 -1
- package/dist/index201.js +13 -26
- package/dist/index201.js.map +1 -1
- package/dist/index202.js +19 -8
- package/dist/index202.js.map +1 -1
- package/dist/index203.js +20 -2
- package/dist/index203.js.map +1 -1
- package/dist/index204.js +29 -3
- package/dist/index204.js.map +1 -1
- package/dist/index205.js +8 -35
- package/dist/index205.js.map +1 -1
- package/dist/index206.js +2 -6
- package/dist/index206.js.map +1 -1
- package/dist/index207.js +235 -2
- package/dist/index207.js.map +1 -1
- package/dist/index208.js +3 -4
- package/dist/index208.js.map +1 -1
- package/dist/index209.js +33 -376
- package/dist/index209.js.map +1 -1
- package/dist/index21.js +4 -4
- package/dist/index21.js.map +1 -1
- package/dist/index210.js +6 -2
- package/dist/index210.js.map +1 -1
- package/dist/index211.js +8 -371
- package/dist/index211.js.map +1 -1
- package/dist/index212.js +378 -2
- package/dist/index212.js.map +1 -1
- package/dist/index213.js +134 -3
- package/dist/index213.js.map +1 -1
- package/dist/index214.js +2 -3
- package/dist/index214.js.map +1 -1
- package/dist/index215.js +174 -2
- package/dist/index215.js.map +1 -1
- package/dist/index216.js +23 -2
- package/dist/index216.js.map +1 -1
- package/dist/index217.js +365 -126
- package/dist/index217.js.map +1 -1
- package/dist/index218.js +3 -174
- package/dist/index218.js.map +1 -1
- package/dist/index219.js +3 -23
- package/dist/index219.js.map +1 -1
- package/dist/index220.js +2 -10
- package/dist/index220.js.map +1 -1
- package/dist/index221.js +26 -233
- package/dist/index221.js.map +1 -1
- package/dist/index222.js +16 -8
- package/dist/index222.js.map +1 -1
- package/dist/index223.js +2 -121
- package/dist/index223.js.map +1 -1
- package/dist/index224.js +8 -27
- package/dist/index224.js.map +1 -1
- package/dist/index225.js +120 -12
- package/dist/index225.js.map +1 -1
- package/dist/index226.js +1 -1
- package/dist/index227.js +3 -434
- package/dist/index227.js.map +1 -1
- package/dist/index228.js +2 -89
- package/dist/index228.js.map +1 -1
- package/dist/index229.js +6 -200
- package/dist/index229.js.map +1 -1
- package/dist/index23.js +15 -17
- package/dist/index23.js.map +1 -1
- package/dist/index230.js +2 -295
- package/dist/index230.js.map +1 -1
- package/dist/index231.js +2 -6
- package/dist/index231.js.map +1 -1
- package/dist/index232.js +2 -2
- package/dist/index236.js +435 -2
- package/dist/index236.js.map +1 -1
- package/dist/index237.js +89 -2
- package/dist/index237.js.map +1 -1
- package/dist/index238.js +199 -3
- package/dist/index238.js.map +1 -1
- package/dist/index239.js +218 -111
- package/dist/index239.js.map +1 -1
- package/dist/index240.js +246 -94
- package/dist/index240.js.map +1 -1
- package/dist/index241.js +2 -2
- package/dist/index241.js.map +1 -1
- package/dist/index242.js +111 -218
- package/dist/index242.js.map +1 -1
- package/dist/index243.js +94 -246
- package/dist/index243.js.map +1 -1
- package/dist/index244.js +17 -19
- package/dist/index244.js.map +1 -1
- package/dist/index246.js +9 -9
- package/dist/index246.js.map +1 -1
- package/dist/index247.js +4 -1
- package/dist/index247.js.map +1 -1
- package/dist/index248.js +2 -2
- package/dist/index249.js +37 -14
- package/dist/index249.js.map +1 -1
- package/dist/index25.js +4 -4
- package/dist/index25.js.map +1 -1
- package/dist/index250.js +2 -38
- package/dist/index250.js.map +1 -1
- package/dist/index251.js +2 -2
- package/dist/index251.js.map +1 -1
- package/dist/index252.js +15 -2
- package/dist/index252.js.map +1 -1
- package/dist/index253.js +3 -2
- package/dist/index253.js.map +1 -1
- package/dist/index255.js +2 -3
- package/dist/index255.js.map +1 -1
- package/dist/index27.js +7 -7
- package/dist/index27.js.map +1 -1
- package/dist/index29.js +15 -15
- package/dist/index29.js.map +1 -1
- package/dist/index3.js +2 -1
- package/dist/index3.js.map +1 -1
- package/dist/index31.js +29 -29
- package/dist/index31.js.map +1 -1
- package/dist/index33.js +11 -12
- package/dist/index33.js.map +1 -1
- package/dist/index35.js +2 -2
- package/dist/index35.js.map +1 -1
- package/dist/index37.js +12 -12
- package/dist/index37.js.map +1 -1
- package/dist/index39.js +5 -7
- package/dist/index39.js.map +1 -1
- package/dist/index4.js.map +1 -1
- package/dist/index41.js +5 -5
- package/dist/index41.js.map +1 -1
- package/dist/index43.js +19 -16
- package/dist/index43.js.map +1 -1
- package/dist/index45.js +9 -9
- package/dist/index45.js.map +1 -1
- package/dist/index47.js +4 -4
- package/dist/index47.js.map +1 -1
- package/dist/index49.js +1 -1
- package/dist/index49.js.map +1 -1
- package/dist/index5.js +7 -6
- package/dist/index5.js.map +1 -1
- package/dist/index51.js +6 -6
- package/dist/index51.js.map +1 -1
- package/dist/index53.js.map +1 -1
- package/dist/index55.js +20 -20
- package/dist/index55.js.map +1 -1
- package/dist/index57.js +35 -35
- package/dist/index57.js.map +1 -1
- package/dist/index59.js +8 -8
- package/dist/index59.js.map +1 -1
- package/dist/index6.js +38 -38
- package/dist/index6.js.map +1 -1
- package/dist/index61.js +27 -27
- package/dist/index61.js.map +1 -1
- package/dist/index63.js +4 -4
- package/dist/index63.js.map +1 -1
- package/dist/index65.js +20 -20
- package/dist/index65.js.map +1 -1
- package/dist/index67.js +26 -26
- package/dist/index67.js.map +1 -1
- package/dist/index69.js +21 -19
- package/dist/index69.js.map +1 -1
- package/dist/index7.js.map +1 -1
- package/dist/index71.js +2 -2
- package/dist/index71.js.map +1 -1
- package/dist/index72.js +3 -3
- package/dist/index72.js.map +1 -1
- package/dist/index73.js +14 -14
- package/dist/index73.js.map +1 -1
- package/dist/index75.js +18 -18
- package/dist/index75.js.map +1 -1
- package/dist/index77.js +11 -11
- package/dist/index77.js.map +1 -1
- package/dist/index79.js +15 -15
- package/dist/index79.js.map +1 -1
- package/dist/index8.js +10 -7
- package/dist/index8.js.map +1 -1
- package/dist/index81.js +1 -1
- package/dist/index81.js.map +1 -1
- package/dist/index83.js +20 -20
- package/dist/index83.js.map +1 -1
- package/dist/index85.js +34 -34
- package/dist/index85.js.map +1 -1
- package/dist/index87.js +18 -18
- package/dist/index87.js.map +1 -1
- package/dist/index89.js.map +1 -1
- package/dist/index9.js.map +1 -1
- package/dist/index91.js +53 -53
- package/dist/index91.js.map +1 -1
- package/dist/index93.js +16 -16
- package/dist/index93.js.map +1 -1
- package/dist/index95.js +21 -21
- package/dist/index95.js.map +1 -1
- package/dist/index97.js +37 -37
- package/dist/index97.js.map +1 -1
- package/dist/index99.js +18 -18
- package/dist/index99.js.map +1 -1
- package/dist/style.css +1 -1
- package/dist/types/CommonProps.d.ts +18 -18
- package/dist/types/ExtractGenericFromComputedRef.d.ts +1 -1
- package/dist/types/ExtractGenericFromRef.d.ts +1 -1
- package/dist/types/VoidHtmlElements.d.ts +1 -1
- package/dist/utilities/functions/cloneDeep.d.ts +1 -1
- package/dist/utilities/functions/debounce.d.ts +1 -1
- package/dist/utilities/functions/flow.d.ts +1 -1
- package/dist/utilities/functions/get.d.ts +1 -1
- package/dist/utilities/functions/isNotNil.d.ts +1 -1
- package/dist/utilities/functions/mapValues.d.ts +1 -1
- package/dist/utilities/functions/merge.d.ts +1 -1
- package/dist/utilities/functions/millisecondsTo.d.ts +1 -1
- package/dist/utilities/functions/overEvery.d.ts +1 -1
- package/dist/utilities/functions/percentage.d.ts +4 -4
- package/dist/utilities/functions/pick.d.ts +1 -1
- package/dist/utilities/functions/pickBy.d.ts +1 -1
- package/dist/utilities/functions/roundToTheNearest.d.ts +1 -1
- package/package.json +93 -77
- package/dist/index256.js +0 -5
- package/dist/index256.js.map +0 -1
package/dist/index19.js
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
import { defineComponent as J, ref as o, useAttrs as Q, computed as h, onMounted as X, onBeforeUnmount as E, watchPostEffect as Y, openBlock as _, createBlock as Z, Teleport as ee, createElementVNode as l, mergeProps as N, createElementBlock as B, renderSlot as i, createTextVNode as te, toDisplayString as V, createCommentVNode as D, nextTick as T } from "vue";
|
|
2
|
-
import { throttle as oe } from "./
|
|
3
|
-
import { useFocusTrap as le } from "./
|
|
2
|
+
import { throttle as oe } from "./index208.js";
|
|
3
|
+
import { useFocusTrap as le } from "./index209.js";
|
|
4
4
|
import { useId as A } from "./index7.js";
|
|
5
5
|
import { wait as L } from "./index122.js";
|
|
6
|
-
import { waitFor as ae } from "./
|
|
6
|
+
import { waitFor as ae } from "./index210.js";
|
|
7
7
|
const se = { class: "bb-base-dialog-close" }, ne = { class: "bb-base-dialog-close__content" }, ie = { class: "bb-base-dialog-close__label" }, re = /* @__PURE__ */ l("span", { class: "bb-base-dialog-close__icon" }, [
|
|
8
8
|
/* @__PURE__ */ l("svg", {
|
|
9
|
-
|
|
9
|
+
"aria-hidden": "true",
|
|
10
10
|
fill: "none",
|
|
11
|
-
|
|
12
|
-
|
|
11
|
+
viewBox: "0 0 24 24",
|
|
12
|
+
xmlns: "http://www.w3.org/2000/svg"
|
|
13
13
|
}, [
|
|
14
14
|
/* @__PURE__ */ l("path", {
|
|
15
15
|
d: "M23 23L1 1M23 1L1 23",
|
|
16
16
|
stroke: "currentColor",
|
|
17
|
-
"stroke-
|
|
18
|
-
"stroke-
|
|
17
|
+
"stroke-linecap": "round",
|
|
18
|
+
"stroke-width": "2"
|
|
19
19
|
})
|
|
20
20
|
])
|
|
21
21
|
], -1), de = /* @__PURE__ */ l("div", { style: { flex: "10000 10000 0%" } }, null, -1), me = /* @__PURE__ */ J({
|
|
@@ -165,23 +165,23 @@ const se = { class: "bb-base-dialog-close" }, ne = { class: "bb-base-dialog-clos
|
|
|
165
165
|
}), [
|
|
166
166
|
v.value ? (_(), B("div", {
|
|
167
167
|
key: 0,
|
|
168
|
-
class: "bb-base-dialog__content",
|
|
169
168
|
ref_key: "content",
|
|
170
|
-
ref: y
|
|
169
|
+
ref: y,
|
|
170
|
+
class: "bb-base-dialog__content"
|
|
171
171
|
}, [
|
|
172
172
|
l("div", {
|
|
173
|
-
class: "bb-base-dialog__header",
|
|
174
173
|
ref_key: "header",
|
|
175
|
-
ref: d
|
|
174
|
+
ref: d,
|
|
175
|
+
class: "bb-base-dialog__header"
|
|
176
176
|
}, [
|
|
177
177
|
i(e.$slots, "header", {
|
|
178
|
-
titleId: w,
|
|
179
178
|
close: S,
|
|
180
|
-
title: e.title
|
|
179
|
+
title: e.title,
|
|
180
|
+
titleId: w
|
|
181
181
|
}, () => [
|
|
182
182
|
l("span", {
|
|
183
|
-
|
|
184
|
-
|
|
183
|
+
id: w,
|
|
184
|
+
class: "bb-base-dialog__title"
|
|
185
185
|
}, [
|
|
186
186
|
i(e.$slots, "title", { text: e.title }, () => [
|
|
187
187
|
te(V(e.title), 1)
|
|
@@ -190,8 +190,8 @@ const se = { class: "bb-base-dialog-close" }, ne = { class: "bb-base-dialog-clos
|
|
|
190
190
|
l("span", se, [
|
|
191
191
|
e.showClose ? (_(), B("button", {
|
|
192
192
|
key: 0,
|
|
193
|
-
|
|
194
|
-
|
|
193
|
+
type: "button",
|
|
194
|
+
onClick: S
|
|
195
195
|
}, [
|
|
196
196
|
i(e.$slots, "close", { text: H.value }, () => [
|
|
197
197
|
l("span", ne, [
|
|
@@ -204,9 +204,9 @@ const se = { class: "bb-base-dialog-close" }, ne = { class: "bb-base-dialog-clos
|
|
|
204
204
|
])
|
|
205
205
|
], 512),
|
|
206
206
|
l("div", {
|
|
207
|
-
class: "bb-base-dialog__body",
|
|
208
207
|
ref_key: "body",
|
|
209
|
-
ref: a
|
|
208
|
+
ref: a,
|
|
209
|
+
class: "bb-base-dialog__body"
|
|
210
210
|
}, [
|
|
211
211
|
i(e.$slots, "description", {
|
|
212
212
|
descriptionId: k,
|
|
@@ -222,9 +222,9 @@ const se = { class: "bb-base-dialog-close" }, ne = { class: "bb-base-dialog-clos
|
|
|
222
222
|
], 512),
|
|
223
223
|
de,
|
|
224
224
|
l("div", {
|
|
225
|
-
class: "bb-base-dialog__footer",
|
|
226
225
|
ref_key: "footer",
|
|
227
|
-
ref: u
|
|
226
|
+
ref: u,
|
|
227
|
+
class: "bb-base-dialog__footer"
|
|
228
228
|
}, [
|
|
229
229
|
i(e.$slots, "footer")
|
|
230
230
|
], 512)
|
package/dist/index19.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index19.js","sources":["../src/components/BaseDialog/BaseDialog.vue?vue&type=script&setup=true&lang.ts"],"sourcesContent":["import { defineComponent as _defineComponent } from 'vue'\nimport { renderSlot as _renderSlot, toDisplayString as _toDisplayString, createTextVNode as _createTextVNode, createElementVNode as _createElementVNode, openBlock as _openBlock, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode, mergeProps as _mergeProps, Teleport as _Teleport, createBlock as _createBlock } from \"vue\"\n\nconst _hoisted_1 = { class: \"bb-base-dialog-close\" }\nconst _hoisted_2 = { class: \"bb-base-dialog-close__content\" }\nconst _hoisted_3 = { class: \"bb-base-dialog-close__label\" }\nconst _hoisted_4 = /*#__PURE__*/_createElementVNode(\"span\", { class: \"bb-base-dialog-close__icon\" }, [\n /*#__PURE__*/_createElementVNode(\"svg\", {\n viewBox: \"0 0 24 24\",\n fill: \"none\",\n xmlns: \"http://www.w3.org/2000/svg\",\n \"aria-hidden\": \"true\"\n }, [\n /*#__PURE__*/_createElementVNode(\"path\", {\n d: \"M23 23L1 1M23 1L1 23\",\n stroke: \"currentColor\",\n \"stroke-width\": \"2\",\n \"stroke-linecap\": \"round\"\n })\n ])\n], -1)\nconst _hoisted_5 = /*#__PURE__*/_createElementVNode(\"div\", { style: {\"flex\":\"10000 10000 0%\"} }, null, -1)\n\nimport {\n computed,\n onBeforeUnmount,\n onMounted,\n ref,\n useAttrs,\n watch,\n nextTick,\n watchPostEffect,\n} from \"vue\";\nimport { throttle } from \"@/utilities/functions/throttle\";\nimport { useFocusTrap } from \"@vueuse/integrations/useFocusTrap\";\nimport { useId } from \"@/composables/useId\";\nimport { wait } from \"@/utilities/functions/wait\";\nimport { waitFor } from \"@/utilities/functions/waitFor\";\nimport type { CommonProps, Size } from \"@/types/CommonProps\";\n\nexport type Sizes = {\n sm: number;\n md: number;\n lg: number;\n};\n\nexport type BaseDialogProps = Pick<\n CommonProps,\n | \"closeLabel\"\n | \"compact\"\n | \"disabled\"\n | \"eager\"\n | \"panelClasses\"\n | \"overlayClasses\"\n | \"persistent\"\n | \"showClose\"\n | \"title\"\n | \"transition\"\n | \"transitionDuration\"\n> &\n Size<Sizes> & {\n /**\n * Description of the content of the modal. Extremely useful for accessibility reasons.\n */\n description?: string;\n /**\n * Displays the modala as fulscreen with no margin to the page\n */\n fullscreen?: boolean;\n /**\n * Defines the state open / closed of the modal.\n */\n modelValue?: boolean | null;\n };\n\nexport type BaseDialogSlots = {\n header?: (props: {\n titleId: typeof titleId;\n close: typeof onCloseClick;\n title: BaseDialogProps[\"title\"];\n }) => any;\n title?: (props: { text: BaseDialogProps[\"title\"] }) => any;\n close?: (props: { text: BaseDialogProps[\"closeLabel\"] }) => any;\n description?: (props: {\n descriptionId: typeof descriptionId;\n text: BaseDialogProps[\"description\"];\n }) => any;\n default?: (props: {}) => any;\n footer?: (props: {}) => any;\n};\n\nexport type BaseDialogEvents = {\n (e: \"shown\"): void;\n (e: \"hidden\"): void;\n (e: \"update:modelValue\", value: boolean): void;\n};\n\n\nexport default /*#__PURE__*/_defineComponent({\n __name: 'BaseDialog',\n props: {\n closeLabel: { default: \"Chiudi modale\" },\n compact: { type: Boolean },\n disabled: { type: Boolean },\n eager: { type: Boolean },\n panelClasses: { default: () => [] },\n overlayClasses: { default: () => [] },\n persistent: { type: Boolean },\n showClose: { type: Boolean, default: true },\n title: {},\n transition: { default: \"fade\" },\n transitionDuration: { default: 350 },\n size: { default: \"sm\" },\n description: {},\n fullscreen: { type: Boolean },\n modelValue: { type: [Boolean, null] }\n },\n emits: [\"shown\", \"hidden\", \"update:modelValue\"],\n setup(__props: any, { emit: __emit }) {\n\nconst props = __props;\n\n\n\nconst emit = __emit;\n\nconst titleId = `title_${useId().id.value}`;\nconst descriptionId = `description_${useId().id.value}`;\n\nconst observer = ref<MutationObserver | null>(null);\nconst overlay = ref<HTMLElement | null>(null);\nconst panel = ref<HTMLElement | null>(null);\nconst content = ref<HTMLElement | null>(null);\nconst header = ref<HTMLElement | null>(null);\nconst body = ref<HTMLElement | null>(null);\nconst footer = ref<HTMLElement | null>(null);\nconst height = ref<number | null>(null);\n\nconst { activate, deactivate } = useFocusTrap(panel, {\n clickOutsideDeactivates: true,\n /* On esc deactivate the trap, return focus and then close the modal */\n escapeDeactivates: () => {\n nextTick(() => {\n emit(\"update:modelValue\", false);\n });\n return true;\n },\n});\n\nconst attrs = useAttrs();\n\nconst closeLabel = computed(() => props.closeLabel);\n\nonMounted(async () => {\n if (body.value) {\n observer.value = new MutationObserver(onContentGrow);\n observer.value.observe(body.value, { childList: true, subtree: true });\n }\n window.addEventListener(\"resize\", onContentGrow);\n});\nonBeforeUnmount(() => {\n window.removeEventListener(\"resize\", onContentGrow);\n});\n\nconst open = ref(false);\nconst opening = ref(false);\nconst closed = ref(true);\nconst closing = ref(false);\nconst hasRenderedAtLeastOnce = ref(props.eager || props.modelValue);\n\nconst busy = computed(() => opening.value || closing.value);\n\nonBeforeUnmount(() => {\n if (props.modelValue) {\n let currentlyOpenModals = Number(\n document.body.dataset[\"openModals\"] ?? \"0\"\n );\n // This prevents overscroll chaining (additional scrolling to the body when the modal has been completely scrolled)\n currentlyOpenModals--;\n document.body.dataset[\"openModals\"] = currentlyOpenModals.toString();\n if (!currentlyOpenModals) {\n document.body.style.overflow = \"auto\";\n document.body.style.paddingRight = \"0px\";\n }\n }\n});\n\n/**\n * When modelValue becomes true if the component wasn't rendered render it\n * and wait for it to be on the page (or transitions would not work).\n * Stash the latest focused element so we can return it later when it closes.\n * Focus on the panel upon opening.\n * ---\n * Notice all interactions update modelValue and then this function aligns the display to it\n */\nconst alignToModelValue = async () => {\n if (props.modelValue) {\n if (!hasRenderedAtLeastOnce.value) {\n hasRenderedAtLeastOnce.value = true;\n await waitFor(() => !!body.value);\n await nextTick();\n if (body.value) {\n observer.value = new MutationObserver(onContentGrow);\n observer.value.observe(body.value, { childList: true, subtree: true });\n }\n }\n\n closed.value = false;\n closing.value = false;\n opening.value = true;\n\n // This prevents overscroll chaining (additional scrolling to the body when the modal has been completely scrolled)\n\n let currentlyOpenModals = Number(\n document.body.dataset[\"openModals\"] ?? \"0\"\n );\n currentlyOpenModals++;\n document.body.dataset[\"openModals\"] = currentlyOpenModals.toString();\n const scrollBarWidth =\n window.innerWidth - document.documentElement.clientWidth;\n document.body.style.overflow = \"hidden\";\n document.body.style.paddingRight = `${scrollBarWidth}px`;\n\n await wait(props.transitionDuration);\n opening.value = false;\n open.value = true;\n emit(\"shown\");\n activate();\n } else {\n deactivate();\n opening.value = false;\n open.value = false;\n closing.value = true;\n\n await wait(props.transitionDuration);\n\n let currentlyOpenModals = Number(\n document.body.dataset[\"openModals\"] ?? \"0\"\n );\n // This prevents overscroll chaining (additional scrolling to the body when the modal has been completely scrolled)\n currentlyOpenModals--;\n document.body.dataset[\"openModals\"] = currentlyOpenModals.toString();\n if (!currentlyOpenModals) {\n document.body.style.overflow = \"auto\";\n document.body.style.paddingRight = \"0px\";\n }\n closing.value = false;\n closed.value = true;\n emit(\"hidden\");\n }\n};\n\n/**\n * Every time modelValue changes align the display to it\n */\nwatchPostEffect(() => {\n if (!props.modelValue && !hasRenderedAtLeastOnce.value) return;\n alignToModelValue();\n});\n\n/**\n * Disable scrolling\n */\nconst onOverlayScroll = (event: UIEvent) => {\n if (event.target === overlay.value) {\n event.preventDefault();\n }\n};\n\n/**\n * Close the modal on overlay click if not persistent\n */\nconst onOverlayClick = (event: MouseEvent) => {\n if (props.disabled || busy.value) return;\n if (overlay.value) {\n if (event.target === overlay.value) {\n if (!props.persistent) {\n emit(\"update:modelValue\", false);\n }\n }\n }\n};\n\n/**\n * On click on the X button\n */\nconst onCloseClick = () => {\n if (props.disabled || busy.value) return;\n deactivate();\n emit(\"update:modelValue\", false);\n};\n\nconst overlayAttributes = computed(() => {\n const classes = [\n {\n \"bb-base-dialog bb-base-dialog__overlay\": true,\n \"bb-base-dialog--fullscreen\": props.fullscreen,\n \"bb-base-dialog--open\": open.value,\n \"bb-base-dialog--opening\": opening.value,\n \"bb-base-dialog--closed\": closed.value,\n \"bb-base-dialog--closing\": closing.value,\n [`bb-base-dialog--transition-${props.transition}`]: true,\n },\n props.overlayClasses,\n ].flat();\n const eventListeners = {\n onClick: onOverlayClick,\n onScroll: onOverlayScroll,\n onTouchmove: onOverlayScroll,\n onWheel: onOverlayScroll,\n onKeydown: onOverlayScroll,\n };\n\n const style = {\n transitionDuration: props.transitionDuration / 1000 + \"s\",\n };\n return {\n class: classes,\n style,\n ...eventListeners,\n ...attrs,\n };\n});\n\nconst panelAttributes = computed(() => {\n const classes = [\n {\n \"bb-base-dialog__panel\": true,\n \"bb-base-dialog__panel--compact\": props.compact,\n },\n props.panelClasses,\n ].flat();\n\n const accessibilityAttrs: {\n [key: string]: string | boolean;\n } = {\n role: \"dialog\",\n \"aria-modal\": true,\n };\n\n if (hasRenderedAtLeastOnce.value) {\n accessibilityAttrs[\"aria-labelledby\"] = titleId;\n\n if (props.description)\n accessibilityAttrs[\"aria-describedby\"] = descriptionId;\n }\n\n let maxWidth;\n const sizes: Sizes = {\n sm: 384,\n md: 652,\n lg: 896,\n };\n if (props.fullscreen) maxWidth = \"100%\";\n else if (typeof props.size === \"number\") maxWidth = props.size + \"px\";\n else if (props.size in sizes)\n maxWidth = sizes[props.size as keyof Sizes] + \"px\";\n else maxWidth = props.size + \"px\";\n\n const style = {\n maxWidth,\n transitionDuration: props.transitionDuration / 1000 + \"s\",\n };\n\n return {\n class: classes,\n style,\n ...accessibilityAttrs,\n };\n});\n\n/**\n * This is called when content inside body changes.\n * Gets the total height the panel needs to be\n * It could be called numerous times so throttle every 300ms\n */\nconst onContentGrow = throttle(async () => {\n if (props.fullscreen) {\n height.value = window.innerHeight;\n return;\n }\n if (header.value && body.value && footer.value) {\n const contentHeight =\n header.value.scrollHeight +\n body.value.scrollHeight +\n footer.value.scrollHeight +\n 2;\n /* Add two so renderless elements at the bottom are not cut off */\n if (content.value) {\n content.value.style.height = \"0px\";\n content.value.style.height = `${contentHeight + 10}px`;\n /**\n * Run until all transitions inside have completed\n */\n await wait(30);\n if (header.value && body.value && footer.value) {\n const contentHeight2 =\n header.value.scrollHeight +\n body.value.scrollHeight +\n footer.value.scrollHeight +\n 20;\n if (contentHeight !== contentHeight2) onContentGrow();\n }\n }\n }\n}, 200);\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createBlock(_Teleport, { to: \"body\" }, [\n _createElementVNode(\"div\", _mergeProps(overlayAttributes.value, {\n ref_key: \"overlay\",\n ref: overlay\n }), [\n _createElementVNode(\"div\", _mergeProps(panelAttributes.value, {\n ref_key: \"panel\",\n ref: panel\n }), [\n (hasRenderedAtLeastOnce.value)\n ? (_openBlock(), _createElementBlock(\"div\", {\n key: 0,\n class: \"bb-base-dialog__content\",\n ref_key: \"content\",\n ref: content\n }, [\n _createElementVNode(\"div\", {\n class: \"bb-base-dialog__header\",\n ref_key: \"header\",\n ref: header\n }, [\n _renderSlot(_ctx.$slots, \"header\", {\n titleId: titleId,\n close: onCloseClick,\n title: _ctx.title\n }, () => [\n _createElementVNode(\"span\", {\n class: \"bb-base-dialog__title\",\n id: titleId\n }, [\n _renderSlot(_ctx.$slots, \"title\", { text: _ctx.title }, () => [\n _createTextVNode(_toDisplayString(_ctx.title), 1)\n ])\n ]),\n _createElementVNode(\"span\", _hoisted_1, [\n (_ctx.showClose)\n ? (_openBlock(), _createElementBlock(\"button\", {\n key: 0,\n onClick: onCloseClick,\n type: \"button\"\n }, [\n _renderSlot(_ctx.$slots, \"close\", { text: closeLabel.value }, () => [\n _createElementVNode(\"span\", _hoisted_2, [\n _createElementVNode(\"span\", _hoisted_3, _toDisplayString(closeLabel.value), 1),\n _hoisted_4\n ])\n ])\n ]))\n : _createCommentVNode(\"\", true)\n ])\n ])\n ], 512),\n _createElementVNode(\"div\", {\n class: \"bb-base-dialog__body\",\n ref_key: \"body\",\n ref: body\n }, [\n _renderSlot(_ctx.$slots, \"description\", {\n descriptionId: descriptionId,\n text: _ctx.description\n }, () => [\n (_ctx.description)\n ? (_openBlock(), _createElementBlock(\"div\", {\n key: 0,\n id: descriptionId,\n class: \"bb-base-dialog__description\"\n }, _toDisplayString(_ctx.description), 1))\n : _createCommentVNode(\"\", true)\n ]),\n _renderSlot(_ctx.$slots, \"default\")\n ], 512),\n _hoisted_5,\n _createElementVNode(\"div\", {\n class: \"bb-base-dialog__footer\",\n ref_key: \"footer\",\n ref: footer\n }, [\n _renderSlot(_ctx.$slots, \"footer\")\n ], 512)\n ], 512))\n : _createCommentVNode(\"\", true)\n ], 16)\n ], 16)\n ]))\n}\n}\n\n})"],"names":["_hoisted_1","_hoisted_2","_hoisted_3","_hoisted_4","_createElementVNode","_hoisted_5","_sfc_main","_defineComponent","__props","__emit","props","emit","titleId","useId","descriptionId","observer","ref","overlay","panel","content","header","body","footer","height","activate","deactivate","useFocusTrap","nextTick","attrs","useAttrs","closeLabel","computed","onMounted","onContentGrow","onBeforeUnmount","open","opening","closed","closing","hasRenderedAtLeastOnce","busy","currentlyOpenModals","alignToModelValue","waitFor","scrollBarWidth","wait","watchPostEffect","onOverlayScroll","event","onOverlayClick","onCloseClick","overlayAttributes","classes","eventListeners","style","panelAttributes","accessibilityAttrs","maxWidth","sizes","throttle","contentHeight","contentHeight2","_ctx","_cache","_openBlock","_createBlock","_Teleport","_mergeProps","_createElementBlock","_renderSlot","_createTextVNode","_toDisplayString","_createCommentVNode"],"mappings":";;;;;;AAGA,MAAMA,KAAa,EAAE,OAAO,0BACtBC,KAAa,EAAE,OAAO,mCACtBC,KAAa,EAAE,OAAO,iCACtBC,KAA8CC,gBAAAA,EAAA,QAAQ,EAAE,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AoB,IAAI,EAAI;AAAA,gBAAA,CACjC;AAAA,cAAA,CACF;AAAA,eACA,GAAG;AAAA,YACNpE,EAAoB,OAAO;AAAA,cACzB,OAAO;AAAA,cACP,SAAS;AAAA,cACT,KAAKiB;AAAA,YAAA,GACJ;AAAA,cACDgD,EAAYP,EAAK,QAAQ,eAAe;AAAA,gBACtC,eAAAhD;AAAA,gBACA,MAAMgD,EAAK;AAAA,cAAA,GACV,MAAM;AAAA,gBACNA,EAAK,eACDE,KAAcI,EAAoB,OAAO;AAAA,kBACxC,KAAK;AAAA,kBACL,IAAItD;AAAA,kBACJ,OAAO;AAAA,gBAAA,GACNyD,EAAiBT,EAAK,WAAW,GAAG,CAAC,KACxCU,EAAoB,IAAI,EAAI;AAAA,cAAA,CACjC;AAAA,cACDH,EAAYP,EAAK,QAAQ,SAAS;AAAA,eACjC,GAAG;AAAA,YACNzD;AAAA,YACAD,EAAoB,OAAO;AAAA,cACzB,OAAO;AAAA,cACP,SAAS;AAAA,cACT,KAAKkB;AAAA,YAAA,GACJ;AAAA,cACD+C,EAAYP,EAAK,QAAQ,QAAQ;AAAA,eAChC,GAAG;AAAA,UACL,GAAA,GAAG,KACNU,EAAoB,IAAI,EAAI;AAAA,WAC/B,EAAE;AAAA,SACJ,EAAE;AAAA,IAAA,CACN;AAAA,EAEH;AAEA,CAAC;"}
|
|
1
|
+
{"version":3,"file":"index19.js","sources":["../src/components/BaseDialog/BaseDialog.vue?vue&type=script&setup=true&lang.ts"],"sourcesContent":["import { defineComponent as _defineComponent } from 'vue'\nimport { renderSlot as _renderSlot, toDisplayString as _toDisplayString, createTextVNode as _createTextVNode, createElementVNode as _createElementVNode, openBlock as _openBlock, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode, mergeProps as _mergeProps, Teleport as _Teleport, createBlock as _createBlock } from \"vue\"\n\nconst _hoisted_1 = { class: \"bb-base-dialog-close\" }\nconst _hoisted_2 = { class: \"bb-base-dialog-close__content\" }\nconst _hoisted_3 = { class: \"bb-base-dialog-close__label\" }\nconst _hoisted_4 = /*#__PURE__*/_createElementVNode(\"span\", { class: \"bb-base-dialog-close__icon\" }, [\n /*#__PURE__*/_createElementVNode(\"svg\", {\n \"aria-hidden\": \"true\",\n fill: \"none\",\n viewBox: \"0 0 24 24\",\n xmlns: \"http://www.w3.org/2000/svg\"\n }, [\n /*#__PURE__*/_createElementVNode(\"path\", {\n d: \"M23 23L1 1M23 1L1 23\",\n stroke: \"currentColor\",\n \"stroke-linecap\": \"round\",\n \"stroke-width\": \"2\"\n })\n ])\n], -1)\nconst _hoisted_5 = /*#__PURE__*/_createElementVNode(\"div\", { style: {\"flex\":\"10000 10000 0%\"} }, null, -1)\n\nimport {\n\tcomputed,\n\tonBeforeUnmount,\n\tonMounted,\n\tref,\n\tuseAttrs,\n\twatch,\n\tnextTick,\n\twatchPostEffect,\n} from 'vue';\nimport { throttle } from '@/utilities/functions/throttle';\nimport { useFocusTrap } from '@vueuse/integrations/useFocusTrap';\nimport { useId } from '@/composables/useId';\nimport { wait } from '@/utilities/functions/wait';\nimport { waitFor } from '@/utilities/functions/waitFor';\nimport type { CommonProps, Size } from '@/types/CommonProps';\n\nexport type Sizes = {\n\tsm: number;\n\tmd: number;\n\tlg: number;\n};\n\nexport type BaseDialogProps = Pick<\n\tCommonProps,\n\t| 'closeLabel'\n\t| 'compact'\n\t| 'disabled'\n\t| 'eager'\n\t| 'panelClasses'\n\t| 'overlayClasses'\n\t| 'persistent'\n\t| 'showClose'\n\t| 'title'\n\t| 'transition'\n\t| 'transitionDuration'\n> &\n\tSize<Sizes> & {\n\t\t/**\n\t\t * Description of the content of the modal. Extremely useful for accessibility reasons.\n\t\t */\n\t\tdescription?: string;\n\t\t/**\n\t\t * Displays the modala as fulscreen with no margin to the page\n\t\t */\n\t\tfullscreen?: boolean;\n\t\t/**\n\t\t * Defines the state open / closed of the modal.\n\t\t */\n\t\tmodelValue?: boolean | null;\n\t};\n\nexport type BaseDialogSlots = {\n\theader?: (props: {\n\t\ttitleId: typeof titleId;\n\t\tclose: typeof onCloseClick;\n\t\ttitle: BaseDialogProps['title'];\n\t}) => any;\n\ttitle?: (props: { text: BaseDialogProps['title'] }) => any;\n\tclose?: (props: { text: BaseDialogProps['closeLabel'] }) => any;\n\tdescription?: (props: {\n\t\tdescriptionId: typeof descriptionId;\n\t\ttext: BaseDialogProps['description'];\n\t}) => any;\n\tdefault?: (props: {}) => any;\n\tfooter?: (props: {}) => any;\n};\n\nexport type BaseDialogEvents = {\n\t(e: 'shown'): void;\n\t(e: 'hidden'): void;\n\t(e: 'update:modelValue', value: boolean): void;\n};\n\n\nexport default /*#__PURE__*/_defineComponent({\n __name: 'BaseDialog',\n props: {\n closeLabel: { default: 'Chiudi modale' },\n compact: { type: Boolean },\n disabled: { type: Boolean },\n eager: { type: Boolean },\n panelClasses: { default: () => [] },\n overlayClasses: { default: () => [] },\n persistent: { type: Boolean },\n showClose: { type: Boolean, default: true },\n title: {},\n transition: { default: 'fade' },\n transitionDuration: { default: 350 },\n size: { default: 'sm' },\n description: {},\n fullscreen: { type: Boolean },\n modelValue: { type: [Boolean, null] }\n },\n emits: [\"shown\", \"hidden\", \"update:modelValue\"],\n setup(__props: any, { emit: __emit }) {\n\nconst props = __props;\n\n\n\nconst emit = __emit;\n\nconst titleId = `title_${useId().id.value}`;\nconst descriptionId = `description_${useId().id.value}`;\n\nconst observer = ref<MutationObserver | null>(null);\nconst overlay = ref<HTMLElement | null>(null);\nconst panel = ref<HTMLElement | null>(null);\nconst content = ref<HTMLElement | null>(null);\nconst header = ref<HTMLElement | null>(null);\nconst body = ref<HTMLElement | null>(null);\nconst footer = ref<HTMLElement | null>(null);\nconst height = ref<number | null>(null);\n\nconst { activate, deactivate } = useFocusTrap(panel, {\n\tclickOutsideDeactivates: true,\n\t/* On esc deactivate the trap, return focus and then close the modal */\n\tescapeDeactivates: () => {\n\t\tnextTick(() => {\n\t\t\temit('update:modelValue', false);\n\t\t});\n\t\treturn true;\n\t},\n});\n\nconst attrs = useAttrs();\n\nconst closeLabel = computed(() => props.closeLabel);\n\nonMounted(async () => {\n\tif (body.value) {\n\t\tobserver.value = new MutationObserver(onContentGrow);\n\t\tobserver.value.observe(body.value, { childList: true, subtree: true });\n\t}\n\twindow.addEventListener('resize', onContentGrow);\n});\nonBeforeUnmount(() => {\n\twindow.removeEventListener('resize', onContentGrow);\n});\n\nconst open = ref(false);\nconst opening = ref(false);\nconst closed = ref(true);\nconst closing = ref(false);\nconst hasRenderedAtLeastOnce = ref(props.eager || props.modelValue);\n\nconst busy = computed(() => opening.value || closing.value);\n\nonBeforeUnmount(() => {\n\tif (props.modelValue) {\n\t\tlet currentlyOpenModals = Number(\n\t\t\tdocument.body.dataset['openModals'] ?? '0'\n\t\t);\n\t\t// This prevents overscroll chaining (additional scrolling to the body when the modal has been completely scrolled)\n\t\tcurrentlyOpenModals--;\n\t\tdocument.body.dataset['openModals'] = currentlyOpenModals.toString();\n\t\tif (!currentlyOpenModals) {\n\t\t\tdocument.body.style.overflow = 'auto';\n\t\t\tdocument.body.style.paddingRight = '0px';\n\t\t}\n\t}\n});\n\n/**\n * When modelValue becomes true if the component wasn't rendered render it\n * and wait for it to be on the page (or transitions would not work).\n * Stash the latest focused element so we can return it later when it closes.\n * Focus on the panel upon opening.\n * ---\n * Notice all interactions update modelValue and then this function aligns the display to it\n */\nconst alignToModelValue = async () => {\n\tif (props.modelValue) {\n\t\tif (!hasRenderedAtLeastOnce.value) {\n\t\t\thasRenderedAtLeastOnce.value = true;\n\t\t\tawait waitFor(() => !!body.value);\n\t\t\tawait nextTick();\n\t\t\tif (body.value) {\n\t\t\t\tobserver.value = new MutationObserver(onContentGrow);\n\t\t\t\tobserver.value.observe(body.value, { childList: true, subtree: true });\n\t\t\t}\n\t\t}\n\n\t\tclosed.value = false;\n\t\tclosing.value = false;\n\t\topening.value = true;\n\n\t\t// This prevents overscroll chaining (additional scrolling to the body when the modal has been completely scrolled)\n\n\t\tlet currentlyOpenModals = Number(\n\t\t\tdocument.body.dataset['openModals'] ?? '0'\n\t\t);\n\t\tcurrentlyOpenModals++;\n\t\tdocument.body.dataset['openModals'] = currentlyOpenModals.toString();\n\t\tconst scrollBarWidth =\n\t\t\twindow.innerWidth - document.documentElement.clientWidth;\n\t\tdocument.body.style.overflow = 'hidden';\n\t\tdocument.body.style.paddingRight = `${scrollBarWidth}px`;\n\n\t\tawait wait(props.transitionDuration);\n\t\topening.value = false;\n\t\topen.value = true;\n\t\temit('shown');\n\t\tactivate();\n\t} else {\n\t\tdeactivate();\n\t\topening.value = false;\n\t\topen.value = false;\n\t\tclosing.value = true;\n\n\t\tawait wait(props.transitionDuration);\n\n\t\tlet currentlyOpenModals = Number(\n\t\t\tdocument.body.dataset['openModals'] ?? '0'\n\t\t);\n\t\t// This prevents overscroll chaining (additional scrolling to the body when the modal has been completely scrolled)\n\t\tcurrentlyOpenModals--;\n\t\tdocument.body.dataset['openModals'] = currentlyOpenModals.toString();\n\t\tif (!currentlyOpenModals) {\n\t\t\tdocument.body.style.overflow = 'auto';\n\t\t\tdocument.body.style.paddingRight = '0px';\n\t\t}\n\t\tclosing.value = false;\n\t\tclosed.value = true;\n\t\temit('hidden');\n\t}\n};\n\n/**\n * Every time modelValue changes align the display to it\n */\nwatchPostEffect(() => {\n\tif (!props.modelValue && !hasRenderedAtLeastOnce.value) return;\n\talignToModelValue();\n});\n\n/**\n * Disable scrolling\n */\nconst onOverlayScroll = (event: UIEvent) => {\n\tif (event.target === overlay.value) {\n\t\tevent.preventDefault();\n\t}\n};\n\n/**\n * Close the modal on overlay click if not persistent\n */\nconst onOverlayClick = (event: MouseEvent) => {\n\tif (props.disabled || busy.value) return;\n\tif (overlay.value) {\n\t\tif (event.target === overlay.value) {\n\t\t\tif (!props.persistent) {\n\t\t\t\temit('update:modelValue', false);\n\t\t\t}\n\t\t}\n\t}\n};\n\n/**\n * On click on the X button\n */\nconst onCloseClick = () => {\n\tif (props.disabled || busy.value) return;\n\tdeactivate();\n\temit('update:modelValue', false);\n};\n\nconst overlayAttributes = computed(() => {\n\tconst classes = [\n\t\t{\n\t\t\t'bb-base-dialog bb-base-dialog__overlay': true,\n\t\t\t'bb-base-dialog--fullscreen': props.fullscreen,\n\t\t\t'bb-base-dialog--open': open.value,\n\t\t\t'bb-base-dialog--opening': opening.value,\n\t\t\t'bb-base-dialog--closed': closed.value,\n\t\t\t'bb-base-dialog--closing': closing.value,\n\t\t\t[`bb-base-dialog--transition-${props.transition}`]: true,\n\t\t},\n\t\tprops.overlayClasses,\n\t].flat();\n\tconst eventListeners = {\n\t\tonClick: onOverlayClick,\n\t\tonScroll: onOverlayScroll,\n\t\tonTouchmove: onOverlayScroll,\n\t\tonWheel: onOverlayScroll,\n\t\tonKeydown: onOverlayScroll,\n\t};\n\n\tconst style = {\n\t\ttransitionDuration: props.transitionDuration / 1000 + 's',\n\t};\n\treturn {\n\t\tclass: classes,\n\t\tstyle,\n\t\t...eventListeners,\n\t\t...attrs,\n\t};\n});\n\nconst panelAttributes = computed(() => {\n\tconst classes = [\n\t\t{\n\t\t\t'bb-base-dialog__panel': true,\n\t\t\t'bb-base-dialog__panel--compact': props.compact,\n\t\t},\n\t\tprops.panelClasses,\n\t].flat();\n\n\tconst accessibilityAttrs: {\n\t\t[key: string]: string | boolean;\n\t} = {\n\t\trole: 'dialog',\n\t\t'aria-modal': true,\n\t};\n\n\tif (hasRenderedAtLeastOnce.value) {\n\t\taccessibilityAttrs['aria-labelledby'] = titleId;\n\n\t\tif (props.description)\n\t\t\taccessibilityAttrs['aria-describedby'] = descriptionId;\n\t}\n\n\tlet maxWidth;\n\tconst sizes: Sizes = {\n\t\tsm: 384,\n\t\tmd: 652,\n\t\tlg: 896,\n\t};\n\tif (props.fullscreen) maxWidth = '100%';\n\telse if (typeof props.size === 'number') maxWidth = props.size + 'px';\n\telse if (props.size in sizes)\n\t\tmaxWidth = sizes[props.size as keyof Sizes] + 'px';\n\telse maxWidth = props.size + 'px';\n\n\tconst style = {\n\t\tmaxWidth,\n\t\ttransitionDuration: props.transitionDuration / 1000 + 's',\n\t};\n\n\treturn {\n\t\tclass: classes,\n\t\tstyle,\n\t\t...accessibilityAttrs,\n\t};\n});\n\n/**\n * This is called when content inside body changes.\n * Gets the total height the panel needs to be\n * It could be called numerous times so throttle every 300ms\n */\nconst onContentGrow = throttle(async () => {\n\tif (props.fullscreen) {\n\t\theight.value = window.innerHeight;\n\t\treturn;\n\t}\n\tif (header.value && body.value && footer.value) {\n\t\tconst contentHeight =\n\t\t\theader.value.scrollHeight +\n\t\t\tbody.value.scrollHeight +\n\t\t\tfooter.value.scrollHeight +\n\t\t\t2;\n\t\t/* Add two so renderless elements at the bottom are not cut off */\n\t\tif (content.value) {\n\t\t\tcontent.value.style.height = '0px';\n\t\t\tcontent.value.style.height = `${contentHeight + 10}px`;\n\t\t\t/**\n\t\t\t * Run until all transitions inside have completed\n\t\t\t */\n\t\t\tawait wait(30);\n\t\t\tif (header.value && body.value && footer.value) {\n\t\t\t\tconst contentHeight2 =\n\t\t\t\t\theader.value.scrollHeight +\n\t\t\t\t\tbody.value.scrollHeight +\n\t\t\t\t\tfooter.value.scrollHeight +\n\t\t\t\t\t20;\n\t\t\t\tif (contentHeight !== contentHeight2) onContentGrow();\n\t\t\t}\n\t\t}\n\t}\n}, 200);\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createBlock(_Teleport, { to: \"body\" }, [\n _createElementVNode(\"div\", _mergeProps(overlayAttributes.value, {\n ref_key: \"overlay\",\n ref: overlay\n }), [\n _createElementVNode(\"div\", _mergeProps(panelAttributes.value, {\n ref_key: \"panel\",\n ref: panel\n }), [\n (hasRenderedAtLeastOnce.value)\n ? (_openBlock(), _createElementBlock(\"div\", {\n key: 0,\n ref_key: \"content\",\n ref: content,\n class: \"bb-base-dialog__content\"\n }, [\n _createElementVNode(\"div\", {\n ref_key: \"header\",\n ref: header,\n class: \"bb-base-dialog__header\"\n }, [\n _renderSlot(_ctx.$slots, \"header\", {\n close: onCloseClick,\n title: _ctx.title,\n titleId: titleId\n }, () => [\n _createElementVNode(\"span\", {\n id: titleId,\n class: \"bb-base-dialog__title\"\n }, [\n _renderSlot(_ctx.$slots, \"title\", { text: _ctx.title }, () => [\n _createTextVNode(_toDisplayString(_ctx.title), 1)\n ])\n ]),\n _createElementVNode(\"span\", _hoisted_1, [\n (_ctx.showClose)\n ? (_openBlock(), _createElementBlock(\"button\", {\n key: 0,\n type: \"button\",\n onClick: onCloseClick\n }, [\n _renderSlot(_ctx.$slots, \"close\", { text: closeLabel.value }, () => [\n _createElementVNode(\"span\", _hoisted_2, [\n _createElementVNode(\"span\", _hoisted_3, _toDisplayString(closeLabel.value), 1),\n _hoisted_4\n ])\n ])\n ]))\n : _createCommentVNode(\"\", true)\n ])\n ])\n ], 512),\n _createElementVNode(\"div\", {\n ref_key: \"body\",\n ref: body,\n class: \"bb-base-dialog__body\"\n }, [\n _renderSlot(_ctx.$slots, \"description\", {\n descriptionId: descriptionId,\n text: _ctx.description\n }, () => [\n (_ctx.description)\n ? (_openBlock(), _createElementBlock(\"div\", {\n key: 0,\n id: descriptionId,\n class: \"bb-base-dialog__description\"\n }, _toDisplayString(_ctx.description), 1))\n : _createCommentVNode(\"\", true)\n ]),\n _renderSlot(_ctx.$slots, \"default\")\n ], 512),\n _hoisted_5,\n _createElementVNode(\"div\", {\n ref_key: \"footer\",\n ref: footer,\n class: \"bb-base-dialog__footer\"\n }, [\n _renderSlot(_ctx.$slots, \"footer\")\n ], 512)\n ], 512))\n : _createCommentVNode(\"\", true)\n ], 16)\n ], 16)\n ]))\n}\n}\n\n})"],"names":["_hoisted_1","_hoisted_2","_hoisted_3","_hoisted_4","_createElementVNode","_hoisted_5","_sfc_main","_defineComponent","__props","__emit","props","emit","titleId","useId","descriptionId","observer","ref","overlay","panel","content","header","body","footer","height","activate","deactivate","useFocusTrap","nextTick","attrs","useAttrs","closeLabel","computed","onMounted","onContentGrow","onBeforeUnmount","open","opening","closed","closing","hasRenderedAtLeastOnce","busy","currentlyOpenModals","alignToModelValue","waitFor","scrollBarWidth","wait","watchPostEffect","onOverlayScroll","event","onOverlayClick","onCloseClick","overlayAttributes","classes","eventListeners","style","panelAttributes","accessibilityAttrs","maxWidth","sizes","throttle","contentHeight","contentHeight2","_ctx","_cache","_openBlock","_createBlock","_Teleport","_mergeProps","_createElementBlock","_renderSlot","_createTextVNode","_toDisplayString","_createCommentVNode"],"mappings":";;;;;;AAGA,MAAMA,KAAa,EAAE,OAAO,0BACtBC,KAAa,EAAE,OAAO,mCACtBC,KAAa,EAAE,OAAO,iCACtBC,KAA8CC,gBAAAA,EAAA,QAAQ,EAAE,OAAO,gCAAgC;AAAA,oBAClE,OAAO;AAAA,IACtC,eAAe;AAAA,IACf,MAAM;AAAA,IACN,SAAS;AAAA,IACT,OAAO;AAAA,EAAA,GACN;AAAA,sBACgC,QAAQ;AAAA,MACvC,GAAG;AAAA,MACH,QAAQ;AAAA,MACR,kBAAkB;AAAA,MAClB,gBAAgB;AAAA,IAAA,CACjB;AAAA,EAAA,CACF;AACH,GAAG,EAAE,GACCC,KAA8CD,gBAAAA,EAAA,OAAO,EAAE,OAAO,EAAC,MAAO,mBAAqB,GAAA,MAAM,EAAE,GA6E7EE,KAAiBC,gBAAAA,EAAA;AAAA,EAC3C,QAAQ;AAAA,EACR,OAAO;AAAA,IACL,YAAY,EAAE,SAAS,gBAAgB;AAAA,IACvC,SAAS,EAAE,MAAM,QAAQ;AAAA,IACzB,UAAU,EAAE,MAAM,QAAQ;AAAA,IAC1B,OAAO,EAAE,MAAM,QAAQ;AAAA,IACvB,cAAc,EAAE,SAAS,MAAM,GAAG;AAAA,IAClC,gBAAgB,EAAE,SAAS,MAAM,GAAG;AAAA,IACpC,YAAY,EAAE,MAAM,QAAQ;AAAA,IAC5B,WAAW,EAAE,MAAM,SAAS,SAAS,GAAK;AAAA,IAC1C,OAAO,CAAC;AAAA,IACR,YAAY,EAAE,SAAS,OAAO;AAAA,IAC9B,oBAAoB,EAAE,SAAS,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.js
CHANGED
|
@@ -1,8 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
import { __require as o } from "./index230.js";
|
|
3
|
-
var t = o();
|
|
4
|
-
const s = /* @__PURE__ */ r(t);
|
|
1
|
+
const n = (t, a, m) => Math.min(Math.max(t, a), m);
|
|
5
2
|
export {
|
|
6
|
-
|
|
3
|
+
n as clamp
|
|
7
4
|
};
|
|
8
5
|
//# sourceMappingURL=index196.js.map
|
package/dist/index196.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index196.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index196.js","sources":["../src/utilities/functions/clamp.ts"],"sourcesContent":["/**\n * Returns value ensuring it doesn't go below min and exceed max.\n * EXAMPLE: clamp(5, 7, 20) === 7\n * @param value The value to clamp\n * @param min Minimum bound\n * @param max Maximum bound\n * @returns\n */\n\nexport const clamp = (value: number, min: number, max: number) => {\n\treturn Math.min(Math.max(value, min), max);\n};\n"],"names":["clamp","value","min","max"],"mappings":"AASO,MAAMA,IAAQ,CAACC,GAAeC,GAAaC,MAC1C,KAAK,IAAI,KAAK,IAAIF,GAAOC,CAAG,GAAGC,CAAG;"}
|
package/dist/index197.js
CHANGED
|
@@ -1,19 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
import { __module as e } from "./index233.js";
|
|
3
|
-
(function(s, a) {
|
|
4
|
-
(function(i, t) {
|
|
5
|
-
s.exports = t();
|
|
6
|
-
})(n, function() {
|
|
7
|
-
return function(i, t) {
|
|
8
|
-
t.prototype.isSameOrAfter = function(r, o) {
|
|
9
|
-
return this.isSame(r, o) || this.isAfter(r, o);
|
|
10
|
-
};
|
|
11
|
-
};
|
|
12
|
-
});
|
|
13
|
-
})(e);
|
|
14
|
-
var m = e.exports;
|
|
15
|
-
const c = /* @__PURE__ */ f(m);
|
|
1
|
+
const s = (r) => !!r && !!r.match(/^(#|var\(--|(rgb|hsl)a?\()/);
|
|
16
2
|
export {
|
|
17
|
-
|
|
3
|
+
s as isCssColor
|
|
18
4
|
};
|
|
19
5
|
//# sourceMappingURL=index197.js.map
|
package/dist/index197.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index197.js","sources":["../
|
|
1
|
+
{"version":3,"file":"index197.js","sources":["../src/utilities/functions/isCssColor.ts"],"sourcesContent":["/**\n * Taken from vuetify colorable mixin\n * https://github.com/vuetifyjs/vuetify/blob/master/packages/vuetify/src/mixins/colorable/index.ts\n */\nexport const isCssColor = (color: string): boolean => {\n\treturn !!color && !!color.match(/^(#|var\\(--|(rgb|hsl)a?\\()/);\n};\n"],"names":["isCssColor","color"],"mappings":"AAIa,MAAAA,IAAa,CAACC,MACnB,CAAC,CAACA,KAAS,CAAC,CAACA,EAAM,MAAM,4BAA4B;"}
|
package/dist/index198.js
CHANGED
|
@@ -1,19 +1,7 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
(function(s, a) {
|
|
4
|
-
(function(f, o) {
|
|
5
|
-
s.exports = o();
|
|
6
|
-
})(n, function() {
|
|
7
|
-
return function(f, o) {
|
|
8
|
-
o.prototype.isSameOrBefore = function(e, r) {
|
|
9
|
-
return this.isSame(e, r) || this.isBefore(e, r);
|
|
10
|
-
};
|
|
11
|
-
};
|
|
12
|
-
});
|
|
13
|
-
})(t);
|
|
14
|
-
var m = t.exports;
|
|
15
|
-
const c = /* @__PURE__ */ i(m);
|
|
1
|
+
import { curry as e } from "./index227.js";
|
|
2
|
+
const t = (n, o, r) => n(r) ? o(r) : r, s = e(t);
|
|
16
3
|
export {
|
|
17
|
-
|
|
4
|
+
t as baseWhen,
|
|
5
|
+
s as when
|
|
18
6
|
};
|
|
19
7
|
//# sourceMappingURL=index198.js.map
|
package/dist/index198.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index198.js","sources":["../
|
|
1
|
+
{"version":3,"file":"index198.js","sources":["../src/utilities/functions/when.ts"],"sourcesContent":["import { curry } from './curry';\n/**\n * Runs fn on item if iteratee(item) is thruthy\n * @param iteratee The test\n * @param item The item to test\n * @param fn The transformer function\n * @returns\n */\nexport const baseWhen = <T, U>(\n\titeratee: (item: T) => boolean,\n\tfn: (item: T) => U,\n\titem: T\n) => {\n\tif (iteratee(item)) return fn(item);\n\treturn item;\n};\n\nexport const when = curry(baseWhen);\n"],"names":["baseWhen","iteratee","fn","item","when","curry"],"mappings":";AAQO,MAAMA,IAAW,CACvBC,GACAC,GACAC,MAEIF,EAASE,CAAI,IAAUD,EAAGC,CAAI,IAC3BA,GAGKC,IAAOC,EAAML,CAAQ;"}
|
package/dist/index199.js
CHANGED
|
@@ -1,22 +1,298 @@
|
|
|
1
|
-
import { getDefaultExportFromCjs as
|
|
2
|
-
import { __module as
|
|
3
|
-
|
|
4
|
-
(function(
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
return
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
return
|
|
13
|
-
}
|
|
14
|
-
|
|
1
|
+
import { getDefaultExportFromCjs as Q, commonjsGlobal as K } from "./index229.js";
|
|
2
|
+
import { __module as E } from "./index230.js";
|
|
3
|
+
(function(V, X) {
|
|
4
|
+
(function(W, k) {
|
|
5
|
+
V.exports = k();
|
|
6
|
+
})(K, function() {
|
|
7
|
+
var W = 1e3, k = 6e4, N = 36e5, A = "millisecond", S = "second", w = "minute", O = "hour", M = "day", T = "week", m = "month", U = "quarter", y = "year", _ = "date", J = "Invalid Date", q = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, B = /\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g, G = { name: "en", weekdays: "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"), months: "January_February_March_April_May_June_July_August_September_October_November_December".split("_"), ordinal: function(s) {
|
|
8
|
+
var n = ["th", "st", "nd", "rd"], t = s % 100;
|
|
9
|
+
return "[" + s + (n[(t - 20) % 10] || n[t] || n[0]) + "]";
|
|
10
|
+
} }, I = function(s, n, t) {
|
|
11
|
+
var r = String(s);
|
|
12
|
+
return !r || r.length >= n ? s : "" + Array(n + 1 - r.length).join(t) + s;
|
|
13
|
+
}, P = { s: I, z: function(s) {
|
|
14
|
+
var n = -s.utcOffset(), t = Math.abs(n), r = Math.floor(t / 60), e = t % 60;
|
|
15
|
+
return (n <= 0 ? "+" : "-") + I(r, 2, "0") + ":" + I(e, 2, "0");
|
|
16
|
+
}, m: function s(n, t) {
|
|
17
|
+
if (n.date() < t.date())
|
|
18
|
+
return -s(t, n);
|
|
19
|
+
var r = 12 * (t.year() - n.year()) + (t.month() - n.month()), e = n.clone().add(r, m), i = t - e < 0, u = n.clone().add(r + (i ? -1 : 1), m);
|
|
20
|
+
return +(-(r + (t - e) / (i ? e - u : u - e)) || 0);
|
|
21
|
+
}, a: function(s) {
|
|
22
|
+
return s < 0 ? Math.ceil(s) || 0 : Math.floor(s);
|
|
23
|
+
}, p: function(s) {
|
|
24
|
+
return { M: m, y, w: T, d: M, D: _, h: O, m: w, s: S, ms: A, Q: U }[s] || String(s || "").toLowerCase().replace(/s$/, "");
|
|
25
|
+
}, u: function(s) {
|
|
26
|
+
return s === void 0;
|
|
27
|
+
} }, x = "en", D = {};
|
|
28
|
+
D[x] = G;
|
|
29
|
+
var Z = "$isDayjsObject", F = function(s) {
|
|
30
|
+
return s instanceof C || !(!s || !s[Z]);
|
|
31
|
+
}, j = function s(n, t, r) {
|
|
32
|
+
var e;
|
|
33
|
+
if (!n)
|
|
34
|
+
return x;
|
|
35
|
+
if (typeof n == "string") {
|
|
36
|
+
var i = n.toLowerCase();
|
|
37
|
+
D[i] && (e = i), t && (D[i] = t, e = i);
|
|
38
|
+
var u = n.split("-");
|
|
39
|
+
if (!e && u.length > 1)
|
|
40
|
+
return s(u[0]);
|
|
41
|
+
} else {
|
|
42
|
+
var o = n.name;
|
|
43
|
+
D[o] = n, e = o;
|
|
44
|
+
}
|
|
45
|
+
return !r && e && (x = e), e || !r && x;
|
|
46
|
+
}, f = function(s, n) {
|
|
47
|
+
if (F(s))
|
|
48
|
+
return s.clone();
|
|
49
|
+
var t = typeof n == "object" ? n : {};
|
|
50
|
+
return t.date = s, t.args = arguments, new C(t);
|
|
51
|
+
}, a = P;
|
|
52
|
+
a.l = j, a.i = F, a.w = function(s, n) {
|
|
53
|
+
return f(s, { locale: n.$L, utc: n.$u, x: n.$x, $offset: n.$offset });
|
|
54
|
+
};
|
|
55
|
+
var C = function() {
|
|
56
|
+
function s(t) {
|
|
57
|
+
this.$L = j(t.locale, null, !0), this.parse(t), this.$x = this.$x || t.x || {}, this[Z] = !0;
|
|
58
|
+
}
|
|
59
|
+
var n = s.prototype;
|
|
60
|
+
return n.parse = function(t) {
|
|
61
|
+
this.$d = function(r) {
|
|
62
|
+
var e = r.date, i = r.utc;
|
|
63
|
+
if (e === null)
|
|
64
|
+
return /* @__PURE__ */ new Date(NaN);
|
|
65
|
+
if (a.u(e))
|
|
66
|
+
return /* @__PURE__ */ new Date();
|
|
67
|
+
if (e instanceof Date)
|
|
68
|
+
return new Date(e);
|
|
69
|
+
if (typeof e == "string" && !/Z$/i.test(e)) {
|
|
70
|
+
var u = e.match(q);
|
|
71
|
+
if (u) {
|
|
72
|
+
var o = u[2] - 1 || 0, c = (u[7] || "0").substring(0, 3);
|
|
73
|
+
return i ? new Date(Date.UTC(u[1], o, u[3] || 1, u[4] || 0, u[5] || 0, u[6] || 0, c)) : new Date(u[1], o, u[3] || 1, u[4] || 0, u[5] || 0, u[6] || 0, c);
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
return new Date(e);
|
|
77
|
+
}(t), this.init();
|
|
78
|
+
}, n.init = function() {
|
|
79
|
+
var t = this.$d;
|
|
80
|
+
this.$y = t.getFullYear(), this.$M = t.getMonth(), this.$D = t.getDate(), this.$W = t.getDay(), this.$H = t.getHours(), this.$m = t.getMinutes(), this.$s = t.getSeconds(), this.$ms = t.getMilliseconds();
|
|
81
|
+
}, n.$utils = function() {
|
|
82
|
+
return a;
|
|
83
|
+
}, n.isValid = function() {
|
|
84
|
+
return this.$d.toString() !== J;
|
|
85
|
+
}, n.isSame = function(t, r) {
|
|
86
|
+
var e = f(t);
|
|
87
|
+
return this.startOf(r) <= e && e <= this.endOf(r);
|
|
88
|
+
}, n.isAfter = function(t, r) {
|
|
89
|
+
return f(t) < this.startOf(r);
|
|
90
|
+
}, n.isBefore = function(t, r) {
|
|
91
|
+
return this.endOf(r) < f(t);
|
|
92
|
+
}, n.$g = function(t, r, e) {
|
|
93
|
+
return a.u(t) ? this[r] : this.set(e, t);
|
|
94
|
+
}, n.unix = function() {
|
|
95
|
+
return Math.floor(this.valueOf() / 1e3);
|
|
96
|
+
}, n.valueOf = function() {
|
|
97
|
+
return this.$d.getTime();
|
|
98
|
+
}, n.startOf = function(t, r) {
|
|
99
|
+
var e = this, i = !!a.u(r) || r, u = a.p(t), o = function(p, $) {
|
|
100
|
+
var v = a.w(e.$u ? Date.UTC(e.$y, $, p) : new Date(e.$y, $, p), e);
|
|
101
|
+
return i ? v : v.endOf(M);
|
|
102
|
+
}, c = function(p, $) {
|
|
103
|
+
return a.w(e.toDate()[p].apply(e.toDate("s"), (i ? [0, 0, 0, 0] : [23, 59, 59, 999]).slice($)), e);
|
|
104
|
+
}, h = this.$W, d = this.$M, l = this.$D, b = "set" + (this.$u ? "UTC" : "");
|
|
105
|
+
switch (u) {
|
|
106
|
+
case y:
|
|
107
|
+
return i ? o(1, 0) : o(31, 11);
|
|
108
|
+
case m:
|
|
109
|
+
return i ? o(1, d) : o(0, d + 1);
|
|
110
|
+
case T:
|
|
111
|
+
var g = this.$locale().weekStart || 0, Y = (h < g ? h + 7 : h) - g;
|
|
112
|
+
return o(i ? l - Y : l + (6 - Y), d);
|
|
113
|
+
case M:
|
|
114
|
+
case _:
|
|
115
|
+
return c(b + "Hours", 0);
|
|
116
|
+
case O:
|
|
117
|
+
return c(b + "Minutes", 1);
|
|
118
|
+
case w:
|
|
119
|
+
return c(b + "Seconds", 2);
|
|
120
|
+
case S:
|
|
121
|
+
return c(b + "Milliseconds", 3);
|
|
122
|
+
default:
|
|
123
|
+
return this.clone();
|
|
124
|
+
}
|
|
125
|
+
}, n.endOf = function(t) {
|
|
126
|
+
return this.startOf(t, !1);
|
|
127
|
+
}, n.$set = function(t, r) {
|
|
128
|
+
var e, i = a.p(t), u = "set" + (this.$u ? "UTC" : ""), o = (e = {}, e[M] = u + "Date", e[_] = u + "Date", e[m] = u + "Month", e[y] = u + "FullYear", e[O] = u + "Hours", e[w] = u + "Minutes", e[S] = u + "Seconds", e[A] = u + "Milliseconds", e)[i], c = i === M ? this.$D + (r - this.$W) : r;
|
|
129
|
+
if (i === m || i === y) {
|
|
130
|
+
var h = this.clone().set(_, 1);
|
|
131
|
+
h.$d[o](c), h.init(), this.$d = h.set(_, Math.min(this.$D, h.daysInMonth())).$d;
|
|
132
|
+
} else
|
|
133
|
+
o && this.$d[o](c);
|
|
134
|
+
return this.init(), this;
|
|
135
|
+
}, n.set = function(t, r) {
|
|
136
|
+
return this.clone().$set(t, r);
|
|
137
|
+
}, n.get = function(t) {
|
|
138
|
+
return this[a.p(t)]();
|
|
139
|
+
}, n.add = function(t, r) {
|
|
140
|
+
var e, i = this;
|
|
141
|
+
t = Number(t);
|
|
142
|
+
var u = a.p(r), o = function(d) {
|
|
143
|
+
var l = f(i);
|
|
144
|
+
return a.w(l.date(l.date() + Math.round(d * t)), i);
|
|
145
|
+
};
|
|
146
|
+
if (u === m)
|
|
147
|
+
return this.set(m, this.$M + t);
|
|
148
|
+
if (u === y)
|
|
149
|
+
return this.set(y, this.$y + t);
|
|
150
|
+
if (u === M)
|
|
151
|
+
return o(1);
|
|
152
|
+
if (u === T)
|
|
153
|
+
return o(7);
|
|
154
|
+
var c = (e = {}, e[w] = k, e[O] = N, e[S] = W, e)[u] || 1, h = this.$d.getTime() + t * c;
|
|
155
|
+
return a.w(h, this);
|
|
156
|
+
}, n.subtract = function(t, r) {
|
|
157
|
+
return this.add(-1 * t, r);
|
|
158
|
+
}, n.format = function(t) {
|
|
159
|
+
var r = this, e = this.$locale();
|
|
160
|
+
if (!this.isValid())
|
|
161
|
+
return e.invalidDate || J;
|
|
162
|
+
var i = t || "YYYY-MM-DDTHH:mm:ssZ", u = a.z(this), o = this.$H, c = this.$m, h = this.$M, d = e.weekdays, l = e.months, b = e.meridiem, g = function($, v, H, L) {
|
|
163
|
+
return $ && ($[v] || $(r, i)) || H[v].slice(0, L);
|
|
164
|
+
}, Y = function($) {
|
|
165
|
+
return a.s(o % 12 || 12, $, "0");
|
|
166
|
+
}, p = b || function($, v, H) {
|
|
167
|
+
var L = $ < 12 ? "AM" : "PM";
|
|
168
|
+
return H ? L.toLowerCase() : L;
|
|
169
|
+
};
|
|
170
|
+
return i.replace(B, function($, v) {
|
|
171
|
+
return v || function(H) {
|
|
172
|
+
switch (H) {
|
|
173
|
+
case "YY":
|
|
174
|
+
return String(r.$y).slice(-2);
|
|
175
|
+
case "YYYY":
|
|
176
|
+
return a.s(r.$y, 4, "0");
|
|
177
|
+
case "M":
|
|
178
|
+
return h + 1;
|
|
179
|
+
case "MM":
|
|
180
|
+
return a.s(h + 1, 2, "0");
|
|
181
|
+
case "MMM":
|
|
182
|
+
return g(e.monthsShort, h, l, 3);
|
|
183
|
+
case "MMMM":
|
|
184
|
+
return g(l, h);
|
|
185
|
+
case "D":
|
|
186
|
+
return r.$D;
|
|
187
|
+
case "DD":
|
|
188
|
+
return a.s(r.$D, 2, "0");
|
|
189
|
+
case "d":
|
|
190
|
+
return String(r.$W);
|
|
191
|
+
case "dd":
|
|
192
|
+
return g(e.weekdaysMin, r.$W, d, 2);
|
|
193
|
+
case "ddd":
|
|
194
|
+
return g(e.weekdaysShort, r.$W, d, 3);
|
|
195
|
+
case "dddd":
|
|
196
|
+
return d[r.$W];
|
|
197
|
+
case "H":
|
|
198
|
+
return String(o);
|
|
199
|
+
case "HH":
|
|
200
|
+
return a.s(o, 2, "0");
|
|
201
|
+
case "h":
|
|
202
|
+
return Y(1);
|
|
203
|
+
case "hh":
|
|
204
|
+
return Y(2);
|
|
205
|
+
case "a":
|
|
206
|
+
return p(o, c, !0);
|
|
207
|
+
case "A":
|
|
208
|
+
return p(o, c, !1);
|
|
209
|
+
case "m":
|
|
210
|
+
return String(c);
|
|
211
|
+
case "mm":
|
|
212
|
+
return a.s(c, 2, "0");
|
|
213
|
+
case "s":
|
|
214
|
+
return String(r.$s);
|
|
215
|
+
case "ss":
|
|
216
|
+
return a.s(r.$s, 2, "0");
|
|
217
|
+
case "SSS":
|
|
218
|
+
return a.s(r.$ms, 3, "0");
|
|
219
|
+
case "Z":
|
|
220
|
+
return u;
|
|
221
|
+
}
|
|
222
|
+
return null;
|
|
223
|
+
}($) || u.replace(":", "");
|
|
224
|
+
});
|
|
225
|
+
}, n.utcOffset = function() {
|
|
226
|
+
return 15 * -Math.round(this.$d.getTimezoneOffset() / 15);
|
|
227
|
+
}, n.diff = function(t, r, e) {
|
|
228
|
+
var i, u = this, o = a.p(r), c = f(t), h = (c.utcOffset() - this.utcOffset()) * k, d = this - c, l = function() {
|
|
229
|
+
return a.m(u, c);
|
|
230
|
+
};
|
|
231
|
+
switch (o) {
|
|
232
|
+
case y:
|
|
233
|
+
i = l() / 12;
|
|
234
|
+
break;
|
|
235
|
+
case m:
|
|
236
|
+
i = l();
|
|
237
|
+
break;
|
|
238
|
+
case U:
|
|
239
|
+
i = l() / 3;
|
|
240
|
+
break;
|
|
241
|
+
case T:
|
|
242
|
+
i = (d - h) / 6048e5;
|
|
243
|
+
break;
|
|
244
|
+
case M:
|
|
245
|
+
i = (d - h) / 864e5;
|
|
246
|
+
break;
|
|
247
|
+
case O:
|
|
248
|
+
i = d / N;
|
|
249
|
+
break;
|
|
250
|
+
case w:
|
|
251
|
+
i = d / k;
|
|
252
|
+
break;
|
|
253
|
+
case S:
|
|
254
|
+
i = d / W;
|
|
255
|
+
break;
|
|
256
|
+
default:
|
|
257
|
+
i = d;
|
|
258
|
+
}
|
|
259
|
+
return e ? i : a.a(i);
|
|
260
|
+
}, n.daysInMonth = function() {
|
|
261
|
+
return this.endOf(m).$D;
|
|
262
|
+
}, n.$locale = function() {
|
|
263
|
+
return D[this.$L];
|
|
264
|
+
}, n.locale = function(t, r) {
|
|
265
|
+
if (!t)
|
|
266
|
+
return this.$L;
|
|
267
|
+
var e = this.clone(), i = j(t, r, !0);
|
|
268
|
+
return i && (e.$L = i), e;
|
|
269
|
+
}, n.clone = function() {
|
|
270
|
+
return a.w(this.$d, this);
|
|
271
|
+
}, n.toDate = function() {
|
|
272
|
+
return new Date(this.valueOf());
|
|
273
|
+
}, n.toJSON = function() {
|
|
274
|
+
return this.isValid() ? this.toISOString() : null;
|
|
275
|
+
}, n.toISOString = function() {
|
|
276
|
+
return this.$d.toISOString();
|
|
277
|
+
}, n.toString = function() {
|
|
278
|
+
return this.$d.toUTCString();
|
|
279
|
+
}, s;
|
|
280
|
+
}(), z = C.prototype;
|
|
281
|
+
return f.prototype = z, [["$ms", A], ["$s", S], ["$m", w], ["$H", O], ["$W", M], ["$M", m], ["$y", y], ["$D", _]].forEach(function(s) {
|
|
282
|
+
z[s[1]] = function(n) {
|
|
283
|
+
return this.$g(n, s[0], s[1]);
|
|
284
|
+
};
|
|
285
|
+
}), f.extend = function(s, n) {
|
|
286
|
+
return s.$i || (s(n, C, f), s.$i = !0), f;
|
|
287
|
+
}, f.locale = j, f.isDayjs = F, f.unix = function(s) {
|
|
288
|
+
return f(1e3 * s);
|
|
289
|
+
}, f.en = D[x], f.Ls = D, f.p = {}, f;
|
|
15
290
|
});
|
|
16
|
-
})(
|
|
17
|
-
var
|
|
18
|
-
const
|
|
291
|
+
})(E);
|
|
292
|
+
var R = E.exports;
|
|
293
|
+
const nt = /* @__PURE__ */ Q(R);
|
|
19
294
|
export {
|
|
20
|
-
|
|
295
|
+
R as d,
|
|
296
|
+
nt as default
|
|
21
297
|
};
|
|
22
298
|
//# sourceMappingURL=index199.js.map
|