Skip to content

Commit b846470

Browse files
committed
rename variables
1 parent aed18e7 commit b846470

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

packages/@tailwindcss-upgrade/src/template/codemods/modernize-arbitrary-values.ts

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -27,10 +27,10 @@ export function modernizeArbitraryValues(
2727
if (ast.nodes.length !== 1) continue
2828

2929
// Track whether we need to add a `*:` variant
30-
let addChildVariant = false
30+
let addStarVariant = false
3131

3232
// Track whether we need to add a `**:` variant
33-
let addAllChildVariant = false
33+
let addStarStarVariant = false
3434

3535
// Handling a child combinator. E.g.: `[&>[data-visible]]` => `*:data-visible`
3636
if (
@@ -46,7 +46,7 @@ export function modernizeArbitraryValues(
4646
ast.nodes[0].nodes[2].type === 'attribute'
4747
) {
4848
ast.nodes[0].nodes = [ast.nodes[0].nodes[2]]
49-
addChildVariant = true
49+
addStarVariant = true
5050
}
5151

5252
// Handling a grand child combinator. E.g.: `[&_[data-visible]]` => `**:data-visible`
@@ -63,7 +63,7 @@ export function modernizeArbitraryValues(
6363
ast.nodes[0].nodes[2].type === 'attribute'
6464
) {
6565
ast.nodes[0].nodes = [ast.nodes[0].nodes[2]]
66-
addAllChildVariant = true
66+
addStarStarVariant = true
6767
}
6868

6969
// Filter out `&`. E.g.: `&[data-foo]` => `[data-foo]`
@@ -252,15 +252,15 @@ export function modernizeArbitraryValues(
252252
}
253253
}
254254

255-
if (addChildVariant) {
255+
if (addStarVariant) {
256256
let idx = clone.variants.indexOf(variant)
257257
if (idx === -1) continue
258258

259259
// Ensure we have the `*:` variant
260260
clone.variants.splice(idx, 1, variant, { kind: 'static', root: '*' })
261261
}
262262

263-
if (addAllChildVariant) {
263+
if (addStarStarVariant) {
264264
let idx = clone.variants.indexOf(variant)
265265
if (idx === -1) continue
266266

0 commit comments

Comments
 (0)