Skip to content

Commit

Permalink
fix: preset not generating oklch
Browse files Browse the repository at this point in the history
  • Loading branch information
itsjavi committed Jun 1, 2024
1 parent f8f889b commit 32ce5cb
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion modules/color-system/lib/color-manipulation.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ export function parseColor(color: string | Color): Required<Oklch> {

export function formatColorAsOklch(color: string | Color): string {
try {
const parsed = formatCss(color)
const parsed = formatCss(parseColor(color))
if (!parsed) {
throw new Error(`Cannot format color: ${JSON.stringify(color)}`)
}
Expand Down
2 changes: 1 addition & 1 deletion modules/color-system/lib/generate-color-tokens.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ export type GeneratedColorTokens = {
semanticColors: ExtendedTheme['semanticTokens']['colors']
}

export default function generateColorTokens2(config: ColorSystemConfig): GeneratedColorTokens {
export default function generateColorTokens(config: ColorSystemConfig): GeneratedColorTokens {
const tokens: GeneratedColorTokens = {
colors: {},
semanticColors: {},
Expand Down

0 comments on commit 32ce5cb

Please sign in to comment.