@trackunit/iris-app-runtime-core 1.13.12 → 1.13.15

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/index.cjs.js CHANGED
@@ -543,7 +543,19 @@ const SitesFilterBarRuntime = {
543
543
  const ThemeCssRuntime = {
544
544
  getThemeCssProperties: async () => {
545
545
  const api = await getHostConnector();
546
- return api.getThemeCssProperties();
546
+ const css = await api.getThemeCssProperties();
547
+ if (!css) {
548
+ return null;
549
+ }
550
+ const cssWithoutRGB = Object.entries(css).reduce((acc, [key, value]) => {
551
+ if (!value.includes("rgb")) {
552
+ // eslint-disable-next-line local-rules/no-typescript-assertion
553
+ acc[key] = `rgb(${value})`;
554
+ }
555
+ return acc;
556
+ // eslint-disable-next-line local-rules/no-typescript-assertion
557
+ }, {});
558
+ return cssWithoutRGB;
547
559
  },
548
560
  };
549
561
 
package/index.esm.js CHANGED
@@ -541,7 +541,19 @@ const SitesFilterBarRuntime = {
541
541
  const ThemeCssRuntime = {
542
542
  getThemeCssProperties: async () => {
543
543
  const api = await getHostConnector();
544
- return api.getThemeCssProperties();
544
+ const css = await api.getThemeCssProperties();
545
+ if (!css) {
546
+ return null;
547
+ }
548
+ const cssWithoutRGB = Object.entries(css).reduce((acc, [key, value]) => {
549
+ if (!value.includes("rgb")) {
550
+ // eslint-disable-next-line local-rules/no-typescript-assertion
551
+ acc[key] = `rgb(${value})`;
552
+ }
553
+ return acc;
554
+ // eslint-disable-next-line local-rules/no-typescript-assertion
555
+ }, {});
556
+ return cssWithoutRGB;
545
557
  },
546
558
  };
547
559
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@trackunit/iris-app-runtime-core",
3
- "version": "1.13.12",
3
+ "version": "1.13.15",
4
4
  "repository": "https://github.com/Trackunit/manager",
5
5
  "license": "SEE LICENSE IN LICENSE.txt",
6
6
  "engines": {
@@ -8,7 +8,7 @@
8
8
  },
9
9
  "dependencies": {
10
10
  "penpal": "^6.2.2",
11
- "@trackunit/iris-app-runtime-core-api": "1.12.12"
11
+ "@trackunit/iris-app-runtime-core-api": "1.12.13"
12
12
  },
13
13
  "module": "./index.esm.js",
14
14
  "main": "./index.cjs.js",