@unocss/preset-attributify 0.60.2 → 0.60.3
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/dist/index.mjs +5 -5
- package/package.json +2 -2
package/dist/index.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { isAttributifySelector, isValidSelector, definePreset } from '@unocss/core';
|
|
2
2
|
|
|
3
|
-
const variantsRE = /^(?!.*\[
|
|
3
|
+
const variantsRE = /^(?!.*\[[^:]+:.+\]$)((?:.+:)?!?)(.*)$/;
|
|
4
4
|
function variantAttributify(options = {}) {
|
|
5
5
|
const prefix = options.prefix ?? "un-";
|
|
6
6
|
const prefixedOnly = options.prefixedOnly ?? false;
|
|
@@ -38,8 +38,8 @@ function variantAttributify(options = {}) {
|
|
|
38
38
|
};
|
|
39
39
|
}
|
|
40
40
|
|
|
41
|
-
const elementRE$1 = /(<\w[\w
|
|
42
|
-
const valuedAttributeRE$1 = /(
|
|
41
|
+
const elementRE$1 = /(<\w[\w:.$-]*\s)((?:'[^>']*'|"[^>"]*"|`[^>`]*`|\{[^>}]*\}|[^>]*?)*)/g;
|
|
42
|
+
const valuedAttributeRE$1 = /(\?|(?!\d|-{2}|-\d)[\w\u00A0-\uFFFF-:%]+)(?:=("[^"]*|'[^']*))?/g;
|
|
43
43
|
const splitterRE$1 = /[\s'"`;>]+/;
|
|
44
44
|
function autocompleteExtractorAttributify(options) {
|
|
45
45
|
return {
|
|
@@ -132,8 +132,8 @@ const strippedPrefixes = [
|
|
|
132
132
|
":"
|
|
133
133
|
];
|
|
134
134
|
const splitterRE = /[\s'"`;]+/g;
|
|
135
|
-
const elementRE = /<[^>\s]*\s((?:'
|
|
136
|
-
const valuedAttributeRE = /(
|
|
135
|
+
const elementRE = /<[^>\s]*\s((?:'[^']*'|"[^"]*"|`[^`]*`|\{[^}]*\}|=>|[^>]*?)*)/g;
|
|
136
|
+
const valuedAttributeRE = /(\?|(?!\d|-{2}|-\d)[\w\u00A0-\uFFFF:!%.~<-]+)=?(?:"([^"]*)"|'([^']*)'|\{([^}]*)\})?/g;
|
|
137
137
|
const defaultIgnoreAttributes = ["placeholder", "fill", "opacity", "stroke-opacity"];
|
|
138
138
|
function extractorAttributify(options) {
|
|
139
139
|
const ignoreAttributes = options?.ignoreAttributes ?? defaultIgnoreAttributes;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@unocss/preset-attributify",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.60.
|
|
4
|
+
"version": "0.60.3",
|
|
5
5
|
"description": "Attributify preset for UnoCSS",
|
|
6
6
|
"author": "Anthony Fu <anthonyfu117@hotmail.com>",
|
|
7
7
|
"license": "MIT",
|
|
@@ -33,7 +33,7 @@
|
|
|
33
33
|
"dist"
|
|
34
34
|
],
|
|
35
35
|
"dependencies": {
|
|
36
|
-
"@unocss/core": "0.60.
|
|
36
|
+
"@unocss/core": "0.60.3"
|
|
37
37
|
},
|
|
38
38
|
"scripts": {
|
|
39
39
|
"build": "unbuild",
|