@wintermuted/ui-theme 1.0.2 → 1.0.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +23 -0
- package/package.json +5 -2
- package/styles/components/action-disclosure.css +66 -0
- package/styles/components/filter-panel.css +78 -0
- package/styles/components/gallery.css +19 -0
- package/styles/components/load-status.css +31 -0
- package/styles/components/nav.css +26 -0
- package/styles/components/view-header.css +43 -0
- package/styles/components.css +3 -0
- package/styles/tokens.css +2 -0
package/README.md
CHANGED
|
@@ -40,6 +40,29 @@ They are also included in the aggregate theme and use the existing tokens.
|
|
|
40
40
|
NumberStepper needs button and tooltip CSS when loading sheets individually.
|
|
41
41
|
Color-picker and selector styles never depend on application toolbar or game selectors.
|
|
42
42
|
|
|
43
|
+
PageHeader reuses `view-header.css` with additive `.wm-page-header` slots.
|
|
44
|
+
Breadcrumbs reuses `nav.css` and `.wm-breadcrumbs`; PreviewImage uses
|
|
45
|
+
`.wm-preview-image`/`.wm-preview-image-fallback` in `gallery.css`.
|
|
46
|
+
The new exported `filter-panel.css` adds the responsive non-modal disclosure:
|
|
47
|
+
controls are inline above 48rem and CSS-hidden/expandable below, without unmounting.
|
|
48
|
+
Long mobile panels scroll with the document; the panel does not clip child popups
|
|
49
|
+
with an internal overflow container. Preview image/fallback sizing uses local
|
|
50
|
+
border-box sizing even when gallery CSS is imported without the base reset.
|
|
51
|
+
Load `view-header.css`, `button.css` and `filter-panel.css` when importing its
|
|
52
|
+
styles individually. All sheets are included by the aggregate theme.
|
|
53
|
+
Loading/error compositions reuse `alert.css`, optionally `spinner.css` and
|
|
54
|
+
`empty-state.css`; no second feedback API or Inventory composition styles were added.
|
|
55
|
+
|
|
56
|
+
`load-status.css` and `action-disclosure.css` provide scoped `.wm-load-status` and
|
|
57
|
+
`.wm-action-disclosure-*` styles for neutral loading/retry feedback and independent
|
|
58
|
+
header actions. They are exported under `styles/components/` and registered in the
|
|
59
|
+
aggregate theme. Load tokens and button CSS when importing these sheets individually;
|
|
60
|
+
base CSS is optional for document defaults. `load-status.css` imports `spinner.css`,
|
|
61
|
+
which owns `.wm-sr-only`, so help-mode announcements stay visually hidden with modular imports.
|
|
62
|
+
RefreshAction uses button CSS alone.
|
|
63
|
+
The additive `--wm-color-warning-text` token supplies readable warning text in light/dark
|
|
64
|
+
themes without changing the existing warning color or Button/Accordion defaults.
|
|
65
|
+
|
|
43
66
|
This package lives in `packages/ui-theme` within the [Wintermuted UI monorepo](https://github.com/wintermuted/wintermuted-ui). New monorepo tags are not directly installable as the theme through a GitHub-source npm dependency; use npm releases or a tarball produced by `npm pack --workspace=@wintermuted/ui-theme`.
|
|
44
67
|
|
|
45
68
|
## Migrating to 1.0
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wintermuted/ui-theme",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.4",
|
|
4
4
|
"description": "Shared Wintermuted UI theme (design tokens, base resets, and component styles) derived from the CV styling language.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"volta": {
|
|
@@ -78,7 +78,10 @@
|
|
|
78
78
|
"./styles/components/color-picker.css": "./styles/components/color-picker.css",
|
|
79
79
|
"./styles/components/ranked-bar-list.css": "./styles/components/ranked-bar-list.css",
|
|
80
80
|
"./styles/components/number-stepper.css": "./styles/components/number-stepper.css",
|
|
81
|
-
"./styles/components/language-selector.css": "./styles/components/language-selector.css"
|
|
81
|
+
"./styles/components/language-selector.css": "./styles/components/language-selector.css",
|
|
82
|
+
"./styles/components/filter-panel.css": "./styles/components/filter-panel.css",
|
|
83
|
+
"./styles/components/load-status.css": "./styles/components/load-status.css",
|
|
84
|
+
"./styles/components/action-disclosure.css": "./styles/components/action-disclosure.css"
|
|
82
85
|
},
|
|
83
86
|
"scripts": {
|
|
84
87
|
"lint": "stylelint \"styles/**/*.css\" \"index.css\""
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
.wm-action-disclosure-header {
|
|
2
|
+
display: flex;
|
|
3
|
+
align-items: center;
|
|
4
|
+
gap: var(--wm-space-2);
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
.wm-action-disclosure-heading {
|
|
8
|
+
flex: 1;
|
|
9
|
+
min-inline-size: 0;
|
|
10
|
+
margin: 0;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
.wm-action-disclosure .wm-action-disclosure-trigger {
|
|
14
|
+
justify-content: flex-start;
|
|
15
|
+
inline-size: 100%;
|
|
16
|
+
min-block-size: var(--wm-control-height);
|
|
17
|
+
padding: var(--wm-space-1);
|
|
18
|
+
border: 0;
|
|
19
|
+
background: transparent;
|
|
20
|
+
color: var(--wm-color-text-secondary);
|
|
21
|
+
font: inherit;
|
|
22
|
+
font-size: var(--wm-text-sm);
|
|
23
|
+
letter-spacing: normal;
|
|
24
|
+
text-transform: none;
|
|
25
|
+
text-align: start;
|
|
26
|
+
white-space: normal;
|
|
27
|
+
overflow-wrap: anywhere;
|
|
28
|
+
transform: none;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
.wm-action-disclosure-indicator {
|
|
32
|
+
display: inline-flex;
|
|
33
|
+
flex: 0 0 auto;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
.wm-action-disclosure-trigger[aria-expanded="true"] > .wm-action-disclosure-indicator {
|
|
37
|
+
transform: rotate(90deg);
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
.wm-action-disclosure .wm-action-disclosure-action {
|
|
41
|
+
flex: 0 0 auto;
|
|
42
|
+
min-inline-size: var(--wm-control-height);
|
|
43
|
+
min-block-size: var(--wm-control-height);
|
|
44
|
+
max-inline-size: 50%;
|
|
45
|
+
padding: var(--wm-space-2);
|
|
46
|
+
border: 0;
|
|
47
|
+
background: transparent;
|
|
48
|
+
color: var(--wm-color-text-secondary);
|
|
49
|
+
letter-spacing: normal;
|
|
50
|
+
text-transform: none;
|
|
51
|
+
white-space: normal;
|
|
52
|
+
overflow-wrap: anywhere;
|
|
53
|
+
transform: none;
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
.wm-action-disclosure .wm-action-disclosure-trigger:hover,
|
|
57
|
+
.wm-action-disclosure .wm-action-disclosure-action:hover {
|
|
58
|
+
background: var(--wm-color-surface-muted);
|
|
59
|
+
color: var(--wm-color-text);
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
.wm-action-disclosure .wm-action-disclosure-trigger:focus-visible,
|
|
63
|
+
.wm-action-disclosure .wm-action-disclosure-action:focus-visible {
|
|
64
|
+
outline: 2px solid var(--wm-color-accent);
|
|
65
|
+
outline-offset: -2px;
|
|
66
|
+
}
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
.wm-filter-panel {
|
|
2
|
+
position: relative;
|
|
3
|
+
}
|
|
4
|
+
|
|
5
|
+
.wm-filter-panel-search {
|
|
6
|
+
flex: 1 1 14rem;
|
|
7
|
+
min-width: 0;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
.wm-filter-panel-controls {
|
|
11
|
+
display: flex;
|
|
12
|
+
flex-wrap: wrap;
|
|
13
|
+
align-items: flex-end;
|
|
14
|
+
gap: var(--wm-space-3);
|
|
15
|
+
min-width: 0;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
.wm-filter-panel-summary {
|
|
19
|
+
flex-basis: 100%;
|
|
20
|
+
color: var(--wm-color-text-secondary);
|
|
21
|
+
font-size: var(--wm-text-sm);
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
.wm-filter-panel .wm-filter-panel-toggle,
|
|
25
|
+
.wm-filter-panel-scrim,
|
|
26
|
+
.wm-filter-panel-header {
|
|
27
|
+
display: none;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
@media (width <= 48rem) {
|
|
31
|
+
.wm-filter-panel-search {
|
|
32
|
+
flex-basis: 0;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
.wm-filter-panel .wm-filter-panel-toggle {
|
|
36
|
+
display: inline-flex;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
.wm-filter-panel-controls {
|
|
40
|
+
display: none;
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
.wm-filter-panel-controls-open {
|
|
44
|
+
display: flex;
|
|
45
|
+
position: absolute;
|
|
46
|
+
inset: 100% 0 auto;
|
|
47
|
+
z-index: var(--wm-layer-popup);
|
|
48
|
+
align-items: stretch;
|
|
49
|
+
flex-direction: column;
|
|
50
|
+
padding: var(--wm-space-4);
|
|
51
|
+
border: 1px solid var(--wm-color-border);
|
|
52
|
+
border-radius: var(--wm-radius-base);
|
|
53
|
+
background: var(--wm-color-surface-solid);
|
|
54
|
+
box-shadow: var(--wm-shadow-soft);
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
.wm-filter-panel-header {
|
|
58
|
+
display: flex;
|
|
59
|
+
align-items: center;
|
|
60
|
+
justify-content: space-between;
|
|
61
|
+
gap: var(--wm-space-3);
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
.wm-filter-panel-scrim {
|
|
65
|
+
display: block;
|
|
66
|
+
position: fixed;
|
|
67
|
+
inset: 0;
|
|
68
|
+
z-index: calc(var(--wm-layer-popup) - 1);
|
|
69
|
+
padding: 0;
|
|
70
|
+
border: 0;
|
|
71
|
+
background: var(--wm-dialog-backdrop);
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
.wm-filter-panel-scrim:focus-visible {
|
|
75
|
+
outline: 2px solid var(--wm-color-accent);
|
|
76
|
+
outline-offset: -2px;
|
|
77
|
+
}
|
|
78
|
+
}
|
|
@@ -1,5 +1,24 @@
|
|
|
1
1
|
/* Image gallery grid with hover-lift thumbnails. */
|
|
2
2
|
|
|
3
|
+
.wm-preview-image {
|
|
4
|
+
box-sizing: border-box;
|
|
5
|
+
display: block;
|
|
6
|
+
width: 100%;
|
|
7
|
+
height: auto;
|
|
8
|
+
aspect-ratio: 16 / 10;
|
|
9
|
+
object-fit: cover;
|
|
10
|
+
border-radius: var(--wm-radius-base);
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
.wm-preview-image-fallback {
|
|
14
|
+
display: grid;
|
|
15
|
+
place-items: center;
|
|
16
|
+
padding: var(--wm-space-4);
|
|
17
|
+
background: var(--wm-color-surface-muted);
|
|
18
|
+
color: var(--wm-color-text-secondary);
|
|
19
|
+
text-align: center;
|
|
20
|
+
}
|
|
21
|
+
|
|
3
22
|
/**
|
|
4
23
|
* .gallery / .wm-gallery
|
|
5
24
|
* Responsive auto-fill image grid. Minimum cell width: 200 px.
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
@import url("./spinner.css");
|
|
2
|
+
|
|
3
|
+
.wm-load-status {
|
|
4
|
+
display: inline-flex;
|
|
5
|
+
align-items: center;
|
|
6
|
+
flex-wrap: wrap;
|
|
7
|
+
gap: var(--wm-space-1);
|
|
8
|
+
max-inline-size: 100%;
|
|
9
|
+
color: var(--wm-color-danger);
|
|
10
|
+
overflow-wrap: anywhere;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
.wm-load-status-warning {
|
|
14
|
+
color: var(--wm-color-warning-text);
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
.wm-load-status .wm-load-status-retry {
|
|
18
|
+
min-inline-size: var(--wm-control-height);
|
|
19
|
+
min-block-size: var(--wm-control-height);
|
|
20
|
+
padding: var(--wm-space-1);
|
|
21
|
+
color: inherit;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
.wm-load-status-loading {
|
|
25
|
+
color: var(--wm-color-text-muted);
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
.wm-load-status-retry:focus-visible {
|
|
29
|
+
outline: 2px solid var(--wm-color-accent);
|
|
30
|
+
outline-offset: -2px;
|
|
31
|
+
}
|
|
@@ -16,3 +16,29 @@
|
|
|
16
16
|
outline: 2px solid var(--wm-color-accent);
|
|
17
17
|
outline-offset: 2px;
|
|
18
18
|
}
|
|
19
|
+
|
|
20
|
+
.wm-breadcrumbs ol {
|
|
21
|
+
display: flex;
|
|
22
|
+
flex-wrap: wrap;
|
|
23
|
+
gap: var(--wm-space-2);
|
|
24
|
+
padding: 0;
|
|
25
|
+
margin: 0;
|
|
26
|
+
list-style: none;
|
|
27
|
+
font-size: var(--wm-text-sm);
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
.wm-breadcrumbs li {
|
|
31
|
+
display: flex;
|
|
32
|
+
gap: var(--wm-space-2);
|
|
33
|
+
min-width: 0;
|
|
34
|
+
overflow-wrap: anywhere;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
.wm-breadcrumbs li + li::before {
|
|
38
|
+
content: "/";
|
|
39
|
+
color: var(--wm-color-text-muted);
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
.wm-breadcrumbs [aria-current="page"] {
|
|
43
|
+
color: var(--wm-color-text-secondary);
|
|
44
|
+
}
|
|
@@ -58,3 +58,46 @@
|
|
|
58
58
|
color: var(--wm-color-text);
|
|
59
59
|
font-size: 0.875rem;
|
|
60
60
|
}
|
|
61
|
+
|
|
62
|
+
.wm-page-header {
|
|
63
|
+
display: flex;
|
|
64
|
+
flex-wrap: wrap;
|
|
65
|
+
align-items: center;
|
|
66
|
+
justify-content: space-between;
|
|
67
|
+
gap: var(--wm-space-4);
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
.wm-page-header > div:first-child {
|
|
71
|
+
min-width: 0;
|
|
72
|
+
flex: 1 1 18rem;
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
.wm-page-header h1 {
|
|
76
|
+
margin: 0 0 var(--wm-space-2);
|
|
77
|
+
font-size: 1.75rem;
|
|
78
|
+
font-weight: 600;
|
|
79
|
+
letter-spacing: -0.01em;
|
|
80
|
+
overflow-wrap: anywhere;
|
|
81
|
+
color: var(--wm-color-text);
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
.wm-page-header-title {
|
|
85
|
+
display: flex;
|
|
86
|
+
align-items: center;
|
|
87
|
+
gap: var(--wm-space-3);
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
.wm-page-header-title > svg {
|
|
91
|
+
flex-shrink: 0;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
.wm-page-header .wm-page-header-eyebrow {
|
|
95
|
+
margin-bottom: var(--wm-space-2);
|
|
96
|
+
font-size: var(--wm-text-sm);
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
.wm-page-header-action {
|
|
100
|
+
display: flex;
|
|
101
|
+
flex-wrap: wrap;
|
|
102
|
+
gap: var(--wm-space-2);
|
|
103
|
+
}
|
package/styles/components.css
CHANGED
|
@@ -39,3 +39,6 @@
|
|
|
39
39
|
@import url("./components/ranked-bar-list.css");
|
|
40
40
|
@import url("./components/number-stepper.css");
|
|
41
41
|
@import url("./components/language-selector.css");
|
|
42
|
+
@import url("./components/filter-panel.css");
|
|
43
|
+
@import url("./components/load-status.css");
|
|
44
|
+
@import url("./components/action-disclosure.css");
|
package/styles/tokens.css
CHANGED
|
@@ -34,6 +34,7 @@
|
|
|
34
34
|
--wm-color-success-soft: #e6f4ea;
|
|
35
35
|
--wm-color-success-border: #cfe6d4;
|
|
36
36
|
--wm-color-warning: #ea8600;
|
|
37
|
+
--wm-color-warning-text: #946000;
|
|
37
38
|
--wm-color-warning-soft: #fff7e0;
|
|
38
39
|
--wm-color-warning-border: #f6d28b;
|
|
39
40
|
--wm-color-danger: #c5221f;
|
|
@@ -71,6 +72,7 @@
|
|
|
71
72
|
--wm-color-success-soft: #132719;
|
|
72
73
|
--wm-color-success-border: #21452c;
|
|
73
74
|
--wm-color-warning: #ffb95a;
|
|
75
|
+
--wm-color-warning-text: #ffb95a;
|
|
74
76
|
--wm-color-warning-soft: #35250f;
|
|
75
77
|
--wm-color-warning-border: #5e441d;
|
|
76
78
|
--wm-color-danger: #ff978f;
|