Skip to content

Commit

Permalink
Fix CSS func types (#1635)
Browse files Browse the repository at this point in the history
* fix: update base css func types

* chore: changeset
  • Loading branch information
itsdouges authored Mar 4, 2024
1 parent 88a44fc commit a68817a
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/funny-camels-punch.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@compiled/react': patch
---

Fix css function base types to have CSS property values available in intellisense.
4 changes: 3 additions & 1 deletion packages/react/src/css/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,9 @@ export default function css<TProps = unknown>(
...interpolations: CssFunction<TProps>[]
): CSSProps<TProps>;

export default function css<T = unknown>(styles: CssObject<T> | CssObject<T>[]): CSSProps<T>;
export default function css<T = unknown>(
styles: CssObject<T> | CssObject<T>[] | CSSProps<T> | CSSProps<T>[]
): CSSProps<T>;

export default function css<T = unknown>(
_styles: TemplateStringsArray | CssObject<T> | CssObject<T>[],
Expand Down

0 comments on commit a68817a

Please sign in to comment.