@nswds/tokens 3.7.0 → 3.8.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/README.md +22 -1
- package/dist/css/motion/global.css +8 -0
- package/dist/css/z-index/global.css +10 -0
- package/dist/index.cjs +199 -57
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +147 -0
- package/dist/index.d.ts +147 -0
- package/dist/index.js +199 -57
- package/dist/index.js.map +1 -1
- package/dist/js/motion/global.d.ts +10 -0
- package/dist/js/motion/global.js +10 -0
- package/dist/js/z-index/global.d.ts +10 -0
- package/dist/js/z-index/global.js +10 -0
- package/dist/json/motion/global.json +12 -0
- package/dist/json/z-index/global.json +12 -0
- package/dist/less/motion/global.less +6 -0
- package/dist/less/z-index/global.less +8 -0
- package/dist/scss/motion/global.scss +6 -0
- package/dist/scss/z-index/global.scss +8 -0
- package/dist/tailwind/motion/global.css +8 -0
- package/dist/tailwind/preset.css +24 -0
- package/dist/tailwind/z-index/global.css +10 -0
- package/dist/tokens/global/motion/canonical.json +45 -0
- package/dist/tokens/global/z-index/canonical.json +44 -0
- package/dist/ts/motion/global.ts +10 -0
- package/dist/ts/z-index/global.ts +10 -0
- package/package.json +1 -1
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
{
|
|
2
|
+
"duration": {
|
|
3
|
+
"duration-fast": "150ms",
|
|
4
|
+
"duration-base": "250ms",
|
|
5
|
+
"duration-slow": "400ms"
|
|
6
|
+
},
|
|
7
|
+
"easing": {
|
|
8
|
+
"easing-standard": "cubic-bezier(0.4, 0, 0.2, 1)",
|
|
9
|
+
"easing-decelerate": "cubic-bezier(0, 0, 0.2, 1)",
|
|
10
|
+
"easing-accelerate": "cubic-bezier(0.4, 0, 1, 1)"
|
|
11
|
+
}
|
|
12
|
+
}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
@duration-fast: 150ms; // Fast — quick feedback on small elements (hovers, toggles, focus rings). DRAFT pending design review.
|
|
2
|
+
@duration-base: 250ms; // Base — the default duration for most UI transitions. DRAFT pending design review.
|
|
3
|
+
@duration-slow: 400ms; // Slow — larger surfaces entering or leaving (modals, drawers, sheets). DRAFT pending design review.
|
|
4
|
+
@easing-standard: cubic-bezier(0.4, 0, 0.2, 1); // Standard ease-in-out — the default curve for elements moving within the viewport. DRAFT pending design review.
|
|
5
|
+
@easing-decelerate: cubic-bezier(0, 0, 0.2, 1); // Decelerate (ease-out) — elements entering the screen, fast then settling. DRAFT pending design review.
|
|
6
|
+
@easing-accelerate: cubic-bezier(0.4, 0, 1, 1); // Accelerate (ease-in) — elements leaving the screen, building speed as they exit. DRAFT pending design review.
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
@z-index-base: 0; // Base stacking level (0) — default in-flow content. DRAFT pending design review.
|
|
2
|
+
@z-index-dropdown: 1000; // Dropdown menus and select popups. DRAFT pending design review.
|
|
3
|
+
@z-index-sticky: 1100; // Sticky elements that pin on scroll (headers, toolbars). DRAFT pending design review.
|
|
4
|
+
@z-index-overlay: 1200; // Full-screen overlay scrims sitting behind modal content. DRAFT pending design review.
|
|
5
|
+
@z-index-modal: 1300; // Modal dialogs and side sheets. DRAFT pending design review.
|
|
6
|
+
@z-index-popover: 1400; // Popovers anchored to a trigger, above modals. DRAFT pending design review.
|
|
7
|
+
@z-index-toast: 1500; // Toast and snackbar notifications. DRAFT pending design review.
|
|
8
|
+
@z-index-tooltip: 1600; // Tooltips — the top-most interactive layer. DRAFT pending design review.
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
$duration-fast: 150ms; // Fast — quick feedback on small elements (hovers, toggles, focus rings). DRAFT pending design review.
|
|
2
|
+
$duration-base: 250ms; // Base — the default duration for most UI transitions. DRAFT pending design review.
|
|
3
|
+
$duration-slow: 400ms; // Slow — larger surfaces entering or leaving (modals, drawers, sheets). DRAFT pending design review.
|
|
4
|
+
$easing-standard: cubic-bezier(0.4, 0, 0.2, 1); // Standard ease-in-out — the default curve for elements moving within the viewport. DRAFT pending design review.
|
|
5
|
+
$easing-decelerate: cubic-bezier(0, 0, 0.2, 1); // Decelerate (ease-out) — elements entering the screen, fast then settling. DRAFT pending design review.
|
|
6
|
+
$easing-accelerate: cubic-bezier(0.4, 0, 1, 1); // Accelerate (ease-in) — elements leaving the screen, building speed as they exit. DRAFT pending design review.
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
$z-index-base: 0; // Base stacking level (0) — default in-flow content. DRAFT pending design review.
|
|
2
|
+
$z-index-dropdown: 1000; // Dropdown menus and select popups. DRAFT pending design review.
|
|
3
|
+
$z-index-sticky: 1100; // Sticky elements that pin on scroll (headers, toolbars). DRAFT pending design review.
|
|
4
|
+
$z-index-overlay: 1200; // Full-screen overlay scrims sitting behind modal content. DRAFT pending design review.
|
|
5
|
+
$z-index-modal: 1300; // Modal dialogs and side sheets. DRAFT pending design review.
|
|
6
|
+
$z-index-popover: 1400; // Popovers anchored to a trigger, above modals. DRAFT pending design review.
|
|
7
|
+
$z-index-toast: 1500; // Toast and snackbar notifications. DRAFT pending design review.
|
|
8
|
+
$z-index-tooltip: 1600; // Tooltips — the top-most interactive layer. DRAFT pending design review.
|
package/dist/tailwind/preset.css
CHANGED
|
@@ -956,3 +956,27 @@
|
|
|
956
956
|
--shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
|
|
957
957
|
--shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
|
|
958
958
|
}
|
|
959
|
+
|
|
960
|
+
|
|
961
|
+
/* ── tailwind/motion/global.css ── */
|
|
962
|
+
@theme {
|
|
963
|
+
--duration-fast: 150ms;
|
|
964
|
+
--duration-base: 250ms;
|
|
965
|
+
--duration-slow: 400ms;
|
|
966
|
+
--ease-standard: cubic-bezier(0.4, 0, 0.2, 1);
|
|
967
|
+
--ease-decelerate: cubic-bezier(0, 0, 0.2, 1);
|
|
968
|
+
--ease-accelerate: cubic-bezier(0.4, 0, 1, 1);
|
|
969
|
+
}
|
|
970
|
+
|
|
971
|
+
|
|
972
|
+
/* ── tailwind/z-index/global.css ── */
|
|
973
|
+
@theme {
|
|
974
|
+
--z-index-base: 0;
|
|
975
|
+
--z-index-dropdown: 1000;
|
|
976
|
+
--z-index-sticky: 1100;
|
|
977
|
+
--z-index-overlay: 1200;
|
|
978
|
+
--z-index-modal: 1300;
|
|
979
|
+
--z-index-popover: 1400;
|
|
980
|
+
--z-index-toast: 1500;
|
|
981
|
+
--z-index-tooltip: 1600;
|
|
982
|
+
}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
{
|
|
2
|
+
"duration": {
|
|
3
|
+
"fast": {
|
|
4
|
+
"$type": "duration",
|
|
5
|
+
"$description": "Fast — quick feedback on small elements (hovers, toggles, focus rings). DRAFT pending design review.",
|
|
6
|
+
"$value": {
|
|
7
|
+
"value": 150,
|
|
8
|
+
"unit": "ms"
|
|
9
|
+
}
|
|
10
|
+
},
|
|
11
|
+
"base": {
|
|
12
|
+
"$type": "duration",
|
|
13
|
+
"$description": "Base — the default duration for most UI transitions. DRAFT pending design review.",
|
|
14
|
+
"$value": {
|
|
15
|
+
"value": 250,
|
|
16
|
+
"unit": "ms"
|
|
17
|
+
}
|
|
18
|
+
},
|
|
19
|
+
"slow": {
|
|
20
|
+
"$type": "duration",
|
|
21
|
+
"$description": "Slow — larger surfaces entering or leaving (modals, drawers, sheets). DRAFT pending design review.",
|
|
22
|
+
"$value": {
|
|
23
|
+
"value": 400,
|
|
24
|
+
"unit": "ms"
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
},
|
|
28
|
+
"easing": {
|
|
29
|
+
"standard": {
|
|
30
|
+
"$type": "cubicBezier",
|
|
31
|
+
"$description": "Standard ease-in-out — the default curve for elements moving within the viewport. DRAFT pending design review.",
|
|
32
|
+
"$value": [0.4, 0, 0.2, 1]
|
|
33
|
+
},
|
|
34
|
+
"decelerate": {
|
|
35
|
+
"$type": "cubicBezier",
|
|
36
|
+
"$description": "Decelerate (ease-out) — elements entering the screen, fast then settling. DRAFT pending design review.",
|
|
37
|
+
"$value": [0, 0, 0.2, 1]
|
|
38
|
+
},
|
|
39
|
+
"accelerate": {
|
|
40
|
+
"$type": "cubicBezier",
|
|
41
|
+
"$description": "Accelerate (ease-in) — elements leaving the screen, building speed as they exit. DRAFT pending design review.",
|
|
42
|
+
"$value": [0.4, 0, 1, 1]
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
{
|
|
2
|
+
"z-index": {
|
|
3
|
+
"base": {
|
|
4
|
+
"$type": "number",
|
|
5
|
+
"$description": "Base stacking level (0) — default in-flow content. DRAFT pending design review.",
|
|
6
|
+
"$value": 0
|
|
7
|
+
},
|
|
8
|
+
"dropdown": {
|
|
9
|
+
"$type": "number",
|
|
10
|
+
"$description": "Dropdown menus and select popups. DRAFT pending design review.",
|
|
11
|
+
"$value": 1000
|
|
12
|
+
},
|
|
13
|
+
"sticky": {
|
|
14
|
+
"$type": "number",
|
|
15
|
+
"$description": "Sticky elements that pin on scroll (headers, toolbars). DRAFT pending design review.",
|
|
16
|
+
"$value": 1100
|
|
17
|
+
},
|
|
18
|
+
"overlay": {
|
|
19
|
+
"$type": "number",
|
|
20
|
+
"$description": "Full-screen overlay scrims sitting behind modal content. DRAFT pending design review.",
|
|
21
|
+
"$value": 1200
|
|
22
|
+
},
|
|
23
|
+
"modal": {
|
|
24
|
+
"$type": "number",
|
|
25
|
+
"$description": "Modal dialogs and side sheets. DRAFT pending design review.",
|
|
26
|
+
"$value": 1300
|
|
27
|
+
},
|
|
28
|
+
"popover": {
|
|
29
|
+
"$type": "number",
|
|
30
|
+
"$description": "Popovers anchored to a trigger, above modals. DRAFT pending design review.",
|
|
31
|
+
"$value": 1400
|
|
32
|
+
},
|
|
33
|
+
"toast": {
|
|
34
|
+
"$type": "number",
|
|
35
|
+
"$description": "Toast and snackbar notifications. DRAFT pending design review.",
|
|
36
|
+
"$value": 1500
|
|
37
|
+
},
|
|
38
|
+
"tooltip": {
|
|
39
|
+
"$type": "number",
|
|
40
|
+
"$description": "Tooltips — the top-most interactive layer. DRAFT pending design review.",
|
|
41
|
+
"$value": 1600
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nswds/tokens",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.8.1",
|
|
4
4
|
"description": "Design tokens for NSW Government digital products, providing colour tokens, theme outputs, and brand assets for use across CSS, SCSS, Less, JavaScript, TypeScript, JSON, Tailwind, Figma, and DTCG-compatible workflows.",
|
|
5
5
|
"license": "MPL-2.0",
|
|
6
6
|
"keywords": [
|