2024-09-08 19:53:57 +08:00
const _ _vite _ _mapDeps = ( i , m = _ _vite _ _mapDeps , d = ( m . f || ( m . f = [ "assets/dagre-C4YA43F3-tz6zXTh4.js" , "assets/graph-BdpSt010.js" , "assets/_baseUniq-B2vm31Ph.js" , "assets/layout-BcGWxNGH.js" , "assets/min-obROkMQB.js" , "assets/json-CQcASCg8.js" , "assets/c4Diagram-THADGKDP-B4rOl2cA.js" , "assets/chunk-XVOYOM2C-Dt7ZJZwW.js" , "assets/flowDiagram-44NOAMKU-D41kA-5y.js" , "assets/chunk-WZBIATSK-DQKPowhU.js" , "assets/chunk-GWHMDDHB-Dvf1EDQf.js" , "assets/channel-Jt8wCr3m.js" , "assets/erDiagram-62CBQV5Y-CeccdTYs.js" , "assets/gitGraphDiagram-UL5UFKDR-e-_8y1Lt.js" , "assets/chunk-OQCM5LHU-C1R1WiFi.js" , "assets/chunk-2RYQ3QTB-Bq6pkclg.js" , "assets/gitGraph-YCYPL57B-CmgSlrg5.js" , "assets/ganttDiagram-ASEIQ4P5-DYAqxy6e.js" , "assets/linear-DvsSTNWK.js" , "assets/init-Gi6I4Gst.js" , "assets/infoDiagram-YGJTP6AA-SChjgQPY.js" , "assets/pieDiagram-OZX6XH5M-COoqIcNF.js" , "assets/arc-CkASfIhv.js" , "assets/ordinal-Cboi1Yqb.js" , "assets/quadrantDiagram-VG34DGKC-BQJtqHoI.js" , "assets/xychartDiagram-TMT7NLBN-D9U2v3C1.js" , "assets/requirementDiagram-FPZB6IJI-lHDtYSLa.js" , "assets/sequenceDiagram-K7U7U2PU-CKNqAT0r.js" , "assets/classDiagram-4BHYIK4I-0AOySSOq.js" , "assets/chunk-BAVOGKFW-BL0UonxV.js" , "assets/classDiagram-v2-SPY6V32O-DUHxjUMl.js" , "assets/chunk-MKAIFKW5-D_6tPnBM.js" , "assets/stateDiagram-WG76EWPK-BDBFTIva.js" , "assets/chunk-NQF7MJAO-C2I99caH.js" , "assets/stateDiagram-v2-KR4XTQLW-CUT8_I48.js" , "assets/journeyDiagram-G5LC7W2K-BAvlOLAE.js" , "assets/timeline-definition-KYQAIZUX-jU0RJtT_.js" , "assets/mindmap-definition-26FWEE7H-LcVQPGrF.js" , "assets/cytoscape.esm-DA5nCczq.js" , "assets/sankeyDiagram-KMMQDL5K-32NcbkUq.js" , "assets/diagram-QS5GVLUX-BBO2fQtF.js" , "assets/blockDiagram-SLEYNUNN-ByCniSCG.js" , "assets/architectureDiagram-WQGLKCSC-B7ABiJq3.js" ] ) ) ) => i . map ( i => d [ i ] ) ;
2024-09-08 17:22:36 +08:00
var mA = Object . defineProperty ; var aS = Ra => { throw TypeError ( Ra ) } ; var _A = ( Ra , qa , Ja ) => qa in Ra ? mA ( Ra , qa , { enumerable : ! 0 , configurable : ! 0 , writable : ! 0 , value : Ja } ) : Ra [ qa ] = Ja ; var n _ = ( Ra , qa , Ja ) => _A ( Ra , typeof qa != "symbol" ? qa + "" : qa , Ja ) , gA = ( Ra , qa , Ja ) => qa . has ( Ra ) || aS ( "Cannot " + Ja ) ; var sS = ( Ra , qa , Ja ) => qa . has ( Ra ) ? aS ( "Cannot add the same private member more than once" ) : qa instanceof WeakSet ? qa . add ( Ra ) : qa . set ( Ra , Ja ) ; var NE = ( Ra , qa , Ja ) => ( gA ( Ra , qa , "access private method" ) , Ja ) ; ( function ( ) { const qa = document . createElement ( "link" ) . relList ; if ( qa && qa . supports && qa . supports ( "modulepreload" ) ) return ; for ( const td of document . querySelectorAll ( 'link[rel="modulepreload"]' ) ) ed ( td ) ; new MutationObserver ( td => { for ( const rd of td ) if ( rd . type === "childList" ) for ( const sd of rd . addedNodes ) sd . tagName === "LINK" && sd . rel === "modulepreload" && ed ( sd ) } ) . observe ( document , { childList : ! 0 , subtree : ! 0 } ) ; function Ja ( td ) { const rd = { } ; return td . integrity && ( rd . integrity = td . integrity ) , td . referrerPolicy && ( rd . referrerPolicy = td . referrerPolicy ) , td . crossOrigin === "use-credentials" ? rd . credentials = "include" : td . crossOrigin === "anonymous" ? rd . credentials = "omit" : rd . credentials = "same-origin" , rd } function ed ( td ) { if ( td . ep ) return ; td . ep = ! 0 ; const rd = Ja ( td ) ; fetch ( td . href , rd ) } } ) ( ) ; const global$1 = globalThis || void 0 || self ; / * *
2024-09-07 10:27:05 +08:00
* @ vue / shared v3 . 5.3
2024-08-27 22:31:52 +08:00
* ( c ) 2018 - present Yuxi ( Evan ) You and Vue contributors
* @ license MIT
2024-09-08 17:22:36 +08:00
* * //*! #__NO_SIDE_EFFECTS__ */function makeMap(Ra,qa){const Ja=new Set(Ra.split(","));return ed=>Ja.has(ed)}const EMPTY_OBJ={},EMPTY_ARR=[],NOOP=()=>{},NO=()=>!1,isOn=Ra=>Ra.charCodeAt(0)===111&&Ra.charCodeAt(1)===110&&(Ra.charCodeAt(2)>122||Ra.charCodeAt(2)<97),isModelListener=Ra=>Ra.startsWith("onUpdate:"),extend$3=Object.assign,remove$1=(Ra,qa)=>{const Ja=Ra.indexOf(qa);Ja>-1&&Ra.splice(Ja,1)},hasOwnProperty$i=Object.prototype.hasOwnProperty,hasOwn$1=(Ra,qa)=>hasOwnProperty$i.call(Ra,qa),isArray$2=Array.isArray,isMap$1=Ra=>toTypeString(Ra)==="[object Map]",isSet$1=Ra=>toTypeString(Ra)==="[object Set]",isDate$1=Ra=>toTypeString(Ra)==="[object Date]",isFunction$4=Ra=>typeof Ra=="function",isString$3=Ra=>typeof Ra=="string",isSymbol$1=Ra=>typeof Ra=="symbol",isObject$5=Ra=>Ra!==null&&typeof Ra=="object",isPromise=Ra=>(isObject$5(Ra)||isFunction$4(Ra))&&isFunction$4(Ra.then)&&isFunction$4(Ra.catch),objectToString$1=Object.prototype.toString,toTypeString=Ra=>objectToString$1.call(Ra),toRawType=Ra=>toTypeString(Ra).slice(8,-1),isPlainObject$3=Ra=>toTypeString(Ra)==="[object Object]",isIntegerKey=Ra=>isString$3(Ra)&&Ra!=="NaN"&&Ra[0]!=="-"&&""+parseInt(Ra,10)===Ra,isReservedProp=makeMap(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),cacheStringFunction=Ra=>{const qa=Object.create(null);return Ja=>qa[Ja]||(qa[Ja]=Ra(Ja))},camelizeRE=/-(\w)/g,camelize=cacheStringFunction(Ra=>Ra.replace(camelizeRE,(qa,Ja)=>Ja?Ja.toUpperCase():"")),hyphenateRE=/\B([A-Z])/g,hyphenate=cacheStringFunction(Ra=>Ra.replace(hyphenateRE,"-$1").toLowerCase()),capitalize$1=cacheStringFunction(Ra=>Ra.charAt(0).toUpperCase()+Ra.slice(1)),toHandlerKey=cacheStringFunction(Ra=>Ra?`on${capitalize$1(Ra)}`:""),hasChanged=(Ra,qa)=>!Object.is(Ra,qa),invokeArrayFns=(Ra,...qa)=>{for(let Ja=0;Ja<Ra.length;Ja++)Ra[Ja](...qa)},def$2=(Ra,qa,Ja,ed=!1)=>{Object.defineProperty(Ra,qa,{configurable:!0,enumerable:!1,writable:ed,value:Ja})},looseToNumber=Ra=>{const qa=parseFloat(Ra);return isNaN(qa)?Ra:qa},toNumber$3=Ra=>{const qa=isString$3(Ra)?Number(Ra):NaN;return isNaN(qa)?Ra:qa};let _globalThis;const getGlobalThis=()=>_globalThis||(_globalThis=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global$1<"u"?global$1:{});function normalizeStyle(Ra){if(isArray$2(Ra)){const qa={};for(let Ja=0;Ja<Ra.length;Ja++){const ed=Ra[Ja],td=isString$3(ed)?parseStringStyle(ed):normalizeStyle(ed);if(td)for(const rd in td)qa[rd]=td[rd]}return qa}else if(isString$3(Ra)||isObject$5(Ra))return Ra}const listDelimiterRE=/;(?![^(]*\))/g,propertyDelimiterRE=/:([^]+)/,styleCommentRE=/\/\*[^]*?\*\//g;function parseStringStyle(Ra){const qa={};return Ra.replace(styleCommentRE,"").split(listDelimiterRE).forEach(Ja=>{if(Ja){const ed=Ja.split(propertyDelimiterRE);ed.length>1&&(qa[ed[0].trim()]=ed[1].trim())}}),qa}function normalizeClass(Ra){let qa="";if(isString$3(Ra))qa=Ra;else if(isArray$2(Ra))for(let Ja=0;Ja<Ra.length;Ja++){const ed=normalizeClass(Ra[Ja]);ed&&(qa+=ed+" ")}else if(isObject$5(Ra))for(const Ja in Ra)Ra[Ja]&&(qa+=Ja+" ");return qa.trim()}function normalizeProps(Ra){if(!Ra)return null;let{class:qa,style:Ja}=Ra;return qa&&!isString$3(qa)&&(Ra.class=normalizeClass(qa)),Ja&&(Ra.style=normalizeStyle(Ja)),Ra}const specialBooleanAttrs="itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly",isSpecialBooleanAttr=makeMap(specialBooleanAttrs);function includeBooleanAttr(Ra){return!!Ra||Ra===""}function looseCompareArrays(Ra,qa){if(Ra.length!==qa.length)return!1;let Ja=!0;for(let ed=0;Ja&&ed<Ra.length;ed++)Ja=looseEqual(Ra[ed],qa[ed]);return Ja}function looseEqual(Ra,qa){if(Ra===qa)return!0;let Ja=isDate$1(Ra),ed=isDate$1(qa);if(Ja||ed)return Ja&&ed?Ra.getTime()===qa.getTime():!1;if(Ja=isSymbol$1(Ra),ed=isSymbol$1(qa),Ja||ed)return Ra===qa;if(Ja=isArray$2(Ra),ed=isArray$2(qa),Ja||ed)return Ja&&ed?looseCompareArrays(Ra,qa):!1;if(Ja=isObject$5(Ra),ed=isObject$5(qa),Ja||ed){if(!Ja||!ed)return!1;const td=Object.keys(Ra).length,rd=Object.keys(qa).length;if(td!==
2024-09-07 10:27:05 +08:00
* @ vue / reactivity v3 . 5.3
2024-08-27 22:31:52 +08:00
* ( c ) 2018 - present Yuxi ( Evan ) You and Vue contributors
* @ license MIT
2024-09-08 17:22:36 +08:00
* * / l e t a c t i v e E f f e c t S c o p e ; c l a s s E f f e c t S c o p e { c o n s t r u c t o r ( q a = ! 1 ) { t h i s . d e t a c h e d = q a , t h i s . _ a c t i v e = ! 0 , t h i s . e f f e c t s = [ ] , t h i s . c l e a n u p s = [ ] , t h i s . _ i s P a u s e d = ! 1 , t h i s . p a r e n t = a c t i v e E f f e c t S c o p e , ! q a & & a c t i v e E f f e c t S c o p e & & ( t h i s . i n d e x = ( a c t i v e E f f e c t S c o p e . s c o p e s | | ( a c t i v e E f f e c t S c o p e . s c o p e s = [ ] ) ) . p u s h ( t h i s ) - 1 ) } g e t a c t i v e ( ) { r e t u r n t h i s . _ a c t i v e } p a u s e ( ) { i f ( t h i s . _ a c t i v e ) { t h i s . _ i s P a u s e d = ! 0 ; l e t q a , J a ; i f ( t h i s . s c o p e s ) f o r ( q a = 0 , J a = t h i s . s c o p e s . l e n g t h ; q a < J a ; q a + + ) t h i s . s c o p e s [ q a ] . p a u s e ( ) ; f o r ( q a = 0 , J a = t h i s . e f f e c t s . l e n g t h ; q a < J a ; q a + + ) t h i s . e f f e c t s [ q a ] . p a u s e ( ) } } r e s u m e ( ) { i f ( t h i s . _ a c t i v e & & t h i s . _ i s P a u s e d ) { t h i s . _ i s P a u s e d = ! 1 ; l e t q a , J a ; i f ( t h i s . s c o p e s ) f o r ( q a = 0 , J a = t h i s . s c o p e s . l e n g t h ; q a < J a ; q a + + ) t h i s . s c o p e s [ q a ] . r e s u m e ( ) ; f o r ( q a = 0 , J a = t h i s . e f f e c t s . l e n g t h ; q a < J a ; q a + + ) t h i s . e f f e c t s [ q a ] . r e s u m e ( ) } } r u n ( q a ) { i f ( t h i s . _ a c t i v e ) { c o n s t J a = a c t i v e E f f e c t S c o p e ; t r y { r e t u r n a c t i v e E f f e c t S c o p e = t h i s , q a ( ) } f i n a l l y { a c t i v e E f f e c t S c o p e = J a } } } o n ( ) { a c t i v e E f f e c t S c o p e = t h i s } o f f ( ) { a c t i v e E f f e c t S c o p e = t h i s . p a r e n t } s t o p ( q a ) { i f ( t h i s . _ a c t i v e ) { l e t J a , e d ; f o r ( J a = 0 , e d = t h i s . e f f e c t s . l e n g t h ; J a < e d ; J a + + ) t h i s . e f f e c t s [ J a ] . s t o p ( ) ; f o r ( J a = 0 , e d = t h i s . c l e a n u p s . l e n g t h ; J a < e d ; J a + + ) t h i s . c l e a n u p s [ J a ] ( ) ; i f ( t h i s . s c o p e s ) f o r ( J a = 0 , e d = t h i s . s c o p e s . l e n g t h ; J a < e d ; J a + + ) t h i s . s c o p e s [ J a ] . s t o p ( ! 0 ) ; i f ( ! t h i s . d e t a c h e d & & t h i s . p a r e n t & & ! q a ) { c o n s t t d = t h i s . p a r e n t . s c o p e s . p o p ( ) ; t d & & t d ! = = t h i s & & ( t h i s . p a r e n t . s c o p e s [ t h i s . i n d e x ] = t d , t d . i n d e x = t h i s . i n d e x ) } t h i s . p a r e n t = v o i d 0 , t h i s . _ a c t i v e = ! 1 } } } f u n c t i o n e f f e c t S c o p e ( R a ) { r e t u r n n e w E f f e c t S c o p e ( R a ) } f u n c t i o n g e t C u r r e n t S c o p e ( ) { r e t u r n a c t i v e E f f e c t S c o p e } f u n c t i o n o n S c o p e D i s p o s e ( R a , q a = ! 1 ) { a c t i v e E f f e c t S c o p e & & a c t i v e E f f e c t S c o p e . c l e a n u p s . p u s h ( R a ) } l e t a c t i v e S u b ; c o n s t p a u s e d Q u e u e E f f e c t s = n e w W e a k S e t ; c l a s s R e a c t i v e E f f e c t { c o n s t r u c t o r ( q a ) { t h i s . f n = q a , t h i s . d e p s = v o i d 0 , t h i s . d e p s T a i l = v o i d 0 , t h i s . f l a g s = 5 , t h i s . n e x t E f f e c t = v o i d 0 , t h i s . c l e a n u p = v o i d 0 , t h i s . s c h e d u l e r = v o i d 0 , a c t i v e E f f e c t S c o p e & & a c t i v e E f f e c t S c o p e . a c t i v e & & a c t i v e E f f e c t S c o p e . e f f e c t s . p u s h ( t h i s ) } p a u s e ( ) { t h i s . f l a g s | = 6 4 } r e s u m e ( ) { t h i s . f l a g s & 6 4 & & ( t h i s . f l a g s & = - 6 5 , p a u s e d Q u e u e E f f e c t s . h a s ( t h i s ) & & ( p a u s e d Q u e u e E f f e c t s . d e l e t e ( t h i s ) , t h i s . t r i g g e r ( ) ) ) } n o t i f y ( ) { t h i s . f l a g s & 2 & & ! ( t h i s . f l a g s & 3 2 ) | | t h i s . f l a g s & 8 | | ( t h i s . f l a g s | = 8 , t h i s . n e x t E f f e c t = b a t c h e d E f f e c t , b a t c h e d E f f e c t = t h i s ) } r u n ( ) { i f ( ! ( t h i s . f l a g s & 1 ) ) r e t u r n t h i s . f n ( ) ; t h i s . f l a g s | = 2 , c l e a n u p E f f e c t ( t h i s ) , p r e p a r e D e p s ( t h i s ) ; c o n s t q a = a c t i v e S u b , J a = s h o u l d T r a c k ; a c t i v e S u b = t h i s , s h o u l d T r a c k = ! 0 ; t r y { r e t u r n t h i s . f n ( ) } f i n a l l y { c l e a n u p D e p s ( t h i s ) , a c t i v e S u b = q a , s h o u l d T r a c k = J a , t h i s . f l a g s & = - 3 } } s t o p ( ) { i f ( t h i s . f l a g s & 1 ) { f o r ( l e t q a = t h i s . d e p s ; q a ; q a = q a . n e x t D e p ) r e m o v e S u b ( q a ) ; t h i s . d e p s = t h i s . d e p s T a i l = v o i d 0 , c l e a n u p E f f e c t ( t h i s ) , t h i s . o n S t o p & & t h i s . o n S t o p ( ) , t h i s . f l a g s & = - 2 } } t r i g g e r ( ) { t h i s . f l a g s & 6 4 ? p a u s e d Q u e u e E f f e c t s . a d d ( t h i s ) : t h i s . s c h e d u l e r ? t h i s . s c h e d u l e r ( ) : t h i s . r u n I f D i r t y ( ) } r u n I f D i r t y ( ) { i s D i r t y ( t h i s ) & & t h i s . r u n ( ) } g e t d i r t y ( ) { r e t u r n i s D i r t y ( t h i s ) } } l e t b a t c h D e p t h = 0 , b a t c h e d E f f e c t ; f u n c t i o n s t a r t B a t c h ( ) { b a t c h D e p t h + + } f u n c t i o n e n d B a t c h ( ) { i f ( - - b a t c h D e p t h > 0 ) r e t u r n ; l e t R a ; f o r ( ; b a t c h e d E f f e c t ; ) { l e t q a = b a t c h e d E f f e c t ; f o r ( b a t c h e d E f f e c t = v o i d 0 ; q a ; ) { c o n s t J a = q a . n e x t E f f e c t ; i f ( q a . n e x t E f f e c t = v o i d 0 , q a . f l a g s & = - 9 , q a . f l a g s & 1 ) t r y { q a . t r i g g e r ( ) } c a t c h ( e d ) { R a | | ( R a = e d ) } q a = J a } } i f ( R a ) t h r o w R a } f u n c t i o n p r e p a r e D e p s ( R a ) { f o r ( l e t q a = R a . d e p s ; q a ; q a = q a . n e x t D e p ) q a . v e r s i o n = - 1 , q a . p r e v A c t i v e L i n k = q a . d e p . a c t i v e L i n k , q a . d e p . a c t i v e L i n k = q a } f u n c t i o n c l e a n u p D e p s ( R a ) { l e t q a , J a = R a . d e p s T a i l ; f o r ( l e t e d = J a ; e d ; e d = e d . p r e v D e p ) e d . v e r s i o n = = = - 1 ? ( e d = = = J a & & ( J a = e d . p r e v D e p ) , r e m o v e S u b ( e d ) , r e m o v e D e p ( e d ) ) : q a = e d , e d . d e p . a c t i v e L i n k = e d . p r e v A c t i v e L i n k , e d . p r e v A c t i v e L i n k = v o i d 0 ; R a . d e p s = q a , R a . d e p s T a i l = J a } f u n c t i o n i s D i r t y ( R a ) { f o r ( l e t q a = R a . d e p s ; q a ; q a = q a . n e x t D e p ) i f ( q a . d e p . v e r s i o n ! = = q a . v e r s i o n | | q a . d e p . c o m p u t e d & & r e f r e s h C o m p u t e d ( q a . d e p . c o m p u t e d ) = = = ! 1 | | q a . d e p . v e r s i o n ! = = q a . v e r s i o n ) r e t u r n ! 0 ; r e t u r n ! ! R a . _ d i r t y } f u n c t i o n r e f r e s h C o m p u t e d ( R a ) { i f ( R a . f l a g s & 2 ) r e t u r n ! 1 ; i f ( R a . f l a g s & 4 & & ! ( R a . f l a g s & 1 6 ) | | ( R a . f l a g s & = - 1 7 , R a . g l o b a l V e r s i o n = = = g l o b a l V e r s i o n ) ) r e t u r n ; R a . g l o b a l V e r s i o n = g l o b a l V e r s i o n ; c o n s t q a = R a . d e p ; i f ( R a . f l a g s | = 2 , q a . v e r s i o n > 0 & & ! R a . i s S S R & & ! i s D i r t y ( R a ) ) { R a . f l a g s & = - 3 ; r e t u r n } c o n s t J a = a c t i v e S u b , e d = s h o u l d T r a c k ; a c t i v e S u b = R a , s h o u l d T r a c k = ! 0 ; t r y { p r e p a r e D e p s ( R a ) ; c o n s t t d = R a . f n ( R a . _ v a l u e ) ; ( q a . v e r s i o n = = = 0 | | h a s C h a n g e d ( t d , R a . _ v a l u e ) ) & & ( R a . _ v a l u e = t d , q a . v e r s i o n + + ) } c a t c h ( t d ) { t h r o w q a . v e r s i o n + + , t d } f i n a l l y { a c t i v e S u b = J a , s
2024-09-07 10:27:05 +08:00
* @ vue / runtime - core v3 . 5.3
2024-08-27 22:31:52 +08:00
* ( c ) 2018 - present Yuxi ( Evan ) You and Vue contributors
* @ license MIT
2024-09-03 08:22:14 +08:00
* * / c o n s t s t a c k = [ ] ; l e t i s W a r n i n g = ! 1 ; f u n c t i o n w a r n $ 1 ( R a , . . . q a ) { i f ( i s W a r n i n g ) r e t u r n ; i s W a r n i n g = ! 0 , p a u s e T r a c k i n g ( ) ; c o n s t J a = s t a c k . l e n g t h ? s t a c k [ s t a c k . l e n g t h - 1 ] . c o m p o n e n t : n u l l , e d = J a & & J a . a p p C o n t e x t . c o n f i g . w a r n H a n d l e r , t d = g e t C o m p o n e n t T r a c e ( ) ; i f ( e d ) c a l l W i t h E r r o r H a n d l i n g ( e d , J a , 1 1 , [ R a + q a . m a p ( r d = > { v a r s d , o d ; r e t u r n ( o d = ( s d = r d . t o S t r i n g ) = = n u l l ? v o i d 0 : s d . c a l l ( r d ) ) ! = n u l l ? o d : J S O N . s t r i n g i f y ( r d ) } ) . j o i n ( " " ) , J a & & J a . p r o x y , t d . m a p ( ( { v n o d e : r d } ) = > ` a t < $ { f o r m a t C o m p o n e n t N a m e ( J a , r d . t y p e ) } > ` ) . j o i n ( `
2024-08-30 15:19:18 +08:00
` ),td]);else{const rd=[ ` [ Vue warn ] : $ { Ra } ` ,...qa];td.length&&rd.push( `
` ,...formatTrace(td)),console.warn(...rd)}resetTracking(),isWarning=!1}function getComponentTrace(){let Ra=stack[stack.length-1];if(!Ra)return[];const qa=[];for(;Ra;){const Ja=qa[0];Ja&&Ja.vnode===Ra?Ja.recurseCount++:qa.push({vnode:Ra,recurseCount:0});const ed=Ra.component&&Ra.component.parent;Ra=ed&&ed.vnode}return qa}function formatTrace(Ra){const qa=[];return Ra.forEach((Ja,ed)=>{qa.push(...ed===0?[]:[ `
2024-09-08 17:22:36 +08:00
` ],...formatTraceEntry(Ja))}),qa}function formatTraceEntry({vnode:Ra,recurseCount:qa}){const Ja=qa>0? ` ... ( $ { qa } recursive calls ) ` :"",ed=Ra.component?Ra.component.parent==null:!1,td= ` at < $ { formatComponentName ( Ra . component , Ra . type , ed ) } ` ,rd=">"+Ja;return Ra.props?[td,...formatProps(Ra.props),rd]:[td+rd]}function formatProps(Ra){const qa=[],Ja=Object.keys(Ra);return Ja.slice(0,3).forEach(ed=>{qa.push(...formatProp(ed,Ra[ed]))}),Ja.length>3&&qa.push(" ..."),qa}function formatProp(Ra,qa,Ja){return isString $ 3(qa)?(qa=JSON.stringify(qa),Ja?qa:[ ` $ { Ra } = $ { qa } ` ]):typeof qa=="number"||typeof qa=="boolean"||qa==null?Ja?qa:[ ` $ { Ra } = $ { qa } ` ]:isRef(qa)?(qa=formatProp(Ra,toRaw(qa.value),!0),Ja?qa:[ ` $ { Ra } = Ref < ` ,qa,">"]):isFunction $ 4(qa)?[ ` $ { Ra } = fn$ { qa . name ? ` < ${ qa . name } > ` : "" } ` ]:(qa=toRaw(qa),Ja?qa:[ ` $ { Ra } = ` ,qa])}function callWithErrorHandling(Ra,qa,Ja,ed){try{return ed?Ra(...ed):Ra()}catch(td){handleError $ 1(td,qa,Ja)}}function callWithAsyncErrorHandling(Ra,qa,Ja,ed){if(isFunction $ 4(Ra)){const td=callWithErrorHandling(Ra,qa,Ja,ed);return td&&isPromise(td)&&td.catch(rd=>{handleError $ 1(rd,qa,Ja)}),td}if(isArray $ 2(Ra)){const td=[];for(let rd=0;rd<Ra.length;rd++)td.push(callWithAsyncErrorHandling(Ra[rd],qa,Ja,ed));return td}}function handleError $ 1(Ra,qa,Ja,ed=!0){const td=qa?qa.vnode:null,{errorHandler:rd,throwUnhandledErrorInProduction:sd}=qa&&qa.appContext.config||EMPTY_OBJ;if(qa){let od=qa.parent;const ld=qa.proxy,cd= ` https : //vuejs.org/error-reference/#runtime-${Ja}`;for(;od;){const ud=od.ec;if(ud){for(let _d=0;_d<ud.length;_d++)if(ud[_d](Ra,ld,cd)===!1)return}od=od.parent}if(rd){pauseTracking(),callWithErrorHandling(rd,null,10,[Ra,ld,cd]),resetTracking();return}}logError(Ra,Ja,td,ed,sd)}function logError(Ra,qa,Ja,ed=!0,td=!1){if(td)throw Ra;console.error(Ra)}let isFlushing=!1,isFlushPending=!1;const queue$2=[];let flushIndex=0;const pendingPostFlushCbs=[];let activePostFlushCbs=null,postFlushIndex=0;const resolvedPromise=Promise.resolve();let currentFlushPromise=null;function nextTick$1(Ra){const qa=currentFlushPromise||resolvedPromise;return Ra?qa.then(this?Ra.bind(this):Ra):qa}function findInsertionIndex(Ra){let qa=isFlushing?flushIndex+1:0,Ja=queue$2.length;for(;qa<Ja;){const ed=qa+Ja>>>1,td=queue$2[ed],rd=getId(td);rd<Ra||rd===Ra&&td.flags&2?qa=ed+1:Ja=ed}return qa}function queueJob(Ra){if(!(Ra.flags&1)){const qa=getId(Ra),Ja=queue$2[queue$2.length-1];!Ja||!(Ra.flags&2)&&qa>=getId(Ja)?queue$2.push(Ra):queue$2.splice(findInsertionIndex(qa),0,Ra),Ra.flags|=1,queueFlush()}}function queueFlush(){!isFlushing&&!isFlushPending&&(isFlushPending=!0,currentFlushPromise=resolvedPromise.then(flushJobs))}function queuePostFlushCb(Ra){isArray$2(Ra)?pendingPostFlushCbs.push(...Ra):activePostFlushCbs&&Ra.id===-1?activePostFlushCbs.splice(postFlushIndex+1,0,Ra):Ra.flags&1||(pendingPostFlushCbs.push(Ra),Ra.flags|=1),queueFlush()}function flushPreFlushCbs(Ra,qa,Ja=isFlushing?flushIndex+1:0){for(;Ja<queue$2.length;Ja++){const ed=queue$2[Ja];if(ed&&ed.flags&2){if(Ra&&ed.id!==Ra.uid)continue;queue$2.splice(Ja,1),Ja--,ed.flags&4&&(ed.flags&=-2),ed(),ed.flags&=-2}}}function flushPostFlushCbs(Ra){if(pendingPostFlushCbs.length){const qa=[...new Set(pendingPostFlushCbs)].sort((Ja,ed)=>getId(Ja)-getId(ed));if(pendingPostFlushCbs.length=0,activePostFlushCbs){activePostFlushCbs.push(...qa);return}for(activePostFlushCbs=qa,postFlushIndex=0;postFlushIndex<activePostFlushCbs.length;postFlushIndex++){const Ja=activePostFlushCbs[postFlushIndex];Ja.flags&4&&(Ja.flags&=-2),Ja.flags&8||Ja(),Ja.flags&=-2}activePostFlushCbs=null,postFlushIndex=0}}const getId=Ra=>Ra.id==null?Ra.flags&2?-1:1/0:Ra.id;function flushJobs(Ra){isFlushPending=!1,isFlushing=!0;try{for(flushIndex=0;flushIndex<queue$2.length;flushIndex++){const qa=queue$2[flushIndex];qa&&!(qa.flags&8)&&(qa.flags&4&&(qa.flags&=-2),callWithErrorHandling(qa,qa.i,qa.i?15:14),qa.flags&=-2)}}finally{for(;flushIndex<queue$2.length;flushIndex++){const qa=queue$2[flushIndex];qa&&(qa.flags&=-2)}flushIndex=0,queue$2.length=0,flushPostFlushCbs(),isFlushing=!1,currentFlushPromise=null,(queue$2.length||pendingPostFlushCbs.length)&&fl
2024-09-07 10:27:05 +08:00
* @ vue / runtime - dom v3 . 5.3
2024-08-27 22:31:52 +08:00
* ( c ) 2018 - present Yuxi ( Evan ) You and Vue contributors
* @ license MIT
2024-09-08 17:22:36 +08:00
* * /let policy;const tt$5=typeof window<"u"&&window.trustedTypes;if(tt$5)try{policy=tt$5.createPolicy("vue",{createHTML:Ra=>Ra})}catch{}const unsafeToTrustedHTML=policy?Ra=>policy.createHTML(Ra):Ra=>Ra,svgNS="http:/ / www . w3 . org / 2000 / svg ",mathmlNS=" http : //www.w3.org/1998/Math/MathML",doc=typeof document<"u"?document:null,templateContainer=doc&&doc.createElement("template"),nodeOps={insert:(Ra,qa,Ja)=>{qa.insertBefore(Ra,Ja||null)},remove:Ra=>{const qa=Ra.parentNode;qa&&qa.removeChild(Ra)},createElement:(Ra,qa,Ja,ed)=>{const td=qa==="svg"?doc.createElementNS(svgNS,Ra):qa==="mathml"?doc.createElementNS(mathmlNS,Ra):Ja?doc.createElement(Ra,{is:Ja}):doc.createElement(Ra);return Ra==="select"&&ed&&ed.multiple!=null&&td.setAttribute("multiple",ed.multiple),td},createText:Ra=>doc.createTextNode(Ra),createComment:Ra=>doc.createComment(Ra),setText:(Ra,qa)=>{Ra.nodeValue=qa},setElementText:(Ra,qa)=>{Ra.textContent=qa},parentNode:Ra=>Ra.parentNode,nextSibling:Ra=>Ra.nextSibling,querySelector:Ra=>doc.querySelector(Ra),setScopeId(Ra,qa){Ra.setAttribute(qa,"")},insertStaticContent(Ra,qa,Ja,ed,td,rd){const sd=Ja?Ja.previousSibling:qa.lastChild;if(td&&(td===rd||td.nextSibling))for(;qa.insertBefore(td.cloneNode(!0),Ja),!(td===rd||!(td=td.nextSibling)););else{templateContainer.innerHTML=unsafeToTrustedHTML(ed==="svg"?`<svg>${Ra}</svg>`:ed==="mathml"?`<math>${Ra}</math>`:Ra);const od=templateContainer.content;if(ed==="svg"||ed==="mathml"){const ld=od.firstChild;for(;ld.firstChild;)od.appendChild(ld.firstChild);od.removeChild(ld)}qa.insertBefore(od,Ja)}return[sd?sd.nextSibling:qa.firstChild,Ja?Ja.previousSibling:qa.lastChild]}},TRANSITION="transition",ANIMATION="animation",vtcKey=Symbol("_vtc"),DOMTransitionPropsValidators={name:String,type:String,css:{type:Boolean,default:!0},duration:[String,Number,Object],enterFromClass:String,enterActiveClass:String,enterToClass:String,appearFromClass:String,appearActiveClass:String,appearToClass:String,leaveFromClass:String,leaveActiveClass:String,leaveToClass:String},TransitionPropsValidators=extend$3({},BaseTransitionPropsValidators,DOMTransitionPropsValidators),decorate$1=Ra=>(Ra.displayName="Transition",Ra.props=TransitionPropsValidators,Ra),Transition$1=decorate$1((Ra,{slots:qa})=>h$1(BaseTransition,resolveTransitionProps(Ra),qa)),callHook=(Ra,qa=[])=>{isArray$2(Ra)?Ra.forEach(Ja=>Ja(...qa)):Ra&&Ra(...qa)},hasExplicitCallback=Ra=>Ra?isArray$2(Ra)?Ra.some(qa=>qa.length>1):Ra.length>1:!1;function resolveTransitionProps(Ra){const qa={};for(const Jd in Ra)Jd in DOMTransitionPropsValidators||(qa[Jd]=Ra[Jd]);if(Ra.css===!1)return qa;const{name:Ja="v",type:ed,duration:td,enterFromClass:rd=`${Ja}-enter-from`,enterActiveClass:sd=`${Ja}-enter-active`,enterToClass:od=`${Ja}-enter-to`,appearFromClass:ld=rd,appearActiveClass:cd=sd,appearToClass:ud=od,leaveFromClass:_d=`${Ja}-leave-from`,leaveActiveClass:yd=`${Ja}-leave-active`,leaveToClass:gd=`${Ja}-leave-to`}=Ra,Ed=normalizeDuration(td),Td=Ed&&Ed[0],Od=Ed&&Ed[1],{onBeforeEnter:Rd,onEnter:Nd,onEnterCancelled:Id,onLeave:Md,onLeaveCancelled:Ld,onBeforeAppear:Pd=Rd,onAppear:qd=Nd,onAppearCancelled:Yd=Id}=qa,Ud=(Jd,Zd,pf)=>{removeTransitionClass(Jd,Zd?ud:od),removeTransitionClass(Jd,Zd?cd:sd),pf&&pf()},Hd=(Jd,Zd)=>{Jd._isLeaving=!1,removeTransitionClass(Jd,_d),removeTransitionClass(Jd,gd),removeTransitionClass(Jd,yd),Zd&&Zd()},zd=Jd=>(Zd,pf)=>{const Qd=Jd?qd:Nd,hf=()=>Ud(Zd,Jd,pf);callHook(Qd,[Zd,hf]),nextFrame(()=>{removeTransitionClass(Zd,Jd?ld:rd),addTransitionClass(Zd,Jd?ud:od),hasExplicitCallback(Qd)||whenTransitionEnds(Zd,ed,Td,hf)})};return extend$3(qa,{onBeforeEnter(Jd){callHook(Rd,[Jd]),addTransitionClass(Jd,rd),addTransitionClass(Jd,sd)},onBeforeAppear(Jd){callHook(Pd,[Jd]),addTransitionClass(Jd,ld),addTransitionClass(Jd,cd)},onEnter:zd(!1),onAppear:zd(!0),onLeave(Jd,Zd){Jd._isLeaving=!0;const pf=()=>Hd(Jd,Zd);addTransitionClass(Jd,_d),addTransitionClass(Jd,yd),forceReflow(),nextFrame(()=>{Jd._isLeaving&&(removeTransitionClass(Jd,_d),addTransitionClass(Jd,gd),hasExplicitCallback(Md)||whenTransitionEnds(Jd,ed,Od,pf))}),callHook(Md,[Jd,pf])},onEnterCancelled
2024-09-03 08:22:14 +08:00
` ).map(td=>{const rd=td.match(/^ \s +/);if(rd===null)return td;const[sd]=rd;return sd.length>=ed.length?td.slice(ed.length):td}).join( `
2024-09-07 10:27:05 +08:00
` )}let _Tokenizer $ 1=class{constructor(qa){n_(this,"options");n_(this,"rules");n_(this,"lexer");this.options=qa||_defaults $ 1}space(qa){const Ja=this.rules.block.newline.exec(qa);if(Ja&&Ja[0].length>0)return{type:"space",raw:Ja[0]}}code(qa){const Ja=this.rules.block.code.exec(qa);if(Ja){const ed=Ja[0].replace(/^(?: {1,4}| {0,3} \t )/gm,"");return{type:"code",raw:Ja[0],codeBlockStyle:"indented",text:this.options.pedantic?ed:rtrim $ 1(ed, `
2024-08-30 15:19:18 +08:00
` )}}}fences(qa){const Ja=this.rules.block.fences.exec(qa);if(Ja){const ed=Ja[0],td=indentCodeCompensation $ 1(ed,Ja[3]||"");return{type:"code",raw:ed,lang:Ja[2]?Ja[2].trim().replace(this.rules.inline.anyPunctuation," $ 1"):Ja[2],text:td}}}heading(qa){const Ja=this.rules.block.heading.exec(qa);if(Ja){let ed=Ja[2].trim();if(/# $ /.test(ed)){const td=rtrim $ 1(ed,"#");(this.options.pedantic||!td||/ $ /.test(td))&&(ed=td.trim())}return{type:"heading",raw:Ja[0],depth:Ja[1].length,text:ed,tokens:this.lexer.inline(ed)}}}hr(qa){const Ja=this.rules.block.hr.exec(qa);if(Ja)return{type:"hr",raw:rtrim $ 1(Ja[0], `
` )}}blockquote(qa){const Ja=this.rules.block.blockquote.exec(qa);if(Ja){let ed=rtrim $ 1(Ja[0], `
2024-08-27 22:31:52 +08:00
` ).split( `
2024-09-03 08:22:14 +08:00
` ),td="",rd="";const sd=[];for(;ed.length>0;){let od=!1;const ld=[];let cd;for(cd=0;cd<ed.length;cd++)if(/^ {0,3}>/.test(ed[cd]))ld.push(ed[cd]),od=!0;else if(!od)ld.push(ed[cd]);else break;ed=ed.slice(cd);const ud=ld.join( `
2024-08-31 11:28:56 +08:00
` ),_d=ud.replace(/ \n {0,3}((?:=+|-+) *)(?= \n | $ )/g, `
2024-08-30 15:19:18 +08:00
$1 ` ).replace(/^ {0,3}>[ \t ]?/gm,"");td=td? ` $ { td }
$ { ud } ` :ud,rd=rd? ` $ { rd }
2024-09-03 08:22:14 +08:00
$ { _d } ` :_d;const yd=this.lexer.state.top;if(this.lexer.state.top=!0,this.lexer.blockTokens(_d,sd,!0),this.lexer.state.top=yd,ed.length===0)break;const gd=sd[sd.length-1];if((gd==null?void 0:gd.type)==="code")break;if((gd==null?void 0:gd.type)==="blockquote"){const Ed=gd,Td=Ed.raw+ `
2024-08-30 15:19:18 +08:00
` +ed.join( `
2024-09-08 17:22:36 +08:00
` ),Od=this.blockquote(Td);sd[sd.length-1]=Od,td=td.substring(0,td.length-Ed.raw.length)+Od.raw,rd=rd.substring(0,rd.length-Ed.text.length)+Od.text;break}else if((gd==null?void 0:gd.type)==="list"){const Ed=gd,Td=Ed.raw+ `
2024-08-30 15:19:18 +08:00
` +ed.join( `
2024-09-08 17:22:36 +08:00
` ),Od=this.list(Td);sd[sd.length-1]=Od,td=td.substring(0,td.length-gd.raw.length)+Od.raw,rd=rd.substring(0,rd.length-Ed.raw.length)+Od.raw,ed=Td.substring(sd[sd.length-1].raw.length).split( `
2024-09-03 08:22:14 +08:00
` );continue}}return{type:"blockquote",raw:td,tokens:sd,text:rd}}}list(qa){let Ja=this.rules.block.list.exec(qa);if(Ja){let ed=Ja[1].trim();const td=ed.length>1,rd={type:"list",raw:"",ordered:td,start:td?+ed.slice(0,-1):"",loose:!1,items:[]};ed=td? ` \ \ d { 1 , 9 } \ \ $ { ed . slice ( - 1 ) } ` : ` \ \ $ { ed } ` ,this.options.pedantic&&(ed=td?ed:"[*+-]");const sd=new RegExp( ` ^ ( { 0 , 3 } $ { ed } ) ( ( ? : [ ] [ ^ \ \ n ] * ) ? ( ? : \ \ n | $ ) ) ` );let od=!1;for(;qa;){let ld=!1,cd="",ud="";if(!(Ja=sd.exec(qa))||this.rules.block.hr.test(qa))break;cd=Ja[0],qa=qa.substring(cd.length);let _d=Ja[2].split( `
` ,1)[0].replace(/^ \t +/,Rd=>" ".repeat(3*Rd.length)),yd=qa.split( `
2024-09-04 14:19:22 +08:00
` ,1)[0],gd=!_d.trim(),Ed=0;if(this.options.pedantic?(Ed=2,ud=_d.trimStart()):gd?Ed=Ja[1].length+1:(Ed=Ja[2].search(/[^ ]/),Ed=Ed>4?1:Ed,ud=_d.slice(Ed),Ed+=Ja[1].length),gd&&/^[ \t ]* $ /.test(yd)&&(cd+=yd+ `
2024-09-03 08:22:14 +08:00
` ,qa=qa.substring(yd.length+1),ld=!0),!ld){const Rd=new RegExp( ` ^ { 0 , $ { Math . min ( 3 , Ed - 1 ) } } ( ? : [ * + - ] | \ \ d { 1 , 9 } [ . ) ] ) ( ( ? : [ ] [ ^ \ \ n ] * ) ? ( ? : \ \ n | $ ) ) ` ),Nd=new RegExp( ` ^ { 0 , $ { Math . min ( 3 , Ed - 1 ) } } ( ( ? : - * ) { 3 , } | ( ? : _ * ) { 3 , } | ( ? : \ \ * * ) { 3 , } ) ( ? : \ \ n + | $ ) ` ),Id=new RegExp( ` ^ { 0 , $ { Math . min ( 3 , Ed - 1 ) } } ( ? : \ ` \` \` |~~~) ` ) , Md = new RegExp ( ` ^ {0, ${ Math . min ( 3 , Ed - 1 ) } }# ` ) ; for ( ; qa ; ) { const Ld = qa . split ( `
2024-09-08 17:22:36 +08:00
` ,1)[0];let Pd;if(yd=Ld,this.options.pedantic?(yd=yd.replace(/^ {1,4}(?=( {4})*[^ ])/g," "),Pd=yd):Pd=yd.replace(/ \t /g," "),Id.test(yd)||Md.test(yd)||Rd.test(yd)||Nd.test(yd))break;if(Pd.search(/[^ ]/)>=Ed||!yd.trim())ud+= `
` +Pd.slice(Ed);else{if(gd||_d.replace(/ \t /g," ").search(/[^ ]/)>=4||Id.test(_d)||Md.test(_d)||Nd.test(_d))break;ud+= `
2024-09-03 08:22:14 +08:00
` +yd}!gd&&!yd.trim()&&(gd=!0),cd+=Ld+ `
2024-09-08 17:22:36 +08:00
` ,qa=qa.substring(Ld.length+1),_d=Pd.slice(Ed)}}rd.loose||(od?rd.loose=!0:/ \n [ \t ]* \n [ \t ]* $ /.test(cd)&&(od=!0));let Td=null,Od;this.options.gfm&&(Td=/^ \[ [ xX] \] /.exec(ud),Td&&(Od=Td[0]!=="[ ] ",ud=ud.replace(/^ \[ [ xX] \] +/,""))),rd.items.push({type:"list_item",raw:cd,task:!!Td,checked:Od,loose:!1,text:ud,tokens:[]}),rd.raw+=cd}rd.items[rd.items.length-1].raw=rd.items[rd.items.length-1].raw.trimEnd(),rd.items[rd.items.length-1].text=rd.items[rd.items.length-1].text.trimEnd(),rd.raw=rd.raw.trimEnd();for(let ld=0;ld<rd.items.length;ld++)if(this.lexer.state.top=!1,rd.items[ld].tokens=this.lexer.blockTokens(rd.items[ld].text,[]),!rd.loose){const cd=rd.items[ld].tokens.filter(_d=>_d.type==="space"),ud=cd.length>0&&cd.some(_d=>/ \n .* \n /.test(_d.raw));rd.loose=ud}if(rd.loose)for(let ld=0;ld<rd.items.length;ld++)rd.items[ld].loose=!0;return rd}}html(qa){const Ja=this.rules.block.html.exec(qa);if(Ja)return{type:"html",block:!0,raw:Ja[0],pre:Ja[1]==="pre"||Ja[1]==="script"||Ja[1]==="style",text:Ja[0]}}def(qa){const Ja=this.rules.block.def.exec(qa);if(Ja){const ed=Ja[1].toLowerCase().replace(/ \s +/g," "),td=Ja[2]?Ja[2].replace(/^<(.*)> $ /," $ 1").replace(this.rules.inline.anyPunctuation," $ 1"):"",rd=Ja[3]?Ja[3].substring(1,Ja[3].length-1).replace(this.rules.inline.anyPunctuation," $ 1"):Ja[3];return{type:"def",tag:ed,raw:Ja[0],href:td,title:rd}}}table(qa){const Ja=this.rules.block.table.exec(qa);if(!Ja||!/[:|]/.test(Ja[2]))return;const ed=splitCells $ 1(Ja[1]),td=Ja[2].replace(/^ \| | \| * $ /g,"").split("|"),rd=Ja[3]&&Ja[3].trim()?Ja[3].replace(/ \n [ \t ]* $ /,"").split( `
2024-09-03 08:22:14 +08:00
` ):[],sd={type:"table",raw:Ja[0],header:[],align:[],rows:[]};if(ed.length===td.length){for(const od of td)/^ *-+: * $ /.test(od)?sd.align.push("right"):/^ *:-+: * $ /.test(od)?sd.align.push("center"):/^ *:-+ * $ /.test(od)?sd.align.push("left"):sd.align.push(null);for(let od=0;od<ed.length;od++)sd.header.push({text:ed[od],tokens:this.lexer.inline(ed[od]),header:!0,align:sd.align[od]});for(const od of rd)sd.rows.push(splitCells $ 1(od,sd.header.length).map((ld,cd)=>({text:ld,tokens:this.lexer.inline(ld),header:!1,align:sd.align[cd]})));return sd}}lheading(qa){const Ja=this.rules.block.lheading.exec(qa);if(Ja)return{type:"heading",raw:Ja[0],depth:Ja[2].charAt(0)==="="?1:2,text:Ja[1],tokens:this.lexer.inline(Ja[1])}}paragraph(qa){const Ja=this.rules.block.paragraph.exec(qa);if(Ja){const ed=Ja[1].charAt(Ja[1].length-1)=== `
2024-09-04 14:19:22 +08:00
` ?Ja[1].slice(0,-1):Ja[1];return{type:"paragraph",raw:Ja[0],text:ed,tokens:this.lexer.inline(ed)}}}text(qa){const Ja=this.rules.block.text.exec(qa);if(Ja)return{type:"text",raw:Ja[0],text:Ja[0],tokens:this.lexer.inline(Ja[0])}}escape(qa){const Ja=this.rules.inline.escape.exec(qa);if(Ja)return{type:"escape",raw:Ja[0],text:escape $ 1 $ 2(Ja[1])}}tag(qa){const Ja=this.rules.inline.tag.exec(qa);if(Ja)return!this.lexer.state.inLink&&/^<a /i.test(Ja[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&/^< \/ a>/i.test(Ja[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&/^<(pre|code|kbd|script)( \s |>)/i.test(Ja[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&/^< \/ (pre|code|kbd|script)( \s |>)/i.test(Ja[0])&&(this.lexer.state.inRawBlock=!1),{type:"html",raw:Ja[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,block:!1,text:Ja[0]}}link(qa){const Ja=this.rules.inline.link.exec(qa);if(Ja){const ed=Ja[2].trim();if(!this.options.pedantic&&/^</.test(ed)){if(!/> $ /.test(ed))return;const sd=rtrim $ 1(ed.slice(0,-1)," \\ ");if((ed.length-sd.length)%2===0)return}else{const sd=findClosingBracket $ 1(Ja[2],"()");if(sd>-1){const ld=(Ja[0].indexOf("!")===0?5:4)+Ja[1].length+sd;Ja[2]=Ja[2].substring(0,sd),Ja[0]=Ja[0].substring(0,ld).trim(),Ja[3]=""}}let td=Ja[2],rd="";if(this.options.pedantic){const sd=/^([^'"]*[^ \s ]) \s +(['"])(.*) \2 /.exec(td);sd&&(td=sd[1],rd=sd[3])}else rd=Ja[3]?Ja[3].slice(1,-1):"";return td=td.trim(),/^</.test(td)&&(this.options.pedantic&&!/> $ /.test(ed)?td=td.slice(1):td=td.slice(1,-1)),outputLink $ 1(Ja,{href:td&&td.replace(this.rules.inline.anyPunctuation," $ 1"),title:rd&&rd.replace(this.rules.inline.anyPunctuation," $ 1")},Ja[0],this.lexer)}}reflink(qa,Ja){let ed;if((ed=this.rules.inline.reflink.exec(qa))||(ed=this.rules.inline.nolink.exec(qa))){const td=(ed[2]||ed[1]).replace(/ \s +/g," "),rd=Ja[td.toLowerCase()];if(!rd){const sd=ed[0].charAt(0);return{type:"text",raw:sd,text:sd}}return outputLink $ 1(ed,rd,ed[0],this.lexer)}}emStrong(qa,Ja,ed=""){let td=this.rules.inline.emStrongLDelim.exec(qa);if(!td||td[3]&&ed.match(/[ \p {L} \p {N}]/u))return;if(!(td[1]||td[2]||"")||!ed||this.rules.inline.punctuation.exec(ed)){const sd=[...td[0]].length-1;let od,ld,cd=sd,ud=0;const _d=td[0][0]==="*"?this.rules.inline.emStrongRDelimAst:this.rules.inline.emStrongRDelimUnd;for(_d.lastIndex=0,Ja=Ja.slice(-1*qa.length+sd);(td=_d.exec(Ja))!=null;){if(od=td[1]||td[2]||td[3]||td[4]||td[5]||td[6],!od)continue;if(ld=[...od].length,td[3]||td[4]){cd+=ld;continue}else if((td[5]||td[6])&&sd%3&&!((sd+ld)%3)){ud+=ld;continue}if(cd-=ld,cd>0)continue;ld=Math.min(ld,ld+cd+ud);const yd=[...td[0]][0].length,gd=qa.slice(0,sd+td.index+yd+ld);if(Math.min(sd,ld)%2){const Td=gd.slice(1,-1);return{type:"em",raw:gd,text:Td,tokens:this.lexer.inlineTokens(Td)}}const Ed=gd.slice(2,-2);return{type:"strong",raw:gd,text:Ed,tokens:this.lexer.inlineTokens(Ed)}}}}codespan(qa){const Ja=this.rules.inline.code.exec(qa);if(Ja){let ed=Ja[2].replace(/ \n /g," ");const td=/[^ ]/.test(ed),rd=/^ /.test(ed)&&/ $ /.test(ed);return td&&rd&&(ed=ed.substring(1,ed.length-1)),ed=escape $ 1 $ 2(ed,!0),{type:"codespan",raw:Ja[0],text:ed}}}br(qa){const Ja=this.rules.inline.br.exec(qa);if(Ja)return{type:"br",raw:Ja[0]}}del(qa){const Ja=this.rules.inline.del.exec(qa);if(Ja)return{type:"del",raw:Ja[0],text:Ja[2],tokens:this.lexer.inlineTokens(Ja[2])}}autolink(qa){const Ja=this.rules.inline.autolink.exec(qa);if(Ja){let ed,td;return Ja[2]==="@"?(ed=escape $ 1 $ 2(Ja[1]),td="mailto:"+ed):(ed=escape $ 1 $ 2(Ja[1]),td=ed),{type:"link",raw:Ja[0],text:ed,href:td,tokens:[{type:"text",raw:ed,text:ed}]}}}url(qa){var ed;let Ja;if(Ja=this.rules.inline.url.exec(qa)){let td,rd;if(Ja[2]==="@")td=escape $ 1 $ 2(Ja[0]),rd="mailto:"+td;else{let sd;do sd=Ja[0],Ja[0]=((ed=this.rules.inline._backpedal.exec(Ja[0]))==null?void 0:ed[0])??"";while(sd!==Ja[0]);td=escape $ 1 $ 2(Ja[0]),Ja[1]==="www."?rd="http://"+Ja[0]:rd=Ja[0]}return{type:"link",raw:Ja[0],text:td,href:rd,tokens:[{type:"text",raw:td,text:td}]}}}inlineText(qa){const Ja=this.rules.inline.text.exec(qa);if(Ja){let ed;return this.lexer.state.inRawBl
2024-09-08 17:22:36 +08:00
] ` ).replace("lheading",lheading $ 1).replace("|table","").replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").replace("|tag","").getRegex()},escape $ 4=/^ \\ ([!"# $ %&'()*+, \- ./:;<=>?@ \[ \] \\ ^_ ` { | } ~ ] ) / , inlineCode$1 = /^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/ , br$4 = /^( {2,}|\\)\n(?!\s*$)/ , inlineText$1 = /^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/ , _punctuation$1 = "\\p{P}\\p{S}" , punctuation$1 = edit$1 ( /^((?![*_])[\spunctuation])/ , "u" ) . replace ( /punctuation/g , _punctuation$1 ) . getRegex ( ) , blockSkip$1 = /\[[^[\]]*?\]\([^\(\)]*?\)|`[^`]*?`|<[^<>]*?>/g , emStrongLDelim$1 = edit$1 ( /^(?:\*+(?:((?!\*)[punct])|[^\s*]))|^_+(?:((?!_)[punct])|([^\s_]))/ , "u" ) . replace ( /punct/g , _punctuation$1 ) . getRegex ( ) , emStrongRDelimAst$1 = edit$1 ( "^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)[punct](\\*+)(?=[\\s]|$)|[^punct\\s](\\*+)(?!\\*)(?=[punct\\s]|$)|(?!\\*)[punct\\s](\\*+)(?=[^punct\\s])|[\\s](\\*+)(?!\\*)(?=[punct])|(?!\\*)[punct](\\*+)(?!\\*)(?=[punct])|[^punct\\s](\\*+)(?=[^punct\\s])" , "gu" ) . replace ( /punct/g , _punctuation$1 ) . getRegex ( ) , emStrongRDelimUnd$1 = edit$1 ( "^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)[punct](_+)(?=[\\s]|$)|[^punct\\s](_+)(?!_)(?=[punct\\s]|$)|(?!_)[punct\\s](_+)(?=[^punct\\s])|[\\s](_+)(?!_)(?=[punct])|(?!_)[punct](_+)(?!_)(?=[punct])" , "gu" ) . replace ( /punct/g , _punctuation$1 ) . getRegex ( ) , anyPunctuation$1 = edit$1 ( /\\([punct])/ , "gu" ) . replace ( /punct/g , _punctuation$1 ) . getRegex ( ) , autolink$1 = edit$1 ( /^<(scheme:[^\s\x00-\x1f<>]*|email)>/ ) . replace ( "scheme" , /[a-zA-Z][a-zA-Z0-9+.-]{1,31}/ ) . replace ( "email" , /[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/ ) . getRegex ( ) , _inlineComment$1 = edit$1 ( _comment$1 ) . replace ( "(?:-->|$)" , "-->" ) . getRegex ( ) , tag$1 = edit$1 ( "^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>" ) . replace ( "comment" , _inlineComment$1 ) . replace ( "attribute" , /\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/ ) . getRegex ( ) , _inlineLabel$1 = /(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/ , link$1 = edit$1 ( /^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/ ) . replace ( "label" , _inlineLabel$1 ) . replace ( "href" , /<(?:\\.|[^\n<>\\])+>|[^\s\x00-\x1f]*/ ) . replace ( "title" , /"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/ ) . getRegex ( ) , reflink$1 = edit$1 ( /^!?\[(label)\]\[(ref)\]/ ) . replace ( "label" , _inlineLabel$1 ) . replace ( "ref" , _blockLabel$1 ) . getRegex ( ) , nolink$1 = edit$1 ( /^!?\[(ref)\](?:\[\])?/ ) . replace ( "ref" , _blockLabel$1 ) . getRegex ( ) , reflinkSearch$1 = edit$1 ( "reflink|nolink(?!\\()" , "g" ) . replace ( "reflink" , reflink$1 ) . replace ( "nolink" , nolink$1 ) . getRegex ( ) , inlineNormal$1 = { _backpedal : noopTest$1 , anyPunctuation : anyPunctuation$1 , autolink : autolink$1 , blockSkip : blockSkip$1 , br : br$4 , code : inlineCode$1 , del : noopTest$1 , emStrongLDelim : emStrongLDelim$1 , emStrongRDelimAst : emStrongRDelimAst$1 , emStrongRDelimUnd : emStrongRDelimUnd$1 , escape : escape$4 , link : link$1 , nolink : nolink$1 , punctuation : punctuation$1 , reflink : reflink$1 , reflinkSearch : reflinkSearch$1 , tag : tag$1 , text : inlineText$1 , url : noopTest$1 } , inlinePedantic$1 = { ... inlineNormal$1 , link : edit$1 ( /^!?\[(label)\]\((.*?)\)/ ) . replace ( "label" , _inlineLabel$1 ) . getRegex ( ) , reflink : edit$1 ( /^!?\[(label)\]\s*\[([^\]]*)\]/ ) . replace ( "label" , _inlineLabel$1 ) . getRegex ( ) } , inlineGfm$1 = { ... inlineNormal$1 , escape : edit$1 ( escape$4 ) . replace ( "])" , "~|])" ) . getRegex ( ) , url : edit$1 ( /^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/ , "i" ) . replace ( "email" , /[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/ ) . getRegex ( ) , _backpedal : /(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/ , del : /^(~~?)(?=[^\s~])([\s\S]*?[^\s~])\1(?=[^~]|$)/ , text : /^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|https?:\/\/|ftp:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/ } , inlineBreaks$1 = { ... inlineGfm$1 , br : edit$1 ( br$4 ) . replace ( "{2,}" , "*" ) .
2024-09-04 14:19:22 +08:00
` ),this.blockTokens(qa,this.tokens);for(let Ja=0;Ja<this.inlineQueue.length;Ja++){const ed=this.inlineQueue[Ja];this.inlineTokens(ed.src,ed.tokens)}return this.inlineQueue=[],this.tokens}blockTokens(qa,Ja=[],ed=!1){this.options.pedantic&&(qa=qa.replace(/ \t /g," ").replace(/^ + $ /gm,""));let td,rd,sd;for(;qa;)if(!(this.options.extensions&&this.options.extensions.block&&this.options.extensions.block.some(od=>(td=od.call({lexer:this},qa,Ja))?(qa=qa.substring(td.raw.length),Ja.push(td),!0):!1))){if(td=this.tokenizer.space(qa)){qa=qa.substring(td.raw.length),td.raw.length===1&&Ja.length>0?Ja[Ja.length-1].raw+= `
2024-08-30 15:19:18 +08:00
` :Ja.push(td);continue}if(td=this.tokenizer.code(qa)){qa=qa.substring(td.raw.length),rd=Ja[Ja.length-1],rd&&(rd.type==="paragraph"||rd.type==="text")?(rd.raw+= `
` +td.raw,rd.text+= `
` +td.text,this.inlineQueue[this.inlineQueue.length-1].src=rd.text):Ja.push(td);continue}if(td=this.tokenizer.fences(qa)){qa=qa.substring(td.raw.length),Ja.push(td);continue}if(td=this.tokenizer.heading(qa)){qa=qa.substring(td.raw.length),Ja.push(td);continue}if(td=this.tokenizer.hr(qa)){qa=qa.substring(td.raw.length),Ja.push(td);continue}if(td=this.tokenizer.blockquote(qa)){qa=qa.substring(td.raw.length),Ja.push(td);continue}if(td=this.tokenizer.list(qa)){qa=qa.substring(td.raw.length),Ja.push(td);continue}if(td=this.tokenizer.html(qa)){qa=qa.substring(td.raw.length),Ja.push(td);continue}if(td=this.tokenizer.def(qa)){qa=qa.substring(td.raw.length),rd=Ja[Ja.length-1],rd&&(rd.type==="paragraph"||rd.type==="text")?(rd.raw+= `
` +td.raw,rd.text+= `
2024-09-03 08:22:14 +08:00
` +td.raw,this.inlineQueue[this.inlineQueue.length-1].src=rd.text):this.tokens.links[td.tag]||(this.tokens.links[td.tag]={href:td.href,title:td.title});continue}if(td=this.tokenizer.table(qa)){qa=qa.substring(td.raw.length),Ja.push(td);continue}if(td=this.tokenizer.lheading(qa)){qa=qa.substring(td.raw.length),Ja.push(td);continue}if(sd=qa,this.options.extensions&&this.options.extensions.startBlock){let od=1/0;const ld=qa.slice(1);let cd;this.options.extensions.startBlock.forEach(ud=>{cd=ud.call({lexer:this},ld),typeof cd=="number"&&cd>=0&&(od=Math.min(od,cd))}),od<1/0&&od>=0&&(sd=qa.substring(0,od+1))}if(this.state.top&&(td=this.tokenizer.paragraph(sd))){rd=Ja[Ja.length-1],ed&&(rd==null?void 0:rd.type)==="paragraph"?(rd.raw+= `
2024-08-30 15:19:18 +08:00
` +td.raw,rd.text+= `
2024-09-03 08:22:14 +08:00
` +td.text,this.inlineQueue.pop(),this.inlineQueue[this.inlineQueue.length-1].src=rd.text):Ja.push(td),ed=sd.length!==qa.length,qa=qa.substring(td.raw.length);continue}if(td=this.tokenizer.text(qa)){qa=qa.substring(td.raw.length),rd=Ja[Ja.length-1],rd&&rd.type==="text"?(rd.raw+= `
2024-08-30 15:19:18 +08:00
` +td.raw,rd.text+= `
2024-09-07 10:27:05 +08:00
` +td.text,this.inlineQueue.pop(),this.inlineQueue[this.inlineQueue.length-1].src=rd.text):Ja.push(td);continue}if(qa){const od="Infinite loop on byte: "+qa.charCodeAt(0);if(this.options.silent){console.error(od);break}else throw new Error(od)}}return this.state.top=!0,Ja}inline(qa,Ja=[]){return this.inlineQueue.push({src:qa,tokens:Ja}),Ja}inlineTokens(qa,Ja=[]){let ed,td,rd,sd=qa,od,ld,cd;if(this.tokens.links){const ud=Object.keys(this.tokens.links);if(ud.length>0)for(;(od=this.tokenizer.rules.inline.reflinkSearch.exec(sd))!=null;)ud.includes(od[0].slice(od[0].lastIndexOf("[")+1,-1))&&(sd=sd.slice(0,od.index)+"["+"a".repeat(od[0].length-2)+"]"+sd.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;(od=this.tokenizer.rules.inline.blockSkip.exec(sd))!=null;)sd=sd.slice(0,od.index)+"["+"a".repeat(od[0].length-2)+"]"+sd.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);for(;(od=this.tokenizer.rules.inline.anyPunctuation.exec(sd))!=null;)sd=sd.slice(0,od.index)+"++"+sd.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);for(;qa;)if(ld||(cd=""),ld=!1,!(this.options.extensions&&this.options.extensions.inline&&this.options.extensions.inline.some(ud=>(ed=ud.call({lexer:this},qa,Ja))?(qa=qa.substring(ed.raw.length),Ja.push(ed),!0):!1))){if(ed=this.tokenizer.escape(qa)){qa=qa.substring(ed.raw.length),Ja.push(ed);continue}if(ed=this.tokenizer.tag(qa)){qa=qa.substring(ed.raw.length),td=Ja[Ja.length-1],td&&ed.type==="text"&&td.type==="text"?(td.raw+=ed.raw,td.text+=ed.text):Ja.push(ed);continue}if(ed=this.tokenizer.link(qa)){qa=qa.substring(ed.raw.length),Ja.push(ed);continue}if(ed=this.tokenizer.reflink(qa,this.tokens.links)){qa=qa.substring(ed.raw.length),td=Ja[Ja.length-1],td&&ed.type==="text"&&td.type==="text"?(td.raw+=ed.raw,td.text+=ed.text):Ja.push(ed);continue}if(ed=this.tokenizer.emStrong(qa,sd,cd)){qa=qa.substring(ed.raw.length),Ja.push(ed);continue}if(ed=this.tokenizer.codespan(qa)){qa=qa.substring(ed.raw.length),Ja.push(ed);continue}if(ed=this.tokenizer.br(qa)){qa=qa.substring(ed.raw.length),Ja.push(ed);continue}if(ed=this.tokenizer.del(qa)){qa=qa.substring(ed.raw.length),Ja.push(ed);continue}if(ed=this.tokenizer.autolink(qa)){qa=qa.substring(ed.raw.length),Ja.push(ed);continue}if(!this.state.inLink&&(ed=this.tokenizer.url(qa))){qa=qa.substring(ed.raw.length),Ja.push(ed);continue}if(rd=qa,this.options.extensions&&this.options.extensions.startInline){let ud=1/0;const _d=qa.slice(1);let yd;this.options.extensions.startInline.forEach(gd=>{yd=gd.call({lexer:this},_d),typeof yd=="number"&&yd>=0&&(ud=Math.min(ud,yd))}),ud<1/0&&ud>=0&&(rd=qa.substring(0,ud+1))}if(ed=this.tokenizer.inlineText(rd)){qa=qa.substring(ed.raw.length),ed.raw.slice(-1)!=="_"&&(cd=ed.raw.slice(-1)),ld=!0,td=Ja[Ja.length-1],td&&td.type==="text"?(td.raw+=ed.raw,td.text+=ed.text):Ja.push(ed);continue}if(qa){const ud="Infinite loop on byte: "+qa.charCodeAt(0);if(this.options.silent){console.error(ud);break}else throw new Error(ud)}}return Ja}},_Renderer $ 1=class{constructor(qa){n_(this,"options");n_(this,"parser");this.options=qa||_defaults $ 1}space(qa){return""}code({text:qa,lang:Ja,escaped:ed}){var sd;const td=(sd=(Ja||"").match(/^ \S */))==null?void 0:sd[0],rd=qa.replace(/ \n $ /,"")+ `
2024-08-30 15:19:18 +08:00
` ;return td?'<pre><code class="language-'+escape $ 1 $ 2(td)+'">'+(ed?rd:escape $ 1 $ 2(rd,!0))+ ` < / c o d e > < / p r e >
` :"<pre><code>"+(ed?rd:escape $ 1 $ 2(rd,!0))+ ` < / c o d e > < / p r e >
` }blockquote({tokens:qa}){return ` < blockquote >
$ { this . parser . parse ( qa ) } < / b l o c k q u o t e >
` }html({text:qa}){return qa}heading({tokens:qa,depth:Ja}){return ` < h$ { Ja } > $ { this . parser . parseInline ( qa ) } < / h $ { J a } >
` }hr(qa){return ` < hr >
2024-09-03 08:22:14 +08:00
` }list(qa){const Ja=qa.ordered,ed=qa.start;let td="";for(let od=0;od<qa.items.length;od++){const ld=qa.items[od];td+=this.listitem(ld)}const rd=Ja?"ol":"ul",sd=Ja&&ed!==1?' start="'+ed+'"':"";return"<"+rd+sd+ ` >
2024-08-30 15:19:18 +08:00
` +td+"</"+rd+ ` >
` }listitem(qa){let Ja="";if(qa.task){const ed=this.checkbox({checked:!!qa.checked});qa.loose?qa.tokens.length>0&&qa.tokens[0].type==="paragraph"?(qa.tokens[0].text=ed+" "+qa.tokens[0].text,qa.tokens[0].tokens&&qa.tokens[0].tokens.length>0&&qa.tokens[0].tokens[0].type==="text"&&(qa.tokens[0].tokens[0].text=ed+" "+qa.tokens[0].tokens[0].text)):qa.tokens.unshift({type:"text",raw:ed+" ",text:ed+" "}):Ja+=ed+" "}return Ja+=this.parser.parse(qa.tokens,!!qa.loose), ` < li > $ { Ja } < / l i >
` }checkbox({checked:qa}){return"<input "+(qa?'checked="" ':"")+'disabled="" type="checkbox">'}paragraph({tokens:qa}){return ` < p > $ { this . parser . parseInline ( qa ) } < / p >
2024-09-03 08:22:14 +08:00
` }table(qa){let Ja="",ed="";for(let rd=0;rd<qa.header.length;rd++)ed+=this.tablecell(qa.header[rd]);Ja+=this.tablerow({text:ed});let td="";for(let rd=0;rd<qa.rows.length;rd++){const sd=qa.rows[rd];ed="";for(let od=0;od<sd.length;od++)ed+=this.tablecell(sd[od]);td+=this.tablerow({text:ed})}return td&&(td= ` < tbody > $ { td } < / t b o d y > ` ) , ` < t a b l e >
2024-08-27 22:31:52 +08:00
< thead >
2024-08-30 15:19:18 +08:00
` +Ja+ ` < / t h e a d >
` +td+ ` < / t a b l e >
` }tablerow({text:qa}){return ` < tr >
$ { qa } < / t r >
` }tablecell(qa){const Ja=this.parser.parseInline(qa.tokens),ed=qa.header?"th":"td";return(qa.align? ` < $ { ed } align = "${qa.align}" > ` : ` < $ { ed } > ` )+Ja+ ` < / $ { e d } >
2024-09-08 17:22:36 +08:00
` }strong({tokens:qa}){return ` < strong > $ { this . parser . parseInline ( qa ) } < / s t r o n g > ` } e m ( { t o k e n s : q a } ) { r e t u r n ` < e m > $ { t h i s . p a r s e r . p a r s e I n l i n e ( q a ) } < / e m > ` } c o d e s p a n ( { t e x t : q a } ) { r e t u r n ` < c o d e > $ { q a } < / c o d e > ` } b r ( q a ) { r e t u r n " < b r > " } d e l ( { t o k e n s : q a } ) { r e t u r n ` < d e l > $ { t h i s . p a r s e r . p a r s e I n l i n e ( q a ) } < / d e l > ` } l i n k ( { h r e f : q a , t i t l e : J a , t o k e n s : e d } ) { c o n s t t d = t h i s . p a r s e r . p a r s e I n l i n e ( e d ) , r d = c l e a n U r l $ 1 ( q a ) ; i f ( r d = = = n u l l ) r e t u r n t d ; q a = r d ; l e t s d = ' < a h r e f = " ' + q a + ' " ' ; r e t u r n J a & & ( s d + = ' t i t l e = " ' + J a + ' " ' ) , s d + = " > " + t d + " < / a > " , s d } i m a g e ( { h r e f : q a , t i t l e : J a , t e x t : e d } ) { c o n s t t d = c l e a n U r l $ 1 ( q a ) ; i f ( t d = = = n u l l ) r e t u r n e d ; q a = t d ; l e t r d = ` < i m g s r c = " $ { q a } " a l t = " $ { e d } " ` ; r e t u r n J a & & ( r d + = ` t i t l e = " $ { J a } " ` ) , r d + = " > " , r d } t e x t ( q a ) { r e t u r n " t o k e n s " i n q a & & q a . t o k e n s ? t h i s . p a r s e r . p a r s e I n l i n e ( q a . t o k e n s ) : q a . t e x t } } , _ T e x t R e n d e r e r $ 1 = c l a s s { s t r o n g ( { t e x t : q a } ) { r e t u r n q a } e m ( { t e x t : q a } ) { r e t u r n q a } c o d e s p a n ( { t e x t : q a } ) { r e t u r n q a } d e l ( { t e x t : q a } ) { r e t u r n q a } h t m l ( { t e x t : q a } ) { r e t u r n q a } t e x t ( { t e x t : q a } ) { r e t u r n q a } l i n k ( { t e x t : q a } ) { r e t u r n " " + q a } i m a g e ( { t e x t : q a } ) { r e t u r n " " + q a } b r ( ) { r e t u r n " " } } , _ P a r s e r $ 1 = c l a s s x T { c o n s t r u c t o r ( q a ) { n _ ( t h i s , " o p t i o n s " ) ; n _ ( t h i s , " r e n d e r e r " ) ; n _ ( t h i s , " t e x t R e n d e r e r " ) ; t h i s . o p t i o n s = q a | | _ d e f a u l t s $ 1 , t h i s . o p t i o n s . r e n d e r e r = t h i s . o p t i o n s . r e n d e r e r | | n e w _ R e n d e r e r $ 1 , t h i s . r e n d e r e r = t h i s . o p t i o n s . r e n d e r e r , t h i s . r e n d e r e r . o p t i o n s = t h i s . o p t i o n s , t h i s . r e n d e r e r . p a r s e r = t h i s , t h i s . t e x t R e n d e r e r = n e w _ T e x t R e n d e r e r $ 1 } s t a t i c p a r s e ( q a , J a ) { r e t u r n n e w x T ( J a ) . p a r s e ( q a ) } s t a t i c p a r s e I n l i n e ( q a , J a ) { r e t u r n n e w x T ( J a ) . p a r s e I n l i n e ( q a ) } p a r s e ( q a , J a = ! 0 ) { l e t e d = " " ; f o r ( l e t t d = 0 ; t d < q a . l e n g t h ; t d + + ) { c o n s t r d = q a [ t d ] ; i f ( t h i s . o p t i o n s . e x t e n s i o n s & & t h i s . o p t i o n s . e x t e n s i o n s . r e n d e r e r s & & t h i s . o p t i o n s . e x t e n s i o n s . r e n d e r e r s [ r d . t y p e ] ) { c o n s t o d = r d , l d = t h i s . o p t i o n s . e x t e n s i o n s . r e n d e r e r s [ o d . t y p e ] . c a l l ( { p a r s e r : t h i s } , o d ) ; i f ( l d ! = = ! 1 | | ! [ " s p a c e " , " h r " , " h e a d i n g " , " c o d e " , " t a b l e " , " b l o c k q u o t e " , " l i s t " , " h t m l " , " p a r a g r a p h " , " t e x t " ] . i n c l u d e s ( o d . t y p e ) ) { e d + = l d | | " " ; c o n t i n u e } } c o n s t s d = r d ; s w i t c h ( s d . t y p e ) { c a s e " s p a c e " : { e d + = t h i s . r e n d e r e r . s p a c e ( s d ) ; c o n t i n u e } c a s e " h r " : { e d + = t h i s . r e n d e r e r . h r ( s d ) ; c o n t i n u e } c a s e " h e a d i n g " : { e d + = t h i s . r e n d e r e r . h e a d i n g ( s d ) ; c o n t i n u e } c a s e " c o d e " : { e d + = t h i s . r e n d e r e r . c o d e ( s d ) ; c o n t i n u e } c a s e " t a b l e " : { e d + = t h i s . r e n d e r e r . t a b l e ( s d ) ; c o n t i n u e } c a s e " b l o c k q u o t e " : { e d + = t h i s . r e n d e r e r . b l o c k q u o t e ( s d ) ; c o n t i n u e } c a s e " l i s t " : { e d + = t h i s . r e n d e r e r . l i s t ( s d ) ; c o n t i n u e } c a s e " h t m l " : { e d + = t h i s . r e n d e r e r . h t m l ( s d ) ; c o n t i n u e } c a s e " p a r a g r a p h " : { e d + = t h i s . r e n d e r e r . p a r a g r a p h ( s d ) ; c o n t i n u e } c a s e " t e x t " : { l e t o d = s d , l d = t h i s . r e n d e r e r . t e x t ( o d ) ; f o r ( ; t d + 1 < q a . l e n g t h & & q a [ t d + 1 ] . t y p e = = = " t e x t " ; ) o d = q a [ + + t d ] , l d + = `
` +this.renderer.text(od);Ja?ed+=this.renderer.paragraph({type:"paragraph",raw:ld,text:ld,tokens:[{type:"text",raw:ld,text:ld}]}):ed+=ld;continue}default:{const od='Token with "'+sd.type+'" type was not found.';if(this.options.silent)return console.error(od),"";throw new Error(od)}}}return ed}parseInline(qa,Ja){Ja=Ja||this.renderer;let ed="";for(let td=0;td<qa.length;td++){const rd=qa[td];if(this.options.extensions&&this.options.extensions.renderers&&this.options.extensions.renderers[rd.type]){const od=this.options.extensions.renderers[rd.type].call({parser:this},rd);if(od!==!1||!["escape","html","link","image","strong","em","codespan","br","del","text"].includes(rd.type)){ed+=od||"";continue}}const sd=rd;switch(sd.type){case"escape":{ed+=Ja.text(sd);break}case"html":{ed+=Ja.html(sd);break}case"link":{ed+=Ja.link(sd);break}case"image":{ed+=Ja.image(sd);break}case"strong":{ed+=Ja.strong(sd);break}case"em":{ed+=Ja.em(sd);break}case"codespan":{ed+=Ja.codespan(sd);break}case"br":{ed+=Ja.br(sd);break}case"del":{ed+=Ja.del(sd);break}case"text":{ed+=Ja.text(sd);break}default:{const od='Token with "'+sd.type+'" type was not found.';if(this.options.silent)return console.error(od),"";throw new Error(od)}}}return ed}};var TT;let _Hooks $ 1=(TT=class{constructor(qa){n_(this,"options");n_(this,"block");this.options=qa||_defaults $ 1}preprocess(qa){return qa}postprocess(qa){return qa}processAllTokens(qa){return qa}provideLexer(){return this.block?_Lexer $ 1.lex:_Lexer $ 1.lexInline}provideParser(){return this.block?_Parser $ 1.parse:_Parser $ 1.parseInline}},n_(TT,"passThroughHooks",new Set(["preprocess","postprocess","processAllTokens"])),TT),Marked $ 1=class{constructor(...qa){n_(this,"defaults",_getDefaults $ 1());n_(this,"options",this.setOptions);n_(this,"parse",this.parseMarkdown(!0));n_(this,"parseInline",this.parseMarkdown(!1));n_(this,"Parser",_Parser $ 1);n_(this,"Renderer",_Renderer $ 1);n_(this,"TextRenderer",_TextRenderer $ 1);n_(this,"Lexer",_Lexer $ 1);n_(this,"Tokenizer",_Tokenizer $ 1);n_(this,"Hooks",_Hooks $ 1);this.use(...qa)}walkTokens(qa,Ja){var td,rd;let ed=[];for(const sd of qa)switch(ed=ed.concat(Ja.call(this,sd)),sd.type){case"table":{const od=sd;for(const ld of od.header)ed=ed.concat(this.walkTokens(ld.tokens,Ja));for(const ld of od.rows)for(const cd of ld)ed=ed.concat(this.walkTokens(cd.tokens,Ja));break}case"list":{const od=sd;ed=ed.concat(this.walkTokens(od.items,Ja));break}default:{const od=sd;(rd=(td=this.defaults.extensions)==null?void 0:td.childTokens)!=null&&rd[od.type]?this.defaults.extensions.childTokens[od.type].forEach(ld=>{const cd=od[ld].flat(1/0);ed=ed.concat(this.walkTokens(cd,Ja))}):od.tokens&&(ed=ed.concat(this.walkTokens(od.tokens,Ja)))}}return ed}use(...qa){const Ja=this.defaults.extensions||{renderers:{},childTokens:{}};return qa.forEach(ed=>{const td={...ed};if(td.async=this.defaults.async||td.async||!1,ed.extensions&&(ed.extensions.forEach(rd=>{if(!rd.name)throw new Error("extension name required");if("renderer"in rd){const sd=Ja.renderers[rd.name];sd?Ja.renderers[rd.name]=function(...od){let ld=rd.renderer.apply(this,od);return ld===!1&&(ld=sd.apply(this,od)),ld}:Ja.renderers[rd.name]=rd.renderer}if("tokenizer"in rd){if(!rd.level||rd.level!=="block"&&rd.level!=="inline")throw new Error("extension level must be 'block' or 'inline'");const sd=Ja[rd.level];sd?sd.unshift(rd.tokenizer):Ja[rd.level]=[rd.tokenizer],rd.start&&(rd.level==="block"?Ja.startBlock?Ja.startBlock.push(rd.start):Ja.startBlock=[rd.start]:rd.level==="inline"&&(Ja.startInline?Ja.startInline.push(rd.start):Ja.startInline=[rd.start]))}"childTokens"in rd&&rd.childTokens&&(Ja.childTokens[rd.name]=rd.childTokens)}),td.extensions=Ja),ed.renderer){const rd=this.defaults.renderer||new _Renderer $ 1(this.defaults);for(const sd in ed.renderer){if(!(sd in rd))throw new Error( ` renderer '${sd}' does not exist ` );if(["options","parser"].includes(sd))continue;const od=sd,ld=ed.renderer[od],cd=rd[od];rd[od]=(...ud)=>{let _d=ld.apply(rd,ud);return _d===!1&&(_d=cd.apply(rd,ud)),_d||""}}td.renderer=rd}if(ed.tokenizer){const rd=this.defaults.tokenizer||new _Tokenizer $ 1(
Please report this to https : //github.com/markedjs/marked.`,qa){const td="<p>An error occurred:</p><pre>"+escape$1$2(ed.message+"",!0)+"</pre>";return Ja?Promise.resolve(td):td}if(Ja)return Promise.reject(ed);throw ed}}};const markedInstance$1=new Marked$1;function marked$1(Ra,qa){return markedInstance$1.parse(Ra,qa)}marked$1.options=marked$1.setOptions=function(Ra){return markedInstance$1.setOptions(Ra),marked$1.defaults=markedInstance$1.defaults,changeDefaults$1(marked$1.defaults),marked$1};marked$1.getDefaults=_getDefaults$1;marked$1.defaults=_defaults$1;marked$1.use=function(...Ra){return markedInstance$1.use(...Ra),marked$1.defaults=markedInstance$1.defaults,changeDefaults$1(marked$1.defaults),marked$1};marked$1.walkTokens=function(Ra,qa){return markedInstance$1.walkTokens(Ra,qa)};marked$1.parseInline=markedInstance$1.parseInline;marked$1.Parser=_Parser$1;marked$1.parser=_Parser$1.parse;marked$1.Renderer=_Renderer$1;marked$1.TextRenderer=_TextRenderer$1;marked$1.Lexer=_Lexer$1;marked$1.lexer=_Lexer$1.lex;marked$1.Tokenizer=_Tokenizer$1;marked$1.Hooks=_Hooks$1;marked$1.parse=marked$1;marked$1.options;marked$1.setOptions;marked$1.use;marked$1.walkTokens;marked$1.parseInline;_Parser$1.parse;_Lexer$1.lex;var commonjsGlobal=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function getDefaultExportFromCjs(Ra){return Ra&&Ra.__esModule&&Object.prototype.hasOwnProperty.call(Ra,"default")?Ra.default:Ra}function getAugmentedNamespace(Ra){if(Ra.__esModule)return Ra;var qa=Ra.default;if(typeof qa=="function"){var Ja=function ed(){return this instanceof ed?Reflect.construct(qa,arguments,this.constructor):qa.apply(this,arguments)};Ja.prototype=qa.prototype}else Ja={};return Object.defineProperty(Ja,"__esModule",{value:!0}),Object.keys(Ra).forEach(function(ed){var td=Object.getOwnPropertyDescriptor(Ra,ed);Object.defineProperty(Ja,ed,td.get?td:{enumerable:!0,get:function(){return Ra[ed]}})}),Ja}var codemirror={exports:{}},hasRequiredCodemirror;function requireCodemirror(){return hasRequiredCodemirror||(hasRequiredCodemirror=1,function(Ra,qa){(function(Ja,ed){Ra.exports=ed()})(commonjsGlobal,function(){var Ja=navigator.userAgent,ed=navigator.platform,td=/gecko\/\d/i.test(Ja),rd=/MSIE \d/.test(Ja),sd=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(Ja),od=/Edge\/(\d+)/.exec(Ja),ld=rd||sd||od,cd=ld&&(rd?document.documentMode||6:+(od||sd)[1]),ud=!od&&/WebKit\//.test(Ja),_d=ud&&/Qt\/\d+\.\d+/.test(Ja),yd=!od&&/Chrome\/(\d+)/.exec(Ja),gd=yd&&+yd[1],Ed=/Opera\//.test(Ja),Td=/Apple Computer/.test(navigator.vendor),Od=/Mac OS X 1\d\D([8-9]|\d\d)\D/.test(Ja),Rd=/PhantomJS/.test(Ja),Nd=Td&&(/Mobile\/\w+/.test(Ja)||navigator.maxTouchPoints>2),Id=/Android/.test(Ja),Md=Nd||Id||/webOS|BlackBerry|Opera Mini|Opera Mobi|IEMobile/i.test(Ja),Ld=Nd||/Mac/.test(ed),Pd=/\bCrOS\b/.test(Ja),qd=/win/i.test(ed),Yd=Ed&&Ja.match(/Version\/(\d*\.\d*)/);Yd&&(Yd=Number(Yd[1])),Yd&&Yd>=15&&(Ed=!1,ud=!0);var Ud=Ld&&(_d||Ed&&(Yd==null||Yd<12.11)),Hd=td||ld&&cd>=9;function zd(Ad){return new RegExp("(^|\\s)"+Ad+"(?:$|\\s)\\s*")}var Jd=function(Ad,Bd){var Wd=Ad.className,Gd=zd(Bd).exec(Wd);if(Gd){var Xd=Wd.slice(Gd.index+Gd[0].length);Ad.className=Wd.slice(0,Gd.index)+(Xd?Gd[1]+Xd:"")}};function Zd(Ad){for(var Bd=Ad.childNodes.length;Bd>0;--Bd)Ad.removeChild(Ad.firstChild);return Ad}function pf(Ad,Bd){return Zd(Ad).appendChild(Bd)}function Qd(Ad,Bd,Wd,Gd){var Xd=document.createElement(Ad);if(Wd&&(Xd.className=Wd),Gd&&(Xd.style.cssText=Gd),typeof Bd=="string")Xd.appendChild(document.createTextNode(Bd));else if(Bd)for(var yf=0;yf<Bd.length;++yf)Xd.appendChild(Bd[yf]);return Xd}function hf(Ad,Bd,Wd,Gd){var Xd=Qd(Ad,Bd,Wd,Gd);return Xd.setAttribute("role","presentation"),Xd}var mf;document.createRange?mf=function(Ad,Bd,Wd,Gd){var Xd=document.createRange();return Xd.setEnd(Gd||Ad,Wd),Xd.setStart(Ad,Bd),Xd}:mf=function(Ad,Bd,Wd){var Gd=document.body.createTextRange();try{Gd.moveToElementText(Ad.parentNode)}catch{return Gd}return Gd.collapse(!0),Gd.moveEnd("character",Wd),Gd.moveStart("character",Bd),Gd};function xf(Ad,Bd){
2024-09-07 10:27:05 +08:00
2024-09-08 17:22:36 +08:00
b ` .split(/ \n /).length!=3?function(Ad){for(var Bd=0,Wd=[],Gd=Ad.length;Bd<=Gd;){var Xd=Ad.indexOf( `
` ,Bd);Xd==-1&&(Xd=Ad.length);var yf=Ad.slice(Bd,Ad.charAt(Xd-1)==" \r "?Xd-1:Xd),kf=yf.indexOf(" \r ");kf!=-1?(Wd.push(yf.slice(0,kf)),Bd+=kf+1):(Wd.push(yf),Bd=Xd+1)}return Wd}:function(Ad){return Ad.split(/ \r \n ?| \n /)},bh=window.getSelection?function(Ad){try{return Ad.selectionStart!=Ad.selectionEnd}catch{return!1}}:function(Ad){var Bd;try{Bd=Ad.ownerDocument.selection.createRange()}catch{}return!Bd||Bd.parentElement()!=Ad?!1:Bd.compareEndPoints("StartToEnd",Bd)!=0},sh=function(){var Ad=Qd("div");return"oncopy"in Ad?!0:(Ad.setAttribute("oncopy","return;"),typeof Ad.oncopy=="function")}(),yh=null;function Lh(Ad){if(yh!=null)return yh;var Bd=pf(Ad,Qd("span","x")),Wd=Bd.getBoundingClientRect(),Gd=mf(Bd,0,1).getBoundingClientRect();return yh=Math.abs(Wd.left-Gd.left)>1}var kh={},Hh={};function $ h(Ad,Bd){arguments.length>2&&(Bd.dependencies=Array.prototype.slice.call(arguments,2)),kh[Ad]=Bd}function wh(Ad,Bd){Hh[Ad]=Bd}function um(Ad){if(typeof Ad=="string"&&Hh.hasOwnProperty(Ad))Ad=Hh[Ad];else if(Ad&&typeof Ad.name=="string"&&Hh.hasOwnProperty(Ad.name)){var Bd=Hh[Ad.name];typeof Bd=="string"&&(Bd={name:Bd}),Ad=Nh(Bd,Ad),Ad.name=Bd.name}else{if(typeof Ad=="string"&&/^[ \w \- ]+ \/ [ \w \- ]+ \+ xml $ /.test(Ad))return um("application/xml");if(typeof Ad=="string"&&/^[ \w \- ]+ \/ [ \w \- ]+ \+ json $ /.test(Ad))return um("application/json")}return typeof Ad=="string"?{name:Ad}:Ad||{name:"null"}}function cm(Ad,Bd){Bd=um(Bd);var Wd=kh[Bd.name];if(!Wd)return cm(Ad,"text/plain");var Gd=Wd(Ad,Bd);if(_m.hasOwnProperty(Bd.name)){var Xd=_m[Bd.name];for(var yf in Xd)Xd.hasOwnProperty(yf)&&(Gd.hasOwnProperty(yf)&&(Gd["_"+yf]=Gd[yf]),Gd[yf]=Xd[yf])}if(Gd.name=Bd.name,Bd.helperType&&(Gd.helperType=Bd.helperType),Bd.modeProps)for(var kf in Bd.modeProps)Gd[kf]=Bd.modeProps[kf];return Gd}var _m={};function Ff(Ad,Bd){var Wd=_m.hasOwnProperty(Ad)?_m[Ad]:_m[Ad]={};_f(Bd,Wd)}function Om(Ad,Bd){if(Bd===!0)return Bd;if(Ad.copyState)return Ad.copyState(Bd);var Wd={};for(var Gd in Bd){var Xd=Bd[Gd];Xd instanceof Array&&(Xd=Xd.concat([])),Wd[Gd]=Xd}return Wd}function m_(Ad,Bd){for(var Wd;Ad.innerMode&&(Wd=Ad.innerMode(Bd),!(!Wd||Wd.mode==Ad));)Bd=Wd.state,Ad=Wd.mode;return Wd||{mode:Ad,state:Bd}}function f_(Ad,Bd,Wd){return Ad.startState?Ad.startState(Bd,Wd):!0}var a_=function(Ad,Bd,Wd){this.pos=this.start=0,this.string=Ad,this.tabSize=Bd||8,this.lastColumnPos=this.lastColumnValue=0,this.lineStart=0,this.lineOracle=Wd};a_.prototype.eol=function(){return this.pos>=this.string.length},a_.prototype.sol=function(){return this.pos==this.lineStart},a_.prototype.peek=function(){return this.string.charAt(this.pos)||void 0},a_.prototype.next=function(){if(this.pos<this.string.length)return this.string.charAt(this.pos++)},a_.prototype.eat=function(Ad){var Bd=this.string.charAt(this.pos),Wd;if(typeof Ad=="string"?Wd=Bd==Ad:Wd=Bd&&(Ad.test?Ad.test(Bd):Ad(Bd)),Wd)return++this.pos,Bd},a_.prototype.eatWhile=function(Ad){for(var Bd=this.pos;this.eat(Ad););return this.pos>Bd},a_.prototype.eatSpace=function(){for(var Ad=this.pos;/[ \s \u 00a0]/.test(this.string.charAt(this.pos));)++this.pos;return this.pos>Ad},a_.prototype.skipToEnd=function(){this.pos=this.string.length},a_.prototype.skipTo=function(Ad){var Bd=this.string.indexOf(Ad,this.pos);if(Bd>-1)return this.pos=Bd,!0},a_.prototype.backUp=function(Ad){this.pos-=Ad},a_.prototype.column=function(){return this.lastColumnPos<this.start&&(this.lastColumnValue= $ f(this.string,this.start,this.tabSize,this.lastColumnPos,this.lastColumnValue),this.lastColumnPos=this.start),this.lastColumnValue-(this.lineStart? $ f(this.string,this.lineStart,this.tabSize):0)},a_.prototype.indentation=function(){return $ f(this.string,null,this.tabSize)-(this.lineStart? $ f(this.string,this.lineStart,this.tabSize):0)},a_.prototype.match=function(Ad,Bd,Wd){if(typeof Ad=="string"){var Gd=function(kf){return Wd?kf.toLowerCase():kf},Xd=this.string.substr(this.pos,Ad.length);if(Gd(Xd)==Gd(Ad))return Bd!==!1&&(this.pos+=Ad.length),!0}else{var yf=this.string.slice(this.pos).match(Ad);return yf&&yf.index>0?null:(yf&&Bd!==!1&&(this.pos+=yf[0].length),yf)}},a_.prototype.current=funct
` ?(Nm=Ih.appendChild(Qd("span",Kh[0]==" \r "?"␍":"","cm-invalidchar")),Nm.setAttribute("cm-text",Kh[0]),Ad.col+=1):(Nm=Ad.cm.options.specialCharPlaceholder(Kh[0]),Nm.setAttribute("cm-text",Kh[0]),ld&&cd<9?Ih.appendChild(Qd("span",[Nm])):Ih.appendChild(Nm),Ad.col+=1);Ad.map.push(Ad.pos,Ad.pos+1,Nm),Ad.pos++}}if(Ad.trailingSpace=qf.charCodeAt(Bd.length-1)==32,Wd||Gd||Xd||ch||yf||kf){var Qm=Wd||"";Gd&&(Qm+=Gd),Xd&&(Qm+=Xd);var Ym=Qd("span",[Ih],Qm,yf);if(kf)for(var e_ in kf)kf.hasOwnProperty(e_)&&e_!="style"&&e_!="class"&&Ym.setAttribute(e_,kf[e_]);return Ad.content.appendChild(Ym)}Ad.content.appendChild(Ih)}}function Eb(Ad,Bd){if(Ad.length>1&&!/ /.test(Ad))return Ad;for(var Wd=Bd,Gd="",Xd=0;Xd<Ad.length;Xd++){var yf=Ad.charAt(Xd);yf==" "&&Wd&&(Xd==Ad.length-1||Ad.charCodeAt(Xd+1)==32)&&(yf=" "),Gd+=yf,Wd=yf==" "}return Gd}function a1(Ad,Bd){return function(Wd,Gd,Xd,yf,kf,qf,Qf){Xd=Xd?Xd+" cm-force-border":"cm-force-border";for(var ch=Wd.pos,Ih=ch+Gd.length;;){for(var Uh=void 0,Kh=0;Kh<Bd.length&&(Uh=Bd[Kh],!(Uh.to>ch&&Uh.from<=ch));Kh++);if(Uh.to>=Ih)return Ad(Wd,Gd,Xd,yf,kf,qf,Qf);Ad(Wd,Gd.slice(0,Uh.to-ch),Xd,yf,null,qf,Qf),yf=null,Gd=Gd.slice(Uh.to-ch),ch=Uh.to}}}function Ig(Ad,Bd,Wd,Gd){var Xd=!Gd&&Wd.widgetNode;Xd&&Ad.map.push(Ad.pos,Ad.pos+Bd,Xd),!Gd&&Ad.cm.display.input.needsContentAttribute&&(Xd||(Xd=Ad.content.appendChild(document.createElement("span"))),Xd.setAttribute("cm-marker",Wd.id)),Xd&&(Ad.cm.display.input.setUneditable(Xd),Ad.content.appendChild(Xd)),Ad.pos+=Bd,Ad.trailingSpace=!1}function Jb(Ad,Bd,Wd){var Gd=Ad.markedSpans,Xd=Ad.text,yf=0;if(!Gd){for(var kf=1;kf<Wd.length;kf+=2)Bd.addToken(Bd,Xd.slice(yf,yf=Wd[kf]),T1(Wd[kf+1],Bd.cm.options));return}for(var qf=Xd.length,Qf=0,ch=1,Ih="",Uh,Kh,Yh=0,hm,Nm,Hm,Km,Qm;;){if(Yh==Qf){hm=Nm=Hm=Kh="",Qm=null,Km=null,Yh=1/0;for(var Ym=[],e_=void 0,c_=0;c_<Gd.length;++c_){var l_=Gd[c_],D_=l_.marker;if(D_.type=="bookmark"&&l_.from==Qf&&D_.widgetNode)Ym.push(D_);else if(l_.from<=Qf&&(l_.to==null||l_.to>Qf||D_.collapsed&&l_.to==Qf&&l_.from==Qf)){if(l_.to!=null&&l_.to!=Qf&&Yh>l_.to&&(Yh=l_.to,Nm=""),D_.className&&(hm+=" "+D_.className),D_.css&&(Kh=(Kh?Kh+";":"")+D_.css),D_.startStyle&&l_.from==Qf&&(Hm+=" "+D_.startStyle),D_.endStyle&&l_.to==Yh&&(e_||(e_=[])).push(D_.endStyle,l_.to),D_.title&&((Qm||(Qm={})).title=D_.title),D_.attributes)for(var r1 in D_.attributes)(Qm||(Qm={}))[r1]=D_.attributes[r1];D_.collapsed&&(!Km||T0(Km.marker,D_)<0)&&(Km=l_)}else l_.from>Qf&&Yh>l_.from&&(Yh=l_.from)}if(e_)for(var v1=0;v1<e_.length;v1+=2)e_[v1+1]==Yh&&(Nm+=" "+e_[v1]);if(!Km||Km.from==Qf)for(var s1=0;s1<Ym.length;++s1)Ig(Bd,0,Ym[s1]);if(Km&&(Km.from||0)==Qf){if(Ig(Bd,(Km.to==null?qf+1:Km.to)-Qf,Km.marker,Km.from==null),Km.to==null)return;Km.to==Qf&&(Km=!1)}}if(Qf>=qf)break;for(var h1=Math.min(qf,Yh);;){if(Ih){var S1=Qf+Ih.length;if(!Km){var x1=S1>h1?Ih.slice(0,h1-Qf):Ih;Bd.addToken(Bd,x1,Uh?Uh+hm:hm,Hm,Qf+x1.length==Yh?Nm:"",Kh,Qm)}if(S1>=h1){Ih=Ih.slice(h1-Qf),Qf=h1;break}Qf=S1,Hm=""}Ih=Xd.slice(yf,yf=Wd[ch++]),Uh=T1(Wd[ch++],Bd.cm.options)}}}function wv(Ad,Bd,Wd){this.line=Bd,this.rest=Rg(Bd),this.size=this.rest?oh(hh(this.rest))-Wd+1:1,this.node=this.text=null,this.hidden=l1(Ad,Bd)}function S0(Ad,Bd,Wd){for(var Gd=[],Xd,yf=Bd;yf<Wd;yf=Xd){var kf=new wv(Ad.doc,Dm(Ad.doc,yf),yf);Xd=yf+kf.size,Gd.push(kf)}return Gd}var Eg=null;function Av(Ad){Eg?Eg.ops.push(Ad):Ad.ownsGroup=Eg={ops:[Ad],delayedCallbacks:[]}}function Iy(Ad){var Bd=Ad.delayedCallbacks,Wd=0;do{for(;Wd<Bd.length;Wd++)Bd[Wd].call(null);for(var Gd=0;Gd<Ad.ops.length;Gd++){var Xd=Ad.ops[Gd];if(Xd.cursorActivityHandlers)for(;Xd.cursorActivityCalled<Xd.cursorActivityHandlers.length;)Xd.cursorActivityHandlers[Xd.cursorActivityCalled++].call(null,Xd.cm)}}while(Wd<Bd.length)}function jd(Ad,Bd){var Wd=Ad.ownsGroup;if(Wd)try{Iy(Wd)}finally{Eg=null,Bd(Wd)}}var kd=null;function Vd(Ad,Bd){var Wd=Vm(Ad,Bd);if(Wd.length){var Gd=Array.prototype.slice.call(arguments,2),Xd;Eg?Xd=Eg.delayedCallbacks:kd?Xd=kd:(Xd=kd=[],setTimeout(df,0));for(var yf=function(qf){Xd.push(function(){return Wd[qf].apply(null,Gd)})},kf=0;kf<Wd.length;++kf)y
2024-09-07 10:27:05 +08:00
top : ` +e_+"px; width: "+(c_??Qf-Ym)+ ` px ;
2024-09-08 17:22:36 +08:00
height : ` +(l_-e_)+"px"))}function Uh(Ym,e_,c_){var l_=Dm(Xd,Ym),D_=l_.text.length,r1,v1;function s1(x1,Y1){return Tm(Ad,am(Ym,x1),"div",l_,Y1)}function h1(x1,Y1,H1){var R1=n1(Ad,l_,null,x1),C1=Y1=="ltr"==(H1=="after")?"left":"right",m1=H1=="after"?R1.begin:R1.end-(/ \s /.test(l_.text.charAt(R1.end-1))?2:1);return s1(m1,C1)[C1]}var S1=Xh(l_,Xd.direction);return Zf(S1,e_||0,c_??D_,function(x1,Y1,H1,R1){var C1=H1=="ltr",m1=s1(x1,C1?"left":"right"),J1=s1(Y1-1,C1?"right":"left"),Yb=e_==null&&x1==0,B0=c_==null&&Y1==D_,G1=R1==0,n0=!S1||R1==S1.length-1;if(J1.top-m1.top<=3){var B1=(ch?Yb:B0)&&G1,CE=(ch?B0:Yb)&&n0,i0=B1?qf:(C1?m1:J1).left,P0=CE?Qf:(C1?J1:m1).right;Ih(i0,m1.top,P0-i0,m1.bottom)}else{var F0,K1,Kb,wE;C1?(F0=ch&&Yb&&G1?qf:m1.left,K1=ch?Qf:h1(x1,H1,"before"),Kb=ch?qf:h1(Y1,H1,"after"),wE=ch&&B0&&n0?Qf:J1.right):(F0=ch?h1(x1,H1,"before"):qf,K1=!ch&&Yb&&G1?Qf:m1.right,Kb=!ch&&B0&&n0?qf:J1.left,wE=ch?h1(Y1,H1,"after"):Qf),Ih(F0,m1.top,K1-F0,m1.bottom),m1.bottom<J1.top&&Ih(qf,m1.bottom,null,J1.top),Ih(Kb,J1.top,wE-Kb,J1.bottom)}(!r1||Q0(m1,r1)<0)&&(r1=m1),Q0(J1,r1)<0&&(r1=J1),(!v1||Q0(m1,v1)<0)&&(v1=m1),Q0(J1,v1)<0&&(v1=J1)}),{start:r1,end:v1}}var Kh=Bd.from(),Yh=Bd.to();if(Kh.line==Yh.line)Uh(Kh.line,Kh.ch,Yh.ch);else{var hm=Dm(Xd,Kh.line),Nm=Dm(Xd,Yh.line),Hm=z_(hm)==z_(Nm),Km=Uh(Kh.line,Kh.ch,Hm?hm.text.length+1:null).end,Qm=Uh(Yh.line,Hm?0:null,Yh.ch).start;Hm&&(Km.top<Qm.top-2?(Ih(Km.right,Km.top,null,Km.bottom),Ih(qf,Qm.top,Qm.left,Qm.bottom)):Ih(Km.right,Km.top,Qm.left-Km.right,Km.bottom)),Km.bottom<Qm.top&&Ih(qf,Km.bottom,null,Qm.top)}Wd.appendChild(yf)}function J0(Ad){if(Ad.state.focused){var Bd=Ad.display;clearInterval(Bd.blinker);var Wd=!0;Bd.cursorDiv.style.visibility="",Ad.options.cursorBlinkRate>0?Bd.blinker=setInterval(function(){Ad.hasFocus()||Ab(Ad),Bd.cursorDiv.style.visibility=(Wd=!Wd)?"":"hidden"},Ad.options.cursorBlinkRate):Ad.options.cursorBlinkRate<0&&(Bd.cursorDiv.style.visibility="hidden")}}function w0(Ad){Ad.hasFocus()||(Ad.display.input.focus(),Ad.state.focused||zy(Ad))}function wb(Ad){Ad.state.delayingBlurEvent=!0,setTimeout(function(){Ad.state.delayingBlurEvent&&(Ad.state.delayingBlurEvent=!1,Ad.state.focused&&Ab(Ad))},100)}function zy(Ad,Bd){Ad.state.delayingBlurEvent&&!Ad.state.draggingText&&(Ad.state.delayingBlurEvent=!1),Ad.options.readOnly!="nocursor"&&(Ad.state.focused||(Mm(Ad,"focus",Ad,Bd),Ad.state.focused=!0,Kf(Ad.display.wrapper,"CodeMirror-focused"),!Ad.curOp&&Ad.display.selForContextMenu!=Ad.doc.sel&&(Ad.display.input.reset(),ud&&setTimeout(function(){return Ad.display.input.reset(!0)},20)),Ad.display.input.receivedFocus()),J0(Ad))}function Ab(Ad,Bd){Ad.state.delayingBlurEvent||(Ad.state.focused&&(Mm(Ad,"blur",Ad,Bd),Ad.state.focused=!1,Jd(Ad.display.wrapper,"CodeMirror-focused")),clearInterval(Ad.display.blinker),setTimeout(function(){Ad.state.focused||(Ad.display.shift=!1)},150))}function $ v(Ad){for(var Bd=Ad.display,Wd=Bd.lineDiv.offsetTop,Gd=Math.max(0,Bd.scroller.getBoundingClientRect().top),Xd=Bd.lineDiv.getBoundingClientRect().top,yf=0,kf=0;kf<Bd.view.length;kf++){var qf=Bd.view[kf],Qf=Ad.options.lineWrapping,ch=void 0,Ih=0;if(!qf.hidden){if(Xd+=qf.line.height,ld&&cd<8){var Uh=qf.node.offsetTop+qf.node.offsetHeight;ch=Uh-Wd,Wd=Uh}else{var Kh=qf.node.getBoundingClientRect();ch=Kh.bottom-Kh.top,!Qf&&qf.text.firstChild&&(Ih=qf.text.firstChild.getBoundingClientRect().right-Kh.left-1)}var Yh=qf.line.height-ch;if((Yh>.005||Yh<-.005)&&(Xd<Gd&&(yf-=Yh),o_(qf.line,ch),tv(qf.line),qf.rest))for(var hm=0;hm<qf.rest.length;hm++)tv(qf.rest[hm]);if(Ih>Ad.display.sizerWidth){var Nm=Math.ceil(Ih/p0(Ad.display));Nm>Ad.display.maxLineLength&&(Ad.display.maxLineLength=Nm,Ad.display.maxLine=qf.line,Ad.display.maxLineChanged=!0)}}}Math.abs(yf)>2&&(Bd.scroller.scrollTop+=yf)}function tv(Ad){if(Ad.widgets)for(var Bd=0;Bd<Ad.widgets.length;++Bd){var Wd=Ad.widgets[Bd],Gd=Wd.node.parentNode;Gd&&(Wd.height=Gd.offsetHeight)}}function Z0(Ad,Bd,Wd){var Gd=Wd&&Wd.top!=null?Math.max(0,Wd.top):Ad.scroller.scrollTop;Gd=Math.floor(Gd-O1(Ad));var Xd=Wd&&Wd.bottom!=null?Wd.bottom:Gd+Ad
top : ` +(Bd.top-Wd.viewOffset-O1(Ad.display))+ ` px ;
height : ` +(Bd.bottom-Bd.top+Xg(Ad)+Wd.barHeight)+ ` px ;
left : ` +Bd.left+"px; width: "+Math.max(2,Bd.right-Bd.left)+"px;");Ad.display.lineSpace.appendChild(kf),kf.scrollIntoView(Xd),Ad.display.lineSpace.removeChild(kf)}}}function $ 2(Ad,Bd,Wd,Gd){Gd==null&&(Gd=0);var Xd;!Ad.options.lineWrapping&&Bd==Wd&&(Wd=Bd.sticky=="before"?am(Bd.line,Bd.ch+1,"before"):Bd,Bd=Bd.ch?am(Bd.line,Bd.sticky=="before"?Bd.ch-1:Bd.ch,"after"):Bd);for(var yf=0;yf<5;yf++){var kf=!1,qf=dm(Ad,Bd),Qf=!Wd||Wd==Bd?qf:dm(Ad,Wd);Xd={left:Math.min(qf.left,Qf.left),top:Math.min(qf.top,Qf.top)-Gd,right:Math.max(qf.left,Qf.left),bottom:Math.max(qf.bottom,Qf.bottom)+Gd};var ch=Ky(Ad,Xd),Ih=Ad.doc.scrollTop,Uh=Ad.doc.scrollLeft;if(ch.scrollTop!=null&&(rv(Ad,ch.scrollTop),Math.abs(Ad.doc.scrollTop-Ih)>1&&(kf=!0)),ch.scrollLeft!=null&&(Lg(Ad,ch.scrollLeft),Math.abs(Ad.doc.scrollLeft-Uh)>1&&(kf=!0)),!kf)break}return Xd}function BE(Ad,Bd){var Wd=Ky(Ad,Bd);Wd.scrollTop!=null&&rv(Ad,Wd.scrollTop),Wd.scrollLeft!=null&&Lg(Ad,Wd.scrollLeft)}function Ky(Ad,Bd){var Wd=Ad.display,Gd=kg(Ad.display);Bd.top<0&&(Bd.top=0);var Xd=Ad.curOp&&Ad.curOp.scrollTop!=null?Ad.curOp.scrollTop:Wd.scroller.scrollTop,yf= $ y(Ad),kf={};Bd.bottom-Bd.top>yf&&(Bd.bottom=Bd.top+yf);var qf=Ad.doc.height+W0(Wd),Qf=Bd.top<Gd,ch=Bd.bottom>qf-Gd;if(Bd.top<Xd)kf.scrollTop=Qf?0:Bd.top;else if(Bd.bottom>Xd+yf){var Ih=Math.min(Bd.top,(ch?qf:Bd.bottom)-yf);Ih!=Xd&&(kf.scrollTop=Ih)}var Uh=Ad.options.fixedGutter?0:Wd.gutters.offsetWidth,Kh=Ad.curOp&&Ad.curOp.scrollLeft!=null?Ad.curOp.scrollLeft:Wd.scroller.scrollLeft-Uh,Yh=Y0(Ad)-Wd.gutters.offsetWidth,hm=Bd.right-Bd.left>Yh;return hm&&(Bd.right=Bd.left+Yh),Bd.left<10?kf.scrollLeft=0:Bd.left<Kh?kf.scrollLeft=Math.max(0,Bd.left+Uh-(hm?0:10)):Bd.right>Yh+Kh-3&&(kf.scrollLeft=Bd.right+(hm?0:10)-Yh),kf}function Xy(Ad,Bd){Bd!=null&&(Mv(Ad),Ad.curOp.scrollTop=(Ad.curOp.scrollTop==null?Ad.doc.scrollTop:Ad.curOp.scrollTop)+Bd)}function c1(Ad){Mv(Ad);var Bd=Ad.getCursor();Ad.curOp.scrollToPos={from:Bd,to:Bd,margin:Ad.options.cursorScrollMargin}}function D1(Ad,Bd,Wd){(Bd!=null||Wd!=null)&&Mv(Ad),Bd!=null&&(Ad.curOp.scrollLeft=Bd),Wd!=null&&(Ad.curOp.scrollTop=Wd)}function M2(Ad,Bd){Mv(Ad),Ad.curOp.scrollToPos=Bd}function Mv(Ad){var Bd=Ad.curOp.scrollToPos;if(Bd){Ad.curOp.scrollToPos=null;var Wd=i_(Ad,Bd.from),Gd=i_(Ad,Bd.to);Qy(Ad,Wd,Gd,Bd.margin)}}function Qy(Ad,Bd,Wd,Gd){var Xd=Ky(Ad,{left:Math.min(Bd.left,Wd.left),top:Math.min(Bd.top,Wd.top)-Gd,right:Math.max(Bd.right,Wd.right),bottom:Math.max(Bd.bottom,Wd.bottom)+Gd});D1(Ad,Xd.scrollLeft,Xd.scrollTop)}function rv(Ad,Bd){Math.abs(Ad.doc.scrollTop-Bd)<2||(td||Bg(Ad,{top:Bd}),Lv(Ad,Bd,!0),td&&Bg(Ad),av(Ad,100))}function Lv(Ad,Bd,Wd){Bd=Math.max(0,Math.min(Ad.display.scroller.scrollHeight-Ad.display.scroller.clientHeight,Bd)),!(Ad.display.scroller.scrollTop==Bd&&!Wd)&&(Ad.doc.scrollTop=Bd,Ad.display.scrollbars.setScrollTop(Bd),Ad.display.scroller.scrollTop!=Bd&&(Ad.display.scroller.scrollTop=Bd))}function Lg(Ad,Bd,Wd,Gd){Bd=Math.max(0,Math.min(Bd,Ad.display.scroller.scrollWidth-Ad.display.scroller.clientWidth)),!((Wd?Bd==Ad.doc.scrollLeft:Math.abs(Ad.doc.scrollLeft-Bd)<2)&&!Gd)&&(Ad.doc.scrollLeft=Bd,UE(Ad),Ad.display.scroller.scrollLeft!=Bd&&(Ad.display.scroller.scrollLeft=Bd),Ad.display.scrollbars.setScrollLeft(Bd))}function eb(Ad){var Bd=Ad.display,Wd=Bd.gutters.offsetWidth,Gd=Math.round(Ad.doc.height+W0(Ad.display));return{clientHeight:Bd.scroller.clientHeight,viewHeight:Bd.wrapper.clientHeight,scrollWidth:Bd.scroller.scrollWidth,clientWidth:Bd.scroller.clientWidth,viewWidth:Bd.wrapper.clientWidth,barLeft:Ad.options.fixedGutter?Wd:0,docHeight:Gd,scrollHeight:Gd+Xg(Ad)+Bd.barHeight,nativeBarWidth:Bd.nativeBarWidth,gutterWidth:Wd}}var Sg=function(Ad,Bd,Wd){this.cm=Wd;var Gd=this.vert=Qd("div",[Qd("div",null,null,"min-width: 1px")],"CodeMirror-vscrollbar"),Xd=this.horiz=Qd("div",[Qd("div",null,null,"height: 100%; min-height: 1px")],"CodeMirror-hscrollbar");Gd.tabIndex=Xd.tabIndex=-1,Ad(Gd),Ad(Xd),om(Gd,"scroll",function(){Gd.clientHeight&&Bd(Gd.scrollTop,"vertical")}),om(Xd,"scroll",function(){Xd.clientWidth&&Bd(Xd.scrollLeft,"horizontal")}),thi
` },setDirection:k1(function(Ad){Ad!="rtl"&&(Ad="ltr"),Ad!=this.direction&&(this.direction=Ad,this.iter(function(Bd){return Bd.order=null}),this.cm&&m0(this.cm))})}),W1.prototype.eachLine=W1.prototype.iter;var Vv=0;function K2(Ad){var Bd=this;if(o2(Bd),!(Jm(Bd,Ad)||W_(Bd.display,Ad))){Xm(Ad),ld&&(Vv=+new Date);var Wd=Qg(Bd,Ad,!0),Gd=Ad.dataTransfer.files;if(!(!Wd||Bd.isReadOnly()))if(Gd&&Gd.length&&window.FileReader&&window.File)for(var Xd=Gd.length,yf=Array(Xd),kf=0,qf=function(){++kf==Xd&&e1(Bd,function(){Wd=h_(Bd.doc,Wd);var Yh={from:Wd,to:Wd,text:Bd.doc.splitLines(yf.filter(function(hm){return hm!=null}).join(Bd.doc.lineSeparator())),origin:"paste"};Bb(Bd.doc,Yh),I0(Bd.doc,N0(h_(Bd.doc,Wd),h_(Bd.doc,D0(Yh))))})()},Qf=function(Yh,hm){if(Bd.options.allowDropFileTypes&&dh(Bd.options.allowDropFileTypes,Yh.type)==-1){qf();return}var Nm=new FileReader;Nm.onerror=function(){return qf()},Nm.onload=function(){var Hm=Nm.result;if(/[ \x 00- \x 08 \x 0e- \x 1f]{2}/.test(Hm)){qf();return}yf[hm]=Hm,qf()},Nm.readAsText(Yh)},ch=0;ch<Gd.length;ch++)Qf(Gd[ch],ch);else{if(Bd.state.draggingText&&Bd.doc.sel.contains(Wd)>-1){Bd.state.draggingText(Ad),setTimeout(function(){return Bd.display.input.focus()},20);return}try{var Ih=Ad.dataTransfer.getData("Text");if(Ih){var Uh;if(Bd.state.draggingText&&!Bd.state.draggingText.copy&&(Uh=Bd.listSelections()),q1(Bd.doc,N0(Wd,Wd)),Uh)for(var Kh=0;Kh<Uh.length;++Kh)sb(Bd.doc,"",Uh[Kh].anchor,Uh[Kh].head,"drag");Bd.replaceSelection(Ih,"around","paste"),Bd.display.input.focus()}}catch{}}}}function fE(Ad,Bd){if(ld&&(!Ad.state.draggingText||+new Date-Vv<100)){G_(Bd);return}if(!(Jm(Ad,Bd)||W_(Ad.display,Bd))&&(Bd.dataTransfer.setData("Text",Ad.getSelection()),Bd.dataTransfer.effectAllowed="copyMove",Bd.dataTransfer.setDragImage&&!Td)){var Wd=Qd("img",null,null,"position: fixed; left: 0; top: 0;");Wd.src="data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==",Ed&&(Wd.width=Wd.height=1,Ad.display.wrapper.appendChild(Wd),Wd._top=Wd.offsetTop),Bd.dataTransfer.setDragImage(Wd,0,0),Ed&&Wd.parentNode.removeChild(Wd)}}function $ _(Ad,Bd){var Wd=Qg(Ad,Bd);if(Wd){var Gd=document.createDocumentFragment();kv(Ad,Wd,Gd),Ad.display.dragCursor||(Ad.display.dragCursor=Qd("div",null,"CodeMirror-cursors CodeMirror-dragcursors"),Ad.display.lineSpace.insertBefore(Ad.display.dragCursor,Ad.display.cursorDiv)),pf(Ad.display.dragCursor,Gd)}}function o2(Ad){Ad.display.dragCursor&&(Ad.display.lineSpace.removeChild(Ad.display.dragCursor),Ad.display.dragCursor=null)}function l2(Ad){if(document.getElementsByClassName){for(var Bd=document.getElementsByClassName("CodeMirror"),Wd=[],Gd=0;Gd<Bd.length;Gd++){var Xd=Bd[Gd].CodeMirror;Xd&&Wd.push(Xd)}Wd.length&&Wd[0].operation(function(){for(var yf=0;yf<Wd.length;yf++)Ad(Wd[yf])})}}var Ub=!1;function c2(){Ub||(X2(),Ub=!0)}function X2(){var Ad;om(window,"resize",function(){Ad==null&&(Ad=setTimeout(function(){Ad=null,l2(Q2)},100))}),om(window,"blur",function(){return l2(Ab)})}function Q2(Ad){var Bd=Ad.display;Bd.cachedCharWidth=Bd.cachedTextHeight=Bd.cachedPaddingH=null,Bd.scrollbarsClipped=!1,Ad.setSize()}for(var M1={3:"Pause",8:"Backspace",9:"Tab",13:"Enter",16:"Shift",17:"Ctrl",18:"Alt",19:"Pause",20:"CapsLock",27:"Esc",32:"Space",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"Left",38:"Up",39:"Right",40:"Down",44:"PrintScrn",45:"Insert",46:"Delete",59:";",61:"=",91:"Mod",92:"Mod",93:"Mod",106:"*",107:"=",109:"-",110:".",111:"/",145:"ScrollLock",173:"-",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:" ` ",219:" [ ",220:" \ \ ",221:" ] ",222:" ' ",224:" Mod ",63232:" Up ",63233:" Down ",63234:" Left ",63235:" Right ",63272:" Delete ",63273:" Home ",63275:" End ",63276:" PageUp ",63277:" PageDown ",63302:" Insert "},uv=0;uv<10;uv++)M1[uv+48]=M1[uv+96]=String(uv);for(var cb=65;cb<=90;cb++)M1[cb]=String.fromCharCode(cb);for(var ub=1;ub<=12;ub++)M1[ub+111]=M1[ub+63235]=" F "+ub;var e0={};e0.basic={Left:" goCharLeft ",Right:" goCharRight ",Up:" goLineUp ",Down:" goLineDown ",End:" goLineEnd ",Home:" goLineStartSmart ",PageUp:" goPageUp ",PageDown:" goPageDown ",Delete:" delCharAfter ",Backspace:" delCharBefore "," Shift - Backspace ":"
` ,"start")},toggleOverwrite:function(Ad){return Ad.toggleOverwrite()}};function g0(Ad,Bd){var Wd=Dm(Ad.doc,Bd),Gd=z_(Wd);return Gd!=Wd&&(Bd=oh(Gd)),hv(!0,Ad,Gd,Bd,1)}function d2(Ad,Bd){var Wd=Dm(Ad.doc,Bd),Gd=G0(Wd);return Gd!=Wd&&(Bd=oh(Gd)),hv(!0,Ad,Wd,Bd,-1)}function mE(Ad,Bd){var Wd=g0(Ad,Bd.line),Gd=Dm(Ad.doc,Wd.line),Xd=Xh(Gd,Ad.doc.direction);if(!Xd||Xd[0].level==0){var yf=Math.max(Wd.ch,Gd.text.search(/ \S /)),kf=Bd.line==Wd.line&&Bd.ch<=yf&&Bd.ch;return am(Wd.line,kf?0:yf,Wd.sticky)}return Wd}function qb(Ad,Bd,Wd){if(typeof Bd=="string"&&(Bd=mv[Bd],!Bd))return!1;Ad.display.input.ensurePolled();var Gd=Ad.display.shift,Xd=!1;try{Ad.isReadOnly()&&(Ad.state.suppressEdits=!0),Wd&&(Ad.display.shift=!1),Xd=Bd(Ad)!=If}finally{Ad.display.shift=Gd,Ad.state.suppressEdits=!1}return Xd}function J2(Ad,Bd,Wd){for(var Gd=0;Gd<Ad.state.keyMaps.length;Gd++){var Xd=hg(Bd,Ad.state.keyMaps[Gd],Wd,Ad);if(Xd)return Xd}return Ad.options.extraKeys&&hg(Bd,Ad.options.extraKeys,Wd,Ad)||hg(Bd,Ad.options.keyMap,Wd,Ad)}var Z2=new Gf;function _v(Ad,Bd,Wd,Gd){var Xd=Ad.state.keySeq;if(Xd){if(Gv(Bd))return"handled";if(/ \' $ /.test(Bd)?Ad.state.keySeq=null:Z2.set(50,function(){Ad.state.keySeq==Xd&&(Ad.state.keySeq=null,Ad.display.input.reset())}),_E(Ad,Xd+" "+Bd,Wd,Gd))return!0}return _E(Ad,Bd,Wd,Gd)}function _E(Ad,Bd,Wd,Gd){var Xd=J2(Ad,Bd,Gd);return Xd=="multi"&&(Ad.state.keySeq=Bd),Xd=="handled"&&Vd(Ad,"keyHandled",Ad,Bd,Wd),(Xd=="handled"||Xd=="multi")&&(Xm(Wd),J0(Ad)),!!Xd}function bE(Ad,Bd){var Wd=dv(Bd,!0);return Wd?Bd.shiftKey&&!Ad.state.keySeq?_v(Ad,"Shift-"+Wd,Bd,function(Gd){return qb(Ad,Gd,!0)})||_v(Ad,Wd,Bd,function(Gd){if(typeof Gd=="string"?/^go[A-Z]/.test(Gd):Gd.motion)return qb(Ad,Gd)}):_v(Ad,Wd,Bd,function(Gd){return qb(Ad,Gd)}):!1}function eT(Ad,Bd,Wd){return _v(Ad,"'"+Wd+"'",Bd,function(Gd){return qb(Ad,Gd,!0)})}var Wv=null;function vE(Ad){var Bd=this;if(!(Ad.target&&Ad.target!=Bd.display.input.getField())&&(Bd.curOp.focus=Lf(wf(Bd)),!Jm(Bd,Ad))){ld&&cd<11&&Ad.keyCode==27&&(Ad.returnValue=!1);var Wd=Ad.keyCode;Bd.display.shift=Wd==16||Ad.shiftKey;var Gd=bE(Bd,Ad);Ed&&(Wv=Gd?Wd:null,!Gd&&Wd==88&&!sh&&(Ld?Ad.metaKey:Ad.ctrlKey)&&Bd.replaceSelection("",null,"cut")),td&&!Ld&&!Gd&&Wd==46&&Ad.shiftKey&&!Ad.ctrlKey&&document.execCommand&&document.execCommand("cut"),Wd==18&&!/ \b CodeMirror-crosshair \b /.test(Bd.display.lineDiv.className)&&ag(Bd)}}function ag(Ad){var Bd=Ad.display.lineDiv;Kf(Bd,"CodeMirror-crosshair");function Wd(Gd){(Gd.keyCode==18||!Gd.altKey)&&(Jd(Bd,"CodeMirror-crosshair"),Pm(document,"keyup",Wd),Pm(document,"mouseover",Wd))}om(document,"keyup",Wd),om(document,"mouseover",Wd)}function qg(Ad){Ad.keyCode==16&&(this.doc.sel.shift=!1),Jm(this,Ad)}function p2(Ad){var Bd=this;if(!(Ad.target&&Ad.target!=Bd.display.input.getField())&&!(W_(Bd.display,Ad)||Jm(Bd,Ad)||Ad.ctrlKey&&!Ad.altKey||Ld&&Ad.metaKey)){var Wd=Ad.keyCode,Gd=Ad.charCode;if(Ed&&Wd==Wv){Wv=null,Xm(Ad);return}if(!(Ed&&(!Ad.which||Ad.which<10)&&bE(Bd,Ad))){var Xd=String.fromCharCode(Gd??Wd);Xd!=" \b "&&(eT(Bd,Ad,Xd)||Bd.display.input.onKeyPress(Ad))}}}var tT=400,Hb=function(Ad,Bd,Wd){this.time=Ad,this.pos=Bd,this.button=Wd};Hb.prototype.compare=function(Ad,Bd,Wd){return this.time+tT>Ad&&zm(Bd,this.pos)==0&&Wd==this.button};var t0,Vb;function f2(Ad,Bd){var Wd=+new Date;return Vb&&Vb.compare(Wd,Ad,Bd)?(t0=Vb=null,"triple"):t0&&t0.compare(Wd,Ad,Bd)?(Vb=new Hb(Wd,Ad,Bd),t0=null,"double"):(t0=new Hb(Wd,Ad,Bd),Vb=null,"single")}function h2(Ad){var Bd=this,Wd=Bd.display;if(!(Jm(Bd,Ad)||Wd.activeTouch&&Wd.input.supportsTouch())){if(Wd.input.ensurePolled(),Wd.shift=Ad.shiftKey,W_(Wd,Ad)){ud||(Wd.scroller.draggable=!1,setTimeout(function(){return Wd.scroller.draggable=!0},100));return}if(!zb(Bd,Ad)){var Gd=Qg(Bd,Ad),Xd=R_(Ad),yf=Gd?f2(Gd,Xd):"single";Uf(Bd).focus(),Xd==1&&Bd.state.selectingText&&Bd.state.selectingText(Ad),!(Gd&&m2(Bd,Xd,Gd,yf,Ad))&&(Xd==1?Gd?gv(Bd,Gd,yf,Ad):J_(Ad)==Wd.scroller&&Xm(Ad):Xd==2?(Gd&&kb(Bd.doc,Gd),setTimeout(function(){return Wd.input.focus()},20)):Xd==3&&(Hd?Bd.display.input.onContextMenu(Ad):wb(Bd)))}}}function m2(Ad,Bd,Wd,Gd,Xd){var yf="Click";
` )==Bd){if(Gd.ranges.length%Cg.text.length==0){ch=[];for(var Ih=0;Ih<Cg.text.length;Ih++)ch.push(yf.splitLines(Cg.text[Ih]))}}else Qf.length==Gd.ranges.length&&Ad.options.pasteLinesPerSelection&&(ch=Ah(Qf,function(Km){return[Km]}));for(var Uh=Ad.curOp.updateInput,Kh=Gd.ranges.length-1;Kh>=0;Kh--){var Yh=Gd.ranges[Kh],hm=Yh.from(),Nm=Yh.to();Yh.empty()&&(Wd&&Wd>0?hm=am(hm.line,hm.ch-Wd):Ad.state.overwrite&&!qf?Nm=am(Nm.line,Math.min(Dm(yf,Nm.line).text.length,Nm.ch+hh(Qf).length)):qf&&Cg&&Cg.lineWise&&Cg.text.join( `
2024-09-03 08:22:14 +08:00
` )==Qf.join( `
2024-09-08 17:22:36 +08:00
` )&&(hm=Nm=am(hm.line,0)));var Hm={from:hm,to:Nm,text:ch?ch[Kh%ch.length]:Qf,origin:Xd||(qf?"paste":Ad.state.cutIncoming>kf?"cut":"+input")};Bb(Ad.doc,Hm),Vd(Ad,"inputRead",Ad,Hm)}Bd&&!qf&&ty(Ad,Bd),c1(Ad),Ad.curOp.updateInput<2&&(Ad.curOp.updateInput=Uh),Ad.curOp.typing=!0,Ad.state.pasteIncoming=Ad.state.cutIncoming=-1}function r0(Ad,Bd){var Wd=Ad.clipboardData&&Ad.clipboardData.getData("Text");if(Wd)return Ad.preventDefault(),!Bd.isReadOnly()&&!Bd.options.disableInput&&Bd.hasFocus()&&V1(Bd,function(){return xE(Bd,Wd,0,null,"paste")}),!0}function ty(Ad,Bd){if(!(!Ad.options.electricChars||!Ad.options.smartIndent))for(var Wd=Ad.doc.sel,Gd=Wd.ranges.length-1;Gd>=0;Gd--){var Xd=Wd.ranges[Gd];if(!(Xd.head.ch>100||Gd&&Wd.ranges[Gd-1].head.line==Xd.head.line)){var yf=Ad.getModeAt(Xd.head),kf=!1;if(yf.electricChars){for(var qf=0;qf<yf.electricChars.length;qf++)if(Bd.indexOf(yf.electricChars.charAt(qf))>-1){kf=yv(Ad,Xd.head.line,"smart");break}}else yf.electricInput&&yf.electricInput.test(Dm(Ad.doc,Xd.head.line).text.slice(0,Xd.head.ch))&&(kf=yv(Ad,Xd.head.line,"smart"));kf&&Vd(Ad,"electricInput",Ad,Xd.head.line)}}}function ry(Ad){for(var Bd=[],Wd=[],Gd=0;Gd<Ad.doc.sel.ranges.length;Gd++){var Xd=Ad.doc.sel.ranges[Gd].head.line,yf={anchor:am(Xd,0),head:am(Xd+1,0)};Wd.push(yf),Bd.push(Ad.getRange(yf.anchor,yf.head))}return{text:Bd,ranges:Wd}}function Ev(Ad,Bd,Wd,Gd){Ad.setAttribute("autocorrect",Wd?"on":"off"),Ad.setAttribute("autocapitalize",Gd?"on":"off"),Ad.setAttribute("spellcheck",!!Bd)}function Tv(){var Ad=Qd("textarea",null,null,"position: absolute; bottom: -1em; padding: 0; width: 1px; height: 1em; min-height: 1em; outline: none"),Bd=Qd("div",[Ad],null,"overflow: hidden; position: relative; width: 3px; height: 0px;");return ud?Ad.style.width="1000px":Ad.setAttribute("wrap","off"),Nd&&(Ad.style.border="1px solid black"),Bd}function Wb(Ad){var Bd=Ad.optionHandlers,Wd=Ad.helpers={};Ad.prototype={constructor:Ad,focus:function(){Uf(this).focus(),this.display.input.focus()},setOption:function(Gd,Xd){var yf=this.options,kf=yf[Gd];yf[Gd]==Xd&&Gd!="mode"||(yf[Gd]=Xd,Bd.hasOwnProperty(Gd)&&e1(this,Bd[Gd])(this,Xd,kf),Mm(this,"optionChange",this,Gd))},getOption:function(Gd){return this.options[Gd]},getDoc:function(){return this.doc},addKeyMap:function(Gd,Xd){this.state.keyMaps[Xd?"push":"unshift"](pv(Gd))},removeKeyMap:function(Gd){for(var Xd=this.state.keyMaps,yf=0;yf<Xd.length;++yf)if(Xd[yf]==Gd||Xd[yf].name==Gd)return Xd.splice(yf,1),!0},addOverlay:b_(function(Gd,Xd){var yf=Gd.token?Gd:Ad.getMode(this.options,Gd);if(yf.startState)throw new Error("Overlays may not be stateful.");uh(this.state.overlays,{mode:yf,modeSpec:Gd,opaque:Xd&&Xd.opaque,priority:Xd&&Xd.priority||0},function(kf){return kf.priority}),this.state.modeGen++,Q1(this)}),removeOverlay:b_(function(Gd){for(var Xd=this.state.overlays,yf=0;yf<Xd.length;++yf){var kf=Xd[yf].modeSpec;if(kf==Gd||typeof Gd=="string"&&kf.name==Gd){Xd.splice(yf,1),this.state.modeGen++,Q1(this);return}}}),indentLine:b_(function(Gd,Xd,yf){typeof Xd!="string"&&typeof Xd!="number"&&(Xd==null?Xd=this.options.smartIndent?"smart":"prev":Xd=Xd?"add":"subtract"),mm(this.doc,Gd)&&yv(this,Gd,Xd,yf)}),indentSelection:b_(function(Gd){for(var Xd=this.doc.sel.ranges,yf=-1,kf=0;kf<Xd.length;kf++){var qf=Xd[kf];if(qf.empty())qf.head.line>yf&&(yv(this,qf.head.line,Gd,!0),yf=qf.head.line,kf==this.doc.sel.primIndex&&c1(this));else{var Qf=qf.from(),ch=qf.to(),Ih=Math.max(yf,Qf.line);yf=Math.min(this.lastLine(),ch.line-(ch.ch?0:1))+1;for(var Uh=Ih;Uh<yf;++Uh)yv(this,Uh,Gd);var Kh=this.doc.sel.ranges;Qf.ch==0&&Xd.length==Kh.length&&Kh[kf].from().ch>0&&xg(this.doc,kf,new Y_(Qf,Kh[kf].to()),Jf)}}}),getTokenAt:function(Gd,Xd){return bg(this,Gd,Xd)},getLineTokens:function(Gd,Xd){return bg(this,am(Gd),Xd,!0)},getTokenTypeAt:function(Gd){Gd=h_(this.doc,Gd);var Xd=_g(this,Dm(this.doc,Gd.line)),yf=0,kf=(Xd.length-1)/2,qf=Gd.ch,Qf;if(qf==0)Qf=Xd[2];else for(;;){var ch=yf+kf>>1;if((ch?Xd[ch*2-1]:0)>=qf)kf=ch;else if(Xd[ch*2+1]<qf)yf=ch+1;else{Qf=Xd[ch*2+2];break}}var Ih=Qf?Qf.indexOf("overlay "):-1;return Ih<0?Qf:Ih==0?null:Q
2024-09-07 10:27:05 +08:00
` ,Hm=zh(Nm,Yh)?"w":Kh&&Nm== `
2024-09-08 17:22:36 +08:00
` ?"n":!Kh||/ \s /.test(Nm)?null:"p";if(Kh&&!hm&&!Hm&&(Hm="s"),Uh&&Uh!=Hm){Wd<0&&(Wd=1,Ih(),Bd.sticky="after");break}if(Hm&&(Uh=Hm),Wd>0&&!Ih(!hm))break}var Km=Mb(Ad,Bd,yf,kf,!0);return E_(yf,Km)&&(Km.hitSide=!0),Km}function Sv(Ad,Bd,Wd,Gd){var Xd=Ad.doc,yf=Bd.left,kf;if(Gd=="page"){var qf=Math.min(Ad.display.wrapper.clientHeight,Uf(Ad).innerHeight||Xd(Ad).documentElement.clientHeight),Qf=Math.max(qf-.5*kg(Ad.display),3);kf=(Wd>0?Bd.bottom:Bd.top)+Wd*Qf}else Gd=="line"&&(kf=Wd>0?Bd.bottom+3:Bd.top-3);for(var ch;ch=q_(Ad,yf,kf),!!ch.outside;){if(Wd<0?kf<=0:kf>=Xd.height){ch.hitSide=!0;break}kf+=Wd*5}return ch}var K_=function(Ad){this.cm=Ad,this.lastAnchorNode=this.lastAnchorOffset=this.lastFocusNode=this.lastFocusOffset=null,this.polling=new Gf,this.composing=null,this.gracePeriod=!1,this.readDOMTimeout=null};K_.prototype.init=function(Ad){var Bd=this,Wd=this,Gd=Wd.cm,Xd=Wd.div=Ad.lineDiv;Xd.contentEditable=!0,Ev(Xd,Gd.options.spellcheck,Gd.options.autocorrect,Gd.options.autocapitalize);function yf(qf){for(var Qf=qf.target;Qf;Qf=Qf.parentNode){if(Qf==Xd)return!0;if(/ \b CodeMirror-(?:line)?widget \b /.test(Qf.className))break}return!1}om(Xd,"paste",function(qf){!yf(qf)||Jm(Gd,qf)||r0(qf,Gd)||cd<=11&&setTimeout(e1(Gd,function(){return Bd.updateFromDOM()}),20)}),om(Xd,"compositionstart",function(qf){Bd.composing={data:qf.data,done:!1}}),om(Xd,"compositionupdate",function(qf){Bd.composing||(Bd.composing={data:qf.data,done:!1})}),om(Xd,"compositionend",function(qf){Bd.composing&&(qf.data!=Bd.composing.data&&Bd.readFromDOMSoon(),Bd.composing.done=!0)}),om(Xd,"touchstart",function(){return Wd.forceCompositionEnd()}),om(Xd,"input",function(){Bd.composing||Bd.readFromDOMSoon()});function kf(qf){if(!(!yf(qf)||Jm(Gd,qf))){if(Gd.somethingSelected())ey({lineWise:!1,text:Gd.getSelections()}),qf.type=="cut"&&Gd.replaceSelection("",null,"cut");else if(Gd.options.lineWiseCopyCut){var Qf=ry(Gd);ey({lineWise:!0,text:Qf.text}),qf.type=="cut"&&Gd.operation(function(){Gd.setSelections(Qf.ranges,0,Jf),Gd.replaceSelection("",null,"cut")})}else return;if(qf.clipboardData){qf.clipboardData.clearData();var ch=Cg.text.join( `
` );if(qf.clipboardData.setData("Text",ch),qf.clipboardData.getData("Text")==ch){qf.preventDefault();return}}var Ih=Tv(),Uh=Ih.firstChild;Ev(Uh),Gd.display.lineSpace.insertBefore(Ih,Gd.display.lineSpace.firstChild),Uh.value=Cg.text.join( `
` );var Kh=Lf(Wf(Xd));Of(Uh),setTimeout(function(){Gd.display.lineSpace.removeChild(Ih),Kh.focus(),Kh==Xd&&Wd.showPrimarySelection()},50)}}om(Xd,"copy",kf),om(Xd,"cut",kf)},K_.prototype.screenReaderLabelChanged=function(Ad){Ad?this.div.setAttribute("aria-label",Ad):this.div.removeAttribute("aria-label")},K_.prototype.prepareSelection=function(){var Ad=Vy(this.cm,!1);return Ad.focus=Lf(Wf(this.div))==this.div,Ad},K_.prototype.showSelection=function(Ad,Bd){!Ad||!this.cm.display.view.length||((Ad.focus||Bd)&&this.showPrimarySelection(),this.showMultipleSelections(Ad))},K_.prototype.getSelection=function(){return this.cm.display.wrapper.ownerDocument.getSelection()},K_.prototype.showPrimarySelection=function(){var Ad=this.getSelection(),Bd=this.cm,Wd=Bd.doc.sel.primary(),Gd=Wd.from(),Xd=Wd.to();if(Bd.display.viewTo==Bd.display.viewFrom||Gd.line>=Bd.display.viewTo||Xd.line<Bd.display.viewFrom){Ad.removeAllRanges();return}var yf=L1(Bd,Ad.anchorNode,Ad.anchorOffset),kf=L1(Bd,Ad.focusNode,Ad.focusOffset);if(!(yf&&!yf.bad&&kf&&!kf.bad&&zm(A1(yf,kf),Gd)==0&&zm(U_(yf,kf),Xd)==0)){var qf=Bd.display.view,Qf=Gd.line>=Bd.display.viewFrom&&M0(Bd,Gd)||{node:qf[0].measure.map[2],offset:0},ch=Xd.line<Bd.display.viewTo&&M0(Bd,Xd);if(!ch){var Ih=qf[qf.length-1].measure,Uh=Ih.maps?Ih.maps[Ih.maps.length-1]:Ih.map;ch={node:Uh[Uh.length-1],offset:Uh[Uh.length-2]-Uh[Uh.length-3]}}if(!Qf||!ch){Ad.removeAllRanges();return}var Kh=Ad.rangeCount&&Ad.getRangeAt(0),Yh;try{Yh=mf(Qf.node,Qf.offset,ch.offset,ch.node)}catch{}Yh&&(!td&&Bd.state.focused?(Ad.collapse(Qf.node,Qf.offset),Yh.collapsed||(Ad.removeAllRanges(),Ad.addRange(Yh))):(Ad.removeAllRanges(),Ad.addRange(Yh)),Kh&&Ad.anchorNode==null?Ad.addRange(Kh):td&&this.startGracePeriod()),this.rememberSelection()}},K_.prototype.startGracePeriod=function(){var Ad=this;clearTimeout(this.gracePeriod),this.gracePeriod=setTimeout(function(){Ad.gracePeriod=!1,Ad.selectionChanged()&&Ad.cm.operation(function(){return Ad.cm.curOp.selectionChanged=!0})},20)},K_.prototype.showMultipleSelections=function(Ad){pf(this.cm.display.cursorDiv,Ad.cursors),pf(this.cm.display.selectionDiv,Ad.selection)},K_.prototype.rememberSelection=function(){var Ad=this.getSelection();this.lastAnchorNode=Ad.anchorNode,this.lastAnchorOffset=Ad.anchorOffset,this.lastFocusNode=Ad.focusNode,this.lastFocusOffset=Ad.focusOffset},K_.prototype.selectionInEditor=function(){var Ad=this.getSelection();if(!Ad.rangeCount)return!1;var Bd=Ad.getRangeAt(0).commonAncestorContainer;return xf(this.div,Bd)},K_.prototype.focus=function(){this.cm.options.readOnly!="nocursor"&&((!this.selectionInEditor()||Lf(Wf(this.div))!=this.div)&&this.showSelection(this.prepareSelection(),!0),this.div.focus())},K_.prototype.blur=function(){this.div.blur()},K_.prototype.getField=function(){return this.div},K_.prototype.supportsTouch=function(){return!0},K_.prototype.receivedFocus=function(){var Ad=this,Bd=this;this.selectionInEditor()?setTimeout(function(){return Ad.pollSelection()},20):V1(this.cm,function(){return Bd.cm.curOp.selectionChanged=!0});function Wd(){Bd.cm.state.focused&&(Bd.pollSelection(),Bd.polling.set(Bd.cm.options.pollInterval,Wd))}this.polling.set(this.cm.options.pollInterval,Wd)},K_.prototype.selectionChanged=function(){var Ad=this.getSelection();return Ad.anchorNode!=this.lastAnchorNode||Ad.anchorOffset!=this.lastAnchorOffset||Ad.focusNode!=this.lastFocusNode||Ad.focusOffset!=this.lastFocusOffset},K_.prototype.pollSelection=function(){if(!(this.readDOMTimeout!=null||this.gracePeriod||!this.selectionChanged())){var Ad=this.getSelection(),Bd=this.cm;if(Id&&yd&&this.cm.display.gutterSpecs.length&&iT(Ad.anchorNode)){this.cm.triggerOnKeyDown({type:"keydown",keyCode:8,preventDefault:Math.abs}),this.blur(),this.focus();return}if(!this.composing){this.rememberSelection();var Wd=L1(Bd,Ad.anchorNode,Ad.anchorOffset),Gd=L1(Bd,Ad.focusNode,Ad.focusOffset);Wd&&Gd&&V1(Bd,function(){U1(Bd.doc,N0(Wd,Gd),Jf),(Wd.bad||Gd.bad)&&(Bd.curOp.selectionChanged=!0)})}}},K_.prototype.pollContent=function(){this.readDOMTimeout!=null&&(clearTimeout(this.readDOMTimeout),this.readDOMT
` ),Of(Xd))}else return;kf.type=="cut"&&(Gd.state.cutIncoming=+new Date)}}om(Xd,"cut",yf),om(Xd,"copy",yf),om(Ad.scroller,"paste",function(kf){if(!(W_(Ad,kf)||Jm(Gd,kf))){if(!Xd.dispatchEvent){Gd.state.pasteIncoming=+new Date,Wd.focus();return}var qf=new Event("paste");qf.clipboardData=kf.clipboardData,Xd.dispatchEvent(qf)}}),om(Ad.lineSpace,"selectstart",function(kf){W_(Ad,kf)||Xm(kf)}),om(Xd,"compositionstart",function(){var kf=Gd.getCursor("from");Wd.composing&&Wd.composing.range.clear(),Wd.composing={start:kf,range:Gd.markText(kf,Gd.getCursor("to"),{className:"CodeMirror-composing"})}}),om(Xd,"compositionend",function(){Wd.composing&&(Wd.poll(),Wd.composing.range.clear(),Wd.composing=null)})},b1.prototype.createField=function(Ad){this.wrapper=Tv(),this.textarea=this.wrapper.firstChild;var Bd=this.cm.options;Ev(this.textarea,Bd.spellcheck,Bd.autocorrect,Bd.autocapitalize)},b1.prototype.screenReaderLabelChanged=function(Ad){Ad?this.textarea.setAttribute("aria-label",Ad):this.textarea.removeAttribute("aria-label")},b1.prototype.prepareSelection=function(){var Ad=this.cm,Bd=Ad.display,Wd=Ad.doc,Gd=Vy(Ad);if(Ad.options.moveInputWithCursor){var Xd=dm(Ad,Wd.sel.primary().head,"div"),yf=Bd.wrapper.getBoundingClientRect(),kf=Bd.lineDiv.getBoundingClientRect();Gd.teTop=Math.max(0,Math.min(Bd.wrapper.clientHeight-10,Xd.top+kf.top-yf.top)),Gd.teLeft=Math.max(0,Math.min(Bd.wrapper.clientWidth-10,Xd.left+kf.left-yf.left))}return Gd},b1.prototype.showSelection=function(Ad){var Bd=this.cm,Wd=Bd.display;pf(Wd.cursorDiv,Ad.cursors),pf(Wd.selectionDiv,Ad.selection),Ad.teTop!=null&&(this.wrapper.style.top=Ad.teTop+"px",this.wrapper.style.left=Ad.teLeft+"px")},b1.prototype.reset=function(Ad){if(!(this.contextMenuPending||this.composing&&Ad)){var Bd=this.cm;if(this.resetting=!0,Bd.somethingSelected()){this.prevInput="";var Wd=Bd.getSelection();this.textarea.value=Wd,Bd.state.focused&&Of(this.textarea),ld&&cd>=9&&(this.hasSelection=Wd)}else Ad||(this.prevInput=this.textarea.value="",ld&&cd>=9&&(this.hasSelection=null));this.resetting=!1}},b1.prototype.getField=function(){return this.textarea},b1.prototype.supportsTouch=function(){return!1},b1.prototype.focus=function(){if(this.cm.options.readOnly!="nocursor"&&(!Md||Lf(Wf(this.textarea))!=this.textarea))try{this.textarea.focus()}catch{}},b1.prototype.blur=function(){this.textarea.blur()},b1.prototype.resetPosition=function(){this.wrapper.style.top=this.wrapper.style.left=0},b1.prototype.receivedFocus=function(){this.slowPoll()},b1.prototype.slowPoll=function(){var Ad=this;this.pollingFast||this.polling.set(this.cm.options.pollInterval,function(){Ad.poll(),Ad.cm.state.focused&&Ad.slowPoll()})},b1.prototype.fastPoll=function(){var Ad=!1,Bd=this;Bd.pollingFast=!0;function Wd(){var Gd=Bd.poll();!Gd&&!Ad?(Ad=!0,Bd.polling.set(60,Wd)):(Bd.pollingFast=!1,Bd.slowPoll())}Bd.polling.set(20,Wd)},b1.prototype.poll=function(){var Ad=this,Bd=this.cm,Wd=this.textarea,Gd=this.prevInput;if(this.contextMenuPending||this.resetting||!Bd.state.focused||bh(Wd)&&!Gd&&!this.composing||Bd.isReadOnly()||Bd.options.disableInput||Bd.state.keySeq)return!1;var Xd=Wd.value;if(Xd==Gd&&!Bd.somethingSelected())return!1;if(ld&&cd>=9&&this.hasSelection===Xd||Ld&&/[ \u f700- \u f7ff]/.test(Xd))return Bd.display.input.reset(),!1;if(Bd.doc.sel==Bd.display.selForContextMenu){var yf=Xd.charCodeAt(0);if(yf==8203&&!Gd&&(Gd=" "),yf==8666)return this.reset(),this.cm.execCommand("undo")}for(var kf=0,qf=Math.min(Gd.length,Xd.length);kf<qf&&Gd.charCodeAt(kf)==Xd.charCodeAt(kf);)++kf;return V1(Bd,function(){xE(Bd,Xd.slice(kf),Gd.length-kf,null,Ad.composing?"*compose":null),Xd.length>1e3||Xd.indexOf( `
` )>-1?Wd.value=Ad.prevInput="":Ad.prevInput=Xd,Ad.composing&&(Ad.composing.range.clear(),Ad.composing.range=Bd.markText(Ad.composing.start,Bd.getCursor("to"),{className:"CodeMirror-composing"}))}),!0},b1.prototype.ensurePolled=function(){this.pollingFast&&this.poll()&&(this.pollingFast=!1)},b1.prototype.onKeyPress=function(){ld&&cd>=9&&(this.hasSelection=null),this.fastPoll()},b1.prototype.onContextMenu=function(Ad){var Bd=this,Wd=Bd.cm,Gd=Wd.display,Xd=Bd.textarea;Bd.contextMenuPending&&Bd.contextMenuPending();var yf=Qg(Wd,Ad),kf=Gd.scroller.scrollTop;if(!yf||Ed)return;var qf=Wd.options.resetSelectionOnContextMenu;qf&&Wd.doc.sel.contains(yf)==-1&&e1(Wd,U1)(Wd.doc,N0(yf),Jf);var Qf=Xd.style.cssText,ch=Bd.wrapper.style.cssText,Ih=Bd.wrapper.offsetParent.getBoundingClientRect();Bd.wrapper.style.cssText="position: static",Xd.style.cssText= ` position : absolute ; width : 30 px ; height : 30 px ;
2024-09-07 10:27:05 +08:00
top : ` +(Ad.clientY-Ih.top-5)+"px; left: "+(Ad.clientX-Ih.left-5)+ ` px ;
2024-08-30 15:19:18 +08:00
z - index : 1000 ; background : ` +(ld?"rgba(255, 255, 255, .05)":"transparent")+ ` ;
2024-09-08 19:53:57 +08:00
outline : none ; border - width : 0 ; outline : none ; overflow : hidden ; opacity : . 05 ; filter : alpha ( opacity = 5 ) ; ` ;var Uh;ud&&(Uh=Xd.ownerDocument.defaultView.scrollY),Gd.input.focus(),ud&&Xd.ownerDocument.defaultView.scrollTo(null,Uh),Gd.input.reset(),Wd.somethingSelected()||(Xd.value=Bd.prevInput=" "),Bd.contextMenuPending=Yh,Gd.selForContextMenu=Wd.doc.sel,clearTimeout(Gd.detectingSelectAll);function Kh(){if(Xd.selectionStart!=null){var Nm=Wd.somethingSelected(),Hm=" "+(Nm?Xd.value:"");Xd.value="⇚",Xd.value=Hm,Bd.prevInput=Nm?"":" ",Xd.selectionStart=1,Xd.selectionEnd=Hm.length,Gd.selForContextMenu=Wd.doc.sel}}function Yh(){if(Bd.contextMenuPending==Yh&&(Bd.contextMenuPending=!1,Bd.wrapper.style.cssText=ch,Xd.style.cssText=Qf,ld&&cd<9&&Gd.scrollbars.setScrollTop(Gd.scroller.scrollTop=kf),Xd.selectionStart!=null)){(!ld||ld&&cd<9)&&Kh();var Nm=0,Hm=function(){Gd.selForContextMenu==Wd.doc.sel&&Xd.selectionStart==0&&Xd.selectionEnd>0&&Bd.prevInput==" "?e1(Wd,Lb)(Wd):Nm++<10?Gd.detectingSelectAll=setTimeout(Hm,500):(Gd.selForContextMenu=null,Gd.input.reset())};Gd.detectingSelectAll=setTimeout(Hm,200)}}if(ld&&cd>=9&&Kh(),Hd){G_(Ad);var hm=function(){Pm(window,"mouseup",hm),setTimeout(Yh,20)};om(window,"mouseup",hm)}else setTimeout(Yh,50)},b1.prototype.readOnlyChanged=function(Ad){Ad||this.reset(),this.textarea.disabled=Ad=="nocursor",this.textarea.readOnly=!!Ad},b1.prototype.setUneditable=function(){},b1.prototype.needsContentAttribute=!1;function E2(Ad,Bd){if(Bd=Bd?_f(Bd):{},Bd.value=Ad.value,!Bd.tabindex&&Ad.tabIndex&&(Bd.tabindex=Ad.tabIndex),!Bd.placeholder&&Ad.placeholder&&(Bd.placeholder=Ad.placeholder),Bd.autofocus==null){var Wd=Lf(Wf(Ad));Bd.autofocus=Wd==Ad||Ad.getAttribute("autofocus")!=null&&Wd==document.body}function Gd(){Ad.value=qf.getValue()}var Xd;if(Ad.form&&(om(Ad.form,"submit",Gd),!Bd.leaveSubmitMethodAlone)){var yf=Ad.form;Xd=yf.submit;try{var kf=yf.submit=function(){Gd(),yf.submit=Xd,yf.submit(),yf.submit=kf}}catch{}}Bd.finishInit=function(Qf){Qf.save=Gd,Qf.getTextArea=function(){return Ad},Qf.toTextArea=function(){Qf.toTextArea=isNaN,Gd(),Ad.parentNode.removeChild(Qf.getWrapperElement()),Ad.style.display="",Ad.form&&(Pm(Ad.form,"submit",Gd),!Bd.leaveSubmitMethodAlone&&typeof Ad.form.submit=="function"&&(Ad.form.submit=Xd))}},Ad.style.display="none";var qf=H_(function(Qf){return Ad.parentNode.insertBefore(Qf,Ad.nextSibling)},Bd);return qf}function sT(Ad){Ad.off=Pm,Ad.on=om,Ad.wheelEventPixels=V2,Ad.Doc=W1,Ad.splitLines=Cf,Ad.countColumn= $ f,Ad.findColumn=Ef,Ad.isWordChar=Jh,Ad.Pass=If,Ad.signal=Mm,Ad.Line=Mf,Ad.changeEnd=D0,Ad.scrollbarModel=tb,Ad.Pos=am,Ad.cmpPos=zm,Ad.modes=kh,Ad.mimeModes=Hh,Ad.resolveMode=um,Ad.getMode=cm,Ad.modeExtensions=_m,Ad.extendMode=Ff,Ad.copyState=Om,Ad.startState=f_,Ad.innerMode=m_,Ad.commands=mv,Ad.keyMap=e0,Ad.keyName=dv,Ad.isModifierKey=Gv,Ad.lookupKey=hg,Ad.normalizeKeyMap=fg,Ad.StringStream=a_,Ad.SharedTextMarker=jb,Ad.TextMarker=Ug,Ad.LineWidget=lb,Ad.e_preventDefault=Xm,Ad.e_stopPropagation=L_,Ad.e_stop=G_,Ad.addClass=Kf,Ad.contains=xf,Ad.rmClass=Jd,Ad.keyNames=M1}SE(H_),Wb(H_);var T2="iter insert remove copy getEditor constructor".split(" ");for(var ny in W1.prototype)W1.prototype.hasOwnProperty(ny)&&dh(T2,ny)<0&&(H_.prototype[ny]=function(Ad){return function(){return Ad.apply(this.doc,arguments)}}(W1.prototype[ny]));return y_(W1),H_.inputStyles={textarea:b1,contenteditable:K_},H_.defineMode=function(Ad){!H_.defaults.mode&&Ad!="null"&&(H_.defaults.mode=Ad), $ h.apply(this,arguments)},H_.defineMIME=wh,H_.defineMode("null",function(){return{token:function(Ad){return Ad.skipToEnd()}}}),H_.defineMIME("text/plain","null"),H_.defineExtension=function(Ad,Bd){H_.prototype[Ad]=Bd},H_.defineDocExtension=function(Ad,Bd){W1.prototype[Ad]=Bd},H_.fromTextArea=E2,sT(H_),H_.version="5.65.17",H_})}(codemirror)),codemirror.exports}var codemirrorExports=requireCodemirror();const CodeMirror=getDefaultExportFromCjs(codemirrorExports);function tryOnScopeDispose $ 1(Ra){return getCurrentScope()?(onScopeDispose(Ra),!0):!1}function toValue $ 2(Ra){return typeof Ra=="function"?Ra():unref(Ra)}
2024-08-27 22:31:52 +08:00
( ? :
2024-08-30 15:19:18 +08:00
( ? : ` +ed+":){7}(?:"+ed+ ` | : ) | // 1:2:3:4:5:6:7:: 1:2:3:4:5:6:7:8
( ? : ` +ed+":){6}(?:"+Ja+"|:"+ed+ ` | : ) | // 1:2:3:4:5:6:: 1:2:3:4:5:6::8 1:2:3:4:5:6::8 1:2:3:4:5:6::1.2.3.4
( ? : ` +ed+":){5}(?::"+Ja+"|(?::"+ed+ ` ) { 1 , 2 } | : ) | // 1:2:3:4:5:: 1:2:3:4:5::7:8 1:2:3:4:5::8 1:2:3:4:5::7:1.2.3.4
( ? : ` +ed+":){4}(?:(?::"+ed+"){0,1}:"+Ja+"|(?::"+ed+ ` ) { 1 , 3 } | : ) | // 1:2:3:4:: 1:2:3:4::6:7:8 1:2:3:4::8 1:2:3:4::6:7:1.2.3.4
( ? : ` +ed+":){3}(?:(?::"+ed+"){0,2}:"+Ja+"|(?::"+ed+ ` ) { 1 , 4 } | : ) | // 1:2:3:: 1:2:3::5:6:7:8 1:2:3::8 1:2:3::5:6:7:1.2.3.4
( ? : ` +ed+":){2}(?:(?::"+ed+"){0,3}:"+Ja+"|(?::"+ed+ ` ) { 1 , 5 } | : ) | // 1:2:: 1:2::4:5:6:7:8 1:2::8 1:2::4:5:6:7:1.2.3.4
( ? : ` +ed+":){1}(?:(?::"+ed+"){0,4}:"+Ja+"|(?::"+ed+ ` ) { 1 , 6 } | : ) | // 1:: 1::3:4:5:6:7:8 1::8 1::3:4:5:6:7:1.2.3.4
( ? : : ( ? : ( ? : : ` +ed+"){0,5}:"+Ja+"|(?::"+ed+ ` ) { 1 , 7 } | : ) ) // ::2:3:4:5:6:7:8 ::2:3:4:5:6:7:8 ::8 ::1.2.3.4
2024-08-27 22:31:52 +08:00
) ( ? : % [ 0 - 9 a - zA - Z ] { 1 , } ) ? // %eth0 %1
2024-09-08 17:22:36 +08:00
` ).replace(/ \s * \/ \/ .* $ /gm,"").replace(/ \n /g,"").trim(),rd=new RegExp("(?:^"+Ja+" $ )|(?:^"+td+" $ )"),sd=new RegExp("^"+Ja+" $ "),od=new RegExp("^"+td+" $ "),ld=function(Md){return Md&&Md.exact?rd:new RegExp("(?:"+qa(Md)+Ja+qa(Md)+")|(?:"+qa(Md)+td+qa(Md)+")","g")};ld.v4=function(Id){return Id&&Id.exact?sd:new RegExp(""+qa(Id)+Ja+qa(Id),"g")},ld.v6=function(Id){return Id&&Id.exact?od:new RegExp(""+qa(Id)+td+qa(Id),"g")};var cd="(?:(?:[a-z]+:)?//)",ud="(?: \\ S+(?:: \\ S*)?@)?",_d=ld.v4().source,yd=ld.v6().source,gd="(?:(?:[a-z \\ u00a1- \\ uffff0-9][-_]*)*[a-z \\ u00a1- \\ uffff0-9]+)",Ed="(?: \\ .(?:[a-z \\ u00a1- \\ uffff0-9]-*)*[a-z \\ u00a1- \\ uffff0-9]+)*",Td="(?: \\ .(?:[a-z \\ u00a1- \\ uffff]{2,}))",Od="(?:: \\ d{2,5})?",Rd='(?:[/?#][^ \\ s"]*)?',Nd="(?:"+cd+"|www \\ .)"+ud+"(?:localhost|"+_d+"|"+yd+"|"+gd+Ed+Td+")"+Od+Rd;return urlReg=new RegExp("(?:^"+Nd+" $ )","i"),urlReg},pattern $ 2={email:/^(([^<>() \[ \] \\ .,;: \s @"]+( \. [^<>() \[ \] \\ .,;: \s @"]+)*)|(".+"))@(( \[ [0-9]{1,3} \. [0-9]{1,3} \. [0-9]{1,3} \. [0-9]{1,3}])|(([a-zA-Z \- 0-9 \u 00A0- \u D7FF \u F900- \u FDCF \u FDF0- \u FFEF]+ \. )+[a-zA-Z \u 00A0- \u D7FF \u F900- \u FDCF \u FDF0- \u FFEF]{2,})) $ /,hex:/^#?([a-f0-9]{6}|[a-f0-9]{3}) $ /i},types $ 2={integer:function(qa){return types $ 2.number(qa)&&parseInt(qa,10)===qa},float:function(qa){return types $ 2.number(qa)&&!types $ 2.integer(qa)},array:function(qa){return Array.isArray(qa)},regexp:function(qa){if(qa instanceof RegExp)return!0;try{return!!new RegExp(qa)}catch{return!1}},date:function(qa){return typeof qa.getTime=="function"&&typeof qa.getMonth=="function"&&typeof qa.getYear=="function"&&!isNaN(qa.getTime())},number:function(qa){return isNaN(qa)?!1:typeof qa=="number"},object:function(qa){return typeof qa=="object"&&!types $ 2.array(qa)},method:function(qa){return typeof qa=="function"},email:function(qa){return typeof qa=="string"&&qa.length<=320&&!!qa.match(pattern $ 2.email)},url:function(qa){return typeof qa=="string"&&qa.length<=2048&&!!qa.match(getUrlRegex())},hex:function(qa){return typeof qa=="string"&&!!qa.match(pattern $ 2.hex)}},type $ 1 $ 1=function(qa,Ja,ed,td,rd){if(qa.required&&Ja===void 0){required $ 1(qa,Ja,ed,td,rd);return}var sd=["integer","float","array","regexp","object","method","email","number","date","url","hex"],od=qa.type;sd.indexOf(od)>-1?types $ 2[od](Ja)||td.push(format $ 2(rd.messages.types[od],qa.fullField,qa.type)):od&&typeof Ja!==qa.type&&td.push(format $ 2(rd.messages.types[od],qa.fullField,qa.type))},range $ 4=function(qa,Ja,ed,td,rd){var sd=typeof qa.len=="number",od=typeof qa.min=="number",ld=typeof qa.max=="number",cd=/[ \u D800- \u DBFF][ \u DC00- \u DFFF]/g,ud=Ja,_d=null,yd=typeof Ja=="number",gd=typeof Ja=="string",Ed=Array.isArray(Ja);if(yd?_d="number":gd?_d="string":Ed&&(_d="array"),!_d)return!1;Ed&&(ud=Ja.length),gd&&(ud=Ja.replace(cd,"_").length),sd?ud!==qa.len&&td.push(format $ 2(rd.messages[_d].len,qa.fullField,qa.len)):od&&!ld&&ud<qa.min?td.push(format $ 2(rd.messages[_d].min,qa.fullField,qa.min)):ld&&!od&&ud>qa.max?td.push(format $ 2(rd.messages[_d].max,qa.fullField,qa.max)):od&&ld&&(ud<qa.min||ud>qa.max)&&td.push(format $ 2(rd.messages[_d].range,qa.fullField,qa.min,qa.max))},ENUM $ 1="enum",enumerable $ 1=function(qa,Ja,ed,td,rd){qa[ENUM $ 1]=Array.isArray(qa[ENUM $ 1])?qa[ENUM $ 1]:[],qa[ENUM $ 1].indexOf(Ja)===-1&&td.push(format $ 2(rd.messages[ENUM $ 1],qa.fullField,qa[ENUM $ 1].join(", ")))},pattern $ 1=function(qa,Ja,ed,td,rd){if(qa.pattern){if(qa.pattern instanceof RegExp)qa.pattern.lastIndex=0,qa.pattern.test(Ja)||td.push(format $ 2(rd.messages.pattern.mismatch,qa.fullField,Ja,qa.pattern));else if(typeof qa.pattern=="string"){var sd=new RegExp(qa.pattern);sd.test(Ja)||td.push(format $ 2(rd.messages.pattern.mismatch,qa.fullField,Ja,qa.pattern))}}},rules={required:required $ 1,whitespace:whitespace $ 1,type:type $ 1 $ 1,range:range $ 4,enum:enumerable $ 1,pattern:pattern $ 1},string=function(qa,Ja,ed,td,rd){var sd=[],od=qa.required||!qa.required&&td.hasOwnProperty(qa.field);if(od){if(isEmptyValue(Ja,"string")&&!qa.required)return ed();rules.required(qa,Ja,td,sd,rd,"string"),isEmptyValue(Ja,"string")||(rules.type(qa,Ja,td,sd,rd),rules.range(qa,Ja,td,sd,rd),rules.pattern(qa,Ja,td,sd,rd),qa.whitespace===!0&
2024-08-27 22:31:52 +08:00
height : 0 ! important ;
visibility : hidden ! important ;
$ { isFirefox ( ) ? "" : "overflow:hidden !important;" }
position : absolute ! important ;
z - index : - 1000 ! important ;
top : 0 ! important ;
right : 0 ! important ;
2024-09-08 17:22:36 +08:00
` ,CONTEXT_STYLE=["letter-spacing","line-height","padding-top","padding-bottom","font-family","font-weight","font-size","text-rendering","text-transform","width","text-indent","padding-left","padding-right","border-width","box-sizing"];function calculateNodeStyling(Ra){const qa=window.getComputedStyle(Ra),Ja=qa.getPropertyValue("box-sizing"),ed=Number.parseFloat(qa.getPropertyValue("padding-bottom"))+Number.parseFloat(qa.getPropertyValue("padding-top")),td=Number.parseFloat(qa.getPropertyValue("border-bottom-width"))+Number.parseFloat(qa.getPropertyValue("border-top-width"));return{contextStyle:CONTEXT_STYLE.map(sd=> ` $ { sd } : $ { qa . getPropertyValue ( sd ) } ` ).join(";"),paddingSize:ed,borderSize:td,boxSizing:Ja}}function calcTextareaHeight(Ra,qa=1,Ja){var ed;hiddenTextarea||(hiddenTextarea=document.createElement("textarea"),document.body.appendChild(hiddenTextarea));const{paddingSize:td,borderSize:rd,boxSizing:sd,contextStyle:od}=calculateNodeStyling(Ra);hiddenTextarea.setAttribute("style", ` $ { od } ; $ { HIDDEN _STYLE } ` ),hiddenTextarea.value=Ra.value||Ra.placeholder||"";let ld=hiddenTextarea.scrollHeight;const cd={};sd==="border-box"?ld=ld+rd:sd==="content-box"&&(ld=ld-td),hiddenTextarea.value="";const ud=hiddenTextarea.scrollHeight-td;if(isNumber $ 3(qa)){let _d=ud*qa;sd==="border-box"&&(_d=_d+td+rd),ld=Math.max(_d,ld),cd.minHeight= ` $ { _d } px ` }if(isNumber $ 3(Ja)){let _d=ud*Ja;sd==="border-box"&&(_d=_d+td+rd),ld=Math.min(_d,ld)}return cd.height= ` $ { ld } px ` ,(ed=hiddenTextarea.parentNode)==null||ed.removeChild(hiddenTextarea),hiddenTextarea=void 0,cd}const inputProps=buildProps({id:{type:String,default:void 0},size:useSizeProp,disabled:Boolean,modelValue:{type:definePropType([String,Number,Object]),default:""},maxlength:{type:[String,Number]},minlength:{type:[String,Number]},type:{type:String,default:"text"},resize:{type:String,values:["none","both","horizontal","vertical"]},autosize:{type:definePropType([Boolean,Object]),default:!1},autocomplete:{type:String,default:"off"},formatter:{type:Function},parser:{type:Function},placeholder:{type:String},form:{type:String},readonly:Boolean,clearable:Boolean,showPassword:Boolean,showWordLimit:Boolean,suffixIcon:{type:iconPropType},prefixIcon:{type:iconPropType},containerRole:{type:String,default:void 0},tabindex:{type:[String,Number],default:0},validateEvent:{type:Boolean,default:!0},inputStyle:{type:definePropType([Object,Array,String]),default:()=>mutable({})},autofocus:Boolean,rows:{type:Number,default:2},...useAriaProps(["ariaLabel"])}),inputEmits={[UPDATE_MODEL_EVENT]:Ra=>isString $ 3(Ra),input:Ra=>isString $ 3(Ra),change:Ra=>isString $ 3(Ra),focus:Ra=>Ra instanceof FocusEvent,blur:Ra=>Ra instanceof FocusEvent,clear:()=>!0,mouseleave:Ra=>Ra instanceof MouseEvent,mouseenter:Ra=>Ra instanceof MouseEvent,keydown:Ra=>Ra instanceof Event,compositionstart:Ra=>Ra instanceof CompositionEvent,compositionupdate:Ra=>Ra instanceof CompositionEvent,compositionend:Ra=>Ra instanceof CompositionEvent},__default__ $ z=defineComponent({name:"ElInput",inheritAttrs:!1}),_sfc_main $ 1q=defineComponent({...__default__ $ z,props:inputProps,emits:inputEmits,setup(Ra,{expose:qa,emit:Ja}){const ed=Ra,td=useAttrs $ 1(),rd=useSlots(),sd=computed(()=>{const Bh={};return ed.containerRole==="combobox"&&(Bh["aria-haspopup"]=td["aria-haspopup"],Bh["aria-owns"]=td["aria-owns"],Bh["aria-expanded"]=td["aria-expanded"]),Bh}),od=computed(()=>[ed.type==="textarea"?Od.b():Td.b(),Td.m(gd.value),Td.is("disabled",Ed.value),Td.is("exceed",Tf.value),{[Td.b("group")]:rd.prepend||rd.append,[Td.m("prefix")]:rd.prefix||ed.prefixIcon,[Td.m("suffix")]:rd.suffix||ed.suffixIcon||ed.clearable||ed.showPassword,[Td.bm("suffix","password-clear")]:Lf.value&&Kf.value,[Td.b("hidden")]:ed.type==="hidden"},td.class]),ld=computed(()=>[Td.e("wrapper"),Td.is("focus",Ud.value)]),cd=useAttrs({excludeKeys:computed(()=>Object.keys(sd.value))}),{form:ud,formItem:_d}=useFormItem(),{inputId:yd}=useFormItemInputId(ed,{formItemContext:_d}),gd=useFormSize(),Ed=useFormDisabled(),Td=useNamespace("input"),Od=useNamespace("textarea"),Rd=shallowRef(),Nd=shallowRef(),Id=ref $ 1(!1),Md=ref $ 1(!1
2024-08-27 22:31:52 +08:00
M 50 50
2024-09-03 08:22:14 +08:00
m 0 $ { Md ? "" : "-" } $ { Id }
a $ { Id } $ { Id } 0 1 1 0 $ { Md ? "-" : "" } $ { Id * 2 }
a $ { Id } $ { Id } 0 1 1 0 $ { Md ? "" : "-" } $ { Id * 2 }
2024-09-08 17:22:36 +08:00
` }),ld=computed(()=>2*Math.PI*sd.value),cd=computed(()=>qa.type==="dashboard"?.75:1),ud=computed(()=> ` $ { - 1 * ld . value * ( 1 - cd . value ) / 2 } px ` ),_d=computed(()=>({strokeDasharray: ` $ { ld . value * cd . value } px , $ { ld . value } px ` ,strokeDashoffset:ud.value})),yd=computed(()=>({strokeDasharray: ` $ { ld . value * cd . value * ( qa . percentage / 100 ) } px , $ { ld . value } px ` ,strokeDashoffset:ud.value,transition:"stroke-dasharray 0.6s ease 0s, stroke 0.6s ease, opacity ease 0.6s"})),gd=computed(()=>{let Id;return qa.color?Id=Nd(qa.percentage):Id=Ja[qa.status]||Ja.default,Id}),Ed=computed(()=>qa.status==="warning"?warning_filled_default:qa.type==="line"?qa.status==="success"?circle_check_default:circle_close_default:qa.status==="success"?check_default:close_default),Td=computed(()=>qa.type==="line"?12+qa.strokeWidth*.4:qa.width*.111111+2),Od=computed(()=>qa.format(qa.percentage));function Rd(Id){const Md=100/Id.length;return Id.map((Pd,qd)=>isString $ 3(Pd)?{color:Pd,percentage:(qd+1)*Md}:Pd).sort((Pd,qd)=>Pd.percentage-qd.percentage)}const Nd=Id=>{var Md;const{color:Ld}=qa;if(isFunction $ 4(Ld))return Ld(Id);if(isString $ 3(Ld))return Ld;{const Pd=Rd(Ld);for(const qd of Pd)if(qd.percentage>Id)return qd.color;return(Md=Pd[Pd.length-1])==null?void 0:Md.color}};return(Id,Md)=>(openBlock(),createElementBlock("div",{class:normalizeClass([unref(ed).b(),unref(ed).m(Id.type),unref(ed).is(Id.status),{[unref(ed).m("without-text")]:!Id.showText,[unref(ed).m("text-inside")]:Id.textInside}]),role:"progressbar","aria-valuenow":Id.percentage,"aria-valuemin":"0","aria-valuemax":"100"},[Id.type==="line"?(openBlock(),createElementBlock("div",{key:0,class:normalizeClass(unref(ed).b("bar"))},[createBaseVNode("div",{class:normalizeClass(unref(ed).be("bar","outer")),style:normalizeStyle({height: ` $ { Id . strokeWidth } px ` })},[createBaseVNode("div",{class:normalizeClass([unref(ed).be("bar","inner"),{[unref(ed).bem("bar","inner","indeterminate")]:Id.indeterminate},{[unref(ed).bem("bar","inner","striped")]:Id.striped},{[unref(ed).bem("bar","inner","striped-flow")]:Id.stripedFlow}]),style:normalizeStyle(unref(td))},[(Id.showText||Id. $ slots.default)&&Id.textInside?(openBlock(),createElementBlock("div",{key:0,class:normalizeClass(unref(ed).be("bar","innerText"))},[renderSlot(Id. $ slots,"default",{percentage:Id.percentage},()=>[createBaseVNode("span",null,toDisplayString(unref(Od)),1)])],2)):createCommentVNode("v-if",!0)],6)],6)],2)):(openBlock(),createElementBlock("div",{key:1,class:normalizeClass(unref(ed).b("circle")),style:normalizeStyle({height: ` $ { Id . width } px ` ,width: ` $ { Id . width } px ` })},[(openBlock(),createElementBlock("svg",{viewBox:"0 0 100 100"},[createBaseVNode("path",{class:normalizeClass(unref(ed).be("circle","track")),d:unref(od),stroke: ` var ( $ { unref ( ed ) . cssVarName ( "fill-color-light" ) } , # e5e9f2 ) ` ,"stroke-linecap":Id.strokeLinecap,"stroke-width":unref(rd),fill:"none",style:normalizeStyle(unref(_d))},null,14,["d","stroke","stroke-linecap","stroke-width"]),createBaseVNode("path",{class:normalizeClass(unref(ed).be("circle","path")),d:unref(od),stroke:unref(gd),fill:"none",opacity:Id.percentage?1:0,"stroke-linecap":Id.strokeLinecap,"stroke-width":unref(rd),style:normalizeStyle(unref(yd))},null,14,["d","stroke","opacity","stroke-linecap","stroke-width"])]))],6)),(Id.showText||Id. $ slots.default)&&!Id.textInside?(openBlock(),createElementBlock("div",{key:2,class:normalizeClass(unref(ed).e("text")),style:normalizeStyle({fontSize: ` $ { unref ( Td ) } px ` })},[renderSlot(Id. $ slots,"default",{percentage:Id.percentage},()=>[Id.status?(openBlock(),createBlock(unref(ElIcon),{key:1},{default:withCtx(()=>[(openBlock(),createBlock(resolveDynamicComponent(unref(Ed))))]),_:1})):(openBlock(),createElementBlock("span",{key:0},toDisplayString(unref(Od)),1))])],6)):createCommentVNode("v-if",!0)],10,["aria-valuenow"]))}});var Progress=_export_sfc $ 1(_sfc_main $ R,[["__file","progress.vue"]]);const ElProgress=withInstall(Progress),switchProps=buildProps({modelValue:{type:[Boolean,String,Number],default:!1},disabled:Boolean,loading:Boolean,size:{type:String,validator:isValidComponentSize},width:{type:[String,Number],default:"
2024-08-30 08:16:01 +08:00
* The buffer module from node . js , for the browser .
*
* @ author Feross Aboukhadijeh < https : //feross.org>
* @ license MIT
2024-09-08 17:22:36 +08:00
* / ( f u n c t i o n ( R a ) { c o n s t q a = b a s e 6 4 J s $ 1 , J a = i e e e 7 5 4 $ 1 , e d = t y p e o f S y m b o l = = " f u n c t i o n " & & t y p e o f S y m b o l . f o r = = " f u n c t i o n " ? S y m b o l . f o r ( " n o d e j s . u t i l . i n s p e c t . c u s t o m " ) : n u l l ; R a . B u f f e r = u d , R a . S l o w B u f f e r = L d , R a . I N S P E C T _ M A X _ B Y T E S = 5 0 ; c o n s t t d = 2 1 4 7 4 8 3 6 4 7 ; R a . k M a x L e n g t h = t d ; c o n s t { U i n t 8 A r r a y : r d , A r r a y B u f f e r : s d , S h a r e d A r r a y B u f f e r : o d } = g l o b a l T h i s ; u d . T Y P E D _ A R R A Y _ S U P P O R T = l d ( ) , ! u d . T Y P E D _ A R R A Y _ S U P P O R T & & t y p e o f c o n s o l e < " u " & & t y p e o f c o n s o l e . e r r o r = = " f u n c t i o n " & & c o n s o l e . e r r o r ( " T h i s b r o w s e r l a c k s t y p e d a r r a y ( U i n t 8 A r r a y ) s u p p o r t w h i c h i s r e q u i r e d b y ` b u f f e r ` v 5 . x . U s e ` b u f f e r ` v 4 . x i f y o u r e q u i r e o l d b r o w s e r s u p p o r t . " ) ; f u n c t i o n l d ( ) { t r y { c o n s t i h = n e w r d ( 1 ) , R f = { f o o : f u n c t i o n ( ) { r e t u r n 4 2 } } ; r e t u r n O b j e c t . s e t P r o t o t y p e O f ( R f , r d . p r o t o t y p e ) , O b j e c t . s e t P r o t o t y p e O f ( i h , R f ) , i h . f o o ( ) = = = 4 2 } c a t c h { r e t u r n ! 1 } } O b j e c t . d e f i n e P r o p e r t y ( u d . p r o t o t y p e , " p a r e n t " , { e n u m e r a b l e : ! 0 , g e t : f u n c t i o n ( ) { i f ( u d . i s B u f f e r ( t h i s ) ) r e t u r n t h i s . b u f f e r } } ) , O b j e c t . d e f i n e P r o p e r t y ( u d . p r o t o t y p e , " o f f s e t " , { e n u m e r a b l e : ! 0 , g e t : f u n c t i o n ( ) { i f ( u d . i s B u f f e r ( t h i s ) ) r e t u r n t h i s . b y t e O f f s e t } } ) ; f u n c t i o n c d ( i h ) { i f ( i h > t d ) t h r o w n e w R a n g e E r r o r ( ' T h e v a l u e " ' + i h + ' " i s i n v a l i d f o r o p t i o n " s i z e " ' ) ; c o n s t R f = n e w r d ( i h ) ; r e t u r n O b j e c t . s e t P r o t o t y p e O f ( R f , u d . p r o t o t y p e ) , R f } f u n c t i o n u d ( i h , R f , D f ) { i f ( t y p e o f i h = = " n u m b e r " ) { i f ( t y p e o f R f = = " s t r i n g " ) t h r o w n e w T y p e E r r o r ( ' T h e " s t r i n g " a r g u m e n t m u s t b e o f t y p e s t r i n g . R e c e i v e d t y p e n u m b e r ' ) ; r e t u r n E d ( i h ) } r e t u r n _ d ( i h , R f , D f ) } u d . p o o l S i z e = 8 1 9 2 ; f u n c t i o n _ d ( i h , R f , D f ) { i f ( t y p e o f i h = = " s t r i n g " ) r e t u r n T d ( i h , R f ) ; i f ( s d . i s V i e w ( i h ) ) r e t u r n R d ( i h ) ; i f ( i h = = n u l l ) t h r o w n e w T y p e E r r o r ( " T h e f i r s t a r g u m e n t m u s t b e o n e o f t y p e s t r i n g , B u f f e r , A r r a y B u f f e r , A r r a y , o r A r r a y - l i k e O b j e c t . R e c e i v e d t y p e " + t y p e o f i h ) ; i f ( B h ( i h , s d ) | | i h & & B h ( i h . b u f f e r , s d ) | | t y p e o f o d < " u " & & ( B h ( i h , o d ) | | i h & & B h ( i h . b u f f e r , o d ) ) ) r e t u r n N d ( i h , R f , D f ) ; i f ( t y p e o f i h = = " n u m b e r " ) t h r o w n e w T y p e E r r o r ( ' T h e " v a l u e " a r g u m e n t m u s t n o t b e o f t y p e n u m b e r . R e c e i v e d t y p e n u m b e r ' ) ; c o n s t Z f = i h . v a l u e O f & & i h . v a l u e O f ( ) ; i f ( Z f ! = n u l l & & Z f ! = = i h ) r e t u r n u d . f r o m ( Z f , R f , D f ) ; c o n s t _ h = I d ( i h ) ; i f ( _ h ) r e t u r n _ h ; i f ( t y p e o f S y m b o l < " u " & & S y m b o l . t o P r i m i t i v e ! = n u l l & & t y p e o f i h [ S y m b o l . t o P r i m i t i v e ] = = " f u n c t i o n " ) r e t u r n u d . f r o m ( i h [ S y m b o l . t o P r i m i t i v e ] ( " s t r i n g " ) , R f , D f ) ; t h r o w n e w T y p e E r r o r ( " T h e f i r s t a r g u m e n t m u s t b e o n e o f t y p e s t r i n g , B u f f e r , A r r a y B u f f e r , A r r a y , o r A r r a y - l i k e O b j e c t . R e c e i v e d t y p e " + t y p e o f i h ) } u d . f r o m = f u n c t i o n ( i h , R f , D f ) { r e t u r n _ d ( i h , R f , D f ) } , O b j e c t . s e t P r o t o t y p e O f ( u d . p r o t o t y p e , r d . p r o t o t y p e ) , O b j e c t . s e t P r o t o t y p e O f ( u d , r d ) ; f u n c t i o n y d ( i h ) { i f ( t y p e o f i h ! = " n u m b e r " ) t h r o w n e w T y p e E r r o r ( ' " s i z e " a r g u m e n t m u s t b e o f t y p e n u m b e r ' ) ; i f ( i h < 0 ) t h r o w n e w R a n g e E r r o r ( ' T h e v a l u e " ' + i h + ' " i s i n v a l i d f o r o p t i o n " s i z e " ' ) } f u n c t i o n g d ( i h , R f , D f ) { r e t u r n y d ( i h ) , i h < = 0 ? c d ( i h ) : R f ! = = v o i d 0 ? t y p e o f D f = = " s t r i n g " ? c d ( i h ) . f i l l ( R f , D f ) : c d ( i h ) . f i l l ( R f ) : c d ( i h ) } u d . a l l o c = f u n c t i o n ( i h , R f , D f ) { r e t u r n g d ( i h , R f , D f ) } ; f u n c t i o n E d ( i h ) { r e t u r n y d ( i h ) , c d ( i h < 0 ? 0 : M d ( i h ) | 0 ) } u d . a l l o c U n s a f e = f u n c t i o n ( i h ) { r e t u r n E d ( i h ) } , u d . a l l o c U n s a f e S l o w = f u n c t i o n ( i h ) { r e t u r n E d ( i h ) } ; f u n c t i o n T d ( i h , R f ) { i f ( ( t y p e o f R f ! = " s t r i n g " | | R f = = = " " ) & & ( R f = " u t f 8 " ) , ! u d . i s E n c o d i n g ( R f ) ) t h r o w n e w T y p e E r r o r ( " U n k n o w n e n c o d i n g : " + R f ) ; c o n s t D f = P d ( i h , R f ) | 0 ; l e t Z f = c d ( D f ) ; c o n s t _ h = Z f . w r i t e ( i h , R f ) ; r e t u r n _ h ! = = D f & & ( Z f = Z f . s l i c e ( 0 , _ h ) ) , Z f } f u n c t i o n O d ( i h ) { c o n s t R f = i h . l e n g t h < 0 ? 0 : M d ( i h . l e n g t h ) | 0 , D f = c d ( R f ) ; f o r ( l e t Z f = 0 ; Z f < R f ; Z f + = 1 ) D f [ Z f ] = i h [ Z f ] & 2 5 5 ; r e t u r n D f } f u n c t i o n R d ( i h ) { i f ( B h ( i h , r d ) ) { c o n s t R f = n e w r d ( i h ) ; r e t u r n N d ( R f . b u f f e r , R f . b y t e O f f s e t , R f . b y t e L e n g t h ) } r e t u r n O d ( i h ) } f u n c t i o n N d ( i h , R f , D f ) { i f ( R f < 0 | | i h . b y t e L e n g t h < R f ) t h r o w n e w R a n g e E r r o r ( ' " o f f s e t " i s o u t s i d e o f b u f f e r b o u n d s ' ) ; i f ( i h . b y t e L e n g t h < R f + ( D f | | 0 ) ) t h r o w n e w R a n g e E r r o r ( ' " l e n g t h " i s o u t s i d e o f b u f f e r b o u n d s ' ) ; l e t Z f ; r e t u r n R f = = = v o i d 0 & & D f = = = v o i d 0 ? Z f = n e w r d ( i h ) : D f = = = v o i d 0 ? Z f = n e w r d ( i h , R f ) : Z f = n e w r d ( i h , R f , D f ) , O b j e c t . s e t P r o t o t y p e O f ( Z f , u d . p r o t o t y p e ) , Z f } f u n c t i o n I d ( i h ) { i f ( u d . i s B u f f e r ( i h ) ) { c o n s t R f = M d ( i h . l e n g t h ) | 0 , D f = c d ( R f ) ; r e t u r n D f . l e n g t h = = = 0 | | i h . c o p y ( D f , 0 , 0 , R f ) , D f } i f ( i h . l e n g t h ! = = v o i d 0 ) r e t u r n t y p e o f i h . l e n g t h ! = " n u m b e r " | | J h ( i h . l e n g t h ) ? c d ( 0 ) : O d ( i h ) ; i f ( i h . t y p e = = = " B u f f e r " & & A r r a y . i s A r r a y ( i h . d a t a ) ) r e t u r n O d ( i h . d a t a ) } f u n c t i o n M d ( i h ) { i f ( i h > = t d ) t h r o w n e w R a n g e E r r o r ( " A t t e m p t t o a l l o c a t e B u f f e r l a r g e r t h a n m a x i m u m s i z e : 0 x " + t d . t o S t r i n g ( 1 6 ) + " b y t e s " ) ; r e t u r n i h | 0 } f u n c t i o n L d ( i h ) { r e t u r n + i h !
https : //github.com/highlightjs/highlight.js/issues/2277`),Yf=mf,Kf=xf),Lf===void 0&&(Lf=!0);const Of={code:Kf,language:Yf};Qd("before:highlight",Of);const Tf=Of.result?Of.result:_d(Of.language,Of.code,Lf);return Tf.code=Of.code,Qd("after:highlight",Tf),Tf}function _d(mf,xf,Lf,Kf){const Yf=Object.create(null);function Of(zh,sm){return zh.keywords[sm]}function Tf(){if(!Pf.keywords){Ah.addText(uh);return}let zh=0;Pf.keywordPatternRe.lastIndex=0;let sm=Pf.keywordPatternRe.exec(uh),fm="";for(;sm;){fm+=uh.substring(zh,sm.index);const ih=Vf.case_insensitive?sm[0].toLowerCase():sm[0],Rf=Of(Pf,ih);if(Rf){const[Df,Zf]=Rf;if(Ah.addText(fm),fm="",Yf[ih]=(Yf[ih]||0)+1,Yf[ih]<=MAX_KEYWORD_HITS&&(Fh+=Zf),Df.startsWith("_"))fm+=sm[0];else{const _h=Vf.classNameAliases[Df]||Df;Uf(sm[0],_h)}}else fm+=sm[0];zh=Pf.keywordPatternRe.lastIndex,sm=Pf.keywordPatternRe.exec(uh)}fm+=uh.substring(zh),Ah.addText(fm)}function wf(){if(uh==="")return;let zh=null;if(typeof Pf.subLanguage=="string"){if(!qa[Pf.subLanguage]){Ah.addText(uh);return}zh=_d(Pf.subLanguage,uh,!0,hh[Pf.subLanguage]),hh[Pf.subLanguage]=zh._top}else zh=gd(uh,Pf.subLanguage.length?Pf.subLanguage:null);Pf.relevance>0&&(Fh+=zh.relevance),Ah.__addSublanguage(zh._emitter,zh.language)}function Wf(){Pf.subLanguage!=null?wf():Tf(),uh=""}function Uf(zh,sm){zh!==""&&(Ah.startScope(sm),Ah.addText(zh),Ah.endScope())}function gf(zh,sm){let fm=1;const ih=sm.length-1;for(;fm<=ih;){if(!zh._emit[fm]){fm++;continue}const Rf=Vf.classNameAliases[zh[fm]]||zh[fm],Df=sm[fm];Rf?Uf(Df,Rf):(uh=Df,Tf(),uh=""),fm++}}function _f(zh,sm){return zh.scope&&typeof zh.scope=="string"&&Ah.openNode(Vf.classNameAliases[zh.scope]||zh.scope),zh.beginScope&&(zh.beginScope._wrap?(Uf(uh,Vf.classNameAliases[zh.beginScope._wrap]||zh.beginScope._wrap),uh=""):zh.beginScope._multi&&(gf(zh.beginScope,sm),uh="")),Pf=Object.create(zh,{parent:{value:Pf}}),Pf}function $f(zh,sm,fm){let ih=startsWith$1(zh.endRe,fm);if(ih){if(zh["on:end"]){const Rf=new Response$1(zh);zh["on:end"](sm,Rf),Rf.isMatchIgnored&&(ih=!1)}if(ih){for(;zh.endsParent&&zh.parent;)zh=zh.parent;return zh}}if(zh.endsWithParent)return $f(zh.parent,sm,fm)}function Gf(zh){return Pf.matcher.regexIndex===0?(uh+=zh[0],1):(Jh=!0,0)}function dh(zh){const sm=zh[0],fm=zh.rule,ih=new Response$1(fm),Rf=[fm.__beforeBegin,fm["on:begin"]];for(const Df of Rf)if(Df&&(Df(zh,ih),ih.isMatchIgnored))return Gf(sm);return fm.skip?uh+=sm:(fm.excludeBegin&&(uh+=sm),Wf(),!fm.returnBegin&&!fm.excludeBegin&&(uh=sm)),_f(fm,zh),fm.returnBegin?0:sm.length}function zf(zh){const sm=zh[0],fm=xf.substring(zh.index),ih=$f(Pf,zh,fm);if(!ih)return NO_MATCH;const Rf=Pf;Pf.endScope&&Pf.endScope._wrap?(Wf(),Uf(sm,Pf.endScope._wrap)):Pf.endScope&&Pf.endScope._multi?(Wf(),gf(Pf.endScope,zh)):Rf.skip?uh+=sm:(Rf.returnEnd||Rf.excludeEnd||(uh+=sm),Wf(),Rf.excludeEnd&&(uh=sm));do Pf.scope&&Ah.closeNode(),!Pf.skip&&!Pf.subLanguage&&(Fh+=Pf.relevance),Pf=Pf.parent;while(Pf!==ih.parent);return ih.starts&&_f(ih.starts,zh),Rf.returnEnd?0:sm.length}function If(){const zh=[];for(let sm=Pf;sm!==Vf;sm=sm.parent)sm.scope&&zh.unshift(sm.scope);zh.forEach(sm=>Ah.openNode(sm))}let Jf={};function Th(zh,sm){const fm=sm&&sm[0];if(uh+=zh,fm==null)return Wf(),0;if(Jf.type==="begin"&&sm.type==="end"&&Jf.index===sm.index&&fm===""){if(uh+=xf.slice(sm.index,sm.index+1),!td){const ih=new Error(`0 width match regex (${mf})`);throw ih.languageName=mf,ih.badRule=Jf.rule,ih}return 1}if(Jf=sm,sm.type==="begin")return dh(sm);if(sm.type==="illegal"&&!Lf){const ih=new Error('Illegal lexeme "'+fm+'" for mode "'+(Pf.scope||"<unnamed>")+'"');throw ih.mode=Pf,ih}else if(sm.type==="end"){const ih=zf(sm);if(ih!==NO_MATCH)return ih}if(sm.type==="illegal"&&fm==="")return 1;if(Bh>1e5&&Bh>sm.index*3)throw new Error("potential infinite loop, way more iterations than matches");return uh+=fm,fm.length}const Vf=Ud(mf);if(!Vf)throw error(rd.replace("{}",mf)),new Error('Unknown language: "'+mf+'"');const Ef=compileLanguage(Vf);let Af="",Pf=Kf||Ef;const hh={},Ah=new od.__emitter(od);If();let uh="",Fh=0,Nh=0,Bh=0,Jh=!1;try{if(Vf.__emitTokens)Vf.__emitTokens(xf,Ah
` },Ed]}}return kotlin_1=td,kotlin_1}var lasso_1,hasRequiredLasso;function requireLasso(){if(hasRequiredLasso)return lasso_1;hasRequiredLasso=1;function Ra(qa){const Ja="[a-zA-Z_][ \\ w.]*",ed="< \\ ?(lasso(script)?|=)",td=" \\ ]| \\ ?>",rd={ $ pattern:Ja+"|&[lg]t;",literal:"true false none minimal full all void and or not bw nbw ew new cn ncn lt lte gt gte eq neq rx nrx ft",built_in:"array date decimal duration integer map pair string tag xml null boolean bytes keyword list locale queue set stack staticarray local var variable global data self inherited currentcapture givenblock",keyword:"cache database_names database_schemanames database_tablenames define_tag define_type email_batch encode_set html_comment handle handle_error header if inline iterate ljax_target link link_currentaction link_currentgroup link_currentrecord link_detail link_firstgroup link_firstrecord link_lastgroup link_lastrecord link_nextgroup link_nextrecord link_prevgroup link_prevrecord log loop namespace_using output_none portal private protect records referer referrer repeating resultset rows search_args search_arguments select sort_args sort_arguments thread_atomic value_list while abort case else fail_if fail_ifnot fail if_empty if_false if_null if_true loop_abort loop_continue loop_count params params_up return return_value run_children soap_definetag soap_lastrequest soap_lastresponse tag_name ascending average by define descending do equals frozen group handle_failure import in into join let match max min on order parent protected provide public require returnhome skip split_thread sum take thread to trait type where with yield yieldhome"},sd=qa.COMMENT("<!--","-->",{relevance:0}),od={className:"meta",begin:" \\ [noprocess \\ ]",starts:{end:" \\ [/noprocess \\ ]",returnEnd:!0,contains:[sd]}},ld={className:"meta",begin:" \\ [/noprocess|"+ed},cd={className:"symbol",begin:"'"+Ja+"'"},ud=[qa.C_LINE_COMMENT_MODE,qa.C_BLOCK_COMMENT_MODE,qa.inherit(qa.C_NUMBER_MODE,{begin:qa.C_NUMBER_RE+"|(-?infinity|NaN) \\ b"}),qa.inherit(qa.APOS_STRING_MODE,{illegal:null}),qa.inherit(qa.QUOTE_STRING_MODE,{illegal:null}),{className:"string",begin:" ` ",end:" ` "},{variants:[{begin:"[# $ ]"+Ja},{begin:"#",end:" \\ d+",illegal:" \\ W"}]},{className:"type",begin:":: \\ s*",end:Ja,illegal:" \\ W"},{className:"params",variants:[{begin:"-(?!infinity)"+Ja,relevance:0},{begin:"( \\ . \\ . \\ .)"}]},{begin:/(->| \. ) \s */,relevance:0,contains:[cd]},{className:"class",beginKeywords:"define",returnEnd:!0,end:" \\ (|=>",contains:[qa.inherit(qa.TITLE_MODE,{begin:Ja+"(=(?!>))?|[-+*/%](?!>)"})]}];return{name:"Lasso",aliases:["ls","lassoscript"],case_insensitive:!0,keywords:rd,contains:[{className:"meta",begin:td,relevance:0,starts:{end:" \\ [|"+ed,returnEnd:!0,relevance:0,contains:[sd]}},od,ld,{className:"meta",begin:" \\ [no_square_brackets",starts:{end:" \\ [/no_square_brackets \\ ]",keywords:rd,contains:[{className:"meta",begin:td,relevance:0,starts:{end:" \\ [noprocess \\ ]|"+ed,returnEnd:!0,contains:[sd]}},od,ld].concat(ud)}},{className:"meta",begin:" \\ [",relevance:0},{className:"meta",begin:"^#!",end:"lasso9 $ ",relevance:10}].concat(ud)}}return lasso_1=Ra,lasso_1}var latex_1,hasRequiredLatex;function requireLatex(){if(hasRequiredLatex)return latex_1;hasRequiredLatex=1;function Ra(qa){const ed=qa.regex.either(...["(?:NeedsTeXFormat|RequirePackage|GetIdInfo)","Provides(?:Expl)?(?:Package|Class|File)","(?:DeclareOption|ProcessOptions)","(?:documentclass|usepackage|input|include)","makeat(?:letter|other)","ExplSyntax(?:On|Off)","(?:new|renew|provide)?command","(?:re)newenvironment","(?:New|Renew|Provide|Declare)(?:Expandable)?DocumentCommand","(?:New|Renew|Provide|Declare)DocumentEnvironment","(?:(?:e|g|x)?def|let)","(?:begin|end)","(?:part|chapter|(?:sub){0,2}section|(?:sub)?paragraph)","caption","(?:label|(?:eq|page|name)?ref|(?:paren|foot|super)?cite)","(?:alpha|beta|[Gg]amma|[Dd]elta|(?:var)?epsilon|zeta|eta|[Tt]heta|vartheta)","(?:iota|(?:var)?kappa|[Ll]ambda|mu|nu|[Xx]i|[Pp]i|varpi|(?:var)rho)","(?:[Ss]igma|varsigma|tau|[Uu]psilon|[Pp]hi|varphi|chi|[Pp]si|[Oo]mega)","(?:frac|sum|prod|lim|infty|times|sqrt|leq|geq|left|right|middl
] ` ,Ed={scope:"string",variants:[ud,cd,_d,yd]},Td={scope:"number",variants:[{begin:" \\ b0[bB][01]+(?:_[01]+)* \\ b"},{begin:" \\ b0[oO][0-7]+(?:_[0-7]+)* \\ b"},{begin:" \\ b0[xX][ \\ da-fA-F]+(?:_[ \\ da-fA-F]+)* \\ b"},{begin:"(?: \\ b \\ d+(?:_ \\ d+)*( \\ .(?: \\ d+(?:_ \\ d+)*))?| \\ B \\ . \\ d+)(?:[eE][+-]? \\ d+)?"}],relevance:0},Od=["false","null","true"],Rd=["__CLASS__","__DIR__","__FILE__","__FUNCTION__","__COMPILER_HALT_OFFSET__","__LINE__","__METHOD__","__NAMESPACE__","__TRAIT__","die","echo","exit","include","include_once","print","require","require_once","array","abstract","and","as","binary","bool","boolean","break","callable","case","catch","class","clone","const","continue","declare","default","do","double","else","elseif","empty","enddeclare","endfor","endforeach","endif","endswitch","endwhile","enum","eval","extends","final","finally","float","for","foreach","from","global","goto","if","implements","instanceof","insteadof","int","integer","interface","isset","iterable","list","match|0","mixed","new","never","object","or","private","protected","public","readonly","real","return","string","switch","throw","trait","try","unset","use","var","void","while","xor","yield"],Nd=["Error|0","AppendIterator","ArgumentCountError","ArithmeticError","ArrayIterator","ArrayObject","AssertionError","BadFunctionCallException","BadMethodCallException","CachingIterator","CallbackFilterIterator","CompileError","Countable","DirectoryIterator","DivisionByZeroError","DomainException","EmptyIterator","ErrorException","Exception","FilesystemIterator","FilterIterator","GlobIterator","InfiniteIterator","InvalidArgumentException","IteratorIterator","LengthException","LimitIterator","LogicException","MultipleIterator","NoRewindIterator","OutOfBoundsException","OutOfRangeException","OuterIterator","OverflowException","ParentIterator","ParseError","RangeException","RecursiveArrayIterator","RecursiveCachingIterator","RecursiveCallbackFilterIterator","RecursiveDirectoryIterator","RecursiveFilterIterator","RecursiveIterator","RecursiveIteratorIterator","RecursiveRegexIterator","RecursiveTreeIterator","RegexIterator","RuntimeException","SeekableIterator","SplDoublyLinkedList","SplFileInfo","SplFileObject","SplFixedArray","SplHeap","SplMaxHeap","SplMinHeap","SplObjectStorage","SplObserver","SplPriorityQueue","SplQueue","SplStack","SplSubject","SplTempFileObject","TypeError","UnderflowException","UnexpectedValueException","UnhandledMatchError","ArrayAccess","BackedEnum","Closure","Fiber","Generator","Iterator","IteratorAggregate","Serializable","Stringable","Throwable","Traversable","UnitEnum","WeakReference","WeakMap","Directory","__PHP_Incomplete_Class","parent","php_user_filter","self","static","stdClass"],Md={keyword:Rd,literal:(pf=>{const Qd=[];return pf.forEach(hf=>{Qd.push(hf),hf.toLowerCase()===hf?Qd.push(hf.toUpperCase()):Qd.push(hf.toLowerCase())}),Qd})(Od),built_in:Nd},Ld=pf=>pf.map(Qd=>Qd.replace(/ \| \d + $ /,"")),Pd={variants:[{match:[/new/,Ja.concat(gd,"+"),Ja.concat("(?!",Ld(Nd).join(" \\ b|")," \\ b)"),rd],scope:{1:"keyword",4:"title.class"}}]},qd=Ja.concat(td," \\ b(?! \\ ()"),Yd={variants:[{match:[Ja.concat(/::/,Ja.lookahead(/(?!class \b )/)),qd],scope:{2:"variable.constant"}},{match:[/::/,/class/],scope:{2:"variable.language"}},{match:[rd,Ja.concat(/::/,Ja.lookahead(/(?!class \b )/)),qd],scope:{1:"title.class",3:"variable.constant"}},{match:[rd,Ja.concat("::",Ja.lookahead(/(?!class \b )/))],scope:{1:"title.class"}},{match:[rd,/::/,/class/],scope:{1:"title.class",3:"variable.language"}}]},Ud={scope:"attr",match:Ja.concat(td,Ja.lookahead(":"),Ja.lookahead(/(?!::)/))},Hd={relevance:0,begin:/ \( /,end:/ \) /,keywords:Md,contains:[Ud,sd,Yd,qa.C_BLOCK_COMMENT_MODE,Ed,Td,Pd]},zd={relevance:0,match:[/ \b /,Ja.concat("(?!fn \\ b|function \\ b|",Ld(Rd).join(" \\ b|"),"|",Ld(Nd).join(" \\ b|")," \\ b)"),td,Ja.concat(gd,"*"),Ja.lookahead(/(?= \( )/)],scope:{3:"title.function.invoke"},contains:[Hd]};Hd.contains.push(zd);const Jd=[Ud,Yd,qa.C_BLOCK_COMMENT_MODE,Ed,Td,Pd],Zd={begin:Ja.concat(/# \[ \s */,rd),beginScope:"meta",end:/]/,endScope:"meta",keywords:{literal:Od,keyword:["new","array"]},contains:[{begi
] * ; ` ,relevance:0},{begin:"[vp][0-9]+"}]}}return smali_1=Ra,smali_1}var smalltalk_1,hasRequiredSmalltalk;function requireSmalltalk(){if(hasRequiredSmalltalk)return smalltalk_1;hasRequiredSmalltalk=1;function Ra(qa){const Ja="[a-z][a-zA-Z0-9_]*",ed={className:"string",begin:" \\ $ .{1}"},td={className:"symbol",begin:"#"+qa.UNDERSCORE_IDENT_RE};return{name:"Smalltalk",aliases:["st"],keywords:["self","super","nil","true","false","thisContext"],contains:[qa.COMMENT('"','"'),qa.APOS_STRING_MODE,{className:"type",begin:" \\ b[A-Z][A-Za-z0-9_]*",relevance:0},{begin:Ja+":",relevance:0},qa.C_NUMBER_MODE,td,ed,{begin:" \\ |[ ]*"+Ja+"([ ]+"+Ja+")*[ ]* \\ |",returnBegin:!0,end:/ \| /,illegal:/ \S /,contains:[{begin:"( \\ |[ ]*)?"+Ja}]},{begin:"# \\ (",end:" \\ )",contains:[qa.APOS_STRING_MODE,ed,qa.C_NUMBER_MODE,td]}]}}return smalltalk_1=Ra,smalltalk_1}var sml_1,hasRequiredSml;function requireSml(){if(hasRequiredSml)return sml_1;hasRequiredSml=1;function Ra(qa){return{name:"SML (Standard ML)",aliases:["ml"],keywords:{ $ pattern:"[a-z_] \\ w*!?",keyword:"abstype and andalso as case datatype do else end eqtype exception fn fun functor handle if in include infix infixr let local nonfix of op open orelse raise rec sharing sig signature struct structure then type val with withtype where while",built_in:"array bool char exn int list option order real ref string substring vector unit word",literal:"true false NONE SOME LESS EQUAL GREATER nil"},illegal:/ \/ \/ |>>/,contains:[{className:"literal",begin:/ \[ ( \| \| )? \] | \( \) /,relevance:0},qa.COMMENT(" \\ ( \\ *"," \\ * \\ )",{contains:["self"]}),{className:"symbol",begin:"'[A-Za-z_](?!')[ \\ w']*"},{className:"type",begin:" ` [ A - Z ] [ \ \ w ']*"},{className:"type",begin:"\\b[A-Z][\\w' ] * ",relevance:0},{begin:" [ a - z _ ] \ \ w * '[\\w' ] * "},qa.inherit(qa.APOS_STRING_MODE,{className:" string ",relevance:0}),qa.inherit(qa.QUOTE_STRING_MODE,{illegal:null}),{className:" number ",begin:" \ \ b ( 0 [ xX ] [ a - fA - F0 - 9_ ] + [ Lln ] ? | 0 [ oO ] [ 0 - 7_ ] + [ Lln ] ? | 0 [ bB ] [ 01_ ] + [ Lln ] ? | [ 0 - 9 ] [ 0 - 9_ ] * ( [ Lln ] | ( \ \ . [ 0 - 9_ ] * ) ? ( [ eE ] [ - + ] ? [ 0 - 9_ ] + ) ? ) ? ) ",relevance:0},{begin:/[-=]>/}]}}return sml_1=Ra,sml_1}var sqf_1,hasRequiredSqf;function requireSqf(){if(hasRequiredSqf)return sqf_1;hasRequiredSqf=1;function Ra(qa){const Ja={className:" variable ",begin:/\b_+[a-zA-Z]\w*/},ed={className:" title ",begin:/[a-zA-Z][a-zA-Z_0-9]*_fnc_[a-zA-Z_0-9]+/},td={className:" string ",variants:[{begin:'" ',end:' "',contains:[{begin:'" "',relevance:0}]},{begin:" '",end:"' ",contains:[{begin:" '' ",relevance:0}]}]},rd=[" break "," breakWith "," breakOut "," breakTo "," case "," catch "," continue "," continueWith "," default "," do "," else "," exit "," exitWith "," for "," forEach "," from "," if "," local "," private "," switch "," step "," then "," throw "," to "," try "," waitUntil "," while "," with "],sd=[" blufor "," civilian "," configNull "," controlNull "," displayNull "," diaryRecordNull "," east "," endl "," false "," grpNull "," independent "," lineBreak "," locationNull "," nil "," objNull "," opfor "," pi "," resistance "," scriptNull "," sideAmbientLife "," sideEmpty "," sideEnemy "," sideFriendly "," sideLogic "," sideUnknown "," taskNull "," teamMemberNull "," true "," west "],od=[" abs "," accTime "," acos "," action "," actionIDs "," actionKeys "," actionKeysEx "," actionKeysImages "," actionKeysNames "," actionKeysNamesArray "," actionName "," actionParams "," activateAddons "," activatedAddons "," activateKey "," activeTitleEffectParams "," add3DENConnection "," add3DENEventHandler "," add3DENLayer "," addAction "," addBackpack "," addBackpackCargo "," addBackpackCargoGlobal "," addBackpackGlobal "," addBinocularItem "," addCamShake "," addCuratorAddons "," addCuratorCameraArea "," addCuratorEditableObjects "," addCuratorEditingArea "," addCuratorPoints "," addEditorObject "," addEventHandler "," addForce "," addForceGeneratorRTD "," addGoggles "," addGroupIcon "," addHandgunItem "," addHeadgear "," addItem "," addItemCargo "," addItemCargoGlobal "," addItemPool "," addItemToBackpack "," addItemToUniform "," addItemToVest "," addLiveStats "," addMagazine "," addMagazineAmmoCargo "," addMagazineCargo "," addMagazineCargoGlobal "," addMagazineGlobal "," addMagazinePool "," addMagazines "," addMagazineTurret "," addMenu "," addMenuItem "," addMissionEventHandler "," addMPEventHandler "," addMusicEventHandler "," addonFiles "," addOwnedMine "," addPlayerSc
2024-08-27 22:31:52 +08:00
] * ? "'`},{begin:`" [ ^ \ r
2024-09-03 08:22:14 +08:00
"]*" ` }]},{className:"built_in",variants:[{begin:" \\ b(abs|acos|asin|atan|atan2|atanh|ceil|cloglog|comb|cos|digamma|exp|floor|invcloglog|invlogit|ln|lnfact|lnfactorial|lngamma|log|log10|max|min|mod|reldif|round|sign|sin|sqrt|sum|tan|tanh|trigamma|trunc|betaden|Binomial|binorm|binormal|chi2|chi2tail|dgammapda|dgammapdada|dgammapdadx|dgammapdx|dgammapdxdx|F|Fden|Ftail|gammaden|gammap|ibeta|invbinomial|invchi2|invchi2tail|invF|invFtail|invgammap|invibeta|invnchi2|invnFtail|invnibeta|invnorm|invnormal|invttail|nbetaden|nchi2|nFden|nFtail|nibeta|norm|normal|normalden|normd|npnchi2|tden|ttail|uniform|abbrev|char|index|indexnot|length|lower|ltrim|match|plural|proper|real|regexm|regexr|regexs|reverse|rtrim|string|strlen|strlower|strltrim|strmatch|strofreal|strpos|strproper|strreverse|strrtrim|strtrim|strupper|subinstr|subinword|substr|trim|upper|word|wordcount|_caller|autocode|byteorder|chop|clip|cond|e|epsdouble|epsfloat|group|inlist|inrange|irecode|matrix|maxbyte|maxdouble|maxfloat|maxint|maxlong|mi|minbyte|mindouble|minfloat|minint|minlong|missing|r|recode|replay|return|s|scalar|d|date|day|dow|doy|halfyear|mdy|month|quarter|week|year|d|daily|dofd|dofh|dofm|dofq|dofw|dofy|h|halfyearly|hofd|m|mofd|monthly|q|qofd|quarterly|tin|twithin|w|weekly|wofd|y|yearly|yh|ym|yofd|yq|yw|cholesky|colnumb|colsof|corr|det|diag|diag0cnt|el|get|hadamard|I|inv|invsym|issym|issymmetric|J|matmissing|matuniform|mreldif|nullmat|rownumb|rowsof|sweep|syminv|trace|vec|vecdiag)(?= \\ ()"}]},qa.COMMENT("^[ ]* \\ *.* $ ",!1),qa.C_LINE_COMMENT_MODE,qa.C_BLOCK_COMMENT_MODE]}}return stata_1=Ra,stata_1}var step21_1,hasRequiredStep21;function requireStep21(){if(hasRequiredStep21)return step21_1;hasRequiredStep21=1;function Ra(qa){return{name:"STEP Part 21",aliases:["p21","step","stp"],case_insensitive:!0,keywords:{ $ pattern:"[A-Z_][A-Z0-9_.]*",keyword:["HEADER","ENDSEC","DATA"]},contains:[{className:"meta",begin:"ISO-10303-21;",relevance:10},{className:"meta",begin:"END-ISO-10303-21;",relevance:10},qa.C_LINE_COMMENT_MODE,qa.C_BLOCK_COMMENT_MODE,qa.COMMENT("/ \\ * \\ *!"," \\ */"),qa.C_NUMBER_MODE,qa.inherit(qa.APOS_STRING_MODE,{illegal:null}),qa.inherit(qa.QUOTE_STRING_MODE,{illegal:null}),{className:"string",begin:"'",end:"'"},{className:"symbol",variants:[{begin:"#",end:" \\ d+",illegal:" \\ W"}]}]}}return step21_1=Ra,step21_1}var stylus_1,hasRequiredStylus;function requireStylus(){if(hasRequiredStylus)return stylus_1;hasRequiredStylus=1;const Ra=cd=>({IMPORTANT:{scope:"meta",begin:"!important"},BLOCK_COMMENT:cd.C_BLOCK_COMMENT_MODE,HEXCOLOR:{scope:"number",begin:/#(([0-9a-fA-F]{3,4})|(([0-9a-fA-F]{2}){3,4})) \b /},FUNCTION_DISPATCH:{className:"built_in",begin:/[ \w -]+(?= \( )/},ATTRIBUTE_SELECTOR_MODE:{scope:"selector-attr",begin:/ \[ /,end:/ \] /,illegal:" $ ",contains:[cd.APOS_STRING_MODE,cd.QUOTE_STRING_MODE]},CSS_NUMBER_MODE:{scope:"number",begin:cd.NUMBER_RE+"(%|em|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc|px|deg|grad|rad|turn|s|ms|Hz|kHz|dpi|dpcm|dppx)?",relevance:0},CSS_VARIABLE:{className:"attr",begin:/--[A-Za-z_][A-Za-z0-9_-]*/}}),qa=["a","abbr","address","article","aside","audio","b","blockquote","body","button","canvas","caption","cite","code","dd","del","details","dfn","div","dl","dt","em","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","header","hgroup","html","i","iframe","img","input","ins","kbd","label","legend","li","main","mark","menu","nav","object","ol","optgroup","option","p","picture","q","quote","samp","section","select","source","span","strong","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","tr","ul","var","video"],Ja=["defs","g","marker","mask","pattern","svg","switch","symbol","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feFlood","feGaussianBlur","feImage","feMerge","feMorphology","feOffset","feSpecularLighting","feTile","feTurbulence","linearGradient","radialGradient","stop","circle","ellipse","image","line","path","polygon","polyline","rect","text","use","textPath","tspan","foreignObject","clipPath"],ed=[...qa,...Ja],td=["any
2024-08-27 22:31:52 +08:00
( multipart ) ? ` ,end: ` \ \ ]
2024-09-08 17:22:36 +08:00
` },{className:"string",begin:" \\ d{4}- \\ d{2}- \\ d{2}( \\ s+) \\ d{2}: \\ d{2}: \\ d{2}. \\ d+Z"},{className:"string",begin:"( \\ +|-) \\ d+"},{className:"keyword",relevance:10,variants:[{begin:"^(test|testing|success|successful|failure|error|skip|xfail|uxsuccess)(:?) \\ s+(test)?"},{begin:"^progress(:?)( \\ s+)?(pop|push)?"},{begin:"^tags:"},{begin:"^time:"}]}]}}return subunit_1=Ra,subunit_1}var swift_1,hasRequiredSwift;function requireSwift(){if(hasRequiredSwift)return swift_1;hasRequiredSwift=1;function Ra(Yd){return Yd?typeof Yd=="string"?Yd:Yd.source:null}function qa(Yd){return Ja("(?=",Yd,")")}function Ja(...Yd){return Yd.map(Hd=>Ra(Hd)).join("")}function ed(Yd){const Ud=Yd[Yd.length-1];return typeof Ud=="object"&&Ud.constructor===Object?(Yd.splice(Yd.length-1,1),Ud):{}}function td(...Yd){return"("+(ed(Yd).capture?"":"?:")+Yd.map(zd=>Ra(zd)).join("|")+")"}const rd=Yd=>Ja(/ \b /,Yd,/ \w $ /.test(Yd)?/ \b /:/ \B /),sd=["Protocol","Type"].map(rd),od=["init","self"].map(rd),ld=["Any","Self"],cd=["actor","any","associatedtype","async","await",/as \? /,/as!/,"as","borrowing","break","case","catch","class","consume","consuming","continue","convenience","copy","default","defer","deinit","didSet","distributed","do","dynamic","each","else","enum","extension","fallthrough",/fileprivate \( set \) /,"fileprivate","final","for","func","get","guard","if","import","indirect","infix",/init \? /,/init!/,"inout",/internal \( set \) /,"internal","in","is","isolated","nonisolated","lazy","let","macro","mutating","nonmutating",/open \( set \) /,"open","operator","optional","override","package","postfix","precedencegroup","prefix",/private \( set \) /,"private","protocol",/public \( set \) /,"public","repeat","required","rethrows","return","set","some","static","struct","subscript","super","switch","throws","throw",/try \? /,/try!/,"try","typealias",/unowned \( safe \) /,/unowned \( unsafe \) /,"unowned","var","weak","where","while","willSet"],ud=["false","nil","true"],_d=["assignment","associativity","higherThan","left","lowerThan","none","right"],yd=["#colorLiteral","#column","#dsohandle","#else","#elseif","#endif","#error","#file","#fileID","#fileLiteral","#filePath","#function","#if","#imageLiteral","#keyPath","#line","#selector","#sourceLocation","#warning"],gd=["abs","all","any","assert","assertionFailure","debugPrint","dump","fatalError","getVaList","isKnownUniquelyReferenced","max","min","numericCast","pointwiseMax","pointwiseMin","precondition","preconditionFailure","print","readLine","repeatElement","sequence","stride","swap","swift_unboxFromSwiftValueWithType","transcode","type","unsafeBitCast","unsafeDowncast","withExtendedLifetime","withUnsafeMutablePointer","withUnsafePointer","withVaList","withoutActuallyEscaping","zip"],Ed=td(/[/= \- +!*%<>&|^~?]/,/[ \u 00A1- \u 00A7]/,/[ \u 00A9 \u 00AB]/,/[ \u 00AC \u 00AE]/,/[ \u 00B0 \u 00B1]/,/[ \u 00B6 \u 00BB \u 00BF \u 00D7 \u 00F7]/,/[ \u 2016- \u 2017]/,/[ \u 2020- \u 2027]/,/[ \u 2030- \u 203E]/,/[ \u 2041- \u 2053]/,/[ \u 2055- \u 205E]/,/[ \u 2190- \u 23FF]/,/[ \u 2500- \u 2775]/,/[ \u 2794- \u 2BFF]/,/[ \u 2E00- \u 2E7F]/,/[ \u 3001- \u 3003]/,/[ \u 3008- \u 3020]/,/[ \u 3030]/),Td=td(Ed,/[ \u 0300- \u 036F]/,/[ \u 1DC0- \u 1DFF]/,/[ \u 20D0- \u 20FF]/,/[ \u FE00- \u FE0F]/,/[ \u FE20- \u FE2F]/),Od=Ja(Ed,Td,"*"),Rd=td(/[a-zA-Z_]/,/[ \u 00A8 \u 00AA \u 00AD \u 00AF \u 00B2- \u 00B5 \u 00B7- \u 00BA]/,/[ \u 00BC- \u 00BE \u 00C0- \u 00D6 \u 00D8- \u 00F6 \u 00F8- \u 00FF]/,/[ \u 0100- \u 02FF \u 0370- \u 167F \u 1681- \u 180D \u 180F- \u 1DBF]/,/[ \u 1E00- \u 1FFF]/,/[ \u 200B- \u 200D \u 202A- \u 202E \u 203F- \u 2040 \u 2054 \u 2060- \u 206F]/,/[ \u 2070- \u 20CF \u 2100- \u 218F \u 2460- \u 24FF \u 2776- \u 2793]/,/[ \u 2C00- \u 2DFF \u 2E80- \u 2FFF]/,/[ \u 3004- \u 3007 \u 3021- \u 302F \u 3031- \u 303F \u 3040- \u D7FF]/,/[ \u F900- \u FD3D \u FD40- \u FDCF \u FDF0- \u FE1F \u FE30- \u FE44]/,/[ \u FE47- \u FEFE \u FF00- \u FFFD]/),Nd=td(Rd,/ \d /,/[ \u 0300- \u 036F \u 1DC0- \u 1DFF \u 20D0- \u 20FF \u FE20- \u FE2F]/),Id=Ja(Rd,Nd,"*"),Md=Ja(/[A-Z]/,Nd,"*"),Ld=["attached","autoclosure",Ja(/convention \( /,td("swift","block","c"),/ \) /),"discardableResult","dynamicCallable","dynamicMemberLookup","escaping","freestanding","frozen","GKInspectable","IBAction","IBDesignable","IBInspectable","IBOutlet","IBSegueAction","inlinable","main","nonobjc","NSApplicationMain","NSCopying","N
` +m_),zf&&arrayForEach([Jd,Zd,pf],f_=>{m_=stringReplace(m_,f_," ")}),Md&&Pf?Md.createHTML(m_):m_},qa.setConfig=function(){let $ h=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};y_( $ h),Th=!0},qa.clearConfig=function(){Jm=null,Th=!1},qa.isValidAttribute=function( $ h,wh,um){Jm||y_({});const cm=Mm( $ h),_m=Mm(wh);return yh(cm,_m,um)},qa.addHook=function( $ h,wh){typeof wh=="function"&&(zd[ $ h]=zd[ $ h]||[],arrayPush(zd[ $ h],wh))},qa.removeHook=function( $ h){if(zd[ $ h])return arrayPop(zd[ $ h])},qa.removeHooks=function( $ h){zd[ $ h]&&(zd[ $ h]=[])},qa.removeAllHooks=function(){zd={}},qa}var purify=createDOMPurify(),__defProp=Object.defineProperty,__name=(Ra,qa)=>__defProp(Ra,"name",{value:qa,configurable:!0}),__export=(Ra,qa)=>{for(var Ja in qa)__defProp(Ra,Ja,{get:qa[Ja],enumerable:!0})},LEVELS={trace:0,debug:1,info:2,warn:3,error:4,fatal:5},log $ 1={trace:__name((...Ra)=>{},"trace"),debug:__name((...Ra)=>{},"debug"),info:__name((...Ra)=>{},"info"),warn:__name((...Ra)=>{},"warn"),error:__name((...Ra)=>{},"error"),fatal:__name((...Ra)=>{},"fatal")},setLogLevel=__name(function(Ra="fatal"){let qa=LEVELS.fatal;typeof Ra=="string"?Ra.toLowerCase()in LEVELS&&(qa=LEVELS[Ra]):typeof Ra=="number"&&(qa=Ra),log $ 1.trace=()=>{},log $ 1.debug=()=>{},log $ 1.info=()=>{},log $ 1.warn=()=>{},log $ 1.error=()=>{},log $ 1.fatal=()=>{},qa<=LEVELS.fatal&&(log $ 1.fatal=console.error?console.error.bind(console,format $ 1("FATAL"),"color: orange"):console.log.bind(console," \x 1B[35m",format $ 1("FATAL"))),qa<=LEVELS.error&&(log $ 1.error=console.error?console.error.bind(console,format $ 1("ERROR"),"color: orange"):console.log.bind(console," \x 1B[31m",format $ 1("ERROR"))),qa<=LEVELS.warn&&(log $ 1.warn=console.warn?console.warn.bind(console,format $ 1("WARN"),"color: orange"):console.log.bind(console," \x 1B[33m",format $ 1("WARN"))),qa<=LEVELS.info&&(log $ 1.info=console.info?console.info.bind(console,format $ 1("INFO"),"color: lightblue"):console.log.bind(console," \x 1B[34m",format $ 1("INFO"))),qa<=LEVELS.debug&&(log $ 1.debug=console.debug?console.debug.bind(console,format $ 1("DEBUG"),"color: lightgreen"):console.log.bind(console," \x 1B[32m",format $ 1("DEBUG"))),qa<=LEVELS.trace&&(log $ 1.trace=console.debug?console.debug.bind(console,format $ 1("TRACE"),"color: lightgreen"):console.log.bind(console," \x 1B[32m",format $ 1("TRACE")))},"setLogLevel"),format $ 1=__name(Ra=> ` % c$ { dayjs2 ( ) . format ( "ss.SSS" ) } : $ { Ra } : ` ,"format"),frontMatterRegex=/^-{3} \s *[ \n \r ](.*?)[ \n \r ]-{3} \s *[ \n \r ]+/s,directiveRegex=/%{2}{ \s *(?:( \w +) \s *:|( \w +)) \s *(?:( \w +)|((?:(?!}%{2}).| \r ? \n )*))? \s *(?:}%{2})?/gi,anyCommentRegex=/ \s *%%.* \n /gm,sy,UnknownDiagramError=(sy=class extends Error{constructor(qa){super(qa),this.name="UnknownDiagramError"}},__name(sy,"UnknownDiagramError"),sy),detectors={},detectType=__name(function(Ra,qa){Ra=Ra.replace(frontMatterRegex,"").replace(directiveRegex,"").replace(anyCommentRegex, `
2024-09-07 10:27:05 +08:00
` );for(const[Ja,{detector:ed}]of Object.entries(detectors))if(ed(Ra,qa))return Ja;throw new UnknownDiagramError( ` No diagram type detected matching given configuration for text : $ { Ra } ` )},"detectType"),registerLazyLoadedDiagrams=__name((...Ra)=>{for(const{id:qa,detector:Ja,loader:ed}of Ra)addDetector(qa,Ja,ed)},"registerLazyLoadedDiagrams"),addDetector=__name((Ra,qa,Ja)=>{detectors[Ra]&&log $ 1.warn( ` Detector with key $ { Ra } already exists . Overwriting . ` ),detectors[Ra]={detector:qa,loader:Ja},log $ 1.debug( ` Detector with key $ { Ra } added$ { Ja ? " with loader" : "" } ` )},"addDetector"),getDiagramLoader=__name(Ra=>detectors[Ra].loader,"getDiagramLoader"),assignWithDepth=__name((Ra,qa,{depth:Ja=2,clobber:ed=!1}={})=>{const td={depth:Ja,clobber:ed};return Array.isArray(qa)&&!Array.isArray(Ra)?(qa.forEach(rd=>assignWithDepth(Ra,rd,td)),Ra):Array.isArray(qa)&&Array.isArray(Ra)?(qa.forEach(rd=>{Ra.includes(rd)||Ra.push(rd)}),Ra):Ra===void 0||Ja<=0?Ra!=null&&typeof Ra=="object"&&typeof qa=="object"?Object.assign(Ra,qa):qa:(qa!==void 0&&typeof Ra=="object"&&typeof qa=="object"&&Object.keys(qa).forEach(rd=>{typeof qa[rd]=="object"&&(Ra[rd]===void 0||typeof Ra[rd]=="object")?(Ra[rd]===void 0&&(Ra[rd]=Array.isArray(qa[rd])?[]:{}),Ra[rd]=assignWithDepth(Ra[rd],qa[rd],{depth:Ja-1,clobber:ed})):(ed||typeof Ra[rd]!="object"&&typeof qa[rd]!="object")&&(Ra[rd]=qa[rd])}),Ra)},"assignWithDepth"),assignWithDepth_default=assignWithDepth,oldAttributeBackgroundColorOdd="#ffffff",oldAttributeBackgroundColorEven="#f2f2f2",mkBorder=__name((Ra,qa)=>qa?adjust(Ra,{s:-40,l:10}):adjust(Ra,{s:-40,l:-10}),"mkBorder"),oy,Theme=(oy=class{constructor(){this.background="#f4f4f4",this.primaryColor="#fff4dd",this.noteBkgColor="#fff5ad",this.noteTextColor="#333",this.THEME_COLOR_LIMIT=12,this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px"}updateColors(){var Ja,ed,td,rd,sd,od,ld,cd,ud,_d,yd;if(this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#333"),this.secondaryColor=this.secondaryColor||adjust(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||adjust(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||mkBorder(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||mkBorder(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||mkBorder(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||mkBorder(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#fff5ad",this.noteTextColor=this.noteTextColor||"#333",this.secondaryTextColor=this.secondaryTextColor||invert(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||invert(this.tertiaryColor),this.lineColor=this.lineColor||invert(this.background),this.arrowheadColor=this.arrowheadColor||invert(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.primaryBorderColor,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?darken(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextCo
2024-08-30 15:19:18 +08:00
font - family : $ { Ja . fontFamily } ;
font - size : $ { Ja . fontSize } ;
fill : $ { Ja . textColor }
2024-08-27 22:31:52 +08:00
}
/* Classes common for multiple diagrams */
& . error - icon {
2024-08-30 15:19:18 +08:00
fill : $ { Ja . errorBkgColor } ;
2024-08-27 22:31:52 +08:00
}
& . error - text {
2024-08-30 15:19:18 +08:00
fill : $ { Ja . errorTextColor } ;
stroke : $ { Ja . errorTextColor } ;
2024-08-27 22:31:52 +08:00
}
& . edge - thickness - normal {
stroke - width : 1 px ;
}
& . edge - thickness - thick {
stroke - width : 3.5 px
}
& . edge - pattern - solid {
stroke - dasharray : 0 ;
}
& . edge - thickness - invisible {
stroke - width : 0 ;
fill : none ;
}
& . edge - pattern - dashed {
stroke - dasharray : 3 ;
}
. edge - pattern - dotted {
stroke - dasharray : 2 ;
}
& . marker {
2024-08-30 15:19:18 +08:00
fill : $ { Ja . lineColor } ;
stroke : $ { Ja . lineColor } ;
2024-08-27 22:31:52 +08:00
}
& . marker . cross {
2024-08-30 15:19:18 +08:00
stroke : $ { Ja . lineColor } ;
2024-08-27 22:31:52 +08:00
}
& svg {
2024-08-30 15:19:18 +08:00
font - family : $ { Ja . fontFamily } ;
font - size : $ { Ja . fontSize } ;
2024-08-27 22:31:52 +08:00
}
& p {
margin : 0
}
2024-08-30 15:19:18 +08:00
$ { ed }
2024-08-27 22:31:52 +08:00
2024-08-30 15:19:18 +08:00
$ { qa }
2024-09-04 13:02:35 +08:00
` },"getStyles"),addStylesForDiagram=__name((Ra,qa)=>{qa!==void 0&&(themes[Ra]=qa)},"addStylesForDiagram"),styles_default=getStyles $ 1,commonDb_exports={};__export(commonDb_exports,{clear:()=>clear $ 1,getAccDescription:()=>getAccDescription,getAccTitle:()=>getAccTitle,getDiagramTitle:()=>getDiagramTitle,setAccDescription:()=>setAccDescription,setAccTitle:()=>setAccTitle,setDiagramTitle:()=>setDiagramTitle});var accTitle="",diagramTitle="",accDescription="",sanitizeText2=__name(Ra=>sanitizeText(Ra,getConfig $ 1()),"sanitizeText"),clear $ 1=__name(()=>{accTitle="",accDescription="",diagramTitle=""},"clear"),setAccTitle=__name(Ra=>{accTitle=sanitizeText2(Ra).replace(/^ \s +/g,"")},"setAccTitle"),getAccTitle=__name(()=>accTitle,"getAccTitle"),setAccDescription=__name(Ra=>{accDescription=sanitizeText2(Ra).replace(/ \n \s +/g, `
2024-09-08 17:22:36 +08:00
` )},"setAccDescription"),getAccDescription=__name(()=>accDescription,"getAccDescription"),setDiagramTitle=__name(Ra=>{diagramTitle=sanitizeText2(Ra)},"setDiagramTitle"),getDiagramTitle=__name(()=>diagramTitle,"getDiagramTitle"),log2=log $ 1,setLogLevel2=setLogLevel,getConfig2=getConfig $ 1,setConfig2=setConfig,defaultConfig2=defaultConfig,sanitizeText3=__name(Ra=>sanitizeText(Ra,getConfig2()),"sanitizeText"),setupGraphViewbox2=setupGraphViewbox,getCommonDb=__name(()=>commonDb_exports,"getCommonDb"),diagrams={},registerDiagram=__name((Ra,qa,Ja)=>{var ed;diagrams[Ra]&&log2.warn( ` Diagram with id $ { Ra } already registered . Overwriting . ` ),diagrams[Ra]=qa,Ja&&addDetector(Ra,Ja),addStylesForDiagram(Ra,qa.styles),(ed=qa.injectUtils)==null||ed.call(qa,log2,setLogLevel2,getConfig2,sanitizeText3,setupGraphViewbox2,getCommonDb(),()=>{})},"registerDiagram"),getDiagram=__name(Ra=>{if(Ra in diagrams)return diagrams[Ra];throw new DiagramNotFoundError(Ra)},"getDiagram"),Dy,DiagramNotFoundError=(Dy=class extends Error{constructor(qa){super( ` Diagram $ { qa } not found . ` )}},__name(Dy,"DiagramNotFoundError"),Dy);const defaultIconDimensions=Object.freeze({left:0,top:0,width:16,height:16}),defaultIconTransformations=Object.freeze({rotate:0,vFlip:!1,hFlip:!1}),defaultIconProps=Object.freeze({...defaultIconDimensions,...defaultIconTransformations}),defaultExtendedIconProps=Object.freeze({...defaultIconProps,body:"",hidden:!1}),defaultIconSizeCustomisations=Object.freeze({width:null,height:null}),defaultIconCustomisations=Object.freeze({...defaultIconSizeCustomisations,...defaultIconTransformations}),matchIconName=/^[a-z0-9]+(-[a-z0-9]+)* $ /,stringToIcon=(Ra,qa,Ja,ed="")=>{const td=Ra.split(":");if(Ra.slice(0,1)==="@"){if(td.length<2||td.length>3)return null;ed=td.shift().slice(1)}if(td.length>3||!td.length)return null;if(td.length>1){const od=td.pop(),ld=td.pop(),cd={provider:td.length>0?td[0]:ed,prefix:ld,name:od};return validateIconName(cd)?cd:null}const rd=td[0],sd=rd.split("-");if(sd.length>1){const od={provider:ed,prefix:sd.shift(),name:sd.join("-")};return validateIconName(od)?od:null}if(Ja&&ed===""){const od={provider:ed,prefix:"",name:rd};return validateIconName(od,Ja)?od:null}return null},validateIconName=(Ra,qa)=>Ra?!!((Ra.provider===""||Ra.provider.match(matchIconName))&&(qa&&Ra.prefix===""||Ra.prefix.match(matchIconName))&&Ra.name.match(matchIconName)):!1;function mergeIconTransformations(Ra,qa){const Ja={};!Ra.hFlip!=!qa.hFlip&&(Ja.hFlip=!0),!Ra.vFlip!=!qa.vFlip&&(Ja.vFlip=!0);const ed=((Ra.rotate||0)+(qa.rotate||0))%4;return ed&&(Ja.rotate=ed),Ja}function mergeIconData(Ra,qa){const Ja=mergeIconTransformations(Ra,qa);for(const ed in defaultExtendedIconProps)ed in defaultIconTransformations?ed in Ra&&!(ed in Ja)&&(Ja[ed]=defaultIconTransformations[ed]):ed in qa?Ja[ed]=qa[ed]:ed in Ra&&(Ja[ed]=Ra[ed]);return Ja}function getIconsTree(Ra,qa){const Ja=Ra.icons,ed=Ra.aliases||Object.create(null),td=Object.create(null);function rd(sd){if(Ja[sd])return td[sd]=[];if(!(sd in td)){td[sd]=null;const od=ed[sd]&&ed[sd].parent,ld=od&&rd(od);ld&&(td[sd]=[od].concat(ld))}return td[sd]}return(qa||Object.keys(Ja).concat(Object.keys(ed))).forEach(rd),td}function internalGetIconData(Ra,qa,Ja){const ed=Ra.icons,td=Ra.aliases||Object.create(null);let rd={};function sd(od){rd=mergeIconData(ed[od]||td[od],rd)}return sd(qa),Ja.forEach(sd),mergeIconData(Ra,rd)}function getIconData(Ra,qa){if(Ra.icons[qa])return internalGetIconData(Ra,qa,[]);const Ja=getIconsTree(Ra,[qa])[qa];return Ja?internalGetIconData(Ra,qa,Ja):null}const unitsSplit=/(-?[0-9.]*[0-9]+[0-9.]*)/g,unitsTest=/^-?[0-9.]*[0-9]+[0-9.]* $ /g;function calculateSize(Ra,qa,Ja){if(qa===1)return Ra;if(Ja=Ja||100,typeof Ra=="number")return Math.ceil(Ra*qa*Ja)/Ja;if(typeof Ra!="string")return Ra;const ed=Ra.split(unitsSplit);if(ed===null||!ed.length)return Ra;const td=[];let rd=ed.shift(),sd=unitsTest.test(rd);for(;;){if(sd){const od=parseFloat(rd);isNaN(od)?td.push(rd):td.push(Math.ceil(od*qa*Ja)/Ja)}else td.push(rd);if(rd=ed.shift(),rd===void 0)return td.join("");sd=!sd}}function splitSVGDefs(Ra,qa="defs"){let Ja=
` ,"ig");Ra=Ra.trim().replace(td,"").replace(/'/gm,'"'),log $ 1.debug( ` Detecting diagram directive$ { qa !== null ? " type:" + qa : "" } based on the text : $ { Ra } ` );let rd;const sd=[];for(;(rd=directiveRegex.exec(Ra))!==null;)if(rd.index===directiveRegex.lastIndex&&directiveRegex.lastIndex++,rd&&!qa||qa&&((Ja=rd[1])!=null&&Ja.match(qa))||qa&&((ed=rd[2])!=null&&ed.match(qa))){const od=rd[1]?rd[1]:rd[2],ld=rd[3]?rd[3].trim():rd[4]?JSON.parse(rd[4].trim()):null;sd.push({type:od,args:ld})}return sd.length===0?{type:Ra,args:null}:sd.length===1?sd[0]:sd}catch(td){return log $ 1.error( ` ERROR : $ { td . message } - Unable to parse directive type : '${qa}' based on the text : '${Ra}' ` ),{type:void 0,args:null}}},"detectDirective"),removeDirectives=__name(function(Ra){return Ra.replace(directiveRegex,"")},"removeDirectives"),isSubstringInArray=__name(function(Ra,qa){for(const[Ja,ed]of qa.entries())if(ed.match(Ra))return Ja;return-1},"isSubstringInArray");function interpolateToCurve(Ra,qa){if(!Ra)return qa;const Ja= ` curve$ { Ra . charAt ( 0 ) . toUpperCase ( ) + Ra . slice ( 1 ) } ` ;return d3CurveTypes[Ja]??qa}__name(interpolateToCurve,"interpolateToCurve");function formatUrl(Ra,qa){const Ja=Ra.trim();if(Ja)return qa.securityLevel!=="loose"?sanitizeUrl_1(Ja):Ja}__name(formatUrl,"formatUrl");var runFunc=__name((Ra,...qa)=>{const Ja=Ra.split("."),ed=Ja.length-1,td=Ja[ed];let rd=window;for(let sd=0;sd<ed;sd++)if(rd=rd[Ja[sd]],!rd){log $ 1.error( ` Function name : $ { Ra } not found in window ` );return}rd[td](...qa)},"runFunc");function distance(Ra,qa){return!Ra||!qa?0:Math.sqrt(Math.pow(qa.x-Ra.x,2)+Math.pow(qa.y-Ra.y,2))}__name(distance,"distance");function traverseEdge(Ra){let qa,Ja=0;Ra.forEach(td=>{Ja+=distance(td,qa),qa=td});const ed=Ja/2;return calculatePoint(Ra,ed)}__name(traverseEdge,"traverseEdge");function calcLabelPosition(Ra){return Ra.length===1?Ra[0]:traverseEdge(Ra)}__name(calcLabelPosition,"calcLabelPosition");var roundNumber=__name((Ra,qa=2)=>{const Ja=Math.pow(10,qa);return Math.round(Ra*Ja)/Ja},"roundNumber"),calculatePoint=__name((Ra,qa)=>{let Ja,ed=qa;for(const td of Ra){if(Ja){const rd=distance(td,Ja);if(rd<ed)ed-=rd;else{const sd=ed/rd;if(sd<=0)return Ja;if(sd>=1)return{x:td.x,y:td.y};if(sd>0&&sd<1)return{x:roundNumber((1-sd)*Ja.x+sd*td.x,5),y:roundNumber((1-sd)*Ja.y+sd*td.y,5)}}}Ja=td}throw new Error("Could not find a suitable point for the given distance")},"calculatePoint"),calcCardinalityPosition=__name((Ra,qa,Ja)=>{log $ 1.info( ` our points $ { JSON . stringify ( qa ) } ` ),qa[0]!==Ja&&(qa=qa.reverse());const td=calculatePoint(qa,25),rd=Ra?10:5,sd=Math.atan2(qa[0].y-td.y,qa[0].x-td.x),od={x:0,y:0};return od.x=Math.sin(sd)*rd+(qa[0].x+td.x)/2,od.y=-Math.cos(sd)*rd+(qa[0].y+td.y)/2,od},"calcCardinalityPosition");function calcTerminalLabelPosition(Ra,qa,Ja){const ed=structuredClone(Ja);log $ 1.info("our points",ed),qa!=="start_left"&&qa!=="start_right"&&ed.reverse();const td=25+Ra,rd=calculatePoint(ed,td),sd=10+Ra*.5,od=Math.atan2(ed[0].y-rd.y,ed[0].x-rd.x),ld={x:0,y:0};return qa==="start_left"?(ld.x=Math.sin(od+Math.PI)*sd+(ed[0].x+rd.x)/2,ld.y=-Math.cos(od+Math.PI)*sd+(ed[0].y+rd.y)/2):qa==="end_right"?(ld.x=Math.sin(od-Math.PI)*sd+(ed[0].x+rd.x)/2-5,ld.y=-Math.cos(od-Math.PI)*sd+(ed[0].y+rd.y)/2-5):qa==="end_left"?(ld.x=Math.sin(od)*sd+(ed[0].x+rd.x)/2-5,ld.y=-Math.cos(od)*sd+(ed[0].y+rd.y)/2-5):(ld.x=Math.sin(od)*sd+(ed[0].x+rd.x)/2,ld.y=-Math.cos(od)*sd+(ed[0].y+rd.y)/2),ld}__name(calcTerminalLabelPosition,"calcTerminalLabelPosition");function getStylesFromArray(Ra){let qa="",Ja="";for(const ed of Ra)ed!==void 0&&(ed.startsWith("color:")||ed.startsWith("text-align:")?Ja=Ja+ed+";":qa=qa+ed+";");return{style:qa,labelStyle:Ja}}__name(getStylesFromArray,"getStylesFromArray");var cnt=0,generateId=__name(()=>(cnt++,"id-"+Math.random().toString(36).substr(2,12)+"-"+cnt),"generateId");function makeRandomHex(Ra){let qa="";const Ja="0123456789abcdef",ed=Ja.length;for(let td=0;td<Ra;td++)qa+=Ja.charAt(Math.floor(Math.random()*ed));return qa}__name(makeRandomHex,"makeRandomHex");var random=__name(Ra=>makeRandomHex(Ra.length),"random"),getTextObj=__name(function(){return{x:0,y:0,fill:vo
2024-09-03 08:22:14 +08:00
` ).map(td=>{const rd=td.match(/^ \s +/);if(rd===null)return td;const[sd]=rd;return sd.length>=ed.length?td.slice(ed.length):td}).join( `
2024-09-07 10:27:05 +08:00
` )}class _Tokenizer{constructor(qa){n_(this,"options");n_(this,"rules");n_(this,"lexer");this.options=qa||_defaults}space(qa){const Ja=this.rules.block.newline.exec(qa);if(Ja&&Ja[0].length>0)return{type:"space",raw:Ja[0]}}code(qa){const Ja=this.rules.block.code.exec(qa);if(Ja){const ed=Ja[0].replace(/^ {1,4}/gm,"");return{type:"code",raw:Ja[0],codeBlockStyle:"indented",text:this.options.pedantic?ed:rtrim(ed, `
2024-08-30 15:19:18 +08:00
` )}}}fences(qa){const Ja=this.rules.block.fences.exec(qa);if(Ja){const ed=Ja[0],td=indentCodeCompensation(ed,Ja[3]||"");return{type:"code",raw:ed,lang:Ja[2]?Ja[2].trim().replace(this.rules.inline.anyPunctuation," $ 1"):Ja[2],text:td}}}heading(qa){const Ja=this.rules.block.heading.exec(qa);if(Ja){let ed=Ja[2].trim();if(/# $ /.test(ed)){const td=rtrim(ed,"#");(this.options.pedantic||!td||/ $ /.test(td))&&(ed=td.trim())}return{type:"heading",raw:Ja[0],depth:Ja[1].length,text:ed,tokens:this.lexer.inline(ed)}}}hr(qa){const Ja=this.rules.block.hr.exec(qa);if(Ja)return{type:"hr",raw:rtrim(Ja[0], `
` )}}blockquote(qa){const Ja=this.rules.block.blockquote.exec(qa);if(Ja){let ed=rtrim(Ja[0], `
2024-08-27 22:31:52 +08:00
` ).split( `
2024-09-03 08:22:14 +08:00
` ),td="",rd="";const sd=[];for(;ed.length>0;){let od=!1;const ld=[];let cd;for(cd=0;cd<ed.length;cd++)if(/^ {0,3}>/.test(ed[cd]))ld.push(ed[cd]),od=!0;else if(!od)ld.push(ed[cd]);else break;ed=ed.slice(cd);const ud=ld.join( `
2024-08-31 11:28:56 +08:00
` ),_d=ud.replace(/ \n {0,3}((?:=+|-+) *)(?= \n | $ )/g, `
2024-08-30 15:19:18 +08:00
$1 ` ).replace(/^ {0,3}>[ \t ]?/gm,"");td=td? ` $ { td }
$ { ud } ` :ud,rd=rd? ` $ { rd }
2024-09-03 08:22:14 +08:00
$ { _d } ` :_d;const yd=this.lexer.state.top;if(this.lexer.state.top=!0,this.lexer.blockTokens(_d,sd,!0),this.lexer.state.top=yd,ed.length===0)break;const gd=sd[sd.length-1];if((gd==null?void 0:gd.type)==="code")break;if((gd==null?void 0:gd.type)==="blockquote"){const Ed=gd,Td=Ed.raw+ `
2024-08-30 15:19:18 +08:00
` +ed.join( `
2024-09-08 17:22:36 +08:00
` ),Od=this.blockquote(Td);sd[sd.length-1]=Od,td=td.substring(0,td.length-Ed.raw.length)+Od.raw,rd=rd.substring(0,rd.length-Ed.text.length)+Od.text;break}else if((gd==null?void 0:gd.type)==="list"){const Ed=gd,Td=Ed.raw+ `
2024-08-30 15:19:18 +08:00
` +ed.join( `
2024-09-08 17:22:36 +08:00
` ),Od=this.list(Td);sd[sd.length-1]=Od,td=td.substring(0,td.length-gd.raw.length)+Od.raw,rd=rd.substring(0,rd.length-Ed.raw.length)+Od.raw,ed=Td.substring(sd[sd.length-1].raw.length).split( `
2024-09-03 08:22:14 +08:00
` );continue}}return{type:"blockquote",raw:td,tokens:sd,text:rd}}}list(qa){let Ja=this.rules.block.list.exec(qa);if(Ja){let ed=Ja[1].trim();const td=ed.length>1,rd={type:"list",raw:"",ordered:td,start:td?+ed.slice(0,-1):"",loose:!1,items:[]};ed=td? ` \ \ d { 1 , 9 } \ \ $ { ed . slice ( - 1 ) } ` : ` \ \ $ { ed } ` ,this.options.pedantic&&(ed=td?ed:"[*+-]");const sd=new RegExp( ` ^ ( { 0 , 3 } $ { ed } ) ( ( ? : [ ] [ ^ \ \ n ] * ) ? ( ? : \ \ n | $ ) ) ` );let od=!1;for(;qa;){let ld=!1,cd="",ud="";if(!(Ja=sd.exec(qa))||this.rules.block.hr.test(qa))break;cd=Ja[0],qa=qa.substring(cd.length);let _d=Ja[2].split( `
` ,1)[0].replace(/^ \t +/,Rd=>" ".repeat(3*Rd.length)),yd=qa.split( `
2024-08-31 11:28:56 +08:00
` ,1)[0],gd=!_d.trim(),Ed=0;if(this.options.pedantic?(Ed=2,ud=_d.trimStart()):gd?Ed=Ja[1].length+1:(Ed=Ja[2].search(/[^ ]/),Ed=Ed>4?1:Ed,ud=_d.slice(Ed),Ed+=Ja[1].length),gd&&/^ * $ /.test(yd)&&(cd+=yd+ `
2024-09-03 08:22:14 +08:00
` ,qa=qa.substring(yd.length+1),ld=!0),!ld){const Rd=new RegExp( ` ^ { 0 , $ { Math . min ( 3 , Ed - 1 ) } } ( ? : [ * + - ] | \ \ d { 1 , 9 } [ . ) ] ) ( ( ? : [ ] [ ^ \ \ n ] * ) ? ( ? : \ \ n | $ ) ) ` ),Nd=new RegExp( ` ^ { 0 , $ { Math . min ( 3 , Ed - 1 ) } } ( ( ? : - * ) { 3 , } | ( ? : _ * ) { 3 , } | ( ? : \ \ * * ) { 3 , } ) ( ? : \ \ n + | $ ) ` ),Id=new RegExp( ` ^ { 0 , $ { Math . min ( 3 , Ed - 1 ) } } ( ? : \ ` \` \` |~~~) ` ) , Md = new RegExp ( ` ^ {0, ${ Math . min ( 3 , Ed - 1 ) } }# ` ) ; for ( ; qa ; ) { const Ld = qa . split ( `
` ,1)[0];if(yd=Ld,this.options.pedantic&&(yd=yd.replace(/^ {1,4}(?=( {4})*[^ ])/g," ")),Id.test(yd)||Md.test(yd)||Rd.test(yd)||Nd.test(qa))break;if(yd.search(/[^ ]/)>=Ed||!yd.trim())ud+= `
` +yd.slice(Ed);else{if(gd||_d.search(/[^ ]/)>=4||Id.test(_d)||Md.test(_d)||Nd.test(_d))break;ud+= `
` +yd}!gd&&!yd.trim()&&(gd=!0),cd+=Ld+ `
2024-09-08 17:22:36 +08:00
` ,qa=qa.substring(Ld.length+1),_d=yd.slice(Ed)}}rd.loose||(od?rd.loose=!0:/ \n * \n * $ /.test(cd)&&(od=!0));let Td=null,Od;this.options.gfm&&(Td=/^ \[ [ xX] \] /.exec(ud),Td&&(Od=Td[0]!=="[ ] ",ud=ud.replace(/^ \[ [ xX] \] +/,""))),rd.items.push({type:"list_item",raw:cd,task:!!Td,checked:Od,loose:!1,text:ud,tokens:[]}),rd.raw+=cd}rd.items[rd.items.length-1].raw=rd.items[rd.items.length-1].raw.trimEnd(),rd.items[rd.items.length-1].text=rd.items[rd.items.length-1].text.trimEnd(),rd.raw=rd.raw.trimEnd();for(let ld=0;ld<rd.items.length;ld++)if(this.lexer.state.top=!1,rd.items[ld].tokens=this.lexer.blockTokens(rd.items[ld].text,[]),!rd.loose){const cd=rd.items[ld].tokens.filter(_d=>_d.type==="space"),ud=cd.length>0&&cd.some(_d=>/ \n .* \n /.test(_d.raw));rd.loose=ud}if(rd.loose)for(let ld=0;ld<rd.items.length;ld++)rd.items[ld].loose=!0;return rd}}html(qa){const Ja=this.rules.block.html.exec(qa);if(Ja)return{type:"html",block:!0,raw:Ja[0],pre:Ja[1]==="pre"||Ja[1]==="script"||Ja[1]==="style",text:Ja[0]}}def(qa){const Ja=this.rules.block.def.exec(qa);if(Ja){const ed=Ja[1].toLowerCase().replace(/ \s +/g," "),td=Ja[2]?Ja[2].replace(/^<(.*)> $ /," $ 1").replace(this.rules.inline.anyPunctuation," $ 1"):"",rd=Ja[3]?Ja[3].substring(1,Ja[3].length-1).replace(this.rules.inline.anyPunctuation," $ 1"):Ja[3];return{type:"def",tag:ed,raw:Ja[0],href:td,title:rd}}}table(qa){const Ja=this.rules.block.table.exec(qa);if(!Ja||!/[:|]/.test(Ja[2]))return;const ed=splitCells(Ja[1]),td=Ja[2].replace(/^ \| | \| * $ /g,"").split("|"),rd=Ja[3]&&Ja[3].trim()?Ja[3].replace(/ \n [ \t ]* $ /,"").split( `
2024-09-03 08:22:14 +08:00
` ):[],sd={type:"table",raw:Ja[0],header:[],align:[],rows:[]};if(ed.length===td.length){for(const od of td)/^ *-+: * $ /.test(od)?sd.align.push("right"):/^ *:-+: * $ /.test(od)?sd.align.push("center"):/^ *:-+ * $ /.test(od)?sd.align.push("left"):sd.align.push(null);for(let od=0;od<ed.length;od++)sd.header.push({text:ed[od],tokens:this.lexer.inline(ed[od]),header:!0,align:sd.align[od]});for(const od of rd)sd.rows.push(splitCells(od,sd.header.length).map((ld,cd)=>({text:ld,tokens:this.lexer.inline(ld),header:!1,align:sd.align[cd]})));return sd}}lheading(qa){const Ja=this.rules.block.lheading.exec(qa);if(Ja)return{type:"heading",raw:Ja[0],depth:Ja[2].charAt(0)==="="?1:2,text:Ja[1],tokens:this.lexer.inline(Ja[1])}}paragraph(qa){const Ja=this.rules.block.paragraph.exec(qa);if(Ja){const ed=Ja[1].charAt(Ja[1].length-1)=== `
` ?Ja[1].slice(0,-1):Ja[1];return{type:"paragraph",raw:Ja[0],text:ed,tokens:this.lexer.inline(ed)}}}text(qa){const Ja=this.rules.block.text.exec(qa);if(Ja)return{type:"text",raw:Ja[0],text:Ja[0],tokens:this.lexer.inline(Ja[0])}}escape(qa){const Ja=this.rules.inline.escape.exec(qa);if(Ja)return{type:"escape",raw:Ja[0],text:escape $ 1 $ 1(Ja[1])}}tag(qa){const Ja=this.rules.inline.tag.exec(qa);if(Ja)return!this.lexer.state.inLink&&/^<a /i.test(Ja[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&/^< \/ a>/i.test(Ja[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&/^<(pre|code|kbd|script)( \s |>)/i.test(Ja[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&/^< \/ (pre|code|kbd|script)( \s |>)/i.test(Ja[0])&&(this.lexer.state.inRawBlock=!1),{type:"html",raw:Ja[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,block:!1,text:Ja[0]}}link(qa){const Ja=this.rules.inline.link.exec(qa);if(Ja){const ed=Ja[2].trim();if(!this.options.pedantic&&/^</.test(ed)){if(!/> $ /.test(ed))return;const sd=rtrim(ed.slice(0,-1)," \\ ");if((ed.length-sd.length)%2===0)return}else{const sd=findClosingBracket(Ja[2],"()");if(sd>-1){const ld=(Ja[0].indexOf("!")===0?5:4)+Ja[1].length+sd;Ja[2]=Ja[2].substring(0,sd),Ja[0]=Ja[0].substring(0,ld).trim(),Ja[3]=""}}let td=Ja[2],rd="";if(this.options.pedantic){const sd=/^([^'"]*[^ \s ]) \s +(['"])(.*) \2 /.exec(td);sd&&(td=sd[1],rd=sd[3])}else rd=Ja[3]?Ja[3].slice(1,-1):"";return td=td.trim(),/^</.test(td)&&(this.options.pedantic&&!/> $ /.test(ed)?td=td.slice(1):td=td.slice(1,-1)),outputLink(Ja,{href:td&&td.replace(this.rules.inline.anyPunctuation," $ 1"),title:rd&&rd.replace(this.rules.inline.anyPunctuation," $ 1")},Ja[0],this.lexer)}}reflink(qa,Ja){let ed;if((ed=this.rules.inline.reflink.exec(qa))||(ed=this.rules.inline.nolink.exec(qa))){const td=(ed[2]||ed[1]).replace(/ \s +/g," "),rd=Ja[td.toLowerCase()];if(!rd){const sd=ed[0].charAt(0);return{type:"text",raw:sd,text:sd}}return outputLink(ed,rd,ed[0],this.lexer)}}emStrong(qa,Ja,ed=""){let td=this.rules.inline.emStrongLDelim.exec(qa);if(!td||td[3]&&ed.match(/[ \p {L} \p {N}]/u))return;if(!(td[1]||td[2]||"")||!ed||this.rules.inline.punctuation.exec(ed)){const sd=[...td[0]].length-1;let od,ld,cd=sd,ud=0;const _d=td[0][0]==="*"?this.rules.inline.emStrongRDelimAst:this.rules.inline.emStrongRDelimUnd;for(_d.lastIndex=0,Ja=Ja.slice(-1*qa.length+sd);(td=_d.exec(Ja))!=null;){if(od=td[1]||td[2]||td[3]||td[4]||td[5]||td[6],!od)continue;if(ld=[...od].length,td[3]||td[4]){cd+=ld;continue}else if((td[5]||td[6])&&sd%3&&!((sd+ld)%3)){ud+=ld;continue}if(cd-=ld,cd>0)continue;ld=Math.min(ld,ld+cd+ud);const yd=[...td[0]][0].length,gd=qa.slice(0,sd+td.index+yd+ld);if(Math.min(sd,ld)%2){const Td=gd.slice(1,-1);return{type:"em",raw:gd,text:Td,tokens:this.lexer.inlineTokens(Td)}}const Ed=gd.slice(2,-2);return{type:"strong",raw:gd,text:Ed,tokens:this.lexer.inlineTokens(Ed)}}}}codespan(qa){const Ja=this.rules.inline.code.exec(qa);if(Ja){let ed=Ja[2].replace(/ \n /g," ");const td=/[^ ]/.test(ed),rd=/^ /.test(ed)&&/ $ /.test(ed);return td&&rd&&(ed=ed.substring(1,ed.length-1)),ed=escape $ 1 $ 1(ed,!0),{type:"codespan",raw:Ja[0],text:ed}}}br(qa){const Ja=this.rules.inline.br.exec(qa);if(Ja)return{type:"br",raw:Ja[0]}}del(qa){const Ja=this.rules.inline.del.exec(qa);if(Ja)return{type:"del",raw:Ja[0],text:Ja[2],tokens:this.lexer.inlineTokens(Ja[2])}}autolink(qa){const Ja=this.rules.inline.autolink.exec(qa);if(Ja){let ed,td;return Ja[2]==="@"?(ed=escape $ 1 $ 1(Ja[1]),td="mailto:"+ed):(ed=escape $ 1 $ 1(Ja[1]),td=ed),{type:"link",raw:Ja[0],text:ed,href:td,tokens:[{type:"text",raw:ed,text:ed}]}}}url(qa){var ed;let Ja;if(Ja=this.rules.inline.url.exec(qa)){let td,rd;if(Ja[2]==="@")td=escape $ 1 $ 1(Ja[0]),rd="mailto:"+td;else{let sd;do sd=Ja[0],Ja[0]=((ed=this.rules.inline._backpedal.exec(Ja[0]))==null?void 0:ed[0])??"";while(sd!==Ja[0]);td=escape $ 1 $ 1(Ja[0]),Ja[1]==="www."?rd="http://"+Ja[0]:rd=Ja[0]}return{type:"link",raw:Ja[0],text:td,href:rd,tokens:[{type:"text",raw:td,text:td}]}}}inlineText(qa){const Ja=this.rules.inline.text.exec(qa);if(Ja){let ed;return this.lexer.state.inRawBlock?ed=J
2024-09-07 10:27:05 +08:00
] ` ).replace("lheading",lheading).replace("|table","").replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").replace("|tag","").getRegex()},escape $ 2=/^ \\ ([!"# $ %&'()*+, \- ./:;<=>?@ \[ \] \\ ^_ ` { | } ~ ] ) / , inlineCode = /^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/ , br$3 = /^( {2,}|\\)\n(?!\s*$)/ , inlineText = /^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/ , _punctuation = "\\p{P}\\p{S}" , punctuation = edit ( /^((?![*_])[\spunctuation])/ , "u" ) . replace ( /punctuation/g , _punctuation ) . getRegex ( ) , blockSkip = /\[[^[\]]*?\]\([^\(\)]*?\)|`[^`]*?`|<[^<>]*?>/g , emStrongLDelim = edit ( /^(?:\*+(?:((?!\*)[punct])|[^\s*]))|^_+(?:((?!_)[punct])|([^\s_]))/ , "u" ) . replace ( /punct/g , _punctuation ) . getRegex ( ) , emStrongRDelimAst = edit ( "^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)[punct](\\*+)(?=[\\s]|$)|[^punct\\s](\\*+)(?!\\*)(?=[punct\\s]|$)|(?!\\*)[punct\\s](\\*+)(?=[^punct\\s])|[\\s](\\*+)(?!\\*)(?=[punct])|(?!\\*)[punct](\\*+)(?!\\*)(?=[punct])|[^punct\\s](\\*+)(?=[^punct\\s])" , "gu" ) . replace ( /punct/g , _punctuation ) . getRegex ( ) , emStrongRDelimUnd = edit ( "^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)[punct](_+)(?=[\\s]|$)|[^punct\\s](_+)(?!_)(?=[punct\\s]|$)|(?!_)[punct\\s](_+)(?=[^punct\\s])|[\\s](_+)(?!_)(?=[punct])|(?!_)[punct](_+)(?!_)(?=[punct])" , "gu" ) . replace ( /punct/g , _punctuation ) . getRegex ( ) , anyPunctuation = edit ( /\\([punct])/ , "gu" ) . replace ( /punct/g , _punctuation ) . getRegex ( ) , autolink = edit ( /^<(scheme:[^\s\x00-\x1f<>]*|email)>/ ) . replace ( "scheme" , /[a-zA-Z][a-zA-Z0-9+.-]{1,31}/ ) . replace ( "email" , /[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/ ) . getRegex ( ) , _inlineComment = edit ( _comment ) . replace ( "(?:-->|$)" , "-->" ) . getRegex ( ) , tag = edit ( "^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>" ) . replace ( "comment" , _inlineComment ) . replace ( "attribute" , /\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/ ) . getRegex ( ) , _inlineLabel = /(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/ , link = edit ( /^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/ ) . replace ( "label" , _inlineLabel ) . replace ( "href" , /<(?:\\.|[^\n<>\\])+>|[^\s\x00-\x1f]*/ ) . replace ( "title" , /"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/ ) . getRegex ( ) , reflink = edit ( /^!?\[(label)\]\[(ref)\]/ ) . replace ( "label" , _inlineLabel ) . replace ( "ref" , _blockLabel ) . getRegex ( ) , nolink = edit ( /^!?\[(ref)\](?:\[\])?/ ) . replace ( "ref" , _blockLabel ) . getRegex ( ) , reflinkSearch = edit ( "reflink|nolink(?!\\()" , "g" ) . replace ( "reflink" , reflink ) . replace ( "nolink" , nolink ) . getRegex ( ) , inlineNormal = { _backpedal : noopTest , anyPunctuation , autolink , blockSkip , br : br$3 , code : inlineCode , del : noopTest , emStrongLDelim , emStrongRDelimAst , emStrongRDelimUnd , escape : escape$2 , link , nolink , punctuation , reflink , reflinkSearch , tag , text : inlineText , url : noopTest } , inlinePedantic = { ... inlineNormal , link : edit ( /^!?\[(label)\]\((.*?)\)/ ) . replace ( "label" , _inlineLabel ) . getRegex ( ) , reflink : edit ( /^!?\[(label)\]\s*\[([^\]]*)\]/ ) . replace ( "label" , _inlineLabel ) . getRegex ( ) } , inlineGfm = { ... inlineNormal , escape : edit ( escape$2 ) . replace ( "])" , "~|])" ) . getRegex ( ) , url : edit ( /^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/ , "i" ) . replace ( "email" , /[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/ ) . getRegex ( ) , _backpedal : /(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/ , del : /^(~~?)(?=[^\s~])([\s\S]*?[^\s~])\1(?=[^~]|$)/ , text : /^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|https?:\/\/|ftp:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/ } , inlineBreaks = { ... inlineGfm , br : edit ( br$3 ) . replace ( "{2,}" , "*" ) . getRegex ( ) , text : edit ( inlineGfm . text ) . replace ( "\\b_" , "\\b_| {2,}\\n" ) . replace ( /\{2,\}/g , "*" ) . getRegex ( ) } , block$2 = { normal : blockNormal , gfm : blockGfm , pedantic : blockPedantic } , inline$1 = { normal : inlineNormal , gfm : inlineGfm , breaks : inlineBreaks , pedantic : inlinePedantic } ; class _Lexer { constructor (
2024-09-03 08:22:14 +08:00
` ),this.blockTokens(qa,this.tokens);for(let Ja=0;Ja<this.inlineQueue.length;Ja++){const ed=this.inlineQueue[Ja];this.inlineTokens(ed.src,ed.tokens)}return this.inlineQueue=[],this.tokens}blockTokens(qa,Ja=[],ed=!1){this.options.pedantic?qa=qa.replace(/ \t /g," ").replace(/^ + $ /gm,""):qa=qa.replace(/^( *)( \t +)/gm,(od,ld,cd)=>ld+" ".repeat(cd.length));let td,rd,sd;for(;qa;)if(!(this.options.extensions&&this.options.extensions.block&&this.options.extensions.block.some(od=>(td=od.call({lexer:this},qa,Ja))?(qa=qa.substring(td.raw.length),Ja.push(td),!0):!1))){if(td=this.tokenizer.space(qa)){qa=qa.substring(td.raw.length),td.raw.length===1&&Ja.length>0?Ja[Ja.length-1].raw+= `
2024-08-30 15:19:18 +08:00
` :Ja.push(td);continue}if(td=this.tokenizer.code(qa)){qa=qa.substring(td.raw.length),rd=Ja[Ja.length-1],rd&&(rd.type==="paragraph"||rd.type==="text")?(rd.raw+= `
` +td.raw,rd.text+= `
` +td.text,this.inlineQueue[this.inlineQueue.length-1].src=rd.text):Ja.push(td);continue}if(td=this.tokenizer.fences(qa)){qa=qa.substring(td.raw.length),Ja.push(td);continue}if(td=this.tokenizer.heading(qa)){qa=qa.substring(td.raw.length),Ja.push(td);continue}if(td=this.tokenizer.hr(qa)){qa=qa.substring(td.raw.length),Ja.push(td);continue}if(td=this.tokenizer.blockquote(qa)){qa=qa.substring(td.raw.length),Ja.push(td);continue}if(td=this.tokenizer.list(qa)){qa=qa.substring(td.raw.length),Ja.push(td);continue}if(td=this.tokenizer.html(qa)){qa=qa.substring(td.raw.length),Ja.push(td);continue}if(td=this.tokenizer.def(qa)){qa=qa.substring(td.raw.length),rd=Ja[Ja.length-1],rd&&(rd.type==="paragraph"||rd.type==="text")?(rd.raw+= `
` +td.raw,rd.text+= `
2024-09-03 08:22:14 +08:00
` +td.raw,this.inlineQueue[this.inlineQueue.length-1].src=rd.text):this.tokens.links[td.tag]||(this.tokens.links[td.tag]={href:td.href,title:td.title});continue}if(td=this.tokenizer.table(qa)){qa=qa.substring(td.raw.length),Ja.push(td);continue}if(td=this.tokenizer.lheading(qa)){qa=qa.substring(td.raw.length),Ja.push(td);continue}if(sd=qa,this.options.extensions&&this.options.extensions.startBlock){let od=1/0;const ld=qa.slice(1);let cd;this.options.extensions.startBlock.forEach(ud=>{cd=ud.call({lexer:this},ld),typeof cd=="number"&&cd>=0&&(od=Math.min(od,cd))}),od<1/0&&od>=0&&(sd=qa.substring(0,od+1))}if(this.state.top&&(td=this.tokenizer.paragraph(sd))){rd=Ja[Ja.length-1],ed&&(rd==null?void 0:rd.type)==="paragraph"?(rd.raw+= `
2024-08-30 15:19:18 +08:00
` +td.raw,rd.text+= `
2024-09-03 08:22:14 +08:00
` +td.text,this.inlineQueue.pop(),this.inlineQueue[this.inlineQueue.length-1].src=rd.text):Ja.push(td),ed=sd.length!==qa.length,qa=qa.substring(td.raw.length);continue}if(td=this.tokenizer.text(qa)){qa=qa.substring(td.raw.length),rd=Ja[Ja.length-1],rd&&rd.type==="text"?(rd.raw+= `
2024-08-30 15:19:18 +08:00
` +td.raw,rd.text+= `
2024-09-07 10:27:05 +08:00
` +td.text,this.inlineQueue.pop(),this.inlineQueue[this.inlineQueue.length-1].src=rd.text):Ja.push(td);continue}if(qa){const od="Infinite loop on byte: "+qa.charCodeAt(0);if(this.options.silent){console.error(od);break}else throw new Error(od)}}return this.state.top=!0,Ja}inline(qa,Ja=[]){return this.inlineQueue.push({src:qa,tokens:Ja}),Ja}inlineTokens(qa,Ja=[]){let ed,td,rd,sd=qa,od,ld,cd;if(this.tokens.links){const ud=Object.keys(this.tokens.links);if(ud.length>0)for(;(od=this.tokenizer.rules.inline.reflinkSearch.exec(sd))!=null;)ud.includes(od[0].slice(od[0].lastIndexOf("[")+1,-1))&&(sd=sd.slice(0,od.index)+"["+"a".repeat(od[0].length-2)+"]"+sd.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;(od=this.tokenizer.rules.inline.blockSkip.exec(sd))!=null;)sd=sd.slice(0,od.index)+"["+"a".repeat(od[0].length-2)+"]"+sd.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);for(;(od=this.tokenizer.rules.inline.anyPunctuation.exec(sd))!=null;)sd=sd.slice(0,od.index)+"++"+sd.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);for(;qa;)if(ld||(cd=""),ld=!1,!(this.options.extensions&&this.options.extensions.inline&&this.options.extensions.inline.some(ud=>(ed=ud.call({lexer:this},qa,Ja))?(qa=qa.substring(ed.raw.length),Ja.push(ed),!0):!1))){if(ed=this.tokenizer.escape(qa)){qa=qa.substring(ed.raw.length),Ja.push(ed);continue}if(ed=this.tokenizer.tag(qa)){qa=qa.substring(ed.raw.length),td=Ja[Ja.length-1],td&&ed.type==="text"&&td.type==="text"?(td.raw+=ed.raw,td.text+=ed.text):Ja.push(ed);continue}if(ed=this.tokenizer.link(qa)){qa=qa.substring(ed.raw.length),Ja.push(ed);continue}if(ed=this.tokenizer.reflink(qa,this.tokens.links)){qa=qa.substring(ed.raw.length),td=Ja[Ja.length-1],td&&ed.type==="text"&&td.type==="text"?(td.raw+=ed.raw,td.text+=ed.text):Ja.push(ed);continue}if(ed=this.tokenizer.emStrong(qa,sd,cd)){qa=qa.substring(ed.raw.length),Ja.push(ed);continue}if(ed=this.tokenizer.codespan(qa)){qa=qa.substring(ed.raw.length),Ja.push(ed);continue}if(ed=this.tokenizer.br(qa)){qa=qa.substring(ed.raw.length),Ja.push(ed);continue}if(ed=this.tokenizer.del(qa)){qa=qa.substring(ed.raw.length),Ja.push(ed);continue}if(ed=this.tokenizer.autolink(qa)){qa=qa.substring(ed.raw.length),Ja.push(ed);continue}if(!this.state.inLink&&(ed=this.tokenizer.url(qa))){qa=qa.substring(ed.raw.length),Ja.push(ed);continue}if(rd=qa,this.options.extensions&&this.options.extensions.startInline){let ud=1/0;const _d=qa.slice(1);let yd;this.options.extensions.startInline.forEach(gd=>{yd=gd.call({lexer:this},_d),typeof yd=="number"&&yd>=0&&(ud=Math.min(ud,yd))}),ud<1/0&&ud>=0&&(rd=qa.substring(0,ud+1))}if(ed=this.tokenizer.inlineText(rd)){qa=qa.substring(ed.raw.length),ed.raw.slice(-1)!=="_"&&(cd=ed.raw.slice(-1)),ld=!0,td=Ja[Ja.length-1],td&&td.type==="text"?(td.raw+=ed.raw,td.text+=ed.text):Ja.push(ed);continue}if(qa){const ud="Infinite loop on byte: "+qa.charCodeAt(0);if(this.options.silent){console.error(ud);break}else throw new Error(ud)}}return Ja}}class _Renderer{constructor(qa){n_(this,"options");n_(this,"parser");this.options=qa||_defaults}space(qa){return""}code({text:qa,lang:Ja,escaped:ed}){var sd;const td=(sd=(Ja||"").match(/^ \S */))==null?void 0:sd[0],rd=qa.replace(/ \n $ /,"")+ `
2024-08-30 15:19:18 +08:00
` ;return td?'<pre><code class="language-'+escape $ 1 $ 1(td)+'">'+(ed?rd:escape $ 1 $ 1(rd,!0))+ ` < / c o d e > < / p r e >
` :"<pre><code>"+(ed?rd:escape $ 1 $ 1(rd,!0))+ ` < / c o d e > < / p r e >
` }blockquote({tokens:qa}){return ` < blockquote >
$ { this . parser . parse ( qa ) } < / b l o c k q u o t e >
` }html({text:qa}){return qa}heading({tokens:qa,depth:Ja}){return ` < h$ { Ja } > $ { this . parser . parseInline ( qa ) } < / h $ { J a } >
` }hr(qa){return ` < hr >
2024-09-03 08:22:14 +08:00
` }list(qa){const Ja=qa.ordered,ed=qa.start;let td="";for(let od=0;od<qa.items.length;od++){const ld=qa.items[od];td+=this.listitem(ld)}const rd=Ja?"ol":"ul",sd=Ja&&ed!==1?' start="'+ed+'"':"";return"<"+rd+sd+ ` >
2024-08-30 15:19:18 +08:00
` +td+"</"+rd+ ` >
` }listitem(qa){let Ja="";if(qa.task){const ed=this.checkbox({checked:!!qa.checked});qa.loose?qa.tokens.length>0&&qa.tokens[0].type==="paragraph"?(qa.tokens[0].text=ed+" "+qa.tokens[0].text,qa.tokens[0].tokens&&qa.tokens[0].tokens.length>0&&qa.tokens[0].tokens[0].type==="text"&&(qa.tokens[0].tokens[0].text=ed+" "+qa.tokens[0].tokens[0].text)):qa.tokens.unshift({type:"text",raw:ed+" ",text:ed+" "}):Ja+=ed+" "}return Ja+=this.parser.parse(qa.tokens,!!qa.loose), ` < li > $ { Ja } < / l i >
` }checkbox({checked:qa}){return"<input "+(qa?'checked="" ':"")+'disabled="" type="checkbox">'}paragraph({tokens:qa}){return ` < p > $ { this . parser . parseInline ( qa ) } < / p >
2024-09-03 08:22:14 +08:00
` }table(qa){let Ja="",ed="";for(let rd=0;rd<qa.header.length;rd++)ed+=this.tablecell(qa.header[rd]);Ja+=this.tablerow({text:ed});let td="";for(let rd=0;rd<qa.rows.length;rd++){const sd=qa.rows[rd];ed="";for(let od=0;od<sd.length;od++)ed+=this.tablecell(sd[od]);td+=this.tablerow({text:ed})}return td&&(td= ` < tbody > $ { td } < / t b o d y > ` ) , ` < t a b l e >
2024-08-27 22:31:52 +08:00
< thead >
2024-08-30 15:19:18 +08:00
` +Ja+ ` < / t h e a d >
` +td+ ` < / t a b l e >
` }tablerow({text:qa}){return ` < tr >
$ { qa } < / t r >
` }tablecell(qa){const Ja=this.parser.parseInline(qa.tokens),ed=qa.header?"th":"td";return(qa.align? ` < $ { ed } align = "${qa.align}" > ` : ` < $ { ed } > ` )+Ja+ ` < / $ { e d } >
2024-09-07 10:27:05 +08:00
` }strong({tokens:qa}){return ` < strong > $ { this . parser . parseInline ( qa ) } < / s t r o n g > ` } e m ( { t o k e n s : q a } ) { r e t u r n ` < e m > $ { t h i s . p a r s e r . p a r s e I n l i n e ( q a ) } < / e m > ` } c o d e s p a n ( { t e x t : q a } ) { r e t u r n ` < c o d e > $ { q a } < / c o d e > ` } b r ( q a ) { r e t u r n " < b r > " } d e l ( { t o k e n s : q a } ) { r e t u r n ` < d e l > $ { t h i s . p a r s e r . p a r s e I n l i n e ( q a ) } < / d e l > ` } l i n k ( { h r e f : q a , t i t l e : J a , t o k e n s : e d } ) { c o n s t t d = t h i s . p a r s e r . p a r s e I n l i n e ( e d ) , r d = c l e a n U r l ( q a ) ; i f ( r d = = = n u l l ) r e t u r n t d ; q a = r d ; l e t s d = ' < a h r e f = " ' + q a + ' " ' ; r e t u r n J a & & ( s d + = ' t i t l e = " ' + J a + ' " ' ) , s d + = " > " + t d + " < / a > " , s d } i m a g e ( { h r e f : q a , t i t l e : J a , t e x t : e d } ) { c o n s t t d = c l e a n U r l ( q a ) ; i f ( t d = = = n u l l ) r e t u r n e d ; q a = t d ; l e t r d = ` < i m g s r c = " $ { q a } " a l t = " $ { e d } " ` ; r e t u r n J a & & ( r d + = ` t i t l e = " $ { J a } " ` ) , r d + = " > " , r d } t e x t ( q a ) { r e t u r n " t o k e n s " i n q a & & q a . t o k e n s ? t h i s . p a r s e r . p a r s e I n l i n e ( q a . t o k e n s ) : q a . t e x t } } c l a s s _ T e x t R e n d e r e r { s t r o n g ( { t e x t : q a } ) { r e t u r n q a } e m ( { t e x t : q a } ) { r e t u r n q a } c o d e s p a n ( { t e x t : q a } ) { r e t u r n q a } d e l ( { t e x t : q a } ) { r e t u r n q a } h t m l ( { t e x t : q a } ) { r e t u r n q a } t e x t ( { t e x t : q a } ) { r e t u r n q a } l i n k ( { t e x t : q a } ) { r e t u r n " " + q a } i m a g e ( { t e x t : q a } ) { r e t u r n " " + q a } b r ( ) { r e t u r n " " } } c l a s s _ P a r s e r { c o n s t r u c t o r ( q a ) { n _ ( t h i s , " o p t i o n s " ) ; n _ ( t h i s , " r e n d e r e r " ) ; n _ ( t h i s , " t e x t R e n d e r e r " ) ; t h i s . o p t i o n s = q a | | _ d e f a u l t s , t h i s . o p t i o n s . r e n d e r e r = t h i s . o p t i o n s . r e n d e r e r | | n e w _ R e n d e r e r , t h i s . r e n d e r e r = t h i s . o p t i o n s . r e n d e r e r , t h i s . r e n d e r e r . o p t i o n s = t h i s . o p t i o n s , t h i s . r e n d e r e r . p a r s e r = t h i s , t h i s . t e x t R e n d e r e r = n e w _ T e x t R e n d e r e r } s t a t i c p a r s e ( q a , J a ) { r e t u r n n e w _ P a r s e r ( J a ) . p a r s e ( q a ) } s t a t i c p a r s e I n l i n e ( q a , J a ) { r e t u r n n e w _ P a r s e r ( J a ) . p a r s e I n l i n e ( q a ) } p a r s e ( q a , J a = ! 0 ) { l e t e d = " " ; f o r ( l e t t d = 0 ; t d < q a . l e n g t h ; t d + + ) { c o n s t r d = q a [ t d ] ; i f ( t h i s . o p t i o n s . e x t e n s i o n s & & t h i s . o p t i o n s . e x t e n s i o n s . r e n d e r e r s & & t h i s . o p t i o n s . e x t e n s i o n s . r e n d e r e r s [ r d . t y p e ] ) { c o n s t o d = r d , l d = t h i s . o p t i o n s . e x t e n s i o n s . r e n d e r e r s [ o d . t y p e ] . c a l l ( { p a r s e r : t h i s } , o d ) ; i f ( l d ! = = ! 1 | | ! [ " s p a c e " , " h r " , " h e a d i n g " , " c o d e " , " t a b l e " , " b l o c k q u o t e " , " l i s t " , " h t m l " , " p a r a g r a p h " , " t e x t " ] . i n c l u d e s ( o d . t y p e ) ) { e d + = l d | | " " ; c o n t i n u e } } c o n s t s d = r d ; s w i t c h ( s d . t y p e ) { c a s e " s p a c e " : { e d + = t h i s . r e n d e r e r . s p a c e ( s d ) ; c o n t i n u e } c a s e " h r " : { e d + = t h i s . r e n d e r e r . h r ( s d ) ; c o n t i n u e } c a s e " h e a d i n g " : { e d + = t h i s . r e n d e r e r . h e a d i n g ( s d ) ; c o n t i n u e } c a s e " c o d e " : { e d + = t h i s . r e n d e r e r . c o d e ( s d ) ; c o n t i n u e } c a s e " t a b l e " : { e d + = t h i s . r e n d e r e r . t a b l e ( s d ) ; c o n t i n u e } c a s e " b l o c k q u o t e " : { e d + = t h i s . r e n d e r e r . b l o c k q u o t e ( s d ) ; c o n t i n u e } c a s e " l i s t " : { e d + = t h i s . r e n d e r e r . l i s t ( s d ) ; c o n t i n u e } c a s e " h t m l " : { e d + = t h i s . r e n d e r e r . h t m l ( s d ) ; c o n t i n u e } c a s e " p a r a g r a p h " : { e d + = t h i s . r e n d e r e r . p a r a g r a p h ( s d ) ; c o n t i n u e } c a s e " t e x t " : { l e t o d = s d , l d = t h i s . r e n d e r e r . t e x t ( o d ) ; f o r ( ; t d + 1 < q a . l e n g t h & & q a [ t d + 1 ] . t y p e = = = " t e x t " ; ) o d = q a [ + + t d ] , l d + = `
2024-09-08 17:22:36 +08:00
` +this.renderer.text(od);Ja?ed+=this.renderer.paragraph({type:"paragraph",raw:ld,text:ld,tokens:[{type:"text",raw:ld,text:ld}]}):ed+=ld;continue}default:{const od='Token with "'+sd.type+'" type was not found.';if(this.options.silent)return console.error(od),"";throw new Error(od)}}}return ed}parseInline(qa,Ja){Ja=Ja||this.renderer;let ed="";for(let td=0;td<qa.length;td++){const rd=qa[td];if(this.options.extensions&&this.options.extensions.renderers&&this.options.extensions.renderers[rd.type]){const od=this.options.extensions.renderers[rd.type].call({parser:this},rd);if(od!==!1||!["escape","html","link","image","strong","em","codespan","br","del","text"].includes(rd.type)){ed+=od||"";continue}}const sd=rd;switch(sd.type){case"escape":{ed+=Ja.text(sd);break}case"html":{ed+=Ja.html(sd);break}case"link":{ed+=Ja.link(sd);break}case"image":{ed+=Ja.image(sd);break}case"strong":{ed+=Ja.strong(sd);break}case"em":{ed+=Ja.em(sd);break}case"codespan":{ed+=Ja.codespan(sd);break}case"br":{ed+=Ja.br(sd);break}case"del":{ed+=Ja.del(sd);break}case"text":{ed+=Ja.text(sd);break}default:{const od='Token with "'+sd.type+'" type was not found.';if(this.options.silent)return console.error(od),"";throw new Error(od)}}}return ed}}class _Hooks{constructor(qa){n_(this,"options");this.options=qa||_defaults}preprocess(qa){return qa}postprocess(qa){return qa}processAllTokens(qa){return qa}}n_(_Hooks,"passThroughHooks",new Set(["preprocess","postprocess","processAllTokens"]));var mb,lS,CT,cS;class Marked{constructor(...qa){sS(this,mb);n_(this,"defaults",_getDefaults());n_(this,"options",this.setOptions);n_(this,"parse",NE(this,mb,CT).call(this,_Lexer.lex,_Parser.parse));n_(this,"parseInline",NE(this,mb,CT).call(this,_Lexer.lexInline,_Parser.parseInline));n_(this,"Parser",_Parser);n_(this,"Renderer",_Renderer);n_(this,"TextRenderer",_TextRenderer);n_(this,"Lexer",_Lexer);n_(this,"Tokenizer",_Tokenizer);n_(this,"Hooks",_Hooks);this.use(...qa)}walkTokens(qa,Ja){var td,rd;let ed=[];for(const sd of qa)switch(ed=ed.concat(Ja.call(this,sd)),sd.type){case"table":{const od=sd;for(const ld of od.header)ed=ed.concat(this.walkTokens(ld.tokens,Ja));for(const ld of od.rows)for(const cd of ld)ed=ed.concat(this.walkTokens(cd.tokens,Ja));break}case"list":{const od=sd;ed=ed.concat(this.walkTokens(od.items,Ja));break}default:{const od=sd;(rd=(td=this.defaults.extensions)==null?void 0:td.childTokens)!=null&&rd[od.type]?this.defaults.extensions.childTokens[od.type].forEach(ld=>{const cd=od[ld].flat(1/0);ed=ed.concat(this.walkTokens(cd,Ja))}):od.tokens&&(ed=ed.concat(this.walkTokens(od.tokens,Ja)))}}return ed}use(...qa){const Ja=this.defaults.extensions||{renderers:{},childTokens:{}};return qa.forEach(ed=>{const td={...ed};if(td.async=this.defaults.async||td.async||!1,ed.extensions&&(ed.extensions.forEach(rd=>{if(!rd.name)throw new Error("extension name required");if("renderer"in rd){const sd=Ja.renderers[rd.name];sd?Ja.renderers[rd.name]=function(...od){let ld=rd.renderer.apply(this,od);return ld===!1&&(ld=sd.apply(this,od)),ld}:Ja.renderers[rd.name]=rd.renderer}if("tokenizer"in rd){if(!rd.level||rd.level!=="block"&&rd.level!=="inline")throw new Error("extension level must be 'block' or 'inline'");const sd=Ja[rd.level];sd?sd.unshift(rd.tokenizer):Ja[rd.level]=[rd.tokenizer],rd.start&&(rd.level==="block"?Ja.startBlock?Ja.startBlock.push(rd.start):Ja.startBlock=[rd.start]:rd.level==="inline"&&(Ja.startInline?Ja.startInline.push(rd.start):Ja.startInline=[rd.start]))}"childTokens"in rd&&rd.childTokens&&(Ja.childTokens[rd.name]=rd.childTokens)}),td.extensions=Ja),ed.renderer){const rd=this.defaults.renderer||new _Renderer(this.defaults);for(const sd in ed.renderer){if(!(sd in rd))throw new Error( ` renderer '${sd}' does not exist ` );if(["options","parser"].includes(sd))continue;const od=sd;let ld=ed.renderer[od];ed.useNewRenderer||(ld=NE(this,mb,lS).call(this,ld,od,rd));const cd=rd[od];rd[od]=(...ud)=>{let _d=ld.apply(rd,ud);return _d===!1&&(_d=cd.apply(rd,ud)),_d||""}}td.renderer=rd}if(ed.tokenizer){const rd=this.defaults.tokenizer||new _Tokenizer(this.defaults);for(const sd in
2024-09-03 08:22:14 +08:00
Please report this to https : //github.com/markedjs/marked.`,qa){const td="<p>An error occurred:</p><pre>"+escape$1$1(ed.message+"",!0)+"</pre>";return Ja?Promise.resolve(td):td}if(Ja)return Promise.reject(ed);throw ed}};const markedInstance=new Marked;function marked(Ra,qa){return markedInstance.parse(Ra,qa)}marked.options=marked.setOptions=function(Ra){return markedInstance.setOptions(Ra),marked.defaults=markedInstance.defaults,changeDefaults(marked.defaults),marked};marked.getDefaults=_getDefaults;marked.defaults=_defaults;marked.use=function(...Ra){return markedInstance.use(...Ra),marked.defaults=markedInstance.defaults,changeDefaults(marked.defaults),marked};marked.walkTokens=function(Ra,qa){return markedInstance.walkTokens(Ra,qa)};marked.parseInline=markedInstance.parseInline;marked.Parser=_Parser;marked.parser=_Parser.parse;marked.Renderer=_Renderer;marked.TextRenderer=_TextRenderer;marked.Lexer=_Lexer;marked.lexer=_Lexer.lex;marked.Tokenizer=_Tokenizer;marked.Hooks=_Hooks;marked.parse=marked;marked.options;marked.setOptions;marked.use;marked.walkTokens;marked.parseInline;_Parser.parse;_Lexer.lex;function dedent(Ra){for(var qa=[],Ja=1;Ja<arguments.length;Ja++)qa[Ja-1]=arguments[Ja];var ed=Array.from(typeof Ra=="string"?[Ra]:Ra);ed[ed.length-1]=ed[ed.length-1].replace(/\r?\n([\t ]*)$/,"");var td=ed.reduce(function(od,ld){var cd=ld.match(/\n([\t ]+|(?!\s).)/g);return cd?od.concat(cd.map(function(ud){var _d,yd;return(yd=(_d=ud.match(/[\t ]/g))===null||_d===void 0?void 0:_d.length)!==null&&yd!==void 0?yd:0})):od},[]);if(td.length){var rd=new RegExp(`
[ ] { ` +Math.min.apply(Math,td)+"}","g");ed=ed.map(function(od){return od.replace(rd, `
` )})}ed[0]=ed[0].replace(/^ \r ? \n /,"");var sd=ed[0];return qa.forEach(function(od,ld){var cd=sd.match(/(?:^| \n )( *) $ /),ud=cd?cd[1]:"",_d=od;typeof od=="string"&&od.includes( `
` )&&(_d=String(od).split( `
2024-08-31 11:28:56 +08:00
` ).map(function(yd,gd){return gd===0?yd:""+ud+yd}).join( `
2024-09-03 08:22:14 +08:00
` )),sd+=_d+ed[ld+1]}),sd}function preprocessMarkdown(Ra,{markdownAutoWrap:qa}){const ed=Ra.replace(/<br \/ >/g, `
2024-08-27 22:31:52 +08:00
` ).replace(/ \n {2,}/g, `
2024-09-03 08:22:14 +08:00
` ),td=dedent(ed);return qa===!1?td.replace(/ /g," "):td}__name(preprocessMarkdown,"preprocessMarkdown");function markdownToLines(Ra,qa={}){const Ja=preprocessMarkdown(Ra,qa),ed=marked.lexer(Ja),td=[[]];let rd=0;function sd(od,ld="normal"){od.type==="text"?od.text.split( `
` ).forEach((ud,_d)=>{_d!==0&&(rd++,td.push([])),ud.split(" ").forEach(yd=>{yd&&td[rd].push({content:yd,type:ld})})}):od.type==="strong"||od.type==="em"?od.tokens.forEach(cd=>{sd(cd,od.type)}):od.type==="html"&&td[rd].push({content:od.text,type:"normal"})}return __name(sd,"processNode"),ed.forEach(od=>{var ld;od.type==="paragraph"?(ld=od.tokens)==null||ld.forEach(cd=>{sd(cd)}):od.type==="html"&&td[rd].push({content:od.text,type:"normal"})}),td}__name(markdownToLines,"markdownToLines");function markdownToHTML(Ra,{markdownAutoWrap:qa}={}){const Ja=marked.lexer(Ra);function ed(td){var rd,sd,od;return td.type==="text"?qa===!1?td.text.replace(/ \n */g,"<br/>").replace(/ /g," "):td.text.replace(/ \n */g,"<br/>"):td.type==="strong"? ` < strong > $ { ( rd = td . tokens ) == null ? void 0 : rd . map ( ed ) . join ( "" ) } < / s t r o n g > ` : t d . t y p e = = = " e m " ? ` < e m > $ { ( s d = t d . t o k e n s ) = = n u l l ? v o i d 0 : s d . m a p ( e d ) . j o i n ( " " ) } < / e m > ` : t d . t y p e = = = " p a r a g r a p h " ? ` < p > $ { ( o d = t d . t o k e n s ) = = n u l l ? v o i d 0 : o d . m a p ( e d ) . j o i n ( " " ) } < / p > ` : t d . t y p e = = = " s p a c e " ? " " : t d . t y p e = = = " h t m l " ? ` $ { t d . t e x t } ` : ` U n s u p p o r t e d m a r k d o w n : $ { t d . t y p e } ` } r e t u r n _ _ n a m e ( e d , " o u t p u t " ) , J a . m a p ( e d ) . j o i n ( " " ) } _ _ n a m e ( m a r k d o w n T o H T M L , " m a r k d o w n T o H T M L " ) ; f u n c t i o n s p l i t T e x t T o C h a r s ( R a ) { r e t u r n I n t l . S e g m e n t e r ? [ . . . n e w I n t l . S e g m e n t e r ( ) . s e g m e n t ( R a ) ] . m a p ( q a = > q a . s e g m e n t ) : [ . . . R a ] } _ _ n a m e ( s p l i t T e x t T o C h a r s , " s p l i t T e x t T o C h a r s " ) ; f u n c t i o n s p l i t W o r d T o F i t W i d t h ( R a , q a ) { c o n s t J a = s p l i t T e x t T o C h a r s ( q a . c o n t e n t ) ; r e t u r n s p l i t W o r d T o F i t W i d t h R e c u r s i o n ( R a , [ ] , J a , q a . t y p e ) } _ _ n a m e ( s p l i t W o r d T o F i t W i d t h , " s p l i t W o r d T o F i t W i d t h " ) ; f u n c t i o n s p l i t W o r d T o F i t W i d t h R e c u r s i o n ( R a , q a , J a , e d ) { i f ( J a . l e n g t h = = = 0 ) r e t u r n [ { c o n t e n t : q a . j o i n ( " " ) , t y p e : e d } , { c o n t e n t : " " , t y p e : e d } ] ; c o n s t [ t d , . . . r d ] = J a , s d = [ . . . q a , t d ] ; r e t u r n R a ( [ { c o n t e n t : s d . j o i n ( " " ) , t y p e : e d } ] ) ? s p l i t W o r d T o F i t W i d t h R e c u r s i o n ( R a , s d , r d , e d ) : ( q a . l e n g t h = = = 0 & & t d & & ( q a . p u s h ( t d ) , J a . s h i f t ( ) ) , [ { c o n t e n t : q a . j o i n ( " " ) , t y p e : e d } , { c o n t e n t : J a . j o i n ( " " ) , t y p e : e d } ] ) } _ _ n a m e ( s p l i t W o r d T o F i t W i d t h R e c u r s i o n , " s p l i t W o r d T o F i t W i d t h R e c u r s i o n " ) ; f u n c t i o n s p l i t L i n e T o F i t W i d t h ( R a , q a ) { i f ( R a . s o m e ( ( { c o n t e n t : J a } ) = > J a . i n c l u d e s ( `
` )))throw new Error("splitLineToFitWidth does not support newlines in the line");return splitLineToFitWidthRecursion(Ra,qa)}__name(splitLineToFitWidth,"splitLineToFitWidth");function splitLineToFitWidthRecursion(Ra,qa,Ja=[],ed=[]){if(Ra.length===0)return ed.length>0&&Ja.push(ed),Ja.length>0?Ja:[];let td="";Ra[0].content===" "&&(td=" ",Ra.shift());const rd=Ra.shift()??{content:" ",type:"normal"},sd=[...ed];if(td!==""&&sd.push({content:td,type:"normal"}),sd.push(rd),qa(sd))return splitLineToFitWidthRecursion(Ra,qa,Ja,sd);if(ed.length>0)Ja.push(ed),Ra.unshift(rd);else if(rd.content){const[od,ld]=splitWordToFitWidth(qa,rd);Ja.push([od]),ld.content&&Ra.unshift(ld)}return splitLineToFitWidthRecursion(Ra,qa,Ja)}__name(splitLineToFitWidthRecursion,"splitLineToFitWidthRecursion");function applyStyle $ 1(Ra,qa){qa&&Ra.attr("style",qa)}__name(applyStyle $ 1,"applyStyle");async function addHtmlSpan(Ra,qa,Ja,ed,td=!1){const rd=Ra.append("foreignObject"),sd=rd.append("xhtml:div");let od=qa.label;qa.label&&hasKatex(qa.label)&&(od=await renderKatex(qa.label.replace(common_default.lineBreakRegex, `
2024-09-08 17:22:36 +08:00
` ),getConfig2()));const ld=qa.isNode?"nodeLabel":"edgeLabel",cd=sd.append("span");cd.html(od),applyStyle $ 1(cd,qa.labelStyle),cd.attr("class", ` $ { ld } $ { ed } ` ),applyStyle $ 1(sd,qa.labelStyle),sd.style("display","table-cell"),sd.style("white-space","nowrap"),sd.style("line-height","1.5"),sd.style("max-width",Ja+"px"),sd.style("text-align","center"),sd.attr("xmlns","http://www.w3.org/1999/xhtml"),td&&sd.attr("class","labelBkg");let ud=sd.node().getBoundingClientRect();return ud.width===Ja&&(sd.style("display","table"),sd.style("white-space","break-spaces"),sd.style("width",Ja+"px"),ud=sd.node().getBoundingClientRect()),rd.node()}__name(addHtmlSpan,"addHtmlSpan");function createTspan(Ra,qa,Ja){return Ra.append("tspan").attr("class","text-outer-tspan").attr("x",0).attr("y",qa*Ja-.1+"em").attr("dy",Ja+"em")}__name(createTspan,"createTspan");function computeWidthOfText(Ra,qa,Ja){const ed=Ra.append("text"),td=createTspan(ed,1,qa);updateTextContentAndStyles(td,Ja);const rd=td.node().getComputedTextLength();return ed.remove(),rd}__name(computeWidthOfText,"computeWidthOfText");function computeDimensionOfText(Ra,qa,Ja){var sd;const ed=Ra.append("text"),td=createTspan(ed,1,qa);updateTextContentAndStyles(td,[{content:Ja,type:"normal"}]);const rd=(sd=td.node())==null?void 0:sd.getBoundingClientRect();return rd&&ed.remove(),rd}__name(computeDimensionOfText,"computeDimensionOfText");function createFormattedText(Ra,qa,Ja,ed=!1){const rd=qa.append("g"),sd=rd.insert("rect").attr("class","background").attr("style","stroke: none"),od=rd.append("text").attr("y","-10.1");let ld=0;for(const cd of Ja){const ud=__name(yd=>computeWidthOfText(rd,1.1,yd)<=Ra,"checkWidth"),_d=ud(cd)?[cd]:splitLineToFitWidth(cd,ud);for(const yd of _d){const gd=createTspan(od,ld,1.1);updateTextContentAndStyles(gd,yd),ld++}}if(ed){const cd=od.node().getBBox(),ud=2;return sd.attr("x",-ud).attr("y",-ud).attr("width",cd.width+2*ud).attr("height",cd.height+2*ud),rd.node()}else return od.node()}__name(createFormattedText,"createFormattedText");function updateTextContentAndStyles(Ra,qa){Ra.text(""),qa.forEach((Ja,ed)=>{const td=Ra.append("tspan").attr("font-style",Ja.type==="em"?"italic":"normal").attr("class","text-inner-tspan").attr("font-weight",Ja.type==="strong"?"bold":"normal");ed===0?td.text(Ja.content):td.text(" "+Ja.content)})}__name(updateTextContentAndStyles,"updateTextContentAndStyles");function replaceIconSubstring(Ra){return Ra.replace(/fa[bklrs]?:fa-[ \w -]+/g,qa=> ` < i class = '${qa.replace(":"," ")}' > < /i>`)}__name(replaceIconSubstring,"replaceIconSubstring");var createText=__name(async(Ra,qa="",{style:Ja="",isTitle:ed=!1,classes:td="",useHtmlLabels:rd=!0,isNode:sd=!0,width:od=200,addSvgBackground:ld=!1}={},cd)=>{if(log$1.info("XYZ createText",qa,Ja,ed,td,rd,sd,"addSvgBackground: ",ld),rd){const ud=markdownToHTML(qa,cd),_d=replaceIconSubstring(decodeEntities(ud)),yd=qa.replace(/ \ \ \ \ / g , "\\" ) , gd = { isNode : sd , label : hasKatex ( qa ) ? yd : _d , labelStyle : Ja . replace ( "fill:" , "color:" ) } ; return await addHtmlSpan ( Ra , gd , od , td , ld ) } else { const ud = qa . replace ( /<br\s*\/?>/g , "<br/>" ) , _d = markdownToLines ( ud . replace ( "<br>" , "<br/>" ) , cd ) , yd = createFormattedText ( od , Ra , _d , qa ? ld : ! 1 ) ; if ( sd ) { /stroke:/ . exec ( Ja ) && ( Ja = Ja . replace ( "stroke:" , "lineColor:" ) ) ; const gd = Ja . replace ( /stroke:[^;]+;?/g , "" ) . replace ( /stroke-width:[^;]+;?/g , "" ) . replace ( /fill:[^;]+;?/g , "" ) . replace ( /color:/g , "fill:" ) ; select ( yd ) . attr ( "style" , gd ) } else { const gd = Ja . replace ( /stroke:[^;]+;?/g , "" ) . replace ( /stroke-width:[^;]+;?/g , "" ) . replace ( /fill:[^;]+;?/g , "" ) . replace ( /background:/g , "fill:" ) ; select ( yd ) . select ( "rect" ) . attr ( "style" , gd . replace ( /background:/g , "fill:" ) ) ; const Ed = Ja . replace ( /stroke:[^;]+;?/g , "" ) . replace ( /stroke-width:[^;]+;?/g , "" ) . replace ( /fill:[^;]+;?/g , "" ) . replace ( /color:/g , "fill:" ) ; select ( yd ) . select ( "text" ) . attr ( "style" , Ed ) } return yd } } , "createText" ) ; function t ( Ra , qa , Ja ) { if ( Ra && Ra . length ) { const [ ed , td ] = qa , rd = Math . PI / 180 * Ja , sd = Math . cos ( rd ) , od = Math . sin ( rd ) ; for ( const ld of Ra ) { const [ cd , ud ] = ld ; ld [ 0 ] = ( cd - ed ) * sd - ( ud - td ) * od + ed , ld [ 1 ] = ( cd - ed ) * od + ( ud - td ) * sd + td } } } function e ( Ra , qa ) { return Ra [ 0 ] === qa [ 0 ] && Ra [ 1 ] === qa [ 1 ] } function s ( Ra , qa , Ja , ed = 1 ) { const td
` ),getConfig2()));const td=Ra.isNode?"nodeLabel":"edgeLabel";return Ja.html('<span class="'+td+'" '+(Ra.labelStyle?'style="'+Ra.labelStyle+'"':"")+">"+ed+"</span>"),applyStyle(Ja,Ra.labelStyle),Ja.style("display","inline-block"),Ja.style("padding-right","1px"),Ja.style("white-space","nowrap"),Ja.attr("xmlns","http://www.w3.org/1999/xhtml"),qa.node()}__name(addHtmlLabel,"addHtmlLabel");var createLabel=__name(async(Ra,qa,Ja,ed)=>{let td=Ra||"";if(typeof td=="object"&&(td=td[0]),evaluate(getConfig2().flowchart.htmlLabels)){td=td.replace(/ \\ n| \n /g,"<br />"),log $ 1.info("vertexText"+td);const rd={isNode:ed,label:decodeEntities(td).replace(/fa[blrs]?:fa-[ \w -]+/g,od=> ` < i class = '${od.replace(":"," ")}' > < /i>`),labelStyle:qa&&qa.replace("fill:","color:")};return await addHtmlLabel(rd)}else{const rd=document.createElementNS("http:/ / www . w3 . org / 2000 / svg "," text ");rd.setAttribute(" style ",qa.replace(" color : "," fill : "));let sd=[];typeof td==" string "?sd=td.split(/\\n|\n|<br\s*\/?>/gi):Array.isArray(td)?sd=td:sd=[];for(const od of sd){const ld=document.createElementNS(" http : //www.w3.org/2000/svg","tspan");ld.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),ld.setAttribute("dy","1em"),ld.setAttribute("x","0"),Ja?ld.setAttribute("class","title-row"):ld.setAttribute("class","row"),ld.textContent=od.trim(),rd.appendChild(ld)}return rd}},"createLabel"),createLabel_default=createLabel,createRoundedRectPathD=__name((Ra,qa,Ja,ed,td)=>["M",Ra+td,qa,"H",Ra+Ja-td,"A",td,td,0,0,1,Ra+Ja,qa+td,"V",qa+ed-td,"A",td,td,0,0,1,Ra+Ja-td,qa+ed,"H",Ra+td,"A",td,td,0,0,1,Ra,qa+ed-td,"V",qa+td,"A",td,td,0,0,1,Ra+td,qa,"Z"].join(" "),"createRoundedRectPathD"),solidStateFill=__name(Ra=>{const{handDrawnSeed:qa}=getConfig2();return{fill:Ra,hachureAngle:120,hachureGap:4,fillWeight:2,roughness:.7,stroke:Ra,seed:qa}},"solidStateFill"),compileStyles=__name(Ra=>{const qa=styles2Map([...Ra.cssCompiledStyles||[],...Ra.cssStyles||[]]);return{stylesMap:qa,stylesArray:[...qa]}},"compileStyles"),styles2Map=__name(Ra=>{const qa=new Map;return Ra.forEach(Ja=>{const[ed,td]=Ja.split(":");qa.set(ed.trim(),td==null?void 0:td.trim())}),qa},"styles2Map"),styles2String=__name(Ra=>{const{stylesArray:qa}=compileStyles(Ra),Ja=[],ed=[],td=[],rd=[];return qa.forEach(sd=>{const od=sd[0];od==="color"||od==="font-size"||od==="font-family"||od==="font-weight"||od==="font-style"||od==="text-decoration"||od==="text-align"||od==="text-transform"||od==="line-height"||od==="letter-spacing"||od==="word-spacing"||od==="text-shadow"||od==="text-overflow"||od==="white-space"||od==="word-wrap"||od==="word-break"||od==="overflow-wrap"||od==="hyphens"?Ja.push(sd.join(":")+" !important"):(ed.push(sd.join(":")+" !important"),od.includes("stroke")&&td.push(sd.join(":")+" !important"),od==="fill"&&rd.push(sd.join(":")+" !important"))}),{labelStyles:Ja.join(";"),nodeStyles:ed.join(";"),stylesArray:qa,borderStyles:td,backgroundStyles:rd}},"styles2String"),userNodeOverrides=__name((Ra,qa)=>{const{themeVariables:Ja,handDrawnSeed:ed}=getConfig2(),{nodeBorder:td,mainBkg:rd}=Ja,{stylesMap:sd}=compileStyles(Ra);return Object.assign({roughness:.7,fill:sd.get("fill")||rd,fillStyle:"hachure",fillWeight:4,stroke:sd.get("stroke")||td,seed:ed,strokeWidth:1.3},qa)},"userNodeOverrides"),rect$2=__name(async(Ra,qa)=>{log$1.info("Creating subgraph rect for ",qa.id,qa);const Ja=getConfig2(),{themeVariables:ed,handDrawnSeed:td}=Ja,{clusterBkg:rd,clusterBorder:sd}=ed,{labelStyles:od,nodeStyles:ld,borderStyles:cd,backgroundStyles:ud}=styles2String(qa),_d=Ra.insert("g").attr("class","cluster "+qa.cssClasses).attr("id",qa.id).attr("data-look",qa.look),yd=evaluate(Ja.flowchart.htmlLabels),gd=_d.insert("g").attr("class","cluster-label "),Ed=await createText(gd,qa.label,{style:qa.labelStyle,useHtmlLabels:yd,isNode:!0});let Td=Ed.getBBox();if(evaluate(Ja.flowchart.htmlLabels)){const qd=Ed.children[0],Yd=select(Ed);Td=qd.getBoundingClientRect(),Yd.attr("width",Td.width),Yd.attr("height",Td.height)}const Od=qa.width<=Td.width+qa.padding?Td.width+qa.padding:qa.width;qa.width<=Td.width+qa.padding?qa.diff=(Od-qa.widt
2024-08-30 15:19:18 +08:00
outsidePoint : $ { JSON . stringify ( qa ) }
insidePoint : $ { JSON . stringify ( Ja ) }
2024-09-08 17:22:36 +08:00
node : x : $ { Ra . x } y : $ { Ra . y } w : $ { Ra . width } h : $ { Ra . height } ` );const ed=Ra.x,td=Ra.y,rd=Math.abs(ed-Ja.x),sd=Ra.width/2;let od=Ja.x<qa.x?sd-rd:sd+rd;const ld=Ra.height/2,cd=Math.abs(qa.y-Ja.y),ud=Math.abs(qa.x-Ja.x);if(Math.abs(td-qa.y)*sd>Math.abs(ed-qa.x)*ld){let _d=Ja.y<qa.y?qa.y-ld-td:td-ld-qa.y;od=ud*_d/cd;const yd={x:Ja.x<qa.x?Ja.x+od:Ja.x-ud+od,y:Ja.y<qa.y?Ja.y+cd-_d:Ja.y-cd+_d};return od===0&&(yd.x=qa.x,yd.y=qa.y),ud===0&&(yd.x=qa.x),cd===0&&(yd.y=qa.y),log $ 1.debug( ` abc89 top / bottom calc , Q $ { cd } , q $ { _d } , R $ { ud } , r $ { od } ` ,yd),yd}else{Ja.x<qa.x?od=qa.x-sd-ed:od=ed-sd-qa.x;let _d=cd*od/ud,yd=Ja.x<qa.x?Ja.x+ud-od:Ja.x-ud+od,gd=Ja.y<qa.y?Ja.y+_d:Ja.y-_d;return log $ 1.debug( ` sides calc abc89 , Q $ { cd } , q $ { _d } , R $ { ud } , r $ { od } ` ,{_x:yd,_y:gd}),od===0&&(yd=qa.x,gd=qa.y),ud===0&&(yd=qa.x),cd===0&&(gd=qa.y),{x:yd,y:gd}}},"intersection"),cutPathAtIntersect=__name((Ra,qa)=>{log $ 1.warn("abc88 cutPathAtIntersect",Ra,qa);let Ja=[],ed=Ra[0],td=!1;return Ra.forEach(rd=>{if(log $ 1.info("abc88 checking point",rd,qa),!outsideNode(qa,rd)&&!td){const sd=intersection(qa,ed,rd);log $ 1.debug("abc88 inside",rd,ed,sd),log $ 1.debug("abc88 intersection",sd,qa);let od=!1;Ja.forEach(ld=>{od=od||ld.x===sd.x&&ld.y===sd.y}),Ja.some(ld=>ld.x===sd.x&&ld.y===sd.y)?log $ 1.warn("abc88 no intersect",sd,Ja):Ja.push(sd),td=!0}else log $ 1.warn("abc88 outside",rd,ed),ed=rd,td||Ja.push(rd)}),log $ 1.debug("returning points",Ja),Ja},"cutPathAtIntersect");function extractCornerPoints(Ra){const qa=[],Ja=[];for(let ed=1;ed<Ra.length-1;ed++){const td=Ra[ed-1],rd=Ra[ed],sd=Ra[ed+1];(td.x===rd.x&&rd.y===sd.y&&Math.abs(rd.x-sd.x)>5&&Math.abs(rd.y-td.y)>5||td.y===rd.y&&rd.x===sd.x&&Math.abs(rd.x-td.x)>5&&Math.abs(rd.y-sd.y)>5)&&(qa.push(rd),Ja.push(ed))}return{cornerPoints:qa,cornerPointPositions:Ja}}__name(extractCornerPoints,"extractCornerPoints");var findAdjacentPoint=__name(function(Ra,qa,Ja){const ed=qa.x-Ra.x,td=qa.y-Ra.y,rd=Math.sqrt(ed*ed+td*td),sd=Ja/rd;return{x:qa.x-sd*ed,y:qa.y-sd*td}},"findAdjacentPoint"),fixCorners=__name(function(Ra){const{cornerPointPositions:qa}=extractCornerPoints(Ra),Ja=[];for(let ed=0;ed<Ra.length;ed++)if(qa.includes(ed)){const td=Ra[ed-1],rd=Ra[ed+1],sd=Ra[ed],od=findAdjacentPoint(td,sd,5),ld=findAdjacentPoint(rd,sd,5),cd=ld.x-od.x,ud=ld.y-od.y;Ja.push(od);const _d=Math.sqrt(2)*2;let yd={x:sd.x,y:sd.y};if(Math.abs(rd.x-td.x)>10&&Math.abs(rd.y-td.y)>=10){log $ 1.debug("Corner point fixing",Math.abs(rd.x-td.x),Math.abs(rd.y-td.y));const gd=5;sd.x===od.x?yd={x:cd<0?od.x-gd+_d:od.x+gd-_d,y:ud<0?od.y-_d:od.y+_d}:yd={x:cd<0?od.x-_d:od.x+_d,y:ud<0?od.y-gd+_d:od.y+gd-_d}}else log $ 1.debug("Corner point skipping fixing",Math.abs(rd.x-td.x),Math.abs(rd.y-td.y));Ja.push(yd,ld)}else Ja.push(Ra[ed]);return Ja},"fixCorners"),insertEdge=__name(function(Ra,qa,Ja,ed,td,rd,sd){const{handDrawnSeed:od}=getConfig2();let ld=qa.points,cd=!1;const ud=td;var _d=rd;_d.intersect&&ud.intersect&&(ld=ld.slice(1,qa.points.length-1),ld.unshift(ud.intersect(ld[0])),log $ 1.debug("Last point APA12",qa.start,"-->",qa.end,ld[ld.length-1],_d,_d.intersect(ld[ld.length-1])),ld.push(_d.intersect(ld[ld.length-1]))),qa.toCluster&&(log $ 1.info("to cluster abc88",Ja.get(qa.toCluster)),ld=cutPathAtIntersect(qa.points,Ja.get(qa.toCluster).node),cd=!0),qa.fromCluster&&(log $ 1.debug("from cluster abc88",Ja.get(qa.fromCluster),JSON.stringify(ld,null,2)),ld=cutPathAtIntersect(ld.reverse(),Ja.get(qa.fromCluster).node).reverse(),cd=!0);let yd=ld.filter(Yd=>!Number.isNaN(Yd.y));yd=fixCorners(yd);let gd=yd[yd.length-1];if(yd.length>1){gd=yd[yd.length-1];const Yd=yd[yd.length-2],Ud=(gd.x-Yd.x)/2,Hd=(gd.y-Yd.y)/2,zd={x:Yd.x+Ud,y:Yd.y+Hd};yd.splice(-1,0,zd)}let Ed=curveBasis;qa.curve&&(Ed=qa.curve);const{x:Td,y:Od}=getLineFunctionsWithOffset(qa),Rd=line $ 1().x(Td).y(Od).curve(Ed);let Nd;switch(qa.thickness){case"normal":Nd="edge-thickness-normal";break;case"thick":Nd="edge-thickness-thick";break;case"invisible":Nd="edge-thickness-invisible";break;default:Nd="edge-thickness-normal"}switch(qa.pattern){case"solid":Nd+=" edge-pattern-solid";break;case"dotted":Nd+=" edge-pattern-dotted";break;case"
2024-08-31 11:28:56 +08:00
point : ` ,yd, `
2024-08-27 22:31:52 +08:00
node :
2024-08-30 15:19:18 +08:00
` ,qa, `
2024-09-08 19:53:57 +08:00
res : ` ,intersect_default.polygon(qa,cd,yd)),intersect_default.polygon(qa,cd,yd)},td},"question"),createHexagonPathD=__name((Ra,qa,Ja,ed,td)=>[ ` M$ { Ra + td } , $ { qa } ` , ` L$ { Ra + Ja - td } , $ { qa } ` , ` L$ { Ra + Ja } , $ { qa - ed / 2 } ` , ` L$ { Ra + Ja - td } , $ { qa - ed } ` , ` L$ { Ra + td } , $ { qa - ed } ` , ` L$ { Ra } , $ { qa - ed / 2 } ` ,"Z"].join(" "),"createHexagonPathD"),hexagon=__name(async(Ra,qa)=>{const{labelStyles:Ja,nodeStyles:ed}=styles2String(qa);qa.labelStyle=Ja;const{shapeSvg:td,bbox:rd}=await labelHelper(Ra,qa,getNodeClasses(qa)),sd=4,od=rd.height+qa.padding,ld=od/sd,cd=rd.width+2*ld+qa.padding,ud=[{x:ld,y:0},{x:cd-ld,y:0},{x:cd,y:-od/2},{x:cd-ld,y:-od},{x:ld,y:-od},{x:0,y:-od/2}];let _d;const{cssStyles:yd}=qa;if(qa.look==="handDrawn"){const gd=at $ 4.svg(td),Ed=userNodeOverrides(qa,{}),Td=createHexagonPathD(0,0,cd,od,ld),Od=gd.path(Td,Ed);_d=td.insert(()=>Od,":first-child").attr("transform", ` translate ( $ { - cd / 2 } , $ { od / 2 } ) ` ),yd&&_d.attr("style",yd)}else _d=insertPolygonShape(td,cd,od,ud);return ed&&_d.attr("style",ed),qa.width=cd,qa.height=od,updateNodeBounds(qa,_d),qa.intersect=function(gd){return intersect_default.polygon(qa,ud,gd)},td},"hexagon"),createLeanRightPathD=__name((Ra,qa,Ja,ed)=>[ ` M$ { Ra - 2 * ed / 6 } , $ { qa } ` , ` L$ { Ra + Ja - ed / 6 } , $ { qa } ` , ` L$ { Ra + Ja + 2 * ed / 6 } , $ { qa - ed } ` , ` L$ { Ra + ed / 6 } , $ { qa - ed } ` ,"Z"].join(" "),"createLeanRightPathD"),lean_right=__name(async(Ra,qa)=>{const{labelStyles:Ja,nodeStyles:ed}=styles2String(qa);qa.labelStyle=Ja;const{shapeSvg:td,bbox:rd}=await labelHelper(Ra,qa,getNodeClasses(qa)),sd=rd.width+qa.padding,od=rd.height+qa.padding,ld=[{x:-2*od/6,y:0},{x:sd-od/6,y:0},{x:sd+2*od/6,y:-od},{x:od/6,y:-od}];let cd;const{cssStyles:ud}=qa;if(qa.look==="handDrawn"){const _d=at $ 4.svg(td),yd=userNodeOverrides(qa,{}),gd=createLeanRightPathD(0,0,sd,od),Ed=_d.path(gd,yd);cd=td.insert(()=>Ed,":first-child").attr("transform", ` translate ( $ { - sd / 2 } , $ { od / 2 } ) ` ),ud&&cd.attr("style",ud)}else cd=insertPolygonShape(td,sd,od,ld);return ed&&cd.attr("style",ed),qa.width=sd,qa.height=od,updateNodeBounds(qa,cd),qa.intersect=function(_d){return intersect_default.polygon(qa,ld,_d)},td},"lean_right"),createLeanLeftPathD=__name((Ra,qa,Ja,ed)=>[ ` M$ { Ra + 2 * ed / 6 } , $ { qa } ` , ` L$ { Ra + Ja + ed / 6 } , $ { qa } ` , ` L$ { Ra + Ja - 2 * ed / 6 } , $ { qa - ed } ` , ` L$ { Ra - ed / 6 } , $ { qa - ed } ` ,"Z"].join(" "),"createLeanLeftPathD"),lean_left=__name(async(Ra,qa)=>{const{labelStyles:Ja,nodeStyles:ed}=styles2String(qa);qa.labelStyle=Ja;const{shapeSvg:td,bbox:rd}=await labelHelper(Ra,qa,getNodeClasses(qa)),sd=rd.width+qa.padding,od=rd.height+qa.padding,ld=[{x:2*od/6,y:0},{x:sd+od/6,y:0},{x:sd-2*od/6,y:-od},{x:-od/6,y:-od}];let cd;const{cssStyles:ud}=qa;if(qa.look==="handDrawn"){const _d=at $ 4.svg(td),yd=userNodeOverrides(qa,{}),gd=createLeanLeftPathD(0,0,sd,od),Ed=_d.path(gd,yd);cd=td.insert(()=>Ed,":first-child").attr("transform", ` translate ( $ { - sd / 2 } , $ { od / 2 } ) ` ),ud&&cd.attr("style",ud)}else cd=insertPolygonShape(td,sd,od,ld);return ed&&cd.attr("style",ed),qa.width=sd,qa.height=od,updateNodeBounds(qa,cd),qa.intersect=function(_d){return intersect_default.polygon(qa,ld,_d)},td},"lean_left"),createTrapezoidPathD=__name((Ra,qa,Ja,ed)=>[ ` M$ { Ra - 2 * ed / 6 } , $ { qa } ` , ` L$ { Ra + Ja + 2 * ed / 6 } , $ { qa } ` , ` L$ { Ra + Ja - ed / 6 } , $ { qa - ed } ` , ` L$ { Ra + ed / 6 } , $ { qa - ed } ` ,"Z"].join(" "),"createTrapezoidPathD"),trapezoid=__name(async(Ra,qa)=>{const{labelStyles:Ja,nodeStyles:ed}=styles2String(qa);qa.labelStyle=Ja;const{shapeSvg:td,bbox:rd}=await labelHelper(Ra,qa,getNodeClasses(qa)),sd=rd.width+qa.padding,od=rd.height+qa.padding,ld=[{x:-2*od/6,y:0},{x:sd+2*od/6,y:0},{x:sd-od/6,y:-od},{x:od/6,y:-od}];let cd;const{cssStyles:ud}=qa;if(qa.look==="handDrawn"){const _d=at $ 4.svg(td),yd=userNodeOverrides(qa,{}),gd=createTrapezoidPathD(0,0,sd,od),Ed=_d.path(gd,yd);cd=td.insert(()=>Ed,":first-child").attr("transform", ` translate ( $ { - sd / 2 } , $ { od / 2 } ) ` ),ud&&cd.attr("style",ud)}else cd=insertPolygonShape(td,sd,od,ld);return ed&&cd.attr("style",ed),qa.width=sd,qa.height=od,updateNodeBounds(qa,cd),qa.intersect=function(_d){return intersect_default.polygon(qa,ld,_d)},td},"trapezoid"),createInvertedTrapezoidPathD=__name((Ra,qa,Ja,ed)=>[ ` M$ { Ra + ed / 6 } , $ { qa } ` , ` L$ { Ra + Ja - ed / 6 } , $ { qa } ` , ` L$ { Ra + Ja + 2 * ed / 6 } , $ { qa - ed } ` , ` L$ { Ra - 2 * ed / 6 } , $ { qa - ed } ` ,"Z
` );const ed=selectSvgElement(qa),td=ed.append("g");ed.attr("viewBox","0 0 2412 512"),configureSvgSize(ed,100,512,!0),td.append("path").attr("class","error-icon").attr("d","m411.313,123.313c6.25-6.25 6.25-16.375 0-22.625s-16.375-6.25-22.625,0l-32,32-9.375,9.375-20.688-20.688c-12.484-12.5-32.766-12.5-45.25,0l-16,16c-1.261,1.261-2.304,2.648-3.31,4.051-21.739-8.561-45.324-13.426-70.065-13.426-105.867,0-192,86.133-192,192s86.133,192 192,192 192-86.133 192-192c0-24.741-4.864-48.327-13.426-70.065 1.402-1.007 2.79-2.049 4.051-3.31l16-16c12.5-12.492 12.5-32.758 0-45.25l-20.688-20.688 9.375-9.375 32.001-31.999zm-219.313,100.687c-52.938,0-96,43.063-96,96 0,8.836-7.164,16-16,16s-16-7.164-16-16c0-70.578 57.422-128 128-128 8.836,0 16,7.164 16,16s-7.164,16-16,16z"),td.append("path").attr("class","error-icon").attr("d","m459.02,148.98c-6.25-6.25-16.375-6.25-22.625,0s-6.25,16.375 0,22.625l16,16c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688 6.25-6.25 6.25-16.375 0-22.625l-16.001-16z"),td.append("path").attr("class","error-icon").attr("d","m340.395,75.605c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688 6.25-6.25 6.25-16.375 0-22.625l-16-16c-6.25-6.25-16.375-6.25-22.625,0s-6.25,16.375 0,22.625l15.999,16z"),td.append("path").attr("class","error-icon").attr("d","m400,64c8.844,0 16-7.164 16-16v-32c0-8.836-7.156-16-16-16-8.844,0-16,7.164-16,16v32c0,8.836 7.156,16 16,16z"),td.append("path").attr("class","error-icon").attr("d","m496,96.586h-32c-8.844,0-16,7.164-16,16 0,8.836 7.156,16 16,16h32c8.844,0 16-7.164 16-16 0-8.836-7.156-16-16-16z"),td.append("path").attr("class","error-icon").attr("d","m436.98,75.605c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688l32-32c6.25-6.25 6.25-16.375 0-22.625s-16.375-6.25-22.625,0l-32,32c-6.251,6.25-6.251,16.375-0.001,22.625z"),td.append("text").attr("class","error-text").attr("x",1440).attr("y",250).attr("font-size","150px").style("text-anchor","middle").text("Syntax error in text"),td.append("text").attr("class","error-text").attr("x",1250).attr("y",400).attr("font-size","100px").style("text-anchor","middle").text( ` mermaid version $ { Ja } ` )},"draw"),renderer={draw},errorRenderer_default=renderer,diagram={db:{},renderer,parser:{parse:__name(()=>{},"parse")}},errorDiagram_default=diagram,id18="flowchart-elk",detector18=__name((Ra,qa={})=>{var Ja;return/^ \s *flowchart-elk/.test(Ra)||/^ \s *flowchart|graph/.test(Ra)&&((Ja=qa==null?void 0:qa.flowchart)==null?void 0:Ja.defaultRenderer)==="elk"?(qa.layout="elk",!0):!1},"detector"),loader18=__name(async()=>{const{diagram:Ra}=await __vitePreload(async()=>{const{diagram:qa}=await import("./flowDiagram-44NOAMKU-D41kA-5y.js");return{diagram:qa}},__vite__mapDeps([8,9,10,11]));return{id:id18,diagram:Ra}},"loader"),plugin16={id:id18,detector:detector18,loader:loader18},detector_default=plugin16,id19="timeline",detector19=__name(Ra=>/^ \s *timeline/.test(Ra),"detector"),loader19=__name(async()=>{const{diagram:Ra}=await __vitePreload(async()=>{const{diagram:qa}=await import("./timeline-definition-KYQAIZUX-jU0RJtT_.js");return{diagram:qa}},__vite__mapDeps([36,22]));return{id:id19,diagram:Ra}},"loader"),plugin17={id:id19,detector:detector19,loader:loader19},detector_default2=plugin17,id20="mindmap",detector20=__name(Ra=>/^ \s *mindmap/.test(Ra),"detector"),loader20=__name(async()=>{const{diagram:Ra}=await __vitePreload(async()=>{const{diagram:qa}=await import("./mindmap-definition-26FWEE7H-LcVQPGrF.js");return{diagram:qa}},__vite__mapDeps([37,38]));return{id:id20,diagram:Ra}},"loader"),plugin18={id:id20,detector:detector20,loader:loader20},detector_default3=plugin18,id21="sankey",detector21=__name(Ra=>/^ \s *sankey-beta/.test(Ra),"detector"),loader21=__name(async()=>{const{diagram:Ra}=await __vitePreload(async()=>{const{diagram:qa}=await import("./sankeyDiagram-KMMQDL5K-32NcbkUq.js");return{diagram:qa}},__vite__mapDeps([39,23,19]));return{id:id21,diagram:Ra}},"loader"),plugin19={id:id21,detector:detector21,loader:loader21},sankeyDetector_default=plugin19,id22="packet",detector22=__name(Ra=>/^ \s *packet-beta/.test(Ra),"detec
2024-09-07 10:27:05 +08:00
` ;try{getDiagram(td)}catch{const _d=getDiagramLoader(td);if(!_d)throw new UnknownDiagramError( ` Diagram $ { td } not found . ` );const{id:yd,diagram:gd}=await _d();registerDiagram(yd,gd)}const{db:rd,parser:sd,renderer:od,init:ld}=getDiagram(td);return sd.parser&&(sd.parser.yy=rd),(cd=rd.clear)==null||cd.call(rd),ld==null||ld(ed),Ja.title&&((ud=rd.setDiagramTitle)==null||ud.call(rd,Ja.title)),await sd.parse(qa),new Cv(td,qa,rd,sd,od)}async render(qa,Ja){await this.renderer.draw(this.text,qa,Ja,this)}getParser(){return this.parser}getType(){return this.type}},__name(Cv,"Diagram"),Cv),interactionFunctions=[],attachFunctions=__name(()=>{interactionFunctions.forEach(Ra=>{Ra()}),interactionFunctions=[]},"attachFunctions"),cleanupComments=__name(Ra=>Ra.replace(/^ \s *%%(?!{)[^ \n ]+ \n ?/gm,"").trimStart(),"cleanupComments");function isNothing(Ra){return typeof Ra>"u"||Ra===null}__name(isNothing,"isNothing");function isObject $ 2(Ra){return typeof Ra=="object"&&Ra!==null}__name(isObject $ 2,"isObject");function toArray $ 2(Ra){return Array.isArray(Ra)?Ra:isNothing(Ra)?[]:[Ra]}__name(toArray $ 2,"toArray");function extend $ 1(Ra,qa){var Ja,ed,td,rd;if(qa)for(rd=Object.keys(qa),Ja=0,ed=rd.length;Ja<ed;Ja+=1)td=rd[Ja],Ra[td]=qa[td];return Ra}__name(extend $ 1,"extend");function repeat(Ra,qa){var Ja="",ed;for(ed=0;ed<qa;ed+=1)Ja+=Ra;return Ja}__name(repeat,"repeat");function isNegativeZero(Ra){return Ra===0&&Number.NEGATIVE_INFINITY===1/Ra}__name(isNegativeZero,"isNegativeZero");var isNothing_1=isNothing,isObject_1=isObject $ 2,toArray_1=toArray $ 2,repeat_1=repeat,isNegativeZero_1=isNegativeZero,extend_1=extend $ 1,common={isNothing:isNothing_1,isObject:isObject_1,toArray:toArray_1,repeat:repeat_1,isNegativeZero:isNegativeZero_1,extend:extend_1};function formatError(Ra,qa){var Ja="",ed=Ra.reason||"(unknown reason)";return Ra.mark?(Ra.mark.name&&(Ja+='in "'+Ra.mark.name+'" '),Ja+="("+(Ra.mark.line+1)+":"+(Ra.mark.column+1)+")",!qa&&Ra.mark.snippet&&(Ja+= `
2024-09-03 08:22:14 +08:00
` +Ra.mark.snippet),ed+" "+Ja):ed}__name(formatError,"formatError");function YAMLException $ 1(Ra,qa){Error.call(this),this.name="YAMLException",this.reason=Ra,this.mark=qa,this.message=formatError(this,!1),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack||""}__name(YAMLException $ 1,"YAMLException $ 1");YAMLException $ 1.prototype=Object.create(Error.prototype);YAMLException $ 1.prototype.constructor=YAMLException $ 1;YAMLException $ 1.prototype.toString=__name(function(qa){return this.name+": "+formatError(this,qa)},"toString");var exception=YAMLException $ 1;function getLine(Ra,qa,Ja,ed,td){var rd="",sd="",od=Math.floor(td/2)-1;return ed-qa>od&&(rd=" ... ",qa=ed-od+rd.length),Ja-ed>od&&(sd=" ...",Ja=ed+od-sd.length),{str:rd+Ra.slice(qa,Ja).replace(/ \t /g,"→")+sd,pos:ed-qa+rd.length}}__name(getLine,"getLine");function padStart(Ra,qa){return common.repeat(" ",qa-Ra.length)+Ra}__name(padStart,"padStart");function makeSnippet(Ra,qa){if(qa=Object.create(qa||null),!Ra.buffer)return null;qa.maxLength||(qa.maxLength=79),typeof qa.indent!="number"&&(qa.indent=1),typeof qa.linesBefore!="number"&&(qa.linesBefore=3),typeof qa.linesAfter!="number"&&(qa.linesAfter=2);for(var Ja=/ \r ? \n | \r | \0 /g,ed=[0],td=[],rd,sd=-1;rd=Ja.exec(Ra.buffer);)td.push(rd.index),ed.push(rd.index+rd[0].length),Ra.position<=rd.index&&sd<0&&(sd=ed.length-2);sd<0&&(sd=ed.length-1);var od="",ld,cd,ud=Math.min(Ra.line+qa.linesAfter,td.length).toString().length,_d=qa.maxLength-(qa.indent+ud+3);for(ld=1;ld<=qa.linesBefore&&!(sd-ld<0);ld++)cd=getLine(Ra.buffer,ed[sd-ld],td[sd-ld],Ra.position-(ed[sd]-ed[sd-ld]),_d),od=common.repeat(" ",qa.indent)+padStart((Ra.line-ld+1).toString(),ud)+" | "+cd.str+ `
` +od;for(cd=getLine(Ra.buffer,ed[sd],td[sd],Ra.position,_d),od+=common.repeat(" ",qa.indent)+padStart((Ra.line+1).toString(),ud)+" | "+cd.str+ `
` ,od+=common.repeat("-",qa.indent+ud+3+cd.pos)+ ` ^
` ,ld=1;ld<=qa.linesAfter&&!(sd+ld>=td.length);ld++)cd=getLine(Ra.buffer,ed[sd+ld],td[sd+ld],Ra.position-(ed[sd]-ed[sd+ld]),_d),od+=common.repeat(" ",qa.indent)+padStart((Ra.line+ld+1).toString(),ud)+" | "+cd.str+ `
` ;return od.replace(/ \n $ /,"")}__name(makeSnippet,"makeSnippet");var snippet=makeSnippet,TYPE_CONSTRUCTOR_OPTIONS=["kind","multi","resolve","construct","instanceOf","predicate","represent","representName","defaultStyle","styleAliases"],YAML_NODE_KINDS=["scalar","sequence","mapping"];function compileStyleAliases(Ra){var qa={};return Ra!==null&&Object.keys(Ra).forEach(function(Ja){Ra[Ja].forEach(function(ed){qa[String(ed)]=Ja})}),qa}__name(compileStyleAliases,"compileStyleAliases");function Type $ 1(Ra,qa){if(qa=qa||{},Object.keys(qa).forEach(function(Ja){if(TYPE_CONSTRUCTOR_OPTIONS.indexOf(Ja)===-1)throw new exception('Unknown option "'+Ja+'" is met in definition of "'+Ra+'" YAML type.')}),this.options=qa,this.tag=Ra,this.kind=qa.kind||null,this.resolve=qa.resolve||function(){return!0},this.construct=qa.construct||function(Ja){return Ja},this.instanceOf=qa.instanceOf||null,this.predicate=qa.predicate||null,this.represent=qa.represent||null,this.representName=qa.representName||null,this.defaultStyle=qa.defaultStyle||null,this.multi=qa.multi||!1,this.styleAliases=compileStyleAliases(qa.styleAliases||null),YAML_NODE_KINDS.indexOf(this.kind)===-1)throw new exception('Unknown kind "'+this.kind+'" is specified for "'+Ra+'" YAML type.')}__name(Type $ 1,"Type $ 1");var type $ 1=Type $ 1;function compileList(Ra,qa){var Ja=[];return Ra[qa].forEach(function(ed){var td=Ja.length;Ja.forEach(function(rd,sd){rd.tag===ed.tag&&rd.kind===ed.kind&&rd.multi===ed.multi&&(td=sd)}),Ja[td]=ed}),Ja}__name(compileList,"compileList");function compileMap(){var Ra={scalar:{},sequence:{},mapping:{},fallback:{},multi:{scalar:[],sequence:[],mapping:[],fallback:[]}},qa,Ja;function ed(td){td.multi?(Ra.multi[td.kind].push(td),Ra.multi.fallback.push(td)):Ra[td.kind][td.tag]=Ra.fallback[td.tag]=td}for(__name(ed,"collectType"),qa=0,Ja=arguments.length;qa<Ja;qa+=1)arguments[qa].forEach(ed);return Ra}__name(compileMap,"compileMap");function Schema $ 1(Ra){return this.extend(Ra)}__name(Schema $ 1,"Schema $ 1");Schema $ 1.prototype.extend=__name(function(qa){var Ja=[],ed=[];if(qa instanceof type $ 1)ed.push(qa);else if(Array.isArray(qa))ed=ed.concat(qa);else if(qa&&(Array.isArray(qa.implicit)||Array.isArray(qa.explicit)))qa.implicit&&(Ja=Ja.concat(qa.implicit)),qa.explicit&&(ed=ed.concat(qa.explicit));else throw new exception("Schema.extend argument should be a Type, [ Type ], or a schema definition ({ implicit: [...], explicit: [...] })");Ja.forEach(function(rd){if(!(rd instanceof type $ 1))throw new exception("Specified list of YAML types (or a single Type object) contains a non-Type object.");if(rd.loadKind&&rd.loadKind!=="scalar")throw new exception("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.");if(rd.multi)throw new exception("There is a multi type in the implicit list of a schema. Multi tags can only be listed as explicit.")}),ed.forEach(function(rd){if(!(rd instanceof type $ 1))throw new exception("Specified list of YAML types (or a single Type object) contains a non-Type object.")});var td=Object.create(Schema $ 1.prototype);return td.implicit=(this.implicit||[]).concat(Ja),td.explicit=(this.explicit||[]).concat(ed),td.compiledImplicit=compileList(td,"implicit"),td.compiledExplicit=compileList(td,"explicit"),td.compiledTypeMap=compileMap(td.compiledImplicit,td.compiledExplicit),td},"extend");var schema=Schema $ 1,str=new type $ 1("tag:yaml.org,2002:str",{kind:"scalar",construct:__name(function(Ra){return Ra!==null?Ra:""},"construct")}),seq $ 1=new type $ 1("tag:yaml.org,2002:seq",{kind:"sequence",construct:__name(function(Ra){return Ra!==null?Ra:[]},"construct")}),map $ 4=new type $ 1("tag:yaml.org,2002:map",{kind:"mapping",construct:__name(function(Ra){return Ra!==null?Ra:{}},"construct")}),failsafe=new schema({explicit:[str,seq $ 1,map $ 4]});function resolveYamlNull(Ra){if(Ra===null)return!0;var qa=Ra.length;return qa===1&&Ra==="~"||qa===4&&(Ra==="null"||Ra==="Null"||Ra==="NULL")}__name(resolveYamlNull,"resolveYamlNull");function constructYamlNull(){return null}__name(constructYamlNull,"constructYamlNull");function isNull(Ra){
\ r ` ;function resolveYamlBinary(Ra){if(Ra===null)return!1;var qa,Ja,ed=0,td=Ra.length,rd=BASE64_MAP;for(Ja=0;Ja<td;Ja++)if(qa=rd.indexOf(Ra.charAt(Ja)),!(qa>64)){if(qa<0)return!1;ed+=6}return ed%8===0}__name(resolveYamlBinary,"resolveYamlBinary");function constructYamlBinary(Ra){var qa,Ja,ed=Ra.replace(/[ \r \n =]/g,""),td=ed.length,rd=BASE64_MAP,sd=0,od=[];for(qa=0;qa<td;qa++)qa%4===0&&qa&&(od.push(sd>>16&255),od.push(sd>>8&255),od.push(sd&255)),sd=sd<<6|rd.indexOf(ed.charAt(qa));return Ja=td%4*6,Ja===0?(od.push(sd>>16&255),od.push(sd>>8&255),od.push(sd&255)):Ja===18?(od.push(sd>>10&255),od.push(sd>>2&255)):Ja===12&&od.push(sd>>4&255),new Uint8Array(od)}__name(constructYamlBinary,"constructYamlBinary");function representYamlBinary(Ra){var qa="",Ja=0,ed,td,rd=Ra.length,sd=BASE64_MAP;for(ed=0;ed<rd;ed++)ed%3===0&&ed&&(qa+=sd[Ja>>18&63],qa+=sd[Ja>>12&63],qa+=sd[Ja>>6&63],qa+=sd[Ja&63]),Ja=(Ja<<8)+Ra[ed];return td=rd%3,td===0?(qa+=sd[Ja>>18&63],qa+=sd[Ja>>12&63],qa+=sd[Ja>>6&63],qa+=sd[Ja&63]):td===2?(qa+=sd[Ja>>10&63],qa+=sd[Ja>>4&63],qa+=sd[Ja<<2&63],qa+=sd[64]):td===1&&(qa+=sd[Ja>>2&63],qa+=sd[Ja<<4&63],qa+=sd[64],qa+=sd[64]),qa}__name(representYamlBinary,"representYamlBinary");function isBinary(Ra){return Object.prototype.toString.call(Ra)==="[object Uint8Array]"}__name(isBinary,"isBinary");var binary=new type $ 1("tag:yaml.org,2002:binary",{kind:"scalar",resolve:resolveYamlBinary,construct:constructYamlBinary,predicate:isBinary,represent:representYamlBinary}),_hasOwnProperty $ 3=Object.prototype.hasOwnProperty,_toString $ 2=Object.prototype.toString;function resolveYamlOmap(Ra){if(Ra===null)return!0;var qa=[],Ja,ed,td,rd,sd,od=Ra;for(Ja=0,ed=od.length;Ja<ed;Ja+=1){if(td=od[Ja],sd=!1,_toString $ 2.call(td)!=="[object Object]")return!1;for(rd in td)if(_hasOwnProperty $ 3.call(td,rd))if(!sd)sd=!0;else return!1;if(!sd)return!1;if(qa.indexOf(rd)===-1)qa.push(rd);else return!1}return!0}__name(resolveYamlOmap,"resolveYamlOmap");function constructYamlOmap(Ra){return Ra!==null?Ra:[]}__name(constructYamlOmap,"constructYamlOmap");var omap=new type $ 1("tag:yaml.org,2002:omap",{kind:"sequence",resolve:resolveYamlOmap,construct:constructYamlOmap}),_toString $ 1=Object.prototype.toString;function resolveYamlPairs(Ra){if(Ra===null)return!0;var qa,Ja,ed,td,rd,sd=Ra;for(rd=new Array(sd.length),qa=0,Ja=sd.length;qa<Ja;qa+=1){if(ed=sd[qa],_toString $ 1.call(ed)!=="[object Object]"||(td=Object.keys(ed),td.length!==1))return!1;rd[qa]=[td[0],ed[td[0]]]}return!0}__name(resolveYamlPairs,"resolveYamlPairs");function constructYamlPairs(Ra){if(Ra===null)return[];var qa,Ja,ed,td,rd,sd=Ra;for(rd=new Array(sd.length),qa=0,Ja=sd.length;qa<Ja;qa+=1)ed=sd[qa],td=Object.keys(ed),rd[qa]=[td[0],ed[td[0]]];return rd}__name(constructYamlPairs,"constructYamlPairs");var pairs=new type $ 1("tag:yaml.org,2002:pairs",{kind:"sequence",resolve:resolveYamlPairs,construct:constructYamlPairs}),_hasOwnProperty $ 2=Object.prototype.hasOwnProperty;function resolveYamlSet(Ra){if(Ra===null)return!0;var qa,Ja=Ra;for(qa in Ja)if(_hasOwnProperty $ 2.call(Ja,qa)&&Ja[qa]!==null)return!1;return!0}__name(resolveYamlSet,"resolveYamlSet");function constructYamlSet(Ra){return Ra!==null?Ra:{}}__name(constructYamlSet,"constructYamlSet");var set=new type $ 1("tag:yaml.org,2002:set",{kind:"mapping",resolve:resolveYamlSet,construct:constructYamlSet}),_default $ 1=core $ 1.extend({implicit:[timestamp,merge $ 1],explicit:[binary,omap,pairs,set]}),_hasOwnProperty $ 1=Object.prototype.hasOwnProperty,CONTEXT_FLOW_IN=1,CONTEXT_FLOW_OUT=2,CONTEXT_BLOCK_IN=3,CONTEXT_BLOCK_OUT=4,CHOMPING_CLIP=1,CHOMPING_STRIP=2,CHOMPING_KEEP=3,PATTERN_NON_PRINTABLE=/[ \x 00- \x 08 \x 0B \x 0C \x 0E- \x 1F \x 7F- \x 84 \x 86- \x 9F \u FFFE \u FFFF]|[ \u D800- \u DBFF](?![ \u DC00- \u DFFF])|(?:[^ \u D800- \u DBFF]|^)[ \u DC00- \u DFFF]/,PATTERN_NON_ASCII_LINE_BREAKS=/[ \x 85 \u 2028 \u 2029]/,PATTERN_FLOW_INDICATORS=/[, \[ \] \{ \} ]/,PATTERN_TAG_HANDLE=/^(?:!|!!|![a-z \- ]+!) $ /i,PATTERN_TAG_URI=/^(?:!|[^, \[ \] \{ \} ])(?:%[0-9a-f]{2}|[0-9a-z \- #; \/ \? :@&= \+ \$ ,_ \. !~ \* ' \( \) \[ \] ])* $ /i;function _class(Ra){return Object.prototype.toString.call(Ra)}__name(_class,"_class");function is_EOL(Ra){return Ra===10||R
` :Ra===118?" \v ":Ra===102?" \f ":Ra===114?" \r ":Ra===101?" \x 1B":Ra===32?" ":Ra===34?'"':Ra===47?"/":Ra===92?" \\ ":Ra===78?"
":Ra===95?" ":Ra===76?" \u 2028":Ra===80?" \u 2029":""}__name(simpleEscapeSequence,"simpleEscapeSequence");function charFromCodepoint(Ra){return Ra<=65535?String.fromCharCode(Ra):String.fromCharCode((Ra-65536>>10)+55296,(Ra-65536&1023)+56320)}__name(charFromCodepoint,"charFromCodepoint");var simpleEscapeCheck=new Array(256),simpleEscapeMap=new Array(256);for(i $ 1=0;i $ 1<256;i $ 1++)simpleEscapeCheck[i $ 1]=simpleEscapeSequence(i $ 1)?1:0,simpleEscapeMap[i $ 1]=simpleEscapeSequence(i $ 1);var i $ 1;function State $ 1(Ra,qa){this.input=Ra,this.filename=qa.filename||null,this.schema=qa.schema||_default $ 1,this.onWarning=qa.onWarning||null,this.legacy=qa.legacy||!1,this.json=qa.json||!1,this.listener=qa.listener||null,this.implicitTypes=this.schema.compiledImplicit,this.typeMap=this.schema.compiledTypeMap,this.length=Ra.length,this.position=0,this.line=0,this.lineStart=0,this.lineIndent=0,this.firstTabInLine=-1,this.documents=[]}__name(State $ 1,"State $ 1");function generateError(Ra,qa){var Ja={name:Ra.filename,buffer:Ra.input.slice(0,-1),position:Ra.position,line:Ra.line,column:Ra.position-Ra.lineStart};return Ja.snippet=snippet(Ja),new exception(qa,Ja)}__name(generateError,"generateError");function throwError(Ra,qa){throw generateError(Ra,qa)}__name(throwError,"throwError");function throwWarning(Ra,qa){Ra.onWarning&&Ra.onWarning.call(null,generateError(Ra,qa))}__name(throwWarning,"throwWarning");var directiveHandlers={YAML:__name(function(qa,Ja,ed){var td,rd,sd;qa.version!==null&&throwError(qa,"duplication of %YAML directive"),ed.length!==1&&throwError(qa,"YAML directive accepts exactly one argument"),td=/^([0-9]+) \. ([0-9]+) $ /.exec(ed[0]),td===null&&throwError(qa,"ill-formed argument of the YAML directive"),rd=parseInt(td[1],10),sd=parseInt(td[2],10),rd!==1&&throwError(qa,"unacceptable YAML version of the document"),qa.version=ed[0],qa.checkLineBreaks=sd<2,sd!==1&&sd!==2&&throwWarning(qa,"unsupported YAML version of the document")},"handleYamlDirective"),TAG:__name(function(qa,Ja,ed){var td,rd;ed.length!==2&&throwError(qa,"TAG directive accepts exactly two arguments"),td=ed[0],rd=ed[1],PATTERN_TAG_HANDLE.test(td)||throwError(qa,"ill-formed tag handle (first argument) of the TAG directive"),_hasOwnProperty $ 1.call(qa.tagMap,td)&&throwError(qa,'there is a previously declared suffix for "'+td+'" tag handle'),PATTERN_TAG_URI.test(rd)||throwError(qa,"ill-formed tag prefix (second argument) of the TAG directive");try{rd=decodeURIComponent(rd)}catch{throwError(qa,"tag prefix is malformed: "+rd)}qa.tagMap[td]=rd},"handleTagDirective")};function captureSegment(Ra,qa,Ja,ed){var td,rd,sd,od;if(qa<Ja){if(od=Ra.input.slice(qa,Ja),ed)for(td=0,rd=od.length;td<rd;td+=1)sd=od.charCodeAt(td),sd===9||32<=sd&&sd<=1114111||throwError(Ra,"expected valid JSON character");else PATTERN_NON_PRINTABLE.test(od)&&throwError(Ra,"the stream contains non-printable characters");Ra.result+=od}}__name(captureSegment,"captureSegment");function mergeMappings(Ra,qa,Ja,ed){var td,rd,sd,od;for(common.isObject(Ja)||throwError(Ra,"cannot merge mappings; the provided source object is unacceptable"),td=Object.keys(Ja),sd=0,od=td.length;sd<od;sd+=1)rd=td[sd],_hasOwnProperty $ 1.call(qa,rd)||(qa[rd]=Ja[rd],ed[rd]=!0)}__name(mergeMappings,"mergeMappings");function storeMappingPair(Ra,qa,Ja,ed,td,rd,sd,od,ld){var cd,ud;if(Array.isArray(td))for(td=Array.prototype.slice.call(td),cd=0,ud=td.length;cd<ud;cd+=1)Array.isArray(td[cd])&&throwError(Ra,"nested arrays are not supported inside keys"),typeof td=="object"&&_class(td[cd])==="[object Object]"&&(td[cd]="[object Object]");if(typeof td=="object"&&_class(td)==="[object Object]"&&(td="[object Object]"),td=String(td),qa===null&&(qa={}),ed==="tag:yaml.org,2002:merge")if(Array.isArray(rd))for(cd=0,ud=rd.length;cd<ud;cd+=1)mergeMappings(Ra,qa,rd[cd],Ja);else mergeMappings(Ra,qa,rd,Ja);else!Ra.json&&!_hasOwnProperty $ 1.call(Ja,td)&&_hasOwnProperty $ 1.call(qa,td)&&(Ra.line=sd||Ra.line,Ra.lineStart=od||Ra.lineStart,Ra.position=ld||Ra.posit
2024-09-08 17:22:36 +08:00
` ,qa-1))}__name(writeFoldedLines,"writeFoldedLines");function readPlainScalar(Ra,qa,Ja){var ed,td,rd,sd,od,ld,cd,ud,_d=Ra.kind,yd=Ra.result,gd;if(gd=Ra.input.charCodeAt(Ra.position),is_WS_OR_EOL(gd)||is_FLOW_INDICATOR(gd)||gd===35||gd===38||gd===42||gd===33||gd===124||gd===62||gd===39||gd===34||gd===37||gd===64||gd===96||(gd===63||gd===45)&&(td=Ra.input.charCodeAt(Ra.position+1),is_WS_OR_EOL(td)||Ja&&is_FLOW_INDICATOR(td)))return!1;for(Ra.kind="scalar",Ra.result="",rd=sd=Ra.position,od=!1;gd!==0;){if(gd===58){if(td=Ra.input.charCodeAt(Ra.position+1),is_WS_OR_EOL(td)||Ja&&is_FLOW_INDICATOR(td))break}else if(gd===35){if(ed=Ra.input.charCodeAt(Ra.position-1),is_WS_OR_EOL(ed))break}else{if(Ra.position===Ra.lineStart&&testDocumentSeparator(Ra)||Ja&&is_FLOW_INDICATOR(gd))break;if(is_EOL(gd))if(ld=Ra.line,cd=Ra.lineStart,ud=Ra.lineIndent,skipSeparationSpace(Ra,!1,-1),Ra.lineIndent>=qa){od=!0,gd=Ra.input.charCodeAt(Ra.position);continue}else{Ra.position=sd,Ra.line=ld,Ra.lineStart=cd,Ra.lineIndent=ud;break}}od&&(captureSegment(Ra,rd,sd,!1),writeFoldedLines(Ra,Ra.line-ld),rd=sd=Ra.position,od=!1),is_WHITE_SPACE(gd)||(sd=Ra.position+1),gd=Ra.input.charCodeAt(++Ra.position)}return captureSegment(Ra,rd,sd,!1),Ra.result?!0:(Ra.kind=_d,Ra.result=yd,!1)}__name(readPlainScalar,"readPlainScalar");function readSingleQuotedScalar(Ra,qa){var Ja,ed,td;if(Ja=Ra.input.charCodeAt(Ra.position),Ja!==39)return!1;for(Ra.kind="scalar",Ra.result="",Ra.position++,ed=td=Ra.position;(Ja=Ra.input.charCodeAt(Ra.position))!==0;)if(Ja===39)if(captureSegment(Ra,ed,Ra.position,!0),Ja=Ra.input.charCodeAt(++Ra.position),Ja===39)ed=Ra.position,Ra.position++,td=Ra.position;else return!0;else is_EOL(Ja)?(captureSegment(Ra,ed,td,!0),writeFoldedLines(Ra,skipSeparationSpace(Ra,!1,qa)),ed=td=Ra.position):Ra.position===Ra.lineStart&&testDocumentSeparator(Ra)?throwError(Ra,"unexpected end of the document within a single quoted scalar"):(Ra.position++,td=Ra.position);throwError(Ra,"unexpected end of the stream within a single quoted scalar")}__name(readSingleQuotedScalar,"readSingleQuotedScalar");function readDoubleQuotedScalar(Ra,qa){var Ja,ed,td,rd,sd,od;if(od=Ra.input.charCodeAt(Ra.position),od!==34)return!1;for(Ra.kind="scalar",Ra.result="",Ra.position++,Ja=ed=Ra.position;(od=Ra.input.charCodeAt(Ra.position))!==0;){if(od===34)return captureSegment(Ra,Ja,Ra.position,!0),Ra.position++,!0;if(od===92){if(captureSegment(Ra,Ja,Ra.position,!0),od=Ra.input.charCodeAt(++Ra.position),is_EOL(od))skipSeparationSpace(Ra,!1,qa);else if(od<256&&simpleEscapeCheck[od])Ra.result+=simpleEscapeMap[od],Ra.position++;else if((sd=escapedHexLen(od))>0){for(td=sd,rd=0;td>0;td--)od=Ra.input.charCodeAt(++Ra.position),(sd=fromHexCode(od))>=0?rd=(rd<<4)+sd:throwError(Ra,"expected hexadecimal character");Ra.result+=charFromCodepoint(rd),Ra.position++}else throwError(Ra,"unknown escape sequence");Ja=ed=Ra.position}else is_EOL(od)?(captureSegment(Ra,Ja,ed,!0),writeFoldedLines(Ra,skipSeparationSpace(Ra,!1,qa)),Ja=ed=Ra.position):Ra.position===Ra.lineStart&&testDocumentSeparator(Ra)?throwError(Ra,"unexpected end of the document within a double quoted scalar"):(Ra.position++,ed=Ra.position)}throwError(Ra,"unexpected end of the stream within a double quoted scalar")}__name(readDoubleQuotedScalar,"readDoubleQuotedScalar");function readFlowCollection(Ra,qa){var Ja=!0,ed,td,rd,sd=Ra.tag,od,ld=Ra.anchor,cd,ud,_d,yd,gd,Ed=Object.create(null),Td,Od,Rd,Nd;if(Nd=Ra.input.charCodeAt(Ra.position),Nd===91)ud=93,gd=!1,od=[];else if(Nd===123)ud=125,gd=!0,od={};else return!1;for(Ra.anchor!==null&&(Ra.anchorMap[Ra.anchor]=od),Nd=Ra.input.charCodeAt(++Ra.position);Nd!==0;){if(skipSeparationSpace(Ra,!0,qa),Nd=Ra.input.charCodeAt(Ra.position),Nd===ud)return Ra.position++,Ra.tag=sd,Ra.anchor=ld,Ra.kind=gd?"mapping":"sequence",Ra.result=od,!0;Ja?Nd===44&&throwError(Ra,"expected the node content, but found ','"):throwError(Ra,"missed comma between flow collection entries"),Od=Td=Rd=null,_d=yd=!1,Nd===63&&(cd=Ra.input.charCodeAt(Ra.position+1),is_WS_OR_EOL(cd)&&(_d=yd=!0,Ra.position++,skipSeparationSpace(Ra,!0,qa))),ed=Ra.l
2024-08-30 15:19:18 +08:00
` ,rd?1+ld:ld):td===CHOMPING_CLIP&&rd&&(Ra.result+= `
2024-08-31 11:28:56 +08:00
` );break}for(ed?is_WHITE_SPACE(_d)?(cd=!0,Ra.result+=common.repeat( `
2024-08-30 15:19:18 +08:00
` ,rd?1+ld:ld)):cd?(cd=!1,Ra.result+=common.repeat( `
` ,ld+1)):ld===0?rd&&(Ra.result+=" "):Ra.result+=common.repeat( `
` ,ld):Ra.result+=common.repeat( `
2024-09-08 17:22:36 +08:00
` ,rd?1+ld:ld),rd=!0,sd=!0,ld=0,Ja=Ra.position;!is_EOL(_d)&&_d!==0;)_d=Ra.input.charCodeAt(++Ra.position);captureSegment(Ra,Ja,Ra.position,!1)}return!0}__name(readBlockScalar,"readBlockScalar");function readBlockSequence(Ra,qa){var Ja,ed=Ra.tag,td=Ra.anchor,rd=[],sd,od=!1,ld;if(Ra.firstTabInLine!==-1)return!1;for(Ra.anchor!==null&&(Ra.anchorMap[Ra.anchor]=rd),ld=Ra.input.charCodeAt(Ra.position);ld!==0&&(Ra.firstTabInLine!==-1&&(Ra.position=Ra.firstTabInLine,throwError(Ra,"tab characters must not be used in indentation")),!(ld!==45||(sd=Ra.input.charCodeAt(Ra.position+1),!is_WS_OR_EOL(sd))));){if(od=!0,Ra.position++,skipSeparationSpace(Ra,!0,-1)&&Ra.lineIndent<=qa){rd.push(null),ld=Ra.input.charCodeAt(Ra.position);continue}if(Ja=Ra.line,composeNode(Ra,qa,CONTEXT_BLOCK_IN,!1,!0),rd.push(Ra.result),skipSeparationSpace(Ra,!0,-1),ld=Ra.input.charCodeAt(Ra.position),(Ra.line===Ja||Ra.lineIndent>qa)&&ld!==0)throwError(Ra,"bad indentation of a sequence entry");else if(Ra.lineIndent<qa)break}return od?(Ra.tag=ed,Ra.anchor=td,Ra.kind="sequence",Ra.result=rd,!0):!1}__name(readBlockSequence,"readBlockSequence");function readBlockMapping(Ra,qa,Ja){var ed,td,rd,sd,od,ld,cd=Ra.tag,ud=Ra.anchor,_d={},yd=Object.create(null),gd=null,Ed=null,Td=null,Od=!1,Rd=!1,Nd;if(Ra.firstTabInLine!==-1)return!1;for(Ra.anchor!==null&&(Ra.anchorMap[Ra.anchor]=_d),Nd=Ra.input.charCodeAt(Ra.position);Nd!==0;){if(!Od&&Ra.firstTabInLine!==-1&&(Ra.position=Ra.firstTabInLine,throwError(Ra,"tab characters must not be used in indentation")),ed=Ra.input.charCodeAt(Ra.position+1),rd=Ra.line,(Nd===63||Nd===58)&&is_WS_OR_EOL(ed))Nd===63?(Od&&(storeMappingPair(Ra,_d,yd,gd,Ed,null,sd,od,ld),gd=Ed=Td=null),Rd=!0,Od=!0,td=!0):Od?(Od=!1,td=!0):throwError(Ra,"incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"),Ra.position+=1,Nd=ed;else{if(sd=Ra.line,od=Ra.lineStart,ld=Ra.position,!composeNode(Ra,Ja,CONTEXT_FLOW_OUT,!1,!0))break;if(Ra.line===rd){for(Nd=Ra.input.charCodeAt(Ra.position);is_WHITE_SPACE(Nd);)Nd=Ra.input.charCodeAt(++Ra.position);if(Nd===58)Nd=Ra.input.charCodeAt(++Ra.position),is_WS_OR_EOL(Nd)||throwError(Ra,"a whitespace character is expected after the key-value separator within a block mapping"),Od&&(storeMappingPair(Ra,_d,yd,gd,Ed,null,sd,od,ld),gd=Ed=Td=null),Rd=!0,Od=!1,td=!1,gd=Ra.tag,Ed=Ra.result;else if(Rd)throwError(Ra,"can not read an implicit mapping pair; a colon is missed");else return Ra.tag=cd,Ra.anchor=ud,!0}else if(Rd)throwError(Ra,"can not read a block mapping entry; a multiline key may not be an implicit key");else return Ra.tag=cd,Ra.anchor=ud,!0}if((Ra.line===rd||Ra.lineIndent>qa)&&(Od&&(sd=Ra.line,od=Ra.lineStart,ld=Ra.position),composeNode(Ra,qa,CONTEXT_BLOCK_OUT,!0,td)&&(Od?Ed=Ra.result:Td=Ra.result),Od||(storeMappingPair(Ra,_d,yd,gd,Ed,Td,sd,od,ld),gd=Ed=Td=null),skipSeparationSpace(Ra,!0,-1),Nd=Ra.input.charCodeAt(Ra.position)),(Ra.line===rd||Ra.lineIndent>qa)&&Nd!==0)throwError(Ra,"bad indentation of a mapping entry");else if(Ra.lineIndent<qa)break}return Od&&storeMappingPair(Ra,_d,yd,gd,Ed,null,sd,od,ld),Rd&&(Ra.tag=cd,Ra.anchor=ud,Ra.kind="mapping",Ra.result=_d),Rd}__name(readBlockMapping,"readBlockMapping");function readTagProperty(Ra){var qa,Ja=!1,ed=!1,td,rd,sd;if(sd=Ra.input.charCodeAt(Ra.position),sd!==33)return!1;if(Ra.tag!==null&&throwError(Ra,"duplication of a tag property"),sd=Ra.input.charCodeAt(++Ra.position),sd===60?(Ja=!0,sd=Ra.input.charCodeAt(++Ra.position)):sd===33?(ed=!0,td="!!",sd=Ra.input.charCodeAt(++Ra.position)):td="!",qa=Ra.position,Ja){do sd=Ra.input.charCodeAt(++Ra.position);while(sd!==0&&sd!==62);Ra.position<Ra.length?(rd=Ra.input.slice(qa,Ra.position),sd=Ra.input.charCodeAt(++Ra.position)):throwError(Ra,"unexpected end of the stream within a verbatim tag")}else{for(;sd!==0&&!is_WS_OR_EOL(sd);)sd===33&&(ed?throwError(Ra,"tag suffix cannot contain exclamation marks"):(td=Ra.input.slice(qa-1,Ra.position+1),PATTERN_TAG_HANDLE.test(td)||throwError(Ra,"named tag handle cannot contain such characters"),ed=!0,qa=Ra.position+1)),sd=Ra.input.charCodeAt(++Ra.position);
2024-09-04 13:02:35 +08:00
` ),Ra.charCodeAt(0)===65279&&(Ra=Ra.slice(1)));var Ja=new State $ 1(Ra,qa),ed=Ra.indexOf(" \0 ");for(ed!==-1&&(Ja.position=ed,throwError(Ja,"null byte is not allowed in input")),Ja.input+=" \0 ";Ja.input.charCodeAt(Ja.position)===32;)Ja.lineIndent+=1,Ja.position+=1;for(;Ja.position<Ja.length-1;)readDocument(Ja);return Ja.documents}__name(loadDocuments,"loadDocuments");function loadAll $ 1(Ra,qa,Ja){qa!==null&&typeof qa=="object"&&typeof Ja>"u"&&(Ja=qa,qa=null);var ed=loadDocuments(Ra,Ja);if(typeof qa!="function")return ed;for(var td=0,rd=ed.length;td<rd;td+=1)qa(ed[td])}__name(loadAll $ 1,"loadAll $ 1");function load $ 1(Ra,qa){var Ja=loadDocuments(Ra,qa);if(Ja.length!==0){if(Ja.length===1)return Ja[0];throw new exception("expected a single document in the stream, but found more")}}__name(load $ 1,"load $ 1");var loadAll_1=loadAll $ 1,load_1=load $ 1,loader25={loadAll:loadAll_1,load:load_1},_toString=Object.prototype.toString,_hasOwnProperty=Object.prototype.hasOwnProperty,CHAR_BOM=65279,CHAR_TAB=9,CHAR_LINE_FEED=10,CHAR_CARRIAGE_RETURN=13,CHAR_SPACE=32,CHAR_EXCLAMATION=33,CHAR_DOUBLE_QUOTE=34,CHAR_SHARP=35,CHAR_PERCENT=37,CHAR_AMPERSAND=38,CHAR_SINGLE_QUOTE=39,CHAR_ASTERISK=42,CHAR_COMMA=44,CHAR_MINUS=45,CHAR_COLON=58,CHAR_EQUALS=61,CHAR_GREATER_THAN=62,CHAR_QUESTION=63,CHAR_COMMERCIAL_AT=64,CHAR_LEFT_SQUARE_BRACKET=91,CHAR_RIGHT_SQUARE_BRACKET=93,CHAR_GRAVE_ACCENT=96,CHAR_LEFT_CURLY_BRACKET=123,CHAR_VERTICAL_LINE=124,CHAR_RIGHT_CURLY_BRACKET=125,ESCAPE_SEQUENCES={};ESCAPE_SEQUENCES[0]=" \\ 0";ESCAPE_SEQUENCES[7]=" \\ a";ESCAPE_SEQUENCES[8]=" \\ b";ESCAPE_SEQUENCES[9]=" \\ t";ESCAPE_SEQUENCES[10]=" \\ n";ESCAPE_SEQUENCES[11]=" \\ v";ESCAPE_SEQUENCES[12]=" \\ f";ESCAPE_SEQUENCES[13]=" \\ r";ESCAPE_SEQUENCES[27]=" \\ e";ESCAPE_SEQUENCES[34]=' \\ "';ESCAPE_SEQUENCES[92]=" \\ \\ ";ESCAPE_SEQUENCES[133]=" \\ N";ESCAPE_SEQUENCES[160]=" \\ _";ESCAPE_SEQUENCES[8232]=" \\ L";ESCAPE_SEQUENCES[8233]=" \\ P";var DEPRECATED_BOOLEANS_SYNTAX=["y","Y","yes","Yes","YES","on","On","ON","n","N","no","No","NO","off","Off","OFF"],DEPRECATED_BASE60_SYNTAX=/^[-+]?[0-9_]+(?::[0-9_]+)+(?: \. [0-9_]*)? $ /;function compileStyleMap(Ra,qa){var Ja,ed,td,rd,sd,od,ld;if(qa===null)return{};for(Ja={},ed=Object.keys(qa),td=0,rd=ed.length;td<rd;td+=1)sd=ed[td],od=String(qa[sd]),sd.slice(0,2)==="!!"&&(sd="tag:yaml.org,2002:"+sd.slice(2)),ld=Ra.compiledTypeMap.fallback[sd],ld&&_hasOwnProperty.call(ld.styleAliases,od)&&(od=ld.styleAliases[od]),Ja[sd]=od;return Ja}__name(compileStyleMap,"compileStyleMap");function encodeHex(Ra){var qa,Ja,ed;if(qa=Ra.toString(16).toUpperCase(),Ra<=255)Ja="x",ed=2;else if(Ra<=65535)Ja="u",ed=4;else if(Ra<=4294967295)Ja="U",ed=8;else throw new exception("code point within a string may not be greater than 0xFFFFFFFF");return" \\ "+Ja+common.repeat("0",ed-qa.length)+qa}__name(encodeHex,"encodeHex");var QUOTING_TYPE_SINGLE=1,QUOTING_TYPE_DOUBLE=2;function State(Ra){this.schema=Ra.schema||_default $ 1,this.indent=Math.max(1,Ra.indent||2),this.noArrayIndent=Ra.noArrayIndent||!1,this.skipInvalid=Ra.skipInvalid||!1,this.flowLevel=common.isNothing(Ra.flowLevel)?-1:Ra.flowLevel,this.styleMap=compileStyleMap(this.schema,Ra.styles||null),this.sortKeys=Ra.sortKeys||!1,this.lineWidth=Ra.lineWidth||80,this.noRefs=Ra.noRefs||!1,this.noCompatMode=Ra.noCompatMode||!1,this.condenseFlow=Ra.condenseFlow||!1,this.quotingType=Ra.quotingType==='"'?QUOTING_TYPE_DOUBLE:QUOTING_TYPE_SINGLE,this.forceQuotes=Ra.forceQuotes||!1,this.replacer=typeof Ra.replacer=="function"?Ra.replacer:null,this.implicitTypes=this.schema.compiledImplicit,this.explicitTypes=this.schema.compiledExplicit,this.tag=null,this.result="",this.duplicates=[],this.usedDuplicates=null}__name(State,"State");function indentString(Ra,qa){for(var Ja=common.repeat(" ",qa),ed=0,td=-1,rd="",sd,od=Ra.length;ed<od;)td=Ra.indexOf( `
2024-09-03 08:22:14 +08:00
` ,ed),td===-1?(sd=Ra.slice(ed),ed=od):(sd=Ra.slice(ed,td+1),ed=td+1),sd.length&&sd!== `
` &&(rd+=Ja),rd+=sd;return rd}__name(indentString,"indentString");function generateNextLine(Ra,qa){return `
` +common.repeat(" ",Ra.indent*qa)}__name(generateNextLine,"generateNextLine");function testImplicitResolving(Ra,qa){var Ja,ed,td;for(Ja=0,ed=Ra.implicitTypes.length;Ja<ed;Ja+=1)if(td=Ra.implicitTypes[Ja],td.resolve(qa))return!0;return!1}__name(testImplicitResolving,"testImplicitResolving");function isWhitespace $ 1(Ra){return Ra===CHAR_SPACE||Ra===CHAR_TAB}__name(isWhitespace $ 1,"isWhitespace");function isPrintable(Ra){return 32<=Ra&&Ra<=126||161<=Ra&&Ra<=55295&&Ra!==8232&&Ra!==8233||57344<=Ra&&Ra<=65533&&Ra!==CHAR_BOM||65536<=Ra&&Ra<=1114111}__name(isPrintable,"isPrintable");function isNsCharOrWhitespace(Ra){return isPrintable(Ra)&&Ra!==CHAR_BOM&&Ra!==CHAR_CARRIAGE_RETURN&&Ra!==CHAR_LINE_FEED}__name(isNsCharOrWhitespace,"isNsCharOrWhitespace");function isPlainSafe(Ra,qa,Ja){var ed=isNsCharOrWhitespace(Ra),td=ed&&!isWhitespace $ 1(Ra);return(Ja?ed:ed&&Ra!==CHAR_COMMA&&Ra!==CHAR_LEFT_SQUARE_BRACKET&&Ra!==CHAR_RIGHT_SQUARE_BRACKET&&Ra!==CHAR_LEFT_CURLY_BRACKET&&Ra!==CHAR_RIGHT_CURLY_BRACKET)&&Ra!==CHAR_SHARP&&!(qa===CHAR_COLON&&!td)||isNsCharOrWhitespace(qa)&&!isWhitespace $ 1(qa)&&Ra===CHAR_SHARP||qa===CHAR_COLON&&td}__name(isPlainSafe,"isPlainSafe");function isPlainSafeFirst(Ra){return isPrintable(Ra)&&Ra!==CHAR_BOM&&!isWhitespace $ 1(Ra)&&Ra!==CHAR_MINUS&&Ra!==CHAR_QUESTION&&Ra!==CHAR_COLON&&Ra!==CHAR_COMMA&&Ra!==CHAR_LEFT_SQUARE_BRACKET&&Ra!==CHAR_RIGHT_SQUARE_BRACKET&&Ra!==CHAR_LEFT_CURLY_BRACKET&&Ra!==CHAR_RIGHT_CURLY_BRACKET&&Ra!==CHAR_SHARP&&Ra!==CHAR_AMPERSAND&&Ra!==CHAR_ASTERISK&&Ra!==CHAR_EXCLAMATION&&Ra!==CHAR_VERTICAL_LINE&&Ra!==CHAR_EQUALS&&Ra!==CHAR_GREATER_THAN&&Ra!==CHAR_SINGLE_QUOTE&&Ra!==CHAR_DOUBLE_QUOTE&&Ra!==CHAR_PERCENT&&Ra!==CHAR_COMMERCIAL_AT&&Ra!==CHAR_GRAVE_ACCENT}__name(isPlainSafeFirst,"isPlainSafeFirst");function isPlainSafeLast(Ra){return!isWhitespace $ 1(Ra)&&Ra!==CHAR_COLON}__name(isPlainSafeLast,"isPlainSafeLast");function codePointAt(Ra,qa){var Ja=Ra.charCodeAt(qa),ed;return Ja>=55296&&Ja<=56319&&qa+1<Ra.length&&(ed=Ra.charCodeAt(qa+1),ed>=56320&&ed<=57343)?(Ja-55296)*1024+ed-56320+65536:Ja}__name(codePointAt,"codePointAt");function needIndentIndicator(Ra){var qa=/^ \n * /;return qa.test(Ra)}__name(needIndentIndicator,"needIndentIndicator");var STYLE_PLAIN=1,STYLE_SINGLE=2,STYLE_LITERAL=3,STYLE_FOLDED=4,STYLE_DOUBLE=5;function chooseScalarStyle(Ra,qa,Ja,ed,td,rd,sd,od){var ld,cd=0,ud=null,_d=!1,yd=!1,gd=ed!==-1,Ed=-1,Td=isPlainSafeFirst(codePointAt(Ra,0))&&isPlainSafeLast(codePointAt(Ra,Ra.length-1));if(qa||sd)for(ld=0;ld<Ra.length;cd>=65536?ld+=2:ld++){if(cd=codePointAt(Ra,ld),!isPrintable(cd))return STYLE_DOUBLE;Td=Td&&isPlainSafe(cd,ud,od),ud=cd}else{for(ld=0;ld<Ra.length;cd>=65536?ld+=2:ld++){if(cd=codePointAt(Ra,ld),cd===CHAR_LINE_FEED)_d=!0,gd&&(yd=yd||ld-Ed-1>ed&&Ra[Ed+1]!==" ",Ed=ld);else if(!isPrintable(cd))return STYLE_DOUBLE;Td=Td&&isPlainSafe(cd,ud,od),ud=cd}yd=yd||gd&&ld-Ed-1>ed&&Ra[Ed+1]!==" "}return!_d&&!yd?Td&&!sd&&!td(Ra)?STYLE_PLAIN:rd===QUOTING_TYPE_DOUBLE?STYLE_DOUBLE:STYLE_SINGLE:Ja>9&&needIndentIndicator(Ra)?STYLE_DOUBLE:sd?rd===QUOTING_TYPE_DOUBLE?STYLE_DOUBLE:STYLE_SINGLE:yd?STYLE_FOLDED:STYLE_LITERAL}__name(chooseScalarStyle,"chooseScalarStyle");function writeScalar(Ra,qa,Ja,ed,td){Ra.dump=function(){if(qa.length===0)return Ra.quotingType===QUOTING_TYPE_DOUBLE?'""':"''";if(!Ra.noCompatMode&&(DEPRECATED_BOOLEANS_SYNTAX.indexOf(qa)!==-1||DEPRECATED_BASE60_SYNTAX.test(qa)))return Ra.quotingType===QUOTING_TYPE_DOUBLE?'"'+qa+'"':"'"+qa+"'";var rd=Ra.indent*Math.max(1,Ja),sd=Ra.lineWidth===-1?-1:Math.max(Math.min(Ra.lineWidth,40),Ra.lineWidth-rd),od=ed||Ra.flowLevel>-1&&Ja>=Ra.flowLevel;function ld(cd){return testImplicitResolving(Ra,cd)}switch(__name(ld,"testAmbiguity"),chooseScalarStyle(qa,od,Ra.indent,sd,ld,Ra.quotingType,Ra.forceQuotes&&!ed,td)){case STYLE_PLAIN:return qa;case STYLE_SINGLE:return"'"+qa.replace(/'/g,"''")+"'";case STYLE_LITERAL:return"|"+blockHeader(qa,Ra.indent)+dropEndingNewline(indentString(qa,rd));case STYLE_FOLDED:return">"+blockHeader(qa,Ra.indent)+dropEndingNewline(indentString(foldString(qa,sd),rd));case STYLE_DOUBLE:return'"'+escapeString(qa)+'"';defaul
2024-08-30 15:19:18 +08:00
` ,td=ed&&(Ra[Ra.length-2]=== `
` ||Ra=== `
` ),rd=td?"+":ed?"":"-";return Ja+rd+ `
` }__name(blockHeader,"blockHeader");function dropEndingNewline(Ra){return Ra[Ra.length-1]=== `
` ?Ra.slice(0,-1):Ra}__name(dropEndingNewline,"dropEndingNewline");function foldString(Ra,qa){for(var Ja=/( \n +)([^ \n ]*)/g,ed=function(){var cd=Ra.indexOf( `
` );return cd=cd!==-1?cd:Ra.length,Ja.lastIndex=cd,foldLine(Ra.slice(0,cd),qa)}(),td=Ra[0]=== `
2024-09-03 08:22:14 +08:00
` ||Ra[0]===" ",rd,sd;sd=Ja.exec(Ra);){var od=sd[1],ld=sd[2];rd=ld[0]===" ",ed+=od+(!td&&!rd&&ld!==""? `
` :"")+foldLine(ld,qa),td=rd}return ed}__name(foldString,"foldString");function foldLine(Ra,qa){if(Ra===""||Ra[0]===" ")return Ra;for(var Ja=/ [^ ]/g,ed,td=0,rd,sd=0,od=0,ld="";ed=Ja.exec(Ra);)od=ed.index,od-td>qa&&(rd=sd>td?sd:od,ld+= `
` +Ra.slice(td,rd),td=rd+1),sd=od;return ld+= `
` ,Ra.length-td>qa&&sd>td?ld+=Ra.slice(td,sd)+ `
` +Ra.slice(sd+1):ld+=Ra.slice(td),ld.slice(1)}__name(foldLine,"foldLine");function escapeString(Ra){for(var qa="",Ja=0,ed,td=0;td<Ra.length;Ja>=65536?td+=2:td++)Ja=codePointAt(Ra,td),ed=ESCAPE_SEQUENCES[Ja],!ed&&isPrintable(Ja)?(qa+=Ra[td],Ja>=65536&&(qa+=Ra[td+1])):qa+=ed||encodeHex(Ja);return qa}__name(escapeString,"escapeString");function writeFlowSequence(Ra,qa,Ja){var ed="",td=Ra.tag,rd,sd,od;for(rd=0,sd=Ja.length;rd<sd;rd+=1)od=Ja[rd],Ra.replacer&&(od=Ra.replacer.call(Ja,String(rd),od)),(writeNode(Ra,qa,od,!1,!1)||typeof od>"u"&&writeNode(Ra,qa,null,!1,!1))&&(ed!==""&&(ed+=","+(Ra.condenseFlow?"":" ")),ed+=Ra.dump);Ra.tag=td,Ra.dump="["+ed+"]"}__name(writeFlowSequence,"writeFlowSequence");function writeBlockSequence(Ra,qa,Ja,ed){var td="",rd=Ra.tag,sd,od,ld;for(sd=0,od=Ja.length;sd<od;sd+=1)ld=Ja[sd],Ra.replacer&&(ld=Ra.replacer.call(Ja,String(sd),ld)),(writeNode(Ra,qa+1,ld,!0,!0,!1,!0)||typeof ld>"u"&&writeNode(Ra,qa+1,null,!0,!0,!1,!0))&&((!ed||td!=="")&&(td+=generateNextLine(Ra,qa)),Ra.dump&&CHAR_LINE_FEED===Ra.dump.charCodeAt(0)?td+="-":td+="- ",td+=Ra.dump);Ra.tag=rd,Ra.dump=td||"[]"}__name(writeBlockSequence,"writeBlockSequence");function writeFlowMapping(Ra,qa,Ja){var ed="",td=Ra.tag,rd=Object.keys(Ja),sd,od,ld,cd,ud;for(sd=0,od=rd.length;sd<od;sd+=1)ud="",ed!==""&&(ud+=", "),Ra.condenseFlow&&(ud+='"'),ld=rd[sd],cd=Ja[ld],Ra.replacer&&(cd=Ra.replacer.call(Ja,ld,cd)),writeNode(Ra,qa,ld,!1,!1)&&(Ra.dump.length>1024&&(ud+="? "),ud+=Ra.dump+(Ra.condenseFlow?'"':"")+":"+(Ra.condenseFlow?"":" "),writeNode(Ra,qa,cd,!1,!1)&&(ud+=Ra.dump,ed+=ud));Ra.tag=td,Ra.dump="{"+ed+"}"}__name(writeFlowMapping,"writeFlowMapping");function writeBlockMapping(Ra,qa,Ja,ed){var td="",rd=Ra.tag,sd=Object.keys(Ja),od,ld,cd,ud,_d,yd;if(Ra.sortKeys===!0)sd.sort();else if(typeof Ra.sortKeys=="function")sd.sort(Ra.sortKeys);else if(Ra.sortKeys)throw new exception("sortKeys must be a boolean or a function");for(od=0,ld=sd.length;od<ld;od+=1)yd="",(!ed||td!=="")&&(yd+=generateNextLine(Ra,qa)),cd=sd[od],ud=Ja[cd],Ra.replacer&&(ud=Ra.replacer.call(Ja,cd,ud)),writeNode(Ra,qa+1,cd,!0,!0,!0)&&(_d=Ra.tag!==null&&Ra.tag!=="?"||Ra.dump&&Ra.dump.length>1024,_d&&(Ra.dump&&CHAR_LINE_FEED===Ra.dump.charCodeAt(0)?yd+="?":yd+="? "),yd+=Ra.dump,_d&&(yd+=generateNextLine(Ra,qa)),writeNode(Ra,qa+1,ud,!0,_d)&&(Ra.dump&&CHAR_LINE_FEED===Ra.dump.charCodeAt(0)?yd+=":":yd+=": ",yd+=Ra.dump,td+=yd));Ra.tag=rd,Ra.dump=td||"{}"}__name(writeBlockMapping,"writeBlockMapping");function detectType2(Ra,qa,Ja){var ed,td,rd,sd,od,ld;for(td=Ja?Ra.explicitTypes:Ra.implicitTypes,rd=0,sd=td.length;rd<sd;rd+=1)if(od=td[rd],(od.instanceOf||od.predicate)&&(!od.instanceOf||typeof qa=="object"&&qa instanceof od.instanceOf)&&(!od.predicate||od.predicate(qa))){if(Ja?od.multi&&od.representName?Ra.tag=od.representName(qa):Ra.tag=od.tag:Ra.tag="?",od.represent){if(ld=Ra.styleMap[od.tag]||od.defaultStyle,_toString.call(od.represent)==="[object Function]")ed=od.represent(qa,ld);else if(_hasOwnProperty.call(od.represent,ld))ed=od.represent[ld](qa,ld);else throw new exception("!<"+od.tag+'> tag resolver accepts not "'+ld+'" style');Ra.dump=ed}return!0}return!1}__name(detectType2,"detectType");function writeNode(Ra,qa,Ja,ed,td,rd,sd){Ra.tag=null,Ra.dump=Ja,detectType2(Ra,Ja,!1)||detectType2(Ra,Ja,!0);var od=_toString.call(Ra.dump),ld=ed,cd;ed&&(ed=Ra.flowLevel<0||Ra.flowLevel>qa);var ud=od==="[object Object]"||od==="[object Array]",_d,yd;if(ud&&(_d=Ra.duplicates.indexOf(Ja),yd=_d!==-1),(Ra.tag!==null&&Ra.tag!=="?"||yd||Ra.indent!==2&&qa>0)&&(td=!1),yd&&Ra.usedDuplicates[_d])Ra.dump="*ref_"+_d;else{if(ud&&yd&&!Ra.usedDuplicates[_d]&&(Ra.usedDuplicates[_d]=!0),od==="[object Object]")ed&&Object.keys(Ra.dump).length!==0?(writeBlockMapping(Ra,qa,Ra.dump,td),yd&&(Ra.dump="&ref_"+_d+Ra.dump)):(writeFlowMapping(Ra,qa,Ra.dump),yd&&(Ra.dump="&ref_"+_d+" "+Ra.dump));else if(od==="[object Array]")ed&&Ra.dump.length!==0?(Ra.noArrayIndent&&!sd&&qa>0?writeBlockSequence(Ra,qa-1,Ra.dump,td):writeBlockSequence(Ra,qa,Ra.dump,td),yd&&(Ra.dump="&ref_"+_d+Ra.dump)):(writeFlowSequence(Ra,qa,Ra.dump),yd&&(Ra.dump="
2024-09-04 13:02:35 +08:00
` :""}__name(dump $ 1,"dump $ 1");function renamed(Ra,qa){return function(){throw new Error("Function yaml."+Ra+" is removed in js-yaml 4. Use yaml."+qa+" instead, which is now safe by default.")}}__name(renamed,"renamed");var JSON_SCHEMA=json,load $ 2=loader25.load;function extractFrontMatter(Ra){const qa=Ra.match(frontMatterRegex);if(!qa)return{text:Ra,metadata:{}};let Ja=load $ 2(qa[1],{schema:JSON_SCHEMA})??{};Ja=typeof Ja=="object"&&!Array.isArray(Ja)?Ja:{};const ed={};return Ja.displayMode&&(ed.displayMode=Ja.displayMode.toString()),Ja.title&&(ed.title=Ja.title.toString()),Ja.config&&(ed.config=Ja.config),{text:Ra.slice(qa[0].length),metadata:ed}}__name(extractFrontMatter,"extractFrontMatter");var cleanupText=__name(Ra=>Ra.replace(/ \r \n ?/g, `
2024-08-30 15:19:18 +08:00
` ).replace(/<( \w +)([^>]*)>/g,(qa,Ja,ed)=>"<"+Ja+ed.replace(/="([^"]*)"/g,"=' $ 1'")+">"),"cleanupText"),processFrontmatter=__name(Ra=>{const{text:qa,metadata:Ja}=extractFrontMatter(Ra),{displayMode:ed,title:td,config:rd={}}=Ja;return ed&&(rd.gantt||(rd.gantt={}),rd.gantt.displayMode=ed),{title:td,config:rd,text:qa}},"processFrontmatter"),processDirectives=__name(Ra=>{const qa=utils_default.detectInit(Ra)??{},Ja=utils_default.detectDirective(Ra,"wrap");return Array.isArray(Ja)?qa.wrap=Ja.some(({type:ed})=>ed==="wrap"):(Ja==null?void 0:Ja.type)==="wrap"&&(qa.wrap=!0),{text:removeDirectives(Ra),directive:qa}},"processDirectives");function preprocessDiagram(Ra){const qa=cleanupText(Ra),Ja=processFrontmatter(qa),ed=processDirectives(Ja.text),td=cleanAndMerge(Ja.config,ed.directive);return Ra=cleanupComments(ed.text),{code:Ra,title:Ja.title,config:td}}__name(preprocessDiagram,"preprocessDiagram");function toBase64 $ 1(Ra){const qa=new TextEncoder().encode(Ra),Ja=Array.from(qa,ed=>String.fromCodePoint(ed)).join("");return btoa(Ja)}__name(toBase64 $ 1,"toBase64");var MAX_TEXTLENGTH=5e4,MAX_TEXTLENGTH_EXCEEDED_MSG="graph TB;a[Maximum text size in diagram exceeded];style a fill:#faa",SECURITY_LVL_SANDBOX="sandbox",SECURITY_LVL_LOOSE="loose",XMLNS_SVG_STD="http://www.w3.org/2000/svg",XMLNS_XLINK_STD="http://www.w3.org/1999/xlink",XMLNS_XHTML_STD="http://www.w3.org/1999/xhtml",IFRAME_WIDTH="100%",IFRAME_HEIGHT="100%",IFRAME_STYLES="border:0;margin:0;",IFRAME_BODY_STYLE="margin:0",IFRAME_SANDBOX_OPTS="allow-top-navigation-by-user-activation allow-popups",IFRAME_NOT_SUPPORTED_MSG='The "iframe" tag is not supported by your browser.',DOMPURIFY_TAGS=["foreignobject"],DOMPURIFY_ATTR=["dominant-baseline"];function processAndSetConfigs(Ra){const qa=preprocessDiagram(Ra);return reset(),addDirective(qa.config??{}),qa}__name(processAndSetConfigs,"processAndSetConfigs");async function parse $ 4(Ra,qa){addDiagrams();try{const{code:Ja}=processAndSetConfigs(Ra);return{diagramType:(await getDiagramFromText(Ja)).type}}catch(Ja){if(qa!=null&&qa.suppressErrors)return!1;throw Ja}}__name(parse $ 4,"parse");var cssImportantStyles=__name((Ra,qa,Ja=[])=> `
. $ { Ra } $ { qa } { $ { Ja . join ( " !important; " ) } ! important ; } ` ,"cssImportantStyles"),createCssStyles=__name((Ra,qa=new Map)=>{var ed;let Ja="";if(Ra.themeCSS!==void 0&&(Ja+= `
$ { Ra . themeCSS } ` ),Ra.fontFamily!==void 0&&(Ja+= `
: root { -- mermaid - font - family : $ { Ra . fontFamily } } ` ),Ra.altFontFamily!==void 0&&(Ja+= `
2024-09-03 08:22:14 +08:00
: root { -- mermaid - alt - font - family : $ { Ra . altFontFamily } } ` ),qa instanceof Map){const od=Ra.htmlLabels??((ed=Ra.flowchart)==null?void 0:ed.htmlLabels)?["> *","span"]:["rect","polygon","ellipse","circle","path"];qa.forEach(ld=>{isEmpty $ 1(ld.styles)||od.forEach(cd=>{Ja+=cssImportantStyles(ld.id,cd,ld.styles)}),isEmpty $ 1(ld.textStyles)||(Ja+=cssImportantStyles(ld.id,"tspan",((ld==null?void 0:ld.textStyles)||[]).map(cd=>cd.replace("color","fill"))))})}return Ja},"createCssStyles"),createUserStyles=__name((Ra,qa,Ja,ed)=>{const td=createCssStyles(Ra,Ja),rd=styles_default(qa,td,Ra.themeVariables);return serialize(compile $ 2( ` $ { ed } { $ { rd } } ` ),stringify $ 4)},"createUserStyles"),cleanUpSvgCode=__name((Ra="",qa,Ja)=>{let ed=Ra;return!Ja&&!qa&&(ed=ed.replace(/marker-end="url \( [ \d +./:=?A-Za-z-]*?#/g,'marker-end="url(#')),ed=decodeEntities(ed),ed=ed.replace(/<br>/g,"<br/>"),ed},"cleanUpSvgCode"),putIntoIFrame=__name((Ra="",qa)=>{var td,rd;const Ja=(rd=(td=qa==null?void 0:qa.viewBox)==null?void 0:td.baseVal)!=null&&rd.height?qa.viewBox.baseVal.height+"px":IFRAME_HEIGHT,ed=toBase64 $ 1( ` < body style = "${IFRAME_BODY_STYLE}" > $ { Ra } < / b o d y > ` ) ; r e t u r n ` < i f r a m e s t y l e = " w i d t h : $ { I F R A M E _ W I D T H } ; h e i g h t : $ { J a } ; $ { I F R A M E _ S T Y L E S } " s r c = " d a t a : t e x t / h t m l ; c h a r s e t = U T F - 8 ; b a s e 6 4 , $ { e d } " s a n d b o x = " $ { I F R A M E _ S A N D B O X _ O P T S } " >
2024-08-27 22:31:52 +08:00
$ { IFRAME _NOT _SUPPORTED _MSG }
2024-09-08 17:22:36 +08:00
< / i f r a m e > ` } , " p u t I n t o I F r a m e " ) , a p p e n d D i v S v g G = _ _ n a m e ( ( R a , q a , J a , e d , t d ) = > { c o n s t r d = R a . a p p e n d ( " d i v " ) ; r d . a t t r ( " i d " , J a ) , e d & & r d . a t t r ( " s t y l e " , e d ) ; c o n s t s d = r d . a p p e n d ( " s v g " ) . a t t r ( " i d " , q a ) . a t t r ( " w i d t h " , " 1 0 0 % " ) . a t t r ( " x m l n s " , X M L N S _ S V G _ S T D ) ; r e t u r n t d & & s d . a t t r ( " x m l n s : x l i n k " , t d ) , s d . a p p e n d ( " g " ) , R a } , " a p p e n d D i v S v g G " ) ; f u n c t i o n s a n d b o x e d I f r a m e ( R a , q a ) { r e t u r n R a . a p p e n d ( " i f r a m e " ) . a t t r ( " i d " , q a ) . a t t r ( " s t y l e " , " w i d t h : 1 0 0 % ; h e i g h t : 1 0 0 % ; " ) . a t t r ( " s a n d b o x " , " " ) } _ _ n a m e ( s a n d b o x e d I f r a m e , " s a n d b o x e d I f r a m e " ) ; v a r r e m o v e E x i s t i n g E l e m e n t s = _ _ n a m e ( ( R a , q a , J a , e d ) = > { v a r t d , r d , s d ; ( t d = R a . g e t E l e m e n t B y I d ( q a ) ) = = n u l l | | t d . r e m o v e ( ) , ( r d = R a . g e t E l e m e n t B y I d ( J a ) ) = = n u l l | | r d . r e m o v e ( ) , ( s d = R a . g e t E l e m e n t B y I d ( e d ) ) = = n u l l | | s d . r e m o v e ( ) } , " r e m o v e E x i s t i n g E l e m e n t s " ) , r e n d e r = _ _ n a m e ( a s y n c f u n c t i o n ( R a , q a , J a ) { v a r J d , Z d , p f , Q d , h f , m f ; a d d D i a g r a m s ( ) ; c o n s t e d = p r o c e s s A n d S e t C o n f i g s ( q a ) ; q a = e d . c o d e ; c o n s t t d = g e t C o n f i g $ 1 ( ) ; l o g $ 1 . d e b u g ( t d ) , q a . l e n g t h > ( ( t d = = n u l l ? v o i d 0 : t d . m a x T e x t S i z e ) ? ? M A X _ T E X T L E N G T H ) & & ( q a = M A X _ T E X T L E N G T H _ E X C E E D E D _ M S G ) ; c o n s t r d = " # " + R a , s d = " i " + R a , o d = " # " + s d , l d = " d " + R a , c d = " # " + l d , u d = _ _ n a m e ( ( ) = > { c o n s t L f = s e l e c t ( y d ? o d : c d ) . n o d e ( ) ; L f & & " r e m o v e " i n L f & & L f . r e m o v e ( ) } , " r e m o v e T e m p E l e m e n t s " ) ; l e t _ d = s e l e c t ( " b o d y " ) ; c o n s t y d = t d . s e c u r i t y L e v e l = = = S E C U R I T Y _ L V L _ S A N D B O X , g d = t d . s e c u r i t y L e v e l = = = S E C U R I T Y _ L V L _ L O O S E , E d = t d . f o n t F a m i l y ; i f ( J a ! = = v o i d 0 ) { i f ( J a & & ( J a . i n n e r H T M L = " " ) , y d ) { c o n s t x f = s a n d b o x e d I f r a m e ( s e l e c t ( J a ) , s d ) ; _ d = s e l e c t ( x f . n o d e s ( ) [ 0 ] . c o n t e n t D o c u m e n t . b o d y ) , _ d . n o d e ( ) . s t y l e . m a r g i n = 0 } e l s e _ d = s e l e c t ( J a ) ; a p p e n d D i v S v g G ( _ d , R a , l d , ` f o n t - f a m i l y : $ { E d } ` , X M L N S _ X L I N K _ S T D ) } e l s e { i f ( r e m o v e E x i s t i n g E l e m e n t s ( d o c u m e n t , R a , l d , s d ) , y d ) { c o n s t x f = s a n d b o x e d I f r a m e ( s e l e c t ( " b o d y " ) , s d ) ; _ d = s e l e c t ( x f . n o d e s ( ) [ 0 ] . c o n t e n t D o c u m e n t . b o d y ) , _ d . n o d e ( ) . s t y l e . m a r g i n = 0 } e l s e _ d = s e l e c t ( " b o d y " ) ; a p p e n d D i v S v g G ( _ d , R a , l d ) } l e t T d , O d ; t r y { T d = a w a i t D i a g r a m . f r o m T e x t ( q a , { t i t l e : e d . t i t l e } ) } c a t c h ( x f ) { i f ( t d . s u p p r e s s E r r o r R e n d e r i n g ) t h r o w u d ( ) , x f ; T d = a w a i t D i a g r a m . f r o m T e x t ( " e r r o r " ) , O d = x f } c o n s t R d = _ d . s e l e c t ( c d ) . n o d e ( ) , N d = T d . t y p e , I d = R d . f i r s t C h i l d , M d = I d . f i r s t C h i l d , L d = ( Z d = ( J d = T d . r e n d e r e r ) . g e t C l a s s e s ) = = n u l l ? v o i d 0 : Z d . c a l l ( J d , q a , T d ) , P d = c r e a t e U s e r S t y l e s ( t d , N d , L d , r d ) , q d = d o c u m e n t . c r e a t e E l e m e n t ( " s t y l e " ) ; q d . i n n e r H T M L = P d , I d . i n s e r t B e f o r e ( q d , M d ) ; t r y { a w a i t T d . r e n d e r e r . d r a w ( q a , R a , v e r s i o n , T d ) } c a t c h ( x f ) { t h r o w t d . s u p p r e s s E r r o r R e n d e r i n g ? u d ( ) : e r r o r R e n d e r e r _ d e f a u l t . d r a w ( q a , R a , v e r s i o n ) , x f } c o n s t Y d = _ d . s e l e c t ( ` $ { c d } s v g ` ) , U d = ( Q d = ( p f = T d . d b ) . g e t A c c T i t l e ) = = n u l l ? v o i d 0 : Q d . c a l l ( p f ) , H d = ( m f = ( h f = T d . d b ) . g e t A c c D e s c r i p t i o n ) = = n u l l ? v o i d 0 : m f . c a l l ( h f ) ; a d d A 1 1 y I n f o ( N d , Y d , U d , H d ) , _ d . s e l e c t ( ` [ i d = " $ { R a } " ] ` ) . s e l e c t A l l ( " f o r e i g n o b j e c t > * " ) . a t t r ( " x m l n s " , X M L N S _ X H T M L _ S T D ) ; l e t z d = _ d . s e l e c t ( c d ) . n o d e ( ) . i n n e r H T M L ; i f ( l o g $ 1 . d e b u g ( " c o n f i g . a r r o w M a r k e r A b s o l u t e " , t d . a r r o w M a r k e r A b s o l u t e ) , z d = c l e a n U p S v g C o d e ( z d , y d , e v a l u a t e ( t d . a r r o w M a r k e r A b s o l u t e ) ) , y d ) { c o n s t x f = _ d . s e l e c t ( c d + " s v g " ) . n o d e ( ) ; z d = p u t I n t o I F r a m e ( z d , x f ) } e l s e g d | | ( z d = p u r i f y . s a n i t i z e ( z d , { A D D _ T A G S : D O M P U R I F Y _ T A G S , A D D _ A T T R : D O M P U R I F Y _ A T T R } ) ) ; i f ( a t t a c h F u n c t i o n s ( ) , O d ) t h r o w O d ; r e t u r n u d ( ) , { d i a g r a m T y p e : N d , s v g : z d , b i n d F u n c t i o n s : T d . d b . b i n d F u n c t i o n s } } , " r e n d e r " ) ; f u n c t i o n i n i t i a l i z e ( R a = { } ) { v a r e d ; c o n s t q a = a s s i g n W i t h D e p t h _ d e f a u l t ( { } , R a ) ; q a ! = n u l l & & q a . f o n t F a m i l y & & ! ( ( e d = q a . t h e m e V a r i a b l e s ) ! = n u l l & & e d . f o n t F a m i l y ) & & ( q a . t h e m e V a r i a b l e s | | ( q a . t h e m e V a r i a b l e s = { } ) , q a . t h e m e V a r i a b l e s . f o n t F a m i l y = q a . f o n t F a m i l y ) , s a v e C o n f i g F r o m I n i t i a l i z e ( q a ) , q a ! = n u l l & & q a . t h e m e & & q a . t h e m e i n t h e m e s _ d e f a u l t ? q a . t h e m e V a r i a b l e s = t h e m e s _ d e f a u l t [ q a . t h e m e ] . g e t T h e m e V a r i a b l e s ( q a . t h e m e V a r i a b l e s ) : q a & & ( q a . t h e m e V a r i a b l e s = t h e m e s _ d e f a u l t . d e f a u l t . g e t T h e m e V a r i a b l e s ( q a . t h e m e V a r i a b l e s ) ) ; c o n s t J a = t y p e o f q a = = " o b j e c t " ? s e t S i t e C o n f i g ( q a ) : g e t S i t e C o n f i g ( ) ; s e t L o g L e v e l ( J a . l o g L e v e l ) , a d d D i a g r a m s ( ) } _ _ n a m e ( i n i t i a l i z e , " i n i t i a l i z e " ) ; v a r g e t D i a g r a m F r o m T e x t = _ _ n a m e ( ( R a , q a = { } ) = > { c o n s t { c o d e : J a } = p r e p r o c e s s D i a g r a m ( R a ) ; r e t u r n D i a g r a m . f r o m T e x t ( J a , q a ) } , " g e t D i a g r a m F r o m T e x t " ) ; f u n c t i o n a d d A 1 1 y I n f o ( R a , q a , J a , e d ) { s e t A 1 1 y D i a g r a m I n f o ( q a , R a ) , a d d S V G a 1 1 y T i t l e D e s c r i p t i o n ( q a , J a , e d , q a . a t t r ( " i d " ) ) } _ _ n a m e ( a d d A 1 1 y I n f o , " a d d A 1 1 y I n f o " ) ; v a r m e r m a i d A P I = O b j e c t . f r e e z e ( { r e n d e r , p a r s e : p a r s e $ 4 , g e t D i a g r a m F r o m T e x t , i n i t i a l i z e , g e t C o n f i g : g e t C o n f i g $ 1 , s e t C o n f i g , g e t S i t e C o n f i g , u p d a t e S i t e C o n f i g , r e s e t : _ _ n a m e ( ( ) = > { r e s e t ( ) } , " r e s e t " ) , g l o b a l R e s e t : _ _ n a m e ( ( ) = > { r e s e t ( d e f a u l t C o n f i g ) } , " g l o b a l R e s e t " ) , d e f a u l t C o n f i g } ) ; s e t L o g L e v e l ( g e t C o n f i g $ 1 ( )
2024-08-27 22:31:52 +08:00
* Wait for document loaded before starting the execution
* //*! Bundled license information:
js - yaml / dist / js - yaml . mjs :
( * ! js - yaml 4.1 . 0 https : //github.com/nodeca/js-yaml @license MIT *)
2024-09-08 09:47:40 +08:00
* /const inlineRule=/ ^ ( \ $ { 1 , 2 } ) ( ? ! \ $ ) ( ( ? : \ \ . | [ ^ \ \ \ n ] ) * ? ( ? : \ \ . | [ ^ \ \ \ n$ ] ) ) \ 1 ( ? = [ \ s ? ! . , : ? ! 。 , : ] | $ ) / , inlineRuleNonStandard = /^(\${1,2})(?!\$)((?:\\.|[^\\\n])*?(?:\\.|[^\\\n$]))\1/ , blockRule = /^(\${1,2})\n((?:\\[\s\S]|[^\\])+?)\n\1(?:\n|$)/ ; function createRenderer ( Ra ) { return qa => { window . MathJax . texReset ( ) ; const ed = window . MathJax . tex2svg ( qa . text , { display : Ra } ) . firstChild , td = ed . style [ "min-width" ] || ed . getAttribute ( "width" ) ; return ed . removeAttribute ( "width" ) , ed . style = "max-width: 300vw !important;" , ed . style . width = td , ed . style . display = "initial" , Ra ? ` <section style="text-align: center; overflow: auto;"> ${ ed . outerHTML } </section> ` : ` <span style="vertical-align: middle; line-height: 1;"> ${ ed . outerHTML } </span> ` } } function inlineKatex ( Ra , qa ) { const Ja = Ra && Ra . nonStandard , ed = Ja ? inlineRuleNonStandard : inlineRule ; return { name : "inlineKatex" , level : "inline" , start ( td ) { let rd , sd = td ; for ( ; sd ; ) { if ( rd = sd . indexOf ( "$" ) , rd === - 1 ) return ; if ( ( Ja ? rd > - 1 : rd === 0 || sd . charAt ( rd - 1 ) === " " ) && sd . substring ( rd ) . match ( ed ) ) return rd ; sd = sd . substring ( rd + 1 ) . replace ( /^\$+/ , "" ) } } , tokenizer ( td ) { const rd = td . match ( ed ) ; if ( rd ) return { type : "inlineKatex" , raw : rd [ 0 ] , text : rd [ 2 ] . trim ( ) , displayMode : rd [ 1 ] . length === 2 } } , renderer : qa } } function blockKatex ( Ra , qa ) { return { name : "blockKatex" , level : "block" , tokenizer ( Ja ) { const ed = Ja . match ( blockRule ) ; if ( ed ) return { type : "blockKatex" , raw : ed [ 0 ] , text : ed [ 2 ] . trim ( ) , displayMode : ed [ 1 ] . length === 2 } } , renderer : qa } } function MDKatex ( Ra = { } ) { return { extensions : [ inlineKatex ( Ra , createRenderer ( ! 1 ) ) , blockKatex ( Ra , createRenderer ( ! 0 ) ) ] } } marked$1 . use ( MDKatex ( { nonStandard : ! 0 } ) ) ; function buildTheme ( { theme : Ra , fonts : qa , size : Ja } ) { const ed = toMerged ( Ra . base , { "font-family" : qa , "font-size" : Ja } ) , td = rd => Object . fromEntries ( Object . entries ( rd ) . map ( ( [ sd , od ] ) => [ sd , toMerged ( ed , od ) ] ) ) ; return { ... td ( Ra . inline ) , ... td ( Ra . block ) } } function buildAddition ( ) { return `
2024-08-27 22:31:52 +08:00
< style >
. preview - wrapper pre : : before {
position : absolute ;
top : 0 ;
right : 0 ;
color : # ccc ;
text - align : center ;
font - size : 0.8 em ;
padding : 5 px 10 px 0 ;
line - height : 15 px ;
height : 15 px ;
font - weight : 600 ;
}
< / s t y l e >
2024-09-04 13:02:35 +08:00
` }function getStyles(Ra,qa,Ja=""){const ed=Ra[qa];return ed? ` style = "${Object.entries(ed).map(([rd,sd])=>`${rd}:${sd}`).join(" ; ")}${Ja}" ` :""}function buildFootnoteArray(Ra){return Ra.map(([qa,Ja,ed])=>ed===Ja? ` < code style = "font-size: 90%; opacity: 0.6;" > [ $ { qa } ] < /code>: <i style="word-break: break-all">${Ja}</i > < br / > ` : ` < code style = "font-size: 90%; opacity: 0.6;" > [ $ { qa } ] < /code> ${Ja}: <i style="word-break: break-all">${ed}</i > < br / > ` ).join( `
2024-09-07 21:44:41 +08:00
` )}function transform $ 1(Ra,qa,Ja){const ed=Ra.split("-");for(const td of ed){if(td==="alt"&&qa)return qa;if(td==="title"&&Ja)return Ja}return""}const macCodeSvg= `
2024-09-08 09:47:40 +08:00
< svg xmlns = "http://www.w3.org/2000/svg" version = "1.1" x = "0px" y = "0px" width = "45px" height = "13px" viewBox = "0 0 450 130" >
2024-09-07 21:44:41 +08:00
< ellipse cx = "65" cy = "65" rx = "50" ry = "52" stroke = "rgb(220,60,54)" stroke - width = "2" fill = "rgb(237,108,96)" / >
< ellipse cx = "225" cy = "65" rx = "50" ry = "52" stroke = "rgb(218,151,33)" stroke - width = "2" fill = "rgb(247,193,81)" / >
< ellipse cx = "385" cy = "65" rx = "50" ry = "52" stroke = "rgb(27,161,37)" stroke - width = "2" fill = "rgb(100,200,86)" / >
< / s v g >
2024-09-08 17:22:36 +08:00
` .trim();function initRenderer(Ra){const qa=[];let Ja=0,ed=buildTheme(Ra),td=0,rd=0,sd=!1;function od(Ed,Td=""){return getStyles(ed,Ed,Td)}function ld(Ed,Td,Od){if(!Td)return"";const Rd=Od??Ed;return ` < $ { Rd } $ { od ( Ed ) } > $ { Td } < /${Rd}>`}function cd(Ed,Td){return qa.push([++Ja,Ed,Td]),Ja}function ud(Ed){qa.length=0,Ja=0,_d(Ed)}function _d(Ed){Ra={...Ra,...Ed},ed=buildTheme(Ra)}const yd=()=>qa.length?ld("h4","引用链接")+ld("footnotes",buildFootnoteArray(qa),"p"):"",gd={heading({tokens:Ed,depth:Td}){const Od=this.parser.parseInline(Ed),Rd=`h${Td}`;return ld(Rd,Od)},paragraph({tokens:Ed}){const Td=this.parser.parseInline(Ed),Od=Td.includes("<figure")&&Td.includes("<img"),Rd=Td.trim()==="";return Od||Rd?Td:ld("p",Td)},blockquote({tokens:Ed}){let Td=this.parser.parse(Ed);return Td=Td.replace(/ < p . * ? > / g , ` < p $ { o d ( " b l o c k q u o t e _ p " ) } > ` ) , l d ( " b l o c k q u o t e " , T d ) } , c o d e ( { t e x t : E d , l a n g : T d = " " } ) { i f ( T d . s t a r t s W i t h ( " m e r m a i d " ) ) r e t u r n c l e a r T i m e o u t ( t d ) , t d = s e t T i m e o u t ( ( ) = > { m e r m a i d _ d e f a u l t . r u n ( ) } , 0 ) , ` < p r e c l a s s = " m e r m a i d " > $ { E d } < / p r e > ` ; c o n s t O d = T d . s p l i t ( " " ) [ 0 ] , R d = H i g h l i g h t J S . g e t L a n g u a g e ( O d ) ? O d : " p l a i n t e x t " ; l e t N d = H i g h l i g h t J S . h i g h l i g h t ( E d , { l a n g u a g e : R d } ) . v a l u e ; r e t u r n N d = N d . r e p l a c e ( / \ r \ n / g , " < b r / > " ) . r e p l a c e ( / \ n / g , " < b r / > " ) . r e p l a c e ( / ( > [ ^ < ] + ) | ( ^ [ ^ < ] + ) / g , I d = > I d . r e p l a c e ( / \ s / g , " & n b s p ; " ) ) , ` < p r e c l a s s = " h l j s c o d e _ _ p r e " $ { o d ( " c o d e _ p r e " ) } > < s p a n c l a s s = " m a c - s i g n " s t y l e = " p a d d i n g : 1 0 p x 1 4 p x 0 ; " h i d d e n > $ { m a c C o d e S v g } < / s p a n > < c o d e c l a s s = " l a n g u a g e - $ { T d } " $ { o d ( " c o d e " ) } > $ { N d } < / c o d e > < / p r e > ` } , c o d e s p a n ( { t e x t : E d } ) { r e t u r n l d ( " c o d e s p a n " , E d , " c o d e " ) } , l i s t i t e m ( E d ) { c o n s t T d = s d ? ` $ { r d + 1 } . ` : " • " , O d = E d . t o k e n s . m a p ( R d = > t h i s [ R d . t y p e ] ( R d ) ) . j o i n ( " " ) ; r e t u r n l d ( " l i s t i t e m " , ` $ { T d } $ { O d } ` , " l i " ) } , l i s t ( { o r d e r e d : E d , i t e m s : T d } ) { c o n s t O d = [ ] ; f o r ( l e t N d = 0 ; N d < T d . l e n g t h ; N d + + ) { s d = E d , r d = N d ; c o n s t I d = T d [ N d ] ; O d . p u s h ( t h i s . l i s t i t e m ( I d ) ) } r e t u r n l d ( E d ? " o l " : " u l " , O d . j o i n ( " " ) ) } , i m a g e ( { h r e f : E d , t i t l e : T d , t e x t : O d } ) { c o n s t R d = l d ( " f i g c a p t i o n " , t r a n s f o r m $ 1 ( R a . l e g e n d , O d , T d ) ) , N d = o d ( " f i g u r e " ) , I d = o d ( " i m a g e " ) ; r e t u r n ` < f i g u r e $ { N d } > < i m g $ { I d } s r c = " $ { E d } " t i t l e = " $ { T d } " a l t = " $ { O d } " / > $ { R d } < / f i g u r e > ` } , l i n k ( { h r e f : E d , t i t l e : T d , t e x t : O d } ) { i f ( E d . s t a r t s W i t h ( " h t t p s : / / m p . w e i x i n . q q . c o m " ) ) r e t u r n ` < a h r e f = " $ { E d } " t i t l e = " $ { T d | | O d } " $ { o d ( " w x _ l i n k " ) } > $ { O d } < / a > ` ; i f ( E d = = = O d ) r e t u r n O d ; i f ( R a . s t a t u s ) { c o n s t R d = c d ( T d | | O d , E d ) ; r e t u r n ` < s p a n $ { o d ( " l i n k " ) } > $ { O d } < s u p > [ $ { R d } ] < / s u p > < / s p a n > ` } r e t u r n l d ( " l i n k " , O d , " s p a n " ) } , s t r o n g ( { t o k e n s : E d } ) { r e t u r n l d ( " s t r o n g " , t h i s . p a r s e r . p a r s e I n l i n e ( E d ) ) } , e m ( { t o k e n s : E d } ) { r e t u r n l d ( " e m " , t h i s . p a r s e r . p a r s e I n l i n e ( E d ) , " s p a n " ) } , t a b l e ( { h e a d e r : E d , r o w s : T d } ) { c o n s t O d = E d . m a p ( N d = > t h i s . t a b l e c e l l ( N d ) ) . j o i n ( " " ) , R d = T d . m a p ( N d = > { c o n s t I d = N d . m a p ( M d = > t h i s . t a b l e c e l l ( M d ) ) . j o i n ( " " ) ; r e t u r n l d ( " t r " , I d ) } ) . j o i n ( " " ) ; r e t u r n `
2024-09-04 13:02:35 +08:00
< section style = "padding:0 8px; max-width: 100%; overflow: auto" >
< table class = "preview-table" >
2024-09-08 17:22:36 +08:00
< thead $ { od ( "thead" ) } > $ { Od } < / t h e a d >
2024-09-04 13:02:35 +08:00
< tbody > $ { Rd } < / t b o d y >
< / t a b l e >
< / s e c t i o n >
` },tablecell(Ed){const Td=this.parser.parseInline(Ed.tokens);return ld("td",Td)},hr(){return ld("hr","")}};return marked $ 1.use({renderer:gd}),{buildAddition,buildFootnotes:yd,setOptions:_d,reset:ud}}const DEFAULT_CONTENT= ` # 探索 Markdown 的奇妙世界
2024-08-27 22:31:52 +08:00
2024-09-01 06:41:46 +08:00
欢迎来到 Markdown 的奇妙世界 ! 无论你是写作爱好者 、 开发者 、 博主 , 还是想要简单记录点什么的人 , Markdown 都能成为你新的好伙伴 。 它不仅让写作变得简单明了 , 还能轻松地将内容转化为漂亮的网页格式 。 今天 , 我们将全面探讨 Markdown 的基础和进阶语法 , 让你在这个过程中充分享受写作的乐趣 !
2024-08-27 22:31:52 +08:00
2024-09-01 06:41:46 +08:00
Markdown 是一种轻量级标记语言 , 用于格式化纯文本 。 它以简单 、 直观的语法而著称 , 可以快速地生成 HTML 。 Markdown 是写作与代码的完美结合 , 既简单又强大 。
2024-08-27 22:31:52 +08:00
2024-09-01 06:41:46 +08:00
# # Markdown 基础语法
2024-08-27 22:31:52 +08:00
2024-09-01 06:41:46 +08:00
# # # 1. 标题 : 让你的内容层次分明
2024-08-27 22:31:52 +08:00
2024-09-01 06:41:46 +08:00
用 \ ` # \` 号来创建标题。标题从 \` # \` 开始,我们最多支持 4 个 \` # \` 号,对应 4 级标题。
2024-08-27 22:31:52 +08:00
2024-08-31 15:27:49 +08:00
\ ` \` \` markdown
# 一级标题
2024-09-04 13:02:35 +08:00
2024-08-31 15:27:49 +08:00
# # 二级标题
2024-09-04 13:02:35 +08:00
2024-08-31 15:27:49 +08:00
# # # 三级标题
2024-09-04 13:02:35 +08:00
2024-08-31 15:27:49 +08:00
# # # # 四级标题
\ ` \` \`
2024-08-27 22:31:52 +08:00
2024-09-01 06:41:46 +08:00
以上代码将渲染出一组层次分明的标题 , 使你的文章井井有条 。
2024-08-27 22:31:52 +08:00
2024-09-01 06:41:46 +08:00
> 标准 Markdown 支持 1 ~ 6 级标题 , 此编辑器也不例外 , 不过我们只准备了四个级别样式 , 同时也是不推荐文章超过四级标题 。
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
# # # 2. 段落与换行 : 自然流畅
2024-08-31 15:27:49 +08:00
2024-09-04 13:02:35 +08:00
Markdown 中的段落就是一行接一行的文本 。 要创建新段落 , 只需在两行文本之间空一行 。
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
# # # 3. 字体样式 : 强调你的文字
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
- * * 粗体 * * : 用两个星号或下划线包裹文字 , 如 \ ` **粗体** \` 或 \` __粗体__ \` 。
2024-09-04 13:02:35 +08:00
- _斜体 _ : 用一个星号或下划线包裹文字 , 如 \ ` *斜体* \` 或 \` _斜体_ \` 。
2024-09-01 06:41:46 +08:00
- ~ ~ 删除线 ~ ~ : 用两个波浪线包裹文字 , 如 \ ` ~~删除线~~ \` 。
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
这些简单的标记可以让你的内容更有层次感和重点突出 。
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
# # # 4. 列表 : 整洁有序
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
- * * 无序列表 * * : 用 \ ` - \` 、 \` * \` 或 \` + \` 加空格开始一行。
- * * 有序列表 * * : 使用数字加点号 ( \ ` 1. \` 、 \` 2. \` )开始一行。
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
在列表中嵌套其他内容 ? 只需缩进即可实现嵌套效果 。
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
- 无序列表项 1
2024-09-04 13:02:35 +08:00
1. 嵌套有序列表项 1
2. 嵌套有序列表项 2
2024-09-01 06:41:46 +08:00
- 无序列表项 2
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
1. 有序列表项 1
2. 有序列表项 2
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
# # # 5. 链接与图片 : 丰富内容
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
- * * 链接 * * : 用方括号和圆括号创建链接 \ ` [显示文本](链接地址) \` 。
- * * 图片 * * : 和链接类似 , 只需在前面加上 \ ` ! \` ,如 \` ![描述文本](图片链接) \` 。
2024-08-31 15:27:49 +08:00
2024-09-04 13:02:35 +08:00
[ 访问 Doocs ] ( https : //github.com/doocs)
2024-08-31 15:27:49 +08:00
2024-09-04 13:02:35 +08:00
! [ doocs ] ( https : //cdn-doocs.oss-cn-shenzhen.aliyuncs.com/gh/doocs/md/images/logo-2.png)
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
轻松实现富媒体内容展示 !
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
> 因微信公众号平台不支持除公众号文章以外的链接 , 故其他平台的链接 , 会呈现链接色泽但不能点击 。
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
> 对于这些链接请注意明文书写 , 或点击左上角 「 格式 - > 微信外链接转底部引用 」 开启引用 , 这样就可以在底部观察到链接指向 。
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
# # # 6. 引用 : 引用名言或引人深思的句子
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
使用 \ ` > \` 来创建引用,只需在文本前面加上它。多层引用?在前一层 \` > \` 后再加一个就行。
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
> 这是一个引用
2024-09-04 13:02:35 +08:00
>
> > 这是一个嵌套引用
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
这让你的引用更加富有层次感 。
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
# # # 7. 代码块 : 展示你的代码
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
- * * 行内代码 * * : 用反引号包裹 , 如 \ ` code \` 。
- * * 代码块 * * : 用三个反引号包裹 , 并指定语言 , 如 :
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
\ ` \` \` js
2024-09-04 13:02:35 +08:00
console . log ( "Hello, Doocs!" ) ;
2024-08-31 15:27:49 +08:00
\ ` \` \`
2024-09-01 06:41:46 +08:00
语法高亮让你的代码更易读 。
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
# # # 8. 分割线 : 分割内容
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
用三个或更多的 \ ` - \` 、 \` * \` 或 \` _ \` 来创建分割线。
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
-- -
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
为你的内容添加视觉分隔 。
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
# # # 9. 表格 : 清晰展示数据
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
Markdown 支持简单的表格 , 用 \ ` | \` 和 \` - \` 分隔单元格和表头。
2024-08-31 15:27:49 +08:00
2024-09-04 13:02:35 +08:00
| 项目人员 | 邮箱 | 微信号 |
| -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- - | -- -- -- -- -- -- -- -- -- -- -- | -- -- -- -- -- -- |
| [ yanglbme ] ( https : //github.com/yanglbme) | contact@yanglibin.info | YLB0109 |
| [ YangFong ] ( https : //github.com/YangFong) | yangfong2022@gmail.com | yq2419731931 |
| [ thinkasany ] ( https : //github.com/thinkasany) | thinkasany@gmail.com | thinkasany |
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
这样的表格让数据展示更为清爽 !
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
> 手动编写标记太麻烦 ? 我们提供了便捷方式 。 左上方点击 「 编辑 - > 插入表格 」 , 即可快速实现表格渲染 。
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
# # Markdown 进阶技巧
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
# # # 1. LaTeX 公式 : 完美展示数学表达式
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
Markdown 允许嵌入 LaTeX 语法展示数学公式 :
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
- * * 行内公式 * * : 用 \ ` $ \` 包裹公式,如 $ E = mc^2 $ 。
- * * 块级公式 * * : 用 \ ` $ $ \` 包裹公式,如:
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
$$
\ \ begin { aligned }
d _ { i , j } & \ \ leftarrow d _ { i , j } + 1 \ \ \ \
d _ { i , y + 1 } & \ \ leftarrow d _ { i , y + 1 } - 1 \ \ \ \
d _ { x + 1 , j } & \ \ leftarrow d _ { x + 1 , j } - 1 \ \ \ \
d _ { x + 1 , y + 1 } & \ \ leftarrow d _ { x + 1 , y + 1 } + 1
\ \ end { aligned }
$$
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
这是展示复杂数学表达的利器 !
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
# # # 2. Mermaid 流程图 : 可视化流程
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
Mermaid 是强大的可视化工具 , 可以在 Markdown 中创建流程图 、 时序图等 。
2024-08-31 15:27:49 +08:00
\ ` \` \` mermaid
2024-09-04 13:02:35 +08:00
graph TD ;
A -- > B ;
A -- > C ;
B -- > D ;
2024-09-01 06:41:46 +08:00
C -- > D ;
2024-08-31 15:27:49 +08:00
\ ` \` \`
\ ` \` \` mermaid
pie
2024-09-01 06:41:46 +08:00
title Key elements in Product X
"Calcium" : 42.96
"Potassium" : 50.05
"Magnesium" : 10.01
"Iron" : 5
2024-08-31 15:27:49 +08:00
\ ` \` \`
\ ` \` \` mermaid
pie
2024-09-01 06:41:46 +08:00
title 为什么总是宅在家里 ?
"喜欢宅" : 45
"天气太热" : 70
"穷" : 500
"没人约" : 95
2024-08-31 15:27:49 +08:00
\ ` \` \`
2024-09-01 06:41:46 +08:00
这种方式不仅能直观展示流程 , 还能提升文档的专业性 。
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
> 更多用法 , 参见 : [ Mermaid User Guide ] ( https : //mermaid.js.org/intro/getting-started.html)。
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
# # 结语
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
Markdown 是一种简单 、 强大且易于掌握的标记语言 , 通过学习基础和进阶语法 , 你可以快速创作内容并有效传达信息 。 无论是技术文档 、 个人博客还是项目说明 , Markdown 都是你的得力助手 。 希望这篇文章能够带你全面了解 Markdown 的潜力 , 让你的写作更加丰富多彩 !
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
现在 , 拿起 Markdown 编辑器 , 开始创作吧 ! 探索 Markdown 的世界 , 你会发现它远比想象中更精彩 !
2024-08-31 15:27:49 +08:00
2024-09-01 06:41:46 +08:00
# # # # 推荐阅读
2024-08-27 22:31:52 +08:00
2024-09-01 06:41:46 +08:00
- [ 阿里又一个 20 k + stars 开源项目诞生 , 恭喜 fastjson ! ] ( https : //mp.weixin.qq.com/s/RNKDCK2KoyeuMeEs6GUrow)
- [ 刷掉 90 % 候选人的互联网大厂海量数据面试题 ( 附题解 + 方法总结 ) ] ( https : //mp.weixin.qq.com/s/rjGqxUvrEqJNlo09GrT1Dw)
- [ 好用 ! 期待已久的文本块功能究竟如何在 Java 13 中发挥作用 ? ] ( https : //mp.weixin.qq.com/s/kalGv5T8AZGxTnLHr2wDsA)
- [ 2019 GitHub 开源贡献排行榜新鲜出炉 ! 微软谷歌领头 , 阿里跻身前 12 ! ] ( https : //mp.weixin.qq.com/s/_q812aGD1b9QvZ2WFI0Qgw)
2024-08-27 22:31:52 +08:00
2024-08-31 15:27:49 +08:00
-- -
2024-09-01 06:41:46 +08:00
< center >
< img src = "https://cdn-doocs.oss-cn-shenzhen.aliyuncs.com/gh/doocs/md/images/1648303220922-7e14aefa-816e-44c1-8604-ade709ca1c69.png" style = "width: 100px;" >
< / c e n t e r >
2024-08-29 18:38:21 +08:00
` ,DEFAULT_CSS_CONTENT= ` / * *
* 按 Alt / Option + Shift + F 可格式化
* 如需使用主题色 , 请使用 var ( -- md - primary - color ) 代替颜色值
* 如 : color : var ( -- md - primary - color ) ;
*
* 召集令 : 如果你有好看的主题样式 , 欢迎分享 , 让更多人能够使用到你的主题 。
* 提交区 : https : //github.com/doocs/md/issues/363
* /
2024-08-27 22:31:52 +08:00
/* 一级标题样式 */
h1 {
}
/* 二级标题样式 */
h2 {
}
/* 三级标题样式 */
h3 {
}
/* 四级标题样式 */
h4 {
}
/* 图片样式 */
image {
}
/* 引用样式 */
blockquote {
}
/* 引用段落样式 */
blockquote _p {
}
/* 段落样式 */
p {
}
/* 分割线样式 */
hr {
}
/* 行内代码样式 */
codespan {
}
/* 粗体样式 */
strong {
}
/* 链接样式 */
link {
}
/* 微信链接样式 */
wx _link {
}
/* 有序列表样式 */
ol {
}
/* 无序列表样式 */
ul {
}
/* 列表项样式 */
li {
}
/* 代码块样式 */
code {
}
2024-09-08 17:22:36 +08:00
` ;var cheerio $ 2={exports:{}},lib $ e={},extendStatics=function(Ra,qa){return extendStatics=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(Ja,ed){Ja.__proto__=ed}||function(Ja,ed){for(var td in ed)Object.prototype.hasOwnProperty.call(ed,td)&&(Ja[td]=ed[td])},extendStatics(Ra,qa)};function __extends $ 4(Ra,qa){if(typeof qa!="function"&&qa!==null)throw new TypeError("Class extends value "+String(qa)+" is not a constructor or null");extendStatics(Ra,qa);function Ja(){this.constructor=Ra}Ra.prototype=qa===null?Object.create(qa):(Ja.prototype=qa.prototype,new Ja)}var __assign $ 7=function(){return __assign $ 7=Object.assign||function(qa){for(var Ja,ed=1,td=arguments.length;ed<td;ed++){Ja=arguments[ed];for(var rd in Ja)Object.prototype.hasOwnProperty.call(Ja,rd)&&(qa[rd]=Ja[rd])}return qa},__assign $ 7.apply(this,arguments)};function __rest $ 1(Ra,qa){var Ja={};for(var ed in Ra)Object.prototype.hasOwnProperty.call(Ra,ed)&&qa.indexOf(ed)<0&&(Ja[ed]=Ra[ed]);if(Ra!=null&&typeof Object.getOwnPropertySymbols=="function")for(var td=0,ed=Object.getOwnPropertySymbols(Ra);td<ed.length;td++)qa.indexOf(ed[td])<0&&Object.prototype.propertyIsEnumerable.call(Ra,ed[td])&&(Ja[ed[td]]=Ra[ed[td]]);return Ja}function __decorate(Ra,qa,Ja,ed){var td=arguments.length,rd=td<3?qa:ed===null?ed=Object.getOwnPropertyDescriptor(qa,Ja):ed,sd;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")rd=Reflect.decorate(Ra,qa,Ja,ed);else for(var od=Ra.length-1;od>=0;od--)(sd=Ra[od])&&(rd=(td<3?sd(rd):td>3?sd(qa,Ja,rd):sd(qa,Ja))||rd);return td>3&&rd&&Object.defineProperty(qa,Ja,rd),rd}function __param(Ra,qa){return function(Ja,ed){qa(Ja,ed,Ra)}}function __esDecorate(Ra,qa,Ja,ed,td,rd){function sd(Rd){if(Rd!==void 0&&typeof Rd!="function")throw new TypeError("Function expected");return Rd}for(var od=ed.kind,ld=od==="getter"?"get":od==="setter"?"set":"value",cd=!qa&&Ra?ed.static?Ra:Ra.prototype:null,ud=qa||(cd?Object.getOwnPropertyDescriptor(cd,ed.name):{}),_d,yd=!1,gd=Ja.length-1;gd>=0;gd--){var Ed={};for(var Td in ed)Ed[Td]=Td==="access"?{}:ed[Td];for(var Td in ed.access)Ed.access[Td]=ed.access[Td];Ed.addInitializer=function(Rd){if(yd)throw new TypeError("Cannot add initializers after decoration has completed");rd.push(sd(Rd||null))};var Od=(0,Ja[gd])(od==="accessor"?{get:ud.get,set:ud.set}:ud[ld],Ed);if(od==="accessor"){if(Od===void 0)continue;if(Od===null||typeof Od!="object")throw new TypeError("Object expected");(_d=sd(Od.get))&&(ud.get=_d),(_d=sd(Od.set))&&(ud.set=_d),(_d=sd(Od.init))&&td.unshift(_d)}else(_d=sd(Od))&&(od==="field"?td.unshift(_d):ud[ld]=_d)}cd&&Object.defineProperty(cd,ed.name,ud),yd=!0}function __runInitializers(Ra,qa,Ja){for(var ed=arguments.length>2,td=0;td<qa.length;td++)Ja=ed?qa[td].call(Ra,Ja):qa[td].call(Ra);return ed?Ja:void 0}function __propKey(Ra){return typeof Ra=="symbol"?Ra:"".concat(Ra)}function __setFunctionName(Ra,qa,Ja){return typeof qa=="symbol"&&(qa=qa.description?"[".concat(qa.description,"]"):""),Object.defineProperty(Ra,"name",{configurable:!0,value:Ja?"".concat(Ja," ",qa):qa})}function __metadata(Ra,qa){if(typeof Reflect=="object"&&typeof Reflect.metadata=="function")return Reflect.metadata(Ra,qa)}function __awaiter $ 8(Ra,qa,Ja,ed){function td(rd){return rd instanceof Ja?rd:new Ja(function(sd){sd(rd)})}return new(Ja||(Ja=Promise))(function(rd,sd){function od(ud){try{cd(ed.next(ud))}catch(_d){sd(_d)}}function ld(ud){try{cd(ed.throw(ud))}catch(_d){sd(_d)}}function cd(ud){ud.done?rd(ud.value):td(ud.value).then(od,ld)}cd((ed=ed.apply(Ra,qa||[])).next())})}function __generator $ 8(Ra,qa){var Ja={label:0,sent:function(){if(rd[0]&1)throw rd[1];return rd[1]},trys:[],ops:[]},ed,td,rd,sd=Object.create((typeof Iterator=="function"?Iterator:Object).prototype);return sd.next=od(0),sd.throw=od(1),sd.return=od(2),typeof Symbol=="function"&&(sd[Symbol.iterator]=function(){return this}),sd;function od(cd){return function(ud){return ld([cd,ud])}}function ld(cd){if(ed)throw new TypeError("Generator is already executing.");for(;sd&&(sd=0,cd[0]&&(Ja=0)),Ja;)try{if(ed=1,td&&(rd=cd[0]&2?td.return:cd[0]?td.throw||((rd=td.return)
` ,nexist $ 1="∄",nexists $ 1="∄",Nfr $ 1="𝔑 ",nfr $ 1="𝔫 ",ngE $ 1="≧̸",nge $ 1="≱",ngeq $ 1="≱",ngeqq $ 1="≧̸",ngeqslant $ 1="⩾̸",nges $ 1="⩾̸",nGg $ 1="⋙̸",ngsim $ 1="≵",nGt $ 1="≫⃒",ngt $ 1="≯",ngtr $ 1="≯",nGtv $ 1="≫̸",nharr $ 1="↮",nhArr $ 1="⇎",nhpar $ 1="⫲",ni $ 6="∋",nis $ 1="⋼",nisd $ 1="⋺",niv $ 1="∋",NJcy $ 1="Њ",njcy $ 1="њ",nlarr $ 1="↚",nlArr $ 1="⇍",nldr $ 1="‥",nlE $ 1="≦̸",nle $ 1="≰",nleftarrow $ 1="↚",nLeftarrow $ 1="⇍",nleftrightarrow $ 1="↮",nLeftrightarrow $ 1="⇎",nleq $ 1="≰",nleqq $ 1="≦̸",nleqslant $ 1="⩽̸",nles $ 1="⩽̸",nless $ 1="≮",nLl $ 1="⋘̸",nlsim $ 1="≴",nLt $ 1="≪⃒",nlt $ 1="≮",nltri $ 1="⋪",nltrie $ 1="⋬",nLtv $ 1="≪̸",nmid $ 1="∤",NoBreak $ 1=" ",NonBreakingSpace $ 1=" ",nopf $ 1="𝕟 ",Nopf $ 1="ℕ ",Not $ 1="⫬",not $ 3="¬",NotCongruent $ 1="≢",NotCupCap $ 1="≭",NotDoubleVerticalBar $ 1="∦",NotElement $ 1="∉",NotEqual $ 1="≠",NotEqualTilde $ 1="≂̸",NotExists $ 1="∄",NotGreater $ 1="≯",NotGreaterEqual $ 1="≱",NotGreaterFullEqual $ 1="≧̸",NotGreaterGreater $ 1="≫̸",NotGreaterLess $ 1="≹",NotGreaterSlantEqual $ 1="⩾̸",NotGreaterTilde $ 1="≵",NotHumpDownHump $ 1="≎̸",NotHumpEqual $ 1="≏̸",notin $ 1="∉",notindot $ 1="⋵̸",notinE $ 1="⋹̸",notinva $ 1="∉",notinvb $ 1="⋷",notinvc $ 1="⋶",NotLeftTriangleBar $ 1="⧏̸",NotLeftTriangle $ 1="⋪",NotLeftTriangleEqual $ 1="⋬",NotLess $ 1="≮",NotLessEqual $ 1="≰",NotLessGreater $ 1="≸",NotLessLess $ 1="≪̸",NotLessSlantEqual $ 1="⩽̸",NotLessTilde $ 1="≴",NotNestedGreaterGreater $ 1="⪢̸",NotNestedLessLess $ 1="⪡̸",notni $ 1="∌",notniva $ 1="∌",notnivb $ 1="⋾",notnivc $ 1="⋽",NotPrecedes $ 1="⊀",NotPrecedesEqual $ 1="⪯̸",NotPrecedesSlantEqual $ 1="⋠",NotReverseElement $ 1="∌",NotRightTriangleBar $ 1="⧐̸",NotRightTriangle $ 1="⋫",NotRightTriangleEqual $ 1="⋭",NotSquareSubset $ 1="⊏̸",NotSquareSubsetEqual $ 1="⋢",NotSquareSuperset $ 1="⊐̸",NotSquareSupersetEqual $ 1="⋣",NotSubset $ 1="⊂⃒",NotSubsetEqual $ 1="⊈",NotSucceeds $ 1="⊁",NotSucceedsEqual $ 1="⪰̸",NotSucceedsSlantEqual $ 1="⋡",NotSucceedsTilde $ 1="≿̸",NotSuperset $ 1="⊃⃒",NotSupersetEqual $ 1="⊉",NotTilde $ 1="≁",NotTildeEqual $ 1="≄",NotTildeFullEqual $ 1="≇",NotTildeTilde $ 1="≉",NotVerticalBar $ 1="∤",nparallel $ 1="∦",npar $ 1="∦",nparsl $ 1="⫽⃥",npart $ 1="∂̸",npolint $ 1="⨔",npr $ 1="⊀",nprcue $ 1="⋠",nprec $ 1="⊀",npreceq $ 1="⪯̸",npre $ 1="⪯̸",nrarrc $ 1="⤳̸",nrarr $ 1="↛",nrArr $ 1="⇏",nrarrw $ 1="↝̸",nrightarrow $ 1="↛",nRightarrow $ 1="⇏",nrtri $ 1="⋫",nrtrie $ 1="⋭",nsc $ 1="⊁",nsccue $ 1="⋡",nsce $ 1="⪰̸",Nscr $ 1="𝒩 ",nscr $ 1="𝓃 ",nshortmid $ 1="∤",nshortparallel $ 1="∦",nsim $ 1="≁",nsime $ 1="≄",nsimeq $ 1="≄",nsmid $ 1="∤",nspar $ 1="∦",nsqsube $ 1="⋢",nsqsupe $ 1="⋣",nsub $ 1="⊄",nsubE $ 1="⫅̸",nsube $ 1="⊈",nsubset $ 1="⊂⃒",nsubseteq $ 1="⊈",nsubseteqq $ 1="⫅̸",nsucc $ 1="⊁",nsucceq $ 1="⪰̸",nsup $ 1="⊅",nsupE $ 1="⫆̸",nsupe $ 1="⊉",nsupset $ 1="⊃⃒",nsupseteq $ 1="⊉",nsupseteqq $ 1="⫆̸",ntgl $ 1="≹",Ntilde $ 3="Ñ",ntilde $ 3="ñ",ntlg $ 1="≸",ntriangleleft $ 1="⋪",ntrianglelefteq $ 1="⋬",ntriangleright $ 1="⋫",ntrianglerighteq $ 1="⋭",Nu $ 4="Ν ",nu $ 6="ν ",num $ 1="#",numero $ 1="№",numsp $ 1=" ",nvap $ 1="≍⃒",nvdash $ 1="⊬",nvDash $ 1="⊭",nVdash $ 1="⊮",nVDash $ 1="⊯",nvge $ 1="≥⃒",nvgt $ 1=">⃒",nvHarr $ 1="⤄",nvinfin $ 1="⧞",nvlArr $ 1="⤂",nvle $ 1="≤⃒",nvlt $ 1="<⃒",nvltrie $ 1="⊴⃒",nvrArr $ 1="⤃",nvrtrie $ 1="⊵⃒",nvsim $ 1="∼⃒",nwarhk $ 1="⤣",nwarr $ 1="↖",nwArr $ 1="⇖",nwarrow $ 1="↖",nwnear $ 1="⤧",Oacute $ 3="Ó",oacute $ 3="ó",oast $ 1="⊛",Ocirc $ 3="Ô",ocirc $ 3="ô",ocir $ 1="⊚",Ocy $ 1="О ",ocy $ 1="о ",odash $ 1="⊝",Odblac $ 1="Ő",odblac $ 1="ő",odiv $ 1="⨸",odot $ 1="⊙",odsold $ 1="⦼",OElig $ 1="Œ",oelig $ 1="œ",ofcir $ 1="⦿",Ofr $ 1="𝔒 ",ofr $ 1="𝔬 ",ogon $ 1="˛ ",Ograve $ 3="Ò",ograve $ 3="ò",ogt $ 1="⧁",ohbar $ 1="⦵",ohm $ 1="Ω",oint $ 1="∮",olarr $ 1="↺",olcir $ 1="⦾",olcross $ 1="⦻",oline $ 1="‾",olt $ 1="⧀",Omacr $ 1="Ō",omacr $ 1="ō",Omega $ 1="Ω",omega $ 1="ω",Omicron $ 1="Ο ",omicron $ 1="ο ",omid $ 1="⦶",ominus $ 1="⊖",Oopf $ 1="𝕆 ",oopf $ 1="𝕠 ",opar $ 1="⦷",OpenCurlyDoubleQuote $ 1="“",OpenCurlyQuote $ 1="‘ ",operp $ 1="⦹",oplus
` :sd(cd.children):(0,qa.isCDATA)(cd)?sd(cd.children):(0,qa.isText)(cd)?cd.data:""}stringify $ 2.getText=sd;function od(cd){return Array.isArray(cd)?cd.map(od).join(""):(0,qa.hasChildren)(cd)&&!(0,qa.isComment)(cd)?od(cd.children):(0,qa.isText)(cd)?cd.data:""}stringify $ 2.textContent=od;function ld(cd){return Array.isArray(cd)?cd.map(ld).join(""):(0,qa.hasChildren)(cd)&&(cd.type===ed.ElementType.Tag||(0,qa.isCDATA)(cd))?ld(cd.children):(0,qa.isText)(cd)?cd.data:""}return stringify $ 2.innerText=ld,stringify $ 2}var traversal={},hasRequiredTraversal;function requireTraversal(){if(hasRequiredTraversal)return traversal;hasRequiredTraversal=1,Object.defineProperty(traversal,"__esModule",{value:!0}),traversal.prevElementSibling=traversal.nextElementSibling=traversal.getName=traversal.hasAttrib=traversal.getAttributeValue=traversal.getSiblings=traversal.getParent=traversal.getChildren=void 0;var Ra=requireLib $ a(),qa=[];function Ja(ud){var _d;return(_d=ud.children)!==null&&_d!==void 0?_d:qa}traversal.getChildren=Ja;function ed(ud){return ud.parent||null}traversal.getParent=ed;function td(ud){var _d,yd,gd=ed(ud);if(gd!=null)return Ja(gd);for(var Ed=[ud],Td=ud.prev,Od=ud.next;Td!=null;)Ed.unshift(Td),_d=Td,Td=_d.prev;for(;Od!=null;)Ed.push(Od),yd=Od,Od=yd.next;return Ed}traversal.getSiblings=td;function rd(ud,_d){var yd;return(yd=ud.attribs)===null||yd===void 0?void 0:yd[_d]}traversal.getAttributeValue=rd;function sd(ud,_d){return ud.attribs!=null&&Object.prototype.hasOwnProperty.call(ud.attribs,_d)&&ud.attribs[_d]!=null}traversal.hasAttrib=sd;function od(ud){return ud.name}traversal.getName=od;function ld(ud){for(var _d,yd=ud.next;yd!==null&&!(0,Ra.isTag)(yd);)_d=yd,yd=_d.next;return yd}traversal.nextElementSibling=ld;function cd(ud){for(var _d,yd=ud.prev;yd!==null&&!(0,Ra.isTag)(yd);)_d=yd,yd=_d.prev;return yd}return traversal.prevElementSibling=cd,traversal}var manipulation $ 1={},hasRequiredManipulation $ 1;function requireManipulation $ 1(){if(hasRequiredManipulation $ 1)return manipulation $ 1;hasRequiredManipulation $ 1=1,Object.defineProperty(manipulation $ 1,"__esModule",{value:!0}),manipulation $ 1.prepend=manipulation $ 1.prependChild=manipulation $ 1.append=manipulation $ 1.appendChild=manipulation $ 1.replaceElement=manipulation $ 1.removeElement=void 0;function Ra(sd){if(sd.prev&&(sd.prev.next=sd.next),sd.next&&(sd.next.prev=sd.prev),sd.parent){var od=sd.parent.children;od.splice(od.lastIndexOf(sd),1)}}manipulation $ 1.removeElement=Ra;function qa(sd,od){var ld=od.prev=sd.prev;ld&&(ld.next=od);var cd=od.next=sd.next;cd&&(cd.prev=od);var ud=od.parent=sd.parent;if(ud){var _d=ud.children;_d[_d.lastIndexOf(sd)]=od}}manipulation $ 1.replaceElement=qa;function Ja(sd,od){if(Ra(od),od.next=null,od.parent=sd,sd.children.push(od)>1){var ld=sd.children[sd.children.length-2];ld.next=od,od.prev=ld}else od.prev=null}manipulation $ 1.appendChild=Ja;function ed(sd,od){Ra(od);var ld=sd.parent,cd=sd.next;if(od.next=cd,od.prev=sd,sd.next=od,od.parent=ld,cd){if(cd.prev=od,ld){var ud=ld.children;ud.splice(ud.lastIndexOf(cd),0,od)}}else ld&&ld.children.push(od)}manipulation $ 1.append=ed;function td(sd,od){if(Ra(od),od.parent=sd,od.prev=null,sd.children.unshift(od)!==1){var ld=sd.children[1];ld.prev=od,od.next=ld}else od.next=null}manipulation $ 1.prependChild=td;function rd(sd,od){Ra(od);var ld=sd.parent;if(ld){var cd=ld.children;cd.splice(cd.indexOf(sd),0,od)}sd.prev&&(sd.prev.next=od),od.parent=ld,od.prev=sd.prev,od.next=sd,sd.prev=od}return manipulation $ 1.prepend=rd,manipulation $ 1}var querying={},hasRequiredQuerying;function requireQuerying(){if(hasRequiredQuerying)return querying;hasRequiredQuerying=1,Object.defineProperty(querying,"__esModule",{value:!0}),querying.findAll=querying.existsOne=querying.findOne=querying.findOneChild=querying.find=querying.filter=void 0;var Ra=requireLib $ a();function qa(od,ld,cd,ud){return cd===void 0&&(cd=!0),ud===void 0&&(ud=1/0),Array.isArray(ld)||(ld=[ld]),Ja(od,ld,cd,ud)}querying.filter=qa;function Ja(od,ld,cd,ud){for(var _d=[],yd=0,gd=ld;yd<gd.length;yd++){var Ed=gd[yd];if(od(Ed)&&(_d.push(Ed),--ud<=0))break;if(cd&&(0,Ra.hasChildren)(Ed)&&
2024-08-27 22:31:52 +08:00
: is ( button , input , select , textarea , optgroup , option ) [ disabled ] ,
optgroup [ disabled ] > option ,
fieldset [ disabled ] : not ( fieldset [ disabled ] legend : first - of - type * )
2024-09-08 17:22:36 +08:00
) ` ,enabled:":not(:disabled)",checked:":is(:is(input[type=radio], input[type=checkbox])[checked], option:selected)",required:":is(input, select, textarea)[required]",optional:":is(input, select, textarea):not([required])",selected:"option:is([selected], select:not([multiple]):not(:has(> option[selected])) > :first-of-type)",checkbox:"[type=checkbox]",file:"[type=file]",password:"[type=password]",radio:"[type=radio]",reset:"[type=reset]",image:"[type=image]",submit:"[type=submit]",parent:":not(:empty)",header:":is(h1, h2, h3, h4, h5, h6)",button:":is(button, input[type=button])",input:":is(input, textarea, select, button)",text:"input:is(:not([type!='']), [type=text])"}),aliases}var subselects={},hasRequiredSubselects;function requireSubselects(){return hasRequiredSubselects||(hasRequiredSubselects=1,function(Ra){var qa=commonjsGlobal&&commonjsGlobal.__spreadArray||function(od,ld,cd){if(cd||arguments.length===2)for(var ud=0,_d=ld.length,yd;ud<_d;ud++)(yd||!(ud in ld))&&(yd||(yd=Array.prototype.slice.call(ld,0,ud)),yd[ud]=ld[ud]);return od.concat(yd||Array.prototype.slice.call(ld))};Object.defineProperty(Ra,"__esModule",{value:!0}),Ra.subselects=Ra.getNextSiblings=Ra.ensureIsTag=Ra.PLACEHOLDER_ELEMENT=void 0;var Ja=requireBoolbase(),ed=requireProcedure();Ra.PLACEHOLDER_ELEMENT={};function td(od,ld){return od===Ja.falseFunc?Ja.falseFunc:function(cd){return ld.isTag(cd)&&od(cd)}}Ra.ensureIsTag=td;function rd(od,ld){var cd=ld.getSiblings(od);if(cd.length<=1)return[];var ud=cd.indexOf(od);return ud<0||ud===cd.length-1?[]:cd.slice(ud+1).filter(ld.isTag)}Ra.getNextSiblings=rd;var sd=function(od,ld,cd,ud,_d){var yd={xmlMode:!!cd.xmlMode,adapter:cd.adapter,equals:cd.equals},gd=_d(ld,yd,ud);return function(Ed){return gd(Ed)&&od(Ed)}};Ra.subselects={is:sd,matches:sd,where:sd,not:function(od,ld,cd,ud,_d){var yd={xmlMode:!!cd.xmlMode,adapter:cd.adapter,equals:cd.equals},gd=_d(ld,yd,ud);return gd===Ja.falseFunc?od:gd===Ja.trueFunc?Ja.falseFunc:function(Td){return!gd(Td)&&od(Td)}},has:function(od,ld,cd,ud,_d){var yd=cd.adapter,gd={xmlMode:!!cd.xmlMode,adapter:yd,equals:cd.equals},Ed=ld.some(function(Id){return Id.some(ed.isTraversal)})?[Ra.PLACEHOLDER_ELEMENT]:void 0,Td=_d(ld,gd,Ed);if(Td===Ja.falseFunc)return Ja.falseFunc;if(Td===Ja.trueFunc)return function(Id){return yd.getChildren(Id).some(yd.isTag)&&od(Id)};var Od=td(Td,yd),Rd=Td.shouldTestNextSiblings,Nd=Rd===void 0?!1:Rd;return Ed?function(Id){Ed[0]=Id;var Md=yd.getChildren(Id),Ld=Nd?qa(qa([],Md,!0),rd(Id,yd),!0):Md;return od(Id)&&yd.existsOne(Od,Ld)}:function(Id){return od(Id)&&yd.existsOne(Od,yd.getChildren(Id))}}}}(subselects)),subselects}var hasRequiredPseudoSelectors;function requirePseudoSelectors(){return hasRequiredPseudoSelectors||(hasRequiredPseudoSelectors=1,function(Ra){Object.defineProperty(Ra,"__esModule",{value:!0}),Ra.compilePseudoSelector=Ra.aliases=Ra.pseudos=Ra.filters=void 0;var qa=requireBoolbase(),Ja=require $ $ 0 $ 5,ed=requireFilters();Object.defineProperty(Ra,"filters",{enumerable:!0,get:function(){return ed.filters}});var td=requirePseudos();Object.defineProperty(Ra,"pseudos",{enumerable:!0,get:function(){return td.pseudos}});var rd=requireAliases();Object.defineProperty(Ra,"aliases",{enumerable:!0,get:function(){return rd.aliases}});var sd=requireSubselects();function od(ld,cd,ud,_d,yd){var gd=cd.name,Ed=cd.data;if(Array.isArray(Ed))return sd.subselects[gd](ld,Ed,ud,_d,yd);if(gd in rd.aliases){if(Ed!=null)throw new Error("Pseudo ".concat(gd," doesn't have any arguments"));var Td=(0,Ja.parse)(rd.aliases[gd]);return sd.subselects.is(ld,Td,ud,_d,yd)}if(gd in ed.filters)return ed.filters[gd](ld,Ed,ud,_d);if(gd in td.pseudos){var Od=td.pseudos[gd];return(0,td.verifyPseudoArgs)(Od,gd,Ed),Od===qa.falseFunc?qa.falseFunc:ld===qa.trueFunc?function(Rd){return Od(Rd,ud,Ed)}:function(Rd){return Od(Rd,ud,Ed)&&ld(Rd)}}throw new Error("unmatched pseudo-class :".concat(gd))}Ra.compilePseudoSelector=od}(pseudoSelectors)),pseudoSelectors}var hasRequiredGeneral;function requireGeneral(){if(hasRequiredGeneral)return general;hasRequiredGeneral=1,Object.defineProperty(general,"
2024-09-07 10:27:05 +08:00
` ,nexist="∄",nexists="∄",Nfr="𝔑 ",nfr="𝔫 ",ngE="≧̸",nge="≱",ngeq="≱",ngeqq="≧̸",ngeqslant="⩾̸",nges="⩾̸",nGg="⋙̸",ngsim="≵",nGt="≫⃒",ngt="≯",ngtr="≯",nGtv="≫̸",nharr="↮",nhArr="⇎",nhpar="⫲",ni $ 5="∋",nis="⋼",nisd="⋺",niv="∋",NJcy="Њ",njcy="њ",nlarr="↚",nlArr="⇍",nldr="‥",nlE="≦̸",nle="≰",nleftarrow="↚",nLeftarrow="⇍",nleftrightarrow="↮",nLeftrightarrow="⇎",nleq="≰",nleqq="≦̸",nleqslant="⩽̸",nles="⩽̸",nless="≮",nLl="⋘̸",nlsim="≴",nLt="≪⃒",nlt="≮",nltri="⋪",nltrie="⋬",nLtv="≪̸",nmid="∤",NoBreak=" ",NonBreakingSpace=" ",nopf="𝕟 ",Nopf="ℕ ",Not="⫬",not $ 1="¬",NotCongruent="≢",NotCupCap="≭",NotDoubleVerticalBar="∦",NotElement="∉",NotEqual="≠",NotEqualTilde="≂̸",NotExists="∄",NotGreater="≯",NotGreaterEqual="≱",NotGreaterFullEqual="≧̸",NotGreaterGreater="≫̸",NotGreaterLess="≹",NotGreaterSlantEqual="⩾̸",NotGreaterTilde="≵",NotHumpDownHump="≎̸",NotHumpEqual="≏̸",notin="∉",notindot="⋵̸",notinE="⋹̸",notinva="∉",notinvb="⋷",notinvc="⋶",NotLeftTriangleBar="⧏̸",NotLeftTriangle="⋪",NotLeftTriangleEqual="⋬",NotLess="≮",NotLessEqual="≰",NotLessGreater="≸",NotLessLess="≪̸",NotLessSlantEqual="⩽̸",NotLessTilde="≴",NotNestedGreaterGreater="⪢̸",NotNestedLessLess="⪡̸",notni="∌",notniva="∌",notnivb="⋾",notnivc="⋽",NotPrecedes="⊀",NotPrecedesEqual="⪯̸",NotPrecedesSlantEqual="⋠",NotReverseElement="∌",NotRightTriangleBar="⧐̸",NotRightTriangle="⋫",NotRightTriangleEqual="⋭",NotSquareSubset="⊏̸",NotSquareSubsetEqual="⋢",NotSquareSuperset="⊐̸",NotSquareSupersetEqual="⋣",NotSubset="⊂⃒",NotSubsetEqual="⊈",NotSucceeds="⊁",NotSucceedsEqual="⪰̸",NotSucceedsSlantEqual="⋡",NotSucceedsTilde="≿̸",NotSuperset="⊃⃒",NotSupersetEqual="⊉",NotTilde="≁",NotTildeEqual="≄",NotTildeFullEqual="≇",NotTildeTilde="≉",NotVerticalBar="∤",nparallel="∦",npar="∦",nparsl="⫽⃥",npart="∂̸",npolint="⨔",npr="⊀",nprcue="⋠",nprec="⊀",npreceq="⪯̸",npre="⪯̸",nrarrc="⤳̸",nrarr="↛",nrArr="⇏",nrarrw="↝̸",nrightarrow="↛",nRightarrow="⇏",nrtri="⋫",nrtrie="⋭",nsc="⊁",nsccue="⋡",nsce="⪰̸",Nscr="𝒩 ",nscr="𝓃 ",nshortmid="∤",nshortparallel="∦",nsim="≁",nsime="≄",nsimeq="≄",nsmid="∤",nspar="∦",nsqsube="⋢",nsqsupe="⋣",nsub="⊄",nsubE="⫅̸",nsube="⊈",nsubset="⊂⃒",nsubseteq="⊈",nsubseteqq="⫅̸",nsucc="⊁",nsucceq="⪰̸",nsup="⊅",nsupE="⫆̸",nsupe="⊉",nsupset="⊃⃒",nsupseteq="⊉",nsupseteqq="⫆̸",ntgl="≹",Ntilde $ 1="Ñ",ntilde $ 1="ñ",ntlg="≸",ntriangleleft="⋪",ntrianglelefteq="⋬",ntriangleright="⋫",ntrianglerighteq="⋭",Nu $ 3="Ν ",nu $ 5="ν ",num="#",numero="№",numsp=" ",nvap="≍⃒",nvdash="⊬",nvDash="⊭",nVdash="⊮",nVDash="⊯",nvge="≥⃒",nvgt=">⃒",nvHarr="⤄",nvinfin="⧞",nvlArr="⤂",nvle="≤⃒",nvlt="<⃒",nvltrie="⊴⃒",nvrArr="⤃",nvrtrie="⊵⃒",nvsim="∼⃒",nwarhk="⤣",nwarr="↖",nwArr="⇖",nwarrow="↖",nwnear="⤧",Oacute $ 1="Ó",oacute $ 1="ó",oast="⊛",Ocirc $ 1="Ô",ocirc $ 1="ô",ocir="⊚",Ocy="О ",ocy="о ",odash="⊝",Odblac="Ő",odblac="ő",odiv="⨸",odot="⊙",odsold="⦼",OElig="Œ",oelig="œ",ofcir="⦿",Ofr="𝔒 ",ofr="𝔬 ",ogon="˛ ",Ograve $ 1="Ò",ograve $ 1="ò",ogt="⧁",ohbar="⦵",ohm="Ω",oint="∮",olarr="↺",olcir="⦾",olcross="⦻",oline="‾",olt="⧀",Omacr="Ō",omacr="ō",Omega="Ω",omega="ω",Omicron="Ο ",omicron="ο ",omid="⦶",ominus="⊖",Oopf="𝕆 ",oopf="𝕠 ",opar="⦷",OpenCurlyDoubleQuote="“",OpenCurlyQuote="‘ ",operp="⦹",oplus="⊕",orarr="↻",Or $ 4="⩔",or $ 3="∨ ",ord="⩝",order="ℴ ",orderof="ℴ ",ordf $ 1="ª",ordm $ 1="º",origof="⊶",oror="⩖",orslope="⩗",orv="⩛",oS="Ⓢ",Oscr="𝒪 ",oscr="ℴ ",Oslash $ 1="Ø",oslash $ 1="ø",osol="⊘",Otilde $ 1="Õ",otilde $ 1="õ",otimesas="⨶",Otimes="⨷",otimes="⊗",Ouml $ 1="Ö",ouml $ 1="ö",ovbar="⌽",OverBar="‾",OverBrace="⏞",OverBracket="⎴",OverParenthesis="⏜",para $ 1="¶",parallel $ 1="∥",par="∥",parsim="⫳",parsl="
2024-09-08 17:22:36 +08:00
` ||Tf===" "||Tf===" \f "||Tf===" \r "}function sd(Tf){return Tf>="a"&&Tf<="z"||Tf>="A"&&Tf<="Z"}function od(Tf,wf,Wf){var Uf=Tf.toLowerCase();return Tf===Uf?function(gf,_f){_f===Uf?gf._state=wf:(gf._state=Wf,gf._index--)}:function(gf,_f){_f===Uf||_f===Tf?gf._state=wf:(gf._state=Wf,gf._index--)}}function ld(Tf,wf){var Wf=Tf.toLowerCase();return function(Uf,gf){gf===Wf||gf===Tf?Uf._state=wf:(Uf._state=3,Uf._index--)}}var cd=od("C",24,16),ud=od("D",25,16),_d=od("A",26,16),yd=od("T",27,16),gd=od("A",28,16),Ed=ld("R",35),Td=ld("I",36),Od=ld("P",37),Rd=ld("T",38),Nd=od("R",40,1),Id=od("I",41,1),Md=od("P",42,1),Ld=od("T",43,1),Pd=ld("Y",45),qd=ld("L",46),Yd=ld("E",47),Ud=od("Y",49,1),Hd=od("L",50,1),zd=od("E",51,1),Jd=ld("I",54),Zd=ld("T",55),pf=ld("L",56),Qd=ld("E",57),hf=od("I",58,1),mf=od("T",59,1),xf=od("L",60,1),Lf=od("E",61,1),Kf=od("#",63,64),Yf=od("X",66,65),Of=function(){function Tf(wf,Wf){var Uf;this._state=1,this.buffer="",this.sectionStart=0,this._index=0,this.bufferOffset=0,this.baseState=1,this.special=1,this.running=!0,this.ended=!1,this.cbs=Wf,this.xmlMode=!!(wf!=null&&wf.xmlMode),this.decodeEntities=(Uf=wf==null?void 0:wf.decodeEntities)!==null&&Uf!==void 0?Uf:!0}return Tf.prototype.reset=function(){this._state=1,this.buffer="",this.sectionStart=0,this._index=0,this.bufferOffset=0,this.baseState=1,this.special=1,this.running=!0,this.ended=!1},Tf.prototype.write=function(wf){this.ended&&this.cbs.onerror(Error(".write() after done!")),this.buffer+=wf,this.parse()},Tf.prototype.end=function(wf){this.ended&&this.cbs.onerror(Error(".end() after done!")),wf&&this.write(wf),this.ended=!0,this.running&&this.finish()},Tf.prototype.pause=function(){this.running=!1},Tf.prototype.resume=function(){this.running=!0,this._index<this.buffer.length&&this.parse(),this.ended&&this.finish()},Tf.prototype.getAbsoluteIndex=function(){return this.bufferOffset+this._index},Tf.prototype.stateText=function(wf){wf==="<"?(this._index>this.sectionStart&&this.cbs.ontext(this.getSection()),this._state=2,this.sectionStart=this._index):this.decodeEntities&&wf==="&"&&(this.special===1||this.special===4)&&(this._index>this.sectionStart&&this.cbs.ontext(this.getSection()),this.baseState=1,this._state=62,this.sectionStart=this._index)},Tf.prototype.isTagStartChar=function(wf){return sd(wf)||this.xmlMode&&!rd(wf)&&wf!=="/"&&wf!==">"},Tf.prototype.stateBeforeTagName=function(wf){wf==="/"?this._state=5:wf==="<"?(this.cbs.ontext(this.getSection()),this.sectionStart=this._index):wf===">"||this.special!==1||rd(wf)?this._state=1:wf==="!"?(this._state=15,this.sectionStart=this._index+1):wf==="?"?(this._state=17,this.sectionStart=this._index+1):this.isTagStartChar(wf)?(this._state=!this.xmlMode&&(wf==="s"||wf==="S")?32:!this.xmlMode&&(wf==="t"||wf==="T")?52:3,this.sectionStart=this._index):this._state=1},Tf.prototype.stateInTagName=function(wf){(wf==="/"||wf===">"||rd(wf))&&(this.emitToken("onopentagname"),this._state=8,this._index--)},Tf.prototype.stateBeforeClosingTagName=function(wf){rd(wf)||(wf===">"?this._state=1:this.special!==1?this.special!==4&&(wf==="s"||wf==="S")?this._state=33:this.special===4&&(wf==="t"||wf==="T")?this._state=53:(this._state=1,this._index--):this.isTagStartChar(wf)?(this._state=6,this.sectionStart=this._index):(this._state=20,this.sectionStart=this._index))},Tf.prototype.stateInClosingTagName=function(wf){(wf===">"||rd(wf))&&(this.emitToken("onclosetag"),this._state=7,this._index--)},Tf.prototype.stateAfterClosingTagName=function(wf){wf===">"&&(this._state=1,this.sectionStart=this._index+1)},Tf.prototype.stateBeforeAttributeName=function(wf){wf===">"?(this.cbs.onopentagend(),this._state=1,this.sectionStart=this._index+1):wf==="/"?this._state=4:rd(wf)||(this._state=9,this.sectionStart=this._index)},Tf.prototype.stateInSelfClosingTag=function(wf){wf===">"?(this.cbs.onselfclosingtag(),this._state=1,this.sectionStart=this._index+1,this.special=1):rd(wf)||(this._state=8,this._index--)},Tf.prototype.stateInAttributeName=function(wf){(wf==="="||wf==="/"||wf===">"||rd(wf))&&(this.cbs.onattribname(this.getSection()),this.sectionStart=-1,th
2024-09-03 08:22:14 +08:00
` ||sd===" \r "&&this.html[rd+1]!== `
2024-09-08 17:22:36 +08:00
` )&&(ed.isEol=!0),ed.col=rd-ed.lineStartPos+1,ed.offset=ed.droppedBufferSize+rd,td.advance.call(this)},retreat(){td.retreat.call(this),ed.isEol=!1,ed.col=this.pos-ed.lineStartPos+1},dropParsedChunk(){const rd=this.pos;td.dropParsedChunk.call(this);const sd=rd-this.pos;ed.lineStartPos-=sd,ed.droppedBufferSize+=sd,ed.offset=ed.droppedBufferSize+this.pos}}}}return preprocessorMixin $ 1=qa,preprocessorMixin $ 1}var tokenizerMixin $ 1,hasRequiredTokenizerMixin $ 1;function requireTokenizerMixin $ 1(){if(hasRequiredTokenizerMixin $ 1)return tokenizerMixin $ 1;hasRequiredTokenizerMixin $ 1=1;const Ra=requireMixin(),qa=requireTokenizer(),Ja=requirePreprocessorMixin $ 1();class ed extends Ra{constructor(rd){super(rd),this.tokenizer=rd,this.posTracker=Ra.install(rd.preprocessor,Ja),this.currentAttrLocation=null,this.ctLoc=null}_getCurrentLocation(){return{startLine:this.posTracker.line,startCol:this.posTracker.col,startOffset:this.posTracker.offset,endLine:-1,endCol:-1,endOffset:-1}}_attachCurrentAttrLocationInfo(){this.currentAttrLocation.endLine=this.posTracker.line,this.currentAttrLocation.endCol=this.posTracker.col,this.currentAttrLocation.endOffset=this.posTracker.offset;const rd=this.tokenizer.currentToken,sd=this.tokenizer.currentAttr;rd.location.attrs||(rd.location.attrs=Object.create(null)),rd.location.attrs[sd.name]=this.currentAttrLocation}_getOverriddenMethods(rd,sd){const od={_createStartTagToken(){sd._createStartTagToken.call(this),this.currentToken.location=rd.ctLoc},_createEndTagToken(){sd._createEndTagToken.call(this),this.currentToken.location=rd.ctLoc},_createCommentToken(){sd._createCommentToken.call(this),this.currentToken.location=rd.ctLoc},_createDoctypeToken(ld){sd._createDoctypeToken.call(this,ld),this.currentToken.location=rd.ctLoc},_createCharacterToken(ld,cd){sd._createCharacterToken.call(this,ld,cd),this.currentCharacterToken.location=rd.ctLoc},_createEOFToken(){sd._createEOFToken.call(this),this.currentToken.location=rd._getCurrentLocation()},_createAttr(ld){sd._createAttr.call(this,ld),rd.currentAttrLocation=rd._getCurrentLocation()},_leaveAttrName(ld){sd._leaveAttrName.call(this,ld),rd._attachCurrentAttrLocationInfo()},_leaveAttrValue(ld){sd._leaveAttrValue.call(this,ld),rd._attachCurrentAttrLocationInfo()},_emitCurrentToken(){const ld=this.currentToken.location;this.currentCharacterToken&&(this.currentCharacterToken.location.endLine=ld.startLine,this.currentCharacterToken.location.endCol=ld.startCol,this.currentCharacterToken.location.endOffset=ld.startOffset),this.currentToken.type===qa.EOF_TOKEN?(ld.endLine=ld.startLine,ld.endCol=ld.startCol,ld.endOffset=ld.startOffset):(ld.endLine=rd.posTracker.line,ld.endCol=rd.posTracker.col+1,ld.endOffset=rd.posTracker.offset+1),sd._emitCurrentToken.call(this)},_emitCurrentCharacterToken(){const ld=this.currentCharacterToken&&this.currentCharacterToken.location;ld&&ld.endOffset===-1&&(ld.endLine=rd.posTracker.line,ld.endCol=rd.posTracker.col,ld.endOffset=rd.posTracker.offset),sd._emitCurrentCharacterToken.call(this)}};return Object.keys(qa.MODE).forEach(ld=>{const cd=qa.MODE[ld];od[cd]=function(ud){rd.ctLoc=rd._getCurrentLocation(),sd[cd].call(this,ud)}}),od}}return tokenizerMixin $ 1=ed,tokenizerMixin $ 1}var openElementStackMixin,hasRequiredOpenElementStackMixin;function requireOpenElementStackMixin(){if(hasRequiredOpenElementStackMixin)return openElementStackMixin;hasRequiredOpenElementStackMixin=1;const Ra=requireMixin();class qa extends Ra{constructor(ed,td){super(ed),this.onItemPop=td.onItemPop}_getOverriddenMethods(ed,td){return{pop(){ed.onItemPop(this.current),td.pop.call(this)},popAllUpToHtmlElement(){for(let rd=this.stackTop;rd>0;rd--)ed.onItemPop(this.items[rd]);td.popAllUpToHtmlElement.call(this)},remove(rd){ed.onItemPop(this.current),td.remove.call(this,rd)}}}}return openElementStackMixin=qa,openElementStackMixin}var parserMixin $ 1,hasRequiredParserMixin $ 1;function requireParserMixin $ 1(){if(hasRequiredParserMixin $ 1)return parserMixin $ 1;hasRequiredParserMixin $ 1=1;const Ra=requireMixin(),qa=requireTokenizer(),Ja=requireTokenizerMixin $ 1(),ed=requireOpenElementStackMixin(
` )){if(Bf.chars.length===1)continue;Bf.chars=Bf.chars.substr(1)}if(this._processInputToken(Bf),Mf&&this.pendingScript)break}}runParsingLoopForCurrentChunk(Mf,Bf){if(this._runParsingLoop(Bf),Bf&&this.pendingScript){const Fm=this.pendingScript;this.pendingScript=null,Bf(Fm);return}Mf&&Mf()}_setupTokenizerCDATAMode(){const Mf=this._getAdjustedCurrentElement();this.tokenizer.allowCDATA=Mf&&Mf!==this.document&&this.treeAdapter.getNamespaceURI(Mf)!==Ed.HTML&&!this._isIntegrationPoint(Mf)}_switchToTextParsing(Mf,Bf){this._insertElement(Mf,Ed.HTML),this.tokenizer.state=Bf,this.originalInsertionMode=this.insertionMode,this.insertionMode=zd}switchToPlaintextParsing(){this.insertionMode=zd,this.originalInsertionMode=Hd,this.tokenizer.state=Ra.MODE.PLAINTEXT}_getAdjustedCurrentElement(){return this.openElements.stackTop===0&&this.fragmentContext?this.fragmentContext:this.openElements.current}_findFormInFragmentContext(){let Mf=this.fragmentContext;do{if(this.treeAdapter.getTagName(Mf)===gd.FORM){this.formElement=Mf;break}Mf=this.treeAdapter.getParentNode(Mf)}while(Mf)}_initTokenizerForFragmentParsing(){if(this.treeAdapter.getNamespaceURI(this.fragmentContext)===Ed.HTML){const Mf=this.treeAdapter.getTagName(this.fragmentContext);Mf===gd.TITLE||Mf===gd.TEXTAREA?this.tokenizer.state=Ra.MODE.RCDATA:Mf===gd.STYLE||Mf===gd.XMP||Mf===gd.IFRAME||Mf===gd.NOEMBED||Mf===gd.NOFRAMES||Mf===gd.NOSCRIPT?this.tokenizer.state=Ra.MODE.RAWTEXT:Mf===gd.SCRIPT?this.tokenizer.state=Ra.MODE.SCRIPT_DATA:Mf===gd.PLAINTEXT&&(this.tokenizer.state=Ra.MODE.PLAINTEXT)}}_setDocumentType(Mf){const Bf=Mf.name||"",Fm=Mf.publicId||"",d_=Mf.systemId||"";this.treeAdapter.setDocumentType(this.document,Bf,Fm,d_)}_attachElementToTree(Mf){if(this._shouldFosterParentOnInsertion())this._fosterParentElement(Mf);else{const Bf=this.openElements.currentTmplContent||this.openElements.current;this.treeAdapter.appendChild(Bf,Mf)}}_appendElement(Mf,Bf){const Fm=this.treeAdapter.createElement(Mf.tagName,Bf,Mf.attrs);this._attachElementToTree(Fm)}_insertElement(Mf,Bf){const Fm=this.treeAdapter.createElement(Mf.tagName,Bf,Mf.attrs);this._attachElementToTree(Fm),this.openElements.push(Fm)}_insertFakeElement(Mf){const Bf=this.treeAdapter.createElement(Mf,Ed.HTML,[]);this._attachElementToTree(Bf),this.openElements.push(Bf)}_insertTemplate(Mf){const Bf=this.treeAdapter.createElement(Mf.tagName,Ed.HTML,Mf.attrs),Fm=this.treeAdapter.createDocumentFragment();this.treeAdapter.setTemplateContent(Bf,Fm),this._attachElementToTree(Bf),this.openElements.push(Bf)}_insertFakeRootElement(){const Mf=this.treeAdapter.createElement(gd.HTML,Ed.HTML,[]);this.treeAdapter.appendChild(this.openElements.current,Mf),this.openElements.push(Mf)}_appendCommentNode(Mf,Bf){const Fm=this.treeAdapter.createCommentNode(Mf.data);this.treeAdapter.appendChild(Bf,Fm)}_insertCharacters(Mf){if(this._shouldFosterParentOnInsertion())this._fosterParentText(Mf.chars);else{const Bf=this.openElements.currentTmplContent||this.openElements.current;this.treeAdapter.insertText(Bf,Mf.chars)}}_adoptNodes(Mf,Bf){for(let Fm=this.treeAdapter.getFirstChild(Mf);Fm;Fm=this.treeAdapter.getFirstChild(Mf))this.treeAdapter.detachNode(Fm),this.treeAdapter.appendChild(Bf,Fm)}_shouldProcessTokenInForeignContent(Mf){const Bf=this._getAdjustedCurrentElement();if(!Bf||Bf===this.document)return!1;const Fm=this.treeAdapter.getNamespaceURI(Bf);if(Fm===Ed.HTML||this.treeAdapter.getTagName(Bf)===gd.ANNOTATION_XML&&Fm===Ed.MATHML&&Mf.type===Ra.START_TAG_TOKEN&&Mf.tagName===gd.SVG)return!1;const d_=Mf.type===Ra.CHARACTER_TOKEN||Mf.type===Ra.NULL_CHARACTER_TOKEN||Mf.type===Ra.WHITESPACE_CHARACTER_TOKEN;return(Mf.type===Ra.START_TAG_TOKEN&&Mf.tagName!==gd.MGLYPH&&Mf.tagName!==gd.MALIGNMARK||d_)&&this._isIntegrationPoint(Bf,Ed.MATHML)||(Mf.type===Ra.START_TAG_TOKEN||d_)&&this._isIntegrationPoint(Bf,Ed.HTML)?!1:Mf.type!==Ra.EOF_TOKEN}_processToken(Mf){ $ f[this.insertionMode][Mf.type](this,Mf)}_processTokenInBodyMode(Mf){ $ f[Hd][Mf.type](this,Mf)}_processTokenInForeignContent(Mf){Mf.type===Ra.CHARACTER_TOKEN?u0(this,Mf):Mf.type===Ra.NULL_CHARACTER_TOKEN?l1(this,Mf)
2024-08-31 11:28:56 +08:00
` )}}):{name:_d,value:yd.replace(ed, ` \ r
2024-09-08 19:53:57 +08:00
` )}}).toArray()}return forms.serializeArray=rd,forms}var hasRequiredCheerio;function requireCheerio(){if(hasRequiredCheerio)return cheerio $ 1;hasRequiredCheerio=1,Object.defineProperty(cheerio $ 1,"__esModule",{value:!0}),cheerio $ 1.Cheerio=void 0;var Ra=require $ $ 0 $ 6,qa=Ra.__importDefault(requireParse()),Ja=Ra.__importDefault(requireOptions()),ed=requireUtils $ 2(),td=Ra.__importStar(requireAttributes()),rd=Ra.__importStar(requireTraversing()),sd=Ra.__importStar(requireManipulation()),od=Ra.__importStar(requireCss()),ld=Ra.__importStar(requireForms()),cd=function(){function _d(yd,gd,Ed,Td){var Od=this;if(Td===void 0&&(Td=Ja.default),this.length=0,this.options=Td,!yd)return this;if(Ed&&(typeof Ed=="string"&&(Ed=qa.default(Ed,this.options,!1)),this._root=new this.constructor(Ed,null,null,this.options),this._root._root=this._root),ed.isCheerio(yd))return yd;var Rd=typeof yd=="string"&&ed.isHtml(yd)?qa.default(yd,this.options,!1).children:ud(yd)?[yd]:Array.isArray(yd)?yd:null;if(Rd)return Rd.forEach(function(Md,Ld){Od[Ld]=Md}),this.length=Rd.length,this;var Nd=yd,Id=gd?typeof gd=="string"?ed.isHtml(gd)?this._make(qa.default(gd,this.options,!1)):(Nd=gd+" "+Nd,this._root):ed.isCheerio(gd)?gd:this._make(gd):this._root;return Id?Id.find(Nd):this}return _d.prototype._make=function(yd,gd){var Ed=new this.constructor(yd,gd,this._root,this.options);return Ed.prevObject=this,Ed},_d}();cheerio $ 1.Cheerio=cd,cd.prototype.cheerio="[cheerio object]",cd.prototype.splice=Array.prototype.splice,cd.prototype[Symbol.iterator]=Array.prototype[Symbol.iterator],Object.assign(cd.prototype,td,rd,sd,od,ld);function ud(_d){return!!_d.name||_d.type==="root"||_d.type==="text"||_d.type==="comment"}return cheerio $ 1}var hasRequiredLoad;function requireLoad(){if(hasRequiredLoad)return load;hasRequiredLoad=1,Object.defineProperty(load,"__esModule",{value:!0}),load.load=void 0;var Ra=require $ $ 0 $ 6,qa=Ra.__importStar(requireOptions()),Ja=Ra.__importStar(require_static()),ed=requireCheerio(),td=Ra.__importDefault(requireParse());function rd(sd,od,ld){if(ld===void 0&&(ld=!0),sd==null)throw new Error("cheerio.load() expects a string");var cd=Ra.__assign(Ra.__assign({},qa.default),qa.flatten(od)),ud=td.default(sd,cd,ld),_d=function(gd){Ra.__extends(Ed,gd);function Ed(){return gd!==null&&gd.apply(this,arguments)||this}return Ed}(ed.Cheerio);function yd(gd,Ed,Td,Od){return Td===void 0&&(Td=ud),new _d(gd,Ed,Td,Ra.__assign(Ra.__assign({},cd),qa.flatten(Od)))}return Object.assign(yd,Ja,{load:rd,_root:ud,_options:cd,fn:_d.prototype,prototype:_d.prototype}),yd}return load.load=rd,load}(function(Ra){Object.defineProperty(Ra,"__esModule",{value:!0}),Ra.root=Ra.parseHTML=Ra.merge=Ra.contains=void 0;var qa=require $ $ 0 $ 6;qa.__exportStar(requireTypes(),Ra),qa.__exportStar(requireLoad(),Ra);var Ja=requireLoad();Ra.default=Ja.load([]);var ed=qa.__importStar(require_static());Ra.contains=ed.contains,Ra.merge=ed.merge,Ra.parseHTML=ed.parseHTML,Ra.root=ed.root})(lib $ e);var utils $ 4={},lexer={exports:{}},debug={exports:{}};(function(Ra,qa){var Ja={version:"v20.17.0",versions:{node:"20.17.0",acorn:"8.11.3",ada:"2.9.0",ares:"1.32.3",base64:"0.5.2",brotli:"1.1.0",cjs_module_lexer:"1.2.2",cldr:"45.0",icu:"75.1",llhttp:"8.1.2",modules:"115",napi:"9",nghttp2:"1.61.0",nghttp3:"0.7.0",ngtcp2:"1.1.0",openssl:"3.0.13+quic",simdutf:"5.3.0",tz:"2024a",undici:"6.19.2",unicode:"15.1",uv:"1.46.0",uvwasi:"0.0.21",v8:"11.3.244.8-node.23",zlib:"1.3.0.1-motley-209717d"},arch:"x64",platform:"linux",release:{name:"node",lts:"Iron",sourceUrl:"https://nodejs.org/download/release/v20.17.0/node-v20.17.0.tar.gz",headersUrl:"https://nodejs.org/download/release/v20.17.0/node-v20.17.0-headers.tar.gz"},moduleLoadList:["Internal Binding builtins","Internal Binding module_wrap","Internal Binding errors","NativeModule internal/assert","Internal Binding util","NativeModule internal/errors","Internal Binding config","Internal Binding timers","Internal Binding async_wrap","Internal Binding task_queue","Internal Binding symbols","NativeModule internal/async_hooks","Internal Binding constants","Internal Binding types","Interna
2024-09-08 17:22:36 +08:00
` )}})(debug);var debugExports=debug.exports;(function(Ra,qa){debugExports("lex"),Ra.exports=Ja;function Ja(ed){var td="",rd,sd=0,od=-1,ld=0,cd=1,ud="before-selector",_d=[ud],yd={},gd=[],Ed=["media","keyframes",{name:"-webkit-keyframes",type:"keyframes",prefix:"-webkit-"},{name:"-moz-keyframes",type:"keyframes",prefix:"-moz-"},{name:"-ms-keyframes",type:"keyframes",prefix:"-ms-"},{name:"-o-keyframes",type:"keyframes",prefix:"-o-"},"font-face",{name:"import",state:"before-at-value"},{name:"charset",state:"before-at-value"},"supports","viewport",{name:"namespace",state:"before-at-value"},"document",{name:"-moz-document",type:"document",prefix:"-moz-"},"page"];function Td(){return Yd(),ed[od]}function Od(mf){return mf?_d[_d.length-1-mf]:ud}function Rd(mf){var xf=od+1;return mf===ed.slice(xf,xf+mf.length)}function Nd(mf){var xf=ed.slice(od).indexOf(mf);return xf>0?xf:!1}function Id(mf){return mf===Md(1)}function Md(mf){return ed[od+(mf||1)]}function Ld(){var mf=_d.pop();return ud=_d[_d.length-1],mf}function Pd(mf){return ud=mf,_d.push(ud),_d.length}function qd(mf){var xf=ud;return _d[_d.length-1]=ud=mf,xf}function Yd(mf){if((mf||1)==1)ed[od]== `
` ?(cd++,sd=1):sd++,od++;else{var xf=ed.slice(od,od+mf).split( `
` );xf.length>1&&(cd+=xf.length-1,sd=1),sd+=xf[xf.length-1].length,od=od+mf}}function Ud(){yd.end={line:cd,col:sd},gd.push(yd),td="",yd={}}function Hd(mf){yd={type:mf,start:{line:cd,col:sd}}}for(;rd=Td();)switch(rd){case" ":switch(Od()){case"selector":case"value":case"value-paren":case"at-group":case"at-value":case"comment":case"double-string":case"single-string":td+=rd;break}break;case `
` :case" ":case" \r ":case" \f ":switch(Od()){case"value":case"value-paren":case"at-group":case"comment":case"single-string":case"double-string":case"selector":td+=rd;break;case"at-value":rd=== `
` &&(yd.value=td.trim(),Ud(),Ld());break}break;case":":switch(Od()){case"name":yd.name=td.trim(),td="",qd("before-value");break;case"before-selector":td+=rd,Hd("selector"),Pd("selector");break;case"before-value":qd("value"),td+=rd;break;default:td+=rd;break}break;case";":switch(Od()){case"name":case"before-value":case"value":td.trim().length>0&&(yd.value=td.trim(),Ud()),qd("before-name");break;case"value-paren":td+=rd;break;case"at-value":yd.value=td.trim(),Ud(),Ld();break;case"before-name":break;default:td+=rd;break}break;case"{":switch(Od()){case"selector":if(Md(-1)===" \\ "){td+=rd;break}yd.text=td.trim(),Ud(),qd("before-name"),ld=ld+1;break;case"at-group":switch(yd.name=td.trim(),yd.type){case"font-face":case"viewport":case"page":Pd("before-name");break;default:Pd("before-selector")}Ud(),ld=ld+1;break;case"name":case"at-rule":yd.name=td.trim(),Ud(),Pd("before-name"),ld=ld+1;break;case"comment":case"double-string":case"single-string":td+=rd;break;case"before-value":qd("value"),td+=rd;break}break;case"}":switch(Od()){case"before-name":case"name":case"before-value":case"value":td&&(yd.value=td.trim()),yd.name&&yd.value&&Ud(),Hd("end"),Ud(),Ld(),Od()==="at-group"&&(Hd("at-group-end"),Ud(),Ld()),ld>0&&(ld=ld-1);break;case"at-group":case"before-selector":case"selector":if(Md(-1)===" \\ "){td+=rd;break}ld>0&&Od(1)==="at-group"&&(Hd("at-group-end"),Ud()),ld>1&&Ld(),ld>0&&(ld=ld-1);break;case"double-string":case"single-string":case"comment":td+=rd;break}break;case'"':case"'":switch(Od()){case"double-string":rd==='"'&&Md(-1)!==" \\ "&&Ld();break;case"single-string":rd==="'"&&Md(-1)!==" \\ "&&Ld();break;case"before-at-value":qd("at-value"),Pd(rd==='"'?"double-string":"single-string");break;case"before-value":qd("value"),Pd(rd==='"'?"double-string":"single-string");break;case"comment":break;default:Md(-1)!==" \\ "&&Pd(rd==='"'?"double-string":"single-string")}td+=rd;break;case"/":switch(Od()){case"comment":case"double-string":case"single-string":td+=rd;break;case"before-value":case"selector":case"name":case"value":if(Id("*")){var zd=Nd("*/");zd&&Yd(zd+1)}else Od()=="before-value"&&qd("value"),td+=rd;break;default:Id("*")?(Hd("comment"),Pd("comment"),Yd()):td+=rd;break}break;case"*":switch(Od()){case"comment":Id("/")?(yd.text=td,Yd(),Ud(),Ld()):td+=rd;break;case"before-selector":td+=rd,Hd("selector"),Pd("selector");break;case"before-value":qd("value"),td+=rd;break;default:td+=rd}break;case"@":switch(Od()){case"comment":case"double-string":case"single-string":td+=rd;break;case"before-value":qd("value"),td+=rd;break;default:for(var Jd=!1,Zd,pf,Qd=0,hf=Ed.length;!Jd&&Qd<hf;++Qd)pf=Ed[Qd],Zd=pf.name||pf,Rd(Zd)&&(Jd=!0,Hd(Zd),Pd(pf.state||"at-group"),Yd(Zd.length),pf.prefix&&(yd.prefix=pf.prefix),pf.type&&(yd.type=pf.type));Jd||(td+=rd);break}break;case"(":switch(Od()){case"value":Pd("value-paren");break;case"before-value":qd("value");break}td+=rd;break;case")":switch(Od()){case"value-paren":Ld();break;case"before-value":qd("value");break}td+=rd;break;default:switch(Od()){case"before-selector":Hd("selector"),Pd("selector");break;case"before-name":Hd("property"),qd("name");break;case"before-value":qd("value");break;case"before-at-value":qd("at-value");break}td+=rd;break}return gd}})(lexer);var lexerExports=lexer.exports,parser $ 2={exports:{}};(function(Ra,qa){debugExports("parse");var Ja=lexerExports;Ra.exports=od;var ed,td,rd,sd;function od(Ld,Pd){Pd||(Pd={}),ed=!!Pd.comments,rd=!!Pd.position,td=0,sd=Array.isArray(Ld)?Ld.slice():Ja(Ld);for(var qd,Yd=[],Ud;Ud=cd();)qd=Rd(Ud),qd&&Yd.push(qd);return{type:"stylesheet",stylesheet:{rules:Yd}}}function ld(Ld,Pd){Pd||(Pd={});for(var qd,Yd=["type","name","value"],Ud={},Hd=0;Hd<Yd.length;++Hd)qd=Yd[Hd],Ld[qd]&&(Ud[qd]=Pd[qd]||Ld[qd]);for(Yd=Object.keys(Pd),Hd=0;Hd<Yd.length;++Hd)qd=Yd[Hd],Ud[qd]||(Ud[qd]=Pd[qd]);return rd&&(Ud.position={start:Ld.start,end:Ld.end}),Ud}function cd(){var Ld=sd.shift();return Ld}function ud(Ld){td=td+1;var Pd={};switch(Ld.type){case"font-face":case"viewport":Pd.declarations=Id();break;case"page":Pd.prefix=Ld.prefix,Pd.declarations=Id();break;default:Pd.prefix=Ld.prefix,Pd.rul
` ,od=" ");var Pd=Ed(Md.stylesheet.rules,Nd).join( `
` ).trim();return Pd}function cd(Md){if(Md){rd+=Md;return}return ed?"":Array(rd).join(td||"")}function ud(Md){return"@"+Md.type+" "+Md.value+";"+sd}function _d(Md){var Ld="",Pd=Md.prefix||"";Md.name&&(Ld=" "+Md.name);var qd=Md.type!=="page";return"@"+Pd+Md.type+Ld+od+Td(Md,qd)+sd}function yd(Md){return Ja?"/*"+(Md.text||"")+"*/"+sd:""}function gd(Md){var Ld;return Md.selectors?Ld=Md.selectors.join(","+sd):(Ld="@"+Md.type,Ld+=Md.name?" "+Md.name:""),cd()+Ld+od+Td(Md)+sd}function Ed(Md,Ld){return Md.reduce(function(Pd,qd){var Yd=qd.type==="comment"?yd(qd):Ld(qd);return Yd&&Pd.push(Yd),Pd},[])}function Td(Md,Ld){var Pd=Md.declarations,qd=Rd;return Md.rules&&(Pd=Md.rules,qd=gd),Pd=Od(Pd,qd),Pd&&(Pd=sd+Pd+(Ld?"":sd)),"{"+Pd+cd()+"}"}function Od(Md,Ld){if(!Md)return"";cd(1);var Pd=Ed(Md,Ld);return cd(-1),Pd.length?Pd.join(sd):""}function Rd(Md){if(Md.type==="property")return Id(Md)}function Nd(Md){switch(Md.type){case"rule":return gd(Md);case"media":case"keyframes":return _d(Md);case"comment":return yd(Md);case"import":case"charset":case"namespace":return ud(Md);case"font-face":case"supports":case"viewport":case"document":case"page":return _d(Md)}}function Id(Md){var Ld=Md.name?Md.name+":"+od:"";return cd()+Ld+Md.value+";"}})(stringify $ 1);var stringifyExports=stringify $ 1.exports,mensch={lex:lexerExports,parse:parserExports,stringify:stringifyExports},selector={exports:{}},escapeRe=/([-.*+?^ ${ } ()|[ \] \/ \\ ])/g,unescapeRe=/ \\ /g,escape $ 1=function(Ra){return(Ra+"").replace(escapeRe," \\ $ 1")},unescape $ 1=function(Ra){return(Ra+"").replace(unescapeRe,"")},slickRe=RegExp( ` ^ ( ? : \ \ s * ( , ) \ \ s * | \ \ s * ( < combinator > + ) \ \ s * | ( \ \ s + ) | ( < unicode > + | \ \ * ) | \ \ # ( < unicode > + ) | \ \ . ( < unicode > + ) | \ \ [ \ \ s * ( < unicode1 > + ) ( ? : \ \ s * ( [ * ^ $ ! ~ | ] ? = ) ( ? : \ \ s * ( ? : ( [ "']?)(.*?)\\9)))?\\s*\\](?!\\])|(:+)(<unicode>+)(?:\\((?:(?:([" '])([^\\13]*)\\13)|((?:\\([^)]+\\)|[^()]*)+))\\))?)`.replace(/<combinator>/,"["+escape$1(">+~`!@$%^&={}\\;</")+"]").replace(/<unicode>/g,"(?:[\\w\\u00a1-\\uFFFF-]|\\\\[^\\s0-9a-f])").replace(/<unicode1>/g,"(?:[:\\w\\u00a1-\\uFFFF-]|\\\\[^\\s0-9a-f])")),Part=function(qa){this.combinator=qa||" ",this.tag="*"};Part.prototype.toString=function(){if(!this.raw){var Ra="",qa,Ja;if(Ra+=this.tag||"*",this.id&&(Ra+="#"+this.id),this.classes&&(Ra+="."+this.classList.join(".")),this.attributes)for(qa=0;Ja=this.attributes[qa++];)Ra+="["+Ja.name+(Ja.operator?Ja.operator+' "'+Ja.value+'" ' : "" ) + "]" ; if ( this . pseudos ) for ( qa = 0 ; Ja = this . pseudos [ qa ++ ] ; ) Ra += ":" + Ja . name , Ja . value && ( Ra += "(" + Ja . value + ")" ) ; this . raw = Ra } return this . raw } ; var Expression = function ( ) { this . length = 0 } ; Expression . prototype . toString = function ( ) { if ( ! this . raw ) { for ( var Ra = "" , qa = 0 , Ja ; Ja = this [ qa ++ ] ; ) qa !== 1 && ( Ra += " " ) , Ja . combinator !== " " && ( Ra += Ja . combinator + " " ) , Ra += Ja ; this . raw = Ra } return this . raw } ; var replacer = function ( Ra , qa , Ja , ed , td , rd , sd , od , ld , cd , ud , _d , yd , gd , Ed , Td ) { var Od , Rd ; if ( ( qa || ! this . length ) && ( Od = this [ this . length ++ ] = new Expression , qa ) ) return "" ; if ( Od || ( Od = this [ this . length - 1 ] ) , ( Ja || ed || ! Od . length ) && ( Rd = Od [ Od . length ++ ] = new Part ( Ja ) ) , Rd || ( Rd = Od [ Od . length - 1 ] ) , td ) Rd . tag = unescape$1 ( td ) ; else if ( rd ) Rd . id = unescape$1 ( rd ) ; else if ( sd ) { var Nd = unescape$1 ( sd ) , Id = Rd . classes || ( Rd . classes = { } ) ; if ( ! Id [ Nd ] ) { Id [ Nd ] = escape$1 ( sd ) ; var Md = Rd . classList || ( Rd . classList = [ ] ) ; Md . push ( Nd ) , Md . sort ( ) } } else yd ? ( Td = Td || Ed , ( Rd . pseudos || ( Rd . pseudos = [ ] ) ) . push ( { type : _d . length == 1 ? "class" : "element" , name : unescape$1 ( yd ) , escapedName : escape$1 ( yd ) , value : Td ? unescape$1 ( Td ) : null , escapedValue : Td ? escape$1 ( Td ) : null } ) ) : od && ( ud = ud ? escape$1 ( ud ) : null , ( Rd . attributes || ( Rd . attributes = [ ] ) ) . push ( { operator : ld , name : unescape$1 ( od ) , escapedName : escape$1 ( od ) , value : ud ? unescape$1 ( ud ) : null , escapedValue : ud ? escape$1 ( ud ) : null } ) ) ; return "" } , Expressions = function ( qa ) { this . length = 0 ; for ( var Ja = this , ed = qa , td ; qa ; ) { if ( td = qa . replace ( slickRe , function ( ) { return replacer . apply ( Ja , arguments ) } ) , td === qa ) throw new Error ( ed + " is an invalid expression" ) ; qa = td } } ; Expressions . prototype . toString = function ( ) { if ( ! this . raw ) { for ( var Ra = [ ] , qa = 0 , Ja ; Ja = this [ qa ++ ] ; ) Ra . push ( Ja ) ; this . raw = Ra . join ( ", " ) } return this . raw } ; var cache$1 = { } , parse = function ( Ra ) { return Ra == null ? null : ( Ra = ( "" + Ra ) . replace ( /^\s+|\s+$/g , "" ) , cache$1 [ Ra ] || ( cache$1 [ R
2024-08-27 22:31:52 +08:00
* Returns an array of the selectors .
*
* @ license Sizzle CSS Selector Engine - MIT
* @ param { String } selectorText from mensch
* @ api public
2024-09-03 08:22:14 +08:00
* / R a . e x t r a c t = f u n c t i o n ( r d ) { f o r ( v a r s d = 0 , o d = [ ] , l d = " " , c d = 0 , u d = r d . l e n g t h ; c d < u d ; c d + + ) { v a r _ d = r d . c h a r A t ( c d ) ; s d ? ( ( _ d = = = " ] " | | _ d = = = " ) " ) & & s d - - , l d + = _ d ) : _ d = = = " , " ? ( o d . p u s h ( l d ) , l d = " " ) : ( ( _ d = = = " [ " | | _ d = = = " ( " ) & & s d + + , ( l d . l e n g t h | | _ d ! = = " , " & & _ d ! = = `
` &&_d!==" ")&&(ld+=_d))}return ld.length&&od.push(ld),od},Ra.parseCSS=function(td){for(var rd=qa.parse(td,{position:!0,comments:!0}),sd=typeof rd.stylesheet<"u"&&rd.stylesheet.rules?rd.stylesheet.rules:[],od=[],ld=0,cd=sd.length;ld<cd;ld++)if(sd[ld].type=="rule")for(var ud=sd[ld],_d=ud.selectors,yd=0,gd=_d.length;yd<gd;yd++)od.push([_d[yd],ud.declarations]);return od},Ra.getPreservedText=function(td,rd,sd){for(var od=qa.parse(td,{position:!0,comments:!0}),ld=typeof od.stylesheet<"u"&&od.stylesheet.rules?od.stylesheet.rules:[],cd=[],ud=ld.length-1;ud>=0;ud--)(rd.fontFaces&&ld[ud].type==="font-face"||rd.mediaQueries&&ld[ud].type==="media"||rd.keyFrames&&ld[ud].type==="keyframes"||rd.pseudos&&ld[ud].selectors&&this.matchesPseudo(ld[ud].selectors[0],sd))&&cd.unshift(qa.stringify({stylesheet:{rules:[ld[ud]]}},{comments:!1,indentation:" "})),ld[ud].position.start;return cd.length===0?!1: `
2024-08-30 15:19:18 +08:00
` +cd.join( `
2024-08-27 22:31:52 +08:00
` )+ `
2024-08-30 15:19:18 +08:00
` },Ra.normalizeLineEndings=function(td){return td.replace(/ \r \n /g, `
2024-08-27 22:31:52 +08:00
` ).replace(/ \n /g, ` \ r
2024-09-08 17:22:36 +08:00
` )},Ra.matchesPseudo=function(td,rd){return rd.find(function(sd){return td.indexOf(sd)>-1})},Ra.compareFunc=function(td,rd){for(var sd=Math.min(td.length,rd.length),od=0;od<sd;od++)if(td[od]!==rd[od])return td[od]>rd[od]?1:-1;return td.length-rd.length},Ra.compare=function(td,rd){return Ra.compareFunc(td,rd)==1?td:rd},Ra.getDefaultOptions=function(td){var rd=Object.assign({extraCss:"",insertPreservedExtraCss:!0,applyStyleTags:!0,removeStyleTags:!0,preserveMediaQueries:!0,preserveFontFaces:!0,preserveKeyFrames:!0,preservePseudos:!0,applyWidthAttributes:!0,applyHeightAttributes:!0,applyAttributesTableElements:!0,url:""},td);return rd.webResources=rd.webResources||{},rd}}(utils $ 4)),utils $ 4}(function(Ra){var qa=lib $ e;requireUtils $ 1();var Ja=function(td,rd,sd){return rd=Object.assign({decodeEntities:!1,_useHtmlParser2:!0},rd),td=sd(td),qa.load(td,rd)},ed=function(){var td=[],rd=function(od){var ld=Ra.exports.codeBlocks;return Object.keys(ld).forEach(function(cd){var ud=new RegExp(ld[cd].start+"([ \\ S \\ s]*?)"+ld[cd].end,"g");od=od.replace(ud,function(_d,yd){return td.push(_d),"JUICE_CODE_BLOCK_"+(td.length-1)+"_"})}),od},sd=function(od){for(var ld=0;ld<td.length;ld++){var cd=new RegExp("JUICE_CODE_BLOCK_"+ld+'_(="")?',"gi");od=od.replace(cd,function(){return td[ld]})}return od};return{encodeEntities:rd,decodeEntities:sd}};Ra.exports=function(td,rd,sd,od){var ld=ed(),cd=Ja(td,rd,ld.encodeEntities),ud=[cd];ud.push.apply(ud,od);var _d=sd.apply(void 0,ud)||cd;return rd&&rd.xmlMode?ld.decodeEntities(_d.xml()):ld.decodeEntities(_d.html())},Ra.exports.codeBlocks={EJS:{start:"<%",end:"%>"},HBS:{start:"{{",end:"}}"}}})(cheerio $ 2);var cheerioExports=cheerio $ 2.exports,numbers $ 1={};numbers $ 1.romanize=function(Ra){if(isNaN(Ra))return NaN;for(var qa=String(+Ra).split(""),Ja=["","C","CC","CCC","CD","D","DC","DCC","DCCC","CM","","X","XX","XXX","XL","L","LX","LXX","LXXX","XC","","I","II","III","IV","V","VI","VII","VIII","IX"],ed="",td=3;td--;)ed=(Ja[+qa.pop()+td*10]||"")+ed;return Array(+qa.join("")+1).join("M")+ed};numbers $ 1.alphanumeric=function(Ra){for(var qa="",Ja;Ra>0;)Ja=(Ra-1)%26,qa=String.fromCharCode(65+Ja)+qa,Ra=(Ra-Ja)/26|0;return qa||void 0};var utils $ 3=requireUtils $ 1(),numbers=numbers $ 1,inline=function(qa){qa.ignoredPseudos=["hover","active","focus","visited","link"],qa.widthElements=["TABLE","TD","TH","IMG"],qa.heightElements=["TABLE","TD","TH","IMG"],qa.tableElements=["TABLE","TH","TR","TD","CAPTION","COLGROUP","COL","THEAD","TBODY","TFOOT"],qa.nonVisualElements=["HEAD","TITLE","BASE","LINK","STYLE","META","SCRIPT","NOSCRIPT"],qa.styleToAttribute={"background-color":"bgcolor","background-image":"background","text-align":"align","vertical-align":"valign"},qa.excludedProperties=[],qa.juiceDocument=ud,qa.inlineDocument=Ja;function Ja(gd,Ed,Td){Td=Td||{};var Od=utils $ 3.parseCSS(Ed),Rd=[],Nd="style",Id={};if(Td.styleAttributeName&&(Nd=Td.styleAttributeName),Od.forEach(Pd),Rd.forEach(qd),Td.inlinePseudoElements&&Rd.forEach(Yd),Td.applyWidthAttributes&&Rd.forEach(function(Jd){Ud(Jd,"width")}),Td.applyHeightAttributes&&Rd.forEach(function(Jd){Ud(Jd,"height")}),Td.applyAttributesTableElements&&Rd.forEach(zd),Td.insertPreservedExtraCss&&Td.extraCss){var Md=utils $ 3.getPreservedText(Td.extraCss,{mediaQueries:Td.preserveMediaQueries,fontFaces:Td.preserveFontFaces,keyFrames:Td.preserveKeyFrames});if(Md){var Ld=null;Td.insertPreservedExtraCss!==!0?Ld=gd(Td.insertPreservedExtraCss):(Ld=gd("head"),Ld.length||(Ld=gd("body")),Ld.length||(Ld=gd.root())),Ld.first().append("<style>"+Md+"</style>")}}function Pd(Jd){var Zd=Jd[0],pf=Jd[1],Qd=new utils $ 3.Selector(Zd),hf=Qd.parsed();if(hf){for(var mf=od(hf),xf=0;xf<hf.length;++xf){var Lf=hf[xf];if(Lf.pseudos)for(var Kf=0;Kf<Lf.pseudos.length;++Kf){var Yf=Lf.pseudos[Kf];if(qa.ignoredPseudos.indexOf(Yf.name)>=0)return}}if(mf){var Of=hf[hf.length-1],Tf=Of.pseudos;Of.pseudos=cd(Of.pseudos),Zd=hf.toString(),Of.pseudos=Tf}var wf;try{wf=gd(Zd)}catch{return}wf.each(function(){var Wf=this;if(Wf.name&&qa.nonVisualElements.indexOf(Wf.name.toUpperCase())>=0)return;if(mf){var Uf="pseudo"+mf,gf=Wf[Uf];gf||(gf=Wf[Uf]=gd
` +Ed.extraCss,Ja(gd,Td,Ed),gd}function _d(gd,Ed){var Td=[],Od=gd("style"),Rd,Nd,Id;return Od.each(function(){Id=this;var Md=!!Id.childNodes;if(Rd=Md?Id.childNodes:Id.children,Rd.length!==1){Ed.removeStyleTags&&gd(Id).remove();return}if(Nd=Rd[0].data,Ed.applyStyleTags&&gd(Id).attr("data-embed")===void 0&&Td.push(Nd),Ed.removeStyleTags&&gd(Id).attr("data-embed")===void 0){var Ld=Md?Id.childNodes[0].nodeValue:Id.children[0].data,Pd=utils $ 3.getPreservedText(Ld,{mediaQueries:Ed.preserveMediaQueries,fontFaces:Ed.preserveFontFaces,keyFrames:Ed.preserveKeyFrames,pseudos:Ed.preservePseudos},qa.ignoredPseudos);Pd?Md?Id.childNodes[0].nodeValue=Pd:Id.children[0].data=Pd:gd(Id).remove()}gd(Id).removeAttr("data-embed")}),Td}function yd(gd,Ed){var Td=_d(gd,Ed),Od=Td.join( `
` );return Od}return qa},cheerio=cheerioExports,makeJuiceClient=inline,juiceClient=makeJuiceClient(function(Ra,qa){return cheerio(Ra,{xmlMode:qa&&qa.xmlMode},juiceDocument,[qa])}),juiceDocument=function(Ra,qa){return juiceClient.juiceDocument(Ra,qa)};juiceClient.inlineContent=function(Ra,qa,Ja){return cheerio(Ra,{xmlMode:Ja&&Ja.xmlMode},juiceClient.inlineDocument,[qa,Ja])};var client=juiceClient;const juice=getDefaultExportFromCjs(client);var yu $ 1=Object.create,He $ 2=Object.defineProperty,Au $ 1=Object.getOwnPropertyDescriptor,Bu $ 1=Object.getOwnPropertyNames,wu $ 2=Object.getPrototypeOf,xu $ 1=Object.prototype.hasOwnProperty,sr $ 2=Ra=>{throw TypeError(Ra)},_u $ 2=(Ra,qa)=>()=>(Ra&&(qa=Ra(Ra=0)),qa),At $ 5=(Ra,qa)=>()=>(qa||Ra((qa={exports:{}}).exports,qa),qa.exports),We $ 1=(Ra,qa)=>{for(var Ja in qa)He $ 2(Ra,Ja,{get:qa[Ja],enumerable:!0})},ar $ 2=(Ra,qa,Ja,ed)=>{if(qa&&typeof qa=="object"||typeof qa=="function")for(let td of Bu $ 1(qa))!xu $ 1.call(Ra,td)&&td!==Ja&&He $ 2(Ra,td,{get:()=>qa[td],enumerable:!(ed=Au $ 1(qa,td))||ed.enumerable});return Ra},Me $ 5=(Ra,qa,Ja)=>(Ja=Ra!=null?yu $ 1(wu $ 2(Ra)):{},ar $ 2(He $ 2(Ja,"default",{value:Ra,enumerable:!0}),Ra)),vu $ 2=Ra=>ar $ 2(He $ 2({},"__esModule",{value:!0}),Ra),bu $ 1=(Ra,qa,Ja)=>qa.has(Ra)||sr $ 2("Cannot "+Ja),Dr $ 2=(Ra,qa,Ja)=>qa.has(Ra)?sr $ 2("Cannot add the same private member more than once"):qa instanceof WeakSet?qa.add(Ra):qa.set(Ra,Ja),pe $ 1=(Ra,qa,Ja)=>(bu $ 1(Ra,qa,"access private method"),Ja),it $ 2=At $ 5((Ra,qa)=>{var Ja=new Proxy(String,{get:()=>Ja});qa.exports=Ja}),Tn $ 3={};We $ 1(Tn $ 3,{default:()=>_o $ 1,shouldHighlight:()=>xo $ 3});var xo $ 3,_o $ 1,kn $ 1=_u $ 2(()=>{xo $ 3=()=>!1,_o $ 1=String}),Pn $ 4=At $ 5((Ra,qa)=>{var Ja=String,ed=function(){return{isColorSupported:!1,reset:Ja,bold:Ja,dim:Ja,italic:Ja,underline:Ja,inverse:Ja,hidden:Ja,strikethrough:Ja,black:Ja,red:Ja,green:Ja,yellow:Ja,blue:Ja,magenta:Ja,cyan:Ja,white:Ja,gray:Ja,bgBlack:Ja,bgRed:Ja,bgGreen:Ja,bgYellow:Ja,bgBlue:Ja,bgMagenta:Ja,bgCyan:Ja,bgWhite:Ja}};qa.exports=ed(),qa.exports.createColors=ed}), $ n $ 4=At $ 5(Ra=>{Object.defineProperty(Ra,"__esModule",{value:!0}),Ra.codeFrameColumns=gd,Ra.default=Ed;var qa=(kn $ 1(),vu $ 2(Tn $ 3)),Ja=td(Pn $ 4(),!0);function ed(Td){if(typeof WeakMap!="function")return null;var Od=new WeakMap,Rd=new WeakMap;return(ed=function(Nd){return Nd?Rd:Od})(Td)}function td(Td,Od){if(Td===null||typeof Td!="object"&&typeof Td!="function")return{default:Td};var Rd=ed(Od);if(Rd&&Rd.has(Td))return Rd.get(Td);var Nd={__proto__:null},Id=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var Md in Td)if(Md!=="default"&&{}.hasOwnProperty.call(Td,Md)){var Ld=Id?Object.getOwnPropertyDescriptor(Td,Md):null;Ld&&(Ld.get||Ld.set)?Object.defineProperty(Nd,Md,Ld):Nd[Md]=Td[Md]}return Nd.default=Td,Rd&&Rd.set(Td,Nd),Nd}var rd=Ja.default,sd=(Td,Od)=>Rd=>Td(Od(Rd)),od;function ld(Td){return Td?(od!=null||(od=(0,Ja.createColors)(!0)),od):rd}var cd=!1;function ud(Td){return{gutter:Td.gray,marker:sd(Td.red,Td.bold),message:sd(Td.red,Td.bold)}}var _d=/ \r \n |[ \n \r \u 2028 \u 2029]/;function yd(Td,Od,Rd){let Nd=Object.assign({column:0,line:-1},Td.start),Id=Object.assign({},Nd,Td.end),{linesAbove:Md=2,linesBelow:Ld=3}=Rd||{},Pd=Nd.line,qd=Nd.column,Yd=Id.line,Ud=Id.column,Hd=Math.max(Pd-(Md+1),0),zd=Math.min(Od.length,Yd+Ld);Pd===-1&&(Hd=0),Yd===-1&&(zd=Od.length);let Jd=Yd-Pd,Zd={};if(Jd)for(let pf=0;pf<=Jd;pf++){let Qd=pf+Pd;if(!qd)Zd[Qd]=!0;else if(pf===0){let hf=Od[Qd-1].length;Zd[Qd]=[qd,hf-qd+1]}else if(pf===Jd)Zd[Qd]=[0,Ud];else{let hf=Od[Qd-pf].length;Zd[Qd]=[0,hf]}}else qd===Ud?qd?Zd[Pd]=[qd,0]:Zd[Pd]=!0:Zd[Pd]=[qd,Ud-qd];return{start:Hd,end:zd,markerLines:Zd}}function gd(Td,Od,Rd={}){let Nd=(Rd.highlightCode||Rd.forceColor)&&(0,qa.shouldHighlight)(Rd),Id=ld(Rd.forceColor),Md=ud(Id),Ld=(Zd,pf)=>Nd?Zd(pf):pf,Pd=Td.split(_d),{start:qd,end:Yd,markerLines:Ud}=yd(Od,Pd,Rd),Hd=Od.start&&typeof Od.start.column=="number",zd=String(Yd).length,Jd=(Nd?(0,qa.default)(Td,Rd):Td).split(_d,Yd).slice(qd,Yd).map((Zd,pf)=>{let Qd=qd+1+pf,hf= ` $ { ` ${ Qd } ` . slice ( - zd ) } | ` ,mf=Ud[Qd],xf=!Ud[Qd+1];if(mf){let Lf="";if(Array.isArray(mf)){let Kf=Zd.slice(0,Math.max(mf[0]-1,0)).rep
` ,Ld(Md.gutter,hf.replace(/ \d /g," "))," ",Kf,Ld(Md.marker,"^").repeat(Yf)].join(""),xf&&Rd.message&&(Lf+=" "+Ld(Md.message,Rd.message))}return[Ld(Md.marker,">"),Ld(Md.gutter,hf),Zd.length>0? ` $ { Zd } ` :"",Lf].join("")}else return ` $ { Ld ( Md . gutter , hf ) } $ { Zd . length > 0 ? ` ${ Zd } ` : "" } ` }).join( `
` );return Rd.message&&!Hd&&(Jd= ` $ { " " . repeat ( zd + 1 ) } $ { Rd . message }
$ { Jd } ` ),Nd?Id.reset(Jd):Jd}function Ed(Td,Od,Rd,Nd={}){if(!cd){cd=!0;let Id="Passing lineNumber and colNumber is deprecated to @babel/code-frame. Please use ` codeFrameColumns ` .";{let Md=new Error(Id);Md.name="DeprecationWarning",console.warn(new Error(Id))}}return Rd=Math.max(Rd,0),gd(Td,{start:{column:Rd,line:Od}},Nd)}}),ir $ 3={};We $ 1(ir $ 3,{__debug:()=>di $ 3,check:()=>fi $ 3,doc:()=>nr $ 2,format:()=>gu $ 1,formatWithCursor:()=>Cu $ 2,getSupportInfo:()=>pi $ 4,util:()=>or $ 2,version:()=>fu $ 1});var Ou $ 2=(Ra,qa,Ja,ed)=>{if(!(Ra&&qa==null))return qa.replaceAll?qa.replaceAll(Ja,ed):Ja.global?qa.replace(Ja,ed):qa.split(Ja).join(ed)},ne $ 3=Ou $ 2;function Z $ 1(){}Z $ 1.prototype={diff:function(Ra,qa){var Ja,ed=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},td=ed.callback;typeof ed=="function"&&(td=ed,ed={}),this.options=ed;var rd=this;function sd(Id){return td?(setTimeout(function(){td(void 0,Id)},0),!0):Id}Ra=this.castInput(Ra),qa=this.castInput(qa),Ra=this.removeEmpty(this.tokenize(Ra)),qa=this.removeEmpty(this.tokenize(qa));var od=qa.length,ld=Ra.length,cd=1,ud=od+ld;ed.maxEditLength&&(ud=Math.min(ud,ed.maxEditLength));var _d=(Ja=ed.timeout)!==null&&Ja!==void 0?Ja:1/0,yd=Date.now()+_d,gd=[{oldPos:-1,lastComponent:void 0}],Ed=this.extractCommon(gd[0],qa,Ra,0);if(gd[0].oldPos+1>=ld&&Ed+1>=od)return sd([{value:this.join(qa),count:qa.length}]);var Td=-1/0,Od=1/0;function Rd(){for(var Id=Math.max(Td,-cd);Id<=Math.min(Od,cd);Id+=2){var Md=void 0,Ld=gd[Id-1],Pd=gd[Id+1];Ld&&(gd[Id-1]=void 0);var qd=!1;if(Pd){var Yd=Pd.oldPos-Id;qd=Pd&&0<=Yd&&Yd<od}var Ud=Ld&&Ld.oldPos+1<ld;if(!qd&&!Ud){gd[Id]=void 0;continue}if(!Ud||qd&&Ld.oldPos+1<Pd.oldPos?Md=rd.addToPath(Pd,!0,void 0,0):Md=rd.addToPath(Ld,void 0,!0,1),Ed=rd.extractCommon(Md,qa,Ra,Id),Md.oldPos+1>=ld&&Ed+1>=od)return sd(Su $ 1(rd,Md.lastComponent,qa,Ra,rd.useLongestToken));gd[Id]=Md,Md.oldPos+1>=ld&&(Od=Math.min(Od,Id-1)),Ed+1>=od&&(Td=Math.max(Td,Id+1))}cd++}if(td)(function Id(){setTimeout(function(){if(cd>ud||Date.now()>yd)return td();Rd()||Id()},0)})();else for(;cd<=ud&&Date.now()<=yd;){var Nd=Rd();if(Nd)return Nd}},addToPath:function(Ra,qa,Ja,ed){var td=Ra.lastComponent;return td&&td.added===qa&&td.removed===Ja?{oldPos:Ra.oldPos+ed,lastComponent:{count:td.count+1,added:qa,removed:Ja,previousComponent:td.previousComponent}}:{oldPos:Ra.oldPos+ed,lastComponent:{count:1,added:qa,removed:Ja,previousComponent:td}}},extractCommon:function(Ra,qa,Ja,ed){for(var td=qa.length,rd=Ja.length,sd=Ra.oldPos,od=sd-ed,ld=0;od+1<td&&sd+1<rd&&this.equals(qa[od+1],Ja[sd+1]);)od++,sd++,ld++;return ld&&(Ra.lastComponent={count:ld,previousComponent:Ra.lastComponent}),Ra.oldPos=sd,od},equals:function(Ra,qa){return this.options.comparator?this.options.comparator(Ra,qa):Ra===qa||this.options.ignoreCase&&Ra.toLowerCase()===qa.toLowerCase()},removeEmpty:function(Ra){for(var qa=[],Ja=0;Ja<Ra.length;Ja++)Ra[Ja]&&qa.push(Ra[Ja]);return qa},castInput:function(Ra){return Ra},tokenize:function(Ra){return Ra.split("")},join:function(Ra){return Ra.join("")}};function Su $ 1(Ra,qa,Ja,ed,td){for(var rd=[],sd;qa;)rd.push(qa),sd=qa.previousComponent,delete qa.previousComponent,qa=sd;rd.reverse();for(var od=0,ld=rd.length,cd=0,ud=0;od<ld;od++){var _d=rd[od];if(_d.removed){if(_d.value=Ra.join(ed.slice(ud,ud+_d.count)),ud+=_d.count,od&&rd[od-1].added){var yd=rd[od-1];rd[od-1]=rd[od],rd[od]=yd}}else{if(!_d.added&&td){var gd=Ja.slice(cd,cd+_d.count);gd=gd.map(function(Td,Od){var Rd=ed[ud+Od];return Rd.length>Td.length?Rd:Td}),_d.value=Ra.join(gd)}else _d.value=Ra.join(Ja.slice(cd,cd+_d.count));cd+=_d.count,_d.added||(ud+=_d.count)}}var Ed=rd[ld-1];return ld>1&&typeof Ed.value=="string"&&(Ed.added||Ed.removed)&&Ra.equals("",Ed.value)&&(rd[ld-2].value+=Ed.value,rd.pop()),rd}var lr $ 1=/^[A-Za-z \x C0- \u 02C6 \u 02C8- \u 02D7 \u 02DE- \u 02FF \u 1E00- \u 1EFF]+ $ /,cr $ 2=/ \S /,fr $ 1=new Z $ 1;fr $ 1.equals=function(Ra,qa){return this.options.ignoreCase&&(Ra=Ra.toLowerCase(),qa=qa.toLowerCase()),Ra===qa||this.options.ignoreWhitespace&&!cr $ 2.test(Ra)&&!cr $ 2.test(qa)};fr $ 1.tokenize=function(Ra){for(var qa=Ra.split(/([^ \S \r \n ]+|[()[ \] {}'" \r \n ]| \b )/),Ja=0;Ja<qa.le
2024-09-03 08:22:14 +08:00
` ));var qa=[],Ja=Ra.split(/( \n | \r \n )/);Ja[Ja.length-1]||Ja.pop();for(var ed=0;ed<Ja.length;ed++){var td=Ja[ed];ed%2&&!this.options.newlineIsToken?qa[qa.length-1]+=td:(this.options.ignoreWhitespace&&(td=td.trim()),qa.push(td))}return qa};var Nu $ 2=new Z $ 1;Nu $ 2.tokenize=function(Ra){return Ra.split(/( \S .+?[.!?])(?= \s +| $ )/)};var Tu $ 2=new Z $ 1;Tu $ 2.tokenize=function(Ra){return Ra.split(/([{}:;,]| \s +)/)};function $ e $ 3(Ra){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"? $ e $ 3=function(qa){return typeof qa}: $ e $ 3=function(qa){return qa&&typeof Symbol=="function"&&qa.constructor===Symbol&&qa!==Symbol.prototype?"symbol":typeof qa}, $ e $ 3(Ra)}var ku $ 1=Object.prototype.toString,Ae $ 2=new Z $ 1;Ae $ 2.useLongestToken=!0;Ae $ 2.tokenize=pr $ 2.tokenize;Ae $ 2.castInput=function(Ra){var qa=this.options,Ja=qa.undefinedReplacement,ed=qa.stringifyReplacer,td=ed===void 0?function(rd,sd){return typeof sd>"u"?Ja:sd}:ed;return typeof Ra=="string"?Ra:JSON.stringify(Bt $ 4(Ra,null,null,td),td," ")};Ae $ 2.equals=function(Ra,qa){return Z $ 1.prototype.equals.call(Ae $ 2,Ra.replace(/,([ \r \n ])/g," $ 1"),qa.replace(/,([ \r \n ])/g," $ 1"))};function Bt $ 4(Ra,qa,Ja,ed,td){qa=qa||[],Ja=Ja||[],ed&&(Ra=ed(td,Ra));var rd;for(rd=0;rd<qa.length;rd+=1)if(qa[rd]===Ra)return Ja[rd];var sd;if(ku $ 1.call(Ra)==="[object Array]"){for(qa.push(Ra),sd=new Array(Ra.length),Ja.push(sd),rd=0;rd<Ra.length;rd+=1)sd[rd]=Bt $ 4(Ra[rd],qa,Ja,ed,td);return qa.pop(),Ja.pop(),sd}if(Ra&&Ra.toJSON&&(Ra=Ra.toJSON()), $ e $ 3(Ra)==="object"&&Ra!==null){qa.push(Ra),sd={},Ja.push(sd);var od=[],ld;for(ld in Ra)Ra.hasOwnProperty(ld)&&od.push(ld);for(od.sort(),rd=0;rd<od.length;rd+=1)ld=od[rd],sd[ld]=Bt $ 4(Ra[ld],qa,Ja,ed,ld);qa.pop(),Ja.pop()}else sd=Ra;return sd}var Ve $ 3=new Z $ 1;Ve $ 3.tokenize=function(Ra){return Ra.slice()};Ve $ 3.join=Ve $ 3.removeEmpty=function(Ra){return Ra};function dr $ 2(Ra,qa,Ja){return Ve $ 3.diff(Ra,qa,Ja)}function Fr $ 2(Ra){let qa=Ra.indexOf(" \r ");return qa>=0?Ra.charAt(qa+1)=== `
2024-08-30 15:19:18 +08:00
` ?"crlf":"cr":"lf"}function Be $ 4(Ra){switch(Ra){case"cr":return" \r ";case"crlf":return ` \ r
2024-08-27 22:31:52 +08:00
` ;default:return `
2024-08-30 15:19:18 +08:00
` }}function wt $ 2(Ra,qa){let Ja;switch(qa){case `
` :Ja=/ \n /gu;break;case" \r ":Ja=/ \r /gu;break;case ` \ r
` :Ja=/ \r \n /gu;break;default:throw new Error( ` Unexpected "eol" $ { JSON . stringify ( qa ) } . ` )}let ed=Ra.match(Ja);return ed?ed.length:0}function mr $ 2(Ra){return ne $ 3(!1,Ra,/ \r \n ?/gu, `
` )}var U $ 2="string",W $ 2="array",z $ 2="cursor",L $ 3="indent",P $ 2="align",I="trim",x $ 1="group",S="fill",_ $ 2="if-break",R $ 2="indent-if-break",Y $ 2="line-suffix",j="line-suffix-boundary",B $ 1="line",N $ 3="label",b $ 1="break-parent",Ue $ 4=new Set([z $ 2,L $ 3,P $ 2,I,x $ 1,S,_ $ 2,R $ 2,Y $ 2,j,B $ 1,N $ 3,b $ 1]);function Lu $ 1(Ra){if(typeof Ra=="string")return U $ 2;if(Array.isArray(Ra))return W $ 2;if(!Ra)return;let{type:qa}=Ra;if(Ue $ 4.has(qa))return qa}var G $ 3=Lu $ 1,Pu $ 1=Ra=>new Intl.ListFormat("en-US",{type:"disjunction"}).format(Ra);function Iu $ 2(Ra){let qa=Ra===null?"null":typeof Ra;if(qa!=="string"&&qa!=="object")return ` Unexpected doc '${qa}' ,
Expected it to be 'string' or 'object' . ` ;if(G $ 3(Ra))throw new Error("doc is valid.");let Ja=Object.prototype.toString.call(Ra);if(Ja!=="[object Object]")return ` Unexpected doc '${Ja}' . ` ;let ed=Pu $ 1([...Ue $ 4].map(td=> ` '${td}' ` ));return ` Unexpected doc . type '${Ra.type}' .
2024-09-08 17:22:36 +08:00
Expected it to be $ { ed } . ` }var xt=class extends Error{constructor(qa){super(Iu $ 2(qa));n_(this,"name","InvalidDocError");this.doc=qa}},Q $ 3=xt,Er $ 2={};function Ru $ 2(Ra,qa,Ja,ed){let td=[Ra];for(;td.length>0;){let rd=td.pop();if(rd===Er $ 2){Ja(td.pop());continue}Ja&&td.push(rd,Er $ 2);let sd=G $ 3(rd);if(!sd)throw new Q $ 3(rd);if((qa==null?void 0:qa(rd))!==!1)switch(sd){case W $ 2:case S:{let od=sd===W $ 2?rd:rd.parts;for(let ld=od.length,cd=ld-1;cd>=0;--cd)td.push(od[cd]);break}case _ $ 2:td.push(rd.flatContents,rd.breakContents);break;case x $ 1:if(ed&&rd.expandedStates)for(let od=rd.expandedStates.length,ld=od-1;ld>=0;--ld)td.push(rd.expandedStates[ld]);else td.push(rd.contents);break;case P $ 2:case L $ 3:case R $ 2:case N $ 3:case Y $ 2:td.push(rd.contents);break;case U $ 2:case z $ 2:case I:case j:case B $ 1:case b $ 1:break;default:throw new Q $ 3(rd)}}}var we $ 2=Ru $ 2,hr $ 1=()=>{},ze $ 3=hr $ 1;function De $ 2(Ra){return{type:L $ 3,contents:Ra}}function ae $ 2(Ra,qa){return{type:P $ 2,contents:qa,n:Ra}}function _t $ 2(Ra,qa={}){return ze $ 3(qa.expandedStates),{type:x $ 1,id:qa.id,contents:Ra,break:!!qa.shouldBreak,expandedStates:qa.expandedStates}}function Cr $ 1(Ra){return ae $ 2(Number.NEGATIVE_INFINITY,Ra)}function gr $ 2(Ra){return ae $ 2({type:"root"},Ra)}function yr $ 2(Ra){return ae $ 2(-1,Ra)}function Ar $ 2(Ra,qa){return _t $ 2(Ra[0],{...qa,expandedStates:Ra})}function Ge $ 2(Ra){return{type:S,parts:Ra}}function Br $ 4(Ra,qa="",Ja={}){return{type:_ $ 2,breakContents:Ra,flatContents:qa,groupId:Ja.groupId}}function wr $ 3(Ra,qa){return{type:R $ 2,contents:Ra,groupId:qa.groupId,negate:qa.negate}}function xe $ 3(Ra){return{type:Y $ 2,contents:Ra}}var xr $ 3={type:j},de $ 2={type:b $ 1},_r $ 3={type:I},_e $ 4={type:B $ 1,hard:!0},vt $ 3={type:B $ 1,hard:!0,literal:!0},Ke $ 2={type:B $ 1},vr $ 2={type:B $ 1,soft:!0},q $ 2=[_e $ 4,de $ 2],qe $ 3=[vt $ 3,de $ 2],ve $ 3={type:z $ 2};function be $ 5(Ra,qa){let Ja=[];for(let ed=0;ed<qa.length;ed++)ed!==0&&Ja.push(Ra),Ja.push(qa[ed]);return Ja}function Je $ 3(Ra,qa,Ja){let ed=Ra;if(qa>0){for(let td=0;td<Math.floor(qa/Ja);++td)ed=De $ 2(ed);ed=ae $ 2(qa%Ja,ed),ed=ae $ 2(Number.NEGATIVE_INFINITY,ed)}return ed}function br $ 2(Ra,qa){return Ra?{type:N $ 3,label:Ra,contents:qa}:qa}function ee $ 2(Ra){var qa;if(!Ra)return"";if(Array.isArray(Ra)){let Ja=[];for(let ed of Ra)if(Array.isArray(ed))Ja.push(...ee $ 2(ed));else{let td=ee $ 2(ed);td!==""&&Ja.push(td)}return Ja}return Ra.type===_ $ 2?{...Ra,breakContents:ee $ 2(Ra.breakContents),flatContents:ee $ 2(Ra.flatContents)}:Ra.type===x $ 1?{...Ra,contents:ee $ 2(Ra.contents),expandedStates:(qa=Ra.expandedStates)==null?void 0:qa.map(ee $ 2)}:Ra.type===S?{type:"fill",parts:Ra.parts.map(ee $ 2)}:Ra.contents?{...Ra,contents:ee $ 2(Ra.contents)}:Ra}function Or $ 3(Ra){let qa=Object.create(null),Ja=new Set;return ed(ee $ 2(Ra));function ed(rd,sd,od){var ld,cd;if(typeof rd=="string")return JSON.stringify(rd);if(Array.isArray(rd)){let ud=rd.map(ed).filter(Boolean);return ud.length===1?ud[0]: ` [ $ { ud . join ( ", " ) } ] ` }if(rd.type===B $ 1){let ud=((ld=od==null?void 0:od[sd+1])==null?void 0:ld.type)===b $ 1;return rd.literal?ud?"literalline":"literallineWithoutBreakParent":rd.hard?ud?"hardline":"hardlineWithoutBreakParent":rd.soft?"softline":"line"}if(rd.type===b $ 1)return((cd=od==null?void 0:od[sd-1])==null?void 0:cd.type)===B $ 1&&od[sd-1].hard?void 0:"breakParent";if(rd.type===I)return"trim";if(rd.type===L $ 3)return"indent("+ed(rd.contents)+")";if(rd.type===P $ 2)return rd.n===Number.NEGATIVE_INFINITY?"dedentToRoot("+ed(rd.contents)+")":rd.n<0?"dedent("+ed(rd.contents)+")":rd.n.type==="root"?"markAsRoot("+ed(rd.contents)+")":"align("+JSON.stringify(rd.n)+", "+ed(rd.contents)+")";if(rd.type===_ $ 2)return"ifBreak("+ed(rd.breakContents)+(rd.flatContents?", "+ed(rd.flatContents):"")+(rd.groupId?(rd.flatContents?"":', ""')+ ` , { groupId : $ { td ( rd . groupId ) } } ` :"")+")";if(rd.type===R $ 2){let ud=[];rd.negate&&ud.push("negate: true"),rd.groupId&&ud.push( ` groupId : $ { td ( rd . groupId ) } ` );let _d=ud.length>0? ` , { $ { ud . join ( ", " ) } } ` :"";return ` indentIfBreak ( $ { ed ( rd . contents ) } $ { _d } ) ` }if(rd.type===x $ 1){let ud=[];rd.break&&rd.break!=="propagated"&&ud.push("shouldBreak: true"),rd.id&&ud.push( ` id : $ { td ( rd . id ) } ` );let _d=ud.length>0? ` , {
` )):Ja)}function Uu $ 3(Ra){if(Ra.type===B $ 1)return!0}function Hr $ 4(Ra){return Xe $ 2(Ra,Uu $ 3,!1)}function Qe $ 2(Ra,qa){return Ra.type===N $ 3?{...Ra,contents:qa(Ra.contents)}:qa(Ra)}var H $ 2=Symbol("MODE_BREAK"),J $ 2=Symbol("MODE_FLAT"),Te $ 3=Symbol("cursor");function Wr $ 3(){return{value:"",length:0,queue:[]}}function zu $ 1(Ra,qa){return bt $ 4(Ra,{type:"indent"},qa)}function Gu $ 2(Ra,qa,Ja){return qa===Number.NEGATIVE_INFINITY?Ra.root||Wr $ 3():qa<0?bt $ 4(Ra,{type:"dedent"},Ja):qa?qa.type==="root"?{...Ra,root:Ra}:bt $ 4(Ra,{type:typeof qa=="string"?"stringAlign":"numberAlign",n:qa},Ja):Ra}function bt $ 4(Ra,qa,Ja){let ed=qa.type==="dedent"?Ra.queue.slice(0,-1):[...Ra.queue,qa],td="",rd=0,sd=0,od=0;for(let Ed of ed)switch(Ed.type){case"indent":ud(),Ja.useTabs?ld(1):cd(Ja.tabWidth);break;case"stringAlign":ud(),td+=Ed.n,rd+=Ed.n.length;break;case"numberAlign":sd+=1,od+=Ed.n;break;default:throw new Error( ` Unexpected type '${Ed.type}' ` )}return yd(),{...Ra,value:td,length:rd,queue:ed};function ld(Ed){td+=" ".repeat(Ed),rd+=Ja.tabWidth*Ed}function cd(Ed){td+=" ".repeat(Ed),rd+=Ed}function ud(){Ja.useTabs?_d():yd()}function _d(){sd>0&&ld(sd),gd()}function yd(){od>0&&cd(od),gd()}function gd(){sd=0,od=0}}function Ot $ 3(Ra){let qa=0,Ja=0,ed=Ra.length;e:for(;ed--;){let td=Ra[ed];if(td===Te $ 3){Ja++;continue}for(let rd=td.length-1;rd>=0;rd--){let sd=td[rd];if(sd===" "||sd===" ")qa++;else{Ra[ed]=td.slice(0,rd+1);break e}}}if(qa>0||Ja>0)for(Ra.length=ed+1;Ja-- >0;)Ra.push(Te $ 3);return qa}function et $ 2(Ra,qa,Ja,ed,td,rd){if(Ja===Number.POSITIVE_INFINITY)return!0;let sd=qa.length,od=[Ra],ld=[];for(;Ja>=0;){if(od.length===0){if(sd===0)return!0;od.push(qa[--sd]);continue}let{mode:cd,doc:ud}=od.pop(),_d=G $ 3(ud);switch(_d){case U $ 2:ld.push(ud),Ja-=Oe $ 4(ud);break;case W $ 2:case S:{let yd=_d===W $ 2?ud:ud.parts;for(let gd=yd.length-1;gd>=0;gd--)od.push({mode:cd,doc:yd[gd]});break}case L $ 3:case P $ 2:case R $ 2:case N $ 3:od.push({mode:cd,doc:ud.contents});break;case I:Ja+=Ot $ 3(ld);break;case x $ 1:{if(rd&&ud.break)return!1;let yd=ud.break?H $ 2:cd,gd=ud.expandedStates&&yd===H $ 2?y $ 1(!1,ud.expandedStates,-1):ud.contents;od.push({mode:yd,doc:gd});break}case _ $ 2:{let yd=(ud.groupId?td[ud.groupId]||J $ 2:cd)===H $ 2?ud.breakContents:ud.flatContents;yd&&od.push({mode:cd,doc:yd});break}case B $ 1:if(cd===H $ 2||ud.hard)return!0;ud.soft||(ld.push(" "),Ja--);break;case Y $ 2:ed=!0;break;case j:if(ed)return!1;break}}return!1}function Fe $ 2(Ra,qa){let Ja={},ed=qa.printWidth,td=Be $ 4(qa.endOfLine),rd=0,sd=[{ind:Wr $ 3(),mode:H $ 2,doc:Ra}],od=[],ld=!1,cd=[],ud=0;for(Rr $ 2(Ra);sd.length>0;){let{ind:yd,mode:gd,doc:Ed}=sd.pop();switch(G $ 3(Ed)){case U $ 2:{let Td=td!== `
2024-08-30 15:19:18 +08:00
` ?ne $ 3(!1,Ed, `
2024-09-08 17:22:36 +08:00
` ,td):Ed;od.push(Td),sd.length>0&&(rd+=Oe $ 4(Td));break}case W $ 2:for(let Td=Ed.length-1;Td>=0;Td--)sd.push({ind:yd,mode:gd,doc:Ed[Td]});break;case z $ 2:if(ud>=2)throw new Error("There are too many 'cursor' in doc.");od.push(Te $ 3),ud++;break;case L $ 3:sd.push({ind:zu $ 1(yd,qa),mode:gd,doc:Ed.contents});break;case P $ 2:sd.push({ind:Gu $ 2(yd,Ed.n,qa),mode:gd,doc:Ed.contents});break;case I:rd-=Ot $ 3(od);break;case x $ 1:switch(gd){case J $ 2:if(!ld){sd.push({ind:yd,mode:Ed.break?H $ 2:J $ 2,doc:Ed.contents});break}case H $ 2:{ld=!1;let Td={ind:yd,mode:J $ 2,doc:Ed.contents},Od=ed-rd,Rd=cd.length>0;if(!Ed.break&&et $ 2(Td,sd,Od,Rd,Ja))sd.push(Td);else if(Ed.expandedStates){let Nd=y $ 1(!1,Ed.expandedStates,-1);if(Ed.break){sd.push({ind:yd,mode:H $ 2,doc:Nd});break}else for(let Id=1;Id<Ed.expandedStates.length+1;Id++)if(Id>=Ed.expandedStates.length){sd.push({ind:yd,mode:H $ 2,doc:Nd});break}else{let Md=Ed.expandedStates[Id],Ld={ind:yd,mode:J $ 2,doc:Md};if(et $ 2(Ld,sd,Od,Rd,Ja)){sd.push(Ld);break}}}else sd.push({ind:yd,mode:H $ 2,doc:Ed.contents});break}}Ed.id&&(Ja[Ed.id]=y $ 1(!1,sd,-1).mode);break;case S:{let Td=ed-rd,{parts:Od}=Ed;if(Od.length===0)break;let[Rd,Nd]=Od,Id={ind:yd,mode:J $ 2,doc:Rd},Md={ind:yd,mode:H $ 2,doc:Rd},Ld=et $ 2(Id,[],Td,cd.length>0,Ja,!0);if(Od.length===1){Ld?sd.push(Id):sd.push(Md);break}let Pd={ind:yd,mode:J $ 2,doc:Nd},qd={ind:yd,mode:H $ 2,doc:Nd};if(Od.length===2){Ld?sd.push(Pd,Id):sd.push(qd,Md);break}Od.splice(0,2);let Yd={ind:yd,mode:gd,doc:Ge $ 2(Od)},Ud=Od[0];et $ 2({ind:yd,mode:J $ 2,doc:[Rd,Nd,Ud]},[],Td,cd.length>0,Ja,!0)?sd.push(Yd,Pd,Id):Ld?sd.push(Yd,qd,Id):sd.push(Yd,qd,Md);break}case _ $ 2:case R $ 2:{let Td=Ed.groupId?Ja[Ed.groupId]:gd;if(Td===H $ 2){let Od=Ed.type===_ $ 2?Ed.breakContents:Ed.negate?Ed.contents:De $ 2(Ed.contents);Od&&sd.push({ind:yd,mode:gd,doc:Od})}if(Td===J $ 2){let Od=Ed.type===_ $ 2?Ed.flatContents:Ed.negate?De $ 2(Ed.contents):Ed.contents;Od&&sd.push({ind:yd,mode:gd,doc:Od})}break}case Y $ 2:cd.push({ind:yd,mode:gd,doc:Ed.contents});break;case j:cd.length>0&&sd.push({ind:yd,mode:gd,doc:_e $ 4});break;case B $ 1:switch(gd){case J $ 2:if(Ed.hard)ld=!0;else{Ed.soft||(od.push(" "),rd+=1);break}case H $ 2:if(cd.length>0){sd.push({ind:yd,mode:gd,doc:Ed},...cd.reverse()),cd.length=0;break}Ed.literal?yd.root?(od.push(td,yd.root.value),rd=yd.root.length):(od.push(td),rd=0):(rd-=Ot $ 3(od),od.push(td+yd.value),rd=yd.length);break}break;case N $ 3:sd.push({ind:yd,mode:gd,doc:Ed.contents});break;case b $ 1:break;default:throw new Q $ 3(Ed)}sd.length===0&&cd.length>0&&(sd.push(...cd.reverse()),cd.length=0)}let _d=od.indexOf(Te $ 3);if(_d!==-1){let yd=od.indexOf(Te $ 3,_d+1),gd=od.slice(0,_d).join(""),Ed=od.slice(_d+1,yd).join(""),Td=od.slice(yd+1).join("");return{formatted:gd+Ed+Td,cursorNodeStart:gd.length,cursorNodeText:Ed}}return{formatted:od.join("")}}function Ku $ 3(Ra,qa,Ja=0){let ed=0;for(let td=Ja;td<Ra.length;++td)Ra[td]===" "?ed=ed+qa-ed%qa:ed++;return ed}var me $ 1=Ku $ 3,te $ 3,Nt $ 3,tt $ 2,St $ 3=class{constructor(qa){Dr $ 2(this,te $ 3),this.stack=[qa]}get key(){let{stack:qa,siblings:Ja}=this;return y $ 1(!1,qa,Ja===null?-2:-4)??null}get index(){return this.siblings===null?null:y $ 1(!1,this.stack,-2)}get node(){return y $ 1(!1,this.stack,-1)}get parent(){return this.getNode(1)}get grandparent(){return this.getNode(2)}get isInArray(){return this.siblings!==null}get siblings(){let{stack:qa}=this,Ja=y $ 1(!1,qa,-3);return Array.isArray(Ja)?Ja:null}get next(){let{siblings:qa}=this;return qa===null?null:qa[this.index+1]}get previous(){let{siblings:qa}=this;return qa===null?null:qa[this.index-1]}get isFirst(){return this.index===0}get isLast(){let{siblings:qa,index:Ja}=this;return qa!==null&&Ja===qa.length-1}get isRoot(){return this.stack.length===1}get root(){return this.stack[0]}get ancestors(){return[...pe $ 1(this,te $ 3,tt $ 2).call(this)]}getName(){let{stack:qa}=this,{length:Ja}=qa;return Ja>1?y $ 1(!1,qa,-2):null}getValue(){return y $ 1(!1,this.stack,-1)}getNode(qa=0){let Ja=pe $ 1(this,te $ 3,Nt $ 3).call(this,qa);return Ja===-1?null:this.stack[Ja]}getParentNode(qa=0){return this.getNode(qa+1)}call(qa,...Ja){let{stack:ed}=this,{length:td}=ed,rd=y $ 1(!1,ed,-1);for(let sd of Ja)rd=r
2024-08-30 15:19:18 +08:00
` )return qa-2;if(td=== `
` ||td===" \r "||td===" \u 2028"||td===" \u 2029")return qa-1}else{if(td===" \r "&&Ra.charAt(qa+1)=== `
` )return qa+2;if(td=== `
2024-09-08 17:22:36 +08:00
` ||td===" \r "||td===" \u 2028"||td===" \u 2029")return qa+1}return qa}var M $ 3=Ju $ 3;function Xu $ 3(Ra,qa,Ja={}){let ed=T $ 1(Ra,Ja.backwards?qa-1:qa,Ja),td=M $ 3(Ra,ed,Ja);return ed!==td}var V $ 4=Xu $ 3;function Zu $ 4(Ra){return Array.isArray(Ra)&&Ra.length>0}var kt $ 3=Zu $ 4,Gr $ 3=new Set(["tokens","comments","parent","enclosingNode","precedingNode","followingNode"]),Qu $ 2=Ra=>Object.keys(Ra).filter(qa=>!Gr $ 3.has(qa));function eo $ 1(Ra){return Ra?qa=>Ra(qa,Gr $ 3):Qu $ 2}var X $ 2=eo $ 1;function to $ 1(Ra){let qa=Ra.type||Ra.kind||"(unknown type)",Ja=String(Ra.name||Ra.id&&(typeof Ra.id=="object"?Ra.id.name:Ra.id)||Ra.key&&(typeof Ra.key=="object"?Ra.key.name:Ra.key)||Ra.value&&(typeof Ra.value=="object"?"":String(Ra.value))||Ra.operator||"");return Ja.length>20&&(Ja=Ja.slice(0,19)+"…"),qa+(Ja?" "+Ja:"")}function Lt $ 2(Ra,qa){(Ra.comments??(Ra.comments=[])).push(qa),qa.printed=!1,qa.nodeDescription=to $ 1(Ra)}function ue $ 2(Ra,qa){qa.leading=!0,qa.trailing=!1,Lt $ 2(Ra,qa)}function re $ 4(Ra,qa,Ja){qa.leading=!1,qa.trailing=!1,Ja&&(qa.marker=Ja),Lt $ 2(Ra,qa)}function oe $ 3(Ra,qa){qa.leading=!1,qa.trailing=!0,Lt $ 2(Ra,qa)}var Pt $ 2=new WeakMap;function ut $ 1(Ra,qa){if(Pt $ 2.has(Ra))return Pt $ 2.get(Ra);let{printer:{getCommentChildNodes:Ja,canAttachComment:ed,getVisitorKeys:td},locStart:rd,locEnd:sd}=qa;if(!ed)return[];let od=((Ja==null?void 0:Ja(Ra,qa))??[...Tt $ 3(Ra,{getVisitorKeys:X $ 2(td)})]).flatMap(ld=>ed(ld)?[ld]:ut $ 1(ld,qa));return od.sort((ld,cd)=>rd(ld)-rd(cd)||sd(ld)-sd(cd)),Pt $ 2.set(Ra,od),od}function qr $ 3(Ra,qa,Ja,ed){let{locStart:td,locEnd:rd}=Ja,sd=td(qa),od=rd(qa),ld=ut $ 1(Ra,Ja),cd,ud,_d=0,yd=ld.length;for(;_d<yd;){let gd=_d+yd>>1,Ed=ld[gd],Td=td(Ed),Od=rd(Ed);if(Td<=sd&&od<=Od)return qr $ 3(Ed,qa,Ja,Ed);if(Od<=sd){cd=Ed,_d=gd+1;continue}if(od<=Td){ud=Ed,yd=gd;continue}throw new Error("Comment location overlaps with node location")}if((ed==null?void 0:ed.type)==="TemplateLiteral"){let{quasis:gd}=ed,Ed=Rt $ 4(gd,qa,Ja);cd&&Rt $ 4(gd,cd,Ja)!==Ed&&(cd=null),ud&&Rt $ 4(gd,ud,Ja)!==Ed&&(ud=null)}return{enclosingNode:ed,precedingNode:cd,followingNode:ud}}var It $ 3=()=>!1;function Jr $ 3(Ra,qa){let{comments:Ja}=Ra;if(delete Ra.comments,!kt $ 3(Ja)||!qa.printer.canAttachComment)return;let ed=[],{locStart:td,locEnd:rd,printer:{experimentalFeatures:{avoidAstMutation:sd=!1}={},handleComments:od={}},originalText:ld}=qa,{ownLine:cd=It $ 3,endOfLine:ud=It $ 3,remaining:_d=It $ 3}=od,yd=Ja.map((gd,Ed)=>({...qr $ 3(Ra,gd,qa),comment:gd,text:ld,options:qa,ast:Ra,isLastComment:Ja.length-1===Ed}));for(let[gd,Ed]of yd.entries()){let{comment:Td,precedingNode:Od,enclosingNode:Rd,followingNode:Nd,text:Id,options:Md,ast:Ld,isLastComment:Pd}=Ed;if(Md.parser==="json"||Md.parser==="json5"||Md.parser==="jsonc"||Md.parser==="__js_expression"||Md.parser==="__ts_expression"||Md.parser==="__vue_expression"||Md.parser==="__vue_ts_expression"){if(td(Td)-td(Ld)<=0){ue $ 2(Ld,Td);continue}if(rd(Td)-rd(Ld)>=0){oe $ 3(Ld,Td);continue}}let qd;if(sd?qd=[Ed]:(Td.enclosingNode=Rd,Td.precedingNode=Od,Td.followingNode=Nd,qd=[Td,Id,Md,Ld,Pd]),ro $ 1(Id,Md,yd,gd))Td.placement="ownLine",cd(...qd)||(Nd?ue $ 2(Nd,Td):Od?oe $ 3(Od,Td):re $ 4(Rd||Ld,Td));else if(no $ 2(Id,Md,yd,gd))Td.placement="endOfLine",ud(...qd)||(Od?oe $ 3(Od,Td):Nd?ue $ 2(Nd,Td):re $ 4(Rd||Ld,Td));else if(Td.placement="remaining",!_d(...qd))if(Od&&Nd){let Yd=ed.length;Yd>0&&ed[Yd-1].followingNode!==Nd&&Kr $ 4(ed,Md),ed.push(Ed)}else Od?oe $ 3(Od,Td):Nd?ue $ 2(Nd,Td):re $ 4(Rd||Ld,Td)}if(Kr $ 4(ed,qa),!sd)for(let gd of Ja)delete gd.precedingNode,delete gd.enclosingNode,delete gd.followingNode}var Xr $ 3=Ra=>!/[ \S \n \u 2028 \u 2029]/u.test(Ra);function ro $ 1(Ra,qa,Ja,ed){let{comment:td,precedingNode:rd}=Ja[ed],{locStart:sd,locEnd:od}=qa,ld=sd(td);if(rd)for(let cd=ed-1;cd>=0;cd--){let{comment:ud,precedingNode:_d}=Ja[cd];if(_d!==rd||!Xr $ 3(Ra.slice(od(ud),ld)))break;ld=sd(ud)}return V $ 4(Ra,ld,{backwards:!0})}function no $ 2(Ra,qa,Ja,ed){let{comment:td,followingNode:rd}=Ja[ed],{locStart:sd,locEnd:od}=qa,ld=od(td);if(rd)for(let cd=ed+1;cd<Ja.length;cd++){let{comment:ud,followingNode:_d}=Ja[cd];if(_d!==rd||!Xr $ 3(Ra.slice(ld,sd(ud))))break;ld=od(ud)}return V $ 4(Ra,ld)}function Kr $ 4(Ra,qa){var Ja
2024-08-30 15:19:18 +08:00
( mixed values within one file are normalised by looking at what 's used after the first line)`}]},filepath:{category:"Special",type:"path",description:"Specify the input filepath. This will be used to do parser inference.",cliName:"stdin-filepath",cliCategory:"Other",cliDescription:"Path to the file to pretend that stdin comes from."},insertPragma:{category:"Special",type:"boolean",default:!1,description:"Insert @format pragma into file' s first docblock comment . ",cliCategory:" Other "},parser:{category:" Global ",type:" choice ",default:void 0,description:" Which parser to use . ",exception:Ra=>typeof Ra==" string "||typeof Ra==" function ",choices:[{value:" flow ",description:" Flow "},{value:" babel ",description:" JavaScript "},{value:" babel - flow ",description:" Flow "},{value:" babel - ts ",description:" TypeScript "},{value:" typescript ",description:" TypeScript "},{value:" acorn ",description:" JavaScript "},{value:" espree ",description:" JavaScript "},{value:" meriyah ",description:" JavaScript "},{value:" css ",description:" CSS "},{value:" less ",description:" Less "},{value:" scss ",description:" SCSS "},{value:" json ",description:" JSON "},{value:" json5 ",description:" JSON5 "},{value:" jsonc ",description:" JSON with Comments "},{value:" json - stringify ",description:" JSON . stringify "},{value:" graphql ",description:" GraphQL "},{value:" markdown ",description:" Markdown "},{value:" mdx ",description:" MDX "},{value:" vue ",description:" Vue "},{value:" yaml ",description:" YAML "},{value:" glimmer ",description:" Ember / Handlebars "},{value:" html ",description:" HTML "},{value:" angular ",description:" Angular "},{value:" lwc ",description:" Lightning Web Components "}]},plugins:{type:" path ",array:!0,default:[{value:[]}],category:" Global ",description:" Add a plugin . Multiple plugins can be passed as separate ` --plugin ` s . ",exception:Ra=>typeof Ra==" string "||typeof Ra==" object ",cliName:" plugin ",cliCategory:" Config "},printWidth:{category:" Global ",type:" int ",default:80,description:" The line length where Prettier will try wrap . ",range:{start:0,end:1/0,step:1}},rangeEnd:{category:" Special ",type:" int " , default : 1 / 0 , range : { start : 0 , end : 1 / 0 , step : 1 } , description : ` Format code ending at a given character offset (exclusive).
The range will extend forwards to the end of the selected statement . ` ,cliCategory:"Editor"},rangeStart:{category:"Special",type:"int",default:0,range:{start:0,end:1/0,step:1},description: ` Format code starting at a given character offset .
The range will extend backwards to the start of the first line containing the selected statement . ` ,cliCategory:"Editor"},requirePragma:{category:"Special",type:"boolean",default:!1,description: ` Require either '@prettier' or '@format' to be present in the file ' s first docblock comment
2024-09-03 08:22:14 +08:00
in order for it to be formatted . ` ,cliCategory:"Other"},tabWidth:{type:"int",category:"Global",default:2,description:"Number of spaces per indentation level.",range:{start:0,end:1/0,step:1}},useTabs:{category:"Global",type:"boolean",default:!1,description:"Indent with tabs instead of spaces."},embeddedLanguageFormatting:{category:"Global",type:"choice",default:"auto",description:"Control how Prettier formats quoted code embedded in the file.",choices:[{value:"auto",description:"Format embedded code if Prettier can automatically identify it."},{value:"off",description:"Never automatically format embedded code."}]}};function ot $ 1({plugins:Ra=[],showDeprecated:qa=!1}={}){let Ja=Ra.flatMap(td=>td.languages??[]),ed=[];for(let td of lo $ 3(Object.assign({},...Ra.map(({options:rd})=>rd),rn $ 2)))!qa&&td.deprecated||(Array.isArray(td.choices)&&(qa||(td.choices=td.choices.filter(rd=>!rd.deprecated)),td.name==="parser"&&(td.choices=[...td.choices,...Do $ 2(td.choices,Ja,Ra)])),td.pluginDefaults=Object.fromEntries(Ra.filter(rd=>{var sd;return((sd=rd.defaultOptions)==null?void 0:sd[td.name])!==void 0}).map(rd=>[rd.name,rd.defaultOptions[td.name]])),ed.push(td));return{languages:Ja,options:ed}}function*Do $ 2(Ra,qa,Ja){let ed=new Set(Ra.map(td=>td.value));for(let td of qa)if(td.parsers){for(let rd of td.parsers)if(!ed.has(rd)){ed.add(rd);let sd=Ja.find(ld=>ld.parsers&&Object.prototype.hasOwnProperty.call(ld.parsers,rd)),od=td.name;sd!=null&&sd.name&&(od+= ` ( plugin : $ { sd . name } ) ` ),yield{value:rd,description:od}}}}function lo $ 3(Ra){let qa=[];for(let[Ja,ed]of Object.entries(Ra)){let td={name:Ja,...ed};Array.isArray(td.default)&&(td.default=y $ 1(!1,td.default,-1).value),qa.push(td)}return qa}var co $ 2=Ra=>String(Ra).split(/[/ \\ ]/u).pop();function nn $ 2(Ra,qa){if(!qa)return;let Ja=co $ 2(qa).toLowerCase();return Ra.find(({filenames:ed})=>ed==null?void 0:ed.some(td=>td.toLowerCase()===Ja))??Ra.find(({extensions:ed})=>ed==null?void 0:ed.some(td=>Ja.endsWith(td)))}function fo $ 1(Ra,qa){if(qa)return Ra.find(({name:Ja})=>Ja.toLowerCase()===qa)??Ra.find(({aliases:Ja})=>Ja==null?void 0:Ja.includes(qa))??Ra.find(({extensions:Ja})=>Ja==null?void 0:Ja.includes( ` . $ { qa } ` ))}function po $ 2(Ra,qa){let Ja=Ra.plugins.flatMap(td=>td.languages??[]),ed=fo $ 1(Ja,qa.language)??nn $ 2(Ja,qa.physicalFile)??nn $ 2(Ja,qa.file)??(qa.physicalFile,void 0);return ed==null?void 0:ed.parsers[0]}var un $ 2=po $ 2,ie $ 3={key:Ra=>/^[ $ _a-zA-Z][ $ _a-zA-Z0-9]* $ /.test(Ra)?Ra:JSON.stringify(Ra),value(Ra){if(Ra===null||typeof Ra!="object")return JSON.stringify(Ra);if(Array.isArray(Ra))return ` [ $ { Ra . map ( Ja => ie$3 . value ( Ja ) ) . join ( ", " ) } ] ` ;let qa=Object.keys(Ra);return qa.length===0?"{}": ` { $ { qa . map ( Ja => ` ${ ie$3 . key ( Ja ) } : ${ ie$3 . value ( Ra [ Ja ] ) } ` ) . join ( ", " ) } } ` },pair:({key:Ra,value:qa})=>ie $ 3.value({[Ra]:qa})},Yt $ 1=Me $ 5(it $ 2()),an $ 2=(Ra,qa,{descriptor:Ja})=>{let ed=[ ` $ { Yt$1 . default . yellow ( typeof Ra == "string" ? Ja . key ( Ra ) : Ja . pair ( Ra ) ) } is deprecated ` ];return qa&&ed.push( ` we now treat it as $ { Yt$1 . default . blue ( typeof qa == "string" ? Ja . key ( qa ) : Ja . pair ( qa ) ) } ` ),ed.join("; ")+"."},le $ 3=Me $ 5(it $ 2()),st $ 1=Symbol.for("vnopts.VALUE_NOT_EXIST"),he $ 2=Symbol.for("vnopts.VALUE_UNCHANGED"),Dn $ 3=" ".repeat(2),cn $ 3=(Ra,qa,Ja)=>{let{text:ed,list:td}=Ja.normalizeExpectedResult(Ja.schemas[Ra].expected(Ja)),rd=[];return ed&&rd.push(ln $ 2(Ra,qa,ed,Ja.descriptor)),td&&rd.push([ln $ 2(Ra,qa,td.title,Ja.descriptor)].concat(td.values.map(sd=>fn $ 2(sd,Ja.loggerPrintWidth))).join( `
2024-08-30 15:19:18 +08:00
` )),pn $ 2(rd,Ja.loggerPrintWidth)};function ln $ 2(Ra,qa,Ja,ed){return[ ` Invalid $ { le$3 . default . red ( ed . key ( Ra ) ) } value . ` , ` Expected $ { le$3 . default . blue ( Ja ) } , ` , ` but received $ { qa === st$1 ? le$3 . default . gray ( "nothing" ) : le$3 . default . red ( ed . value ( qa ) ) } . ` ].join(" ")}function fn $ 2({text:Ra,list:qa},Ja){let ed=[];return Ra&&ed.push( ` - $ { le$3 . default . blue ( Ra ) } ` ),qa&&ed.push([ ` - $ { le$3 . default . blue ( qa . title ) } : ` ].concat(qa.values.map(td=>fn $ 2(td,Ja-Dn $ 3.length).replace(/^| \n /g, ` $ & $ { Dn$3 } ` ))).join( `
2024-09-03 08:22:14 +08:00
` )),pn $ 2(ed,Ja)}function pn $ 2(Ra,qa){if(Ra.length===1)return Ra[0];let[Ja,ed]=Ra,[td,rd]=Ra.map(sd=>sd.split( `
2024-09-08 17:22:36 +08:00
` ,1)[0].length);return td>qa&&td>rd?ed:Ja}var Wt $ 1=Me $ 5(it $ 2()),jt $ 2=[],dn $ 3=[];function Ht $ 3(Ra,qa){if(Ra===qa)return 0;let Ja=Ra;Ra.length>qa.length&&(Ra=qa,qa=Ja);let ed=Ra.length,td=qa.length;for(;ed>0&&Ra.charCodeAt(~-ed)===qa.charCodeAt(~-td);)ed--,td--;let rd=0;for(;rd<ed&&Ra.charCodeAt(rd)===qa.charCodeAt(rd);)rd++;if(ed-=rd,td-=rd,ed===0)return td;let sd,od,ld,cd,ud=0,_d=0;for(;ud<ed;)dn $ 3[ud]=Ra.charCodeAt(rd+ud),jt $ 2[ud]=++ud;for(;_d<td;)for(sd=qa.charCodeAt(rd+_d),ld=_d++,od=_d,ud=0;ud<ed;ud++)cd=sd===dn $ 3[ud]?ld:ld+1,ld=jt $ 2[ud],od=jt $ 2[ud]=ld>od?cd>od?od+1:cd:cd>ld?ld+1:cd;return od}var at $ 3=(Ra,qa,{descriptor:Ja,logger:ed,schemas:td})=>{let rd=[ ` Ignored unknown option $ { Wt$1 . default . yellow ( Ja . pair ( { key : Ra , value : qa } ) ) } . ` ],sd=Object.keys(td).sort().find(od=>Ht $ 3(Ra,od)<3);sd&&rd.push( ` Did you mean $ { Wt$1 . default . blue ( Ja . key ( sd ) ) } ? ` ),ed.warn(rd.join(" "))},Fo $ 2=["default","expected","validate","deprecated","forward","redirect","overlap","preprocess","postprocess"];function mo $ 3(Ra,qa){let Ja=new Ra(qa),ed=Object.create(Ja);for(let td of Fo $ 2)td in qa&&(ed[td]=Eo $ 1(qa[td],Ja,O $ 2.prototype[td].length));return ed}var O $ 2=class{static create(qa){return mo $ 3(this,qa)}constructor(qa){this.name=qa.name}default(qa){}expected(qa){return"nothing"}validate(qa,Ja){return!1}deprecated(qa,Ja){return!1}forward(qa,Ja){}redirect(qa,Ja){}overlap(qa,Ja,ed){return qa}preprocess(qa,Ja){return qa}postprocess(qa,Ja){return he $ 2}};function Eo $ 1(Ra,qa,Ja){return typeof Ra=="function"?(...ed)=>Ra(...ed.slice(0,Ja-1),qa,...ed.slice(Ja-1)):()=>Ra}var Dt $ 4=class extends O $ 2{constructor(qa){super(qa),this._sourceName=qa.sourceName}expected(qa){return qa.schemas[this._sourceName].expected(qa)}validate(qa,Ja){return Ja.schemas[this._sourceName].validate(qa,Ja)}redirect(qa,Ja){return this._sourceName}},lt $ 2=class extends O $ 2{expected(){return"anything"}validate(){return!0}},ct $ 1=class extends O $ 2{constructor({valueSchema:qa,name:Ja=qa.name,...ed}){super({...ed,name:Ja}),this._valueSchema=qa}expected(qa){let{text:Ja,list:ed}=qa.normalizeExpectedResult(this._valueSchema.expected(qa));return{text:Ja&& ` an array of $ { Ja } ` ,list:ed&&{title:"an array of the following values",values:[{list:ed}]}}}validate(qa,Ja){if(!Array.isArray(qa))return!1;let ed=[];for(let td of qa){let rd=Ja.normalizeValidateResult(this._valueSchema.validate(td,Ja),td);rd!==!0&&ed.push(rd.value)}return ed.length===0?!0:{value:ed}}deprecated(qa,Ja){let ed=[];for(let td of qa){let rd=Ja.normalizeDeprecatedResult(this._valueSchema.deprecated(td,Ja),td);rd!==!1&&ed.push(...rd.map(({value:sd})=>({value:[sd]})))}return ed}forward(qa,Ja){let ed=[];for(let td of qa){let rd=Ja.normalizeForwardResult(this._valueSchema.forward(td,Ja),td);ed.push(...rd.map(Fn $ 2))}return ed}redirect(qa,Ja){let ed=[],td=[];for(let rd of qa){let sd=Ja.normalizeRedirectResult(this._valueSchema.redirect(rd,Ja),rd);"remain"in sd&&ed.push(sd.remain),td.push(...sd.redirect.map(Fn $ 2))}return ed.length===0?{redirect:td}:{redirect:td,remain:ed}}overlap(qa,Ja){return qa.concat(Ja)}};function Fn $ 2({from:Ra,to:qa}){return{from:[Ra],to:qa}}var ft $ 2=class extends O $ 2{expected(){return"true or false"}validate(qa){return typeof qa=="boolean"}};function En $ 2(Ra,qa){let Ja=Object.create(null);for(let ed of Ra){let td=ed[qa];if(Ja[td])throw new Error( ` Duplicate $ { qa } $ { JSON . stringify ( td ) } ` );Ja[td]=ed}return Ja}function hn $ 2(Ra,qa){let Ja=new Map;for(let ed of Ra){let td=ed[qa];if(Ja.has(td))throw new Error( ` Duplicate $ { qa } $ { JSON . stringify ( td ) } ` );Ja.set(td,ed)}return Ja}function Cn $ 3(){let Ra=Object.create(null);return qa=>{let Ja=JSON.stringify(qa);return Ra[Ja]?!0:(Ra[Ja]=!0,!1)}}function gn $ 3(Ra,qa){let Ja=[],ed=[];for(let td of Ra)qa(td)?Ja.push(td):ed.push(td);return[Ja,ed]}function yn $ 3(Ra){return Ra===Math.floor(Ra)}function An $ 2(Ra,qa){if(Ra===qa)return 0;let Ja=typeof Ra,ed=typeof qa,td=["undefined","object","boolean","number","string"];return Ja!==ed?td.indexOf(Ja)-td.indexOf(ed):Ja!=="string"?Number(Ra)-Number(qa):Ra.localeCompare(qa)}function Bn $ 3(Ra){return(...qa)=>{let Ja=Ra(...qa);return typeof Ja=="string"?new
` +ed,Ra.codeFrame=ed,Ra}throw Ra}var ce $ 3=ko $ 1;async function Un $ 3(Ra,qa,Ja,ed,td){let{embeddedLanguageFormatting:rd,printer:{embed:sd,hasPrettierIgnore:od=()=>!1,getVisitorKeys:ld}}=Ja;if(!sd||rd!=="auto")return;if(sd.length>2)throw new Error("printer.embed has too many parameters. The API changed in Prettier v3. Please update your plugin. See https://prettier.io/docs/en/plugins.html#optional-embed");let cd=X $ 2(sd.getVisitorKeys??ld),ud=[];gd();let _d=Ra.stack;for(let{print:Ed,node:Td,pathStack:Od}of ud)try{Ra.stack=Od;let Rd=await Ed(yd,qa,Ra,Ja);Rd&&td.set(Td,Rd)}catch(Rd){if(globalThis.PRETTIER_DEBUG)throw Rd}Ra.stack=_d;function yd(Ed,Td){return Po $ 1(Ed,Td,Ja,ed)}function gd(){let{node:Ed}=Ra;if(Ed===null||typeof Ed!="object"||od(Ra))return;for(let Od of cd(Ed))Array.isArray(Ed[Od])?Ra.each(gd,Od):Ra.call(gd,Od);let Td=sd(Ra,Ja);if(Td){if(typeof Td=="function"){ud.push({print:Td,node:Ed,pathStack:[...Ra.stack]});return}td.set(Ed,Td)}}}async function Po $ 1(Ra,qa,Ja,ed){let td=await se $ 2({...Ja,...qa,parentParser:Ja.parser,originalText:Ra},{passThrough:!0}),{ast:rd}=await ce $ 3(Ra,td),sd=await ed(rd,td);return Ze $ 3(sd)}function Io $ 1(Ra,qa){let{originalText:Ja,[Symbol.for("comments")]:ed,locStart:td,locEnd:rd,[Symbol.for("printedComments")]:sd}=qa,{node:od}=Ra,ld=td(od),cd=rd(od);for(let ud of ed)td(ud)>=ld&&rd(ud)<=cd&&sd.add(ud);return Ja.slice(ld,cd)}var zn $ 3=Io $ 1;async function Ye $ 2(Ra,qa){({ast:Ra}=await Qt $ 2(Ra,qa));let Ja=new Map,ed=new Mr $ 3(Ra),td=new Map;await Un $ 3(ed,sd,qa,Ye $ 2,td);let rd=await Gn $ 4(ed,qa,sd,void 0,td);return en $ 2(qa),rd;function sd(ld,cd){return ld===void 0||ld===ed?od(cd):Array.isArray(ld)?ed.call(()=>od(cd),...ld):ed.call(()=>od(cd),ld)}function od(ld){let cd=ed.node;if(cd==null)return"";let ud=cd&&typeof cd=="object"&&ld===void 0;if(ud&&Ja.has(cd))return Ja.get(cd);let _d=Gn $ 4(ed,qa,sd,ld,td);return ud&&Ja.set(cd,_d),_d}}function Gn $ 4(Ra,qa,Ja,ed,td){var rd;let{node:sd}=Ra,{printer:od}=qa,ld;return(rd=od.hasPrettierIgnore)!=null&&rd.call(od,Ra)?ld=zn $ 3(Ra,qa):td.has(sd)?ld=td.get(sd):ld=od.print(Ra,qa,Ja,ed),sd===qa.cursorNode&&(ld=Qe $ 2(ld,cd=>[ve $ 3,cd,ve $ 3])),od.printComment&&(!od.willPrintOwnComments||!od.willPrintOwnComments(Ra,qa))&&(ld=Qr $ 4(Ra,ld,qa)),ld}async function Qt $ 2(Ra,qa){let Ja=Ra.comments??[];qa[Symbol.for("comments")]=Ja,qa[Symbol.for("tokens")]=Ra.tokens??[],qa[Symbol.for("printedComments")]=new Set,Jr $ 3(Ra,qa);let{printer:{preprocess:ed}}=qa;return Ra=ed?await ed(Ra,qa):Ra,{ast:Ra,comments:Ja}}function Ro $ 1(Ra,qa){let{cursorOffset:Ja,locStart:ed,locEnd:td}=qa,rd=X $ 2(qa.printer.getVisitorKeys),sd=ld=>ed(ld)<=Ja&&td(ld)>=Ja,od=Ra;for(let ld of Ur $ 3(Ra,{getVisitorKeys:rd,filter:sd}))od=ld;return od}var Kn $ 3=Ro $ 1;function Yo $ 1(Ra,qa){let{printer:{massageAstNode:Ja,getVisitorKeys:ed}}=qa;if(!Ja)return Ra;let td=X $ 2(ed),rd=Ja.ignoredProperties??new Set;return sd(Ra);function sd(od,ld){if(!(od!==null&&typeof od=="object"))return od;if(Array.isArray(od))return od.map(yd=>sd(yd,ld)).filter(Boolean);let cd={},ud=new Set(td(od));for(let yd in od)!Object.prototype.hasOwnProperty.call(od,yd)||rd.has(yd)||(ud.has(yd)?cd[yd]=sd(od[yd],od):cd[yd]=od[yd]);let _d=Ja(od,cd,ld);if(_d!==null)return _d??cd}}var qn $ 3=Yo $ 1,jo $ 2=(Ra,qa,Ja)=>{if(!(Ra&&qa==null)){if(qa.findLastIndex)return qa.findLastIndex(Ja);for(let ed=qa.length-1;ed>=0;ed--){let td=qa[ed];if(Ja(td,ed,qa))return ed}return-1}},Jn $ 4=jo $ 2,Ho $ 3=({parser:Ra})=>Ra==="json"||Ra==="json5"||Ra==="jsonc"||Ra==="json-stringify";function Wo $ 2(Ra,qa){let Ja=[Ra.node,...Ra.parentNodes],ed=new Set([qa.node,...qa.parentNodes]);return Ja.find(td=>Qn $ 4.has(td.type)&&ed.has(td))}function Xn $ 4(Ra){let qa=Jn $ 4(!1,Ra,Ja=>Ja.type!=="Program"&&Ja.type!=="File");return qa===-1?Ra:Ra.slice(0,qa+1)}function Mo $ 3(Ra,qa,{locStart:Ja,locEnd:ed}){let td=Ra.node,rd=qa.node;if(td===rd)return{startNode:td,endNode:rd};let sd=Ja(Ra.node);for(let ld of Xn $ 4(qa.parentNodes))if(Ja(ld)>=sd)rd=ld;else break;let od=ed(qa.node);for(let ld of Xn $ 4(Ra.parentNodes)){if(ed(ld)<=od)td=ld;else break;if(td===rd)break}return{startNode:td,endNode:rd}}function er $ 2(Ra,qa,Ja,ed,td=
2024-09-03 08:22:14 +08:00
` ,td)+1),ld=ed.slice(od,td).match(/^ \s */u)[0],cd=me $ 1(ld,qa.tabWidth),ud=await ou $ 3(sd,{...qa,rangeStart:0,rangeEnd:Number.POSITIVE_INFINITY,cursorOffset:qa.cursorOffset>td&&qa.cursorOffset<=rd?qa.cursorOffset-td:-1,endOfLine:"lf"},cd),_d=ud.formatted.trimEnd(),{cursorOffset:yd}=qa;yd>rd?yd+=_d.length-sd.length:ud.cursorOffset>=0&&(yd=ud.cursorOffset+td);let gd=ed.slice(0,td)+_d+ed.slice(rd);if(qa.endOfLine!=="lf"){let Ed=Be $ 4(qa.endOfLine);yd>=0&&Ed=== ` \ r
2024-08-31 11:28:56 +08:00
` &&(yd+=wt $ 2(gd.slice(0,yd), `
` )),gd=ne $ 3(!1,gd, `
2024-09-03 08:22:14 +08:00
` ,Ed)}return{formatted:gd,cursorOffset:yd,comments:ud.comments}}function tr $ 2(Ra,qa,Ja){return typeof qa!="number"||Number.isNaN(qa)||qa<0||qa>Ra.length?Ja:qa}function ru $ 3(Ra,qa){let{cursorOffset:Ja,rangeStart:ed,rangeEnd:td}=qa;return Ja=tr $ 2(Ra,Ja,-1),ed=tr $ 2(Ra,ed,0),td=tr $ 2(Ra,td,Ra.length),{...qa,cursorOffset:Ja,rangeStart:ed,rangeEnd:td}}function iu $ 2(Ra,qa){let{cursorOffset:Ja,rangeStart:ed,rangeEnd:td,endOfLine:rd}=ru $ 3(Ra,qa),sd=Ra.charAt(0)===uu $ 4;if(sd&&(Ra=Ra.slice(1),Ja--,ed--,td--),rd==="auto"&&(rd=Fr $ 2(Ra)),Ra.includes(" \r ")){let od=ld=>wt $ 2(Ra.slice(0,Math.max(ld,0)), ` \ r
2024-09-08 17:22:36 +08:00
` );Ja-=od(Ja),ed-=od(ed),td-=od(td),Ra=mr $ 2(Ra)}return{hasBOM:sd,text:Ra,options:ru $ 3(Ra,{...qa,cursorOffset:Ja,rangeStart:ed,rangeEnd:td,endOfLine:rd})}}async function nu $ 4(Ra,qa){let Ja=await ht $ 3(qa);return!Ja.hasPragma||Ja.hasPragma(Ra)}async function rr $ 2(Ra,qa){let{hasBOM:Ja,text:ed,options:td}=iu $ 2(Ra,await se $ 2(qa));if(td.rangeStart>=td.rangeEnd&&ed!==""||td.requirePragma&&!await nu $ 4(ed,td))return{formatted:Ra,cursorOffset:qa.cursorOffset,comments:[]};let rd;return td.rangeStart>0||td.rangeEnd<ed.length?rd=await Uo $ 3(ed,td):(!td.requirePragma&&td.insertPragma&&td.printer.insertPragma&&!await nu $ 4(ed,td)&&(ed=td.printer.insertPragma(ed)),rd=await ou $ 3(ed,td)),Ja&&(rd.formatted=uu $ 4+rd.formatted,rd.cursorOffset>=0&&rd.cursorOffset++),rd}async function su $ 3(Ra,qa,Ja){let{text:ed,options:td}=iu $ 2(Ra,await se $ 2(qa)),rd=await ce $ 3(ed,td);return Ja&&(Ja.preprocessForPrint&&(rd.ast=await Qt $ 2(rd.ast,td)),Ja.massage&&(rd.ast=qn $ 3(rd.ast,td))),rd}async function au $ 3(Ra,qa){qa=await se $ 2(qa);let Ja=await Ye $ 2(Ra,qa);return Fe $ 2(Ja,qa)}async function Du $ 2(Ra,qa){let Ja=Or $ 3(Ra),{formatted:ed}=await rr $ 2(Ja,{...qa,parser:"__js_expression"});return ed}async function lu $ 3(Ra,qa){qa=await se $ 2(qa);let{ast:Ja}=await ce $ 3(Ra,qa);return Ye $ 2(Ja,qa)}async function cu $ 2(Ra,qa){return Fe $ 2(Ra,await se $ 2(qa))}var nr $ 2={};We $ 1(nr $ 2,{builders:()=>Go $ 1,printer:()=>Ko $ 2,utils:()=>qo $ 1});var Go $ 1={join:be $ 5,line:Ke $ 2,softline:vr $ 2,hardline:q $ 2,literalline:qe $ 3,group:_t $ 2,conditionalGroup:Ar $ 2,fill:Ge $ 2,lineSuffix:xe $ 3,lineSuffixBoundary:xr $ 3,cursor:ve $ 3,breakParent:de $ 2,ifBreak:Br $ 4,trim:_r $ 3,indent:De $ 2,indentIfBreak:wr $ 3,align:ae $ 2,addAlignmentToDoc:Je $ 3,markAsRoot:gr $ 2,dedentToRoot:Cr $ 1,dedent:yr $ 2,hardlineWithoutBreakParent:_e $ 4,literallineWithoutBreakParent:vt $ 3,label:br $ 2,concat:Ra=>Ra},Ko $ 2={printDocToString:Fe $ 2},qo $ 1={willBreak:Ir $ 3,traverseDoc:we $ 2,findInDoc:Xe $ 2,mapDoc:Ne $ 2,removeLines:Yr $ 4,stripTrailingHardline:Ze $ 3,replaceEndOfLine:jr $ 3,canBreak:Hr $ 4},fu $ 1="3.3.3",or $ 2={};We $ 1(or $ 2,{addDanglingComment:()=>re $ 4,addLeadingComment:()=>ue $ 2,addTrailingComment:()=>oe $ 3,getAlignmentSize:()=>me $ 1,getIndentSize:()=>pu $ 2,getMaxContinuousCount:()=>du $ 3,getNextNonSpaceNonCommentCharacter:()=>Fu $ 2,getNextNonSpaceNonCommentCharacterIndex:()=>si $ 4,getStringWidth:()=>Oe $ 4,hasNewline:()=>V $ 4,hasNewlineInRange:()=>mu $ 2,hasSpaces:()=>Eu $ 2,isNextLineEmpty:()=>ci $ 3,isNextLineEmptyAfterIndex:()=>gt $ 2,isPreviousLineEmpty:()=>Di $ 3,makeString:()=>hu $ 2,skip:()=>Ee $ 3,skipEverythingButNewLine:()=>nt $ 1,skipInlineComment:()=>Ce $ 2,skipNewline:()=>M $ 3,skipSpaces:()=>T $ 1,skipToLineEnd:()=>rt $ 2,skipTrailingComment:()=>ge $ 4,skipWhitespace:()=>zr $ 3});function Jo $ 2(Ra,qa){if(qa===!1)return!1;if(Ra.charAt(qa)==="/"&&Ra.charAt(qa+1)==="*"){for(let Ja=qa+2;Ja<Ra.length;++Ja)if(Ra.charAt(Ja)==="*"&&Ra.charAt(Ja+1)==="/")return Ja+2}return qa}var Ce $ 2=Jo $ 2;function Xo $ 1(Ra,qa){return qa===!1?!1:Ra.charAt(qa)==="/"&&Ra.charAt(qa+1)==="/"?nt $ 1(Ra,qa):qa}var ge $ 4=Xo $ 1;function Zo $ 2(Ra,qa){let Ja=null,ed=qa;for(;ed!==Ja;)Ja=ed,ed=T $ 1(Ra,ed),ed=Ce $ 2(Ra,ed),ed=ge $ 4(Ra,ed),ed=M $ 3(Ra,ed);return ed}var je $ 4=Zo $ 2;function Qo $ 2(Ra,qa){let Ja=null,ed=qa;for(;ed!==Ja;)Ja=ed,ed=rt $ 2(Ra,ed),ed=Ce $ 2(Ra,ed),ed=T $ 1(Ra,ed);return ed=ge $ 4(Ra,ed),ed=M $ 3(Ra,ed),ed!==!1&&V $ 4(Ra,ed)}var gt $ 2=Qo $ 2;function ei $ 3(Ra,qa){let Ja=Ra.lastIndexOf( `
2024-08-30 15:19:18 +08:00
` );return Ja===-1?0:me $ 1(Ra.slice(Ja+1).match(/^[ \t ]*/u)[0],qa)}var pu $ 2=ei $ 3;function ur $ 2(Ra){if(typeof Ra!="string")throw new TypeError("Expected a string");return Ra.replace(/[| \\ {}()[ \] ^ $ +*?.]/g," \\ $ &").replace(/-/g," \\ x2d")}function ti $ 4(Ra,qa){let Ja=Ra.match(new RegExp( ` ( $ { ur$2 ( qa ) } ) + ` ,"gu"));return Ja===null?0:Ja.reduce((ed,td)=>Math.max(ed,td.length/qa.length),0)}var du $ 3=ti $ 4;function ri $ 4(Ra,qa){let Ja=je $ 4(Ra,qa);return Ja===!1?"":Ra.charAt(Ja)}var Fu $ 2=ri $ 4;function ni $ 4(Ra,qa,Ja){for(let ed=qa;ed<Ja;++ed)if(Ra.charAt(ed)=== `
2024-09-08 17:22:36 +08:00
` )return!0;return!1}var mu $ 2=ni $ 4;function ui $ 3(Ra,qa,Ja={}){return T $ 1(Ra,Ja.backwards?qa-1:qa,Ja)!==qa}var Eu $ 2=ui $ 3;function oi $ 3(Ra,qa,Ja){let ed=qa==='"'?"'":'"',td=ne $ 3(!1,Ra,/ \\ (.)|(["'])/gsu,(rd,sd,od)=>sd===ed?sd:od===qa?" \\ "+od:od||(Ja&&/^[^ \n \r "'0-7 \\ bfnrt-vx \u 2028 \u 2029] $ /u.test(sd)?sd:" \\ "+sd));return qa+td+qa}var hu $ 2=oi $ 3;function ii $ 4(Ra,qa,Ja){return je $ 4(Ra,Ja(qa))}function si $ 4(Ra,qa){return arguments.length===2||typeof qa=="number"?je $ 4(Ra,qa):ii $ 4(...arguments)}function ai $ 4(Ra,qa,Ja){return Le $ 3(Ra,Ja(qa))}function Di $ 3(Ra,qa){return arguments.length===2||typeof qa=="number"?Le $ 3(Ra,qa):ai $ 4(...arguments)}function li $ 4(Ra,qa,Ja){return gt $ 2(Ra,Ja(qa))}function ci $ 3(Ra,qa){return arguments.length===2||typeof qa=="number"?gt $ 2(Ra,qa):li $ 4(...arguments)}function fe $ 3(Ra,qa=1){return async(...Ja)=>{let ed=Ja[qa]??{},td=ed.plugins??[];return Ja[qa]={...ed,plugins:Array.isArray(td)?td:Object.values(td)},Ra(...Ja)}}var Cu $ 2=fe $ 3(rr $ 2);async function gu $ 1(Ra,qa){let{formatted:Ja}=await Cu $ 2(Ra,{...qa,cursorOffset:-1});return Ja}async function fi $ 3(Ra,qa){return await gu $ 1(Ra,qa)===Ra}var pi $ 4=fe $ 3(ot $ 1,0),di $ 3={parse:fe $ 3(su $ 3),formatAST:fe $ 3(au $ 3),formatDoc:fe $ 3(Du $ 2),printToDoc:fe $ 3(lu $ 3),printDocToString:fe $ 3(cu $ 2)},el $ 2=Object.create,ft $ 1=Object.defineProperty,rl $ 2=Object.getOwnPropertyDescriptor,tl $ 2=Object.getOwnPropertyNames,nl $ 2=Object.getPrototypeOf,il $ 2=Object.prototype.hasOwnProperty,C=(Ra,qa)=>()=>(qa||Ra((qa={exports:{}}).exports,qa),qa.exports),Ln $ 3=(Ra,qa)=>{for(var Ja in qa)ft $ 1(Ra,Ja,{get:qa[Ja],enumerable:!0})},ul $ 2=(Ra,qa,Ja,ed)=>{if(qa&&typeof qa=="object"||typeof qa=="function")for(let td of tl $ 2(qa))!il $ 2.call(Ra,td)&&td!==Ja&&ft $ 1(Ra,td,{get:()=>qa[td],enumerable:!(ed=rl $ 2(qa,td))||ed.enumerable});return Ra},Ue $ 3=(Ra,qa,Ja)=>(Ja=Ra!=null?el $ 2(nl $ 2(Ra)):{},ul $ 2(ft $ 1(Ja,"default",{value:Ra,enumerable:!0}),Ra)),xr $ 2=C((Ra,qa)=>{qa.exports=Ja;function Ja(ed){return String(ed).replace(/ \s +/g," ")}}),Pi $ 2=C((Ra,qa)=>{qa.exports=Ed;var Ja=9,ed=10,td=32,rd=33,sd=58,od=91,ld=92,cd=93,ud=94,_d=96,yd=4,gd=1024;function Ed(Ld){var Pd=this.Parser,qd=this.Compiler;Td(Pd)&&Rd(Pd,Ld),Od(qd)&&Nd(qd)}function Td(Ld){return!!(Ld&&Ld.prototype&&Ld.prototype.blockTokenizers)}function Od(Ld){return!!(Ld&&Ld.prototype&&Ld.prototype.visitors)}function Rd(Ld,Pd){for(var qd=Pd||{},Yd=Ld.prototype,Ud=Yd.blockTokenizers,Hd=Yd.inlineTokenizers,zd=Yd.blockMethods,Jd=Yd.inlineMethods,Zd=Ud.definition,pf=Hd.reference,Qd=[],hf=-1,mf=zd.length,xf;++hf<mf;)xf=zd[hf],!(xf==="newline"||xf==="indentedCode"||xf==="paragraph"||xf==="footnoteDefinition")&&Qd.push([xf]);Qd.push(["footnoteDefinition"]),qd.inlineNotes&&(Id(Jd,"reference","inlineNote"),Hd.inlineNote=Yf),Id(zd,"definition","footnoteDefinition"),Id(Jd,"reference","footnoteCall"),Ud.definition=Tf,Ud.footnoteDefinition=Lf,Hd.footnoteCall=Kf,Hd.reference=Of,Yd.interruptFootnoteDefinition=Qd,Of.locator=pf.locator,Kf.locator=wf,Yf.locator=Wf;function Lf(Uf,gf,_f){for(var $ f=this,Gf= $ f.interruptFootnoteDefinition,dh= $ f.offset,zf=gf.length+1,If=0,Jf=[],Th,Vf,Ef,Af,Pf,hh,Ah,uh,Fh,Nh,Bh,Jh,zh;If<zf&&(Af=gf.charCodeAt(If),!(Af!==Ja&&Af!==td));)If++;if(gf.charCodeAt(If++)===od&&gf.charCodeAt(If++)===ud){for(Vf=If;If<zf;){if(Af=gf.charCodeAt(If),Af!==Af||Af===ed||Af===Ja||Af===td)return;if(Af===cd){Ef=If,If++;break}If++}if(!(Ef===void 0||Vf===Ef||gf.charCodeAt(If++)!==sd)){if(_f)return!0;for(Th=gf.slice(Vf,Ef),Pf=Uf.now(),Fh=0,Nh=0,Bh=If,Jh=[];If<zf;){if(Af=gf.charCodeAt(If),Af!==Af||Af===ed)zh={start:Fh,contentStart:Bh||If,contentEnd:If,end:If},Jh.push(zh),Af===ed&&(Fh=If+1,Nh=0,Bh=void 0,zh.end=Fh);else if(Nh!==void 0)if(Af===td||Af===Ja)Nh+=Af===td?1:yd-Nh%yd,Nh>yd&&(Nh=void 0,Bh=If);else{if(Nh<yd&&zh&&(zh.contentStart===zh.contentEnd||Md(Gf,Ud, $ f,[Uf,gf.slice(If,gd),!0])))break;Nh=void 0,Bh=If}If++}for(If=-1,zf=Jh.length;zf>0&&(zh=Jh[zf-1],zh.contentStart===zh.contentEnd);)zf--;for(hh=Uf(gf.slice(0,zh.contentEnd));++If<zf;)zh=Jh[If],dh[Pf.line+If]=(dh[Pf.line+If]||0)+(zh.contentStart-zh.start),Jf.push(gf.slice(zh.contentStart,zh.end));return Ah= $ f.enterBlock(),uh= $ f.toke
2024-08-27 22:31:52 +08:00
2024-08-30 15:19:18 +08:00
` ).split( `
2024-09-08 17:22:36 +08:00
` ),Zd=0,pf=Jd.length,Qd;++Zd<pf;)Qd=Jd[Zd],Qd!==""&&(Jd[Zd]=qd+Qd);return"[^"+(zd.label||zd.identifier)+"]: "+Jd.join( `
` )}}function Id(Ld,Pd,qd){Ld.splice(Ld.indexOf(Pd),0,qd)}function Md(Ld,Pd,qd,Yd){for(var Ud=Ld.length,Hd=-1;++Hd<Ud;)if(Pd[Ld[Hd][0]].apply(qd,Yd))return!0;return!1}}),Bt $ 3=C(Ra=>{Ra.isRemarkParser=qa,Ra.isRemarkCompiler=Ja;function qa(ed){return!!(ed&&ed.prototype&&ed.prototype.blockTokenizers)}function Ja(ed){return!!(ed&&ed.prototype&&ed.prototype.visitors)}}),Mi $ 1=C((Ra,qa)=>{var Ja=Bt $ 3();qa.exports=_d;var ed=9,td=32,rd=36,sd=48,od=57,ld=92,cd=["math","math-inline"],ud="math-display";function _d(Ed){let Td=this.Parser,Od=this.Compiler;Ja.isRemarkParser(Td)&&yd(Td,Ed),Ja.isRemarkCompiler(Od)&&gd(Od)}function yd(Ed,Td){let Od=Ed.prototype,Rd=Od.inlineMethods;Id.locator=Nd,Od.inlineTokenizers.math=Id,Rd.splice(Rd.indexOf("text"),0,"math");function Nd(Md,Ld){return Md.indexOf(" $ ",Ld)}function Id(Md,Ld,Pd){let qd=Ld.length,Yd=!1,Ud=!1,Hd=0,zd,Jd,Zd,pf,Qd,hf,mf;if(Ld.charCodeAt(Hd)===ld&&(Ud=!0,Hd++),Ld.charCodeAt(Hd)===rd){if(Hd++,Ud)return Pd?!0:Md(Ld.slice(0,Hd))({type:"text",value:" $ "});if(Ld.charCodeAt(Hd)===rd&&(Yd=!0,Hd++),Zd=Ld.charCodeAt(Hd),!(Zd===td||Zd===ed)){for(pf=Hd;Hd<qd;){if(Jd=Zd,Zd=Ld.charCodeAt(Hd+1),Jd===rd){if(zd=Ld.charCodeAt(Hd-1),zd!==td&&zd!==ed&&(Zd!==Zd||Zd<sd||Zd>od)&&(!Yd||Zd===rd)){Qd=Hd-1,Hd++,Yd&&Hd++,hf=Hd;break}}else Jd===ld&&(Hd++,Zd=Ld.charCodeAt(Hd+1));Hd++}if(hf!==void 0)return Pd?!0:(mf=Ld.slice(pf,Qd+1),Md(Ld.slice(0,hf))({type:"inlineMath",value:mf,data:{hName:"span",hProperties:{className:cd.concat(Yd&&Td.inlineMathDouble?[ud]:[])},hChildren:[{type:"text",value:mf}]}}))}}}}function gd(Ed){let Td=Ed.prototype;Td.visitors.inlineMath=Od;function Od(Rd){let Nd=" $ ";return(Rd.data&&Rd.data.hProperties&&Rd.data.hProperties.className||[]).includes(ud)&&(Nd=" $ $ "),Nd+Rd.value+Nd}}}), $ i $ 2=C((Ra,qa)=>{var Ja=Bt $ 3();qa.exports=ud;var ed=10,td=32,rd=36,sd= `
` ,od=" $ ",ld=2,cd=["math","math-display"];function ud(){let gd=this.Parser,Ed=this.Compiler;Ja.isRemarkParser(gd)&&_d(gd),Ja.isRemarkCompiler(Ed)&&yd(Ed)}function _d(gd){let Ed=gd.prototype,Td=Ed.blockMethods,Od=Ed.interruptParagraph,Rd=Ed.interruptList,Nd=Ed.interruptBlockquote;Ed.blockTokenizers.math=Id,Td.splice(Td.indexOf("fencedCode")+1,0,"math"),Od.splice(Od.indexOf("fencedCode")+1,0,["math"]),Rd.splice(Rd.indexOf("fencedCode")+1,0,["math"]),Nd.splice(Nd.indexOf("fencedCode")+1,0,["math"]);function Id(Md,Ld,Pd){var qd=Ld.length,Yd=0;let Ud,Hd,zd,Jd,Zd,pf,Qd,hf,mf,xf,Lf;for(;Yd<qd&&Ld.charCodeAt(Yd)===td;)Yd++;for(Zd=Yd;Yd<qd&&Ld.charCodeAt(Yd)===rd;)Yd++;if(pf=Yd-Zd,!(pf<ld)){for(;Yd<qd&&Ld.charCodeAt(Yd)===td;)Yd++;for(Qd=Yd;Yd<qd;){if(Ud=Ld.charCodeAt(Yd),Ud===rd)return;if(Ud===ed)break;Yd++}if(Ld.charCodeAt(Yd)===ed){if(Pd)return!0;for(Hd=[],Qd!==Yd&&Hd.push(Ld.slice(Qd,Yd)),Yd++,zd=Ld.indexOf(sd,Yd+1),zd=zd===-1?qd:zd;Yd<qd;){for(hf=!1,xf=Yd,Lf=zd,Jd=zd,mf=0;Jd>xf&&Ld.charCodeAt(Jd-1)===td;)Jd--;for(;Jd>xf&&Ld.charCodeAt(Jd-1)===rd;)mf++,Jd--;for(pf<=mf&&Ld.indexOf(od,xf)===Jd&&(hf=!0,Lf=Jd);xf<=Lf&&xf-Yd<Zd&&Ld.charCodeAt(xf)===td;)xf++;if(hf)for(;Lf>xf&&Ld.charCodeAt(Lf-1)===td;)Lf--;if((!hf||xf!==Lf)&&Hd.push(Ld.slice(xf,Lf)),hf)break;Yd=zd+1,zd=Ld.indexOf(sd,Yd+1),zd=zd===-1?qd:zd}return Hd=Hd.join( `
` ),Md(Ld.slice(0,zd))({type:"math",value:Hd,data:{hName:"div",hProperties:{className:cd.concat()},hChildren:[{type:"text",value:Hd}]}})}}}}function yd(gd){let Ed=gd.prototype;Ed.visitors.math=Td;function Td(Od){return ` $$
` +Od.value+ `
2024-09-03 08:22:14 +08:00
$$ ` }}}),Wi $ 1=C((Ra,qa)=>{var Ja=Mi $ 1(),ed= $ i $ 2();qa.exports=td;function td(rd){var sd=rd||{};ed.call(this,sd),Ja.call(this,sd)}}),Ie $ 1=C((Ra,qa)=>{qa.exports=ed;var Ja=Object.prototype.hasOwnProperty;function ed(){for(var td={},rd=0;rd<arguments.length;rd++){var sd=arguments[rd];for(var od in sd)Ja.call(sd,od)&&(td[od]=sd[od])}return td}}),Ji $ 3=C((Ra,qa)=>{typeof Object.create=="function"?qa.exports=function(Ja,ed){ed&&(Ja.super_=ed,Ja.prototype=Object.create(ed.prototype,{constructor:{value:Ja,enumerable:!1,writable:!0,configurable:!0}}))}:qa.exports=function(Ja,ed){if(ed){Ja.super_=ed;var td=function(){};td.prototype=ed.prototype,Ja.prototype=new td,Ja.prototype.constructor=Ja}}}),Zi $ 1=C((Ra,qa)=>{var Ja=Ie $ 1(),ed=Ji $ 3();qa.exports=td;function td(rd){var sd,od,ld;ed(ud,rd),ed(cd,ud),sd=ud.prototype;for(od in sd)ld=sd[od],ld&&typeof ld=="object"&&(sd[od]="concat"in ld?ld.concat():Ja(ld));return ud;function cd(_d){return rd.apply(this,_d)}function ud(){return this instanceof ud?rd.apply(this,arguments):new cd(arguments)}}}),ru $ 2=C((Ra,qa)=>{qa.exports=Ja;function Ja(ed,td,rd){return sd;function sd(){var od=rd||this,ld=od[ed];return od[ed]=!td,cd;function cd(){od[ed]=ld}}}}),nu $ 3=C((Ra,qa)=>{qa.exports=Ja;function Ja(ed){for(var td=String(ed),rd=[],sd=/ \r ? \n | \r /g;sd.exec(td);)rd.push(sd.lastIndex);return rd.push(td.length+1),{toPoint:od,toPosition:od,toOffset:ld};function od(cd){var ud=-1;if(cd>-1&&cd<rd[rd.length-1]){for(;++ud<rd.length;)if(rd[ud]>cd)return{line:ud+1,column:cd-(rd[ud-1]||0)+1,offset:cd}}return{}}function ld(cd){var ud=cd&&cd.line,_d=cd&&cd.column,yd;return!isNaN(ud)&&!isNaN(_d)&&ud-1 in rd&&(yd=(rd[ud-2]||0)+_d-1||0),yd>-1&&yd<rd[rd.length-1]?yd:-1}}}),uu $ 3=C((Ra,qa)=>{qa.exports=ed;var Ja=" \\ ";function ed(td,rd){return sd;function sd(od){for(var ld=0,cd=od.indexOf(Ja),ud=td[rd],_d=[],yd;cd!==-1;)_d.push(od.slice(ld,cd)),ld=cd+1,yd=od.charAt(ld),(!yd||ud.indexOf(yd)===-1)&&_d.push(Ja),cd=od.indexOf(Ja,ld+1);return _d.push(od.slice(ld)),_d.join("")}}}),au $ 2=C((Ra,qa)=>{qa.exports={AElig:"Æ",AMP:"&",Aacute:"Á",Acirc:"Â",Agrave:"À",Aring:"Å",Atilde:"Ã",Auml:"Ä",COPY:"©",Ccedil:"Ç",ETH:"Ð",Eacute:"É",Ecirc:"Ê",Egrave:"È",Euml:"Ë",GT:">",Iacute:"Í",Icirc:"Î",Igrave:"Ì",Iuml:"Ï",LT:"<",Ntilde:"Ñ",Oacute:"Ó",Ocirc:"Ô",Ograve:"Ò",Oslash:"Ø",Otilde:"Õ",Ouml:"Ö",QUOT:'"',REG:"®",THORN:"Þ",Uacute:"Ú",Ucirc:"Û",Ugrave:"Ù",Uuml:"Ü",Yacute:"Ý",aacute:"á",acirc:"â",acute:"´ ",aelig:"æ",agrave:"à",amp:"&",aring:"å",atilde:"ã",auml:"ä",brvbar:"¦",ccedil:"ç",cedil:"¸ ",cent:"¢",copy:"©",curren:"¤",deg:"°",divide:"÷",eacute:"é",ecirc:"ê",egrave:"è",eth:"ð",euml:"ë",frac12:"½",frac14:"¼",frac34:"¾",gt:">",iacute:"í",icirc:"î",iexcl:"¡",igrave:"ì",iquest:"¿",iuml:"ï",laquo:"«",lt:"<",macr:"¯",micro:"µ",middot:"·",nbsp:" ",not:"¬",ntilde:"ñ",oacute:"ó",ocirc:"ô",ograve:"ò",ordf:"ª",ordm:"º",oslash:"ø",otilde:"õ",ouml:"ö",para:"¶",plusmn:"±",pound:"£",quot:'"',raquo:"»",reg:"®",sect:"§",shy:" ",sup1:"¹",sup2:"²",sup3:"³",szlig:"ß",thorn:"þ",times:"× ",uacute:"ú",ucirc:"û",ugrave:"ù",uml:"¨",uuml:"ü",yacute:"ý",yen:"¥",yuml:"ÿ"}}),ou $ 2=C((Ra,qa)=>{qa.exports={0:"<22> ",128:"€",130:"‚ ",131:"ƒ",132:"„",133:"…",134:"†",135:"‡",136:"ˆ ",137:"‰",138:"Š",139:"‹ ",140:"Œ",142:"Ž",145:"‘ ",146:"’ ",147:"“",148:"”",149:"•",150:"– ",151:"—",152:"˜ ",153:"™",154:"š",155:"› ",156:"œ",158:"ž",159:"Ÿ"}}),Ne $ 1=C((Ra,qa)=>{qa.exports=Ja;function Ja(ed){var td=typeof ed=="string"?ed.charCodeAt(0):ed;return td>=48&&td<=57}}),lu $ 2=C((Ra,qa)=>{qa.exports=Ja;function Ja(ed){var td=typeof ed=="string"?ed.charCodeAt(0):ed;return td>=97&&td<=102||td>=65&&td<=70||td>=48&&td<=57}}),Ve $ 2=C((Ra,qa)=>{qa.exports=Ja;function Ja(ed){var td=typeof ed=="string"?ed.charCodeAt(0):ed;return td>=97&&td<=122||td>=65&&td<=90}}),pu $ 1=C((Ra,qa)=>{var Ja=Ve $ 2(),ed=Ne $ 1();qa.exports=td;function td(rd){return Ja(rd)||ed(rd)}}),du $ 2=C((Ra,qa)=>{qa.exports={AEli:"Æ",AElig:"Æ",AM:"&",AMP:"&",Aacut:"Á",Aacute:"Á",Abreve:"Ă",Acir:"Â",Acirc:"
2024-09-08 17:22:36 +08:00
` ,Nfr:"𝔑 ",NoBreak:" ",NonBreakingSpace:" ",Nopf:"ℕ ",Not:"⫬",NotCongruent:"≢",NotCupCap:"≭",NotDoubleVerticalBar:"∦",NotElement:"∉",NotEqual:"≠",NotEqualTilde:"≂̸",NotExists:"∄",NotGreater:"≯",NotGreaterEqual:"≱",NotGreaterFullEqual:"≧̸",NotGreaterGreater:"≫̸",NotGreaterLess:"≹",NotGreaterSlantEqual:"⩾̸",NotGreaterTilde:"≵",NotHumpDownHump:"≎̸",NotHumpEqual:"≏̸",NotLeftTriangle:"⋪",NotLeftTriangleBar:"⧏̸",NotLeftTriangleEqual:"⋬",NotLess:"≮",NotLessEqual:"≰",NotLessGreater:"≸",NotLessLess:"≪̸",NotLessSlantEqual:"⩽̸",NotLessTilde:"≴",NotNestedGreaterGreater:"⪢̸",NotNestedLessLess:"⪡̸",NotPrecedes:"⊀",NotPrecedesEqual:"⪯̸",NotPrecedesSlantEqual:"⋠",NotReverseElement:"∌",NotRightTriangle:"⋫",NotRightTriangleBar:"⧐̸",NotRightTriangleEqual:"⋭",NotSquareSubset:"⊏̸",NotSquareSubsetEqual:"⋢",NotSquareSuperset:"⊐̸",NotSquareSupersetEqual:"⋣",NotSubset:"⊂⃒",NotSubsetEqual:"⊈",NotSucceeds:"⊁",NotSucceedsEqual:"⪰̸",NotSucceedsSlantEqual:"⋡",NotSucceedsTilde:"≿̸",NotSuperset:"⊃⃒",NotSupersetEqual:"⊉",NotTilde:"≁",NotTildeEqual:"≄",NotTildeFullEqual:"≇",NotTildeTilde:"≉",NotVerticalBar:"∤",Nscr:"𝒩 ",Ntild:"Ñ",Ntilde:"Ñ",Nu:"Ν ",OElig:"Œ",Oacut:"Ó",Oacute:"Ó",Ocir:"Ô",Ocirc:"Ô",Ocy:"О ",Odblac:"Ő",Ofr:"𝔒 ",Ograv:"Ò",Ograve:"Ò",Omacr:"Ō",Omega:"Ω",Omicron:"Ο ",Oopf:"𝕆 ",OpenCurlyDoubleQuote:"“",OpenCurlyQuote:"‘ ",Or:"⩔",Oscr:"𝒪 ",Oslas:"Ø",Oslash:"Ø",Otild:"Õ",Otilde:"Õ",Otimes:"⨷",Oum:"Ö",Ouml:"Ö",OverBar:"‾",OverBrace:"⏞",OverBracket:"⎴",OverParenthesis:"⏜",PartialD:"∂",Pcy:"П",Pfr:"𝔓 ",Phi:"Φ",Pi:"Π",PlusMinus:"±",Poincareplane:"ℌ ",Popf:"ℙ ",Pr:"⪻",Precedes:"≺",PrecedesEqual:"⪯",PrecedesSlantEqual:"≼",PrecedesTilde:"≾",Prime:"″",Product:"∏",Proportion:"∷",Proportional:"∝",Pscr:"𝒫 ",Psi:"Ψ",QUO:'"',QUOT:'"',Qfr:"𝔔 ",Qopf:"ℚ ",Qscr:"𝒬 ",RBarr:"⤐",RE:"®",REG:"®",Racute:"Ŕ",Rang:"⟫",Rarr:"↠",Rarrtl:"⤖",Rcaron:"Ř",Rcedil:"Ŗ",Rcy:"Р ",Re:"ℜ ",ReverseElement:"∋",ReverseEquilibrium:"⇋",ReverseUpEquilibrium:"⥯",Rfr:"ℜ ",Rho:"Ρ ",RightAngleBracket:"⟩",RightArrow:"→",RightArrowBar:"⇥",RightArrowLeftArrow:"⇄",RightCeiling:"⌉",RightDoubleBracket:"⟧",RightDownTeeVector:"⥝",RightDownVector:"⇂",RightDownVectorBar:"⥕",RightFloor:"⌋",RightTee:"⊢",RightTeeArrow:"↦",RightTeeVector:"⥛",RightTriangle:"⊳",RightTriangleBar:"⧐",RightTriangleEqual:"⊵",RightUpDownVector:"⥏",RightUpTeeVector:"⥜",RightUpVector:"↾",RightUpVectorBar:"⥔",RightVector:"⇀",RightVectorBar:"⥓",Rightarrow:"⇒",Ropf:"ℝ ",RoundImplies:"⥰",Rrightarrow:"⇛",Rscr:"ℛ ",Rsh:"↱",RuleDelayed:"⧴",SHCHcy:"Щ",SHcy:"Ш",SOFTcy:"Ь ",Sacute:"Ś",Sc:"⪼",Scaron:"Š",Scedil:"Ş",Scirc:"Ŝ",Scy:"С ",Sfr:"𝔖 ",ShortDownArrow:"↓",ShortLeftArrow:"←",ShortRightArrow:"→",ShortUpArrow:"↑",Sigma:"Σ",SmallCircle:"∘",Sopf:"𝕊 ",Sqrt:"√",Square:"□",SquareIntersection:"⊓",SquareSubset:"⊏",SquareSubsetEqual:"⊑",SquareSuperset:"⊐",SquareSupersetEqual:"⊒",SquareUnion:"⊔",Sscr:"𝒮 ",Star:"⋆",Sub:"⋐",Subset:"⋐",SubsetEqual:"⊆",Succeeds:"≻",SucceedsEqual:"⪰",SucceedsSlantEqual:"≽",SucceedsTilde:"≿",SuchThat:"∋",Sum:"∑",Sup:"⋑",Superset:"⊃",SupersetEqual:"⊇",Supset:"⋑",THOR:"Þ",THORN:"Þ",TRADE:"™",TSHcy:"Ћ",TScy:"Ц",Tab:" ",Tau:"Τ ",Tcaron:"Ť",Tcedil:"Ţ",Tcy:"Т ",Tfr:"𝔗 ",Therefore:"∴",Theta:"Θ",ThickSpace:" ",ThinSpace:" ",Tilde:"∼ ",TildeEqual:"≃",TildeFullEqual:"≅",TildeTilde:"≈",Topf:"𝕋 ",TripleDot:"⃛",Tscr:"𝒯 ",Tstrok:"Ŧ",Uacut:"Ú",Uacute:"Ú",Uarr:"↟",Uarrocir:"⥉",Ubrcy:"Ў",Ubreve:"Ŭ",Ucir:"Û",Ucirc:"Û",Ucy:"У ",Udblac:"Ű",Ufr:"𝔘 ",Ugrav:"Ù",Ugrave:"Ù",Umacr:"Ū",UnderBar:"_",UnderBrace:"⏟",UnderBracket:"⎵",UnderParenthesis:"⏝",Union:"⋃ ",UnionPlus:"⊎",Uogon:"Ų",Uopf:"𝕌 ",UpArrow:"↑",UpArrowBar:"⤒",UpArrowDownArrow:"⇅",UpDownArrow:"↕",UpEquilibrium:"⥮",UpTee:"⊥",UpTeeArrow:"↥",Uparrow:"⇑",Updownarrow:"
2024-09-07 10:27:05 +08:00
` );mf!==-1;)Td++,hf=mf,mf=Qd.indexOf( `
2024-09-08 17:22:36 +08:00
` ,mf+1);hf===-1?Od+=Qd.length:Od=Qd.length-hf,Td in _d&&(hf!==-1?Od+=_d[Td]:Od<=_d[Td]&&(Od=_d[Td]+1))}function Yd(){var Qd=[],hf=Td+1;return function(){for(var mf=Td+1;hf<mf;)Qd.push((_d[hf]||0)+1),hf++;return Qd}}function Ud(){var Qd={line:Td,column:Od};return Qd.offset=ud.toOffset(Qd),Qd}function Hd(Qd){this.start=Qd,this.end=Ud()}function zd(Qd){ld.slice(0,Qd.length)!==Qd&&ud.file.fail(new Error("Incorrectly eaten value: please report this warning on https://git.io/vg5Ft"),Ud())}function Jd(){var Qd=Ud();return hf;function hf(mf,xf){var Lf=mf.position,Kf=Lf?Lf.start:Qd,Yf=[],Of=Lf&&Lf.end.line,Tf=Qd.line;if(mf.position=new Hd(Kf),Lf&&xf&&Lf.indent){if(Yf=Lf.indent,Of<Tf){for(;++Of<Tf;)Yf.push((_d[Of]||0)+1);Yf.push(Qd.column)}xf=Yf.concat(xf)}return mf.position.indent=xf||[],mf}}function Zd(Qd,hf){var mf=hf?hf.children:yd,xf=mf[mf.length-1],Lf;return xf&&Qd.type===xf.type&&(Qd.type==="text"||Qd.type==="blockquote")&&ed(xf)&&ed(Qd)&&(Lf=Qd.type==="text"?td:rd,Qd=Lf.call(ud,xf,Qd)),Qd!==xf&&mf.push(Qd),ud.atStart&&yd.length!==0&&ud.exitStart(),Qd}function pf(Qd){var hf=Yd(),mf=Jd(),xf=Ud();return zd(Qd),Lf.reset=Kf,Kf.test=Yf,Lf.test=Yf,ld=ld.slice(Qd.length),qd(Qd),hf=hf(),Lf;function Lf(Of,Tf){return mf(Zd(mf(Of),Tf),hf)}function Kf(){var Of=Lf.apply(null,arguments);return Td=xf.line,Od=xf.column,ld=Qd+ld,Of}function Yf(){var Of=mf({});return Td=xf.line,Od=xf.column,ld=Qd+ld,Of.position}}}}function ed(sd){var od,ld;return sd.type!=="text"||!sd.position?!0:(od=sd.position.start,ld=sd.position.end,od.line!==ld.line||ld.column-od.column===sd.value.length)}function td(sd,od){return sd.value+=od.value,sd}function rd(sd,od){return this.options.commonmark||this.options.gfm?od:(sd.children=sd.children.concat(od.children),sd)}}),Uu $ 2=C((Ra,qa)=>{qa.exports=rd;var Ja=[" \\ "," ` "," * "," { "," } "," [ "," ] "," ( "," ) "," # "," + "," - "," . "," ! "," _ "," > "],ed=Ja.concat([" ~ "," | " ] ) , td = ed . concat ( [ `
` ,'"'," $ ","%","&","'",",","/",":",";","<","=","?","@","^"]);rd.default=Ja,rd.gfm=ed,rd.commonmark=td;function rd(sd){var od=sd||{};return od.commonmark?td:od.gfm?ed:Ja}}),Mu $ 1=C((Ra,qa)=>{qa.exports=["address","article","aside","base","basefont","blockquote","body","caption","center","col","colgroup","dd","details","dialog","dir","div","dl","dt","fieldset","figcaption","figure","footer","form","frame","frameset","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","iframe","legend","li","link","main","menu","menuitem","meta","nav","noframes","ol","optgroup","option","p","param","pre","section","source","title","summary","table","tbody","td","tfoot","th","thead","title","tr","track","ul"]}),Rt $ 3=C((Ra,qa)=>{qa.exports={position:!0,gfm:!0,commonmark:!1,pedantic:!1,blocks:Mu $ 1()}}),Vu $ 2=C((Ra,qa)=>{var Ja=Ie $ 1(),ed=Uu $ 2(),td=Rt $ 3();qa.exports=rd;function rd(sd){var od=this,ld=od.options,cd,ud;if(sd==null)sd={};else if(typeof sd=="object")sd=Ja(sd);else throw new Error("Invalid value ` "+sd+" ` for setting ` options ` ");for(cd in td){if(ud=sd[cd],ud==null&&(ud=ld[cd]),cd!=="blocks"&&typeof ud!="boolean"||cd==="blocks"&&typeof ud!="object")throw new Error("Invalid value ` "+ud+" ` for setting ` options . "+cd+" ` ");sd[cd]=ud}return od.options=sd,od.escape=ed(sd),od}}),Hu $ 2=C((Ra,qa)=>{qa.exports=Ja;function Ja(od){if(od==null)return sd;if(typeof od=="string")return rd(od);if(typeof od=="object")return"length"in od?td(od):ed(od);if(typeof od=="function")return od;throw new Error("Expected function, string, or object as test")}function ed(od){return ld;function ld(cd){var ud;for(ud in od)if(cd[ud]!==od[ud])return!1;return!0}}function td(od){for(var ld=[],cd=-1;++cd<od.length;)ld[cd]=Ja(od[cd]);return ud;function ud(){for(var _d=-1;++_d<ld.length;)if(ld[_d].apply(this,arguments))return!0;return!1}}function rd(od){return ld;function ld(cd){return!!(cd&&cd.type===od)}}function sd(){return!0}}),Ku $ 2=C((Ra,qa)=>{qa.exports=Ja;function Ja(ed){return ed}}),Zu $ 3=C((Ra,qa)=>{qa.exports=od;var Ja=Hu $ 2(),ed=Ku $ 2(),td=!0,rd="skip",sd=!1;od.CONTINUE=td,od.SKIP=rd,od.EXIT=sd;function od(cd,ud,_d,yd){var gd,Ed;typeof ud=="function"&&typeof _d!="function"&&(yd=_d,_d=ud,ud=null),Ed=Ja(ud),gd=yd?-1:1,Td(cd,null,[])();function Td(Od,Rd,Nd){var Id=typeof Od=="object"&&Od!==null?Od:{},Md;return typeof Id.type=="string"&&(Md=typeof Id.tagName=="string"?Id.tagName:typeof Id.name=="string"?Id.name:void 0,Ld.displayName="node ("+ed(Id.type+(Md?"<"+Md+">":""))+")"),Ld;function Ld(){var Pd=Nd.concat(Od),qd=[],Yd,Ud;if((!ud||Ed(Od,Rd,Nd[Nd.length-1]||null))&&(qd=ld(_d(Od,Nd)),qd[0]===sd))return qd;if(Od.children&&qd[0]!==rd)for(Ud=(yd?Od.children.length:-1)+gd;Ud>-1&&Ud<Od.children.length;){if(Yd=Td(Od.children[Ud],Ud,Pd)(),Yd[0]===sd)return Yd;Ud=typeof Yd[1]=="number"?Yd[1]:Ud+gd}return qd}}}function ld(cd){return cd!==null&&typeof cd=="object"&&"length"in cd?cd:typeof cd=="number"?[td,cd]:[cd]}}),ra $ 2=C((Ra,qa)=>{qa.exports=sd;var Ja=Zu $ 3(),ed=Ja.CONTINUE,td=Ja.SKIP,rd=Ja.EXIT;sd.CONTINUE=ed,sd.SKIP=td,sd.EXIT=rd;function sd(od,ld,cd,ud){typeof ld=="function"&&typeof cd!="function"&&(ud=cd,cd=ld,ld=null),Ja(od,ld,_d,ud);function _d(yd,gd){var Ed=gd[gd.length-1],Td=Ed?Ed.children.indexOf(yd):null;return cd(yd,Td,Ed)}}}),na $ 1=C((Ra,qa)=>{var Ja=ra $ 2();qa.exports=ed;function ed(sd,od){return Ja(sd,od?td:rd),sd}function td(sd){delete sd.position}function rd(sd){sd.position=void 0}}),aa $ 3=C((Ra,qa)=>{var Ja=Ie $ 1(),ed=na $ 1();qa.exports=sd;var td= `
2024-09-03 08:22:14 +08:00
` ,rd=/ \r \n | \r /g;function sd(){var od=this,ld=String(od.file),cd={line:1,column:1,offset:0},ud=Ja(cd),_d;return ld=ld.replace(rd,td),ld.charCodeAt(0)===65279&&(ld=ld.slice(1),ud.column++,ud.offset++),_d={type:"root",children:od.tokenizeBlock(ld,ud),position:{start:cd,end:od.eof||Ja(cd)}},od.options.position||ed(_d,!0),_d}}),sa $ 1=C((Ra,qa)=>{var Ja=/^[ \t ]*( \n | $ )/;qa.exports=ed;function ed(td,rd,sd){for(var od,ld="",cd=0,ud=rd.length;cd<ud&&(od=Ja.exec(rd.slice(cd)),od!=null);)cd+=od[0].length,ld+=od[0];if(ld!==""){if(sd)return!0;td(ld)}}}),Hr $ 3=C((Ra,qa)=>{var Ja="",ed;qa.exports=td;function td(rd,sd){if(typeof rd!="string")throw new TypeError("expected a string");if(sd===1)return rd;if(sd===2)return rd+rd;var od=rd.length*sd;if(ed!==rd||typeof ed>"u")ed=rd,Ja="";else if(Ja.length>=od)return Ja.substr(0,od);for(;od>Ja.length&&sd>1;)sd&1&&(Ja+=rd),sd>>=1,rd+=rd;return Ja+=rd,Ja=Ja.substr(0,od),Ja}}),Mt $ 2=C((Ra,qa)=>{qa.exports=Ja;function Ja(ed){return String(ed).replace(/ \n + $ /,"")}}),pa $ 1=C((Ra,qa)=>{var Ja=Hr $ 3(),ed=Mt $ 2();qa.exports=cd;var td= `
2024-09-08 17:22:36 +08:00
` ,rd=" ",sd=" ",od=4,ld=Ja(sd,od);function cd(ud,_d,yd){for(var gd=-1,Ed=_d.length,Td="",Od="",Rd="",Nd="",Id,Md,Ld;++gd<Ed;)if(Id=_d.charAt(gd),Ld)if(Ld=!1,Td+=Rd,Od+=Nd,Rd="",Nd="",Id===td)Rd=Id,Nd=Id;else for(Td+=Id,Od+=Id;++gd<Ed;){if(Id=_d.charAt(gd),!Id||Id===td){Nd=Id,Rd=Id;break}Td+=Id,Od+=Id}else if(Id===sd&&_d.charAt(gd+1)===Id&&_d.charAt(gd+2)===Id&&_d.charAt(gd+3)===Id)Rd+=ld,gd+=3,Ld=!0;else if(Id===rd)Rd+=Id,Ld=!0;else{for(Md="";Id===rd||Id===sd;)Md+=Id,Id=_d.charAt(++gd);if(Id!==td)break;Rd+=Md+Id,Nd+=Id}if(Od)return yd?!0:ud(Td)({type:"code",lang:null,meta:null,value:ed(Od)})}}),ma $ 1=C((Ra,qa)=>{qa.exports=cd;var Ja= `
` ,ed=" ",td=" ",rd="~",sd=" ` ",od=3,ld=4;function cd(ud,_d,yd){var gd=this,Ed=gd.options.gfm,Td=_d.length+1,Od=0,Rd=" ",Nd,Id,Md,Ld,Pd,qd,Yd,Ud,Hd,zd,Jd,Zd,pf;if(Ed){for(;Od<Td&&(Md=_d.charAt(Od),!(Md!==td&&Md!==ed));)Rd+=Md,Od++;if(Zd=Od,Md=_d.charAt(Od),!(Md!==rd&&Md!==sd)){for(Od++,Id=Md,Nd=1,Rd+=Md;Od<Td&&(Md=_d.charAt(Od),Md===Id);)Rd+=Md,Nd++,Od++;if(!(Nd<od)){for(;Od<Td&&(Md=_d.charAt(Od),!(Md!==td&&Md!==ed));)Rd+=Md,Od++;for(Ld=" ",Yd=" ";Od<Td&&(Md=_d.charAt(Od),!(Md===Ja||Id===sd&&Md===Id));)Md===td||Md===ed?Yd+=Md:(Ld+=Yd+Md,Yd=" "),Od++;if(Md=_d.charAt(Od),!(Md&&Md!==Ja)){if(yd)return!0;pf=ud.now(),pf.column+=Rd.length,pf.offset+=Rd.length,Rd+=Ld,Ld=gd.decode.raw(gd.unescape(Ld),pf),Yd&&(Rd+=Yd),Yd=" ",zd=" ",Jd=" ",Ud=" ",Hd=" ";for(var Qd=!0;Od<Td;){if(Md=_d.charAt(Od),Ud+=zd,Hd+=Jd,zd=" ",Jd=" ",Md!==Ja){Ud+=Md,Jd+=Md,Od++;continue}for(Qd?(Rd+=Md,Qd=!1):(zd+=Md,Jd+=Md),Yd=" ",Od++;Od<Td&&(Md=_d.charAt(Od),Md===td);)Yd+=Md,Od++;if(zd+=Yd,Jd+=Yd.slice(Zd),!(Yd.length>=ld)){for(Yd=" ";Od<Td&&(Md=_d.charAt(Od),Md===Id);)Yd+=Md,Od++;if(zd+=Yd,Jd+=Yd,!(Yd.length<Nd)){for(Yd=" ";Od<Td&&(Md=_d.charAt(Od),!(Md!==td&&Md!==ed));)zd+=Md,Jd+=Md,Od++;if(!Md||Md===Ja)break}}}for(Rd+=Ud+zd,Od=-1,Td=Ld.length;++Od<Td;)if(Md=Ld.charAt(Od),Md===td||Md===ed)Pd||(Pd=Ld.slice(0,Od));else if(Pd){qd=Ld.slice(Od);break}return ud(Rd)({type:" code ",lang:Pd||Ld||null,meta:qd||null,value:Hd})}}}}}}),Re$4=C((Ra,qa)=>{Ra=qa.exports=Ja;function Ja(ed){return ed.trim?ed.trim():Ra.right(Ra.left(ed))}Ra.left=function(ed){return ed.trimLeft?ed.trimLeft():ed.replace(/^\s\s*/," " ) } , Ra . right = function ( ed ) { if ( ed . trimRight ) return ed . trimRight ( ) ; for ( var td = /\s/ , rd = ed . length ; td . test ( ed . charAt ( -- rd ) ) ; ) ; return ed . slice ( 0 , rd + 1 ) } } ) , Kr$3 = C ( ( Ra , qa ) => { qa . exports = Ja ; function Ja ( ed , td , rd , sd ) { for ( var od = ed . length , ld = - 1 , cd , ud ; ++ ld < od ; ) if ( cd = ed [ ld ] , ud = cd [ 1 ] || { } , ! ( ud . pedantic !== void 0 && ud . pedantic !== rd . options . pedantic ) && ! ( ud . commonmark !== void 0 && ud . commonmark !== rd . options . commonmark ) && td [ cd [ 0 ] ] . apply ( rd , sd ) ) return ! 0 ; return ! 1 } } ) , ba$2 = C ( ( Ra , qa ) => { var Ja = Re$4 ( ) , ed = Kr$3 ( ) ; qa . exports = ld ; var td = `
` ,rd=" ",sd=" ",od=">";function ld(cd,ud,_d){for(var yd=this,gd=yd.offset,Ed=yd.blockTokenizers,Td=yd.interruptBlockquote,Od=cd.now(),Rd=Od.line,Nd=ud.length,Id=[],Md=[],Ld=[],Pd,qd=0,Yd,Ud,Hd,zd,Jd,Zd,pf,Qd;qd<Nd&&(Yd=ud.charAt(qd),!(Yd!==sd&&Yd!==rd));)qd++;if(ud.charAt(qd)===od){if(_d)return!0;for(qd=0;qd<Nd;){for(Hd=ud.indexOf(td,qd),Zd=qd,pf=!1,Hd===-1&&(Hd=Nd);qd<Nd&&(Yd=ud.charAt(qd),!(Yd!==sd&&Yd!==rd));)qd++;if(ud.charAt(qd)===od?(qd++,pf=!0,ud.charAt(qd)===sd&&qd++):qd=Zd,zd=ud.slice(qd,Hd),!pf&&!Ja(zd)){qd=Zd;break}if(!pf&&(Ud=ud.slice(qd),ed(Td,Ed,yd,[cd,Ud,!0])))break;Jd=Zd===qd?zd:ud.slice(Zd,Hd),Ld.push(qd-Zd),Id.push(Jd),Md.push(zd),qd=Hd+1}for(qd=-1,Nd=Ld.length,Pd=cd(Id.join(td));++qd<Nd;)gd[Rd]=(gd[Rd]||0)+Ld[qd],Rd++;return Qd=yd.enterBlock(),Md=yd.tokenizeBlock(Md.join(td),Od),Qd(),Pd({type:"blockquote",children:Md})}}}),xa $ 2=C((Ra,qa)=>{qa.exports=od;var Ja= `
` ,ed=" ",td=" ",rd="#",sd=6;function od(ld,cd,ud){for(var _d=this,yd=_d.options.pedantic,gd=cd.length+1,Ed=-1,Td=ld.now(),Od="",Rd="",Nd,Id,Md;++Ed<gd;){if(Nd=cd.charAt(Ed),Nd!==td&&Nd!==ed){Ed--;break}Od+=Nd}for(Md=0;++Ed<=gd;){if(Nd=cd.charAt(Ed),Nd!==rd){Ed--;break}Od+=Nd,Md++}if(!(Md>sd)&&!(!Md||!yd&&cd.charAt(Ed+1)===rd)){for(gd=cd.length+1,Id="";++Ed<gd;){if(Nd=cd.charAt(Ed),Nd!==td&&Nd!==ed){Ed--;break}Id+=Nd}if(!(!yd&&Id.length===0&&Nd&&Nd!==Ja)){if(ud)return!0;for(Od+=Id,Id="",Rd="";++Ed<gd&&(Nd=cd.charAt(Ed),!(!Nd||Nd===Ja));){if(Nd!==td&&Nd!==ed&&Nd!==rd){Rd+=Id+Nd,Id="";continue}for(;Nd===td||Nd===ed;)Id+=Nd,Nd=cd.charAt(++Ed);if(!yd&&Rd&&!Id&&Nd===rd){Rd+=Nd;continue}for(;Nd===rd;)Id+=Nd,Nd=cd.charAt(++Ed);for(;Nd===td||Nd===ed;)Id+=Nd,Nd=cd.charAt(++Ed);Ed--}return Td.column+=Od.length,Td.offset+=Od.length,Od+=Rd+Id,ld(Od)({type:"heading",depth:Md,children:_d.tokenizeInline(Rd,Td)})}}}}),Ba $ 1=C((Ra,qa)=>{qa.exports=cd;var Ja=" ",ed= `
` ,td=" ",rd="*",sd="-",od="_",ld=3;function cd(ud,_d,yd){for(var gd=-1,Ed=_d.length+1,Td="",Od,Rd,Nd,Id;++gd<Ed&&(Od=_d.charAt(gd),!(Od!==Ja&&Od!==td));)Td+=Od;if(!(Od!==rd&&Od!==sd&&Od!==od))for(Rd=Od,Td+=Od,Nd=1,Id="";++gd<Ed;)if(Od=_d.charAt(gd),Od===Rd)Nd++,Td+=Id+Rd,Id="";else if(Od===td)Id+=Od;else return Nd>=ld&&(!Od||Od===ed)?(Td+=Id,yd?!0:ud(Td)({type:"thematicBreak"})):void 0}}), $ t $ 2=C((Ra,qa)=>{qa.exports=sd;var Ja=" ",ed=" ",td=1,rd=4;function sd(od){for(var ld=0,cd=0,ud=od.charAt(ld),_d={},yd,gd=0;ud===Ja||ud===ed;){for(yd=ud===Ja?rd:td,cd+=yd,yd>1&&(cd=Math.floor(cd/yd)*yd);gd<cd;)_d[++gd]=ld;ud=od.charAt(++ld)}return{indent:cd,stops:_d}}}),Oa $ 3=C((Ra,qa)=>{var Ja=Re $ 4(),ed=Hr $ 3(),td= $ t $ 2();qa.exports=ld;var rd= `
` ,sd=" ",od="!";function ld(cd,ud){var _d=cd.split(rd),yd=_d.length+1,gd=1/0,Ed=[],Td,Od,Rd;for(_d.unshift(ed(sd,ud)+od);yd--;)if(Od=td(_d[yd]),Ed[yd]=Od.stops,Ja(_d[yd]).length!==0)if(Od.indent)Od.indent>0&&Od.indent<gd&&(gd=Od.indent);else{gd=1/0;break}if(gd!==1/0)for(yd=_d.length;yd--;){for(Rd=Ed[yd],Td=gd;Td&&!(Td in Rd);)Td--;_d[yd]=_d[yd].slice(Rd[Td]+1)}return _d.shift(),_d.join(rd)}}),Ua $ 3=C((Ra,qa)=>{var Ja=Re $ 4(),ed=Hr $ 3(),td=Ne $ 1(),rd= $ t $ 2(),sd=Oa $ 3(),od=Kr $ 3();qa.exports=Yd;var ld="*",cd="_",ud="+",_d="-",yd=".",gd=" ",Ed= `
` ,Td=" ",Od=")",Rd="x",Nd=4,Id=/ \n \n (?! \s * $ )/,Md=/^ \[ ([ X \t x])][ \t ]/,Ld=/^([ \t ]*)([*+-]| \d +[.)])( {1,4}(?! )| | \t | $ |(?= \n ))([^ \n ]*)/,Pd=/^([ \t ]*)([*+-]| \d +[.)])([ \t ]+)/,qd=/^( {1,4}| \t )?/gm;function Yd(Jd,Zd,pf){for(var Qd=this,hf=Qd.options.commonmark,mf=Qd.options.pedantic,xf=Qd.blockTokenizers,Lf=Qd.interruptList,Kf=0,Yf=Zd.length,Of=null,Tf,wf,Wf,Uf,gf,_f, $ f,Gf,dh,zf,If,Jf,Th,Vf,Ef,Af,Pf,hh,Ah,uh=!1,Fh,Nh,Bh,Jh;Kf<Yf&&(Uf=Zd.charAt(Kf),!(Uf!==Td&&Uf!==gd));)Kf++;if(Uf=Zd.charAt(Kf),Uf===ld||Uf===ud||Uf===_d)gf=Uf,Wf=!1;else{for(Wf=!0,wf="";Kf<Yf&&(Uf=Zd.charAt(Kf),!!td(Uf));)wf+=Uf,Kf++;if(Uf=Zd.charAt(Kf),!wf||!(Uf===yd||hf&&Uf===Od)||pf&&wf!=="1")return;Of=parseInt(wf,10),gf=Uf}if(Uf=Zd.charAt(++Kf),!(Uf!==gd&&Uf!==Td&&(mf||Uf!==Ed&&Uf!==""))){if(pf)return!0;for(Kf=0,Vf=[],Ef=[],Af=[];Kf<Yf;){for(_f=Zd.indexOf(Ed,Kf), $ f=Kf,Gf=!1,Jh=!1,_f===-1&&(_f=Yf),Tf=0;Kf<Yf;){if(Uf=Zd.charAt(Kf),Uf===Td)Tf+=Nd-Tf%Nd;else if(Uf===gd)Tf++;else break;Kf++}if(Pf&&Tf>=Pf.indent&&(Jh=!0),Uf=Zd.charAt(Kf),dh=null,!Jh){if(Uf===ld||Uf===ud||Uf===_d)dh=Uf,Kf++,Tf++;else{for(wf="";Kf<Yf&&(Uf=Zd.charAt(Kf),!!td(Uf));)wf+=Uf,Kf++;Uf=Zd.charAt(Kf),Kf++,wf&&(Uf===yd||hf&&Uf===Od)&&(dh=Uf,Tf+=wf.length+1)}if(dh)if(Uf=Zd.charAt(Kf),Uf===Td)Tf+=Nd-Tf%Nd,Kf++;else if(Uf===gd){for(Bh=Kf+Nd;Kf<Bh&&Zd.charAt(Kf)===gd;)Kf++,Tf++;Kf===Bh&&Zd.charAt(Kf)===gd&&(Kf-=Nd-1,Tf-=Nd-1)}else Uf!==Ed&&Uf!==""&&(dh=null)}if(dh){if(!mf&&gf!==dh)break;Gf=!0}else!hf&&!Jh&&Zd.charAt( $ f)===gd?Jh=!0:hf&&Pf&&(Jh=Tf>=Pf.indent||Tf>Nd),Gf=!1,Kf= $ f;if(If=Zd.slice( $ f,_f),zf= $ f===Kf?If:Zd.slice(Kf,_f),(dh===ld||dh===cd||dh===_d)&&xf.thematicBreak.call(Qd,Jd,If,!0))break;if(Jf=Th,Th=!Gf&&!Ja(zf).length,Jh&&Pf)Pf.value=Pf.value.concat(Af,If),Ef=Ef.concat(Af,If),Af=[];else if(Gf)Af.length!==0&&(uh=!0,Pf.value.push(""),Pf.trail=Af.concat()),Pf={value:[If],indent:Tf,trail:[]},Vf.push(Pf),Ef=Ef.concat(Af,If),Af=[];else if(Th){if(Jf&&!hf)break;Af.push(If)}else{if(Jf||od(Lf,xf,Qd,[Jd,If,!0]))break;Pf.value=Pf.value.concat(Af,If),Ef=Ef.concat(Af,If),Af=[]}Kf=_f+1}for(Fh=Jd(Ef.join(Ed)).reset({type:"list",ordered:Wf,start:Of,spread:uh,children:[]}),hh=Qd.enterList(),Ah=Qd.enterBlock(),Kf=-1,Yf=Vf.length;++Kf<Yf;)Pf=Vf[Kf].value.join(Ed),Nh=Jd.now(),Jd(Pf)(Ud(Qd,Pf,Nh),Fh),Pf=Vf[Kf].trail.join(Ed),Kf!==Yf-1&&(Pf+=Ed),Jd(Pf);return hh(),Ah(),Fh}}function Ud(Jd,Zd,pf){var Qd=Jd.offset,hf=Jd.options.pedantic?Hd:zd,mf=null,xf,Lf;return Zd=hf.apply(null,arguments),Jd.options.gfm&&(xf=Zd.match(Md),xf&&(Lf=xf[0].length,mf=xf[1].toLowerCase()===Rd,Qd[pf.line]+=Lf,Zd=Zd.slice(Lf))),{type:"listItem",spread:Id.test(Zd),checked:mf,children:Jd.tokenizeBlock(Zd,pf)}}function Hd(Jd,Zd,pf){var Qd=Jd.offset,hf=pf.line;return Zd=Zd.replace(Pd,mf),hf=pf.line,Zd.replace(qd,mf);function mf(xf){return Qd[hf]=(Qd[hf]||0)+xf.length,hf++,""}}function zd(Jd,Zd,pf){var Qd=Jd.offset,hf=pf.line,mf,xf,Lf,Kf,Yf,Of,Tf;for(Zd=Zd.replace(Ld,wf),Kf=Zd.split(Ed),Yf=sd(Zd,rd(mf).indent).split(Ed),Yf[0]=Lf,Qd[hf]=(Qd[hf]||0)+xf.length,hf++,Of=0,Tf=Kf.length;++Of<Tf;)Qd[hf]=(Qd[hf]||0)+Kf[Of].length-Yf[Of].length,hf++;return Yf.join(Ed);function wf(Wf,Uf,gf,_f, $ f){return xf=Uf+gf+_f,Lf= $ f,Number(gf)<10&&xf.length%2===1&&(gf=gd+gf),mf=Uf+ed(gd,gf.length)+_f,mf+Lf}}}),Ga $ 2=C((Ra,qa)=>{qa.exports=ud;var Ja= `
` ,ed=" ",td=" ",rd="=",sd="-",od=3,ld=1,cd=2;function ud(_d,yd,gd){for(var Ed=this,Td=_d.now(),Od=yd.length,Rd=-1,Nd="",Id,Md,Ld,Pd,qd;++Rd<Od;){if(Ld=yd.charAt(Rd),Ld!==td||Rd>=od){Rd--;break}Nd+=Ld}for(Id="",Md="";++Rd<Od;){if(Ld=yd.charAt(Rd),Ld===Ja){Rd--;break}Ld===td||Ld===ed?Md+=Ld:(Id+=Md+Ld,Md="")}if(Td.column+=Nd.length,Td.offset+=Nd.length,Nd+=Id+Md,Ld=yd.charAt(++Rd),Pd=yd.charAt(++Rd),!(Ld!==Ja||Pd!==rd&&Pd!==sd)){for(Nd+=Ld,Md=Pd,qd=Pd===rd?ld:cd;++Rd<Od;){if(Ld=yd.charAt(Rd),Ld!==Pd){if(Ld!==Ja)return;Rd--;break}Md+=Ld}return gd?!0:_d(Nd+Md)({type:"heading",depth:qd,children:Ed.tokenizeInline(Id,Td)})}}}),Xt $ 3=C(Ra=>{var qa="[a-zA-Z_:][a-zA-Z0-9:._-]*",Ja="[^ \" '=<> ` \ \u0000 - \ \u0020 ] + ",ed=" '[^' ] * '",td=' "[^" ] * "',rd=" ( ? : "+Ja+" | "+ed+" | "+td+" ) ",sd=" ( ? : \ \ s + "+qa+" ( ? : \ \ s *= \ \ s * "+rd+" ) ? ) ",od=" < [ A - Za - z ] [ A - Za - z0 - 9 \ \ - ] * "+sd+" * \ \ s * \ \ / ? > ",ld=" < \ \ / [ A - Za - z ] [ A - Za - z0 - 9 \ \ - ] * \ \ s * > ",cd=" <!-- -- > | <!-- ( ? : - ? [ ^ > - ] ) ( ? : - ? [ ^ - ] ) * -- > ",ud=" < [ ? ] . * ? [ ? ] > ",_d=" < ! [ A - Za - z ] + \ \ s + [ ^ > ] * > ",yd=" < ! \ \ [ CDATA \ \ [ [ \ \ s \ \ S ] * ? \ \ ] \ \ ] > ";Ra.openCloseTag=new RegExp(" ^ ( ? : "+od+" | "+ld+" ) "),Ra.tag=new RegExp(" ^ ( ? : "+od+" | "+ld+" | "+cd+" | "+ud+" | "+_d+" | "+yd+" ) ")}),Ka$1=C((Ra,qa)=>{var Ja=Xt$3().openCloseTag;qa.exports=Id;var ed=" ",td=" " , rd = `
` ,sd="<",od=/^<(script|pre|style)(?=( \s |>| $ ))/i,ld=/< \/ (script|pre|style)>/i,cd=/^<!--/,ud=/-->/,_d=/^< \? /,yd=/ \? >/,gd=/^<![A-Za-z]/,Ed=/>/,Td=/^<! \[ CDATA \[ /,Od=/]]>/,Rd=/^ $ /,Nd=new RegExp(Ja.source+" \\ s* $ ");function Id(Md,Ld,Pd){for(var qd=this,Yd=qd.options.blocks.join("|"),Ud=new RegExp("^</?("+Yd+")(?=( \\ s|/?>| $ ))","i"),Hd=Ld.length,zd=0,Jd,Zd,pf,Qd,hf,mf,xf,Lf=[[od,ld,!0],[cd,ud,!0],[_d,yd,!0],[gd,Ed,!0],[Td,Od,!0],[Ud,Rd,!0],[Nd,Rd,!1]];zd<Hd&&(Qd=Ld.charAt(zd),!(Qd!==ed&&Qd!==td));)zd++;if(Ld.charAt(zd)===sd){for(Jd=Ld.indexOf(rd,zd+1),Jd=Jd===-1?Hd:Jd,Zd=Ld.slice(zd,Jd),pf=-1,hf=Lf.length;++pf<hf;)if(Lf[pf][0].test(Zd)){mf=Lf[pf];break}if(mf){if(Pd)return mf[2];if(zd=Jd,!mf[1].test(Zd))for(;zd<Hd;){if(Jd=Ld.indexOf(rd,zd+1),Jd=Jd===-1?Hd:Jd,Zd=Ld.slice(zd+1,Jd),mf[1].test(Zd)){Zd&&(zd=Jd);break}zd=Jd}return xf=Ld.slice(0,zd),Md(xf)({type:"html",value:xf})}}}}),ue $ 1=C((Ra,qa)=>{qa.exports=td;var Ja=String.fromCharCode,ed=/ \s /;function td(rd){return ed.test(typeof rd=="number"?Ja(rd):rd.charAt(0))}}),Qt $ 1=C((Ra,qa)=>{var Ja=xr $ 2();qa.exports=ed;function ed(td){return Ja(td).toLowerCase()}}),io $ 1=C((Ra,qa)=>{var Ja=ue $ 1(),ed=Qt $ 1();qa.exports=Rd;var td='"',rd="'",sd=" \\ ",od= `
` ,ld=" ",cd=" ",ud="[",_d="]",yd="(",gd=")",Ed=":",Td="<",Od=">";function Rd(Md,Ld,Pd){for(var qd=this,Yd=qd.options.commonmark,Ud=0,Hd=Ld.length,zd="",Jd,Zd,pf,Qd,hf,mf,xf,Lf;Ud<Hd&&(Qd=Ld.charAt(Ud),!(Qd!==cd&&Qd!==ld));)zd+=Qd,Ud++;if(Qd=Ld.charAt(Ud),Qd===ud){for(Ud++,zd+=Qd,pf="";Ud<Hd&&(Qd=Ld.charAt(Ud),Qd!==_d);)Qd===sd&&(pf+=Qd,Ud++,Qd=Ld.charAt(Ud)),pf+=Qd,Ud++;if(!(!pf||Ld.charAt(Ud)!==_d||Ld.charAt(Ud+1)!==Ed)){for(mf=pf,zd+=pf+_d+Ed,Ud=zd.length,pf="";Ud<Hd&&(Qd=Ld.charAt(Ud),!(Qd!==ld&&Qd!==cd&&Qd!==od));)zd+=Qd,Ud++;if(Qd=Ld.charAt(Ud),pf="",Jd=zd,Qd===Td){for(Ud++;Ud<Hd&&(Qd=Ld.charAt(Ud),!!Nd(Qd));)pf+=Qd,Ud++;if(Qd=Ld.charAt(Ud),Qd===Nd.delimiter)zd+=Td+pf+Qd,Ud++;else{if(Yd)return;Ud-=pf.length+1,pf=""}}if(!pf){for(;Ud<Hd&&(Qd=Ld.charAt(Ud),!!Id(Qd));)pf+=Qd,Ud++;zd+=pf}if(pf){for(xf=pf,pf="";Ud<Hd&&(Qd=Ld.charAt(Ud),!(Qd!==ld&&Qd!==cd&&Qd!==od));)pf+=Qd,Ud++;if(Qd=Ld.charAt(Ud),hf=null,Qd===td?hf=td:Qd===rd?hf=rd:Qd===yd&&(hf=gd),!hf)pf="",Ud=zd.length;else if(pf){for(zd+=pf+Qd,Ud=zd.length,pf="";Ud<Hd&&(Qd=Ld.charAt(Ud),Qd!==hf);){if(Qd===od){if(Ud++,Qd=Ld.charAt(Ud),Qd===od||Qd===hf)return;pf+=od}pf+=Qd,Ud++}if(Qd=Ld.charAt(Ud),Qd!==hf)return;Zd=zd,zd+=pf+Qd,Ud++,Lf=pf,pf=""}else return;for(;Ud<Hd&&(Qd=Ld.charAt(Ud),!(Qd!==ld&&Qd!==cd));)zd+=Qd,Ud++;if(Qd=Ld.charAt(Ud),!Qd||Qd===od)return Pd?!0:(Jd=Md(Jd).test().end,xf=qd.decode.raw(qd.unescape(xf),Jd,{nonTerminated:!1}),Lf&&(Zd=Md(Zd).test().end,Lf=qd.decode.raw(qd.unescape(Lf),Zd)),Md(zd)({type:"definition",identifier:ed(mf),label:mf,title:Lf||null,url:xf}))}}}}function Nd(Md){return Md!==Od&&Md!==ud&&Md!==_d}Nd.delimiter=Od;function Id(Md){return Md!==ud&&Md!==_d&&!Ja(Md)}}),oo $ 3=C((Ra,qa)=>{var Ja=ue $ 1();qa.exports=Td;var ed=" ",td= `
` ,rd=" ",sd="-",od=":",ld=" \\ ",cd="|",ud=1,_d=2,yd="left",gd="center",Ed="right";function Td(Od,Rd,Nd){var Id=this,Md,Ld,Pd,qd,Yd,Ud,Hd,zd,Jd,Zd,pf,Qd,hf,mf,xf,Lf,Kf,Yf,Of,Tf,wf,Wf;if(Id.options.gfm){for(Md=0,Lf=0,Ud=Rd.length+1,Hd=[];Md<Ud;){if(Tf=Rd.indexOf(td,Md),wf=Rd.indexOf(cd,Md+1),Tf===-1&&(Tf=Rd.length),wf===-1||wf>Tf){if(Lf<_d)return;break}Hd.push(Rd.slice(Md,Tf)),Lf++,Md=Tf+1}for(qd=Hd.join(td),Ld=Hd.splice(1,1)[0]||[],Md=0,Ud=Ld.length,Lf--,Pd=!1,pf=[];Md<Ud;){if(Jd=Ld.charAt(Md),Jd===cd){if(Zd=null,Pd===!1){if(Wf===!1)return}else pf.push(Pd),Pd=!1;Wf=!1}else if(Jd===sd)Zd=!0,Pd=Pd||null;else if(Jd===od)Pd===yd?Pd=gd:Zd&&Pd===null?Pd=Ed:Pd=yd;else if(!Ja(Jd))return;Md++}if(Pd!==!1&&pf.push(Pd),!(pf.length<ud)){if(Nd)return!0;for(xf=-1,Yf=[],Of=Od(qd).reset({type:"table",align:pf,children:Yf});++xf<Lf;){for(Kf=Hd[xf],Yd={type:"tableRow",children:[]},xf&&Od(td),Od(Kf).reset(Yd,Of),Ud=Kf.length+1,Md=0,zd="",Qd="",hf=!0;Md<Ud;){if(Jd=Kf.charAt(Md),Jd===ed||Jd===rd){Qd?zd+=Jd:Od(Jd),Md++;continue}Jd===""||Jd===cd?hf?Od(Jd):((Qd||Jd)&&!hf&&(qd=Qd,zd.length>1&&(Jd?(qd+=zd.slice(0,-1),zd=zd.charAt(zd.length-1)):(qd+=zd,zd="")),mf=Od.now(),Od(qd)({type:"tableCell",children:Id.tokenizeInline(Qd,mf)},Yd)),Od(zd+Jd),zd="",Qd=""):(zd&&(Qd+=zd,zd=""),Qd+=Jd,Jd===ld&&Md!==Ud-2&&(Qd+=Kf.charAt(Md+1),Md++)),hf=!1,Md++}xf||Od(td+Ld)}return Of}}}}),lo $ 2=C((Ra,qa)=>{var Ja=Re $ 4(),ed=Mt $ 2(),td=Kr $ 3();qa.exports=cd;var rd=" ",sd= `
` ,od=" ",ld=4;function cd(ud,_d,yd){for(var gd=this,Ed=gd.options,Td=Ed.commonmark,Od=gd.blockTokenizers,Rd=gd.interruptParagraph,Nd=_d.indexOf(sd),Id=_d.length,Md,Ld,Pd,qd,Yd;Nd<Id;){if(Nd===-1){Nd=Id;break}if(_d.charAt(Nd+1)===sd)break;if(Td){for(qd=0,Md=Nd+1;Md<Id;){if(Pd=_d.charAt(Md),Pd===rd){qd=ld;break}else if(Pd===od)qd++;else break;Md++}if(qd>=ld&&Pd!==sd){Nd=_d.indexOf(sd,Nd+1);continue}}if(Ld=_d.slice(Nd+1),td(Rd,Od,gd,[ud,Ld,!0]))break;if(Md=Nd,Nd=_d.indexOf(sd,Nd+1),Nd!==-1&&Ja(_d.slice(Md,Nd))===""){Nd=Md;break}}return Ld=_d.slice(0,Nd),yd?!0:(Yd=ud.now(),Ld=ed(Ld),ud(Ld)({type:"paragraph",children:gd.tokenizeInline(Ld,Yd)}))}}),Do $ 1=C((Ra,qa)=>{qa.exports=Ja;function Ja(ed,td){return ed.indexOf(" \\ ",td)}}),Fo $ 1=C((Ra,qa)=>{var Ja=Do $ 1();qa.exports=rd,rd.locator=Ja;var ed= `
` ,td=" \\ ";function rd(sd,od,ld){var cd=this,ud,_d;if(od.charAt(0)===td&&(ud=od.charAt(1),cd.escape.indexOf(ud)!==-1))return ld?!0:(ud===ed?_d={type:"break"}:_d={type:"text",value:ud},sd(td+ud)(_d))}}),tn $ 2=C((Ra,qa)=>{qa.exports=Ja;function Ja(ed,td){return ed.indexOf("<",td)}}),yo $ 2=C((Ra,qa)=>{var Ja=ue $ 1(),ed=pr $ 1(),td=tn $ 2();qa.exports=_d,_d.locator=td,_d.notInLink=!0;var rd="<",sd=">",od="@",ld="/",cd="mailto:",ud=cd.length;function _d(yd,gd,Ed){var Td=this,Od="",Rd=gd.length,Nd=0,Id="",Md=!1,Ld="",Pd,qd,Yd,Ud,Hd;if(gd.charAt(0)===rd){for(Nd++,Od=rd;Nd<Rd&&(Pd=gd.charAt(Nd),!(Ja(Pd)||Pd===sd||Pd===od||Pd===":"&&gd.charAt(Nd+1)===ld));)Id+=Pd,Nd++;if(Id){if(Ld+=Id,Id="",Pd=gd.charAt(Nd),Ld+=Pd,Nd++,Pd===od)Md=!0;else{if(Pd!==":"||gd.charAt(Nd+1)!==ld)return;Ld+=ld,Nd++}for(;Nd<Rd&&(Pd=gd.charAt(Nd),!(Ja(Pd)||Pd===sd));)Id+=Pd,Nd++;if(Pd=gd.charAt(Nd),!(!Id||Pd!==sd))return Ed?!0:(Ld+=Id,Yd=Ld,Od+=Ld+Pd,qd=yd.now(),qd.column++,qd.offset++,Md&&(Ld.slice(0,ud).toLowerCase()===cd?(Yd=Yd.slice(ud),qd.column+=ud,qd.offset+=ud):Ld=cd+Ld),Ud=Td.inlineTokenizers,Td.inlineTokenizers={text:Ud.text},Hd=Td.enterLink(),Yd=Td.tokenizeInline(Yd,qd),Td.inlineTokenizers=Ud,Hd(),yd(Od)({type:"link",title:null,url:ed(Ld,{nonTerminated:!1}),children:Yd}))}}}}),xo $ 2=C((Ra,qa)=>{qa.exports=Ja;function Ja(ed,td){var rd=String(ed),sd=0,od;if(typeof td!="string")throw new Error("Expected character");for(od=rd.indexOf(td);od!==-1;)sd++,od=rd.indexOf(td,od+td.length);return sd}}),Bo $ 1=C((Ra,qa)=>{qa.exports=ed;var Ja=["www.","http://","https://"];function ed(td,rd){var sd=-1,od,ld,cd;if(!this.options.gfm)return sd;for(ld=Ja.length,od=-1;++od<ld;)cd=td.indexOf(Ja[od],rd),cd!==-1&&(sd===-1||cd<sd)&&(sd=cd);return sd}}),Oo $ 1=C((Ra,qa)=>{var Ja=xo $ 2(),ed=pr $ 1(),td=Ne $ 1(),rd=Ve $ 2(),sd=ue $ 1(),od=Bo $ 1();qa.exports=qd,qd.locator=od,qd.notInLink=!0;var ld=33,cd=38,ud=41,_d=42,yd=44,gd=45,Ed=46,Td=58,Od=59,Rd=63,Nd=60,Id=95,Md=126,Ld="(",Pd=")";function qd(Yd,Ud,Hd){var zd=this,Jd=zd.options.gfm,Zd=zd.inlineTokenizers,pf=Ud.length,Qd=-1,hf=!1,mf,xf,Lf,Kf,Yf,Of,Tf,wf,Wf,Uf,gf,_f, $ f,Gf;if(Jd){if(Ud.slice(0,4)==="www.")hf=!0,Kf=4;else if(Ud.slice(0,7).toLowerCase()==="http://")Kf=7;else if(Ud.slice(0,8).toLowerCase()==="https://")Kf=8;else return;for(Qd=Kf-1,Lf=Kf,mf=[];Kf<pf;){if(Tf=Ud.charCodeAt(Kf),Tf===Ed){if(Qd===Kf-1)break;mf.push(Kf),Qd=Kf,Kf++;continue}if(td(Tf)||rd(Tf)||Tf===gd||Tf===Id){Kf++;continue}break}if(Tf===Ed&&(mf.pop(),Kf--),mf[0]!==void 0&&(xf=mf.length<2?Lf:mf[mf.length-2]+1,Ud.slice(xf,Kf).indexOf("_")===-1)){if(Hd)return!0;for(wf=Kf,Yf=Kf;Kf<pf&&(Tf=Ud.charCodeAt(Kf),!(sd(Tf)||Tf===Nd));)Kf++,Tf===ld||Tf===_d||Tf===yd||Tf===Ed||Tf===Td||Tf===Rd||Tf===Id||Tf===Md||(wf=Kf);if(Kf=wf,Ud.charCodeAt(Kf-1)===ud)for(Of=Ud.slice(Yf,Kf),Wf=Ja(Of,Ld),Uf=Ja(Of,Pd);Uf>Wf;)Kf=Yf+Of.lastIndexOf(Pd),Of=Ud.slice(Yf,Kf),Uf--;if(Ud.charCodeAt(Kf-1)===Od&&(Kf--,rd(Ud.charCodeAt(Kf-1)))){for(wf=Kf-2;rd(Ud.charCodeAt(wf));)wf--;Ud.charCodeAt(wf)===cd&&(Kf=wf)}return gf=Ud.slice(0,Kf), $ f=ed(gf,{nonTerminated:!1}),hf&&( $ f="http://"+ $ f),Gf=zd.enterLink(),zd.inlineTokenizers={text:Zd.text},_f=zd.tokenizeInline(gf,Yd.now()),zd.inlineTokenizers=Zd,Gf(),Yd(gf)({type:"link",title:null,url: $ f,children:_f})}}}}),No $ 1=C((Ra,qa)=>{var Ja=Ne $ 1(),ed=Ve $ 2(),td=43,rd=45,sd=46,od=95;qa.exports=ld;function ld(ud,_d){var yd=this,gd,Ed;if(!this.options.gfm||(gd=ud.indexOf("@",_d),gd===-1))return-1;if(Ed=gd,Ed===_d||!cd(ud.charCodeAt(Ed-1)))return ld.call(yd,ud,gd+1);for(;Ed>_d&&cd(ud.charCodeAt(Ed-1));)Ed--;return Ed}function cd(ud){return Ja(ud)||ed(ud)||ud===td||ud===rd||ud===sd||ud===od}}),Mo $ 2=C((Ra,qa)=>{var Ja=pr $ 1(),ed=Ne $ 1(),td=Ve $ 2(),rd=No $ 1();qa.exports=_d,_d.locator=rd,_d.notInLink=!0;var sd=43,od=45,ld=46,cd=64,ud=95;function _d(yd,gd,Ed){var Td=this,Od=Td.options.gfm,Rd=Td.inlineTokenizers,Nd=0,Id=gd.length,Md=-1,Ld,Pd,qd,Yd;if(Od){for(Ld=gd.charCodeAt(Nd);ed(Ld)||td(Ld)||Ld===sd||Ld===od||Ld===ld||Ld===ud;)Ld=gd.charCodeAt(++Nd);if(Nd!==0&&Ld===cd){for(Nd++;Nd<Id;){if(Ld=gd.charCodeAt(Nd),ed(Ld)||td(Ld)||Ld===od||Ld===ld||Ld===ud){Nd++,Md===-1&&Ld===ld&&(Md=Nd)
` ,rd="!",sd='"',od="'",ld="(",cd=")",ud="<",_d=">",yd="[",gd=" \\ ",Ed="]",Td=" ` ";function Od(Rd,Nd,Id){var Md=this,Ld=" ",Pd=0,qd=Nd.charAt(0),Yd=Md.options.pedantic,Ud=Md.options.commonmark,Hd=Md.options.gfm,zd,Jd,Zd,pf,Qd,hf,mf,xf,Lf,Kf,Yf,Of,Tf,wf,Wf,Uf,gf,_f;if(qd===rd&&(xf=!0,Ld=qd,qd=Nd.charAt(++Pd)),qd===yd&&!(!xf&&Md.inLink)){for(Ld+=qd,wf=" ",Pd++,Yf=Nd.length,Uf=Rd.now(),Tf=0,Uf.column+=Pd,Uf.offset+=Pd;Pd<Yf;){if(qd=Nd.charAt(Pd),hf=qd,qd===Td){for(Jd=1;Nd.charAt(Pd+1)===Td;)hf+=qd,Pd++,Jd++;Zd?Jd>=Zd&&(Zd=0):Zd=Jd}else if(qd===gd)Pd++,hf+=Nd.charAt(Pd);else if((!Zd||Hd)&&qd===yd)Tf++;else if((!Zd||Hd)&&qd===Ed)if(Tf)Tf--;else{if(Nd.charAt(Pd+1)!==ld)return;hf+=ld,zd=!0,Pd++;break}wf+=hf,hf=" ",Pd++}if(zd){for(Lf=wf,Ld+=wf+hf,Pd++;Pd<Yf&&(qd=Nd.charAt(Pd),!!Ja(qd));)Ld+=qd,Pd++;if(qd=Nd.charAt(Pd),wf=" ",pf=Ld,qd===ud){for(Pd++,pf+=ud;Pd<Yf&&(qd=Nd.charAt(Pd),qd!==_d);){if(Ud&&qd===td)return;wf+=qd,Pd++}if(Nd.charAt(Pd)!==_d)return;Ld+=ud+wf+_d,Wf=wf,Pd++}else{for(qd=null,hf=" ";Pd<Yf&&(qd=Nd.charAt(Pd),!(hf&&(qd===sd||qd===od||Ud&&qd===ld)));){if(Ja(qd)){if(!Yd)break;hf+=qd}else{if(qd===ld)Tf++;else if(qd===cd){if(Tf===0)break;Tf--}wf+=hf,hf=" ",qd===gd&&(wf+=gd,qd=Nd.charAt(++Pd)),wf+=qd}Pd++}Ld+=wf,Wf=wf,Pd=Ld.length}for(wf=" ";Pd<Yf&&(qd=Nd.charAt(Pd),!!Ja(qd));)wf+=qd,Pd++;if(qd=Nd.charAt(Pd),Ld+=wf,wf&&(qd===sd||qd===od||Ud&&qd===ld))if(Pd++,Ld+=qd,wf=" ",Kf=qd===ld?cd:qd,Qd=Ld,Ud){for(;Pd<Yf&&(qd=Nd.charAt(Pd),qd!==Kf);)qd===gd&&(wf+=gd,qd=Nd.charAt(++Pd)),Pd++,wf+=qd;if(qd=Nd.charAt(Pd),qd!==Kf)return;for(Of=wf,Ld+=wf+qd,Pd++;Pd<Yf&&(qd=Nd.charAt(Pd),!!Ja(qd));)Ld+=qd,Pd++}else for(hf=" ";Pd<Yf;){if(qd=Nd.charAt(Pd),qd===Kf)mf&&(wf+=Kf+hf,hf=" "),mf=!0;else if(!mf)wf+=qd;else if(qd===cd){Ld+=wf+Kf+hf,Of=wf;break}else Ja(qd)?hf+=qd:(wf+=Kf+hf+qd,hf=" ",mf=!1);Pd++}if(Nd.charAt(Pd)===cd)return Id?!0:(Ld+=cd,Wf=Md.decode.raw(Md.unescape(Wf),Rd(pf).test().end,{nonTerminated:!1}),Of&&(Qd=Rd(Qd).test().end,Of=Md.decode.raw(Md.unescape(Of),Qd)),_f={type:xf?" image ":" link ",title:Of||null,url:Wf},xf?_f.alt=Md.decode.raw(Md.unescape(Lf),Uf)||null:(gf=Md.enterLink(),_f.children=Md.tokenizeInline(Lf,Uf),gf()),Rd(Ld)(_f))}}}}),rs$1=C((Ra,qa)=>{var Ja=ue$1(),ed=dn$2(),td=Qt$1();qa.exports=Ed,Ed.locator=ed;var rd=" link ",sd=" image ",od=" shortcut ",ld=" collapsed ",cd=" full ",ud=" ! ",_d=" [ ",yd=" \ \ ",gd=" ] ";function Ed(Td,Od,Rd){var Nd=this,Id=Nd.options.commonmark,Md=Od.charAt(0),Ld=0,Pd=Od.length,qd=" ",Yd=" ",Ud=rd,Hd=od,zd,Jd,Zd,pf,Qd,hf,mf,xf;if(Md===ud&&(Ud=sd,Yd=Md,Md=Od.charAt(++Ld)),Md===_d){for(Ld++,Yd+=Md,hf=" ",xf=0;Ld<Pd;){if(Md=Od.charAt(Ld),Md===_d)mf=!0,xf++;else if(Md===gd){if(!xf)break;xf--}Md===yd&&(hf+=yd,Md=Od.charAt(++Ld)),hf+=Md,Ld++}if(qd=hf,zd=hf,Md=Od.charAt(Ld),Md===gd){if(Ld++,qd+=Md,hf=" ",!Id)for(;Ld<Pd&&(Md=Od.charAt(Ld),!!Ja(Md));)hf+=Md,Ld++;if(Md=Od.charAt(Ld),Md===_d){for(Jd=" ",hf+=Md,Ld++;Ld<Pd&&(Md=Od.charAt(Ld),!(Md===_d||Md===gd));)Md===yd&&(Jd+=yd,Md=Od.charAt(++Ld)),Jd+=Md,Ld++;Md=Od.charAt(Ld),Md===gd?(Hd=Jd?cd:ld,hf+=Jd+Md,Ld++):Jd=" ",qd+=hf,hf=" "}else{if(!zd)return;Jd=zd}if(!(Hd!==cd&&mf))return qd=Yd+qd,Ud===rd&&Nd.inLink?null:Rd?!0:(Zd=Td.now(),Zd.column+=Yd.length,Zd.offset+=Yd.length,Jd=Hd===cd?Jd:zd,pf={type:Ud+" Reference ",identifier:td(Jd),label:Jd,referenceType:Hd},Ud===rd?(Qd=Nd.enterLink(),pf.children=Nd.tokenizeInline(zd,Zd),Qd()):pf.alt=Nd.decode.raw(Nd.unescape(zd),Zd)||null,Td(qd)(pf))}}}}),ns$1=C((Ra,qa)=>{qa.exports=Ja;function Ja(ed,td){var rd=ed.indexOf(" * * ",td),sd=ed.indexOf(" _ _ ",td);return sd===-1?rd:rd===-1||sd<rd?sd:rd}}),os$1=C((Ra,qa)=>{var Ja=Re$4(),ed=ue$1(),td=ns$1();qa.exports=ld,ld.locator=td;var rd=" \ \ ",sd=" * ",od=" _ ";function ld(cd,ud,_d){var yd=this,gd=0,Ed=ud.charAt(gd),Td,Od,Rd,Nd,Id,Md,Ld;if(!(Ed!==sd&&Ed!==od||ud.charAt(++gd)!==Ed)&&(Od=yd.options.pedantic,Rd=Ed,Id=Rd+Rd,Md=ud.length,gd++,Nd=" ",Ed=" ",!(Od&&ed(ud.charAt(gd)))))for(;gd<Md;){if(Ld=Ed,Ed=ud.charAt(gd),Ed===Rd&&ud.charAt(gd+1)===Rd&&(!Od||!ed(Ld))&&(Ed=ud.charAt(gd+2),Ed!==Rd))return Ja(Nd)?_d?!0:(Td=cd.now(),Td.column+=2,Td.offset+=2,cd(Id+Nd+Id)({type:" strong " , children : yd . tokenizeInline ( Nd , Td ) } ) ) : void
2024-09-03 08:22:14 +08:00
` ,td);rd>td&&ed.charAt(rd-1)===" ";)rd--;return rd}}),Os $ 3=C((Ra,qa)=>{var Ja=Ts $ 2();qa.exports=sd,sd.locator=Ja;var ed=" ",td= `
2024-09-08 17:22:36 +08:00
` ,rd=2;function sd(od,ld,cd){for(var ud=ld.length,_d=-1,yd="",gd;++_d<ud;){if(gd=ld.charAt(_d),gd===td)return _d<rd?void 0:cd?!0:(yd+=gd,od(yd)({type:"break"}));if(gd!==ed)return;yd+=gd}}}),Ls $ 3=C((Ra,qa)=>{qa.exports=Ja;function Ja(ed,td,rd){var sd=this,od,ld,cd,ud,_d,yd,gd,Ed,Td,Od;if(rd)return!0;for(od=sd.inlineMethods,ud=od.length,ld=sd.inlineTokenizers,cd=-1,Td=td.length;++cd<ud;)Ed=od[cd],!(Ed==="text"||!ld[Ed])&&(gd=ld[Ed].locator,gd||ed.file.fail("Missing locator: ` "+Ed+" ` "),yd=gd.call(sd,td,1),yd!==-1&&yd<Td&&(Td=yd));_d=td.slice(0,Td),Od=ed.now(),sd.decode(_d,Od,Rd);function Rd(Nd,Id,Md){ed(Md||Nd)({type:"text",value:Nd})}}}),Us $ 2=C((Ra,qa)=>{var Ja=Ie $ 1(),ed=ru $ 2(),td=nu $ 3(),rd=uu $ 3(),sd=Ou $ 1(),od=Iu $ 1();qa.exports=ld;function ld(_d,yd){this.file=yd,this.offset={},this.options=Ja(this.options),this.setOptions({}),this.inList=!1,this.inBlock=!1,this.inLink=!1,this.atStart=!0,this.toOffset=td(yd).toOffset,this.unescape=rd(this,"escape"),this.decode=sd(this)}var cd=ld.prototype;cd.setOptions=Vu $ 2(),cd.parse=aa $ 3(),cd.options=Rt $ 3(),cd.exitStart=ed("atStart",!0),cd.enterList=ed("inList",!1),cd.enterLink=ed("inLink",!1),cd.enterBlock=ed("inBlock",!1),cd.interruptParagraph=[["thematicBreak"],["list"],["atxHeading"],["fencedCode"],["blockquote"],["html"],["setextHeading",{commonmark:!1}],["definition",{commonmark:!1}]],cd.interruptList=[["atxHeading",{pedantic:!1}],["fencedCode",{pedantic:!1}],["thematicBreak",{pedantic:!1}],["definition",{commonmark:!1}]],cd.interruptBlockquote=[["indentedCode",{commonmark:!0}],["fencedCode",{commonmark:!0}],["atxHeading",{commonmark:!0}],["setextHeading",{commonmark:!0}],["thematicBreak",{commonmark:!0}],["html",{commonmark:!0}],["list",{commonmark:!0}],["definition",{commonmark:!1}]],cd.blockTokenizers={blankLine:sa $ 1(),indentedCode:pa $ 1(),fencedCode:ma $ 1(),blockquote:ba $ 2(),atxHeading:xa $ 2(),thematicBreak:Ba $ 1(),list:Ua $ 3(),setextHeading:Ga $ 2(),html:Ka $ 1(),definition:io $ 1(),table:oo $ 3(),paragraph:lo $ 2()},cd.inlineTokenizers={escape:Fo $ 1(),autoLink:yo $ 2(),url:Oo $ 1(),email:Mo $ 2(),html:Vo $ 1(),link:Qo $ 1(),reference:rs $ 1(),strong:os $ 1(),emphasis:ms $ 3(),deletion:ys $ 3(),code:Bs $ 2(),break:Os $ 3(),text:Ls $ 3()},cd.blockMethods=ud(cd.blockTokenizers),cd.inlineMethods=ud(cd.inlineTokenizers),cd.tokenizeBlock=od("block"),cd.tokenizeInline=od("inline"),cd.tokenizeFactory=od;function ud(_d){var yd=[],gd;for(gd in _d)yd.push(gd);return yd}}),Gs $ 1=C((Ra,qa)=>{var Ja=Zi $ 1(),ed=Ie $ 1(),td=Us $ 2();qa.exports=rd,rd.Parser=td;function rd(sd){var od=this.data("settings"),ld=Ja(td);ld.prototype.options=ed(ld.prototype.options,od,sd),this.Parser=ld}}),js $ 2=C((Ra,qa)=>{qa.exports=Ja;function Ja(ed){if(ed)throw ed}}),yn $ 2=C((Ra,qa)=>{qa.exports=function(Ja){return Ja!=null&&Ja.constructor!=null&&typeof Ja.constructor.isBuffer=="function"&&Ja.constructor.isBuffer(Ja)}}),rc $ 2=C((Ra,qa)=>{var Ja=Object.prototype.hasOwnProperty,ed=Object.prototype.toString,td=Object.defineProperty,rd=Object.getOwnPropertyDescriptor,sd=function(ud){return typeof Array.isArray=="function"?Array.isArray(ud):ed.call(ud)==="[object Array]"},od=function(ud){if(!ud||ed.call(ud)!=="[object Object]")return!1;var _d=Ja.call(ud,"constructor"),yd=ud.constructor&&ud.constructor.prototype&&Ja.call(ud.constructor.prototype,"isPrototypeOf");if(ud.constructor&&!_d&&!yd)return!1;var gd;for(gd in ud);return typeof gd>"u"||Ja.call(ud,gd)},ld=function(ud,_d){td&&_d.name==="__proto__"?td(ud,_d.name,{enumerable:!0,configurable:!0,value:_d.newValue,writable:!0}):ud[_d.name]=_d.newValue},cd=function(ud,_d){if(_d==="__proto__")if(Ja.call(ud,_d)){if(rd)return rd(ud,_d).value}else return;return ud[_d]};qa.exports=function ud(){var _d,yd,gd,Ed,Td,Od,Rd=arguments[0],Nd=1,Id=arguments.length,Md=!1;for(typeof Rd=="boolean"&&(Md=Rd,Rd=arguments[1]||{},Nd=2),(Rd==null||typeof Rd!="object"&&typeof Rd!="function")&&(Rd={});Nd<Id;++Nd)if(_d=arguments[Nd],_d!=null)for(yd in _d)gd=cd(Rd,yd),Ed=cd(_d,yd),Rd!==Ed&&(Md&&Ed&&(od(Ed)||(Td=sd(Ed)))?(Td?(Td=!1,Od=gd&&sd(gd)?gd:[]):Od=gd&&od(gd)?gd:{},ld(Rd,{name:yd,newValue:ud(Md,Od,Ed)})):typeof Ed<"u"&&ld(Rd,{name:yd,newV
2024-08-30 15:19:18 +08:00
Expected it to be 'string' or 'object' . ` ;if(Y $ 1(Ra))throw new Error("doc is valid.");let Ja=Object.prototype.toString.call(Ra);if(Ja!=="[object Object]")return ` Unexpected doc '${Ja}' . ` ;let ed=ll $ 2([...wr $ 2].map(td=> ` '${td}' ` ));return ` Unexpected doc . type '${Ra.type}' .
2024-09-07 10:27:05 +08:00
Expected it to be $ { ed } . ` }var Dt $ 3=class extends Error{constructor(Ja){super(fl $ 2(Ja));n_(this,"name","InvalidDocError");this.doc=Ja}},qe $ 2=Dt $ 3,Nn $ 2={};function Dl $ 2(Ra,qa,Ja,ed){let td=[Ra];for(;td.length>0;){let rd=td.pop();if(rd===Nn $ 2){Ja(td.pop());continue}Ja&&td.push(rd,Nn $ 2);let sd=Y $ 1(rd);if(!sd)throw new qe $ 2(rd);if((qa==null?void 0:qa(rd))!==!1)switch(sd){case H $ 1:case J $ 1:{let od=sd===H $ 1?rd:rd.parts;for(let ld=od.length,cd=ld-1;cd>=0;--cd)td.push(od[cd]);break}case X $ 1:td.push(rd.flatContents,rd.breakContents);break;case K $ 2:if(ed&&rd.expandedStates)for(let od=rd.expandedStates.length,ld=od-1;ld>=0;--ld)td.push(rd.expandedStates[ld]);else td.push(rd.contents);break;case re $ 3:case ee $ 1:case se $ 1:case fe $ 2:case ce $ 2:td.push(rd.contents);break;case $ $ 1:case ge $ 3:case oe $ 2:case le $ 2:case W $ 1:case te $ 2:break;default:throw new qe $ 2(rd)}}}var Rn $ 2=Dl $ 2,Un $ 2=()=>{},kr $ 2=Un $ 2;function Ze $ 2(Ra){return{type:ee $ 1,contents:Ra}}function ve $ 2(Ra,qa){return{type:re $ 3,contents:qa,n:Ra}}function ze $ 2(Ra,qa={}){return kr $ 2(qa.expandedStates),{type:K $ 2,id:qa.id,contents:Ra,break:!!qa.shouldBreak,expandedStates:qa.expandedStates}}function _e $ 3(Ra){return ve $ 2({type:"root"},Ra)}function Ee $ 2(Ra){return{type:J $ 1,parts:Ra}}function zn $ 2(Ra,qa="",Ja={}){return{type:X $ 1,breakContents:Ra,flatContents:qa,groupId:Ja.groupId}}var er $ 1={type:te $ 2},rr $ 1={type:W $ 1,hard:!0},pl $ 2={type:W $ 1,hard:!0,literal:!0},Br $ 3={type:W $ 1},qr $ 2={type:W $ 1,soft:!0},L $ 2=[rr $ 1,er $ 1],tr $ 1=[pl $ 2,er $ 1];function Tr $ 2(Ra,qa){let Ja=[];for(let ed=0;ed<qa.length;ed++)ed!==0&&Ja.push(Ra),Ja.push(qa[ed]);return Ja}function dl $ 2(Ra,qa){if(typeof Ra=="string")return qa(Ra);let Ja=new Map;return ed(Ra);function ed(rd){if(Ja.has(rd))return Ja.get(rd);let sd=td(rd);return Ja.set(rd,sd),sd}function td(rd){switch(Y $ 1(rd)){case H $ 1:return qa(rd.map(ed));case J $ 1:return qa({...rd,parts:rd.parts.map(ed)});case X $ 1:return qa({...rd,breakContents:ed(rd.breakContents),flatContents:ed(rd.flatContents)});case K $ 2:{let{expandedStates:sd,contents:od}=rd;return sd?(sd=sd.map(ed),od=sd[0]):od=ed(od),qa({...rd,contents:od,expandedStates:sd})}case re $ 3:case ee $ 1:case se $ 1:case fe $ 2:case ce $ 2:return qa({...rd,contents:ed(rd.contents)});case $ $ 1:case ge $ 3:case oe $ 2:case le $ 2:case W $ 1:case te $ 2:return qa(rd);default:throw new qe $ 2(rd)}}}function Mn $ 2(Ra){if(Ra.length>0){let qa=M $ 2(!1,Ra,-1);!qa.expandedStates&&!qa.break&&(qa.break="propagated")}return null}function Yn $ 3(Ra){let qa=new Set,Ja=[];function ed(rd){if(rd.type===te $ 2&&Mn $ 2(Ja),rd.type===K $ 2){if(Ja.push(rd),qa.has(rd))return!1;qa.add(rd)}}function td(rd){rd.type===K $ 2&&Ja.pop().break&&Mn $ 2(Ja)}Rn $ 2(Ra,ed,td,!0)}function Ce $ 1(Ra,qa=tr $ 1){return dl $ 2(Ra,Ja=>typeof Ja=="string"?Tr $ 2(qa,Ja.split( `
` )):Ja)}function hl $ 2(Ra,qa){let Ja=Ra.match(new RegExp( ` ( $ { Be$3 ( qa ) } ) + ` ,"gu"));return Ja===null?0:Ja.reduce((ed,td)=>Math.max(ed,td.length/qa.length),0)}var _r $ 2=hl $ 2;function ml $ 2(Ra,qa){let Ja=Ra.match(new RegExp( ` ( $ { Be$3 ( qa ) } ) + ` ,"gu"));if(Ja===null)return 0;let ed=new Map,td=0;for(let rd of Ja){let sd=rd.length/qa.length;ed.set(sd,!0),sd>td&&(td=sd)}for(let rd=1;rd<td;rd++)if(!ed.get(rd))return rd;return td+1}var Gn $ 3=ml $ 2,Sr $ 2="'",Vn $ 2='"';function Fl $ 3(Ra,qa){let Ja=qa===!0||qa===Sr $ 2?Sr $ 2:Vn $ 2,ed=Ja===Sr $ 2?Vn $ 2:Sr $ 2,td=0,rd=0;for(let sd of Ra)sd===Ja?td++:sd===ed&&rd++;return td>rd?ed:Ja}var jn $ 3=Fl $ 3,pt $ 2=class extends Error{constructor(Ja,ed,td="type"){super( ` Unexpected $ { ed } node $ { td } : $ { JSON . stringify ( Ja [ td ] ) } . ` );n_(this,"name","UnexpectedNodeError");this.node=Ja}}, $ n $ 3=pt $ 2,Xn $ 3=Ue $ 3(xr $ 2());function gl $ 2(Ra){return(Ra==null?void 0:Ra.type)==="front-matter"}var Hn $ 2=gl $ 2,nr $ 1=3;function vl $ 2(Ra){let qa=Ra.slice(0,nr $ 1);if(qa!=="---"&&qa!=="+++")return;let Ja=Ra.indexOf( `
2024-08-30 15:19:18 +08:00
` ,nr $ 1);if(Ja===-1)return;let ed=Ra.slice(nr $ 1,Ja).trim(),td=Ra.indexOf( `
$ { qa } ` ,Ja),rd=ed;if(rd||(rd=qa==="+++"?"toml":"yaml"),td===-1&&qa==="---"&&rd==="yaml"&&(td=Ra.indexOf( `
2024-09-03 08:22:14 +08:00
... ` ,Ja)),td===-1)return;let sd=td+1+nr $ 1,od=Ra.charAt(sd+1);if(!/ \s ?/u.test(od))return;let ld=Ra.slice(0,sd);return{type:"front-matter",language:rd,explicitLanguage:ed,value:Ra.slice(Ja+1,td),startDelimiter:qa,endDelimiter:ld.slice(-nr $ 1),raw:ld}}function El $ 3(Ra){let qa=vl $ 2(Ra);if(!qa)return{content:Ra};let{raw:Ja}=qa;return{frontMatter:qa,content:N $ 2(!1,Ja,/[^ \n ]/gu," ")+Ra.slice(Ja.length)}}var ir $ 2=El $ 3,Wn $ 2=["format","prettier"];function dt $ 2(Ra){let qa= ` @ ( $ { Wn$2 . join ( "|" ) } ) ` ,Ja=new RegExp([ ` <!-- \ \ s * $ { qa } \ \ s * -- > ` , ` \ \ { \ \ s * \ \ / \ \ * \ \ s * $ { qa } \ \ s * \ \ * \ \ / \ \ s * \ \ } ` , ` <!-- . * \ r ?
2024-08-27 22:31:52 +08:00
[ \ \ s \ \ S ] * ( ^ |
) [ ^ \ \ S
2024-08-30 15:19:18 +08:00
] * $ { qa } [ ^ \ \ S
2024-08-27 22:31:52 +08:00
] * ( $ |
) [ \ \ s \ \ S ] *
2024-08-30 15:19:18 +08:00
. * -- > ` ].join("|"),"mu"),ed=Ra.match(Ja);return(ed==null?void 0:ed.index)===0}var Kn $ 2=Ra=>dt $ 2(ir $ 2(Ra).content.trimStart()),Jn $ 3=Ra=>{let qa=ir $ 2(Ra),Ja= ` <!-- @ $ { Wn$2 [ 0 ] } -- > ` ;return qa.frontMatter? ` $ { qa . frontMatter . raw }
$ { Ja }
$ { qa . content } ` : ` $ { Ja }
$ { qa . content } ` },Cl $ 2=new Set(["position","raw"]);function Qn $ 3(Ra,qa,Ja){if((Ra.type==="front-matter"||Ra.type==="code"||Ra.type==="yaml"||Ra.type==="import"||Ra.type==="export"||Ra.type==="jsx")&&delete qa.value,Ra.type==="list"&&delete qa.isAligned,(Ra.type==="list"||Ra.type==="listItem")&&delete qa.spread,Ra.type==="text")return null;if(Ra.type==="inlineCode"&&(qa.value=N $ 2(!1,Ra.value, `
` ," ")),Ra.type==="wikiLink"&&(qa.value=N $ 2(!1,Ra.value.trim(),/[ \t \n ]+/gu," ")),(Ra.type==="definition"||Ra.type==="linkReference"||Ra.type==="imageReference")&&(qa.label=(0,Xn $ 3.default)(Ra.label)),(Ra.type==="link"||Ra.type==="image")&&Ra.url&&Ra.url.includes("("))for(let ed of"<>")qa.url=N $ 2(!1,Ra.url,ed,encodeURIComponent(ed));if((Ra.type==="definition"||Ra.type==="link"||Ra.type==="image")&&Ra.title&&(qa.title=N $ 2(!1,Ra.title,/ \\ (?=["')])/gu,"")),(Ja==null?void 0:Ja.type)==="root"&&Ja.children.length>0&&(Ja.children[0]===Ra||Hn $ 2(Ja.children[0])&&Ja.children[1]===Ra)&&Ra.type==="html"&&dt $ 2(Ra.value))return null}Qn $ 3.ignoredProperties=Cl $ 2;var Zn $ 2=Qn $ 3,ei $ 2=/(?:[ \u 02ea- \u 02eb \u 1100- \u 11ff \u 2e80- \u 2e99 \u 2e9b- \u 2ef3 \u 2f00- \u 2fd5 \u 2ff0- \u 303f \u 3041- \u 3096 \u 3099- \u 309f \u 30a1- \u 30fa \u 30fc- \u 30ff \u 3105- \u 312f \u 3131- \u 318e \u 3190- \u 4dbf \u 4e00- \u 9fff \u a700- \u a707 \u a960- \u a97c \u ac00- \u d7a3 \u d7b0- \u d7c6 \u d7cb- \u d7fb \u f900- \u fa6d \u fa70- \u fad9 \u fe10- \u fe1f \u fe30- \u fe6f \u ff00- \u ffef]|[ \u d840- \u d868 \u d86a- \u d86c \u d86f- \u d872 \u d874- \u d879 \u d880- \u d883 \u d885- \u d887][ \u dc00- \u dfff]| \u d81b[ \u dfe3]| \u d82b[ \u dff0- \u dff3 \u dff5- \u dffb \u dffd- \u dffe]| \u d82c[ \u dc00- \u dd22 \u dd32 \u dd50- \u dd52 \u dd55 \u dd64- \u dd67]| \u d83c[ \u de00 \u de50- \u de51]| \u d869[ \u dc00- \u dedf \u df00- \u dfff]| \u d86d[ \u dc00- \u df39 \u df40- \u dfff]| \u d86e[ \u dc00- \u dc1d \u dc20- \u dfff]| \u d873[ \u dc00- \u dea1 \u deb0- \u dfff]| \u d87a[ \u dc00- \u dfe0]| \u d87e[ \u dc00- \u de1d]| \u d884[ \u dc00- \u df4a \u df50- \u dfff]| \u d888[ \u dc00- \u dfaf])(?:[ \u fe00- \u fe0f]| \u db40[ \u dd00- \u ddef])?/u,Se $ 2=new RegExp("(?:[ \\ u0021- \\ u002f \\ u003a- \\ u0040 \\ u005b- \\ u0060 \\ u007b- \\ u007e]| \\ p{General_Category=Connector_Punctuation}| \\ p{General_Category=Dash_Punctuation}| \\ p{General_Category=Close_Punctuation}| \\ p{General_Category=Final_Punctuation}| \\ p{General_Category=Initial_Punctuation}| \\ p{General_Category=Other_Punctuation}| \\ p{General_Category=Open_Punctuation})","u");async function bl $ 2(Ra,qa){if(Ra.language==="yaml"){let Ja=Ra.value.trim(),ed=Ja?await qa(Ja,{parser:"yaml"}):"";return _e $ 3([Ra.startDelimiter,Ra.explicitLanguage,L $ 2,ed,ed?L $ 2:"",Ra.endDelimiter])}}var ri $ 3=bl $ 2,yl $ 2=Ra=>String(Ra).split(/[/ \\ ]/u).pop();function ti $ 3(Ra,qa){if(!qa)return;let Ja=yl $ 2(qa).toLowerCase();return Ra.find(({filenames:ed})=>ed==null?void 0:ed.some(td=>td.toLowerCase()===Ja))??Ra.find(({extensions:ed})=>ed==null?void 0:ed.some(td=>Ja.endsWith(td)))}function Al $ 3(Ra,qa){if(qa)return Ra.find(({name:Ja})=>Ja.toLowerCase()===qa)??Ra.find(({aliases:Ja})=>Ja==null?void 0:Ja.includes(qa))??Ra.find(({extensions:Ja})=>Ja==null?void 0:Ja.includes( ` . $ { qa } ` ))}function xl $ 3(Ra,qa){let Ja=Ra.plugins.flatMap(td=>td.languages??[]),ed=Al $ 3(Ja,qa.language)??ti $ 3(Ja,qa.physicalFile)??ti $ 3(Ja,qa.file)??(qa.physicalFile,void 0);return ed==null?void 0:ed.parsers[0]}var ni $ 3=xl $ 3,wl $ 3=new Proxy(()=>{},{get:()=>wl $ 3});function Oe $ 3(Ra){return Ra.position.start.offset}function Pe $ 3(Ra){return Ra.position.end.offset}var ht $ 2=new Set(["liquidNode","inlineCode","emphasis","esComment","strong","delete","wikiLink","link","linkReference","image","imageReference","footnote","footnoteReference","sentence","whitespace","word","break","inlineMath"]),Or $ 2=new Set([...ht $ 2,"tableCell","paragraph","heading"]),Le $ 2="non-cjk",De $ 1="cj-letter",be $ 4="k-letter",ur $ 1="cjk-punctuation",kl $ 2=new RegExp(" \\ p{Script_Extensions=Hangul}","u");function Pr $ 2(Ra){let qa=[],Ja=Ra.split(/([ \t \n ]+)/u);for(let[td,rd]of Ja.entries()){if(td%2===1){qa.push({type:"whitespace",value:/ \n /u.test(rd)? `
2024-09-03 08:22:14 +08:00
` :" "});continue}if((td===0||td===Ja.length-1)&&rd==="")continue;let sd=rd.split(new RegExp( ` ( $ { ei$2 . source } ) ` ,"u"));for(let[od,ld]of sd.entries())if(!((od===0||od===sd.length-1)&&ld==="")){if(od%2===0){ld!==""&&ed({type:"word",value:ld,kind:Le $ 2,hasLeadingPunctuation:Se $ 2.test(ld[0]),hasTrailingPunctuation:Se $ 2.test(M $ 2(!1,ld,-1))});continue}ed(Se $ 2.test(ld)?{type:"word",value:ld,kind:ur $ 1,hasLeadingPunctuation:!0,hasTrailingPunctuation:!0}:{type:"word",value:ld,kind:kl $ 2.test(ld)?be $ 4:De $ 1,hasLeadingPunctuation:!1,hasTrailingPunctuation:!1})}}return qa;function ed(td){let rd=M $ 2(!1,qa,-1);(rd==null?void 0:rd.type)==="word"&&!sd(Le $ 2,ur $ 1)&&![rd.value,td.value].some(od=>/ \u 3000/u.test(od))&&qa.push({type:"whitespace",value:""}),qa.push(td);function sd(od,ld){return rd.kind===od&&td.kind===ld||rd.kind===ld&&td.kind===od}}}function Me $ 4(Ra,qa){let Ja=qa.originalText.slice(Ra.position.start.offset,Ra.position.end.offset),{numberText:ed,leadingSpaces:td}=Ja.match(/^ \s *(?<numberText> \d +)( \. | \) )(?<leadingSpaces> \s *)/u).groups;return{number:Number(ed),leadingSpaces:td}}function ii $ 3(Ra,qa){return!Ra.ordered||Ra.children.length<2||Me $ 4(Ra.children[1],qa).number!==1?!1:Me $ 4(Ra.children[0],qa).number!==0?!0:Ra.children.length>2&&Me $ 4(Ra.children[2],qa).number===1}function Lr $ 2(Ra,qa){let{value:Ja}=Ra;return Ra.position.end.offset===qa.length&&Ja.endsWith( `
2024-08-30 15:19:18 +08:00
` )&&qa.endsWith( `
2024-09-03 08:22:14 +08:00
` )?Ja.slice(0,-1):Ja}function ye $ 2(Ra,qa){return function Ja(ed,td,rd){let sd={...qa(ed,td,rd)};return sd.children&&(sd.children=sd.children.map((od,ld)=>Ja(od,ld,[sd,...rd]))),sd}(Ra,null,[])}function mt $ 2(Ra){if((Ra==null?void 0:Ra.type)!=="link"||Ra.children.length!==1)return!1;let[qa]=Ra.children;return Oe $ 3(Ra)===Oe $ 3(qa)&&Pe $ 3(Ra)===Pe $ 3(qa)}function Bl $ 2(Ra,qa){let{node:Ja}=Ra;if(Ja.type==="code"&&Ja.lang!==null){let ed=ni $ 3(qa,{language:Ja.lang});if(ed)return async td=>{let rd=qa.__inJsTemplate?"~":" ` ",sd=rd.repeat(Math.max(3,_r$2(Ja.value,rd)+1)),od={parser:ed};Ja.lang===" ts "||Ja.lang===" typescript "?od.filepath=" dummy . ts ":Ja.lang===" tsx "&&(od.filepath=" dummy . tsx ");let ld=await td(Lr$2(Ja,qa.originalText),od);return _e$3([sd,Ja.lang,Ja.meta?" "+Ja.meta:" ",L$2,Ce$1(ld),L$2,sd])}}switch(Ja.type){case" front - matter ":return ed=>ri$3(Ja,ed);case" import ":case" export ":return ed=>ed(Ja.value,{parser:" babel "});case" jsx ":return ed=>ed(`<$>${Ja.value}</$>`,{parser:" _ _js _expression ",rootMarker:" mdx "})}return null}var ui$2=Bl$2,ar$1=null;function or$1(Ra){if(ar$1!==null&&typeof ar$1.property){let qa=ar$1;return ar$1=or$1.prototype=null,qa}return ar$1=or$1.prototype=Ra??Object.create(null),new or$1}var ql$3=10;for(let Ra=0;Ra<=ql$3;Ra++)or$1();function Ft$3(Ra){return or$1(Ra)}function Tl$3(Ra,qa=" type "){Ft$3(Ra);function Ja(ed){let td=ed[qa],rd=Ra[td];if(!Array.isArray(rd))throw Object.assign(new Error(`Missing visitor keys for '${td}'.`),{node:ed});return rd}return Ja}var ai$3=Tl$3,_l$2={" front - matter ":[],root:[" children "],paragraph:[" children "],sentence:[" children "],word:[],whitespace:[],emphasis:[" children "],strong:[" children "],delete:[" children "],inlineCode:[],wikiLink:[],link:[" children "],image:[],blockquote:[" children "],heading:[" children "],code:[],html:[],list:[" children "],thematicBreak:[],linkReference:[" children "],imageReference:[],definition:[],footnote:[" children "],footnoteReference:[],footnoteDefinition:[" children "],table:[" children "],tableCell:[" children "],break:[],liquidNode:[],import:[],export:[],esComment:[],jsx:[],math:[],inlineMath:[],tableRow:[" children "],listItem:[" children "],text:[]},oi$2=_l$2,Sl$3=ai$3(oi$2),si$3=Sl$3;function ci$2(Ra){switch(Ra){case" cr ":return" \ r ";case" crlf " : return ` \r
2024-08-30 15:19:18 +08:00
` ;default:return `
2024-09-03 08:22:14 +08:00
` }}var li $ 3=()=>/[#*0-9] \u FE0F? \u 20E3|[ \x A9 \x AE \u 203C \u 2049 \u 2122 \u 2139 \u 2194- \u 2199 \u 21A9 \u 21AA \u 231A \u 231B \u 2328 \u 23CF \u 23ED- \u 23EF \u 23F1 \u 23F2 \u 23F8- \u 23FA \u 24C2 \u 25AA \u 25AB \u 25B6 \u 25C0 \u 25FB \u 25FC \u 25FE \u 2600- \u 2604 \u 260E \u 2611 \u 2614 \u 2615 \u 2618 \u 2620 \u 2622 \u 2623 \u 2626 \u 262A \u 262E \u 262F \u 2638- \u 263A \u 2640 \u 2642 \u 2648- \u 2653 \u 265F \u 2660 \u 2663 \u 2665 \u 2666 \u 2668 \u 267B \u 267E \u 267F \u 2692 \u 2694- \u 2697 \u 2699 \u 269B \u 269C \u 26A0 \u 26A7 \u 26AA \u 26B0 \u 26B1 \u 26BD \u 26BE \u 26C4 \u 26C8 \u 26CF \u 26D1 \u 26E9 \u 26F0- \u 26F5 \u 26F7 \u 26F8 \u 26FA \u 2702 \u 2708 \u 2709 \u 270F \u 2712 \u 2714 \u 2716 \u 271D \u 2721 \u 2733 \u 2734 \u 2744 \u 2747 \u 2757 \u 2763 \u 27A1 \u 2934 \u 2935 \u 2B05- \u 2B07 \u 2B1B \u 2B1C \u 2B55 \u 3030 \u 303D \u 3297 \u 3299] \u FE0F?|[ \u 261D \u 270C \u 270D](?: \u FE0F| \u D83C[ \u DFFB- \u DFFF])?|[ \u 270A \u 270B](?: \u D83C[ \u DFFB- \u DFFF])?|[ \u 23E9- \u 23EC \u 23F0 \u 23F3 \u 25FD \u 2693 \u 26A1 \u 26AB \u 26C5 \u 26CE \u 26D4 \u 26EA \u 26FD \u 2705 \u 2728 \u 274C \u 274E \u 2753- \u 2755 \u 2795- \u 2797 \u 27B0 \u 27BF \u 2B50]| \u 26D3 \u FE0F?(?: \u 200D \u D83D \u DCA5)?| \u 26F9(?: \u FE0F| \u D83C[ \u DFFB- \u DFFF])?(?: \u 200D[ \u 2640 \u 2642] \u FE0F?)?| \u 2764 \u FE0F?(?: \u 200D(?: \u D83D \u DD25| \u D83E \u DE79))?| \u D83C(?:[ \u DC04 \u DD70 \u DD71 \u DD7E \u DD7F \u DE02 \u DE37 \u DF21 \u DF24- \u DF2C \u DF36 \u DF7D \u DF96 \u DF97 \u DF99- \u DF9B \u DF9E \u DF9F \u DFCD \u DFCE \u DFD4- \u DFDF \u DFF5 \u DFF7] \u FE0F?|[ \u DF85 \u DFC2 \u DFC7](?: \u D83C[ \u DFFB- \u DFFF])?|[ \u DFC4 \u DFCA](?: \u D83C[ \u DFFB- \u DFFF])?(?: \u 200D[ \u 2640 \u 2642] \u FE0F?)?|[ \u DFCB \u DFCC](?: \u FE0F| \u D83C[ \u DFFB- \u DFFF])?(?: \u 200D[ \u 2640 \u 2642] \u FE0F?)?|[ \u DCCF \u DD8E \u DD91- \u DD9A \u DE01 \u DE1A \u DE2F \u DE32- \u DE36 \u DE38- \u DE3A \u DE50 \u DE51 \u DF00- \u DF20 \u DF2D- \u DF35 \u DF37- \u DF43 \u DF45- \u DF4A \u DF4C- \u DF7C \u DF7E- \u DF84 \u DF86- \u DF93 \u DFA0- \u DFC1 \u DFC5 \u DFC6 \u DFC8 \u DFC9 \u DFCF- \u DFD3 \u DFE0- \u DFF0 \u DFF8- \u DFFF]| \u DDE6 \u D83C[ \u DDE8- \u DDEC \u DDEE \u DDF1 \u DDF2 \u DDF4 \u DDF6- \u DDFA \u DDFC \u DDFD \u DDFF]| \u DDE7 \u D83C[ \u DDE6 \u DDE7 \u DDE9- \u DDEF \u DDF1- \u DDF4 \u DDF6- \u DDF9 \u DDFB \u DDFC \u DDFE \u DDFF]| \u DDE8 \u D83C[ \u DDE6 \u DDE8 \u DDE9 \u DDEB- \u DDEE \u DDF0- \u DDF5 \u DDF7 \u DDFA- \u DDFF]| \u DDE9 \u D83C[ \u DDEA \u DDEC \u DDEF \u DDF0 \u DDF2 \u DDF4 \u DDFF]| \u DDEA \u D83C[ \u DDE6 \u DDE8 \u DDEA \u DDEC \u DDED \u DDF7- \u DDFA]| \u DDEB \u D83C[ \u DDEE- \u DDF0 \u DDF2 \u DDF4 \u DDF7]| \u DDEC \u D83C[ \u DDE6 \u DDE7 \u DDE9- \u DDEE \u DDF1- \u DDF3 \u DDF5- \u DDFA \u DDFC \u DDFE]| \u DDED \u D83C[ \u DDF0 \u DDF2 \u DDF3 \u DDF7 \u DDF9 \u DDFA]| \u DDEE \u D83C[ \u DDE8- \u DDEA \u DDF1- \u DDF4 \u DDF6- \u DDF9]| \u DDEF \u D83C[ \u DDEA \u DDF2 \u DDF4 \u DDF5]| \u DDF0 \u D83C[ \u DDEA \u DDEC- \u DDEE \u DDF2 \u DDF3 \u DDF5 \u DDF7 \u DDFC \u DDFE \u DDFF]| \u DDF1 \u D83C[ \u DDE6- \u DDE8 \u DDEE \u DDF0 \u DDF7- \u DDFB \u DDFE]| \u DDF2 \u D83C[ \u DDE6 \u DDE8- \u DDED \u DDF0- \u DDFF]| \u DDF3 \u D83C[ \u DDE6 \u DDE8 \u DDEA- \u DDEC \u DDEE \u DDF1 \u DDF4 \u DDF5 \u DDF7 \u DDFA \u DDFF]| \u DDF4 \u D83C \u DDF2| \u DDF5 \u D83C[ \u DDE6 \u DDEA- \u DDED \u DDF0- \u DDF3 \u DDF7- \u DDF9 \u DDFC \u DDFE]| \u DDF6 \u D83C \u DDE6| \u DDF7 \u D83C[ \u DDEA \u DDF4 \u DDF8 \u DDFA \u DDFC]| \u DDF8 \u D83C[ \u DDE6- \u DDEA \u DDEC- \u DDF4 \u DDF7- \u DDF9 \u DDFB \u DDFD- \u DDFF]| \u DDF9 \u D83C[ \u DDE6 \u DDE8 \u DDE9 \u DDEB- \u DDED \u DDEF- \u DDF4 \u DDF7 \u DDF9 \u DDFB \u DDFC \u DDFF]| \u DDFA \u D83C[ \u DDE6 \u DDEC \u DDF2 \u DDF3 \u DDF8 \u DDFE \u DDFF]| \u DDFB \u D83C[ \u DDE6 \u DDE8 \u DDEA \u DDEC \u DDEE \u DDF3 \u DDFA]| \u DDFC \u D83C[ \u DDEB \u DDF8]| \u DDFD \u D83C \u DDF0| \u DDFE \u D83C[ \u DDEA \u DDF9]| \u DDFF \u D83C[ \u DDE6 \u DDF2 \u DDFC]| \u DF44(?: \u 200D \u D83D \u DFEB)?| \u DF4B(?: \u 200D \u D83D \u DFE9)?| \u DFC3(?: \u D83C[ \u DFFB- \u DFFF])?(?: \u 200D(?:[ \u 2640 \u 2642] \u FE0F?(?: \u 200D \u 27A1 \u FE0F?)?| \u 27A1 \u FE0F?))?| \u DFF3 \u FE0F?(?: \u 200D(?: \u 26A7 \u FE0F?| \u D83C \u DF08))?| \u DFF4(?: \u 200D \u 2620 \u FE0F?| \u DB40 \u DC67 \u DB40 \u DC62 \u DB40(?: \u DC65 \u DB40 \u DC6E \u DB40 \u DC67| \u DC73 \u DB40 \u DC63 \u DB40 \u DC74| \u DC77 \u DB40 \u DC6C \u DB40 \u DC73) \u DB40 \u DC7F)?)| \u D83D(?:[ \u DC3F \u DCFD \u DD49 \u DD4A \u DD6F \u DD70 \u DD73 \u DD76- \u DD79 \u DD87 \u DD8A- \u DD8D \u DDA5 \u DDA8 \u DDB1 \u DDB2 \u DDBC \u DDC2- \u DDC4 \u DDD1- \u DDD3 \u DDDC- \u DDDE \u DDE1 \u DDE3 \u DDE8 \u DDEF \u DDF3 \u DDFA \u DECB \u DECD- \u DECF \u DEE0- \u DEE5 \u DEE9 \u DEF0 \u DEF3] \u FE0F?|[ \u DC42 \u DC43 \u DC46- \u DC50 \u DC66 \u DC67 \u DC6B- \u DC6D \u DC72 \u DC74- \u DC76 \u DC78 \u DC7C \u DC83 \u DC85 \u DC8F \u DC91 \u DCAA \u DD7A \u DD95 \u DD96 \u DE4C \u DE4F \u DEC0 \u DECC](?: \u D83C[ \u DFFB- \u DFFF])?|[ \u DC6E \u DC70 \u DC71 \u DC73 \u DC77 \u DC81 \u DC82 \u DC86 \u DC87 \u DE45- \u DE47 \u DE4B \u DE4D \u DE4E \u DEA3 \u DEB4 \u DEB5](?: \u D83C[ \u
2024-08-30 15:19:18 +08:00
` ?N $ 2(!1,Ed, `
2024-09-08 17:22:36 +08:00
` ,td):Ed;od.push(Td),sd.length>0&&(rd+=sr $ 1(Td));break}case H $ 1:for(let Td=Ed.length-1;Td>=0;Td--)sd.push({ind:yd,mode:gd,doc:Ed[Td]});break;case ge $ 3:if(ud>=2)throw new Error("There are too many 'cursor' in doc.");od.push(cr $ 1),ud++;break;case ee $ 1:sd.push({ind:Ll $ 3(yd,qa),mode:gd,doc:Ed.contents});break;case re $ 3:sd.push({ind:Il $ 3(yd,Ed.n,qa),mode:gd,doc:Ed.contents});break;case oe $ 2:rd-=vt $ 2(od);break;case K $ 2:switch(gd){case ne $ 2:if(!ld){sd.push({ind:yd,mode:Ed.break?G $ 2:ne $ 2,doc:Ed.contents});break}case G $ 2:{ld=!1;let Td={ind:yd,mode:ne $ 2,doc:Ed.contents},Od=ed-rd,Rd=cd.length>0;if(!Ed.break&&Ir $ 2(Td,sd,Od,Rd,Ja))sd.push(Td);else if(Ed.expandedStates){let Nd=M $ 2(!1,Ed.expandedStates,-1);if(Ed.break){sd.push({ind:yd,mode:G $ 2,doc:Nd});break}else for(let Id=1;Id<Ed.expandedStates.length+1;Id++)if(Id>=Ed.expandedStates.length){sd.push({ind:yd,mode:G $ 2,doc:Nd});break}else{let Md=Ed.expandedStates[Id],Ld={ind:yd,mode:ne $ 2,doc:Md};if(Ir $ 2(Ld,sd,Od,Rd,Ja)){sd.push(Ld);break}}}else sd.push({ind:yd,mode:G $ 2,doc:Ed.contents});break}}Ed.id&&(Ja[Ed.id]=M $ 2(!1,sd,-1).mode);break;case J $ 1:{let Td=ed-rd,{parts:Od}=Ed;if(Od.length===0)break;let[Rd,Nd]=Od,Id={ind:yd,mode:ne $ 2,doc:Rd},Md={ind:yd,mode:G $ 2,doc:Rd},Ld=Ir $ 2(Id,[],Td,cd.length>0,Ja,!0);if(Od.length===1){Ld?sd.push(Id):sd.push(Md);break}let Pd={ind:yd,mode:ne $ 2,doc:Nd},qd={ind:yd,mode:G $ 2,doc:Nd};if(Od.length===2){Ld?sd.push(Pd,Id):sd.push(qd,Md);break}Od.splice(0,2);let Yd={ind:yd,mode:gd,doc:Ee $ 2(Od)},Ud=Od[0];Ir $ 2({ind:yd,mode:ne $ 2,doc:[Rd,Nd,Ud]},[],Td,cd.length>0,Ja,!0)?sd.push(Yd,Pd,Id):Ld?sd.push(Yd,qd,Id):sd.push(Yd,qd,Md);break}case X $ 1:case se $ 1:{let Td=Ed.groupId?Ja[Ed.groupId]:gd;if(Td===G $ 2){let Od=Ed.type===X $ 1?Ed.breakContents:Ed.negate?Ed.contents:Ze $ 2(Ed.contents);Od&&sd.push({ind:yd,mode:gd,doc:Od})}if(Td===ne $ 2){let Od=Ed.type===X $ 1?Ed.flatContents:Ed.negate?Ze $ 2(Ed.contents):Ed.contents;Od&&sd.push({ind:yd,mode:gd,doc:Od})}break}case ce $ 2:cd.push({ind:yd,mode:gd,doc:Ed.contents});break;case le $ 2:cd.length>0&&sd.push({ind:yd,mode:gd,doc:rr $ 1});break;case W $ 1:switch(gd){case ne $ 2:if(Ed.hard)ld=!0;else{Ed.soft||(od.push(" "),rd+=1);break}case G $ 2:if(cd.length>0){sd.push({ind:yd,mode:gd,doc:Ed},...cd.reverse()),cd.length=0;break}Ed.literal?yd.root?(od.push(td,yd.root.value),rd=yd.root.length):(od.push(td),rd=0):(rd-=vt $ 2(od),od.push(td+yd.value),rd=yd.length);break}break;case fe $ 2:sd.push({ind:yd,mode:gd,doc:Ed.contents});break;case te $ 2:break;default:throw new qe $ 2(Ed)}sd.length===0&&cd.length>0&&(sd.push(...cd.reverse()),cd.length=0)}let _d=od.indexOf(cr $ 1);if(_d!==-1){let yd=od.indexOf(cr $ 1,_d+1),gd=od.slice(0,_d).join(""),Ed=od.slice(_d+1,yd).join(""),Td=od.slice(yd+1).join("");return{formatted:gd+Ed+Td,cursorNodeStart:gd.length,cursorNodeText:Ed}}return{formatted:od.join("")}}function mi $ 1(Ra,qa,Ja){let{node:ed}=Ra,td=[],rd=Ra.map(()=>Ra.map(({index:_d})=>{let yd=hi $ 2(Ja(),qa).formatted,gd=sr $ 1(yd);return td[_d]=Math.max(td[_d]??3,gd),{text:yd,width:gd}},"children"),"children"),sd=ld(!1);if(qa.proseWrap!=="never")return[er $ 1,sd];let od=ld(!0);return[er $ 1,ze $ 2(zn $ 2(od,sd))];function ld(_d){return Tr $ 2(rr $ 1,[ud(rd[0],_d),cd(_d),...rd.slice(1).map(yd=>ud(yd,_d))].map(yd=> ` | $ { yd . join ( " | " ) } | ` ))}function cd(_d){return td.map((yd,gd)=>{let Ed=ed.align[gd],Td=Ed==="center"||Ed==="left"?":":"-",Od=Ed==="center"||Ed==="right"?":":"-",Rd=_d?"-":"-".repeat(yd-2);return ` $ { Td } $ { Rd } $ { Od } ` })}function ud(_d,yd){return _d.map(({text:gd,width:Ed},Td)=>{if(yd)return gd;let Od=td[Td]-Ed,Rd=ed.align[Td],Nd=0;Rd==="right"?Nd=Od:Rd==="center"&&(Nd=Math.floor(Od/2));let Id=Od-Nd;return ` $ { " " . repeat ( Nd ) } $ { gd } $ { " " . repeat ( Id ) } ` })}}function Fi $ 1(Ra,qa,Ja){let ed=Ra.map(Ja,"children");return Nl $ 3(ed)}function Nl $ 3(Ra){let qa=[""];return function Ja(ed){for(let td of ed){let rd=Y $ 1(td);if(rd===H $ 1){Ja(td);continue}let sd=td,od=[];rd===J $ 1&&([sd,...od]=td.parts),qa.push([qa.pop(),sd],...od)}}(Ra),Ee $ 2(qa)}var Rl $ 3=/^. $ /su;function Ul $ 2(Ra,qa){return Ra=zl $ 3(Ra,qa),Ra=Yl $ 2(Ra),Ra=Vl $ 2(Ra,qa),Ra=jl $ 2(Ra,qa),Ra=Gl $ 3(Ra),Ra}function zl $ 3(Ra,qa){return ye $ 2(Ra,Ja=>Ja.type!=="text"||J
2024-08-30 15:19:18 +08:00
` )return L $ 2;let td=qa===" "||qa=== `
2024-09-03 08:22:14 +08:00
` &&Jl $ 3(Ra,ed);return Xl $ 3(Ra,qa,Ja,ed,td)?td?Br $ 3:qr $ 2:td?" ":""}var Ql $ 3=new Set(["listItem","definition"]);function Zl $ 2(Ra,qa,Ja){var ed,td;let{node:rd}=Ra;if(af(Ra)){let sd=[""],od=Pr $ 2(qa.originalText.slice(rd.position.start.offset,rd.position.end.offset));for(let ld of od){if(ld.type==="word"){sd.push([sd.pop(),ld.value]);continue}let cd=Et $ 3(Ra,ld.value,qa.proseWrap,!0);if(Y $ 1(cd)=== $ $ 1){sd.push([sd.pop(),cd]);continue}sd.push(cd)}return Ee $ 2(sd)}switch(rd.type){case"front-matter":return qa.originalText.slice(rd.position.start.offset,rd.position.end.offset);case"root":return rd.children.length===0?"":[tf(Ra,qa,Ja),L $ 2];case"paragraph":return Fi $ 1(Ra,qa,Ja);case"sentence":return vi $ 2(Ra,Ja);case"word":{let sd=N $ 2(!1,N $ 2(!1,rd.value,"*",String.raw ` \ * ` ),new RegExp([ ` ( ^ | $ { Se$2 . source } ) ( _ + ) ` , ` ( _ + ) ( $ { Se$2 . source } | $ ) ` ].join("|"),"gu"),(cd,ud,_d,yd,gd)=>N $ 2(!1,_d? ` $ { ud } $ { _d } ` : ` $ { yd } $ { gd } ` ,"_",String.raw ` \ _ ` )),od=(cd,ud,_d)=>cd.type==="sentence"&&_d===0,ld=(cd,ud,_d)=>mt $ 2(cd.children[_d-1]);return sd!==rd.value&&(Ra.match(void 0,od,ld)||Ra.match(void 0,od,(cd,ud,_d)=>cd.type==="emphasis"&&_d===0,ld))&&(sd=sd.replace(/^( \\ ?[*_])+/u,cd=>N $ 2(!1,cd," \\ ",""))),sd}case"whitespace":{let{next:sd}=Ra,od=sd&&/^>|^(?:[*+-]|#{1,6}| \d +[).]) $ /u.test(sd.value)?"never":qa.proseWrap;return Et $ 3(Ra,rd.value,od)}case"emphasis":{let sd;if(mt $ 2(rd.children[0]))sd=qa.originalText[rd.position.start.offset];else{let{previous:od,next:ld}=Ra;sd=(od==null?void 0:od.type)==="sentence"&&((ed=M $ 2(!1,od.children,-1))==null?void 0:ed.type)==="word"&&!M $ 2(!1,od.children,-1).hasTrailingPunctuation||(ld==null?void 0:ld.type)==="sentence"&&((td=ld.children[0])==null?void 0:td.type)==="word"&&!ld.children[0].hasLeadingPunctuation||Ra.hasAncestor(cd=>cd.type==="emphasis")?"*":"_"}return[sd,V $ 3(Ra,qa,Ja),sd]}case"strong":return["**",V $ 3(Ra,qa,Ja),"**"];case"delete":return["~~",V $ 3(Ra,qa,Ja),"~~"];case"inlineCode":{let sd=qa.proseWrap==="preserve"?rd.value:N $ 2(!1,rd.value, `
2024-09-08 17:22:36 +08:00
` ," "),od=Gn $ 3(sd," ` "),ld=" ` ".repeat(od||1),cd=sd.startsWith(" ` ")||sd.endsWith(" ` ")||/^[ \n ]/u.test(sd)&&/[ \n ] $ /u.test(sd)&&/[^ \n ]/u.test(sd)?" ":"";return[ld,cd,sd,cd,ld]}case"wikiLink":{let sd="";return qa.proseWrap==="preserve"?sd=rd.value:sd=N $ 2(!1,rd.value,/[ \t \n ]+/gu," "),["[[",sd,"]]"]}case"link":switch(qa.originalText[rd.position.start.offset]){case"<":{let sd="mailto:";return["<",rd.url.startsWith(sd)&&qa.originalText.slice(rd.position.start.offset+1,rd.position.start.offset+1+sd.length)!==sd?rd.url.slice(sd.length):rd.url,">"]}case"[":return["[",V $ 3(Ra,qa,Ja),"](",Ct $ 4(rd.url,")"),Nr $ 2(rd.title,qa),")"];default:return qa.originalText.slice(rd.position.start.offset,rd.position.end.offset)}case"image":return["![",rd.alt||"","](",Ct $ 4(rd.url,")"),Nr $ 2(rd.title,qa),")"];case"blockquote":return["> ",ve $ 2("> ",V $ 3(Ra,qa,Ja))];case"heading":return["#".repeat(rd.depth)+" ",V $ 3(Ra,qa,Ja)];case"code":{if(rd.isIndented){let ld=" ".repeat(4);return ve $ 2(ld,[ld,Ce $ 1(rd.value,L $ 2)])}let sd=qa.__inJsTemplate?"~":" ` ",od=sd.repeat(Math.max(3,_r$2(rd.value,sd)+1));return[od,rd.lang||" ",rd.meta?" "+rd.meta:" ",L$2,Ce$1(Lr$2(rd,qa.originalText),L$2),L$2,od]}case" html ":{let{parent:sd,isLast:od}=Ra,ld=sd.type===" root "&&od?rd.value.trimEnd():rd.value,cd=/^<!--.*-->$/su.test(ld);return Ce$1(ld,cd?L$2:_e$3(tr$1))}case" list ":{let sd=Ai$2(rd,Ra.parent),od=ii$3(rd,qa);return V$3(Ra,qa,Ja,{processor(ld){let cd=_d(),ud=ld.node;if(ud.children.length===2&&ud.children[1].type===" html "&&ud.children[0].position.start.column!==ud.children[1].position.start.column)return[cd,yi$3(ld,qa,Ja,cd)];return[cd,ve$2(" ".repeat(cd.length),yi$3(ld,qa,Ja,cd))];function _d(){let yd=rd.ordered?(ld.isFirst?rd.start:od?1:rd.start+ld.index)+(sd%2===0?" . ":" ) "):sd%2===0?" - ":" * ";return rd.isAligned||rd.hasIndentedCodeblock?ef(yd,qa):yd}}})}case" thematicBreak ":{let{ancestors:sd}=Ra,od=sd.findIndex(ld=>ld.type===" list ");return od===-1?" -- - ":Ai$2(sd[od],sd[od+1])%2===0?" * * * ":" -- - "}case" linkReference ":return[" [ ",V$3(Ra,qa,Ja)," ] ",rd.referenceType===" full "?bt$3(rd):rd.referenceType===" collapsed "?" [ ] ":" "];case" imageReference ":switch(rd.referenceType){case" full ":return[" ! [ ",rd.alt||" "," ] ",bt$3(rd)];default:return[" ! [ ",rd.alt," ] ",rd.referenceType===" collapsed "?" [ ] ":" "]}case" definition ":{let sd=qa.proseWrap===" always "?Br$3:" ";return ze$2([bt$3(rd)," : ",Ze$2([sd,Ct$4(rd.url),rd.title===null?" ":[sd,Nr$2(rd.title,qa,!1)]])])}case" footnote ":return[" [ ^ ",V$3(Ra,qa,Ja)," ] "];case" footnoteReference ":return Bi$2(rd);case" footnoteDefinition ":{let sd=rd.children.length===1&&rd.children[0].type===" paragraph "&&(qa.proseWrap===" never "||qa.proseWrap===" preserve "&&rd.children[0].position.start.line===rd.children[0].position.end.line);return[Bi$2(rd)," : ",sd?V$3(Ra,qa,Ja):ze$2([ve$2(" ".repeat(4),V$3(Ra,qa,Ja,{processor:({isFirst:od})=>od?ze$2([qr$2,Ja()]):Ja()}))])]}case" table ":return mi$1(Ra,qa,Ja);case" tableCell ":return V$3(Ra,qa,Ja);case" break ":return/\s/u.test(qa.originalText[rd.position.start.offset])?[" ",_e$3(tr$1)]:[" \ \ ",L$2];case" liquidNode ":return Ce$1(rd.value,L$2);case" import ":case" export ":case" jsx ":return rd.value;case" esComment ":return[" { /* ",rd.value," */ } "];case" math ":return[" $$ ",L$2,rd.value?[Ce$1(rd.value,L$2),L$2]:" "," $$ "];case" inlineMath ":return qa.originalText.slice(Oe$3(rd),Pe$3(rd));case" tableRow ":case" listItem ":case" text ":default:throw new $n$3(rd," Markdown ")}}function yi$3(Ra,qa,Ja,ed){let{node:td}=Ra,rd=td.checked===null?" ":td.checked?" [ x ] ":" [ ] ";return[rd,V$3(Ra,qa,Ja,{processor({node:sd,isFirst:od}){if(od&&sd.type!==" list ")return ve$2(" ".repeat(rd.length),Ja());let ld=" ".repeat(sf(qa.tabWidth-ed.length,0,3));return[ld,ve$2(ld,Ja())]}})]}function ef(Ra,qa){let Ja=ed();return Ra+" " . repeat ( Ja >= 4 ? 0 : Ja ) ; function ed ( ) { let td = Ra . length % qa . tabWidth ; return td === 0 ? 0 : qa . tabWidth - td } } function Ai$2 ( Ra , qa ) { return rf ( Ra , qa , Ja => Ja . ordered === Ra . ordered ) } function rf ( Ra , qa , Ja ) { let ed = - 1 ; for ( let td of qa . children ) if ( td . type === Ra . type && Ja ( td ) ? ed ++ : ed = - 1 , td === Ra ) return ed } function tf ( Ra , qa , Ja ) { let ed = [ ] , td = null , { children : rd } = Ra . node ; for ( let [ sd , od ] of rd . entries ( ) ) switch ( yt$2 (
` )}function uf({node:Ra,previous:qa,parent:Ja},ed){if(wi $ 2(qa,ed))return!0;let td=qa.type===Ra.type&&Ql $ 3.has(Ra.type),rd=Ja.type==="listItem"&&!wi $ 2(Ja,ed),sd=yt $ 2(qa)==="next",od=Ra.type==="html"&&qa.type==="html"&&qa.position.end.line+1===Ra.position.start.line,ld=Ra.type==="html"&&Ja.type==="listItem"&&qa.type==="paragraph"&&qa.position.end.line+1===Ra.position.start.line;return!(td||rd||sd||od||ld)}function ki $ 2({node:Ra,previous:qa}){let Ja=qa.type==="list",ed=Ra.type==="code"&&Ra.isIndented;return Ja&&ed}function af(Ra){let qa=Ra.findAncestor(Ja=>Ja.type==="linkReference"||Ja.type==="imageReference");return qa&&(qa.type!=="linkReference"||qa.referenceType!=="full")}var of=(Ra,qa)=>{for(let Ja of qa)Ra=N $ 2(!1,Ra,Ja,encodeURIComponent(Ja));return Ra};function Ct $ 4(Ra,qa=[]){let Ja=[" ",...Array.isArray(qa)?qa:[qa]];return new RegExp(Ja.map(ed=>Be $ 3(ed)).join("|"),"u").test(Ra)? ` < $ { of ( Ra , "<>" ) } > ` :Ra}function Nr $ 2(Ra,qa,Ja=!0){if(!Ra)return"";if(Ja)return" "+Nr $ 2(Ra,qa,!1);if(Ra=N $ 2(!1,Ra,/ \\ (?=["')])/gu,""),Ra.includes('"')&&Ra.includes("'")&&!Ra.includes(")"))return ` ( $ { Ra } ) ` ;let ed=jn $ 3(Ra,qa.singleQuote);return Ra=N $ 2(!1,Ra," \\ "," \\ \\ "),Ra=N $ 2(!1,Ra,ed, ` \ \ $ { ed } ` ), ` $ { ed } $ { Ra } $ { ed } ` }function sf(Ra,qa,Ja){return Ra<qa?qa:Ra>Ja?Ja:Ra}function cf(Ra){return Ra.index>0&&yt $ 2(Ra.previous)==="next"}function bt $ 3(Ra){return ` [ $ { ( 0 , qi$1 . default ) ( Ra . label ) } ] ` }function Bi $ 2(Ra){return ` [ ^ $ { Ra . label } ] ` }var lf={preprocess:gi $ 2,print:Zl $ 2,embed:ui $ 2,massageAstNode:Zn $ 2,hasPrettierIgnore:cf,insertPragma:Jn $ 3,getVisitorKeys:si $ 3},Ti $ 2=lf,_i $ 2=[{linguistLanguageId:222,name:"Markdown",type:"prose",color:"#083fa1",aliases:["md","pandoc"],aceMode:"markdown",codemirrorMode:"gfm",codemirrorMimeType:"text/x-gfm",wrap:!0,extensions:[".md",".livemd",".markdown",".mdown",".mdwn",".mkd",".mkdn",".mkdown",".ronn",".scd",".workbook"],filenames:["contents.lr","README"],tmScope:"text.md",parsers:["markdown"],vscodeLanguageIds:["markdown"]},{linguistLanguageId:222,name:"MDX",type:"prose",color:"#083fa1",aliases:["md","pandoc"],aceMode:"markdown",codemirrorMode:"gfm",codemirrorMimeType:"text/x-gfm",wrap:!0,extensions:[".mdx"],filenames:[],tmScope:"text.md",parsers:["mdx"],vscodeLanguageIds:["mdx"]}],At $ 4={bracketSpacing:{category:"Common",type:"boolean",default:!0,description:"Print spaces between brackets.",oppositeDescription:"Do not print spaces between brackets."},singleQuote:{category:"Common",type:"boolean",default:!1,description:"Use single quotes instead of double quotes."},proseWrap:{category:"Common",type:"choice",default:"preserve",description:"How to wrap prose.",choices:[{value:"always",description:"Wrap prose if it exceeds the print width."},{value:"never",description:"Do not wrap prose."},{value:"preserve",description:"Wrap prose as-is."}]},bracketSameLine:{category:"Common",type:"boolean",default:!1,description:"Put > of opening tags on the last line instead of on a new line."},singleAttributePerLine:{category:"Common",type:"boolean",default:!1,description:"Enforce single attribute per line in HTML, Vue and JSX."}},ff={proseWrap:At $ 4.proseWrap,singleQuote:At $ 4.singleQuote},Si $ 2=ff,On $ 2={};Ln $ 3(On $ 2,{markdown:()=>km,mdx:()=>Bm,remark:()=>km});var Wc $ 2=Ue $ 3(Pi $ 2()),Kc $ 1=Ue $ 3(Wi $ 1()),Jc $ 1=Ue $ 3(Gs $ 1()),Xc $ 1=Ue $ 3(Ic $ 1()),vm=/^import \s /u,Em=/^export \s /u,Nc $ 1=String.raw ` [ a - z ] [ a - z0 - 9 ] * ( \ . [ a - z ] [ a - z0 - 9 ] * ) * | ` ,Rc $ 1=/<!---->|<!---?[^>-](?:-?[^-])*-->/u,Cm=/^ \{ \s * \/ \* (.*) \* \/ \s * \} /u,bm $ 1= `
` ,Uc $ 1=Ra=>vm.test(Ra),Sn $ 2=Ra=>Em.test(Ra),zc $ 1=(Ra,qa)=>{let Ja=qa.indexOf(bm $ 1),ed=qa.slice(0,Ja);if(Sn $ 2(ed)||Uc $ 1(ed))return Ra(ed)({type:Sn $ 2(ed)?"export":"import",value:ed})},Mc $ 1=(Ra,qa)=>{let Ja=Cm.exec(qa);if(Ja)return Ra(Ja[0])({type:"esComment",value:Ja[1].trim()})};zc $ 1.locator=Ra=>Sn $ 2(Ra)||Uc $ 1(Ra)?-1:1;Mc $ 1.locator=(Ra,qa)=>Ra.indexOf("{",qa);var Yc $ 1=function(){let{Parser:Ra}=this,{blockTokenizers:qa,blockMethods:Ja,inlineTokenizers:ed,inlineMethods:td}=Ra.prototype;qa.esSyntax=zc $ 1,ed.esComment=Mc $ 1,Ja.splice(Ja.indexOf("paragraph"),0,"esSyntax"),td.splice(td.indexOf("text"),0,"esComment")},ym=function(){let Ra=this.Parser.prototype;Ra.blockMethods=["frontMatter",...Ra.blockMethods],Ra.blockTokenizers.frontMatter=qa;function qa(Ja,ed){let td=ir $ 2(ed);if(td.frontMatter)return Ja(td.frontMatter.raw)(td.frontMatter)}qa.onlyAtStart=!0},Gc $ 1=ym;function Am(){return Ra=>ye $ 2(Ra,(qa,Ja,[ed])=>qa.type!=="html"||Rc $ 1.test(qa.value)||Or $ 2.has(ed.type)?qa:{...qa,type:"jsx"})}var Vc $ 1=Am,xm=function(){let Ra=this.Parser.prototype,qa=Ra.inlineMethods;qa.splice(qa.indexOf("text"),0,"liquid"),Ra.inlineTokenizers.liquid=Ja;function Ja(ed,td){let rd=td.match(/^( \{ %.*?% \} | \{ \{ .*? \} \} )/su);if(rd)return ed(rd[0])({type:"liquidNode",value:rd[0]})}Ja.locator=function(ed,td){return ed.indexOf("{",td)}},jc $ 2=xm,wm=function(){let Ra="wikiLink",qa=/^ \[ \[ (?<linkContents>.+?) \] \] /su,Ja=this.Parser.prototype,ed=Ja.inlineMethods;ed.splice(ed.indexOf("link"),0,Ra),Ja.inlineTokenizers.wikiLink=td;function td(rd,sd){let od=qa.exec(sd);if(od){let ld=od.groups.linkContents.trim();return rd(od[0])({type:Ra,value:ld})}}td.locator=function(rd,sd){return rd.indexOf("[",sd)}}, $ c $ 1=wm;function Qc $ 1({isMDX:Ra}){return qa=>{let Ja=(0,Xc $ 1.default)().use(Jc $ 1.default,{commonmark:!0,...Ra&&{blocks:[Nc $ 1]}}).use(Wc $ 2.default).use(Gc $ 1).use(Kc $ 1.default).use(Ra?Yc $ 1:Hc $ 2).use(jc $ 2).use(Ra?Vc $ 1:Hc $ 2).use( $ c $ 1);return Ja.run(Ja.parse(qa))}}function Hc $ 2(){}var Zc $ 1={astFormat:"mdast",hasPragma:Kn $ 2,locStart:Oe $ 3,locEnd:Pe $ 3},km={...Zc $ 1,parse:Qc $ 1({isMDX:!1})},Bm={...Zc $ 1,parse:Qc $ 1({isMDX:!0})},qm={mdast:Ti $ 2},fC=Pn $ 3;const prettierPluginMarkdown=Object.freeze(Object.defineProperty({__proto__:null,default:fC,languages:_i $ 2,options:Si $ 2,parsers:On $ 2,printers:qm},Symbol.toStringTag,{value:"Module"}));var $ s $ 2=Object.create,je $ 3=Object.defineProperty,Vs $ 1=Object.getOwnPropertyDescriptor,qs $ 2=Object.getOwnPropertyNames,zs $ 1=Object.getPrototypeOf,Ks $ 2=Object.prototype.hasOwnProperty,Hs $ 2=(Ra,qa)=>()=>(qa||Ra((qa={exports:{}}).exports,qa),qa.exports),Ws $ 1=(Ra,qa)=>{for(var Ja in qa)je $ 3(Ra,Ja,{get:qa[Ja],enumerable:!0})},Js $ 1=(Ra,qa,Ja,ed)=>{if(qa&&typeof qa=="object"||typeof qa=="function")for(let td of qs $ 2(qa))!Ks $ 2.call(Ra,td)&&td!==Ja&&je $ 3(Ra,td,{get:()=>qa[td],enumerable:!(ed=Vs $ 1(qa,td))||ed.enumerable});return Ra},vt $ 1=(Ra,qa,Ja)=>(Ja=Ra!=null? $ s $ 2(zs $ 1(Ra)):{},Js $ 1(je $ 3(Ja,"default",{value:Ra,enumerable:!0}),Ra)),At $ 3=Hs $ 2(Ra=>{Object.defineProperty(Ra,"__esModule",{value:!0});function qa(jd,kd){if(jd==null)return{};var Vd={},df=Object.keys(jd),Nf,Xf;for(Xf=0;Xf<df.length;Xf++)Nf=df[Xf],!(kd.indexOf(Nf)>=0)&&(Vd[Nf]=jd[Nf]);return Vd}var Ja=class{constructor(jd,kd,Vd){this.line=void 0,this.column=void 0,this.index=void 0,this.line=jd,this.column=kd,this.index=Vd}},ed=class{constructor(jd,kd){this.start=void 0,this.end=void 0,this.filename=void 0,this.identifierName=void 0,this.start=jd,this.end=kd}};function td(jd,kd){let{line:Vd,column:df,index:Nf}=jd;return new Ja(Vd,df+kd,Nf+kd)}var rd="BABEL_PARSER_SOURCETYPE_MODULE_REQUIRED",sd={ImportMetaOutsideModule:{message: ` import . meta may appear only with 'sourceType: "module"' ` ,code:rd},ImportOutsideModule:{message: ` 'import' and 'export' may appear only with 'sourceType: "module"' ` ,code:rd}},od={ArrayPattern:"array destructuring pattern",AssignmentExpression:"assignment expression",AssignmentPattern:"assignment expression",ArrowFunctionExpression:"arrow function expression",ConditionalExpression:"conditional expression",CatchClause:"catch clause",ForOfStatement:"for-of statement",ForInStatement:"for-
- Did you mean \ ` export { ' ${ jd } ' as ' ${ kd } ' } from 'some-module' \` ? ` , ExportDefaultFromAsIdentifier : "'from' is not allowed as an identifier after 'export default'." , ForInOfLoopInitializer : ( { type : jd } ) => ` ' ${ jd === "ForInStatement" ? "for-in" : "for-of" } ' loop variable declaration may not have an initializer. ` , ForInUsing : "For-in loop may not start with 'using' declaration." , ForOfAsync : "The left-hand side of a for-of loop may not be 'async'." , ForOfLet : "The left-hand side of a for-of loop may not start with 'let'." , GeneratorInSingleStatementContext : "Generators can only be declared at the top level or inside a block." , IllegalBreakContinue : ( { type : jd } ) => ` Unsyntactic ${ jd === "BreakStatement" ? "break" : "continue" } . ` , IllegalLanguageModeDirective : "Illegal 'use strict' directive in function with non-simple parameter list." , IllegalReturn : "'return' outside of function." , ImportAttributesUseAssert : "The `assert` keyword in import attributes is deprecated and it has been replaced by the `with` keyword. You can enable the `deprecatedAssertSyntax: true` option in the import attributes plugin to suppress this error." , ImportBindingIsString : ( { importName : jd } ) => ` A string literal cannot be used as an imported binding.
- Did you mean \ ` import { " ${ jd } " as foo } \` ? ` , ImportCallArgumentTrailingComma : "Trailing comma is disallowed inside import(...) arguments." , ImportCallArity : ( { maxArgumentCount : jd } ) => ` \` import() \` requires exactly ${ jd === 1 ? "one argument" : "one or two arguments" } . ` , ImportCallNotNewExpression : "Cannot use new with import(...)." , ImportCallSpreadArgument : "`...` is not allowed in `import()`." , ImportJSONBindingNotDefault : "A JSON module can only be imported with `default`." , ImportReflectionHasAssertion : "`import module x` cannot have assertions." , ImportReflectionNotBinding : 'Only `import module x from "./module"` is valid.' , IncompatibleRegExpUVFlags : "The 'u' and 'v' regular expression flags cannot be enabled at the same time." , InvalidBigIntLiteral : "Invalid BigIntLiteral." , InvalidCodePoint : "Code point out of bounds." , InvalidCoverInitializedName : "Invalid shorthand property initializer." , InvalidDecimal : "Invalid decimal." , InvalidDigit : ( { radix : jd } ) => ` Expected number in radix ${ jd } . ` , InvalidEscapeSequence : "Bad character escape sequence." , InvalidEscapeSequenceTemplate : "Invalid escape sequence in template." , InvalidEscapedReservedWord : ( { reservedWord : jd } ) => ` Escape sequence in keyword ${ jd } . ` , InvalidIdentifier : ( { identifierName : jd } ) => ` Invalid identifier ${ jd } . ` , InvalidLhs : ( { ancestor : jd } ) => ` Invalid left-hand side in ${ ld ( jd ) } . ` , InvalidLhsBinding : ( { ancestor : jd } ) => ` Binding invalid left-hand side in ${ ld ( jd ) } . ` , InvalidLhsOptionalChaining : ( { ancestor : jd } ) => ` Invalid optional chaining in the left-hand side of ${ ld ( jd ) } . ` , InvalidNumber : "Invalid number." , InvalidOrMissingExponent : "Floating-point numbers require a valid exponent after the 'e'." , InvalidOrUnexpectedToken : ( { unexpected : jd } ) => ` Unexpected character ' ${ jd } '. ` , InvalidParenthesizedAssignment : "Invalid parenthesized assignment pattern." , InvalidPrivateFieldResolution : ( { identifierName : jd } ) => ` Private name # ${ jd } is not defined. ` , InvalidPropertyBindingPattern : "Binding member expression." , InvalidRecordProperty : "Only properties and spread elements are allowed in record definitions." , InvalidRestAssignmentPattern : "Invalid rest operator's argument." , LabelRedeclaration : ( { labelName : jd } ) => ` Label ' ${ jd } ' is already declared. ` , LetInLexicalBinding : "'let' is disallowed as a lexically bound name." , LineTerminatorBeforeArrow : "No line break is allowed before '=>'." , MalformedRegExpFlags : "Invalid regular expression flag." , MissingClassName : "A class name is required." , MissingEqInAssignment : "Only '=' operator can be used for specifying default value." , MissingSemicolon : "Missing semicolon." , MissingPlugin : ( { missingPlugin : jd } ) => ` This experimental syntax requires enabling the parser plugin: ${ jd . map ( kd => JSON . stringify ( kd ) ) . join ( ", " ) } . ` , MissingOneOfPlugins : ( { missingPlugin : jd } ) => ` This experimental syntax requires enabling one of the following parser plugin(s): ${ jd . map ( kd => JSON . stringify ( kd ) ) . join ( ", " ) } . ` , MissingUnicodeEscape : "Expecting Unicode escape sequence \\uXXXX." , MixingCoalesceWithLogical : "Nullish coalescing operator(??) requires parens when mixing with logical operators." , ModuleAttributeDifferentFromType : "The only accepted module attribute is `type`." , ModuleAttributeInvalidValue : "Only string literals are allowed as module attribute values." , ModuleAttributesWithDuplicateKeys : ( { key : jd } ) => ` Duplicate key " ${ jd } " is not allowed in module attributes. ` , ModuleExportNameHasLoneSurrogate : ( { surrogateCharCode : jd } ) => ` An export name cannot include a lone surrogate, found ' \\ u ${ jd . toString ( 16 ) } '. ` , ModuleExportUndefined : ( { localName : jd } ) => ` Export ' ${ jd } ' is not defined. ` , MultipleDefaultsInSwitch : "Multiple default clauses." , NewlineAfterThrow : "Illegal newline after throw." , NoCatchOrFinally : "Missing catch or finally clause." , NumberIdentifier : "Identifier directly after number." , NumericSeparatorInEscapeSequence : "Numeric separators are not allowed inside unicode escape sequences or hex escape sequences." , ObsoleteAwaitStar : "'await*' has been removed from the async functions proposal. Use Promise.all() instead." , OptionalChainingNoNew : "Constructors in/after an Optional Chain are not allowed." , OptionalChainingNoTemplate : " Tagged Template Literals ar
` ,++Vd,r_===13&&kd.charCodeAt(Vd)===10&&++Vd,++Nf,Wm=df=Vd):Xf.unterminated(gh,Rh,Vh):++Vd}return{pos:Vd,str:jh,firstInvalidLoc:Sm,lineStart:df,curLine:Nf,containsInvalid:!!Sm}}function m_(jd,kd,Vd,df){return jd==="template"?kd===96||kd===36&&Vd.charCodeAt(df+1)===123:kd===(jd==="double"?34:39)}function f_(jd,kd,Vd,df,Nf,Xf){let gh=!Nf;kd++;let Rh=jh=>({pos:kd,ch:jh,lineStart:Vd,curLine:df}),Vh=jd.charCodeAt(kd++);switch(Vh){case 110:return Rh( `
` );case 114:return Rh(" \r ");case 120:{let jh;return{code:jh,pos:kd}=a_(jd,kd,Vd,df,2,!1,gh,Xf),Rh(jh===null?null:String.fromCharCode(jh))}case 117:{let jh;return{code:jh,pos:kd}=v_(jd,kd,Vd,df,gh,Xf),Rh(jh===null?null:String.fromCodePoint(jh))}case 116:return Rh(" ");case 98:return Rh(" \b ");case 118:return Rh(" \v ");case 102:return Rh(" \f ");case 13:jd.charCodeAt(kd)===10&&++kd;case 10:Vd=kd,++df;case 8232:case 8233:return Rh("");case 56:case 57:if(Nf)return Rh(null);Xf.strictNumericEscape(kd-1,Vd,df);default:if(Vh>=48&&Vh<=55){let jh=kd-1,Sm=/^[0-7]+/.exec(jd.slice(jh,kd+2))[0],Wm=parseInt(Sm,8);Wm>255&&(Sm=Sm.slice(0,-1),Wm=parseInt(Sm,8)),kd+=Sm.length-1;let Zm=jd.charCodeAt(kd);if(Sm!=="0"||Zm===56||Zm===57){if(Nf)return Rh(null);Xf.strictNumericEscape(jh,Vd,df)}return Rh(String.fromCharCode(Wm))}return Rh(String.fromCharCode(Vh))}}function a_(jd,kd,Vd,df,Nf,Xf,gh,Rh){let Vh=kd,jh;return{n:jh,pos:kd}=Dm(jd,kd,Vd,df,16,Nf,Xf,!1,Rh,!gh),jh===null&&(gh?Rh.invalidEscapeSequence(Vh,Vd,df):kd=Vh-1),{code:jh,pos:kd}}function Dm(jd,kd,Vd,df,Nf,Xf,gh,Rh,Vh,jh){let Sm=kd,Wm=Nf===16?_m.hex:_m.decBinOct,Zm=Nf===16?Ff.hex:Nf===10?Ff.dec:Nf===8?Ff.oct:Ff.bin,r_=!1,x_=0;for(let p1=0,P_=Xf??1/0;p1<P_;++p1){let W_=jd.charCodeAt(kd),O1;if(W_===95&&Rh!=="bail"){let W0=jd.charCodeAt(kd-1),Tb=jd.charCodeAt(kd+1);if(Rh){if(Number.isNaN(Tb)||!Zm(Tb)||Wm.has(W0)||Wm.has(Tb)){if(jh)return{n:null,pos:kd};Vh.unexpectedNumericSeparator(kd,Vd,df)}}else{if(jh)return{n:null,pos:kd};Vh.numericSeparatorInEscapeSequence(kd,Vd,df)}++kd;continue}if(W_>=97?O1=W_-97+10:W_>=65?O1=W_-65+10:cm(W_)?O1=W_-48:O1=1/0,O1>=Nf){if(O1<=9&&jh)return{n:null,pos:kd};if(O1<=9&&Vh.invalidDigit(kd,Vd,df,Nf))O1=0;else if(gh)O1=0,r_=!0;else break}++kd,x_=x_*Nf+O1}return kd===Sm||Xf!=null&&kd-Sm!==Xf||r_?{n:null,pos:kd}:{n:x_,pos:kd}}function v_(jd,kd,Vd,df,Nf,Xf){let gh=jd.charCodeAt(kd),Rh;if(gh===123){if(++kd,{code:Rh,pos:kd}=a_(jd,kd,Vd,df,jd.indexOf("}",kd)-kd,!0,Nf,Xf),++kd,Rh!==null&&Rh>1114111)if(Nf)Xf.invalidCodePoint(kd,Vd,df);else return{code:null,pos:kd}}else({code:Rh,pos:kd}=a_(jd,kd,Vd,df,4,!1,Nf,Xf));return{code:Rh,pos:kd}}function u_(jd,kd,Vd){return new Ja(Vd,jd-kd,jd)}var o_=new Set([103,109,115,105,121,117,100,118]),oh=class{constructor(jd){this.type=jd.type,this.value=jd.value,this.start=jd.start,this.end=jd.end,this.loc=new ed(jd.startLoc,jd.endLoc)}},Oh=class extends bh{constructor(jd,kd){super(),this.isLookahead=void 0,this.tokens=[],this.errorHandlers_readInt={invalidDigit:(Vd,df,Nf,Xf)=>this.options.errorRecovery?(this.raise(Nd.InvalidDigit,u_(Vd,df,Nf),{radix:Xf}),!0):!1,numericSeparatorInEscapeSequence:this.errorBuilder(Nd.NumericSeparatorInEscapeSequence),unexpectedNumericSeparator:this.errorBuilder(Nd.UnexpectedNumericSeparator)},this.errorHandlers_readCodePoint=Object.assign({},this.errorHandlers_readInt,{invalidEscapeSequence:this.errorBuilder(Nd.InvalidEscapeSequence),invalidCodePoint:this.errorBuilder(Nd.InvalidCodePoint)}),this.errorHandlers_readStringContents_string=Object.assign({},this.errorHandlers_readCodePoint,{strictNumericEscape:(Vd,df,Nf)=>{this.recordStrictModeErrors(Nd.StrictNumericEscape,u_(Vd,df,Nf))},unterminated:(Vd,df,Nf)=>{throw this.raise(Nd.UnterminatedString,u_(Vd-1,df,Nf))}}),this.errorHandlers_readStringContents_template=Object.assign({},this.errorHandlers_readCodePoint,{strictNumericEscape:this.errorBuilder(Nd.StrictNumericEscape),unterminated:(Vd,df,Nf)=>{throw this.raise(Nd.UnterminatedTemplate,u_(Vd,df,Nf))}}),this.state=new um,this.state.init(jd),this.input=kd,this.length=kd.length,this.comments=[],this.isLookahead=!1}pushToken(jd){this.tokens.length=this.state.tokensLength,this.tokens.push(jd),++this.state.tokensLength}next(){this.checkKeywordEscapes(),this.options.tokens&&this.pushToken(new oh(this.state)),this.state.lastTokEndLoc=this.state.endLoc,this.state.lastTokStartLoc=this.state.startLoc,this.nextToken()}eat(jd){return this.match(jd)?(this.next(),!0):!1}match(jd){return this.state.type===jd}createLookaheadState(jd){return{pos:jd.pos,value:null,type:jd.type,start:jd.start,end:jd.end,context:[this.curContext
2024-08-30 15:19:18 +08:00
` : ` \ r
2024-09-08 17:22:36 +08:00
` ):df=String.fromCharCode(Vd),++this.state.curLine,this.state.lineStart=this.state.pos,df}jsxReadString(kd){let Vd="",df=++this.state.pos;for(;;){if(this.state.pos>=this.length)throw this.raise(Nd.UnterminatedString,this.state.startLoc);let Nf=this.input.charCodeAt(this.state.pos);if(Nf===kd)break;Nf===38?(Vd+=this.input.slice(df,this.state.pos),Vd+=this.jsxReadEntity(),df=this.state.pos):Lh(Nf)?(Vd+=this.input.slice(df,this.state.pos),Vd+=this.jsxReadNewLine(!1),df=this.state.pos):++this.state.pos}Vd+=this.input.slice(df,this.state.pos++),this.finishToken(133,Vd)}jsxReadEntity(){let kd=++this.state.pos;if(this.codePointAtPos(this.state.pos)===35){++this.state.pos;let Vd=10;this.codePointAtPos(this.state.pos)===120&&(Vd=16,++this.state.pos);let df=this.readInt(Vd,void 0,!1,"bail");if(df!==null&&this.codePointAtPos(this.state.pos)===59)return++this.state.pos,String.fromCodePoint(df)}else{let Vd=0,df=!1;for(;Vd++<10&&this.state.pos<this.length&&!(df=this.codePointAtPos(this.state.pos)===59);)++this.state.pos;if(df){this.input.slice(kd,this.state.pos);let Nf;++this.state.pos}}return this.state.pos=kd,"&"}jsxReadWord(){let kd,Vd=this.state.pos;do kd=this.input.charCodeAt(++this.state.pos);while(Xh(kd)||kd===45);this.finishToken(140,this.input.slice(Vd,this.state.pos))}jsxParseIdentifier(){let kd=this.startNode();return this.match(140)?kd.name=this.state.value:Af(this.state.type)?kd.name=Nh(this.state.type):this.unexpected(),this.next(),this.finishNode(kd,"JSXIdentifier")}jsxParseNamespacedName(){let kd=this.state.startLoc,Vd=this.jsxParseIdentifier();if(!this.eat(14))return Vd;let df=this.startNodeAt(kd);return df.namespace=Vd,df.name=this.jsxParseIdentifier(),this.finishNode(df,"JSXNamespacedName")}jsxParseElementName(){let kd=this.state.startLoc,Vd=this.jsxParseNamespacedName();if(Vd.type==="JSXNamespacedName")return Vd;for(;this.eat(16);){let df=this.startNodeAt(kd);df.object=Vd,df.property=this.jsxParseIdentifier(),Vd=this.finishNode(df,"JSXMemberExpression")}return Vd}jsxParseAttributeValue(){let kd;switch(this.state.type){case 5:return kd=this.startNode(),this.setContext(Yd.brace),this.next(),kd=this.jsxParseExpressionContainer(kd,Yd.j_oTag),kd.expression.type==="JSXEmptyExpression"&&this.raise(d1.AttributeIsEmpty,kd),kd;case 142:case 133:return this.parseExprAtom();default:throw this.raise(d1.UnsupportedJsxValue,this.state.startLoc)}}jsxParseEmptyExpression(){let kd=this.startNodeAt(this.state.lastTokEndLoc);return this.finishNodeAt(kd,"JSXEmptyExpression",this.state.startLoc)}jsxParseSpreadChild(kd){return this.next(),kd.expression=this.parseExpression(),this.setContext(Yd.j_expr),this.state.canStartJSXElement=!0,this.expect(8),this.finishNode(kd,"JSXSpreadChild")}jsxParseExpressionContainer(kd,Vd){if(this.match(8))kd.expression=this.jsxParseEmptyExpression();else{let df=this.parseExpression();kd.expression=df}return this.setContext(Vd),this.state.canStartJSXElement=!0,this.expect(8),this.finishNode(kd,"JSXExpressionContainer")}jsxParseAttribute(){let kd=this.startNode();return this.match(5)?(this.setContext(Yd.brace),this.next(),this.expect(21),kd.argument=this.parseMaybeAssignAllowIn(),this.setContext(Yd.j_oTag),this.state.canStartJSXElement=!0,this.expect(8),this.finishNode(kd,"JSXSpreadAttribute")):(kd.name=this.jsxParseNamespacedName(),kd.value=this.eat(29)?this.jsxParseAttributeValue():null,this.finishNode(kd,"JSXAttribute"))}jsxParseOpeningElementAt(kd){let Vd=this.startNodeAt(kd);return this.eat(143)?this.finishNode(Vd,"JSXOpeningFragment"):(Vd.name=this.jsxParseElementName(),this.jsxParseOpeningElementAfterName(Vd))}jsxParseOpeningElementAfterName(kd){let Vd=[];for(;!this.match(56)&&!this.match(143);)Vd.push(this.jsxParseAttribute());return kd.attributes=Vd,kd.selfClosing=this.eat(56),this.expect(143),this.finishNode(kd,"JSXOpeningElement")}jsxParseClosingElementAt(kd){let Vd=this.startNodeAt(kd);return this.eat(143)?this.finishNode(Vd,"JSXClosingFragment"):(Vd.name=this.jsxParseElementName(),this.expect(143),this.finishNode(Vd,"JSXClosingElement"))}jsxParseElementAt(kd){let Vd=this.startNodeAt(kd),df=[],Nf
` ),cooked:Nf===null?null:Nf.slice(1,Vh)},gh.tail=Rh,this.next();let Sm=this.finishNode(gh,"TemplateElement");return this.resetEndLocation(Sm,td(this.state.lastTokEndLoc,Vh)),Sm}parseTemplate(jd){let kd=this.startNode(),Vd=this.parseTemplateElement(jd),df=[Vd],Nf=[];for(;!Vd.tail;)Nf.push(this.parseTemplateSubstitution()),this.readTemplateContinuation(),df.push(Vd=this.parseTemplateElement(jd));return kd.expressions=Nf,kd.quasis=df,this.finishNode(kd,"TemplateLiteral")}parseTemplateSubstitution(){return this.parseExpression()}parseObjectLike(jd,kd,Vd,df){Vd&&this.expectPlugin("recordAndTuple");let Nf=this.state.inFSharpPipelineDirectBody;this.state.inFSharpPipelineDirectBody=!1;let Xf=Object.create(null),gh=!0,Rh=this.startNode();for(Rh.properties=[],this.next();!this.match(jd);){if(gh)gh=!1;else if(this.expect(12),this.match(jd)){this.addTrailingCommaExtraToNode(Rh);break}let jh;kd?jh=this.parseBindingProperty():(jh=this.parsePropertyDefinition(df),this.checkProto(jh,Vd,Xf,df)),Vd&&!this.isObjectProperty(jh)&&jh.type!=="SpreadElement"&&this.raise(Nd.InvalidRecordProperty,jh),jh.shorthand&&this.addExtra(jh,"shorthand",!0),Rh.properties.push(jh)}this.next(),this.state.inFSharpPipelineDirectBody=Nf;let Vh="ObjectExpression";return kd?Vh="ObjectPattern":Vd&&(Vh="RecordExpression"),this.finishNode(Rh,Vh)}addTrailingCommaExtraToNode(jd){this.addExtra(jd,"trailingComma",this.state.lastTokStartLoc.index),this.addExtra(jd,"trailingCommaLoc",this.state.lastTokStartLoc,!1)}maybeAsyncOrAccessorProp(jd){return!jd.computed&&jd.key.type==="Identifier"&&(this.isLiteralPropertyName()||this.match(0)||this.match(55))}parsePropertyDefinition(jd){let kd=[];if(this.match(26))for(this.hasPlugin("decorators")&&this.raise(Nd.UnsupportedPropertyDecorator,this.state.startLoc);this.match(26);)kd.push(this.parseDecorator());let Vd=this.startNode(),df=!1,Nf=!1,Xf;if(this.match(21))return kd.length&&this.unexpected(),this.parseSpread();kd.length&&(Vd.decorators=kd,kd=[]),Vd.method=!1,jd&&(Xf=this.state.startLoc);let gh=this.eat(55);this.parsePropertyNamePrefixOperator(Vd);let Rh=this.state.containsEsc;if(this.parsePropertyName(Vd,jd),!gh&&!Rh&&this.maybeAsyncOrAccessorProp(Vd)){let{key:Vh}=Vd,jh=Vh.name;jh==="async"&&!this.hasPrecedingLineBreak()&&(df=!0,this.resetPreviousNodeTrailingComments(Vh),gh=this.eat(55),this.parsePropertyName(Vd)),(jh==="get"||jh==="set")&&(Nf=!0,this.resetPreviousNodeTrailingComments(Vh),Vd.kind=jh,this.match(55)&&(gh=!0,this.raise(Nd.AccessorIsGenerator,this.state.curPosition(),{kind:jh}),this.next()),this.parsePropertyName(Vd))}return this.parseObjPropValue(Vd,Xf,gh,df,!1,Nf,jd)}getGetterSetterExpectedParamCount(jd){return jd.kind==="get"?0:1}getObjectOrClassMethodParams(jd){return jd.params}checkGetterSetterParams(jd){var kd;let Vd=this.getGetterSetterExpectedParamCount(jd),df=this.getObjectOrClassMethodParams(jd);df.length!==Vd&&this.raise(jd.kind==="get"?Nd.BadGetterArity:Nd.BadSetterArity,jd),jd.kind==="set"&&((kd=df[df.length-1])==null?void 0:kd.type)==="RestElement"&&this.raise(Nd.BadSetterRestParameter,jd)}parseObjectMethod(jd,kd,Vd,df,Nf){if(Nf){let Xf=this.parseMethod(jd,kd,!1,!1,!1,"ObjectMethod");return this.checkGetterSetterParams(Xf),Xf}if(Vd||kd||this.match(10))return df&&this.unexpected(),jd.kind="method",jd.method=!0,this.parseMethod(jd,kd,Vd,!1,!1,"ObjectMethod")}parseObjectProperty(jd,kd,Vd,df){if(jd.shorthand=!1,this.eat(14))return jd.value=Vd?this.parseMaybeDefault(this.state.startLoc):this.parseMaybeAssignAllowIn(df),this.finishNode(jd,"ObjectProperty");if(!jd.computed&&jd.key.type==="Identifier"){if(this.checkReservedWord(jd.key.name,jd.key.loc.start,!0,!1),Vd)jd.value=this.parseMaybeDefault(kd,E1(jd.key));else if(this.match(29)){let Nf=this.state.startLoc;df!=null?df.shorthandAssignLoc===null&&(df.shorthandAssignLoc=Nf):this.raise(Nd.InvalidCoverInitializedName,Nf),jd.value=this.parseMaybeDefault(kd,E1(jd.key))}else jd.value=E1(jd.key);return jd.shorthand=!0,this.finishNode(jd,"ObjectProperty")}}parseObjPropValue(jd,kd,Vd,df,Nf,Xf,gh){let Rh=this.parseObjectMethod(jd,Vd,df,Nf,Xf)||this.parseObjectPr
2024-08-30 15:19:18 +08:00
` )return qa-2;if(td=== `
` ||td===" \r "||td===" \u 2028"||td===" \u 2029")return qa-1}else{if(td===" \r "&&Ra.charAt(qa+1)=== `
` )return qa+2;if(td=== `
2024-09-08 17:22:36 +08:00
` ||td===" \r "||td===" \u 2028"||td===" \u 2029")return qa+1}return qa}var us $ 2=mr $ 1;function yr $ 1(Ra,qa){return qa===!1?!1:Ra.charAt(qa)==="/"&&Ra.charAt(qa+1)==="/"?cs $ 2(Ra,qa):qa}var fs $ 2=yr $ 1;function xr $ 1(Ra,qa){let Ja=null,ed=qa;for(;ed!==Ja;)Ja=ed,ed=ls $ 2(Ra,ed),ed=ps $ 1(Ra,ed),ed=fs $ 2(Ra,ed),ed=us $ 2(Ra,ed);return ed}var ds $ 1=xr $ 1;function Pr $ 1(Ra){let qa=[];for(let Ja of Ra)try{return Ja()}catch(ed){qa.push(ed)}throw Object.assign(new Error("All combinations failed"),{errors:qa})}var ms $ 2=Pr $ 1;function gr $ 1(Ra){if(!Ra.startsWith("#!"))return"";let qa=Ra.indexOf( `
` );return qa===-1?Ra:Ra.slice(0,qa)}var Oe $ 2=gr $ 1,Tr $ 1=(Ra,qa,Ja)=>{if(!(Ra&&qa==null))return Array.isArray(qa)||typeof qa=="string"?qa[Ja<0?qa.length+Ja:Ja]:qa.at(Ja)},St $ 2=Tr $ 1;function br $ 1(Ra){return Array.isArray(Ra)&&Ra.length>0}var Pe $ 2=br $ 1;function D $ 1(Ra){var qa,Ja,ed;let td=((qa=Ra.range)==null?void 0:qa[0])??Ra.start,rd=(ed=((Ja=Ra.declaration)==null?void 0:Ja.decorators)??Ra.decorators)==null?void 0:ed[0];return rd?Math.min(D $ 1(rd),td):td}function B(Ra){var qa;return((qa=Ra.range)==null?void 0:qa[1])??Ra.end}function Ar $ 1(Ra){let qa=new Set(Ra);return Ja=>qa.has(Ja==null?void 0:Ja.type)}var ys $ 2=Ar $ 1,Sr $ 1=ys $ 2(["Block","CommentBlock","MultiLine"]),ge $ 2=Sr $ 1;function wr $ 1(Ra){let qa= ` * $ { Ra . value } * ` .split( `
` );return qa.length>1&&qa.every(Ja=>Ja.trimStart()[0]==="*")}var wt $ 1=wr $ 1;function Cr(Ra){return ge $ 2(Ra)&&Ra.value[0]==="*"&&/@(?:type|satisfies) \b /u.test(Ra.value)}var xs $ 1=Cr,Te $ 2=null;function be $ 3(Ra){if(Te $ 2!==null&&typeof Te $ 2.property){let qa=Te $ 2;return Te $ 2=be $ 3.prototype=null,qa}return Te $ 2=be $ 3.prototype=Ra??Object.create(null),new be $ 3}var Er $ 1=10;for(let Ra=0;Ra<=Er $ 1;Ra++)be $ 3();function Ct $ 3(Ra){return be $ 3(Ra)}function Ir $ 1(Ra,qa="type"){Ct $ 3(Ra);function Ja(ed){let td=ed[qa],rd=Ra[td];if(!Array.isArray(rd))throw Object.assign(new Error( ` Missing visitor keys for '${td}' . ` ),{node:ed});return rd}return Ja}var Ps $ 2=Ir $ 1,gs $ 2={ArrayExpression:["elements"],AssignmentExpression:["left","right"],BinaryExpression:["left","right"],InterpreterDirective:[],Directive:["value"],DirectiveLiteral:[],BlockStatement:["directives","body"],BreakStatement:["label"],CallExpression:["callee","arguments","typeParameters","typeArguments"],CatchClause:["param","body"],ConditionalExpression:["test","consequent","alternate"],ContinueStatement:["label"],DebuggerStatement:[],DoWhileStatement:["test","body"],EmptyStatement:[],ExpressionStatement:["expression"],File:["program"],ForInStatement:["left","right","body"],ForStatement:["init","test","update","body"],FunctionDeclaration:["id","params","body","returnType","typeParameters","predicate"],FunctionExpression:["id","params","body","returnType","typeParameters"],Identifier:["typeAnnotation","decorators"],IfStatement:["test","consequent","alternate"],LabeledStatement:["label","body"],StringLiteral:[],NumericLiteral:[],NullLiteral:[],BooleanLiteral:[],RegExpLiteral:[],LogicalExpression:["left","right"],MemberExpression:["object","property"],NewExpression:["callee","arguments","typeParameters","typeArguments"],Program:["directives","body"],ObjectExpression:["properties"],ObjectMethod:["key","params","body","decorators","returnType","typeParameters"],ObjectProperty:["key","value","decorators"],RestElement:["argument","typeAnnotation","decorators"],ReturnStatement:["argument"],SequenceExpression:["expressions"],ParenthesizedExpression:["expression"],SwitchCase:["test","consequent"],SwitchStatement:["discriminant","cases"],ThisExpression:[],ThrowStatement:["argument"],TryStatement:["block","handler","finalizer"],UnaryExpression:["argument"],UpdateExpression:["argument"],VariableDeclaration:["declarations"],VariableDeclarator:["id","init"],WhileStatement:["test","body"],WithStatement:["object","body"],AssignmentPattern:["left","right","decorators","typeAnnotation"],ArrayPattern:["elements","typeAnnotation","decorators"],ArrowFunctionExpression:["params","body","returnType","typeParameters","predicate"],ClassBody:["body"],ClassExpression:["id","body","superClass","mixins","typeParameters","superTypeParameters","implements","decorators","superTypeArguments"],ClassDeclaration:["id","body","superClass","mixins","typeParameters","superTypeParameters","implements","decorators","superTypeArguments"],ExportAllDeclaration:["source","attributes","exported"],ExportDefaultDeclaration:["declaration"],ExportNamedDeclaration:["declaration","specifiers","source","attributes"],ExportSpecifier:["local","exported"],ForOfStatement:["left","right","body"],ImportDeclaration:["specifiers","source","attributes"],ImportDefaultSpecifier:["local"],ImportNamespaceSpecifier:["local"],ImportSpecifier:["local","imported"],ImportExpression:["source","options","attributes"],MetaProperty:["meta","property"],ClassMethod:["key","params","body","decorators","returnType","typeParameters"],ObjectPattern:["properties","typeAnnotation","decorators"],SpreadElement:["argument"],Super:[],TaggedTemplateExpression:["tag","quasi","typeParameters","typeArguments"],TemplateElement:[],TemplateLiteral:["quasis","expressions"],YieldExpression:["argument"],AwaitExpression:["argument"],Import:[],BigIntLiteral:[],ExportNamespaceSpecifier:["exported"],OptionalMemberExpression:["object","property"],OptionalCallExpression:["callee","arguments","typeParameters","typeArguments"],ClassProperty:["key","value","typeAnnotation","decorators","variance
` ;Ra=ie $ 2(!1,Ra.replace(Or $ 1,"").replace(Mr $ 2,""),Ur $ 2," $ 1");let Ja="";for(;Ja!==Ra;)Ja=Ra,Ra=ie $ 2(!1,Ra,Rr $ 1, ` $ { qa } $1 $2$ { qa } ` );Ra=Ra.replace(Ss $ 1,"").trimEnd();let ed=Object.create(null),td=ie $ 2(!1,Ra,ws $ 2,"").replace(Ss $ 1,"").trimEnd(),rd;for(;rd=ws $ 2.exec(Ra);){let sd=ie $ 2(!1,rd[2],Br $ 2,"");if(typeof ed[rd[1]]=="string"||Array.isArray(ed[rd[1]])){let od=ed[rd[1]];ed[rd[1]]=[..._r $ 1,...Array.isArray(od)?od:[od],sd]}else ed[rd[1]]=sd}return{comments:td,pragmas:ed}}function jr $ 2(Ra){let qa=Oe $ 2(Ra);qa&&(Ra=Ra.slice(qa.length+1));let Ja=Cs $ 1(Ra),{pragmas:ed,comments:td}=Es $ 2(Ja);return{shebang:qa,text:Ra,pragmas:ed,comments:td}}function Is $ 2(Ra){let{pragmas:qa}=jr $ 2(Ra);return Object.prototype.hasOwnProperty.call(qa,"prettier")||Object.prototype.hasOwnProperty.call(qa,"format")}function $ r $ 2(Ra){return Ra=typeof Ra=="function"?{parse:Ra}:Ra,{astFormat:"estree",hasPragma:Is $ 2,locStart:D $ 1,locEnd:B,...Ra}}var G $ 1= $ r $ 2;function Vr $ 2(Ra){let{filepath:qa}=Ra;if(qa){if(qa=qa.toLowerCase(),qa.endsWith(".cjs"))return"script";if(qa.endsWith(".mjs"))return"module"}}var Ns $ 1=Vr $ 2;function qr $ 1(Ra,qa){let{type:Ja="JsExpressionRoot",rootMarker:ed,text:td}=qa,{tokens:rd,comments:sd}=Ra;return delete Ra.tokens,delete Ra.comments,{tokens:rd,comments:sd,type:Ja,node:Ra,range:[0,td.length],rootMarker:ed}}var Ue $ 2=qr $ 1,re $ 2=Ra=>G $ 1(Jr $ 2(Ra)),zr $ 2={sourceType:"module",allowImportExportEverywhere:!0,allowReturnOutsideFunction:!0,allowNewTargetOutsideFunction:!0,allowSuperOutsideMethod:!0,allowUndeclaredExports:!0,errorRecovery:!0,createParenthesizedExpressions:!0,createImportExpressions:!0,plugins:["doExpressions","exportDefaultFrom","functionBind","functionSent","throwExpressions","partialApplication","decorators","decimal","moduleBlocks","asyncDoExpressions","destructuringPrivate","decoratorAutoAccessors","importReflection","explicitResourceManagement",["importAttributes",{deprecatedAssertSyntax:!0}],"sourcePhaseImports","deferredImportEvaluation",["optionalChainingAssign",{version:"2023-07"}],"recordAndTuple"],tokens:!0,ranges:!0},ks $ 1="v8intrinsic",vs $ 2=[["pipelineOperator",{proposal:"hack",topicToken:"%"}],["pipelineOperator",{proposal:"minimal"}],["pipelineOperator",{proposal:"fsharp"}]],V $ 2=(Ra,qa=zr $ 2)=>({...qa,plugins:[...qa.plugins,...Ra]}),Kr $ 2=/@(?:no)?flow \b /u;function Hr $ 2(Ra,qa){var Ja;if((Ja=qa.filepath)!=null&&Ja.endsWith(".js.flow"))return!0;let ed=Oe $ 2(Ra);ed&&(Ra=Ra.slice(ed.length));let td=ds $ 1(Ra,0);return td!==!1&&(Ra=Ra.slice(0,td)),Kr $ 2.test(Ra)}function Wr $ 2(Ra,qa,Ja){let ed=Ra(qa,Ja),td=ed.errors.find(rd=>!Xr $ 2.has(rd.reasonCode));if(td)throw td;return ed}function Jr $ 2({isExpression:Ra=!1,optionsCombinations:qa}){return(Ja,ed={})=>{if((ed.parser==="babel"||ed.parser==="__babel_estree")&&Hr $ 2(Ja,ed))return ed.parser="babel-flow",Bs $ 1.parse(Ja,ed);let td=qa;(ed.__babelSourceType??Ns $ 1(ed))==="script"&&(td=td.map(ld=>({...ld,sourceType:"script"})));let rd=/%[A-Z]/u.test(Ja);Ja.includes("|>")?td=(rd?[...vs $ 2,ks $ 1]:vs $ 2).flatMap(ld=>td.map(cd=>V $ 2([ld],cd))):rd&&(td=td.map(ld=>V $ 2([ks $ 1],ld)));let sd=Ra?_e $ 2.parseExpression:_e $ 2.parse,od;try{od=ms $ 2(td.map(ld=>()=>Wr $ 2(sd,Ja,ld)))}catch({errors:[ld]}){throw Re $ 3(ld)}return Ra&&(od=Ue $ 2(od,{text:Ja,rootMarker:ed.rootMarker})),As $ 2(od,{parser:"babel",text:Ja})}}var Xr $ 2=new Set(["StrictNumericEscape","StrictWith","StrictOctalLiteral","StrictDelete","StrictEvalArguments","StrictEvalArgumentsBinding","StrictFunction","ForInOfLoopInitializer","EmptyTypeArguments","EmptyTypeParameters","ConstructorHasTypeParameters","UnsupportedParameterPropertyKind","DecoratorExportClass","ParamDupe","InvalidDecimal","RestTrailingComma","UnsupportedParameterDecorator","UnterminatedJsxContent","UnexpectedReservedWord","ModuleAttributesWithDuplicateKeys","LineTerminatorBeforeArrow","InvalidEscapeSequenceTemplate","NonAbstractClassHasAbstractMethod","OptionalTypeBeforeRequired","PatternIsOptional","OptionalBindingPattern","DeclareClassFieldHasInitializer","TypeImportCannotSpecifyDefaultAndNamed","ConstructorClassField","VarRedeclaration","InvalidPrivateFieldResolution","DuplicateExport"]),Fs $ 1
2024-08-30 15:19:18 +08:00
` )return qa-2;if(td=== `
` ||td===" \r "||td===" \u 2028"||td===" \u 2029")return qa-1}else{if(td===" \r "&&Ra.charAt(qa+1)=== `
` )return qa+2;if(td=== `
2024-09-03 08:22:14 +08:00
` ||td===" \r "||td===" \u 2028"||td===" \u 2029")return qa+1}return qa}var Ue $ 1= $ a $ 2;function Ka(Ra,qa,Ja={}){let ed=Ge $ 1(Ra,Ja.backwards?qa-1:qa,Ja),td=Ue $ 1(Ra,ed,Ja);return ed!==td}var te $ 1=Ka;function za(Ra,qa){if(qa===!1)return!1;if(Ra.charAt(qa)==="/"&&Ra.charAt(qa+1)==="*"){for(let Ja=qa+2;Ja<Ra.length;++Ja)if(Ra.charAt(Ja)==="*"&&Ra.charAt(Ja+1)==="/")return Ja+2}return qa}var Lt $ 1=za;function Qa(Ra,qa){return qa===!1?!1:Ra.charAt(qa)==="/"&&Ra.charAt(qa+1)==="/"?zs(Ra,qa):qa}var wt=Qa;function Za $ 1(Ra,qa){let Ja=null,ed=qa;for(;ed!==Ja;)Ja=ed,ed=Ks $ 1(Ra,ed),ed=Lt $ 1(Ra,ed),ed=Ge $ 1(Ra,ed);return ed=wt(Ra,ed),ed=Ue $ 1(Ra,ed),ed!==!1&&te $ 1(Ra,ed)}var Ot $ 2=Za $ 1;function eo(Ra){return Array.isArray(Ra)&&Ra.length>0}var w=eo,dr="'",Qs $ 1='"';function to(Ra,qa){let Ja=qa===!0||qa===dr?dr:Qs $ 1,ed=Ja===dr?Qs $ 1:dr,td=0,rd=0;for(let sd of Ra)sd===Ja?td++:sd===ed&&rd++;return td>rd?ed:Ja}var xr=to;function ro(Ra,qa,Ja){let ed=qa==='"'?"'":'"',td=N $ 1(!1,Ra,/ \\ (.)|(["'])/gsu,(rd,sd,od)=>sd===ed?sd:od===qa?" \\ "+od:od||(Ja&&/^[^ \n \r "'0-7 \\ bfnrt-vx \u 2028 \u 2029] $ /u.test(sd)?sd:" \\ "+sd));return qa+td+qa}var Zs $ 1=ro;function no $ 1(Ra,qa){let Ja=Ra.slice(1,-1),ed=qa.parser==="json"||qa.parser==="jsonc"||qa.parser==="json5"&&qa.quoteProps==="preserve"&&!qa.singleQuote?'"':qa.__isInHtmlAttribute?"'":xr(Ja,qa.singleQuote);return Zs $ 1(Ja,ed,!(qa.parser==="css"||qa.parser==="less"||qa.parser==="scss"||qa.__embeddedInHtml))}var tt $ 1=no $ 1;function R $ 1(Ra){var qa,Ja,ed;let td=((qa=Ra.range)==null?void 0:qa[0])??Ra.start,rd=(ed=((Ja=Ra.declaration)==null?void 0:Ja.decorators)??Ra.decorators)==null?void 0:ed[0];return rd?Math.min(R $ 1(rd),td):td}function k(Ra){var qa;return((qa=Ra.range)==null?void 0:qa[1])??Ra.end}function ht $ 1(Ra,qa){let Ja=R $ 1(Ra);return Number.isInteger(Ja)&&Ja===R $ 1(qa)}function so $ 1(Ra,qa){let Ja=k(Ra);return Number.isInteger(Ja)&&Ja===k(qa)}function eu $ 1(Ra,qa){return ht $ 1(Ra,qa)&&so $ 1(Ra,qa)}var Qt=null;function Zt $ 2(Ra){if(Qt!==null&&typeof Qt.property){let qa=Qt;return Qt=Zt $ 2.prototype=null,qa}return Qt=Zt $ 2.prototype=Ra??Object.create(null),new Zt $ 2}var uo $ 2=10;for(let Ra=0;Ra<=uo $ 2;Ra++)Zt $ 2();function In $ 1(Ra){return Zt $ 2(Ra)}function io(Ra,qa="type"){In $ 1(Ra);function Ja(ed){let td=ed[qa],rd=Ra[td];if(!Array.isArray(rd))throw Object.assign(new Error( ` Missing visitor keys for '${td}' . ` ),{node:ed});return rd}return Ja}var hr=io,tu $ 2={ArrayExpression:["elements"],AssignmentExpression:["left","right"],BinaryExpression:["left","right"],InterpreterDirective:[],Directive:["value"],DirectiveLiteral:[],BlockStatement:["directives","body"],BreakStatement:["label"],CallExpression:["callee","arguments","typeParameters","typeArguments"],CatchClause:["param","body"],ConditionalExpression:["test","consequent","alternate"],ContinueStatement:["label"],DebuggerStatement:[],DoWhileStatement:["test","body"],EmptyStatement:[],ExpressionStatement:["expression"],File:["program"],ForInStatement:["left","right","body"],ForStatement:["init","test","update","body"],FunctionDeclaration:["id","params","body","returnType","typeParameters","predicate"],FunctionExpression:["id","params","body","returnType","typeParameters"],Identifier:["typeAnnotation","decorators"],IfStatement:["test","consequent","alternate"],LabeledStatement:["label","body"],StringLiteral:[],NumericLiteral:[],NullLiteral:[],BooleanLiteral:[],RegExpLiteral:[],LogicalExpression:["left","right"],MemberExpression:["object","property"],NewExpression:["callee","arguments","typeParameters","typeArguments"],Program:["directives","body"],ObjectExpression:["properties"],ObjectMethod:["key","params","body","decorators","returnType","typeParameters"],ObjectProperty:["key","value","decorators"],RestElement:["argument","typeAnnotation","decorators"],ReturnStatement:["argument"],SequenceExpression:["expressions"],ParenthesizedExpression:["expression"],SwitchCase:["test","consequent"],SwitchStatement:["discriminant","cases"],ThisExpression:[],ThrowStatement:["argument"],TryStatement:["block","handler","finalizer"],UnaryExpression:["argument"],UpdateExpression:["argument"],VariableDeclaration:["decla
2024-08-30 15:19:18 +08:00
` ):Ra.type==="UnaryExpression"?rr(Ra.argument,{printWidth:Ja}):Ra.type==="CallExpression"&&Ra.arguments.length===0&&Ra.callee.type==="Identifier"?Ra.callee.name.length<=ed-2:kr(Ra)}function Oe $ 1(Ra,qa){return X(qa)?Bt $ 2(qa):d(qa,g $ 2.Leading,Ja=>te $ 1(Ra,k(Ja)))}function nu $ 2(Ra){return Ra.quasis.some(qa=>qa.value.raw.includes( `
` ))}function Lr(Ra,qa){return(Ra.type==="TemplateLiteral"&&nu $ 2(Ra)||Ra.type==="TaggedTemplateExpression"&&nu $ 2(Ra.quasi))&&!te $ 1(qa,R $ 1(Ra),{backwards:!0})}function wr(Ra){if(!d(Ra))return!1;let qa=O $ 1(!1,ct(Ra,g $ 2.Dangling),-1);return qa&&!re $ 1(qa)}function lu $ 1(Ra){if(Ra.length<=1)return!1;let qa=0;for(let Ja of Ra)if(_t $ 1(Ja)){if(qa+=1,qa>1)return!0}else if(L $ 1(Ja)){for(let ed of oe $ 1(Ja))if(_t $ 1(ed))return!0}return!1}function Or(Ra){let{node:qa,parent:Ja,key:ed}=Ra;return ed==="callee"&&L $ 1(qa)&&L $ 1(Ja)&&Ja.arguments.length>0&&qa.arguments.length>Ja.arguments.length}var xo $ 1=new Set(["!","-","+","~"]);function be $ 2(Ra,qa=2){if(qa<=0)return!1;if(Ra.type==="ChainExpression"||Ra.type==="TSNonNullExpression")return be $ 2(Ra.expression,qa);let Ja=ed=>be $ 2(ed,qa-1);if(vn $ 1(Ra))return et $ 1(Ra.pattern??Ra.regex.pattern)<=5;if(kr(Ra)||Do(Ra)||Ra.type==="ArgumentPlaceholder")return!0;if(Ra.type==="TemplateLiteral")return Ra.quasis.every(ed=>!ed.value.raw.includes( `
2024-09-03 08:22:14 +08:00
` ))&&Ra.expressions.every(Ja);if(se(Ra))return Ra.properties.every(ed=>!ed.computed&&(ed.shorthand||ed.value&&Ja(ed.value)));if(U $ 1(Ra))return Ra.elements.every(ed=>ed===null||Ja(ed));if(lt $ 1(Ra)){if(Ra.type==="ImportExpression"||be $ 2(Ra.callee,qa)){let ed=oe $ 1(Ra);return ed.length<=qa&&ed.every(Ja)}return!1}return q $ 1(Ra)?be $ 2(Ra.object,qa)&&be $ 2(Ra.property,qa):Ra.type==="UnaryExpression"&&xo $ 1.has(Ra.operator)||Ra.type==="UpdateExpression"?be $ 2(Ra.argument,qa):!1}function fe $ 1(Ra){var qa;return((qa=Ra.extra)==null?void 0:qa.raw)??Ra.raw}function mu $ 1(Ra){return Ra}function ae(Ra,qa="es5"){return Ra.trailingComma==="es5"&&qa==="es5"||Ra.trailingComma==="all"&&(qa==="all"||qa==="es5")}function ie $ 1(Ra,qa){switch(Ra.type){case"BinaryExpression":case"LogicalExpression":case"AssignmentExpression":case"NGPipeExpression":return ie $ 1(Ra.left,qa);case"MemberExpression":case"OptionalMemberExpression":return ie $ 1(Ra.object,qa);case"TaggedTemplateExpression":return Ra.tag.type==="FunctionExpression"?!1:ie $ 1(Ra.tag,qa);case"CallExpression":case"OptionalCallExpression":return Ra.callee.type==="FunctionExpression"?!1:ie $ 1(Ra.callee,qa);case"ConditionalExpression":return ie $ 1(Ra.test,qa);case"UpdateExpression":return!Ra.prefix&&ie $ 1(Ra.argument,qa);case"BindExpression":return Ra.object&&ie $ 1(Ra.object,qa);case"SequenceExpression":return ie $ 1(Ra.expressions[0],qa);case"ChainExpression":case"TSSatisfiesExpression":case"TSAsExpression":case"TSNonNullExpression":case"AsExpression":case"AsConstExpression":case"SatisfiesExpression":return ie $ 1(Ra.expression,qa);default:return qa(Ra)}}var su $ 2={"==":!0,"!=":!0,"===":!0,"!==":!0},br={"*":!0,"/":!0,"%":!0},_n $ 2={">>":!0,">>>":!0,"<<":!0};function nr(Ra,qa){return!(er(qa)!==er(Ra)||Ra==="**"||su $ 2[Ra]&&su $ 2[qa]||qa==="%"&&br[Ra]||Ra==="%"&&br[qa]||qa!==Ra&&br[qa]&&br[Ra]||_n $ 2[Ra]&&_n $ 2[qa])}var ho $ 1=new Map([["|>"],["??"],["||"],["&&"],["|"],["^"],["&"],["==","===","!=","!=="],["<",">","<=",">=","in","instanceof"],[">>","<<",">>>"],["+","-"],["*","/","%"],["**"]].flatMap((Ra,qa)=>Ra.map(Ja=>[Ja,qa])));function er(Ra){return ho $ 1.get(Ra)}function yu(Ra){return!!_n $ 2[Ra]||Ra==="|"||Ra==="^"||Ra==="&"}function Du $ 1(Ra){var qa;if(Ra.rest)return!0;let Ja=K $ 1(Ra);return((qa=O $ 1(!1,Ja,-1))==null?void 0:qa.type)==="RestElement"}var wn $ 2=new WeakMap;function K $ 1(Ra){if(wn $ 2.has(Ra))return wn $ 2.get(Ra);let qa=[];return Ra.this&&qa.push(Ra.this),Array.isArray(Ra.parameters)?qa.push(...Ra.parameters):Array.isArray(Ra.params)&&qa.push(...Ra.params),Ra.rest&&qa.push(Ra.rest),wn $ 2.set(Ra,qa),qa}function fu(Ra,qa){let{node:Ja}=Ra,ed=0,td=rd=>qa(rd,ed++);Ja.this&&Ra.call(td,"this"),Array.isArray(Ja.parameters)?Ra.each(td,"parameters"):Array.isArray(Ja.params)&&Ra.each(td,"params"),Ja.rest&&Ra.call(td,"rest")}var On $ 1=new WeakMap;function oe $ 1(Ra){if(On $ 1.has(Ra))return On $ 1.get(Ra);if(Ra.type==="ChainExpression")return oe $ 1(Ra.expression);let qa=Ra.arguments;return Ra.type==="ImportExpression"&&(qa=[Ra.source],Ra.attributes&&qa.push(Ra.attributes),Ra.options&&qa.push(Ra.options)),On $ 1.set(Ra,qa),qa}function Rt $ 2(Ra,qa){let{node:Ja}=Ra;if(Ja.type==="ChainExpression")return Ra.call(()=>Rt $ 2(Ra,qa),"expression");Ja.type==="ImportExpression"?(Ra.call(ed=>qa(ed,0),"source"),Ja.attributes&&Ra.call(ed=>qa(ed,1),"attributes"),Ja.options&&Ra.call(ed=>qa(ed,1),"options")):Ra.each(qa,"arguments")}function Rn $ 1(Ra,qa){let Ja=[];if(Ra.type==="ChainExpression"&&(Ra=Ra.expression,Ja.push("expression")),Ra.type==="ImportExpression"){if(qa===0||qa===(Ra.attributes||Ra.options?-2:-1))return[...Ja,"source"];if(Ra.attributes&&(qa===1||qa===-1))return[...Ja,"attributes"];if(Ra.options&&(qa===1||qa===-1))return[...Ja,"options"];throw new RangeError("Invalid argument index")}if(qa<0&&(qa=Ra.arguments.length+qa),qa<0||qa>=Ra.arguments.length)throw new RangeError("Invalid argument index");return[...Ja,"arguments",qa]}function sr(Ra){return Ra.value.trim()==="prettier-ignore"&&!Ra.unignore}function Bt $ 2(Ra){return(Ra==null?void 0:Ra.prettierIgnore)||d(Ra,g $ 2.PrettierIgnore)}var g $ 2={Leading:2,Trailing:4,Dangling:8,Block:16,Line:32,Pr
2024-08-30 15:19:18 +08:00
Expected it to be 'string' or 'object' . ` ;if(ut(Ra))throw new Error("doc is valid.");let Ja=Object.prototype.toString.call(Ra);if(Ja!=="[object Object]")return ` Unexpected doc '${Ja}' . ` ;let ed=Bo([...jr $ 1].map(td=> ` '${td}' ` ));return ` Unexpected doc . type '${Ra.type}' .
2024-09-08 17:22:36 +08:00
Expected it to be $ { ed } . ` }var Jn $ 2=class extends Error{constructor(Ja){super(bo $ 1(Ja));n_(this,"name","InvalidDocError");this.doc=Ja}},Ct $ 2=Jn $ 2,Au={};function Po(Ra,qa,Ja,ed){let td=[Ra];for(;td.length>0;){let rd=td.pop();if(rd===Au){Ja(td.pop());continue}Ja&&td.push(rd,Au);let sd=ut(rd);if(!sd)throw new Ct $ 2(rd);if((qa==null?void 0:qa(rd))!==!1)switch(sd){case _e $ 1:case Pe $ 1:{let od=sd===_e $ 1?rd:rd.parts;for(let ld=od.length,cd=ld-1;cd>=0;--cd)td.push(od[cd]);break}case xe $ 2:td.push(rd.flatContents,rd.breakContents);break;case le $ 1:if(ed&&rd.expandedStates)for(let od=rd.expandedStates.length,ld=od-1;ld>=0;--ld)td.push(rd.expandedStates[ld]);else td.push(rd.contents);break;case Ye $ 1:case Xe $ 1:case He $ 1:case je $ 2:case Ve $ 1:td.push(rd.contents);break;case rt $ 1:case nt:case st:case $ e $ 2:case me:case ve $ 1:break;default:throw new Ct $ 2(rd)}}}var qn $ 2=Po,Tu $ 1=()=>{},vr=Tu $ 1;function f(Ra){return{type:Xe $ 1,contents:Ra}}function he $ 1(Ra,qa){return{type:Ye $ 1,contents:qa,n:Ra}}function l(Ra,qa={}){return vr(qa.expandedStates),{type:le $ 1,id:qa.id,contents:Ra,break:!!qa.shouldBreak,expandedStates:qa.expandedStates}}function du $ 1(Ra){return he $ 1(Number.NEGATIVE_INFINITY,Ra)}function Mr $ 1(Ra){return he $ 1(-1,Ra)}function ze $ 1(Ra,qa){return l(Ra[0],{...qa,expandedStates:Ra})}function qt $ 1(Ra){return{type:Pe $ 1,parts:Ra}}function b(Ra,qa="",Ja={}){return{type:xe $ 2,breakContents:Ra,flatContents:qa,groupId:Ja.groupId}}function At $ 2(Ra,qa){return{type:He $ 1,contents:Ra,groupId:qa.groupId,negate:qa.negate}}function Wn $ 1(Ra){return{type:Ve $ 1,contents:Ra}}var ke $ 2={type: $ e $ 2},Ee $ 1={type:ve $ 1},Gn $ 2={type:me,hard:!0},ko={type:me,hard:!0,literal:!0},x={type:me},E $ 1={type:me,soft:!0},F=[Gn $ 2,Ee $ 1],Rr=[ko,Ee $ 1],Un $ 1={type:nt};function P $ 1(Ra,qa){let Ja=[];for(let ed=0;ed<qa.length;ed++)ed!==0&&Ja.push(Ra),Ja.push(qa[ed]);return Ja}function xu(Ra,qa,Ja){let ed=Ra;if(qa>0){for(let td=0;td<Math.floor(qa/Ja);++td)ed=f(ed);ed=he $ 1(qa%Ja,ed),ed=he $ 1(Number.NEGATIVE_INFINITY,ed)}return ed}function it $ 1(Ra,qa){return Ra?{type:je $ 2,label:Ra,contents:qa}:qa}function mt $ 1(Ra,qa){if(typeof Ra=="string")return qa(Ra);let Ja=new Map;return ed(Ra);function ed(rd){if(Ja.has(rd))return Ja.get(rd);let sd=td(rd);return Ja.set(rd,sd),sd}function td(rd){switch(ut(rd)){case _e $ 1:return qa(rd.map(ed));case Pe $ 1:return qa({...rd,parts:rd.parts.map(ed)});case xe $ 2:return qa({...rd,breakContents:ed(rd.breakContents),flatContents:ed(rd.flatContents)});case le $ 1:{let{expandedStates:sd,contents:od}=rd;return sd?(sd=sd.map(ed),od=sd[0]):od=ed(od),qa({...rd,contents:od,expandedStates:sd})}case Ye $ 1:case Xe $ 1:case He $ 1:case je $ 2:case Ve $ 1:return qa({...rd,contents:ed(rd.contents)});case rt $ 1:case nt:case st:case $ e $ 2:case me:case ve $ 1:return qa(rd);default:throw new Ct $ 2(rd)}}}function gu(Ra,qa,Ja){let ed=Ja,td=!1;function rd(sd){if(td)return!1;let od=qa(sd);od!==void 0&&(td=!0,ed=od)}return qn $ 2(Ra,rd),ed}function Io(Ra){if(Ra.type===le $ 1&&Ra.break||Ra.type===me&&Ra.hard||Ra.type===ve $ 1)return!0}function ne $ 1(Ra){return gu(Ra,Io,!1)}function hu $ 1(Ra){if(Ra.length>0){let qa=O $ 1(!1,Ra,-1);!qa.expandedStates&&!qa.break&&(qa.break="propagated")}return null}function Su(Ra){let qa=new Set,Ja=[];function ed(rd){if(rd.type===ve $ 1&&hu $ 1(Ja),rd.type===le $ 1){if(Ja.push(rd),qa.has(rd))return!1;qa.add(rd)}}function td(rd){rd.type===le $ 1&&Ja.pop().break&&hu $ 1(Ja)}qn $ 2(Ra,ed,td,!0)}function Lo $ 2(Ra){return Ra.type===me&&!Ra.hard?Ra.soft?"":" ":Ra.type===xe $ 2?Ra.flatContents:Ra}function ur(Ra){return mt $ 1(Ra,Lo $ 2)}function wo $ 1(Ra){switch(ut(Ra)){case Pe $ 1:if(Ra.parts.every(qa=>qa===""))return"";break;case le $ 1:if(!Ra.contents&&!Ra.id&&!Ra.break&&!Ra.expandedStates)return"";if(Ra.contents.type===le $ 1&&Ra.contents.id===Ra.id&&Ra.contents.break===Ra.break&&Ra.contents.expandedStates===Ra.expandedStates)return Ra.contents;break;case Ye $ 1:case Xe $ 1:case He $ 1:case Ve $ 1:if(!Ra.contents)return"";break;case xe $ 2:if(!Ra.flatContents&&!Ra.breakContents)return"";break;case _e $ 1:{let qa=[];for(let Ja of Ra){if(!Ja)continue;let[ed,...td]=Array.isArray(Ja)?Ja:[Ja];typeof ed=="string"&&typeof O $ 1(!1,qa,-1)=="s
2024-08-30 15:19:18 +08:00
` )):Ja)}function Oo(Ra){if(Ra.type===me)return!0}function Bu(Ra){return gu(Ra,Oo,!1)}function ir $ 1(Ra,qa){return Ra.type===je $ 2?{...Ra,contents:qa(Ra.contents)}:qa(Ra)}function _o(Ra){let qa= ` * $ { Ra . value } * ` .split( `
` );return qa.length>1&&qa.every(Ja=>Ja.trimStart()[0]==="*")}var bu=_o;function Pu(Ra,qa){let Ja=Ra.node;if(vt(Ja))return qa.originalText.slice(R $ 1(Ja),k(Ja)).trimEnd();if(re $ 1(Ja))return bu(Ja)?jo $ 1(Ja):["/*",Ie(Ja.value),"*/"];throw new Error("Not a comment: "+JSON.stringify(Ja))}function jo $ 1(Ra){let qa=Ra.value.split( `
` );return["/*",P $ 1(F,qa.map((Ja,ed)=>ed===0?Ja.trimEnd():" "+(ed<qa.length-1?Ja.trim():Ja.trimStart()))),"*/"]}var Kn $ 1={};Ar(Kn $ 1,{endOfLine:()=>Go,ownLine:()=>Wo $ 1,remaining:()=>Uo $ 2});function vo(Ra){let qa=Ra.type||Ra.kind||"(unknown type)",Ja=String(Ra.name||Ra.id&&(typeof Ra.id=="object"?Ra.id.name:Ra.id)||Ra.key&&(typeof Ra.key=="object"?Ra.key.name:Ra.key)||Ra.value&&(typeof Ra.value=="object"?"":String(Ra.value))||Ra.operator||"");return Ja.length>20&&(Ja=Ja.slice(0,19)+"…"),qa+(Ja?" "+Ja:"")}function Nn $ 1(Ra,qa){(Ra.comments??(Ra.comments=[])).push(qa),qa.printed=!1,qa.nodeDescription=vo(Ra)}function ce $ 1(Ra,qa){qa.leading=!0,qa.trailing=!1,Nn $ 1(Ra,qa)}function Le $ 1(Ra,qa,Ja){qa.leading=!1,qa.trailing=!1,Ja&&(qa.marker=Ja),Nn $ 1(Ra,qa)}function z $ 1(Ra,qa){qa.leading=!1,qa.trailing=!0,Nn $ 1(Ra,qa)}function Mo $ 1(Ra,qa){let Ja=null,ed=qa;for(;ed!==Ja;)Ja=ed,ed=Ge $ 1(Ra,ed),ed=Lt $ 1(Ra,ed),ed=wt(Ra,ed),ed=Ue $ 1(Ra,ed);return ed}var yt $ 1=Mo $ 1;function Ro(Ra,qa){let Ja=yt $ 1(Ra,qa);return Ja===!1?"":Ra.charAt(Ja)}var ge $ 1=Ro;function Jo $ 1(Ra,qa,Ja){for(let ed=qa;ed<Ja;++ed)if(Ra.charAt(ed)=== `
2024-09-08 17:22:36 +08:00
` )return!0;return!1}var de $ 1=Jo $ 1;function qo(Ra){return re $ 1(Ra)&&Ra.value[0]==="*"&&/@(?:type|satisfies) \b /u.test(Ra.value)}var ku=qo;function Wo $ 1(Ra){return[Mu,Lu,_u $ 1,ep,Xo,Yn $ 2,Hn $ 1,Iu,wu $ 1,sp,rp, $ n $ 2,vu $ 1,up,Ou,ju $ 1,Vn $ 1,Yo,yp].some(qa=>qa(Ra))}function Go(Ra){return[No,_u $ 1,Lu,vu $ 1,Yn $ 2,Hn $ 1,Iu,wu $ 1,ju $ 1,tp,np, $ n $ 2,op $ 1,Vn $ 1,lp,mp].some(qa=>qa(Ra))}function Uo $ 2(Ra){return[Mu,Yn $ 2,Hn $ 1,Ho $ 2,Zo $ 1,Ou, $ n $ 2,Qo,zo $ 1,cp,Vn $ 1,pp].some(qa=>qa(Ra))}function bt $ 2(Ra,qa){let Ja=(Ra.body||Ra.properties).find(({type:ed})=>ed!=="EmptyStatement");Ja?ce $ 1(Ja,qa):Le $ 1(Ra,qa)}function Xn $ 2(Ra,qa){Ra.type==="BlockStatement"?bt $ 2(Ra,qa):ce $ 1(Ra,qa)}function No({comment:Ra,followingNode:qa}){return qa&&ku(Ra)?(ce $ 1(qa,Ra),!0):!1}function Yn $ 2({comment:Ra,precedingNode:qa,enclosingNode:Ja,followingNode:ed,text:td}){if((Ja==null?void 0:Ja.type)!=="IfStatement"||!ed)return!1;if(ge $ 1(td,k(Ra))===")")return z $ 1(qa,Ra),!0;if(qa===Ja.consequent&&ed===Ja.alternate){if(qa.type==="BlockStatement")z $ 1(qa,Ra);else{let rd=vt(Ra)||Ra.loc.start.line===Ra.loc.end.line,sd=Ra.loc.start.line===qa.loc.start.line;rd&&sd?z $ 1(qa,Ra):Le $ 1(Ja,Ra)}return!0}return ed.type==="BlockStatement"?(bt $ 2(ed,Ra),!0):ed.type==="IfStatement"?(Xn $ 2(ed.consequent,Ra),!0):Ja.consequent===ed?(ce $ 1(ed,Ra),!0):!1}function Hn $ 1({comment:Ra,precedingNode:qa,enclosingNode:Ja,followingNode:ed,text:td}){return(Ja==null?void 0:Ja.type)!=="WhileStatement"||!ed?!1:ge $ 1(td,k(Ra))===")"?(z $ 1(qa,Ra),!0):ed.type==="BlockStatement"?(bt $ 2(ed,Ra),!0):Ja.body===ed?(ce $ 1(ed,Ra),!0):!1}function Iu({comment:Ra,precedingNode:qa,enclosingNode:Ja,followingNode:ed}){return(Ja==null?void 0:Ja.type)!=="TryStatement"&&(Ja==null?void 0:Ja.type)!=="CatchClause"||!ed?!1:Ja.type==="CatchClause"&&qa?(z $ 1(qa,Ra),!0):ed.type==="BlockStatement"?(bt $ 2(ed,Ra),!0):ed.type==="TryStatement"?(Xn $ 2(ed.finalizer,Ra),!0):ed.type==="CatchClause"?(Xn $ 2(ed.body,Ra),!0):!1}function Xo({comment:Ra,enclosingNode:qa,followingNode:Ja}){return q $ 1(qa)&&(Ja==null?void 0:Ja.type)==="Identifier"?(ce $ 1(qa,Ra),!0):!1}function Yo({comment:Ra,enclosingNode:qa,followingNode:Ja,options:ed}){return!ed.experimentalTernaries||!((qa==null?void 0:qa.type)==="ConditionalExpression"||(qa==null?void 0:qa.type)==="ConditionalTypeAnnotation"||(qa==null?void 0:qa.type)==="TSConditionalType")?!1:(Ja==null?void 0:Ja.type)==="ConditionalExpression"||(Ja==null?void 0:Ja.type)==="ConditionalTypeAnnotation"||(Ja==null?void 0:Ja.type)==="TSConditionalType"?(Le $ 1(qa,Ra),!0):!1}function Lu({comment:Ra,precedingNode:qa,enclosingNode:Ja,followingNode:ed,text:td,options:rd}){let sd=qa&&!de $ 1(td,k(qa),R $ 1(Ra));return(!qa||!sd)&&((Ja==null?void 0:Ja.type)==="ConditionalExpression"||(Ja==null?void 0:Ja.type)==="ConditionalTypeAnnotation"||(Ja==null?void 0:Ja.type)==="TSConditionalType")&&ed?rd.experimentalTernaries&&Ja.alternate===ed&&!(re $ 1(Ra)&&!de $ 1(rd.originalText,R $ 1(Ra),k(Ra)))?(Le $ 1(Ja,Ra),!0):(ce $ 1(ed,Ra),!0):!1}function Ho $ 2({comment:Ra,precedingNode:qa,enclosingNode:Ja}){return Ae $ 1(Ja)&&Ja.shorthand&&Ja.key===qa&&Ja.value.type==="AssignmentPattern"?(z $ 1(Ja.value.left,Ra),!0):!1}var Vo=new Set(["ClassDeclaration","ClassExpression","DeclareClass","DeclareInterface","InterfaceDeclaration","TSInterfaceDeclaration"]);function wu $ 1({comment:Ra,precedingNode:qa,enclosingNode:Ja,followingNode:ed}){if(Vo.has(Ja==null?void 0:Ja.type)){if(w(Ja.decorators)&&(ed==null?void 0:ed.type)!=="Decorator")return z $ 1(O $ 1(!1,Ja.decorators,-1),Ra),!0;if(Ja.body&&ed===Ja.body)return bt $ 2(Ja.body,Ra),!0;if(ed){if(Ja.superClass&&ed===Ja.superClass&&qa&&(qa===Ja.id||qa===Ja.typeParameters))return z $ 1(qa,Ra),!0;for(let td of["implements","extends","mixins"])if(Ja[td]&&ed===Ja[td][0])return qa&&(qa===Ja.id||qa===Ja.typeParameters||qa===Ja.superClass)?z $ 1(qa,Ra):Le $ 1(Ja,Ra,td),!0}}return!1}var $ o $ 1=new Set(["ClassMethod","ClassProperty","PropertyDefinition","TSAbstractPropertyDefinition","TSAbstractMethodDefinition","TSDeclareMethod","MethodDefinition","ClassAccessorProperty","AccessorProperty","TSAbstractAccessorProperty"]);function Ou({comment:Ra,precedingNode:qa,enclosingNode:J
2024-08-27 22:31:52 +08:00
` ;default:return `
2024-09-08 17:22:36 +08:00
` }}var Se $ 1=Symbol("MODE_BREAK"),at $ 2=Symbol("MODE_FLAT"),ar=Symbol("cursor");function qu $ 2(){return{value:"",length:0,queue:[]}}function Cp(Ra,qa){return Qn $ 2(Ra,{type:"indent"},qa)}function Ap $ 1(Ra,qa,Ja){return qa===Number.NEGATIVE_INFINITY?Ra.root||qu $ 2():qa<0?Qn $ 2(Ra,{type:"dedent"},Ja):qa?qa.type==="root"?{...Ra,root:Ra}:Qn $ 2(Ra,{type:typeof qa=="string"?"stringAlign":"numberAlign",n:qa},Ja):Ra}function Qn $ 2(Ra,qa,Ja){let ed=qa.type==="dedent"?Ra.queue.slice(0,-1):[...Ra.queue,qa],td="",rd=0,sd=0,od=0;for(let Ed of ed)switch(Ed.type){case"indent":ud(),Ja.useTabs?ld(1):cd(Ja.tabWidth);break;case"stringAlign":ud(),td+=Ed.n,rd+=Ed.n.length;break;case"numberAlign":sd+=1,od+=Ed.n;break;default:throw new Error( ` Unexpected type '${Ed.type}' ` )}return yd(),{...Ra,value:td,length:rd,queue:ed};function ld(Ed){td+=" ".repeat(Ed),rd+=Ja.tabWidth*Ed}function cd(Ed){td+=" ".repeat(Ed),rd+=Ed}function ud(){Ja.useTabs?_d():yd()}function _d(){sd>0&&ld(sd),gd()}function yd(){od>0&&cd(od),gd()}function gd(){sd=0,od=0}}function Zn $ 1(Ra){let qa=0,Ja=0,ed=Ra.length;e:for(;ed--;){let td=Ra[ed];if(td===ar){Ja++;continue}for(let rd=td.length-1;rd>=0;rd--){let sd=td[rd];if(sd===" "||sd===" ")qa++;else{Ra[ed]=td.slice(0,rd+1);break e}}}if(qa>0||Ja>0)for(Ra.length=ed+1;Ja-- >0;)Ra.push(ar);return qa}function Jr $ 1(Ra,qa,Ja,ed,td,rd){if(Ja===Number.POSITIVE_INFINITY)return!0;let sd=qa.length,od=[Ra],ld=[];for(;Ja>=0;){if(od.length===0){if(sd===0)return!0;od.push(qa[--sd]);continue}let{mode:cd,doc:ud}=od.pop(),_d=ut(ud);switch(_d){case rt $ 1:ld.push(ud),Ja-=et $ 1(ud);break;case _e $ 1:case Pe $ 1:{let yd=_d===_e $ 1?ud:ud.parts;for(let gd=yd.length-1;gd>=0;gd--)od.push({mode:cd,doc:yd[gd]});break}case Xe $ 1:case Ye $ 1:case He $ 1:case je $ 2:od.push({mode:cd,doc:ud.contents});break;case st:Ja+=Zn $ 1(ld);break;case le $ 1:{if(rd&&ud.break)return!1;let yd=ud.break?Se $ 1:cd,gd=ud.expandedStates&&yd===Se $ 1?O $ 1(!1,ud.expandedStates,-1):ud.contents;od.push({mode:yd,doc:gd});break}case xe $ 2:{let yd=(ud.groupId?td[ud.groupId]||at $ 2:cd)===Se $ 1?ud.breakContents:ud.flatContents;yd&&od.push({mode:cd,doc:yd});break}case me:if(cd===Se $ 1||ud.hard)return!0;ud.soft||(ld.push(" "),Ja--);break;case Ve $ 1:ed=!0;break;case $ e $ 2:if(ed)return!1;break}}return!1}function es $ 1(Ra,qa){let Ja={},ed=qa.printWidth,td=Ju $ 2(qa.endOfLine),rd=0,sd=[{ind:qu $ 2(),mode:Se $ 1,doc:Ra}],od=[],ld=!1,cd=[],ud=0;for(Su(Ra);sd.length>0;){let{ind:yd,mode:gd,doc:Ed}=sd.pop();switch(ut(Ed)){case rt $ 1:{let Td=td!== `
2024-08-30 15:19:18 +08:00
` ?N $ 1(!1,Ed, `
2024-09-08 17:22:36 +08:00
` ,td):Ed;od.push(Td),sd.length>0&&(rd+=et $ 1(Td));break}case _e $ 1:for(let Td=Ed.length-1;Td>=0;Td--)sd.push({ind:yd,mode:gd,doc:Ed[Td]});break;case nt:if(ud>=2)throw new Error("There are too many 'cursor' in doc.");od.push(ar),ud++;break;case Xe $ 1:sd.push({ind:Cp(yd,qa),mode:gd,doc:Ed.contents});break;case Ye $ 1:sd.push({ind:Ap $ 1(yd,Ed.n,qa),mode:gd,doc:Ed.contents});break;case st:rd-=Zn $ 1(od);break;case le $ 1:switch(gd){case at $ 2:if(!ld){sd.push({ind:yd,mode:Ed.break?Se $ 1:at $ 2,doc:Ed.contents});break}case Se $ 1:{ld=!1;let Td={ind:yd,mode:at $ 2,doc:Ed.contents},Od=ed-rd,Rd=cd.length>0;if(!Ed.break&&Jr $ 1(Td,sd,Od,Rd,Ja))sd.push(Td);else if(Ed.expandedStates){let Nd=O $ 1(!1,Ed.expandedStates,-1);if(Ed.break){sd.push({ind:yd,mode:Se $ 1,doc:Nd});break}else for(let Id=1;Id<Ed.expandedStates.length+1;Id++)if(Id>=Ed.expandedStates.length){sd.push({ind:yd,mode:Se $ 1,doc:Nd});break}else{let Md=Ed.expandedStates[Id],Ld={ind:yd,mode:at $ 2,doc:Md};if(Jr $ 1(Ld,sd,Od,Rd,Ja)){sd.push(Ld);break}}}else sd.push({ind:yd,mode:Se $ 1,doc:Ed.contents});break}}Ed.id&&(Ja[Ed.id]=O $ 1(!1,sd,-1).mode);break;case Pe $ 1:{let Td=ed-rd,{parts:Od}=Ed;if(Od.length===0)break;let[Rd,Nd]=Od,Id={ind:yd,mode:at $ 2,doc:Rd},Md={ind:yd,mode:Se $ 1,doc:Rd},Ld=Jr $ 1(Id,[],Td,cd.length>0,Ja,!0);if(Od.length===1){Ld?sd.push(Id):sd.push(Md);break}let Pd={ind:yd,mode:at $ 2,doc:Nd},qd={ind:yd,mode:Se $ 1,doc:Nd};if(Od.length===2){Ld?sd.push(Pd,Id):sd.push(qd,Md);break}Od.splice(0,2);let Yd={ind:yd,mode:gd,doc:qt $ 1(Od)},Ud=Od[0];Jr $ 1({ind:yd,mode:at $ 2,doc:[Rd,Nd,Ud]},[],Td,cd.length>0,Ja,!0)?sd.push(Yd,Pd,Id):Ld?sd.push(Yd,qd,Id):sd.push(Yd,qd,Md);break}case xe $ 2:case He $ 1:{let Td=Ed.groupId?Ja[Ed.groupId]:gd;if(Td===Se $ 1){let Od=Ed.type===xe $ 2?Ed.breakContents:Ed.negate?Ed.contents:f(Ed.contents);Od&&sd.push({ind:yd,mode:gd,doc:Od})}if(Td===at $ 2){let Od=Ed.type===xe $ 2?Ed.flatContents:Ed.negate?f(Ed.contents):Ed.contents;Od&&sd.push({ind:yd,mode:gd,doc:Od})}break}case Ve $ 1:cd.push({ind:yd,mode:gd,doc:Ed.contents});break;case $ e $ 2:cd.length>0&&sd.push({ind:yd,mode:gd,doc:Gn $ 2});break;case me:switch(gd){case at $ 2:if(Ed.hard)ld=!0;else{Ed.soft||(od.push(" "),rd+=1);break}case Se $ 1:if(cd.length>0){sd.push({ind:yd,mode:gd,doc:Ed},...cd.reverse()),cd.length=0;break}Ed.literal?yd.root?(od.push(td,yd.root.value),rd=yd.root.length):(od.push(td),rd=0):(rd-=Zn $ 1(od),od.push(td+yd.value),rd=yd.length);break}break;case je $ 2:sd.push({ind:yd,mode:gd,doc:Ed.contents});break;case ve $ 1:break;default:throw new Ct $ 2(Ed)}sd.length===0&&cd.length>0&&(sd.push(...cd.reverse()),cd.length=0)}let _d=od.indexOf(ar);if(_d!==-1){let yd=od.indexOf(ar,_d+1),gd=od.slice(0,_d).join(""),Ed=od.slice(_d+1,yd).join(""),Td=od.slice(yd+1).join("");return{formatted:gd+Ed+Td,cursorNodeStart:gd.length,cursorNodeText:Ed}}return{formatted:od.join("")}}function Tp $ 1(Ra,qa,Ja=0){let ed=0;for(let td=Ja;td<Ra.length;++td)Ra[td]===" "?ed=ed+qa-ed%qa:ed++;return ed}var Wu=Tp $ 1;function dp(Ra,qa){let Ja=Ra.lastIndexOf( `
2024-09-03 08:22:14 +08:00
` );return Ja===-1?0:Wu(Ra.slice(Ja+1).match(/^[ \t ]*/u)[0],qa)}var Gu $ 1=dp;function qr(Ra,qa,Ja){let{node:ed}=Ra;if(ed.type==="TemplateLiteral"&&gp(Ra)){let ld=xp(Ra,Ja,qa);if(ld)return ld}let td="expressions";ed.type==="TSTemplateLiteralType"&&(td="types");let rd=[],sd=Ra.map(qa,td);rd.push(ke $ 2," ` " ) ; let od = 0 ; return Ra . each ( ( { index : ld , node : cd } ) => { if ( rd . push ( qa ( ) ) , cd . tail ) return ; let { tabWidth : ud } = Ja , _d = cd . value . raw , yd = _d . includes ( `
` )?Gu $ 1(_d,ud):od;od=yd;let gd=sd[ld],Ed=ed[td][ld],Td=de $ 1(Ja.originalText,k(cd),R $ 1(ed.quasis[ld+1]));if(!Td){let Rd=es $ 1(gd,{...Ja,printWidth:Number.POSITIVE_INFINITY}).formatted;Rd.includes( `
2024-09-08 17:22:36 +08:00
` )?Td=!0:gd=Rd}Td&&(d(Ed)||Ed.type==="Identifier"||q $ 1(Ed)||Ed.type==="ConditionalExpression"||Ed.type==="SequenceExpression"||Te $ 1(Ed)||De(Ed))&&(gd=[f([E $ 1,gd]),E $ 1]);let Od=yd===0&&_d.endsWith( `
` )?he $ 1(Number.NEGATIVE_INFINITY,gd):xu(gd,yd,ud);rd.push(l([" ${ ",Od,ke$2," } "]))},"quasis"),rd.push(" ` "),rd}function Uu$1(Ra,qa){let Ja=qa(" quasi ");return it$1(Ja.label&&{tagged:!0,...Ja.label},[qa(" tag "),qa(Ra.node.typeArguments?" typeArguments ":" typeParameters "),ke$2,Ja])}function xp(Ra,qa,Ja){let{node:ed}=Ra,td=ed.quasis[0].value.raw.trim().split(/\s*\|\s*/u);if(td.length>1||td.some(rd=>rd.length>0)){qa.__inJestEach=!0;let rd=Ra.map(Ja," expressions ");qa.__inJestEach=!1;let sd=[],od=rd.map(yd=>" $ { "+es$1(yd,{...qa,printWidth:Number.POSITIVE_INFINITY,endOfLine:" lf "}).formatted+" } " ) , ld = [ { hasLineBreak : ! 1 , cells : [ ] } ] ; for ( let yd = 1 ; yd < ed . quasis . length ; yd ++ ) { let gd = O$1 ( ! 1 , ld , - 1 ) , Ed = od [ yd - 1 ] ; gd . cells . push ( Ed ) , Ed . includes ( `
2024-08-31 11:28:56 +08:00
` )&&(gd.hasLineBreak=!0),ed.quasis[yd].value.raw.includes( `
2024-09-08 17:22:36 +08:00
` )&&ld.push({hasLineBreak:!1,cells:[]})}let cd=Math.max(td.length,...ld.map(yd=>yd.cells.length)),ud=Array.from({length:cd}).fill(0),_d=[{cells:td},...ld.filter(yd=>yd.cells.length>0)];for(let{cells:yd}of _d.filter(gd=>!gd.hasLineBreak))for(let[gd,Ed]of yd.entries())ud[gd]=Math.max(ud[gd],et $ 1(Ed));return sd.push(ke $ 2," ` ",f([F,P$1(F,_d.map(yd=>P$1(" | ",yd.cells.map((gd,Ed)=>yd.hasLineBreak?gd:gd+" ".repeat(ud[Ed]-et$1(gd))))))]),F," ` "),sd}}function hp(Ra,qa){let{node:Ja}=Ra,ed=qa();return d(Ja)&&(ed=l([f([E $ 1,ed]),E $ 1])),[" ${ ",ed,ke$2," } "]}function Gt $ 2(Ra,qa){return Ra.map(Ja=>hp(Ja,qa),"expressions")}function Wr $ 1(Ra,qa){return mt $ 1(Ra,Ja=>typeof Ja=="string"?qa?N $ 1(!1,Ja,/( \\ *) ` / gu , "$1$1\\`" ) : ts$1 ( Ja ) : Ja ) } function ts$1 ( Ra ) { return N$1 ( ! 1 , Ra , /([\\`]|\$\{)/gu , String . raw ` \$ 1 ` ) } function gp ( { node : Ra , parent : qa } ) { let Ja = /^[fx]?(?:describe|it|test)$/u ; return qa . type === "TaggedTemplateExpression" && qa . quasi === Ra && qa . tag . type === "MemberExpression" && qa . tag . property . type === "Identifier" && qa . tag . property . name === "each" && ( qa . tag . object . type === "Identifier" && Ja . test ( qa . tag . object . name ) || qa . tag . object . type === "MemberExpression" && qa . tag . object . property . type === "Identifier" && ( qa . tag . object . property . name === "only" || qa . tag . object . property . name === "skip" ) && qa . tag . object . object . type === "Identifier" && Ja . test ( qa . tag . object . object . name ) ) } var ns = [ ( Ra , qa ) => Ra . type === "ObjectExpression" && qa === "properties" , ( Ra , qa ) => Ra . type === "CallExpression" && Ra . callee . type === "Identifier" && Ra . callee . name === "Component" && qa === "arguments" , ( Ra , qa ) => Ra . type === "Decorator" && qa === "expression" ] ; function Nu$1 ( Ra ) { let qa = ed => ed . type === "TemplateLiteral" , Ja = ( ed , td ) => Ae$1 ( ed ) && ! ed . computed && ed . key . type === "Identifier" && ed . key . name === "styles" && td === "value" ; return Ra . match ( qa , ( ed , td ) => U$1 ( ed ) && td === "elements" , Ja , ... ns ) || Ra . match ( qa , Ja , ... ns ) } function Xu$2 ( Ra ) { return Ra . match ( qa => qa . type === "TemplateLiteral" , ( qa , Ja ) => Ae$1 ( qa ) && ! qa . computed && qa . key . type === "Identifier" && qa . key . name === "template" && Ja === "value" , ... ns ) } function rs ( Ra , qa ) { return d ( Ra , g$2 . Block | g$2 . Leading , ( { value : Ja } ) => Ja === ` ${ qa } ` ) } function Gr$1 ( { node : Ra , parent : qa } , Ja ) { return rs ( Ra , Ja ) || Sp ( qa ) && rs ( qa , Ja ) || qa . type === "ExpressionStatement" && rs ( qa , Ja ) } function Sp ( Ra ) { return Ra . type === "AsConstExpression" || Ra . type === "TSAsExpression" && Ra . typeAnnotation . type === "TSTypeReference" && Ra . typeAnnotation . typeName . type === "Identifier" && Ra . typeAnnotation . typeName . name === "const" } async function Bp$1 ( Ra , qa , Ja ) { let { node : ed } = Ja , td = ed . quasis . map ( ud => ud . value . raw ) , rd = 0 , sd = td . reduce ( ( ud , _d , yd ) => yd === 0 ? _d : ud + "@prettier-placeholder-" + rd ++ + "-id" + _d , "" ) , od = await Ra ( sd , { parser : "scss" } ) , ld = Gt$2 ( Ja , qa ) , cd = bp ( od , ld ) ; if ( ! cd ) throw new Error ( "Couldn't insert all the expressions" ) ; return [ "`" , f ( [ F , cd ] ) , E$1 , "`" ] } function bp ( Ra , qa ) { if ( ! w ( qa ) ) return Ra ; let Ja = 0 , ed = mt$1 ( Wt ( Ra ) , td => typeof td != "string" || ! td . includes ( "@prettier-placeholder" ) ? td : td . split ( /@prettier-placeholder-(\d+)-id/u ) . map ( ( rd , sd ) => sd % 2 === 0 ? Ie ( rd ) : ( Ja ++ , qa [ rd ] ) ) ) ; return qa . length === Ja ? ed : null } function Pp ( { node : Ra , parent : qa , grandparent : Ja } ) { return Ja && Ra . quasis && qa . type === "JSXExpressionContainer" && Ja . type === "JSXElement" && Ja . openingElement . name . name === "style" && Ja . openingElement . attributes . some ( ed => ed . type === "JSXAttribute" && ed . name . name === "jsx" ) || ( qa == null ? void 0 : qa . type ) === "TaggedTemplateExpression" && qa . tag . type === "Identifier" && qa . tag . name === "css" || ( qa == null ? void 0 : qa . type ) === "TaggedTemplateExpression" && qa . tag . type === "MemberExpression" && qa . tag . object . name === "css" && ( qa . tag . property . name === "global" || qa . tag . property . name === "resolve" ) } function Ur$1 ( Ra ) { return Ra . type === "Identifier" && Ra . name === "styled" } function Yu$1 ( Ra ) { return /^[A-Z]/u . test ( Ra . object . name ) && Ra . property . name === "extend" } function kp$1 ( { parent : Ra } ) { if ( ! Ra || Ra . type !== "TaggedTemplateExpression" ) return ! 1 ; let qa = Ra . tag . type === "ParenthesizedExpression" ? Ra . tag . expression : Ra . tag ; switch ( qa . type ) { case "MemberExpression" : return Ur$1 ( qa . object ) || Yu$1 ( qa ) ; case "CallExpression" : return Ur$1 ( qa . callee ) || qa . callee . type === "MemberExpression" && ( qa . callee . object . type === "MemberExpression" && ( Ur$1 ( qa . callee . object . object ) || Yu$1 ( qa . callee . object ) ) || qa . callee . object . type === " Cal
` ),gd=yd.length,Ed=rd[od],Td=gd>2&&yd[0].trim()===""&&yd[1].trim()==="",Od=gd>2&&yd[gd-1].trim()===""&&yd[gd-2].trim()==="",Rd=yd.every(Id=>/^ \s *(?:#[^ \n \r ]*)? $ /u.test(Id));if(!ud&&/#[^ \n \r ]* $ /u.test(yd[gd-1]))return null;let Nd=null;Rd?Nd=Op $ 1(yd):Nd=await Ra(_d,{parser:"graphql"}),Nd?(Nd=Wr $ 1(Nd,!1),!cd&&Td&&sd.push(""),sd.push(Nd),!ud&&Od&&sd.push("")):!cd&&!ud&&Td&&sd.push(""),Ed&&sd.push(Ed)}return[" ` ",f([F,P$1(F,sd)]),F," ` "]}function Op $ 1(Ra){let qa=[],Ja=!1,ed=Ra.map(td=>td.trim());for(let[td,rd]of ed.entries())rd!==""&&(ed[td-1]===""&&Ja?qa.push([F,rd]):qa.push(rd),Ja=!0);return qa.length===0?null:P $ 1(F,qa)}function _p({node:Ra,parent:qa}){return Gr $ 1({node:Ra,parent:qa},"GraphQL")||qa&&(qa.type==="TaggedTemplateExpression"&&(qa.tag.type==="MemberExpression"&&qa.tag.object.name==="graphql"&&qa.tag.property.name==="experimental"||qa.tag.type==="Identifier"&&(qa.tag.name==="gql"||qa.tag.name==="graphql"))||qa.type==="CallExpression"&&qa.callee.type==="Identifier"&&qa.callee.name==="graphql")}function jp(Ra){if(_p(Ra))return wp}var Vu $ 1=jp,ss $ 1=0;async function $ u $ 1(Ra,qa,Ja,ed,td){let{node:rd}=ed,sd=ss $ 1;ss $ 1=ss $ 1+1>>>0;let od=Rd=> ` PRETTIER _HTML _PLACEHOLDER _$ { Rd } _$ { sd } _IN _JS ` ,ld=rd.quasis.map((Rd,Nd,Id)=>Nd===Id.length-1?Rd.value.cooked:Rd.value.cooked+od(Nd)).join(""),cd=Gt $ 2(ed,Ja),ud=new RegExp(od(String.raw ` ( \ d + ) ` ),"gu"),_d=0,yd=await qa(ld,{parser:Ra,__onHtmlRoot(Rd){_d=Rd.children.length}}),gd=mt $ 1(yd,Rd=>{if(typeof Rd!="string")return Rd;let Nd=[],Id=Rd.split(ud);for(let Md=0;Md<Id.length;Md++){let Ld=Id[Md];if(Md%2===0){Ld&&(Ld=ts $ 1(Ld),td.__embeddedInHtml&&(Ld=N $ 1(!1,Ld,/< \/ (?=script \b )/giu,String.raw ` < \ / ` )),Nd.push(Ld));continue}let Pd=Number(Ld);Nd.push(cd[Pd])}return Nd}),Ed=/^ \s /u.test(ld)?" ":"",Td=/ \s $ /u.test(ld)?" ":"",Od=td.htmlWhitespaceSensitivity==="ignore"?F:Ed&&Td?x:null;return Od?l([" ` ",f([Od,l(gd)]),Od," ` "]):it $ 1({hug:!1},l([" ` ",Ed,_d>1?f(l(gd)):l(gd),Td," ` "]))}function vp(Ra){return Gr $ 1(Ra,"HTML")||Ra.match(qa=>qa.type==="TemplateLiteral",(qa,Ja)=>qa.type==="TaggedTemplateExpression"&&qa.tag.type==="Identifier"&&qa.tag.name==="html"&&Ja==="quasi")}var Mp $ 1= $ u $ 1.bind(void 0,"html"),Rp $ 1= $ u $ 1.bind(void 0,"angular");function Jp(Ra){if(vp(Ra))return Mp $ 1;if(Xu $ 2(Ra))return Rp $ 1}var Ku $ 1=Jp;async function qp(Ra,qa,Ja){let{node:ed}=Ja,td=N $ 1(!1,ed.quasis[0].value.raw,/((?: \\ \\ )*) \\ ` / gu , ( ld , cd ) => "\\" . repeat ( cd . length / 2 ) + "`" ) , rd = Wp ( td ) , sd = rd !== "" ; sd && ( td = N$1 ( ! 1 , td , new RegExp ( ` ^ ${ rd } ` , "gmu" ) , "" ) ) ; let od = Wr$1 ( await Ra ( td , { parser : "markdown" , _ _inJsTemplate : ! 0 } ) , ! 0 ) ; return [ "`" , sd ? f ( [ E$1 , od ] ) : [ Rr , du$1 ( od ) ] , E$1 , "`" ] } function Wp ( Ra ) { let qa = Ra . match ( /^([^\S\n]*)\S/mu ) ; return qa === null ? "" : qa [ 1 ] } function Gp ( Ra ) { if ( Up ( Ra ) ) return qp } function Up ( { node : Ra , parent : qa } ) { return ( qa == null ? void 0 : qa . type ) === "TaggedTemplateExpression" && Ra . quasis . length === 1 && qa . tag . type === "Identifier" && ( qa . tag . name === "md" || qa . tag . name === "markdown" ) } var zu = Gp ; function Np$1 ( Ra ) { let { node : qa } = Ra ; if ( qa . type !== "TemplateLiteral" || Xp ( qa ) ) return ; let Ja ; for ( let ed of [ Hu$1 , Vu$1 , Ku$1 , zu ] ) if ( Ja = ed ( Ra ) , ! ! Ja ) return qa . quasis . length === 1 && qa . quasis [ 0 ] . value . raw . trim ( ) === "" ? "``" : async ( ... td ) => { let rd = await Ja ( ... td ) ; return rd && it$1 ( { embed : ! 0 , ... rd . label } , rd ) } } function Xp ( { quasis : Ra } ) { return Ra . some ( ( { value : { cooked : qa } } ) => qa === null ) } var Qu$1 = Np$1 , Yp = /\*\/$/ , Hp = /^\/\*\*?/ , ri$2 = /^\s*(\/\*\*?(.|\r?\n)*?\*\/)/ , Vp$1 = /(^|\s+)\/\/([^\n\r]*)/g , Zu$2 = /^(\r?\n)+/ , $p$1 = /(?:^|\r?\n) *(@[^\n\r]*?) *\r?\n *(?![^\n\r@]*\/\/[^]*)([^\s@][^\n\r@]+?) *\r?\n/g , ei$1 = /(?:^|\r?\n) *@(\S+) *([^\n\r]*)/g , Kp$1 = /(\r?\n|^) *\* ?/g , ni$2 = [ ] ; function si$2 ( Ra ) { let qa = Ra . match ( ri$2 ) ; return qa ? qa [ 0 ] . trimStart ( ) : "" } function ui$1 ( Ra ) { let qa = Ra . match ( ri$2 ) , Ja = qa == null ? void 0 : qa [ 0 ] ; return Ja == null ? Ra : Ra . slice ( Ja . length ) } function ii$2 ( Ra ) { let qa = `
` ;Ra=N $ 1(!1,Ra.replace(Hp,"").replace(Yp,""),Kp $ 1," $ 1");let Ja="";for(;Ja!==Ra;)Ja=Ra,Ra=N $ 1(!1,Ra, $ p $ 1, ` $ { qa } $1 $2$ { qa } ` );Ra=Ra.replace(Zu $ 2,"").trimEnd();let ed=Object.create(null),td=N $ 1(!1,Ra,ei $ 1,"").replace(Zu $ 2,"").trimEnd(),rd;for(;rd=ei $ 1.exec(Ra);){let sd=N $ 1(!1,rd[2],Vp $ 1,"");if(typeof ed[rd[1]]=="string"||Array.isArray(ed[rd[1]])){let od=ed[rd[1]];ed[rd[1]]=[...ni $ 2,...Array.isArray(od)?od:[od],sd]}else ed[rd[1]]=sd}return{comments:td,pragmas:ed}}function ai $ 2({comments:Ra="",pragmas:qa={}}){let Ja= `
` ,ed="/**",td=" *",rd=" */",sd=Object.keys(qa),od=sd.flatMap(cd=>ti $ 2(cd,qa[cd])).map(cd=> ` $ { td } $ { cd } $ { Ja } ` ).join("");if(!Ra){if(sd.length===0)return"";if(sd.length===1&&!Array.isArray(qa[sd[0]])){let cd=qa[sd[0]];return ` $ { ed } $ { ti$2 ( sd [ 0 ] , cd ) [ 0 ] } $ { rd } ` }}let ld=Ra.split(Ja).map(cd=> ` $ { td } $ { cd } ` ).join(Ja)+Ja;return ed+Ja+(Ra?ld:"")+(Ra&&sd.length>0?td+Ja:"")+od+rd}function ti $ 2(Ra,qa){return[...ni $ 2,...Array.isArray(qa)?qa:[qa]].map(Ja=> ` @ $ { Ra } $ { Ja } ` .trim())}function zp $ 1(Ra){if(!Ra.startsWith("#!"))return"";let qa=Ra.indexOf( `
` );return qa===-1?Ra:Ra.slice(0,qa)}var oi $ 1=zp $ 1;function Qp(Ra){let qa=oi $ 1(Ra);qa&&(Ra=Ra.slice(qa.length+1));let Ja=si $ 2(Ra),{pragmas:ed,comments:td}=ii $ 2(Ja);return{shebang:qa,text:Ra,pragmas:ed,comments:td}}function pi $ 2(Ra){let{shebang:qa,text:Ja,pragmas:ed,comments:td}=Qp(Ra),rd=ui $ 1(Ja),sd=ai $ 2({pragmas:{format:"",...ed},comments:td.trimStart()});return(qa? ` $ { qa }
2024-09-03 08:22:14 +08:00
` :"")+sd+(rd.startsWith( `
2024-08-27 22:31:52 +08:00
` )? `
` : `
2024-09-08 17:22:36 +08:00
` )+rd}function Zp(Ra,qa){let{originalText:Ja,[Symbol.for("comments")]:ed,locStart:td,locEnd:rd,[Symbol.for("printedComments")]:sd}=qa,{node:od}=Ra,ld=td(od),cd=rd(od);for(let ud of ed)td(ud)>=ld&&rd(ud)<=cd&&sd.add(ud);return Ja.slice(ld,cd)}var ci $ 1=Zp;function us $ 1(Ra,qa){var Ja,ed,td,rd,sd,od,ld,cd,ud;if(Ra.isRoot)return!1;let{node:_d,key:yd,parent:gd}=Ra;if(qa.__isInHtmlInterpolation&&!qa.bracketSpacing&&nc $ 2(_d)&&or(Ra))return!0;if(ec $ 2(_d))return!1;if(_d.type==="Identifier"){if((Ja=_d.extra)!=null&&Ja.parenthesized&&/^PRETTIER_HTML_PLACEHOLDER_ \d +_ \d +_IN_JS $ /u.test(_d.name)||yd==="left"&&(_d.name==="async"&&!gd.await||_d.name==="let")&&gd.type==="ForOfStatement")return!0;if(_d.name==="let"){let Ed=(ed=Ra.findAncestor(Td=>Td.type==="ForOfStatement"))==null?void 0:ed.left;if(Ed&&ie $ 1(Ed,Td=>Td===_d))return!0}if(yd==="object"&&_d.name==="let"&&gd.type==="MemberExpression"&&gd.computed&&!gd.optional){let Ed=Ra.findAncestor(Od=>Od.type==="ExpressionStatement"||Od.type==="ForStatement"||Od.type==="ForInStatement"),Td=Ed?Ed.type==="ExpressionStatement"?Ed.expression:Ed.type==="ForStatement"?Ed.init:Ed.left:void 0;if(Td&&ie $ 1(Td,Od=>Od===_d))return!0}if(yd==="expression")switch(_d.name){case"await":case"interface":case"module":case"using":case"yield":case"let":case"component":case"hook":case"type":{let Ed=Ra.findAncestor(Td=>!Te $ 1(Td));if(Ed!==gd&&Ed.type==="ExpressionStatement")return!0}}return!1}if(_d.type==="ObjectExpression"||_d.type==="FunctionExpression"||_d.type==="ClassExpression"||_d.type==="DoExpression"){let Ed=(td=Ra.findAncestor(Td=>Td.type==="ExpressionStatement"))==null?void 0:td.expression;if(Ed&&ie $ 1(Ed,Td=>Td===_d))return!0}if(_d.type==="ObjectExpression"){let Ed=(rd=Ra.findAncestor(Td=>Td.type==="ArrowFunctionExpression"))==null?void 0:rd.body;if(Ed&&Ed.type!=="SequenceExpression"&&Ed.type!=="AssignmentExpression"&&ie $ 1(Ed,Td=>Td===_d))return!0}switch(gd.type){case"ParenthesizedExpression":return!1;case"ClassDeclaration":case"ClassExpression":if(yd==="superClass"&&(_d.type==="ArrowFunctionExpression"||_d.type==="AssignmentExpression"||_d.type==="AwaitExpression"||_d.type==="BinaryExpression"||_d.type==="ConditionalExpression"||_d.type==="LogicalExpression"||_d.type==="NewExpression"||_d.type==="ObjectExpression"||_d.type==="SequenceExpression"||_d.type==="TaggedTemplateExpression"||_d.type==="UnaryExpression"||_d.type==="UpdateExpression"||_d.type==="YieldExpression"||_d.type==="TSNonNullExpression"||_d.type==="ClassExpression"&&w(_d.decorators)))return!0;break;case"ExportDefaultDeclaration":return li $ 2(Ra,qa)||_d.type==="SequenceExpression";case"Decorator":if(yd==="expression"&&!uc $ 1(_d))return!0;break;case"TypeAnnotation":if(Ra.match(void 0,void 0,(Ed,Td)=>Td==="returnType"&&Ed.type==="ArrowFunctionExpression")&&rc $ 1(_d))return!0;break;case"BinaryExpression":if(yd==="left"&&(gd.operator==="in"||gd.operator==="instanceof")&&_d.type==="UnaryExpression")return!0;break;case"VariableDeclarator":if(yd==="init"&&Ra.match(void 0,void 0,(Ed,Td)=>Td==="declarations"&&Ed.type==="VariableDeclaration",(Ed,Td)=>Td==="left"&&Ed.type==="ForInStatement"))return!0;break}switch(_d.type){case"UpdateExpression":if(gd.type==="UnaryExpression")return _d.prefix&&(_d.operator==="++"&&gd.operator==="+"||_d.operator==="--"&&gd.operator==="-");case"UnaryExpression":switch(gd.type){case"UnaryExpression":return _d.operator===gd.operator&&(_d.operator==="+"||_d.operator==="-");case"BindExpression":return!0;case"MemberExpression":case"OptionalMemberExpression":return yd==="object";case"TaggedTemplateExpression":return!0;case"NewExpression":case"CallExpression":case"OptionalCallExpression":return yd==="callee";case"BinaryExpression":return yd==="left"&&gd.operator==="**";case"TSNonNullExpression":return!0;default:return!1}case"BinaryExpression":if(gd.type==="UpdateExpression"||_d.operator==="in"&&tc $ 1(Ra))return!0;if(_d.operator==="|>"&&(sd=_d.extra)!=null&&sd.parenthesized){let Ed=Ra.grandparent;if(Ed.type==="BinaryExpression"&&Ed.operator==="|>")return!0}case"TSTypeAssertion":case"TSAsExpression":case"TSSatisfiesExpression":case"As
\ r ` ),ms $ 1=Ra=>Ra===""||Ra===x||Ra===F||Ra===E $ 1;function cc(Ra,qa,Ja){var ed,td,rd;let{node:sd}=Ra;if(sd.type==="JSXElement"&&gc(sd))return[Ja("openingElement"),Ja("closingElement")];let od=sd.type==="JSXElement"?Ja("openingElement"):Ja("openingFragment"),ld=sd.type==="JSXElement"?Ja("closingElement"):Ja("closingFragment");if(sd.children.length===1&&sd.children[0].type==="JSXExpressionContainer"&&(sd.children[0].expression.type==="TemplateLiteral"||sd.children[0].expression.type==="TaggedTemplateExpression"))return[od,...Ra.map(Ja,"children"),ld];sd.children=sd.children.map(Pd=>Sc(Pd)?{type:"JSXText",value:" ",raw:" "}:Pd);let cd=sd.children.some(X),ud=sd.children.filter(Pd=>Pd.type==="JSXExpressionContainer").length>1,_d=sd.type==="JSXElement"&&sd.openingElement.attributes.length>1,yd=ne $ 1(od)||cd||_d||ud,gd=Ra.parent.rootMarker==="mdx",Ed=qa.singleQuote?"{' '}":'{" "}',Td=gd?" ":b([Ed,E $ 1]," "),Od=((td=(ed=sd.openingElement)==null?void 0:ed.name)==null?void 0:td.name)==="fbt",Rd=lc $ 1(Ra,qa,Ja,Td,Od),Nd=sd.children.some(Pd=>pr(Pd));for(let Pd=Rd.length-2;Pd>=0;Pd--){let qd=Rd[Pd]===""&&Rd[Pd+1]==="",Yd=Rd[Pd]===F&&Rd[Pd+1]===""&&Rd[Pd+2]===F,Ud=(Rd[Pd]===E $ 1||Rd[Pd]===F)&&Rd[Pd+1]===""&&Rd[Pd+2]===Td,Hd=Rd[Pd]===Td&&Rd[Pd+1]===""&&(Rd[Pd+2]===E $ 1||Rd[Pd+2]===F),zd=Rd[Pd]===Td&&Rd[Pd+1]===""&&Rd[Pd+2]===Td,Jd=Rd[Pd]===E $ 1&&Rd[Pd+1]===""&&Rd[Pd+2]===F||Rd[Pd]===F&&Rd[Pd+1]===""&&Rd[Pd+2]===E $ 1;Yd&&Nd||qd||Ud||zd||Jd?Rd.splice(Pd,2):Hd&&Rd.splice(Pd+1,2)}for(;Rd.length>0&&ms $ 1(O $ 1(!1,Rd,-1));)Rd.pop();for(;Rd.length>1&&ms $ 1(Rd[0])&&ms $ 1(Rd[1]);)Rd.shift(),Rd.shift();let Id=[];for(let[Pd,qd]of Rd.entries()){if(qd===Td){if(Pd===1&&Rd[Pd-1]===""){if(Rd.length===2){Id.push(Ed);continue}Id.push([Ed,F]);continue}else if(Pd===Rd.length-1){Id.push(Ed);continue}else if(Rd[Pd-1]===""&&Rd[Pd-2]===F){Id.push(Ed);continue}}Id.push(qd),ne $ 1(qd)&&(yd=!0)}let Md=Nd?qt $ 1(Id):l(Id,{shouldBreak:!0});if(((rd=qa.cursorNode)==null?void 0:rd.type)==="JSXText"&&sd.children.includes(qa.cursorNode)&&(Md=[Un $ 1,Md,Un $ 1]),gd)return Md;let Ld=l([od,f([F,Md]),F,ld]);return yd?Ld:ze $ 1([l([od,...Rd,ld]),Ld])}function lc $ 1(Ra,qa,Ja,ed,td){let rd=[];return Ra.each(({node:sd,next:od})=>{if(sd.type==="JSXText"){let ld=fe $ 1(sd);if(pr(sd)){let cd=Nr.split(ld,!0);cd[0]===""&&(rd.push(""),cd.shift(),/ \n /u.test(cd[0])?rd.push(fi $ 1(td,cd[1],sd,od)):rd.push(ed),cd.shift());let ud;if(O $ 1(!1,cd,-1)===""&&(cd.pop(),ud=cd.pop()),cd.length===0)return;for(let[_d,yd]of cd.entries())_d%2===1?rd.push(x):rd.push(yd);ud!==void 0?/ \n /u.test(ud)?rd.push(fi $ 1(td,O $ 1(!1,rd,-1),sd,od)):rd.push(ed):rd.push(Di $ 1(td,O $ 1(!1,rd,-1),sd,od))}else/ \n /u.test(ld)?ld.match(/ \n /gu).length>1&&rd.push("",F):rd.push("",ed)}else{let ld=Ja();if(rd.push(ld),od&&pr(od)){let cd=Nr.trim(fe $ 1(od)),[ud]=Nr.split(cd);rd.push(Di $ 1(td,ud,sd,od))}else rd.push(F)}},"children"),rd}function Di $ 1(Ra,qa,Ja,ed){return Ra?"":Ja.type==="JSXElement"&&!Ja.closingElement||(ed==null?void 0:ed.type)==="JSXElement"&&!ed.closingElement?qa.length===1?E $ 1:F:E $ 1}function fi $ 1(Ra,qa,Ja,ed){return Ra?F:qa.length===1?Ja.type==="JSXElement"&&!Ja.closingElement||(ed==null?void 0:ed.type)==="JSXElement"&&!ed.closingElement?F:E $ 1:F}var mc=new Set(["ArrayExpression","TupleExpression","JSXAttribute","JSXElement","JSXExpressionContainer","JSXFragment","ExpressionStatement","CallExpression","OptionalCallExpression","ConditionalExpression","JsExpressionRoot"]);function yc(Ra,qa,Ja){let{parent:ed}=Ra;if(mc.has(ed.type))return qa;let td=Ra.match(void 0,sd=>sd.type==="ArrowFunctionExpression",L $ 1,sd=>sd.type==="JSXExpressionContainer"),rd=Be $ 1(Ra,Ja);return l([rd?"":b("("),f([E $ 1,qa]),E $ 1,rd?"":b(")")],{shouldBreak:td})}function Dc(Ra,qa,Ja){let{node:ed}=Ra,td=[];if(td.push(Ja("name")),ed.value){let rd;if(Q $ 2(ed.value)){let sd=fe $ 1(ed.value),od=N $ 1(!1,N $ 1(!1,sd.slice(1,-1),"'","'"),""",'"'),ld=xr(od,qa.jsxSingleQuote);od=ld==='"'?N $ 1(!1,od,'"',"""):N $ 1(!1,od,"'","'"),rd=Ra.call(()=>ye $ 1(Ra,Ie(ld+od+ld),qa),"value")}else rd=Ja("value");td.push("=",rd)}return td}function fc(Ra,qa,Ja){let{node:ed}=Ra,td=(rd,sd)=>rd.type==
2024-09-03 08:22:14 +08:00
` )&&!sd&&!d(rd.attributes[0]))return l(["<",Ja("name"),rd.typeArguments?Ja("typeArguments"):Ja("typeParameters")," ",...Ra.map(Ja,"attributes"),rd.selfClosing?" />":">"]);let od=(td=rd.attributes)==null?void 0:td.some(cd=>Q $ 2(cd.value)&&cd.value.value.includes( `
2024-09-08 17:22:36 +08:00
` )),ld=qa.singleAttributePerLine&&rd.attributes.length>1?F:x;return l(["<",Ja("name"),rd.typeArguments?Ja("typeArguments"):Ja("typeParameters"),f(Ra.map(()=>[ld,Ja()],"attributes")),...Fc(rd,qa,sd)],{shouldBreak:od})}function Fc(Ra,qa,Ja){return Ra.selfClosing?[x,"/>"]:Cc(Ra,qa,Ja)?[">"]:[E $ 1,">"]}function Cc(Ra,qa,Ja){let ed=Ra.attributes.length>0&&d(O $ 1(!1,Ra.attributes,-1),g $ 2.Trailing);return Ra.attributes.length===0&&!Ja||(qa.bracketSameLine||qa.jsxBracketSameLine)&&(!Ja||Ra.attributes.length>0)&&!ed}function Ac(Ra,qa,Ja){let{node:ed}=Ra,td=[];td.push("</");let rd=Ja("name");return d(ed.name,g $ 2.Leading|g $ 2.Line)?td.push(f([F,rd]),F):d(ed.name,g $ 2.Leading|g $ 2.Block)?td.push(" ",rd):td.push(rd),td.push(">"),td}function Tc(Ra,qa){let{node:Ja}=Ra,ed=d(Ja),td=d(Ja,g $ 2.Line),rd=Ja.type==="JSXOpeningFragment";return[rd?"<":"</",f([td?F:ed&&!rd?" ":"",M $ 1(Ra,qa)]),td?F:"",">"]}function dc(Ra,qa,Ja){let ed=ye $ 1(Ra,cc(Ra,qa,Ja),qa);return yc(Ra,ed,qa)}function xc(Ra,qa){let{node:Ja}=Ra,ed=d(Ja,g $ 2.Line);return[M $ 1(Ra,qa,{indent:ed}),ed?F:""]}function hc(Ra,qa,Ja){let{node:ed}=Ra;return["{",Ra.call(({node:td})=>{let rd=["...",Ja()];return!d(td)||!zn $ 1(Ra)?rd:[f([E $ 1,ye $ 1(Ra,rd,qa)]),E $ 1]},ed.type==="JSXSpreadAttribute"?"argument":"expression"),"}"]}function Ei $ 1(Ra,qa,Ja){let{node:ed}=Ra;if(ed.type.startsWith("JSX"))switch(ed.type){case"JSXAttribute":return Dc(Ra,qa,Ja);case"JSXIdentifier":return ed.name;case"JSXNamespacedName":return P $ 1(":",[Ja("namespace"),Ja("name")]);case"JSXMemberExpression":return P $ 1(".",[Ja("object"),Ja("property")]);case"JSXSpreadAttribute":case"JSXSpreadChild":return hc(Ra,qa,Ja);case"JSXExpressionContainer":return fc(Ra,qa,Ja);case"JSXFragment":case"JSXElement":return dc(Ra,qa,Ja);case"JSXOpeningElement":return Ec(Ra,qa,Ja);case"JSXClosingElement":return Ac(Ra,qa,Ja);case"JSXOpeningFragment":case"JSXClosingFragment":return Tc(Ra,qa);case"JSXEmptyExpression":return xc(Ra,qa);case"JSXText":throw new Error("JSXText should be handled by JSXElement");default:throw new Me $ 2(ed,"JSX")}}function gc(Ra){if(Ra.children.length===0)return!0;if(Ra.children.length>1)return!1;let qa=Ra.children[0];return qa.type==="JSXText"&&!pr(qa)}function pr(Ra){return Ra.type==="JSXText"&&(Nr.hasNonWhitespaceCharacter(fe $ 1(Ra))||!/ \n /u.test(fe $ 1(Ra)))}function Sc(Ra){return Ra.type==="JSXExpressionContainer"&&Q $ 2(Ra.expression)&&Ra.expression.value===" "&&!d(Ra.expression)}function Fi(Ra){let{node:qa,parent:Ja}=Ra;if(!X(qa)||!X(Ja))return!1;let{index:ed,siblings:td}=Ra,rd;for(let sd=ed;sd>0;sd--){let od=td[sd-1];if(!(od.type==="JSXText"&&!pr(od))){rd=od;break}}return(rd==null?void 0:rd.type)==="JSXExpressionContainer"&&rd.expression.type==="JSXEmptyExpression"&&Bt $ 2(rd.expression)}function Bc(Ra){return Bt $ 2(Ra.node)||Fi(Ra)}var Xr $ 1=Bc,bc=0;function Yr $ 2(Ra,qa,Ja){var ed;let{node:td,parent:rd,grandparent:sd,key:od}=Ra,ld=od!=="body"&&(rd.type==="IfStatement"||rd.type==="WhileStatement"||rd.type==="SwitchStatement"||rd.type==="DoWhileStatement"),cd=td.operator==="|>"&&((ed=Ra.root.extra)==null?void 0:ed.__isUsingHackPipeline),ud=ys $ 1(Ra,Ja,qa,!1,ld);if(ld)return ud;if(cd)return l(ud);if(L $ 1(rd)&&rd.callee===td||rd.type==="UnaryExpression"||q $ 1(rd)&&!rd.computed)return l([f([E $ 1,...ud]),E $ 1]);let _d=rd.type==="ReturnStatement"||rd.type==="ThrowStatement"||rd.type==="JSXExpressionContainer"&&sd.type==="JSXAttribute"||td.operator!=="|"&&rd.type==="JsExpressionRoot"||td.type!=="NGPipeExpression"&&(rd.type==="NGRoot"&&qa.parser==="__ng_binding"||rd.type==="NGMicrosyntaxExpression"&&sd.type==="NGMicrosyntax"&&sd.body.length===1)||td===rd.body&&rd.type==="ArrowFunctionExpression"||td!==rd.body&&rd.type==="ForStatement"||rd.type==="ConditionalExpression"&&sd.type!=="ReturnStatement"&&sd.type!=="ThrowStatement"&&!L $ 1(sd)||rd.type==="TemplateLiteral",yd=rd.type==="AssignmentExpression"||rd.type==="VariableDeclarator"||rd.type==="ClassProperty"||rd.type==="PropertyDefinition"||rd.type==="TSAbstractPropertyDefinition"||rd.type==="ClassPrivateProperty"||Ae $ 1(rd),gd=De(td.left)&&nr(td.operator,td.left.operator);if(_d||Ut $ 1(td)&&!gd||!Ut $
2024-09-03 08:22:14 +08:00
` +Nd+yd("^")}return" "+gd(Rd)+Ed}).join( `
` )}toString(){let sd=this.showSourceCode();return sd&&(sd= `
2024-08-30 15:19:18 +08:00
2024-09-03 08:22:14 +08:00
` +sd+ `
` ),this.name+": "+this.message+sd}};qa.exports=td,td.default=td}), $ t $ 1=y((Ra,qa)=>{var Ja={after: `
2024-08-30 15:19:18 +08:00
` ,beforeClose: `
2024-08-27 22:31:52 +08:00
` ,beforeComment: `
2024-08-30 15:19:18 +08:00
` ,beforeDecl: `
` ,beforeOpen:" ",beforeRule: `
2024-09-03 08:22:14 +08:00
` ,colon:": ",commentLeft:" ",commentRight:" ",emptyBody:"",indent:" ",semicolon:!1};function ed(rd){return rd[0].toUpperCase()+rd.slice(1)}var td=class{constructor(rd){this.builder=rd}atrule(rd,sd){let od="@"+rd.name,ld=rd.params?this.rawValue(rd,"params"):"";if(typeof rd.raws.afterName<"u"?od+=rd.raws.afterName:ld&&(od+=" "),rd.nodes)this.block(rd,od+ld);else{let cd=(rd.raws.between||"")+(sd?";":"");this.builder(od+ld+cd,rd)}}beforeAfter(rd,sd){let od;rd.type==="decl"?od=this.raw(rd,null,"beforeDecl"):rd.type==="comment"?od=this.raw(rd,null,"beforeComment"):sd==="before"?od=this.raw(rd,null,"beforeRule"):od=this.raw(rd,null,"beforeClose");let ld=rd.parent,cd=0;for(;ld&&ld.type!=="root";)cd+=1,ld=ld.parent;if(od.includes( `
` )){let ud=this.raw(rd,null,"indent");if(ud.length)for(let _d=0;_d<cd;_d++)od+=ud}return od}block(rd,sd){let od=this.raw(rd,"between","beforeOpen");this.builder(sd+od+"{",rd,"start");let ld;rd.nodes&&rd.nodes.length?(this.body(rd),ld=this.raw(rd,"after")):ld=this.raw(rd,"after","emptyBody"),ld&&this.builder(ld),this.builder("}",rd,"end")}body(rd){let sd=rd.nodes.length-1;for(;sd>0&&rd.nodes[sd].type==="comment";)sd-=1;let od=this.raw(rd,"semicolon");for(let ld=0;ld<rd.nodes.length;ld++){let cd=rd.nodes[ld],ud=this.raw(cd,"before");ud&&this.builder(ud),this.stringify(cd,sd!==ld||od)}}comment(rd){let sd=this.raw(rd,"left","commentLeft"),od=this.raw(rd,"right","commentRight");this.builder("/*"+sd+rd.text+od+"*/",rd)}decl(rd,sd){let od=this.raw(rd,"between","colon"),ld=rd.prop+od+this.rawValue(rd,"value");rd.important&&(ld+=rd.raws.important||" !important"),sd&&(ld+=";"),this.builder(ld,rd)}document(rd){this.body(rd)}raw(rd,sd,od){let ld;if(od||(od=sd),sd&&(ld=rd.raws[sd],typeof ld<"u"))return ld;let cd=rd.parent;if(od==="before"&&(!cd||cd.type==="root"&&cd.first===rd||cd&&cd.type==="document"))return"";if(!cd)return Ja[od];let ud=rd.root();if(ud.rawCache||(ud.rawCache={}),typeof ud.rawCache[od]<"u")return ud.rawCache[od];if(od==="before"||od==="after")return this.beforeAfter(rd,od);{let _d="raw"+ed(od);this[_d]?ld=this[_d](ud,rd):ud.walk(yd=>{if(ld=yd.raws[sd],typeof ld<"u")return!1})}return typeof ld>"u"&&(ld=Ja[od]),ud.rawCache[od]=ld,ld}rawBeforeClose(rd){let sd;return rd.walk(od=>{if(od.nodes&&od.nodes.length>0&&typeof od.raws.after<"u")return sd=od.raws.after,sd.includes( `
` )&&(sd=sd.replace(/[^ \n ]+ $ /,"")),!1}),sd&&(sd=sd.replace(/ \S /g,"")),sd}rawBeforeComment(rd,sd){let od;return rd.walkComments(ld=>{if(typeof ld.raws.before<"u")return od=ld.raws.before,od.includes( `
` )&&(od=od.replace(/[^ \n ]+ $ /,"")),!1}),typeof od>"u"?od=this.raw(sd,null,"beforeDecl"):od&&(od=od.replace(/ \S /g,"")),od}rawBeforeDecl(rd,sd){let od;return rd.walkDecls(ld=>{if(typeof ld.raws.before<"u")return od=ld.raws.before,od.includes( `
` )&&(od=od.replace(/[^ \n ]+ $ /,"")),!1}),typeof od>"u"?od=this.raw(sd,null,"beforeRule"):od&&(od=od.replace(/ \S /g,"")),od}rawBeforeOpen(rd){let sd;return rd.walk(od=>{if(od.type!=="decl"&&(sd=od.raws.between,typeof sd<"u"))return!1}),sd}rawBeforeRule(rd){let sd;return rd.walk(od=>{if(od.nodes&&(od.parent!==rd||rd.first!==od)&&typeof od.raws.before<"u")return sd=od.raws.before,sd.includes( `
` )&&(sd=sd.replace(/[^ \n ]+ $ /,"")),!1}),sd&&(sd=sd.replace(/ \S /g,"")),sd}rawColon(rd){let sd;return rd.walkDecls(od=>{if(typeof od.raws.between<"u")return sd=od.raws.between.replace(/[^ \s :]/g,""),!1}),sd}rawEmptyBody(rd){let sd;return rd.walk(od=>{if(od.nodes&&od.nodes.length===0&&(sd=od.raws.after,typeof sd<"u"))return!1}),sd}rawIndent(rd){if(rd.raws.indent)return rd.raws.indent;let sd;return rd.walk(od=>{let ld=od.parent;if(ld&&ld!==rd&&ld.parent&&ld.parent===rd&&typeof od.raws.before<"u"){let cd=od.raws.before.split( `
2024-09-08 17:22:36 +08:00
` );return sd=cd[cd.length-1],sd=sd.replace(/ \S /g,""),!1}}),sd}rawSemicolon(rd){let sd;return rd.walk(od=>{if(od.nodes&&od.nodes.length&&od.last.type==="decl"&&(sd=od.raws.semicolon,typeof sd<"u"))return!1}),sd}rawValue(rd,sd){let od=rd[sd],ld=rd.raws[sd];return ld&&ld.value===od?ld.raw:od}root(rd){this.body(rd),rd.raws.after&&this.builder(rd.raws.after)}rule(rd){this.block(rd,this.rawValue(rd,"selector")),rd.raws.ownSemicolon&&this.builder(rd.raws.ownSemicolon,rd,"end")}stringify(rd,sd){if(!this[rd.type])throw new Error("Unknown AST node type "+rd.type+". Maybe you need to change PostCSS stringifier.");this[rd.type](rd,sd)}};qa.exports=td,td.default=td}),it=y((Ra,qa)=>{var Ja= $ t $ 1();function ed(td,rd){new Ja(rd).stringify(td)}qa.exports=ed,ed.default=ed}),at $ 1=y((Ra,qa)=>{var{isClean:Ja,my:ed}=Ut(),td=Ft $ 1(),rd= $ t $ 1(),sd=it();function od(cd,ud){let _d=new cd.constructor;for(let yd in cd){if(!Object.prototype.hasOwnProperty.call(cd,yd)||yd==="proxyCache")continue;let gd=cd[yd],Ed=typeof gd;yd==="parent"&&Ed==="object"?ud&&(_d[yd]=ud):yd==="source"?_d[yd]=gd:Array.isArray(gd)?_d[yd]=gd.map(Td=>od(Td,_d)):(Ed==="object"&&gd!==null&&(gd=od(gd)),_d[yd]=gd)}return _d}var ld=class{constructor(cd={}){this.raws={},this[Ja]=!1,this[ed]=!0;for(let ud in cd)if(ud==="nodes"){this.nodes=[];for(let _d of cd[ud])typeof _d.clone=="function"?this.append(_d.clone()):this.append(_d)}else this[ud]=cd[ud]}addToError(cd){if(cd.postcssNode=this,cd.stack&&this.source&&/ \n \s {4}at /.test(cd.stack)){let ud=this.source;cd.stack=cd.stack.replace(/ \n \s {4}at /, ` $ & $ { ud . input . from } : $ { ud . start . line } : $ { ud . start . column } $ & ` )}return cd}after(cd){return this.parent.insertAfter(this,cd),this}assign(cd={}){for(let ud in cd)this[ud]=cd[ud];return this}before(cd){return this.parent.insertBefore(this,cd),this}cleanRaws(cd){delete this.raws.before,delete this.raws.after,cd||delete this.raws.between}clone(cd={}){let ud=od(this);for(let _d in cd)ud[_d]=cd[_d];return ud}cloneAfter(cd={}){let ud=this.clone(cd);return this.parent.insertAfter(this,ud),ud}cloneBefore(cd={}){let ud=this.clone(cd);return this.parent.insertBefore(this,ud),ud}error(cd,ud={}){if(this.source){let{end:_d,start:yd}=this.rangeBy(ud);return this.source.input.error(cd,{column:yd.column,line:yd.line},{column:_d.column,line:_d.line},ud)}return new td(cd)}getProxyProcessor(){return{get(cd,ud){return ud==="proxyOf"?cd:ud==="root"?()=>cd.root().toProxy():cd[ud]},set(cd,ud,_d){return cd[ud]===_d||(cd[ud]=_d,(ud==="prop"||ud==="value"||ud==="name"||ud==="params"||ud==="important"||ud==="text")&&cd.markDirty()),!0}}}markDirty(){if(this[Ja]){this[Ja]=!1;let cd=this;for(;cd=cd.parent;)cd[Ja]=!1}}next(){if(!this.parent)return;let cd=this.parent.index(this);return this.parent.nodes[cd+1]}positionBy(cd,ud){let _d=this.source.start;if(cd.index)_d=this.positionInside(cd.index,ud);else if(cd.word){ud=this.toString();let yd=ud.indexOf(cd.word);yd!==-1&&(_d=this.positionInside(yd,ud))}return _d}positionInside(cd,ud){let _d=ud||this.toString(),yd=this.source.start.column,gd=this.source.start.line;for(let Ed=0;Ed<cd;Ed++)_d[Ed]=== `
` ?(yd=1,gd+=1):yd+=1;return{column:yd,line:gd}}prev(){if(!this.parent)return;let cd=this.parent.index(this);return this.parent.nodes[cd-1]}rangeBy(cd){let ud={column:this.source.start.column,line:this.source.start.line},_d=this.source.end?{column:this.source.end.column+1,line:this.source.end.line}:{column:ud.column+1,line:ud.line};if(cd.word){let yd=this.toString(),gd=yd.indexOf(cd.word);gd!==-1&&(ud=this.positionInside(gd,yd),_d=this.positionInside(gd+cd.word.length,yd))}else cd.start?ud={column:cd.start.column,line:cd.start.line}:cd.index&&(ud=this.positionInside(cd.index)),cd.end?_d={column:cd.end.column,line:cd.end.line}:typeof cd.endIndex=="number"?_d=this.positionInside(cd.endIndex):cd.index&&(_d=this.positionInside(cd.index+1));return(_d.line<ud.line||_d.line===ud.line&&_d.column<=ud.column)&&(_d={column:ud.column+1,line:ud.line}),{end:_d,start:ud}}raw(cd,ud){return new rd().raw(this,cd,ud)}remove(){return this.parent&&this.parent.removeChild(this),this.parent=void 0,this}replaceWith(...cd){if(this.parent){let ud=this,_d=!1;for(let yd of cd)yd===this?_d=!0:_d?(this.parent.insertAfter(ud,yd),ud=yd):this.parent.insertBefore(ud,yd);_d||this.remove()}return this}root(){let cd=this;for(;cd.parent&&cd.parent.type!=="document";)cd=cd.parent;return cd}toJSON(cd,ud){let _d={},yd=ud==null;ud=ud||new Map;let gd=0;for(let Ed in this){if(!Object.prototype.hasOwnProperty.call(this,Ed)||Ed==="parent"||Ed==="proxyCache")continue;let Td=this[Ed];if(Array.isArray(Td))_d[Ed]=Td.map(Od=>typeof Od=="object"&&Od.toJSON?Od.toJSON(null,ud):Od);else if(typeof Td=="object"&&Td.toJSON)_d[Ed]=Td.toJSON(null,ud);else if(Ed==="source"){let Od=ud.get(Td.input);Od==null&&(Od=gd,ud.set(Td.input,gd),gd++),_d[Ed]={end:Td.end,inputId:Od,start:Td.start}}else _d[Ed]=Td}return yd&&(_d.inputs=[...ud.keys()].map(Ed=>Ed.toJSON())),_d}toProxy(){return this.proxyCache||(this.proxyCache=new Proxy(this,this.getProxyProcessor())),this.proxyCache}toString(cd=sd){cd.stringify&&(cd=cd.stringify);let ud="";return cd(this,_d=>{ud+=_d}),ud}warn(cd,ud,_d){let yd={node:this};for(let gd in _d)yd[gd]=_d[gd];return cd.warn(ud,yd)}get proxyOf(){return this}};qa.exports=ld,ld.default=ld}),lt=y((Ra,qa)=>{var Ja=at $ 1(),ed=class extends Ja{constructor(td){td&&typeof td.value<"u"&&typeof td.value!="string"&&(td={...td,value:String(td.value)}),super(td),this.type="decl"}get variable(){return this.prop.startsWith("--")||this.prop[0]===" $ "}};qa.exports=ed,ed.default=ed}),Oe=y((Ra,qa)=>{var Ja=at $ 1(),ed=class extends Ja{constructor(td){super(td),this.type="comment"}};qa.exports=ed,ed.default=ed}),re=y((Ra,qa)=>{var{isClean:Ja,my:ed}=Ut(),td=lt(),rd=Oe(),sd=at $ 1(),od,ld,cd,ud;function _d(Ed){return Ed.map(Td=>(Td.nodes&&(Td.nodes=_d(Td.nodes)),delete Td.source,Td))}function yd(Ed){if(Ed[Ja]=!1,Ed.proxyOf.nodes)for(let Td of Ed.proxyOf.nodes)yd(Td)}var gd=class pS extends sd{append(...Td){for(let Od of Td){let Rd=this.normalize(Od,this.last);for(let Nd of Rd)this.proxyOf.nodes.push(Nd)}return this.markDirty(),this}cleanRaws(Td){if(super.cleanRaws(Td),this.nodes)for(let Od of this.nodes)Od.cleanRaws(Td)}each(Td){if(!this.proxyOf.nodes)return;let Od=this.getIterator(),Rd,Nd;for(;this.indexes[Od]<this.proxyOf.nodes.length&&(Rd=this.indexes[Od],Nd=Td(this.proxyOf.nodes[Rd],Rd),Nd!==!1);)this.indexes[Od]+=1;return delete this.indexes[Od],Nd}every(Td){return this.nodes.every(Td)}getIterator(){this.lastEach||(this.lastEach=0),this.indexes||(this.indexes={}),this.lastEach+=1;let Td=this.lastEach;return this.indexes[Td]=0,Td}getProxyProcessor(){return{get(Td,Od){return Od==="proxyOf"?Td:Td[Od]?Od==="each"||typeof Od=="string"&&Od.startsWith("walk")?(...Rd)=>Td[Od](...Rd.map(Nd=>typeof Nd=="function"?(Id,Md)=>Nd(Id.toProxy(),Md):Nd)):Od==="every"||Od==="some"?Rd=>Td[Od]((Nd,...Id)=>Rd(Nd.toProxy(),...Id)):Od==="root"?()=>Td.root().toProxy():Od==="nodes"?Td.nodes.map(Rd=>Rd.toProxy()):Od==="first"||Od==="last"?Td[Od].toProxy():Td[Od]:Td[Od]},set(Td,Od,Rd){return Td[Od]===Rd||(Td[Od]=Rd,(Od==="name"||Od==="params"||Od==="selector")&&Td.markDirty()),!0}}}index(Td){return typeof Td=="number"?Td:
` ," "];return Ja.split(ed,td)},split(ed,td,rd){let sd=[],od="",ld=!1,cd=0,ud=!1,_d="",yd=!1;for(let gd of ed)yd?yd=!1:gd===" \\ "?yd=!0:ud?gd===_d&&(ud=!1):gd==='"'||gd==="'"?(ud=!0,_d=gd):gd==="("?cd+=1:gd===")"?cd>0&&(cd-=1):cd===0&&td.includes(gd)&&(ld=!0),ld?(od!==""&&sd.push(od.trim()),od="",ld=!1):od+=gd;return(rd||od!=="")&&sd.push(od.trim()),sd}};qa.exports=Ja,Ja.default=Ja}),jt=y((Ra,qa)=>{var Ja=re(),ed=us(),td=class extends Ja{constructor(rd){super(rd),this.type="rule",this.nodes||(this.nodes=[])}get selectors(){return ed.comma(this.selector)}set selectors(rd){let sd=this.selector?this.selector.match(/, \s */):null,od=sd?sd[0]:","+this.raw("between","beforeOpen");this.selector=rd.join(od)}};qa.exports=td,td.default=td,Ja.registerRule(td)}),Ht $ 1=y((Ra,qa)=>{var Ja=lt(),ed=Vt $ 1(),td=Oe(),rd=Gt $ 1(),sd=Ae(),od=jt(),ld={empty:!0,space:!0};function cd(_d){for(let yd=_d.length-1;yd>=0;yd--){let gd=_d[yd],Ed=gd[3]||gd[2];if(Ed)return Ed}}var ud=class{constructor(_d){this.input=_d,this.root=new sd,this.current=this.root,this.spaces="",this.semicolon=!1,this.createTokenizer(),this.root.source={input:_d,start:{column:1,line:1,offset:0}}}atrule(_d){let yd=new rd;yd.name=_d[1].slice(1),yd.name===""&&this.unnamedAtrule(yd,_d),this.init(yd,_d[2]);let gd,Ed,Td,Od=!1,Rd=!1,Nd=[],Id=[];for(;!this.tokenizer.endOfFile();){if(_d=this.tokenizer.nextToken(),gd=_d[0],gd==="("||gd==="["?Id.push(gd==="("?")":"]"):gd==="{"&&Id.length>0?Id.push("}"):gd===Id[Id.length-1]&&Id.pop(),Id.length===0)if(gd===";"){yd.source.end=this.getPosition(_d[2]),yd.source.end.offset++,this.semicolon=!0;break}else if(gd==="{"){Rd=!0;break}else if(gd==="}"){if(Nd.length>0){for(Td=Nd.length-1,Ed=Nd[Td];Ed&&Ed[0]==="space";)Ed=Nd[--Td];Ed&&(yd.source.end=this.getPosition(Ed[3]||Ed[2]),yd.source.end.offset++)}this.end(_d);break}else Nd.push(_d);else Nd.push(_d);if(this.tokenizer.endOfFile()){Od=!0;break}}yd.raws.between=this.spacesAndCommentsFromEnd(Nd),Nd.length?(yd.raws.afterName=this.spacesAndCommentsFromStart(Nd),this.raw(yd,"params",Nd),Od&&(_d=Nd[Nd.length-1],yd.source.end=this.getPosition(_d[3]||_d[2]),yd.source.end.offset++,this.spaces=yd.raws.between,yd.raws.between="")):(yd.raws.afterName="",yd.params=""),Rd&&(yd.nodes=[],this.current=yd)}checkMissedSemicolon(_d){let yd=this.colon(_d);if(yd===!1)return;let gd=0,Ed;for(let Td=yd-1;Td>=0&&(Ed=_d[Td],!(Ed[0]!=="space"&&(gd+=1,gd===2)));Td--);throw this.input.error("Missed semicolon",Ed[0]==="word"?Ed[3]+1:Ed[2])}colon(_d){let yd=0,gd,Ed,Td;for(let[Od,Rd]of _d.entries()){if(gd=Rd,Ed=gd[0],Ed==="("&&(yd+=1),Ed===")"&&(yd-=1),yd===0&&Ed===":")if(!Td)this.doubleColon(gd);else{if(Td[0]==="word"&&Td[1]==="progid")continue;return Od}Td=gd}return!1}comment(_d){let yd=new td;this.init(yd,_d[2]),yd.source.end=this.getPosition(_d[3]||_d[2]),yd.source.end.offset++;let gd=_d[1].slice(2,-2);if(/^ \s * $ /.test(gd))yd.text="",yd.raws.left=gd,yd.raws.right="";else{let Ed=gd.match(/^( \s *)([^]* \S )( \s *) $ /);yd.text=Ed[2],yd.raws.left=Ed[1],yd.raws.right=Ed[3]}}createTokenizer(){this.tokenizer=ed(this.input)}decl(_d,yd){let gd=new Ja;this.init(gd,_d[0][2]);let Ed=_d[_d.length-1];for(Ed[0]===";"&&(this.semicolon=!0,_d.pop()),gd.source.end=this.getPosition(Ed[3]||Ed[2]||cd(_d)),gd.source.end.offset++;_d[0][0]!=="word";)_d.length===1&&this.unknownWord(_d),gd.raws.before+=_d.shift()[1];for(gd.source.start=this.getPosition(_d[0][2]),gd.prop="";_d.length;){let Nd=_d[0][0];if(Nd===":"||Nd==="space"||Nd==="comment")break;gd.prop+=_d.shift()[1]}gd.raws.between="";let Td;for(;_d.length;)if(Td=_d.shift(),Td[0]===":"){gd.raws.between+=Td[1];break}else Td[0]==="word"&&/ \w /.test(Td[1])&&this.unknownWord([Td]),gd.raws.between+=Td[1];(gd.prop[0]==="_"||gd.prop[0]==="*")&&(gd.raws.before+=gd.prop[0],gd.prop=gd.prop.slice(1));let Od=[],Rd;for(;_d.length&&(Rd=_d[0][0],!(Rd!=="space"&&Rd!=="comment"));)Od.push(_d.shift());this.precheckMissedSemicolon(_d);for(let Nd=_d.length-1;Nd>=0;Nd--){if(Td=_d[Nd],Td[1].toLowerCase()==="!important"){gd.important=!0;let Id=this.stringFrom(_d,Nd);Id=this.spacesFromEnd(_d)+Id,Id!==" !important"&&(gd.raws.important=Id
` );Nd=new Array(Md.length);let Ld=0;for(let Pd=0,qd=Md.length;Pd<qd;Pd++)Nd[Pd]=Ld,Ld+=Md[Pd].length+1;this[yd]=Nd}Rd=Nd[Nd.length-1];let Id=0;if(Od>=Rd)Id=Nd.length-1;else{let Md=Nd.length-2,Ld;for(;Id<Md;)if(Ld=Id+(Md-Id>>1),Od<Nd[Ld])Md=Ld-1;else if(Od>=Nd[Ld+1])Id=Ld+1;else{Id=Ld;break}}return{col:Od-Nd[Id]+1,line:Id+1}}mapResolve(Od){return/^ \w +: \/ \/ /.test(Od)?Od:od(this.map.consumer().sourceRoot||this.map.root||".",Od)}origin(Od,Rd,Nd,Id){if(!this.map)return!1;let Md=this.map.consumer(),Ld=Md.originalPositionFor({column:Rd,line:Od});if(!Ld.source)return!1;let Pd;typeof Nd=="number"&&(Pd=Md.originalPositionFor({column:Id,line:Nd}));let qd;sd(Ld.source)?qd=rd(Ld.source):qd=new URL(Ld.source,this.map.consumer().sourceRoot||rd(this.map.mapFile));let Yd={column:Ld.column,endColumn:Pd&&Pd.column,endLine:Pd&&Pd.line,line:Ld.line,url:qd.toString()};if(qd.protocol==="file:")if(td)Yd.file=td(qd);else throw new Error("file: protocol is not available in this PostCSS build");let Ud=Md.sourceContentFor(Ld.source);return Ud&&(Yd.source=Ud),Yd}toJSON(){let Od={};for(let Rd of["hasBOM","css","file","id"])this[Rd]!=null&&(Od[Rd]=this[Rd]);return this.map&&(Od.map={...this.map},Od.map.consumerCache&&(Od.map.consumerCache=void 0)),Od}get from(){return this.file||this.id}};qa.exports=Td,Td.default=Td,cd&&cd.registerInput&&cd.registerInput(Td)}),pt=y((Ra,qa)=>{var Ja=re(),ed=Ht $ 1(),td=Re $ 1();function rd(sd,od){let ld=new td(sd,od),cd=new ed(ld);try{cd.parse()}catch(ud){throw ud}return cd.root}qa.exports=rd,rd.default=rd,Ja.registerParse(rd)}),no=y((Ra,qa)=>{var Ja=Vt $ 1(),ed=Re $ 1();qa.exports={isInlineComment(td){if(td[0]==="word"&&td[1].slice(0,2)==="//"){let rd=td,sd=[],od,ld;for(;td;){if(/ \r ? \n /.test(td[1])){if(/['"].* \r ? \n /.test(td[1])){sd.push(td[1].substring(0,td[1].indexOf( `
2024-08-30 15:19:18 +08:00
` ))),ld=td[1].substring(td[1].indexOf( `
2024-09-08 17:22:36 +08:00
` ));let ud=this.input.css.valueOf().substring(this.tokenizer.position());ld+=ud,od=td[3]+ud.length-ld.length}else this.tokenizer.back(td);break}sd.push(td[1]),od=td[2],td=this.tokenizer.nextToken({ignoreUnclosed:!0})}let cd=["comment",sd.join(""),rd[2],od];return this.inlineComment(cd),ld&&(this.input=new ed(ld),this.tokenizer=Ja(this.input)),!0}else if(td[1]==="/"){let rd=this.tokenizer.nextToken({ignoreUnclosed:!0});if(rd[0]==="comment"&&/^ \/ \* /.test(rd[1]))return rd[0]="word",rd[1]=rd[1].slice(1),td[1]="//",this.tokenizer.back(rd),qa.exports.isInlineComment.bind(this)(td)}return!1}}}),oo $ 1=y((Ra,qa)=>{qa.exports={interpolation(Ja){let ed=[Ja,this.tokenizer.nextToken()],td=["word","}"];if(ed[0][1].length>1||ed[1][0]!=="{")return this.tokenizer.back(ed[1]),!1;for(Ja=this.tokenizer.nextToken();Ja&&td.includes(Ja[0]);)ed.push(Ja),Ja=this.tokenizer.nextToken();let rd=ed.map(cd=>cd[1]),[sd]=ed,od=ed.pop(),ld=["word",rd.join(""),sd[2],od[2]];return this.tokenizer.back(Ja),this.tokenizer.back(ld),!0}}}),uo $ 1=y((Ra,qa)=>{var Ja=/^#[0-9a-fA-F]{6} $ |^#[0-9a-fA-F]{3} $ /,ed=/ \. [0-9]/,td=rd=>{let[,sd]=rd,[od]=sd;return(od==="."||od==="#")&&Ja.test(sd)===!1&&ed.test(sd)===!1};qa.exports={isMixinToken:td}}),co=y((Ra,qa)=>{var Ja=Vt $ 1(),ed=/^url \( (.+) \) /;qa.exports=td=>{let{name:rd,params:sd=""}=td;if(rd==="import"&&sd.length){td.import=!0;let od=Ja({css:sd});for(td.filename=sd.replace(ed," $ 1");!od.endOfFile();){let[ld,cd]=od.nextToken();if(ld==="word"&&cd==="url")return;if(ld==="brackets"){td.options=cd,td.filename=sd.replace(cd,"").trim();break}}}}}),mo $ 1=y((Ra,qa)=>{var Ja=/: $ /,ed=/^:( \s +)?/;qa.exports=td=>{let{name:rd,params:sd=""}=td;if(td.name.slice(-1)===":"){if(Ja.test(rd)){let[od]=rd.match(Ja);td.name=rd.replace(od,""),td.raws.afterName=od+(td.raws.afterName||""),td.variable=!0,td.value=td.params}if(ed.test(sd)){let[od]=sd.match(ed);td.value=sd.replace(od,""),td.raws.afterName=(td.raws.afterName||"")+od,td.variable=!0}}}}),go $ 1=y((Ra,qa)=>{var Ja=Oe(),ed=Ht $ 1(),{isInlineComment:td}=no(),{interpolation:rd}=oo $ 1(),{isMixinToken:sd}=uo $ 1(),od=co(),ld=mo $ 1(),cd=/(! \s *important) $ /i;qa.exports=class extends ed{constructor(...ud){super(...ud),this.lastNode=null}atrule(ud){rd.bind(this)(ud)||(super.atrule(ud),od(this.lastNode),ld(this.lastNode))}decl(...ud){super.decl(...ud),/extend \( .+ \) /i.test(this.lastNode.value)&&(this.lastNode.extend=!0)}each(ud){ud[0][1]= ` $ { ud [ 0 ] [ 1 ] } ` ;let _d=ud.findIndex(Td=>Td[0]==="("),yd=ud.reverse().find(Td=>Td[0]===")"),gd=ud.reverse().indexOf(yd),Ed=ud.splice(_d,gd).map(Td=>Td[1]).join("");for(let Td of ud.reverse())this.tokenizer.back(Td);this.atrule(this.tokenizer.nextToken()),this.lastNode.function=!0,this.lastNode.params=Ed}init(ud,_d,yd){super.init(ud,_d,yd),this.lastNode=ud}inlineComment(ud){let _d=new Ja,yd=ud[1].slice(2);if(this.init(_d,ud[2]),_d.source.end=this.getPosition(ud[3]||ud[2]),_d.inline=!0,_d.raws.begin="//",/^ \s * $ /.test(yd))_d.text="",_d.raws.left=yd,_d.raws.right="";else{let gd=yd.match(/^( \s *)([^]*[^ \s ])( \s *) $ /);[,_d.raws.left,_d.text,_d.raws.right]=gd}}mixin(ud){let[_d]=ud,yd=_d[1].slice(0,1),gd=ud.findIndex(Nd=>Nd[0]==="brackets"),Ed=ud.findIndex(Nd=>Nd[0]==="("),Td="";if((gd<0||gd>3)&&Ed>0){let Nd=ud.reduce((zd,Jd,Zd)=>Jd[0]===")"?Zd:zd),Id=ud.slice(Ed,Nd+Ed).map(zd=>zd[1]).join(""),[Md]=ud.slice(Ed),Ld=[Md[2],Md[3]],[Pd]=ud.slice(Nd,Nd+1),qd=[Pd[2],Pd[3]],Yd=["brackets",Id].concat(Ld,qd),Ud=ud.slice(0,Ed),Hd=ud.slice(Nd+1);ud=Ud,ud.push(Yd),ud=ud.concat(Hd)}let Od=[];for(let Nd of ud)if((Nd[1]==="!"||Od.length)&&Od.push(Nd),Nd[1]==="important")break;if(Od.length){let[Nd]=Od,Id=ud.indexOf(Nd),Md=Od[Od.length-1],Ld=[Nd[2],Nd[3]],Pd=[Md[4],Md[5]],qd=["word",Od.map(Yd=>Yd[1]).join("")].concat(Ld,Pd);ud.splice(Id,Od.length,qd)}let Rd=ud.findIndex(Nd=>cd.test(Nd[1]));Rd>0&&([,Td]=ud[Rd],ud.splice(Rd,1));for(let Nd of ud.reverse())this.tokenizer.back(Nd);this.atrule(this.tokenizer.nextToken()),this.lastNode.mixin=!0,this.lastNode.raws.identifier=yd,Td&&(this.lastNode.important=!0,this.lastNode.raws.important=Td)}other(ud){td.bind(this)(ud)||super.other(ud)}rule(ud){let _d=ud[ud.length-1
https : //evilmartians.com/chronicles/postcss-8-plugin-migration`));let zd=Pd(...Hd);return zd.postcssPlugin=Ld,zd.postcssVersion=new sd().version,zd}let Ud;return Object.defineProperty(Yd,"postcss",{get(){return Ud||(Ud=Yd()),Ud}}),Yd.process=function(Hd,zd,Jd){return Md([Yd(Jd)]).process(Hd,zd)},Yd},Md.stringify=od,Md.parse=Td,Md.fromJSON=ld,Md.list=Od,Md.comment=Ld=>new _d(Ld),Md.atRule=Ld=>new yd(Ld),Md.decl=Ld=>new ed(Ld),Md.rule=Ld=>new Rd(Ld),Md.root=Ld=>new Nd(Ld),Md.document=Ld=>new cd(Ld),Md.CssSyntaxError=Ja,Md.Declaration=ed,Md.Container=rd,Md.Processor=sd,Md.Document=cd,Md.Comment=_d,Md.Warning=ud,Md.AtRule=yd,Md.Result=gd,Md.Input=Ed,Md.Rule=Rd,Md.Root=Nd,Md.Node=Id,td.registerPostcss(Md),qa.exports=Md,Md.default=Md}),Ho$1=y((Ra,qa)=>{var{Container:Ja}=Zt$1(),ed=class extends Ja{constructor(td){super(td),this.type="decl",this.isNested=!0,this.nodes||(this.nodes=[])}};qa.exports=ed}),Jo=y((Ra,qa)=>{var Ja=/[\t\n\f\r "#'()/;[\\\]{}]/g,ed=/[,\t\n\f\r !"#'():;@[\\\]{}]|\/(?=\*)/g,td=/.[\r\n"'(/\\]/,rd=/[\da-f]/i,sd=/[\n\f\r]/g;qa.exports=function(od,ld={}){let cd=od.css.valueOf(),ud=ld.ignoreErrors,_d,yd,gd,Ed,Td,Od,Rd,Nd,Id,Md=cd.length,Ld=0,Pd=[],qd=[],Yd;function Ud(){return Ld}function Hd(Qd){throw od.error("Unclosed "+Qd,Ld)}function zd(){return qd.length===0&&Ld>=Md}function Jd(){let Qd=1,hf=!1,mf=!1;for(;Qd>0;)yd+=1,cd.length<=yd&&Hd("interpolation"),_d=cd.charCodeAt(yd),Nd=cd.charCodeAt(yd+1),hf?!mf&&_d===hf?(hf=!1,mf=!1):_d===92?mf=!mf:mf&&(mf=!1):_d===39||_d===34?hf=_d:_d===125?Qd-=1:_d===35&&Nd===123&&(Qd+=1)}function Zd(Qd){if(qd.length)return qd.pop();if(Ld>=Md)return;let hf=Qd?Qd.ignoreUnclosed:!1;switch(_d=cd.charCodeAt(Ld),_d){case 10:case 32:case 9:case 13:case 12:{yd=Ld;do yd+=1,_d=cd.charCodeAt(yd);while(_d===32||_d===10||_d===9||_d===13||_d===12);Id=["space",cd.slice(Ld,yd)],Ld=yd-1;break}case 91:case 93:case 123:case 125:case 58:case 59:case 41:{let mf=String.fromCharCode(_d);Id=[mf,mf,Ld];break}case 44:{Id=["word",",",Ld,Ld+1];break}case 40:{if(Rd=Pd.length?Pd.pop()[1]:"",Nd=cd.charCodeAt(Ld+1),Rd==="url"&&Nd!==39&&Nd!==34){for(Yd=1,Od=!1,yd=Ld+1;yd<=cd.length-1;){if(Nd=cd.charCodeAt(yd),Nd===92)Od=!Od;else if(Nd===40)Yd+=1;else if(Nd===41&&(Yd-=1,Yd===0))break;yd+=1}Ed=cd.slice(Ld,yd+1),Id=["brackets",Ed,Ld,yd],Ld=yd}else yd=cd.indexOf(")",Ld+1),Ed=cd.slice(Ld,yd+1),yd===-1||td.test(Ed)?Id=["(","(",Ld]:(Id=["brackets",Ed,Ld,yd],Ld=yd);break}case 39:case 34:{for(gd=_d,yd=Ld,Od=!1;yd<Md&&(yd++,yd===Md&&Hd("string"),_d=cd.charCodeAt(yd),Nd=cd.charCodeAt(yd+1),!(!Od&&_d===gd));)_d===92?Od=!Od:Od?Od=!1:_d===35&&Nd===123&&Jd();Id=["string",cd.slice(Ld,yd+1),Ld,yd],Ld=yd;break}case 64:{Ja.lastIndex=Ld+1,Ja.test(cd),Ja.lastIndex===0?yd=cd.length-1:yd=Ja.lastIndex-2,Id=["at-word",cd.slice(Ld,yd+1),Ld,yd],Ld=yd;break}case 92:{for(yd=Ld,Td=!0;cd.charCodeAt(yd+1)===92;)yd+=1,Td=!Td;if(_d=cd.charCodeAt(yd+1),Td&&_d!==47&&_d!==32&&_d!==10&&_d!==9&&_d!==13&&_d!==12&&(yd+=1,rd.test(cd.charAt(yd)))){for(;rd.test(cd.charAt(yd+1));)yd+=1;cd.charCodeAt(yd+1)===32&&(yd+=1)}Id=["word",cd.slice(Ld,yd+1),Ld,yd],Ld=yd;break}default:Nd=cd.charCodeAt(Ld+1),_d===35&&Nd===123?(yd=Ld,Jd(),Ed=cd.slice(Ld,yd+1),Id=["word",Ed,Ld,yd],Ld=yd):_d===47&&Nd===42?(yd=cd.indexOf("*/",Ld+2)+1,yd===0&&(ud||hf?yd=cd.length:Hd("comment")),Id=["comment",cd.slice(Ld,yd+1),Ld,yd],Ld=yd):_d===47&&Nd===47?(sd.lastIndex=Ld+1,sd.test(cd),sd.lastIndex===0?yd=cd.length-1:yd=sd.lastIndex-2,Ed=cd.slice(Ld,yd+1),Id=["comment",Ed,Ld,yd,"inline"],Ld=yd):(ed.lastIndex=Ld+1,ed.test(cd),ed.lastIndex===0?yd=cd.length-1:yd=ed.lastIndex-2,Id=["word",cd.slice(Ld,yd+1),Ld,yd],Pd.push(Id),Ld=yd);break}return Ld++,Id}function pf(Qd){qd.push(Qd)}return{back:pf,endOfFile:zd,nextToken:Zd,position:Ud}}}),Zo=y((Ra,qa)=>{var{Comment:Ja}=Zt$1(),ed=Ht$1(),td=Ho$1(),rd=Jo(),sd=class extends ed{atrule(od){let ld=od[1],cd=od;for(;!this.tokenizer.endOfFile();){let ud=this.tokenizer.nextToken();if(ud[0]==="word"&&ud[2]===cd[3]+1)ld+=ud[1],cd=ud;else{this.tokenizer.back(ud);break}}super.atrule(["at-word",ld,od[2],cd[3]])}comment(od){if(od[4]==="inline"){let ld=new Ja;thi
` ))break;_d[0]==="("?cd+=1:_d[0]===")"?cd-=1:cd===0&&_d[0]===":"&&(ld=!0)}if(!ld||ud.trim()===""||/^[#:A-Za-z-]/.test(ud))super.rule(od);else{od.pop();let _d=new td;this.init(_d,od[0][2]);let yd;for(let Ed=od.length-1;Ed>=0;Ed--)if(od[Ed][0]!=="space"){yd=od[Ed];break}if(yd[3]){let Ed=this.input.fromOffset(yd[3]);_d.source.end={column:Ed.col,line:Ed.line,offset:yd[3]+1}}else{let Ed=this.input.fromOffset(yd[2]);_d.source.end={column:Ed.col,line:Ed.line,offset:yd[2]+1}}for(;od[0][0]!=="word";)_d.raws.before+=od.shift()[1];if(od[0][2]){let Ed=this.input.fromOffset(od[0][2]);_d.source.start={column:Ed.col,line:Ed.line,offset:od[0][2]}}for(_d.prop="";od.length;){let Ed=od[0][0];if(Ed===":"||Ed==="space"||Ed==="comment")break;_d.prop+=od.shift()[1]}_d.raws.between="";let gd;for(;od.length;)if(gd=od.shift(),gd[0]===":"){_d.raws.between+=gd[1];break}else _d.raws.between+=gd[1];(_d.prop[0]==="_"||_d.prop[0]==="*")&&(_d.raws.before+=_d.prop[0],_d.prop=_d.prop.slice(1)),_d.raws.between+=this.spacesAndCommentsFromStart(od),this.precheckMissedSemicolon(od);for(let Ed=od.length-1;Ed>0;Ed--){if(gd=od[Ed],gd[1]==="!important"){_d.important=!0;let Td=this.stringFrom(od,Ed);Td=this.spacesFromEnd(od)+Td,Td!==" !important"&&(_d.raws.important=Td);break}else if(gd[1]==="important"){let Td=od.slice(0),Od="";for(let Rd=Ed;Rd>0;Rd--){let Nd=Td[Rd][0];if(Od.trim().indexOf("!")===0&&Nd!=="space")break;Od=Td.pop()[1]+Od}Od.trim().indexOf("!")===0&&(_d.important=!0,_d.raws.important=Od,od=Td)}if(gd[0]!=="space"&&gd[0]!=="comment")break}this.raw(_d,"value",od),_d.value.includes(":")&&this.checkMissedSemicolon(od),this.current=_d}}};qa.exports=sd}),ta=y((Ra,qa)=>{var{Input:Ja}=Zt $ 1(),ed=Zo();qa.exports=function(td,rd){let sd=new Ja(td,rd),od=new ed(sd);return od.parse(),od.root}}),Os=y(Ra=>{Object.defineProperty(Ra,"__esModule",{value:!0});function qa(Ja){this.after=Ja.after,this.before=Ja.before,this.type=Ja.type,this.value=Ja.value,this.sourceIndex=Ja.sourceIndex}Ra.default=qa}),As=y(Ra=>{Object.defineProperty(Ra,"__esModule",{value:!0});var qa=Os(),Ja=ed(qa);function ed(rd){return rd&&rd.__esModule?rd:{default:rd}}function td(rd){var sd=this;this.constructor(rd),this.nodes=rd.nodes,this.after===void 0&&(this.after=this.nodes.length>0?this.nodes[this.nodes.length-1].after:""),this.before===void 0&&(this.before=this.nodes.length>0?this.nodes[0].before:""),this.sourceIndex===void 0&&(this.sourceIndex=this.before.length),this.nodes.forEach(function(od){od.parent=sd})}td.prototype=Object.create(Ja.default.prototype),td.constructor=Ja.default,td.prototype.walk=function(rd,sd){for(var od=typeof rd=="string"||rd instanceof RegExp,ld=od?sd:rd,cd=typeof rd=="string"?new RegExp(rd):rd,ud=0;ud<this.nodes.length;ud++){var _d=this.nodes[ud],yd=od?cd.test(_d.type):!0;if(yd&&ld&&ld(_d,ud,this.nodes)===!1||_d.nodes&&_d.walk(rd,sd)===!1)return!1}return!0},td.prototype.each=function(){for(var rd=arguments.length<=0||arguments[0]===void 0?function(){}:arguments[0],sd=0;sd<this.nodes.length;sd++){var od=this.nodes[sd];if(rd(od,sd,this.nodes)===!1)return!1}return!0},Ra.default=td}),aa $ 1=y(Ra=>{Object.defineProperty(Ra,"__esModule",{value:!0}),Ra.parseMediaFeature=sd,Ra.parseMediaQuery=od,Ra.parseMediaList=ld;var qa=Os(),Ja=rd(qa),ed=As(),td=rd(ed);function rd(cd){return cd&&cd.__esModule?cd:{default:cd}}function sd(cd){var ud=arguments.length<=1||arguments[1]===void 0?0:arguments[1],_d=[{mode:"normal",character:null}],yd=[],gd=0,Ed="",Td=null,Od=null,Rd=ud,Nd=cd;cd[0]==="("&&cd[cd.length-1]===")"&&(Nd=cd.substring(1,cd.length-1),Rd++);for(var Id=0;Id<Nd.length;Id++){var Md=Nd[Id];if((Md==="'"||Md==='"')&&(_d[gd].isCalculationEnabled===!0?(_d.push({mode:"string",isCalculationEnabled:!1,character:Md}),gd++):_d[gd].mode==="string"&&_d[gd].character===Md&&Nd[Id-1]!==" \\ "&&(_d.pop(),gd--)),Md==="{"?(_d.push({mode:"interpolation",isCalculationEnabled:!0}),gd++):Md==="}"&&(_d.pop(),gd--),_d[gd].mode==="normal"&&Md===":"){var Ld=Nd.substring(Id+1);Od={type:"value",before:/^( \s *)/.exec(Ld)[1],after:/( \s *) $ /.exec(Ld)[1],value:Ld.trim()},Od.sourceIndex=Od.before.length+Id+1+Rd,T
` ),Lf=xf.length-1,Lf>0?(Of=_f+Lf,Tf=hf-xf[Lf].length):(Of=_f,Tf=gf),Zd.push(["comment",Kf,_f, $ f-gf,Of,hf-Tf, $ f]),gf=Tf,_f=Of, $ f=hf):(Hd.lastIndex= $ f+1,Hd.test(pf),Hd.lastIndex===0?hf=pf.length-1:hf=Hd.lastIndex-2,Zd.push(["word",pf.slice( $ f,hf+1),_f, $ f-gf,_f,hf-gf, $ f]), $ f=hf);break} $ f++}return Zd}qa.exports=Ra.default}),tu $ 1=y((Ra,qa)=>{Ra.__esModule=!0;var Ja=function(){function gf(_f, $ f){for(var Gf=0;Gf< $ f.length;Gf++){var dh= $ f[Gf];dh.enumerable=dh.enumerable||!1,dh.configurable=!0,"value"in dh&&(dh.writable=!0),Object.defineProperty(_f,dh.key,dh)}}return function(_f, $ f,Gf){return $ f&&gf(_f.prototype, $ f),Gf&&gf(_f,Gf),_f}}(),ed=qs(),td=wf(ed),rd=Ls(),sd=wf(rd),od=Ds $ 1(),ld=wf(od),cd=ga $ 1(),ud=wf(cd),_d=xa(),yd=wf(_d),gd=ka(),Ed=wf(gd),Td=Sa(),Od=wf(Td),Rd=Oa $ 1(),Nd=wf(Rd),Id=Aa(),Md=wf(Id),Ld=Pa $ 1(),Pd=wf(Ld),qd=Ia(),Yd=wf(qd),Ud=La(),Hd=wf(Ud),zd=Ma(),Jd=wf(zd),Zd=Ua $ 1(),pf=wf(Zd),Qd= $ a $ 1(),hf=wf(Qd),mf=Ya $ 1(),xf=wf(mf),Lf=Xa $ 1(),Kf=wf(Lf),Yf=D(),Of=Tf(Yf);function Tf(gf){if(gf&&gf.__esModule)return gf;var _f={};if(gf!=null)for(var $ f in gf)Object.prototype.hasOwnProperty.call(gf, $ f)&&(_f[ $ f]=gf[ $ f]);return _f.default=gf,_f}function wf(gf){return gf&&gf.__esModule?gf:{default:gf}}function Wf(gf,_f){if(!(gf instanceof _f))throw new TypeError("Cannot call a class as a function")}var Uf=function(){function gf(_f){Wf(this,gf),this.input=_f,this.lossy=_f.options.lossless===!1,this.position=0,this.root=new ud.default;var $ f=new yd.default;return this.root.append( $ f),this.current= $ f,this.lossy?this.tokens=(0,Kf.default)({safe:_f.safe,css:_f.css.trim()}):this.tokens=(0,Kf.default)(_f),this.loop()}return gf.prototype.attribute=function(){var _f="", $ f=void 0,Gf=this.currToken;for(this.position++;this.position<this.tokens.length&&this.currToken[0]!=="]";)_f+=this.tokens[this.position][1],this.position++;this.position===this.tokens.length&&!~_f.indexOf("]")&&this.error("Expected a closing square bracket.");var dh=_f.split(/((?:[*~^ $ |]?=))([^]*)/),zf=dh[0].split(/( \| )/g),If={operator:dh[1],value:dh[2],source:{start:{line:Gf[2],column:Gf[3]},end:{line:this.currToken[2],column:this.currToken[3]}},sourceIndex:Gf[4]};if(zf.length>1?(zf[0]===""&&(zf[0]=!0),If.attribute=this.parseValue(zf[2]),If.namespace=this.parseNamespace(zf[0])):If.attribute=this.parseValue(dh[0]), $ f=new Hd.default(If),dh[2]){var Jf=dh[2].split(/( \s +i \s *?) $ /),Th=Jf[0].trim(); $ f.value=this.lossy?Th:Jf[0],Jf[1]&&( $ f.insensitive=!0,this.lossy||( $ f.raws.insensitive=Jf[1])), $ f.quoted=Th[0]==="'"||Th[0]==='"', $ f.raws.unquoted= $ f.quoted?Th.slice(1,-1):Th}this.newNode( $ f),this.position++},gf.prototype.combinator=function(){if(this.currToken[1]==="|")return this.namespace();for(var _f=new pf.default({value:"",source:{start:{line:this.currToken[2],column:this.currToken[3]},end:{line:this.currToken[2],column:this.currToken[3]}},sourceIndex:this.currToken[4]});this.position<this.tokens.length&&this.currToken&&(this.currToken[0]==="space"||this.currToken[0]==="combinator");)this.nextToken&&this.nextToken[0]==="combinator"?(_f.spaces.before=this.parseSpace(this.currToken[1]),_f.source.start.line=this.nextToken[2],_f.source.start.column=this.nextToken[3],_f.source.end.column=this.nextToken[3],_f.source.end.line=this.nextToken[2],_f.sourceIndex=this.nextToken[4]):this.prevToken&&this.prevToken[0]==="combinator"?_f.spaces.after=this.parseSpace(this.currToken[1]):this.currToken[0]==="combinator"?_f.value=this.currToken[1]:this.currToken[0]==="space"&&(_f.value=this.parseSpace(this.currToken[1]," ")),this.position++;return this.newNode(_f)},gf.prototype.comma=function(){if(this.position===this.tokens.length-1){this.root.trailingComma=!0,this.position++;return}var _f=new yd.default;this.current.parent.append(_f),this.current=_f,this.position++},gf.prototype.comment=function(){var _f=new Od.default({value:this.currToken[1],source:{start:{line:this.currToken[2],column:this.currToken[3]},end:{line:this.currToken[4],column:this.currToken[5]}},sourceIndex:this.currToken[6]});this.newNode(_f),this.position++},gf.prototype.error=function(_f){throw new this.input.error(_f)},gf.prototype.miss
` ?(rd=1,sd+=1):rd+=1;return{line:sd,column:rd}}positionBy(ed){let td=this.source.start;if(Object(ed).index)td=this.positionInside(ed.index);else if(Object(ed).word){let rd=this.toString().indexOf(ed.word);rd!==-1&&(td=this.positionInside(rd))}return td}}}),U=y((Ra,qa)=>{var Ja=z(),ed=class extends Ja{constructor(td){super(td),this.nodes||(this.nodes=[])}push(td){return td.parent=this,this.nodes.push(td),this}each(td){this.lastEach||(this.lastEach=0),this.indexes||(this.indexes={}),this.lastEach+=1;let rd=this.lastEach,sd,od;if(this.indexes[rd]=0,!!this.nodes){for(;this.indexes[rd]<this.nodes.length&&(sd=this.indexes[rd],od=td(this.nodes[sd],sd),od!==!1);)this.indexes[rd]+=1;return delete this.indexes[rd],od}}walk(td){return this.each((rd,sd)=>{let od=td(rd,sd);return od!==!1&&rd.walk&&(od=rd.walk(td)),od})}walkType(td,rd){if(!td||!rd)throw new Error("Parameters {type} and {callback} are required.");let sd=typeof td=="function";return this.walk((od,ld)=>{if(sd&&od instanceof td||!sd&&od.type===td)return rd.call(this,od,ld)})}append(td){return td.parent=this,this.nodes.push(td),this}prepend(td){return td.parent=this,this.nodes.unshift(td),this}cleanRaws(td){if(super.cleanRaws(td),this.nodes)for(let rd of this.nodes)rd.cleanRaws(td)}insertAfter(td,rd){let sd=this.index(td),od;this.nodes.splice(sd+1,0,rd);for(let ld in this.indexes)od=this.indexes[ld],sd<=od&&(this.indexes[ld]=od+this.nodes.length);return this}insertBefore(td,rd){let sd=this.index(td),od;this.nodes.splice(sd,0,rd);for(let ld in this.indexes)od=this.indexes[ld],sd<=od&&(this.indexes[ld]=od+this.nodes.length);return this}removeChild(td){td=this.index(td),this.nodes[td].parent=void 0,this.nodes.splice(td,1);let rd;for(let sd in this.indexes)rd=this.indexes[sd],rd>=td&&(this.indexes[sd]=rd-1);return this}removeAll(){for(let td of this.nodes)td.parent=void 0;return this.nodes=[],this}every(td){return this.nodes.every(td)}some(td){return this.nodes.some(td)}index(td){return typeof td=="number"?td:this.nodes.indexOf(td)}get first(){if(this.nodes)return this.nodes[0]}get last(){if(this.nodes)return this.nodes[this.nodes.length-1]}toString(){let td=this.nodes.map(String).join("");return this.value&&(td=this.value+td),this.raws.before&&(td=this.raws.before+td),this.raws.after&&(td+=this.raws.after),td}};ed.registerWalker=td=>{let rd="walk"+td.name;rd.lastIndexOf("s")!==rd.length-1&&(rd+="s"),!ed.prototype[rd]&&(ed.prototype[rd]=function(sd){return this.walkType(td,sd)})},qa.exports=ed}),uu $ 1=y((Ra,qa)=>{var Ja=U();qa.exports=class extends Ja{constructor(ed){super(ed),this.type="root"}}}),cu=y((Ra,qa)=>{var Ja=U();qa.exports=class extends Ja{constructor(ed){super(ed),this.type="value",this.unbalanced=0}}}),hu=y((Ra,qa)=>{var Ja=U(),ed=class extends Ja{constructor(td){super(td),this.type="atword"}toString(){return this.quoted&&this.raws.quote,[this.raws.before,"@",String.prototype.toString.call(this.value),this.raws.after].join("")}};Ja.registerWalker(ed),qa.exports=ed}),mu=y((Ra,qa)=>{var Ja=U(),ed=z(),td=class extends ed{constructor(rd){super(rd),this.type="colon"}};Ja.registerWalker(td),qa.exports=td}),wu=y((Ra,qa)=>{var Ja=U(),ed=z(),td=class extends ed{constructor(rd){super(rd),this.type="comma"}};Ja.registerWalker(td),qa.exports=td}),vu=y((Ra,qa)=>{var Ja=U(),ed=z(),td=class extends ed{constructor(rd){super(rd),this.type="comment",this.inline=Object(rd).inline||!1}toString(){return[this.raws.before,this.inline?"//":"/*",String(this.value),this.inline?"":"*/",this.raws.after].join("")}};Ja.registerWalker(td),qa.exports=td}),_u=y((Ra,qa)=>{var Ja=U(),ed=class extends Ja{constructor(td){super(td),this.type="func",this.unbalanced=-1}};Ja.registerWalker(ed),qa.exports=ed}),Eu=y((Ra,qa)=>{var Ja=U(),ed=z(),td=class extends ed{constructor(rd){super(rd),this.type="number",this.unit=Object(rd).unit||""}toString(){return[this.raws.before,String(this.value),this.unit,this.raws.after].join("")}};Ja.registerWalker(td),qa.exports=td}),Tu=y((Ra,qa)=>{var Ja=U(),ed=z(),td=class extends ed{constructor(rd){super(rd),this.type="operator"}};Ja.registerWalker(td),qa.exports=td}),Cu=y
2024-09-03 08:22:14 +08:00
` ,Td+2);Id=pf!==-1?pf-1:yd}qd=_d.slice(Td,Id+1),Ld=qd.split( `
2024-09-08 17:22:36 +08:00
` ),Pd=Ld.length-1,Pd>0?(Yd=Ed+Pd,Ud=Id-Ld[Pd].length):(Yd=Ed,Ud=gd),ud.push(["comment",qd,Ed,Td-gd,Yd,Id-Ud,Td]),gd=Ud,Ed=Yd,Td=Id}else if(Nd===35&&!rd.test(_d.slice(Td+1,Td+2)))Id=Td+1,ud.push(["#",_d.slice(Td,Id),Ed,Td-gd,Ed,Id-gd,Td]),Td=Id-1;else if((Nd===117||Nd===85)&&_d.charCodeAt(Td+1)===43){Id=Td+2;do Id+=1,Nd=_d.charCodeAt(Id);while(Id<yd&&sd.test(_d.slice(Id,Id+1)));ud.push(["unicoderange",_d.slice(Td,Id),Ed,Td-gd,Ed,Id-gd,Td]),Td=Id-1}else if(Nd===47)Id=Td+1,ud.push(["operator",_d.slice(Td,Id),Ed,Td-gd,Ed,Id-gd,Td]),Td=Id-1;else{let pf=ed;if(Nd>=48&&Nd<=57&&(pf=td),pf.lastIndex=Td+1,pf.test(_d),pf.lastIndex===0?Id=_d.length-1:Id=pf.lastIndex-2,pf===td||Nd===46){let Qd=_d.charCodeAt(Id),hf=_d.charCodeAt(Id+1),mf=_d.charCodeAt(Id+2);(Qd===101||Qd===69)&&(hf===45||hf===43)&&mf>=48&&mf<=57&&(td.lastIndex=Id+2,td.test(_d),td.lastIndex===0?Id=_d.length-1:Id=td.lastIndex-2)}ud.push(["word",_d.slice(Td,Id+1),Ed,Td-gd,Ed,Id-gd,Td]),Td=Id}break}Td++}return ud}}), $ u=y((Ra,qa)=>{var Ja=class extends Error{constructor(ed){super(ed),this.name=this.constructor.name,this.message=ed||"An error ocurred while parsing.",typeof Error.captureStackTrace=="function"?Error.captureStackTrace(this,this.constructor):this.stack=new Error(ed).stack}};qa.exports=Ja}),Vu=y((Ra,qa)=>{var Ja=uu $ 1(),ed=cu(),td=hu(),rd=mu(),sd=wu(),od=vu(),ld=_u(),cd=Eu(),ud=Tu(),_d=Cu(),yd=Nu(),gd=Ru(),Ed=qu $ 1(),Td=Uu(),Od=qs(),Rd=Ls(),Nd=Ds $ 1(),Id= $ u();function Md(Ld){return Ld.sort((Pd,qd)=>Pd-qd)}qa.exports=class{constructor(Ld,Pd){let qd={loose:!1};this.cache=[],this.input=Ld,this.options=Object.assign({},qd,Pd),this.position=0,this.unbalanced=0,this.root=new Ja;let Yd=new ed;this.root.append(Yd),this.current=Yd,this.tokens=Td(Ld,this.options)}parse(){return this.loop()}colon(){let Ld=this.currToken;this.newNode(new rd({value:Ld[1],source:{start:{line:Ld[2],column:Ld[3]},end:{line:Ld[4],column:Ld[5]}},sourceIndex:Ld[6]})),this.position++}comma(){let Ld=this.currToken;this.newNode(new sd({value:Ld[1],source:{start:{line:Ld[2],column:Ld[3]},end:{line:Ld[4],column:Ld[5]}},sourceIndex:Ld[6]})),this.position++}comment(){let Ld=!1,Pd=this.currToken[1].replace(/ \/ \* | \* \/ /g,""),qd;this.options.loose&&Pd.startsWith("//")&&(Pd=Pd.substring(2),Ld=!0),qd=new od({value:Pd,inline:Ld,source:{start:{line:this.currToken[2],column:this.currToken[3]},end:{line:this.currToken[4],column:this.currToken[5]}},sourceIndex:this.currToken[6]}),this.newNode(qd),this.position++}error(Ld,Pd){throw new Id(Ld+ ` at line : $ { Pd [ 2 ] } , column $ { Pd [ 3 ] } ` )}loop(){for(;this.position<this.tokens.length;)this.parseTokens();return!this.current.last&&this.spaces?this.current.raws.before+=this.spaces:this.spaces&&(this.current.last.raws.after+=this.spaces),this.spaces="",this.root}operator(){let Ld=this.currToken[1],Pd;if(Ld==="+"||Ld==="-"){if(this.options.loose||this.position>0&&(this.current.type==="func"&&this.current.value==="calc"?this.prevToken[0]!=="space"&&this.prevToken[0]!=="("?this.error("Syntax Error",this.currToken):this.nextToken[0]!=="space"&&this.nextToken[0]!=="word"?this.error("Syntax Error",this.currToken):this.nextToken[0]==="word"&&this.current.last.type!=="operator"&&this.current.last.value!=="("&&this.error("Syntax Error",this.currToken):(this.nextToken[0]==="space"||this.nextToken[0]==="operator"||this.prevToken[0]==="operator")&&this.error("Syntax Error",this.currToken)),this.options.loose){if((!this.current.nodes.length||this.current.last&&this.current.last.type==="operator")&&this.nextToken[0]==="word")return this.word()}else if(this.nextToken[0]==="word")return this.word()}return Pd=new ud({value:this.currToken[1],source:{start:{line:this.currToken[2],column:this.currToken[3]},end:{line:this.currToken[2],column:this.currToken[3]}},sourceIndex:this.currToken[4]}),this.position++,this.newNode(Pd)}parseTokens(){switch(this.currToken[0]){case"space":this.space();break;case"colon":this.colon();break;case"comma":this.comma();break;case"comment":this.comment();break;case"(":this.parenOpen();break;case")":this.parenClose();break;case"atword":case"word":this.word();break;case"opera
Expected it to be 'string' or 'object' . ` ;if(Ve(Ra))throw new Error("doc is valid.");let Ja=Object.prototype.toString.call(Ra);if(Ja!=="[object Object]")return ` Unexpected doc '${Ja}' . ` ;let ed=ml([...bt $ 1].map(td=> ` '${td}' ` ));return ` Unexpected doc . type '${Ra.type}' .
2024-09-07 10:27:05 +08:00
Expected it to be $ { ed } . ` }var Fr=class extends Error{constructor(qa){super(yl(qa));n_(this,"name","InvalidDocError");this.doc=qa}}, $ r=Fr,Zs=()=>{},_t=Zs;function q(Ra){return{type:we,contents:Ra}}function en(Ra,qa){return{type:ge,contents:qa,n:Ra}}function L(Ra,qa={}){return _t(qa.expandedStates),{type:ve,id:qa.id,contents:Ra,break:!!qa.shouldBreak,expandedStates:qa.expandedStates}}function tn(Ra){return en({type:"root"},Ra)}function ue(Ra){return en(-1,Ra)}function Ge(Ra){return{type:xe $ 1,parts:Ra}}function kt(Ra,qa="",Ja={}){return{type:oe,breakContents:Ra,flatContents:qa,groupId:Ja.groupId}}var je $ 1={type:be $ 1},wl $ 1={type:K,hard:!0},A={type:K},M={type:K,soft:!0},E=[wl $ 1,je $ 1];function V(Ra,qa){let Ja=[];for(let ed=0;ed<qa.length;ed++)ed!==0&&Ja.push(Ra),Ja.push(qa[ed]);return Ja}var gl=(Ra,qa,Ja)=>{if(!(Ra&&qa==null))return Array.isArray(qa)||typeof qa=="string"?qa[Ja<0?qa.length+Ja:Ja]:qa.at(Ja)},G=gl;function vl(Ra,qa){if(typeof Ra=="string")return qa(Ra);let Ja=new Map;return ed(Ra);function ed(rd){if(Ja.has(rd))return Ja.get(rd);let sd=td(rd);return Ja.set(rd,sd),sd}function td(rd){switch(Ve(rd)){case Be:return qa(rd.map(ed));case xe $ 1:return qa({...rd,parts:rd.parts.map(ed)});case oe:return qa({...rd,breakContents:ed(rd.breakContents),flatContents:ed(rd.flatContents)});case ve:{let{expandedStates:sd,contents:od}=rd;return sd?(sd=sd.map(ed),od=sd[0]):od=ed(od),qa({...rd,contents:od,expandedStates:sd})}case ge:case we:case $ e $ 1:case ze:case We:return qa({...rd,contents:ed(rd.contents)});case Me $ 1:case Ue:case Fe:case Ye:case K:case be $ 1:return qa(rd);default:throw new $ r(rd)}}}function xl $ 1(Ra){return Ra.type===K&&!Ra.hard?Ra.soft?"":" ":Ra.type===oe?Ra.flatContents:Ra}function rn(Ra){return vl(Ra,xl $ 1)}function bl(Ra){return Array.isArray(Ra)&&Ra.length>0}var ee=bl,Et="'",sn='"';function _l(Ra,qa){let Ja=qa===!0||qa===Et?Et:sn,ed=Ja===Et?sn:Et,td=0,rd=0;for(let sd of Ra)sd===Ja?td++:sd===ed&&rd++;return td>rd?ed:Ja}var nn=_l;function kl(Ra,qa,Ja){let ed=qa==='"'?"'":'"',td=_ $ 1(!1,Ra,/ \\ (.)|(["'])/gsu,(rd,sd,od)=>sd===ed?sd:od===qa?" \\ "+od:od||(Ja&&/^[^ \n \r "'0-7 \\ bfnrt-vx \u 2028 \u 2029] $ /u.test(sd)?sd:" \\ "+sd));return qa+td+qa}var on=kl;function El $ 1(Ra,qa){let Ja=Ra.slice(1,-1),ed=qa.parser==="json"||qa.parser==="jsonc"||qa.parser==="json5"&&qa.quoteProps==="preserve"&&!qa.singleQuote?'"':qa.__isInHtmlAttribute?"'":nn(Ja,qa.singleQuote);return on(Ja,ed,!(qa.parser==="css"||qa.parser==="less"||qa.parser==="scss"||qa.__embeddedInHtml))}var St=El $ 1,Wr=class extends Error{constructor(qa,Ja,ed="type"){super( ` Unexpected $ { Ja } node $ { ed } : $ { JSON . stringify ( qa [ ed ] ) } . ` );n_(this,"name","UnexpectedNodeError");this.node=qa}},an=Wr;function Sl $ 1(Ra){return(Ra==null?void 0:Ra.type)==="front-matter"}var _e=Sl $ 1,Tl $ 1=new Set(["raw","raws","sourceIndex","source","before","after","trailingComma","spaces"]);function un(Ra,qa,Ja){if(_e(Ra)&&Ra.language==="yaml"&&delete qa.value,Ra.type==="css-comment"&&Ja.type==="css-root"&&Ja.nodes.length>0&&((Ja.nodes[0]===Ra||_e(Ja.nodes[0])&&Ja.nodes[1]===Ra)&&(delete qa.text,/^ \* \s *@(?:format|prettier) \s * $ /u.test(Ra.text))||Ja.type==="css-root"&&G(!1,Ja.nodes,-1)===Ra))return null;if(Ra.type==="value-root"&&delete qa.text,(Ra.type==="media-query"||Ra.type==="media-query-list"||Ra.type==="media-feature-expression")&&delete qa.value,Ra.type==="css-rule"&&delete qa.params,(Ra.type==="media-feature"||Ra.type==="media-keyword"||Ra.type==="media-type"||Ra.type==="media-unknown"||Ra.type==="media-url"||Ra.type==="media-value"||Ra.type==="selector-attribute"||Ra.type==="selector-string"||Ra.type==="selector-class"||Ra.type==="selector-combinator"||Ra.type==="value-string")&&Ra.value&&(qa.value=Ol $ 1(Ra.value)),Ra.type==="selector-combinator"&&(qa.value=_ $ 1(!1,qa.value,/ \s +/gu," ")),Ra.type==="media-feature"&&(qa.value=_ $ 1(!1,qa.value," ","")),(Ra.type==="value-word"&&(Ra.isColor&&Ra.isHex||["initial","inherit","unset","revert"].includes(Ra.value.toLowerCase()))||Ra.type==="media-feature"||Ra.type==="selector-root-invalid"||Ra.type==="selector-pseudo")&&(qa.value=qa.value.toLowerCase()),Ra.type==="css-decl"
2024-09-08 17:22:36 +08:00
` ,Ja)+1;return Ja+Ra.column}var zr=Il $ 1;function Tt $ 1(Ra){return(qa,Ja,ed)=>{let td=!!(ed!=null&&ed.backwards);if(Ja===!1)return!1;let{length:rd}=qa,sd=Ja;for(;sd>=0&&sd<rd;){let od=qa.charAt(sd);if(Ra instanceof RegExp){if(!Ra.test(od))return sd}else if(!Ra.includes(od))return sd;td?sd--:sd++}return sd===-1||sd===rd?sd:!1}}var Ot $ 1=Tt $ 1(" "),yn=Tt $ 1(",; "),Ct $ 1=Tt $ 1(/[^ \n \r ]/u);function wn $ 1(Ra,qa){var Ja,ed,td;if(typeof((ed=(Ja=Ra.source)==null?void 0:Ja.start)==null?void 0:ed.offset)=="number")return Ra.source.start.offset;if(typeof Ra.sourceIndex=="number")return Ra.sourceIndex;if((td=Ra.source)!=null&&td.start)return zr(Ra.source.start,qa);throw Object.assign(new Error("Can not locate node."),{node:Ra})}function Vr(Ra,qa){var Ja,ed;if(Ra.type==="css-comment"&&Ra.inline)return Ct $ 1(qa,Ra.source.startOffset);if(typeof((ed=(Ja=Ra.source)==null?void 0:Ja.end)==null?void 0:ed.offset)=="number")return Ra.source.end.offset;if(Ra.source){if(Ra.source.end)return zr(Ra.source.end,qa);if(ee(Ra.nodes))return Vr(G(!1,Ra.nodes,-1),qa)}return null}function Gr(Ra,qa){Ra.source&&(Ra.source.startOffset=wn $ 1(Ra,qa),Ra.source.endOffset=Vr(Ra,qa));for(let Ja in Ra){let ed=Ra[Ja];Ja==="source"||!ed||typeof ed!="object"||(ed.type==="value-root"||ed.type==="value-unknown"?gn $ 1(ed,ql $ 1(Ra),ed.text||ed.value):Gr(ed,qa))}}function gn $ 1(Ra,qa,Ja){Ra.source&&(Ra.source.startOffset=wn $ 1(Ra,Ja)+qa,Ra.source.endOffset=Vr(Ra,Ja)+qa);for(let ed in Ra){let td=Ra[ed];ed==="source"||!td||typeof td!="object"||gn $ 1(td,qa,Ja)}}function ql $ 1(Ra){var qa;let Ja=Ra.source.startOffset;return typeof Ra.prop=="string"&&(Ja+=Ra.prop.length),Ra.type==="css-atrule"&&typeof Ra.name=="string"&&(Ja+=1+Ra.name.length+Ra.raws.afterName.match(/^ \s *:? \s */u)[0].length),Ra.type!=="css-atrule"&&typeof((qa=Ra.raws)==null?void 0:qa.between)=="string"&&(Ja+=Ra.raws.between.length),Ja}function vn(Ra){let qa="initial",Ja="initial",ed,td=!1,rd=[];for(let sd=0;sd<Ra.length;sd++){let od=Ra[sd];switch(qa){case"initial":if(od==="'"){qa="single-quotes";continue}if(od==='"'){qa="double-quotes";continue}if((od==="u"||od==="U")&&Ra.slice(sd,sd+4).toLowerCase()==="url("){qa="url",sd+=3;continue}if(od==="*"&&Ra[sd-1]==="/"){qa="comment-block";continue}if(od==="/"&&Ra[sd-1]==="/"){qa="comment-inline",ed=sd-1;continue}continue;case"single-quotes":if(od==="'"&&Ra[sd-1]!==" \\ "&&(qa=Ja,Ja="initial"),od=== `
2024-09-03 08:22:14 +08:00
` ||od===" \r ")return Ra;continue;case"double-quotes":if(od==='"'&&Ra[sd-1]!==" \\ "&&(qa=Ja,Ja="initial"),od=== `
` ||od===" \r ")return Ra;continue;case"url":if(od===")"&&(qa="initial"),od=== `
` ||od===" \r ")return Ra;if(od==="'"){qa="single-quotes",Ja="url";continue}if(od==='"'){qa="double-quotes",Ja="url";continue}continue;case"comment-block":od==="/"&&Ra[sd-1]==="*"&&(qa="initial");continue;case"comment-inline":(od==='"'||od==="'"||od==="*")&&(td=!0),(od=== `
` ||od===" \r ")&&(td&&rd.push([ed,sd]),qa="initial",td=!1);continue}}for(let[sd,od]of rd)Ra=Ra.slice(0,sd)+_ $ 1(!1,Ra.slice(sd,od),/["'*]/gu," ")+Ra.slice(od);return Ra}function N(Ra){var qa;return(qa=Ra.source)==null?void 0:qa.startOffset}function P(Ra){var qa;return(qa=Ra.source)==null?void 0:qa.endOffset}var Ll $ 1=/ \* \/ $ /,Dl=/^ \/ \* \* ?/,kn=/^ \s *( \/ \* \* ?(.| \r ? \n )*? \* \/ )/,Ml=/(^| \s +) \/ \/ ([^ \n \r ]*)/g,xn=/^( \r ? \n )+/,Bl=/(?:^| \r ? \n ) *(@[^ \n \r ]*?) * \r ? \n *(?![^ \n \r @]* \/ \/ [^]*)([^ \s @][^ \n \r @]+?) * \r ? \n /g,bn $ 1=/(?:^| \r ? \n ) *@( \S +) *([^ \n \r ]*)/g,Ul=/( \r ? \n |^) * \* ?/g,En=[];function Sn(Ra){let qa=Ra.match(kn);return qa?qa[0].trimStart():""}function Tn $ 1(Ra){let qa=Ra.match(kn),Ja=qa==null?void 0:qa[0];return Ja==null?Ra:Ra.slice(Ja.length)}function On(Ra){let qa= `
` ;Ra=_ $ 1(!1,Ra.replace(Dl,"").replace(Ll $ 1,""),Ul," $ 1");let Ja="";for(;Ja!==Ra;)Ja=Ra,Ra=_ $ 1(!1,Ra,Bl, ` $ { qa } $1 $2$ { qa } ` );Ra=Ra.replace(xn,"").trimEnd();let ed=Object.create(null),td=_ $ 1(!1,Ra,bn $ 1,"").replace(xn,"").trimEnd(),rd;for(;rd=bn $ 1.exec(Ra);){let sd=_ $ 1(!1,rd[2],Ml,"");if(typeof ed[rd[1]]=="string"||Array.isArray(ed[rd[1]])){let od=ed[rd[1]];ed[rd[1]]=[...En,...Array.isArray(od)?od:[od],sd]}else ed[rd[1]]=sd}return{comments:td,pragmas:ed}}function Cn $ 1({comments:Ra="",pragmas:qa={}}){let Ja= `
` ,ed="/**",td=" *",rd=" */",sd=Object.keys(qa),od=sd.flatMap(cd=>_n $ 1(cd,qa[cd])).map(cd=> ` $ { td } $ { cd } $ { Ja } ` ).join("");if(!Ra){if(sd.length===0)return"";if(sd.length===1&&!Array.isArray(qa[sd[0]])){let cd=qa[sd[0]];return ` $ { ed } $ { _n$1 ( sd [ 0 ] , cd ) [ 0 ] } $ { rd } ` }}let ld=Ra.split(Ja).map(cd=> ` $ { td } $ { cd } ` ).join(Ja)+Ja;return ed+Ja+(Ra?ld:"")+(Ra&&sd.length>0?td+Ja:"")+od+rd}function _n $ 1(Ra,qa){return[...En,...Array.isArray(qa)?qa:[qa]].map(Ja=> ` @ $ { Ra } $ { Ja } ` .trim())}function Fl $ 1(Ra){if(!Ra.startsWith("#!"))return"";let qa=Ra.indexOf( `
` );return qa===-1?Ra:Ra.slice(0,qa)}var An=Fl $ 1;function Nn(Ra){let qa=An(Ra);qa&&(Ra=Ra.slice(qa.length+1));let Ja=Sn(Ra),{pragmas:ed,comments:td}=On(Ja);return{shebang:qa,text:Ra,pragmas:ed,comments:td}}function Pn $ 1(Ra){let{pragmas:qa}=Nn(Ra);return Object.prototype.hasOwnProperty.call(qa,"prettier")||Object.prototype.hasOwnProperty.call(qa,"format")}function Rn(Ra){let{shebang:qa,text:Ja,pragmas:ed,comments:td}=Nn(Ra),rd=Tn $ 1(Ja),sd=Cn $ 1({pragmas:{format:"",...ed},comments:td.trimStart()});return(qa? ` $ { qa }
` :"")+sd+(rd.startsWith( `
2024-08-30 15:19:18 +08:00
` )? `
` : `
2024-08-27 22:31:52 +08:00
2024-08-30 15:19:18 +08:00
` )+rd}var Qe=3;function $ l(Ra){let qa=Ra.slice(0,Qe);if(qa!=="---"&&qa!=="+++")return;let Ja=Ra.indexOf( `
` ,Qe);if(Ja===-1)return;let ed=Ra.slice(Qe,Ja).trim(),td=Ra.indexOf( `
$ { qa } ` ,Ja),rd=ed;if(rd||(rd=qa==="+++"?"toml":"yaml"),td===-1&&qa==="---"&&rd==="yaml"&&(td=Ra.indexOf( `
2024-09-08 17:22:36 +08:00
... ` ,Ja)),td===-1)return;let sd=td+1+Qe,od=Ra.charAt(sd+1);if(!/ \s ?/u.test(od))return;let ld=Ra.slice(0,sd);return{type:"front-matter",language:rd,explicitLanguage:ed,value:Ra.slice(Ja+1,td),startDelimiter:qa,endDelimiter:ld.slice(-Qe),raw:ld}}function Wl(Ra){let qa= $ l(Ra);if(!qa)return{content:Ra};let{raw:Ja}=qa;return{frontMatter:qa,content:_ $ 1(!1,Ja,/[^ \n ]/gu," ")+Ra.slice(Ja.length)}}var Je $ 1=Wl;function In(Ra){return Pn $ 1(Je $ 1(Ra).content)}function qn $ 1(Ra){let{frontMatter:qa,content:Ja}=Je $ 1(Ra);return(qa?qa.raw+ `
2024-08-30 15:19:18 +08:00
2024-09-08 17:22:36 +08:00
` :"")+Rn(Ja)}var Yl=new Set(["red","green","blue","alpha","a","rgb","hue","h","saturation","s","lightness","l","whiteness","w","blackness","b","tint","shade","blend","blenda","contrast","hsl","hsla","hwb","hwba"]);function Ln(Ra){var qa,Ja;return(Ja=(qa=Ra.findAncestor(ed=>ed.type==="css-decl"))==null?void 0:qa.prop)==null?void 0:Ja.toLowerCase()}var zl $ 1=new Set(["initial","inherit","unset","revert"]);function Dn $ 1(Ra){return zl $ 1.has(Ra.toLowerCase())}function Mn(Ra,qa){var Ja;let ed=Ra.findAncestor(td=>td.type==="css-atrule");return((Ja=ed==null?void 0:ed.name)==null?void 0:Ja.toLowerCase().endsWith("keyframes"))&&["from","to"].includes(qa.toLowerCase())}function te(Ra){return Ra.includes(" $ ")||Ra.includes("@")||Ra.includes("#")||Ra.startsWith("%")||Ra.startsWith("--")||Ra.startsWith(":--")||Ra.includes("(")&&Ra.includes(")")?Ra:Ra.toLowerCase()}function ke $ 1(Ra,qa){var Ja;let ed=Ra.findAncestor(td=>td.type==="value-func");return((Ja=ed==null?void 0:ed.value)==null?void 0:Ja.toLowerCase())===qa}function Bn $ 1(Ra){var qa;let Ja=Ra.findAncestor(td=>td.type==="css-rule"),ed=(qa=Ja==null?void 0:Ja.raws)==null?void 0:qa.selector;return ed&&(ed.startsWith(":import")||ed.startsWith(":export"))}function Ee(Ra,qa){let Ja=Array.isArray(qa)?qa:[qa],ed=Ra.findAncestor(td=>td.type==="css-atrule");return ed&&Ja.includes(ed.name.toLowerCase())}function Un(Ra){var qa;let{node:Ja}=Ra;return Ja.groups[0].value==="url"&&Ja.groups.length===2&&((qa=Ra.findAncestor(ed=>ed.type==="css-atrule"))==null?void 0:qa.name)==="import"}function Fn(Ra){return Ra.type==="value-func"&&Ra.value.toLowerCase()==="url"}function $ n $ 1(Ra){return Ra.type==="value-func"&&Ra.value.toLowerCase()==="var"}function Wn(Ra){let{selector:qa}=Ra;return qa?typeof qa=="string"&&/^@.+:.* $ /u.test(qa)||qa.value&&/^@.+:.* $ /u.test(qa.value):!1}function Yn $ 1(Ra){return Ra.type==="value-word"&&["from","through","end"].includes(Ra.value)}function zn(Ra){return Ra.type==="value-word"&&["and","or","not"].includes(Ra.value)}function Vn(Ra){return Ra.type==="value-word"&&Ra.value==="in"}function At $ 1(Ra){return Ra.type==="value-operator"&&Ra.value==="*"}function Xe(Ra){return Ra.type==="value-operator"&&Ra.value==="/"}function Q $ 1(Ra){return Ra.type==="value-operator"&&Ra.value==="+"}function le(Ra){return Ra.type==="value-operator"&&Ra.value==="-"}function Vl(Ra){return Ra.type==="value-operator"&&Ra.value==="%"}function Nt(Ra){return At $ 1(Ra)||Xe(Ra)||Q $ 1(Ra)||le(Ra)||Vl(Ra)}function Gn $ 1(Ra){return Ra.type==="value-word"&&["==","!="].includes(Ra.value)}function jn $ 1(Ra){return Ra.type==="value-word"&&["<",">","<=",">="].includes(Ra.value)}function Ze(Ra,qa){return qa.parser==="scss"&&Ra.type==="css-atrule"&&["if","else","for","each","while"].includes(Ra.name)}function Hr(Ra){var qa;return((qa=Ra.raws)==null?void 0:qa.params)&&/^ \( \s * \) $ /u.test(Ra.raws.params)}function Pt(Ra){return Ra.name.startsWith("prettier-placeholder")}function Hn(Ra){return Ra.prop.startsWith("@prettier-placeholder")}function Kn(Ra,qa){return Ra.value===" $ $ "&&Ra.type==="value-func"&&(qa==null?void 0:qa.type)==="value-word"&&!qa.raws.before}function Qn $ 1(Ra){var qa,Ja;return((qa=Ra.value)==null?void 0:qa.type)==="value-root"&&((Ja=Ra.value.group)==null?void 0:Ja.type)==="value-value"&&Ra.prop.toLowerCase()==="composes"}function Jn $ 1(Ra){var qa,Ja,ed;return((ed=(Ja=(qa=Ra.value)==null?void 0:qa.group)==null?void 0:Ja.group)==null?void 0:ed.type)==="value-paren_group"&&Ra.value.group.group.open!==null&&Ra.value.group.group.close!==null}function ce(Ra){var qa;return((qa=Ra.raws)==null?void 0:qa.before)===""}function Rt $ 1(Ra){var qa,Ja;return Ra.type==="value-comma_group"&&((Ja=(qa=Ra.groups)==null?void 0:qa[1])==null?void 0:Ja.type)==="value-colon"}function jr(Ra){var qa;return Ra.type==="value-paren_group"&&((qa=Ra.groups)==null?void 0:qa[0])&&Rt $ 1(Ra.groups[0])}function Kr(Ra,qa){var Ja;if(qa.parser!=="scss")return!1;let{node:ed}=Ra;if(ed.groups.length===0)return!1;let td=Ra.grandparent;if(!jr(ed)&&!(td&&jr(td)))return!1;let rd=Ra.findAncestor(sd=>sd.type==="css-decl");return!!((Ja=rd==null?void 0:rd.prop)!=n
2024-08-30 15:19:18 +08:00
` )return qa-2;if(td=== `
` ||td===" \r "||td===" \u 2028"||td===" \u 2029")return qa-1}else{if(td===" \r "&&Ra.charAt(qa+1)=== `
` )return qa+2;if(td=== `
2024-09-08 17:22:36 +08:00
` ||td===" \r "||td===" \u 2028"||td===" \u 2029")return qa+1}return qa}var Dt $ 1=Xl $ 1;function Zl(Ra,qa,Ja={}){let ed=Ot $ 1(Ra,Ja.backwards?qa-1:qa,Ja),td=Dt $ 1(Ra,ed,Ja);return ed!==td}var Mt=Zl;function ec $ 1(Ra,qa){if(qa===!1)return!1;if(Ra.charAt(qa)==="/"&&Ra.charAt(qa+1)==="*"){for(let Ja=qa+2;Ja<Ra.length;++Ja)if(Ra.charAt(Ja)==="*"&&Ra.charAt(Ja+1)==="/")return Ja+2}return qa}var ui=ec $ 1;function tc(Ra,qa){return qa===!1?!1:Ra.charAt(qa)==="/"&&Ra.charAt(qa+1)==="/"?Ct $ 1(Ra,qa):qa}var li $ 1=tc;function rc(Ra,qa){let Ja=null,ed=qa;for(;ed!==Ja;)Ja=ed,ed=yn(Ra,ed),ed=ui(Ra,ed),ed=Ot $ 1(Ra,ed);return ed=li $ 1(Ra,ed),ed=Dt $ 1(Ra,ed),ed!==!1&&Mt(Ra,ed)}var Bt $ 1=rc;function sc({node:Ra,parent:qa},Ja){return!!(Ra.source&&Ja.originalText.slice(N(Ra),N(qa.close)).trimEnd().endsWith(","))}function nc $ 1(Ra,qa){return $ n $ 1(Ra.grandparent)&&sc(Ra,qa)?",":Ra.node.type!=="value-comment"&&!(Ra.node.type==="value-comma_group"&&Ra.node.groups.every(Ja=>Ja.type==="value-comment"))&&ai $ 1(qa)&&Ra.callParent(()=>Kr(Ra,qa))?kt(","):""}function ci(Ra,qa,Ja){let{node:ed,parent:td}=Ra,rd=Ra.map(({node:gd})=>typeof gd=="string"?gd:Ja(),"groups");if(td&&Fn(td)&&(ed.groups.length===1||ed.groups.length>0&&ed.groups[0].type==="value-comma_group"&&ed.groups[0].groups.length>0&&ed.groups[0].groups[0].type==="value-word"&&ed.groups[0].groups[0].value.startsWith("data:")))return[ed.open?Ja("open"):"",V(",",rd),ed.close?Ja("close"):""];if(!ed.open){let gd=es(Ra),Ed=V([",",gd?E:A],rd);return q(gd?[E,Ed]:L(Ge(Ed)))}let sd=Ra.map(({node:gd,isLast:Ed,index:Td})=>{var Od;let Rd=rd[Td];if(Rt $ 1(gd)&&gd.type==="value-comma_group"&&gd.groups&&gd.groups[0].type!=="value-paren_group"&&((Od=gd.groups[2])==null?void 0:Od.type)==="value-paren_group"){let{parts:Id}=Rd.contents.contents;Id[1]=L(Id[1]),Rd=L(ue(Rd))}let Nd=[Rd,Ed?nc $ 1(Ra,qa):","];if(!Ed&&gd.type==="value-comma_group"&&ee(gd.groups)){let Id=G(!1,gd.groups,-1);!Id.source&&Id.close&&(Id=Id.close),Id.source&&Bt $ 1(qa.originalText,P(Id))&&Nd.push(E)}return Nd},"groups"),od=Xn $ 1(ed,td),ld=ti $ 1(ed,td),cd=Kr(Ra,qa),ud=ld||cd&&!od,_d=ld||od,yd=L([ed.open?Ja("open"):"",q([M,V(A,sd)]),M,ed.close?Ja("close"):""],{shouldBreak:ud});return _d?ue(yd):yd}function es(Ra){return Ra.match(qa=>qa.type==="value-paren_group"&&!qa.open&&qa.groups.some(Ja=>Ja.type==="value-comma_group"),(qa,Ja)=>Ja==="group"&&qa.type==="value-value",(qa,Ja)=>Ja==="group"&&qa.type==="value-root",(qa,Ja)=>Ja==="value"&&(qa.type==="css-decl"&&!qa.prop.startsWith("--")||qa.type==="css-atrule"&&qa.variable))}function ic(Ra,qa,Ja){let ed=[];return Ra.each(()=>{let{node:td,previous:rd}=Ra;if((rd==null?void 0:rd.type)==="css-comment"&&rd.text.trim()==="prettier-ignore"?ed.push(qa.originalText.slice(N(td),P(td))):ed.push(Ja()),Ra.isLast)return;let{next:sd}=Ra;sd.type==="css-comment"&&!Mt(qa.originalText,N(sd),{backwards:!0})&&!_e(td)||sd.type==="css-atrule"&&sd.name==="else"&&td.type!=="css-comment"?ed.push(" "):(ed.push(qa.__isHTMLStyleAttribute?A:E),Bt $ 1(qa.originalText,P(td))&&!_e(td)&&ed.push(E))},"nodes"),ed}var Te=ic;function oc $ 1(Ra,qa,Ja){var ed,td,rd,sd,od,ld;let{node:cd}=Ra;switch(cd.type){case"front-matter":return[cd.raw,E];case"css-root":{let ud=Te(Ra,qa,Ja),_d=cd.raws.after.trim();return _d.startsWith(";")&&(_d=_d.slice(1).trim()),[cd.frontMatter?[Ja("frontMatter"),E]:"",ud,_d? ` $ { _d } ` :"",cd.nodes.length>0?E:""]}case"css-comment":{let ud=cd.inline||cd.raws.inline,_d=qa.originalText.slice(N(cd),P(cd));return ud?_d.trimEnd():_d}case"css-rule":return[Ja("selector"),cd.important?" !important":"",cd.nodes?[((ed=cd.selector)==null?void 0:ed.type)==="selector-unknown"&&Se(cd.selector.value)?A:cd.selector?" ":"","{",cd.nodes.length>0?q([E,Te(Ra,qa,Ja)]):"",E,"}",Wn(cd)?";":""]:";"];case"css-decl":{let ud=Ra.parent,{between:_d}=cd.raws,yd=_d.trim(),gd=yd===":",Ed=typeof cd.value=="string"&&/^ * $ /u.test(cd.value),Td=typeof cd.value=="string"?cd.value:Ja("value");return Td=Qn $ 1(cd)?rn(Td):Td,!gd&&Se(yd)&&!((rd=(td=cd.value)==null?void 0:td.group)!=null&&rd.group&&Ra.call(()=>es(Ra),"value","group","group"))&&(Td=q([E,ue(Td)])),[_ $ 1(!1,cd.raws.before,/[ \s ;]/gu,"
2024-08-30 15:19:18 +08:00
` }return ed}function toBase64(Ra){return new Promise((qa,Ja)=>{const ed=new FileReader;ed.readAsDataURL(Ra),ed.onload=()=>qa(ed.result.split(",").pop()),ed.onerror=td=>Ja(td)})}function checkImage(Ra){if(!/ \. (?:gif|jpe?g|png) $ /i.test(Ra.name))return{ok:!1,msg:"请上传 JPG/PNG/GIF 格式的图片"};const Ja=10;return Ra.size>Ja*1024*1024?{ok:!1,msg: ` 由于公众号限制 , 图片大小不能超过 $ { Ja } M ` }:{ok:!0}}function removeLeft(Ra){const qa=Ra.split( `
` ),Ja=qa.filter(ed=>ed.trim()).map(ed=>ed.match(/(^ \s +)?/)[0].length).sort((ed,td)=>ed-td)[0];return qa.map(ed=>ed.slice(Ja)).join( `
2024-09-08 19:53:57 +08:00
` )}function solveWeChatImage(){const qa=document.getElementById("output").getElementsByTagName("img");for(let Ja=0;Ja<qa.length;Ja++){const ed=qa[Ja],td=ed.getAttribute("width"),rd=ed.getAttribute("height");ed.removeAttribute("width"),ed.removeAttribute("height"),ed.style.width=td,ed.style.height=rd}}function mergeCss(Ra){return juice(Ra,{inlinePseudoElements:!0,preserveImportant:!0})}const useStore=defineStore("store",()=>{const Ra=useDark(),qa=useToggle(Ra),Ja=useStorage("isMacCodeBlock",!0),ed=useToggle(Ja),td=useStorage("isEditOnLeft",!0),rd=useToggle(td),sd=useStorage("isCiteStatus",!1),od=useToggle(sd),ld=ref $ 1(""),cd=useStorage(addPrefix("theme"),themeOptions[0].value),ud=useStorage("fonts",fontFamilyOptions[0].value),_d=useStorage("size",fontSizeOptions[2].value),yd=useStorage("color",colorOptions[0].value),gd=useStorage("codeBlockTheme",codeBlockThemeOptions[23].value),Ed=useStorage("legend",legendOptions[3].value),Td=computed(()=>_d.value.replace("px","")),Od=initRenderer({theme:customizeTheme(themeMap[cd.value],{fontSize:Td.value,color:yd.value}),fonts:ud.value,size:_d}),Rd=ref $ 1(null),Nd=useStorage("__editor_content",DEFAULT_CONTENT),Id=()=>{formatDoc(Rd.value.getValue()).then(Ef=>{Nd.value=Ef,Rd.value.setValue(Ef)})},Md=()=>{const Ef=gd.value,Af=document.querySelector("#hljs");if(Af)Af.setAttribute("href",Ef);else{const Pf=document.createElement("link");Pf.setAttribute("type","text/css"),Pf.setAttribute("rel","stylesheet"),Pf.setAttribute("href",Ef),Pf.setAttribute("id","hljs"),document.head.appendChild(Pf)}},Ld=()=>{Md(),Od.reset({status:sd.value,legend:Ed.value});let Ef=marked $ 1.parse(Rd.value.getValue(0));Ef=Ef.replace(/(style=".*?)"/,' $ 1;margin-top: 0"'),Ef+=Od.buildFootnotes(),Ef+=Od.buildAddition(),Ja.value&&(Ef+= `
2024-08-27 22:31:52 +08:00
< style >
2024-09-07 21:44:41 +08:00
. hljs . code _ _pre > . mac - sign {
display : inline - block ;
2024-08-27 22:31:52 +08:00
}
. hljs . code _ _pre {
padding : 0 ! important ;
}
. hljs . code _ _pre code {
display : - webkit - box ;
padding : 0.5 em 1 em 1 em ;
overflow - x : auto ;
text - indent : 0 ;
}
< / s t y l e >
2024-09-08 19:53:57 +08:00
` ),ld.value=Ef},Pd=ref $ 1(null),qd=Ef=>{Pd.value.setValue(Ef)},Yd=useStorage("__css_content",DEFAULT_CSS_CONTENT),Ud=useStorage(addPrefix("css_content_config"),{active:"方案1",tabs:[{title:"方案1",name:"方案1",content:Yd.value||DEFAULT_CSS_CONTENT}]});onMounted(()=>{Yd.value=""});const Hd=()=>Ud.value.tabs.find(Ef=>Ef.name===Ud.value.active),zd=Ef=>{Ud.value.active=Ef;const Af=Ud.value.tabs.find(Pf=>Pf.name===Ef).content;qd(Af)},Jd=Ef=>{const Af=Hd();Af.title=Ef,Af.name=Ef,Ud.value.active=Ef},Zd=Ef=>{Ud.value.tabs.push({name:Ef,title:Ef,content:DEFAULT_CSS_CONTENT}),Ud.value.active=Ef,qd(DEFAULT_CSS_CONTENT)},pf=Ef=>Ud.value.tabs.every(({name:Af})=>Af!==Ef),Qd=()=>{const Ef=css2json(Pd.value.getValue()),Af=customCssWithTemplate(Ef,yd.value,customizeTheme(themeMap[cd.value],{fontSize:Td.value,color:yd.value}));Od.setOptions({theme:Af}),Ld()};onMounted(()=>{const Ef=document.querySelector("#cssEditor");Ef.value=Hd().content,Pd.value=markRaw(CodeMirror.fromTextArea(Ef,{mode:"css",theme:"style-mirror",lineNumbers:!1,lineWrapping:!0,matchBrackets:!0,autofocus:!0,extraKeys:{[ ` $ { shiftKey } - $ { altKey } - F ` ]:function(Pf){formatDoc(Pf.getValue(),"css").then(hh=>{Hd().content=hh,Pf.setValue(hh)})}}})),Pd.value.on("keyup",(Af,Pf)=>{(Pf.keyCode>=65&&Pf.keyCode<=90||Pf.keyCode===189)&&Af.showHint(Pf)}),Pd.value.on("update",()=>{Qd(),Hd().content=Pd.value.getValue()})});const hf=()=>{sd.value=!1,Ja.value=!0,cd.value=themeOptions[0].value,ud.value=fontFamilyOptions[0].value,ud.value=fontFamilyOptions[0].value,_d.value=fontSizeOptions[2].value,yd.value=colorOptions[0].value,gd.value=codeBlockThemeOptions[2].value,Ed.value=legendOptions[3].value,Ud.value={active:"方案 1",tabs:[{title:"方案 1",name:"方案 1",content:Yd.value||DEFAULT_CSS_CONTENT}]},Pd.value.setValue(DEFAULT_CSS_CONTENT),Qd(),Ld()},mf=Ef=>(...Af)=>{Ef(...Af),Ld()},xf=(Ef,Af)=>{const Pf=themeMap[cd.value],hh=Ef.replace("px","");return customizeTheme(Pf,{fontSize:hh,color:Af})},Lf=mf(Ef=>{Od.setOptions({theme:customizeTheme(themeMap[Ef],{fontSize:Td.value,color:yd.value})}),cd.value=Ef}),Kf=mf(Ef=>{Od.setOptions({fonts:Ef}),ud.value=Ef}),Yf=mf(Ef=>{const Af=xf(Ef,yd.value);Od.setOptions({size:Ef,theme:Af}),_d.value=Ef}),Of=mf(Ef=>{const Af=xf(_d.value,Ef);Od.setOptions({theme:Af}),yd.value=Ef}),Tf=mf(Ef=>{gd.value=Ef}),wf=mf(Ef=>{Ed.value=Ef}),Wf=mf(()=>{ed()}),Uf=mf(()=>{od()}),gf=()=>{exportHTML(),document.querySelector("#output").innerHTML=ld.value},_f=()=>{downloadMD(Rd.value.getValue())}, $ f=()=>{const Ef=document.body,Af=document.createElement("input");Af.type="file",Af.name="filename",Af.accept=".md",Af.onchange=()=>{const Pf=Af.files[0];if(!Pf)return;const hh=new FileReader;hh.readAsText(Pf),hh.onload=Ah=>{Rd.value.setValue(Ah.target.result),ElMessage.success("文档导入成功")}},Ef.appendChild(Af),Af.click(),Ef.removeChild(Af)},Gf=()=>{ElMessageBox.confirm("此操作将丢失本地自定义样式,是否继续?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning",center:!0}).then(()=>{hf(),ElMessage({type:"success",message:"样式重置成功~"})}).catch(()=>{Rd.value.focus()})},dh=ref $ 1(!1),zf=useToggle(dh),If=ref $ 1(!1),Jf=useToggle(If),Th=ref $ 1(!1),Vf=useToggle(Th);return{isShowCssEditor:dh,toggleShowCssEditor:zf,isShowInsertFormDialog:If,toggleShowInsertFormDialog:Jf,isShowUploadImgDialog:Th,toggleShowUploadImgDialog:Vf,isDark:Ra,toggleDark:qa,isEditOnLeft:td,toggleEditOnLeft:rd,isMacCodeBlock:Ja,isCiteStatus:sd,citeStatusChanged:Uf,output:ld,editor:Rd,cssEditor:Pd,theme:cd,fontFamily:ud,fontSize:_d,fontColor:yd,codeBlockTheme:gd,legend:Ed,editorRefresh:Ld,themeChanged:Lf,fontChanged:Kf,sizeChanged:Yf,colorChanged:Of,codeBlockThemeChanged:Tf,legendChanged:wf,macCodeBlockChanged:Wf,formatContent:Id,exportEditorContent2HTML:gf,exportEditorContent2MD:_f,importMarkdownContent: $ f,resetStyleConfirm:Gf,editorContent:Nd,cssContentConfig:Ud,addCssContentTab:Zd,validatorTabName:pf,setCssEditorValue:qd,tabChanged:zd,renameTab:Jd}}),Store=createPinia(),ElementPlus={install(Ra){Ra.config.globalProperties. $ loading=ElLoading.service,Ra
2024-08-27 22:31:52 +08:00
( c ) 2012 by Cédric Mesnil . All rights reserved .
Redistribution and use in source and binary forms , with or without modification , are permitted provided that the following conditions are met :
- Redistributions of source code must retain the above copyright notice , this list of conditions and the following disclaimer .
- Redistributions in binary form must reproduce the above copyright notice , this list of conditions and the following disclaimer in the documentation and / or other materials provided with the distribution .
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES , INCLUDING , BUT NOT LIMITED TO , THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED . IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT , INDIRECT , INCIDENTAL , SPECIAL , EXEMPLARY , OR CONSEQUENTIAL DAMAGES ( INCLUDING , BUT NOT LIMITED TO , PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES ; LOSS OF USE , DATA , OR PROFITS ; OR BUSINESS INTERRUPTION ) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY , WHETHER IN CONTRACT , STRICT LIABILITY , OR TORT ( INCLUDING NEGLIGENCE OR OTHERWISE ) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE , EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE .
2024-09-08 17:22:36 +08:00
* / r e t u r n f u n c t i o n ( e d ) { v a r t d = J a , r d = t d . l i b , s d = r d . W o r d A r r a y , o d = r d . H a s h e r , l d = t d . a l g o , c d = s d . c r e a t e ( [ 0 , 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 , 9 , 1 0 , 1 1 , 1 2 , 1 3 , 1 4 , 1 5 , 7 , 4 , 1 3 , 1 , 1 0 , 6 , 1 5 , 3 , 1 2 , 0 , 9 , 5 , 2 , 1 4 , 1 1 , 8 , 3 , 1 0 , 1 4 , 4 , 9 , 1 5 , 8 , 1 , 2 , 7 , 0 , 6 , 1 3 , 1 1 , 5 , 1 2 , 1 , 9 , 1 1 , 1 0 , 0 , 8 , 1 2 , 4 , 1 3 , 3 , 7 , 1 5 , 1 4 , 5 , 6 , 2 , 4 , 0 , 5 , 9 , 7 , 1 2 , 2 , 1 0 , 1 4 , 1 , 3 , 8 , 1 1 , 6 , 1 5 , 1 3 ] ) , u d = s d . c r e a t e ( [ 5 , 1 4 , 7 , 0 , 9 , 2 , 1 1 , 4 , 1 3 , 6 , 1 5 , 8 , 1 , 1 0 , 3 , 1 2 , 6 , 1 1 , 3 , 7 , 0 , 1 3 , 5 , 1 0 , 1 4 , 1 5 , 8 , 1 2 , 4 , 9 , 1 , 2 , 1 5 , 5 , 1 , 3 , 7 , 1 4 , 6 , 9 , 1 1 , 8 , 1 2 , 2 , 1 0 , 0 , 4 , 1 3 , 8 , 6 , 4 , 1 , 3 , 1 1 , 1 5 , 0 , 5 , 1 2 , 2 , 1 3 , 9 , 7 , 1 0 , 1 4 , 1 2 , 1 5 , 1 0 , 4 , 1 , 5 , 8 , 7 , 6 , 2 , 1 3 , 1 4 , 0 , 3 , 9 , 1 1 ] ) , _ d = s d . c r e a t e ( [ 1 1 , 1 4 , 1 5 , 1 2 , 5 , 8 , 7 , 9 , 1 1 , 1 3 , 1 4 , 1 5 , 6 , 7 , 9 , 8 , 7 , 6 , 8 , 1 3 , 1 1 , 9 , 7 , 1 5 , 7 , 1 2 , 1 5 , 9 , 1 1 , 7 , 1 3 , 1 2 , 1 1 , 1 3 , 6 , 7 , 1 4 , 9 , 1 3 , 1 5 , 1 4 , 8 , 1 3 , 6 , 5 , 1 2 , 7 , 5 , 1 1 , 1 2 , 1 4 , 1 5 , 1 4 , 1 5 , 9 , 8 , 9 , 1 4 , 5 , 6 , 8 , 6 , 5 , 1 2 , 9 , 1 5 , 5 , 1 1 , 6 , 8 , 1 3 , 1 2 , 5 , 1 2 , 1 3 , 1 4 , 1 1 , 8 , 5 , 6 ] ) , y d = s d . c r e a t e ( [ 8 , 9 , 9 , 1 1 , 1 3 , 1 5 , 1 5 , 5 , 7 , 7 , 8 , 1 1 , 1 4 , 1 4 , 1 2 , 6 , 9 , 1 3 , 1 5 , 7 , 1 2 , 8 , 9 , 1 1 , 7 , 7 , 1 2 , 7 , 6 , 1 5 , 1 3 , 1 1 , 9 , 7 , 1 5 , 1 1 , 8 , 6 , 6 , 1 4 , 1 2 , 1 3 , 5 , 1 4 , 1 3 , 1 3 , 7 , 5 , 1 5 , 5 , 8 , 1 1 , 1 4 , 1 4 , 6 , 1 4 , 6 , 9 , 1 2 , 9 , 1 2 , 5 , 1 5 , 8 , 8 , 5 , 1 2 , 9 , 1 2 , 5 , 1 4 , 6 , 8 , 1 3 , 6 , 5 , 1 5 , 1 3 , 1 1 , 1 1 ] ) , g d = s d . c r e a t e ( [ 0 , 1 5 1 8 5 0 0 2 4 9 , 1 8 5 9 7 7 5 3 9 3 , 2 4 0 0 9 5 9 7 0 8 , 2 8 4 0 8 5 3 8 3 8 ] ) , E d = s d . c r e a t e ( [ 1 3 5 2 8 2 9 9 2 6 , 1 5 4 8 6 0 3 6 8 4 , 1 8 3 6 0 7 2 6 9 1 , 2 0 5 3 9 9 4 2 1 7 , 0 ] ) , T d = l d . R I P E M D 1 6 0 = o d . e x t e n d ( { _ d o R e s e t : f u n c t i o n ( ) { t h i s . _ h a s h = s d . c r e a t e ( [ 1 7 3 2 5 8 4 1 9 3 , 4 0 2 3 2 3 3 4 1 7 , 2 5 6 2 3 8 3 1 0 2 , 2 7 1 7 3 3 8 7 8 , 3 2 8 5 3 7 7 5 2 0 ] ) } , _ d o P r o c e s s B l o c k : f u n c t i o n ( P d , q d ) { f o r ( v a r Y d = 0 ; Y d < 1 6 ; Y d + + ) { v a r U d = q d + Y d , H d = P d [ U d ] ; P d [ U d ] = ( H d < < 8 | H d > > > 2 4 ) & 1 6 7 1 1 9 3 5 | ( H d < < 2 4 | H d > > > 8 ) & 4 2 7 8 2 5 5 3 6 0 } v a r z d = t h i s . _ h a s h . w o r d s , J d = g d . w o r d s , Z d = E d . w o r d s , p f = c d . w o r d s , Q d = u d . w o r d s , h f = _ d . w o r d s , m f = y d . w o r d s , x f , L f , K f , Y f , O f , T f , w f , W f , U f , g f ; T f = x f = z d [ 0 ] , w f = L f = z d [ 1 ] , W f = K f = z d [ 2 ] , U f = Y f = z d [ 3 ] , g f = O f = z d [ 4 ] ; f o r ( v a r _ f , Y d = 0 ; Y d < 8 0 ; Y d + = 1 ) _ f = x f + P d [ q d + p f [ Y d ] ] | 0 , Y d < 1 6 ? _ f + = O d ( L f , K f , Y f ) + J d [ 0 ] : Y d < 3 2 ? _ f + = R d ( L f , K f , Y f ) + J d [ 1 ] : Y d < 4 8 ? _ f + = N d ( L f , K f , Y f ) + J d [ 2 ] : Y d < 6 4 ? _ f + = I d ( L f , K f , Y f ) + J d [ 3 ] : _ f + = M d ( L f , K f , Y f ) + J d [ 4 ] , _ f = _ f | 0 , _ f = L d ( _ f , h f [ Y d ] ) , _ f = _ f + O f | 0 , x f = O f , O f = Y f , Y f = L d ( K f , 1 0 ) , K f = L f , L f = _ f , _ f = T f + P d [ q d + Q d [ Y d ] ] | 0 , Y d < 1 6 ? _ f + = M d ( w f , W f , U f ) + Z d [ 0 ] : Y d < 3 2 ? _ f + = I d ( w f , W f , U f ) + Z d [ 1 ] : Y d < 4 8 ? _ f + = N d ( w f , W f , U f ) + Z d [ 2 ] : Y d < 6 4 ? _ f + = R d ( w f , W f , U f ) + Z d [ 3 ] : _ f + = O d ( w f , W f , U f ) + Z d [ 4 ] , _ f = _ f | 0 , _ f = L d ( _ f , m f [ Y d ] ) , _ f = _ f + g f | 0 , T f = g f , g f = U f , U f = L d ( W f , 1 0 ) , W f = w f , w f = _ f ; _ f = z d [ 1 ] + K f + U f | 0 , z d [ 1 ] = z d [ 2 ] + Y f + g f | 0 , z d [ 2 ] = z d [ 3 ] + O f + T f | 0 , z d [ 3 ] = z d [ 4 ] + x f + w f | 0 , z d [ 4 ] = z d [ 0 ] + L f + W f | 0 , z d [ 0 ] = _ f } , _ d o F i n a l i z e : f u n c t i o n ( ) { v a r P d = t h i s . _ d a t a , q d = P d . w o r d s , Y d = t h i s . _ n D a t a B y t e s * 8 , U d = P d . s i g B y t e s * 8 ; q d [ U d > > > 5 ] | = 1 2 8 < < 2 4 - U d % 3 2 , q d [ ( U d + 6 4 > > > 9 < < 4 ) + 1 4 ] = ( Y d < < 8 | Y d > > > 2 4 ) & 1 6 7 1 1 9 3 5 | ( Y d < < 2 4 | Y d > > > 8 ) & 4 2 7 8 2 5 5 3 6 0 , P d . s i g B y t e s = ( q d . l e n g t h + 1 ) * 4 , t h i s . _ p r o c e s s ( ) ; f o r ( v a r H d = t h i s . _ h a s h , z d = H d . w o r d s , J d = 0 ; J d < 5 ; J d + + ) { v a r Z d = z d [ J d ] ; z d [ J d ] = ( Z d < < 8 | Z d > > > 2 4 ) & 1 6 7 1 1 9 3 5 | ( Z d < < 2 4 | Z d > > > 8 ) & 4 2 7 8 2 5 5 3 6 0 } r e t u r n H d } , c l o n e : f u n c t i o n ( ) { v a r P d = o d . c l o n e . c a l l ( t h i s ) ; r e t u r n P d . _ h a s h = t h i s . _ h a s h . c l o n e ( ) , P d } } ) ; f u n c t i o n O d ( P d , q d , Y d ) { r e t u r n P d ^ q d ^ Y d } f u n c t i o n R d ( P d , q d , Y d ) { r e t u r n P d & q d | ~ P d & Y d } f u n c t i o n N d ( P d , q d , Y d ) { r e t u r n ( P d | ~ q d ) ^ Y d } f u n c t i o n I d ( P d , q d , Y d ) { r e t u r n P d & Y d | q d & ~ Y d } f u n c t i o n M d ( P d , q d , Y d ) { r e t u r n P d ^ ( q d | ~ Y d ) } f u n c t i o n L d ( P d , q d ) { r e t u r n P d < < q d | P d > > > 3 2 - q d } t d . R I P E M D 1 6 0 = o d . _ c r e a t e H e l p e r ( T d ) , t d . H m a c R I P E M D 1 6 0 = o d . _ c r e a t e H m a c H e l p e r ( T d ) } ( ) , J a . R I P E M D 1 6 0 } ) } ( r i p e m d 1 6 0 ) ) , r i p e m d 1 6 0 . e x p o r t s } v a r h m a c = { e x p o r t s : { } } , h a s R e q u i r e d H m a c ; f u n c t i o n r e q u i r e H m a c ( ) { r e t u r n h a s R e q u i r e d H m a c | | ( h a s R e q u i r e d H m a c = 1 , f u n c t i o n ( R a , q a ) { ( f u n c t i o n ( J a , e d ) { R a . e x p o r t s = e d ( r e q u i r e C o r e ( ) ) } ) ( c o m m o n j s G l o b a l , f u n c t i o n ( J a ) { ( f u n c t i o n ( ) { v a r e d = J a , t d = e d . l i b , r d = t d . B a s e , s d = e d . e n c , o d = s d . U t f 8 , l d = e d . a l g o ; l d . H M A C = r d . e x t e n d ( { i n i t : f u n c t i o n ( c d , u d ) { c d = t h i s . _ h a s h e r = n e w c d . i n i t , t y p e o f u d = = " s t r i n g " & & ( u d = o d . p a r s e ( u d ) ) ; v a r _ d = c d . b l o c k S i z e , y d = _ d * 4 ; u d . s i g B y t e s > y d & & ( u d = c d . f i n a l i z e ( u d ) ) , u d . c l a m p ( ) ; f o r ( v a r g d = t h i s . _ o K e y = u d . c l o n e ( ) , E d = t h i s . _ i K e y = u d . c l o n e ( ) , T d = g d . w o r d s , O d = E d . w o r d s , R d = 0 ; R d < _ d ; R d + + ) T d [ R d ] ^ = 1 5 4 9 5 5 6 8 2 8 , O d [ R d ] ^ = 9 0 9 5 2 2 4 8 6 ; g d . s i g B y t e s = E d . s i g B y t e s = y d , t h i s . r e s e t ( ) } , r e s e t : f u n c t i o n ( ) { v a r c d = t h i s . _ h a s h e r ; c d . r e s e t ( ) , c d . u p d a t e ( t h i s . _ i K e y ) } , u p d a t e : f u n c t i o n ( c d ) { r e t u r n t h i s . _ h a s h e r . u p d a t e ( c d ) , t h i s } , f i n a l i z e : f u n c t i o n ( c d ) { v a r u d = t h i s . _ h a s h e r , _ d = u d . f i n a l i z e ( c d ) ; u d . r e s e t ( ) ; v a r y d = u d . f i n a l i z e ( t h i s . _ o K e y . c l o n e ( ) . c o n c a t ( _ d ) ) ; r e t u r n y d } } ) } ) ( ) } ) } ( h m a c ) ) , h m a c . e x p o r t s } v a r p b k d f 2 = { e x p o r t s : { } } , h a s R e q u i r e d P b k d f 2 ; f u n c t i o n r e q u i r e P b k d f 2 ( ) { r e t u r n h a s R e q u i r e d P b k d f 2 | | ( h a s R e q u i r e d P b k d f 2 = 1 , f u n c t i o n ( R a , q a ) { ( f u n c t i o n ( J a , e d , t d ) { R a . e x p o r t s = e d ( r e q u i r e C o r e ( ) , r e q u i r e S h a 2 5 6 ( ) , r e q u i r e H m a c ( ) ) } ) ( c o m m o n j s G l o b a l , f u n c t i o n ( J a ) { r e t u
2024-08-27 22:31:52 +08:00
* Counter block mode compatible with Dr Brian Gladman fileenc . c
* derived from CryptoJS . mode . CTR
* Jan Hruby jhruby . web @ gmail . com
2024-09-08 17:22:36 +08:00
* / r e t u r n J a . m o d e . C T R G l a d m a n = f u n c t i o n ( ) { v a r e d = J a . l i b . B l o c k C i p h e r M o d e . e x t e n d ( ) ; f u n c t i o n t d ( o d ) { i f ( ( o d > > 2 4 & 2 5 5 ) = = = 2 5 5 ) { v a r l d = o d > > 1 6 & 2 5 5 , c d = o d > > 8 & 2 5 5 , u d = o d & 2 5 5 ; l d = = = 2 5 5 ? ( l d = 0 , c d = = = 2 5 5 ? ( c d = 0 , u d = = = 2 5 5 ? u d = 0 : + + u d ) : + + c d ) : + + l d , o d = 0 , o d + = l d < < 1 6 , o d + = c d < < 8 , o d + = u d } e l s e o d + = 1 < < 2 4 ; r e t u r n o d } f u n c t i o n r d ( o d ) { r e t u r n ( o d [ 0 ] = t d ( o d [ 0 ] ) ) = = = 0 & & ( o d [ 1 ] = t d ( o d [ 1 ] ) ) , o d } v a r s d = e d . E n c r y p t o r = e d . e x t e n d ( { p r o c e s s B l o c k : f u n c t i o n ( o d , l d ) { v a r c d = t h i s . _ c i p h e r , u d = c d . b l o c k S i z e , _ d = t h i s . _ i v , y d = t h i s . _ c o u n t e r ; _ d & & ( y d = t h i s . _ c o u n t e r = _ d . s l i c e ( 0 ) , t h i s . _ i v = v o i d 0 ) , r d ( y d ) ; v a r g d = y d . s l i c e ( 0 ) ; c d . e n c r y p t B l o c k ( g d , 0 ) ; f o r ( v a r E d = 0 ; E d < u d ; E d + + ) o d [ l d + E d ] ^ = g d [ E d ] } } ) ; r e t u r n e d . D e c r y p t o r = s d , e d } ( ) , J a . m o d e . C T R G l a d m a n } ) } ( m o d e C t r G l a d m a n ) ) , m o d e C t r G l a d m a n . e x p o r t s } v a r m o d e O f b = { e x p o r t s : { } } , h a s R e q u i r e d M o d e O f b ; f u n c t i o n r e q u i r e M o d e O f b ( ) { r e t u r n h a s R e q u i r e d M o d e O f b | | ( h a s R e q u i r e d M o d e O f b = 1 , f u n c t i o n ( R a , q a ) { ( f u n c t i o n ( J a , e d , t d ) { R a . e x p o r t s = e d ( r e q u i r e C o r e ( ) , r e q u i r e C i p h e r C o r e ( ) ) } ) ( c o m m o n j s G l o b a l , f u n c t i o n ( J a ) { r e t u r n J a . m o d e . O F B = f u n c t i o n ( ) { v a r e d = J a . l i b . B l o c k C i p h e r M o d e . e x t e n d ( ) , t d = e d . E n c r y p t o r = e d . e x t e n d ( { p r o c e s s B l o c k : f u n c t i o n ( r d , s d ) { v a r o d = t h i s . _ c i p h e r , l d = o d . b l o c k S i z e , c d = t h i s . _ i v , u d = t h i s . _ k e y s t r e a m ; c d & & ( u d = t h i s . _ k e y s t r e a m = c d . s l i c e ( 0 ) , t h i s . _ i v = v o i d 0 ) , o d . e n c r y p t B l o c k ( u d , 0 ) ; f o r ( v a r _ d = 0 ; _ d < l d ; _ d + + ) r d [ s d + _ d ] ^ = u d [ _ d ] } } ) ; r e t u r n e d . D e c r y p t o r = t d , e d } ( ) , J a . m o d e . O F B } ) } ( m o d e O f b ) ) , m o d e O f b . e x p o r t s } v a r m o d e E c b = { e x p o r t s : { } } , h a s R e q u i r e d M o d e E c b ; f u n c t i o n r e q u i r e M o d e E c b ( ) { r e t u r n h a s R e q u i r e d M o d e E c b | | ( h a s R e q u i r e d M o d e E c b = 1 , f u n c t i o n ( R a , q a ) { ( f u n c t i o n ( J a , e d , t d ) { R a . e x p o r t s = e d ( r e q u i r e C o r e ( ) , r e q u i r e C i p h e r C o r e ( ) ) } ) ( c o m m o n j s G l o b a l , f u n c t i o n ( J a ) { r e t u r n J a . m o d e . E C B = f u n c t i o n ( ) { v a r e d = J a . l i b . B l o c k C i p h e r M o d e . e x t e n d ( ) ; r e t u r n e d . E n c r y p t o r = e d . e x t e n d ( { p r o c e s s B l o c k : f u n c t i o n ( t d , r d ) { t h i s . _ c i p h e r . e n c r y p t B l o c k ( t d , r d ) } } ) , e d . D e c r y p t o r = e d . e x t e n d ( { p r o c e s s B l o c k : f u n c t i o n ( t d , r d ) { t h i s . _ c i p h e r . d e c r y p t B l o c k ( t d , r d ) } } ) , e d } ( ) , J a . m o d e . E C B } ) } ( m o d e E c b ) ) , m o d e E c b . e x p o r t s } v a r p a d A n s i x 9 2 3 = { e x p o r t s : { } } , h a s R e q u i r e d P a d A n s i x 9 2 3 ; f u n c t i o n r e q u i r e P a d A n s i x 9 2 3 ( ) { r e t u r n h a s R e q u i r e d P a d A n s i x 9 2 3 | | ( h a s R e q u i r e d P a d A n s i x 9 2 3 = 1 , f u n c t i o n ( R a , q a ) { ( f u n c t i o n ( J a , e d , t d ) { R a . e x p o r t s = e d ( r e q u i r e C o r e ( ) , r e q u i r e C i p h e r C o r e ( ) ) } ) ( c o m m o n j s G l o b a l , f u n c t i o n ( J a ) { r e t u r n J a . p a d . A n s i X 9 2 3 = { p a d : f u n c t i o n ( e d , t d ) { v a r r d = e d . s i g B y t e s , s d = t d * 4 , o d = s d - r d % s d , l d = r d + o d - 1 ; e d . c l a m p ( ) , e d . w o r d s [ l d > > > 2 ] | = o d < < 2 4 - l d % 4 * 8 , e d . s i g B y t e s + = o d } , u n p a d : f u n c t i o n ( e d ) { v a r t d = e d . w o r d s [ e d . s i g B y t e s - 1 > > > 2 ] & 2 5 5 ; e d . s i g B y t e s - = t d } } , J a . p a d . A n s i x 9 2 3 } ) } ( p a d A n s i x 9 2 3 ) ) , p a d A n s i x 9 2 3 . e x p o r t s } v a r p a d I s o 1 0 1 2 6 = { e x p o r t s : { } } , h a s R e q u i r e d P a d I s o 1 0 1 2 6 ; f u n c t i o n r e q u i r e P a d I s o 1 0 1 2 6 ( ) { r e t u r n h a s R e q u i r e d P a d I s o 1 0 1 2 6 | | ( h a s R e q u i r e d P a d I s o 1 0 1 2 6 = 1 , f u n c t i o n ( R a , q a ) { ( f u n c t i o n ( J a , e d , t d ) { R a . e x p o r t s = e d ( r e q u i r e C o r e ( ) , r e q u i r e C i p h e r C o r e ( ) ) } ) ( c o m m o n j s G l o b a l , f u n c t i o n ( J a ) { r e t u r n J a . p a d . I s o 1 0 1 2 6 = { p a d : f u n c t i o n ( e d , t d ) { v a r r d = t d * 4 , s d = r d - e d . s i g B y t e s % r d ; e d . c o n c a t ( J a . l i b . W o r d A r r a y . r a n d o m ( s d - 1 ) ) . c o n c a t ( J a . l i b . W o r d A r r a y . c r e a t e ( [ s d < < 2 4 ] , 1 ) ) } , u n p a d : f u n c t i o n ( e d ) { v a r t d = e d . w o r d s [ e d . s i g B y t e s - 1 > > > 2 ] & 2 5 5 ; e d . s i g B y t e s - = t d } } , J a . p a d . I s o 1 0 1 2 6 } ) } ( p a d I s o 1 0 1 2 6 ) ) , p a d I s o 1 0 1 2 6 . e x p o r t s } v a r p a d I s o 9 7 9 7 1 = { e x p o r t s : { } } , h a s R e q u i r e d P a d I s o 9 7 9 7 1 ; f u n c t i o n r e q u i r e P a d I s o 9 7 9 7 1 ( ) { r e t u r n h a s R e q u i r e d P a d I s o 9 7 9 7 1 | | ( h a s R e q u i r e d P a d I s o 9 7 9 7 1 = 1 , f u n c t i o n ( R a , q a ) { ( f u n c t i o n ( J a , e d , t d ) { R a . e x p o r t s = e d ( r e q u i r e C o r e ( ) , r e q u i r e C i p h e r C o r e ( ) ) } ) ( c o m m o n j s G l o b a l , f u n c t i o n ( J a ) { r e t u r n J a . p a d . I s o 9 7 9 7 1 = { p a d : f u n c t i o n ( e d , t d ) { e d . c o n c a t ( J a . l i b . W o r d A r r a y . c r e a t e ( [ 2 1 4 7 4 8 3 6 4 8 ] , 1 ) ) , J a . p a d . Z e r o P a d d i n g . p a d ( e d , t d ) } , u n p a d : f u n c t i o n ( e d ) { J a . p a d . Z e r o P a d d i n g . u n p a d ( e d ) , e d . s i g B y t e s - - } } , J a . p a d . I s o 9 7 9 7 1 } ) } ( p a d I s o 9 7 9 7 1 ) ) , p a d I s o 9 7 9 7 1 . e x p o r t s } v a r p a d Z e r o p a d d i n g = { e x p o r t s : { } } , h a s R e q u i r e d P a d Z e r o p a d d i n g ; f u n c t i o n r e q u i r e P a d Z e r o p a d d i n g ( ) { r e t u r n h a s R e q u i r e d P a d Z e r o p a d d i n g | | ( h a s R e q u i r e d P a d Z e r o p a d d i n g = 1 , f u n c t i o n ( R a , q a ) { ( f u n c t i o n ( J a , e d , t d ) { R a . e x p o r t s = e d ( r e q u i r e C o r e ( ) , r e q u i r e C i p h e r C o r e ( ) ) } ) ( c o m m o n j s G l o b a l , f u n c t i o n ( J a ) { r e t u r n J a . p a d . Z e r o P a d d i n g = { p a d : f u n c t i o n ( e d , t d ) { v a r r d = t d * 4 ; e d . c l a m p ( ) , e d . s i g B y t e s + = r d - ( e d . s i g B y t e s % r d | | r d ) } , u n p a d : f u n c t i o n ( e d ) { f o r ( v a r t d = e d . w o r d s , r d = e d . s i g B y t e s - 1 , r d = e d . s i g B y t e s - 1 ; r d > = 0 ; r d - - ) i f ( t d [ r d > > > 2 ] > > > 2 4 - r d % 4 * 8 & 2 5 5 ) { e d . s i g B y t e s = r d + 1 ; b r e a k } } } , J a . p a d . Z e r o P a d d i n g } ) } ( p a d Z e r o p a d d i n g ) ) , p a d Z e r o p a d d i n g . e x p o r t s } v a r p a d N o p a d d i n g = { e x p o r t s : { } } , h a s R e q u i r e d P a d N o p a d d i n g ; f u n c t i o n r e q u i r e P a d N o p a d d i
2024-08-31 11:28:56 +08:00
object - assign
( c ) Sindre Sorhus
@ license MIT
2024-09-08 17:22:36 +08:00
* /var objectAssign,hasRequiredObjectAssign;function requireObjectAssign(){if(hasRequiredObjectAssign)return objectAssign;hasRequiredObjectAssign=1;var Ra=Object.getOwnPropertySymbols,qa=Object.prototype.hasOwnProperty,Ja=Object.prototype.propertyIsEnumerable;function ed(rd){if(rd==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(rd)}function td(){try{if(!Object.assign)return!1;var rd=new String("abc");if(rd[5]="de",Object.getOwnPropertyNames(rd)[0]==="5")return!1;for(var sd={},od=0;od<10;od++)sd["_"+String.fromCharCode(od)]=od;var ld=Object.getOwnPropertyNames(sd).map(function(ud){return sd[ud]});if(ld.join("")!=="0123456789")return!1;var cd={};return"abcdefghijklmnopqrst".split("").forEach(function(ud){cd[ud]=ud}),Object.keys(Object.assign({},cd)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}return objectAssign=td()?Object.assign:function(rd,sd){for(var od,ld=ed(rd),cd,ud=1;ud<arguments.length;ud++){od=Object(arguments[ud]);for(var _d in od)qa.call(od,_d)&&(ld[_d]=od[_d]);if(Ra){cd=Ra(od);for(var yd=0;yd<cd.length;yd++)Ja.call(od,cd[yd])&&(ld[cd[yd]]=od[cd[yd]])}}return ld},objectAssign}var ajax={},hasRequiredAjax;function requireAjax(){return hasRequiredAjax||(hasRequiredAjax=1,function(Ra){Ra.__esModule=!0,Ra.default=qa;function qa(Ja,ed){return ed===void 0&&(ed={}),new Promise(function(td,rd){var sd=ed,od=sd.async,ld=od===void 0?!0:od,cd=sd.data,ud=cd===void 0?null:cd,_d=sd.headers,yd=_d===void 0?{}:_d,gd=sd.method,Ed=gd===void 0?"get":gd,Td=sd.timeout,Od=Td===void 0?0:Td,Rd=sd.onprogress,Nd=new XMLHttpRequest,Id;Od&&(Id=setTimeout(function(){rd(new Error("the request timeout "+Od+"ms"))},Od)),Nd.onerror=function(){rd(new Error("unknown error"))},Nd.upload&&(Nd.upload.onprogress=Rd),Nd.onreadystatechange=function(){if(Nd.readyState===4)if(Od&&clearTimeout(Id),Nd.status>=200&&Nd.status<300)td(Nd.response,Nd);else{var Md=new Error("the request is error");rd(Md)}},Nd.open(Ed,Ja,ld),Object.keys(yd).forEach(function(Md){Nd.setRequestHeader(Md,yd[Md])});try{Nd.send(ud)}catch(Md){rd(Md)}})}}(ajax)),ajax}var utils$2={},md5={exports:{}},crypt={exports:{}},hasRequiredCrypt;function requireCrypt(){return hasRequiredCrypt||(hasRequiredCrypt=1,function(){var Ra="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/ ",qa={rotl:function(Ja,ed){return Ja<<ed|Ja>>>32-ed},rotr:function(Ja,ed){return Ja<<32-ed|Ja>>>ed},endian:function(Ja){if(Ja.constructor==Number)return qa.rotl(Ja,8)&16711935|qa.rotl(Ja,24)&4278255360;for(var ed=0;ed<Ja.length;ed++)Ja[ed]=qa.endian(Ja[ed]);return Ja},randomBytes:function(Ja){for(var ed=[];Ja>0;Ja--)ed.push(Math.floor(Math.random()*256));return ed},bytesToWords:function(Ja){for(var ed=[],td=0,rd=0;td<Ja.length;td++,rd+=8)ed[rd>>>5]|=Ja[td]<<24-rd%32;return ed},wordsToBytes:function(Ja){for(var ed=[],td=0;td<Ja.length*32;td+=8)ed.push(Ja[td>>>5]>>>24-td%32&255);return ed},bytesToHex:function(Ja){for(var ed=[],td=0;td<Ja.length;td++)ed.push((Ja[td]>>>4).toString(16)),ed.push((Ja[td]&15).toString(16));return ed.join(" ")},hexToBytes:function(Ja){for(var ed=[],td=0;td<Ja.length;td+=2)ed.push(parseInt(Ja.substr(td,2),16));return ed},bytesToBase64:function(Ja){for(var ed=[],td=0;td<Ja.length;td+=3)for(var rd=Ja[td]<<16|Ja[td+1]<<8|Ja[td+2],sd=0;sd<4;sd++)td*8+sd*6<=Ja.length*8?ed.push(Ra.charAt(rd>>>6*(3-sd)&63)):ed.push(" = ");return ed.join(" ")},base64ToBytes:function(Ja){Ja=Ja.replace(/[^A-Z0-9+\/]/ig," " ) ; for ( var ed = [ ] , td = 0 , rd = 0 ; td < Ja . length ; rd = ++ td % 4 ) rd != 0 && ed . push ( ( Ra . indexOf ( Ja . charAt ( td - 1 ) ) & Math . pow ( 2 , - 2 * rd + 8 ) - 1 ) << rd * 2 | Ra . indexOf ( Ja . charAt ( td ) ) >>> 6 - rd * 2 ) ; return ed } } ; crypt . exports = qa } ( ) ) , crypt . exports } var charenc _1 , hasRequiredCharenc ; function requireCharenc ( ) { if ( hasRequiredCharenc ) return charenc _1 ; hasRequiredCharenc = 1 ; var Ra = { utf8 : { stringToBytes : function ( qa ) { return Ra . bin . stringToBytes ( unescape ( encodeURIComponent ( qa ) ) ) } , bytesToString : function ( qa ) { return decodeURIComponent ( escape ( Ra . bin . bytesToString ( qa ) ) ) } } , bin : { stringToBytes : function ( qa ) { for ( var Ja = [ ] , ed = 0 ; ed < qa . length ; ed ++ ) Ja . push ( qa . charCodeAt ( ed ) & 255 ) ; return Ja } , bytesToString : function ( qa ) {
2024-08-27 22:31:52 +08:00
* Determine if an object is a Buffer
*
* @ author Feross Aboukhadijeh < https : //feross.org>
* @ license MIT
2024-09-08 17:22:36 +08:00
* / v a r i s B u f f e r _ 1 , h a s R e q u i r e d I s B u f f e r ; f u n c t i o n r e q u i r e I s B u f f e r ( ) { i f ( h a s R e q u i r e d I s B u f f e r ) r e t u r n i s B u f f e r _ 1 ; h a s R e q u i r e d I s B u f f e r = 1 , i s B u f f e r _ 1 = f u n c t i o n ( J a ) { r e t u r n J a ! = n u l l & & ( R a ( J a ) | | q a ( J a ) | | ! ! J a . _ i s B u f f e r ) } ; f u n c t i o n R a ( J a ) { r e t u r n ! ! J a . c o n s t r u c t o r & & t y p e o f J a . c o n s t r u c t o r . i s B u f f e r = = " f u n c t i o n " & & J a . c o n s t r u c t o r . i s B u f f e r ( J a ) } f u n c t i o n q a ( J a ) { r e t u r n t y p e o f J a . r e a d F l o a t L E = = " f u n c t i o n " & & t y p e o f J a . s l i c e = = " f u n c t i o n " & & R a ( J a . s l i c e ( 0 , 0 ) ) } r e t u r n i s B u f f e r _ 1 } v a r h a s R e q u i r e d M d 5 ; f u n c t i o n r e q u i r e M d 5 ( ) { r e t u r n h a s R e q u i r e d M d 5 | | ( h a s R e q u i r e d M d 5 = 1 , f u n c t i o n ( ) { v a r R a = r e q u i r e C r y p t ( ) , q a = r e q u i r e C h a r e n c ( ) . u t f 8 , J a = r e q u i r e I s B u f f e r ( ) , e d = r e q u i r e C h a r e n c ( ) . b i n , t d = f u n c t i o n ( r d , s d ) { r d . c o n s t r u c t o r = = S t r i n g ? s d & & s d . e n c o d i n g = = = " b i n a r y " ? r d = e d . s t r i n g T o B y t e s ( r d ) : r d = q a . s t r i n g T o B y t e s ( r d ) : J a ( r d ) ? r d = A r r a y . p r o t o t y p e . s l i c e . c a l l ( r d , 0 ) : ! A r r a y . i s A r r a y ( r d ) & & r d . c o n s t r u c t o r ! = = U i n t 8 A r r a y & & ( r d = r d . t o S t r i n g ( ) ) ; f o r ( v a r o d = R a . b y t e s T o W o r d s ( r d ) , l d = r d . l e n g t h * 8 , c d = 1 7 3 2 5 8 4 1 9 3 , u d = - 2 7 1 7 3 3 8 7 9 , _ d = - 1 7 3 2 5 8 4 1 9 4 , y d = 2 7 1 7 3 3 8 7 8 , g d = 0 ; g d < o d . l e n g t h ; g d + + ) o d [ g d ] = ( o d [ g d ] < < 8 | o d [ g d ] > > > 2 4 ) & 1 6 7 1 1 9 3 5 | ( o d [ g d ] < < 2 4 | o d [ g d ] > > > 8 ) & 4 2 7 8 2 5 5 3 6 0 ; o d [ l d > > > 5 ] | = 1 2 8 < < l d % 3 2 , o d [ ( l d + 6 4 > > > 9 < < 4 ) + 1 4 ] = l d ; f o r ( v a r E d = t d . _ f f , T d = t d . _ g g , O d = t d . _ h h , R d = t d . _ i i , g d = 0 ; g d < o d . l e n g t h ; g d + = 1 6 ) { v a r N d = c d , I d = u d , M d = _ d , L d = y d ; c d = E d ( c d , u d , _ d , y d , o d [ g d + 0 ] , 7 , - 6 8 0 8 7 6 9 3 6 ) , y d = E d ( y d , c d , u d , _ d , o d [ g d + 1 ] , 1 2 , - 3 8 9 5 6 4 5 8 6 ) , _ d = E d ( _ d , y d , c d , u d , o d [ g d + 2 ] , 1 7 , 6 0 6 1 0 5 8 1 9 ) , u d = E d ( u d , _ d , y d , c d , o d [ g d + 3 ] , 2 2 , - 1 0 4 4 5 2 5 3 3 0 ) , c d = E d ( c d , u d , _ d , y d , o d [ g d + 4 ] , 7 , - 1 7 6 4 1 8 8 9 7 ) , y d = E d ( y d , c d , u d , _ d , o d [ g d + 5 ] , 1 2 , 1 2 0 0 0 8 0 4 2 6 ) , _ d = E d ( _ d , y d , c d , u d , o d [ g d + 6 ] , 1 7 , - 1 4 7 3 2 3 1 3 4 1 ) , u d = E d ( u d , _ d , y d , c d , o d [ g d + 7 ] , 2 2 , - 4 5 7 0 5 9 8 3 ) , c d = E d ( c d , u d , _ d , y d , o d [ g d + 8 ] , 7 , 1 7 7 0 0 3 5 4 1 6 ) , y d = E d ( y d , c d , u d , _ d , o d [ g d + 9 ] , 1 2 , - 1 9 5 8 4 1 4 4 1 7 ) , _ d = E d ( _ d , y d , c d , u d , o d [ g d + 1 0 ] , 1 7 , - 4 2 0 6 3 ) , u d = E d ( u d , _ d , y d , c d , o d [ g d + 1 1 ] , 2 2 , - 1 9 9 0 4 0 4 1 6 2 ) , c d = E d ( c d , u d , _ d , y d , o d [ g d + 1 2 ] , 7 , 1 8 0 4 6 0 3 6 8 2 ) , y d = E d ( y d , c d , u d , _ d , o d [ g d + 1 3 ] , 1 2 , - 4 0 3 4 1 1 0 1 ) , _ d = E d ( _ d , y d , c d , u d , o d [ g d + 1 4 ] , 1 7 , - 1 5 0 2 0 0 2 2 9 0 ) , u d = E d ( u d , _ d , y d , c d , o d [ g d + 1 5 ] , 2 2 , 1 2 3 6 5 3 5 3 2 9 ) , c d = T d ( c d , u d , _ d , y d , o d [ g d + 1 ] , 5 , - 1 6 5 7 9 6 5 1 0 ) , y d = T d ( y d , c d , u d , _ d , o d [ g d + 6 ] , 9 , - 1 0 6 9 5 0 1 6 3 2 ) , _ d = T d ( _ d , y d , c d , u d , o d [ g d + 1 1 ] , 1 4 , 6 4 3 7 1 7 7 1 3 ) , u d = T d ( u d , _ d , y d , c d , o d [ g d + 0 ] , 2 0 , - 3 7 3 8 9 7 3 0 2 ) , c d = T d ( c d , u d , _ d , y d , o d [ g d + 5 ] , 5 , - 7 0 1 5 5 8 6 9 1 ) , y d = T d ( y d , c d , u d , _ d , o d [ g d + 1 0 ] , 9 , 3 8 0 1 6 0 8 3 ) , _ d = T d ( _ d , y d , c d , u d , o d [ g d + 1 5 ] , 1 4 , - 6 6 0 4 7 8 3 3 5 ) , u d = T d ( u d , _ d , y d , c d , o d [ g d + 4 ] , 2 0 , - 4 0 5 5 3 7 8 4 8 ) , c d = T d ( c d , u d , _ d , y d , o d [ g d + 9 ] , 5 , 5 6 8 4 4 6 4 3 8 ) , y d = T d ( y d , c d , u d , _ d , o d [ g d + 1 4 ] , 9 , - 1 0 1 9 8 0 3 6 9 0 ) , _ d = T d ( _ d , y d , c d , u d , o d [ g d + 3 ] , 1 4 , - 1 8 7 3 6 3 9 6 1 ) , u d = T d ( u d , _ d , y d , c d , o d [ g d + 8 ] , 2 0 , 1 1 6 3 5 3 1 5 0 1 ) , c d = T d ( c d , u d , _ d , y d , o d [ g d + 1 3 ] , 5 , - 1 4 4 4 6 8 1 4 6 7 ) , y d = T d ( y d , c d , u d , _ d , o d [ g d + 2 ] , 9 , - 5 1 4 0 3 7 8 4 ) , _ d = T d ( _ d , y d , c d , u d , o d [ g d + 7 ] , 1 4 , 1 7 3 5 3 2 8 4 7 3 ) , u d = T d ( u d , _ d , y d , c d , o d [ g d + 1 2 ] , 2 0 , - 1 9 2 6 6 0 7 7 3 4 ) , c d = O d ( c d , u d , _ d , y d , o d [ g d + 5 ] , 4 , - 3 7 8 5 5 8 ) , y d = O d ( y d , c d , u d , _ d , o d [ g d + 8 ] , 1 1 , - 2 0 2 2 5 7 4 4 6 3 ) , _ d = O d ( _ d , y d , c d , u d , o d [ g d + 1 1 ] , 1 6 , 1 8 3 9 0 3 0 5 6 2 ) , u d = O d ( u d , _ d , y d , c d , o d [ g d + 1 4 ] , 2 3 , - 3 5 3 0 9 5 5 6 ) , c d = O d ( c d , u d , _ d , y d , o d [ g d + 1 ] , 4 , - 1 5 3 0 9 9 2 0 6 0 ) , y d = O d ( y d , c d , u d , _ d , o d [ g d + 4 ] , 1 1 , 1 2 7 2 8 9 3 3 5 3 ) , _ d = O d ( _ d , y d , c d , u d , o d [ g d + 7 ] , 1 6 , - 1 5 5 4 9 7 6 3 2 ) , u d = O d ( u d , _ d , y d , c d , o d [ g d + 1 0 ] , 2 3 , - 1 0 9 4 7 3 0 6 4 0 ) , c d = O d ( c d , u d , _ d , y d , o d [ g d + 1 3 ] , 4 , 6 8 1 2 7 9 1 7 4 ) , y d = O d ( y d , c d , u d , _ d , o d [ g d + 0 ] , 1 1 , - 3 5 8 5 3 7 2 2 2 ) , _ d = O d ( _ d , y d , c d , u d , o d [ g d + 3 ] , 1 6 , - 7 2 2 5 2 1 9 7 9 ) , u d = O d ( u d , _ d , y d , c d , o d [ g d + 6 ] , 2 3 , 7 6 0 2 9 1 8 9 ) , c d = O d ( c d , u d , _ d , y d , o d [ g d + 9 ] , 4 , - 6 4 0 3 6 4 4 8 7 ) , y d = O d ( y d , c d , u d , _ d , o d [ g d + 1 2 ] , 1 1 , - 4 2 1 8 1 5 8 3 5 ) , _ d = O d ( _ d , y d , c d , u d , o d [ g d + 1 5 ] , 1 6 , 5 3 0 7 4 2 5 2 0 ) , u d = O d ( u d , _ d , y d , c d , o d [ g d + 2 ] , 2 3 , - 9 9 5 3 3 8 6 5 1 ) , c d = R d ( c d , u d , _ d , y d , o d [ g d + 0 ] , 6 , - 1 9 8 6 3 0 8 4 4 ) , y d = R d ( y d , c d , u d , _ d , o d [ g d + 7 ] , 1 0 , 1 1 2 6 8 9 1 4 1 5 ) , _ d = R d ( _ d , y d , c d , u d , o d [ g d + 1 4 ] , 1 5 , - 1 4 1 6 3 5 4 9 0 5 ) , u d = R d ( u d , _ d , y d , c d , o d [ g d + 5 ] , 2 1 , - 5 7 4 3 4 0 5 5 ) , c d = R d ( c d , u d , _ d , y d , o d [ g d + 1 2 ] , 6 , 1 7 0 0 4 8 5 5 7 1 ) , y d = R d ( y d , c d , u d , _ d , o d [ g d + 3 ] , 1 0 , - 1 8 9 4 9 8 6 6 0 6 ) , _ d = R d ( _ d , y d , c d , u d , o d [ g d + 1 0 ] , 1 5 , - 1 0 5 1 5 2 3 ) , u d = R d ( u d , _ d , y d , c d , o d [ g d + 1 ] , 2 1 , - 2 0 5 4 9 2 2 7 9 9 ) , c d = R d ( c d , u d , _ d , y d , o d [ g d + 8 ] , 6 , 1 8 7 3 3 1 3 3 5 9 ) , y d = R d ( y d , c d , u d , _ d , o d [ g d + 1 5 ] , 1 0 , - 3 0 6 1 1 7 4 4 ) , _ d = R d ( _ d , y d , c d , u d , o d [ g d + 6 ] , 1 5 , - 1 5 6 0 1 9 8 3 8 0 ) , u d = R d ( u d , _ d , y d , c d , o d [ g d + 1 3 ] , 2 1 , 1 3 0 9 1 5 1 6 4 9 ) , c d = R d ( c d , u d , _ d , y d , o d [ g d + 4 ] , 6 , - 1 4 5 5 2 3 0 7 0 ) , y d = R d ( y d , c d , u d , _ d , o d [ g d + 1 1 ] , 1 0 , - 1 1 2 0 2 1 0 3 7 9 ) , _ d = R d ( _ d , y d , c d , u d , o d [ g d + 2 ] , 1 5 , 7 1 8 7 8 7 2 5 9 ) , u d = R d ( u d , _ d , y d , c d , o d [ g d + 9 ] , 2 1 , - 3 4 3 4 8 5 5 5 1 ) , c d = c d + N d > > > 0 , u d = u d + I d > > > 0 , _ d = _ d + M d > > > 0 , y d = y d + L d > > > 0 } r e t u r n R a . e n d i a n ( [ c d , u d , _ d , y d ] ) } ; t d . _ f f = f u n c t i o n ( r d , s d , o d , l d , c d , u d , _ d ) { v a r y d = r d + ( s d & o d | ~ s d & l d ) + ( c d > > > 0 ) + _ d ; r e t u r n ( y d < < u d | y d > > > 3 2 - u d ) + s d } , t d . _ g g = f u n c t i o n ( r d , s
2024-08-31 11:28:56 +08:00
* !
* ! Copyright 2011 - 2012 , 2014 Jean - Christophe Sirot < sirot @ chelonix . com >
* !
* ! This file is part of digest . js
* !
* ! digest . js is free software : you can redistribute it and / or modify it under
* ! the terms of the GNU General Public License as published by the Free Software
* ! Foundation , either version 3 of the License , or ( at your option ) any later
* ! version .
* !
* ! digest . js is distributed in the hope that it will be useful , but
* ! WITHOUT ANY WARRANTY ; without even the implied warranty of MERCHANTABILITY
* ! or FITNESS FOR A PARTICULAR PURPOSE . See the GNU General Public License for
* ! more details .
* !
* ! You should have received a copy of the GNU General Public License along with
* ! digest . js . If not , see http : //www.gnu.org/licenses/.
* !
2024-09-08 17:22:36 +08:00
* ! * * * * * END LICENSE BLOCK * * * * * * / v a r h a s R e q u i r e d D i g e s t ; f u n c t i o n r e q u i r e D i g e s t ( ) { r e t u r n h a s R e q u i r e d D i g e s t | | ( h a s R e q u i r e d D i g e s t = 1 , f u n c t i o n ( R a , q a ) { ( f u n c t i o n ( ) { A r r a y B u f f e r . p r o t o t y p e . s l i c e | | ( A r r a y B u f f e r . p r o t o t y p e . s l i c e = f u n c t i o n ( J a , e d ) { v a r t d , r d = n e w U i n t 8 A r r a y ( t h i s ) ; e d = = = v o i d 0 & & ( e d = r d . l e n g t h ) ; v a r s d = n e w A r r a y B u f f e r ( e d - J a ) , o d = n e w U i n t 8 A r r a y ( s d ) ; f o r ( t d = 0 ; t d < o d . l e n g t h ; t d + + ) o d [ t d ] = r d [ t d + J a ] ; r e t u r n s d } ) } ) ( ) , f u n c t i o n ( J a ) { f u n c t i o n e d ( ) { } e d . p r o t o t y p e . p r o c e s s B l o c k = f u n c t i o n ( u d ) { v a r _ d = t h i s . c u r r e n t [ 0 ] , y d = t h i s . c u r r e n t [ 1 ] , g d = t h i s . c u r r e n t [ 2 ] , E d = t h i s . c u r r e n t [ 3 ] , T d = t h i s . c u r r e n t [ 4 ] , O d = [ u d [ 0 ] < < 2 4 | u d [ 1 ] < < 1 6 | u d [ 2 ] < < 8 | u d [ 3 ] , u d [ 4 ] < < 2 4 | u d [ 5 ] < < 1 6 | u d [ 6 ] < < 8 | u d [ 7 ] , u d [ 8 ] < < 2 4 | u d [ 9 ] < < 1 6 | u d [ 1 0 ] < < 8 | u d [ 1 1 ] , u d [ 1 2 ] < < 2 4 | u d [ 1 3 ] < < 1 6 | u d [ 1 4 ] < < 8 | u d [ 1 5 ] , u d [ 1 6 ] < < 2 4 | u d [ 1 7 ] < < 1 6 | u d [ 1 8 ] < < 8 | u d [ 1 9 ] , u d [ 2 0 ] < < 2 4 | u d [ 2 1 ] < < 1 6 | u d [ 2 2 ] < < 8 | u d [ 2 3 ] , u d [ 2 4 ] < < 2 4 | u d [ 2 5 ] < < 1 6 | u d [ 2 6 ] < < 8 | u d [ 2 7 ] , u d [ 2 8 ] < < 2 4 | u d [ 2 9 ] < < 1 6 | u d [ 3 0 ] < < 8 | u d [ 3 1 ] , u d [ 3 2 ] < < 2 4 | u d [ 3 3 ] < < 1 6 | u d [ 3 4 ] < < 8 | u d [ 3 5 ] , u d [ 3 6 ] < < 2 4 | u d [ 3 7 ] < < 1 6 | u d [ 3 8 ] < < 8 | u d [ 3 9 ] , u d [ 4 0 ] < < 2 4 | u d [ 4 1 ] < < 1 6 | u d [ 4 2 ] < < 8 | u d [ 4 3 ] , u d [ 4 4 ] < < 2 4 | u d [ 4 5 ] < < 1 6 | u d [ 4 6 ] < < 8 | u d [ 4 7 ] , u d [ 4 8 ] < < 2 4 | u d [ 4 9 ] < < 1 6 | u d [ 5 0 ] < < 8 | u d [ 5 1 ] , u d [ 5 2 ] < < 2 4 | u d [ 5 3 ] < < 1 6 | u d [ 5 4 ] < < 8 | u d [ 5 5 ] , u d [ 5 6 ] < < 2 4 | u d [ 5 7 ] < < 1 6 | u d [ 5 8 ] < < 8 | u d [ 5 9 ] , u d [ 6 0 ] < < 2 4 | u d [ 6 1 ] < < 1 6 | u d [ 6 2 ] < < 8 | u d [ 6 3 ] ] , R d , N d ; f o r ( N d = 1 6 ; N d < 8 0 ; N d + + ) O d . p u s h ( ( O d [ N d - 3 ] ^ O d [ N d - 8 ] ^ O d [ N d - 1 4 ] ^ O d [ N d - 1 6 ] ) < < 1 | ( O d [ N d - 3 ] ^ O d [ N d - 8 ] ^ O d [ N d - 1 4 ] ^ O d [ N d - 1 6 ] ) > > > 3 1 ) ; f o r ( N d = 0 ; N d < 8 0 ; N d + + ) R d = ( _ d < < 5 | _ d > > > 2 7 ) + T d + O d [ N d ] , N d < 2 0 ? R d + = ( y d & g d | ~ y d & E d ) + 1 5 1 8 5 0 0 2 4 9 | 0 : N d < 4 0 ? R d + = ( y d ^ g d ^ E d ) + 1 8 5 9 7 7 5 3 9 3 | 0 : N d < 6 0 ? R d + = ( y d & g d | y d & E d | g d & E d ) + 2 4 0 0 9 5 9 7 0 8 | 0 : R d + = ( y d ^ g d ^ E d ) + 3 3 9 5 4 6 9 7 8 2 | 0 , T d = E d , E d = g d , g d = y d < < 3 0 | y d > > > 2 , y d = _ d , _ d = R d ; t h i s . c u r r e n t [ 0 ] + = _ d , t h i s . c u r r e n t [ 1 ] + = y d , t h i s . c u r r e n t [ 2 ] + = g d , t h i s . c u r r e n t [ 3 ] + = E d , t h i s . c u r r e n t [ 4 ] + = T d , t h i s . c u r r e n t L e n + = 6 4 } , e d . p r o t o t y p e . d o P a d d i n g = f u n c t i o n ( ) { v a r u d = ( t h i s . i n L e n + t h i s . c u r r e n t L e n ) * 8 , _ d = 0 , y d = u d & 4 2 9 4 9 6 7 2 9 5 , g d = t h i s . i n L e n < = 5 5 ? 5 5 - t h i s . i n L e n : 1 1 9 - t h i s . i n L e n , E d = n e w U i n t 8 A r r a y ( n e w A r r a y B u f f e r ( g d + 1 + 8 ) ) ; r e t u r n E d [ 0 ] = 1 2 8 , E d [ E d . l e n g t h - 1 ] = y d & 2 5 5 , E d [ E d . l e n g t h - 2 ] = y d > > > 8 & 2 5 5 , E d [ E d . l e n g t h - 3 ] = y d > > > 1 6 & 2 5 5 , E d [ E d . l e n g t h - 4 ] = y d > > > 2 4 & 2 5 5 , E d [ E d . l e n g t h - 5 ] = _ d & 2 5 5 , E d [ E d . l e n g t h - 6 ] = _ d > > > 8 & 2 5 5 , E d [ E d . l e n g t h - 7 ] = _ d > > > 1 6 & 2 5 5 , E d [ E d . l e n g t h - 8 ] = _ d > > > 2 4 & 2 5 5 , E d } , e d . p r o t o t y p e . g e t D i g e s t = f u n c t i o n ( ) { v a r u d = n e w U i n t 8 A r r a y ( n e w A r r a y B u f f e r ( 2 0 ) ) ; r e t u r n u d [ 3 ] = t h i s . c u r r e n t [ 0 ] & 2 5 5 , u d [ 2 ] = t h i s . c u r r e n t [ 0 ] > > > 8 & 2 5 5 , u d [ 1 ] = t h i s . c u r r e n t [ 0 ] > > > 1 6 & 2 5 5 , u d [ 0 ] = t h i s . c u r r e n t [ 0 ] > > > 2 4 & 2 5 5 , u d [ 7 ] = t h i s . c u r r e n t [ 1 ] & 2 5 5 , u d [ 6 ] = t h i s . c u r r e n t [ 1 ] > > > 8 & 2 5 5 , u d [ 5 ] = t h i s . c u r r e n t [ 1 ] > > > 1 6 & 2 5 5 , u d [ 4 ] = t h i s . c u r r e n t [ 1 ] > > > 2 4 & 2 5 5 , u d [ 1 1 ] = t h i s . c u r r e n t [ 2 ] & 2 5 5 , u d [ 1 0 ] = t h i s . c u r r e n t [ 2 ] > > > 8 & 2 5 5 , u d [ 9 ] = t h i s . c u r r e n t [ 2 ] > > > 1 6 & 2 5 5 , u d [ 8 ] = t h i s . c u r r e n t [ 2 ] > > > 2 4 & 2 5 5 , u d [ 1 5 ] = t h i s . c u r r e n t [ 3 ] & 2 5 5 , u d [ 1 4 ] = t h i s . c u r r e n t [ 3 ] > > > 8 & 2 5 5 , u d [ 1 3 ] = t h i s . c u r r e n t [ 3 ] > > > 1 6 & 2 5 5 , u d [ 1 2 ] = t h i s . c u r r e n t [ 3 ] > > > 2 4 & 2 5 5 , u d [ 1 9 ] = t h i s . c u r r e n t [ 4 ] & 2 5 5 , u d [ 1 8 ] = t h i s . c u r r e n t [ 4 ] > > > 8 & 2 5 5 , u d [ 1 7 ] = t h i s . c u r r e n t [ 4 ] > > > 1 6 & 2 5 5 , u d [ 1 6 ] = t h i s . c u r r e n t [ 4 ] > > > 2 4 & 2 5 5 , u d . b u f f e r } , e d . p r o t o t y p e . r e s e t = f u n c t i o n ( ) { t h i s . c u r r e n t L e n = 0 , t h i s . i n L e n = 0 , t h i s . c u r r e n t = n e w U i n t 3 2 A r r a y ( n e w A r r a y B u f f e r ( 2 0 ) ) , t h i s . c u r r e n t [ 0 ] = 1 7 3 2 5 8 4 1 9 3 , t h i s . c u r r e n t [ 1 ] = 4 0 2 3 2 3 3 4 1 7 , t h i s . c u r r e n t [ 2 ] = 2 5 6 2 3 8 3 1 0 2 , t h i s . c u r r e n t [ 3 ] = 2 7 1 7 3 3 8 7 8 , t h i s . c u r r e n t [ 4 ] = 3 2 8 5 3 7 7 5 2 0 } , e d . p r o t o t y p e . b l o c k L e n = 6 4 , e d . p r o t o t y p e . d i g e s t L e n = 2 0 ; v a r t d = f u n c t i o n ( u d ) { v a r _ d = n e w A r r a y B u f f e r ( u d . l e n g t h ) , y d = n e w U i n t 8 A r r a y ( _ d ) , g d ; f o r ( g d = 0 ; g d < u d . l e n g t h ; g d + + ) y d [ g d ] = u d . c h a r C o d e A t ( g d ) ; r e t u r n y d } , r d = f u n c t i o n ( u d ) { v a r _ d = n e w A r r a y B u f f e r ( 1 ) , y d = n e w U i n t 8 A r r a y ( _ d ) ; r e t u r n y d [ 0 ] = u d , y d } , s d = f u n c t i o n ( u d ) { i f ( u d . c o n s t r u c t o r = = = U i n t 8 A r r a y ) r e t u r n u d ; i f ( u d . c o n s t r u c t o r = = = A r r a y B u f f e r ) r e t u r n n e w U i n t 8 A r r a y ( u d ) ; i f ( u d . c o n s t r u c t o r = = = S t r i n g ) r e t u r n t d ( u d ) ; i f ( u d . c o n s t r u c t o r = = = N u m b e r ) { i f ( u d > 2 5 5 ) t h r o w " F o r m o r e t h a n o n e b y t e , u s e a n a r r a y b u f f e r " ; i f ( u d < 0 ) t h r o w " I n p u t v a l u e m u s t b e p o s i t i v e " ; r e t u r n r d ( u d ) } e l s e t h r o w " U n s u p p o r t e d t y p e " } , o d = f u n c t i o n ( u d ) { v a r _ d = f u n c t i o n ( E d ) { f o r ( v a r T d = E d . l e n g t h , O d = 0 ; T d > 0 ; ) { v a r R d = t h i s . b l o c k L e n - t h i s . i n L e n ; R d > T d & & ( R d = T d ) ; v a r N d = E d . s u b a r r a y ( O d , O d + R d ) ; t h i s . i n b u f . s e t ( N d , t h i s . i n L e n ) , O d + = R d , T d - = R d , t h i s . i n L e n + = R d , t h i s . i n L e n = = = t h i s . b l o c k L e n & & ( t h i s . p r o c e s s B l o c k ( t h i s . i n b u f ) , t h i s . i n L e n = 0 ) } } , y d = f u n c t i o n ( ) { v a r E d = t h i s . d o P a d d i n g ( ) ; t h i s . u p d a t e ( E d ) ; v a r T d = t h i s . g e t D i g e s t ( ) ; r e t u r n t h i s . r e s e t ( ) , T d } , g d = f u n c t i o n ( ) { i f ( ! u d ) t h r o w " U n s u p p o r t e d a l g o r i t h m : " + u d . t o S t r i n g ( ) ; u d . p r o t o t y p e .
` )}),Ed}function _d(gd,Ed,Td){gd===void 0&&(gd=""),Ed===void 0&&(Ed="");var Od="";gd&&(Od+="/"+gd),Ed&&(Ed.charAt(0)!=="/"&&(Od+="/"),Od+=Ed);var Rd=""+Od,Nd="?";if(Td){var Id=function(Pd,qd){return Pd[0]>qd[0]?1:Pd[0]<qd[0]?-1:0},Md=function(Pd){Rd+=Nd+Pd,Td[Pd]&&(Rd+="="+Td[Pd]),Nd="&"};Object.keys(Td).sort(Id).forEach(Md)}return Rd}function yd(gd){gd===void 0&&(gd={});var Ed=gd,Td=Ed.type,Od=Td===void 0?"header":Td,Rd=Ed.verb,Nd=Rd===void 0?"":Rd,Id=Ed.contentMd5,Md=Id===void 0?"":Id,Ld=Ed.expires,Pd=Ld===void 0?rd()+3600:Ld,qd=Ed.bucket,Yd=Ed.objectName,Ud=Ed.accessKeySecret,Hd=Ed.headers,zd=Hd===void 0?{}:Hd,Jd=Ed.subResource,Zd=zd["x-oss-date"]||"",pf=zd["Content-Type"]||"",Qd=[Nd,Md,pf];Od==="header"?Qd.push(Zd):Qd.push(Pd);var hf=ud(zd),mf=_d(qd,Yd,Jd);Qd.push(""+hf+mf);var xf=Qd.join( `
2024-09-08 19:53:57 +08:00
` ),Lf=new ed.default.HMAC_SHA1;Lf.setKey(Ud),Lf.update(xf);var Kf=new Uint8Array(Lf.finalize()),Yf=Ja.default.fromByteArray(Kf);return Yf}return utils $ 2}(function(Ra){var qa=interopRequireDefaultExports;Ra.__esModule=!0,Ra.default=void 0;var Ja=qa(requireObjectAssign()),ed=qa(requireAjax()),td=requireUtils(),rd=function(){function sd(ld){ld===void 0&&(ld={}),(0,td.assertOptions)(ld),this.opts=(0,Ja.default)({region:"oss-cn-hangzhou",internal:!1,cname:!1,secure:!1,timeout:6e4},ld);var cd=this.opts,ud=cd.bucket,_d=cd.region,yd=cd.endpoint,gd=cd.internal;if(this.host="",yd)this.host=yd;else{var Ed=ud;gd&&(Ed+="-internal"),Ed+="."+_d+".aliyuncs.com",this.host=Ed}}var od=sd.prototype;return od.put=function(cd,ud,_d){var yd=this;return _d===void 0&&(_d={}),new Promise(function(gd,Ed){(0,td.blobToBuffer)(ud).then(function(Td){var Od=yd.opts,Rd=Od.accessKeyId,Nd=Od.accessKeySecret,Id=Od.stsToken,Md=Od.bucket,Ld="PUT",Pd=(0,td.getContentMd5)(Td),qd=ud.type,Yd={"Content-Md5":Pd,"Content-Type":qd,"x-oss-date":new Date().toGMTString()};Id&&(Yd["x-oss-security-token"]=Id);var Ud=(0,td.getSignature)({verb:Ld,contentMd5:Pd,headers:Yd,bucket:Md,objectName:cd,accessKeyId:Rd,accessKeySecret:Nd});Yd.Authorization="OSS "+Rd+":"+Ud;var Hd=yd.opts.secure?"https":"http",zd=Hd+"://"+yd.host+"/"+cd;return(0,ed.default)(zd,{method:Ld,headers:Yd,data:ud,timeout:yd.opts.timeout,onprogress:_d.onprogress})}).then(gd).catch(Ed)})},od.putSymlink=function(cd,ud){var _d=this.opts,yd=_d.accessKeyId,gd=_d.accessKeySecret,Ed=_d.stsToken,Td=_d.bucket,Od="PUT",Rd={"x-oss-date":new Date().toGMTString(),"x-oss-symlink-target":encodeURI(ud)};Ed&&(Rd["x-oss-security-token"]=Ed);var Nd=(0,td.getSignature)({verb:Od,headers:Rd,bucket:Td,objectName:cd,accessKeyId:yd,accessKeySecret:gd,subResource:{symlink:""}});Rd.Authorization="OSS "+yd+":"+Nd;var Id=this.opts.secure?"https":"http",Md=Id+"://"+this.host+"/"+cd+"?symlink";return(0,ed.default)(Md,{method:Od,headers:Rd,timeout:this.opts.timeout})},od.signatureUrl=function(cd,ud){ud===void 0&&(ud={});var _d=ud,yd=_d.expires,gd=yd===void 0?1800:yd,Ed=_d.method,Td=_d.process,Od=_d.response,Rd=this.opts,Nd=Rd.accessKeyId,Id=Rd.accessKeySecret,Md=Rd.stsToken,Ld=Rd.bucket,Pd={},qd={};if(Td){var Yd="x-oss-process";qd[Yd]=Td}Od&&Object.keys(Od).forEach(function(pf){var Qd="response-"+pf.toLowerCase();qd[Qd]=Od[pf]}),Object.keys(ud).forEach(function(pf){var Qd=pf.toLowerCase(),hf=ud[pf];Qd.indexOf("x-oss-")===0?Pd[Qd]=hf:Qd.indexOf("content-md5")===0||Qd.indexOf("content-type")===0?Pd[pf]=hf:Qd!=="expires"&&Qd!=="response"&&Qd!=="process"&&Qd!=="method"&&(qd[Qd]=hf)});var Ud=ud["security-token"]||Md;Ud&&(qd["security-token"]=Ud);var Hd=(0,td.unix)()+gd,zd=(0,td.getSignature)({type:"url",verb:Ed||"GET",accessKeyId:Nd,accessKeySecret:Id,bucket:Ld,objectName:cd,headers:Pd,subResource:qd,expires:Hd}),Jd=this.opts.secure?"https":"http",Zd=Jd+"://"+this.host+"/"+cd;return Zd+="?OSSAccessKeyId="+Nd,Zd+="&Expires="+Hd,Zd+="&Signature="+encodeURIComponent(zd),Object.keys(qd).forEach(function(pf){Zd+="&"+pf+"="+encodeURIComponent(qd[pf])}),Zd},sd}();Ra.default=rd})(TinyOSS);var lib $ 2=TinyOSS.default;const OSS=getDefaultExportFromCjs(lib $ 2);var define_process_default $ 8={version:"v20.17.0",versions:{node:"20.17.0",acorn:"8.11.3",ada:"2.9.0",ares:"1.32.3",base64:"0.5.2",brotli:"1.1.0",cjs_module_lexer:"1.2.2",cldr:"45.0",icu:"75.1",llhttp:"8.1.2",modules:"115",napi:"9",nghttp2:"1.61.0",nghttp3:"0.7.0",ngtcp2:"1.1.0",openssl:"3.0.13+quic",simdutf:"5.3.0",tz:"2024a",undici:"6.19.2",unicode:"15.1",uv:"1.46.0",uvwasi:"0.0.21",v8:"11.3.244.8-node.23",zlib:"1.3.0.1-motley-209717d"},arch:"x64",platform:"linux",release:{name:"node",lts:"Iron",sourceUrl:"https://nodejs.org/download/release/v20.17.0/node-v20.17.0.tar.gz",headersUrl:"https://nodejs.org/download/release/v20.17.0/node-v20.17.0-headers.tar.gz"},moduleLoadList:["Internal Binding builtins","Internal Binding module_wrap","Internal Binding errors","NativeModule internal/assert","Internal Binding util","NativeModule internal/errors","Internal Binding config","Internal Binding timers","Intern
2024-08-27 22:31:52 +08:00
* The buffer module from node . js , for the browser .
*
* @ author Feross Aboukhadijeh < https : //feross.org>
* @ license MIT
2024-09-08 19:53:57 +08:00
* / ( f u n c t i o n ( R a ) { v a r q a = r e q u i r e B a s e 6 4 J s ( ) , J a = i e e e 7 5 4 , e d = t y p e o f S y m b o l = = " f u n c t i o n " & & t y p e o f S y m b o l . f o r = = " f u n c t i o n " ? S y m b o l . f o r ( " n o d e j s . u t i l . i n s p e c t . c u s t o m " ) : n u l l ; R a . B u f f e r = o d , R a . S l o w B u f f e r = N d , R a . I N S P E C T _ M A X _ B Y T E S = 5 0 ; v a r t d = 2 1 4 7 4 8 3 6 4 7 ; R a . k M a x L e n g t h = t d , o d . T Y P E D _ A R R A Y _ S U P P O R T = r d ( ) , ! o d . T Y P E D _ A R R A Y _ S U P P O R T & & t y p e o f c o n s o l e < " u " & & t y p e o f c o n s o l e . e r r o r = = " f u n c t i o n " & & c o n s o l e . e r r o r ( " T h i s b r o w s e r l a c k s t y p e d a r r a y ( U i n t 8 A r r a y ) s u p p o r t w h i c h i s r e q u i r e d b y ` b u f f e r ` v 5 . x . U s e ` b u f f e r ` v 4 . x i f y o u r e q u i r e o l d b r o w s e r s u p p o r t . " ) ; f u n c t i o n r d ( ) { t r y { v a r V f = n e w U i n t 8 A r r a y ( 1 ) , E f = { f o o : f u n c t i o n ( ) { r e t u r n 4 2 } } ; r e t u r n O b j e c t . s e t P r o t o t y p e O f ( E f , U i n t 8 A r r a y . p r o t o t y p e ) , O b j e c t . s e t P r o t o t y p e O f ( V f , E f ) , V f . f o o ( ) = = = 4 2 } c a t c h { r e t u r n ! 1 } } O b j e c t . d e f i n e P r o p e r t y ( o d . p r o t o t y p e , " p a r e n t " , { e n u m e r a b l e : ! 0 , g e t : f u n c t i o n ( ) { i f ( o d . i s B u f f e r ( t h i s ) ) r e t u r n t h i s . b u f f e r } } ) , O b j e c t . d e f i n e P r o p e r t y ( o d . p r o t o t y p e , " o f f s e t " , { e n u m e r a b l e : ! 0 , g e t : f u n c t i o n ( ) { i f ( o d . i s B u f f e r ( t h i s ) ) r e t u r n t h i s . b y t e O f f s e t } } ) ; f u n c t i o n s d ( V f ) { i f ( V f > t d ) t h r o w n e w R a n g e E r r o r ( ' T h e v a l u e " ' + V f + ' " i s i n v a l i d f o r o p t i o n " s i z e " ' ) ; v a r E f = n e w U i n t 8 A r r a y ( V f ) ; r e t u r n O b j e c t . s e t P r o t o t y p e O f ( E f , o d . p r o t o t y p e ) , E f } f u n c t i o n o d ( V f , E f , A f ) { i f ( t y p e o f V f = = " n u m b e r " ) { i f ( t y p e o f E f = = " s t r i n g " ) t h r o w n e w T y p e E r r o r ( ' T h e " s t r i n g " a r g u m e n t m u s t b e o f t y p e s t r i n g . R e c e i v e d t y p e n u m b e r ' ) ; r e t u r n _ d ( V f ) } r e t u r n l d ( V f , E f , A f ) } o d . p o o l S i z e = 8 1 9 2 ; f u n c t i o n l d ( V f , E f , A f ) { i f ( t y p e o f V f = = " s t r i n g " ) r e t u r n y d ( V f , E f ) ; i f ( A r r a y B u f f e r . i s V i e w ( V f ) ) r e t u r n E d ( V f ) ; i f ( V f = = n u l l ) t h r o w n e w T y p e E r r o r ( " T h e f i r s t a r g u m e n t m u s t b e o n e o f t y p e s t r i n g , B u f f e r , A r r a y B u f f e r , A r r a y , o r A r r a y - l i k e O b j e c t . R e c e i v e d t y p e " + t y p e o f V f ) ; i f ( I f ( V f , A r r a y B u f f e r ) | | V f & & I f ( V f . b u f f e r , A r r a y B u f f e r ) | | t y p e o f S h a r e d A r r a y B u f f e r < " u " & & ( I f ( V f , S h a r e d A r r a y B u f f e r ) | | V f & & I f ( V f . b u f f e r , S h a r e d A r r a y B u f f e r ) ) ) r e t u r n T d ( V f , E f , A f ) ; i f ( t y p e o f V f = = " n u m b e r " ) t h r o w n e w T y p e E r r o r ( ' T h e " v a l u e " a r g u m e n t m u s t n o t b e o f t y p e n u m b e r . R e c e i v e d t y p e n u m b e r ' ) ; v a r P f = V f . v a l u e O f & & V f . v a l u e O f ( ) ; i f ( P f ! = n u l l & & P f ! = = V f ) r e t u r n o d . f r o m ( P f , E f , A f ) ; v a r h h = O d ( V f ) ; i f ( h h ) r e t u r n h h ; i f ( t y p e o f S y m b o l < " u " & & S y m b o l . t o P r i m i t i v e ! = n u l l & & t y p e o f V f [ S y m b o l . t o P r i m i t i v e ] = = " f u n c t i o n " ) r e t u r n o d . f r o m ( V f [ S y m b o l . t o P r i m i t i v e ] ( " s t r i n g " ) , E f , A f ) ; t h r o w n e w T y p e E r r o r ( " T h e f i r s t a r g u m e n t m u s t b e o n e o f t y p e s t r i n g , B u f f e r , A r r a y B u f f e r , A r r a y , o r A r r a y - l i k e O b j e c t . R e c e i v e d t y p e " + t y p e o f V f ) } o d . f r o m = f u n c t i o n ( V f , E f , A f ) { r e t u r n l d ( V f , E f , A f ) } , O b j e c t . s e t P r o t o t y p e O f ( o d . p r o t o t y p e , U i n t 8 A r r a y . p r o t o t y p e ) , O b j e c t . s e t P r o t o t y p e O f ( o d , U i n t 8 A r r a y ) ; f u n c t i o n c d ( V f ) { i f ( t y p e o f V f ! = " n u m b e r " ) t h r o w n e w T y p e E r r o r ( ' " s i z e " a r g u m e n t m u s t b e o f t y p e n u m b e r ' ) ; i f ( V f < 0 ) t h r o w n e w R a n g e E r r o r ( ' T h e v a l u e " ' + V f + ' " i s i n v a l i d f o r o p t i o n " s i z e " ' ) } f u n c t i o n u d ( V f , E f , A f ) { r e t u r n c d ( V f ) , V f < = 0 ? s d ( V f ) : E f ! = = v o i d 0 ? t y p e o f A f = = " s t r i n g " ? s d ( V f ) . f i l l ( E f , A f ) : s d ( V f ) . f i l l ( E f ) : s d ( V f ) } o d . a l l o c = f u n c t i o n ( V f , E f , A f ) { r e t u r n u d ( V f , E f , A f ) } ; f u n c t i o n _ d ( V f ) { r e t u r n c d ( V f ) , s d ( V f < 0 ? 0 : R d ( V f ) | 0 ) } o d . a l l o c U n s a f e = f u n c t i o n ( V f ) { r e t u r n _ d ( V f ) } , o d . a l l o c U n s a f e S l o w = f u n c t i o n ( V f ) { r e t u r n _ d ( V f ) } ; f u n c t i o n y d ( V f , E f ) { i f ( ( t y p e o f E f ! = " s t r i n g " | | E f = = = " " ) & & ( E f = " u t f 8 " ) , ! o d . i s E n c o d i n g ( E f ) ) t h r o w n e w T y p e E r r o r ( " U n k n o w n e n c o d i n g : " + E f ) ; v a r A f = I d ( V f , E f ) | 0 , P f = s d ( A f ) , h h = P f . w r i t e ( V f , E f ) ; r e t u r n h h ! = = A f & & ( P f = P f . s l i c e ( 0 , h h ) ) , P f } f u n c t i o n g d ( V f ) { f o r ( v a r E f = V f . l e n g t h < 0 ? 0 : R d ( V f . l e n g t h ) | 0 , A f = s d ( E f ) , P f = 0 ; P f < E f ; P f + = 1 ) A f [ P f ] = V f [ P f ] & 2 5 5 ; r e t u r n A f } f u n c t i o n E d ( V f ) { i f ( I f ( V f , U i n t 8 A r r a y ) ) { v a r E f = n e w U i n t 8 A r r a y ( V f ) ; r e t u r n T d ( E f . b u f f e r , E f . b y t e O f f s e t , E f . b y t e L e n g t h ) } r e t u r n g d ( V f ) } f u n c t i o n T d ( V f , E f , A f ) { i f ( E f < 0 | | V f . b y t e L e n g t h < E f ) t h r o w n e w R a n g e E r r o r ( ' " o f f s e t " i s o u t s i d e o f b u f f e r b o u n d s ' ) ; i f ( V f . b y t e L e n g t h < E f + ( A f | | 0 ) ) t h r o w n e w R a n g e E r r o r ( ' " l e n g t h " i s o u t s i d e o f b u f f e r b o u n d s ' ) ; v a r P f ; r e t u r n E f = = = v o i d 0 & & A f = = = v o i d 0 ? P f = n e w U i n t 8 A r r a y ( V f ) : A f = = = v o i d 0 ? P f = n e w U i n t 8 A r r a y ( V f , E f ) : P f = n e w U i n t 8 A r r a y ( V f , E f , A f ) , O b j e c t . s e t P r o t o t y p e O f ( P f , o d . p r o t o t y p e ) , P f } f u n c t i o n O d ( V f ) { i f ( o d . i s B u f f e r ( V f ) ) { v a r E f = R d ( V f . l e n g t h ) | 0 , A f = s d ( E f ) ; r e t u r n A f . l e n g t h = = = 0 | | V f . c o p y ( A f , 0 , 0 , E f ) , A f } i f ( V f . l e n g t h ! = = v o i d 0 ) r e t u r n t y p e o f V f . l e n g t h ! = " n u m b e r " | | J f ( V f . l e n g t h ) ? s d ( 0 ) : g d ( V f ) ; i f ( V f . t y p e = = = " B u f f e r " & & A r r a y . i s A r r a y ( V f . d a t a ) ) r e t u r n g d ( V f . d a t a ) } f u n c t i o n R d ( V f ) { i f ( V f > = t d ) t h r o w n e w R a n g e E r r o r ( " A t t e m p t t o a l l o c a t e B u f f e r l a r g e r t h a n m a x i m u m s i z e : 0 x " + t d . t o S t r i
2024-09-07 10:27:05 +08:00
` )>-1&&( $ f?dh=dh.split( `
` ).map(function(If){return" "+If}).join( `
` ).slice(2):dh= `
` +dh.split( `
` ).map(function(If){return" "+If}).join( `
2024-09-08 17:22:36 +08:00
` ))):dh=wf.stylize("[Circular]","special")),Ud(Gf)){if( $ f&&_f.match(/^ \d + $ /))return dh;Gf=JSON.stringify(""+_f),Gf.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)" $ /)?(Gf=Gf.slice(1,-1),Gf=wf.stylize(Gf,"name")):(Gf=Gf.replace(/'/g," \\ '").replace(/ \\ "/g,'"').replace(/(^"|" $ )/g,"'"),Gf=wf.stylize(Gf,"string"))}return Gf+": "+dh}function Rd(wf,Wf,Uf){var gf=wf.reduce(function(_f, $ f){return $ f.indexOf( `
` )>=0,_f+ $ f.replace(/ \u 001b \[ \d \d ?m/g,"").length+1},0);return gf>60?Uf[0]+(Wf===""?"":Wf+ `
2024-09-03 08:22:14 +08:00
` )+" "+wf.join( ` ,
2024-09-08 19:53:57 +08:00
` )+" "+Uf[1]:Uf[0]+Wf+" "+wf.join(", ")+" "+Uf[1]}Ra.types=types;function Nd(wf){return Array.isArray(wf)}Ra.isArray=Nd;function Id(wf){return typeof wf=="boolean"}Ra.isBoolean=Id;function Md(wf){return wf===null}Ra.isNull=Md;function Ld(wf){return wf==null}Ra.isNullOrUndefined=Ld;function Pd(wf){return typeof wf=="number"}Ra.isNumber=Pd;function qd(wf){return typeof wf=="string"}Ra.isString=qd;function Yd(wf){return typeof wf=="symbol"}Ra.isSymbol=Yd;function Ud(wf){return wf===void 0}Ra.isUndefined=Ud;function Hd(wf){return zd(wf)&&hf(wf)==="[object RegExp]"}Ra.isRegExp=Hd,Ra.types.isRegExp=Hd;function zd(wf){return typeof wf=="object"&&wf!==null}Ra.isObject=zd;function Jd(wf){return zd(wf)&&hf(wf)==="[object Date]"}Ra.isDate=Jd,Ra.types.isDate=Jd;function Zd(wf){return zd(wf)&&(hf(wf)==="[object Error]"||wf instanceof Error)}Ra.isError=Zd,Ra.types.isNativeError=Zd;function pf(wf){return typeof wf=="function"}Ra.isFunction=pf;function Qd(wf){return wf===null||typeof wf=="boolean"||typeof wf=="number"||typeof wf=="string"||typeof wf=="symbol"||typeof wf>"u"}Ra.isPrimitive=Qd,Ra.isBuffer=isBufferBrowser;function hf(wf){return Object.prototype.toString.call(wf)}function mf(wf){return wf<10?"0"+wf.toString(10):wf.toString(10)}var xf=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function Lf(){var wf=new Date,Wf=[mf(wf.getHours()),mf(wf.getMinutes()),mf(wf.getSeconds())].join(":");return[wf.getDate(),xf[wf.getMonth()],Wf].join(" ")}Ra.log=function(){console.log("%s - %s",Lf(),Ra.format.apply(Ra,arguments))},Ra.inherits=inherits_browserExports,Ra._extend=function(wf,Wf){if(!Wf||!zd(Wf))return wf;for(var Uf=Object.keys(Wf),gf=Uf.length;gf--;)wf[Uf[gf]]=Wf[Uf[gf]];return wf};function Kf(wf,Wf){return Object.prototype.hasOwnProperty.call(wf,Wf)}var Yf=typeof Symbol<"u"?Symbol("util.promisify.custom"):void 0;Ra.promisify=function(Wf){if(typeof Wf!="function")throw new TypeError('The "original" argument must be of type Function');if(Yf&&Wf[Yf]){var Uf=Wf[Yf];if(typeof Uf!="function")throw new TypeError('The "util.promisify.custom" argument must be of type Function');return Object.defineProperty(Uf,Yf,{value:Uf,enumerable:!1,writable:!1,configurable:!0}),Uf}function Uf(){for(var gf,_f, $ f=new Promise(function(zf,If){gf=zf,_f=If}),Gf=[],dh=0;dh<arguments.length;dh++)Gf.push(arguments[dh]);Gf.push(function(zf,If){zf?_f(zf):gf(If)});try{Wf.apply(this,Gf)}catch(zf){_f(zf)}return $ f}return Object.setPrototypeOf(Uf,Object.getPrototypeOf(Wf)),Yf&&Object.defineProperty(Uf,Yf,{value:Uf,enumerable:!1,writable:!1,configurable:!0}),Object.defineProperties(Uf,ed(Wf))},Ra.promisify.custom=Yf;function Of(wf,Wf){if(!wf){var Uf=new Error("Promise was rejected with a falsy value");Uf.reason=wf,wf=Uf}return Wf(wf)}function Tf(wf){if(typeof wf!="function")throw new TypeError('The "original" argument must be of type Function');function Wf(){for(var Uf=[],gf=0;gf<arguments.length;gf++)Uf.push(arguments[gf]);var _f=Uf.pop();if(typeof _f!="function")throw new TypeError("The last argument must be of type Function");var $ f=this,Gf=function(){return _f.apply( $ f,arguments)};wf.apply(this,Uf).then(function(dh){qa.nextTick(Gf.bind(null,null,dh))},function(dh){qa.nextTick(Of.bind(null,dh,Gf))})}return Object.setPrototypeOf(Wf,Object.getPrototypeOf(wf)),Object.defineProperties(Wf,ed(wf)),Wf}Ra.callbackify=Tf})(util $ 5);var buffer_list,hasRequiredBuffer_list;function requireBuffer_list(){if(hasRequiredBuffer_list)return buffer_list;hasRequiredBuffer_list=1;function Ra(Ed,Td){var Od=Object.keys(Ed);if(Object.getOwnPropertySymbols){var Rd=Object.getOwnPropertySymbols(Ed);Td&&(Rd=Rd.filter(function(Nd){return Object.getOwnPropertyDescriptor(Ed,Nd).enumerable})),Od.push.apply(Od,Rd)}return Od}function qa(Ed){for(var Td=1;Td<arguments.length;Td++){var Od=arguments[Td]!=null?arguments[Td]:{};Td%2?Ra(Object(Od),!0).forEach(function(Rd){Ja(Ed,Rd,Od[Rd])}):Object.getOwnPropertyDescriptors?Object.defineProperties(Ed,Object.getOwnPropertyDescriptors(Od)):Ra(Object(Od)).forEach(function(Rd){Object.defineProperty(Ed,Rd,Object.getOwnPropertyDescript
2024-08-30 15:19:18 +08:00
` ,Ja);Ja=td===-1?Ra.length:td}else if(ed!==-1&&Ra[Ja]==="/"&&Ra[Ja+1]==="*"){let td=Ra.indexOf("*/",Ja);td!==-1?(Ja=td+2,ed=Ra.indexOf("*/",Ja)):(qa+=Ra[Ja],Ja++)}else qa+=Ra[Ja],Ja++;return qa}function parseParams(Ra){const qa=stripComments(Ra.toString());let Ja=qa.match(FN_ARGS);if(Ja||(Ja=qa.match(ARROW_FN_ARGS)),!Ja)throw new Error( ` could not parse args in autoInject
2024-08-27 22:31:52 +08:00
Source :
2024-09-08 17:22:36 +08:00
` +qa);let[,ed]=Ja;return ed.replace(/ \s /g,"").split(FN_ARG_SPLIT).map(td=>td.replace(FN_ARG,"").trim())}function autoInject(Ra,qa){var Ja={};return Object.keys(Ra).forEach(ed=>{var td=Ra[ed],rd,sd=isAsync(td),od=!sd&&td.length===1||sd&&td.length===0;if(Array.isArray(td))rd=[...td],td=rd.pop(),Ja[ed]=rd.concat(rd.length>0?ld:td);else if(od)Ja[ed]=td;else{if(rd=parseParams(td),td.length===0&&!sd&&rd.length===0)throw new Error("autoInject task functions require explicit parameters.");sd||rd.pop(),Ja[ed]=rd.concat(ld)}function ld(cd,ud){var _d=rd.map(yd=>cd[yd]);_d.push(ud),wrapAsync(td)(..._d)}}),auto(Ja,qa)}class DLL{constructor(){this.head=this.tail=null,this.length=0}removeLink(qa){return qa.prev?qa.prev.next=qa.next:this.head=qa.next,qa.next?qa.next.prev=qa.prev:this.tail=qa.prev,qa.prev=qa.next=null,this.length-=1,qa}empty(){for(;this.head;)this.shift();return this}insertAfter(qa,Ja){Ja.prev=qa,Ja.next=qa.next,qa.next?qa.next.prev=Ja:this.tail=Ja,qa.next=Ja,this.length+=1}insertBefore(qa,Ja){Ja.prev=qa.prev,Ja.next=qa,qa.prev?qa.prev.next=Ja:this.head=Ja,qa.prev=Ja,this.length+=1}unshift(qa){this.head?this.insertBefore(this.head,qa):setInitial(this,qa)}push(qa){this.tail?this.insertAfter(this.tail,qa):setInitial(this,qa)}shift(){return this.head&&this.removeLink(this.head)}pop(){return this.tail&&this.removeLink(this.tail)}toArray(){return[...this]}*[Symbol.iterator](){for(var qa=this.head;qa;)yield qa.data,qa=qa.next}remove(qa){for(var Ja=this.head;Ja;){var{next:ed}=Ja;qa(Ja)&&this.removeLink(Ja),Ja=ed}return this}}function setInitial(Ra,qa){Ra.length=1,Ra.head=Ra.tail=qa}function queue $ 1(Ra,qa,Ja){if(qa==null)qa=1;else if(qa===0)throw new RangeError("Concurrency must not be zero");var ed=wrapAsync(Ra),td=0,rd=[];const sd={error:[],drain:[],saturated:[],unsaturated:[],empty:[]};function od(Nd,Id){sd[Nd].push(Id)}function ld(Nd,Id){const Md=(...Ld)=>{cd(Nd,Md),Id(...Ld)};sd[Nd].push(Md)}function cd(Nd,Id){if(!Nd)return Object.keys(sd).forEach(Md=>sd[Md]=[]);if(!Id)return sd[Nd]=[];sd[Nd]=sd[Nd].filter(Md=>Md!==Id)}function ud(Nd,...Id){sd[Nd].forEach(Md=>Md(...Id))}var _d=!1;function yd(Nd,Id,Md,Ld){if(Ld!=null&&typeof Ld!="function")throw new Error("task callback must be a function");Rd.started=!0;var Pd,qd;function Yd(Hd,...zd){if(Hd)return Md?qd(Hd):Pd();if(zd.length<=1)return Pd(zd[0]);Pd(zd)}var Ud=Rd._createTaskItem(Nd,Md?Yd:Ld||Yd);if(Id?Rd._tasks.unshift(Ud):Rd._tasks.push(Ud),_d||(_d=!0,setImmediate $ 1 $ 1(()=>{_d=!1,Rd.process()})),Md||!Ld)return new Promise((Hd,zd)=>{Pd=Hd,qd=zd})}function gd(Nd){return function(Id,...Md){td-=1;for(var Ld=0,Pd=Nd.length;Ld<Pd;Ld++){var qd=Nd[Ld],Yd=rd.indexOf(qd);Yd===0?rd.shift():Yd>0&&rd.splice(Yd,1),qd.callback(Id,...Md),Id!=null&&ud("error",Id,qd.data)}td<=Rd.concurrency-Rd.buffer&&ud("unsaturated"),Rd.idle()&&ud("drain"),Rd.process()}}function Ed(Nd){return Nd.length===0&&Rd.idle()?(setImmediate $ 1 $ 1(()=>ud("drain")),!0):!1}const Td=Nd=>Id=>{if(!Id)return new Promise((Md,Ld)=>{ld(Nd,(Pd,qd)=>{if(Pd)return Ld(Pd);Md(qd)})});cd(Nd),od(Nd,Id)};var Od=!1,Rd={_tasks:new DLL,_createTaskItem(Nd,Id){return{data:Nd,callback:Id}},*[Symbol.iterator](){yield*Rd._tasks[Symbol.iterator]()},concurrency:qa,payload:Ja,buffer:qa/4,started:!1,paused:!1,push(Nd,Id){return Array.isArray(Nd)?Ed(Nd)?void 0:Nd.map(Md=>yd(Md,!1,!1,Id)):yd(Nd,!1,!1,Id)},pushAsync(Nd,Id){return Array.isArray(Nd)?Ed(Nd)?void 0:Nd.map(Md=>yd(Md,!1,!0,Id)):yd(Nd,!1,!0,Id)},kill(){cd(),Rd._tasks.empty()},unshift(Nd,Id){return Array.isArray(Nd)?Ed(Nd)?void 0:Nd.map(Md=>yd(Md,!0,!1,Id)):yd(Nd,!0,!1,Id)},unshiftAsync(Nd,Id){return Array.isArray(Nd)?Ed(Nd)?void 0:Nd.map(Md=>yd(Md,!0,!0,Id)):yd(Nd,!0,!0,Id)},remove(Nd){Rd._tasks.remove(Nd)},process(){if(!Od){for(Od=!0;!Rd.paused&&td<Rd.concurrency&&Rd._tasks.length;){var Nd=[],Id=[],Md=Rd._tasks.length;Rd.payload&&(Md=Math.min(Md,Rd.payload));for(var Ld=0;Ld<Md;Ld++){var Pd=Rd._tasks.shift();Nd.push(Pd),rd.push(Pd),Id.push(Pd.data)}td+=1,Rd._tasks.length===0&&ud("empty"),td===Rd.concurrency&&ud("saturated");var qd=onlyOnce(gd(Nd));ed(Id,qd)}Od=!1}},length(){return Rd._tasks.
2024-08-27 22:31:52 +08:00
* @ license
* Lodash < https : //lodash.com/>
* Copyright OpenJS Foundation and other contributors < https : //openjsf.org/>
* Released under MIT license < https : //lodash.com/license>
* Based on Underscore . js 1.8 . 3 < http : //underscorejs.org/LICENSE>
* Copyright Jeremy Ashkenas , DocumentCloud and Investigative Reporters & Editors
2024-09-08 17:22:36 +08:00
* /lodash.exports;(function(Ra,qa){(function(){var Ja,ed="4.17.21",td=200,rd="Unsupported core-js use. Try https:/ / npms . io / search ? q = ponyfill . ",sd=" Expected a function ",od=" Invalid ` variable ` option passed into ` _.template ` ",ld=" _ _lodash _hash _undefined _ _ ",cd=500,ud=" _ _lodash _placeholder _ _ ",_d=1,yd=2,gd=4,Ed=1,Td=2,Od=1,Rd=2,Nd=4,Id=8,Md=16,Ld=32,Pd=64,qd=128,Yd=256,Ud=512,Hd=30,zd=" ... ",Jd=800,Zd=16,pf=1,Qd=2,hf=3,mf=1/0,xf=9007199254740991,Lf=17976931348623157e292,Kf=NaN,Yf=4294967295,Of=Yf-1,Tf=Yf>>>1,wf=[[" ary ",qd],[" bind ",Od],[" bindKey ",Rd],[" curry ",Id],[" curryRight ",Md],[" flip ",Ud],[" partial ",Ld],[" partialRight ",Pd],[" rearg ",Yd]],Wf=" [ object Arguments ] ",Uf=" [ object Array ] ",gf=" [ object AsyncFunction ] ",_f=" [ object Boolean ] ",$f=" [ object Date ] ",Gf=" [ object DOMException ] ",dh=" [ object Error ] ",zf=" [ object Function ] ",If=" [ object GeneratorFunction ] ",Jf=" [ object Map ] ",Th=" [ object Number ] ",Vf=" [ object Null ] ",Ef=" [ object Object ] ",Af=" [ object Promise ] ",Pf=" [ object Proxy ] ",hh=" [ object RegExp ] ",Ah=" [ object Set ] ",uh=" [ object String ] ",Fh=" [ object Symbol ] ",Nh=" [ object Undefined ] ",Bh=" [ object WeakMap ] ",Jh=" [ object WeakSet ] ",zh=" [ object ArrayBuffer ] ",sm=" [ object DataView ] ",fm=" [ object Float32Array ] ",ih=" [ object Float64Array ] ",Rf=" [ object Int8Array ] ",Df=" [ object Int16Array ] ",Zf=" [ object Int32Array ] ",_h=" [ object Uint8Array ] ",Mh=" [ object Uint8ClampedArray ] ",qh=" [ object Uint16Array ] ",Xh=" [ object Uint32Array ] ",gm=/\b__p \+= '';/g,om=/\b(__p \+=) '' \+/g,Vm=/(__e\(.*?\)|\b__t\)) \+\n'';/g,Pm=/&(?:amp|lt|gt|quot|#39);/g,Mm=/[&<>" ']/g,Jm=RegExp(Pm.source),N_=RegExp(Mm.source),I_=/<%-([\s\S]+?)%>/g,y_=/<%([\s\S]+?)%>/g,Xm=/<%=([\s\S]+?)%>/g,L_=/\.|\[(?:[^[\]]*|(["' ] ) ( ? : ( ? ! \ 1 ) [ ^ \ \ ] | \ \ . ) * ? \ 1 ) \ ] / , w _ = /^\w*$/ , G _ = /[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g , J _ = /[\\^$.*+?()[\]{}|]/g , R _ = RegExp ( J _ . source ) , k _ = /^\s+/ , jm = /\s/ , g _ = /\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/ , o1 = /\{\n\/\* \[wrapped with (.+)\] \*/ , im = /,? & / , Cf = /[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g , bh = /[()=,{}\[\]\/\s]/ , sh = /\\(\\)?/g , yh = /\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g , Lh = /\w*$/ , kh = /^[-+]0x[0-9a-f]+$/i , Hh = /^0b[01]+$/i , $h = /^\[object .+?Constructor\]$/ , wh = /^0o[0-7]+$/i , um = /^(?:0|[1-9]\d*)$/ , cm = /[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g , _m = /($^)/ , Ff = /['\n\r\u2028\u2029\\]/g , Om = "\\ud800-\\udfff" , m _ = "\\u0300-\\u036f" , f _ = "\\ufe20-\\ufe2f" , a _ = "\\u20d0-\\u20ff" , Dm = m _ + f _ + a _ , v _ = "\\u2700-\\u27bf" , u _ = "a-z\\xdf-\\xf6\\xf8-\\xff" , o _ = "\\xac\\xb1\\xd7\\xf7" , oh = "\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf" , Oh = "\\u2000-\\u206f" , mm = " \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000" , Lm = "A-Z\\xc0-\\xd6\\xd8-\\xde" , am = "\\ufe0e\\ufe0f" , zm = o _ + oh + Oh + mm , E _ = "['’ ]" , t1 = "[" + Om + "]" , U _ = "[" + zm + "]" , A1 = "[" + Dm + "]" , _1 = "\\d+" , h _ = "[" + v _ + "]" , j1 = "[" + u _ + "]" , F _ = "[^" + Om + zm + _1 + v _ + u _ + Lm + "]" , y1 = "\\ud83c[\\udffb-\\udfff]" , u1 = "(?:" + A1 + "|" + y1 + ")" , Z1 = "[^" + Om + "]" , _g = "(?:\\ud83c[\\udde6-\\uddff]){2}" , E1 = "[\\ud800-\\udbff][\\udc00-\\udfff]" , tg = "[" + Lm + "]" , o0 = "\\u200d" , Wg = "(?:" + j1 + "|" + F _ + ")" , s _ = "(?:" + tg + "|" + F _ + ")" , bg = "(?:" + E _ + "(?:d|ll|m|re|s|t|ve))?" , g1 = "(?:" + E _ + "(?:D|LL|M|RE|S|T|VE))?" , l0 = u1 + "?" , y0 = "[" + am + "]?" , vg = "(?:" + o0 + "(?:" + [ Z1 , _g , E1 ] . join ( "|" ) + ")" + y0 + l0 + ")*" , Dg = "\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])" , d1 = "\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])" , z1 = y0 + l0 + vg , sg = "(?:" + [ h _ , _g , E1 ] . join ( "|" ) + ")" + z1 , rg = "(?:" + [ Z1 + A1 + "?" , A1 , _g , E1 , t1 ] . join ( "|" ) + ")" , Yg = RegExp ( E _ , "g" ) , _b = RegExp ( A1 , "g" ) , j0 = RegExp ( y1 + "(?=" + y1 + ")|" + rg + z1 , "g" ) , gb = RegExp ( [ tg + "?" + j1 + "+" + bg + "(?=" + [ U _ , tg , "$" ] . join ( "|" ) + ")" , s _ + "+" + g1 + "(?=" + [ U _ , tg + Wg , "$" ] . join ( "|" ) + ")" , tg + "?" + Wg + "+" + bg , tg + "+" + g1 , d1 , Dg , _1 , sg ] . join ( "|" ) , "g" ) , Qb = RegExp ( "[" + o0 + Om + Dm + am + "]" ) , U0 = /[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/ , q0 = [ "Array" , "Buffer" , "DataView" , "Date" , "Error" , "Float32Array" , "Float64Array" , "Function" , "Int8Array" , "Int16Array" , "Int32Array" , "Map" , "Math" , "Object" , "Promise" , "RegExp" , "Set" , "String" , "Symbol" , "TypeError" , "Uint8Array" , "Uint8ClampedArray" , "Uint16Array" , "Uint32Array" , "WeakMap" , "_" , " clearTim
2024-09-03 08:22:14 +08:00
/* [wrapped with `+Kd+`] */
2024-09-08 17:22:36 +08:00
` )}function Bd(Fd){return O_(Fd)||xv(Fd)||!!(LE&&Fd&&Fd[LE])}function Wd(Fd,Kd){var bf=typeof Fd;return Kd=Kd??xf,!!Kd&&(bf=="number"||bf!="symbol"&&um.test(Fd))&&Fd>-1&&Fd%1==0&&Fd<Kd}function Gd(Fd,Kd,bf){if(!w1(bf))return!1;var jf=typeof Kd;return(jf=="number"?wg(bf)&&Wd(Kd,bf.length):jf=="string"&&Kd in bf)?b0(bf[Kd],Fd):!1}function Xd(Fd,Kd){if(O_(Fd))return!1;var bf=typeof Fd;return bf=="number"||bf=="symbol"||bf=="boolean"||Fd==null||Hg(Fd)?!0:w_.test(Fd)||!L_.test(Fd)||Kd!=null&&Fd in n1(Kd)}function yf(Fd){var Kd=typeof Fd;return Kd=="string"||Kd=="number"||Kd=="symbol"||Kd=="boolean"?Fd!=="__proto__":Fd===null}function kf(Fd){var Kd=Tv(Fd),bf=Ch[Kd];if(typeof bf!="function"||!(Kd in b_.prototype))return!1;if(Fd===bf)return!0;var jf=Ev(bf);return!!jf&&Fd===jf[0]}function qf(Fd){return!!Iv&&Iv in Fd}var Qf=p0?pb:ET;function ch(Fd){var Kd=Fd&&Fd.constructor,bf=typeof Kd=="function"&&Kd.prototype||kg;return Fd===bf}function Ih(Fd){return Fd===Fd&&!w1(Fd)}function Uh(Fd,Kd){return function(bf){return bf==null?!1:bf[Fd]===Kd&&(Kd!==Ja||Fd in n1(bf))}}function Kh(Fd){var Kd=w2(Fd,function(jf){return bf.size===cd&&bf.clear(),jf}),bf=Kd.cache;return Kd}function Yh(Fd,Kd){var bf=Fd[1],jf=Kd[1],ph=bf|jf,Dh=ph<(Od|Rd|qd),Gh=jf==qd&&bf==Id||jf==qd&&bf==Yd&&Fd[7].length<=Kd[8]||jf==(qd|Yd)&&Kd[7].length<=Kd[8]&&bf==Id;if(!(Dh||Gh))return Fd;jf&Od&&(Fd[2]=Kd[2],ph|=bf&Od?0:Nd);var Wh=Kd[3];if(Wh){var Zh=Fd[3];Fd[3]=Zh?Wv(Zh,Wh,Kd[4]):Wh,Fd[4]=Zh?ug(Fd[3],ud):Kd[4]}return Wh=Kd[5],Wh&&(Zh=Fd[5],Fd[5]=Zh?vE(Zh,Wh,Kd[6]):Wh,Fd[6]=Zh?ug(Fd[5],ud):Kd[6]),Wh=Kd[7],Wh&&(Fd[7]=Wh),jf&qd&&(Fd[8]=Fd[8]==null?Kd[8]:D1(Fd[8],Kd[8])),Fd[9]==null&&(Fd[9]=Kd[9]),Fd[0]=Kd[0],Fd[1]=ph,Fd}function hm(Fd){var Kd=[];if(Fd!=null)for(var bf in n1(Fd))Kd.push(bf);return Kd}function Nm(Fd){return Qg.call(Fd)}function Hm(Fd,Kd,bf){return Kd=c1(Kd===Ja?Fd.length-1:Kd,0),function(){for(var jf=arguments,ph=-1,Dh=c1(jf.length-Kd,0),Gh=dm(Dh);++ph<Dh;)Gh[ph]=jf[Kd+ph];ph=-1;for(var Wh=dm(Kd+1);++ph<Kd;)Wh[ph]=jf[ph];return Wh[Kd]=bf(Gh),Fm(Fd,this,Wh)}}function Km(Fd,Kd){return Kd.length<2?Fd:I0(Fd,M1(Kd,0,-1))}function Qm(Fd,Kd){for(var bf=Fd.length,jf=D1(Kd.length,bf),ph=ag(Fd);jf--;){var Dh=Kd[jf];Fd[jf]=Wd(Dh,bf)?ph[Dh]:Ja}return Fd}function Ym(Fd,Kd){if(!(Kd==="constructor"&&typeof Fd[Kd]=="function")&&Kd!="__proto__")return Fd[Kd]}var e_=r1(c2),c_= $ v||function(Fd,Kd){return z_.setTimeout(Fd,Kd)},l_=r1(X2);function D_(Fd,Kd,bf){var jf=Kd+"";return l_(Fd,Ad(jf,x1(b1(jf),bf)))}function r1(Fd){var Kd=0,bf=0;return function(){var jf=M2(),ph=Zd-(jf-bf);if(bf=jf,ph>0){if(++Kd>=Jd)return arguments[0]}else Kd=0;return Fd.apply(Ja,arguments)}}function v1(Fd,Kd){var bf=-1,jf=Fd.length,ph=jf-1;for(Kd=Kd===Ja?jf:Kd;++bf<Kd;){var Dh=Vv(bf,ph),Gh=Fd[Dh];Fd[Dh]=Fd[bf],Fd[bf]=Gh}return Fd.length=Kd,Fd}var s1=Kh(function(Fd){var Kd=[];return Fd.charCodeAt(0)===46&&Kd.push(""),Fd.replace(G_,function(bf,jf,ph,Dh){Kd.push(ph?Dh.replace(sh," $ 1"):jf||bf)}),Kd});function h1(Fd){if(typeof Fd=="string"||Hg(Fd))return Fd;var Kd=Fd+"";return Kd=="0"&&1/Fd==-mf?"-0":Kd}function S1(Fd){if(Fd!=null){try{return Cb.call(Fd)}catch{}try{return Fd+""}catch{}}return""}function x1(Fd,Kd){return A_(wf,function(bf){var jf="_."+bf[0];Kd&bf[1]&&!z0(Fd,jf)&&Fd.push(jf)}),Fd.sort()}function Y1(Fd){if(Fd instanceof b_)return Fd.clone();var Kd=new e1(Fd.__wrapped__,Fd.__chain__);return Kd.__actions__=ag(Fd.__actions__),Kd.__index__=Fd.__index__,Kd.__values__=Fd.__values__,Kd}function H1(Fd,Kd,bf){(bf?Gd(Fd,Kd,bf):Kd===Ja)?Kd=1:Kd=c1(M_(Kd),0);var jf=Fd==null?0:Fd.length;if(!jf||Kd<1)return[];for(var ph=0,Dh=0,Gh=dm(tv(jf/Kd));ph<jf;)Gh[Dh++]=M1(Fd,ph,ph+=Kd);return Gh}function R1(Fd){for(var Kd=-1,bf=Fd==null?0:Fd.length,jf=0,ph=[];++Kd<bf;){var Dh=Fd[Kd];Dh&&(ph[jf++]=Dh)}return ph}function C1(){var Fd=arguments.length;if(!Fd)return[];for(var Kd=dm(Fd-1),bf=arguments[0],jf=Fd;jf--;)Kd[jf-1]=arguments[jf];return Ig(O_(bf)?ag(bf):[bf], $ 1(Kd,1))}var m1= $ _(function(Fd,Kd){return P1(Fd)?ov(Fd, $ 1(Kd,1,P1,!0)):[]}),J1= $ _(function(Fd,Kd){var bf=a0(Kd);return P1(bf)&&(bf=Ja),P1(Fd)?ov(Fd, $ 1(Kd,1,P1,!0
` ;Fd.replace(t_,function(S_,j_,V_,Vg,mg,zg){return V_||(V_=Vg),Um+=Fd.slice(Rm,zg).replace(Ff,Y0),j_&&(Wh=!0,Um+= ` ' +
2024-09-07 10:27:05 +08:00
_ _e ( ` +j_+ ` ) +
'`),mg&&(Zh=!0,Um+=`' ;
` +mg+ ` ;
2024-09-08 17:22:36 +08:00
_ _p += '`),V_&&(Um+=`' +
( ( _ _t = ( ` +V_+ ` ) ) == null ? '' : _ _t ) +
2024-09-07 10:27:05 +08:00
'`),Rm=zg+S_.length,S_}),Um+=`' ;
` ;var T_=Q_.call(Kd,"variable")&&Kd.variable;if(!T_)Um= ` with ( obj ) {
2024-09-03 08:22:14 +08:00
` +Um+ `
2024-08-27 22:31:52 +08:00
}
2024-09-08 17:22:36 +08:00
` ;else if(bh.test(T_))throw new C_(od);Um=(Zh?Um.replace(gm,""):Um).replace(om," $ 1").replace(Vm," $ 1;"),Um="function("+(T_||"obj")+ ` ) {
2024-09-07 10:27:05 +08:00
` +(T_?"": ` obj || ( obj = { } ) ;
` )+"var __t, __p = ''"+(Wh?", __e = _.escape":"")+(Zh? ` , _ _j = Array . prototype . join ;
2024-08-27 22:31:52 +08:00
function print ( ) { _ _p += _ _j . call ( arguments , '' ) }
` : ` ;
2024-09-03 08:22:14 +08:00
` )+Um+ ` return _ _p
2024-09-08 19:53:57 +08:00
} ` ;var B_=rS(function(){return q_(Dh,p_+"return "+Um).apply(Ja,Gh)});if(B_.source=Um,dT(B_))throw B_;return B_}function Tw(Fd){return i1(Fd).toLowerCase()}function Sw(Fd){return i1(Fd).toUpperCase()}function xw(Fd,Kd,bf){if(Fd=i1(Fd),Fd&&(bf||Kd===Ja))return r_(Fd);if(!Fd||!(Kd=fg(Kd)))return Fd;var jf=Og(Fd),ph=Og(Kd),Dh=W_(jf,ph),Gh=O1(jf,ph)+1;return g0(jf,Dh,Gh).join("")}function Cw(Fd,Kd,bf){if(Fd=i1(Fd),Fd&&(bf||Kd===Ja))return Fd.slice(0,By(Fd)+1);if(!Fd||!(Kd=fg(Kd)))return Fd;var jf=Og(Fd),ph=O1(jf,Og(Kd))+1;return g0(jf,0,ph).join("")}function ww(Fd,Kd,bf){if(Fd=i1(Fd),Fd&&(bf||Kd===Ja))return Fd.replace(k_,"");if(!Fd||!(Kd=fg(Kd)))return Fd;var jf=Og(Fd),ph=W_(jf,Og(Kd));return g0(jf,ph).join("")}function Aw(Fd,Kd){var bf=Hd,jf=zd;if(w1(Kd)){var ph="separator"in Kd?Kd.separator:ph;bf="length"in Kd?M_(Kd.length):bf,jf="omission"in Kd?fg(Kd.omission):jf}Fd=i1(Fd);var Dh=Fd.length;if(Sb(Fd)){var Gh=Og(Fd);Dh=Gh.length}if(bf>=Dh)return Fd;var Wh=bf-xb(jf);if(Wh<1)return jf;var Zh=Gh?g0(Gh,0,Wh).join(""):Fd.slice(0,Wh);if(ph===Ja)return Zh+jf;if(Gh&&(Wh+=Zh.length-Wh),pT(ph)){if(Fd.slice(Wh).search(ph)){var Rm, $ m=Zh;for(ph.global||(ph=ev(ph.source,i1(Lh.exec(ph))+"g")),ph.lastIndex=0;Rm=ph.exec( $ m);)var Um=Rm.index;Zh=Zh.slice(0,Um===Ja?Wh:Um)}}else if(Fd.indexOf(fg(ph),Wh)!=Wh){var t_=Zh.lastIndexOf(ph);t_>-1&&(Zh=Zh.slice(0,t_))}return Zh+jf}function Nw(Fd){return Fd=i1(Fd),Fd&&Jm.test(Fd)?Fd.replace(Pm,OE):Fd}var Dw=Gb(function(Fd,Kd,bf){return Fd+(bf?" ":"")+Kd.toUpperCase()}),mT=m2("toUpperCase");function tS(Fd,Kd,bf){return Fd=i1(Fd),Kd=bf?Ja:Kd,Kd===Ja?DE(Fd)? $ E(Fd):Iy(Fd):Fd.match(Kd)||[]}var rS= $ _(function(Fd,Kd){try{return Fm(Fd,Ja,Kd)}catch(bf){return dT(bf)?bf:new C_(bf)}}),Rw=r0(function(Fd,Kd){return A_(Kd,function(bf){bf=h1(bf),m0(Fd,bf,cT(Fd[bf],Fd))}),Fd});function Iw(Fd){var Kd=Fd==null?0:Fd.length,bf=__();return Fd=Kd?a1(Fd,function(jf){if(typeof jf[1]!="function")throw new Tg(sd);return[bf(jf[0]),jf[1]]}):[], $ _(function(jf){for(var ph=-1;++ph<Kd;){var Dh=Fd[ph];if(Fm(Dh[0],this,jf))return Fm(Dh[1],this,jf)}})}function Ow(Fd){return z2(pg(Fd,_d))}function _T(Fd){return function(){return Fd}}function kw(Fd,Kd){return Fd==null||Fd!==Fd?Kd:Fd}var $ w=_2(),Mw=_2(!0);function Ng(Fd){return Fd}function gT(Fd){return Pb(typeof Fd=="function"?Fd:pg(Fd,_d))}function Lw(Fd){return n2(pg(Fd,_d))}function Bw(Fd,Kd){return dE(Fd,pg(Kd,_d))}var Pw= $ _(function(Fd,Kd){return function(bf){return Lb(bf,Fd,Kd)}}),Fw= $ _(function(Fd,Kd){return function(bf){return Lb(Fd,bf,Kd)}});function bT(Fd,Kd,bf){var jf=X1(Kd),ph=qv(Kd,jf);bf==null&&!(w1(Kd)&&(ph.length||!jf.length))&&(bf=Kd,Kd=Fd,Fd=this,ph=qv(Kd,X1(Kd)));var Dh=!(w1(bf)&&"chain"in bf)||!!bf.chain,Gh=pb(Fd);return A_(ph,function(Wh){var Zh=Kd[Wh];Fd[Wh]=Zh,Gh&&(Fd.prototype[Wh]=function(){var Rm=this.__chain__;if(Dh||Rm){var $ m=Fd(this.__wrapped__),Um= $ m.__actions__=ag(this.__actions__);return Um.push({func:Zh,args:arguments,thisArg:Fd}), $ m.__chain__=Rm, $ m}return Zh.apply(Fd,Ig([this.value()],arguments))})}),Fd}function jw(){return z_._===this&&(z_._=Q1),this}function vT(){}function Uw(Fd){return Fd=M_(Fd), $ _(function(Kd){return jb(Kd,Fd)})}var qw=Kv(a1),Hw=Kv(og),Vw=Kv(S0);function nS(Fd){return Xd(Fd)?gh(h1(Fd)):Y2(Fd)}function Gw(Fd){return function(Kd){return Fd==null?Ja:I0(Fd,Kd)}}var zw=db(),Ww=db(!0);function yT(){return[]}function ET(){return!1}function Yw(){return{}}function Kw(){return""}function Xw(){return!0}function Qw(Fd,Kd){if(Fd=M_(Fd),Fd<1||Fd>xf)return[];var bf=Yf,jf=D1(Fd,Yf);Kd=__(Kd),Fd-=Yf;for(var ph=Wm(jf,Kd);++bf<Fd;)Kd(bf);return ph}function Jw(Fd){return O_(Fd)?a1(Fd,h1):Hg(Fd)?[Fd]:ag(s1(i1(Fd)))}function Zw(Fd){var Kd=++ME;return i1(Fd)+Kd}var eA=zb(function(Fd,Kd){return Fd+Kd},0),tA=SE("ceil"),rA=zb(function(Fd,Kd){return Fd/Kd},1),nA=SE("floor");function iA(Fd){return Fd&&Fd.length?jv(Fd,Ng,Hv):Ja}function aA(Fd,Kd){return Fd&&Fd.length?jv(Fd,__(Kd,2),Hv):Ja}function sA(Fd){return Xf(Fd,Ng)}function oA(Fd,Kd){return Xf(Fd,__(Kd,2))}function lA(Fd){return Fd&&Fd.length?jv(Fd,Ng,lb):Ja}function cA(Fd,Kd){return Fd&&Fd.length?jv(Fd,__
2024-09-03 08:22:14 +08:00
` :"")),Ja&&Ja()}function rd(sd){return sd.interrupt?(sd.interrupt.append=Ra,sd.interrupt.end=td,sd.interrupt=!1,Ra(!0),!0):!1}if(Ra(!1,qa.indents+(qa.name?"<"+qa.name:"")+(qa.attributes.length?" "+qa.attributes.join(" "):"")+(ed?qa.name?">":"":qa.name?"/>":"")+(qa.indent&&ed>1? `
2024-08-30 15:19:18 +08:00
` :"")),!ed)return Ra(!1,qa.indent? `
` :"");rd(qa)||td()}function attribute(Ra,qa){return Ra+'="'+escapeForXML(qa)+'"'}xml $ 2.exports=xml $ 1;xml $ 2.exports.element=xml $ 2.exports.Element=element;var xmlExports=xml $ 2.exports;const Xml=getDefaultExportFromCjs(xmlExports);var xml2js={},defaults $ 1={},hasRequiredDefaults;function requireDefaults(){return hasRequiredDefaults||(hasRequiredDefaults=1,(function(){defaults $ 1.defaults={"0.1":{explicitCharkey:!1,trim:!0,normalize:!0,normalizeTags:!1,attrkey:"@",charkey:"#",explicitArray:!1,ignoreAttrs:!1,mergeAttrs:!1,explicitRoot:!1,validator:null,xmlns:!1,explicitChildren:!1,childkey:"@@",charsAsChildren:!1,includeWhiteChars:!1,async:!1,strict:!0,attrNameProcessors:null,attrValueProcessors:null,tagNameProcessors:null,valueProcessors:null,emptyTag:""},"0.2":{explicitCharkey:!1,trim:!1,normalize:!1,normalizeTags:!1,attrkey:" $ ",charkey:"_",explicitArray:!0,ignoreAttrs:!1,mergeAttrs:!1,explicitRoot:!0,validator:null,xmlns:!1,explicitChildren:!1,preserveChildrenOrder:!1,childkey:" $ $ ",charsAsChildren:!1,includeWhiteChars:!1,async:!1,strict:!0,attrNameProcessors:null,attrValueProcessors:null,tagNameProcessors:null,valueProcessors:null,rootName:"root",xmldec:{version:"1.0",encoding:"UTF-8",standalone:!0},doctype:null,renderOpts:{pretty:!0,indent:" ",newline: `
2024-09-08 17:22:36 +08:00
` },headless:!1,chunkSize:1e4,emptyTag:"",cdata:!1}}}).call(commonjsGlobal)),defaults $ 1}var builder={},lib $ 1={},Utility={},hasRequiredUtility;function requireUtility(){return hasRequiredUtility||(hasRequiredUtility=1,(function(){var Ra,qa,Ja,ed,td,rd,sd,od=[].slice,ld={}.hasOwnProperty;Ra=function(){var cd,ud,_d,yd,gd,Ed;if(Ed=arguments[0],gd=2<=arguments.length?od.call(arguments,1):[],td(Object.assign))Object.assign.apply(null,arguments);else for(cd=0,_d=gd.length;cd<_d;cd++)if(yd=gd[cd],yd!=null)for(ud in yd)ld.call(yd,ud)&&(Ed[ud]=yd[ud]);return Ed},td=function(cd){return!!cd&&Object.prototype.toString.call(cd)==="[object Function]"},rd=function(cd){var ud;return!!cd&&((ud=typeof cd)=="function"||ud==="object")},Ja=function(cd){return td(Array.isArray)?Array.isArray(cd):Object.prototype.toString.call(cd)==="[object Array]"},ed=function(cd){var ud;if(Ja(cd))return!cd.length;for(ud in cd)if(ld.call(cd,ud))return!1;return!0},sd=function(cd){var ud,_d;return rd(cd)&&(_d=Object.getPrototypeOf(cd))&&(ud=_d.constructor)&&typeof ud=="function"&&ud instanceof ud&&Function.prototype.toString.call(ud)===Function.prototype.toString.call(Object)},qa=function(cd){return td(cd.valueOf)?cd.valueOf():cd},Utility.assign=Ra,Utility.isFunction=td,Utility.isObject=rd,Utility.isArray=Ja,Utility.isEmpty=ed,Utility.isPlainObject=sd,Utility.getValue=qa}).call(commonjsGlobal)),Utility}var XMLDOMImplementation={exports:{}},hasRequiredXMLDOMImplementation;function requireXMLDOMImplementation(){return hasRequiredXMLDOMImplementation||(hasRequiredXMLDOMImplementation=1,(function(){XMLDOMImplementation.exports=function(){function Ra(){}return Ra.prototype.hasFeature=function(qa,Ja){return!0},Ra.prototype.createDocumentType=function(qa,Ja,ed){throw new Error("This DOM method is not implemented.")},Ra.prototype.createDocument=function(qa,Ja,ed){throw new Error("This DOM method is not implemented.")},Ra.prototype.createHTMLDocument=function(qa){throw new Error("This DOM method is not implemented.")},Ra.prototype.getFeature=function(qa,Ja){throw new Error("This DOM method is not implemented.")},Ra}()}).call(commonjsGlobal)),XMLDOMImplementation.exports}var XMLDocument={exports:{}},XMLDOMConfiguration={exports:{}},XMLDOMErrorHandler={exports:{}},hasRequiredXMLDOMErrorHandler;function requireXMLDOMErrorHandler(){return hasRequiredXMLDOMErrorHandler||(hasRequiredXMLDOMErrorHandler=1,(function(){XMLDOMErrorHandler.exports=function(){function Ra(){}return Ra.prototype.handleError=function(qa){throw new Error(qa)},Ra}()}).call(commonjsGlobal)),XMLDOMErrorHandler.exports}var XMLDOMStringList={exports:{}},hasRequiredXMLDOMStringList;function requireXMLDOMStringList(){return hasRequiredXMLDOMStringList||(hasRequiredXMLDOMStringList=1,(function(){XMLDOMStringList.exports=function(){function Ra(qa){this.arr=qa||[]}return Object.defineProperty(Ra.prototype,"length",{get:function(){return this.arr.length}}),Ra.prototype.item=function(qa){return this.arr[qa]||null},Ra.prototype.contains=function(qa){return this.arr.indexOf(qa)!==-1},Ra}()}).call(commonjsGlobal)),XMLDOMStringList.exports}var hasRequiredXMLDOMConfiguration;function requireXMLDOMConfiguration(){return hasRequiredXMLDOMConfiguration||(hasRequiredXMLDOMConfiguration=1,(function(){var Ra,qa;Ra=requireXMLDOMErrorHandler(),qa=requireXMLDOMStringList(),XMLDOMConfiguration.exports=function(){function Ja(){this.defaultParams={"canonical-form":!1,"cdata-sections":!1,comments:!1,"datatype-normalization":!1,"element-content-whitespace":!0,entities:!0,"error-handler":new Ra,infoset:!0,"validate-if-schema":!1,namespaces:!0,"namespace-declarations":!0,"normalize-characters":!1,"schema-location":"","schema-type":"","split-cdata-sections":!0,validate:!1,"well-formed":!0},this.params=Object.create(this.defaultParams)}return Object.defineProperty(Ja.prototype,"parameterNames",{get:function(){return new qa(Object.keys(this.defaultParams))}}),Ja.prototype.getParameter=function(ed){return this.params.hasOwnProperty(ed)?this.params[ed]:null},Ja.prototype.canSetParameter=function(ed,td){return!0},Ja.prototype.setParameter=fu
` ,sd.offset=(cd=rd.offset)!=null?cd:0,sd.dontPrettyTextNodes=(ud=(_d=rd.dontPrettyTextNodes)!=null?_d:rd.dontprettytextnodes)!=null?ud:0,sd.spaceBeforeSlash=(yd=(gd=rd.spaceBeforeSlash)!=null?gd:rd.spacebeforeslash)!=null?yd:"",sd.spaceBeforeSlash===!0&&(sd.spaceBeforeSlash=" "),sd.suppressPrettyCount=0,sd.user={},sd.state=qa.None,sd},td.prototype.indent=function(rd,sd,od){var ld;return!sd.pretty||sd.suppressPrettyCount?"":sd.pretty&&(ld=(od||0)+sd.offset+1,ld>0)?new Array(ld).join(sd.indent):""},td.prototype.endline=function(rd,sd,od){return!sd.pretty||sd.suppressPrettyCount?"":sd.newline},td.prototype.attribute=function(rd,sd,od){var ld;return this.openAttribute(rd,sd,od),ld=" "+rd.name+'="'+rd.value+'"',this.closeAttribute(rd,sd,od),ld},td.prototype.cdata=function(rd,sd,od){var ld;return this.openNode(rd,sd,od),sd.state=qa.OpenTag,ld=this.indent(rd,sd,od)+"<![CDATA[",sd.state=qa.InsideTag,ld+=rd.value,sd.state=qa.CloseTag,ld+="]]>"+this.endline(rd,sd,od),sd.state=qa.None,this.closeNode(rd,sd,od),ld},td.prototype.comment=function(rd,sd,od){var ld;return this.openNode(rd,sd,od),sd.state=qa.OpenTag,ld=this.indent(rd,sd,od)+"<!-- ",sd.state=qa.InsideTag,ld+=rd.value,sd.state=qa.CloseTag,ld+=" -->"+this.endline(rd,sd,od),sd.state=qa.None,this.closeNode(rd,sd,od),ld},td.prototype.declaration=function(rd,sd,od){var ld;return this.openNode(rd,sd,od),sd.state=qa.OpenTag,ld=this.indent(rd,sd,od)+"<?xml",sd.state=qa.InsideTag,ld+=' version="'+rd.version+'"',rd.encoding!=null&&(ld+=' encoding="'+rd.encoding+'"'),rd.standalone!=null&&(ld+=' standalone="'+rd.standalone+'"'),sd.state=qa.CloseTag,ld+=sd.spaceBeforeSlash+"?>",ld+=this.endline(rd,sd,od),sd.state=qa.None,this.closeNode(rd,sd,od),ld},td.prototype.docType=function(rd,sd,od){var ld,cd,ud,_d,yd;if(od||(od=0),this.openNode(rd,sd,od),sd.state=qa.OpenTag,_d=this.indent(rd,sd,od),_d+="<!DOCTYPE "+rd.root().name,rd.pubID&&rd.sysID?_d+=' PUBLIC "'+rd.pubID+'" "'+rd.sysID+'"':rd.sysID&&(_d+=' SYSTEM "'+rd.sysID+'"'),rd.children.length>0){for(_d+=" [",_d+=this.endline(rd,sd,od),sd.state=qa.InsideTag,yd=rd.children,cd=0,ud=yd.length;cd<ud;cd++)ld=yd[cd],_d+=this.writeChildNode(ld,sd,od+1);sd.state=qa.CloseTag,_d+="]"}return sd.state=qa.CloseTag,_d+=sd.spaceBeforeSlash+">",_d+=this.endline(rd,sd,od),sd.state=qa.None,this.closeNode(rd,sd,od),_d},td.prototype.element=function(rd,sd,od){var ld,cd,ud,_d,yd,gd,Ed,Td,Od,Rd,Nd,Id,Md,Ld;od||(od=0),Rd=!1,Nd="",this.openNode(rd,sd,od),sd.state=qa.OpenTag,Nd+=this.indent(rd,sd,od)+"<"+rd.name,Id=rd.attribs;for(Od in Id)ed.call(Id,Od)&&(ld=Id[Od],Nd+=this.attribute(ld,sd,od));if(ud=rd.children.length,_d=ud===0?null:rd.children[0],ud===0||rd.children.every(function(Pd){return(Pd.type===Ra.Text||Pd.type===Ra.Raw)&&Pd.value===""}))sd.allowEmpty?(Nd+=">",sd.state=qa.CloseTag,Nd+="</"+rd.name+">"+this.endline(rd,sd,od)):(sd.state=qa.CloseTag,Nd+=sd.spaceBeforeSlash+"/>"+this.endline(rd,sd,od));else if(sd.pretty&&ud===1&&(_d.type===Ra.Text||_d.type===Ra.Raw)&&_d.value!=null)Nd+=">",sd.state=qa.InsideTag,sd.suppressPrettyCount++,Rd=!0,Nd+=this.writeChildNode(_d,sd,od+1),sd.suppressPrettyCount--,Rd=!1,sd.state=qa.CloseTag,Nd+="</"+rd.name+">"+this.endline(rd,sd,od);else{if(sd.dontPrettyTextNodes){for(Md=rd.children,yd=0,Ed=Md.length;yd<Ed;yd++)if(cd=Md[yd],(cd.type===Ra.Text||cd.type===Ra.Raw)&&cd.value!=null){sd.suppressPrettyCount++,Rd=!0;break}}for(Nd+=">"+this.endline(rd,sd,od),sd.state=qa.InsideTag,Ld=rd.children,gd=0,Td=Ld.length;gd<Td;gd++)cd=Ld[gd],Nd+=this.writeChildNode(cd,sd,od+1);sd.state=qa.CloseTag,Nd+=this.indent(rd,sd,od)+"</"+rd.name+">",Rd&&sd.suppressPrettyCount--,Nd+=this.endline(rd,sd,od),sd.state=qa.None}return this.closeNode(rd,sd,od),Nd},td.prototype.writeChildNode=function(rd,sd,od){switch(rd.type){case Ra.CData:return this.cdata(rd,sd,od);case Ra.Comment:return this.comment(rd,sd,od);case Ra.Element:return this.element(rd,sd,od);case Ra.Raw:return this.raw(rd,sd,od);case Ra.Text:return this.text(rd,sd,od);case Ra.ProcessingInstruction:return this.processingInstruction(rd,sd,od);case Ra.Dummy:return"";case Ra.Declaration:return
` ||gf===" \r "||gf===" "}function Ld(gf){return gf==='"'||gf==="'"}function Pd(gf){return gf===">"||Md(gf)}function qd(gf,_f){return gf.test(_f)}function Yd(gf,_f){return!qd(gf,_f)}var Ud=0;qa.STATE={BEGIN:Ud++,BEGIN_WHITESPACE:Ud++,TEXT:Ud++,TEXT_ENTITY:Ud++,OPEN_WAKA:Ud++,SGML_DECL:Ud++,SGML_DECL_QUOTED:Ud++,DOCTYPE:Ud++,DOCTYPE_QUOTED:Ud++,DOCTYPE_DTD:Ud++,DOCTYPE_DTD_QUOTED:Ud++,COMMENT_STARTING:Ud++,COMMENT:Ud++,COMMENT_ENDING:Ud++,COMMENT_ENDED:Ud++,CDATA:Ud++,CDATA_ENDING:Ud++,CDATA_ENDING_2:Ud++,PROC_INST:Ud++,PROC_INST_BODY:Ud++,PROC_INST_ENDING:Ud++,OPEN_TAG:Ud++,OPEN_TAG_SLASH:Ud++,ATTRIB:Ud++,ATTRIB_NAME:Ud++,ATTRIB_NAME_SAW_WHITE:Ud++,ATTRIB_VALUE:Ud++,ATTRIB_VALUE_QUOTED:Ud++,ATTRIB_VALUE_CLOSED:Ud++,ATTRIB_VALUE_UNQUOTED:Ud++,ATTRIB_VALUE_ENTITY_Q:Ud++,ATTRIB_VALUE_ENTITY_U:Ud++,CLOSE_TAG:Ud++,CLOSE_TAG_SAW_WHITE:Ud++,SCRIPT:Ud++,SCRIPT_ENDING:Ud++},qa.XML_ENTITIES={amp:"&",gt:">",lt:"<",quot:'"',apos:"'"},qa.ENTITIES={amp:"&",gt:">",lt:"<",quot:'"',apos:"'",AElig:198,Aacute:193,Acirc:194,Agrave:192,Aring:197,Atilde:195,Auml:196,Ccedil:199,ETH:208,Eacute:201,Ecirc:202,Egrave:200,Euml:203,Iacute:205,Icirc:206,Igrave:204,Iuml:207,Ntilde:209,Oacute:211,Ocirc:212,Ograve:210,Oslash:216,Otilde:213,Ouml:214,THORN:222,Uacute:218,Ucirc:219,Ugrave:217,Uuml:220,Yacute:221,aacute:225,acirc:226,aelig:230,agrave:224,aring:229,atilde:227,auml:228,ccedil:231,eacute:233,ecirc:234,egrave:232,eth:240,euml:235,iacute:237,icirc:238,igrave:236,iuml:239,ntilde:241,oacute:243,ocirc:244,ograve:242,oslash:248,otilde:245,ouml:246,szlig:223,thorn:254,uacute:250,ucirc:251,ugrave:249,uuml:252,yacute:253,yuml:255,copy:169,reg:174,nbsp:160,iexcl:161,cent:162,pound:163,curren:164,yen:165,brvbar:166,sect:167,uml:168,ordf:170,laquo:171,not:172,shy:173,macr:175,deg:176,plusmn:177,sup1:185,sup2:178,sup3:179,acute:180,micro:181,para:182,middot:183,cedil:184,ordm:186,raquo:187,frac14:188,frac12:189,frac34:190,iquest:191,times:215,divide:247,OElig:338,oelig:339,Scaron:352,scaron:353,Yuml:376,fnof:402,circ:710,tilde:732,Alpha:913,Beta:914,Gamma:915,Delta:916,Epsilon:917,Zeta:918,Eta:919,Theta:920,Iota:921,Kappa:922,Lambda:923,Mu:924,Nu:925,Xi:926,Omicron:927,Pi:928,Rho:929,Sigma:931,Tau:932,Upsilon:933,Phi:934,Chi:935,Psi:936,Omega:937,alpha:945,beta:946,gamma:947,delta:948,epsilon:949,zeta:950,eta:951,theta:952,iota:953,kappa:954,lambda:955,mu:956,nu:957,xi:958,omicron:959,pi:960,rho:961,sigmaf:962,sigma:963,tau:964,upsilon:965,phi:966,chi:967,psi:968,omega:969,thetasym:977,upsih:978,piv:982,ensp:8194,emsp:8195,thinsp:8201,zwnj:8204,zwj:8205,lrm:8206,rlm:8207,ndash:8211,mdash:8212,lsquo:8216,rsquo:8217,sbquo:8218,ldquo:8220,rdquo:8221,bdquo:8222,dagger:8224,Dagger:8225,bull:8226,hellip:8230,permil:8240,prime:8242,Prime:8243,lsaquo:8249,rsaquo:8250,oline:8254,frasl:8260,euro:8364,image:8465,weierp:8472,real:8476,trade:8482,alefsym:8501,larr:8592,uarr:8593,rarr:8594,darr:8595,harr:8596,crarr:8629,lArr:8656,uArr:8657,rArr:8658,dArr:8659,hArr:8660,forall:8704,part:8706,exist:8707,empty:8709,nabla:8711,isin:8712,notin:8713,ni:8715,prod:8719,sum:8721,minus:8722,lowast:8727,radic:8730,prop:8733,infin:8734,ang:8736,and:8743,or:8744,cap:8745,cup:8746,int:8747,there4:8756,sim:8764,cong:8773,asymp:8776,ne:8800,equiv:8801,le:8804,ge:8805,sub:8834,sup:8835,nsub:8836,sube:8838,supe:8839,oplus:8853,otimes:8855,perp:8869,sdot:8901,lceil:8968,rceil:8969,lfloor:8970,rfloor:8971,lang:9001,rang:9002,loz:9674,spades:9824,clubs:9827,hearts:9829,diams:9830},Object.keys(qa.ENTITIES).forEach(function(gf){var _f=qa.ENTITIES[gf], $ f=typeof _f=="number"?String.fromCharCode(_f):_f;qa.ENTITIES[gf]= $ f});for(var Hd in qa.STATE)qa.STATE[qa.STATE[Hd]]=Hd;Ud=qa.STATE;function zd(gf,_f, $ f){gf[_f]&&gf[_f]( $ f)}function Jd(gf,_f, $ f){gf.textNode&&Zd(gf),zd(gf,_f, $ f)}function Zd(gf){gf.textNode=pf(gf.opt,gf.textNode),gf.textNode&&zd(gf,"ontext",gf.textNode),gf.textNode=""}function pf(gf,_f){return gf.trim&&(_f=_f.trim()),gf.normalize&&(_f=_f.replace(/ \s +/g," ")),_f}function Qd(gf,_f){return Zd(gf),gf.trackPosition&&(_f+= `
2024-09-03 08:22:14 +08:00
Line : ` +gf.line+ `
Column : ` +gf.column+ `
2024-09-08 17:22:36 +08:00
Char : ` +gf.c),_f=new Error(_f),gf.error=_f,zd(gf,"onerror",_f),gf}function hf(gf){return gf.sawRoot&&!gf.closedRoot&&mf(gf,"Unclosed root tag"),gf.state!==Ud.BEGIN&&gf.state!==Ud.BEGIN_WHITESPACE&&gf.state!==Ud.TEXT&&Qd(gf,"Unexpected end"),Zd(gf),gf.c="",gf.closed=!0,zd(gf,"onend"),ed.call(gf,gf.strict,gf.opt),gf}function mf(gf,_f){if(typeof gf!="object"||!(gf instanceof ed))throw new Error("bad call to strictFail");gf.strict&&Qd(gf,_f)}function xf(gf){gf.strict||(gf.tagName=gf.tagName[gf.looseCase]());var _f=gf.tags[gf.tags.length-1]||gf, $ f=gf.tag={name:gf.tagName,attributes:{}};gf.opt.xmlns&&( $ f.ns=_f.ns),gf.attribList.length=0,Jd(gf,"onopentagstart", $ f)}function Lf(gf,_f){var $ f=gf.indexOf(":"),Gf= $ f<0?["",gf]:gf.split(":"),dh=Gf[0],zf=Gf[1];return _f&&gf==="xmlns"&&(dh="xmlns",zf=""),{prefix:dh,local:zf}}function Kf(gf){if(gf.strict||(gf.attribName=gf.attribName[gf.looseCase]()),gf.attribList.indexOf(gf.attribName)!==-1||gf.tag.attributes.hasOwnProperty(gf.attribName)){gf.attribName=gf.attribValue="";return}if(gf.opt.xmlns){var _f=Lf(gf.attribName,!0), $ f=_f.prefix,Gf=_f.local;if( $ f==="xmlns")if(Gf==="xml"&&gf.attribValue!==gd)mf(gf,"xml: prefix must be bound to "+gd+ `
Actual : ` +gf.attribValue);else if(Gf==="xmlns"&&gf.attribValue!==Ed)mf(gf,"xmlns: prefix must be bound to "+Ed+ `
Actual : ` +gf.attribValue);else{var dh=gf.tag,zf=gf.tags[gf.tags.length-1]||gf;dh.ns===zf.ns&&(dh.ns=Object.create(zf.ns)),dh.ns[Gf]=gf.attribValue}gf.attribList.push([gf.attribName,gf.attribValue])}else gf.tag.attributes[gf.attribName]=gf.attribValue,Jd(gf,"onattribute",{name:gf.attribName,value:gf.attribValue});gf.attribName=gf.attribValue=""}function Yf(gf,_f){if(gf.opt.xmlns){var $ f=gf.tag,Gf=Lf(gf.tagName); $ f.prefix=Gf.prefix, $ f.local=Gf.local, $ f.uri= $ f.ns[Gf.prefix]||"", $ f.prefix&&! $ f.uri&&(mf(gf,"Unbound namespace prefix: "+JSON.stringify(gf.tagName)), $ f.uri=Gf.prefix);var dh=gf.tags[gf.tags.length-1]||gf; $ f.ns&&dh.ns!== $ f.ns&&Object.keys( $ f.ns).forEach(function(uh){Jd(gf,"onopennamespace",{prefix:uh,uri: $ f.ns[uh]})});for(var zf=0,If=gf.attribList.length;zf<If;zf++){var Jf=gf.attribList[zf],Th=Jf[0],Vf=Jf[1],Ef=Lf(Th,!0),Af=Ef.prefix,Pf=Ef.local,hh=Af===""?"": $ f.ns[Af]||"",Ah={name:Th,value:Vf,prefix:Af,local:Pf,uri:hh};Af&&Af!=="xmlns"&&!hh&&(mf(gf,"Unbound namespace prefix: "+JSON.stringify(Af)),Ah.uri=Af),gf.tag.attributes[Th]=Ah,Jd(gf,"onattribute",Ah)}gf.attribList.length=0}gf.tag.isSelfClosing=!!_f,gf.sawRoot=!0,gf.tags.push(gf.tag),Jd(gf,"onopentag",gf.tag),_f||(!gf.noscript&&gf.tagName.toLowerCase()==="script"?gf.state=Ud.SCRIPT:gf.state=Ud.TEXT,gf.tag=null,gf.tagName=""),gf.attribName=gf.attribValue="",gf.attribList.length=0}function Of(gf){if(!gf.tagName){mf(gf,"Weird empty close tag."),gf.textNode+="</>",gf.state=Ud.TEXT;return}if(gf.script){if(gf.tagName!=="script"){gf.script+="</"+gf.tagName+">",gf.tagName="",gf.state=Ud.SCRIPT;return}Jd(gf,"onscript",gf.script),gf.script=""}var _f=gf.tags.length, $ f=gf.tagName;gf.strict||( $ f= $ f[gf.looseCase]());for(var Gf= $ f;_f--;){var dh=gf.tags[_f];if(dh.name!==Gf)mf(gf,"Unexpected close tag");else break}if(_f<0){mf(gf,"Unmatched closing tag: "+gf.tagName),gf.textNode+="</"+gf.tagName+">",gf.state=Ud.TEXT;return}gf.tagName= $ f;for(var zf=gf.tags.length;zf-- >_f;){var If=gf.tag=gf.tags.pop();gf.tagName=gf.tag.name,Jd(gf,"onclosetag",gf.tagName);var Jf={};for(var Th in If.ns)Jf[Th]=If.ns[Th];var Vf=gf.tags[gf.tags.length-1]||gf;gf.opt.xmlns&&If.ns!==Vf.ns&&Object.keys(If.ns).forEach(function(Ef){var Af=If.ns[Ef];Jd(gf,"onclosenamespace",{prefix:Ef,uri:Af})})}_f===0&&(gf.closedRoot=!0),gf.tagName=gf.attribValue=gf.attribName="",gf.attribList.length=0,gf.state=Ud.TEXT}function Tf(gf){var _f=gf.entity, $ f=_f.toLowerCase(),Gf,dh="";return gf.ENTITIES[_f]?gf.ENTITIES[_f]:gf.ENTITIES[ $ f]?gf.ENTITIES[ $ f]:(_f= $ f,_f.charAt(0)==="#"&&(_f.charAt(1)==="x"?(_f=_f.slice(2),Gf=parseInt(_f,16),dh=Gf.toString(16)):(_f=_f.slice(1),Gf=parseInt(_f,10),dh=Gf.toString(10))),_f=_f.replace(/^0+/,""),isNaN(Gf)||dh.toLowerCase()!==_f?(mf(gf,"Invalid character entity"),"&"+gf.entity+";"):String.fromCodePoint(Gf))}function wf(gf,_f){_f==="<"?(gf.state=Ud.OPEN_WAKA,gf.startTagPosition=gf.position):Md(_f)||(mf(gf,"Non-whitespace before first tag."),gf.textNode=_f,gf.state=Ud.TEXT)}function Wf(gf,_f){var $ f="";return _f<gf.length&&( $ f=gf.charAt(_f)), $ f}function Uf(gf){var _f=this;if(this.error)throw this.error;if(_f.closed)return Qd(_f,"Cannot write after close. Assign an onready handler.");if(gf===null)return hf(_f);typeof gf=="object"&&(gf=gf.toString());for(var $ f=0,Gf="";Gf=Wf(gf, $ f++),_f.c=Gf,!!Gf;)switch(_f.trackPosition&&(_f.position++,Gf=== `
` ?(_f.line++,_f.column=0):_f.column++),_f.state){case Ud.BEGIN:if(_f.state=Ud.BEGIN_WHITESPACE,Gf===" \u FEFF")continue;wf(_f,Gf);continue;case Ud.BEGIN_WHITESPACE:wf(_f,Gf);continue;case Ud.TEXT:if(_f.sawRoot&&!_f.closedRoot){for(var dh= $ f-1;Gf&&Gf!=="<"&&Gf!=="&";)Gf=Wf(gf, $ f++),Gf&&_f.trackPosition&&(_f.position++,Gf=== `
2024-09-08 19:53:57 +08:00
` ?(_f.line++,_f.column=0):_f.column++);_f.textNode+=gf.substring(dh, $ f-1)}Gf==="<"&&!(_f.sawRoot&&_f.closedRoot&&!_f.strict)?(_f.state=Ud.OPEN_WAKA,_f.startTagPosition=_f.position):(!Md(Gf)&&(!_f.sawRoot||_f.closedRoot)&&mf(_f,"Text data outside of root node."),Gf==="&"?_f.state=Ud.TEXT_ENTITY:_f.textNode+=Gf);continue;case Ud.SCRIPT:Gf==="<"?_f.state=Ud.SCRIPT_ENDING:_f.script+=Gf;continue;case Ud.SCRIPT_ENDING:Gf==="/"?_f.state=Ud.CLOSE_TAG:(_f.script+="<"+Gf,_f.state=Ud.SCRIPT);continue;case Ud.OPEN_WAKA:if(Gf==="!")_f.state=Ud.SGML_DECL,_f.sgmlDecl="";else if(!Md(Gf))if(qd(Od,Gf))_f.state=Ud.OPEN_TAG,_f.tagName=Gf;else if(Gf==="/")_f.state=Ud.CLOSE_TAG,_f.tagName="";else if(Gf==="?")_f.state=Ud.PROC_INST,_f.procInstName=_f.procInstBody="";else{if(mf(_f,"Unencoded <"),_f.startTagPosition+1<_f.position){var zf=_f.position-_f.startTagPosition;Gf=new Array(zf).join(" ")+Gf}_f.textNode+="<"+Gf,_f.state=Ud.TEXT}continue;case Ud.SGML_DECL:if(_f.sgmlDecl+Gf==="--"){_f.state=Ud.COMMENT,_f.comment="",_f.sgmlDecl="";continue}_f.doctype&&_f.doctype!==!0&&_f.sgmlDecl?(_f.state=Ud.DOCTYPE_DTD,_f.doctype+="<!"+_f.sgmlDecl+Gf,_f.sgmlDecl=""):(_f.sgmlDecl+Gf).toUpperCase()===_d?(Jd(_f,"onopencdata"),_f.state=Ud.CDATA,_f.sgmlDecl="",_f.cdata=""):(_f.sgmlDecl+Gf).toUpperCase()===yd?(_f.state=Ud.DOCTYPE,(_f.doctype||_f.sawRoot)&&mf(_f,"Inappropriately located doctype declaration"),_f.doctype="",_f.sgmlDecl=""):Gf===">"?(Jd(_f,"onsgmldeclaration",_f.sgmlDecl),_f.sgmlDecl="",_f.state=Ud.TEXT):(Ld(Gf)&&(_f.state=Ud.SGML_DECL_QUOTED),_f.sgmlDecl+=Gf);continue;case Ud.SGML_DECL_QUOTED:Gf===_f.q&&(_f.state=Ud.SGML_DECL,_f.q=""),_f.sgmlDecl+=Gf;continue;case Ud.DOCTYPE:Gf===">"?(_f.state=Ud.TEXT,Jd(_f,"ondoctype",_f.doctype),_f.doctype=!0):(_f.doctype+=Gf,Gf==="["?_f.state=Ud.DOCTYPE_DTD:Ld(Gf)&&(_f.state=Ud.DOCTYPE_QUOTED,_f.q=Gf));continue;case Ud.DOCTYPE_QUOTED:_f.doctype+=Gf,Gf===_f.q&&(_f.q="",_f.state=Ud.DOCTYPE);continue;case Ud.DOCTYPE_DTD:Gf==="]"?(_f.doctype+=Gf,_f.state=Ud.DOCTYPE):Gf==="<"?(_f.state=Ud.OPEN_WAKA,_f.startTagPosition=_f.position):Ld(Gf)?(_f.doctype+=Gf,_f.state=Ud.DOCTYPE_DTD_QUOTED,_f.q=Gf):_f.doctype+=Gf;continue;case Ud.DOCTYPE_DTD_QUOTED:_f.doctype+=Gf,Gf===_f.q&&(_f.state=Ud.DOCTYPE_DTD,_f.q="");continue;case Ud.COMMENT:Gf==="-"?_f.state=Ud.COMMENT_ENDING:_f.comment+=Gf;continue;case Ud.COMMENT_ENDING:Gf==="-"?(_f.state=Ud.COMMENT_ENDED,_f.comment=pf(_f.opt,_f.comment),_f.comment&&Jd(_f,"oncomment",_f.comment),_f.comment=""):(_f.comment+="-"+Gf,_f.state=Ud.COMMENT);continue;case Ud.COMMENT_ENDED:Gf!==">"?(mf(_f,"Malformed comment"),_f.comment+="--"+Gf,_f.state=Ud.COMMENT):_f.doctype&&_f.doctype!==!0?_f.state=Ud.DOCTYPE_DTD:_f.state=Ud.TEXT;continue;case Ud.CDATA:Gf==="]"?_f.state=Ud.CDATA_ENDING:_f.cdata+=Gf;continue;case Ud.CDATA_ENDING:Gf==="]"?_f.state=Ud.CDATA_ENDING_2:(_f.cdata+="]"+Gf,_f.state=Ud.CDATA);continue;case Ud.CDATA_ENDING_2:Gf===">"?(_f.cdata&&Jd(_f,"oncdata",_f.cdata),Jd(_f,"onclosecdata"),_f.cdata="",_f.state=Ud.TEXT):Gf==="]"?_f.cdata+="]":(_f.cdata+="]]"+Gf,_f.state=Ud.CDATA);continue;case Ud.PROC_INST:Gf==="?"?_f.state=Ud.PROC_INST_ENDING:Md(Gf)?_f.state=Ud.PROC_INST_BODY:_f.procInstName+=Gf;continue;case Ud.PROC_INST_BODY:if(!_f.procInstBody&&Md(Gf))continue;Gf==="?"?_f.state=Ud.PROC_INST_ENDING:_f.procInstBody+=Gf;continue;case Ud.PROC_INST_ENDING:Gf===">"?(Jd(_f,"onprocessinginstruction",{name:_f.procInstName,body:_f.procInstBody}),_f.procInstName=_f.procInstBody="",_f.state=Ud.TEXT):(_f.procInstBody+="?"+Gf,_f.state=Ud.PROC_INST_BODY);continue;case Ud.OPEN_TAG:qd(Rd,Gf)?_f.tagName+=Gf:(xf(_f),Gf===">"?Yf(_f):Gf==="/"?_f.state=Ud.OPEN_TAG_SLASH:(Md(Gf)||mf(_f,"Invalid character in tag name"),_f.state=Ud.ATTRIB));continue;case Ud.OPEN_TAG_SLASH:Gf===">"?(Yf(_f,!0),Of(_f)):(mf(_f,"Forward-slash in opening tag not followed by >"),_f.state=Ud.ATTRIB);continue;case Ud.ATTRIB:if(Md(Gf))continue;Gf===">"?Yf(_f):Gf==="/"?_f.state=Ud.OPEN_TAG_SLASH:qd(Od,Gf)?(_f.attribName=Gf,_f.attribValue="",_f.state=Ud.ATTRIB_NAME):mf(_f,"Invalid attribute name");continue;case Ud.ATTRIB_NAME:Gf==="="?_f.state
2024-09-03 08:22:14 +08:00
` &&Ra[rd]!==" \r ";rd++)ld+=Ra[rd];if(ld=ld.trim(),ld[ld.length-1]==="/"&&(ld=ld.substring(0,ld.length-1),rd--),!validateTagName(ld)){let _d;return ld.trim().length===0?_d="Invalid space after '<'.":_d="Tag '"+ld+"' is an invalid name.",getErrorObject("InvalidTag",_d,getLineNumberForPosition(Ra,rd))}const cd=readAttributeStr(Ra,rd);if(cd===!1)return getErrorObject("InvalidAttr","Attributes for '"+ld+"' have open quote.",getLineNumberForPosition(Ra,rd));let ud=cd.value;if(rd=cd.index,ud[ud.length-1]==="/"){const _d=rd-ud.length;ud=ud.substring(0,ud.length-1);const yd=validateAttributeString(ud,qa);if(yd===!0)ed=!0;else return getErrorObject(yd.err.code,yd.err.msg,getLineNumberForPosition(Ra,_d+yd.err.line))}else if(od)if(cd.tagClosed){if(ud.trim().length>0)return getErrorObject("InvalidTag","Closing tag '"+ld+"' can't have attributes or invalid starting.",getLineNumberForPosition(Ra,sd));if(Ja.length===0)return getErrorObject("InvalidTag","Closing tag '"+ld+"' has not been opened.",getLineNumberForPosition(Ra,sd));{const _d=Ja.pop();if(ld!==_d.tagName){let yd=getLineNumberForPosition(Ra,_d.tagStartPos);return getErrorObject("InvalidTag","Expected closing tag '"+_d.tagName+"' (opened in line "+yd.line+", col "+yd.col+") instead of closing tag '"+ld+"'.",getLineNumberForPosition(Ra,sd))}Ja.length==0&&(td=!0)}}else return getErrorObject("InvalidTag","Closing tag '"+ld+"' doesn't have proper closing.",getLineNumberForPosition(Ra,rd));else{const _d=validateAttributeString(ud,qa);if(_d!==!0)return getErrorObject(_d.err.code,_d.err.msg,getLineNumberForPosition(Ra,rd-ud.length+_d.err.line));if(td===!0)return getErrorObject("InvalidXml","Multiple possible root nodes found.",getLineNumberForPosition(Ra,rd));qa.unpairedTags.indexOf(ld)!==-1||Ja.push({tagName:ld,tagStartPos:sd}),ed=!0}for(rd++;rd<Ra.length;rd++)if(Ra[rd]==="<")if(Ra[rd+1]==="!"){rd++,rd=readCommentAndCDATA(Ra,rd);continue}else if(Ra[rd+1]==="?"){if(rd=readPI(Ra,++rd),rd.err)return rd}else break;else if(Ra[rd]==="&"){const _d=validateAmpersand(Ra,rd);if(_d==-1)return getErrorObject("InvalidChar","char '&' is not expected.",getLineNumberForPosition(Ra,rd));rd=_d}else if(td===!0&&!isWhiteSpace(Ra[rd]))return getErrorObject("InvalidXml","Extra text at the end",getLineNumberForPosition(Ra,rd));Ra[rd]==="<"&&rd--}}else{if(isWhiteSpace(Ra[rd]))continue;return getErrorObject("InvalidChar","char '"+Ra[rd]+"' is not expected.",getLineNumberForPosition(Ra,rd))}if(ed){if(Ja.length==1)return getErrorObject("InvalidTag","Unclosed tag '"+Ja[0].tagName+"'.",getLineNumberForPosition(Ra,Ja[0].tagStartPos));if(Ja.length>0)return getErrorObject("InvalidXml","Invalid '"+JSON.stringify(Ja.map(rd=>rd.tagName),null,4).replace(/ \r ? \n /g,"")+"' found.",{line:1,col:1})}else return getErrorObject("InvalidXml","Start tag expected.",1);return!0};function isWhiteSpace(Ra){return Ra===" "||Ra===" "||Ra=== `
2024-09-04 14:19:22 +08:00
` ||Ra===" \r "}function readPI(Ra,qa){const Ja=qa;for(;qa<Ra.length;qa++)if(Ra[qa]=="?"||Ra[qa]==" "){const ed=Ra.substr(Ja,qa-Ja);if(qa>5&&ed==="xml")return getErrorObject("InvalidXml","XML declaration allowed only at the start of the document.",getLineNumberForPosition(Ra,qa));if(Ra[qa]=="?"&&Ra[qa+1]==">"){qa++;break}else continue}return qa}function readCommentAndCDATA(Ra,qa){if(Ra.length>qa+5&&Ra[qa+1]==="-"&&Ra[qa+2]==="-"){for(qa+=3;qa<Ra.length;qa++)if(Ra[qa]==="-"&&Ra[qa+1]==="-"&&Ra[qa+2]===">"){qa+=2;break}}else if(Ra.length>qa+8&&Ra[qa+1]==="D"&&Ra[qa+2]==="O"&&Ra[qa+3]==="C"&&Ra[qa+4]==="T"&&Ra[qa+5]==="Y"&&Ra[qa+6]==="P"&&Ra[qa+7]==="E"){let Ja=1;for(qa+=8;qa<Ra.length;qa++)if(Ra[qa]==="<")Ja++;else if(Ra[qa]===">"&&(Ja--,Ja===0))break}else if(Ra.length>qa+9&&Ra[qa+1]==="["&&Ra[qa+2]==="C"&&Ra[qa+3]==="D"&&Ra[qa+4]==="A"&&Ra[qa+5]==="T"&&Ra[qa+6]==="A"&&Ra[qa+7]==="["){for(qa+=8;qa<Ra.length;qa++)if(Ra[qa]==="]"&&Ra[qa+1]==="]"&&Ra[qa+2]===">"){qa+=2;break}}return qa}const doubleQuote='"',singleQuote="'";function readAttributeStr(Ra,qa){let Ja="",ed="",td=!1;for(;qa<Ra.length;qa++){if(Ra[qa]===doubleQuote||Ra[qa]===singleQuote)ed===""?ed=Ra[qa]:ed!==Ra[qa]||(ed="");else if(Ra[qa]===">"&&ed===""){td=!0;break}Ja+=Ra[qa]}return ed!==""?!1:{value:Ja,index:qa,tagClosed:td}}const validAttrStrRegxp=new RegExp( ` ( \ \ s * ) ( [ ^ \ \ s = ] + ) ( \ \ s *= ) ? ( \ \ s * ( [ '"])(([\\s\\S])*?)\\5)?`,"g");function validateAttributeString(Ra,qa){const Ja=util$3.getAllMatches(Ra,validAttrStrRegxp),ed={};for(let td=0;td<Ja.length;td++){if(Ja[td][1].length===0)return getErrorObject("InvalidAttr","Attribute ' "+Ja[td][2]+" ' has no space in starting.",getPositionFromMatch(Ja[td]));if(Ja[td][3]!==void 0&&Ja[td][4]===void 0)return getErrorObject("InvalidAttr","Attribute ' "+Ja[td][2]+" ' is without value.",getPositionFromMatch(Ja[td]));if(Ja[td][3]===void 0&&!qa.allowBooleanAttributes)return getErrorObject("InvalidAttr","boolean attribute ' "+Ja[td][2]+" ' is not allowed.",getPositionFromMatch(Ja[td]));const rd=Ja[td][2];if(!validateAttrName(rd))return getErrorObject("InvalidAttr","Attribute ' "+rd+" ' is an invalid name.",getPositionFromMatch(Ja[td]));if(!ed.hasOwnProperty(rd))ed[rd]=1;else return getErrorObject("InvalidAttr","Attribute ' "+rd+" ' is repeated . ",getPositionFromMatch(Ja[td]))}return!0}function validateNumberAmpersand(Ra,qa){let Ja=/\d/;for(Ra[qa]===" x "&&(qa++,Ja=/[\da-fA-F]/);qa<Ra.length;qa++){if(Ra[qa]===" ; ")return qa;if(!Ra[qa].match(Ja))break}return-1}function validateAmpersand(Ra,qa){if(qa++,Ra[qa]===" ; ")return-1;if(Ra[qa]===" # ")return qa++,validateNumberAmpersand(Ra,qa);let Ja=0;for(;qa<Ra.length;qa++,Ja++)if(!(Ra[qa].match(/\w/)&&Ja<20)){if(Ra[qa]===" ; ")break;return-1}return qa}function getErrorObject(Ra,qa,Ja){return{err:{code:Ra,msg:qa,line:Ja.line||Ja,col:Ja.col}}}function validateAttrName(Ra){return util$3.isName(Ra)}function validateTagName(Ra){return util$3.isName(Ra)}function getLineNumberForPosition(Ra,qa){const Ja=Ra.substring(0,qa).split(/\r?\n/);return{line:Ja.length,col:Ja[Ja.length-1].length+1}}function getPositionFromMatch(Ra){return Ra.startIndex+Ra[1].length}var OptionsBuilder={};const defaultOptions$1={preserveOrder:!1,attributeNamePrefix:" @ _ ",attributesGroupName:!1,textNodeName:" # text ",ignoreAttributes:!0,removeNSPrefix:!1,allowBooleanAttributes:!1,parseTagValue:!0,parseAttributeValue:!1,trimValues:!0,cdataPropName:!1,numberParseOptions:{hex:!0,leadingZeros:!0,eNotation:!0},tagValueProcessor:function(Ra,qa){return qa},attributeValueProcessor:function(Ra,qa){return qa},stopNodes:[],alwaysCreateTextNode:!1,isArray:()=>!1,commentPropName:!1,unpairedTags:[],processEntities:!0,htmlEntities:!1,ignoreDeclaration:!1,ignorePiTags:!1,transformTagName:!1,transformAttributeName:!1,updateTag:function(Ra,qa,Ja){return Ra}},buildOptions$1=function(Ra){return Object.assign({},defaultOptions$1,Ra)};OptionsBuilder.buildOptions=buildOptions$1;OptionsBuilder.defaultOptions=defaultOptions$1;class XmlNode{constructor(qa){this.tagname=qa,this.child=[],this[" : @ "]={}}add(qa,Ja){qa===" _ _proto _ _ "&&(qa=" # _ _proto _ _ " ) , this . child . push ( { [ qa ] : Ja } ) } addChild ( qa )
2024-09-08 17:22:36 +08:00
` );const qa=new xmlNode("!xml");let Ja=qa,ed="",td="";for(let rd=0;rd<Ra.length;rd++)if(Ra[rd]==="<")if(Ra[rd+1]==="/"){const od=findClosingIndex(Ra,">",rd,"Closing Tag is not closed.");let ld=Ra.substring(rd+2,od).trim();if(this.options.removeNSPrefix){const _d=ld.indexOf(":");_d!==-1&&(ld=ld.substr(_d+1))}this.options.transformTagName&&(ld=this.options.transformTagName(ld)),Ja&&(ed=this.saveTextToParentTag(ed,Ja,td));const cd=td.substring(td.lastIndexOf(".")+1);if(ld&&this.options.unpairedTags.indexOf(ld)!==-1)throw new Error( ` Unpaired tag can not be used as closing tag : < /${ld}>`);let ud=0;cd&&this.options.unpairedTags.indexOf(cd)!==-1?(ud=td.lastIndexOf(".",td.lastIndexOf(".")-1),this.tagsNodeStack.pop()):ud=td.lastIndexOf("."),td=td.substring(0,ud),Ja=this.tagsNodeStack.pop(),ed="",rd=od}else if(Ra[rd+1]==="?"){let od=readTagExp(Ra,rd,!1,"?>");if(!od)throw new Error("Pi Tag is not closed.");if(ed=this.saveTextToParentTag(ed,Ja,td),!(this.options.ignoreDeclaration&&od.tagName==="?xml"||this.options.ignorePiTags)){const ld=new xmlNode(od.tagName);ld.add(this.options.textNodeName,""),od.tagName!==od.tagExp&&od.attrExpPresent&&(ld[":@"]=this.buildAttributesMap(od.tagExp,td,od.tagName)),this.addChild(Ja,ld,td)}rd=od.closeIndex+1}else if(Ra.substr(rd+1,3)==="!--"){const od=findClosingIndex(Ra,"-->",rd+4,"Comment is not closed.");if(this.options.commentPropName){const ld=Ra.substring(rd+4,od-2);ed=this.saveTextToParentTag(ed,Ja,td),Ja.add(this.options.commentPropName,[{[this.options.textNodeName]:ld}])}rd=od}else if(Ra.substr(rd+1,2)==="!D"){const od=readDocType(Ra,rd);this.docTypeEntities=od.entities,rd=od.i}else if(Ra.substr(rd+1,2)==="!["){const od=findClosingIndex(Ra,"]]>",rd,"CDATA is not closed.")-2,ld=Ra.substring(rd+9,od);ed=this.saveTextToParentTag(ed,Ja,td);let cd=this.parseTextData(ld,Ja.tagname,td,!0,!1,!0,!0);cd==null&&(cd=""),this.options.cdataPropName?Ja.add(this.options.cdataPropName,[{[this.options.textNodeName]:ld}]):Ja.add(this.options.textNodeName,cd),rd=od+2}else{let od=readTagExp(Ra,rd,this.options.removeNSPrefix),ld=od.tagName;const cd=od.rawTagName;let ud=od.tagExp,_d=od.attrExpPresent,yd=od.closeIndex;this.options.transformTagName&&(ld=this.options.transformTagName(ld)),Ja&&ed&&Ja.tagname!=="!xml"&&(ed=this.saveTextToParentTag(ed,Ja,td,!1));const gd=Ja;if(gd&&this.options.unpairedTags.indexOf(gd.tagname)!==-1&&(Ja=this.tagsNodeStack.pop(),td=td.substring(0,td.lastIndexOf("."))),ld!==qa.tagname&&(td+=td?"."+ld:ld),this.isItStopNode(this.options.stopNodes,td,ld)){let Ed="";if(ud.length>0&&ud.lastIndexOf("/ ")===ud.length-1)ld[ld.length-1]===" / "?(ld=ld.substr(0,ld.length-1),td=td.substr(0,td.length-1),ud=ld):ud=ud.substr(0,ud.length-1),rd=od.closeIndex;else if(this.options.unpairedTags.indexOf(ld)!==-1)rd=od.closeIndex;else{const Od=this.readStopNodeData(Ra,cd,yd+1);if(!Od)throw new Error(`Unexpected end of ${cd}`);rd=Od.i,Ed=Od.tagContent}const Td=new xmlNode(ld);ld!==ud&&_d&&(Td[" : @ "]=this.buildAttributesMap(ud,td,ld)),Ed&&(Ed=this.parseTextData(Ed,ld,td,!0,_d,!0,!0)),td=td.substr(0,td.lastIndexOf(" . ")),Td.add(this.options.textNodeName,Ed),this.addChild(Ja,Td,td)}else{if(ud.length>0&&ud.lastIndexOf(" / ")===ud.length-1){ld[ld.length-1]===" / "?(ld=ld.substr(0,ld.length-1),td=td.substr(0,td.length-1),ud=ld):ud=ud.substr(0,ud.length-1),this.options.transformTagName&&(ld=this.options.transformTagName(ld));const Ed=new xmlNode(ld);ld!==ud&&_d&&(Ed[" : @ "]=this.buildAttributesMap(ud,td,ld)),this.addChild(Ja,Ed,td),td=td.substr(0,td.lastIndexOf(" . "))}else{const Ed=new xmlNode(ld);this.tagsNodeStack.push(Ja),ld!==ud&&_d&&(Ed[" : @ "]=this.buildAttributesMap(ud,td,ld)),this.addChild(Ja,Ed,td),Ja=Ed}ed=" ",rd=yd}}else ed+=Ra[rd];return qa.child};function addChild(Ra,qa,Ja){const ed=this.options.updateTag(qa.tagname,Ja,qa[" : @ "]);ed===!1||(typeof ed==" string " && ( qa . tagname = ed ) , Ra . addChild ( qa ) ) } const replaceEntitiesValue$1 = function ( Ra ) { if ( this . options . processEntities ) { for ( let qa in this . docTypeEntities ) { const Ja = this . docTypeEntities [ qa ] ; Ra = Ra . replace ( Ja . regx , Ja . val ) } for ( let qa in this . lastEntities ) { const Ja = this . lastEntit
` ;function toXml(Ra,qa){let Ja="";return qa.format&&qa.indentBy.length>0&&(Ja=EOL),arrToStr(Ra,qa,"",Ja)}function arrToStr(Ra,qa,Ja,ed){let td="",rd=!1;for(let sd=0;sd<Ra.length;sd++){const od=Ra[sd],ld=propName(od);if(ld===void 0)continue;let cd="";if(Ja.length===0?cd=ld:cd= ` $ { Ja } . $ { ld } ` ,ld===qa.textNodeName){let Ed=od[ld];isStopNode(cd,qa)||(Ed=qa.tagValueProcessor(ld,Ed),Ed=replaceEntitiesValue(Ed,qa)),rd&&(td+=ed),td+=Ed,rd=!1;continue}else if(ld===qa.cdataPropName){rd&&(td+=ed),td+= ` < ! [ CDATA [ $ { od [ ld ] [ 0 ] [ qa . textNodeName ] } ] ] > ` ,rd=!1;continue}else if(ld===qa.commentPropName){td+=ed+ ` <!-- $ { od [ ld ] [ 0 ] [ qa . textNodeName ] } -- > ` ,rd=!0;continue}else if(ld[0]==="?"){const Ed=attr_to_str(od[":@"],qa),Td=ld==="?xml"?"":ed;let Od=od[ld][0][qa.textNodeName];Od=Od.length!==0?" "+Od:"",td+=Td+ ` < $ { ld } $ { Od } $ { Ed } ? > ` ,rd=!0;continue}let ud=ed;ud!==""&&(ud+=qa.indentBy);const _d=attr_to_str(od[":@"],qa),yd=ed+ ` < $ { ld } $ { _d } ` ,gd=arrToStr(od[ld],qa,cd,ud);qa.unpairedTags.indexOf(ld)!==-1?qa.suppressUnpairedNode?td+=yd+">":td+=yd+"/>":(!gd||gd.length===0)&&qa.suppressEmptyNode?td+=yd+"/>":gd&&gd.endsWith(">")?td+=yd+ ` > $ { gd } $ { ed } < /${ld}>`:(td+=yd+">",gd&&ed!==""&&(gd.includes("/ > ")||gd.includes(" < /"))?td+=ed+qa.indentBy+gd+ed:td+=gd,td+=`</ $ { ld } > ` ),rd=!0}return td}function propName(Ra){const qa=Object.keys(Ra);for(let Ja=0;Ja<qa.length;Ja++){const ed=qa[Ja];if(Ra.hasOwnProperty(ed)&&ed!==":@")return ed}}function attr_to_str(Ra,qa){let Ja="";if(Ra&&!qa.ignoreAttributes)for(let ed in Ra){if(!Ra.hasOwnProperty(ed))continue;let td=qa.attributeValueProcessor(ed,Ra[ed]);td=replaceEntitiesValue(td,qa),td===!0&&qa.suppressBooleanAttributes?Ja+= ` $ { ed . substr ( qa . attributeNamePrefix . length ) } ` :Ja+= ` $ { ed . substr ( qa . attributeNamePrefix . length ) } = "${td}" ` }return Ja}function isStopNode(Ra,qa){Ra=Ra.substr(0,Ra.length-qa.textNodeName.length-1);let Ja=Ra.substr(Ra.lastIndexOf(".")+1);for(let ed in qa.stopNodes)if(qa.stopNodes[ed]===Ra||qa.stopNodes[ed]==="*."+Ja)return!0;return!1}function replaceEntitiesValue(Ra,qa){if(Ra&&Ra.length>0&&qa.processEntities)for(let Ja=0;Ja<qa.entities.length;Ja++){const ed=qa.entities[Ja];Ra=Ra.replace(ed.regex,ed.val)}return Ra}var orderedJs2Xml=toXml;const buildFromOrderedJs=orderedJs2Xml,getIgnoreAttributesFn=ignoreAttributes,defaultOptions={attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,cdataPropName:!1,format:!1,indentBy:" ",suppressEmptyNode:!1,suppressUnpairedNode:!0,suppressBooleanAttributes:!0,tagValueProcessor:function(Ra,qa){return qa},attributeValueProcessor:function(Ra,qa){return qa},preserveOrder:!1,commentPropName:!1,unpairedTags:[],entities:[{regex:new RegExp("&","g"),val:"&"},{regex:new RegExp(">","g"),val:">"},{regex:new RegExp("<","g"),val:"<"},{regex:new RegExp("'","g"),val:"'"},{regex:new RegExp('"',"g"),val:"""}],processEntities:!0,stopNodes:[],oneListGroup:!1};function Builder(Ra){this.options=Object.assign({},defaultOptions,Ra),this.options.ignoreAttributes===!0||this.options.attributesGroupName?this.isAttribute=function(){return!1}:(this.ignoreAttributesFn=getIgnoreAttributesFn(this.options.ignoreAttributes),this.attrPrefixLen=this.options.attributeNamePrefix.length,this.isAttribute=isAttribute),this.processTextOrObjNode=processTextOrObjNode,this.options.format?(this.indentate=indentate,this.tagEndChar= ` >
2024-08-27 22:31:52 +08:00
` ,this.newLine= `
2024-09-08 17:22:36 +08:00
` ):(this.indentate=function(){return""},this.tagEndChar=">",this.newLine="")}Builder.prototype.build=function(Ra){return this.options.preserveOrder?buildFromOrderedJs(Ra,this.options):(Array.isArray(Ra)&&this.options.arrayNodeName&&this.options.arrayNodeName.length>1&&(Ra={[this.options.arrayNodeName]:Ra}),this.j2x(Ra,0,[]).val)};Builder.prototype.j2x=function(Ra,qa,Ja){let ed="",td="";const rd=Ja.join(".");for(let sd in Ra)if(Object.prototype.hasOwnProperty.call(Ra,sd))if(typeof Ra[sd]>"u")this.isAttribute(sd)&&(td+="");else if(Ra[sd]===null)this.isAttribute(sd)?td+="":sd[0]==="?"?td+=this.indentate(qa)+"<"+sd+"?"+this.tagEndChar:td+=this.indentate(qa)+"<"+sd+"/"+this.tagEndChar;else if(Ra[sd]instanceof Date)td+=this.buildTextValNode(Ra[sd],sd,"",qa);else if(typeof Ra[sd]!="object"){const od=this.isAttribute(sd);if(od&&!this.ignoreAttributesFn(od,rd))ed+=this.buildAttrPairStr(od,""+Ra[sd]);else if(!od)if(sd===this.options.textNodeName){let ld=this.options.tagValueProcessor(sd,""+Ra[sd]);td+=this.replaceEntitiesValue(ld)}else td+=this.buildTextValNode(Ra[sd],sd,"",qa)}else if(Array.isArray(Ra[sd])){const od=Ra[sd].length;let ld="",cd="";for(let ud=0;ud<od;ud++){const _d=Ra[sd][ud];if(!(typeof _d>"u"))if(_d===null)sd[0]==="?"?td+=this.indentate(qa)+"<"+sd+"?"+this.tagEndChar:td+=this.indentate(qa)+"<"+sd+"/"+this.tagEndChar;else if(typeof _d=="object")if(this.options.oneListGroup){const yd=this.j2x(_d,qa+1,Ja.concat(sd));ld+=yd.val,this.options.attributesGroupName&&_d.hasOwnProperty(this.options.attributesGroupName)&&(cd+=yd.attrStr)}else ld+=this.processTextOrObjNode(_d,sd,qa,Ja);else if(this.options.oneListGroup){let yd=this.options.tagValueProcessor(sd,_d);yd=this.replaceEntitiesValue(yd),ld+=yd}else ld+=this.buildTextValNode(_d,sd,"",qa)}this.options.oneListGroup&&(ld=this.buildObjectNode(ld,sd,cd,qa)),td+=ld}else if(this.options.attributesGroupName&&sd===this.options.attributesGroupName){const od=Object.keys(Ra[sd]),ld=od.length;for(let cd=0;cd<ld;cd++)ed+=this.buildAttrPairStr(od[cd],""+Ra[sd][od[cd]])}else td+=this.processTextOrObjNode(Ra[sd],sd,qa,Ja);return{attrStr:ed,val:td}};Builder.prototype.buildAttrPairStr=function(Ra,qa){return qa=this.options.attributeValueProcessor(Ra,""+qa),qa=this.replaceEntitiesValue(qa),this.options.suppressBooleanAttributes&&qa==="true"?" "+Ra:" "+Ra+'="'+qa+'"'};function processTextOrObjNode(Ra,qa,Ja,ed){const td=this.j2x(Ra,Ja+1,ed.concat(qa));return Ra[this.options.textNodeName]!==void 0&&Object.keys(Ra).length===1?this.buildTextValNode(Ra[this.options.textNodeName],qa,td.attrStr,Ja):this.buildObjectNode(td.val,qa,td.attrStr,Ja)}Builder.prototype.buildObjectNode=function(Ra,qa,Ja,ed){if(Ra==="")return qa[0]==="?"?this.indentate(ed)+"<"+qa+Ja+"?"+this.tagEndChar:this.indentate(ed)+"<"+qa+Ja+this.closeTag(qa)+this.tagEndChar;{let td="</"+qa+this.tagEndChar,rd="";return qa[0]==="?"&&(rd="?",td=""),(Ja||Ja==="")&&Ra.indexOf("<")===-1?this.indentate(ed)+"<"+qa+Ja+rd+">"+Ra+td:this.options.commentPropName!==!1&&qa===this.options.commentPropName&&rd.length===0?this.indentate(ed)+ ` <!-- $ { Ra } -- > ` +this.newLine:this.indentate(ed)+"<"+qa+Ja+rd+this.tagEndChar+Ra+this.indentate(ed)+td}};Builder.prototype.closeTag=function(Ra){let qa="";return this.options.unpairedTags.indexOf(Ra)!==-1?this.options.suppressUnpairedNode||(qa="/"):this.options.suppressEmptyNode?qa="/":qa= ` > < /${Ra}`,qa};Builder.prototype.buildTextValNode=function(Ra,qa,Ja,ed){if(this.options.cdataPropName!==!1&&qa===this.options.cdataPropName)return this.indentate(ed)+`<![CDATA[${Ra}]]>`+this.newLine;if(this.options.commentPropName!==!1&&qa===this.options.commentPropName)return this.indentate(ed)+`<!--${Ra}-->`+this.newLine;if(qa[0]==="?")return this.indentate(ed)+"<"+qa+Ja+"?"+this.tagEndChar;{let td=this.options.tagValueProcessor(qa,Ra);return td=this.replaceEntitiesValue(td),td===""?this.indentate(ed)+"<"+qa+Ja+this.closeTag(qa)+this.tagEndChar:this.indentate(ed)+"<"+qa+Ja+">"+td+"</ " + qa + this . tagEndChar } } ; Builder . prototype . replaceEntitiesValue = function ( Ra ) { if ( Ra && Ra . length > 0 && this . options . processEntities ) for ( let qa = 0 ; qa < this . op
2024-08-27 22:31:52 +08:00
* mime - db
* Copyright ( c ) 2014 Jonathan Ong
* Copyright ( c ) 2015 - 2022 Douglas Christopher Wilson
* MIT Licensed
* /var mimeDb=require$$0;/ * !
* mime - types
* Copyright ( c ) 2014 Jonathan Ong
* Copyright ( c ) 2015 Douglas Christopher Wilson
* MIT Licensed
2024-09-08 19:53:57 +08:00
* /(function(Ra){var qa=mimeDb,Ja=pathBrowserify.extname,ed=/ ^ \ s * ( [ ^ ; \ s ] * ) ( ? : ; | \ s | $ ) / , td = /^text\//i ; Ra . charset = rd , Ra . charsets = { lookup : rd } , Ra . contentType = sd , Ra . extension = od , Ra . extensions = Object . create ( null ) , Ra . lookup = ld , Ra . types = Object . create ( null ) , cd ( Ra . extensions , Ra . types ) ; function rd ( ud ) { if ( ! ud || typeof ud != "string" ) return ! 1 ; var _d = ed . exec ( ud ) , yd = _d && qa [ _d [ 1 ] . toLowerCase ( ) ] ; return yd && yd . charset ? yd . charset : _d && td . test ( _d [ 1 ] ) ? "UTF-8" : ! 1 } function sd ( ud ) { if ( ! ud || typeof ud != "string" ) return ! 1 ; var _d = ud . indexOf ( "/" ) === - 1 ? Ra . lookup ( ud ) : ud ; if ( ! _d ) return ! 1 ; if ( _d . indexOf ( "charset" ) === - 1 ) { var yd = Ra . charset ( _d ) ; yd && ( _d += "; charset=" + yd . toLowerCase ( ) ) } return _d } function od ( ud ) { if ( ! ud || typeof ud != "string" ) return ! 1 ; var _d = ed . exec ( ud ) , yd = _d && Ra . extensions [ _d [ 1 ] . toLowerCase ( ) ] ; return ! yd || ! yd . length ? ! 1 : yd [ 0 ] } function ld ( ud ) { if ( ! ud || typeof ud != "string" ) return ! 1 ; var _d = Ja ( "x." + ud ) . toLowerCase ( ) . substr ( 1 ) ; return _d && Ra . types [ _d ] || ! 1 } function cd ( ud , _d ) { var yd = [ "nginx" , "apache" , void 0 , "iana" ] ; Object . keys ( qa ) . forEach ( function ( Ed ) { var Td = qa [ Ed ] , Od = Td . extensions ; if ( ! ( ! Od || ! Od . length ) ) { ud [ Ed ] = Od ; for ( var Rd = 0 ; Rd < Od . length ; Rd ++ ) { var Nd = Od [ Rd ] ; if ( _d [ Nd ] ) { var Id = yd . indexOf ( qa [ _d [ Nd ] ] . source ) , Md = yd . indexOf ( Td . source ) ; if ( _d [ Nd ] !== "application/octet-stream" && ( Id > Md || Id === Md && _d [ Nd ] . substr ( 0 , 12 ) === "application/" ) ) continue } _d [ Nd ] = Ed } } } ) } } ) ( mimeTypes$1 ) ; let ENCRYPTION _TYPES = function ( Ra ) { return Ra . SSEC = "SSE-C" , Ra . KMS = "KMS" , Ra } ( { } ) , RETENTION _MODES = function ( Ra ) { return Ra . GOVERNANCE = "GOVERNANCE" , Ra . COMPLIANCE = "COMPLIANCE" , Ra } ( { } ) , RETENTION _VALIDITY _UNITS = function ( Ra ) { return Ra . DAYS = "Days" , Ra . YEARS = "Years" , Ra } ( { } ) , LEGAL _HOLD _STATUS = function ( Ra ) { return Ra . ENABLED = "ON" , Ra . DISABLED = "OFF" , Ra } ( { } ) ; const MetaDataHeaderPrefix = "x-amz-meta-" ; function uriEscape ( Ra ) { return Ra . split ( "" ) . reduce ( ( qa , Ja ) => { const ed = Buffer$2 . from ( Ja ) ; if ( ed . length === 1 && ( "A" <= Ja && Ja <= "Z" || "a" <= Ja && Ja <= "z" || "0" <= Ja && Ja <= "9" || Ja === "_" || Ja === "." || Ja === "~" || Ja === "-" ) ) return qa = qa + Ja , qa ; for ( const td of ed ) qa = qa + "%" + td . toString ( 16 ) . toUpperCase ( ) ; return qa } , "" ) } function uriResourceEscape ( Ra ) { return uriEscape ( Ra ) . replace ( /%2F/g , "/" ) } function getScope ( Ra , qa , Ja = "s3" ) { return ` ${ makeDateShort ( qa ) } / ${ Ra } / ${ Ja } /aws4_request ` } function isAmazonEndpoint ( Ra ) { return Ra === "s3.amazonaws.com" || Ra === "s3.cn-north-1.amazonaws.com.cn" } function isVirtualHostStyle ( Ra , qa , Ja , ed ) { return qa === "https:" && Ja . includes ( "." ) ? ! 1 : isAmazonEndpoint ( Ra ) || ! ed } function isValidIP ( Ra ) { return ipaddr . isValid ( Ra ) } function isValidEndpoint ( Ra ) { return isValidDomain ( Ra ) || isValidIP ( Ra ) } function isValidDomain ( Ra ) { if ( ! isString$1 ( Ra ) || Ra . length === 0 || Ra . length > 255 || Ra [ 0 ] === "-" || Ra . slice ( - 1 ) === "-" || Ra [ 0 ] === "_" || Ra . slice ( - 1 ) === "_" || Ra [ 0 ] === "." ) return ! 1 ; const qa = "`~!@#$%^&*()+={}[]|\\\"';:><?/" ; for ( const Ja of qa ) if ( Ra . includes ( Ja ) ) return ! 1 ; return ! 0 } function probeContentType ( Ra ) { let qa = mimeTypes$1 . lookup ( Ra ) ; return qa || ( qa = "application/octet-stream" ) , qa } function isValidPort ( Ra ) { return isNumber$2 ( Ra ) ? 0 <= Ra && Ra <= 65535 : ! 1 } function isValidBucketName ( Ra ) { return ! isString$1 ( Ra ) || Ra . length < 3 || Ra . length > 63 || Ra . includes ( ".." ) || /[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+/ . test ( Ra ) ? ! 1 : ! ! /^[a-z0-9][a-z0-9.-]+[a-z0-9]$/ . test ( Ra ) } function isValidObjectName ( Ra ) { return isValidPrefix ( Ra ) ? Ra . length !== 0 : ! 1 } function isValidPrefix ( Ra ) { return ! ( ! isString$1 ( Ra ) || Ra . length > 1024 ) } function isNumber$2 ( Ra ) { return typeof Ra == "number" } function isFunction$1 ( Ra ) { return typeof Ra == "function" } function isString$1 ( Ra ) { return typeof Ra == "string" } function isObject$1 ( Ra ) { return typeof Ra == "object" && Ra !== null } function isReadableStream$1 ( Ra ) { return isObject$1 ( Ra ) && isFunction$1 ( Ra . _read ) } function isBoolean$1 ( Ra ) { return typeof Ra == "boolean" } function isEmpty ( Ra ) { return _ . isEmpty ( Ra ) } function isEmptyObject ( Ra ) { return Object . values ( Ra ) . filter ( qa => qa !== void 0 ) . length !== 0 } function isDefined ( Ra ) { return Ra != null } function isValidDate ( Ra ) { return Ra instanceof Date && ! isNaN ( Ra ) } function makeDateLong ( Ra ) { Ra = Ra || new Date ; const qa = Ra . toISOString ( ) ; return qa . slice ( 0 , 4 ) + qa . slice ( 5 , 7 ) + qa . slice ( 8 , 13 ) + qa . slice ( 14 , 16 ) + qa . slice ( 17 , 19 ) + "Z" } function makeDateShort ( Ra ) { Ra = Ra || new Date ; const qa = Ra . toISOString ( ) ; return qa . slice ( 0 , 4 ) + qa . sl
2024-08-27 22:31:52 +08:00
` )+ `
2024-08-30 15:19:18 +08:00
` ,ed.join(";").toLowerCase(),td].join( `
` )}function getCredential(Ra,qa,Ja,ed="s3"){if(!isString $ 1(Ra))throw new TypeError('accessKey should be of type "string"');if(!isString $ 1(qa))throw new TypeError('region should be of type "string"');if(!isObject $ 1(Ja))throw new TypeError('requestDate should be of type "object"');return ` $ { Ra } / $ { getScope ( qa , Ja , ed ) } ` }function getSignedHeaders(Ra){if(!isObject $ 1(Ra))throw new TypeError('request should be of type "object"');const qa=["authorization","content-length","content-type","user-agent"];return Object.keys(Ra).filter(Ja=>!qa.includes(Ja)).sort()}function getSigningKey(Ra,qa,Ja,ed="s3"){if(!isObject $ 1(Ra))throw new TypeError('date should be of type "object"');if(!isString $ 1(qa))throw new TypeError('region should be of type "string"');if(!isString $ 1(Ja))throw new TypeError('secretKey should be of type "string"');const td=makeDateShort(Ra);return(void 0)("sha256",(void 0)("sha256",(void 0)("sha256",(void 0)("sha256","AWS4"+Ja).update(td).digest()).update(qa).digest()).update(ed).digest()).update("aws4_request").digest()}function getStringToSign(Ra,qa,Ja,ed="s3"){if(!isString $ 1(Ra))throw new TypeError('canonicalRequest should be of type "string"');if(!isObject $ 1(qa))throw new TypeError('requestDate should be of type "object"');if(!isString $ 1(Ja))throw new TypeError('region should be of type "string"');const td=(void 0)("sha256").update(Ra).digest("hex"),rd=getScope(Ja,qa,ed);return[signV4Algorithm,makeDateLong(qa),rd,td].join( `
2024-09-08 19:53:57 +08:00
` )}function postPresignSignatureV4(Ra,qa,Ja,ed){if(!isString $ 1(Ra))throw new TypeError('region should be of type "string"');if(!isObject $ 1(qa))throw new TypeError('date should be of type "object"');if(!isString $ 1(Ja))throw new TypeError('secretKey should be of type "string"');if(!isString $ 1(ed))throw new TypeError('policyBase64 should be of type "string"');return(void 0)("sha256",getSigningKey(qa,Ra,Ja)).update(ed).digest("hex").toLowerCase()}function signV4(Ra,qa,Ja,ed,td,rd,sd="s3"){if(!isObject $ 1(Ra))throw new TypeError('request should be of type "object"');if(!isString $ 1(qa))throw new TypeError('accessKey should be of type "string"');if(!isString $ 1(Ja))throw new TypeError('secretKey should be of type "string"');if(!isString $ 1(ed))throw new TypeError('region should be of type "string"');if(!qa)throw new AccessKeyRequiredError("accessKey is required for signing");if(!Ja)throw new SecretKeyRequiredError("secretKey is required for signing");const od=getSignedHeaders(Ra.headers),ld=getCanonicalRequest(Ra.method,Ra.path,Ra.headers,od,rd),cd=sd||"s3",ud=getStringToSign(ld,td,ed,cd),_d=getSigningKey(td,ed,Ja,cd),yd=getCredential(qa,ed,td,cd),gd=(void 0)("sha256",_d).update(ud).digest("hex").toLowerCase();return ` $ { signV4Algorithm } Credential = $ { yd } , SignedHeaders = $ { od . join ( ";" ) . toLowerCase ( ) } , Signature = $ { gd } ` }function presignSignatureV4(Ra,qa,Ja,ed,td,rd,sd){if(!isObject $ 1(Ra))throw new TypeError('request should be of type "object"');if(!isString $ 1(qa))throw new TypeError('accessKey should be of type "string"');if(!isString $ 1(Ja))throw new TypeError('secretKey should be of type "string"');if(!isString $ 1(td))throw new TypeError('region should be of type "string"');if(!qa)throw new AccessKeyRequiredError("accessKey is required for presigning");if(!Ja)throw new SecretKeyRequiredError("secretKey is required for presigning");if(!isNumber $ 2(sd))throw new TypeError('expires should be of type "number"');if(sd<1)throw new ExpiresParamError("expires param cannot be less than 1 seconds");if(sd>604800)throw new ExpiresParamError("expires param cannot be greater than 7 days");const od=makeDateLong(rd),ld=getSignedHeaders(Ra.headers),cd=getCredential(qa,td,rd),ud="UNSIGNED-PAYLOAD",_d=[];_d.push( ` X - Amz - Algorithm = $ { signV4Algorithm } ` ),_d.push( ` X - Amz - Credential = $ { uriEscape ( cd ) } ` ),_d.push( ` X - Amz - Date = $ { od } ` ),_d.push( ` X - Amz - Expires = $ { sd } ` ),_d.push( ` X - Amz - SignedHeaders = $ { uriEscape ( ld . join ( ";" ) . toLowerCase ( ) ) } ` ),ed&&_d.push( ` X - Amz - Security - Token = $ { uriEscape ( ed ) } ` );const yd=Ra.path.split("?")[0];let gd=Ra.path.split("?")[1];gd?gd=gd+"&"+_d.join("&"):gd=_d.join("&");const Ed=yd+"?"+gd,Td=getCanonicalRequest(Ra.method,Ed,Ra.headers,ld,ud),Od=getStringToSign(Td,rd,td),Nd=(void 0)("sha256",getSigningKey(rd,td,Ja)).update(Od).digest("hex").toLowerCase();return Ra.protocol+"//"+Ra.headers.host+Ed+ ` & X - Amz - Signature = $ { Nd } ` }async function readAsBuffer(Ra){return new Promise((qa,Ja)=>{const ed=[];Ra.on("data",td=>ed.push(td)).on("error",td=>Ja(td)).on("end",()=>qa(Buffer $ 2.concat(ed)))})}async function readAsString(Ra){return(await readAsBuffer(Ra)).toString()}async function drainResponse(Ra){return new Promise((qa,Ja)=>{Ra.on("data",()=>{}).on("error",ed=>Ja(ed)).on("end",()=>qa())})}function parseBucketRegion(Ra){return parseXml(Ra).LocationConstraint}const fxp=new fxp $ 2.XMLParser;function parseError(Ra,qa){let Ja={};const ed=fxp.parse(Ra);ed.Error&&(Ja=ed.Error);const td=new S3Error;return Object.entries(Ja).forEach(([rd,sd])=>{td[rd.toLowerCase()]=sd}),Object.entries(qa).forEach(([rd,sd])=>{td[rd]=sd}),td}async function parseResponseError(Ra){const qa=Ra.statusCode;let Ja,ed;qa===301?(Ja="MovedPermanently",ed="Moved Permanently"):qa===307?(Ja="TemporaryRedirect",ed="Are you using the correct endpoint URL?"):qa===403?(Ja="AccessDenied",ed="Valid and authorized credentials required"):qa===404?(Ja="NotFound",ed="Not Found"):qa===405||qa===501?(Ja="MethodNotAllowed",ed="Method Not Allowed"):(Ja="UnknownError",ed= ` $ { qa } ` );const td={};td.amzRequestid=Ra.headers["x-amz-request-id"],td.amzId2=Ra.headers["x-amz-id-2"],td.amzBucketRegion=Ra.headers["x-amz-bucket
2024-08-30 15:19:18 +08:00
` )}),td.write( `
` )};if(td.write( ` REQUEST : $ { qa . method } $ { qa . path }
` ),rd(qa.headers),Ja&&(this.logStream.write( ` RESPONSE : $ { Ja . statusCode }
` ),rd(Ja.headers)),ed){td.write( ` ERROR BODY :
2024-09-03 08:22:14 +08:00
` );const sd=JSON.stringify(ed,null," ");td.write( ` $ { sd }
2024-09-08 19:53:57 +08:00
` )}}traceOn(qa){qa||(qa=define_process_default $ 3.stdout),this.logStream=qa}traceOff(){this.logStream=void 0}async makeRequestAsync(qa,Ja="",ed=[200],td=""){if(!isObject $ 1(qa))throw new TypeError('options should be of type "object"');if(!isString $ 1(Ja)&&!isObject $ 1(Ja))throw new TypeError('payload should be of type "string" or "Buffer"');if(ed.forEach(sd=>{if(!isNumber $ 2(sd))throw new TypeError('statusCode should be of type "number"')}),!isString $ 1(td))throw new TypeError('region should be of type "string"');qa.headers||(qa.headers={}),(qa.method==="POST"||qa.method==="PUT"||qa.method==="DELETE")&&(qa.headers["content-length"]=Ja.length.toString());const rd=this.enableSHA256?toSha256(Ja):"";return this.makeRequestStreamAsync(qa,Ja,rd,ed,td)}async makeRequestAsyncOmit(qa,Ja="",ed=[200],td=""){const rd=await this.makeRequestAsync(qa,Ja,ed,td);return await drainResponse(rd),rd}async makeRequestStreamAsync(qa,Ja,ed,td,rd){if(!isObject $ 1(qa))throw new TypeError('options should be of type "object"');if(!(Buffer $ 2.isBuffer(Ja)||typeof Ja=="string"||isReadableStream $ 1(Ja)))throw new InvalidArgumentError( ` stream should be a Buffer , string or readable Stream , got $ { typeof Ja } instead ` );if(!isString $ 1(ed))throw new TypeError('sha256sum should be of type "string"');if(td.forEach(ld=>{if(!isNumber $ 2(ld))throw new TypeError('statusCode should be of type "number"')}),!isString $ 1(rd))throw new TypeError('region should be of type "string"');if(!this.enableSHA256&&ed.length!==0)throw new InvalidArgumentError("sha256sum expected to be empty for anonymous or https requests");if(this.enableSHA256&&ed.length!==64)throw new InvalidArgumentError( ` Invalid sha256sum : $ { ed } ` );await this.checkAndRefreshCreds(),rd=rd||await this.getBucketRegionAsync(qa.bucketName);const sd=this.getRequestOptions({...qa,region:rd});if(!this.anonymous){this.enableSHA256||(ed="UNSIGNED-PAYLOAD");const ld=new Date;sd.headers["x-amz-date"]=makeDateLong(ld),sd.headers["x-amz-content-sha256"]=ed,this.sessionToken&&(sd.headers["x-amz-security-token"]=this.sessionToken),sd.headers.authorization=signV4(sd,this.accessKey,this.secretKey,rd,ld,ed)}const od=await request $ 1(this.transport,sd,Ja);if(!od.statusCode)throw new Error("BUG: response doesn't have a statusCode");if(!td.includes(od.statusCode)){delete this.regionMap[qa.bucketName];const ld=await parseResponseError(od);throw this.logHTTP(sd,od,ld),ld}return this.logHTTP(sd,od),od}async getBucketRegionAsync(qa){if(!isValidBucketName(qa))throw new InvalidBucketNameError( ` Invalid bucket name : $ { qa } ` );if(this.region)return this.region;const Ja=this.regionMap[qa];if(Ja)return Ja;const ed=async cd=>{const ud=await readAsString(cd),_d=parseBucketRegion(ud)||DEFAULT_REGION;return this.regionMap[qa]=_d,_d},td="GET",rd="location",sd=this.pathStyle&&!isBrowser_1;let od;try{const cd=await this.makeRequestAsync({method:td,bucketName:qa,query:rd,pathStyle:sd},"",[200],DEFAULT_REGION);return ed(cd)}catch(cd){if(cd.name!=="AuthorizationHeaderMalformed"||(od=cd.Region,!od))throw cd}const ld=await this.makeRequestAsync({method:td,bucketName:qa,query:rd,pathStyle:sd},"",[200],od);return await ed(ld)}makeRequest(qa,Ja="",ed=[200],td="",rd,sd){let od;rd?od=this.makeRequestAsync(qa,Ja,ed,td):od=this.makeRequestAsyncOmit(qa,Ja,ed,td),od.then(ld=>sd(null,ld),ld=>{sd(ld)})}makeRequestStream(qa,Ja,ed,td,rd,sd,od){(async()=>{const cd=await this.makeRequestStreamAsync(qa,Ja,ed,td,rd);return sd||await drainResponse(cd),cd})().then(cd=>od(null,cd),cd=>od(cd))}getBucketRegion(qa,Ja){return this.getBucketRegionAsync(qa).then(ed=>Ja(null,ed),ed=>Ja(ed))}async removeBucket(qa){if(!isValidBucketName(qa))throw new InvalidBucketNameError("Invalid bucket name: "+qa);await this.makeRequestAsyncOmit({method:"DELETE",bucketName:qa},"",[204]),delete this.regionMap[qa]}async statObject(qa,Ja,ed={}){if(!isValidBucketName(qa))throw new InvalidBucketNameError("Invalid bucket name: "+qa);if(!isValidObjectName(Ja))throw new InvalidObjectNameError( ` Invalid object name : $ { Ja } ` );if(!isObject $ 1(ed))throw new InvalidArgumentError('statOpts should be of type "object"');const
2024-09-08 17:22:36 +08:00
` ).forEach(function(Rd){if(Rd){var Nd=Rd.indexOf(":"),Id=Rd.substr(0,Nd).trim().toLowerCase(),Md=Rd.substr(Nd+1).trim();Td[Id]=Md}}),{error:yd,statusCode:gd.status,statusMessage:gd.statusText,headers:Td,body:Ed}},cd=function(yd,gd){return!gd&&gd==="text"?yd.responseText:yd.response},ud=function(yd,gd){var Ed=(yd.method||"GET").toUpperCase(),Td=yd.url;if(yd.qs){var Od=od(yd.qs);Od&&(Td+=(Td.indexOf("?")===-1?"?":"&")+Od)}var Rd=new XMLHttpRequest;if(Rd.open(Ed,Td,!0),Rd.responseType=yd.dataType||"text",yd.xhrFields)for(var Nd in yd.xhrFields)Rd[Nd]=yd.xhrFields[Nd];var Id=yd.headers;if(Id)for(var Md in Id)Id.hasOwnProperty(Md)&&Md.toLowerCase()!=="content-length"&&Md.toLowerCase()!=="user-agent"&&Md.toLowerCase()!=="origin"&&Md.toLowerCase()!=="host"&&Rd.setRequestHeader(Md,Id[Md]);return yd.onProgress&&Rd.upload&&(Rd.upload.onprogress=yd.onProgress),yd.onDownloadProgress&&(Rd.onprogress=yd.onDownloadProgress),yd.timeout&&(Rd.timeout=yd.timeout),Rd.ontimeout=function(Ld){var Pd=new Error("timeout");gd(ld(Pd,Rd))},Rd.onload=function(){gd(ld(null,Rd,cd(Rd,yd.dataType)))},Rd.onerror=function(Ld){var Pd=cd(Rd,yd.dataType);if(Pd)gd(ld(null,Rd,Pd));else{var qd=Rd.statusText;!qd&&Rd.status===0&&(qd=new Error("CORS blocked or network error")),gd(ld(qd,Rd,Pd))}},Rd.send(yd.body||""),Rd};Ja.exports=ud},"./node_modules/@babel/runtime/helpers/classCallCheck.js":function(Ja,ed){function td(rd,sd){if(!(rd instanceof sd))throw new TypeError("Cannot call a class as a function")}Ja.exports=td,Ja.exports.__esModule=!0,Ja.exports.default=Ja.exports},"./node_modules/@babel/runtime/helpers/createClass.js":function(Ja,ed,td){var rd=td("./node_modules/@babel/runtime/helpers/toPropertyKey.js");function sd(ld,cd){for(var ud=0;ud<cd.length;ud++){var _d=cd[ud];_d.enumerable=_d.enumerable||!1,_d.configurable=!0,"value"in _d&&(_d.writable=!0),Object.defineProperty(ld,rd(_d.key),_d)}}function od(ld,cd,ud){return cd&&sd(ld.prototype,cd),ud&&sd(ld,ud),Object.defineProperty(ld,"prototype",{writable:!1}),ld}Ja.exports=od,Ja.exports.__esModule=!0,Ja.exports.default=Ja.exports},"./node_modules/@babel/runtime/helpers/toPrimitive.js":function(Ja,ed,td){var rd=td("./node_modules/@babel/runtime/helpers/typeof.js").default;function sd(od,ld){if(rd(od)!=="object"||od===null)return od;var cd=od[Symbol.toPrimitive];if(cd!==void 0){var ud=cd.call(od,ld||"default");if(rd(ud)!=="object")return ud;throw new TypeError("@@toPrimitive must return a primitive value.")}return(ld==="string"?String:Number)(od)}Ja.exports=sd,Ja.exports.__esModule=!0,Ja.exports.default=Ja.exports},"./node_modules/@babel/runtime/helpers/toPropertyKey.js":function(Ja,ed,td){var rd=td("./node_modules/@babel/runtime/helpers/typeof.js").default,sd=td("./node_modules/@babel/runtime/helpers/toPrimitive.js");function od(ld){var cd=sd(ld,"string");return rd(cd)==="symbol"?cd:String(cd)}Ja.exports=od,Ja.exports.__esModule=!0,Ja.exports.default=Ja.exports},"./node_modules/@babel/runtime/helpers/typeof.js":function(Ja,ed){function td(rd){"@babel/helpers - typeof";return Ja.exports=td=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(sd){return typeof sd}:function(sd){return sd&&typeof Symbol=="function"&&sd.constructor===Symbol&&sd!==Symbol.prototype?"symbol":typeof sd},Ja.exports.__esModule=!0,Ja.exports.default=Ja.exports,td(rd)}Ja.exports=td,Ja.exports.__esModule=!0,Ja.exports.default=Ja.exports},"./node_modules/fast-xml-parser/src/fxp.js":function(Ja,ed,td){const rd=td("./node_modules/fast-xml-parser/src/validator.js"),sd=td("./node_modules/fast-xml-parser/src/xmlparser/XMLParser.js"),od=td("./node_modules/fast-xml-parser/src/xmlbuilder/json2xml.js");Ja.exports={XMLParser:sd,XMLValidator:rd,XMLBuilder:od}},"./node_modules/fast-xml-parser/src/util.js":function(Ja,ed,td){const rd=":A-Za-z_ \\ u00C0- \\ u00D6 \\ u00D8- \\ u00F6 \\ u00F8- \\ u02FF \\ u0370- \\ u037D \\ u037F- \\ u1FFF \\ u200C- \\ u200D \\ u2070- \\ u218F \\ u2C00- \\ u2FEF \\ u3001- \\ uD7FF \\ uF900- \\ uFDCF \\ uFDF0- \\ uFFFD",sd=rd+" \\ -. \\ d \\ u00B7 \\ u0300- \\ u036F \\ u203F- \\ u2040",od="["+rd+"]["+sd+"]*",ld=new RegExp("^"+od+" $ "),cd=function(_d,yd){const gd=[];l
` &&Pd[zd]!==" \r ";zd++)pf+=Pd[zd];if(pf=pf.trim(),pf[pf.length-1]==="/"&&(pf=pf.substring(0,pf.length-1),zd--),!Id(pf)){let mf;return pf.trim().length===0?mf="Invalid space after '<'.":mf="Tag '"+pf+"' is an invalid name.",Rd("InvalidTag",mf,Md(Pd,zd))}const Qd=yd(Pd,zd);if(Qd===!1)return Rd("InvalidAttr","Attributes for '"+pf+"' have open quote.",Md(Pd,zd));let hf=Qd.value;if(zd=Qd.index,hf[hf.length-1]==="/"){const mf=zd-hf.length;hf=hf.substring(0,hf.length-1);const xf=Ed(hf,qd);if(xf===!0)Ud=!0;else return Rd(xf.err.code,xf.err.msg,Md(Pd,mf+xf.err.line))}else if(Zd)if(Qd.tagClosed){if(hf.trim().length>0)return Rd("InvalidTag","Closing tag '"+pf+"' can't have attributes or invalid starting.",Md(Pd,Jd));if(Yd.length===0)return Rd("InvalidTag","Closing tag '"+pf+"' has not been opened.",Md(Pd,Jd));{const mf=Yd.pop();if(pf!==mf.tagName){let xf=Md(Pd,mf.tagStartPos);return Rd("InvalidTag","Expected closing tag '"+mf.tagName+"' (opened in line "+xf.line+", col "+xf.col+") instead of closing tag '"+pf+"'.",Md(Pd,Jd))}Yd.length==0&&(Hd=!0)}}else return Rd("InvalidTag","Closing tag '"+pf+"' doesn't have proper closing.",Md(Pd,zd));else{const mf=Ed(hf,qd);if(mf!==!0)return Rd(mf.err.code,mf.err.msg,Md(Pd,zd-hf.length+mf.err.line));if(Hd===!0)return Rd("InvalidXml","Multiple possible root nodes found.",Md(Pd,zd));qd.unpairedTags.indexOf(pf)!==-1||Yd.push({tagName:pf,tagStartPos:Jd}),Ud=!0}for(zd++;zd<Pd.length;zd++)if(Pd[zd]==="<")if(Pd[zd+1]==="!"){zd++,zd=cd(Pd,zd);continue}else if(Pd[zd+1]==="?"){if(zd=ld(Pd,++zd),zd.err)return zd}else break;else if(Pd[zd]==="&"){const mf=Od(Pd,zd);if(mf==-1)return Rd("InvalidChar","char '&' is not expected.",Md(Pd,zd));zd=mf}else if(Hd===!0&&!od(Pd[zd]))return Rd("InvalidXml","Extra text at the end",Md(Pd,zd));Pd[zd]==="<"&&zd--}}else{if(od(Pd[zd]))continue;return Rd("InvalidChar","char '"+Pd[zd]+"' is not expected.",Md(Pd,zd))}if(Ud){if(Yd.length==1)return Rd("InvalidTag","Unclosed tag '"+Yd[0].tagName+"'.",Md(Pd,Yd[0].tagStartPos));if(Yd.length>0)return Rd("InvalidXml","Invalid '"+JSON.stringify(Yd.map(zd=>zd.tagName),null,4).replace(/ \r ? \n /g,"")+"' found.",{line:1,col:1})}else return Rd("InvalidXml","Start tag expected.",1);return!0};function od(Pd){return Pd===" "||Pd===" "||Pd=== `
` ||Pd===" \r "}function ld(Pd,qd){const Yd=qd;for(;qd<Pd.length;qd++)if(Pd[qd]=="?"||Pd[qd]==" "){const Ud=Pd.substr(Yd,qd-Yd);if(qd>5&&Ud==="xml")return Rd("InvalidXml","XML declaration allowed only at the start of the document.",Md(Pd,qd));if(Pd[qd]=="?"&&Pd[qd+1]==">"){qd++;break}else continue}return qd}function cd(Pd,qd){if(Pd.length>qd+5&&Pd[qd+1]==="-"&&Pd[qd+2]==="-"){for(qd+=3;qd<Pd.length;qd++)if(Pd[qd]==="-"&&Pd[qd+1]==="-"&&Pd[qd+2]===">"){qd+=2;break}}else if(Pd.length>qd+8&&Pd[qd+1]==="D"&&Pd[qd+2]==="O"&&Pd[qd+3]==="C"&&Pd[qd+4]==="T"&&Pd[qd+5]==="Y"&&Pd[qd+6]==="P"&&Pd[qd+7]==="E"){let Yd=1;for(qd+=8;qd<Pd.length;qd++)if(Pd[qd]==="<")Yd++;else if(Pd[qd]===">"&&(Yd--,Yd===0))break}else if(Pd.length>qd+9&&Pd[qd+1]==="["&&Pd[qd+2]==="C"&&Pd[qd+3]==="D"&&Pd[qd+4]==="A"&&Pd[qd+5]==="T"&&Pd[qd+6]==="A"&&Pd[qd+7]==="["){for(qd+=8;qd<Pd.length;qd++)if(Pd[qd]==="]"&&Pd[qd+1]==="]"&&Pd[qd+2]===">"){qd+=2;break}}return qd}const ud='"',_d="'";function yd(Pd,qd){let Yd="",Ud="",Hd=!1;for(;qd<Pd.length;qd++){if(Pd[qd]===ud||Pd[qd]===_d)Ud===""?Ud=Pd[qd]:Ud!==Pd[qd]||(Ud="");else if(Pd[qd]===">"&&Ud===""){Hd=!0;break}Yd+=Pd[qd]}return Ud!==""?!1:{value:Yd,index:qd,tagClosed:Hd}}const gd=new RegExp( ` ( \ \ s * ) ( [ ^ \ \ s = ] + ) ( \ \ s *= ) ? ( \ \ s * ( [ '"])(([\\s\\S])*?)\\5)?`,"g");function Ed(Pd,qd){const Yd=rd.getAllMatches(Pd,gd),Ud={};for(let Hd=0;Hd<Yd.length;Hd++){if(Yd[Hd][1].length===0)return Rd("InvalidAttr","Attribute ' "+Yd[Hd][2]+" ' has no space in starting.",Ld(Yd[Hd]));if(Yd[Hd][3]!==void 0&&Yd[Hd][4]===void 0)return Rd("InvalidAttr","Attribute ' "+Yd[Hd][2]+" ' is without value.",Ld(Yd[Hd]));if(Yd[Hd][3]===void 0&&!qd.allowBooleanAttributes)return Rd("InvalidAttr","boolean attribute ' "+Yd[Hd][2]+" ' is not allowed.",Ld(Yd[Hd]));const zd=Yd[Hd][2];if(!Nd(zd))return Rd("InvalidAttr","Attribute ' "+zd+" ' is an invalid name.",Ld(Yd[Hd]));if(!Ud.hasOwnProperty(zd))Ud[zd]=1;else return Rd("InvalidAttr","Attribute ' "+zd+" ' is repeated.",Ld(Yd[Hd]))}return!0}function Td(Pd,qd){let Yd=/\d/;for(Pd[qd]==="x"&&(qd++,Yd=/[\da-fA-F]/);qd<Pd.length;qd++){if(Pd[qd]===";")return qd;if(!Pd[qd].match(Yd))break}return-1}function Od(Pd,qd){if(qd++,Pd[qd]===";")return-1;if(Pd[qd]==="#")return qd++,Td(Pd,qd);let Yd=0;for(;qd<Pd.length;qd++,Yd++)if(!(Pd[qd].match(/\w/)&&Yd<20)){if(Pd[qd]===";")break;return-1}return qd}function Rd(Pd,qd,Yd){return{err:{code:Pd,msg:qd,line:Yd.line||Yd,col:Yd.col}}}function Nd(Pd){return rd.isName(Pd)}function Id(Pd){return rd.isName(Pd)}function Md(Pd,qd){const Yd=Pd.substring(0,qd).split(/\r?\n/);return{line:Yd.length,col:Yd[Yd.length-1].length+1}}function Ld(Pd){return Pd.startIndex+Pd[1].length}},"./node_modules/fast-xml-parser/src/xmlbuilder/json2xml.js":function(Ja,ed,td){const rd=td("./node_modules/fast-xml-parser/src/xmlbuilder/orderedJs2Xml.js"),sd={attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,cdataPropName:!1,format:!1,indentBy:" ",suppressEmptyNode:!1,suppressUnpairedNode:!0,suppressBooleanAttributes:!0,tagValueProcessor:function(_d,yd){return yd},attributeValueProcessor:function(_d,yd){return yd},preserveOrder:!1,commentPropName:!1,unpairedTags:[],entities:[{regex:new RegExp("&","g"),val:"&"},{regex:new RegExp(">","g"),val:">"},{regex:new RegExp("<","g"),val:"<"},{regex:new RegExp("' "," g "),val:" & apos ; "},{regex:new RegExp('" ' , "g" ) , val : """ } ] , processEntities : ! 0 , stopNodes : [ ] , oneListGroup : ! 1 } ; function od ( _d ) { this . options = Object . assign ( { } , sd , _d ) , this . options . ignoreAttributes || this . options . attributesGroupName ? this . isAttribute = function ( ) { return ! 1 } : ( this . attrPrefixLen = this . options . attributeNamePrefix . length , this . isAttribute = ud ) , this . processTextOrObjNode = ld , this . options . format ? ( this . indentate = cd , this . tagEndChar = ` >
2024-08-27 22:31:52 +08:00
` ,this.newLine= `
2024-09-08 17:22:36 +08:00
` ):(this.indentate=function(){return""},this.tagEndChar=">",this.newLine="")}od.prototype.build=function(_d){return this.options.preserveOrder?rd(_d,this.options):(Array.isArray(_d)&&this.options.arrayNodeName&&this.options.arrayNodeName.length>1&&(_d={[this.options.arrayNodeName]:_d}),this.j2x(_d,0).val)},od.prototype.j2x=function(_d,yd){let gd="",Ed="";for(let Td in _d)if(Object.prototype.hasOwnProperty.call(_d,Td))if(typeof _d[Td]>"u")this.isAttribute(Td)&&(Ed+="");else if(_d[Td]===null)this.isAttribute(Td)?Ed+="":Td[0]==="?"?Ed+=this.indentate(yd)+"<"+Td+"?"+this.tagEndChar:Ed+=this.indentate(yd)+"<"+Td+"/"+this.tagEndChar;else if(_d[Td]instanceof Date)Ed+=this.buildTextValNode(_d[Td],Td,"",yd);else if(typeof _d[Td]!="object"){const Od=this.isAttribute(Td);if(Od)gd+=this.buildAttrPairStr(Od,""+_d[Td]);else if(Td===this.options.textNodeName){let Rd=this.options.tagValueProcessor(Td,""+_d[Td]);Ed+=this.replaceEntitiesValue(Rd)}else Ed+=this.buildTextValNode(_d[Td],Td,"",yd)}else if(Array.isArray(_d[Td])){const Od=_d[Td].length;let Rd="";for(let Nd=0;Nd<Od;Nd++){const Id=_d[Td][Nd];typeof Id>"u"||(Id===null?Td[0]==="?"?Ed+=this.indentate(yd)+"<"+Td+"?"+this.tagEndChar:Ed+=this.indentate(yd)+"<"+Td+"/"+this.tagEndChar:typeof Id=="object"?this.options.oneListGroup?Rd+=this.j2x(Id,yd+1).val:Rd+=this.processTextOrObjNode(Id,Td,yd):Rd+=this.buildTextValNode(Id,Td,"",yd))}this.options.oneListGroup&&(Rd=this.buildObjectNode(Rd,Td,"",yd)),Ed+=Rd}else if(this.options.attributesGroupName&&Td===this.options.attributesGroupName){const Od=Object.keys(_d[Td]),Rd=Od.length;for(let Nd=0;Nd<Rd;Nd++)gd+=this.buildAttrPairStr(Od[Nd],""+_d[Td][Od[Nd]])}else Ed+=this.processTextOrObjNode(_d[Td],Td,yd);return{attrStr:gd,val:Ed}},od.prototype.buildAttrPairStr=function(_d,yd){return yd=this.options.attributeValueProcessor(_d,""+yd),yd=this.replaceEntitiesValue(yd),this.options.suppressBooleanAttributes&&yd==="true"?" "+_d:" "+_d+'="'+yd+'"'};function ld(_d,yd,gd){const Ed=this.j2x(_d,gd+1);return _d[this.options.textNodeName]!==void 0&&Object.keys(_d).length===1?this.buildTextValNode(_d[this.options.textNodeName],yd,Ed.attrStr,gd):this.buildObjectNode(Ed.val,yd,Ed.attrStr,gd)}od.prototype.buildObjectNode=function(_d,yd,gd,Ed){if(_d==="")return yd[0]==="?"?this.indentate(Ed)+"<"+yd+gd+"?"+this.tagEndChar:this.indentate(Ed)+"<"+yd+gd+this.closeTag(yd)+this.tagEndChar;{let Td="</"+yd+this.tagEndChar,Od="";return yd[0]==="?"&&(Od="?",Td=""),(gd||gd==="")&&_d.indexOf("<")===-1?this.indentate(Ed)+"<"+yd+gd+Od+">"+_d+Td:this.options.commentPropName!==!1&&yd===this.options.commentPropName&&Od.length===0?this.indentate(Ed)+ ` <!-- $ { _d } -- > ` +this.newLine:this.indentate(Ed)+"<"+yd+gd+Od+this.tagEndChar+_d+this.indentate(Ed)+Td}},od.prototype.closeTag=function(_d){let yd="";return this.options.unpairedTags.indexOf(_d)!==-1?this.options.suppressUnpairedNode||(yd="/"):this.options.suppressEmptyNode?yd="/":yd= ` > < /${_d}`,yd},od.prototype.buildTextValNode=function(_d,yd,gd,Ed){if(this.options.cdataPropName!==!1&&yd===this.options.cdataPropName)return this.indentate(Ed)+`<![CDATA[${_d}]]>`+this.newLine;if(this.options.commentPropName!==!1&&yd===this.options.commentPropName)return this.indentate(Ed)+`<!--${_d}-->`+this.newLine;if(yd[0]==="?")return this.indentate(Ed)+"<"+yd+gd+"?"+this.tagEndChar;{let Td=this.options.tagValueProcessor(yd,_d);return Td=this.replaceEntitiesValue(Td),Td===""?this.indentate(Ed)+"<"+yd+gd+this.closeTag(yd)+this.tagEndChar:this.indentate(Ed)+"<"+yd+gd+">"+Td+"</ "+yd+this.tagEndChar}},od.prototype.replaceEntitiesValue=function(_d){if(_d&&_d.length>0&&this.options.processEntities)for(let yd=0;yd<this.options.entities.length;yd++){const gd=this.options.entities[yd];_d=_d.replace(gd.regex,gd.val)}return _d};function cd(_d){return this.options.indentBy.repeat(_d)}function ud(_d){return _d.startsWith(this.options.attributeNamePrefix)&&_d!==this.options.textNodeName?_d.substr(this.attrPrefixLen):!1}Ja.exports=od}," . / node _modules / fast - xml - parser / src / xmlbuilder / orderedJs2Xml . js " : function ( Ja , ed ) { const td = `
` ;function rd(_d,yd){let gd="";return yd.format&&yd.indentBy.length>0&&(gd=td),sd(_d,yd,"",gd)}function sd(_d,yd,gd,Ed){let Td="",Od=!1;for(let Rd=0;Rd<_d.length;Rd++){const Nd=_d[Rd],Id=od(Nd);if(Id===void 0)continue;let Md="";if(gd.length===0?Md=Id:Md= ` $ { gd } . $ { Id } ` ,Id===yd.textNodeName){let Ud=Nd[Id];cd(Md,yd)||(Ud=yd.tagValueProcessor(Id,Ud),Ud=ud(Ud,yd)),Od&&(Td+=Ed),Td+=Ud,Od=!1;continue}else if(Id===yd.cdataPropName){Od&&(Td+=Ed),Td+= ` < ! [ CDATA [ $ { Nd [ Id ] [ 0 ] [ yd . textNodeName ] } ] ] > ` ,Od=!1;continue}else if(Id===yd.commentPropName){Td+=Ed+ ` <!-- $ { Nd [ Id ] [ 0 ] [ yd . textNodeName ] } -- > ` ,Od=!0;continue}else if(Id[0]==="?"){const Ud=ld(Nd[":@"],yd),Hd=Id==="?xml"?"":Ed;let zd=Nd[Id][0][yd.textNodeName];zd=zd.length!==0?" "+zd:"",Td+=Hd+ ` < $ { Id } $ { zd } $ { Ud } ? > ` ,Od=!0;continue}let Ld=Ed;Ld!==""&&(Ld+=yd.indentBy);const Pd=ld(Nd[":@"],yd),qd=Ed+ ` < $ { Id } $ { Pd } ` ,Yd=sd(Nd[Id],yd,Md,Ld);yd.unpairedTags.indexOf(Id)!==-1?yd.suppressUnpairedNode?Td+=qd+">":Td+=qd+"/>":(!Yd||Yd.length===0)&&yd.suppressEmptyNode?Td+=qd+"/>":Yd&&Yd.endsWith(">")?Td+=qd+ ` > $ { Yd } $ { Ed } < /${Id}>`:(Td+=qd+">",Yd&&Ed!==""&&(Yd.includes("/ > ")||Yd.includes(" < /"))?Td+=Ed+yd.indentBy+Yd+Ed:Td+=Yd,Td+=`</ $ { Id } > ` ),Od=!0}return Td}function od(_d){const yd=Object.keys(_d);for(let gd=0;gd<yd.length;gd++){const Ed=yd[gd];if(_d.hasOwnProperty(Ed)&&Ed!==":@")return Ed}}function ld(_d,yd){let gd="";if(_d&&!yd.ignoreAttributes)for(let Ed in _d){if(!_d.hasOwnProperty(Ed))continue;let Td=yd.attributeValueProcessor(Ed,_d[Ed]);Td=ud(Td,yd),Td===!0&&yd.suppressBooleanAttributes?gd+= ` $ { Ed . substr ( yd . attributeNamePrefix . length ) } ` :gd+= ` $ { Ed . substr ( yd . attributeNamePrefix . length ) } = "${Td}" ` }return gd}function cd(_d,yd){_d=_d.substr(0,_d.length-yd.textNodeName.length-1);let gd=_d.substr(_d.lastIndexOf(".")+1);for(let Ed in yd.stopNodes)if(yd.stopNodes[Ed]===_d||yd.stopNodes[Ed]==="*."+gd)return!0;return!1}function ud(_d,yd){if(_d&&_d.length>0&&yd.processEntities)for(let gd=0;gd<yd.entities.length;gd++){const Ed=yd.entities[gd];_d=_d.replace(Ed.regex,Ed.val)}return _d}Ja.exports=rd},"./node_modules/fast-xml-parser/src/xmlparser/DocTypeReader.js":function(Ja,ed,td){const rd=td("./node_modules/fast-xml-parser/src/util.js");function sd(Ed,Td){const Od={};if(Ed[Td+3]==="O"&&Ed[Td+4]==="C"&&Ed[Td+5]==="T"&&Ed[Td+6]==="Y"&&Ed[Td+7]==="P"&&Ed[Td+8]==="E"){Td=Td+9;let Rd=1,Nd=!1,Id=!1,Md="";for(;Td<Ed.length;Td++)if(Ed[Td]==="<"&&!Id){if(Nd&&cd(Ed,Td))Td+=7,[entityName,val,Td]=od(Ed,Td+1),val.indexOf("&")===-1&&(Od[gd(entityName)]={regx:RegExp( ` & $ { entityName } ; ` ,"g"),val});else if(Nd&&ud(Ed,Td))Td+=8;else if(Nd&&_d(Ed,Td))Td+=8;else if(Nd&&yd(Ed,Td))Td+=9;else if(ld)Id=!0;else throw new Error("Invalid DOCTYPE");Rd++,Md=""}else if(Ed[Td]===">"){if(Id?Ed[Td-1]==="-"&&Ed[Td-2]==="-"&&(Id=!1,Rd--):Rd--,Rd===0)break}else Ed[Td]==="["?Nd=!0:Md+=Ed[Td];if(Rd!==0)throw new Error("Unclosed DOCTYPE")}else throw new Error("Invalid Tag instead of DOCTYPE");return{entities:Od,i:Td}}function od(Ed,Td){let Od="";for(;Td<Ed.length&&Ed[Td]!=="'"&&Ed[Td]!=='"';Td++)Od+=Ed[Td];if(Od=Od.trim(),Od.indexOf(" ")!==-1)throw new Error("External entites are not supported");const Rd=Ed[Td++];let Nd="";for(;Td<Ed.length&&Ed[Td]!==Rd;Td++)Nd+=Ed[Td];return[Od,Nd,Td]}function ld(Ed,Td){return Ed[Td+1]==="!"&&Ed[Td+2]==="-"&&Ed[Td+3]==="-"}function cd(Ed,Td){return Ed[Td+1]==="!"&&Ed[Td+2]==="E"&&Ed[Td+3]==="N"&&Ed[Td+4]==="T"&&Ed[Td+5]==="I"&&Ed[Td+6]==="T"&&Ed[Td+7]==="Y"}function ud(Ed,Td){return Ed[Td+1]==="!"&&Ed[Td+2]==="E"&&Ed[Td+3]==="L"&&Ed[Td+4]==="E"&&Ed[Td+5]==="M"&&Ed[Td+6]==="E"&&Ed[Td+7]==="N"&&Ed[Td+8]==="T"}function _d(Ed,Td){return Ed[Td+1]==="!"&&Ed[Td+2]==="A"&&Ed[Td+3]==="T"&&Ed[Td+4]==="T"&&Ed[Td+5]==="L"&&Ed[Td+6]==="I"&&Ed[Td+7]==="S"&&Ed[Td+8]==="T"}function yd(Ed,Td){return Ed[Td+1]==="!"&&Ed[Td+2]==="N"&&Ed[Td+3]==="O"&&Ed[Td+4]==="T"&&Ed[Td+5]==="A"&&Ed[Td+6]==="T"&&Ed[Td+7]==="I"&&Ed[Td+8]==="O"&&Ed[Td+9]==="N"}function gd(Ed){if(rd.isName(Ed))return Ed;throw new Error( ` Invalid entity name $ { Ed } ` )}Ja.exports=sd},"./node_modules/fast-xml-parser/src/xmlparser/OptionsBuilder.js":function(Ja,ed){const td={preserveOrd
` );const Hd=new sd("!xml");let zd=Hd,Jd="",Zd="";for(let pf=0;pf<Ud.length;pf++)if(Ud[pf]==="<")if(Ud[pf+1]==="/"){const hf=Ld(Ud,">",pf,"Closing Tag is not closed.");let mf=Ud.substring(pf+2,hf).trim();if(this.options.removeNSPrefix){const Kf=mf.indexOf(":");Kf!==-1&&(mf=mf.substr(Kf+1))}this.options.transformTagName&&(mf=this.options.transformTagName(mf)),zd&&(Jd=this.saveTextToParentTag(Jd,zd,Zd));const xf=Zd.substring(Zd.lastIndexOf(".")+1);if(mf&&this.options.unpairedTags.indexOf(mf)!==-1)throw new Error( ` Unpaired tag can not be used as closing tag : < /${mf}>`);let Lf=0;xf&&this.options.unpairedTags.indexOf(xf)!==-1?(Lf=Zd.lastIndexOf(".",Zd.lastIndexOf(".")-1),this.tagsNodeStack.pop()):Lf=Zd.lastIndexOf("."),Zd=Zd.substring(0,Lf),zd=this.tagsNodeStack.pop(),Jd="",pf=hf}else if(Ud[pf+1]==="?"){let hf=Pd(Ud,pf,!1,"?>");if(!hf)throw new Error("Pi Tag is not closed.");if(Jd=this.saveTextToParentTag(Jd,zd,Zd),!(this.options.ignoreDeclaration&&hf.tagName==="?xml"||this.options.ignorePiTags)){const mf=new sd(hf.tagName);mf.add(this.options.textNodeName,""),hf.tagName!==hf.tagExp&&hf.attrExpPresent&&(mf[":@"]=this.buildAttributesMap(hf.tagExp,Zd,hf.tagName)),this.addChild(zd,mf,Zd)}pf=hf.closeIndex+1}else if(Ud.substr(pf+1,3)==="!--"){const hf=Ld(Ud,"-->",pf+4,"Comment is not closed.");if(this.options.commentPropName){const mf=Ud.substring(pf+4,hf-2);Jd=this.saveTextToParentTag(Jd,zd,Zd),zd.add(this.options.commentPropName,[{[this.options.textNodeName]:mf}])}pf=hf}else if(Ud.substr(pf+1,2)==="!D"){const hf=od(Ud,pf);this.docTypeEntities=hf.entities,pf=hf.i}else if(Ud.substr(pf+1,2)==="!["){const hf=Ld(Ud,"]]>",pf,"CDATA is not closed.")-2,mf=Ud.substring(pf+9,hf);Jd=this.saveTextToParentTag(Jd,zd,Zd);let xf=this.parseTextData(mf,zd.tagname,Zd,!0,!1,!0,!0);xf==null&&(xf=""),this.options.cdataPropName?zd.add(this.options.cdataPropName,[{[this.options.textNodeName]:mf}]):zd.add(this.options.textNodeName,xf),pf=hf+2}else{let hf=Pd(Ud,pf,this.options.removeNSPrefix),mf=hf.tagName;const xf=hf.rawTagName;let Lf=hf.tagExp,Kf=hf.attrExpPresent,Yf=hf.closeIndex;this.options.transformTagName&&(mf=this.options.transformTagName(mf)),zd&&Jd&&zd.tagname!=="!xml"&&(Jd=this.saveTextToParentTag(Jd,zd,Zd,!1));const Of=zd;if(Of&&this.options.unpairedTags.indexOf(Of.tagname)!==-1&&(zd=this.tagsNodeStack.pop(),Zd=Zd.substring(0,Zd.lastIndexOf("."))),mf!==Hd.tagname&&(Zd+=Zd?"."+mf:mf),this.isItStopNode(this.options.stopNodes,Zd,mf)){let Tf="";if(Lf.length>0&&Lf.lastIndexOf("/ ")===Lf.length-1)mf[mf.length-1]===" / "?(mf=mf.substr(0,mf.length-1),Zd=Zd.substr(0,Zd.length-1),Lf=mf):Lf=Lf.substr(0,Lf.length-1),pf=hf.closeIndex;else if(this.options.unpairedTags.indexOf(mf)!==-1)pf=hf.closeIndex;else{const Wf=this.readStopNodeData(Ud,xf,Yf+1);if(!Wf)throw new Error(`Unexpected end of ${xf}`);pf=Wf.i,Tf=Wf.tagContent}const wf=new sd(mf);mf!==Lf&&Kf&&(wf[" : @ "]=this.buildAttributesMap(Lf,Zd,mf)),Tf&&(Tf=this.parseTextData(Tf,mf,Zd,!0,Kf,!0,!0)),Zd=Zd.substr(0,Zd.lastIndexOf(" . ")),wf.add(this.options.textNodeName,Tf),this.addChild(zd,wf,Zd)}else{if(Lf.length>0&&Lf.lastIndexOf(" / ")===Lf.length-1){mf[mf.length-1]===" / "?(mf=mf.substr(0,mf.length-1),Zd=Zd.substr(0,Zd.length-1),Lf=mf):Lf=Lf.substr(0,Lf.length-1),this.options.transformTagName&&(mf=this.options.transformTagName(mf));const Tf=new sd(mf);mf!==Lf&&Kf&&(Tf[" : @ "]=this.buildAttributesMap(Lf,Zd,mf)),this.addChild(zd,Tf,Zd),Zd=Zd.substr(0,Zd.lastIndexOf(" . "))}else{const Tf=new sd(mf);this.tagsNodeStack.push(zd),mf!==Lf&&Kf&&(Tf[" : @ "]=this.buildAttributesMap(Lf,Zd,mf)),this.addChild(zd,Tf,Zd),zd=Tf}Jd=" ",pf=Yf}}else Jd+=Ud[pf];return Hd.child};function Od(Ud,Hd,zd){const Jd=this.options.updateTag(Hd.tagname,zd,Hd[" : @ "]);Jd===!1||(typeof Jd==" string " && ( Hd . tagname = Jd ) , Ud . addChild ( Hd ) ) } const Rd = function ( Ud ) { if ( this . options . processEntities ) { for ( let Hd in this . docTypeEntities ) { const zd = this . docTypeEntities [ Hd ] ; Ud = Ud . replace ( zd . regx , zd . val ) } for ( let Hd in this . lastEntities ) { const zd = this . lastEntities [ Hd ] ; Ud = Ud . replace ( zd . regex , zd . val ) } if ( this . options . htmlEntities ) for ( let Hd in this . htmlEntities ) { const zd = this . htm
In order to be iterable , non - array objects must have a [ Symbol . iterator ] ( ) method . ` )}var qh=!0,Xh=!1,gm;return{s:function(){Zf=Zf.call(Rf)},n:function(){var Vm=Zf.next();return qh=Vm.done,Vm},e:function(Vm){Xh=!0,gm=Vm},f:function(){try{!qh&&Zf.return!=null&&Zf.return()}finally{if(Xh)throw gm}}}}function ld(Rf,Df){if(Rf){if(typeof Rf=="string")return cd(Rf,Df);var Zf=Object.prototype.toString.call(Rf).slice(8,-1);if(Zf==="Object"&&Rf.constructor&&(Zf=Rf.constructor.name),Zf==="Map"||Zf==="Set")return Array.from(Rf);if(Zf==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array $ /.test(Zf))return cd(Rf,Df)}}function cd(Rf,Df){(Df==null||Df>Rf.length)&&(Df=Rf.length);for(var Zf=0,_h=new Array(Df);Zf<Df;Zf++)_h[Zf]=Rf[Zf];return _h}var ud=td("./lib/md5.js"),_d=td("./lib/crypto.js"),yd=td("./node_modules/fast-xml-parser/src/fxp.js"),gd=yd.XMLParser,Ed=yd.XMLBuilder,Td=new gd({ignoreDeclaration:!0,ignoreAttributes:!0,parseTagValue:!1}),Od=new Ed,Rd=td("./lib/base64.js"),Nd=td("./src/tracker.js"),Id=function(Df){var Zf=Td.parse(Df);return Zf},Md=function(Df){var Zf=Od.build(Df);return Zf};function Ld(Rf){return encodeURIComponent(Rf).replace(/!/g,"%21").replace(/'/g,"%27").replace(/ \( /g,"%28").replace(/ \) /g,"%29").replace(/ \* /g,"%2A")}function Pd(Rf,Df){var Zf=[];for(var _h in Rf)Rf.hasOwnProperty(_h)&&Zf.push(Df?Ld(_h).toLowerCase():_h);return Zf.sort(function(Mh,qh){return Mh=Mh.toLowerCase(),qh=qh.toLowerCase(),Mh===qh?0:Mh>qh?1:-1})}var qd=function(Df,Zf){var _h,Mh,qh,Xh=[],gm=Pd(Df);for(_h=0;_h<gm.length;_h++)Mh=gm[_h],qh=Df[Mh]===void 0||Df[Mh]===null?"":""+Df[Mh],Mh=Zf?Ld(Mh).toLowerCase():Ld(Mh),qh=Ld(qh)||"",Xh.push(Mh+"="+qh);return Xh.join("&")},Yd=["cache-control","content-disposition","content-encoding","content-length","content-md5","expect","expires","host","if-match","if-modified-since","if-none-match","if-unmodified-since","origin","range","transfer-encoding","pic-operations"],Ud=function(Df){var Zf={};for(var _h in Df){var Mh=_h.toLowerCase();(Mh.indexOf("x-cos-")>-1||Yd.indexOf(Mh)>-1)&&(Zf[_h]=Df[_h])}return Zf},Hd=function(Df){Df=Df||{};var Zf=Df.SecretId,_h=Df.SecretKey,Mh=Df.KeyTime,qh=(Df.method||Df.Method||"get").toLowerCase(),Xh=Tf(Df.Query||Df.params||{}),gm=Ud(Tf(Df.Headers||Df.headers||{})),om=Df.Key||"",Vm;Df.UseRawKey?Vm=Df.Pathname||Df.pathname||"/"+om:(Vm=Df.Pathname||Df.pathname||om,Vm.indexOf("/")!==0&&(Vm="/"+Vm));var Pm=Df.ForceSignHost!==!1;if(!gm.Host&&!gm.host&&Df.Bucket&&Df.Region&&Pm&&(gm.Host=Df.Bucket+".cos."+Df.Region+".myqcloud.com"),!Zf)throw new Error("missing param SecretId");if(!_h)throw new Error("missing param SecretKey");var Mm=Math.round(Pf(Df.SystemClockOffset)/1e3)-1,Jm=Mm,N_=Df.Expires||Df.expires;N_===void 0?Jm+=900:Jm+=N_*1||0;var I_="sha1",y_=Zf,Xm=Mh||Mm+";"+Jm,L_=Mh||Mm+";"+Jm,w_=Pd(gm,!0).join(";").toLowerCase(),G_=Pd(Xh,!0).join(";").toLowerCase(),J_=_d.HmacSHA1(L_,_h).toString(),R_=[qh,Vm,ih.obj2str(Xh,!0),ih.obj2str(gm,!0),""].join( `
2024-09-07 10:27:05 +08:00
` ),k_=["sha1",Xm,_d.SHA1(R_).toString(),""].join( `
2024-09-08 19:53:57 +08:00
` ),jm=_d.HmacSHA1(k_,J_).toString(),g_=["q-sign-algorithm="+I_,"q-ak="+y_,"q-sign-time="+Xm,"q-key-time="+L_,"q-header-list="+w_,"q-url-param-list="+G_,"q-signature="+jm].join("&");return g_},zd=function(Df,Zf,_h){var Mh=Zf/8,qh=Df.slice(_h,_h+Mh);return new Uint8Array(qh).reverse(),new{8:Uint8Array,16:Uint16Array,32:Uint32Array}[Zf](qh)[0]},Jd=function(Df,Zf,_h,Mh){var qh=Df.slice(Zf,_h),Xh="";return new Uint8Array(qh).forEach(function(gm){Xh+=String.fromCharCode(gm)}),Mh&&(Xh=decodeURIComponent(escape(Xh))),Xh},Zd=function(Df){for(var Zf={},_h=Jd(Df),Mh={records:[]};Df.byteLength;){var qh=zd(Df,32,0),Xh=zd(Df,32,4),gm=qh-Xh-16,om=0,Vm;for(Df=Df.slice(12);om<Xh;){var Pm=zd(Df,8,om),Mm=Jd(Df,om+1,om+1+Pm),Jm=zd(Df,16,om+Pm+2),N_=Jd(Df,om+Pm+4,om+Pm+4+Jm);Zf[Mm]=N_,om+=Pm+4+Jm}if(Zf[":event-type"]==="Records")Vm=Jd(Df,om,om+gm,!0),Mh.records.push(Vm);else if(Zf[":event-type"]==="Stats")Vm=Jd(Df,om,om+gm,!0),Mh.stats=ih.xml2json(Vm).Stats;else if(Zf[":event-type"]==="error"){var I_=Zf[":error-code"],y_=Zf[":error-message"],Xm=new Error(y_);Xm.message=y_,Xm.name=Xm.code=I_,Mh.error=Xm}Df=Df.slice(om+gm+4)}return{payload:Mh.records.join(""),body:_h}},pf=function(Df){var Zf=this.options.CopySourceParser;if(Zf)return Zf(Df);var _h=Df.match(/^([^.]+- \d +) \. cos(v6|-cdc|-cdz|-internal)? \. ([^.]+) \. ((myqcloud \. com)|(tencentcos \. cn)) \/ (.+) $ /);return _h?{Bucket:_h[1],Region:_h[3],Key:_h[7]}:null},Qd=function(){},hf=function(Df){var Zf={};for(var _h in Df)Df.hasOwnProperty(_h)&&Df[_h]!==void 0&&Df[_h]!==null&&(Zf[_h]=Df[_h]);return Zf},mf=function(Df,Zf){var _h,Mh=new FileReader;FileReader.prototype.readAsBinaryString?(_h=FileReader.prototype.readAsBinaryString,Mh.onload=function(){Zf(this.result)}):FileReader.prototype.readAsArrayBuffer?_h=function(Xh){var gm="",om=new FileReader;om.onload=function(Vm){for(var Pm=new Uint8Array(om.result),Mm=Pm.byteLength,Jm=0;Jm<Mm;Jm++)gm+=String.fromCharCode(Pm[Jm]);Zf(gm)},om.readAsArrayBuffer(Xh)}:console.error("FileReader not support readAsBinaryString"),_h.call(Mh,Df)},xf=function(){var Rf=function(_h,Mh){_h=_h.split("."),Mh=Mh.split(".");for(var qh=0;qh<Mh.length;qh++)if(_h[qh]!==Mh[qh])return parseInt(_h[qh])>parseInt(Mh[qh])?1:-1;return 0},Df=function(_h){if(!_h)return!1;var Mh=(_h.match(/Chrome \/ ([. \d ]+)/)||[])[1],qh=(_h.match(/QBCore \/ ([. \d ]+)/)||[])[1],Xh=(_h.match(/QQBrowser \/ ([. \d ]+)/)||[])[1],gm=Mh&&Rf(Mh,"53.0.2785.116")<0&&qh&&Rf(qh,"3.53.991.400")<0&&Xh&&Rf(Xh,"9.0.2524.400")<=0||!1;return gm};return Df(typeof navigator<"u"&&navigator.userAgent)}(),Lf=function(Df,Zf,_h,Mh,qh){var Xh;if(Df.slice?Xh=Df.slice(Zf,_h):Df.mozSlice?Xh=Df.mozSlice(Zf,_h):Df.webkitSlice&&(Xh=Df.webkitSlice(Zf,_h)),Mh&&xf){var gm=new FileReader;gm.onload=function(om){Xh=null,qh(new Blob([gm.result]))},gm.readAsArrayBuffer(Xh)}else qh(Xh)},Kf=function(Df,Zf,_h,Mh){_h=_h||Qd,Df?typeof Zf=="string"?_h(ih.md5(Zf,!0)):Blob&&Zf instanceof Blob?ih.getFileMd5(Zf,function(qh,Xh){_h(Xh)},Mh):_h():_h()},Yf=1024*1024,Of=function(Df,Zf,_h){var Mh=Df.size,qh=0,Xh=ud.getCtx(),gm=function om(Vm){if(Vm>=Mh){var Pm=Xh.digest("hex");Zf(null,Pm);return}var Mm=Math.min(Mh,Vm+Yf);ih.fileSlice(Df,Vm,Mm,!1,function(Jm){mf(Jm,function(N_){Jm=null,Xh=Xh.update(N_,!0),qh+=N_.length,N_=null,_h&&_h({loaded:qh,total:Mh,percent:Math.round(qh/Mh*1e4)/1e4}),om(Vm+Yf)})})};gm(0)};function Tf(Rf){return Gf(Rf,function(Df){return sd(Df)==="object"&&Df!==null?Tf(Df):Df})}function wf(Rf,Df,Zf){return Rf&&Df in Rf?Rf[Df]:Zf}function Wf(Rf,Df){return $ f(Df,function(Zf,_h){Rf[_h]=Df[_h]}),Rf}function Uf(Rf){return Rf instanceof Array}function gf(Rf,Df){for(var Zf=!1,_h=0;_h<Rf.length;_h++)if(Df===Rf[_h]){Zf=!0;break}return Zf}function _f(Rf){return Uf(Rf)?Rf:[Rf]}function $ f(Rf,Df){for(var Zf in Rf)Rf.hasOwnProperty(Zf)&&Df(Rf[Zf],Zf)}function Gf(Rf,Df){var Zf=Uf(Rf)?[]:{};for(var _h in Rf)Rf.hasOwnProperty(_h)&&(Zf[_h]=Df(Rf[_h],_h));return Zf}function dh(Rf,Df){var Zf=Uf(Rf),_h=Zf?[]:{};for(var Mh in Rf)Rf.hasOwnProperty(Mh)&&Df(Rf[Mh],Mh)&&(Zf?_h.push(Rf[Mh]):_h[Mh]=Rf[Mh]);return _h}var zf=function(Df){var Zf,_h,Mh,qh="";for(Zf=0,_h=Df.length/2
2024-09-03 08:22:14 +08:00
` ).forEach(function(sd){td=sd.indexOf(":"),Ja=sd.substring(0,td).trim().toLowerCase(),ed=sd.substring(td+1).trim(),!(!Ja||qa[Ja]&&ignoreDuplicateOf[Ja])&&(Ja==="set-cookie"?qa[Ja]?qa[Ja].push(ed):qa[Ja]=[ed]:qa[Ja]=qa[Ja]?qa[Ja]+", "+ed:ed)}),qa}, $ internals=Symbol("internals");function normalizeHeader(Ra){return Ra&&String(Ra).trim().toLowerCase()}function normalizeValue(Ra){return Ra===!1||Ra==null?Ra:utils $ 1.isArray(Ra)?Ra.map(normalizeValue):String(Ra)}function parseTokens(Ra){const qa=Object.create(null),Ja=/([^ \s ,;=]+) \s *(?:= \s *([^,;]+))?/g;let ed;for(;ed=Ja.exec(Ra);)qa[ed[1]]=ed[2];return qa}const isValidHeaderName=Ra=>/^[-_a-zA-Z0-9^ ` | ~ , ! # $ % & ' * + . ] + $ / . test ( Ra . trim ( ) ) ; function matchHeaderValue ( Ra , qa , Ja , ed , td ) { if ( utils$1 . isFunction ( ed ) ) return ed . call ( this , qa , Ja ) ; if ( td && ( qa = Ja ) , ! ! utils$1 . isString ( qa ) ) { if ( utils$1 . isString ( ed ) ) return qa . indexOf ( ed ) !== - 1 ; if ( utils$1 . isRegExp ( ed ) ) return ed . test ( qa ) } } function formatHeader ( Ra ) { return Ra . trim ( ) . toLowerCase ( ) . replace ( /([a-z\d])(\w*)/g , ( qa , Ja , ed ) => Ja . toUpperCase ( ) + ed ) } function buildAccessors ( Ra , qa ) { const Ja = utils$1 . toCamelCase ( " " + qa ) ; [ "get" , "set" , "has" ] . forEach ( ed => { Object . defineProperty ( Ra , ed + Ja , { value : function ( td , rd , sd ) { return this [ ed ] . call ( this , qa , td , rd , sd ) } , configurable : ! 0 } ) } ) } class AxiosHeaders { constructor ( qa ) { qa && this . set ( qa ) } set ( qa , Ja , ed ) { const td = this ; function rd ( od , ld , cd ) { const ud = normalizeHeader ( ld ) ; if ( ! ud ) throw new Error ( "header name must be a non-empty string" ) ; const _d = utils$1 . findKey ( td , ud ) ; ( ! _d || td [ _d ] === void 0 || cd === ! 0 || cd === void 0 && td [ _d ] !== ! 1 ) && ( td [ _d || ld ] = normalizeValue ( od ) ) } const sd = ( od , ld ) => utils$1 . forEach ( od , ( cd , ud ) => rd ( cd , ud , ld ) ) ; if ( utils$1 . isPlainObject ( qa ) || qa instanceof this . constructor ) sd ( qa , Ja ) ; else if ( utils$1 . isString ( qa ) && ( qa = qa . trim ( ) ) && ! isValidHeaderName ( qa ) ) sd ( parseHeaders ( qa ) , Ja ) ; else if ( utils$1 . isHeaders ( qa ) ) for ( const [ od , ld ] of qa . entries ( ) ) rd ( ld , od , ed ) ; else qa != null && rd ( Ja , qa , ed ) ; return this } get ( qa , Ja ) { if ( qa = normalizeHeader ( qa ) , qa ) { const ed = utils$1 . findKey ( this , qa ) ; if ( ed ) { const td = this [ ed ] ; if ( ! Ja ) return td ; if ( Ja === ! 0 ) return parseTokens ( td ) ; if ( utils$1 . isFunction ( Ja ) ) return Ja . call ( this , td , ed ) ; if ( utils$1 . isRegExp ( Ja ) ) return Ja . exec ( td ) ; throw new TypeError ( "parser must be boolean|regexp|function" ) } } } has ( qa , Ja ) { if ( qa = normalizeHeader ( qa ) , qa ) { const ed = utils$1 . findKey ( this , qa ) ; return ! ! ( ed && this [ ed ] !== void 0 && ( ! Ja || matchHeaderValue ( this , this [ ed ] , ed , Ja ) ) ) } return ! 1 } delete ( qa , Ja ) { const ed = this ; let td = ! 1 ; function rd ( sd ) { if ( sd = normalizeHeader ( sd ) , sd ) { const od = utils$1 . findKey ( ed , sd ) ; od && ( ! Ja || matchHeaderValue ( ed , ed [ od ] , od , Ja ) ) && ( delete ed [ od ] , td = ! 0 ) } } return utils$1 . isArray ( qa ) ? qa . forEach ( rd ) : rd ( qa ) , td } clear ( qa ) { const Ja = Object . keys ( this ) ; let ed = Ja . length , td = ! 1 ; for ( ; ed -- ; ) { const rd = Ja [ ed ] ; ( ! qa || matchHeaderValue ( this , this [ rd ] , rd , qa , ! 0 ) ) && ( delete this [ rd ] , td = ! 0 ) } return td } normalize ( qa ) { const Ja = this , ed = { } ; return utils$1 . forEach ( this , ( td , rd ) => { const sd = utils$1 . findKey ( ed , rd ) ; if ( sd ) { Ja [ sd ] = normalizeValue ( td ) , delete Ja [ rd ] ; return } const od = qa ? formatHeader ( rd ) : String ( rd ) . trim ( ) ; od !== rd && delete Ja [ rd ] , Ja [ od ] = normalizeValue ( td ) , ed [ od ] = ! 0 } ) , this } concat ( ... qa ) { return this . constructor . concat ( this , ... qa ) } toJSON ( qa ) { const Ja = Object . create ( null ) ; return utils$1 . forEach ( this , ( ed , td ) => { ed != null && ed !== ! 1 && ( Ja [ td ] = qa && utils$1 . isArray ( ed ) ? ed . join ( ", " ) : ed ) } ) , Ja } [ Symbol . iterator ] ( ) { return Object . entries ( this . toJSON ( ) ) [ Symbol . iterator ] ( ) } toString ( ) { return Object . entries ( this . toJSON ( ) ) . map ( ( [ qa , Ja ] ) => qa + ": " + Ja ) . join ( `
2024-09-08 17:22:36 +08:00
` )}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(qa){return qa instanceof this?qa:new this(qa)}static concat(qa,...Ja){const ed=new this(qa);return Ja.forEach(td=>ed.set(td)),ed}static accessor(qa){const ed=(this[ $ internals]=this[ $ internals]={accessors:{}}).accessors,td=this.prototype;function rd(sd){const od=normalizeHeader(sd);ed[od]||(buildAccessors(td,sd),ed[od]=!0)}return utils $ 1.isArray(qa)?qa.forEach(rd):rd(qa),this}}AxiosHeaders.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);utils $ 1.reduceDescriptors(AxiosHeaders.prototype,({value:Ra},qa)=>{let Ja=qa[0].toUpperCase()+qa.slice(1);return{get:()=>Ra,set(ed){this[Ja]=ed}}});utils $ 1.freezeMethods(AxiosHeaders);function transformData(Ra,qa){const Ja=this||defaults,ed=qa||Ja,td=AxiosHeaders.from(ed.headers);let rd=ed.data;return utils $ 1.forEach(Ra,function(od){rd=od.call(Ja,rd,td.normalize(),qa?qa.status:void 0)}),td.normalize(),rd}function isCancel(Ra){return!!(Ra&&Ra.__CANCEL__)}function CanceledError(Ra,qa,Ja){AxiosError.call(this,Ra??"canceled",AxiosError.ERR_CANCELED,qa,Ja),this.name="CanceledError"}utils $ 1.inherits(CanceledError,AxiosError,{__CANCEL__:!0});function settle(Ra,qa,Ja){const ed=Ja.config.validateStatus;!Ja.status||!ed||ed(Ja.status)?Ra(Ja):qa(new AxiosError("Request failed with status code "+Ja.status,[AxiosError.ERR_BAD_REQUEST,AxiosError.ERR_BAD_RESPONSE][Math.floor(Ja.status/100)-4],Ja.config,Ja.request,Ja))}function parseProtocol(Ra){const qa=/^([-+ \w ]{1,25})(:? \/ \/ |:)/.exec(Ra);return qa&&qa[1]||""}function speedometer(Ra,qa){Ra=Ra||10;const Ja=new Array(Ra),ed=new Array(Ra);let td=0,rd=0,sd;return qa=qa!==void 0?qa:1e3,function(ld){const cd=Date.now(),ud=ed[rd];sd||(sd=cd),Ja[td]=ld,ed[td]=cd;let _d=rd,yd=0;for(;_d!==td;)yd+=Ja[_d++],_d=_d%Ra;if(td=(td+1)%Ra,td===rd&&(rd=(rd+1)%Ra),cd-sd<qa)return;const gd=ud&&cd-ud;return gd?Math.round(yd*1e3/gd):void 0}}function throttle(Ra,qa){let Ja=0,ed=1e3/qa,td,rd;const sd=(cd,ud=Date.now())=>{Ja=ud,td=null,rd&&(clearTimeout(rd),rd=null),Ra.apply(null,cd)};return[(...cd)=>{const ud=Date.now(),_d=ud-Ja;_d>=ed?sd(cd,ud):(td=cd,rd||(rd=setTimeout(()=>{rd=null,sd(td)},ed-_d)))},()=>td&&sd(td)]}const progressEventReducer=(Ra,qa,Ja=3)=>{let ed=0;const td=speedometer(50,250);return throttle(rd=>{const sd=rd.loaded,od=rd.lengthComputable?rd.total:void 0,ld=sd-ed,cd=td(ld),ud=sd<=od;ed=sd;const _d={loaded:sd,total:od,progress:od?sd/od:void 0,bytes:ld,rate:cd||void 0,estimated:cd&&od&&ud?(od-sd)/cd:void 0,event:rd,lengthComputable:od!=null,[qa?"download":"upload"]:!0};Ra(_d)},Ja)},progressEventDecorator=(Ra,qa)=>{const Ja=Ra!=null;return[ed=>qa[0]({lengthComputable:Ja,total:Ra,loaded:ed}),qa[1]]},asyncDecorator=Ra=>(...qa)=>utils $ 1.asap(()=>Ra(...qa)),isURLSameOrigin=platform.hasStandardBrowserEnv?function(){const qa=platform.navigator&&/(msie|trident)/i.test(platform.navigator.userAgent),Ja=document.createElement("a");let ed;function td(rd){let sd=rd;return qa&&(Ja.setAttribute("href",sd),sd=Ja.href),Ja.setAttribute("href",sd),{href:Ja.href,protocol:Ja.protocol?Ja.protocol.replace(/: $ /,""):"",host:Ja.host,search:Ja.search?Ja.search.replace(/^ \? /,""):"",hash:Ja.hash?Ja.hash.replace(/^#/,""):"",hostname:Ja.hostname,port:Ja.port,pathname:Ja.pathname.charAt(0)==="/"?Ja.pathname:"/"+Ja.pathname}}return ed=td(window.location.href),function(sd){const od=utils $ 1.isString(sd)?td(sd):sd;return od.protocol===ed.protocol&&od.host===ed.host}}():function(){return function(){return!0}}(),cookies=platform.hasStandardBrowserEnv?{write(Ra,qa,Ja,ed,td,rd){const sd=[Ra+"="+encodeURIComponent(qa)];utils $ 1.isNumber(Ja)&&sd.push("expires="+new Date(Ja).toGMTString()),utils $ 1.isString(ed)&&sd.push("path="+ed),utils $ 1.isString(td)&&sd.push("domain="+td),rd===!0&&sd.push("secure"),document.cookie=sd.join("; ")},read(Ra){const qa=document.cookie.match(new RegExp("(^|; \\ s*)("+Ra+")=([^;]*)"));return qa?decodeURIComponent(qa[3]):null},remove(Ra){this.write(Ra,"",Date.now()-864e5)}}:{write(){},read(){return null},remove(){}};function isAbsoluteURL(Ra){return/^([a-z][a-z \d + \- .]*
2024-08-30 15:19:18 +08:00
` +rd.map(renderReason).join( `
2024-09-04 13:02:35 +08:00
` ):" "+renderReason(rd[0]):"as no adapter specified";throw new AxiosError("There is no suitable adapter to dispatch the request "+sd,"ERR_NOT_SUPPORT")}return ed},adapters:knownAdapters};function throwIfCancellationRequested(Ra){if(Ra.cancelToken&&Ra.cancelToken.throwIfRequested(),Ra.signal&&Ra.signal.aborted)throw new CanceledError(null,Ra)}function dispatchRequest(Ra){return throwIfCancellationRequested(Ra),Ra.headers=AxiosHeaders.from(Ra.headers),Ra.data=transformData.call(Ra,Ra.transformRequest),["post","put","patch"].indexOf(Ra.method)!==-1&&Ra.headers.setContentType("application/x-www-form-urlencoded",!1),adapters.getAdapter(Ra.adapter||defaults.adapter)(Ra).then(function(ed){return throwIfCancellationRequested(Ra),ed.data=transformData.call(Ra,Ra.transformResponse,ed),ed.headers=AxiosHeaders.from(ed.headers),ed},function(ed){return isCancel(ed)||(throwIfCancellationRequested(Ra),ed&&ed.response&&(ed.response.data=transformData.call(Ra,Ra.transformResponse,ed.response),ed.response.headers=AxiosHeaders.from(ed.response.headers))),Promise.reject(ed)})}const VERSION="1.7.7",validators $ 1={};["object","boolean","number","function","string","symbol"].forEach((Ra,qa)=>{validators $ 1[Ra]=function(ed){return typeof ed===Ra||"a"+(qa<1?"n ":" ")+Ra}});const deprecatedWarnings={};validators $ 1.transitional=function(qa,Ja,ed){function td(rd,sd){return"[Axios v"+VERSION+"] Transitional option '"+rd+"'"+sd+(ed?". "+ed:"")}return(rd,sd,od)=>{if(qa===!1)throw new AxiosError(td(sd," has been removed"+(Ja?" in "+Ja:"")),AxiosError.ERR_DEPRECATED);return Ja&&!deprecatedWarnings[sd]&&(deprecatedWarnings[sd]=!0,console.warn(td(sd," has been deprecated since v"+Ja+" and will be removed in the near future"))),qa?qa(rd,sd,od):!0}};function assertOptions(Ra,qa,Ja){if(typeof Ra!="object")throw new AxiosError("options must be an object",AxiosError.ERR_BAD_OPTION_VALUE);const ed=Object.keys(Ra);let td=ed.length;for(;td-- >0;){const rd=ed[td],sd=qa[rd];if(sd){const od=Ra[rd],ld=od===void 0||sd(od,rd,Ra);if(ld!==!0)throw new AxiosError("option "+rd+" must be "+ld,AxiosError.ERR_BAD_OPTION_VALUE);continue}if(Ja!==!0)throw new AxiosError("Unknown option "+rd,AxiosError.ERR_BAD_OPTION)}}const validator={assertOptions,validators:validators $ 1},validators=validator.validators;class Axios{constructor(qa){this.defaults=qa,this.interceptors={request:new InterceptorManager,response:new InterceptorManager}}async request(qa,Ja){try{return await this._request(qa,Ja)}catch(ed){if(ed instanceof Error){let td;Error.captureStackTrace?Error.captureStackTrace(td={}):td=new Error;const rd=td.stack?td.stack.replace(/^.+ \n /,""):"";try{ed.stack?rd&&!String(ed.stack).endsWith(rd.replace(/^.+ \n .+ \n /,""))&&(ed.stack+= `
2024-09-08 17:22:36 +08:00
` +rd):ed.stack=rd}catch{}}throw ed}}_request(qa,Ja){typeof qa=="string"?(Ja=Ja||{},Ja.url=qa):Ja=qa||{},Ja=mergeConfig(this.defaults,Ja);const{transitional:ed,paramsSerializer:td,headers:rd}=Ja;ed!==void 0&&validator.assertOptions(ed,{silentJSONParsing:validators.transitional(validators.boolean),forcedJSONParsing:validators.transitional(validators.boolean),clarifyTimeoutError:validators.transitional(validators.boolean)},!1),td!=null&&(utils $ 1.isFunction(td)?Ja.paramsSerializer={serialize:td}:validator.assertOptions(td,{encode:validators.function,serialize:validators.function},!0)),Ja.method=(Ja.method||this.defaults.method||"get").toLowerCase();let sd=rd&&utils $ 1.merge(rd.common,rd[Ja.method]);rd&&utils $ 1.forEach(["delete","get","head","post","put","patch","common"],Ed=>{delete rd[Ed]}),Ja.headers=AxiosHeaders.concat(sd,rd);const od=[];let ld=!0;this.interceptors.request.forEach(function(Td){typeof Td.runWhen=="function"&&Td.runWhen(Ja)===!1||(ld=ld&&Td.synchronous,od.unshift(Td.fulfilled,Td.rejected))});const cd=[];this.interceptors.response.forEach(function(Td){cd.push(Td.fulfilled,Td.rejected)});let ud,_d=0,yd;if(!ld){const Ed=[dispatchRequest.bind(this),void 0];for(Ed.unshift.apply(Ed,od),Ed.push.apply(Ed,cd),yd=Ed.length,ud=Promise.resolve(Ja);_d<yd;)ud=ud.then(Ed[_d++],Ed[_d++]);return ud}yd=od.length;let gd=Ja;for(_d=0;_d<yd;){const Ed=od[_d++],Td=od[_d++];try{gd=Ed(gd)}catch(Od){Td.call(this,Od);break}}try{ud=dispatchRequest.call(this,gd)}catch(Ed){return Promise.reject(Ed)}for(_d=0,yd=cd.length;_d<yd;)ud=ud.then(cd[_d++],cd[_d++]);return ud}getUri(qa){qa=mergeConfig(this.defaults,qa);const Ja=buildFullPath(qa.baseURL,qa.url);return buildURL(Ja,qa.params,qa.paramsSerializer)}}utils $ 1.forEach(["delete","get","head","options"],function(qa){Axios.prototype[qa]=function(Ja,ed){return this.request(mergeConfig(ed||{},{method:qa,url:Ja,data:(ed||{}).data}))}});utils $ 1.forEach(["post","put","patch"],function(qa){function Ja(ed){return function(rd,sd,od){return this.request(mergeConfig(od||{},{method:qa,headers:ed?{"Content-Type":"multipart/form-data"}:{},url:rd,data:sd}))}}Axios.prototype[qa]=Ja(),Axios.prototype[qa+"Form"]=Ja(!0)});class CancelToken{constructor(qa){if(typeof qa!="function")throw new TypeError("executor must be a function.");let Ja;this.promise=new Promise(function(rd){Ja=rd});const ed=this;this.promise.then(td=>{if(!ed._listeners)return;let rd=ed._listeners.length;for(;rd-- >0;)ed._listeners[rd](td);ed._listeners=null}),this.promise.then=td=>{let rd;const sd=new Promise(od=>{ed.subscribe(od),rd=od}).then(td);return sd.cancel=function(){ed.unsubscribe(rd)},sd},qa(function(rd,sd,od){ed.reason||(ed.reason=new CanceledError(rd,sd,od),Ja(ed.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(qa){if(this.reason){qa(this.reason);return}this._listeners?this._listeners.push(qa):this._listeners=[qa]}unsubscribe(qa){if(!this._listeners)return;const Ja=this._listeners.indexOf(qa);Ja!==-1&&this._listeners.splice(Ja,1)}toAbortSignal(){const qa=new AbortController,Ja=ed=>{qa.abort(ed)};return this.subscribe(Ja),qa.signal.unsubscribe=()=>this.unsubscribe(Ja),qa.signal}static source(){let qa;return{token:new CancelToken(function(td){qa=td}),cancel:qa}}}function spread(Ra){return function(Ja){return Ra.apply(null,Ja)}}function isAxiosError(Ra){return utils $ 1.isObject(Ra)&&Ra.isAxiosError===!0}const HttpStatusCode={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,Expect
2024-08-27 22:31:52 +08:00
async ( CUSTOM _ARG ) => {
$ { localStorage . getItem ( "formCustomConfig" ) }
}
2024-09-08 17:22:36 +08:00
` ;return new Promise((resolve,reject)=>{const exportObj={content,file,util:{axios:service,CryptoJS,OSS,COS,Buffer,uuidv4:v4,qiniu,tokenTools,getDir,getDateFilename},okCb:resolve,errCb:reject};eval(str)(exportObj).catch(Ra=>{console.error(Ra),reject(Ra)})})}function fileUpload(Ra,qa){const Ja=localStorage.getItem("imgHost");switch(!Ja&&localStorage.setItem("imgHost","default"),Ja){case"aliOSS":return aliOSSFileUpload(qa);case"minio":return minioFileUpload(Ra,qa.name);case"txCOS":return txCOSFileUpload(qa);case"qiniu":return qiniuUpload(qa);case"gitee":return giteeUpload(Ra,qa.name);case"github":return ghFileUpload(Ra,qa.name);case"formCustom":return formCustomUpload(Ra,qa);default:return ghFileUpload(Ra,qa.name)}}const fileApi={fileUpload};/**
2024-08-27 22:31:52 +08:00
* @ license lucide - vue - next v0 . 428.0 - ISC
*
* This source code is licensed under the ISC license .
* See the LICENSE file in the root directory of this source tree .
2024-08-30 15:19:18 +08:00
* /const toKebabCase=Ra=>Ra.replace(/ ( [ a - z0 - 9 ] ) ( [ A - Z ] ) / g , "$1-$2" ) . toLowerCase ( ) ; / * *
2024-08-27 22:31:52 +08:00
* @ license lucide - vue - next v0 . 428.0 - ISC
*
* This source code is licensed under the ISC license .
* See the LICENSE file in the root directory of this source tree .
* /var defaultAttributes={xmlns:"http:/ / www . w3 . org / 2000 / svg ",width:24,height:24,viewBox:" 0 0 24 24 ",fill:" none ",stroke:" currentColor "," stroke - width ":2," stroke - linecap ":" round "," stroke - linejoin ":" round " } ; / * *
* @ license lucide - vue - next v0 . 428.0 - ISC
*
* This source code is licensed under the ISC license .
* See the LICENSE file in the root directory of this source tree .
2024-09-03 08:22:14 +08:00
* / c o n s t I c o n = ( { s i z e : R a , s t r o k e W i d t h : q a = 2 , a b s o l u t e S t r o k e W i d t h : J a , c o l o r : e d , i c o n N o d e : t d , n a m e : r d , c l a s s : s d , . . . o d } , { s l o t s : l d } ) = > h $ 1 ( " s v g " , { . . . d e f a u l t A t t r i b u t e s , w i d t h : R a | | d e f a u l t A t t r i b u t e s . w i d t h , h e i g h t : R a | | d e f a u l t A t t r i b u t e s . h e i g h t , s t r o k e : e d | | d e f a u l t A t t r i b u t e s . s t r o k e , " s t r o k e - w i d t h " : J a ? N u m b e r ( q a ) * 2 4 / N u m b e r ( R a ) : q a , c l a s s : [ " l u c i d e " , ` l u c i d e - $ { t o K e b a b C a s e ( r d ? ? " i c o n " ) } ` ] , . . . o d } , [ . . . t d . m a p ( c d = > h $ 1 ( . . . c d ) ) , . . . l d . d e f a u l t ? [ l d . d e f a u l t ( ) ] : [ ] ] ) ; / * *
2024-08-27 22:31:52 +08:00
* @ license lucide - vue - next v0 . 428.0 - ISC
*
* This source code is licensed under the ISC license .
* See the LICENSE file in the root directory of this source tree .
2024-09-03 08:22:14 +08:00
* /const createLucideIcon=(Ra,qa)=>(Ja,{slots:ed})=>h$1(Icon,{...Ja,iconNode:qa,name:Ra},ed);/ * *
2024-08-27 22:31:52 +08:00
* @ license lucide - vue - next v0 . 428.0 - ISC
*
* This source code is licensed under the ISC license .
* See the LICENSE file in the root directory of this source tree .
2024-09-08 17:22:36 +08:00
* /const Check=createLucideIcon("CheckIcon",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);/ * *
* @ license lucide - vue - next v0 . 428.0 - ISC
*
* This source code is licensed under the ISC license .
* See the LICENSE file in the root directory of this source tree .
* /const ChevronDown=createLucideIcon("ChevronDownIcon",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]);/ * *
* @ license lucide - vue - next v0 . 428.0 - ISC
*
* This source code is licensed under the ISC license .
* See the LICENSE file in the root directory of this source tree .
* /const ChevronRight=createLucideIcon("ChevronRightIcon",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]);/ * *
* @ license lucide - vue - next v0 . 428.0 - ISC
*
* This source code is licensed under the ISC license .
* See the LICENSE file in the root directory of this source tree .
* /const ChevronUp=createLucideIcon("ChevronUpIcon",[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]]);/ * *
* @ license lucide - vue - next v0 . 428.0 - ISC
*
* This source code is licensed under the ISC license .
* See the LICENSE file in the root directory of this source tree .
* /const Moon=createLucideIcon("MoonIcon",[["path",{d:"M12 3a6 6 0 0 0 9 9 9 9 0 1 1-9-9Z",key:"a7tn18"}]]);/ * *
* @ license lucide - vue - next v0 . 428.0 - ISC
*
* This source code is licensed under the ISC license .
* See the LICENSE file in the root directory of this source tree .
* /const Paintbrush=createLucideIcon("PaintbrushIcon",[["path",{d:"m14.622 17.897-10.68-2.913",key:"vj2p1u"}],["path",{d:"M18.376 2.622a1 1 0 1 1 3.002 3.002L17.36 9.643a.5.5 0 0 0 0 .707l.944.944a2.41 2.41 0 0 1 0 3.408l-.944.944a.5.5 0 0 1-.707 0L8.354 7.348a.5.5 0 0 1 0-.707l.944-.944a2.41 2.41 0 0 1 3.408 0l.944.944a.5.5 0 0 0 .707 0z",key:"18tc5c"}],["path",{d:"M9 8c-1.804 2.71-3.97 3.46-6.583 3.948a.507.507 0 0 0-.302.819l7.32 8.883a1 1 0 0 0 1.185.204C12.735 20.405 16 16.792 16 15",key:"ytzfxy"}]]);/ * *
* @ license lucide - vue - next v0 . 428.0 - ISC
*
* This source code is licensed under the ISC license .
* See the LICENSE file in the root directory of this source tree .
* / c o n s t S u n = c r e a t e L u c i d e I c o n ( " S u n I c o n " , [ [ " c i r c l e " , { c x : " 1 2 " , c y : " 1 2 " , r : " 4 " , k e y : " 4 e x i p 2 " } ] , [ " p a t h " , { d : " M 1 2 2 v 2 " , k e y : " t u s 0 3 m " } ] , [ " p a t h " , { d : " M 1 2 2 0 v 2 " , k e y : " 1 l h 1 k g " } ] , [ " p a t h " , { d : " m 4 . 9 3 4 . 9 3 1 . 4 1 1 . 4 1 " , k e y : " 1 4 9 t 6 j " } ] , [ " p a t h " , { d : " m 1 7 . 6 6 1 7 . 6 6 1 . 4 1 1 . 4 1 " , k e y : " p t b g u v " } ] , [ " p a t h " , { d : " M 2 1 2 h 2 " , k e y : " 1 t 8 f 8 n " } ] , [ " p a t h " , { d : " M 2 0 1 2 h 2 " , k e y : " 1 q 8 m j w " } ] , [ " p a t h " , { d : " m 6 . 3 4 1 7 . 6 6 - 1 . 4 1 1 . 4 1 " , k e y : " 1 m 8 z z 5 " } ] , [ " p a t h " , { d : " m 1 9 . 0 7 4 . 9 3 - 1 . 4 1 1 . 4 1 " , k e y : " 1 s h l c s " } ] ] ) ; f u n c t i o n i s C o m p o n e n t P u b l i c I n s t a n c e ( R a ) { r e t u r n R a ! = n u l l & & t y p e o f R a = = " o b j e c t " & & " $ e l " i n R a } f u n c t i o n u n w r a p E l e m e n t ( R a ) { i f ( i s C o m p o n e n t P u b l i c I n s t a n c e ( R a ) ) { c o n s t q a = R a . $ e l ; r e t u r n i s N o d e $ 1 ( q a ) & & g e t N o d e N a m e ( q a ) = = = " # c o m m e n t " ? n u l l : q a } r e t u r n R a } f u n c t i o n t o V a l u e $ 1 ( R a ) { r e t u r n t y p e o f R a = = " f u n c t i o n " ? R a ( ) : u n r e f ( R a ) } f u n c t i o n a r r o w ( R a ) { r e t u r n { n a m e : " a r r o w " , o p t i o n s : R a , f n ( q a ) { c o n s t J a = u n w r a p E l e m e n t ( t o V a l u e $ 1 ( R a . e l e m e n t ) ) ; r e t u r n J a = = n u l l ? { } : a r r o w $ 1 ( { e l e m e n t : J a , p a d d i n g : R a . p a d d i n g } ) . f n ( q a ) } } } f u n c t i o n g e t D P R ( R a ) { r e t u r n t y p e o f w i n d o w > " u " ? 1 : ( R a . o w n e r D o c u m e n t . d e f a u l t V i e w | | w i n d o w ) . d e v i c e P i x e l R a t i o | | 1 } f u n c t i o n r o u n d B y D P R ( R a , q a ) { c o n s t J a = g e t D P R ( R a ) ; r e t u r n M a t h . r o u n d ( q a * J a ) / J a } f u n c t i o n u s e F l o a t i n g ( R a , q a , J a ) { J a = = = v o i d 0 & & ( J a = { } ) ; c o n s t e d = J a . w h i l e E l e m e n t s M o u n t e d , t d = c o m p u t e d ( ( ) = > { v a r q d ; r e t u r n ( q d = t o V a l u e $ 1 ( J a . o p e n ) ) ! = n u l l ? q d : ! 0 } ) , r d = c o m p u t e d ( ( ) = > t o V a l u e $ 1 ( J a . m i d d l e w a r e ) ) , s d = c o m p u t e d ( ( ) = > { v a r q d ; r e t u r n ( q d = t o V a l u e $ 1 ( J a . p l a c e m e n t ) ) ! = n u l l ? q d : " b o t t o m " } ) , o d = c o m p u t e d ( ( ) = > { v a r q d ; r e t u r n ( q d = t o V a l u e $ 1 ( J a . s t r a t e g y ) ) ! = n u l l ? q d : " a b s o l u t e " } ) , l d = c o m p u t e d ( ( ) = > { v a r q d ; r e t u r n ( q d = t o V a l u e $ 1 ( J a . t r a n s f o r m ) ) ! = n u l l ? q d : ! 0 } ) , c d = c o m p u t e d ( ( ) = > u n w r a p E l e m e n t ( R a . v a l u e ) ) , u d = c o m p u t e d ( ( ) = > u n w r a p E l e m e n t ( q a . v a l u e ) ) , _ d = r e f $ 1 ( 0 ) , y d = r e f $ 1 ( 0 ) , g d = r e f $ 1 ( o d . v a l u e ) , E d = r e f $ 1 ( s d . v a l u e ) , T d = s h a l l o w R e f ( { } ) , O d = r e f $ 1 ( ! 1 ) , R d = c o m p u t e d ( ( ) = > { c o n s t q d = { p o s i t i o n : g d . v a l u e , l e f t : " 0 " , t o p : " 0 " } ; i f ( ! u d . v a l u e ) r e t u r n q d ; c o n s t Y d = r o u n d B y D P R ( u d . v a l u e , _ d . v a l u e ) , U d = r o u n d B y D P R ( u d . v a l u e , y d . v a l u e ) ; r e t u r n l d . v a l u e ? { . . . q d , t r a n s f o r m : " t r a n s l a t e ( " + Y d + " p x , " + U d + " p x ) " , . . . g e t D P R ( u d . v a l u e ) > = 1 . 5 & & { w i l l C h a n g e : " t r a n s f o r m " } } : { p o s i t i o n : g d . v a l u e , l e f t : Y d + " p x " , t o p : U d + " p x " } } ) ; l e t N d ; f u n c t i o n I d ( ) { c d . v a l u e = = n u l l | | u d . v a l u e = = n u l l | | c o m p u t e P o s i t i o n ( c d . v a l u e , u d . v a l u e , { m i d d l e w a r e : r d . v a l u e , p l a c e m e n t : s d . v a l u e , s t r a t e g y : o d . v a l u e } ) . t h e n ( q d = > { _ d . v a l u e = q d . x , y d . v a l u e = q d . y , g d . v a l u e = q d . s t r a t e g y , E d . v a l u e = q d . p l a c e m e n t , T d . v a l u e = q d . m i d d l e w a r e D a t a , O d . v a l u e = ! 0 } ) } f u n c t i o n M d ( ) { t y p e o f N d = = " f u n c t i o n " & & ( N d ( ) , N d = v o i d 0 ) } f u n c t i o n L d ( ) { i f ( M d ( ) , e d = = = v o i d 0 ) { I d ( ) ; r e t u r n } i f ( c d . v a l u e ! = n u l l & & u d . v a l u e ! = n u l l ) { N d = e d ( c d . v a l u e , u d . v a l u e , I d ) ; r e t u r n } } f u n c t i o n P d ( ) { t d . v a l u e | | ( O d . v a l u e = ! 1 ) } r e t u r n w a t c h ( [ r d , s d , o d ] , I d , { f l u s h : " s y n c " } ) , w a t c h ( [ c d , u d ] , L d , { f l u s h : " s y n c " } ) , w a t c h ( t d , P d , { f l u s h : " s y n c " } ) , g e t C u r r e n t S c o p e ( ) & & o n S c o p e D i s p o s e ( M d ) , { x : s h a l l o w R e a d o n l y ( _ d ) , y : s h a l l o w R e a d o n l y ( y d ) , s t r a t e g y : s h a l l o w R e a d o n l y ( g d ) , p l a c e m e n t : s h a l l o w R e a d o n l y ( E d ) , m i d d l e w a r e D a t a : s h a l l o w R e a d o n l y ( T d ) , i s P o s i t i o n e d : s h a l l o w R e a d o n l y ( O d ) , f l o a t i n g S t y l e s : R d , u p d a t e : I d } } f u n c t i o n Q ( R a , q a ) { c o n s t J a = t y p e o f R a = = " s t r i n g " & & ! q a ? ` $ { R a } C o n t e x t ` : q a , e d = S y m b o l ( J a ) ; r e t u r n [ t d = > { c o n s t r d = i n j e c t ( e d , t d ) ; i f ( r d | | r d = = = n u l l ) r e t u r n r d ; t h r o w n e w E r r o r ( ` I n j e c t i o n \ ` $ { e d . t o S t r i n g ( ) } \ ` n o t f o u n d . C o m p o n e n t m u s t b e u s e d w i t h i n $ { A r r a y . i s A r r a y ( R a ) ? ` o n e o f t h e f o l l o w i n g c o m p o n e n t s : $ { R a . j o i n ( " , " ) } ` : ` \ ` $ { R a } \ ` ` } ` ) } , t d = > ( p r o v i d e ( e d , t d ) , t d ) ] } f u n c t i o n K t ( R a , q a , J a ) { c o n s t e d = J a . o r i g i n a l E v e n t . t a r g e t , t d = n e w C u s t o m E v e n t ( R a , { b u b b l e s : ! 1 , c a n c e l a b l e : ! 0 , d e t a i l : J a } ) ; q a & & e d . a d d E v e n t L i s t e n e r ( R a , q a , { o n c e : ! 0 } ) , e d . d i s p a t c h E v e n t ( t d ) } f u n c t i o n H t ( R a , q a = N u m b e r . N E G A T I V E _ I N F I N I T Y , J a = N u m b e r . P O S I T I V E _ I N F I N I T Y ) { r e t u r n M a t h . m i n ( M a t h . m a x ( R a , q a ) , J a ) } f u n c t i o n z t ( R a ) { r e t u r n R a = = n u l l } f u n c t i o n Y r ( R a , q a ) { v a r J a ; c o n s t e d = s h a l l o w R e f ( ) ; r e t u r n w a t c h E f f e c t ( ( ) = > { e d . v a l u e = R a ( ) } , { . . . q a , f l u s h : ( J a = v o i d 0 ) ! = n u l l ? J a : " s y n c " } ) , r e a d o n l y ( e d ) } f u n c t i o n m t ( R a ) { r e t u r n g e t C u r r e n t S c o p e ( ) ? ( o n S c o p e D i s p o s e ( R a ) , ! 0 ) : ! 1 } f u n c t i o n i a ( ) { c o n s t R a = n e w S e t , q a = J a = > { R a . d e l e t e ( J a ) } ; r e t u r n { o n : J a = > { R a . a d d ( J a ) ; c o n s t e d = ( ) = > q a ( J a ) ; r e t u r n m t ( e d ) , { o f f : e d } } , o f f : q a , t r i g g e r : ( . . . J a ) = > P r o m i s e . a l l ( A r r a y . f r o m ( R a ) . m a p ( e d = > e d ( . . . J a ) ) ) } } f u n c t i o n Z r ( R a ) { l e t q a = ! 1 , J a ; c o n s t e d = e f f e c t S c o p e ( ! 0 ) ; r e t u r n ( . . . t d ) = > ( q a | | ( J a = e d . r u n ( ( ) = > R a ( . . . t d ) ) , q a = ! 0 ) , J a ) } f u n c t i o n w l ( R a ) { l e t q a = 0 , J a , e d ; c o n s t t d = ( ) = > { q a - = 1 , e d & & q a < = 0 & & ( e d . s t o p ( ) , J a =
` )].join( `
` ))}return()=>rd.value||td.value||od.value?h $ 1(qa.default({present:od})[0],{ref:ud=>{const _d= $ e(ud);return typeof(_d==null?void 0:_d.hasAttribute)>"u"||(_d!=null&&_d.hasAttribute("data-radix-popper-content-wrapper")?sd.value=_d.firstElementChild:sd.value=_d),_d}}):null}}),ht=defineComponent({__name:"Teleport",props:{to:{default:"body"},disabled:{type:Boolean},forceMount:{type:Boolean}},setup(Ra){const qa=ja();return(Ja,ed)=>unref(qa)||Ja.forceMount?(openBlock(),createBlock(Teleport $ 1,{key:0,to:Ja.to,disabled:Ja.disabled},[renderSlot(Ja. $ slots,"default")],8,["to","disabled"])):createCommentVNode("",!0)}}),Yi="dismissableLayer.pointerDownOutside",Xi="dismissableLayer.focusOutside";function Fl(Ra,qa){const Ja=qa.closest("[data-dismissable-layer]"),ed=Ra.dataset.dismissableLayer===""?Ra:Ra.querySelector("[data-dismissable-layer]"),td=Array.from(Ra.ownerDocument.querySelectorAll("[data-dismissable-layer]"));return!!(Ja&&ed===Ja||td.indexOf(ed)<td.indexOf(Ja))}function Nl(Ra,qa){var Ja;const ed=((Ja=qa==null?void 0:qa.value)==null?void 0:Ja.ownerDocument)??(globalThis==null?void 0:globalThis.document),td=ref $ 1(!1),rd=ref $ 1(()=>{});return watchEffect(sd=>{if(!qe)return;const od=async cd=>{const ud=cd.target;if(qa!=null&&qa.value){if(Fl(qa.value,ud)){td.value=!1;return}if(cd.target&&!td.value){let _d=function(){Kt(Yi,Ra,yd)};const yd={originalEvent:cd};cd.pointerType==="touch"?(ed.removeEventListener("click",rd.value),rd.value=_d,ed.addEventListener("click",rd.value,{once:!0})):_d()}else ed.removeEventListener("click",rd.value);td.value=!1}},ld=window.setTimeout(()=>{ed.addEventListener("pointerdown",od)},0);sd(()=>{window.clearTimeout(ld),ed.removeEventListener("pointerdown",od),ed.removeEventListener("click",rd.value)})}),{onPointerDownCapture:()=>td.value=!0}}function Ll(Ra,qa){var Ja;const ed=((Ja=qa==null?void 0:qa.value)==null?void 0:Ja.ownerDocument)??(globalThis==null?void 0:globalThis.document),td=ref $ 1(!1);return watchEffect(rd=>{if(!qe)return;const sd=async od=>{qa!=null&&qa.value&&(await nextTick $ 1(),!(!qa.value||Fl(qa.value,od.target))&&od.target&&!td.value&&Kt(Xi,Ra,{originalEvent:od}))};ed.addEventListener("focusin",sd),rd(()=>ed.removeEventListener("focusin",sd))}),{onFocusCapture:()=>td.value=!0,onBlurCapture:()=>td.value=!1}}const je=reactive({layersRoot:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),yt=defineComponent({__name:"DismissableLayer",props:{disableOutsidePointerEvents:{type:Boolean,default:!1},asChild:{type:Boolean},as:{}},emits:["escapeKeyDown","pointerDownOutside","focusOutside","interactOutside","dismiss"],setup(Ra,{emit:qa}){const Ja=Ra,ed=qa,{forwardRef:td,currentElement:rd}=T(),sd=computed(()=>{var Ed;return((Ed=rd.value)==null?void 0:Ed.ownerDocument)??globalThis.document}),od=computed(()=>je.layersRoot),ld=computed(()=>rd.value?Array.from(od.value).indexOf(rd.value):-1),cd=computed(()=>je.layersWithOutsidePointerEventsDisabled.size>0),ud=computed(()=>{const Ed=Array.from(od.value),[Td]=[...je.layersWithOutsidePointerEventsDisabled].slice(-1),Od=Ed.indexOf(Td);return ld.value>=Od}),_d=Nl(async Ed=>{const Td=[...je.branches].some(Od=>Od.contains(Ed.target));!ud.value||Td||(ed("pointerDownOutside",Ed),ed("interactOutside",Ed),await nextTick $ 1(),Ed.defaultPrevented||ed("dismiss"))},rd),yd=Ll(Ed=>{[...je.branches].some(Td=>Td.contains(Ed.target))||(ed("focusOutside",Ed),ed("interactOutside",Ed),Ed.defaultPrevented||ed("dismiss"))},rd);jn("Escape",Ed=>{ld.value===od.value.size-1&&(ed("escapeKeyDown",Ed),Ed.defaultPrevented||ed("dismiss"))});let gd;return watchEffect(Ed=>{rd.value&&(Ja.disableOutsidePointerEvents&&(je.layersWithOutsidePointerEventsDisabled.size===0&&(gd=sd.value.body.style.pointerEvents,sd.value.body.style.pointerEvents="none"),je.layersWithOutsidePointerEventsDisabled.add(rd.value)),od.value.add(rd.value),Ed(()=>{Ja.disableOutsidePointerEvents&&je.layersWithOutsidePointerEventsDisabled.size===1&&(sd.value.body.style.pointerEvents=gd)}))}),watchEffect(Ed=>{Ed(()=>{rd.value&&(od.value.delete(rd.value),je.layersWithOutsidePointerEventsDisabled.delete(rd.v
2024-08-30 15:19:18 +08:00
$ { ld }
2024-09-08 17:22:36 +08:00
` ,"end"),sd(),Ja()}return(ld,cd)=>{const ud=ElInputNumber,_d=ElCol,yd=ElRow,gd=ElInput,Ed=ElButton,Td=ElDialog;return openBlock(),createBlock(Td,{title:"插入表格",class:"insert__dialog","model-value":unref(qa).isShowInsertFormDialog,onClose:cd[3]||(cd[3]=Od=>unref(Ja)(!1))},{footer:withCtx(()=>[createBaseVNode("div",_hoisted_2 $ 1,[createVNode(Ed,{plain:"",onClick:cd[2]||(cd[2]=Od=>unref(Ja)(!1))},{default:withCtx(()=>cd[6]||(cd[6]=[createTextVNode(" 取 消 ")])),_:1}),createVNode(Ed,{type:"primary",plain:"",onClick:od},{default:withCtx(()=>cd[7]||(cd[7]=[createTextVNode(" 确 定 ")])),_:1})])]),default:withCtx(()=>[createVNode(yd,{class:"tb-options",type:"flex",align:"middle",gutter:10},{default:withCtx(()=>[createVNode(_d,{span:12},{default:withCtx(()=>[cd[4]||(cd[4]=createTextVNode(" 行数: ")),createVNode(ud,{modelValue:ed.value,"onUpdate:modelValue":cd[0]||(cd[0]=Od=>ed.value=Od),"controls-position":"right",min:1,max:100,size:"small"},null,8,["modelValue"])]),_:1}),createVNode(_d,{span:12},{default:withCtx(()=>[cd[5]||(cd[5]=createTextVNode(" 列数: ")),createVNode(ud,{modelValue:td.value,"onUpdate:modelValue":cd[1]||(cd[1]=Od=>td.value=Od),"controls-position":"right",min:1,max:100,size:"small"},null,8,["modelValue"])]),_:1})]),_:1}),createBaseVNode("table",_hoisted_1 $ 2,[(openBlock(!0),createElementBlock(Fragment,null,renderList(ed.value+1,Od=>(openBlock(),createElementBlock("tr",{key:Od,class:normalizeClass({"head-style":Od===1})},[(openBlock(!0),createElementBlock(Fragment,null,renderList(td.value,Rd=>(openBlock(),createElementBlock("td",{key:Rd},[createVNode(gd,{modelValue:rd.value[ ` k _$ { Od - 1 } _$ { Rd - 1 } ` ],"onUpdate:modelValue":Nd=>rd.value[ ` k _$ { Od - 1 } _$ { Rd - 1 } ` ]=Nd,align:"center",placeholder:Od===1?"表头":""},null,8,["modelValue","onUpdate:modelValue","placeholder"])]))),128))],2))),128))])]),_:1},8,["model-value"])}}},InsertFormDialog=_export_sfc(_sfc_main $ b,[["__scopeId","data-v-56362dff"]]),_sfc_main $ a={__name:"UploadImgDialog",emits:["uploadImage"],setup(Ra,{emit:qa}){const Ja=qa,ed=useStore(),td=ref $ 1({repo:"",branch:"",accessToken:""}),rd=ref $ 1({accessKeyId:"",accessKeySecret:"",bucket:"",region:"",path:"",cdnHost:"",useSSL:!0}),sd=ref $ 1({secretId:"",secretKey:"",bucket:"",region:"",path:"",cdnHost:""}),od=ref $ 1({accessKey:"",secretKey:"",bucket:"",domain:"",region:""}),ld=ref $ 1({endpoint:"",port:"",useSSL:!0,bucket:"",accessKey:"",secretKey:""}),cd=ref $ 1({code:localStorage.getItem("formCustomConfig")||removeLeft( `
2024-08-27 22:31:52 +08:00
const { file , util , okCb , errCb } = CUSTOM _ARG
const param = new FormData ( )
param . append ( 'file' , file )
util . axios . post ( '${window.location.origin}/upload' , param , {
headers : { 'Content-Type' : 'multipart/form-data' }
} ) . then ( res => {
okCb ( res . url )
} ) . catch ( err => {
errCb ( err )
} )
2024-09-08 17:22:36 +08:00
` ).trim(),editor:void 0}),ud=[{value:"default",label:"默认"},{value:"github",label:"GitHub"},{value:"aliOSS",label:"阿里云"},{value:"txCOS",label:"腾讯云"},{value:"qiniu",label:"七牛云"},{value:"minio",label:"MinIO"},{value:"formCustom",label:"自定义代码"}],_d=ref $ 1("default"),yd=ref $ 1(null),gd=ref $ 1("upload");watch(gd,async qd=>{qd==="formCustom"&&nextTick $ 1(()=>{const Yd=yd.value. $ el.querySelector("textarea");cd.value.editor=cd.value.editor||CodeMirror.fromTextArea(Yd,{mode:"javascript"})})},{immediate:!0}),onBeforeMount(()=>{localStorage.getItem("githubConfig")&&(td.value=JSON.parse(localStorage.getItem("githubConfig"))),localStorage.getItem("aliOSSConfig")&&(rd.value=JSON.parse(localStorage.getItem("aliOSSConfig"))),localStorage.getItem("txCOSConfig")&&(sd.value=JSON.parse(localStorage.getItem("txCOSConfig"))),localStorage.getItem("qiniuConfig")&&(od.value=JSON.parse(localStorage.getItem("qiniuConfig"))),localStorage.getItem("minioConfig")&&(ld.value=JSON.parse(localStorage.getItem("minioConfig"))),localStorage.getItem("imgHost")&&(_d.value=localStorage.getItem("imgHost"))});function Ed(){localStorage.setItem("imgHost",_d.value),ElMessage.success("已成功切换图床")}function Td(){if(!(td.value.repo&&td.value.accessToken)){const qd=td.value.repo?"token":"GitHub 仓库";ElMessage.error( ` 参数 「 $ { qd } 」 不能为空 ` );return}localStorage.setItem("githubConfig",JSON.stringify(td.value)),ElMessage.success("保存成功")}function Od(){if(!(rd.value.accessKeyId&&rd.value.accessKeySecret&&rd.value.bucket&&rd.value.region)){ElMessage.error("阿里云 OSS 参数配置不全");return}localStorage.setItem("aliOSSConfig",JSON.stringify(rd.value)),ElMessage.success("保存成功")}function Rd(){if(!(ld.value.endpoint&&ld.value.bucket&&ld.value.accessKey&&ld.value.secretKey)){ElMessage.error("MinIO 参数配置不全");return}localStorage.setItem("minioConfig",JSON.stringify(ld.value)),ElMessage.success("保存成功")}function Nd(){if(!(sd.value.secretId&&sd.value.secretKey&&sd.value.bucket&&sd.value.region)){ElMessage.error("腾讯云 COS 参数配置不全");return}localStorage.setItem("txCOSConfig",JSON.stringify(sd.value)),ElMessage.success("保存成功")}function Id(){if(!(od.value.accessKey&&od.value.secretKey&&od.value.bucket&&od.value.domain)){ElMessage.error("七牛云 Kodo 参数配置不全");return}localStorage.setItem("qiniuConfig",JSON.stringify(od.value)),ElMessage.success("保存成功")}function Md(){const qd=cd.value.editor.getValue();localStorage.setItem("formCustomConfig",qd),ElMessage.success("保存成功")}function Ld(qd){const Yd=checkImage(qd);if(!Yd.ok)return ElMessage.error(Yd.msg),!1;let Ud=localStorage.getItem("imgHost");Ud=Ud||"default",localStorage.setItem("imgHost",Ud);const Hd=localStorage.getItem( ` $ { Ud } Config ` );return Ud==="default"||Hd?!0:(ElMessage.error( ` 请先配置 $ { Ud } 图床参数 ` ),!1)}function Pd(qd){Ja("uploadImage",qd.file)}return(qd,Yd)=>{const Ud=ElOption,Hd=ElSelect,zd=ElIcon,Jd=ElUpload,Zd=ElTabPane,pf=ElInput,Qd=ElFormItem,hf=ElLink,mf=ElButton,xf=ElForm,Lf=ElSwitch,Kf=ElTabs,Yf=ElDialog;return openBlock(),createBlock(Yf,{title:"本地上传",class:"upload__dialog","model-value":unref(ed).isShowUploadImgDialog,onClose:Yd[31]||(Yd[31]=Of=>unref(ed).toggleShowUploadImgDialog(!1))},{default:withCtx(()=>[createVNode(Kf,{modelValue:gd.value,"onUpdate:modelValue":Yd[30]||(Yd[30]=Of=>gd.value=Of)},{default:withCtx(()=>[createVNode(Zd,{class:"upload-panel",label:"选择上传",name:"upload"},{default:withCtx(()=>[createVNode(Hd,{modelValue:_d.value,"onUpdate:modelValue":Yd[0]||(Yd[0]=Of=>_d.value=Of),placeholder:"请选择",size:"small",onChange:Ed},{default:withCtx(()=>[(openBlock(),createElementBlock(Fragment,null,renderList(ud,Of=>createVNode(Ud,{key:Of.value,label:Of.label,value:Of.value},null,8,["label","value"])),64))]),_:1},8,["modelValue"]),createVNode(Jd,{drag:"",multiple:"",action:"",headers:{"Content-Type":"multipart/form-data"},"show-file-list":!1,accept:".jpg, .jpeg, .png, .gif",name:"file","before-upload":Ld,"http-request":Pd},{default:withCtx(()=>[c
$ { xf }
` ,mf),ElMessage.success("图片上传成功")}function Ud(hf,mf){Ed.value=!0,toBase64(hf).then(xf=>fileApi.fileUpload(xf,hf)).then(xf=>{mf?mf(xf):Yd(xf)}).catch(xf=>{ElMessage.error(xf.message)}).finally(()=>{Ed.value=!1})}const Hd=ref $ 1(0);function zd(){const hf=document.querySelector("#editor");hf.value||(hf.value=td.value),ed.value=CodeMirror.fromTextArea(hf,{mode:"text/x-markdown",theme:"xq-light",lineNumbers:!1,lineWrapping:!0,styleActiveLine:!0,autoCloseBrackets:!0,extraKeys:{[ ` $ { shiftKey } - $ { altKey } - F ` ]:function(xf){formatDoc(xf.getValue(0)).then(Lf=>{xf.setValue(Lf)})},[ ` $ { ctrlKey } - B ` ]:function(xf){const Lf=xf.getSelection();xf.replaceSelection( ` * * $ { Lf } * * ` )},[ ` $ { ctrlKey } - I ` ]:function(xf){const Lf=xf.getSelection();xf.replaceSelection( ` * $ { Lf } * ` )},[ ` $ { ctrlKey } - D ` ]:function(xf){const Lf=xf.getSelection();xf.replaceSelection( ` ~ ~ $ { Lf } ~ ~ ` )},[ ` $ { ctrlKey } - K ` ]:function(xf){const Lf=xf.getSelection();xf.replaceSelection( ` [ $ { Lf } ] ( ) ` )},[ ` $ { ctrlKey } - E ` ]:function(xf){const Lf=xf.getSelection();xf.replaceSelection( ` \ ` ${ Lf } \` ` ) } , [ ` ${ ctrlKey } -L ` ] : function ( xf ) { const Lf = xf . getSelection ( ) ; xf . replaceSelection ( ` \` ${ Lf } \` ` ) } } } ) , ed . value . on ( "change" , mf => { clearTimeout ( Hd . value ) , Hd . value = setTimeout ( ( ) => { Nd ( ) , td . value = mf . getValue ( ) } , 300 ) } ) , ed . value . on ( "paste" , ( mf , xf ) => { if ( ! ( ! ( xf . clipboardData && xf . clipboardData . items ) || Ed . value ) ) for ( let Lf = 0 , Kf = xf . clipboardData . items . length ; Lf < Kf ; ++ Lf ) { const Yf = xf . clipboardData . items [ Lf ] ; if ( Yf . kind === "file" ) { const Of = Yf . getAsFile ( ) ; if ( ! qd ( Of ) ) continue ; Ud ( Of ) } } } ) } const Jd = ref$1 ( null ) ; function Zd ( hf ) { ed . value . options . extraKeys [ hf ] ( ed . value ) } const pf = ref$1 ( null ) ; function Qd ( ) { const hf = pf . value . $el , mf = async ( { md : Kf , list : Yf } ) => { const Of = [ ... Kf . str . matchAll ( /!\[(.*?)\]\((.*?)\)/g ) || [ ] ] . filter ( Wf => Wf ) , Tf = Kf . path . match ( /.+?\// ) [ 0 ] ; ( await Promise . all ( Of . map ( Wf => new Promise ( Uf => { let [ , , gf ] = Wf ; gf = gf . replace ( /^.\// , "" ) ; const { file : _f } = Yf . find ( $f => $f . path === ` ${ Tf } ${ gf } ` ) || { } ; Ud ( _f , $f => { Uf ( { matchStr : gf , url : $f } ) } ) } ) ) ) ) . forEach ( Wf => { Kf . str = Kf . str . replace ( ` ](./ ${ Wf . matchStr } ) ` , ` ]( ${ Wf . url } ) ` ) . replace ( ` ]( ${ Wf . matchStr } ) ` , ` ]( ${ Wf . url } ) ` ) } ) , ed . value . setValue ( Kf . str ) } ; hf . ondragover = Kf => Kf . preventDefault ( ) , hf . ondrop = async Kf => { Kf . preventDefault ( ) ; for ( const Yf of Kf . dataTransfer . items ) Yf . getAsFileSystemHandle ( ) . then ( async Of => { if ( Of . kind === "directory" ) { const Tf = await Lf ( Of ) , wf = await xf ( { list : Tf } ) ; mf ( { md : wf , list : Tf } ) } else { const Tf = await Of . getFile ( ) ; console . log ( "file" , Tf ) } } ) } ; async function xf ( { list : Kf } ) { return new Promise ( Yf => { const { path : Of , file : Tf } = Kf . find ( Wf => Wf . path . match ( /\.md$/ ) ) , wf = new FileReader ; wf . readAsText ( Tf , "UTF-8" ) , wf . onload = Wf => { Yf ( { str : Wf . target . result , file : Tf , path : Of } ) } } ) } async function Lf ( Kf ) { const Yf = [ ] ; let Of = "" ; try { const Tf = [ Kf ] ; for ( const wf of Tf ) { Of += ` ${ wf . name } / ` ; for await ( const [ , Wf ] of wf ) Wf . kind === "file" ? Yf . push ( { path : Of + Wf . name , file : await Wf . getFile ( ) } ) : ( Yf . push ( { path : ` ${ Of + Wf . name } / ` } ) , Tf . push ( Wf ) ) } } catch ( Tf ) { console . error ( Tf ) } return Yf } } return onMounted ( ( ) => { zd ( ) , Nd ( ) , Qd ( ) } ) , ( hf , mf ) => { const xf = ElHeader , Lf = ElCol , Kf = ElRow , Yf = ElMain , Of = ElContainer ; return openBlock ( ) , createElementBlock ( "div" , { ref _key : "container" , ref : Jd , class : "container" } , [ createVNode ( Of , null , { default : withCtx ( ( ) => [ createVNode ( xf , { class : "editor__header" } , { default : withCtx ( ( ) => [ createVNode ( EditorHeader , { onAddFormat : Zd , onFormatContent : unref ( cd ) , onStartCopy : Ld , onEndCopy : Pd } , null , 8 , [ "onFormatContent" ] ) ] ) , _ : 1 } ) , createVNode ( Yf , { class : "container-main" } , { default : withCtx ( ( ) => [ createVNode ( Kf , { class : "container-main-section" } , { default : withCtx ( ( ) => [ createVNode ( Lf , { ref _key : "codeMirrorWrapper" , ref : pf , span : unref ( rd ) ? 8 : 12 , class : normalizeClass ( [ "codeMirror-wrapper" , { "order-1" : ! unref ( qa ) . isEditOnLeft } ] ) } , { default : withCtx ( ( ) => [ createVNode ( unref ( _sfc _main$7 ) , null , { default : withCtx ( ( ) => [ createVNode ( unref ( _sfc _main$6 ) , null , { default : withCtx ( ( ) => mf [ 7 ] || ( mf [ 7 ] = [ createBaseVNode ( "textarea" , { id : "editor" , type : "textarea" , placeholder : "Your markdown text here." } , null , - 1 ) ] ) ) , _ : 1 } ) , createVNode ( unref ( _sfc _main$5 ) , { class : "w-64" } , { default : withCtx ( ( ) => [ createVNode ( unref ( _sfc _main$4 ) , { inset : "" , onClick : mf [ 0 ] || ( mf [ 0 ] = Tf => unref ( gd ) ( ) ) } , { default : withCtx ( ( ) => mf [ 8 ] || ( mf [ 8 ] = [ createTextVNode ( "
` ;Rd.replaceSelection(qd+qd,null),yd(Rd,-1),Md=Rd.listSelections();for(var Yd=0;Yd<Md.length;Yd++){var Ud=Md[Yd].head.line;Rd.indentLine(Ud,null,!0),Rd.indentLine(Ud+1,null,!0)}})}function yd(Rd,Nd){for(var Id=[],Md=Rd.listSelections(),Ld=0,Pd=0;Pd<Md.length;Pd++){var qd=Md[Pd];qd.head==Rd.getCursor()&&(Ld=Pd);var Yd=qd.head.ch||Nd>0?{line:qd.head.line,ch:qd.head.ch+Nd}:{line:qd.head.line-1};Id.push({anchor:Yd,head:Yd})}Rd.setSelections(Id,Ld)}function gd(Rd){var Nd=Ja.cmpPos(Rd.anchor,Rd.head)>0;return{anchor:new td(Rd.anchor.line,Rd.anchor.ch+(Nd?-1:1)),head:new td(Rd.head.line,Rd.head.ch+(Nd?1:-1))}}function Ed(Rd,Nd){var Id=cd(Rd);if(!Id||Rd.getOption("disableInput"))return Ja.Pass;var Md=rd(Id,"pairs"),Ld=Md.indexOf(Nd);if(Ld==-1)return Ja.Pass;for(var Pd=rd(Id,"closeBefore"),qd=rd(Id,"triples"),Yd=Md.charAt(Ld+1)==Nd,Ud=Rd.listSelections(),Hd=Ld%2==0,zd,Jd=0;Jd<Ud.length;Jd++){var Zd=Ud[Jd],pf=Zd.head,Qd,hf=Rd.getRange(pf,td(pf.line,pf.ch+1));if(Hd&&!Zd.empty())Qd="surround";else if((Yd||!Hd)&&hf==Nd)Yd&&Od(Rd,pf)?Qd="both":qd.indexOf(Nd)>=0&&Rd.getRange(pf,td(pf.line,pf.ch+3))==Nd+Nd+Nd?Qd="skipThree":Qd="skip";else if(Yd&&pf.ch>1&&qd.indexOf(Nd)>=0&&Rd.getRange(td(pf.line,pf.ch-2),pf)==Nd+Nd){if(pf.ch>2&&/ \b string/.test(Rd.getTokenTypeAt(td(pf.line,pf.ch-2))))return Ja.Pass;Qd="addFour"}else if(Yd){var mf=pf.ch==0?" ":Rd.getRange(td(pf.line,pf.ch-1),pf);if(!Ja.isWordChar(hf)&&mf!=Nd&&!Ja.isWordChar(mf))Qd="both";else return Ja.Pass}else if(Hd&&(hf.length===0||/ \s /.test(hf)||Pd.indexOf(hf)>-1))Qd="both";else return Ja.Pass;if(!zd)zd=Qd;else if(zd!=Qd)return Ja.Pass}var xf=Ld%2?Md.charAt(Ld-1):Nd,Lf=Ld%2?Nd:Md.charAt(Ld+1);Rd.operation(function(){if(zd=="skip")yd(Rd,1);else if(zd=="skipThree")yd(Rd,3);else if(zd=="surround"){for(var Kf=Rd.getSelections(),Yf=0;Yf<Kf.length;Yf++)Kf[Yf]=xf+Kf[Yf]+Lf;Rd.replaceSelections(Kf,"around"),Kf=Rd.listSelections().slice();for(var Yf=0;Yf<Kf.length;Yf++)Kf[Yf]=gd(Kf[Yf]);Rd.setSelections(Kf)}else zd=="both"?(Rd.replaceSelection(xf+Lf,null),Rd.triggerElectric(xf+Lf),yd(Rd,-1)):zd=="addFour"&&(Rd.replaceSelection(xf+xf+xf+xf,"before"),yd(Rd,1))})}function Td(Rd,Nd){var Id=Rd.getRange(td(Nd.line,Nd.ch-1),td(Nd.line,Nd.ch+1));return Id.length==2?Id:null}function Od(Rd,Nd){var Id=Rd.getTokenAt(td(Nd.line,Nd.ch+1));return/ \b string/.test(Id.type)&&Id.start==Nd.ch&&(Nd.ch==0||!/ \b string/.test(Rd.getTokenTypeAt(Nd)))}})})();(function(Ra,qa){(function(Ja){Ja(requireCodemirror())})(function(Ja){var ed=/MSIE \d /.test(navigator.userAgent)&&(document.documentMode==null||document.documentMode<8),td=Ja.Pos,rd={"(":")>",")":"(<","[":"]>","]":"[<","{":"}>","}":"{<","<":">>",">":"<<"};function sd(yd){return yd&&yd.bracketRegex||/[(){}[ \] ]/}function od(yd,gd,Ed){var Td=yd.getLineHandle(gd.line),Od=gd.ch-1,Rd=Ed&&Ed.afterCursor;Rd==null&&(Rd=/(^| )cm-fat-cursor( $ | )/.test(yd.getWrapperElement().className));var Nd=sd(Ed),Id=!Rd&&Od>=0&&Nd.test(Td.text.charAt(Od))&&rd[Td.text.charAt(Od)]||Nd.test(Td.text.charAt(Od+1))&&rd[Td.text.charAt(++Od)];if(!Id)return null;var Md=Id.charAt(1)==">"?1:-1;if(Ed&&Ed.strict&&Md>0!=(Od==gd.ch))return null;var Ld=yd.getTokenTypeAt(td(gd.line,Od+1)),Pd=ld(yd,td(gd.line,Od+(Md>0?1:0)),Md,Ld,Ed);return Pd==null?null:{from:td(gd.line,Od),to:Pd&&Pd.pos,match:Pd&&Pd.ch==Id.charAt(0),forward:Md>0}}function ld(yd,gd,Ed,Td,Od){for(var Rd=Od&&Od.maxScanLineLength||1e4,Nd=Od&&Od.maxScanLines||1e3,Id=[],Md=sd(Od),Ld=Ed>0?Math.min(gd.line+Nd,yd.lastLine()+1):Math.max(yd.firstLine()-1,gd.line-Nd),Pd=gd.line;Pd!=Ld;Pd+=Ed){var qd=yd.getLine(Pd);if(qd){var Yd=Ed>0?0:qd.length-1,Ud=Ed>0?qd.length:-1;if(!(qd.length>Rd))for(Pd==gd.line&&(Yd=gd.ch-(Ed<0?1:0));Yd!=Ud;Yd+=Ed){var Hd=qd.charAt(Yd);if(Md.test(Hd)&&(Td===void 0||(yd.getTokenTypeAt(td(Pd,Yd+1))||"")==(Td||""))){var zd=rd[Hd];if(zd&&zd.charAt(1)==">"==Ed>0)Id.push(Hd);else if(Id.length)Id.pop();else return{pos:td(Pd,Yd),ch:Hd}}}}}return Pd-Ed==(Ed>0?yd.lastLine():yd.firstLine())?!1:null}function cd(yd,gd,Ed){for(var Td=yd.state.matchBrackets.maxHighlightLineLength||1e3,Od=Ed&&Ed.highlightNonMatching,Rd=[],Nd=yd.listSelections(