diff --git a/civicpatch/2dba439c07ca.png b/civicpatch/2dba439c07ca.png
new file mode 100644
index 000000000..807d4fc61
Binary files /dev/null and b/civicpatch/2dba439c07ca.png differ
diff --git a/civicpatch/3e2771d8c6d7.png b/civicpatch/3e2771d8c6d7.png
new file mode 100644
index 000000000..868134407
Binary files /dev/null and b/civicpatch/3e2771d8c6d7.png differ
diff --git a/civicpatch/92a1a277f78b.png b/civicpatch/92a1a277f78b.png
new file mode 100644
index 000000000..d8a8e1a03
Binary files /dev/null and b/civicpatch/92a1a277f78b.png differ
diff --git a/civicpatch/Dockerfile b/civicpatch/Dockerfile
index 09a3240ce..11529048e 100644
--- a/civicpatch/Dockerfile
+++ b/civicpatch/Dockerfile
@@ -63,7 +63,7 @@ RUN poetry install
FROM image-base AS post-install
-RUN poetry run patchright install --with-deps chromium
+RUN poetry run patchright install --with-deps chrome
COPY --chown=civicpatch_user:civicpatch_user ${PROJECT_NAME}/src/setup.py /app/src/setup.py
RUN poetry run post-install
diff --git a/civicpatch/c8a27d7feb18.png b/civicpatch/c8a27d7feb18.png
new file mode 100644
index 000000000..194c4307b
Binary files /dev/null and b/civicpatch/c8a27d7feb18.png differ
diff --git a/civicpatch/docker-compose.development.yml b/civicpatch/docker-compose.development.yml
index ca33addbf..372e85b27 100644
--- a/civicpatch/docker-compose.development.yml
+++ b/civicpatch/docker-compose.development.yml
@@ -67,9 +67,15 @@ services:
target: development
environment:
CIVICPATCH_ENV: test
+ # Integration tests
+ GOOGLE_GEMINI_TOKEN: ${GOOGLE_GEMINI_TOKEN}
+ OPENAI_TOKEN: ${OPENAI_TOKEN}
+ TOGETHER_AI_TOKEN: ${TOGETHER_AI_TOKEN}
volumes:
- ./data:/app/data
- ./data_source:/app/data_source
+ - ../shared:/app/src/shared:ro
+ - .:/app
civicpatch_prod:
build:
diff --git a/civicpatch/mise.toml b/civicpatch/mise.toml
index 2188b11b5..7133a29a4 100644
--- a/civicpatch/mise.toml
+++ b/civicpatch/mise.toml
@@ -44,7 +44,12 @@ docker compose -f docker-compose.development.yml run --rm civicpatch pytest -vvm
[tasks.evals]
run = """
-docker compose -f docker-compose.development.yml run --rm civicpatch pytest -vvm evals tests/prompts
+docker compose -f docker-compose.development.yml run --rm civicpatch_test pytest -vvm evals tests/prompts
+"""
+
+[tasks.evals_relevant]
+run = """
+docker compose -f docker-compose.development.yml run --rm civicpatch_test pytest -vvm evals_relevant tests/prompts
"""
[tasks.scratchtest]
diff --git a/civicpatch/pytest.ini b/civicpatch/pytest.ini
index 160743be3..2076a8da6 100644
--- a/civicpatch/pytest.ini
+++ b/civicpatch/pytest.ini
@@ -4,6 +4,7 @@ markers =
integration: mark a test as an integration test
unit: mark a test as a unit test
evals: mark a test related to evaluations
+ evals_relevant: mark a test related to relevant page evaluation
contracts: mark a test related to contracts
# Add default options for pytest
diff --git a/civicpatch/src/frontend/build/bundle.js b/civicpatch/src/frontend/build/bundle.js
index 6360225ed..821d21de1 100644
--- a/civicpatch/src/frontend/build/bundle.js
+++ b/civicpatch/src/frontend/build/bundle.js
@@ -4,7 +4,7 @@ import{registerCivMap as e}from'@components';
* Copyright 2017 Google LLC
* SPDX-License-Identifier: BSD-3-Clause
*/
-const t=globalThis,n=e=>{t.emitLitDebugLogEvents&&t.dispatchEvent(new CustomEvent('lit-debug',{detail:e}))};let i,o=0;t.litIssuedWarnings??=new Set,i=(e,n)=>{n+=e?` See https://lit.dev/msg/${e} for more information.`:'',t.litIssuedWarnings.has(n)||t.litIssuedWarnings.has(e)||(console.warn(n),t.litIssuedWarnings.add(n))},queueMicrotask(()=>{i('dev-mode','Lit is in dev mode. Not recommended for production!')});const r=t.ShadyDOM?.inUse&&!0===t.ShadyDOM?.noPatch?t.ShadyDOM.wrap:e=>e,s=t.trustedTypes,a=s?s.createPolicy('lit-html',{createHTML:e=>e}):void 0,l=e=>e,c=(e,t,n)=>l,d=e=>{if(I!==c)throw new Error('Attempted to overwrite existing lit-html security policy. setSanitizeDOMValueFactory should be called at most once.');I=e},u=()=>{I=c},p=(e,t,n)=>I(e,t,n),h='$lit$',m=`lit$${Math.random().toFixed(9).slice(2)}$`,f='?'+m,g=`<${f}>`,b=document,v=()=>b.createComment(''),y=e=>null===e||'object'!=typeof e&&'function'!=typeof e,_=Array.isArray,$='[ \t\n\f\r]',w=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,x=/-->/g,k=/>/g,S=new RegExp(`>|${$}(?:([^\\s"'>=/]+)(${$}*=${$}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`,'g'),C=/'/g,A=/"/g,E=/^(?:script|style|textarea|title)$/i,O=(e=>(t,...n)=>(t.some(e=>void 0===e)&&console.warn('Some template strings are undefined.\nThis is probably caused by illegal octal escape sequences.'),n.some(e=>e?._$litStatic$)&&i('','Static values \'literal\' or \'unsafeStatic\' cannot be used as values to non-static templates.\nPlease use the static \'html\' tag function. See https://lit.dev/docs/templates/expressions/#static-expressions'),{_$litType$:e,strings:t,values:n}))(1),j=Symbol.for('lit-noChange'),P=Symbol.for('lit-nothing'),T=new WeakMap,N=b.createTreeWalker(b,129);let I=c;function M(e,t){if(!_(e)||!e.hasOwnProperty('raw')){let e='invalid template strings array';throw e='\n Internal Error: expected template strings to be an array\n with a \'raw\' field. Faking a template strings array by\n calling html or svg like an ordinary function is effectively\n the same as calling unsafeHtml and can lead to major security\n issues, e.g. opening your code up to XSS attacks.\n If you\'re using the html or svg tagged template functions normally\n and still seeing this error, please file a bug at\n https://github.com/lit/lit/issues/new?template=bug_report.md\n and include information about your build tooling, if any.\n '.trim().replace(/\n */g,'\n'),new Error(e)}return void 0!==a?a.createHTML(t):t}class D{constructor({strings:e,_$litType$:t},o){let r;this.parts=[];let a=0,l=0;const c=e.length-1,d=this.parts,[u,p]=((e,t)=>{const n=e.length-1,i=[];let o,r=2===t?'':3===t?'':'')),i]})(e,t);if(this.el=D.createElement(u,o),N.currentNode=this.el.content,2===t||3===t){const e=this.el.content.firstChild;e.replaceWith(...e.childNodes)}for(;null!==(r=N.nextNode())&&d.length0){r.textContent=s?s.emptyScript:'';for(let n=0;n" contains a duplicate "disabled" attribute. The error was detected in the following template: \n`'+e.join('${...}')+'`');n&&n({kind:'template prep',template:this,clonableTemplate:this.el,parts:this.parts,strings:e})}static createElement(e,t){const n=b.createElement('template');return n.innerHTML=e,n}}function L(e,t,n=e,i){if(t===j)return t;let o=void 0!==i?n.__directives?.[i]:n.__directive;const r=y(t)?void 0:t._$litDirective$;return o?.constructor!==r&&(o?._$notifyDirectiveConnectionChanged?.(!1),void 0===r?o=void 0:(o=new r(e),o._$initialize(e,n,i)),void 0!==i?(n.__directives??=[])[i]=o:n.__directive=o),void 0!==o&&(t=L(e,o._$resolve(e,t.values),o,i)),t}class U{constructor(e,t){this._$parts=[],this._$disconnectableChildren=void 0,this._$template=e,this._$parent=t}get parentNode(){return this._$parent.parentNode}get _$isConnected(){return this._$parent._$isConnected}_clone(e){const{el:{content:t},parts:n}=this._$template,i=(e?.creationScope??b).importNode(t,!0);N.currentNode=i;let o=N.nextNode(),r=0,s=0,a=n[0];for(;void 0!==a;){if(r===a.index){let t;2===a.type?t=new R(o,o.nextSibling,this,e):1===a.type?t=new a.ctor(o,a.name,a.strings,this,e):6===a.type&&(t=new W(o,this,e)),this._$parts.push(t),a=n[++s]}r!==a?.index&&(o=N.nextNode(),r++)}return N.currentNode=b,i}_update(e){let t=0;for(const i of this._$parts)void 0!==i&&(n&&n({kind:'set part',part:i,value:e[t],valueIndex:t,values:e,templateInstance:this}),void 0!==i.strings?(i._$setValue(e,i,t),t+=i.strings.length-2):i._$setValue(e[t])),t++}}class R{get _$isConnected(){return this._$parent?._$isConnected??this.__isConnected}constructor(e,t,n,i){this.type=2,this._$committedValue=P,this._$disconnectableChildren=void 0,this._$startNode=e,this._$endNode=t,this._$parent=n,this.options=i,this.__isConnected=i?.isConnected??!0,this._textSanitizer=void 0}get parentNode(){let e=r(this._$startNode).parentNode;const t=this._$parent;return void 0!==t&&11===e?.nodeType&&(e=t.parentNode),e}get startNode(){return this._$startNode}get endNode(){return this._$endNode}_$setValue(e,t=this){if(null===this.parentNode)throw new Error('This `ChildPart` has no `parentNode` and therefore cannot accept a value. This likely means the element containing the part was manipulated in an unsupported way outside of Lit\'s control such that the part\'s marker nodes were ejected from DOM. For example, setting the element\'s `innerHTML` or `textContent` can do this.');if(e=L(this,e,t),y(e))e===P||null==e||''===e?(this._$committedValue!==P&&(n&&n({kind:'commit nothing to child',start:this._$startNode,end:this._$endNode,parent:this._$parent,options:this.options}),this._$clear()),this._$committedValue=P):e!==this._$committedValue&&e!==j&&this._commitText(e);else if(void 0!==e._$litType$)this._commitTemplateResult(e);else if(void 0!==e.nodeType){if(this.options?.host===e)return this._commitText('[probable mistake: rendered a template\'s host in itself (commonly caused by writing ${this} in a template]'),void console.warn('Attempted to render the template host',e,'inside itself. This is almost always a mistake, and in dev mode ','we render some warning text. In production however, we\'ll ','render it, which will usually result in an error, and sometimes ','in the element disappearing from the DOM.');this._commitNode(e)}else(e=>_(e)||'function'==typeof e?.[Symbol.iterator])(e)?this._commitIterable(e):this._commitText(e)}_insert(e){return r(r(this._$startNode).parentNode).insertBefore(e,this._$endNode)}_commitNode(e){if(this._$committedValue!==e){if(this._$clear(),I!==c){const e=this._$startNode.parentNode?.nodeName;if('STYLE'===e||'SCRIPT'===e){let t='Forbidden';throw t='STYLE'===e?'Lit does not support binding inside style nodes. This is a security risk, as style injection attacks can exfiltrate data and spoof UIs. Consider instead using css`...` literals to compose styles, and do dynamic styling with css custom properties, ::parts, s, and by mutating the DOM rather than stylesheets.':'Lit does not support binding inside script nodes. This is a security risk, as it could allow arbitrary code execution.',new Error(t)}}n&&n({kind:'commit node',start:this._$startNode,parent:this._$parent,value:e,options:this.options}),this._$committedValue=this._insert(e)}}_commitText(e){if(this._$committedValue!==P&&y(this._$committedValue)){const t=r(this._$startNode).nextSibling;void 0===this._textSanitizer&&(this._textSanitizer=p(t,'data','property')),e=this._textSanitizer(e),n&&n({kind:'commit text',node:t,value:e,options:this.options}),t.data=e}else{const t=b.createTextNode('');this._commitNode(t),void 0===this._textSanitizer&&(this._textSanitizer=p(t,'data','property')),e=this._textSanitizer(e),n&&n({kind:'commit text',node:t,value:e,options:this.options}),t.data=e}this._$committedValue=e}_commitTemplateResult(e){const{values:t,_$litType$:i}=e,o='number'==typeof i?this._$getTemplate(e):(void 0===i.el&&(i.el=D.createElement(M(i.h,i.h[0]),this.options)),i);if(this._$committedValue?._$template===o)n&&n({kind:'template updating',template:o,instance:this._$committedValue,parts:this._$committedValue._$parts,options:this.options,values:t}),this._$committedValue._update(t);else{const e=new U(o,this),i=e._clone(this.options);n&&n({kind:'template instantiated',template:o,instance:e,parts:e._$parts,options:this.options,fragment:i,values:t}),e._update(t),n&&n({kind:'template instantiated and updated',template:o,instance:e,parts:e._$parts,options:this.options,fragment:i,values:t}),this._commitNode(i),this._$committedValue=e}}_$getTemplate(e){let t=T.get(e.strings);return void 0===t&&T.set(e.strings,t=new D(e)),t}_commitIterable(e){_(this._$committedValue)||(this._$committedValue=[],this._$clear());const t=this._$committedValue;let n,i=0;for(const o of e)i===t.length?t.push(n=new R(this._insert(v()),this._insert(v()),this,this.options)):n=t[i],n._$setValue(o),i++;i2||''!==n[0]||''!==n[1]?(this._$committedValue=new Array(n.length-1).fill(new String),this.strings=n):this._$committedValue=P,this._sanitizer=void 0}_$setValue(e,t=this,n,i){const o=this.strings;let r=!1;if(void 0===o)e=L(this,e,t,0),r=!y(e)||e!==this._$committedValue&&e!==j,r&&(this._$committedValue=e);else{const i=e;let s,a;for(e=o[0],s=0;s\` has a \`@${t}=...\` listener with invalid content. Event listeners in templates must have exactly one expression and no surrounding text.`)}_$setValue(e,t=this){if((e=L(this,e,t,0)??P)===j)return;const i=this._$committedValue,o=e===P&&i!==P||e.capture!==i.capture||e.once!==i.once||e.passive!==i.passive,r=e!==P&&(i===P||o);n&&n({kind:'commit event listener',element:this.element,name:this.name,value:e,options:this.options,removeListener:o,addListener:r,oldListener:i}),o&&this.element.removeEventListener(this.name,this,i),r&&this.element.addEventListener(this.name,this,e),this._$committedValue=e}handleEvent(e){'function'==typeof this._$committedValue?this._$committedValue.call(this.options?.host??this.element,e):this._$committedValue.handleEvent(e)}}class W{constructor(e,t,n){this.element=e,this.type=6,this._$disconnectableChildren=void 0,this._$parent=t,this.options=n}get _$isConnected(){return this._$parent._$isConnected}_$setValue(e){n&&n({kind:'commit to element binding',element:this.element,value:e,options:this.options}),L(this,e)}}const K=t.litHtmlPolyfillSupportDevMode;K?.(D,R),(t.litHtmlVersions??=[]).push('3.3.1'),t.litHtmlVersions.length>1&&queueMicrotask(()=>{i('multiple-versions','Multiple versions of Lit loaded. Loading multiple versions is not recommended.')});const Y=(e,t,i)=>{if(null==t)throw new TypeError(`The container to render into may not be ${t}`);const r=o++,s=i?.renderBefore??t;let a=s._$litPart$;if(n&&n({kind:'begin render',id:r,value:e,container:t,options:i,part:a}),void 0===a){const e=i?.renderBefore??null;s._$litPart$=a=new R(t.insertBefore(v(),e),e,void 0,i??{})}return a._$setValue(e),n&&n({kind:'end render',id:r,value:e,container:t,options:i,part:a}),a};let B;Y.setSanitizer=d,Y.createSanitizer=p,Y._testOnlyClearSanitizerFactoryDoNotCallOrElse=u;let H=0;function J(e){B=e}function G(){B=null,H=0}const Z=Symbol('haunted.phase'),Q=Symbol('haunted.hook'),X=Symbol('haunted.update'),ee=Symbol('haunted.commit'),te=Symbol('haunted.effects'),ne=Symbol('haunted.layoutEffects'),ie='haunted.context';let oe=class{update;host;virtual;[Q];[te];[ne];constructor(e,t){this.update=e,this.host=t,this[Q]=new Map,this[te]=[],this[ne]=[]}run(e){J(this);let t=e();return G(),t}_runEffects(e){let t=this[e];J(this);for(let e of t)e.call(this);G()}runEffects(){this._runEffects(te)}runLayoutEffects(){this._runEffects(ne)}teardown(){this[Q].forEach(e=>{'function'==typeof e.teardown&&e.teardown()})}};const re=Promise.resolve().then.bind(Promise.resolve());function se(){let e,t=[];function n(){e=null;let n=t;t=[];for(var i=0,o=n.length;i{t.push(i),null==e&&(e=re(n))}}const ae=se(),le=se();class ce{renderer;host;state;[Z];_updateQueued;constructor(e,t){this.renderer=e,this.host=t,this.state=new oe(this.update.bind(this),t),this[Z]=null,this._updateQueued=!1}update(){this._updateQueued||(ae(()=>{let e=this.handlePhase(X);le(()=>{this.handlePhase(ee,e),le(()=>{this.handlePhase(te)})}),this._updateQueued=!1}),this._updateQueued=!0)}handlePhase(e,t){switch(this[Z]=e,e){case ee:return this.commit(t),void this.runEffects(ne);case X:return this.render();case te:return this.runEffects(te)}}render(){return this.state.run(()=>this.renderer.call(this.host,this.host))}runEffects(e){this.state._runEffects(e)}teardown(){this.state.teardown()}}function de(e){class t extends ce{frag;constructor(e,t,n){super(e,n||t),this.frag=t}commit(t){e(t,this.frag)}}return function(e,n,i){const o=(i||n||{}).baseElement||HTMLElement,{observedAttributes:r=[],useShadowDOM:s=!0,shadowRootInit:a={}}=i||n||{};class l extends o{_scheduler;static get observedAttributes(){return e.observedAttributes||r||[]}constructor(){super(),!1===s?this._scheduler=new t(e,this):(this.attachShadow({mode:'open',...a}),this._scheduler=new t(e,this.shadowRoot,this))}connectedCallback(){this._scheduler.update()}disconnectedCallback(){this._scheduler.teardown()}attributeChangedCallback(e,t,n){if(t===n)return;let i=''===n||n;Reflect.set(this,((e='')=>e.replace(/-+([a-z])?/g,(e,t)=>t?t.toUpperCase():''))(e),i)}}const c=new Proxy(o.prototype,{getPrototypeOf:e=>e,set(e,t,n,i){let o;return t in e?(o=Object.getOwnPropertyDescriptor(e,t),o&&o.set?(o.set.call(i,n),!0):(Reflect.set(e,t,n,i),!0)):(o='symbol'==typeof t||'_'===t[0]?{enumerable:!0,configurable:!0,writable:!0,value:n}:function(e){let t=e,n=!1;return Object.freeze({enumerable:!0,configurable:!0,get:()=>t,set(e){n&&t===e||(n=!0,t=e,this._scheduler&&this._scheduler.update())}})}(n),Object.defineProperty(i,t,o),o.set&&o.set.call(i,n),!0)}});return Object.setPrototypeOf(l.prototype,c),l}}class ue{id;state;constructor(e,t){this.id=e,this.state=t}}function pe(e,...t){let n=H++,i=B[Q],o=i.get(n);return o||(o=new e(n,B,...t),i.set(n,o)),o.update(...t)}function he(e){return pe.bind(null,e)}function me(e){return he(class extends ue{callback;lastValues;values;_teardown;constructor(t,n,i,o){super(t,n),e(n,this)}update(e,t){this.callback=e,this.values=t}call(){const e=!this.values||this.hasChanged();this.lastValues=this.values,e&&this.run()}run(){this.teardown(),this._teardown=this.callback.call(this.state)}teardown(){'function'==typeof this._teardown&&this._teardown()}hasChanged(){return!this.lastValues||this.values.some((e,t)=>this.lastValues[t]!==e)}})}function fe(e,t){e[te].push(t)}const ge=me(fe),be=he(class extends ue{Context;value;_ranEffect;_unsubscribe;constructor(e,t,n){super(e,t),this._updater=this._updater.bind(this),this._ranEffect=!1,this._unsubscribe=null,fe(t,this)}update(e){if(this.state.virtual)throw new Error('can\'t be used with virtual components');return this.Context!==e&&(this._subscribe(e),this.Context=e),this.value}call(){this._ranEffect||(this._ranEffect=!0,this._unsubscribe&&this._unsubscribe(),this._subscribe(this.Context),this.state.update())}_updater(e){this.value=e,this.state.update()}_subscribe(e){const t={Context:e,callback:this._updater};this.state.host.dispatchEvent(new CustomEvent(ie,{detail:t,bubbles:!0,cancelable:!0,composed:!0}));const{unsubscribe:n=null,value:i}=t;this.value=n?i:e.defaultValue,this._unsubscribe=n}teardown(){this._unsubscribe&&this._unsubscribe()}});const ve=he(class extends ue{value;values;constructor(e,t,n,i){super(e,t),this.value=n(),this.values=i}update(e,t){return this.hasChanged(t)&&(this.values=t,this.value=e()),this.value}hasChanged(e=[]){return e.some((e,t)=>this.values[t]!==e)}}),ye=(e,t)=>ve(()=>e,t);me(function(e,t){e[ne].push(t)});const _e=he(class extends ue{args;constructor(e,t,n){if(super(e,t),this.updater=this.updater.bind(this),'function'==typeof n){n=n()}this.makeArgs(n)}update(){return this.args}updater(e){const[t]=this.args;if('function'==typeof e){e=e(t)}Object.is(t,e)||(this.makeArgs(e),this.state.update())}makeArgs(e){this.args=Object.freeze([e,this.updater])}});
+const t=globalThis,n=e=>{t.emitLitDebugLogEvents&&t.dispatchEvent(new CustomEvent('lit-debug',{detail:e}))};let i,o=0;t.litIssuedWarnings??=new Set,i=(e,n)=>{n+=e?` See https://lit.dev/msg/${e} for more information.`:'',t.litIssuedWarnings.has(n)||t.litIssuedWarnings.has(e)||(console.warn(n),t.litIssuedWarnings.add(n))},queueMicrotask(()=>{i('dev-mode','Lit is in dev mode. Not recommended for production!')});const r=t.ShadyDOM?.inUse&&!0===t.ShadyDOM?.noPatch?t.ShadyDOM.wrap:e=>e,s=t.trustedTypes,a=s?s.createPolicy('lit-html',{createHTML:e=>e}):void 0,l=e=>e,c=(e,t,n)=>l,d=e=>{if(I!==c)throw new Error('Attempted to overwrite existing lit-html security policy. setSanitizeDOMValueFactory should be called at most once.');I=e},u=()=>{I=c},p=(e,t,n)=>I(e,t,n),h='$lit$',m=`lit$${Math.random().toFixed(9).slice(2)}$`,f='?'+m,g=`<${f}>`,b=document,v=()=>b.createComment(''),y=e=>null===e||'object'!=typeof e&&'function'!=typeof e,_=Array.isArray,$='[ \t\n\f\r]',w=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,x=/-->/g,k=/>/g,S=new RegExp(`>|${$}(?:([^\\s"'>=/]+)(${$}*=${$}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`,'g'),C=/'/g,A=/"/g,E=/^(?:script|style|textarea|title)$/i,O=(e=>(t,...n)=>(t.some(e=>void 0===e)&&console.warn('Some template strings are undefined.\nThis is probably caused by illegal octal escape sequences.'),n.some(e=>e?._$litStatic$)&&i('','Static values \'literal\' or \'unsafeStatic\' cannot be used as values to non-static templates.\nPlease use the static \'html\' tag function. See https://lit.dev/docs/templates/expressions/#static-expressions'),{_$litType$:e,strings:t,values:n}))(1),j=Symbol.for('lit-noChange'),P=Symbol.for('lit-nothing'),N=new WeakMap,T=b.createTreeWalker(b,129);let I=c;function M(e,t){if(!_(e)||!e.hasOwnProperty('raw')){let e='invalid template strings array';throw e='\n Internal Error: expected template strings to be an array\n with a \'raw\' field. Faking a template strings array by\n calling html or svg like an ordinary function is effectively\n the same as calling unsafeHtml and can lead to major security\n issues, e.g. opening your code up to XSS attacks.\n If you\'re using the html or svg tagged template functions normally\n and still seeing this error, please file a bug at\n https://github.com/lit/lit/issues/new?template=bug_report.md\n and include information about your build tooling, if any.\n '.trim().replace(/\n */g,'\n'),new Error(e)}return void 0!==a?a.createHTML(t):t}class D{constructor({strings:e,_$litType$:t},o){let r;this.parts=[];let a=0,l=0;const c=e.length-1,d=this.parts,[u,p]=((e,t)=>{const n=e.length-1,i=[];let o,r=2===t?'':3===t?'':'')),i]})(e,t);if(this.el=D.createElement(u,o),T.currentNode=this.el.content,2===t||3===t){const e=this.el.content.firstChild;e.replaceWith(...e.childNodes)}for(;null!==(r=T.nextNode())&&d.length0){r.textContent=s?s.emptyScript:'';for(let n=0;n" contains a duplicate "disabled" attribute. The error was detected in the following template: \n`'+e.join('${...}')+'`');n&&n({kind:'template prep',template:this,clonableTemplate:this.el,parts:this.parts,strings:e})}static createElement(e,t){const n=b.createElement('template');return n.innerHTML=e,n}}function L(e,t,n=e,i){if(t===j)return t;let o=void 0!==i?n.__directives?.[i]:n.__directive;const r=y(t)?void 0:t._$litDirective$;return o?.constructor!==r&&(o?._$notifyDirectiveConnectionChanged?.(!1),void 0===r?o=void 0:(o=new r(e),o._$initialize(e,n,i)),void 0!==i?(n.__directives??=[])[i]=o:n.__directive=o),void 0!==o&&(t=L(e,o._$resolve(e,t.values),o,i)),t}class U{constructor(e,t){this._$parts=[],this._$disconnectableChildren=void 0,this._$template=e,this._$parent=t}get parentNode(){return this._$parent.parentNode}get _$isConnected(){return this._$parent._$isConnected}_clone(e){const{el:{content:t},parts:n}=this._$template,i=(e?.creationScope??b).importNode(t,!0);T.currentNode=i;let o=T.nextNode(),r=0,s=0,a=n[0];for(;void 0!==a;){if(r===a.index){let t;2===a.type?t=new R(o,o.nextSibling,this,e):1===a.type?t=new a.ctor(o,a.name,a.strings,this,e):6===a.type&&(t=new W(o,this,e)),this._$parts.push(t),a=n[++s]}r!==a?.index&&(o=T.nextNode(),r++)}return T.currentNode=b,i}_update(e){let t=0;for(const i of this._$parts)void 0!==i&&(n&&n({kind:'set part',part:i,value:e[t],valueIndex:t,values:e,templateInstance:this}),void 0!==i.strings?(i._$setValue(e,i,t),t+=i.strings.length-2):i._$setValue(e[t])),t++}}class R{get _$isConnected(){return this._$parent?._$isConnected??this.__isConnected}constructor(e,t,n,i){this.type=2,this._$committedValue=P,this._$disconnectableChildren=void 0,this._$startNode=e,this._$endNode=t,this._$parent=n,this.options=i,this.__isConnected=i?.isConnected??!0,this._textSanitizer=void 0}get parentNode(){let e=r(this._$startNode).parentNode;const t=this._$parent;return void 0!==t&&11===e?.nodeType&&(e=t.parentNode),e}get startNode(){return this._$startNode}get endNode(){return this._$endNode}_$setValue(e,t=this){if(null===this.parentNode)throw new Error('This `ChildPart` has no `parentNode` and therefore cannot accept a value. This likely means the element containing the part was manipulated in an unsupported way outside of Lit\'s control such that the part\'s marker nodes were ejected from DOM. For example, setting the element\'s `innerHTML` or `textContent` can do this.');if(e=L(this,e,t),y(e))e===P||null==e||''===e?(this._$committedValue!==P&&(n&&n({kind:'commit nothing to child',start:this._$startNode,end:this._$endNode,parent:this._$parent,options:this.options}),this._$clear()),this._$committedValue=P):e!==this._$committedValue&&e!==j&&this._commitText(e);else if(void 0!==e._$litType$)this._commitTemplateResult(e);else if(void 0!==e.nodeType){if(this.options?.host===e)return this._commitText('[probable mistake: rendered a template\'s host in itself (commonly caused by writing ${this} in a template]'),void console.warn('Attempted to render the template host',e,'inside itself. This is almost always a mistake, and in dev mode ','we render some warning text. In production however, we\'ll ','render it, which will usually result in an error, and sometimes ','in the element disappearing from the DOM.');this._commitNode(e)}else(e=>_(e)||'function'==typeof e?.[Symbol.iterator])(e)?this._commitIterable(e):this._commitText(e)}_insert(e){return r(r(this._$startNode).parentNode).insertBefore(e,this._$endNode)}_commitNode(e){if(this._$committedValue!==e){if(this._$clear(),I!==c){const e=this._$startNode.parentNode?.nodeName;if('STYLE'===e||'SCRIPT'===e){let t='Forbidden';throw t='STYLE'===e?'Lit does not support binding inside style nodes. This is a security risk, as style injection attacks can exfiltrate data and spoof UIs. Consider instead using css`...` literals to compose styles, and do dynamic styling with css custom properties, ::parts, s, and by mutating the DOM rather than stylesheets.':'Lit does not support binding inside script nodes. This is a security risk, as it could allow arbitrary code execution.',new Error(t)}}n&&n({kind:'commit node',start:this._$startNode,parent:this._$parent,value:e,options:this.options}),this._$committedValue=this._insert(e)}}_commitText(e){if(this._$committedValue!==P&&y(this._$committedValue)){const t=r(this._$startNode).nextSibling;void 0===this._textSanitizer&&(this._textSanitizer=p(t,'data','property')),e=this._textSanitizer(e),n&&n({kind:'commit text',node:t,value:e,options:this.options}),t.data=e}else{const t=b.createTextNode('');this._commitNode(t),void 0===this._textSanitizer&&(this._textSanitizer=p(t,'data','property')),e=this._textSanitizer(e),n&&n({kind:'commit text',node:t,value:e,options:this.options}),t.data=e}this._$committedValue=e}_commitTemplateResult(e){const{values:t,_$litType$:i}=e,o='number'==typeof i?this._$getTemplate(e):(void 0===i.el&&(i.el=D.createElement(M(i.h,i.h[0]),this.options)),i);if(this._$committedValue?._$template===o)n&&n({kind:'template updating',template:o,instance:this._$committedValue,parts:this._$committedValue._$parts,options:this.options,values:t}),this._$committedValue._update(t);else{const e=new U(o,this),i=e._clone(this.options);n&&n({kind:'template instantiated',template:o,instance:e,parts:e._$parts,options:this.options,fragment:i,values:t}),e._update(t),n&&n({kind:'template instantiated and updated',template:o,instance:e,parts:e._$parts,options:this.options,fragment:i,values:t}),this._commitNode(i),this._$committedValue=e}}_$getTemplate(e){let t=N.get(e.strings);return void 0===t&&N.set(e.strings,t=new D(e)),t}_commitIterable(e){_(this._$committedValue)||(this._$committedValue=[],this._$clear());const t=this._$committedValue;let n,i=0;for(const o of e)i===t.length?t.push(n=new R(this._insert(v()),this._insert(v()),this,this.options)):n=t[i],n._$setValue(o),i++;i2||''!==n[0]||''!==n[1]?(this._$committedValue=new Array(n.length-1).fill(new String),this.strings=n):this._$committedValue=P,this._sanitizer=void 0}_$setValue(e,t=this,n,i){const o=this.strings;let r=!1;if(void 0===o)e=L(this,e,t,0),r=!y(e)||e!==this._$committedValue&&e!==j,r&&(this._$committedValue=e);else{const i=e;let s,a;for(e=o[0],s=0;s\` has a \`@${t}=...\` listener with invalid content. Event listeners in templates must have exactly one expression and no surrounding text.`)}_$setValue(e,t=this){if((e=L(this,e,t,0)??P)===j)return;const i=this._$committedValue,o=e===P&&i!==P||e.capture!==i.capture||e.once!==i.once||e.passive!==i.passive,r=e!==P&&(i===P||o);n&&n({kind:'commit event listener',element:this.element,name:this.name,value:e,options:this.options,removeListener:o,addListener:r,oldListener:i}),o&&this.element.removeEventListener(this.name,this,i),r&&this.element.addEventListener(this.name,this,e),this._$committedValue=e}handleEvent(e){'function'==typeof this._$committedValue?this._$committedValue.call(this.options?.host??this.element,e):this._$committedValue.handleEvent(e)}}class W{constructor(e,t,n){this.element=e,this.type=6,this._$disconnectableChildren=void 0,this._$parent=t,this.options=n}get _$isConnected(){return this._$parent._$isConnected}_$setValue(e){n&&n({kind:'commit to element binding',element:this.element,value:e,options:this.options}),L(this,e)}}const K=t.litHtmlPolyfillSupportDevMode;K?.(D,R),(t.litHtmlVersions??=[]).push('3.3.1'),t.litHtmlVersions.length>1&&queueMicrotask(()=>{i('multiple-versions','Multiple versions of Lit loaded. Loading multiple versions is not recommended.')});const Y=(e,t,i)=>{if(null==t)throw new TypeError(`The container to render into may not be ${t}`);const r=o++,s=i?.renderBefore??t;let a=s._$litPart$;if(n&&n({kind:'begin render',id:r,value:e,container:t,options:i,part:a}),void 0===a){const e=i?.renderBefore??null;s._$litPart$=a=new R(t.insertBefore(v(),e),e,void 0,i??{})}return a._$setValue(e),n&&n({kind:'end render',id:r,value:e,container:t,options:i,part:a}),a};let B;Y.setSanitizer=d,Y.createSanitizer=p,Y._testOnlyClearSanitizerFactoryDoNotCallOrElse=u;let H=0;function J(e){B=e}function G(){B=null,H=0}const Z=Symbol('haunted.phase'),Q=Symbol('haunted.hook'),X=Symbol('haunted.update'),ee=Symbol('haunted.commit'),te=Symbol('haunted.effects'),ne=Symbol('haunted.layoutEffects'),ie='haunted.context';let oe=class{update;host;virtual;[Q];[te];[ne];constructor(e,t){this.update=e,this.host=t,this[Q]=new Map,this[te]=[],this[ne]=[]}run(e){J(this);let t=e();return G(),t}_runEffects(e){let t=this[e];J(this);for(let e of t)e.call(this);G()}runEffects(){this._runEffects(te)}runLayoutEffects(){this._runEffects(ne)}teardown(){this[Q].forEach(e=>{'function'==typeof e.teardown&&e.teardown()})}};const re=Promise.resolve().then.bind(Promise.resolve());function se(){let e,t=[];function n(){e=null;let n=t;t=[];for(var i=0,o=n.length;i{t.push(i),null==e&&(e=re(n))}}const ae=se(),le=se();class ce{renderer;host;state;[Z];_updateQueued;constructor(e,t){this.renderer=e,this.host=t,this.state=new oe(this.update.bind(this),t),this[Z]=null,this._updateQueued=!1}update(){this._updateQueued||(ae(()=>{let e=this.handlePhase(X);le(()=>{this.handlePhase(ee,e),le(()=>{this.handlePhase(te)})}),this._updateQueued=!1}),this._updateQueued=!0)}handlePhase(e,t){switch(this[Z]=e,e){case ee:return this.commit(t),void this.runEffects(ne);case X:return this.render();case te:return this.runEffects(te)}}render(){return this.state.run(()=>this.renderer.call(this.host,this.host))}runEffects(e){this.state._runEffects(e)}teardown(){this.state.teardown()}}function de(e){class t extends ce{frag;constructor(e,t,n){super(e,n||t),this.frag=t}commit(t){e(t,this.frag)}}return function(e,n,i){const o=(i||n||{}).baseElement||HTMLElement,{observedAttributes:r=[],useShadowDOM:s=!0,shadowRootInit:a={}}=i||n||{};class l extends o{_scheduler;static get observedAttributes(){return e.observedAttributes||r||[]}constructor(){super(),!1===s?this._scheduler=new t(e,this):(this.attachShadow({mode:'open',...a}),this._scheduler=new t(e,this.shadowRoot,this))}connectedCallback(){this._scheduler.update()}disconnectedCallback(){this._scheduler.teardown()}attributeChangedCallback(e,t,n){if(t===n)return;let i=''===n||n;Reflect.set(this,((e='')=>e.replace(/-+([a-z])?/g,(e,t)=>t?t.toUpperCase():''))(e),i)}}const c=new Proxy(o.prototype,{getPrototypeOf:e=>e,set(e,t,n,i){let o;return t in e?(o=Object.getOwnPropertyDescriptor(e,t),o&&o.set?(o.set.call(i,n),!0):(Reflect.set(e,t,n,i),!0)):(o='symbol'==typeof t||'_'===t[0]?{enumerable:!0,configurable:!0,writable:!0,value:n}:function(e){let t=e,n=!1;return Object.freeze({enumerable:!0,configurable:!0,get:()=>t,set(e){n&&t===e||(n=!0,t=e,this._scheduler&&this._scheduler.update())}})}(n),Object.defineProperty(i,t,o),o.set&&o.set.call(i,n),!0)}});return Object.setPrototypeOf(l.prototype,c),l}}class ue{id;state;constructor(e,t){this.id=e,this.state=t}}function pe(e,...t){let n=H++,i=B[Q],o=i.get(n);return o||(o=new e(n,B,...t),i.set(n,o)),o.update(...t)}function he(e){return pe.bind(null,e)}function me(e){return he(class extends ue{callback;lastValues;values;_teardown;constructor(t,n,i,o){super(t,n),e(n,this)}update(e,t){this.callback=e,this.values=t}call(){const e=!this.values||this.hasChanged();this.lastValues=this.values,e&&this.run()}run(){this.teardown(),this._teardown=this.callback.call(this.state)}teardown(){'function'==typeof this._teardown&&this._teardown()}hasChanged(){return!this.lastValues||this.values.some((e,t)=>this.lastValues[t]!==e)}})}function fe(e,t){e[te].push(t)}const ge=me(fe),be=he(class extends ue{Context;value;_ranEffect;_unsubscribe;constructor(e,t,n){super(e,t),this._updater=this._updater.bind(this),this._ranEffect=!1,this._unsubscribe=null,fe(t,this)}update(e){if(this.state.virtual)throw new Error('can\'t be used with virtual components');return this.Context!==e&&(this._subscribe(e),this.Context=e),this.value}call(){this._ranEffect||(this._ranEffect=!0,this._unsubscribe&&this._unsubscribe(),this._subscribe(this.Context),this.state.update())}_updater(e){this.value=e,this.state.update()}_subscribe(e){const t={Context:e,callback:this._updater};this.state.host.dispatchEvent(new CustomEvent(ie,{detail:t,bubbles:!0,cancelable:!0,composed:!0}));const{unsubscribe:n=null,value:i}=t;this.value=n?i:e.defaultValue,this._unsubscribe=n}teardown(){this._unsubscribe&&this._unsubscribe()}});const ve=he(class extends ue{value;values;constructor(e,t,n,i){super(e,t),this.value=n(),this.values=i}update(e,t){return this.hasChanged(t)&&(this.values=t,this.value=e()),this.value}hasChanged(e=[]){return e.some((e,t)=>this.values[t]!==e)}}),ye=(e,t)=>ve(()=>e,t);me(function(e,t){e[ne].push(t)});const _e=he(class extends ue{args;constructor(e,t,n){if(super(e,t),this.updater=this.updater.bind(this),'function'==typeof n){n=n()}this.makeArgs(n)}update(){return this.args}updater(e){const[t]=this.args;if('function'==typeof e){e=e(t)}Object.is(t,e)||(this.makeArgs(e),this.state.update())}makeArgs(e){this.args=Object.freeze([e,this.updater])}});
/**
* @license
* Portions Copyright 2021 Google LLC
@@ -20,7 +20,7 @@ const $e=2;class we{constructor(e){}get _$isConnected(){return this._$parent._$i
* @license
* Copyright 2019 Google LLC
* SPDX-License-Identifier: BSD-3-Clause
- */const xe=globalThis,ke=xe.ShadowRoot&&(void 0===xe.ShadyCSS||xe.ShadyCSS.nativeShadow)&&'adoptedStyleSheets'in Document.prototype&&'replace'in CSSStyleSheet.prototype,Se=Symbol(),Ce=new WeakMap;class Ae{constructor(e,t,n){if(this._$cssResult$=!0,n!==Se)throw new Error('CSSResult is not constructable. Use `unsafeCSS` or `css` instead.');this.cssText=e,this._strings=t}get styleSheet(){let e=this._styleSheet;const t=this._strings;if(ke&&void 0===e){const n=void 0!==t&&1===t.length;n&&(e=Ce.get(t)),void 0===e&&((this._styleSheet=e=new CSSStyleSheet).replaceSync(this.cssText),n&&Ce.set(t,e))}return e}toString(){return this.cssText}}const Ee=e=>{let t='';for(const n of e.cssRules)t+=n.cssText;return new Ae('string'==typeof(n=t)?n:String(n),void 0,Se);var n},Oe=ke?e=>e:e=>e instanceof CSSStyleSheet?Ee(e):e,{is:je,defineProperty:Pe,getOwnPropertyDescriptor:Te,getOwnPropertyNames:Ne,getOwnPropertySymbols:Ie,getPrototypeOf:Me}=Object,De=globalThis;let Le;const Ue=De.trustedTypes,Re=Ue?Ue.emptyScript:'',Ve=De.reactiveElementPolyfillSupportDevMode;De.litIssuedWarnings??=new Set,Le=(e,t)=>{t+=` See https://lit.dev/msg/${e} for more information.`,De.litIssuedWarnings.has(t)||De.litIssuedWarnings.has(e)||(console.warn(t),De.litIssuedWarnings.add(t))},queueMicrotask(()=>{Le('dev-mode','Lit is in dev mode. Not recommended for production!'),De.ShadyDOM?.inUse&&void 0===Ve&&Le('polyfill-support-missing','Shadow DOM is being polyfilled via `ShadyDOM` but the `polyfill-support` module has not been loaded.')});const ze=(e,t)=>e,Fe={toAttribute(e,t){switch(t){case Boolean:e=e?Re:null;break;case Object:case Array:e=null==e?e:JSON.stringify(e)}return e},fromAttribute(e,t){let n=e;switch(t){case Boolean:n=null!==e;break;case Number:n=null===e?null:Number(e);break;case Object:case Array:try{n=JSON.parse(e)}catch(e){n=null}}return n}},qe=(e,t)=>!je(e,t),We={attribute:!0,type:String,converter:Fe,reflect:!1,useDefault:!1,hasChanged:qe};Symbol.metadata??=Symbol('metadata'),De.litPropertyMetadata??=new WeakMap;class Ke extends HTMLElement{static addInitializer(e){this.__prepare(),(this._initializers??=[]).push(e)}static get observedAttributes(){return this.finalize(),this.__attributeToPropertyMap&&[...this.__attributeToPropertyMap.keys()]}static createProperty(e,t=We){if(t.state&&(t.attribute=!1),this.__prepare(),this.prototype.hasOwnProperty(e)&&((t=Object.create(t)).wrapped=!0),this.elementProperties.set(e,t),!t.noAccessor){const n=Symbol.for(`${String(e)} (@property() cache)`),i=this.getPropertyDescriptor(e,n,t);void 0!==i&&Pe(this.prototype,e,i)}}static getPropertyDescriptor(e,t,n){const{get:i,set:o}=Te(this.prototype,e)??{get(){return this[t]},set(e){this[t]=e}};if(null==i){if('value'in(Te(this.prototype,e)??{}))throw new Error(`Field ${JSON.stringify(String(e))} on ${this.name} was declared as a reactive property but it's actually declared as a value on the prototype. Usually this is due to using @property or @state on a method.`);Le('reactive-property-without-getter',`Field ${JSON.stringify(String(e))} on ${this.name} was declared as a reactive property but it does not have a getter. This will be an error in a future version of Lit.`)}return{get:i,set(t){const r=i?.call(this);o?.call(this,t),this.requestUpdate(e,r,n)},configurable:!0,enumerable:!0}}static getPropertyOptions(e){return this.elementProperties.get(e)??We}static __prepare(){if(this.hasOwnProperty(ze('elementProperties')))return;const e=Me(this);e.finalize(),void 0!==e._initializers&&(this._initializers=[...e._initializers]),this.elementProperties=new Map(e.elementProperties)}static finalize(){if(this.hasOwnProperty(ze('finalized')))return;if(this.finalized=!0,this.__prepare(),this.hasOwnProperty(ze('properties'))){const e=this.properties,t=[...Ne(e),...Ie(e)];for(const n of t)this.createProperty(n,e[n])}const e=this[Symbol.metadata];if(null!==e){const t=litPropertyMetadata.get(e);if(void 0!==t)for(const[e,n]of t)this.elementProperties.set(e,n)}this.__attributeToPropertyMap=new Map;for(const[e,t]of this.elementProperties){const n=this.__attributeNameForProperty(e,t);void 0!==n&&this.__attributeToPropertyMap.set(n,e)}this.elementStyles=this.finalizeStyles(this.styles),this.hasOwnProperty('createProperty')&&Le('no-override-create-property','Overriding ReactiveElement.createProperty() is deprecated. The override will not be called with standard decorators'),this.hasOwnProperty('getPropertyDescriptor')&&Le('no-override-get-property-descriptor','Overriding ReactiveElement.getPropertyDescriptor() is deprecated. The override will not be called with standard decorators')}static finalizeStyles(e){const t=[];if(Array.isArray(e)){const n=new Set(e.flat(1/0).reverse());for(const e of n)t.unshift(Oe(e))}else void 0!==e&&t.push(Oe(e));return t}static __attributeNameForProperty(e,t){const n=t.attribute;return!1===n?void 0:'string'==typeof n?n:'string'==typeof e?e.toLowerCase():void 0}constructor(){super(),this.__instanceProperties=void 0,this.isUpdatePending=!1,this.hasUpdated=!1,this.__reflectingProperty=null,this.__initialize()}__initialize(){this.__updatePromise=new Promise(e=>this.enableUpdating=e),this._$changedProperties=new Map,this.__saveInstanceProperties(),this.requestUpdate(),this.constructor._initializers?.forEach(e=>e(this))}addController(e){(this.__controllers??=new Set).add(e),void 0!==this.renderRoot&&this.isConnected&&e.hostConnected?.()}removeController(e){this.__controllers?.delete(e)}__saveInstanceProperties(){const e=new Map,t=this.constructor.elementProperties;for(const n of t.keys())this.hasOwnProperty(n)&&(e.set(n,this[n]),delete this[n]);e.size>0&&(this.__instanceProperties=e)}createRenderRoot(){const e=this.shadowRoot??this.attachShadow(this.constructor.shadowRootOptions);return((e,t)=>{if(ke)e.adoptedStyleSheets=t.map(e=>e instanceof CSSStyleSheet?e:e.styleSheet);else for(const n of t){const t=document.createElement('style'),i=xe.litNonce;void 0!==i&&t.setAttribute('nonce',i),t.textContent=n.cssText,e.appendChild(t)}})(e,this.constructor.elementStyles),e}connectedCallback(){this.renderRoot??=this.createRenderRoot(),this.enableUpdating(!0),this.__controllers?.forEach(e=>e.hostConnected?.())}enableUpdating(e){}disconnectedCallback(){this.__controllers?.forEach(e=>e.hostDisconnected?.())}attributeChangedCallback(e,t,n){this._$attributeToProperty(e,n)}__propertyToAttribute(e,t){const n=this.constructor.elementProperties.get(e),i=this.constructor.__attributeNameForProperty(e,n);if(void 0!==i&&!0===n.reflect){const o=(void 0!==n.converter?.toAttribute?n.converter:Fe).toAttribute(t,n.type);this.constructor.enabledWarnings.includes('migration')&&void 0===o&&Le('undefined-attribute-value',`The attribute value for the ${e} property is undefined on element ${this.localName}. The attribute will be removed, but in the previous version of \`ReactiveElement\`, the attribute would not have changed.`),this.__reflectingProperty=e,null==o?this.removeAttribute(i):this.setAttribute(i,o),this.__reflectingProperty=null}}_$attributeToProperty(e,t){const n=this.constructor,i=n.__attributeToPropertyMap.get(e);if(void 0!==i&&this.__reflectingProperty!==i){const e=n.getPropertyOptions(i),o='function'==typeof e.converter?{fromAttribute:e.converter}:void 0!==e.converter?.fromAttribute?e.converter:Fe;this.__reflectingProperty=i;const r=o.fromAttribute(t,e.type);this[i]=r??this.__defaultValues?.get(i)??r,this.__reflectingProperty=null}}requestUpdate(e,t,n){if(void 0!==e){e instanceof Event&&Le('','The requestUpdate() method was called with an Event as the property name. This is probably a mistake caused by binding this.requestUpdate as an event listener. Instead bind a function that will call it with no arguments: () => this.requestUpdate()');const i=this.constructor,o=this[e];n??=i.getPropertyOptions(e);if(!((n.hasChanged??qe)(o,t)||n.useDefault&&n.reflect&&o===this.__defaultValues?.get(e)&&!this.hasAttribute(i.__attributeNameForProperty(e,n))))return;this._$changeProperty(e,t,n)}!1===this.isUpdatePending&&(this.__updatePromise=this.__enqueueUpdate())}_$changeProperty(e,t,{useDefault:n,reflect:i,wrapped:o},r){n&&!(this.__defaultValues??=new Map).has(e)&&(this.__defaultValues.set(e,r??t??this[e]),!0!==o||void 0!==r)||(this._$changedProperties.has(e)||(this.hasUpdated||n||(t=void 0),this._$changedProperties.set(e,t)),!0===i&&this.__reflectingProperty!==e&&(this.__reflectingProperties??=new Set).add(e))}async __enqueueUpdate(){this.isUpdatePending=!0;try{await this.__updatePromise}catch(e){Promise.reject(e)}const e=this.scheduleUpdate();return null!=e&&await e,!this.isUpdatePending}scheduleUpdate(){const e=this.performUpdate();return this.constructor.enabledWarnings.includes('async-perform-update')&&'function'==typeof e?.then&&Le('async-perform-update',`Element ${this.localName} returned a Promise from performUpdate(). This behavior is deprecated and will be removed in a future version of ReactiveElement.`),e}performUpdate(){if(!this.isUpdatePending)return;var e;if(e={kind:'update'},De.emitLitDebugLogEvents&&De.dispatchEvent(new CustomEvent('lit-debug',{detail:e})),!this.hasUpdated){this.renderRoot??=this.createRenderRoot();{const e=[...this.constructor.elementProperties.keys()].filter(e=>this.hasOwnProperty(e)&&e in Me(this));if(e.length)throw new Error(`The following properties on element ${this.localName} will not trigger updates as expected because they are set using class fields: ${e.join(', ')}. Native class fields and some compiled output will overwrite accessors used for detecting changes. See https://lit.dev/msg/class-field-shadowing for more information.`)}if(this.__instanceProperties){for(const[e,t]of this.__instanceProperties)this[e]=t;this.__instanceProperties=void 0}const e=this.constructor.elementProperties;if(e.size>0)for(const[t,n]of e){const{wrapped:e}=n,i=this[t];!0!==e||this._$changedProperties.has(t)||void 0===i||this._$changeProperty(t,void 0,n,i)}}let t=!1;const n=this._$changedProperties;try{t=this.shouldUpdate(n),t?(this.willUpdate(n),this.__controllers?.forEach(e=>e.hostUpdate?.()),this.update(n)):this.__markUpdated()}catch(e){throw t=!1,this.__markUpdated(),e}t&&this._$didUpdate(n)}willUpdate(e){}_$didUpdate(e){this.__controllers?.forEach(e=>e.hostUpdated?.()),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(e)),this.updated(e),this.isUpdatePending&&this.constructor.enabledWarnings.includes('change-in-update')&&Le('change-in-update',`Element ${this.localName} scheduled an update (generally because a property was set) after an update completed, causing a new update to be scheduled. This is inefficient and should be avoided unless the next update can only be scheduled as a side effect of the previous update.`)}__markUpdated(){this._$changedProperties=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this.__updatePromise}shouldUpdate(e){return!0}update(e){this.__reflectingProperties&&=this.__reflectingProperties.forEach(e=>this.__propertyToAttribute(e,this[e])),this.__markUpdated()}updated(e){}firstUpdated(e){}}Ke.elementStyles=[],Ke.shadowRootOptions={mode:'open'},Ke[ze('elementProperties')]=new Map,Ke[ze('finalized')]=new Map,Ve?.({ReactiveElement:Ke});{Ke.enabledWarnings=['change-in-update','async-perform-update'];const e=e=>{e.hasOwnProperty(ze('enabledWarnings'))||(e.enabledWarnings=e.enabledWarnings.slice())};Ke.enableWarning=function(t){e(this),this.enabledWarnings.includes(t)||this.enabledWarnings.push(t)},Ke.disableWarning=function(t){e(this);const n=this.enabledWarnings.indexOf(t);n>=0&&this.enabledWarnings.splice(n,1)}}(De.reactiveElementVersions??=[]).push('2.1.1'),De.reactiveElementVersions.length>1&&queueMicrotask(()=>{Le('multiple-versions','Multiple versions of Lit loaded. Loading multiple versions is not recommended.')})
+ */const xe=globalThis,ke=xe.ShadowRoot&&(void 0===xe.ShadyCSS||xe.ShadyCSS.nativeShadow)&&'adoptedStyleSheets'in Document.prototype&&'replace'in CSSStyleSheet.prototype,Se=Symbol(),Ce=new WeakMap;class Ae{constructor(e,t,n){if(this._$cssResult$=!0,n!==Se)throw new Error('CSSResult is not constructable. Use `unsafeCSS` or `css` instead.');this.cssText=e,this._strings=t}get styleSheet(){let e=this._styleSheet;const t=this._strings;if(ke&&void 0===e){const n=void 0!==t&&1===t.length;n&&(e=Ce.get(t)),void 0===e&&((this._styleSheet=e=new CSSStyleSheet).replaceSync(this.cssText),n&&Ce.set(t,e))}return e}toString(){return this.cssText}}const Ee=e=>{let t='';for(const n of e.cssRules)t+=n.cssText;return new Ae('string'==typeof(n=t)?n:String(n),void 0,Se);var n},Oe=ke?e=>e:e=>e instanceof CSSStyleSheet?Ee(e):e,{is:je,defineProperty:Pe,getOwnPropertyDescriptor:Ne,getOwnPropertyNames:Te,getOwnPropertySymbols:Ie,getPrototypeOf:Me}=Object,De=globalThis;let Le;const Ue=De.trustedTypes,Re=Ue?Ue.emptyScript:'',Ve=De.reactiveElementPolyfillSupportDevMode;De.litIssuedWarnings??=new Set,Le=(e,t)=>{t+=` See https://lit.dev/msg/${e} for more information.`,De.litIssuedWarnings.has(t)||De.litIssuedWarnings.has(e)||(console.warn(t),De.litIssuedWarnings.add(t))},queueMicrotask(()=>{Le('dev-mode','Lit is in dev mode. Not recommended for production!'),De.ShadyDOM?.inUse&&void 0===Ve&&Le('polyfill-support-missing','Shadow DOM is being polyfilled via `ShadyDOM` but the `polyfill-support` module has not been loaded.')});const ze=(e,t)=>e,Fe={toAttribute(e,t){switch(t){case Boolean:e=e?Re:null;break;case Object:case Array:e=null==e?e:JSON.stringify(e)}return e},fromAttribute(e,t){let n=e;switch(t){case Boolean:n=null!==e;break;case Number:n=null===e?null:Number(e);break;case Object:case Array:try{n=JSON.parse(e)}catch(e){n=null}}return n}},qe=(e,t)=>!je(e,t),We={attribute:!0,type:String,converter:Fe,reflect:!1,useDefault:!1,hasChanged:qe};Symbol.metadata??=Symbol('metadata'),De.litPropertyMetadata??=new WeakMap;class Ke extends HTMLElement{static addInitializer(e){this.__prepare(),(this._initializers??=[]).push(e)}static get observedAttributes(){return this.finalize(),this.__attributeToPropertyMap&&[...this.__attributeToPropertyMap.keys()]}static createProperty(e,t=We){if(t.state&&(t.attribute=!1),this.__prepare(),this.prototype.hasOwnProperty(e)&&((t=Object.create(t)).wrapped=!0),this.elementProperties.set(e,t),!t.noAccessor){const n=Symbol.for(`${String(e)} (@property() cache)`),i=this.getPropertyDescriptor(e,n,t);void 0!==i&&Pe(this.prototype,e,i)}}static getPropertyDescriptor(e,t,n){const{get:i,set:o}=Ne(this.prototype,e)??{get(){return this[t]},set(e){this[t]=e}};if(null==i){if('value'in(Ne(this.prototype,e)??{}))throw new Error(`Field ${JSON.stringify(String(e))} on ${this.name} was declared as a reactive property but it's actually declared as a value on the prototype. Usually this is due to using @property or @state on a method.`);Le('reactive-property-without-getter',`Field ${JSON.stringify(String(e))} on ${this.name} was declared as a reactive property but it does not have a getter. This will be an error in a future version of Lit.`)}return{get:i,set(t){const r=i?.call(this);o?.call(this,t),this.requestUpdate(e,r,n)},configurable:!0,enumerable:!0}}static getPropertyOptions(e){return this.elementProperties.get(e)??We}static __prepare(){if(this.hasOwnProperty(ze('elementProperties')))return;const e=Me(this);e.finalize(),void 0!==e._initializers&&(this._initializers=[...e._initializers]),this.elementProperties=new Map(e.elementProperties)}static finalize(){if(this.hasOwnProperty(ze('finalized')))return;if(this.finalized=!0,this.__prepare(),this.hasOwnProperty(ze('properties'))){const e=this.properties,t=[...Te(e),...Ie(e)];for(const n of t)this.createProperty(n,e[n])}const e=this[Symbol.metadata];if(null!==e){const t=litPropertyMetadata.get(e);if(void 0!==t)for(const[e,n]of t)this.elementProperties.set(e,n)}this.__attributeToPropertyMap=new Map;for(const[e,t]of this.elementProperties){const n=this.__attributeNameForProperty(e,t);void 0!==n&&this.__attributeToPropertyMap.set(n,e)}this.elementStyles=this.finalizeStyles(this.styles),this.hasOwnProperty('createProperty')&&Le('no-override-create-property','Overriding ReactiveElement.createProperty() is deprecated. The override will not be called with standard decorators'),this.hasOwnProperty('getPropertyDescriptor')&&Le('no-override-get-property-descriptor','Overriding ReactiveElement.getPropertyDescriptor() is deprecated. The override will not be called with standard decorators')}static finalizeStyles(e){const t=[];if(Array.isArray(e)){const n=new Set(e.flat(1/0).reverse());for(const e of n)t.unshift(Oe(e))}else void 0!==e&&t.push(Oe(e));return t}static __attributeNameForProperty(e,t){const n=t.attribute;return!1===n?void 0:'string'==typeof n?n:'string'==typeof e?e.toLowerCase():void 0}constructor(){super(),this.__instanceProperties=void 0,this.isUpdatePending=!1,this.hasUpdated=!1,this.__reflectingProperty=null,this.__initialize()}__initialize(){this.__updatePromise=new Promise(e=>this.enableUpdating=e),this._$changedProperties=new Map,this.__saveInstanceProperties(),this.requestUpdate(),this.constructor._initializers?.forEach(e=>e(this))}addController(e){(this.__controllers??=new Set).add(e),void 0!==this.renderRoot&&this.isConnected&&e.hostConnected?.()}removeController(e){this.__controllers?.delete(e)}__saveInstanceProperties(){const e=new Map,t=this.constructor.elementProperties;for(const n of t.keys())this.hasOwnProperty(n)&&(e.set(n,this[n]),delete this[n]);e.size>0&&(this.__instanceProperties=e)}createRenderRoot(){const e=this.shadowRoot??this.attachShadow(this.constructor.shadowRootOptions);return((e,t)=>{if(ke)e.adoptedStyleSheets=t.map(e=>e instanceof CSSStyleSheet?e:e.styleSheet);else for(const n of t){const t=document.createElement('style'),i=xe.litNonce;void 0!==i&&t.setAttribute('nonce',i),t.textContent=n.cssText,e.appendChild(t)}})(e,this.constructor.elementStyles),e}connectedCallback(){this.renderRoot??=this.createRenderRoot(),this.enableUpdating(!0),this.__controllers?.forEach(e=>e.hostConnected?.())}enableUpdating(e){}disconnectedCallback(){this.__controllers?.forEach(e=>e.hostDisconnected?.())}attributeChangedCallback(e,t,n){this._$attributeToProperty(e,n)}__propertyToAttribute(e,t){const n=this.constructor.elementProperties.get(e),i=this.constructor.__attributeNameForProperty(e,n);if(void 0!==i&&!0===n.reflect){const o=(void 0!==n.converter?.toAttribute?n.converter:Fe).toAttribute(t,n.type);this.constructor.enabledWarnings.includes('migration')&&void 0===o&&Le('undefined-attribute-value',`The attribute value for the ${e} property is undefined on element ${this.localName}. The attribute will be removed, but in the previous version of \`ReactiveElement\`, the attribute would not have changed.`),this.__reflectingProperty=e,null==o?this.removeAttribute(i):this.setAttribute(i,o),this.__reflectingProperty=null}}_$attributeToProperty(e,t){const n=this.constructor,i=n.__attributeToPropertyMap.get(e);if(void 0!==i&&this.__reflectingProperty!==i){const e=n.getPropertyOptions(i),o='function'==typeof e.converter?{fromAttribute:e.converter}:void 0!==e.converter?.fromAttribute?e.converter:Fe;this.__reflectingProperty=i;const r=o.fromAttribute(t,e.type);this[i]=r??this.__defaultValues?.get(i)??r,this.__reflectingProperty=null}}requestUpdate(e,t,n){if(void 0!==e){e instanceof Event&&Le('','The requestUpdate() method was called with an Event as the property name. This is probably a mistake caused by binding this.requestUpdate as an event listener. Instead bind a function that will call it with no arguments: () => this.requestUpdate()');const i=this.constructor,o=this[e];n??=i.getPropertyOptions(e);if(!((n.hasChanged??qe)(o,t)||n.useDefault&&n.reflect&&o===this.__defaultValues?.get(e)&&!this.hasAttribute(i.__attributeNameForProperty(e,n))))return;this._$changeProperty(e,t,n)}!1===this.isUpdatePending&&(this.__updatePromise=this.__enqueueUpdate())}_$changeProperty(e,t,{useDefault:n,reflect:i,wrapped:o},r){n&&!(this.__defaultValues??=new Map).has(e)&&(this.__defaultValues.set(e,r??t??this[e]),!0!==o||void 0!==r)||(this._$changedProperties.has(e)||(this.hasUpdated||n||(t=void 0),this._$changedProperties.set(e,t)),!0===i&&this.__reflectingProperty!==e&&(this.__reflectingProperties??=new Set).add(e))}async __enqueueUpdate(){this.isUpdatePending=!0;try{await this.__updatePromise}catch(e){Promise.reject(e)}const e=this.scheduleUpdate();return null!=e&&await e,!this.isUpdatePending}scheduleUpdate(){const e=this.performUpdate();return this.constructor.enabledWarnings.includes('async-perform-update')&&'function'==typeof e?.then&&Le('async-perform-update',`Element ${this.localName} returned a Promise from performUpdate(). This behavior is deprecated and will be removed in a future version of ReactiveElement.`),e}performUpdate(){if(!this.isUpdatePending)return;var e;if(e={kind:'update'},De.emitLitDebugLogEvents&&De.dispatchEvent(new CustomEvent('lit-debug',{detail:e})),!this.hasUpdated){this.renderRoot??=this.createRenderRoot();{const e=[...this.constructor.elementProperties.keys()].filter(e=>this.hasOwnProperty(e)&&e in Me(this));if(e.length)throw new Error(`The following properties on element ${this.localName} will not trigger updates as expected because they are set using class fields: ${e.join(', ')}. Native class fields and some compiled output will overwrite accessors used for detecting changes. See https://lit.dev/msg/class-field-shadowing for more information.`)}if(this.__instanceProperties){for(const[e,t]of this.__instanceProperties)this[e]=t;this.__instanceProperties=void 0}const e=this.constructor.elementProperties;if(e.size>0)for(const[t,n]of e){const{wrapped:e}=n,i=this[t];!0!==e||this._$changedProperties.has(t)||void 0===i||this._$changeProperty(t,void 0,n,i)}}let t=!1;const n=this._$changedProperties;try{t=this.shouldUpdate(n),t?(this.willUpdate(n),this.__controllers?.forEach(e=>e.hostUpdate?.()),this.update(n)):this.__markUpdated()}catch(e){throw t=!1,this.__markUpdated(),e}t&&this._$didUpdate(n)}willUpdate(e){}_$didUpdate(e){this.__controllers?.forEach(e=>e.hostUpdated?.()),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(e)),this.updated(e),this.isUpdatePending&&this.constructor.enabledWarnings.includes('change-in-update')&&Le('change-in-update',`Element ${this.localName} scheduled an update (generally because a property was set) after an update completed, causing a new update to be scheduled. This is inefficient and should be avoided unless the next update can only be scheduled as a side effect of the previous update.`)}__markUpdated(){this._$changedProperties=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this.__updatePromise}shouldUpdate(e){return!0}update(e){this.__reflectingProperties&&=this.__reflectingProperties.forEach(e=>this.__propertyToAttribute(e,this[e])),this.__markUpdated()}updated(e){}firstUpdated(e){}}Ke.elementStyles=[],Ke.shadowRootOptions={mode:'open'},Ke[ze('elementProperties')]=new Map,Ke[ze('finalized')]=new Map,Ve?.({ReactiveElement:Ke});{Ke.enabledWarnings=['change-in-update','async-perform-update'];const e=e=>{e.hasOwnProperty(ze('enabledWarnings'))||(e.enabledWarnings=e.enabledWarnings.slice())};Ke.enableWarning=function(t){e(this),this.enabledWarnings.includes(t)||this.enabledWarnings.push(t)},Ke.disableWarning=function(t){e(this);const n=this.enabledWarnings.indexOf(t);n>=0&&this.enabledWarnings.splice(n,1)}}(De.reactiveElementVersions??=[]).push('2.1.1'),De.reactiveElementVersions.length>1&&queueMicrotask(()=>{Le('multiple-versions','Multiple versions of Lit loaded. Loading multiple versions is not recommended.')})
/**
* @license
* Copyright 2017 Google LLC
@@ -626,121 +626,87 @@ function ct(e){return null==e}customElements.define('civ-autocomplete-select',ot
.footer=${b}
.modalProps=${i}
>
- `},{useShadowDOM:!1})),customElements.define('person-card',ot(function({person:e,onSelect:t,onChange:n,onDelete:i,onReset:o}){const r=(t,i,o)=>{const r=[...e[t]||[]];r[i]=o,n&&n(t,r)},s=t=>{const i=[...e[t]||[]];i.push(''),n&&n(t,i)},a=(t,i)=>{const o=[...e[t]||[]];o.splice(i,1),n&&n(t,o)},l=(e,t)=>{n&&n(e,t)},c=e._changes?.includes('name'),d=e._changes?.includes('office'),u=e._changes?.includes('start_date'),p=e._changes?.includes('end_date'),h=e._changes?.includes('phones'),m=e._changes?.includes('emails'),f=e._changes?.includes('other_names'),g=e._changes?.includes('urls'),b=e._changes?.includes('source_urls'),v=e._changes?.includes('image'),y=e.image||e.cdn_image||null;return O`
-
- toggleSelect(e._tempKey)}
- >
-
- {e.stopPropagation(),t&&t(e.target.checked)}}
- aria-label="Select ${e.name}"
- ?disabled=${e._deleted}
- />
-
+
+ ${r?x:w}
+
${e._changes&&e._changes.length>0?O`
`:''}
- `},{observedAttributes:['person'],useShadowDOM:!1}));var dt={isNothing:ct,isObject:function(e){return'object'==typeof e&&null!==e},toArray:function(e){return Array.isArray(e)?e:ct(e)?[]:[e]},repeat:function(e,t){var n,i='';for(n=0;na&&(t=i-a+(r=' ... ').length),n-i>a&&(n=i+a-(s=' ...').length),{str:r+e.slice(t,n).replace(/\t/g,'→')+s,pos:i-t+r.length}}function ft(e,t){return dt.repeat(' ',t-e.length)+e}var gt=function(e,t){if(t=Object.create(t||null),!e.buffer)return null;t.maxLength||(t.maxLength=79),'number'!=typeof t.indent&&(t.indent=1),'number'!=typeof t.linesBefore&&(t.linesBefore=3),'number'!=typeof t.linesAfter&&(t.linesAfter=2);for(var n,i=/\r?\n|\r|\0/g,o=[0],r=[],s=-1;n=i.exec(e.buffer);)r.push(n.index),o.push(n.index+n[0].length),e.position<=n.index&&s<0&&(s=o.length-2);s<0&&(s=o.length-1);var a,l,c='',d=Math.min(e.line+t.linesAfter,r.length).toString().length,u=t.maxLength-(t.indent+d+3);for(a=1;a<=t.linesBefore&&!(s-a<0);a++)l=mt(e.buffer,o[s-a],r[s-a],e.position-(o[s]-o[s-a]),u),c=dt.repeat(' ',t.indent)+ft((e.line-a+1).toString(),d)+' | '+l.str+'\n'+c;for(l=mt(e.buffer,o[s],r[s],e.position,u),c+=dt.repeat(' ',t.indent)+ft((e.line+1).toString(),d)+' | '+l.str+'\n',c+=dt.repeat('-',t.indent+d+3+l.pos)+'^\n',a=1;a<=t.linesAfter&&!(s+a>=r.length);a++)l=mt(e.buffer,o[s+a],r[s+a],e.position-(o[s]-o[s+a]),u),c+=dt.repeat(' ',t.indent)+ft((e.line+a+1).toString(),d)+' | '+l.str+'\n';return c.replace(/\n$/,'')},bt=['kind','multi','resolve','construct','instanceOf','predicate','represent','representName','defaultStyle','styleAliases'],vt=['scalar','sequence','mapping'];var yt=function(e,t){if(t=t||{},Object.keys(t).forEach(t=>{if(-1===bt.indexOf(t))throw new ht('Unknown option "'+t+'" is met in definition of "'+e+'" YAML type.')}),this.options=t,this.tag=e,this.kind=t.kind||null,this.resolve=t.resolve||(()=>!0),this.construct=t.construct||(e=>e),this.instanceOf=t.instanceOf||null,this.predicate=t.predicate||null,this.represent=t.represent||null,this.representName=t.representName||null,this.defaultStyle=t.defaultStyle||null,this.multi=t.multi||!1,this.styleAliases=function(e){var t={};return null!==e&&Object.keys(e).forEach(n=>{e[n].forEach(e=>{t[String(e)]=n})}),t}(t.styleAliases||null),-1===vt.indexOf(this.kind))throw new ht('Unknown kind "'+this.kind+'" is specified for "'+e+'" YAML type.')};function _t(e,t){var n=[];return e[t].forEach(e=>{var t=n.length;n.forEach((n,i)=>{n.tag===e.tag&&n.kind===e.kind&&n.multi===e.multi&&(t=i)}),n[t]=e}),n}function $t(e){return this.extend(e)}$t.prototype.extend=function(e){var t=[],n=[];if(e instanceof yt)n.push(e);else if(Array.isArray(e))n=n.concat(e);else{if(!e||!Array.isArray(e.implicit)&&!Array.isArray(e.explicit))throw new ht('Schema.extend argument should be a Type, [ Type ], or a schema definition ({ implicit: [...], explicit: [...] })');e.implicit&&(t=t.concat(e.implicit)),e.explicit&&(n=n.concat(e.explicit))}t.forEach(e=>{if(!(e instanceof yt))throw new ht('Specified list of YAML types (or a single Type object) contains a non-Type object.');if(e.loadKind&&'scalar'!==e.loadKind)throw new ht('There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.');if(e.multi)throw new ht('There is a multi type in the implicit list of a schema. Multi tags can only be listed as explicit.')}),n.forEach(e=>{if(!(e instanceof yt))throw new ht('Specified list of YAML types (or a single Type object) contains a non-Type object.')});var i=Object.create($t.prototype);return i.implicit=(this.implicit||[]).concat(t),i.explicit=(this.explicit||[]).concat(n),i.compiledImplicit=_t(i,'implicit'),i.compiledExplicit=_t(i,'explicit'),i.compiledTypeMap=function(){var e,t,n={scalar:{},sequence:{},mapping:{},fallback:{},multi:{scalar:[],sequence:[],mapping:[],fallback:[]}};function i(e){e.multi?(n.multi[e.kind].push(e),n.multi.fallback.push(e)):n[e.kind][e.tag]=n.fallback[e.tag]=e}for(e=0,t=arguments.length;enull!==e?e:''}),kt=new yt('tag:yaml.org,2002:seq',{kind:'sequence',construct:e=>null!==e?e:[]}),St=new yt('tag:yaml.org,2002:map',{kind:'mapping',construct:e=>null!==e?e:{}}),Ct=new wt({explicit:[xt,kt,St]});var At=new yt('tag:yaml.org,2002:null',{kind:'scalar',resolve:function(e){if(null===e)return!0;var t=e.length;return 1===t&&'~'===e||4===t&&('null'===e||'Null'===e||'NULL'===e)},construct:function(){return null},predicate:function(e){return null===e},represent:{canonical:()=>'~',lowercase:()=>'null',uppercase:()=>'NULL',camelcase:()=>'Null',empty:()=>''},defaultStyle:'lowercase'});var Et=new yt('tag:yaml.org,2002:bool',{kind:'scalar',resolve:function(e){if(null===e)return!1;var t=e.length;return 4===t&&('true'===e||'True'===e||'TRUE'===e)||5===t&&('false'===e||'False'===e||'FALSE'===e)},construct:function(e){return'true'===e||'True'===e||'TRUE'===e},predicate:function(e){return'[object Boolean]'===Object.prototype.toString.call(e)},represent:{lowercase:e=>e?'true':'false',uppercase:e=>e?'TRUE':'FALSE',camelcase:e=>e?'True':'False'},defaultStyle:'lowercase'});function Ot(e){return 48<=e&&e<=57||65<=e&&e<=70||97<=e&&e<=102}function jt(e){return 48<=e&&e<=55}function Pt(e){return 48<=e&&e<=57}var Tt=new yt('tag:yaml.org,2002:int',{kind:'scalar',resolve:function(e){if(null===e)return!1;var t,n=e.length,i=0,o=!1;if(!n)return!1;if('-'!==(t=e[i])&&'+'!==t||(t=e[++i]),'0'===t){if(i+1===n)return!0;if('b'===(t=e[++i])){for(i++;ie>=0?'0b'+e.toString(2):'-0b'+e.toString(2).slice(1),octal:e=>e>=0?'0o'+e.toString(8):'-0o'+e.toString(8).slice(1),decimal:e=>e.toString(10),hexadecimal:e=>e>=0?'0x'+e.toString(16).toUpperCase():'-0x'+e.toString(16).toUpperCase().slice(1)},defaultStyle:'decimal',styleAliases:{binary:[2,'bin'],octal:[8,'oct'],decimal:[10,'dec'],hexadecimal:[16,'hex']}}),Nt=new RegExp('^(?:[-+]?(?:[0-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$');var It=/^[-+]?[0-9]+e/;var Mt=new yt('tag:yaml.org,2002:float',{kind:'scalar',resolve:function(e){return null!==e&&!(!Nt.test(e)||'_'===e[e.length-1])},construct:function(e){var t,n;return n='-'===(t=e.replace(/_/g,'').toLowerCase())[0]?-1:1,'+-'.indexOf(t[0])>=0&&(t=t.slice(1)),'.inf'===t?1===n?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY:'.nan'===t?NaN:n*parseFloat(t,10)},predicate:function(e){return'[object Number]'===Object.prototype.toString.call(e)&&(e%1!=0||dt.isNegativeZero(e))},represent:function(e,t){var n;if(isNaN(e))switch(t){case'lowercase':return'.nan';case'uppercase':return'.NAN';case'camelcase':return'.NaN'}else if(Number.POSITIVE_INFINITY===e)switch(t){case'lowercase':return'.inf';case'uppercase':return'.INF';case'camelcase':return'.Inf'}else if(Number.NEGATIVE_INFINITY===e)switch(t){case'lowercase':return'-.inf';case'uppercase':return'-.INF';case'camelcase':return'-.Inf'}else if(dt.isNegativeZero(e))return'-0.0';return n=e.toString(10),It.test(n)?n.replace('e','.e'):n},defaultStyle:'lowercase'}),Dt=Ct.extend({implicit:[At,Et,Tt,Mt]}),Lt=Dt,Ut=new RegExp('^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$'),Rt=new RegExp('^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$');var Vt=new yt('tag:yaml.org,2002:timestamp',{kind:'scalar',resolve:function(e){return null!==e&&(null!==Ut.exec(e)||null!==Rt.exec(e))},construct:function(e){var t,n,i,o,r,s,a,l,c=0,d=null;if(null===(t=Ut.exec(e))&&(t=Rt.exec(e)),null===t)throw new Error('Date resolve error');if(n=+t[1],i=+t[2]-1,o=+t[3],!t[4])return new Date(Date.UTC(n,i,o));if(r=+t[4],s=+t[5],a=+t[6],t[7]){for(c=t[7].slice(0,3);c.length<3;)c+='0';c=+c}return t[9]&&(d=6e4*(60*+t[10]+ +(t[11]||0)),'-'===t[9]&&(d=-d)),l=new Date(Date.UTC(n,i,o,r,s,a,c)),d&&l.setTime(l.getTime()-d),l},instanceOf:Date,represent:function(e){return e.toISOString()}});var zt=new yt('tag:yaml.org,2002:merge',{kind:'scalar',resolve:function(e){return'<<'===e||null===e}}),Ft='ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=\n\r';var qt=new yt('tag:yaml.org,2002:binary',{kind:'scalar',resolve:function(e){if(null===e)return!1;var t,n,i=0,o=e.length,r=Ft;for(n=0;n64)){if(t<0)return!1;i+=6}return i%8==0},construct:function(e){var t,n,i=e.replace(/[\r\n=]/g,''),o=i.length,r=Ft,s=0,a=[];for(t=0;t>16&255),a.push(s>>8&255),a.push(255&s)),s=s<<6|r.indexOf(i.charAt(t));return 0===(n=o%4*6)?(a.push(s>>16&255),a.push(s>>8&255),a.push(255&s)):18===n?(a.push(s>>10&255),a.push(s>>2&255)):12===n&&a.push(s>>4&255),new Uint8Array(a)},predicate:function(e){return'[object Uint8Array]'===Object.prototype.toString.call(e)},represent:function(e){var t,n,i='',o=0,r=e.length,s=Ft;for(t=0;t>18&63],i+=s[o>>12&63],i+=s[o>>6&63],i+=s[63&o]),o=(o<<8)+e[t];return 0===(n=r%3)?(i+=s[o>>18&63],i+=s[o>>12&63],i+=s[o>>6&63],i+=s[63&o]):2===n?(i+=s[o>>10&63],i+=s[o>>4&63],i+=s[o<<2&63],i+=s[64]):1===n&&(i+=s[o>>2&63],i+=s[o<<4&63],i+=s[64],i+=s[64]),i}}),Wt=Object.prototype.hasOwnProperty,Kt=Object.prototype.toString;var Yt=new yt('tag:yaml.org,2002:omap',{kind:'sequence',resolve:function(e){if(null===e)return!0;var t,n,i,o,r,s=[],a=e;for(t=0,n=a.length;t>10),56320+(e-65536&1023))}function fn(e,t,n){'__proto__'===t?Object.defineProperty(e,t,{configurable:!0,enumerable:!0,writable:!0,value:n}):e[t]=n}for(var gn=new Array(256),bn=new Array(256),vn=0;vn<256;vn++)gn[vn]=hn(vn)?1:0,bn[vn]=hn(vn);function yn(e,t){this.input=e,this.filename=t.filename||null,this.schema=t.schema||Zt,this.onWarning=t.onWarning||null,this.legacy=t.legacy||!1,this.json=t.json||!1,this.listener=t.listener||null,this.implicitTypes=this.schema.compiledImplicit,this.typeMap=this.schema.compiledTypeMap,this.length=e.length,this.position=0,this.line=0,this.lineStart=0,this.lineIndent=0,this.firstTabInLine=-1,this.documents=[]}function _n(e,t){var n={name:e.filename,buffer:e.input.slice(0,-1),position:e.position,line:e.line,column:e.position-e.lineStart};return n.snippet=gt(n),new ht(t,n)}function $n(e,t){throw _n(e,t)}function wn(e,t){e.onWarning&&e.onWarning.call(null,_n(e,t))}var xn={YAML:function(e,t,n){var i,o,r;null!==e.version&&$n(e,'duplication of %YAML directive'),1!==n.length&&$n(e,'YAML directive accepts exactly one argument'),null===(i=/^([0-9]+)\.([0-9]+)$/.exec(n[0]))&&$n(e,'ill-formed argument of the YAML directive'),o=parseInt(i[1],10),r=parseInt(i[2],10),1!==o&&$n(e,'unacceptable YAML version of the document'),e.version=n[0],e.checkLineBreaks=r<2,1!==r&&2!==r&&wn(e,'unsupported YAML version of the document')},TAG:function(e,t,n){var i,o;2!==n.length&&$n(e,'TAG directive accepts exactly two arguments'),i=n[0],o=n[1],nn.test(i)||$n(e,'ill-formed tag handle (first argument) of the TAG directive'),Qt.call(e.tagMap,i)&&$n(e,'there is a previously declared suffix for "'+i+'" tag handle'),on.test(o)||$n(e,'ill-formed tag prefix (second argument) of the TAG directive');try{o=decodeURIComponent(o)}catch(t){$n(e,'tag prefix is malformed: '+o)}e.tagMap[i]=o}};function kn(e,t,n,i){var o,r,s,a;if(t1&&(e.result+=dt.repeat('\n',t-1))}function Pn(e,t){var n,i,o=e.tag,r=e.anchor,s=[],a=!1;if(-1!==e.firstTabInLine)return!1;for(null!==e.anchor&&(e.anchorMap[e.anchor]=s),i=e.input.charCodeAt(e.position);0!==i&&(-1!==e.firstTabInLine&&(e.position=e.firstTabInLine,$n(e,'tab characters must not be used in indentation')),45===i)&&ln(e.input.charCodeAt(e.position+1));)if(a=!0,e.position++,En(e,!0,-1)&&e.lineIndent<=t)s.push(null),i=e.input.charCodeAt(e.position);else if(n=e.line,In(e,t,3,!1,!0),s.push(e.result),En(e,!0,-1),i=e.input.charCodeAt(e.position),(e.line===n||e.lineIndent>t)&&0!==i)$n(e,'bad indentation of a sequence entry');else if(e.lineIndentt?m=1:e.lineIndent===t?m=0:e.lineIndentt?m=1:e.lineIndent===t?m=0:e.lineIndentt)&&(b&&(s=e.line,a=e.lineStart,l=e.position),In(e,t,4,!0,o)&&(b?f=e.result:g=e.result),b||(Cn(e,p,h,m,f,g,s,a,l),m=f=g=null),En(e,!0,-1),c=e.input.charCodeAt(e.position)),(e.line===r||e.lineIndent>t)&&0!==c)$n(e,'bad indentation of a mapping entry');else if(e.lineIndent=0))break;0===o?$n(e,'bad explicit indentation width of a block scalar; it cannot be less than one'):l?$n(e,'repeat of an indentation width identifier'):(c=t+o-1,l=!0)}if(an(r)){do{r=e.input.charCodeAt(++e.position)}while(an(r));if(35===r)do{r=e.input.charCodeAt(++e.position)}while(!sn(r)&&0!==r)}for(;0!==r;){for(An(e),e.lineIndent=0,r=e.input.charCodeAt(e.position);(!l||e.lineIndentc&&(c=e.lineIndent),sn(r))d++;else{if(e.lineIndent0){for(o=s,r=0;o>0;o--)(s=dn(a=e.input.charCodeAt(++e.position)))>=0?r=(r<<4)+s:$n(e,'expected hexadecimal character');e.result+=mn(r),e.position++}else $n(e,'unknown escape sequence');n=i=e.position}else sn(a)?(kn(e,n,i,!0),jn(e,En(e,!1,t)),n=i=e.position):e.position===e.lineStart&&On(e)?$n(e,'unexpected end of the document within a double quoted scalar'):(e.position++,i=e.position)}$n(e,'unexpected end of the stream within a double quoted scalar')}(e,p)?g=!0:!function(e){var t,n,i;if(42!==(i=e.input.charCodeAt(e.position)))return!1;for(i=e.input.charCodeAt(++e.position),t=e.position;0!==i&&!ln(i)&&!cn(i);)i=e.input.charCodeAt(++e.position);return e.position===t&&$n(e,'name of an alias node must contain at least one character'),n=e.input.slice(t,e.position),Qt.call(e.anchorMap,n)||$n(e,'unidentified alias "'+n+'"'),e.result=e.anchorMap[n],En(e,!0,-1),!0}(e)?function(e,t,n){var i,o,r,s,a,l,c,d,u=e.kind,p=e.result;if(ln(d=e.input.charCodeAt(e.position))||cn(d)||35===d||38===d||42===d||33===d||124===d||62===d||39===d||34===d||37===d||64===d||96===d)return!1;if((63===d||45===d)&&(ln(i=e.input.charCodeAt(e.position+1))||n&&cn(i)))return!1;for(e.kind='scalar',e.result='',o=r=e.position,s=!1;0!==d;){if(58===d){if(ln(i=e.input.charCodeAt(e.position+1))||n&&cn(i))break}else if(35===d){if(ln(e.input.charCodeAt(e.position-1)))break}else{if(e.position===e.lineStart&&On(e)||n&&cn(d))break;if(sn(d)){if(a=e.line,l=e.lineStart,c=e.lineIndent,En(e,!1,-1),e.lineIndent>=t){s=!0,d=e.input.charCodeAt(e.position);continue}e.position=r,e.line=a,e.lineStart=l,e.lineIndent=c;break}}s&&(kn(e,o,r,!1),jn(e,e.line-a),o=r=e.position,s=!1),an(d)||(r=e.position+1),d=e.input.charCodeAt(++e.position)}return kn(e,o,r,!1),!!e.result||(e.kind=u,e.result=p,!1)}(e,p,1===n)&&(g=!0,null===e.tag&&(e.tag='?')):(g=!0,null===e.tag&&null===e.anchor||$n(e,'alias node should not have any properties')),null!==e.anchor&&(e.anchorMap[e.anchor]=e.result)):0===m&&(g=a&&Pn(e,h))),null===e.tag)null!==e.anchor&&(e.anchorMap[e.anchor]=e.result);else if('?'===e.tag){for(null!==e.result&&'scalar'!==e.kind&&$n(e,'unacceptable node kind for !> tag; it should be "scalar", not "'+e.kind+'"'),l=0,c=e.implicitTypes.length;l'),null!==e.result&&u.kind!==e.kind&&$n(e,'unacceptable node kind for !<'+e.tag+'> tag; it should be "'+u.kind+'", not "'+e.kind+'"'),u.resolve(e.result,e.tag)?(e.result=u.construct(e.result,e.tag),null!==e.anchor&&(e.anchorMap[e.anchor]=e.result)):$n(e,'cannot resolve a node with !<'+e.tag+'> explicit tag')}return null!==e.listener&&e.listener('close',e),null!==e.tag||null!==e.anchor||g}function Mn(e){var t,n,i,o,r=e.position,s=!1;for(e.version=null,e.checkLineBreaks=e.legacy,e.tagMap=Object.create(null),e.anchorMap=Object.create(null);0!==(o=e.input.charCodeAt(e.position))&&(En(e,!0,-1),o=e.input.charCodeAt(e.position),!(e.lineIndent>0||37!==o));){for(s=!0,o=e.input.charCodeAt(++e.position),t=e.position;0!==o&&!ln(o);)o=e.input.charCodeAt(++e.position);for(i=[],(n=e.input.slice(t,e.position)).length<1&&$n(e,'directive name must not be less than one character in length');0!==o;){for(;an(o);)o=e.input.charCodeAt(++e.position);if(35===o){do{o=e.input.charCodeAt(++e.position)}while(0!==o&&!sn(o));break}if(sn(o))break;for(t=e.position;0!==o&&!ln(o);)o=e.input.charCodeAt(++e.position);i.push(e.input.slice(t,e.position))}0!==o&&An(e),Qt.call(xn,n)?xn[n](e,n,i):wn(e,'unknown document directive "'+n+'"')}En(e,!0,-1),0===e.lineIndent&&45===e.input.charCodeAt(e.position)&&45===e.input.charCodeAt(e.position+1)&&45===e.input.charCodeAt(e.position+2)?(e.position+=3,En(e,!0,-1)):s&&$n(e,'directives end mark is expected'),In(e,e.lineIndent-1,4,!1,!0),En(e,!0,-1),e.checkLineBreaks&&en.test(e.input.slice(r,e.position))&&wn(e,'non-ASCII line breaks are interpreted as content'),e.documents.push(e.result),e.position===e.lineStart&&On(e)?46===e.input.charCodeAt(e.position)&&(e.position+=3,En(e,!0,-1)):e.position=55296&&i<=56319&&t+1=56320&&n<=57343?1024*(i-55296)+n-56320+65536:i}function Xn(e){return/^\n* /.test(e)}function ei(e,t,n,i,o,r,s,a){var l,c=0,d=null,u=!1,p=!1,h=-1!==i,m=-1,f=function(e){return Jn(e)&&e!==Vn&&!Hn(e)&&45!==e&&63!==e&&58!==e&&44!==e&&91!==e&&93!==e&&123!==e&&125!==e&&35!==e&&38!==e&&42!==e&&33!==e&&124!==e&&61!==e&&62!==e&&39!==e&&34!==e&&37!==e&&64!==e&&96!==e}(Qn(e,0))&&function(e){return!Hn(e)&&58!==e}(Qn(e,e.length-1));if(t||s)for(l=0;l=65536?l+=2:l++){if(!Jn(c=Qn(e,l)))return 5;f=f&&Zn(c,d,a),d=c}else{for(l=0;l=65536?l+=2:l++){if(10===(c=Qn(e,l)))u=!0,h&&(p=p||l-m-1>i&&' '!==e[m+1],m=l);else if(!Jn(c))return 5;f=f&&Zn(c,d,a),d=c}p=p||h&&l-m-1>i&&' '!==e[m+1]}return u||p?n>9&&Xn(e)?5:s?2===r?5:2:p?4:3:!f||s||o(e)?2===r?5:2:1}function ti(e,t,n,i,o){e.dump=(()=>{if(0===t.length)return 2===e.quotingType?'""':'\'\'';if(!e.noCompatMode&&(-1!==Fn.indexOf(t)||qn.test(t)))return 2===e.quotingType?'"'+t+'"':'\''+t+'\'';var r=e.indent*Math.max(1,n),s=-1===e.lineWidth?-1:Math.max(Math.min(e.lineWidth,40),e.lineWidth-r),a=i||e.flowLevel>-1&&n>=e.flowLevel;switch(ei(t,a,e.indent,s,function(t){return((e,t)=>{var n,i;for(n=0,i=e.implicitTypes.length;n'+ni(t,e.indent)+ii(Yn(function(e,t){var n,i,o=/(\n+)([^\n]*)/g,r=(a=e.indexOf('\n'),a=-1!==a?a:e.length,o.lastIndex=a,oi(e.slice(0,a),t)),s='\n'===e[0]||' '===e[0];var a;for(;i=o.exec(e);){var l=i[1],c=i[2];n=' '===c[0],r+=l+(s||n||''===c?'':'\n')+oi(c,t),s=n}return r}(t,s),r));case 5:return'"'+function(e){for(var t,n='',i=0,o=0;o=65536?o+=2:o++)i=Qn(e,o),!(t=zn[i])&&Jn(i)?(n+=e[o],i>=65536&&(n+=e[o+1])):n+=t||Wn(i);return n}(t)+'"';default:throw new ht('impossible error: invalid scalar style')}})()}function ni(e,t){var n=Xn(e)?String(t):'',i='\n'===e[e.length-1];return n+(i&&('\n'===e[e.length-2]||'\n'===e)?'+':i?'':'-')+'\n'}function ii(e){return'\n'===e[e.length-1]?e.slice(0,-1):e}function oi(e,t){if(''===e||' '===e[0])return e;for(var n,i,o=/ [^ ]/g,r=0,s=0,a=0,l='';n=o.exec(e);)(a=n.index)-r>t&&(i=s>r?s:a,l+='\n'+e.slice(r,i),r=i+1),s=a;return l+='\n',e.length-r>t&&s>r?l+=e.slice(r,s)+'\n'+e.slice(s+1):l+=e.slice(r),l.slice(1)}function ri(e,t,n,i){var o,r,s,a='',l=e.tag;for(o=0,r=n.length;o tag resolver accepts not "'+l+'" style');i=a.represent[l](t,l)}e.dump=i}return!0}return!1}function ai(e,t,n,i,o,r,s){e.tag=null,e.dump=n,si(e,n,!1)||si(e,n,!0);var a,l=Un.call(e.dump),c=i;i&&(i=e.flowLevel<0||e.flowLevel>t);var d,u,p='[object Object]'===l||'[object Array]'===l;if(p&&(u=-1!==(d=e.duplicates.indexOf(n))),(null!==e.tag&&'?'!==e.tag||u||2!==e.indent&&t>0)&&(o=!1),u&&e.usedDuplicates[d])e.dump='*ref_'+d;else{if(p&&u&&!e.usedDuplicates[d]&&(e.usedDuplicates[d]=!0),'[object Object]'===l)i&&0!==Object.keys(e.dump).length?(!function(e,t,n,i){var o,r,s,a,l,c,d='',u=e.tag,p=Object.keys(n);if(!0===e.sortKeys)p.sort();else if('function'==typeof e.sortKeys)p.sort(e.sortKeys);else if(e.sortKeys)throw new ht('sortKeys must be a boolean or a function');for(o=0,r=p.length;o1024)&&(e.dump&&10===e.dump.charCodeAt(0)?c+='?':c+='? '),c+=e.dump,l&&(c+=Bn(e,t)),ai(e,t+1,a,!0,l)&&(e.dump&&10===e.dump.charCodeAt(0)?c+=':':c+=': ',d+=c+=e.dump));e.tag=u,e.dump=d||'{}'}(e,t,e.dump,o),u&&(e.dump='&ref_'+d+e.dump)):(!function(e,t,n){var i,o,r,s,a,l='',c=e.tag,d=Object.keys(n);for(i=0,o=d.length;i1024&&(a+='? '),a+=e.dump+(e.condenseFlow?'"':'')+':'+(e.condenseFlow?'':' '),ai(e,t,s,!1,!1)&&(l+=a+=e.dump));e.tag=c,e.dump='{'+l+'}'}(e,t,e.dump),u&&(e.dump='&ref_'+d+' '+e.dump));else if('[object Array]'===l)i&&0!==e.dump.length?(e.noArrayIndent&&!s&&t>0?ri(e,t-1,e.dump,o):ri(e,t,e.dump,o),u&&(e.dump='&ref_'+d+e.dump)):(!function(e,t,n){var i,o,r,s='',a=e.tag;for(i=0,o=n.length;i',e.dump=a+' '+e.dump)}return!0}function li(e,t){var n,i,o=[],r=[];for(ci(e,o,r),n=0,i=r.length;n{throw new Error('Function yaml.'+e+' is removed in js-yaml 4. Use yaml.'+t+' instead, which is now safe by default.')}}var ui={Type:yt,Schema:wt,FAILSAFE_SCHEMA:Ct,JSON_SCHEMA:Dt,CORE_SCHEMA:Lt,DEFAULT_SCHEMA:Zt,load:Ln.load,loadAll:Ln.loadAll,dump:{dump:function(e,t){var n=new Kn(t=t||{});n.noRefs||li(e,n);var i=e;return n.replacer&&(i=n.replacer.call({'':i},'',i)),ai(n,0,i,!0,!0)?n.dump+'\n':''}}.dump,YAMLException:ht,types:{binary:qt,float:Mt,map:St,null:At,pairs:Ht,set:Gt,timestamp:Vt,bool:Et,int:Tt,merge:zt,omap:Yt,seq:kt,str:xt},safeLoad:di('safeLoad','load'),safeLoadAll:di('safeLoadAll','loadAll'),safeDump:di('safeDump','dump')};function pi(e){const[t,n]=_e(0),i=Array.from({length:e},()=>new rt);return ge(()=>{i[t]?.value?.focus()},[t,e]),{refs:i,focusedIdx:t,setFocusedIdx:n,handleKeyDown:function(t,i){let o=i;if(['ArrowRight','ArrowDown'].includes(t.key))o=Math.min(e-1,i+1);else{if(!['ArrowLeft','ArrowUp'].includes(t.key))return;o=Math.max(0,i-1)}t.preventDefault(),n(o)}}}class hi{diff(e,t,n={}){let i;'function'==typeof n?(i=n,n={}):'callback'in n&&(i=n.callback);const o=this.castInput(e,n),r=this.castInput(t,n),s=this.removeEmpty(this.tokenize(o,n)),a=this.removeEmpty(this.tokenize(r,n));return this.diffWithOptionsObj(s,a,n,i)}diffWithOptionsObj(e,t,n,i){var o;const r=e=>(e=this.postProcess(e,n),i?void setTimeout(()=>{i(e)},0):e),s=t.length,a=e.length;let l=1,c=s+a;null!=n.maxEditLength&&(c=Math.min(c,n.maxEditLength));const d=null!==(o=n.timeout)&&void 0!==o?o:1/0,u=Date.now()+d,p=[{oldPos:-1,lastComponent:void 0}];let h=this.extractCommon(p[0],t,e,0,n);if(p[0].oldPos+1>=a&&h+1>=s)return r(this.buildValues(p[0].lastComponent,t,e));let m=-1/0,f=1/0;const g=()=>{for(let i=Math.max(m,-l);i<=Math.min(f,l);i+=2){let o;const l=p[i-1],c=p[i+1];l&&(p[i-1]=void 0);let d=!1;if(c){const e=c.oldPos-i;d=c&&0<=e&&e=a&&h+1>=s)return r(this.buildValues(o.lastComponent,t,e))||!0;p[i]=o,o.oldPos+1>=a&&(f=Math.min(f,i-1)),h+1>=s&&(m=Math.max(m,i+1))}else p[i]=void 0}l++};if(i)!function e(){setTimeout(()=>{if(l>c||Date.now()>u)return i(void 0);g()||e()},0)}();else for(;l<=c&&Date.now()<=u;){const e=g();if(e)return e}}addToPath(e,t,n,i,o){const r=e.lastComponent;return r&&!o.oneChangePerToken&&r.added===t&&r.removed===n?{oldPos:e.oldPos+i,lastComponent:{count:r.count+1,added:t,removed:n,previousComponent:r.previousComponent}}:{oldPos:e.oldPos+i,lastComponent:{count:1,added:t,removed:n,previousComponent:r}}}extractCommon(e,t,n,i,o){const r=t.length,s=n.length;let a=e.oldPos,l=a-i,c=0;for(;l+1{const i=n[l+t];return i.length>e.length?i:e}),e.value=this.join(i)}else e.value=this.join(t.slice(a,a+e.count));a+=e.count,e.added||(l+=e.count)}}return i}}const mi=new class extends hi{constructor(){super(...arguments),this.tokenize=fi}equals(e,t,n){return n.ignoreWhitespace?(n.newlineIsToken&&e.includes('\n')||(e=e.trim()),n.newlineIsToken&&t.includes('\n')||(t=t.trim())):n.ignoreNewlineAtEof&&!n.newlineIsToken&&(e.endsWith('\n')&&(e=e.slice(0,-1)),t.endsWith('\n')&&(t=t.slice(0,-1))),super.equals(e,t,n)}};function fi(e,t){t.stripTrailingCr&&(e=e.replace(/\r\n/g,'\n'));const n=[],i=e.split(/(\n|\r\n)/);i[i.length-1]||i.pop();for(let e=0;e{const t=e.value.split('\n');''===t[t.length-1]&&t.pop(),t.forEach(t=>{let n='',i='',o='',r='',c='diff-cell',d='diff-cell';e.removed?(n=a++,o=t,c+=' removed'):e.added?(i=l++,r=t,d+=' added'):(n=a++,i=l++,o=r=t),s.push(O`
+ `},{observedAttributes:['person'],useShadowDOM:!1}));var dt={isNothing:ct,isObject:function(e){return'object'==typeof e&&null!==e},toArray:function(e){return Array.isArray(e)?e:ct(e)?[]:[e]},repeat:function(e,t){var n,i='';for(n=0;na&&(t=i-a+(r=' ... ').length),n-i>a&&(n=i+a-(s=' ...').length),{str:r+e.slice(t,n).replace(/\t/g,'→')+s,pos:i-t+r.length}}function ft(e,t){return dt.repeat(' ',t-e.length)+e}var gt=function(e,t){if(t=Object.create(t||null),!e.buffer)return null;t.maxLength||(t.maxLength=79),'number'!=typeof t.indent&&(t.indent=1),'number'!=typeof t.linesBefore&&(t.linesBefore=3),'number'!=typeof t.linesAfter&&(t.linesAfter=2);for(var n,i=/\r?\n|\r|\0/g,o=[0],r=[],s=-1;n=i.exec(e.buffer);)r.push(n.index),o.push(n.index+n[0].length),e.position<=n.index&&s<0&&(s=o.length-2);s<0&&(s=o.length-1);var a,l,c='',d=Math.min(e.line+t.linesAfter,r.length).toString().length,u=t.maxLength-(t.indent+d+3);for(a=1;a<=t.linesBefore&&!(s-a<0);a++)l=mt(e.buffer,o[s-a],r[s-a],e.position-(o[s]-o[s-a]),u),c=dt.repeat(' ',t.indent)+ft((e.line-a+1).toString(),d)+' | '+l.str+'\n'+c;for(l=mt(e.buffer,o[s],r[s],e.position,u),c+=dt.repeat(' ',t.indent)+ft((e.line+1).toString(),d)+' | '+l.str+'\n',c+=dt.repeat('-',t.indent+d+3+l.pos)+'^\n',a=1;a<=t.linesAfter&&!(s+a>=r.length);a++)l=mt(e.buffer,o[s+a],r[s+a],e.position-(o[s]-o[s+a]),u),c+=dt.repeat(' ',t.indent)+ft((e.line+a+1).toString(),d)+' | '+l.str+'\n';return c.replace(/\n$/,'')},bt=['kind','multi','resolve','construct','instanceOf','predicate','represent','representName','defaultStyle','styleAliases'],vt=['scalar','sequence','mapping'];var yt=function(e,t){if(t=t||{},Object.keys(t).forEach(t=>{if(-1===bt.indexOf(t))throw new ht('Unknown option "'+t+'" is met in definition of "'+e+'" YAML type.')}),this.options=t,this.tag=e,this.kind=t.kind||null,this.resolve=t.resolve||(()=>!0),this.construct=t.construct||(e=>e),this.instanceOf=t.instanceOf||null,this.predicate=t.predicate||null,this.represent=t.represent||null,this.representName=t.representName||null,this.defaultStyle=t.defaultStyle||null,this.multi=t.multi||!1,this.styleAliases=function(e){var t={};return null!==e&&Object.keys(e).forEach(n=>{e[n].forEach(e=>{t[String(e)]=n})}),t}(t.styleAliases||null),-1===vt.indexOf(this.kind))throw new ht('Unknown kind "'+this.kind+'" is specified for "'+e+'" YAML type.')};function _t(e,t){var n=[];return e[t].forEach(e=>{var t=n.length;n.forEach((n,i)=>{n.tag===e.tag&&n.kind===e.kind&&n.multi===e.multi&&(t=i)}),n[t]=e}),n}function $t(e){return this.extend(e)}$t.prototype.extend=function(e){var t=[],n=[];if(e instanceof yt)n.push(e);else if(Array.isArray(e))n=n.concat(e);else{if(!e||!Array.isArray(e.implicit)&&!Array.isArray(e.explicit))throw new ht('Schema.extend argument should be a Type, [ Type ], or a schema definition ({ implicit: [...], explicit: [...] })');e.implicit&&(t=t.concat(e.implicit)),e.explicit&&(n=n.concat(e.explicit))}t.forEach(e=>{if(!(e instanceof yt))throw new ht('Specified list of YAML types (or a single Type object) contains a non-Type object.');if(e.loadKind&&'scalar'!==e.loadKind)throw new ht('There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.');if(e.multi)throw new ht('There is a multi type in the implicit list of a schema. Multi tags can only be listed as explicit.')}),n.forEach(e=>{if(!(e instanceof yt))throw new ht('Specified list of YAML types (or a single Type object) contains a non-Type object.')});var i=Object.create($t.prototype);return i.implicit=(this.implicit||[]).concat(t),i.explicit=(this.explicit||[]).concat(n),i.compiledImplicit=_t(i,'implicit'),i.compiledExplicit=_t(i,'explicit'),i.compiledTypeMap=function(){var e,t,n={scalar:{},sequence:{},mapping:{},fallback:{},multi:{scalar:[],sequence:[],mapping:[],fallback:[]}};function i(e){e.multi?(n.multi[e.kind].push(e),n.multi.fallback.push(e)):n[e.kind][e.tag]=n.fallback[e.tag]=e}for(e=0,t=arguments.length;enull!==e?e:''}),kt=new yt('tag:yaml.org,2002:seq',{kind:'sequence',construct:e=>null!==e?e:[]}),St=new yt('tag:yaml.org,2002:map',{kind:'mapping',construct:e=>null!==e?e:{}}),Ct=new wt({explicit:[xt,kt,St]});var At=new yt('tag:yaml.org,2002:null',{kind:'scalar',resolve:function(e){if(null===e)return!0;var t=e.length;return 1===t&&'~'===e||4===t&&('null'===e||'Null'===e||'NULL'===e)},construct:function(){return null},predicate:function(e){return null===e},represent:{canonical:()=>'~',lowercase:()=>'null',uppercase:()=>'NULL',camelcase:()=>'Null',empty:()=>''},defaultStyle:'lowercase'});var Et=new yt('tag:yaml.org,2002:bool',{kind:'scalar',resolve:function(e){if(null===e)return!1;var t=e.length;return 4===t&&('true'===e||'True'===e||'TRUE'===e)||5===t&&('false'===e||'False'===e||'FALSE'===e)},construct:function(e){return'true'===e||'True'===e||'TRUE'===e},predicate:function(e){return'[object Boolean]'===Object.prototype.toString.call(e)},represent:{lowercase:e=>e?'true':'false',uppercase:e=>e?'TRUE':'FALSE',camelcase:e=>e?'True':'False'},defaultStyle:'lowercase'});function Ot(e){return 48<=e&&e<=57||65<=e&&e<=70||97<=e&&e<=102}function jt(e){return 48<=e&&e<=55}function Pt(e){return 48<=e&&e<=57}var Nt=new yt('tag:yaml.org,2002:int',{kind:'scalar',resolve:function(e){if(null===e)return!1;var t,n=e.length,i=0,o=!1;if(!n)return!1;if('-'!==(t=e[i])&&'+'!==t||(t=e[++i]),'0'===t){if(i+1===n)return!0;if('b'===(t=e[++i])){for(i++;ie>=0?'0b'+e.toString(2):'-0b'+e.toString(2).slice(1),octal:e=>e>=0?'0o'+e.toString(8):'-0o'+e.toString(8).slice(1),decimal:e=>e.toString(10),hexadecimal:e=>e>=0?'0x'+e.toString(16).toUpperCase():'-0x'+e.toString(16).toUpperCase().slice(1)},defaultStyle:'decimal',styleAliases:{binary:[2,'bin'],octal:[8,'oct'],decimal:[10,'dec'],hexadecimal:[16,'hex']}}),Tt=new RegExp('^(?:[-+]?(?:[0-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$');var It=/^[-+]?[0-9]+e/;var Mt=new yt('tag:yaml.org,2002:float',{kind:'scalar',resolve:function(e){return null!==e&&!(!Tt.test(e)||'_'===e[e.length-1])},construct:function(e){var t,n;return n='-'===(t=e.replace(/_/g,'').toLowerCase())[0]?-1:1,'+-'.indexOf(t[0])>=0&&(t=t.slice(1)),'.inf'===t?1===n?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY:'.nan'===t?NaN:n*parseFloat(t,10)},predicate:function(e){return'[object Number]'===Object.prototype.toString.call(e)&&(e%1!=0||dt.isNegativeZero(e))},represent:function(e,t){var n;if(isNaN(e))switch(t){case'lowercase':return'.nan';case'uppercase':return'.NAN';case'camelcase':return'.NaN'}else if(Number.POSITIVE_INFINITY===e)switch(t){case'lowercase':return'.inf';case'uppercase':return'.INF';case'camelcase':return'.Inf'}else if(Number.NEGATIVE_INFINITY===e)switch(t){case'lowercase':return'-.inf';case'uppercase':return'-.INF';case'camelcase':return'-.Inf'}else if(dt.isNegativeZero(e))return'-0.0';return n=e.toString(10),It.test(n)?n.replace('e','.e'):n},defaultStyle:'lowercase'}),Dt=Ct.extend({implicit:[At,Et,Nt,Mt]}),Lt=Dt,Ut=new RegExp('^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$'),Rt=new RegExp('^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$');var Vt=new yt('tag:yaml.org,2002:timestamp',{kind:'scalar',resolve:function(e){return null!==e&&(null!==Ut.exec(e)||null!==Rt.exec(e))},construct:function(e){var t,n,i,o,r,s,a,l,c=0,d=null;if(null===(t=Ut.exec(e))&&(t=Rt.exec(e)),null===t)throw new Error('Date resolve error');if(n=+t[1],i=+t[2]-1,o=+t[3],!t[4])return new Date(Date.UTC(n,i,o));if(r=+t[4],s=+t[5],a=+t[6],t[7]){for(c=t[7].slice(0,3);c.length<3;)c+='0';c=+c}return t[9]&&(d=6e4*(60*+t[10]+ +(t[11]||0)),'-'===t[9]&&(d=-d)),l=new Date(Date.UTC(n,i,o,r,s,a,c)),d&&l.setTime(l.getTime()-d),l},instanceOf:Date,represent:function(e){return e.toISOString()}});var zt=new yt('tag:yaml.org,2002:merge',{kind:'scalar',resolve:function(e){return'<<'===e||null===e}}),Ft='ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=\n\r';var qt=new yt('tag:yaml.org,2002:binary',{kind:'scalar',resolve:function(e){if(null===e)return!1;var t,n,i=0,o=e.length,r=Ft;for(n=0;n64)){if(t<0)return!1;i+=6}return i%8==0},construct:function(e){var t,n,i=e.replace(/[\r\n=]/g,''),o=i.length,r=Ft,s=0,a=[];for(t=0;t>16&255),a.push(s>>8&255),a.push(255&s)),s=s<<6|r.indexOf(i.charAt(t));return 0===(n=o%4*6)?(a.push(s>>16&255),a.push(s>>8&255),a.push(255&s)):18===n?(a.push(s>>10&255),a.push(s>>2&255)):12===n&&a.push(s>>4&255),new Uint8Array(a)},predicate:function(e){return'[object Uint8Array]'===Object.prototype.toString.call(e)},represent:function(e){var t,n,i='',o=0,r=e.length,s=Ft;for(t=0;t>18&63],i+=s[o>>12&63],i+=s[o>>6&63],i+=s[63&o]),o=(o<<8)+e[t];return 0===(n=r%3)?(i+=s[o>>18&63],i+=s[o>>12&63],i+=s[o>>6&63],i+=s[63&o]):2===n?(i+=s[o>>10&63],i+=s[o>>4&63],i+=s[o<<2&63],i+=s[64]):1===n&&(i+=s[o>>2&63],i+=s[o<<4&63],i+=s[64],i+=s[64]),i}}),Wt=Object.prototype.hasOwnProperty,Kt=Object.prototype.toString;var Yt=new yt('tag:yaml.org,2002:omap',{kind:'sequence',resolve:function(e){if(null===e)return!0;var t,n,i,o,r,s=[],a=e;for(t=0,n=a.length;t>10),56320+(e-65536&1023))}function fn(e,t,n){'__proto__'===t?Object.defineProperty(e,t,{configurable:!0,enumerable:!0,writable:!0,value:n}):e[t]=n}for(var gn=new Array(256),bn=new Array(256),vn=0;vn<256;vn++)gn[vn]=hn(vn)?1:0,bn[vn]=hn(vn);function yn(e,t){this.input=e,this.filename=t.filename||null,this.schema=t.schema||Zt,this.onWarning=t.onWarning||null,this.legacy=t.legacy||!1,this.json=t.json||!1,this.listener=t.listener||null,this.implicitTypes=this.schema.compiledImplicit,this.typeMap=this.schema.compiledTypeMap,this.length=e.length,this.position=0,this.line=0,this.lineStart=0,this.lineIndent=0,this.firstTabInLine=-1,this.documents=[]}function _n(e,t){var n={name:e.filename,buffer:e.input.slice(0,-1),position:e.position,line:e.line,column:e.position-e.lineStart};return n.snippet=gt(n),new ht(t,n)}function $n(e,t){throw _n(e,t)}function wn(e,t){e.onWarning&&e.onWarning.call(null,_n(e,t))}var xn={YAML:function(e,t,n){var i,o,r;null!==e.version&&$n(e,'duplication of %YAML directive'),1!==n.length&&$n(e,'YAML directive accepts exactly one argument'),null===(i=/^([0-9]+)\.([0-9]+)$/.exec(n[0]))&&$n(e,'ill-formed argument of the YAML directive'),o=parseInt(i[1],10),r=parseInt(i[2],10),1!==o&&$n(e,'unacceptable YAML version of the document'),e.version=n[0],e.checkLineBreaks=r<2,1!==r&&2!==r&&wn(e,'unsupported YAML version of the document')},TAG:function(e,t,n){var i,o;2!==n.length&&$n(e,'TAG directive accepts exactly two arguments'),i=n[0],o=n[1],nn.test(i)||$n(e,'ill-formed tag handle (first argument) of the TAG directive'),Qt.call(e.tagMap,i)&&$n(e,'there is a previously declared suffix for "'+i+'" tag handle'),on.test(o)||$n(e,'ill-formed tag prefix (second argument) of the TAG directive');try{o=decodeURIComponent(o)}catch(t){$n(e,'tag prefix is malformed: '+o)}e.tagMap[i]=o}};function kn(e,t,n,i){var o,r,s,a;if(t1&&(e.result+=dt.repeat('\n',t-1))}function Pn(e,t){var n,i,o=e.tag,r=e.anchor,s=[],a=!1;if(-1!==e.firstTabInLine)return!1;for(null!==e.anchor&&(e.anchorMap[e.anchor]=s),i=e.input.charCodeAt(e.position);0!==i&&(-1!==e.firstTabInLine&&(e.position=e.firstTabInLine,$n(e,'tab characters must not be used in indentation')),45===i)&&ln(e.input.charCodeAt(e.position+1));)if(a=!0,e.position++,En(e,!0,-1)&&e.lineIndent<=t)s.push(null),i=e.input.charCodeAt(e.position);else if(n=e.line,In(e,t,3,!1,!0),s.push(e.result),En(e,!0,-1),i=e.input.charCodeAt(e.position),(e.line===n||e.lineIndent>t)&&0!==i)$n(e,'bad indentation of a sequence entry');else if(e.lineIndentt?m=1:e.lineIndent===t?m=0:e.lineIndentt?m=1:e.lineIndent===t?m=0:e.lineIndentt)&&(b&&(s=e.line,a=e.lineStart,l=e.position),In(e,t,4,!0,o)&&(b?f=e.result:g=e.result),b||(Cn(e,p,h,m,f,g,s,a,l),m=f=g=null),En(e,!0,-1),c=e.input.charCodeAt(e.position)),(e.line===r||e.lineIndent>t)&&0!==c)$n(e,'bad indentation of a mapping entry');else if(e.lineIndent=0))break;0===o?$n(e,'bad explicit indentation width of a block scalar; it cannot be less than one'):l?$n(e,'repeat of an indentation width identifier'):(c=t+o-1,l=!0)}if(an(r)){do{r=e.input.charCodeAt(++e.position)}while(an(r));if(35===r)do{r=e.input.charCodeAt(++e.position)}while(!sn(r)&&0!==r)}for(;0!==r;){for(An(e),e.lineIndent=0,r=e.input.charCodeAt(e.position);(!l||e.lineIndentc&&(c=e.lineIndent),sn(r))d++;else{if(e.lineIndent0){for(o=s,r=0;o>0;o--)(s=dn(a=e.input.charCodeAt(++e.position)))>=0?r=(r<<4)+s:$n(e,'expected hexadecimal character');e.result+=mn(r),e.position++}else $n(e,'unknown escape sequence');n=i=e.position}else sn(a)?(kn(e,n,i,!0),jn(e,En(e,!1,t)),n=i=e.position):e.position===e.lineStart&&On(e)?$n(e,'unexpected end of the document within a double quoted scalar'):(e.position++,i=e.position)}$n(e,'unexpected end of the stream within a double quoted scalar')}(e,p)?g=!0:!function(e){var t,n,i;if(42!==(i=e.input.charCodeAt(e.position)))return!1;for(i=e.input.charCodeAt(++e.position),t=e.position;0!==i&&!ln(i)&&!cn(i);)i=e.input.charCodeAt(++e.position);return e.position===t&&$n(e,'name of an alias node must contain at least one character'),n=e.input.slice(t,e.position),Qt.call(e.anchorMap,n)||$n(e,'unidentified alias "'+n+'"'),e.result=e.anchorMap[n],En(e,!0,-1),!0}(e)?function(e,t,n){var i,o,r,s,a,l,c,d,u=e.kind,p=e.result;if(ln(d=e.input.charCodeAt(e.position))||cn(d)||35===d||38===d||42===d||33===d||124===d||62===d||39===d||34===d||37===d||64===d||96===d)return!1;if((63===d||45===d)&&(ln(i=e.input.charCodeAt(e.position+1))||n&&cn(i)))return!1;for(e.kind='scalar',e.result='',o=r=e.position,s=!1;0!==d;){if(58===d){if(ln(i=e.input.charCodeAt(e.position+1))||n&&cn(i))break}else if(35===d){if(ln(e.input.charCodeAt(e.position-1)))break}else{if(e.position===e.lineStart&&On(e)||n&&cn(d))break;if(sn(d)){if(a=e.line,l=e.lineStart,c=e.lineIndent,En(e,!1,-1),e.lineIndent>=t){s=!0,d=e.input.charCodeAt(e.position);continue}e.position=r,e.line=a,e.lineStart=l,e.lineIndent=c;break}}s&&(kn(e,o,r,!1),jn(e,e.line-a),o=r=e.position,s=!1),an(d)||(r=e.position+1),d=e.input.charCodeAt(++e.position)}return kn(e,o,r,!1),!!e.result||(e.kind=u,e.result=p,!1)}(e,p,1===n)&&(g=!0,null===e.tag&&(e.tag='?')):(g=!0,null===e.tag&&null===e.anchor||$n(e,'alias node should not have any properties')),null!==e.anchor&&(e.anchorMap[e.anchor]=e.result)):0===m&&(g=a&&Pn(e,h))),null===e.tag)null!==e.anchor&&(e.anchorMap[e.anchor]=e.result);else if('?'===e.tag){for(null!==e.result&&'scalar'!==e.kind&&$n(e,'unacceptable node kind for !> tag; it should be "scalar", not "'+e.kind+'"'),l=0,c=e.implicitTypes.length;l'),null!==e.result&&u.kind!==e.kind&&$n(e,'unacceptable node kind for !<'+e.tag+'> tag; it should be "'+u.kind+'", not "'+e.kind+'"'),u.resolve(e.result,e.tag)?(e.result=u.construct(e.result,e.tag),null!==e.anchor&&(e.anchorMap[e.anchor]=e.result)):$n(e,'cannot resolve a node with !<'+e.tag+'> explicit tag')}return null!==e.listener&&e.listener('close',e),null!==e.tag||null!==e.anchor||g}function Mn(e){var t,n,i,o,r=e.position,s=!1;for(e.version=null,e.checkLineBreaks=e.legacy,e.tagMap=Object.create(null),e.anchorMap=Object.create(null);0!==(o=e.input.charCodeAt(e.position))&&(En(e,!0,-1),o=e.input.charCodeAt(e.position),!(e.lineIndent>0||37!==o));){for(s=!0,o=e.input.charCodeAt(++e.position),t=e.position;0!==o&&!ln(o);)o=e.input.charCodeAt(++e.position);for(i=[],(n=e.input.slice(t,e.position)).length<1&&$n(e,'directive name must not be less than one character in length');0!==o;){for(;an(o);)o=e.input.charCodeAt(++e.position);if(35===o){do{o=e.input.charCodeAt(++e.position)}while(0!==o&&!sn(o));break}if(sn(o))break;for(t=e.position;0!==o&&!ln(o);)o=e.input.charCodeAt(++e.position);i.push(e.input.slice(t,e.position))}0!==o&&An(e),Qt.call(xn,n)?xn[n](e,n,i):wn(e,'unknown document directive "'+n+'"')}En(e,!0,-1),0===e.lineIndent&&45===e.input.charCodeAt(e.position)&&45===e.input.charCodeAt(e.position+1)&&45===e.input.charCodeAt(e.position+2)?(e.position+=3,En(e,!0,-1)):s&&$n(e,'directives end mark is expected'),In(e,e.lineIndent-1,4,!1,!0),En(e,!0,-1),e.checkLineBreaks&&en.test(e.input.slice(r,e.position))&&wn(e,'non-ASCII line breaks are interpreted as content'),e.documents.push(e.result),e.position===e.lineStart&&On(e)?46===e.input.charCodeAt(e.position)&&(e.position+=3,En(e,!0,-1)):e.position=55296&&i<=56319&&t+1=56320&&n<=57343?1024*(i-55296)+n-56320+65536:i}function Xn(e){return/^\n* /.test(e)}function ei(e,t,n,i,o,r,s,a){var l,c=0,d=null,u=!1,p=!1,h=-1!==i,m=-1,f=function(e){return Jn(e)&&e!==Vn&&!Hn(e)&&45!==e&&63!==e&&58!==e&&44!==e&&91!==e&&93!==e&&123!==e&&125!==e&&35!==e&&38!==e&&42!==e&&33!==e&&124!==e&&61!==e&&62!==e&&39!==e&&34!==e&&37!==e&&64!==e&&96!==e}(Qn(e,0))&&function(e){return!Hn(e)&&58!==e}(Qn(e,e.length-1));if(t||s)for(l=0;l=65536?l+=2:l++){if(!Jn(c=Qn(e,l)))return 5;f=f&&Zn(c,d,a),d=c}else{for(l=0;l=65536?l+=2:l++){if(10===(c=Qn(e,l)))u=!0,h&&(p=p||l-m-1>i&&' '!==e[m+1],m=l);else if(!Jn(c))return 5;f=f&&Zn(c,d,a),d=c}p=p||h&&l-m-1>i&&' '!==e[m+1]}return u||p?n>9&&Xn(e)?5:s?2===r?5:2:p?4:3:!f||s||o(e)?2===r?5:2:1}function ti(e,t,n,i,o){e.dump=(()=>{if(0===t.length)return 2===e.quotingType?'""':'\'\'';if(!e.noCompatMode&&(-1!==Fn.indexOf(t)||qn.test(t)))return 2===e.quotingType?'"'+t+'"':'\''+t+'\'';var r=e.indent*Math.max(1,n),s=-1===e.lineWidth?-1:Math.max(Math.min(e.lineWidth,40),e.lineWidth-r),a=i||e.flowLevel>-1&&n>=e.flowLevel;switch(ei(t,a,e.indent,s,function(t){return((e,t)=>{var n,i;for(n=0,i=e.implicitTypes.length;n'+ni(t,e.indent)+ii(Yn(function(e,t){var n,i,o=/(\n+)([^\n]*)/g,r=(a=e.indexOf('\n'),a=-1!==a?a:e.length,o.lastIndex=a,oi(e.slice(0,a),t)),s='\n'===e[0]||' '===e[0];var a;for(;i=o.exec(e);){var l=i[1],c=i[2];n=' '===c[0],r+=l+(s||n||''===c?'':'\n')+oi(c,t),s=n}return r}(t,s),r));case 5:return'"'+function(e){for(var t,n='',i=0,o=0;o=65536?o+=2:o++)i=Qn(e,o),!(t=zn[i])&&Jn(i)?(n+=e[o],i>=65536&&(n+=e[o+1])):n+=t||Wn(i);return n}(t)+'"';default:throw new ht('impossible error: invalid scalar style')}})()}function ni(e,t){var n=Xn(e)?String(t):'',i='\n'===e[e.length-1];return n+(i&&('\n'===e[e.length-2]||'\n'===e)?'+':i?'':'-')+'\n'}function ii(e){return'\n'===e[e.length-1]?e.slice(0,-1):e}function oi(e,t){if(''===e||' '===e[0])return e;for(var n,i,o=/ [^ ]/g,r=0,s=0,a=0,l='';n=o.exec(e);)(a=n.index)-r>t&&(i=s>r?s:a,l+='\n'+e.slice(r,i),r=i+1),s=a;return l+='\n',e.length-r>t&&s>r?l+=e.slice(r,s)+'\n'+e.slice(s+1):l+=e.slice(r),l.slice(1)}function ri(e,t,n,i){var o,r,s,a='',l=e.tag;for(o=0,r=n.length;o tag resolver accepts not "'+l+'" style');i=a.represent[l](t,l)}e.dump=i}return!0}return!1}function ai(e,t,n,i,o,r,s){e.tag=null,e.dump=n,si(e,n,!1)||si(e,n,!0);var a,l=Un.call(e.dump),c=i;i&&(i=e.flowLevel<0||e.flowLevel>t);var d,u,p='[object Object]'===l||'[object Array]'===l;if(p&&(u=-1!==(d=e.duplicates.indexOf(n))),(null!==e.tag&&'?'!==e.tag||u||2!==e.indent&&t>0)&&(o=!1),u&&e.usedDuplicates[d])e.dump='*ref_'+d;else{if(p&&u&&!e.usedDuplicates[d]&&(e.usedDuplicates[d]=!0),'[object Object]'===l)i&&0!==Object.keys(e.dump).length?(!function(e,t,n,i){var o,r,s,a,l,c,d='',u=e.tag,p=Object.keys(n);if(!0===e.sortKeys)p.sort();else if('function'==typeof e.sortKeys)p.sort(e.sortKeys);else if(e.sortKeys)throw new ht('sortKeys must be a boolean or a function');for(o=0,r=p.length;o1024)&&(e.dump&&10===e.dump.charCodeAt(0)?c+='?':c+='? '),c+=e.dump,l&&(c+=Bn(e,t)),ai(e,t+1,a,!0,l)&&(e.dump&&10===e.dump.charCodeAt(0)?c+=':':c+=': ',d+=c+=e.dump));e.tag=u,e.dump=d||'{}'}(e,t,e.dump,o),u&&(e.dump='&ref_'+d+e.dump)):(!function(e,t,n){var i,o,r,s,a,l='',c=e.tag,d=Object.keys(n);for(i=0,o=d.length;i1024&&(a+='? '),a+=e.dump+(e.condenseFlow?'"':'')+':'+(e.condenseFlow?'':' '),ai(e,t,s,!1,!1)&&(l+=a+=e.dump));e.tag=c,e.dump='{'+l+'}'}(e,t,e.dump),u&&(e.dump='&ref_'+d+' '+e.dump));else if('[object Array]'===l)i&&0!==e.dump.length?(e.noArrayIndent&&!s&&t>0?ri(e,t-1,e.dump,o):ri(e,t,e.dump,o),u&&(e.dump='&ref_'+d+e.dump)):(!function(e,t,n){var i,o,r,s='',a=e.tag;for(i=0,o=n.length;i',e.dump=a+' '+e.dump)}return!0}function li(e,t){var n,i,o=[],r=[];for(ci(e,o,r),n=0,i=r.length;n{throw new Error('Function yaml.'+e+' is removed in js-yaml 4. Use yaml.'+t+' instead, which is now safe by default.')}}var ui={Type:yt,Schema:wt,FAILSAFE_SCHEMA:Ct,JSON_SCHEMA:Dt,CORE_SCHEMA:Lt,DEFAULT_SCHEMA:Zt,load:Ln.load,loadAll:Ln.loadAll,dump:{dump:function(e,t){var n=new Kn(t=t||{});n.noRefs||li(e,n);var i=e;return n.replacer&&(i=n.replacer.call({'':i},'',i)),ai(n,0,i,!0,!0)?n.dump+'\n':''}}.dump,YAMLException:ht,types:{binary:qt,float:Mt,map:St,null:At,pairs:Ht,set:Gt,timestamp:Vt,bool:Et,int:Nt,merge:zt,omap:Yt,seq:kt,str:xt},safeLoad:di('safeLoad','load'),safeLoadAll:di('safeLoadAll','loadAll'),safeDump:di('safeDump','dump')};function pi(e){const[t,n]=_e(0),i=Array.from({length:e},()=>new rt);return ge(()=>{i[t]?.value?.focus()},[t,e]),{refs:i,focusedIdx:t,setFocusedIdx:n,handleKeyDown:function(t,i){let o=i;if(['ArrowRight','ArrowDown'].includes(t.key))o=Math.min(e-1,i+1);else{if(!['ArrowLeft','ArrowUp'].includes(t.key))return;o=Math.max(0,i-1)}t.preventDefault(),n(o)}}}class hi{diff(e,t,n={}){let i;'function'==typeof n?(i=n,n={}):'callback'in n&&(i=n.callback);const o=this.castInput(e,n),r=this.castInput(t,n),s=this.removeEmpty(this.tokenize(o,n)),a=this.removeEmpty(this.tokenize(r,n));return this.diffWithOptionsObj(s,a,n,i)}diffWithOptionsObj(e,t,n,i){var o;const r=e=>(e=this.postProcess(e,n),i?void setTimeout(()=>{i(e)},0):e),s=t.length,a=e.length;let l=1,c=s+a;null!=n.maxEditLength&&(c=Math.min(c,n.maxEditLength));const d=null!==(o=n.timeout)&&void 0!==o?o:1/0,u=Date.now()+d,p=[{oldPos:-1,lastComponent:void 0}];let h=this.extractCommon(p[0],t,e,0,n);if(p[0].oldPos+1>=a&&h+1>=s)return r(this.buildValues(p[0].lastComponent,t,e));let m=-1/0,f=1/0;const g=()=>{for(let i=Math.max(m,-l);i<=Math.min(f,l);i+=2){let o;const l=p[i-1],c=p[i+1];l&&(p[i-1]=void 0);let d=!1;if(c){const e=c.oldPos-i;d=c&&0<=e&&e=a&&h+1>=s)return r(this.buildValues(o.lastComponent,t,e))||!0;p[i]=o,o.oldPos+1>=a&&(f=Math.min(f,i-1)),h+1>=s&&(m=Math.max(m,i+1))}else p[i]=void 0}l++};if(i)!function e(){setTimeout(()=>{if(l>c||Date.now()>u)return i(void 0);g()||e()},0)}();else for(;l<=c&&Date.now()<=u;){const e=g();if(e)return e}}addToPath(e,t,n,i,o){const r=e.lastComponent;return r&&!o.oneChangePerToken&&r.added===t&&r.removed===n?{oldPos:e.oldPos+i,lastComponent:{count:r.count+1,added:t,removed:n,previousComponent:r.previousComponent}}:{oldPos:e.oldPos+i,lastComponent:{count:1,added:t,removed:n,previousComponent:r}}}extractCommon(e,t,n,i,o){const r=t.length,s=n.length;let a=e.oldPos,l=a-i,c=0;for(;l+1{const i=n[l+t];return i.length>e.length?i:e}),e.value=this.join(i)}else e.value=this.join(t.slice(a,a+e.count));a+=e.count,e.added||(l+=e.count)}}return i}}const mi=new class extends hi{constructor(){super(...arguments),this.tokenize=fi}equals(e,t,n){return n.ignoreWhitespace?(n.newlineIsToken&&e.includes('\n')||(e=e.trim()),n.newlineIsToken&&t.includes('\n')||(t=t.trim())):n.ignoreNewlineAtEof&&!n.newlineIsToken&&(e.endsWith('\n')&&(e=e.slice(0,-1)),t.endsWith('\n')&&(t=t.slice(0,-1))),super.equals(e,t,n)}};function fi(e,t){t.stripTrailingCr&&(e=e.replace(/\r\n/g,'\n'));const n=[],i=e.split(/(\n|\r\n)/);i[i.length-1]||i.pop();for(let e=0;e{const t=e.value.split('\n');''===t[t.length-1]&&t.pop(),t.forEach(t=>{let n='',i='',o='',r='',c='diff-cell',d='diff-cell';e.removed?(n=a++,o=t,c+=' removed'):e.added?(i=l++,r=t,d+=' added'):(n=a++,i=l++,o=r=t),s.push(O`