@soli92/solids 1.0.0 → 1.1.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/CHANGELOG.md CHANGED
@@ -1,25 +1,39 @@
1
+ ## [1.1.1](https://github.com/soli92/solids/compare/v1.1.0...v1.1.1) (2026-03-24)
2
+
3
+
4
+ ### Bug Fixes
5
+
6
+ * align GitHub URLs to soli92; deploy Storybook on GitHub Release ([0faeb60](https://github.com/soli92/solids/commit/0faeb60fcfdb0b3e050e3e6e1d4e239e2ec58f0d))
7
+
8
+ # [1.1.0](https://github.com/Soli92/solids/compare/v1.0.0...v1.1.0) (2026-03-24)
9
+
10
+
11
+ ### Features
12
+
13
+ * tailwind preset, shadcn registry [@solids](https://github.com/solids), Storybook button showcase ([2df67ce](https://github.com/Soli92/solids/commit/2df67ce8e1b810348775a717a0a106eac614378f))
14
+
1
15
  # 1.0.0 (2026-03-24)
2
16
 
3
17
 
4
18
  ### Bug Fixes
5
19
 
6
- * **base:** add prefers-color-scheme dark support for color-scheme property ([f055741](https://github.com/Soli92/solids/commit/f0557414b2fe1da5de8e46b7708676cc054f697f))
7
- * **ci:** pass NODE_AUTH_TOKEN for npm auth via setup-node ([9de7228](https://github.com/Soli92/solids/commit/9de72289c35ba69e37e5a7eecf2dd426af63d99f))
8
- * **ci:** upgrade Node to 22 for semantic-release compatibility ([3b0f4c0](https://github.com/Soli92/solids/commit/3b0f4c04e98dfb0ab4f6e3b97445d91c6a27f083))
9
- * **docs:** fix npm package name casing (must be lowercase) + fix import paths ([e51bd71](https://github.com/Soli92/solids/commit/e51bd713618c91e0893529d2570d89663c535ed2))
10
- * **release:** add missing semantic-release core plugins to devDependencies ([8b57869](https://github.com/Soli92/solids/commit/8b57869fdd2e85a3af79cb51c5bcb435b3ad313a))
11
- * **release:** correct semantic-release plugin order (git must be last) ([94d674b](https://github.com/Soli92/solids/commit/94d674b877120fd4c25bc5a42bf771912fe49341))
12
- * **shadcn:** complete truncated dark theme block ([f7e36d9](https://github.com/Soli92/solids/commit/f7e36d99cb19c9278240830f476f8652ebcfd850))
13
- * **tokens:** add missing overlay color in dark theme ([ba011dd](https://github.com/Soli92/solids/commit/ba011ddf5d43c5e77643906a79eda069683586e7))
20
+ * **base:** add prefers-color-scheme dark support for color-scheme property ([f055741](https://github.com/soli92/solids/commit/f0557414b2fe1da5de8e46b7708676cc054f697f))
21
+ * **ci:** pass NODE_AUTH_TOKEN for npm auth via setup-node ([9de7228](https://github.com/soli92/solids/commit/9de72289c35ba69e37e5a7eecf2dd426af63d99f))
22
+ * **ci:** upgrade Node to 22 for semantic-release compatibility ([3b0f4c0](https://github.com/soli92/solids/commit/3b0f4c04e98dfb0ab4f6e3b97445d91c6a27f083))
23
+ * **docs:** fix npm package name casing (must be lowercase) + fix import paths ([e51bd71](https://github.com/soli92/solids/commit/e51bd713618c91e0893529d2570d89663c535ed2))
24
+ * **release:** add missing semantic-release core plugins to devDependencies ([8b57869](https://github.com/soli92/solids/commit/8b57869fdd2e85a3af79cb51c5bcb435b3ad313a))
25
+ * **release:** correct semantic-release plugin order (git must be last) ([94d674b](https://github.com/soli92/solids/commit/94d674b877120fd4c25bc5a42bf771912fe49341))
26
+ * **shadcn:** complete truncated dark theme block ([f7e36d9](https://github.com/soli92/solids/commit/f7e36d99cb19c9278240830f476f8652ebcfd850))
27
+ * **tokens:** add missing overlay color in dark theme ([ba011dd](https://github.com/soli92/solids/commit/ba011ddf5d43c5e77643906a79eda069683586e7))
14
28
 
15
29
 
16
30
  ### Features
17
31
 
18
- * add real utility classes to utilities.css ([34112a4](https://github.com/Soli92/solids/commit/34112a40516f9b1c964af45cbd93aca9e30634a9))
19
- * add shadcn.css export and update package exports ([274256f](https://github.com/Soli92/solids/commit/274256fe21fded1053201d2ad8a6cfe3a50eb47e))
20
- * **css:** add shadcn/ui compatibility layer — maps shadcn vars to SoliDS tokens ([324131b](https://github.com/Soli92/solids/commit/324131b18823edcc71900d840cc3a099159eb129))
21
- * **tokens:** complete dark theme — all semantic overrides for dark mode ([8649ce5](https://github.com/Soli92/solids/commit/8649ce542afa682926d73306d31d732c4985bdca))
22
- * **tokens:** complete light theme — all semantic overrides ([6d5f857](https://github.com/Soli92/solids/commit/6d5f857581a8642da6eab5dcd30c1eb1987d8c4d))
23
- * **tokens:** complete semantic tokens — text, bg, border, intent, interactive ([668d4b0](https://github.com/Soli92/solids/commit/668d4b0b21bf98b624aa33f4a7709937a537d5d6))
24
- * **tokens:** expand base palette — full color scale, typography, shadow, spacing ([06f1499](https://github.com/Soli92/solids/commit/06f1499ccfc003d39c082590048d1484ef24f6af))
25
- * update build script to generate shadcn.css and full CSS variables ([a483dae](https://github.com/Soli92/solids/commit/a483dae64fc1ca97013dfd16124a73ad8609a2cd))
32
+ * add real utility classes to utilities.css ([34112a4](https://github.com/soli92/solids/commit/34112a40516f9b1c964af45cbd93aca9e30634a9))
33
+ * add shadcn.css export and update package exports ([274256f](https://github.com/soli92/solids/commit/274256fe21fded1053201d2ad8a6cfe3a50eb47e))
34
+ * **css:** add shadcn/ui compatibility layer — maps shadcn vars to SoliDS tokens ([324131b](https://github.com/soli92/solids/commit/324131b18823edcc71900d840cc3a099159eb129))
35
+ * **tokens:** complete dark theme — all semantic overrides for dark mode ([8649ce5](https://github.com/soli92/solids/commit/8649ce542afa682926d73306d31d732c4985bdca))
36
+ * **tokens:** complete light theme — all semantic overrides ([6d5f857](https://github.com/soli92/solids/commit/6d5f857581a8642da6eab5dcd30c1eb1987d8c4d))
37
+ * **tokens:** complete semantic tokens — text, bg, border, intent, interactive ([668d4b0](https://github.com/soli92/solids/commit/668d4b0b21bf98b624aa33f4a7709937a537d5d6))
38
+ * **tokens:** expand base palette — full color scale, typography, shadow, spacing ([06f1499](https://github.com/soli92/solids/commit/06f1499ccfc003d39c082590048d1484ef24f6af))
39
+ * update build script to generate shadcn.css and full CSS variables ([a483dae](https://github.com/soli92/solids/commit/a483dae64fc1ca97013dfd16124a73ad8609a2cd))
package/README.md CHANGED
@@ -1,9 +1,11 @@
1
1
  # SoliDS
2
2
 
3
- **SoliDS** è il design system personale di [Soli92](https://github.com/Soli92) —
3
+ **SoliDS** è il design system personale di [soli92](https://github.com/soli92) —
4
4
  una fondamenta **agnostica** basata su **design tokens** e **CSS variables**,
5
5
  pronta all'uso con qualsiasi framework web e compatibile con **shadcn/ui**.
6
6
 
7
+ **Storybook** (docs + esempio Button): dopo ogni release su npm viene pubblicato su GitHub Pages — [soli92.github.io/solids](https://soli92.github.io/solids/) (attiva *Settings → Pages → Source: GitHub Actions* se è la prima volta).
8
+
7
9
  ---
8
10
 
9
11
  ## Cosa include
@@ -32,6 +34,8 @@ npm install @soli92/solids
32
34
 
33
35
  ### Con Tailwind + shadcn/ui (Next.js, Vite…)
34
36
 
37
+ **Consigliato:** usa il **preset Tailwind** del pacchetto così tema, colori shadcn, font e shadow restano allineati ai token in un solo punto.
38
+
35
39
  ```css
36
40
  /* globals.css */
37
41
  @import "@soli92/solids/css/index.css";
@@ -44,33 +48,19 @@ npm install @soli92/solids
44
48
  ```js
45
49
  // tailwind.config.js
46
50
  module.exports = {
47
- darkMode: ["class", '[data-theme="dark"]'],
48
- theme: {
49
- extend: {
50
- colors: {
51
- background: "var(--background)",
52
- foreground: "var(--foreground)",
53
- primary: { DEFAULT: "var(--primary)", foreground: "var(--primary-foreground)" },
54
- secondary: { DEFAULT: "var(--secondary)", foreground: "var(--secondary-foreground)" },
55
- muted: { DEFAULT: "var(--muted)", foreground: "var(--muted-foreground)" },
56
- accent: { DEFAULT: "var(--accent)", foreground: "var(--accent-foreground)" },
57
- destructive: { DEFAULT: "var(--destructive)",foreground: "var(--destructive-foreground)" },
58
- card: { DEFAULT: "var(--card)", foreground: "var(--card-foreground)" },
59
- popover: { DEFAULT: "var(--popover)", foreground: "var(--popover-foreground)" },
60
- border: "var(--border)",
61
- input: "var(--input)",
62
- ring: "var(--ring)",
63
- },
64
- borderRadius: {
65
- lg: "var(--radius)",
66
- md: "calc(var(--radius) - 2px)",
67
- sm: "calc(var(--radius) - 4px)",
68
- },
69
- },
70
- },
51
+ presets: [require("@soli92/solids/tailwind-preset")],
52
+ content: ["./app/**/*.{ts,tsx}", "./components/**/*.{ts,tsx}"],
71
53
  };
72
54
  ```
73
55
 
56
+ Serve anche `tailwindcss-animate` (dipendenza tipica di shadcn):
57
+
58
+ ```bash
59
+ npm install tailwindcss-animate
60
+ ```
61
+
62
+ Poi inizializza shadcn e aggiungi i componenti con la CLI (`npx shadcn@latest init` → `add button`, …). I componenti useranno le variabili `--background`, `--primary`, ecc., già mappate da SoliDS. Un esempio di `components.json` è in [templates/components.json.example](./templates/components.json.example).
63
+
74
64
  ➡️ Guida completa: [docs/shadcn-integration.md](./docs/shadcn-integration.md)
75
65
 
76
66
  ### Senza framework
@@ -93,6 +83,8 @@ import "@soli92/solids/css/base.css"; // solo base
93
83
  import "@soli92/solids/css/utilities.css"; // solo utilities
94
84
  ```
95
85
 
86
+ Preset Tailwind (shadcn): `require("@soli92/solids/tailwind-preset")` nel `tailwind.config`.
87
+
96
88
  ---
97
89
 
98
90
  ## Token Reference
@@ -195,13 +187,33 @@ npm install
195
187
  # Build (genera dist/)
196
188
  npm run build
197
189
 
198
- # Storybook
190
+ # Storybook (build token + Tailwind preview, poi dev server)
199
191
  npm run storybook
200
192
 
201
193
  # Release (semantic-release — solo da CI)
202
194
  npm run release
195
+
196
+ # Registry shadcn (sync src → registry/solids + JSON in registry/r)
197
+ npm run registry:build
203
198
  ```
204
199
 
200
+ Per Storybook, il CSS Tailwind viene precompilato in `.storybook/preview-tw.built.css` (file ignorato da git) dallo script `build:storybook-css`.
201
+
202
+ ---
203
+
204
+ ## Framework UI (progetti personali + shadcn)
205
+
206
+ SoliDS resta **agnostico**: i componenti UI vivono nelle tue app (modello shadcn: codice in repo, non solo in `node_modules`). Il flusso consigliato:
207
+
208
+ 1. **Token e CSS** — `@soli92/solids` (`index.css` + opzionale solo layer).
209
+ 2. **Tailwind** — `presets: [require("@soli92/solids/tailwind-preset")]` + `tailwindcss-animate`.
210
+ 3. **shadcn/ui** — `npx shadcn@latest init` e `add` per ogni blocco (Radix + CVA + le tue classi).
211
+ 4. **Tema** — `data-theme` / `next-themes` come in [docs/shadcn-integration.md](./docs/shadcn-integration.md).
212
+
213
+ In questo repository, **Storybook** include un esempio **Button** in stile shadcn in `src/components/ui/button.tsx` (solo sorgente di riferimento: **non** è incluso nell’artifact npm `dist/`; nei progetti veri aggiungi i componenti con la CLI shadcn).
214
+
215
+ Il **registry shadcn** per il modello 1 è in `registry/` (sorgenti) e `registry/r/` (JSON generati). Guida operativa: [docs/registry-model-1.md](./docs/registry-model-1.md).
216
+
205
217
  ---
206
218
 
207
219
  ## Struttura
@@ -214,18 +226,27 @@ src/
214
226
  │ └── themes/
215
227
  │ ├── light.json # Override tema light
216
228
  │ └── dark.json # Override tema dark
229
+ ├── tailwind/
230
+ │ └── preset.cjs # Preset Tailwind (shadcn + token SD)
231
+ ├── components/ui/ # Esempio shadcn in Storybook
217
232
  ├── css/
218
233
  │ ├── shadcn.css # Compatibility layer shadcn/ui
219
234
  │ ├── base.css # Reset + global styles
220
235
  │ └── utilities.css # Classi utility sd-*
221
236
  scripts/
222
- └── build.mjs # Build script → genera dist/
237
+ ├── build.mjs # Build script → genera dist/
238
+ └── sync-registry.mjs # Copia src → registry/solids (per shadcn build)
239
+ registry/
240
+ │ └── solids/ # Sorgenti registry (sync da src/)
241
+ registry.json # Indice item shadcn (root repo)
242
+ registry/r/ # JSON pubblicati (`npm run registry:build`)
223
243
  docs/
224
- └── shadcn-integration.md # Guida integrazione completa
244
+ ├── shadcn-integration.md # Guida integrazione completa
245
+ └── registry-model-1.md # Modello shadcn in repo + @solids
225
246
  ```
226
247
 
227
248
  ---
228
249
 
229
250
  ## License
230
251
 
231
- MIT © [Soli92](https://github.com/Soli92)
252
+ MIT © [soli92](https://github.com/soli92)
@@ -1,7 +1,7 @@
1
1
  /* ============================================================
2
2
  SoliDS — Utility Classes
3
3
  Lightweight, token-driven utility layer.
4
- Import via: @import "@Soli92/solids/css/index.css"
4
+ Import via: @import "@soli92/solids/css/index.css"
5
5
  ============================================================ */
6
6
 
7
7
  /* ─── Display ────────────────────────────────────────────── */
@@ -0,0 +1,89 @@
1
+ /**
2
+ * SoliDS — Tailwind preset (shadcn/ui + token bridge).
3
+ * Install: tailwindcss, tailwindcss-animate, @soli92/solids.
4
+ * In tailwind.config: presets: [require("@soli92/solids/tailwind-preset")].
5
+ * In globals.css: import SoliDS index.css, then Tailwind layers.
6
+ */
7
+ const { fontFamily } = require("tailwindcss/defaultTheme");
8
+
9
+ /** @type {import("tailwindcss").Config} */
10
+ module.exports = {
11
+ darkMode: ["class", '[data-theme="dark"]'],
12
+ theme: {
13
+ extend: {
14
+ colors: {
15
+ background: "var(--background)",
16
+ foreground: "var(--foreground)",
17
+ card: {
18
+ DEFAULT: "var(--card)",
19
+ foreground: "var(--card-foreground)",
20
+ },
21
+ popover: {
22
+ DEFAULT: "var(--popover)",
23
+ foreground: "var(--popover-foreground)",
24
+ },
25
+ primary: {
26
+ DEFAULT: "var(--primary)",
27
+ foreground: "var(--primary-foreground)",
28
+ },
29
+ secondary: {
30
+ DEFAULT: "var(--secondary)",
31
+ foreground: "var(--secondary-foreground)",
32
+ },
33
+ muted: {
34
+ DEFAULT: "var(--muted)",
35
+ foreground: "var(--muted-foreground)",
36
+ },
37
+ accent: {
38
+ DEFAULT: "var(--accent)",
39
+ foreground: "var(--accent-foreground)",
40
+ },
41
+ destructive: {
42
+ DEFAULT: "var(--destructive)",
43
+ foreground: "var(--destructive-foreground)",
44
+ },
45
+ border: "var(--border)",
46
+ input: "var(--input)",
47
+ ring: "var(--ring)",
48
+ chart: {
49
+ 1: "var(--chart-1)",
50
+ 2: "var(--chart-2)",
51
+ 3: "var(--chart-3)",
52
+ 4: "var(--chart-4)",
53
+ 5: "var(--chart-5)",
54
+ },
55
+ sidebar: {
56
+ DEFAULT: "var(--sidebar)",
57
+ foreground: "var(--sidebar-foreground)",
58
+ primary: "var(--sidebar-primary)",
59
+ "primary-foreground": "var(--sidebar-primary-foreground)",
60
+ accent: "var(--sidebar-accent)",
61
+ "accent-foreground": "var(--sidebar-accent-foreground)",
62
+ border: "var(--sidebar-border)",
63
+ ring: "var(--sidebar-ring)",
64
+ },
65
+ "sd-primary": "var(--sd-color-primary-default)",
66
+ "sd-success": "var(--sd-color-intent-success)",
67
+ "sd-warning": "var(--sd-color-intent-warning)",
68
+ "sd-danger": "var(--sd-color-intent-danger)",
69
+ "sd-info": "var(--sd-color-intent-info)",
70
+ },
71
+ borderRadius: {
72
+ lg: "var(--radius)",
73
+ md: "calc(var(--radius) - 2px)",
74
+ sm: "calc(var(--radius) - 4px)",
75
+ },
76
+ fontFamily: {
77
+ sans: ["var(--sd-font-body)", ...fontFamily.sans],
78
+ mono: ["var(--sd-font-mono)", ...fontFamily.mono],
79
+ },
80
+ boxShadow: {
81
+ sm: "var(--sd-shadow-sm)",
82
+ md: "var(--sd-shadow-md)",
83
+ lg: "var(--sd-shadow-lg)",
84
+ xl: "var(--sd-shadow-xl)",
85
+ },
86
+ },
87
+ },
88
+ plugins: [require("tailwindcss-animate")],
89
+ };
package/package.json CHANGED
@@ -1,15 +1,15 @@
1
1
  {
2
2
  "name": "@soli92/solids",
3
- "version": "1.0.0",
3
+ "version": "1.1.1",
4
4
  "description": "SoliDS – agnostic design system foundations (tokens + CSS) with shadcn/ui compatibility.",
5
5
  "license": "MIT",
6
6
  "repository": {
7
7
  "type": "git",
8
- "url": "git+https://github.com/Soli92/solids.git"
8
+ "url": "git+https://github.com/soli92/solids.git"
9
9
  },
10
- "homepage": "https://github.com/Soli92/solids#readme",
10
+ "homepage": "https://github.com/soli92/solids#readme",
11
11
  "bugs": {
12
- "url": "https://github.com/Soli92/solids/issues"
12
+ "url": "https://github.com/soli92/solids/issues"
13
13
  },
14
14
  "keywords": [
15
15
  "design-system",
@@ -38,7 +38,8 @@
38
38
  "./css/themes.css": "./dist/css/themes.css",
39
39
  "./css/shadcn.css": "./dist/css/shadcn.css",
40
40
  "./css/base.css": "./dist/css/base.css",
41
- "./css/utilities.css": "./dist/css/utilities.css"
41
+ "./css/utilities.css": "./dist/css/utilities.css",
42
+ "./tailwind-preset": "./dist/tailwind/preset.cjs"
42
43
  },
43
44
  "publishConfig": {
44
45
  "access": "public"
@@ -48,10 +49,14 @@
48
49
  "clean": "node -e \"import('node:fs').then(({rmSync})=>rmSync('dist',{recursive:true,force:true}))\"",
49
50
  "prepublishOnly": "npm run build",
50
51
  "release": "semantic-release",
51
- "storybook": "storybook dev -p 6006 --docs",
52
- "build-storybook": "storybook build"
52
+ "build:storybook-css": "tailwindcss -c ./tailwind.config.cjs -i ./.storybook/preview-tw.input.css -o ./.storybook/preview-tw.built.css",
53
+ "storybook": "npm run build && npm run build:storybook-css && storybook dev -p 6006",
54
+ "build-storybook": "npm run build && npm run build:storybook-css && storybook build",
55
+ "registry:sync": "node ./scripts/sync-registry.mjs",
56
+ "registry:build": "node ./scripts/sync-registry.mjs && shadcn build --output ./registry/r"
53
57
  },
54
58
  "devDependencies": {
59
+ "@radix-ui/react-slot": "^1.1.2",
55
60
  "@semantic-release/changelog": "^6.0.0",
56
61
  "@semantic-release/commit-analyzer": "^13.0.0",
57
62
  "@semantic-release/git": "^10.0.0",
@@ -62,7 +67,18 @@
62
67
  "@storybook/addon-essentials": "^8.6.14",
63
68
  "@storybook/blocks": "^8.6.14",
64
69
  "@storybook/react-vite": "^8.6.14",
70
+ "@types/react": "^18.3.18",
71
+ "@types/react-dom": "^18.3.5",
72
+ "autoprefixer": "^10.4.20",
73
+ "class-variance-authority": "^0.7.1",
74
+ "clsx": "^2.1.1",
75
+ "postcss": "^8.4.49",
65
76
  "semantic-release": "^25.0.0",
66
- "storybook": "^8.6.14"
77
+ "shadcn": "^4.1.0",
78
+ "storybook": "^8.6.14",
79
+ "tailwind-merge": "^2.6.0",
80
+ "tailwindcss": "^3.4.17",
81
+ "tailwindcss-animate": "^1.0.7",
82
+ "typescript": "^5.7.2"
67
83
  }
68
84
  }