@stylexjs/stylex 0.14.1 → 0.14.2
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/lib/cjs/types/StyleXTypes.d.ts +49 -50
- package/lib/es/types/StyleXTypes.d.ts +49 -50
- package/package.json +2 -2
|
@@ -94,56 +94,56 @@ export type Keyframes = Readonly<{ [name: string]: CSSProperties }>;
|
|
|
94
94
|
|
|
95
95
|
export type PositionTry = Readonly<{
|
|
96
96
|
// Anchor Positioning Properties
|
|
97
|
-
positionAnchor?: CSSProperties['positionAnchor']
|
|
98
|
-
positionArea?: CSSProperties['positionArea']
|
|
97
|
+
positionAnchor?: CSSProperties['positionAnchor'];
|
|
98
|
+
positionArea?: CSSProperties['positionArea'];
|
|
99
99
|
// inset Properties
|
|
100
|
-
top?: CSSProperties['top']
|
|
101
|
-
right?: CSSProperties['right']
|
|
102
|
-
bottom?: CSSProperties['bottom']
|
|
103
|
-
left?: CSSProperties['left']
|
|
104
|
-
inset?: CSSProperties['inset']
|
|
105
|
-
insetBlock?: CSSProperties['insetBlock']
|
|
106
|
-
insetBlockEnd?: CSSProperties['insetBlockEnd']
|
|
107
|
-
insetBlockStart?: CSSProperties['insetBlockStart']
|
|
108
|
-
insetInline?: CSSProperties['insetInline']
|
|
109
|
-
insetInlineEnd?: CSSProperties['insetInlineEnd']
|
|
110
|
-
insetInlineStart?: CSSProperties['insetInlineStart']
|
|
100
|
+
top?: CSSProperties['top'];
|
|
101
|
+
right?: CSSProperties['right'];
|
|
102
|
+
bottom?: CSSProperties['bottom'];
|
|
103
|
+
left?: CSSProperties['left'];
|
|
104
|
+
inset?: CSSProperties['inset'];
|
|
105
|
+
insetBlock?: CSSProperties['insetBlock'];
|
|
106
|
+
insetBlockEnd?: CSSProperties['insetBlockEnd'];
|
|
107
|
+
insetBlockStart?: CSSProperties['insetBlockStart'];
|
|
108
|
+
insetInline?: CSSProperties['insetInline'];
|
|
109
|
+
insetInlineEnd?: CSSProperties['insetInlineEnd'];
|
|
110
|
+
insetInlineStart?: CSSProperties['insetInlineStart'];
|
|
111
111
|
// margin Properties
|
|
112
|
-
margin?: CSSProperties['margin']
|
|
113
|
-
marginBlock?: CSSProperties['marginBlock']
|
|
114
|
-
marginBlockEnd?: CSSProperties['marginBlockEnd']
|
|
115
|
-
marginBlockStart?: CSSProperties['marginBlockStart']
|
|
116
|
-
marginInline?: CSSProperties['marginInline']
|
|
117
|
-
marginInlineEnd?: CSSProperties['marginInlineEnd']
|
|
118
|
-
marginInlineStart?: CSSProperties['marginInlineStart']
|
|
119
|
-
marginTop?: CSSProperties['marginTop']
|
|
120
|
-
marginBottom?: CSSProperties['marginBottom']
|
|
121
|
-
marginLeft?: CSSProperties['marginLeft']
|
|
122
|
-
marginRight?: CSSProperties['marginRight']
|
|
112
|
+
margin?: CSSProperties['margin'];
|
|
113
|
+
marginBlock?: CSSProperties['marginBlock'];
|
|
114
|
+
marginBlockEnd?: CSSProperties['marginBlockEnd'];
|
|
115
|
+
marginBlockStart?: CSSProperties['marginBlockStart'];
|
|
116
|
+
marginInline?: CSSProperties['marginInline'];
|
|
117
|
+
marginInlineEnd?: CSSProperties['marginInlineEnd'];
|
|
118
|
+
marginInlineStart?: CSSProperties['marginInlineStart'];
|
|
119
|
+
marginTop?: CSSProperties['marginTop'];
|
|
120
|
+
marginBottom?: CSSProperties['marginBottom'];
|
|
121
|
+
marginLeft?: CSSProperties['marginLeft'];
|
|
122
|
+
marginRight?: CSSProperties['marginRight'];
|
|
123
123
|
// size properties
|
|
124
|
-
width?: CSSProperties['width']
|
|
125
|
-
height?: CSSProperties['height']
|
|
126
|
-
minWidth?: CSSProperties['minWidth']
|
|
127
|
-
minHeight?: CSSProperties['minHeight']
|
|
128
|
-
maxWidth?: CSSProperties['maxWidth']
|
|
129
|
-
maxHeight?: CSSProperties['maxHeight']
|
|
130
|
-
blockSize?: CSSProperties['blockSize']
|
|
131
|
-
inlineSize?: CSSProperties['inlineSize']
|
|
132
|
-
minBlockSize?: CSSProperties['minBlockSize']
|
|
133
|
-
minInlineSize?: CSSProperties['minInlineSize']
|
|
134
|
-
maxBlockSize?: CSSProperties['maxBlockSize']
|
|
135
|
-
maxInlineSize?: CSSProperties['maxInlineSize']
|
|
124
|
+
width?: CSSProperties['width'];
|
|
125
|
+
height?: CSSProperties['height'];
|
|
126
|
+
minWidth?: CSSProperties['minWidth'];
|
|
127
|
+
minHeight?: CSSProperties['minHeight'];
|
|
128
|
+
maxWidth?: CSSProperties['maxWidth'];
|
|
129
|
+
maxHeight?: CSSProperties['maxHeight'];
|
|
130
|
+
blockSize?: CSSProperties['blockSize'];
|
|
131
|
+
inlineSize?: CSSProperties['inlineSize'];
|
|
132
|
+
minBlockSize?: CSSProperties['minBlockSize'];
|
|
133
|
+
minInlineSize?: CSSProperties['minInlineSize'];
|
|
134
|
+
maxBlockSize?: CSSProperties['maxBlockSize'];
|
|
135
|
+
maxInlineSize?: CSSProperties['maxInlineSize'];
|
|
136
136
|
// self alignment properties
|
|
137
|
-
alignSelf?: CSSProperties['alignSelf']
|
|
138
|
-
justifySelf?: CSSProperties['justifySelf']
|
|
139
|
-
placeSelf?: CSSProperties['placeSelf']
|
|
137
|
+
alignSelf?: CSSProperties['alignSelf'];
|
|
138
|
+
justifySelf?: CSSProperties['justifySelf'];
|
|
139
|
+
placeSelf?: CSSProperties['placeSelf'];
|
|
140
140
|
}>;
|
|
141
141
|
|
|
142
142
|
export type ViewTransitionClass = Readonly<{
|
|
143
|
-
group?: CSSProperties
|
|
144
|
-
imagePair?: CSSProperties
|
|
145
|
-
old?: CSSProperties
|
|
146
|
-
new?: CSSProperties
|
|
143
|
+
group?: CSSProperties;
|
|
144
|
+
imagePair?: CSSProperties;
|
|
145
|
+
old?: CSSProperties;
|
|
146
|
+
new?: CSSProperties;
|
|
147
147
|
}>;
|
|
148
148
|
|
|
149
149
|
export type LegacyThemeStyles = Readonly<{ [constantName: string]: string }>;
|
|
@@ -244,11 +244,13 @@ export type VarGroup<
|
|
|
244
244
|
|
|
245
245
|
export type TokensFromVarGroup<T extends VarGroup<{}>> = T['__tokens'];
|
|
246
246
|
|
|
247
|
-
export type IDFromVarGroup<T extends VarGroup<{}>> =
|
|
248
|
-
T['__opaqueId'];
|
|
247
|
+
export type IDFromVarGroup<T extends VarGroup<{}>> = T['__opaqueId'];
|
|
249
248
|
|
|
250
249
|
type TTokens = Readonly<{
|
|
251
|
-
[key: string]:
|
|
250
|
+
[key: string]:
|
|
251
|
+
| CSSType<null | string | number>
|
|
252
|
+
| string
|
|
253
|
+
| { [key: string]: string };
|
|
252
254
|
}>;
|
|
253
255
|
|
|
254
256
|
type UnwrapVars<T> = T extends StyleXVar<infer U> ? U : T;
|
|
@@ -282,10 +284,7 @@ export type StyleX$DefineVars = <
|
|
|
282
284
|
declare class ThemeKey<out VG extends VarGroup<{}>> extends String {
|
|
283
285
|
private varGroup: VG;
|
|
284
286
|
}
|
|
285
|
-
export type Theme<
|
|
286
|
-
T extends VarGroup<{}>,
|
|
287
|
-
Tag extends symbol = symbol,
|
|
288
|
-
> = Tag &
|
|
287
|
+
export type Theme<T extends VarGroup<{}>, Tag extends symbol = symbol> = Tag &
|
|
289
288
|
Readonly<{
|
|
290
289
|
theme: StyleXClassNameFor<ThemeKey<T>, IDFromVarGroup<T>>;
|
|
291
290
|
}>;
|
|
@@ -94,56 +94,56 @@ export type Keyframes = Readonly<{ [name: string]: CSSProperties }>;
|
|
|
94
94
|
|
|
95
95
|
export type PositionTry = Readonly<{
|
|
96
96
|
// Anchor Positioning Properties
|
|
97
|
-
positionAnchor?: CSSProperties['positionAnchor']
|
|
98
|
-
positionArea?: CSSProperties['positionArea']
|
|
97
|
+
positionAnchor?: CSSProperties['positionAnchor'];
|
|
98
|
+
positionArea?: CSSProperties['positionArea'];
|
|
99
99
|
// inset Properties
|
|
100
|
-
top?: CSSProperties['top']
|
|
101
|
-
right?: CSSProperties['right']
|
|
102
|
-
bottom?: CSSProperties['bottom']
|
|
103
|
-
left?: CSSProperties['left']
|
|
104
|
-
inset?: CSSProperties['inset']
|
|
105
|
-
insetBlock?: CSSProperties['insetBlock']
|
|
106
|
-
insetBlockEnd?: CSSProperties['insetBlockEnd']
|
|
107
|
-
insetBlockStart?: CSSProperties['insetBlockStart']
|
|
108
|
-
insetInline?: CSSProperties['insetInline']
|
|
109
|
-
insetInlineEnd?: CSSProperties['insetInlineEnd']
|
|
110
|
-
insetInlineStart?: CSSProperties['insetInlineStart']
|
|
100
|
+
top?: CSSProperties['top'];
|
|
101
|
+
right?: CSSProperties['right'];
|
|
102
|
+
bottom?: CSSProperties['bottom'];
|
|
103
|
+
left?: CSSProperties['left'];
|
|
104
|
+
inset?: CSSProperties['inset'];
|
|
105
|
+
insetBlock?: CSSProperties['insetBlock'];
|
|
106
|
+
insetBlockEnd?: CSSProperties['insetBlockEnd'];
|
|
107
|
+
insetBlockStart?: CSSProperties['insetBlockStart'];
|
|
108
|
+
insetInline?: CSSProperties['insetInline'];
|
|
109
|
+
insetInlineEnd?: CSSProperties['insetInlineEnd'];
|
|
110
|
+
insetInlineStart?: CSSProperties['insetInlineStart'];
|
|
111
111
|
// margin Properties
|
|
112
|
-
margin?: CSSProperties['margin']
|
|
113
|
-
marginBlock?: CSSProperties['marginBlock']
|
|
114
|
-
marginBlockEnd?: CSSProperties['marginBlockEnd']
|
|
115
|
-
marginBlockStart?: CSSProperties['marginBlockStart']
|
|
116
|
-
marginInline?: CSSProperties['marginInline']
|
|
117
|
-
marginInlineEnd?: CSSProperties['marginInlineEnd']
|
|
118
|
-
marginInlineStart?: CSSProperties['marginInlineStart']
|
|
119
|
-
marginTop?: CSSProperties['marginTop']
|
|
120
|
-
marginBottom?: CSSProperties['marginBottom']
|
|
121
|
-
marginLeft?: CSSProperties['marginLeft']
|
|
122
|
-
marginRight?: CSSProperties['marginRight']
|
|
112
|
+
margin?: CSSProperties['margin'];
|
|
113
|
+
marginBlock?: CSSProperties['marginBlock'];
|
|
114
|
+
marginBlockEnd?: CSSProperties['marginBlockEnd'];
|
|
115
|
+
marginBlockStart?: CSSProperties['marginBlockStart'];
|
|
116
|
+
marginInline?: CSSProperties['marginInline'];
|
|
117
|
+
marginInlineEnd?: CSSProperties['marginInlineEnd'];
|
|
118
|
+
marginInlineStart?: CSSProperties['marginInlineStart'];
|
|
119
|
+
marginTop?: CSSProperties['marginTop'];
|
|
120
|
+
marginBottom?: CSSProperties['marginBottom'];
|
|
121
|
+
marginLeft?: CSSProperties['marginLeft'];
|
|
122
|
+
marginRight?: CSSProperties['marginRight'];
|
|
123
123
|
// size properties
|
|
124
|
-
width?: CSSProperties['width']
|
|
125
|
-
height?: CSSProperties['height']
|
|
126
|
-
minWidth?: CSSProperties['minWidth']
|
|
127
|
-
minHeight?: CSSProperties['minHeight']
|
|
128
|
-
maxWidth?: CSSProperties['maxWidth']
|
|
129
|
-
maxHeight?: CSSProperties['maxHeight']
|
|
130
|
-
blockSize?: CSSProperties['blockSize']
|
|
131
|
-
inlineSize?: CSSProperties['inlineSize']
|
|
132
|
-
minBlockSize?: CSSProperties['minBlockSize']
|
|
133
|
-
minInlineSize?: CSSProperties['minInlineSize']
|
|
134
|
-
maxBlockSize?: CSSProperties['maxBlockSize']
|
|
135
|
-
maxInlineSize?: CSSProperties['maxInlineSize']
|
|
124
|
+
width?: CSSProperties['width'];
|
|
125
|
+
height?: CSSProperties['height'];
|
|
126
|
+
minWidth?: CSSProperties['minWidth'];
|
|
127
|
+
minHeight?: CSSProperties['minHeight'];
|
|
128
|
+
maxWidth?: CSSProperties['maxWidth'];
|
|
129
|
+
maxHeight?: CSSProperties['maxHeight'];
|
|
130
|
+
blockSize?: CSSProperties['blockSize'];
|
|
131
|
+
inlineSize?: CSSProperties['inlineSize'];
|
|
132
|
+
minBlockSize?: CSSProperties['minBlockSize'];
|
|
133
|
+
minInlineSize?: CSSProperties['minInlineSize'];
|
|
134
|
+
maxBlockSize?: CSSProperties['maxBlockSize'];
|
|
135
|
+
maxInlineSize?: CSSProperties['maxInlineSize'];
|
|
136
136
|
// self alignment properties
|
|
137
|
-
alignSelf?: CSSProperties['alignSelf']
|
|
138
|
-
justifySelf?: CSSProperties['justifySelf']
|
|
139
|
-
placeSelf?: CSSProperties['placeSelf']
|
|
137
|
+
alignSelf?: CSSProperties['alignSelf'];
|
|
138
|
+
justifySelf?: CSSProperties['justifySelf'];
|
|
139
|
+
placeSelf?: CSSProperties['placeSelf'];
|
|
140
140
|
}>;
|
|
141
141
|
|
|
142
142
|
export type ViewTransitionClass = Readonly<{
|
|
143
|
-
group?: CSSProperties
|
|
144
|
-
imagePair?: CSSProperties
|
|
145
|
-
old?: CSSProperties
|
|
146
|
-
new?: CSSProperties
|
|
143
|
+
group?: CSSProperties;
|
|
144
|
+
imagePair?: CSSProperties;
|
|
145
|
+
old?: CSSProperties;
|
|
146
|
+
new?: CSSProperties;
|
|
147
147
|
}>;
|
|
148
148
|
|
|
149
149
|
export type LegacyThemeStyles = Readonly<{ [constantName: string]: string }>;
|
|
@@ -244,11 +244,13 @@ export type VarGroup<
|
|
|
244
244
|
|
|
245
245
|
export type TokensFromVarGroup<T extends VarGroup<{}>> = T['__tokens'];
|
|
246
246
|
|
|
247
|
-
export type IDFromVarGroup<T extends VarGroup<{}>> =
|
|
248
|
-
T['__opaqueId'];
|
|
247
|
+
export type IDFromVarGroup<T extends VarGroup<{}>> = T['__opaqueId'];
|
|
249
248
|
|
|
250
249
|
type TTokens = Readonly<{
|
|
251
|
-
[key: string]:
|
|
250
|
+
[key: string]:
|
|
251
|
+
| CSSType<null | string | number>
|
|
252
|
+
| string
|
|
253
|
+
| { [key: string]: string };
|
|
252
254
|
}>;
|
|
253
255
|
|
|
254
256
|
type UnwrapVars<T> = T extends StyleXVar<infer U> ? U : T;
|
|
@@ -282,10 +284,7 @@ export type StyleX$DefineVars = <
|
|
|
282
284
|
declare class ThemeKey<out VG extends VarGroup<{}>> extends String {
|
|
283
285
|
private varGroup: VG;
|
|
284
286
|
}
|
|
285
|
-
export type Theme<
|
|
286
|
-
T extends VarGroup<{}>,
|
|
287
|
-
Tag extends symbol = symbol,
|
|
288
|
-
> = Tag &
|
|
287
|
+
export type Theme<T extends VarGroup<{}>, Tag extends symbol = symbol> = Tag &
|
|
289
288
|
Readonly<{
|
|
290
289
|
theme: StyleXClassNameFor<ThemeKey<T>, IDFromVarGroup<T>>;
|
|
291
290
|
}>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@stylexjs/stylex",
|
|
3
|
-
"version": "0.14.
|
|
3
|
+
"version": "0.14.2",
|
|
4
4
|
"description": "A library for defining styles for optimized user interfaces.",
|
|
5
5
|
"main": "./lib/cjs/stylex.js",
|
|
6
6
|
"module": "./lib/es/stylex.mjs",
|
|
@@ -56,7 +56,7 @@
|
|
|
56
56
|
"cross-env": "^7.0.3",
|
|
57
57
|
"rimraf": "^5.0.10",
|
|
58
58
|
"rollup": "^4.24.0",
|
|
59
|
-
"scripts": "0.14.
|
|
59
|
+
"scripts": "0.14.2"
|
|
60
60
|
},
|
|
61
61
|
"files": [
|
|
62
62
|
"lib/*"
|