@vue/shared
Advanced tools
+41
-20
| /** | ||
| * @vue/shared v3.6.0-rc.5 | ||
| * @vue/shared v3.6.0-rc.6 | ||
| * (c) 2018-present Yuxi (Evan) You and Vue contributors | ||
@@ -18,3 +18,3 @@ * @license MIT | ||
| */ | ||
| /* @__NO_SIDE_EFFECTS__ */ | ||
| /*@__NO_SIDE_EFFECTS__*/ | ||
| function makeMap(str) { | ||
@@ -67,5 +67,5 @@ const map = Object.create(null); | ||
| const isIntegerKey = (key) => isString(key) && key !== "NaN" && key[0] !== "-" && "" + parseInt(key, 10) === key; | ||
| const isReservedProp = /* @__PURE__ */ makeMap(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"); | ||
| const isBuiltInTag = /* @__PURE__ */ makeMap("slot,component"); | ||
| const isBuiltInDirective = /* @__PURE__ */ makeMap("bind,cloak,else-if,else,for,html,if,model,on,once,pre,show,slot,text,memo"); | ||
| const isReservedProp = /*@__PURE__*/ makeMap(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"); | ||
| const isBuiltInTag = /*#__PURE__*/ makeMap("slot,component"); | ||
| const isBuiltInDirective = /*@__PURE__*/ makeMap("bind,cloak,else-if,else,for,html,if,model,on,once,pre,show,slot,text,memo"); | ||
| const cacheStringFunction = (fn) => { | ||
@@ -264,3 +264,3 @@ const cache = Object.create(null); | ||
| }; | ||
| const isGloballyAllowed = /* @__PURE__ */ makeMap("Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt,console,Error,Symbol"); | ||
| const isGloballyAllowed = /*@__PURE__*/ makeMap("Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt,console,Error,Symbol"); | ||
| /** @deprecated use `isGloballyAllowed` instead */ | ||
@@ -378,3 +378,3 @@ const isGloballyWhitelisted = isGloballyAllowed; | ||
| */ | ||
| const isHTMLTag = /* @__PURE__ */ makeMap(HTML_TAGS); | ||
| const isHTMLTag = /*@__PURE__*/ makeMap(HTML_TAGS); | ||
| /** | ||
@@ -384,3 +384,3 @@ * Compiler only. | ||
| */ | ||
| const isSVGTag = /* @__PURE__ */ makeMap(SVG_TAGS); | ||
| const isSVGTag = /*@__PURE__*/ makeMap(SVG_TAGS); | ||
| /** | ||
@@ -390,3 +390,3 @@ * Compiler only. | ||
| */ | ||
| const isMathMLTag = /* @__PURE__ */ makeMap(MATH_TAGS); | ||
| const isMathMLTag = /*@__PURE__*/ makeMap(MATH_TAGS); | ||
| /** | ||
@@ -396,3 +396,3 @@ * Compiler only. | ||
| */ | ||
| const isVoidTag = /* @__PURE__ */ makeMap(VOID_TAGS); | ||
| const isVoidTag = /*@__PURE__*/ makeMap(VOID_TAGS); | ||
| /** | ||
@@ -402,3 +402,3 @@ * Compiler only. | ||
| */ | ||
| const isFormattingTag = /* @__PURE__ */ makeMap(FORMATTING_TAGS); | ||
| const isFormattingTag = /*@__PURE__*/ makeMap(FORMATTING_TAGS); | ||
| /** | ||
@@ -408,3 +408,3 @@ * Compiler only. | ||
| */ | ||
| const isAlwaysCloseTag = /* @__PURE__ */ makeMap(ALWAYS_CLOSE_TAGS); | ||
| const isAlwaysCloseTag = /*@__PURE__*/ makeMap(ALWAYS_CLOSE_TAGS); | ||
| /** | ||
@@ -414,3 +414,3 @@ * Compiler only. | ||
| */ | ||
| const isInlineTag = /* @__PURE__ */ makeMap(INLINE_TAGS); | ||
| const isInlineTag = /*@__PURE__*/ makeMap(INLINE_TAGS); | ||
| /** | ||
@@ -420,3 +420,3 @@ * Compiler only. | ||
| */ | ||
| const isBlockTag = /* @__PURE__ */ makeMap(BLOCK_TAGS); | ||
| const isBlockTag = /*@__PURE__*/ makeMap(BLOCK_TAGS); | ||
| //#endregion | ||
@@ -436,7 +436,7 @@ //#region packages/shared/src/domAttrConfig.ts | ||
| const specialBooleanAttrs = `itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly`; | ||
| const isSpecialBooleanAttr = /* @__PURE__ */ makeMap(specialBooleanAttrs); | ||
| const isSpecialBooleanAttr = /*@__PURE__*/ makeMap(specialBooleanAttrs); | ||
| /** | ||
| * The full list is needed during SSR to produce the correct initial markup. | ||
| */ | ||
| const isBooleanAttr = /* @__PURE__ */ makeMap(specialBooleanAttrs + ",async,autofocus,autoplay,controls,default,defer,disabled,inert,loop,open,required,reversed,scoped,seamless,checked,muted,multiple,selected"); | ||
| const isBooleanAttr = /*@__PURE__*/ makeMap(specialBooleanAttrs + ",async,autofocus,autoplay,controls,default,defer,disabled,inert,loop,open,required,reversed,scoped,seamless,checked,muted,multiple,selected"); | ||
| /** | ||
@@ -449,3 +449,3 @@ * Boolean attributes should be included if the value is truthy or ''. | ||
| } | ||
| const unsafeAttrCharRE = /[>/="'\u0009\u000a\u000c\u0020]/; | ||
| const unsafeAttrCharRE = /[>/="'\u0009\u000a\u000c\u000d\u0020]/; | ||
| const attrValidationCache = {}; | ||
@@ -470,11 +470,11 @@ function isSSRSafeAttrName(name) { | ||
| */ | ||
| const isKnownHtmlAttr = /* @__PURE__ */ makeMap("accept,accept-charset,accesskey,action,align,allow,alt,async,autocapitalize,autocomplete,autofocus,autoplay,background,bgcolor,border,buffered,capture,challenge,charset,checked,cite,class,code,codebase,color,cols,colspan,content,contenteditable,contextmenu,controls,coords,crossorigin,csp,data,datetime,decoding,default,defer,dir,dirname,disabled,download,draggable,dropzone,enctype,enterkeyhint,for,form,formaction,formenctype,formmethod,formnovalidate,formtarget,headers,height,hidden,high,href,hreflang,http-equiv,icon,id,importance,inert,integrity,ismap,itemprop,keytype,kind,label,lang,language,loading,list,loop,low,manifest,max,maxlength,minlength,media,min,multiple,muted,name,novalidate,open,optimum,pattern,ping,placeholder,poster,preload,radiogroup,readonly,referrerpolicy,rel,required,reversed,rows,rowspan,sandbox,scope,scoped,selected,shape,size,sizes,slot,span,spellcheck,src,srcdoc,srclang,srcset,start,step,style,summary,tabindex,target,title,translate,type,usemap,value,width,wrap"); | ||
| const isKnownHtmlAttr = /*@__PURE__*/ makeMap("accept,accept-charset,accesskey,action,align,allow,alt,async,autocapitalize,autocomplete,autofocus,autoplay,background,bgcolor,border,buffered,capture,challenge,charset,checked,cite,class,code,codebase,color,cols,colspan,content,contenteditable,contextmenu,controls,coords,crossorigin,csp,data,datetime,decoding,default,defer,dir,dirname,disabled,download,draggable,dropzone,enctype,enterkeyhint,for,form,formaction,formenctype,formmethod,formnovalidate,formtarget,headers,height,hidden,high,href,hreflang,http-equiv,icon,id,importance,inert,integrity,ismap,itemprop,keytype,kind,label,lang,language,loading,list,loop,low,manifest,max,maxlength,minlength,media,min,multiple,muted,name,novalidate,open,optimum,pattern,ping,placeholder,poster,preload,radiogroup,readonly,referrerpolicy,rel,required,reversed,rows,rowspan,sandbox,scope,scoped,selected,shape,size,sizes,slot,span,spellcheck,src,srcdoc,srclang,srcset,start,step,style,summary,tabindex,target,title,translate,type,usemap,value,width,wrap"); | ||
| /** | ||
| * Generated from https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute | ||
| */ | ||
| const isKnownSvgAttr = /* @__PURE__ */ makeMap("xmlns,accent-height,accumulate,additive,alignment-baseline,alphabetic,amplitude,arabic-form,ascent,attributeName,attributeType,azimuth,baseFrequency,baseline-shift,baseProfile,bbox,begin,bias,by,calcMode,cap-height,class,clip,clipPathUnits,clip-path,clip-rule,color,color-interpolation,color-interpolation-filters,color-profile,color-rendering,contentScriptType,contentStyleType,crossorigin,cursor,cx,cy,d,decelerate,descent,diffuseConstant,direction,display,divisor,dominant-baseline,dur,dx,dy,edgeMode,elevation,enable-background,end,exponent,fill,fill-opacity,fill-rule,filter,filterRes,filterUnits,flood-color,flood-opacity,font-family,font-size,font-size-adjust,font-stretch,font-style,font-variant,font-weight,format,from,fr,fx,fy,g1,g2,glyph-name,glyph-orientation-horizontal,glyph-orientation-vertical,glyphRef,gradientTransform,gradientUnits,hanging,height,href,hreflang,horiz-adv-x,horiz-origin-x,id,ideographic,image-rendering,in,in2,intercept,k,k1,k2,k3,k4,kernelMatrix,kernelUnitLength,kerning,keyPoints,keySplines,keyTimes,lang,lengthAdjust,letter-spacing,lighting-color,limitingConeAngle,local,marker-end,marker-mid,marker-start,markerHeight,markerUnits,markerWidth,mask,maskContentUnits,maskUnits,mathematical,max,media,method,min,mode,name,numOctaves,offset,opacity,operator,order,orient,orientation,origin,overflow,overline-position,overline-thickness,panose-1,paint-order,path,pathLength,patternContentUnits,patternTransform,patternUnits,ping,pointer-events,points,pointsAtX,pointsAtY,pointsAtZ,preserveAlpha,preserveAspectRatio,primitiveUnits,r,radius,referrerPolicy,refX,refY,rel,rendering-intent,repeatCount,repeatDur,requiredExtensions,requiredFeatures,restart,result,rotate,rx,ry,scale,seed,shape-rendering,slope,spacing,specularConstant,specularExponent,speed,spreadMethod,startOffset,stdDeviation,stemh,stemv,stitchTiles,stop-color,stop-opacity,strikethrough-position,strikethrough-thickness,string,stroke,stroke-dasharray,stroke-dashoffset,stroke-linecap,stroke-linejoin,stroke-miterlimit,stroke-opacity,stroke-width,style,surfaceScale,systemLanguage,tabindex,tableValues,target,targetX,targetY,text-anchor,text-decoration,text-rendering,textLength,to,transform,transform-origin,type,u1,u2,underline-position,underline-thickness,unicode,unicode-bidi,unicode-range,units-per-em,v-alphabetic,v-hanging,v-ideographic,v-mathematical,values,vector-effect,version,vert-adv-y,vert-origin-x,vert-origin-y,viewBox,viewTarget,visibility,width,widths,word-spacing,writing-mode,x,x-height,x1,x2,xChannelSelector,xlink:actuate,xlink:arcrole,xlink:href,xlink:role,xlink:show,xlink:title,xlink:type,xmlns:xlink,xml:base,xml:lang,xml:space,y,y1,y2,yChannelSelector,z,zoomAndPan"); | ||
| const isKnownSvgAttr = /*@__PURE__*/ makeMap("xmlns,accent-height,accumulate,additive,alignment-baseline,alphabetic,amplitude,arabic-form,ascent,attributeName,attributeType,azimuth,baseFrequency,baseline-shift,baseProfile,bbox,begin,bias,by,calcMode,cap-height,class,clip,clipPathUnits,clip-path,clip-rule,color,color-interpolation,color-interpolation-filters,color-profile,color-rendering,contentScriptType,contentStyleType,crossorigin,cursor,cx,cy,d,decelerate,descent,diffuseConstant,direction,display,divisor,dominant-baseline,dur,dx,dy,edgeMode,elevation,enable-background,end,exponent,fill,fill-opacity,fill-rule,filter,filterRes,filterUnits,flood-color,flood-opacity,font-family,font-size,font-size-adjust,font-stretch,font-style,font-variant,font-weight,format,from,fr,fx,fy,g1,g2,glyph-name,glyph-orientation-horizontal,glyph-orientation-vertical,glyphRef,gradientTransform,gradientUnits,hanging,height,href,hreflang,horiz-adv-x,horiz-origin-x,id,ideographic,image-rendering,in,in2,intercept,k,k1,k2,k3,k4,kernelMatrix,kernelUnitLength,kerning,keyPoints,keySplines,keyTimes,lang,lengthAdjust,letter-spacing,lighting-color,limitingConeAngle,local,marker-end,marker-mid,marker-start,markerHeight,markerUnits,markerWidth,mask,maskContentUnits,maskUnits,mathematical,max,media,method,min,mode,name,numOctaves,offset,opacity,operator,order,orient,orientation,origin,overflow,overline-position,overline-thickness,panose-1,paint-order,path,pathLength,patternContentUnits,patternTransform,patternUnits,ping,pointer-events,points,pointsAtX,pointsAtY,pointsAtZ,preserveAlpha,preserveAspectRatio,primitiveUnits,r,radius,referrerPolicy,refX,refY,rel,rendering-intent,repeatCount,repeatDur,requiredExtensions,requiredFeatures,restart,result,rotate,rx,ry,scale,seed,shape-rendering,slope,spacing,specularConstant,specularExponent,speed,spreadMethod,startOffset,stdDeviation,stemh,stemv,stitchTiles,stop-color,stop-opacity,strikethrough-position,strikethrough-thickness,string,stroke,stroke-dasharray,stroke-dashoffset,stroke-linecap,stroke-linejoin,stroke-miterlimit,stroke-opacity,stroke-width,style,surfaceScale,systemLanguage,tabindex,tableValues,target,targetX,targetY,text-anchor,text-decoration,text-rendering,textLength,to,transform,transform-origin,type,u1,u2,underline-position,underline-thickness,unicode,unicode-bidi,unicode-range,units-per-em,v-alphabetic,v-hanging,v-ideographic,v-mathematical,values,vector-effect,version,vert-adv-y,vert-origin-x,vert-origin-y,viewBox,viewTarget,visibility,width,widths,word-spacing,writing-mode,x,x-height,x1,x2,xChannelSelector,xlink:actuate,xlink:arcrole,xlink:href,xlink:role,xlink:show,xlink:title,xlink:type,xmlns:xlink,xml:base,xml:lang,xml:space,y,y1,y2,yChannelSelector,z,zoomAndPan"); | ||
| /** | ||
| * Generated from https://developer.mozilla.org/en-US/docs/Web/MathML/Attribute | ||
| */ | ||
| const isKnownMathMLAttr = /* @__PURE__ */ makeMap("accent,accentunder,actiontype,align,alignmentscope,altimg,altimg-height,altimg-valign,altimg-width,alttext,bevelled,close,columnsalign,columnlines,columnspan,denomalign,depth,dir,display,displaystyle,encoding,equalcolumns,equalrows,fence,fontstyle,fontweight,form,frame,framespacing,groupalign,height,href,id,indentalign,indentalignfirst,indentalignlast,indentshift,indentshiftfirst,indentshiftlast,indextype,justify,largetop,largeop,lquote,lspace,mathbackground,mathcolor,mathsize,mathvariant,maxsize,minlabelspacing,mode,other,overflow,position,rowalign,rowlines,rowspan,rquote,rspace,scriptlevel,scriptminsize,scriptsizemultiplier,selection,separator,separators,shift,side,src,stackalign,stretchy,subscriptshift,superscriptshift,symmetric,voffset,width,widths,xlink:href,xlink:show,xlink:type,xmlns"); | ||
| const isKnownMathMLAttr = /*@__PURE__*/ makeMap("accent,accentunder,actiontype,align,alignmentscope,altimg,altimg-height,altimg-valign,altimg-width,alttext,bevelled,close,columnsalign,columnlines,columnspan,denomalign,depth,dir,display,displaystyle,encoding,equalcolumns,equalrows,fence,fontstyle,fontweight,form,frame,framespacing,groupalign,height,href,id,indentalign,indentalignfirst,indentalignlast,indentshift,indentshiftfirst,indentshiftlast,indextype,justify,largetop,largeop,lquote,lspace,mathbackground,mathcolor,mathsize,mathvariant,maxsize,minlabelspacing,mode,other,overflow,position,rowalign,rowlines,rowspan,rquote,rspace,scriptlevel,scriptminsize,scriptsizemultiplier,selection,separator,separators,shift,side,src,stackalign,stretchy,subscriptshift,superscriptshift,symmetric,voffset,width,widths,xlink:href,xlink:show,xlink:type,xmlns"); | ||
| /** | ||
@@ -564,2 +564,17 @@ * Shared between server-renderer and runtime-core hydration logic | ||
| } | ||
| function looseCompareCollections(a, b) { | ||
| if (a.size !== b.size) return false; | ||
| const candidates = Array.from(b); | ||
| const matched = new Uint8Array(candidates.length); | ||
| for (const item of a) { | ||
| let index = -1; | ||
| for (let i = 0; i < candidates.length; i++) if (!matched[i] && looseEqual(item, candidates[i])) { | ||
| index = i; | ||
| break; | ||
| } | ||
| if (index < 0) return false; | ||
| matched[index] = 1; | ||
| } | ||
| return true; | ||
| } | ||
| function looseEqual(a, b) { | ||
@@ -580,2 +595,8 @@ if (a === b) return true; | ||
| if (!aValidType || !bValidType) return false; | ||
| aValidType = isMap(a); | ||
| bValidType = isMap(b); | ||
| if (aValidType || bValidType) return aValidType && bValidType ? looseCompareCollections(a, b) : false; | ||
| aValidType = isSet(a); | ||
| bValidType = isSet(b); | ||
| if (aValidType || bValidType) return aValidType && bValidType ? looseCompareCollections(a, b) : false; | ||
| if (Object.keys(a).length !== Object.keys(b).length) return false; | ||
@@ -582,0 +603,0 @@ for (const key in a) { |
+41
-20
| /** | ||
| * @vue/shared v3.6.0-rc.5 | ||
| * @vue/shared v3.6.0-rc.6 | ||
| * (c) 2018-present Yuxi (Evan) You and Vue contributors | ||
@@ -18,3 +18,3 @@ * @license MIT | ||
| */ | ||
| /* @__NO_SIDE_EFFECTS__ */ | ||
| /*@__NO_SIDE_EFFECTS__*/ | ||
| function makeMap(str) { | ||
@@ -67,5 +67,5 @@ const map = Object.create(null); | ||
| const isIntegerKey = (key) => isString(key) && key !== "NaN" && key[0] !== "-" && "" + parseInt(key, 10) === key; | ||
| const isReservedProp = /* @__PURE__ */ makeMap(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"); | ||
| const isBuiltInTag = /* @__PURE__ */ makeMap("slot,component"); | ||
| const isBuiltInDirective = /* @__PURE__ */ makeMap("bind,cloak,else-if,else,for,html,if,model,on,once,pre,show,slot,text,memo"); | ||
| const isReservedProp = /*@__PURE__*/ makeMap(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"); | ||
| const isBuiltInTag = /*#__PURE__*/ makeMap("slot,component"); | ||
| const isBuiltInDirective = /*@__PURE__*/ makeMap("bind,cloak,else-if,else,for,html,if,model,on,once,pre,show,slot,text,memo"); | ||
| const cacheStringFunction = (fn) => { | ||
@@ -264,3 +264,3 @@ const cache = Object.create(null); | ||
| }; | ||
| const isGloballyAllowed = /* @__PURE__ */ makeMap("Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt,console,Error,Symbol"); | ||
| const isGloballyAllowed = /*@__PURE__*/ makeMap("Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt,console,Error,Symbol"); | ||
| /** @deprecated use `isGloballyAllowed` instead */ | ||
@@ -378,3 +378,3 @@ const isGloballyWhitelisted = isGloballyAllowed; | ||
| */ | ||
| const isHTMLTag = /* @__PURE__ */ makeMap(HTML_TAGS); | ||
| const isHTMLTag = /*@__PURE__*/ makeMap(HTML_TAGS); | ||
| /** | ||
@@ -384,3 +384,3 @@ * Compiler only. | ||
| */ | ||
| const isSVGTag = /* @__PURE__ */ makeMap(SVG_TAGS); | ||
| const isSVGTag = /*@__PURE__*/ makeMap(SVG_TAGS); | ||
| /** | ||
@@ -390,3 +390,3 @@ * Compiler only. | ||
| */ | ||
| const isMathMLTag = /* @__PURE__ */ makeMap(MATH_TAGS); | ||
| const isMathMLTag = /*@__PURE__*/ makeMap(MATH_TAGS); | ||
| /** | ||
@@ -396,3 +396,3 @@ * Compiler only. | ||
| */ | ||
| const isVoidTag = /* @__PURE__ */ makeMap(VOID_TAGS); | ||
| const isVoidTag = /*@__PURE__*/ makeMap(VOID_TAGS); | ||
| /** | ||
@@ -402,3 +402,3 @@ * Compiler only. | ||
| */ | ||
| const isFormattingTag = /* @__PURE__ */ makeMap(FORMATTING_TAGS); | ||
| const isFormattingTag = /*@__PURE__*/ makeMap(FORMATTING_TAGS); | ||
| /** | ||
@@ -408,3 +408,3 @@ * Compiler only. | ||
| */ | ||
| const isAlwaysCloseTag = /* @__PURE__ */ makeMap(ALWAYS_CLOSE_TAGS); | ||
| const isAlwaysCloseTag = /*@__PURE__*/ makeMap(ALWAYS_CLOSE_TAGS); | ||
| /** | ||
@@ -414,3 +414,3 @@ * Compiler only. | ||
| */ | ||
| const isInlineTag = /* @__PURE__ */ makeMap(INLINE_TAGS); | ||
| const isInlineTag = /*@__PURE__*/ makeMap(INLINE_TAGS); | ||
| /** | ||
@@ -420,3 +420,3 @@ * Compiler only. | ||
| */ | ||
| const isBlockTag = /* @__PURE__ */ makeMap(BLOCK_TAGS); | ||
| const isBlockTag = /*@__PURE__*/ makeMap(BLOCK_TAGS); | ||
| //#endregion | ||
@@ -436,7 +436,7 @@ //#region packages/shared/src/domAttrConfig.ts | ||
| const specialBooleanAttrs = `itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly`; | ||
| const isSpecialBooleanAttr = /* @__PURE__ */ makeMap(specialBooleanAttrs); | ||
| const isSpecialBooleanAttr = /*@__PURE__*/ makeMap(specialBooleanAttrs); | ||
| /** | ||
| * The full list is needed during SSR to produce the correct initial markup. | ||
| */ | ||
| const isBooleanAttr = /* @__PURE__ */ makeMap(specialBooleanAttrs + ",async,autofocus,autoplay,controls,default,defer,disabled,inert,loop,open,required,reversed,scoped,seamless,checked,muted,multiple,selected"); | ||
| const isBooleanAttr = /*@__PURE__*/ makeMap(specialBooleanAttrs + ",async,autofocus,autoplay,controls,default,defer,disabled,inert,loop,open,required,reversed,scoped,seamless,checked,muted,multiple,selected"); | ||
| /** | ||
@@ -449,3 +449,3 @@ * Boolean attributes should be included if the value is truthy or ''. | ||
| } | ||
| const unsafeAttrCharRE = /[>/="'\u0009\u000a\u000c\u0020]/; | ||
| const unsafeAttrCharRE = /[>/="'\u0009\u000a\u000c\u000d\u0020]/; | ||
| const attrValidationCache = {}; | ||
@@ -470,11 +470,11 @@ function isSSRSafeAttrName(name) { | ||
| */ | ||
| const isKnownHtmlAttr = /* @__PURE__ */ makeMap("accept,accept-charset,accesskey,action,align,allow,alt,async,autocapitalize,autocomplete,autofocus,autoplay,background,bgcolor,border,buffered,capture,challenge,charset,checked,cite,class,code,codebase,color,cols,colspan,content,contenteditable,contextmenu,controls,coords,crossorigin,csp,data,datetime,decoding,default,defer,dir,dirname,disabled,download,draggable,dropzone,enctype,enterkeyhint,for,form,formaction,formenctype,formmethod,formnovalidate,formtarget,headers,height,hidden,high,href,hreflang,http-equiv,icon,id,importance,inert,integrity,ismap,itemprop,keytype,kind,label,lang,language,loading,list,loop,low,manifest,max,maxlength,minlength,media,min,multiple,muted,name,novalidate,open,optimum,pattern,ping,placeholder,poster,preload,radiogroup,readonly,referrerpolicy,rel,required,reversed,rows,rowspan,sandbox,scope,scoped,selected,shape,size,sizes,slot,span,spellcheck,src,srcdoc,srclang,srcset,start,step,style,summary,tabindex,target,title,translate,type,usemap,value,width,wrap"); | ||
| const isKnownHtmlAttr = /*@__PURE__*/ makeMap("accept,accept-charset,accesskey,action,align,allow,alt,async,autocapitalize,autocomplete,autofocus,autoplay,background,bgcolor,border,buffered,capture,challenge,charset,checked,cite,class,code,codebase,color,cols,colspan,content,contenteditable,contextmenu,controls,coords,crossorigin,csp,data,datetime,decoding,default,defer,dir,dirname,disabled,download,draggable,dropzone,enctype,enterkeyhint,for,form,formaction,formenctype,formmethod,formnovalidate,formtarget,headers,height,hidden,high,href,hreflang,http-equiv,icon,id,importance,inert,integrity,ismap,itemprop,keytype,kind,label,lang,language,loading,list,loop,low,manifest,max,maxlength,minlength,media,min,multiple,muted,name,novalidate,open,optimum,pattern,ping,placeholder,poster,preload,radiogroup,readonly,referrerpolicy,rel,required,reversed,rows,rowspan,sandbox,scope,scoped,selected,shape,size,sizes,slot,span,spellcheck,src,srcdoc,srclang,srcset,start,step,style,summary,tabindex,target,title,translate,type,usemap,value,width,wrap"); | ||
| /** | ||
| * Generated from https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute | ||
| */ | ||
| const isKnownSvgAttr = /* @__PURE__ */ makeMap("xmlns,accent-height,accumulate,additive,alignment-baseline,alphabetic,amplitude,arabic-form,ascent,attributeName,attributeType,azimuth,baseFrequency,baseline-shift,baseProfile,bbox,begin,bias,by,calcMode,cap-height,class,clip,clipPathUnits,clip-path,clip-rule,color,color-interpolation,color-interpolation-filters,color-profile,color-rendering,contentScriptType,contentStyleType,crossorigin,cursor,cx,cy,d,decelerate,descent,diffuseConstant,direction,display,divisor,dominant-baseline,dur,dx,dy,edgeMode,elevation,enable-background,end,exponent,fill,fill-opacity,fill-rule,filter,filterRes,filterUnits,flood-color,flood-opacity,font-family,font-size,font-size-adjust,font-stretch,font-style,font-variant,font-weight,format,from,fr,fx,fy,g1,g2,glyph-name,glyph-orientation-horizontal,glyph-orientation-vertical,glyphRef,gradientTransform,gradientUnits,hanging,height,href,hreflang,horiz-adv-x,horiz-origin-x,id,ideographic,image-rendering,in,in2,intercept,k,k1,k2,k3,k4,kernelMatrix,kernelUnitLength,kerning,keyPoints,keySplines,keyTimes,lang,lengthAdjust,letter-spacing,lighting-color,limitingConeAngle,local,marker-end,marker-mid,marker-start,markerHeight,markerUnits,markerWidth,mask,maskContentUnits,maskUnits,mathematical,max,media,method,min,mode,name,numOctaves,offset,opacity,operator,order,orient,orientation,origin,overflow,overline-position,overline-thickness,panose-1,paint-order,path,pathLength,patternContentUnits,patternTransform,patternUnits,ping,pointer-events,points,pointsAtX,pointsAtY,pointsAtZ,preserveAlpha,preserveAspectRatio,primitiveUnits,r,radius,referrerPolicy,refX,refY,rel,rendering-intent,repeatCount,repeatDur,requiredExtensions,requiredFeatures,restart,result,rotate,rx,ry,scale,seed,shape-rendering,slope,spacing,specularConstant,specularExponent,speed,spreadMethod,startOffset,stdDeviation,stemh,stemv,stitchTiles,stop-color,stop-opacity,strikethrough-position,strikethrough-thickness,string,stroke,stroke-dasharray,stroke-dashoffset,stroke-linecap,stroke-linejoin,stroke-miterlimit,stroke-opacity,stroke-width,style,surfaceScale,systemLanguage,tabindex,tableValues,target,targetX,targetY,text-anchor,text-decoration,text-rendering,textLength,to,transform,transform-origin,type,u1,u2,underline-position,underline-thickness,unicode,unicode-bidi,unicode-range,units-per-em,v-alphabetic,v-hanging,v-ideographic,v-mathematical,values,vector-effect,version,vert-adv-y,vert-origin-x,vert-origin-y,viewBox,viewTarget,visibility,width,widths,word-spacing,writing-mode,x,x-height,x1,x2,xChannelSelector,xlink:actuate,xlink:arcrole,xlink:href,xlink:role,xlink:show,xlink:title,xlink:type,xmlns:xlink,xml:base,xml:lang,xml:space,y,y1,y2,yChannelSelector,z,zoomAndPan"); | ||
| const isKnownSvgAttr = /*@__PURE__*/ makeMap("xmlns,accent-height,accumulate,additive,alignment-baseline,alphabetic,amplitude,arabic-form,ascent,attributeName,attributeType,azimuth,baseFrequency,baseline-shift,baseProfile,bbox,begin,bias,by,calcMode,cap-height,class,clip,clipPathUnits,clip-path,clip-rule,color,color-interpolation,color-interpolation-filters,color-profile,color-rendering,contentScriptType,contentStyleType,crossorigin,cursor,cx,cy,d,decelerate,descent,diffuseConstant,direction,display,divisor,dominant-baseline,dur,dx,dy,edgeMode,elevation,enable-background,end,exponent,fill,fill-opacity,fill-rule,filter,filterRes,filterUnits,flood-color,flood-opacity,font-family,font-size,font-size-adjust,font-stretch,font-style,font-variant,font-weight,format,from,fr,fx,fy,g1,g2,glyph-name,glyph-orientation-horizontal,glyph-orientation-vertical,glyphRef,gradientTransform,gradientUnits,hanging,height,href,hreflang,horiz-adv-x,horiz-origin-x,id,ideographic,image-rendering,in,in2,intercept,k,k1,k2,k3,k4,kernelMatrix,kernelUnitLength,kerning,keyPoints,keySplines,keyTimes,lang,lengthAdjust,letter-spacing,lighting-color,limitingConeAngle,local,marker-end,marker-mid,marker-start,markerHeight,markerUnits,markerWidth,mask,maskContentUnits,maskUnits,mathematical,max,media,method,min,mode,name,numOctaves,offset,opacity,operator,order,orient,orientation,origin,overflow,overline-position,overline-thickness,panose-1,paint-order,path,pathLength,patternContentUnits,patternTransform,patternUnits,ping,pointer-events,points,pointsAtX,pointsAtY,pointsAtZ,preserveAlpha,preserveAspectRatio,primitiveUnits,r,radius,referrerPolicy,refX,refY,rel,rendering-intent,repeatCount,repeatDur,requiredExtensions,requiredFeatures,restart,result,rotate,rx,ry,scale,seed,shape-rendering,slope,spacing,specularConstant,specularExponent,speed,spreadMethod,startOffset,stdDeviation,stemh,stemv,stitchTiles,stop-color,stop-opacity,strikethrough-position,strikethrough-thickness,string,stroke,stroke-dasharray,stroke-dashoffset,stroke-linecap,stroke-linejoin,stroke-miterlimit,stroke-opacity,stroke-width,style,surfaceScale,systemLanguage,tabindex,tableValues,target,targetX,targetY,text-anchor,text-decoration,text-rendering,textLength,to,transform,transform-origin,type,u1,u2,underline-position,underline-thickness,unicode,unicode-bidi,unicode-range,units-per-em,v-alphabetic,v-hanging,v-ideographic,v-mathematical,values,vector-effect,version,vert-adv-y,vert-origin-x,vert-origin-y,viewBox,viewTarget,visibility,width,widths,word-spacing,writing-mode,x,x-height,x1,x2,xChannelSelector,xlink:actuate,xlink:arcrole,xlink:href,xlink:role,xlink:show,xlink:title,xlink:type,xmlns:xlink,xml:base,xml:lang,xml:space,y,y1,y2,yChannelSelector,z,zoomAndPan"); | ||
| /** | ||
| * Generated from https://developer.mozilla.org/en-US/docs/Web/MathML/Attribute | ||
| */ | ||
| const isKnownMathMLAttr = /* @__PURE__ */ makeMap("accent,accentunder,actiontype,align,alignmentscope,altimg,altimg-height,altimg-valign,altimg-width,alttext,bevelled,close,columnsalign,columnlines,columnspan,denomalign,depth,dir,display,displaystyle,encoding,equalcolumns,equalrows,fence,fontstyle,fontweight,form,frame,framespacing,groupalign,height,href,id,indentalign,indentalignfirst,indentalignlast,indentshift,indentshiftfirst,indentshiftlast,indextype,justify,largetop,largeop,lquote,lspace,mathbackground,mathcolor,mathsize,mathvariant,maxsize,minlabelspacing,mode,other,overflow,position,rowalign,rowlines,rowspan,rquote,rspace,scriptlevel,scriptminsize,scriptsizemultiplier,selection,separator,separators,shift,side,src,stackalign,stretchy,subscriptshift,superscriptshift,symmetric,voffset,width,widths,xlink:href,xlink:show,xlink:type,xmlns"); | ||
| const isKnownMathMLAttr = /*@__PURE__*/ makeMap("accent,accentunder,actiontype,align,alignmentscope,altimg,altimg-height,altimg-valign,altimg-width,alttext,bevelled,close,columnsalign,columnlines,columnspan,denomalign,depth,dir,display,displaystyle,encoding,equalcolumns,equalrows,fence,fontstyle,fontweight,form,frame,framespacing,groupalign,height,href,id,indentalign,indentalignfirst,indentalignlast,indentshift,indentshiftfirst,indentshiftlast,indextype,justify,largetop,largeop,lquote,lspace,mathbackground,mathcolor,mathsize,mathvariant,maxsize,minlabelspacing,mode,other,overflow,position,rowalign,rowlines,rowspan,rquote,rspace,scriptlevel,scriptminsize,scriptsizemultiplier,selection,separator,separators,shift,side,src,stackalign,stretchy,subscriptshift,superscriptshift,symmetric,voffset,width,widths,xlink:href,xlink:show,xlink:type,xmlns"); | ||
| /** | ||
@@ -564,2 +564,17 @@ * Shared between server-renderer and runtime-core hydration logic | ||
| } | ||
| function looseCompareCollections(a, b) { | ||
| if (a.size !== b.size) return false; | ||
| const candidates = Array.from(b); | ||
| const matched = new Uint8Array(candidates.length); | ||
| for (const item of a) { | ||
| let index = -1; | ||
| for (let i = 0; i < candidates.length; i++) if (!matched[i] && looseEqual(item, candidates[i])) { | ||
| index = i; | ||
| break; | ||
| } | ||
| if (index < 0) return false; | ||
| matched[index] = 1; | ||
| } | ||
| return true; | ||
| } | ||
| function looseEqual(a, b) { | ||
@@ -580,2 +595,8 @@ if (a === b) return true; | ||
| if (!aValidType || !bValidType) return false; | ||
| aValidType = isMap(a); | ||
| bValidType = isMap(b); | ||
| if (aValidType || bValidType) return aValidType && bValidType ? looseCompareCollections(a, b) : false; | ||
| aValidType = isSet(a); | ||
| bValidType = isSet(b); | ||
| if (aValidType || bValidType) return aValidType && bValidType ? looseCompareCollections(a, b) : false; | ||
| if (Object.keys(a).length !== Object.keys(b).length) return false; | ||
@@ -582,0 +603,0 @@ for (const key in a) { |
+235
-235
| //#region temp/packages/shared/src/makeMap.d.ts | ||
| /** | ||
| * Make a map and return a function for checking if a key | ||
| * is in that map. | ||
| * IMPORTANT: all calls of this function must be prefixed with | ||
| * \/\*#\_\_PURE\_\_\*\/ | ||
| * So that they can be tree-shaken if necessary. | ||
| */ | ||
| * Make a map and return a function for checking if a key | ||
| * is in that map. | ||
| * IMPORTANT: all calls of this function must be prefixed with | ||
| * \/\*#\_\_PURE\_\_\*\/ | ||
| * So that they can be tree-shaken if necessary. | ||
| */ | ||
| export declare function makeMap(str: string): (key: string) => boolean; | ||
@@ -18,8 +18,8 @@ //#endregion | ||
| /** | ||
| * Always return true. | ||
| */ | ||
| * Always return true. | ||
| */ | ||
| export declare const YES: () => boolean; | ||
| /** | ||
| * Always return false. | ||
| */ | ||
| * Always return false. | ||
| */ | ||
| export declare const NO: () => boolean; | ||
@@ -51,23 +51,23 @@ export declare const isOn: (key: string) => boolean; | ||
| /** | ||
| * @private | ||
| */ | ||
| * @private | ||
| */ | ||
| export declare const camelize: (str: string) => string; | ||
| /** | ||
| * @private | ||
| */ | ||
| * @private | ||
| */ | ||
| export declare const hyphenate: (str: string) => string; | ||
| /** | ||
| * @private | ||
| */ | ||
| * @private | ||
| */ | ||
| export declare const capitalize: <T extends string>(str: T) => Capitalize<T>; | ||
| /** | ||
| * @private | ||
| */ | ||
| * @private | ||
| */ | ||
| export declare const toHandlerKey: <T extends string>(str: T) => T extends "" ? "" : `on${Capitalize<T>}`; | ||
| /** | ||
| * #13070 When v-model and v-model:model directives are used together, | ||
| * they will generate the same modelModifiers prop, | ||
| * so a `$` suffix is added to avoid conflicts. | ||
| * @private | ||
| */ | ||
| * #13070 When v-model and v-model:model directives are used together, | ||
| * they will generate the same modelModifiers prop, | ||
| * so a `$` suffix is added to avoid conflicts. | ||
| * @private | ||
| */ | ||
| export declare const getModifierPropName: (name: string) => string; | ||
@@ -78,10 +78,10 @@ export declare const hasChanged: (value: any, oldValue: any) => boolean; | ||
| /** | ||
| * "123-foo" will be parsed to 123 | ||
| * This is used for the .number modifier in v-model | ||
| */ | ||
| * "123-foo" will be parsed to 123 | ||
| * This is used for the .number modifier in v-model | ||
| */ | ||
| export declare const looseToNumber: (val: any) => any; | ||
| /** | ||
| * Only concerns number-like strings | ||
| * "123-foo" will be returned as-is | ||
| */ | ||
| * Only concerns number-like strings | ||
| * "123-foo" will be returned as-is | ||
| */ | ||
| export declare const toNumber: (val: any) => any; | ||
@@ -95,115 +95,115 @@ export declare const getGlobalThis: () => any; | ||
| /** | ||
| * Patch flags are optimization hints generated by the compiler. | ||
| * when a block with dynamicChildren is encountered during diff, the algorithm | ||
| * enters "optimized mode". In this mode, we know that the vdom is produced by | ||
| * a render function generated by the compiler, so the algorithm only needs to | ||
| * handle updates explicitly marked by these patch flags. | ||
| * | ||
| * Patch flags can be combined using the | bitwise operator and can be checked | ||
| * using the & operator, e.g. | ||
| * | ||
| * ```js | ||
| * const flag = TEXT | CLASS | ||
| * if (flag & TEXT) { ... } | ||
| * ``` | ||
| * | ||
| * Check the `patchElement` function in '../../runtime-core/src/renderer.ts' to see how the | ||
| * flags are handled during diff. | ||
| */ | ||
| * Patch flags are optimization hints generated by the compiler. | ||
| * when a block with dynamicChildren is encountered during diff, the algorithm | ||
| * enters "optimized mode". In this mode, we know that the vdom is produced by | ||
| * a render function generated by the compiler, so the algorithm only needs to | ||
| * handle updates explicitly marked by these patch flags. | ||
| * | ||
| * Patch flags can be combined using the | bitwise operator and can be checked | ||
| * using the & operator, e.g. | ||
| * | ||
| * ```js | ||
| * const flag = TEXT | CLASS | ||
| * if (flag & TEXT) { ... } | ||
| * ``` | ||
| * | ||
| * Check the `patchElement` function in '../../runtime-core/src/renderer.ts' to see how the | ||
| * flags are handled during diff. | ||
| */ | ||
| export declare enum PatchFlags { | ||
| /** | ||
| * Indicates an element with dynamic textContent (children fast path) | ||
| */ | ||
| * Indicates an element with dynamic textContent (children fast path) | ||
| */ | ||
| TEXT = 1, | ||
| /** | ||
| * Indicates an element with dynamic class binding. | ||
| */ | ||
| * Indicates an element with dynamic class binding. | ||
| */ | ||
| CLASS = 2, | ||
| /** | ||
| * Indicates an element with dynamic style | ||
| * The compiler pre-compiles static string styles into static objects | ||
| * + detects and hoists inline static objects | ||
| * e.g. `style="color: red"` and `:style="{ color: 'red' }"` both get hoisted | ||
| * as: | ||
| * ```js | ||
| * const style = { color: 'red' } | ||
| * render() { return e('div', { style }) } | ||
| * ``` | ||
| */ | ||
| * Indicates an element with dynamic style | ||
| * The compiler pre-compiles static string styles into static objects | ||
| * + detects and hoists inline static objects | ||
| * e.g. `style="color: red"` and `:style="{ color: 'red' }"` both get hoisted | ||
| * as: | ||
| * ```js | ||
| * const style = { color: 'red' } | ||
| * render() { return e('div', { style }) } | ||
| * ``` | ||
| */ | ||
| STYLE = 4, | ||
| /** | ||
| * Indicates an element that has non-class/style dynamic props. | ||
| * Can also be on a component that has any dynamic props (includes | ||
| * class/style). when this flag is present, the vnode also has a dynamicProps | ||
| * array that contains the keys of the props that may change so the runtime | ||
| * can diff them faster (without having to worry about removed props) | ||
| */ | ||
| * Indicates an element that has non-class/style dynamic props. | ||
| * Can also be on a component that has any dynamic props (includes | ||
| * class/style). when this flag is present, the vnode also has a dynamicProps | ||
| * array that contains the keys of the props that may change so the runtime | ||
| * can diff them faster (without having to worry about removed props) | ||
| */ | ||
| PROPS = 8, | ||
| /** | ||
| * Indicates an element with props with dynamic keys. When keys change, a full | ||
| * diff is always needed to remove the old key. This flag is mutually | ||
| * exclusive with CLASS, STYLE and PROPS. | ||
| */ | ||
| * Indicates an element with props with dynamic keys. When keys change, a full | ||
| * diff is always needed to remove the old key. This flag is mutually | ||
| * exclusive with CLASS, STYLE and PROPS. | ||
| */ | ||
| FULL_PROPS = 16, | ||
| /** | ||
| * Indicates an element that requires props hydration | ||
| * (but not necessarily patching) | ||
| * e.g. event listeners & v-bind with prop modifier | ||
| */ | ||
| * Indicates an element that requires props hydration | ||
| * (but not necessarily patching) | ||
| * e.g. event listeners & v-bind with prop modifier | ||
| */ | ||
| NEED_HYDRATION = 32, | ||
| /** | ||
| * Indicates a fragment whose children order doesn't change. | ||
| */ | ||
| * Indicates a fragment whose children order doesn't change. | ||
| */ | ||
| STABLE_FRAGMENT = 64, | ||
| /** | ||
| * Indicates a fragment with keyed or partially keyed children | ||
| */ | ||
| * Indicates a fragment with keyed or partially keyed children | ||
| */ | ||
| KEYED_FRAGMENT = 128, | ||
| /** | ||
| * Indicates a fragment with unkeyed children. | ||
| */ | ||
| * Indicates a fragment with unkeyed children. | ||
| */ | ||
| UNKEYED_FRAGMENT = 256, | ||
| /** | ||
| * Indicates an element that only needs non-props patching, e.g. ref or | ||
| * directives (onVnodeXXX hooks). since every patched vnode checks for refs | ||
| * and onVnodeXXX hooks, it simply marks the vnode so that a parent block | ||
| * will track it. | ||
| */ | ||
| * Indicates an element that only needs non-props patching, e.g. ref or | ||
| * directives (onVnodeXXX hooks). since every patched vnode checks for refs | ||
| * and onVnodeXXX hooks, it simply marks the vnode so that a parent block | ||
| * will track it. | ||
| */ | ||
| NEED_PATCH = 512, | ||
| /** | ||
| * Indicates a component with dynamic slots (e.g. slot that references a v-for | ||
| * iterated value, or dynamic slot names). | ||
| * Components with this flag are always force updated. | ||
| */ | ||
| * Indicates a component with dynamic slots (e.g. slot that references a v-for | ||
| * iterated value, or dynamic slot names). | ||
| * Components with this flag are always force updated. | ||
| */ | ||
| DYNAMIC_SLOTS = 1024, | ||
| /** | ||
| * Indicates a fragment that was created only because the user has placed | ||
| * comments at the root level of a template. This is a dev-only flag since | ||
| * comments are stripped in production. | ||
| */ | ||
| * Indicates a fragment that was created only because the user has placed | ||
| * comments at the root level of a template. This is a dev-only flag since | ||
| * comments are stripped in production. | ||
| */ | ||
| DEV_ROOT_FRAGMENT = 2048, | ||
| /** | ||
| * SPECIAL FLAGS ------------------------------------------------------------- | ||
| * Special flags are negative integers. They are never matched against using | ||
| * bitwise operators (bitwise matching should only happen in branches where | ||
| * patchFlag > 0), and are mutually exclusive. When checking for a special | ||
| * flag, simply check patchFlag === FLAG. | ||
| */ | ||
| * SPECIAL FLAGS ------------------------------------------------------------- | ||
| * Special flags are negative integers. They are never matched against using | ||
| * bitwise operators (bitwise matching should only happen in branches where | ||
| * patchFlag > 0), and are mutually exclusive. When checking for a special | ||
| * flag, simply check patchFlag === FLAG. | ||
| */ | ||
| /** | ||
| * Indicates a cached static vnode. This is also a hint for hydration to skip | ||
| * the entire sub tree since static content never needs to be updated. | ||
| */ | ||
| * Indicates a cached static vnode. This is also a hint for hydration to skip | ||
| * the entire sub tree since static content never needs to be updated. | ||
| */ | ||
| CACHED = -1, | ||
| /** | ||
| * A special flag that indicates that the diffing algorithm should bail out | ||
| * of optimized mode. For example, on block fragments created by renderSlot() | ||
| * when encountering non-compiler generated slots (i.e. manually written | ||
| * render functions, which should always be fully diffed) | ||
| * OR manually cloneVNodes | ||
| */ | ||
| * A special flag that indicates that the diffing algorithm should bail out | ||
| * of optimized mode. For example, on block fragments created by renderSlot() | ||
| * when encountering non-compiler generated slots (i.e. manually written | ||
| * render functions, which should always be fully diffed) | ||
| * OR manually cloneVNodes | ||
| */ | ||
| BAIL = -2 | ||
| } | ||
| /** | ||
| * dev only flag -> name mapping | ||
| */ | ||
| * dev only flag -> name mapping | ||
| */ | ||
| export declare const PatchFlagNames: Record<PatchFlags, string>; | ||
@@ -229,24 +229,24 @@ //#endregion | ||
| /** | ||
| * Stable slots that only reference slot props or context state. The slot | ||
| * can fully capture its own dependencies so when passed down the parent won't | ||
| * need to force the child to update. | ||
| */ | ||
| * Stable slots that only reference slot props or context state. The slot | ||
| * can fully capture its own dependencies so when passed down the parent won't | ||
| * need to force the child to update. | ||
| */ | ||
| STABLE = 1, | ||
| /** | ||
| * Slots that reference scope variables (v-for or an outer slot prop), or | ||
| * has conditional structure (v-if, v-for). The parent will need to force | ||
| * the child to update because the slot does not fully capture its dependencies. | ||
| */ | ||
| * Slots that reference scope variables (v-for or an outer slot prop), or | ||
| * has conditional structure (v-if, v-for). The parent will need to force | ||
| * the child to update because the slot does not fully capture its dependencies. | ||
| */ | ||
| DYNAMIC = 2, | ||
| /** | ||
| * `<slot/>` being forwarded into a child component. Whether the parent needs | ||
| * to update the child is dependent on what kind of slots the parent itself | ||
| * received. This has to be refined at runtime, when the child's vnode | ||
| * is being created (in `normalizeChildren`) | ||
| */ | ||
| * `<slot/>` being forwarded into a child component. Whether the parent needs | ||
| * to update the child is dependent on what kind of slots the parent itself | ||
| * received. This has to be refined at runtime, when the child's vnode | ||
| * is being created (in `normalizeChildren`) | ||
| */ | ||
| FORWARDED = 3 | ||
| } | ||
| /** | ||
| * Dev only | ||
| */ | ||
| * Dev only | ||
| */ | ||
| export declare const slotFlagsText: Record<SlotFlags, string>; | ||
@@ -272,40 +272,40 @@ //#endregion | ||
| /** | ||
| * Compiler only. | ||
| * Do NOT use in runtime code paths unless behind `__DEV__` flag. | ||
| */ | ||
| * Compiler only. | ||
| * Do NOT use in runtime code paths unless behind `__DEV__` flag. | ||
| */ | ||
| export declare const isHTMLTag: (key: string) => boolean; | ||
| /** | ||
| * Compiler only. | ||
| * Do NOT use in runtime code paths unless behind `__DEV__` flag. | ||
| */ | ||
| * Compiler only. | ||
| * Do NOT use in runtime code paths unless behind `__DEV__` flag. | ||
| */ | ||
| export declare const isSVGTag: (key: string) => boolean; | ||
| /** | ||
| * Compiler only. | ||
| * Do NOT use in runtime code paths unless behind `__DEV__` flag. | ||
| */ | ||
| * Compiler only. | ||
| * Do NOT use in runtime code paths unless behind `__DEV__` flag. | ||
| */ | ||
| export declare const isMathMLTag: (key: string) => boolean; | ||
| /** | ||
| * Compiler only. | ||
| * Do NOT use in runtime code paths unless behind `__DEV__` flag. | ||
| */ | ||
| * Compiler only. | ||
| * Do NOT use in runtime code paths unless behind `__DEV__` flag. | ||
| */ | ||
| export declare const isVoidTag: (key: string) => boolean; | ||
| /** | ||
| * Compiler only. | ||
| * Do NOT use in runtime code paths unless behind `__DEV__` flag. | ||
| */ | ||
| * Compiler only. | ||
| * Do NOT use in runtime code paths unless behind `__DEV__` flag. | ||
| */ | ||
| export declare const isFormattingTag: (key: string) => boolean; | ||
| /** | ||
| * Compiler only. | ||
| * Do NOT use in runtime code paths unless behind `__DEV__` flag. | ||
| */ | ||
| * Compiler only. | ||
| * Do NOT use in runtime code paths unless behind `__DEV__` flag. | ||
| */ | ||
| export declare const isAlwaysCloseTag: (key: string) => boolean; | ||
| /** | ||
| * Compiler only. | ||
| * Do NOT use in runtime code paths unless behind `__DEV__` flag. | ||
| */ | ||
| * Compiler only. | ||
| * Do NOT use in runtime code paths unless behind `__DEV__` flag. | ||
| */ | ||
| export declare const isInlineTag: (key: string) => boolean; | ||
| /** | ||
| * Compiler only. | ||
| * Do NOT use in runtime code paths unless behind `__DEV__` flag. | ||
| */ | ||
| * Compiler only. | ||
| * Do NOT use in runtime code paths unless behind `__DEV__` flag. | ||
| */ | ||
| export declare const isBlockTag: (key: string) => boolean; | ||
@@ -316,9 +316,9 @@ //#endregion | ||
| /** | ||
| * The full list is needed during SSR to produce the correct initial markup. | ||
| */ | ||
| * The full list is needed during SSR to produce the correct initial markup. | ||
| */ | ||
| export declare const isBooleanAttr: (key: string) => boolean; | ||
| /** | ||
| * Boolean attributes should be included if the value is truthy or ''. | ||
| * e.g. `<select multiple>` compiles to `{ multiple: '' }` | ||
| */ | ||
| * Boolean attributes should be included if the value is truthy or ''. | ||
| * e.g. `<select multiple>` compiles to `{ multiple: '' }` | ||
| */ | ||
| export declare function includeBooleanAttr(value: unknown): boolean; | ||
@@ -328,19 +328,19 @@ export declare function isSSRSafeAttrName(name: string): boolean; | ||
| /** | ||
| * Known attributes, this is used for stringification of runtime static nodes | ||
| * so that we don't stringify bindings that cannot be set from HTML. | ||
| * Don't also forget to allow `data-*` and `aria-*`! | ||
| * Generated from https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes | ||
| */ | ||
| * Known attributes, this is used for stringification of runtime static nodes | ||
| * so that we don't stringify bindings that cannot be set from HTML. | ||
| * Don't also forget to allow `data-*` and `aria-*`! | ||
| * Generated from https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes | ||
| */ | ||
| export declare const isKnownHtmlAttr: (key: string) => boolean; | ||
| /** | ||
| * Generated from https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute | ||
| */ | ||
| * Generated from https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute | ||
| */ | ||
| export declare const isKnownSvgAttr: (key: string) => boolean; | ||
| /** | ||
| * Generated from https://developer.mozilla.org/en-US/docs/Web/MathML/Attribute | ||
| */ | ||
| * Generated from https://developer.mozilla.org/en-US/docs/Web/MathML/Attribute | ||
| */ | ||
| export declare const isKnownMathMLAttr: (key: string) => boolean; | ||
| /** | ||
| * Shared between server-renderer and runtime-core hydration logic | ||
| */ | ||
| * Shared between server-renderer and runtime-core hydration logic | ||
| */ | ||
| export declare function isRenderableAttrValue(value: unknown): boolean; | ||
@@ -369,17 +369,17 @@ export declare function shouldSetAsAttr(tagName: string, key: string): boolean; | ||
| /** | ||
| * For converting {{ interpolation }} values to displayed strings. | ||
| * @private | ||
| */ | ||
| * For converting {{ interpolation }} values to displayed strings. | ||
| * @private | ||
| */ | ||
| export declare const toDisplayString: (val: unknown) => string; | ||
| //#endregion | ||
| //#region temp/packages/shared/src/typeUtils.d.ts | ||
| export type Prettify<T> = { [K in keyof T]: T[K] } & {}; | ||
| export type Prettify<T> = { [K in keyof T]: T[K]; } & {}; | ||
| export type UnionToIntersection<U> = (U extends any ? (k: U) => void : never) extends ((k: infer I) => void) ? I : never; | ||
| export type LooseRequired<T> = { [P in keyof (T & Required<T>)]: T[P] }; | ||
| export type LooseRequired<T> = { [P in keyof (T & Required<T>)]: T[P]; }; | ||
| export type IfAny<T, Y, N> = 0 extends 1 & T ? Y : N; | ||
| export type IsKeyValues<T, K = string> = IfAny<T, false, T extends object ? (keyof T extends K ? true : false) : false>; | ||
| /** | ||
| * Utility for extracting the parameters from a function overload (for typed emits) | ||
| * https://github.com/microsoft/TypeScript/issues/32164#issuecomment-1146737709 | ||
| */ | ||
| * Utility for extracting the parameters from a function overload (for typed emits) | ||
| * https://github.com/microsoft/TypeScript/issues/32164#issuecomment-1146737709 | ||
| */ | ||
| export type OverloadParameters<T extends (...args: any[]) => any> = Parameters<OverloadUnion<T>>; | ||
@@ -395,5 +395,5 @@ type OverloadProps<TOverload> = Pick<TOverload, keyof TOverload>; | ||
| /** | ||
| * Normalize CSS var value created by `v-bind` in `<style>` block | ||
| * See https://github.com/vuejs/core/pull/12461#issuecomment-2495804664 | ||
| */ | ||
| * Normalize CSS var value created by `v-bind` in `<style>` block | ||
| * See https://github.com/vuejs/core/pull/12461#issuecomment-2495804664 | ||
| */ | ||
| export declare function normalizeCssVarValue(value: unknown): string; | ||
@@ -403,35 +403,35 @@ //#endregion | ||
| /** | ||
| * Flags to optimize vapor `createFor` runtime behavior, shared between the | ||
| * compiler and the runtime | ||
| */ | ||
| * Flags to optimize vapor `createFor` runtime behavior, shared between the | ||
| * compiler and the runtime | ||
| */ | ||
| export declare enum VaporVForFlags { | ||
| /** | ||
| * v-for is the only child of a parent container, so it can take the fast | ||
| * path with textContent = '' when the whole list is emptied | ||
| */ | ||
| * v-for is the only child of a parent container, so it can take the fast | ||
| * path with textContent = '' when the whole list is emptied | ||
| */ | ||
| FAST_REMOVE = 1, | ||
| /** | ||
| * v-for used on a component-shaped item. Component items require structural | ||
| * removal before item scope cleanup and cannot use the fast-clear path. This | ||
| * does not guarantee the item block is a VaporComponentInstance: component | ||
| * fallback paths may still return a DOM Node. | ||
| */ | ||
| * v-for used on a component-shaped item. Component items require structural | ||
| * removal before item scope cleanup and cannot use the fast-clear path. This | ||
| * does not guarantee the item block is a VaporComponentInstance: component | ||
| * fallback paths may still return a DOM Node. | ||
| */ | ||
| IS_COMPONENT = 2, | ||
| /** | ||
| * v-for inside v-once | ||
| */ | ||
| * v-for inside v-once | ||
| */ | ||
| ONCE = 4, | ||
| /** | ||
| * v-for item block is a single DOM Node. | ||
| */ | ||
| * v-for item block is a single DOM Node. | ||
| */ | ||
| IS_SINGLE_NODE = 8, | ||
| /** | ||
| * v-for item block is known to be a VaporFragment, so runtime can use | ||
| * fragment-specific insert/remove helpers. | ||
| */ | ||
| * v-for item block is known to be a VaporFragment, so runtime can use | ||
| * fragment-specific insert/remove helpers. | ||
| */ | ||
| IS_FRAGMENT = 16, | ||
| /** | ||
| * v-for sits on a slot content/fallback root chain and can change slot | ||
| * validity. | ||
| */ | ||
| * v-for sits on a slot content/fallback root chain and can change slot | ||
| * validity. | ||
| */ | ||
| SLOT_ROOT = 32 | ||
@@ -445,51 +445,51 @@ } | ||
| /** | ||
| * Bit layout for vapor `createIf` flags. | ||
| * | ||
| * - bits 0-1: true branch VaporBlockShape | ||
| * - bits 2-3: false branch VaporBlockShape | ||
| * - bit 4: v-once | ||
| * - bit 5: true branch is static and can skip branch-owned EffectScope | ||
| * - bit 6: false branch is static and can skip branch-owned EffectScope | ||
| * - bit 7: v-if sits on a slot content/fallback root chain | ||
| * - bits 8+: branch index + 1 for keyed dynamic fragments | ||
| * | ||
| * Examples: | ||
| * - v-once, true single-root, no false branch: 1 | ONCE = 17 | ||
| * - keyed index 0, true/false single-root: 1 | (1 << 2) | (1 << 8) = 261 | ||
| */ | ||
| * Bit layout for vapor `createIf` flags. | ||
| * | ||
| * - bits 0-1: true branch VaporBlockShape | ||
| * - bits 2-3: false branch VaporBlockShape | ||
| * - bit 4: v-once | ||
| * - bit 5: true branch is static and can skip branch-owned EffectScope | ||
| * - bit 6: false branch is static and can skip branch-owned EffectScope | ||
| * - bit 7: v-if sits on a slot content/fallback root chain | ||
| * - bits 8+: branch index + 1 for keyed dynamic fragments | ||
| * | ||
| * Examples: | ||
| * - v-once, true single-root, no false branch: 1 | ONCE = 17 | ||
| * - keyed index 0, true/false single-root: 1 | (1 << 2) | (1 << 8) = 261 | ||
| */ | ||
| export declare enum VaporIfFlags { | ||
| /** | ||
| * Documents the packed true/false branch shape bits. Runtime decode shifts | ||
| * to the selected branch first, then masks with 0b11 for one VaporBlockShape. | ||
| */ | ||
| * Documents the packed true/false branch shape bits. Runtime decode shifts | ||
| * to the selected branch first, then masks with 0b11 for one VaporBlockShape. | ||
| */ | ||
| BLOCK_SHAPE = 15, | ||
| /** | ||
| * Marks a branch that is created once and never updated. | ||
| */ | ||
| * Marks a branch that is created once and never updated. | ||
| */ | ||
| ONCE = 16, | ||
| /** | ||
| * The compiler proved that the true branch only returns static template nodes, | ||
| * so runtime can skip creating a branch-owned EffectScope. | ||
| */ | ||
| * The compiler proved that the true branch only returns static template nodes, | ||
| * so runtime can skip creating a branch-owned EffectScope. | ||
| */ | ||
| TRUE_NO_SCOPE = 32, | ||
| /** | ||
| * The compiler proved that the false branch only returns static template | ||
| * nodes, so runtime can skip creating a branch-owned EffectScope. | ||
| */ | ||
| * The compiler proved that the false branch only returns static template | ||
| * nodes, so runtime can skip creating a branch-owned EffectScope. | ||
| */ | ||
| FALSE_NO_SCOPE = 64, | ||
| /** | ||
| * v-if sits on a slot content/fallback root chain and can change slot | ||
| * validity. | ||
| */ | ||
| * v-if sits on a slot content/fallback root chain and can change slot | ||
| * validity. | ||
| */ | ||
| SLOT_ROOT = 128, | ||
| /** | ||
| * Shift for keyed branch index. The encoded value is index + 1, so decoded | ||
| * zero means "not keyed" and source index 0 still round-trips. | ||
| */ | ||
| * Shift for keyed branch index. The encoded value is index + 1, so decoded | ||
| * zero means "not keyed" and source index 0 still round-trips. | ||
| */ | ||
| INDEX_SHIFT = 8 | ||
| } | ||
| /** | ||
| * Flags used by vapor template factories, shared between the compiler and the | ||
| * runtime. | ||
| */ | ||
| * Flags used by vapor template factories, shared between the compiler and the | ||
| * runtime. | ||
| */ | ||
| export declare enum TemplateFlags { | ||
@@ -500,5 +500,5 @@ ROOT = 1, | ||
| /** | ||
| * Flags used by vapor slot outlets, shared between the compiler and the | ||
| * runtime. | ||
| */ | ||
| * Flags used by vapor slot outlets, shared between the compiler and the | ||
| * runtime. | ||
| */ | ||
| export declare enum VaporSlotFlags { | ||
@@ -517,2 +517,2 @@ NO_SLOTTED = 1, | ||
| } | ||
| //#endregion | ||
| //#endregion |
| /** | ||
| * @vue/shared v3.6.0-rc.5 | ||
| * @vue/shared v3.6.0-rc.6 | ||
| * (c) 2018-present Yuxi (Evan) You and Vue contributors | ||
@@ -14,3 +14,3 @@ * @license MIT | ||
| */ | ||
| /* @__NO_SIDE_EFFECTS__ */ | ||
| /*@__NO_SIDE_EFFECTS__*/ | ||
| function makeMap(str) { | ||
@@ -63,5 +63,5 @@ const map = Object.create(null); | ||
| const isIntegerKey = (key) => isString(key) && key !== "NaN" && key[0] !== "-" && "" + parseInt(key, 10) === key; | ||
| const isReservedProp = /* @__PURE__ */ makeMap(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"); | ||
| const isBuiltInTag = /* @__PURE__ */ makeMap("slot,component"); | ||
| const isBuiltInDirective = /* @__PURE__ */ makeMap("bind,cloak,else-if,else,for,html,if,model,on,once,pre,show,slot,text,memo"); | ||
| const isReservedProp = /*@__PURE__*/ makeMap(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"); | ||
| const isBuiltInTag = /*#__PURE__*/ makeMap("slot,component"); | ||
| const isBuiltInDirective = /*@__PURE__*/ makeMap("bind,cloak,else-if,else,for,html,if,model,on,once,pre,show,slot,text,memo"); | ||
| const cacheStringFunction = (fn) => { | ||
@@ -260,3 +260,3 @@ const cache = Object.create(null); | ||
| }; | ||
| const isGloballyAllowed = /* @__PURE__ */ makeMap("Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt,console,Error,Symbol"); | ||
| const isGloballyAllowed = /*@__PURE__*/ makeMap("Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt,console,Error,Symbol"); | ||
| /** @deprecated use `isGloballyAllowed` instead */ | ||
@@ -374,3 +374,3 @@ const isGloballyWhitelisted = isGloballyAllowed; | ||
| */ | ||
| const isHTMLTag = /* @__PURE__ */ makeMap(HTML_TAGS); | ||
| const isHTMLTag = /*@__PURE__*/ makeMap(HTML_TAGS); | ||
| /** | ||
@@ -380,3 +380,3 @@ * Compiler only. | ||
| */ | ||
| const isSVGTag = /* @__PURE__ */ makeMap(SVG_TAGS); | ||
| const isSVGTag = /*@__PURE__*/ makeMap(SVG_TAGS); | ||
| /** | ||
@@ -386,3 +386,3 @@ * Compiler only. | ||
| */ | ||
| const isMathMLTag = /* @__PURE__ */ makeMap(MATH_TAGS); | ||
| const isMathMLTag = /*@__PURE__*/ makeMap(MATH_TAGS); | ||
| /** | ||
@@ -392,3 +392,3 @@ * Compiler only. | ||
| */ | ||
| const isVoidTag = /* @__PURE__ */ makeMap(VOID_TAGS); | ||
| const isVoidTag = /*@__PURE__*/ makeMap(VOID_TAGS); | ||
| /** | ||
@@ -398,3 +398,3 @@ * Compiler only. | ||
| */ | ||
| const isFormattingTag = /* @__PURE__ */ makeMap(FORMATTING_TAGS); | ||
| const isFormattingTag = /*@__PURE__*/ makeMap(FORMATTING_TAGS); | ||
| /** | ||
@@ -404,3 +404,3 @@ * Compiler only. | ||
| */ | ||
| const isAlwaysCloseTag = /* @__PURE__ */ makeMap(ALWAYS_CLOSE_TAGS); | ||
| const isAlwaysCloseTag = /*@__PURE__*/ makeMap(ALWAYS_CLOSE_TAGS); | ||
| /** | ||
@@ -410,3 +410,3 @@ * Compiler only. | ||
| */ | ||
| const isInlineTag = /* @__PURE__ */ makeMap(INLINE_TAGS); | ||
| const isInlineTag = /*@__PURE__*/ makeMap(INLINE_TAGS); | ||
| /** | ||
@@ -416,3 +416,3 @@ * Compiler only. | ||
| */ | ||
| const isBlockTag = /* @__PURE__ */ makeMap(BLOCK_TAGS); | ||
| const isBlockTag = /*@__PURE__*/ makeMap(BLOCK_TAGS); | ||
| //#endregion | ||
@@ -432,7 +432,7 @@ //#region packages/shared/src/domAttrConfig.ts | ||
| const specialBooleanAttrs = `itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly`; | ||
| const isSpecialBooleanAttr = /* @__PURE__ */ makeMap(specialBooleanAttrs); | ||
| const isSpecialBooleanAttr = /*@__PURE__*/ makeMap(specialBooleanAttrs); | ||
| /** | ||
| * The full list is needed during SSR to produce the correct initial markup. | ||
| */ | ||
| const isBooleanAttr = /* @__PURE__ */ makeMap(specialBooleanAttrs + ",async,autofocus,autoplay,controls,default,defer,disabled,inert,loop,open,required,reversed,scoped,seamless,checked,muted,multiple,selected"); | ||
| const isBooleanAttr = /*@__PURE__*/ makeMap(specialBooleanAttrs + ",async,autofocus,autoplay,controls,default,defer,disabled,inert,loop,open,required,reversed,scoped,seamless,checked,muted,multiple,selected"); | ||
| /** | ||
@@ -445,3 +445,3 @@ * Boolean attributes should be included if the value is truthy or ''. | ||
| } | ||
| const unsafeAttrCharRE = /[>/="'\u0009\u000a\u000c\u0020]/; | ||
| const unsafeAttrCharRE = /[>/="'\u0009\u000a\u000c\u000d\u0020]/; | ||
| const attrValidationCache = {}; | ||
@@ -466,11 +466,11 @@ function isSSRSafeAttrName(name) { | ||
| */ | ||
| const isKnownHtmlAttr = /* @__PURE__ */ makeMap("accept,accept-charset,accesskey,action,align,allow,alt,async,autocapitalize,autocomplete,autofocus,autoplay,background,bgcolor,border,buffered,capture,challenge,charset,checked,cite,class,code,codebase,color,cols,colspan,content,contenteditable,contextmenu,controls,coords,crossorigin,csp,data,datetime,decoding,default,defer,dir,dirname,disabled,download,draggable,dropzone,enctype,enterkeyhint,for,form,formaction,formenctype,formmethod,formnovalidate,formtarget,headers,height,hidden,high,href,hreflang,http-equiv,icon,id,importance,inert,integrity,ismap,itemprop,keytype,kind,label,lang,language,loading,list,loop,low,manifest,max,maxlength,minlength,media,min,multiple,muted,name,novalidate,open,optimum,pattern,ping,placeholder,poster,preload,radiogroup,readonly,referrerpolicy,rel,required,reversed,rows,rowspan,sandbox,scope,scoped,selected,shape,size,sizes,slot,span,spellcheck,src,srcdoc,srclang,srcset,start,step,style,summary,tabindex,target,title,translate,type,usemap,value,width,wrap"); | ||
| const isKnownHtmlAttr = /*@__PURE__*/ makeMap("accept,accept-charset,accesskey,action,align,allow,alt,async,autocapitalize,autocomplete,autofocus,autoplay,background,bgcolor,border,buffered,capture,challenge,charset,checked,cite,class,code,codebase,color,cols,colspan,content,contenteditable,contextmenu,controls,coords,crossorigin,csp,data,datetime,decoding,default,defer,dir,dirname,disabled,download,draggable,dropzone,enctype,enterkeyhint,for,form,formaction,formenctype,formmethod,formnovalidate,formtarget,headers,height,hidden,high,href,hreflang,http-equiv,icon,id,importance,inert,integrity,ismap,itemprop,keytype,kind,label,lang,language,loading,list,loop,low,manifest,max,maxlength,minlength,media,min,multiple,muted,name,novalidate,open,optimum,pattern,ping,placeholder,poster,preload,radiogroup,readonly,referrerpolicy,rel,required,reversed,rows,rowspan,sandbox,scope,scoped,selected,shape,size,sizes,slot,span,spellcheck,src,srcdoc,srclang,srcset,start,step,style,summary,tabindex,target,title,translate,type,usemap,value,width,wrap"); | ||
| /** | ||
| * Generated from https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute | ||
| */ | ||
| const isKnownSvgAttr = /* @__PURE__ */ makeMap("xmlns,accent-height,accumulate,additive,alignment-baseline,alphabetic,amplitude,arabic-form,ascent,attributeName,attributeType,azimuth,baseFrequency,baseline-shift,baseProfile,bbox,begin,bias,by,calcMode,cap-height,class,clip,clipPathUnits,clip-path,clip-rule,color,color-interpolation,color-interpolation-filters,color-profile,color-rendering,contentScriptType,contentStyleType,crossorigin,cursor,cx,cy,d,decelerate,descent,diffuseConstant,direction,display,divisor,dominant-baseline,dur,dx,dy,edgeMode,elevation,enable-background,end,exponent,fill,fill-opacity,fill-rule,filter,filterRes,filterUnits,flood-color,flood-opacity,font-family,font-size,font-size-adjust,font-stretch,font-style,font-variant,font-weight,format,from,fr,fx,fy,g1,g2,glyph-name,glyph-orientation-horizontal,glyph-orientation-vertical,glyphRef,gradientTransform,gradientUnits,hanging,height,href,hreflang,horiz-adv-x,horiz-origin-x,id,ideographic,image-rendering,in,in2,intercept,k,k1,k2,k3,k4,kernelMatrix,kernelUnitLength,kerning,keyPoints,keySplines,keyTimes,lang,lengthAdjust,letter-spacing,lighting-color,limitingConeAngle,local,marker-end,marker-mid,marker-start,markerHeight,markerUnits,markerWidth,mask,maskContentUnits,maskUnits,mathematical,max,media,method,min,mode,name,numOctaves,offset,opacity,operator,order,orient,orientation,origin,overflow,overline-position,overline-thickness,panose-1,paint-order,path,pathLength,patternContentUnits,patternTransform,patternUnits,ping,pointer-events,points,pointsAtX,pointsAtY,pointsAtZ,preserveAlpha,preserveAspectRatio,primitiveUnits,r,radius,referrerPolicy,refX,refY,rel,rendering-intent,repeatCount,repeatDur,requiredExtensions,requiredFeatures,restart,result,rotate,rx,ry,scale,seed,shape-rendering,slope,spacing,specularConstant,specularExponent,speed,spreadMethod,startOffset,stdDeviation,stemh,stemv,stitchTiles,stop-color,stop-opacity,strikethrough-position,strikethrough-thickness,string,stroke,stroke-dasharray,stroke-dashoffset,stroke-linecap,stroke-linejoin,stroke-miterlimit,stroke-opacity,stroke-width,style,surfaceScale,systemLanguage,tabindex,tableValues,target,targetX,targetY,text-anchor,text-decoration,text-rendering,textLength,to,transform,transform-origin,type,u1,u2,underline-position,underline-thickness,unicode,unicode-bidi,unicode-range,units-per-em,v-alphabetic,v-hanging,v-ideographic,v-mathematical,values,vector-effect,version,vert-adv-y,vert-origin-x,vert-origin-y,viewBox,viewTarget,visibility,width,widths,word-spacing,writing-mode,x,x-height,x1,x2,xChannelSelector,xlink:actuate,xlink:arcrole,xlink:href,xlink:role,xlink:show,xlink:title,xlink:type,xmlns:xlink,xml:base,xml:lang,xml:space,y,y1,y2,yChannelSelector,z,zoomAndPan"); | ||
| const isKnownSvgAttr = /*@__PURE__*/ makeMap("xmlns,accent-height,accumulate,additive,alignment-baseline,alphabetic,amplitude,arabic-form,ascent,attributeName,attributeType,azimuth,baseFrequency,baseline-shift,baseProfile,bbox,begin,bias,by,calcMode,cap-height,class,clip,clipPathUnits,clip-path,clip-rule,color,color-interpolation,color-interpolation-filters,color-profile,color-rendering,contentScriptType,contentStyleType,crossorigin,cursor,cx,cy,d,decelerate,descent,diffuseConstant,direction,display,divisor,dominant-baseline,dur,dx,dy,edgeMode,elevation,enable-background,end,exponent,fill,fill-opacity,fill-rule,filter,filterRes,filterUnits,flood-color,flood-opacity,font-family,font-size,font-size-adjust,font-stretch,font-style,font-variant,font-weight,format,from,fr,fx,fy,g1,g2,glyph-name,glyph-orientation-horizontal,glyph-orientation-vertical,glyphRef,gradientTransform,gradientUnits,hanging,height,href,hreflang,horiz-adv-x,horiz-origin-x,id,ideographic,image-rendering,in,in2,intercept,k,k1,k2,k3,k4,kernelMatrix,kernelUnitLength,kerning,keyPoints,keySplines,keyTimes,lang,lengthAdjust,letter-spacing,lighting-color,limitingConeAngle,local,marker-end,marker-mid,marker-start,markerHeight,markerUnits,markerWidth,mask,maskContentUnits,maskUnits,mathematical,max,media,method,min,mode,name,numOctaves,offset,opacity,operator,order,orient,orientation,origin,overflow,overline-position,overline-thickness,panose-1,paint-order,path,pathLength,patternContentUnits,patternTransform,patternUnits,ping,pointer-events,points,pointsAtX,pointsAtY,pointsAtZ,preserveAlpha,preserveAspectRatio,primitiveUnits,r,radius,referrerPolicy,refX,refY,rel,rendering-intent,repeatCount,repeatDur,requiredExtensions,requiredFeatures,restart,result,rotate,rx,ry,scale,seed,shape-rendering,slope,spacing,specularConstant,specularExponent,speed,spreadMethod,startOffset,stdDeviation,stemh,stemv,stitchTiles,stop-color,stop-opacity,strikethrough-position,strikethrough-thickness,string,stroke,stroke-dasharray,stroke-dashoffset,stroke-linecap,stroke-linejoin,stroke-miterlimit,stroke-opacity,stroke-width,style,surfaceScale,systemLanguage,tabindex,tableValues,target,targetX,targetY,text-anchor,text-decoration,text-rendering,textLength,to,transform,transform-origin,type,u1,u2,underline-position,underline-thickness,unicode,unicode-bidi,unicode-range,units-per-em,v-alphabetic,v-hanging,v-ideographic,v-mathematical,values,vector-effect,version,vert-adv-y,vert-origin-x,vert-origin-y,viewBox,viewTarget,visibility,width,widths,word-spacing,writing-mode,x,x-height,x1,x2,xChannelSelector,xlink:actuate,xlink:arcrole,xlink:href,xlink:role,xlink:show,xlink:title,xlink:type,xmlns:xlink,xml:base,xml:lang,xml:space,y,y1,y2,yChannelSelector,z,zoomAndPan"); | ||
| /** | ||
| * Generated from https://developer.mozilla.org/en-US/docs/Web/MathML/Attribute | ||
| */ | ||
| const isKnownMathMLAttr = /* @__PURE__ */ makeMap("accent,accentunder,actiontype,align,alignmentscope,altimg,altimg-height,altimg-valign,altimg-width,alttext,bevelled,close,columnsalign,columnlines,columnspan,denomalign,depth,dir,display,displaystyle,encoding,equalcolumns,equalrows,fence,fontstyle,fontweight,form,frame,framespacing,groupalign,height,href,id,indentalign,indentalignfirst,indentalignlast,indentshift,indentshiftfirst,indentshiftlast,indextype,justify,largetop,largeop,lquote,lspace,mathbackground,mathcolor,mathsize,mathvariant,maxsize,minlabelspacing,mode,other,overflow,position,rowalign,rowlines,rowspan,rquote,rspace,scriptlevel,scriptminsize,scriptsizemultiplier,selection,separator,separators,shift,side,src,stackalign,stretchy,subscriptshift,superscriptshift,symmetric,voffset,width,widths,xlink:href,xlink:show,xlink:type,xmlns"); | ||
| const isKnownMathMLAttr = /*@__PURE__*/ makeMap("accent,accentunder,actiontype,align,alignmentscope,altimg,altimg-height,altimg-valign,altimg-width,alttext,bevelled,close,columnsalign,columnlines,columnspan,denomalign,depth,dir,display,displaystyle,encoding,equalcolumns,equalrows,fence,fontstyle,fontweight,form,frame,framespacing,groupalign,height,href,id,indentalign,indentalignfirst,indentalignlast,indentshift,indentshiftfirst,indentshiftlast,indextype,justify,largetop,largeop,lquote,lspace,mathbackground,mathcolor,mathsize,mathvariant,maxsize,minlabelspacing,mode,other,overflow,position,rowalign,rowlines,rowspan,rquote,rspace,scriptlevel,scriptminsize,scriptsizemultiplier,selection,separator,separators,shift,side,src,stackalign,stretchy,subscriptshift,superscriptshift,symmetric,voffset,width,widths,xlink:href,xlink:show,xlink:type,xmlns"); | ||
| /** | ||
@@ -560,2 +560,17 @@ * Shared between server-renderer and runtime-core hydration logic | ||
| } | ||
| function looseCompareCollections(a, b) { | ||
| if (a.size !== b.size) return false; | ||
| const candidates = Array.from(b); | ||
| const matched = new Uint8Array(candidates.length); | ||
| for (const item of a) { | ||
| let index = -1; | ||
| for (let i = 0; i < candidates.length; i++) if (!matched[i] && looseEqual(item, candidates[i])) { | ||
| index = i; | ||
| break; | ||
| } | ||
| if (index < 0) return false; | ||
| matched[index] = 1; | ||
| } | ||
| return true; | ||
| } | ||
| function looseEqual(a, b) { | ||
@@ -576,2 +591,8 @@ if (a === b) return true; | ||
| if (!aValidType || !bValidType) return false; | ||
| aValidType = isMap(a); | ||
| bValidType = isMap(b); | ||
| if (aValidType || bValidType) return aValidType && bValidType ? looseCompareCollections(a, b) : false; | ||
| aValidType = isSet(a); | ||
| bValidType = isSet(b); | ||
| if (aValidType || bValidType) return aValidType && bValidType ? looseCompareCollections(a, b) : false; | ||
| if (Object.keys(a).length !== Object.keys(b).length) return false; | ||
@@ -578,0 +599,0 @@ for (const key in a) { |
+1
-1
| { | ||
| "name": "@vue/shared", | ||
| "version": "3.6.0-rc.5", | ||
| "version": "3.6.0-rc.6", | ||
| "description": "internal utils shared across @vue packages", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
121419
1.93%3089
2.05%