@neovici/cosmoz-tokens 4.6.0 → 4.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +6 -5
- package/package.json +1 -1
- package/src/fallback.css +9 -3
- package/src/shadows.css +19 -10
- package/src/spacing.css +7 -1
package/README.md
CHANGED
|
@@ -21,7 +21,7 @@ This imports all token files:
|
|
|
21
21
|
|
|
22
22
|
- Primitives (colors)
|
|
23
23
|
- Typography (fonts, sizes)
|
|
24
|
-
- Spacing (border radius)
|
|
24
|
+
- Spacing (border radius, control heights)
|
|
25
25
|
- Shadows
|
|
26
26
|
- Semantic tokens (with dark mode support)
|
|
27
27
|
|
|
@@ -133,10 +133,11 @@ document.documentElement.dataset.theme = 'dark';
|
|
|
133
133
|
|
|
134
134
|
### Spacing
|
|
135
135
|
|
|
136
|
-
| Token
|
|
137
|
-
|
|
|
138
|
-
| `--cz-spacing`
|
|
139
|
-
| `--cz-radius-{none-full}`
|
|
136
|
+
| Token | Description |
|
|
137
|
+
| ----------------------------- | ------------------------------- |
|
|
138
|
+
| `--cz-spacing` | Base spacing unit (4px) |
|
|
139
|
+
| `--cz-radius-{none-full}` | Border radius scale |
|
|
140
|
+
| `--cz-control-height-{sm-xl}` | Control heights (28/32/36/40px) |
|
|
140
141
|
|
|
141
142
|
### Shadows
|
|
142
143
|
|
package/package.json
CHANGED
package/src/fallback.css
CHANGED
|
@@ -100,9 +100,15 @@
|
|
|
100
100
|
--cz-color-fg-processing-secondary: var(--cz-color-indigo-500);
|
|
101
101
|
--cz-color-fg-info: var(--cz-color-info-600);
|
|
102
102
|
--cz-color-fg-info-secondary: var(--cz-color-info-500);
|
|
103
|
-
--cz-focus-ring:
|
|
104
|
-
|
|
105
|
-
|
|
103
|
+
--cz-focus-ring:
|
|
104
|
+
inset 0 0 0 1px var(--cz-color-brand-500),
|
|
105
|
+
inset 0 0 0 2px var(--cz-color-bg-primary);
|
|
106
|
+
--cz-focus-ring-error:
|
|
107
|
+
inset 0 0 0 1px var(--cz-color-error-500),
|
|
108
|
+
inset 0 0 0 2px var(--cz-color-bg-primary);
|
|
109
|
+
--cz-focus-ring-info:
|
|
110
|
+
inset 0 0 0 1px var(--cz-color-info-500),
|
|
111
|
+
inset 0 0 0 2px var(--cz-color-bg-primary);
|
|
106
112
|
--cz-shadow-skeumorphic:
|
|
107
113
|
0px 0px 0px 1px rgba(10, 13, 18, 0.18) inset,
|
|
108
114
|
0px -2px 0px 0px rgba(10, 13, 18, 0.05) inset;
|
package/src/shadows.css
CHANGED
|
@@ -63,20 +63,29 @@
|
|
|
63
63
|
*/
|
|
64
64
|
--skeumorphic-color: light-dark(rgba(255, 255, 255, 0.12), transparent);
|
|
65
65
|
|
|
66
|
-
/*
|
|
66
|
+
/*
|
|
67
|
+
* Focus ring shadows. Inset so overflow can't clip them (#29); the inner
|
|
68
|
+
* surface band keeps the ring visible on solid fills of the same hue.
|
|
69
|
+
*/
|
|
67
70
|
--cz-color-focus-ring: light-dark(
|
|
68
|
-
var(--cz-color-brand-
|
|
69
|
-
var(--cz-color-brand-
|
|
71
|
+
var(--cz-color-brand-500),
|
|
72
|
+
var(--cz-color-brand-400)
|
|
70
73
|
);
|
|
71
74
|
--cz-color-focus-ring-error: light-dark(
|
|
72
|
-
var(--cz-color-error-
|
|
73
|
-
var(--cz-color-error-
|
|
75
|
+
var(--cz-color-error-500),
|
|
76
|
+
var(--cz-color-error-400)
|
|
74
77
|
);
|
|
75
78
|
--cz-color-focus-ring-info: light-dark(
|
|
76
|
-
var(--cz-color-info-
|
|
77
|
-
var(--cz-color-info-
|
|
79
|
+
var(--cz-color-info-500),
|
|
80
|
+
var(--cz-color-info-400)
|
|
78
81
|
);
|
|
79
|
-
--cz-focus-ring:
|
|
80
|
-
|
|
81
|
-
|
|
82
|
+
--cz-focus-ring:
|
|
83
|
+
inset 0 0 0 1px var(--cz-color-focus-ring),
|
|
84
|
+
inset 0 0 0 2px var(--cz-color-bg-primary);
|
|
85
|
+
--cz-focus-ring-error:
|
|
86
|
+
inset 0 0 0 1px var(--cz-color-focus-ring-error),
|
|
87
|
+
inset 0 0 0 2px var(--cz-color-bg-primary);
|
|
88
|
+
--cz-focus-ring-info:
|
|
89
|
+
inset 0 0 0 1px var(--cz-color-focus-ring-info),
|
|
90
|
+
inset 0 0 0 2px var(--cz-color-bg-primary);
|
|
82
91
|
}
|
package/src/spacing.css
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Cosmoz Design Tokens - Spacing
|
|
3
|
-
*
|
|
3
|
+
* Spacing, border radius and control height scales
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
6
|
:root {
|
|
@@ -19,4 +19,10 @@
|
|
|
19
19
|
--cz-radius-3xl: 1.25rem;
|
|
20
20
|
--cz-radius-4xl: 1.5rem;
|
|
21
21
|
--cz-radius-full: 9999px;
|
|
22
|
+
|
|
23
|
+
/* Control heights, shared by buttons, inputs and other form controls */
|
|
24
|
+
--cz-control-height-sm: 1.75rem;
|
|
25
|
+
--cz-control-height-md: 2rem;
|
|
26
|
+
--cz-control-height-lg: 2.25rem;
|
|
27
|
+
--cz-control-height-xl: 2.5rem;
|
|
22
28
|
}
|