@bilursag/solidui-tokens 0.0.0-stage → 0.1.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/LICENSE ADDED
@@ -0,0 +1,54 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 bilursag
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
22
+
23
+ -------------------------------------------------------------------------------
24
+ Third-party notices
25
+ -------------------------------------------------------------------------------
26
+
27
+ Plush UI — https://github.com/dominikmartn/plush-ui
28
+ SolidUI's visual language and its spring easing curve are derived from Plush UI.
29
+
30
+ MIT License
31
+
32
+ Copyright (c) 2026 Dominik Martin
33
+
34
+ Permission is hereby granted, free of charge, to any person obtaining a copy
35
+ of this software and associated documentation files (the "Software"), to deal
36
+ in the Software without restriction, including without limitation the rights
37
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
38
+ copies of the Software, and to permit persons to whom the Software is
39
+ furnished to do so, subject to the following conditions:
40
+
41
+ The above copyright notice and this permission notice shall be included in
42
+ all copies or substantial portions of the Software.
43
+
44
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
45
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
46
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
47
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
48
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
49
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
50
+ SOFTWARE.
51
+
52
+ Fonts — Open Runde and Montserrat are licensed under the SIL Open Font
53
+ License 1.1. The license texts ship with @bilursag/solidui-native in assets/fonts/;
54
+ the web packages load them from @fontsource, which includes the same licenses.
package/README.md CHANGED
@@ -1,3 +1,20 @@
1
- # Temporary Holding Version
1
+ # @bilursag/solidui-tokens
2
2
 
3
- This version is a temporary placeholder for this package. An operational version to replace this has been submitted for review and is awaiting a staged release.
3
+ Design tokens for [SolidUI](https://github.com/bilursag/solidui): colors, type scale, radii, control heights, shadows and motion, plus:
4
+
5
+ - `createTheme({ brand })` — derives the brand palette for light and dark from one color.
6
+ - `checkContrast(theme)` — every text/background pair with its WCAG ratio.
7
+ - `themeToCss(theme)` / `nativeVars(theme, scheme)` — output for the web and for NativeWind.
8
+ - `@bilursag/solidui-tokens/web.css` — Tailwind v4 variables, `@theme` and utilities (used by `@bilursag/solidui-react`).
9
+ - `@bilursag/solidui-tokens/tailwind-preset` — Tailwind v3 preset (used by `@bilursag/solidui-native`).
10
+
11
+ ## Theme CLI
12
+
13
+ ```bash
14
+ npx @bilursag/solidui-tokens theme --brand "#0a7d5a" --out solidui-theme.css
15
+ npx @bilursag/solidui-tokens theme --help
16
+ ```
17
+
18
+ Exits with an error if any pair fails WCAG AA (pass `--force` to write it anyway).
19
+
20
+ MIT — see [LICENSE](LICENSE).
package/dist/cli.d.ts ADDED
@@ -0,0 +1,3 @@
1
+ #!/usr/bin/env node
2
+ export {};
3
+ //# sourceMappingURL=cli.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cli.d.ts","sourceRoot":"","sources":["../src/cli.ts"],"names":[],"mappings":""}
package/dist/cli.js ADDED
@@ -0,0 +1,77 @@
1
+ #!/usr/bin/env node
2
+ /**
3
+ * npx @bilursag/solidui-tokens theme --brand "#0a7d5a" [--brand-dark "#…"] [--accent "#…"] [--out theme.css] [--json]
4
+ *
5
+ * Prints (or writes) the CSS variables for a custom theme and checks every
6
+ * text/background pair against WCAG. Exits with 1 if a pair fails (use --force to write anyway).
7
+ */
8
+ import { writeFileSync } from 'node:fs';
9
+ import { parseArgs } from 'node:util';
10
+ import { checkContrast, createTheme, themeToCss } from './index.js';
11
+ const HELP = `SolidUI theme generator
12
+
13
+ Usage:
14
+ npx @bilursag/solidui-tokens theme --brand <hex> [options]
15
+
16
+ Options:
17
+ --brand <hex> Brand color (required). Derives hover, press, tint, ink and focus.
18
+ --brand-dark <hex> Exact brand color for dark mode (default: derived from --brand).
19
+ --accent <hex> Second gradient color (default: a neighbouring hue that keeps on-brand legible).
20
+ --font <stack> CSS font stack for text.
21
+ --heading <stack> CSS font stack for titles.
22
+ --out <file> Write the CSS to a file instead of stdout.
23
+ --json Print the theme as JSON (for @bilursag/solidui-native's ThemeProvider).
24
+ --force Output even if some contrast pairs fail.
25
+ -h, --help Show this help.
26
+ `;
27
+ const { values, positionals } = parseArgs({
28
+ allowPositionals: true,
29
+ options: {
30
+ brand: { type: 'string' },
31
+ 'brand-dark': { type: 'string' },
32
+ accent: { type: 'string' },
33
+ font: { type: 'string' },
34
+ heading: { type: 'string' },
35
+ out: { type: 'string' },
36
+ json: { type: 'boolean' },
37
+ force: { type: 'boolean' },
38
+ help: { type: 'boolean', short: 'h' },
39
+ },
40
+ });
41
+ if (values.help || positionals[0] !== 'theme' || !values.brand) {
42
+ process.stderr.write(HELP);
43
+ process.exit(values.help ? 0 : 1);
44
+ }
45
+ const options = {
46
+ brand: values['brand-dark'] ? { light: values.brand, dark: values['brand-dark'] } : values.brand,
47
+ accent: values.accent,
48
+ fonts: { ...(values.font && { rounded: values.font }), ...(values.heading && { heading: values.heading }) },
49
+ };
50
+ let theme;
51
+ try {
52
+ theme = createTheme(options);
53
+ }
54
+ catch (e) {
55
+ process.stderr.write(`${e.message}\n`);
56
+ process.exit(1);
57
+ }
58
+ const results = checkContrast(theme);
59
+ const failures = results.filter((r) => !r.pass);
60
+ for (const r of failures) {
61
+ process.stderr.write(`✗ ${r.scheme}: ${r.fg} on ${r.bg} = ${r.ratio.toFixed(2)}:1 (needs ${r.min}:1)\n`);
62
+ }
63
+ process.stderr.write(failures.length
64
+ ? `\n${failures.length} of ${results.length} contrast checks failed. Try a darker or more saturated brand color, or pass --force.\n`
65
+ : `✓ ${results.length} contrast checks pass (WCAG AA)\n`);
66
+ if (failures.length && !values.force)
67
+ process.exit(1);
68
+ const header = `/* SolidUI theme — generated by \`npx @bilursag/solidui-tokens theme --brand ${values.brand}\`. Import after @bilursag/solidui-react/styles.css. */\n`;
69
+ const output = values.json ? JSON.stringify(theme, null, 2) + '\n' : header + themeToCss(theme);
70
+ if (values.out) {
71
+ writeFileSync(values.out, output);
72
+ process.stderr.write(`→ ${values.out}\n`);
73
+ }
74
+ else {
75
+ process.stdout.write(output);
76
+ }
77
+ //# sourceMappingURL=cli.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cli.js","sourceRoot":"","sources":["../src/cli.ts"],"names":[],"mappings":";AACA;;;;;GAKG;AACH,OAAO,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AACxC,OAAO,EAAE,SAAS,EAAE,MAAM,WAAW,CAAC;AACtC,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,UAAU,EAAqB,MAAM,YA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gFAAgF,MAAM,CAAC,KAAK,2DAA2D,CAAC;AACvK,MAAM,MAAM,GAAG,MAAM,CAAC,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,SAAS,CAAC,KAAK,EAAE,IAAI,EAAE,CAAC,CAAC,GAAG,IAAI,CAAC,CAAC,CAAC,MAAM,GAAG,UAAU,CAAC,KAAK,CAAC,CAAC;AAChG,IAAI,MAAM,CAAC,GAAG,EAAE,CAAC;IACf,aAAa,CAAC,MAAM,CAAC,GAAG,EAAE,MAAM,CAAC,CAAC;IAClC,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,KAAK,MAAM,CAAC,GAAG,IAAI,CAAC,CAAC;AAC5C,CAAC;KAAM,CAAC;IACN,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC;AAC/B,CAAC"}
@@ -0,0 +1,20 @@
1
+ /** Small color helpers (sRGB, 6-digit hex). No dependencies. */
2
+ export declare const isHex: (v: string) => boolean;
3
+ export declare function toRgb(hex: string): [number, number, number];
4
+ export declare function toHex([r, g, b]: readonly number[]): string;
5
+ /** "r g b" channels, the format NativeWind needs for opacity modifiers (bg-brand/50). */
6
+ export declare const rgbChannels: (hex: string) => string;
7
+ /** Mix `a` toward `b` by `amount` (0 = a, 1 = b). */
8
+ export declare function mix(a: string, b: string, amount: number): string;
9
+ /** WCAG 2.x relative luminance. */
10
+ export declare function luminance(hex: string): number;
11
+ /** WCAG 2.x contrast ratio, 1–21. */
12
+ export declare function contrast(a: string, b: string): number;
13
+ /**
14
+ * Moves `color` toward `target` (usually black or white) in small steps until it
15
+ * reaches `ratio` against every background. Returns the closest it got.
16
+ */
17
+ export declare function shiftUntil(color: string, target: string, backgrounds: string[], ratio: number): string;
18
+ export declare function toHsl(hex: string): [number, number, number];
19
+ export declare function fromHsl(h: number, s: number, l: number): string;
20
+ //# sourceMappingURL=color.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"color.d.ts","sourceRoot":"","sources":["../src/color.ts"],"names":[],"mappings":"AAAA,gEAAgE;AAEhE,eAAO,MAAM,KAAK,GAAI,GAAG,MAAM,YAA8B,CAAC;AAM9D,wBAAgB,KAAK,CAAC,GAAG,EAAE,MAAM,GAAG,CAAC,MAAM,EAAE,MAAM,EAAE,MAAM,CAAC,CAG3D;AAED,wBAAgB,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,EAAE,SAAS,MAAM,EAAE,UAEjD;AAED,yFAAyF;AACzF,eAAO,MAAM,WAAW,GAAI,KAAK,MAAM,WAAyB,CAAC;AAEjE,qDAAqD;AACrD,wBAAgB,GAAG,CAAC,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,UAGvD;AAED,mCAAmC;AACnC,wBAAgB,SAAS,CAAC,GAAG,EAAE,MAAM,UAOpC;AAED,qCAAqC;AACrC,wBAAgB,QAAQ,CAAC,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,MAAM,UAG5C;AAED;;;GAGG;AACH,wBAAgB,UAAU,CAAC,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,WAAW,EAAE,MAAM,EAAE,EAAE,KAAK,EAAE,MAAM,UAM7F;AAED,wBAAgB,KAAK,CAAC,GAAG,EAAE,MAAM,GAAG,CAAC,MAAM,EAAE,MAAM,EAAE,MAAM,CAAC,CAU3D;AAED,wBAAgB,OAAO,CAAC,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,MAAM,UAKtD"}
package/dist/color.js ADDED
@@ -0,0 +1,65 @@
1
+ /** Small color helpers (sRGB, 6-digit hex). No dependencies. */
2
+ export const isHex = (v) => /^#[0-9a-f]{6}$/i.test(v);
3
+ function assertHex(hex) {
4
+ if (!isHex(hex))
5
+ throw new Error(`SolidUI: expected a 6-digit hex color like "#4b48e0", got "${hex}"`);
6
+ }
7
+ export function toRgb(hex) {
8
+ assertHex(hex);
9
+ return [1, 3, 5].map((i) => parseInt(hex.slice(i, i + 2), 16));
10
+ }
11
+ export function toHex([r, g, b]) {
12
+ return '#' + [r, g, b].map((c) => Math.round(Math.min(255, Math.max(0, c))).toString(16).padStart(2, '0')).join('');
13
+ }
14
+ /** "r g b" channels, the format NativeWind needs for opacity modifiers (bg-brand/50). */
15
+ export const rgbChannels = (hex) => toRgb(hex).join(' ');
16
+ /** Mix `a` toward `b` by `amount` (0 = a, 1 = b). */
17
+ export function mix(a, b, amount) {
18
+ const [x, y] = [toRgb(a), toRgb(b)];
19
+ return toHex(x.map((c, i) => c + (y[i] - c) * amount));
20
+ }
21
+ /** WCAG 2.x relative luminance. */
22
+ export function luminance(hex) {
23
+ const f = (c) => {
24
+ const s = c / 255;
25
+ return s <= 0.03928 ? s / 12.92 : ((s + 0.055) / 1.055) ** 2.4;
26
+ };
27
+ const [r, g, b] = toRgb(hex);
28
+ return 0.2126 * f(r) + 0.7152 * f(g) + 0.0722 * f(b);
29
+ }
30
+ /** WCAG 2.x contrast ratio, 1–21. */
31
+ export function contrast(a, b) {
32
+ const [hi, lo] = [luminance(a), luminance(b)].sort((x, y) => y - x);
33
+ return (hi + 0.05) / (lo + 0.05);
34
+ }
35
+ /**
36
+ * Moves `color` toward `target` (usually black or white) in small steps until it
37
+ * reaches `ratio` against every background. Returns the closest it got.
38
+ */
39
+ export function shiftUntil(color, target, backgrounds, ratio) {
40
+ for (let t = 0; t <= 1.0001; t += 0.02) {
41
+ const c = mix(color, target, t);
42
+ if (backgrounds.every((bg) => contrast(c, bg) >= ratio))
43
+ return c;
44
+ }
45
+ return target;
46
+ }
47
+ export function toHsl(hex) {
48
+ const [r, g, b] = toRgb(hex).map((c) => c / 255);
49
+ const max = Math.max(r, g, b);
50
+ const min = Math.min(r, g, b);
51
+ const l = (max + min) / 2;
52
+ if (max === min)
53
+ return [0, 0, l];
54
+ const d = max - min;
55
+ const s = l > 0.5 ? d / (2 - max - min) : d / (max + min);
56
+ const h = max === r ? (g - b) / d + (g < b ? 6 : 0) : max === g ? (b - r) / d + 2 : (r - g) / d + 4;
57
+ return [h * 60, s, l];
58
+ }
59
+ export function fromHsl(h, s, l) {
60
+ const k = (n) => (n + h / 30) % 12;
61
+ const a = s * Math.min(l, 1 - l);
62
+ const f = (n) => l - a * Math.max(-1, Math.min(k(n) - 3, 9 - k(n), 1));
63
+ return toHex([f(0) * 255, f(8) * 255, f(4) * 255]);
64
+ }
65
+ //# sourceMappingURL=color.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"color.js","sourceRoot":"","sources":["../src/color.ts"],"names":[],"mappings":"AAAA,gEAAgE;AAEhE,MAAM,CAAC,MAAM,KAAK,GAAG,CAAC,CAAS,EAAE,EAAE,CAAC,iBAAiB,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;AAE9D,SAAS,SAAS,CAAC,GAAW;IAC5B,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC;QAAE,MAAM,IAAI,KAAK,CAAC,8DAA8D,GAAG,GAAG,CAAC,CAAC;AACzG,CAAC;AAED,MAAM,UAAU,KAAK,CAAC,GAAW;IAC/B,SAAS,CAAC,GAAG,CAAC,CAAC;IACf,OAAO,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,QAAQ,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,GAAG,CAAC,CAAC,EAAE,EAAE,CAAC,CAA6B,CAAC;AAC7F,CAAC;AAED,MAAM,UAAU,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAoB;IAChD,OAAO,GAAG,GAAG,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,GAAG,CAAC,GAAG,EAAE,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,CAAC,CAA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,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC;IAC/E,OAAO,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG,GAAG,EAAE,CAAC,CAAC,CAAC,CAAC,GAAG,GAAG,EAAE,CAAC,CAAC,CAAC,CAAC,GAAG,GAAG,CAAC,CAAC,CAAC;AACrD,CAAC"}
package/dist/css.d.ts ADDED
@@ -0,0 +1,51 @@
1
+ import { type ColorScheme } from './scales.js';
2
+ import { type Theme } from './theme.js';
3
+ export declare const CSS_PREFIX = "--sui-";
4
+ /**
5
+ * The theme's variables for one scheme as a plain object, e.g. for a React `style` prop:
6
+ * <div style={themeVars(createTheme({ brand }), 'light')}>…</div>
7
+ * Lets a page re-brand an area at runtime without generating CSS.
8
+ */
9
+ export declare function themeVars(theme: Theme, scheme: ColorScheme): Record<string, string>;
10
+ /**
11
+ * Only the variables that change between themes: colors, gradient, shadows and fonts.
12
+ * Import it after `@bilursag/solidui-react/styles.css` to re-brand the components.
13
+ * `.dark` / `.light` match the classes the components already respond to.
14
+ */
15
+ export declare function themeToCss(theme: Theme): string;
16
+ /** The complete Tailwind v4 stylesheet: theme variables + @theme + utilities. */
17
+ export declare function webCss(theme?: Theme): string;
18
+ /**
19
+ * Variables for NativeWind's `vars()`: `{ '--sui-brand': '75 72 224', … }`.
20
+ * Only hex colors: NativeWind needs RGB channels for opacity modifiers (bg-brand/50).
21
+ */
22
+ export declare function nativeVars(theme: Theme, scheme: ColorScheme): Record<string, string>;
23
+ /** Tailwind v3 preset for NativeWind: colors → variables, radii, heights, fonts and the type scale. */
24
+ export declare function tailwindPreset(): {
25
+ theme: {
26
+ extend: {
27
+ colors: {
28
+ [k: string]: string;
29
+ };
30
+ borderRadius: {
31
+ [k: string]: string;
32
+ };
33
+ spacing: {
34
+ [k: string]: string;
35
+ };
36
+ fontFamily: {
37
+ heading: "Montserrat-Bold"[];
38
+ rounded: "OpenRunde-Medium"[];
39
+ };
40
+ letterSpacing: {
41
+ heading: "-0.02em";
42
+ };
43
+ fontSize: {
44
+ [k: string]: (string | {
45
+ lineHeight: string;
46
+ })[];
47
+ };
48
+ };
49
+ };
50
+ };
51
+ //# sourceMappingURL=css.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"css.d.ts","sourceRoot":"","sources":["../src/css.ts"],"names":[],"mappings":"AAMA,OAAO,EAAyC,KAAK,WAAW,EAAE,MAAM,aAAa,CAAC;AACtF,OAAO,EAA4B,KAAK,KAAK,EAAE,MAAM,YAAY,CAAC;AAElE,eAAO,MAAM,UAAU,WAAW,CAAC;AAEnC;;;;GAIG;AACH,wBAAgB,SAAS,CAAC,KAAK,EAAE,KAAK,EAAE,MAAM,EAAE,WAAW,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAQnF;AAMD;;;;GAIG;AACH,wBAAgB,UAAU,CAAC,KAAK,EAAE,KAAK,UAiBtC;AAED,iFAAiF;AACjF,wBAAgB,MAAM,CAAC,KAAK,GAAE,KAAoB,UA2DjD;AAED;;;GAGG;AACH,wBAAgB,UAAU,CAAC,KAAK,EAAE,KAAK,EAAE,MAAM,EAAE,WAAW,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAGpF;AAED,uGAAuG;AACvG,wBAAgB,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;EAyB7B"}
package/dist/css.js ADDED
@@ -0,0 +1,137 @@
1
+ /**
2
+ * Turns a theme into what each platform consumes:
3
+ * - Web (Tailwind v4): CSS variables (`--sui-*`) + an `@theme inline` block + utilities.
4
+ * - Native (NativeWind / Tailwind v3): "r g b" variables + a Tailwind preset.
5
+ */
6
+ import { isHex, rgbChannels } from './color.js';
7
+ import { font, motion, radius, size, typeScale } from './scales.js';
8
+ import { colorNames, defaultTheme } from './theme.js';
9
+ export const CSS_PREFIX = '--sui-';
10
+ /**
11
+ * The theme's variables for one scheme as a plain object, e.g. for a React `style` prop:
12
+ * <div style={themeVars(createTheme({ brand }), 'light')}>…</div>
13
+ * Lets a page re-brand an area at runtime without generating CSS.
14
+ */
15
+ export function themeVars(theme, scheme) {
16
+ const c = theme.colors[scheme];
17
+ const [a, b] = theme.gradients[scheme].brand;
18
+ return {
19
+ ...Object.fromEntries(colorNames.map((n) => [`${CSS_PREFIX}${n}`, c[n]])),
20
+ [`${CSS_PREFIX}brand-gradient`]: `linear-gradient(135deg, ${a}, ${b})`,
21
+ ...Object.fromEntries(Object.entries(theme.shadows[scheme]).map(([k, v]) => [`${CSS_PREFIX}shadow-${k}`, v])),
22
+ };
23
+ }
24
+ function schemeVars(theme, scheme, indent = ' ') {
25
+ return Object.entries(themeVars(theme, scheme)).map(([k, v]) => `${indent}${k}: ${v};`).join('\n');
26
+ }
27
+ /**
28
+ * Only the variables that change between themes: colors, gradient, shadows and fonts.
29
+ * Import it after `@bilursag/solidui-react/styles.css` to re-brand the components.
30
+ * `.dark` / `.light` match the classes the components already respond to.
31
+ */
32
+ export function themeToCss(theme) {
33
+ return `:root {
34
+ ${schemeVars(theme, 'light')}
35
+ ${CSS_PREFIX}font-rounded: ${theme.fonts.rounded};
36
+ ${CSS_PREFIX}font-heading: ${theme.fonts.heading};
37
+ }
38
+
39
+ .dark {
40
+ ${schemeVars(theme, 'dark')}
41
+ }
42
+
43
+ /* Forces the light scheme inside a dark page (side-by-side previews, for instance).
44
+ It comes after .dark so it wins when nested. */
45
+ .light {
46
+ ${schemeVars(theme, 'light')}
47
+ }
48
+ `;
49
+ }
50
+ /** The complete Tailwind v4 stylesheet: theme variables + @theme + utilities. */
51
+ export function webCss(theme = defaultTheme) {
52
+ return `${themeToCss(theme).replace(':root {\n', `:root {
53
+ ${CSS_PREFIX}tracking-heading: ${font.headingTracking};
54
+ ${CSS_PREFIX}ease-spring: ${motion.easeSpring};
55
+ ${CSS_PREFIX}ease-fade: ${motion.easeFade};
56
+ ${CSS_PREFIX}dur-fast: ${motion.durationFast}ms;
57
+ ${CSS_PREFIX}dur-fade: ${motion.durationFade}ms;
58
+ ${CSS_PREFIX}dur-spring: ${motion.durationSpring}ms;
59
+ ${CSS_PREFIX}press-pill: ${motion.pressScale.pill};
60
+ ${CSS_PREFIX}press-icon: ${motion.pressScale.icon};
61
+ `)}
62
+ @media (prefers-reduced-motion: reduce) {
63
+ :root { ${CSS_PREFIX}dur-spring: 0ms; ${CSS_PREFIX}dur-fade: 0ms; ${CSS_PREFIX}dur-fast: 0ms; }
64
+ }
65
+
66
+ @theme inline {
67
+ ${colorNames.map((n) => ` --color-${n}: var(${CSS_PREFIX}${n});`).join('\n')}
68
+ ${Object.entries(radius).map(([k, v]) => ` --radius-${k}: ${v}px;`).join('\n')}
69
+ ${Object.entries(size).map(([k, v]) => ` --spacing-${k}: ${v}px;`).join('\n')}
70
+ --shadow-soft: var(${CSS_PREFIX}shadow-soft);
71
+ --shadow-raised: var(${CSS_PREFIX}shadow-raised);
72
+ --shadow-overlay: var(${CSS_PREFIX}shadow-overlay);
73
+ --font-rounded: var(${CSS_PREFIX}font-rounded);
74
+ --font-heading: var(${CSS_PREFIX}font-heading);
75
+ --tracking-heading: var(${CSS_PREFIX}tracking-heading);
76
+ ${Object.entries(typeScale)
77
+ .map(([k, t]) => [
78
+ ` --text-${k}: ${t.size}px;`,
79
+ ` --text-${k}--line-height: ${t.lineHeight}px;`,
80
+ 'tracking' in t ? ` --text-${k}--letter-spacing: var(${CSS_PREFIX}tracking-heading);` : '',
81
+ ].filter(Boolean).join('\n'))
82
+ .join('\n')}
83
+ --ease-spring: var(${CSS_PREFIX}ease-spring);
84
+ --ease-fade: var(${CSS_PREFIX}ease-fade);
85
+ }
86
+
87
+ @utility bg-brand-gradient {
88
+ background-image: var(${CSS_PREFIX}brand-gradient);
89
+ }
90
+
91
+ @utility focus-ring {
92
+ outline: 2px solid var(${CSS_PREFIX}focus);
93
+ outline-offset: 2px;
94
+ }
95
+
96
+ @utility press-spring {
97
+ transition:
98
+ scale var(${CSS_PREFIX}dur-spring) var(${CSS_PREFIX}ease-spring),
99
+ background-color var(${CSS_PREFIX}dur-fast) var(${CSS_PREFIX}ease-fade),
100
+ box-shadow var(${CSS_PREFIX}dur-fast) var(${CSS_PREFIX}ease-fade),
101
+ color var(${CSS_PREFIX}dur-fast) var(${CSS_PREFIX}ease-fade),
102
+ opacity var(${CSS_PREFIX}dur-fade) var(${CSS_PREFIX}ease-fade);
103
+ }
104
+ `;
105
+ }
106
+ /**
107
+ * Variables for NativeWind's `vars()`: `{ '--sui-brand': '75 72 224', … }`.
108
+ * Only hex colors: NativeWind needs RGB channels for opacity modifiers (bg-brand/50).
109
+ */
110
+ export function nativeVars(theme, scheme) {
111
+ const c = theme.colors[scheme];
112
+ return Object.fromEntries(colorNames.filter((n) => isHex(c[n])).map((n) => [`${CSS_PREFIX}${n}`, rgbChannels(c[n])]));
113
+ }
114
+ /** Tailwind v3 preset for NativeWind: colors → variables, radii, heights, fonts and the type scale. */
115
+ export function tailwindPreset() {
116
+ const c = defaultTheme.colors.light;
117
+ return {
118
+ theme: {
119
+ extend: {
120
+ colors: Object.fromEntries(colorNames.filter((n) => isHex(c[n])).map((n) => [n, `rgb(var(${CSS_PREFIX}${n}) / <alpha-value>)`])),
121
+ borderRadius: Object.fromEntries(Object.entries(radius).map(([k, v]) => [k, `${v}px`])),
122
+ spacing: Object.fromEntries(Object.entries(size).map(([k, v]) => [k, `${v}px`])),
123
+ fontFamily: {
124
+ rounded: [font.native.rounded.medium],
125
+ ...Object.fromEntries(Object.entries(font.native.rounded).map(([w, f]) => [`rounded-${w}`, [f]])),
126
+ heading: [font.native.heading.bold],
127
+ ...Object.fromEntries(Object.entries(font.native.heading).map(([w, f]) => [`heading-${w}`, [f]])),
128
+ },
129
+ letterSpacing: { heading: font.headingTracking },
130
+ // Size + line height in px. Title tracking goes through the
131
+ // tracking-heading class (in <Text>), not here.
132
+ fontSize: Object.fromEntries(Object.entries(typeScale).map(([k, t]) => [k, [`${t.size}px`, { lineHeight: `${t.lineHeight}px` }]])),
133
+ },
134
+ },
135
+ };
136
+ }
137
+ //# sourceMappingURL=css.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"css.js","sourceRoot":"","sources":["../src/css.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,OAAO,EAAE,KAAK,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAChD,OAAO,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,EAAE,IAAI,EAAE,SAAS,EAAoB,MAAM,aAAa,CAAC;AACtF,OAAO,EAAE,UAAU,EAAE,YAAY,EAAc,MAAM,YAAY,CAAC;AAElE,MAAM,CAAC,MAAM,UAAU,GAAG,QAAQ,CAAC;AAEnC;;;;GAIG;AACH,MAAM,UAAU,SAAS,CAAC,KAAY,EAAE,MAAmB;IACzD,MAAM,CAAC,GAAG,KAAK,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC;IAC/B,MAAM,CAAC,CAAC,EAAE,CAAC,CAAC,GAAG,KAAK,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC,KAAK,CAAC;IAC7C,OAAO;QACL,GAAG,MAAM,CAAC,WAAW,CAAC,UAAU,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,GAAG,UAAU,GAAG,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QACzE,CAAC,GAAG,UAAU,gBAAgB,CAAC,EAAE,2BAA2B,CAAC,KAAK,CAAC,GAAG;QACtE,GAAG,MAAM,CAAC,WAAW,CAAC,MAAM,CAAC,OAAO,CAAC,KAAK,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,GAAG,UAAU,UAAU,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,CAAC;KAC9G,CAAC;AACJ,CAAC;AAED,SAAS,UA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CAAC;oBACrC,GAAG,MAAM,CAAC,WAAW,CAAC,MAAM,CAAC,OAAO,CAAC,IAAI,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,WAAW,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;oBACjG,OAAO,EAAE,CAAC,IAAI,CAAC,MAAM,CAAC,OAAO,CAAC,IAAI,CAAC;oBACnC,GAAG,MAAM,CAAC,WAAW,CAAC,MAAM,CAAC,OAAO,CAAC,IAAI,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,WAAW,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;iBAClG;gBACD,aAAa,EAAE,EAAE,OAAO,EAAE,IAAI,CAAC,eAAe,EAAE;gBAChD,4DAA4D;gBAC5D,gDAAgD;gBAChD,QAAQ,EAAE,MAAM,CAAC,WAAW,CAC1B,MAAM,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC,GAAG,CAAC,CAAC,IAAI,IAAI,EAAE,EAAE,UAAU,EAAE,GAAG,CAAC,CAAC,UAAU,IAAI,EAAE,CAAC,CAAC,CAAC,CACrG;aACF;SACF;KACF,CAAC;AACJ,CAAC"}
@@ -0,0 +1,13 @@
1
+ /**
2
+ * SolidUI design tokens — the single source of truth for @bilursag/solidui-react (web)
3
+ * and @bilursag/solidui-native (React Native).
4
+ *
5
+ * Look and feel inspired by Plush UI (https://plush-ui.pages.dev, MIT): light
6
+ * surfaces with soft shadows instead of borders, pill-shaped controls, rounded
7
+ * type and spring motion.
8
+ */
9
+ export * from './scales.js';
10
+ export * from './color.js';
11
+ export * from './theme.js';
12
+ export * from './css.js';
13
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AACH,cAAc,aAAa,CAAC;AAC5B,cAAc,YAAY,CAAC;AAC3B,cAAc,YAAY,CAAC;AAC3B,cAAc,UAAU,CAAC"}
package/dist/index.js ADDED
@@ -0,0 +1,13 @@
1
+ /**
2
+ * SolidUI design tokens — the single source of truth for @bilursag/solidui-react (web)
3
+ * and @bilursag/solidui-native (React Native).
4
+ *
5
+ * Look and feel inspired by Plush UI (https://plush-ui.pages.dev, MIT): light
6
+ * surfaces with soft shadows instead of borders, pill-shaped controls, rounded
7
+ * type and spring motion.
8
+ */
9
+ export * from './scales.js';
10
+ export * from './color.js';
11
+ export * from './theme.js';
12
+ export * from './css.js';
13
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AACH,cAAc,aAAa,CAAC;AAC5B,cAAc,YAAY,CAAC;AAC3B,cAAc,YAAY,CAAC;AAC3B,cAAc,UAAU,CAAC"}