@splendidlabz/styles 4.11.0 → 4.13.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.
Files changed (38) hide show
  1. package/README.md +86 -0
  2. package/package.json +12 -6
  3. package/src/base.css +15 -0
  4. package/src/components/astro/fancylist.css +22 -24
  5. package/src/components/bundle-astro.css +7 -0
  6. package/src/components/bundle-svelte.css +7 -0
  7. package/src/components/css/button.css +40 -0
  8. package/src/components/css/card.css +9 -0
  9. package/src/{form → components/css/forms}/index.css +0 -1
  10. package/src/components/css/index.css +2 -0
  11. package/src/components/svelte/tabs.css +169 -28
  12. package/src/effects/bundle.css +5 -0
  13. package/src/effects/index.css +2 -0
  14. package/src/generic/anchors-and-buttons.css +3 -40
  15. package/src/generic/form.css +11 -0
  16. package/src/layouts/bundle.css +5 -0
  17. package/src/layouts/index.css +1 -1
  18. package/src/styles.css +9 -6
  19. package/src/theming.css +7 -0
  20. package/src/tools/object.css +6 -1
  21. package/src/utilities.css +11 -0
  22. package/dist/no-tw/layouts.css +0 -1895
  23. package/dist/no-tw/styles.css +0 -3094
  24. package/src/effects/testgb.css +0 -372
  25. package/src/form/textarea.css +0 -38
  26. /package/src/{form → components/css/forms}/checkbox-and-radio.css +0 -0
  27. /package/src/{form → components/css/forms}/input.css +0 -0
  28. /package/src/{form → components/css/forms}/select.css +0 -0
  29. /package/src/{type → components/css/typography}/font-position.css +0 -0
  30. /package/src/{type → components/css/typography}/font.css +0 -0
  31. /package/src/{type → components/css/typography}/index.css +0 -0
  32. /package/src/{type → components/css/typography}/text-edge.css +0 -0
  33. /package/src/{type → components/css/typography}/text-relative.css +0 -0
  34. /package/src/{animation → effects/animation}/animation.css +0 -0
  35. /package/src/{animation → effects/animation}/fly.css +0 -0
  36. /package/src/{animation → effects/animation}/index.css +0 -0
  37. /package/src/{transitions → effects/transitions}/index.css +0 -0
  38. /package/src/{transitions → effects/transitions}/starting-style.css +0 -0
package/README.md ADDED
@@ -0,0 +1,86 @@
1
+ # @splendidlabz/styles
2
+
3
+ Splendid Labz styles for Tailwind CSS v4.
4
+
5
+ ## Install
6
+
7
+ ```bash
8
+ npm install @splendidlabz/styles
9
+ ```
10
+
11
+ ## The quickest way — everything
12
+
13
+ ```css
14
+ @import 'tailwindcss';
15
+ @import '@splendidlabz/styles';
16
+ ```
17
+
18
+ That's the whole system: reset, theme, styled HTML, utilities, and the CSS components (`prose`, `card`, `table`, and friends). Tailwind tree-shakes whatever you don't use, so most projects want this and nothing else.
19
+
20
+ ## Keep your own reset — just the classes
21
+
22
+ Already have your own reset and base styles? Take Splendid's utilities and components without letting it touch your HTML:
23
+
24
+ ```css
25
+ @import 'tailwindcss';
26
+ @import '@splendidlabz/styles/utilities';
27
+ @import '@splendidlabz/styles/components/css';
28
+ ```
29
+
30
+ `utilities` is the same utility classes as above with no reset and no element styling. `components/css` adds the opt-in component classes. Nothing renders differently until you reach for a class.
31
+
32
+ ## Using Splendid's Astro or Svelte components
33
+
34
+ If you're pulling in components from `@splendidlabz/astro` or `@splendidlabz/svelte`, there are two extra things to wire up:
35
+
36
+ ```css
37
+ /* 1. Point Tailwind at the packages so it scans their class names —
38
+ they live in node_modules, which Tailwind skips by default. */
39
+ @source "../node_modules/@splendidlabz/astro";
40
+ @source "../node_modules/@splendidlabz/svelte";
41
+
42
+ @import 'tailwindcss';
43
+
44
+ /* 2. A base + the framework component styles. */
45
+ @import '@splendidlabz/styles/base';
46
+ @import '@splendidlabz/styles/components/astro'; /* or /components/svelte */
47
+ ```
48
+
49
+ Use `base`, not the full `@splendidlabz/styles`. The full import already carries the CSS components, and `/components/astro` brings them along too — so pairing them gives you two copies. `base` is the reset and styling *without* the components, and the framework layer fills them in once.
50
+
51
+ ## Without Tailwind's preflight
52
+
53
+ Splendid ships its own reset, so you can drop Tailwind's. Import Tailwind's theme and utilities on their own instead of the whole thing, and set the layer order so Splendid's reset lands first:
54
+
55
+ ```css
56
+ @layer reset, theme, base, components, utilities;
57
+
58
+ @import 'tailwindcss/theme.css' layer(theme);
59
+ @import 'tailwindcss/utilities.css' layer(utilities);
60
+
61
+ @import '@splendidlabz/styles';
62
+ ```
63
+
64
+ Everything else works the same — this just replaces `@import 'tailwindcss'`.
65
+
66
+ ## Two things that'll bite you
67
+
68
+ - **One base at a time.** `@splendidlabz/styles`, `base`, and `utilities` all overlap. Import two of them and you get two copies of the shared parts — Tailwind v4 doesn't merge repeated imports. Pick one.
69
+ - **Component layers need a base under them.** `components/css`, `components/astro`, and `components/svelte` can't stand alone — on their own they have nothing to resolve against and the build fails. Any of the three bases covers them; import order doesn't matter.
70
+
71
+ ## Every entry point
72
+
73
+ | Import | What you get |
74
+ | ---------------------- | ---------------------------------------------------------- |
75
+ | `@splendidlabz/styles` | Everything — reset, styled HTML, utilities, CSS components |
76
+ | `…/base` | Reset, styled HTML, utilities — no components |
77
+ | `…/utilities` | Utilities only — leaves your HTML alone |
78
+ | `…/components/css` | CSS component classes (`prose`, `card`, …) |
79
+ | `…/components/astro` | Astro component styles (includes CSS components) |
80
+ | `…/components/svelte` | Svelte component styles (includes CSS components) |
81
+ | `…/components` | All component styles — css, astro, svelte |
82
+ | `…/layouts` | Layout utilities (already in every base) |
83
+ | `…/effects` | Effects, animation, transitions (already in every base) |
84
+ | `…/tools` | The `@apply` / `@variant` helpers |
85
+ | `…/theming` | `@theme` tokens plus color/pigment |
86
+ | `…/variables` | `@theme` tokens on their own |
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@splendidlabz/styles",
3
- "version": "4.11.0",
3
+ "version": "4.13.0",
4
4
  "description": "",
5
5
  "type": "module",
6
6
  "homepage": "https://splendidlabz.com/docs/styles",
@@ -12,18 +12,24 @@
12
12
  ],
13
13
  "exports": {
14
14
  ".": "./src/styles.css",
15
+ "./base": "./src/base.css",
16
+ "./utilities": "./src/utilities.css",
17
+ "./tools": "./src/tools/index.css",
18
+ "./layouts": "./src/layouts/bundle.css",
19
+ "./effects": "./src/effects/bundle.css",
20
+ "./variables": "./src/variables/index.css",
21
+ "./theming": "./src/theming.css",
15
22
  "./components": "./src/components/index.css",
16
- "./layouts": "./src/layouts/direct.css",
23
+ "./components/css": "./src/components/css/index.css",
24
+ "./components/astro": "./src/components/bundle-astro.css",
25
+ "./components/svelte": "./src/components/bundle-svelte.css",
17
26
  "./pigment": "./src/tools/pigment.css",
18
27
  "./scripts": "./scripts/index.js",
19
28
  "./scripts/*": "./scripts/*.js"
20
29
  },
21
30
  "scripts": {
22
31
  "lint": "stylelint '**/*.{css,scss}' --fix",
23
- "lightning": "lightningcss --bundle --targets \">= 0.25%\" ./src/styles.css -o dist/styles.css",
24
- "build-styles": "npx @tailwindcss/cli -i ./no-tailwind/index.css -o ./dist/no-tw/styles.css",
25
- "build-layouts": "npx @tailwindcss/cli -i ./no-tailwind/layouts.css -o ./dist/no-tw/layouts.css",
26
- "build": "npm run build-styles & npm run build-layouts"
32
+ "lightning": "lightningcss --bundle --targets \">= 0.25%\" ./src/styles.css -o dist/styles.css"
27
33
  },
28
34
  "dependencies": {
29
35
  "@splendidlabz/utils": "*"
package/src/base.css ADDED
@@ -0,0 +1,15 @@
1
+ /* Opinionated foundation: everything except the CSS/framework components.
2
+ Restyles bare HTML (reset + generic) and registers every utility group
3
+ (tools, layouts, effects), all tree-shaken. This is the foundation that
4
+ powers `base + components/*`. Use base OR utilities, never both. */
5
+
6
+ @import './tools/index.css';
7
+ /* button is a @utility (foundation-level): generic @applies it to bare
8
+ <button>, and framework components @apply button-icon. */
9
+ @import './components/css/button.css';
10
+ @import './reset.css' layer(reset);
11
+ @import './layout-reset.css' layer(reset);
12
+ @import './variables/index.css';
13
+ @import './generic/index.css';
14
+ @import './layouts/index.css';
15
+ @import './effects/index.css';
@@ -1,33 +1,31 @@
1
1
  @utility fancylist {
2
- & {
3
- --svg-width: 1em;
4
- --svg-height: 1lh;
5
- display: grid;
2
+ --svg-width: 1em;
3
+ --svg-height: 1lh;
4
+ display: grid;
6
5
 
7
- /* grid-template-columns: auto 1fr; */
8
- column-gap: 0.5em;
6
+ /* grid-template-columns: auto 1fr; */
7
+ column-gap: 0.5em;
9
8
 
10
- :where(li) {
11
- grid-column: 1 / -1;
12
- display: grid;
9
+ :where(li) {
10
+ grid-column: 1 / -1;
11
+ display: grid;
13
12
 
14
- /* grid-template-columns: subgrid; */
15
- grid-template-columns: auto 1fr;
16
- column-gap: inherit;
13
+ /* grid-template-columns: subgrid; */
14
+ grid-template-columns: auto 1fr;
15
+ column-gap: inherit;
17
16
 
18
- /* Positions the Emoji */
19
- /* This is kind of brute-forced at the moment. */
20
- :where(.emoji),
21
- > :where(astro-slot, astro-island) > :where(.emoji) {
22
- font-size: 0.75em;
23
- line-height: 1lh;
24
- }
17
+ /* Positions the Emoji */
18
+ /* This is kind of brute-forced at the moment. */
19
+ :where(.emoji),
20
+ > :where(astro-slot, astro-island) > :where(.emoji) {
21
+ font-size: 0.75em;
22
+ line-height: 1lh;
23
+ }
25
24
 
26
- :where(ul) {
27
- grid-column: 2;
28
- display: grid;
29
- column-gap: inherit;
30
- }
25
+ :where(ul) {
26
+ grid-column: 2;
27
+ display: grid;
28
+ column-gap: inherit;
31
29
  }
32
30
  }
33
31
  }
@@ -0,0 +1,7 @@
1
+ /* Astro component styles + the CSS components they @apply (prose, etc.).
2
+ Pure layer — no tools/layouts/button. Import a foundation first
3
+ (base or utilities), or these @applies won't resolve. Astro class names may
4
+ clash with common component names — opt in deliberately. */
5
+
6
+ @import './css/index.css';
7
+ @import './astro/index.css';
@@ -0,0 +1,7 @@
1
+ /* Svelte component styles + the CSS components they @apply (prose, button-icon).
2
+ Pure layer — no tools/layouts/button. Import a foundation first
3
+ (base or utilities), or these @applies won't resolve. Svelte class names may
4
+ clash with common component names — opt in deliberately. */
5
+
6
+ @import './css/index.css';
7
+ @import './svelte/index.css';
@@ -0,0 +1,40 @@
1
+ @utility button {
2
+ & {
3
+ @apply pigment-with-svg;
4
+ flex-shrink: 0; /* Prevents button from shrinking when used in flex elements */
5
+ display: inline-flex;
6
+ justify-content: center;
7
+ align-items: center;
8
+ gap: 0.5em;
9
+ max-width: 100%;
10
+ padding: 0.125lh 0.75lh;
11
+ font: inherit;
12
+ text-decoration-line: none !important;
13
+
14
+ &[disabled] {
15
+ cursor: default;
16
+ }
17
+
18
+ * {
19
+ pointer-events: none;
20
+ }
21
+
22
+ svg path {
23
+ @apply transition-scaffold;
24
+ transition: var(--transition-values);
25
+ transition-property: var(--transition-props);
26
+ }
27
+ }
28
+ }
29
+
30
+ @utility button-icon {
31
+ & {
32
+ padding: 0.5em;
33
+ }
34
+ }
35
+
36
+ @utility button-round {
37
+ & {
38
+ border-radius: 50%;
39
+ }
40
+ }
@@ -43,10 +43,17 @@
43
43
  @apply divider-between-y;
44
44
 
45
45
  > * {
46
+ flex-grow: 1;
46
47
  border-width: 0;
47
48
  border-radius: 0;
48
49
  }
49
50
 
51
+ /* Opt-in equal columns. :where() keeps single-class specificity so a
52
+ responsive flip to card-divided-vertical resets flex-basis cleanly. */
53
+ &:where(.equal) > * {
54
+ flex-basis: 0;
55
+ }
56
+
50
57
  > :where(:not(:first-child)) {
51
58
  border-left-width: var(--border-width);
52
59
  border-color: var(--_bc, var(--border-color));
@@ -70,6 +77,8 @@
70
77
  @apply divider-between-x;
71
78
 
72
79
  > * {
80
+ flex-grow: 0;
81
+ flex-basis: auto;
73
82
  border-width: 0;
74
83
  border-radius: 0;
75
84
  }
@@ -1,4 +1,3 @@
1
1
  @import './input.css';
2
- @import './textarea.css';
3
2
  @import './select.css';
4
3
  @import './checkbox-and-radio.css';
@@ -9,3 +9,5 @@
9
9
  @import './table.css';
10
10
  @import './writing-mode.css';
11
11
  @import './strikethrough.css';
12
+ @import './forms/index.css';
13
+ @import './typography/index.css';
@@ -58,50 +58,136 @@
58
58
  @utility tablist-underline {
59
59
  gap: 0;
60
60
 
61
- .tab {
61
+ /* Structural pseudos wrapped in :where() so static and responsive placement
62
+ compose by source order (see tablist-card-divided for the full rationale). */
63
+ :where(.tab) {
62
64
  border-width: 0;
63
65
  border-radius: 0;
64
66
  }
65
67
 
66
- &.tablist-top .tab {
68
+ &:where(.tablist-top) :where(.tab) {
67
69
  border-bottom-width: var(--border-width);
68
70
  }
69
71
 
70
- &.tablist-left .tab {
72
+ &:where(.tablist-left) :where(.tab) {
71
73
  border-right-width: var(--border-width);
72
74
  }
73
75
 
74
- &.tablist-right .tab {
76
+ &:where(.tablist-right) :where(.tab) {
75
77
  border-left-width: var(--border-width);
76
78
  }
79
+
80
+ /* Responsive placement. The class rules above are the static/old-browser
81
+ fallback; these react to the live --placement so a tablist that flips
82
+ placement at a breakpoint moves its underline to the new edge. Each block
83
+ zeroes the other two edges so no stale underline from the static rule
84
+ survives the flip. */
85
+ @container style(--placement: top) {
86
+ :where(.tab) {
87
+ border-bottom-width: var(--border-width);
88
+ border-right-width: 0;
89
+ border-left-width: 0;
90
+ }
91
+ }
92
+
93
+ @container style(--placement: left) {
94
+ :where(.tab) {
95
+ border-right-width: var(--border-width);
96
+ border-bottom-width: 0;
97
+ border-left-width: 0;
98
+ }
99
+ }
100
+
101
+ @container style(--placement: right) {
102
+ :where(.tab) {
103
+ border-left-width: var(--border-width);
104
+ border-bottom-width: 0;
105
+ border-right-width: 0;
106
+ }
107
+ }
77
108
  }
78
109
 
79
110
  @utility tablist-tab {
80
- .tab {
111
+ :where(.tab) {
81
112
  position: relative;
82
113
  z-index: 1;
83
114
  }
84
115
 
85
- &.tablist-top :where(.tab) {
116
+ /* Static/old-browser fallback. Structural selectors wrapped in :where() so
117
+ the container queries below compose by source order. Edge removal uses the
118
+ -width longhand (not the `border-*: 0` shorthand) so it leaves border-style
119
+ intact — otherwise a responsive flip could restore an edge's width while
120
+ its style stayed `none` and nothing would render. */
121
+ &:where(.tablist-top) :where(.tab) {
86
122
  top: var(--border-width);
87
- border-bottom: 0;
123
+ border-bottom-width: 0;
88
124
  border-end-start-radius: 0;
89
125
  border-end-end-radius: 0;
90
126
  }
91
127
 
92
- &.tablist-left :where(.tab) {
128
+ &:where(.tablist-left) :where(.tab) {
93
129
  right: var(--border-width);
94
- border-right: 0;
130
+ border-right-width: 0;
95
131
  border-start-end-radius: 0;
96
132
  border-end-end-radius: 0;
97
133
  }
98
134
 
99
- &.tablist-right :where(.tab) {
135
+ &:where(.tablist-right) :where(.tab) {
100
136
  left: var(--border-width);
101
- border-left: 0;
137
+ border-left-width: 0;
102
138
  border-start-start-radius: 0;
103
139
  border-end-start-radius: 0;
104
140
  }
141
+
142
+ /* Responsive placement. Each block fully restates the tab treatment for its
143
+ placement: the active offset (other two reset to 0), the removed edge (other
144
+ removable edges restored to --border-width), and the two flattened corners
145
+ (the rest restored to --radius). This makes a breakpoint flip land cleanly
146
+ with no stale offset, missing edge, or squared corner from the static rule. */
147
+ @container style(--placement: top) {
148
+ :where(.tab) {
149
+ top: var(--border-width);
150
+ right: 0;
151
+ left: 0;
152
+ border-bottom-width: 0;
153
+ border-right-width: var(--border-width);
154
+ border-left-width: var(--border-width);
155
+ border-start-start-radius: var(--radius);
156
+ border-start-end-radius: var(--radius);
157
+ border-end-start-radius: 0;
158
+ border-end-end-radius: 0;
159
+ }
160
+ }
161
+
162
+ @container style(--placement: left) {
163
+ :where(.tab) {
164
+ right: var(--border-width);
165
+ top: 0;
166
+ left: 0;
167
+ border-right-width: 0;
168
+ border-bottom-width: var(--border-width);
169
+ border-left-width: var(--border-width);
170
+ border-start-start-radius: var(--radius);
171
+ border-end-start-radius: var(--radius);
172
+ border-start-end-radius: 0;
173
+ border-end-end-radius: 0;
174
+ }
175
+ }
176
+
177
+ @container style(--placement: right) {
178
+ :where(.tab) {
179
+ left: var(--border-width);
180
+ top: 0;
181
+ right: 0;
182
+ border-left-width: 0;
183
+ border-bottom-width: var(--border-width);
184
+ border-right-width: var(--border-width);
185
+ border-start-end-radius: var(--radius);
186
+ border-end-end-radius: var(--radius);
187
+ border-start-start-radius: 0;
188
+ border-end-start-radius: 0;
189
+ }
190
+ }
105
191
  }
106
192
 
107
193
  @utility tablist-card-divided {
@@ -110,50 +196,105 @@
110
196
  gap: 0;
111
197
  padding: 0;
112
198
 
199
+ /* Structural pseudos are wrapped in :where() so every rule stays at the
200
+ specificity of a single class. Placement treatments then compose purely by
201
+ source order: when a tablist both carries a static placement class and
202
+ flips --placement responsively, the last matching block's resets win
203
+ cleanly with no leftover corners or doubled dividers. */
204
+
113
205
  &:where(.tablist-top) {
114
206
  :where(.tab) {
115
207
  border-width: 0;
116
208
  border-radius: 0;
117
209
 
118
- &:not(:first-child) {
210
+ &:where(:not(:first-child)) {
119
211
  border-left-width: var(--border-width);
120
212
  border-color: var(--_bc, var(--border-color));
121
213
  }
122
214
 
123
- &:first-child {
124
- border-radius: 0;
215
+ &:where(:first-child) {
125
216
  border-top-left-radius: calc(var(--radius) - var(--border-width));
126
217
  border-bottom-left-radius: calc(var(--radius) - var(--border-width));
127
218
  }
128
219
 
129
- &:last-child {
130
- border-radius: 0;
220
+ &:where(:last-child) {
131
221
  border-top-right-radius: calc(var(--radius) - var(--border-width));
132
222
  border-bottom-right-radius: calc(var(--radius) - var(--border-width));
133
223
  }
134
224
  }
135
225
  }
136
226
 
137
- &.tablist-left,
138
- &.tablist-right {
227
+ &:where(.tablist-left),
228
+ &:where(.tablist-right) {
139
229
  :where(.tab) {
140
230
  border-width: 0;
141
231
  border-radius: 0;
142
- }
143
232
 
144
- &:not(:first-child) {
145
- border-top-width: var(--border-width);
146
- border-style: var(--border-style);
233
+ &:where(:not(:first-child)) {
234
+ border-top-width: var(--border-width);
235
+ border-color: var(--_bc, var(--border-color));
236
+ }
237
+
238
+ &:where(:first-child) {
239
+ border-top-left-radius: calc(var(--radius) - var(--border-width));
240
+ border-top-right-radius: calc(var(--radius) - var(--border-width));
241
+ }
242
+
243
+ &:where(:last-child) {
244
+ border-bottom-left-radius: calc(var(--radius) - var(--border-width));
245
+ border-bottom-right-radius: calc(var(--radius) - var(--border-width));
246
+ }
147
247
  }
248
+ }
148
249
 
149
- &:first-child {
150
- border-top-left-radius: calc(var(--radius) - var(--border-width));
151
- border-top-right-radius: calc(var(--radius) - var(--border-width));
250
+ /* Responsive placement.
251
+ The class rules above cover static placement in every browser. These
252
+ container style queries react to the live --placement value, so a tablist
253
+ that flips placement at a breakpoint (tablist-top max-bp:tablist-left)
254
+ also flips its divided-border treatment. They win over the class rules by
255
+ source order in supporting browsers; older browsers ignore them and keep
256
+ the static treatment. */
257
+ @container style(--placement: top) {
258
+ :where(.tab) {
259
+ border-width: 0;
260
+ border-radius: 0;
261
+
262
+ &:where(:not(:first-child)) {
263
+ border-left-width: var(--border-width);
264
+ border-color: var(--_bc, var(--border-color));
265
+ }
266
+
267
+ &:where(:first-child) {
268
+ border-top-left-radius: calc(var(--radius) - var(--border-width));
269
+ border-bottom-left-radius: calc(var(--radius) - var(--border-width));
270
+ }
271
+
272
+ &:where(:last-child) {
273
+ border-top-right-radius: calc(var(--radius) - var(--border-width));
274
+ border-bottom-right-radius: calc(var(--radius) - var(--border-width));
275
+ }
152
276
  }
277
+ }
153
278
 
154
- &:last-child {
155
- border-bottom-left-radius: calc(var(--radius) - var(--border-width));
156
- border-bottom-right-radius: calc(var(--radius) - var(--border-width));
279
+ @container style(--placement: left) or style(--placement: right) {
280
+ :where(.tab) {
281
+ border-width: 0;
282
+ border-radius: 0;
283
+
284
+ &:where(:not(:first-child)) {
285
+ border-top-width: var(--border-width);
286
+ border-color: var(--_bc, var(--border-color));
287
+ }
288
+
289
+ &:where(:first-child) {
290
+ border-top-left-radius: calc(var(--radius) - var(--border-width));
291
+ border-top-right-radius: calc(var(--radius) - var(--border-width));
292
+ }
293
+
294
+ &:where(:last-child) {
295
+ border-bottom-left-radius: calc(var(--radius) - var(--border-width));
296
+ border-bottom-right-radius: calc(var(--radius) - var(--border-width));
297
+ }
157
298
  }
158
299
  }
159
300
  }
@@ -0,0 +1,5 @@
1
+ /* Standalone effects: tools (effects @apply border-scaffold, transition-scaffold)
2
+ + the effect utilities (incl. animation + transitions). Self-contained. */
3
+
4
+ @import '../tools/index.css';
5
+ @import './index.css';
@@ -1,3 +1,5 @@
1
+ @import './animation/index.css';
2
+ @import './transitions/index.css';
1
3
  @import './elevation.css';
2
4
  @import './gradients.css';
3
5
  @import './fancybox.css';
@@ -1,43 +1,6 @@
1
- @utility button {
2
- & {
3
- @apply pigment-with-svg;
4
- flex-shrink: 0; /* Prevents button from shrinking when used in flex elements */
5
- display: inline-flex;
6
- justify-content: center;
7
- align-items: center;
8
- gap: 0.5em;
9
- max-width: 100%;
10
- padding: 0.125lh 0.75lh;
11
- font: inherit;
12
- text-decoration-line: none !important;
13
-
14
- &[disabled] {
15
- cursor: default;
16
- }
17
-
18
- * {
19
- pointer-events: none;
20
- }
21
-
22
- svg path {
23
- @apply transition-scaffold;
24
- transition: var(--transition-values);
25
- transition-property: var(--transition-props);
26
- }
27
- }
28
- }
29
-
30
- @utility button-icon {
31
- & {
32
- padding: 0.5em;
33
- }
34
- }
35
-
36
- @utility button-round {
37
- & {
38
- border-radius: 50%;
39
- }
40
- }
1
+ /* button / button-icon / button-round utilities live in components/css/button.css.
2
+ The base layer below `@apply`s `button`; whichever bundle includes this file
3
+ must also register button.css (styles.css via components/css, base.css directly). */
41
4
 
42
5
  @layer base {
43
6
  a {
@@ -1,8 +1,19 @@
1
+ @theme {
2
+ --textarea-height: 6lh;
3
+ }
4
+
1
5
  @layer base {
2
6
  fieldset {
3
7
  border: none;
4
8
  }
5
9
 
10
+ textarea {
11
+ min-height: var(--textarea-height);
12
+ resize: vertical;
13
+ /* stylelint-disable-next-line */
14
+ field-sizing: normal; /* Allows textarea to auto */
15
+ }
16
+
6
17
  /* Text inputs */
7
18
  input:where(
8
19
  [type='text'],
@@ -0,0 +1,5 @@
1
+ /* Standalone layouts: tools (for @variant interact-within etc.) + layout reset
2
+ + the layout utilities. Self-contained; imports tools once. */
3
+
4
+ @import '../tools/index.css';
5
+ @import './direct.css';
@@ -1,4 +1,4 @@
1
- /* Micro needs to come first
1
+ /* Micro needs to come first
2
2
  because it contains vertical that macro uses */
3
3
  @import './micro/index.css';
4
4
  @import './shell/index.css';