UNPKG

@wordpress/style-engine

Version:
38 lines 1.54 kB
/** * Internal dependencies */ import { generateRule } from '../utils'; const color = { name: 'color', generate: function (style, options) { let path = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : ['outline', 'color']; let ruleKey = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : 'outlineColor'; return generateRule(style, options, path, ruleKey); } }; const offset = { name: 'offset', generate: function (style, options) { let path = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : ['outline', 'offset']; let ruleKey = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : 'outlineColor'; return generateRule(style, options, path, ruleKey); } }; const outlineStyle = { name: 'style', generate: function (style, options) { let path = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : ['outline', 'style']; let ruleKey = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : 'outlineStyle'; return generateRule(style, options, path, ruleKey); } }; const width = { name: 'width', generate: function (style, options) { let path = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : ['outline', 'width']; let ruleKey = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : 'outlineWidth'; return generateRule(style, options, path, ruleKey); } }; export default [color, outlineStyle, offset, width]; //# sourceMappingURL=index.js.map