nuance-ui 0.2.8 → 0.2.9

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.
Files changed (96) hide show
  1. package/LICENSE.md +9 -9
  2. package/README.md +75 -75
  3. package/dist/module.json +1 -1
  4. package/dist/runtime/components/action-icon/action-icon-group.vue +3 -3
  5. package/dist/runtime/components/action-icon/action-icon.vue +23 -23
  6. package/dist/runtime/components/app-shell/app-shell-aside.vue +30 -30
  7. package/dist/runtime/components/app-shell/app-shell-footer.vue +29 -29
  8. package/dist/runtime/components/app-shell/app-shell-header.vue +30 -30
  9. package/dist/runtime/components/app-shell/app-shell-main.vue +18 -18
  10. package/dist/runtime/components/app-shell/app-shell-navbar.vue +34 -34
  11. package/dist/runtime/components/app-shell/app-shell-section.vue +10 -10
  12. package/dist/runtime/components/app-shell/app-shell.vue +34 -34
  13. package/dist/runtime/components/box.vue +3 -3
  14. package/dist/runtime/components/breadcrumbs.vue +78 -78
  15. package/dist/runtime/components/button/button.vue +40 -40
  16. package/dist/runtime/components/button/unstyled-button.vue +23 -23
  17. package/dist/runtime/components/calendar/calendar.vue +60 -60
  18. package/dist/runtime/components/calendar/ui/core/calendar-header.vue +95 -95
  19. package/dist/runtime/components/calendar/ui/core/calendar-root.vue +3 -3
  20. package/dist/runtime/components/calendar/ui/levels/calendar-decade.vue +40 -40
  21. package/dist/runtime/components/calendar/ui/levels/calendar-month.vue +77 -77
  22. package/dist/runtime/components/calendar/ui/levels/calendar-year.vue +40 -40
  23. package/dist/runtime/components/card/card-section.vue +3 -3
  24. package/dist/runtime/components/card/card.vue +3 -3
  25. package/dist/runtime/components/checkbox/checkbox-card.vue +37 -37
  26. package/dist/runtime/components/checkbox/checkbox-indicator.vue +117 -117
  27. package/dist/runtime/components/checkbox/checkbox.vue +139 -139
  28. package/dist/runtime/components/chip/chip-group.vue +2 -2
  29. package/dist/runtime/components/chip/chip.vue +200 -200
  30. package/dist/runtime/components/combobox/combobox-dropdown.vue +14 -14
  31. package/dist/runtime/components/combobox/combobox-empty.vue +3 -3
  32. package/dist/runtime/components/combobox/combobox-group.vue +21 -21
  33. package/dist/runtime/components/combobox/combobox-option-list.vue +3 -3
  34. package/dist/runtime/components/combobox/combobox-option.vue +22 -22
  35. package/dist/runtime/components/combobox/combobox-options-dropdown.vue +29 -29
  36. package/dist/runtime/components/combobox/combobox-root.vue +3 -3
  37. package/dist/runtime/components/combobox/combobox-target.vue +3 -3
  38. package/dist/runtime/components/container.vue +8 -8
  39. package/dist/runtime/components/date-time-picker.d.vue.ts +3 -3
  40. package/dist/runtime/components/date-time-picker.vue +66 -66
  41. package/dist/runtime/components/date-time-picker.vue.d.ts +3 -3
  42. package/dist/runtime/components/dialog/ui/dialog-close-button.vue +11 -11
  43. package/dist/runtime/components/dialog/ui/dialog-header.vue +5 -5
  44. package/dist/runtime/components/dialog/ui/dialog-title.vue +5 -5
  45. package/dist/runtime/components/drawer/drawer-close-button.vue +3 -3
  46. package/dist/runtime/components/drawer/drawer-header.vue +3 -3
  47. package/dist/runtime/components/drawer/drawer-root.vue +15 -15
  48. package/dist/runtime/components/drawer/drawer-title.vue +3 -3
  49. package/dist/runtime/components/files/file-upload-button.vue +12 -12
  50. package/dist/runtime/components/files/file-upload-icon.vue +1 -1
  51. package/dist/runtime/components/input/date-picker.vue +85 -85
  52. package/dist/runtime/components/input/email-input.vue +19 -19
  53. package/dist/runtime/components/input/number-input.vue +134 -134
  54. package/dist/runtime/components/input/password-input.vue +28 -28
  55. package/dist/runtime/components/input/text-input.vue +35 -35
  56. package/dist/runtime/components/input/ui/input-inline.vue +105 -105
  57. package/dist/runtime/components/input/ui/input-wrapper.vue +54 -54
  58. package/dist/runtime/components/link/link-button.vue +16 -16
  59. package/dist/runtime/components/link/link.vue +10 -10
  60. package/dist/runtime/components/loader/_loaders/bars-loader.vue +5 -5
  61. package/dist/runtime/components/loader/_loaders/dots-loader.vue +5 -5
  62. package/dist/runtime/components/loader/_loaders/oval-loader.vue +1 -1
  63. package/dist/runtime/components/modal/modal-close-button.vue +3 -3
  64. package/dist/runtime/components/modal/modal-header.vue +3 -3
  65. package/dist/runtime/components/modal/modal-root.vue +13 -13
  66. package/dist/runtime/components/modal/modal-title.vue +3 -3
  67. package/dist/runtime/components/nav-link/nav-icon-link.vue +15 -15
  68. package/dist/runtime/components/nav-link/nav-link.vue +132 -132
  69. package/dist/runtime/components/paper.vue +33 -33
  70. package/dist/runtime/components/popover/popover-dropdown.vue +69 -70
  71. package/dist/runtime/components/popover/popover-target.vue +8 -8
  72. package/dist/runtime/components/popover/popover.vue +1 -1
  73. package/dist/runtime/components/progress/progress-label.vue +3 -3
  74. package/dist/runtime/components/progress/progress-root.vue +3 -3
  75. package/dist/runtime/components/progress/progress-section.vue +8 -8
  76. package/dist/runtime/components/progress/progress.vue +9 -9
  77. package/dist/runtime/components/renderless/renderless.vue +3 -3
  78. package/dist/runtime/components/roving-focus/roving-focus-item.vue +14 -14
  79. package/dist/runtime/components/select.vue +63 -63
  80. package/dist/runtime/components/switch/switch-group.vue +16 -16
  81. package/dist/runtime/components/table/table.d.ts +30 -30
  82. package/dist/runtime/components/table/ui/table-sortable-header.vue +11 -11
  83. package/dist/runtime/components/tabs/tabs-list.vue +10 -10
  84. package/dist/runtime/components/tabs/tabs-panel.vue +11 -11
  85. package/dist/runtime/components/tabs/tabs-root.vue +8 -8
  86. package/dist/runtime/components/tabs/tabs-tab.vue +22 -22
  87. package/dist/runtime/components/text.vue +67 -67
  88. package/dist/runtime/components/textarea.vue +36 -36
  89. package/dist/runtime/components/title.vue +14 -14
  90. package/dist/runtime/components/transition.vue +3 -3
  91. package/dist/runtime/components/tree/_ui/tree-item.vue +128 -129
  92. package/dist/runtime/components/tree/_ui/tree-root.vue +21 -21
  93. package/dist/runtime/components/visually-hidden/visually-hidden-input.vue +1 -1
  94. package/dist/runtime/components/visually-hidden/visually-hidden.vue +9 -9
  95. package/dist/runtime/styles/dark-theme.css +1 -1
  96. package/package.json +1 -1
@@ -16,7 +16,7 @@ const _mod = computed(() => {
16
16
  </script>
17
17
 
18
18
  <template>
19
- <component :is v-bind='_mod'>
20
- <slot />
21
- </component>
19
+ <component :is v-bind='_mod'>
20
+ <slot />
21
+ </component>
22
22
  </template>
@@ -33,85 +33,85 @@ const breadcrumbs = computed(() => unref(items) ?? []);
33
33
  </script>
34
34
 
35
35
  <template>
36
- <Box :is :mod :style :class='$style.root' aria-label='breadcrumb'>
37
- <template v-for='(item, ix) in breadcrumbs' :key='item.to'>
38
- <li :class='$style.breadcrumb' role='presentation' aria-hidden='true'>
39
- <slot
40
- :name='item.slot ?? "item"'
41
- :item='item'
42
- :ix='ix'
43
- :active='item.active ?? ix === breadcrumbs.length - 1'
44
- >
45
- <Button
46
- :size
47
- :variant
48
- :class='$style.item'
49
- :mod='{ active: item.active ?? ix === breadcrumbs.length - 1 }'
50
- :color='item.active ?? ix === breadcrumbs.length - 1 ? color : inactive'
51
- @click.stop.prevent='$emit("click", item)'
52
- >
53
- <template v-if='item?.icon' #leftSection>
54
- <Icon :name='item.icon' :class='$style.icon' />
55
- </template>
56
- {{ item.label }}
57
- </Button>
58
- </slot>
59
- </li>
60
- <li v-if='ix < breadcrumbs.length - 1' role='presentation' aria-hidden='true' :class='$style.separator'>
61
- <slot name='separator'>
62
- <Icon :name='separator' />
63
- </slot>
64
- </li>
65
- </template>
66
- </Box>
36
+ <Box :is :mod :style :class='$style.root' aria-label='breadcrumb'>
37
+ <template v-for='(item, ix) in breadcrumbs' :key='item.to'>
38
+ <li :class='$style.breadcrumb' role='presentation' aria-hidden='true'>
39
+ <slot
40
+ :name='item.slot ?? "item"'
41
+ :item='item'
42
+ :ix='ix'
43
+ :active='item.active ?? ix === breadcrumbs.length - 1'
44
+ >
45
+ <Button
46
+ :size
47
+ :variant
48
+ :class='$style.item'
49
+ :mod='{ active: item.active ?? ix === breadcrumbs.length - 1 }'
50
+ :color='item.active ?? ix === breadcrumbs.length - 1 ? color : inactive'
51
+ @click.stop.prevent='$emit("click", item)'
52
+ >
53
+ <template v-if='item?.icon' #leftSection>
54
+ <Icon :name='item.icon' :class='$style.icon' />
55
+ </template>
56
+ {{ item.label }}
57
+ </Button>
58
+ </slot>
59
+ </li>
60
+ <li v-if='ix < breadcrumbs.length - 1' role='presentation' aria-hidden='true' :class='$style.separator'>
61
+ <slot name='separator'>
62
+ <Icon :name='separator' />
63
+ </slot>
64
+ </li>
65
+ </template>
66
+ </Box>
67
67
  </template>
68
68
 
69
69
  <style module lang="postcss">
70
- .root {
71
- --bc-spacing: var(--spacing-xs);
72
-
73
- display: flex;
74
- flex-wrap: wrap;
75
- gap: var(--bc-spacing);
76
- align-items: center;
77
- }
78
-
79
- .breadcrumb {
80
- line-height: 1;
81
-
82
- color: var(--color-text);
83
- white-space: nowrap;
84
- -webkit-tap-highlight-color: transparent;
85
-
86
- }
87
-
88
- .item {
89
- display: flex;
90
- gap: .25rem;
91
- align-items: center;
92
-
93
- font-weight: 600;
94
- text-transform: capitalize;
95
- }
96
-
97
- .icon {
98
- width: 1.2em;
99
- height: 1.2em;
100
- }
101
-
102
- .separator {
103
- display: flex;
104
- align-items: center;
105
- justify-content: center;
106
-
107
- line-height: 1;
108
-
109
- @mixin where-light {
110
- color: var(--color-gray-7);
111
- }
112
-
113
- @mixin where-dark {
114
- color: var(--color-dark-2);
115
- }
116
- }
70
+ .root {
71
+ --bc-spacing: var(--spacing-xs);
72
+
73
+ display: flex;
74
+ flex-wrap: wrap;
75
+ gap: var(--bc-spacing);
76
+ align-items: center;
77
+ }
78
+
79
+ .breadcrumb {
80
+ line-height: 1;
81
+
82
+ color: var(--color-text);
83
+ white-space: nowrap;
84
+ -webkit-tap-highlight-color: transparent;
85
+
86
+ }
87
+
88
+ .item {
89
+ display: flex;
90
+ gap: .25rem;
91
+ align-items: center;
92
+
93
+ font-weight: 600;
94
+ text-transform: capitalize;
95
+ }
96
+
97
+ .icon {
98
+ width: 1.2em;
99
+ height: 1.2em;
100
+ }
101
+
102
+ .separator {
103
+ display: flex;
104
+ align-items: center;
105
+ justify-content: center;
106
+
107
+ line-height: 1;
108
+
109
+ @mixin where-light {
110
+ color: var(--color-gray-7);
111
+ }
112
+
113
+ @mixin where-dark {
114
+ color: var(--color-dark-2);
115
+ }
116
+ }
117
117
  </style>
@@ -69,50 +69,50 @@ const style = computed(() => useStyleResolver((theme) => {
69
69
  </script>
70
70
 
71
71
  <template>
72
- <Box
73
- :is
74
- type='button'
72
+ <Box
73
+ :is
74
+ type='button'
75
75
  :mod='[
76
76
  {
77
77
  "with-left-section": !!$slots?.leftSection || !!icon,
78
78
  "with-right-section": !!$slots?.rightSection
79
79
  },
80
80
  mod
81
- ]'
82
- :style='style.root'
83
- :class='[css.root, classes?.root]'
84
- :disabled='loading'
85
- >
86
- <Transition name='fade-down'>
87
- <Loader v-show='loading' :class='css.loader' :color :size />
88
- </Transition>
89
-
90
- <span :class='[css.inner, classes?.inner]'>
91
- <span
92
- v-if='$slots.leftSection || icon'
93
- :class='[css.section, classes?.section]'
94
- data-position='left'
95
- v-bind='leftSectionProps'
96
- :style='style.leftSection'
97
- >
98
- <slot name='leftSection'>
99
- <Icon v-if='icon' :name='icon' />
100
- </slot>
101
- </span>
102
-
103
- <span :class='[css.label, classes?.label]'>
104
- <slot />
105
- </span>
106
-
107
- <span
108
- v-if='$slots.rightSection'
109
- data-position='right'
110
- :class='[css.section, classes?.section]'
111
- v-bind='rightSectionProps'
112
- :style='style.rightSection'
113
- >
114
- <slot name='rightSection' />
115
- </span>
116
- </span>
117
- </Box>
81
+ ]'
82
+ :style='style.root'
83
+ :class='[css.root, classes?.root]'
84
+ :disabled='loading'
85
+ >
86
+ <Transition name='fade-down'>
87
+ <Loader v-show='loading' :class='css.loader' :color :size />
88
+ </Transition>
89
+
90
+ <span :class='[css.inner, classes?.inner]'>
91
+ <span
92
+ v-if='$slots.leftSection || icon'
93
+ :class='[css.section, classes?.section]'
94
+ data-position='left'
95
+ v-bind='leftSectionProps'
96
+ :style='style.leftSection'
97
+ >
98
+ <slot name='leftSection'>
99
+ <Icon v-if='icon' :name='icon' />
100
+ </slot>
101
+ </span>
102
+
103
+ <span :class='[css.label, classes?.label]'>
104
+ <slot />
105
+ </span>
106
+
107
+ <span
108
+ v-if='$slots.rightSection'
109
+ data-position='right'
110
+ :class='[css.section, classes?.section]'
111
+ v-bind='rightSectionProps'
112
+ :style='style.rightSection'
113
+ >
114
+ <slot name='rightSection' />
115
+ </span>
116
+ </span>
117
+ </Box>
118
118
  </template>
@@ -9,30 +9,30 @@ const { is = "button", ...props } = defineProps({
9
9
  </script>
10
10
 
11
11
  <template>
12
- <Box :is :class='$style.unstyled' v-bind='props' type='button'>
13
- <slot />
14
- </Box>
12
+ <Box :is :class='$style.unstyled' v-bind='props' type='button'>
13
+ <slot />
14
+ </Box>
15
15
  </template>
16
16
 
17
17
  <style module lang="postcss">
18
- :where(.unstyled) {
19
- touch-action: manipulation;
20
- cursor: pointer;
21
-
22
- padding: 0;
23
- border: 0;
24
-
25
- font-size: var(--font-size-md);
26
- color: inherit;
27
- text-align: left;
28
- text-decoration: none;
29
-
30
- appearance: none;
31
- background-color: transparent;
32
- -webkit-tap-highlight-color: transparent;
33
-
34
- @mixin where-rtl {
35
- text-align: right;
36
- }
37
- }
18
+ :where(.unstyled) {
19
+ touch-action: manipulation;
20
+ cursor: pointer;
21
+
22
+ padding: 0;
23
+ border: 0;
24
+
25
+ font-size: var(--font-size-md);
26
+ color: inherit;
27
+ text-align: left;
28
+ text-decoration: none;
29
+
30
+ appearance: none;
31
+ background-color: transparent;
32
+ -webkit-tap-highlight-color: transparent;
33
+
34
+ @mixin where-rtl {
35
+ text-align: right;
36
+ }
37
+ }
38
38
  </style>
@@ -42,86 +42,86 @@ const [calendars, nav] = useCalendarNavigation({
42
42
  </script>
43
43
 
44
44
  <template>
45
- <CalendarRoot
46
- v-slot='{ config }'
47
- v-model:date='date'
48
- v-model:select='select'
49
- v-bind='props'
50
- :class='$style.content'
51
- @select='(select) => $emit("select", select)'
52
- >
53
- <section v-for='(calendar, ix) in calendars' :key='`calendar-${ix}`'>
54
- <CalendarHeader
55
- :with-prev='ix === 0'
56
- :with-next='ix === calendars.length - 1'
57
- :prev-disabled='nav.isPrevDisabled'
58
- :next-disabled='nav.isNextDisabled'
45
+ <CalendarRoot
46
+ v-slot='{ config }'
47
+ v-model:date='date'
48
+ v-model:select='select'
49
+ v-bind='props'
50
+ :class='$style.content'
51
+ @select='(select) => $emit("select", select)'
52
+ >
53
+ <section v-for='(calendar, ix) in calendars' :key='`calendar-${ix}`'>
54
+ <CalendarHeader
55
+ :with-prev='ix === 0'
56
+ :with-next='ix === calendars.length - 1'
57
+ :prev-disabled='nav.isPrevDisabled'
58
+ :next-disabled='nav.isNextDisabled'
59
59
  @prev='() => {
60
60
  nav.move(-1);
61
61
  $emit("prev");
62
- }'
62
+ }'
63
63
  @next='() => {
64
64
  nav.move(1);
65
65
  $emit("next");
66
- }'
66
+ }'
67
67
  @level='() => {
68
68
  level = nav.nextLevel();
69
69
  $emit("level");
70
- }'
71
- >
72
- <slot name='level' :config>
73
- {{ nav.getLevelLabel(calendar, config) }}
74
- </slot>
75
- </CalendarHeader>
76
-
77
- <CalendarMonth
78
- v-if='level === "month"'
79
- :month='calendar'
80
- :with-week-numbers='props.withWeekNumbers'
81
- :with-cell-spacing='props.withCellSpacing'
82
- :size
83
- >
84
- <template v-if='!!$slots.weekday' #weekday>
85
- <slot name='weekday' />
86
- </template>
87
-
88
- <slot name='day' />
89
- </CalendarMonth>
90
- <CalendarYear
91
- v-if='level === "year"'
92
- :year='calendar'
93
- :size
94
- :selectable='props.minLevel === "year"'
70
+ }'
71
+ >
72
+ <slot name='level' :config>
73
+ {{ nav.getLevelLabel(calendar, config) }}
74
+ </slot>
75
+ </CalendarHeader>
76
+
77
+ <CalendarMonth
78
+ v-if='level === "month"'
79
+ :month='calendar'
80
+ :with-week-numbers='props.withWeekNumbers'
81
+ :with-cell-spacing='props.withCellSpacing'
82
+ :size
83
+ >
84
+ <template v-if='!!$slots.weekday' #weekday>
85
+ <slot name='weekday' />
86
+ </template>
87
+
88
+ <slot name='day' />
89
+ </CalendarMonth>
90
+ <CalendarYear
91
+ v-if='level === "year"'
92
+ :year='calendar'
93
+ :size
94
+ :selectable='props.minLevel === "year"'
95
95
  @select='(month) => {
96
96
  if (props.minLevel !== "year") {
97
97
  level = nav.prevLevel();
98
98
  date = month;
99
99
  }
100
- }'
101
- />
102
- <CalendarDecade
103
- v-if='level === "decade"'
104
- :date='calendar'
105
- :size
106
- :selectable='props.minLevel === "decade"'
100
+ }'
101
+ />
102
+ <CalendarDecade
103
+ v-if='level === "decade"'
104
+ :date='calendar'
105
+ :size
106
+ :selectable='props.minLevel === "decade"'
107
107
  @select='(year) => {
108
108
  if (props.minLevel !== "decade") {
109
109
  level = nav.prevLevel();
110
110
  date = year;
111
111
  }
112
- }'
113
- />
114
- </section>
115
- </CalendarRoot>
112
+ }'
113
+ />
114
+ </section>
115
+ </CalendarRoot>
116
116
  </template>
117
117
 
118
118
  <style lang="postcss" module>
119
- .content {
120
- --calendar-cell-spacing: rem(1px);
121
-
122
- display: flex;
123
- gap: var(--spacing-sm);
124
-
125
- width: fit-content;
126
- }
119
+ .content {
120
+ --calendar-cell-spacing: rem(1px);
121
+
122
+ display: flex;
123
+ gap: var(--spacing-sm);
124
+
125
+ width: fit-content;
126
+ }
127
127
  </style>
@@ -26,102 +26,102 @@ defineEmits(["prev", "level", "next"]);
26
26
  </script>
27
27
 
28
28
  <template>
29
- <Box :is v-bind='props' :class='$style.header'>
30
- <UnstyledButton
31
- v-if='withPrev'
32
- aria-label='Previous page'
33
- :disabled='prevDisabled?.()'
34
- :class='$style.control'
35
- @click='$emit("prev")'
36
- >
37
- <Icon :name='prevIcon' :class='$style.icon' />
38
- </UnstyledButton>
39
-
40
- <UnstyledButton
41
- :disabled
42
- :class='$style.level'
43
- @click='$emit("level")'
44
- >
45
- <slot />
46
- </UnstyledButton>
47
-
48
- <UnstyledButton
49
- v-if='withNext'
50
- aria-label='Next page'
51
- :disabled='nextDisabled?.()'
52
- :class='$style.control'
53
- @click='$emit("next")'
54
- >
55
- <Icon :name='nextIcon' :class='$style.icon' />
56
- </UnstyledButton>
57
- </Box>
29
+ <Box :is v-bind='props' :class='$style.header'>
30
+ <UnstyledButton
31
+ v-if='withPrev'
32
+ aria-label='Previous page'
33
+ :disabled='prevDisabled?.()'
34
+ :class='$style.control'
35
+ @click='$emit("prev")'
36
+ >
37
+ <Icon :name='prevIcon' :class='$style.icon' />
38
+ </UnstyledButton>
39
+
40
+ <UnstyledButton
41
+ :disabled
42
+ :class='$style.level'
43
+ @click='$emit("level")'
44
+ >
45
+ <slot />
46
+ </UnstyledButton>
47
+
48
+ <UnstyledButton
49
+ v-if='withNext'
50
+ aria-label='Next page'
51
+ :disabled='nextDisabled?.()'
52
+ :class='$style.control'
53
+ @click='$emit("next")'
54
+ >
55
+ <Icon :name='nextIcon' :class='$style.icon' />
56
+ </UnstyledButton>
57
+ </Box>
58
58
  </template>
59
59
 
60
60
  <style lang="postcss" module>
61
- .header {
62
- --dch-control-size-xs: rem(30px);
63
- --dch-control-size-sm: rem(36px);
64
- --dch-control-size-md: rem(42px);
65
- --dch-control-size-lg: rem(48px);
66
- --dch-control-size-xl: rem(54px);
67
- --dch-control-size: var(--dch-control-size-sm);
68
-
69
- --dch-control-radius: var(--radius-default);
70
-
71
- display: flex;
72
- }
73
-
74
- .level,
75
- .control {
76
- cursor: pointer;
77
- user-select: none;
78
-
79
- display: flex;
80
- align-items: center;
81
- justify-content: center;
82
-
83
- height: var(--dch-control-size);
84
- border-radius: var(--dch-control-radius);
85
-
86
- opacity: 1;
87
-
88
- &:where([data-static]) {
89
- cursor: default;
90
- }
91
-
92
- &:hover {
93
- &:where(:not([data-static], :disabled)) {
94
- @mixin light {
95
- background-color: var(--color-gray-0);
96
- }
97
-
98
- @mixin dark {
99
- background-color: var(--color-dark-5);
100
- }
101
- }
102
- }
103
-
104
- &:where(:disabled) {
105
- cursor: not-allowed;
106
-
107
- opacity: 0.2;
108
- }
109
- }
110
-
111
- .level {
112
- flex: 1;
113
-
114
- font-size: var(--dch-fz, var(--font-size-sm));
115
- font-weight: 500;
116
- text-transform: capitalize;
117
- }
118
-
119
- .control {
120
- width: var(--dch-control-size);
121
- }
122
-
123
- .icon {
124
- width: 60%;
125
- height: 60%;
126
- }
61
+ .header {
62
+ --dch-control-size-xs: rem(30px);
63
+ --dch-control-size-sm: rem(36px);
64
+ --dch-control-size-md: rem(42px);
65
+ --dch-control-size-lg: rem(48px);
66
+ --dch-control-size-xl: rem(54px);
67
+ --dch-control-size: var(--dch-control-size-sm);
68
+
69
+ --dch-control-radius: var(--radius-default);
70
+
71
+ display: flex;
72
+ }
73
+
74
+ .level,
75
+ .control {
76
+ cursor: pointer;
77
+ user-select: none;
78
+
79
+ display: flex;
80
+ align-items: center;
81
+ justify-content: center;
82
+
83
+ height: var(--dch-control-size);
84
+ border-radius: var(--dch-control-radius);
85
+
86
+ opacity: 1;
87
+
88
+ &:where([data-static]) {
89
+ cursor: default;
90
+ }
91
+
92
+ &:hover {
93
+ &:where(:not([data-static], :disabled)) {
94
+ @mixin light {
95
+ background-color: var(--color-gray-0);
96
+ }
97
+
98
+ @mixin dark {
99
+ background-color: var(--color-dark-5);
100
+ }
101
+ }
102
+ }
103
+
104
+ &:where(:disabled) {
105
+ cursor: not-allowed;
106
+
107
+ opacity: 0.2;
108
+ }
109
+ }
110
+
111
+ .level {
112
+ flex: 1;
113
+
114
+ font-size: var(--dch-fz, var(--font-size-sm));
115
+ font-weight: 500;
116
+ text-transform: capitalize;
117
+ }
118
+
119
+ .control {
120
+ width: var(--dch-control-size);
121
+ }
122
+
123
+ .icon {
124
+ width: 60%;
125
+ height: 60%;
126
+ }
127
127
  </style>
@@ -73,7 +73,7 @@ useCalendarSelection({
73
73
  </script>
74
74
 
75
75
  <template>
76
- <Box>
77
- <slot :config />
78
- </Box>
76
+ <Box>
77
+ <slot :config />
78
+ </Box>
79
79
  </template>