@motifx-community/design-system 0.1.0-beta.3 → 0.1.0-beta.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/CHANGELOG.md +7 -0
- package/README.md +1 -1
- package/dist/css/styles.css +4 -0
- package/dist/css/tokens.css +4 -0
- package/dist/js/generated/tokens.d.ts +20 -0
- package/dist/js/generated/tokens.js +4 -0
- package/dist/json/dark.json +28 -0
- package/dist/json/density-compact.json +28 -0
- package/dist/json/fluent/dark.json +28 -0
- package/dist/json/fluent/density-compact.json +28 -0
- package/dist/json/fluent/light.json +28 -0
- package/dist/json/high-contrast.json +28 -0
- package/dist/json/light.json +28 -0
- package/dist/json/lilac/dark.json +28 -0
- package/dist/json/lilac/density-compact.json +28 -0
- package/dist/json/lilac/light.json +28 -0
- package/dist/json/lounge/dark.json +28 -0
- package/dist/json/lounge/density-compact.json +28 -0
- package/dist/json/material/dark.json +28 -0
- package/dist/json/material/density-compact.json +28 -0
- package/dist/json/material/light.json +28 -0
- package/dist/json/tactile/dark.json +28 -0
- package/dist/json/tactile/density-compact.json +28 -0
- package/dist/json/tactile/high-contrast.json +28 -0
- package/dist/json/tactile/light.json +28 -0
- package/llms.txt +1 -1
- package/package.json +1 -1
- package/tokens/primitive/dimension.json +28 -0
package/CHANGELOG.md
CHANGED
|
@@ -7,6 +7,13 @@ renaming one is a breaking change and is announced one minor version ahead with
|
|
|
7
7
|
|
|
8
8
|
## [Unreleased]
|
|
9
9
|
|
|
10
|
+
## [0.1.0-beta.4] - 2026-11-30
|
|
11
|
+
|
|
12
|
+
### Added
|
|
13
|
+
|
|
14
|
+
- The `breakpoint` scale, `breakpoint.sm` (560 px), `md` (768 px), `lg` (1024 px) and `xl` (1440 px): the widths at
|
|
15
|
+
which a layout changes, measured on the container it fills rather than on the screen. Narrower than `sm` is `xs`.
|
|
16
|
+
|
|
10
17
|
## [0.1.0-beta.3] - 2026-11-07
|
|
11
18
|
|
|
12
19
|
### Added
|
package/README.md
CHANGED
|
@@ -47,7 +47,7 @@ That card is dark in the dark theme, black-and-white in `data-theme="high-contra
|
|
|
47
47
|
|
|
48
48
|
## Concepts
|
|
49
49
|
|
|
50
|
-
**Four layers.** *Primitive* tokens are the shared palette and scales (`color.gray.95`, `space.4`); components never read them. *Design language* tokens are what a language brings of its own: corner radii, shadows, type and motion (`radius.md`, `shadow.4`, `font.family.sans`, `motion.duration.fast`), the same names in every language with that language's values. *Semantic* tokens give the palette meaning per theme (`color.bg.canvas`, `color.fg.primary`, `color.accent.solid`, `focus.ring.color`) and are what components use. *Density* tokens (`control.height.md`, `control.padding.md`, `control.gap`) size controls. A component library adds a fifth layer of its own, component tokens, which reference these.
|
|
50
|
+
**Four layers.** *Primitive* tokens are the shared palette and scales (`color.gray.95`, `space.4`, `breakpoint.md`); components never read them. The `breakpoint` scale is where a layout changes, measured on the container it fills rather than on the screen: sm from 560 px, md from 768 px, lg from 1024 px, xl from 1440 px, and xs below them; a component library maps it to tokens of its own. *Design language* tokens are what a language brings of its own: corner radii, shadows, type and motion (`radius.md`, `shadow.4`, `font.family.sans`, `motion.duration.fast`), the same names in every language with that language's values. *Semantic* tokens give the palette meaning per theme (`color.bg.canvas`, `color.fg.primary`, `color.accent.solid`, `focus.ring.color`) and are what components use. *Density* tokens (`control.height.md`, `control.padding.md`, `control.gap`) size controls. A component library adds a fifth layer of its own, component tokens, which reference these.
|
|
51
51
|
|
|
52
52
|
**The CSS custom properties are the API.** `--mx-color-bg-canvas` is a public name, in `@layer mx.tokens`. Adding tokens is a minor release; removing or renaming one is a major release announced one minor ahead with `$deprecated`. The TypeScript side (`tokens`, `TokenName`, `cssVar`) is a typed view of the same names, not a second API.
|
|
53
53
|
|
package/dist/css/styles.css
CHANGED
|
@@ -436,6 +436,10 @@
|
|
|
436
436
|
--mx-icon-size-lg: 1.25rem;
|
|
437
437
|
--mx-border-width-1: 1px;
|
|
438
438
|
--mx-border-width-2: 2px;
|
|
439
|
+
--mx-breakpoint-sm: 560px;
|
|
440
|
+
--mx-breakpoint-md: 768px;
|
|
441
|
+
--mx-breakpoint-lg: 1024px;
|
|
442
|
+
--mx-breakpoint-xl: 1440px;
|
|
439
443
|
--mx-opacity-disabled: 0.5;
|
|
440
444
|
--mx-z-dropdown: 1000;
|
|
441
445
|
--mx-z-sticky: 1100;
|
package/dist/css/tokens.css
CHANGED
|
@@ -192,6 +192,10 @@
|
|
|
192
192
|
--mx-icon-size-lg: 1.25rem;
|
|
193
193
|
--mx-border-width-1: 1px;
|
|
194
194
|
--mx-border-width-2: 2px;
|
|
195
|
+
--mx-breakpoint-sm: 560px;
|
|
196
|
+
--mx-breakpoint-md: 768px;
|
|
197
|
+
--mx-breakpoint-lg: 1024px;
|
|
198
|
+
--mx-breakpoint-xl: 1440px;
|
|
195
199
|
--mx-opacity-disabled: 0.5;
|
|
196
200
|
--mx-z-dropdown: 1000;
|
|
197
201
|
--mx-z-sticky: 1100;
|
|
@@ -1370,6 +1370,26 @@ export declare const tokens: {
|
|
|
1370
1370
|
readonly type: 'dimension';
|
|
1371
1371
|
readonly layer: 'primitive';
|
|
1372
1372
|
};
|
|
1373
|
+
readonly 'breakpoint.sm': {
|
|
1374
|
+
readonly cssVar: '--mx-breakpoint-sm';
|
|
1375
|
+
readonly type: 'dimension';
|
|
1376
|
+
readonly layer: 'primitive';
|
|
1377
|
+
};
|
|
1378
|
+
readonly 'breakpoint.md': {
|
|
1379
|
+
readonly cssVar: '--mx-breakpoint-md';
|
|
1380
|
+
readonly type: 'dimension';
|
|
1381
|
+
readonly layer: 'primitive';
|
|
1382
|
+
};
|
|
1383
|
+
readonly 'breakpoint.lg': {
|
|
1384
|
+
readonly cssVar: '--mx-breakpoint-lg';
|
|
1385
|
+
readonly type: 'dimension';
|
|
1386
|
+
readonly layer: 'primitive';
|
|
1387
|
+
};
|
|
1388
|
+
readonly 'breakpoint.xl': {
|
|
1389
|
+
readonly cssVar: '--mx-breakpoint-xl';
|
|
1390
|
+
readonly type: 'dimension';
|
|
1391
|
+
readonly layer: 'primitive';
|
|
1392
|
+
};
|
|
1373
1393
|
readonly 'opacity.disabled': {
|
|
1374
1394
|
readonly cssVar: '--mx-opacity-disabled';
|
|
1375
1395
|
readonly type: 'number';
|
|
@@ -275,6 +275,10 @@ export const tokens = {
|
|
|
275
275
|
'icon.size.lg': { cssVar: '--mx-icon-size-lg', type: 'dimension', layer: 'primitive' },
|
|
276
276
|
'border.width.1': { cssVar: '--mx-border-width-1', type: 'dimension', layer: 'primitive' },
|
|
277
277
|
'border.width.2': { cssVar: '--mx-border-width-2', type: 'dimension', layer: 'primitive' },
|
|
278
|
+
'breakpoint.sm': { cssVar: '--mx-breakpoint-sm', type: 'dimension', layer: 'primitive' },
|
|
279
|
+
'breakpoint.md': { cssVar: '--mx-breakpoint-md', type: 'dimension', layer: 'primitive' },
|
|
280
|
+
'breakpoint.lg': { cssVar: '--mx-breakpoint-lg', type: 'dimension', layer: 'primitive' },
|
|
281
|
+
'breakpoint.xl': { cssVar: '--mx-breakpoint-xl', type: 'dimension', layer: 'primitive' },
|
|
278
282
|
'opacity.disabled': { cssVar: '--mx-opacity-disabled', type: 'number', layer: 'primitive' },
|
|
279
283
|
'z.dropdown': { cssVar: '--mx-z-dropdown', type: 'number', layer: 'primitive' },
|
|
280
284
|
'z.sticky': { cssVar: '--mx-z-sticky', type: 'number', layer: 'primitive' },
|
package/dist/json/dark.json
CHANGED
|
@@ -1917,6 +1917,34 @@
|
|
|
1917
1917
|
"value": "2px",
|
|
1918
1918
|
"ref": null
|
|
1919
1919
|
},
|
|
1920
|
+
"breakpoint.sm": {
|
|
1921
|
+
"cssVar": "--mx-breakpoint-sm",
|
|
1922
|
+
"type": "dimension",
|
|
1923
|
+
"layer": "primitive",
|
|
1924
|
+
"value": "560px",
|
|
1925
|
+
"ref": null
|
|
1926
|
+
},
|
|
1927
|
+
"breakpoint.md": {
|
|
1928
|
+
"cssVar": "--mx-breakpoint-md",
|
|
1929
|
+
"type": "dimension",
|
|
1930
|
+
"layer": "primitive",
|
|
1931
|
+
"value": "768px",
|
|
1932
|
+
"ref": null
|
|
1933
|
+
},
|
|
1934
|
+
"breakpoint.lg": {
|
|
1935
|
+
"cssVar": "--mx-breakpoint-lg",
|
|
1936
|
+
"type": "dimension",
|
|
1937
|
+
"layer": "primitive",
|
|
1938
|
+
"value": "1024px",
|
|
1939
|
+
"ref": null
|
|
1940
|
+
},
|
|
1941
|
+
"breakpoint.xl": {
|
|
1942
|
+
"cssVar": "--mx-breakpoint-xl",
|
|
1943
|
+
"type": "dimension",
|
|
1944
|
+
"layer": "primitive",
|
|
1945
|
+
"value": "1440px",
|
|
1946
|
+
"ref": null
|
|
1947
|
+
},
|
|
1920
1948
|
"opacity.disabled": {
|
|
1921
1949
|
"cssVar": "--mx-opacity-disabled",
|
|
1922
1950
|
"type": "number",
|
|
@@ -1917,6 +1917,34 @@
|
|
|
1917
1917
|
"value": "2px",
|
|
1918
1918
|
"ref": null
|
|
1919
1919
|
},
|
|
1920
|
+
"breakpoint.sm": {
|
|
1921
|
+
"cssVar": "--mx-breakpoint-sm",
|
|
1922
|
+
"type": "dimension",
|
|
1923
|
+
"layer": "primitive",
|
|
1924
|
+
"value": "560px",
|
|
1925
|
+
"ref": null
|
|
1926
|
+
},
|
|
1927
|
+
"breakpoint.md": {
|
|
1928
|
+
"cssVar": "--mx-breakpoint-md",
|
|
1929
|
+
"type": "dimension",
|
|
1930
|
+
"layer": "primitive",
|
|
1931
|
+
"value": "768px",
|
|
1932
|
+
"ref": null
|
|
1933
|
+
},
|
|
1934
|
+
"breakpoint.lg": {
|
|
1935
|
+
"cssVar": "--mx-breakpoint-lg",
|
|
1936
|
+
"type": "dimension",
|
|
1937
|
+
"layer": "primitive",
|
|
1938
|
+
"value": "1024px",
|
|
1939
|
+
"ref": null
|
|
1940
|
+
},
|
|
1941
|
+
"breakpoint.xl": {
|
|
1942
|
+
"cssVar": "--mx-breakpoint-xl",
|
|
1943
|
+
"type": "dimension",
|
|
1944
|
+
"layer": "primitive",
|
|
1945
|
+
"value": "1440px",
|
|
1946
|
+
"ref": null
|
|
1947
|
+
},
|
|
1920
1948
|
"opacity.disabled": {
|
|
1921
1949
|
"cssVar": "--mx-opacity-disabled",
|
|
1922
1950
|
"type": "number",
|
|
@@ -1917,6 +1917,34 @@
|
|
|
1917
1917
|
"value": "2px",
|
|
1918
1918
|
"ref": null
|
|
1919
1919
|
},
|
|
1920
|
+
"breakpoint.sm": {
|
|
1921
|
+
"cssVar": "--mx-breakpoint-sm",
|
|
1922
|
+
"type": "dimension",
|
|
1923
|
+
"layer": "primitive",
|
|
1924
|
+
"value": "560px",
|
|
1925
|
+
"ref": null
|
|
1926
|
+
},
|
|
1927
|
+
"breakpoint.md": {
|
|
1928
|
+
"cssVar": "--mx-breakpoint-md",
|
|
1929
|
+
"type": "dimension",
|
|
1930
|
+
"layer": "primitive",
|
|
1931
|
+
"value": "768px",
|
|
1932
|
+
"ref": null
|
|
1933
|
+
},
|
|
1934
|
+
"breakpoint.lg": {
|
|
1935
|
+
"cssVar": "--mx-breakpoint-lg",
|
|
1936
|
+
"type": "dimension",
|
|
1937
|
+
"layer": "primitive",
|
|
1938
|
+
"value": "1024px",
|
|
1939
|
+
"ref": null
|
|
1940
|
+
},
|
|
1941
|
+
"breakpoint.xl": {
|
|
1942
|
+
"cssVar": "--mx-breakpoint-xl",
|
|
1943
|
+
"type": "dimension",
|
|
1944
|
+
"layer": "primitive",
|
|
1945
|
+
"value": "1440px",
|
|
1946
|
+
"ref": null
|
|
1947
|
+
},
|
|
1920
1948
|
"opacity.disabled": {
|
|
1921
1949
|
"cssVar": "--mx-opacity-disabled",
|
|
1922
1950
|
"type": "number",
|
|
@@ -1917,6 +1917,34 @@
|
|
|
1917
1917
|
"value": "2px",
|
|
1918
1918
|
"ref": null
|
|
1919
1919
|
},
|
|
1920
|
+
"breakpoint.sm": {
|
|
1921
|
+
"cssVar": "--mx-breakpoint-sm",
|
|
1922
|
+
"type": "dimension",
|
|
1923
|
+
"layer": "primitive",
|
|
1924
|
+
"value": "560px",
|
|
1925
|
+
"ref": null
|
|
1926
|
+
},
|
|
1927
|
+
"breakpoint.md": {
|
|
1928
|
+
"cssVar": "--mx-breakpoint-md",
|
|
1929
|
+
"type": "dimension",
|
|
1930
|
+
"layer": "primitive",
|
|
1931
|
+
"value": "768px",
|
|
1932
|
+
"ref": null
|
|
1933
|
+
},
|
|
1934
|
+
"breakpoint.lg": {
|
|
1935
|
+
"cssVar": "--mx-breakpoint-lg",
|
|
1936
|
+
"type": "dimension",
|
|
1937
|
+
"layer": "primitive",
|
|
1938
|
+
"value": "1024px",
|
|
1939
|
+
"ref": null
|
|
1940
|
+
},
|
|
1941
|
+
"breakpoint.xl": {
|
|
1942
|
+
"cssVar": "--mx-breakpoint-xl",
|
|
1943
|
+
"type": "dimension",
|
|
1944
|
+
"layer": "primitive",
|
|
1945
|
+
"value": "1440px",
|
|
1946
|
+
"ref": null
|
|
1947
|
+
},
|
|
1920
1948
|
"opacity.disabled": {
|
|
1921
1949
|
"cssVar": "--mx-opacity-disabled",
|
|
1922
1950
|
"type": "number",
|
|
@@ -1917,6 +1917,34 @@
|
|
|
1917
1917
|
"value": "2px",
|
|
1918
1918
|
"ref": null
|
|
1919
1919
|
},
|
|
1920
|
+
"breakpoint.sm": {
|
|
1921
|
+
"cssVar": "--mx-breakpoint-sm",
|
|
1922
|
+
"type": "dimension",
|
|
1923
|
+
"layer": "primitive",
|
|
1924
|
+
"value": "560px",
|
|
1925
|
+
"ref": null
|
|
1926
|
+
},
|
|
1927
|
+
"breakpoint.md": {
|
|
1928
|
+
"cssVar": "--mx-breakpoint-md",
|
|
1929
|
+
"type": "dimension",
|
|
1930
|
+
"layer": "primitive",
|
|
1931
|
+
"value": "768px",
|
|
1932
|
+
"ref": null
|
|
1933
|
+
},
|
|
1934
|
+
"breakpoint.lg": {
|
|
1935
|
+
"cssVar": "--mx-breakpoint-lg",
|
|
1936
|
+
"type": "dimension",
|
|
1937
|
+
"layer": "primitive",
|
|
1938
|
+
"value": "1024px",
|
|
1939
|
+
"ref": null
|
|
1940
|
+
},
|
|
1941
|
+
"breakpoint.xl": {
|
|
1942
|
+
"cssVar": "--mx-breakpoint-xl",
|
|
1943
|
+
"type": "dimension",
|
|
1944
|
+
"layer": "primitive",
|
|
1945
|
+
"value": "1440px",
|
|
1946
|
+
"ref": null
|
|
1947
|
+
},
|
|
1920
1948
|
"opacity.disabled": {
|
|
1921
1949
|
"cssVar": "--mx-opacity-disabled",
|
|
1922
1950
|
"type": "number",
|
|
@@ -1917,6 +1917,34 @@
|
|
|
1917
1917
|
"value": "2px",
|
|
1918
1918
|
"ref": null
|
|
1919
1919
|
},
|
|
1920
|
+
"breakpoint.sm": {
|
|
1921
|
+
"cssVar": "--mx-breakpoint-sm",
|
|
1922
|
+
"type": "dimension",
|
|
1923
|
+
"layer": "primitive",
|
|
1924
|
+
"value": "560px",
|
|
1925
|
+
"ref": null
|
|
1926
|
+
},
|
|
1927
|
+
"breakpoint.md": {
|
|
1928
|
+
"cssVar": "--mx-breakpoint-md",
|
|
1929
|
+
"type": "dimension",
|
|
1930
|
+
"layer": "primitive",
|
|
1931
|
+
"value": "768px",
|
|
1932
|
+
"ref": null
|
|
1933
|
+
},
|
|
1934
|
+
"breakpoint.lg": {
|
|
1935
|
+
"cssVar": "--mx-breakpoint-lg",
|
|
1936
|
+
"type": "dimension",
|
|
1937
|
+
"layer": "primitive",
|
|
1938
|
+
"value": "1024px",
|
|
1939
|
+
"ref": null
|
|
1940
|
+
},
|
|
1941
|
+
"breakpoint.xl": {
|
|
1942
|
+
"cssVar": "--mx-breakpoint-xl",
|
|
1943
|
+
"type": "dimension",
|
|
1944
|
+
"layer": "primitive",
|
|
1945
|
+
"value": "1440px",
|
|
1946
|
+
"ref": null
|
|
1947
|
+
},
|
|
1920
1948
|
"opacity.disabled": {
|
|
1921
1949
|
"cssVar": "--mx-opacity-disabled",
|
|
1922
1950
|
"type": "number",
|
package/dist/json/light.json
CHANGED
|
@@ -1917,6 +1917,34 @@
|
|
|
1917
1917
|
"value": "2px",
|
|
1918
1918
|
"ref": null
|
|
1919
1919
|
},
|
|
1920
|
+
"breakpoint.sm": {
|
|
1921
|
+
"cssVar": "--mx-breakpoint-sm",
|
|
1922
|
+
"type": "dimension",
|
|
1923
|
+
"layer": "primitive",
|
|
1924
|
+
"value": "560px",
|
|
1925
|
+
"ref": null
|
|
1926
|
+
},
|
|
1927
|
+
"breakpoint.md": {
|
|
1928
|
+
"cssVar": "--mx-breakpoint-md",
|
|
1929
|
+
"type": "dimension",
|
|
1930
|
+
"layer": "primitive",
|
|
1931
|
+
"value": "768px",
|
|
1932
|
+
"ref": null
|
|
1933
|
+
},
|
|
1934
|
+
"breakpoint.lg": {
|
|
1935
|
+
"cssVar": "--mx-breakpoint-lg",
|
|
1936
|
+
"type": "dimension",
|
|
1937
|
+
"layer": "primitive",
|
|
1938
|
+
"value": "1024px",
|
|
1939
|
+
"ref": null
|
|
1940
|
+
},
|
|
1941
|
+
"breakpoint.xl": {
|
|
1942
|
+
"cssVar": "--mx-breakpoint-xl",
|
|
1943
|
+
"type": "dimension",
|
|
1944
|
+
"layer": "primitive",
|
|
1945
|
+
"value": "1440px",
|
|
1946
|
+
"ref": null
|
|
1947
|
+
},
|
|
1920
1948
|
"opacity.disabled": {
|
|
1921
1949
|
"cssVar": "--mx-opacity-disabled",
|
|
1922
1950
|
"type": "number",
|
|
@@ -1917,6 +1917,34 @@
|
|
|
1917
1917
|
"value": "2px",
|
|
1918
1918
|
"ref": null
|
|
1919
1919
|
},
|
|
1920
|
+
"breakpoint.sm": {
|
|
1921
|
+
"cssVar": "--mx-breakpoint-sm",
|
|
1922
|
+
"type": "dimension",
|
|
1923
|
+
"layer": "primitive",
|
|
1924
|
+
"value": "560px",
|
|
1925
|
+
"ref": null
|
|
1926
|
+
},
|
|
1927
|
+
"breakpoint.md": {
|
|
1928
|
+
"cssVar": "--mx-breakpoint-md",
|
|
1929
|
+
"type": "dimension",
|
|
1930
|
+
"layer": "primitive",
|
|
1931
|
+
"value": "768px",
|
|
1932
|
+
"ref": null
|
|
1933
|
+
},
|
|
1934
|
+
"breakpoint.lg": {
|
|
1935
|
+
"cssVar": "--mx-breakpoint-lg",
|
|
1936
|
+
"type": "dimension",
|
|
1937
|
+
"layer": "primitive",
|
|
1938
|
+
"value": "1024px",
|
|
1939
|
+
"ref": null
|
|
1940
|
+
},
|
|
1941
|
+
"breakpoint.xl": {
|
|
1942
|
+
"cssVar": "--mx-breakpoint-xl",
|
|
1943
|
+
"type": "dimension",
|
|
1944
|
+
"layer": "primitive",
|
|
1945
|
+
"value": "1440px",
|
|
1946
|
+
"ref": null
|
|
1947
|
+
},
|
|
1920
1948
|
"opacity.disabled": {
|
|
1921
1949
|
"cssVar": "--mx-opacity-disabled",
|
|
1922
1950
|
"type": "number",
|
|
@@ -1917,6 +1917,34 @@
|
|
|
1917
1917
|
"value": "2px",
|
|
1918
1918
|
"ref": null
|
|
1919
1919
|
},
|
|
1920
|
+
"breakpoint.sm": {
|
|
1921
|
+
"cssVar": "--mx-breakpoint-sm",
|
|
1922
|
+
"type": "dimension",
|
|
1923
|
+
"layer": "primitive",
|
|
1924
|
+
"value": "560px",
|
|
1925
|
+
"ref": null
|
|
1926
|
+
},
|
|
1927
|
+
"breakpoint.md": {
|
|
1928
|
+
"cssVar": "--mx-breakpoint-md",
|
|
1929
|
+
"type": "dimension",
|
|
1930
|
+
"layer": "primitive",
|
|
1931
|
+
"value": "768px",
|
|
1932
|
+
"ref": null
|
|
1933
|
+
},
|
|
1934
|
+
"breakpoint.lg": {
|
|
1935
|
+
"cssVar": "--mx-breakpoint-lg",
|
|
1936
|
+
"type": "dimension",
|
|
1937
|
+
"layer": "primitive",
|
|
1938
|
+
"value": "1024px",
|
|
1939
|
+
"ref": null
|
|
1940
|
+
},
|
|
1941
|
+
"breakpoint.xl": {
|
|
1942
|
+
"cssVar": "--mx-breakpoint-xl",
|
|
1943
|
+
"type": "dimension",
|
|
1944
|
+
"layer": "primitive",
|
|
1945
|
+
"value": "1440px",
|
|
1946
|
+
"ref": null
|
|
1947
|
+
},
|
|
1920
1948
|
"opacity.disabled": {
|
|
1921
1949
|
"cssVar": "--mx-opacity-disabled",
|
|
1922
1950
|
"type": "number",
|
|
@@ -1917,6 +1917,34 @@
|
|
|
1917
1917
|
"value": "2px",
|
|
1918
1918
|
"ref": null
|
|
1919
1919
|
},
|
|
1920
|
+
"breakpoint.sm": {
|
|
1921
|
+
"cssVar": "--mx-breakpoint-sm",
|
|
1922
|
+
"type": "dimension",
|
|
1923
|
+
"layer": "primitive",
|
|
1924
|
+
"value": "560px",
|
|
1925
|
+
"ref": null
|
|
1926
|
+
},
|
|
1927
|
+
"breakpoint.md": {
|
|
1928
|
+
"cssVar": "--mx-breakpoint-md",
|
|
1929
|
+
"type": "dimension",
|
|
1930
|
+
"layer": "primitive",
|
|
1931
|
+
"value": "768px",
|
|
1932
|
+
"ref": null
|
|
1933
|
+
},
|
|
1934
|
+
"breakpoint.lg": {
|
|
1935
|
+
"cssVar": "--mx-breakpoint-lg",
|
|
1936
|
+
"type": "dimension",
|
|
1937
|
+
"layer": "primitive",
|
|
1938
|
+
"value": "1024px",
|
|
1939
|
+
"ref": null
|
|
1940
|
+
},
|
|
1941
|
+
"breakpoint.xl": {
|
|
1942
|
+
"cssVar": "--mx-breakpoint-xl",
|
|
1943
|
+
"type": "dimension",
|
|
1944
|
+
"layer": "primitive",
|
|
1945
|
+
"value": "1440px",
|
|
1946
|
+
"ref": null
|
|
1947
|
+
},
|
|
1920
1948
|
"opacity.disabled": {
|
|
1921
1949
|
"cssVar": "--mx-opacity-disabled",
|
|
1922
1950
|
"type": "number",
|
|
@@ -1917,6 +1917,34 @@
|
|
|
1917
1917
|
"value": "2px",
|
|
1918
1918
|
"ref": null
|
|
1919
1919
|
},
|
|
1920
|
+
"breakpoint.sm": {
|
|
1921
|
+
"cssVar": "--mx-breakpoint-sm",
|
|
1922
|
+
"type": "dimension",
|
|
1923
|
+
"layer": "primitive",
|
|
1924
|
+
"value": "560px",
|
|
1925
|
+
"ref": null
|
|
1926
|
+
},
|
|
1927
|
+
"breakpoint.md": {
|
|
1928
|
+
"cssVar": "--mx-breakpoint-md",
|
|
1929
|
+
"type": "dimension",
|
|
1930
|
+
"layer": "primitive",
|
|
1931
|
+
"value": "768px",
|
|
1932
|
+
"ref": null
|
|
1933
|
+
},
|
|
1934
|
+
"breakpoint.lg": {
|
|
1935
|
+
"cssVar": "--mx-breakpoint-lg",
|
|
1936
|
+
"type": "dimension",
|
|
1937
|
+
"layer": "primitive",
|
|
1938
|
+
"value": "1024px",
|
|
1939
|
+
"ref": null
|
|
1940
|
+
},
|
|
1941
|
+
"breakpoint.xl": {
|
|
1942
|
+
"cssVar": "--mx-breakpoint-xl",
|
|
1943
|
+
"type": "dimension",
|
|
1944
|
+
"layer": "primitive",
|
|
1945
|
+
"value": "1440px",
|
|
1946
|
+
"ref": null
|
|
1947
|
+
},
|
|
1920
1948
|
"opacity.disabled": {
|
|
1921
1949
|
"cssVar": "--mx-opacity-disabled",
|
|
1922
1950
|
"type": "number",
|
|
@@ -1917,6 +1917,34 @@
|
|
|
1917
1917
|
"value": "2px",
|
|
1918
1918
|
"ref": null
|
|
1919
1919
|
},
|
|
1920
|
+
"breakpoint.sm": {
|
|
1921
|
+
"cssVar": "--mx-breakpoint-sm",
|
|
1922
|
+
"type": "dimension",
|
|
1923
|
+
"layer": "primitive",
|
|
1924
|
+
"value": "560px",
|
|
1925
|
+
"ref": null
|
|
1926
|
+
},
|
|
1927
|
+
"breakpoint.md": {
|
|
1928
|
+
"cssVar": "--mx-breakpoint-md",
|
|
1929
|
+
"type": "dimension",
|
|
1930
|
+
"layer": "primitive",
|
|
1931
|
+
"value": "768px",
|
|
1932
|
+
"ref": null
|
|
1933
|
+
},
|
|
1934
|
+
"breakpoint.lg": {
|
|
1935
|
+
"cssVar": "--mx-breakpoint-lg",
|
|
1936
|
+
"type": "dimension",
|
|
1937
|
+
"layer": "primitive",
|
|
1938
|
+
"value": "1024px",
|
|
1939
|
+
"ref": null
|
|
1940
|
+
},
|
|
1941
|
+
"breakpoint.xl": {
|
|
1942
|
+
"cssVar": "--mx-breakpoint-xl",
|
|
1943
|
+
"type": "dimension",
|
|
1944
|
+
"layer": "primitive",
|
|
1945
|
+
"value": "1440px",
|
|
1946
|
+
"ref": null
|
|
1947
|
+
},
|
|
1920
1948
|
"opacity.disabled": {
|
|
1921
1949
|
"cssVar": "--mx-opacity-disabled",
|
|
1922
1950
|
"type": "number",
|
|
@@ -1917,6 +1917,34 @@
|
|
|
1917
1917
|
"value": "2px",
|
|
1918
1918
|
"ref": null
|
|
1919
1919
|
},
|
|
1920
|
+
"breakpoint.sm": {
|
|
1921
|
+
"cssVar": "--mx-breakpoint-sm",
|
|
1922
|
+
"type": "dimension",
|
|
1923
|
+
"layer": "primitive",
|
|
1924
|
+
"value": "560px",
|
|
1925
|
+
"ref": null
|
|
1926
|
+
},
|
|
1927
|
+
"breakpoint.md": {
|
|
1928
|
+
"cssVar": "--mx-breakpoint-md",
|
|
1929
|
+
"type": "dimension",
|
|
1930
|
+
"layer": "primitive",
|
|
1931
|
+
"value": "768px",
|
|
1932
|
+
"ref": null
|
|
1933
|
+
},
|
|
1934
|
+
"breakpoint.lg": {
|
|
1935
|
+
"cssVar": "--mx-breakpoint-lg",
|
|
1936
|
+
"type": "dimension",
|
|
1937
|
+
"layer": "primitive",
|
|
1938
|
+
"value": "1024px",
|
|
1939
|
+
"ref": null
|
|
1940
|
+
},
|
|
1941
|
+
"breakpoint.xl": {
|
|
1942
|
+
"cssVar": "--mx-breakpoint-xl",
|
|
1943
|
+
"type": "dimension",
|
|
1944
|
+
"layer": "primitive",
|
|
1945
|
+
"value": "1440px",
|
|
1946
|
+
"ref": null
|
|
1947
|
+
},
|
|
1920
1948
|
"opacity.disabled": {
|
|
1921
1949
|
"cssVar": "--mx-opacity-disabled",
|
|
1922
1950
|
"type": "number",
|
|
@@ -1917,6 +1917,34 @@
|
|
|
1917
1917
|
"value": "2px",
|
|
1918
1918
|
"ref": null
|
|
1919
1919
|
},
|
|
1920
|
+
"breakpoint.sm": {
|
|
1921
|
+
"cssVar": "--mx-breakpoint-sm",
|
|
1922
|
+
"type": "dimension",
|
|
1923
|
+
"layer": "primitive",
|
|
1924
|
+
"value": "560px",
|
|
1925
|
+
"ref": null
|
|
1926
|
+
},
|
|
1927
|
+
"breakpoint.md": {
|
|
1928
|
+
"cssVar": "--mx-breakpoint-md",
|
|
1929
|
+
"type": "dimension",
|
|
1930
|
+
"layer": "primitive",
|
|
1931
|
+
"value": "768px",
|
|
1932
|
+
"ref": null
|
|
1933
|
+
},
|
|
1934
|
+
"breakpoint.lg": {
|
|
1935
|
+
"cssVar": "--mx-breakpoint-lg",
|
|
1936
|
+
"type": "dimension",
|
|
1937
|
+
"layer": "primitive",
|
|
1938
|
+
"value": "1024px",
|
|
1939
|
+
"ref": null
|
|
1940
|
+
},
|
|
1941
|
+
"breakpoint.xl": {
|
|
1942
|
+
"cssVar": "--mx-breakpoint-xl",
|
|
1943
|
+
"type": "dimension",
|
|
1944
|
+
"layer": "primitive",
|
|
1945
|
+
"value": "1440px",
|
|
1946
|
+
"ref": null
|
|
1947
|
+
},
|
|
1920
1948
|
"opacity.disabled": {
|
|
1921
1949
|
"cssVar": "--mx-opacity-disabled",
|
|
1922
1950
|
"type": "number",
|
|
@@ -1917,6 +1917,34 @@
|
|
|
1917
1917
|
"value": "2px",
|
|
1918
1918
|
"ref": null
|
|
1919
1919
|
},
|
|
1920
|
+
"breakpoint.sm": {
|
|
1921
|
+
"cssVar": "--mx-breakpoint-sm",
|
|
1922
|
+
"type": "dimension",
|
|
1923
|
+
"layer": "primitive",
|
|
1924
|
+
"value": "560px",
|
|
1925
|
+
"ref": null
|
|
1926
|
+
},
|
|
1927
|
+
"breakpoint.md": {
|
|
1928
|
+
"cssVar": "--mx-breakpoint-md",
|
|
1929
|
+
"type": "dimension",
|
|
1930
|
+
"layer": "primitive",
|
|
1931
|
+
"value": "768px",
|
|
1932
|
+
"ref": null
|
|
1933
|
+
},
|
|
1934
|
+
"breakpoint.lg": {
|
|
1935
|
+
"cssVar": "--mx-breakpoint-lg",
|
|
1936
|
+
"type": "dimension",
|
|
1937
|
+
"layer": "primitive",
|
|
1938
|
+
"value": "1024px",
|
|
1939
|
+
"ref": null
|
|
1940
|
+
},
|
|
1941
|
+
"breakpoint.xl": {
|
|
1942
|
+
"cssVar": "--mx-breakpoint-xl",
|
|
1943
|
+
"type": "dimension",
|
|
1944
|
+
"layer": "primitive",
|
|
1945
|
+
"value": "1440px",
|
|
1946
|
+
"ref": null
|
|
1947
|
+
},
|
|
1920
1948
|
"opacity.disabled": {
|
|
1921
1949
|
"cssVar": "--mx-opacity-disabled",
|
|
1922
1950
|
"type": "number",
|
|
@@ -1917,6 +1917,34 @@
|
|
|
1917
1917
|
"value": "2px",
|
|
1918
1918
|
"ref": null
|
|
1919
1919
|
},
|
|
1920
|
+
"breakpoint.sm": {
|
|
1921
|
+
"cssVar": "--mx-breakpoint-sm",
|
|
1922
|
+
"type": "dimension",
|
|
1923
|
+
"layer": "primitive",
|
|
1924
|
+
"value": "560px",
|
|
1925
|
+
"ref": null
|
|
1926
|
+
},
|
|
1927
|
+
"breakpoint.md": {
|
|
1928
|
+
"cssVar": "--mx-breakpoint-md",
|
|
1929
|
+
"type": "dimension",
|
|
1930
|
+
"layer": "primitive",
|
|
1931
|
+
"value": "768px",
|
|
1932
|
+
"ref": null
|
|
1933
|
+
},
|
|
1934
|
+
"breakpoint.lg": {
|
|
1935
|
+
"cssVar": "--mx-breakpoint-lg",
|
|
1936
|
+
"type": "dimension",
|
|
1937
|
+
"layer": "primitive",
|
|
1938
|
+
"value": "1024px",
|
|
1939
|
+
"ref": null
|
|
1940
|
+
},
|
|
1941
|
+
"breakpoint.xl": {
|
|
1942
|
+
"cssVar": "--mx-breakpoint-xl",
|
|
1943
|
+
"type": "dimension",
|
|
1944
|
+
"layer": "primitive",
|
|
1945
|
+
"value": "1440px",
|
|
1946
|
+
"ref": null
|
|
1947
|
+
},
|
|
1920
1948
|
"opacity.disabled": {
|
|
1921
1949
|
"cssVar": "--mx-opacity-disabled",
|
|
1922
1950
|
"type": "number",
|
|
@@ -1917,6 +1917,34 @@
|
|
|
1917
1917
|
"value": "2px",
|
|
1918
1918
|
"ref": null
|
|
1919
1919
|
},
|
|
1920
|
+
"breakpoint.sm": {
|
|
1921
|
+
"cssVar": "--mx-breakpoint-sm",
|
|
1922
|
+
"type": "dimension",
|
|
1923
|
+
"layer": "primitive",
|
|
1924
|
+
"value": "560px",
|
|
1925
|
+
"ref": null
|
|
1926
|
+
},
|
|
1927
|
+
"breakpoint.md": {
|
|
1928
|
+
"cssVar": "--mx-breakpoint-md",
|
|
1929
|
+
"type": "dimension",
|
|
1930
|
+
"layer": "primitive",
|
|
1931
|
+
"value": "768px",
|
|
1932
|
+
"ref": null
|
|
1933
|
+
},
|
|
1934
|
+
"breakpoint.lg": {
|
|
1935
|
+
"cssVar": "--mx-breakpoint-lg",
|
|
1936
|
+
"type": "dimension",
|
|
1937
|
+
"layer": "primitive",
|
|
1938
|
+
"value": "1024px",
|
|
1939
|
+
"ref": null
|
|
1940
|
+
},
|
|
1941
|
+
"breakpoint.xl": {
|
|
1942
|
+
"cssVar": "--mx-breakpoint-xl",
|
|
1943
|
+
"type": "dimension",
|
|
1944
|
+
"layer": "primitive",
|
|
1945
|
+
"value": "1440px",
|
|
1946
|
+
"ref": null
|
|
1947
|
+
},
|
|
1920
1948
|
"opacity.disabled": {
|
|
1921
1949
|
"cssVar": "--mx-opacity-disabled",
|
|
1922
1950
|
"type": "number",
|
|
@@ -1917,6 +1917,34 @@
|
|
|
1917
1917
|
"value": "2px",
|
|
1918
1918
|
"ref": null
|
|
1919
1919
|
},
|
|
1920
|
+
"breakpoint.sm": {
|
|
1921
|
+
"cssVar": "--mx-breakpoint-sm",
|
|
1922
|
+
"type": "dimension",
|
|
1923
|
+
"layer": "primitive",
|
|
1924
|
+
"value": "560px",
|
|
1925
|
+
"ref": null
|
|
1926
|
+
},
|
|
1927
|
+
"breakpoint.md": {
|
|
1928
|
+
"cssVar": "--mx-breakpoint-md",
|
|
1929
|
+
"type": "dimension",
|
|
1930
|
+
"layer": "primitive",
|
|
1931
|
+
"value": "768px",
|
|
1932
|
+
"ref": null
|
|
1933
|
+
},
|
|
1934
|
+
"breakpoint.lg": {
|
|
1935
|
+
"cssVar": "--mx-breakpoint-lg",
|
|
1936
|
+
"type": "dimension",
|
|
1937
|
+
"layer": "primitive",
|
|
1938
|
+
"value": "1024px",
|
|
1939
|
+
"ref": null
|
|
1940
|
+
},
|
|
1941
|
+
"breakpoint.xl": {
|
|
1942
|
+
"cssVar": "--mx-breakpoint-xl",
|
|
1943
|
+
"type": "dimension",
|
|
1944
|
+
"layer": "primitive",
|
|
1945
|
+
"value": "1440px",
|
|
1946
|
+
"ref": null
|
|
1947
|
+
},
|
|
1920
1948
|
"opacity.disabled": {
|
|
1921
1949
|
"cssVar": "--mx-opacity-disabled",
|
|
1922
1950
|
"type": "number",
|
|
@@ -1917,6 +1917,34 @@
|
|
|
1917
1917
|
"value": "2px",
|
|
1918
1918
|
"ref": null
|
|
1919
1919
|
},
|
|
1920
|
+
"breakpoint.sm": {
|
|
1921
|
+
"cssVar": "--mx-breakpoint-sm",
|
|
1922
|
+
"type": "dimension",
|
|
1923
|
+
"layer": "primitive",
|
|
1924
|
+
"value": "560px",
|
|
1925
|
+
"ref": null
|
|
1926
|
+
},
|
|
1927
|
+
"breakpoint.md": {
|
|
1928
|
+
"cssVar": "--mx-breakpoint-md",
|
|
1929
|
+
"type": "dimension",
|
|
1930
|
+
"layer": "primitive",
|
|
1931
|
+
"value": "768px",
|
|
1932
|
+
"ref": null
|
|
1933
|
+
},
|
|
1934
|
+
"breakpoint.lg": {
|
|
1935
|
+
"cssVar": "--mx-breakpoint-lg",
|
|
1936
|
+
"type": "dimension",
|
|
1937
|
+
"layer": "primitive",
|
|
1938
|
+
"value": "1024px",
|
|
1939
|
+
"ref": null
|
|
1940
|
+
},
|
|
1941
|
+
"breakpoint.xl": {
|
|
1942
|
+
"cssVar": "--mx-breakpoint-xl",
|
|
1943
|
+
"type": "dimension",
|
|
1944
|
+
"layer": "primitive",
|
|
1945
|
+
"value": "1440px",
|
|
1946
|
+
"ref": null
|
|
1947
|
+
},
|
|
1920
1948
|
"opacity.disabled": {
|
|
1921
1949
|
"cssVar": "--mx-opacity-disabled",
|
|
1922
1950
|
"type": "number",
|
package/llms.txt
CHANGED
|
@@ -44,7 +44,7 @@ That card is dark in the dark theme, black-and-white in `data-theme="high-contra
|
|
|
44
44
|
|
|
45
45
|
## Concepts
|
|
46
46
|
|
|
47
|
-
**Four layers.** *Primitive* tokens are the shared palette and scales (`color.gray.95`, `space.4`); components never read them. *Design language* tokens are what a language brings of its own: corner radii, shadows, type and motion (`radius.md`, `shadow.4`, `font.family.sans`, `motion.duration.fast`), the same names in every language with that language's values. *Semantic* tokens give the palette meaning per theme (`color.bg.canvas`, `color.fg.primary`, `color.accent.solid`, `focus.ring.color`) and are what components use. *Density* tokens (`control.height.md`, `control.padding.md`, `control.gap`) size controls. A component library adds a fifth layer of its own, component tokens, which reference these.
|
|
47
|
+
**Four layers.** *Primitive* tokens are the shared palette and scales (`color.gray.95`, `space.4`, `breakpoint.md`); components never read them. The `breakpoint` scale is where a layout changes, measured on the container it fills rather than on the screen: sm from 560 px, md from 768 px, lg from 1024 px, xl from 1440 px, and xs below them; a component library maps it to tokens of its own. *Design language* tokens are what a language brings of its own: corner radii, shadows, type and motion (`radius.md`, `shadow.4`, `font.family.sans`, `motion.duration.fast`), the same names in every language with that language's values. *Semantic* tokens give the palette meaning per theme (`color.bg.canvas`, `color.fg.primary`, `color.accent.solid`, `focus.ring.color`) and are what components use. *Density* tokens (`control.height.md`, `control.padding.md`, `control.gap`) size controls. A component library adds a fifth layer of its own, component tokens, which reference these.
|
|
48
48
|
|
|
49
49
|
**The CSS custom properties are the API.** `--mx-color-bg-canvas` is a public name, in `@layer mx.tokens`. Adding tokens is a minor release; removing or renaming one is a major release announced one minor ahead with `$deprecated`. The TypeScript side (`tokens`, `TokenName`, `cssVar`) is a typed view of the same names, not a second API.
|
|
50
50
|
|
package/package.json
CHANGED
|
@@ -110,5 +110,33 @@
|
|
|
110
110
|
"$description": "Border widths.",
|
|
111
111
|
"$type": "dimension"
|
|
112
112
|
}
|
|
113
|
+
},
|
|
114
|
+
"breakpoint": {
|
|
115
|
+
"$description": "Widths at which a layout changes, measured on the container it fills, not on the screen: sm from 560 px (a large phone, a narrow pane), md from 768 px (a tablet held upright), lg from 1024 px (a tablet on its side, a small desktop), xl from 1440 px (a wide desktop). Narrower than sm is xs.",
|
|
116
|
+
"$type": "dimension",
|
|
117
|
+
"sm": {
|
|
118
|
+
"$value": {
|
|
119
|
+
"value": 560,
|
|
120
|
+
"unit": "px"
|
|
121
|
+
}
|
|
122
|
+
},
|
|
123
|
+
"md": {
|
|
124
|
+
"$value": {
|
|
125
|
+
"value": 768,
|
|
126
|
+
"unit": "px"
|
|
127
|
+
}
|
|
128
|
+
},
|
|
129
|
+
"lg": {
|
|
130
|
+
"$value": {
|
|
131
|
+
"value": 1024,
|
|
132
|
+
"unit": "px"
|
|
133
|
+
}
|
|
134
|
+
},
|
|
135
|
+
"xl": {
|
|
136
|
+
"$value": {
|
|
137
|
+
"value": 1440,
|
|
138
|
+
"unit": "px"
|
|
139
|
+
}
|
|
140
|
+
}
|
|
113
141
|
}
|
|
114
142
|
}
|