UNPKG

grommet

Version:

focus on the essential experience

25 lines 998 B
import styled, { css } from 'styled-components'; import { baseStyle, styledComponentsConfig } from '../../utils'; var fullStyle = function fullStyle(full) { if (full === 'min') return css(["min-height:100vh;"]); return css(["width:100vw;height:100vh;overflow:auto;"]); }; var StyledGrommet = styled.div.withConfig(styledComponentsConfig).withConfig({ displayName: "StyledGrommet", componentId: "sc-19lkkz7-0" })(["", " ", " ", " ", " ", ""], function (props) { return !props.plain && baseStyle; }, function (props) { return props.full && fullStyle(props.full); }, function (props) { return props.theme.global.font.face; }, function (props) { return props.theme.grommet.extend; }, function (props) { return props.cssVars && Object.keys(props.theme.global.colors).filter(function (k) { return typeof props.theme.global.colors[k] === 'string'; }).map(function (k) { return "--" + k + ": " + props.theme.global.colors[k] + ";"; }).join('\n'); }); export { StyledGrommet };