Skip to content
Snippets Groups Projects
Commit 7eb06ed9 authored by Konrad Mohrfeldt's avatar Konrad Mohrfeldt :koala:
Browse files

feat: add custom inset tailwind utilities

parent a33ec5d9
No related branches found
No related tags found
No related merge requests found
...@@ -9,9 +9,23 @@ module.exports = { ...@@ -9,9 +9,23 @@ module.exports = {
preflight: false, preflight: false,
}, },
plugins: [ plugins: [
plugin(function ({ addVariant }) { plugin(function ({ addVariant, addUtilities }) {
addVariant('hocus', ['&:hover', '&:focus-visible']) addVariant('hocus', ['&:hover', '&:focus-visible'])
addVariant('group-hocus', ':merge(.group):is(:hover, :focus-visible) &') addVariant('group-hocus', ':merge(.group):is(:hover, :focus-visible) &')
addUtilities({
'.inset-y-center': {
'inset-block': 0,
'margin-block': 'auto',
},
'.inset-x-center': {
'inset-inline': 0,
'margin-inline': 'auto',
},
'.inset-center': {
inset: 0,
margin: 'auto',
},
})
}), }),
], ],
theme: { theme: {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment