@styleframe/theme 2.3.0 → 2.5.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/CHANGELOG.md +177 -3
- package/dist/theme.d.ts +938 -349
- package/dist/theme.js +4378 -3860
- package/dist/theme.umd.cjs +4 -4
- package/package.json +4 -4
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,179 @@
|
|
|
1
1
|
# @styleframe/theme
|
|
2
2
|
|
|
3
|
+
## 2.5.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [#105](https://github.com/styleframe-dev/styleframe/pull/105) [`b109ac1`](https://github.com/styleframe-dev/styleframe/commit/b109ac148d837ae0a060c34f0236338bf4deca36) Thanks [@alexgrozav](https://github.com/alexgrozav)! - Add multiplier support to spacing utilities (margin, padding, gap, space) with @-prefixed numeric values that generate calc() expressions based on a base spacing variable
|
|
8
|
+
|
|
9
|
+
## 2.4.0
|
|
10
|
+
|
|
11
|
+
### Minor Changes
|
|
12
|
+
|
|
13
|
+
- [#93](https://github.com/styleframe-dev/styleframe/pull/93) [`4ebc385`](https://github.com/styleframe-dev/styleframe/commit/4ebc3856ad4468e6caea5f72e595e781e2651b09) Thanks [@alexgrozav](https://github.com/alexgrozav)! - Add `useDesignTokensPreset` composable for quick design token system setup
|
|
14
|
+
- Introduces a comprehensive preset function that bootstraps complete design token systems with sensible defaults in a single function call
|
|
15
|
+
- Full TypeScript type inference for all configuration options
|
|
16
|
+
- Flexible domain configuration: use defaults, disable domains with `false`, or provide custom values
|
|
17
|
+
- Automatic color variation generation (lightness, shades, tints) with configurable levels
|
|
18
|
+
- Exports default values from variable composables (`defaultSpacingValues`, `defaultColorValues`, etc.)
|
|
19
|
+
- Adds `useFontStyle` variable composable
|
|
20
|
+
- Includes 54 comprehensive tests and detailed documentation
|
|
21
|
+
|
|
22
|
+
- [#95](https://github.com/styleframe-dev/styleframe/pull/95) [`75fd781`](https://github.com/styleframe-dev/styleframe/commit/75fd78196d61498db066de6e355eabcebbd39071) Thanks [@alexgrozav](https://github.com/alexgrozav)! - Rename `useUtilities` to `useUtilitiesPreset` for consistency with design tokens preset naming
|
|
23
|
+
- **BREAKING**: Renamed `useUtilities()` to `useUtilitiesPreset()` to align with `useDesignTokensPreset()` naming convention
|
|
24
|
+
- Added comprehensive presets documentation page with complete API reference for 200+ utility creators
|
|
25
|
+
- Updated all documentation examples and storybook files to use the new function name
|
|
26
|
+
- Clarified CHANGELOG entries to indicate this is a rename from the previous function
|
|
27
|
+
|
|
28
|
+
- [#97](https://github.com/styleframe-dev/styleframe/pull/97) [`fe021c6`](https://github.com/styleframe-dev/styleframe/commit/fe021c6b90c83593e5a297e4e66ef516d643252f) Thanks [@alexgrozav](https://github.com/alexgrozav)! - Centralize theme variable defaults to dedicated values folder
|
|
29
|
+
|
|
30
|
+
**BREAKING**: Default value exports have been renamed and `useUtilitiesPreset` has moved.
|
|
31
|
+
|
|
32
|
+
### Renamed Exports
|
|
33
|
+
|
|
34
|
+
All default value exports have been renamed from `defaultXxxValues` to `xxxValues`:
|
|
35
|
+
- `defaultSpacingValues` → `spacingValues`
|
|
36
|
+
- `defaultColorValues` → `colorValues`
|
|
37
|
+
- `defaultBorderWidthValues` → `borderWidthValues`
|
|
38
|
+
- `defaultBorderRadiusValues` → `borderRadiusValues`
|
|
39
|
+
- `defaultBorderStyleValues` → `borderStyleValues`
|
|
40
|
+
- `defaultBoxShadowValues` → `boxShadowValues`
|
|
41
|
+
- `defaultBreakpointValues` → `breakpointValues`
|
|
42
|
+
- `defaultEasingValues` → `easingValues`
|
|
43
|
+
- `defaultFontFamilyValues` → `fontFamilyValues`
|
|
44
|
+
- `defaultFontSizeValues` → `fontSizeValues`
|
|
45
|
+
- `defaultFontStyleValues` → `fontStyleValues`
|
|
46
|
+
- `defaultFontWeightValues` → `fontWeightValues`
|
|
47
|
+
- `defaultLineHeightValues` → `lineHeightValues`
|
|
48
|
+
- `defaultLetterSpacingValues` → `letterSpacingValues`
|
|
49
|
+
- `defaultScaleValues` → `scaleValues`
|
|
50
|
+
- `defaultScalePowerValues` → `scalePowerValues`
|
|
51
|
+
- `defaultColorLightnessValues` → `colorLightnessValues`
|
|
52
|
+
- `defaultColorShadeValues` → `colorShadeValues`
|
|
53
|
+
- `defaultColorTintValues` → `colorTintValues`
|
|
54
|
+
|
|
55
|
+
### Moved `useUtilitiesPreset`
|
|
56
|
+
|
|
57
|
+
The `useUtilitiesPreset` function has moved from `utilities/` to `presets/`:
|
|
58
|
+
|
|
59
|
+
```ts
|
|
60
|
+
// Before
|
|
61
|
+
import { useUtilitiesPreset } from "@styleframe/theme/utilities";
|
|
62
|
+
|
|
63
|
+
// After
|
|
64
|
+
import { useUtilitiesPreset } from "@styleframe/theme/presets";
|
|
65
|
+
// Or from the main export
|
|
66
|
+
import { useUtilitiesPreset } from "@styleframe/theme";
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
### Enhanced `useUtilitiesPreset`
|
|
70
|
+
|
|
71
|
+
The `useUtilitiesPreset` now supports configuration options:
|
|
72
|
+
- Customize utility default values
|
|
73
|
+
- Disable specific utilities with `false`
|
|
74
|
+
- Merge custom values with defaults using `meta.merge: true`
|
|
75
|
+
|
|
76
|
+
```ts
|
|
77
|
+
const utilities = useUtilitiesPreset(s, {
|
|
78
|
+
meta: { merge: true },
|
|
79
|
+
display: { flex: "flex", block: "block" },
|
|
80
|
+
position: false, // Disable position utilities
|
|
81
|
+
});
|
|
82
|
+
```
|
|
83
|
+
|
|
84
|
+
Migration: Update imports to use the new export names and import path.
|
|
85
|
+
|
|
86
|
+
- [#95](https://github.com/styleframe-dev/styleframe/pull/95) [`75fd781`](https://github.com/styleframe-dev/styleframe/commit/75fd78196d61498db066de6e355eabcebbd39071) Thanks [@alexgrozav](https://github.com/alexgrozav)! - Standardize utility class names to match CSS property syntax
|
|
87
|
+
|
|
88
|
+
**BREAKING**: All utility class names now use CSS-standard property names instead of abbreviated Tailwind-style names. This affects the generated CSS class names.
|
|
89
|
+
|
|
90
|
+
### Border Color Utilities
|
|
91
|
+
- `border-t-color` → `border-top-color`
|
|
92
|
+
- `border-r-color` → `border-right-color`
|
|
93
|
+
- `border-b-color` → `border-bottom-color`
|
|
94
|
+
- `border-l-color` → `border-left-color`
|
|
95
|
+
- `border-s-color` → `border-inline-start-color`
|
|
96
|
+
- `border-e-color` → `border-inline-end-color`
|
|
97
|
+
|
|
98
|
+
### Scroll Utilities
|
|
99
|
+
- `scroll-m` → `scroll-margin`
|
|
100
|
+
- `scroll-mt` → `scroll-margin-top`
|
|
101
|
+
- `scroll-mr` → `scroll-margin-right`
|
|
102
|
+
- `scroll-mb` → `scroll-margin-bottom`
|
|
103
|
+
- `scroll-ml` → `scroll-margin-left`
|
|
104
|
+
- `scroll-mx` → `scroll-margin-x`
|
|
105
|
+
- `scroll-my` → `scroll-margin-y`
|
|
106
|
+
- `scroll-ms` → `scroll-margin-inline-start`
|
|
107
|
+
- `scroll-me` → `scroll-margin-inline-end`
|
|
108
|
+
- `scroll-p` → `scroll-padding`
|
|
109
|
+
- `scroll-pt` → `scroll-padding-top`
|
|
110
|
+
- `scroll-pr` → `scroll-padding-right`
|
|
111
|
+
- `scroll-pb` → `scroll-padding-bottom`
|
|
112
|
+
- `scroll-pl` → `scroll-padding-left`
|
|
113
|
+
- `scroll-px` → `scroll-padding-x`
|
|
114
|
+
- `scroll-py` → `scroll-padding-y`
|
|
115
|
+
- `scroll-ps` → `scroll-padding-inline-start`
|
|
116
|
+
- `scroll-pe` → `scroll-padding-inline-end`
|
|
117
|
+
|
|
118
|
+
### Grid Utilities
|
|
119
|
+
- `grid-cols` → `grid-template-columns`
|
|
120
|
+
- `grid-rows` → `grid-template-rows`
|
|
121
|
+
- `col` → `grid-column`
|
|
122
|
+
- `col-span` → `grid-column-span`
|
|
123
|
+
- `col-start` → `grid-column-start`
|
|
124
|
+
- `col-end` → `grid-column-end`
|
|
125
|
+
- `row` → `grid-row`
|
|
126
|
+
- `row-span` → `grid-row-span`
|
|
127
|
+
- `row-start` → `grid-row-start`
|
|
128
|
+
- `row-end` → `grid-row-end`
|
|
129
|
+
- `auto-cols` → `grid-auto-columns`
|
|
130
|
+
- `auto-rows` → `grid-auto-rows`
|
|
131
|
+
- `grid-flow` → `grid-auto-flow`
|
|
132
|
+
|
|
133
|
+
### Flex Utilities
|
|
134
|
+
- `grow` → `flex-grow`
|
|
135
|
+
- `shrink` → `flex-shrink`
|
|
136
|
+
- `basis` → `flex-basis`
|
|
137
|
+
|
|
138
|
+
### Align Utilities
|
|
139
|
+
- `content` → `align-content`
|
|
140
|
+
- `items` → `align-items`
|
|
141
|
+
- `self` → `align-self`
|
|
142
|
+
|
|
143
|
+
### Justify Utilities
|
|
144
|
+
- `justify` → `justify-content`
|
|
145
|
+
|
|
146
|
+
### Transition Utilities
|
|
147
|
+
- `transition` → `transition-property`
|
|
148
|
+
- `duration` → `transition-duration`
|
|
149
|
+
- `ease` → `transition-timing-function`
|
|
150
|
+
- `delay` → `transition-delay`
|
|
151
|
+
|
|
152
|
+
### Transform Utilities
|
|
153
|
+
- `backface` → `backface-visibility`
|
|
154
|
+
- `origin` → `transform-origin`
|
|
155
|
+
|
|
156
|
+
### Inset Utilities
|
|
157
|
+
- `start` → `inset-inline-start`
|
|
158
|
+
- `end` → `inset-inline-end`
|
|
159
|
+
|
|
160
|
+
### Typography Utilities
|
|
161
|
+
- `underline-offset` → `text-underline-offset`
|
|
162
|
+
- `text-decoration` → `text-decoration-line`
|
|
163
|
+
|
|
164
|
+
### Box Utilities
|
|
165
|
+
- `box-decoration` → `box-decoration-break`
|
|
166
|
+
|
|
167
|
+
### Outline Utilities
|
|
168
|
+
- `outline` → `outline-width`
|
|
169
|
+
|
|
170
|
+
Migration: Update any CSS class references in your templates from the old abbreviated names to the new CSS-standard names.
|
|
171
|
+
|
|
172
|
+
### Patch Changes
|
|
173
|
+
|
|
174
|
+
- Updated dependencies [[`8460f16`](https://github.com/styleframe-dev/styleframe/commit/8460f169cec1199810e9203b357dac9f2f128c56)]:
|
|
175
|
+
- @styleframe/core@2.6.0
|
|
176
|
+
|
|
3
177
|
## 2.3.0
|
|
4
178
|
|
|
5
179
|
### Minor Changes
|
|
@@ -24,11 +198,11 @@
|
|
|
24
198
|
|
|
25
199
|
### Patch Changes
|
|
26
200
|
|
|
27
|
-
- [#76](https://github.com/styleframe-dev/styleframe/pull/76) [`06afe2a`](https://github.com/styleframe-dev/styleframe/commit/06afe2af66c3ecd8c6a516336e594c1e8cb56de1) Thanks [@alexgrozav](https://github.com/alexgrozav)! -
|
|
201
|
+
- [#76](https://github.com/styleframe-dev/styleframe/pull/76) [`06afe2a`](https://github.com/styleframe-dev/styleframe/commit/06afe2af66c3ecd8c6a516336e594c1e8cb56de1) Thanks [@alexgrozav](https://github.com/alexgrozav)! - **BREAKING**: rename `useUtilities` to `useUtilitiesPreset` for consistency with design tokens preset naming
|
|
28
202
|
|
|
29
|
-
|
|
203
|
+
Renamed `useUtilities()` to `useUtilitiesPreset()` to align with the naming convention established by `useDesignTokensPreset()`. The function registers all ~180 utility composables with a Styleframe instance and returns their creator functions, enabling automatic utility class generation for recipe declarations.
|
|
30
204
|
|
|
31
|
-
Updated recipe documentation examples to use `
|
|
205
|
+
Updated recipe documentation examples to use `useUtilitiesPreset()` with destructured functions and demonstrate both `ref()` and `@variable.name` syntax for referencing design tokens.
|
|
32
206
|
|
|
33
207
|
- Updated dependencies [[`d98b650`](https://github.com/styleframe-dev/styleframe/commit/d98b65030170582ceacfabde3ba9ff7d92105389)]:
|
|
34
208
|
- @styleframe/core@2.5.0
|