@unocss/svelte-scoped 0.63.4 → 0.63.6

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
- export { U as default } from './shared/svelte-scoped.DPsPs-Am.mjs';
1
+ export { U as default } from './shared/svelte-scoped.Mm5co22N.mjs';
2
2
  import 'node:process';
3
3
  import '@unocss/config';
4
4
  import '@unocss/core';
@@ -110,7 +110,7 @@ async function sortClassesIntoCategories(body, options, uno, filename) {
110
110
  }
111
111
 
112
112
  const expressionsRE = /\S*\{[^{}]+\}\S*/g;
113
- const classesRE = /(["'`])([\s\S]*?)\1/g;
113
+ const classesRE = /(?<=\?\s*|:\s*)(["'`])([\s\S]*?)\1/g;
114
114
  async function processExpressions(body, options, uno, filename) {
115
115
  const rulesToGenerate = {};
116
116
  const updatedExpressions = [];
@@ -123,7 +123,10 @@ async function processExpressions(body, options, uno, filename) {
123
123
  const { rulesToGenerate: rulesFromExpression, ignore } = await sortClassesIntoCategories(withoutQuotes, options, uno, filename);
124
124
  Object.assign(rulesToGenerate, rulesFromExpression);
125
125
  const updatedClasses = Object.keys(rulesFromExpression).concat(ignore).join(" ");
126
- expression = expression.replace(withQuotes, quoteMark + updatedClasses + quoteMark);
126
+ expression = expression.replace(
127
+ withQuotes,
128
+ quoteMark + updatedClasses + quoteMark
129
+ );
127
130
  }
128
131
  updatedExpressions.push(expression);
129
132
  }
package/dist/vite.mjs CHANGED
@@ -7,7 +7,7 @@ import MagicString from 'magic-string';
7
7
  import { readFileSync, existsSync, statSync } from 'node:fs';
8
8
  import { dirname, resolve } from 'node:path';
9
9
  import { fileURLToPath } from 'node:url';
10
- import { U as UnocssSveltePreprocess } from './shared/svelte-scoped.DPsPs-Am.mjs';
10
+ import { U as UnocssSveltePreprocess } from './shared/svelte-scoped.Mm5co22N.mjs';
11
11
  import 'css-tree';
12
12
 
13
13
  function ConfigHMRPlugin({ ready }) {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@unocss/svelte-scoped",
3
3
  "type": "module",
4
- "version": "0.63.4",
4
+ "version": "0.63.6",
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",
@@ -52,9 +52,9 @@
52
52
  "dependencies": {
53
53
  "css-tree": "^3.0.0",
54
54
  "magic-string": "^0.30.11",
55
- "@unocss/config": "0.63.4",
56
- "@unocss/reset": "0.63.4",
57
- "@unocss/preset-uno": "0.63.4"
55
+ "@unocss/reset": "0.63.6",
56
+ "@unocss/preset-uno": "0.63.6",
57
+ "@unocss/config": "0.63.6"
58
58
  },
59
59
  "devDependencies": {
60
60
  "prettier-plugin-svelte": "^2.10.1",