UNPKG

@empathyco/x-tailwindcss

Version:
32 lines (29 loc) 1 kB
'use strict'; /** * Util to remove background for component `button`. * * @param helpers - The {@link TailwindHelpers} to generate CSS. * @returns The {@link CssStyleOptions} for the util. */ function noBackground(helpers) { const { theme } = helpers; return { // Disabled style '--button-disabled-border-color': 'transparent', '--button-disabled-background-color': 'transparent', borderColor: 'transparent', backgroundColor: 'transparent', color: `var(--button-color-50,${theme('x.colors.neutral.90')})`, '&:hover': { borderColor: 'transparent', backgroundColor: 'transparent', color: `var(--button-color-75,${theme('x.colors.neutral.100')})`, }, '&:active': { borderColor: 'transparent', backgroundColor: 'transparent', color: `var(--button-color-75,${theme('x.colors.neutral.100')})`, }, }; } exports.noBackground = noBackground;