Remove variant dark mode strategy
This commit is contained in:
parent
2433d99716
commit
185250438c
2 changed files with 0 additions and 97 deletions
|
|
@ -229,65 +229,3 @@ it('should use modern sorting otherwise', () => {
|
|||
`)
|
||||
})
|
||||
})
|
||||
|
||||
it('should allow customization of the dark mode variant', () => {
|
||||
let config = {
|
||||
darkMode: ['variant', '&:not(.light *)'],
|
||||
content: [{ raw: html`<div class="dark:font-bold"></div>` }],
|
||||
corePlugins: { preflight: false },
|
||||
}
|
||||
|
||||
let input = css`
|
||||
@tailwind utilities;
|
||||
`
|
||||
|
||||
return run(input, config).then((result) => {
|
||||
expect(result.css).toMatchFormattedCss(css`
|
||||
.dark\:font-bold:not(.light *) {
|
||||
font-weight: 700;
|
||||
}
|
||||
`)
|
||||
})
|
||||
})
|
||||
|
||||
it('should support parallel selectors for the dark mode variant', () => {
|
||||
let config = {
|
||||
darkMode: ['variant', ['&:not(.light *)', '&:not(.extralight *)']],
|
||||
content: [{ raw: html`<div class="dark:font-bold"></div>` }],
|
||||
corePlugins: { preflight: false },
|
||||
}
|
||||
|
||||
let input = css`
|
||||
@tailwind utilities;
|
||||
`
|
||||
|
||||
return run(input, config).then((result) => {
|
||||
expect(result.css).toMatchFormattedCss(css`
|
||||
.dark\:font-bold:not(.light *),
|
||||
.dark\:font-bold:not(.extralight *) {
|
||||
font-weight: 700;
|
||||
}
|
||||
`)
|
||||
})
|
||||
})
|
||||
|
||||
it('should support fn selectors for the dark mode variant', () => {
|
||||
let config = {
|
||||
darkMode: ['variant', () => ['&:not(.light *)', '&:not(.extralight *)']],
|
||||
content: [{ raw: html`<div class="dark:font-bold"></div>` }],
|
||||
corePlugins: { preflight: false },
|
||||
}
|
||||
|
||||
let input = css`
|
||||
@tailwind utilities;
|
||||
`
|
||||
|
||||
return run(input, config).then((result) => {
|
||||
expect(result.css).toMatchFormattedCss(css`
|
||||
.dark\:font-bold:not(.light *),
|
||||
.dark\:font-bold:not(.extralight *) {
|
||||
font-weight: 700;
|
||||
}
|
||||
`)
|
||||
})
|
||||
})
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue