Skip to content

Commit

Permalink
fix: replace all instances of lighten and darken functions
Browse files Browse the repository at this point in the history
  • Loading branch information
luis-almeida committed Aug 5, 2024
1 parent 08a912e commit b828b9c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/zcli-themes/src/lib/zass.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ export default function zass (source: string, variables: Variable[], assets: [pa

const command = /(?<command>lighten|darken)/i
const percentage = /(?<percentage>\d{1,3})%/
const functionsRegex = new RegExp(`${command.source}\\s*\\((?<color>.*),\\s*${percentage.source}\\s*\\)`)
const functionsRegex = new RegExp(`${command.source}\\s*\\((?<color>.*),\\s*${percentage.source}\\s*\\)`, 'g')

// `darken` and `lighten` functions may use variables so make
// sure to replace them last
Expand Down

0 comments on commit b828b9c

Please sign in to comment.