maz-ui 3.19.3 → 3.21.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/MazAvatar.mjs +1 -1
- package/components/MazBackdrop.mjs +1 -1
- package/components/MazBottomSheet.mjs +1 -1
- package/components/MazBtn.mjs +1 -1
- package/components/MazCard.mjs +1 -1
- package/components/MazCarousel.mjs +1 -1
- package/components/MazCheckbox.d.ts +22 -2
- package/components/MazCheckbox.mjs +146 -32
- package/components/MazDialog.mjs +1 -1
- package/components/MazDialogPromise.mjs +1 -1
- package/components/MazDrawer.mjs +1 -1
- package/components/MazDropdown.d.ts +98 -0
- package/components/MazDropdown.mjs +4 -0
- package/components/MazGallery.mjs +1 -1
- package/components/MazInput.mjs +1 -1
- package/components/MazInputNumber.mjs +4 -4
- package/components/MazInputPrice.mjs +1 -1
- package/components/MazInputTags.mjs +1 -1
- package/components/MazLazyImg.d.ts +9 -0
- package/components/MazLazyImg.mjs +1 -1
- package/components/MazPhoneNumberInput.mjs +1 -1
- package/components/MazPicker.mjs +1 -1
- package/components/MazRadioButtons.mjs +4 -4
- package/components/MazSelect.d.ts +12 -4
- package/components/MazSelect.mjs +1 -1
- package/components/MazSlider.mjs +86 -79
- package/components/MazStepper.mjs +1 -1
- package/components/MazSwitch.d.ts +11 -2
- package/components/MazSwitch.mjs +60 -43
- package/components/MazTabsBar.d.ts +0 -9
- package/components/MazTabsBar.mjs +1 -1
- package/components/MazTabsContent.mjs +6 -8
- package/components/MazTextarea.mjs +12 -14
- package/components/assets/MazAvatar.css +1 -1
- package/components/assets/MazBtn.css +1 -1
- package/components/assets/MazCheckbox.css +1 -1
- package/components/assets/MazDropdown.css +1 -0
- package/components/assets/MazInput.css +1 -1
- package/components/assets/MazInputPrice.css +1 -1
- package/components/assets/MazInputTags.css +1 -1
- package/components/assets/MazLazyImg.css +1 -1
- package/components/assets/MazPhoneNumberInput.css +1 -1
- package/components/assets/MazPicker.css +1 -1
- package/components/assets/MazPickerCalendar.css +1 -1
- package/components/assets/MazPickerMonthSwitcher.css +1 -1
- package/components/assets/MazPickerYearSwitcher.css +1 -1
- package/components/assets/MazRadioButtons.css +1 -1
- package/components/assets/MazSelect.css +1 -1
- package/components/assets/MazSlider.css +1 -1
- package/components/assets/MazSwitch.css +1 -1
- package/components/assets/MazTabsBar.css +1 -1
- package/components/assets/MazTextarea.css +1 -1
- package/components/chunks/{MazAvatar-a65c81e3.mjs → MazAvatar-358d78d4.mjs} +7 -8
- package/components/chunks/{MazBottomSheet-b78adb87.mjs → MazBottomSheet-c1efac29.mjs} +3 -3
- package/components/chunks/{MazBtn-54c47489.mjs → MazBtn-186afd07.mjs} +4 -4
- package/components/chunks/{MazBtn-57cb16a1.mjs → MazBtn-1c424138.mjs} +4 -4
- package/components/chunks/{MazBtn-5a37bfef.mjs → MazBtn-206ba68d.mjs} +4 -4
- package/components/chunks/{MazBtn-18894690.mjs → MazBtn-3d271413.mjs} +4 -4
- package/components/chunks/{MazBtn-21743551.mjs → MazBtn-48e48384.mjs} +4 -4
- package/components/chunks/{MazBtn-67e1fe7b.mjs → MazBtn-5479f92f.mjs} +4 -4
- package/components/chunks/{MazBtn-b29e3116.mjs → MazBtn-5b998d0d.mjs} +4 -4
- package/components/chunks/{MazBtn-9d312f09.mjs → MazBtn-5df90d56.mjs} +4 -4
- package/components/chunks/{MazBtn-2703c9bd.mjs → MazBtn-8a08e6a3.mjs} +2 -2
- package/components/chunks/{MazBtn-000f9f66.mjs → MazBtn-984e4c09.mjs} +3 -3
- package/components/chunks/{MazBtn-6e16fbca.mjs → MazBtn-9ec23564.mjs} +4 -4
- package/components/chunks/{MazBtn-16ab35fe.mjs → MazBtn-bdcb2265.mjs} +4 -4
- package/components/chunks/MazBtn-d5cb263a.mjs +184 -0
- package/components/chunks/{MazBtn-9333e80f.mjs → MazBtn-e9af467f.mjs} +4 -4
- package/components/chunks/{MazBtn-bf133cbc.mjs → MazBtn-ebb51888.mjs} +4 -4
- package/components/chunks/{MazCard-d9369776.mjs → MazCard-fdfd5207.mjs} +4 -4
- package/components/chunks/{MazCarousel-06ca7c0b.mjs → MazCarousel-ffac593b.mjs} +3 -3
- package/components/chunks/MazCheckbox-18c07284.mjs +146 -0
- package/components/chunks/MazCheckbox-560eaa6e.mjs +146 -0
- package/components/chunks/{MazDialog-d5f6a7d8.mjs → MazDialog-364b0186.mjs} +3 -3
- package/components/chunks/{MazDialogPromise-23cb2e40.mjs → MazDialogPromise-4b671901.mjs} +4 -4
- package/components/chunks/{MazDrawer-7d6428cf.mjs → MazDrawer-d34462e7.mjs} +3 -3
- package/components/chunks/MazDropdown-98d5f3fa.mjs +423 -0
- package/components/chunks/{MazGallery-c80e96f6.mjs → MazGallery-e269499b.mjs} +2 -2
- package/components/chunks/{MazIcon-81176bfa.mjs → MazIcon-fd04279a.mjs} +1 -1
- package/components/chunks/{MazInput-2a43e4a6.mjs → MazInput-3352e3bc.mjs} +40 -35
- package/components/chunks/{MazInput-8e284503.mjs → MazInput-3695525b.mjs} +44 -41
- package/components/chunks/{MazInput-129c8695.mjs → MazInput-36b810a7.mjs} +44 -41
- package/components/chunks/{MazInputPrice-e88dec74.mjs → MazInputPrice-4b976785.mjs} +44 -41
- package/components/chunks/{MazInputTags-872a6fae.mjs → MazInputTags-5dc51bf6.mjs} +46 -43
- package/components/chunks/{MazLazyImg-8d49fa48.mjs → MazLazyImg-6e395356.mjs} +12 -15
- package/components/chunks/{MazLazyImg-51c16f47.mjs → MazLazyImg-e0d8b6d0.mjs} +13 -16
- package/components/chunks/{MazPhoneNumberInput-e4f90230.mjs → MazPhoneNumberInput-35c89fc9.mjs} +177 -115
- package/components/chunks/{MazPicker-6fc29a1c.mjs → MazPicker-b8ad037a.mjs} +110 -91
- package/components/chunks/{MazPickerCalendar-6271c78d.mjs → MazPickerCalendar-c8214eb6.mjs} +16 -14
- package/components/chunks/{MazPickerHeader-4f70f191.mjs → MazPickerHeader-418be7ec.mjs} +1 -1
- package/components/chunks/{MazPickerMonthSwitcher-674ce015.mjs → MazPickerMonthSwitcher-ec0eafab.mjs} +5 -5
- package/components/chunks/{MazPickerShortcuts-2242854f.mjs → MazPickerShortcuts-fefb471d.mjs} +2 -2
- package/components/chunks/{MazPickerTime-bb97786b.mjs → MazPickerTime-e8e333e2.mjs} +2 -2
- package/components/chunks/{MazPickerYearSwitcher-47e5444b.mjs → MazPickerYearSwitcher-a72555c9.mjs} +6 -6
- package/components/chunks/{MazSelect-1f4d1193.mjs → MazSelect-ac1994af.mjs} +173 -112
- package/components/chunks/{MazSpinner-5368411e.mjs → MazSpinner-01bdbfa5.mjs} +1 -1
- package/components/chunks/MazSpinner-08a8029c.mjs +46 -0
- package/components/chunks/{MazSpinner-213b3866.mjs → MazSpinner-322f7316.mjs} +1 -1
- package/components/chunks/{MazSpinner-232086b5.mjs → MazSpinner-48a95578.mjs} +1 -1
- package/components/chunks/{MazSpinner-467d514f.mjs → MazSpinner-48f87ac2.mjs} +1 -1
- package/components/chunks/MazSpinner-50c53a1b.mjs +46 -0
- package/components/chunks/{MazSpinner-d6625983.mjs → MazSpinner-55ce68bb.mjs} +1 -1
- package/components/chunks/{MazSpinner-6c664898.mjs → MazSpinner-5e47d189.mjs} +1 -1
- package/components/chunks/MazSpinner-6a51c06a.mjs +46 -0
- package/components/chunks/{MazSpinner-984d259a.mjs → MazSpinner-8337bb5a.mjs} +1 -1
- package/components/chunks/{MazSpinner-bed2bced.mjs → MazSpinner-ab44d433.mjs} +1 -1
- package/components/chunks/{MazSpinner-2cbf1c0a.mjs → MazSpinner-c15f2e6b.mjs} +1 -1
- package/components/chunks/{MazSpinner-25ddb933.mjs → MazSpinner-c74532b1.mjs} +1 -1
- package/components/chunks/MazSpinner-ce4be8f1.mjs +46 -0
- package/components/chunks/{MazSpinner-2fac70be.mjs → MazSpinner-e1f88ad7.mjs} +1 -1
- package/components/chunks/MazSpinner-eea9056d.mjs +46 -0
- package/components/chunks/{MazSpinner-c9df761f.mjs → MazSpinner-f691123b.mjs} +1 -1
- package/components/chunks/{MazStepper-293b4be5.mjs → MazStepper-4c19dbfc.mjs} +4 -4
- package/components/chunks/{MazTabsBar-6dffbdde.mjs → MazTabsBar-aa8cccd4.mjs} +18 -12
- package/components/chunks/{MazTransitionExpand-648e21e0.mjs → MazTransitionExpand-e419ee71.mjs} +1 -1
- package/components/chunks/{MazTransitionExpand-f3018af6.mjs → MazTransitionExpand-f9e5a2d6.mjs} +1 -1
- package/components/chunks/check-8da249b1.mjs +32 -0
- package/components/chunks/{check-circle-403abf7e.mjs → check-circle-7acfa4c4.mjs} +1 -1
- package/components/chunks/{check-b1507ce9.mjs → check-f2fcce10.mjs} +1 -1
- package/components/chunks/{chevron-down-7a070b10.mjs → chevron-down-a78b9604.mjs} +1 -1
- package/{modules/chunks/chevron-left-7ab9664d.mjs → components/chunks/chevron-left-3365d59b.mjs} +1 -1
- package/components/chunks/{chevron-right-d300cd13.mjs → chevron-right-02f9e837.mjs} +1 -1
- package/components/chunks/debounce-7d66ffa9.mjs +12 -0
- package/components/chunks/{exclamation-circle-78184f31.mjs → exclamation-circle-2e115536.mjs} +1 -1
- package/components/chunks/{exclamation-triangle-7b00fa9b.mjs → exclamation-triangle-10eb48dc.mjs} +1 -1
- package/components/chunks/{eye-290c6a03.mjs → eye-fbb13657.mjs} +1 -1
- package/components/chunks/{eye-slash-3c6844fc.mjs → eye-slash-342420ff.mjs} +1 -1
- package/components/chunks/{magnifying-glass-6a0dd1a2.mjs → magnifying-glass-5dffa35e.mjs} +1 -1
- package/components/chunks/{minus-a1cc422e.mjs → minus-c9cdee90.mjs} +1 -1
- package/components/chunks/{no-photography-bc9a1f6a.mjs → no-photography-b0d08d6f.mjs} +1 -1
- package/components/chunks/{no-symbol-6173a20b.mjs → no-symbol-975ce547.mjs} +1 -1
- package/components/chunks/{pencil-6f15596d.mjs → pencil-2f766dc8.mjs} +1 -1
- package/components/chunks/{plus-9ca3cdd9.mjs → plus-b1b0a5a8.mjs} +1 -1
- package/components/chunks/{x-mark-af0cf423.mjs → x-mark-3b05101b.mjs} +1 -1
- package/{modules/chunks/x-mark-6dd31278.mjs → components/chunks/x-mark-c6ff45dd.mjs} +1 -1
- package/components/index.d.ts +1 -0
- package/components/index.mjs +1 -0
- package/css/main.css +1 -1
- package/modules/assets/MazBtn.css +1 -1
- package/modules/assets/index.css +1 -1
- package/modules/chunks/{MazBtn-f4c8698d.mjs → MazBtn-df596002.mjs} +5 -5
- package/modules/chunks/{MazIcon-2c79b9d8.mjs → MazIcon-ad447370.mjs} +1 -1
- package/modules/chunks/{MazSpinner-331f6dc8.mjs → MazSpinner-afef5357.mjs} +1 -1
- package/modules/chunks/{arrow-top-right-on-square-3878577d.mjs → arrow-top-right-on-square-32bbe5a1.mjs} +1 -1
- package/{components/chunks/chevron-left-7ab9664d.mjs → modules/chunks/chevron-left-3365d59b.mjs} +1 -1
- package/modules/chunks/{index-1c3e48da.mjs → index-9a112dd8.mjs} +15 -17
- package/modules/chunks/{link-74f1af7a.mjs → link-4eb05848.mjs} +1 -1
- package/{components/chunks/x-mark-6dd31278.mjs → modules/chunks/x-mark-c6ff45dd.mjs} +1 -1
- package/modules/index.mjs +1 -1
- package/nuxt/index.json +1 -1
- package/package.json +13 -13
- package/tailwindcss/tailwind.config.ts +1 -1
- package/types/components/MazCheckbox.vue.d.ts +22 -2
- package/types/components/MazDropdown.vue.d.ts +98 -0
- package/types/components/MazLazyImg.vue.d.ts +9 -0
- package/types/components/MazSelect.vue.d.ts +12 -4
- package/types/components/MazSwitch.vue.d.ts +11 -2
- package/types/components/MazTabsBar.vue.d.ts +0 -9
- package/types/components/index.d.ts +1 -0
- package/types/modules/helpers/debounce.d.ts +1 -1
- package/components/chunks/MazBtn-a776eb42.mjs +0 -184
- package/components/chunks/MazSpinner-47025e56.mjs +0 -46
- package/components/chunks/MazSpinner-5fdafc97.mjs +0 -46
- package/components/chunks/MazSpinner-819a5b00.mjs +0 -46
- package/components/chunks/MazSpinner-a74389bd.mjs +0 -46
- package/components/chunks/debounce-b08199da.mjs +0 -14
package/components/MazAvatar.mjs
CHANGED
package/components/MazBtn.mjs
CHANGED
package/components/MazCard.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { type PropType } from 'vue';
|
|
2
|
-
import type { Color } from './types';
|
|
3
|
-
export type { Color };
|
|
2
|
+
import type { Color, Size } from './types';
|
|
3
|
+
export type { Color, Size };
|
|
4
4
|
declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
5
5
|
modelValue: {
|
|
6
6
|
type: BooleanConstructor;
|
|
@@ -18,7 +18,16 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
18
18
|
type: StringConstructor;
|
|
19
19
|
default: string;
|
|
20
20
|
};
|
|
21
|
+
size: {
|
|
22
|
+
type: PropType<Size>;
|
|
23
|
+
default: string;
|
|
24
|
+
};
|
|
25
|
+
disabled: {
|
|
26
|
+
type: BooleanConstructor;
|
|
27
|
+
default: boolean;
|
|
28
|
+
};
|
|
21
29
|
}, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
30
|
+
change: (...args: any[]) => void;
|
|
22
31
|
"update:model-value": (...args: any[]) => void;
|
|
23
32
|
}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
24
33
|
modelValue: {
|
|
@@ -37,10 +46,21 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
37
46
|
type: StringConstructor;
|
|
38
47
|
default: string;
|
|
39
48
|
};
|
|
49
|
+
size: {
|
|
50
|
+
type: PropType<Size>;
|
|
51
|
+
default: string;
|
|
52
|
+
};
|
|
53
|
+
disabled: {
|
|
54
|
+
type: BooleanConstructor;
|
|
55
|
+
default: boolean;
|
|
56
|
+
};
|
|
40
57
|
}>> & {
|
|
58
|
+
onChange?: ((...args: any[]) => any) | undefined;
|
|
41
59
|
"onUpdate:model-value"?: ((...args: any[]) => any) | undefined;
|
|
42
60
|
}, {
|
|
61
|
+
size: Size;
|
|
43
62
|
color: Color;
|
|
63
|
+
disabled: boolean;
|
|
44
64
|
name: string;
|
|
45
65
|
id: string;
|
|
46
66
|
}, {}>, {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import "./assets/MazCheckbox.css";
|
|
2
|
-
import { computed, defineComponent,
|
|
2
|
+
import { computed, openBlock, createElementBlock, createElementVNode, defineComponent, useCssVars, getCurrentInstance, unref, normalizeClass, mergeProps, createVNode, Transition, withCtx, withDirectives, vShow, renderSlot } from "vue";
|
|
3
3
|
const useInstanceUniqId = ({
|
|
4
4
|
componentName,
|
|
5
5
|
instance,
|
|
@@ -7,8 +7,35 @@ const useInstanceUniqId = ({
|
|
|
7
7
|
}) => {
|
|
8
8
|
return computed(() => providedId ?? `${componentName}-${instance == null ? void 0 : instance.uid}`);
|
|
9
9
|
};
|
|
10
|
-
const _hoisted_1 =
|
|
11
|
-
|
|
10
|
+
const _hoisted_1$1 = {
|
|
11
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
12
|
+
width: "1em",
|
|
13
|
+
height: "1em",
|
|
14
|
+
fill: "none",
|
|
15
|
+
viewBox: "0 0 24 24"
|
|
16
|
+
};
|
|
17
|
+
const _hoisted_2$1 = /* @__PURE__ */ createElementVNode(
|
|
18
|
+
"path",
|
|
19
|
+
{
|
|
20
|
+
stroke: "currentColor",
|
|
21
|
+
"stroke-linecap": "round",
|
|
22
|
+
"stroke-linejoin": "round",
|
|
23
|
+
"stroke-width": "1.5",
|
|
24
|
+
d: "m4.5 12.75 6 6 9-13.5"
|
|
25
|
+
},
|
|
26
|
+
null,
|
|
27
|
+
-1
|
|
28
|
+
/* HOISTED */
|
|
29
|
+
);
|
|
30
|
+
const _hoisted_3 = [
|
|
31
|
+
_hoisted_2$1
|
|
32
|
+
];
|
|
33
|
+
function render(_ctx, _cache) {
|
|
34
|
+
return openBlock(), createElementBlock("svg", _hoisted_1$1, [..._hoisted_3]);
|
|
35
|
+
}
|
|
36
|
+
const CheckIcon = { render };
|
|
37
|
+
const _hoisted_1 = ["for", "aria-checked"];
|
|
38
|
+
const _hoisted_2 = ["id", "checked", "disabled", "name"];
|
|
12
39
|
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
13
40
|
__name: "MazCheckbox",
|
|
14
41
|
props: {
|
|
@@ -18,46 +45,133 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
18
45
|
type: String,
|
|
19
46
|
default: "primary"
|
|
20
47
|
},
|
|
21
|
-
name: { type: String, default: "m-checkbox" }
|
|
48
|
+
name: { type: String, default: "m-checkbox" },
|
|
49
|
+
size: { type: String, default: "md" },
|
|
50
|
+
disabled: { type: Boolean, default: false }
|
|
22
51
|
},
|
|
23
|
-
emits: [
|
|
24
|
-
|
|
52
|
+
emits: [
|
|
53
|
+
/* emitted when value change */
|
|
54
|
+
"update:model-value",
|
|
55
|
+
/* emited when value change */
|
|
56
|
+
"change"
|
|
57
|
+
],
|
|
58
|
+
setup(__props, { emit: __emit }) {
|
|
59
|
+
useCssVars((_ctx) => ({
|
|
60
|
+
"2887ae19": checkIconColor.value,
|
|
61
|
+
"3ea743fb": checkboxSize.value,
|
|
62
|
+
"8729aa64": checkboxSelectedColor.value,
|
|
63
|
+
"324bb1de": checkboxBoxShadow.value
|
|
64
|
+
}));
|
|
25
65
|
const instance = getCurrentInstance();
|
|
26
66
|
const props = __props;
|
|
67
|
+
const emits = __emit;
|
|
27
68
|
const instanceId = useInstanceUniqId({
|
|
28
69
|
componentName: "MazCheckbox",
|
|
29
70
|
instance,
|
|
30
71
|
providedId: props.id
|
|
31
72
|
});
|
|
73
|
+
const checkboxSize = computed(() => {
|
|
74
|
+
switch (props.size) {
|
|
75
|
+
case "xl": {
|
|
76
|
+
return "2.25rem";
|
|
77
|
+
}
|
|
78
|
+
case "lg": {
|
|
79
|
+
return "2rem";
|
|
80
|
+
}
|
|
81
|
+
default: {
|
|
82
|
+
return "1.625rem";
|
|
83
|
+
}
|
|
84
|
+
case "sm": {
|
|
85
|
+
return "1.425rem";
|
|
86
|
+
}
|
|
87
|
+
case "xs": {
|
|
88
|
+
return "1.325rem";
|
|
89
|
+
}
|
|
90
|
+
case "mini": {
|
|
91
|
+
return "1.2rem";
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
});
|
|
95
|
+
const checkIconSize = computed(() => {
|
|
96
|
+
switch (props.size) {
|
|
97
|
+
case "xl": {
|
|
98
|
+
return "maz-text-2xl";
|
|
99
|
+
}
|
|
100
|
+
case "lg": {
|
|
101
|
+
return "maz-text-xl";
|
|
102
|
+
}
|
|
103
|
+
default: {
|
|
104
|
+
return "maz-text-lg";
|
|
105
|
+
}
|
|
106
|
+
case "sm": {
|
|
107
|
+
return "maz-text-base";
|
|
108
|
+
}
|
|
109
|
+
case "xs": {
|
|
110
|
+
return "maz-text-sm";
|
|
111
|
+
}
|
|
112
|
+
case "mini": {
|
|
113
|
+
return "maz-text-xs";
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
});
|
|
117
|
+
const checkIconColor = computed(() => `var(--maz-color-${props.color}-contrast)`);
|
|
118
|
+
const checkboxSelectedColor = computed(() => `var(--maz-color-${props.color})`);
|
|
119
|
+
const checkboxBoxShadow = computed(
|
|
120
|
+
() => ["black", "transparent"].includes(props.color) ? `var(--maz-color-muted)` : `var(--maz-color-${props.color}-alpha)`
|
|
121
|
+
);
|
|
122
|
+
function keyboardHandler(event) {
|
|
123
|
+
if (["Enter", "Space"].includes(event.code)) {
|
|
124
|
+
event.preventDefault();
|
|
125
|
+
emitValue(!props.modelValue);
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
function emitValue(value) {
|
|
129
|
+
emits("update:model-value", value);
|
|
130
|
+
emits("change", value);
|
|
131
|
+
}
|
|
32
132
|
return (_ctx, _cache) => {
|
|
33
|
-
return openBlock(), createElementBlock(
|
|
34
|
-
|
|
35
|
-
{
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
133
|
+
return openBlock(), createElementBlock("label", {
|
|
134
|
+
for: unref(instanceId),
|
|
135
|
+
class: normalizeClass(["m-checkbox", { "--disabled": __props.disabled }]),
|
|
136
|
+
tabindex: "0",
|
|
137
|
+
role: "checkbox",
|
|
138
|
+
"aria-checked": __props.modelValue,
|
|
139
|
+
onKeydown: keyboardHandler
|
|
140
|
+
}, [
|
|
141
|
+
createElementVNode("input", mergeProps({
|
|
142
|
+
id: unref(instanceId),
|
|
143
|
+
checked: __props.modelValue
|
|
144
|
+
}, _ctx.$attrs, {
|
|
145
|
+
disabled: __props.disabled,
|
|
146
|
+
name: __props.name,
|
|
147
|
+
type: "checkbox",
|
|
148
|
+
onChange: _cache[0] || (_cache[0] = ($event) => {
|
|
149
|
+
var _a;
|
|
150
|
+
return emitValue((_a = $event == null ? void 0 : $event.target) == null ? void 0 : _a.checked);
|
|
151
|
+
})
|
|
152
|
+
}), null, 16, _hoisted_2),
|
|
153
|
+
createElementVNode("span", null, [
|
|
154
|
+
createVNode(Transition, {
|
|
155
|
+
name: "maz-scale",
|
|
156
|
+
persisted: ""
|
|
157
|
+
}, {
|
|
158
|
+
default: withCtx(() => [
|
|
159
|
+
withDirectives(createVNode(unref(CheckIcon), {
|
|
160
|
+
class: normalizeClass(["check-icon", checkIconSize.value])
|
|
161
|
+
}, null, 8, ["class"]), [
|
|
162
|
+
[vShow, __props.modelValue]
|
|
163
|
+
])
|
|
164
|
+
]),
|
|
165
|
+
_: 1
|
|
166
|
+
/* STABLE */
|
|
167
|
+
})
|
|
168
|
+
]),
|
|
169
|
+
renderSlot(_ctx.$slots, "default", {}, void 0, true)
|
|
170
|
+
], 42, _hoisted_1);
|
|
57
171
|
};
|
|
58
172
|
}
|
|
59
173
|
});
|
|
60
|
-
const
|
|
174
|
+
const MazCheckbox_vue_vue_type_style_index_0_scoped_e6c359ea_lang = "";
|
|
61
175
|
const _export_sfc = (sfc, props) => {
|
|
62
176
|
const target = sfc.__vccOpts || sfc;
|
|
63
177
|
for (const [key, val] of props) {
|
|
@@ -65,7 +179,7 @@ const _export_sfc = (sfc, props) => {
|
|
|
65
179
|
}
|
|
66
180
|
return target;
|
|
67
181
|
};
|
|
68
|
-
const MazCheckbox = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-
|
|
182
|
+
const MazCheckbox = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-e6c359ea"]]);
|
|
69
183
|
export {
|
|
70
184
|
MazCheckbox as default
|
|
71
185
|
};
|
package/components/MazDialog.mjs
CHANGED
package/components/MazDrawer.mjs
CHANGED
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
import { type Color } from './MazBtn.vue';
|
|
2
|
+
import { type RouteLocationRaw } from 'vue-router';
|
|
3
|
+
import { type Position } from './types';
|
|
4
|
+
export type { Color, Position };
|
|
5
|
+
export type MenuItem = {
|
|
6
|
+
label: string;
|
|
7
|
+
action?: () => unknown;
|
|
8
|
+
target?: string;
|
|
9
|
+
href?: string;
|
|
10
|
+
to?: RouteLocationRaw;
|
|
11
|
+
} & Record<string, unknown>;
|
|
12
|
+
declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
|
|
13
|
+
/** Menu items */
|
|
14
|
+
items: MenuItem[];
|
|
15
|
+
/** Menu should be open? */
|
|
16
|
+
open?: boolean | undefined;
|
|
17
|
+
/** id of the menu */
|
|
18
|
+
id?: string | undefined;
|
|
19
|
+
/** Should open the dropdown on click, hover or both */
|
|
20
|
+
trigger?: "click" | "hover" | "both" | undefined;
|
|
21
|
+
/** Button color */
|
|
22
|
+
color?: Color | undefined;
|
|
23
|
+
/** Position of the dropdown */
|
|
24
|
+
position?: Position | undefined;
|
|
25
|
+
/** Disable close menu on menuitem clicked */
|
|
26
|
+
noCloseOnClick?: boolean | undefined;
|
|
27
|
+
/** Disable menu */
|
|
28
|
+
disabled?: boolean | undefined;
|
|
29
|
+
}>, {
|
|
30
|
+
id: string;
|
|
31
|
+
trigger: string;
|
|
32
|
+
color: string;
|
|
33
|
+
position: string;
|
|
34
|
+
}>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
35
|
+
"menuitem-clicked": (...args: any[]) => void;
|
|
36
|
+
"update:open": (...args: any[]) => void;
|
|
37
|
+
}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
|
|
38
|
+
/** Menu items */
|
|
39
|
+
items: MenuItem[];
|
|
40
|
+
/** Menu should be open? */
|
|
41
|
+
open?: boolean | undefined;
|
|
42
|
+
/** id of the menu */
|
|
43
|
+
id?: string | undefined;
|
|
44
|
+
/** Should open the dropdown on click, hover or both */
|
|
45
|
+
trigger?: "click" | "hover" | "both" | undefined;
|
|
46
|
+
/** Button color */
|
|
47
|
+
color?: Color | undefined;
|
|
48
|
+
/** Position of the dropdown */
|
|
49
|
+
position?: Position | undefined;
|
|
50
|
+
/** Disable close menu on menuitem clicked */
|
|
51
|
+
noCloseOnClick?: boolean | undefined;
|
|
52
|
+
/** Disable menu */
|
|
53
|
+
disabled?: boolean | undefined;
|
|
54
|
+
}>, {
|
|
55
|
+
id: string;
|
|
56
|
+
trigger: string;
|
|
57
|
+
color: string;
|
|
58
|
+
position: string;
|
|
59
|
+
}>>> & {
|
|
60
|
+
"onMenuitem-clicked"?: ((...args: any[]) => any) | undefined;
|
|
61
|
+
"onUpdate:open"?: ((...args: any[]) => any) | undefined;
|
|
62
|
+
}, {
|
|
63
|
+
color: Color;
|
|
64
|
+
id: string;
|
|
65
|
+
position: Position;
|
|
66
|
+
trigger: "click" | "hover" | "both";
|
|
67
|
+
}, {}>, {
|
|
68
|
+
default?(_: {}): any;
|
|
69
|
+
menuitem?(_: {
|
|
70
|
+
item: MenuItem;
|
|
71
|
+
}): any;
|
|
72
|
+
"menuitem-label"?(_: {
|
|
73
|
+
item: MenuItem;
|
|
74
|
+
}): any;
|
|
75
|
+
}>;
|
|
76
|
+
export default _default;
|
|
77
|
+
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
78
|
+
type __VLS_TypePropsToRuntimeProps<T> = {
|
|
79
|
+
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
80
|
+
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
81
|
+
} : {
|
|
82
|
+
type: import('vue').PropType<T[K]>;
|
|
83
|
+
required: true;
|
|
84
|
+
};
|
|
85
|
+
};
|
|
86
|
+
type __VLS_WithDefaults<P, D> = {
|
|
87
|
+
[K in keyof Pick<P, keyof P>]: K extends keyof D ? __VLS_Prettify<P[K] & {
|
|
88
|
+
default: D[K];
|
|
89
|
+
}> : P[K];
|
|
90
|
+
};
|
|
91
|
+
type __VLS_Prettify<T> = {
|
|
92
|
+
[K in keyof T]: T[K];
|
|
93
|
+
} & {};
|
|
94
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
95
|
+
new (): {
|
|
96
|
+
$slots: S;
|
|
97
|
+
};
|
|
98
|
+
};
|
|
@@ -669,7 +669,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
669
669
|
scale: { type: Boolean, default: true }
|
|
670
670
|
},
|
|
671
671
|
setup(__props) {
|
|
672
|
-
const NoPhotographyIcon = defineAsyncComponent(() => import("./chunks/no-photography-
|
|
672
|
+
const NoPhotographyIcon = defineAsyncComponent(() => import("./chunks/no-photography-b0d08d6f.mjs"));
|
|
673
673
|
const props = __props;
|
|
674
674
|
onBeforeMount(() => {
|
|
675
675
|
if (props.imagesShownCount > 5)
|
package/components/MazInput.mjs
CHANGED
|
@@ -18,10 +18,10 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
18
18
|
},
|
|
19
19
|
emits: ["update:model-value"],
|
|
20
20
|
setup(__props, { emit: __emit }) {
|
|
21
|
-
const MazBtn = defineAsyncComponent(() => import("./chunks/MazBtn-
|
|
22
|
-
const MazInput = defineAsyncComponent(() => import("./chunks/MazInput-
|
|
23
|
-
const PlusIcon = defineAsyncComponent(() => import("./chunks/plus-
|
|
24
|
-
const MinusIcon = defineAsyncComponent(() => import("./chunks/minus-
|
|
21
|
+
const MazBtn = defineAsyncComponent(() => import("./chunks/MazBtn-8a08e6a3.mjs"));
|
|
22
|
+
const MazInput = defineAsyncComponent(() => import("./chunks/MazInput-36b810a7.mjs"));
|
|
23
|
+
const PlusIcon = defineAsyncComponent(() => import("./chunks/plus-b1b0a5a8.mjs"));
|
|
24
|
+
const MinusIcon = defineAsyncComponent(() => import("./chunks/minus-c9cdee90.mjs"));
|
|
25
25
|
const props = __props;
|
|
26
26
|
const emits = __emit;
|
|
27
27
|
const currentValue = computed({
|
|
@@ -3,6 +3,10 @@ import type { Image } from './types';
|
|
|
3
3
|
export type { Image };
|
|
4
4
|
declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
5
5
|
image: Prop<Image>;
|
|
6
|
+
alt: {
|
|
7
|
+
type: StringConstructor;
|
|
8
|
+
default: undefined;
|
|
9
|
+
};
|
|
6
10
|
noPhoto: {
|
|
7
11
|
type: BooleanConstructor;
|
|
8
12
|
default: boolean;
|
|
@@ -35,6 +39,10 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
35
39
|
intersecting: (...args: any[]) => void;
|
|
36
40
|
}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
37
41
|
image: Prop<Image>;
|
|
42
|
+
alt: {
|
|
43
|
+
type: StringConstructor;
|
|
44
|
+
default: undefined;
|
|
45
|
+
};
|
|
38
46
|
noPhoto: {
|
|
39
47
|
type: BooleanConstructor;
|
|
40
48
|
default: boolean;
|
|
@@ -66,6 +74,7 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
66
74
|
onLoading?: ((...args: any[]) => any) | undefined;
|
|
67
75
|
onIntersecting?: ((...args: any[]) => any) | undefined;
|
|
68
76
|
}, {
|
|
77
|
+
alt: string;
|
|
69
78
|
noPhoto: boolean;
|
|
70
79
|
loadOnce: boolean;
|
|
71
80
|
noLoader: boolean;
|
package/components/MazPicker.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import "./assets/MazRadioButtons.css";
|
|
2
2
|
import { defineComponent, openBlock, createElementBlock, normalizeClass, Fragment, renderList, normalizeStyle, createElementVNode, renderSlot, createTextVNode, toDisplayString } from "vue";
|
|
3
|
-
const _hoisted_1 = ["
|
|
3
|
+
const _hoisted_1 = ["for"];
|
|
4
4
|
const _hoisted_2 = ["id", "name", "value", "onChange"];
|
|
5
5
|
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
6
6
|
__name: "MazRadioButtons",
|
|
@@ -40,8 +40,8 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
40
40
|
null,
|
|
41
41
|
renderList(__props.options, (option, i) => {
|
|
42
42
|
return openBlock(), createElementBlock("label", {
|
|
43
|
-
id: option.value.toString(),
|
|
44
43
|
key: i,
|
|
44
|
+
for: option.value.toString(),
|
|
45
45
|
class: normalizeClass(["m-radio-buttons__items", {
|
|
46
46
|
"--is-selected": isSelected(option.value),
|
|
47
47
|
"maz-elevation": !__props.noElevation
|
|
@@ -83,7 +83,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
83
83
|
};
|
|
84
84
|
}
|
|
85
85
|
});
|
|
86
|
-
const
|
|
86
|
+
const MazRadioButtons_vue_vue_type_style_index_0_scoped_f0f8688b_lang = "";
|
|
87
87
|
const _export_sfc = (sfc, props) => {
|
|
88
88
|
const target = sfc.__vccOpts || sfc;
|
|
89
89
|
for (const [key, val] of props) {
|
|
@@ -91,7 +91,7 @@ const _export_sfc = (sfc, props) => {
|
|
|
91
91
|
}
|
|
92
92
|
return target;
|
|
93
93
|
};
|
|
94
|
-
const MazRadioButtons = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-
|
|
94
|
+
const MazRadioButtons = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-f0f8688b"]]);
|
|
95
95
|
export {
|
|
96
96
|
MazRadioButtons as default
|
|
97
97
|
};
|
|
@@ -4,7 +4,7 @@ export type MazSelectOption = Record<string, ModelValueSimple>;
|
|
|
4
4
|
export type { Color, Size, ModelValueSimple, Position };
|
|
5
5
|
declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
6
6
|
modelValue: {
|
|
7
|
-
type: PropType<ModelValueSimple>;
|
|
7
|
+
type: PropType<ModelValueSimple | ModelValueSimple[]>;
|
|
8
8
|
default: undefined;
|
|
9
9
|
};
|
|
10
10
|
id: {
|
|
@@ -73,6 +73,10 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
73
73
|
type: StringConstructor;
|
|
74
74
|
default: string;
|
|
75
75
|
};
|
|
76
|
+
multiple: {
|
|
77
|
+
type: BooleanConstructor;
|
|
78
|
+
default: boolean;
|
|
79
|
+
};
|
|
76
80
|
}, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
77
81
|
close: (...args: any[]) => void;
|
|
78
82
|
blur: (...args: any[]) => void;
|
|
@@ -83,7 +87,7 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
83
87
|
"selected-option": (...args: any[]) => void;
|
|
84
88
|
}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
85
89
|
modelValue: {
|
|
86
|
-
type: PropType<ModelValueSimple>;
|
|
90
|
+
type: PropType<ModelValueSimple | ModelValueSimple[]>;
|
|
87
91
|
default: undefined;
|
|
88
92
|
};
|
|
89
93
|
id: {
|
|
@@ -152,6 +156,10 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
152
156
|
type: StringConstructor;
|
|
153
157
|
default: string;
|
|
154
158
|
};
|
|
159
|
+
multiple: {
|
|
160
|
+
type: BooleanConstructor;
|
|
161
|
+
default: boolean;
|
|
162
|
+
};
|
|
155
163
|
}>> & {
|
|
156
164
|
onFocus?: ((...args: any[]) => any) | undefined;
|
|
157
165
|
onBlur?: ((...args: any[]) => any) | undefined;
|
|
@@ -165,10 +173,11 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
165
173
|
color: Color;
|
|
166
174
|
search: boolean;
|
|
167
175
|
disabled: boolean;
|
|
176
|
+
multiple: boolean;
|
|
168
177
|
required: boolean;
|
|
169
178
|
id: string;
|
|
170
179
|
open: boolean;
|
|
171
|
-
modelValue: ModelValueSimple;
|
|
180
|
+
modelValue: ModelValueSimple | ModelValueSimple[];
|
|
172
181
|
options: MazSelectOption[];
|
|
173
182
|
optionValueKey: string;
|
|
174
183
|
optionLabelKey: string;
|
|
@@ -183,7 +192,6 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
183
192
|
default?(_: {
|
|
184
193
|
option: MazSelectOption;
|
|
185
194
|
isSelected: boolean;
|
|
186
|
-
selectedOption: ModelValueSimple;
|
|
187
195
|
}): any;
|
|
188
196
|
}>;
|
|
189
197
|
export default _default;
|
package/components/MazSelect.mjs
CHANGED