Skip to content

Commit

Permalink
Fix const values in --color-s / --color-l
Browse files Browse the repository at this point in the history
  • Loading branch information
sashachabin committed Dec 21, 2023
1 parent 13032a8 commit c37ef48
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions utils/getCSSVarsColors.js
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import { hexToHSL } from './hexToHSL'

export function getCSSVarsColors(color) {
const { h, s, l } = hexToHSL(color)
const { h } = hexToHSL(color)

return {
'--color-h': h,
'--color-s': s,
'--color-l': l,
'--color-hsl': `var(--color-h) 45% 45%`,
'--color-s': '45%',
'--color-l': '45%',
'--color-hsl': `var(--color-h) var(--color-s) var(--color-l)`,
'--color': `hsl(var(--color-hsl))`,
}
}

0 comments on commit c37ef48

Please sign in to comment.