Skip to content

Commit

Permalink
Merge branch 'canary' of https://github.com/modulz/stitches into canary
Browse files Browse the repository at this point in the history
  • Loading branch information
Pedro Duarte committed Aug 12, 2021
2 parents 9c58932 + fc1b4a1 commit a19ad0e
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 6 deletions.
7 changes: 4 additions & 3 deletions packages/react/types/css-util.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,8 @@ export type CSS<
Media = {},
Theme = {},
ThemeMap = Config.DefaultThemeMap,
Utils = {}
Utils = {},
IsFlat = false
> = (
// nested at-rule css styles
& {
Expand Down Expand Up @@ -97,7 +98,7 @@ export type CSS<
)
}
// unknown css declaration styles
& {
& (true extends IsFlat ? {} : {
/** Unknown property. */
[K in string]: (
| number
Expand All @@ -106,7 +107,7 @@ export type CSS<
| {}
| undefined
)
}
})
)

/** Unique symbol used to reference a property value. */
Expand Down
3 changes: 2 additions & 1 deletion packages/react/types/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,8 @@ export type CSS<
Config['media'],
Config['theme'],
Config['themeMap'],
Config['utils']
Config['utils'],
false
>

/** Returns the properties, attributes, and children expected by a component. */
Expand Down
4 changes: 2 additions & 2 deletions packages/react/types/stitches.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ export default interface Stitches<
? Composers[K]
: Composers[K] extends Util.Function
? Composers[K]
: CSSUtil.CSS<Media, Theme, ThemeMap, Utils> & {
: CSSUtil.CSS<Media, Theme, ThemeMap, Utils, true> & {
/** The **variants** property sets variants.
*
* [Read Documentation](https://stitches.dev/docs/variants)
Expand Down Expand Up @@ -194,7 +194,7 @@ export default interface Stitches<
? Composers[K]
: Composers[K] extends Util.Function
? Composers[K]
: CSSUtil.CSS<Media, Theme, ThemeMap, Utils> & {
: CSSUtil.CSS<Media, Theme, ThemeMap, Utils, true> & {
/** The **variants** property sets variants.
*
* [Read Documentation](https://stitches.dev/docs/variants)
Expand Down

0 comments on commit a19ad0e

Please sign in to comment.