@unocss/svelte-scoped 66.7.0 → 66.7.2-beta.1

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.
@@ -1,4 +1,4 @@
1
- import { i as transformClasses, n as transformStyle, r as themeRE, t as checkForApply } from "./transformStyle-NRa-cUil.mjs";
1
+ import { i as transformClasses, n as transformStyle, r as themeRE, t as checkForApply } from "./transformStyle-C_Qgy-5X.mjs";
2
2
  import process from "node:process";
3
3
  import { createRecoveryConfigLoader } from "@unocss/config";
4
4
  import { createGenerator, warnOnce } from "@unocss/core";
@@ -407,8 +407,11 @@ function transformTheme(s, theme) {
407
407
  function getThemeValue(rawArguments, theme) {
408
408
  const keys = rawArguments.split(".");
409
409
  let current = theme;
410
- for (const key of keys) if (current[key] === void 0) throw new Error(`"${rawArguments}" is not found in your theme`);
411
- else current = current[key];
410
+ for (const key of keys) {
411
+ if (key === "__proto__" || key === "constructor") throw new Error(`"${rawArguments}" contains invalid key "${key}"`);
412
+ if (current[key] === void 0) throw new Error(`"${rawArguments}" is not found in your theme`);
413
+ else current = current[key];
414
+ }
412
415
  return current;
413
416
  }
414
417
  //#endregion
package/dist/vite.mjs CHANGED
@@ -1,4 +1,4 @@
1
- import { i as transformClasses, n as transformStyle, r as themeRE, t as checkForApply } from "./transformStyle-NRa-cUil.mjs";
1
+ import { i as transformClasses, n as transformStyle, r as themeRE, t as checkForApply } from "./transformStyle-C_Qgy-5X.mjs";
2
2
  import process$1 from "node:process";
3
3
  import { createRecoveryConfigLoader } from "@unocss/config";
4
4
  import { BetterMap, createGenerator, cssIdRE } from "@unocss/core";
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@unocss/svelte-scoped",
3
3
  "type": "module",
4
- "version": "66.7.0",
4
+ "version": "66.7.2-beta.1",
5
5
  "description": "Use UnoCSS in a modular fashion with styles being stored only in the Svelte component they are used in: Vite plugin for apps, Svelte preprocessor for component libraries",
6
6
  "author": "Jacob Bowdoin",
7
7
  "license": "MIT",
@@ -48,11 +48,11 @@
48
48
  "magic-string": "^0.30.21",
49
49
  "pathe": "^2.0.3",
50
50
  "zimmerframe": "^1.1.4",
51
- "@unocss/core": "66.7.0",
52
- "@unocss/config": "66.7.0",
53
- "@unocss/reset": "66.7.0",
54
- "@unocss/preset-wind3": "66.7.0",
55
- "@unocss/preset-uno": "66.7.0"
51
+ "@unocss/preset-uno": "66.7.2-beta.1",
52
+ "@unocss/preset-wind3": "66.7.2-beta.1",
53
+ "@unocss/reset": "66.7.2-beta.1",
54
+ "@unocss/core": "66.7.2-beta.1",
55
+ "@unocss/config": "66.7.2-beta.1"
56
56
  },
57
57
  "devDependencies": {
58
58
  "prettier-plugin-svelte": "^3.5.2",