@fy-/fws-vue 0.3.0 → 0.3.1

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 (179) hide show
  1. package/package.json +1 -11
  2. package/presets/Lara/accordion/index.js +0 -86
  3. package/presets/Lara/autocomplete/index.js +0 -284
  4. package/presets/Lara/avatar/index.js +0 -46
  5. package/presets/Lara/badge/index.js +0 -44
  6. package/presets/Lara/badgedirective/index.js +0 -49
  7. package/presets/Lara/blockui/index.js +0 -8
  8. package/presets/Lara/breadcrumb/index.js +0 -64
  9. package/presets/Lara/button/index.js +0 -470
  10. package/presets/Lara/calendar/index.js +0 -683
  11. package/presets/Lara/card/index.js +0 -37
  12. package/presets/Lara/carousel/index.js +0 -152
  13. package/presets/Lara/cascadeselect/index.js +0 -228
  14. package/presets/Lara/checkbox/index.js +0 -106
  15. package/presets/Lara/chip/index.js +0 -45
  16. package/presets/Lara/chips/index.js +0 -118
  17. package/presets/Lara/colorpicker/index.js +0 -129
  18. package/presets/Lara/confirmpopup/index.js +0 -107
  19. package/presets/Lara/contextmenu/index.js +0 -130
  20. package/presets/Lara/datatable/index.js +0 -1289
  21. package/presets/Lara/dataview/index.js +0 -40
  22. package/presets/Lara/deferred/index.js +0 -3
  23. package/presets/Lara/dialog/index.js +0 -249
  24. package/presets/Lara/divider/index.js +0 -72
  25. package/presets/Lara/dock/index.js +0 -97
  26. package/presets/Lara/dropdown/index.js +0 -300
  27. package/presets/Lara/fieldset/index.js +0 -98
  28. package/presets/Lara/fileupload/index.js +0 -173
  29. package/presets/Lara/floatlabel/index.js +0 -26
  30. package/presets/Lara/galleria/index.js +0 -351
  31. package/presets/Lara/global.js +0 -90
  32. package/presets/Lara/iconfield/index.js +0 -22
  33. package/presets/Lara/image/index.js +0 -206
  34. package/presets/Lara/index.js +0 -181
  35. package/presets/Lara/inlinemessage/index.js +0 -36
  36. package/presets/Lara/inplace/index.js +0 -27
  37. package/presets/Lara/inputgroup/index.js +0 -5
  38. package/presets/Lara/inputgroupaddon/index.js +0 -28
  39. package/presets/Lara/inputmask/index.js +0 -37
  40. package/presets/Lara/inputnumber/index.js +0 -253
  41. package/presets/Lara/inputotp/index.js +0 -72
  42. package/presets/Lara/inputswitch/index.js +0 -93
  43. package/presets/Lara/inputtext/index.js +0 -61
  44. package/presets/Lara/knob/index.js +0 -47
  45. package/presets/Lara/listbox/index.js +0 -170
  46. package/presets/Lara/megamenu/index.js +0 -207
  47. package/presets/Lara/menu/index.js +0 -98
  48. package/presets/Lara/menubar/index.js +0 -181
  49. package/presets/Lara/message/index.js +0 -87
  50. package/presets/Lara/metergroup/index.js +0 -110
  51. package/presets/Lara/multiselect/index.js +0 -589
  52. package/presets/Lara/orderlist/index.js +0 -266
  53. package/presets/Lara/organizationchart/index.js +0 -142
  54. package/presets/Lara/overlaypanel/index.js +0 -41
  55. package/presets/Lara/paginator/index.js +0 -590
  56. package/presets/Lara/panel/index.js +0 -93
  57. package/presets/Lara/panelmenu/index.js +0 -139
  58. package/presets/Lara/password/index.js +0 -140
  59. package/presets/Lara/picklist/index.js +0 -659
  60. package/presets/Lara/progressbar/index.js +0 -61
  61. package/presets/Lara/progressspinner/index.js +0 -51
  62. package/presets/Lara/radiobutton/index.js +0 -116
  63. package/presets/Lara/rating/index.js +0 -95
  64. package/presets/Lara/ripple/index.js +0 -6
  65. package/presets/Lara/scrollpanel/index.js +0 -77
  66. package/presets/Lara/scrolltop/index.js +0 -45
  67. package/presets/Lara/selectbutton/index.js +0 -60
  68. package/presets/Lara/sidebar/index.js +0 -163
  69. package/presets/Lara/skeleton/index.js +0 -19
  70. package/presets/Lara/slider/index.js +0 -149
  71. package/presets/Lara/speeddial/index.js +0 -535
  72. package/presets/Lara/splitbutton/index.js +0 -1081
  73. package/presets/Lara/splitter/index.js +0 -64
  74. package/presets/Lara/stepper/index.js +0 -183
  75. package/presets/Lara/steps/index.js +0 -115
  76. package/presets/Lara/tabmenu/index.js +0 -82
  77. package/presets/Lara/tabview/index.js +0 -166
  78. package/presets/Lara/tag/index.js +0 -37
  79. package/presets/Lara/terminal/index.js +0 -60
  80. package/presets/Lara/textarea/index.js +0 -39
  81. package/presets/Lara/tieredmenu/index.js +0 -125
  82. package/presets/Lara/timeline/index.js +0 -107
  83. package/presets/Lara/toast/index.js +0 -113
  84. package/presets/Lara/togglebutton/index.js +0 -100
  85. package/presets/Lara/toolbar/index.js +0 -28
  86. package/presets/Lara/tooltip/index.js +0 -73
  87. package/presets/Lara/tree/index.js +0 -281
  88. package/presets/Lara/treeselect/index.js +0 -387
  89. package/presets/Lara/treetable/index.js +0 -509
  90. package/presets/Lara/tristatecheckbox/index.js +0 -112
  91. package/presets/Wind/accordion/index.js +0 -75
  92. package/presets/Wind/autocomplete/index.js +0 -294
  93. package/presets/Wind/avatar/index.js +0 -48
  94. package/presets/Wind/badge/index.js +0 -43
  95. package/presets/Wind/badgedirective/index.js +0 -50
  96. package/presets/Wind/blockui/index.js +0 -8
  97. package/presets/Wind/breadcrumb/index.js +0 -45
  98. package/presets/Wind/button/index.js +0 -474
  99. package/presets/Wind/calendar/index.js +0 -659
  100. package/presets/Wind/card/index.js +0 -40
  101. package/presets/Wind/carousel/index.js +0 -152
  102. package/presets/Wind/cascadeselect/index.js +0 -225
  103. package/presets/Wind/checkbox/index.js +0 -112
  104. package/presets/Wind/chip/index.js +0 -45
  105. package/presets/Wind/chips/index.js +0 -120
  106. package/presets/Wind/colorpicker/index.js +0 -129
  107. package/presets/Wind/confirmpopup/index.js +0 -123
  108. package/presets/Wind/contextmenu/index.js +0 -128
  109. package/presets/Wind/datatable/index.js +0 -1330
  110. package/presets/Wind/dataview/index.js +0 -40
  111. package/presets/Wind/deferred/index.js +0 -3
  112. package/presets/Wind/dialog/index.js +0 -251
  113. package/presets/Wind/divider/index.js +0 -72
  114. package/presets/Wind/dock/index.js +0 -97
  115. package/presets/Wind/dropdown/index.js +0 -287
  116. package/presets/Wind/fieldset/index.js +0 -99
  117. package/presets/Wind/fileupload/index.js +0 -173
  118. package/presets/Wind/floatlabel/index.js +0 -26
  119. package/presets/Wind/galleria/index.js +0 -351
  120. package/presets/Wind/global.js +0 -77
  121. package/presets/Wind/iconfield/index.js +0 -22
  122. package/presets/Wind/image/index.js +0 -206
  123. package/presets/Wind/index.js +0 -181
  124. package/presets/Wind/inlinemessage/index.js +0 -29
  125. package/presets/Wind/inplace/index.js +0 -30
  126. package/presets/Wind/inputgroup/index.js +0 -5
  127. package/presets/Wind/inputgroupaddon/index.js +0 -28
  128. package/presets/Wind/inputmask/index.js +0 -34
  129. package/presets/Wind/inputnumber/index.js +0 -244
  130. package/presets/Wind/inputotp/index.js +0 -72
  131. package/presets/Wind/inputswitch/index.js +0 -106
  132. package/presets/Wind/inputtext/index.js +0 -61
  133. package/presets/Wind/knob/index.js +0 -47
  134. package/presets/Wind/listbox/index.js +0 -159
  135. package/presets/Wind/megamenu/index.js +0 -218
  136. package/presets/Wind/menu/index.js +0 -111
  137. package/presets/Wind/menubar/index.js +0 -188
  138. package/presets/Wind/message/index.js +0 -87
  139. package/presets/Wind/metergroup/index.js +0 -110
  140. package/presets/Wind/multiselect/index.js +0 -619
  141. package/presets/Wind/orderlist/index.js +0 -275
  142. package/presets/Wind/organizationchart/index.js +0 -143
  143. package/presets/Wind/overlaypanel/index.js +0 -42
  144. package/presets/Wind/paginator/index.js +0 -596
  145. package/presets/Wind/panel/index.js +0 -95
  146. package/presets/Wind/panelmenu/index.js +0 -136
  147. package/presets/Wind/password/index.js +0 -141
  148. package/presets/Wind/picklist/index.js +0 -684
  149. package/presets/Wind/progressbar/index.js +0 -68
  150. package/presets/Wind/progressspinner/index.js +0 -51
  151. package/presets/Wind/radiobutton/index.js +0 -92
  152. package/presets/Wind/rating/index.js +0 -86
  153. package/presets/Wind/ripple/index.js +0 -6
  154. package/presets/Wind/scrollpanel/index.js +0 -77
  155. package/presets/Wind/scrolltop/index.js +0 -45
  156. package/presets/Wind/selectbutton/index.js +0 -58
  157. package/presets/Wind/sidebar/index.js +0 -165
  158. package/presets/Wind/skeleton/index.js +0 -19
  159. package/presets/Wind/slider/index.js +0 -135
  160. package/presets/Wind/speeddial/index.js +0 -536
  161. package/presets/Wind/splitbutton/index.js +0 -1078
  162. package/presets/Wind/splitter/index.js +0 -64
  163. package/presets/Wind/stepper/index.js +0 -180
  164. package/presets/Wind/steps/index.js +0 -132
  165. package/presets/Wind/tabmenu/index.js +0 -84
  166. package/presets/Wind/tabview/index.js +0 -168
  167. package/presets/Wind/tag/index.js +0 -37
  168. package/presets/Wind/terminal/index.js +0 -60
  169. package/presets/Wind/textarea/index.js +0 -40
  170. package/presets/Wind/tieredmenu/index.js +0 -121
  171. package/presets/Wind/timeline/index.js +0 -107
  172. package/presets/Wind/toast/index.js +0 -111
  173. package/presets/Wind/togglebutton/index.js +0 -91
  174. package/presets/Wind/toolbar/index.js +0 -30
  175. package/presets/Wind/tooltip/index.js +0 -43
  176. package/presets/Wind/tree/index.js +0 -300
  177. package/presets/Wind/treeselect/index.js +0 -404
  178. package/presets/Wind/treetable/index.js +0 -505
  179. package/presets/Wind/tristatecheckbox/index.js +0 -118
@@ -1,1078 +0,0 @@
1
- export default {
2
- root: ({ props }) => ({
3
- class: [
4
- // Flexbox and Position
5
- "inline-flex",
6
- "relative",
7
-
8
- // Shape
9
- "rounded-md",
10
- { "shadow-lg": props.raised },
11
- ],
12
- }),
13
- button: {
14
- root: ({ parent }) => ({
15
- class: [
16
- "relative",
17
- // Alignments
18
- "items-center inline-flex text-center align-bottom justify-center",
19
-
20
- // Sizes & Spacing
21
- "text-sm",
22
- {
23
- "px-2.5 py-1.5 min-w-[2rem]": parent.props.size === null,
24
- "px-2 py-1": parent.props.size === "small",
25
- "px-3 py-2": parent.props.size === "large",
26
- },
27
- {
28
- "min-w-8 p-0 py-1.5":
29
- parent.props.label == null && parent.props.icon !== null,
30
- },
31
-
32
- // Shape
33
- "rounded-r-none",
34
- "border-r-0",
35
- { "rounded-l-full": parent.props.rounded },
36
- {
37
- "rounded-md": !parent.props.rounded,
38
- "rounded-full": parent.props.rounded,
39
- },
40
-
41
- // Link Button
42
- {
43
- "text-primary-600 bg-transparent ring-transparent": parent.props.link,
44
- },
45
-
46
- // Plain Button
47
- {
48
- "text-white bg-gray-500 ring-1 ring-gray-500":
49
- parent.props.plain && !parent.props.outlined && !parent.props.text,
50
- },
51
- // Plain Text Button
52
- { "text-surface-500": parent.props.plain && parent.props.text },
53
- // Plain Outlined Button
54
- {
55
- "text-surface-500 ring-1 ring-gray-500":
56
- parent.props.plain && parent.props.outlined,
57
- },
58
-
59
- // Text Button
60
- {
61
- "bg-transparent ring-transparent":
62
- parent.props.text && !parent.props.plain,
63
- },
64
-
65
- // Outlined Button
66
- { "bg-transparent": parent.props.outlined && !parent.props.plain },
67
-
68
- // --- Severity Buttons ---
69
-
70
- // Primary Button
71
- {
72
- "text-white dark:text-surface-900":
73
- !parent.props.link &&
74
- parent.props.severity === null &&
75
- !parent.props.text &&
76
- !parent.props.outlined &&
77
- !parent.props.plain,
78
- "bg-primary-500 dark:bg-primary-400":
79
- !parent.props.link &&
80
- parent.props.severity === null &&
81
- !parent.props.text &&
82
- !parent.props.outlined &&
83
- !parent.props.plain,
84
- "ring-1 ring-primary-500 dark:ring-primary-400":
85
- !parent.props.link &&
86
- parent.props.severity === null &&
87
- !parent.props.text &&
88
- !parent.props.outlined &&
89
- !parent.props.plain,
90
- },
91
- // Primary Text Button
92
- {
93
- "text-primary-500 dark:text-primary-400":
94
- parent.props.text &&
95
- parent.props.severity === null &&
96
- !parent.props.plain,
97
- },
98
- // Primary Outlined Button
99
- {
100
- "text-primary-500 ring-1 ring-primary-500 hover:bg-primary-300/20":
101
- parent.props.outlined &&
102
- parent.props.severity === null &&
103
- !parent.props.plain,
104
- },
105
-
106
- // Secondary Button
107
- {
108
- "text-white dark:text-surface-900":
109
- parent.props.severity === "secondary" &&
110
- !parent.props.text &&
111
- !parent.props.outlined &&
112
- !parent.props.plain,
113
- "bg-surface-500 dark:bg-surface-400":
114
- parent.props.severity === "secondary" &&
115
- !parent.props.text &&
116
- !parent.props.outlined &&
117
- !parent.props.plain,
118
- "ring-1 ring-surface-500 dark:ring-surface-400":
119
- parent.props.severity === "secondary" &&
120
- !parent.props.text &&
121
- !parent.props.outlined &&
122
- !parent.props.plain,
123
- },
124
- // Secondary Text Button
125
- {
126
- "text-surface-500 dark:text-surface-400":
127
- parent.props.text &&
128
- parent.props.severity === "secondary" &&
129
- !parent.props.plain,
130
- },
131
- // Secondary Outlined Button
132
- {
133
- "text-surface-500 ring-1 ring-surface-500 hover:bg-surface-300/20":
134
- parent.props.outlined &&
135
- parent.props.severity === "secondary" &&
136
- !parent.props.plain,
137
- },
138
-
139
- // Success Button
140
- {
141
- "text-white dark:text-surface-900":
142
- parent.props.severity === "success" &&
143
- !parent.props.text &&
144
- !parent.props.outlined &&
145
- !parent.props.plain,
146
- "bg-green-500 dark:bg-green-400":
147
- parent.props.severity === "success" &&
148
- !parent.props.text &&
149
- !parent.props.outlined &&
150
- !parent.props.plain,
151
- "ring-1 ring-green-500 dark:ring-green-400":
152
- parent.props.severity === "success" &&
153
- !parent.props.text &&
154
- !parent.props.outlined &&
155
- !parent.props.plain,
156
- },
157
- // Success Text Button
158
- {
159
- "text-surface-500 dark:text-surface-400":
160
- parent.props.text &&
161
- parent.props.severity === "secondary" &&
162
- !parent.props.plain,
163
- },
164
- // Success Outlined Button
165
- {
166
- "text-green-500 ring-1 ring-green-500 hover:bg-green-300/20":
167
- parent.props.outlined &&
168
- parent.props.severity === "success" &&
169
- !parent.props.plain,
170
- },
171
-
172
- // Info Button
173
- {
174
- "text-white dark:text-surface-900":
175
- parent.props.severity === "info" &&
176
- !parent.props.text &&
177
- !parent.props.outlined &&
178
- !parent.props.plain,
179
- "bg-blue-500 dark:bg-blue-400":
180
- parent.props.severity === "info" &&
181
- !parent.props.text &&
182
- !parent.props.outlined &&
183
- !parent.props.plain,
184
- "ring-1 ring-blue-500 dark:ring-blue-400":
185
- parent.props.severity === "info" &&
186
- !parent.props.text &&
187
- !parent.props.outlined &&
188
- !parent.props.plain,
189
- },
190
- // Info Text Button
191
- {
192
- "text-blue-500 dark:text-blue-400":
193
- parent.props.text &&
194
- parent.props.severity === "info" &&
195
- !parent.props.plain,
196
- },
197
- // Info Outlined Button
198
- {
199
- "text-blue-500 ring-1 ring-blue-500 hover:bg-blue-300/20 ":
200
- parent.props.outlined &&
201
- parent.props.severity === "info" &&
202
- !parent.props.plain,
203
- },
204
-
205
- // Warning Button
206
- {
207
- "text-white dark:text-surface-900":
208
- parent.props.severity === "warning" &&
209
- !parent.props.text &&
210
- !parent.props.outlined &&
211
- !parent.props.plain,
212
- "bg-orange-500 dark:bg-orange-400":
213
- parent.props.severity === "warning" &&
214
- !parent.props.text &&
215
- !parent.props.outlined &&
216
- !parent.props.plain,
217
- "ring-1 ring-orange-500 dark:ring-orange-400":
218
- parent.props.severity === "warning" &&
219
- !parent.props.text &&
220
- !parent.props.outlined &&
221
- !parent.props.plain,
222
- },
223
- // Warning Text Button
224
- {
225
- "text-orange-500 dark:text-orange-400":
226
- parent.props.text &&
227
- parent.props.severity === "warning" &&
228
- !parent.props.plain,
229
- },
230
- // Warning Outlined Button
231
- {
232
- "text-orange-500 ring-1 ring-orange-500 hover:bg-orange-300/20":
233
- parent.props.outlined &&
234
- parent.props.severity === "warning" &&
235
- !parent.props.plain,
236
- },
237
-
238
- // Help Button
239
- {
240
- "text-white dark:text-surface-900":
241
- parent.props.severity === "help" &&
242
- !parent.props.text &&
243
- !parent.props.outlined &&
244
- !parent.props.plain,
245
- "bg-purple-500 dark:bg-purple-400":
246
- parent.props.severity === "help" &&
247
- !parent.props.text &&
248
- !parent.props.outlined &&
249
- !parent.props.plain,
250
- "ring-1 ring-purple-500 dark:ring-purple-400":
251
- parent.props.severity === "help" &&
252
- !parent.props.text &&
253
- !parent.props.outlined &&
254
- !parent.props.plain,
255
- },
256
- // Help Text Button
257
- {
258
- "text-purple-500 dark:text-purple-400":
259
- parent.props.text &&
260
- parent.props.severity === "help" &&
261
- !parent.props.plain,
262
- },
263
- // Help Outlined Button
264
- {
265
- "text-purple-500 ring-1 ring-purple-500 hover:bg-purple-300/20":
266
- parent.props.outlined &&
267
- parent.props.severity === "help" &&
268
- !parent.props.plain,
269
- },
270
-
271
- // Danger Button
272
- {
273
- "text-white dark:text-surface-900":
274
- parent.props.severity === "danger" &&
275
- !parent.props.text &&
276
- !parent.props.outlined &&
277
- !parent.props.plain,
278
- "bg-red-500 dark:bg-red-400":
279
- parent.props.severity === "danger" &&
280
- !parent.props.text &&
281
- !parent.props.outlined &&
282
- !parent.props.plain,
283
- "ring-1 ring-red-500 dark:ring-red-400":
284
- parent.props.severity === "danger" &&
285
- !parent.props.text &&
286
- !parent.props.outlined &&
287
- !parent.props.plain,
288
- },
289
- // Danger Text Button
290
- {
291
- "text-red-500 dark:text-red-400":
292
- parent.props.text &&
293
- parent.props.severity === "danger" &&
294
- !parent.props.plain,
295
- },
296
- // Danger Outlined Button
297
- {
298
- "text-red-500 ring-1 ring-red-500 hover:bg-red-300/20":
299
- parent.props.outlined &&
300
- parent.props.severity === "danger" &&
301
- !parent.props.plain,
302
- },
303
-
304
- // --- Severity Button States ---
305
- "focus:outline-none focus:outline-offset-0 focus:ring-2 focus:ring-offset-current",
306
- {
307
- "focus:ring-offset-2":
308
- !parent.props.link &&
309
- !parent.props.plain &&
310
- !parent.props.outlined &&
311
- !parent.props.text,
312
- },
313
-
314
- // Link
315
- {
316
- "focus:ring-primary-500 dark:focus:ring-primary-400":
317
- parent.props.link,
318
- },
319
-
320
- // Plain
321
- {
322
- "hover:bg-gray-600 hover:ring-gray-600":
323
- parent.props.plain && !parent.props.outlined && !parent.props.text,
324
- },
325
- // Text & Outlined Button
326
- {
327
- "hover:bg-surface-300/20":
328
- parent.props.plain && (parent.props.text || parent.props.outlined),
329
- },
330
-
331
- // Primary
332
- {
333
- "hover:bg-primary-600 dark:hover:bg-primary-300 hover:ring-primary-600 dark:hover:ring-primary-300":
334
- !parent.props.link &&
335
- parent.props.severity === null &&
336
- !parent.props.text &&
337
- !parent.props.outlined &&
338
- !parent.props.plain,
339
- },
340
- {
341
- "focus:ring-primary-500 dark:focus:ring-primary-400":
342
- parent.props.severity === null,
343
- },
344
- // Text & Outlined Button
345
- {
346
- "hover:bg-primary-300/20":
347
- (parent.props.text || parent.props.outlined) &&
348
- parent.props.severity === null &&
349
- !parent.props.plain,
350
- },
351
-
352
- // Secondary
353
- {
354
- "hover:bg-surface-600 dark:hover:bg-surface-300 hover:ring-surface-600 dark:hover:ring-surface-300":
355
- parent.props.severity === "secondary" &&
356
- !parent.props.text &&
357
- !parent.props.outlined &&
358
- !parent.props.plain,
359
- },
360
- {
361
- "focus:ring-surface-500 dark:focus:ring-surface-400":
362
- parent.props.severity === "secondary",
363
- },
364
- // Text & Outlined Button
365
- {
366
- "hover:bg-surface-300/20":
367
- (parent.props.text || parent.props.outlined) &&
368
- parent.props.severity === "secondary" &&
369
- !parent.props.plain,
370
- },
371
-
372
- // Success
373
- {
374
- "hover:bg-green-600 dark:hover:bg-green-300 hover:ring-green-600 dark:hover:ring-green-300":
375
- parent.props.severity === "success" &&
376
- !parent.props.text &&
377
- !parent.props.outlined &&
378
- !parent.props.plain,
379
- },
380
- {
381
- "focus:ring-green-500 dark:focus:ring-green-400":
382
- parent.props.severity === "success",
383
- },
384
- // Text & Outlined Button
385
- {
386
- "hover:bg-green-300/20":
387
- (parent.props.text || parent.props.outlined) &&
388
- parent.props.severity === "success" &&
389
- !parent.props.plain,
390
- },
391
-
392
- // Info
393
- {
394
- "hover:bg-blue-600 dark:hover:bg-blue-300 hover:ring-blue-600 dark:hover:ring-blue-300":
395
- parent.props.severity === "info" &&
396
- !parent.props.text &&
397
- !parent.props.outlined &&
398
- !parent.props.plain,
399
- },
400
- {
401
- "focus:ring-blue-500 dark:focus:ring-blue-400":
402
- parent.props.severity === "info",
403
- },
404
- // Text & Outlined Button
405
- {
406
- "hover:bg-blue-300/20":
407
- (parent.props.text || parent.props.outlined) &&
408
- parent.props.severity === "info" &&
409
- !parent.props.plain,
410
- },
411
-
412
- // Warning
413
- {
414
- "hover:bg-orange-600 dark:hover:bg-orange-300 hover:ring-orange-600 dark:hover:ring-orange-300":
415
- parent.props.severity === "warning" &&
416
- !parent.props.text &&
417
- !parent.props.outlined &&
418
- !parent.props.plain,
419
- },
420
- {
421
- "focus:ring-orange-500 dark:focus:ring-orange-400":
422
- parent.props.severity === "warning",
423
- },
424
- // Text & Outlined Button
425
- {
426
- "hover:bg-orange-300/20":
427
- (parent.props.text || parent.props.outlined) &&
428
- parent.props.severity === "warning" &&
429
- !parent.props.plain,
430
- },
431
-
432
- // Help
433
- {
434
- "hover:bg-purple-600 dark:hover:bg-purple-300 hover:ring-purple-600 dark:hover:ring-purple-300":
435
- parent.props.severity === "help" &&
436
- !parent.props.text &&
437
- !parent.props.outlined &&
438
- !parent.props.plain,
439
- },
440
- {
441
- "focus:ring-purple-500 dark:focus:ring-purple-400":
442
- parent.props.severity === "help",
443
- },
444
- // Text & Outlined Button
445
- {
446
- "hover:bg-purple-300/20":
447
- (parent.props.text || parent.props.outlined) &&
448
- parent.props.severity === "help" &&
449
- !parent.props.plain,
450
- },
451
-
452
- // Warning
453
- {
454
- "hover:bg-red-600 dark:hover:bg-red-300 hover:ring-red-600 dark:hover:ring-red-300":
455
- parent.props.severity === "danger" &&
456
- !parent.props.text &&
457
- !parent.props.outlined &&
458
- !parent.props.plain,
459
- },
460
- {
461
- "focus:ring-red-500 dark:focus:ring-red-400":
462
- parent.props.severity === "danger",
463
- },
464
- // Text & Outlined Button
465
- {
466
- "hover:bg-red-300/20":
467
- (parent.props.text || parent.props.outlined) &&
468
- parent.props.severity === "danger" &&
469
- !parent.props.plain,
470
- },
471
-
472
- // Transitions
473
- "transition duration-200 ease-in-out",
474
-
475
- // Misc
476
- "cursor-pointer overflow-hidden select-none",
477
- ],
478
- }),
479
- icon: {
480
- class: [
481
- // Margins
482
- "mr-2",
483
- ],
484
- },
485
- },
486
- menubutton: {
487
- root: ({ parent }) => ({
488
- class: [
489
- "relative",
490
-
491
- // Alignments
492
- "items-center inline-flex text-center align-bottom justify-center",
493
-
494
- // Sizes & Spacing
495
- "text-sm",
496
- {
497
- "px-2.5 py-1.5 min-w-[2rem]": parent.props.size === null,
498
- "px-2 py-1": parent.props.size === "small",
499
- "px-3 py-2": parent.props.size === "large",
500
- },
501
- {
502
- "min-w-8 p-0 py-1.5":
503
- parent.props.label == null && parent.props.icon !== null,
504
- },
505
- "ml-px",
506
-
507
- // Shape
508
- "rounded-l-none",
509
- { "rounded-l-full": parent.props.rounded },
510
- {
511
- "rounded-md": !parent.props.rounded,
512
- "rounded-full": parent.props.rounded,
513
- },
514
-
515
- // Link Button
516
- {
517
- "text-primary-600 bg-transparent ring-transparent": parent.props.link,
518
- },
519
-
520
- // Plain Button
521
- {
522
- "text-white bg-gray-500 ring-1 ring-gray-500":
523
- parent.props.plain && !parent.props.outlined && !parent.props.text,
524
- },
525
- // Plain Text Button
526
- { "text-surface-500": parent.props.plain && parent.props.text },
527
- // Plain Outlined Button
528
- {
529
- "text-surface-500 ring-1 ring-gray-500":
530
- parent.props.plain && parent.props.outlined,
531
- },
532
-
533
- // Text Button
534
- {
535
- "bg-transparent ring-transparent":
536
- parent.props.text && !parent.props.plain,
537
- },
538
-
539
- // Outlined Button
540
- { "bg-transparent": parent.props.outlined && !parent.props.plain },
541
-
542
- // --- Severity Buttons ---
543
-
544
- // Primary Button
545
- {
546
- "text-white dark:text-surface-900":
547
- !parent.props.link &&
548
- parent.props.severity === null &&
549
- !parent.props.text &&
550
- !parent.props.outlined &&
551
- !parent.props.plain,
552
- "bg-primary-500 dark:bg-primary-400":
553
- !parent.props.link &&
554
- parent.props.severity === null &&
555
- !parent.props.text &&
556
- !parent.props.outlined &&
557
- !parent.props.plain,
558
- "ring-1 ring-primary-500 dark:ring-primary-400":
559
- !parent.props.link &&
560
- parent.props.severity === null &&
561
- !parent.props.text &&
562
- !parent.props.outlined &&
563
- !parent.props.plain,
564
- },
565
- // Primary Text Button
566
- {
567
- "text-primary-500 dark:text-primary-400":
568
- parent.props.text &&
569
- parent.props.severity === null &&
570
- !parent.props.plain,
571
- },
572
- // Primary Outlined Button
573
- {
574
- "text-primary-500 ring-1 ring-primary-500 hover:bg-primary-300/20":
575
- parent.props.outlined &&
576
- parent.props.severity === null &&
577
- !parent.props.plain,
578
- },
579
-
580
- // Secondary Button
581
- {
582
- "text-white dark:text-surface-900":
583
- parent.props.severity === "secondary" &&
584
- !parent.props.text &&
585
- !parent.props.outlined &&
586
- !parent.props.plain,
587
- "bg-surface-500 dark:bg-surface-400":
588
- parent.props.severity === "secondary" &&
589
- !parent.props.text &&
590
- !parent.props.outlined &&
591
- !parent.props.plain,
592
- "ring-1 ring-surface-500 dark:ring-surface-400":
593
- parent.props.severity === "secondary" &&
594
- !parent.props.text &&
595
- !parent.props.outlined &&
596
- !parent.props.plain,
597
- },
598
- // Secondary Text Button
599
- {
600
- "text-surface-500 dark:text-surface-400":
601
- parent.props.text &&
602
- parent.props.severity === "secondary" &&
603
- !parent.props.plain,
604
- },
605
- // Secondary Outlined Button
606
- {
607
- "text-surface-500 ring-1 ring-surface-500 hover:bg-surface-300/20":
608
- parent.props.outlined &&
609
- parent.props.severity === "secondary" &&
610
- !parent.props.plain,
611
- },
612
-
613
- // Success Button
614
- {
615
- "text-white dark:text-surface-900":
616
- parent.props.severity === "success" &&
617
- !parent.props.text &&
618
- !parent.props.outlined &&
619
- !parent.props.plain,
620
- "bg-green-500 dark:bg-green-400":
621
- parent.props.severity === "success" &&
622
- !parent.props.text &&
623
- !parent.props.outlined &&
624
- !parent.props.plain,
625
- "ring-1 ring-green-500 dark:ring-green-400":
626
- parent.props.severity === "success" &&
627
- !parent.props.text &&
628
- !parent.props.outlined &&
629
- !parent.props.plain,
630
- },
631
- // Success Text Button
632
- {
633
- "text-surface-500 dark:text-surface-400":
634
- parent.props.text &&
635
- parent.props.severity === "secondary" &&
636
- !parent.props.plain,
637
- },
638
- // Success Outlined Button
639
- {
640
- "text-green-500 ring-1 ring-green-500 hover:bg-green-300/20":
641
- parent.props.outlined &&
642
- parent.props.severity === "success" &&
643
- !parent.props.plain,
644
- },
645
-
646
- // Info Button
647
- {
648
- "text-white dark:text-surface-900":
649
- parent.props.severity === "info" &&
650
- !parent.props.text &&
651
- !parent.props.outlined &&
652
- !parent.props.plain,
653
- "bg-blue-500 dark:bg-blue-400":
654
- parent.props.severity === "info" &&
655
- !parent.props.text &&
656
- !parent.props.outlined &&
657
- !parent.props.plain,
658
- "ring-1 ring-blue-500 dark:ring-blue-400":
659
- parent.props.severity === "info" &&
660
- !parent.props.text &&
661
- !parent.props.outlined &&
662
- !parent.props.plain,
663
- },
664
- // Info Text Button
665
- {
666
- "text-blue-500 dark:text-blue-400":
667
- parent.props.text &&
668
- parent.props.severity === "info" &&
669
- !parent.props.plain,
670
- },
671
- // Info Outlined Button
672
- {
673
- "text-blue-500 ring-1 ring-blue-500 hover:bg-blue-300/20 ":
674
- parent.props.outlined &&
675
- parent.props.severity === "info" &&
676
- !parent.props.plain,
677
- },
678
-
679
- // Warning Button
680
- {
681
- "text-white dark:text-surface-900":
682
- parent.props.severity === "warning" &&
683
- !parent.props.text &&
684
- !parent.props.outlined &&
685
- !parent.props.plain,
686
- "bg-orange-500 dark:bg-orange-400":
687
- parent.props.severity === "warning" &&
688
- !parent.props.text &&
689
- !parent.props.outlined &&
690
- !parent.props.plain,
691
- "ring-1 ring-orange-500 dark:ring-orange-400":
692
- parent.props.severity === "warning" &&
693
- !parent.props.text &&
694
- !parent.props.outlined &&
695
- !parent.props.plain,
696
- },
697
- // Warning Text Button
698
- {
699
- "text-orange-500 dark:text-orange-400":
700
- parent.props.text &&
701
- parent.props.severity === "warning" &&
702
- !parent.props.plain,
703
- },
704
- // Warning Outlined Button
705
- {
706
- "text-orange-500 ring-1 ring-orange-500 hover:bg-orange-300/20":
707
- parent.props.outlined &&
708
- parent.props.severity === "warning" &&
709
- !parent.props.plain,
710
- },
711
-
712
- // Help Button
713
- {
714
- "text-white dark:text-surface-900":
715
- parent.props.severity === "help" &&
716
- !parent.props.text &&
717
- !parent.props.outlined &&
718
- !parent.props.plain,
719
- "bg-purple-500 dark:bg-purple-400":
720
- parent.props.severity === "help" &&
721
- !parent.props.text &&
722
- !parent.props.outlined &&
723
- !parent.props.plain,
724
- "ring-1 ring-purple-500 dark:ring-purple-400":
725
- parent.props.severity === "help" &&
726
- !parent.props.text &&
727
- !parent.props.outlined &&
728
- !parent.props.plain,
729
- },
730
- // Help Text Button
731
- {
732
- "text-purple-500 dark:text-purple-400":
733
- parent.props.text &&
734
- parent.props.severity === "help" &&
735
- !parent.props.plain,
736
- },
737
- // Help Outlined Button
738
- {
739
- "text-purple-500 ring-1 ring-purple-500 hover:bg-purple-300/20":
740
- parent.props.outlined &&
741
- parent.props.severity === "help" &&
742
- !parent.props.plain,
743
- },
744
-
745
- // Danger Button
746
- {
747
- "text-white dark:text-surface-900":
748
- parent.props.severity === "danger" &&
749
- !parent.props.text &&
750
- !parent.props.outlined &&
751
- !parent.props.plain,
752
- "bg-red-500 dark:bg-red-400":
753
- parent.props.severity === "danger" &&
754
- !parent.props.text &&
755
- !parent.props.outlined &&
756
- !parent.props.plain,
757
- "ring-1 ring-red-500 dark:ring-red-400":
758
- parent.props.severity === "danger" &&
759
- !parent.props.text &&
760
- !parent.props.outlined &&
761
- !parent.props.plain,
762
- },
763
- // Danger Text Button
764
- {
765
- "text-red-500 dark:text-red-400":
766
- parent.props.text &&
767
- parent.props.severity === "danger" &&
768
- !parent.props.plain,
769
- },
770
- // Danger Outlined Button
771
- {
772
- "text-red-500 ring-1 ring-red-500 hover:bg-red-300/20":
773
- parent.props.outlined &&
774
- parent.props.severity === "danger" &&
775
- !parent.props.plain,
776
- },
777
-
778
- // --- Severity Button States ---
779
- "focus:outline-none focus:outline-offset-0 focus:ring-2 focus:ring-offset-current",
780
- {
781
- "focus:ring-offset-2":
782
- !parent.props.link &&
783
- !parent.props.plain &&
784
- !parent.props.outlined &&
785
- !parent.props.text,
786
- },
787
-
788
- // Link
789
- {
790
- "focus:ring-primary-500 dark:focus:ring-primary-400":
791
- parent.props.link,
792
- },
793
-
794
- // Plain
795
- {
796
- "hover:bg-gray-600 hover:ring-gray-600":
797
- parent.props.plain && !parent.props.outlined && !parent.props.text,
798
- },
799
- // Text & Outlined Button
800
- {
801
- "hover:bg-surface-300/20":
802
- parent.props.plain && (parent.props.text || parent.props.outlined),
803
- },
804
-
805
- // Primary
806
- {
807
- "hover:bg-primary-600 dark:hover:bg-primary-300 hover:ring-primary-600 dark:hover:ring-primary-300":
808
- !parent.props.link &&
809
- parent.props.severity === null &&
810
- !parent.props.text &&
811
- !parent.props.outlined &&
812
- !parent.props.plain,
813
- },
814
- {
815
- "focus:ring-primary-500 dark:focus:ring-primary-400":
816
- parent.props.severity === null,
817
- },
818
- // Text & Outlined Button
819
- {
820
- "hover:bg-primary-300/20":
821
- (parent.props.text || parent.props.outlined) &&
822
- parent.props.severity === null &&
823
- !parent.props.plain,
824
- },
825
-
826
- // Secondary
827
- {
828
- "hover:bg-surface-600 dark:hover:bg-surface-300 hover:ring-surface-600 dark:hover:ring-surface-300":
829
- parent.props.severity === "secondary" &&
830
- !parent.props.text &&
831
- !parent.props.outlined &&
832
- !parent.props.plain,
833
- },
834
- {
835
- "focus:ring-surface-500 dark:focus:ring-surface-400":
836
- parent.props.severity === "secondary",
837
- },
838
- // Text & Outlined Button
839
- {
840
- "hover:bg-surface-300/20":
841
- (parent.props.text || parent.props.outlined) &&
842
- parent.props.severity === "secondary" &&
843
- !parent.props.plain,
844
- },
845
-
846
- // Success
847
- {
848
- "hover:bg-green-600 dark:hover:bg-green-300 hover:ring-green-600 dark:hover:ring-green-300":
849
- parent.props.severity === "success" &&
850
- !parent.props.text &&
851
- !parent.props.outlined &&
852
- !parent.props.plain,
853
- },
854
- {
855
- "focus:ring-green-500 dark:focus:ring-green-400":
856
- parent.props.severity === "success",
857
- },
858
- // Text & Outlined Button
859
- {
860
- "hover:bg-green-300/20":
861
- (parent.props.text || parent.props.outlined) &&
862
- parent.props.severity === "success" &&
863
- !parent.props.plain,
864
- },
865
-
866
- // Info
867
- {
868
- "hover:bg-blue-600 dark:hover:bg-blue-300 hover:ring-blue-600 dark:hover:ring-blue-300":
869
- parent.props.severity === "info" &&
870
- !parent.props.text &&
871
- !parent.props.outlined &&
872
- !parent.props.plain,
873
- },
874
- {
875
- "focus:ring-blue-500 dark:focus:ring-blue-400":
876
- parent.props.severity === "info",
877
- },
878
- // Text & Outlined Button
879
- {
880
- "hover:bg-blue-300/20":
881
- (parent.props.text || parent.props.outlined) &&
882
- parent.props.severity === "info" &&
883
- !parent.props.plain,
884
- },
885
-
886
- // Warning
887
- {
888
- "hover:bg-orange-600 dark:hover:bg-orange-300 hover:ring-orange-600 dark:hover:ring-orange-300":
889
- parent.props.severity === "warning" &&
890
- !parent.props.text &&
891
- !parent.props.outlined &&
892
- !parent.props.plain,
893
- },
894
- {
895
- "focus:ring-orange-500 dark:focus:ring-orange-400":
896
- parent.props.severity === "warning",
897
- },
898
- // Text & Outlined Button
899
- {
900
- "hover:bg-orange-300/20":
901
- (parent.props.text || parent.props.outlined) &&
902
- parent.props.severity === "warning" &&
903
- !parent.props.plain,
904
- },
905
-
906
- // Help
907
- {
908
- "hover:bg-purple-600 dark:hover:bg-purple-300 hover:ring-purple-600 dark:hover:ring-purple-300":
909
- parent.props.severity === "help" &&
910
- !parent.props.text &&
911
- !parent.props.outlined &&
912
- !parent.props.plain,
913
- },
914
- {
915
- "focus:ring-purple-500 dark:focus:ring-purple-400":
916
- parent.props.severity === "help",
917
- },
918
- // Text & Outlined Button
919
- {
920
- "hover:bg-purple-300/20":
921
- (parent.props.text || parent.props.outlined) &&
922
- parent.props.severity === "help" &&
923
- !parent.props.plain,
924
- },
925
-
926
- // Warning
927
- {
928
- "hover:bg-red-600 dark:hover:bg-red-300 hover:ring-red-600 dark:hover:ring-red-300":
929
- parent.props.severity === "danger" &&
930
- !parent.props.text &&
931
- !parent.props.outlined &&
932
- !parent.props.plain,
933
- },
934
- {
935
- "focus:ring-red-500 dark:focus:ring-red-400":
936
- parent.props.severity === "danger",
937
- },
938
- // Text & Outlined Button
939
- {
940
- "hover:bg-red-300/20":
941
- (parent.props.text || parent.props.outlined) &&
942
- parent.props.severity === "danger" &&
943
- !parent.props.plain,
944
- },
945
-
946
- // Transitions
947
- "transition duration-200 ease-in-out",
948
-
949
- // Misc
950
- "cursor-pointer overflow-hidden select-none",
951
- ],
952
- }),
953
- label: {
954
- class: ["hidden"],
955
- },
956
- },
957
- menu: {
958
- root: {
959
- class: [
960
- // Shape
961
- "rounded-md",
962
-
963
- // Size
964
- "min-w-[12rem]",
965
- "p-1.5",
966
-
967
- // Colors
968
- "bg-surface-0 dark:bg-surface-700",
969
- "ring-1 ring-surface-200 dark:ring-surface-700",
970
- ],
971
- },
972
- menu: {
973
- class: [
974
- // Spacings and Shape
975
- "list-none",
976
- "m-0",
977
- "p-0",
978
- "outline-none",
979
- ],
980
- },
981
- menuitem: {
982
- class: ["relative first:mt-0 mt-1"],
983
- },
984
- content: ({ context }) => ({
985
- class: [
986
- //Shape
987
- "rounded-md",
988
-
989
- // Colors
990
- {
991
- "text-surface-500 dark:text-white/70":
992
- !context.focused && !context.active,
993
- "text-surface-500 dark:text-white/70 bg-surface-200 dark:bg-black/70":
994
- context.focused && !context.active,
995
- "text-surface-900 dark:text-surface-0/80 bg-surface-50 dark:bg-black/70":
996
- context.focused && context.active,
997
- "text-surface-900 dark:text-surface-0/80 bg-surface-50 dark:bg-black/70":
998
- !context.focused && context.active,
999
- },
1000
-
1001
- // Hover States
1002
- {
1003
- "hover:bg-surface-50 dark:hover:bg-surface-800": !context.active,
1004
- "hover:bg-surface-100 dark:hover:bg-black/40 text-surface-900 dark:text-surface-0/80":
1005
- context.active,
1006
- },
1007
-
1008
- // Transitions
1009
- "transition-shadow",
1010
- "duration-200",
1011
- ],
1012
- }),
1013
- action: {
1014
- class: [
1015
- "relative",
1016
-
1017
- // Font
1018
- "font-semibold",
1019
-
1020
- // Flexbox
1021
- "flex",
1022
- "items-center",
1023
-
1024
- // Spacing
1025
- "py-2",
1026
- "px-3",
1027
-
1028
- // Misc
1029
- "no-underline",
1030
- "overflow-hidden",
1031
- "cursor-pointer",
1032
- "select-none",
1033
- ],
1034
- },
1035
- icon: {
1036
- class: [
1037
- // Spacing
1038
- "mr-2",
1039
- "leading-6",
1040
- "text-sm",
1041
- ],
1042
- },
1043
- label: {
1044
- class: ["leading-none", "text-sm"],
1045
- },
1046
- submenuicon: {
1047
- class: [
1048
- // Position
1049
- "ml-auto",
1050
- ],
1051
- },
1052
- submenu: {
1053
- class: [
1054
- // Size
1055
- "w-full sm:w-48",
1056
-
1057
- // Spacing
1058
- "p-1.5",
1059
- "m-0 mx-1.5",
1060
- "list-none",
1061
-
1062
- // Shape
1063
- "shadow-none sm:shadow-md",
1064
- "border-0",
1065
-
1066
- // Position
1067
- "static sm:absolute",
1068
- "z-10",
1069
-
1070
- // Color
1071
- "bg-surface-0 dark:bg-surface-700",
1072
- ],
1073
- },
1074
- separator: {
1075
- class: "border-t border-surface-200 dark:border-surface-600 my-1",
1076
- },
1077
- },
1078
- };