@nexub/tokens 2.5.0 → 2.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/css/rem.css +83 -0
- package/dist/json/component.json +28 -0
- package/package.json +3 -1
package/dist/css/rem.css
ADDED
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
/* @nexub/tokens/css/rem: import after @nexub/tokens/css (and @nexub/themes). */
|
|
2
|
+
:root {
|
|
3
|
+
--spacing-1: 0.25rem;
|
|
4
|
+
--spacing-2: 0.5rem;
|
|
5
|
+
--spacing-3: 0.75rem;
|
|
6
|
+
--spacing-4: 1rem;
|
|
7
|
+
--spacing-5: 1.25rem;
|
|
8
|
+
--spacing-6: 1.5rem;
|
|
9
|
+
--spacing-7: 1.75rem;
|
|
10
|
+
--spacing-8: 2rem;
|
|
11
|
+
--spacing-9: 2.25rem;
|
|
12
|
+
--spacing-10: 2.5rem;
|
|
13
|
+
--spacing-11: 2.75rem;
|
|
14
|
+
--spacing-12: 3rem;
|
|
15
|
+
--spacing-14: 3.5rem;
|
|
16
|
+
--spacing-16: 4rem;
|
|
17
|
+
--spacing-20: 5rem;
|
|
18
|
+
--spacing-24: 6rem;
|
|
19
|
+
--spacing-28: 7rem;
|
|
20
|
+
--spacing-32: 8rem;
|
|
21
|
+
--spacing-40: 10rem;
|
|
22
|
+
--spacing-48: 12rem;
|
|
23
|
+
--spacing-56: 14rem;
|
|
24
|
+
--spacing-64: 16rem;
|
|
25
|
+
--spacing-0-5: 0.125rem;
|
|
26
|
+
--spacing-1-5: 0.375rem;
|
|
27
|
+
--spacing-2-5: 0.625rem;
|
|
28
|
+
--spacing-3-5: 0.875rem;
|
|
29
|
+
--radius-xs: 0.125rem;
|
|
30
|
+
--radius-sm: 0.25rem;
|
|
31
|
+
--radius-md: 0.5rem;
|
|
32
|
+
--radius-lg: 0.75rem;
|
|
33
|
+
--radius-xl: 1rem;
|
|
34
|
+
--radius-2xl: 1.5rem;
|
|
35
|
+
--radius-3xl: 2rem;
|
|
36
|
+
--shape-field: 0.75rem;
|
|
37
|
+
--shape-container: 1rem;
|
|
38
|
+
--shape-overlay: 1.5rem;
|
|
39
|
+
--shape-tooltip: 0.5rem;
|
|
40
|
+
--shape-min: 0.25rem;
|
|
41
|
+
--size-control-xs: 1.5rem;
|
|
42
|
+
--size-control-sm: 2rem;
|
|
43
|
+
--size-control-md: 2.5rem;
|
|
44
|
+
--size-control-lg: 3rem;
|
|
45
|
+
--size-control-xl: 3.5rem;
|
|
46
|
+
--type-display-lg-size: 3.5rem;
|
|
47
|
+
--type-display-lg-lineHeight: 3.75rem;
|
|
48
|
+
--type-display-md-size: 2.75rem;
|
|
49
|
+
--type-display-md-lineHeight: 3rem;
|
|
50
|
+
--type-display-sm-size: 2.25rem;
|
|
51
|
+
--type-display-sm-lineHeight: 2.5rem;
|
|
52
|
+
--type-headline-lg-size: 2rem;
|
|
53
|
+
--type-headline-lg-lineHeight: 2.375rem;
|
|
54
|
+
--type-headline-md-size: 1.75rem;
|
|
55
|
+
--type-headline-md-lineHeight: 2.125rem;
|
|
56
|
+
--type-headline-sm-size: 1.5rem;
|
|
57
|
+
--type-headline-sm-lineHeight: 1.875rem;
|
|
58
|
+
--type-title-lg-size: 1.25rem;
|
|
59
|
+
--type-title-lg-lineHeight: 1.75rem;
|
|
60
|
+
--type-title-md-size: 1rem;
|
|
61
|
+
--type-title-md-lineHeight: 1.5rem;
|
|
62
|
+
--type-title-sm-size: 0.875rem;
|
|
63
|
+
--type-title-sm-lineHeight: 1.25rem;
|
|
64
|
+
--type-body-lg-size: 1.125rem;
|
|
65
|
+
--type-body-lg-lineHeight: 1.75rem;
|
|
66
|
+
--type-body-md-size: 1rem;
|
|
67
|
+
--type-body-md-lineHeight: 1.5rem;
|
|
68
|
+
--type-body-sm-size: 0.875rem;
|
|
69
|
+
--type-body-sm-lineHeight: 1.25rem;
|
|
70
|
+
--type-label-lg-size: 0.875rem;
|
|
71
|
+
--type-label-lg-lineHeight: 1.25rem;
|
|
72
|
+
--type-label-md-size: 0.8125rem;
|
|
73
|
+
--type-label-md-lineHeight: 1.125rem;
|
|
74
|
+
--type-label-sm-size: 0.75rem;
|
|
75
|
+
--type-label-sm-lineHeight: 1rem;
|
|
76
|
+
}
|
|
77
|
+
[data-density='compact'] {
|
|
78
|
+
--size-control-xs: 1.25rem;
|
|
79
|
+
--size-control-sm: 1.5rem;
|
|
80
|
+
--size-control-md: 2rem;
|
|
81
|
+
--size-control-lg: 2.5rem;
|
|
82
|
+
--size-control-xl: 3rem;
|
|
83
|
+
}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$description": "Component tier. Unset by default: each component reads var(--<name>, <css>), so the default resolves where the component sits and nested data-contrast / data-product / data-theme keep working. Set one on any element to restyle that component below it. Kept out of variables.css on purpose (a :root declaration would freeze the role at :root).",
|
|
3
|
+
"button": {
|
|
4
|
+
"filled-bg": { "$type": "color", "$value": "{color.primary}", "$extensions": { "dev.nexub": { "css": "var(--color-primary)" } } },
|
|
5
|
+
"filled-fg": { "$type": "color", "$value": "{color.on-primary}", "$extensions": { "dev.nexub": { "css": "var(--color-on-primary)" } } },
|
|
6
|
+
"tonal-bg": { "$type": "color", "$value": "{color.secondary-container}", "$extensions": { "dev.nexub": { "css": "var(--color-secondary-container)" } } },
|
|
7
|
+
"tonal-fg": { "$type": "color", "$value": "{color.on-secondary-container}", "$extensions": { "dev.nexub": { "css": "var(--color-on-secondary-container)" } } },
|
|
8
|
+
"outlined-border": { "$type": "color", "$value": "{color.outline-variant}", "$extensions": { "dev.nexub": { "css": "var(--color-outline-variant)" } } },
|
|
9
|
+
"outlined-fg": { "$type": "color", "$value": "{color.on-surface}", "$extensions": { "dev.nexub": { "css": "var(--color-on-surface)" } } },
|
|
10
|
+
"text-fg": { "$type": "color", "$value": "{color.on-surface}", "$extensions": { "dev.nexub": { "css": "var(--color-on-surface)" } } }
|
|
11
|
+
},
|
|
12
|
+
"field": {
|
|
13
|
+
"$description": "Input, Textarea, Select and Combobox triggers.",
|
|
14
|
+
"bg": { "$type": "color", "$value": "{color.surface-container-lowest}", "$extensions": { "dev.nexub": { "css": "var(--color-surface-container-lowest)" } } },
|
|
15
|
+
"fg": { "$type": "color", "$value": "{color.on-surface}", "$extensions": { "dev.nexub": { "css": "var(--color-on-surface)" } } },
|
|
16
|
+
"border": { "$type": "color", "$value": "{color.outline}", "$extensions": { "dev.nexub": { "css": "var(--color-outline)" } } },
|
|
17
|
+
"radius": { "$type": "dimension", "$value": "{shape.field}", "$extensions": { "dev.nexub": { "css": "var(--shape-field)" } } }
|
|
18
|
+
},
|
|
19
|
+
"card": {
|
|
20
|
+
"bg": { "$type": "color", "$value": "{color.surface-elevated}", "$extensions": { "dev.nexub": { "css": "var(--color-surface-elevated)" } } },
|
|
21
|
+
"fg": { "$type": "color", "$value": "{color.on-surface}", "$extensions": { "dev.nexub": { "css": "var(--color-on-surface)" } } },
|
|
22
|
+
"border": { "$type": "color", "$value": "{color.outline-variant}", "$description": "At 60% opacity.", "$extensions": { "dev.nexub": { "css": "color-mix(in srgb,var(--color-outline-variant) 60%,transparent)" } } },
|
|
23
|
+
"radius": { "$type": "dimension", "$value": "{shape.container}", "$extensions": { "dev.nexub": { "css": "var(--shape-container)" } } }
|
|
24
|
+
},
|
|
25
|
+
"badge": {
|
|
26
|
+
"radius": { "$type": "dimension", "$value": "{shape.control}", "$extensions": { "dev.nexub": { "css": "var(--shape-control)" } } }
|
|
27
|
+
}
|
|
28
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nexub/tokens",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.7.0",
|
|
4
4
|
"description": "Design tokens for Nexub Design System — colours, typography, spacing, radii, shadows, and motion as CSS variables, Tailwind presets and React Native objects.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -38,6 +38,7 @@
|
|
|
38
38
|
},
|
|
39
39
|
"./css": "./dist/css/variables.css",
|
|
40
40
|
"./css/roles": "./dist/css/roles.css",
|
|
41
|
+
"./css/rem": "./dist/css/rem.css",
|
|
41
42
|
"./seed": {
|
|
42
43
|
"types": "./dist/js/seed.d.ts",
|
|
43
44
|
"default": "./dist/js/seed.js"
|
|
@@ -52,6 +53,7 @@
|
|
|
52
53
|
},
|
|
53
54
|
"./tailwind.css": "./dist/tailwind/theme.css",
|
|
54
55
|
"./json": "./dist/json/tokens.json",
|
|
56
|
+
"./json/component": "./dist/json/component.json",
|
|
55
57
|
"./package.json": "./package.json"
|
|
56
58
|
},
|
|
57
59
|
"devDependencies": {
|