Skip to content

Commit

Permalink
fix: darkmode for heading component
Browse files Browse the repository at this point in the history
  • Loading branch information
im3dabasia committed Dec 27, 2024
1 parent 4868ee3 commit 74a8363
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion packages/components/src/heading/hook.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ export function useHeading(
const {
as: asProp,
level = 2,
color = COLORS.gray[ 900 ],
color = COLORS.theme.foreground,
isBlock = true,
weight = CONFIG.fontWeightHeading as import('react').CSSProperties[ 'fontWeight' ],
...otherProps
Expand Down
4 changes: 2 additions & 2 deletions packages/components/src/text/hook.ts
Original file line number Diff line number Diff line change
Expand Up @@ -105,8 +105,8 @@ export default function useText(
getOptimalTextShade( optimizeReadabilityFor ) === 'dark';

sx.optimalTextColor = isOptimalTextColorDark
? css( { color: COLORS.gray[ 900 ] } )
: css( { color: COLORS.white } );
? css( { color: COLORS.theme.foreground } )
: css( { color: COLORS.theme.foregroundInverted } );
}

return cx(
Expand Down

0 comments on commit 74a8363

Please sign in to comment.