fractalstyler2 0.1.0 → 0.4.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/README.md +61 -59
- package/dist/cli.js +47 -9
- package/dist/index.d.ts +32 -1
- package/dist/index.js +73 -4
- package/dist/mcp/export.d.ts +13 -0
- package/dist/mcp/export.js +76 -0
- package/dist/mcp/schemas/compile_fractals.json +20 -0
- package/dist/mcp/schemas/css_to_fractals.json +16 -0
- package/dist/mcp/schemas/generate_component.json +45 -0
- package/dist/mcp/schemas/get_design_tokens.json +23 -0
- package/dist/mcp/schemas/instructions.md +18 -0
- package/dist/mcp/schemas/list_fractals.json +20 -0
- package/dist/mcp/schemas/snap_to_tokens.json +25 -0
- package/dist/mcp/schemas/validate_recipe.json +16 -0
- package/dist/mcp/server.js +28 -12
- package/dist/styles/{_tokens.sass → _00_tokens.sass} +75 -64
- package/dist/styles/{_config.sass → _01_config.sass} +28 -36
- package/dist/styles/_02_fonts.sass +13 -0
- package/dist/styles/_03_responsive.sass +31 -0
- package/dist/styles/{_atoms.sass → _04_atoms.sass} +4 -4
- package/{templates/_molecules.sass → dist/styles/_05_molecules.sass} +16 -12
- package/dist/styles/_06_recipes.sass +189 -0
- package/dist/styles/{_base.sass → _07_base.sass} +3 -2
- package/dist/styles/_08_blocks.sass +433 -0
- package/dist/styles/_09_utilities.sass +208 -0
- package/dist/styles/_10_layouts.sass +373 -0
- package/dist/styles/_11_own.sass +21 -0
- package/dist/styles/_fractals.sass +7 -6
- package/dist/styles/index.sass +14 -16
- package/mcp.json +11 -0
- package/package.json +6 -3
- package/plugin.json +22 -0
- package/skills/fractal-styler/SKILL.md +83 -0
- package/skills/fractal-styler/references/fractals.md +28 -0
- package/skills/fractal-styler/references/tokens.md +36 -0
- package/skills/style-migration/SKILL.md +45 -0
- package/templates/{_tokens.sass → _00_tokens.sass} +73 -64
- package/templates/{_config.sass → _01_config.sass} +24 -36
- package/templates/_02_fonts.sass +13 -0
- package/templates/_03_responsive.sass +31 -0
- package/templates/{_atoms.sass → _04_atoms.sass} +4 -4
- package/{dist/styles/_molecules.sass → templates/_05_molecules.sass} +16 -12
- package/templates/_06_recipes.sass +189 -0
- package/templates/{_base.sass → _07_base.sass} +3 -2
- package/templates/_08_blocks.sass +433 -0
- package/templates/_09_utilities.sass +207 -0
- package/templates/_10_layouts.sass +373 -0
- package/templates/_11_own.sass +21 -0
- package/templates/_fractals.sass +7 -6
- package/templates/index.sass +14 -16
- package/dist/styles/_blocks.sass +0 -88
- package/dist/styles/_layouts.sass +0 -108
- package/dist/styles/_responsive.sass +0 -43
- package/dist/styles/_utilities.sass +0 -125
- package/templates/_blocks.sass +0 -88
- package/templates/_layouts.sass +0 -108
- package/templates/_responsive.sass +0 -43
- package/templates/_utilities.sass +0 -125
|
@@ -1,125 +0,0 @@
|
|
|
1
|
-
// =============================================================================
|
|
2
|
-
// UTILITY PROJECTION — the *other* way to consume a fractal.
|
|
3
|
-
// -----------------------------------------------------------------------------
|
|
4
|
-
// A fractal is a mixin. Here we bind a subset of them to class names so they
|
|
5
|
-
// stay usable straight from markup (`class="box gap-m pad-l"`). This is the
|
|
6
|
-
// key idea: utility classes are not a separate system — they are a generated
|
|
7
|
-
// projection of the exact same fractals your components compose. Emit only the
|
|
8
|
-
// atoms you want in markup; delete this whole file if you go SASS-only.
|
|
9
|
-
// =============================================================================
|
|
10
|
-
|
|
11
|
-
@use 'config' as *
|
|
12
|
-
@use 'atoms' as *
|
|
13
|
-
@use 'molecules' as *
|
|
14
|
-
@use 'responsive' as *
|
|
15
|
-
|
|
16
|
-
// --- Flow ------------------------------------------------------------------
|
|
17
|
-
.box
|
|
18
|
-
+box
|
|
19
|
-
.row
|
|
20
|
-
+row
|
|
21
|
-
&.wrap
|
|
22
|
-
+wrap
|
|
23
|
-
|
|
24
|
-
// Alignment modifiers, semantic and axis-aware.
|
|
25
|
-
.box
|
|
26
|
-
&.xcenter
|
|
27
|
-
align-items: center
|
|
28
|
-
&.xleft
|
|
29
|
-
align-items: flex-start
|
|
30
|
-
&.xright
|
|
31
|
-
align-items: flex-end
|
|
32
|
-
&.ycenter
|
|
33
|
-
justify-content: center
|
|
34
|
-
&.ytop
|
|
35
|
-
justify-content: flex-start
|
|
36
|
-
&.ybot
|
|
37
|
-
justify-content: flex-end
|
|
38
|
-
|
|
39
|
-
.row
|
|
40
|
-
&.ycenter
|
|
41
|
-
align-items: center
|
|
42
|
-
&.ytop
|
|
43
|
-
align-items: flex-start
|
|
44
|
-
&.ybot
|
|
45
|
-
align-items: flex-end
|
|
46
|
-
&.xbetween
|
|
47
|
-
justify-content: space-between
|
|
48
|
-
&.xevenly
|
|
49
|
-
justify-content: space-evenly
|
|
50
|
-
&.xleft
|
|
51
|
-
justify-content: flex-start
|
|
52
|
-
&.xright
|
|
53
|
-
justify-content: flex-end
|
|
54
|
-
|
|
55
|
-
// Fixed column grids.
|
|
56
|
-
@for $n from 1 through 6
|
|
57
|
-
.grid-cols-#{$n}
|
|
58
|
-
+grid($n)
|
|
59
|
-
|
|
60
|
-
.center
|
|
61
|
-
+center
|
|
62
|
-
|
|
63
|
-
// --- Spacing scale → gap-* / pad-* -----------------------------------------
|
|
64
|
-
@each $s in $space-steps
|
|
65
|
-
.gap-#{$s}
|
|
66
|
-
+gap($s)
|
|
67
|
-
.pad-#{$s}
|
|
68
|
-
+pad($s)
|
|
69
|
-
.px-#{$s}
|
|
70
|
-
+px($s)
|
|
71
|
-
.py-#{$s}
|
|
72
|
-
+py($s)
|
|
73
|
-
|
|
74
|
-
// --- Radius / shadow / surface ---------------------------------------------
|
|
75
|
-
@each $r in $radius-steps
|
|
76
|
-
.radius-#{$r}
|
|
77
|
-
+radius($r)
|
|
78
|
-
|
|
79
|
-
@each $s in $shadow-steps
|
|
80
|
-
.shadow-#{$s}
|
|
81
|
-
+shadow($s)
|
|
82
|
-
|
|
83
|
-
@each $role in $surface-roles
|
|
84
|
-
.bg-#{$role}
|
|
85
|
-
+bg($role)
|
|
86
|
-
|
|
87
|
-
.border
|
|
88
|
-
+border
|
|
89
|
-
@each $side in top right bottom left
|
|
90
|
-
.border-#{$side}
|
|
91
|
-
+border($side)
|
|
92
|
-
|
|
93
|
-
// --- Type ------------------------------------------------------------------
|
|
94
|
-
@each $t in $text-steps
|
|
95
|
-
.text-#{$t}
|
|
96
|
-
+type($t)
|
|
97
|
-
|
|
98
|
-
.truncate
|
|
99
|
-
+truncate
|
|
100
|
-
|
|
101
|
-
// Semantic type primitives — so you stop retyping `.text-sm .lh15 .muted`.
|
|
102
|
-
.body
|
|
103
|
-
+type(md)
|
|
104
|
-
+leading(1.6)
|
|
105
|
-
+ink(primary)
|
|
106
|
-
.muted
|
|
107
|
-
+ink(secondary)
|
|
108
|
-
.eyebrow
|
|
109
|
-
+type(sm)
|
|
110
|
-
+ink(muted)
|
|
111
|
-
text-transform: uppercase
|
|
112
|
-
letter-spacing: 0.06em
|
|
113
|
-
font-weight: 500
|
|
114
|
-
|
|
115
|
-
// --- Sizing shortcuts ------------------------------------------------------
|
|
116
|
-
.wfull
|
|
117
|
-
+w(100%)
|
|
118
|
-
.hfull
|
|
119
|
-
+h(100%)
|
|
120
|
-
.full
|
|
121
|
-
+full
|
|
122
|
-
.grow
|
|
123
|
-
+grow
|
|
124
|
-
.min0
|
|
125
|
-
+min0
|