Skip to content

Commit e999308

Browse files
Sprinkles: Fix types for numbers as values (#59)
1 parent 9f2cc7e commit e999308

File tree

2 files changed

+10
-3
lines changed

2 files changed

+10
-3
lines changed

.changeset/orange-moons-wink.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'@vanilla-extract/sprinkles': patch
3+
---
4+
5+
Fix types for numbers as values

packages/sprinkles/src/index.ts

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,12 @@ interface Condition {
1616

1717
type BaseConditions = { [conditionName: string]: Condition };
1818

19+
type CSSProperties = CSS.Properties<(string & {}) | number>;
20+
1921
type AtomicProperties = {
20-
[Property in keyof CSS.Properties]?:
21-
| Record<string, CSS.Properties[Property]>
22-
| Array<CSS.Properties[Property]>;
22+
[Property in keyof CSSProperties]?:
23+
| Record<string, CSSProperties[Property]>
24+
| Array<CSSProperties[Property]>;
2325
};
2426

2527
type ShorthandOptions<

0 commit comments

Comments
 (0)