@wordpress/style-engine 0.15.1-next.957ca95e4c.0 → 0.16.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -2,6 +2,8 @@
2
2
 
3
3
  ## Unreleased
4
4
 
5
+ ## 0.16.0 (2022-09-13)
6
+
5
7
  ## 0.15.0 (2022-08-24)
6
8
 
7
9
  ## 0.14.0 (2022-08-10)
package/README.md CHANGED
@@ -135,9 +135,9 @@ $stylesheet = wp_style_engine_get_stylesheet_from_css_rules(
135
135
  print_r( $stylesheet ); // .wp-pumpkin, .wp-kumquat {color:orange}.wp-tomato{color:red;padding:100px}
136
136
  ```
137
137
 
138
- ### wp_style_engine_get_stylesheet_from_store()
138
+ ### wp_style_engine_get_stylesheet_from_context()
139
139
 
140
- Returns compiled CSS from a store, if found.
140
+ Returns compiled CSS from a stored context, if found.
141
141
 
142
142
  _Parameters_
143
143
 
@@ -167,8 +167,8 @@ $stylesheet = wp_style_engine_get_stylesheet_from_css_rules(
167
167
  )
168
168
  );
169
169
 
170
- // Later, fetch compiled rules from store.
171
- $stylesheet = gutenberg_style_engine_get_stylesheet_from_store( 'fruit-styles' );
170
+ // Later, fetch compiled rules from context store.
171
+ $stylesheet = gutenberg_style_engine_get_stylesheet_from_context( 'fruit-styles' );
172
172
  print_r( $stylesheet ); // .wp-apple{color:green;}
173
173
  if ( ! empty( $stylesheet ) ) {
174
174
  wp_register_style( 'my-stylesheet', false, array(), true, true );
@@ -229,6 +229,8 @@ A guide to the terms and variable names referenced by the Style Engine package.
229
229
  <dl>
230
230
  <dt>Block style (Gutenberg internal)</dt>
231
231
  <dd>An object comprising a block's style attribute that contains a block's style values. E.g., <code>{ spacing: { margin: '10px' }, color: { ... }, ... }</code></dd>
232
+ <dt>Context</dt>
233
+ <dd>An identifier for a group of styles that share a common origin or purpose, e.g., 'block-supports' or 'global-styles'. The context is also used as a key to fetch CSS rules from the store.</dd>
232
234
  <dt>CSS declaration or (CSS property declaration)</dt>
233
235
  <dd>A CSS property paired with a CSS value. E.g., <code>color: pink</code> </dd>
234
236
  <dt>CSS declarations block</dt>
@@ -13,6 +13,8 @@ var _color = _interopRequireDefault(require("./color"));
13
13
 
14
14
  var _shadow = _interopRequireDefault(require("./shadow"));
15
15
 
16
+ var _outline = _interopRequireDefault(require("./outline"));
17
+
16
18
  var _spacing = _interopRequireDefault(require("./spacing"));
17
19
 
18
20
  var _typography = _interopRequireDefault(require("./typography"));
@@ -20,6 +22,6 @@ var _typography = _interopRequireDefault(require("./typography"));
20
22
  /**
21
23
  * Internal dependencies
22
24
  */
23
- const styleDefinitions = [..._border.default, ..._color.default, ..._spacing.default, ..._typography.default, ..._shadow.default];
25
+ const styleDefinitions = [..._border.default, ..._color.default, ..._outline.default, ..._spacing.default, ..._typography.default, ..._shadow.default];
24
26
  exports.styleDefinitions = styleDefinitions;
25
27
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["@wordpress/style-engine/src/styles/index.ts"],"names":["styleDefinitions","border","color","spacing","typography","shadow"],"mappings":";;;;;;;;;AAGA;;AACA;;AACA;;AACA;;AACA;;AAPA;AACA;AACA;AAOO,MAAMA,gBAAgB,GAAG,CAC/B,GAAGC,eAD4B,EAE/B,GAAGC,cAF4B,EAG/B,GAAGC,gBAH4B,EAI/B,GAAGC,mBAJ4B,EAK/B,GAAGC,eAL4B,CAAzB","sourcesContent":["/**\n * Internal dependencies\n */\nimport border from './border';\nimport color from './color';\nimport shadow from './shadow';\nimport spacing from './spacing';\nimport typography from './typography';\n\nexport const styleDefinitions = [\n\t...border,\n\t...color,\n\t...spacing,\n\t...typography,\n\t...shadow,\n];\n"]}
1
+ {"version":3,"sources":["@wordpress/style-engine/src/styles/index.ts"],"names":["styleDefinitions","border","color","outline","spacing","typography","shadow"],"mappings":";;;;;;;;;AAGA;;AACA;;AACA;;AACA;;AACA;;AACA;;AARA;AACA;AACA;AAQO,MAAMA,gBAAgB,GAAG,CAC/B,GAAGC,eAD4B,EAE/B,GAAGC,cAF4B,EAG/B,GAAGC,gBAH4B,EAI/B,GAAGC,gBAJ4B,EAK/B,GAAGC,mBAL4B,EAM/B,GAAGC,eAN4B,CAAzB","sourcesContent":["/**\n * Internal dependencies\n */\nimport border from './border';\nimport color from './color';\nimport shadow from './shadow';\nimport outline from './outline';\nimport spacing from './spacing';\nimport typography from './typography';\n\nexport const styleDefinitions = [\n\t...border,\n\t...color,\n\t...outline,\n\t...spacing,\n\t...typography,\n\t...shadow,\n];\n"]}
@@ -0,0 +1,47 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.default = void 0;
7
+
8
+ var _utils = require("../utils");
9
+
10
+ /**
11
+ * Internal dependencies
12
+ */
13
+ const color = {
14
+ name: 'color',
15
+ generate: function (style, options) {
16
+ let path = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : ['outline', 'color'];
17
+ let ruleKey = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : 'outlineColor';
18
+ return (0, _utils.generateRule)(style, options, path, ruleKey);
19
+ }
20
+ };
21
+ const offset = {
22
+ name: 'offset',
23
+ generate: function (style, options) {
24
+ let path = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : ['outline', 'offset'];
25
+ let ruleKey = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : 'outlineColor';
26
+ return (0, _utils.generateRule)(style, options, path, ruleKey);
27
+ }
28
+ };
29
+ const outlineStyle = {
30
+ name: 'style',
31
+ generate: function (style, options) {
32
+ let path = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : ['outline', 'style'];
33
+ let ruleKey = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : 'outlineStyle';
34
+ return (0, _utils.generateRule)(style, options, path, ruleKey);
35
+ }
36
+ };
37
+ const width = {
38
+ name: 'width',
39
+ generate: function (style, options) {
40
+ let path = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : ['outline', 'width'];
41
+ let ruleKey = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : 'outlineWidth';
42
+ return (0, _utils.generateRule)(style, options, path, ruleKey);
43
+ }
44
+ };
45
+ var _default = [color, outlineStyle, offset, width];
46
+ exports.default = _default;
47
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["@wordpress/style-engine/src/styles/outline/index.ts"],"names":["color","name","generate","style","options","path","ruleKey","offset","outlineStyle","width"],"mappings":";;;;;;;AAIA;;AAJA;AACA;AACA;AAIA,MAAMA,KAAK,GAAG;AACbC,EAAAA,IAAI,EAAE,OADO;AAEbC,EAAAA,QAAQ,EAAE,UACTC,KADS,EAETC,OAFS,EAKe;AAAA,QAFxBC,IAEwB,uEAFP,CAAE,SAAF,EAAa,OAAb,CAEO;AAAA,QADxBC,OACwB,uEADN,cACM;AACxB,WAAO,yBAAcH,KAAd,EAAqBC,OAArB,EAA8BC,IAA9B,EAAoCC,OAApC,CAAP;AACA;AATY,CAAd;AAYA,MAAMC,MAAM,GAAG;AACdN,EAAAA,IAAI,EAAE,QADQ;AAEdC,EAAAA,QAAQ,EAAE,UACTC,KADS,EAETC,OAFS,EAKe;AAAA,QAFxBC,IAEwB,uEAFP,CAAE,SAAF,EAAa,QAAb,CAEO;AAAA,QADxBC,OACwB,uEADN,cACM;AACxB,WAAO,yBAAcH,KAAd,EAAqBC,OAArB,EAA8BC,IAA9B,EAAoCC,OAApC,CAAP;AACA;AATa,CAAf;AAYA,MAAME,YAAY,GAAG;AACpBP,EAAAA,IAAI,EAAE,OADc;AAEpBC,EAAAA,QAAQ,EAAE,UACTC,KADS,EAETC,OAFS,EAKe;AAAA,QAFxBC,IAEwB,uEAFP,CAAE,SAAF,EAAa,OAAb,CAEO;AAAA,QADxBC,OACwB,uEADN,cACM;AACxB,WAAO,yBAAcH,KAAd,EAAqBC,OAArB,EAA8BC,IAA9B,EAAoCC,OAApC,CAAP;AACA;AATmB,CAArB;AAYA,MAAMG,KAAK,GAAG;AACbR,EAAAA,IAAI,EAAE,OADO;AAEbC,EAAAA,QAAQ,EAAE,UACTC,KADS,EAETC,OAFS,EAKe;AAAA,QAFxBC,IAEwB,uEAFP,CAAE,SAAF,EAAa,OAAb,CAEO;AAAA,QADxBC,OACwB,uEADN,cACM;AACxB,WAAO,yBAAcH,KAAd,EAAqBC,OAArB,EAA8BC,IAA9B,EAAoCC,OAApC,CAAP;AACA;AATY,CAAd;eAYe,CAAEN,KAAF,EAASQ,YAAT,EAAuBD,MAAvB,EAA+BE,KAA/B,C","sourcesContent":["/**\n * Internal dependencies\n */\nimport type { GeneratedCSSRule, Style, StyleOptions } from '../../types';\nimport { generateRule } from '../utils';\n\nconst color = {\n\tname: 'color',\n\tgenerate: (\n\t\tstyle: Style,\n\t\toptions: StyleOptions,\n\t\tpath: string[] = [ 'outline', 'color' ],\n\t\truleKey: string = 'outlineColor'\n\t): GeneratedCSSRule[] => {\n\t\treturn generateRule( style, options, path, ruleKey );\n\t},\n};\n\nconst offset = {\n\tname: 'offset',\n\tgenerate: (\n\t\tstyle: Style,\n\t\toptions: StyleOptions,\n\t\tpath: string[] = [ 'outline', 'offset' ],\n\t\truleKey: string = 'outlineColor'\n\t): GeneratedCSSRule[] => {\n\t\treturn generateRule( style, options, path, ruleKey );\n\t},\n};\n\nconst outlineStyle = {\n\tname: 'style',\n\tgenerate: (\n\t\tstyle: Style,\n\t\toptions: StyleOptions,\n\t\tpath: string[] = [ 'outline', 'style' ],\n\t\truleKey: string = 'outlineStyle'\n\t): GeneratedCSSRule[] => {\n\t\treturn generateRule( style, options, path, ruleKey );\n\t},\n};\n\nconst width = {\n\tname: 'width',\n\tgenerate: (\n\t\tstyle: Style,\n\t\toptions: StyleOptions,\n\t\tpath: string[] = [ 'outline', 'width' ],\n\t\truleKey: string = 'outlineWidth'\n\t): GeneratedCSSRule[] => {\n\t\treturn generateRule( style, options, path, ruleKey );\n\t},\n};\n\nexport default [ color, outlineStyle, offset, width ];\n"]}
@@ -4,7 +4,8 @@
4
4
  import border from './border';
5
5
  import color from './color';
6
6
  import shadow from './shadow';
7
+ import outline from './outline';
7
8
  import spacing from './spacing';
8
9
  import typography from './typography';
9
- export const styleDefinitions = [...border, ...color, ...spacing, ...typography, ...shadow];
10
+ export const styleDefinitions = [...border, ...color, ...outline, ...spacing, ...typography, ...shadow];
10
11
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["@wordpress/style-engine/src/styles/index.ts"],"names":["border","color","shadow","spacing","typography","styleDefinitions"],"mappings":"AAAA;AACA;AACA;AACA,OAAOA,MAAP,MAAmB,UAAnB;AACA,OAAOC,KAAP,MAAkB,SAAlB;AACA,OAAOC,MAAP,MAAmB,UAAnB;AACA,OAAOC,OAAP,MAAoB,WAApB;AACA,OAAOC,UAAP,MAAuB,cAAvB;AAEA,OAAO,MAAMC,gBAAgB,GAAG,CAC/B,GAAGL,MAD4B,EAE/B,GAAGC,KAF4B,EAG/B,GAAGE,OAH4B,EAI/B,GAAGC,UAJ4B,EAK/B,GAAGF,MAL4B,CAAzB","sourcesContent":["/**\n * Internal dependencies\n */\nimport border from './border';\nimport color from './color';\nimport shadow from './shadow';\nimport spacing from './spacing';\nimport typography from './typography';\n\nexport const styleDefinitions = [\n\t...border,\n\t...color,\n\t...spacing,\n\t...typography,\n\t...shadow,\n];\n"]}
1
+ {"version":3,"sources":["@wordpress/style-engine/src/styles/index.ts"],"names":["border","color","shadow","outline","spacing","typography","styleDefinitions"],"mappings":"AAAA;AACA;AACA;AACA,OAAOA,MAAP,MAAmB,UAAnB;AACA,OAAOC,KAAP,MAAkB,SAAlB;AACA,OAAOC,MAAP,MAAmB,UAAnB;AACA,OAAOC,OAAP,MAAoB,WAApB;AACA,OAAOC,OAAP,MAAoB,WAApB;AACA,OAAOC,UAAP,MAAuB,cAAvB;AAEA,OAAO,MAAMC,gBAAgB,GAAG,CAC/B,GAAGN,MAD4B,EAE/B,GAAGC,KAF4B,EAG/B,GAAGE,OAH4B,EAI/B,GAAGC,OAJ4B,EAK/B,GAAGC,UAL4B,EAM/B,GAAGH,MAN4B,CAAzB","sourcesContent":["/**\n * Internal dependencies\n */\nimport border from './border';\nimport color from './color';\nimport shadow from './shadow';\nimport outline from './outline';\nimport spacing from './spacing';\nimport typography from './typography';\n\nexport const styleDefinitions = [\n\t...border,\n\t...color,\n\t...outline,\n\t...spacing,\n\t...typography,\n\t...shadow,\n];\n"]}
@@ -0,0 +1,38 @@
1
+ /**
2
+ * Internal dependencies
3
+ */
4
+ import { generateRule } from '../utils';
5
+ const color = {
6
+ name: 'color',
7
+ generate: function (style, options) {
8
+ let path = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : ['outline', 'color'];
9
+ let ruleKey = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : 'outlineColor';
10
+ return generateRule(style, options, path, ruleKey);
11
+ }
12
+ };
13
+ const offset = {
14
+ name: 'offset',
15
+ generate: function (style, options) {
16
+ let path = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : ['outline', 'offset'];
17
+ let ruleKey = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : 'outlineColor';
18
+ return generateRule(style, options, path, ruleKey);
19
+ }
20
+ };
21
+ const outlineStyle = {
22
+ name: 'style',
23
+ generate: function (style, options) {
24
+ let path = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : ['outline', 'style'];
25
+ let ruleKey = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : 'outlineStyle';
26
+ return generateRule(style, options, path, ruleKey);
27
+ }
28
+ };
29
+ const width = {
30
+ name: 'width',
31
+ generate: function (style, options) {
32
+ let path = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : ['outline', 'width'];
33
+ let ruleKey = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : 'outlineWidth';
34
+ return generateRule(style, options, path, ruleKey);
35
+ }
36
+ };
37
+ export default [color, outlineStyle, offset, width];
38
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["@wordpress/style-engine/src/styles/outline/index.ts"],"names":["generateRule","color","name","generate","style","options","path","ruleKey","offset","outlineStyle","width"],"mappings":"AAAA;AACA;AACA;AAEA,SAASA,YAAT,QAA6B,UAA7B;AAEA,MAAMC,KAAK,GAAG;AACbC,EAAAA,IAAI,EAAE,OADO;AAEbC,EAAAA,QAAQ,EAAE,UACTC,KADS,EAETC,OAFS,EAKe;AAAA,QAFxBC,IAEwB,uEAFP,CAAE,SAAF,EAAa,OAAb,CAEO;AAAA,QADxBC,OACwB,uEADN,cACM;AACxB,WAAOP,YAAY,CAAEI,KAAF,EAASC,OAAT,EAAkBC,IAAlB,EAAwBC,OAAxB,CAAnB;AACA;AATY,CAAd;AAYA,MAAMC,MAAM,GAAG;AACdN,EAAAA,IAAI,EAAE,QADQ;AAEdC,EAAAA,QAAQ,EAAE,UACTC,KADS,EAETC,OAFS,EAKe;AAAA,QAFxBC,IAEwB,uEAFP,CAAE,SAAF,EAAa,QAAb,CAEO;AAAA,QADxBC,OACwB,uEADN,cACM;AACxB,WAAOP,YAAY,CAAEI,KAAF,EAASC,OAAT,EAAkBC,IAAlB,EAAwBC,OAAxB,CAAnB;AACA;AATa,CAAf;AAYA,MAAME,YAAY,GAAG;AACpBP,EAAAA,IAAI,EAAE,OADc;AAEpBC,EAAAA,QAAQ,EAAE,UACTC,KADS,EAETC,OAFS,EAKe;AAAA,QAFxBC,IAEwB,uEAFP,CAAE,SAAF,EAAa,OAAb,CAEO;AAAA,QADxBC,OACwB,uEADN,cACM;AACxB,WAAOP,YAAY,CAAEI,KAAF,EAASC,OAAT,EAAkBC,IAAlB,EAAwBC,OAAxB,CAAnB;AACA;AATmB,CAArB;AAYA,MAAMG,KAAK,GAAG;AACbR,EAAAA,IAAI,EAAE,OADO;AAEbC,EAAAA,QAAQ,EAAE,UACTC,KADS,EAETC,OAFS,EAKe;AAAA,QAFxBC,IAEwB,uEAFP,CAAE,SAAF,EAAa,OAAb,CAEO;AAAA,QADxBC,OACwB,uEADN,cACM;AACxB,WAAOP,YAAY,CAAEI,KAAF,EAASC,OAAT,EAAkBC,IAAlB,EAAwBC,OAAxB,CAAnB;AACA;AATY,CAAd;AAYA,eAAe,CAAEN,KAAF,EAASQ,YAAT,EAAuBD,MAAvB,EAA+BE,KAA/B,CAAf","sourcesContent":["/**\n * Internal dependencies\n */\nimport type { GeneratedCSSRule, Style, StyleOptions } from '../../types';\nimport { generateRule } from '../utils';\n\nconst color = {\n\tname: 'color',\n\tgenerate: (\n\t\tstyle: Style,\n\t\toptions: StyleOptions,\n\t\tpath: string[] = [ 'outline', 'color' ],\n\t\truleKey: string = 'outlineColor'\n\t): GeneratedCSSRule[] => {\n\t\treturn generateRule( style, options, path, ruleKey );\n\t},\n};\n\nconst offset = {\n\tname: 'offset',\n\tgenerate: (\n\t\tstyle: Style,\n\t\toptions: StyleOptions,\n\t\tpath: string[] = [ 'outline', 'offset' ],\n\t\truleKey: string = 'outlineColor'\n\t): GeneratedCSSRule[] => {\n\t\treturn generateRule( style, options, path, ruleKey );\n\t},\n};\n\nconst outlineStyle = {\n\tname: 'style',\n\tgenerate: (\n\t\tstyle: Style,\n\t\toptions: StyleOptions,\n\t\tpath: string[] = [ 'outline', 'style' ],\n\t\truleKey: string = 'outlineStyle'\n\t): GeneratedCSSRule[] => {\n\t\treturn generateRule( style, options, path, ruleKey );\n\t},\n};\n\nconst width = {\n\tname: 'width',\n\tgenerate: (\n\t\tstyle: Style,\n\t\toptions: StyleOptions,\n\t\tpath: string[] = [ 'outline', 'width' ],\n\t\truleKey: string = 'outlineWidth'\n\t): GeneratedCSSRule[] => {\n\t\treturn generateRule( style, options, path, ruleKey );\n\t},\n};\n\nexport default [ color, outlineStyle, offset, width ];\n"]}
@@ -1,5 +1,5 @@
1
1
  export declare const styleDefinitions: (import("../types").StyleDefinition | {
2
2
  name: string;
3
- generate: (style: import("../types").Style, options: import("../types").StyleOptions) => import("../types").GeneratedCSSRule[];
3
+ generate: (style: import("../types").Style, options: import("../types").StyleOptions, path?: string[], ruleKey?: string) => import("../types").GeneratedCSSRule[];
4
4
  })[];
5
5
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/styles/index.ts"],"names":[],"mappings":"AASA,eAAO,MAAM,gBAAgB;;;IAM5B,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/styles/index.ts"],"names":[],"mappings":"AAUA,eAAO,MAAM,gBAAgB;;;IAO5B,CAAC"}
@@ -0,0 +1,10 @@
1
+ /**
2
+ * Internal dependencies
3
+ */
4
+ import type { GeneratedCSSRule, Style, StyleOptions } from '../../types';
5
+ declare const _default: {
6
+ name: string;
7
+ generate: (style: Style, options: StyleOptions, path?: string[], ruleKey?: string) => GeneratedCSSRule[];
8
+ }[];
9
+ export default _default;
10
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/styles/outline/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,gBAAgB,EAAE,KAAK,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC;;;;;AAmDzE,wBAAsD"}
@@ -505,13 +505,17 @@ class WP_Style_Engine {
505
505
  * Returns a compiled stylesheet from stored CSS rules.
506
506
  *
507
507
  * @param WP_Style_Engine_CSS_Rule[] $css_rules An array of WP_Style_Engine_CSS_Rule objects from a store or otherwise.
508
+ * @param array $options array(
509
+ * 'optimize' => (boolean) Whether to optimize the CSS output, e.g., combine rules.
510
+ * 'prettify' => (boolean) Whether to add new lines to output.
511
+ * );.
508
512
  *
509
513
  * @return string A compiled stylesheet from stored CSS rules.
510
514
  */
511
- public static function compile_stylesheet_from_css_rules( $css_rules ) {
515
+ public static function compile_stylesheet_from_css_rules( $css_rules, $options = array() ) {
512
516
  $processor = new WP_Style_Engine_Processor();
513
517
  $processor->add_rules( $css_rules );
514
- return $processor->get_css();
518
+ return $processor->get_css( $options );
515
519
  }
516
520
  }
517
521
 
@@ -591,6 +595,8 @@ function wp_style_engine_get_styles( $block_styles, $options = array() ) {
591
595
  * @param array<string> $options array(
592
596
  * 'context' => (string|null) An identifier describing the origin of the style object, e.g., 'block-supports' or 'global-styles'. Default is 'block-supports'.
593
597
  * When set, the style engine will attempt to store the CSS rules.
598
+ * 'optimize' => (boolean) Whether to optimize the CSS output, e.g., combine rules.
599
+ * 'prettify' => (boolean) Whether to add new lines to output.
594
600
  * );.
595
601
  *
596
602
  * @return string A compiled CSS string.
@@ -624,7 +630,7 @@ function wp_style_engine_get_stylesheet_from_css_rules( $css_rules, $options = a
624
630
  return '';
625
631
  }
626
632
 
627
- return WP_Style_Engine::compile_stylesheet_from_css_rules( $css_rule_objects );
633
+ return WP_Style_Engine::compile_stylesheet_from_css_rules( $css_rule_objects, $options );
628
634
  }
629
635
 
630
636
  /**
@@ -633,13 +639,16 @@ function wp_style_engine_get_stylesheet_from_css_rules( $css_rules, $options = a
633
639
  * @access public
634
640
  *
635
641
  * @param string $store_name A valid store name.
636
- *
642
+ * @param array $options array(
643
+ * 'optimize' => (boolean) Whether to optimize the CSS output, e.g., combine rules.
644
+ * 'prettify' => (boolean) Whether to add new lines to output.
645
+ * );.
637
646
  * @return string A compiled CSS string.
638
647
  */
639
- function wp_style_engine_get_stylesheet_from_store( $store_name ) {
648
+ function wp_style_engine_get_stylesheet_from_context( $store_name, $options = array() ) {
640
649
  if ( ! class_exists( 'WP_Style_Engine' ) || empty( $store_name ) ) {
641
650
  return '';
642
651
  }
643
652
 
644
- return WP_Style_Engine::compile_stylesheet_from_css_rules( WP_Style_Engine::get_store( $store_name )->get_all_rules() );
653
+ return WP_Style_Engine::compile_stylesheet_from_css_rules( WP_Style_Engine::get_store( $store_name )->get_all_rules(), $options );
645
654
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wordpress/style-engine",
3
- "version": "0.15.1-next.957ca95e4c.0",
3
+ "version": "0.16.0",
4
4
  "description": "WordPress Style engine.",
5
5
  "author": "The WordPress Contributors",
6
6
  "license": "GPL-2.0-or-later",
@@ -34,5 +34,5 @@
34
34
  "publishConfig": {
35
35
  "access": "public"
36
36
  },
37
- "gitHead": "272a74bbbaab10ee24424eafe9578e705fbfbbb4"
37
+ "gitHead": "0d732d4b184adcb28cc83087603e81b764390d4b"
38
38
  }
@@ -37,7 +37,7 @@ class WP_Style_Engine_Processor_Test extends WP_UnitTestCase {
37
37
  $a_nice_processor->add_rules( array( $a_nice_css_rule, $a_nicer_css_rule ) );
38
38
  $this->assertEquals(
39
39
  '.a-nice-rule{color:var(--nice-color);background-color:purple;}.a-nicer-rule{font-family:Nice sans;font-size:1em;background-color:purple;}',
40
- $a_nice_processor->get_css()
40
+ $a_nice_processor->get_css( array( 'prettify' => false ) )
41
41
  );
42
42
  }
43
43
 
@@ -109,7 +109,7 @@ class WP_Style_Engine_Processor_Test extends WP_UnitTestCase {
109
109
  $a_nice_renderer->add_store( $a_nice_store );
110
110
  $this->assertEquals(
111
111
  '.a-nice-rule{color:var(--nice-color);background-color:purple;}.a-nicer-rule{font-family:Nice sans;font-size:1em;background-color:purple;}',
112
- $a_nice_renderer->get_css()
112
+ $a_nice_renderer->get_css( array( 'prettify' => false ) )
113
113
  );
114
114
  }
115
115
 
@@ -138,7 +138,7 @@ class WP_Style_Engine_Processor_Test extends WP_UnitTestCase {
138
138
  $an_excellent_processor->add_rules( $another_excellent_rule );
139
139
  $this->assertEquals(
140
140
  '.an-excellent-rule{color:var(--excellent-color);border-style:dotted;border-color:brown;}',
141
- $an_excellent_processor->get_css()
141
+ $an_excellent_processor->get_css( array( 'prettify' => false ) )
142
142
  );
143
143
 
144
144
  $yet_another_excellent_rule = new WP_Style_Engine_CSS_Rule( '.an-excellent-rule' );
@@ -152,7 +152,7 @@ class WP_Style_Engine_Processor_Test extends WP_UnitTestCase {
152
152
  $an_excellent_processor->add_rules( $yet_another_excellent_rule );
153
153
  $this->assertEquals(
154
154
  '.an-excellent-rule{color:var(--excellent-color);border-style:dashed;border-color:brown;border-width:2px;}',
155
- $an_excellent_processor->get_css()
155
+ $an_excellent_processor->get_css( array( 'prettify' => false ) )
156
156
  );
157
157
  }
158
158
 
@@ -189,7 +189,12 @@ class WP_Style_Engine_Processor_Test extends WP_UnitTestCase {
189
189
 
190
190
  $this->assertEquals(
191
191
  '.a-sweet-rule{color:var(--sweet-color);background-color:purple;}#an-even-sweeter-rule > marquee{color:var(--sweet-color);background-color:purple;}.the-sweetest-rule-of-all a{color:var(--sweet-color);background-color:purple;}',
192
- $a_sweet_processor->get_css( array( 'optimize' => false ) )
192
+ $a_sweet_processor->get_css(
193
+ array(
194
+ 'optimize' => false,
195
+ 'prettify' => false,
196
+ )
197
+ )
193
198
  );
194
199
  }
195
200
 
@@ -218,7 +223,7 @@ class WP_Style_Engine_Processor_Test extends WP_UnitTestCase {
218
223
 
219
224
  $this->assertEquals(
220
225
  '.a-sweet-rule,#an-even-sweeter-rule > marquee{color:var(--sweet-color);background-color:purple;}',
221
- $a_sweet_processor->get_css()
226
+ $a_sweet_processor->get_css( array( 'prettify' => false ) )
222
227
  );
223
228
  }
224
229
  /**
@@ -240,7 +245,7 @@ class WP_Style_Engine_Processor_Test extends WP_UnitTestCase {
240
245
  )
241
246
  );
242
247
  $a_lovely_processor->add_rules( $a_lovelier_rule );
243
- $this->assertEquals( '.a-lovely-rule,.a-lovelier-rule{border-color:purple;}', $a_lovely_processor->get_css() );
248
+ $this->assertEquals( '.a-lovely-rule,.a-lovelier-rule{border-color:purple;}', $a_lovely_processor->get_css( array( 'prettify' => false ) ) );
244
249
 
245
250
  $a_most_lovely_rule = new WP_Style_Engine_CSS_Rule(
246
251
  '.a-most-lovely-rule',
@@ -260,7 +265,7 @@ class WP_Style_Engine_Processor_Test extends WP_UnitTestCase {
260
265
 
261
266
  $this->assertEquals(
262
267
  '.a-lovely-rule,.a-lovelier-rule,.a-most-lovely-rule,.a-perfectly-lovely-rule{border-color:purple;}',
263
- $a_lovely_processor->get_css()
268
+ $a_lovely_processor->get_css( array( 'prettify' => false ) )
264
269
  );
265
270
  }
266
271
  }
@@ -612,7 +612,7 @@ class WP_Style_Engine_Test extends WP_UnitTestCase {
612
612
  ),
613
613
  );
614
614
 
615
- $compiled_stylesheet = wp_style_engine_get_stylesheet_from_css_rules( $css_rules );
615
+ $compiled_stylesheet = wp_style_engine_get_stylesheet_from_css_rules( $css_rules, array( 'prettify' => false ) );
616
616
  $this->assertSame( '.saruman{color:white;height:100px;border-style:solid;align-self:unset;}.gandalf{color:grey;height:90px;border-style:dotted;align-self:safe center;}.radagast{color:brown;height:60px;border-style:dashed;align-self:stretch;}', $compiled_stylesheet );
617
617
  }
618
618
 
@@ -656,7 +656,7 @@ class WP_Style_Engine_Test extends WP_UnitTestCase {
656
656
  ),
657
657
  );
658
658
 
659
- $compiled_stylesheet = wp_style_engine_get_stylesheet_from_css_rules( $css_rules );
659
+ $compiled_stylesheet = wp_style_engine_get_stylesheet_from_css_rules( $css_rules, array( 'prettify' => false ) );
660
660
  $this->assertSame( '.gandalf{color:white;height:190px;border-style:dotted;padding:10px;margin-bottom:100px;}.dumbledore,.rincewind{color:grey;height:90px;border-style:dotted;}', $compiled_stylesheet );
661
661
  }
662
662
  }
@@ -4,12 +4,14 @@
4
4
  import border from './border';
5
5
  import color from './color';
6
6
  import shadow from './shadow';
7
+ import outline from './outline';
7
8
  import spacing from './spacing';
8
9
  import typography from './typography';
9
10
 
10
11
  export const styleDefinitions = [
11
12
  ...border,
12
13
  ...color,
14
+ ...outline,
13
15
  ...spacing,
14
16
  ...typography,
15
17
  ...shadow,
@@ -0,0 +1,55 @@
1
+ /**
2
+ * Internal dependencies
3
+ */
4
+ import type { GeneratedCSSRule, Style, StyleOptions } from '../../types';
5
+ import { generateRule } from '../utils';
6
+
7
+ const color = {
8
+ name: 'color',
9
+ generate: (
10
+ style: Style,
11
+ options: StyleOptions,
12
+ path: string[] = [ 'outline', 'color' ],
13
+ ruleKey: string = 'outlineColor'
14
+ ): GeneratedCSSRule[] => {
15
+ return generateRule( style, options, path, ruleKey );
16
+ },
17
+ };
18
+
19
+ const offset = {
20
+ name: 'offset',
21
+ generate: (
22
+ style: Style,
23
+ options: StyleOptions,
24
+ path: string[] = [ 'outline', 'offset' ],
25
+ ruleKey: string = 'outlineColor'
26
+ ): GeneratedCSSRule[] => {
27
+ return generateRule( style, options, path, ruleKey );
28
+ },
29
+ };
30
+
31
+ const outlineStyle = {
32
+ name: 'style',
33
+ generate: (
34
+ style: Style,
35
+ options: StyleOptions,
36
+ path: string[] = [ 'outline', 'style' ],
37
+ ruleKey: string = 'outlineStyle'
38
+ ): GeneratedCSSRule[] => {
39
+ return generateRule( style, options, path, ruleKey );
40
+ },
41
+ };
42
+
43
+ const width = {
44
+ name: 'width',
45
+ generate: (
46
+ style: Style,
47
+ options: StyleOptions,
48
+ path: string[] = [ 'outline', 'width' ],
49
+ ruleKey: string = 'outlineWidth'
50
+ ): GeneratedCSSRule[] => {
51
+ return generateRule( style, options, path, ruleKey );
52
+ },
53
+ };
54
+
55
+ export default [ color, outlineStyle, offset, width ];
@@ -1 +1 @@
1
- {"program":{"fileNames":["../../node_modules/typescript/lib/lib.es5.d.ts","../../node_modules/typescript/lib/lib.es2015.d.ts","../../node_modules/typescript/lib/lib.es2016.d.ts","../../node_modules/typescript/lib/lib.es2017.d.ts","../../node_modules/typescript/lib/lib.es2018.d.ts","../../node_modules/typescript/lib/lib.es2019.d.ts","../../node_modules/typescript/lib/lib.es2020.d.ts","../../node_modules/typescript/lib/lib.es2021.d.ts","../../node_modules/typescript/lib/lib.esnext.d.ts","../../node_modules/typescript/lib/lib.dom.d.ts","../../node_modules/typescript/lib/lib.es2015.core.d.ts","../../node_modules/typescript/lib/lib.es2015.collection.d.ts","../../node_modules/typescript/lib/lib.es2015.generator.d.ts","../../node_modules/typescript/lib/lib.es2015.iterable.d.ts","../../node_modules/typescript/lib/lib.es2015.promise.d.ts","../../node_modules/typescript/lib/lib.es2015.proxy.d.ts","../../node_modules/typescript/lib/lib.es2015.reflect.d.ts","../../node_modules/typescript/lib/lib.es2015.symbol.d.ts","../../node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts","../../node_modules/typescript/lib/lib.es2016.array.include.d.ts","../../node_modules/typescript/lib/lib.es2017.object.d.ts","../../node_modules/typescript/lib/lib.es2017.sharedmemory.d.ts","../../node_modules/typescript/lib/lib.es2017.string.d.ts","../../node_modules/typescript/lib/lib.es2017.intl.d.ts","../../node_modules/typescript/lib/lib.es2017.typedarrays.d.ts","../../node_modules/typescript/lib/lib.es2018.asyncgenerator.d.ts","../../node_modules/typescript/lib/lib.es2018.asynciterable.d.ts","../../node_modules/typescript/lib/lib.es2018.intl.d.ts","../../node_modules/typescript/lib/lib.es2018.promise.d.ts","../../node_modules/typescript/lib/lib.es2018.regexp.d.ts","../../node_modules/typescript/lib/lib.es2019.array.d.ts","../../node_modules/typescript/lib/lib.es2019.object.d.ts","../../node_modules/typescript/lib/lib.es2019.string.d.ts","../../node_modules/typescript/lib/lib.es2019.symbol.d.ts","../../node_modules/typescript/lib/lib.es2020.bigint.d.ts","../../node_modules/typescript/lib/lib.es2020.promise.d.ts","../../node_modules/typescript/lib/lib.es2020.sharedmemory.d.ts","../../node_modules/typescript/lib/lib.es2020.string.d.ts","../../node_modules/typescript/lib/lib.es2020.symbol.wellknown.d.ts","../../node_modules/typescript/lib/lib.es2020.intl.d.ts","../../node_modules/typescript/lib/lib.es2021.promise.d.ts","../../node_modules/typescript/lib/lib.es2021.string.d.ts","../../node_modules/typescript/lib/lib.es2021.weakref.d.ts","../../node_modules/typescript/lib/lib.esnext.intl.d.ts","../../node_modules/@types/lodash/common/common.d.ts","../../node_modules/@types/lodash/common/array.d.ts","../../node_modules/@types/lodash/common/collection.d.ts","../../node_modules/@types/lodash/common/date.d.ts","../../node_modules/@types/lodash/common/function.d.ts","../../node_modules/@types/lodash/common/lang.d.ts","../../node_modules/@types/lodash/common/math.d.ts","../../node_modules/@types/lodash/common/number.d.ts","../../node_modules/@types/lodash/common/object.d.ts","../../node_modules/@types/lodash/common/seq.d.ts","../../node_modules/@types/lodash/common/string.d.ts","../../node_modules/@types/lodash/common/util.d.ts","../../node_modules/@types/lodash/index.d.ts","../../node_modules/@types/react/global.d.ts","../../node_modules/@types/react/node_modules/csstype/index.d.ts","../../node_modules/@types/prop-types/index.d.ts","../../node_modules/@types/scheduler/tracing.d.ts","../../node_modules/@types/react/index.d.ts","./src/types.ts","./src/styles/constants.ts","./src/styles/utils.ts","./src/styles/border/index.ts","./src/styles/color/background.ts","./src/styles/color/gradient.ts","./src/styles/color/text.ts","./src/styles/color/index.ts","./src/styles/shadow/index.ts","./src/styles/spacing/padding.ts","./src/styles/spacing/margin.ts","./src/styles/spacing/index.ts","./src/styles/typography/index.ts","./src/styles/index.ts","./src/index.ts"],"fileInfos":[{"version":"aa9fb4c70f369237c2f45f9d969c9a59e0eae9a192962eb48581fe864aa609db","affectsGlobalScope":true},"dc47c4fa66b9b9890cf076304de2a9c5201e94b740cffdf09f87296d877d71f6","7a387c58583dfca701b6c85e0adaf43fb17d590fb16d5b2dc0a2fbd89f35c467","8a12173c586e95f4433e0c6dc446bc88346be73ffe9ca6eec7aa63c8f3dca7f9","5f4e733ced4e129482ae2186aae29fde948ab7182844c3a5a51dd346182c7b06","e6b724280c694a9f588847f754198fb96c43d805f065c3a5b28bbc9594541c84","e21c071ca3e1b4a815d5f04a7475adcaeea5d64367e840dd0154096d705c3940","eb75e89d63b3b72dd9ca8b0cac801cecae5be352307c004adeaa60bc9d6df51f","2cc028cd0bdb35b1b5eb723d84666a255933fffbea607f72cbd0c7c7b4bee144",{"version":"e54c8715a4954cfdc66cd69489f2b725c09ebf37492dbd91cff0a1688b1159e8","affectsGlobalScope":true},{"version":"51b8b27c21c066bf877646e320bf6a722b80d1ade65e686923cd9d4494aef1ca","affectsGlobalScope":true},{"version":"43fb1d932e4966a39a41b464a12a81899d9ae5f2c829063f5571b6b87e6d2f9c","affectsGlobalScope":true},{"version":"cdccba9a388c2ee3fd6ad4018c640a471a6c060e96f1232062223063b0a5ac6a","affectsGlobalScope":true},{"version":"2c8c5ee58f30e7c944e04ab1fb5506fdbb4dd507c9efa6972cf4b91cec90c503","affectsGlobalScope":true},{"version":"2bb4b3927299434052b37851a47bf5c39764f2ba88a888a107b32262e9292b7c","affectsGlobalScope":true},{"version":"810627a82ac06fb5166da5ada4159c4ec11978dfbb0805fe804c86406dab8357","affectsGlobalScope":true},{"version":"62d80405c46c3f4c527ee657ae9d43fda65a0bf582292429aea1e69144a522a6","affectsGlobalScope":true},{"version":"3013574108c36fd3aaca79764002b3717da09725a36a6fc02eac386593110f93","affectsGlobalScope":true},{"version":"75ec0bdd727d887f1b79ed6619412ea72ba3c81d92d0787ccb64bab18d261f14","affectsGlobalScope":true},{"version":"3be5a1453daa63e031d266bf342f3943603873d890ab8b9ada95e22389389006","affectsGlobalScope":true},{"version":"17bb1fc99591b00515502d264fa55dc8370c45c5298f4a5c2083557dccba5a2a","affectsGlobalScope":true},{"version":"7ce9f0bde3307ca1f944119f6365f2d776d281a393b576a18a2f2893a2d75c98","affectsGlobalScope":true},{"version":"6a6b173e739a6a99629a8594bfb294cc7329bfb7b227f12e1f7c11bc163b8577","affectsGlobalScope":true},{"version":"12a310447c5d23c7d0d5ca2af606e3bd08afda69100166730ab92c62999ebb9d","affectsGlobalScope":true},{"version":"b0124885ef82641903d232172577f2ceb5d3e60aed4da1153bab4221e1f6dd4e","affectsGlobalScope":true},{"version":"0eb85d6c590b0d577919a79e0084fa1744c1beba6fd0d4e951432fa1ede5510a","affectsGlobalScope":true},{"version":"da233fc1c8a377ba9e0bed690a73c290d843c2c3d23a7bd7ec5cd3d7d73ba1e0","affectsGlobalScope":true},{"version":"df9c8a72ca8b0ed62f5470b41208a0587f0f73f0a7db28e5a1272cf92537518e","affectsGlobalScope":true},{"version":"bb2d3fb05a1d2ffbca947cc7cbc95d23e1d053d6595391bd325deb265a18d36c","affectsGlobalScope":true},{"version":"c80df75850fea5caa2afe43b9949338ce4e2de086f91713e9af1a06f973872b8","affectsGlobalScope":true},{"version":"9d57b2b5d15838ed094aa9ff1299eecef40b190722eb619bac4616657a05f951","affectsGlobalScope":true},{"version":"6c51b5dd26a2c31dbf37f00cfc32b2aa6a92e19c995aefb5b97a3a64f1ac99de","affectsGlobalScope":true},{"version":"93544ca2f26a48716c1b6c5091842cad63129daac422dfa4bc52460465f22bb1","affectsGlobalScope":true},{"version":"2ad234885a4240522efccd77de6c7d99eecf9b4de0914adb9a35c0c22433f993","affectsGlobalScope":true},{"version":"1b3fe904465430e030c93239a348f05e1be80640d91f2f004c3512c2c2c89f34","affectsGlobalScope":true},{"version":"7435b75fdf3509622e79622dbe5091cf4b09688410ee2034e4fc17d0c99d0862","affectsGlobalScope":true},{"version":"e7e8e1d368290e9295ef18ca23f405cf40d5456fa9f20db6373a61ca45f75f40","affectsGlobalScope":true},{"version":"faf0221ae0465363c842ce6aa8a0cbda5d9296940a8e26c86e04cc4081eea21e","affectsGlobalScope":true},{"version":"06393d13ea207a1bfe08ec8d7be562549c5e2da8983f2ee074e00002629d1871","affectsGlobalScope":true},{"version":"9f1817f7c3f02f6d56e0f403b927e90bb133f371dcebc36fa7d6d208ef6899da","affectsGlobalScope":true},{"version":"cd6efb9467a8b6338ece2e2855e37765700f2cd061ca54b01b33878cf5c7677e","affectsGlobalScope":true},{"version":"fb4416144c1bf0323ccbc9afb0ab289c07312214e8820ad17d709498c865a3fe","affectsGlobalScope":true},{"version":"5b0ca94ec819d68d33da516306c15297acec88efeb0ae9e2b39f71dbd9685ef7","affectsGlobalScope":true},{"version":"4632665b87204bb1caa8b44d165bce0c50dfab177df5b561b345a567cabacf9a","affectsGlobalScope":true},"675e702f2032766a91eeadee64f51014c64688525da99dccd8178f0c599f13a8","438284c7c455a29b9c0e2d1e72abc62ee93d9a163029ffe918a34c5db3b92da2","0c75b204aed9cf6ff1c7b4bed87a3ece0d9d6fc857a6350c0c95ed0c38c814e8","187119ff4f9553676a884e296089e131e8cc01691c546273b1d0089c3533ce42","c24ad9be9adf28f0927e3d9d9e9cec1c677022356f241ccbbfb97bfe8fb3d1a1","0ec0998e2d085e8ea54266f547976ae152c9dd6cdb9ac4d8a520a230f5ebae84","9364c7566b0be2f7b70ff5285eb34686f83ccb01bda529b82d23b2a844653bfb","00baffbe8a2f2e4875367479489b5d43b5fc1429ecb4a4cc98cfc3009095f52a","82251920b05f30981c9a4109cb5f3169dce4b477effc845c6d781044a30e7672","3c92b6dfd43cc1c2485d9eba5ff0b74a19bb8725b692773ef1d66dac48cda4bd","3e59f00ab03c33717b3130066d4debb272da90eeded4935ff0604c2bc25a5cae","9fa6b83a35e897f340858995ca5d77e901d89fd18644cd4c9e8a4afe0b2e6363",{"version":"0714e2046df66c0e93c3330d30dbc0565b3e8cd3ee302cf99e4ede6220e5fec8","affectsGlobalScope":true},{"version":"ecf78e637f710f340ec08d5d92b3f31b134a46a4fcf2e758690d8c46ce62cba6","affectsGlobalScope":true},"381899b8d1d4c1be716f18cb5242ba39f66f4b1e31d45af62a32a99f8edcb39d","f7b46d22a307739c145e5fddf537818038fdfffd580d79ed717f4d4d37249380","f5a8b384f182b3851cec3596ccc96cb7464f8d3469f48c74bf2befb782a19de5",{"version":"1bc82f5b3bb93df76d19730c84467b0b346187198537135d63a672956f323720","affectsGlobalScope":true},"8e48d645663797109ba89566cae1d06a5c8a0d7e6fecc83589c243a4410adbf8","301543eebfdd2fc5e5d6d928c5ed3f65bd377e95d184eb1351df5fe38ef9eac0","64db6f93189a8ece82eb8a2265338a3297c69e9ea34a692edd97f216aaaf2692","1fa9eb4c782532dc5d216edc97194d451e75bbdc6cf0b7ec2fad623e453bb6e3","49dec6685c69b84a795d1e2c2a8d7ac8953efb4a7dadb9b1b04c836053e0ea21","8cbcd8c85fe3627d4c9e75ccf2784b7e4d0082396600e9d432f1cd61009a7933","f303eb9a884f47802f08d6b1d376c737856c29783532a44116bfc7e4929a7204","e8dc9f16ad89ba54f1e7202369a69a265ccd5eec0df39cf429ff1a941603d4da","51f25b3291c4ca38c72cb150453eb2961bb0ca2891102719064e2a695c47a55a","caa45d96bc56c4f2ea6dfbe715413636f0d8b74121a8820b70526a3ae1bfd9b9","3d0705f37a3de49d9210d2656cd697ae0cd93476a7e60f7b099797166e4d78b0","b7003bd91d5a0b8bf84a3ef07a0cf5a4b8e0cef58d9e6404f54f05fd4ed6f0b2","f663bea39fe633f8875848f18196303c24fe9d039549ae750c0d6e3bd9571032","e3919c55fa8f6858bf9374d50ab4bd6d44f5ca398efb068658292c44372b2456","ed40d027865f44d58e94e1cd791091a96efa5ea1a3dd7fe4f996e95e4f51fe2a"],"options":{"allowSyntheticDefaultImports":true,"composite":true,"declaration":true,"declarationDir":"./build-types","declarationMap":true,"emitDeclarationOnly":true,"esModuleInterop":false,"importsNotUsedAsValues":2,"jsx":1,"module":99,"noFallthroughCasesInSwitch":true,"noImplicitReturns":true,"noUnusedLocals":true,"noUnusedParameters":true,"rootDir":"./src","strict":true,"target":99},"fileIdsList":[[45,47,48,49,50,51,52,53,54,55,56,57],[45,46,48,49,50,51,52,53,54,55,56,57],[46,47,48,49,50,51,52,53,54,55,56,57],[45,46,47,49,50,51,52,53,54,55,56,57],[45,46,47,48,50,51,52,53,54,55,56,57],[45,46,47,48,49,51,52,53,54,55,56,57],[45,46,47,48,49,50,52,53,54,55,56,57],[45,46,47,48,49,50,51,53,54,55,56,57],[45,46,47,48,49,50,51,52,54,55,56,57],[45,46,47,48,49,50,51,52,53,55,56,57],[45,46,47,48,49,50,51,52,53,54,56,57],[45,46,47,48,49,50,51,52,53,54,55,57],[45,46,47,48,49,50,51,52,53,54,55,56],[58,59,60,61],[57,63,76],[63,65],[67,68,69],[66,70,71,74,75],[72,73],[57,63,64],[62]],"referencedMap":[[46,1],[47,2],[45,3],[48,4],[49,5],[50,6],[51,7],[52,8],[53,9],[54,10],[55,11],[56,12],[57,13],[62,14],[77,15],[66,16],[67,16],[68,16],[70,17],[69,16],[76,18],[71,16],[74,19],[73,16],[72,16],[75,16],[65,20],[63,21]],"exportedModulesMap":[[46,1],[47,2],[45,3],[48,4],[49,5],[50,6],[51,7],[52,8],[53,9],[54,10],[55,11],[56,12],[57,13],[62,14],[77,15],[66,16],[67,16],[68,16],[70,17],[69,16],[76,18],[71,16],[74,19],[73,16],[72,16],[75,16],[65,20],[63,21]],"semanticDiagnosticsPerFile":[46,47,45,48,49,50,51,52,53,54,55,56,57,60,58,62,59,61,10,12,11,2,13,14,15,16,17,18,19,20,3,4,24,21,22,23,25,26,27,5,28,29,30,31,6,32,33,34,35,7,40,36,37,38,39,8,41,42,43,1,9,44,77,66,67,68,70,69,64,76,71,74,73,72,75,65,63]},"version":"4.4.2"}
1
+ {"program":{"fileNames":["../../node_modules/typescript/lib/lib.es5.d.ts","../../node_modules/typescript/lib/lib.es2015.d.ts","../../node_modules/typescript/lib/lib.es2016.d.ts","../../node_modules/typescript/lib/lib.es2017.d.ts","../../node_modules/typescript/lib/lib.es2018.d.ts","../../node_modules/typescript/lib/lib.es2019.d.ts","../../node_modules/typescript/lib/lib.es2020.d.ts","../../node_modules/typescript/lib/lib.es2021.d.ts","../../node_modules/typescript/lib/lib.esnext.d.ts","../../node_modules/typescript/lib/lib.dom.d.ts","../../node_modules/typescript/lib/lib.es2015.core.d.ts","../../node_modules/typescript/lib/lib.es2015.collection.d.ts","../../node_modules/typescript/lib/lib.es2015.generator.d.ts","../../node_modules/typescript/lib/lib.es2015.iterable.d.ts","../../node_modules/typescript/lib/lib.es2015.promise.d.ts","../../node_modules/typescript/lib/lib.es2015.proxy.d.ts","../../node_modules/typescript/lib/lib.es2015.reflect.d.ts","../../node_modules/typescript/lib/lib.es2015.symbol.d.ts","../../node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts","../../node_modules/typescript/lib/lib.es2016.array.include.d.ts","../../node_modules/typescript/lib/lib.es2017.object.d.ts","../../node_modules/typescript/lib/lib.es2017.sharedmemory.d.ts","../../node_modules/typescript/lib/lib.es2017.string.d.ts","../../node_modules/typescript/lib/lib.es2017.intl.d.ts","../../node_modules/typescript/lib/lib.es2017.typedarrays.d.ts","../../node_modules/typescript/lib/lib.es2018.asyncgenerator.d.ts","../../node_modules/typescript/lib/lib.es2018.asynciterable.d.ts","../../node_modules/typescript/lib/lib.es2018.intl.d.ts","../../node_modules/typescript/lib/lib.es2018.promise.d.ts","../../node_modules/typescript/lib/lib.es2018.regexp.d.ts","../../node_modules/typescript/lib/lib.es2019.array.d.ts","../../node_modules/typescript/lib/lib.es2019.object.d.ts","../../node_modules/typescript/lib/lib.es2019.string.d.ts","../../node_modules/typescript/lib/lib.es2019.symbol.d.ts","../../node_modules/typescript/lib/lib.es2020.bigint.d.ts","../../node_modules/typescript/lib/lib.es2020.promise.d.ts","../../node_modules/typescript/lib/lib.es2020.sharedmemory.d.ts","../../node_modules/typescript/lib/lib.es2020.string.d.ts","../../node_modules/typescript/lib/lib.es2020.symbol.wellknown.d.ts","../../node_modules/typescript/lib/lib.es2020.intl.d.ts","../../node_modules/typescript/lib/lib.es2021.promise.d.ts","../../node_modules/typescript/lib/lib.es2021.string.d.ts","../../node_modules/typescript/lib/lib.es2021.weakref.d.ts","../../node_modules/typescript/lib/lib.esnext.intl.d.ts","../../node_modules/@types/lodash/common/common.d.ts","../../node_modules/@types/lodash/common/array.d.ts","../../node_modules/@types/lodash/common/collection.d.ts","../../node_modules/@types/lodash/common/date.d.ts","../../node_modules/@types/lodash/common/function.d.ts","../../node_modules/@types/lodash/common/lang.d.ts","../../node_modules/@types/lodash/common/math.d.ts","../../node_modules/@types/lodash/common/number.d.ts","../../node_modules/@types/lodash/common/object.d.ts","../../node_modules/@types/lodash/common/seq.d.ts","../../node_modules/@types/lodash/common/string.d.ts","../../node_modules/@types/lodash/common/util.d.ts","../../node_modules/@types/lodash/index.d.ts","../../node_modules/@types/react/global.d.ts","../../node_modules/@types/react/node_modules/csstype/index.d.ts","../../node_modules/@types/prop-types/index.d.ts","../../node_modules/@types/scheduler/tracing.d.ts","../../node_modules/@types/react/index.d.ts","./src/types.ts","./src/styles/constants.ts","./src/styles/utils.ts","./src/styles/border/index.ts","./src/styles/color/background.ts","./src/styles/color/gradient.ts","./src/styles/color/text.ts","./src/styles/color/index.ts","./src/styles/shadow/index.ts","./src/styles/outline/index.ts","./src/styles/spacing/padding.ts","./src/styles/spacing/margin.ts","./src/styles/spacing/index.ts","./src/styles/typography/index.ts","./src/styles/index.ts","./src/index.ts"],"fileInfos":[{"version":"aa9fb4c70f369237c2f45f9d969c9a59e0eae9a192962eb48581fe864aa609db","affectsGlobalScope":true},"dc47c4fa66b9b9890cf076304de2a9c5201e94b740cffdf09f87296d877d71f6","7a387c58583dfca701b6c85e0adaf43fb17d590fb16d5b2dc0a2fbd89f35c467","8a12173c586e95f4433e0c6dc446bc88346be73ffe9ca6eec7aa63c8f3dca7f9","5f4e733ced4e129482ae2186aae29fde948ab7182844c3a5a51dd346182c7b06","e6b724280c694a9f588847f754198fb96c43d805f065c3a5b28bbc9594541c84","e21c071ca3e1b4a815d5f04a7475adcaeea5d64367e840dd0154096d705c3940","eb75e89d63b3b72dd9ca8b0cac801cecae5be352307c004adeaa60bc9d6df51f","2cc028cd0bdb35b1b5eb723d84666a255933fffbea607f72cbd0c7c7b4bee144",{"version":"e54c8715a4954cfdc66cd69489f2b725c09ebf37492dbd91cff0a1688b1159e8","affectsGlobalScope":true},{"version":"51b8b27c21c066bf877646e320bf6a722b80d1ade65e686923cd9d4494aef1ca","affectsGlobalScope":true},{"version":"43fb1d932e4966a39a41b464a12a81899d9ae5f2c829063f5571b6b87e6d2f9c","affectsGlobalScope":true},{"version":"cdccba9a388c2ee3fd6ad4018c640a471a6c060e96f1232062223063b0a5ac6a","affectsGlobalScope":true},{"version":"2c8c5ee58f30e7c944e04ab1fb5506fdbb4dd507c9efa6972cf4b91cec90c503","affectsGlobalScope":true},{"version":"2bb4b3927299434052b37851a47bf5c39764f2ba88a888a107b32262e9292b7c","affectsGlobalScope":true},{"version":"810627a82ac06fb5166da5ada4159c4ec11978dfbb0805fe804c86406dab8357","affectsGlobalScope":true},{"version":"62d80405c46c3f4c527ee657ae9d43fda65a0bf582292429aea1e69144a522a6","affectsGlobalScope":true},{"version":"3013574108c36fd3aaca79764002b3717da09725a36a6fc02eac386593110f93","affectsGlobalScope":true},{"version":"75ec0bdd727d887f1b79ed6619412ea72ba3c81d92d0787ccb64bab18d261f14","affectsGlobalScope":true},{"version":"3be5a1453daa63e031d266bf342f3943603873d890ab8b9ada95e22389389006","affectsGlobalScope":true},{"version":"17bb1fc99591b00515502d264fa55dc8370c45c5298f4a5c2083557dccba5a2a","affectsGlobalScope":true},{"version":"7ce9f0bde3307ca1f944119f6365f2d776d281a393b576a18a2f2893a2d75c98","affectsGlobalScope":true},{"version":"6a6b173e739a6a99629a8594bfb294cc7329bfb7b227f12e1f7c11bc163b8577","affectsGlobalScope":true},{"version":"12a310447c5d23c7d0d5ca2af606e3bd08afda69100166730ab92c62999ebb9d","affectsGlobalScope":true},{"version":"b0124885ef82641903d232172577f2ceb5d3e60aed4da1153bab4221e1f6dd4e","affectsGlobalScope":true},{"version":"0eb85d6c590b0d577919a79e0084fa1744c1beba6fd0d4e951432fa1ede5510a","affectsGlobalScope":true},{"version":"da233fc1c8a377ba9e0bed690a73c290d843c2c3d23a7bd7ec5cd3d7d73ba1e0","affectsGlobalScope":true},{"version":"df9c8a72ca8b0ed62f5470b41208a0587f0f73f0a7db28e5a1272cf92537518e","affectsGlobalScope":true},{"version":"bb2d3fb05a1d2ffbca947cc7cbc95d23e1d053d6595391bd325deb265a18d36c","affectsGlobalScope":true},{"version":"c80df75850fea5caa2afe43b9949338ce4e2de086f91713e9af1a06f973872b8","affectsGlobalScope":true},{"version":"9d57b2b5d15838ed094aa9ff1299eecef40b190722eb619bac4616657a05f951","affectsGlobalScope":true},{"version":"6c51b5dd26a2c31dbf37f00cfc32b2aa6a92e19c995aefb5b97a3a64f1ac99de","affectsGlobalScope":true},{"version":"93544ca2f26a48716c1b6c5091842cad63129daac422dfa4bc52460465f22bb1","affectsGlobalScope":true},{"version":"2ad234885a4240522efccd77de6c7d99eecf9b4de0914adb9a35c0c22433f993","affectsGlobalScope":true},{"version":"1b3fe904465430e030c93239a348f05e1be80640d91f2f004c3512c2c2c89f34","affectsGlobalScope":true},{"version":"7435b75fdf3509622e79622dbe5091cf4b09688410ee2034e4fc17d0c99d0862","affectsGlobalScope":true},{"version":"e7e8e1d368290e9295ef18ca23f405cf40d5456fa9f20db6373a61ca45f75f40","affectsGlobalScope":true},{"version":"faf0221ae0465363c842ce6aa8a0cbda5d9296940a8e26c86e04cc4081eea21e","affectsGlobalScope":true},{"version":"06393d13ea207a1bfe08ec8d7be562549c5e2da8983f2ee074e00002629d1871","affectsGlobalScope":true},{"version":"9f1817f7c3f02f6d56e0f403b927e90bb133f371dcebc36fa7d6d208ef6899da","affectsGlobalScope":true},{"version":"cd6efb9467a8b6338ece2e2855e37765700f2cd061ca54b01b33878cf5c7677e","affectsGlobalScope":true},{"version":"fb4416144c1bf0323ccbc9afb0ab289c07312214e8820ad17d709498c865a3fe","affectsGlobalScope":true},{"version":"5b0ca94ec819d68d33da516306c15297acec88efeb0ae9e2b39f71dbd9685ef7","affectsGlobalScope":true},{"version":"4632665b87204bb1caa8b44d165bce0c50dfab177df5b561b345a567cabacf9a","affectsGlobalScope":true},"675e702f2032766a91eeadee64f51014c64688525da99dccd8178f0c599f13a8","438284c7c455a29b9c0e2d1e72abc62ee93d9a163029ffe918a34c5db3b92da2","0c75b204aed9cf6ff1c7b4bed87a3ece0d9d6fc857a6350c0c95ed0c38c814e8","187119ff4f9553676a884e296089e131e8cc01691c546273b1d0089c3533ce42","c24ad9be9adf28f0927e3d9d9e9cec1c677022356f241ccbbfb97bfe8fb3d1a1","0ec0998e2d085e8ea54266f547976ae152c9dd6cdb9ac4d8a520a230f5ebae84","9364c7566b0be2f7b70ff5285eb34686f83ccb01bda529b82d23b2a844653bfb","00baffbe8a2f2e4875367479489b5d43b5fc1429ecb4a4cc98cfc3009095f52a","82251920b05f30981c9a4109cb5f3169dce4b477effc845c6d781044a30e7672","3c92b6dfd43cc1c2485d9eba5ff0b74a19bb8725b692773ef1d66dac48cda4bd","3e59f00ab03c33717b3130066d4debb272da90eeded4935ff0604c2bc25a5cae","9fa6b83a35e897f340858995ca5d77e901d89fd18644cd4c9e8a4afe0b2e6363",{"version":"0714e2046df66c0e93c3330d30dbc0565b3e8cd3ee302cf99e4ede6220e5fec8","affectsGlobalScope":true},{"version":"ecf78e637f710f340ec08d5d92b3f31b134a46a4fcf2e758690d8c46ce62cba6","affectsGlobalScope":true},"381899b8d1d4c1be716f18cb5242ba39f66f4b1e31d45af62a32a99f8edcb39d","f7b46d22a307739c145e5fddf537818038fdfffd580d79ed717f4d4d37249380","f5a8b384f182b3851cec3596ccc96cb7464f8d3469f48c74bf2befb782a19de5",{"version":"1bc82f5b3bb93df76d19730c84467b0b346187198537135d63a672956f323720","affectsGlobalScope":true},"8e48d645663797109ba89566cae1d06a5c8a0d7e6fecc83589c243a4410adbf8","301543eebfdd2fc5e5d6d928c5ed3f65bd377e95d184eb1351df5fe38ef9eac0","64db6f93189a8ece82eb8a2265338a3297c69e9ea34a692edd97f216aaaf2692","1fa9eb4c782532dc5d216edc97194d451e75bbdc6cf0b7ec2fad623e453bb6e3","49dec6685c69b84a795d1e2c2a8d7ac8953efb4a7dadb9b1b04c836053e0ea21","8cbcd8c85fe3627d4c9e75ccf2784b7e4d0082396600e9d432f1cd61009a7933","f303eb9a884f47802f08d6b1d376c737856c29783532a44116bfc7e4929a7204","e8dc9f16ad89ba54f1e7202369a69a265ccd5eec0df39cf429ff1a941603d4da","51f25b3291c4ca38c72cb150453eb2961bb0ca2891102719064e2a695c47a55a","b9494715addecd488c8424333bdcb21390262ce9e7a5c244009e2ea21328181a","caa45d96bc56c4f2ea6dfbe715413636f0d8b74121a8820b70526a3ae1bfd9b9","3d0705f37a3de49d9210d2656cd697ae0cd93476a7e60f7b099797166e4d78b0","b7003bd91d5a0b8bf84a3ef07a0cf5a4b8e0cef58d9e6404f54f05fd4ed6f0b2","f663bea39fe633f8875848f18196303c24fe9d039549ae750c0d6e3bd9571032","1d74aab11e4f2e9bf4eff69b158bff07261a20cd45606cad289852365eb1c23a","ed40d027865f44d58e94e1cd791091a96efa5ea1a3dd7fe4f996e95e4f51fe2a"],"options":{"allowSyntheticDefaultImports":true,"composite":true,"declaration":true,"declarationDir":"./build-types","declarationMap":true,"emitDeclarationOnly":true,"esModuleInterop":false,"importsNotUsedAsValues":2,"jsx":1,"module":99,"noFallthroughCasesInSwitch":true,"noImplicitReturns":true,"noUnusedLocals":true,"noUnusedParameters":true,"rootDir":"./src","strict":true,"target":99},"fileIdsList":[[45,47,48,49,50,51,52,53,54,55,56,57],[45,46,48,49,50,51,52,53,54,55,56,57],[46,47,48,49,50,51,52,53,54,55,56,57],[45,46,47,49,50,51,52,53,54,55,56,57],[45,46,47,48,50,51,52,53,54,55,56,57],[45,46,47,48,49,51,52,53,54,55,56,57],[45,46,47,48,49,50,52,53,54,55,56,57],[45,46,47,48,49,50,51,53,54,55,56,57],[45,46,47,48,49,50,51,52,54,55,56,57],[45,46,47,48,49,50,51,52,53,55,56,57],[45,46,47,48,49,50,51,52,53,54,56,57],[45,46,47,48,49,50,51,52,53,54,55,57],[45,46,47,48,49,50,51,52,53,54,55,56],[58,59,60,61],[57,63,77],[63,65],[67,68,69],[66,70,71,72,75,76],[73,74],[57,63,64],[62]],"referencedMap":[[46,1],[47,2],[45,3],[48,4],[49,5],[50,6],[51,7],[52,8],[53,9],[54,10],[55,11],[56,12],[57,13],[62,14],[78,15],[66,16],[67,16],[68,16],[70,17],[69,16],[77,18],[72,16],[71,16],[75,19],[74,16],[73,16],[76,16],[65,20],[63,21]],"exportedModulesMap":[[46,1],[47,2],[45,3],[48,4],[49,5],[50,6],[51,7],[52,8],[53,9],[54,10],[55,11],[56,12],[57,13],[62,14],[78,15],[66,16],[67,16],[68,16],[70,17],[69,16],[77,18],[72,16],[71,16],[75,19],[74,16],[73,16],[76,16],[65,20],[63,21]],"semanticDiagnosticsPerFile":[46,47,45,48,49,50,51,52,53,54,55,56,57,60,58,62,59,61,10,12,11,2,13,14,15,16,17,18,19,20,3,4,24,21,22,23,25,26,27,5,28,29,30,31,6,32,33,34,35,7,40,36,37,38,39,8,41,42,43,1,9,44,78,66,67,68,70,69,64,77,72,71,75,74,73,76,65,63]},"version":"4.4.2"}