babel-plugin-jsx-dom-expressions 0.32.0 → 0.32.9

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.
Files changed (2) hide show
  1. package/index.js +13 -8
  2. package/package.json +2 -2
package/index.js CHANGED
@@ -81,6 +81,7 @@ const DelegatedEvents = new Set([
81
81
  "beforeinput",
82
82
  "click",
83
83
  "dblclick",
84
+ "contextmenu",
84
85
  "focusin",
85
86
  "focusout",
86
87
  "input",
@@ -1294,12 +1295,16 @@ function appendTemplates$1(path, templates) {
1294
1295
  };
1295
1296
  return t__namespace.variableDeclarator(
1296
1297
  template.id,
1297
- t__namespace.callExpression(
1298
- registerImportMethod(path, "template"),
1299
- [
1300
- t__namespace.templateLiteral([t__namespace.templateElement(tmpl, true)], []),
1301
- t__namespace.numericLiteral(template.elementCount)
1302
- ].concat(template.isSVG ? t__namespace.booleanLiteral(template.isSVG) : [])
1298
+ t__namespace.addComment(
1299
+ t__namespace.callExpression(
1300
+ registerImportMethod(path, "template"),
1301
+ [
1302
+ t__namespace.templateLiteral([t__namespace.templateElement(tmpl, true)], []),
1303
+ t__namespace.numericLiteral(template.elementCount)
1304
+ ].concat(template.isSVG ? t__namespace.booleanLiteral(template.isSVG) : [])
1305
+ ),
1306
+ 'leading',
1307
+ '#__PURE__'
1303
1308
  )
1304
1309
  );
1305
1310
  });
@@ -1637,7 +1642,7 @@ function transformAttributes$1(path, results) {
1637
1642
  if (attr.name.name === "classList") {
1638
1643
  if (t__namespace.isObjectExpression(expr) && !expr.properties.some(p => t__namespace.isSpreadElement(p))) {
1639
1644
  transformClasslistObject(path, expr, values, quasis);
1640
- i && attributes.splice(attributes.indexOf(classAttributes[i].node), 1);
1645
+ i && attributes.splice(attributes.indexOf(classAttributes[i]), 1);
1641
1646
  continue;
1642
1647
  }
1643
1648
  expr = t__namespace.callExpression(registerImportMethod(path, "ssrClassList"), [expr]);
@@ -1645,7 +1650,7 @@ function transformAttributes$1(path, results) {
1645
1650
  values.push(t__namespace.logicalExpression("||", expr, t__namespace.stringLiteral("")));
1646
1651
  quasis.push(t__namespace.TemplateElement({ raw: isLast ? "" : " " }));
1647
1652
  }
1648
- i && attributes.splice(attributes.indexOf(classAttributes[i].node), 1);
1653
+ i && attributes.splice(attributes.indexOf(classAttributes[i]), 1);
1649
1654
  }
1650
1655
  first.value = t__namespace.JSXExpressionContainer(t__namespace.TemplateLiteral(quasis, values));
1651
1656
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "babel-plugin-jsx-dom-expressions",
3
3
  "description": "A JSX to DOM plugin that wraps expressions for fine grained change detection",
4
- "version": "0.32.0",
4
+ "version": "0.32.9",
5
5
  "author": "Ryan Carniato",
6
6
  "license": "MIT",
7
7
  "repository": {
@@ -23,5 +23,5 @@
23
23
  "@babel/types": "^7.16.0",
24
24
  "html-entities": "2.3.2"
25
25
  },
26
- "gitHead": "6c6759c7f721d1e738b3aead7afb5c3cd0be04fc"
26
+ "gitHead": "8a9b236619e0d18abee5da391cae33e25e82f92a"
27
27
  }