2023-12-22 16:49:59 +01:00
var w = { isObservable ( e ) { return ! 1 } , processReactiveAttribute ( e , t , n , r ) { return n } } ; function M ( e , t = ! 0 ) { return t ? Object . assign ( w , e ) : ( Object . setPrototypeOf ( e , w ) , e ) } function N ( e ) { return w . isPrototypeOf ( e ) && e !== w ? e : w } function x ( e ) { return typeof e > "u" } function B ( e ) { let t = typeof e ; return t !== "object" ? t : e === null ? "null" : Object . prototype . toString . call ( e ) } function P ( e , t ) { if ( ! e || ! ( e instanceof AbortSignal ) ) return ! 0 ; if ( ! e . aborted ) return e . addEventListener ( "abort" , t ) , function ( ) { e . removeEventListener ( "abort" , t ) } } var $ = { setDeleteAttr : te , ssr : "" } ; function te ( e , t , n ) { if ( Reflect . set ( e , t , n ) , ! ! x ( n ) ) { if ( Reflect . deleteProperty ( e , t ) , e instanceof HTMLElement && e . getAttribute ( t ) === "undefined" ) return e . removeAttribute ( t ) ; if ( Reflect . get ( e , t ) === "undefined" ) return Reflect . set ( e , t , "" ) } } var y = [ { scope : document . body , host : e => e ? e ( document . body ) : document . body , custom _element : ! 1 , prevent : ! 0 } ] , p = { get current ( ) { return y [ y . length - 1 ] } , get host ( ) { return this . current . host } , preventDefault ( ) { let { current : e } = this ; return e . prevent = ! 0 , e } , get state ( ) { return [ ... y ] } , push ( e = { } ) { return y . push ( Object . assign ( { } , this . current , { prevent : ! 1 } , e ) ) } , pushRoot ( ) { return y . push ( y [ 0 ] ) } , pop ( ) { if ( y . length !== 1 ) return y . pop ( ) } } ; function H ( ... e ) { return this . appendOriginal ( ... e ) , this } function ne ( e ) { return e . append === H || ( e . appendOriginal = e . append , e . append = H ) , e } var L ; function R ( e , t , ... n ) { let r = N ( this ) , o = 0 , c , s ; switch ( ( Object ( t ) !== t || r . isObservable ( t ) ) && ( t = { textContent : t } ) , ! 0 ) { case typeof e == "function" : { o = 1 , p . push ( { scope : e , host : ( ... l ) => l . length ? ( o === 1 ? n . unshift ( ... l ) : l . forEach ( b => b ( s ) ) , void 0 ) : s } ) , c = e ( t || void 0 ) ; let u = c instanceof DocumentFragment ; if ( c . nodeName === "#comment" ) break ; let d = R . mark ( { type : "component" , name : e . name , host : u ? "this" : "parentElement" } ) ; c . prepend ( d ) , u && ( s = d ) ; break } case e === "#text" : c = A . call ( this , document . createTextNode ( "" ) , t ) ; break ; case ( e === "<>" || ! e ) : c = A . call ( this , document . createDocumentFragment ( ) , t ) ; break ; case ! ! L : c = A . call ( this , document . createElementNS ( L , e ) , t ) ; break ; case ! c : c = A . call ( this , document . createElement ( e ) , t ) } return ne ( c ) , s || ( s = c ) , n . forEach ( u => u ( s ) ) , o && p . pop ( ) , o = 2 , c } function xe ( e , t = e , n = void 0 ) { let r = Symbol . for ( "default" ) , o = Array . from ( t . querySelectorAll ( "slot" ) ) . reduce ( ( s , u ) => Reflect . set ( s , u . name || r , u ) && s , { } ) , c = Reflect . has ( o , r ) ; if ( e . append = new Proxy ( e . append , { apply ( s , u , d ) { if ( ! d . length ) return e ; let l = document . createDocumentFragment ( ) ; for ( let b of d ) { if ( ! b || ! b . slot ) { c && l . appendChild ( b ) ; continue } let i = b . slot , f = o [ i ] ; _ ( b , "remove" , "slot" ) , f && ( re ( f , b , n ) , Reflect . deleteProperty ( o , i ) ) } return c && ( o [ r ] . replaceWith ( l ) , Reflect . deleteProperty ( o , r ) ) , e . append = s , e } } ) , e !== t ) { let s = Array . from ( e . childNodes ) ; s . forEach ( u => u . remove ( ) ) , e . append ( ... s ) } return t } function re ( e , t , n ) { n && n ( e , t ) ; try { e . replaceWith ( A ( t , { className : [ t . className , e . className ] , dataset : { ... e . dataset } } ) ) } catch { e . replaceWith ( t ) } } R . mark = function ( e , t = ! 1 ) { e = Object . entries ( e ) . map ( ( [ o , c ] ) => o + ` =" ${ c } " ` ) . join ( " " ) ; let n = t ? "" : "/" , r = document . createComment ( ` <dde:mark ${ e } ${ $ . ssr } ${ n } > ` ) ; return t || ( r . end = document . createComment ( "</dde:mark>" ) ) , r } ; function _e ( e ) { let t = this ; return function ( ... r ) { L = e ; let o = R . call ( t , ... r ) ; return L = void 0 , o } } var { setDeleteAttr : I } = $ , j = new WeakMap ; function A ( e , ... t ) { if ( ! t . length ) return e ; j . set ( e , G ( e , this ) ) ; for ( let [ n , r ] of Object . entries ( Object . assign ( { } , ... t ) ) ) Z . call ( this , e , n , r ) ; return j . delete ( e ) , e } function Z ( e , t , n ) { let { setRemoveAttr : r , s : o } = G ( e , this ) , c = this ; n = o . processReactiveAttribute ( e , t , n , ( u , d ) => Z . call ( c , e , u , d ) ) ; let [ s ] = t ; if ( s === "=" ) return r ( t . slice ( 1 ) , n ) ; if ( s === "." ) return J ( e , t . slice ( 1 ) , n ) ; if ( /(aria|data)([A-Z])/ . test ( t ) ) return t = t . replace ( /([a-z])([A-Z])/g , "$1-$2" ) . toLowerCase ( ) , r ( t , n ) ; switch ( t === "className" && ( t = "class" ) , t ) { case "xlink:href" : return r ( t , n , "http://www.w3.org/1999/xlink" ) ; case "textContent" : return I ( e , t , n ) ; case "style" : if ( typeof n != "object" ) break ; case "dataset" : return F ( o , n , J . bind ( null , e [ t ] ) ) ; case "ariaset" : return F ( o , n , ( u , d ) => r ( "aria-" + u , d ) ) ; case "classList" : return oe . call ( c , e , n ) } return ce ( e , t ) ? I ( e , t , n ) : r ( t , n ) } function G ( e , t ) { if ( j . has ( e ) ) return j . get ( e ) ; let r = ( e instanceof SVGElement ? ie : se ) . bind ( null , e , "Attribute" ) , o = N ( t ) ; return { setRemoveAttr : r , s : o } } function oe ( e , t ) { let n = N ( this ) ; return F ( n , t , ( r , o ) => e . classList . toggle ( r
* Investigate ` __dde_attributes ` key of the element . * / m . c l e a r ( . . . O b j e c t . v a l u e s ( r [ S ] ) ) } ) ( r ) } ) , n e w P r o x y ( n , { a p p l y ( o , c , s ) { i f ( ! s . l e n g t h ) r e t u r n o ( ) ; l e t u = s [ 0 ] ; r e t u r n _ ( r , " s e t " , e , u ) } } ) } ; v a r Y = { i s O b s e r v a b l e : W , p r o c e s s R e a c t i v e A t t r i b u t e ( e , t , n , r ) { i f ( ! W ( n ) ) r e t u r n n ; l e t o = c = > r ( t , c ) ; r e t u r n U ( n , o ) , e e ( n , o , e , t ) , n ( ) } } ; f u n c t i o n e e ( e , t , . . . n ) { l e t { c u r r e n t : r } = p ; r . p r e v e n t | | r . h o s t ( f u n c t i o n ( o ) { o [ k ] | | ( o [ k ] = [ ] , E . d i s c o n n e c t e d ( ( ) = > o [ k ] . f o r E a c h ( ( [ [ c , s ] ] ) = > C ( c , s , c [ h ] ? . h o s t ( ) = = = o ) ) ) ( o ) ) , o [ k ] . p u s h ( [ [ e , t ] , . . . n ] ) } ) } f u n c t i o n X ( e , t ) { l e t n = ( . . . r ) = > r . l e n g t h ? h e ( n , . . . r ) : p e ( n ) ; r e t u r n d e ( n , e , t ) } v a r a e = O b j e c t . a s s i g n ( O b j e c t . c r e a t e ( n u l l ) , { s t o p P r o p a g a t i o n ( ) { t h i s . s k i p = ! 0 } } ) , q = c l a s s e x t e n d s E r r o r { c o n s t r u c t o r ( ) { s u p e r ( ) ; l e t [ t , . . . n ] = t h i s . s t a c k . s p l i t ( `
` ),r=t.slice(t.indexOf("@"),t.indexOf(".js:")+4);this.stack=n.find(o=>!o.includes(r))}};function de(e,t,n){let r=[];B(n)!=="[object Object]"&&(n={});let{onclear:o}=m.symbols;n[o]&&(r.push(n[o]),Reflect.deleteProperty(n,o));let{host:c}=p;return Reflect.defineProperty(e,h,{value:{value:t,actions:n,onclear:r,host:c,listeners:new Set,defined:new q},enumerable:!1,writable:!1,configurable:!0}),e.toJSON=()=>e(),Object.setPrototypeOf(e[h],ae),e}function le(){return T[T.length-1]}function pe(e){if(!e[h])return;let{value:t,listeners:n}=e[h],r=le();return r&&n.add(r),g.has(r)&&g.get(r).add(e),t}function he(e,t,n){if(!e[h])return;let r=e[h];if(!(!n&&r.value===t))return r.value=t,r.listeners.forEach(o=>o(t)),t}function U(e,t){if(e[h])return e[h].listeners.add(t)}function C(e,t,n){let r=e[h];if(!r)return;let o=r.listeners.delete(t);if(n&&!r.listeners.size){if(e.clear(e),!g.has(r))return o;let c=g.get(r);if(!g.has(c))return o;g.get(c).forEach(s=>C(s,c,!0))}return o}M(Y);export{m as O,A as assign,Z as assignAttribute,ne as chainableAppend,oe as classListDeclarative,R as createElement,_e as createElementNS,Se as customElementRender,Ce as customElementWithDDE,Pe as dispatchEvent,R as el,_e as elNS,_ as elementAttribute,Oe as empty,W as isObservable,Ce as lifecycleToEvents,m as observable,E as on,M as registerReactivity,p as scope,xe as simulateSlots};