vueless 0.0.216 → 0.0.218

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 (57) hide show
  1. package/package.json +2 -2
  2. package/ui.button/configs/default.config.js +19 -19
  3. package/ui.button-link/configs/default.config.js +6 -13
  4. package/ui.button-link/index.vue +1 -1
  5. package/ui.button-toggle/index.vue +1 -1
  6. package/ui.container-page/configs/default.config.js +1 -1
  7. package/ui.dropdown-button/index.vue +6 -3
  8. package/ui.dropdown-item/configs/default.config.js +3 -3
  9. package/ui.dropdown-link/index.vue +1 -1
  10. package/ui.dropdown-list/configs/default.config.js +10 -10
  11. package/ui.dropdown-list/index.vue +1 -1
  12. package/ui.form-calendar/components/MonthView.vue +13 -5
  13. package/ui.form-calendar/components/YearView.vue +13 -5
  14. package/ui.form-calendar/configs/default.config.js +2 -0
  15. package/ui.form-calendar/index.vue +1 -1
  16. package/ui.form-calendar/services/date.service.js +8 -0
  17. package/ui.form-checkbox/configs/default.config.js +8 -12
  18. package/ui.form-checkbox/index.vue +5 -7
  19. package/ui.form-checkbox-group/configs/default.config.js +10 -1
  20. package/ui.form-checkbox-group/index.stories.js +21 -28
  21. package/ui.form-checkbox-group/index.vue +3 -3
  22. package/ui.form-date-picker-range/configs/default.config.js +1 -1
  23. package/ui.form-date-picker-range/index.vue +28 -21
  24. package/ui.form-input/composables/attrs.composable.js +10 -10
  25. package/ui.form-input/configs/default.config.js +20 -15
  26. package/ui.form-input/index.vue +2 -1
  27. package/ui.form-input-file/configs/default.config.js +9 -18
  28. package/ui.form-input-file/index.vue +1 -1
  29. package/ui.form-input-money/index.vue +1 -1
  30. package/ui.form-input-rating/index.vue +1 -1
  31. package/ui.form-input-search/index.vue +1 -1
  32. package/ui.form-label/configs/default.config.js +40 -48
  33. package/ui.form-label/index.vue +10 -2
  34. package/ui.form-radio/configs/default.config.js +5 -10
  35. package/ui.form-radio/index.vue +3 -3
  36. package/ui.form-radio-group/configs/default.config.js +3 -4
  37. package/ui.form-radio-group/index.stories.js +7 -15
  38. package/ui.form-radio-group/index.vue +1 -1
  39. package/ui.form-select/configs/default.config.js +15 -21
  40. package/ui.form-select/index.vue +2 -2
  41. package/ui.form-switch/configs/default.config.js +14 -14
  42. package/ui.form-switch/index.vue +1 -1
  43. package/ui.form-textarea/configs/default.config.js +11 -16
  44. package/ui.form-textarea/index.vue +1 -1
  45. package/ui.image-icon/configs/default.config.js +11 -11
  46. package/ui.text-badge/configs/default.config.js +4 -4
  47. package/ui.text-block/configs/default.config.js +3 -4
  48. package/ui.text-block/index.vue +1 -1
  49. package/ui.text-empty/configs/default.config.js +12 -12
  50. package/ui.text-empty/index.vue +16 -9
  51. package/ui.text-file/configs/default.config.js +13 -4
  52. package/ui.text-file/index.vue +12 -2
  53. package/ui.text-files/configs/default.config.js +3 -10
  54. package/ui.text-files/index.vue +1 -1
  55. package/ui.text-money/configs/default.config.js +7 -8
  56. package/ui.text-money/index.stories.js +2 -9
  57. package/web-types.json +39 -30
@@ -82,21 +82,22 @@
82
82
  <UButton
83
83
  v-for="periodButton in periods"
84
84
  :key="periodButton.name"
85
+ :label="periodButton.title"
85
86
  variant="thirdary"
86
87
  size="xs"
87
88
  square
89
+ filled
88
90
  color="brand"
89
91
  v-bind="periodButtonAttrs(getPeriodButtonsClasses(periodButton.name))"
90
92
  @click="onClickPeriodButton(periodButton.name)"
91
- >
92
- {{ periodButton.title }}
93
- </UButton>
93
+ />
94
94
  </div>
95
95
 
96
96
  <div v-bind="periodsRowAttrs">
97
97
  <UButton
98
98
  v-if="customRangeButton.range.to && customRangeButton.range.from"
99
99
  variant="thirdary"
100
+ filled
100
101
  color="brand"
101
102
  v-bind="periodButtonAttrs(getPeriodButtonsClasses(PERIOD.custom))"
102
103
  @click="onClickCustomRangeButton"
@@ -107,6 +108,8 @@
107
108
 
108
109
  <UButton
109
110
  variant="thirdary"
111
+ size="xs"
112
+ filled
110
113
  color="brand"
111
114
  v-bind="periodButtonAttrs(getPeriodButtonsClasses(PERIOD.ownRange))"
112
115
  @click="onClickOwnRange"
@@ -123,29 +126,33 @@
123
126
 
124
127
  <template v-if="!isPeriod.ownRange && !isPeriod.custom">
125
128
  <div v-bind="rangeSwitchWrapperAttrs">
126
- <UIcon
127
- internal
128
- interactive
129
- color="grayscale"
130
- size="sm"
131
- :name="config.prevIconName"
132
- v-bind="prevIconAttrs"
133
- @click="onClickShiftDatesList('prev')"
134
- />
129
+ <UButton size="sm" color="brand" variant="thirdary" square>
130
+ <UIcon
131
+ internal
132
+ interactive
133
+ size="sm"
134
+ color="gray"
135
+ :name="config.prevIconName"
136
+ v-bind="prevIconAttrs"
137
+ @click="onClickShiftDatesList('prev')"
138
+ />
139
+ </UButton>
135
140
 
136
141
  <div v-bind="rangeSwitchTitleAttrs">
137
142
  {{ rangeSwitchTitle }}
138
143
  </div>
139
144
 
140
- <UIcon
141
- internal
142
- interactive
143
- class="icon"
144
- size="sm"
145
- :name="config.nextIconName"
146
- v-bind="nextIconAttrs"
147
- @click="onClickShiftDatesList('next')"
148
- />
145
+ <UButton size="sm" color="brand" variant="thirdary" square>
146
+ <UIcon
147
+ internal
148
+ interactive
149
+ size="sm"
150
+ color="gray"
151
+ :name="config.nextIconName"
152
+ v-bind="nextIconAttrs"
153
+ @click="onClickShiftDatesList('next')"
154
+ />
155
+ </UButton>
149
156
  </div>
150
157
 
151
158
  <div v-bind="periodDateListAttrs(getPeriodDateListClasses())">
@@ -1,9 +1,9 @@
1
1
  import { computed } from "vue";
2
2
  import useUI from "../../composable.ui";
3
- import { cva, cx } from "../../service.ui";
3
+ import { cva } from "../../service.ui";
4
4
  import defaultConfig from "../configs/default.config";
5
5
 
6
- export default function useAttrs(props, { inputPasswordClasses }) {
6
+ export default function useAttrs(props) {
7
7
  const { config, getAttrs, hasSlotContent, isSystemKey } = useUI(
8
8
  defaultConfig,
9
9
  () => props.config,
@@ -29,14 +29,14 @@ export default function useAttrs(props, { inputPasswordClasses }) {
29
29
 
30
30
  attrs[`${key}Attrs`] = getAttrs(key, { classes });
31
31
 
32
- if (key === "input") {
33
- const inputAttrs = attrs[`${key}Attrs`];
34
-
35
- attrs[`${key}Attrs`] = computed(() => ({
36
- ...inputAttrs.value,
37
- class: cx([inputAttrs.value.class, inputPasswordClasses.value]),
38
- }));
39
- }
32
+ // if (key === "input") {
33
+ // const inputAttrs = attrs[`${key}Attrs`];
34
+ //
35
+ // attrs[`${key}Attrs`] = computed(() => ({
36
+ // ...inputAttrs.value,
37
+ // class: cx([inputAttrs.value.class]),
38
+ // }));
39
+ // }
40
40
  }
41
41
 
42
42
  return {
@@ -1,5 +1,5 @@
1
1
  export default /*tw*/ {
2
- label: "{ULabel} relative w-full",
2
+ label: "{ULabel}",
3
3
  inputWrapper: "flex relative w-full",
4
4
  rightIconSlot: "flex items-center justify-end whitespace-nowrap pr-3 rounded-r-lg rounded-l-none",
5
5
  leftIconSlot: "flex items-center justify-end whitespace-nowrap pl-3 rounded-l-lg rounded-r-none",
@@ -8,7 +8,8 @@ export default /*tw*/ {
8
8
  passwordHiddenIconName: "visibility_off-fill",
9
9
  block: {
10
10
  base: `
11
- rounded-lg border border-solid border-gray-300 bg-white !opacity-100 relative flex transition
11
+ w-full bg-white !opacity-100 relative flex transition
12
+ rounded-md border border-solid border-gray-300
12
13
  hover:border-gray-400 hover:focus-within:border-brand-500
13
14
  focus-within:border-brand-500 focus-within:ring-4 focus-within:ring-brand-600/[.15]
14
15
  `,
@@ -21,46 +22,50 @@ export default /*tw*/ {
21
22
  },
22
23
  error: {
23
24
  true: `
24
- border-red-300
25
+ hover:bg-red-300 border-red-300
25
26
  hover:border-red-400 hover:focus-within:border-red-500
26
27
  focus-within:border-red-500 focus-within:ring-red-100
27
28
  `,
28
29
  },
29
30
  },
31
+ compoundVariants: [{ labelAlign: "topInside", label: true, class: "rounded-lg" }],
30
32
  },
31
33
  input: {
32
34
  base: `
33
- block w-full pb-2 px-4 font-normal leading-none text-gray-900 placeholder:font-normal placeholder-gray-400
34
- transition bg-white border-none border-gray-300 rounded-lg shadow-none
35
+ block w-full py-2 px-3 font-normal leading-none text-gray-900
36
+ placeholder:font-normal placeholder-gray-400
37
+ transition bg-white border-none border-gray-300 rounded-md shadow-none
35
38
  focus:outline-none focus:ring-0 disabled:opacity-50
36
39
  disabled:cursor-not-allowed disabled:text-gray-900 disabled:border-gray-100
37
40
  read-only:border-gray-300 read-only:ring-0
38
41
  `,
39
42
  variants: {
40
43
  size: {
41
- sm: "pt-2 pb-2 text-sm placeholder:text-sm placeholder:font-normal",
42
- md: "pt-2.5 pb-2.5 text-base placeholder:text-base placeholder:font-normal",
43
- lg: "pt-3 pb-3 text-lg placeholder:text-lg placeholder:font-normal",
44
+ sm: "text-xs placeholder:text-xs placeholder:font-normal",
45
+ md: "text-sm placeholder:text-sm placeholder:font-normal",
46
+ lg: "text-base placeholder:text-base placeholder:font-normal",
44
47
  },
45
- error: `
46
- border-red-300 hover:border-red-400 focus:border-red-500 focus:ring-red-100
48
+ error: {
49
+ true: `
50
+ bg-red-50 border-red-900 hover:border-red-400 focus:border-red-500 focus:ring-red-100
47
51
  focus-within:border-red-500 focus-within:ring-red-100
48
52
  `,
53
+ },
49
54
  },
50
55
  compoundVariants: [
51
- { labelAlign: "topInside", label: true, size: "sm", class: "pt-5 pb-1.5" },
52
- { labelAlign: "topInside", label: true, size: "md", class: "pt-6 pb-1.5" },
53
- { labelAlign: "topInside", label: true, size: "lg", class: "pt-7 pb-2" },
56
+ { labelAlign: "topInside", label: true, class: "rounded-lg" },
57
+ { labelAlign: "topInside", label: true, size: "sm", class: "pt-5" },
58
+ { labelAlign: "topInside", label: true, size: "md", class: "pt-6" },
59
+ { labelAlign: "topInside", label: true, size: "lg", class: "pt-7" },
54
60
  ],
55
61
  },
56
62
  defaultVariants: {
57
63
  size: "md",
58
64
  type: "text",
59
65
  inputmode: "text",
60
- error: false,
66
+ labelAlign: "topInside",
61
67
  readonly: false,
62
68
  disabled: false,
63
- labelAlign: "topInside",
64
69
  noAutocomplete: false,
65
70
  },
66
71
  };
@@ -8,6 +8,7 @@
8
8
  :error="error"
9
9
  :size="size"
10
10
  :align="labelAlign"
11
+ centred
11
12
  v-bind="labelAttrs"
12
13
  >
13
14
  <label :for="id" v-bind="blockAttrs">
@@ -168,7 +169,7 @@ const props = defineProps({
168
169
 
169
170
  /**
170
171
  * Set label placement related from the default slot.
171
- * @values top, topInside, topWithDesc, bottom, left, right
172
+ * @values top, topInside, topWithDesc, left, right
172
173
  */
173
174
  labelAlign: {
174
175
  type: String,
@@ -1,18 +1,9 @@
1
1
  export default /*tw*/ {
2
- label: {
3
- wrapper: "{ULabel} relative w-full",
4
- label: {
5
- compoundVariants: [
6
- { align: "topInside", size: "sm", class: "left-5 top-4" },
7
- { align: "topInside", size: "md", class: "left-5 top-5" },
8
- { align: "topInside", size: "lg", class: "left-5 top-6" },
9
- ],
10
- },
11
- },
2
+ label: "{ULabel} w-full",
12
3
  dropzoneWrapper: {
13
4
  base: `
14
5
  size-auto w-full rounded-lg border border-solid border-gray-300 bg-white
15
- p-4 px-5 py-6 transition hover:border-gray-400
6
+ p-3 transition hover:border-gray-400
16
7
  `,
17
8
  variants: {
18
9
  error: {
@@ -20,14 +11,14 @@ export default /*tw*/ {
20
11
  },
21
12
  },
22
13
  compoundVariants: [
23
- { labelAlign: "topInside", label: true, size: "sm", class: "pt-8" },
24
- { labelAlign: "topInside", label: true, size: "md", class: "pt-10" },
25
- { labelAlign: "topInside", label: true, size: "lg", class: "pt-12" },
14
+ { labelAlign: "topInside", label: true, size: "sm", class: "pt-7" },
15
+ { labelAlign: "topInside", label: true, size: "md", class: "pt-8" },
16
+ { labelAlign: "topInside", label: true, size: "lg", class: "pt-9" },
26
17
  ],
27
18
  },
28
19
  description: "{UText} text-gray-700",
29
20
  contentWrapper: {
30
- base: "relative mt-3 flex w-full gap-6 justify-between items-start rounded bg-brand-50 p-3",
21
+ base: "relative flex w-full gap-6 justify-between items-start rounded-lg bg-brand-50 p-3",
31
22
  variants: {
32
23
  multiple: {
33
24
  false: "items-center",
@@ -38,9 +29,9 @@ export default /*tw*/ {
38
29
  base: "pr-4 text-gray-700 flex-grow w-full self-center",
39
30
  variants: {
40
31
  size: {
41
- sm: "text-sm",
42
- md: "text-base",
43
- lg: "text-lg",
32
+ sm: "text-xs",
33
+ md: "text-sm",
34
+ lg: "text-base",
44
35
  },
45
36
  },
46
37
  },
@@ -116,7 +116,7 @@ const props = defineProps({
116
116
 
117
117
  /**
118
118
  * Set label placement related from the default slot.
119
- * @values top, topInside, topWithDesc, bottom, left, right
119
+ * @values top, topInside, topWithDesc, left, right
120
120
  */
121
121
  labelAlign: {
122
122
  type: String,
@@ -68,7 +68,7 @@ const props = defineProps({
68
68
 
69
69
  /**
70
70
  * Set label placement related from the default slot.
71
- * @values top, topInside, topWithDesc, bottom, left, right
71
+ * @values top, topInside, topWithDesc, left, right
72
72
  */
73
73
  labelAlign: {
74
74
  type: String,
@@ -99,7 +99,7 @@ const props = defineProps({
99
99
 
100
100
  /**
101
101
  * Rating label placement.
102
- * @values top, topInside, topWithDesc, bottom, left, right
102
+ * @values top, topWithDesc, left, right
103
103
  */
104
104
  labelAlign: {
105
105
  type: String,
@@ -103,7 +103,7 @@ const props = defineProps({
103
103
 
104
104
  /**
105
105
  * Label placement.
106
- * @values top, topInside, topWithDesc, bottom, left, right
106
+ * @values top, topInside, topWithDesc, left, right
107
107
  */
108
108
  labelAlign: {
109
109
  type: String,
@@ -1,40 +1,41 @@
1
1
  export default /*tw*/ {
2
2
  wrapper: {
3
- base: "flex",
3
+ base: "flex gap-2",
4
4
  variants: {
5
- size: {
6
- xs: "gap-2",
7
- sm: "gap-2",
8
- md: "gap-2.5",
9
- lg: "gap-3",
10
- xl: "gap-3.5",
11
- },
12
5
  align: {
13
6
  top: "flex-col",
14
- topInside: "flex-col gap-0",
7
+ topInside: "flex-col gap-0 relative",
15
8
  topWithDesc: "flex-col-reverse w-fit",
16
- left: "flex-row w-fit",
17
- right: "flex-row-reverse w-fit",
18
- bottom: "flex-col-reverse w-fit",
9
+ right: "flex-row w-fit",
10
+ left: "flex-row-reverse w-fit",
19
11
  },
20
12
  },
13
+ compoundVariants: [
14
+ { align: "left", size: "sm", class: "gap-2" },
15
+ { align: "left", size: "md", class: "gap-3" },
16
+ { align: "left", size: "lg", class: "gap-4" },
17
+ { align: "right", size: "sm", class: "gap-2.5" },
18
+ { align: "right", size: "md", class: "gap-3" },
19
+ { align: "right", size: "lg", class: "gap-3.5" },
20
+ { align: "left", centred: true, class: "items-center" },
21
+ { align: "right", centred: true, class: "items-center" },
22
+ ],
21
23
  },
22
24
  labelWrapper: "",
23
25
  label: {
24
- base: "text-gray-500 z-10 font-normal block !leading-none",
26
+ base: "text-gray-900 z-10 block !leading-none",
25
27
  variants: {
26
28
  size: {
27
- xs: "text-2xs",
28
29
  sm: "text-xs",
29
30
  md: "text-sm",
30
31
  lg: "text-base",
31
- xl: "text-lg",
32
32
  },
33
33
  align: {
34
- topInside: "absolute left-4",
35
- topWithDesc: "pt-1 pb-1.5",
36
- left: "pt-1 pb-1 text-gray-900",
37
- right: "pt-1 pb-1 text-gray-900",
34
+ top: "font-medium",
35
+ topInside: "font-normal absolute left-3 text-gray-500",
36
+ topWithDesc: "font-medium",
37
+ left: "font-normal",
38
+ right: "font-normal",
38
39
  },
39
40
  error: {
40
41
  true: "text-red-500",
@@ -44,61 +45,52 @@ export default /*tw*/ {
44
45
  },
45
46
  },
46
47
  compoundVariants: [
47
- { align: "topInside", size: "xs", class: "top-1.5" },
48
- { align: "topInside", size: "sm", class: "top-2" },
49
- { align: "topInside", size: "md", class: "top-2.5" },
50
- { align: "topInside", size: "lg", class: "top-3" },
51
- { align: "topInside", size: "xl", class: "top-3.5" },
52
- { align: "topWithDesc", size: "xs", class: "-mt-px" },
53
- { align: "topWithDesc", size: "sm", class: "" },
54
- { align: "topWithDesc", size: "md", class: "mt-px" },
55
- { align: "topWithDesc", size: "lg", class: "mt-0.5" },
56
- { align: "topWithDesc", size: "xl", class: "mt-1" },
57
- { align: "left", size: "xs", class: "-mt-0.5 text-sm" },
58
- { align: "left", size: "sm", class: "text-sm" },
59
- { align: "left", size: "md", class: "mt-px text-base" },
60
- { align: "left", size: "lg", class: "mt-0.5 text-lg" },
61
- { align: "left", size: "xl", class: "mt-1 text-xl" },
62
- { align: "right", size: "sm", class: "-mt-0.5 text-xs" },
63
- { align: "right", size: "sm", class: "text-sm" },
64
- { align: "right", size: "md", class: "mt-px text-base" },
65
- { align: "right", size: "lg", class: "mt-0.5 text-lg" },
66
- { align: "right", size: "xl", class: "mt-1 text-xl" },
48
+ { align: "topInside", size: "sm", class: "top-2 text-2xs" },
49
+ { align: "topInside", size: "md", class: "top-2.5 text-xs" },
50
+ { align: "topInside", size: "lg", class: "top-2.5 text-sm" },
51
+ { align: "topWithDesc", size: "sm", class: "-mt-px" },
52
+ { align: "topWithDesc", size: "md", class: "" },
53
+ { align: "topWithDesc", size: "lg", class: "mt-px" },
54
+ { align: "left", size: "sm", class: "-mt-px text-sm" },
55
+ { align: "left", size: "md", class: "text-sm" },
56
+ { align: "left", size: "lg", class: "mt-px text-base" },
57
+ { align: "right", size: "sm", class: "-mt-px text-xs" },
58
+ { align: "right", size: "md", class: "text-sm" },
59
+ { align: "right", size: "lg", class: "mt-px text-base" },
60
+ { align: "left", centred: false, class: "pt-1" },
61
+ { align: "right", centred: false, class: "pt-1" },
67
62
  ],
68
63
  },
69
64
  description: {
70
- base: "font-normal text-gray-500/[85] !leading-none",
65
+ base: "font-normal text-gray-500 !leading-none",
71
66
  variants: {
72
67
  size: {
73
- xs: "text-2xs",
74
68
  sm: "text-2xs",
75
69
  md: "text-xs",
76
70
  lg: "text-sm",
77
- xl: "text-base",
78
71
  },
79
72
  align: {
80
- topInside: "pl-4",
81
73
  top: "pl-0 -mt-0.5",
82
- left: "pl-0",
83
- right: "pl-0",
84
- bottom: "-order-1 -mt-2",
74
+ topInside: "pl-3",
75
+ topWithDesc: "pt-1",
76
+ left: "pt-1 pl-0",
77
+ right: "pt-1 pl-0",
85
78
  },
86
79
  error: {
87
80
  true: "text-red-500",
88
81
  },
89
82
  },
90
83
  compoundVariants: [
91
- { align: "topInside", size: "xs", class: "mt-1" },
92
84
  { align: "topInside", size: "sm", class: "mt-1.5" },
93
85
  { align: "topInside", size: "md", class: "mt-2" },
94
86
  { align: "topInside", size: "lg", class: "mt-2.5" },
95
- { align: "topInside", size: "xl", class: "mt-3" },
96
87
  ],
97
88
  },
98
89
  defaultVariants: {
99
90
  align: "top",
100
91
  size: "md",
101
92
  error: false,
93
+ centred: false,
102
94
  disabled: false,
103
95
  },
104
96
  };
@@ -94,14 +94,22 @@ const props = defineProps({
94
94
  },
95
95
 
96
96
  /**
97
- * Set label placement related from the default slot.
98
- * @values top, topInside, topWithDesc, bottom, left, right
97
+ * Label placement.
98
+ * @values top, topInside, topWithDesc, left, right
99
99
  */
100
100
  align: {
101
101
  type: String,
102
102
  default: UIService.get(defaultConfig, ULabel).default.align,
103
103
  },
104
104
 
105
+ /**
106
+ * Centre label.
107
+ */
108
+ centred: {
109
+ type: Boolean,
110
+ default: UIService.get(defaultConfig, ULabel).default.centred,
111
+ },
112
+
105
113
  /**
106
114
  * Set error message.
107
115
  */
@@ -1,8 +1,5 @@
1
1
  export default /*tw*/ {
2
- label: {
3
- wrapper: "inline-flex",
4
- label: "{ULabel} cursor-pointer",
5
- },
2
+ label: "{ULabel}",
6
3
  radio: {
7
4
  base: `
8
5
  cursor-pointer
@@ -15,11 +12,9 @@ export default /*tw*/ {
15
12
  `,
16
13
  variants: {
17
14
  size: {
18
- xs: "size-4",
19
- sm: "size-5",
20
- md: "size-6",
21
- lg: "size-7",
22
- xl: "size-8",
15
+ sm: "size-4",
16
+ md: "size-5",
17
+ lg: "size-6",
23
18
  },
24
19
  },
25
20
  compoundVariants: [
@@ -38,7 +33,7 @@ export default /*tw*/ {
38
33
  defaultVariants: {
39
34
  size: "md",
40
35
  color: "brand",
41
- labelAlign: "left",
36
+ labelAlign: "right",
42
37
  disabled: false,
43
38
  checked: false,
44
39
  },
@@ -91,7 +91,7 @@ const props = defineProps({
91
91
 
92
92
  /**
93
93
  * Radio size.
94
- * @values xs, sm, md, lg, xl
94
+ * @values sm, md, lg
95
95
  */
96
96
  size: {
97
97
  type: String,
@@ -108,8 +108,8 @@ const props = defineProps({
108
108
  },
109
109
 
110
110
  /**
111
- * Set label placement related from the default slot.
112
- * @values top, topInside, topWithDesc, bottom, left, right
111
+ * Label placement.
112
+ * @values left, right
113
113
  */
114
114
  labelAlign: {
115
115
  type: String,
@@ -5,10 +5,9 @@ export default /*tw*/ {
5
5
  base: "flex flex-col",
6
6
  variants: {
7
7
  size: {
8
- sm: "gap-2",
9
- md: "gap-3",
10
- lg: "gap-4",
11
- xl: "gap-5",
8
+ sm: "gap-1.5 mt-1",
9
+ md: "gap-2 mt-1.5",
10
+ lg: "gap-2.5 mt-2",
12
11
  },
13
12
  },
14
13
  },
@@ -38,21 +38,13 @@ const DefaultTemplate = (args) => ({
38
38
  };
39
39
  },
40
40
  template: `
41
- <UGroup>
41
+ <UGroup gap="2xl">
42
42
  <URadioGroup v-bind="args" v-model="value">
43
- <template v-for="(radio,index) in args.radios" :key="index">
44
- <URadio
45
- v-bind="radio"
46
- >
47
- </URadio>
48
- </template>
43
+ <URadio v-for="(radio, index) in args.radios" :key="index" v-bind="radio" />
49
44
  </URadioGroup>
50
-
51
- <URow>
52
- <UAlert color="green" size="sm">
53
- <p>Selected value: <b>{{ value }}</b></p>
54
- </UAlert>
55
- </URow>
45
+ <UAlert color="gray" size="xs">
46
+ <code>Selected value: <b>{{ value }}</b></code>
47
+ </UAlert>
56
48
  </UGroup>
57
49
  `,
58
50
  });
@@ -100,7 +92,7 @@ const ColorsTemplate = (args, { argTypes } = {}) => ({
100
92
  :label="color"
101
93
  :color="color"
102
94
  :options="args.radios"
103
- name="color"
95
+ :name="color"
104
96
  v-model="value"
105
97
  />
106
98
  </URow>
@@ -127,7 +119,7 @@ const SizesTemplate = (args, { argTypes } = {}) => ({
127
119
  :label="size"
128
120
  :size="size"
129
121
  :options="args.radios"
130
- name="size"
122
+ :name="size"
131
123
  v-model="value"
132
124
  />
133
125
  </URow>
@@ -84,7 +84,7 @@ const props = defineProps({
84
84
 
85
85
  /**
86
86
  * Radio size.
87
- * @values xs, sm, md, lg, xl
87
+ * @values sm, md, lg
88
88
  */
89
89
  size: {
90
90
  type: String,