cisse-vue-ui 0.5.30 → 0.5.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/{DarkModeToggle.vue_vue_type_script_setup_true_lang-BBIkEeLJ.js → DarkModeToggle.vue_vue_type_script_setup_true_lang-0K4ucPlO.js} +2 -2
- package/dist/{DarkModeToggle.vue_vue_type_script_setup_true_lang-BBIkEeLJ.js.map → DarkModeToggle.vue_vue_type_script_setup_true_lang-0K4ucPlO.js.map} +1 -1
- package/dist/{DarkModeToggle.vue_vue_type_script_setup_true_lang-BHabkuFp.cjs → DarkModeToggle.vue_vue_type_script_setup_true_lang-DOrIWBcH.cjs} +2 -2
- package/dist/{DarkModeToggle.vue_vue_type_script_setup_true_lang-BHabkuFp.cjs.map → DarkModeToggle.vue_vue_type_script_setup_true_lang-DOrIWBcH.cjs.map} +1 -1
- package/dist/{Combobox.vue_vue_type_script_setup_true_lang-Dlza3xUG.js → IconPicker.vue_vue_type_script_setup_true_lang-Ch1x6Ap9.js} +474 -180
- package/dist/IconPicker.vue_vue_type_script_setup_true_lang-Ch1x6Ap9.js.map +1 -0
- package/dist/{Combobox.vue_vue_type_script_setup_true_lang-C2z3wwmX.cjs → IconPicker.vue_vue_type_script_setup_true_lang-agY_E72J.cjs} +474 -180
- package/dist/IconPicker.vue_vue_type_script_setup_true_lang-agY_E72J.cjs.map +1 -0
- package/dist/{PageLayout.vue_vue_type_script_setup_true_lang-6Hqk04te.cjs → PageLayout.vue_vue_type_script_setup_true_lang-DTVojbLU.cjs} +15 -3
- package/dist/PageLayout.vue_vue_type_script_setup_true_lang-DTVojbLU.cjs.map +1 -0
- package/dist/{PageLayout.vue_vue_type_script_setup_true_lang-C1zrOWOi.js → PageLayout.vue_vue_type_script_setup_true_lang-DcSTegL0.js} +16 -4
- package/dist/PageLayout.vue_vue_type_script_setup_true_lang-DcSTegL0.js.map +1 -0
- package/dist/components/core/index.cjs +1 -1
- package/dist/components/core/index.js +1 -1
- package/dist/components/form/IconPicker.vue.d.ts +33 -0
- package/dist/components/form/index.cjs +17 -16
- package/dist/components/form/index.cjs.map +1 -1
- package/dist/components/form/index.d.ts +1 -0
- package/dist/components/form/index.js +3 -2
- package/dist/components/index.cjs +19 -18
- package/dist/components/index.cjs.map +1 -1
- package/dist/components/index.js +5 -4
- package/dist/components/layout/BaseLayout.vue.d.ts +5 -1
- package/dist/components/layout/index.cjs +1 -1
- package/dist/components/layout/index.js +1 -1
- package/dist/{index-CJwlO351.js → index-BaWpldIJ.js} +58 -3
- package/dist/{index-CJwlO351.js.map → index-BaWpldIJ.js.map} +1 -1
- package/dist/{index-ChV8B_ZB.cjs → index-ChwvHG2L.cjs} +20 -19
- package/dist/index-ChwvHG2L.cjs.map +1 -0
- package/dist/{index-CUNU12xk.cjs → index-D1x3TH9k.cjs} +56 -1
- package/dist/{index-CUNU12xk.cjs.map → index-D1x3TH9k.cjs.map} +1 -1
- package/dist/index-DaA7OpRC.js +76 -0
- package/dist/index-DaA7OpRC.js.map +1 -0
- package/dist/index.cjs +20 -19
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +6 -5
- package/dist/style.css +1 -1
- package/dist/types/components.d.ts +1 -0
- package/package.json +1 -1
- package/dist/Combobox.vue_vue_type_script_setup_true_lang-C2z3wwmX.cjs.map +0 -1
- package/dist/Combobox.vue_vue_type_script_setup_true_lang-Dlza3xUG.js.map +0 -1
- package/dist/PageLayout.vue_vue_type_script_setup_true_lang-6Hqk04te.cjs.map +0 -1
- package/dist/PageLayout.vue_vue_type_script_setup_true_lang-C1zrOWOi.js.map +0 -1
- package/dist/index-CFtit7xh.js +0 -75
- package/dist/index-CFtit7xh.js.map +0 -1
- package/dist/index-ChV8B_ZB.cjs.map +0 -1
|
@@ -4,9 +4,9 @@ const useId = require("./useId-nxrBaIC9.cjs");
|
|
|
4
4
|
const vue$1 = require("@iconify/vue");
|
|
5
5
|
const useDropdown = require("./useDropdown-DHFnd259.cjs");
|
|
6
6
|
const _pluginVue_exportHelper = require("./_plugin-vue_export-helper-DM9IkUGy.cjs");
|
|
7
|
-
const index = require("./index-
|
|
8
|
-
const _hoisted_1$
|
|
9
|
-
const _sfc_main$
|
|
7
|
+
const index = require("./index-D1x3TH9k.cjs");
|
|
8
|
+
const _hoisted_1$e = ["data-error", "for"];
|
|
9
|
+
const _sfc_main$e = /* @__PURE__ */ vue.defineComponent({
|
|
10
10
|
__name: "FormLabel",
|
|
11
11
|
props: {
|
|
12
12
|
error: { type: [String, Boolean] },
|
|
@@ -20,12 +20,12 @@ const _sfc_main$d = /* @__PURE__ */ vue.defineComponent({
|
|
|
20
20
|
class: "block text-sm font-medium text-gray-700 data-[error=true]:text-red-500 dark:text-gray-300"
|
|
21
21
|
}, [
|
|
22
22
|
vue.renderSlot(_ctx.$slots, "default")
|
|
23
|
-
], 8, _hoisted_1$
|
|
23
|
+
], 8, _hoisted_1$e);
|
|
24
24
|
};
|
|
25
25
|
}
|
|
26
26
|
});
|
|
27
|
-
const _hoisted_1$
|
|
28
|
-
const _sfc_main$
|
|
27
|
+
const _hoisted_1$d = ["id", "data-error", "role", "aria-live"];
|
|
28
|
+
const _sfc_main$d = /* @__PURE__ */ vue.defineComponent({
|
|
29
29
|
__name: "FormHelp",
|
|
30
30
|
props: {
|
|
31
31
|
id: {},
|
|
@@ -44,12 +44,12 @@ const _sfc_main$c = /* @__PURE__ */ vue.defineComponent({
|
|
|
44
44
|
vue.renderSlot(_ctx.$slots, "default", {}, () => [
|
|
45
45
|
vue.createTextVNode(vue.toDisplayString(__props.text ?? ""), 1)
|
|
46
46
|
])
|
|
47
|
-
], 8, _hoisted_1$
|
|
47
|
+
], 8, _hoisted_1$d);
|
|
48
48
|
};
|
|
49
49
|
}
|
|
50
50
|
});
|
|
51
|
-
const _hoisted_1$
|
|
52
|
-
const _sfc_main$
|
|
51
|
+
const _hoisted_1$c = ["id", "disabled", "name", "placeholder", "type", "required", "aria-invalid", "aria-required", "aria-describedby"];
|
|
52
|
+
const _sfc_main$c = /* @__PURE__ */ vue.defineComponent({
|
|
53
53
|
__name: "FormInput",
|
|
54
54
|
props: /* @__PURE__ */ vue.mergeModels({
|
|
55
55
|
type: { default: "text" },
|
|
@@ -82,35 +82,35 @@ const _sfc_main$b = /* @__PURE__ */ vue.defineComponent({
|
|
|
82
82
|
"aria-required": props.required || void 0,
|
|
83
83
|
"aria-describedby": props.describedBy || void 0,
|
|
84
84
|
class: "mt-1 block w-full rounded-md border border-gray-300 bg-white px-3 py-2 text-sm text-gray-800 placeholder-gray-400 shadow-sm user-invalid:border-red-500 user-invalid:text-red-600 focus:border-primary focus:ring-1 focus:ring-primary focus:outline-hidden focus:user-invalid:border-red-500 focus:user-invalid:ring-red-500 disabled:border-gray-200 disabled:bg-gray-50 disabled:text-gray-500 disabled:shadow-none dark:border-gray-700 dark:bg-gray-900 dark:text-gray-200 dark:placeholder-gray-500 dark:focus:border-primary dark:focus:ring-primary dark:disabled:border-gray-800 dark:disabled:bg-gray-950 dark:disabled:text-gray-500"
|
|
85
|
-
}, _ctx.$attrs), null, 16, _hoisted_1$
|
|
85
|
+
}, _ctx.$attrs), null, 16, _hoisted_1$c)), [
|
|
86
86
|
[vue.vModelDynamic, modelValue.value]
|
|
87
87
|
]);
|
|
88
88
|
};
|
|
89
89
|
}
|
|
90
90
|
});
|
|
91
|
-
const _hoisted_1$
|
|
92
|
-
const _hoisted_2$
|
|
93
|
-
const _hoisted_3$
|
|
94
|
-
const _hoisted_4$
|
|
95
|
-
const _hoisted_5$
|
|
91
|
+
const _hoisted_1$b = { class: "relative" };
|
|
92
|
+
const _hoisted_2$a = ["id", "disabled", "aria-expanded", "aria-controls", "aria-invalid", "aria-describedby"];
|
|
93
|
+
const _hoisted_3$9 = { class: "flex-1 truncate" };
|
|
94
|
+
const _hoisted_4$7 = ["id", "aria-label"];
|
|
95
|
+
const _hoisted_5$6 = {
|
|
96
96
|
key: 0,
|
|
97
97
|
class: "sticky top-0 border-b border-gray-200 bg-white p-2 dark:border-gray-700 dark:bg-gray-800"
|
|
98
98
|
};
|
|
99
|
-
const _hoisted_6$
|
|
100
|
-
const _hoisted_7$
|
|
99
|
+
const _hoisted_6$6 = { class: "flex items-center gap-2 rounded-md border border-gray-300 bg-gray-50 px-2 py-1.5 dark:border-gray-600 dark:bg-gray-900" };
|
|
100
|
+
const _hoisted_7$6 = {
|
|
101
101
|
key: 1,
|
|
102
102
|
class: "px-4 py-3 text-sm text-gray-500 dark:text-gray-400",
|
|
103
103
|
role: "status"
|
|
104
104
|
};
|
|
105
|
-
const _hoisted_8$
|
|
106
|
-
const _hoisted_9$
|
|
107
|
-
const _hoisted_10$
|
|
105
|
+
const _hoisted_8$5 = { class: "py-1" };
|
|
106
|
+
const _hoisted_9$3 = ["aria-selected", "data-index", "onClick", "onMouseenter"];
|
|
107
|
+
const _hoisted_10$3 = {
|
|
108
108
|
key: 1,
|
|
109
109
|
class: "size-4 shrink-0",
|
|
110
110
|
"aria-hidden": "true"
|
|
111
111
|
};
|
|
112
|
-
const _hoisted_11$
|
|
113
|
-
const _sfc_main$
|
|
112
|
+
const _hoisted_11$3 = { class: "flex-1" };
|
|
113
|
+
const _sfc_main$b = /* @__PURE__ */ vue.defineComponent({
|
|
114
114
|
__name: "FormSelect",
|
|
115
115
|
props: /* @__PURE__ */ vue.mergeModels({
|
|
116
116
|
options: {},
|
|
@@ -228,7 +228,7 @@ const _sfc_main$a = /* @__PURE__ */ vue.defineComponent({
|
|
|
228
228
|
return [base, state, text, props.triggerClass];
|
|
229
229
|
});
|
|
230
230
|
return (_ctx, _cache) => {
|
|
231
|
-
return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$
|
|
231
|
+
return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$b, [
|
|
232
232
|
vue.createElementVNode("button", {
|
|
233
233
|
id: triggerId.value,
|
|
234
234
|
ref_key: "triggerRef",
|
|
@@ -248,14 +248,14 @@ const _sfc_main$a = /* @__PURE__ */ vue.defineComponent({
|
|
|
248
248
|
option: selectedOption.value,
|
|
249
249
|
placeholder: __props.placeholder
|
|
250
250
|
}, () => [
|
|
251
|
-
vue.createElementVNode("span", _hoisted_3$
|
|
251
|
+
vue.createElementVNode("span", _hoisted_3$9, vue.toDisplayString(displayValue.value), 1)
|
|
252
252
|
]),
|
|
253
253
|
vue.createVNode(vue.unref(vue$1.Icon), {
|
|
254
254
|
icon: "lucide:chevron-down",
|
|
255
255
|
class: vue.normalizeClass(["size-4 shrink-0 text-gray-400 transition-transform", vue.unref(isOpen) && "rotate-180"]),
|
|
256
256
|
"aria-hidden": "true"
|
|
257
257
|
}, null, 8, ["class"])
|
|
258
|
-
], 42, _hoisted_2$
|
|
258
|
+
], 42, _hoisted_2$a),
|
|
259
259
|
(vue.openBlock(), vue.createBlock(vue.Teleport, {
|
|
260
260
|
to: "body",
|
|
261
261
|
disabled: !__props.teleport
|
|
@@ -282,8 +282,8 @@ const _sfc_main$a = /* @__PURE__ */ vue.defineComponent({
|
|
|
282
282
|
!__props.teleport && "absolute mt-1 w-full"
|
|
283
283
|
])
|
|
284
284
|
}, [
|
|
285
|
-
__props.searchable ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_5$
|
|
286
|
-
vue.createElementVNode("div", _hoisted_6$
|
|
285
|
+
__props.searchable ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_5$6, [
|
|
286
|
+
vue.createElementVNode("div", _hoisted_6$6, [
|
|
287
287
|
vue.createVNode(vue.unref(vue$1.Icon), {
|
|
288
288
|
icon: "lucide:search",
|
|
289
289
|
class: "size-4 text-gray-400",
|
|
@@ -303,8 +303,8 @@ const _sfc_main$a = /* @__PURE__ */ vue.defineComponent({
|
|
|
303
303
|
])
|
|
304
304
|
])
|
|
305
305
|
])) : vue.createCommentVNode("", true),
|
|
306
|
-
filteredOptions.value.length === 0 ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_7$
|
|
307
|
-
vue.createElementVNode("div", _hoisted_8$
|
|
306
|
+
filteredOptions.value.length === 0 ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_7$6, vue.toDisplayString(__props.noResultsText), 1)) : vue.createCommentVNode("", true),
|
|
307
|
+
vue.createElementVNode("div", _hoisted_8$5, [
|
|
308
308
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(filteredOptions.value, (option, index2) => {
|
|
309
309
|
return vue.openBlock(), vue.createElementBlock("button", {
|
|
310
310
|
key: String(option.value),
|
|
@@ -331,13 +331,13 @@ const _sfc_main$a = /* @__PURE__ */ vue.defineComponent({
|
|
|
331
331
|
icon: "lucide:check",
|
|
332
332
|
class: "size-4 shrink-0 text-primary",
|
|
333
333
|
"aria-hidden": "true"
|
|
334
|
-
})) : (vue.openBlock(), vue.createElementBlock("span", _hoisted_10$
|
|
335
|
-
vue.createElementVNode("span", _hoisted_11$
|
|
334
|
+
})) : (vue.openBlock(), vue.createElementBlock("span", _hoisted_10$3)),
|
|
335
|
+
vue.createElementVNode("span", _hoisted_11$3, vue.toDisplayString(option.label), 1)
|
|
336
336
|
])
|
|
337
|
-
], 42, _hoisted_9$
|
|
337
|
+
], 42, _hoisted_9$3);
|
|
338
338
|
}), 128))
|
|
339
339
|
])
|
|
340
|
-
], 14, _hoisted_4$
|
|
340
|
+
], 14, _hoisted_4$7)) : vue.createCommentVNode("", true)
|
|
341
341
|
]),
|
|
342
342
|
_: 3
|
|
343
343
|
})
|
|
@@ -346,8 +346,8 @@ const _sfc_main$a = /* @__PURE__ */ vue.defineComponent({
|
|
|
346
346
|
};
|
|
347
347
|
}
|
|
348
348
|
});
|
|
349
|
-
const _hoisted_1$
|
|
350
|
-
const _sfc_main$
|
|
349
|
+
const _hoisted_1$a = ["hidden"];
|
|
350
|
+
const _sfc_main$a = /* @__PURE__ */ vue.defineComponent({
|
|
351
351
|
__name: "FormGroup",
|
|
352
352
|
props: /* @__PURE__ */ vue.mergeModels({
|
|
353
353
|
label: {},
|
|
@@ -386,7 +386,7 @@ const _sfc_main$9 = /* @__PURE__ */ vue.defineComponent({
|
|
|
386
386
|
}, [
|
|
387
387
|
vue.renderSlot(_ctx.$slots, "default", {}, () => [
|
|
388
388
|
vue.renderSlot(_ctx.$slots, "label", {}, () => [
|
|
389
|
-
__props.label ? (vue.openBlock(), vue.createBlock(_sfc_main$
|
|
389
|
+
__props.label ? (vue.openBlock(), vue.createBlock(_sfc_main$e, {
|
|
390
390
|
key: 0,
|
|
391
391
|
"html-for": inputId.value,
|
|
392
392
|
error: __props.error
|
|
@@ -398,7 +398,7 @@ const _sfc_main$9 = /* @__PURE__ */ vue.defineComponent({
|
|
|
398
398
|
}, 8, ["html-for", "error"])) : vue.createCommentVNode("", true)
|
|
399
399
|
]),
|
|
400
400
|
vue.renderSlot(_ctx.$slots, "input", {}, () => [
|
|
401
|
-
isSelect.value ? (vue.openBlock(), vue.createBlock(_sfc_main$
|
|
401
|
+
isSelect.value ? (vue.openBlock(), vue.createBlock(_sfc_main$b, vue.mergeProps({
|
|
402
402
|
key: 0,
|
|
403
403
|
modelValue: modelValue.value,
|
|
404
404
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => modelValue.value = $event)
|
|
@@ -406,7 +406,7 @@ const _sfc_main$9 = /* @__PURE__ */ vue.defineComponent({
|
|
|
406
406
|
id: inputId.value,
|
|
407
407
|
invalid: Boolean(__props.error),
|
|
408
408
|
"described-by": hasError.value ? helpId.value : void 0
|
|
409
|
-
}), null, 16, ["modelValue", "id", "invalid", "described-by"])) : (vue.openBlock(), vue.createBlock(_sfc_main$
|
|
409
|
+
}), null, 16, ["modelValue", "id", "invalid", "described-by"])) : (vue.openBlock(), vue.createBlock(_sfc_main$c, vue.mergeProps({
|
|
410
410
|
key: 1,
|
|
411
411
|
modelValue: modelValue.value,
|
|
412
412
|
"onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => modelValue.value = $event)
|
|
@@ -416,7 +416,7 @@ const _sfc_main$9 = /* @__PURE__ */ vue.defineComponent({
|
|
|
416
416
|
"described-by": hasError.value ? helpId.value : void 0
|
|
417
417
|
}), null, 16, ["modelValue", "id", "invalid", "described-by"]))
|
|
418
418
|
]),
|
|
419
|
-
hasError.value ? (vue.openBlock(), vue.createBlock(_sfc_main$
|
|
419
|
+
hasError.value ? (vue.openBlock(), vue.createBlock(_sfc_main$d, {
|
|
420
420
|
key: 0,
|
|
421
421
|
id: helpId.value,
|
|
422
422
|
error: true
|
|
@@ -427,13 +427,13 @@ const _sfc_main$9 = /* @__PURE__ */ vue.defineComponent({
|
|
|
427
427
|
_: 1
|
|
428
428
|
}, 8, ["id"])) : vue.createCommentVNode("", true)
|
|
429
429
|
])
|
|
430
|
-
], 12, _hoisted_1$
|
|
430
|
+
], 12, _hoisted_1$a);
|
|
431
431
|
};
|
|
432
432
|
}
|
|
433
433
|
});
|
|
434
|
-
const _hoisted_1$
|
|
435
|
-
const _hoisted_2$
|
|
436
|
-
const _sfc_main$
|
|
434
|
+
const _hoisted_1$9 = { class: "relative" };
|
|
435
|
+
const _hoisted_2$9 = ["disabled", "placeholder", "value"];
|
|
436
|
+
const _sfc_main$9 = /* @__PURE__ */ vue.defineComponent({
|
|
437
437
|
__name: "SearchInput",
|
|
438
438
|
props: {
|
|
439
439
|
modelValue: {},
|
|
@@ -449,7 +449,7 @@ const _sfc_main$8 = /* @__PURE__ */ vue.defineComponent({
|
|
|
449
449
|
emit("update:modelValue", target.value);
|
|
450
450
|
};
|
|
451
451
|
return (_ctx, _cache) => {
|
|
452
|
-
return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$
|
|
452
|
+
return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$9, [
|
|
453
453
|
vue.createVNode(vue.unref(vue$1.Icon), {
|
|
454
454
|
icon: __props.icon,
|
|
455
455
|
class: "absolute top-1/2 left-3 size-5 -translate-y-1/2 text-gray-400"
|
|
@@ -461,19 +461,19 @@ const _sfc_main$8 = /* @__PURE__ */ vue.defineComponent({
|
|
|
461
461
|
class: "focus:border-primary focus:ring-primary w-full rounded-lg border border-gray-300 bg-white py-2 pr-4 pl-10 text-gray-900 placeholder-gray-400 transition-colors disabled:cursor-not-allowed disabled:opacity-50 dark:border-gray-600 dark:bg-gray-800 dark:text-gray-100 dark:placeholder-gray-500",
|
|
462
462
|
type: "text",
|
|
463
463
|
onInput: handleInput
|
|
464
|
-
}, null, 40, _hoisted_2$
|
|
464
|
+
}, null, 40, _hoisted_2$9)
|
|
465
465
|
]);
|
|
466
466
|
};
|
|
467
467
|
}
|
|
468
468
|
});
|
|
469
|
-
const _hoisted_1$
|
|
470
|
-
const _hoisted_2$
|
|
469
|
+
const _hoisted_1$8 = ["id", "aria-checked", "aria-labelledby", "aria-describedby", "disabled"];
|
|
470
|
+
const _hoisted_2$8 = {
|
|
471
471
|
key: 0,
|
|
472
472
|
class: "flex flex-col"
|
|
473
473
|
};
|
|
474
|
-
const _hoisted_3$
|
|
475
|
-
const _hoisted_4$
|
|
476
|
-
const _sfc_main$
|
|
474
|
+
const _hoisted_3$8 = ["id"];
|
|
475
|
+
const _hoisted_4$6 = ["id"];
|
|
476
|
+
const _sfc_main$8 = /* @__PURE__ */ vue.defineComponent({
|
|
477
477
|
__name: "Switch",
|
|
478
478
|
props: {
|
|
479
479
|
modelValue: { type: Boolean, default: false },
|
|
@@ -537,35 +537,35 @@ const _sfc_main$7 = /* @__PURE__ */ vue.defineComponent({
|
|
|
537
537
|
]),
|
|
538
538
|
"aria-hidden": "true"
|
|
539
539
|
}, null, 2)
|
|
540
|
-
], 10, _hoisted_1$
|
|
541
|
-
__props.label || __props.description ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_2$
|
|
540
|
+
], 10, _hoisted_1$8),
|
|
541
|
+
__props.label || __props.description ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_2$8, [
|
|
542
542
|
__props.label ? (vue.openBlock(), vue.createElementBlock("span", {
|
|
543
543
|
key: 0,
|
|
544
544
|
id: labelId.value,
|
|
545
545
|
class: "text-sm font-medium text-gray-900 dark:text-white"
|
|
546
|
-
}, vue.toDisplayString(__props.label), 9, _hoisted_3$
|
|
546
|
+
}, vue.toDisplayString(__props.label), 9, _hoisted_3$8)) : vue.createCommentVNode("", true),
|
|
547
547
|
__props.description ? (vue.openBlock(), vue.createElementBlock("span", {
|
|
548
548
|
key: 1,
|
|
549
549
|
id: descriptionId.value,
|
|
550
550
|
class: "text-sm text-gray-500 dark:text-gray-400"
|
|
551
|
-
}, vue.toDisplayString(__props.description), 9, _hoisted_4$
|
|
551
|
+
}, vue.toDisplayString(__props.description), 9, _hoisted_4$6)) : vue.createCommentVNode("", true)
|
|
552
552
|
])) : vue.createCommentVNode("", true)
|
|
553
553
|
], 2);
|
|
554
554
|
};
|
|
555
555
|
}
|
|
556
556
|
});
|
|
557
|
-
const _hoisted_1$
|
|
558
|
-
const _hoisted_2$
|
|
557
|
+
const _hoisted_1$7 = { class: "w-full" };
|
|
558
|
+
const _hoisted_2$7 = {
|
|
559
559
|
key: 0,
|
|
560
560
|
class: "mb-2 flex justify-between text-sm"
|
|
561
561
|
};
|
|
562
|
-
const _hoisted_3$
|
|
563
|
-
const _hoisted_4$
|
|
564
|
-
const _hoisted_5$
|
|
565
|
-
const _hoisted_6$
|
|
566
|
-
const _hoisted_7$
|
|
567
|
-
const _hoisted_8$
|
|
568
|
-
const _sfc_main$
|
|
562
|
+
const _hoisted_3$7 = { class: "text-gray-600 dark:text-gray-400" };
|
|
563
|
+
const _hoisted_4$5 = { class: "font-medium text-gray-900 dark:text-white" };
|
|
564
|
+
const _hoisted_5$5 = { class: "text-gray-600 dark:text-gray-400" };
|
|
565
|
+
const _hoisted_6$5 = { class: "relative" };
|
|
566
|
+
const _hoisted_7$5 = ["value", "min", "max", "step", "disabled"];
|
|
567
|
+
const _hoisted_8$4 = { class: "pointer-events-none absolute inset-y-0 left-0 flex items-center" };
|
|
568
|
+
const _sfc_main$7 = /* @__PURE__ */ vue.defineComponent({
|
|
569
569
|
__name: "Slider",
|
|
570
570
|
props: /* @__PURE__ */ vue.mergeModels({
|
|
571
571
|
min: { default: 0 },
|
|
@@ -596,13 +596,13 @@ const _sfc_main$6 = /* @__PURE__ */ vue.defineComponent({
|
|
|
596
596
|
modelValue.value = Number(target.value);
|
|
597
597
|
};
|
|
598
598
|
return (_ctx, _cache) => {
|
|
599
|
-
return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$
|
|
600
|
-
__props.showValue ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_2$
|
|
601
|
-
vue.createElementVNode("span", _hoisted_3$
|
|
602
|
-
vue.createElementVNode("span", _hoisted_4$
|
|
603
|
-
vue.createElementVNode("span", _hoisted_5$
|
|
599
|
+
return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$7, [
|
|
600
|
+
__props.showValue ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_2$7, [
|
|
601
|
+
vue.createElementVNode("span", _hoisted_3$7, vue.toDisplayString(__props.min), 1),
|
|
602
|
+
vue.createElementVNode("span", _hoisted_4$5, vue.toDisplayString(displayValue.value), 1),
|
|
603
|
+
vue.createElementVNode("span", _hoisted_5$5, vue.toDisplayString(__props.max), 1)
|
|
604
604
|
])) : vue.createCommentVNode("", true),
|
|
605
|
-
vue.createElementVNode("div", _hoisted_6$
|
|
605
|
+
vue.createElementVNode("div", _hoisted_6$5, [
|
|
606
606
|
vue.createElementVNode("input", {
|
|
607
607
|
type: "range",
|
|
608
608
|
value: modelValue.value,
|
|
@@ -612,8 +612,8 @@ const _sfc_main$6 = /* @__PURE__ */ vue.defineComponent({
|
|
|
612
612
|
disabled: __props.disabled,
|
|
613
613
|
class: "slider-input w-full cursor-pointer appearance-none bg-transparent disabled:cursor-not-allowed disabled:opacity-50",
|
|
614
614
|
onInput: handleInput
|
|
615
|
-
}, null, 40, _hoisted_7$
|
|
616
|
-
vue.createElementVNode("div", _hoisted_8$
|
|
615
|
+
}, null, 40, _hoisted_7$5),
|
|
616
|
+
vue.createElementVNode("div", _hoisted_8$4, [
|
|
617
617
|
vue.createElementVNode("div", {
|
|
618
618
|
class: "h-2 rounded-full bg-primary",
|
|
619
619
|
style: vue.normalizeStyle({ width: `${percentage.value}%` })
|
|
@@ -624,27 +624,27 @@ const _sfc_main$6 = /* @__PURE__ */ vue.defineComponent({
|
|
|
624
624
|
};
|
|
625
625
|
}
|
|
626
626
|
});
|
|
627
|
-
const Slider = /* @__PURE__ */ _pluginVue_exportHelper._export_sfc(_sfc_main$
|
|
628
|
-
const _hoisted_1$
|
|
629
|
-
const _hoisted_2$
|
|
630
|
-
const _hoisted_3$
|
|
631
|
-
const _hoisted_4$
|
|
632
|
-
const _hoisted_5$
|
|
633
|
-
const _hoisted_6$
|
|
634
|
-
const _hoisted_7$
|
|
627
|
+
const Slider = /* @__PURE__ */ _pluginVue_exportHelper._export_sfc(_sfc_main$7, [["__scopeId", "data-v-c25e2c2a"]]);
|
|
628
|
+
const _hoisted_1$6 = { class: "relative" };
|
|
629
|
+
const _hoisted_2$6 = ["id", "disabled", "aria-expanded", "aria-controls"];
|
|
630
|
+
const _hoisted_3$6 = { class: "flex-1 truncate" };
|
|
631
|
+
const _hoisted_4$4 = { class: "flex items-center gap-1" };
|
|
632
|
+
const _hoisted_5$4 = ["id", "aria-label"];
|
|
633
|
+
const _hoisted_6$4 = { class: "mb-4 flex items-center justify-between" };
|
|
634
|
+
const _hoisted_7$4 = {
|
|
635
635
|
class: "font-medium text-gray-900 dark:text-white",
|
|
636
636
|
"aria-live": "polite",
|
|
637
637
|
"aria-atomic": "true"
|
|
638
638
|
};
|
|
639
|
-
const _hoisted_8$
|
|
639
|
+
const _hoisted_8$3 = {
|
|
640
640
|
class: "mb-2 grid grid-cols-7 gap-1",
|
|
641
641
|
role: "row"
|
|
642
642
|
};
|
|
643
|
-
const _hoisted_9$
|
|
644
|
-
const _hoisted_10$
|
|
645
|
-
const _hoisted_11$
|
|
646
|
-
const _hoisted_12 = { class: "mt-4 border-t border-gray-200 pt-3 dark:border-gray-700" };
|
|
647
|
-
const _sfc_main$
|
|
643
|
+
const _hoisted_9$2 = ["abbr"];
|
|
644
|
+
const _hoisted_10$2 = ["id", "aria-label"];
|
|
645
|
+
const _hoisted_11$2 = ["aria-label", "aria-selected", "aria-disabled", "disabled", "onClick"];
|
|
646
|
+
const _hoisted_12$1 = { class: "mt-4 border-t border-gray-200 pt-3 dark:border-gray-700" };
|
|
647
|
+
const _sfc_main$6 = /* @__PURE__ */ vue.defineComponent({
|
|
648
648
|
__name: "DatePicker",
|
|
649
649
|
props: /* @__PURE__ */ vue.mergeModels({
|
|
650
650
|
placeholder: { default: "Select date" },
|
|
@@ -768,7 +768,7 @@ const _sfc_main$5 = /* @__PURE__ */ vue.defineComponent({
|
|
|
768
768
|
return formatter.format(date);
|
|
769
769
|
};
|
|
770
770
|
return (_ctx, _cache) => {
|
|
771
|
-
return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$
|
|
771
|
+
return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$6, [
|
|
772
772
|
vue.createElementVNode("button", {
|
|
773
773
|
id: triggerId.value,
|
|
774
774
|
ref_key: "triggerRef",
|
|
@@ -786,8 +786,8 @@ const _sfc_main$5 = /* @__PURE__ */ vue.defineComponent({
|
|
|
786
786
|
onClick: _cache[0] || (_cache[0] = //@ts-ignore
|
|
787
787
|
(...args) => vue.unref(toggle) && vue.unref(toggle)(...args))
|
|
788
788
|
}, [
|
|
789
|
-
vue.createElementVNode("span", _hoisted_3$
|
|
790
|
-
vue.createElementVNode("div", _hoisted_4$
|
|
789
|
+
vue.createElementVNode("span", _hoisted_3$6, vue.toDisplayString(displayValue.value || __props.placeholder), 1),
|
|
790
|
+
vue.createElementVNode("div", _hoisted_4$4, [
|
|
791
791
|
modelValue.value ? (vue.openBlock(), vue.createElementBlock("button", {
|
|
792
792
|
key: 0,
|
|
793
793
|
type: "button",
|
|
@@ -807,7 +807,7 @@ const _sfc_main$5 = /* @__PURE__ */ vue.defineComponent({
|
|
|
807
807
|
"aria-hidden": "true"
|
|
808
808
|
})
|
|
809
809
|
])
|
|
810
|
-
], 10, _hoisted_2$
|
|
810
|
+
], 10, _hoisted_2$6),
|
|
811
811
|
(vue.openBlock(), vue.createBlock(vue.Teleport, {
|
|
812
812
|
to: "body",
|
|
813
813
|
disabled: !__props.teleport
|
|
@@ -832,7 +832,7 @@ const _sfc_main$5 = /* @__PURE__ */ vue.defineComponent({
|
|
|
832
832
|
style: vue.normalizeStyle(vue.unref(dropdownStyle)),
|
|
833
833
|
class: "z-9999 w-72 rounded-lg border border-gray-200 bg-white p-4 shadow-lg dark:border-gray-700 dark:bg-gray-800"
|
|
834
834
|
}, [
|
|
835
|
-
vue.createElementVNode("div", _hoisted_6$
|
|
835
|
+
vue.createElementVNode("div", _hoisted_6$4, [
|
|
836
836
|
vue.createElementVNode("button", {
|
|
837
837
|
type: "button",
|
|
838
838
|
class: "rounded p-1 hover:bg-gray-100 dark:hover:bg-gray-700",
|
|
@@ -845,7 +845,7 @@ const _sfc_main$5 = /* @__PURE__ */ vue.defineComponent({
|
|
|
845
845
|
"aria-hidden": "true"
|
|
846
846
|
})
|
|
847
847
|
]),
|
|
848
|
-
vue.createElementVNode("span", _hoisted_7$
|
|
848
|
+
vue.createElementVNode("span", _hoisted_7$4, vue.toDisplayString(monthYear.value), 1),
|
|
849
849
|
vue.createElementVNode("button", {
|
|
850
850
|
type: "button",
|
|
851
851
|
class: "rounded p-1 hover:bg-gray-100 dark:hover:bg-gray-700",
|
|
@@ -859,14 +859,14 @@ const _sfc_main$5 = /* @__PURE__ */ vue.defineComponent({
|
|
|
859
859
|
})
|
|
860
860
|
])
|
|
861
861
|
]),
|
|
862
|
-
vue.createElementVNode("div", _hoisted_8$
|
|
862
|
+
vue.createElementVNode("div", _hoisted_8$3, [
|
|
863
863
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(weekDays.value, (day) => {
|
|
864
864
|
return vue.openBlock(), vue.createElementBlock("div", {
|
|
865
865
|
key: day,
|
|
866
866
|
class: "text-center text-xs font-medium text-gray-500 dark:text-gray-400",
|
|
867
867
|
role: "columnheader",
|
|
868
868
|
abbr: day
|
|
869
|
-
}, vue.toDisplayString(day), 9, _hoisted_9$
|
|
869
|
+
}, vue.toDisplayString(day), 9, _hoisted_9$2);
|
|
870
870
|
}), 128))
|
|
871
871
|
]),
|
|
872
872
|
vue.createElementVNode("div", {
|
|
@@ -893,17 +893,17 @@ const _sfc_main$5 = /* @__PURE__ */ vue.defineComponent({
|
|
|
893
893
|
day.isSelected && "bg-primary text-white font-semibold"
|
|
894
894
|
]),
|
|
895
895
|
onClick: ($event) => selectDate(day)
|
|
896
|
-
}, vue.toDisplayString(day.date.getDate()), 11, _hoisted_11$
|
|
896
|
+
}, vue.toDisplayString(day.date.getDate()), 11, _hoisted_11$2);
|
|
897
897
|
}), 128))
|
|
898
|
-
], 8, _hoisted_10$
|
|
899
|
-
vue.createElementVNode("div", _hoisted_12, [
|
|
898
|
+
], 8, _hoisted_10$2),
|
|
899
|
+
vue.createElementVNode("div", _hoisted_12$1, [
|
|
900
900
|
vue.createElementVNode("button", {
|
|
901
901
|
type: "button",
|
|
902
902
|
class: "w-full rounded py-1.5 text-sm font-medium text-primary hover:bg-primary/10",
|
|
903
903
|
onClick: _cache[1] || (_cache[1] = ($event) => selectDate({ date: /* @__PURE__ */ new Date(), isDisabled: false }))
|
|
904
904
|
}, " Today ")
|
|
905
905
|
])
|
|
906
|
-
], 12, _hoisted_5$
|
|
906
|
+
], 12, _hoisted_5$4)) : vue.createCommentVNode("", true)
|
|
907
907
|
]),
|
|
908
908
|
_: 1
|
|
909
909
|
})
|
|
@@ -912,27 +912,27 @@ const _sfc_main$5 = /* @__PURE__ */ vue.defineComponent({
|
|
|
912
912
|
};
|
|
913
913
|
}
|
|
914
914
|
});
|
|
915
|
-
const _hoisted_1$
|
|
916
|
-
const _hoisted_2$
|
|
917
|
-
const _hoisted_3$
|
|
918
|
-
const _hoisted_4$
|
|
919
|
-
const _hoisted_5$
|
|
915
|
+
const _hoisted_1$5 = { class: "space-y-4" };
|
|
916
|
+
const _hoisted_2$5 = ["accept", "multiple", "disabled"];
|
|
917
|
+
const _hoisted_3$5 = { class: "space-y-2" };
|
|
918
|
+
const _hoisted_4$3 = { class: "text-sm font-medium text-gray-700 dark:text-gray-300" };
|
|
919
|
+
const _hoisted_5$3 = {
|
|
920
920
|
key: 0,
|
|
921
921
|
class: "text-xs text-gray-500 dark:text-gray-400"
|
|
922
922
|
};
|
|
923
|
-
const _hoisted_6$
|
|
923
|
+
const _hoisted_6$3 = {
|
|
924
924
|
key: 1,
|
|
925
925
|
class: "text-xs text-gray-500 dark:text-gray-400"
|
|
926
926
|
};
|
|
927
|
-
const _hoisted_7$
|
|
927
|
+
const _hoisted_7$3 = {
|
|
928
928
|
key: 0,
|
|
929
929
|
class: "space-y-2"
|
|
930
930
|
};
|
|
931
|
-
const _hoisted_8$
|
|
932
|
-
const _hoisted_9 = { class: "text-sm font-medium text-gray-700 dark:text-gray-300 truncate" };
|
|
933
|
-
const _hoisted_10 = { class: "text-xs text-gray-500 dark:text-gray-400" };
|
|
934
|
-
const _hoisted_11 = ["onClick"];
|
|
935
|
-
const _sfc_main$
|
|
931
|
+
const _hoisted_8$2 = { class: "flex-1 min-w-0" };
|
|
932
|
+
const _hoisted_9$1 = { class: "text-sm font-medium text-gray-700 dark:text-gray-300 truncate" };
|
|
933
|
+
const _hoisted_10$1 = { class: "text-xs text-gray-500 dark:text-gray-400" };
|
|
934
|
+
const _hoisted_11$1 = ["onClick"];
|
|
935
|
+
const _sfc_main$5 = /* @__PURE__ */ vue.defineComponent({
|
|
936
936
|
__name: "FileUpload",
|
|
937
937
|
props: {
|
|
938
938
|
accept: {},
|
|
@@ -1060,7 +1060,7 @@ const _sfc_main$4 = /* @__PURE__ */ vue.defineComponent({
|
|
|
1060
1060
|
return "heroicons:document";
|
|
1061
1061
|
};
|
|
1062
1062
|
return (_ctx, _cache) => {
|
|
1063
|
-
return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$
|
|
1063
|
+
return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$5, [
|
|
1064
1064
|
vue.createElementVNode("div", {
|
|
1065
1065
|
class: vue.normalizeClass(dropzoneClasses.value),
|
|
1066
1066
|
onDrop: vue.withModifiers(handleDrop, ["prevent"]),
|
|
@@ -1077,18 +1077,18 @@ const _sfc_main$4 = /* @__PURE__ */ vue.defineComponent({
|
|
|
1077
1077
|
multiple: __props.multiple,
|
|
1078
1078
|
disabled: __props.disabled,
|
|
1079
1079
|
onChange: handleInputChange
|
|
1080
|
-
}, null, 40, _hoisted_2$
|
|
1081
|
-
vue.createElementVNode("div", _hoisted_3$
|
|
1080
|
+
}, null, 40, _hoisted_2$5),
|
|
1081
|
+
vue.createElementVNode("div", _hoisted_3$5, [
|
|
1082
1082
|
vue.createVNode(vue.unref(vue$1.Icon), {
|
|
1083
1083
|
icon: "heroicons:cloud-arrow-up",
|
|
1084
1084
|
class: vue.normalizeClass(["size-12 mx-auto text-gray-400", { "text-primary-500": isDragging.value }])
|
|
1085
1085
|
}, null, 8, ["class"]),
|
|
1086
|
-
vue.createElementVNode("p", _hoisted_4$
|
|
1087
|
-
__props.description ? (vue.openBlock(), vue.createElementBlock("p", _hoisted_5$
|
|
1088
|
-
__props.maxSize ? (vue.openBlock(), vue.createElementBlock("p", _hoisted_6$
|
|
1086
|
+
vue.createElementVNode("p", _hoisted_4$3, vue.toDisplayString(__props.label), 1),
|
|
1087
|
+
__props.description ? (vue.openBlock(), vue.createElementBlock("p", _hoisted_5$3, vue.toDisplayString(__props.description), 1)) : vue.createCommentVNode("", true),
|
|
1088
|
+
__props.maxSize ? (vue.openBlock(), vue.createElementBlock("p", _hoisted_6$3, " Max size: " + vue.toDisplayString(formatSize(__props.maxSize)), 1)) : vue.createCommentVNode("", true)
|
|
1089
1089
|
])
|
|
1090
1090
|
], 34),
|
|
1091
|
-
files.value.length > 0 ? (vue.openBlock(), vue.createElementBlock("ul", _hoisted_7$
|
|
1091
|
+
files.value.length > 0 ? (vue.openBlock(), vue.createElementBlock("ul", _hoisted_7$3, [
|
|
1092
1092
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(files.value, (uploadedFile) => {
|
|
1093
1093
|
return vue.openBlock(), vue.createElementBlock("li", {
|
|
1094
1094
|
key: uploadedFile.id,
|
|
@@ -1098,9 +1098,9 @@ const _sfc_main$4 = /* @__PURE__ */ vue.defineComponent({
|
|
|
1098
1098
|
icon: getFileIcon(uploadedFile.file),
|
|
1099
1099
|
class: "size-8 text-gray-400"
|
|
1100
1100
|
}, null, 8, ["icon"]),
|
|
1101
|
-
vue.createElementVNode("div", _hoisted_8$
|
|
1102
|
-
vue.createElementVNode("p", _hoisted_9, vue.toDisplayString(uploadedFile.file.name), 1),
|
|
1103
|
-
vue.createElementVNode("p", _hoisted_10, vue.toDisplayString(formatSize(uploadedFile.file.size)), 1)
|
|
1101
|
+
vue.createElementVNode("div", _hoisted_8$2, [
|
|
1102
|
+
vue.createElementVNode("p", _hoisted_9$1, vue.toDisplayString(uploadedFile.file.name), 1),
|
|
1103
|
+
vue.createElementVNode("p", _hoisted_10$1, vue.toDisplayString(formatSize(uploadedFile.file.size)), 1)
|
|
1104
1104
|
]),
|
|
1105
1105
|
vue.createElementVNode("button", {
|
|
1106
1106
|
type: "button",
|
|
@@ -1111,7 +1111,7 @@ const _sfc_main$4 = /* @__PURE__ */ vue.defineComponent({
|
|
|
1111
1111
|
icon: "heroicons:x-mark",
|
|
1112
1112
|
class: "size-5"
|
|
1113
1113
|
})
|
|
1114
|
-
], 8, _hoisted_11)
|
|
1114
|
+
], 8, _hoisted_11$1)
|
|
1115
1115
|
]);
|
|
1116
1116
|
}), 128))
|
|
1117
1117
|
])) : vue.createCommentVNode("", true)
|
|
@@ -1119,13 +1119,13 @@ const _sfc_main$4 = /* @__PURE__ */ vue.defineComponent({
|
|
|
1119
1119
|
};
|
|
1120
1120
|
}
|
|
1121
1121
|
});
|
|
1122
|
-
const _hoisted_1$
|
|
1123
|
-
const _hoisted_2$
|
|
1124
|
-
const _hoisted_3$
|
|
1122
|
+
const _hoisted_1$4 = { class: "flex items-center gap-1" };
|
|
1123
|
+
const _hoisted_2$4 = ["disabled", "onClick", "onMousemove"];
|
|
1124
|
+
const _hoisted_3$4 = {
|
|
1125
1125
|
key: 0,
|
|
1126
1126
|
class: "ml-2 text-sm font-medium text-gray-700 dark:text-gray-300"
|
|
1127
1127
|
};
|
|
1128
|
-
const _sfc_main$
|
|
1128
|
+
const _sfc_main$4 = /* @__PURE__ */ vue.defineComponent({
|
|
1129
1129
|
__name: "Rating",
|
|
1130
1130
|
props: {
|
|
1131
1131
|
modelValue: { default: 0 },
|
|
@@ -1188,7 +1188,7 @@ const _sfc_main$3 = /* @__PURE__ */ vue.defineComponent({
|
|
|
1188
1188
|
hoverValue.value = null;
|
|
1189
1189
|
};
|
|
1190
1190
|
return (_ctx, _cache) => {
|
|
1191
|
-
return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$
|
|
1191
|
+
return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$4, [
|
|
1192
1192
|
vue.createElementVNode("div", {
|
|
1193
1193
|
class: "flex items-center",
|
|
1194
1194
|
onMouseleave: handleMouseLeave
|
|
@@ -1220,29 +1220,29 @@ const _sfc_main$3 = /* @__PURE__ */ vue.defineComponent({
|
|
|
1220
1220
|
class: vue.normalizeClass([sizeClasses.value, __props.color])
|
|
1221
1221
|
}, null, 8, ["icon", "class"])
|
|
1222
1222
|
], 4)
|
|
1223
|
-
], 42, _hoisted_2$
|
|
1223
|
+
], 42, _hoisted_2$4);
|
|
1224
1224
|
}), 128))
|
|
1225
1225
|
], 32),
|
|
1226
|
-
__props.showValue ? (vue.openBlock(), vue.createElementBlock("span", _hoisted_3$
|
|
1226
|
+
__props.showValue ? (vue.openBlock(), vue.createElementBlock("span", _hoisted_3$4, vue.toDisplayString(__props.modelValue.toFixed(__props.allowHalf ? 1 : 0)), 1)) : vue.createCommentVNode("", true)
|
|
1227
1227
|
]);
|
|
1228
1228
|
};
|
|
1229
1229
|
}
|
|
1230
1230
|
});
|
|
1231
|
-
const _hoisted_1$
|
|
1232
|
-
const _hoisted_2$
|
|
1231
|
+
const _hoisted_1$3 = { class: "relative inline-block" };
|
|
1232
|
+
const _hoisted_2$3 = {
|
|
1233
1233
|
key: 0,
|
|
1234
1234
|
class: "block text-sm font-medium text-gray-700 dark:text-gray-300 mb-1"
|
|
1235
1235
|
};
|
|
1236
|
-
const _hoisted_3$
|
|
1237
|
-
const _hoisted_4$
|
|
1238
|
-
const _hoisted_5$
|
|
1239
|
-
const _hoisted_6$
|
|
1240
|
-
const _hoisted_7$
|
|
1236
|
+
const _hoisted_3$3 = ["disabled"];
|
|
1237
|
+
const _hoisted_4$2 = { class: "text-sm font-mono text-gray-700 dark:text-gray-300" };
|
|
1238
|
+
const _hoisted_5$2 = { class: "grid grid-cols-5 gap-2 mb-3" };
|
|
1239
|
+
const _hoisted_6$2 = ["title", "onClick"];
|
|
1240
|
+
const _hoisted_7$2 = {
|
|
1241
1241
|
key: 0,
|
|
1242
1242
|
class: "flex items-center gap-2 pt-3 border-t border-gray-200 dark:border-gray-700"
|
|
1243
1243
|
};
|
|
1244
|
-
const _hoisted_8 = ["value"];
|
|
1245
|
-
const _sfc_main$
|
|
1244
|
+
const _hoisted_8$1 = ["value"];
|
|
1245
|
+
const _sfc_main$3 = /* @__PURE__ */ vue.defineComponent({
|
|
1246
1246
|
__name: "ColorPicker",
|
|
1247
1247
|
props: {
|
|
1248
1248
|
modelValue: { default: "#3b82f6" },
|
|
@@ -1311,8 +1311,8 @@ const _sfc_main$2 = /* @__PURE__ */ vue.defineComponent({
|
|
|
1311
1311
|
isOpen.value = false;
|
|
1312
1312
|
};
|
|
1313
1313
|
return (_ctx, _cache) => {
|
|
1314
|
-
return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$
|
|
1315
|
-
__props.label ? (vue.openBlock(), vue.createElementBlock("label", _hoisted_2$
|
|
1314
|
+
return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$3, [
|
|
1315
|
+
__props.label ? (vue.openBlock(), vue.createElementBlock("label", _hoisted_2$3, vue.toDisplayString(__props.label), 1)) : vue.createCommentVNode("", true),
|
|
1316
1316
|
vue.createElementVNode("button", {
|
|
1317
1317
|
type: "button",
|
|
1318
1318
|
class: vue.normalizeClass(["flex items-center gap-2 px-3 py-2 border border-gray-300 dark:border-gray-600 rounded-lg bg-white dark:bg-gray-800 hover:bg-gray-50 dark:hover:bg-gray-700 transition-colors", { "opacity-50 cursor-not-allowed": __props.disabled }]),
|
|
@@ -1323,12 +1323,12 @@ const _sfc_main$2 = /* @__PURE__ */ vue.defineComponent({
|
|
|
1323
1323
|
class: "size-6 rounded border border-gray-200 dark:border-gray-600",
|
|
1324
1324
|
style: vue.normalizeStyle({ backgroundColor: __props.modelValue })
|
|
1325
1325
|
}, null, 4),
|
|
1326
|
-
vue.createElementVNode("span", _hoisted_4$
|
|
1326
|
+
vue.createElementVNode("span", _hoisted_4$2, vue.toDisplayString(__props.modelValue), 1),
|
|
1327
1327
|
vue.createVNode(vue.unref(vue$1.Icon), {
|
|
1328
1328
|
icon: "heroicons:chevron-down",
|
|
1329
1329
|
class: vue.normalizeClass(["size-4 text-gray-400", { "rotate-180": isOpen.value }])
|
|
1330
1330
|
}, null, 8, ["class"])
|
|
1331
|
-
], 10, _hoisted_3$
|
|
1331
|
+
], 10, _hoisted_3$3),
|
|
1332
1332
|
(vue.openBlock(), vue.createBlock(vue.Teleport, {
|
|
1333
1333
|
to: teleportTarget.value,
|
|
1334
1334
|
disabled: teleportDisabled.value
|
|
@@ -1348,7 +1348,7 @@ const _sfc_main$2 = /* @__PURE__ */ vue.defineComponent({
|
|
|
1348
1348
|
onClick: _cache[1] || (_cache[1] = vue.withModifiers(() => {
|
|
1349
1349
|
}, ["stop"]))
|
|
1350
1350
|
}, [
|
|
1351
|
-
vue.createElementVNode("div", _hoisted_5$
|
|
1351
|
+
vue.createElementVNode("div", _hoisted_5$2, [
|
|
1352
1352
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(__props.swatches, (color) => {
|
|
1353
1353
|
return vue.openBlock(), vue.createElementBlock("button", {
|
|
1354
1354
|
key: color,
|
|
@@ -1367,16 +1367,16 @@ const _sfc_main$2 = /* @__PURE__ */ vue.defineComponent({
|
|
|
1367
1367
|
["#ffffff", "#f9fafb", "#f3f4f6", "#e5e7eb", "#eab308", "#f59e0b"].includes(color) ? "text-gray-800" : "text-white"
|
|
1368
1368
|
]])
|
|
1369
1369
|
}, null, 8, ["class"])) : vue.createCommentVNode("", true)
|
|
1370
|
-
], 14, _hoisted_6$
|
|
1370
|
+
], 14, _hoisted_6$2);
|
|
1371
1371
|
}), 128))
|
|
1372
1372
|
]),
|
|
1373
|
-
__props.showInput ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_7$
|
|
1373
|
+
__props.showInput ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_7$2, [
|
|
1374
1374
|
vue.createElementVNode("input", {
|
|
1375
1375
|
type: "color",
|
|
1376
1376
|
value: __props.modelValue,
|
|
1377
1377
|
class: "size-8 rounded cursor-pointer border-0 p-0",
|
|
1378
1378
|
onInput: handleNativeInput
|
|
1379
|
-
}, null, 40, _hoisted_8),
|
|
1379
|
+
}, null, 40, _hoisted_8$1),
|
|
1380
1380
|
vue.withDirectives(vue.createElementVNode("input", {
|
|
1381
1381
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => inputValue.value = $event),
|
|
1382
1382
|
type: "text",
|
|
@@ -1402,16 +1402,16 @@ const _sfc_main$2 = /* @__PURE__ */ vue.defineComponent({
|
|
|
1402
1402
|
};
|
|
1403
1403
|
}
|
|
1404
1404
|
});
|
|
1405
|
-
const _hoisted_1$
|
|
1406
|
-
const _hoisted_2$
|
|
1405
|
+
const _hoisted_1$2 = { class: "space-y-2" };
|
|
1406
|
+
const _hoisted_2$2 = {
|
|
1407
1407
|
key: 0,
|
|
1408
1408
|
class: "flex justify-between text-sm font-medium text-gray-700 dark:text-gray-300"
|
|
1409
1409
|
};
|
|
1410
|
-
const _hoisted_3$
|
|
1410
|
+
const _hoisted_3$2 = {
|
|
1411
1411
|
key: 1,
|
|
1412
1412
|
class: "flex justify-between text-xs text-gray-500 dark:text-gray-400"
|
|
1413
1413
|
};
|
|
1414
|
-
const _sfc_main$
|
|
1414
|
+
const _sfc_main$2 = /* @__PURE__ */ vue.defineComponent({
|
|
1415
1415
|
__name: "RangeSlider",
|
|
1416
1416
|
props: {
|
|
1417
1417
|
modelValue: { default: () => [25, 75] },
|
|
@@ -1489,8 +1489,8 @@ const _sfc_main$1 = /* @__PURE__ */ vue.defineComponent({
|
|
|
1489
1489
|
}
|
|
1490
1490
|
};
|
|
1491
1491
|
return (_ctx, _cache) => {
|
|
1492
|
-
return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$
|
|
1493
|
-
__props.showLabels ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_2$
|
|
1492
|
+
return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$2, [
|
|
1493
|
+
__props.showLabels ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_2$2, [
|
|
1494
1494
|
vue.createElementVNode("span", null, vue.toDisplayString(__props.formatLabel(minValue.value)), 1),
|
|
1495
1495
|
vue.createElementVNode("span", null, vue.toDisplayString(__props.formatLabel(maxValue.value)), 1)
|
|
1496
1496
|
])) : vue.createCommentVNode("", true),
|
|
@@ -1523,7 +1523,7 @@ const _sfc_main$1 = /* @__PURE__ */ vue.defineComponent({
|
|
|
1523
1523
|
onMousedown: _cache[1] || (_cache[1] = ($event) => handleMouseDown("max"))
|
|
1524
1524
|
}, null, 38)
|
|
1525
1525
|
], 2),
|
|
1526
|
-
__props.showMinMax ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_3$
|
|
1526
|
+
__props.showMinMax ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_3$2, [
|
|
1527
1527
|
vue.createElementVNode("span", null, vue.toDisplayString(__props.formatLabel(__props.min)), 1),
|
|
1528
1528
|
vue.createElementVNode("span", null, vue.toDisplayString(__props.formatLabel(__props.max)), 1)
|
|
1529
1529
|
])) : vue.createCommentVNode("", true)
|
|
@@ -1531,18 +1531,18 @@ const _sfc_main$1 = /* @__PURE__ */ vue.defineComponent({
|
|
|
1531
1531
|
};
|
|
1532
1532
|
}
|
|
1533
1533
|
});
|
|
1534
|
-
const _hoisted_1 = ["aria-expanded", "aria-controls"];
|
|
1535
|
-
const _hoisted_2 = ["id", "name", "placeholder", "disabled", "aria-controls"];
|
|
1536
|
-
const _hoisted_3 = { class: "flex items-center gap-1" };
|
|
1537
|
-
const _hoisted_4 = ["id", "aria-label", "aria-multiselectable"];
|
|
1538
|
-
const _hoisted_5 = ["aria-selected", "aria-disabled", "disabled", "onClick"];
|
|
1539
|
-
const _hoisted_6 = { class: "flex-1" };
|
|
1540
|
-
const _hoisted_7 = {
|
|
1534
|
+
const _hoisted_1$1 = ["aria-expanded", "aria-controls"];
|
|
1535
|
+
const _hoisted_2$1 = ["id", "name", "placeholder", "disabled", "aria-controls"];
|
|
1536
|
+
const _hoisted_3$1 = { class: "flex items-center gap-1" };
|
|
1537
|
+
const _hoisted_4$1 = ["id", "aria-label", "aria-multiselectable"];
|
|
1538
|
+
const _hoisted_5$1 = ["aria-selected", "aria-disabled", "disabled", "onClick"];
|
|
1539
|
+
const _hoisted_6$1 = { class: "flex-1" };
|
|
1540
|
+
const _hoisted_7$1 = {
|
|
1541
1541
|
key: 1,
|
|
1542
1542
|
class: "px-3 py-2 text-center text-sm text-gray-500 dark:text-gray-400",
|
|
1543
1543
|
role: "status"
|
|
1544
1544
|
};
|
|
1545
|
-
const _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
1545
|
+
const _sfc_main$1 = /* @__PURE__ */ vue.defineComponent({
|
|
1546
1546
|
__name: "Combobox",
|
|
1547
1547
|
props: {
|
|
1548
1548
|
modelValue: {},
|
|
@@ -1673,10 +1673,10 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
|
1673
1673
|
class: "flex-1 border-none bg-transparent text-sm text-gray-900 outline-hidden placeholder:text-gray-400 dark:text-gray-100 dark:placeholder:text-gray-500",
|
|
1674
1674
|
onClick: _cache[1] || (_cache[1] = vue.withModifiers(() => {
|
|
1675
1675
|
}, ["stop"]))
|
|
1676
|
-
}, null, 8, _hoisted_2)), [
|
|
1676
|
+
}, null, 8, _hoisted_2$1)), [
|
|
1677
1677
|
[vue.vModelText, search.value]
|
|
1678
1678
|
]),
|
|
1679
|
-
vue.createElementVNode("div", _hoisted_3, [
|
|
1679
|
+
vue.createElementVNode("div", _hoisted_3$1, [
|
|
1680
1680
|
__props.clearable && selectedOptions.value.length > 0 && !__props.disabled ? (vue.openBlock(), vue.createElementBlock("button", {
|
|
1681
1681
|
key: 0,
|
|
1682
1682
|
type: "button",
|
|
@@ -1699,7 +1699,7 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
|
1699
1699
|
"aria-hidden": "true"
|
|
1700
1700
|
}, null, 8, ["class"])
|
|
1701
1701
|
])
|
|
1702
|
-
], 10, _hoisted_1),
|
|
1702
|
+
], 10, _hoisted_1$1),
|
|
1703
1703
|
(vue.openBlock(), vue.createBlock(vue.Teleport, {
|
|
1704
1704
|
to: teleportTarget.value,
|
|
1705
1705
|
disabled: teleportDisabled.value
|
|
@@ -1749,16 +1749,16 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
|
1749
1749
|
class: "size-3"
|
|
1750
1750
|
})) : vue.createCommentVNode("", true)
|
|
1751
1751
|
], 2)) : vue.createCommentVNode("", true),
|
|
1752
|
-
vue.createElementVNode("span", _hoisted_6, vue.toDisplayString(option.label), 1),
|
|
1752
|
+
vue.createElementVNode("span", _hoisted_6$1, vue.toDisplayString(option.label), 1),
|
|
1753
1753
|
!__props.multiple && isSelected(option) ? (vue.openBlock(), vue.createBlock(vue.unref(vue$1.Icon), {
|
|
1754
1754
|
key: 1,
|
|
1755
1755
|
icon: "lucide:check",
|
|
1756
1756
|
class: "size-4 text-primary",
|
|
1757
1757
|
"aria-hidden": "true"
|
|
1758
1758
|
})) : vue.createCommentVNode("", true)
|
|
1759
|
-
], 10, _hoisted_5);
|
|
1760
|
-
}), 128)) : (vue.openBlock(), vue.createElementBlock("div", _hoisted_7, vue.toDisplayString(__props.noResultsText), 1))
|
|
1761
|
-
], 8, _hoisted_4)) : vue.createCommentVNode("", true)
|
|
1759
|
+
], 10, _hoisted_5$1);
|
|
1760
|
+
}), 128)) : (vue.openBlock(), vue.createElementBlock("div", _hoisted_7$1, vue.toDisplayString(__props.noResultsText), 1))
|
|
1761
|
+
], 8, _hoisted_4$1)) : vue.createCommentVNode("", true)
|
|
1762
1762
|
]),
|
|
1763
1763
|
_: 1
|
|
1764
1764
|
})
|
|
@@ -1767,18 +1767,312 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
|
1767
1767
|
};
|
|
1768
1768
|
}
|
|
1769
1769
|
});
|
|
1770
|
+
const _hoisted_1 = { class: "relative" };
|
|
1771
|
+
const _hoisted_2 = {
|
|
1772
|
+
key: 0,
|
|
1773
|
+
class: "text-red-500 ml-0.5"
|
|
1774
|
+
};
|
|
1775
|
+
const _hoisted_3 = ["id", "disabled", "aria-invalid", "aria-describedby"];
|
|
1776
|
+
const _hoisted_4 = {
|
|
1777
|
+
key: 0,
|
|
1778
|
+
class: "flex items-center gap-2 flex-1"
|
|
1779
|
+
};
|
|
1780
|
+
const _hoisted_5 = { class: "flex h-8 w-8 items-center justify-center rounded bg-gray-100 dark:bg-gray-800" };
|
|
1781
|
+
const _hoisted_6 = { class: "text-gray-700 dark:text-gray-300 font-mono text-xs truncate" };
|
|
1782
|
+
const _hoisted_7 = {
|
|
1783
|
+
key: 1,
|
|
1784
|
+
class: "flex-1 text-gray-400 dark:text-gray-500"
|
|
1785
|
+
};
|
|
1786
|
+
const _hoisted_8 = { class: "relative mb-4" };
|
|
1787
|
+
const _hoisted_9 = ["placeholder"];
|
|
1788
|
+
const _hoisted_10 = {
|
|
1789
|
+
key: 0,
|
|
1790
|
+
class: "absolute right-3 top-1/2 -translate-y-1/2"
|
|
1791
|
+
};
|
|
1792
|
+
const _hoisted_11 = { class: "max-h-64 overflow-y-auto" };
|
|
1793
|
+
const _hoisted_12 = {
|
|
1794
|
+
key: 0,
|
|
1795
|
+
class: "py-8 text-center text-sm text-gray-500"
|
|
1796
|
+
};
|
|
1797
|
+
const _hoisted_13 = {
|
|
1798
|
+
key: 1,
|
|
1799
|
+
class: "grid grid-cols-8 gap-1"
|
|
1800
|
+
};
|
|
1801
|
+
const _hoisted_14 = ["title", "onClick"];
|
|
1802
|
+
const _hoisted_15 = { class: "mt-4 flex items-center justify-between border-t border-gray-200 pt-4 dark:border-gray-700" };
|
|
1803
|
+
const _hoisted_16 = { class: "text-xs text-gray-500" };
|
|
1804
|
+
const _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
1805
|
+
__name: "IconPicker",
|
|
1806
|
+
props: /* @__PURE__ */ vue.mergeModels({
|
|
1807
|
+
label: {},
|
|
1808
|
+
placeholder: { default: "Rechercher une icône..." },
|
|
1809
|
+
help: {},
|
|
1810
|
+
error: {},
|
|
1811
|
+
required: { type: Boolean },
|
|
1812
|
+
disabled: { type: Boolean },
|
|
1813
|
+
id: {},
|
|
1814
|
+
collections: { default: () => ["mdi", "heroicons", "lucide"] },
|
|
1815
|
+
limit: { default: 48 }
|
|
1816
|
+
}, {
|
|
1817
|
+
"modelValue": { default: "" },
|
|
1818
|
+
"modelModifiers": {}
|
|
1819
|
+
}),
|
|
1820
|
+
emits: ["update:modelValue"],
|
|
1821
|
+
setup(__props) {
|
|
1822
|
+
const props = __props;
|
|
1823
|
+
const modelValue = vue.useModel(__props, "modelValue");
|
|
1824
|
+
const { id: generatedId, related } = useId.useId({ prefix: "iconpicker", id: props.id });
|
|
1825
|
+
const inputId = vue.computed(() => props.id ?? generatedId.value);
|
|
1826
|
+
const helpId = vue.computed(() => related("help"));
|
|
1827
|
+
const searchQuery = vue.ref("");
|
|
1828
|
+
const isOpen = vue.ref(false);
|
|
1829
|
+
const isLoading = vue.ref(false);
|
|
1830
|
+
const searchResults = vue.ref([]);
|
|
1831
|
+
const popularIcons = [
|
|
1832
|
+
"mdi:heart",
|
|
1833
|
+
"mdi:star",
|
|
1834
|
+
"mdi:home",
|
|
1835
|
+
"mdi:account",
|
|
1836
|
+
"mdi:email",
|
|
1837
|
+
"mdi:phone",
|
|
1838
|
+
"mdi:calendar",
|
|
1839
|
+
"mdi:clock",
|
|
1840
|
+
"mdi:check",
|
|
1841
|
+
"mdi:close",
|
|
1842
|
+
"mdi:plus",
|
|
1843
|
+
"mdi:minus",
|
|
1844
|
+
"mdi:stethoscope",
|
|
1845
|
+
"mdi:hospital",
|
|
1846
|
+
"mdi:medical-bag",
|
|
1847
|
+
"mdi:pill",
|
|
1848
|
+
"mdi:heart-pulse",
|
|
1849
|
+
"mdi:tooth",
|
|
1850
|
+
"mdi:eye",
|
|
1851
|
+
"mdi:brain",
|
|
1852
|
+
"mdi:lungs",
|
|
1853
|
+
"mdi:bone",
|
|
1854
|
+
"heroicons:heart",
|
|
1855
|
+
"heroicons:star",
|
|
1856
|
+
"heroicons:home",
|
|
1857
|
+
"heroicons:user",
|
|
1858
|
+
"heroicons:envelope",
|
|
1859
|
+
"heroicons:phone",
|
|
1860
|
+
"heroicons:calendar",
|
|
1861
|
+
"heroicons:clock",
|
|
1862
|
+
"heroicons:check",
|
|
1863
|
+
"heroicons:x-mark",
|
|
1864
|
+
"heroicons:plus",
|
|
1865
|
+
"heroicons:minus",
|
|
1866
|
+
"lucide:heart",
|
|
1867
|
+
"lucide:star",
|
|
1868
|
+
"lucide:home",
|
|
1869
|
+
"lucide:user",
|
|
1870
|
+
"lucide:mail",
|
|
1871
|
+
"lucide:phone",
|
|
1872
|
+
"lucide:calendar",
|
|
1873
|
+
"lucide:clock",
|
|
1874
|
+
"lucide:check",
|
|
1875
|
+
"lucide:x",
|
|
1876
|
+
"lucide:plus",
|
|
1877
|
+
"lucide:minus"
|
|
1878
|
+
];
|
|
1879
|
+
const displayedIcons = vue.computed(() => {
|
|
1880
|
+
if (searchQuery.value && searchResults.value.length > 0) {
|
|
1881
|
+
return searchResults.value;
|
|
1882
|
+
}
|
|
1883
|
+
return popularIcons;
|
|
1884
|
+
});
|
|
1885
|
+
const hasError = vue.computed(() => props.error && typeof props.error === "string");
|
|
1886
|
+
async function searchIcons(query) {
|
|
1887
|
+
if (!query || query.length < 2) {
|
|
1888
|
+
searchResults.value = [];
|
|
1889
|
+
return;
|
|
1890
|
+
}
|
|
1891
|
+
isLoading.value = true;
|
|
1892
|
+
try {
|
|
1893
|
+
const collectionsParam = props.collections.join(",");
|
|
1894
|
+
const response = await fetch(
|
|
1895
|
+
`https://api.iconify.design/search?query=${encodeURIComponent(query)}&limit=${props.limit}&prefixes=${collectionsParam}`
|
|
1896
|
+
);
|
|
1897
|
+
const data = await response.json();
|
|
1898
|
+
searchResults.value = data.icons || [];
|
|
1899
|
+
} catch (error) {
|
|
1900
|
+
console.error("Failed to search icons:", error);
|
|
1901
|
+
searchResults.value = [];
|
|
1902
|
+
} finally {
|
|
1903
|
+
isLoading.value = false;
|
|
1904
|
+
}
|
|
1905
|
+
}
|
|
1906
|
+
const debouncedSearch = index.useDebounceFn(searchIcons, 300);
|
|
1907
|
+
vue.watch(searchQuery, (query) => {
|
|
1908
|
+
debouncedSearch(query);
|
|
1909
|
+
});
|
|
1910
|
+
function selectIcon(icon) {
|
|
1911
|
+
modelValue.value = icon;
|
|
1912
|
+
isOpen.value = false;
|
|
1913
|
+
searchQuery.value = "";
|
|
1914
|
+
}
|
|
1915
|
+
function clearSelection() {
|
|
1916
|
+
modelValue.value = "";
|
|
1917
|
+
}
|
|
1918
|
+
function openPicker() {
|
|
1919
|
+
if (!props.disabled) {
|
|
1920
|
+
isOpen.value = true;
|
|
1921
|
+
}
|
|
1922
|
+
}
|
|
1923
|
+
function closePicker() {
|
|
1924
|
+
isOpen.value = false;
|
|
1925
|
+
searchQuery.value = "";
|
|
1926
|
+
}
|
|
1927
|
+
return (_ctx, _cache) => {
|
|
1928
|
+
return vue.openBlock(), vue.createElementBlock("div", _hoisted_1, [
|
|
1929
|
+
__props.label ? (vue.openBlock(), vue.createBlock(_sfc_main$e, {
|
|
1930
|
+
key: 0,
|
|
1931
|
+
"html-for": inputId.value,
|
|
1932
|
+
error: __props.error
|
|
1933
|
+
}, {
|
|
1934
|
+
default: vue.withCtx(() => [
|
|
1935
|
+
vue.createTextVNode(vue.toDisplayString(__props.label) + " ", 1),
|
|
1936
|
+
__props.required ? (vue.openBlock(), vue.createElementBlock("span", _hoisted_2, "*")) : vue.createCommentVNode("", true)
|
|
1937
|
+
]),
|
|
1938
|
+
_: 1
|
|
1939
|
+
}, 8, ["html-for", "error"])) : vue.createCommentVNode("", true),
|
|
1940
|
+
vue.createElementVNode("button", {
|
|
1941
|
+
id: inputId.value,
|
|
1942
|
+
type: "button",
|
|
1943
|
+
disabled: __props.disabled,
|
|
1944
|
+
"aria-invalid": hasError.value || void 0,
|
|
1945
|
+
"aria-describedby": hasError.value ? helpId.value : void 0,
|
|
1946
|
+
class: vue.normalizeClass(["mt-1 flex w-full items-center gap-3 rounded-md border bg-white px-3 py-2 text-left text-sm shadow-sm transition-colors focus:outline-none focus:ring-2 focus:ring-primary dark:bg-gray-900", [
|
|
1947
|
+
hasError.value ? "border-red-500 focus:border-red-500 focus:ring-red-500" : "border-gray-300 focus:border-primary dark:border-gray-700",
|
|
1948
|
+
__props.disabled ? "cursor-not-allowed bg-gray-50 dark:bg-gray-950" : "cursor-pointer hover:border-gray-400 dark:hover:border-gray-600"
|
|
1949
|
+
]]),
|
|
1950
|
+
onClick: openPicker
|
|
1951
|
+
}, [
|
|
1952
|
+
modelValue.value ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_4, [
|
|
1953
|
+
vue.createElementVNode("div", _hoisted_5, [
|
|
1954
|
+
vue.createVNode(vue.unref(vue$1.Icon), {
|
|
1955
|
+
icon: modelValue.value,
|
|
1956
|
+
class: "h-5 w-5 text-gray-700 dark:text-gray-300"
|
|
1957
|
+
}, null, 8, ["icon"])
|
|
1958
|
+
]),
|
|
1959
|
+
vue.createElementVNode("span", _hoisted_6, vue.toDisplayString(modelValue.value), 1)
|
|
1960
|
+
])) : (vue.openBlock(), vue.createElementBlock("span", _hoisted_7, vue.toDisplayString(__props.placeholder), 1)),
|
|
1961
|
+
modelValue.value && !__props.disabled ? (vue.openBlock(), vue.createElementBlock("button", {
|
|
1962
|
+
key: 2,
|
|
1963
|
+
type: "button",
|
|
1964
|
+
class: "p-1 text-gray-400 hover:text-gray-600 dark:hover:text-gray-300",
|
|
1965
|
+
onClick: vue.withModifiers(clearSelection, ["stop"])
|
|
1966
|
+
}, [
|
|
1967
|
+
vue.createVNode(vue.unref(vue$1.Icon), {
|
|
1968
|
+
icon: "lucide:x",
|
|
1969
|
+
class: "h-4 w-4"
|
|
1970
|
+
})
|
|
1971
|
+
])) : vue.createCommentVNode("", true),
|
|
1972
|
+
vue.createVNode(vue.unref(vue$1.Icon), {
|
|
1973
|
+
icon: "lucide:chevron-down",
|
|
1974
|
+
class: "h-4 w-4 text-gray-400"
|
|
1975
|
+
})
|
|
1976
|
+
], 10, _hoisted_3),
|
|
1977
|
+
__props.help && !hasError.value ? (vue.openBlock(), vue.createBlock(_sfc_main$d, {
|
|
1978
|
+
key: 1,
|
|
1979
|
+
id: helpId.value
|
|
1980
|
+
}, {
|
|
1981
|
+
default: vue.withCtx(() => [
|
|
1982
|
+
vue.createTextVNode(vue.toDisplayString(__props.help), 1)
|
|
1983
|
+
]),
|
|
1984
|
+
_: 1
|
|
1985
|
+
}, 8, ["id"])) : vue.createCommentVNode("", true),
|
|
1986
|
+
hasError.value ? (vue.openBlock(), vue.createBlock(_sfc_main$d, {
|
|
1987
|
+
key: 2,
|
|
1988
|
+
id: helpId.value,
|
|
1989
|
+
error: true
|
|
1990
|
+
}, {
|
|
1991
|
+
default: vue.withCtx(() => [
|
|
1992
|
+
vue.createTextVNode(vue.toDisplayString(__props.error), 1)
|
|
1993
|
+
]),
|
|
1994
|
+
_: 1
|
|
1995
|
+
}, 8, ["id"])) : vue.createCommentVNode("", true),
|
|
1996
|
+
(vue.openBlock(), vue.createBlock(vue.Teleport, { to: "body" }, [
|
|
1997
|
+
isOpen.value ? (vue.openBlock(), vue.createElementBlock("div", {
|
|
1998
|
+
key: 0,
|
|
1999
|
+
class: "fixed inset-0 z-50",
|
|
2000
|
+
onClick: closePicker
|
|
2001
|
+
}, [
|
|
2002
|
+
vue.createElementVNode("div", {
|
|
2003
|
+
class: "absolute left-1/2 top-1/2 -translate-x-1/2 -translate-y-1/2 w-full max-w-md rounded-lg border border-gray-200 bg-white p-4 shadow-xl dark:border-gray-700 dark:bg-gray-900",
|
|
2004
|
+
onClick: _cache[1] || (_cache[1] = vue.withModifiers(() => {
|
|
2005
|
+
}, ["stop"]))
|
|
2006
|
+
}, [
|
|
2007
|
+
vue.createElementVNode("div", _hoisted_8, [
|
|
2008
|
+
vue.createVNode(vue.unref(vue$1.Icon), {
|
|
2009
|
+
icon: "lucide:search",
|
|
2010
|
+
class: "absolute left-3 top-1/2 h-4 w-4 -translate-y-1/2 text-gray-400"
|
|
2011
|
+
}),
|
|
2012
|
+
vue.withDirectives(vue.createElementVNode("input", {
|
|
2013
|
+
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => searchQuery.value = $event),
|
|
2014
|
+
type: "text",
|
|
2015
|
+
placeholder: __props.placeholder,
|
|
2016
|
+
class: "w-full rounded-md border border-gray-300 bg-white py-2 pl-10 pr-4 text-sm text-gray-800 placeholder-gray-400 focus:border-primary focus:outline-none focus:ring-1 focus:ring-primary dark:border-gray-700 dark:bg-gray-800 dark:text-gray-200 dark:placeholder-gray-500",
|
|
2017
|
+
autofocus: ""
|
|
2018
|
+
}, null, 8, _hoisted_9), [
|
|
2019
|
+
[vue.vModelText, searchQuery.value]
|
|
2020
|
+
]),
|
|
2021
|
+
isLoading.value ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_10, [
|
|
2022
|
+
vue.createVNode(vue.unref(vue$1.Icon), {
|
|
2023
|
+
icon: "lucide:loader-2",
|
|
2024
|
+
class: "h-4 w-4 animate-spin text-gray-400"
|
|
2025
|
+
})
|
|
2026
|
+
])) : vue.createCommentVNode("", true)
|
|
2027
|
+
]),
|
|
2028
|
+
vue.createElementVNode("div", _hoisted_11, [
|
|
2029
|
+
displayedIcons.value.length === 0 && searchQuery.value ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_12, ' Aucune icône trouvée pour "' + vue.toDisplayString(searchQuery.value) + '" ', 1)) : (vue.openBlock(), vue.createElementBlock("div", _hoisted_13, [
|
|
2030
|
+
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(displayedIcons.value, (icon) => {
|
|
2031
|
+
return vue.openBlock(), vue.createElementBlock("button", {
|
|
2032
|
+
key: icon,
|
|
2033
|
+
type: "button",
|
|
2034
|
+
class: vue.normalizeClass(["flex h-9 w-9 items-center justify-center rounded transition-colors", [
|
|
2035
|
+
modelValue.value === icon ? "bg-primary text-white" : "hover:bg-gray-100 dark:hover:bg-gray-800 text-gray-700 dark:text-gray-300"
|
|
2036
|
+
]]),
|
|
2037
|
+
title: icon,
|
|
2038
|
+
onClick: ($event) => selectIcon(icon)
|
|
2039
|
+
}, [
|
|
2040
|
+
vue.createVNode(vue.unref(vue$1.Icon), {
|
|
2041
|
+
icon,
|
|
2042
|
+
class: "h-5 w-5"
|
|
2043
|
+
}, null, 8, ["icon"])
|
|
2044
|
+
], 10, _hoisted_14);
|
|
2045
|
+
}), 128))
|
|
2046
|
+
]))
|
|
2047
|
+
]),
|
|
2048
|
+
vue.createElementVNode("div", _hoisted_15, [
|
|
2049
|
+
vue.createElementVNode("p", _hoisted_16, vue.toDisplayString(searchQuery.value ? `${displayedIcons.value.length} résultats` : "Icônes populaires"), 1),
|
|
2050
|
+
vue.createElementVNode("button", {
|
|
2051
|
+
type: "button",
|
|
2052
|
+
class: "text-sm text-gray-500 hover:text-gray-700 dark:hover:text-gray-300",
|
|
2053
|
+
onClick: closePicker
|
|
2054
|
+
}, " Fermer ")
|
|
2055
|
+
])
|
|
2056
|
+
])
|
|
2057
|
+
])) : vue.createCommentVNode("", true)
|
|
2058
|
+
]))
|
|
2059
|
+
]);
|
|
2060
|
+
};
|
|
2061
|
+
}
|
|
2062
|
+
});
|
|
1770
2063
|
exports.Slider = Slider;
|
|
1771
|
-
exports._sfc_main = _sfc_main$
|
|
1772
|
-
exports._sfc_main$1 = _sfc_main$
|
|
1773
|
-
exports._sfc_main$10 = _sfc_main$
|
|
1774
|
-
exports._sfc_main$11 = _sfc_main$
|
|
1775
|
-
exports._sfc_main$12 = _sfc_main;
|
|
1776
|
-
exports._sfc_main$
|
|
1777
|
-
exports._sfc_main$
|
|
1778
|
-
exports._sfc_main$
|
|
1779
|
-
exports._sfc_main$
|
|
1780
|
-
exports._sfc_main$
|
|
1781
|
-
exports._sfc_main$
|
|
1782
|
-
exports._sfc_main$
|
|
1783
|
-
exports._sfc_main$
|
|
1784
|
-
|
|
2064
|
+
exports._sfc_main = _sfc_main$e;
|
|
2065
|
+
exports._sfc_main$1 = _sfc_main$d;
|
|
2066
|
+
exports._sfc_main$10 = _sfc_main$3;
|
|
2067
|
+
exports._sfc_main$11 = _sfc_main$2;
|
|
2068
|
+
exports._sfc_main$12 = _sfc_main$1;
|
|
2069
|
+
exports._sfc_main$13 = _sfc_main;
|
|
2070
|
+
exports._sfc_main$2 = _sfc_main$c;
|
|
2071
|
+
exports._sfc_main$3 = _sfc_main$b;
|
|
2072
|
+
exports._sfc_main$4 = _sfc_main$a;
|
|
2073
|
+
exports._sfc_main$5 = _sfc_main$9;
|
|
2074
|
+
exports._sfc_main$6 = _sfc_main$8;
|
|
2075
|
+
exports._sfc_main$7 = _sfc_main$6;
|
|
2076
|
+
exports._sfc_main$8 = _sfc_main$5;
|
|
2077
|
+
exports._sfc_main$9 = _sfc_main$4;
|
|
2078
|
+
//# sourceMappingURL=IconPicker.vue_vue_type_script_setup_true_lang-agY_E72J.cjs.map
|