@getflip/swirl-components 0.113.1 → 0.115.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.
Files changed (32) hide show
  1. package/components.json +34 -18
  2. package/dist/cjs/loader.cjs.js +1 -1
  3. package/dist/cjs/swirl-components.cjs.js +1 -1
  4. package/dist/cjs/swirl-stack.cjs.entry.js +2 -1
  5. package/dist/cjs/swirl-theme-provider.cjs.entry.js +42 -285
  6. package/dist/collection/assets/pdfjs/pdf.worker.min.js +1 -1
  7. package/dist/collection/collection-manifest.json +1 -1
  8. package/dist/collection/components/swirl-stack/swirl-stack.js +19 -1
  9. package/dist/collection/components/swirl-theme-provider/swirl-theme-provider.js +72 -99
  10. package/dist/collection/components/swirl-theme-provider/swirl-theme-provider.spec.js +67 -18
  11. package/dist/collection/components/swirl-theme-provider/swirl-theme-provider.stories.js +371 -17
  12. package/dist/collection/components/swirl-theme-provider/swirl-theme-provider.types.js +1 -0
  13. package/dist/components/assets/pdfjs/pdf.worker.min.js +1 -1
  14. package/dist/components/swirl-stack2.js +3 -1
  15. package/dist/components/swirl-theme-provider.js +46 -289
  16. package/dist/esm/loader.js +1 -1
  17. package/dist/esm/swirl-components.js +1 -1
  18. package/dist/esm/swirl-stack.entry.js +2 -1
  19. package/dist/esm/swirl-theme-provider.entry.js +42 -285
  20. package/dist/swirl-components/p-bac71c14.entry.js +1 -0
  21. package/dist/swirl-components/p-bceafa56.entry.js +1 -0
  22. package/dist/swirl-components/swirl-components.esm.js +1 -1
  23. package/dist/types/components/swirl-stack/swirl-stack.d.ts +1 -0
  24. package/dist/types/components/swirl-theme-provider/swirl-theme-provider.d.ts +15 -34
  25. package/dist/types/components/swirl-theme-provider/swirl-theme-provider.types.d.ts +45 -0
  26. package/dist/types/components.d.ts +13 -11
  27. package/dist/types/index.d.ts +1 -1
  28. package/package.json +1 -1
  29. package/vscode-data.json +4 -0
  30. package/dist/swirl-components/p-1a4c6557.entry.js +0 -1
  31. package/dist/swirl-components/p-e9d96bc0.entry.js +0 -1
  32. package/dist/typings.d.ts +0 -1
@@ -42,7 +42,6 @@
42
42
  "./components/swirl-table-column/swirl-table-column.js",
43
43
  "./components/swirl-tag/swirl-tag.js",
44
44
  "./components/swirl-text/swirl-text.js",
45
- "./components/swirl-theme-provider/swirl-theme-provider.js",
46
45
  "./components/swirl-thumbnail/swirl-thumbnail.js",
47
46
  "./components/swirl-toast/swirl-toast.js",
48
47
  "./components/swirl-toast-provider/swirl-toast-provider.js",
@@ -299,6 +298,7 @@
299
298
  "./components/swirl-table-row/swirl-table-row.js",
300
299
  "./components/swirl-table-row-group/swirl-table-row-group.js",
301
300
  "./components/swirl-tabs/swirl-tabs.js",
301
+ "./components/swirl-theme-provider/swirl-theme-provider.js",
302
302
  "./components/swirl-time-input/swirl-time-input.js",
303
303
  "./components/swirl-tree-navigation-item/swirl-tree-navigation-item.js",
304
304
  "./components/swirl-video-thumbnail/swirl-video-thumbnail.js",
@@ -4,6 +4,7 @@ export class SwirlStack {
4
4
  constructor() {
5
5
  this.align = "start";
6
6
  this.as = "div";
7
+ this.height = undefined;
7
8
  this.justify = "start";
8
9
  this.orientation = "vertical";
9
10
  this.spacing = "0";
@@ -12,7 +13,7 @@ export class SwirlStack {
12
13
  render() {
13
14
  const Tag = this.as;
14
15
  const className = classnames("stack", `stack--align-${this.align}`, `stack--justify-${this.justify}`, `stack--orientation-${this.orientation}`, { "stack--wrap": this.wrap });
15
- return (h(Host, null, h(Tag, { class: className, style: { gap: `var(--s-space-${this.spacing})` } }, h("slot", null))));
16
+ return (h(Host, { style: { height: this.height } }, h(Tag, { class: className, style: { gap: `var(--s-space-${this.spacing})`, height: this.height } }, h("slot", null))));
16
17
  }
17
18
  static get is() { return "swirl-stack"; }
18
19
  static get encapsulation() { return "shadow"; }
@@ -69,6 +70,23 @@ export class SwirlStack {
69
70
  "reflect": false,
70
71
  "defaultValue": "\"div\""
71
72
  },
73
+ "height": {
74
+ "type": "string",
75
+ "mutable": false,
76
+ "complexType": {
77
+ "original": "string",
78
+ "resolved": "string",
79
+ "references": {}
80
+ },
81
+ "required": false,
82
+ "optional": true,
83
+ "docs": {
84
+ "tags": [],
85
+ "text": ""
86
+ },
87
+ "attribute": "height",
88
+ "reflect": false
89
+ },
72
90
  "justify": {
73
91
  "type": "string",
74
92
  "mutable": false,
@@ -1,25 +1,8 @@
1
1
  import { h, Host, } from "@stencil/core";
2
- import { hsla, parseToHsla, toRgba } from "color2k";
3
2
  const preferredThemeStorageKey = "swirl-preferred-theme";
4
- const tenantColorMapping = {
5
- "--s-action-primary-default": "primary",
6
- "--s-action-primary-hovered": "primaryHovered",
7
- "--s-action-primary-pressed": "primaryPressed",
8
- "--s-text-on-action-primary": "primaryContrast",
9
- "--s-icon-on-action-primary": "primaryContrast",
10
- "--s-surface-highlight-default": "secondary",
11
- "--s-surface-highlight-hovered": "secondaryHovered",
12
- "--s-surface-highlight-pressed": "secondaryPressed",
13
- "--s-on-surface-highlight-default": "secondaryHovered",
14
- "--s-text-on-surface-highlight": "secondaryContrast",
15
- "--s-icon-on-surface-highlight": "secondaryContrast",
16
- "--s-text-highlight": "text",
17
- "--s-interactive-primary-default": "text",
18
- "--s-interactive-primary-hovered": "textHovered",
19
- "--s-interactive-primary-pressed": "textPressed",
20
- };
21
3
  export class SwirlThemeProvider {
22
4
  constructor() {
5
+ this.setDesignTokens = [];
23
6
  this.config = undefined;
24
7
  }
25
8
  componentWillLoad() {
@@ -33,27 +16,27 @@ export class SwirlThemeProvider {
33
16
  this.updateAppTheme();
34
17
  }
35
18
  /**
36
- * Returns the active app theme.
19
+ * Returns the active OS theme.
37
20
  * @returns SwirlTheme
38
21
  */
39
- async getActiveTheme() {
40
- return this.appTheme;
22
+ async getActiveOSTheme() {
23
+ return this.appOSTheme;
41
24
  }
42
25
  /**
43
- * Returns the user's preferred theme stored in local storage.
26
+ * Returns the user's preferred OS theme stored in local storage.
44
27
  * @returns SwirlTheme
45
28
  */
46
- async getPreferredTheme() {
29
+ async getPreferredOSTheme() {
47
30
  if (!Boolean(this.resolvedConfig.storage)) {
48
31
  return;
49
32
  }
50
33
  return this.resolvedConfig.storage.getItem(preferredThemeStorageKey);
51
34
  }
52
35
  /**
53
- * Sets the user's preferred theme and stores it in local storage. Overrides
54
- * the OS theme.
36
+ * Sets the user's preferred OS theme and stores it in local storage. Overrides
37
+ * the system theme.
55
38
  */
56
- async setPreferredTheme(theme) {
39
+ async setPreferredOSTheme(theme) {
57
40
  if (!Boolean(this.resolvedConfig.storage)) {
58
41
  return;
59
42
  }
@@ -61,9 +44,9 @@ export class SwirlThemeProvider {
61
44
  this.updateAppTheme();
62
45
  }
63
46
  /**
64
- * Resets the user's preferred theme, using the OS theme instead.
47
+ * Resets the user's preferred OS theme, using the system theme instead.
65
48
  */
66
- async resetPreferredTheme() {
49
+ async resetPreferredOSTheme() {
67
50
  if (!Boolean(this.resolvedConfig.storage)) {
68
51
  return;
69
52
  }
@@ -90,8 +73,8 @@ export class SwirlThemeProvider {
90
73
  });
91
74
  }
92
75
  async updateAppTheme() {
93
- this.appTheme = (await this.getPreferredTheme()) || this.osTheme;
94
- if (this.appTheme === "dark") {
76
+ this.appOSTheme = (await this.getPreferredOSTheme()) || this.osTheme;
77
+ if (this.appOSTheme === "dark") {
95
78
  document.documentElement.classList.remove("theme-light");
96
79
  document.documentElement.classList.add("theme-dark");
97
80
  }
@@ -100,59 +83,49 @@ export class SwirlThemeProvider {
100
83
  document.documentElement.classList.add("theme-light");
101
84
  }
102
85
  this.updateTenantVariables();
86
+ this.updateTenantAssets();
103
87
  const themeChangeEventData = {
104
- activeTheme: await this.getActiveTheme(),
105
- preferredTheme: await this.getPreferredTheme(),
88
+ activeTheme: await this.getActiveOSTheme(),
89
+ preferredTheme: await this.getPreferredOSTheme(),
106
90
  };
107
- if (!Boolean(this.recentThemeChangeEventData) ||
91
+ if (!Boolean(this.recentOSThemeChangeEventData) ||
108
92
  themeChangeEventData.activeTheme !==
109
- this.recentThemeChangeEventData.activeTheme ||
93
+ this.recentOSThemeChangeEventData.activeTheme ||
110
94
  themeChangeEventData.preferredTheme !==
111
- this.recentThemeChangeEventData.preferredTheme) {
112
- this.recentThemeChangeEventData = themeChangeEventData;
113
- this.themeChange.emit(this.recentThemeChangeEventData);
95
+ this.recentOSThemeChangeEventData.preferredTheme) {
96
+ this.recentOSThemeChangeEventData = themeChangeEventData;
97
+ this.themeChange.emit(this.recentOSThemeChangeEventData);
114
98
  }
115
99
  }
100
+ updateTenantAssets() {
101
+ const theme = this.resolvedConfig?.themes?.[this.appOSTheme];
102
+ if (!Boolean(theme)) {
103
+ return;
104
+ }
105
+ document.head
106
+ .querySelector('link[rel="icon"]')
107
+ ?.setAttribute("href", theme.favicon.link);
108
+ }
116
109
  updateTenantVariables() {
117
- const tenantTheme = this.resolvedConfig?.tenantColors;
118
- if (!Boolean(tenantTheme)) {
110
+ const theme = this.resolvedConfig?.themes?.[this.appOSTheme];
111
+ if (!Boolean(theme)) {
119
112
  this.resetTenantVariables();
120
113
  return;
121
114
  }
122
115
  const rootElement = this.resolvedConfig.rootElement;
123
- // generate state colors (hovered, pressed) from base colors
124
- const primaryHsla = parseToHsla(tenantTheme.primary);
125
- const secondaryHsla = parseToHsla(tenantTheme.secondary);
126
- const textHsla = parseToHsla(tenantTheme.text);
127
- const primaryHovered = toRgba(hsla(primaryHsla[0], primaryHsla[1] - 0.21, primaryHsla[2] + 0.09, 1));
128
- const primaryPressed = toRgba(hsla(primaryHsla[0], primaryHsla[1] - 0.2, primaryHsla[2] + 0.17, 1));
129
- const secondaryHovered = toRgba(hsla(secondaryHsla[0], secondaryHsla[1], secondaryHsla[2] + 0.07, 1));
130
- const secondaryPressed = toRgba(hsla(secondaryHsla[0], secondaryHsla[1], secondaryHsla[2] + 0.15, 1));
131
- const textHovered = toRgba(hsla(textHsla[0], textHsla[1] - 0.34, textHsla[2] + 0.1, 1));
132
- const textPressed = toRgba(hsla(textHsla[0], textHsla[1] - 0.48, textHsla[2] + 0.2, 1));
133
- const tenantThemeWithGeneratedStateColors = {
134
- ...tenantTheme,
135
- primaryHovered: primaryHovered,
136
- primaryPressed: primaryPressed,
137
- secondaryHovered: secondaryHovered,
138
- secondaryPressed: secondaryPressed,
139
- textHovered: textHovered,
140
- textPressed: textPressed,
141
- };
142
- // set custom properties for tenant theme colors
143
- Object.entries(tenantColorMapping).forEach(([key, value]) => rootElement.style.setProperty(key, tenantThemeWithGeneratedStateColors[value]));
116
+ this.setDesignTokens = [];
117
+ theme.design_tokens.forEach((token) => {
118
+ const propertyName = `--s-${token.id}`;
119
+ rootElement.style.setProperty(propertyName, `rgba(${token.color.r}, ${token.color.g}, ${token.color.b}, ${token.color.a})`);
120
+ this.setDesignTokens.push(propertyName);
121
+ });
144
122
  }
145
123
  resetTenantVariables() {
146
124
  const rootElement = this.resolvedConfig.rootElement;
147
- [
148
- ...Object.keys(tenantColorMapping),
149
- "primaryHovered",
150
- "primaryPressed",
151
- "secondaryHovered",
152
- "secondaryPressed",
153
- "textHovered",
154
- "textPressed",
155
- ].forEach((key) => rootElement.style.removeProperty(key));
125
+ this.setDesignTokens.forEach((property) => {
126
+ rootElement.style.removeProperty(property);
127
+ });
128
+ this.setDesignTokens = [];
156
129
  }
157
130
  render() {
158
131
  return (h(Host, null, h("slot", null)));
@@ -176,11 +149,11 @@ export class SwirlThemeProvider {
176
149
  "mutable": false,
177
150
  "complexType": {
178
151
  "original": "SwirlThemeProviderConfig",
179
- "resolved": "{ rootElement?: HTMLElement; storage?: SwirlThemeProviderStorage; tenantColors?: SwirlThemeProviderTenantColors; }",
152
+ "resolved": "{ rootElement?: HTMLElement; storage?: SwirlThemeProviderStorage; themes?: SwirlThemes; }",
180
153
  "references": {
181
154
  "SwirlThemeProviderConfig": {
182
- "location": "local",
183
- "path": "/home/runner/work/swirl/swirl/packages/swirl-components/src/components/swirl-theme-provider/swirl-theme-provider.tsx"
155
+ "location": "import",
156
+ "path": "./swirl-theme-provider.types"
184
157
  }
185
158
  }
186
159
  },
@@ -205,12 +178,12 @@ export class SwirlThemeProvider {
205
178
  "text": ""
206
179
  },
207
180
  "complexType": {
208
- "original": "SwirlThemeChangeEventData",
209
- "resolved": "{ activeTheme: SwirlTheme; preferredTheme: SwirlTheme; }",
181
+ "original": "SwirlOSThemeChangeEventData",
182
+ "resolved": "{ activeTheme: SwirlOSTheme; preferredTheme: SwirlOSTheme; }",
210
183
  "references": {
211
- "SwirlThemeChangeEventData": {
212
- "location": "local",
213
- "path": "/home/runner/work/swirl/swirl/packages/swirl-components/src/components/swirl-theme-provider/swirl-theme-provider.tsx"
184
+ "SwirlOSThemeChangeEventData": {
185
+ "location": "import",
186
+ "path": "./swirl-theme-provider.types"
214
187
  }
215
188
  }
216
189
  }
@@ -218,55 +191,55 @@ export class SwirlThemeProvider {
218
191
  }
219
192
  static get methods() {
220
193
  return {
221
- "getActiveTheme": {
194
+ "getActiveOSTheme": {
222
195
  "complexType": {
223
- "signature": "() => Promise<SwirlTheme>",
196
+ "signature": "() => Promise<SwirlOSTheme>",
224
197
  "parameters": [],
225
198
  "references": {
226
199
  "Promise": {
227
200
  "location": "global"
228
201
  },
229
- "SwirlTheme": {
230
- "location": "local",
231
- "path": "/home/runner/work/swirl/swirl/packages/swirl-components/src/components/swirl-theme-provider/swirl-theme-provider.tsx"
202
+ "SwirlOSTheme": {
203
+ "location": "import",
204
+ "path": "./swirl-theme-provider.types"
232
205
  }
233
206
  },
234
- "return": "Promise<SwirlTheme>"
207
+ "return": "Promise<SwirlOSTheme>"
235
208
  },
236
209
  "docs": {
237
- "text": "Returns the active app theme.",
210
+ "text": "Returns the active OS theme.",
238
211
  "tags": [{
239
212
  "name": "returns",
240
213
  "text": "SwirlTheme"
241
214
  }]
242
215
  }
243
216
  },
244
- "getPreferredTheme": {
217
+ "getPreferredOSTheme": {
245
218
  "complexType": {
246
- "signature": "() => Promise<SwirlTheme>",
219
+ "signature": "() => Promise<SwirlOSTheme>",
247
220
  "parameters": [],
248
221
  "references": {
249
222
  "Promise": {
250
223
  "location": "global"
251
224
  },
252
- "SwirlTheme": {
253
- "location": "local",
254
- "path": "/home/runner/work/swirl/swirl/packages/swirl-components/src/components/swirl-theme-provider/swirl-theme-provider.tsx"
225
+ "SwirlOSTheme": {
226
+ "location": "import",
227
+ "path": "./swirl-theme-provider.types"
255
228
  }
256
229
  },
257
- "return": "Promise<SwirlTheme>"
230
+ "return": "Promise<SwirlOSTheme>"
258
231
  },
259
232
  "docs": {
260
- "text": "Returns the user's preferred theme stored in local storage.",
233
+ "text": "Returns the user's preferred OS theme stored in local storage.",
261
234
  "tags": [{
262
235
  "name": "returns",
263
236
  "text": "SwirlTheme"
264
237
  }]
265
238
  }
266
239
  },
267
- "setPreferredTheme": {
240
+ "setPreferredOSTheme": {
268
241
  "complexType": {
269
- "signature": "(theme: SwirlTheme) => Promise<void>",
242
+ "signature": "(theme: SwirlOSTheme) => Promise<void>",
270
243
  "parameters": [{
271
244
  "tags": [],
272
245
  "text": ""
@@ -275,19 +248,19 @@ export class SwirlThemeProvider {
275
248
  "Promise": {
276
249
  "location": "global"
277
250
  },
278
- "SwirlTheme": {
279
- "location": "local",
280
- "path": "/home/runner/work/swirl/swirl/packages/swirl-components/src/components/swirl-theme-provider/swirl-theme-provider.tsx"
251
+ "SwirlOSTheme": {
252
+ "location": "import",
253
+ "path": "./swirl-theme-provider.types"
281
254
  }
282
255
  },
283
256
  "return": "Promise<void>"
284
257
  },
285
258
  "docs": {
286
- "text": "Sets the user's preferred theme and stores it in local storage. Overrides\nthe OS theme.",
259
+ "text": "Sets the user's preferred OS theme and stores it in local storage. Overrides\nthe system theme.",
287
260
  "tags": []
288
261
  }
289
262
  },
290
- "resetPreferredTheme": {
263
+ "resetPreferredOSTheme": {
291
264
  "complexType": {
292
265
  "signature": "() => Promise<void>",
293
266
  "parameters": [],
@@ -299,7 +272,7 @@ export class SwirlThemeProvider {
299
272
  "return": "Promise<void>"
300
273
  },
301
274
  "docs": {
302
- "text": "Resets the user's preferred theme, using the OS theme instead.",
275
+ "text": "Resets the user's preferred OS theme, using the system theme instead.",
303
276
  "tags": []
304
277
  }
305
278
  }
@@ -24,21 +24,21 @@ describe("swirl-theme-provider", () => {
24
24
  components: [SwirlThemeProvider],
25
25
  html: `<swirl-theme-provider></swirl-theme-provider>`,
26
26
  });
27
- expect(await page.root.getActiveTheme()).toBe("dark");
27
+ expect(await page.root.getActiveOSTheme()).toBe("dark");
28
28
  });
29
29
  it("overrides the os theme with a preferred user theme", async () => {
30
30
  const page = await newSpecPage({
31
31
  components: [SwirlThemeProvider],
32
32
  html: `<swirl-theme-provider></swirl-theme-provider>`,
33
33
  });
34
- expect(await page.root.getActiveTheme()).toBe("dark");
35
- expect(await page.root.getPreferredTheme()).toBeNull();
36
- await page.root.setPreferredTheme("light");
37
- expect(await page.root.getActiveTheme()).toBe("light");
38
- expect(await page.root.getPreferredTheme()).toBe("light");
39
- await page.root.resetPreferredTheme();
40
- expect(await page.root.getActiveTheme()).toBe("dark");
41
- expect(await page.root.getPreferredTheme()).toBeNull();
34
+ expect(await page.root.getActiveOSTheme()).toBe("dark");
35
+ expect(await page.root.getPreferredOSTheme()).toBeNull();
36
+ await page.root.setPreferredOSTheme("light");
37
+ expect(await page.root.getActiveOSTheme()).toBe("light");
38
+ expect(await page.root.getPreferredOSTheme()).toBe("light");
39
+ await page.root.resetPreferredOSTheme();
40
+ expect(await page.root.getActiveOSTheme()).toBe("dark");
41
+ expect(await page.root.getPreferredOSTheme()).toBeNull();
42
42
  });
43
43
  it("adds custom tenant color properties", async () => {
44
44
  const page = await newSpecPage({
@@ -46,17 +46,66 @@ describe("swirl-theme-provider", () => {
46
46
  html: `<swirl-theme-provider></swirl-theme-provider>`,
47
47
  });
48
48
  page.root.config = {
49
- tenantColors: {
50
- primary: "red",
51
- primaryContrast: "blue",
52
- secondary: "green",
53
- secondaryContrast: "orange",
54
- text: "purple",
49
+ themes: {
50
+ dark: {
51
+ favicon: {
52
+ id: "d3458010-97c6-40a7-896d-804ab6c33496",
53
+ link: "https://master.flip-app.dev/media/themes/d3458010-97c6-40a7-896d-804ab6c33496",
54
+ file_name: "dark-favIcon.png",
55
+ },
56
+ company_icon: {
57
+ id: "6d1c1da4-fa4b-4d77-b44d-b1fa58ed6337",
58
+ link: "https://master.flip-app.dev/media/themes/6d1c1da4-fa4b-4d77-b44d-b1fa58ed6337",
59
+ file_name: "dark-companyIcon.png",
60
+ },
61
+ company_logo: {
62
+ id: "618f411b-eaad-4c06-8834-54fce38fcbad",
63
+ link: "https://master.flip-app.dev/media/themes/618f411b-eaad-4c06-8834-54fce38fcbad",
64
+ file_name: "dark-companyLogo.png",
65
+ },
66
+ design_tokens: [
67
+ {
68
+ id: "text-highlight",
69
+ color: {
70
+ r: 255,
71
+ g: 0,
72
+ b: 0,
73
+ a: 255,
74
+ },
75
+ },
76
+ ],
77
+ },
78
+ light: {
79
+ favicon: {
80
+ id: "49ab1bb9-17d9-45c0-87b4-2247bb8c3648",
81
+ link: "https://master.flip-app.dev/media/themes/49ab1bb9-17d9-45c0-87b4-2247bb8c3648",
82
+ file_name: "light-favIcon.png",
83
+ },
84
+ company_icon: {
85
+ id: "0eaddd17-3468-4243-bdd8-6fae1222e032",
86
+ link: "https://master.flip-app.dev/media/themes/0eaddd17-3468-4243-bdd8-6fae1222e032",
87
+ file_name: "light-companyIcon.png",
88
+ },
89
+ company_logo: {
90
+ id: "b39cb0c9-9097-48c8-900b-6e24686aac5e",
91
+ link: "https://master.flip-app.dev/media/themes/b39cb0c9-9097-48c8-900b-6e24686aac5e",
92
+ file_name: "light-companyLogo.png",
93
+ },
94
+ design_tokens: [
95
+ {
96
+ id: "text-highlight",
97
+ color: {
98
+ r: 0,
99
+ g: 255,
100
+ b: 0,
101
+ a: 255,
102
+ },
103
+ },
104
+ ],
105
+ },
55
106
  },
56
107
  };
57
108
  await page.waitForChanges();
58
- expect(page.doc.documentElement.style.getPropertyValue("--s-action-primary-default")).toBe("red");
59
- expect(page.doc.documentElement.style.getPropertyValue("--s-surface-highlight-default")).toBe("green");
60
- expect(page.doc.documentElement.style.getPropertyValue("--s-text-highlight")).toBe("purple");
109
+ expect(page.doc.documentElement.style.getPropertyValue("--s-text-highlight")).toBe("rgba(255, 0, 0, 255)");
61
110
  });
62
111
  });