UNPKG

@gannochenko/ui.styled-components

Version:

<!-- PROJECT SHIELDS --> <!-- *** Reference links are enclosed in brackets [ ] instead of parentheses ( ). *** See the bottom of this document for the declaration of the reference variables *** for contributors-url, forks-url, etc. This is an optional, co

18 lines (17 loc) 671 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.backgroundColor = void 0; const styled_components_1 = require("styled-components"); const transition_1 = require("./transition"); const backgroundColor = (color = 'inherit', hoverColor, focusColor, transitionTime = 0) => (0, styled_components_1.css) ` background-color: ${color}; &:hover { background-color: ${hoverColor || color}; } &:focus { background-color: ${focusColor || color}; } ${(0, transition_1.transition)('background-color', transitionTime)} `; exports.backgroundColor = backgroundColor; //# sourceMappingURL=backgroundColor.js.map