@dolanske/vui 1.4.0 → 1.4.2
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/components/Accordion/Accordion.vue.d.ts +48 -0
- package/dist/components/Accordion/AccordionGroup.vue.d.ts +21 -0
- package/dist/components/Alert/Alert.vue.d.ts +36 -0
- package/dist/components/Avatar/Avatar.vue.d.ts +25 -0
- package/dist/components/Badge/Badge.vue.d.ts +22 -0
- package/dist/components/Breadcrumbs/BreadcrumbItem.vue.d.ts +22 -0
- package/dist/components/Breadcrumbs/Breadcrumbs.vue.d.ts +18 -0
- package/dist/components/Button/Button.vue.d.ts +32 -0
- package/dist/components/ButtonGroup/ButtonGroup.vue.d.ts +22 -0
- package/dist/components/Calendar/Calendar.vue.d.ts +27 -0
- package/dist/components/Card/Card.vue.d.ts +26 -0
- package/dist/components/Checkbox/Checkbox.vue.d.ts +33 -0
- package/dist/components/CopyClipboard/CopyClipboard.vue.d.ts +46 -0
- package/dist/components/Divider/Divider.vue.d.ts +23 -0
- package/dist/components/Drawer/Drawer.vue.d.ts +53 -0
- package/dist/components/Dropdown/Dropdown.vue.d.ts +177 -0
- package/dist/components/Dropdown/DropdownItem.vue.d.ts +23 -0
- package/dist/components/Dropdown/DropdownTitle.vue.d.ts +21 -0
- package/dist/components/Flex/Flex.vue.d.ts +41 -0
- package/dist/components/Grid/Grid.vue.d.ts +35 -0
- package/dist/components/Input/Color.vue.d.ts +11 -0
- package/dist/components/Input/Counter.vue.d.ts +19 -0
- package/dist/components/Input/Dropzone.vue.d.ts +193 -0
- package/dist/components/Input/File.vue.d.ts +8 -0
- package/dist/components/Input/Input.vue.d.ts +56 -0
- package/dist/components/Input/Password.vue.d.ts +6 -0
- package/dist/components/Input/Textarea.vue.d.ts +31 -0
- package/dist/components/Kbd/Kbd.vue.d.ts +23 -0
- package/dist/components/Kbd/KbdGroup.vue.d.ts +19 -0
- package/dist/components/Modal/Confirm.vue.d.ts +43 -0
- package/dist/components/Modal/Modal.vue.d.ts +58 -0
- package/dist/components/OTP/OTP.vue.d.ts +44 -0
- package/dist/components/OTP/OTPItem.vue.d.ts +5 -0
- package/dist/components/Pagination/Pagination.vue.d.ts +46 -0
- package/dist/components/Pagination/pagination.d.ts +12 -0
- package/dist/components/Popout/Popout.vue.d.ts +36 -0
- package/dist/components/Progress/Progress.vue.d.ts +33 -0
- package/dist/components/Radio/Radio.vue.d.ts +29 -0
- package/dist/components/Radio/RadioGroup.vue.d.ts +27 -0
- package/dist/components/Select/Select.vue.d.ts +35 -0
- package/dist/components/Sheet/Sheet.vue.d.ts +47 -0
- package/dist/components/Sidebar/Sidebar.vue.d.ts +70 -0
- package/dist/components/Skeleton/Skeleton.vue.d.ts +8 -0
- package/dist/components/Spinner/Spinner.vue.d.ts +6 -0
- package/dist/components/Switch/Switch.vue.d.ts +28 -0
- package/dist/components/Table/Cell.vue.d.ts +22 -0
- package/dist/components/Table/Head.vue.d.ts +30 -0
- package/dist/components/Table/Root.vue.d.ts +41 -0
- package/dist/components/Table/SelectAll.vue.d.ts +2 -0
- package/dist/components/Table/SelectRow.vue.d.ts +6 -0
- package/dist/components/Table/index.d.ts +6 -0
- package/dist/components/Table/table.d.ts +68 -0
- package/dist/components/Tabs/Tab.vue.d.ts +22 -0
- package/dist/components/Tabs/Tabs.vue.d.ts +34 -0
- package/dist/components/Toast/Toasts.vue.d.ts +2 -0
- package/dist/components/Toast/toast.d.ts +287 -0
- package/dist/components/Tooltip/Tooltip.vue.d.ts +33 -0
- package/dist/fonts/GeistMono-Regular.ttf +0 -0
- package/dist/fonts/GeistMono-SemiBold.ttf +0 -0
- package/dist/fonts/Inter_18pt-Black.ttf +0 -0
- package/dist/fonts/Inter_18pt-Bold.ttf +0 -0
- package/dist/fonts/Inter_18pt-ExtraBold.ttf +0 -0
- package/dist/fonts/Inter_18pt-Light.ttf +0 -0
- package/dist/fonts/Inter_18pt-Medium.ttf +0 -0
- package/dist/fonts/Inter_18pt-Regular.ttf +0 -0
- package/dist/fonts/Inter_18pt-SemiBold.ttf +0 -0
- package/dist/index.d.ts +56 -0
- package/dist/internal/Backdrop/Backdrop.vue.d.ts +21 -0
- package/dist/shared/helpers.d.ts +34 -0
- package/dist/shared/slots.d.ts +20 -0
- package/dist/shared/theme.d.ts +3 -0
- package/dist/shared/types.d.ts +24 -0
- package/dist/vui.css +1 -0
- package/dist/vui.js +16215 -0
- package/package.json +1 -2
- package/src/App.vue +0 -103
- package/src/components/Accordion/Accordion.vue +0 -98
- package/src/components/Accordion/AccordionGroup.vue +0 -49
- package/src/components/Accordion/accordion.scss +0 -97
- package/src/components/Alert/Alert.vue +0 -59
- package/src/components/Alert/alert.scss +0 -162
- package/src/components/Avatar/Avatar.vue +0 -53
- package/src/components/Avatar/avatar.scss +0 -52
- package/src/components/Badge/Badge.vue +0 -21
- package/src/components/Badge/badge.scss +0 -210
- package/src/components/Breadcrumbs/BreadcrumbItem.vue +0 -26
- package/src/components/Breadcrumbs/Breadcrumbs.vue +0 -29
- package/src/components/Breadcrumbs/breadcrumbs.scss +0 -31
- package/src/components/Button/Button.vue +0 -86
- package/src/components/Button/button.scss +0 -292
- package/src/components/ButtonGroup/ButtonGroup.vue +0 -28
- package/src/components/ButtonGroup/button-group.scss +0 -51
- package/src/components/Calendar/Calendar.vue +0 -66
- package/src/components/Calendar/calendar.scss +0 -88
- package/src/components/Card/Card.vue +0 -48
- package/src/components/Card/card.scss +0 -55
- package/src/components/Checkbox/Checkbox.vue +0 -54
- package/src/components/Checkbox/checkbox.scss +0 -80
- package/src/components/CopyClipboard/CopyClipboard.vue +0 -98
- package/src/components/CopyClipboard/copy-clipboard.scss +0 -25
- package/src/components/Divider/Divider.vue +0 -38
- package/src/components/Divider/divider.scss +0 -37
- package/src/components/Drawer/Drawer.vue +0 -102
- package/src/components/Drawer/drawer.scss +0 -37
- package/src/components/Dropdown/Dropdown.vue +0 -120
- package/src/components/Dropdown/DropdownItem.vue +0 -33
- package/src/components/Dropdown/DropdownTitle.vue +0 -14
- package/src/components/Dropdown/dropdown-item.scss +0 -84
- package/src/components/Dropdown/dropdown.scss +0 -53
- package/src/components/Flex/Flex.vue +0 -113
- package/src/components/Grid/Grid.vue +0 -87
- package/src/components/Input/Color.vue +0 -26
- package/src/components/Input/Counter.vue +0 -66
- package/src/components/Input/Dropzone.vue +0 -65
- package/src/components/Input/File.vue +0 -15
- package/src/components/Input/Input.vue +0 -123
- package/src/components/Input/Password.vue +0 -35
- package/src/components/Input/Textarea.vue +0 -78
- package/src/components/Input/input.scss +0 -302
- package/src/components/Kbd/Kbd.vue +0 -48
- package/src/components/Kbd/KbdGroup.vue +0 -28
- package/src/components/Kbd/kbd.scss +0 -19
- package/src/components/Modal/Confirm.vue +0 -56
- package/src/components/Modal/Modal.vue +0 -103
- package/src/components/Modal/modal.scss +0 -54
- package/src/components/OTP/OTP.vue +0 -133
- package/src/components/OTP/OTPItem.vue +0 -37
- package/src/components/OTP/otp.scss +0 -84
- package/src/components/Pagination/Pagination.vue +0 -92
- package/src/components/Pagination/pagination.ts +0 -78
- package/src/components/Popout/Popout.vue +0 -73
- package/src/components/Popout/popout.scss +0 -16
- package/src/components/Progress/Progress.vue +0 -103
- package/src/components/Progress/progress.scss +0 -47
- package/src/components/Radio/Radio.vue +0 -38
- package/src/components/Radio/RadioGroup.vue +0 -34
- package/src/components/Radio/radio.scss +0 -78
- package/src/components/Select/Select.vue +0 -212
- package/src/components/Select/select.scss +0 -82
- package/src/components/Sheet/Sheet.vue +0 -106
- package/src/components/Sheet/sheet.scss +0 -71
- package/src/components/Sidebar/Sidebar.vue +0 -116
- package/src/components/Sidebar/sidebar.scss +0 -124
- package/src/components/Skeleton/Skeleton.vue +0 -43
- package/src/components/Skeleton/skeleton.scss +0 -14
- package/src/components/Spinner/Spinner.vue +0 -42
- package/src/components/Spinner/spinner.scss +0 -47
- package/src/components/Switch/Switch.vue +0 -31
- package/src/components/Switch/switch.scss +0 -93
- package/src/components/Table/Cell.vue +0 -23
- package/src/components/Table/Head.vue +0 -66
- package/src/components/Table/Root.vue +0 -66
- package/src/components/Table/SelectAll.vue +0 -23
- package/src/components/Table/SelectRow.vue +0 -30
- package/src/components/Table/index.ts +0 -7
- package/src/components/Table/table.scss +0 -155
- package/src/components/Table/table.ts +0 -248
- package/src/components/Tabs/Tab.vue +0 -25
- package/src/components/Tabs/Tabs.vue +0 -90
- package/src/components/Tabs/tabs.scss +0 -87
- package/src/components/Toast/Toasts.vue +0 -52
- package/src/components/Toast/toast.scss +0 -45
- package/src/components/Toast/toast.ts +0 -75
- package/src/components/Tooltip/Tooltip.vue +0 -78
- package/src/components/Tooltip/tooltip.scss +0 -5
- package/src/examples/ExampleAccordions.vue +0 -69
- package/src/examples/ExampleAlerts.vue +0 -78
- package/src/examples/ExampleAvatars.vue +0 -44
- package/src/examples/ExampleBadges.vue +0 -48
- package/src/examples/ExampleBreadcrumbs.vue +0 -46
- package/src/examples/ExampleButtons.vue +0 -148
- package/src/examples/ExampleCalendars.vue +0 -40
- package/src/examples/ExampleCards.vue +0 -94
- package/src/examples/ExampleCheckboxes.vue +0 -123
- package/src/examples/ExampleCopyClipboard.vue +0 -47
- package/src/examples/ExampleDividers.vue +0 -39
- package/src/examples/ExampleDrawers.vue +0 -67
- package/src/examples/ExampleDropdowns.vue +0 -114
- package/src/examples/ExampleFlexGrid.vue +0 -124
- package/src/examples/ExampleInputs.vue +0 -236
- package/src/examples/ExampleKBD.vue +0 -65
- package/src/examples/ExampleModals.vue +0 -143
- package/src/examples/ExamplePalette.vue +0 -165
- package/src/examples/ExamplePopouts.vue +0 -41
- package/src/examples/ExampleSheets.vue +0 -77
- package/src/examples/ExampleSidebars.vue +0 -276
- package/src/examples/ExampleSkeletons.vue +0 -26
- package/src/examples/ExampleSpinners.vue +0 -80
- package/src/examples/ExampleTables.vue +0 -359
- package/src/examples/ExampleTabs.vue +0 -142
- package/src/examples/ExampleToasts.vue +0 -96
- package/src/examples/ExampleTooltips.vue +0 -70
- package/src/examples/shared/ExampleColor.vue +0 -28
- package/src/index.ts +0 -116
- package/src/internal/Backdrop/Backdrop.vue +0 -22
- package/src/internal/Backdrop/backdrop.scss +0 -34
- package/src/main.ts +0 -5
- package/src/shared/helpers.ts +0 -124
- package/src/shared/slots.ts +0 -61
- package/src/shared/theme.ts +0 -22
- package/src/shared/types.ts +0 -29
- package/src/style/animation.scss +0 -50
- package/src/style/core.scss +0 -133
- package/src/style/fonts.scss +0 -73
- package/src/style/layout.scss +0 -179
- package/src/style/media-query.scss +0 -29
- package/src/style/reset.scss +0 -135
- package/src/style/text.scss +0 -137
- package/src/style/theme.scss +0 -195
- package/src/style/tooltip.scss +0 -146
- package/src/style/typography.scss +0 -435
- package/src/style/utils.scss +0 -36
- package/src/style.scss +0 -1
- package/src/vite-env.d.ts +0 -1
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
<script setup lang='ts'>
|
|
2
|
-
import type { Space } from '../../shared/types'
|
|
3
|
-
import Flex from '../Flex/Flex.vue'
|
|
4
|
-
import './button-group.scss'
|
|
5
|
-
|
|
6
|
-
interface Props {
|
|
7
|
-
vertical?: boolean
|
|
8
|
-
gap?: Space | number
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
const {
|
|
12
|
-
vertical,
|
|
13
|
-
gap = 0,
|
|
14
|
-
} = defineProps<Props>()
|
|
15
|
-
</script>
|
|
16
|
-
|
|
17
|
-
<template>
|
|
18
|
-
<Flex
|
|
19
|
-
:row="!vertical"
|
|
20
|
-
:column="vertical"
|
|
21
|
-
class="vui-button-group"
|
|
22
|
-
:class="{ vertical }"
|
|
23
|
-
:gap
|
|
24
|
-
inline
|
|
25
|
-
>
|
|
26
|
-
<slot />
|
|
27
|
-
</Flex>
|
|
28
|
-
</template>
|
|
@@ -1,51 +0,0 @@
|
|
|
1
|
-
.vui-button-group {
|
|
2
|
-
.vui-button {
|
|
3
|
-
z-index: var(--z-default);
|
|
4
|
-
|
|
5
|
-
&:hover {
|
|
6
|
-
z-index: var(--z-active);
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
&:not(:first-child, :last-child) {
|
|
10
|
-
border-radius: 0;
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
&:first-child {
|
|
14
|
-
border-top-right-radius: 0;
|
|
15
|
-
border-bottom-right-radius: 0;
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
&:last-child {
|
|
19
|
-
border-top-left-radius: 0;
|
|
20
|
-
border-bottom-left-radius: 0;
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
&:not(:last-child) {
|
|
24
|
-
margin-right: 0px;
|
|
25
|
-
}
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
&.vertical {
|
|
29
|
-
.vui-button {
|
|
30
|
-
width: 100%;
|
|
31
|
-
|
|
32
|
-
&:not(:first-child, :last-child) {
|
|
33
|
-
border-radius: 0;
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
&:first-child {
|
|
37
|
-
border-bottom-left-radius: 0;
|
|
38
|
-
border-bottom-right-radius: 0;
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
&:last-child {
|
|
42
|
-
border-top-left-radius: 0;
|
|
43
|
-
border-top-right-radius: 0;
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
&:not(:last-child) {
|
|
47
|
-
margin-bottom: 0px;
|
|
48
|
-
}
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
|
-
}
|
|
@@ -1,66 +0,0 @@
|
|
|
1
|
-
<script setup lang='ts'>
|
|
2
|
-
import type { VueDatePickerProps } from '@vuepic/vue-datepicker'
|
|
3
|
-
import { Icon } from '@iconify/vue'
|
|
4
|
-
import VueDatePicker from '@vuepic/vue-datepicker'
|
|
5
|
-
import { useAttrs } from 'vue'
|
|
6
|
-
import { theme } from '../../shared/theme'
|
|
7
|
-
import '@vuepic/vue-datepicker/dist/main.css'
|
|
8
|
-
import './calendar.scss'
|
|
9
|
-
|
|
10
|
-
const props = withDefaults(defineProps<VueDatePickerProps & {
|
|
11
|
-
expand?: boolean
|
|
12
|
-
}>(), {
|
|
13
|
-
autoApply: true,
|
|
14
|
-
autoPosition: true,
|
|
15
|
-
format: 'dd/MM/yyyy HH:mm',
|
|
16
|
-
monthNameFormat: 'long',
|
|
17
|
-
expand: false,
|
|
18
|
-
})
|
|
19
|
-
|
|
20
|
-
const ICON_SIZE = 18
|
|
21
|
-
const attrs = useAttrs()
|
|
22
|
-
</script>
|
|
23
|
-
|
|
24
|
-
<template>
|
|
25
|
-
<VueDatePicker
|
|
26
|
-
v-bind="{ ...props, ...attrs }"
|
|
27
|
-
class="vui-calendar"
|
|
28
|
-
:class="{ 'vui-calendar-inline': props.inline }"
|
|
29
|
-
:style="props.expand ?? !$slots.trigger
|
|
30
|
-
? undefined
|
|
31
|
-
: { display: 'inline-block', width: 'auto' }
|
|
32
|
-
"
|
|
33
|
-
:dark="theme === 'dark'"
|
|
34
|
-
>
|
|
35
|
-
<!-- Icon slots -->
|
|
36
|
-
<template #input-icon>
|
|
37
|
-
<Icon :width="ICON_SIZE" :height="ICON_SIZE" icon="ph:calendar-blank" />
|
|
38
|
-
</template>
|
|
39
|
-
<template #calendar-icon>
|
|
40
|
-
<Icon :width="ICON_SIZE" :height="ICON_SIZE" icon="ph:calendar-blank" />
|
|
41
|
-
</template>
|
|
42
|
-
<template #clear-icon>
|
|
43
|
-
<Icon :width="ICON_SIZE" :height="ICON_SIZE" icon="ph:x" />
|
|
44
|
-
</template>
|
|
45
|
-
<template #clock-icon>
|
|
46
|
-
<Icon :width="ICON_SIZE" :height="ICON_SIZE" icon="ph:clock" />
|
|
47
|
-
</template>
|
|
48
|
-
<template #arrow-left>
|
|
49
|
-
<Icon :width="ICON_SIZE" :height="ICON_SIZE" icon="ph:caret-left" />
|
|
50
|
-
</template>
|
|
51
|
-
<template #arrow-right>
|
|
52
|
-
<Icon :width="ICON_SIZE" :height="ICON_SIZE" icon="ph:caret-right" />
|
|
53
|
-
</template>
|
|
54
|
-
<template #arrow-up>
|
|
55
|
-
<Icon :width="ICON_SIZE" :height="ICON_SIZE" icon="ph:caret-up" />
|
|
56
|
-
</template>
|
|
57
|
-
<template #arrow-down>
|
|
58
|
-
<Icon :width="ICON_SIZE" :height="ICON_SIZE" icon="ph:caret-down" />
|
|
59
|
-
</template>
|
|
60
|
-
|
|
61
|
-
<!-- Content slots -->
|
|
62
|
-
<template v-if="$slots.trigger" #trigger>
|
|
63
|
-
<slot name="trigger" />
|
|
64
|
-
</template>
|
|
65
|
-
</VueDatePicker>
|
|
66
|
-
</template>
|
|
@@ -1,88 +0,0 @@
|
|
|
1
|
-
.dp__theme_light,
|
|
2
|
-
.dp__theme_dark {
|
|
3
|
-
--dp-background-color: var(--color-bg);
|
|
4
|
-
--dp-text-color: var(--color-text);
|
|
5
|
-
--dp-hover-color: var(--color-button-gray-hover);
|
|
6
|
-
--dp-hover-text-color: var(--color-text);
|
|
7
|
-
--dp-hover-icon-color: var(--color-text-lighter);
|
|
8
|
-
--dp-primary-color: var(--color-accent);
|
|
9
|
-
--dp-primary-disabled-color: var(--color-accent-disabled);
|
|
10
|
-
--dp-primary-text-color: var(--color-text-invert);
|
|
11
|
-
--dp-secondary-color: var(--color-border);
|
|
12
|
-
--dp-border-color: var(--color-border);
|
|
13
|
-
--dp-menu-border-color: var(--color-border);
|
|
14
|
-
--dp-border-color-hover: var(--color-border-strong);
|
|
15
|
-
--dp-border-color-focus: var(--color-border-strong);
|
|
16
|
-
--dp-disabled-color: var(--color-bg-raised);
|
|
17
|
-
--dp-disabled-color-text: var(--color-text-light);
|
|
18
|
-
--dp-scroll-bar-background: var(--color-bg-lowered);
|
|
19
|
-
--dp-scroll-bar-color: var(--color-border);
|
|
20
|
-
--dp-success-color: var(--color-green);
|
|
21
|
-
--dp-success-color-disabled: var(--color-green-disabled);
|
|
22
|
-
--dp-icon-color: var(--color-text-light);
|
|
23
|
-
--dp-danger-color: var(--color-red);
|
|
24
|
-
--dp-marker-color: var(--color-red);
|
|
25
|
-
--dp-tooltip-color: var(--color-bg-raised);
|
|
26
|
-
--dp-highlight-color: var(--color-bg-raised);
|
|
27
|
-
--dp-range-between-dates-background-color: var(--dp-hover-color, #484848);
|
|
28
|
-
--dp-range-between-dates-text-color: var(--dp-hover-text-color, #fff);
|
|
29
|
-
--dp-range-between-border-color: var(--dp-hover-color, #fff);
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
// TODO: dp theme light
|
|
33
|
-
|
|
34
|
-
.dp__theme_light {
|
|
35
|
-
--dp-primary-text-color: var(--color-text);
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
:root {
|
|
39
|
-
--dp-font-family: var(--global-font);
|
|
40
|
-
--dp-border-radius: var(--border-radius-s);
|
|
41
|
-
--dp-cell-border-radius: var(--border-radius-s);
|
|
42
|
-
--dp-common-transition: var(--transition);
|
|
43
|
-
|
|
44
|
-
--dp-font-size: var(--font-size-m);
|
|
45
|
-
--dp-preview-font-size: var(--font-size-s);
|
|
46
|
-
--dp-time-font-size: var(--font-size-s);
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
.vui-calendar-inline {
|
|
50
|
-
.dp__outer_menu_wrap {
|
|
51
|
-
box-shadow: none;
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
.dp__menu {
|
|
55
|
-
border: none;
|
|
56
|
-
}
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
.dp__overlay_cell_pad {
|
|
60
|
-
font-size: var(--font-size-m);
|
|
61
|
-
text-transform: capitalize;
|
|
62
|
-
font-weight: var(--font-weight-medium);
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
.dp__main {
|
|
66
|
-
font-size: var(--font-size-m);
|
|
67
|
-
font-weight: var(--font-weight);
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
.dp__btn {
|
|
71
|
-
font-weight: var(--font-medium);
|
|
72
|
-
}
|
|
73
|
-
|
|
74
|
-
.dp__outer_menu_wrap {
|
|
75
|
-
box-shadow: var(--box-shadow-strong);
|
|
76
|
-
}
|
|
77
|
-
|
|
78
|
-
.dp__input_icon {
|
|
79
|
-
inset-inline-start: 8px;
|
|
80
|
-
}
|
|
81
|
-
|
|
82
|
-
.dp--clear-btn {
|
|
83
|
-
inset-inline-end: 8px;
|
|
84
|
-
}
|
|
85
|
-
|
|
86
|
-
.dp__input {
|
|
87
|
-
height: var(--interactive-el-height);
|
|
88
|
-
}
|
|
@@ -1,48 +0,0 @@
|
|
|
1
|
-
<script setup lang="ts">
|
|
2
|
-
import Divider from '../Divider/Divider.vue'
|
|
3
|
-
import './card.scss'
|
|
4
|
-
|
|
5
|
-
export interface Props {
|
|
6
|
-
separators?: boolean
|
|
7
|
-
headerSeparator?: boolean
|
|
8
|
-
footerSeparator?: boolean
|
|
9
|
-
padding?: boolean
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
const {
|
|
13
|
-
padding = true,
|
|
14
|
-
separators,
|
|
15
|
-
headerSeparator,
|
|
16
|
-
footerSeparator,
|
|
17
|
-
} = defineProps<Props>()
|
|
18
|
-
</script>
|
|
19
|
-
|
|
20
|
-
<template>
|
|
21
|
-
<div
|
|
22
|
-
class="vui-card" :class="{
|
|
23
|
-
separators,
|
|
24
|
-
'header-separator': headerSeparator,
|
|
25
|
-
'footer-separator': footerSeparator,
|
|
26
|
-
'no-padding': !padding,
|
|
27
|
-
}"
|
|
28
|
-
>
|
|
29
|
-
<div v-if="$slots.header || $slots['header-end']" class="vui-card-header">
|
|
30
|
-
<div class="flex-1">
|
|
31
|
-
<slot name="header" />
|
|
32
|
-
</div>
|
|
33
|
-
<slot name="header-end" />
|
|
34
|
-
</div>
|
|
35
|
-
|
|
36
|
-
<Divider v-if="(separators || headerSeparator) && ($slots.header || $slots['header-end'])" :size="1" />
|
|
37
|
-
|
|
38
|
-
<div v-if="$slots.default" class="vui-card-content">
|
|
39
|
-
<slot />
|
|
40
|
-
</div>
|
|
41
|
-
|
|
42
|
-
<Divider v-if="(separators || footerSeparator) && $slots.footer" :size="1" />
|
|
43
|
-
|
|
44
|
-
<div v-if="$slots.footer" class="vui-card-footer">
|
|
45
|
-
<slot name="footer" />
|
|
46
|
-
</div>
|
|
47
|
-
</div>
|
|
48
|
-
</template>
|
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
.vui-card {
|
|
2
|
-
display: block;
|
|
3
|
-
width: 100%;
|
|
4
|
-
background-color: var(--color-bg);
|
|
5
|
-
border-radius: var(--border-radius-m);
|
|
6
|
-
border: 1px solid var(--color-border);
|
|
7
|
-
|
|
8
|
-
&.no-padding {
|
|
9
|
-
.vui-card-header,
|
|
10
|
-
.vui-card-content,
|
|
11
|
-
.vui-card-footer {
|
|
12
|
-
padding: 0;
|
|
13
|
-
}
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
&:not(.separators) {
|
|
17
|
-
// &:not(.header-separator) .vui-card-content:first-child {
|
|
18
|
-
// padding-bottom: var(--space-xs);
|
|
19
|
-
// }
|
|
20
|
-
|
|
21
|
-
&.header-separator {
|
|
22
|
-
.vui-card-content:not(:first-child) {
|
|
23
|
-
padding-top: var(--space-m);
|
|
24
|
-
// padding-block: var(--space-m);
|
|
25
|
-
}
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
&.footer-separator {
|
|
29
|
-
.vui-card-content {
|
|
30
|
-
padding-bottom: var(--space-m);
|
|
31
|
-
}
|
|
32
|
-
}
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
.vui-card-header {
|
|
36
|
-
display: flex;
|
|
37
|
-
align-items: center;
|
|
38
|
-
justify-content: space-between;
|
|
39
|
-
padding: var(--space-s) var(--space-m);
|
|
40
|
-
background-color: var(--color-bg);
|
|
41
|
-
border-top-left-radius: var(--border-radius-m);
|
|
42
|
-
border-top-right-radius: var(--border-radius-m);
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
.vui-card-content {
|
|
46
|
-
padding: var(--space-m);
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
.vui-card-footer {
|
|
50
|
-
padding: var(--space-s) var(--space-m);
|
|
51
|
-
background-color: var(--color-bg);
|
|
52
|
-
border-bottom-left-radius: var(--border-radius-m);
|
|
53
|
-
border-bottom-right-radius: var(--border-radius-m);
|
|
54
|
-
}
|
|
55
|
-
}
|
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
<script setup lang="ts">
|
|
2
|
-
import { Icon } from '@iconify/vue'
|
|
3
|
-
import { useId } from 'vue'
|
|
4
|
-
import './checkbox.scss'
|
|
5
|
-
|
|
6
|
-
interface Props {
|
|
7
|
-
label?: string
|
|
8
|
-
iconOn?: string
|
|
9
|
-
iconOff?: string
|
|
10
|
-
disabled?: boolean
|
|
11
|
-
checked?: boolean
|
|
12
|
-
accent?: boolean
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
const {
|
|
16
|
-
label,
|
|
17
|
-
// iconOn = theme.value === 'light' ? 'ph:check-square-fill' : 'ph:check-square',
|
|
18
|
-
iconOn = 'ph:check-square-fill',
|
|
19
|
-
iconOff = 'ph:square',
|
|
20
|
-
disabled,
|
|
21
|
-
checked: checkedProp,
|
|
22
|
-
accent,
|
|
23
|
-
} = defineProps<Props>()
|
|
24
|
-
const emit = defineEmits<{
|
|
25
|
-
change: [checked: boolean]
|
|
26
|
-
}>()
|
|
27
|
-
const slots = defineSlots()
|
|
28
|
-
const checked = defineModel<boolean>()
|
|
29
|
-
const id = useId()
|
|
30
|
-
</script>
|
|
31
|
-
|
|
32
|
-
<template>
|
|
33
|
-
<div class="vui-checkbox" :class="{ disabled: !!disabled, checked, accent }">
|
|
34
|
-
<input
|
|
35
|
-
:id
|
|
36
|
-
v-model="checked"
|
|
37
|
-
type="checkbox"
|
|
38
|
-
:disabled
|
|
39
|
-
:checked="checkedProp"
|
|
40
|
-
@change="(e) => {
|
|
41
|
-
if (disabled) return
|
|
42
|
-
emit('change', (e.target as HTMLInputElement).checked)
|
|
43
|
-
}"
|
|
44
|
-
>
|
|
45
|
-
<label :for="id">
|
|
46
|
-
<span class="vui-checkbox-icon">
|
|
47
|
-
<Icon :icon="checked ? iconOn : iconOff" />
|
|
48
|
-
</span>
|
|
49
|
-
<p v-if="label || slots.default" class="vui-checkbox-content">
|
|
50
|
-
<slot>{{ label }}</slot>
|
|
51
|
-
</p>
|
|
52
|
-
</label>
|
|
53
|
-
</div>
|
|
54
|
-
</template>
|
|
@@ -1,80 +0,0 @@
|
|
|
1
|
-
.vui-checkbox {
|
|
2
|
-
--checkbox-size: 24px;
|
|
3
|
-
|
|
4
|
-
&.checked {
|
|
5
|
-
.vui-checkbox-icon svg {
|
|
6
|
-
color: var(--color-text);
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
&.accent .vui-checkbox-icon svg {
|
|
10
|
-
color: var(--color-accent);
|
|
11
|
-
}
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
&.disabled {
|
|
15
|
-
.vui-checkbox-icon {
|
|
16
|
-
opacity: 0.25;
|
|
17
|
-
cursor: not-allowed;
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
input + label .vui-checkbox-content {
|
|
21
|
-
opacity: 0.4;
|
|
22
|
-
cursor: not-allowed;
|
|
23
|
-
}
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
.vui-checkbox-icon {
|
|
27
|
-
width: var(--checkbox-size);
|
|
28
|
-
height: var(--checkbox-size);
|
|
29
|
-
|
|
30
|
-
svg {
|
|
31
|
-
width: 100%;
|
|
32
|
-
height: 100%;
|
|
33
|
-
color: var(--color-text);
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
input {
|
|
38
|
-
width: 1px;
|
|
39
|
-
height: 1px;
|
|
40
|
-
position: absolute;
|
|
41
|
-
overflow: hidden;
|
|
42
|
-
outline: none !important;
|
|
43
|
-
opacity: 0;
|
|
44
|
-
|
|
45
|
-
&:focus-visible + label .vui-checkbox-icon {
|
|
46
|
-
outline: 2px solid var(--color-text);
|
|
47
|
-
border-radius: var(--border-radius-s);
|
|
48
|
-
cursor: default;
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
& + label {
|
|
52
|
-
display: grid;
|
|
53
|
-
grid-template-columns: 20px 1fr;
|
|
54
|
-
gap: 10px;
|
|
55
|
-
font-size: var(--font-size-m);
|
|
56
|
-
color: var(--color-text);
|
|
57
|
-
user-select: none;
|
|
58
|
-
align-items: baseline;
|
|
59
|
-
|
|
60
|
-
.vui-checkbox-content {
|
|
61
|
-
display: block;
|
|
62
|
-
|
|
63
|
-
&:is(p) {
|
|
64
|
-
display: flex;
|
|
65
|
-
align-items: center;
|
|
66
|
-
min-height: var(--checkbox-size);
|
|
67
|
-
font-size: var(--font-size-m);
|
|
68
|
-
align-self: flex-start;
|
|
69
|
-
// line-height: var(--checkbox-size);
|
|
70
|
-
}
|
|
71
|
-
}
|
|
72
|
-
}
|
|
73
|
-
}
|
|
74
|
-
}
|
|
75
|
-
|
|
76
|
-
:root.light {
|
|
77
|
-
.vui-checkbox.checked.accent .vui-checkbox-icon svg {
|
|
78
|
-
color: var(--color-accent);
|
|
79
|
-
}
|
|
80
|
-
}
|
|
@@ -1,98 +0,0 @@
|
|
|
1
|
-
<script setup lang='ts'>
|
|
2
|
-
import type { Placement } from '@floating-ui/vue'
|
|
3
|
-
import { autoUpdate, flip, offset, shift, useFloating } from '@floating-ui/vue'
|
|
4
|
-
import { Icon } from '@iconify/vue'
|
|
5
|
-
import { useClipboard } from '@vueuse/core'
|
|
6
|
-
import { computed, onMounted, useSlots, useTemplateRef } from 'vue'
|
|
7
|
-
import { getPlacementAnimationName, isNil } from '../../shared/helpers'
|
|
8
|
-
import Flex from '../Flex/Flex.vue'
|
|
9
|
-
import './copy-clipboard.scss'
|
|
10
|
-
|
|
11
|
-
interface Props {
|
|
12
|
-
/**
|
|
13
|
-
* Text to copy
|
|
14
|
-
*/
|
|
15
|
-
text: string
|
|
16
|
-
/**
|
|
17
|
-
* Wether to show a tooltip after successful copy
|
|
18
|
-
*/
|
|
19
|
-
confirm?: string | boolean
|
|
20
|
-
/**
|
|
21
|
-
* How long will the copy confirmation tooltip be visible in milliseconds.
|
|
22
|
-
*/
|
|
23
|
-
confirmTime?: number
|
|
24
|
-
/**
|
|
25
|
-
* Tooltip position. Default is top
|
|
26
|
-
*/
|
|
27
|
-
confirmPlacement?: Placement
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
const {
|
|
31
|
-
text,
|
|
32
|
-
confirm,
|
|
33
|
-
confirmTime,
|
|
34
|
-
confirmPlacement = 'top',
|
|
35
|
-
} = defineProps<Props>()
|
|
36
|
-
|
|
37
|
-
const {
|
|
38
|
-
copy,
|
|
39
|
-
copied,
|
|
40
|
-
isSupported,
|
|
41
|
-
} = useClipboard({
|
|
42
|
-
copiedDuring: confirmTime,
|
|
43
|
-
})
|
|
44
|
-
const slots = useSlots()
|
|
45
|
-
|
|
46
|
-
const parsedConfirm = computed(() => {
|
|
47
|
-
if (isNil(confirm))
|
|
48
|
-
return false
|
|
49
|
-
if (confirm === '')
|
|
50
|
-
return true
|
|
51
|
-
else return confirm
|
|
52
|
-
})
|
|
53
|
-
|
|
54
|
-
onMounted(() => {
|
|
55
|
-
if (!isSupported.value) {
|
|
56
|
-
console.error('Clipboard API is not supported. This component will not work')
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
if (typeof parsedConfirm.value === 'string' && slots.confirm) {
|
|
60
|
-
console.warn('[ClipBoard] You are using the \'confirm\' prop and slot. The slot will take precedence.')
|
|
61
|
-
}
|
|
62
|
-
})
|
|
63
|
-
|
|
64
|
-
const anchorRef = useTemplateRef('anchor')
|
|
65
|
-
const tooltipRef = useTemplateRef('tooltip')
|
|
66
|
-
|
|
67
|
-
const { floatingStyles } = useFloating(anchorRef, tooltipRef, {
|
|
68
|
-
whileElementsMounted: autoUpdate,
|
|
69
|
-
transform: false,
|
|
70
|
-
strategy: 'fixed',
|
|
71
|
-
placement: confirmPlacement,
|
|
72
|
-
middleware: [
|
|
73
|
-
offset(8),
|
|
74
|
-
shift(),
|
|
75
|
-
flip(),
|
|
76
|
-
],
|
|
77
|
-
})
|
|
78
|
-
</script>
|
|
79
|
-
|
|
80
|
-
<template>
|
|
81
|
-
<div ref="anchor" class="vui-clipboard-copy-wrap" role="button" @click="copy(text)">
|
|
82
|
-
<slot :copy :copied />
|
|
83
|
-
</div>
|
|
84
|
-
|
|
85
|
-
<Transition :name="getPlacementAnimationName(confirmPlacement)" mode="in-out">
|
|
86
|
-
<div v-if="copied && (!!parsedConfirm || $slots.confirm)" ref="tooltip" class="vui-clipboard-tooltip" :style="floatingStyles">
|
|
87
|
-
<slot name="confirm">
|
|
88
|
-
<template v-if="typeof parsedConfirm === 'string'">
|
|
89
|
-
{{ parsedConfirm }}
|
|
90
|
-
</template>
|
|
91
|
-
<Flex v-else y-center x-center>
|
|
92
|
-
<Icon width="16" height="16" icon="ph:check-bold" />
|
|
93
|
-
Copied to clipboard
|
|
94
|
-
</Flex>
|
|
95
|
-
</slot>
|
|
96
|
-
</div>
|
|
97
|
-
</Transition>
|
|
98
|
-
</template>
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
.vui-clipboard-copy-wrap {
|
|
2
|
-
display: inline-block;
|
|
3
|
-
position: relative;
|
|
4
|
-
}
|
|
5
|
-
|
|
6
|
-
.vui-clipboard-tooltip {
|
|
7
|
-
padding: 6px 8px;
|
|
8
|
-
border-radius: var(--border-radius-s);
|
|
9
|
-
background-color: var(--color-bg-raised);
|
|
10
|
-
font-size: var(--font-size-m);
|
|
11
|
-
color: var(--color-text);
|
|
12
|
-
box-shadow: var(--box-shadow);
|
|
13
|
-
z-index: var(--z-popout);
|
|
14
|
-
|
|
15
|
-
svg path {
|
|
16
|
-
color: var(--color-text);
|
|
17
|
-
}
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
:root.light {
|
|
21
|
-
.vui-clipboard-tooltip {
|
|
22
|
-
background-color: var(--color-bg);
|
|
23
|
-
box-shadow: var(--box-shadow-strong);
|
|
24
|
-
}
|
|
25
|
-
}
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
<script setup lang="ts">
|
|
2
|
-
import { computed } from 'vue'
|
|
3
|
-
import { formatUnitValue } from '../../shared/helpers'
|
|
4
|
-
import './divider.scss'
|
|
5
|
-
|
|
6
|
-
interface Props {
|
|
7
|
-
thickness?: number
|
|
8
|
-
size?: number | string
|
|
9
|
-
vertical?: boolean
|
|
10
|
-
margin?: string | number
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
const {
|
|
14
|
-
thickness = 1,
|
|
15
|
-
size = 32,
|
|
16
|
-
vertical,
|
|
17
|
-
margin = '0',
|
|
18
|
-
} = defineProps<Props>()
|
|
19
|
-
|
|
20
|
-
const h = computed(() => formatUnitValue(size))
|
|
21
|
-
const w = computed(() => vertical ? h.value : 'initial')
|
|
22
|
-
const m = computed(() => formatUnitValue(margin))
|
|
23
|
-
</script>
|
|
24
|
-
|
|
25
|
-
<template>
|
|
26
|
-
<div
|
|
27
|
-
class="vui-divider" :class="{ vertical }" :style="{
|
|
28
|
-
margin: m,
|
|
29
|
-
width: w,
|
|
30
|
-
height: h,
|
|
31
|
-
}"
|
|
32
|
-
>
|
|
33
|
-
<hr :style="{ [vertical ? 'borderRightWidth' : 'borderBottomWidth']: `${thickness}px` }">
|
|
34
|
-
<div v-if="$slots.default" class="vui-divider-slot">
|
|
35
|
-
<slot />
|
|
36
|
-
</div>
|
|
37
|
-
</div>
|
|
38
|
-
</template>
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
.vui-divider {
|
|
2
|
-
display: flex;
|
|
3
|
-
align-items: center;
|
|
4
|
-
justify-content: center;
|
|
5
|
-
position: relative;
|
|
6
|
-
height: 32px;
|
|
7
|
-
width: 100%;
|
|
8
|
-
|
|
9
|
-
&.vertical hr {
|
|
10
|
-
transform: translateX(-50%);
|
|
11
|
-
width: 1px;
|
|
12
|
-
height: 100%;
|
|
13
|
-
border-right-color: var(--color-border);
|
|
14
|
-
border-right-style: solid;
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
hr {
|
|
18
|
-
display: block;
|
|
19
|
-
transform: translateY(-50%);
|
|
20
|
-
width: 100%;
|
|
21
|
-
height: 1px;
|
|
22
|
-
border: none;
|
|
23
|
-
border-bottom-color: var(--color-border);
|
|
24
|
-
border-bottom-style: solid;
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
.vui-divider-slot {
|
|
28
|
-
position: absolute;
|
|
29
|
-
top: 50%;
|
|
30
|
-
left: 50%;
|
|
31
|
-
transform: translate(-50%, -50%);
|
|
32
|
-
|
|
33
|
-
& > *:first-child {
|
|
34
|
-
outline: 3px solid var(--color-bg);
|
|
35
|
-
}
|
|
36
|
-
}
|
|
37
|
-
}
|