htmljs-parser 5.7.2 → 5.7.4
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.js +9 -1
- package/dist/index.mjs +9 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1737,6 +1737,9 @@ var EXPRESSION = {
|
|
|
1737
1737
|
case 61 /* EQUAL */:
|
|
1738
1738
|
if (expression.operators) {
|
|
1739
1739
|
if (this.lookAtCharCodeAhead(1) === 62 /* CLOSE_ANGLE_BRACKET */) {
|
|
1740
|
+
if (expression.inType && !expression.forceType && this.getPreviousNonWhitespaceCharCode() !== 41 /* CLOSE_PAREN */) {
|
|
1741
|
+
expression.inType = false;
|
|
1742
|
+
}
|
|
1740
1743
|
this.pos++;
|
|
1741
1744
|
} else if (!(expression.forceType || expression.groupStack.length)) {
|
|
1742
1745
|
expression.inType = false;
|
|
@@ -1789,7 +1792,12 @@ var EXPRESSION = {
|
|
|
1789
1792
|
case 41 /* CLOSE_PAREN */:
|
|
1790
1793
|
case 93 /* CLOSE_SQUARE_BRACKET */:
|
|
1791
1794
|
case 125 /* CLOSE_CURLY_BRACE */:
|
|
1792
|
-
case
|
|
1795
|
+
case 62 /* CLOSE_ANGLE_BRACKET */: {
|
|
1796
|
+
if (code === 62 /* CLOSE_ANGLE_BRACKET */) {
|
|
1797
|
+
if (!expression.inType || this.lookAtCharCodeAhead(-1) === 61 /* EQUAL */) {
|
|
1798
|
+
break;
|
|
1799
|
+
}
|
|
1800
|
+
}
|
|
1793
1801
|
if (!expression.groupStack.length) {
|
|
1794
1802
|
return this.emitError(
|
|
1795
1803
|
expression,
|
package/dist/index.mjs
CHANGED
|
@@ -1712,6 +1712,9 @@ var EXPRESSION = {
|
|
|
1712
1712
|
case 61 /* EQUAL */:
|
|
1713
1713
|
if (expression.operators) {
|
|
1714
1714
|
if (this.lookAtCharCodeAhead(1) === 62 /* CLOSE_ANGLE_BRACKET */) {
|
|
1715
|
+
if (expression.inType && !expression.forceType && this.getPreviousNonWhitespaceCharCode() !== 41 /* CLOSE_PAREN */) {
|
|
1716
|
+
expression.inType = false;
|
|
1717
|
+
}
|
|
1715
1718
|
this.pos++;
|
|
1716
1719
|
} else if (!(expression.forceType || expression.groupStack.length)) {
|
|
1717
1720
|
expression.inType = false;
|
|
@@ -1764,7 +1767,12 @@ var EXPRESSION = {
|
|
|
1764
1767
|
case 41 /* CLOSE_PAREN */:
|
|
1765
1768
|
case 93 /* CLOSE_SQUARE_BRACKET */:
|
|
1766
1769
|
case 125 /* CLOSE_CURLY_BRACE */:
|
|
1767
|
-
case
|
|
1770
|
+
case 62 /* CLOSE_ANGLE_BRACKET */: {
|
|
1771
|
+
if (code === 62 /* CLOSE_ANGLE_BRACKET */) {
|
|
1772
|
+
if (!expression.inType || this.lookAtCharCodeAhead(-1) === 61 /* EQUAL */) {
|
|
1773
|
+
break;
|
|
1774
|
+
}
|
|
1775
|
+
}
|
|
1768
1776
|
if (!expression.groupStack.length) {
|
|
1769
1777
|
return this.emitError(
|
|
1770
1778
|
expression,
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "htmljs-parser",
|
|
3
3
|
"description": "An HTML parser recognizes content and string placeholders and allows JavaScript expressions as attribute values",
|
|
4
|
-
"version": "5.7.
|
|
4
|
+
"version": "5.7.4",
|
|
5
5
|
"devDependencies": {
|
|
6
6
|
"@changesets/changelog-github": "^0.5.0",
|
|
7
7
|
"@changesets/cli": "^2.27.1",
|