vueless 0.0.703 → 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 (63) 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/config.ts +6 -16
  37. package/ui.form-input-file/UInputFile.vue +1 -2
  38. package/ui.form-input-file/config.ts +4 -7
  39. package/ui.form-input-search/UInputSearch.vue +0 -1
  40. package/ui.form-label/config.ts +3 -3
  41. package/ui.form-radio/URadio.vue +5 -2
  42. package/ui.form-radio/config.ts +12 -6
  43. package/ui.form-radio-group/URadioGroup.vue +1 -0
  44. package/ui.form-select/config.ts +4 -7
  45. package/ui.form-switch/USwitch.vue +8 -2
  46. package/ui.form-switch/config.ts +11 -8
  47. package/ui.form-switch/types.ts +0 -1
  48. package/ui.form-textarea/config.ts +8 -14
  49. package/ui.navigation-breadcrumbs/UBreadcrumbs.vue +0 -1
  50. package/ui.navigation-breadcrumbs/types.ts +1 -1
  51. package/ui.navigation-pagination/UPagination.vue +22 -10
  52. package/ui.navigation-pagination/config.ts +15 -17
  53. package/ui.navigation-tab/UTab.vue +58 -20
  54. package/ui.navigation-tab/config.ts +14 -14
  55. package/ui.navigation-tab/storybook/stories.ts +1 -1
  56. package/ui.navigation-tab/types.ts +15 -4
  57. package/ui.navigation-tabs/UTabs.vue +6 -4
  58. package/ui.navigation-tabs/config.ts +4 -15
  59. package/ui.navigation-tabs/storybook/stories.ts +0 -3
  60. package/ui.navigation-tabs/types.ts +8 -3
  61. package/ui.text-alert/UAlert.vue +0 -1
  62. package/ui.text-badge/config.ts +3 -6
  63. package/ui.text-file/UFile.vue +2 -9
@@ -2,32 +2,35 @@ export default /*tw*/ {
2
2
  switchLabel: "{ULabel}",
3
3
  wrapper: {
4
4
  base: `
5
- flex items-center p-0.5 relative rounded-3xl cursor-pointer transition
6
- focus-within:ring-dynamic focus-within:ring-offset-dynamic
5
+ flex items-center p-0.5 relative rounded-full cursor-pointer transition
6
+ focus-visible:ring-dynamic focus-visible:ring-offset-dynamic ring-{color}-600 outline-0
7
7
  `,
8
8
  variants: {
9
- checked: {
10
- true: "bg-{color}-600 ring-{color}-700/15 hover:bg-{color}-700 active:bg-{color}-800",
11
- false: "bg-gray-300 ring-gray-700/15 hover:bg-gray-400 active:bg-gray-500",
12
- },
13
9
  size: {
14
10
  sm: "w-6",
15
11
  md: "w-8",
16
12
  lg: "w-10",
17
13
  },
14
+ color: {
15
+ grayscale: "ring-gray-900",
16
+ },
17
+ checked: {
18
+ true: "bg-{color}-600 hover:bg-{color}-700 active:bg-{color}-800",
19
+ false: "bg-gray-300 hover:bg-gray-400 active:bg-gray-600",
20
+ },
18
21
  },
19
22
  compoundVariants: [
20
23
  { toggleLabel: true, size: "sm", class: "w-10" },
21
24
  { toggleLabel: true, size: "md", class: "w-12" },
22
25
  { toggleLabel: true, size: "lg", class: "w-14" },
26
+ { color: "grayscale", checked: true, class: "bg-gray-900 hover:bg-gray-800 active:bg-gray-700" },
23
27
  { disabled: true, checked: false, class: "bg-gray-300" },
24
28
  { disabled: true, checked: true, class: "bg-gray-400" },
25
- { color: "grayscale", disabled: false, checked: true, class: "bg-gray-900 ring-gray-700/15" },
26
29
  ],
27
30
  },
28
31
  input: "absolute size-0 opacity-0",
29
32
  circle: {
30
- base: "transition-all duration-300 rounded-full bg-white flex items-center justify-center",
33
+ base: "rounded-full bg-white flex items-center justify-center transition-all",
31
34
  variants: {
32
35
  size: {
33
36
  sm: "size-3",
@@ -53,7 +53,6 @@ export interface Props {
53
53
  | "pink"
54
54
  | "rose"
55
55
  | "gray"
56
- | "white"
57
56
  | "brand";
58
57
 
59
58
  /**
@@ -1,27 +1,21 @@
1
1
  export default /*tw*/ {
2
2
  textareaLabel: "{ULabel}",
3
- leftSlot: "flex items-center justify-center whitespace-nowrap pl-3 gap-1 rounded-dynamic rounded-r-none",
4
- rightSlot: "flex items-center justify-center whitespace-nowrap pr-3 gap-1 rounded-dynamic rounded-l-none",
3
+ slot: "flex items-center justify-center whitespace-nowrap gap-1 rounded-dynamic",
4
+ leftSlot: "{>slot} pl-3 rounded-r-none",
5
+ rightSlot: "{>slot} pr-3 rounded-l-none",
5
6
  wrapper: {
6
7
  base: `
7
8
  flex bg-white transition w-full
8
- rounded-dynamic border border-gray-300 hover:border-gray-400 hover:focus-within:border-brand-500
9
- focus-within:border-brand-500 focus-within:ring-dynamic focus-within:ring-offset-dynamic
10
- focus-within:ring-brand-700/15 focus-within:outline-none
9
+ rounded-dynamic border border-gray-300 hover:border-gray-400 hover:focus-within:border-brand-600
10
+ focus-within:border-brand-600 focus-within:ring-dynamic focus-within:ring-offset-0
11
+ focus-within:ring-brand-600 focus-within:outline-none
11
12
  `,
12
13
  variants: {
13
14
  error: {
14
- true: `
15
- bg-red-50 border-red-300
16
- hover:border-red-400 hover:focus-within:border-red-500
17
- focus-within:border-red-500 focus-within:ring-red-700/15
18
- `,
15
+ true: "!border-red-600 focus-within:ring-red-600",
19
16
  },
20
17
  disabled: {
21
- true: `
22
- focus-within:ring-0 focus-within:ring-offset-0 bg-gray-100
23
- hover:border-gray-300 focus-within:border-gray-300 hover:focus-within:border-gray-300
24
- `,
18
+ true: "!border-gray-300 focus-within:ring-0 bg-gray-100",
25
19
  },
26
20
  },
27
21
  },
@@ -76,7 +76,6 @@ const { config, breadcrumbsAttrs, breadcrumbLinkAttrs, breadcrumbIconAttrs, divi
76
76
  :underlined="underlined"
77
77
  :dashed="dashed"
78
78
  :disabled="link.disabled || (!link.to && !link.href)"
79
- :ring="false"
80
79
  v-bind="breadcrumbLinkAttrs"
81
80
  :data-test="dataTest"
82
81
  @click="onClickLink(link)"
@@ -56,7 +56,7 @@ export interface Props {
56
56
  underlined?: boolean;
57
57
 
58
58
  /**
59
- * Set breadcrumbs' underline style as dashed.
59
+ * Set links underline style as dashed.
60
60
  */
61
61
  dashed?: boolean;
62
62
 
@@ -124,7 +124,6 @@ const {
124
124
  <div v-bind="paginationAttrs">
125
125
  <UButton
126
126
  v-if="showFirst"
127
- :ring="false"
128
127
  variant="thirdary"
129
128
  :label="firstLabel"
130
129
  :square="!firstLabel"
@@ -138,6 +137,7 @@ const {
138
137
  <UIcon
139
138
  v-if="!firstLabel"
140
139
  internal
140
+ color="brand"
141
141
  :name="config.defaults.firstIcon"
142
142
  v-bind="firstIconAttrs"
143
143
  />
@@ -145,7 +145,6 @@ const {
145
145
  </UButton>
146
146
 
147
147
  <UButton
148
- :ring="false"
149
148
  variant="thirdary"
150
149
  :label="prevLabel"
151
150
  :square="!prevLabel"
@@ -156,7 +155,13 @@ const {
156
155
  >
157
156
  <!-- @slot Use it to add something instead of the "prev" label. -->
158
157
  <slot name="prev">
159
- <UIcon v-if="!prevLabel" internal :name="config.defaults.prevIcon" v-bind="prevIconAttrs" />
158
+ <UIcon
159
+ v-if="!prevLabel"
160
+ internal
161
+ color="brand"
162
+ :name="config.defaults.prevIcon"
163
+ v-bind="prevIconAttrs"
164
+ />
160
165
  </slot>
161
166
  </UButton>
162
167
 
@@ -165,7 +170,6 @@ const {
165
170
  v-if="!isFinite(page.number)"
166
171
  square
167
172
  disabled
168
- :ring="false"
169
173
  variant="thirdary"
170
174
  v-bind="inactiveButtonAttrs"
171
175
  >
@@ -176,7 +180,6 @@ const {
176
180
  <UButton
177
181
  v-else-if="page.isActive"
178
182
  filled
179
- :ring="false"
180
183
  :variant="variant"
181
184
  :label="String(page.number)"
182
185
  :disabled="disabled"
@@ -186,7 +189,6 @@ const {
186
189
 
187
190
  <UButton
188
191
  v-else
189
- :ring="false"
190
192
  variant="thirdary"
191
193
  :label="String(page.number)"
192
194
  :disabled="disabled"
@@ -197,7 +199,6 @@ const {
197
199
  </template>
198
200
 
199
201
  <UButton
200
- :ring="false"
201
202
  variant="thirdary"
202
203
  :label="nextLabel"
203
204
  :square="!nextLabel"
@@ -208,13 +209,18 @@ const {
208
209
  >
209
210
  <!-- @slot Use it to add something instead of the "next" label. -->
210
211
  <slot name="next">
211
- <UIcon v-if="!nextLabel" internal :name="config.defaults.nextIcon" v-bind="nextIconAttrs" />
212
+ <UIcon
213
+ v-if="!nextLabel"
214
+ internal
215
+ color="brand"
216
+ :name="config.defaults.nextIcon"
217
+ v-bind="nextIconAttrs"
218
+ />
212
219
  </slot>
213
220
  </UButton>
214
221
 
215
222
  <UButton
216
223
  v-if="showLast"
217
- :ring="false"
218
224
  variant="thirdary"
219
225
  :label="lastLabel"
220
226
  :square="!lastLabel"
@@ -225,7 +231,13 @@ const {
225
231
  >
226
232
  <!-- @slot Use it to add something instead of the "last" label. -->
227
233
  <slot name="last">
228
- <UIcon v-if="!lastLabel" internal :name="config.defaults.lastIcon" v-bind="lastIconAttrs" />
234
+ <UIcon
235
+ v-if="!lastLabel"
236
+ internal
237
+ color="brand"
238
+ :name="config.defaults.lastIcon"
239
+ v-bind="lastIconAttrs"
240
+ />
229
241
  </slot>
230
242
  </UButton>
231
243
  </div>
@@ -1,26 +1,24 @@
1
1
  export default /*tw*/ {
2
2
  pagination: "flex",
3
3
  paginationButton: {
4
- base: "font-normal",
4
+ base: "{UButton} font-normal",
5
5
  variants: {
6
6
  size: {
7
- lg: "!text-base",
7
+ sm: "text-xs",
8
+ md: "text-sm",
9
+ lg: "text-base",
8
10
  },
9
11
  },
10
12
  defaults: {
11
- size: {
12
- sm: "xs",
13
- md: "sm",
14
- lg: "md",
15
- },
13
+ size: "xs",
16
14
  },
17
15
  },
18
- firstButton: "{UButton} {>paginationButton}",
19
- lastButton: "{UButton} {>paginationButton}",
20
- prevButton: "{UButton} {>paginationButton}",
21
- nextButton: "{UButton} {>paginationButton}",
22
- inactiveButton: "{UButton} {>paginationButton}",
23
- activeButton: "{UButton} {>paginationButton}",
16
+ firstButton: "{>paginationButton}",
17
+ lastButton: "{>paginationButton}",
18
+ prevButton: "{>paginationButton}",
19
+ nextButton: "{>paginationButton}",
20
+ inactiveButton: "{>paginationButton}",
21
+ activeButton: "{>paginationButton}",
24
22
  paginationIcon: {
25
23
  base: "{UIcon}",
26
24
  defaults: {
@@ -31,10 +29,10 @@ export default /*tw*/ {
31
29
  },
32
30
  },
33
31
  },
34
- lastIcon: "{UIcon} {>paginationIcon}",
35
- firstIcon: "{UIcon} {>paginationIcon}",
36
- prevIcon: "{UIcon} {>paginationIcon}",
37
- nextIcon: "{UIcon} {>paginationIcon}",
32
+ lastIcon: "{>paginationIcon}",
33
+ firstIcon: "{>paginationIcon}",
34
+ prevIcon: "{>paginationIcon}",
35
+ nextIcon: "{>paginationIcon}",
38
36
  defaults: {
39
37
  variant: "primary",
40
38
  size: "md",
@@ -3,30 +3,30 @@ import { computed, inject, toValue } from "vue";
3
3
 
4
4
  import useUI from "../composables/useUI.ts";
5
5
  import { getDefaults } from "../utils/ui.ts";
6
+ import UButton from "../ui.button/UButton.vue";
6
7
 
7
8
  import { COMPONENT_NAME } from "./constants.ts";
8
9
  import defaultConfig from "./config.ts";
9
10
 
10
- import type { Props, UTabSize, Config } from "./types.ts";
11
- import type { SetUTabsSelectedItem } from "../ui.navigation-tabs/types.ts";
11
+ import type { Props, Config } from "./types.ts";
12
+ import type { Props as UTabsProps, SetUTabsSelectedItem } from "../ui.navigation-tabs/types.ts";
12
13
 
13
14
  defineOptions({ inheritAttrs: false });
14
15
 
15
- const setUTabsSelectedItem = inject<SetUTabsSelectedItem | null>("setUTabsSelectedItem", null);
16
- const getUTabsSelectedItem = inject("getUTabsSelectedItem", null);
17
- const getUTabsSize = inject("getUTabsSize", null);
16
+ const setUTabsSelectedItem = inject<SetUTabsSelectedItem>("setUTabsSelectedItem");
17
+ const getUTabsSelectedItem = inject("getUTabsSelectedItem");
18
+ const getUTabsSquare = inject<UTabsProps["square"]>("getUTabsSquare");
19
+ const getUTabsBlock = inject<UTabsProps["block"]>("getUTabsBlock");
20
+ const getUTabsSize = inject<UTabsProps["size"]>("getUTabsSize", "md");
18
21
 
19
22
  const props = withDefaults(defineProps<Props>(), {
20
23
  ...getDefaults<Props, Config>(defaultConfig, COMPONENT_NAME),
21
24
  });
22
25
 
23
- const selected = computed(() => {
24
- return toValue(getUTabsSelectedItem) === props.value && !props.disabled;
25
- });
26
-
27
- const size = computed(() => {
28
- return toValue(getUTabsSize) || getDefaults<UTabSize, Config>(defaultConfig, COMPONENT_NAME).size;
29
- });
26
+ const size = computed(() => toValue(getUTabsSize));
27
+ const block = computed(() => toValue(getUTabsBlock));
28
+ const square = computed(() => toValue(getUTabsSquare));
29
+ const isActive = computed(() => toValue(getUTabsSelectedItem) === props.value && !props.disabled);
30
30
 
31
31
  async function onClickSetValue() {
32
32
  if (!props.disabled && setUTabsSelectedItem) {
@@ -40,18 +40,56 @@ async function onClickSetValue() {
40
40
  */
41
41
  const mutatedProps = computed(() => ({
42
42
  size: size.value,
43
+ block: block.value,
44
+ square: square.value,
43
45
  /* component state, not a props */
44
- selected: selected.value,
46
+ active: isActive.value,
45
47
  }));
46
48
 
47
- const { tabAttrs } = useUI<Config>(defaultConfig, mutatedProps);
49
+ const { tabButtonAttrs, tabButtonActiveAttrs } = useUI<Config>(defaultConfig, mutatedProps);
48
50
  </script>
49
51
 
50
52
  <template>
51
- <div v-bind="tabAttrs" :data-test="dataTest" @click="onClickSetValue">
52
- <!-- @slot Use it to add something instead of the label. -->
53
- <slot>
54
- {{ label }}
55
- </slot>
56
- </div>
53
+ <UButton
54
+ variant="thirdary"
55
+ :size="size"
56
+ :label="label"
57
+ :icon="icon"
58
+ :left-icon="leftIcon"
59
+ :right-icon="rightIcon"
60
+ :block="block"
61
+ :square="square"
62
+ :disabled="disabled"
63
+ v-bind="isActive ? tabButtonActiveAttrs : tabButtonAttrs"
64
+ :data-test="dataTest"
65
+ @click="onClickSetValue"
66
+ >
67
+ <template #left="{ iconName }">
68
+ <!--
69
+ @slot Use it to add something before the label.
70
+ @binding {boolean} active
71
+ @binding {string} icon-name
72
+ -->
73
+ <slot name="left" :active="isActive" :icon-name="iconName" />
74
+ </template>
75
+
76
+ <template #default="{ iconName, label }">
77
+ <!--
78
+ @slot Use it to add something instead of the label.
79
+ @binding {string} label
80
+ @binding {boolean} active
81
+ @binding {string} icon-name
82
+ -->
83
+ <slot :label="label" :active="isActive" :icon-name="iconName" />
84
+ </template>
85
+
86
+ <template #right="{ iconName }">
87
+ <!--
88
+ @slot Use it to add something after the label.
89
+ @binding {boolean} active
90
+ @binding {string} icon-name
91
+ -->
92
+ <slot name="right" :active="isActive" :icon-name="iconName" />
93
+ </template>
94
+ </UButton>
57
95
  </template>
@@ -1,18 +1,18 @@
1
1
  export default /*tw*/ {
2
- tab: {
3
- base: "w-max text-center cursor-pointer -mb-px",
4
- variants: {
5
- size: {
6
- sm: "text-xs pb-1",
7
- md: "text-sm pb-2",
8
- lg: "text-base pb-3",
9
- },
10
- disabled: {
11
- true: "text-gray-400 cursor-not-allowed",
12
- },
13
- selected: {
14
- true: "border-b-2 text-brand-700 border-brand-700",
15
- },
2
+ tabButton: {
3
+ base: `
4
+ {UButton} -mb-px rounded-none border-transparent
5
+ hover:bg-transparent dark:hover:bg-transparent
6
+ active:bg-transparent dark:active:bg-transparent
7
+ `,
8
+ defaults: {
9
+ color: "gray",
10
+ },
11
+ },
12
+ tabButtonActive: {
13
+ base: "{>tabButton} border-b-brand-600",
14
+ defaults: {
15
+ color: "brand",
16
16
  },
17
17
  },
18
18
  defaults: {
@@ -57,7 +57,7 @@ SlotDefault.args = {
57
57
  slotTemplate: `
58
58
  <template #default>
59
59
  <div class="flex items-center">
60
- <UIcon name="star" size="sm" />
60
+ <UIcon name="star" size="sm" color="inherit" />
61
61
  </div>
62
62
  </template>
63
63
  `,
@@ -3,10 +3,6 @@ import type { ComponentConfig } from "../types.ts";
3
3
 
4
4
  export type Config = typeof defaultConfig;
5
5
 
6
- export interface UTabSize {
7
- size: string;
8
- }
9
-
10
6
  export interface Props {
11
7
  /**
12
8
  * Tab label.
@@ -18,6 +14,21 @@ export interface Props {
18
14
  */
19
15
  value?: string | number;
20
16
 
17
+ /**
18
+ * Icon name (appears instead of label).
19
+ */
20
+ icon?: string;
21
+
22
+ /**
23
+ * Left icon name.
24
+ */
25
+ leftIcon?: string;
26
+
27
+ /**
28
+ * Right icon name.
29
+ */
30
+ rightIcon?: string;
31
+
21
32
  /**
22
33
  * Make tab disabled.
23
34
  */
@@ -32,15 +32,17 @@ const selectedItem = computed({
32
32
  set: (value) => emit("update:modelValue", value),
33
33
  });
34
34
 
35
- provide("setUTabsSelectedItem", (value: string) => (selectedItem.value = value));
36
- provide("getUTabsSelectedItem", () => selectedItem.value);
37
35
  provide("getUTabsSize", () => props.size);
36
+ provide("getUTabsBlock", () => props.block);
37
+ provide("getUTabsSquare", () => props.square);
38
+ provide("getUTabsSelectedItem", () => selectedItem.value);
39
+ provide("setUTabsSelectedItem", (value: string) => (selectedItem.value = value));
38
40
 
39
41
  /**
40
42
  * Get element / nested component attributes for each config token ✨
41
43
  * Applies: `class`, `config`, redefined default `props` and dev `vl-...` attributes.
42
44
  */
43
- const { tabsAttrs, itemAttrs } = useUI<Config>(defaultConfig);
45
+ const { tabsAttrs, tabAttrs } = useUI<Config>(defaultConfig);
44
46
  </script>
45
47
 
46
48
  <template>
@@ -54,7 +56,7 @@ const { tabsAttrs, itemAttrs } = useUI<Config>(defaultConfig);
54
56
  :value="item.value"
55
57
  :disabled="item.disabled"
56
58
  :size="size"
57
- v-bind="itemAttrs"
59
+ v-bind="tabAttrs"
58
60
  :data-test="`${dataTest}-item-${index}`"
59
61
  />
60
62
  </slot>
@@ -1,20 +1,9 @@
1
1
  export default /*tw*/ {
2
- tabs: {
3
- base: "mb-6 flex",
4
- variants: {
5
- size: {
6
- sm: "gap-5",
7
- md: "gap-6",
8
- lg: "gap-7",
9
- },
10
- underlined: {
11
- true: "border-b border-gray-100",
12
- },
13
- },
14
- },
15
- item: "{UTab}",
2
+ tabs: "mb-6 flex border-b border-gray-200 dark:border-gray-700",
3
+ tab: "{UTab}",
16
4
  defaults: {
17
5
  size: "md",
18
- underlined: false,
6
+ block: false,
7
+ square: false,
19
8
  },
20
9
  };
@@ -78,9 +78,6 @@ Default.args = {};
78
78
  export const Sizes = EnumVariantTemplate.bind({});
79
79
  Sizes.args = { enum: "size" };
80
80
 
81
- export const BottomLine = DefaultTemplate.bind({});
82
- BottomLine.args = { underlined: true };
83
-
84
81
  export const DisabledTab = DefaultTemplate.bind({});
85
82
  DisabledTab.args = {
86
83
  options: [
@@ -28,12 +28,17 @@ export interface Props {
28
28
  /**
29
29
  * Tabs size.
30
30
  */
31
- size?: "sm" | "md" | "lg";
31
+ size?: "2xs" | "xs" | "sm" | "md" | "lg" | "xl";
32
32
 
33
33
  /**
34
- * Add the bottom line along the entire length.
34
+ * Make the Tabs fill the width with its container.
35
35
  */
36
- underlined?: boolean;
36
+ block?: boolean;
37
+
38
+ /**
39
+ * Set the same paddings for the tabs.
40
+ */
41
+ square?: boolean;
37
42
 
38
43
  /**
39
44
  * Component config object.
@@ -111,7 +111,6 @@ const {
111
111
  v-if="closable"
112
112
  square
113
113
  size="xs"
114
- :ring="false"
115
114
  :color="closeButtonColor"
116
115
  variant="thirdary"
117
116
  v-bind="closeButtonAttrs"
@@ -16,14 +16,11 @@ export default /*tw*/ {
16
16
  true: "rounded-full",
17
17
  },
18
18
  tabindex: {
19
- true: `
20
- cursor-pointer focus-within:ring-dynamic focus-within:ring-offset-dynamic focus-within:ring-{color}-700/15
21
- focus:ring-dynamic focus:ring-offset-dynamic focus:ring-{color}-700/15
22
- `,
19
+ true: "cursor-pointer focus-visible:ring-dynamic focus-visible:ring-offset-dynamic focus-visible:ring-{color}-600",
23
20
  },
24
21
  color: {
25
- grayscale: "focus:ring-gray-700/15 focus-within:ring-gray-700/15",
26
- white: "focus:ring-gray-700/15 focus-within:ring-gray-700/15",
22
+ grayscale: "focus-visible:ring-gray-900",
23
+ white: " focus-visible:ring-gray-900",
27
24
  },
28
25
  },
29
26
  compoundVariants: [
@@ -59,7 +59,7 @@ const {
59
59
  </script>
60
60
 
61
61
  <template>
62
- <ULink :href="url" :ring="false" v-bind="fileAttrs" :data-test="dataTest">
62
+ <ULink :href="url" v-bind="fileAttrs" :data-test="dataTest">
63
63
  <slot name="left" :file="{ elementId, label, url, imageUrl }" />
64
64
 
65
65
  <slot :file="{ elementId, label, url, imageUrl }">
@@ -77,14 +77,7 @@ const {
77
77
  @blur="onBlur"
78
78
  />
79
79
 
80
- <ULink
81
- :label="label"
82
- :ring="false"
83
- :size="size"
84
- color="gray"
85
- dashed
86
- v-bind="fileLabelAttrs"
87
- />
80
+ <ULink :label="label" :size="size" color="gray" dashed v-bind="fileLabelAttrs" />
88
81
  </div>
89
82
  </slot>
90
83