diff --git a/packages/zcli-themes/src/lib/zass.ts b/packages/zcli-themes/src/lib/zass.ts index dfdf738c..9e7ed27d 100644 --- a/packages/zcli-themes/src/lib/zass.ts +++ b/packages/zcli-themes/src/lib/zass.ts @@ -40,7 +40,7 @@ export default function zass (source: string, variables: Variable[], assets: [pa const command = /(?lighten|darken)/i const percentage = /(?\d{1,3})%/ - const functionsRegex = new RegExp(`${command.source}\\s*\\((?.*),\\s*${percentage.source}\\s*\\)`) + const functionsRegex = new RegExp(`${command.source}\\s*\\((?.*),\\s*${percentage.source}\\s*\\)`, 'g') // `darken` and `lighten` functions may use variables so make // sure to replace them last