We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
@custom-variant
1 parent d083801 commit 25601e2Copy full SHA for 25601e2
packages/@tailwindcss-upgrade/src/codemods/config/migrate-js-config.ts
@@ -235,7 +235,13 @@ async function migrateTheme(
235
236
if (variants.size > 0) {
237
css += '\n@tw-bucket custom-variant {\n'
238
+
239
+ let previousRoot = ''
240
for (let [name, selector] of variants) {
241
+ let root = name.split('-')[0]
242
+ if (previousRoot !== root) css += '\n'
243
+ previousRoot = root
244
245
css += `@custom-variant ${name} (${selector});\n`
246
}
247
css += '}\n'
0 commit comments