@vonage/vivid 5.20.0 → 5.20.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,4 +1,4 @@
1
1
  var e,t=`fast-kernel`;try{if(document.currentScript)e=document.currentScript.getAttribute(t);else{let n=document.getElementsByTagName(`script`);e=n[n.length-1].getAttribute(t)}}catch{e=`isolate`}var n;switch(e){case`share`:n=Object.freeze({updateQueue:1,observable:2,contextEvent:3,elementRegistry:4});break;case`share-v2`:n=Object.freeze({updateQueue:1.2,observable:2.2,contextEvent:3.2,elementRegistry:4.2});break;default:let e=`-${Math.random().toString(36).substring(2,8)}`;n=Object.freeze({updateQueue:`1.2${e}`,observable:`2.2${e}`,contextEvent:`3.2${e}`,elementRegistry:`4.2${e}`});break}var r;(function(e){e[e.needsArrayObservation=1101]=`needsArrayObservation`,e[e.onlySetDOMPolicyOnce=1201]=`onlySetDOMPolicyOnce`,e[e.bindingInnerHTMLRequiresTrustedTypes=1202]=`bindingInnerHTMLRequiresTrustedTypes`,e[e.twoWayBindingRequiresObservables=1203]=`twoWayBindingRequiresObservables`,e[e.hostBindingWithoutHost=1204]=`hostBindingWithoutHost`,e[e.unsupportedBindingBehavior=1205]=`unsupportedBindingBehavior`,e[e.directCallToHTMLTagNotAllowed=1206]=`directCallToHTMLTagNotAllowed`,e[e.onlySetTemplatePolicyOnce=1207]=`onlySetTemplatePolicyOnce`,e[e.cannotSetTemplatePolicyAfterCompilation=1208]=`cannotSetTemplatePolicyAfterCompilation`,e[e.blockedByDOMPolicy=1209]=`blockedByDOMPolicy`,e[e.missingElementDefinition=1401]=`missingElementDefinition`,e[e.noRegistrationForContext=1501]=`noRegistrationForContext`,e[e.noFactoryForResolver=1502]=`noFactoryForResolver`,e[e.invalidResolverStrategy=1503]=`invalidResolverStrategy`,e[e.cannotAutoregisterDependency=1504]=`cannotAutoregisterDependency`,e[e.cannotResolveKey=1505]=`cannotResolveKey`,e[e.cannotConstructNativeFunction=1506]=`cannotConstructNativeFunction`,e[e.cannotJITRegisterNonConstructor=1507]=`cannotJITRegisterNonConstructor`,e[e.cannotJITRegisterIntrinsic=1508]=`cannotJITRegisterIntrinsic`,e[e.cannotJITRegisterInterface=1509]=`cannotJITRegisterInterface`,e[e.invalidResolver=1510]=`invalidResolver`,e[e.invalidKey=1511]=`invalidKey`,e[e.noDefaultResolver=1512]=`noDefaultResolver`,e[e.cyclicDependency=1513]=`cyclicDependency`,e[e.connectUpdateRequiresController=1514]=`connectUpdateRequiresController`})(r||={});var i=e=>typeof e==`function`,a=e=>typeof e==`string`,o=()=>void 0;(function(){if(!(typeof globalThis<`u`))if(typeof global<`u`)global.globalThis=global;else if(typeof self<`u`)self.globalThis=self;else if(typeof window<`u`)window.globalThis=window;else{let e=Function(`return this`)();e.globalThis=e}})(),(function(){`requestIdleCallback`in globalThis||(globalThis.requestIdleCallback=function(e,t){let n=Date.now();return setTimeout(()=>{e({didTimeout:t?.timeout?Date.now()-n>=t.timeout:!1,timeRemaining:()=>0})},1)},globalThis.cancelIdleCallback=function(e){clearTimeout(e)})})();var s={configurable:!1,enumerable:!1,writable:!1};globalThis.FAST===void 0&&Reflect.defineProperty(globalThis,`FAST`,Object.assign({value:Object.create(null)},s));var c=globalThis.FAST;if(c.getById===void 0){let e=Object.create(null);Reflect.defineProperty(c,`getById`,Object.assign({value(t,n){let r=e[t];return r===void 0&&(r=n?e[t]=n():null),r}},s))}c.error===void 0&&Object.assign(c,{warn(){},error(e){return Error(`Error ${e}`)},addMessages(){}});var l=Object.freeze([]);function u(){let e=new Map;return Object.freeze({register(t){return e.has(t.type)?!1:(e.set(t.type,t),!0)},getByType(t){return e.get(t)},getForInstance(t){if(t!=null)return e.get(t.constructor)}})}function d(){let e=new WeakMap;return function(t){let n=e.get(t);if(n===void 0){let r=Reflect.getPrototypeOf(t);for(;n===void 0&&r!==null;)n=e.get(r),r=Reflect.getPrototypeOf(r);n=n===void 0?[]:n.slice(0),e.set(t,n)}return n}}function f(e){e.prototype.toJSON=o}var p=Object.freeze({none:0,attribute:1,booleanAttribute:2,property:3,content:4,tokenList:5,event:6}),m=e=>e,ee=globalThis.trustedTypes?globalThis.trustedTypes.createPolicy(`fast-html`,{createHTML:m}):{createHTML:m},h=Object.freeze({createHTML(e){return ee.createHTML(e)},protect(e,t,n,r){return r}}),te=h,g=Object.freeze({get policy(){return h},setPolicy(e){if(h!==te)throw c.error(r.onlySetDOMPolicyOnce);h=e},setAttribute(e,t,n){n==null?e.removeAttribute(t):e.setAttribute(t,n)},setBooleanAttribute(e,t,n){n?e.setAttribute(t,``):e.removeAttribute(t)}}),_=class{constructor(e,t){this.sub1=void 0,this.sub2=void 0,this.spillover=void 0,this.subject=e,this.sub1=t}has(e){return this.spillover===void 0?this.sub1===e||this.sub2===e:this.spillover.indexOf(e)!==-1}subscribe(e){let t=this.spillover;if(t===void 0){if(this.has(e))return;if(this.sub1===void 0){this.sub1=e;return}if(this.sub2===void 0){this.sub2=e;return}this.spillover=[this.sub1,this.sub2,e],this.sub1=void 0,this.sub2=void 0}else t.indexOf(e)===-1&&t.push(e)}unsubscribe(e){let t=this.spillover;if(t===void 0)this.sub1===e?this.sub1=void 0:this.sub2===e&&(this.sub2=void 0);else{let n=t.indexOf(e);n!==-1&&t.splice(n,1)}}notify(e){let t=this.spillover,n=this.subject;if(t===void 0){let t=this.sub1,r=this.sub2;t!==void 0&&t.handleChange(n,e),r!==void 0&&r.handleChange(n,e)}else for(let r=0,i=t.length;r<i;++r)t[r].handleChange(n,e)}},ne=class{constructor(e){this.subscribers={},this.subjectSubscribers=null,this.subject=e}notify(e){var t,n;(t=this.subscribers[e])==null||t.notify(e),(n=this.subjectSubscribers)==null||n.notify(e)}subscribe(e,t){let n;n=t?this.subscribers[t]??(this.subscribers[t]=new _(this.subject)):this.subjectSubscribers??=new _(this.subject),n.subscribe(e)}unsubscribe(e,t){var n,r;t?(n=this.subscribers[t])==null||n.unsubscribe(e):(r=this.subjectSubscribers)==null||r.unsubscribe(e)}},re=c.getById(n.updateQueue,()=>{let e=[],t=[],n=globalThis.requestAnimationFrame,r=!0;function i(){if(t.length)throw t.shift()}function a(n){try{n.call()}catch(n){if(r)t.push(n),setTimeout(i,0);else throw e.length=0,n}}function o(){let t=0;for(;t<e.length;)if(a(e[t]),t++,t>1024){for(let n=0,r=e.length-t;n<r;n++)e[n]=e[n+t];e.length-=t,t=0}e.length=0}function s(t){e.push(t),e.length<2&&(r?n(o):o())}return Object.freeze({enqueue:s,next:()=>new Promise(s),process:o,setMode:e=>r=e})}),v=Object.freeze({unknown:void 0,coupled:1}),y=c.getById(n.observable,()=>{let e=re.enqueue,t=/(:|&&|\|\||if|\?\.)/,n=new WeakMap,o,s=e=>{throw c.error(r.needsArrayObservation)};function l(e){let t=e.$fastController??n.get(e);return t===void 0&&(Array.isArray(e)?t=s(e):n.set(e,t=new ne(e))),t}let u=d();class p{constructor(e){this.name=e,this.field=`_${e}`,this.callback=`${e}Changed`}getValue(e){return o!==void 0&&o.watch(e,this.name),e[this.field]}setValue(e,t){let n=this.field,r=e[n];if(r!==t){e[n]=t;let a=e[this.callback];i(a)&&a.call(e,r,t),l(e).notify(this.name)}}}class m extends _{constructor(e,t,n=!1){super(e,t),this.expression=e,this.isVolatileBinding=n,this.needsRefresh=!0,this.needsQueue=!0,this.isAsync=!0,this.first=this,this.last=null,this.propertySource=void 0,this.propertyName=void 0,this.notifier=void 0,this.next=void 0}setMode(e){this.isAsync=this.needsQueue=e}bind(e){this.controller=e;let t=this.observe(e.source,e.context);return!e.isBound&&this.requiresUnbind(e)&&e.onUnbind(this),t}requiresUnbind(e){return e.sourceLifetime!==v.coupled||this.first!==this.last||this.first.propertySource!==e.source}unbind(e){this.dispose()}observe(e,t){this.needsRefresh&&this.last!==null&&this.dispose();let n=o;o=this.needsRefresh?this:void 0,this.needsRefresh=this.isVolatileBinding;let r;try{r=this.expression(e,t)}finally{o=n}return r}disconnect(){this.dispose()}dispose(){if(this.last!==null){let e=this.first;for(;e!==void 0;)e.notifier.unsubscribe(this,e.propertyName),e=e.next;this.last=null,this.needsRefresh=this.needsQueue=this.isAsync}}watch(e,t){let n=this.last,r=l(e),i=n===null?this.first:{};if(i.propertySource=e,i.propertyName=t,i.notifier=r,r.subscribe(this,t),n!==null){if(!this.needsRefresh){let t;o=void 0,t=n.propertySource[n.propertyName],o=this,e===t&&(this.needsRefresh=!0)}n.next=i}this.last=i}handleChange(){this.needsQueue?(this.needsQueue=!1,e(this)):this.isAsync||this.call()}call(){this.last!==null&&(this.needsQueue=this.isAsync,this.notify(this))}*records(){let e=this.first;for(;e!==void 0;)yield e,e=e.next}}return f(m),Object.freeze({setArrayObserverFactory(e){s=e},getNotifier:l,track(e,t){o&&o.watch(e,t)},trackVolatile(){o&&(o.needsRefresh=!0)},notify(e,t){l(e).notify(t)},defineProperty(e,t){a(t)&&(t=new p(t)),u(e).push(t),Reflect.defineProperty(e,t.name,{enumerable:!0,get(){return t.getValue(this)},set(e){t.setValue(this,e)}})},getAccessors:u,binding(e,t,n=this.isVolatileBinding(e)){return new m(e,t,n)},isVolatileBinding(e){return t.test(e.toString())}})});function ie(e,t){y.defineProperty(e,t)}function ae(e,t,n){return Object.assign({},n,{get(){return y.trackVolatile(),n.get.apply(this)}})}var oe=c.getById(n.contextEvent,()=>{let e=null;return{get(){return e},set(t){e=t}}}),b=Object.freeze({default:{index:0,length:0,get event(){return b.getEvent()},eventDetail(){return this.event.detail},eventTarget(){return this.event.target}},getEvent(){return oe.get()},setEvent(e){oe.set(e)}}),x=class{constructor(e,t,n=!1){this.evaluate=e,this.policy=t,this.isVolatile=n}},se=class extends x{createObserver(e){return y.binding(this.evaluate,e,this.isVolatile)}};function S(e,t,n=y.isVolatileBinding(e)){return new se(e,t,n)}var ce=class extends x{createObserver(){return this}bind(e){return this.evaluate(e.source,e.context)}};f(ce);function C(e,t){return new ce(e,t)}var le;function ue(e){return e.map(e=>e instanceof w?ue(e.styles):[e]).reduce((e,t)=>e.concat(t),[])}var w=class e{get strategy(){return this._strategy===null&&this.withStrategy(le),this._strategy}constructor(t){this.styles=t,this.targets=new WeakSet,this._strategy=null,this.behaviors=t.map(t=>t instanceof e?t.behaviors:null).reduce((e,t)=>t===null?e:e===null?t:e.concat(t),null)}addStylesTo(e){this.strategy.addStylesTo(e),this.targets.add(e)}removeStylesFrom(e){this.strategy.removeStylesFrom(e),this.targets.delete(e)}isAttachedTo(e){return this.targets.has(e)}withBehaviors(...e){return this.behaviors=this.behaviors===null?e:this.behaviors.concat(e),this}withStrategy(e){return this._strategy=new e(ue(this.styles)),this}static setDefaultStrategy(e){le=e}static normalize(t){return t===void 0?void 0:Array.isArray(t)?new e(t):t instanceof e?t:new e([t])}};w.supportsAdoptedStyleSheets=Array.isArray(document.adoptedStyleSheets)&&`replace`in CSSStyleSheet.prototype;var T=`fast-${Math.random().toString(36).substring(2,8)}`,E=`${T}{`,D=`}${T}`,de=D.length,fe=0,O=()=>`${T}-${++fe}`,pe=Object.freeze({interpolation:e=>`${E}${e}${D}`,attribute:e=>`${O()}="${E}${e}${D}"`,comment:e=>`<!--${E}${e}${D}-->`}),k=Object.freeze({parse(e,t){let n=e.split(E);if(n.length===1)return null;let r=[];for(let e=0,i=n.length;e<i;++e){let i=n[e],a=i.indexOf(D),o;if(a===-1)o=i;else{let e=i.substring(0,a);r.push(t[e]),o=i.substring(a+de)}o!==``&&r.push(o)}return r}}),me=u(),A=Object.freeze({getForInstance:me.getForInstance,getByType:me.getByType,define(e,t){return t||={},t.type=e,me.register(t),e},assignAspect(e,t){if(!t){e.aspectType=p.content;return}switch(e.sourceAspect=t,t[0]){case`:`:e.targetAspect=t.substring(1),e.aspectType=e.targetAspect===`classList`?p.tokenList:p.property;break;case`?`:e.targetAspect=t.substring(1),e.aspectType=p.booleanAttribute;break;case`@`:e.targetAspect=t.substring(1),e.aspectType=p.event;break;default:e.targetAspect=t,e.aspectType=p.attribute;break}}}),he=class{constructor(e){this.options=e}createHTML(e){return pe.attribute(e(this))}createBehavior(){return this}};f(he);var ge=/fe-b\$\$start\$\$(\d+)\$\$(.+)\$\$fe-b/,_e=/fe-b\$\$end\$\$(\d+)\$\$(.+)\$\$fe-b/,ve=/fe-repeat\$\$start\$\$(\d+)\$\$fe-repeat/,ye=/fe-repeat\$\$end\$\$(\d+)\$\$fe-repeat/,be=/^(?:.{0,1000})fe-eb\$\$start\$\$(.+?)\$\$fe-eb/,xe=/fe-eb\$\$end\$\$(.{0,1000})\$\$fe-eb(?:.{0,1000})$/;function Se(e){return e&&e.nodeType===Node.COMMENT_NODE}var j=Object.freeze({attributeMarkerName:`data-fe-b`,compactAttributeMarkerName:`data-fe-c`,attributeBindingSeparator:` `,contentBindingStartMarker(e,t){return`fe-b$$start$$${e}$$${t}$$fe-b`},contentBindingEndMarker(e,t){return`fe-b$$end$$${e}$$${t}$$fe-b`},repeatStartMarker(e){return`fe-repeat$$start$$${e}$$fe-repeat`},repeatEndMarker(e){return`fe-repeat$$end$$${e}$$fe-repeat`},isContentBindingStartMarker(e){return ge.test(e)},isContentBindingEndMarker(e){return _e.test(e)},isRepeatViewStartMarker(e){return ve.test(e)},isRepeatViewEndMarker(e){return ye.test(e)},isElementBoundaryStartMarker(e){return Se(e)&&be.test(e.data.trim())},isElementBoundaryEndMarker(e){return Se(e)&&xe.test(e.data)},parseAttributeBinding(e){let t=e.getAttribute(this.attributeMarkerName);return t===null?t:t.split(this.attributeBindingSeparator).map(e=>parseInt(e))},parseEnumeratedAttributeBinding(e){let t=[],n=this.attributeMarkerName.length+1,r=`${this.attributeMarkerName}-`;for(let i of e.getAttributeNames())if(i.startsWith(r)){let e=Number(i.slice(n));if(!Number.isNaN(e))t.push(e);else throw c.error(1601,{name:i,expectedFormat:`${r}<number>`})}return t.length===0?null:t},parseCompactAttributeBinding(e){let t=`${this.compactAttributeMarkerName}-`,n=e.getAttributeNames().find(e=>e.startsWith(t));if(!n)return null;let r=n.slice(t.length).split(`-`),i=parseInt(r[0],10),a=parseInt(r[1],10);if(r.length!==2||Number.isNaN(i)||Number.isNaN(a)||i<0||a<1)throw c.error(1604,{name:n,expectedFormat:`${this.compactAttributeMarkerName}-{index}-{count}`});let o=[];for(let e=0;e<a;e++)o.push(i+e);return o},parseContentBindingStartMarker(e){return Te(ge,e)},parseContentBindingEndMarker(e){return Te(_e,e)},parseRepeatStartMarker(e){return Ce(ve,e)},parseRepeatEndMarker(e){return Ce(ye,e)},parseElementBoundaryStartMarker(e){return we(be,e.trim())},parseElementBoundaryEndMarker(e){return we(xe,e)}});function Ce(e,t){let n=e.exec(t);return n===null?n:parseInt(n[1])}function we(e,t){let n=e.exec(t);return n===null?n:n[1]}function Te(e,t){let n=e.exec(t);return n===null?n:[parseInt(n[1]),n[2]]}var M=Symbol.for(`fe-hydration`);function N(e){return e[M]===M}var Ee=`defer-hydration`,De=class extends Error{constructor(e,t,n){super(e),this.factories=t,this.node=n}};function Oe(e){return e.nodeType===Node.COMMENT_NODE}function ke(e){return e.nodeType===Node.TEXT_NODE}function Ae(e,t){let n=document.createRange();return n.setStart(e,0),n.setEnd(t,Oe(t)||ke(t)?t.data.length:t.childNodes.length),n}function je(e){return e instanceof DocumentFragment&&`mode`in e}function Me(e,t,n){let r=Ae(e,t),i=r.commonAncestorContainer,a=Ie(n),o=document.createTreeWalker(i,NodeFilter.SHOW_ELEMENT+NodeFilter.SHOW_COMMENT+NodeFilter.SHOW_TEXT,{acceptNode(e){return r.comparePoint(e,0)===0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_REJECT}}),s={},c={},l=o.currentNode=e;for(;l!==null;){switch(l.nodeType){case Node.ELEMENT_NODE:Ne(l,n,s,a);break;case Node.COMMENT_NODE:Pe(l,o,n,s,c,a);break}l=o.nextNode()}return r.detach(),{targets:s,boundaries:c}}function Ne(e,t,n,r){let i=j.parseAttributeBinding(e)??j.parseEnumeratedAttributeBinding(e)??j.parseCompactAttributeBinding(e);if(i!==null){for(let a of i){let i=t[a+r];if(!i)throw new De(`HydrationView was unable to successfully target factory on ${e.nodeName} inside ${e.getRootNode().host.nodeName}. This likely indicates a template mismatch between SSR rendering and hydration.`,t,e);P(i,e,n)}e.removeAttribute(j.attributeMarkerName)}}function Pe(e,t,n,r,i,a){if(j.isElementBoundaryStartMarker(e)){Fe(e,t);return}if(j.isContentBindingStartMarker(e.data)){let o=j.parseContentBindingStartMarker(e.data);if(o===null)return;let[s,c]=o,l=n[s+a],u=[],d=t.nextSibling();e.data=``;let f=d;for(;d!==null;){if(Oe(d)){let e=j.parseContentBindingEndMarker(d.data);if(e&&e[1]===c)break}u.push(d),d=t.nextSibling()}if(d===null){let t=e.getRootNode();throw Error(`Error hydrating Comment node inside "${je(t)?t.host.nodeName:t.nodeName}".`)}d.data=``,u.length===1&&ke(u[0])?P(l,u[0],r):(d!==f&&d.previousSibling!==null&&(i[l.targetNodeId]={first:f,last:d.previousSibling}),P(l,d.parentNode.insertBefore(document.createTextNode(``),d),r))}}function Fe(e,t){let n=j.parseElementBoundaryStartMarker(e.data),r=t.nextSibling();for(;r!==null;){if(Oe(r)){let e=j.parseElementBoundaryEndMarker(r.data);if(e&&e===n)break}r=t.nextSibling()}}function Ie(e){let t=0;for(let n=0,r=e.length;n<r&&e[n].targetNodeId===`h`;++n)t++;return t}function P(e,t,n){if(e.targetNodeId===void 0)throw Error(`Factory could not be target to the node`);n[e.targetNodeId]=t}var Le;function Re(e,t){let n=e.parentNode,r=e,i;for(;r!==t;){if(i=r.nextSibling,!i)throw Error(`Unmatched first/last child inside "${t.getRootNode().host.nodeName}".`);n.removeChild(r),r=i}n.removeChild(t)}var ze=class{constructor(){this.index=0,this.length=0}get event(){return b.getEvent()}get isEven(){return this.index%2==0}get isOdd(){return this.index%2!=0}get isFirst(){return this.index===0}get isInMiddle(){return!this.isFirst&&!this.isLast}get isLast(){return this.index===this.length-1}eventDetail(){return this.event.detail}eventTarget(){return this.event.target}},F=class extends ze{constructor(e,t,n){super(),this.fragment=e,this.factories=t,this.targets=n,this.behaviors=null,this.unbindables=[],this.source=null,this.isBound=!1,this.sourceLifetime=v.unknown,this.context=this,this.firstChild=e.firstChild,this.lastChild=e.lastChild}appendTo(e){e.appendChild(this.fragment)}insertBefore(e){if(this.fragment.hasChildNodes())e.parentNode.insertBefore(this.fragment,e);else{let t=this.lastChild;if(e.previousSibling===t)return;let n=e.parentNode,r=this.firstChild,i;for(;r!==t;)i=r.nextSibling,n.insertBefore(r,e),r=i;n.insertBefore(t,e)}}remove(){let e=this.fragment,t=this.lastChild,n=this.firstChild,r;for(;n!==t;)r=n.nextSibling,e.appendChild(n),n=r;e.appendChild(t)}dispose(){Re(this.firstChild,this.lastChild),this.unbind()}onUnbind(e){this.unbindables.push(e)}bind(e,t=this){if(this.source===e)return;let n=this.behaviors;if(n===null){this.source=e,this.context=t,this.behaviors=n=Array(this.factories.length);let r=this.factories;for(let e=0,t=r.length;e<t;++e){let t=r[e].createBehavior();t.bind(this),n[e]=t}}else{this.source!==null&&this.evaluateUnbindables(),this.isBound=!1,this.source=e,this.context=t;for(let e=0,t=n.length;e<t;++e)n[e].bind(this)}this.isBound=!0}unbind(){!this.isBound||this.source===null||(this.evaluateUnbindables(),this.source=null,this.context=this,this.isBound=!1)}evaluateUnbindables(){let e=this.unbindables;for(let t=0,n=e.length;t<n;++t)e[t].unbind(this);e.length=0}static disposeContiguousBatch(e){if(e.length!==0){Re(e[0].firstChild,e[e.length-1].lastChild);for(let t=0,n=e.length;t<n;++t)e[t].unbind()}}};f(F),y.defineProperty(F.prototype,`index`),y.defineProperty(F.prototype,`length`);var I={unhydrated:`unhydrated`,hydrating:`hydrating`,hydrated:`hydrated`},Be=class extends Error{constructor(e,t,n,r){super(e),this.factory=t,this.fragment=n,this.templateString=r}},Ve=class extends ze{get hydrationStage(){return this._hydrationStage}get targets(){return this._targets}get bindingViewBoundaries(){return this._bindingViewBoundaries}constructor(e,t,n,r){super(),this.firstChild=e,this.lastChild=t,this.sourceTemplate=n,this.hostBindingTarget=r,this[Le]=M,this.context=this,this.source=null,this.isBound=!1,this.sourceLifetime=v.unknown,this.unbindables=[],this.fragment=null,this.behaviors=null,this._hydrationStage=I.unhydrated,this._bindingViewBoundaries={},this._targets={},this.factories=n.compile().factories}insertBefore(e){if(this.fragment!==null)if(this.fragment.hasChildNodes())e.parentNode.insertBefore(this.fragment,e);else{let t=this.lastChild;if(e.previousSibling===t)return;let n=e.parentNode,r=this.firstChild,i;for(;r!==t;)i=r.nextSibling,n.insertBefore(r,e),r=i;n.insertBefore(t,e)}}appendTo(e){this.fragment!==null&&e.appendChild(this.fragment)}remove(){let e=this.fragment||=document.createDocumentFragment(),t=this.lastChild,n=this.firstChild,r;for(;n!==t;){if(r=n.nextSibling,!r)throw Error(`Unmatched first/last child inside "${t.getRootNode().host.nodeName}".`);e.appendChild(n),n=r}e.appendChild(t)}bind(e,t=this){if(this.hydrationStage!==I.hydrated&&(this._hydrationStage=I.hydrating),this.source===e)return;let n=this.behaviors;if(n===null){this.source=e,this.context=t;try{let{targets:e,boundaries:t}=Me(this.firstChild,this.lastChild,this.factories);this._targets=e,this._bindingViewBoundaries=t}catch(e){if(e instanceof De){let t=this.sourceTemplate.html;typeof t!=`string`&&(t=t.innerHTML),e.templateString=t}throw e}this.behaviors=n=Array(this.factories.length);let r=this.factories;for(let e=0,t=r.length;e<t;++e){let t=r[e];if(t.targetNodeId===`h`&&this.hostBindingTarget&&P(t,this.hostBindingTarget,this._targets),t.targetNodeId in this.targets){let r=t.createBehavior();r.bind(this),n[e]=r}else{let e=this.sourceTemplate.html;typeof e!=`string`&&(e=e.innerHTML);let n=(this.firstChild?.getRootNode()).host?.nodeName||`unknown`,r=t,i=[`HydrationView was unable to successfully target bindings inside "<${n.toLowerCase()}>".`,`
2
2
  Mismatch Details:`,` - Expected target node ID: "${t.targetNodeId}"`,` - Available target IDs: [${Object.keys(this.targets).join(`, `)||`none`}]`];throw t.targetTagName&&i.push(` - Expected tag name: "${t.targetTagName}"`),r.sourceAspect&&i.push(` - Source aspect: "${r.sourceAspect}"`),r.aspectType!==void 0&&i.push(` - Aspect type: ${r.aspectType}`),i.push(`
3
3
  This usually means:`,` 1. The server-rendered HTML doesn't match the client template`,` 2. The hydration markers are missing or corrupted`,` 3. The DOM structure was modified before hydration`,`\nTemplate: ${e.slice(0,200)}${e.length>200?`...`:``}`),new Be(i.join(`
4
- `),t,Ae(this.firstChild,this.lastChild).cloneContents(),e)}}}else{this.source!==null&&this.evaluateUnbindables(),this.isBound=!1,this.source=e,this.context=t;for(let e=0,t=n.length;e<t;++e)n[e].bind(this)}this.isBound=!0,this._hydrationStage=I.hydrated}unbind(){!this.isBound||this.source===null||(this.evaluateUnbindables(),this.source=null,this.context=this,this.isBound=!1)}dispose(){Re(this.firstChild,this.lastChild),this.unbind()}onUnbind(e){this.unbindables.push(e)}evaluateUnbindables(){let e=this.unbindables;for(let t=0,n=e.length;t<n;++t)e[t].unbind(this);e.length=0}};Le=M,f(Ve);function He(e){return e.create!==void 0}function Ue(e,t,n,r){if(n??=``,He(n)){e.textContent=``;let t=e.$fastView;if(t===void 0)if(N(r)&&N(n)&&r.bindingViewBoundaries[this.targetNodeId]!==void 0&&r.hydrationStage!==I.hydrated){let e=r.bindingViewBoundaries[this.targetNodeId];t=n.hydrate(e.first,e.last)}else t=n.create();else e.$fastTemplate!==n&&(t.isComposed&&(t.remove(),t.unbind()),t=n.create());t.isComposed?t.needsBindOnly&&(t.needsBindOnly=!1,t.bind(r.source,r.context)):(t.isComposed=!0,t.bind(r.source,r.context),t.insertBefore(e),e.$fastView=t,e.$fastTemplate=n)}else{let t=e.$fastView;t!==void 0&&t.isComposed&&(t.isComposed=!1,t.remove(),t.needsBindOnly?t.needsBindOnly=!1:t.unbind()),e.textContent=n}}function We(e,t,n){let r=`${this.id}-t`,i=e[r]??(e[r]={v:0,cv:Object.create(null)}),a=i.cv,o=i.v,s=e[t];if(n!=null&&n.length){let e=n.split(/\s+/);for(let t=0,n=e.length;t<n;++t){let n=e[t];n!==``&&(a[n]=o,s.add(n))}}if(i.v=o+1,o!==0){--o;for(let e in a)a[e]===o&&s.remove(e)}}var Ge={[p.attribute]:g.setAttribute,[p.booleanAttribute]:g.setBooleanAttribute,[p.property]:(e,t,n)=>e[t]=n,[p.content]:Ue,[p.tokenList]:We,[p.event]:()=>void 0},L=class{constructor(e){this.dataBinding=e,this.updateTarget=null,this.aspectType=p.content}createHTML(e){return pe.interpolation(e(this))}createBehavior(){if(this.updateTarget===null){let e=Ge[this.aspectType],t=this.dataBinding.policy??this.policy;if(!e)throw c.error(r.unsupportedBindingBehavior);this.data=`${this.id}-d`,this.updateTarget=t.protect(this.targetTagName,this.aspectType,this.targetAspect,e)}return this}bind(e){let t=e.targets[this.targetNodeId],n=N(e)&&e.hydrationStage&&e.hydrationStage!==I.hydrated;switch(this.aspectType){case p.event:t[this.data]=e,t.addEventListener(this.targetAspect,this,this.dataBinding.options);break;case p.content:e.onUnbind(this);default:{let r=t[this.data]??(t[this.data]=this.dataBinding.createObserver(this,this));if(r.target=t,r.controller=e,n&&(this.aspectType===p.attribute||this.aspectType===p.booleanAttribute)){r.bind(e);break}this.updateTarget(t,this.targetAspect,r.bind(e),e);break}}}unbind(e){let t=e.targets[this.targetNodeId].$fastView;t!==void 0&&t.isComposed&&(t.unbind(),t.needsBindOnly=!0)}handleEvent(e){let t=e.currentTarget[this.data];if(t.isBound){b.setEvent(e);let n=this.dataBinding.evaluate(t.source,t.context);b.setEvent(null),n!==!0&&e.preventDefault()}}handleChange(e,t){let n=t.controller;if(!n.isBound)return;let r=t.target;this.updateTarget(r,this.targetAspect,t.bind(n),n)}};A.define(L,{aspected:!0});var Ke=(e,t)=>`${e}.${t}`,qe={},R={index:0,node:null};function Je(e){e.startsWith(`fast-`)||c.warn(r.hostBindingWithoutHost,{name:e})}var Ye=new Proxy(document.createElement(`div`),{get(e,t){Je(t);let n=Reflect.get(e,t);return i(n)?n.bind(e):n},set(e,t,n){return Je(t),Reflect.set(e,t,n)}}),Xe=class{constructor(e,t,n){this.fragment=e,this.directives=t,this.policy=n,this.proto=null,this.nodeIds=new Set,this.descriptors={},this.factories=[]}addFactory(e,t,n,r,i){this.nodeIds.has(n)||(this.nodeIds.add(n),this.addTargetDescriptor(t,n,r)),e.id=e.id??O(),e.targetNodeId=n,e.targetTagName=i,e.policy=e.policy??this.policy,this.factories.push(e)}freeze(){return this.proto=Object.create(null,this.descriptors),this}addTargetDescriptor(e,t,n){let r=this.descriptors;if(t===`r`||t===`h`||r[t])return;if(!r[e]){let t=e.lastIndexOf(`.`),n=e.substring(0,t),r=parseInt(e.substring(t+1),10);this.addTargetDescriptor(n,e,r)}let i=qe[t];if(!i){let r=`_${t}`;qe[t]=i={get(){return this[r]??(this[r]=this[e].childNodes[n])}}}r[t]=i}createView(e){let t=this.fragment.cloneNode(!0),n=Object.create(this.proto);n.r=t,n.h=e??Ye;for(let e of this.nodeIds)Reflect.get(n,e);return new F(t,this.factories,n)}};function Ze(e,t,n,r,i,a=!1){let o=n.attributes,s=e.directives;for(let c=0,l=o.length;c<l;++c){let u=o[c],d=u.value,f=k.parse(d,s),p=null;f===null?a&&(p=new L(C(()=>d,e.policy)),A.assignAspect(p,u.name)):p=z.aggregate(f,e.policy),p!==null&&(n.removeAttributeNode(u),c--,l--,e.addFactory(p,t,r,i,n.tagName))}}function Qe(e,t,n,r,i){let o=k.parse(t.textContent,e.directives);if(o===null)return R.node=t.nextSibling,R.index=i+1,R;let s,c=s=t;for(let t=0,l=o.length;t<l;++t){let l=o[t];t!==0&&(i++,r=Ke(n,i),s=c.parentNode.insertBefore(document.createTextNode(``),c.nextSibling)),a(l)?s.textContent=l:(s.textContent=` `,A.assignAspect(l),e.addFactory(l,n,r,i,null)),c=s}return R.index=i+1,R.node=c.nextSibling,R}function $e(e,t,n){let r=0,i=t.firstChild;for(;i;){let t=et(e,n,i,r);i=t.node,r=t.index}}function et(e,t,n,r){let i=Ke(t,r);switch(n.nodeType){case 1:Ze(e,t,n,i,r),$e(e,n,i);break;case 3:return Qe(e,n,t,i,r);case 8:{let a=k.parse(n.data,e.directives);a!==null&&e.addFactory(z.aggregate(a),t,i,r,null);break}}return R.index=r+1,R.node=n.nextSibling,R}function tt(e,t){return e&&e.nodeType===8&&k.parse(e.data,t)!==null}var nt=`TEMPLATE`,z={compile(e,t,n=g.policy){let r;if(a(e)){r=document.createElement(nt),r.innerHTML=n.createHTML(e);let t=r.content.firstElementChild;t!==null&&t.tagName===nt&&(r=t)}else r=e;!r.content.firstChild&&!r.content.lastChild&&r.content.appendChild(document.createComment(``));let i=document.adoptNode(r.content),o=new Xe(i,t,n);return Ze(o,``,r,`h`,0,!0),(tt(i.firstChild,t)||i.childNodes.length===1&&Object.keys(t).length>0)&&i.insertBefore(document.createComment(``),i.firstChild),$e(o,i,`r`),R.node=null,o.freeze()},setDefaultStrategy(e){this.compile=e},aggregate(e,t=g.policy){if(e.length===1)return e[0];let n,r=!1,i,o=e.length,s=e.map(e=>a(e)?()=>e:(n=e.sourceAspect||n,r||=e.dataBinding.isVolatile,i||=e.dataBinding.policy,e.dataBinding.evaluate)),c=new L(S((e,t)=>{let n=``;for(let r=0;r<o;++r)n+=s[r](e,t);return n},i??t,r));return A.assignAspect(c,n),c}},rt=`boolean`,it=`reflect`,at=Object.freeze({locate:d()}),ot={toView(e){return e?`true`:`false`},fromView(e){return!(e==null||e===`false`||e===!1||e===0)}};function st(e){if(e==null)return null;let t=e*1;return isNaN(t)?null:t}var ct={toView(e){let t=st(e);return t&&t.toString()},fromView:st},lt=class e{constructor(e,t,n=t.toLowerCase(),r=it,i){this.guards=new Set,this.Owner=e,this.name=t,this.attribute=n,this.mode=r,this.converter=i,this.fieldName=`_${t}`,this.callbackName=`${t}Changed`,this.hasCallback=this.callbackName in e.prototype,r===rt&&i===void 0&&(this.converter=ot)}setValue(e,t){let n=e[this.fieldName],r=this.converter;r!==void 0&&(t=r.fromView(t)),n!==t&&(e[this.fieldName]=t,this.tryReflectToAttribute(e),this.hasCallback&&e[this.callbackName](n,t),e.$fastController.notify(this.name))}getValue(e){return y.track(e,this.name),e[this.fieldName]}onAttributeChangedCallback(e,t){this.guards.has(e)||(this.guards.add(e),this.setValue(e,t),this.guards.delete(e))}tryReflectToAttribute(e){let t=this.mode,n=this.guards;n.has(e)||t===`fromView`||re.enqueue(()=>{n.add(e);let r=e[this.fieldName];switch(t){case it:let t=this.converter;g.setAttribute(e,this.attribute,t===void 0?r:t.toView(r));break;case rt:g.setBooleanAttribute(e,this.attribute,r);break}n.delete(e)})}static collect(t,...n){let r=[];n.push(at.locate(t));for(let i=0,o=n.length;i<o;++i){let o=n[i];if(o!==void 0)for(let n=0,i=o.length;n<i;++n){let i=o[n];a(i)?r.push(new e(t,i)):r.push(new e(t,i.property,i.attribute,i.mode,i.converter))}}return r}};function ut(e,t){let n;function r(e,t){arguments.length>1&&(n.property=t),at.locate(e.constructor).push(n)}if(arguments.length>1){n={},r(e,t);return}return n=e===void 0?{}:e,r}var dt=function(e,t,n,r){function i(e){return e instanceof n?e:new n(function(t){t(e)})}return new(n||=Promise)(function(n,a){function o(e){try{c(r.next(e))}catch(e){a(e)}}function s(e){try{c(r.throw(e))}catch(e){a(e)}}function c(e){e.done?n(e.value):i(e.value).then(o,s)}c((r=r.apply(e,t||[])).next())})},B,ft={mode:`open`},pt={},V=new Set,H=c.getById(n.elementRegistry,()=>u()),mt={deferAndHydrate:`defer-and-hydrate`},U=class{get isDefined(){return this.platformDefined}constructor(e,t=e.definition){this.platformDefined=!1,a(t)&&(t={name:t}),this.type=e,this.name=t.name,this.template=t.template,this.templateOptions=t.templateOptions,this.registry=t.registry??customElements;let n=e.prototype,r=lt.collect(e,t.attributes),i=Array(r.length),o={},s={};for(let e=0,t=r.length;e<t;++e){let t=r[e];i[e]=t.attribute,o[t.name]=t,s[t.attribute]=t,y.defineProperty(n,t)}Reflect.defineProperty(e,`observedAttributes`,{value:i,enumerable:!0}),this.attributes=r,this.propertyLookup=o,this.attributeLookup=s,this.shadowOptions=t.shadowOptions===void 0?ft:t.shadowOptions===null?void 0:Object.assign(Object.assign({},ft),t.shadowOptions),this.elementOptions=t.elementOptions===void 0?pt:Object.assign(Object.assign({},pt),t.elementOptions),this.styles=w.normalize(t.styles),H.register(this),y.defineProperty(B.isRegistered,this.name),B.isRegistered[this.name]=this.type}define(e=this.registry){var t,n;let r=this.type;return e.get(this.name)||(this.platformDefined=!0,e.define(this.name,r,this.elementOptions),(n=(t=this.lifecycleCallbacks)?.elementDidDefine)==null||n.call(t,this.name)),this}static compose(e,t){return V.has(e)||H.getByType(e)?new B(class extends e{},t):new B(e,t)}static registerBaseType(e){V.add(e)}static composeAsync(e,t){return new Promise(n=>{(V.has(e)||H.getByType(e))&&n(new B(class extends e{},t));let r=new B(e,t);y.getNotifier(r).subscribe({handleChange:()=>{var e,t;(t=(e=r.lifecycleCallbacks)?.templateDidUpdate)==null||t.call(e,r.name),n(r)}},`template`)})}};B=U,U.isRegistered={},U.getByType=H.getByType,U.getForInstance=H.getForInstance,U.registerAsync=e=>dt(void 0,void 0,void 0,function*(){return new Promise(t=>{B.isRegistered[e]&&t(B.isRegistered[e]),y.getNotifier(B.isRegistered).subscribe({handleChange:()=>t(B.isRegistered[e])},e)})}),y.defineProperty(U.prototype,`template`);var ht=/([ \x09\x0a\x0c\x0d])([^\0-\x1F\x7F-\x9F "'>=/]+)([ \x09\x0a\x0c\x0d]*=[ \x09\x0a\x0c\x0d]*(?:[^ \x09\x0a\x0c\x0d"'`<>=]*|"[^"]*|'[^']*))$/,gt=Object.create(null),W=class{constructor(e,t=gt){this.html=e,this.factories=t}createHTML(e){let t=this.factories;for(let n in t)e(t[n]);return this.html}};W.empty=new W(``),A.define(W);function _t(e,t,n,r=A.getForInstance(e)){if(r.aspected){let n=ht.exec(t);n!==null&&A.assignAspect(e,n[2])}return e.createHTML(n)}var vt=class e{constructor(e,t={},n){this.policy=n,this.result=null,this.html=e,this.factories=t}compile(){return this.result===null&&(this.result=z.compile(this.html,this.factories,this.policy)),this.result}create(e){return this.compile().createView(e)}inline(){return new W(a(this.html)?this.html:this.html.innerHTML,this.factories)}withPolicy(e){if(this.result)throw c.error(r.cannotSetTemplatePolicyAfterCompilation);if(this.policy)throw c.error(r.onlySetTemplatePolicyOnce);return this.policy=e,this}render(e,t,n){let r=this.create(n);return r.bind(e),r.appendTo(t),r}static create(t,n,r){let a=``,o=Object.create(null),s=e=>{let t=e.id??=O();return o[t]=e,t};for(let e=0,r=t.length-1;e<r;++e){let r=t[e],o=n[e],c;if(a+=r,i(o))o=new L(S(o));else if(o instanceof x)o=new L(o);else if(!(c=A.getForInstance(o))){let e=o;o=new L(C(()=>e))}a+=_t(o,r,s,c)}return new e(a+t[t.length-1],o,r)}};f(vt);var yt=((e,...t)=>{if(Array.isArray(e)&&Array.isArray(e.raw))return vt.create(e,t);throw c.error(r.directCallToHTMLTagNotAllowed)});yt.partial=e=>new W(e);var bt=class extends MutationObserver{constructor(e){function t(e){this.callback.call(null,e.filter(e=>this.observedNodes.has(e.target)))}super(t),this.callback=e,this.observedNodes=new Set}observe(e,t){this.observedNodes.add(e),super.observe(e,t)}unobserve(e){this.observedNodes.delete(e),this.observedNodes.size<1&&this.disconnect()}},xt=Object.freeze({create(e){let t=[],n={},r=null,i=!1;return{source:e,context:b.default,targets:n,get isBound(){return i},addBehaviorFactory(e,t){let n=e;n.id=n.id??O(),n.targetNodeId=n.targetNodeId??O(),n.targetTagName=t.tagName??null,n.policy=n.policy??g.policy,this.addTarget(n.targetNodeId,t),this.addBehavior(n.createBehavior())},addTarget(e,t){n[e]=t},addBehavior(e){t.push(e),i&&e.bind(this)},onUnbind(e){r===null&&(r=[]),r.push(e)},connectedCallback(e){i||(i=!0,t.forEach(e=>e.bind(this)))},disconnectedCallback(e){i&&(i=!1,r!==null&&r.forEach(e=>e.unbind(this)))}}}}),St={bubbles:!0,composed:!0,cancelable:!0},G=`isConnected`,Ct=new WeakMap;function K(e){return e.shadowRoot??Ct.get(e)??null}var wt,q;(function(e){e[e.connecting=0]=`connecting`,e[e.connected=1]=`connected`,e[e.disconnecting=2]=`disconnecting`,e[e.disconnected=3]=`disconnected`})(q||={});var J=class e extends ne{get isConnected(){return y.track(this,G),this.stage===q.connected}get context(){return this.view?.context??b.default}get isBound(){return this.view?.isBound??!1}get sourceLifetime(){return this.view?.sourceLifetime}get template(){if(this._template===null){let e=this.definition;this.source.resolveTemplate?this._template=this.source.resolveTemplate():e.template&&(this._template=e.template??null)}return this._template}set template(e){this._template!==e&&(this._template=e,this.needsInitialization||this.renderTemplate(e))}get shadowOptions(){return this._shadowRootOptions}set shadowOptions(e){if(this._shadowRootOptions===void 0&&e!==void 0){this._shadowRootOptions=e;let t=this.source.shadowRoot;t?this.hasExistingShadowRoot=!0:(t=this.source.attachShadow(e),e.mode===`closed`&&Ct.set(this.source,t))}}get mainStyles(){if(this._mainStyles===null){let e=this.definition;this.source.resolveStyles?this._mainStyles=this.source.resolveStyles():e.styles&&(this._mainStyles=e.styles??null)}return this._mainStyles}set mainStyles(e){this._mainStyles!==e&&(this._mainStyles!==null&&this.removeStyles(this._mainStyles),this._mainStyles=e,this.needsInitialization||this.addStyles(e))}constructor(e,t){super(e),this.boundObservables=null,this.needsInitialization=!0,this.hasExistingShadowRoot=!1,this._template=null,this.stage=q.disconnected,this.guardBehaviorConnection=!1,this.behaviors=null,this.behaviorsConnected=!1,this._mainStyles=null,this.$fastController=this,this.view=null,this.source=e,this.definition=t,this.shadowOptions=t.shadowOptions;let n=y.getAccessors(e);if(n.length>0){let t=this.boundObservables=Object.create(null);for(let r=0,i=n.length;r<i;++r){let i=n[r].name,a=e[i];a!==void 0&&(delete e[i],t[i]=a)}}}onUnbind(e){var t;(t=this.view)==null||t.onUnbind(e)}addBehavior(e){let t=this.behaviors??=new Map,n=t.get(e)??0;n===0?(t.set(e,1),e.addedCallback&&e.addedCallback(this),e.connectedCallback&&!this.guardBehaviorConnection&&(this.stage===q.connected||this.stage===q.connecting)&&e.connectedCallback(this)):t.set(e,n+1)}removeBehavior(e,t=!1){let n=this.behaviors;if(n===null)return;let r=n.get(e);r!==void 0&&(r===1||t?(n.delete(e),e.disconnectedCallback&&this.stage!==q.disconnected&&e.disconnectedCallback(this),e.removedCallback&&e.removedCallback(this)):n.set(e,r-1))}addStyles(e){if(!e)return;let t=this.source;if(e instanceof HTMLElement)(K(t)??this.source).append(e);else if(!e.isAttachedTo(t)){let n=e.behaviors;if(e.addStylesTo(t),n!==null)for(let e=0,t=n.length;e<t;++e)this.addBehavior(n[e])}}removeStyles(e){if(!e)return;let t=this.source;if(e instanceof HTMLElement)(K(t)??t).removeChild(e);else if(e.isAttachedTo(t)){let n=e.behaviors;if(e.removeStylesFrom(t),n!==null)for(let e=0,t=n.length;e<t;++e)this.removeBehavior(n[e])}}connect(){this.stage===q.disconnected&&(this.stage=q.connecting,this.bindObservables(),this.connectBehaviors(),this.needsInitialization?(this.renderTemplate(this.template),this.addStyles(this.mainStyles),this.needsInitialization=!1):this.view!==null&&this.view.bind(this.source),this.stage=q.connected,y.notify(this,G))}bindObservables(){if(this.boundObservables!==null){let e=this.source,t=this.boundObservables,n=Object.keys(t);for(let r=0,i=n.length;r<i;++r){let i=n[r];e[i]=t[i]}this.boundObservables=null}}connectBehaviors(){if(this.behaviorsConnected===!1){let e=this.behaviors;if(e!==null){this.guardBehaviorConnection=!0;for(let t of e.keys())t.connectedCallback&&t.connectedCallback(this);this.guardBehaviorConnection=!1}this.behaviorsConnected=!0}}disconnectBehaviors(){if(this.behaviorsConnected===!0){let e=this.behaviors;if(e!==null)for(let t of e.keys())t.disconnectedCallback&&t.disconnectedCallback(this);this.behaviorsConnected=!1}}disconnect(){this.stage===q.connected&&(this.stage=q.disconnecting,y.notify(this,G),this.view!==null&&this.view.unbind(),this.disconnectBehaviors(),this.stage=q.disconnected)}onAttributeChangedCallback(e,t,n){let r=this.definition.attributeLookup[e];r!==void 0&&r.onAttributeChangedCallback(this.source,n)}emit(e,t,n){return this.stage===q.connected?this.source.dispatchEvent(new CustomEvent(e,Object.assign(Object.assign({detail:t},St),n))):!1}renderTemplate(e){let t=this.source,n=K(t)??t;if(this.view!==null)this.view.dispose(),this.view=null;else if(!this.needsInitialization||this.hasExistingShadowRoot){this.hasExistingShadowRoot=!1;for(let e=n.firstChild;e!==null;e=n.firstChild)n.removeChild(e)}e&&(this.view=e.render(t,n,t),this.view.sourceLifetime=v.coupled)}static forCustomElement(t,n=!1){let i=t.$fastController;if(i!==void 0&&!n)return i;let a=U.getForInstance(t);if(a===void 0)throw c.error(r.missingElementDefinition);return y.getNotifier(a).subscribe({handleChange:()=>{e.forCustomElement(t,!0),t.$fastController.connect()}},`template`),y.getNotifier(a).subscribe({handleChange:()=>{e.forCustomElement(t,!0),t.$fastController.connect()}},`shadowOptions`),t.$fastController=new wt(t,a)}static setStrategy(e){wt=e}};f(J),J.setStrategy(J);function Y(e){return`adoptedStyleSheets`in e?e:K(e)??e.getRootNode()}var Tt=class e{constructor(t){let n=e.styleSheetCache;this.sheets=t.map(e=>{if(e instanceof CSSStyleSheet)return e;let t=n.get(e);return t===void 0&&(t=new CSSStyleSheet,t.replaceSync(e),n.set(e,t)),t})}addStylesTo(e){At(Y(e),this.sheets)}removeStylesFrom(e){jt(Y(e),this.sheets)}};Tt.styleSheetCache=new Map;var Et=0,Dt=()=>`fast-${++Et}`;function Ot(e){return e===document?document.body:e}var kt=class{constructor(e){this.styles=e,this.styleClass=Dt()}addStylesTo(e){e=Ot(Y(e));let t=this.styles,n=this.styleClass;for(let r=0;r<t.length;r++){let i=document.createElement(`style`);i.innerHTML=t[r],i.className=n,e.append(i)}}removeStylesFrom(e){e=Ot(Y(e));let t=e.querySelectorAll(`.${this.styleClass}`);for(let n=0,r=t.length;n<r;++n)e.removeChild(t[n])}},At=(e,t)=>{e.adoptedStyleSheets=[...e.adoptedStyleSheets,...t]},jt=(e,t)=>{e.adoptedStyleSheets=e.adoptedStyleSheets.filter(e=>t.indexOf(e)===-1)};if(w.supportsAdoptedStyleSheets){try{document.adoptedStyleSheets.push(),document.adoptedStyleSheets.splice(),At=(e,t)=>{e.adoptedStyleSheets.push(...t)},jt=(e,t)=>{for(let n of t){let t=e.adoptedStyleSheets.indexOf(n);t!==-1&&e.adoptedStyleSheets.splice(t,1)}}}catch{}w.setDefaultStrategy(Tt)}else w.setDefaultStrategy(kt);var Mt=`needs-hydration`,X=class e extends J{get shadowOptions(){return super.shadowOptions}set shadowOptions(e){super.shadowOptions=e,(this.hasExistingShadowRoot||e!==void 0&&!this.template)&&this.definition.templateOptions===mt.deferAndHydrate&&(this.source.toggleAttribute(Ee,!0),this.source.toggleAttribute(Mt,!0))}addHydratingInstance(){if(!e.hydratingInstances)return;let t=this.definition.name,n=e.hydratingInstances.get(t);n||(n=new Set,e.hydratingInstances.set(t,n)),n.add(this.source)}static config(t){return e.lifecycleCallbacks=t,this}static hydrationObserverHandler(t){for(let n of t)n.target.hasAttribute(`defer-hydration`)||(e.hydrationObserver.unobserve(n.target),n.target.$fastController.connect())}static checkHydrationComplete(t){var n,r;if(t.didTimeout){e.idleCallbackId=requestIdleCallback(e.checkHydrationComplete,{timeout:50});return}if(e.hydratingInstances?.size===0){try{(r=(n=e.lifecycleCallbacks).hydrationComplete)==null||r.call(n)}catch{}J.setStrategy(J)}}connect(){var t,n,r,i,a;if(this.needsHydration=this.needsHydration??this.source.hasAttribute(Mt),this.needsHydration&&this.addHydratingInstance(),this.source.hasAttribute(`defer-hydration`)){this.addHydratingInstance(),e.hydrationObserver.observe(this.source,{attributeFilter:[Ee]});return}if(!this.needsHydration){super.connect(),this.removeHydratingInstance();return}if(this.stage===q.disconnected){if(!e.hydrationStarted){e.hydrationStarted=!0;try{(n=(t=e.lifecycleCallbacks).hydrationStarted)==null||n.call(t)}catch{}}try{(i=(r=e.lifecycleCallbacks).elementWillHydrate)==null||i.call(r,this.source)}catch{}if(this.stage=q.connecting,this.bindObservables(),this.connectBehaviors(),this.template)if(N(this.template)){let e=this.source,t=K(e)??e,n=t.firstChild,r=t.lastChild;e.shadowRoot===null&&(j.isElementBoundaryStartMarker(n)&&(n.data=``,n=n.nextSibling),j.isElementBoundaryEndMarker(r)&&(r.data=``,r=r.previousSibling)),this.view=this.template.hydrate(n,r,e),(a=this.view)==null||a.bind(this.source)}else this.renderTemplate(this.template);this.addStyles(this.mainStyles),this.stage=q.connected,this.source.removeAttribute(Mt),this.needsInitialization=this.needsHydration=!1,this.removeHydratingInstance(),y.notify(this,G)}}removeHydratingInstance(){var t,n;if(!e.hydratingInstances)return;try{(n=(t=e.lifecycleCallbacks).elementDidHydrate)==null||n.call(t,this.source)}catch{}let r=this.definition.name,i=e.hydratingInstances.get(r);i&&(i.delete(this.source),i.size||e.hydratingInstances.delete(r),e.idleCallbackId&&cancelIdleCallback(e.idleCallbackId),e.idleCallbackId=requestIdleCallback(e.checkHydrationComplete,{timeout:50}))}disconnect(){super.disconnect(),e.hydrationObserver.unobserve(this.source)}static install(){J.setStrategy(e)}};X.hydrationObserver=new bt(X.hydrationObserverHandler),X.lifecycleCallbacks={},X.hydrationStarted=!1,X.idleCallbackId=null,X.hydratingInstances=new Map;function Nt(e){let t=class extends e{constructor(){super(),J.forCustomElement(this)}$emit(e,t,n){return this.$fastController.emit(e,t,n)}connectedCallback(){this.$fastController.connect()}disconnectedCallback(){this.$fastController.disconnect()}attributeChangedCallback(e,t,n){this.$fastController.onAttributeChangedCallback(e,t,n)}};return U.registerBaseType(t),t}function Pt(e,t){return i(e)?U.compose(e,t):U.compose(this,e)}function Ft(e,t){return i(e)?new Promise(n=>{U.composeAsync(e,t).then(e=>{n(e)})}).then(e=>e.define().type):new Promise(t=>{U.composeAsync(this,e).then(e=>{t(e)})}).then(e=>e.define().type)}function It(e,t){return i(e)?U.compose(e,t).define().type:U.compose(this,e).define().type}function Lt(e){return Nt(e)}var Rt=Object.assign(Nt(HTMLElement),{from:Lt,define:It,compose:Pt,defineAsync:Ft});function zt(e,t){return e instanceof Function?e(t):e}var Bt=new Set,Vt=new Map,Ht=e=>(t=`vwc`)=>{let n=e=>`${t}-${e}`,r=e=>{let i=n(e.name),a=e.type;if(a.componentName=e.name,Bt.has(i))return;Vt.has(a)&&Vt.get(a)!==i&&(a=class extends a{}),Bt.add(i),Vt.set(a,i);for(let t of e.dependencies)r(t);let o=new Map([[e.type,i],...e.dependencies.map(e=>[e.type,n(e.name)])]),s={tagFor:(t,n)=>{if(!o.has(t))throw Error(`Could not get tag for ${t.name} as it is not a dependency of ${e.name}.`);let r=o.get(t);return n?r:yt.partial(r)},tagForNonDependency(e){return n(e)}};U.compose(a,{...e.options,template:zt(e.template,s),name:`${t}-${e.name}`}).define()};r(e)},Ut=(e,t,n,r,i)=>({name:e,type:t,template:n,dependencies:r,options:i}),Wt=new WeakMap,Z=e=>{let t=Wt.get(e);return t||(t=[],Wt.set(e,t)),t},Gt=(e,t)=>{Z(e).push(t)},Kt=(e,t)=>{Z(e).splice(Z(e).indexOf(t),1)},qt=(e,t)=>{Z(e).forEach(n=>n(e,t))},Jt=e=>e===`delegate`,Yt=e=>`vvd${e.charAt(0).toUpperCase()}${e.slice(1)}`,Xt=(e,t)=>{if(Jt(e._vividAriaBehaviour)){let n=e[t];e[`_${t}`]=null,e.removeAttribute($(t)),e[`_${t}`]=n,e[t]===null?delete e.dataset[Yt(t)]:e.dataset[Yt(t)]=e[t]}else g.setAttribute(e,$(t),e[t])},Q=new WeakMap,Zt=(e,t)=>{let n=Q.get(e);n?n.add(t):Q.set(e,new Set([t]))},Qt=(e,t)=>{e.isConnected?Xt(e,t):Zt(e,t)},$t=e=>{let t=Q.get(e);if(t){for(let n of t)Xt(e,n);Q.delete(e)}},en=`role.ariaAtomic.ariaAutoComplete.ariaBusy.ariaChecked.ariaColCount.ariaColIndex.ariaColIndexText.ariaColSpan.ariaCurrent.ariaDescription.ariaDisabled.ariaExpanded.ariaHasPopup.ariaHidden.ariaInvalid.ariaKeyShortcuts.ariaLabel.ariaLevel.ariaLive.ariaModal.ariaMultiLine.ariaMultiSelectable.ariaOrientation.ariaPlaceholder.ariaPosInSet.ariaPressed.ariaReadOnly.ariaRequired.ariaRoleDescription.ariaRowCount.ariaRowIndex.ariaRowIndexText.ariaRowSpan.ariaSelected.ariaSetSize.ariaSort.ariaValueMax.ariaValueMin.ariaValueNow.ariaValueText.ariaRelevant`.split(`.`),tn=[`ariaControls`,`ariaDescribedBy`,`ariaDetails`,`ariaErrorMessage`,`ariaFlowTo`,`ariaLabelledBy`,`ariaOwns`],nn=[...en,...tn],$=e=>e.replace(`aria`,`aria-`).toLowerCase(),rn=e=>{class t extends e{constructor(...e){super(...e),this._vividAriaBehaviour=`default`;for(let e of nn)this[`_${e}`]=null}connectedCallback(){super.connectedCallback(),$t(this)}}for(let e of nn)ut({attribute:$(e),mode:`fromView`})(t.prototype,e),t.prototype[`${e}Changed`]=function(){Qt(this,e),this._vividAriaBehaviour!==`default`&&qt(this,e)};return t},an=e=>{class t extends e{#e=new Set;_addController(e){this.#e.add(e),this.$fastController.isConnected&&e.hostConnected?.()}_removeController(e){this.#e.delete(e)}connectedCallback(){super.connectedCallback();for(let e of this.#e)e.hostConnected?.()}disconnectedCallback(){super.disconnectedCallback();for(let e of this.#e)e.hostDisconnected?.()}}return t};function on(){let e=new WeakMap;return t=>(e.has(t)||e.set(t,[]),e.get(t))}var sn=on(),cn=e=>(t,n)=>{sn(t.constructor).push({newPropertyName:n,...e})},ln=e=>{class t extends e{#e(e){let t=!1,n=!1,r=t=>n&&e.fromDeprecated(t[e.deprecatedPropertyName])===t[e.newPropertyName],i=n=>t&&e.toDeprecated&&e.toDeprecated(n[e.newPropertyName])===n[e.deprecatedPropertyName],a={handleChange(a,o){if(o===e.newPropertyName){if(t=!0,!e.toDeprecated||r(a))return;a[e.deprecatedPropertyName]=e.toDeprecated(a[e.newPropertyName])}if(o===e.deprecatedPropertyName){if(n=!0,i(a))return;a[e.newPropertyName]=e.fromDeprecated(a[e.deprecatedPropertyName])}}},o=y.getNotifier(this);o.subscribe(a,e.newPropertyName),o.subscribe(a,e.deprecatedPropertyName)}constructor(...e){super(...e);for(let e of sn(this.constructor))this.#e(e)}}return t},un=class extends rn(ln(an(Rt))){static{this.VIVID_VERSION=`5.20.0`}connectedCallback(){super.connectedCallback();let e=this.constructor.componentName;this.setAttribute(`data-vvd-component`,e)}};Object.defineProperty(exports,`A`,{enumerable:!0,get:function(){return ie}}),Object.defineProperty(exports,`C`,{enumerable:!0,get:function(){return pe}}),Object.defineProperty(exports,`D`,{enumerable:!0,get:function(){return x}}),Object.defineProperty(exports,`E`,{enumerable:!0,get:function(){return S}}),Object.defineProperty(exports,`F`,{enumerable:!0,get:function(){return l}}),Object.defineProperty(exports,`I`,{enumerable:!0,get:function(){return i}}),Object.defineProperty(exports,`L`,{enumerable:!0,get:function(){return a}}),Object.defineProperty(exports,`M`,{enumerable:!0,get:function(){return re}}),Object.defineProperty(exports,`N`,{enumerable:!0,get:function(){return _}}),Object.defineProperty(exports,`O`,{enumerable:!0,get:function(){return b}}),Object.defineProperty(exports,`P`,{enumerable:!0,get:function(){return g}}),Object.defineProperty(exports,`R`,{enumerable:!0,get:function(){return o}}),Object.defineProperty(exports,`S`,{enumerable:!0,get:function(){return he}}),Object.defineProperty(exports,`T`,{enumerable:!0,get:function(){return C}}),Object.defineProperty(exports,`_`,{enumerable:!0,get:function(){return F}}),Object.defineProperty(exports,`a`,{enumerable:!0,get:function(){return en}}),Object.defineProperty(exports,`b`,{enumerable:!0,get:function(){return N}}),Object.defineProperty(exports,`c`,{enumerable:!0,get:function(){return Gt}}),Object.defineProperty(exports,`d`,{enumerable:!0,get:function(){return Ht}}),Object.defineProperty(exports,`f`,{enumerable:!0,get:function(){return xt}}),Object.defineProperty(exports,`g`,{enumerable:!0,get:function(){return L}}),Object.defineProperty(exports,`h`,{enumerable:!0,get:function(){return ct}}),Object.defineProperty(exports,`i`,{enumerable:!0,get:function(){return tn}}),Object.defineProperty(exports,`j`,{enumerable:!0,get:function(){return ae}}),Object.defineProperty(exports,`k`,{enumerable:!0,get:function(){return y}}),Object.defineProperty(exports,`l`,{enumerable:!0,get:function(){return Kt}}),Object.defineProperty(exports,`m`,{enumerable:!0,get:function(){return ut}}),Object.defineProperty(exports,`n`,{enumerable:!0,get:function(){return cn}}),Object.defineProperty(exports,`o`,{enumerable:!0,get:function(){return Qt}}),Object.defineProperty(exports,`p`,{enumerable:!0,get:function(){return yt}}),Object.defineProperty(exports,`r`,{enumerable:!0,get:function(){return $}}),Object.defineProperty(exports,`s`,{enumerable:!0,get:function(){return qt}}),Object.defineProperty(exports,`t`,{enumerable:!0,get:function(){return un}}),Object.defineProperty(exports,`u`,{enumerable:!0,get:function(){return Ut}}),Object.defineProperty(exports,`v`,{enumerable:!0,get:function(){return I}}),Object.defineProperty(exports,`w`,{enumerable:!0,get:function(){return w}}),Object.defineProperty(exports,`x`,{enumerable:!0,get:function(){return A}}),Object.defineProperty(exports,`y`,{enumerable:!0,get:function(){return j}});
4
+ `),t,Ae(this.firstChild,this.lastChild).cloneContents(),e)}}}else{this.source!==null&&this.evaluateUnbindables(),this.isBound=!1,this.source=e,this.context=t;for(let e=0,t=n.length;e<t;++e)n[e].bind(this)}this.isBound=!0,this._hydrationStage=I.hydrated}unbind(){!this.isBound||this.source===null||(this.evaluateUnbindables(),this.source=null,this.context=this,this.isBound=!1)}dispose(){Re(this.firstChild,this.lastChild),this.unbind()}onUnbind(e){this.unbindables.push(e)}evaluateUnbindables(){let e=this.unbindables;for(let t=0,n=e.length;t<n;++t)e[t].unbind(this);e.length=0}};Le=M,f(Ve);function He(e){return e.create!==void 0}function Ue(e,t,n,r){if(n??=``,He(n)){e.textContent=``;let t=e.$fastView;if(t===void 0)if(N(r)&&N(n)&&r.bindingViewBoundaries[this.targetNodeId]!==void 0&&r.hydrationStage!==I.hydrated){let e=r.bindingViewBoundaries[this.targetNodeId];t=n.hydrate(e.first,e.last)}else t=n.create();else e.$fastTemplate!==n&&(t.isComposed&&(t.remove(),t.unbind()),t=n.create());t.isComposed?t.needsBindOnly&&(t.needsBindOnly=!1,t.bind(r.source,r.context)):(t.isComposed=!0,t.bind(r.source,r.context),t.insertBefore(e),e.$fastView=t,e.$fastTemplate=n)}else{let t=e.$fastView;t!==void 0&&t.isComposed&&(t.isComposed=!1,t.remove(),t.needsBindOnly?t.needsBindOnly=!1:t.unbind()),e.textContent=n}}function We(e,t,n){let r=`${this.id}-t`,i=e[r]??(e[r]={v:0,cv:Object.create(null)}),a=i.cv,o=i.v,s=e[t];if(n!=null&&n.length){let e=n.split(/\s+/);for(let t=0,n=e.length;t<n;++t){let n=e[t];n!==``&&(a[n]=o,s.add(n))}}if(i.v=o+1,o!==0){--o;for(let e in a)a[e]===o&&s.remove(e)}}var Ge={[p.attribute]:g.setAttribute,[p.booleanAttribute]:g.setBooleanAttribute,[p.property]:(e,t,n)=>e[t]=n,[p.content]:Ue,[p.tokenList]:We,[p.event]:()=>void 0},L=class{constructor(e){this.dataBinding=e,this.updateTarget=null,this.aspectType=p.content}createHTML(e){return pe.interpolation(e(this))}createBehavior(){if(this.updateTarget===null){let e=Ge[this.aspectType],t=this.dataBinding.policy??this.policy;if(!e)throw c.error(r.unsupportedBindingBehavior);this.data=`${this.id}-d`,this.updateTarget=t.protect(this.targetTagName,this.aspectType,this.targetAspect,e)}return this}bind(e){let t=e.targets[this.targetNodeId],n=N(e)&&e.hydrationStage&&e.hydrationStage!==I.hydrated;switch(this.aspectType){case p.event:t[this.data]=e,t.addEventListener(this.targetAspect,this,this.dataBinding.options);break;case p.content:e.onUnbind(this);default:{let r=t[this.data]??(t[this.data]=this.dataBinding.createObserver(this,this));if(r.target=t,r.controller=e,n&&(this.aspectType===p.attribute||this.aspectType===p.booleanAttribute)){r.bind(e);break}this.updateTarget(t,this.targetAspect,r.bind(e),e);break}}}unbind(e){let t=e.targets[this.targetNodeId].$fastView;t!==void 0&&t.isComposed&&(t.unbind(),t.needsBindOnly=!0)}handleEvent(e){let t=e.currentTarget[this.data];if(t.isBound){b.setEvent(e);let n=this.dataBinding.evaluate(t.source,t.context);b.setEvent(null),n!==!0&&e.preventDefault()}}handleChange(e,t){let n=t.controller;if(!n.isBound)return;let r=t.target;this.updateTarget(r,this.targetAspect,t.bind(n),n)}};A.define(L,{aspected:!0});var Ke=(e,t)=>`${e}.${t}`,qe={},R={index:0,node:null};function Je(e){e.startsWith(`fast-`)||c.warn(r.hostBindingWithoutHost,{name:e})}var Ye=new Proxy(document.createElement(`div`),{get(e,t){Je(t);let n=Reflect.get(e,t);return i(n)?n.bind(e):n},set(e,t,n){return Je(t),Reflect.set(e,t,n)}}),Xe=class{constructor(e,t,n){this.fragment=e,this.directives=t,this.policy=n,this.proto=null,this.nodeIds=new Set,this.descriptors={},this.factories=[]}addFactory(e,t,n,r,i){this.nodeIds.has(n)||(this.nodeIds.add(n),this.addTargetDescriptor(t,n,r)),e.id=e.id??O(),e.targetNodeId=n,e.targetTagName=i,e.policy=e.policy??this.policy,this.factories.push(e)}freeze(){return this.proto=Object.create(null,this.descriptors),this}addTargetDescriptor(e,t,n){let r=this.descriptors;if(t===`r`||t===`h`||r[t])return;if(!r[e]){let t=e.lastIndexOf(`.`),n=e.substring(0,t),r=parseInt(e.substring(t+1),10);this.addTargetDescriptor(n,e,r)}let i=qe[t];if(!i){let r=`_${t}`;qe[t]=i={get(){return this[r]??(this[r]=this[e].childNodes[n])}}}r[t]=i}createView(e){let t=this.fragment.cloneNode(!0),n=Object.create(this.proto);n.r=t,n.h=e??Ye;for(let e of this.nodeIds)Reflect.get(n,e);return new F(t,this.factories,n)}};function Ze(e,t,n,r,i,a=!1){let o=n.attributes,s=e.directives;for(let c=0,l=o.length;c<l;++c){let u=o[c],d=u.value,f=k.parse(d,s),p=null;f===null?a&&(p=new L(C(()=>d,e.policy)),A.assignAspect(p,u.name)):p=z.aggregate(f,e.policy),p!==null&&(n.removeAttributeNode(u),c--,l--,e.addFactory(p,t,r,i,n.tagName))}}function Qe(e,t,n,r,i){let o=k.parse(t.textContent,e.directives);if(o===null)return R.node=t.nextSibling,R.index=i+1,R;let s,c=s=t;for(let t=0,l=o.length;t<l;++t){let l=o[t];t!==0&&(i++,r=Ke(n,i),s=c.parentNode.insertBefore(document.createTextNode(``),c.nextSibling)),a(l)?s.textContent=l:(s.textContent=` `,A.assignAspect(l),e.addFactory(l,n,r,i,null)),c=s}return R.index=i+1,R.node=c.nextSibling,R}function $e(e,t,n){let r=0,i=t.firstChild;for(;i;){let t=et(e,n,i,r);i=t.node,r=t.index}}function et(e,t,n,r){let i=Ke(t,r);switch(n.nodeType){case 1:Ze(e,t,n,i,r),$e(e,n,i);break;case 3:return Qe(e,n,t,i,r);case 8:{let a=k.parse(n.data,e.directives);a!==null&&e.addFactory(z.aggregate(a),t,i,r,null);break}}return R.index=r+1,R.node=n.nextSibling,R}function tt(e,t){return e&&e.nodeType===8&&k.parse(e.data,t)!==null}var nt=`TEMPLATE`,z={compile(e,t,n=g.policy){let r;if(a(e)){r=document.createElement(nt),r.innerHTML=n.createHTML(e);let t=r.content.firstElementChild;t!==null&&t.tagName===nt&&(r=t)}else r=e;!r.content.firstChild&&!r.content.lastChild&&r.content.appendChild(document.createComment(``));let i=document.adoptNode(r.content),o=new Xe(i,t,n);return Ze(o,``,r,`h`,0,!0),(tt(i.firstChild,t)||i.childNodes.length===1&&Object.keys(t).length>0)&&i.insertBefore(document.createComment(``),i.firstChild),$e(o,i,`r`),R.node=null,o.freeze()},setDefaultStrategy(e){this.compile=e},aggregate(e,t=g.policy){if(e.length===1)return e[0];let n,r=!1,i,o=e.length,s=e.map(e=>a(e)?()=>e:(n=e.sourceAspect||n,r||=e.dataBinding.isVolatile,i||=e.dataBinding.policy,e.dataBinding.evaluate)),c=new L(S((e,t)=>{let n=``;for(let r=0;r<o;++r)n+=s[r](e,t);return n},i??t,r));return A.assignAspect(c,n),c}},rt=`boolean`,it=`reflect`,at=Object.freeze({locate:d()}),ot={toView(e){return e?`true`:`false`},fromView(e){return!(e==null||e===`false`||e===!1||e===0)}};function st(e){if(e==null)return null;let t=e*1;return isNaN(t)?null:t}var ct={toView(e){let t=st(e);return t&&t.toString()},fromView:st},lt=class e{constructor(e,t,n=t.toLowerCase(),r=it,i){this.guards=new Set,this.Owner=e,this.name=t,this.attribute=n,this.mode=r,this.converter=i,this.fieldName=`_${t}`,this.callbackName=`${t}Changed`,this.hasCallback=this.callbackName in e.prototype,r===rt&&i===void 0&&(this.converter=ot)}setValue(e,t){let n=e[this.fieldName],r=this.converter;r!==void 0&&(t=r.fromView(t)),n!==t&&(e[this.fieldName]=t,this.tryReflectToAttribute(e),this.hasCallback&&e[this.callbackName](n,t),e.$fastController.notify(this.name))}getValue(e){return y.track(e,this.name),e[this.fieldName]}onAttributeChangedCallback(e,t){this.guards.has(e)||(this.guards.add(e),this.setValue(e,t),this.guards.delete(e))}tryReflectToAttribute(e){let t=this.mode,n=this.guards;n.has(e)||t===`fromView`||re.enqueue(()=>{n.add(e);let r=e[this.fieldName];switch(t){case it:let t=this.converter;g.setAttribute(e,this.attribute,t===void 0?r:t.toView(r));break;case rt:g.setBooleanAttribute(e,this.attribute,r);break}n.delete(e)})}static collect(t,...n){let r=[];n.push(at.locate(t));for(let i=0,o=n.length;i<o;++i){let o=n[i];if(o!==void 0)for(let n=0,i=o.length;n<i;++n){let i=o[n];a(i)?r.push(new e(t,i)):r.push(new e(t,i.property,i.attribute,i.mode,i.converter))}}return r}};function ut(e,t){let n;function r(e,t){arguments.length>1&&(n.property=t),at.locate(e.constructor).push(n)}if(arguments.length>1){n={},r(e,t);return}return n=e===void 0?{}:e,r}var dt=function(e,t,n,r){function i(e){return e instanceof n?e:new n(function(t){t(e)})}return new(n||=Promise)(function(n,a){function o(e){try{c(r.next(e))}catch(e){a(e)}}function s(e){try{c(r.throw(e))}catch(e){a(e)}}function c(e){e.done?n(e.value):i(e.value).then(o,s)}c((r=r.apply(e,t||[])).next())})},B,ft={mode:`open`},pt={},V=new Set,H=c.getById(n.elementRegistry,()=>u()),mt={deferAndHydrate:`defer-and-hydrate`},U=class{get isDefined(){return this.platformDefined}constructor(e,t=e.definition){this.platformDefined=!1,a(t)&&(t={name:t}),this.type=e,this.name=t.name,this.template=t.template,this.templateOptions=t.templateOptions,this.registry=t.registry??customElements;let n=e.prototype,r=lt.collect(e,t.attributes),i=Array(r.length),o={},s={};for(let e=0,t=r.length;e<t;++e){let t=r[e];i[e]=t.attribute,o[t.name]=t,s[t.attribute]=t,y.defineProperty(n,t)}Reflect.defineProperty(e,`observedAttributes`,{value:i,enumerable:!0}),this.attributes=r,this.propertyLookup=o,this.attributeLookup=s,this.shadowOptions=t.shadowOptions===void 0?ft:t.shadowOptions===null?void 0:Object.assign(Object.assign({},ft),t.shadowOptions),this.elementOptions=t.elementOptions===void 0?pt:Object.assign(Object.assign({},pt),t.elementOptions),this.styles=w.normalize(t.styles),H.register(this),y.defineProperty(B.isRegistered,this.name),B.isRegistered[this.name]=this.type}define(e=this.registry){var t,n;let r=this.type;return e.get(this.name)||(this.platformDefined=!0,e.define(this.name,r,this.elementOptions),(n=(t=this.lifecycleCallbacks)?.elementDidDefine)==null||n.call(t,this.name)),this}static compose(e,t){return V.has(e)||H.getByType(e)?new B(class extends e{},t):new B(e,t)}static registerBaseType(e){V.add(e)}static composeAsync(e,t){return new Promise(n=>{(V.has(e)||H.getByType(e))&&n(new B(class extends e{},t));let r=new B(e,t);y.getNotifier(r).subscribe({handleChange:()=>{var e,t;(t=(e=r.lifecycleCallbacks)?.templateDidUpdate)==null||t.call(e,r.name),n(r)}},`template`)})}};B=U,U.isRegistered={},U.getByType=H.getByType,U.getForInstance=H.getForInstance,U.registerAsync=e=>dt(void 0,void 0,void 0,function*(){return new Promise(t=>{B.isRegistered[e]&&t(B.isRegistered[e]),y.getNotifier(B.isRegistered).subscribe({handleChange:()=>t(B.isRegistered[e])},e)})}),y.defineProperty(U.prototype,`template`);var ht=/([ \x09\x0a\x0c\x0d])([^\0-\x1F\x7F-\x9F "'>=/]+)([ \x09\x0a\x0c\x0d]*=[ \x09\x0a\x0c\x0d]*(?:[^ \x09\x0a\x0c\x0d"'`<>=]*|"[^"]*|'[^']*))$/,gt=Object.create(null),W=class{constructor(e,t=gt){this.html=e,this.factories=t}createHTML(e){let t=this.factories;for(let n in t)e(t[n]);return this.html}};W.empty=new W(``),A.define(W);function _t(e,t,n,r=A.getForInstance(e)){if(r.aspected){let n=ht.exec(t);n!==null&&A.assignAspect(e,n[2])}return e.createHTML(n)}var vt=class e{constructor(e,t={},n){this.policy=n,this.result=null,this.html=e,this.factories=t}compile(){return this.result===null&&(this.result=z.compile(this.html,this.factories,this.policy)),this.result}create(e){return this.compile().createView(e)}inline(){return new W(a(this.html)?this.html:this.html.innerHTML,this.factories)}withPolicy(e){if(this.result)throw c.error(r.cannotSetTemplatePolicyAfterCompilation);if(this.policy)throw c.error(r.onlySetTemplatePolicyOnce);return this.policy=e,this}render(e,t,n){let r=this.create(n);return r.bind(e),r.appendTo(t),r}static create(t,n,r){let a=``,o=Object.create(null),s=e=>{let t=e.id??=O();return o[t]=e,t};for(let e=0,r=t.length-1;e<r;++e){let r=t[e],o=n[e],c;if(a+=r,i(o))o=new L(S(o));else if(o instanceof x)o=new L(o);else if(!(c=A.getForInstance(o))){let e=o;o=new L(C(()=>e))}a+=_t(o,r,s,c)}return new e(a+t[t.length-1],o,r)}};f(vt);var yt=((e,...t)=>{if(Array.isArray(e)&&Array.isArray(e.raw))return vt.create(e,t);throw c.error(r.directCallToHTMLTagNotAllowed)});yt.partial=e=>new W(e);var bt=class extends MutationObserver{constructor(e){function t(e){this.callback.call(null,e.filter(e=>this.observedNodes.has(e.target)))}super(t),this.callback=e,this.observedNodes=new Set}observe(e,t){this.observedNodes.add(e),super.observe(e,t)}unobserve(e){this.observedNodes.delete(e),this.observedNodes.size<1&&this.disconnect()}},xt=Object.freeze({create(e){let t=[],n={},r=null,i=!1;return{source:e,context:b.default,targets:n,get isBound(){return i},addBehaviorFactory(e,t){let n=e;n.id=n.id??O(),n.targetNodeId=n.targetNodeId??O(),n.targetTagName=t.tagName??null,n.policy=n.policy??g.policy,this.addTarget(n.targetNodeId,t),this.addBehavior(n.createBehavior())},addTarget(e,t){n[e]=t},addBehavior(e){t.push(e),i&&e.bind(this)},onUnbind(e){r===null&&(r=[]),r.push(e)},connectedCallback(e){i||(i=!0,t.forEach(e=>e.bind(this)))},disconnectedCallback(e){i&&(i=!1,r!==null&&r.forEach(e=>e.unbind(this)))}}}}),St={bubbles:!0,composed:!0,cancelable:!0},G=`isConnected`,Ct=new WeakMap;function K(e){return e.shadowRoot??Ct.get(e)??null}var wt,q;(function(e){e[e.connecting=0]=`connecting`,e[e.connected=1]=`connected`,e[e.disconnecting=2]=`disconnecting`,e[e.disconnected=3]=`disconnected`})(q||={});var J=class e extends ne{get isConnected(){return y.track(this,G),this.stage===q.connected}get context(){return this.view?.context??b.default}get isBound(){return this.view?.isBound??!1}get sourceLifetime(){return this.view?.sourceLifetime}get template(){if(this._template===null){let e=this.definition;this.source.resolveTemplate?this._template=this.source.resolveTemplate():e.template&&(this._template=e.template??null)}return this._template}set template(e){this._template!==e&&(this._template=e,this.needsInitialization||this.renderTemplate(e))}get shadowOptions(){return this._shadowRootOptions}set shadowOptions(e){if(this._shadowRootOptions===void 0&&e!==void 0){this._shadowRootOptions=e;let t=this.source.shadowRoot;t?this.hasExistingShadowRoot=!0:(t=this.source.attachShadow(e),e.mode===`closed`&&Ct.set(this.source,t))}}get mainStyles(){if(this._mainStyles===null){let e=this.definition;this.source.resolveStyles?this._mainStyles=this.source.resolveStyles():e.styles&&(this._mainStyles=e.styles??null)}return this._mainStyles}set mainStyles(e){this._mainStyles!==e&&(this._mainStyles!==null&&this.removeStyles(this._mainStyles),this._mainStyles=e,this.needsInitialization||this.addStyles(e))}constructor(e,t){super(e),this.boundObservables=null,this.needsInitialization=!0,this.hasExistingShadowRoot=!1,this._template=null,this.stage=q.disconnected,this.guardBehaviorConnection=!1,this.behaviors=null,this.behaviorsConnected=!1,this._mainStyles=null,this.$fastController=this,this.view=null,this.source=e,this.definition=t,this.shadowOptions=t.shadowOptions;let n=y.getAccessors(e);if(n.length>0){let t=this.boundObservables=Object.create(null);for(let r=0,i=n.length;r<i;++r){let i=n[r].name,a=e[i];a!==void 0&&(delete e[i],t[i]=a)}}}onUnbind(e){var t;(t=this.view)==null||t.onUnbind(e)}addBehavior(e){let t=this.behaviors??=new Map,n=t.get(e)??0;n===0?(t.set(e,1),e.addedCallback&&e.addedCallback(this),e.connectedCallback&&!this.guardBehaviorConnection&&(this.stage===q.connected||this.stage===q.connecting)&&e.connectedCallback(this)):t.set(e,n+1)}removeBehavior(e,t=!1){let n=this.behaviors;if(n===null)return;let r=n.get(e);r!==void 0&&(r===1||t?(n.delete(e),e.disconnectedCallback&&this.stage!==q.disconnected&&e.disconnectedCallback(this),e.removedCallback&&e.removedCallback(this)):n.set(e,r-1))}addStyles(e){if(!e)return;let t=this.source;if(e instanceof HTMLElement)(K(t)??this.source).append(e);else if(!e.isAttachedTo(t)){let n=e.behaviors;if(e.addStylesTo(t),n!==null)for(let e=0,t=n.length;e<t;++e)this.addBehavior(n[e])}}removeStyles(e){if(!e)return;let t=this.source;if(e instanceof HTMLElement)(K(t)??t).removeChild(e);else if(e.isAttachedTo(t)){let n=e.behaviors;if(e.removeStylesFrom(t),n!==null)for(let e=0,t=n.length;e<t;++e)this.removeBehavior(n[e])}}connect(){this.stage===q.disconnected&&(this.stage=q.connecting,this.bindObservables(),this.connectBehaviors(),this.needsInitialization?(this.renderTemplate(this.template),this.addStyles(this.mainStyles),this.needsInitialization=!1):this.view!==null&&this.view.bind(this.source),this.stage=q.connected,y.notify(this,G))}bindObservables(){if(this.boundObservables!==null){let e=this.source,t=this.boundObservables,n=Object.keys(t);for(let r=0,i=n.length;r<i;++r){let i=n[r];e[i]=t[i]}this.boundObservables=null}}connectBehaviors(){if(this.behaviorsConnected===!1){let e=this.behaviors;if(e!==null){this.guardBehaviorConnection=!0;for(let t of e.keys())t.connectedCallback&&t.connectedCallback(this);this.guardBehaviorConnection=!1}this.behaviorsConnected=!0}}disconnectBehaviors(){if(this.behaviorsConnected===!0){let e=this.behaviors;if(e!==null)for(let t of e.keys())t.disconnectedCallback&&t.disconnectedCallback(this);this.behaviorsConnected=!1}}disconnect(){this.stage===q.connected&&(this.stage=q.disconnecting,y.notify(this,G),this.view!==null&&this.view.unbind(),this.disconnectBehaviors(),this.stage=q.disconnected)}onAttributeChangedCallback(e,t,n){let r=this.definition.attributeLookup[e];r!==void 0&&r.onAttributeChangedCallback(this.source,n)}emit(e,t,n){return this.stage===q.connected?this.source.dispatchEvent(new CustomEvent(e,Object.assign(Object.assign({detail:t},St),n))):!1}renderTemplate(e){let t=this.source,n=K(t)??t;if(this.view!==null)this.view.dispose(),this.view=null;else if(!this.needsInitialization||this.hasExistingShadowRoot){this.hasExistingShadowRoot=!1;for(let e=n.firstChild;e!==null;e=n.firstChild)n.removeChild(e)}e&&(this.view=e.render(t,n,t),this.view.sourceLifetime=v.coupled)}static forCustomElement(t,n=!1){let i=t.$fastController;if(i!==void 0&&!n)return i;let a=U.getForInstance(t);if(a===void 0)throw c.error(r.missingElementDefinition);return y.getNotifier(a).subscribe({handleChange:()=>{e.forCustomElement(t,!0),t.$fastController.connect()}},`template`),y.getNotifier(a).subscribe({handleChange:()=>{e.forCustomElement(t,!0),t.$fastController.connect()}},`shadowOptions`),t.$fastController=new wt(t,a)}static setStrategy(e){wt=e}};f(J),J.setStrategy(J);function Y(e){return`adoptedStyleSheets`in e?e:K(e)??e.getRootNode()}var Tt=class e{constructor(t){let n=e.styleSheetCache;this.sheets=t.map(e=>{if(e instanceof CSSStyleSheet)return e;let t=n.get(e);return t===void 0&&(t=new CSSStyleSheet,t.replaceSync(e),n.set(e,t)),t})}addStylesTo(e){At(Y(e),this.sheets)}removeStylesFrom(e){jt(Y(e),this.sheets)}};Tt.styleSheetCache=new Map;var Et=0,Dt=()=>`fast-${++Et}`;function Ot(e){return e===document?document.body:e}var kt=class{constructor(e){this.styles=e,this.styleClass=Dt()}addStylesTo(e){e=Ot(Y(e));let t=this.styles,n=this.styleClass;for(let r=0;r<t.length;r++){let i=document.createElement(`style`);i.innerHTML=t[r],i.className=n,e.append(i)}}removeStylesFrom(e){e=Ot(Y(e));let t=e.querySelectorAll(`.${this.styleClass}`);for(let n=0,r=t.length;n<r;++n)e.removeChild(t[n])}},At=(e,t)=>{e.adoptedStyleSheets=[...e.adoptedStyleSheets,...t]},jt=(e,t)=>{e.adoptedStyleSheets=e.adoptedStyleSheets.filter(e=>t.indexOf(e)===-1)};if(w.supportsAdoptedStyleSheets){try{document.adoptedStyleSheets.push(),document.adoptedStyleSheets.splice(),At=(e,t)=>{e.adoptedStyleSheets.push(...t)},jt=(e,t)=>{for(let n of t){let t=e.adoptedStyleSheets.indexOf(n);t!==-1&&e.adoptedStyleSheets.splice(t,1)}}}catch{}w.setDefaultStrategy(Tt)}else w.setDefaultStrategy(kt);var Mt=`needs-hydration`,X=class e extends J{get shadowOptions(){return super.shadowOptions}set shadowOptions(e){super.shadowOptions=e,(this.hasExistingShadowRoot||e!==void 0&&!this.template)&&this.definition.templateOptions===mt.deferAndHydrate&&(this.source.toggleAttribute(Ee,!0),this.source.toggleAttribute(Mt,!0))}addHydratingInstance(){if(!e.hydratingInstances)return;let t=this.definition.name,n=e.hydratingInstances.get(t);n||(n=new Set,e.hydratingInstances.set(t,n)),n.add(this.source)}static config(t){return e.lifecycleCallbacks=t,this}static hydrationObserverHandler(t){for(let n of t)n.target.hasAttribute(`defer-hydration`)||(e.hydrationObserver.unobserve(n.target),n.target.$fastController.connect())}static checkHydrationComplete(t){var n,r;if(t.didTimeout){e.idleCallbackId=requestIdleCallback(e.checkHydrationComplete,{timeout:50});return}if(e.hydratingInstances?.size===0){try{(r=(n=e.lifecycleCallbacks).hydrationComplete)==null||r.call(n)}catch{}J.setStrategy(J)}}connect(){var t,n,r,i,a;if(this.needsHydration=this.needsHydration??this.source.hasAttribute(Mt),this.needsHydration&&this.addHydratingInstance(),this.source.hasAttribute(`defer-hydration`)){this.addHydratingInstance(),e.hydrationObserver.observe(this.source,{attributeFilter:[Ee]});return}if(!this.needsHydration){super.connect(),this.removeHydratingInstance();return}if(this.stage===q.disconnected){if(!e.hydrationStarted){e.hydrationStarted=!0;try{(n=(t=e.lifecycleCallbacks).hydrationStarted)==null||n.call(t)}catch{}}try{(i=(r=e.lifecycleCallbacks).elementWillHydrate)==null||i.call(r,this.source)}catch{}if(this.stage=q.connecting,this.bindObservables(),this.connectBehaviors(),this.template)if(N(this.template)){let e=this.source,t=K(e)??e,n=t.firstChild,r=t.lastChild;e.shadowRoot===null&&(j.isElementBoundaryStartMarker(n)&&(n.data=``,n=n.nextSibling),j.isElementBoundaryEndMarker(r)&&(r.data=``,r=r.previousSibling)),this.view=this.template.hydrate(n,r,e),(a=this.view)==null||a.bind(this.source)}else this.renderTemplate(this.template);this.addStyles(this.mainStyles),this.stage=q.connected,this.source.removeAttribute(Mt),this.needsInitialization=this.needsHydration=!1,this.removeHydratingInstance(),y.notify(this,G)}}removeHydratingInstance(){var t,n;if(!e.hydratingInstances)return;try{(n=(t=e.lifecycleCallbacks).elementDidHydrate)==null||n.call(t,this.source)}catch{}let r=this.definition.name,i=e.hydratingInstances.get(r);i&&(i.delete(this.source),i.size||e.hydratingInstances.delete(r),e.idleCallbackId&&cancelIdleCallback(e.idleCallbackId),e.idleCallbackId=requestIdleCallback(e.checkHydrationComplete,{timeout:50}))}disconnect(){super.disconnect(),e.hydrationObserver.unobserve(this.source)}static install(){J.setStrategy(e)}};X.hydrationObserver=new bt(X.hydrationObserverHandler),X.lifecycleCallbacks={},X.hydrationStarted=!1,X.idleCallbackId=null,X.hydratingInstances=new Map;function Nt(e){let t=class extends e{constructor(){super(),J.forCustomElement(this)}$emit(e,t,n){return this.$fastController.emit(e,t,n)}connectedCallback(){this.$fastController.connect()}disconnectedCallback(){this.$fastController.disconnect()}attributeChangedCallback(e,t,n){this.$fastController.onAttributeChangedCallback(e,t,n)}};return U.registerBaseType(t),t}function Pt(e,t){return i(e)?U.compose(e,t):U.compose(this,e)}function Ft(e,t){return i(e)?new Promise(n=>{U.composeAsync(e,t).then(e=>{n(e)})}).then(e=>e.define().type):new Promise(t=>{U.composeAsync(this,e).then(e=>{t(e)})}).then(e=>e.define().type)}function It(e,t){return i(e)?U.compose(e,t).define().type:U.compose(this,e).define().type}function Lt(e){return Nt(e)}var Rt=Object.assign(Nt(HTMLElement),{from:Lt,define:It,compose:Pt,defineAsync:Ft});function zt(e,t){return e instanceof Function?e(t):e}var Bt=new Set,Vt=new Map,Ht=e=>(t=`vwc`)=>{let n=e=>`${t}-${e}`,r=e=>{let i=n(e.name),a=e.type;if(a.componentName=e.name,Bt.has(i))return;Vt.has(a)&&Vt.get(a)!==i&&(a=class extends a{}),Bt.add(i),Vt.set(a,i);for(let t of e.dependencies)r(t);let o=new Map([[e.type,i],...e.dependencies.map(e=>[e.type,n(e.name)])]),s={tagFor:(t,n)=>{if(!o.has(t))throw Error(`Could not get tag for ${t.name} as it is not a dependency of ${e.name}.`);let r=o.get(t);return n?r:yt.partial(r)},tagForNonDependency(e){return n(e)}};U.compose(a,{...e.options,template:zt(e.template,s),name:`${t}-${e.name}`}).define()};r(e)},Ut=(e,t,n,r,i)=>({name:e,type:t,template:n,dependencies:r,options:i}),Wt=new WeakMap,Z=e=>{let t=Wt.get(e);return t||(t=[],Wt.set(e,t)),t},Gt=(e,t)=>{Z(e).push(t)},Kt=(e,t)=>{Z(e).splice(Z(e).indexOf(t),1)},qt=(e,t)=>{Z(e).forEach(n=>n(e,t))},Jt=e=>e===`delegate`,Yt=e=>`vvd${e.charAt(0).toUpperCase()}${e.slice(1)}`,Xt=(e,t)=>{if(Jt(e._vividAriaBehaviour)){let n=e[t];e[`_${t}`]=null,e.removeAttribute($(t)),e[`_${t}`]=n,e[t]===null?delete e.dataset[Yt(t)]:e.dataset[Yt(t)]=e[t]}else g.setAttribute(e,$(t),e[t])},Q=new WeakMap,Zt=(e,t)=>{let n=Q.get(e);n?n.add(t):Q.set(e,new Set([t]))},Qt=(e,t)=>{e.isConnected?Xt(e,t):Zt(e,t)},$t=e=>{let t=Q.get(e);if(t){for(let n of t)Xt(e,n);Q.delete(e)}},en=`role.ariaAtomic.ariaAutoComplete.ariaBusy.ariaChecked.ariaColCount.ariaColIndex.ariaColIndexText.ariaColSpan.ariaCurrent.ariaDescription.ariaDisabled.ariaExpanded.ariaHasPopup.ariaHidden.ariaInvalid.ariaKeyShortcuts.ariaLabel.ariaLevel.ariaLive.ariaModal.ariaMultiLine.ariaMultiSelectable.ariaOrientation.ariaPlaceholder.ariaPosInSet.ariaPressed.ariaReadOnly.ariaRequired.ariaRoleDescription.ariaRowCount.ariaRowIndex.ariaRowIndexText.ariaRowSpan.ariaSelected.ariaSetSize.ariaSort.ariaValueMax.ariaValueMin.ariaValueNow.ariaValueText.ariaRelevant`.split(`.`),tn=[`ariaControls`,`ariaDescribedBy`,`ariaDetails`,`ariaErrorMessage`,`ariaFlowTo`,`ariaLabelledBy`,`ariaOwns`],nn=[...en,...tn],$=e=>e.replace(`aria`,`aria-`).toLowerCase(),rn=e=>{class t extends e{constructor(...e){super(...e),this._vividAriaBehaviour=`default`;for(let e of nn)this[`_${e}`]=null}connectedCallback(){super.connectedCallback(),$t(this)}}for(let e of nn)ut({attribute:$(e),mode:`fromView`})(t.prototype,e),t.prototype[`${e}Changed`]=function(){Qt(this,e),this._vividAriaBehaviour!==`default`&&qt(this,e)};return t},an=e=>{class t extends e{#e=new Set;_addController(e){this.#e.add(e),this.$fastController.isConnected&&e.hostConnected?.()}_removeController(e){this.#e.delete(e)}connectedCallback(){super.connectedCallback();for(let e of this.#e)e.hostConnected?.()}disconnectedCallback(){super.disconnectedCallback();for(let e of this.#e)e.hostDisconnected?.()}}return t};function on(){let e=new WeakMap;return t=>(e.has(t)||e.set(t,[]),e.get(t))}var sn=on(),cn=e=>(t,n)=>{sn(t.constructor).push({newPropertyName:n,...e})},ln=e=>{class t extends e{#e(e){let t=!1,n=!1,r=t=>n&&e.fromDeprecated(t[e.deprecatedPropertyName])===t[e.newPropertyName],i=n=>t&&e.toDeprecated&&e.toDeprecated(n[e.newPropertyName])===n[e.deprecatedPropertyName],a={handleChange(a,o){if(o===e.newPropertyName){if(t=!0,!e.toDeprecated||r(a))return;a[e.deprecatedPropertyName]=e.toDeprecated(a[e.newPropertyName])}if(o===e.deprecatedPropertyName){if(n=!0,i(a))return;a[e.newPropertyName]=e.fromDeprecated(a[e.deprecatedPropertyName])}}},o=y.getNotifier(this);o.subscribe(a,e.newPropertyName),o.subscribe(a,e.deprecatedPropertyName)}constructor(...e){super(...e);for(let e of sn(this.constructor))this.#e(e)}}return t},un=class extends rn(ln(an(Rt))){static{this.VIVID_VERSION=`5.20.1`}connectedCallback(){super.connectedCallback();let e=this.constructor.componentName;this.setAttribute(`data-vvd-component`,e)}};Object.defineProperty(exports,`A`,{enumerable:!0,get:function(){return ie}}),Object.defineProperty(exports,`C`,{enumerable:!0,get:function(){return pe}}),Object.defineProperty(exports,`D`,{enumerable:!0,get:function(){return x}}),Object.defineProperty(exports,`E`,{enumerable:!0,get:function(){return S}}),Object.defineProperty(exports,`F`,{enumerable:!0,get:function(){return l}}),Object.defineProperty(exports,`I`,{enumerable:!0,get:function(){return i}}),Object.defineProperty(exports,`L`,{enumerable:!0,get:function(){return a}}),Object.defineProperty(exports,`M`,{enumerable:!0,get:function(){return re}}),Object.defineProperty(exports,`N`,{enumerable:!0,get:function(){return _}}),Object.defineProperty(exports,`O`,{enumerable:!0,get:function(){return b}}),Object.defineProperty(exports,`P`,{enumerable:!0,get:function(){return g}}),Object.defineProperty(exports,`R`,{enumerable:!0,get:function(){return o}}),Object.defineProperty(exports,`S`,{enumerable:!0,get:function(){return he}}),Object.defineProperty(exports,`T`,{enumerable:!0,get:function(){return C}}),Object.defineProperty(exports,`_`,{enumerable:!0,get:function(){return F}}),Object.defineProperty(exports,`a`,{enumerable:!0,get:function(){return en}}),Object.defineProperty(exports,`b`,{enumerable:!0,get:function(){return N}}),Object.defineProperty(exports,`c`,{enumerable:!0,get:function(){return Gt}}),Object.defineProperty(exports,`d`,{enumerable:!0,get:function(){return Ht}}),Object.defineProperty(exports,`f`,{enumerable:!0,get:function(){return xt}}),Object.defineProperty(exports,`g`,{enumerable:!0,get:function(){return L}}),Object.defineProperty(exports,`h`,{enumerable:!0,get:function(){return ct}}),Object.defineProperty(exports,`i`,{enumerable:!0,get:function(){return tn}}),Object.defineProperty(exports,`j`,{enumerable:!0,get:function(){return ae}}),Object.defineProperty(exports,`k`,{enumerable:!0,get:function(){return y}}),Object.defineProperty(exports,`l`,{enumerable:!0,get:function(){return Kt}}),Object.defineProperty(exports,`m`,{enumerable:!0,get:function(){return ut}}),Object.defineProperty(exports,`n`,{enumerable:!0,get:function(){return cn}}),Object.defineProperty(exports,`o`,{enumerable:!0,get:function(){return Qt}}),Object.defineProperty(exports,`p`,{enumerable:!0,get:function(){return yt}}),Object.defineProperty(exports,`r`,{enumerable:!0,get:function(){return $}}),Object.defineProperty(exports,`s`,{enumerable:!0,get:function(){return qt}}),Object.defineProperty(exports,`t`,{enumerable:!0,get:function(){return un}}),Object.defineProperty(exports,`u`,{enumerable:!0,get:function(){return Ut}}),Object.defineProperty(exports,`v`,{enumerable:!0,get:function(){return I}}),Object.defineProperty(exports,`w`,{enumerable:!0,get:function(){return w}}),Object.defineProperty(exports,`x`,{enumerable:!0,get:function(){return A}}),Object.defineProperty(exports,`y`,{enumerable:!0,get:function(){return j}});
@@ -1865,7 +1865,7 @@ var sn = on(), cn = (e) => (t, n) => {
1865
1865
  return t;
1866
1866
  }, un = class extends rn(ln(an(Rt))) {
1867
1867
  static {
1868
- this.VIVID_VERSION = "5.20.0";
1868
+ this.VIVID_VERSION = "5.20.1";
1869
1869
  }
1870
1870
  connectedCallback() {
1871
1871
  super.connectedCallback();
@@ -41842,6 +41842,15 @@
41842
41842
  "kind": "method",
41843
41843
  "name": "updateBindings"
41844
41844
  },
41845
+ {
41846
+ "kind": "method",
41847
+ "name": "shouldReturnFocusToEditor",
41848
+ "return": {
41849
+ "type": {
41850
+ "text": "boolean"
41851
+ }
41852
+ }
41853
+ },
41845
41854
  {
41846
41855
  "kind": "method",
41847
41856
  "name": "bindToEl",
@@ -54011,6 +54020,106 @@
54011
54020
  }
54012
54021
  ]
54013
54022
  },
54023
+ {
54024
+ "kind": "javascript-module",
54025
+ "path": "src/shared/picker-field/mixins/calendar-segments/calendarGrid.ts",
54026
+ "declarations": [
54027
+ {
54028
+ "kind": "function",
54029
+ "name": "buildCalendarGrid",
54030
+ "return": {
54031
+ "type": {
54032
+ "text": "CalendarGrid"
54033
+ }
54034
+ },
54035
+ "parameters": [
54036
+ {
54037
+ "name": "month",
54038
+ "type": {
54039
+ "text": "Month"
54040
+ }
54041
+ },
54042
+ {
54043
+ "name": "locale",
54044
+ "type": {
54045
+ "text": "CalendarPickerLocale"
54046
+ }
54047
+ }
54048
+ ]
54049
+ }
54050
+ ],
54051
+ "exports": [
54052
+ {
54053
+ "kind": "js",
54054
+ "name": "buildCalendarGrid",
54055
+ "declaration": {
54056
+ "name": "buildCalendarGrid",
54057
+ "module": "src/shared/picker-field/mixins/calendar-segments/calendarGrid.ts"
54058
+ }
54059
+ }
54060
+ ]
54061
+ },
54062
+ {
54063
+ "kind": "javascript-module",
54064
+ "path": "src/shared/picker-field/mixins/calendar-segments/monthPickerGrid.ts",
54065
+ "declarations": [
54066
+ {
54067
+ "kind": "variable",
54068
+ "name": "MonthsPerRow",
54069
+ "type": {
54070
+ "text": "number"
54071
+ },
54072
+ "default": "4"
54073
+ },
54074
+ {
54075
+ "kind": "function",
54076
+ "name": "buildMonthPickerGrid",
54077
+ "return": {
54078
+ "type": {
54079
+ "text": "MonthPickerGrid"
54080
+ }
54081
+ },
54082
+ "parameters": [
54083
+ {
54084
+ "name": "year",
54085
+ "type": {
54086
+ "text": "number"
54087
+ }
54088
+ },
54089
+ {
54090
+ "name": "locale",
54091
+ "type": {
54092
+ "text": "CalendarPickerLocale"
54093
+ }
54094
+ }
54095
+ ]
54096
+ }
54097
+ ],
54098
+ "exports": [
54099
+ {
54100
+ "kind": "js",
54101
+ "name": "MonthsPerRow",
54102
+ "declaration": {
54103
+ "name": "MonthsPerRow",
54104
+ "module": "src/shared/picker-field/mixins/calendar-segments/monthPickerGrid.ts"
54105
+ }
54106
+ },
54107
+ {
54108
+ "kind": "js",
54109
+ "name": "buildMonthPickerGrid",
54110
+ "declaration": {
54111
+ "name": "buildMonthPickerGrid",
54112
+ "module": "src/shared/picker-field/mixins/calendar-segments/monthPickerGrid.ts"
54113
+ }
54114
+ }
54115
+ ]
54116
+ },
54117
+ {
54118
+ "kind": "javascript-module",
54119
+ "path": "src/shared/picker-field/mixins/calendar-segments/segment.ts",
54120
+ "declarations": [],
54121
+ "exports": []
54122
+ },
54014
54123
  {
54015
54124
  "kind": "javascript-module",
54016
54125
  "path": "src/shared/picker-field/mixins/inline-time-picker/columns.ts",
@@ -54474,106 +54583,6 @@
54474
54583
  }
54475
54584
  ]
54476
54585
  },
54477
- {
54478
- "kind": "javascript-module",
54479
- "path": "src/shared/picker-field/mixins/calendar-segments/calendarGrid.ts",
54480
- "declarations": [
54481
- {
54482
- "kind": "function",
54483
- "name": "buildCalendarGrid",
54484
- "return": {
54485
- "type": {
54486
- "text": "CalendarGrid"
54487
- }
54488
- },
54489
- "parameters": [
54490
- {
54491
- "name": "month",
54492
- "type": {
54493
- "text": "Month"
54494
- }
54495
- },
54496
- {
54497
- "name": "locale",
54498
- "type": {
54499
- "text": "CalendarPickerLocale"
54500
- }
54501
- }
54502
- ]
54503
- }
54504
- ],
54505
- "exports": [
54506
- {
54507
- "kind": "js",
54508
- "name": "buildCalendarGrid",
54509
- "declaration": {
54510
- "name": "buildCalendarGrid",
54511
- "module": "src/shared/picker-field/mixins/calendar-segments/calendarGrid.ts"
54512
- }
54513
- }
54514
- ]
54515
- },
54516
- {
54517
- "kind": "javascript-module",
54518
- "path": "src/shared/picker-field/mixins/calendar-segments/monthPickerGrid.ts",
54519
- "declarations": [
54520
- {
54521
- "kind": "variable",
54522
- "name": "MonthsPerRow",
54523
- "type": {
54524
- "text": "number"
54525
- },
54526
- "default": "4"
54527
- },
54528
- {
54529
- "kind": "function",
54530
- "name": "buildMonthPickerGrid",
54531
- "return": {
54532
- "type": {
54533
- "text": "MonthPickerGrid"
54534
- }
54535
- },
54536
- "parameters": [
54537
- {
54538
- "name": "year",
54539
- "type": {
54540
- "text": "number"
54541
- }
54542
- },
54543
- {
54544
- "name": "locale",
54545
- "type": {
54546
- "text": "CalendarPickerLocale"
54547
- }
54548
- }
54549
- ]
54550
- }
54551
- ],
54552
- "exports": [
54553
- {
54554
- "kind": "js",
54555
- "name": "MonthsPerRow",
54556
- "declaration": {
54557
- "name": "MonthsPerRow",
54558
- "module": "src/shared/picker-field/mixins/calendar-segments/monthPickerGrid.ts"
54559
- }
54560
- },
54561
- {
54562
- "kind": "js",
54563
- "name": "buildMonthPickerGrid",
54564
- "declaration": {
54565
- "name": "buildMonthPickerGrid",
54566
- "module": "src/shared/picker-field/mixins/calendar-segments/monthPickerGrid.ts"
54567
- }
54568
- }
54569
- ]
54570
- },
54571
- {
54572
- "kind": "javascript-module",
54573
- "path": "src/shared/picker-field/mixins/calendar-segments/segment.ts",
54574
- "declarations": [],
54575
- "exports": []
54576
- },
54577
54586
  {
54578
54587
  "kind": "javascript-module",
54579
54588
  "path": "src/shared/deprecation/replaced-props.ts",
@@ -16,6 +16,7 @@ type EventBinding = [
16
16
  ];
17
17
  type CtxProps = {
18
18
  popupPlacement: 'top' | 'bottom';
19
+ shouldReturnFocusToEditor: boolean;
19
20
  menuOffset?: number;
20
21
  disabled?: boolean;
21
22
  };
@@ -28,6 +29,7 @@ export declare class UiCtx {
28
29
  private bindings;
29
30
  bindProp<T>(prop: Prop<T> | undefined, bindFn: (value: T) => void): void;
30
31
  updateBindings(): void;
32
+ shouldReturnFocusToEditor(): boolean;
31
33
  bindToEl<T extends Node>(target: T, props?: Partial<Props<T>>, events?: EventBinding[], children?: Array<Node>): void;
32
34
  }
33
35
  export declare const createDiv: (ctx: UiCtx, props: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vonage/vivid",
3
- "version": "5.20.0",
3
+ "version": "5.20.1",
4
4
  "homepage": "https://vivid.vonage.com",
5
5
  "bugs": {
6
6
  "url": "https://github.com/Vonage/vivid-3/issues"
@@ -88,16 +88,16 @@
88
88
  "wait-on": "^8.0.5",
89
89
  "@repo/cem-analyzer-plugins": "1.0.0",
90
90
  "@repo/eslint-config": "1.0.0",
91
- "@repo/shared": "1.0.0",
92
91
  "@repo/eslint-plugin-repo": "1.0.0",
92
+ "@repo/metadata-extractor": "1.0.0",
93
93
  "@repo/stylelint-config": "1.0.0",
94
- "@repo/tokens": "1.0.0",
94
+ "@repo/shared": "1.0.0",
95
95
  "@repo/styles": "1.0.0",
96
- "@repo/metadata-extractor": "1.0.0",
96
+ "@repo/tokens": "1.0.0",
97
97
  "@repo/tools": "1.0.0",
98
- "@repo/typescript-config": "1.0.0",
99
98
  "@repo/vitest-config": "1.0.0",
100
- "@vonage/vivid-icons": "4.10.0"
99
+ "@vonage/vivid-icons": "4.10.0",
100
+ "@repo/typescript-config": "1.0.0"
101
101
  },
102
102
  "customElements": "custom-elements.json",
103
103
  "scripts": {