Skip to content
This repository was archived by the owner on Apr 25, 2026. It is now read-only.
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions packages/core/src/default/defaultThemeMap.js
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,7 @@ export const defaultThemeMap = {

fontSize: fontSizes,

accentColor: colors,
background: colors,
backgroundColor: colors,
backgroundImage: colors,
Expand Down
9 changes: 5 additions & 4 deletions packages/core/types/config.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import type Stitches from './stitches.js'
/** Configuration Interface */
declare namespace ConfigType {
/** Prefix interface. */
export type Prefix<T = ''> = T extends string ? T: string
export type Prefix<T = ''> = T extends string ? T : string

/** Media interface. */
export type Media<T = {}> = {
Expand All @@ -28,10 +28,10 @@ declare namespace ConfigType {
transitions?: { [token in number | string]: boolean | number | string }
zIndices?: { [token in number | string]: boolean | number | string }
} & {
[Scale in keyof T]: {
[Token in keyof T[Scale]]: T[Scale][Token] extends (boolean | number | string) ? T[Scale][Token] : (boolean | number | string)
[Scale in keyof T]: {
[Token in keyof T[Scale]]: T[Scale][Token] extends (boolean | number | string) ? T[Scale][Token] : (boolean | number | string)
}
}
}

/** ThemeMap interface. */
export type ThemeMap<T = {}> = {
Expand Down Expand Up @@ -112,6 +112,7 @@ export interface DefaultThemeMap {

fontSize: 'fontSizes'

accentColor: 'colors'
background: 'colors'
backgroundColor: 'colors'
backgroundImage: 'colors'
Expand Down
43 changes: 26 additions & 17 deletions packages/core/types/css.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,19 @@
* SOFTWARE.
*/

export {};
export { };


export interface StandardLonghandProperties {
/**
* The **`accent-color`** CSS property sets the accent color for user-interface controls generated by some elements.
*
* **Syntax**: `auto | <color>`
*
* **Initial value**: `auto`
*
*/
accentColor?: Property.Color;
/**
* The CSS **`align-content`** property sets the distribution of space between and around content items along a flexbox's cross-axis or a grid's block axis.
*
Expand Down Expand Up @@ -1307,7 +1316,7 @@ export interface StandardLonghandProperties {
*
* **Initial value**: `normal`
*
*/
*/
gridGap?: Property.GridGap;
/**
* The **`hanging-punctuation`** CSS property specifies whether a punctuation mark should hang at the start or end of a line of text. Hanging punctuation may be placed outside the line box.
Expand Down Expand Up @@ -3503,7 +3512,7 @@ export interface StandardShorthandProperties {

export interface StandardProperties
extends StandardLonghandProperties,
StandardShorthandProperties {}
StandardShorthandProperties { }


export interface SvgProperties {
Expand Down Expand Up @@ -3571,7 +3580,7 @@ export interface SvgProperties {

export interface Properties
extends StandardProperties,
SvgProperties {}
SvgProperties { }

export interface StandardLonghandPropertiesHyphen {
/**
Expand Down Expand Up @@ -4857,7 +4866,7 @@ export interface StandardLonghandPropertiesHyphen {
* **Initial value**: `normal`
*
*/
"grid-gap"?: Property.GridGap;
"grid-gap"?: Property.GridGap;
/**
* The **`hanging-punctuation`** CSS property specifies whether a punctuation mark should hang at the start or end of a line of text. Hanging punctuation may be placed outside the line box.
*
Expand Down Expand Up @@ -7052,7 +7061,7 @@ export interface StandardShorthandPropertiesHyphen {

export interface StandardPropertiesHyphen
extends StandardLonghandPropertiesHyphen,
StandardShorthandPropertiesHyphen {}
StandardShorthandPropertiesHyphen { }


export interface SvgPropertiesHyphen {
Expand Down Expand Up @@ -7120,7 +7129,7 @@ export interface SvgPropertiesHyphen {

export interface PropertiesHyphen
extends StandardPropertiesHyphen,
SvgPropertiesHyphen {}
SvgPropertiesHyphen { }

export type StandardLonghandPropertiesFallback = {
[P in keyof StandardLonghandProperties]: StandardLonghandProperties[P] | StandardLonghandProperties[P][];
Expand All @@ -7132,7 +7141,7 @@ export type StandardShorthandPropertiesFallback = {

export interface StandardPropertiesFallback
extends StandardLonghandPropertiesFallback,
StandardShorthandPropertiesFallback {}
StandardShorthandPropertiesFallback { }


export type SvgPropertiesFallback = {
Expand All @@ -7141,7 +7150,7 @@ export type SvgPropertiesFallback = {

export interface PropertiesFallback
extends StandardPropertiesFallback,
SvgPropertiesFallback {}
SvgPropertiesFallback { }

export type StandardLonghandPropertiesHyphenFallback = {
[P in keyof StandardLonghandPropertiesHyphen]: StandardLonghandPropertiesHyphen[P] | StandardLonghandPropertiesHyphen[P][];
Expand All @@ -7153,7 +7162,7 @@ export type StandardShorthandPropertiesHyphenFallback = {

export interface StandardPropertiesHyphenFallback
extends StandardLonghandPropertiesHyphenFallback,
StandardShorthandPropertiesHyphenFallback {}
StandardShorthandPropertiesHyphenFallback { }


export type SvgPropertiesHyphenFallback = {
Expand All @@ -7162,7 +7171,7 @@ export type SvgPropertiesHyphenFallback = {

export interface PropertiesHyphenFallback
extends StandardPropertiesHyphenFallback,
SvgPropertiesHyphenFallback {}
SvgPropertiesHyphenFallback { }

export type AtRules =
| "@charset"
Expand Down Expand Up @@ -7741,7 +7750,7 @@ export type SvgAttributes =

export type Globals = "inherit" | "initial" | "revert" | "unset";

export type OnlyObject = Record<never,never>
export type OnlyObject = Record<never, never>

export type OnlyNumber = number & OnlyObject

Expand All @@ -7762,11 +7771,11 @@ export namespace Property {

export type Animation = DataType.SingleAnimation | OnlyString;

export type AnimationDelay = never | OnlyString;
export type AnimationDelay = never | OnlyString;

export type AnimationDirection = DataType.SingleAnimationDirection | OnlyString;

export type AnimationDuration = never | OnlyString;
export type AnimationDuration = never | OnlyString;

export type AnimationFillMode = DataType.SingleAnimationFillMode | OnlyString;

Expand Down Expand Up @@ -8783,9 +8792,9 @@ export namespace Property {

export type Transition = DataType.SingleTransition | OnlyString;

export type TransitionDelay = never | OnlyString;
export type TransitionDelay = never | OnlyString;

export type TransitionDuration = never | OnlyString;
export type TransitionDuration = never | OnlyString;

export type TransitionProperty = "all" | "none" | OnlyString;

Expand Down Expand Up @@ -9813,7 +9822,7 @@ declare namespace DataType {

type SingleAnimationFillMode = "backwards" | "both" | "forwards" | "none";

type SingleTransition = EasingFunction | "all" | "none" | OnlyString;
type SingleTransition = EasingFunction | "all" | "none" | OnlyString;

type StepTimingFunction = "step-end" | "step-start" | OnlyString;

Expand Down
9 changes: 5 additions & 4 deletions packages/react/types/config.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import type Stitches from './stitches.js'
/** Configuration Interface */
declare namespace ConfigType {
/** Prefix interface. */
export type Prefix<T = ''> = T extends string ? T: string
export type Prefix<T = ''> = T extends string ? T : string

/** Media interface. */
export type Media<T = {}> = {
Expand All @@ -28,10 +28,10 @@ declare namespace ConfigType {
transitions?: { [token in number | string]: boolean | number | string }
zIndices?: { [token in number | string]: boolean | number | string }
} & {
[Scale in keyof T]: {
[Token in keyof T[Scale]]: T[Scale][Token] extends (boolean | number | string) ? T[Scale][Token] : (boolean | number | string)
[Scale in keyof T]: {
[Token in keyof T[Scale]]: T[Scale][Token] extends (boolean | number | string) ? T[Scale][Token] : (boolean | number | string)
}
}
}

/** ThemeMap interface. */
export type ThemeMap<T = {}> = {
Expand Down Expand Up @@ -112,6 +112,7 @@ export interface DefaultThemeMap {

fontSize: 'fontSizes'

accentColor: 'colors'
background: 'colors'
backgroundColor: 'colors'
backgroundImage: 'colors'
Expand Down
47 changes: 28 additions & 19 deletions packages/react/types/css.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,19 @@
* SOFTWARE.
*/

export {};
export { };


export interface StandardLonghandProperties {
/**
* The **`accent-color`** CSS property sets the accent color for user-interface controls generated by some elements.
*
* **Syntax**: `auto | <color>`
*
* **Initial value**: `auto`
*
*/
accentColor?: Property.Color;
/**
* The CSS **`align-content`** property sets the distribution of space between and around content items along a flexbox's cross-axis or a grid's block axis.
*
Expand Down Expand Up @@ -1300,14 +1309,14 @@ export interface StandardLonghandProperties {
*
*/
gridTemplateRows?: Property.GridTemplateRows;
/**
/**
* The **`grid-gap`** CSS property sets the size of the gap (gutter) between between rows and columns.
*
* **Syntax**: `normal | <length-percentage>`
*
* **Initial value**: `normal`
*
*/
*/
gridGap?: Property.GridGap;
/**
* The **`hanging-punctuation`** CSS property specifies whether a punctuation mark should hang at the start or end of a line of text. Hanging punctuation may be placed outside the line box.
Expand Down Expand Up @@ -3503,7 +3512,7 @@ export interface StandardShorthandProperties {

export interface StandardProperties
extends StandardLonghandProperties,
StandardShorthandProperties {}
StandardShorthandProperties { }


export interface SvgProperties {
Expand Down Expand Up @@ -3571,7 +3580,7 @@ export interface SvgProperties {

export interface Properties
extends StandardProperties,
SvgProperties {}
SvgProperties { }

export interface StandardLonghandPropertiesHyphen {
/**
Expand Down Expand Up @@ -4849,15 +4858,15 @@ export interface StandardLonghandPropertiesHyphen {
*
*/
"grid-template-rows"?: Property.GridTemplateRows;
/**
/**
* The **`grid-gap`** CSS property sets the size of the gap (gutter) between between rows and columns.
*
* **Syntax**: `normal | <length-percentage>`
*
* **Initial value**: `normal`
*
*/
"grid-gap"?: Property.GridGap;
"grid-gap"?: Property.GridGap;
/**
* The **`hanging-punctuation`** CSS property specifies whether a punctuation mark should hang at the start or end of a line of text. Hanging punctuation may be placed outside the line box.
*
Expand Down Expand Up @@ -7052,7 +7061,7 @@ export interface StandardShorthandPropertiesHyphen {

export interface StandardPropertiesHyphen
extends StandardLonghandPropertiesHyphen,
StandardShorthandPropertiesHyphen {}
StandardShorthandPropertiesHyphen { }


export interface SvgPropertiesHyphen {
Expand Down Expand Up @@ -7120,7 +7129,7 @@ export interface SvgPropertiesHyphen {

export interface PropertiesHyphen
extends StandardPropertiesHyphen,
SvgPropertiesHyphen {}
SvgPropertiesHyphen { }

export type StandardLonghandPropertiesFallback = {
[P in keyof StandardLonghandProperties]: StandardLonghandProperties[P] | StandardLonghandProperties[P][];
Expand All @@ -7132,7 +7141,7 @@ export type StandardShorthandPropertiesFallback = {

export interface StandardPropertiesFallback
extends StandardLonghandPropertiesFallback,
StandardShorthandPropertiesFallback {}
StandardShorthandPropertiesFallback { }


export type SvgPropertiesFallback = {
Expand All @@ -7141,7 +7150,7 @@ export type SvgPropertiesFallback = {

export interface PropertiesFallback
extends StandardPropertiesFallback,
SvgPropertiesFallback {}
SvgPropertiesFallback { }

export type StandardLonghandPropertiesHyphenFallback = {
[P in keyof StandardLonghandPropertiesHyphen]: StandardLonghandPropertiesHyphen[P] | StandardLonghandPropertiesHyphen[P][];
Expand All @@ -7153,7 +7162,7 @@ export type StandardShorthandPropertiesHyphenFallback = {

export interface StandardPropertiesHyphenFallback
extends StandardLonghandPropertiesHyphenFallback,
StandardShorthandPropertiesHyphenFallback {}
StandardShorthandPropertiesHyphenFallback { }


export type SvgPropertiesHyphenFallback = {
Expand All @@ -7162,7 +7171,7 @@ export type SvgPropertiesHyphenFallback = {

export interface PropertiesHyphenFallback
extends StandardPropertiesHyphenFallback,
SvgPropertiesHyphenFallback {}
SvgPropertiesHyphenFallback { }

export type AtRules =
| "@charset"
Expand Down Expand Up @@ -7741,7 +7750,7 @@ export type SvgAttributes =

export type Globals = "inherit" | "initial" | "revert" | "unset";

export type OnlyObject = Record<never,never>
export type OnlyObject = Record<never, never>

export type OnlyNumber = number & OnlyObject

Expand All @@ -7762,11 +7771,11 @@ export namespace Property {

export type Animation = DataType.SingleAnimation | OnlyString;

export type AnimationDelay = never | OnlyString;
export type AnimationDelay = never | OnlyString;

export type AnimationDirection = DataType.SingleAnimationDirection | OnlyString;

export type AnimationDuration = never | OnlyString;
export type AnimationDuration = never | OnlyString;

export type AnimationFillMode = DataType.SingleAnimationFillMode | OnlyString;

Expand Down Expand Up @@ -8783,9 +8792,9 @@ export namespace Property {

export type Transition = DataType.SingleTransition | OnlyString;

export type TransitionDelay = never | OnlyString;
export type TransitionDelay = never | OnlyString;

export type TransitionDuration = never | OnlyString;
export type TransitionDuration = never | OnlyString;

export type TransitionProperty = "all" | "none" | OnlyString;

Expand Down Expand Up @@ -9813,7 +9822,7 @@ declare namespace DataType {

type SingleAnimationFillMode = "backwards" | "both" | "forwards" | "none";

type SingleTransition = EasingFunction | "all" | "none" | OnlyString;
type SingleTransition = EasingFunction | "all" | "none" | OnlyString;

type StepTimingFunction = "step-end" | "step-start" | OnlyString;

Expand Down