@domql/element 2.5.60 → 2.5.61

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/create.js CHANGED
@@ -152,7 +152,8 @@ const createBasedOnType = (element, parent, key, options) => {
152
152
  const redefineElement = (element, parent, key, options) => {
153
153
  const elementWrapper = createBasedOnType(element, parent, key, options)
154
154
 
155
- if (options.syntaxv3 || (element.props && element.props.syntaxv3)) {
155
+ if (options.syntaxv3 || element.props?.syntaxv3 || parent.props?.syntaxv3) {
156
+ element.props.syntaxv3 = true
156
157
  return createValidDomqlObjectFromSugar(element, parent, key, options)
157
158
  } else if (checkIfKeyIsComponent(key)) {
158
159
  return applyKeyComponentAsExtend(elementWrapper, parent, key)
@@ -115,8 +115,10 @@ const createBasedOnType = (element, parent, key, options) => {
115
115
  return element;
116
116
  };
117
117
  const redefineElement = (element, parent, key, options) => {
118
+ var _a, _b;
118
119
  const elementWrapper = createBasedOnType(element, parent, key, options);
119
- if (options.syntaxv3 || element.props && element.props.syntaxv3) {
120
+ if (options.syntaxv3 || ((_a = element.props) == null ? void 0 : _a.syntaxv3) || ((_b = parent.props) == null ? void 0 : _b.syntaxv3)) {
121
+ element.props.syntaxv3 = true;
120
122
  return (0, import_component.createValidDomqlObjectFromSugar)(element, parent, key, options);
121
123
  } else if ((0, import_component.checkIfKeyIsComponent)(key)) {
122
124
  return (0, import_component.applyKeyComponentAsExtend)(elementWrapper, parent, key);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@domql/element",
3
- "version": "2.5.60",
3
+ "version": "2.5.61",
4
4
  "license": "MIT",
5
5
  "type": "module",
6
6
  "module": "index.js",
@@ -31,7 +31,7 @@
31
31
  "@domql/state": "latest",
32
32
  "@domql/utils": "latest"
33
33
  },
34
- "gitHead": "ea0a85fc95e055393c95181eb56c98e94403bea1",
34
+ "gitHead": "c6aea56536fc17cf5176fed238cf77da99965ed8",
35
35
  "devDependencies": {
36
36
  "@babel/core": "^7.12.0"
37
37
  }