Skip to content

Commit

Permalink
Fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
philipp-spiess authored and adamwathan committed Nov 7, 2024
1 parent 9c630e9 commit cb3f28c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/@tailwindcss-upgrade/src/migrate-js-config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -341,10 +341,10 @@ function removeUnnecessarySpacingKeys(
let [multiplier, unit] = splitNumberAndUnit(value as string)
if (multiplier === null) continue

if (!isValidSpacingMultiplier(multiplier)) continue
if (!isValidSpacingMultiplier(key)) continue
if (unit !== spacingUnit) continue

if (parseFloat(multiplier) === parseFloat(multiplier) * parseFloat(spacingMultiplier)) {
if (parseFloat(multiplier) === Number(key) * parseFloat(spacingMultiplier)) {
delete resolvedConfig.theme.spacing[key]
designSystem.theme.clearNamespace(escape(`--spacing-${key.replaceAll('.', '_')}`), 0)
}
Expand Down

0 comments on commit cb3f28c

Please sign in to comment.