mirror of
https://github.com/notherealmarco/WASAPhoto.git
synced 2025-05-05 20:32:35 +02:00
Add decaf webui
This commit is contained in:
parent
6b4c9bb531
commit
69c0388954
742 changed files with 608981 additions and 6 deletions
21
webui/node_modules/@vue/shared/LICENSE
generated
vendored
Normal file
21
webui/node_modules/@vue/shared/LICENSE
generated
vendored
Normal file
|
@ -0,0 +1,21 @@
|
|||
The MIT License (MIT)
|
||||
|
||||
Copyright (c) 2018-present, Yuxi (Evan) You
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in
|
||||
all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||
THE SOFTWARE.
|
3
webui/node_modules/@vue/shared/README.md
generated
vendored
Normal file
3
webui/node_modules/@vue/shared/README.md
generated
vendored
Normal file
|
@ -0,0 +1,3 @@
|
|||
# @vue/shared
|
||||
|
||||
Internal utility functions and constants shared across `@vue` packages.
|
659
webui/node_modules/@vue/shared/dist/shared.cjs.js
generated
vendored
Normal file
659
webui/node_modules/@vue/shared/dist/shared.cjs.js
generated
vendored
Normal file
|
@ -0,0 +1,659 @@
|
|||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, '__esModule', { value: true });
|
||||
|
||||
/**
|
||||
* 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 rollup can tree-shake them if necessary.
|
||||
*/
|
||||
function makeMap(str, expectsLowerCase) {
|
||||
const map = Object.create(null);
|
||||
const list = str.split(',');
|
||||
for (let i = 0; i < list.length; i++) {
|
||||
map[list[i]] = true;
|
||||
}
|
||||
return expectsLowerCase ? val => !!map[val.toLowerCase()] : val => !!map[val];
|
||||
}
|
||||
|
||||
/**
|
||||
* dev only flag -> name mapping
|
||||
*/
|
||||
const PatchFlagNames = {
|
||||
[1 /* TEXT */]: `TEXT`,
|
||||
[2 /* CLASS */]: `CLASS`,
|
||||
[4 /* STYLE */]: `STYLE`,
|
||||
[8 /* PROPS */]: `PROPS`,
|
||||
[16 /* FULL_PROPS */]: `FULL_PROPS`,
|
||||
[32 /* HYDRATE_EVENTS */]: `HYDRATE_EVENTS`,
|
||||
[64 /* STABLE_FRAGMENT */]: `STABLE_FRAGMENT`,
|
||||
[128 /* KEYED_FRAGMENT */]: `KEYED_FRAGMENT`,
|
||||
[256 /* UNKEYED_FRAGMENT */]: `UNKEYED_FRAGMENT`,
|
||||
[512 /* NEED_PATCH */]: `NEED_PATCH`,
|
||||
[1024 /* DYNAMIC_SLOTS */]: `DYNAMIC_SLOTS`,
|
||||
[2048 /* DEV_ROOT_FRAGMENT */]: `DEV_ROOT_FRAGMENT`,
|
||||
[-1 /* HOISTED */]: `HOISTED`,
|
||||
[-2 /* BAIL */]: `BAIL`
|
||||
};
|
||||
|
||||
/**
|
||||
* Dev only
|
||||
*/
|
||||
const slotFlagsText = {
|
||||
[1 /* STABLE */]: 'STABLE',
|
||||
[2 /* DYNAMIC */]: 'DYNAMIC',
|
||||
[3 /* FORWARDED */]: 'FORWARDED'
|
||||
};
|
||||
|
||||
const GLOBALS_WHITE_LISTED = 'Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,' +
|
||||
'decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,' +
|
||||
'Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt';
|
||||
const isGloballyWhitelisted = /*#__PURE__*/ makeMap(GLOBALS_WHITE_LISTED);
|
||||
|
||||
const range = 2;
|
||||
function generateCodeFrame(source, start = 0, end = source.length) {
|
||||
// Split the content into individual lines but capture the newline sequence
|
||||
// that separated each line. This is important because the actual sequence is
|
||||
// needed to properly take into account the full line length for offset
|
||||
// comparison
|
||||
let lines = source.split(/(\r?\n)/);
|
||||
// Separate the lines and newline sequences into separate arrays for easier referencing
|
||||
const newlineSequences = lines.filter((_, idx) => idx % 2 === 1);
|
||||
lines = lines.filter((_, idx) => idx % 2 === 0);
|
||||
let count = 0;
|
||||
const res = [];
|
||||
for (let i = 0; i < lines.length; i++) {
|
||||
count +=
|
||||
lines[i].length +
|
||||
((newlineSequences[i] && newlineSequences[i].length) || 0);
|
||||
if (count >= start) {
|
||||
for (let j = i - range; j <= i + range || end > count; j++) {
|
||||
if (j < 0 || j >= lines.length)
|
||||
continue;
|
||||
const line = j + 1;
|
||||
res.push(`${line}${' '.repeat(Math.max(3 - String(line).length, 0))}| ${lines[j]}`);
|
||||
const lineLength = lines[j].length;
|
||||
const newLineSeqLength = (newlineSequences[j] && newlineSequences[j].length) || 0;
|
||||
if (j === i) {
|
||||
// push underline
|
||||
const pad = start - (count - (lineLength + newLineSeqLength));
|
||||
const length = Math.max(1, end > count ? lineLength - pad : end - start);
|
||||
res.push(` | ` + ' '.repeat(pad) + '^'.repeat(length));
|
||||
}
|
||||
else if (j > i) {
|
||||
if (end > count) {
|
||||
const length = Math.max(Math.min(end - count, lineLength), 1);
|
||||
res.push(` | ` + '^'.repeat(length));
|
||||
}
|
||||
count += lineLength + newLineSeqLength;
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
return res.join('\n');
|
||||
}
|
||||
|
||||
/**
|
||||
* On the client we only need to offer special cases for boolean attributes that
|
||||
* have different names from their corresponding dom properties:
|
||||
* - itemscope -> N/A
|
||||
* - allowfullscreen -> allowFullscreen
|
||||
* - formnovalidate -> formNoValidate
|
||||
* - ismap -> isMap
|
||||
* - nomodule -> noModule
|
||||
* - novalidate -> noValidate
|
||||
* - readonly -> readOnly
|
||||
*/
|
||||
const specialBooleanAttrs = `itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly`;
|
||||
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,hidden,` +
|
||||
`loop,open,required,reversed,scoped,seamless,` +
|
||||
`checked,muted,multiple,selected`);
|
||||
/**
|
||||
* Boolean attributes should be included if the value is truthy or ''.
|
||||
* e.g. `<select multiple>` compiles to `{ multiple: '' }`
|
||||
*/
|
||||
function includeBooleanAttr(value) {
|
||||
return !!value || value === '';
|
||||
}
|
||||
const unsafeAttrCharRE = /[>/="'\u0009\u000a\u000c\u0020]/;
|
||||
const attrValidationCache = {};
|
||||
function isSSRSafeAttrName(name) {
|
||||
if (attrValidationCache.hasOwnProperty(name)) {
|
||||
return attrValidationCache[name];
|
||||
}
|
||||
const isUnsafe = unsafeAttrCharRE.test(name);
|
||||
if (isUnsafe) {
|
||||
console.error(`unsafe attribute name: ${name}`);
|
||||
}
|
||||
return (attrValidationCache[name] = !isUnsafe);
|
||||
}
|
||||
const propsToAttrMap = {
|
||||
acceptCharset: 'accept-charset',
|
||||
className: 'class',
|
||||
htmlFor: 'for',
|
||||
httpEquiv: 'http-equiv'
|
||||
};
|
||||
/**
|
||||
* CSS properties that accept plain numbers
|
||||
*/
|
||||
const isNoUnitNumericStyleProp = /*#__PURE__*/ makeMap(`animation-iteration-count,border-image-outset,border-image-slice,` +
|
||||
`border-image-width,box-flex,box-flex-group,box-ordinal-group,column-count,` +
|
||||
`columns,flex,flex-grow,flex-positive,flex-shrink,flex-negative,flex-order,` +
|
||||
`grid-row,grid-row-end,grid-row-span,grid-row-start,grid-column,` +
|
||||
`grid-column-end,grid-column-span,grid-column-start,font-weight,line-clamp,` +
|
||||
`line-height,opacity,order,orphans,tab-size,widows,z-index,zoom,` +
|
||||
// SVG
|
||||
`fill-opacity,flood-opacity,stop-opacity,stroke-dasharray,stroke-dashoffset,` +
|
||||
`stroke-miterlimit,stroke-opacity,stroke-width`);
|
||||
/**
|
||||
* 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
|
||||
*/
|
||||
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,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,xml:base,xml:lang,` +
|
||||
`xml:space,y,y1,y2,yChannelSelector,z,zoomAndPan`);
|
||||
|
||||
function normalizeStyle(value) {
|
||||
if (isArray(value)) {
|
||||
const res = {};
|
||||
for (let i = 0; i < value.length; i++) {
|
||||
const item = value[i];
|
||||
const normalized = isString(item)
|
||||
? parseStringStyle(item)
|
||||
: normalizeStyle(item);
|
||||
if (normalized) {
|
||||
for (const key in normalized) {
|
||||
res[key] = normalized[key];
|
||||
}
|
||||
}
|
||||
}
|
||||
return res;
|
||||
}
|
||||
else if (isString(value)) {
|
||||
return value;
|
||||
}
|
||||
else if (isObject(value)) {
|
||||
return value;
|
||||
}
|
||||
}
|
||||
const listDelimiterRE = /;(?![^(]*\))/g;
|
||||
const propertyDelimiterRE = /:(.+)/;
|
||||
function parseStringStyle(cssText) {
|
||||
const ret = {};
|
||||
cssText.split(listDelimiterRE).forEach(item => {
|
||||
if (item) {
|
||||
const tmp = item.split(propertyDelimiterRE);
|
||||
tmp.length > 1 && (ret[tmp[0].trim()] = tmp[1].trim());
|
||||
}
|
||||
});
|
||||
return ret;
|
||||
}
|
||||
function stringifyStyle(styles) {
|
||||
let ret = '';
|
||||
if (!styles || isString(styles)) {
|
||||
return ret;
|
||||
}
|
||||
for (const key in styles) {
|
||||
const value = styles[key];
|
||||
const normalizedKey = key.startsWith(`--`) ? key : hyphenate(key);
|
||||
if (isString(value) ||
|
||||
(typeof value === 'number' && isNoUnitNumericStyleProp(normalizedKey))) {
|
||||
// only render valid values
|
||||
ret += `${normalizedKey}:${value};`;
|
||||
}
|
||||
}
|
||||
return ret;
|
||||
}
|
||||
function normalizeClass(value) {
|
||||
let res = '';
|
||||
if (isString(value)) {
|
||||
res = value;
|
||||
}
|
||||
else if (isArray(value)) {
|
||||
for (let i = 0; i < value.length; i++) {
|
||||
const normalized = normalizeClass(value[i]);
|
||||
if (normalized) {
|
||||
res += normalized + ' ';
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (isObject(value)) {
|
||||
for (const name in value) {
|
||||
if (value[name]) {
|
||||
res += name + ' ';
|
||||
}
|
||||
}
|
||||
}
|
||||
return res.trim();
|
||||
}
|
||||
function normalizeProps(props) {
|
||||
if (!props)
|
||||
return null;
|
||||
let { class: klass, style } = props;
|
||||
if (klass && !isString(klass)) {
|
||||
props.class = normalizeClass(klass);
|
||||
}
|
||||
if (style) {
|
||||
props.style = normalizeStyle(style);
|
||||
}
|
||||
return props;
|
||||
}
|
||||
|
||||
// These tag configs are shared between compiler-dom and runtime-dom, so they
|
||||
// https://developer.mozilla.org/en-US/docs/Web/HTML/Element
|
||||
const HTML_TAGS = 'html,body,base,head,link,meta,style,title,address,article,aside,footer,' +
|
||||
'header,h1,h2,h3,h4,h5,h6,nav,section,div,dd,dl,dt,figcaption,' +
|
||||
'figure,picture,hr,img,li,main,ol,p,pre,ul,a,b,abbr,bdi,bdo,br,cite,code,' +
|
||||
'data,dfn,em,i,kbd,mark,q,rp,rt,ruby,s,samp,small,span,strong,sub,sup,' +
|
||||
'time,u,var,wbr,area,audio,map,track,video,embed,object,param,source,' +
|
||||
'canvas,script,noscript,del,ins,caption,col,colgroup,table,thead,tbody,td,' +
|
||||
'th,tr,button,datalist,fieldset,form,input,label,legend,meter,optgroup,' +
|
||||
'option,output,progress,select,textarea,details,dialog,menu,' +
|
||||
'summary,template,blockquote,iframe,tfoot';
|
||||
// https://developer.mozilla.org/en-US/docs/Web/SVG/Element
|
||||
const SVG_TAGS = 'svg,animate,animateMotion,animateTransform,circle,clipPath,color-profile,' +
|
||||
'defs,desc,discard,ellipse,feBlend,feColorMatrix,feComponentTransfer,' +
|
||||
'feComposite,feConvolveMatrix,feDiffuseLighting,feDisplacementMap,' +
|
||||
'feDistanceLight,feDropShadow,feFlood,feFuncA,feFuncB,feFuncG,feFuncR,' +
|
||||
'feGaussianBlur,feImage,feMerge,feMergeNode,feMorphology,feOffset,' +
|
||||
'fePointLight,feSpecularLighting,feSpotLight,feTile,feTurbulence,filter,' +
|
||||
'foreignObject,g,hatch,hatchpath,image,line,linearGradient,marker,mask,' +
|
||||
'mesh,meshgradient,meshpatch,meshrow,metadata,mpath,path,pattern,' +
|
||||
'polygon,polyline,radialGradient,rect,set,solidcolor,stop,switch,symbol,' +
|
||||
'text,textPath,title,tspan,unknown,use,view';
|
||||
const VOID_TAGS = 'area,base,br,col,embed,hr,img,input,link,meta,param,source,track,wbr';
|
||||
/**
|
||||
* Compiler only.
|
||||
* Do NOT use in runtime code paths unless behind `true` flag.
|
||||
*/
|
||||
const isHTMLTag = /*#__PURE__*/ makeMap(HTML_TAGS);
|
||||
/**
|
||||
* Compiler only.
|
||||
* Do NOT use in runtime code paths unless behind `true` flag.
|
||||
*/
|
||||
const isSVGTag = /*#__PURE__*/ makeMap(SVG_TAGS);
|
||||
/**
|
||||
* Compiler only.
|
||||
* Do NOT use in runtime code paths unless behind `true` flag.
|
||||
*/
|
||||
const isVoidTag = /*#__PURE__*/ makeMap(VOID_TAGS);
|
||||
|
||||
const escapeRE = /["'&<>]/;
|
||||
function escapeHtml(string) {
|
||||
const str = '' + string;
|
||||
const match = escapeRE.exec(str);
|
||||
if (!match) {
|
||||
return str;
|
||||
}
|
||||
let html = '';
|
||||
let escaped;
|
||||
let index;
|
||||
let lastIndex = 0;
|
||||
for (index = match.index; index < str.length; index++) {
|
||||
switch (str.charCodeAt(index)) {
|
||||
case 34: // "
|
||||
escaped = '"';
|
||||
break;
|
||||
case 38: // &
|
||||
escaped = '&';
|
||||
break;
|
||||
case 39: // '
|
||||
escaped = ''';
|
||||
break;
|
||||
case 60: // <
|
||||
escaped = '<';
|
||||
break;
|
||||
case 62: // >
|
||||
escaped = '>';
|
||||
break;
|
||||
default:
|
||||
continue;
|
||||
}
|
||||
if (lastIndex !== index) {
|
||||
html += str.slice(lastIndex, index);
|
||||
}
|
||||
lastIndex = index + 1;
|
||||
html += escaped;
|
||||
}
|
||||
return lastIndex !== index ? html + str.slice(lastIndex, index) : html;
|
||||
}
|
||||
// https://www.w3.org/TR/html52/syntax.html#comments
|
||||
const commentStripRE = /^-?>|<!--|-->|--!>|<!-$/g;
|
||||
function escapeHtmlComment(src) {
|
||||
return src.replace(commentStripRE, '');
|
||||
}
|
||||
|
||||
function looseCompareArrays(a, b) {
|
||||
if (a.length !== b.length)
|
||||
return false;
|
||||
let equal = true;
|
||||
for (let i = 0; equal && i < a.length; i++) {
|
||||
equal = looseEqual(a[i], b[i]);
|
||||
}
|
||||
return equal;
|
||||
}
|
||||
function looseEqual(a, b) {
|
||||
if (a === b)
|
||||
return true;
|
||||
let aValidType = isDate(a);
|
||||
let bValidType = isDate(b);
|
||||
if (aValidType || bValidType) {
|
||||
return aValidType && bValidType ? a.getTime() === b.getTime() : false;
|
||||
}
|
||||
aValidType = isSymbol(a);
|
||||
bValidType = isSymbol(b);
|
||||
if (aValidType || bValidType) {
|
||||
return a === b;
|
||||
}
|
||||
aValidType = isArray(a);
|
||||
bValidType = isArray(b);
|
||||
if (aValidType || bValidType) {
|
||||
return aValidType && bValidType ? looseCompareArrays(a, b) : false;
|
||||
}
|
||||
aValidType = isObject(a);
|
||||
bValidType = isObject(b);
|
||||
if (aValidType || bValidType) {
|
||||
/* istanbul ignore if: this if will probably never be called */
|
||||
if (!aValidType || !bValidType) {
|
||||
return false;
|
||||
}
|
||||
const aKeysCount = Object.keys(a).length;
|
||||
const bKeysCount = Object.keys(b).length;
|
||||
if (aKeysCount !== bKeysCount) {
|
||||
return false;
|
||||
}
|
||||
for (const key in a) {
|
||||
const aHasKey = a.hasOwnProperty(key);
|
||||
const bHasKey = b.hasOwnProperty(key);
|
||||
if ((aHasKey && !bHasKey) ||
|
||||
(!aHasKey && bHasKey) ||
|
||||
!looseEqual(a[key], b[key])) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
return String(a) === String(b);
|
||||
}
|
||||
function looseIndexOf(arr, val) {
|
||||
return arr.findIndex(item => looseEqual(item, val));
|
||||
}
|
||||
|
||||
/**
|
||||
* For converting {{ interpolation }} values to displayed strings.
|
||||
* @private
|
||||
*/
|
||||
const toDisplayString = (val) => {
|
||||
return isString(val)
|
||||
? val
|
||||
: val == null
|
||||
? ''
|
||||
: isArray(val) ||
|
||||
(isObject(val) &&
|
||||
(val.toString === objectToString || !isFunction(val.toString)))
|
||||
? JSON.stringify(val, replacer, 2)
|
||||
: String(val);
|
||||
};
|
||||
const replacer = (_key, val) => {
|
||||
// can't use isRef here since @vue/shared has no deps
|
||||
if (val && val.__v_isRef) {
|
||||
return replacer(_key, val.value);
|
||||
}
|
||||
else if (isMap(val)) {
|
||||
return {
|
||||
[`Map(${val.size})`]: [...val.entries()].reduce((entries, [key, val]) => {
|
||||
entries[`${key} =>`] = val;
|
||||
return entries;
|
||||
}, {})
|
||||
};
|
||||
}
|
||||
else if (isSet(val)) {
|
||||
return {
|
||||
[`Set(${val.size})`]: [...val.values()]
|
||||
};
|
||||
}
|
||||
else if (isObject(val) && !isArray(val) && !isPlainObject(val)) {
|
||||
return String(val);
|
||||
}
|
||||
return val;
|
||||
};
|
||||
|
||||
const EMPTY_OBJ = Object.freeze({})
|
||||
;
|
||||
const EMPTY_ARR = Object.freeze([]) ;
|
||||
const NOOP = () => { };
|
||||
/**
|
||||
* Always return false.
|
||||
*/
|
||||
const NO = () => false;
|
||||
const onRE = /^on[^a-z]/;
|
||||
const isOn = (key) => onRE.test(key);
|
||||
const isModelListener = (key) => key.startsWith('onUpdate:');
|
||||
const extend = Object.assign;
|
||||
const remove = (arr, el) => {
|
||||
const i = arr.indexOf(el);
|
||||
if (i > -1) {
|
||||
arr.splice(i, 1);
|
||||
}
|
||||
};
|
||||
const hasOwnProperty = Object.prototype.hasOwnProperty;
|
||||
const hasOwn = (val, key) => hasOwnProperty.call(val, key);
|
||||
const isArray = Array.isArray;
|
||||
const isMap = (val) => toTypeString(val) === '[object Map]';
|
||||
const isSet = (val) => toTypeString(val) === '[object Set]';
|
||||
const isDate = (val) => toTypeString(val) === '[object Date]';
|
||||
const isFunction = (val) => typeof val === 'function';
|
||||
const isString = (val) => typeof val === 'string';
|
||||
const isSymbol = (val) => typeof val === 'symbol';
|
||||
const isObject = (val) => val !== null && typeof val === 'object';
|
||||
const isPromise = (val) => {
|
||||
return isObject(val) && isFunction(val.then) && isFunction(val.catch);
|
||||
};
|
||||
const objectToString = Object.prototype.toString;
|
||||
const toTypeString = (value) => objectToString.call(value);
|
||||
const toRawType = (value) => {
|
||||
// extract "RawType" from strings like "[object RawType]"
|
||||
return toTypeString(value).slice(8, -1);
|
||||
};
|
||||
const isPlainObject = (val) => toTypeString(val) === '[object Object]';
|
||||
const isIntegerKey = (key) => isString(key) &&
|
||||
key !== 'NaN' &&
|
||||
key[0] !== '-' &&
|
||||
'' + parseInt(key, 10) === key;
|
||||
const isReservedProp = /*#__PURE__*/ makeMap(
|
||||
// the leading comma is intentional so empty string "" is also included
|
||||
',key,ref,ref_for,ref_key,' +
|
||||
'onVnodeBeforeMount,onVnodeMounted,' +
|
||||
'onVnodeBeforeUpdate,onVnodeUpdated,' +
|
||||
'onVnodeBeforeUnmount,onVnodeUnmounted');
|
||||
const isBuiltInDirective = /*#__PURE__*/ makeMap('bind,cloak,else-if,else,for,html,if,model,on,once,pre,show,slot,text,memo');
|
||||
const cacheStringFunction = (fn) => {
|
||||
const cache = Object.create(null);
|
||||
return ((str) => {
|
||||
const hit = cache[str];
|
||||
return hit || (cache[str] = fn(str));
|
||||
});
|
||||
};
|
||||
const camelizeRE = /-(\w)/g;
|
||||
/**
|
||||
* @private
|
||||
*/
|
||||
const camelize = cacheStringFunction((str) => {
|
||||
return str.replace(camelizeRE, (_, c) => (c ? c.toUpperCase() : ''));
|
||||
});
|
||||
const hyphenateRE = /\B([A-Z])/g;
|
||||
/**
|
||||
* @private
|
||||
*/
|
||||
const hyphenate = cacheStringFunction((str) => str.replace(hyphenateRE, '-$1').toLowerCase());
|
||||
/**
|
||||
* @private
|
||||
*/
|
||||
const capitalize = cacheStringFunction((str) => str.charAt(0).toUpperCase() + str.slice(1));
|
||||
/**
|
||||
* @private
|
||||
*/
|
||||
const toHandlerKey = cacheStringFunction((str) => str ? `on${capitalize(str)}` : ``);
|
||||
// compare whether a value has changed, accounting for NaN.
|
||||
const hasChanged = (value, oldValue) => !Object.is(value, oldValue);
|
||||
const invokeArrayFns = (fns, arg) => {
|
||||
for (let i = 0; i < fns.length; i++) {
|
||||
fns[i](arg);
|
||||
}
|
||||
};
|
||||
const def = (obj, key, value) => {
|
||||
Object.defineProperty(obj, key, {
|
||||
configurable: true,
|
||||
enumerable: false,
|
||||
value
|
||||
});
|
||||
};
|
||||
const toNumber = (val) => {
|
||||
const n = parseFloat(val);
|
||||
return isNaN(n) ? val : n;
|
||||
};
|
||||
let _globalThis;
|
||||
const getGlobalThis = () => {
|
||||
return (_globalThis ||
|
||||
(_globalThis =
|
||||
typeof globalThis !== 'undefined'
|
||||
? globalThis
|
||||
: typeof self !== 'undefined'
|
||||
? self
|
||||
: typeof window !== 'undefined'
|
||||
? window
|
||||
: typeof global !== 'undefined'
|
||||
? global
|
||||
: {}));
|
||||
};
|
||||
const identRE = /^[_$a-zA-Z\xA0-\uFFFF][_$a-zA-Z0-9\xA0-\uFFFF]*$/;
|
||||
function genPropsAccessExp(name) {
|
||||
return identRE.test(name)
|
||||
? `__props.${name}`
|
||||
: `__props[${JSON.stringify(name)}]`;
|
||||
}
|
||||
|
||||
exports.EMPTY_ARR = EMPTY_ARR;
|
||||
exports.EMPTY_OBJ = EMPTY_OBJ;
|
||||
exports.NO = NO;
|
||||
exports.NOOP = NOOP;
|
||||
exports.PatchFlagNames = PatchFlagNames;
|
||||
exports.camelize = camelize;
|
||||
exports.capitalize = capitalize;
|
||||
exports.def = def;
|
||||
exports.escapeHtml = escapeHtml;
|
||||
exports.escapeHtmlComment = escapeHtmlComment;
|
||||
exports.extend = extend;
|
||||
exports.genPropsAccessExp = genPropsAccessExp;
|
||||
exports.generateCodeFrame = generateCodeFrame;
|
||||
exports.getGlobalThis = getGlobalThis;
|
||||
exports.hasChanged = hasChanged;
|
||||
exports.hasOwn = hasOwn;
|
||||
exports.hyphenate = hyphenate;
|
||||
exports.includeBooleanAttr = includeBooleanAttr;
|
||||
exports.invokeArrayFns = invokeArrayFns;
|
||||
exports.isArray = isArray;
|
||||
exports.isBooleanAttr = isBooleanAttr;
|
||||
exports.isBuiltInDirective = isBuiltInDirective;
|
||||
exports.isDate = isDate;
|
||||
exports.isFunction = isFunction;
|
||||
exports.isGloballyWhitelisted = isGloballyWhitelisted;
|
||||
exports.isHTMLTag = isHTMLTag;
|
||||
exports.isIntegerKey = isIntegerKey;
|
||||
exports.isKnownHtmlAttr = isKnownHtmlAttr;
|
||||
exports.isKnownSvgAttr = isKnownSvgAttr;
|
||||
exports.isMap = isMap;
|
||||
exports.isModelListener = isModelListener;
|
||||
exports.isNoUnitNumericStyleProp = isNoUnitNumericStyleProp;
|
||||
exports.isObject = isObject;
|
||||
exports.isOn = isOn;
|
||||
exports.isPlainObject = isPlainObject;
|
||||
exports.isPromise = isPromise;
|
||||
exports.isReservedProp = isReservedProp;
|
||||
exports.isSSRSafeAttrName = isSSRSafeAttrName;
|
||||
exports.isSVGTag = isSVGTag;
|
||||
exports.isSet = isSet;
|
||||
exports.isSpecialBooleanAttr = isSpecialBooleanAttr;
|
||||
exports.isString = isString;
|
||||
exports.isSymbol = isSymbol;
|
||||
exports.isVoidTag = isVoidTag;
|
||||
exports.looseEqual = looseEqual;
|
||||
exports.looseIndexOf = looseIndexOf;
|
||||
exports.makeMap = makeMap;
|
||||
exports.normalizeClass = normalizeClass;
|
||||
exports.normalizeProps = normalizeProps;
|
||||
exports.normalizeStyle = normalizeStyle;
|
||||
exports.objectToString = objectToString;
|
||||
exports.parseStringStyle = parseStringStyle;
|
||||
exports.propsToAttrMap = propsToAttrMap;
|
||||
exports.remove = remove;
|
||||
exports.slotFlagsText = slotFlagsText;
|
||||
exports.stringifyStyle = stringifyStyle;
|
||||
exports.toDisplayString = toDisplayString;
|
||||
exports.toHandlerKey = toHandlerKey;
|
||||
exports.toNumber = toNumber;
|
||||
exports.toRawType = toRawType;
|
||||
exports.toTypeString = toTypeString;
|
658
webui/node_modules/@vue/shared/dist/shared.cjs.prod.js
generated
vendored
Normal file
658
webui/node_modules/@vue/shared/dist/shared.cjs.prod.js
generated
vendored
Normal file
|
@ -0,0 +1,658 @@
|
|||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, '__esModule', { value: true });
|
||||
|
||||
/**
|
||||
* 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 rollup can tree-shake them if necessary.
|
||||
*/
|
||||
function makeMap(str, expectsLowerCase) {
|
||||
const map = Object.create(null);
|
||||
const list = str.split(',');
|
||||
for (let i = 0; i < list.length; i++) {
|
||||
map[list[i]] = true;
|
||||
}
|
||||
return expectsLowerCase ? val => !!map[val.toLowerCase()] : val => !!map[val];
|
||||
}
|
||||
|
||||
/**
|
||||
* dev only flag -> name mapping
|
||||
*/
|
||||
const PatchFlagNames = {
|
||||
[1 /* TEXT */]: `TEXT`,
|
||||
[2 /* CLASS */]: `CLASS`,
|
||||
[4 /* STYLE */]: `STYLE`,
|
||||
[8 /* PROPS */]: `PROPS`,
|
||||
[16 /* FULL_PROPS */]: `FULL_PROPS`,
|
||||
[32 /* HYDRATE_EVENTS */]: `HYDRATE_EVENTS`,
|
||||
[64 /* STABLE_FRAGMENT */]: `STABLE_FRAGMENT`,
|
||||
[128 /* KEYED_FRAGMENT */]: `KEYED_FRAGMENT`,
|
||||
[256 /* UNKEYED_FRAGMENT */]: `UNKEYED_FRAGMENT`,
|
||||
[512 /* NEED_PATCH */]: `NEED_PATCH`,
|
||||
[1024 /* DYNAMIC_SLOTS */]: `DYNAMIC_SLOTS`,
|
||||
[2048 /* DEV_ROOT_FRAGMENT */]: `DEV_ROOT_FRAGMENT`,
|
||||
[-1 /* HOISTED */]: `HOISTED`,
|
||||
[-2 /* BAIL */]: `BAIL`
|
||||
};
|
||||
|
||||
/**
|
||||
* Dev only
|
||||
*/
|
||||
const slotFlagsText = {
|
||||
[1 /* STABLE */]: 'STABLE',
|
||||
[2 /* DYNAMIC */]: 'DYNAMIC',
|
||||
[3 /* FORWARDED */]: 'FORWARDED'
|
||||
};
|
||||
|
||||
const GLOBALS_WHITE_LISTED = 'Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,' +
|
||||
'decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,' +
|
||||
'Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt';
|
||||
const isGloballyWhitelisted = /*#__PURE__*/ makeMap(GLOBALS_WHITE_LISTED);
|
||||
|
||||
const range = 2;
|
||||
function generateCodeFrame(source, start = 0, end = source.length) {
|
||||
// Split the content into individual lines but capture the newline sequence
|
||||
// that separated each line. This is important because the actual sequence is
|
||||
// needed to properly take into account the full line length for offset
|
||||
// comparison
|
||||
let lines = source.split(/(\r?\n)/);
|
||||
// Separate the lines and newline sequences into separate arrays for easier referencing
|
||||
const newlineSequences = lines.filter((_, idx) => idx % 2 === 1);
|
||||
lines = lines.filter((_, idx) => idx % 2 === 0);
|
||||
let count = 0;
|
||||
const res = [];
|
||||
for (let i = 0; i < lines.length; i++) {
|
||||
count +=
|
||||
lines[i].length +
|
||||
((newlineSequences[i] && newlineSequences[i].length) || 0);
|
||||
if (count >= start) {
|
||||
for (let j = i - range; j <= i + range || end > count; j++) {
|
||||
if (j < 0 || j >= lines.length)
|
||||
continue;
|
||||
const line = j + 1;
|
||||
res.push(`${line}${' '.repeat(Math.max(3 - String(line).length, 0))}| ${lines[j]}`);
|
||||
const lineLength = lines[j].length;
|
||||
const newLineSeqLength = (newlineSequences[j] && newlineSequences[j].length) || 0;
|
||||
if (j === i) {
|
||||
// push underline
|
||||
const pad = start - (count - (lineLength + newLineSeqLength));
|
||||
const length = Math.max(1, end > count ? lineLength - pad : end - start);
|
||||
res.push(` | ` + ' '.repeat(pad) + '^'.repeat(length));
|
||||
}
|
||||
else if (j > i) {
|
||||
if (end > count) {
|
||||
const length = Math.max(Math.min(end - count, lineLength), 1);
|
||||
res.push(` | ` + '^'.repeat(length));
|
||||
}
|
||||
count += lineLength + newLineSeqLength;
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
return res.join('\n');
|
||||
}
|
||||
|
||||
/**
|
||||
* On the client we only need to offer special cases for boolean attributes that
|
||||
* have different names from their corresponding dom properties:
|
||||
* - itemscope -> N/A
|
||||
* - allowfullscreen -> allowFullscreen
|
||||
* - formnovalidate -> formNoValidate
|
||||
* - ismap -> isMap
|
||||
* - nomodule -> noModule
|
||||
* - novalidate -> noValidate
|
||||
* - readonly -> readOnly
|
||||
*/
|
||||
const specialBooleanAttrs = `itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly`;
|
||||
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,hidden,` +
|
||||
`loop,open,required,reversed,scoped,seamless,` +
|
||||
`checked,muted,multiple,selected`);
|
||||
/**
|
||||
* Boolean attributes should be included if the value is truthy or ''.
|
||||
* e.g. `<select multiple>` compiles to `{ multiple: '' }`
|
||||
*/
|
||||
function includeBooleanAttr(value) {
|
||||
return !!value || value === '';
|
||||
}
|
||||
const unsafeAttrCharRE = /[>/="'\u0009\u000a\u000c\u0020]/;
|
||||
const attrValidationCache = {};
|
||||
function isSSRSafeAttrName(name) {
|
||||
if (attrValidationCache.hasOwnProperty(name)) {
|
||||
return attrValidationCache[name];
|
||||
}
|
||||
const isUnsafe = unsafeAttrCharRE.test(name);
|
||||
if (isUnsafe) {
|
||||
console.error(`unsafe attribute name: ${name}`);
|
||||
}
|
||||
return (attrValidationCache[name] = !isUnsafe);
|
||||
}
|
||||
const propsToAttrMap = {
|
||||
acceptCharset: 'accept-charset',
|
||||
className: 'class',
|
||||
htmlFor: 'for',
|
||||
httpEquiv: 'http-equiv'
|
||||
};
|
||||
/**
|
||||
* CSS properties that accept plain numbers
|
||||
*/
|
||||
const isNoUnitNumericStyleProp = /*#__PURE__*/ makeMap(`animation-iteration-count,border-image-outset,border-image-slice,` +
|
||||
`border-image-width,box-flex,box-flex-group,box-ordinal-group,column-count,` +
|
||||
`columns,flex,flex-grow,flex-positive,flex-shrink,flex-negative,flex-order,` +
|
||||
`grid-row,grid-row-end,grid-row-span,grid-row-start,grid-column,` +
|
||||
`grid-column-end,grid-column-span,grid-column-start,font-weight,line-clamp,` +
|
||||
`line-height,opacity,order,orphans,tab-size,widows,z-index,zoom,` +
|
||||
// SVG
|
||||
`fill-opacity,flood-opacity,stop-opacity,stroke-dasharray,stroke-dashoffset,` +
|
||||
`stroke-miterlimit,stroke-opacity,stroke-width`);
|
||||
/**
|
||||
* 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
|
||||
*/
|
||||
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,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,xml:base,xml:lang,` +
|
||||
`xml:space,y,y1,y2,yChannelSelector,z,zoomAndPan`);
|
||||
|
||||
function normalizeStyle(value) {
|
||||
if (isArray(value)) {
|
||||
const res = {};
|
||||
for (let i = 0; i < value.length; i++) {
|
||||
const item = value[i];
|
||||
const normalized = isString(item)
|
||||
? parseStringStyle(item)
|
||||
: normalizeStyle(item);
|
||||
if (normalized) {
|
||||
for (const key in normalized) {
|
||||
res[key] = normalized[key];
|
||||
}
|
||||
}
|
||||
}
|
||||
return res;
|
||||
}
|
||||
else if (isString(value)) {
|
||||
return value;
|
||||
}
|
||||
else if (isObject(value)) {
|
||||
return value;
|
||||
}
|
||||
}
|
||||
const listDelimiterRE = /;(?![^(]*\))/g;
|
||||
const propertyDelimiterRE = /:(.+)/;
|
||||
function parseStringStyle(cssText) {
|
||||
const ret = {};
|
||||
cssText.split(listDelimiterRE).forEach(item => {
|
||||
if (item) {
|
||||
const tmp = item.split(propertyDelimiterRE);
|
||||
tmp.length > 1 && (ret[tmp[0].trim()] = tmp[1].trim());
|
||||
}
|
||||
});
|
||||
return ret;
|
||||
}
|
||||
function stringifyStyle(styles) {
|
||||
let ret = '';
|
||||
if (!styles || isString(styles)) {
|
||||
return ret;
|
||||
}
|
||||
for (const key in styles) {
|
||||
const value = styles[key];
|
||||
const normalizedKey = key.startsWith(`--`) ? key : hyphenate(key);
|
||||
if (isString(value) ||
|
||||
(typeof value === 'number' && isNoUnitNumericStyleProp(normalizedKey))) {
|
||||
// only render valid values
|
||||
ret += `${normalizedKey}:${value};`;
|
||||
}
|
||||
}
|
||||
return ret;
|
||||
}
|
||||
function normalizeClass(value) {
|
||||
let res = '';
|
||||
if (isString(value)) {
|
||||
res = value;
|
||||
}
|
||||
else if (isArray(value)) {
|
||||
for (let i = 0; i < value.length; i++) {
|
||||
const normalized = normalizeClass(value[i]);
|
||||
if (normalized) {
|
||||
res += normalized + ' ';
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (isObject(value)) {
|
||||
for (const name in value) {
|
||||
if (value[name]) {
|
||||
res += name + ' ';
|
||||
}
|
||||
}
|
||||
}
|
||||
return res.trim();
|
||||
}
|
||||
function normalizeProps(props) {
|
||||
if (!props)
|
||||
return null;
|
||||
let { class: klass, style } = props;
|
||||
if (klass && !isString(klass)) {
|
||||
props.class = normalizeClass(klass);
|
||||
}
|
||||
if (style) {
|
||||
props.style = normalizeStyle(style);
|
||||
}
|
||||
return props;
|
||||
}
|
||||
|
||||
// These tag configs are shared between compiler-dom and runtime-dom, so they
|
||||
// https://developer.mozilla.org/en-US/docs/Web/HTML/Element
|
||||
const HTML_TAGS = 'html,body,base,head,link,meta,style,title,address,article,aside,footer,' +
|
||||
'header,h1,h2,h3,h4,h5,h6,nav,section,div,dd,dl,dt,figcaption,' +
|
||||
'figure,picture,hr,img,li,main,ol,p,pre,ul,a,b,abbr,bdi,bdo,br,cite,code,' +
|
||||
'data,dfn,em,i,kbd,mark,q,rp,rt,ruby,s,samp,small,span,strong,sub,sup,' +
|
||||
'time,u,var,wbr,area,audio,map,track,video,embed,object,param,source,' +
|
||||
'canvas,script,noscript,del,ins,caption,col,colgroup,table,thead,tbody,td,' +
|
||||
'th,tr,button,datalist,fieldset,form,input,label,legend,meter,optgroup,' +
|
||||
'option,output,progress,select,textarea,details,dialog,menu,' +
|
||||
'summary,template,blockquote,iframe,tfoot';
|
||||
// https://developer.mozilla.org/en-US/docs/Web/SVG/Element
|
||||
const SVG_TAGS = 'svg,animate,animateMotion,animateTransform,circle,clipPath,color-profile,' +
|
||||
'defs,desc,discard,ellipse,feBlend,feColorMatrix,feComponentTransfer,' +
|
||||
'feComposite,feConvolveMatrix,feDiffuseLighting,feDisplacementMap,' +
|
||||
'feDistanceLight,feDropShadow,feFlood,feFuncA,feFuncB,feFuncG,feFuncR,' +
|
||||
'feGaussianBlur,feImage,feMerge,feMergeNode,feMorphology,feOffset,' +
|
||||
'fePointLight,feSpecularLighting,feSpotLight,feTile,feTurbulence,filter,' +
|
||||
'foreignObject,g,hatch,hatchpath,image,line,linearGradient,marker,mask,' +
|
||||
'mesh,meshgradient,meshpatch,meshrow,metadata,mpath,path,pattern,' +
|
||||
'polygon,polyline,radialGradient,rect,set,solidcolor,stop,switch,symbol,' +
|
||||
'text,textPath,title,tspan,unknown,use,view';
|
||||
const VOID_TAGS = 'area,base,br,col,embed,hr,img,input,link,meta,param,source,track,wbr';
|
||||
/**
|
||||
* Compiler only.
|
||||
* Do NOT use in runtime code paths unless behind `false` flag.
|
||||
*/
|
||||
const isHTMLTag = /*#__PURE__*/ makeMap(HTML_TAGS);
|
||||
/**
|
||||
* Compiler only.
|
||||
* Do NOT use in runtime code paths unless behind `false` flag.
|
||||
*/
|
||||
const isSVGTag = /*#__PURE__*/ makeMap(SVG_TAGS);
|
||||
/**
|
||||
* Compiler only.
|
||||
* Do NOT use in runtime code paths unless behind `false` flag.
|
||||
*/
|
||||
const isVoidTag = /*#__PURE__*/ makeMap(VOID_TAGS);
|
||||
|
||||
const escapeRE = /["'&<>]/;
|
||||
function escapeHtml(string) {
|
||||
const str = '' + string;
|
||||
const match = escapeRE.exec(str);
|
||||
if (!match) {
|
||||
return str;
|
||||
}
|
||||
let html = '';
|
||||
let escaped;
|
||||
let index;
|
||||
let lastIndex = 0;
|
||||
for (index = match.index; index < str.length; index++) {
|
||||
switch (str.charCodeAt(index)) {
|
||||
case 34: // "
|
||||
escaped = '"';
|
||||
break;
|
||||
case 38: // &
|
||||
escaped = '&';
|
||||
break;
|
||||
case 39: // '
|
||||
escaped = ''';
|
||||
break;
|
||||
case 60: // <
|
||||
escaped = '<';
|
||||
break;
|
||||
case 62: // >
|
||||
escaped = '>';
|
||||
break;
|
||||
default:
|
||||
continue;
|
||||
}
|
||||
if (lastIndex !== index) {
|
||||
html += str.slice(lastIndex, index);
|
||||
}
|
||||
lastIndex = index + 1;
|
||||
html += escaped;
|
||||
}
|
||||
return lastIndex !== index ? html + str.slice(lastIndex, index) : html;
|
||||
}
|
||||
// https://www.w3.org/TR/html52/syntax.html#comments
|
||||
const commentStripRE = /^-?>|<!--|-->|--!>|<!-$/g;
|
||||
function escapeHtmlComment(src) {
|
||||
return src.replace(commentStripRE, '');
|
||||
}
|
||||
|
||||
function looseCompareArrays(a, b) {
|
||||
if (a.length !== b.length)
|
||||
return false;
|
||||
let equal = true;
|
||||
for (let i = 0; equal && i < a.length; i++) {
|
||||
equal = looseEqual(a[i], b[i]);
|
||||
}
|
||||
return equal;
|
||||
}
|
||||
function looseEqual(a, b) {
|
||||
if (a === b)
|
||||
return true;
|
||||
let aValidType = isDate(a);
|
||||
let bValidType = isDate(b);
|
||||
if (aValidType || bValidType) {
|
||||
return aValidType && bValidType ? a.getTime() === b.getTime() : false;
|
||||
}
|
||||
aValidType = isSymbol(a);
|
||||
bValidType = isSymbol(b);
|
||||
if (aValidType || bValidType) {
|
||||
return a === b;
|
||||
}
|
||||
aValidType = isArray(a);
|
||||
bValidType = isArray(b);
|
||||
if (aValidType || bValidType) {
|
||||
return aValidType && bValidType ? looseCompareArrays(a, b) : false;
|
||||
}
|
||||
aValidType = isObject(a);
|
||||
bValidType = isObject(b);
|
||||
if (aValidType || bValidType) {
|
||||
/* istanbul ignore if: this if will probably never be called */
|
||||
if (!aValidType || !bValidType) {
|
||||
return false;
|
||||
}
|
||||
const aKeysCount = Object.keys(a).length;
|
||||
const bKeysCount = Object.keys(b).length;
|
||||
if (aKeysCount !== bKeysCount) {
|
||||
return false;
|
||||
}
|
||||
for (const key in a) {
|
||||
const aHasKey = a.hasOwnProperty(key);
|
||||
const bHasKey = b.hasOwnProperty(key);
|
||||
if ((aHasKey && !bHasKey) ||
|
||||
(!aHasKey && bHasKey) ||
|
||||
!looseEqual(a[key], b[key])) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
return String(a) === String(b);
|
||||
}
|
||||
function looseIndexOf(arr, val) {
|
||||
return arr.findIndex(item => looseEqual(item, val));
|
||||
}
|
||||
|
||||
/**
|
||||
* For converting {{ interpolation }} values to displayed strings.
|
||||
* @private
|
||||
*/
|
||||
const toDisplayString = (val) => {
|
||||
return isString(val)
|
||||
? val
|
||||
: val == null
|
||||
? ''
|
||||
: isArray(val) ||
|
||||
(isObject(val) &&
|
||||
(val.toString === objectToString || !isFunction(val.toString)))
|
||||
? JSON.stringify(val, replacer, 2)
|
||||
: String(val);
|
||||
};
|
||||
const replacer = (_key, val) => {
|
||||
// can't use isRef here since @vue/shared has no deps
|
||||
if (val && val.__v_isRef) {
|
||||
return replacer(_key, val.value);
|
||||
}
|
||||
else if (isMap(val)) {
|
||||
return {
|
||||
[`Map(${val.size})`]: [...val.entries()].reduce((entries, [key, val]) => {
|
||||
entries[`${key} =>`] = val;
|
||||
return entries;
|
||||
}, {})
|
||||
};
|
||||
}
|
||||
else if (isSet(val)) {
|
||||
return {
|
||||
[`Set(${val.size})`]: [...val.values()]
|
||||
};
|
||||
}
|
||||
else if (isObject(val) && !isArray(val) && !isPlainObject(val)) {
|
||||
return String(val);
|
||||
}
|
||||
return val;
|
||||
};
|
||||
|
||||
const EMPTY_OBJ = {};
|
||||
const EMPTY_ARR = [];
|
||||
const NOOP = () => { };
|
||||
/**
|
||||
* Always return false.
|
||||
*/
|
||||
const NO = () => false;
|
||||
const onRE = /^on[^a-z]/;
|
||||
const isOn = (key) => onRE.test(key);
|
||||
const isModelListener = (key) => key.startsWith('onUpdate:');
|
||||
const extend = Object.assign;
|
||||
const remove = (arr, el) => {
|
||||
const i = arr.indexOf(el);
|
||||
if (i > -1) {
|
||||
arr.splice(i, 1);
|
||||
}
|
||||
};
|
||||
const hasOwnProperty = Object.prototype.hasOwnProperty;
|
||||
const hasOwn = (val, key) => hasOwnProperty.call(val, key);
|
||||
const isArray = Array.isArray;
|
||||
const isMap = (val) => toTypeString(val) === '[object Map]';
|
||||
const isSet = (val) => toTypeString(val) === '[object Set]';
|
||||
const isDate = (val) => toTypeString(val) === '[object Date]';
|
||||
const isFunction = (val) => typeof val === 'function';
|
||||
const isString = (val) => typeof val === 'string';
|
||||
const isSymbol = (val) => typeof val === 'symbol';
|
||||
const isObject = (val) => val !== null && typeof val === 'object';
|
||||
const isPromise = (val) => {
|
||||
return isObject(val) && isFunction(val.then) && isFunction(val.catch);
|
||||
};
|
||||
const objectToString = Object.prototype.toString;
|
||||
const toTypeString = (value) => objectToString.call(value);
|
||||
const toRawType = (value) => {
|
||||
// extract "RawType" from strings like "[object RawType]"
|
||||
return toTypeString(value).slice(8, -1);
|
||||
};
|
||||
const isPlainObject = (val) => toTypeString(val) === '[object Object]';
|
||||
const isIntegerKey = (key) => isString(key) &&
|
||||
key !== 'NaN' &&
|
||||
key[0] !== '-' &&
|
||||
'' + parseInt(key, 10) === key;
|
||||
const isReservedProp = /*#__PURE__*/ makeMap(
|
||||
// the leading comma is intentional so empty string "" is also included
|
||||
',key,ref,ref_for,ref_key,' +
|
||||
'onVnodeBeforeMount,onVnodeMounted,' +
|
||||
'onVnodeBeforeUpdate,onVnodeUpdated,' +
|
||||
'onVnodeBeforeUnmount,onVnodeUnmounted');
|
||||
const isBuiltInDirective = /*#__PURE__*/ makeMap('bind,cloak,else-if,else,for,html,if,model,on,once,pre,show,slot,text,memo');
|
||||
const cacheStringFunction = (fn) => {
|
||||
const cache = Object.create(null);
|
||||
return ((str) => {
|
||||
const hit = cache[str];
|
||||
return hit || (cache[str] = fn(str));
|
||||
});
|
||||
};
|
||||
const camelizeRE = /-(\w)/g;
|
||||
/**
|
||||
* @private
|
||||
*/
|
||||
const camelize = cacheStringFunction((str) => {
|
||||
return str.replace(camelizeRE, (_, c) => (c ? c.toUpperCase() : ''));
|
||||
});
|
||||
const hyphenateRE = /\B([A-Z])/g;
|
||||
/**
|
||||
* @private
|
||||
*/
|
||||
const hyphenate = cacheStringFunction((str) => str.replace(hyphenateRE, '-$1').toLowerCase());
|
||||
/**
|
||||
* @private
|
||||
*/
|
||||
const capitalize = cacheStringFunction((str) => str.charAt(0).toUpperCase() + str.slice(1));
|
||||
/**
|
||||
* @private
|
||||
*/
|
||||
const toHandlerKey = cacheStringFunction((str) => str ? `on${capitalize(str)}` : ``);
|
||||
// compare whether a value has changed, accounting for NaN.
|
||||
const hasChanged = (value, oldValue) => !Object.is(value, oldValue);
|
||||
const invokeArrayFns = (fns, arg) => {
|
||||
for (let i = 0; i < fns.length; i++) {
|
||||
fns[i](arg);
|
||||
}
|
||||
};
|
||||
const def = (obj, key, value) => {
|
||||
Object.defineProperty(obj, key, {
|
||||
configurable: true,
|
||||
enumerable: false,
|
||||
value
|
||||
});
|
||||
};
|
||||
const toNumber = (val) => {
|
||||
const n = parseFloat(val);
|
||||
return isNaN(n) ? val : n;
|
||||
};
|
||||
let _globalThis;
|
||||
const getGlobalThis = () => {
|
||||
return (_globalThis ||
|
||||
(_globalThis =
|
||||
typeof globalThis !== 'undefined'
|
||||
? globalThis
|
||||
: typeof self !== 'undefined'
|
||||
? self
|
||||
: typeof window !== 'undefined'
|
||||
? window
|
||||
: typeof global !== 'undefined'
|
||||
? global
|
||||
: {}));
|
||||
};
|
||||
const identRE = /^[_$a-zA-Z\xA0-\uFFFF][_$a-zA-Z0-9\xA0-\uFFFF]*$/;
|
||||
function genPropsAccessExp(name) {
|
||||
return identRE.test(name)
|
||||
? `__props.${name}`
|
||||
: `__props[${JSON.stringify(name)}]`;
|
||||
}
|
||||
|
||||
exports.EMPTY_ARR = EMPTY_ARR;
|
||||
exports.EMPTY_OBJ = EMPTY_OBJ;
|
||||
exports.NO = NO;
|
||||
exports.NOOP = NOOP;
|
||||
exports.PatchFlagNames = PatchFlagNames;
|
||||
exports.camelize = camelize;
|
||||
exports.capitalize = capitalize;
|
||||
exports.def = def;
|
||||
exports.escapeHtml = escapeHtml;
|
||||
exports.escapeHtmlComment = escapeHtmlComment;
|
||||
exports.extend = extend;
|
||||
exports.genPropsAccessExp = genPropsAccessExp;
|
||||
exports.generateCodeFrame = generateCodeFrame;
|
||||
exports.getGlobalThis = getGlobalThis;
|
||||
exports.hasChanged = hasChanged;
|
||||
exports.hasOwn = hasOwn;
|
||||
exports.hyphenate = hyphenate;
|
||||
exports.includeBooleanAttr = includeBooleanAttr;
|
||||
exports.invokeArrayFns = invokeArrayFns;
|
||||
exports.isArray = isArray;
|
||||
exports.isBooleanAttr = isBooleanAttr;
|
||||
exports.isBuiltInDirective = isBuiltInDirective;
|
||||
exports.isDate = isDate;
|
||||
exports.isFunction = isFunction;
|
||||
exports.isGloballyWhitelisted = isGloballyWhitelisted;
|
||||
exports.isHTMLTag = isHTMLTag;
|
||||
exports.isIntegerKey = isIntegerKey;
|
||||
exports.isKnownHtmlAttr = isKnownHtmlAttr;
|
||||
exports.isKnownSvgAttr = isKnownSvgAttr;
|
||||
exports.isMap = isMap;
|
||||
exports.isModelListener = isModelListener;
|
||||
exports.isNoUnitNumericStyleProp = isNoUnitNumericStyleProp;
|
||||
exports.isObject = isObject;
|
||||
exports.isOn = isOn;
|
||||
exports.isPlainObject = isPlainObject;
|
||||
exports.isPromise = isPromise;
|
||||
exports.isReservedProp = isReservedProp;
|
||||
exports.isSSRSafeAttrName = isSSRSafeAttrName;
|
||||
exports.isSVGTag = isSVGTag;
|
||||
exports.isSet = isSet;
|
||||
exports.isSpecialBooleanAttr = isSpecialBooleanAttr;
|
||||
exports.isString = isString;
|
||||
exports.isSymbol = isSymbol;
|
||||
exports.isVoidTag = isVoidTag;
|
||||
exports.looseEqual = looseEqual;
|
||||
exports.looseIndexOf = looseIndexOf;
|
||||
exports.makeMap = makeMap;
|
||||
exports.normalizeClass = normalizeClass;
|
||||
exports.normalizeProps = normalizeProps;
|
||||
exports.normalizeStyle = normalizeStyle;
|
||||
exports.objectToString = objectToString;
|
||||
exports.parseStringStyle = parseStringStyle;
|
||||
exports.propsToAttrMap = propsToAttrMap;
|
||||
exports.remove = remove;
|
||||
exports.slotFlagsText = slotFlagsText;
|
||||
exports.stringifyStyle = stringifyStyle;
|
||||
exports.toDisplayString = toDisplayString;
|
||||
exports.toHandlerKey = toHandlerKey;
|
||||
exports.toNumber = toNumber;
|
||||
exports.toRawType = toRawType;
|
||||
exports.toTypeString = toTypeString;
|
356
webui/node_modules/@vue/shared/dist/shared.d.ts
generated
vendored
Normal file
356
webui/node_modules/@vue/shared/dist/shared.d.ts
generated
vendored
Normal file
|
@ -0,0 +1,356 @@
|
|||
/**
|
||||
* @private
|
||||
*/
|
||||
export declare const camelize: (str: string) => string;
|
||||
|
||||
/**
|
||||
* @private
|
||||
*/
|
||||
export declare const capitalize: (str: string) => string;
|
||||
|
||||
export declare const def: (obj: object, key: string | symbol, value: any) => void;
|
||||
|
||||
export declare const EMPTY_ARR: readonly never[];
|
||||
|
||||
export declare const EMPTY_OBJ: {
|
||||
readonly [key: string]: any;
|
||||
};
|
||||
|
||||
export declare function escapeHtml(string: unknown): string;
|
||||
|
||||
export declare function escapeHtmlComment(src: string): string;
|
||||
|
||||
export declare const extend: {
|
||||
<T, U>(target: T, source: U): T & U;
|
||||
<T_1, U_1, V>(target: T_1, source1: U_1, source2: V): T_1 & U_1 & V;
|
||||
<T_2, U_2, V_1, W>(target: T_2, source1: U_2, source2: V_1, source3: W): T_2 & U_2 & V_1 & W;
|
||||
(target: object, ...sources: any[]): any;
|
||||
};
|
||||
|
||||
export declare function generateCodeFrame(source: string, start?: number, end?: number): string;
|
||||
|
||||
export declare function genPropsAccessExp(name: string): string;
|
||||
|
||||
export declare const getGlobalThis: () => any;
|
||||
|
||||
export declare const hasChanged: (value: any, oldValue: any) => boolean;
|
||||
|
||||
export declare const hasOwn: (val: object, key: string | symbol) => key is never;
|
||||
|
||||
/**
|
||||
* @private
|
||||
*/
|
||||
export declare const hyphenate: (str: string) => string;
|
||||
|
||||
export declare type IfAny<T, Y, N> = 0 extends 1 & T ? Y : N;
|
||||
|
||||
/**
|
||||
* 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;
|
||||
|
||||
export declare const invokeArrayFns: (fns: Function[], arg?: any) => void;
|
||||
|
||||
export declare const isArray: (arg: any) => arg is any[];
|
||||
|
||||
/**
|
||||
* The full list is needed during SSR to produce the correct initial markup.
|
||||
*/
|
||||
export declare const isBooleanAttr: (key: string) => boolean;
|
||||
|
||||
export declare const isBuiltInDirective: (key: string) => boolean;
|
||||
|
||||
export declare const isDate: (val: unknown) => val is Date;
|
||||
|
||||
export declare const isFunction: (val: unknown) => val is Function;
|
||||
|
||||
export declare const isGloballyWhitelisted: (key: string) => boolean;
|
||||
|
||||
/**
|
||||
* Compiler only.
|
||||
* Do NOT use in runtime code paths unless behind `__DEV__` flag.
|
||||
*/
|
||||
export declare const isHTMLTag: (key: string) => boolean;
|
||||
|
||||
export declare const isIntegerKey: (key: unknown) => 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
|
||||
*/
|
||||
export declare const isKnownHtmlAttr: (key: string) => boolean;
|
||||
|
||||
/**
|
||||
* Generated from https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute
|
||||
*/
|
||||
export declare const isKnownSvgAttr: (key: string) => boolean;
|
||||
|
||||
export declare const isMap: (val: unknown) => val is Map<any, any>;
|
||||
|
||||
export declare const isModelListener: (key: string) => boolean;
|
||||
|
||||
/**
|
||||
* CSS properties that accept plain numbers
|
||||
*/
|
||||
export declare const isNoUnitNumericStyleProp: (key: string) => boolean;
|
||||
|
||||
export declare const isObject: (val: unknown) => val is Record<any, any>;
|
||||
|
||||
export declare const isOn: (key: string) => boolean;
|
||||
|
||||
export declare const isPlainObject: (val: unknown) => val is object;
|
||||
|
||||
export declare const isPromise: <T = any>(val: unknown) => val is Promise<T>;
|
||||
|
||||
export declare const isReservedProp: (key: string) => boolean;
|
||||
|
||||
export declare const isSet: (val: unknown) => val is Set<any>;
|
||||
|
||||
export declare const isSpecialBooleanAttr: (key: string) => boolean;
|
||||
|
||||
export declare function isSSRSafeAttrName(name: string): boolean;
|
||||
|
||||
export declare const isString: (val: unknown) => val is string;
|
||||
|
||||
/**
|
||||
* Compiler only.
|
||||
* Do NOT use in runtime code paths unless behind `__DEV__` flag.
|
||||
*/
|
||||
export declare const isSVGTag: (key: string) => boolean;
|
||||
|
||||
export declare const isSymbol: (val: unknown) => val is symbol;
|
||||
|
||||
/**
|
||||
* Compiler only.
|
||||
* Do NOT use in runtime code paths unless behind `__DEV__` flag.
|
||||
*/
|
||||
export declare const isVoidTag: (key: string) => boolean;
|
||||
|
||||
export declare function looseEqual(a: any, b: any): boolean;
|
||||
|
||||
export declare function looseIndexOf(arr: any[], val: any): number;
|
||||
|
||||
export declare type LooseRequired<T> = {
|
||||
[P in string & keyof T]: T[P];
|
||||
};
|
||||
|
||||
/**
|
||||
* 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 rollup can tree-shake them if necessary.
|
||||
*/
|
||||
export declare function makeMap(str: string, expectsLowerCase?: boolean): (key: string) => boolean;
|
||||
|
||||
/**
|
||||
* Always return false.
|
||||
*/
|
||||
export declare const NO: () => boolean;
|
||||
|
||||
export declare const NOOP: () => void;
|
||||
|
||||
export declare function normalizeClass(value: unknown): string;
|
||||
|
||||
export declare type NormalizedStyle = Record<string, string | number>;
|
||||
|
||||
export declare function normalizeProps(props: Record<string, any> | null): Record<string, any> | null;
|
||||
|
||||
export declare function normalizeStyle(value: unknown): NormalizedStyle | string | undefined;
|
||||
|
||||
export declare const objectToString: () => string;
|
||||
|
||||
export declare function parseStringStyle(cssText: string): NormalizedStyle;
|
||||
|
||||
/**
|
||||
* dev only flag -> name mapping
|
||||
*/
|
||||
export declare const PatchFlagNames: {
|
||||
[x: number]: string;
|
||||
};
|
||||
|
||||
/**
|
||||
* 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 const enum PatchFlags {
|
||||
/**
|
||||
* Indicates an element with dynamic textContent (children fast path)
|
||||
*/
|
||||
TEXT = 1,
|
||||
/**
|
||||
* 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 }) }
|
||||
* ```
|
||||
*/
|
||||
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)
|
||||
*/
|
||||
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.
|
||||
*/
|
||||
FULL_PROPS = 16,
|
||||
/**
|
||||
* Indicates an element with event listeners (which need to be attached
|
||||
* during hydration)
|
||||
*/
|
||||
HYDRATE_EVENTS = 32,
|
||||
/**
|
||||
* Indicates a fragment whose children order doesn't change.
|
||||
*/
|
||||
STABLE_FRAGMENT = 64,
|
||||
/**
|
||||
* Indicates a fragment with keyed or partially keyed children
|
||||
*/
|
||||
KEYED_FRAGMENT = 128,
|
||||
/**
|
||||
* 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.
|
||||
*/
|
||||
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.
|
||||
*/
|
||||
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.
|
||||
*/
|
||||
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.
|
||||
*/
|
||||
/**
|
||||
* Indicates a hoisted static vnode. This is a hint for hydration to skip
|
||||
* the entire sub tree since static content never needs to be updated.
|
||||
*/
|
||||
HOISTED = -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
|
||||
*/
|
||||
BAIL = -2
|
||||
}
|
||||
|
||||
export declare const propsToAttrMap: Record<string, string | undefined>;
|
||||
|
||||
export declare const remove: <T>(arr: T[], el: T) => void;
|
||||
|
||||
export declare const enum ShapeFlags {
|
||||
ELEMENT = 1,
|
||||
FUNCTIONAL_COMPONENT = 2,
|
||||
STATEFUL_COMPONENT = 4,
|
||||
TEXT_CHILDREN = 8,
|
||||
ARRAY_CHILDREN = 16,
|
||||
SLOTS_CHILDREN = 32,
|
||||
TELEPORT = 64,
|
||||
SUSPENSE = 128,
|
||||
COMPONENT_SHOULD_KEEP_ALIVE = 256,
|
||||
COMPONENT_KEPT_ALIVE = 512,
|
||||
COMPONENT = 6
|
||||
}
|
||||
|
||||
export declare const enum SlotFlags {
|
||||
/**
|
||||
* 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.
|
||||
*/
|
||||
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`)
|
||||
*/
|
||||
FORWARDED = 3
|
||||
}
|
||||
|
||||
/**
|
||||
* Dev only
|
||||
*/
|
||||
export declare const slotFlagsText: {
|
||||
1: string;
|
||||
2: string;
|
||||
3: string;
|
||||
};
|
||||
|
||||
export declare function stringifyStyle(styles: NormalizedStyle | string | undefined): string;
|
||||
|
||||
/**
|
||||
* For converting {{ interpolation }} values to displayed strings.
|
||||
* @private
|
||||
*/
|
||||
export declare const toDisplayString: (val: unknown) => string;
|
||||
|
||||
/**
|
||||
* @private
|
||||
*/
|
||||
export declare const toHandlerKey: (str: string) => string;
|
||||
|
||||
export declare const toNumber: (val: any) => any;
|
||||
|
||||
export declare const toRawType: (value: unknown) => string;
|
||||
|
||||
export declare const toTypeString: (value: unknown) => string;
|
||||
|
||||
export declare type UnionToIntersection<U> = (U extends any ? (k: U) => void : never) extends (k: infer I) => void ? I : never;
|
||||
|
||||
export { }
|
596
webui/node_modules/@vue/shared/dist/shared.esm-bundler.js
generated
vendored
Normal file
596
webui/node_modules/@vue/shared/dist/shared.esm-bundler.js
generated
vendored
Normal file
|
@ -0,0 +1,596 @@
|
|||
/**
|
||||
* 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 rollup can tree-shake them if necessary.
|
||||
*/
|
||||
function makeMap(str, expectsLowerCase) {
|
||||
const map = Object.create(null);
|
||||
const list = str.split(',');
|
||||
for (let i = 0; i < list.length; i++) {
|
||||
map[list[i]] = true;
|
||||
}
|
||||
return expectsLowerCase ? val => !!map[val.toLowerCase()] : val => !!map[val];
|
||||
}
|
||||
|
||||
/**
|
||||
* dev only flag -> name mapping
|
||||
*/
|
||||
const PatchFlagNames = {
|
||||
[1 /* TEXT */]: `TEXT`,
|
||||
[2 /* CLASS */]: `CLASS`,
|
||||
[4 /* STYLE */]: `STYLE`,
|
||||
[8 /* PROPS */]: `PROPS`,
|
||||
[16 /* FULL_PROPS */]: `FULL_PROPS`,
|
||||
[32 /* HYDRATE_EVENTS */]: `HYDRATE_EVENTS`,
|
||||
[64 /* STABLE_FRAGMENT */]: `STABLE_FRAGMENT`,
|
||||
[128 /* KEYED_FRAGMENT */]: `KEYED_FRAGMENT`,
|
||||
[256 /* UNKEYED_FRAGMENT */]: `UNKEYED_FRAGMENT`,
|
||||
[512 /* NEED_PATCH */]: `NEED_PATCH`,
|
||||
[1024 /* DYNAMIC_SLOTS */]: `DYNAMIC_SLOTS`,
|
||||
[2048 /* DEV_ROOT_FRAGMENT */]: `DEV_ROOT_FRAGMENT`,
|
||||
[-1 /* HOISTED */]: `HOISTED`,
|
||||
[-2 /* BAIL */]: `BAIL`
|
||||
};
|
||||
|
||||
/**
|
||||
* Dev only
|
||||
*/
|
||||
const slotFlagsText = {
|
||||
[1 /* STABLE */]: 'STABLE',
|
||||
[2 /* DYNAMIC */]: 'DYNAMIC',
|
||||
[3 /* FORWARDED */]: 'FORWARDED'
|
||||
};
|
||||
|
||||
const GLOBALS_WHITE_LISTED = 'Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,' +
|
||||
'decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,' +
|
||||
'Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt';
|
||||
const isGloballyWhitelisted = /*#__PURE__*/ makeMap(GLOBALS_WHITE_LISTED);
|
||||
|
||||
const range = 2;
|
||||
function generateCodeFrame(source, start = 0, end = source.length) {
|
||||
// Split the content into individual lines but capture the newline sequence
|
||||
// that separated each line. This is important because the actual sequence is
|
||||
// needed to properly take into account the full line length for offset
|
||||
// comparison
|
||||
let lines = source.split(/(\r?\n)/);
|
||||
// Separate the lines and newline sequences into separate arrays for easier referencing
|
||||
const newlineSequences = lines.filter((_, idx) => idx % 2 === 1);
|
||||
lines = lines.filter((_, idx) => idx % 2 === 0);
|
||||
let count = 0;
|
||||
const res = [];
|
||||
for (let i = 0; i < lines.length; i++) {
|
||||
count +=
|
||||
lines[i].length +
|
||||
((newlineSequences[i] && newlineSequences[i].length) || 0);
|
||||
if (count >= start) {
|
||||
for (let j = i - range; j <= i + range || end > count; j++) {
|
||||
if (j < 0 || j >= lines.length)
|
||||
continue;
|
||||
const line = j + 1;
|
||||
res.push(`${line}${' '.repeat(Math.max(3 - String(line).length, 0))}| ${lines[j]}`);
|
||||
const lineLength = lines[j].length;
|
||||
const newLineSeqLength = (newlineSequences[j] && newlineSequences[j].length) || 0;
|
||||
if (j === i) {
|
||||
// push underline
|
||||
const pad = start - (count - (lineLength + newLineSeqLength));
|
||||
const length = Math.max(1, end > count ? lineLength - pad : end - start);
|
||||
res.push(` | ` + ' '.repeat(pad) + '^'.repeat(length));
|
||||
}
|
||||
else if (j > i) {
|
||||
if (end > count) {
|
||||
const length = Math.max(Math.min(end - count, lineLength), 1);
|
||||
res.push(` | ` + '^'.repeat(length));
|
||||
}
|
||||
count += lineLength + newLineSeqLength;
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
return res.join('\n');
|
||||
}
|
||||
|
||||
/**
|
||||
* On the client we only need to offer special cases for boolean attributes that
|
||||
* have different names from their corresponding dom properties:
|
||||
* - itemscope -> N/A
|
||||
* - allowfullscreen -> allowFullscreen
|
||||
* - formnovalidate -> formNoValidate
|
||||
* - ismap -> isMap
|
||||
* - nomodule -> noModule
|
||||
* - novalidate -> noValidate
|
||||
* - readonly -> readOnly
|
||||
*/
|
||||
const specialBooleanAttrs = `itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly`;
|
||||
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,hidden,` +
|
||||
`loop,open,required,reversed,scoped,seamless,` +
|
||||
`checked,muted,multiple,selected`);
|
||||
/**
|
||||
* Boolean attributes should be included if the value is truthy or ''.
|
||||
* e.g. `<select multiple>` compiles to `{ multiple: '' }`
|
||||
*/
|
||||
function includeBooleanAttr(value) {
|
||||
return !!value || value === '';
|
||||
}
|
||||
const unsafeAttrCharRE = /[>/="'\u0009\u000a\u000c\u0020]/;
|
||||
const attrValidationCache = {};
|
||||
function isSSRSafeAttrName(name) {
|
||||
if (attrValidationCache.hasOwnProperty(name)) {
|
||||
return attrValidationCache[name];
|
||||
}
|
||||
const isUnsafe = unsafeAttrCharRE.test(name);
|
||||
if (isUnsafe) {
|
||||
console.error(`unsafe attribute name: ${name}`);
|
||||
}
|
||||
return (attrValidationCache[name] = !isUnsafe);
|
||||
}
|
||||
const propsToAttrMap = {
|
||||
acceptCharset: 'accept-charset',
|
||||
className: 'class',
|
||||
htmlFor: 'for',
|
||||
httpEquiv: 'http-equiv'
|
||||
};
|
||||
/**
|
||||
* CSS properties that accept plain numbers
|
||||
*/
|
||||
const isNoUnitNumericStyleProp = /*#__PURE__*/ makeMap(`animation-iteration-count,border-image-outset,border-image-slice,` +
|
||||
`border-image-width,box-flex,box-flex-group,box-ordinal-group,column-count,` +
|
||||
`columns,flex,flex-grow,flex-positive,flex-shrink,flex-negative,flex-order,` +
|
||||
`grid-row,grid-row-end,grid-row-span,grid-row-start,grid-column,` +
|
||||
`grid-column-end,grid-column-span,grid-column-start,font-weight,line-clamp,` +
|
||||
`line-height,opacity,order,orphans,tab-size,widows,z-index,zoom,` +
|
||||
// SVG
|
||||
`fill-opacity,flood-opacity,stop-opacity,stroke-dasharray,stroke-dashoffset,` +
|
||||
`stroke-miterlimit,stroke-opacity,stroke-width`);
|
||||
/**
|
||||
* 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
|
||||
*/
|
||||
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,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,xml:base,xml:lang,` +
|
||||
`xml:space,y,y1,y2,yChannelSelector,z,zoomAndPan`);
|
||||
|
||||
function normalizeStyle(value) {
|
||||
if (isArray(value)) {
|
||||
const res = {};
|
||||
for (let i = 0; i < value.length; i++) {
|
||||
const item = value[i];
|
||||
const normalized = isString(item)
|
||||
? parseStringStyle(item)
|
||||
: normalizeStyle(item);
|
||||
if (normalized) {
|
||||
for (const key in normalized) {
|
||||
res[key] = normalized[key];
|
||||
}
|
||||
}
|
||||
}
|
||||
return res;
|
||||
}
|
||||
else if (isString(value)) {
|
||||
return value;
|
||||
}
|
||||
else if (isObject(value)) {
|
||||
return value;
|
||||
}
|
||||
}
|
||||
const listDelimiterRE = /;(?![^(]*\))/g;
|
||||
const propertyDelimiterRE = /:(.+)/;
|
||||
function parseStringStyle(cssText) {
|
||||
const ret = {};
|
||||
cssText.split(listDelimiterRE).forEach(item => {
|
||||
if (item) {
|
||||
const tmp = item.split(propertyDelimiterRE);
|
||||
tmp.length > 1 && (ret[tmp[0].trim()] = tmp[1].trim());
|
||||
}
|
||||
});
|
||||
return ret;
|
||||
}
|
||||
function stringifyStyle(styles) {
|
||||
let ret = '';
|
||||
if (!styles || isString(styles)) {
|
||||
return ret;
|
||||
}
|
||||
for (const key in styles) {
|
||||
const value = styles[key];
|
||||
const normalizedKey = key.startsWith(`--`) ? key : hyphenate(key);
|
||||
if (isString(value) ||
|
||||
(typeof value === 'number' && isNoUnitNumericStyleProp(normalizedKey))) {
|
||||
// only render valid values
|
||||
ret += `${normalizedKey}:${value};`;
|
||||
}
|
||||
}
|
||||
return ret;
|
||||
}
|
||||
function normalizeClass(value) {
|
||||
let res = '';
|
||||
if (isString(value)) {
|
||||
res = value;
|
||||
}
|
||||
else if (isArray(value)) {
|
||||
for (let i = 0; i < value.length; i++) {
|
||||
const normalized = normalizeClass(value[i]);
|
||||
if (normalized) {
|
||||
res += normalized + ' ';
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (isObject(value)) {
|
||||
for (const name in value) {
|
||||
if (value[name]) {
|
||||
res += name + ' ';
|
||||
}
|
||||
}
|
||||
}
|
||||
return res.trim();
|
||||
}
|
||||
function normalizeProps(props) {
|
||||
if (!props)
|
||||
return null;
|
||||
let { class: klass, style } = props;
|
||||
if (klass && !isString(klass)) {
|
||||
props.class = normalizeClass(klass);
|
||||
}
|
||||
if (style) {
|
||||
props.style = normalizeStyle(style);
|
||||
}
|
||||
return props;
|
||||
}
|
||||
|
||||
// These tag configs are shared between compiler-dom and runtime-dom, so they
|
||||
// https://developer.mozilla.org/en-US/docs/Web/HTML/Element
|
||||
const HTML_TAGS = 'html,body,base,head,link,meta,style,title,address,article,aside,footer,' +
|
||||
'header,h1,h2,h3,h4,h5,h6,nav,section,div,dd,dl,dt,figcaption,' +
|
||||
'figure,picture,hr,img,li,main,ol,p,pre,ul,a,b,abbr,bdi,bdo,br,cite,code,' +
|
||||
'data,dfn,em,i,kbd,mark,q,rp,rt,ruby,s,samp,small,span,strong,sub,sup,' +
|
||||
'time,u,var,wbr,area,audio,map,track,video,embed,object,param,source,' +
|
||||
'canvas,script,noscript,del,ins,caption,col,colgroup,table,thead,tbody,td,' +
|
||||
'th,tr,button,datalist,fieldset,form,input,label,legend,meter,optgroup,' +
|
||||
'option,output,progress,select,textarea,details,dialog,menu,' +
|
||||
'summary,template,blockquote,iframe,tfoot';
|
||||
// https://developer.mozilla.org/en-US/docs/Web/SVG/Element
|
||||
const SVG_TAGS = 'svg,animate,animateMotion,animateTransform,circle,clipPath,color-profile,' +
|
||||
'defs,desc,discard,ellipse,feBlend,feColorMatrix,feComponentTransfer,' +
|
||||
'feComposite,feConvolveMatrix,feDiffuseLighting,feDisplacementMap,' +
|
||||
'feDistanceLight,feDropShadow,feFlood,feFuncA,feFuncB,feFuncG,feFuncR,' +
|
||||
'feGaussianBlur,feImage,feMerge,feMergeNode,feMorphology,feOffset,' +
|
||||
'fePointLight,feSpecularLighting,feSpotLight,feTile,feTurbulence,filter,' +
|
||||
'foreignObject,g,hatch,hatchpath,image,line,linearGradient,marker,mask,' +
|
||||
'mesh,meshgradient,meshpatch,meshrow,metadata,mpath,path,pattern,' +
|
||||
'polygon,polyline,radialGradient,rect,set,solidcolor,stop,switch,symbol,' +
|
||||
'text,textPath,title,tspan,unknown,use,view';
|
||||
const VOID_TAGS = 'area,base,br,col,embed,hr,img,input,link,meta,param,source,track,wbr';
|
||||
/**
|
||||
* Compiler only.
|
||||
* Do NOT use in runtime code paths unless behind `(process.env.NODE_ENV !== 'production')` flag.
|
||||
*/
|
||||
const isHTMLTag = /*#__PURE__*/ makeMap(HTML_TAGS);
|
||||
/**
|
||||
* Compiler only.
|
||||
* Do NOT use in runtime code paths unless behind `(process.env.NODE_ENV !== 'production')` flag.
|
||||
*/
|
||||
const isSVGTag = /*#__PURE__*/ makeMap(SVG_TAGS);
|
||||
/**
|
||||
* Compiler only.
|
||||
* Do NOT use in runtime code paths unless behind `(process.env.NODE_ENV !== 'production')` flag.
|
||||
*/
|
||||
const isVoidTag = /*#__PURE__*/ makeMap(VOID_TAGS);
|
||||
|
||||
const escapeRE = /["'&<>]/;
|
||||
function escapeHtml(string) {
|
||||
const str = '' + string;
|
||||
const match = escapeRE.exec(str);
|
||||
if (!match) {
|
||||
return str;
|
||||
}
|
||||
let html = '';
|
||||
let escaped;
|
||||
let index;
|
||||
let lastIndex = 0;
|
||||
for (index = match.index; index < str.length; index++) {
|
||||
switch (str.charCodeAt(index)) {
|
||||
case 34: // "
|
||||
escaped = '"';
|
||||
break;
|
||||
case 38: // &
|
||||
escaped = '&';
|
||||
break;
|
||||
case 39: // '
|
||||
escaped = ''';
|
||||
break;
|
||||
case 60: // <
|
||||
escaped = '<';
|
||||
break;
|
||||
case 62: // >
|
||||
escaped = '>';
|
||||
break;
|
||||
default:
|
||||
continue;
|
||||
}
|
||||
if (lastIndex !== index) {
|
||||
html += str.slice(lastIndex, index);
|
||||
}
|
||||
lastIndex = index + 1;
|
||||
html += escaped;
|
||||
}
|
||||
return lastIndex !== index ? html + str.slice(lastIndex, index) : html;
|
||||
}
|
||||
// https://www.w3.org/TR/html52/syntax.html#comments
|
||||
const commentStripRE = /^-?>|<!--|-->|--!>|<!-$/g;
|
||||
function escapeHtmlComment(src) {
|
||||
return src.replace(commentStripRE, '');
|
||||
}
|
||||
|
||||
function looseCompareArrays(a, b) {
|
||||
if (a.length !== b.length)
|
||||
return false;
|
||||
let equal = true;
|
||||
for (let i = 0; equal && i < a.length; i++) {
|
||||
equal = looseEqual(a[i], b[i]);
|
||||
}
|
||||
return equal;
|
||||
}
|
||||
function looseEqual(a, b) {
|
||||
if (a === b)
|
||||
return true;
|
||||
let aValidType = isDate(a);
|
||||
let bValidType = isDate(b);
|
||||
if (aValidType || bValidType) {
|
||||
return aValidType && bValidType ? a.getTime() === b.getTime() : false;
|
||||
}
|
||||
aValidType = isSymbol(a);
|
||||
bValidType = isSymbol(b);
|
||||
if (aValidType || bValidType) {
|
||||
return a === b;
|
||||
}
|
||||
aValidType = isArray(a);
|
||||
bValidType = isArray(b);
|
||||
if (aValidType || bValidType) {
|
||||
return aValidType && bValidType ? looseCompareArrays(a, b) : false;
|
||||
}
|
||||
aValidType = isObject(a);
|
||||
bValidType = isObject(b);
|
||||
if (aValidType || bValidType) {
|
||||
/* istanbul ignore if: this if will probably never be called */
|
||||
if (!aValidType || !bValidType) {
|
||||
return false;
|
||||
}
|
||||
const aKeysCount = Object.keys(a).length;
|
||||
const bKeysCount = Object.keys(b).length;
|
||||
if (aKeysCount !== bKeysCount) {
|
||||
return false;
|
||||
}
|
||||
for (const key in a) {
|
||||
const aHasKey = a.hasOwnProperty(key);
|
||||
const bHasKey = b.hasOwnProperty(key);
|
||||
if ((aHasKey && !bHasKey) ||
|
||||
(!aHasKey && bHasKey) ||
|
||||
!looseEqual(a[key], b[key])) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
return String(a) === String(b);
|
||||
}
|
||||
function looseIndexOf(arr, val) {
|
||||
return arr.findIndex(item => looseEqual(item, val));
|
||||
}
|
||||
|
||||
/**
|
||||
* For converting {{ interpolation }} values to displayed strings.
|
||||
* @private
|
||||
*/
|
||||
const toDisplayString = (val) => {
|
||||
return isString(val)
|
||||
? val
|
||||
: val == null
|
||||
? ''
|
||||
: isArray(val) ||
|
||||
(isObject(val) &&
|
||||
(val.toString === objectToString || !isFunction(val.toString)))
|
||||
? JSON.stringify(val, replacer, 2)
|
||||
: String(val);
|
||||
};
|
||||
const replacer = (_key, val) => {
|
||||
// can't use isRef here since @vue/shared has no deps
|
||||
if (val && val.__v_isRef) {
|
||||
return replacer(_key, val.value);
|
||||
}
|
||||
else if (isMap(val)) {
|
||||
return {
|
||||
[`Map(${val.size})`]: [...val.entries()].reduce((entries, [key, val]) => {
|
||||
entries[`${key} =>`] = val;
|
||||
return entries;
|
||||
}, {})
|
||||
};
|
||||
}
|
||||
else if (isSet(val)) {
|
||||
return {
|
||||
[`Set(${val.size})`]: [...val.values()]
|
||||
};
|
||||
}
|
||||
else if (isObject(val) && !isArray(val) && !isPlainObject(val)) {
|
||||
return String(val);
|
||||
}
|
||||
return val;
|
||||
};
|
||||
|
||||
const EMPTY_OBJ = (process.env.NODE_ENV !== 'production')
|
||||
? Object.freeze({})
|
||||
: {};
|
||||
const EMPTY_ARR = (process.env.NODE_ENV !== 'production') ? Object.freeze([]) : [];
|
||||
const NOOP = () => { };
|
||||
/**
|
||||
* Always return false.
|
||||
*/
|
||||
const NO = () => false;
|
||||
const onRE = /^on[^a-z]/;
|
||||
const isOn = (key) => onRE.test(key);
|
||||
const isModelListener = (key) => key.startsWith('onUpdate:');
|
||||
const extend = Object.assign;
|
||||
const remove = (arr, el) => {
|
||||
const i = arr.indexOf(el);
|
||||
if (i > -1) {
|
||||
arr.splice(i, 1);
|
||||
}
|
||||
};
|
||||
const hasOwnProperty = Object.prototype.hasOwnProperty;
|
||||
const hasOwn = (val, key) => hasOwnProperty.call(val, key);
|
||||
const isArray = Array.isArray;
|
||||
const isMap = (val) => toTypeString(val) === '[object Map]';
|
||||
const isSet = (val) => toTypeString(val) === '[object Set]';
|
||||
const isDate = (val) => toTypeString(val) === '[object Date]';
|
||||
const isFunction = (val) => typeof val === 'function';
|
||||
const isString = (val) => typeof val === 'string';
|
||||
const isSymbol = (val) => typeof val === 'symbol';
|
||||
const isObject = (val) => val !== null && typeof val === 'object';
|
||||
const isPromise = (val) => {
|
||||
return isObject(val) && isFunction(val.then) && isFunction(val.catch);
|
||||
};
|
||||
const objectToString = Object.prototype.toString;
|
||||
const toTypeString = (value) => objectToString.call(value);
|
||||
const toRawType = (value) => {
|
||||
// extract "RawType" from strings like "[object RawType]"
|
||||
return toTypeString(value).slice(8, -1);
|
||||
};
|
||||
const isPlainObject = (val) => toTypeString(val) === '[object Object]';
|
||||
const isIntegerKey = (key) => isString(key) &&
|
||||
key !== 'NaN' &&
|
||||
key[0] !== '-' &&
|
||||
'' + parseInt(key, 10) === key;
|
||||
const isReservedProp = /*#__PURE__*/ makeMap(
|
||||
// the leading comma is intentional so empty string "" is also included
|
||||
',key,ref,ref_for,ref_key,' +
|
||||
'onVnodeBeforeMount,onVnodeMounted,' +
|
||||
'onVnodeBeforeUpdate,onVnodeUpdated,' +
|
||||
'onVnodeBeforeUnmount,onVnodeUnmounted');
|
||||
const isBuiltInDirective = /*#__PURE__*/ makeMap('bind,cloak,else-if,else,for,html,if,model,on,once,pre,show,slot,text,memo');
|
||||
const cacheStringFunction = (fn) => {
|
||||
const cache = Object.create(null);
|
||||
return ((str) => {
|
||||
const hit = cache[str];
|
||||
return hit || (cache[str] = fn(str));
|
||||
});
|
||||
};
|
||||
const camelizeRE = /-(\w)/g;
|
||||
/**
|
||||
* @private
|
||||
*/
|
||||
const camelize = cacheStringFunction((str) => {
|
||||
return str.replace(camelizeRE, (_, c) => (c ? c.toUpperCase() : ''));
|
||||
});
|
||||
const hyphenateRE = /\B([A-Z])/g;
|
||||
/**
|
||||
* @private
|
||||
*/
|
||||
const hyphenate = cacheStringFunction((str) => str.replace(hyphenateRE, '-$1').toLowerCase());
|
||||
/**
|
||||
* @private
|
||||
*/
|
||||
const capitalize = cacheStringFunction((str) => str.charAt(0).toUpperCase() + str.slice(1));
|
||||
/**
|
||||
* @private
|
||||
*/
|
||||
const toHandlerKey = cacheStringFunction((str) => str ? `on${capitalize(str)}` : ``);
|
||||
// compare whether a value has changed, accounting for NaN.
|
||||
const hasChanged = (value, oldValue) => !Object.is(value, oldValue);
|
||||
const invokeArrayFns = (fns, arg) => {
|
||||
for (let i = 0; i < fns.length; i++) {
|
||||
fns[i](arg);
|
||||
}
|
||||
};
|
||||
const def = (obj, key, value) => {
|
||||
Object.defineProperty(obj, key, {
|
||||
configurable: true,
|
||||
enumerable: false,
|
||||
value
|
||||
});
|
||||
};
|
||||
const toNumber = (val) => {
|
||||
const n = parseFloat(val);
|
||||
return isNaN(n) ? val : n;
|
||||
};
|
||||
let _globalThis;
|
||||
const getGlobalThis = () => {
|
||||
return (_globalThis ||
|
||||
(_globalThis =
|
||||
typeof globalThis !== 'undefined'
|
||||
? globalThis
|
||||
: typeof self !== 'undefined'
|
||||
? self
|
||||
: typeof window !== 'undefined'
|
||||
? window
|
||||
: typeof global !== 'undefined'
|
||||
? global
|
||||
: {}));
|
||||
};
|
||||
const identRE = /^[_$a-zA-Z\xA0-\uFFFF][_$a-zA-Z0-9\xA0-\uFFFF]*$/;
|
||||
function genPropsAccessExp(name) {
|
||||
return identRE.test(name)
|
||||
? `__props.${name}`
|
||||
: `__props[${JSON.stringify(name)}]`;
|
||||
}
|
||||
|
||||
export { EMPTY_ARR, EMPTY_OBJ, NO, NOOP, PatchFlagNames, camelize, capitalize, def, escapeHtml, escapeHtmlComment, extend, genPropsAccessExp, generateCodeFrame, getGlobalThis, hasChanged, hasOwn, hyphenate, includeBooleanAttr, invokeArrayFns, isArray, isBooleanAttr, isBuiltInDirective, isDate, isFunction, isGloballyWhitelisted, isHTMLTag, isIntegerKey, isKnownHtmlAttr, isKnownSvgAttr, isMap, isModelListener, isNoUnitNumericStyleProp, isObject, isOn, isPlainObject, isPromise, isReservedProp, isSSRSafeAttrName, isSVGTag, isSet, isSpecialBooleanAttr, isString, isSymbol, isVoidTag, looseEqual, looseIndexOf, makeMap, normalizeClass, normalizeProps, normalizeStyle, objectToString, parseStringStyle, propsToAttrMap, remove, slotFlagsText, stringifyStyle, toDisplayString, toHandlerKey, toNumber, toRawType, toTypeString };
|
7
webui/node_modules/@vue/shared/index.js
generated
vendored
Normal file
7
webui/node_modules/@vue/shared/index.js
generated
vendored
Normal file
|
@ -0,0 +1,7 @@
|
|||
'use strict'
|
||||
|
||||
if (process.env.NODE_ENV === 'production') {
|
||||
module.exports = require('./dist/shared.cjs.prod.js')
|
||||
} else {
|
||||
module.exports = require('./dist/shared.cjs.js')
|
||||
}
|
33
webui/node_modules/@vue/shared/package.json
generated
vendored
Normal file
33
webui/node_modules/@vue/shared/package.json
generated
vendored
Normal file
|
@ -0,0 +1,33 @@
|
|||
{
|
||||
"name": "@vue/shared",
|
||||
"version": "3.2.37",
|
||||
"description": "internal utils shared across @vue packages",
|
||||
"main": "index.js",
|
||||
"module": "dist/shared.esm-bundler.js",
|
||||
"types": "dist/shared.d.ts",
|
||||
"files": [
|
||||
"index.js",
|
||||
"dist"
|
||||
],
|
||||
"sideEffects": false,
|
||||
"buildOptions": {
|
||||
"formats": [
|
||||
"esm-bundler",
|
||||
"cjs"
|
||||
]
|
||||
},
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "git+https://github.com/vuejs/core.git",
|
||||
"directory": "packages/shared"
|
||||
},
|
||||
"keywords": [
|
||||
"vue"
|
||||
],
|
||||
"author": "Evan You",
|
||||
"license": "MIT",
|
||||
"bugs": {
|
||||
"url": "https://github.com/vuejs/core/issues"
|
||||
},
|
||||
"homepage": "https://github.com/vuejs/core/tree/main/packages/shared#readme"
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue