cisse-vue-ui 0.5.17 → 0.5.22
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/README.md +666 -666
- package/dist/Button.vue_vue_type_script_setup_true_lang-DKE8elsf.js +236 -0
- package/dist/Button.vue_vue_type_script_setup_true_lang-DKE8elsf.js.map +1 -0
- package/dist/Button.vue_vue_type_script_setup_true_lang-DrGM65ny.cjs +235 -0
- package/dist/Button.vue_vue_type_script_setup_true_lang-DrGM65ny.cjs.map +1 -0
- package/dist/{RangeSlider.vue_vue_type_script_setup_true_lang-y3zIxWfI.js → Combobox.vue_vue_type_script_setup_true_lang-DhcLb6DX.js} +408 -185
- package/dist/Combobox.vue_vue_type_script_setup_true_lang-DhcLb6DX.js.map +1 -0
- package/dist/{RangeSlider.vue_vue_type_script_setup_true_lang-Cv1OwT9S.cjs → Combobox.vue_vue_type_script_setup_true_lang-FdUrjmSG.cjs} +435 -212
- package/dist/Combobox.vue_vue_type_script_setup_true_lang-FdUrjmSG.cjs.map +1 -0
- package/dist/{ListSkeleton.vue_vue_type_script_setup_true_lang-Bech-H58.js → ConfirmDialog.vue_vue_type_script_setup_true_lang-CNucAMQg.js} +226 -248
- package/dist/ConfirmDialog.vue_vue_type_script_setup_true_lang-CNucAMQg.js.map +1 -0
- package/dist/{ListSkeleton.vue_vue_type_script_setup_true_lang-CHoagJ0-.cjs → ConfirmDialog.vue_vue_type_script_setup_true_lang-DXb9wQQv.cjs} +225 -247
- package/dist/ConfirmDialog.vue_vue_type_script_setup_true_lang-DXb9wQQv.cjs.map +1 -0
- package/dist/{Timeline.vue_vue_type_script_setup_true_lang-CuPF4MPe.js → DarkModeToggle.vue_vue_type_script_setup_true_lang-43fxlbro.js} +209 -415
- package/dist/DarkModeToggle.vue_vue_type_script_setup_true_lang-43fxlbro.js.map +1 -0
- package/dist/{Timeline.vue_vue_type_script_setup_true_lang-CqeiZOID.cjs → DarkModeToggle.vue_vue_type_script_setup_true_lang-BoB48313.cjs} +234 -440
- package/dist/DarkModeToggle.vue_vue_type_script_setup_true_lang-BoB48313.cjs.map +1 -0
- package/dist/Dropdown.vue_vue_type_script_setup_true_lang-C3pr8BwC.js.map +1 -1
- package/dist/Dropdown.vue_vue_type_script_setup_true_lang-DKxcVBKu.cjs.map +1 -1
- package/dist/PageLayout.vue_vue_type_script_setup_true_lang-D22uNeS1.cjs.map +1 -1
- package/dist/PageLayout.vue_vue_type_script_setup_true_lang-kT7np2ir.js.map +1 -1
- package/dist/cisse-vue-ui.css +51 -51
- package/dist/components/core/AccordionItem.stories.d.ts +10 -0
- package/dist/components/core/Avatar.vue.d.ts +1 -1
- package/dist/components/core/Button.vue.d.ts +1 -1
- package/dist/components/core/CardComponent.stories.d.ts +3 -0
- package/dist/components/core/CardComponent.vue.d.ts +15 -2
- package/dist/components/core/DarkModeToggle.stories.d.ts +15 -0
- package/dist/components/core/DarkModeToggle.test.d.ts +1 -0
- package/dist/components/core/DarkModeToggle.vue.d.ts +21 -0
- package/dist/components/core/MobileList.stories.d.ts +13 -0
- package/dist/components/core/MobileList.vue.d.ts +6 -0
- package/dist/components/core/ResponsiveList.stories.d.ts +15 -0
- package/dist/components/core/ResponsiveList.vue.d.ts +6 -0
- package/dist/components/core/TabPanel.stories.d.ts +8 -0
- package/dist/components/core/TableAction.stories.d.ts +14 -0
- package/dist/components/core/TableComponent.stories.d.ts +2 -0
- package/dist/components/core/TableComponent.vue.d.ts +6 -0
- package/dist/components/core/index.cjs +22 -20
- package/dist/components/core/index.cjs.map +1 -1
- package/dist/components/core/index.d.ts +2 -0
- package/dist/components/core/index.js +16 -14
- package/dist/components/core/index.js.map +1 -1
- package/dist/components/feedback/CardSkeleton.stories.d.ts +11 -0
- package/dist/components/feedback/CardSkeleton.test.d.ts +1 -0
- package/dist/components/feedback/CardSkeleton.vue.d.ts +1 -1
- package/dist/components/feedback/ConfirmDialog.stories.d.ts +12 -0
- package/dist/components/feedback/ConfirmDialog.test.d.ts +1 -0
- package/dist/components/feedback/ConfirmDialog.vue.d.ts +53 -0
- package/dist/components/feedback/ListSkeleton.stories.d.ts +12 -0
- package/dist/components/feedback/ListSkeleton.test.d.ts +1 -0
- package/dist/components/feedback/ListSkeleton.vue.d.ts +1 -1
- package/dist/components/feedback/Modal.vue.d.ts +11 -2
- package/dist/components/feedback/NotificationComponent.stories.d.ts +14 -0
- package/dist/components/feedback/NotificationList.stories.d.ts +11 -0
- package/dist/components/feedback/Progress.vue.d.ts +1 -1
- package/dist/components/feedback/Skeleton.vue.d.ts +1 -1
- package/dist/components/feedback/TableSkeleton.stories.d.ts +12 -0
- package/dist/components/feedback/TableSkeleton.test.d.ts +1 -0
- package/dist/components/feedback/TableSkeleton.vue.d.ts +1 -1
- package/dist/components/feedback/ToastContainer.stories.d.ts +15 -0
- package/dist/components/feedback/index.cjs +17 -15
- package/dist/components/feedback/index.cjs.map +1 -1
- package/dist/components/feedback/index.d.ts +2 -0
- package/dist/components/feedback/index.js +6 -4
- package/dist/components/feedback/index.js.map +1 -1
- package/dist/components/form/ColorPicker.vue.d.ts +3 -0
- package/dist/components/form/Combobox.stories.d.ts +15 -0
- package/dist/components/form/Combobox.test.d.ts +1 -0
- package/dist/components/form/Combobox.vue.d.ts +46 -0
- package/dist/components/form/FileUpload.vue.d.ts +1 -1
- package/dist/components/form/FormHelp.stories.d.ts +11 -0
- package/dist/components/form/FormLabel.stories.d.ts +12 -0
- package/dist/components/form/FormSelect.stories.d.ts +2 -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 +2 -0
- package/dist/components/form/index.js +3 -2
- package/dist/components/index.cjs +55 -51
- package/dist/components/index.cjs.map +1 -1
- package/dist/components/index.js +36 -32
- package/dist/components/index.js.map +1 -1
- package/dist/composables/index.cjs +3 -2
- package/dist/composables/index.cjs.map +1 -1
- package/dist/composables/index.js +9 -8
- package/dist/composables/index.js.map +1 -1
- package/dist/index-D7HVSFi2.cjs +337 -0
- package/dist/index-D7HVSFi2.cjs.map +1 -0
- package/dist/index-DZYqrXV0.js +75 -0
- package/dist/index-DZYqrXV0.js.map +1 -0
- package/dist/index-Dghdw1yo.js +338 -0
- package/dist/index-Dghdw1yo.js.map +1 -0
- package/dist/index-DjEv91o4.cjs +74 -0
- package/dist/index-DjEv91o4.cjs.map +1 -0
- package/dist/index.cjs +59 -54
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +46 -41
- package/dist/index.js.map +1 -1
- package/dist/style.css +1 -1
- package/dist/useDarkMode-Cl5QWTlC.js +53 -0
- package/dist/useDarkMode-Cl5QWTlC.js.map +1 -0
- package/dist/useDarkMode-DLZcJEUQ.cjs +52 -0
- package/dist/useDarkMode-DLZcJEUQ.cjs.map +1 -0
- package/dist/useDropdown-DHFnd259.cjs.map +1 -1
- package/dist/useDropdown-iVu14E6s.js.map +1 -1
- package/dist/{useToast-CRh_sG82.cjs → useToast-Bk60GArg.cjs} +1 -50
- package/dist/useToast-Bk60GArg.cjs.map +1 -0
- package/dist/{useToast-DwFOkewC.js → useToast-ina5g3mj.js} +6 -55
- package/dist/useToast-ina5g3mj.js.map +1 -0
- package/package.json +168 -168
- package/dist/Checkbox.vue_vue_type_script_setup_true_lang-B-nLCCNY.js +0 -54
- package/dist/Checkbox.vue_vue_type_script_setup_true_lang-B-nLCCNY.js.map +0 -1
- package/dist/Checkbox.vue_vue_type_script_setup_true_lang-DIoHDji4.cjs +0 -53
- package/dist/Checkbox.vue_vue_type_script_setup_true_lang-DIoHDji4.cjs.map +0 -1
- package/dist/ListSkeleton.vue_vue_type_script_setup_true_lang-Bech-H58.js.map +0 -1
- package/dist/ListSkeleton.vue_vue_type_script_setup_true_lang-CHoagJ0-.cjs.map +0 -1
- package/dist/RangeSlider.vue_vue_type_script_setup_true_lang-Cv1OwT9S.cjs.map +0 -1
- package/dist/RangeSlider.vue_vue_type_script_setup_true_lang-y3zIxWfI.js.map +0 -1
- package/dist/Timeline.vue_vue_type_script_setup_true_lang-CqeiZOID.cjs.map +0 -1
- package/dist/Timeline.vue_vue_type_script_setup_true_lang-CuPF4MPe.js.map +0 -1
- package/dist/index-5Ru0o5KY.js +0 -71
- package/dist/index-5Ru0o5KY.js.map +0 -1
- package/dist/index-CnDEGRt-.cjs +0 -70
- package/dist/index-CnDEGRt-.cjs.map +0 -1
- package/dist/useToast-CRh_sG82.cjs.map +0 -1
- package/dist/useToast-DwFOkewC.js.map +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { readonly, ref
|
|
1
|
+
import { readonly, ref } from "vue";
|
|
2
2
|
var IDX = 256, HEX = [], SIZE = 256, BUFFER;
|
|
3
3
|
while (IDX--) HEX[IDX] = (IDX + 256).toString(16).substring(1);
|
|
4
4
|
function uid(len) {
|
|
@@ -48,54 +48,6 @@ function useNotifications() {
|
|
|
48
48
|
clear
|
|
49
49
|
};
|
|
50
50
|
}
|
|
51
|
-
function useDarkMode(options = {}) {
|
|
52
|
-
const {
|
|
53
|
-
selector = "html",
|
|
54
|
-
attribute = "class",
|
|
55
|
-
storageKey = "dark-mode",
|
|
56
|
-
defaultValue = false
|
|
57
|
-
} = options;
|
|
58
|
-
const isDark = ref(defaultValue);
|
|
59
|
-
const getInitialValue = () => {
|
|
60
|
-
if (typeof window === "undefined") return defaultValue;
|
|
61
|
-
const stored = localStorage.getItem(storageKey);
|
|
62
|
-
if (stored !== null) {
|
|
63
|
-
return stored === "true";
|
|
64
|
-
}
|
|
65
|
-
return window.matchMedia("(prefers-color-scheme: dark)").matches;
|
|
66
|
-
};
|
|
67
|
-
const updateDOM = (dark) => {
|
|
68
|
-
if (typeof document === "undefined") return;
|
|
69
|
-
const element = document.querySelector(selector);
|
|
70
|
-
if (!element) return;
|
|
71
|
-
if (attribute === "class") {
|
|
72
|
-
element.classList.toggle("dark", dark);
|
|
73
|
-
} else {
|
|
74
|
-
element.setAttribute(attribute, dark ? "dark" : "light");
|
|
75
|
-
}
|
|
76
|
-
};
|
|
77
|
-
const toggle = () => {
|
|
78
|
-
isDark.value = !isDark.value;
|
|
79
|
-
};
|
|
80
|
-
const set = (value) => {
|
|
81
|
-
isDark.value = value;
|
|
82
|
-
};
|
|
83
|
-
watch(isDark, (newValue) => {
|
|
84
|
-
updateDOM(newValue);
|
|
85
|
-
if (typeof localStorage !== "undefined") {
|
|
86
|
-
localStorage.setItem(storageKey, String(newValue));
|
|
87
|
-
}
|
|
88
|
-
});
|
|
89
|
-
onMounted(() => {
|
|
90
|
-
isDark.value = getInitialValue();
|
|
91
|
-
updateDOM(isDark.value);
|
|
92
|
-
});
|
|
93
|
-
return {
|
|
94
|
-
isDark,
|
|
95
|
-
toggle,
|
|
96
|
-
set
|
|
97
|
-
};
|
|
98
|
-
}
|
|
99
51
|
function useExportCSV() {
|
|
100
52
|
const escapeCSV = (value) => {
|
|
101
53
|
if (value === null || value === void 0) return "";
|
|
@@ -216,11 +168,10 @@ function useToast() {
|
|
|
216
168
|
};
|
|
217
169
|
}
|
|
218
170
|
export {
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
useToast as e,
|
|
171
|
+
useExportCSV as a,
|
|
172
|
+
useModal as b,
|
|
173
|
+
useModals as c,
|
|
174
|
+
useToast as d,
|
|
224
175
|
useNotifications as u
|
|
225
176
|
};
|
|
226
|
-
//# sourceMappingURL=useToast-
|
|
177
|
+
//# sourceMappingURL=useToast-ina5g3mj.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useToast-ina5g3mj.js","sources":["../node_modules/uid/dist/index.mjs","../src/composables/useNotifications.ts","../src/composables/useExportCSV.ts","../src/composables/useModal.ts","../src/composables/useToast.ts"],"sourcesContent":["var IDX=256, HEX=[], SIZE=256, BUFFER;\nwhile (IDX--) HEX[IDX] = (IDX + 256).toString(16).substring(1);\n\nexport function uid(len) {\n\tvar i=0, tmp=(len || 11);\n\tif (!BUFFER || ((IDX + tmp) > SIZE*2)) {\n\t\tfor (BUFFER='',IDX=0; i < SIZE; i++) {\n\t\t\tBUFFER += HEX[Math.random() * 256 | 0];\n\t\t}\n\t}\n\n\treturn BUFFER.substring(IDX, IDX++ + tmp);\n}\n","import { ref, readonly } from 'vue'\r\nimport { uid } from 'uid'\r\nimport type { Notification, NotificationType, NotificationOptions } from '@/types'\r\n\r\n// Global state (singleton pattern) - shared across all useNotifications() calls\r\nconst notifications = ref<Notification[]>([])\r\n\r\n/**\r\n * Composable for managing notifications/toasts\r\n * Uses singleton pattern - all components share the same notifications state\r\n */\r\nexport function useNotifications() {\r\n\r\n const notify = (\r\n type: NotificationType,\r\n message: string,\r\n options: NotificationOptions = {},\r\n ): string => {\r\n const id = uid()\r\n const notification: Notification = {\r\n id,\r\n type,\r\n message,\r\n title: options.title ?? null,\r\n duration: options.duration ?? 5000,\r\n }\r\n\r\n notifications.value.push(notification)\r\n\r\n if (notification.duration && notification.duration > 0) {\r\n setTimeout(() => remove(id), notification.duration)\r\n }\r\n\r\n return id\r\n }\r\n\r\n const success = (message: string, options?: NotificationOptions) =>\r\n notify('success', message, options)\r\n\r\n const warning = (message: string, options?: NotificationOptions) =>\r\n notify('warning', message, options)\r\n\r\n const error = (message: string, options?: NotificationOptions) =>\r\n notify('error', message, options)\r\n\r\n const info = (message: string, options?: NotificationOptions) =>\r\n notify('info', message, options)\r\n\r\n const remove = (id: string) => {\r\n notifications.value = notifications.value.filter((n) => n.id !== id)\r\n }\r\n\r\n const clear = () => {\r\n notifications.value = []\r\n }\r\n\r\n return {\r\n notifications: readonly(notifications),\r\n notify,\r\n success,\r\n warning,\r\n error,\r\n info,\r\n remove,\r\n clear,\r\n }\r\n}\r\n","/**\n * Composable for exporting data to CSV format\n */\nexport function useExportCSV() {\n const escapeCSV = (value: unknown): string => {\n if (value === null || value === undefined) return ''\n const str = String(value)\n if (str.includes(',') || str.includes('\"') || str.includes('\\n')) {\n return `\"${str.replace(/\"/g, '\"\"')}\"`\n }\n return str\n }\n\n const exportToCSV = <T extends Record<string, unknown>>(\n data: T[],\n columns: { key: keyof T; label: string }[],\n filename: string = 'export.csv',\n ) => {\n if (!data || data.length === 0) {\n console.warn('No data to export')\n return\n }\n\n // Create header row\n const headers = columns.map((col) => escapeCSV(col.label)).join(',')\n\n // Create data rows\n const rows = data.map((item) =>\n columns.map((col) => escapeCSV(item[col.key])).join(','),\n )\n\n // Combine header and rows\n const csv = [headers, ...rows].join('\\n')\n\n // Create and trigger download\n const blob = new Blob([csv], { type: 'text/csv;charset=utf-8;' })\n const url = URL.createObjectURL(blob)\n const link = document.createElement('a')\n link.setAttribute('href', url)\n link.setAttribute('download', filename)\n link.style.visibility = 'hidden'\n document.body.appendChild(link)\n link.click()\n document.body.removeChild(link)\n URL.revokeObjectURL(url)\n }\n\n return {\n exportToCSV,\n escapeCSV,\n }\n}\n","import { ref, type Ref } from 'vue'\r\n\r\nexport interface UseModalReturn<T = unknown> {\r\n /** Whether the modal is currently open */\r\n isOpen: Ref<boolean>\r\n /** Data associated with the modal (e.g., item being edited) */\r\n data: Ref<T | null>\r\n /** Open the modal, optionally with data */\r\n open: (newData?: T) => void\r\n /** Close the modal and clear data */\r\n close: () => void\r\n /** Toggle the modal state */\r\n toggle: () => void\r\n}\r\n\r\n/**\r\n * Composable for managing modal state\r\n *\r\n * @example\r\n * ```ts\r\n * // Simple modal\r\n * const createModal = useModal()\r\n * createModal.open()\r\n * createModal.close()\r\n *\r\n * // Modal with data (e.g., for editing)\r\n * const editModal = useModal<User>()\r\n * editModal.open(selectedUser)\r\n * // Access editModal.data.value in modal\r\n *\r\n * // With onClose callback\r\n * const deleteModal = useModal<Item>({ onClose: () => refetch() })\r\n * ```\r\n */\r\nexport function useModal<T = unknown>(options?: {\r\n /** Initial open state */\r\n initialOpen?: boolean\r\n /** Initial data */\r\n initialData?: T | null\r\n /** Callback when modal opens */\r\n onOpen?: (data: T | null) => void\r\n /** Callback when modal closes */\r\n onClose?: () => void\r\n}): UseModalReturn<T> {\r\n const {\r\n initialOpen = false,\r\n initialData = null,\r\n onOpen,\r\n onClose,\r\n } = options ?? {}\r\n\r\n const isOpen = ref(initialOpen)\r\n const data = ref<T | null>(initialData) as Ref<T | null>\r\n\r\n const open = (newData?: T) => {\r\n data.value = newData ?? null\r\n isOpen.value = true\r\n onOpen?.(data.value)\r\n }\r\n\r\n const close = () => {\r\n isOpen.value = false\r\n data.value = null\r\n onClose?.()\r\n }\r\n\r\n const toggle = () => {\r\n if (isOpen.value) {\r\n close()\r\n } else {\r\n open()\r\n }\r\n }\r\n\r\n return {\r\n isOpen,\r\n data,\r\n open,\r\n close,\r\n toggle,\r\n }\r\n}\r\n\r\n/**\r\n * Create multiple related modals at once\r\n * Useful when a page has several modals (create, edit, delete, etc.)\r\n *\r\n * @example\r\n * ```ts\r\n * const modals = useModals({\r\n * create: useModal(),\r\n * edit: useModal<User>(),\r\n * delete: useModal<User>(),\r\n * })\r\n *\r\n * modals.create.open()\r\n * modals.edit.open(user)\r\n * modals.delete.close()\r\n * ```\r\n */\r\nexport function useModals<T extends Record<string, UseModalReturn<unknown>>>(\r\n modals: T\r\n): T {\r\n return modals\r\n}\r\n","import { ref } from 'vue'\r\nimport type { ToastType } from '@/components/feedback/Toast.vue'\r\nimport type { ToastItem } from '@/components/feedback/ToastContainer.vue'\r\n\r\nexport interface ToastOptions {\r\n message: string\r\n type?: ToastType\r\n title?: string\r\n duration?: number\r\n}\r\n\r\nconst toasts = ref<ToastItem[]>([])\r\n\r\nlet toastId = 0\r\n\r\nexport function useToast() {\r\n const add = (options: ToastOptions): string => {\r\n const id = `toast-${++toastId}`\r\n const toast: ToastItem = {\r\n id,\r\n message: options.message,\r\n type: options.type || 'info',\r\n title: options.title,\r\n duration: options.duration ?? 5000,\r\n }\r\n toasts.value.push(toast)\r\n return id\r\n }\r\n\r\n const remove = (id: string) => {\r\n const index = toasts.value.findIndex((t) => t.id === id)\r\n if (index > -1) {\r\n toasts.value.splice(index, 1)\r\n }\r\n }\r\n\r\n const clear = () => {\r\n toasts.value = []\r\n }\r\n\r\n const success = (message: string, title?: string) => {\r\n return add({ message, title, type: 'success' })\r\n }\r\n\r\n const error = (message: string, title?: string) => {\r\n return add({ message, title, type: 'error' })\r\n }\r\n\r\n const warning = (message: string, title?: string) => {\r\n return add({ message, title, type: 'warning' })\r\n }\r\n\r\n const info = (message: string, title?: string) => {\r\n return add({ message, title, type: 'info' })\r\n }\r\n\r\n return {\r\n toasts,\r\n add,\r\n remove,\r\n clear,\r\n success,\r\n error,\r\n warning,\r\n info,\r\n }\r\n}\r\n"],"names":[],"mappings":"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","x_google_ignoreList":[0]}
|
package/package.json
CHANGED
|
@@ -1,168 +1,168 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "cisse-vue-ui",
|
|
3
|
-
"version": "0.5.
|
|
4
|
-
"description": "Vue 3 + TypeScript + Tailwind CSS v4 component library",
|
|
5
|
-
"author": "Cisse",
|
|
6
|
-
"license": "MIT",
|
|
7
|
-
"type": "module",
|
|
8
|
-
"main": "./dist/index.cjs",
|
|
9
|
-
"module": "./dist/index.js",
|
|
10
|
-
"types": "./dist/index.d.ts",
|
|
11
|
-
"exports": {
|
|
12
|
-
".": {
|
|
13
|
-
"import": {
|
|
14
|
-
"types": "./dist/index.d.ts",
|
|
15
|
-
"default": "./dist/index.js"
|
|
16
|
-
},
|
|
17
|
-
"require": {
|
|
18
|
-
"types": "./dist/index.d.cts",
|
|
19
|
-
"default": "./dist/index.cjs"
|
|
20
|
-
}
|
|
21
|
-
},
|
|
22
|
-
"./components": {
|
|
23
|
-
"import": {
|
|
24
|
-
"types": "./dist/components/index.d.ts",
|
|
25
|
-
"default": "./dist/components/index.js"
|
|
26
|
-
}
|
|
27
|
-
},
|
|
28
|
-
"./components/core": {
|
|
29
|
-
"import": {
|
|
30
|
-
"types": "./dist/components/core/index.d.ts",
|
|
31
|
-
"default": "./dist/components/core/index.js"
|
|
32
|
-
}
|
|
33
|
-
},
|
|
34
|
-
"./components/form": {
|
|
35
|
-
"import": {
|
|
36
|
-
"types": "./dist/components/form/index.d.ts",
|
|
37
|
-
"default": "./dist/components/form/index.js"
|
|
38
|
-
}
|
|
39
|
-
},
|
|
40
|
-
"./components/feedback": {
|
|
41
|
-
"import": {
|
|
42
|
-
"types": "./dist/components/feedback/index.d.ts",
|
|
43
|
-
"default": "./dist/components/feedback/index.js"
|
|
44
|
-
}
|
|
45
|
-
},
|
|
46
|
-
"./components/layout": {
|
|
47
|
-
"import": {
|
|
48
|
-
"types": "./dist/components/layout/index.d.ts",
|
|
49
|
-
"default": "./dist/components/layout/index.js"
|
|
50
|
-
}
|
|
51
|
-
},
|
|
52
|
-
"./components/type": {
|
|
53
|
-
"import": {
|
|
54
|
-
"types": "./dist/components/type/index.d.ts",
|
|
55
|
-
"default": "./dist/components/type/index.js"
|
|
56
|
-
}
|
|
57
|
-
},
|
|
58
|
-
"./composables": {
|
|
59
|
-
"import": {
|
|
60
|
-
"types": "./dist/composables/index.d.ts",
|
|
61
|
-
"default": "./dist/composables/index.js"
|
|
62
|
-
}
|
|
63
|
-
},
|
|
64
|
-
"./types": {
|
|
65
|
-
"import": {
|
|
66
|
-
"types": "./dist/types/index.d.ts",
|
|
67
|
-
"default": "./dist/types/index.js"
|
|
68
|
-
}
|
|
69
|
-
},
|
|
70
|
-
"./style.css": "./dist/style.css",
|
|
71
|
-
"./dist/style.css": "./dist/style.css"
|
|
72
|
-
},
|
|
73
|
-
"files": [
|
|
74
|
-
"dist",
|
|
75
|
-
"README.md",
|
|
76
|
-
"LICENSE"
|
|
77
|
-
],
|
|
78
|
-
"sideEffects": [
|
|
79
|
-
"*.css"
|
|
80
|
-
],
|
|
81
|
-
"keywords": [
|
|
82
|
-
"vue",
|
|
83
|
-
"vue3",
|
|
84
|
-
"typescript",
|
|
85
|
-
"tailwindcss",
|
|
86
|
-
"tailwind",
|
|
87
|
-
"ui",
|
|
88
|
-
"components",
|
|
89
|
-
"library"
|
|
90
|
-
],
|
|
91
|
-
"repository": {
|
|
92
|
-
"type": "git",
|
|
93
|
-
"url": "https://github.com/moulayecisse/cisse-vue-ui.git"
|
|
94
|
-
},
|
|
95
|
-
"scripts": {
|
|
96
|
-
"dev": "vite --config playground/vite.config.ts",
|
|
97
|
-
"build": "vue-tsc --noEmit && vite build && bun run build:css",
|
|
98
|
-
"build:css": "bunx @tailwindcss/cli -i ./src/styles/components.css -o ./dist/style.css --minify",
|
|
99
|
-
"build:watch": "vite build --watch",
|
|
100
|
-
"preview": "vite preview",
|
|
101
|
-
"test": "vitest --config vitest.config.ts",
|
|
102
|
-
"test:storybook": "vitest --project storybook",
|
|
103
|
-
"type-check": "vue-tsc --noEmit",
|
|
104
|
-
"lint": "eslint . --fix",
|
|
105
|
-
"prepublishOnly": "bun run build",
|
|
106
|
-
"storybook": "storybook dev -p 6006",
|
|
107
|
-
"build-storybook": "storybook build",
|
|
108
|
-
"deploy-storybook": "storybook build && gh-pages -d storybook-static"
|
|
109
|
-
},
|
|
110
|
-
"peerDependencies": {
|
|
111
|
-
"@iconify/vue": ">=4.0.0",
|
|
112
|
-
"tailwindcss": ">=4.0.0",
|
|
113
|
-
"vue": ">=3.4.0"
|
|
114
|
-
},
|
|
115
|
-
"peerDependenciesMeta": {
|
|
116
|
-
"pinia": {
|
|
117
|
-
"optional": true
|
|
118
|
-
},
|
|
119
|
-
"vue-router": {
|
|
120
|
-
"optional": true
|
|
121
|
-
}
|
|
122
|
-
},
|
|
123
|
-
"devDependencies": {
|
|
124
|
-
"@chromatic-com/storybook": "^4.1.3",
|
|
125
|
-
"@eslint/js": "^9.39.1",
|
|
126
|
-
"@iconify/vue": "^5.0.0",
|
|
127
|
-
"@storybook/addon-a11y": "^10.1.6",
|
|
128
|
-
"@storybook/addon-docs": "^10.1.6",
|
|
129
|
-
"@storybook/addon-vitest": "^10.1.6",
|
|
130
|
-
"@storybook/vue3-vite": "^10.1.6",
|
|
131
|
-
"@tailwindcss/vite": "^4.1.17",
|
|
132
|
-
"@types/node": "^22.19.1",
|
|
133
|
-
"@vitejs/plugin-vue": "^6.0.2",
|
|
134
|
-
"@vitest/browser": "^3.2.4",
|
|
135
|
-
"@vitest/coverage-v8": "^3.2.4",
|
|
136
|
-
"@vue/test-utils": "^2.4.6",
|
|
137
|
-
"@vue/tsconfig": "^0.8.1",
|
|
138
|
-
"ajv": "^8.17.1",
|
|
139
|
-
"eslint": "^9.39.1",
|
|
140
|
-
"eslint-plugin-storybook": "^10.1.6",
|
|
141
|
-
"eslint-plugin-vue": "^10.6.2",
|
|
142
|
-
"gh-pages": "^6.3.0",
|
|
143
|
-
"globals": "^16.5.0",
|
|
144
|
-
"happy-dom": "^20.0.11",
|
|
145
|
-
"pinia": "^3.0.4",
|
|
146
|
-
"playwright": "^1.57.0",
|
|
147
|
-
"storybook": "^10.1.6",
|
|
148
|
-
"tailwindcss": "^4.1.17",
|
|
149
|
-
"typescript": "~5.9.3",
|
|
150
|
-
"typescript-eslint": "^8.49.0",
|
|
151
|
-
"vite": "^6.4.1",
|
|
152
|
-
"vite-plugin-dts": "^4.5.4",
|
|
153
|
-
"vitest": "^3.2.4",
|
|
154
|
-
"vue": "^3.5.25",
|
|
155
|
-
"vue-router": "^4.6.3",
|
|
156
|
-
"vue-tsc": "^2.2.12"
|
|
157
|
-
},
|
|
158
|
-
"dependencies": {
|
|
159
|
-
"@vueuse/core": "^14.1.0",
|
|
160
|
-
"tailwind-merge": "^3.4.0",
|
|
161
|
-
"uid": "^2.0.2"
|
|
162
|
-
},
|
|
163
|
-
"eslintConfig": {
|
|
164
|
-
"extends": [
|
|
165
|
-
"plugin:storybook/recommended"
|
|
166
|
-
]
|
|
167
|
-
}
|
|
168
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"name": "cisse-vue-ui",
|
|
3
|
+
"version": "0.5.22",
|
|
4
|
+
"description": "Vue 3 + TypeScript + Tailwind CSS v4 component library",
|
|
5
|
+
"author": "Cisse",
|
|
6
|
+
"license": "MIT",
|
|
7
|
+
"type": "module",
|
|
8
|
+
"main": "./dist/index.cjs",
|
|
9
|
+
"module": "./dist/index.js",
|
|
10
|
+
"types": "./dist/index.d.ts",
|
|
11
|
+
"exports": {
|
|
12
|
+
".": {
|
|
13
|
+
"import": {
|
|
14
|
+
"types": "./dist/index.d.ts",
|
|
15
|
+
"default": "./dist/index.js"
|
|
16
|
+
},
|
|
17
|
+
"require": {
|
|
18
|
+
"types": "./dist/index.d.cts",
|
|
19
|
+
"default": "./dist/index.cjs"
|
|
20
|
+
}
|
|
21
|
+
},
|
|
22
|
+
"./components": {
|
|
23
|
+
"import": {
|
|
24
|
+
"types": "./dist/components/index.d.ts",
|
|
25
|
+
"default": "./dist/components/index.js"
|
|
26
|
+
}
|
|
27
|
+
},
|
|
28
|
+
"./components/core": {
|
|
29
|
+
"import": {
|
|
30
|
+
"types": "./dist/components/core/index.d.ts",
|
|
31
|
+
"default": "./dist/components/core/index.js"
|
|
32
|
+
}
|
|
33
|
+
},
|
|
34
|
+
"./components/form": {
|
|
35
|
+
"import": {
|
|
36
|
+
"types": "./dist/components/form/index.d.ts",
|
|
37
|
+
"default": "./dist/components/form/index.js"
|
|
38
|
+
}
|
|
39
|
+
},
|
|
40
|
+
"./components/feedback": {
|
|
41
|
+
"import": {
|
|
42
|
+
"types": "./dist/components/feedback/index.d.ts",
|
|
43
|
+
"default": "./dist/components/feedback/index.js"
|
|
44
|
+
}
|
|
45
|
+
},
|
|
46
|
+
"./components/layout": {
|
|
47
|
+
"import": {
|
|
48
|
+
"types": "./dist/components/layout/index.d.ts",
|
|
49
|
+
"default": "./dist/components/layout/index.js"
|
|
50
|
+
}
|
|
51
|
+
},
|
|
52
|
+
"./components/type": {
|
|
53
|
+
"import": {
|
|
54
|
+
"types": "./dist/components/type/index.d.ts",
|
|
55
|
+
"default": "./dist/components/type/index.js"
|
|
56
|
+
}
|
|
57
|
+
},
|
|
58
|
+
"./composables": {
|
|
59
|
+
"import": {
|
|
60
|
+
"types": "./dist/composables/index.d.ts",
|
|
61
|
+
"default": "./dist/composables/index.js"
|
|
62
|
+
}
|
|
63
|
+
},
|
|
64
|
+
"./types": {
|
|
65
|
+
"import": {
|
|
66
|
+
"types": "./dist/types/index.d.ts",
|
|
67
|
+
"default": "./dist/types/index.js"
|
|
68
|
+
}
|
|
69
|
+
},
|
|
70
|
+
"./style.css": "./dist/style.css",
|
|
71
|
+
"./dist/style.css": "./dist/style.css"
|
|
72
|
+
},
|
|
73
|
+
"files": [
|
|
74
|
+
"dist",
|
|
75
|
+
"README.md",
|
|
76
|
+
"LICENSE"
|
|
77
|
+
],
|
|
78
|
+
"sideEffects": [
|
|
79
|
+
"*.css"
|
|
80
|
+
],
|
|
81
|
+
"keywords": [
|
|
82
|
+
"vue",
|
|
83
|
+
"vue3",
|
|
84
|
+
"typescript",
|
|
85
|
+
"tailwindcss",
|
|
86
|
+
"tailwind",
|
|
87
|
+
"ui",
|
|
88
|
+
"components",
|
|
89
|
+
"library"
|
|
90
|
+
],
|
|
91
|
+
"repository": {
|
|
92
|
+
"type": "git",
|
|
93
|
+
"url": "https://github.com/moulayecisse/cisse-vue-ui.git"
|
|
94
|
+
},
|
|
95
|
+
"scripts": {
|
|
96
|
+
"dev": "vite --config playground/vite.config.ts",
|
|
97
|
+
"build": "vue-tsc --noEmit && vite build && bun run build:css",
|
|
98
|
+
"build:css": "bunx @tailwindcss/cli -i ./src/styles/components.css -o ./dist/style.css --minify",
|
|
99
|
+
"build:watch": "vite build --watch",
|
|
100
|
+
"preview": "vite preview",
|
|
101
|
+
"test": "vitest --config vitest.config.ts",
|
|
102
|
+
"test:storybook": "vitest --project storybook",
|
|
103
|
+
"type-check": "vue-tsc --noEmit",
|
|
104
|
+
"lint": "eslint . --fix",
|
|
105
|
+
"prepublishOnly": "bun run build",
|
|
106
|
+
"storybook": "storybook dev -p 6006",
|
|
107
|
+
"build-storybook": "storybook build",
|
|
108
|
+
"deploy-storybook": "storybook build && gh-pages -d storybook-static"
|
|
109
|
+
},
|
|
110
|
+
"peerDependencies": {
|
|
111
|
+
"@iconify/vue": ">=4.0.0",
|
|
112
|
+
"tailwindcss": ">=4.0.0",
|
|
113
|
+
"vue": ">=3.4.0"
|
|
114
|
+
},
|
|
115
|
+
"peerDependenciesMeta": {
|
|
116
|
+
"pinia": {
|
|
117
|
+
"optional": true
|
|
118
|
+
},
|
|
119
|
+
"vue-router": {
|
|
120
|
+
"optional": true
|
|
121
|
+
}
|
|
122
|
+
},
|
|
123
|
+
"devDependencies": {
|
|
124
|
+
"@chromatic-com/storybook": "^4.1.3",
|
|
125
|
+
"@eslint/js": "^9.39.1",
|
|
126
|
+
"@iconify/vue": "^5.0.0",
|
|
127
|
+
"@storybook/addon-a11y": "^10.1.6",
|
|
128
|
+
"@storybook/addon-docs": "^10.1.6",
|
|
129
|
+
"@storybook/addon-vitest": "^10.1.6",
|
|
130
|
+
"@storybook/vue3-vite": "^10.1.6",
|
|
131
|
+
"@tailwindcss/vite": "^4.1.17",
|
|
132
|
+
"@types/node": "^22.19.1",
|
|
133
|
+
"@vitejs/plugin-vue": "^6.0.2",
|
|
134
|
+
"@vitest/browser": "^3.2.4",
|
|
135
|
+
"@vitest/coverage-v8": "^3.2.4",
|
|
136
|
+
"@vue/test-utils": "^2.4.6",
|
|
137
|
+
"@vue/tsconfig": "^0.8.1",
|
|
138
|
+
"ajv": "^8.17.1",
|
|
139
|
+
"eslint": "^9.39.1",
|
|
140
|
+
"eslint-plugin-storybook": "^10.1.6",
|
|
141
|
+
"eslint-plugin-vue": "^10.6.2",
|
|
142
|
+
"gh-pages": "^6.3.0",
|
|
143
|
+
"globals": "^16.5.0",
|
|
144
|
+
"happy-dom": "^20.0.11",
|
|
145
|
+
"pinia": "^3.0.4",
|
|
146
|
+
"playwright": "^1.57.0",
|
|
147
|
+
"storybook": "^10.1.6",
|
|
148
|
+
"tailwindcss": "^4.1.17",
|
|
149
|
+
"typescript": "~5.9.3",
|
|
150
|
+
"typescript-eslint": "^8.49.0",
|
|
151
|
+
"vite": "^6.4.1",
|
|
152
|
+
"vite-plugin-dts": "^4.5.4",
|
|
153
|
+
"vitest": "^3.2.4",
|
|
154
|
+
"vue": "^3.5.25",
|
|
155
|
+
"vue-router": "^4.6.3",
|
|
156
|
+
"vue-tsc": "^2.2.12"
|
|
157
|
+
},
|
|
158
|
+
"dependencies": {
|
|
159
|
+
"@vueuse/core": "^14.1.0",
|
|
160
|
+
"tailwind-merge": "^3.4.0",
|
|
161
|
+
"uid": "^2.0.2"
|
|
162
|
+
},
|
|
163
|
+
"eslintConfig": {
|
|
164
|
+
"extends": [
|
|
165
|
+
"plugin:storybook/recommended"
|
|
166
|
+
]
|
|
167
|
+
}
|
|
168
|
+
}
|
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
import { defineComponent, createElementBlock, openBlock, normalizeClass, createElementVNode, createCommentVNode, toDisplayString } from "vue";
|
|
2
|
-
const _hoisted_1 = ["checked", "disabled", "indeterminate"];
|
|
3
|
-
const _hoisted_2 = {
|
|
4
|
-
key: 0,
|
|
5
|
-
class: "flex flex-col"
|
|
6
|
-
};
|
|
7
|
-
const _hoisted_3 = {
|
|
8
|
-
key: 0,
|
|
9
|
-
class: "text-sm font-medium text-gray-900 dark:text-white"
|
|
10
|
-
};
|
|
11
|
-
const _hoisted_4 = {
|
|
12
|
-
key: 1,
|
|
13
|
-
class: "text-sm text-gray-500 dark:text-gray-400"
|
|
14
|
-
};
|
|
15
|
-
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
16
|
-
__name: "Checkbox",
|
|
17
|
-
props: {
|
|
18
|
-
modelValue: { type: Boolean, default: false },
|
|
19
|
-
label: {},
|
|
20
|
-
description: {},
|
|
21
|
-
disabled: { type: Boolean },
|
|
22
|
-
indeterminate: { type: Boolean }
|
|
23
|
-
},
|
|
24
|
-
emits: ["update:modelValue"],
|
|
25
|
-
setup(__props, { emit: __emit }) {
|
|
26
|
-
const emit = __emit;
|
|
27
|
-
const toggle = (event) => {
|
|
28
|
-
const target = event.target;
|
|
29
|
-
emit("update:modelValue", target.checked);
|
|
30
|
-
};
|
|
31
|
-
return (_ctx, _cache) => {
|
|
32
|
-
return openBlock(), createElementBlock("label", {
|
|
33
|
-
class: normalizeClass(["inline-flex items-start gap-3", __props.disabled ? "cursor-not-allowed opacity-50" : "cursor-pointer"])
|
|
34
|
-
}, [
|
|
35
|
-
createElementVNode("input", {
|
|
36
|
-
type: "checkbox",
|
|
37
|
-
checked: __props.modelValue,
|
|
38
|
-
disabled: __props.disabled,
|
|
39
|
-
indeterminate: __props.indeterminate,
|
|
40
|
-
class: "mt-0.5 size-4 rounded border-gray-300 text-primary/90 focus:ring-2 focus:ring-primary focus:ring-offset-2 disabled:cursor-not-allowed dark:border-gray-600 dark:bg-gray-800 dark:focus:ring-offset-gray-900",
|
|
41
|
-
onChange: toggle
|
|
42
|
-
}, null, 40, _hoisted_1),
|
|
43
|
-
__props.label || __props.description ? (openBlock(), createElementBlock("div", _hoisted_2, [
|
|
44
|
-
__props.label ? (openBlock(), createElementBlock("span", _hoisted_3, toDisplayString(__props.label), 1)) : createCommentVNode("", true),
|
|
45
|
-
__props.description ? (openBlock(), createElementBlock("span", _hoisted_4, toDisplayString(__props.description), 1)) : createCommentVNode("", true)
|
|
46
|
-
])) : createCommentVNode("", true)
|
|
47
|
-
], 2);
|
|
48
|
-
};
|
|
49
|
-
}
|
|
50
|
-
});
|
|
51
|
-
export {
|
|
52
|
-
_sfc_main as _
|
|
53
|
-
};
|
|
54
|
-
//# sourceMappingURL=Checkbox.vue_vue_type_script_setup_true_lang-B-nLCCNY.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Checkbox.vue_vue_type_script_setup_true_lang-B-nLCCNY.js","sources":["../src/components/form/Checkbox.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nwithDefaults(\n defineProps<{\n /** v-model value */\n modelValue?: boolean\n /** Label text */\n label?: string\n /** Description text */\n description?: string\n /** Disabled state */\n disabled?: boolean\n /** Indeterminate state */\n indeterminate?: boolean\n }>(),\n {\n modelValue: false,\n },\n)\n\nconst emit = defineEmits<{\n 'update:modelValue': [value: boolean]\n}>()\n\nconst toggle = (event: Event) => {\n const target = event.target as HTMLInputElement\n emit('update:modelValue', target.checked)\n}\n</script>\n\n<template>\n <label\n class=\"inline-flex items-start gap-3\"\n :class=\"disabled ? 'cursor-not-allowed opacity-50' : 'cursor-pointer'\"\n >\n <input\n type=\"checkbox\"\n :checked=\"modelValue\"\n :disabled=\"disabled\"\n :indeterminate=\"indeterminate\"\n class=\"mt-0.5 size-4 rounded border-gray-300 text-primary/90 focus:ring-2 focus:ring-primary focus:ring-offset-2 disabled:cursor-not-allowed dark:border-gray-600 dark:bg-gray-800 dark:focus:ring-offset-gray-900\"\n @change=\"toggle\"\n >\n <div\n v-if=\"label || description\"\n class=\"flex flex-col\"\n >\n <span\n v-if=\"label\"\n class=\"text-sm font-medium text-gray-900 dark:text-white\"\n >\n {{ label }}\n </span>\n <span\n v-if=\"description\"\n class=\"text-sm text-gray-500 dark:text-gray-400\"\n >\n {{ description }}\n </span>\n </div>\n </label>\n</template>\n"],"names":["_createElementBlock","_normalizeClass","_createElementVNode","_openBlock","_toDisplayString"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;AAmBA,UAAM,OAAO;AAIb,UAAM,SAAS,CAAC,UAAiB;AAC/B,YAAM,SAAS,MAAM;AACrB,WAAK,qBAAqB,OAAO,OAAO;AAAA,IAC1C;;0BAIEA,mBA6BQ,SAAA;AAAA,QA5BN,OAAKC,eAAA,CAAC,iCACE,QAAA,WAAQ,kCAAA,gBAAA,CAAA;AAAA,MAAA;QAEhBC,mBAOC,SAAA;AAAA,UANC,MAAK;AAAA,UACJ,SAAS,QAAA;AAAA,UACT,UAAU,QAAA;AAAA,UACV,eAAe,QAAA;AAAA,UAChB,OAAM;AAAA,UACL,UAAQ;AAAA,QAAA;QAGH,QAAA,SAAS,QAAA,eADjBC,aAAAH,mBAgBM,OAhBN,YAgBM;AAAA,UAXI,QAAA,sBADRA,mBAKO,QALP,YAKOI,gBADF,QAAA,KAAK,GAAA,CAAA;UAGF,QAAA,4BADRJ,mBAKO,QALP,YAKOI,gBADF,QAAA,WAAW,GAAA,CAAA;;;;;;"}
|
|
@@ -1,53 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
const vue = require("vue");
|
|
3
|
-
const _hoisted_1 = ["checked", "disabled", "indeterminate"];
|
|
4
|
-
const _hoisted_2 = {
|
|
5
|
-
key: 0,
|
|
6
|
-
class: "flex flex-col"
|
|
7
|
-
};
|
|
8
|
-
const _hoisted_3 = {
|
|
9
|
-
key: 0,
|
|
10
|
-
class: "text-sm font-medium text-gray-900 dark:text-white"
|
|
11
|
-
};
|
|
12
|
-
const _hoisted_4 = {
|
|
13
|
-
key: 1,
|
|
14
|
-
class: "text-sm text-gray-500 dark:text-gray-400"
|
|
15
|
-
};
|
|
16
|
-
const _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
17
|
-
__name: "Checkbox",
|
|
18
|
-
props: {
|
|
19
|
-
modelValue: { type: Boolean, default: false },
|
|
20
|
-
label: {},
|
|
21
|
-
description: {},
|
|
22
|
-
disabled: { type: Boolean },
|
|
23
|
-
indeterminate: { type: Boolean }
|
|
24
|
-
},
|
|
25
|
-
emits: ["update:modelValue"],
|
|
26
|
-
setup(__props, { emit: __emit }) {
|
|
27
|
-
const emit = __emit;
|
|
28
|
-
const toggle = (event) => {
|
|
29
|
-
const target = event.target;
|
|
30
|
-
emit("update:modelValue", target.checked);
|
|
31
|
-
};
|
|
32
|
-
return (_ctx, _cache) => {
|
|
33
|
-
return vue.openBlock(), vue.createElementBlock("label", {
|
|
34
|
-
class: vue.normalizeClass(["inline-flex items-start gap-3", __props.disabled ? "cursor-not-allowed opacity-50" : "cursor-pointer"])
|
|
35
|
-
}, [
|
|
36
|
-
vue.createElementVNode("input", {
|
|
37
|
-
type: "checkbox",
|
|
38
|
-
checked: __props.modelValue,
|
|
39
|
-
disabled: __props.disabled,
|
|
40
|
-
indeterminate: __props.indeterminate,
|
|
41
|
-
class: "mt-0.5 size-4 rounded border-gray-300 text-primary/90 focus:ring-2 focus:ring-primary focus:ring-offset-2 disabled:cursor-not-allowed dark:border-gray-600 dark:bg-gray-800 dark:focus:ring-offset-gray-900",
|
|
42
|
-
onChange: toggle
|
|
43
|
-
}, null, 40, _hoisted_1),
|
|
44
|
-
__props.label || __props.description ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_2, [
|
|
45
|
-
__props.label ? (vue.openBlock(), vue.createElementBlock("span", _hoisted_3, vue.toDisplayString(__props.label), 1)) : vue.createCommentVNode("", true),
|
|
46
|
-
__props.description ? (vue.openBlock(), vue.createElementBlock("span", _hoisted_4, vue.toDisplayString(__props.description), 1)) : vue.createCommentVNode("", true)
|
|
47
|
-
])) : vue.createCommentVNode("", true)
|
|
48
|
-
], 2);
|
|
49
|
-
};
|
|
50
|
-
}
|
|
51
|
-
});
|
|
52
|
-
exports._sfc_main = _sfc_main;
|
|
53
|
-
//# sourceMappingURL=Checkbox.vue_vue_type_script_setup_true_lang-DIoHDji4.cjs.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Checkbox.vue_vue_type_script_setup_true_lang-DIoHDji4.cjs","sources":["../src/components/form/Checkbox.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nwithDefaults(\n defineProps<{\n /** v-model value */\n modelValue?: boolean\n /** Label text */\n label?: string\n /** Description text */\n description?: string\n /** Disabled state */\n disabled?: boolean\n /** Indeterminate state */\n indeterminate?: boolean\n }>(),\n {\n modelValue: false,\n },\n)\n\nconst emit = defineEmits<{\n 'update:modelValue': [value: boolean]\n}>()\n\nconst toggle = (event: Event) => {\n const target = event.target as HTMLInputElement\n emit('update:modelValue', target.checked)\n}\n</script>\n\n<template>\n <label\n class=\"inline-flex items-start gap-3\"\n :class=\"disabled ? 'cursor-not-allowed opacity-50' : 'cursor-pointer'\"\n >\n <input\n type=\"checkbox\"\n :checked=\"modelValue\"\n :disabled=\"disabled\"\n :indeterminate=\"indeterminate\"\n class=\"mt-0.5 size-4 rounded border-gray-300 text-primary/90 focus:ring-2 focus:ring-primary focus:ring-offset-2 disabled:cursor-not-allowed dark:border-gray-600 dark:bg-gray-800 dark:focus:ring-offset-gray-900\"\n @change=\"toggle\"\n >\n <div\n v-if=\"label || description\"\n class=\"flex flex-col\"\n >\n <span\n v-if=\"label\"\n class=\"text-sm font-medium text-gray-900 dark:text-white\"\n >\n {{ label }}\n </span>\n <span\n v-if=\"description\"\n class=\"text-sm text-gray-500 dark:text-gray-400\"\n >\n {{ description }}\n </span>\n </div>\n </label>\n</template>\n"],"names":["_createElementBlock","_normalizeClass","_createElementVNode","_openBlock","_toDisplayString"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAmBA,UAAM,OAAO;AAIb,UAAM,SAAS,CAAC,UAAiB;AAC/B,YAAM,SAAS,MAAM;AACrB,WAAK,qBAAqB,OAAO,OAAO;AAAA,IAC1C;;8BAIEA,IAAAA,mBA6BQ,SAAA;AAAA,QA5BN,OAAKC,IAAAA,eAAA,CAAC,iCACE,QAAA,WAAQ,kCAAA,gBAAA,CAAA;AAAA,MAAA;QAEhBC,IAAAA,mBAOC,SAAA;AAAA,UANC,MAAK;AAAA,UACJ,SAAS,QAAA;AAAA,UACT,UAAU,QAAA;AAAA,UACV,eAAe,QAAA;AAAA,UAChB,OAAM;AAAA,UACL,UAAQ;AAAA,QAAA;QAGH,QAAA,SAAS,QAAA,eADjBC,IAAAA,aAAAH,IAAAA,mBAgBM,OAhBN,YAgBM;AAAA,UAXI,QAAA,0BADRA,IAAAA,mBAKO,QALP,YAKOI,IAAAA,gBADF,QAAA,KAAK,GAAA,CAAA;UAGF,QAAA,gCADRJ,IAAAA,mBAKO,QALP,YAKOI,IAAAA,gBADF,QAAA,WAAW,GAAA,CAAA;;;;;;;"}
|