@cratis/components 4.10.4 → 4.11.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.
@@ -0,0 +1,1827 @@
1
+ @layer cratis-components {
2
+ /* @cratis/components/DataPage/styles — requires @cratis/components/styles/base. Areas: Common, DataPage, DataTables, Dropdown, Notifications. */
3
+ /* ── allotment/dist/style.css ─────────────────────────────────────── */
4
+ :root {
5
+ --separator-border: rgba(128, 128, 128, 0.35);
6
+ --sash-hover-transition-duration: 0.1s;
7
+ }
8
+
9
+ .allotment-module_splitView__L-yRc {
10
+ height: 100%;
11
+ overflow: hidden;
12
+ position: relative;
13
+ width: 100%;
14
+ }
15
+
16
+ .allotment-module_splitView__L-yRc > .allotment-module_sashContainer__fzwJF {
17
+ height: 100%;
18
+ pointer-events: none;
19
+ position: absolute;
20
+ width: 100%;
21
+ }
22
+
23
+ .allotment-module_splitView__L-yRc > .allotment-module_sashContainer__fzwJF > .allotment-module_sash__QA-2t {
24
+ pointer-events: auto;
25
+ }
26
+
27
+ .allotment-module_splitView__L-yRc > .allotment-module_splitViewContainer__rQnVa {
28
+ height: 100%;
29
+ position: relative;
30
+ white-space: nowrap;
31
+ width: 100%;
32
+ }
33
+
34
+ .allotment-module_splitView__L-yRc > .allotment-module_splitViewContainer__rQnVa > .allotment-module_splitViewView__MGZ6O {
35
+ overflow: hidden;
36
+ position: absolute;
37
+ white-space: initial;
38
+ }
39
+
40
+ .allotment-module_splitView__L-yRc.allotment-module_vertical__WSwwa > .allotment-module_splitViewContainer__rQnVa > .allotment-module_splitViewView__MGZ6O {
41
+ width: 100%;
42
+ }
43
+
44
+ .allotment-module_splitView__L-yRc.allotment-module_horizontal__7doS8 > .allotment-module_splitViewContainer__rQnVa > .allotment-module_splitViewView__MGZ6O {
45
+ height: 100%;
46
+ }
47
+
48
+ .allotment-module_splitView__L-yRc.allotment-module_separatorBorder__x-rDS
49
+ > .allotment-module_splitViewContainer__rQnVa
50
+ > .allotment-module_splitViewView__MGZ6O:not(:first-child)::before {
51
+ background-color: var(--separator-border);
52
+ content: " ";
53
+ left: 0;
54
+ pointer-events: none;
55
+ position: absolute;
56
+ top: 0;
57
+ z-index: 5;
58
+ }
59
+
60
+ .allotment-module_splitView__L-yRc.allotment-module_separatorBorder__x-rDS.allotment-module_vertical__WSwwa
61
+ > .allotment-module_splitViewContainer__rQnVa
62
+ > .allotment-module_splitViewView__MGZ6O:not(:first-child)::before {
63
+ height: 1px;
64
+ width: 100%;
65
+ }
66
+
67
+ .allotment-module_splitView__L-yRc.allotment-module_separatorBorder__x-rDS.allotment-module_horizontal__7doS8
68
+ > .allotment-module_splitViewContainer__rQnVa
69
+ > .allotment-module_splitViewView__MGZ6O:not(:first-child)::before {
70
+ height: 100%;
71
+ width: 1px;
72
+ }
73
+
74
+ :root {
75
+ --focus-border: #007fd4;
76
+ --sash-size: 8px;
77
+ --sash-hover-size: 4px;
78
+ }
79
+
80
+ .sash-module_sash__K-9lB {
81
+ position: absolute;
82
+ z-index: 35;
83
+ touch-action: none;
84
+ pointer-events: auto;
85
+ text-align: initial;
86
+ }
87
+
88
+ .sash-module_sash__K-9lB.sash-module_disabled__Hm-wx {
89
+ pointer-events: none;
90
+ }
91
+
92
+ .sash-module_sash__K-9lB.sash-module_mac__Jf6OJ.sash-module_vertical__pB-rs {
93
+ cursor: col-resize;
94
+ }
95
+
96
+ .sash-module_sash__K-9lB.sash-module_vertical__pB-rs.sash-module_minimum__-UKxp {
97
+ cursor: e-resize;
98
+ }
99
+
100
+ .sash-module_sash__K-9lB.sash-module_vertical__pB-rs.sash-module_maximum__TCWxD {
101
+ cursor: w-resize;
102
+ }
103
+
104
+ .sash-module_sash__K-9lB.sash-module_mac__Jf6OJ.sash-module_horizontal__kFbiw {
105
+ cursor: row-resize;
106
+ }
107
+
108
+ .sash-module_sash__K-9lB.sash-module_horizontal__kFbiw.sash-module_minimum__-UKxp {
109
+ cursor: s-resize;
110
+ }
111
+
112
+ .sash-module_sash__K-9lB.sash-module_horizontal__kFbiw.sash-module_maximum__TCWxD {
113
+ cursor: n-resize;
114
+ }
115
+
116
+ .sash-module_sash__K-9lB.sash-module_disabled__Hm-wx {
117
+ cursor: default !important;
118
+ pointer-events: none !important;
119
+ }
120
+
121
+ .sash-module_sash__K-9lB.sash-module_vertical__pB-rs {
122
+ cursor: ew-resize;
123
+ top: 0;
124
+ width: var(--sash-size);
125
+ height: 100%;
126
+ }
127
+
128
+ .sash-module_sash__K-9lB.sash-module_horizontal__kFbiw {
129
+ cursor: ns-resize;
130
+ left: 0;
131
+ width: 100%;
132
+ height: var(--sash-size);
133
+ }
134
+
135
+ .sash-module_sash__K-9lB:not(.sash-module_disabled__Hm-wx) > .sash-module_orthogonal-drag-handle__Yii2- {
136
+ content: " ";
137
+ height: calc(var(--sash-size) * 2);
138
+ width: calc(var(--sash-size) * 2);
139
+ z-index: 100;
140
+ display: block;
141
+ cursor: all-scroll;
142
+ position: absolute;
143
+ }
144
+
145
+ .sash-module_sash__K-9lB.sash-module_horizontal__kFbiw.sash-module_orthogonal-edge-north__f7Noe:not(.sash-module_disabled__Hm-wx)
146
+ > .sash-module_orthogonal-drag-handle__Yii2-.sash-module_start__uZEDk,
147
+ .sash-module_sash__K-9lB.sash-module_horizontal__kFbiw.sash-module_orthogonal-edge-south__6ZrFC:not(.sash-module_disabled__Hm-wx)
148
+ > .sash-module_orthogonal-drag-handle__Yii2-.sash-module_end__0TP-R {
149
+ cursor: nwse-resize;
150
+ }
151
+
152
+ .sash-module_sash__K-9lB.sash-module_horizontal__kFbiw.sash-module_orthogonal-edge-north__f7Noe:not(.sash-module_disabled__Hm-wx)
153
+ > .sash-module_orthogonal-drag-handle__Yii2-.sash-module_end__0TP-R,
154
+ .sash-module_sash__K-9lB.sash-module_horizontal__kFbiw.sash-module_orthogonal-edge-south__6ZrFC:not(.sash-module_disabled__Hm-wx)
155
+ > .sash-module_orthogonal-drag-handle__Yii2-.sash-module_start__uZEDk {
156
+ cursor: nesw-resize;
157
+ }
158
+
159
+ .sash-module_sash__K-9lB.sash-module_vertical__pB-rs > .sash-module_orthogonal-drag-handle__Yii2-.sash-module_start__uZEDk {
160
+ left: calc(var(--sash-size) * -0.5);
161
+ top: calc(var(--sash-size) * -1);
162
+ }
163
+
164
+ .sash-module_sash__K-9lB.sash-module_vertical__pB-rs > .sash-module_orthogonal-drag-handle__Yii2-.sash-module_end__0TP-R {
165
+ left: calc(var(--sash-size) * -0.5);
166
+ bottom: calc(var(--sash-size) * -1);
167
+ }
168
+
169
+ .sash-module_sash__K-9lB.sash-module_horizontal__kFbiw > .sash-module_orthogonal-drag-handle__Yii2-.sash-module_start__uZEDk {
170
+ top: calc(var(--sash-size) * -0.5);
171
+ left: calc(var(--sash-size) * -1);
172
+ }
173
+
174
+ .sash-module_sash__K-9lB.sash-module_horizontal__kFbiw > .sash-module_orthogonal-drag-handle__Yii2-.sash-module_end__0TP-R {
175
+ top: calc(var(--sash-size) * -0.5);
176
+ right: calc(var(--sash-size) * -1);
177
+ }
178
+
179
+ .sash-module_sash__K-9lB:before {
180
+ content: "";
181
+ pointer-events: none;
182
+ position: absolute;
183
+ width: 100%;
184
+ height: 100%;
185
+ transition: background-color var(--sash-hover-transition-duration) ease-out;
186
+ background: transparent;
187
+ }
188
+
189
+ .sash-module_sash__K-9lB.sash-module_vertical__pB-rs:before {
190
+ width: var(--sash-hover-size);
191
+ left: calc(50% - (var(--sash-hover-size) / 2));
192
+ }
193
+
194
+ .sash-module_sash__K-9lB.sash-module_horizontal__kFbiw:before {
195
+ height: var(--sash-hover-size);
196
+ top: calc(50% - (var(--sash-hover-size) / 2));
197
+ }
198
+
199
+ .sash-module_sash__K-9lB.sash-module_hover__80W6I:before,
200
+ .sash-module_sash__K-9lB.sash-module_active__bJspD:before {
201
+ background: var(--focus-border);
202
+ }
203
+
204
+ /* ── ./Common/ActionMenubar.css ─────────────────────────────────────── */
205
+ /* Copyright (c) Cratis. All rights reserved. */
206
+ /* Licensed under the MIT license. See LICENSE file in the project root for full license information. */
207
+
208
+ .cratis-action-menubar {
209
+ display: flex;
210
+ align-items: center;
211
+ gap: 0.25rem;
212
+ flex-wrap: wrap;
213
+ }
214
+
215
+ /* ── ./Common/Button.css ─────────────────────────────────────── */
216
+ /* Copyright (c) Cratis. All rights reserved. */
217
+ /* Licensed under the MIT license. See LICENSE file in the project root for full license information. */
218
+
219
+ .cratis-button {
220
+ display: inline-flex;
221
+ box-sizing: border-box;
222
+ min-height: var(--cratis-control-height);
223
+ padding: 0.75rem 1.25rem;
224
+ align-items: center;
225
+ justify-content: center;
226
+ gap: 0.45rem;
227
+ border: 1px solid var(--cratis-action-background);
228
+ border-radius: var(--cratis-border-radius);
229
+ background: var(--cratis-action-background);
230
+ color: var(--cratis-action-text);
231
+ font: inherit;
232
+ font-weight: 600;
233
+ line-height: 1;
234
+ cursor: pointer;
235
+ transition:
236
+ background-color 140ms ease,
237
+ border-color 140ms ease,
238
+ color 140ms ease,
239
+ opacity 140ms ease;
240
+ }
241
+ .cratis-button:not([data-tone])[data-variant='solid']:hover:not(:disabled) {
242
+ border-color: var(--cratis-action-background-hover);
243
+ background: var(--cratis-action-background-hover);
244
+ }
245
+ .cratis-button:not([data-tone])[data-variant='solid']:active:not(:disabled) {
246
+ border-color: var(--cratis-action-background-active);
247
+ background: var(--cratis-action-background-active);
248
+ }
249
+ .cratis-button:is([data-variant='outline'], [data-variant='ghost']):hover:not(:disabled) {
250
+ background: color-mix(in srgb, currentColor 4%, transparent);
251
+ }
252
+ .cratis-button:is([data-variant='outline'], [data-variant='ghost']):active:not(
253
+ :disabled
254
+ ) {
255
+ background: color-mix(in srgb, currentColor 16%, transparent);
256
+ }
257
+ .cratis-button:focus-visible {
258
+ outline: none;
259
+ box-shadow: var(--cratis-focus-ring);
260
+ }
261
+ .cratis-button:disabled {
262
+ cursor: not-allowed;
263
+ opacity: var(--cratis-disabled-opacity);
264
+ }
265
+ .cratis-button[data-size='small'] {
266
+ min-height: var(--cratis-control-height-small);
267
+ padding: 0.5rem 0.75rem;
268
+ font-size: 0.8rem;
269
+ }
270
+ .cratis-button[data-size='large'] {
271
+ min-height: var(--cratis-control-height-large);
272
+ padding: 0.875rem 1.5rem;
273
+ font-size: 1rem;
274
+ }
275
+ .cratis-button[data-shape='pill'],
276
+ .cratis-button[data-icon-only='true'] {
277
+ border-radius: 999px;
278
+ }
279
+ .cratis-button[data-icon-only='true'] {
280
+ width: var(--cratis-control-height);
281
+ padding: 0;
282
+ }
283
+ .cratis-button[data-size='small'][data-icon-only='true'] {
284
+ width: var(--cratis-control-height-small);
285
+ }
286
+ .cratis-button[data-size='large'][data-icon-only='true'] {
287
+ width: var(--cratis-control-height-large);
288
+ }
289
+
290
+ .cratis-button[data-variant='outline'] {
291
+ border-color: currentColor;
292
+ background: transparent;
293
+ color: var(--cratis-primary-color);
294
+ }
295
+ .cratis-button[data-variant='ghost'] {
296
+ border-color: transparent;
297
+ background: transparent;
298
+ color: var(--cratis-text-color);
299
+ }
300
+ .cratis-button[data-variant='link'] {
301
+ min-height: auto;
302
+ padding: 0;
303
+ border-color: transparent;
304
+ background: transparent;
305
+ color: var(--cratis-primary-color);
306
+ text-decoration: underline;
307
+ }
308
+
309
+ .cratis-button[data-tone='neutral'] {
310
+ --cratis-button-tone: var(--cratis-text-color);
311
+ --cratis-button-fill: var(--cratis-surface-100);
312
+ --cratis-button-fill-text: var(--cratis-text-color);
313
+ }
314
+ .cratis-button[data-tone='accent'] {
315
+ --cratis-button-tone: var(--cratis-info-background);
316
+ --cratis-button-fill: var(--cratis-info-background);
317
+ --cratis-button-fill-text: var(--cratis-info-text);
318
+ }
319
+ .cratis-button[data-tone='positive'] {
320
+ --cratis-button-tone: var(--cratis-success-background);
321
+ --cratis-button-fill: var(--cratis-success-background);
322
+ --cratis-button-fill-text: var(--cratis-success-text);
323
+ }
324
+ .cratis-button[data-tone='caution'] {
325
+ --cratis-button-tone: var(--cratis-warning-background);
326
+ --cratis-button-fill: var(--cratis-warning-background);
327
+ --cratis-button-fill-text: var(--cratis-warning-text);
328
+ }
329
+ .cratis-button[data-tone='critical'] {
330
+ --cratis-button-tone: var(--cratis-danger-background);
331
+ --cratis-button-fill: var(--cratis-danger-background);
332
+ --cratis-button-fill-text: var(--cratis-danger-text);
333
+ }
334
+ .cratis-button[data-tone='accent'][data-severity='help'] {
335
+ --cratis-button-tone: var(--cratis-primary-600);
336
+ --cratis-button-fill: var(--cratis-primary-600);
337
+ --cratis-button-fill-text: var(--cratis-primary-600-text);
338
+ }
339
+ .cratis-button[data-tone='neutral'][data-severity='contrast'] {
340
+ --cratis-button-tone: var(--cratis-text-color);
341
+ --cratis-button-fill: var(--cratis-text-color);
342
+ --cratis-button-fill-text: var(--cratis-surface-0);
343
+ }
344
+ .cratis-button[data-tone][data-variant='solid'] {
345
+ border-color: var(--cratis-button-fill);
346
+ background: var(--cratis-button-fill);
347
+ color: var(--cratis-button-fill-text);
348
+ }
349
+ .cratis-button[data-tone][data-variant='solid']:hover:not(:disabled) {
350
+ border-color: color-mix(in srgb, var(--cratis-button-fill) 88%, black);
351
+ background: color-mix(in srgb, var(--cratis-button-fill) 88%, black);
352
+ }
353
+ .cratis-button[data-tone][data-variant='solid']:active:not(:disabled) {
354
+ border-color: color-mix(in srgb, var(--cratis-button-fill) 76%, black);
355
+ background: color-mix(in srgb, var(--cratis-button-fill) 76%, black);
356
+ }
357
+ .cratis-button[data-tone]:is(
358
+ [data-variant='outline'],
359
+ [data-variant='ghost'],
360
+ [data-variant='link']
361
+ ) {
362
+ color: var(--cratis-button-tone);
363
+ }
364
+
365
+ .cratis-button__icon,
366
+ .cratis-button__spinner {
367
+ display: inline-flex;
368
+ flex: 0 0 auto;
369
+ }
370
+ .cratis-button__spinner {
371
+ width: 1em;
372
+ height: 1em;
373
+ border: 2px solid currentColor;
374
+ border-right-color: transparent;
375
+ border-radius: 50%;
376
+ animation: cratis-button-spin 700ms linear infinite;
377
+ }
378
+
379
+ @keyframes cratis-button-spin {
380
+ to {
381
+ transform: rotate(360deg);
382
+ }
383
+ }
384
+
385
+ @media (prefers-reduced-motion: reduce) {
386
+ .cratis-button,
387
+ .cratis-button__spinner {
388
+ transition: none;
389
+ animation: none;
390
+ }
391
+ }
392
+
393
+ @media (forced-colors: active) {
394
+ .cratis-button {
395
+ border-color: ButtonText;
396
+ }
397
+ .cratis-button:focus-visible {
398
+ outline: 2px solid Highlight;
399
+ outline-offset: 2px;
400
+ box-shadow: none;
401
+ }
402
+ }
403
+
404
+ /* ── ./Common/ComboBox.css ─────────────────────────────────────── */
405
+ /* Copyright (c) Cratis. All rights reserved. */
406
+ /* Licensed under the MIT license. See LICENSE file in the project root for full license information. */
407
+
408
+ .cratis-combobox {
409
+ display: inline-flex;
410
+ flex-direction: column;
411
+ min-width: 10rem;
412
+ color: var(--cratis-text-color);
413
+ }
414
+ .cratis-combobox__control {
415
+ display: flex;
416
+ min-height: var(--cratis-control-height);
417
+ border: 1px solid var(--cratis-control-border);
418
+ border-radius: var(--cratis-border-radius);
419
+ background: var(--cratis-control-background);
420
+ }
421
+ .cratis-combobox__control:focus-within {
422
+ border-color: var(--cratis-primary-color);
423
+ box-shadow: var(--cratis-focus-ring);
424
+ }
425
+ .cratis-combobox[data-invalid='true'] .cratis-combobox__control {
426
+ border-color: var(--cratis-red-500);
427
+ }
428
+ .cratis-combobox[data-disabled='true'] {
429
+ cursor: not-allowed;
430
+ opacity: var(--cratis-disabled-opacity);
431
+ }
432
+ .cratis-combobox__input,
433
+ .cratis-combobox__trigger {
434
+ border: 0;
435
+ background: transparent;
436
+ color: inherit;
437
+ font: inherit;
438
+ }
439
+ .cratis-combobox__input {
440
+ flex: 1 1 auto;
441
+ min-width: 0;
442
+ padding: 0.625rem 0.75rem;
443
+ outline: 0;
444
+ }
445
+ .cratis-combobox__trigger {
446
+ padding: 0 0.75rem;
447
+ color: var(--cratis-text-color-secondary);
448
+ }
449
+ .cratis-combobox__popover {
450
+ width: var(--trigger-width);
451
+ overflow: auto;
452
+ border: 1px solid var(--cratis-surface-border);
453
+ border-radius: var(--cratis-border-radius);
454
+ background: var(--cratis-surface-overlay);
455
+ box-shadow: var(--cratis-shadow-overlay);
456
+ }
457
+ .cratis-combobox__listbox {
458
+ max-height: 18rem;
459
+ padding: 0.25rem;
460
+ }
461
+ .cratis-combobox__option,
462
+ .cratis-combobox__action,
463
+ .cratis-combobox__message {
464
+ display: flex;
465
+ gap: 0.5rem;
466
+ padding: 0.5rem 0.75rem;
467
+ border-radius: var(--cratis-border-radius);
468
+ }
469
+ .cratis-combobox__listbox[data-option-layout='stacked'] .cratis-combobox__option {
470
+ flex-direction: column;
471
+ }
472
+ .cratis-combobox__option[data-focused],
473
+ .cratis-combobox__action[data-focused] {
474
+ background: var(--cratis-surface-hover);
475
+ }
476
+ .cratis-combobox__option[data-selected='true'] {
477
+ background: var(--cratis-highlight-bg);
478
+ color: var(--cratis-highlight-text-color);
479
+ }
480
+ .cratis-combobox__option[data-disabled='true'] {
481
+ opacity: var(--cratis-disabled-opacity);
482
+ }
483
+ .cratis-combobox__option-description,
484
+ .cratis-combobox__message,
485
+ .cratis-combobox__description {
486
+ color: var(--cratis-text-color-secondary);
487
+ }
488
+ .cratis-combobox__action {
489
+ border-top: 1px solid var(--cratis-surface-border);
490
+ color: var(--cratis-primary-color);
491
+ }
492
+ .cratis-combobox__description,
493
+ .cratis-combobox__error {
494
+ margin-top: 0.25rem;
495
+ font-size: 0.875em;
496
+ }
497
+ .cratis-combobox__error {
498
+ color: var(--cratis-red-500);
499
+ }
500
+
501
+ /* ── ./Common/Collections.css ─────────────────────────────────────── */
502
+ /* Copyright (c) Cratis. All rights reserved. */
503
+ /* Licensed under the MIT license. See LICENSE file in the project root for full license information. */
504
+
505
+ /* Toggle group, tabs, tag group and breadcrumbs share a token vocabulary and a focus treatment, so
506
+ they share one stylesheet rather than repeating it four times in the published aggregate. */
507
+
508
+ .cratis-toggle-group,
509
+ .cratis-tabs__list,
510
+ .cratis-tag-group,
511
+ .cratis-breadcrumbs {
512
+ display: flex;
513
+ align-items: center;
514
+ color: var(--cratis-text-color);
515
+ }
516
+ .cratis-toggle-group__option:focus-visible,
517
+ .cratis-tabs__tab:focus-visible,
518
+ .cratis-tag-group__tag:focus-visible,
519
+ .cratis-tag-group__remove:focus-visible,
520
+ .cratis-tag-group__input:focus-visible,
521
+ .cratis-breadcrumbs__link:focus-visible {
522
+ outline: none;
523
+ box-shadow: var(--cratis-focus-ring);
524
+ }
525
+ .cratis-toggle-group[data-disabled],
526
+ .cratis-tabs[data-disabled] {
527
+ cursor: not-allowed;
528
+ opacity: var(--cratis-disabled-opacity);
529
+ }
530
+ /* A disabled tag group keeps its values readable — they are information, not an inactive control,
531
+ and fading them takes their contrast below the threshold. Only the affordances dim. */
532
+ .cratis-tag-group[data-disabled] {
533
+ cursor: not-allowed;
534
+ background: var(--cratis-surface-ground);
535
+ }
536
+ .cratis-tag-group[data-disabled] .cratis-tag-group__tag {
537
+ border-style: dashed;
538
+ }
539
+
540
+ /* Toggle group */
541
+ .cratis-toggle-group {
542
+ gap: 0.125rem;
543
+ padding: 0.125rem;
544
+ border: 1px solid var(--cratis-surface-border);
545
+ border-radius: var(--cratis-border-radius);
546
+ background: var(--cratis-surface-ground);
547
+ }
548
+ .cratis-toggle-group__option {
549
+ display: inline-flex;
550
+ align-items: center;
551
+ gap: 0.35rem;
552
+ padding: 0.25rem 0.75rem;
553
+ border: 0;
554
+ border-radius: calc(var(--cratis-border-radius) - 1px);
555
+ background: transparent;
556
+ color: inherit;
557
+ font: inherit;
558
+ cursor: pointer;
559
+ }
560
+ .cratis-toggle-group__option[data-selected] {
561
+ background: var(--cratis-surface-card);
562
+ box-shadow: var(--cratis-shadow-card, none);
563
+ font-weight: 600;
564
+ }
565
+ .cratis-toggle-group__option[data-disabled] {
566
+ cursor: not-allowed;
567
+ opacity: var(--cratis-disabled-opacity);
568
+ }
569
+ .cratis-toggle-group__icon {
570
+ display: inline-flex;
571
+ }
572
+ .cratis-toggle-group[data-invalid] {
573
+ border-color: var(--cratis-red-500);
574
+ }
575
+
576
+ /* Tabs */
577
+ .cratis-tabs {
578
+ display: flex;
579
+ flex-direction: column;
580
+ }
581
+ .cratis-tabs__list {
582
+ gap: 0.25rem;
583
+ border-bottom: 1px solid var(--cratis-surface-border);
584
+ }
585
+ .cratis-tabs__tab {
586
+ padding: 0.5rem 0.75rem;
587
+ border: 0;
588
+ border-bottom: 2px solid transparent;
589
+ background: transparent;
590
+ color: var(--cratis-text-color-secondary);
591
+ font: inherit;
592
+ cursor: pointer;
593
+ }
594
+ .cratis-tabs__tab[data-selected] {
595
+ border-bottom-color: var(--cratis-primary-color);
596
+ color: var(--cratis-text-color);
597
+ font-weight: 600;
598
+ }
599
+ .cratis-tabs__tab[data-disabled] {
600
+ cursor: not-allowed;
601
+ opacity: var(--cratis-disabled-opacity);
602
+ }
603
+ .cratis-tabs__panel {
604
+ padding: 0.75rem 0;
605
+ outline: none;
606
+ }
607
+
608
+ /* Tag group */
609
+ .cratis-tag-group {
610
+ flex-wrap: wrap;
611
+ gap: 0.35rem;
612
+ min-height: var(--cratis-control-height);
613
+ padding: 0.25rem 0.5rem;
614
+ border: 1px solid var(--cratis-control-border);
615
+ border-radius: var(--cratis-border-radius);
616
+ background: var(--cratis-control-background);
617
+ }
618
+ .cratis-tag-group:focus-within {
619
+ border-color: var(--cratis-primary-color);
620
+ box-shadow: var(--cratis-focus-ring);
621
+ }
622
+ .cratis-tag-group[data-invalid] {
623
+ border-color: var(--cratis-red-500);
624
+ }
625
+ .cratis-tag-group__group,
626
+ .cratis-tag-group__list {
627
+ display: contents;
628
+ }
629
+ .cratis-tag-group__tag {
630
+ display: inline-flex;
631
+ align-items: center;
632
+ gap: 0.25rem;
633
+ padding: 0.1rem 0.5rem;
634
+ border: 1px solid var(--cratis-surface-border);
635
+ border-radius: 999px;
636
+ background: var(--cratis-surface-ground);
637
+ font-size: 0.9em;
638
+ }
639
+ .cratis-tag-group__remove {
640
+ display: inline-flex;
641
+ align-items: center;
642
+ justify-content: center;
643
+ padding: 0;
644
+ border: 0;
645
+ background: transparent;
646
+ color: var(--cratis-text-color-secondary);
647
+ line-height: 1;
648
+ cursor: pointer;
649
+ }
650
+ .cratis-tag-group__remove:hover {
651
+ color: var(--cratis-text-color);
652
+ }
653
+ .cratis-tag-group__input {
654
+ flex: 1 1 6rem;
655
+ min-width: 4rem;
656
+ border: 0;
657
+ background: transparent;
658
+ color: inherit;
659
+ font: inherit;
660
+ outline: none;
661
+ }
662
+
663
+ /* Breadcrumbs */
664
+ .cratis-breadcrumbs {
665
+ flex-wrap: wrap;
666
+ gap: 0.35rem;
667
+ padding: 0;
668
+ margin: 0;
669
+ list-style: none;
670
+ }
671
+ .cratis-breadcrumbs__item {
672
+ display: inline-flex;
673
+ align-items: center;
674
+ gap: 0.35rem;
675
+ }
676
+ .cratis-breadcrumbs__link {
677
+ border-radius: var(--cratis-border-radius);
678
+ color: var(--cratis-text-color-secondary);
679
+ text-decoration: none;
680
+ cursor: pointer;
681
+ }
682
+ .cratis-breadcrumbs__link:hover {
683
+ color: var(--cratis-text-color);
684
+ text-decoration: underline;
685
+ }
686
+ .cratis-breadcrumbs__item[data-selected] {
687
+ color: var(--cratis-text-color);
688
+ font-weight: 600;
689
+ }
690
+ .cratis-breadcrumbs__separator {
691
+ color: var(--cratis-text-color-secondary);
692
+ }
693
+
694
+ @media (forced-colors: active) {
695
+ .cratis-toggle-group__option[data-selected],
696
+ .cratis-tabs__tab[data-selected] {
697
+ forced-color-adjust: none;
698
+ background: Highlight;
699
+ color: HighlightText;
700
+ }
701
+ }
702
+
703
+ /* ── ./Common/DatePickerInput.css ─────────────────────────────────────── */
704
+ /* Copyright (c) Cratis. All rights reserved. */
705
+ /* Licensed under the MIT license. See LICENSE file in the project root for full license information. */
706
+
707
+ .cratis-date-picker {
708
+ display: inline-flex;
709
+ width: 100%;
710
+ color: var(--cratis-text-color);
711
+ }
712
+ .cratis-date-picker__picker {
713
+ width: 100%;
714
+ }
715
+ .cratis-date-picker__group {
716
+ position: relative;
717
+ display: flex;
718
+ width: 100%;
719
+ box-sizing: border-box;
720
+ min-height: var(--cratis-control-height);
721
+ align-items: center;
722
+ overflow: hidden;
723
+ border: 1px solid var(--cratis-control-border);
724
+ border-radius: var(--cratis-border-radius);
725
+ background: var(--cratis-control-background);
726
+ }
727
+ .cratis-date-picker__group[data-focus-within] {
728
+ border-color: var(--cratis-primary-color);
729
+ box-shadow: var(--cratis-focus-ring);
730
+ }
731
+ .cratis-date-picker[data-invalid='true'] .cratis-date-picker__group {
732
+ border-color: var(--cratis-red-500);
733
+ }
734
+ .cratis-date-picker[data-disabled='true'] {
735
+ opacity: var(--cratis-disabled-opacity);
736
+ }
737
+ .cratis-date-picker__input {
738
+ display: flex;
739
+ flex: 1;
740
+ flex-wrap: wrap;
741
+ min-width: 0;
742
+ padding: 0.625rem 0.75rem;
743
+ }
744
+ .cratis-date-picker__group[data-empty='true']:not([data-focus-within])
745
+ .cratis-date-picker__input {
746
+ opacity: 0;
747
+ }
748
+ .cratis-date-picker__placeholder {
749
+ position: absolute;
750
+ inset-inline-start: 0.7rem;
751
+ color: var(--cratis-text-color-secondary);
752
+ pointer-events: none;
753
+ }
754
+ .cratis-date-picker__group[data-focus-within] .cratis-date-picker__placeholder {
755
+ display: none;
756
+ }
757
+ .cratis-date-picker__segment {
758
+ padding: 0 0.1rem;
759
+ border-radius: 0.2rem;
760
+ outline: none;
761
+ font-variant-numeric: tabular-nums;
762
+ }
763
+ .cratis-date-picker__segment:not([data-type='literal']) {
764
+ display: flex;
765
+ min-width: 24px;
766
+ min-height: 24px;
767
+ align-items: center;
768
+ justify-content: center;
769
+ }
770
+ .cratis-date-picker__segment[data-placeholder] {
771
+ color: var(--cratis-text-color-secondary);
772
+ }
773
+ .cratis-date-picker__segment[data-focused] {
774
+ background: var(--cratis-highlight-bg);
775
+ color: var(--cratis-highlight-text-color);
776
+ }
777
+ .cratis-date-picker__trigger {
778
+ align-self: stretch;
779
+ min-width: var(--cratis-control-height);
780
+ border: 0;
781
+ border-inline-start: 1px solid var(--cratis-control-border);
782
+ background: transparent;
783
+ color: var(--cratis-text-color-secondary);
784
+ cursor: pointer;
785
+ }
786
+ .cratis-date-picker__trigger:hover {
787
+ background: var(--cratis-surface-hover);
788
+ color: var(--cratis-text-color);
789
+ }
790
+ .cratis-date-picker__trigger:focus-visible {
791
+ outline: none;
792
+ box-shadow: inset var(--cratis-focus-ring);
793
+ }
794
+ .cratis-date-picker__popover {
795
+ z-index: var(--cratis-z-index-overlay);
796
+ overflow: auto;
797
+ border: 1px solid var(--cratis-surface-border);
798
+ border-radius: var(--cratis-border-radius);
799
+ background: var(--cratis-surface-overlay);
800
+ color: var(--cratis-text-color);
801
+ box-shadow: var(--cratis-shadow-overlay);
802
+ }
803
+ .cratis-date-picker__dialog {
804
+ padding: 0.75rem;
805
+ outline: none;
806
+ }
807
+ .cratis-date-picker__calendar {
808
+ width: max-content;
809
+ }
810
+ .cratis-date-picker__header {
811
+ display: grid;
812
+ grid-template-columns: 2rem 1fr 2rem;
813
+ align-items: center;
814
+ gap: 0.5rem;
815
+ margin-bottom: 0.5rem;
816
+ }
817
+ .cratis-date-picker__heading {
818
+ margin: 0;
819
+ text-align: center;
820
+ font-size: 0.95rem;
821
+ }
822
+ .cratis-date-picker__nav,
823
+ .cratis-date-picker__action {
824
+ min-height: 2rem;
825
+ border: 1px solid var(--cratis-surface-border);
826
+ border-radius: calc(var(--cratis-border-radius) * 0.75);
827
+ background: transparent;
828
+ color: inherit;
829
+ cursor: pointer;
830
+ }
831
+ .cratis-date-picker__nav:hover,
832
+ .cratis-date-picker__action:hover {
833
+ background: var(--cratis-surface-hover);
834
+ }
835
+ .cratis-date-picker__nav:focus-visible,
836
+ .cratis-date-picker__action:focus-visible {
837
+ outline: none;
838
+ box-shadow: var(--cratis-focus-ring);
839
+ }
840
+ .cratis-date-picker__grid {
841
+ border-collapse: collapse;
842
+ }
843
+ .cratis-date-picker__grid th {
844
+ width: 2.25rem;
845
+ height: 2rem;
846
+ color: var(--cratis-text-color-secondary);
847
+ font-size: 0.75rem;
848
+ font-weight: 500;
849
+ }
850
+ .cratis-date-picker__cell {
851
+ display: flex;
852
+ width: 2.5rem;
853
+ height: 2.5rem;
854
+ align-items: center;
855
+ justify-content: center;
856
+ border-radius: 50%;
857
+ outline: none;
858
+ cursor: default;
859
+ }
860
+ .cratis-date-picker__cell[data-hovered] {
861
+ background: var(--cratis-surface-hover);
862
+ }
863
+ .cratis-date-picker__cell[data-selected] {
864
+ background: var(--cratis-action-background);
865
+ color: var(--cratis-action-text);
866
+ }
867
+ .cratis-date-picker__cell[data-focused] {
868
+ box-shadow: var(--cratis-focus-ring);
869
+ }
870
+ .cratis-date-picker__cell[data-disabled],
871
+ .cratis-date-picker__cell[data-outside-month] {
872
+ opacity: 0.45;
873
+ }
874
+ .cratis-date-picker__button-bar {
875
+ display: flex;
876
+ justify-content: flex-end;
877
+ gap: 0.5rem;
878
+ margin-top: 0.6rem;
879
+ padding-top: 0.6rem;
880
+ border-top: 1px solid var(--cratis-surface-border);
881
+ }
882
+ .cratis-date-picker__action {
883
+ padding: 0.35rem 0.65rem;
884
+ }
885
+
886
+ @media (forced-colors: active) {
887
+ .cratis-date-picker__group,
888
+ .cratis-date-picker__popover,
889
+ .cratis-date-picker__nav,
890
+ .cratis-date-picker__action {
891
+ border-color: CanvasText;
892
+ }
893
+ .cratis-date-picker__cell[data-selected] {
894
+ background: Highlight;
895
+ color: HighlightText;
896
+ }
897
+ }
898
+
899
+ /* ── ./Common/FormElement.css ─────────────────────────────────────── */
900
+ /* Copyright (c) Cratis. All rights reserved. */
901
+ /* Licensed under the MIT license. See LICENSE file in the project root for full license information. */
902
+
903
+ .cratis-form-element {
904
+ display: flex;
905
+ flex: 1 1 auto;
906
+ align-items: stretch;
907
+ }
908
+
909
+ .cratis-form-element__addon {
910
+ display: inline-flex;
911
+ align-items: center;
912
+ justify-content: center;
913
+ padding: 0 0.75rem;
914
+ color: var(--cratis-text-color-secondary);
915
+ background: var(--cratis-surface-100);
916
+ border: 1px solid var(--cratis-control-border);
917
+ border-right: 0;
918
+ border-top-left-radius: var(--cratis-border-radius);
919
+ border-bottom-left-radius: var(--cratis-border-radius);
920
+ }
921
+
922
+ .cratis-form-element > *:not(.cratis-form-element__addon) {
923
+ flex: 1 1 auto;
924
+ min-width: 0;
925
+ }
926
+
927
+ /* ── ./Common/NumberInput.css ─────────────────────────────────────── */
928
+ /* Copyright (c) Cratis. All rights reserved. */
929
+ /* Licensed under the MIT license. See LICENSE file in the project root for full license information. */
930
+
931
+ .cratis-number-input {
932
+ box-sizing: border-box;
933
+ width: 100%;
934
+ max-width: 100%;
935
+ color: var(--cratis-text-color);
936
+ }
937
+ .cratis-number-input__group {
938
+ display: flex;
939
+ box-sizing: border-box;
940
+ min-width: 0;
941
+ min-height: var(--cratis-control-height);
942
+ align-items: stretch;
943
+ overflow: hidden;
944
+ border: 1px solid var(--cratis-control-border);
945
+ border-radius: var(--cratis-border-radius);
946
+ background: var(--cratis-control-background);
947
+ box-shadow: var(--cratis-shadow-subtle);
948
+ }
949
+ .cratis-number-input__control,
950
+ .cratis-number-input__steps {
951
+ display: flex;
952
+ min-width: 0;
953
+ align-items: stretch;
954
+ }
955
+ .cratis-number-input__control {
956
+ flex: 1 1 auto;
957
+ }
958
+ .cratis-number-input__steps {
959
+ flex: 0 0 auto;
960
+ }
961
+ .cratis-number-input__group:focus-within {
962
+ border-color: var(--cratis-primary-color);
963
+ box-shadow: var(--cratis-focus-ring);
964
+ }
965
+ .cratis-number-input[data-invalid='true'] .cratis-number-input__group {
966
+ border-color: var(--cratis-red-500);
967
+ }
968
+ .cratis-number-input[data-disabled='true'] {
969
+ cursor: not-allowed;
970
+ opacity: var(--cratis-disabled-opacity);
971
+ }
972
+ .cratis-number-input:is([data-disabled='true'], [data-readonly='true'])
973
+ .cratis-number-input__group {
974
+ background: var(--cratis-surface-100);
975
+ }
976
+ .cratis-number-input__input {
977
+ box-sizing: border-box;
978
+ width: 100%;
979
+ min-width: 0;
980
+ min-height: var(--cratis-control-height);
981
+ padding: 0.625rem 0.75rem;
982
+ flex: 1 1 auto;
983
+ border: 0;
984
+ outline: 0;
985
+ background: transparent;
986
+ color: var(--cratis-text-color);
987
+ font: inherit;
988
+ font-variant-numeric: tabular-nums;
989
+ }
990
+ .cratis-number-input__input::placeholder {
991
+ color: var(--cratis-text-color-secondary);
992
+ }
993
+ .cratis-number-input__adornment {
994
+ display: inline-flex;
995
+ min-width: 0;
996
+ padding-inline: 0.75rem;
997
+ align-items: center;
998
+ color: var(--cratis-number-input-adornment-color);
999
+ white-space: nowrap;
1000
+ }
1001
+ .cratis-number-input__prefix {
1002
+ padding-inline-end: 0;
1003
+ }
1004
+ .cratis-number-input__suffix {
1005
+ padding-inline-start: 0;
1006
+ }
1007
+ .cratis-number-input__step {
1008
+ display: inline-flex;
1009
+ box-sizing: border-box;
1010
+ width: var(--cratis-control-height);
1011
+ min-width: 2.75rem;
1012
+ min-height: var(--cratis-control-height);
1013
+ padding: 0;
1014
+ align-items: center;
1015
+ justify-content: center;
1016
+ border: 0;
1017
+ border-inline-start: 1px solid var(--cratis-control-border);
1018
+ background: var(--cratis-number-input-step-background);
1019
+ color: var(--cratis-text-color);
1020
+ font: inherit;
1021
+ cursor: pointer;
1022
+ }
1023
+ .cratis-number-input__step:hover:not(:disabled) {
1024
+ background: var(--cratis-number-input-step-background-hover);
1025
+ }
1026
+ .cratis-number-input__step:focus-visible {
1027
+ outline: 2px solid var(--cratis-primary-color);
1028
+ outline-offset: -3px;
1029
+ }
1030
+ .cratis-number-input__step:disabled {
1031
+ cursor: not-allowed;
1032
+ opacity: var(--cratis-disabled-opacity);
1033
+ }
1034
+ .cratis-number-input__description,
1035
+ .cratis-number-input__error {
1036
+ display: block;
1037
+ margin-block-start: 0.35rem;
1038
+ line-height: 1.4;
1039
+ }
1040
+ .cratis-number-input__description {
1041
+ color: var(--cratis-text-color-secondary);
1042
+ }
1043
+ .cratis-number-input__error {
1044
+ color: var(--cratis-red-500);
1045
+ }
1046
+
1047
+ @media (max-width: 24rem) {
1048
+ .cratis-number-input__group {
1049
+ flex-wrap: wrap;
1050
+ }
1051
+ .cratis-number-input__control,
1052
+ .cratis-number-input__steps {
1053
+ width: 100%;
1054
+ flex-basis: 100%;
1055
+ border-block-start: 1px solid var(--cratis-control-border);
1056
+ }
1057
+ .cratis-number-input__step {
1058
+ width: 50%;
1059
+ min-width: 0;
1060
+ flex: 1 1 50%;
1061
+ }
1062
+ .cratis-number-input__step:first-child {
1063
+ border-inline-start: 0;
1064
+ }
1065
+ }
1066
+
1067
+ @media (forced-colors: active) {
1068
+ .cratis-number-input__group,
1069
+ .cratis-number-input__step {
1070
+ border-color: CanvasText;
1071
+ }
1072
+ .cratis-number-input__group:focus-within,
1073
+ .cratis-number-input__step:focus-visible {
1074
+ outline: 2px solid Highlight;
1075
+ outline-offset: 2px;
1076
+ box-shadow: none;
1077
+ }
1078
+ }
1079
+
1080
+ /* ── ./Common/Primitives.css ─────────────────────────────────────── */
1081
+ /* Copyright (c) Cratis. All rights reserved. */
1082
+ /* Licensed under the MIT license. See LICENSE file in the project root for full license information. */
1083
+
1084
+ .cratis-text-input,
1085
+ .cratis-text-area {
1086
+ box-sizing: border-box;
1087
+ min-height: var(--cratis-control-height);
1088
+ padding: 0.625rem 0.75rem;
1089
+ border: 1px solid var(--cratis-control-border);
1090
+ border-radius: var(--cratis-border-radius);
1091
+ background: var(--cratis-control-background);
1092
+ color: var(--cratis-text-color);
1093
+ font: inherit;
1094
+ box-shadow: var(--cratis-shadow-subtle);
1095
+ }
1096
+ .cratis-text-area {
1097
+ resize: vertical;
1098
+ }
1099
+ .cratis-text-input::placeholder,
1100
+ .cratis-text-area::placeholder {
1101
+ color: var(--cratis-text-color-secondary);
1102
+ }
1103
+ .cratis-text-input:focus-visible,
1104
+ .cratis-text-area:focus-visible {
1105
+ outline: none;
1106
+ border-color: var(--cratis-primary-color);
1107
+ box-shadow: var(--cratis-focus-ring);
1108
+ }
1109
+ .cratis-text-input:is(:disabled, [data-readonly='true']),
1110
+ .cratis-text-area:is(:disabled, [data-readonly='true']) {
1111
+ background: var(--cratis-surface-100);
1112
+ }
1113
+ .cratis-text-input:disabled,
1114
+ .cratis-text-area:disabled {
1115
+ cursor: not-allowed;
1116
+ opacity: var(--cratis-disabled-opacity);
1117
+ }
1118
+ .cratis-text-input[data-invalid='true'],
1119
+ .cratis-text-area[data-invalid='true'] {
1120
+ border-color: var(--cratis-red-500);
1121
+ }
1122
+
1123
+ .cratis-choice {
1124
+ position: relative;
1125
+ display: inline-flex;
1126
+ align-items: center;
1127
+ gap: 0.5rem;
1128
+ color: var(--cratis-text-color);
1129
+ cursor: pointer;
1130
+ }
1131
+ .cratis-choice[data-disabled='true'] {
1132
+ cursor: not-allowed;
1133
+ opacity: var(--cratis-disabled-opacity);
1134
+ }
1135
+ .cratis-choice[data-readonly='true']:not([data-disabled='true']) {
1136
+ cursor: default;
1137
+ }
1138
+ .cratis-choice__input {
1139
+ position: absolute;
1140
+ width: 1px;
1141
+ height: 1px;
1142
+ margin: -1px;
1143
+ overflow: hidden;
1144
+ clip: rect(0 0 0 0);
1145
+ clip-path: inset(50%);
1146
+ white-space: nowrap;
1147
+ }
1148
+ .cratis-checkbox__box,
1149
+ .cratis-radio__box,
1150
+ .cratis-switch__control {
1151
+ display: inline-flex;
1152
+ box-sizing: border-box;
1153
+ flex: 0 0 auto;
1154
+ align-items: center;
1155
+ border: 1px solid var(--cratis-control-border);
1156
+ background: var(--cratis-control-background);
1157
+ }
1158
+ .cratis-checkbox__box,
1159
+ .cratis-radio__box {
1160
+ width: 1.25rem;
1161
+ height: 1.25rem;
1162
+ justify-content: center;
1163
+ }
1164
+ .cratis-checkbox__box {
1165
+ border-radius: var(--cratis-border-radius);
1166
+ }
1167
+ .cratis-checkbox__indicator {
1168
+ color: var(--cratis-primary-color-text);
1169
+ font-size: 0.85rem;
1170
+ line-height: 1;
1171
+ opacity: 0;
1172
+ }
1173
+ .cratis-radio__box {
1174
+ border-radius: 50%;
1175
+ }
1176
+ .cratis-radio__indicator {
1177
+ width: 0.65rem;
1178
+ height: 0.65rem;
1179
+ border-radius: 50%;
1180
+ background: var(--cratis-primary-color);
1181
+ opacity: 0;
1182
+ }
1183
+ .cratis-switch__control {
1184
+ width: 2.5rem;
1185
+ height: 1.4rem;
1186
+ padding: 0.15rem;
1187
+ border-radius: 999px;
1188
+ background: var(--cratis-surface-100);
1189
+ transition: background-color 140ms ease;
1190
+ }
1191
+ .cratis-switch__handle {
1192
+ width: 1rem;
1193
+ height: 1rem;
1194
+ border-radius: 50%;
1195
+ background: var(--cratis-control-background);
1196
+ box-shadow: var(--cratis-shadow-subtle);
1197
+ transition: transform 140ms ease;
1198
+ }
1199
+ .cratis-choice__input:focus-visible
1200
+ + :is(.cratis-checkbox__box, .cratis-radio__box, .cratis-switch__control) {
1201
+ box-shadow: var(--cratis-focus-ring);
1202
+ }
1203
+ .cratis-choice__input:checked + .cratis-checkbox__box,
1204
+ .cratis-choice__input:checked + .cratis-switch__control {
1205
+ border-color: var(--cratis-primary-color);
1206
+ background: var(--cratis-primary-color);
1207
+ }
1208
+ .cratis-choice__input:checked + .cratis-checkbox__box .cratis-checkbox__indicator,
1209
+ .cratis-choice__input:checked + .cratis-radio__box .cratis-radio__indicator {
1210
+ opacity: 1;
1211
+ }
1212
+ .cratis-choice__input:checked + .cratis-radio__box {
1213
+ border-color: var(--cratis-primary-color);
1214
+ }
1215
+ .cratis-choice__input:checked + .cratis-switch__control .cratis-switch__handle {
1216
+ transform: translateX(1.05rem);
1217
+ }
1218
+ .cratis-choice:dir(rtl)
1219
+ .cratis-choice__input:checked
1220
+ + .cratis-switch__control
1221
+ .cratis-switch__handle {
1222
+ transform: translateX(-1.05rem);
1223
+ }
1224
+ .cratis-choice[data-invalid='true']
1225
+ :is(.cratis-checkbox__box, .cratis-radio__box, .cratis-switch__control) {
1226
+ border-color: var(--cratis-red-500);
1227
+ }
1228
+
1229
+ .cratis-surface {
1230
+ box-sizing: border-box;
1231
+ border: 1px solid var(--cratis-surface-border);
1232
+ border-radius: var(--cratis-border-radius);
1233
+ background: var(--cratis-surface-card);
1234
+ color: var(--cratis-text-color);
1235
+ box-shadow: var(--cratis-shadow-subtle);
1236
+ }
1237
+
1238
+ @media (prefers-reduced-motion: reduce) {
1239
+ .cratis-switch__control,
1240
+ .cratis-switch__handle {
1241
+ transition: none;
1242
+ }
1243
+ }
1244
+
1245
+ @media (forced-colors: active) {
1246
+ .cratis-text-input,
1247
+ .cratis-text-area,
1248
+ .cratis-checkbox__box,
1249
+ .cratis-radio__box,
1250
+ .cratis-switch__control,
1251
+ .cratis-surface {
1252
+ border-color: CanvasText;
1253
+ }
1254
+ .cratis-choice__input:checked
1255
+ + :is(.cratis-checkbox__box, .cratis-switch__control) {
1256
+ background: Highlight;
1257
+ }
1258
+ .cratis-choice__input:checked + .cratis-radio__box .cratis-radio__indicator {
1259
+ background: Highlight;
1260
+ }
1261
+ .cratis-choice__input:focus-visible
1262
+ + :is(.cratis-checkbox__box, .cratis-radio__box, .cratis-switch__control),
1263
+ .cratis-text-input:focus-visible,
1264
+ .cratis-text-area:focus-visible {
1265
+ outline: 2px solid Highlight;
1266
+ outline-offset: 2px;
1267
+ box-shadow: none;
1268
+ }
1269
+ }
1270
+
1271
+ /* ── ./Common/Tooltip.css ─────────────────────────────────────── */
1272
+ /* Copyright (c) Cratis. All rights reserved. */
1273
+ /* Licensed under the MIT license. See LICENSE file in the project root for full license information. */
1274
+
1275
+ /* ── Tooltip bubble ──────────────────────────────────────────────────────── */
1276
+ .cratis-tooltip-popup {
1277
+ background: var(--cratis-surface-100);
1278
+ color: var(--cratis-text-color);
1279
+ border: 1px solid var(--cratis-surface-border);
1280
+ box-shadow: var(--cratis-shadow-overlay);
1281
+ border-radius: var(--cratis-border-radius);
1282
+ padding: 0.25rem 0.5rem;
1283
+ font-size: 0.75rem;
1284
+ font-family: inherit;
1285
+ max-width: 24rem;
1286
+ z-index: var(--cratis-z-index-tooltip);
1287
+ }
1288
+
1289
+ /* ── ./DataTables/ColumnFilterMenu.css ─────────────────────────────────────── */
1290
+ /* Copyright (c) Cratis. All rights reserved. */
1291
+ /* Licensed under the MIT license. See LICENSE file in the project root for full license information. */
1292
+
1293
+ .cratis-filter-trigger {
1294
+ display: inline-flex;
1295
+ align-items: center;
1296
+ justify-content: center;
1297
+ padding: 0.25rem;
1298
+ border: none;
1299
+ background: transparent;
1300
+ color: var(--cratis-text-color-secondary);
1301
+ cursor: pointer;
1302
+ border-radius: 0.25rem;
1303
+ }
1304
+
1305
+ .cratis-filter-trigger:hover {
1306
+ background: var(--cratis-surface-hover);
1307
+ color: var(--cratis-text-color);
1308
+ }
1309
+
1310
+ .cratis-filter-trigger[data-active='true'] {
1311
+ color: var(--cratis-primary-color);
1312
+ }
1313
+
1314
+ .cratis-filter-trigger:focus-visible {
1315
+ outline: none;
1316
+ box-shadow: var(--cratis-focus-ring);
1317
+ }
1318
+
1319
+ .cratis-filter-popover {
1320
+ z-index: var(--cratis-z-index-filter);
1321
+ }
1322
+
1323
+ .cratis-filter-menu {
1324
+ display: flex;
1325
+ flex-direction: column;
1326
+ gap: 0.5rem;
1327
+ min-width: 14rem;
1328
+ padding: 0.5rem;
1329
+ background: var(--cratis-surface-overlay);
1330
+ border: 1px solid var(--cratis-surface-border);
1331
+ border-radius: var(--cratis-border-radius);
1332
+ box-shadow: var(--cratis-shadow-overlay);
1333
+ }
1334
+
1335
+ .cratis-filter-menu__input {
1336
+ box-sizing: border-box;
1337
+ min-height: var(--cratis-control-height);
1338
+ padding: 0.625rem 0.75rem;
1339
+ border: 1px solid var(--cratis-control-border);
1340
+ border-radius: var(--cratis-border-radius);
1341
+ background: var(--cratis-control-background);
1342
+ color: var(--cratis-text-color);
1343
+ font: inherit;
1344
+ }
1345
+
1346
+ .cratis-filter-menu__input:focus-visible {
1347
+ outline: none;
1348
+ border-color: var(--cratis-primary-color);
1349
+ box-shadow: var(--cratis-focus-ring);
1350
+ }
1351
+
1352
+ .cratis-filter-menu-actions {
1353
+ display: flex;
1354
+ justify-content: space-between;
1355
+ gap: 0.5rem;
1356
+ }
1357
+
1358
+ /* ── ./DataTables/DataTableCore.css ─────────────────────────────────────── */
1359
+ /* Copyright (c) Cratis. All rights reserved. */
1360
+ /* Licensed under the MIT license. See LICENSE file in the project root for full license information. */
1361
+
1362
+ .cratis-datatable__sr-only {
1363
+ position: absolute;
1364
+ width: 1px;
1365
+ height: 1px;
1366
+ padding: 0;
1367
+ margin: -1px;
1368
+ overflow: hidden;
1369
+ clip: rect(0, 0, 0, 0);
1370
+ white-space: nowrap;
1371
+ border: 0;
1372
+ }
1373
+
1374
+ .cratis-datatable {
1375
+ width: 100%;
1376
+ color: var(--cratis-text-color);
1377
+ }
1378
+
1379
+ /* The bounded scroll container is sized with a percentage `max-height`, which CSS resolves
1380
+ to `none` whenever the containing block has no definite height (CSS 2.1 10.7). The root
1381
+ is `height: auto` by default, so a scrollable table would grow past its parent and get
1382
+ clipped instead of scrolling. Giving the scrollable root a definite height re-establishes
1383
+ the chain, and the flex child absorbs the remaining space. */
1384
+ .cratis-datatable--scrollable {
1385
+ display: flex;
1386
+ flex-direction: column;
1387
+ height: 100%;
1388
+ min-height: 0;
1389
+ }
1390
+
1391
+ .cratis-datatable--scrollable .cratis-datatable__container {
1392
+ flex: 1 1 auto;
1393
+ min-height: 0;
1394
+ }
1395
+ .cratis-datatable-header-cell {
1396
+ display: flex;
1397
+ min-width: 0;
1398
+ align-items: center;
1399
+ justify-content: space-between;
1400
+ gap: 0.35rem;
1401
+ }
1402
+ .cratis-datatable-search {
1403
+ padding: 0.5rem;
1404
+ border-bottom: 1px solid var(--cratis-surface-border);
1405
+ }
1406
+ .cratis-datatable-search__input {
1407
+ width: 100%;
1408
+ box-sizing: border-box;
1409
+ min-height: var(--cratis-control-height);
1410
+ padding: 0.625rem 0.75rem;
1411
+ border: 1px solid var(--cratis-control-border);
1412
+ border-radius: var(--cratis-border-radius);
1413
+ background: var(--cratis-control-background);
1414
+ color: var(--cratis-text-color);
1415
+ font: inherit;
1416
+ }
1417
+ .cratis-datatable-search__input:focus-visible {
1418
+ outline: none;
1419
+ border-color: var(--cratis-primary-color);
1420
+ box-shadow: var(--cratis-focus-ring);
1421
+ }
1422
+ .cratis-datatable__container {
1423
+ width: 100%;
1424
+ overflow-x: auto;
1425
+ }
1426
+ .cratis-datatable__table {
1427
+ width: 100%;
1428
+ border-spacing: 0;
1429
+ border-collapse: collapse;
1430
+ }
1431
+ .cratis-datatable__header-cell {
1432
+ position: sticky;
1433
+ top: 0;
1434
+ z-index: 1;
1435
+ padding: 0.875rem 1rem;
1436
+ border-bottom: 1px solid var(--cratis-surface-border);
1437
+ background: var(--cratis-surface-section);
1438
+ color: var(--cratis-text-color);
1439
+ text-align: start;
1440
+ font-size: 0.875rem;
1441
+ font-weight: 700;
1442
+ }
1443
+ .cratis-datatable__sort {
1444
+ display: inline-flex;
1445
+ padding: 0;
1446
+ align-items: center;
1447
+ gap: 0.35rem;
1448
+ border: 0;
1449
+ background: transparent;
1450
+ color: inherit;
1451
+ font: inherit;
1452
+ font-weight: inherit;
1453
+ cursor: pointer;
1454
+ }
1455
+ .cratis-datatable__sort:focus-visible {
1456
+ outline: none;
1457
+ border-radius: 0.2rem;
1458
+ box-shadow: var(--cratis-focus-ring);
1459
+ }
1460
+ .cratis-datatable__cell {
1461
+ padding: 0.875rem 1rem;
1462
+ border-bottom: 1px solid var(--cratis-surface-border);
1463
+ vertical-align: middle;
1464
+ }
1465
+ .cratis-datatable__row {
1466
+ background: var(--cratis-surface-card);
1467
+ transition: background-color 100ms ease;
1468
+ }
1469
+ .cratis-datatable__row[data-interactive='true']:hover {
1470
+ background: var(--cratis-surface-hover);
1471
+ }
1472
+ .cratis-datatable__row:focus-visible {
1473
+ outline: none;
1474
+ box-shadow: inset var(--cratis-focus-ring);
1475
+ }
1476
+ .cratis-datatable__row[data-selected='true'] {
1477
+ background: var(--cratis-highlight-bg);
1478
+ color: var(--cratis-highlight-text-color);
1479
+ }
1480
+ .cratis-datatable__empty-cell {
1481
+ padding: 2rem 1rem;
1482
+ color: var(--cratis-text-color-secondary);
1483
+ text-align: center;
1484
+ }
1485
+
1486
+ @media (prefers-reduced-motion: reduce) {
1487
+ .cratis-datatable__row {
1488
+ transition: none;
1489
+ }
1490
+ }
1491
+ @media (forced-colors: active) {
1492
+ .cratis-datatable-search__input,
1493
+ .cratis-datatable__header-cell,
1494
+ .cratis-datatable__cell {
1495
+ border-color: CanvasText;
1496
+ }
1497
+ .cratis-datatable__row[data-selected='true'] {
1498
+ outline: 2px solid Highlight;
1499
+ }
1500
+ }
1501
+
1502
+ /* ── ./DataTables/TablePaginator.css ─────────────────────────────────────── */
1503
+ /* Copyright (c) Cratis. All rights reserved. */
1504
+ /* Licensed under the MIT license. See LICENSE file in the project root for full license information. */
1505
+
1506
+ .cratis-table-paginator {
1507
+ display: flex;
1508
+ align-items: center;
1509
+ justify-content: center;
1510
+ gap: 0.25rem;
1511
+ padding: 0.25rem;
1512
+ }
1513
+
1514
+ .cratis-table-paginator-info {
1515
+ font-size: 0.875rem;
1516
+ color: var(--cratis-text-color-secondary);
1517
+ padding: 0 0.5rem;
1518
+ }
1519
+
1520
+ .cratis-table-paginator-range {
1521
+ font-size: 0.8125rem;
1522
+ color: var(--cratis-text-color-secondary);
1523
+ margin-right: auto;
1524
+ padding: 0 0.5rem;
1525
+ }
1526
+
1527
+ /* ── ./Dropdown/Dropdown.css ─────────────────────────────────────── */
1528
+ /* Copyright (c) Cratis. All rights reserved. */
1529
+ /* Licensed under the MIT license. See LICENSE file in the project root for full license information. */
1530
+
1531
+ .cratis-dropdown {
1532
+ position: relative;
1533
+ display: inline-flex;
1534
+ min-width: 10rem;
1535
+ color: var(--cratis-text-color);
1536
+ }
1537
+ .cratis-dropdown__select,
1538
+ .cratis-dropdown__combobox {
1539
+ position: relative;
1540
+ display: flex;
1541
+ width: 100%;
1542
+ }
1543
+ .cratis-dropdown__trigger,
1544
+ .cratis-dropdown__filter,
1545
+ .cratis-dropdown__multiple {
1546
+ width: 100%;
1547
+ box-sizing: border-box;
1548
+ min-height: var(--cratis-control-height);
1549
+ border: 1px solid var(--cratis-control-border);
1550
+ border-radius: var(--cratis-border-radius);
1551
+ background: var(--cratis-control-background);
1552
+ color: var(--cratis-text-color);
1553
+ font: inherit;
1554
+ }
1555
+ .cratis-dropdown__trigger {
1556
+ display: flex;
1557
+ padding: 0.625rem 2.25rem 0.625rem 0.75rem;
1558
+ align-items: center;
1559
+ justify-content: space-between;
1560
+ gap: 0.5rem;
1561
+ text-align: start;
1562
+ cursor: pointer;
1563
+ }
1564
+ .cratis-dropdown__filter {
1565
+ padding: 0.625rem 4rem 0.625rem 0.75rem;
1566
+ }
1567
+ .cratis-dropdown:not([data-disabled='true'])
1568
+ :is(.cratis-dropdown__trigger, .cratis-dropdown__filter):hover {
1569
+ border-color: var(--cratis-primary-300);
1570
+ background: var(--cratis-surface-hover);
1571
+ }
1572
+ .cratis-dropdown__trigger[data-pressed] {
1573
+ background: var(--cratis-highlight-bg);
1574
+ }
1575
+ .cratis-dropdown__multiple {
1576
+ padding: 0.4rem;
1577
+ }
1578
+ .cratis-dropdown__trigger:focus-visible,
1579
+ .cratis-dropdown__filter:focus-visible,
1580
+ .cratis-dropdown__multiple:focus-visible {
1581
+ outline: none;
1582
+ box-shadow: var(--cratis-focus-ring);
1583
+ border-color: var(--cratis-primary-color);
1584
+ }
1585
+ .cratis-dropdown[data-invalid='true']
1586
+ :is(.cratis-dropdown__trigger, .cratis-dropdown__filter, .cratis-dropdown__multiple) {
1587
+ border-color: var(--cratis-red-500);
1588
+ }
1589
+ .cratis-dropdown[data-disabled='true'] {
1590
+ opacity: var(--cratis-disabled-opacity);
1591
+ }
1592
+ .cratis-dropdown__value {
1593
+ min-width: 0;
1594
+ overflow: hidden;
1595
+ text-overflow: ellipsis;
1596
+ white-space: nowrap;
1597
+ }
1598
+ .cratis-dropdown__indicator {
1599
+ position: absolute;
1600
+ inset-inline-end: 0.55rem;
1601
+ top: 50%;
1602
+ display: inline-flex;
1603
+ width: 1.5rem;
1604
+ height: 1.5rem;
1605
+ padding: 0;
1606
+ align-items: center;
1607
+ justify-content: center;
1608
+ transform: translateY(-50%);
1609
+ border: 0;
1610
+ background: transparent;
1611
+ color: var(--cratis-text-color-secondary);
1612
+ }
1613
+ .cratis-dropdown__clear {
1614
+ position: absolute;
1615
+ inset-inline-end: 2.15rem;
1616
+ top: 50%;
1617
+ z-index: 1;
1618
+ display: inline-flex;
1619
+ width: 1.5rem;
1620
+ height: 1.5rem;
1621
+ padding: 0;
1622
+ align-items: center;
1623
+ justify-content: center;
1624
+ transform: translateY(-50%);
1625
+ border: 0;
1626
+ border-radius: 50%;
1627
+ background: transparent;
1628
+ color: var(--cratis-text-color-secondary);
1629
+ cursor: pointer;
1630
+ }
1631
+ .cratis-dropdown__clear:hover {
1632
+ background: var(--cratis-surface-hover);
1633
+ color: var(--cratis-text-color);
1634
+ }
1635
+ .cratis-dropdown__clear:focus-visible {
1636
+ outline: none;
1637
+ box-shadow: var(--cratis-focus-ring);
1638
+ }
1639
+ .cratis-dropdown__popover {
1640
+ z-index: var(--cratis-z-index-overlay);
1641
+ min-width: var(--trigger-width);
1642
+ max-height: min(20rem, var(--available-height));
1643
+ overflow: auto;
1644
+ border: 1px solid var(--cratis-surface-border);
1645
+ border-radius: var(--cratis-border-radius);
1646
+ background: var(--cratis-surface-overlay);
1647
+ color: var(--cratis-text-color);
1648
+ box-shadow: var(--cratis-shadow-overlay);
1649
+ }
1650
+ .cratis-dropdown__listbox {
1651
+ padding: 0.3rem;
1652
+ outline: none;
1653
+ }
1654
+ .cratis-dropdown__option {
1655
+ display: flex;
1656
+ min-height: var(--cratis-control-height);
1657
+ padding: 0.75rem 1.25rem;
1658
+ align-items: center;
1659
+ border-radius: calc(var(--cratis-border-radius) * 0.75);
1660
+ outline: none;
1661
+ cursor: default;
1662
+ }
1663
+ .cratis-dropdown__option[data-focused] {
1664
+ background: var(--cratis-surface-hover);
1665
+ }
1666
+ .cratis-dropdown__option[data-selected] {
1667
+ background: var(--cratis-highlight-bg);
1668
+ color: var(--cratis-highlight-text-color);
1669
+ }
1670
+ .cratis-dropdown__option[data-focus-visible] {
1671
+ box-shadow: inset var(--cratis-focus-ring);
1672
+ }
1673
+ .cratis-dropdown__option[data-disabled] {
1674
+ opacity: 0.5;
1675
+ }
1676
+
1677
+ @media (forced-colors: active) {
1678
+ .cratis-dropdown__trigger,
1679
+ .cratis-dropdown__filter,
1680
+ .cratis-dropdown__multiple,
1681
+ .cratis-dropdown__popover {
1682
+ border-color: CanvasText;
1683
+ }
1684
+ .cratis-dropdown__option[data-focused],
1685
+ .cratis-dropdown__option[data-selected] {
1686
+ outline: 2px solid Highlight;
1687
+ }
1688
+ }
1689
+
1690
+ /* ── ./Notifications/Toaster.css ─────────────────────────────────────── */
1691
+ /* Copyright (c) Cratis. All rights reserved. */
1692
+ /* Licensed under the MIT license. See LICENSE file in the project root for full license information. */
1693
+
1694
+ .cratis-toaster {
1695
+ position: fixed;
1696
+ z-index: var(--cratis-z-index-toast);
1697
+ display: flex;
1698
+ width: min(26rem, calc(100vw - 2rem));
1699
+ flex-direction: column;
1700
+ gap: 0.75rem;
1701
+ pointer-events: none;
1702
+ }
1703
+ .cratis-toaster[data-position^='top'] {
1704
+ top: 1rem;
1705
+ }
1706
+ .cratis-toaster[data-position^='bottom'] {
1707
+ bottom: 1rem;
1708
+ }
1709
+ .cratis-toaster[data-position$='left'] {
1710
+ left: 1rem;
1711
+ }
1712
+ .cratis-toaster[data-position$='right'] {
1713
+ right: 1rem;
1714
+ }
1715
+ .cratis-toaster[data-position$='center'] {
1716
+ left: 50%;
1717
+ transform: translateX(-50%);
1718
+ }
1719
+
1720
+ .cratis-toast {
1721
+ display: flex;
1722
+ min-width: 18rem;
1723
+ max-width: 26rem;
1724
+ padding: 0.75rem 1rem;
1725
+ align-items: flex-start;
1726
+ gap: 0.625rem;
1727
+ border: 1px solid var(--cratis-surface-border);
1728
+ border-inline-start: 4px solid var(--cratis-surface-border);
1729
+ border-radius: var(--cratis-border-radius);
1730
+ background: var(--cratis-surface-overlay);
1731
+ color: var(--cratis-text-color);
1732
+ box-shadow: var(--cratis-shadow-toast);
1733
+ pointer-events: auto;
1734
+ }
1735
+ .cratis-toast__content {
1736
+ display: flex;
1737
+ min-width: 0;
1738
+ flex: 1;
1739
+ flex-direction: column;
1740
+ gap: 0.125rem;
1741
+ }
1742
+ .cratis-toast__title {
1743
+ font-weight: 600;
1744
+ }
1745
+ .cratis-toast__description {
1746
+ color: var(--cratis-text-color-secondary);
1747
+ font-size: 0.875rem;
1748
+ white-space: pre-line;
1749
+ }
1750
+ .cratis-toast__icon {
1751
+ flex: 0 0 auto;
1752
+ }
1753
+ .cratis-toast__close {
1754
+ display: inline-flex;
1755
+ width: 1.75rem;
1756
+ height: 1.75rem;
1757
+ padding: 0;
1758
+ align-items: center;
1759
+ justify-content: center;
1760
+ border: 0;
1761
+ border-radius: 50%;
1762
+ background: transparent;
1763
+ color: var(--cratis-text-color-secondary);
1764
+ cursor: pointer;
1765
+ }
1766
+ .cratis-toast__close:hover {
1767
+ background: var(--cratis-surface-hover);
1768
+ color: var(--cratis-text-color);
1769
+ }
1770
+ .cratis-toast__close:focus-visible {
1771
+ outline: none;
1772
+ box-shadow: var(--cratis-focus-ring);
1773
+ }
1774
+ .cratis-toast__action {
1775
+ align-self: flex-start;
1776
+ margin-top: 0.4rem;
1777
+ }
1778
+ .cratis-toast[data-loading='true'] .cratis-toast__icon {
1779
+ animation: cratis-toast-spin 800ms linear infinite;
1780
+ }
1781
+ .cratis-toast[data-severity='success'] {
1782
+ border-inline-start-color: var(--cratis-green-500);
1783
+ }
1784
+ .cratis-toast[data-severity='info'] {
1785
+ border-inline-start-color: var(--cratis-primary-color);
1786
+ }
1787
+ .cratis-toast[data-severity='warn'] {
1788
+ border-inline-start-color: var(--cratis-orange-500);
1789
+ }
1790
+ .cratis-toast[data-severity='error'] {
1791
+ border-inline-start-color: var(--cratis-red-500);
1792
+ }
1793
+ .cratis-toast[data-severity='success'] .cratis-toast__icon {
1794
+ color: var(--cratis-green-500);
1795
+ }
1796
+ .cratis-toast[data-severity='info'] .cratis-toast__icon {
1797
+ color: var(--cratis-primary-color);
1798
+ }
1799
+ .cratis-toast[data-severity='warn'] .cratis-toast__icon {
1800
+ color: var(--cratis-orange-500);
1801
+ }
1802
+ .cratis-toast[data-severity='error'] .cratis-toast__icon {
1803
+ color: var(--cratis-red-500);
1804
+ }
1805
+
1806
+ @keyframes cratis-toast-spin {
1807
+ to {
1808
+ transform: rotate(360deg);
1809
+ }
1810
+ }
1811
+ @media (prefers-reduced-motion: reduce) {
1812
+ .cratis-toast__icon {
1813
+ animation: none !important;
1814
+ }
1815
+ }
1816
+ @media (forced-colors: active) {
1817
+ .cratis-toast {
1818
+ border-color: CanvasText;
1819
+ }
1820
+ .cratis-toast__close:focus-visible {
1821
+ outline: 2px solid Highlight;
1822
+ outline-offset: 2px;
1823
+ box-shadow: none;
1824
+ }
1825
+ }
1826
+
1827
+ }