@uxf/ui 10.0.0-beta.7 → 10.0.0-beta.74

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 (194) hide show
  1. package/_file-input-base/file-input-base.js +9 -1
  2. package/_select-base/_select-base.d.ts +1 -1
  3. package/_select-base/_select-base.js +4 -3
  4. package/alert-bubble/alert-bubble.d.ts +8 -0
  5. package/alert-bubble/alert-bubble.js +22 -0
  6. package/alert-bubble/alert-bubble.spec.d.ts +1 -0
  7. package/alert-bubble/alert-bubble.spec.js +9 -0
  8. package/alert-bubble/alert-bubble.stories.d.ts +7 -0
  9. package/alert-bubble/alert-bubble.stories.js +50 -0
  10. package/alert-bubble/index.d.ts +3 -0
  11. package/alert-bubble/index.js +5 -0
  12. package/alert-bubble/theme.d.ts +16 -0
  13. package/alert-bubble/theme.js +2 -0
  14. package/avatar-file-input/avatar-file-input.d.ts +3 -0
  15. package/avatar-file-input/avatar-file-input.js +10 -4
  16. package/avatar-file-input/avatar-file-input.stories.js +2 -2
  17. package/avatar-file-input/theme.d.ts +5 -0
  18. package/avatar-file-input/theme.js +2 -0
  19. package/button/theme.d.ts +1 -0
  20. package/calendar/calendar-day-cell.d.ts +3 -0
  21. package/calendar/calendar-day-cell.js +14 -14
  22. package/{date-picker/date-picker-navigation.d.ts → calendar/calendar-navigation.d.ts} +2 -3
  23. package/{date-picker/date-picker-navigation.js → calendar/calendar-navigation.js} +6 -6
  24. package/calendar/calendar-provider.js +1 -1
  25. package/calendar/calendar.d.ts +5 -0
  26. package/calendar/calendar.js +5 -8
  27. package/calendar/index.d.ts +4 -1
  28. package/calendar/index.js +5 -15
  29. package/chip/chip.js +6 -4
  30. package/chip/chip.stories.js +37 -28
  31. package/combobox/combobox.d.ts +1 -1
  32. package/combobox/combobox.stories.d.ts +2 -1
  33. package/combobox/combobox.stories.js +6 -2
  34. package/config/icons-config.d.ts +1 -1
  35. package/config/icons-config.js +1 -1
  36. package/config/icons.d.ts +13 -3
  37. package/config/icons.js +3 -1
  38. package/css/alert-bubble.css +100 -0
  39. package/css/avatar-file-input.css +54 -20
  40. package/css/avatar.css +3 -3
  41. package/css/badge.css +5 -5
  42. package/css/button-group.css +1 -1
  43. package/css/button-list.css +2 -2
  44. package/css/button.css +72 -26
  45. package/css/calendar.css +115 -51
  46. package/css/checkbox-button.css +8 -8
  47. package/css/checkbox.css +9 -9
  48. package/css/chip.css +217 -318
  49. package/css/color-radio-group.css +1 -1
  50. package/css/color-radio.css +3 -3
  51. package/css/component-structure-analyzer.css +12 -12
  52. package/css/date-picker.css +10 -3
  53. package/css/date-range-picker.css +21 -0
  54. package/css/datetime-picker.css +2 -2
  55. package/css/dialog.css +55 -0
  56. package/css/dropdown.css +10 -2
  57. package/css/dropzone.css +7 -7
  58. package/css/error-message.css +1 -1
  59. package/css/file-input.css +2 -2
  60. package/css/flash-messages.css +133 -9
  61. package/css/icon.css +1 -1
  62. package/css/image-gallery.css +7 -7
  63. package/css/input-with-popover.css +1 -1
  64. package/css/input.css +8 -8
  65. package/css/layout.css +4 -4
  66. package/css/list-item.css +2 -2
  67. package/css/message.css +92 -0
  68. package/css/modal.css +10 -54
  69. package/css/multi-combobox.css +10 -10
  70. package/css/pagination.css +14 -14
  71. package/css/paper.css +1 -1
  72. package/css/radio-group.css +3 -3
  73. package/css/radio.css +7 -7
  74. package/css/raster-image.css +1 -1
  75. package/css/select-base.css +1 -1
  76. package/css/tabs.css +13 -13
  77. package/css/text-link.css +4 -4
  78. package/css/textarea.css +68 -76
  79. package/css/time-picker.css +12 -16
  80. package/css/toggle.css +1 -1
  81. package/css/tooltip.css +2 -2
  82. package/date-picker/date-picker-decade.js +6 -6
  83. package/date-picker/date-picker-month.js +6 -6
  84. package/date-picker/date-picker-year.js +2 -2
  85. package/date-picker/date-picker.d.ts +2 -0
  86. package/date-picker/date-picker.js +2 -0
  87. package/date-picker-input/date-picker-input.d.ts +1 -0
  88. package/date-picker-input/date-picker-input.js +3 -1
  89. package/date-range-picker/date-range-picker-content.d.ts +2 -0
  90. package/date-range-picker/date-range-picker-content.js +55 -0
  91. package/date-range-picker/date-range-picker-decade.d.ts +6 -0
  92. package/date-range-picker/date-range-picker-decade.js +72 -0
  93. package/date-range-picker/date-range-picker-month.d.ts +8 -0
  94. package/date-range-picker/date-range-picker-month.js +69 -0
  95. package/date-range-picker/date-range-picker-year.d.ts +7 -0
  96. package/date-range-picker/date-range-picker-year.js +80 -0
  97. package/date-range-picker/date-range-picker.d.ts +10 -0
  98. package/date-range-picker/date-range-picker.js +51 -0
  99. package/date-range-picker/date-range-picker.spec.d.ts +1 -0
  100. package/date-range-picker/date-range-picker.spec.js +9 -0
  101. package/date-range-picker/date-range-picker.stories.d.ts +7 -0
  102. package/date-range-picker/date-range-picker.stories.js +43 -0
  103. package/date-range-picker/index.d.ts +3 -0
  104. package/date-range-picker/index.js +5 -0
  105. package/date-range-picker/types.d.ts +5 -0
  106. package/date-range-picker/types.js +2 -0
  107. package/date-range-picker-input/date-range-picker-input.d.ts +16 -0
  108. package/date-range-picker-input/date-range-picker-input.js +62 -0
  109. package/date-range-picker-input/date-range-picker-input.spec.d.ts +1 -0
  110. package/date-range-picker-input/date-range-picker-input.spec.js +9 -0
  111. package/date-range-picker-input/date-range-picker-input.stories.d.ts +10 -0
  112. package/date-range-picker-input/date-range-picker-input.stories.js +53 -0
  113. package/date-range-picker-input/index.d.ts +2 -0
  114. package/date-range-picker-input/index.js +5 -0
  115. package/datetime-picker/datetime-picker.d.ts +1 -0
  116. package/datetime-picker/datetime-picker.js +2 -2
  117. package/datetime-picker-input/datetime-picker-input.d.ts +1 -0
  118. package/datetime-picker-input/datetime-picker-input.js +3 -1
  119. package/dialog/dialog.d.ts +9 -0
  120. package/{modal/modal-dialog.js → dialog/dialog.js} +8 -9
  121. package/dialog/dialog.spec.d.ts +1 -0
  122. package/dialog/dialog.spec.js +9 -0
  123. package/dialog/dialog.stories.d.ts +7 -0
  124. package/dialog/dialog.stories.js +47 -0
  125. package/dialog/index.d.ts +2 -0
  126. package/dialog/index.js +5 -0
  127. package/dropzone/dropzone-input.js +10 -6
  128. package/file-input/file-input.d.ts +3 -0
  129. package/file-input/file-input.js +5 -5
  130. package/flash-messages/flash-message.js +1 -1
  131. package/flash-messages/flash-messages.js +44 -10
  132. package/flash-messages/flash-messages.stories.js +12 -0
  133. package/image-gallery/components/close-button.d.ts +2 -1
  134. package/image-gallery/components/close-button.js +2 -3
  135. package/image-gallery/components/gallery.d.ts +4 -1
  136. package/image-gallery/components/gallery.js +5 -4
  137. package/image-gallery/components/next-button.d.ts +7 -0
  138. package/image-gallery/components/next-button.js +14 -0
  139. package/image-gallery/components/prev-button.d.ts +7 -0
  140. package/image-gallery/components/prev-button.js +14 -0
  141. package/image-gallery/image-gallery.d.ts +4 -1
  142. package/image-gallery/image-gallery.js +1 -1
  143. package/image-gallery/image-gallery.stories.js +5 -1
  144. package/message/index.d.ts +3 -0
  145. package/message/index.js +7 -0
  146. package/message/message-content.d.ts +17 -0
  147. package/message/message-content.js +41 -0
  148. package/message/message-service.d.ts +13 -0
  149. package/message/message-service.js +29 -0
  150. package/message/message.d.ts +20 -0
  151. package/message/message.js +47 -0
  152. package/message/message.spec.d.ts +1 -0
  153. package/message/message.spec.js +9 -0
  154. package/message/message.stories.d.ts +7 -0
  155. package/message/message.stories.js +82 -0
  156. package/message/theme.d.ts +12 -0
  157. package/message/theme.js +2 -0
  158. package/modal/index.d.ts +2 -1
  159. package/modal/index.js +3 -3
  160. package/modal/modal.d.ts +5 -4
  161. package/modal/modal.js +9 -9
  162. package/modal/modal.stories.js +12 -0
  163. package/modal/theme.d.ts +3 -0
  164. package/multi-combobox/_multi-combobox-base.js +9 -3
  165. package/multi-combobox/multi-combobox.stories.js +6 -3
  166. package/multi-combobox/types.d.ts +4 -0
  167. package/multi-select/_multi-select-base.js +2 -2
  168. package/multi-select/multi-select.stories.js +5 -2
  169. package/package.json +10 -8
  170. package/radio-group/index.d.ts +1 -1
  171. package/radio-group/radio-group.d.ts +3 -3
  172. package/radio-group/radio-group.js +2 -2
  173. package/radio-group/radio-group.stories.js +4 -4
  174. package/raster-image/raster-image.js +1 -1
  175. package/select/select.d.ts +1 -1
  176. package/select/select.stories.d.ts +2 -1
  177. package/select/select.stories.js +8 -2
  178. package/textarea/textarea.js +5 -5
  179. package/time-picker/time-picker-hour.js +3 -3
  180. package/time-picker/time-picker-hours.js +1 -1
  181. package/time-picker/time-picker-minute.js +3 -3
  182. package/time-picker/time-picker-minutes.js +1 -1
  183. package/time-picker/time-picker.d.ts +1 -0
  184. package/time-picker/time-picker.js +3 -2
  185. package/time-picker-input/time-picker-input.js +3 -1
  186. package/tooltip/tooltip.js +20 -18
  187. package/utils/icons-config.js +13 -3
  188. package/utils/mocks/uploadFIle.mock.js +1 -1
  189. package/utils/storybook-config.d.ts +11 -1
  190. package/utils/storybook-config.js +9 -1
  191. package/utils/tailwind-config.js +8 -0
  192. package/image-gallery/components/arrow-button.d.ts +0 -7
  193. package/image-gallery/components/arrow-button.js +0 -14
  194. package/modal/modal-dialog.d.ts +0 -11
@@ -37,7 +37,7 @@ exports.default = {
37
37
  };
38
38
  const options = [
39
39
  { id: "one", label: "Option one" },
40
- { id: "two", label: "Option two" },
40
+ { id: "two", label: "Option two disabled", disabled: true },
41
41
  { id: "three", label: "Option three" },
42
42
  { id: "four", label: "Option with diacritics (ěščřžýáíé)" },
43
43
  ];
@@ -52,7 +52,11 @@ function Default() {
52
52
  react_1.default.createElement(index_1.Combobox, { id: "combobox-1", label: "Combobox", name: "combobox", onChange: onChange, options: options, placeholder: "Vyberte...", value: value }),
53
53
  react_1.default.createElement(index_1.Combobox, { helperText: "Start typing to see options...", id: "combobox-1", label: "Combobox with helper text", name: "combobox", onChange: onChange, options: options, placeholder: "Vyberte...", value: value }),
54
54
  react_1.default.createElement(index_1.Combobox, { helperText: "Error message", id: "combobox-1", isInvalid: true, isRequired: true, label: "Combobox invalid", name: "combobox", onChange: onChange, options: options, placeholder: "Vyberte...", value: value }),
55
- react_1.default.createElement(index_1.Combobox, { dropdownPlacement: "top", id: "combobox-1", label: "Combobox with dropdown top", name: "combobox", onChange: onChange, options: options, placeholder: "Vyberte...", isClearable: true, value: value })));
55
+ react_1.default.createElement(index_1.Combobox, { dropdownPlacement: "top", id: "combobox-1", label: "Combobox with dropdown top", name: "combobox", onChange: onChange, options: options, placeholder: "Vyberte...", isClearable: true, value: value }),
56
+ react_1.default.createElement(index_1.Combobox, { id: "combobox-render", label: "RenderOption", name: "combobox", onChange: onChange, options: options, placeholder: "Vyberte...", isClearable: true, value: value, renderOption: (option, isSelected) => (react_1.default.createElement(react_1.default.Fragment, null,
57
+ "Option: ",
58
+ option.label,
59
+ isSelected && " (selected)")) })));
56
60
  return (react_1.default.createElement("div", { className: "flex flex-col lg:flex-row" },
57
61
  react_1.default.createElement("div", { className: "light space-y-2 p-20 lg:w-1/2" }, storyComboboxes),
58
62
  react_1.default.createElement("div", { className: "dark space-y-2 bg-gray-900 p-20 lg:w-1/2" }, storyComboboxes)));
@@ -1,2 +1,2 @@
1
- export declare const ICONS_VERSION = "1685632683041";
1
+ export declare const ICONS_VERSION = "1687765245583";
2
2
  export declare const ICON_SPRITE = "/.storybook/static-assets/icons-generated/_icon-sprite.svg";
@@ -1,5 +1,5 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.ICON_SPRITE = exports.ICONS_VERSION = void 0;
4
- exports.ICONS_VERSION = "1685632683041";
4
+ exports.ICONS_VERSION = "1687765245583";
5
5
  exports.ICON_SPRITE = "/.storybook/static-assets/icons-generated/_icon-sprite.svg";
package/config/icons.d.ts CHANGED
@@ -75,14 +75,22 @@ export declare const ICONS: {
75
75
  readonly w: 384;
76
76
  readonly h: 512;
77
77
  };
78
- readonly videoFile: {
79
- readonly w: 384;
78
+ readonly "triangle-exclamation": {
79
+ readonly w: 512;
80
80
  readonly h: 512;
81
81
  };
82
82
  readonly user: {
83
83
  readonly w: 448;
84
84
  readonly h: 512;
85
85
  };
86
+ readonly videoFile: {
87
+ readonly w: 384;
88
+ readonly h: 512;
89
+ };
90
+ readonly xmark: {
91
+ readonly w: 384;
92
+ readonly h: 512;
93
+ };
86
94
  readonly xmarkLarge: {
87
95
  readonly w: 448;
88
96
  readonly h: 512;
@@ -110,8 +118,10 @@ declare module "@uxf/ui/icon/theme" {
110
118
  "ellipsis-vertical": true;
111
119
  "file": true;
112
120
  "imageFile": true;
113
- "videoFile": true;
121
+ "triangle-exclamation": true;
114
122
  "user": true;
123
+ "videoFile": true;
124
+ "xmark": true;
115
125
  "xmarkLarge": true;
116
126
  }
117
127
  }
package/config/icons.js CHANGED
@@ -22,7 +22,9 @@ exports.ICONS = {
22
22
  "ellipsis-vertical": { w: 128, h: 512 },
23
23
  "file": { w: 384, h: 512 },
24
24
  "imageFile": { w: 384, h: 512 },
25
- "videoFile": { w: 384, h: 512 },
25
+ "triangle-exclamation": { w: 512, h: 512 },
26
26
  "user": { w: 448, h: 512 },
27
+ "videoFile": { w: 384, h: 512 },
28
+ "xmark": { w: 384, h: 512 },
27
29
  "xmarkLarge": { w: 448, h: 512 },
28
30
  };
@@ -0,0 +1,100 @@
1
+ .uxf-alert-bubble {
2
+ --bg-color: unset;
3
+ --icon-color: unset;
4
+ --icon-size: unset;
5
+ --size: unset;
6
+
7
+ align-items: center;
8
+ background-color: var(--bg-color);
9
+ border-radius: 999px;
10
+ display: flex;
11
+ flex-shrink: 0;
12
+ height: var(--size);
13
+ justify-content: center;
14
+ width: var(--size);
15
+
16
+ &__icon {
17
+ color: var(--icon-color);
18
+ flex-shrink: 0;
19
+ height: var(--icon-size);
20
+ width: var(--icon-size);
21
+ }
22
+
23
+ &--color-default {
24
+ :root .light & {
25
+ --bg-color: theme("backgroundColor.primary.100");
26
+ --icon-color: theme("colors.primary.600");
27
+ }
28
+
29
+ :root .dark & {
30
+ --bg-color: theme("backgroundColor.primary.600");
31
+ --icon-color: theme("colors.primary.100");
32
+ }
33
+ }
34
+
35
+ &--color-warning {
36
+ :root .light & {
37
+ --bg-color: theme("backgroundColor.warning.100");
38
+ --icon-color: theme("colors.warning.600");
39
+ }
40
+
41
+ :root .dark & {
42
+ --bg-color: theme("backgroundColor.warning.600");
43
+ --icon-color: theme("colors.warning.100");
44
+ }
45
+ }
46
+
47
+ &--color-success {
48
+ :root .light & {
49
+ --bg-color: theme("backgroundColor.success.100");
50
+ --icon-color: theme("colors.success.600");
51
+ }
52
+
53
+ :root .dark & {
54
+ --bg-color: theme("backgroundColor.success.600");
55
+ --icon-color: theme("colors.success.100");
56
+ }
57
+ }
58
+
59
+ &--color-error {
60
+ :root .light & {
61
+ --bg-color: theme("backgroundColor.error.100");
62
+ --icon-color: theme("colors.error.600");
63
+ }
64
+
65
+ :root .dark & {
66
+ --bg-color: theme("backgroundColor.error.600");
67
+ --icon-color: theme("colors.error.100");
68
+ }
69
+ }
70
+
71
+ &--size-xs {
72
+ --size: theme("alertBubbleSize.xs");
73
+ --icon-size: 20px;
74
+ }
75
+
76
+ &--size-sm {
77
+ --size: theme("alertBubbleSize.sm");
78
+ --icon-size: 24px;
79
+ }
80
+
81
+ &--size-default {
82
+ --size: theme("alertBubbleSize.default");
83
+ --icon-size: 24px;
84
+ }
85
+
86
+ &--size-lg {
87
+ --size: theme("alertBubbleSize.lg");
88
+ --icon-size: 30px;
89
+ }
90
+
91
+ &--size-xl {
92
+ --size: theme("alertBubbleSize.xl");
93
+ --icon-size: 30px;
94
+ }
95
+
96
+ &--size-2xl {
97
+ --size: theme("alertBubbleSize.2xl");
98
+ --icon-size: 40px;
99
+ }
100
+ }
@@ -1,82 +1,116 @@
1
1
  .uxf-avatar-file-input {
2
+ align-items: center;
3
+ display: flex;
4
+ gap: theme("spacing.4");
5
+
2
6
  &__input {
3
- @apply hidden;
7
+ display: none;
8
+ }
9
+
10
+ &--variant-default {
11
+ .uxf-avatar-file-input__label {
12
+ border-radius: theme("borderRadius.full");
13
+ }
4
14
  }
5
15
 
6
16
  &__label {
7
- @apply cursor-pointer h-20 w-20 rounded-full flex items-center justify-center border-2 border-dashed
8
- transition-all duration-75 ease-in-out;
17
+ @apply transition-all duration-75;
18
+
19
+ align-items: center;
20
+ border-style: dashed;
21
+ border-width: theme("borderWidth.2");
22
+ cursor: pointer;
23
+ display: flex;
24
+ height: theme("height.20");
25
+ justify-content: center;
26
+ width: theme("width.20");
9
27
 
10
28
  :root .light & {
11
- @apply border-lightLow;
29
+ border-color: theme("colors.lightBorder");
12
30
  }
13
31
 
14
32
  :root .dark & {
15
- @apply border-lightBorder;
33
+ border-color: theme("colors.darkBorder");
16
34
  }
17
35
 
18
- &__icon {
36
+ &-wrapper {
37
+ align-items: center;
38
+ display: flex;
39
+ gap: theme("spacing.4");
40
+ }
41
+
42
+ &-icon {
19
43
  :root .light & {
20
- @apply text-lightLow;
44
+ color: theme("colors.lightLow");
21
45
  }
22
46
 
23
47
  :root .dark & {
24
- @apply text-lightBorder;
48
+ color: theme("colors.lightBorder");
25
49
  }
26
50
 
27
51
  &.is-invalid {
28
52
  :root .light & {
29
- @apply text-error;
53
+ color: theme("colors.error.DEFAULT");
30
54
  }
31
55
 
32
56
  :root .dark & {
33
- @apply text-error;
57
+ color: theme("colors.error.DEFAULT");
34
58
  }
35
59
  }
36
60
  }
37
61
 
38
62
  &:hover {
39
- @apply border-4;
63
+ border-width: theme("borderWidth.4");
40
64
  }
41
65
 
42
66
  &.is-invalid {
43
67
  :root .light & {
44
- @apply border-error;
68
+ border-color: theme("colors.error.DEFAULT");
45
69
  }
46
70
 
47
71
  :root .dark & {
48
- @apply border-error;
72
+ border-color: theme("colors.error.DEFAULT");
49
73
  }
50
74
  }
51
75
 
52
76
  &.is-disabled {
53
- @apply cursor-not-allowed bg-lightLow/20;
77
+ background-color: theme("colors.lightLow/.20");
78
+ cursor: not-allowed;
54
79
 
55
80
  &:hover {
56
- @apply border-2;
81
+ border-width: theme("borderWidth.2");
57
82
  }
58
83
  }
59
84
  }
60
85
 
61
86
  &__label-text {
62
- @apply text-sm text-center;
87
+ @apply text-sm shadow-sm;
88
+
89
+ border: theme("borderWidth.DEFAULT") solid theme("colors.gray.300");
90
+ padding: theme("spacing[1.5]") theme("spacing.3");
91
+ text-align: center;
63
92
 
64
93
  :root .light & {
65
- @apply text-lightLow;
94
+ color: theme("colors.lightHigh");
66
95
  }
67
96
 
68
97
  :root .dark & {
69
- @apply text-lightBorder;
98
+ color: theme("colors.lightBorder");
70
99
  }
71
100
 
72
101
  &.is-invalid {
73
102
  :root .light & {
74
- @apply text-error;
103
+ color: theme("colors.error.DEFAULT");
75
104
  }
76
105
 
77
106
  :root .dark & {
78
- @apply text-error;
107
+ color: theme("colors.error.DEFAULT");
79
108
  }
80
109
  }
81
110
  }
111
+
112
+ &__image {
113
+ height: theme("height.20");
114
+ width: theme("width.20");
115
+ }
82
116
  }
package/css/avatar.css CHANGED
@@ -1,15 +1,15 @@
1
1
  .uxf-avatar {
2
- @apply relative inline-flex items-center justify-center h-10 w-10 rounded-full;
2
+ @apply relative inline-flex h-10 w-10 items-center justify-center rounded-full;
3
3
 
4
4
  &__image {
5
5
  @apply absolute left-0 top-0 block h-full w-full rounded-inherit object-cover;
6
6
  }
7
7
 
8
8
  :root .light & {
9
- @apply text-gray-700 bg-gray-200;
9
+ @apply bg-gray-200 text-gray-700;
10
10
  }
11
11
 
12
12
  :root .dark & {
13
- @apply text-gray-200 bg-gray-800;
13
+ @apply bg-gray-800 text-gray-200;
14
14
  }
15
15
  }
package/css/badge.css CHANGED
@@ -2,22 +2,22 @@
2
2
  @apply inline-flex items-center justify-center font-bold;
3
3
 
4
4
  &--size-small {
5
- @apply h-6 min-w-[24px] text-sm rounded-[12px] px-1.5;
5
+ @apply h-6 min-w-[24px] rounded-[12px] px-1.5 text-sm;
6
6
  }
7
7
 
8
8
  &--size-medium {
9
- @apply h-8 min-w-[32px] text-base rounded-[16px] px-2;
9
+ @apply h-8 min-w-[32px] rounded-[16px] px-2 text-base;
10
10
  }
11
11
 
12
12
  &--size-large {
13
- @apply h-10 min-w-[40px] text-lg rounded-[20px] px-2;
13
+ @apply h-10 min-w-[40px] rounded-[20px] px-2 text-lg;
14
14
  }
15
15
 
16
16
  :root .light & {
17
- @apply text-white bg-primary;
17
+ @apply bg-primary text-white;
18
18
  }
19
19
 
20
20
  :root .dark & {
21
- @apply text-gray-900 bg-white;
21
+ @apply bg-white text-gray-900;
22
22
  }
23
23
  }
@@ -1,6 +1,6 @@
1
1
  .uxf-button-group {
2
- display: flex;
3
2
  align-items: center;
3
+ display: flex;
4
4
 
5
5
  .uxf-button {
6
6
  &:focus {
@@ -6,7 +6,7 @@
6
6
  }
7
7
 
8
8
  &__menu-items {
9
- @apply absolute right-0 mt-2 w-40 divide-y rounded-md shadow-lg ring-1 focus:outline-none z-dropdown;
9
+ @apply absolute right-0 z-dropdown mt-2 w-40 divide-y rounded-md shadow-lg ring-1 focus:outline-none;
10
10
 
11
11
  :root .light & {
12
12
  @apply divide-gray-100 bg-white ring-black/5;
@@ -26,7 +26,7 @@
26
26
  }
27
27
 
28
28
  &__menu-button {
29
- @apply flex px-3 py-2 space-x-3 text-sm is-hoverable:hover:cursor-pointer;
29
+ @apply flex space-x-3 px-3 py-2 text-sm is-hoverable:hover:cursor-pointer;
30
30
 
31
31
  :root .light & {
32
32
  @apply text-black hover:text-gray-800;
package/css/button.css CHANGED
@@ -17,7 +17,7 @@
17
17
  }
18
18
 
19
19
  &--full-width {
20
- @apply w-full flex flex-row justify-center;
20
+ @apply flex w-full flex-row justify-center;
21
21
  }
22
22
 
23
23
  &.is-disabled {
@@ -54,9 +54,9 @@
54
54
  }
55
55
 
56
56
  &--size-xs {
57
- height: theme("inputSize.xs");
57
+ @apply rounded px-2.5 text-xs;
58
58
 
59
- @apply px-2.5 text-xs rounded;
59
+ height: theme("inputSize.xs");
60
60
 
61
61
  &.is-loading::after {
62
62
  height: 14px;
@@ -64,9 +64,9 @@
64
64
  }
65
65
 
66
66
  &.uxf-button--icon-button {
67
- width: theme("inputSize.xs");
68
-
69
67
  @apply p-0;
68
+
69
+ width: theme("inputSize.xs");
70
70
  }
71
71
 
72
72
  .uxf-icon {
@@ -75,19 +75,19 @@
75
75
  }
76
76
 
77
77
  &--size-sm {
78
- height: theme("inputSize.sm");
79
-
80
78
  @apply px-3 text-sm leading-4;
81
79
 
80
+ height: theme("inputSize.sm");
81
+
82
82
  &.is-loading::after {
83
83
  height: 16px;
84
84
  width: 16px;
85
85
  }
86
86
 
87
87
  &.uxf-button--icon-button {
88
- width: theme("inputSize.sm");
89
-
90
88
  @apply p-0;
89
+
90
+ width: theme("inputSize.sm");
91
91
  }
92
92
 
93
93
  .uxf-icon {
@@ -96,10 +96,10 @@
96
96
  }
97
97
 
98
98
  &--size-default {
99
- height: theme("inputSize.default");
100
-
101
99
  @apply px-4 text-sm;
102
100
 
101
+ height: theme("inputSize.default");
102
+
103
103
  &.uxf-button--icon-button {
104
104
  width: theme("inputSize.default");
105
105
 
@@ -108,10 +108,10 @@
108
108
  }
109
109
 
110
110
  &--size-lg {
111
- height: theme("inputSize.lg");
112
-
113
111
  @apply px-4 text-base;
114
112
 
113
+ height: theme("inputSize.lg");
114
+
115
115
  &.uxf-button--icon-button {
116
116
  width: theme("inputSize.lg");
117
117
 
@@ -120,14 +120,14 @@
120
120
  }
121
121
 
122
122
  &--size-xl {
123
- height: theme("inputSize.xl");
124
-
125
123
  @apply px-6 text-base;
126
124
 
127
- &.uxf-button--icon-button {
128
- width: theme("inputSize.xl");
125
+ height: theme("inputSize.xl");
129
126
 
127
+ &.uxf-button--icon-button {
130
128
  @apply p-0;
129
+
130
+ width: theme("inputSize.xl");
131
131
  }
132
132
  }
133
133
 
@@ -146,11 +146,11 @@
146
146
  @apply focus-visible:ring-primary;
147
147
 
148
148
  :root .light & {
149
- @apply text-primary border-primary is-hoverable:border-primary-700 is-hoverable:text-primary-700;
149
+ @apply border-primary text-primary is-hoverable:border-primary-700 is-hoverable:text-primary-700;
150
150
  }
151
151
 
152
152
  :root .dark & {
153
- @apply text-primary border-primary is-hoverable:border-primary-300 is-hoverable:text-primary-300;
153
+ @apply border-primary text-primary is-hoverable:border-primary-300 is-hoverable:text-primary-300;
154
154
  }
155
155
  }
156
156
 
@@ -158,11 +158,23 @@
158
158
  @apply focus-visible:ring-success;
159
159
 
160
160
  :root .light & {
161
- @apply text-success border-success is-hoverable:border-success-700 is-hoverable:text-success-700;
161
+ @apply border-success text-success is-hoverable:border-success-700 is-hoverable:text-success-700;
162
+ }
163
+
164
+ :root .dark & {
165
+ @apply border-success text-success is-hoverable:border-success-300 is-hoverable:text-success-300;
166
+ }
167
+ }
168
+
169
+ &.uxf-button--color-warning {
170
+ @apply focus-visible:ring-warning;
171
+
172
+ :root .light & {
173
+ @apply border-warning text-warning is-hoverable:border-warning-700 is-hoverable:text-warning-700;
162
174
  }
163
175
 
164
176
  :root .dark & {
165
- @apply text-success border-success is-hoverable:border-success-300 is-hoverable:text-success-300;
177
+ @apply border-warning text-warning is-hoverable:border-warning-300 is-hoverable:text-warning-300;
166
178
  }
167
179
  }
168
180
 
@@ -170,11 +182,11 @@
170
182
  @apply focus-visible:ring-error;
171
183
 
172
184
  :root .light & {
173
- @apply text-error border-error is-hoverable:border-error-700 is-hoverable:text-error-700;
185
+ @apply border-error text-error is-hoverable:border-error-700 is-hoverable:text-error-700;
174
186
  }
175
187
 
176
188
  :root .dark & {
177
- @apply text-error border-error is-hoverable:border-error-300 is-hoverable:text-error-300;
189
+ @apply border-error text-error is-hoverable:border-error-300 is-hoverable:text-error-300;
178
190
  }
179
191
  }
180
192
 
@@ -261,17 +273,39 @@
261
273
  }
262
274
  }
263
275
  }
276
+
277
+ &.uxf-button--color-warning {
278
+ @apply focus-visible:ring-warning;
279
+
280
+ :root .light & {
281
+ @apply bg-warning is-hoverable:bg-warning-700;
282
+ }
283
+
284
+ :root .dark & {
285
+ @apply bg-warning is-hoverable:bg-warning-400;
286
+ }
287
+
288
+ &.is-disabled {
289
+ :root .light & {
290
+ @apply bg-gray-300 text-lightLow;
291
+ }
292
+
293
+ :root .dark & {
294
+ @apply bg-gray-600 text-gray-400;
295
+ }
296
+ }
297
+ }
264
298
  }
265
299
 
266
300
  &--variant-white {
267
301
  @apply border focus-visible:ring-primary;
268
302
 
269
303
  :root .light & {
270
- @apply border-lightBorder bg-white is-hoverable:bg-gray-100 text-lightMedium;
304
+ @apply border-lightBorder bg-white text-lightMedium is-hoverable:bg-gray-100;
271
305
  }
272
306
 
273
307
  :root .dark & {
274
- @apply border-darkBorder text-darkMedium bg-lightHigh is-hoverable:bg-gray-800 is-hoverable:text-darkHigh;
308
+ @apply border-darkBorder bg-lightHigh text-darkMedium is-hoverable:bg-gray-800 is-hoverable:text-darkHigh;
275
309
  }
276
310
 
277
311
  &.is-disabled {
@@ -280,7 +314,7 @@
280
314
  }
281
315
 
282
316
  :root .dark & {
283
- @apply text-darkLow border-darkBorder;
317
+ @apply border-darkBorder text-darkLow;
284
318
  }
285
319
  }
286
320
  }
@@ -322,6 +356,18 @@
322
356
  }
323
357
  }
324
358
 
359
+ &.uxf-button--color-warning {
360
+ @apply text-warning;
361
+
362
+ :root .light & {
363
+ @apply is-hoverable:text-warning-700;
364
+ }
365
+
366
+ :root .dark & {
367
+ @apply is-hoverable:text-warning-300;
368
+ }
369
+ }
370
+
325
371
  &.is-disabled {
326
372
  :root .light & {
327
373
  @apply text-lightLow;