Releases: zss-in-js/typedcssx
2.0.1
2.0.0
Breaking Changes
Function-based media queries have been removed.
They will be replaced by a format using directly specified breakpoints.
[max_sm]: {...}Other changes
Style class imports are now the default export.
The compilation script for libraries has been changed from compile to compiler.
The compiler now uses tsc --noEmit to perform type checking before compilation.
Other fixes
Fixed to accept % for color rgb etc.
1.3.8
1.3.7
- Added @Keyframes to global
- Added font relative size to margin and padding.
It's can use from and to write it like this:
Style.global({
'@keyframes fadeIn': {
from: {
opacity: 0,
},
to: {
opacity: 1,
},
},Or it can also be written as:
Style.global({
'@keyframes fadeIn': {
'0%': {
opacity: 0,
},
'100%': {
opacity: 1,
},
},We are currently working on improving the issue of not being able to use separate units for padding and margin at the same time.
1.3.6
1.3.5
- Fixed an issue where px was not added when entering a number value in a pseudo element within a media element.
- Fixed a bug where &string elements were not output correctly when enclosed in media blocks.
- Refactoring the sheet-compiler.ts and style-compiler.ts
1.3.4
Union types have been removed.
old code.
type Exact<T, U> = T extends U ? (U extends T ? T : never) : never;
export type ExactClassesObjectType<T> = {
[K in keyof T]: Exact<T[K], CustomCSSProperties>;
};
create<T extends ClassesObjectType>(object: ExactClassesObjectType<T> | ClassesObjectType): ReturnStyleType<T> new code.
type Exact<T, U> = T extends U ? T : never;
export type ExactClassesObjectType<T> = {
[K in keyof T | string]: K extends keyof T ? Exact<T[K], CustomCSSProperties> : CustomCSSProperties;
};
create<T extends ClassesObjectType>(object: ExactClassesObjectType<T>): ReturnStyleType<T>Autocompletion speed slightly has increased due to a change from complex union types.
Also, from this update you can now write directly to component files as css.tsx.