@ebay/skin 18.0.2 → 18.0.4

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.
@@ -157,10 +157,21 @@ class GenerateImages {
157
157
  (config.deprecated === null ||
158
158
  config.deprecated.indexOf(nameObj.simpleName) === -1);
159
159
 
160
+ const sizes = symbol.getAttribute("viewBox");
161
+
162
+ if (sizes === null) {
163
+ console.log("ERROR: viewbox dimensions missing from " + filename);
164
+ return;
165
+ }
166
+
167
+ const [, , width, height] = sizes.split(" ");
168
+
160
169
  if (isAllowedInDocs) {
161
170
  this.imageList.push({
162
171
  name: nameObj.fullName,
163
172
  size: nameObj.size,
173
+ height,
174
+ width,
164
175
  });
165
176
  }
166
177
  console.log("Processing SVG:", symbol, filename);
@@ -170,15 +181,6 @@ class GenerateImages {
170
181
  if (config.skip.indexOf(filename) > -1) {
171
182
  return;
172
183
  }
173
- const sizes = symbol.getAttribute("viewBox");
174
-
175
- if (sizes === null) {
176
- console.log("ERROR: viewbox dimensions missing from " + filename);
177
- return;
178
- }
179
-
180
- const [, , width, height] = sizes.split(" ");
181
- const id = `${nameObj.prefix}-${nameObj.fullName}`;
182
184
  }
183
185
 
184
186
  async run() {
@@ -226,17 +228,17 @@ function stripName(name, mappedPrefix, mappedPostfix) {
226
228
  const matcher = new RegExp(
227
229
  `^((?:icon-|program-badge-|star-rating-)?)([\\w-]+?)((?:|-small))$`,
228
230
  );
229
- const sizeMatcher = new RegExp(
230
- `(?:${supportedSizes.join("|")})(?:-\\w+)?$`,
231
- );
231
+ const sizeMatcher = new RegExp(`(${supportedSizes.join("|")})(?:-\\w+)?$`);
232
232
 
233
233
  const nameMatch = name.match(matcher);
234
234
  if (nameMatch) {
235
235
  const [, prefix, newName, postfix] = nameMatch;
236
236
  const sizeMatch = name.match(sizeMatcher);
237
237
  let size;
238
+ let rawSize;
238
239
  if (sizeMatch) {
239
240
  size = sizeMatch[0];
241
+ rawSize = sizeMatch[1];
240
242
  }
241
243
 
242
244
  const fullName = `${newName}${postfix}`;
@@ -245,6 +247,7 @@ function stripName(name, mappedPrefix, mappedPostfix) {
245
247
  name: newName,
246
248
  postfix,
247
249
  size,
250
+ rawSize,
248
251
  simpleName: prefix === "icon-" ? fullName : `${prefix}${fullName}`,
249
252
  fullName,
250
253
  };
@@ -31,15 +31,15 @@ div.star-rating[data-stars^="4"] svg:nth-child(-n + 4),
31
31
  div.star-rating[data-stars^="5"] svg:nth-child(-n + 5) {
32
32
  --color-star-rating-full: var(
33
33
  --color-star-rating-filled,
34
- $color-star-rating-icon-filled-foreground
34
+ #{$color-star-rating-icon-filled-foreground}
35
35
  );
36
36
  --color-star-rating-full-stroke: var(
37
37
  --color-star-rating-filled-stroke,
38
- $color-star-rating-icon-filled-stroke
38
+ #{$color-star-rating-icon-filled-stroke}
39
39
  );
40
40
  --color-star-rating-half-stroke: var(
41
41
  --color-star-rating-filled-stroke,
42
- $color-star-rating-icon-filled-stroke
42
+ #{$color-star-rating-icon-filled-stroke}
43
43
  );
44
44
  }
45
45
 
@@ -33,8 +33,7 @@
33
33
 
34
34
  /* `.textbox--focus` should be removed after full browser support for `:has` */
35
35
  .textbox--focus,
36
- .textbox:has(> .textbox__control:focus):not(
37
- .textbox--readonly,
36
+ .textbox:has(> .textbox__control:focus):not(.textbox--readonly):not(
38
37
  :has(> .textbox__control[readonly])
39
38
  ) {
40
39
  box-shadow: 0 0 0 1px var(--color-stroke-strong);
package/src/svg/icons.svg CHANGED
@@ -16,11 +16,11 @@
16
16
  <stop offset=".785" stop-color="#4EE04B" />
17
17
  </linearGradient>
18
18
  <linearGradient
19
- id="ref-ai-spectrum-filled-16-colored"
20
- x1="21.21"
21
- y1="11.161"
22
- x2="11.274"
23
- y2="21.774"
19
+ id="ref-ai-spectrum-20-colored"
20
+ x1="26.984"
21
+ y1="14.065"
22
+ x2="14.21"
23
+ y2="27.71"
24
24
  gradientUnits="userSpaceOnUse"
25
25
  >
26
26
  <stop offset=".098" stop-color="#FFD80E" />
@@ -30,11 +30,11 @@
30
30
  <stop offset=".785" stop-color="#4EE04B" />
31
31
  </linearGradient>
32
32
  <linearGradient
33
- id="ref-ai-spectrum-24-colored"
34
- x1="32.758"
35
- y1="16.968"
36
- x2="17.145"
37
- y2="33.645"
33
+ id="ref-ai-spectrum-filled-16-colored"
34
+ x1="21.21"
35
+ y1="11.161"
36
+ x2="11.274"
37
+ y2="21.774"
38
38
  gradientUnits="userSpaceOnUse"
39
39
  >
40
40
  <stop offset=".098" stop-color="#FFD80E" />
@@ -72,7 +72,7 @@
72
72
  <stop offset=".785" stop-color="#4EE04B" />
73
73
  </linearGradient>
74
74
  <linearGradient
75
- id="ref-ai-spectrum-filled-24-colored"
75
+ id="ref-ai-spectrum-24-colored"
76
76
  x1="32.758"
77
77
  y1="16.968"
78
78
  x2="17.145"
@@ -86,11 +86,11 @@
86
86
  <stop offset=".785" stop-color="#4EE04B" />
87
87
  </linearGradient>
88
88
  <linearGradient
89
- id="ref-ai-spectrum-20-colored"
90
- x1="26.984"
91
- y1="14.065"
92
- x2="14.21"
93
- y2="27.71"
89
+ id="ref-ai-spectrum-filled-24-colored"
90
+ x1="32.758"
91
+ y1="16.968"
92
+ x2="17.145"
93
+ y2="33.645"
94
94
  gradientUnits="userSpaceOnUse"
95
95
  >
96
96
  <stop offset=".098" stop-color="#FFD80E" />
package/svg.svg CHANGED
@@ -16,11 +16,11 @@
16
16
  <stop offset=".785" stop-color="#4EE04B" />
17
17
  </linearGradient>
18
18
  <linearGradient
19
- id="ref-ai-spectrum-filled-16-colored"
20
- x1="21.21"
21
- y1="11.161"
22
- x2="11.274"
23
- y2="21.774"
19
+ id="ref-ai-spectrum-20-colored"
20
+ x1="26.984"
21
+ y1="14.065"
22
+ x2="14.21"
23
+ y2="27.71"
24
24
  gradientUnits="userSpaceOnUse"
25
25
  >
26
26
  <stop offset=".098" stop-color="#FFD80E" />
@@ -30,11 +30,11 @@
30
30
  <stop offset=".785" stop-color="#4EE04B" />
31
31
  </linearGradient>
32
32
  <linearGradient
33
- id="ref-ai-spectrum-24-colored"
34
- x1="32.758"
35
- y1="16.968"
36
- x2="17.145"
37
- y2="33.645"
33
+ id="ref-ai-spectrum-filled-16-colored"
34
+ x1="21.21"
35
+ y1="11.161"
36
+ x2="11.274"
37
+ y2="21.774"
38
38
  gradientUnits="userSpaceOnUse"
39
39
  >
40
40
  <stop offset=".098" stop-color="#FFD80E" />
@@ -72,7 +72,7 @@
72
72
  <stop offset=".785" stop-color="#4EE04B" />
73
73
  </linearGradient>
74
74
  <linearGradient
75
- id="ref-ai-spectrum-filled-24-colored"
75
+ id="ref-ai-spectrum-24-colored"
76
76
  x1="32.758"
77
77
  y1="16.968"
78
78
  x2="17.145"
@@ -86,11 +86,11 @@
86
86
  <stop offset=".785" stop-color="#4EE04B" />
87
87
  </linearGradient>
88
88
  <linearGradient
89
- id="ref-ai-spectrum-20-colored"
90
- x1="26.984"
91
- y1="14.065"
92
- x2="14.21"
93
- y2="27.71"
89
+ id="ref-ai-spectrum-filled-24-colored"
90
+ x1="32.758"
91
+ y1="16.968"
92
+ x2="17.145"
93
+ y2="33.645"
94
94
  gradientUnits="userSpaceOnUse"
95
95
  >
96
96
  <stop offset=".098" stop-color="#FFD80E" />