mirror of
https://github.com/tailwindlabs/tailwindcss.git
synced 2025-12-08 21:36:08 +00:00
Changed Variant Generation to apply per selector in a ruleset (fixes #530)
This commit is contained in:
parent
a63c976dc7
commit
002a4ba90d
@ -13,10 +13,12 @@ export default function generateVariantFunction(generator) {
|
||||
separator: escapeClassName(config.options.separator),
|
||||
modifySelectors: modifierFunction => {
|
||||
cloned.walkRules(rule => {
|
||||
rule.selector = modifierFunction({
|
||||
className: rule.selector.slice(1),
|
||||
selector: rule.selector,
|
||||
})
|
||||
rule.selectors = rule.selectors.map(selector =>
|
||||
modifierFunction({
|
||||
className: selector.slice(1),
|
||||
selector
|
||||
})
|
||||
)
|
||||
})
|
||||
return cloned
|
||||
},
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user