Socket
Socket
Sign inDemoInstall

@ui5/webcomponents-theme-base

Package Overview
Dependencies
Maintainers
2
Versions
163
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@ui5/webcomponents-theme-base - npm Package Compare versions

Comparing version 0.29.4 to 0.31.0

dist/Assets-static.js

10

CHANGELOG.md

@@ -6,3 +6,3 @@ # Change Log

## [0.29.2](https://github.com/SAP/ui5-webcomponents/compare/v0.29.1...v0.29.2) (2021-02-09)
# [1.0.0-rc.12](https://github.com/SAP/ui5-webcomponents/compare/v1.0.0-rc.11...v1.0.0-rc.12) (2021-02-18)

@@ -15,10 +15,2 @@ **Note:** Version bump only for package @ui5/webcomponents-theme-base

## [0.29.1](https://github.com/SAP/ui5-webcomponents/compare/v0.29.0...v0.29.1) (2021-01-21)
**Note:** Version bump only for package @ui5/webcomponents-theme-base
# [1.0.0-rc.11](https://github.com/SAP/ui5-webcomponents/compare/v1.0.0-rc.10...v1.0.0-rc.11) (2020-12-21)

@@ -25,0 +17,0 @@

@@ -1,23 +0,24 @@

import { registerThemeProperties } from "@ui5/webcomponents-base/dist/asset-registries/Themes.js";
import { registerThemePropertiesLoader } from "@ui5/webcomponents-base/dist/asset-registries/Themes.js";
import sap_belize from "../assets/themes/sap_belize/parameters-bundle.css.json";
import sap_belize_hcb from "../assets/themes/sap_belize_hcb/parameters-bundle.css.json";
import sap_belize_hcw from "../assets/themes/sap_belize_hcw/parameters-bundle.css.json";
import sap_fiori_3_dark from "../assets/themes/sap_fiori_3_dark/parameters-bundle.css.json";
import sap_fiori_3_hcb from "../assets/themes/sap_fiori_3_hcb/parameters-bundle.css.json";
import sap_fiori_3_hcw from "../assets/themes/sap_fiori_3_hcw/parameters-bundle.css.json";
const loadThemeProperties = async (themeName) => {
switch (themeName) {
case "sap_belize": return (await import("../assets/themes/sap_belize/parameters-bundle.css.json")).default;
case "sap_belize_hcb": return (await import("../assets/themes/sap_belize_hcb/parameters-bundle.css.json")).default;
case "sap_belize_hcw": return (await import("../assets/themes/sap_belize_hcw/parameters-bundle.css.json")).default;
case "sap_fiori_3_dark": return (await import("../assets/themes/sap_fiori_3_dark/parameters-bundle.css.json")).default;
case "sap_fiori_3_hcb": return (await import("../assets/themes/sap_fiori_3_hcb/parameters-bundle.css.json")).default;
case "sap_fiori_3_hcw": return (await import("../assets/themes/sap_fiori_3_hcw/parameters-bundle.css.json")).default;
default: throw "unknown theme"
}
}
const isInlined = obj => typeof (obj) === "object";
if (isInlined(sap_belize) || isInlined(sap_belize_hcb) || isInlined(sap_belize_hcw) || isInlined(sap_fiori_3_dark) || isInlined(sap_fiori_3_hcb) || isInlined(sap_fiori_3_hcw)) {
console.warn(`Inefficient bundling detected: consider bundling theme properties imports as URLs instead of inlining them.
See rollup-plugin-url or webpack file-loader for more information.
Suggested pattern: "assets\\\/.*\\\.json"`);
const loadAndCheck = async (themeName) => {
const data = await loadThemeProperties(themeName);
if (typeof data === "string" && data.endsWith(".json")) {
throw new Error(`[themes] Invalid bundling detected - dynamic JSON imports bundled as URLs. Switch to inlining JSON files from the build or use 'import ".../Assets-static.js"'. Check the "Assets" documentation for more information.`);
}
return data;
}
registerThemeProperties("@ui5/webcomponents-theme-base", "sap_belize", sap_belize);
registerThemeProperties("@ui5/webcomponents-theme-base", "sap_belize_hcb", sap_belize_hcb);
registerThemeProperties("@ui5/webcomponents-theme-base", "sap_belize_hcw", sap_belize_hcw);
registerThemeProperties("@ui5/webcomponents-theme-base", "sap_fiori_3_dark", sap_fiori_3_dark);
registerThemeProperties("@ui5/webcomponents-theme-base", "sap_fiori_3_hcb", sap_fiori_3_hcb);
registerThemeProperties("@ui5/webcomponents-theme-base", "sap_fiori_3_hcw", sap_fiori_3_hcw);
["sap_belize", "sap_belize_hcb", "sap_belize_hcw", "sap_fiori_3_dark", "sap_fiori_3_hcb", "sap_fiori_3_hcw"]
.forEach(themeName => registerThemePropertiesLoader("@ui5/webcomponents-theme-base", themeName, loadAndCheck));
{
"name": "@ui5/webcomponents-theme-base",
"version": "0.29.4",
"version": "0.31.0",
"description": "UI5 Web Components: webcomponents.theme-base",

@@ -27,8 +27,8 @@ "author": "SAP SE (https://www.sap.com)",

"@sap-theming/theming-base-content": "11.1.19",
"@ui5/webcomponents-base": "0.29.4"
"@ui5/webcomponents-base": "0.31.0"
},
"devDependencies": {
"@ui5/webcomponents-tools": "0.29.4",
"@ui5/webcomponents-tools": "0.31.0",
"chokidar-cli": "^2.0.0",
"chromedriver": "latest",
"chromedriver": "88.0.0",
"copy-and-watch": "^0.1.4",

@@ -35,0 +35,0 @@ "cssnano": "^4.1.10",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc