@vue/compat 3.4.21 → 3.4.22

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,11 +1,13 @@
1
1
  /**
2
- * @vue/compat v3.4.21
2
+ * @vue/compat v3.4.22
3
3
  * (c) 2018-present Yuxi (Evan) You and Vue contributors
4
4
  * @license MIT
5
5
  **/
6
6
  var Vue = (function () {
7
7
  'use strict';
8
8
 
9
+ /*! #__NO_SIDE_EFFECTS__ */
10
+ // @__NO_SIDE_EFFECTS__
9
11
  function makeMap(str, expectsLowerCase) {
10
12
  const set = new Set(str.split(","));
11
13
  return expectsLowerCase ? (val) => set.has(val.toLowerCase()) : (val) => set.has(val);
@@ -357,7 +359,11 @@ var Vue = (function () {
357
359
  };
358
360
  const stringifySymbol = (v, i = "") => {
359
361
  var _a;
360
- return isSymbol(v) ? `Symbol(${(_a = v.description) != null ? _a : i})` : v;
362
+ return (
363
+ // Symbol.description in es2019+ so we need to cast here to pass
364
+ // the lib: es2016 check
365
+ isSymbol(v) ? `Symbol(${(_a = v.description) != null ? _a : i})` : v
366
+ );
361
367
  };
362
368
 
363
369
  function warn$2(msg, ...args) {
@@ -793,6 +799,8 @@ var Vue = (function () {
793
799
  return instrumentations;
794
800
  }
795
801
  function hasOwnProperty(key) {
802
+ if (!isSymbol(key))
803
+ key = String(key);
796
804
  const obj = toRaw(this);
797
805
  track(obj, "has", key);
798
806
  return obj.hasOwnProperty(key);
@@ -1145,23 +1153,16 @@ var Vue = (function () {
1145
1153
  clear: createReadonlyMethod("clear"),
1146
1154
  forEach: createForEach(true, true)
1147
1155
  };
1148
- const iteratorMethods = ["keys", "values", "entries", Symbol.iterator];
1156
+ const iteratorMethods = [
1157
+ "keys",
1158
+ "values",
1159
+ "entries",
1160
+ Symbol.iterator
1161
+ ];
1149
1162
  iteratorMethods.forEach((method) => {
1150
- mutableInstrumentations2[method] = createIterableMethod(
1151
- method,
1152
- false,
1153
- false
1154
- );
1155
- readonlyInstrumentations2[method] = createIterableMethod(
1156
- method,
1157
- true,
1158
- false
1159
- );
1160
- shallowInstrumentations2[method] = createIterableMethod(
1161
- method,
1162
- false,
1163
- true
1164
- );
1163
+ mutableInstrumentations2[method] = createIterableMethod(method, false, false);
1164
+ readonlyInstrumentations2[method] = createIterableMethod(method, true, false);
1165
+ shallowInstrumentations2[method] = createIterableMethod(method, false, true);
1165
1166
  shallowReadonlyInstrumentations2[method] = createIterableMethod(
1166
1167
  method,
1167
1168
  true,
@@ -1318,7 +1319,7 @@ var Vue = (function () {
1318
1319
  return !!(value && value["__v_isShallow"]);
1319
1320
  }
1320
1321
  function isProxy(value) {
1321
- return isReactive(value) || isReadonly(value);
1322
+ return value ? !!value["__v_raw"] : false;
1322
1323
  }
1323
1324
  function toRaw(observed) {
1324
1325
  const raw = observed && observed["__v_raw"];
@@ -1780,11 +1781,17 @@ getter: `, this.getter);
1780
1781
  }
1781
1782
  return res;
1782
1783
  }
1783
- const values = [];
1784
- for (let i = 0; i < fn.length; i++) {
1785
- values.push(callWithAsyncErrorHandling(fn[i], instance, type, args));
1784
+ if (isArray(fn)) {
1785
+ const values = [];
1786
+ for (let i = 0; i < fn.length; i++) {
1787
+ values.push(callWithAsyncErrorHandling(fn[i], instance, type, args));
1788
+ }
1789
+ return values;
1790
+ } else {
1791
+ warn$1(
1792
+ `Invalid value type passed to callWithAsyncErrorHandling(): ${typeof fn}`
1793
+ );
1786
1794
  }
1787
- return values;
1788
1795
  }
1789
1796
  function handleError(err, instance, type, throwInDev = true) {
1790
1797
  const contextVNode = instance ? instance.vnode : null;
@@ -1805,12 +1812,14 @@ getter: `, this.getter);
1805
1812
  }
1806
1813
  const appErrorHandler = instance.appContext.config.errorHandler;
1807
1814
  if (appErrorHandler) {
1815
+ pauseTracking();
1808
1816
  callWithErrorHandling(
1809
1817
  appErrorHandler,
1810
1818
  null,
1811
1819
  10,
1812
1820
  [err, exposedInstance, errorInfo]
1813
1821
  );
1822
+ resetTracking();
1814
1823
  return;
1815
1824
  }
1816
1825
  }
@@ -2186,6 +2195,8 @@ getter: `, this.getter);
2186
2195
  _devtoolsComponentRemoved(component);
2187
2196
  }
2188
2197
  };
2198
+ /*! #__NO_SIDE_EFFECTS__ */
2199
+ // @__NO_SIDE_EFFECTS__
2189
2200
  function createDevtoolsComponentHook(hook) {
2190
2201
  return (component) => {
2191
2202
  emit$2(
@@ -4831,7 +4842,7 @@ If this is a native custom element, make sure to exclude it from component resol
4831
4842
  return () => {
4832
4843
  pendingCacheKey = null;
4833
4844
  if (!slots.default) {
4834
- return null;
4845
+ return current = null;
4835
4846
  }
4836
4847
  const children = slots.default();
4837
4848
  const rawVNode = children[0];
@@ -5562,47 +5573,74 @@ If this is a native custom element, make sure to exclude it from component resol
5562
5573
  $once: (i) => once.bind(null, i),
5563
5574
  $off: (i) => off.bind(null, i),
5564
5575
  $children: getCompatChildren,
5565
- $listeners: getCompatListeners
5576
+ $listeners: getCompatListeners,
5577
+ // inject additional properties into $options for compat
5578
+ // e.g. vuex needs this.$options.parent
5579
+ $options: (i) => {
5580
+ if (!isCompatEnabled$1("PRIVATE_APIS", i)) {
5581
+ return resolveMergedOptions(i);
5582
+ }
5583
+ if (i.resolvedOptions) {
5584
+ return i.resolvedOptions;
5585
+ }
5586
+ const res = i.resolvedOptions = extend({}, resolveMergedOptions(i));
5587
+ Object.defineProperties(res, {
5588
+ parent: {
5589
+ get() {
5590
+ warnDeprecation$1("PRIVATE_APIS", i, "$options.parent");
5591
+ return i.proxy.$parent;
5592
+ }
5593
+ },
5594
+ propsData: {
5595
+ get() {
5596
+ warnDeprecation$1(
5597
+ "PRIVATE_APIS",
5598
+ i,
5599
+ "$options.propsData"
5600
+ );
5601
+ return i.vnode.props;
5602
+ }
5603
+ }
5604
+ });
5605
+ return res;
5606
+ }
5566
5607
  });
5567
- if (isCompatEnabled$1("PRIVATE_APIS", null)) {
5568
- extend(map, {
5569
- // needed by many libs / render fns
5570
- $vnode: (i) => i.vnode,
5571
- // inject additional properties into $options for compat
5572
- // e.g. vuex needs this.$options.parent
5573
- $options: (i) => {
5574
- const res = extend({}, resolveMergedOptions(i));
5575
- res.parent = i.proxy.$parent;
5576
- res.propsData = i.vnode.props;
5577
- return res;
5578
- },
5579
- // some private properties that are likely accessed...
5580
- _self: (i) => i.proxy,
5581
- _uid: (i) => i.uid,
5582
- _data: (i) => i.data,
5583
- _isMounted: (i) => i.isMounted,
5584
- _isDestroyed: (i) => i.isUnmounted,
5585
- // v2 render helpers
5586
- $createElement: () => compatH,
5587
- _c: () => compatH,
5588
- _o: () => legacyMarkOnce,
5589
- _n: () => looseToNumber,
5590
- _s: () => toDisplayString,
5591
- _l: () => renderList,
5592
- _t: (i) => legacyRenderSlot.bind(null, i),
5593
- _q: () => looseEqual,
5594
- _i: () => looseIndexOf,
5595
- _m: (i) => legacyRenderStatic.bind(null, i),
5596
- _f: () => resolveFilter$1,
5597
- _k: (i) => legacyCheckKeyCodes.bind(null, i),
5598
- _b: () => legacyBindObjectProps,
5599
- _v: () => createTextVNode,
5600
- _e: () => createCommentVNode,
5601
- _u: () => legacyresolveScopedSlots,
5602
- _g: () => legacyBindObjectListeners,
5603
- _d: () => legacyBindDynamicKeys,
5604
- _p: () => legacyPrependModifier
5605
- });
5608
+ const privateAPIs = {
5609
+ // needed by many libs / render fns
5610
+ $vnode: (i) => i.vnode,
5611
+ // some private properties that are likely accessed...
5612
+ _self: (i) => i.proxy,
5613
+ _uid: (i) => i.uid,
5614
+ _data: (i) => i.data,
5615
+ _isMounted: (i) => i.isMounted,
5616
+ _isDestroyed: (i) => i.isUnmounted,
5617
+ // v2 render helpers
5618
+ $createElement: () => compatH,
5619
+ _c: () => compatH,
5620
+ _o: () => legacyMarkOnce,
5621
+ _n: () => looseToNumber,
5622
+ _s: () => toDisplayString,
5623
+ _l: () => renderList,
5624
+ _t: (i) => legacyRenderSlot.bind(null, i),
5625
+ _q: () => looseEqual,
5626
+ _i: () => looseIndexOf,
5627
+ _m: (i) => legacyRenderStatic.bind(null, i),
5628
+ _f: () => resolveFilter$1,
5629
+ _k: (i) => legacyCheckKeyCodes.bind(null, i),
5630
+ _b: () => legacyBindObjectProps,
5631
+ _v: () => createTextVNode,
5632
+ _e: () => createCommentVNode,
5633
+ _u: () => legacyresolveScopedSlots,
5634
+ _g: () => legacyBindObjectListeners,
5635
+ _d: () => legacyBindDynamicKeys,
5636
+ _p: () => legacyPrependModifier
5637
+ };
5638
+ for (const key in privateAPIs) {
5639
+ map[key] = (i) => {
5640
+ if (isCompatEnabled$1("PRIVATE_APIS", i)) {
5641
+ return privateAPIs[key](i);
5642
+ }
5643
+ };
5606
5644
  }
5607
5645
  }
5608
5646
 
@@ -5643,6 +5681,9 @@ If this is a native custom element, make sure to exclude it from component resol
5643
5681
  const hasSetupBinding = (state, key) => state !== EMPTY_OBJ && !state.__isScriptSetup && hasOwn(state, key);
5644
5682
  const PublicInstanceProxyHandlers = {
5645
5683
  get({ _: instance }, key) {
5684
+ if (key === "__v_skip") {
5685
+ return true;
5686
+ }
5646
5687
  const { ctx, setupState, data, props, accessCache, type, appContext } = instance;
5647
5688
  if (key === "__isVue") {
5648
5689
  return true;
@@ -6497,7 +6538,7 @@ If this is a native custom element, make sure to exclude it from component resol
6497
6538
  return vm;
6498
6539
  }
6499
6540
  }
6500
- Vue.version = `2.6.14-compat:${"3.4.21"}`;
6541
+ Vue.version = `2.6.14-compat:${"3.4.22"}`;
6501
6542
  Vue.config = singletonApp.config;
6502
6543
  Vue.use = (p, ...options) => {
6503
6544
  if (p && isFunction(p.install)) {
@@ -6691,15 +6732,14 @@ If this is a native custom element, make sure to exclude it from component resol
6691
6732
  app.config.globalProperties = Object.create(Ctor.prototype);
6692
6733
  }
6693
6734
  let hasPrototypeAugmentations = false;
6694
- const descriptors = Object.getOwnPropertyDescriptors(Ctor.prototype);
6695
- for (const key in descriptors) {
6735
+ for (const key of Object.getOwnPropertyNames(Ctor.prototype)) {
6696
6736
  if (key !== "constructor") {
6697
6737
  hasPrototypeAugmentations = true;
6698
6738
  if (enabled) {
6699
6739
  Object.defineProperty(
6700
6740
  app.config.globalProperties,
6701
6741
  key,
6702
- descriptors[key]
6742
+ Object.getOwnPropertyDescriptor(Ctor.prototype, key)
6703
6743
  );
6704
6744
  }
6705
6745
  }
@@ -7135,10 +7175,10 @@ If you want to remount the same app, move your app creation logic into a factory
7135
7175
  return false;
7136
7176
  }
7137
7177
 
7178
+ const attrsProto = {};
7138
7179
  function initProps(instance, rawProps, isStateful, isSSR = false) {
7139
7180
  const props = {};
7140
- const attrs = {};
7141
- def(attrs, InternalObjectKey, 1);
7181
+ const attrs = Object.create(attrsProto);
7142
7182
  instance.propsDefaults = /* @__PURE__ */ Object.create(null);
7143
7183
  setFullProps(instance, rawProps, props, attrs);
7144
7184
  for (const key in instance.propsOptions[0]) {
@@ -7260,7 +7300,7 @@ If you want to remount the same app, move your app creation logic into a factory
7260
7300
  }
7261
7301
  }
7262
7302
  if (hasAttrsChanged) {
7263
- trigger(instance, "set", "$attrs");
7303
+ trigger(instance.attrs, "set", "");
7264
7304
  }
7265
7305
  {
7266
7306
  validateProps(rawProps || {}, props, instance);
@@ -7618,7 +7658,7 @@ If you want to remount the same app, move your app creation logic into a factory
7618
7658
  const type = children._;
7619
7659
  if (type) {
7620
7660
  instance.slots = toRaw(children);
7621
- def(children, "_", type);
7661
+ def(instance.slots, "_", type);
7622
7662
  } else {
7623
7663
  normalizeObjectSlots(
7624
7664
  children,
@@ -7632,7 +7672,6 @@ If you want to remount the same app, move your app creation logic into a factory
7632
7672
  normalizeVNodeSlots(instance, children);
7633
7673
  }
7634
7674
  }
7635
- def(instance.slots, InternalObjectKey, 1);
7636
7675
  };
7637
7676
  const updateSlots = (instance, children, optimized) => {
7638
7677
  const { vnode, slots } = instance;
@@ -7804,6 +7843,7 @@ If you want to remount the same app, move your app creation logic into a factory
7804
7843
  }
7805
7844
  };
7806
7845
  const hydrateNode = (node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized = false) => {
7846
+ optimized = optimized || !!vnode.dynamicChildren;
7807
7847
  const isFragmentStart = isComment(node) && node.data === "[";
7808
7848
  const onMismatch = () => handleMismatch(
7809
7849
  node,
@@ -10323,7 +10363,6 @@ Server rendered element contains fewer child nodes than client vdom.`
10323
10363
  ...vnodeArgsTransformer ? vnodeArgsTransformer(args, currentRenderingInstance) : args
10324
10364
  );
10325
10365
  };
10326
- const InternalObjectKey = `__vInternal`;
10327
10366
  const normalizeKey = ({ key }) => key != null ? key : null;
10328
10367
  const normalizeRef = ({
10329
10368
  ref,
@@ -10463,7 +10502,7 @@ Component that was made reactive: `,
10463
10502
  function guardReactiveProps(props) {
10464
10503
  if (!props)
10465
10504
  return null;
10466
- return isProxy(props) || InternalObjectKey in props ? extend({}, props) : props;
10505
+ return isProxy(props) || Object.getPrototypeOf(props) === attrsProto ? extend({}, props) : props;
10467
10506
  }
10468
10507
  function cloneVNode(vnode, extraProps, mergeRef = false) {
10469
10508
  const { props, ref, patchFlag, children } = vnode;
@@ -10571,7 +10610,7 @@ Component that was made reactive: `,
10571
10610
  } else {
10572
10611
  type = 32;
10573
10612
  const slotFlag = children._;
10574
- if (!slotFlag && !(InternalObjectKey in children)) {
10613
+ if (!slotFlag) {
10575
10614
  children._ctx = currentRenderingInstance;
10576
10615
  } else if (slotFlag === 3 && currentRenderingInstance) {
10577
10616
  if (currentRenderingInstance.slots._ === 1) {
@@ -10792,7 +10831,7 @@ Component that was made reactive: `,
10792
10831
  }
10793
10832
  }
10794
10833
  instance.accessCache = /* @__PURE__ */ Object.create(null);
10795
- instance.proxy = markRaw(new Proxy(instance.ctx, PublicInstanceProxyHandlers));
10834
+ instance.proxy = new Proxy(instance.ctx, PublicInstanceProxyHandlers);
10796
10835
  {
10797
10836
  exposePropsOnRenderContext(instance);
10798
10837
  }
@@ -10936,26 +10975,21 @@ Component that was made reactive: `,
10936
10975
  }
10937
10976
  }
10938
10977
  }
10939
- function getAttrsProxy(instance) {
10940
- return instance.attrsProxy || (instance.attrsProxy = new Proxy(
10941
- instance.attrs,
10942
- {
10943
- get(target, key) {
10944
- markAttrsAccessed();
10945
- track(instance, "get", "$attrs");
10946
- return target[key];
10947
- },
10948
- set() {
10949
- warn$1(`setupContext.attrs is readonly.`);
10950
- return false;
10951
- },
10952
- deleteProperty() {
10953
- warn$1(`setupContext.attrs is readonly.`);
10954
- return false;
10955
- }
10956
- }
10957
- ));
10958
- }
10978
+ const attrsProxyHandlers = {
10979
+ get(target, key) {
10980
+ markAttrsAccessed();
10981
+ track(target, "get", "");
10982
+ return target[key];
10983
+ },
10984
+ set() {
10985
+ warn$1(`setupContext.attrs is readonly.`);
10986
+ return false;
10987
+ },
10988
+ deleteProperty() {
10989
+ warn$1(`setupContext.attrs is readonly.`);
10990
+ return false;
10991
+ }
10992
+ } ;
10959
10993
  function getSlotsProxy(instance) {
10960
10994
  return instance.slotsProxy || (instance.slotsProxy = new Proxy(instance.slots, {
10961
10995
  get(target, key) {
@@ -10989,9 +11023,10 @@ Component that was made reactive: `,
10989
11023
  instance.exposed = exposed || {};
10990
11024
  };
10991
11025
  {
11026
+ let attrsProxy;
10992
11027
  return Object.freeze({
10993
11028
  get attrs() {
10994
- return getAttrsProxy(instance);
11029
+ return attrsProxy || (attrsProxy = new Proxy(instance.attrs, attrsProxyHandlers));
10995
11030
  },
10996
11031
  get slots() {
10997
11032
  return getSlotsProxy(instance);
@@ -11336,7 +11371,7 @@ Component that was made reactive: `,
11336
11371
  return true;
11337
11372
  }
11338
11373
 
11339
- const version = "3.4.21";
11374
+ const version = "3.4.22";
11340
11375
  const warn = warn$1 ;
11341
11376
  const ErrorTypeStrings = ErrorTypeStrings$1 ;
11342
11377
  const devtools = devtools$1 ;
@@ -11806,8 +11841,8 @@ Component that was made reactive: `,
11806
11841
  setVarsOnVNode(instance.subTree, vars);
11807
11842
  updateTeleports(vars);
11808
11843
  };
11809
- watchPostEffect(setVars);
11810
11844
  onMounted(() => {
11845
+ watchPostEffect(setVars);
11811
11846
  const ob = new MutationObserver(setVars);
11812
11847
  ob.observe(instance.subTree.el.parentNode, { childList: true });
11813
11848
  onUnmounted(() => ob.disconnect());
@@ -12073,11 +12108,14 @@ Component that was made reactive: `,
12073
12108
  const invokers = el[veiKey] || (el[veiKey] = {});
12074
12109
  const existingInvoker = invokers[rawName];
12075
12110
  if (nextValue && existingInvoker) {
12076
- existingInvoker.value = nextValue;
12111
+ existingInvoker.value = sanitizeEventValue(nextValue, rawName) ;
12077
12112
  } else {
12078
12113
  const [name, options] = parseName(rawName);
12079
12114
  if (nextValue) {
12080
- const invoker = invokers[rawName] = createInvoker(nextValue, instance);
12115
+ const invoker = invokers[rawName] = createInvoker(
12116
+ sanitizeEventValue(nextValue, rawName) ,
12117
+ instance
12118
+ );
12081
12119
  addEventListener(el, name, invoker, options);
12082
12120
  } else if (existingInvoker) {
12083
12121
  removeEventListener(el, name, existingInvoker, options);
@@ -12120,6 +12158,16 @@ Component that was made reactive: `,
12120
12158
  invoker.attached = getNow();
12121
12159
  return invoker;
12122
12160
  }
12161
+ function sanitizeEventValue(value, propName) {
12162
+ if (isFunction(value) || isArray(value)) {
12163
+ return value;
12164
+ }
12165
+ warn(
12166
+ `Wrong type passed as event handler to ${propName} - did you forget @ or : in front of your prop?
12167
+ Expected function or array of functions, received type ${typeof value}.`
12168
+ );
12169
+ return NOOP;
12170
+ }
12123
12171
  function patchStopImmediatePropagation(e, value) {
12124
12172
  if (isArray(value)) {
12125
12173
  const originalStop = e.stopImmediatePropagation;
@@ -12127,7 +12175,9 @@ Component that was made reactive: `,
12127
12175
  originalStop.call(e);
12128
12176
  e._stopped = true;
12129
12177
  };
12130
- return value.map((fn) => (e2) => !e2._stopped && fn && fn(e2));
12178
+ return value.map(
12179
+ (fn) => (e2) => !e2._stopped && fn && fn(e2)
12180
+ );
12131
12181
  } else {
12132
12182
  return value;
12133
12183
  }
@@ -12328,7 +12378,7 @@ Component that was made reactive: `,
12328
12378
  }
12329
12379
  }
12330
12380
  _setAttr(key) {
12331
- let value = this.getAttribute(key);
12381
+ let value = this.hasAttribute(key) ? this.getAttribute(key) : void 0;
12332
12382
  const camelKey = camelize(key);
12333
12383
  if (this._numberProps && this._numberProps[camelKey]) {
12334
12384
  value = toNumber(value);
@@ -12488,7 +12538,28 @@ Component that was made reactive: `,
12488
12538
  )) {
12489
12539
  tag = "span";
12490
12540
  }
12491
- prevChildren = children;
12541
+ prevChildren = [];
12542
+ if (children) {
12543
+ for (let i = 0; i < children.length; i++) {
12544
+ const child = children[i];
12545
+ if (child.el && child.el instanceof Element) {
12546
+ prevChildren.push(child);
12547
+ setTransitionHooks(
12548
+ child,
12549
+ resolveTransitionHooks(
12550
+ child,
12551
+ cssTransitionProps,
12552
+ state,
12553
+ instance
12554
+ )
12555
+ );
12556
+ positionMap.set(
12557
+ child,
12558
+ child.el.getBoundingClientRect()
12559
+ );
12560
+ }
12561
+ }
12562
+ }
12492
12563
  children = slots.default ? getTransitionRawChildren(slots.default()) : [];
12493
12564
  for (let i = 0; i < children.length; i++) {
12494
12565
  const child = children[i];
@@ -12501,16 +12572,6 @@ Component that was made reactive: `,
12501
12572
  warn(`<TransitionGroup> children must be keyed.`);
12502
12573
  }
12503
12574
  }
12504
- if (prevChildren) {
12505
- for (let i = 0; i < prevChildren.length; i++) {
12506
- const child = prevChildren[i];
12507
- setTransitionHooks(
12508
- child,
12509
- resolveTransitionHooks(child, cssTransitionProps, state, instance)
12510
- );
12511
- positionMap.set(child, child.el.getBoundingClientRect());
12512
- }
12513
- }
12514
12575
  return createVNode(tag, null, children);
12515
12576
  };
12516
12577
  }
@@ -12612,7 +12673,7 @@ Component that was made reactive: `,
12612
12673
  el[assignKey] = getModelAssigner(vnode);
12613
12674
  if (el.composing)
12614
12675
  return;
12615
- const elValue = number || el.type === "number" ? looseToNumber(el.value) : el.value;
12676
+ const elValue = (number || el.type === "number") && !/^0\d/.test(el.value) ? looseToNumber(el.value) : el.value;
12616
12677
  const newValue = value == null ? "" : value;
12617
12678
  if (elValue === newValue) {
12618
12679
  return;
@@ -12715,14 +12776,14 @@ Component that was made reactive: `,
12715
12776
  // set value in mounted & updated because <select> relies on its children
12716
12777
  // <option>s.
12717
12778
  mounted(el, { value, modifiers: { number } }) {
12718
- setSelected(el, value, number);
12779
+ setSelected(el, value);
12719
12780
  },
12720
12781
  beforeUpdate(el, _binding, vnode) {
12721
12782
  el[assignKey] = getModelAssigner(vnode);
12722
12783
  },
12723
12784
  updated(el, { value, modifiers: { number } }) {
12724
12785
  if (!el._assigning) {
12725
- setSelected(el, value, number);
12786
+ setSelected(el, value);
12726
12787
  }
12727
12788
  }
12728
12789
  };
@@ -12742,9 +12803,7 @@ Component that was made reactive: `,
12742
12803
  if (isArrayValue) {
12743
12804
  const optionType = typeof optionValue;
12744
12805
  if (optionType === "string" || optionType === "number") {
12745
- option.selected = value.includes(
12746
- number ? looseToNumber(optionValue) : optionValue
12747
- );
12806
+ option.selected = value.some((v) => String(v) === String(optionValue));
12748
12807
  } else {
12749
12808
  option.selected = looseIndexOf(value, optionValue) > -1;
12750
12809
  }
@@ -15065,7 +15124,7 @@ Use a v-bind binding combined with a v-on listener that emits update:x event ins
15065
15124
  if (isImplied) {
15066
15125
  setLocEnd(el.loc, backTrack(end, 60));
15067
15126
  } else {
15068
- setLocEnd(el.loc, end + 1);
15127
+ setLocEnd(el.loc, lookAhead(end, 62) + 1);
15069
15128
  }
15070
15129
  if (tokenizer.inSFCRoot) {
15071
15130
  if (el.children.length) {
@@ -15160,6 +15219,12 @@ Use a v-bind binding combined with a v-on listener that emits update:x event ins
15160
15219
  }
15161
15220
  }
15162
15221
  }
15222
+ function lookAhead(index, c) {
15223
+ let i = index;
15224
+ while (currentInput.charCodeAt(i) !== c && i < currentInput.length - 1)
15225
+ i++;
15226
+ return i;
15227
+ }
15163
15228
  function backTrack(index, c) {
15164
15229
  let i = index;
15165
15230
  while (currentInput.charCodeAt(i) !== c && i >= 0)
@@ -17341,13 +17406,27 @@ Use a v-bind binding combined with a v-on listener that emits update:x event ins
17341
17406
  function resolveComponentType(node, context, ssr = false) {
17342
17407
  let { tag } = node;
17343
17408
  const isExplicitDynamic = isComponentTag(tag);
17344
- const isProp = findProp(node, "is");
17409
+ const isProp = findProp(
17410
+ node,
17411
+ "is",
17412
+ false,
17413
+ true
17414
+ /* allow empty */
17415
+ );
17345
17416
  if (isProp) {
17346
17417
  if (isExplicitDynamic || isCompatEnabled(
17347
17418
  "COMPILER_IS_ON_ELEMENT",
17348
17419
  context
17349
17420
  )) {
17350
- const exp = isProp.type === 6 ? isProp.value && createSimpleExpression(isProp.value.content, true) : isProp.exp;
17421
+ let exp;
17422
+ if (isProp.type === 6) {
17423
+ exp = isProp.value && createSimpleExpression(isProp.value.content, true);
17424
+ } else {
17425
+ exp = isProp.exp;
17426
+ if (!exp) {
17427
+ exp = createSimpleExpression(`is`, false, isProp.loc);
17428
+ }
17429
+ }
17351
17430
  if (exp) {
17352
17431
  return createCallExpression(context.helper(RESOLVE_DYNAMIC_COMPONENT), [
17353
17432
  exp