"use strict";const _=require("./directive-helpers-C-un5pST.js"),c=require("./directive-C7oCP5Bh.js");/**
 * @license
 * Copyright 2017 Google LLC
 * SPDX-License-Identifier: BSD-3-Clause
 */const o=(s,e)=>{var t,i;const n=s._$AN;if(n===void 0)return!1;for(const l of n)(i=(t=l)._$AO)===null||i===void 0||i.call(t,e,!1),o(l,e);return!0},r=s=>{let e,t;do{if((e=s._$AM)===void 0)break;t=e._$AN,t.delete(s),s=e}while((t==null?void 0:t.size)===0)},h=s=>{for(let e;e=s._$AM;s=e){let t=e._$AN;if(t===void 0)e._$AN=t=new Set;else if(t.has(s))break;t.add(s),A(e)}};function $(s){this._$AN!==void 0?(r(this),this._$AM=s,h(this)):this._$AM=s}function d(s,e=!1,t=0){const i=this._$AH,n=this._$AN;if(n!==void 0&&n.size!==0)if(e)if(Array.isArray(i))for(let l=t;l<i.length;l++)o(i[l],!1),r(i[l]);else i!=null&&(o(i,!1),r(i));else o(this,s)}const A=s=>{var e,t,i,n;s.type==c.t.CHILD&&((e=(i=s)._$AP)!==null&&e!==void 0||(i._$AP=d),(t=(n=s)._$AQ)!==null&&t!==void 0||(n._$AQ=$))};class u extends c.i{constructor(){super(...arguments),this._$AN=void 0}_$AT(e,t,i){super._$AT(e,t,i),h(this),this.isConnected=e._$AU}_$AO(e,t=!0){var i,n;e!==this.isConnected&&(this.isConnected=e,e?(i=this.reconnected)===null||i===void 0||i.call(this):(n=this.disconnected)===null||n===void 0||n.call(this)),t&&(o(this,e),r(this))}setValue(e){if(_.e(this._$Ct))this._$Ct._$AI(e,this);else{const t=[...this._$Ct._$AH];t[this._$Ci]=e,this._$Ct._$AI(t,this,0)}}disconnected(){}reconnected(){}}exports.c=u;
