@indielayer/ui 1.4.0 → 1.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/docs/components/common/CodePreview.vue +1 -1
- package/docs/components/common/CodeSnippet.vue +5 -7
- package/docs/components/common/DocumentPage.vue +89 -93
- package/docs/components/menu/DocsMenu.vue +75 -122
- package/docs/components/toolbar/PreToolbar.vue +10 -12
- package/docs/components/toolbar/Toolbar.vue +21 -8
- package/docs/layouts/default.vue +7 -3
- package/docs/pages/colors.vue +49 -54
- package/docs/pages/component/button/button-group.vue +6 -2
- package/docs/pages/component/button/size.vue +1 -1
- package/docs/pages/component/carousel/usage.vue +2 -2
- package/docs/pages/component/form/usage.vue +3 -3
- package/docs/pages/component/formGroup/usage.vue +1 -0
- package/docs/pages/component/input/usage.vue +8 -9
- package/docs/pages/component/modal/composed.vue +3 -2
- package/docs/pages/component/modal/usage.vue +11 -6
- package/docs/pages/component/popover/usage.vue +3 -3
- package/docs/pages/component/select/usage.vue +1 -0
- package/docs/pages/component/tabs/usage.vue +6 -1
- package/docs/pages/component/textarea/usage.vue +10 -13
- package/docs/pages/component/toggle/usage.vue +9 -11
- package/docs/pages/component/tooltip/index.vue +2 -2
- package/docs/pages/component/tooltip/usage.vue +4 -8
- package/docs/pages/icons.vue +54 -58
- package/docs/pages/index.vue +73 -77
- package/docs/pages/play.vue +2 -14
- package/docs/pages/typography.vue +26 -30
- package/docs/router/index.ts +2 -0
- package/exports/tailwind.preset.js +0 -1
- package/lib/components/accordion/theme/AccordionItem.base.theme.js +7 -7
- package/lib/components/badge/Badge.vue.js +7 -7
- package/lib/components/breadcrumbs/theme/Breadcrumbs.base.theme.js +1 -1
- package/lib/components/button/theme/Button.base.theme.js +7 -7
- package/lib/components/card/theme/Card.base.theme.js +1 -1
- package/lib/components/checkbox/Checkbox.vue.d.ts +3 -0
- package/lib/components/checkbox/Checkbox.vue2.js +23 -23
- package/lib/components/checkbox/theme/Checkbox.base.theme.js +6 -6
- package/lib/components/checkbox/theme/Checkbox.carbon.theme.js +2 -2
- package/lib/components/container/theme/Container.base.theme.js +2 -2
- package/lib/components/divider/Divider.vue.js +14 -14
- package/lib/components/divider/theme/Divider.base.theme.js +2 -2
- package/lib/components/drawer/Drawer.vue.js +2 -2
- package/lib/components/drawer/theme/Drawer.base.theme.js +1 -1
- package/lib/components/form/Form.vue.js +1 -1
- package/lib/components/form/theme/Form.base.theme.js +4 -4
- package/lib/components/form/theme/Form.carbon.theme.js +4 -4
- package/lib/components/formGroup/FormGroup.vue.d.ts +3 -0
- package/lib/components/formGroup/FormGroup.vue.js +16 -15
- package/lib/components/formGroup/theme/FormGroup.base.theme.js +1 -1
- package/lib/components/icon/theme/Icon.base.theme.js +1 -1
- package/lib/components/index.js +108 -107
- package/lib/components/input/Input.vue.d.ts +3 -0
- package/lib/components/input/Input.vue.js +4 -3
- package/lib/components/input/theme/Input.base.theme.js +10 -10
- package/lib/components/input/theme/Input.carbon.theme.js +10 -10
- package/lib/components/inputFooter/theme/InputFooter.base.theme.js +3 -3
- package/lib/components/inputFooter/theme/InputFooter.carbon.theme.js +2 -2
- package/lib/components/label/Label.vue.d.ts +3 -0
- package/lib/components/label/Label.vue.js +26 -20
- package/lib/components/label/theme/Label.base.theme.js +1 -1
- package/lib/components/label/theme/Label.carbon.theme.js +3 -3
- package/lib/components/link/Link.vue.js +2 -2
- package/lib/components/link/Link.vue2.js +4 -4
- package/lib/components/loader/theme/Loader.base.theme.js +1 -1
- package/lib/components/loader/theme/Loader.carbon.theme.js +1 -1
- package/lib/components/menu/Menu.vue.js +19 -19
- package/lib/components/menu/theme/MenuItem.base.theme.js +21 -31
- package/lib/components/modal/Modal.vue.d.ts +4 -0
- package/lib/components/modal/Modal.vue.js +78 -74
- package/lib/components/modal/theme/Modal.base.theme.js +10 -10
- package/lib/components/modal/theme/Modal.carbon.theme.js +3 -3
- package/lib/components/notifications/Notifications.vue.js +1 -1
- package/lib/components/notifications/theme/Notifications.base.theme.js +1 -1
- package/lib/components/notifications/theme/Notifications.carbon.theme.js +3 -3
- package/lib/components/pagination/Pagination.vue.js +27 -27
- package/lib/components/popover/Popover.vue.d.ts +13 -0
- package/lib/components/popover/Popover.vue.js +13 -8
- package/lib/components/popover/Popover.vue2.js +3 -2
- package/lib/components/popover/Popover.vue3.js +2 -3
- package/lib/components/popover/theme/PopoverContainer.base.theme.js +4 -4
- package/lib/components/popover/theme/PopoverContainer.carbon.theme.js +4 -4
- package/lib/components/progress/Progress.vue.js +11 -11
- package/lib/components/progress/theme/Progress.base.theme.js +10 -10
- package/lib/components/radio/Radio.vue.d.ts +3 -0
- package/lib/components/radio/theme/Radio.base.theme.js +28 -28
- package/lib/components/radio/theme/Radio.carbon.theme.js +8 -8
- package/lib/components/select/Select.vue.d.ts +16 -0
- package/lib/components/select/Select.vue.js +95 -92
- package/lib/components/select/theme/Select.base.theme.js +11 -11
- package/lib/components/select/theme/Select.carbon.theme.js +10 -10
- package/lib/components/skeleton/theme/Skeleton.base.theme.js +1 -1
- package/lib/components/slider/Slider.vue.d.ts +3 -0
- package/lib/components/slider/Slider.vue.js +1 -1
- package/lib/components/slider/theme/Slider.carbon.theme.js +6 -6
- package/lib/components/stepper/Stepper.vue.js +14 -14
- package/lib/components/tab/Tab.vue.js +55 -54
- package/lib/components/tab/theme/TabGroup.base.theme.js +15 -15
- package/lib/components/tab/theme/TabGroup.carbon.theme.js +8 -8
- package/lib/components/table/Table.vue.js +192 -194
- package/lib/components/table/theme/Table.base.theme.js +3 -3
- package/lib/components/table/theme/Table.carbon.theme.js +7 -7
- package/lib/components/table/theme/TableHead.base.theme.js +1 -1
- package/lib/components/table/theme/TableHead.carbon.theme.js +1 -1
- package/lib/components/table/theme/TableHeader.base.theme.js +1 -1
- package/lib/components/table/theme/TableHeader.carbon.theme.js +2 -2
- package/lib/components/table/theme/TableRow.base.theme.js +3 -3
- package/lib/components/table/theme/TableRow.carbon.theme.js +3 -3
- package/lib/components/tag/Tag.vue.js +4 -4
- package/lib/components/textarea/Textarea.vue.d.ts +7 -0
- package/lib/components/textarea/Textarea.vue.js +23 -21
- package/lib/components/textarea/theme/Textarea.base.theme.js +6 -6
- package/lib/components/textarea/theme/Textarea.carbon.theme.js +6 -6
- package/lib/components/toggle/Toggle.vue.d.ts +3 -0
- package/lib/components/toggle/Toggle.vue.js +26 -26
- package/lib/components/toggle/theme/Toggle.base.theme.js +1 -1
- package/lib/components/tooltip/ToggleTip.vue.d.ts +14 -0
- package/lib/components/tooltip/ToggleTip.vue.js +29 -0
- package/lib/components/tooltip/ToggleTip.vue2.js +4 -0
- package/lib/components/tooltip/Tooltip.vue.d.ts +22 -3
- package/lib/components/tooltip/Tooltip.vue.js +26 -17
- package/lib/components/tooltip/__tests__/ToggleTip.spec.d.ts +1 -0
- package/lib/components/tooltip/index.d.ts +2 -0
- package/lib/composables/useColors.js +9 -9
- package/lib/composables/useInputtable.d.ts +1 -0
- package/lib/composables/useInputtable.js +20 -19
- package/lib/index.js +37 -35
- package/lib/index.umd.js +7 -3
- package/lib/tailwind.preset.js +0 -1
- package/lib/themes/base/index.js +3 -6
- package/lib/themes/base/styles.css.js +4 -0
- package/lib/version.d.ts +1 -1
- package/lib/version.js +1 -1
- package/package.json +2 -1
- package/src/components/accordion/theme/AccordionItem.base.theme.ts +2 -2
- package/src/components/badge/Badge.vue +1 -1
- package/src/components/breadcrumbs/theme/Breadcrumbs.base.theme.ts +1 -1
- package/src/components/button/theme/Button.base.theme.ts +2 -2
- package/src/components/card/theme/Card.base.theme.ts +1 -1
- package/src/components/checkbox/Checkbox.vue +1 -1
- package/src/components/checkbox/theme/Checkbox.base.theme.ts +8 -8
- package/src/components/checkbox/theme/Checkbox.carbon.theme.ts +2 -2
- package/src/components/container/theme/Container.base.theme.ts +2 -2
- package/src/components/divider/Divider.vue +1 -1
- package/src/components/divider/theme/Divider.base.theme.ts +2 -2
- package/src/components/drawer/Drawer.vue +2 -2
- package/src/components/drawer/theme/Drawer.base.theme.ts +1 -1
- package/src/components/form/Form.vue +1 -1
- package/src/components/form/theme/Form.base.theme.ts +1 -1
- package/src/components/form/theme/Form.carbon.theme.ts +1 -1
- package/src/components/formGroup/FormGroup.vue +1 -0
- package/src/components/formGroup/theme/FormGroup.base.theme.ts +1 -1
- package/src/components/icon/theme/Icon.base.theme.ts +2 -2
- package/src/components/input/Input.vue +2 -1
- package/src/components/input/theme/Input.base.theme.ts +5 -5
- package/src/components/input/theme/Input.carbon.theme.ts +6 -6
- package/src/components/inputFooter/theme/InputFooter.base.theme.ts +3 -3
- package/src/components/inputFooter/theme/InputFooter.carbon.theme.ts +2 -2
- package/src/components/label/Label.vue +4 -1
- package/src/components/label/theme/Label.base.theme.ts +1 -1
- package/src/components/label/theme/Label.carbon.theme.ts +1 -1
- package/src/components/link/Link.vue +1 -1
- package/src/components/loader/theme/Loader.base.theme.ts +1 -1
- package/src/components/loader/theme/Loader.carbon.theme.ts +1 -1
- package/src/components/menu/Menu.vue +3 -3
- package/src/components/menu/theme/MenuItem.base.theme.ts +30 -34
- package/src/components/modal/Modal.vue +8 -3
- package/src/components/modal/theme/Modal.base.theme.ts +9 -6
- package/src/components/modal/theme/Modal.carbon.theme.ts +3 -3
- package/src/components/notifications/Notifications.vue +1 -1
- package/src/components/notifications/theme/Notifications.base.theme.ts +1 -1
- package/src/components/notifications/theme/Notifications.carbon.theme.ts +1 -1
- package/src/components/pagination/Pagination.vue +3 -3
- package/src/components/popover/Popover.vue +77 -2
- package/src/components/popover/theme/PopoverContainer.base.theme.ts +1 -1
- package/src/components/popover/theme/PopoverContainer.carbon.theme.ts +1 -1
- package/src/components/progress/Progress.vue +1 -1
- package/src/components/progress/theme/Progress.base.theme.ts +2 -2
- package/src/components/radio/theme/Radio.base.theme.ts +8 -8
- package/src/components/radio/theme/Radio.carbon.theme.ts +1 -1
- package/src/components/select/Select.vue +7 -4
- package/src/components/select/theme/Select.base.theme.ts +8 -8
- package/src/components/select/theme/Select.carbon.theme.ts +8 -8
- package/src/components/skeleton/theme/Skeleton.base.theme.ts +1 -1
- package/src/components/slider/Slider.vue +1 -1
- package/src/components/slider/theme/Slider.carbon.theme.ts +1 -1
- package/src/components/stepper/Stepper.vue +3 -3
- package/src/components/tab/Tab.vue +3 -3
- package/src/components/tab/theme/TabGroup.base.theme.ts +4 -4
- package/src/components/tab/theme/TabGroup.carbon.theme.ts +3 -3
- package/src/components/table/Table.vue +2 -0
- package/src/components/table/theme/Table.base.theme.ts +1 -1
- package/src/components/table/theme/Table.carbon.theme.ts +2 -2
- package/src/components/table/theme/TableHead.base.theme.ts +1 -1
- package/src/components/table/theme/TableHead.carbon.theme.ts +1 -1
- package/src/components/table/theme/TableHeader.base.theme.ts +1 -1
- package/src/components/table/theme/TableHeader.carbon.theme.ts +2 -2
- package/src/components/table/theme/TableRow.base.theme.ts +3 -3
- package/src/components/table/theme/TableRow.carbon.theme.ts +3 -3
- package/src/components/tag/Tag.vue +1 -1
- package/src/components/textarea/Textarea.vue +3 -1
- package/src/components/textarea/theme/Textarea.base.theme.ts +5 -4
- package/src/components/textarea/theme/Textarea.carbon.theme.ts +5 -5
- package/src/components/toggle/Toggle.vue +3 -3
- package/src/components/toggle/theme/Toggle.base.theme.ts +1 -1
- package/src/components/tooltip/ToggleTip.vue +31 -0
- package/src/components/tooltip/Tooltip.vue +14 -4
- package/src/components/tooltip/__tests__/ToggleTip.spec.ts +11 -0
- package/src/components/tooltip/index.ts +3 -0
- package/src/composables/useColors.ts +1 -1
- package/src/composables/useInputtable.ts +1 -0
- package/src/themes/base/index.ts +0 -3
- package/src/themes/base/styles.css +4 -0
- package/src/version.ts +1 -1
- package/volar.d.ts +1 -0
|
@@ -3,21 +3,17 @@ import type { MenuItemTheme } from '../MenuItem.vue'
|
|
|
3
3
|
const theme: MenuItemTheme = {
|
|
4
4
|
classes: {
|
|
5
5
|
wrapper: ({ props, data }) => {
|
|
6
|
-
const classes
|
|
6
|
+
const classes = ['relative !flex items-center whitespace-nowrap px-3']
|
|
7
7
|
|
|
8
|
-
classes.push(
|
|
9
|
-
|
|
10
|
-
|
|
8
|
+
if (!props.disabled) classes.push('cursor-pointer')
|
|
9
|
+
if (data.isActive) classes.push('font-medium')
|
|
10
|
+
if (props.rounded) classes.push('rounded')
|
|
11
11
|
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
'py-4 text-lg': props.size === 'xl',
|
|
18
|
-
|
|
19
|
-
'rounded': props.rounded,
|
|
20
|
-
})
|
|
12
|
+
if (props.size === 'xs') classes.push('py-1 text-xs')
|
|
13
|
+
else if (props.size === 'sm') classes.push('py-1.5 text-sm')
|
|
14
|
+
else if (props.size === 'lg') classes.push('py-3')
|
|
15
|
+
else if (props.size === 'xl') classes.push('py-4 text-lg')
|
|
16
|
+
else classes.push('py-1.5')
|
|
21
17
|
|
|
22
18
|
return classes
|
|
23
19
|
},
|
|
@@ -25,23 +21,23 @@ const theme: MenuItemTheme = {
|
|
|
25
21
|
|
|
26
22
|
styles: ({ colors, props, css, data }) => {
|
|
27
23
|
const color = colors.getPalette(props.color || 'gray')
|
|
28
|
-
const
|
|
24
|
+
const secondary = colors.getPalette('secondary')
|
|
29
25
|
|
|
30
26
|
if (props.disabled) return css.variables({
|
|
31
|
-
text:
|
|
27
|
+
text: secondary[300],
|
|
32
28
|
dark: {
|
|
33
|
-
text:
|
|
29
|
+
text: secondary[600],
|
|
34
30
|
},
|
|
35
31
|
})
|
|
36
32
|
|
|
37
33
|
if (props.filled) {
|
|
38
34
|
if (data.isActive) {
|
|
39
35
|
return css.variables({
|
|
40
|
-
bg: props.selected ? color[100] : color[
|
|
41
|
-
text: color[
|
|
36
|
+
bg: props.selected ? color[100] : color[200],
|
|
37
|
+
text: color[800],
|
|
42
38
|
hover: {
|
|
43
|
-
bg: props.selected ? color[
|
|
44
|
-
text: color[
|
|
39
|
+
bg: props.selected ? color[200] : color[200],
|
|
40
|
+
text: color[800],
|
|
45
41
|
},
|
|
46
42
|
dark: {
|
|
47
43
|
bg: props.selected ? color[700] : color[700],
|
|
@@ -55,18 +51,18 @@ const theme: MenuItemTheme = {
|
|
|
55
51
|
}
|
|
56
52
|
|
|
57
53
|
return css.variables({
|
|
58
|
-
bg: props.selected ?
|
|
59
|
-
text:
|
|
54
|
+
bg: props.selected ? secondary[100] : 'transparent',
|
|
55
|
+
text: secondary[800],
|
|
60
56
|
hover: {
|
|
61
|
-
bg:
|
|
62
|
-
text:
|
|
57
|
+
bg: secondary[100],
|
|
58
|
+
text: secondary[900],
|
|
63
59
|
},
|
|
64
60
|
dark: {
|
|
65
|
-
bg: props.selected ?
|
|
66
|
-
text:
|
|
61
|
+
bg: props.selected ? secondary[800] : 'transparent',
|
|
62
|
+
text: secondary[200],
|
|
67
63
|
hover: {
|
|
68
|
-
bg:
|
|
69
|
-
text:
|
|
64
|
+
bg: secondary[600],
|
|
65
|
+
text: secondary[100],
|
|
70
66
|
},
|
|
71
67
|
},
|
|
72
68
|
})
|
|
@@ -90,16 +86,16 @@ const theme: MenuItemTheme = {
|
|
|
90
86
|
}
|
|
91
87
|
|
|
92
88
|
return css.variables({
|
|
93
|
-
text:
|
|
89
|
+
text: secondary[800],
|
|
94
90
|
hover: {
|
|
95
|
-
text:
|
|
96
|
-
border:
|
|
91
|
+
text: secondary[900],
|
|
92
|
+
border: secondary[300],
|
|
97
93
|
},
|
|
98
94
|
dark: {
|
|
99
|
-
text:
|
|
95
|
+
text: secondary[300],
|
|
100
96
|
hover: {
|
|
101
|
-
text:
|
|
102
|
-
border:
|
|
97
|
+
text: secondary[200],
|
|
98
|
+
border: secondary[800],
|
|
103
99
|
},
|
|
104
100
|
},
|
|
105
101
|
})
|
|
@@ -36,6 +36,7 @@ const modalProps = {
|
|
|
36
36
|
type: [Array, Object] as PropType<[FormError[], FormError]>,
|
|
37
37
|
default: () => ([]),
|
|
38
38
|
},
|
|
39
|
+
persistent: Boolean,
|
|
39
40
|
}
|
|
40
41
|
|
|
41
42
|
export type ModalSize = typeof modalSize[number]
|
|
@@ -88,7 +89,7 @@ watch(value, (val) => {
|
|
|
88
89
|
|
|
89
90
|
if (val) {
|
|
90
91
|
setTimeout(() => {
|
|
91
|
-
stopClickOutside = onClickOutside(modalRef,
|
|
92
|
+
stopClickOutside = onClickOutside(modalRef, clickOutsideCallback)
|
|
92
93
|
})
|
|
93
94
|
}
|
|
94
95
|
})
|
|
@@ -120,7 +121,11 @@ async function checkVisibiliy() {
|
|
|
120
121
|
if (typeof window !== 'undefined') useEventListener(document, 'keydown', onKeyDown)
|
|
121
122
|
|
|
122
123
|
function onKeyDown(event: KeyboardEvent) {
|
|
123
|
-
if (event.key === 'Escape' && value.value) close()
|
|
124
|
+
if (event.key === 'Escape' && value.value && !props.persistent) close()
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
function clickOutsideCallback() {
|
|
128
|
+
if (!props.persistent) close()
|
|
124
129
|
}
|
|
125
130
|
|
|
126
131
|
function close() {
|
|
@@ -204,7 +209,7 @@ defineExpose({ open, close })
|
|
|
204
209
|
<x-button
|
|
205
210
|
v-if="showClose"
|
|
206
211
|
ghost
|
|
207
|
-
size="
|
|
212
|
+
size="sm"
|
|
208
213
|
tabindex="-1"
|
|
209
214
|
:icon="closeIcon"
|
|
210
215
|
:class="classes.closeIcon"
|
|
@@ -5,7 +5,7 @@ const theme: ModalTheme = {
|
|
|
5
5
|
wrapper: 'fixed z-40 inset-0 overflow-y-auto transition-all',
|
|
6
6
|
|
|
7
7
|
backdrop: ({ data }) => {
|
|
8
|
-
const classes = ['fixed inset-0 bg-
|
|
8
|
+
const classes = ['fixed inset-0 bg-secondary-500 dark:bg-black transition-opacity']
|
|
9
9
|
|
|
10
10
|
if (data.visible) classes.push('ease-out duration-200 opacity-30 dark:opacity-70')
|
|
11
11
|
else classes.push('ease-in duration-100 opacity-0')
|
|
@@ -14,7 +14,7 @@ const theme: ModalTheme = {
|
|
|
14
14
|
},
|
|
15
15
|
|
|
16
16
|
modal: ({ props, data }) => {
|
|
17
|
-
const classes = ['relative flex flex-col z-10 bg-white dark:bg-
|
|
17
|
+
const classes = ['relative flex flex-col z-10 bg-white dark:bg-secondary-900 rounded-md shadow-lg transform transition-all overflow-hidden max-h-full w-full']
|
|
18
18
|
|
|
19
19
|
if (data.visible) classes.push('ease-out duration-200 opacity-100 translate-y-0 sm:scale-100')
|
|
20
20
|
else classes.push('ease-in duration-200 opacity-0 translate-y-4 sm:translate-y-0 sm:scale-95')
|
|
@@ -33,14 +33,17 @@ const theme: ModalTheme = {
|
|
|
33
33
|
header: 'text-lg pl-6 py-4 border-b pr-12',
|
|
34
34
|
|
|
35
35
|
content: 'px-6 py-4',
|
|
36
|
+
actions: ({ props, slots }) => {
|
|
37
|
+
const classes = ['flex gap-4 bg-secondary-50 dark:bg-secondary-800 p-4 justify-end']
|
|
36
38
|
|
|
37
|
-
|
|
39
|
+
return classes
|
|
40
|
+
},
|
|
38
41
|
|
|
39
|
-
label: 'text-xs text-
|
|
42
|
+
label: 'text-xs text-secondary-500 mb-1',
|
|
40
43
|
|
|
41
|
-
title: 'text-xl font-semibold
|
|
44
|
+
title: 'text-xl font-semibold',
|
|
42
45
|
|
|
43
|
-
description: 'text-sm',
|
|
46
|
+
description: 'text-sm mb-8',
|
|
44
47
|
},
|
|
45
48
|
}
|
|
46
49
|
|
|
@@ -5,7 +5,7 @@ const theme: ModalTheme = {
|
|
|
5
5
|
wrapper: 'fixed z-40 inset-0 overflow-y-auto transition-all',
|
|
6
6
|
|
|
7
7
|
backdrop: ({ data }) => {
|
|
8
|
-
const classes = ['fixed inset-0 bg-
|
|
8
|
+
const classes = ['fixed inset-0 bg-secondary-500 dark:bg-black transition-opacity']
|
|
9
9
|
|
|
10
10
|
if (data.visible) classes.push('ease-out duration-200 opacity-70 dark:opacity-70')
|
|
11
11
|
else classes.push('ease-in duration-100 opacity-0')
|
|
@@ -14,7 +14,7 @@ const theme: ModalTheme = {
|
|
|
14
14
|
},
|
|
15
15
|
|
|
16
16
|
modal: ({ props, data }) => {
|
|
17
|
-
const classes = ['relative flex flex-col z-10 bg-
|
|
17
|
+
const classes = ['relative flex flex-col z-10 bg-secondary-200 dark:bg-secondary-900 shadow-lg transform transition-all overflow-hidden max-h-full w-full']
|
|
18
18
|
|
|
19
19
|
if (data.visible) classes.push('ease-out duration-200 opacity-100 translate-y-0 sm:scale-100')
|
|
20
20
|
else classes.push('ease-in duration-200 opacity-0 translate-y-4 sm:translate-y-0 sm:scale-95')
|
|
@@ -49,7 +49,7 @@ const theme: ModalTheme = {
|
|
|
49
49
|
return classes
|
|
50
50
|
},
|
|
51
51
|
|
|
52
|
-
label: 'text-xs text-
|
|
52
|
+
label: 'text-xs text-secondary-500 mb-1',
|
|
53
53
|
|
|
54
54
|
title: 'text-xl mb-4',
|
|
55
55
|
|
|
@@ -308,7 +308,7 @@ defineExpose({ log, info, success, warn, warning: warn, error })
|
|
|
308
308
|
<x-icon
|
|
309
309
|
v-if="notification.removable"
|
|
310
310
|
:icon="closeIcon"
|
|
311
|
-
class="text-
|
|
311
|
+
class="text-secondary-400 hover:text-secondary-500 ml-3 cursor-pointer"
|
|
312
312
|
@click="() => {remove(notification)}"
|
|
313
313
|
/>
|
|
314
314
|
</li>
|
|
@@ -6,7 +6,7 @@ const theme: NotificationsTheme = {
|
|
|
6
6
|
|
|
7
7
|
list: 'flex flex-col items-end w-full sm:w-[520px] px-4',
|
|
8
8
|
|
|
9
|
-
item: 'w-full flex items-center rounded-md px-4 py-3 bg-
|
|
9
|
+
item: 'w-full flex items-center rounded-md px-4 py-3 bg-secondary-800 dark:bg-secondary-50 text-white dark:text-secondary-900 border border-secondary-700 dark:border-secondary-100',
|
|
10
10
|
},
|
|
11
11
|
}
|
|
12
12
|
|
|
@@ -7,7 +7,7 @@ const theme: NotificationsTheme = {
|
|
|
7
7
|
list: 'flex flex-col items-end w-full sm:w-[520px] px-4',
|
|
8
8
|
|
|
9
9
|
item: () => {
|
|
10
|
-
const classes = ['w-full flex items-center px-4 py-3 bg-
|
|
10
|
+
const classes = ['w-full flex items-center px-4 py-3 bg-secondary-800 dark:bg-secondary-50 text-white dark:text-secondary-900 border-l-2 border-[color:var(--x-notification-icon)]']
|
|
11
11
|
|
|
12
12
|
return classes
|
|
13
13
|
},
|
|
@@ -111,7 +111,7 @@ const { styles, classes, className } = useTheme('Pagination', {}, props)
|
|
|
111
111
|
@click="prevPage"
|
|
112
112
|
/>
|
|
113
113
|
<div class="mx-9 flex items-center">
|
|
114
|
-
<span class="text-
|
|
114
|
+
<span class="text-secondary-600 mr-2">Page</span>
|
|
115
115
|
<x-input
|
|
116
116
|
v-model="quickInput"
|
|
117
117
|
:size="size"
|
|
@@ -119,7 +119,7 @@ const { styles, classes, className } = useTheme('Pagination', {}, props)
|
|
|
119
119
|
hide-footer
|
|
120
120
|
@keydown.enter="onQuickInput"
|
|
121
121
|
/>
|
|
122
|
-
<span class="text-
|
|
122
|
+
<span class="text-secondary-600 ml-2">of {{ totalPages }}</span>
|
|
123
123
|
</div>
|
|
124
124
|
<x-button
|
|
125
125
|
:icon-left="nextIcon"
|
|
@@ -163,7 +163,7 @@ const { styles, classes, className } = useTheme('Pagination', {}, props)
|
|
|
163
163
|
class="rounded-full cursor-pointer"
|
|
164
164
|
:class="[
|
|
165
165
|
classes.dots,
|
|
166
|
-
i === modelValue ? 'bg-[color:var(--x-pagination-bg)]': 'bg-
|
|
166
|
+
i === modelValue ? 'bg-[color:var(--x-pagination-bg)]': 'bg-secondary-100 hover:bg-secondary-200'
|
|
167
167
|
]"
|
|
168
168
|
@click="$emit('update:modelValue', i)"
|
|
169
169
|
></li>
|
|
@@ -23,6 +23,10 @@ const popoverProps = {
|
|
|
23
23
|
type: Array as PropType<Array<PopoverTriggerEvent>>,
|
|
24
24
|
default: () => ['click'],
|
|
25
25
|
},
|
|
26
|
+
hideArrow: {
|
|
27
|
+
type: Boolean,
|
|
28
|
+
default: true,
|
|
29
|
+
},
|
|
26
30
|
showTriggers: [Array, Function] as PropType<Array<PopoverTriggerEvent> | ((triggers: Array<PopoverTriggerEvent>) => Array<PopoverTriggerEvent>)>,
|
|
27
31
|
hideTriggers: [Array, Function] as PropType<Array<PopoverTriggerEvent> | ((triggers: Array<PopoverTriggerEvent>) => Array<PopoverTriggerEvent>)>,
|
|
28
32
|
popperTriggers: Array as PropType<Array<PopoverTriggerEvent>>,
|
|
@@ -121,7 +125,8 @@ const { styles, classes, className } = useTheme('Popover', {}, props)
|
|
|
121
125
|
:eager-mount="eagerMount"
|
|
122
126
|
:popper-class="[
|
|
123
127
|
classes.content,
|
|
124
|
-
popperClass
|
|
128
|
+
popperClass,
|
|
129
|
+
hideArrow ? 'v-popper__popper--no-arrow' : '',
|
|
125
130
|
]"
|
|
126
131
|
:compute-transform-origin="computeTransformOrigin"
|
|
127
132
|
@show="() => { isOpen = true; $emit('show') }"
|
|
@@ -142,6 +147,9 @@ const { styles, classes, className } = useTheme('Popover', {}, props)
|
|
|
142
147
|
</template>
|
|
143
148
|
|
|
144
149
|
<style lang="postcss">
|
|
150
|
+
/* stylelint-disable no-duplicate-selectors */
|
|
151
|
+
/* stylelint-disable no-descending-specificity */
|
|
152
|
+
/* stylelint-disable selector-class-pattern */
|
|
145
153
|
.resize-observer {
|
|
146
154
|
position: absolute;
|
|
147
155
|
top: 0;
|
|
@@ -168,7 +176,7 @@ const { styles, classes, className } = useTheme('Popover', {}, props)
|
|
|
168
176
|
z-index: -1;
|
|
169
177
|
}
|
|
170
178
|
}
|
|
171
|
-
|
|
179
|
+
|
|
172
180
|
.v-popper__popper {
|
|
173
181
|
z-index: 10000;
|
|
174
182
|
top: 0;
|
|
@@ -202,4 +210,71 @@ const { styles, classes, className } = useTheme('Popover', {}, props)
|
|
|
202
210
|
height: 100%;
|
|
203
211
|
display: none;
|
|
204
212
|
}
|
|
213
|
+
|
|
214
|
+
.v-popper__arrow-container {
|
|
215
|
+
position: absolute;
|
|
216
|
+
width: 10px;
|
|
217
|
+
height: 10px;
|
|
218
|
+
}
|
|
219
|
+
|
|
220
|
+
.v-popper__arrow-inner {
|
|
221
|
+
border-style: solid;
|
|
222
|
+
position: absolute;
|
|
223
|
+
top: 0;
|
|
224
|
+
left: 0;
|
|
225
|
+
width: 0;
|
|
226
|
+
height: 0;
|
|
227
|
+
visibility: hidden;
|
|
228
|
+
border-width: 7px;
|
|
229
|
+
}
|
|
230
|
+
.v-popper__arrow-outer { display: none; }
|
|
231
|
+
|
|
232
|
+
.v-popper__popper[data-popper-placement^="top"] .v-popper__arrow-inner,
|
|
233
|
+
.v-popper__popper[data-popper-placement^="bottom"] .v-popper__arrow-inner { left: -2px; }
|
|
234
|
+
|
|
235
|
+
.v-popper__popper[data-popper-placement^="top"] .v-popper__arrow-inner {
|
|
236
|
+
border-bottom-width: 0;
|
|
237
|
+
border-left-color: transparent !important;
|
|
238
|
+
border-right-color: transparent !important;
|
|
239
|
+
border-bottom-color: transparent !important;
|
|
240
|
+
}
|
|
241
|
+
.v-popper__popper[data-popper-placement^="top"] .v-popper__arrow-inner { top: -2px; }
|
|
242
|
+
.v-popper__popper[data-popper-placement^="bottom"] .v-popper__arrow-container { top: 0; }
|
|
243
|
+
|
|
244
|
+
.v-popper__popper[data-popper-placement^="bottom"] .v-popper__arrow-inner {
|
|
245
|
+
border-top-width: 0;
|
|
246
|
+
border-left-color: transparent !important;
|
|
247
|
+
border-right-color: transparent !important;
|
|
248
|
+
border-top-color: transparent !important;
|
|
249
|
+
}
|
|
250
|
+
.v-popper__popper[data-popper-placement^="bottom"] .v-popper__arrow-inner { top: -4px; }
|
|
251
|
+
|
|
252
|
+
.v-popper__popper[data-popper-placement^="left"] .v-popper__arrow-inner,
|
|
253
|
+
.v-popper__popper[data-popper-placement^="right"] .v-popper__arrow-inner { top: -2px; }
|
|
254
|
+
|
|
255
|
+
.v-popper__popper[data-popper-placement^="right"] .v-popper__arrow-inner {
|
|
256
|
+
border-left-width: 0;
|
|
257
|
+
border-left-color: transparent !important;
|
|
258
|
+
border-top-color: transparent !important;
|
|
259
|
+
border-bottom-color: transparent !important;
|
|
260
|
+
}
|
|
261
|
+
.v-popper__popper[data-popper-placement^="right"] .v-popper__arrow-inner { left: -4px; }
|
|
262
|
+
.v-popper__popper[data-popper-placement^="left"] .v-popper__arrow-container { right: -10px; }
|
|
263
|
+
|
|
264
|
+
.v-popper__popper[data-popper-placement^="left"] .v-popper__arrow-inner {
|
|
265
|
+
border-right-width: 0;
|
|
266
|
+
border-top-color: transparent !important;
|
|
267
|
+
border-right-color: transparent !important;
|
|
268
|
+
border-bottom-color: transparent !important;
|
|
269
|
+
}
|
|
270
|
+
.v-popper__popper[data-popper-placement^="left"] .v-popper__arrow-inner { left: -2px; }
|
|
271
|
+
|
|
272
|
+
.v-popper--theme-dropdown .v-popper__arrow-inner {
|
|
273
|
+
visibility: visible;
|
|
274
|
+
border-color: #374151;
|
|
275
|
+
}
|
|
276
|
+
|
|
277
|
+
.v-popper__popper--no-arrow .v-popper__arrow-container {
|
|
278
|
+
display: none;
|
|
279
|
+
}
|
|
205
280
|
</style>
|
|
@@ -2,7 +2,7 @@ import type { PopoverContainerTheme } from '../PopoverContainer.vue'
|
|
|
2
2
|
|
|
3
3
|
const theme: PopoverContainerTheme = {
|
|
4
4
|
classes: {
|
|
5
|
-
wrapper: 'block w-full bg-white dark:bg-
|
|
5
|
+
wrapper: 'block w-full bg-white dark:bg-secondary-700 shadow-lg rounded-md border border-secondary-200 dark:border-secondary-800',
|
|
6
6
|
},
|
|
7
7
|
}
|
|
8
8
|
|
|
@@ -2,7 +2,7 @@ import type { PopoverContainerTheme } from '../PopoverContainer.vue'
|
|
|
2
2
|
|
|
3
3
|
const theme: PopoverContainerTheme = {
|
|
4
4
|
classes: {
|
|
5
|
-
wrapper: 'block w-full bg-
|
|
5
|
+
wrapper: 'block w-full bg-secondary-100 dark:bg-secondary-700 shadow-lg border border-secondary-200 dark:border-secondary-800 text-sm',
|
|
6
6
|
},
|
|
7
7
|
}
|
|
8
8
|
|
|
@@ -53,7 +53,7 @@ const { styles, classes, className } = useTheme('Progress', {}, props)
|
|
|
53
53
|
</div>
|
|
54
54
|
<div
|
|
55
55
|
v-if="gradient"
|
|
56
|
-
class="absolute h-full bg-
|
|
56
|
+
class="absolute h-full bg-secondary-100 dark:bg-secondary-700 right-0 top-0"
|
|
57
57
|
:class="{ 'duration-150 transition-[width]': animate }"
|
|
58
58
|
:style="{
|
|
59
59
|
width: `${100 - percentage}%`
|
|
@@ -2,11 +2,11 @@ import type { ProgressTheme } from '../Progress.vue'
|
|
|
2
2
|
|
|
3
3
|
const theme: ProgressTheme = {
|
|
4
4
|
classes: {
|
|
5
|
-
wrapper: ({ props }) => `relative rounded bg-
|
|
5
|
+
wrapper: ({ props }) => `relative rounded bg-secondary-100 dark:bg-secondary-700 overflow-hidden pointer-events-none ${props.thick ? 'h-1.5' : 'h-1'}`,
|
|
6
6
|
|
|
7
7
|
list: 'flex flex-col items-end w-full sm:w-[520px] px-4',
|
|
8
8
|
|
|
9
|
-
item: 'w-full flex items-center rounded-md px-4 py-3 bg-
|
|
9
|
+
item: 'w-full flex items-center rounded-md px-4 py-3 bg-secondary-800 dark:bg-secondary-50 text-white dark:text-secondary-900',
|
|
10
10
|
},
|
|
11
11
|
|
|
12
12
|
styles: ({ props, colors, css }) => {
|
|
@@ -11,13 +11,13 @@ const theme: RadioTheme = {
|
|
|
11
11
|
},
|
|
12
12
|
|
|
13
13
|
circle: ({ props }) => {
|
|
14
|
-
|
|
14
|
+
const classes = ['rounded-full flex justify-center items-center shrink-0 border outline-offset-2 outline-slate-300 dark:outline-slate-500 group-focus:outline-1 group-focus:outline']
|
|
15
15
|
|
|
16
|
-
if (props.size === '
|
|
17
|
-
if (props.size === 'xl')
|
|
18
|
-
else
|
|
16
|
+
if (props.size === 'lg') classes.push('h-5 w-5')
|
|
17
|
+
else if (props.size === 'xl') classes.push('h-6 w-6')
|
|
18
|
+
else classes.push('h-4 w-4')
|
|
19
19
|
|
|
20
|
-
return
|
|
20
|
+
return classes
|
|
21
21
|
},
|
|
22
22
|
|
|
23
23
|
circleIcon: ({ props, data }) => {
|
|
@@ -28,13 +28,13 @@ const theme: RadioTheme = {
|
|
|
28
28
|
if (props.size === 'sm' || props.size === 'xs') c.push('h-2')
|
|
29
29
|
else if (props.size === 'lg') c.push('h-2.5')
|
|
30
30
|
else if (props.size === 'xl') c.push('h-3')
|
|
31
|
-
else c.push('h-
|
|
31
|
+
else c.push('h-2')
|
|
32
32
|
|
|
33
33
|
return c
|
|
34
34
|
},
|
|
35
35
|
|
|
36
36
|
label: ({ props }) => {
|
|
37
|
-
let c = 'font-medium text-
|
|
37
|
+
let c = 'font-medium text-secondary-800 dark:text-secondary-200 pl-2'
|
|
38
38
|
|
|
39
39
|
if (props.size === 'xs') c += ' text-xs'
|
|
40
40
|
else if (props.size === 'sm') c += ' text-sm'
|
|
@@ -112,7 +112,7 @@ const theme: RadioTheme = {
|
|
|
112
112
|
border: props.glow ? color[300] : gray[300],
|
|
113
113
|
dark: {
|
|
114
114
|
bg: gray[900],
|
|
115
|
-
border: props.glow ? color[300] : gray[
|
|
115
|
+
border: props.glow ? color[300] : gray[400],
|
|
116
116
|
},
|
|
117
117
|
}))
|
|
118
118
|
}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
<script lang="ts">
|
|
2
2
|
const selectProps = {
|
|
3
|
+
...useColors.props('primary'),
|
|
3
4
|
...useCommon.props(),
|
|
4
5
|
...useInteractive.props(),
|
|
5
6
|
...useInputtable.props(),
|
|
@@ -33,6 +34,7 @@ export default {
|
|
|
33
34
|
<script setup lang="ts">
|
|
34
35
|
import { computed, ref, watch, type PropType, type ExtractPublicPropTypes, type Ref, nextTick, unref } from 'vue'
|
|
35
36
|
import { useEventListener } from '@vueuse/core'
|
|
37
|
+
import { useColors } from '../../composables/useColors'
|
|
36
38
|
import { useCommon } from '../../composables/useCommon'
|
|
37
39
|
import { useInputtable } from '../../composables/useInputtable'
|
|
38
40
|
import { useInteractive } from '../../composables/useInteractive'
|
|
@@ -325,6 +327,7 @@ defineExpose({ focus, blur, reset, validate, setError })
|
|
|
325
327
|
className,
|
|
326
328
|
classes.wrapper,
|
|
327
329
|
]"
|
|
330
|
+
:tooltip="tooltip"
|
|
328
331
|
v-on="labelListeners"
|
|
329
332
|
>
|
|
330
333
|
<div class="relative">
|
|
@@ -347,7 +350,7 @@ defineExpose({ focus, blur, reset, validate, setError })
|
|
|
347
350
|
<template v-else>
|
|
348
351
|
<div
|
|
349
352
|
v-if="placeholder"
|
|
350
|
-
class="text-
|
|
353
|
+
class="text-secondary-400 dark:text-secondary-500"
|
|
351
354
|
>
|
|
352
355
|
{{ placeholder }}
|
|
353
356
|
</div>
|
|
@@ -381,7 +384,7 @@ defineExpose({ focus, blur, reset, validate, setError })
|
|
|
381
384
|
<template v-else>
|
|
382
385
|
<div
|
|
383
386
|
v-if="placeholder"
|
|
384
|
-
class="text-
|
|
387
|
+
class="text-secondary-400 dark:text-secondary-500"
|
|
385
388
|
>
|
|
386
389
|
{{ placeholder }}
|
|
387
390
|
</div>
|
|
@@ -400,12 +403,12 @@ defineExpose({ focus, blur, reset, validate, setError })
|
|
|
400
403
|
:size="size"
|
|
401
404
|
:disabled="item.disabled"
|
|
402
405
|
:selected="index === selectedIndex"
|
|
403
|
-
color="
|
|
406
|
+
:color="color"
|
|
404
407
|
filled
|
|
405
408
|
@click="() => !multiple && popoverRef?.hide()"
|
|
406
409
|
/>
|
|
407
410
|
</template>
|
|
408
|
-
<div v-else class="px-2 text-center text-
|
|
411
|
+
<div v-else class="px-2 text-center text-secondary-400">
|
|
409
412
|
No options
|
|
410
413
|
</div>
|
|
411
414
|
</x-popover-container>
|
|
@@ -5,9 +5,9 @@ const theme: SelectTheme = {
|
|
|
5
5
|
wrapper: '',
|
|
6
6
|
|
|
7
7
|
box: ({ props, data }) => {
|
|
8
|
-
const classes = ['w-full border border-
|
|
8
|
+
const classes = ['w-full border border-secondary-300 dark:border-secondary-700 pr-8 outline-transparent outline outline-2 outline-offset-[-1px] transition-all duration-150 ease-in-out rounded-md shadow-sm']
|
|
9
9
|
|
|
10
|
-
if (!data.errorInternal && !props.disabled) classes.push('hover:border-
|
|
10
|
+
if (!data.errorInternal && !props.disabled) classes.push('hover:border-secondary-400 dark:hover:border-secondary-500')
|
|
11
11
|
|
|
12
12
|
if (props.size === 'xs') classes.push('px-2 py-1 text-xs')
|
|
13
13
|
else if (props.size === 'sm') classes.push('px-2 py-2 text-sm')
|
|
@@ -15,11 +15,11 @@ const theme: SelectTheme = {
|
|
|
15
15
|
else if (props.size === 'xl') classes.push('px-5 py-4 text-xl')
|
|
16
16
|
else classes.push('px-3 py-2')
|
|
17
17
|
|
|
18
|
-
if (props.disabled) classes.push('bg-
|
|
19
|
-
else classes.push('bg-white dark:bg-
|
|
18
|
+
if (props.disabled) classes.push('bg-secondary-100 dark:bg-secondary-700 text-secondary-400 dark:text-secondary-600 cursor-not-allowed')
|
|
19
|
+
else classes.push('bg-white dark:bg-secondary-800 text-secondary-700 dark:text-secondary-200')
|
|
20
20
|
|
|
21
21
|
if (data.errorInternal) {
|
|
22
|
-
classes.push('border-
|
|
22
|
+
classes.push('border-error-500 dark:border-error-400 group-focus:outline-error-500')
|
|
23
23
|
} else if (!props.disabled) {
|
|
24
24
|
classes.push('group-focus:outline-[color:var(--x-select-border)]')
|
|
25
25
|
}
|
|
@@ -27,7 +27,7 @@ const theme: SelectTheme = {
|
|
|
27
27
|
return classes
|
|
28
28
|
},
|
|
29
29
|
|
|
30
|
-
content: '
|
|
30
|
+
content: 'p-1 max-h-72 overflow-y-auto',
|
|
31
31
|
|
|
32
32
|
iconWrapper: 'pointer-events-none absolute inset-y-0 right-0 flex items-center px-2',
|
|
33
33
|
|
|
@@ -39,8 +39,8 @@ const theme: SelectTheme = {
|
|
|
39
39
|
else if (props.size === 'xl') classes.push('h-7 w-7')
|
|
40
40
|
else classes.push('h-5 w-5')
|
|
41
41
|
|
|
42
|
-
if (props.disabled) classes.push('text-
|
|
43
|
-
else classes.push('text-
|
|
42
|
+
if (props.disabled) classes.push('text-secondary-300 dark:text-secondary-500')
|
|
43
|
+
else classes.push('text-secondary-500 dark:text-secondary-400')
|
|
44
44
|
|
|
45
45
|
return classes
|
|
46
46
|
},
|
|
@@ -5,24 +5,24 @@ const theme: SelectTheme = {
|
|
|
5
5
|
wrapper: '',
|
|
6
6
|
|
|
7
7
|
box: ({ props, data }) => {
|
|
8
|
-
const classes = ['w-full border-b text-sm px-4 border-
|
|
8
|
+
const classes = ['w-full border-b text-sm px-4 border-secondary-300 dark:border-secondary-700 pr-8 outline-transparent outline outline-2 outline-offset-[-1px] transition-all duration-150 ease-in-out']
|
|
9
9
|
|
|
10
|
-
if (!data.errorInternal && !props.disabled) classes.push('hover:border-
|
|
10
|
+
if (!data.errorInternal && !props.disabled) classes.push('hover:border-secondary-400 dark:hover:border-secondary-500')
|
|
11
11
|
|
|
12
12
|
if (props.size === 'xs' || props.size === 'sm') classes.push('py-1.5')
|
|
13
13
|
else if (props.size === 'lg' || props.size === 'xl') classes.push('py-3.5')
|
|
14
14
|
else classes.push('py-2.5')
|
|
15
15
|
|
|
16
16
|
if (props.disabled) {
|
|
17
|
-
classes.push('bg-
|
|
17
|
+
classes.push('bg-secondary-100 dark:bg-secondary-900 text-secondary-300 cursor-not-allowed')
|
|
18
18
|
} else if (props.readonly) {
|
|
19
|
-
classes.push('bg-white dark:bg-
|
|
19
|
+
classes.push('bg-white dark:bg-secondary-900 text-secondary-700')
|
|
20
20
|
} else {
|
|
21
|
-
classes.push('bg-
|
|
21
|
+
classes.push('bg-secondary-50 dark:bg-secondary-800 text-secondary-700 dark:text-secondary-200')
|
|
22
22
|
}
|
|
23
23
|
|
|
24
24
|
if (data.errorInternal) {
|
|
25
|
-
classes.push('border-
|
|
25
|
+
classes.push('border-error-500 dark:border-error-400 group-focus:outline-error-500')
|
|
26
26
|
} else if (!props.disabled) {
|
|
27
27
|
classes.push('group-focus:outline-[color:var(--x-select-border)]')
|
|
28
28
|
}
|
|
@@ -37,8 +37,8 @@ const theme: SelectTheme = {
|
|
|
37
37
|
icon: ({ props }) => {
|
|
38
38
|
const classes = ['h-5 w-5']
|
|
39
39
|
|
|
40
|
-
if (props.disabled) classes.push('text-
|
|
41
|
-
else classes.push('text-
|
|
40
|
+
if (props.disabled) classes.push('text-secondary-300 dark:text-secondary-500')
|
|
41
|
+
else classes.push('text-secondary-500 dark:text-secondary-400')
|
|
42
42
|
|
|
43
43
|
return classes
|
|
44
44
|
},
|
|
@@ -3,7 +3,7 @@ import type { SkeletonTheme } from '../Skeleton.vue'
|
|
|
3
3
|
const theme: SkeletonTheme = {
|
|
4
4
|
classes: {
|
|
5
5
|
wrapper: ({ props }) => {
|
|
6
|
-
const classes = ['animate-pulse bg-
|
|
6
|
+
const classes = ['animate-pulse bg-secondary-300 dark:bg-secondary-600']
|
|
7
7
|
|
|
8
8
|
if (props.shape === 'circle') classes.push('w-8 h-8 rounded-full')
|
|
9
9
|
else classes.push('rounded-md')
|
|
@@ -211,6 +211,6 @@ defineExpose({ focus, blur, reset, validate, setError })
|
|
|
211
211
|
<slot name="suffix" :value="value"></slot>
|
|
212
212
|
</div>
|
|
213
213
|
|
|
214
|
-
<p v-if="errorInternal" class="text-sm text-
|
|
214
|
+
<p v-if="errorInternal" class="text-sm text-error-500 mt-1" v-text="errorInternal"></p>
|
|
215
215
|
</x-label>
|
|
216
216
|
</template>
|