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

20 lines 994 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.heightProps = exports.widthProps = void 0; const styled_components_1 = require("styled-components"); const utils_1 = require("./utils"); const widthProps = ({ width, maxWidth, minWidth, wide, theme, }) => (0, styled_components_1.css) ` ${(0, utils_1.getStyleFor)('width', width, theme)}; ${(0, utils_1.getStyleFor)('max-width', maxWidth, theme)}; ${(0, utils_1.getStyleFor)('min-width', minWidth, theme)}; ${wide === true ? 'width: 100%;' : ''}; `; exports.widthProps = widthProps; const heightProps = ({ height, maxHeight, minHeight, tall, theme, }) => (0, styled_components_1.css) ` ${(0, utils_1.getStyleFor)('height', height, theme)}; ${(0, utils_1.getStyleFor)('max-height', maxHeight, theme)}; ${(0, utils_1.getStyleFor)('min-height', minHeight, theme)}; ${tall === true ? 'height: 100%;' : ''}; `; exports.heightProps = heightProps; //# sourceMappingURL=sizeProps.js.map