@birdycom/omniaui 0.11.0 → 0.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.
- package/LICENSE +21 -21
- package/README.md +21 -21
- package/bin/lib/add.mjs +126 -126
- package/bin/lib/catalog.mjs +169 -169
- package/bin/lib/project.mjs +90 -90
- package/bin/omniaui.mjs +69 -69
- package/dist/code-block.css +25 -25
- package/dist/components-extra.css +916 -914
- package/dist/components.css +6559 -6469
- package/dist/components.min.css +1 -1
- package/dist/data-table.d.ts +9 -9
- package/dist/data-table.js +505 -505
- package/dist/docs-ui.css +267 -265
- package/dist/oc-theme.css +69 -69
- package/dist/parts/app-accordion-accent.css +60 -60
- package/dist/parts/app-alpha-tabs.css +68 -68
- package/dist/parts/app-busy-overlay.css +25 -25
- package/dist/parts/app-column-menu.css +85 -85
- package/dist/parts/app-confirm-dialog.css +70 -70
- package/dist/parts/app-cookie-consent.css +63 -63
- package/dist/parts/app-data-table.css +174 -174
- package/dist/parts/app-greeting.css +47 -47
- package/dist/parts/app-list-toolbar.css +81 -81
- package/dist/parts/app-page-header.css +54 -54
- package/dist/parts/app-severity-card.css +91 -91
- package/dist/parts/app-sidebar-dark.css +15 -15
- package/dist/parts/app-sortable-row.css +52 -52
- package/dist/parts/app-stat-card.css +68 -68
- package/dist/parts/app-table-actions.css +71 -71
- package/dist/parts/app-table-compact.css +54 -54
- package/dist/parts/app-top-progress.css +68 -68
- package/dist/parts/app-tree.css +104 -104
- package/dist/parts/app-upgrade-banner.css +90 -90
- package/dist/parts/app-version-banner.css +80 -80
- package/dist/parts/data-chart-line.css +167 -167
- package/dist/parts/forms-affix-input.css +75 -75
- package/dist/parts/forms-barcode-input.css +75 -75
- package/dist/parts/forms-chip-filter.css +91 -91
- package/dist/parts/forms-color-select.css +97 -89
- package/dist/parts/forms-decimal-input.css +51 -51
- package/dist/parts/forms-filter-counts.css +94 -94
- package/dist/parts/forms-language-select.css +89 -76
- package/dist/parts/forms-number-input.css +98 -95
- package/dist/parts/forms-password-requirements.css +55 -55
- package/dist/parts/forms-phone-input.css +85 -85
- package/dist/parts/forms-time-input.css +74 -74
- package/dist/parts/forms-toggle-field.css +69 -69
- package/dist/parts/media-art.css +21 -21
- package/dist/parts/media-attachment.css +160 -160
- package/dist/parts/media-browser-frame.css +73 -73
- package/dist/parts/media-card.css +83 -83
- package/dist/parts/media-chat-composer.css +90 -90
- package/dist/parts/media-doc-viewer.css +151 -151
- package/dist/parts/media-emoji-picker.css +88 -88
- package/dist/parts/media-entity-card.css +52 -52
- package/dist/parts/media-flip-card.css +78 -78
- package/dist/parts/media-image-zoom.css +68 -68
- package/dist/parts/media-lightbox.css +131 -131
- package/dist/parts/media-message-thread.css +136 -136
- package/dist/parts/media-message.css +160 -160
- package/dist/parts/media-row.css +78 -78
- package/dist/parts/media-stack-card.css +82 -82
- package/dist/parts/media-terminal-log.css +76 -76
- package/dist/parts/media-thumb.css +71 -71
- package/dist/parts/site-fact-list.css +25 -25
- package/dist/parts/site-link-arrow.css +34 -34
- package/dist/parts/site-marquee.css +34 -34
- package/dist/parts/site-next-teaser.css +75 -75
- package/dist/parts/site-price-card.css +91 -75
- package/dist/parts/site-product-mark.css +66 -66
- package/dist/parts/site-project-card.css +111 -111
- package/dist/parts/site-prose.css +124 -124
- package/dist/parts/site-stack-list.css +48 -48
- package/dist/parts/site-timeline.css +54 -54
- package/dist/showcase.css +404 -404
- package/package.json +69 -69
- package/snippets/accordion-accent.html +24 -24
- package/snippets/accordion.html +11 -11
- package/snippets/affix-input.html +30 -30
- package/snippets/alert-dialog.html +22 -22
- package/snippets/alert.html +5 -5
- package/snippets/alpha-tabs.html +37 -37
- package/snippets/aspect-ratio.html +15 -15
- package/snippets/attachment.html +43 -43
- package/snippets/avatar.html +6 -6
- package/snippets/back-link.html +5 -5
- package/snippets/badge.html +5 -5
- package/snippets/barcode-input.html +18 -18
- package/snippets/breadcrumb.html +6 -6
- package/snippets/browser-frame.html +18 -18
- package/snippets/busy-overlay.html +31 -31
- package/snippets/button-group.html +21 -21
- package/snippets/button.html +8 -8
- package/snippets/calendar.html +43 -43
- package/snippets/card.html +17 -17
- package/snippets/carousel.html +21 -21
- package/snippets/chart-line.html +46 -46
- package/snippets/chart.html +27 -27
- package/snippets/chat-composer.html +21 -21
- package/snippets/checkbox.html +5 -5
- package/snippets/checklist.html +23 -23
- package/snippets/chip-filter.html +14 -14
- package/snippets/code-window.html +20 -20
- package/snippets/collapsible.html +19 -19
- package/snippets/color-field.html +13 -13
- package/snippets/color-select.html +18 -18
- package/snippets/column-menu.html +38 -38
- package/snippets/combobox.html +19 -19
- package/snippets/command.html +24 -24
- package/snippets/confirm-dialog.html +32 -32
- package/snippets/context-menu.html +25 -25
- package/snippets/cookie-consent.html +70 -70
- package/snippets/copy-field.html +19 -19
- package/snippets/counter.html +2 -2
- package/snippets/data-table.html +151 -151
- package/snippets/date-picker.html +32 -32
- package/snippets/decimal-input.html +20 -20
- package/snippets/definition-list.html +20 -20
- package/snippets/demo-panel.html +18 -18
- package/snippets/doc-viewer.html +58 -58
- package/snippets/drawer.html +30 -30
- package/snippets/dropdown-menu.html +27 -27
- package/snippets/dropdown.html +9 -9
- package/snippets/dropzone.html +13 -13
- package/snippets/emoji-picker.html +51 -51
- package/snippets/empty-state.html +17 -17
- package/snippets/entity-card.html +26 -26
- package/snippets/expandable-table.html +26 -26
- package/snippets/fact-list.html +14 -14
- package/snippets/filter-counts.html +30 -30
- package/snippets/flip-card.html +22 -22
- package/snippets/form-field.html +6 -6
- package/snippets/greeting.html +22 -22
- package/snippets/heading.html +14 -14
- package/snippets/hover-card.html +18 -18
- package/snippets/image-zoom.html +30 -30
- package/snippets/input-group.html +10 -10
- package/snippets/input.html +5 -5
- package/snippets/item.html +26 -26
- package/snippets/kbd.html +13 -13
- package/snippets/label.html +9 -9
- package/snippets/language-select.html +26 -26
- package/snippets/launcher-card.html +14 -14
- package/snippets/lightbox.html +50 -50
- package/snippets/link-arrow.html +10 -10
- package/snippets/list-toolbar.html +33 -33
- package/snippets/marquee.html +15 -15
- package/snippets/media-card.html +28 -28
- package/snippets/media-row.html +21 -21
- package/snippets/media-thumb.html +12 -12
- package/snippets/menubar.html +30 -30
- package/snippets/message-thread.html +123 -123
- package/snippets/message.html +51 -51
- package/snippets/modal.html +15 -15
- package/snippets/native-select.html +15 -15
- package/snippets/navmenu.html +23 -23
- package/snippets/next-teaser.html +15 -15
- package/snippets/number-input.html +27 -27
- package/snippets/otp-input.html +9 -9
- package/snippets/page-header.html +24 -24
- package/snippets/pagination.html +6 -6
- package/snippets/password-input.html +24 -24
- package/snippets/password-requirements.html +30 -30
- package/snippets/phone-input.html +22 -22
- package/snippets/popover.html +15 -15
- package/snippets/price-card.html +34 -34
- package/snippets/product-mark.html +13 -13
- package/snippets/progress.html +4 -4
- package/snippets/project-card.html +23 -23
- package/snippets/prose.html +54 -54
- package/snippets/radio.html +17 -17
- package/snippets/recovery-codes.html +20 -20
- package/snippets/resizable.html +16 -16
- package/snippets/scroll-area.html +20 -20
- package/snippets/search.html +8 -8
- package/snippets/segmented.html +11 -11
- package/snippets/select.html +7 -7
- package/snippets/separator.html +15 -15
- package/snippets/severity-card.html +35 -35
- package/snippets/sheet.html +32 -32
- package/snippets/sidebar-docs.html +24 -24
- package/snippets/sidebar.html +55 -55
- package/snippets/site-footer.html +6 -6
- package/snippets/site-header.html +26 -26
- package/snippets/skeleton.html +4 -4
- package/snippets/slider.html +17 -17
- package/snippets/sortable-row.html +31 -31
- package/snippets/spinner.html +14 -14
- package/snippets/stack-card.html +17 -17
- package/snippets/stack-list.html +16 -16
- package/snippets/stat-card.html +24 -24
- package/snippets/stepper.html +13 -13
- package/snippets/switch.html +6 -6
- package/snippets/table-actions.html +39 -39
- package/snippets/table-compact.html +24 -24
- package/snippets/table.html +29 -29
- package/snippets/tabs.html +9 -9
- package/snippets/tag-input.html +60 -17
- package/snippets/terminal-log.html +23 -23
- package/snippets/textarea.html +3 -3
- package/snippets/theme-switch.html +6 -6
- package/snippets/time-input.html +26 -26
- package/snippets/timeline.html +28 -28
- package/snippets/toast-stack.html +10 -10
- package/snippets/toast.html +36 -36
- package/snippets/toc.html +13 -13
- package/snippets/toggle-field.html +20 -20
- package/snippets/toggle.html +22 -22
- package/snippets/tooltip.html +4 -4
- package/snippets/top-progress.html +12 -12
- package/snippets/tree.html +38 -38
- package/snippets/upgrade-banner.html +28 -28
- package/snippets/user.html +15 -15
- package/snippets/version-banner.html +15 -15
|
@@ -1,91 +1,91 @@
|
|
|
1
|
-
/* File: packages/ui/src/parts/forms-chip-filter.css
|
|
2
|
-
Map: group -> chip (label + hidden checkbox/radio) -> count bubble -> states -> --scroll / --sm
|
|
3
|
-
Chip filter: rounded filter chips. Checkboxes = pick several, radios = pick one.
|
|
4
|
-
:has(input:checked) highlights the chip; no JavaScript. */
|
|
5
|
-
|
|
6
|
-
/* Group: wrapping row of chips. */
|
|
7
|
-
.oc-chip-filter {
|
|
8
|
-
display: flex;
|
|
9
|
-
flex-wrap: wrap;
|
|
10
|
-
gap: 0.5rem;
|
|
11
|
-
margin: 0;
|
|
12
|
-
padding: 0;
|
|
13
|
-
border: 0;
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
/* Chip: pill-shaped label around one input. */
|
|
17
|
-
.oc-chip-filter-item {
|
|
18
|
-
position: relative;
|
|
19
|
-
display: inline-flex;
|
|
20
|
-
align-items: center;
|
|
21
|
-
gap: 0.375rem;
|
|
22
|
-
padding: 0.3rem 0.85rem;
|
|
23
|
-
border: 1px solid var(--oc-border);
|
|
24
|
-
border-radius: 999px;
|
|
25
|
-
background: transparent;
|
|
26
|
-
color: var(--oc-muted-foreground);
|
|
27
|
-
font-size: 0.8rem;
|
|
28
|
-
font-weight: 500;
|
|
29
|
-
white-space: nowrap;
|
|
30
|
-
cursor: pointer;
|
|
31
|
-
user-select: none;
|
|
32
|
-
transition: background var(--oc-transition-fast), color var(--oc-transition-fast), border-color var(--oc-transition-fast);
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
/* Invisible but focusable input. */
|
|
36
|
-
.oc-chip-filter-item input {
|
|
37
|
-
position: absolute;
|
|
38
|
-
inset: 0;
|
|
39
|
-
margin: 0;
|
|
40
|
-
opacity: 0;
|
|
41
|
-
cursor: pointer;
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
.oc-chip-filter-item:hover {
|
|
45
|
-
border-color: var(--oc-border-strong);
|
|
46
|
-
color: var(--oc-foreground);
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
/* Selected: tinted primary background and border. */
|
|
50
|
-
.oc-chip-filter-item:has(input:checked) {
|
|
51
|
-
border-color: var(--oc-primary);
|
|
52
|
-
background: color-mix(in srgb, var(--oc-primary) 14%, transparent);
|
|
53
|
-
color: var(--oc-foreground);
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
.oc-chip-filter-item:has(input:focus-visible) {
|
|
57
|
-
outline: 2px solid var(--oc-ring);
|
|
58
|
-
outline-offset: 2px;
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
.oc-chip-filter-item:has(input:disabled) {
|
|
62
|
-
opacity: 0.45;
|
|
63
|
-
cursor: not-allowed;
|
|
64
|
-
}
|
|
65
|
-
|
|
66
|
-
/* Optional count bubble inside a chip. */
|
|
67
|
-
.oc-chip-filter-count {
|
|
68
|
-
min-inline-size: 1.25rem;
|
|
69
|
-
padding: 0 0.35rem;
|
|
70
|
-
border-radius: 999px;
|
|
71
|
-
background: var(--oc-surface-strong);
|
|
72
|
-
font-size: 0.7rem;
|
|
73
|
-
font-variant-numeric: tabular-nums;
|
|
74
|
-
text-align: center;
|
|
75
|
-
}
|
|
76
|
-
|
|
77
|
-
.oc-chip-filter-item:has(input:checked) .oc-chip-filter-count {
|
|
78
|
-
background: var(--oc-primary);
|
|
79
|
-
color: var(--oc-primary-foreground);
|
|
80
|
-
}
|
|
81
|
-
|
|
82
|
-
/* Scroll: one line that scrolls sideways (mobile toolbars). */
|
|
83
|
-
.oc-chip-filter--scroll {
|
|
84
|
-
flex-wrap: nowrap;
|
|
85
|
-
overflow-x: auto;
|
|
86
|
-
padding-block: 0.25rem;
|
|
87
|
-
scrollbar-width: thin;
|
|
88
|
-
}
|
|
89
|
-
|
|
90
|
-
/* Small chips. */
|
|
91
|
-
.oc-chip-filter--sm .oc-chip-filter-item { padding: 0.15rem 0.6rem; font-size: 0.72rem; }
|
|
1
|
+
/* File: packages/ui/src/parts/forms-chip-filter.css
|
|
2
|
+
Map: group -> chip (label + hidden checkbox/radio) -> count bubble -> states -> --scroll / --sm
|
|
3
|
+
Chip filter: rounded filter chips. Checkboxes = pick several, radios = pick one.
|
|
4
|
+
:has(input:checked) highlights the chip; no JavaScript. */
|
|
5
|
+
|
|
6
|
+
/* Group: wrapping row of chips. */
|
|
7
|
+
.oc-chip-filter {
|
|
8
|
+
display: flex;
|
|
9
|
+
flex-wrap: wrap;
|
|
10
|
+
gap: 0.5rem;
|
|
11
|
+
margin: 0;
|
|
12
|
+
padding: 0;
|
|
13
|
+
border: 0;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
/* Chip: pill-shaped label around one input. */
|
|
17
|
+
.oc-chip-filter-item {
|
|
18
|
+
position: relative;
|
|
19
|
+
display: inline-flex;
|
|
20
|
+
align-items: center;
|
|
21
|
+
gap: 0.375rem;
|
|
22
|
+
padding: 0.3rem 0.85rem;
|
|
23
|
+
border: 1px solid var(--oc-border);
|
|
24
|
+
border-radius: 999px;
|
|
25
|
+
background: transparent;
|
|
26
|
+
color: var(--oc-muted-foreground);
|
|
27
|
+
font-size: 0.8rem;
|
|
28
|
+
font-weight: 500;
|
|
29
|
+
white-space: nowrap;
|
|
30
|
+
cursor: pointer;
|
|
31
|
+
user-select: none;
|
|
32
|
+
transition: background var(--oc-transition-fast), color var(--oc-transition-fast), border-color var(--oc-transition-fast);
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
/* Invisible but focusable input. */
|
|
36
|
+
.oc-chip-filter-item input {
|
|
37
|
+
position: absolute;
|
|
38
|
+
inset: 0;
|
|
39
|
+
margin: 0;
|
|
40
|
+
opacity: 0;
|
|
41
|
+
cursor: pointer;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
.oc-chip-filter-item:hover {
|
|
45
|
+
border-color: var(--oc-border-strong);
|
|
46
|
+
color: var(--oc-foreground);
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
/* Selected: tinted primary background and border. */
|
|
50
|
+
.oc-chip-filter-item:has(input:checked) {
|
|
51
|
+
border-color: var(--oc-primary);
|
|
52
|
+
background: color-mix(in srgb, var(--oc-primary) 14%, transparent);
|
|
53
|
+
color: var(--oc-foreground);
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
.oc-chip-filter-item:has(input:focus-visible) {
|
|
57
|
+
outline: 2px solid var(--oc-ring);
|
|
58
|
+
outline-offset: 2px;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
.oc-chip-filter-item:has(input:disabled) {
|
|
62
|
+
opacity: 0.45;
|
|
63
|
+
cursor: not-allowed;
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
/* Optional count bubble inside a chip. */
|
|
67
|
+
.oc-chip-filter-count {
|
|
68
|
+
min-inline-size: 1.25rem;
|
|
69
|
+
padding: 0 0.35rem;
|
|
70
|
+
border-radius: 999px;
|
|
71
|
+
background: var(--oc-surface-strong);
|
|
72
|
+
font-size: 0.7rem;
|
|
73
|
+
font-variant-numeric: tabular-nums;
|
|
74
|
+
text-align: center;
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
.oc-chip-filter-item:has(input:checked) .oc-chip-filter-count {
|
|
78
|
+
background: var(--oc-primary);
|
|
79
|
+
color: var(--oc-primary-foreground);
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
/* Scroll: one line that scrolls sideways (mobile toolbars). */
|
|
83
|
+
.oc-chip-filter--scroll {
|
|
84
|
+
flex-wrap: nowrap;
|
|
85
|
+
overflow-x: auto;
|
|
86
|
+
padding-block: 0.25rem;
|
|
87
|
+
scrollbar-width: thin;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
/* Small chips. */
|
|
91
|
+
.oc-chip-filter--sm .oc-chip-filter-item { padding: 0.15rem 0.6rem; font-size: 0.72rem; }
|
|
@@ -1,89 +1,97 @@
|
|
|
1
|
-
/* File: packages/ui/src/parts/forms-color-select.css
|
|
2
|
-
Map: group (swatch grid) -> option (label + hidden radio) -> swatch -> states -> --list variant (swatch + name) -> --sm
|
|
3
|
-
Color select: pick one color from a set of swatches. Radio inputs inside labels, so keyboard,
|
|
4
|
-
forms and "name" grouping work natively. Each option sets its color with --oc-swatch (an Omnia token). */
|
|
5
|
-
|
|
6
|
-
/* Group: wrapping row of swatches (role="radiogroup"). */
|
|
7
|
-
.oc-color-select {
|
|
8
|
-
display: flex;
|
|
9
|
-
flex-wrap: wrap;
|
|
10
|
-
gap: 0.5rem;
|
|
11
|
-
margin: 0;
|
|
12
|
-
padding: 0;
|
|
13
|
-
border: 0;
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
/* Option: the label around one radio. --oc-swatch is set inline, e.g. style="--oc-swatch: var(--color-red-70)". */
|
|
17
|
-
.oc-color-select-option {
|
|
18
|
-
--oc-swatch: var(--oc-muted);
|
|
19
|
-
position: relative;
|
|
20
|
-
display: inline-flex;
|
|
21
|
-
align-items: center;
|
|
22
|
-
gap: 0.5rem;
|
|
23
|
-
border-radius: 999px;
|
|
24
|
-
color: var(--oc-foreground);
|
|
25
|
-
font-size: 0.875rem;
|
|
26
|
-
cursor: pointer;
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
/* The radio is invisible but stays focusable. */
|
|
30
|
-
.oc-color-select-option input {
|
|
31
|
-
position: absolute;
|
|
32
|
-
inset: 0;
|
|
33
|
-
margin: 0;
|
|
34
|
-
opacity: 0;
|
|
35
|
-
cursor: pointer;
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
/* Swatch: round color dot with a thin inner border so light colors stay visible. */
|
|
39
|
-
.oc-color-select-swatch {
|
|
40
|
-
flex: none;
|
|
41
|
-
inline-size: 1.75rem;
|
|
42
|
-
block-size: 1.75rem;
|
|
43
|
-
border-radius: 999px;
|
|
44
|
-
background: var(--oc-swatch);
|
|
45
|
-
box-shadow: inset 0 0 0 1px oklch(from var(--oc-foreground) l c h / 0.15);
|
|
46
|
-
transition: box-shadow var(--oc-transition-fast), transform var(--oc-transition-fast);
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
.oc-color-select-option:hover .oc-color-select-swatch { transform: scale(1.08); }
|
|
50
|
-
|
|
51
|
-
/* Selected: a ring in the background color, then a ring in the swatch color. */
|
|
52
|
-
.oc-color-select-option:has(input:checked) .oc-color-select-swatch {
|
|
53
|
-
box-shadow: 0 0 0 2px var(--oc-background), 0 0 0 4px var(--oc-swatch);
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
.oc-color-select-option:has(input:focus-visible) .oc-color-select-swatch {
|
|
57
|
-
outline: 2px solid var(--oc-ring);
|
|
58
|
-
outline-offset: 4px;
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
.
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
.oc-color-select-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
}
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
.oc-color-select--list
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
1
|
+
/* File: packages/ui/src/parts/forms-color-select.css
|
|
2
|
+
Map: group (swatch grid) -> option (label + hidden radio) -> swatch -> states -> --list variant (swatch + name) -> --sm
|
|
3
|
+
Color select: pick one color from a set of swatches. Radio inputs inside labels, so keyboard,
|
|
4
|
+
forms and "name" grouping work natively. Each option sets its color with --oc-swatch (an Omnia token). */
|
|
5
|
+
|
|
6
|
+
/* Group: wrapping row of swatches (role="radiogroup"). */
|
|
7
|
+
.oc-color-select {
|
|
8
|
+
display: flex;
|
|
9
|
+
flex-wrap: wrap;
|
|
10
|
+
gap: 0.5rem;
|
|
11
|
+
margin: 0;
|
|
12
|
+
padding: 0;
|
|
13
|
+
border: 0;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
/* Option: the label around one radio. --oc-swatch is set inline, e.g. style="--oc-swatch: var(--color-red-70)". */
|
|
17
|
+
.oc-color-select-option {
|
|
18
|
+
--oc-swatch: var(--oc-muted);
|
|
19
|
+
position: relative;
|
|
20
|
+
display: inline-flex;
|
|
21
|
+
align-items: center;
|
|
22
|
+
gap: 0.5rem;
|
|
23
|
+
border-radius: 999px;
|
|
24
|
+
color: var(--oc-foreground);
|
|
25
|
+
font-size: 0.875rem;
|
|
26
|
+
cursor: pointer;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
/* The radio is invisible but stays focusable. */
|
|
30
|
+
.oc-color-select-option input {
|
|
31
|
+
position: absolute;
|
|
32
|
+
inset: 0;
|
|
33
|
+
margin: 0;
|
|
34
|
+
opacity: 0;
|
|
35
|
+
cursor: pointer;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
/* Swatch: round color dot with a thin inner border so light colors stay visible. */
|
|
39
|
+
.oc-color-select-swatch {
|
|
40
|
+
flex: none;
|
|
41
|
+
inline-size: 1.75rem;
|
|
42
|
+
block-size: 1.75rem;
|
|
43
|
+
border-radius: 999px;
|
|
44
|
+
background: var(--oc-swatch);
|
|
45
|
+
box-shadow: inset 0 0 0 1px oklch(from var(--oc-foreground) l c h / 0.15);
|
|
46
|
+
transition: box-shadow var(--oc-transition-fast), transform var(--oc-transition-fast);
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
.oc-color-select-option:hover .oc-color-select-swatch { transform: scale(1.08); }
|
|
50
|
+
|
|
51
|
+
/* Selected: a ring in the background color, then a ring in the swatch color. */
|
|
52
|
+
.oc-color-select-option:has(input:checked) .oc-color-select-swatch {
|
|
53
|
+
box-shadow: 0 0 0 2px var(--oc-background), 0 0 0 4px var(--oc-swatch);
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
.oc-color-select-option:has(input:focus-visible) .oc-color-select-swatch {
|
|
57
|
+
outline: 2px solid var(--oc-ring);
|
|
58
|
+
outline-offset: 4px;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
/* Disabled (e.g. a color already in use): faded, a diagonal line through the swatch, no hover zoom.
|
|
62
|
+
Give the label a title ("Purple, in use") so the reason shows on hover. */
|
|
63
|
+
.oc-color-select-option:has(input:disabled) {
|
|
64
|
+
opacity: 0.55;
|
|
65
|
+
cursor: not-allowed;
|
|
66
|
+
}
|
|
67
|
+
.oc-color-select-option:has(input:disabled) .oc-color-select-swatch {
|
|
68
|
+
background:
|
|
69
|
+
linear-gradient(135deg, transparent calc(50% - 1.5px), var(--oc-background) calc(50% - 1.5px) calc(50% + 1.5px), transparent calc(50% + 1.5px)),
|
|
70
|
+
var(--oc-swatch);
|
|
71
|
+
transform: none;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
/* Name next to the swatch (visible in --list; screen-reader text in the grid). */
|
|
75
|
+
.oc-color-select-name { line-height: 1.2; }
|
|
76
|
+
.oc-color-select:not(.oc-color-select--list) .oc-color-select-name {
|
|
77
|
+
position: absolute;
|
|
78
|
+
inline-size: 1px;
|
|
79
|
+
block-size: 1px;
|
|
80
|
+
overflow: hidden;
|
|
81
|
+
clip-path: inset(50%);
|
|
82
|
+
white-space: nowrap;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
/* List variant: one row per color with its name, e.g. inside a popover. */
|
|
86
|
+
.oc-color-select--list { flex-direction: column; gap: 0.125rem; }
|
|
87
|
+
.oc-color-select--list .oc-color-select-option {
|
|
88
|
+
padding: 0.375rem 0.5rem;
|
|
89
|
+
border-radius: calc(var(--oc-radius) - 2px);
|
|
90
|
+
}
|
|
91
|
+
.oc-color-select--list .oc-color-select-option:hover { background: var(--oc-surface); }
|
|
92
|
+
.oc-color-select--list .oc-color-select-option:has(input:checked) { background: var(--oc-surface-strong); font-weight: 500; }
|
|
93
|
+
.oc-color-select--list .oc-color-select-swatch { inline-size: 1rem; block-size: 1rem; }
|
|
94
|
+
.oc-color-select--list .oc-color-select-option:hover .oc-color-select-swatch { transform: none; }
|
|
95
|
+
|
|
96
|
+
/* Small swatches. */
|
|
97
|
+
.oc-color-select--sm .oc-color-select-swatch { inline-size: 1.25rem; block-size: 1.25rem; }
|
|
@@ -1,51 +1,51 @@
|
|
|
1
|
-
/* File: packages/ui/src/parts/forms-decimal-input.css
|
|
2
|
-
Map: field (right-aligned tabular digits) -> unit suffix wrapper -> states -> --start alignment
|
|
3
|
-
Decimal input: a text field for locale numbers like 1.234,56 (inputmode="decimal").
|
|
4
|
-
Plain HTML validates with pattern + :user-invalid; the React/Vue wrappers format the value on blur. */
|
|
5
|
-
|
|
6
|
-
/* Field: add next to .oc-input. Digits line up in columns (tabular figures). */
|
|
7
|
-
.oc-decimal-input {
|
|
8
|
-
text-align: end;
|
|
9
|
-
font-variant-numeric: tabular-nums;
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
/* Left-aligned variant, e.g. inside a sentence or a narrow table cell. */
|
|
13
|
-
.oc-decimal-input--start { text-align: start; }
|
|
14
|
-
|
|
15
|
-
/* Wrapper with a unit after the value (m², kg, h). The unit sits inside the frame. */
|
|
16
|
-
.oc-decimal-field {
|
|
17
|
-
display: flex;
|
|
18
|
-
align-items: center;
|
|
19
|
-
border: 1px solid var(--oc-input);
|
|
20
|
-
border-radius: var(--oc-radius);
|
|
21
|
-
transition: border-color var(--oc-transition-fast), box-shadow var(--oc-transition-fast);
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
.oc-decimal-field:focus-within {
|
|
25
|
-
border-color: var(--oc-ring);
|
|
26
|
-
box-shadow: 0 0 0 2px color-mix(in srgb, var(--oc-ring) 25%, transparent);
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
/* Inside the wrapper the input has no frame of its own. */
|
|
30
|
-
.oc-decimal-field > .oc-decimal-input {
|
|
31
|
-
flex: 1;
|
|
32
|
-
min-inline-size: 0;
|
|
33
|
-
border: 0;
|
|
34
|
-
box-shadow: none;
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
.oc-decimal-field-unit {
|
|
38
|
-
padding-inline: 0 0.75rem;
|
|
39
|
-
color: var(--oc-muted-foreground);
|
|
40
|
-
font-size: 0.875rem;
|
|
41
|
-
white-space: nowrap;
|
|
42
|
-
pointer-events: none;
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
/* Invalid after user input (pattern mismatch), or via aria-invalid. */
|
|
46
|
-
.oc-decimal-input:user-invalid { border-color: var(--oc-destructive); }
|
|
47
|
-
.oc-decimal-field:has(.oc-decimal-input:user-invalid),
|
|
48
|
-
.oc-decimal-field:has([aria-invalid="true"]) { border-color: var(--oc-destructive); }
|
|
49
|
-
|
|
50
|
-
/* Disabled wrapper. */
|
|
51
|
-
.oc-decimal-field:has(.oc-decimal-input:disabled) { opacity: 0.5; cursor: not-allowed; }
|
|
1
|
+
/* File: packages/ui/src/parts/forms-decimal-input.css
|
|
2
|
+
Map: field (right-aligned tabular digits) -> unit suffix wrapper -> states -> --start alignment
|
|
3
|
+
Decimal input: a text field for locale numbers like 1.234,56 (inputmode="decimal").
|
|
4
|
+
Plain HTML validates with pattern + :user-invalid; the React/Vue wrappers format the value on blur. */
|
|
5
|
+
|
|
6
|
+
/* Field: add next to .oc-input. Digits line up in columns (tabular figures). */
|
|
7
|
+
.oc-decimal-input {
|
|
8
|
+
text-align: end;
|
|
9
|
+
font-variant-numeric: tabular-nums;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
/* Left-aligned variant, e.g. inside a sentence or a narrow table cell. */
|
|
13
|
+
.oc-decimal-input--start { text-align: start; }
|
|
14
|
+
|
|
15
|
+
/* Wrapper with a unit after the value (m², kg, h). The unit sits inside the frame. */
|
|
16
|
+
.oc-decimal-field {
|
|
17
|
+
display: flex;
|
|
18
|
+
align-items: center;
|
|
19
|
+
border: 1px solid var(--oc-input);
|
|
20
|
+
border-radius: var(--oc-radius);
|
|
21
|
+
transition: border-color var(--oc-transition-fast), box-shadow var(--oc-transition-fast);
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
.oc-decimal-field:focus-within {
|
|
25
|
+
border-color: var(--oc-ring);
|
|
26
|
+
box-shadow: 0 0 0 2px color-mix(in srgb, var(--oc-ring) 25%, transparent);
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
/* Inside the wrapper the input has no frame of its own. */
|
|
30
|
+
.oc-decimal-field > .oc-decimal-input {
|
|
31
|
+
flex: 1;
|
|
32
|
+
min-inline-size: 0;
|
|
33
|
+
border: 0;
|
|
34
|
+
box-shadow: none;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
.oc-decimal-field-unit {
|
|
38
|
+
padding-inline: 0 0.75rem;
|
|
39
|
+
color: var(--oc-muted-foreground);
|
|
40
|
+
font-size: 0.875rem;
|
|
41
|
+
white-space: nowrap;
|
|
42
|
+
pointer-events: none;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
/* Invalid after user input (pattern mismatch), or via aria-invalid. */
|
|
46
|
+
.oc-decimal-input:user-invalid { border-color: var(--oc-destructive); }
|
|
47
|
+
.oc-decimal-field:has(.oc-decimal-input:user-invalid),
|
|
48
|
+
.oc-decimal-field:has([aria-invalid="true"]) { border-color: var(--oc-destructive); }
|
|
49
|
+
|
|
50
|
+
/* Disabled wrapper. */
|
|
51
|
+
.oc-decimal-field:has(.oc-decimal-input:disabled) { opacity: 0.5; cursor: not-allowed; }
|
|
@@ -1,94 +1,94 @@
|
|
|
1
|
-
/* File: packages/ui/src/parts/forms-filter-counts.css
|
|
2
|
-
Map: group (grid of tiles) -> tile (label + hidden radio) -> value / label / hint -> tones -> states -> --compact
|
|
3
|
-
Filter counts: pick a view (e.g. Active / Deleted / All) from tiles that show how many items each has.
|
|
4
|
-
Radio inputs inside labels; the checked tile gets the accent color. No JavaScript. */
|
|
5
|
-
|
|
6
|
-
/* Group: responsive grid of equal tiles (role="radiogroup"). */
|
|
7
|
-
.oc-filter-counts {
|
|
8
|
-
display: grid;
|
|
9
|
-
grid-template-columns: repeat(auto-fit, minmax(10rem, 1fr));
|
|
10
|
-
gap: 0.75rem;
|
|
11
|
-
/* A <fieldset> shrinks to its content by default; fill the row so auto-fit can make columns. */
|
|
12
|
-
inline-size: 100%;
|
|
13
|
-
min-inline-size: 0;
|
|
14
|
-
margin: 0;
|
|
15
|
-
padding: 0;
|
|
16
|
-
border: 0;
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
/* Tile: --oc-filter-accent drives the tone (primary by default). */
|
|
20
|
-
.oc-filter-counts-item {
|
|
21
|
-
--oc-filter-accent: var(--oc-primary);
|
|
22
|
-
position: relative;
|
|
23
|
-
display: grid;
|
|
24
|
-
gap: 0.125rem;
|
|
25
|
-
padding: 0.875rem 1rem;
|
|
26
|
-
border: 1px solid var(--oc-border);
|
|
27
|
-
border-radius: var(--oc-radius);
|
|
28
|
-
background: var(--oc-card);
|
|
29
|
-
color: var(--oc-foreground);
|
|
30
|
-
cursor: pointer;
|
|
31
|
-
transition: border-color var(--oc-transition-fast), background var(--oc-transition-fast);
|
|
32
|
-
}
|
|
33
|
-
|
|
34
|
-
/* Invisible but focusable radio. */
|
|
35
|
-
.oc-filter-counts-item input {
|
|
36
|
-
position: absolute;
|
|
37
|
-
inset: 0;
|
|
38
|
-
margin: 0;
|
|
39
|
-
opacity: 0;
|
|
40
|
-
cursor: pointer;
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
.oc-filter-counts-item:hover { background: var(--oc-surface); }
|
|
44
|
-
|
|
45
|
-
/* Big number. */
|
|
46
|
-
.oc-filter-counts-value {
|
|
47
|
-
font-size: 1.5rem;
|
|
48
|
-
font-weight: 700;
|
|
49
|
-
font-variant-numeric: tabular-nums;
|
|
50
|
-
line-height: 1.1;
|
|
51
|
-
color: var(--oc-filter-accent);
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
.oc-filter-counts-label { font-size: 0.875rem; font-weight: 600; }
|
|
55
|
-
.oc-filter-counts-hint { font-size: 0.75rem; color: var(--oc-muted-foreground); }
|
|
56
|
-
|
|
57
|
-
/* Tones per tile. */
|
|
58
|
-
.oc-filter-counts-item--success { --oc-filter-accent: var(--oc-success); }
|
|
59
|
-
.oc-filter-counts-item--destructive { --oc-filter-accent: var(--oc-destructive); }
|
|
60
|
-
.oc-filter-counts-item--muted { --oc-filter-accent: var(--oc-muted-foreground); }
|
|
61
|
-
|
|
62
|
-
/* Selected: accent border + soft accent background. */
|
|
63
|
-
.oc-filter-counts-item:has(input:checked) {
|
|
64
|
-
border-color: var(--oc-filter-accent);
|
|
65
|
-
background: color-mix(in srgb, var(--oc-filter-accent) 10%, var(--oc-card));
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
.oc-filter-counts-item:has(input:focus-visible) {
|
|
69
|
-
outline: 2px solid var(--oc-ring);
|
|
70
|
-
outline-offset: 2px;
|
|
71
|
-
}
|
|
72
|
-
|
|
73
|
-
.oc-filter-counts-item:has(input:disabled) { opacity: 0.5; cursor: not-allowed; }
|
|
74
|
-
|
|
75
|
-
/* Compact: inline pills "Active 12", for toolbars above a table. */
|
|
76
|
-
.oc-filter-counts--compact {
|
|
77
|
-
display: inline-flex;
|
|
78
|
-
inline-size: auto;
|
|
79
|
-
flex-wrap: wrap;
|
|
80
|
-
gap: 0.25rem;
|
|
81
|
-
}
|
|
82
|
-
|
|
83
|
-
.oc-filter-counts--compact .oc-filter-counts-item {
|
|
84
|
-
display: inline-flex;
|
|
85
|
-
flex-direction: row-reverse;
|
|
86
|
-
align-items: baseline;
|
|
87
|
-
gap: 0.375rem;
|
|
88
|
-
padding: 0.3rem 0.75rem;
|
|
89
|
-
border-radius: 999px;
|
|
90
|
-
}
|
|
91
|
-
|
|
92
|
-
.oc-filter-counts--compact .oc-filter-counts-value { font-size: 0.8rem; }
|
|
93
|
-
.oc-filter-counts--compact .oc-filter-counts-label { font-size: 0.8rem; font-weight: 500; }
|
|
94
|
-
.oc-filter-counts--compact .oc-filter-counts-hint { display: none; }
|
|
1
|
+
/* File: packages/ui/src/parts/forms-filter-counts.css
|
|
2
|
+
Map: group (grid of tiles) -> tile (label + hidden radio) -> value / label / hint -> tones -> states -> --compact
|
|
3
|
+
Filter counts: pick a view (e.g. Active / Deleted / All) from tiles that show how many items each has.
|
|
4
|
+
Radio inputs inside labels; the checked tile gets the accent color. No JavaScript. */
|
|
5
|
+
|
|
6
|
+
/* Group: responsive grid of equal tiles (role="radiogroup"). */
|
|
7
|
+
.oc-filter-counts {
|
|
8
|
+
display: grid;
|
|
9
|
+
grid-template-columns: repeat(auto-fit, minmax(10rem, 1fr));
|
|
10
|
+
gap: 0.75rem;
|
|
11
|
+
/* A <fieldset> shrinks to its content by default; fill the row so auto-fit can make columns. */
|
|
12
|
+
inline-size: 100%;
|
|
13
|
+
min-inline-size: 0;
|
|
14
|
+
margin: 0;
|
|
15
|
+
padding: 0;
|
|
16
|
+
border: 0;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
/* Tile: --oc-filter-accent drives the tone (primary by default). */
|
|
20
|
+
.oc-filter-counts-item {
|
|
21
|
+
--oc-filter-accent: var(--oc-primary);
|
|
22
|
+
position: relative;
|
|
23
|
+
display: grid;
|
|
24
|
+
gap: 0.125rem;
|
|
25
|
+
padding: 0.875rem 1rem;
|
|
26
|
+
border: 1px solid var(--oc-border);
|
|
27
|
+
border-radius: var(--oc-radius);
|
|
28
|
+
background: var(--oc-card);
|
|
29
|
+
color: var(--oc-foreground);
|
|
30
|
+
cursor: pointer;
|
|
31
|
+
transition: border-color var(--oc-transition-fast), background var(--oc-transition-fast);
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
/* Invisible but focusable radio. */
|
|
35
|
+
.oc-filter-counts-item input {
|
|
36
|
+
position: absolute;
|
|
37
|
+
inset: 0;
|
|
38
|
+
margin: 0;
|
|
39
|
+
opacity: 0;
|
|
40
|
+
cursor: pointer;
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
.oc-filter-counts-item:hover { background: var(--oc-surface); }
|
|
44
|
+
|
|
45
|
+
/* Big number. */
|
|
46
|
+
.oc-filter-counts-value {
|
|
47
|
+
font-size: 1.5rem;
|
|
48
|
+
font-weight: 700;
|
|
49
|
+
font-variant-numeric: tabular-nums;
|
|
50
|
+
line-height: 1.1;
|
|
51
|
+
color: var(--oc-filter-accent);
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
.oc-filter-counts-label { font-size: 0.875rem; font-weight: 600; }
|
|
55
|
+
.oc-filter-counts-hint { font-size: 0.75rem; color: var(--oc-muted-foreground); }
|
|
56
|
+
|
|
57
|
+
/* Tones per tile. */
|
|
58
|
+
.oc-filter-counts-item--success { --oc-filter-accent: var(--oc-success); }
|
|
59
|
+
.oc-filter-counts-item--destructive { --oc-filter-accent: var(--oc-destructive); }
|
|
60
|
+
.oc-filter-counts-item--muted { --oc-filter-accent: var(--oc-muted-foreground); }
|
|
61
|
+
|
|
62
|
+
/* Selected: accent border + soft accent background. */
|
|
63
|
+
.oc-filter-counts-item:has(input:checked) {
|
|
64
|
+
border-color: var(--oc-filter-accent);
|
|
65
|
+
background: color-mix(in srgb, var(--oc-filter-accent) 10%, var(--oc-card));
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
.oc-filter-counts-item:has(input:focus-visible) {
|
|
69
|
+
outline: 2px solid var(--oc-ring);
|
|
70
|
+
outline-offset: 2px;
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
.oc-filter-counts-item:has(input:disabled) { opacity: 0.5; cursor: not-allowed; }
|
|
74
|
+
|
|
75
|
+
/* Compact: inline pills "Active 12", for toolbars above a table. */
|
|
76
|
+
.oc-filter-counts--compact {
|
|
77
|
+
display: inline-flex;
|
|
78
|
+
inline-size: auto;
|
|
79
|
+
flex-wrap: wrap;
|
|
80
|
+
gap: 0.25rem;
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
.oc-filter-counts--compact .oc-filter-counts-item {
|
|
84
|
+
display: inline-flex;
|
|
85
|
+
flex-direction: row-reverse;
|
|
86
|
+
align-items: baseline;
|
|
87
|
+
gap: 0.375rem;
|
|
88
|
+
padding: 0.3rem 0.75rem;
|
|
89
|
+
border-radius: 999px;
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
.oc-filter-counts--compact .oc-filter-counts-value { font-size: 0.8rem; }
|
|
93
|
+
.oc-filter-counts--compact .oc-filter-counts-label { font-size: 0.8rem; font-weight: 500; }
|
|
94
|
+
.oc-filter-counts--compact .oc-filter-counts-hint { display: none; }
|