UNPKG

@chakra-v2/styled-system

Version:

Style function for css-in-js building component libraries

33 lines (30 loc) 862 B
import { t } from '../utils/index.mjs'; const position = { position: true, pos: t.prop("position"), zIndex: t.prop("zIndex", "zIndices"), inset: t.spaceT("inset"), insetX: t.spaceT(["left", "right"]), insetInline: t.spaceT("insetInline"), insetY: t.spaceT(["top", "bottom"]), insetBlock: t.spaceT("insetBlock"), top: t.spaceT("top"), insetBlockStart: t.spaceT("insetBlockStart"), bottom: t.spaceT("bottom"), insetBlockEnd: t.spaceT("insetBlockEnd"), left: t.spaceT("left"), insetInlineStart: t.logical({ scale: "space", property: { ltr: "left", rtl: "right" } }), right: t.spaceT("right"), insetInlineEnd: t.logical({ scale: "space", property: { ltr: "right", rtl: "left" } }) }; Object.assign(position, { insetStart: position.insetInlineStart, insetEnd: position.insetInlineEnd }); export { position };