Expose theme variables to CSS
This commit is contained in:
parent
ba7d3be00e
commit
3c38f0a391
2 changed files with 5 additions and 1 deletions
|
|
@ -23,7 +23,8 @@ export function parseCssConfig(root) {
|
|||
}
|
||||
})
|
||||
|
||||
theme.remove()
|
||||
// Allow the variables to be used with var() anywhere in CSS
|
||||
theme.selector = ':root'
|
||||
|
||||
return config
|
||||
}
|
||||
|
|
|
|||
|
|
@ -32,6 +32,9 @@ test('it does something', () => {
|
|||
--tw-text-opacity: 1;
|
||||
color: rgb(250 202 222 / var(--tw-text-opacity));
|
||||
}
|
||||
:root {
|
||||
--colors-potato: #facade;
|
||||
}
|
||||
`)
|
||||
})
|
||||
})
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue