vueless 0.0.702 → 0.0.704

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 (76) hide show
  1. package/bin/constants.js +2 -2
  2. package/constants.js +2 -2
  3. package/package.json +1 -1
  4. package/ui.button/config.ts +8 -26
  5. package/ui.button/storybook/stories.ts +0 -3
  6. package/ui.button/types.ts +0 -5
  7. package/ui.button-link/config.ts +3 -9
  8. package/ui.button-link/storybook/stories.ts +0 -3
  9. package/ui.button-link/types.ts +0 -5
  10. package/ui.button-toggle/UToggle.vue +0 -1
  11. package/ui.button-toggle/config.ts +1 -6
  12. package/ui.button-toggle/types.ts +0 -5
  13. package/ui.button-toggle-item/UToggleItem.vue +0 -2
  14. package/ui.button-toggle-item/config.ts +1 -1
  15. package/ui.container-modal/UModal.vue +0 -1
  16. package/ui.container-page/UPage.vue +0 -1
  17. package/ui.dropdown-badge/config.ts +4 -5
  18. package/ui.dropdown-badge/storybook/stories.ts +0 -1
  19. package/ui.dropdown-button/config.ts +4 -5
  20. package/ui.dropdown-button/storybook/stories.ts +0 -1
  21. package/ui.dropdown-link/UDropdownLink.vue +0 -1
  22. package/ui.dropdown-link/config.ts +3 -7
  23. package/ui.dropdown-link/storybook/stories.ts +0 -3
  24. package/ui.dropdown-link/types.ts +0 -5
  25. package/ui.dropdown-list/config.ts +7 -3
  26. package/ui.dropdown-list/storybook/stories.ts +1 -0
  27. package/ui.form-calendar/UCalendar.vue +0 -4
  28. package/ui.form-calendar/UCalendarDayView.vue +0 -13
  29. package/ui.form-calendar/UCalendarMonthView.vue +0 -12
  30. package/ui.form-calendar/UCalendarYearView.vue +0 -12
  31. package/ui.form-checkbox/config.ts +9 -6
  32. package/ui.form-color-picker/UColorPicker.vue +0 -1
  33. package/ui.form-date-picker-range/UDatePickerRange.vue +0 -3
  34. package/ui.form-date-picker-range/UDatePickerRangePeriodMenu.vue +0 -12
  35. package/ui.form-date-picker-range/config.ts +7 -20
  36. package/ui.form-input/UInput.vue +2 -8
  37. package/ui.form-input/config.ts +6 -16
  38. package/ui.form-input/storybook/stories.ts +36 -22
  39. package/ui.form-input/types.ts +1 -1
  40. package/ui.form-input-file/UInputFile.vue +1 -2
  41. package/ui.form-input-file/config.ts +4 -7
  42. package/ui.form-input-money/UInputMoney.vue +5 -4
  43. package/ui.form-input-money/storybook/stories.ts +126 -49
  44. package/ui.form-input-number/storybook/stories.ts +43 -21
  45. package/ui.form-input-rating/UInputRating.vue +1 -0
  46. package/ui.form-input-rating/config.ts +5 -0
  47. package/ui.form-input-rating/storybook/stories.ts +62 -19
  48. package/ui.form-input-rating/types.ts +12 -7
  49. package/ui.form-input-search/UInputSearch.vue +1 -1
  50. package/ui.form-input-search/config.ts +8 -11
  51. package/ui.form-input-search/storybook/stories.ts +110 -31
  52. package/ui.form-input-search/types.ts +6 -6
  53. package/ui.form-label/config.ts +3 -3
  54. package/ui.form-radio/URadio.vue +5 -2
  55. package/ui.form-radio/config.ts +12 -6
  56. package/ui.form-radio-group/URadioGroup.vue +1 -0
  57. package/ui.form-select/config.ts +4 -7
  58. package/ui.form-switch/USwitch.vue +8 -2
  59. package/ui.form-switch/config.ts +11 -8
  60. package/ui.form-switch/types.ts +0 -1
  61. package/ui.form-textarea/config.ts +8 -14
  62. package/ui.navigation-breadcrumbs/UBreadcrumbs.vue +0 -1
  63. package/ui.navigation-breadcrumbs/types.ts +1 -1
  64. package/ui.navigation-pagination/UPagination.vue +22 -10
  65. package/ui.navigation-pagination/config.ts +15 -17
  66. package/ui.navigation-tab/UTab.vue +58 -20
  67. package/ui.navigation-tab/config.ts +14 -14
  68. package/ui.navigation-tab/storybook/stories.ts +1 -1
  69. package/ui.navigation-tab/types.ts +15 -4
  70. package/ui.navigation-tabs/UTabs.vue +6 -4
  71. package/ui.navigation-tabs/config.ts +4 -15
  72. package/ui.navigation-tabs/storybook/stories.ts +0 -3
  73. package/ui.navigation-tabs/types.ts +8 -3
  74. package/ui.text-alert/UAlert.vue +0 -1
  75. package/ui.text-badge/config.ts +3 -6
  76. package/ui.text-file/UFile.vue +2 -9
package/bin/constants.js CHANGED
@@ -9,8 +9,8 @@ export default {
9
9
  brand: "grayscale",
10
10
  gray: "cool",
11
11
  darkMode: "auto",
12
- ring: 4,
13
- ringOffset: 0,
12
+ ring: 2,
13
+ ringOffset: 2,
14
14
  ringOffsetColorLight: "#ffffff", // white
15
15
  ringOffsetColorDark: "#111827", // gray-900
16
16
  rounding: 8,
package/constants.js CHANGED
@@ -17,8 +17,8 @@ export const COLOR_MODE_KEY = "vl-color-mode";
17
17
  /* Vueless defaults */
18
18
  export const DEFAULT_BRAND_COLOR = GRAYSCALE_COLOR;
19
19
  export const DEFAULT_GRAY_COLOR = COOL_COLOR;
20
- export const DEFAULT_RING = 4; /* pixels */
21
- export const DEFAULT_RING_OFFSET = 0; /* pixels */
20
+ export const DEFAULT_RING = 2; /* pixels */
21
+ export const DEFAULT_RING_OFFSET = 2; /* pixels */
22
22
  export const DEFAULT_RING_OFFSET_COLOR_LIGHT = "#ffffff"; // white
23
23
  export const DEFAULT_RING_OFFSET_COLOR_DARK = "#111827"; // gray-900
24
24
  export const DEFAULT_ROUNDING = 8; /* pixels */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vueless",
3
- "version": "0.0.702",
3
+ "version": "0.0.704",
4
4
  "license": "MIT",
5
5
  "description": "Vue Styleless UI Component Library, powered by Tailwind CSS.",
6
6
  "keywords": [
@@ -2,13 +2,10 @@ export default /*tw*/ {
2
2
  button: {
3
3
  base: `
4
4
  flex items-center justify-center font-medium !leading-snug whitespace-nowrap
5
- border border-transparent outline-none transition
6
- disabled:cursor-not-allowed cursor-pointer
7
- disabled:ring-0 disabled:ring-offset-0
8
- focus:ring-dynamic focus-within:ring-dynamic
9
- focus:ring-offset-dynamic focus-within:ring-offset-dynamic
10
- focus:ring-{color}-700/15 focus-within:ring-{color}-700/15
11
- dark:focus:ring-{color}-500/15 dark:focus-within:ring-{color}-500/15
5
+ border border-transparent outline-none transition cursor-pointer
6
+ focus-visible:ring-dynamic focus-visible:ring-offset-dynamic
7
+ focus-visible:ring-{color}-600 dark:focus-visible:ring-{color}-400
8
+ disabled:cursor-not-allowed disabled:ring-0 disabled:ring-offset-0
12
9
  `,
13
10
  variants: {
14
11
  size: {
@@ -24,21 +21,18 @@ export default /*tw*/ {
24
21
  text-white dark:text-gray-900
25
22
  bg-{color}-600 dark:bg-{color}-400
26
23
  hover:bg-{color}-700 dark:hover:bg-{color}-500
27
- focus:bg-{color}-700 dark:focus:bg-{color}-500
28
24
  active:bg-{color}-800 dark:active:bg-{color}-600
29
25
  disabled:bg-gray-400 dark:disabled:bg-gray-600
30
26
  `,
31
27
  secondary: `
32
28
  text-{color}-600 border-{color}-600 dark:text-{color}-400 dark:border-{color}-400
33
29
  hover:text-{color}-700 hover:border-{color}-700 dark:hover:text-{color}-500 dark:hover:border-{color}-500
34
- focus:text-{color}-700 focus:border-{color}-700 dark:focus:text-{color}-500 dark:focus:border-{color}-500
35
30
  active:text-{color}-800 active:border-{color}-800 dark:active:text-{color}-600 dark:active:border-{color}-600
36
31
  disabled:text-gray-400 disabled:border-gray-400 dark:disabled:text-gray-600 dark:disabled:border-gray-600
37
32
  `,
38
33
  thirdary: `
39
34
  text-{color}-600 dark:text-{color}-400
40
35
  hover:text-{color}-700 hover:bg-{color}-700/10 dark:hover:text-{color}-500 dark:hover:bg-{color}-500/10
41
- focus:text-{color}-700 focus:bg-{color}-700/10 dark:focus:text-{color}-500 dark:focus:bg-{color}-500/10
42
36
  active:text-{color}-800 active:bg-{color}-800/15 dark:active:text-{color}-600 dark:active:bg-{color}-600/15
43
37
  disabled:text-gray-400 disabled:bg-transparent dark:disabled:text-gray-600 dark:disabled:bg-transparent
44
38
  `,
@@ -47,9 +41,6 @@ export default /*tw*/ {
47
41
  false: "rounded-dynamic",
48
42
  true: "rounded-full",
49
43
  },
50
- ring: {
51
- false: "!ring-0 !ring-offset-0",
52
- },
53
44
  loading: {
54
45
  true: "gap-0 pointer-events-none",
55
46
  },
@@ -63,10 +54,7 @@ export default /*tw*/ {
63
54
  compoundVariants: [
64
55
  {
65
56
  color: ["grayscale", "white"],
66
- class: `
67
- focus:ring-gray-700/15 dark:focus:ring-gray-500/15
68
- focus-within:ring-gray-700/15 dark:focus-within:ring-gray-500/15
69
- `,
57
+ class: "focus-visible:ring-gray-900 dark:focus-visible:ring-gray-100",
70
58
  },
71
59
  {
72
60
  color: "grayscale",
@@ -74,7 +62,6 @@ export default /*tw*/ {
74
62
  class: `
75
63
  bg-gray-900 dark:bg-gray-100
76
64
  hover:bg-gray-800 dark:hover:bg-gray-200
77
- focus:bg-gray-800 dark:focus:bg-gray-200
78
65
  active:bg-gray-700 dark:active:bg-gray-300
79
66
  `,
80
67
  },
@@ -84,8 +71,7 @@ export default /*tw*/ {
84
71
  class: `
85
72
  text-gray-900 border-gray-900 dark:text-gray-100 dark:border-gray-100
86
73
  hover:text-gray-800 hover:border-gray-800 dark:hover:text-gray-200 dark:hover:border-gray-200
87
- focus:text-gray-800 focus:border-gray-800 dark:focus:text-gray-200 dark:focus:border-gray-200
88
- active:text-gray-700 active:border-gray-700 dark:active:focus-gray-300 dark:active:border-gray-300
74
+ active:text-gray-700 active:border-gray-700 dark:active:text-gray-300 dark:active:border-gray-300
89
75
  `,
90
76
  },
91
77
  {
@@ -94,7 +80,6 @@ export default /*tw*/ {
94
80
  class: `
95
81
  text-gray-900 dark:text-gray-100
96
82
  hover:text-gray-800 hover:bg-gray-800/5 dark:hover:text-gray-200 dark:hover:bg-gray-200/5
97
- focus:text-gray-800 focus:bg-gray-800/5 dark:focus:text-gray-200 dark:focus:bg-gray-200/5
98
83
  active:text-gray-700 active:bg-gray-700/10 dark:active:text-gray-300 dark:active:bg-gray-300/10
99
84
  `,
100
85
  },
@@ -103,7 +88,6 @@ export default /*tw*/ {
103
88
  class: `
104
89
  text-gray-900 dark:text-white
105
90
  hover:text-gray-800 dark:hover:text-gray-100
106
- focus:text-gray-800 dark:focus:text-gray-100
107
91
  active:text-gray-700 dark:active:text-gray-200
108
92
  `,
109
93
  },
@@ -113,19 +97,18 @@ export default /*tw*/ {
113
97
  class: `
114
98
  bg-white dark:text-gray-900
115
99
  hover:bg-gray-50 dark:hover:text-gray-800
116
- focus:bg-gray-50 dark:focus:text-gray-800
117
100
  active:bg-gray-100 dark:active:text-gray-700
118
101
  `,
119
102
  },
120
103
  {
121
104
  color: "white",
122
105
  variant: "secondary",
123
- class: "border-gray-100 hover:border-gray-200 focus:border-gray-200 active:border-gray-300",
106
+ class: "border-gray-100 hover:border-gray-200 active:border-gray-300",
124
107
  },
125
108
  {
126
109
  color: "white",
127
110
  variant: "thirdary",
128
- class: "hover:bg-white/10 focus:bg-white/10 active:bg-white/15",
111
+ class: "hover:bg-white/10 active:bg-white/15",
129
112
  },
130
113
  { filled: true, variant: "thirdary", class: "bg-{color}-700/10 dark:bg-{color}-500/10" },
131
114
  { filled: true, variant: "thirdary", color: ["grayscale", "white"], class: "bg-gray-800/5 dark:bg-gray-200/5" },
@@ -187,7 +170,6 @@ export default /*tw*/ {
187
170
  block: false,
188
171
  square: false,
189
172
  filled: false,
190
- ring: true,
191
173
  loading: false,
192
174
  disabled: false,
193
175
  },
@@ -155,9 +155,6 @@ Block.args = { block: true };
155
155
  export const Disabled = EnumVariantTemplate.bind({});
156
156
  Disabled.args = { enum: "variant", disabled: true };
157
157
 
158
- export const NoRing = DefaultTemplate.bind({});
159
- NoRing.args = { ring: false };
160
-
161
158
  export const Colors = ColorTemplate.bind({});
162
159
  Colors.args = {};
163
160
 
@@ -100,11 +100,6 @@ export interface Props {
100
100
  */
101
101
  loading?: boolean;
102
102
 
103
- /**
104
- * Show button ring on focus.
105
- */
106
- ring?: boolean;
107
-
108
103
  /**
109
104
  * Unique element id.
110
105
  */
@@ -4,9 +4,8 @@ export default /*tw*/ {
4
4
  inline-block cursor-pointer !leading-none rounded transition
5
5
  text-{color}-600 decoration-{color}-600 underline-offset-4
6
6
  hover:text-{color}-700 hover:decoration-{color}-700
7
- focus:text-{color}-700 focus:decoration-{color}-700 focus:outline-0
8
7
  active:text-{color}-800 active:decoration-{color}-800
9
- focus:ring-dynamic focus:ring-offset-4 focus:ring-{color}-700/15
8
+ focus-visible:ring-dynamic focus-visible:ring-offset-4 focus-visible:ring-{color}-600 focus-visible:outline-0
10
9
  `,
11
10
  variants: {
12
11
  size: {
@@ -23,16 +22,15 @@ export default /*tw*/ {
23
22
  gray: `
24
23
  text-gray-500 decoration-gray-500
25
24
  hover:text-gray-600 hover:decoration-gray-600
26
- focus:text-gray-600 focus:decoration-gray-600
27
25
  active:text-gray-700 active:decoration-gray-700
28
26
  `,
29
27
  grayscale: `
30
28
  text-gray-900 decoration-gray-900
31
29
  hover:text-gray-800 hover:decoration-gray-800
32
- focus:text-gray-800 focus:decoration-gray-800 focus:ring-gray-700/15
33
30
  active:text-gray-700 active:decoration-gray-700
31
+ focus-visible:ring-gray-900
34
32
  `,
35
- white: "decoration-white text-white focus:ring-white/15",
33
+ white: "decoration-white text-white focus-visible:ring-white",
36
34
  },
37
35
  defaultSlot: {
38
36
  true: "flex items-center no-underline hover:no-underline",
@@ -43,9 +41,6 @@ export default /*tw*/ {
43
41
  disabled: {
44
42
  true: "text-gray-400 pointer-events-none",
45
43
  },
46
- ring: {
47
- false: "!ring-0 !ring-offset-0",
48
- },
49
44
  block: {
50
45
  true: "w-full",
51
46
  },
@@ -61,7 +56,6 @@ export default /*tw*/ {
61
56
  ariaCurrentValue: "page",
62
57
  rel: "noopener noreferrer",
63
58
  underlined: undefined,
64
- ring: false,
65
59
  block: false,
66
60
  dashed: false,
67
61
  custom: false,
@@ -185,9 +185,6 @@ export const UnderlineVariants: StoryFn<ULinkArgs> = (args: ULinkArgs, { argType
185
185
  export const Disabled = DefaultTemplate.bind({});
186
186
  Disabled.args = { disabled: true };
187
187
 
188
- export const NoRing = DefaultTemplate.bind({});
189
- NoRing.args = { ring: false };
190
-
191
188
  export const Block = DefaultTemplate.bind({});
192
189
  Block.args = { block: true };
193
190
 
@@ -107,11 +107,6 @@ export interface Props {
107
107
  */
108
108
  block?: boolean;
109
109
 
110
- /**
111
- * Show link ring on focus.
112
- */
113
- ring?: boolean;
114
-
115
110
  /**
116
111
  * Whether RouterLink should not wrap its content in a tag.
117
112
  */
@@ -61,7 +61,6 @@ provide("getToggleRound", () => props.round);
61
61
  provide("getToggleBlock", () => props.block);
62
62
  provide("getToggleSquare", () => props.square);
63
63
  provide("getToggleDisabled", () => props.disabled);
64
- provide("getToggleRing", () => props.ring);
65
64
  provide("getToggleSplit", () => props.split);
66
65
 
67
66
  provide("toggleSelectedValue", {
@@ -30,12 +30,7 @@ export default /*tw*/ {
30
30
  },
31
31
  split: {
32
32
  true: "flex flex-wrap",
33
- false: `
34
- p-1 gap-1 flex flex-nowrap w-fit transition
35
- border border-gray-300 rounded-dynamic
36
- hover:border-gray-400 hover:focus-within:border-brand-500 focus-within:border-brand-500
37
- focus-within:ring-dynamic focus-within:ring-offset-dynamic focus-within:ring-brand-700/15
38
- `,
33
+ false: "p-1 gap-1 flex flex-nowrap w-fit transition border rounded-dynamic border-gray-300",
39
34
  },
40
35
  disabled: {
41
36
  true: "pointer-events-none",
@@ -81,11 +81,6 @@ export interface Props {
81
81
  */
82
82
  square?: boolean;
83
83
 
84
- /**
85
- * Show button ring on focus.
86
- */
87
- ring?: boolean;
88
-
89
84
  /**
90
85
  * Component config object.
91
86
  */
@@ -37,7 +37,6 @@ const getToggleSize = inject<() => ButtonSize>("getToggleSize", () => "md" as Bu
37
37
  const getToggleRound = inject<() => boolean>("getToggleRound", () => false);
38
38
  const getToggleBlock = inject<() => boolean>("getToggleBlock", () => false);
39
39
  const getToggleSquare = inject<() => boolean>("getToggleSquare", () => false);
40
- const getToggleRing = inject<() => boolean>("getToggleRing", () => false);
41
40
  const getToggleSplit = inject<() => boolean>("getToggleSplit", () => true);
42
41
 
43
42
  const getToggleDisabled = inject<() => boolean>(
@@ -109,7 +108,6 @@ const { toggleButtonInactiveAttrs, toggleButtonActiveAttrs, toggleInputAttrs } =
109
108
  :block="getToggleBlock()"
110
109
  :square="getToggleSquare()"
111
110
  :disabled="getToggleDisabled() || disabled"
112
- :ring="getToggleRing() || getToggleSplit()"
113
111
  v-bind="isSelected ? toggleButtonActiveAttrs : toggleButtonInactiveAttrs"
114
112
  @click="onClickSetValue"
115
113
  >
@@ -1,6 +1,6 @@
1
1
  export default /*tw*/ {
2
2
  toggleButton: {
3
- base: "{UButton} font-normal",
3
+ base: "{UButton} font-normal focus-visible:ring-offset-0",
4
4
  defaults: {
5
5
  variant: "thirdary",
6
6
  },
@@ -171,7 +171,6 @@ const {
171
171
  size="sm"
172
172
  color="gray"
173
173
  :to="backTo"
174
- :ring="false"
175
174
  :label="backLabel"
176
175
  v-bind="backLinkAttrs"
177
176
  @click="onClickBackLink"
@@ -117,7 +117,6 @@ const {
117
117
  />
118
118
 
119
119
  <ULink
120
- :ring="false"
121
120
  size="sm"
122
121
  color="gray"
123
122
  :to="backTo"
@@ -1,13 +1,12 @@
1
1
  export default /*tw*/ {
2
2
  wrapper: "relative inline-block",
3
3
  dropdownBadge: {
4
- base: "{UBadge} transition",
4
+ base: "{UBadge}",
5
5
  variants: {
6
6
  opened: {
7
- true: "group ring-dynamic ring-offset-dynamic ring-{color}-700/15",
7
+ true: "group",
8
8
  },
9
9
  },
10
- compoundVariants: [{ opened: true, color: ["grayscale", "white"], class: "ring-gray-700/15" }],
11
10
  },
12
11
  dropdownIcon: {
13
12
  base: "{UIcon} transition duration-300 group-[]:rotate-180",
@@ -23,8 +22,8 @@ export default /*tw*/ {
23
22
  base: "{UDropdownList} w-fit",
24
23
  variants: {
25
24
  yPosition: {
26
- top: "bottom-6 mb-6",
27
- bottom: "top-3 mt-6",
25
+ top: "bottom-5 mb-5",
26
+ bottom: "top-3 mt-5",
28
27
  },
29
28
  xPosition: {
30
29
  left: "left-0",
@@ -181,7 +181,6 @@ SlotToggle.args = {
181
181
  :label="opened ? 'collapse' : 'expand'"
182
182
  color="green"
183
183
  size="sm"
184
- :ring=false
185
184
  class="mx-1"
186
185
  />
187
186
  </template>
@@ -1,13 +1,12 @@
1
1
  export default /*tw*/ {
2
2
  wrapper: "relative inline-block",
3
3
  dropdownButton: {
4
- base: "{UButton} transition",
4
+ base: "{UButton}",
5
5
  variants: {
6
6
  opened: {
7
- true: "group ring-dynamic ring-offset-dynamic ring-{color}-700/15",
7
+ true: "group",
8
8
  },
9
9
  },
10
- compoundVariants: [{ opened: true, color: ["grayscale", "white"], class: "ring-gray-700/15" }],
11
10
  },
12
11
  dropdownIcon: {
13
12
  base: "{UIcon} transition duration-300 group-[]:rotate-180",
@@ -26,8 +25,8 @@ export default /*tw*/ {
26
25
  base: "{UDropdownList} w-fit",
27
26
  variants: {
28
27
  yPosition: {
29
- top: "bottom-full mb-2",
30
- bottom: "top-full mt-2",
28
+ top: "bottom-full mb-1",
29
+ bottom: "top-full mt-1",
31
30
  },
32
31
  xPosition: {
33
32
  left: "left-0",
@@ -175,7 +175,6 @@ SlotToggle.args = {
175
175
  <ULink
176
176
  :label="opened ? 'collapse' : 'expand'"
177
177
  color="green"
178
- :ring=false
179
178
  />
180
179
  </template>
181
180
  `,
@@ -82,7 +82,6 @@ const { config, getDataTest, wrapperAttrs, dropdownLinkAttrs, dropdownListAttrs,
82
82
 
83
83
  <ULink
84
84
  :id="elementId"
85
- :ring="ring"
86
85
  :size="size"
87
86
  :label="label"
88
87
  :color="color"
@@ -5,12 +5,9 @@ export default /*tw*/ {
5
5
  opened: {
6
6
  true: "group",
7
7
  },
8
- ring: {
9
- true: "focus-within:ring-dynamic focus-within:ring-offset-4 focus-within:ring-{color}-700/15",
10
- },
11
8
  },
12
9
  },
13
- dropdownLink: "{ULink} focus:ring-0 focus:ring-offset-0",
10
+ dropdownLink: "{ULink}",
14
11
  toggleIcon: {
15
12
  base: "{UIcon} block transition duration-300 group-[]:rotate-180",
16
13
  variants: {
@@ -30,8 +27,8 @@ export default /*tw*/ {
30
27
  base: "{UDropdownList} w-fit",
31
28
  variants: {
32
29
  yPosition: {
33
- top: "bottom-6 mb-4",
34
- bottom: "top-3 mt-4",
30
+ top: "bottom-3 mb-3",
31
+ bottom: "top-3 mt-3",
35
32
  },
36
33
  xPosition: {
37
34
  left: "left-0",
@@ -47,7 +44,6 @@ export default /*tw*/ {
47
44
  xPosition: "left",
48
45
  underlined: undefined,
49
46
  dashed: true,
50
- ring: false,
51
47
  noIcon: false,
52
48
  disabled: false,
53
49
  /* icons */
@@ -107,9 +107,6 @@ DropdownListYPosition.args = { enum: "yPosition" };
107
107
  export const Disabled = DefaultTemplate.bind({});
108
108
  Disabled.args = { disabled: true };
109
109
 
110
- export const Ring = DefaultTemplate.bind({});
111
- Ring.args = { ring: true };
112
-
113
110
  export const Colors = EnumVariantTemplate.bind({});
114
111
  Colors.args = { enum: "color" };
115
112
 
@@ -67,11 +67,6 @@ export interface Props {
67
67
  */
68
68
  disabled?: boolean;
69
69
 
70
- /**
71
- * Show link focus ring.
72
- */
73
- ring?: boolean;
74
-
75
70
  /**
76
71
  * Hide dropdown icon.
77
72
  */
@@ -6,15 +6,19 @@ export default /*tw*/ {
6
6
  focus:outline-none
7
7
  `,
8
8
  list: "list-none align-top w-full h-full",
9
- listItem: "group/item block",
9
+ listItem: "group/item block mb-px last:mb-0",
10
10
  option: {
11
11
  base: `
12
12
  rounded-dynamic-sm px-2 py-2.5 flex items-center align-middle whitespace-nowrap cursor-pointer
13
13
  font-normal !leading-none text-gray-900
14
- hover:bg-{color}-50 active:bg-{color}-100
14
+ hover:bg-{color}-600/5 active:bg-{color}-600/10
15
15
  overflow-hidden text-ellipsis
16
16
  `,
17
17
  variants: {
18
+ color: {
19
+ grayscale: "hover:bg-gray-100 active:bg-gray-200",
20
+ white: "hover:bg-gray-100 active:bg-gray-200",
21
+ },
18
22
  size: {
19
23
  sm: "text-xs",
20
24
  md: "text-sm",
@@ -25,7 +29,7 @@ export default /*tw*/ {
25
29
  },
26
30
  },
27
31
  },
28
- optionActive: "{>option} font-semibold bg-{color}-100 hover:bg-{color}-100 text-brand-600",
32
+ optionActive: "{>option} font-semibold bg-{color}-600/10 hover:bg-{color}-600/10 text-brand-600",
29
33
  optionHighlighted: "bg-{color}-50",
30
34
  optionContent: "overflow-visible text-ellipsis",
31
35
  groupBase: {
@@ -57,6 +57,7 @@ const DefaultTemplate: StoryFn<DefaultUDropdownListArgs> = (args: DefaultUDropdo
57
57
  template: `
58
58
  <UDropdownList
59
59
  v-bind="args"
60
+ v-model="args.modelValue"
60
61
  class="mx-4 w-[24rem]"
61
62
  @add="showAlert('You triggered the add action!')"
62
63
  >
@@ -724,7 +724,6 @@ const {
724
724
  <UButton
725
725
  square
726
726
  size="sm"
727
- :ring="false"
728
727
  color="grayscale"
729
728
  variant="thirdary"
730
729
  :left-icon="config.defaults.prevIcon"
@@ -735,7 +734,6 @@ const {
735
734
 
736
735
  <UButton
737
736
  size="sm"
738
- :ring="false"
739
737
  color="grayscale"
740
738
  variant="thirdary"
741
739
  v-bind="viewSwitchButtonAttrs"
@@ -752,7 +750,6 @@ const {
752
750
  <UButton
753
751
  square
754
752
  size="sm"
755
- :ring="false"
756
753
  color="grayscale"
757
754
  variant="thirdary"
758
755
  :left-icon="config.defaults.nextIcon"
@@ -849,7 +846,6 @@ const {
849
846
  ref="ok-button"
850
847
  filled
851
848
  size="sm"
852
- :ring="false"
853
849
  color="grayscale"
854
850
  variant="thirdary"
855
851
  v-bind="timepickerSubmitButtonAttrs"
@@ -229,7 +229,6 @@ const {
229
229
  variant="primary"
230
230
  color="brand"
231
231
  size="md"
232
- :ring="false"
233
232
  square
234
233
  v-bind="selectedDayAttrs"
235
234
  :disabled="dateIsOutOfRange(day, minDate, maxDate, locale, dateFormat)"
@@ -244,7 +243,6 @@ const {
244
243
  variant="thirdary"
245
244
  color="brand"
246
245
  size="md"
247
- :ring="false"
248
246
  square
249
247
  v-bind="currentDayAttrs"
250
248
  :disabled="dateIsOutOfRange(day, minDate, maxDate, locale, dateFormat)"
@@ -259,7 +257,6 @@ const {
259
257
  variant="thirdary"
260
258
  color="brand"
261
259
  size="md"
262
- :ring="false"
263
260
  square
264
261
  filled
265
262
  v-bind="currentFirstDayInRangeAttrs"
@@ -275,7 +272,6 @@ const {
275
272
  variant="thirdary"
276
273
  color="brand"
277
274
  size="md"
278
- :ring="false"
279
275
  square
280
276
  filled
281
277
  v-bind="currentLastDayInRangeAttrs"
@@ -291,7 +287,6 @@ const {
291
287
  variant="primary"
292
288
  color="brand"
293
289
  size="md"
294
- :ring="false"
295
290
  square
296
291
  filled
297
292
  v-bind="firstDayInRangeAttrs"
@@ -307,7 +302,6 @@ const {
307
302
  variant="primary"
308
303
  color="brand"
309
304
  size="md"
310
- :ring="false"
311
305
  square
312
306
  filled
313
307
  v-bind="lastDayInRangeAttrs"
@@ -323,7 +317,6 @@ const {
323
317
  variant="thirdary"
324
318
  color="brand"
325
319
  size="md"
326
- :ring="false"
327
320
  square
328
321
  filled
329
322
  v-bind="anotherMonthFirstDayInRangeAttrs"
@@ -339,7 +332,6 @@ const {
339
332
  variant="thirdary"
340
333
  color="brand"
341
334
  size="md"
342
- :ring="false"
343
335
  square
344
336
  filled
345
337
  v-bind="anotherMonthLastDayInRangeAttrs"
@@ -355,7 +347,6 @@ const {
355
347
  variant="thirdary"
356
348
  color="brand"
357
349
  size="md"
358
- :ring="false"
359
350
  square
360
351
  v-bind="currentDayInRangeAttrs"
361
352
  :disabled="dateIsOutOfRange(day, minDate, maxDate, locale, dateFormat)"
@@ -370,7 +361,6 @@ const {
370
361
  variant="thirdary"
371
362
  color="brand"
372
363
  size="md"
373
- :ring="false"
374
364
  square
375
365
  v-bind="dayInRangeAttrs"
376
366
  :disabled="dateIsOutOfRange(day, minDate, maxDate, locale, dateFormat)"
@@ -385,7 +375,6 @@ const {
385
375
  variant="thirdary"
386
376
  color="brand"
387
377
  size="md"
388
- :ring="false"
389
378
  square
390
379
  v-bind="activeDayAttrs"
391
380
  :disabled="dateIsOutOfRange(day, minDate, maxDate, locale, dateFormat)"
@@ -400,7 +389,6 @@ const {
400
389
  variant="thirdary"
401
390
  color="grayscale"
402
391
  size="md"
403
- :ring="false"
404
392
  square
405
393
  v-bind="anotherMonthDayAttrs"
406
394
  :disabled="dateIsOutOfRange(day, minDate, maxDate, locale, dateFormat)"
@@ -415,7 +403,6 @@ const {
415
403
  variant="thirdary"
416
404
  color="grayscale"
417
405
  size="md"
418
- :ring="false"
419
406
  square
420
407
  v-bind="dayAttrs"
421
408
  :disabled="dateIsOutOfRange(day, minDate, maxDate, locale, dateFormat)"