@vuact/runtime-dom 3.5.13-vuact.2 → 3.5.16-vuact.0

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,5 +1,5 @@
1
1
  /**
2
- * @vuactjs/runtime-dom v3.5.13
2
+ * @vue/runtime-dom v3.5.16
3
3
  * (c) 2018-present Yuxi (Evan) You and Vue contributors
4
4
  * @license MIT
5
5
  **/
@@ -10,7 +10,7 @@ Object.defineProperty(exports, '__esModule', { value: true });
10
10
  var runtimeCore = require('@vue/runtime-core');
11
11
  var shared = require('@vue/shared');
12
12
 
13
- let policy = undefined;
13
+ let policy = void 0;
14
14
  const tt = typeof window !== "undefined" && window.trustedTypes;
15
15
  if (tt) {
16
16
  try {
@@ -236,11 +236,11 @@ function resolveTransitionProps(rawProps) {
236
236
  callHook(onLeave, [el, resolve]);
237
237
  },
238
238
  onEnterCancelled(el) {
239
- finishEnter(el, false, undefined, true);
239
+ finishEnter(el, false, void 0, true);
240
240
  callHook(onEnterCancelled, [el]);
241
241
  },
242
242
  onAppearCancelled(el) {
243
- finishEnter(el, true, undefined, true);
243
+ finishEnter(el, true, void 0, true);
244
244
  callHook(onAppearCancelled, [el]);
245
245
  },
246
246
  onLeaveCancelled(el) {
@@ -276,7 +276,7 @@ function removeTransitionClass(el, cls) {
276
276
  if (_vtc) {
277
277
  _vtc.delete(cls);
278
278
  if (!_vtc.size) {
279
- el[vtcKey] = undefined;
279
+ el[vtcKey] = void 0;
280
280
  }
281
281
  }
282
282
  }
@@ -634,7 +634,7 @@ function patchEvent(el, rawName, prevValue, nextValue, instance = null) {
634
634
  addEventListener(el, name, invoker, options);
635
635
  } else if (existingInvoker) {
636
636
  removeEventListener(el, name, existingInvoker, options);
637
- invokers[rawName] = undefined;
637
+ invokers[rawName] = void 0;
638
638
  }
639
639
  }
640
640
  }
@@ -739,7 +739,7 @@ function shouldSetAsProp(el, key, value, isSVG) {
739
739
  }
740
740
  return false;
741
741
  }
742
- if (key === "spellcheck" || key === "draggable" || key === "translate") {
742
+ if (key === "spellcheck" || key === "draggable" || key === "translate" || key === "autocorrect") {
743
743
  return false;
744
744
  }
745
745
  if (key === "form") {
@@ -822,13 +822,10 @@ class VueElement extends BaseClass {
822
822
  this._root = this;
823
823
  }
824
824
  }
825
- if (!this._def.__asyncLoader) {
826
- this._resolveProps(this._def);
827
- }
828
825
  }
829
826
  connectedCallback() {
830
827
  if (!this.isConnected) return;
831
- if (!this.shadowRoot) {
828
+ if (!this.shadowRoot && !this._resolved) {
832
829
  this._parseSlots();
833
830
  }
834
831
  this._connected = true;
@@ -841,12 +838,11 @@ class VueElement extends BaseClass {
841
838
  }
842
839
  if (!this._instance) {
843
840
  if (this._resolved) {
844
- this._setParent();
845
- this._update();
841
+ this._mount(this._def);
846
842
  } else {
847
843
  if (parent && parent._pendingResolve) {
848
844
  this._pendingResolve = parent._pendingResolve.then(() => {
849
- this._pendingResolve = undefined;
845
+ this._pendingResolve = void 0;
850
846
  this._resolveDef();
851
847
  });
852
848
  } else {
@@ -858,7 +854,15 @@ class VueElement extends BaseClass {
858
854
  _setParent(parent = this._parent) {
859
855
  if (parent) {
860
856
  this._instance.parent = parent._instance;
861
- this._instance.provides = parent._instance.provides;
857
+ this._inheritParentContext(parent);
858
+ }
859
+ }
860
+ _inheritParentContext(parent = this._parent) {
861
+ if (parent && this._app) {
862
+ Object.setPrototypeOf(
863
+ this._app._context.provides,
864
+ parent._instance.provides
865
+ );
862
866
  }
863
867
  }
864
868
  disconnectedCallback() {
@@ -870,7 +874,7 @@ class VueElement extends BaseClass {
870
874
  this._ob = null;
871
875
  }
872
876
  this._app && this._app.unmount();
873
- if (this._instance) this._instance.ce = undefined;
877
+ if (this._instance) this._instance.ce = void 0;
874
878
  this._app = this._instance = null;
875
879
  }
876
880
  });
@@ -893,7 +897,7 @@ class VueElement extends BaseClass {
893
897
  this._ob.observe(this, { attributes: true });
894
898
  const resolve = (def, isAsync = false) => {
895
899
  this._resolved = true;
896
- this._pendingResolve = undefined;
900
+ this._pendingResolve = void 0;
897
901
  const { props, styles } = def;
898
902
  let numberProps;
899
903
  if (props && !shared.isArray(props)) {
@@ -908,9 +912,7 @@ class VueElement extends BaseClass {
908
912
  }
909
913
  }
910
914
  this._numberProps = numberProps;
911
- if (isAsync) {
912
- this._resolveProps(def);
913
- }
915
+ this._resolveProps(def);
914
916
  if (this.shadowRoot) {
915
917
  this._applyStyles(styles);
916
918
  } else if (styles) {
@@ -934,6 +936,7 @@ class VueElement extends BaseClass {
934
936
  def.name = "VueElement";
935
937
  }
936
938
  this._app = this._createApp(def);
939
+ this._inheritParentContext();
937
940
  if (def.configureApp) {
938
941
  def.configureApp(this._app);
939
942
  }
@@ -1018,7 +1021,9 @@ class VueElement extends BaseClass {
1018
1021
  }
1019
1022
  }
1020
1023
  _update() {
1021
- render(this._createVNode(), this._root);
1024
+ const vnode = this._createVNode();
1025
+ if (this._app) vnode.appContext = this._app._context;
1026
+ render(vnode, this._root);
1022
1027
  }
1023
1028
  _createVNode() {
1024
1029
  const baseProps = {};
@@ -1228,6 +1233,7 @@ const TransitionGroupImpl = /* @__PURE__ */ decorate({
1228
1233
  instance.vnode.el,
1229
1234
  moveClass
1230
1235
  )) {
1236
+ prevChildren = [];
1231
1237
  return;
1232
1238
  }
1233
1239
  prevChildren.forEach(callPendingCbs);
@@ -1251,6 +1257,7 @@ const TransitionGroupImpl = /* @__PURE__ */ decorate({
1251
1257
  };
1252
1258
  el.addEventListener("transitionend", cb);
1253
1259
  });
1260
+ prevChildren = [];
1254
1261
  });
1255
1262
  return () => {
1256
1263
  const rawProps = runtimeCore.toRaw(props);
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @vuactjs/runtime-dom v3.5.13
2
+ * @vue/runtime-dom v3.5.16
3
3
  * (c) 2018-present Yuxi (Evan) You and Vue contributors
4
4
  * @license MIT
5
5
  **/
@@ -10,7 +10,7 @@ Object.defineProperty(exports, '__esModule', { value: true });
10
10
  var runtimeCore = require('@vue/runtime-core');
11
11
  var shared = require('@vue/shared');
12
12
 
13
- let policy = undefined;
13
+ let policy = void 0;
14
14
  const tt = typeof window !== "undefined" && window.trustedTypes;
15
15
  if (tt) {
16
16
  try {
@@ -235,11 +235,11 @@ function resolveTransitionProps(rawProps) {
235
235
  callHook(onLeave, [el, resolve]);
236
236
  },
237
237
  onEnterCancelled(el) {
238
- finishEnter(el, false, undefined, true);
238
+ finishEnter(el, false, void 0, true);
239
239
  callHook(onEnterCancelled, [el]);
240
240
  },
241
241
  onAppearCancelled(el) {
242
- finishEnter(el, true, undefined, true);
242
+ finishEnter(el, true, void 0, true);
243
243
  callHook(onAppearCancelled, [el]);
244
244
  },
245
245
  onLeaveCancelled(el) {
@@ -272,7 +272,7 @@ function removeTransitionClass(el, cls) {
272
272
  if (_vtc) {
273
273
  _vtc.delete(cls);
274
274
  if (!_vtc.size) {
275
- el[vtcKey] = undefined;
275
+ el[vtcKey] = void 0;
276
276
  }
277
277
  }
278
278
  }
@@ -613,7 +613,7 @@ function patchEvent(el, rawName, prevValue, nextValue, instance = null) {
613
613
  addEventListener(el, name, invoker, options);
614
614
  } else if (existingInvoker) {
615
615
  removeEventListener(el, name, existingInvoker, options);
616
- invokers[rawName] = undefined;
616
+ invokers[rawName] = void 0;
617
617
  }
618
618
  }
619
619
  }
@@ -708,7 +708,7 @@ function shouldSetAsProp(el, key, value, isSVG) {
708
708
  }
709
709
  return false;
710
710
  }
711
- if (key === "spellcheck" || key === "draggable" || key === "translate") {
711
+ if (key === "spellcheck" || key === "draggable" || key === "translate" || key === "autocorrect") {
712
712
  return false;
713
713
  }
714
714
  if (key === "form") {
@@ -786,13 +786,10 @@ class VueElement extends BaseClass {
786
786
  this._root = this;
787
787
  }
788
788
  }
789
- if (!this._def.__asyncLoader) {
790
- this._resolveProps(this._def);
791
- }
792
789
  }
793
790
  connectedCallback() {
794
791
  if (!this.isConnected) return;
795
- if (!this.shadowRoot) {
792
+ if (!this.shadowRoot && !this._resolved) {
796
793
  this._parseSlots();
797
794
  }
798
795
  this._connected = true;
@@ -805,12 +802,11 @@ class VueElement extends BaseClass {
805
802
  }
806
803
  if (!this._instance) {
807
804
  if (this._resolved) {
808
- this._setParent();
809
- this._update();
805
+ this._mount(this._def);
810
806
  } else {
811
807
  if (parent && parent._pendingResolve) {
812
808
  this._pendingResolve = parent._pendingResolve.then(() => {
813
- this._pendingResolve = undefined;
809
+ this._pendingResolve = void 0;
814
810
  this._resolveDef();
815
811
  });
816
812
  } else {
@@ -822,7 +818,15 @@ class VueElement extends BaseClass {
822
818
  _setParent(parent = this._parent) {
823
819
  if (parent) {
824
820
  this._instance.parent = parent._instance;
825
- this._instance.provides = parent._instance.provides;
821
+ this._inheritParentContext(parent);
822
+ }
823
+ }
824
+ _inheritParentContext(parent = this._parent) {
825
+ if (parent && this._app) {
826
+ Object.setPrototypeOf(
827
+ this._app._context.provides,
828
+ parent._instance.provides
829
+ );
826
830
  }
827
831
  }
828
832
  disconnectedCallback() {
@@ -834,7 +838,7 @@ class VueElement extends BaseClass {
834
838
  this._ob = null;
835
839
  }
836
840
  this._app && this._app.unmount();
837
- if (this._instance) this._instance.ce = undefined;
841
+ if (this._instance) this._instance.ce = void 0;
838
842
  this._app = this._instance = null;
839
843
  }
840
844
  });
@@ -857,7 +861,7 @@ class VueElement extends BaseClass {
857
861
  this._ob.observe(this, { attributes: true });
858
862
  const resolve = (def, isAsync = false) => {
859
863
  this._resolved = true;
860
- this._pendingResolve = undefined;
864
+ this._pendingResolve = void 0;
861
865
  const { props, styles } = def;
862
866
  let numberProps;
863
867
  if (props && !shared.isArray(props)) {
@@ -872,9 +876,7 @@ class VueElement extends BaseClass {
872
876
  }
873
877
  }
874
878
  this._numberProps = numberProps;
875
- if (isAsync) {
876
- this._resolveProps(def);
877
- }
879
+ this._resolveProps(def);
878
880
  if (this.shadowRoot) {
879
881
  this._applyStyles(styles);
880
882
  }
@@ -891,6 +893,7 @@ class VueElement extends BaseClass {
891
893
  }
892
894
  _mount(def) {
893
895
  this._app = this._createApp(def);
896
+ this._inheritParentContext();
894
897
  if (def.configureApp) {
895
898
  def.configureApp(this._app);
896
899
  }
@@ -973,7 +976,9 @@ class VueElement extends BaseClass {
973
976
  }
974
977
  }
975
978
  _update() {
976
- render(this._createVNode(), this._root);
979
+ const vnode = this._createVNode();
980
+ if (this._app) vnode.appContext = this._app._context;
981
+ render(vnode, this._root);
977
982
  }
978
983
  _createVNode() {
979
984
  const baseProps = {};
@@ -1135,6 +1140,7 @@ const TransitionGroupImpl = /* @__PURE__ */ decorate({
1135
1140
  instance.vnode.el,
1136
1141
  moveClass
1137
1142
  )) {
1143
+ prevChildren = [];
1138
1144
  return;
1139
1145
  }
1140
1146
  prevChildren.forEach(callPendingCbs);
@@ -1158,6 +1164,7 @@ const TransitionGroupImpl = /* @__PURE__ */ decorate({
1158
1164
  };
1159
1165
  el.addEventListener("transitionend", cb);
1160
1166
  });
1167
+ prevChildren = [];
1161
1168
  });
1162
1169
  return () => {
1163
1170
  const rawProps = runtimeCore.toRaw(props);