zeus-css 1.0.3 → 1.0.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/README.md +7 -13
- package/bin/postinstall.js +13 -0
- package/dist/zeus.css +0 -2
- package/dist/zeus.min.css +1 -1
- package/package.json +14 -20
- package/scss/.stylelintrc.json +41 -0
- package/scss/LICENSE +21 -0
- package/scss/README.md +160 -0
- package/scss/dist/zeus.css +8465 -0
- package/scss/dist/zeus.css.map +1 -0
- package/scss/dist/zeus.min.css +1 -0
- package/scss/dist/zeus.min.css.map +1 -0
- package/scss/package.json +89 -0
- package/scss/scripts/gen-cheatsheet.mjs +178 -0
- package/scss/scripts/gen-tokens.mjs +91 -0
- package/scss/scripts/test-compile.mjs +474 -0
- package/dist/zeus.css.map +0 -1
- package/dist/zeus.min.css.map +0 -1
- /package/{API.md → scss/API.md} +0 -0
- /package/{CHANGELOG.md → scss/CHANGELOG.md} +0 -0
- /package/{cheatsheet.md → scss/cheatsheet.md} +0 -0
- /package/{llms.txt → scss/llms.txt} +0 -0
package/README.md
CHANGED
|
@@ -17,34 +17,30 @@ Import the pre-compiled global foundation (Reset, Variable pipeline, utility cla
|
|
|
17
17
|
import 'zeus-css/dist/zeus.css';
|
|
18
18
|
```
|
|
19
19
|
|
|
20
|
-
### 2.
|
|
21
|
-
|
|
20
|
+
### 2. Generate Your Local Config
|
|
21
|
+
Run the init command in your project root (you'll see a reminder for this after `npm install` too):
|
|
22
22
|
|
|
23
23
|
```bash
|
|
24
24
|
npx zeus-css init
|
|
25
25
|
```
|
|
26
26
|
|
|
27
|
-
This creates
|
|
27
|
+
This creates `zeus.config.scss` and `zeus.customize.scss` directly in your project — not buried in `node_modules` — so you can edit them like any other file. Skip this step only if you're happy with the default theme as-is. Override colors, spacing, fonts, and more using OKLCH:
|
|
28
28
|
|
|
29
29
|
```scss
|
|
30
|
-
// zeus.
|
|
30
|
+
// zeus.config.scss
|
|
31
31
|
$zeus-colors: (
|
|
32
32
|
"primary": oklch(57.9% 0.232 259.6),
|
|
33
33
|
"secondary": oklch(74.7% 0.174 60.6)
|
|
34
34
|
) !default;
|
|
35
|
-
```
|
|
36
|
-
|
|
37
|
-
Then import your local bridge instead of the package directly:
|
|
38
35
|
|
|
39
|
-
|
|
40
|
-
@use "./zeus.scss" as *;
|
|
36
|
+
@forward "zeus-css/scss/zeus.scss";
|
|
41
37
|
```
|
|
42
38
|
|
|
43
39
|
### 3. Use CSS Variables in CSS Modules
|
|
44
|
-
Thanks to the framework's token generation, you can natively use the fluid CSS variables everywhere
|
|
40
|
+
Thanks to the framework's token generation, you can natively use the fluid CSS variables everywhere:
|
|
45
41
|
|
|
46
42
|
```scss
|
|
47
|
-
@use "zeus-css/scss/zeus.scss" as *;
|
|
43
|
+
@use "zeus-css/scss/zeus.scss" as *;
|
|
48
44
|
|
|
49
45
|
.card {
|
|
50
46
|
padding: var(--space-md) var(--space-lg);
|
|
@@ -58,8 +54,6 @@ Thanks to the framework's token generation, you can natively use the fluid CSS v
|
|
|
58
54
|
}
|
|
59
55
|
```
|
|
60
56
|
|
|
61
|
-
> **Note:** Bundlers (Next.js, Vite, webpack `sass-loader`) resolve `zeus-css/...` imports automatically. Compiling with the plain `sass` CLI instead requires `--load-path=node_modules`.
|
|
62
|
-
|
|
63
57
|
## ⚠️ Optimizing for Production (Crucial)
|
|
64
58
|
Zeus CSS ships with thousands of utility classes to give you absolute freedom during development. For production builds, you **must** use PurgeCSS to remove unused selectors and keep your CSS payload tiny.
|
|
65
59
|
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
try {
|
|
3
|
+
if (process.env.CI) {
|
|
4
|
+
process.exit(0);
|
|
5
|
+
}
|
|
6
|
+
console.log('');
|
|
7
|
+
console.log('⚡ Zeus CSS installed.');
|
|
8
|
+
console.log(' Run `npx zeus-css init` to get local zeus.config.scss / zeus.customize.scss files you can edit.');
|
|
9
|
+
console.log(' (Skip this if you only want the default theme via zeus-css/dist/zeus.css.)');
|
|
10
|
+
console.log('');
|
|
11
|
+
} catch (e) {
|
|
12
|
+
// Never fail an install just because the reminder couldn't print.
|
|
13
|
+
}
|