@codeandfunction/callaloo 4.9.2 → 4.9.3
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/callaloo.global.js +1 -1
- package/dist/chunks/{CLCalendar-BGwHfZr9.js → CLCalendar.vue_vue_type_style_index_0_lang-Bz1JdT1A.js} +52 -52
- package/dist/components/Containers/CLCarousel/CLCarousel.js +148 -144
- package/dist/components/Form/CLCalendar/CLCalendar.css +1 -1
- package/dist/components/Form/CLCalendar/CLCalendar.js +3 -3
- package/dist/components/Form/CLInputDatePicker/CLInputDatePicker.css +1 -1
- package/dist/components/Form/CLInputDatePicker/CLInputDatePicker.js +60 -61
- package/dist/components/Modals/CLModalDatePicker/CLModalDatePicker.css +1 -1
- package/dist/components/Modals/CLModalDatePicker/CLModalDatePicker.js +53 -54
- package/dist/styles.css +1 -1
- package/package.json +1 -1
- package/dist/chunks/_plugin-vue_export-helper-CHgC5LLL.js +0 -9
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
1
|
+
import '../components/Form/CLCalendar/CLCalendar.css';
|
|
2
|
+
import { defineComponent as Y, mergeModels as w, useCssVars as Z, useModel as ee, ref as S, toRef as ae, watch as te, onMounted as le, createElementBlock as s, openBlock as r, normalizeClass as u, createElementVNode as M, createVNode as f, unref as e, withCtx as h, createTextVNode as v, toDisplayString as C, Fragment as V, renderList as $, createBlock as ie, createCommentVNode as re } from "vue";
|
|
2
3
|
import { _ as b } from "./CLButton.vue_vue_type_style_index_0_lang-MvhnNzVW.js";
|
|
3
4
|
import { _ as B } from "./CLText.vue_vue_type_style_index_0_lang-B-L8ECJL.js";
|
|
4
|
-
import { CLColorVariants as c, CLSizes as
|
|
5
|
-
import { useDatePicker as
|
|
6
|
-
|
|
7
|
-
const se = ["data-testid"], ue = /* @__PURE__ */ Y({
|
|
5
|
+
import { CLColorVariants as c, CLSizes as k, CLIconSizes as N, CLIconNames as P, CLBorderRadius as _, CLTextTypes as R, CLColors as g, CLAlign as ne } from "../index.js";
|
|
6
|
+
import { useDatePicker as oe } from "../composables/useDatePicker.js";
|
|
7
|
+
const de = ["data-testid"], ve = /* @__PURE__ */ Y({
|
|
8
8
|
name: "CLCalendar",
|
|
9
9
|
__name: "CLCalendar",
|
|
10
10
|
props: /* @__PURE__ */ w({
|
|
@@ -20,69 +20,69 @@ const se = ["data-testid"], ue = /* @__PURE__ */ Y({
|
|
|
20
20
|
modelModifiers: {}
|
|
21
21
|
}),
|
|
22
22
|
emits: /* @__PURE__ */ w(["date-select"], ["update:modelValue"]),
|
|
23
|
-
setup(l, { expose: T, emit:
|
|
23
|
+
setup(l, { expose: T, emit: E }) {
|
|
24
24
|
Z((t) => ({
|
|
25
|
-
|
|
25
|
+
v63768322: t.width
|
|
26
26
|
}));
|
|
27
|
-
const m = l,
|
|
27
|
+
const m = l, I = E, i = "clll-calendar", n = ee(l, "modelValue"), o = S(n.value?.end ?? null), d = S(n.value?.start ?? null), {
|
|
28
28
|
calendarGrid: F,
|
|
29
29
|
cancelDraft: G,
|
|
30
30
|
clearDraft: A,
|
|
31
31
|
currentMonthLabel: O,
|
|
32
|
-
draftEnd:
|
|
33
|
-
draftStart:
|
|
32
|
+
draftEnd: D,
|
|
33
|
+
draftStart: x,
|
|
34
34
|
getDayAriaLabel: j,
|
|
35
35
|
handleNextMonth: q,
|
|
36
36
|
handlePrevMonth: H,
|
|
37
37
|
initializeDraft: p,
|
|
38
|
-
isDraftEnd:
|
|
39
|
-
isDraftStart:
|
|
38
|
+
isDraftEnd: z,
|
|
39
|
+
isDraftStart: L,
|
|
40
40
|
isInDraftRange: J,
|
|
41
41
|
onDayClick: K,
|
|
42
42
|
weekDays: Q
|
|
43
|
-
} =
|
|
44
|
-
appliedEnd:
|
|
43
|
+
} = oe({
|
|
44
|
+
appliedEnd: o,
|
|
45
45
|
appliedStart: d,
|
|
46
46
|
isRange: ae(m, "isRange")
|
|
47
47
|
});
|
|
48
|
-
te(
|
|
49
|
-
d.value = t?.start ?? null,
|
|
48
|
+
te(n, (t) => {
|
|
49
|
+
d.value = t?.start ?? null, o.value = t?.end ?? null, p();
|
|
50
50
|
}, { deep: !0 }), le(() => {
|
|
51
51
|
p();
|
|
52
52
|
});
|
|
53
|
-
const U = (t,
|
|
54
|
-
|
|
53
|
+
const U = (t, y) => {
|
|
54
|
+
y?.preventDefault(), y?.stopPropagation(), !(m.disabled || m.busy || !t) && (K(t), I("date-select", t));
|
|
55
55
|
};
|
|
56
56
|
return T({
|
|
57
57
|
apply: () => {
|
|
58
|
-
d.value =
|
|
59
|
-
end:
|
|
58
|
+
d.value = x.value, o.value = D.value, n.value = {
|
|
59
|
+
end: o.value,
|
|
60
60
|
start: d.value
|
|
61
61
|
};
|
|
62
62
|
},
|
|
63
63
|
cancel: () => {
|
|
64
64
|
G();
|
|
65
65
|
},
|
|
66
|
-
draftEnd:
|
|
67
|
-
draftStart:
|
|
66
|
+
draftEnd: D,
|
|
67
|
+
draftStart: x,
|
|
68
68
|
initializeDraft: p,
|
|
69
69
|
reset: () => {
|
|
70
|
-
A(), d.value = null,
|
|
70
|
+
A(), d.value = null, o.value = null, n.value = null;
|
|
71
71
|
}
|
|
72
|
-
}), (t,
|
|
73
|
-
class: u([
|
|
72
|
+
}), (t, y) => (r(), s("div", {
|
|
73
|
+
class: u([i, l.fluid ? `${i}__fluid` : ""]),
|
|
74
74
|
"data-testid": l.testId
|
|
75
75
|
}, [
|
|
76
76
|
M("div", {
|
|
77
|
-
class: u(`${
|
|
77
|
+
class: u(`${i}__header`)
|
|
78
78
|
}, [
|
|
79
79
|
f(e(b), {
|
|
80
80
|
"aria-label": "Previous month",
|
|
81
|
-
"border-radius": e(
|
|
81
|
+
"border-radius": e(_).Full,
|
|
82
82
|
"icon-before": e(P).ChevronLeft,
|
|
83
83
|
"icon-size": e(N).Tiny,
|
|
84
84
|
"on-click": e(H),
|
|
85
|
-
size: e(
|
|
85
|
+
size: e(k).Tiny,
|
|
86
86
|
variant: e(c).Ghost,
|
|
87
87
|
height: "32px",
|
|
88
88
|
width: "32px",
|
|
@@ -92,18 +92,18 @@ const se = ["data-testid"], ue = /* @__PURE__ */ Y({
|
|
|
92
92
|
type: e(R).Medium,
|
|
93
93
|
medium: ""
|
|
94
94
|
}, {
|
|
95
|
-
default:
|
|
96
|
-
|
|
95
|
+
default: h(() => [
|
|
96
|
+
v(C(e(O)), 1)
|
|
97
97
|
]),
|
|
98
98
|
_: 1
|
|
99
99
|
}, 8, ["type"]),
|
|
100
100
|
f(e(b), {
|
|
101
101
|
"aria-label": "Next month",
|
|
102
|
-
"border-radius": e(
|
|
102
|
+
"border-radius": e(_).Full,
|
|
103
103
|
"icon-before": e(P).ChevronRight,
|
|
104
104
|
"icon-size": e(N).Tiny,
|
|
105
105
|
"on-click": e(q),
|
|
106
|
-
size: e(
|
|
106
|
+
size: e(k).Tiny,
|
|
107
107
|
variant: e(c).Ghost,
|
|
108
108
|
height: "32px",
|
|
109
109
|
width: "32px",
|
|
@@ -111,53 +111,53 @@ const se = ["data-testid"], ue = /* @__PURE__ */ Y({
|
|
|
111
111
|
}, null, 8, ["border-radius", "icon-before", "icon-size", "on-click", "size", "variant"])
|
|
112
112
|
], 2),
|
|
113
113
|
M("div", {
|
|
114
|
-
class: u(`${
|
|
114
|
+
class: u(`${i}__grid`)
|
|
115
115
|
}, [
|
|
116
|
-
(
|
|
116
|
+
(r(!0), s(V, null, $(e(Q), (a) => (r(), s("div", {
|
|
117
117
|
key: a,
|
|
118
|
-
class: u(`${
|
|
118
|
+
class: u(`${i}__weekday`)
|
|
119
119
|
}, [
|
|
120
120
|
f(e(B), {
|
|
121
|
-
align: e(
|
|
121
|
+
align: e(ne).Center,
|
|
122
122
|
color: e(g).Neutral,
|
|
123
123
|
type: e(R).Small
|
|
124
124
|
}, {
|
|
125
|
-
default:
|
|
126
|
-
|
|
125
|
+
default: h(() => [
|
|
126
|
+
v(C(a), 1)
|
|
127
127
|
]),
|
|
128
128
|
_: 2
|
|
129
129
|
}, 1032, ["align", "color", "type"])
|
|
130
130
|
], 2))), 128)),
|
|
131
|
-
(
|
|
131
|
+
(r(!0), s(V, null, $(e(F), (a, W) => (r(), s("div", {
|
|
132
132
|
key: a.date ?? `pad-${W}`,
|
|
133
133
|
class: u([
|
|
134
|
-
`${
|
|
135
|
-
a.isOutsideMonth ? `${
|
|
134
|
+
`${i}__cell`,
|
|
135
|
+
a.isOutsideMonth ? `${i}__cell--outside` : ""
|
|
136
136
|
])
|
|
137
137
|
}, [
|
|
138
|
-
a.day && a.date ? (
|
|
138
|
+
a.day && a.date ? (r(), ie(e(b), {
|
|
139
139
|
key: 0,
|
|
140
140
|
"aria-label": e(j)(a.date),
|
|
141
|
-
"border-radius": e(
|
|
142
|
-
color: e(
|
|
141
|
+
"border-radius": e(_).Full,
|
|
142
|
+
color: e(L)(a.date) || e(z)(a.date) ? l.color : e(g).Secondary,
|
|
143
143
|
disabled: l.disabled || l.busy,
|
|
144
|
-
size: e(
|
|
144
|
+
size: e(k).Small,
|
|
145
145
|
height: "100%",
|
|
146
146
|
width: "100%",
|
|
147
147
|
"on-click": (X) => U(a.date, X),
|
|
148
|
-
variant: e(
|
|
148
|
+
variant: e(L)(a.date) || e(z)(a.date) ? e(c).Solid : e(J)(a.date) ? e(c).Soft : e(c).Ghost,
|
|
149
149
|
wrap: ""
|
|
150
150
|
}, {
|
|
151
|
-
default:
|
|
152
|
-
|
|
151
|
+
default: h(() => [
|
|
152
|
+
v(C(a.day), 1)
|
|
153
153
|
]),
|
|
154
154
|
_: 2
|
|
155
|
-
}, 1032, ["aria-label", "border-radius", "color", "disabled", "size", "on-click", "variant"])) :
|
|
155
|
+
}, 1032, ["aria-label", "border-radius", "color", "disabled", "size", "on-click", "variant"])) : re("", !0)
|
|
156
156
|
], 2))), 128))
|
|
157
157
|
], 2)
|
|
158
|
-
], 10,
|
|
158
|
+
], 10, de));
|
|
159
159
|
}
|
|
160
|
-
})
|
|
160
|
+
});
|
|
161
161
|
export {
|
|
162
|
-
|
|
162
|
+
ve as _
|
|
163
163
|
};
|