@infonomic/uikit 5.2.1 → 5.4.0
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/dist/astro.d.ts +45 -0
- package/dist/astro.js +45 -0
- package/dist/components/accordion/accordion.module.css +60 -0
- package/dist/components/avatar/avatar.module.css +54 -0
- package/dist/components/badge/badge.module.css +61 -0
- package/dist/components/button/button-group.module.css +19 -0
- package/dist/components/button/button.astro +86 -0
- package/dist/components/button/button.module.css +431 -0
- package/dist/components/button/control-buttons.module.css +132 -0
- package/dist/components/button/copy-button.module.css +56 -0
- package/dist/components/button/icon-button.astro +47 -0
- package/dist/components/card/card-content.astro +14 -0
- package/dist/components/card/card-description.astro +14 -0
- package/dist/components/card/card-footer.astro +14 -0
- package/dist/components/card/card-header.astro +14 -0
- package/dist/components/card/card-title.astro +14 -0
- package/dist/components/card/card.astro +41 -0
- package/dist/components/card/card.module.css +77 -0
- package/dist/components/container/container.astro +13 -0
- package/dist/components/container/container.module.css +36 -0
- package/dist/components/dropdown/dropdown.module.css +120 -0
- package/dist/components/forms/calendar.module.css +269 -0
- package/dist/components/forms/checkbox.module.css +211 -0
- package/dist/components/forms/error-text.astro +14 -0
- package/dist/components/forms/error-text.module.css +9 -0
- package/dist/components/forms/help-text.astro +13 -0
- package/dist/components/forms/help-text.module.css +9 -0
- package/dist/components/forms/input-adornment.astro +26 -0
- package/dist/components/forms/input-adornment.module.css +21 -0
- package/dist/components/forms/input.astro +99 -0
- package/dist/components/forms/input.module.css +278 -0
- package/dist/components/forms/label.astro +24 -0
- package/dist/components/forms/label.module.css +15 -0
- package/dist/components/forms/radio-group.module.css +163 -0
- package/dist/components/forms/select.module.css +68 -0
- package/dist/components/forms/text-area.module.css +10 -0
- package/dist/components/hamburger/hamburger.astro +30 -0
- package/dist/components/notifications/alert.module.css +110 -0
- package/dist/components/notifications/toast.module.css +237 -0
- package/dist/components/overlay/overlay.module.css +41 -0
- package/dist/components/pager/pagination.module.css +149 -0
- package/dist/components/scroll-area/scroll-area.module.css +64 -0
- package/dist/components/scroll-to-top/scroll-to-top.astro +75 -0
- package/dist/components/scroll-to-top/scroll-to-top.d.ts +12 -7
- package/dist/components/scroll-to-top/scroll-to-top.d.ts.map +1 -1
- package/dist/components/scroll-to-top/scroll-to-top.js +24 -14
- package/dist/components/scroll-to-top/scroll-to-top.module.css +86 -0
- package/dist/components/section/section.astro +13 -0
- package/dist/components/section/section.module.css +9 -0
- package/dist/components/shimmer/shimmer.module.css +53 -0
- package/dist/components/table/table.module.css +100 -0
- package/dist/components/tabs/tabs.module.css +66 -0
- package/dist/components/tooltip/tooltip.module.css +45 -0
- package/dist/icons/close-icon.astro +38 -0
- package/dist/icons/icon-element.astro +27 -0
- package/dist/icons/icons.module.css +155 -0
- package/dist/icons/light-icon.astro +36 -0
- package/dist/icons/moon-icon.astro +38 -0
- package/dist/icons/search-icon.astro +40 -0
- package/dist/widgets/datepicker/datepicker.module.css +189 -0
- package/dist/widgets/drawer/drawer.module.css +112 -0
- package/dist/widgets/modal/modal.module.css +81 -0
- package/dist/widgets/timeline/timeline.module.css +87 -0
- package/package.json +5 -4
- package/src/astro.d.ts +2 -0
- package/src/astro.js +3 -0
- package/src/components/scroll-to-top/scroll-to-top.astro +75 -0
- package/src/components/scroll-to-top/scroll-to-top.tsx +52 -33
|
@@ -0,0 +1,431 @@
|
|
|
1
|
+
@layer infonomic-base, infonomic-functional, infonomic-utilities, infonomic-theme, infonomic-typography, infonomic-components;
|
|
2
|
+
|
|
3
|
+
@layer infonomic-components {
|
|
4
|
+
.button,
|
|
5
|
+
:global(.button) {
|
|
6
|
+
border: none;
|
|
7
|
+
cursor: pointer;
|
|
8
|
+
font-weight: normal;
|
|
9
|
+
text-align: center;
|
|
10
|
+
display: inline-flex;
|
|
11
|
+
gap: var(--gap-2);
|
|
12
|
+
line-height: 0;
|
|
13
|
+
align-items: center;
|
|
14
|
+
white-space: nowrap;
|
|
15
|
+
justify-content: center;
|
|
16
|
+
outline: 2px solid transparent;
|
|
17
|
+
outline-offset: 2px;
|
|
18
|
+
transition: background-color var(--transition-normal), box-shadow var(--transition-normal);
|
|
19
|
+
border-radius: var(--border-radius-sm);
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
.button:disabled,
|
|
23
|
+
.button[disabled],
|
|
24
|
+
:global(.button):disabled,
|
|
25
|
+
:global(.button)[disabled] {
|
|
26
|
+
pointer-events: none;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
.button:focus,
|
|
30
|
+
.button:active,
|
|
31
|
+
:global(.button):focus,
|
|
32
|
+
:global(.button):active {
|
|
33
|
+
--ring-offset-color: var(--background);
|
|
34
|
+
--ring-offset-shadow: var(--ring-inset) 0 0 0 var(--ring-offset-width) var(--ring-offset-color);
|
|
35
|
+
--ring-shadow: var(--ring-inset) 0 0 0 calc(1px + var(--ring-offset-width)) var(--ring-color);
|
|
36
|
+
box-shadow: var(--ring-offset-shadow), var(--ring-shadow), var(--shadow, 0 0 #0000);
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
.button.square,
|
|
40
|
+
:global(.button-square) {
|
|
41
|
+
aspect-ratio: 1 / 1;
|
|
42
|
+
padding: 0;
|
|
43
|
+
border-radius: var(--border-radius-sm);
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
.button.round,
|
|
47
|
+
:global(.button-round) {
|
|
48
|
+
aspect-ratio: 1 / 1;
|
|
49
|
+
padding: 0;
|
|
50
|
+
border-radius: var(--border-radius-full);
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
/* Sizes */
|
|
54
|
+
.xs,
|
|
55
|
+
:global(.button-xs) {
|
|
56
|
+
min-height: 26px;
|
|
57
|
+
font-size: 0.7rem;
|
|
58
|
+
padding: 0.2rem 0.4rem;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
.sm,
|
|
62
|
+
:global(.button-sm) {
|
|
63
|
+
min-height: 32px;
|
|
64
|
+
font-size: 0.775rem;
|
|
65
|
+
padding: 0.25rem 0.5rem;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
.md,
|
|
69
|
+
:global(.button-md) {
|
|
70
|
+
min-height: 38px;
|
|
71
|
+
font-size: 0.95rem;
|
|
72
|
+
padding: 0.625rem 1.25rem;
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
.lg,
|
|
76
|
+
:global(.button-lg) {
|
|
77
|
+
min-height: 46px;
|
|
78
|
+
font-size: 1.1rem;
|
|
79
|
+
padding: 0.75rem 1.5rem;
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
.xl,
|
|
83
|
+
:global(.button-xl) {
|
|
84
|
+
min-height: 54px;
|
|
85
|
+
font-size: 1.2rem;
|
|
86
|
+
padding: 0.75rem 1.5rem;
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
/* Variants - Consuming Variables */
|
|
90
|
+
.filled,
|
|
91
|
+
:global(.button-filled) {
|
|
92
|
+
color: var(--button-variant-filled-foreground);
|
|
93
|
+
background-color: var(--button-variant-filled);
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
.filled:hover,
|
|
97
|
+
:global(.button-filled):hover {
|
|
98
|
+
background-color: var(--button-variant-filled-hover);
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
.filled:focus,
|
|
102
|
+
.filled:active,
|
|
103
|
+
:global(.button-filled):focus,
|
|
104
|
+
:global(.button-filled):active {
|
|
105
|
+
--ring-color: var(--button-ring-color);
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
.filled:disabled,
|
|
109
|
+
.filled[disabled],
|
|
110
|
+
:global(.button-filled):disabled,
|
|
111
|
+
:global(.button-filled)[disabled] {
|
|
112
|
+
background-color: var(--button-variant-filled-disabled, oklch(from var(--button-variant-filled) calc(l * 1.1) calc(c * 0.85) h));
|
|
113
|
+
color: var(--button-variant-filled-foreground-disabled, oklch(from var(--button-variant-filled-foreground) calc(l * 0.9) calc(c * 0.85) h));
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
.outlined,
|
|
117
|
+
:global(.button-outlined) {
|
|
118
|
+
border: 1px solid var(--button-variant-outlined-border);
|
|
119
|
+
color: var(--button-variant-outlined-foreground);
|
|
120
|
+
background-color: var(--button-variant-outlined);
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
.outlined:disabled,
|
|
124
|
+
.outlined[disabled],
|
|
125
|
+
:global(.button-outlined):disabled,
|
|
126
|
+
:global(.button-outlined)[disabled] {
|
|
127
|
+
border-color: var(--button-variant-outlined-border-disabled, oklch(from var(--button-variant-outlined-border) calc(l * 1.5) calc(c * 0.8) h));
|
|
128
|
+
color: var(--button-variant-outlined-foreground-disabled, oklch(from var(--button-variant-outlined-foreground) calc(l * 1.1) calc(c * 0.7) h));
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
.outlined:hover,
|
|
132
|
+
:global(.button-outlined):hover {
|
|
133
|
+
background-color: var(--button-variant-outlined-hover);
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
.outlined:focus,
|
|
137
|
+
.outlined:active,
|
|
138
|
+
:global(.button-outlined):focus,
|
|
139
|
+
:global(.button-outlined):active {
|
|
140
|
+
--ring-color: var(--button-ring-color);
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
.gradient,
|
|
144
|
+
:global(.button-gradient) {
|
|
145
|
+
color: var(--button-variant-gradient-foreground);
|
|
146
|
+
background: linear-gradient(45deg,
|
|
147
|
+
var(--button-variant-gradient-start),
|
|
148
|
+
var(--button-variant-gradient-end));
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
.gradient:disabled,
|
|
152
|
+
.gradient[disabled],
|
|
153
|
+
:global(.button-gradient):disabled,
|
|
154
|
+
:global(.button-gradient)[disabled] {
|
|
155
|
+
background: unset;
|
|
156
|
+
background-color: var(--button-variant-gradient-disabled, oklch(from var(--button-variant-gradient-end) calc(l * 1.2) calc(c * 0.85) h));
|
|
157
|
+
color: var(--button-variant-gradient-foreground-disabled, oklch(from var(--button-variant-gradient-foreground) calc(l * 0.9) calc(c * 0.85) h));
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
.gradient:hover,
|
|
161
|
+
:global(.button-gradient):hover {
|
|
162
|
+
color: var(--button-variant-gradient-foreground);
|
|
163
|
+
background: linear-gradient(45deg,
|
|
164
|
+
var(--button-variant-gradient-start),
|
|
165
|
+
var(--button-variant-gradient-end));
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
.gradient:focus,
|
|
169
|
+
.gradient:active,
|
|
170
|
+
:global(.button-gradient):focus,
|
|
171
|
+
:global(.button-gradient):active {
|
|
172
|
+
--ring-color: var(--button-ring-color);
|
|
173
|
+
}
|
|
174
|
+
|
|
175
|
+
.text,
|
|
176
|
+
:global(.button-text) {
|
|
177
|
+
background-color: var(--button-variant-text);
|
|
178
|
+
color: var(--button-variant-text-foreground);
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
.text:disabled,
|
|
182
|
+
.text[disabled],
|
|
183
|
+
:global(.button-text):disabled,
|
|
184
|
+
:global(.button-text)[disabled] {
|
|
185
|
+
color: oklch(from var(--button-variant-text-foreground) calc(l * 1.5) calc(c * 0.5) h);
|
|
186
|
+
}
|
|
187
|
+
|
|
188
|
+
.text:hover,
|
|
189
|
+
:global(.button-text):hover {
|
|
190
|
+
background-color: var(--button-variant-text-hover);
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
.text:focus,
|
|
194
|
+
.text:active,
|
|
195
|
+
:global(.button-text):focus,
|
|
196
|
+
:global(.button-text):active {
|
|
197
|
+
--ring-color: var(--button-ring-color);
|
|
198
|
+
}
|
|
199
|
+
|
|
200
|
+
/* Intents - Defining Variables */
|
|
201
|
+
.primary,
|
|
202
|
+
:global(.button-primary) {
|
|
203
|
+
--button-ring-color: var(--ring-primary);
|
|
204
|
+
|
|
205
|
+
/* Filled */
|
|
206
|
+
--button-variant-filled: var(--fill-primary-strong);
|
|
207
|
+
--button-variant-filled-foreground: var(--text-on-primary);
|
|
208
|
+
--button-variant-filled-hover: var(--fill-primary-strong-hover);
|
|
209
|
+
--button-variant-filled-disabled: var(--fill-primary-strong-disabled);
|
|
210
|
+
--button-variant-filled-foreground-disabled: var(--text-on-primary-disabled);
|
|
211
|
+
|
|
212
|
+
/* Outlined */
|
|
213
|
+
--button-variant-outlined: transparent;
|
|
214
|
+
--button-variant-outlined-foreground: var(--text-primary-strong);
|
|
215
|
+
--button-variant-outlined-hover: var(--fill-primary-weak);
|
|
216
|
+
--button-variant-outlined-border: var(--stroke-primary);
|
|
217
|
+
--button-variant-outlined-border-disabled: var(--stroke-primary-disabled);
|
|
218
|
+
--button-variant-outlined-foreground-disabled: var(--text-primary-disabled);
|
|
219
|
+
|
|
220
|
+
/* Text */
|
|
221
|
+
--button-variant-text: transparent;
|
|
222
|
+
--button-variant-text-foreground: var(--text-primary-weak);
|
|
223
|
+
--button-variant-text-hover: var(--fill-primary-weak-hover);
|
|
224
|
+
|
|
225
|
+
/* Gradient */
|
|
226
|
+
--button-variant-gradient-start: var(--gradient-primary-start);
|
|
227
|
+
--button-variant-gradient-end: var(--gradient-primary-end);
|
|
228
|
+
--button-variant-gradient-foreground: var(--gradient-primary-foreground);
|
|
229
|
+
--button-variant-gradient-disabled: var(--gradient-primary-disabled);
|
|
230
|
+
--button-variant-gradient-foreground-disabled: var(--text-on-primary-disabled);
|
|
231
|
+
}
|
|
232
|
+
|
|
233
|
+
.secondary,
|
|
234
|
+
:global(.button-secondary) {
|
|
235
|
+
--button-ring-color: var(--ring-secondary);
|
|
236
|
+
|
|
237
|
+
/* Filled */
|
|
238
|
+
--button-variant-filled: var(--fill-secondary-strong);
|
|
239
|
+
--button-variant-filled-foreground: var(--text-on-secondary);
|
|
240
|
+
--button-variant-filled-hover: var(--fill-secondary-strong-hover);
|
|
241
|
+
--button-variant-filled-disabled: var(--fill-secondary-strong-disabled);
|
|
242
|
+
--button-variant-filled-foreground-disabled: var(--text-on-secondary-disabled);
|
|
243
|
+
|
|
244
|
+
/* Outlined */
|
|
245
|
+
--button-variant-outlined: transparent;
|
|
246
|
+
--button-variant-outlined-foreground: var(--text-secondary-strong);
|
|
247
|
+
--button-variant-outlined-hover: var(--fill-secondary-weak);
|
|
248
|
+
--button-variant-outlined-border: var(--stroke-secondary);
|
|
249
|
+
--button-variant-outlined-border-disabled: var(--stroke-secondary-disabled);
|
|
250
|
+
--button-variant-outlined-foreground-disabled: var(--text-secondary-disabled);
|
|
251
|
+
|
|
252
|
+
/* Text */
|
|
253
|
+
--button-variant-text: transparent;
|
|
254
|
+
--button-variant-text-foreground: var(--text-secondary-weak);
|
|
255
|
+
--button-variant-text-hover: var(--fill-secondary-weak-hover);
|
|
256
|
+
|
|
257
|
+
/* Gradient */
|
|
258
|
+
--button-variant-gradient-start: var(--gradient-secondary-start);
|
|
259
|
+
--button-variant-gradient-end: var(--gradient-secondary-end);
|
|
260
|
+
--button-variant-gradient-foreground: var(--gradient-secondary-foreground);
|
|
261
|
+
--button-variant-gradient-disabled: var(--gradient-secondary-disabled);
|
|
262
|
+
--button-variant-gradient-foreground-disabled: var(--text-on-secondary-disabled);
|
|
263
|
+
}
|
|
264
|
+
|
|
265
|
+
.noeffect,
|
|
266
|
+
:global(.button-noeffect) {
|
|
267
|
+
--button-ring-color: var(--ring-noeffect);
|
|
268
|
+
|
|
269
|
+
/* Filled */
|
|
270
|
+
--button-variant-filled: var(--fill-noeffect-strong);
|
|
271
|
+
--button-variant-filled-foreground: var(--text-on-noeffect);
|
|
272
|
+
--button-variant-filled-hover: var(--fill-noeffect-strong-hover);
|
|
273
|
+
--button-variant-filled-disabled: var(--fill-noeffect-strong-disabled);
|
|
274
|
+
--button-variant-filled-foreground-disabled: var(--text-on-noeffect-disabled);
|
|
275
|
+
|
|
276
|
+
/* Outlined */
|
|
277
|
+
--button-variant-outlined: transparent;
|
|
278
|
+
--button-variant-outlined-foreground: var(--text-noeffect-strong);
|
|
279
|
+
--button-variant-outlined-hover: var(--fill-noeffect-weak);
|
|
280
|
+
--button-variant-outlined-border: var(--stroke-noeffect);
|
|
281
|
+
--button-variant-outlined-border-disabled: var(--stroke-noeffect-disabled);
|
|
282
|
+
--button-variant-outlined-foreground-disabled: var(--text-noeffect-disabled);
|
|
283
|
+
|
|
284
|
+
/* Text */
|
|
285
|
+
--button-variant-text: transparent;
|
|
286
|
+
--button-variant-text-foreground: var(--text-noeffect-weak);
|
|
287
|
+
--button-variant-text-hover: var(--fill-noeffect-weak-hover);
|
|
288
|
+
|
|
289
|
+
/* Gradient */
|
|
290
|
+
--button-variant-gradient-start: var(--gradient-noeffect-start);
|
|
291
|
+
--button-variant-gradient-end: var(--gradient-noeffect-end);
|
|
292
|
+
--button-variant-gradient-foreground: var(--gradient-noeffect-foreground);
|
|
293
|
+
--button-variant-gradient-disabled: var(--gradient-noeffect-disabled);
|
|
294
|
+
--button-variant-gradient-foreground-disabled: var(--text-on-noeffect-disabled);
|
|
295
|
+
}
|
|
296
|
+
|
|
297
|
+
.success,
|
|
298
|
+
:global(.button-success) {
|
|
299
|
+
--button-ring-color: var(--ring-success);
|
|
300
|
+
|
|
301
|
+
/* Filled */
|
|
302
|
+
--button-variant-filled: var(--fill-success-strong);
|
|
303
|
+
--button-variant-filled-foreground: var(--text-on-success);
|
|
304
|
+
--button-variant-filled-hover: var(--fill-success-strong-hover);
|
|
305
|
+
--button-variant-filled-disabled: var(--fill-success-strong-disabled);
|
|
306
|
+
--button-variant-filled-foreground-disabled: var(--text-on-success-disabled);
|
|
307
|
+
|
|
308
|
+
/* Outlined */
|
|
309
|
+
--button-variant-outlined: transparent;
|
|
310
|
+
--button-variant-outlined-foreground: var(--text-success-strong);
|
|
311
|
+
--button-variant-outlined-hover: var(--fill-success-weak);
|
|
312
|
+
--button-variant-outlined-border: var(--stroke-success);
|
|
313
|
+
--button-variant-outlined-border-disabled: var(--stroke-success-disabled);
|
|
314
|
+
--button-variant-outlined-foreground-disabled: var(--text-success-disabled);
|
|
315
|
+
|
|
316
|
+
/* Text */
|
|
317
|
+
--button-variant-text: transparent;
|
|
318
|
+
--button-variant-text-foreground: var(--text-success-weak);
|
|
319
|
+
--button-variant-text-hover: var(--fill-success-weak-hover);
|
|
320
|
+
|
|
321
|
+
/* Gradient */
|
|
322
|
+
--button-variant-gradient-start: var(--gradient-success-start);
|
|
323
|
+
--button-variant-gradient-end: var(--gradient-success-end);
|
|
324
|
+
--button-variant-gradient-foreground: var(--gradient-success-foreground);
|
|
325
|
+
--button-variant-gradient-disabled: var(--gradient-success-disabled);
|
|
326
|
+
--button-variant-gradient-foreground-disabled: var(--text-on-success-disabled);
|
|
327
|
+
}
|
|
328
|
+
|
|
329
|
+
.info,
|
|
330
|
+
:global(.button-info) {
|
|
331
|
+
--button-ring-color: var(--ring-info);
|
|
332
|
+
|
|
333
|
+
/* Filled */
|
|
334
|
+
--button-variant-filled: var(--fill-info-strong);
|
|
335
|
+
--button-variant-filled-foreground: var(--text-on-info);
|
|
336
|
+
--button-variant-filled-hover: var(--fill-info-strong-hover);
|
|
337
|
+
--button-variant-filled-disabled: var(--fill-info-strong-disabled);
|
|
338
|
+
--button-variant-filled-foreground-disabled: var(--text-on-info-disabled);
|
|
339
|
+
|
|
340
|
+
/* Outlined */
|
|
341
|
+
--button-variant-outlined: transparent;
|
|
342
|
+
--button-variant-outlined-foreground: var(--text-info-strong);
|
|
343
|
+
--button-variant-outlined-hover: var(--fill-info-weak);
|
|
344
|
+
--button-variant-outlined-border: var(--stroke-info);
|
|
345
|
+
--button-variant-outlined-border-disabled: var(--stroke-info-disabled);
|
|
346
|
+
--button-variant-outlined-foreground-disabled: var(--text-info-disabled);
|
|
347
|
+
|
|
348
|
+
/* Text */
|
|
349
|
+
--button-variant-text: transparent;
|
|
350
|
+
--button-variant-text-foreground: var(--text-info-weak);
|
|
351
|
+
--button-variant-text-hover: var(--fill-info-weak-hover);
|
|
352
|
+
|
|
353
|
+
/* Gradient */
|
|
354
|
+
--button-variant-gradient-start: var(--gradient-info-start);
|
|
355
|
+
--button-variant-gradient-end: var(--gradient-info-end);
|
|
356
|
+
--button-variant-gradient-foreground: var(--gradient-info-foreground);
|
|
357
|
+
--button-variant-gradient-disabled: var(--gradient-info-disabled);
|
|
358
|
+
--button-variant-gradient-foreground-disabled: var(--text-on-info-disabled);
|
|
359
|
+
}
|
|
360
|
+
|
|
361
|
+
.warning,
|
|
362
|
+
:global(.button-warning) {
|
|
363
|
+
--button-ring-color: var(--ring-warning);
|
|
364
|
+
|
|
365
|
+
/* Filled */
|
|
366
|
+
--button-variant-filled: var(--fill-warning-strong);
|
|
367
|
+
--button-variant-filled-foreground: var(--text-on-warning);
|
|
368
|
+
--button-variant-filled-hover: var(--fill-warning-strong-hover);
|
|
369
|
+
--button-variant-filled-disabled: var(--fill-warning-strong-disabled);
|
|
370
|
+
--button-variant-filled-foreground-disabled: var(--text-on-warning-disabled);
|
|
371
|
+
|
|
372
|
+
/* Outlined */
|
|
373
|
+
--button-variant-outlined: transparent;
|
|
374
|
+
--button-variant-outlined-foreground: var(--text-warning-strong);
|
|
375
|
+
--button-variant-outlined-hover: var(--fill-warning-weak);
|
|
376
|
+
--button-variant-outlined-border: var(--stroke-warning);
|
|
377
|
+
--button-variant-outlined-border-disabled: var(--stroke-warning-disabled);
|
|
378
|
+
--button-variant-outlined-foreground-disabled: var(--text-warning-disabled);
|
|
379
|
+
|
|
380
|
+
/* Text */
|
|
381
|
+
--button-variant-text: transparent;
|
|
382
|
+
--button-variant-text-foreground: var(--text-warning-weak);
|
|
383
|
+
--button-variant-text-hover: var(--fill-warning-weak-hover);
|
|
384
|
+
|
|
385
|
+
/* Gradient */
|
|
386
|
+
--button-variant-gradient-start: var(--gradient-warning-start);
|
|
387
|
+
--button-variant-gradient-end: var(--gradient-warning-end);
|
|
388
|
+
--button-variant-gradient-foreground: var(--gradient-warning-foreground);
|
|
389
|
+
--button-variant-gradient-disabled: var(--gradient-warning-disabled);
|
|
390
|
+
--button-variant-gradient-foreground-disabled: var(--text-on-warning-disabled);
|
|
391
|
+
}
|
|
392
|
+
|
|
393
|
+
.danger,
|
|
394
|
+
:global(.button-danger) {
|
|
395
|
+
--button-ring-color: var(--ring-danger);
|
|
396
|
+
|
|
397
|
+
/* Filled */
|
|
398
|
+
--button-variant-filled: var(--fill-danger-strong);
|
|
399
|
+
--button-variant-filled-foreground: var(--text-on-danger);
|
|
400
|
+
--button-variant-filled-hover: var(--fill-danger-strong-hover);
|
|
401
|
+
--button-variant-filled-disabled: var(--fill-danger-strong-disabled);
|
|
402
|
+
--button-variant-filled-foreground-disabled: var(--text-on-danger-disabled);
|
|
403
|
+
|
|
404
|
+
/* Outlined */
|
|
405
|
+
--button-variant-outlined: transparent;
|
|
406
|
+
--button-variant-outlined-foreground: var(--text-danger-strong);
|
|
407
|
+
--button-variant-outlined-hover: var(--fill-danger-weak);
|
|
408
|
+
--button-variant-outlined-border: var(--stroke-danger);
|
|
409
|
+
--button-variant-outlined-border-disabled: var(--stroke-danger-disabled);
|
|
410
|
+
--button-variant-outlined-foreground-disabled: var(--text-danger-disabled);
|
|
411
|
+
|
|
412
|
+
/* Text */
|
|
413
|
+
--button-variant-text: transparent;
|
|
414
|
+
--button-variant-text-foreground: var(--text-danger-weak);
|
|
415
|
+
--button-variant-text-hover: var(--fill-danger-weak-hover);
|
|
416
|
+
|
|
417
|
+
/* Gradient */
|
|
418
|
+
--button-variant-gradient-start: var(--gradient-danger-start);
|
|
419
|
+
--button-variant-gradient-end: var(--gradient-danger-end);
|
|
420
|
+
--button-variant-gradient-foreground: var(--gradient-danger-foreground);
|
|
421
|
+
--button-variant-gradient-disabled: var(--gradient-danger-disabled);
|
|
422
|
+
--button-variant-gradient-foreground-disabled: var(--text-on-danger-disabled);
|
|
423
|
+
}
|
|
424
|
+
|
|
425
|
+
/* Full width */
|
|
426
|
+
.fullWidth,
|
|
427
|
+
:global(.button-full-width) {
|
|
428
|
+
width: 100%;
|
|
429
|
+
display: flex;
|
|
430
|
+
}
|
|
431
|
+
}
|
|
@@ -0,0 +1,132 @@
|
|
|
1
|
+
@layer infonomic-base, infonomic-utilities, infonomic-theme, infonomic-components;
|
|
2
|
+
|
|
3
|
+
@layer infonomic-components {
|
|
4
|
+
|
|
5
|
+
.stop-button,
|
|
6
|
+
.play-button,
|
|
7
|
+
.directional-button {
|
|
8
|
+
display: flex;
|
|
9
|
+
align-items: center;
|
|
10
|
+
justify-content: center;
|
|
11
|
+
text-decoration: none;
|
|
12
|
+
border-style: none;
|
|
13
|
+
border-radius: 100%;
|
|
14
|
+
padding: 0;
|
|
15
|
+
margin: 0;
|
|
16
|
+
outline: none;
|
|
17
|
+
color: white;
|
|
18
|
+
background-color: var(--fill-primary-strong);
|
|
19
|
+
transition-property: all, color;
|
|
20
|
+
transition-duration: 0.3s, 1ms;
|
|
21
|
+
transition-timing-function: cubic-bezier(0.25, 0.8, 0.5, 1), ease;
|
|
22
|
+
transition-delay: 0s, 0s;
|
|
23
|
+
cursor: pointer;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
.directional-button span {
|
|
27
|
+
width: 40%;
|
|
28
|
+
padding-bottom: 3px;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
.play-button span {
|
|
32
|
+
width: 80%;
|
|
33
|
+
height: 80%;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
.stop-button span {
|
|
37
|
+
width: 50%;
|
|
38
|
+
height: 50%;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
.directional-button span .icon path {
|
|
42
|
+
stroke: none;
|
|
43
|
+
fill: white;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
.stop-button:hover,
|
|
47
|
+
.play-button:hover,
|
|
48
|
+
.stop-button:focus,
|
|
49
|
+
.play-button:focus,
|
|
50
|
+
.directional-button:hover,
|
|
51
|
+
.directional-button:focus {
|
|
52
|
+
color: white;
|
|
53
|
+
background-color: var(--fill-primary-strong-hover);
|
|
54
|
+
transform: translateY(-5px);
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
/* Sizes */
|
|
58
|
+
.xs {
|
|
59
|
+
width: 20px;
|
|
60
|
+
min-width: 20px;
|
|
61
|
+
height: 20px;
|
|
62
|
+
min-height: 20px;
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
.sm {
|
|
66
|
+
width: 30px;
|
|
67
|
+
min-width: 30px;
|
|
68
|
+
height: 30px;
|
|
69
|
+
min-height: 30px;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
.md {
|
|
73
|
+
width: 40px;
|
|
74
|
+
min-width: 40px;
|
|
75
|
+
height: 40px;
|
|
76
|
+
min-height: 40px;
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
.lg {
|
|
80
|
+
width: 50px;
|
|
81
|
+
min-width: 50px;
|
|
82
|
+
height: 50px;
|
|
83
|
+
min-height: 50px;
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
.xl {
|
|
87
|
+
width: 40px;
|
|
88
|
+
min-width: 40px;
|
|
89
|
+
height: 40px;
|
|
90
|
+
min-height: 40px;
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
/* Up is default so no need to rotate */
|
|
94
|
+
.up:hover,
|
|
95
|
+
.up:focus {
|
|
96
|
+
transform: translateY(-5px);
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
.down span,
|
|
100
|
+
.down span {
|
|
101
|
+
transform: rotate(180deg);
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
.down:hover,
|
|
105
|
+
.down:focus {
|
|
106
|
+
transform: translateY(5px);
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
.left span,
|
|
110
|
+
.left span {
|
|
111
|
+
transform: rotate(-90deg);
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
.left:hover,
|
|
115
|
+
.left:focus {
|
|
116
|
+
transform: translateX(-5px);
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
.right span,
|
|
120
|
+
.right span {
|
|
121
|
+
transform: rotate(90deg);
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
.right:hover,
|
|
125
|
+
.right:focus {
|
|
126
|
+
transform: translateX(5px);
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
/* No dark theme overrides needed!
|
|
130
|
+
* Tokens automatically switch in .dark and respect .not-dark
|
|
131
|
+
*/
|
|
132
|
+
}
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
@layer infonomic-base, infonomic-functional, infonomic-utilities, infonomic-theme, infonomic-typography, infonomic-components;
|
|
2
|
+
|
|
3
|
+
@layer infonomic-components {
|
|
4
|
+
.copy-button-container,
|
|
5
|
+
:global(.copy-button-container) {
|
|
6
|
+
display: inline-block;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
.copy-button svg,
|
|
10
|
+
:global(.copy-button) svg {
|
|
11
|
+
width: 90%;
|
|
12
|
+
height: 90%;
|
|
13
|
+
display: block;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
/* Sizes */
|
|
17
|
+
.xs,
|
|
18
|
+
:global(.copy-button-xs) {
|
|
19
|
+
width: 26px;
|
|
20
|
+
height: 26px;
|
|
21
|
+
min-height: 26px;
|
|
22
|
+
padding: 0.25rem;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
.sm,
|
|
26
|
+
:global(.copy-button-sm) {
|
|
27
|
+
width: 32px;
|
|
28
|
+
height: 32px;
|
|
29
|
+
min-height: 32px;
|
|
30
|
+
padding: 0.35rem;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
.md,
|
|
34
|
+
:global(.copy-button-md) {
|
|
35
|
+
width: 38px;
|
|
36
|
+
height: 38px;
|
|
37
|
+
min-height: 38px;
|
|
38
|
+
padding: 0.45rem;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
.lg,
|
|
42
|
+
:global(.copy-button-lg) {
|
|
43
|
+
width: 46px;
|
|
44
|
+
height: 46px;
|
|
45
|
+
min-height: 46px;
|
|
46
|
+
padding: 0.55rem;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
.xl,
|
|
50
|
+
:global(.copy-button-xl) {
|
|
51
|
+
width: 54px;
|
|
52
|
+
height: 54px;
|
|
53
|
+
min-height: 54px;
|
|
54
|
+
padding: 0.65rem;
|
|
55
|
+
}
|
|
56
|
+
}
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
---
|
|
2
|
+
import type { HTMLAttributes } from 'astro/types'
|
|
3
|
+
import type { Intent, Size, Variant } from './@types/button.js'
|
|
4
|
+
import Button from './button.astro'
|
|
5
|
+
|
|
6
|
+
import styles from './button.module.css'
|
|
7
|
+
|
|
8
|
+
interface Props extends HTMLAttributes<'button'>, Omit<HTMLAttributes<'a'>, 'type'> {
|
|
9
|
+
variant?: Variant
|
|
10
|
+
size?: Size
|
|
11
|
+
type?: 'submit' | 'reset' | 'button'
|
|
12
|
+
intent?: Intent
|
|
13
|
+
fullWidth?: boolean
|
|
14
|
+
ripple?: boolean
|
|
15
|
+
class?: string
|
|
16
|
+
as?: 'button' | 'a'
|
|
17
|
+
href?: string
|
|
18
|
+
square?: boolean
|
|
19
|
+
round?: boolean
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
const {
|
|
23
|
+
square = false,
|
|
24
|
+
round = true,
|
|
25
|
+
variant,
|
|
26
|
+
size,
|
|
27
|
+
type,
|
|
28
|
+
intent,
|
|
29
|
+
class: className,
|
|
30
|
+
...rest
|
|
31
|
+
} = Astro.props as Props
|
|
32
|
+
---
|
|
33
|
+
|
|
34
|
+
<Button
|
|
35
|
+
class:list={[
|
|
36
|
+
'icon-button',
|
|
37
|
+
variant,
|
|
38
|
+
size,
|
|
39
|
+
intent,
|
|
40
|
+
{ [styles.square]: square },
|
|
41
|
+
{ [styles.round]: !square && round },
|
|
42
|
+
className
|
|
43
|
+
]}
|
|
44
|
+
{...rest}
|
|
45
|
+
>
|
|
46
|
+
<slot />
|
|
47
|
+
</Button>
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
---
|
|
2
|
+
import type { HTMLAttributes } from 'astro/types'
|
|
3
|
+
interface Props extends HTMLAttributes<'div'> {
|
|
4
|
+
class?: string
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
import styles from './card.module.css'
|
|
8
|
+
|
|
9
|
+
const { class: className, ...rest } = Astro.props as Props
|
|
10
|
+
---
|
|
11
|
+
|
|
12
|
+
<div class:list={[styles['card-content'], className]} {...rest}>
|
|
13
|
+
<slot />
|
|
14
|
+
</div>
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
---
|
|
2
|
+
import type { HTMLAttributes } from 'astro/types'
|
|
3
|
+
interface Props extends HTMLAttributes<'div'> {
|
|
4
|
+
class?: string
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
import styles from './card.module.css'
|
|
8
|
+
|
|
9
|
+
const { class: className, ...rest } = Astro.props as Props
|
|
10
|
+
---
|
|
11
|
+
|
|
12
|
+
<div class:list={[styles['card-description'], className]} {...rest}>
|
|
13
|
+
<slot />
|
|
14
|
+
</div>
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
---
|
|
2
|
+
import type { HTMLAttributes } from 'astro/types'
|
|
3
|
+
interface Props extends HTMLAttributes<'div'> {
|
|
4
|
+
class?: string
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
import styles from './card.module.css'
|
|
8
|
+
|
|
9
|
+
const { class: className, ...rest } = Astro.props as Props
|
|
10
|
+
---
|
|
11
|
+
|
|
12
|
+
<div class:list={[styles['card-footer'], className]} {...rest}>
|
|
13
|
+
<slot />
|
|
14
|
+
</div>
|