@cooperco/cooper-component-library 0.0.10
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.
- package/README.md +11 -0
- package/package.json +85 -0
- package/src/assets/main.css +155 -0
- package/src/assets/theme.css +67 -0
- package/src/assets/usercard.jpg +0 -0
- package/src/assets/vue.svg +1 -0
- package/src/components/Accordion.vue +33 -0
- package/src/components/AccordionItem.vue +53 -0
- package/src/components/CTA.vue +39 -0
- package/src/components/CarouselModule.vue +46 -0
- package/src/components/ContainerCollectionModule.vue +33 -0
- package/src/components/ContainerModule.vue +116 -0
- package/src/components/ContentAndImage.vue +34 -0
- package/src/components/ContentMediaModule.vue +50 -0
- package/src/components/ContentModule.vue +51 -0
- package/src/components/FooterNavigation.vue +57 -0
- package/src/components/IconChevron.vue +107 -0
- package/src/components/Image.vue +15 -0
- package/src/components/LogoCollectionModule.vue +30 -0
- package/src/components/LogoContainerModule.vue +30 -0
- package/src/components/NavigationElement.vue +92 -0
- package/src/components/PrimaryNavigation.vue +68 -0
- package/src/components/SplitModule.vue +42 -0
- package/src/components/Testimonial.vue +48 -0
- package/src/components/TestimonialModule.vue +48 -0
- package/src/components/TileCollection.vue +37 -0
- package/src/components/TileCollectionModule.vue +45 -0
- package/src/components/TileContent.vue +105 -0
- package/src/components/Video.vue +18 -0
- package/src/components/types/Accordion.ts +18 -0
- package/src/components/types/AccordionItem.ts +19 -0
- package/src/components/types/CTA.ts +13 -0
- package/src/components/types/CarouselModule.ts +21 -0
- package/src/components/types/ContainerCollectionModule.ts +12 -0
- package/src/components/types/ContainerModule.ts +35 -0
- package/src/components/types/ContentAndImage.ts +14 -0
- package/src/components/types/ContentMediaModule.ts +14 -0
- package/src/components/types/ContentModule.ts +21 -0
- package/src/components/types/FooterNavigation.ts +12 -0
- package/src/components/types/Image.ts +12 -0
- package/src/components/types/LogoCollectionModule.ts +12 -0
- package/src/components/types/LogoContainerModule.ts +12 -0
- package/src/components/types/NavigationElement.ts +19 -0
- package/src/components/types/PrimaryNavigation.ts +10 -0
- package/src/components/types/SplitModule.ts +16 -0
- package/src/components/types/Testimonial.ts +17 -0
- package/src/components/types/TileCollection.ts +14 -0
- package/src/components/types/TileContent.ts +34 -0
- package/src/components/types/Video.ts +8 -0
- package/src/components/types/index.ts +10 -0
- package/src/presets/aura/accordion/index.js +81 -0
- package/src/presets/aura/autocomplete/index.js +280 -0
- package/src/presets/aura/avatar/index.js +46 -0
- package/src/presets/aura/badge/index.js +43 -0
- package/src/presets/aura/badgedirective/index.js +49 -0
- package/src/presets/aura/blockui/index.js +8 -0
- package/src/presets/aura/breadcrumb/index.js +63 -0
- package/src/presets/aura/button/index.js +511 -0
- package/src/presets/aura/calendar/index.js +702 -0
- package/src/presets/aura/card/index.js +53 -0
- package/src/presets/aura/carousel/index.js +160 -0
- package/src/presets/aura/cascadeselect/index.js +220 -0
- package/src/presets/aura/checkbox/index.js +107 -0
- package/src/presets/aura/chip/index.js +45 -0
- package/src/presets/aura/chips/index.js +126 -0
- package/src/presets/aura/colorpicker/index.js +132 -0
- package/src/presets/aura/confirmpopup/index.js +111 -0
- package/src/presets/aura/contextmenu/index.js +132 -0
- package/src/presets/aura/datatable/index.js +1290 -0
- package/src/presets/aura/dataview/index.js +40 -0
- package/src/presets/aura/deferred/index.js +3 -0
- package/src/presets/aura/dialog/index.js +250 -0
- package/src/presets/aura/divider/index.js +72 -0
- package/src/presets/aura/dock/index.js +97 -0
- package/src/presets/aura/dropdown/index.js +297 -0
- package/src/presets/aura/fieldset/index.js +95 -0
- package/src/presets/aura/fileupload/index.js +175 -0
- package/src/presets/aura/floatlabel/index.js +26 -0
- package/src/presets/aura/galleria/index.js +353 -0
- package/src/presets/aura/global.js +90 -0
- package/src/presets/aura/iconfield/index.js +22 -0
- package/src/presets/aura/image/index.js +206 -0
- package/src/presets/aura/index.js +181 -0
- package/src/presets/aura/inlinemessage/index.js +46 -0
- package/src/presets/aura/inplace/index.js +27 -0
- package/src/presets/aura/inputgroup/index.js +5 -0
- package/src/presets/aura/inputgroupaddon/index.js +28 -0
- package/src/presets/aura/inputmask/index.js +47 -0
- package/src/presets/aura/inputnumber/index.js +293 -0
- package/src/presets/aura/inputotp/index.js +69 -0
- package/src/presets/aura/inputswitch/index.js +94 -0
- package/src/presets/aura/inputtext/index.js +63 -0
- package/src/presets/aura/knob/index.js +47 -0
- package/src/presets/aura/listbox/index.js +158 -0
- package/src/presets/aura/megamenu/index.js +206 -0
- package/src/presets/aura/menu/index.js +122 -0
- package/src/presets/aura/menubar/index.js +184 -0
- package/src/presets/aura/message/index.js +112 -0
- package/src/presets/aura/metergroup/index.js +110 -0
- package/src/presets/aura/multiselect/index.js +579 -0
- package/src/presets/aura/orderlist/index.js +281 -0
- package/src/presets/aura/organizationchart/index.js +142 -0
- package/src/presets/aura/overlaypanel/index.js +34 -0
- package/src/presets/aura/paginator/index.js +566 -0
- package/src/presets/aura/panel/index.js +102 -0
- package/src/presets/aura/panelmenu/index.js +130 -0
- package/src/presets/aura/password/index.js +143 -0
- package/src/presets/aura/picklist/index.js +718 -0
- package/src/presets/aura/progressbar/index.js +64 -0
- package/src/presets/aura/progressspinner/index.js +51 -0
- package/src/presets/aura/radiobutton/index.js +121 -0
- package/src/presets/aura/rating/index.js +95 -0
- package/src/presets/aura/ripple/index.js +6 -0
- package/src/presets/aura/scrollpanel/index.js +77 -0
- package/src/presets/aura/scrolltop/index.js +45 -0
- package/src/presets/aura/selectbutton/index.js +66 -0
- package/src/presets/aura/sidebar/index.js +160 -0
- package/src/presets/aura/skeleton/index.js +19 -0
- package/src/presets/aura/slider/index.js +144 -0
- package/src/presets/aura/speeddial/index.js +579 -0
- package/src/presets/aura/splitbutton/index.js +1185 -0
- package/src/presets/aura/splitter/index.js +71 -0
- package/src/presets/aura/stepper/index.js +183 -0
- package/src/presets/aura/steps/index.js +117 -0
- package/src/presets/aura/tabmenu/index.js +75 -0
- package/src/presets/aura/tabview/index.js +162 -0
- package/src/presets/aura/tag/index.js +44 -0
- package/src/presets/aura/terminal/index.js +60 -0
- package/src/presets/aura/textarea/index.js +49 -0
- package/src/presets/aura/tieredmenu/index.js +125 -0
- package/src/presets/aura/timeline/index.js +114 -0
- package/src/presets/aura/toast/index.js +151 -0
- package/src/presets/aura/togglebutton/index.js +98 -0
- package/src/presets/aura/toolbar/index.js +28 -0
- package/src/presets/aura/tooltip/index.js +73 -0
- package/src/presets/aura/tree/index.js +294 -0
- package/src/presets/aura/treeselect/index.js +404 -0
- package/src/presets/aura/treetable/index.js +513 -0
- package/src/presets/aura/tristatecheckbox/index.js +121 -0
|
@@ -0,0 +1,280 @@
|
|
|
1
|
+
export default {
|
|
2
|
+
root: ({ props }) => ({
|
|
3
|
+
class: [
|
|
4
|
+
'relative',
|
|
5
|
+
|
|
6
|
+
// Flex
|
|
7
|
+
'inline-flex',
|
|
8
|
+
|
|
9
|
+
// Size
|
|
10
|
+
{ 'w-full': props.multiple },
|
|
11
|
+
|
|
12
|
+
// Color
|
|
13
|
+
'text-surface-900 dark:text-surface-0',
|
|
14
|
+
|
|
15
|
+
//States
|
|
16
|
+
{
|
|
17
|
+
'bg-surface-200 dark:bg-surface-700 select-none pointer-events-none cursor-default':
|
|
18
|
+
props.disabled,
|
|
19
|
+
},
|
|
20
|
+
],
|
|
21
|
+
}),
|
|
22
|
+
container: ({ props, state }) => ({
|
|
23
|
+
class: [
|
|
24
|
+
// Font
|
|
25
|
+
'leading-none',
|
|
26
|
+
|
|
27
|
+
// Flex
|
|
28
|
+
'flex items-center flex-wrap',
|
|
29
|
+
'gap-2',
|
|
30
|
+
|
|
31
|
+
// Spacing
|
|
32
|
+
'm-0 list-none',
|
|
33
|
+
'p-1',
|
|
34
|
+
|
|
35
|
+
// Size
|
|
36
|
+
'w-full',
|
|
37
|
+
|
|
38
|
+
// Shape
|
|
39
|
+
'appearance-none rounded-md',
|
|
40
|
+
|
|
41
|
+
// Color
|
|
42
|
+
'text-surface-700 dark:text-white/80',
|
|
43
|
+
'placeholder:text-surface-400 dark:placeholder:text-surface-500',
|
|
44
|
+
{ 'bg-surface-0 dark:bg-surface-950': !props.disabled },
|
|
45
|
+
'border',
|
|
46
|
+
{ 'border-surface-300 dark:border-surface-700': !props.invalid },
|
|
47
|
+
|
|
48
|
+
// Invalid State
|
|
49
|
+
'invalid:focus:ring-red-200',
|
|
50
|
+
'invalid:hover:border-red-500',
|
|
51
|
+
{ 'border-red-500 dark:border-red-400': props.invalid },
|
|
52
|
+
|
|
53
|
+
// States
|
|
54
|
+
{
|
|
55
|
+
'hover:border-surface-400 dark:hover:border-surface-700':
|
|
56
|
+
!props.invalid,
|
|
57
|
+
},
|
|
58
|
+
{
|
|
59
|
+
'outline-none outline-offset-0 z-10 ring-1 ring-primary-500 dark:ring-primary-400':
|
|
60
|
+
state.focused,
|
|
61
|
+
},
|
|
62
|
+
|
|
63
|
+
// Transition
|
|
64
|
+
'transition duration-200 ease-in-out',
|
|
65
|
+
|
|
66
|
+
// Misc
|
|
67
|
+
'cursor-text overflow-hidden',
|
|
68
|
+
],
|
|
69
|
+
}),
|
|
70
|
+
inputtoken: {
|
|
71
|
+
class: ['py-1 px-0 ml-2', 'inline-flex flex-auto'],
|
|
72
|
+
},
|
|
73
|
+
input: ({ props, parent }) => ({
|
|
74
|
+
class: [
|
|
75
|
+
// Font
|
|
76
|
+
'text-base leading-none',
|
|
77
|
+
|
|
78
|
+
// Shape
|
|
79
|
+
'appearance-none rounded-md',
|
|
80
|
+
{ 'rounded-tr-none rounded-br-none': props.dropdown },
|
|
81
|
+
{ 'outline-none shadow-none rounded-none': props.multiple },
|
|
82
|
+
|
|
83
|
+
// Size
|
|
84
|
+
{ 'w-full': props.multiple },
|
|
85
|
+
|
|
86
|
+
// Spacing
|
|
87
|
+
'm-0',
|
|
88
|
+
{ 'py-2 px-3': !props.multiple, 'p-0': props.multiple },
|
|
89
|
+
|
|
90
|
+
// Colors
|
|
91
|
+
'text-surface-700 dark:text-white/80',
|
|
92
|
+
'border',
|
|
93
|
+
{
|
|
94
|
+
'bg-surface-0 dark:bg-surface-950': !props.multiple,
|
|
95
|
+
' border-surface-300 dark:border-surface-700':
|
|
96
|
+
!props.multiple && !props.invalid,
|
|
97
|
+
'border-0 bg-transparent': props.multiple,
|
|
98
|
+
},
|
|
99
|
+
|
|
100
|
+
// Invalid State
|
|
101
|
+
{ 'border-red-500 dark:border-red-400': props.invalid },
|
|
102
|
+
|
|
103
|
+
// States
|
|
104
|
+
{
|
|
105
|
+
'focus:outline-none focus:outline-offset-0 focus:ring-1 focus:ring-primary-500 dark:focus:ring-primary-400 focus:z-10':
|
|
106
|
+
!props.multiple,
|
|
107
|
+
},
|
|
108
|
+
|
|
109
|
+
// Filled State *for FloatLabel
|
|
110
|
+
{
|
|
111
|
+
filled:
|
|
112
|
+
parent.instance?.$name == 'FloatLabel' && props.modelValue !== '',
|
|
113
|
+
},
|
|
114
|
+
|
|
115
|
+
// Transition
|
|
116
|
+
'transition-colors duration-200',
|
|
117
|
+
],
|
|
118
|
+
}),
|
|
119
|
+
token: {
|
|
120
|
+
class: [
|
|
121
|
+
// Flex
|
|
122
|
+
'inline-flex items-center',
|
|
123
|
+
|
|
124
|
+
// Spacings
|
|
125
|
+
'py-1 px-3 m-0',
|
|
126
|
+
|
|
127
|
+
// Shape
|
|
128
|
+
'rounded',
|
|
129
|
+
|
|
130
|
+
// Colors
|
|
131
|
+
'bg-surface-100 dark:bg-surface-700',
|
|
132
|
+
'text-surface-700 dark:text-white',
|
|
133
|
+
|
|
134
|
+
// Misc
|
|
135
|
+
'cursor-default',
|
|
136
|
+
],
|
|
137
|
+
},
|
|
138
|
+
removeTokenIcon: {
|
|
139
|
+
class: [
|
|
140
|
+
// Spacing
|
|
141
|
+
'ml-[0.375rem]',
|
|
142
|
+
|
|
143
|
+
// Size
|
|
144
|
+
'w-4 h-4',
|
|
145
|
+
|
|
146
|
+
// Misc
|
|
147
|
+
'cursor-pointer',
|
|
148
|
+
],
|
|
149
|
+
},
|
|
150
|
+
dropdownbutton: {
|
|
151
|
+
root: {
|
|
152
|
+
class: [
|
|
153
|
+
'relative',
|
|
154
|
+
|
|
155
|
+
// Alignments
|
|
156
|
+
'items-center inline-flex justify-center text-center align-bottom',
|
|
157
|
+
|
|
158
|
+
// Shape
|
|
159
|
+
'rounded-r-md',
|
|
160
|
+
|
|
161
|
+
// Size
|
|
162
|
+
'py-2 leading-none',
|
|
163
|
+
'w-10',
|
|
164
|
+
|
|
165
|
+
// Colors
|
|
166
|
+
'text-primary-inverse',
|
|
167
|
+
'bg-primary',
|
|
168
|
+
'border border-primary',
|
|
169
|
+
|
|
170
|
+
// States
|
|
171
|
+
'focus:outline-none focus:outline-offset-0 focus:ring-1 ',
|
|
172
|
+
'hover:bg-primary-hover hover:border-primary-hover',
|
|
173
|
+
'focus:ring-primary-500 dark:focus:ring-primary-400',
|
|
174
|
+
],
|
|
175
|
+
},
|
|
176
|
+
},
|
|
177
|
+
loadingicon: {
|
|
178
|
+
class: [
|
|
179
|
+
'text-surface-500 dark:text-surface-0/70',
|
|
180
|
+
'absolute top-[50%] right-[0.5rem] -mt-2 animate-spin',
|
|
181
|
+
],
|
|
182
|
+
},
|
|
183
|
+
panel: {
|
|
184
|
+
class: [
|
|
185
|
+
// Colors
|
|
186
|
+
'bg-surface-0 dark:bg-surface-900',
|
|
187
|
+
'text-surface-700 dark:text-white/80',
|
|
188
|
+
|
|
189
|
+
// Shape
|
|
190
|
+
'border border-surface-300 dark:border-surface-700',
|
|
191
|
+
'rounded-md',
|
|
192
|
+
'shadow-md',
|
|
193
|
+
|
|
194
|
+
// Size
|
|
195
|
+
'overflow-auto',
|
|
196
|
+
],
|
|
197
|
+
},
|
|
198
|
+
list: {
|
|
199
|
+
class: 'p-1 list-none m-0',
|
|
200
|
+
},
|
|
201
|
+
item: ({ context }) => ({
|
|
202
|
+
class: [
|
|
203
|
+
'relative',
|
|
204
|
+
|
|
205
|
+
// Font
|
|
206
|
+
'leading-none',
|
|
207
|
+
|
|
208
|
+
// Spacing
|
|
209
|
+
'm-0 px-3 py-2',
|
|
210
|
+
'first:mt-0 mt-[2px]',
|
|
211
|
+
|
|
212
|
+
// Shape
|
|
213
|
+
'border-0 rounded',
|
|
214
|
+
|
|
215
|
+
// Colors
|
|
216
|
+
{
|
|
217
|
+
'text-surface-700 dark:text-white/80':
|
|
218
|
+
!context.focused && !context.selected,
|
|
219
|
+
'bg-surface-200 dark:bg-surface-600/60':
|
|
220
|
+
context.focused && !context.selected,
|
|
221
|
+
'text-surface-700 dark:text-white/80':
|
|
222
|
+
context.focused && !context.selected,
|
|
223
|
+
|
|
224
|
+
'text-primary-highlight-inverse': context.selected,
|
|
225
|
+
'bg-primary-highlight': context.selected,
|
|
226
|
+
},
|
|
227
|
+
|
|
228
|
+
//States
|
|
229
|
+
{
|
|
230
|
+
'hover:bg-surface-100 dark:hover:bg-[rgba(255,255,255,0.03)]':
|
|
231
|
+
!context.focused && !context.selected,
|
|
232
|
+
},
|
|
233
|
+
{ 'hover:bg-primary-highlight-hover': context.selected },
|
|
234
|
+
{
|
|
235
|
+
'hover:text-surface-700 hover:bg-surface-100 dark:hover:text-white dark:hover:bg-[rgba(255,255,255,0.03)]':
|
|
236
|
+
context.focused && !context.selected,
|
|
237
|
+
},
|
|
238
|
+
|
|
239
|
+
// Transition
|
|
240
|
+
'transition-shadow duration-200',
|
|
241
|
+
|
|
242
|
+
// Misc
|
|
243
|
+
'cursor-pointer overflow-hidden whitespace-nowrap',
|
|
244
|
+
],
|
|
245
|
+
}),
|
|
246
|
+
itemgroup: {
|
|
247
|
+
class: [
|
|
248
|
+
'font-semibold',
|
|
249
|
+
|
|
250
|
+
// Spacing
|
|
251
|
+
'm-0 py-2 px-3',
|
|
252
|
+
|
|
253
|
+
// Colors
|
|
254
|
+
'text-surface-400 dark:text-surface-500',
|
|
255
|
+
|
|
256
|
+
// Misc
|
|
257
|
+
'cursor-auto',
|
|
258
|
+
],
|
|
259
|
+
},
|
|
260
|
+
emptymessage: {
|
|
261
|
+
class: [
|
|
262
|
+
// Font
|
|
263
|
+
'leading-none',
|
|
264
|
+
|
|
265
|
+
// Spacing
|
|
266
|
+
'py-2 px-3',
|
|
267
|
+
|
|
268
|
+
// Color
|
|
269
|
+
'text-surface-800 dark:text-white/80',
|
|
270
|
+
'bg-transparent',
|
|
271
|
+
],
|
|
272
|
+
},
|
|
273
|
+
transition: {
|
|
274
|
+
enterFromClass: 'opacity-0 scale-y-[0.8]',
|
|
275
|
+
enterActiveClass:
|
|
276
|
+
'transition-[transform,opacity] duration-[120ms] ease-[cubic-bezier(0,0,0.2,1)]',
|
|
277
|
+
leaveActiveClass: 'transition-opacity duration-100 ease-linear',
|
|
278
|
+
leaveToClass: 'opacity-0',
|
|
279
|
+
},
|
|
280
|
+
}
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
export default {
|
|
2
|
+
root: ({ props, parent }) => ({
|
|
3
|
+
class: [
|
|
4
|
+
// Font
|
|
5
|
+
{
|
|
6
|
+
'text-xl': props.size == 'large',
|
|
7
|
+
'text-2xl': props.size == 'xlarge',
|
|
8
|
+
},
|
|
9
|
+
|
|
10
|
+
// Alignments
|
|
11
|
+
'inline-flex items-center justify-center',
|
|
12
|
+
'relative',
|
|
13
|
+
|
|
14
|
+
// Sizes
|
|
15
|
+
{
|
|
16
|
+
'h-8 w-8': props.size == null || props.size == 'normal',
|
|
17
|
+
'w-12 h-12': props.size == 'large',
|
|
18
|
+
'w-16 h-16': props.size == 'xlarge',
|
|
19
|
+
},
|
|
20
|
+
{ '-ml-4': parent.instance.$style?.name == 'avatargroup' },
|
|
21
|
+
|
|
22
|
+
// Shapes
|
|
23
|
+
{
|
|
24
|
+
'rounded-lg': props.shape == 'square',
|
|
25
|
+
'rounded-full': props.shape == 'circle',
|
|
26
|
+
},
|
|
27
|
+
{ 'border-2': parent.instance.$style?.name == 'avatargroup' },
|
|
28
|
+
|
|
29
|
+
// Colors
|
|
30
|
+
'bg-surface-300 dark:bg-surface-700',
|
|
31
|
+
{
|
|
32
|
+
'border-white dark:border-surface-800':
|
|
33
|
+
parent.instance.$style?.name == 'avatargroup',
|
|
34
|
+
},
|
|
35
|
+
],
|
|
36
|
+
}),
|
|
37
|
+
image: ({ props }) => ({
|
|
38
|
+
class: [
|
|
39
|
+
'h-full w-full',
|
|
40
|
+
{
|
|
41
|
+
'rounded-lg': props.shape == 'square',
|
|
42
|
+
'rounded-full': props.shape == 'circle',
|
|
43
|
+
},
|
|
44
|
+
],
|
|
45
|
+
}),
|
|
46
|
+
}
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
export default {
|
|
2
|
+
root: ({ props }) => ({
|
|
3
|
+
class: [
|
|
4
|
+
// Font
|
|
5
|
+
'font-bold',
|
|
6
|
+
|
|
7
|
+
{
|
|
8
|
+
'text-xs leading-[1.5rem]': props.size == null,
|
|
9
|
+
'text-lg leading-[2.25rem]': props.size == 'large',
|
|
10
|
+
'text-2xl leading-[3rem]': props.size == 'xlarge',
|
|
11
|
+
},
|
|
12
|
+
|
|
13
|
+
// Alignment
|
|
14
|
+
'text-center inline-block',
|
|
15
|
+
|
|
16
|
+
// Size
|
|
17
|
+
'p-0 px-1',
|
|
18
|
+
{
|
|
19
|
+
'min-w-[1.5rem] h-[1.5rem]': props.size == null,
|
|
20
|
+
'min-w-[2.25rem] h-[2.25rem]': props.size == 'large',
|
|
21
|
+
'min-w-[3rem] h-[3rem]': props.size == 'xlarge',
|
|
22
|
+
},
|
|
23
|
+
|
|
24
|
+
// Shape
|
|
25
|
+
{
|
|
26
|
+
'rounded-full': props.value.length == 1,
|
|
27
|
+
'rounded-[0.71rem]': props.value.length !== 1,
|
|
28
|
+
},
|
|
29
|
+
|
|
30
|
+
// Color
|
|
31
|
+
'text-primary-inverse',
|
|
32
|
+
{
|
|
33
|
+
'bg-primary': props.severity == null || props.severity == 'primary',
|
|
34
|
+
'bg-surface-500 dark:bg-surface-400': props.severity == 'secondary',
|
|
35
|
+
'bg-green-500 dark:bg-green-400': props.severity == 'success',
|
|
36
|
+
'bg-blue-500 dark:bg-blue-400': props.severity == 'info',
|
|
37
|
+
'bg-orange-500 dark:bg-orange-400': props.severity == 'warning',
|
|
38
|
+
'bg-purple-500 dark:bg-purple-400': props.severity == 'help',
|
|
39
|
+
'bg-red-500 dark:bg-red-400': props.severity == 'danger',
|
|
40
|
+
},
|
|
41
|
+
],
|
|
42
|
+
}),
|
|
43
|
+
}
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
export default {
|
|
2
|
+
root: ({ context }) => ({
|
|
3
|
+
class: [
|
|
4
|
+
// Font
|
|
5
|
+
'font-bold',
|
|
6
|
+
'text-xs leading-5',
|
|
7
|
+
|
|
8
|
+
// Alignment
|
|
9
|
+
'flex items-center justify-center',
|
|
10
|
+
'text-center',
|
|
11
|
+
|
|
12
|
+
// Position
|
|
13
|
+
'absolute top-0 right-0 transform translate-x-1/2 -translate-y-1/2 origin-top-right',
|
|
14
|
+
|
|
15
|
+
// Size
|
|
16
|
+
'm-0',
|
|
17
|
+
{
|
|
18
|
+
'p-0': context.nogutter || context.dot,
|
|
19
|
+
'px-2': !context.nogutter && !context.dot,
|
|
20
|
+
'min-w-[0.5rem] w-2 h-2': context.dot,
|
|
21
|
+
'min-w-[1.5rem] h-6': !context.dot,
|
|
22
|
+
},
|
|
23
|
+
|
|
24
|
+
// Shape
|
|
25
|
+
{
|
|
26
|
+
'rounded-full': context.nogutter || context.dot,
|
|
27
|
+
'rounded-[10px]': !context.nogutter && !context.dot,
|
|
28
|
+
},
|
|
29
|
+
|
|
30
|
+
// Color
|
|
31
|
+
'text-primary-inverse',
|
|
32
|
+
{
|
|
33
|
+
'bg-primary':
|
|
34
|
+
!context.info &&
|
|
35
|
+
!context.success &&
|
|
36
|
+
!context.warning &&
|
|
37
|
+
!context.danger &&
|
|
38
|
+
!context.help &&
|
|
39
|
+
!context.secondary,
|
|
40
|
+
'bg-surface-500 dark:bg-surface-400': context.secondary,
|
|
41
|
+
'bg-green-500 dark:bg-green-400': context.success,
|
|
42
|
+
'bg-blue-500 dark:bg-blue-400': context.info,
|
|
43
|
+
'bg-orange-500 dark:bg-orange-400': context.warning,
|
|
44
|
+
'bg-purple-500 dark:bg-purple-400': context.help,
|
|
45
|
+
'bg-red-500 dark:bg-red-400': context.danger,
|
|
46
|
+
},
|
|
47
|
+
],
|
|
48
|
+
}),
|
|
49
|
+
}
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
export default {
|
|
2
|
+
root: {
|
|
3
|
+
class: [
|
|
4
|
+
// Shape
|
|
5
|
+
'rounded-md',
|
|
6
|
+
|
|
7
|
+
// Spacing
|
|
8
|
+
'p-4',
|
|
9
|
+
|
|
10
|
+
// Color
|
|
11
|
+
'bg-surface-0 dark:bg-surface-900',
|
|
12
|
+
|
|
13
|
+
// Misc
|
|
14
|
+
'overflow-x-auto',
|
|
15
|
+
],
|
|
16
|
+
},
|
|
17
|
+
menu: {
|
|
18
|
+
class: [
|
|
19
|
+
// Flex & Alignment
|
|
20
|
+
'flex items-center flex-nowrap',
|
|
21
|
+
|
|
22
|
+
// Spacing
|
|
23
|
+
'm-0 p-0 list-none leading-none',
|
|
24
|
+
],
|
|
25
|
+
},
|
|
26
|
+
action: {
|
|
27
|
+
class: [
|
|
28
|
+
// Flex & Alignment
|
|
29
|
+
'flex items-center',
|
|
30
|
+
|
|
31
|
+
// Shape
|
|
32
|
+
'rounded-md',
|
|
33
|
+
|
|
34
|
+
// Color
|
|
35
|
+
'text-surface-600 dark:text-white/70',
|
|
36
|
+
|
|
37
|
+
// States
|
|
38
|
+
'focus-visible:outline-none focus-visible:outline-offset-0',
|
|
39
|
+
'focus-visible:ring-1 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400',
|
|
40
|
+
|
|
41
|
+
// Transitions
|
|
42
|
+
'transition-shadow duration-200',
|
|
43
|
+
|
|
44
|
+
// Misc
|
|
45
|
+
'text-decoration-none',
|
|
46
|
+
],
|
|
47
|
+
},
|
|
48
|
+
icon: {
|
|
49
|
+
class: 'text-surface-600 dark:text-white/70',
|
|
50
|
+
},
|
|
51
|
+
separator: {
|
|
52
|
+
class: [
|
|
53
|
+
// Flex & Alignment
|
|
54
|
+
'flex items-center',
|
|
55
|
+
|
|
56
|
+
// Spacing
|
|
57
|
+
'mx-2',
|
|
58
|
+
|
|
59
|
+
// Color
|
|
60
|
+
'text-surface-600 dark:text-white/70',
|
|
61
|
+
],
|
|
62
|
+
},
|
|
63
|
+
}
|