Liu Song’s Projects


~/Projects/chrome-devtools-frontend

git clone https://code.lsong.org/chrome-devtools-frontend

Commit

Commit
e46507be5fbaaaef85266f7d1d70a77c1f7499c0
Author
Randolf <[email protected]>
Date
2022-11-28 10:19:55 +0000 +0000
Diffstat
 front_end/third_party/lit-html/README.chromium | 4 
 front_end/third_party/lit-html/package/async-directive.d.ts | 1 
 front_end/third_party/lit-html/package/async-directive.d.ts.map | 2 
 front_end/third_party/lit-html/package/async-directive.js | 4 
 front_end/third_party/lit-html/package/async-directive.js.map | 2 
 front_end/third_party/lit-html/package/development/async-directive.d.ts | 1 
 front_end/third_party/lit-html/package/development/async-directive.d.ts.map | 2 
 front_end/third_party/lit-html/package/development/async-directive.js | 1 
 front_end/third_party/lit-html/package/development/async-directive.js.map | 2 
 front_end/third_party/lit-html/package/development/directive-helpers.d.ts | 2 
 front_end/third_party/lit-html/package/development/directive-helpers.d.ts.map | 2 
 front_end/third_party/lit-html/package/development/directive-helpers.js | 20 
 front_end/third_party/lit-html/package/development/directive-helpers.js.map | 2 
 front_end/third_party/lit-html/package/development/directive.d.ts | 4 
 front_end/third_party/lit-html/package/development/directive.d.ts.map | 2 
 front_end/third_party/lit-html/package/development/directive.js.map | 2 
 front_end/third_party/lit-html/package/development/directives/async-replace.d.ts | 2 
 front_end/third_party/lit-html/package/development/directives/async-replace.d.ts.map | 2 
 front_end/third_party/lit-html/package/development/directives/async-replace.js | 2 
 front_end/third_party/lit-html/package/development/directives/async-replace.js.map | 2 
 front_end/third_party/lit-html/package/development/directives/keyed.d.ts | 5 
 front_end/third_party/lit-html/package/development/directives/keyed.d.ts.map | 2 
 front_end/third_party/lit-html/package/development/directives/keyed.js.map | 2 
 front_end/third_party/lit-html/package/development/directives/live.d.ts | 2 
 front_end/third_party/lit-html/package/development/directives/live.js | 2 
 front_end/third_party/lit-html/package/development/directives/live.js.map | 2 
 front_end/third_party/lit-html/package/development/directives/private-async-helpers.js.map | 2 
 front_end/third_party/lit-html/package/development/directives/ref.d.ts | 2 
 front_end/third_party/lit-html/package/development/directives/ref.d.ts.map | 2 
 front_end/third_party/lit-html/package/development/directives/ref.js | 25 
 front_end/third_party/lit-html/package/development/directives/ref.js.map | 2 
 front_end/third_party/lit-html/package/development/directives/style-map.d.ts | 20 
 front_end/third_party/lit-html/package/development/directives/style-map.d.ts.map | 2 
 front_end/third_party/lit-html/package/development/directives/style-map.js | 15 
 front_end/third_party/lit-html/package/development/directives/style-map.js.map | 2 
 front_end/third_party/lit-html/package/development/directives/until.d.ts.map | 2 
 front_end/third_party/lit-html/package/development/directives/until.js | 3 
 front_end/third_party/lit-html/package/development/directives/until.js.map | 2 
 front_end/third_party/lit-html/package/development/experimental-hydrate.d.ts.map | 2 
 front_end/third_party/lit-html/package/development/experimental-hydrate.js | 12 
 front_end/third_party/lit-html/package/development/experimental-hydrate.js.map | 2 
 front_end/third_party/lit-html/package/development/is-server.d.ts | 15 
 front_end/third_party/lit-html/package/development/is-server.d.ts.map | 1 
 front_end/third_party/lit-html/package/development/is-server.js | 22 
 front_end/third_party/lit-html/package/development/is-server.js.map | 1 
 front_end/third_party/lit-html/package/development/lit-html.d.ts | 56 
 front_end/third_party/lit-html/package/development/lit-html.d.ts.map | 2 
 front_end/third_party/lit-html/package/development/lit-html.js | 228 
 front_end/third_party/lit-html/package/development/lit-html.js.map | 2 
 front_end/third_party/lit-html/package/development/polyfill-support.js | 6 
 front_end/third_party/lit-html/package/development/polyfill-support.js.map | 2 
 front_end/third_party/lit-html/package/development/private-ssr-support.d.ts | 4 
 front_end/third_party/lit-html/package/development/private-ssr-support.d.ts.map | 2 
 front_end/third_party/lit-html/package/development/static.d.ts | 35 
 front_end/third_party/lit-html/package/development/static.d.ts.map | 2 
 front_end/third_party/lit-html/package/development/static.js | 30 
 front_end/third_party/lit-html/package/development/static.js.map | 2 
 front_end/third_party/lit-html/package/directive-helpers.d.ts | 2 
 front_end/third_party/lit-html/package/directive-helpers.d.ts.map | 2 
 front_end/third_party/lit-html/package/directive-helpers.js | 2 
 front_end/third_party/lit-html/package/directive-helpers.js.map | 2 
 front_end/third_party/lit-html/package/directive.d.ts | 4 
 front_end/third_party/lit-html/package/directive.d.ts.map | 2 
 front_end/third_party/lit-html/package/directive.js.map | 2 
 front_end/third_party/lit-html/package/directives/async-append.js | 2 
 front_end/third_party/lit-html/package/directives/async-append.js.map | 2 
 front_end/third_party/lit-html/package/directives/async-replace.d.ts | 2 
 front_end/third_party/lit-html/package/directives/async-replace.d.ts.map | 2 
 front_end/third_party/lit-html/package/directives/async-replace.js | 4 
 front_end/third_party/lit-html/package/directives/async-replace.js.map | 2 
 front_end/third_party/lit-html/package/directives/cache.js | 2 
 front_end/third_party/lit-html/package/directives/cache.js.map | 2 
 front_end/third_party/lit-html/package/directives/choose.js.map | 2 
 front_end/third_party/lit-html/package/directives/class-map.js | 2 
 front_end/third_party/lit-html/package/directives/class-map.js.map | 2 
 front_end/third_party/lit-html/package/directives/guard.js | 2 
 front_end/third_party/lit-html/package/directives/guard.js.map | 2 
 front_end/third_party/lit-html/package/directives/if-defined.js.map | 2 
 front_end/third_party/lit-html/package/directives/join.js.map | 2 
 front_end/third_party/lit-html/package/directives/keyed.d.ts | 5 
 front_end/third_party/lit-html/package/directives/keyed.d.ts.map | 2 
 front_end/third_party/lit-html/package/directives/keyed.js.map | 2 
 front_end/third_party/lit-html/package/directives/live.d.ts | 2 
 front_end/third_party/lit-html/package/directives/live.js.map | 2 
 front_end/third_party/lit-html/package/directives/map.js.map | 2 
 front_end/third_party/lit-html/package/directives/private-async-helpers.js | 2 
 front_end/third_party/lit-html/package/directives/private-async-helpers.js.map | 2 
 front_end/third_party/lit-html/package/directives/range.js.map | 2 
 front_end/third_party/lit-html/package/directives/ref.d.ts | 2 
 front_end/third_party/lit-html/package/directives/ref.d.ts.map | 2 
 front_end/third_party/lit-html/package/directives/ref.js | 4 
 front_end/third_party/lit-html/package/directives/ref.js.map | 2 
 front_end/third_party/lit-html/package/directives/repeat.js | 2 
 front_end/third_party/lit-html/package/directives/repeat.js.map | 2 
 front_end/third_party/lit-html/package/directives/style-map.d.ts | 20 
 front_end/third_party/lit-html/package/directives/style-map.d.ts.map | 2 
 front_end/third_party/lit-html/package/directives/style-map.js | 2 
 front_end/third_party/lit-html/package/directives/style-map.js.map | 2 
 front_end/third_party/lit-html/package/directives/template-content.js | 2 
 front_end/third_party/lit-html/package/directives/template-content.js.map | 2 
 front_end/third_party/lit-html/package/directives/unsafe-html.js | 2 
 front_end/third_party/lit-html/package/directives/unsafe-html.js.map | 2 
 front_end/third_party/lit-html/package/directives/unsafe-svg.js.map | 2 
 front_end/third_party/lit-html/package/directives/until.d.ts.map | 2 
 front_end/third_party/lit-html/package/directives/until.js | 4 
 front_end/third_party/lit-html/package/directives/until.js.map | 2 
 front_end/third_party/lit-html/package/directives/when.js.map | 2 
 front_end/third_party/lit-html/package/experimental-hydrate.d.ts.map | 2 
 front_end/third_party/lit-html/package/experimental-hydrate.js | 2 
 front_end/third_party/lit-html/package/experimental-hydrate.js.map | 2 
 front_end/third_party/lit-html/package/is-server.d.ts | 15 
 front_end/third_party/lit-html/package/is-server.d.ts.map | 1 
 front_end/third_party/lit-html/package/is-server.js | 7 
 front_end/third_party/lit-html/package/is-server.js.map | 1 
 front_end/third_party/lit-html/package/lit-html.d.ts | 56 
 front_end/third_party/lit-html/package/lit-html.d.ts.map | 2 
 front_end/third_party/lit-html/package/lit-html.js | 2 
 front_end/third_party/lit-html/package/lit-html.js.map | 2 
 front_end/third_party/lit-html/package/node/async-directive.js | 7 
 front_end/third_party/lit-html/package/node/async-directive.js.map | 1 
 front_end/third_party/lit-html/package/node/directive-helpers.js | 7 
 front_end/third_party/lit-html/package/node/directive-helpers.js.map | 1 
 front_end/third_party/lit-html/package/node/directive.js | 7 
 front_end/third_party/lit-html/package/node/directive.js.map | 1 
 front_end/third_party/lit-html/package/node/directives/async-append.js | 7 
 front_end/third_party/lit-html/package/node/directives/async-append.js.map | 1 
 front_end/third_party/lit-html/package/node/directives/async-replace.js | 7 
 front_end/third_party/lit-html/package/node/directives/async-replace.js.map | 1 
 front_end/third_party/lit-html/package/node/directives/cache.js | 7 
 front_end/third_party/lit-html/package/node/directives/cache.js.map | 1 
 front_end/third_party/lit-html/package/node/directives/choose.js | 7 
 front_end/third_party/lit-html/package/node/directives/choose.js.map | 1 
 front_end/third_party/lit-html/package/node/directives/class-map.js | 7 
 front_end/third_party/lit-html/package/node/directives/class-map.js.map | 1 
 front_end/third_party/lit-html/package/node/directives/guard.js | 8 
 front_end/third_party/lit-html/package/node/directives/guard.js.map | 1 
 front_end/third_party/lit-html/package/node/directives/if-defined.js | 7 
 front_end/third_party/lit-html/package/node/directives/if-defined.js.map | 1 
 front_end/third_party/lit-html/package/node/directives/join.js | 7 
 front_end/third_party/lit-html/package/node/directives/join.js.map | 1 
 front_end/third_party/lit-html/package/node/directives/keyed.js | 7 
 front_end/third_party/lit-html/package/node/directives/keyed.js.map | 1 
 front_end/third_party/lit-html/package/node/directives/live.js | 7 
 front_end/third_party/lit-html/package/node/directives/live.js.map | 1 
 front_end/third_party/lit-html/package/node/directives/map.js | 7 
 front_end/third_party/lit-html/package/node/directives/map.js.map | 1 
 front_end/third_party/lit-html/package/node/directives/private-async-helpers.js | 7 
 front_end/third_party/lit-html/package/node/directives/private-async-helpers.js.map | 1 
 front_end/third_party/lit-html/package/node/directives/range.js | 7 
 front_end/third_party/lit-html/package/node/directives/range.js.map | 1 
 front_end/third_party/lit-html/package/node/directives/ref.js | 7 
 front_end/third_party/lit-html/package/node/directives/ref.js.map | 1 
 front_end/third_party/lit-html/package/node/directives/repeat.js | 8 
 front_end/third_party/lit-html/package/node/directives/repeat.js.map | 1 
 front_end/third_party/lit-html/package/node/directives/style-map.js | 7 
 front_end/third_party/lit-html/package/node/directives/style-map.js.map | 1 
 front_end/third_party/lit-html/package/node/directives/template-content.js | 7 
 front_end/third_party/lit-html/package/node/directives/template-content.js.map | 1 
 front_end/third_party/lit-html/package/node/directives/unsafe-html.js | 7 
 front_end/third_party/lit-html/package/node/directives/unsafe-html.js.map | 1 
 front_end/third_party/lit-html/package/node/directives/unsafe-svg.js | 7 
 front_end/third_party/lit-html/package/node/directives/unsafe-svg.js.map | 1 
 front_end/third_party/lit-html/package/node/directives/until.js | 7 
 front_end/third_party/lit-html/package/node/directives/until.js.map | 1 
 front_end/third_party/lit-html/package/node/directives/when.js | 7 
 front_end/third_party/lit-html/package/node/directives/when.js.map | 1 
 front_end/third_party/lit-html/package/node/experimental-hydrate.js | 7 
 front_end/third_party/lit-html/package/node/experimental-hydrate.js.map | 1 
 front_end/third_party/lit-html/package/node/is-server.js | 7 
 front_end/third_party/lit-html/package/node/is-server.js.map | 1 
 front_end/third_party/lit-html/package/node/lit-html.js | 7 
 front_end/third_party/lit-html/package/node/lit-html.js.map | 1 
 front_end/third_party/lit-html/package/node/polyfill-support.js | 7 
 front_end/third_party/lit-html/package/node/polyfill-support.js.map | 1 
 front_end/third_party/lit-html/package/node/private-ssr-support.js | 7 
 front_end/third_party/lit-html/package/node/private-ssr-support.js.map | 1 
 front_end/third_party/lit-html/package/node/static.js | 7 
 front_end/third_party/lit-html/package/node/static.js.map | 1 
 front_end/third_party/lit-html/package/package.json | 261 
 front_end/third_party/lit-html/package/polyfill-support.js | 2 
 front_end/third_party/lit-html/package/polyfill-support.js.map | 2 
 front_end/third_party/lit-html/package/private-ssr-support.d.ts | 4 
 front_end/third_party/lit-html/package/private-ssr-support.d.ts.map | 2 
 front_end/third_party/lit-html/package/private-ssr-support.js | 2 
 front_end/third_party/lit-html/package/private-ssr-support.js.map | 2 
 front_end/third_party/lit-html/package/static.d.ts | 35 
 front_end/third_party/lit-html/package/static.d.ts.map | 2 
 front_end/third_party/lit-html/package/static.js | 4 
 front_end/third_party/lit-html/package/static.js.map | 2 

Update `lit-html` to `2.4.0`

Bug: none
Change-Id: I33a0db4566c7b9dbd042c0e95e8ca0e446e651cb
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/4061490
Commit-Queue: Randolf Jung <[email protected]>
Reviewed-by: Jack Franklin <[email protected]>


diff --git a/front_end/third_party/lit-html/README.chromium b/front_end/third_party/lit-html/README.chromium
index afd2dd724e1ea83ab601533dee41807838f40501..bd5c39a30e2ed125334a8b83006d2d94479e29e7 100644
--- a/front_end/third_party/lit-html/README.chromium
+++ b/front_end/third_party/lit-html/README.chromium
@@ -1,7 +1,7 @@
 Name: Lit-HTML
 Short Name: lit-html
-URL: https://github.com/polymer/lit-html
+URL: https://github.com/lit/lit/tree/main/packages/lit-html
-Version: 2.2.1
+Version: 2.4.0
 License: BSD-3
 License File: package/LICENSE
 Security Critical: no




diff --git a/front_end/third_party/lit-html/package/async-directive.d.ts b/front_end/third_party/lit-html/package/async-directive.d.ts
index 400da5b96dd947869729c7019cc4f1713380ab0e..bd595b8a71f9237f0c2122632ec288647d797459 100644
--- a/front_end/third_party/lit-html/package/async-directive.d.ts
+++ b/front_end/third_party/lit-html/package/async-directive.d.ts
@@ -118,6 +119,7 @@  */
 import { Disconnectable, Part } from './lit-html.js';
 import { Directive } from './directive.js';
 /**
+ * SPDX-License-Identifier: BSD-3-Clause
  * This module is designed to add support for an async `setValue` API and
 /**
  * An abstract `Directive` base class whose `disconnected` method will be




diff --git a/front_end/third_party/lit-html/package/async-directive.d.ts.map b/front_end/third_party/lit-html/package/async-directive.d.ts.map
index a8ba53e16a406cd523c431cfdd9d8ee6ee8bf50d..06b74bdeb09f214182a4cadfcf5b27c2a1a9a844 100644
--- a/front_end/third_party/lit-html/package/async-directive.d.ts.map
+++ b/front_end/third_party/lit-html/package/async-directive.d.ts.map
@@ -1 +1 @@
-{"version":3,"file":"async-directive.d.ts","sourceRoot":"","sources":["../src/async-directive.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgHG;AAEH,OAAO,EAA2B,cAAc,EAAE,IAAI,EAAC,MAAM,eAAe,CAAC;AAE7E,OAAO,EAAC,SAAS,EAAqB,MAAM,gBAAgB,CAAC;AAC7D,OAAO,EAAC,SAAS,EAAC,MAAM,gBAAgB,CAAC;AA0JzC;;;;;;;;;;;;;;;;GAgBG;AACH,8BAAsB,cAAe,SAAQ,SAAS;IAMpD;;OAEG;IACH,WAAW,EAAG,OAAO,CAAC;IAItB;;;;;OAKG;IACM,YAAY,CACnB,IAAI,EAAE,IAAI,EACV,MAAM,EAAE,cAAc,EACtB,cAAc,EAAE,MAAM,GAAG,SAAS;IAqCpC;;;;;;;;;OASG;IACH,QAAQ,CAAC,KAAK,EAAE,OAAO;IAevB;;;;;OAKG;IACH,SAAS,CAAC,YAAY;IACtB,SAAS,CAAC,WAAW;CACtB"}
\ No newline at end of file
+{"version":3,"file":"async-directive.d.ts","sourceRoot":"","sources":["../src/async-directive.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgHG;AAEH,OAAO,EAA2B,cAAc,EAAE,IAAI,EAAC,MAAM,eAAe,CAAC;AAE7E,OAAO,EAAC,SAAS,EAAqB,MAAM,gBAAgB,CAAC;AAC7D,cAAc,gBAAgB,CAAC;AA0J/B;;;;;;;;;;;;;;;;GAgBG;AACH,8BAAsB,cAAe,SAAQ,SAAS;IAMpD;;OAEG;IACH,WAAW,EAAG,OAAO,CAAC;IAItB;;;;;OAKG;IACM,YAAY,CACnB,IAAI,EAAE,IAAI,EACV,MAAM,EAAE,cAAc,EACtB,cAAc,EAAE,MAAM,GAAG,SAAS;IAqCpC;;;;;;;;;OASG;IACH,QAAQ,CAAC,KAAK,EAAE,OAAO;IAevB;;;;;OAKG;IACH,SAAS,CAAC,YAAY;IACtB,SAAS,CAAC,WAAW;CACtB"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/async-directive.js b/front_end/third_party/lit-html/package/async-directive.js
index 6c86aacf59eef0a4eae2b59837d471a435ff8e4c..0aee36624b515a54342b2647c7c115179c140dc3 100644
--- a/front_end/third_party/lit-html/package/async-directive.js
+++ b/front_end/third_party/lit-html/package/async-directive.js
@@ -1,7 +1,7 @@
-import{isSingleExpression as i}from"./directive-helpers.js";import{Directive as t,PartType as s}from"./directive.js";export{directive}from"./directive.js";
+import{isSingleExpression as i}from"./directive-helpers.js";import{Directive as t,PartType as e}from"./directive.js";export{Directive,PartType,directive}from"./directive.js";
 /**
  * @license
  * Copyright 2017 Google LLC
  * SPDX-License-Identifier: BSD-3-Clause
- */const e=(i,t)=>{var s,o;const n=i._$AN;if(void 0===n)return!1;for(const i of n)null===(o=(s=i)._$AO)||void 0===o||o.call(s,t,!1),e(i,t);return!0},o=i=>{let t,s;do{if(void 0===(t=i._$AM))break;s=t._$AN,s.delete(i),i=t}while(0===(null==s?void 0:s.size))},n=i=>{for(let t;t=i._$AM;i=t){let s=t._$AN;if(void 0===s)t._$AN=s=new Set;else if(s.has(i))break;s.add(i),l(t)}};function r(i){void 0!==this._$AN?(o(this),this._$AM=i,n(this)):this._$AM=i}function h(i,t=!1,s=0){const n=this._$AH,r=this._$AN;if(void 0!==r&&0!==r.size)if(t)if(Array.isArray(n))for(let i=s;i<n.length;i++)e(n[i],!1),o(n[i]);else null!=n&&(e(n,!1),o(n));else e(this,i)}const l=i=>{var t,e,o,n;i.type==s.CHILD&&(null!==(t=(o=i)._$AP)&&void 0!==t||(o._$AP=h),null!==(e=(n=i)._$AQ)&&void 0!==e||(n._$AQ=r))};class d extends t{constructor(){super(...arguments),this._$AN=void 0}_$AT(i,t,s){super._$AT(i,t,s),n(this),this.isConnected=i._$AU}_$AO(i,t=!0){var s,n;i!==this.isConnected&&(this.isConnected=i,i?null===(s=this.reconnected)||void 0===s||s.call(this):null===(n=this.disconnected)||void 0===n||n.call(this)),t&&(e(this,i),o(this))}setValue(t){if(i(this._$Ct))this._$Ct._$AI(t,this);else{const i=[...this._$Ct._$AH];i[this._$Ci]=t,this._$Ct._$AI(i,this,0)}}disconnected(){}reconnected(){}}export{d as AsyncDirective};
+ */const s=(i,t)=>{var e,o;const r=i._$AN;if(void 0===r)return!1;for(const i of r)null===(o=(e=i)._$AO)||void 0===o||o.call(e,t,!1),s(i,t);return!0},o=i=>{let t,e;do{if(void 0===(t=i._$AM))break;e=t._$AN,e.delete(i),i=t}while(0===(null==e?void 0:e.size))},r=i=>{for(let t;t=i._$AM;i=t){let e=t._$AN;if(void 0===e)t._$AN=e=new Set;else if(e.has(i))break;e.add(i),l(t)}};function n(i){void 0!==this._$AN?(o(this),this._$AM=i,r(this)):this._$AM=i}function h(i,t=!1,e=0){const r=this._$AH,n=this._$AN;if(void 0!==n&&0!==n.size)if(t)if(Array.isArray(r))for(let i=e;i<r.length;i++)s(r[i],!1),o(r[i]);else null!=r&&(s(r,!1),o(r));else s(this,i)}const l=i=>{var t,s,o,r;i.type==e.CHILD&&(null!==(t=(o=i)._$AP)&&void 0!==t||(o._$AP=h),null!==(s=(r=i)._$AQ)&&void 0!==s||(r._$AQ=n))};class c extends t{constructor(){super(...arguments),this._$AN=void 0}_$AT(i,t,e){super._$AT(i,t,e),r(this),this.isConnected=i._$AU}_$AO(i,t=!0){var e,r;i!==this.isConnected&&(this.isConnected=i,i?null===(e=this.reconnected)||void 0===e||e.call(this):null===(r=this.disconnected)||void 0===r||r.call(this)),t&&(s(this,i),o(this))}setValue(t){if(i(this._$Ct))this._$Ct._$AI(t,this);else{const i=[...this._$Ct._$AH];i[this._$Ci]=t,this._$Ct._$AI(i,this,0)}}disconnected(){}reconnected(){}}export{c as AsyncDirective};
 //# sourceMappingURL=async-directive.js.map




diff --git a/front_end/third_party/lit-html/package/async-directive.js.map b/front_end/third_party/lit-html/package/async-directive.js.map
index 974951e97a51e86c89107d9749c536215cce5afc..df8c9880c5b786f1121482c55aca5dd065f4f280 100644
--- a/front_end/third_party/lit-html/package/async-directive.js.map
+++ b/front_end/third_party/lit-html/package/async-directive.js.map
@@ -1 +1 @@
-{"version":3,"file":"async-directive.js","sources":["src/async-directive.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n/**\n * Overview:\n *\n * This module is designed to add support for an async `setValue` API and\n * `disconnected` callback to directives with the least impact on the core\n * runtime or payload when that feature is not used.\n *\n * The strategy is to introduce a `AsyncDirective` subclass of\n * `Directive` that climbs the \"parent\" tree in its constructor to note which\n * branches of lit-html's \"logical tree\" of data structures contain such\n * directives and thus need to be crawled when a subtree is being cleared (or\n * manually disconnected) in order to run the `disconnected` callback.\n *\n * The \"nodes\" of the logical tree include Parts, TemplateInstances (for when a\n * TemplateResult is committed to a value of a ChildPart), and Directives; these\n * all implement a common interface called `DisconnectableChild`. Each has a\n * `_$parent` reference which is set during construction in the core code, and a\n * `_$disconnectableChildren` field which is initially undefined.\n *\n * The sparse tree created by means of the `AsyncDirective` constructor\n * crawling up the `_$parent` tree and placing a `_$disconnectableChildren` Set\n * on each parent that includes each child that contains a\n * `AsyncDirective` directly or transitively via its children. In order to\n * notify connection state changes and disconnect (or reconnect) a tree, the\n * `_$notifyConnectionChanged` API is patched onto ChildParts as a directive\n * climbs the parent tree, which is called by the core when clearing a part if\n * it exists. When called, that method iterates over the sparse tree of\n * Set<DisconnectableChildren> built up by AsyncDirectives, and calls\n * `_$notifyDirectiveConnectionChanged` on any directives that are encountered\n * in that tree, running the required callbacks.\n *\n * A given \"logical tree\" of lit-html data-structures might look like this:\n *\n *  ChildPart(N1) _$dC=[D2,T3]\n *   ._directive\n *     AsyncDirective(D2)\n *   ._value // user value was TemplateResult\n *     TemplateInstance(T3) _$dC=[A4,A6,N10,N12]\n *      ._parts[]\n *        AttributePart(A4) _$dC=[D5]\n *         ._directives[]\n *           AsyncDirective(D5)\n *        AttributePart(A6) _$dC=[D7,D8]\n *         ._directives[]\n *           AsyncDirective(D7)\n *           Directive(D8) _$dC=[D9]\n *            ._directive\n *              AsyncDirective(D9)\n *        ChildPart(N10) _$dC=[D11]\n *         ._directive\n *           AsyncDirective(D11)\n *         ._value\n *           string\n *        ChildPart(N12) _$dC=[D13,N14,N16]\n *         ._directive\n *           AsyncDirective(D13)\n *         ._value // user value was iterable\n *           Array<ChildPart>\n *             ChildPart(N14) _$dC=[D15]\n *              ._value\n *                string\n *             ChildPart(N16) _$dC=[D17,T18]\n *              ._directive\n *                AsyncDirective(D17)\n *              ._value // user value was TemplateResult\n *                TemplateInstance(T18) _$dC=[A19,A21,N25]\n *                 ._parts[]\n *                   AttributePart(A19) _$dC=[D20]\n *                    ._directives[]\n *                      AsyncDirective(D20)\n *                   AttributePart(A21) _$dC=[22,23]\n *                    ._directives[]\n *                      AsyncDirective(D22)\n *                      Directive(D23) _$dC=[D24]\n *                       ._directive\n *                         AsyncDirective(D24)\n *                   ChildPart(N25) _$dC=[D26]\n *                    ._directive\n *                      AsyncDirective(D26)\n *                    ._value\n *                      string\n *\n * Example 1: The directive in ChildPart(N12) updates and returns `nothing`. The\n * ChildPart will _clear() itself, and so we need to disconnect the \"value\" of\n * the ChildPart (but not its directive). In this case, when `_clear()` calls\n * `_$notifyConnectionChanged()`, we don't iterate all of the\n * _$disconnectableChildren, rather we do a value-specific disconnection: i.e.\n * since the _value was an Array<ChildPart> (because an iterable had been\n * committed), we iterate the array of ChildParts (N14, N16) and run\n * `setConnected` on them (which does recurse down the full tree of\n * `_$disconnectableChildren` below it, and also removes N14 and N16 from N12's\n * `_$disconnectableChildren`). Once the values have been disconnected, we then\n * check whether the ChildPart(N12)'s list of `_$disconnectableChildren` is empty\n * (and would remove it from its parent TemplateInstance(T3) if so), but since\n * it would still contain its directive D13, it stays in the disconnectable\n * tree.\n *\n * Example 2: In the course of Example 1, `setConnected` will reach\n * ChildPart(N16); in this case the entire part is being disconnected, so we\n * simply iterate all of N16's `_$disconnectableChildren` (D17,T18) and\n * recursively run `setConnected` on them. Note that we only remove children\n * from `_$disconnectableChildren` for the top-level values being disconnected\n * on a clear; doing this bookkeeping lower in the tree is wasteful since it's\n * all being thrown away.\n *\n * Example 3: If the LitElement containing the entire tree above becomes\n * disconnected, it will run `childPart.setConnected()` (which calls\n * `childPart._$notifyConnectionChanged()` if it exists); in this case, we\n * recursively run `setConnected()` over the entire tree, without removing any\n * children from `_$disconnectableChildren`, since this tree is required to\n * re-connect the tree, which does the same operation, simply passing\n * `isConnected: true` down the tree, signaling which callback to run.\n */\n\nimport {AttributePart, ChildPart, Disconnectable, Part} from './lit-html.js';\nimport {isSingleExpression} from './directive-helpers.js';\nimport {Directive, PartInfo, PartType} from './directive.js';\nexport {directive} from './directive.js';\n\nconst DEV_MODE = true;\n\n/**\n * Recursively walks down the tree of Parts/TemplateInstances/Directives to set\n * the connected state of directives and run `disconnected`/ `reconnected`\n * callbacks.\n *\n * @return True if there were children to disconnect; false otherwise\n */\nconst notifyChildrenConnectedChanged = (\n  parent: Disconnectable,\n  isConnected: boolean\n): boolean => {\n  const children = parent._$disconnectableChildren;\n  if (children === undefined) {\n    return false;\n  }\n  for (const obj of children) {\n    // The existence of `_$notifyDirectiveConnectionChanged` is used as a \"brand\" to\n    // disambiguate AsyncDirectives from other DisconnectableChildren\n    // (as opposed to using an instanceof check to know when to call it); the\n    // redundancy of \"Directive\" in the API name is to avoid conflicting with\n    // `_$notifyConnectionChanged`, which exists `ChildParts` which are also in\n    // this list\n    // Disconnect Directive (and any nested directives contained within)\n    // This property needs to remain unminified.\n    (obj as AsyncDirective)['_$notifyDirectiveConnectionChanged']?.(\n      isConnected,\n      false\n    );\n    // Disconnect Part/TemplateInstance\n    notifyChildrenConnectedChanged(obj, isConnected);\n  }\n  return true;\n};\n\n/**\n * Removes the given child from its parent list of disconnectable children, and\n * if the parent list becomes empty as a result, removes the parent from its\n * parent, and so forth up the tree when that causes subsequent parent lists to\n * become empty.\n */\nconst removeDisconnectableFromParent = (obj: Disconnectable) => {\n  let parent, children;\n  do {\n    if ((parent = obj._$parent) === undefined) {\n      break;\n    }\n    children = parent._$disconnectableChildren!;\n    children.delete(obj);\n    obj = parent;\n  } while (children?.size === 0);\n};\n\nconst addDisconnectableToParent = (obj: Disconnectable) => {\n  // Climb the parent tree, creating a sparse tree of children needing\n  // disconnection\n  for (let parent; (parent = obj._$parent); obj = parent) {\n    let children = parent._$disconnectableChildren;\n    if (children === undefined) {\n      parent._$disconnectableChildren = children = new Set();\n    } else if (children.has(obj)) {\n      // Once we've reached a parent that already contains this child, we\n      // can short-circuit\n      break;\n    }\n    children.add(obj);\n    installDisconnectAPI(parent);\n  }\n};\n\n/**\n * Changes the parent reference of the ChildPart, and updates the sparse tree of\n * Disconnectable children accordingly.\n *\n * Note, this method will be patched onto ChildPart instances and called from\n * the core code when parts are moved between different parents.\n */\nfunction reparentDisconnectables(this: ChildPart, newParent: Disconnectable) {\n  if (this._$disconnectableChildren !== undefined) {\n    removeDisconnectableFromParent(this);\n    this._$parent = newParent;\n    addDisconnectableToParent(this);\n  } else {\n    this._$parent = newParent;\n  }\n}\n\n/**\n * Sets the connected state on any directives contained within the committed\n * value of this part (i.e. within a TemplateInstance or iterable of\n * ChildParts) and runs their `disconnected`/`reconnected`s, as well as within\n * any directives stored on the ChildPart (when `valueOnly` is false).\n *\n * `isClearingValue` should be passed as `true` on a top-level part that is\n * clearing itself, and not as a result of recursively disconnecting directives\n * as part of a `clear` operation higher up the tree. This both ensures that any\n * directive on this ChildPart that produced a value that caused the clear\n * operation is not disconnected, and also serves as a performance optimization\n * to avoid needless bookkeeping when a subtree is going away; when clearing a\n * subtree, only the top-most part need to remove itself from the parent.\n *\n * `fromPartIndex` is passed only in the case of a partial `_clear` running as a\n * result of truncating an iterable.\n *\n * Note, this method will be patched onto ChildPart instances and called from the\n * core code when parts are cleared or the connection state is changed by the\n * user.\n */\nfunction notifyChildPartConnectedChanged(\n  this: ChildPart,\n  isConnected: boolean,\n  isClearingValue = false,\n  fromPartIndex = 0\n) {\n  const value = this._$committedValue;\n  const children = this._$disconnectableChildren;\n  if (children === undefined || children.size === 0) {\n    return;\n  }\n  if (isClearingValue) {\n    if (Array.isArray(value)) {\n      // Iterable case: Any ChildParts created by the iterable should be\n      // disconnected and removed from this ChildPart's disconnectable\n      // children (starting at `fromPartIndex` in the case of truncation)\n      for (let i = fromPartIndex; i < value.length; i++) {\n        notifyChildrenConnectedChanged(value[i], false);\n        removeDisconnectableFromParent(value[i]);\n      }\n    } else if (value != null) {\n      // TemplateInstance case: If the value has disconnectable children (will\n      // only be in the case that it is a TemplateInstance), we disconnect it\n      // and remove it from this ChildPart's disconnectable children\n      notifyChildrenConnectedChanged(value as Disconnectable, false);\n      removeDisconnectableFromParent(value as Disconnectable);\n    }\n  } else {\n    notifyChildrenConnectedChanged(this, isConnected);\n  }\n}\n\n/**\n * Patches disconnection API onto ChildParts.\n */\nconst installDisconnectAPI = (obj: Disconnectable) => {\n  if ((obj as ChildPart).type == PartType.CHILD) {\n    (obj as ChildPart)._$notifyConnectionChanged ??=\n      notifyChildPartConnectedChanged;\n    (obj as ChildPart)._$reparentDisconnectables ??= reparentDisconnectables;\n  }\n};\n\n/**\n * An abstract `Directive` base class whose `disconnected` method will be\n * called when the part containing the directive is cleared as a result of\n * re-rendering, or when the user calls `part.setConnected(false)` on\n * a part that was previously rendered containing the directive (as happens\n * when e.g. a LitElement disconnects from the DOM).\n *\n * If `part.setConnected(true)` is subsequently called on a\n * containing part, the directive's `reconnected` method will be called prior\n * to its next `update`/`render` callbacks. When implementing `disconnected`,\n * `reconnected` should also be implemented to be compatible with reconnection.\n *\n * Note that updates may occur while the directive is disconnected. As such,\n * directives should generally check the `this.isConnected` flag during\n * render/update to determine whether it is safe to subscribe to resources\n * that may prevent garbage collection.\n */\nexport abstract class AsyncDirective extends Directive {\n  // As opposed to other Disconnectables, AsyncDirectives always get notified\n  // when the RootPart connection changes, so the public `isConnected`\n  // is a locally stored variable initialized via its part's getter and synced\n  // via `_$notifyDirectiveConnectionChanged`. This is cheaper than using\n  // the _$isConnected getter, which has to look back up the tree each time.\n  /**\n   * The connection state for this Directive.\n   */\n  isConnected!: boolean;\n\n  // @internal\n  override _$disconnectableChildren?: Set<Disconnectable> = undefined;\n  /**\n   * Initialize the part with internal fields\n   * @param part\n   * @param parent\n   * @param attributeIndex\n   */\n  override _$initialize(\n    part: Part,\n    parent: Disconnectable,\n    attributeIndex: number | undefined\n  ) {\n    super._$initialize(part, parent, attributeIndex);\n    addDisconnectableToParent(this);\n    this.isConnected = part._$isConnected;\n  }\n  // This property needs to remain unminified.\n  /**\n   * Called from the core code when a directive is going away from a part (in\n   * which case `shouldRemoveFromParent` should be true), and from the\n   * `setChildrenConnected` helper function when recursively changing the\n   * connection state of a tree (in which case `shouldRemoveFromParent` should\n   * be false).\n   *\n   * @param isConnected\n   * @param isClearingDirective - True when the directive itself is being\n   *     removed; false when the tree is being disconnected\n   * @internal\n   */\n  override ['_$notifyDirectiveConnectionChanged'](\n    isConnected: boolean,\n    isClearingDirective = true\n  ) {\n    if (isConnected !== this.isConnected) {\n      this.isConnected = isConnected;\n      if (isConnected) {\n        this.reconnected?.();\n      } else {\n        this.disconnected?.();\n      }\n    }\n    if (isClearingDirective) {\n      notifyChildrenConnectedChanged(this, isConnected);\n      removeDisconnectableFromParent(this);\n    }\n  }\n\n  /**\n   * Sets the value of the directive's Part outside the normal `update`/`render`\n   * lifecycle of a directive.\n   *\n   * This method should not be called synchronously from a directive's `update`\n   * or `render`.\n   *\n   * @param directive The directive to update\n   * @param value The value to set\n   */\n  setValue(value: unknown) {\n    if (isSingleExpression(this.__part as unknown as PartInfo)) {\n      this.__part._$setValue(value, this);\n    } else {\n      // this.__attributeIndex will be defined in this case, but\n      // assert it in dev mode\n      if (DEV_MODE && this.__attributeIndex === undefined) {\n        throw new Error(`Expected this.__attributeIndex to be a number`);\n      }\n      const newValues = [...(this.__part._$committedValue as Array<unknown>)];\n      newValues[this.__attributeIndex!] = value;\n      (this.__part as AttributePart)._$setValue(newValues, this, 0);\n    }\n  }\n\n  /**\n   * User callbacks for implementing logic to release any resources/subscriptions\n   * that may have been retained by this directive. Since directives may also be\n   * re-connected, `reconnected` should also be implemented to restore the\n   * working state of the directive prior to the next render.\n   */\n  protected disconnected() {}\n  protected reconnected() {}\n}\n"],"names":["notifyChildrenConnectedChanged","parent","isConnected","children","_$disconnectableChildren","undefined","obj","removeDisconnectableFromParent","_$parent","delete","size","addDisconnectableToParent","Set","has","add","installDisconnectAPI","reparentDisconnectables","newParent","this","notifyChildPartConnectedChanged","isClearingValue","fromPartIndex","value","_$committedValue","Array","isArray","i","length","type","PartType","CHILD","_$notifyConnectionChanged","_$reparentDisconnectables","AsyncDirective","Directive","constructor","_$initialize","part","attributeIndex","super","_$isConnected","_$AO","isClearingDirective","reconnected","disconnected","setValue","isSingleExpression","__part","_$setValue","newValues","__attributeIndex"],"mappings":";;;;;GAsIA,MAAMA,EAAiC,CACrCC,EACAC,aAEA,MAAMC,EAAWF,EAAOG,KACxB,QAAiBC,IAAbF,EACF,OAAO,EAET,IAAK,MAAMG,KAAOH,eASfG,GAA2D,4BAC1DJ,GACA,GAGFF,EAA+BM,EAAKJ,GAEtC,OAAO,GASHK,EAAkCD,IACtC,IAAIL,EAAQE,EACZ,EAAG,CACD,QAAgCE,KAA3BJ,EAASK,EAAIE,MAChB,MAEFL,EAAWF,EAAOG,KAClBD,EAASM,OAAOH,GAChBA,EAAML,QACoB,KAAnBE,MAAAA,SAAAA,EAAUO,QAGfC,EAA6BL,IAGjC,IAAK,IAAIL,EAASA,EAASK,EAAIE,KAAWF,EAAML,EAAQ,CACtD,IAAIE,EAAWF,EAAOG,KACtB,QAAiBC,IAAbF,EACFF,EAAOG,KAA2BD,EAAW,IAAIS,SAC5C,GAAIT,EAASU,IAAIP,GAGtB,MAEFH,EAASW,IAAIR,GACbS,EAAqBd,KAWzB,SAASe,EAAyCC,QACVZ,IAAlCa,KAAKd,MACPG,EAA+BW,MAC/BA,KAAKV,KAAWS,EAChBN,EAA0BO,OAE1BA,KAAKV,KAAWS,EAyBpB,SAASE,EAEPjB,EACAkB,GAAkB,EAClBC,EAAgB,GAEhB,MAAMC,EAAQJ,KAAKK,KACbpB,EAAWe,KAAKd,KACtB,QAAiBC,IAAbF,GAA4C,IAAlBA,EAASO,KAGvC,GAAIU,EACF,GAAII,MAAMC,QAAQH,GAIhB,IAAK,IAAII,EAAIL,EAAeK,EAAIJ,EAAMK,OAAQD,IAC5C1B,EAA+BsB,EAAMI,IAAI,GACzCnB,EAA+Be,EAAMI,SAErB,MAATJ,IAITtB,EAA+BsB,GAAyB,GACxDf,EAA+Be,SAGjCtB,EAA+BkB,KAAMhB,GAOzC,MAAMa,EAAwBT,gBACvBA,EAAkBsB,MAAQC,EAASC,qBACrCxB,GAAkByB,sBAAAA,KACjBZ,gBACDb,GAAkB0B,sBAAAA,KAA8BhB,WAqB/BiB,UAAuBC,EAA7CC,kCAYWjB,eAAiDb,EAOjD+B,KACPC,EACApC,EACAqC,GAEAC,MAAMH,KAAaC,EAAMpC,EAAQqC,GACjC3B,EAA0BO,MAC1BA,KAAKhB,YAAcmC,EAAKG,KAejBC,KACPvC,EACAwC,GAAsB,WAElBxC,IAAgBgB,KAAKhB,cACvBgB,KAAKhB,YAAcA,EACfA,YACFgB,KAAKyB,iCAALzB,gBAEAA,KAAK0B,kCAAL1B,OAGAwB,IACF1C,EAA+BkB,KAAMhB,GACrCK,EAA+BW,OAcnC2B,SAASvB,GACP,GAAIwB,EAAmB5B,KAAK6B,MAC1B7B,KAAK6B,KAAOC,KAAW1B,EAAOJ,UACzB,CAML,MAAM+B,EAAY,IAAK/B,KAAK6B,KAAOxB,MACnC0B,EAAU/B,KAAKgC,MAAqB5B,EACnCJ,KAAK6B,KAAyBC,KAAWC,EAAW/B,KAAM,IAUrD0B,gBACAD"}
\ No newline at end of file
+{"version":3,"file":"async-directive.js","sources":["src/async-directive.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n/**\n * Overview:\n *\n * This module is designed to add support for an async `setValue` API and\n * `disconnected` callback to directives with the least impact on the core\n * runtime or payload when that feature is not used.\n *\n * The strategy is to introduce a `AsyncDirective` subclass of\n * `Directive` that climbs the \"parent\" tree in its constructor to note which\n * branches of lit-html's \"logical tree\" of data structures contain such\n * directives and thus need to be crawled when a subtree is being cleared (or\n * manually disconnected) in order to run the `disconnected` callback.\n *\n * The \"nodes\" of the logical tree include Parts, TemplateInstances (for when a\n * TemplateResult is committed to a value of a ChildPart), and Directives; these\n * all implement a common interface called `DisconnectableChild`. Each has a\n * `_$parent` reference which is set during construction in the core code, and a\n * `_$disconnectableChildren` field which is initially undefined.\n *\n * The sparse tree created by means of the `AsyncDirective` constructor\n * crawling up the `_$parent` tree and placing a `_$disconnectableChildren` Set\n * on each parent that includes each child that contains a\n * `AsyncDirective` directly or transitively via its children. In order to\n * notify connection state changes and disconnect (or reconnect) a tree, the\n * `_$notifyConnectionChanged` API is patched onto ChildParts as a directive\n * climbs the parent tree, which is called by the core when clearing a part if\n * it exists. When called, that method iterates over the sparse tree of\n * Set<DisconnectableChildren> built up by AsyncDirectives, and calls\n * `_$notifyDirectiveConnectionChanged` on any directives that are encountered\n * in that tree, running the required callbacks.\n *\n * A given \"logical tree\" of lit-html data-structures might look like this:\n *\n *  ChildPart(N1) _$dC=[D2,T3]\n *   ._directive\n *     AsyncDirective(D2)\n *   ._value // user value was TemplateResult\n *     TemplateInstance(T3) _$dC=[A4,A6,N10,N12]\n *      ._parts[]\n *        AttributePart(A4) _$dC=[D5]\n *         ._directives[]\n *           AsyncDirective(D5)\n *        AttributePart(A6) _$dC=[D7,D8]\n *         ._directives[]\n *           AsyncDirective(D7)\n *           Directive(D8) _$dC=[D9]\n *            ._directive\n *              AsyncDirective(D9)\n *        ChildPart(N10) _$dC=[D11]\n *         ._directive\n *           AsyncDirective(D11)\n *         ._value\n *           string\n *        ChildPart(N12) _$dC=[D13,N14,N16]\n *         ._directive\n *           AsyncDirective(D13)\n *         ._value // user value was iterable\n *           Array<ChildPart>\n *             ChildPart(N14) _$dC=[D15]\n *              ._value\n *                string\n *             ChildPart(N16) _$dC=[D17,T18]\n *              ._directive\n *                AsyncDirective(D17)\n *              ._value // user value was TemplateResult\n *                TemplateInstance(T18) _$dC=[A19,A21,N25]\n *                 ._parts[]\n *                   AttributePart(A19) _$dC=[D20]\n *                    ._directives[]\n *                      AsyncDirective(D20)\n *                   AttributePart(A21) _$dC=[22,23]\n *                    ._directives[]\n *                      AsyncDirective(D22)\n *                      Directive(D23) _$dC=[D24]\n *                       ._directive\n *                         AsyncDirective(D24)\n *                   ChildPart(N25) _$dC=[D26]\n *                    ._directive\n *                      AsyncDirective(D26)\n *                    ._value\n *                      string\n *\n * Example 1: The directive in ChildPart(N12) updates and returns `nothing`. The\n * ChildPart will _clear() itself, and so we need to disconnect the \"value\" of\n * the ChildPart (but not its directive). In this case, when `_clear()` calls\n * `_$notifyConnectionChanged()`, we don't iterate all of the\n * _$disconnectableChildren, rather we do a value-specific disconnection: i.e.\n * since the _value was an Array<ChildPart> (because an iterable had been\n * committed), we iterate the array of ChildParts (N14, N16) and run\n * `setConnected` on them (which does recurse down the full tree of\n * `_$disconnectableChildren` below it, and also removes N14 and N16 from N12's\n * `_$disconnectableChildren`). Once the values have been disconnected, we then\n * check whether the ChildPart(N12)'s list of `_$disconnectableChildren` is empty\n * (and would remove it from its parent TemplateInstance(T3) if so), but since\n * it would still contain its directive D13, it stays in the disconnectable\n * tree.\n *\n * Example 2: In the course of Example 1, `setConnected` will reach\n * ChildPart(N16); in this case the entire part is being disconnected, so we\n * simply iterate all of N16's `_$disconnectableChildren` (D17,T18) and\n * recursively run `setConnected` on them. Note that we only remove children\n * from `_$disconnectableChildren` for the top-level values being disconnected\n * on a clear; doing this bookkeeping lower in the tree is wasteful since it's\n * all being thrown away.\n *\n * Example 3: If the LitElement containing the entire tree above becomes\n * disconnected, it will run `childPart.setConnected()` (which calls\n * `childPart._$notifyConnectionChanged()` if it exists); in this case, we\n * recursively run `setConnected()` over the entire tree, without removing any\n * children from `_$disconnectableChildren`, since this tree is required to\n * re-connect the tree, which does the same operation, simply passing\n * `isConnected: true` down the tree, signaling which callback to run.\n */\n\nimport {AttributePart, ChildPart, Disconnectable, Part} from './lit-html.js';\nimport {isSingleExpression} from './directive-helpers.js';\nimport {Directive, PartInfo, PartType} from './directive.js';\nexport * from './directive.js';\n\nconst DEV_MODE = true;\n\n/**\n * Recursively walks down the tree of Parts/TemplateInstances/Directives to set\n * the connected state of directives and run `disconnected`/ `reconnected`\n * callbacks.\n *\n * @return True if there were children to disconnect; false otherwise\n */\nconst notifyChildrenConnectedChanged = (\n  parent: Disconnectable,\n  isConnected: boolean\n): boolean => {\n  const children = parent._$disconnectableChildren;\n  if (children === undefined) {\n    return false;\n  }\n  for (const obj of children) {\n    // The existence of `_$notifyDirectiveConnectionChanged` is used as a \"brand\" to\n    // disambiguate AsyncDirectives from other DisconnectableChildren\n    // (as opposed to using an instanceof check to know when to call it); the\n    // redundancy of \"Directive\" in the API name is to avoid conflicting with\n    // `_$notifyConnectionChanged`, which exists `ChildParts` which are also in\n    // this list\n    // Disconnect Directive (and any nested directives contained within)\n    // This property needs to remain unminified.\n    (obj as AsyncDirective)['_$notifyDirectiveConnectionChanged']?.(\n      isConnected,\n      false\n    );\n    // Disconnect Part/TemplateInstance\n    notifyChildrenConnectedChanged(obj, isConnected);\n  }\n  return true;\n};\n\n/**\n * Removes the given child from its parent list of disconnectable children, and\n * if the parent list becomes empty as a result, removes the parent from its\n * parent, and so forth up the tree when that causes subsequent parent lists to\n * become empty.\n */\nconst removeDisconnectableFromParent = (obj: Disconnectable) => {\n  let parent, children;\n  do {\n    if ((parent = obj._$parent) === undefined) {\n      break;\n    }\n    children = parent._$disconnectableChildren!;\n    children.delete(obj);\n    obj = parent;\n  } while (children?.size === 0);\n};\n\nconst addDisconnectableToParent = (obj: Disconnectable) => {\n  // Climb the parent tree, creating a sparse tree of children needing\n  // disconnection\n  for (let parent; (parent = obj._$parent); obj = parent) {\n    let children = parent._$disconnectableChildren;\n    if (children === undefined) {\n      parent._$disconnectableChildren = children = new Set();\n    } else if (children.has(obj)) {\n      // Once we've reached a parent that already contains this child, we\n      // can short-circuit\n      break;\n    }\n    children.add(obj);\n    installDisconnectAPI(parent);\n  }\n};\n\n/**\n * Changes the parent reference of the ChildPart, and updates the sparse tree of\n * Disconnectable children accordingly.\n *\n * Note, this method will be patched onto ChildPart instances and called from\n * the core code when parts are moved between different parents.\n */\nfunction reparentDisconnectables(this: ChildPart, newParent: Disconnectable) {\n  if (this._$disconnectableChildren !== undefined) {\n    removeDisconnectableFromParent(this);\n    this._$parent = newParent;\n    addDisconnectableToParent(this);\n  } else {\n    this._$parent = newParent;\n  }\n}\n\n/**\n * Sets the connected state on any directives contained within the committed\n * value of this part (i.e. within a TemplateInstance or iterable of\n * ChildParts) and runs their `disconnected`/`reconnected`s, as well as within\n * any directives stored on the ChildPart (when `valueOnly` is false).\n *\n * `isClearingValue` should be passed as `true` on a top-level part that is\n * clearing itself, and not as a result of recursively disconnecting directives\n * as part of a `clear` operation higher up the tree. This both ensures that any\n * directive on this ChildPart that produced a value that caused the clear\n * operation is not disconnected, and also serves as a performance optimization\n * to avoid needless bookkeeping when a subtree is going away; when clearing a\n * subtree, only the top-most part need to remove itself from the parent.\n *\n * `fromPartIndex` is passed only in the case of a partial `_clear` running as a\n * result of truncating an iterable.\n *\n * Note, this method will be patched onto ChildPart instances and called from the\n * core code when parts are cleared or the connection state is changed by the\n * user.\n */\nfunction notifyChildPartConnectedChanged(\n  this: ChildPart,\n  isConnected: boolean,\n  isClearingValue = false,\n  fromPartIndex = 0\n) {\n  const value = this._$committedValue;\n  const children = this._$disconnectableChildren;\n  if (children === undefined || children.size === 0) {\n    return;\n  }\n  if (isClearingValue) {\n    if (Array.isArray(value)) {\n      // Iterable case: Any ChildParts created by the iterable should be\n      // disconnected and removed from this ChildPart's disconnectable\n      // children (starting at `fromPartIndex` in the case of truncation)\n      for (let i = fromPartIndex; i < value.length; i++) {\n        notifyChildrenConnectedChanged(value[i], false);\n        removeDisconnectableFromParent(value[i]);\n      }\n    } else if (value != null) {\n      // TemplateInstance case: If the value has disconnectable children (will\n      // only be in the case that it is a TemplateInstance), we disconnect it\n      // and remove it from this ChildPart's disconnectable children\n      notifyChildrenConnectedChanged(value as Disconnectable, false);\n      removeDisconnectableFromParent(value as Disconnectable);\n    }\n  } else {\n    notifyChildrenConnectedChanged(this, isConnected);\n  }\n}\n\n/**\n * Patches disconnection API onto ChildParts.\n */\nconst installDisconnectAPI = (obj: Disconnectable) => {\n  if ((obj as ChildPart).type == PartType.CHILD) {\n    (obj as ChildPart)._$notifyConnectionChanged ??=\n      notifyChildPartConnectedChanged;\n    (obj as ChildPart)._$reparentDisconnectables ??= reparentDisconnectables;\n  }\n};\n\n/**\n * An abstract `Directive` base class whose `disconnected` method will be\n * called when the part containing the directive is cleared as a result of\n * re-rendering, or when the user calls `part.setConnected(false)` on\n * a part that was previously rendered containing the directive (as happens\n * when e.g. a LitElement disconnects from the DOM).\n *\n * If `part.setConnected(true)` is subsequently called on a\n * containing part, the directive's `reconnected` method will be called prior\n * to its next `update`/`render` callbacks. When implementing `disconnected`,\n * `reconnected` should also be implemented to be compatible with reconnection.\n *\n * Note that updates may occur while the directive is disconnected. As such,\n * directives should generally check the `this.isConnected` flag during\n * render/update to determine whether it is safe to subscribe to resources\n * that may prevent garbage collection.\n */\nexport abstract class AsyncDirective extends Directive {\n  // As opposed to other Disconnectables, AsyncDirectives always get notified\n  // when the RootPart connection changes, so the public `isConnected`\n  // is a locally stored variable initialized via its part's getter and synced\n  // via `_$notifyDirectiveConnectionChanged`. This is cheaper than using\n  // the _$isConnected getter, which has to look back up the tree each time.\n  /**\n   * The connection state for this Directive.\n   */\n  isConnected!: boolean;\n\n  // @internal\n  override _$disconnectableChildren?: Set<Disconnectable> = undefined;\n  /**\n   * Initialize the part with internal fields\n   * @param part\n   * @param parent\n   * @param attributeIndex\n   */\n  override _$initialize(\n    part: Part,\n    parent: Disconnectable,\n    attributeIndex: number | undefined\n  ) {\n    super._$initialize(part, parent, attributeIndex);\n    addDisconnectableToParent(this);\n    this.isConnected = part._$isConnected;\n  }\n  // This property needs to remain unminified.\n  /**\n   * Called from the core code when a directive is going away from a part (in\n   * which case `shouldRemoveFromParent` should be true), and from the\n   * `setChildrenConnected` helper function when recursively changing the\n   * connection state of a tree (in which case `shouldRemoveFromParent` should\n   * be false).\n   *\n   * @param isConnected\n   * @param isClearingDirective - True when the directive itself is being\n   *     removed; false when the tree is being disconnected\n   * @internal\n   */\n  override ['_$notifyDirectiveConnectionChanged'](\n    isConnected: boolean,\n    isClearingDirective = true\n  ) {\n    if (isConnected !== this.isConnected) {\n      this.isConnected = isConnected;\n      if (isConnected) {\n        this.reconnected?.();\n      } else {\n        this.disconnected?.();\n      }\n    }\n    if (isClearingDirective) {\n      notifyChildrenConnectedChanged(this, isConnected);\n      removeDisconnectableFromParent(this);\n    }\n  }\n\n  /**\n   * Sets the value of the directive's Part outside the normal `update`/`render`\n   * lifecycle of a directive.\n   *\n   * This method should not be called synchronously from a directive's `update`\n   * or `render`.\n   *\n   * @param directive The directive to update\n   * @param value The value to set\n   */\n  setValue(value: unknown) {\n    if (isSingleExpression(this.__part as unknown as PartInfo)) {\n      this.__part._$setValue(value, this);\n    } else {\n      // this.__attributeIndex will be defined in this case, but\n      // assert it in dev mode\n      if (DEV_MODE && this.__attributeIndex === undefined) {\n        throw new Error(`Expected this.__attributeIndex to be a number`);\n      }\n      const newValues = [...(this.__part._$committedValue as Array<unknown>)];\n      newValues[this.__attributeIndex!] = value;\n      (this.__part as AttributePart)._$setValue(newValues, this, 0);\n    }\n  }\n\n  /**\n   * User callbacks for implementing logic to release any resources/subscriptions\n   * that may have been retained by this directive. Since directives may also be\n   * re-connected, `reconnected` should also be implemented to restore the\n   * working state of the directive prior to the next render.\n   */\n  protected disconnected() {}\n  protected reconnected() {}\n}\n"],"names":["notifyChildrenConnectedChanged","parent","isConnected","children","_$disconnectableChildren","undefined","obj","_b","_a","removeDisconnectableFromParent","_$parent","delete","size","addDisconnectableToParent","Set","has","add","installDisconnectAPI","reparentDisconnectables","newParent","this","notifyChildPartConnectedChanged","isClearingValue","fromPartIndex","value","_$committedValue","Array","isArray","i","length","type","PartType","CHILD","_c","_$notifyConnectionChanged","_d","_$reparentDisconnectables","AsyncDirective","Directive","constructor","_$initialize","part","attributeIndex","super","_$isConnected","_$AO","isClearingDirective","reconnected","call","disconnected","setValue","isSingleExpression","__part","_$setValue","newValues","__attributeIndex"],"mappings":";;;;;GAsIA,MAAMA,EAAiC,CACrCC,EACAC,aAEA,MAAMC,EAAWF,EAAOG,KACxB,QAAiBC,IAAbF,EACF,OAAO,EAET,IAAK,MAAMG,KAAOH,UAShBI,GAAAC,EAACF,GAA2D,4BAC1DJ,GACA,GAGFF,EAA+BM,EAAKJ,GAEtC,OAAO,CAAI,EASPO,EAAkCH,IACtC,IAAIL,EAAQE,EACZ,EAAG,CACD,QAAgCE,KAA3BJ,EAASK,EAAII,MAChB,MAEFP,EAAWF,EAAOG,KAClBD,EAASQ,OAAOL,GAChBA,EAAML,QACoB,KAAnBE,aAAQ,EAARA,EAAUS,MAAY,EAG3BC,EAA6BP,IAGjC,IAAK,IAAIL,EAASA,EAASK,EAAII,KAAWJ,EAAML,EAAQ,CACtD,IAAIE,EAAWF,EAAOG,KACtB,QAAiBC,IAAbF,EACFF,EAAOG,KAA2BD,EAAW,IAAIW,SAC5C,GAAIX,EAASY,IAAIT,GAGtB,MAEFH,EAASa,IAAIV,GACbW,EAAqBhB,EACtB,GAUH,SAASiB,EAAyCC,QACVd,IAAlCe,KAAKhB,MACPK,EAA+BW,MAC/BA,KAAKV,KAAWS,EAChBN,EAA0BO,OAE1BA,KAAKV,KAAWS,CAEpB,CAuBA,SAASE,EAEPnB,EACAoB,GAAkB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eAAiB,CACjBF,cAAgB"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/development/async-directive.d.ts b/front_end/third_party/lit-html/package/development/async-directive.d.ts
index 400da5b96dd947869729c7019cc4f1713380ab0e..bd595b8a71f9237f0c2122632ec288647d797459 100644
--- a/front_end/third_party/lit-html/package/development/async-directive.d.ts
+++ b/front_end/third_party/lit-html/package/development/async-directive.d.ts
@@ -118,6 +119,7 @@  */
 import { Disconnectable, Part } from './lit-html.js';
 import { Directive } from './directive.js';
 /**
+ * SPDX-License-Identifier: BSD-3-Clause
  * This module is designed to add support for an async `setValue` API and
 /**
  * An abstract `Directive` base class whose `disconnected` method will be




diff --git a/front_end/third_party/lit-html/package/development/async-directive.d.ts.map b/front_end/third_party/lit-html/package/development/async-directive.d.ts.map
index a8ba53e16a406cd523c431cfdd9d8ee6ee8bf50d..06b74bdeb09f214182a4cadfcf5b27c2a1a9a844 100644
--- a/front_end/third_party/lit-html/package/development/async-directive.d.ts.map
+++ b/front_end/third_party/lit-html/package/development/async-directive.d.ts.map
@@ -1 +1 @@
-{"version":3,"file":"async-directive.d.ts","sourceRoot":"","sources":["../src/async-directive.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgHG;AAEH,OAAO,EAA2B,cAAc,EAAE,IAAI,EAAC,MAAM,eAAe,CAAC;AAE7E,OAAO,EAAC,SAAS,EAAqB,MAAM,gBAAgB,CAAC;AAC7D,OAAO,EAAC,SAAS,EAAC,MAAM,gBAAgB,CAAC;AA0JzC;;;;;;;;;;;;;;;;GAgBG;AACH,8BAAsB,cAAe,SAAQ,SAAS;IAMpD;;OAEG;IACH,WAAW,EAAG,OAAO,CAAC;IAItB;;;;;OAKG;IACM,YAAY,CACnB,IAAI,EAAE,IAAI,EACV,MAAM,EAAE,cAAc,EACtB,cAAc,EAAE,MAAM,GAAG,SAAS;IAqCpC;;;;;;;;;OASG;IACH,QAAQ,CAAC,KAAK,EAAE,OAAO;IAevB;;;;;OAKG;IACH,SAAS,CAAC,YAAY;IACtB,SAAS,CAAC,WAAW;CACtB"}
\ No newline at end of file
+{"version":3,"file":"async-directive.d.ts","sourceRoot":"","sources":["../src/async-directive.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgHG;AAEH,OAAO,EAA2B,cAAc,EAAE,IAAI,EAAC,MAAM,eAAe,CAAC;AAE7E,OAAO,EAAC,SAAS,EAAqB,MAAM,gBAAgB,CAAC;AAC7D,cAAc,gBAAgB,CAAC;AA0J/B;;;;;;;;;;;;;;;;GAgBG;AACH,8BAAsB,cAAe,SAAQ,SAAS;IAMpD;;OAEG;IACH,WAAW,EAAG,OAAO,CAAC;IAItB;;;;;OAKG;IACM,YAAY,CACnB,IAAI,EAAE,IAAI,EACV,MAAM,EAAE,cAAc,EACtB,cAAc,EAAE,MAAM,GAAG,SAAS;IAqCpC;;;;;;;;;OASG;IACH,QAAQ,CAAC,KAAK,EAAE,OAAO;IAevB;;;;;OAKG;IACH,SAAS,CAAC,YAAY;IACtB,SAAS,CAAC,WAAW;CACtB"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/development/async-directive.js b/front_end/third_party/lit-html/package/development/async-directive.js
index 56820750ea01a0005ba099459f1fdb94043b211e..3cac674909c78c96ab5ebfbd31eb4771819dbc7c 100644
--- a/front_end/third_party/lit-html/package/development/async-directive.js
+++ b/front_end/third_party/lit-html/package/development/async-directive.js
@@ -5,6 +5,7 @@  * SPDX-License-Identifier: BSD-3-Clause
  */
 import { isSingleExpression } from './directive-helpers.js';
 import { Directive, PartType } from './directive.js';
+    if (children === undefined) {
 export { directive } from './directive.js';
 const DEV_MODE = true;
 /**




diff --git a/front_end/third_party/lit-html/package/development/async-directive.js.map b/front_end/third_party/lit-html/package/development/async-directive.js.map
index 310d0f34db90b8e0ed5c0bb23471d7a0568245ac..de206a57126a49cac27e2af3c5e7287463019f09 100644
--- a/front_end/third_party/lit-html/package/development/async-directive.js.map
+++ b/front_end/third_party/lit-html/package/development/async-directive.js.map
@@ -1 +1 @@
-{"version":3,"file":"async-directive.js","sourceRoot":"","sources":["../src/async-directive.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAqHH,OAAO,EAAC,kBAAkB,EAAC,MAAM,wBAAwB,CAAC;AAC1D,OAAO,EAAC,SAAS,EAAY,QAAQ,EAAC,MAAM,gBAAgB,CAAC;AAC7D,OAAO,EAAC,SAAS,EAAC,MAAM,gBAAgB,CAAC;AAEzC,MAAM,QAAQ,GAAG,IAAI,CAAC;AAEtB;;;;;;GAMG;AACH,MAAM,8BAA8B,GAAG,CACrC,MAAsB,EACtB,WAAoB,EACX,EAAE;;IACX,MAAM,QAAQ,GAAG,MAAM,CAAC,wBAAwB,CAAC;IACjD,IAAI,QAAQ,KAAK,SAAS,EAAE;QAC1B,OAAO,KAAK,CAAC;KACd;IACD,KAAK,MAAM,GAAG,IAAI,QAAQ,EAAE;QAC1B,gFAAgF;QAChF,iEAAiE;QACjE,yEAAyE;QACzE,yEAAyE;QACzE,2EAA2E;QAC3E,YAAY;QACZ,oEAAoE;QACpE,4CAA4C;QAC5C,MAAA,MAAC,GAAsB,EAAC,oCAAoC,CAAC,mDAC3D,WAAW,EACX,KAAK,CACN,CAAC;QACF,mCAAmC;QACnC,8BAA8B,CAAC,GAAG,EAAE,WAAW,CAAC,CAAC;KAClD;IACD,OAAO,IAAI,CAAC;AACd,CAAC,CAAC;AAEF;;;;;GAKG;AACH,MAAM,8BAA8B,GAAG,CAAC,GAAmB,EAAE,EAAE;IAC7D,IAAI,MAAM,EAAE,QAAQ,CAAC;I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;YACxE,SAAS,CAAC,IAAI,CAAC,gBAAiB,CAAC,GAAG,KAAK,CAAC;YACzC,IAAI,CAAC,MAAwB,CAAC,UAAU,CAAC,SAAS,EAAE,IAAI,EAAE,CAAC,CAAC,CAAC;SAC/D;IACH,CAAC;IAED;;;;;OAKG;IACO,YAAY,KAAI,CAAC;IACjB,WAAW,KAAI,CAAC;CAC3B","sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n/**\n * Overview:\n *\n * This module is designed to add support for an async `setValue` API and\n * `disconnected` callback to directives with the least impact on the core\n * runtime or payload when that feature is not used.\n *\n * The strategy is to introduce a `AsyncDirective` subclass of\n * `Directive` that climbs the \"parent\" tree in its constructor to note which\n * branches of lit-html's \"logical tree\" of data structures contain such\n * directives and thus need to be crawled when a subtree is being cleared (or\n * manually disconnected) in order to run the `disconnected` callback.\n *\n * The \"nodes\" of the logical tree include Parts, TemplateInstances (for when a\n * TemplateResult is committed to a value of a ChildPart), and Directives; these\n * all implement a common interface called `DisconnectableChild`. Each has a\n * `_$parent` reference which is set during construction in the core code, and a\n * `_$disconnectableChildren` field which is initially undefined.\n *\n * The sparse tree created by means of the `AsyncDirective` constructor\n * crawling up the `_$parent` tree and placing a `_$disconnectableChildren` Set\n * on each parent that includes each child that contains a\n * `AsyncDirective` directly or transitively via its children. In order to\n * notify connection state changes and disconnect (or reconnect) a tree, the\n * `_$notifyConnectionChanged` API is patched onto ChildParts as a directive\n * climbs the parent tree, which is called by the core when clearing a part if\n * it exists. When called, that method iterates over the sparse tree of\n * Set<DisconnectableChildren> built up by AsyncDirectives, and calls\n * `_$notifyDirectiveConnectionChanged` on any directives that are encountered\n * in that tree, running the required callbacks.\n *\n * A given \"logical tree\" of lit-html data-structures might look like this:\n *\n *  ChildPart(N1) _$dC=[D2,T3]\n *   ._directive\n *     AsyncDirective(D2)\n *   ._value // user value was TemplateResult\n *     TemplateInstance(T3) _$dC=[A4,A6,N10,N12]\n *      ._parts[]\n *        AttributePart(A4) _$dC=[D5]\n *         ._directives[]\n *           AsyncDirective(D5)\n *        AttributePart(A6) _$dC=[D7,D8]\n *         ._directives[]\n *           AsyncDirective(D7)\n *           Directive(D8) _$dC=[D9]\n *            ._directive\n *              AsyncDirective(D9)\n *        ChildPart(N10) _$dC=[D11]\n *         ._directive\n *           AsyncDirective(D11)\n *         ._value\n *           string\n *        ChildPart(N12) _$dC=[D13,N14,N16]\n *         ._directive\n *           AsyncDirective(D13)\n *         ._value // user value was iterable\n *           Array<ChildPart>\n *             ChildPart(N14) _$dC=[D15]\n *              ._value\n *                string\n *             ChildPart(N16) _$dC=[D17,T18]\n *              ._directive\n *                AsyncDirective(D17)\n *              ._value // user value was TemplateResult\n *                TemplateInstance(T18) _$dC=[A19,A21,N25]\n *                 ._parts[]\n *                   AttributePart(A19) _$dC=[D20]\n *                    ._directives[]\n *                      AsyncDirective(D20)\n *                   AttributePart(A21) _$dC=[22,23]\n *                    ._directives[]\n *                      AsyncDirective(D22)\n *                      Directive(D23) _$dC=[D24]\n *                       ._directive\n *                         AsyncDirective(D24)\n *                   ChildPart(N25) _$dC=[D26]\n *                    ._directive\n *                      AsyncDirective(D26)\n *                    ._value\n *                      string\n *\n * Example 1: The directive in ChildPart(N12) updates and returns `nothing`. The\n * ChildPart will _clear() itself, and so we need to disconnect the \"value\" of\n * the ChildPart (but not its directive). In this case, when `_clear()` calls\n * `_$notifyConnectionChanged()`, we don't iterate all of the\n * _$disconnectableChildren, rather we do a value-specific disconnection: i.e.\n * since the _value was an Array<ChildPart> (because an iterable had been\n * committed), we iterate the array of ChildParts (N14, N16) and run\n * `setConnected` on them (which does recurse down the full tree of\n * `_$disconnectableChildren` below it, and also removes N14 and N16 from N12's\n * `_$disconnectableChildren`). Once the values have been disconnected, we then\n * check whether the ChildPart(N12)'s list of `_$disconnectableChildren` is empty\n * (and would remove it from its parent TemplateInstance(T3) if so), but since\n * it would still contain its directive D13, it stays in the disconnectable\n * tree.\n *\n * Example 2: In the course of Example 1, `setConnected` will reach\n * ChildPart(N16); in this case the entire part is being disconnected, so we\n * simply iterate all of N16's `_$disconnectableChildren` (D17,T18) and\n * recursively run `setConnected` on them. Note that we only remove children\n * from `_$disconnectableChildren` for the top-level values being disconnected\n * on a clear; doing this bookkeeping lower in the tree is wasteful since it's\n * all being thrown away.\n *\n * Example 3: If the LitElement containing the entire tree above becomes\n * disconnected, it will run `childPart.setConnected()` (which calls\n * `childPart._$notifyConnectionChanged()` if it exists); in this case, we\n * recursively run `setConnected()` over the entire tree, without removing any\n * children from `_$disconnectableChildren`, since this tree is required to\n * re-connect the tree, which does the same operation, simply passing\n * `isConnected: true` down the tree, signaling which callback to run.\n */\n\nimport {AttributePart, ChildPart, Disconnectable, Part} from './lit-html.js';\nimport {isSingleExpression} from './directive-helpers.js';\nimport {Directive, PartInfo, PartType} from './directive.js';\nexport {directive} from './directive.js';\n\nconst DEV_MODE = true;\n\n/**\n * Recursively walks down the tree of Parts/TemplateInstances/Directives to set\n * the connected state of directives and run `disconnected`/ `reconnected`\n * callbacks.\n *\n * @return True if there were children to disconnect; false otherwise\n */\nconst notifyChildrenConnectedChanged = (\n  parent: Disconnectable,\n  isConnected: boolean\n): boolean => {\n  const children = parent._$disconnectableChildren;\n  if (children === undefined) {\n    return false;\n  }\n  for (const obj of children) {\n    // The existence of `_$notifyDirectiveConnectionChanged` is used as a \"brand\" to\n    // disambiguate AsyncDirectives from other DisconnectableChildren\n    // (as opposed to using an instanceof check to know when to call it); the\n    // redundancy of \"Directive\" in the API name is to avoid conflicting with\n    // `_$notifyConnectionChanged`, which exists `ChildParts` which are also in\n    // this list\n    // Disconnect Directive (and any nested directives contained within)\n    // This property needs to remain unminified.\n    (obj as AsyncDirective)['_$notifyDirectiveConnectionChanged']?.(\n      isConnected,\n      false\n    );\n    // Disconnect Part/TemplateInstance\n    notifyChildrenConnectedChanged(obj, isConnected);\n  }\n  return true;\n};\n\n/**\n * Removes the given child from its parent list of disconnectable children, and\n * if the parent list becomes empty as a result, removes the parent from its\n * parent, and so forth up the tree when that causes subsequent parent lists to\n * become empty.\n */\nconst removeDisconnectableFromParent = (obj: Disconnectable) => {\n  let parent, children;\n  do {\n    if ((parent = obj._$parent) === undefined) {\n      break;\n    }\n    children = parent._$disconnectableChildren!;\n    children.delete(obj);\n    obj = parent;\n  } while (children?.size === 0);\n};\n\nconst addDisconnectableToParent = (obj: Disconnectable) => {\n  // Climb the parent tree, creating a sparse tree of children needing\n  // disconnection\n  for (let parent; (parent = obj._$parent); obj = parent) {\n    let children = parent._$disconnectableChildren;\n    if (children === undefined) {\n      parent._$disconnectableChildren = children = new Set();\n    } else if (children.has(obj)) {\n      // Once we've reached a parent that already contains this child, we\n      // can short-circuit\n      break;\n    }\n    children.add(obj);\n    installDisconnectAPI(parent);\n  }\n};\n\n/**\n * Changes the parent reference of the ChildPart, and updates the sparse tree of\n * Disconnectable children accordingly.\n *\n * Note, this method will be patched onto ChildPart instances and called from\n * the core code when parts are moved between different parents.\n */\nfunction reparentDisconnectables(this: ChildPart, newParent: Disconnectable) {\n  if (this._$disconnectableChildren !== undefined) {\n    removeDisconnectableFromParent(this);\n    this._$parent = newParent;\n    addDisconnectableToParent(this);\n  } else {\n    this._$parent = newParent;\n  }\n}\n\n/**\n * Sets the connected state on any directives contained within the committed\n * value of this part (i.e. within a TemplateInstance or iterable of\n * ChildParts) and runs their `disconnected`/`reconnected`s, as well as within\n * any directives stored on the ChildPart (when `valueOnly` is false).\n *\n * `isClearingValue` should be passed as `true` on a top-level part that is\n * clearing itself, and not as a result of recursively disconnecting directives\n * as part of a `clear` operation higher up the tree. This both ensures that any\n * directive on this ChildPart that produced a value that caused the clear\n * operation is not disconnected, and also serves as a performance optimization\n * to avoid needless bookkeeping when a subtree is going away; when clearing a\n * subtree, only the top-most part need to remove itself from the parent.\n *\n * `fromPartIndex` is passed only in the case of a partial `_clear` running as a\n * result of truncating an iterable.\n *\n * Note, this method will be patched onto ChildPart instances and called from the\n * core code when parts are cleared or the connection state is changed by the\n * user.\n */\nfunction notifyChildPartConnectedChanged(\n  this: ChildPart,\n  isConnected: boolean,\n  isClearingValue = false,\n  fromPartIndex = 0\n) {\n  const value = this._$committedValue;\n  const children = this._$disconnectableChildren;\n  if (children === undefined || children.size === 0) {\n    return;\n  }\n  if (isClearingValue) {\n    if (Array.isArray(value)) {\n      // Iterable case: Any ChildParts created by the iterable should be\n      // disconnected and removed from this ChildPart's disconnectable\n      // children (starting at `fromPartIndex` in the case of truncation)\n      for (let i = fromPartIndex; i < value.length; i++) {\n        notifyChildrenConnectedChanged(value[i], false);\n        removeDisconnectableFromParent(value[i]);\n      }\n    } else if (value != null) {\n      // TemplateInstance case: If the value has disconnectable children (will\n      // only be in the case that it is a TemplateInstance), we disconnect it\n      // and remove it from this ChildPart's disconnectable children\n      notifyChildrenConnectedChanged(value as Disconnectable, false);\n      removeDisconnectableFromParent(value as Disconnectable);\n    }\n  } else {\n    notifyChildrenConnectedChanged(this, isConnected);\n  }\n}\n\n/**\n * Patches disconnection API onto ChildParts.\n */\nconst installDisconnectAPI = (obj: Disconnectable) => {\n  if ((obj as ChildPart).type == PartType.CHILD) {\n    (obj as ChildPart)._$notifyConnectionChanged ??=\n      notifyChildPartConnectedChanged;\n    (obj as ChildPart)._$reparentDisconnectables ??= reparentDisconnectables;\n  }\n};\n\n/**\n * An abstract `Directive` base class whose `disconnected` method will be\n * called when the part containing the directive is cleared as a result of\n * re-rendering, or when the user calls `part.setConnected(false)` on\n * a part that was previously rendered containing the directive (as happens\n * when e.g. a LitElement disconnects from the DOM).\n *\n * If `part.setConnected(true)` is subsequently called on a\n * containing part, the directive's `reconnected` method will be called prior\n * to its next `update`/`render` callbacks. When implementing `disconnected`,\n * `reconnected` should also be implemented to be compatible with reconnection.\n *\n * Note that updates may occur while the directive is disconnected. As such,\n * directives should generally check the `this.isConnected` flag during\n * render/update to determine whether it is safe to subscribe to resources\n * that may prevent garbage collection.\n */\nexport abstract class AsyncDirective extends Directive {\n  // As opposed to other Disconnectables, AsyncDirectives always get notified\n  // when the RootPart connection changes, so the public `isConnected`\n  // is a locally stored variable initialized via its part's getter and synced\n  // via `_$notifyDirectiveConnectionChanged`. This is cheaper than using\n  // the _$isConnected getter, which has to look back up the tree each time.\n  /**\n   * The connection state for this Directive.\n   */\n  isConnected!: boolean;\n\n  // @internal\n  override _$disconnectableChildren?: Set<Disconnectable> = undefined;\n  /**\n   * Initialize the part with internal fields\n   * @param part\n   * @param parent\n   * @param attributeIndex\n   */\n  override _$initialize(\n    part: Part,\n    parent: Disconnectable,\n    attributeIndex: number | undefined\n  ) {\n    super._$initialize(part, parent, attributeIndex);\n    addDisconnectableToParent(this);\n    this.isConnected = part._$isConnected;\n  }\n  // This property needs to remain unminified.\n  /**\n   * Called from the core code when a directive is going away from a part (in\n   * which case `shouldRemoveFromParent` should be true), and from the\n   * `setChildrenConnected` helper function when recursively changing the\n   * connection state of a tree (in which case `shouldRemoveFromParent` should\n   * be false).\n   *\n   * @param isConnected\n   * @param isClearingDirective - True when the directive itself is being\n   *     removed; false when the tree is being disconnected\n   * @internal\n   */\n  override ['_$notifyDirectiveConnectionChanged'](\n    isConnected: boolean,\n    isClearingDirective = true\n  ) {\n    if (isConnected !== this.isConnected) {\n      this.isConnected = isConnected;\n      if (isConnected) {\n        this.reconnected?.();\n      } else {\n        this.disconnected?.();\n      }\n    }\n    if (isClearingDirective) {\n      notifyChildrenConnectedChanged(this, isConnected);\n      removeDisconnectableFromParent(this);\n    }\n  }\n\n  /**\n   * Sets the value of the directive's Part outside the normal `update`/`render`\n   * lifecycle of a directive.\n   *\n   * This method should not be called synchronously from a directive's `update`\n   * or `render`.\n   *\n   * @param directive The directive to update\n   * @param value The value to set\n   */\n  setValue(value: unknown) {\n    if (isSingleExpression(this.__part as unknown as PartInfo)) {\n      this.__part._$setValue(value, this);\n    } else {\n      // this.__attributeIndex will be defined in this case, but\n      // assert it in dev mode\n      if (DEV_MODE && this.__attributeIndex === undefined) {\n        throw new Error(`Expected this.__attributeIndex to be a number`);\n      }\n      const newValues = [...(this.__part._$committedValue as Array<unknown>)];\n      newValues[this.__attributeIndex!] = value;\n      (this.__part as AttributePart)._$setValue(newValues, this, 0);\n    }\n  }\n\n  /**\n   * User callbacks for implementing logic to release any resources/subscriptions\n   * that may have been retained by this directive. Since directives may also be\n   * re-connected, `reconnected` should also be implemented to restore the\n   * working state of the directive prior to the next render.\n   */\n  protected disconnected() {}\n  protected reconnected() {}\n}\n"]}
\ No newline at end of file
+{"version":3,"file":"async-directive.js","sourceRoot":"","sources":["../src/async-directive.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAqHH,OAAO,EAAC,kBAAkB,EAAC,MAAM,wBAAwB,CAAC;AAC1D,OAAO,EAAC,SAAS,EAAY,QAAQ,EAAC,MAAM,gBAAgB,CAAC;AAC7D,cAAc,gBAAgB,CAAC;AAE/B,MAAM,QAAQ,GAAG,IAAI,CAAC;AAEtB;;;;;;GAMG;AACH,MAAM,8BAA8B,GAAG,CACrC,MAAsB,EACtB,WAAoB,EACX,EAAE;;IACX,MAAM,QAAQ,GAAG,MAAM,CAAC,wBAAwB,CAAC;IACjD,IAAI,QAAQ,KAAK,SAAS,EAAE;QAC1B,OAAO,KAAK,CAAC;KACd;IACD,KAAK,MAAM,GAAG,IAAI,QAAQ,EAAE;QAC1B,gFAAgF;QAChF,iEAAiE;QACjE,yEAAyE;QACzE,yEAAyE;QACzE,2EAA2E;QAC3E,YAAY;QACZ,oEAAoE;QACpE,4CAA4C;QAC5C,MAAA,MAAC,GAAsB,EAAC,oCAAoC,CAAC,mDAC3D,WAAW,EACX,KAAK,CACN,CAAC;QACF,mCAAmC;QACnC,8BAA8B,CAAC,GAAG,EAAE,WAAW,CAAC,CAAC;KAClD;IACD,OAAO,IAAI,CAAC;AACd,CAAC,CAAC;AAEF;;;;;GAKG;AACH,MAAM,8BAA8B,GAAG,CAAC,GAAmB,EAAE,EAAE;IAC7D,IAAI,MAAM,EAAE,QAAQ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AAI,CAAC,gBAAiB,CAAC,GAAG,KAAK,CAAC;YACzC,IAAI,CAAC,MAAwB,CAAC,UAAU,CAAC,SAAS,EAAE,IAAI,EAAE,CAAC,CAAC,CAAC;SAC/D;IACH,CAAC;IAED;;;;;OAKG;IACO,YAAY,KAAI,CAAC;IACjB,WAAW,KAAI,CAAC;CAC3B","sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n/**\n * Overview:\n *\n * This module is designed to add support for an async `setValue` API and\n * `disconnected` callback to directives with the least impact on the core\n * runtime or payload when that feature is not used.\n *\n * The strategy is to introduce a `AsyncDirective` subclass of\n * `Directive` that climbs the \"parent\" tree in its constructor to note which\n * branches of lit-html's \"logical tree\" of data structures contain such\n * directives and thus need to be crawled when a subtree is being cleared (or\n * manually disconnected) in order to run the `disconnected` callback.\n *\n * The \"nodes\" of the logical tree include Parts, TemplateInstances (for when a\n * TemplateResult is committed to a value of a ChildPart), and Directives; these\n * all implement a common interface called `DisconnectableChild`. Each has a\n * `_$parent` reference which is set during construction in the core code, and a\n * `_$disconnectableChildren` field which is initially undefined.\n *\n * The sparse tree created by means of the `AsyncDirective` constructor\n * crawling up the `_$parent` tree and placing a `_$disconnectableChildren` Set\n * on each parent that includes each child that contains a\n * `AsyncDirective` directly or transitively via its children. In order to\n * notify connection state changes and disconnect (or reconnect) a tree, the\n * `_$notifyConnectionChanged` API is patched onto ChildParts as a directive\n * climbs the parent tree, which is called by the core when clearing a part if\n * it exists. When called, that method iterates over the sparse tree of\n * Set<DisconnectableChildren> built up by AsyncDirectives, and calls\n * `_$notifyDirectiveConnectionChanged` on any directives that are encountered\n * in that tree, running the required callbacks.\n *\n * A given \"logical tree\" of lit-html data-structures might look like this:\n *\n *  ChildPart(N1) _$dC=[D2,T3]\n *   ._directive\n *     AsyncDirective(D2)\n *   ._value // user value was TemplateResult\n *     TemplateInstance(T3) _$dC=[A4,A6,N10,N12]\n *      ._parts[]\n *        AttributePart(A4) _$dC=[D5]\n *         ._directives[]\n *           AsyncDirective(D5)\n *        AttributePart(A6) _$dC=[D7,D8]\n *         ._directives[]\n *           AsyncDirective(D7)\n *           Directive(D8) _$dC=[D9]\n *            ._directive\n *              AsyncDirective(D9)\n *        ChildPart(N10) _$dC=[D11]\n *         ._directive\n *           AsyncDirective(D11)\n *         ._value\n *           string\n *        ChildPart(N12) _$dC=[D13,N14,N16]\n *         ._directive\n *           AsyncDirective(D13)\n *         ._value // user value was iterable\n *           Array<ChildPart>\n *             ChildPart(N14) _$dC=[D15]\n *              ._value\n *                string\n *             ChildPart(N16) _$dC=[D17,T18]\n *              ._directive\n *                AsyncDirective(D17)\n *              ._value // user value was TemplateResult\n *                TemplateInstance(T18) _$dC=[A19,A21,N25]\n *                 ._parts[]\n *                   AttributePart(A19) _$dC=[D20]\n *                    ._directives[]\n *                      AsyncDirective(D20)\n *                   AttributePart(A21) _$dC=[22,23]\n *                    ._directives[]\n *                      AsyncDirective(D22)\n *                      Directive(D23) _$dC=[D24]\n *                       ._directive\n *                         AsyncDirective(D24)\n *                   ChildPart(N25) _$dC=[D26]\n *                    ._directive\n *                      AsyncDirective(D26)\n *                    ._value\n *                      string\n *\n * Example 1: The directive in ChildPart(N12) updates and returns `nothing`. The\n * ChildPart will _clear() itself, and so we need to disconnect the \"value\" of\n * the ChildPart (but not its directive). In this case, when `_clear()` calls\n * `_$notifyConnectionChanged()`, we don't iterate all of the\n * _$disconnectableChildren, rather we do a value-specific disconnection: i.e.\n * since the _value was an Array<ChildPart> (because an iterable had been\n * committed), we iterate the array of ChildParts (N14, N16) and run\n * `setConnected` on them (which does recurse down the full tree of\n * `_$disconnectableChildren` below it, and also removes N14 and N16 from N12's\n * `_$disconnectableChildren`). Once the values have been disconnected, we then\n * check whether the ChildPart(N12)'s list of `_$disconnectableChildren` is empty\n * (and would remove it from its parent TemplateInstance(T3) if so), but since\n * it would still contain its directive D13, it stays in the disconnectable\n * tree.\n *\n * Example 2: In the course of Example 1, `setConnected` will reach\n * ChildPart(N16); in this case the entire part is being disconnected, so we\n * simply iterate all of N16's `_$disconnectableChildren` (D17,T18) and\n * recursively run `setConnected` on them. Note that we only remove children\n * from `_$disconnectableChildren` for the top-level values being disconnected\n * on a clear; doing this bookkeeping lower in the tree is wasteful since it's\n * all being thrown away.\n *\n * Example 3: If the LitElement containing the entire tree above becomes\n * disconnected, it will run `childPart.setConnected()` (which calls\n * `childPart._$notifyConnectionChanged()` if it exists); in this case, we\n * recursively run `setConnected()` over the entire tree, without removing any\n * children from `_$disconnectableChildren`, since this tree is required to\n * re-connect the tree, which does the same operation, simply passing\n * `isConnected: true` down the tree, signaling which callback to run.\n */\n\nimport {AttributePart, ChildPart, Disconnectable, Part} from './lit-html.js';\nimport {isSingleExpression} from './directive-helpers.js';\nimport {Directive, PartInfo, PartType} from './directive.js';\nexport * from './directive.js';\n\nconst DEV_MODE = true;\n\n/**\n * Recursively walks down the tree of Parts/TemplateInstances/Directives to set\n * the connected state of directives and run `disconnected`/ `reconnected`\n * callbacks.\n *\n * @return True if there were children to disconnect; false otherwise\n */\nconst notifyChildrenConnectedChanged = (\n  parent: Disconnectable,\n  isConnected: boolean\n): boolean => {\n  const children = parent._$disconnectableChildren;\n  if (children === undefined) {\n    return false;\n  }\n  for (const obj of children) {\n    // The existence of `_$notifyDirectiveConnectionChanged` is used as a \"brand\" to\n    // disambiguate AsyncDirectives from other DisconnectableChildren\n    // (as opposed to using an instanceof check to know when to call it); the\n    // redundancy of \"Directive\" in the API name is to avoid conflicting with\n    // `_$notifyConnectionChanged`, which exists `ChildParts` which are also in\n    // this list\n    // Disconnect Directive (and any nested directives contained within)\n    // This property needs to remain unminified.\n    (obj as AsyncDirective)['_$notifyDirectiveConnectionChanged']?.(\n      isConnected,\n      false\n    );\n    // Disconnect Part/TemplateInstance\n    notifyChildrenConnectedChanged(obj, isConnected);\n  }\n  return true;\n};\n\n/**\n * Removes the given child from its parent list of disconnectable children, and\n * if the parent list becomes empty as a result, removes the parent from its\n * parent, and so forth up the tree when that causes subsequent parent lists to\n * become empty.\n */\nconst removeDisconnectableFromParent = (obj: Disconnectable) => {\n  let parent, children;\n  do {\n    if ((parent = obj._$parent) === undefined) {\n      break;\n    }\n    children = parent._$disconnectableChildren!;\n    children.delete(obj);\n    obj = parent;\n  } while (children?.size === 0);\n};\n\nconst addDisconnectableToParent = (obj: Disconnectable) => {\n  // Climb the parent tree, creating a sparse tree of children needing\n  // disconnection\n  for (let parent; (parent = obj._$parent); obj = parent) {\n    let children = parent._$disconnectableChildren;\n    if (children === undefined) {\n      parent._$disconnectableChildren = children = new Set();\n    } else if (children.has(obj)) {\n      // Once we've reached a parent that already contains this child, we\n      // can short-circuit\n      break;\n    }\n    children.add(obj);\n    installDisconnectAPI(parent);\n  }\n};\n\n/**\n * Changes the parent reference of the ChildPart, and updates the sparse tree of\n * Disconnectable children accordingly.\n *\n * Note, this method will be patched onto ChildPart instances and called from\n * the core code when parts are moved between different parents.\n */\nfunction reparentDisconnectables(this: ChildPart, newParent: Disconnectable) {\n  if (this._$disconnectableChildren !== undefined) {\n    removeDisconnectableFromParent(this);\n    this._$parent = newParent;\n    addDisconnectableToParent(this);\n  } else {\n    this._$parent = newParent;\n  }\n}\n\n/**\n * Sets the connected state on any directives contained within the committed\n * value of this part (i.e. within a TemplateInstance or iterable of\n * ChildParts) and runs their `disconnected`/`reconnected`s, as well as within\n * any directives stored on the ChildPart (when `valueOnly` is false).\n *\n * `isClearingValue` should be passed as `true` on a top-level part that is\n * clearing itself, and not as a result of recursively disconnecting directives\n * as part of a `clear` operation higher up the tree. This both ensures that any\n * directive on this ChildPart that produced a value that caused the clear\n * operation is not disconnected, and also serves as a performance optimization\n * to avoid needless bookkeeping when a subtree is going away; when clearing a\n * subtree, only the top-most part need to remove itself from the parent.\n *\n * `fromPartIndex` is passed only in the case of a partial `_clear` running as a\n * result of truncating an iterable.\n *\n * Note, this method will be patched onto ChildPart instances and called from the\n * core code when parts are cleared or the connection state is changed by the\n * user.\n */\nfunction notifyChildPartConnectedChanged(\n  this: ChildPart,\n  isConnected: boolean,\n  isClearingValue = false,\n  fromPartIndex = 0\n) {\n  const value = this._$committedValue;\n  const children = this._$disconnectableChildren;\n  if (children === undefined || children.size === 0) {\n    return;\n  }\n  if (isClearingValue) {\n    if (Array.isArray(value)) {\n      // Iterable case: Any ChildParts created by the iterable should be\n      // disconnected and removed from this ChildPart's disconnectable\n      // children (starting at `fromPartIndex` in the case of truncation)\n      for (let i = fromPartIndex; i < value.length; i++) {\n        notifyChildrenConnectedChanged(value[i], false);\n        removeDisconnectableFromParent(value[i]);\n      }\n    } else if (value != null) {\n      // TemplateInstance case: If the value has disconnectable children (will\n      // only be in the case that it is a TemplateInstance), we disconnect it\n      // and remove it from this ChildPart's disconnectable children\n      notifyChildrenConnectedChanged(value as Disconnectable, false);\n      removeDisconnectableFromParent(value as Disconnectable);\n    }\n  } else {\n    notifyChildrenConnectedChanged(this, isConnected);\n  }\n}\n\n/**\n * Patches disconnection API onto ChildParts.\n */\nconst installDisconnectAPI = (obj: Disconnectable) => {\n  if ((obj as ChildPart).type == PartType.CHILD) {\n    (obj as ChildPart)._$notifyConnectionChanged ??=\n      notifyChildPartConnectedChanged;\n    (obj as ChildPart)._$reparentDisconnectables ??= reparentDisconnectables;\n  }\n};\n\n/**\n * An abstract `Directive` base class whose `disconnected` method will be\n * called when the part containing the directive is cleared as a result of\n * re-rendering, or when the user calls `part.setConnected(false)` on\n * a part that was previously rendered containing the directive (as happens\n * when e.g. a LitElement disconnects from the DOM).\n *\n * If `part.setConnected(true)` is subsequently called on a\n * containing part, the directive's `reconnected` method will be called prior\n * to its next `update`/`render` callbacks. When implementing `disconnected`,\n * `reconnected` should also be implemented to be compatible with reconnection.\n *\n * Note that updates may occur while the directive is disconnected. As such,\n * directives should generally check the `this.isConnected` flag during\n * render/update to determine whether it is safe to subscribe to resources\n * that may prevent garbage collection.\n */\nexport abstract class AsyncDirective extends Directive {\n  // As opposed to other Disconnectables, AsyncDirectives always get notified\n  // when the RootPart connection changes, so the public `isConnected`\n  // is a locally stored variable initialized via its part's getter and synced\n  // via `_$notifyDirectiveConnectionChanged`. This is cheaper than using\n  // the _$isConnected getter, which has to look back up the tree each time.\n  /**\n   * The connection state for this Directive.\n   */\n  isConnected!: boolean;\n\n  // @internal\n  override _$disconnectableChildren?: Set<Disconnectable> = undefined;\n  /**\n   * Initialize the part with internal fields\n   * @param part\n   * @param parent\n   * @param attributeIndex\n   */\n  override _$initialize(\n    part: Part,\n    parent: Disconnectable,\n    attributeIndex: number | undefined\n  ) {\n    super._$initialize(part, parent, attributeIndex);\n    addDisconnectableToParent(this);\n    this.isConnected = part._$isConnected;\n  }\n  // This property needs to remain unminified.\n  /**\n   * Called from the core code when a directive is going away from a part (in\n   * which case `shouldRemoveFromParent` should be true), and from the\n   * `setChildrenConnected` helper function when recursively changing the\n   * connection state of a tree (in which case `shouldRemoveFromParent` should\n   * be false).\n   *\n   * @param isConnected\n   * @param isClearingDirective - True when the directive itself is being\n   *     removed; false when the tree is being disconnected\n   * @internal\n   */\n  override ['_$notifyDirectiveConnectionChanged'](\n    isConnected: boolean,\n    isClearingDirective = true\n  ) {\n    if (isConnected !== this.isConnected) {\n      this.isConnected = isConnected;\n      if (isConnected) {\n        this.reconnected?.();\n      } else {\n        this.disconnected?.();\n      }\n    }\n    if (isClearingDirective) {\n      notifyChildrenConnectedChanged(this, isConnected);\n      removeDisconnectableFromParent(this);\n    }\n  }\n\n  /**\n   * Sets the value of the directive's Part outside the normal `update`/`render`\n   * lifecycle of a directive.\n   *\n   * This method should not be called synchronously from a directive's `update`\n   * or `render`.\n   *\n   * @param directive The directive to update\n   * @param value The value to set\n   */\n  setValue(value: unknown) {\n    if (isSingleExpression(this.__part as unknown as PartInfo)) {\n      this.__part._$setValue(value, this);\n    } else {\n      // this.__attributeIndex will be defined in this case, but\n      // assert it in dev mode\n      if (DEV_MODE && this.__attributeIndex === undefined) {\n        throw new Error(`Expected this.__attributeIndex to be a number`);\n      }\n      const newValues = [...(this.__part._$committedValue as Array<unknown>)];\n      newValues[this.__attributeIndex!] = value;\n      (this.__part as AttributePart)._$setValue(newValues, this, 0);\n    }\n  }\n\n  /**\n   * User callbacks for implementing logic to release any resources/subscriptions\n   * that may have been retained by this directive. Since directives may also be\n   * re-connected, `reconnected` should also be implemented to restore the\n   * working state of the directive prior to the next render.\n   */\n  protected disconnected() {}\n  protected reconnected() {}\n}\n"]}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/development/directive-helpers.d.ts b/front_end/third_party/lit-html/package/development/directive-helpers.d.ts
index 8b633940b82e38fbf14c663bd099e57cea186c80..300a0eb693eeced333744bf55af4796a52b03ceb 100644
--- a/front_end/third_party/lit-html/package/development/directive-helpers.d.ts
+++ b/front_end/third_party/lit-html/package/development/directive-helpers.d.ts
@@ -20,7 +20,7 @@ export declare type TemplateResultType = typeof TemplateResultType[keyof typeof TemplateResultType];
 /**
  * Tests if a value is a TemplateResult.
  */
-export declare const isTemplateResult: (value: unknown, type?: TemplateResultType | undefined) => value is TemplateResult<1 | 2>;
+export declare const isTemplateResult: (value: unknown, type?: TemplateResultType) => value is TemplateResult<1 | 2>;
 /**
  * Tests if a value is a DirectiveResult.
  */




diff --git a/front_end/third_party/lit-html/package/development/directive-helpers.d.ts.map b/front_end/third_party/lit-html/package/development/directive-helpers.d.ts.map
index eabd5ba2dffb495f35fee4140132e032cc0fc4a1..995ce2c39a686cb065adf7c6db0844ef2678852a 100644
--- a/front_end/third_party/lit-html/package/development/directive-helpers.d.ts.map
+++ b/front_end/third_party/lit-html/package/development/directive-helpers.d.ts.map
@@ -1 +1 @@
-{"version":3,"file":"directive-helpers.d.ts","sourceRoot":"","sources":["../src/directive-helpers.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAO,IAAI,EAAE,eAAe,EAAE,cAAc,EAAC,MAAM,eAAe,CAAC;AAC1E,OAAO,EACL,eAAe,EACf,cAAc,EACd,QAAQ,EAET,MAAM,gBAAgB,CAAC;AACxB,aAAK,SAAS,GAAG,IAAI,GAAG,SAAS,GAAG,OAAO,GAAG,MAAM,GAAG,MAAM,GAAG,MAAM,GAAG,MAAM,CAAC;AAehF;;;;GAIG;AACH,eAAO,MAAM,WAAW,UAAW,OAAO,uBACkC,CAAC;AAE7E,eAAO,MAAM,kBAAkB;;;CAGrB,CAAC;AAEX,oBAAY,kBAAkB,GAC5B,OAAO,kBAAkB,CAAC,MAAM,OAAO,kBAAkB,CAAC,CAAC;AAE7D;;GAEG;AACH,eAAO,MAAM,gBAAgB,UACpB,OAAO,0EAMwC,CAAC;AAEzD;;GAEG;AACH,eAAO,MAAM,iBAAiB,UAAW,OAAO,6CAEe,CAAC;AAEhE;;GAEG;AACH,eAAO,MAAM,iBAAiB,UAAW,OAAO,KAAG,cAAc,GAAG,SAEnB,CAAC;AAElD;;;;;;;GAOG;AACH,eAAO,MAAM,kBAAkB,SAAU,QAAQ,YACE,CAAC;AAIpD;;;;;;;;;;;GAWG;AACH,eAAO,MAAM,UAAU,wMAqDtB,CAAC;AAEF;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,iBAAiB,gEAErB,OAAO,oBACG,eAAe,MAIjC,CAAC;AAMF;;;;;;;;;;GAUG;AACH,eAAO,MAAM,iBAAiB,SAAU,IAAI,UAAS,OAAO,YAC3B,CAAC;AAElC;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,iBAAiB,sDAA6C,CAAC;AAE5E;;;;GAIG;AACH,eAAO,MAAM,UAAU,mDAStB,CAAC;AAEF,eAAO,MAAM,SAAS,mDAErB,CAAC"}
\ No newline at end of file
+{"version":3,"file":"directive-helpers.d.ts","sourceRoot":"","sources":["../src/directive-helpers.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAO,IAAI,EAAE,eAAe,EAAE,cAAc,EAAC,MAAM,eAAe,CAAC;AAC1E,OAAO,EACL,eAAe,EACf,cAAc,EACd,QAAQ,EAET,MAAM,gBAAgB,CAAC;AACxB,aAAK,SAAS,GAAG,IAAI,GAAG,SAAS,GAAG,OAAO,GAAG,MAAM,GAAG,MAAM,GAAG,MAAM,GAAG,MAAM,CAAC;AAehF;;;;GAIG;AACH,eAAO,MAAM,WAAW,UAAW,OAAO,uBACkC,CAAC;AAE7E,eAAO,MAAM,kBAAkB;;;CAGrB,CAAC;AAEX,oBAAY,kBAAkB,GAC5B,OAAO,kBAAkB,CAAC,MAAM,OAAO,kBAAkB,CAAC,CAAC;AAE7D;;GAEG;AACH,eAAO,MAAM,gBAAgB,UACpB,OAAO,SACP,kBAAkB,mCAK6B,CAAC;AAEzD;;GAEG;AACH,eAAO,MAAM,iBAAiB,UAAW,OAAO,6CAEe,CAAC;AAEhE;;GAEG;AACH,eAAO,MAAM,iBAAiB,UAAW,OAAO,KAAG,cAAc,GAAG,SAEnB,CAAC;AAElD;;;;;;;GAOG;AACH,eAAO,MAAM,kBAAkB,SAAU,QAAQ,YACE,CAAC;AAIpD;;;;;;;;;;;GAWG;AACH,eAAO,MAAM,UAAU,wMAqDtB,CAAC;AAEF;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,iBAAiB,gEAErB,OAAO,oBACG,eAAe,MAIjC,CAAC;AAMF;;;;;;;;;;GAUG;AACH,eAAO,MAAM,iBAAiB,SAAU,IAAI,UAAS,OAAO,YAC3B,CAAC;AAElC;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,iBAAiB,sDAA6C,CAAC;AAE5E;;;;GAIG;AACH,eAAO,MAAM,UAAU,mDAStB,CAAC;AAEF,eAAO,MAAM,SAAS,mDAErB,CAAC"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/development/directive-helpers.js b/front_end/third_party/lit-html/package/development/directive-helpers.js
index 02877fc971f09e8a54dcc691f878ceac028f702b..145fdd838cb66b58697b7d6f146349562f385611 100644
--- a/front_end/third_party/lit-html/package/development/directive-helpers.js
+++ b/front_end/third_party/lit-html/package/development/directive-helpers.js
@@ -25,30 +25,28 @@ };
 /**
  * Tests if a value is a TemplateResult.
  */
-export const isTemplateResult = (value, type) => {
- * @license
+    ? window.ShadyDOM.wrap
  */
- * @license
+    ? window.ShadyDOM.wrap
 var _a, _b;
- * @license
+    ? window.ShadyDOM.wrap
 import { _$LH } from './lit-html.js';
- * @license
+    ? window.ShadyDOM.wrap
 const { _ChildPart: ChildPart } = _$LH;
-        : ((_b = value) === null || _b === void 0 ? void 0 : _b['_$litType$']) === type;
-};
 /**
  * Tests if a value is a DirectiveResult.
  */
+/**
  * Copyright 2020 Google LLC
-/**
+const ENABLE_SHADYDOM_NOPATCH = true;
 // This property needs to remain unminified.
-return ((_a = value) === null || _a === void 0 ? void 0 : _a['_$litDirective$']) !== undefined; };
+(value === null || value === void 0 ? void 0 : value['_$litDirective$']) !== undefined;
 /**
  * Retrieves the Directive class for a DirectiveResult
  */
-export const getDirectiveClass = (value) => { var _a; 
+export const getDirectiveClass = (value) => 
 // This property needs to remain unminified.
-return (_a = value) === null || _a === void 0 ? void 0 : _a['_$litDirective$']; };
+value === null || value === void 0 ? void 0 : value['_$litDirective$'];
 /**
  * Tests whether a part has only a single-expression with no strings to
  * interpolate between.




diff --git a/front_end/third_party/lit-html/package/development/directive-helpers.js.map b/front_end/third_party/lit-html/package/development/directive-helpers.js.map
index f4ce3f15f531a0c6d8e778d53b12e9eb70cfb17b..7962f933fb18f8f3229d4dfe58017aa05ed0ac30 100644
--- a/front_end/third_party/lit-html/package/development/directive-helpers.js.map
+++ b/front_end/third_party/lit-html/package/development/directive-helpers.js.map
@@ -1 +1 @@
-{"version":3,"file":"directive-helpers.js","sourceRoot":"","sources":["../src/directive-helpers.ts"],"names":[],"mappings":"AAAA;;;;GAIG;;AAEH,OAAO,EAAC,IAAI,EAAwC,MAAM,eAAe,CAAC;AAS1E,MAAM,EAAC,UAAU,EAAE,SAAS,EAAC,GAAG,IAAI,CAAC;AAIrC,MAAM,uBAAuB,GAAG,IAAI,CAAC;AAErC,MAAM,IA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AyB,+CAA9B,IAAI,EAA6B,KAAK,EAAE,IAAI,CAAC,CAAC;IAC9C,IAAI,KAAK,GAAqB,IAAI,CAAC,WAAW,CAAC;IAC/C,MAAM,GAAG,GAAqB,IAAI,CAAC,IAAI,CAAC,SAAU,CAAC,CAAC,WAAW,CAAC;IAChE,OAAO,KAAK,KAAK,GAAG,EAAE;QACpB,MAAM,CAAC,GAAqB,IAAI,CAAC,KAAM,CAAC,CAAC,WAAW,CAAC;QACpD,IAAI,CAAC,KAAM,CAAe,CAAC,MAAM,EAAE,CAAC;QACrC,KAAK,GAAG,CAAC,CAAC;KACX;AACH,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,SAAS,GAAG,CAAC,IAAe,EAAE,EAAE;IAC3C,IAAI,CAAC,OAAO,EAAE,CAAC;AACjB,CAAC,CAAC","sourcesContent":["/**\n * @license\n * Copyright 2020 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {_$LH, Part, DirectiveParent, TemplateResult} from './lit-html.js';\nimport {\n  DirectiveResult,\n  DirectiveClass,\n  PartInfo,\n  AttributePartInfo,\n} from './directive.js';\ntype Primitive = null | undefined | boolean | number | string | symbol | bigint;\n\nconst {_ChildPart: ChildPart} = _$LH;\n\ntype ChildPart = InstanceType<typeof ChildPart>;\n\nconst ENABLE_SHADYDOM_NOPATCH = true;\n\nconst wrap =\n  ENABLE_SHADYDOM_NOPATCH &&\n  window.ShadyDOM?.inUse &&\n  window.ShadyDOM?.noPatch === true\n    ? window.ShadyDOM!.wrap\n    : (node: Node) => node;\n\n/**\n * Tests if a value is a primitive value.\n *\n * See https://tc39.github.io/ecma262/#sec-typeof-operator\n */\nexport const isPrimitive = (value: unknown): value is Primitive =>\n  value === null || (typeof value != 'object' && typeof value != 'function');\n\nexport const TemplateResultType = {\n  HTML: 1,\n  SVG: 2,\n} as const;\n\nexport type TemplateResultType =\n  typeof TemplateResultType[keyof typeof TemplateResultType];\n\n/**\n * Tests if a value is a TemplateResult.\n */\nexport const isTemplateResult = (\n  value: unknown,\n  type?: TemplateResultType\n): value is TemplateResult =>\n  type === undefined\n    ? // This property needs to remain unminified.\n      (value as TemplateResult)?.['_$litType$'] !== undefined\n    : (value as TemplateResult)?.['_$litType$'] === type;\n\n/**\n * Tests if a value is a DirectiveResult.\n */\nexport const isDirectiveResult = (value: unknown): value is DirectiveResult =>\n  // This property needs to remain unminified.\n  (value as DirectiveResult)?.['_$litDirective$'] !== undefined;\n\n/**\n * Retrieves the Directive class for a DirectiveResult\n */\nexport const getDirectiveClass = (value: unknown): DirectiveClass | undefined =>\n  // This property needs to remain unminified.\n  (value as DirectiveResult)?.['_$litDirective$'];\n\n/**\n * Tests whether a part has only a single-expression with no strings to\n * interpolate between.\n *\n * Only AttributePart and PropertyPart can have multiple expressions.\n * Multi-expression parts have a `strings` property and single-expression\n * parts do not.\n */\nexport const isSingleExpression = (part: PartInfo) =>\n  (part as AttributePartInfo).strings === undefined;\n\nconst createMarker = () => document.createComment('');\n\n/**\n * Inserts a ChildPart into the given container ChildPart's DOM, either at the\n * end of the container ChildPart, or before the optional `refPart`.\n *\n * This does not add the part to the containerPart's committed value. That must\n * be done by callers.\n *\n * @param containerPart Part within which to add the new ChildPart\n * @param refPart Part before which to add the new ChildPart; when omitted the\n *     part added to the end of the `containerPart`\n * @param part Part to insert, or undefined to create a new part\n */\nexport const insertPart = (\n  containerPart: ChildPart,\n  refPart?: ChildPart,\n  part?: ChildPart\n): ChildPart => {\n  const container = wrap(containerPart._$startNode).parentNode!;\n\n  const refNode =\n    refPart === undefined ? containerPart._$endNode : refPart._$startNode;\n\n  if (part === undefined) {\n    const startNode = wrap(container).insertBefore(createMarker(), refNode);\n    const endNode = wrap(container).insertBefore(createMarker(), refNode);\n    part = new ChildPart(\n      startNode,\n      endNode,\n      containerPart,\n      containerPart.options\n    );\n  } else {\n    const endNode = wrap(part._$endNode!).nextSibling;\n    const oldParent = part._$parent;\n    const parentChanged = oldParent !== containerPart;\n    if (parentChanged) {\n      part._$reparentDisconnectables?.(containerPart);\n      // Note that although `_$reparentDisconnectables` updates the part's\n      // `_$parent` reference after unlinking from its current parent, that\n      // method only exists if Disconnectables are present, so we need to\n      // unconditionally set it here\n      part._$parent = containerPart;\n      // Since the _$isConnected getter is somewhat costly, only\n      // read it once we know the subtree has directives that need\n      // to be notified\n      let newConnectionState;\n      if (\n        part._$notifyConnectionChanged !== undefined &&\n        (newConnectionState = containerPart._$isConnected) !==\n          oldParent!._$isConnected\n      ) {\n        part._$notifyConnectionChanged(newConnectionState);\n      }\n    }\n    if (endNode !== refNode || parentChanged) {\n      let start: Node | null = part._$startNode;\n      while (start !== endNode) {\n        const n: Node | null = wrap(start!).nextSibling;\n        wrap(container).insertBefore(start!, refNode);\n        start = n;\n      }\n    }\n  }\n\n  return part;\n};\n\n/**\n * Sets the value of a Part.\n *\n * Note that this should only be used to set/update the value of user-created\n * parts (i.e. those created using `insertPart`); it should not be used\n * by directives to set the value of the directive's container part. Directives\n * should return a value from `update`/`render` to update their part state.\n *\n * For directives that require setting their part value asynchronously, they\n * should extend `AsyncDirective` and call `this.setValue()`.\n *\n * @param part Part to set\n * @param value Value to set\n * @param index For `AttributePart`s, the index to set\n * @param directiveParent Used internally; should not be set by user\n */\nexport const setChildPartValue = <T extends ChildPart>(\n  part: T,\n  value: unknown,\n  directiveParent: DirectiveParent = part\n): T => {\n  part._$setValue(value, directiveParent);\n  return part;\n};\n\n// A sentinal value that can never appear as a part value except when set by\n// live(). Used to force a dirty-check to fail and cause a re-render.\nconst RESET_VALUE = {};\n\n/**\n * Sets the committed value of a ChildPart directly without triggering the\n * commit stage of the part.\n *\n * This is useful in cases where a directive needs to update the part such\n * that the next update detects a value change or not. When value is omitted,\n * the next update will be guaranteed to be detected as a change.\n *\n * @param part\n * @param value\n */\nexport const setCommittedValue = (part: Part, value: unknown = RESET_VALUE) =>\n  (part._$committedValue = value);\n\n/**\n * Returns the committed value of a ChildPart.\n *\n * The committed value is used for change detection and efficient updates of\n * the part. It can differ from the value set by the template or directive in\n * cases where the template value is transformed before being commited.\n *\n * - `TemplateResult`s are committed as a `TemplateInstance`\n * - Iterables are committed as `Array<ChildPart>`\n * - All other types are committed as the template value or value returned or\n *   set by a directive.\n *\n * @param part\n */\nexport const getCommittedValue = (part: ChildPart) => part._$committedValue;\n\n/**\n * Removes a ChildPart from the DOM, including any of its content.\n *\n * @param part The Part to remove\n */\nexport const removePart = (part: ChildPart) => {\n  part._$notifyConnectionChanged?.(false, true);\n  let start: ChildNode | null = part._$startNode;\n  const end: ChildNode | null = wrap(part._$endNode!).nextSibling;\n  while (start !== end) {\n    const n: ChildNode | null = wrap(start!).nextSibling;\n    (wrap(start!) as ChildNode).remove();\n    start = n;\n  }\n};\n\nexport const clearPart = (part: ChildPart) => {\n  part._$clear();\n};\n"]}
\ No newline at end of file
+{"version":3,"file":"directive-helpers.js","sourceRoot":"","sources":["../src/directive-helpers.ts"],"names":[],"mappings":"AAAA;;;;GAIG;;AAEH,OAAO,EAAC,IAAI,EAAwC,MAAM,eAAe,CAAC;AAS1E,MAAM,EAAC,UAAU,EAAE,SAAS,EAAC,GAAG,IAAI,CAAC;AAIrC,MAAM,uBAAuB,GAAG,IAAI,CAAC;AAErC,MAAM,IAAI,GACR,uBAAuB;KACvB,MAAA,MAAM,CAAC,QAAQ,0CAAE,KAAK,CAAA;IACtB,CAAA,MAAA,MAAM,CAAC,QAAQ,0CAAE,OAAO,MAAK,IAAI;IAC/B,CAAC,CAAC,MAAM,CAAC,QAAS,CAAC,IAAI;IACvB,CAAC,CAAC,CAAC,IAAU,EAAE,EAAE,CAAC,IAAI,CAAC;AAE3B;;;;GAIG;AACH,MAAM,CAAC,MAAM,WAAW,GAAG,CAAC,KAAc,EAAsB,EAAE,CAChE,KAAK,KAAK,IAAI,IAAI,CAAC,OAAO,KAAK,IAAI,QAAQ,IAAI,OAAO,KAAK,IAAI,UAAU,CAAC,CAAC;AAE7E,MAAM,CAAC,MAAM,kBAAkB,GAAG;IAChC,I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,CAAC,OAAO,EAAE,CAAC;AACjB,CAAC,CAAC","sourcesContent":["/**\n * @license\n * Copyright 2020 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {_$LH, Part, DirectiveParent, TemplateResult} from './lit-html.js';\nimport {\n  DirectiveResult,\n  DirectiveClass,\n  PartInfo,\n  AttributePartInfo,\n} from './directive.js';\ntype Primitive = null | undefined | boolean | number | string | symbol | bigint;\n\nconst {_ChildPart: ChildPart} = _$LH;\n\ntype ChildPart = InstanceType<typeof ChildPart>;\n\nconst ENABLE_SHADYDOM_NOPATCH = true;\n\nconst wrap =\n  ENABLE_SHADYDOM_NOPATCH &&\n  window.ShadyDOM?.inUse &&\n  window.ShadyDOM?.noPatch === true\n    ? window.ShadyDOM!.wrap\n    : (node: Node) => node;\n\n/**\n * Tests if a value is a primitive value.\n *\n * See https://tc39.github.io/ecma262/#sec-typeof-operator\n */\nexport const isPrimitive = (value: unknown): value is Primitive =>\n  value === null || (typeof value != 'object' && typeof value != 'function');\n\nexport const TemplateResultType = {\n  HTML: 1,\n  SVG: 2,\n} as const;\n\nexport type TemplateResultType =\n  typeof TemplateResultType[keyof typeof TemplateResultType];\n\n/**\n * Tests if a value is a TemplateResult.\n */\nexport const isTemplateResult = (\n  value: unknown,\n  type?: TemplateResultType\n): value is TemplateResult =>\n  type === undefined\n    ? // This property needs to remain unminified.\n      (value as TemplateResult)?.['_$litType$'] !== undefined\n    : (value as TemplateResult)?.['_$litType$'] === type;\n\n/**\n * Tests if a value is a DirectiveResult.\n */\nexport const isDirectiveResult = (value: unknown): value is DirectiveResult =>\n  // This property needs to remain unminified.\n  (value as DirectiveResult)?.['_$litDirective$'] !== undefined;\n\n/**\n * Retrieves the Directive class for a DirectiveResult\n */\nexport const getDirectiveClass = (value: unknown): DirectiveClass | undefined =>\n  // This property needs to remain unminified.\n  (value as DirectiveResult)?.['_$litDirective$'];\n\n/**\n * Tests whether a part has only a single-expression with no strings to\n * interpolate between.\n *\n * Only AttributePart and PropertyPart can have multiple expressions.\n * Multi-expression parts have a `strings` property and single-expression\n * parts do not.\n */\nexport const isSingleExpression = (part: PartInfo) =>\n  (part as AttributePartInfo).strings === undefined;\n\nconst createMarker = () => document.createComment('');\n\n/**\n * Inserts a ChildPart into the given container ChildPart's DOM, either at the\n * end of the container ChildPart, or before the optional `refPart`.\n *\n * This does not add the part to the containerPart's committed value. That must\n * be done by callers.\n *\n * @param containerPart Part within which to add the new ChildPart\n * @param refPart Part before which to add the new ChildPart; when omitted the\n *     part added to the end of the `containerPart`\n * @param part Part to insert, or undefined to create a new part\n */\nexport const insertPart = (\n  containerPart: ChildPart,\n  refPart?: ChildPart,\n  part?: ChildPart\n): ChildPart => {\n  const container = wrap(containerPart._$startNode).parentNode!;\n\n  const refNode =\n    refPart === undefined ? containerPart._$endNode : refPart._$startNode;\n\n  if (part === undefined) {\n    const startNode = wrap(container).insertBefore(createMarker(), refNode);\n    const endNode = wrap(container).insertBefore(createMarker(), refNode);\n    part = new ChildPart(\n      startNode,\n      endNode,\n      containerPart,\n      containerPart.options\n    );\n  } else {\n    const endNode = wrap(part._$endNode!).nextSibling;\n    const oldParent = part._$parent;\n    const parentChanged = oldParent !== containerPart;\n    if (parentChanged) {\n      part._$reparentDisconnectables?.(containerPart);\n      // Note that although `_$reparentDisconnectables` updates the part's\n      // `_$parent` reference after unlinking from its current parent, that\n      // method only exists if Disconnectables are present, so we need to\n      // unconditionally set it here\n      part._$parent = containerPart;\n      // Since the _$isConnected getter is somewhat costly, only\n      // read it once we know the subtree has directives that need\n      // to be notified\n      let newConnectionState;\n      if (\n        part._$notifyConnectionChanged !== undefined &&\n        (newConnectionState = containerPart._$isConnected) !==\n          oldParent!._$isConnected\n      ) {\n        part._$notifyConnectionChanged(newConnectionState);\n      }\n    }\n    if (endNode !== refNode || parentChanged) {\n      let start: Node | null = part._$startNode;\n      while (start !== endNode) {\n        const n: Node | null = wrap(start!).nextSibling;\n        wrap(container).insertBefore(start!, refNode);\n        start = n;\n      }\n    }\n  }\n\n  return part;\n};\n\n/**\n * Sets the value of a Part.\n *\n * Note that this should only be used to set/update the value of user-created\n * parts (i.e. those created using `insertPart`); it should not be used\n * by directives to set the value of the directive's container part. Directives\n * should return a value from `update`/`render` to update their part state.\n *\n * For directives that require setting their part value asynchronously, they\n * should extend `AsyncDirective` and call `this.setValue()`.\n *\n * @param part Part to set\n * @param value Value to set\n * @param index For `AttributePart`s, the index to set\n * @param directiveParent Used internally; should not be set by user\n */\nexport const setChildPartValue = <T extends ChildPart>(\n  part: T,\n  value: unknown,\n  directiveParent: DirectiveParent = part\n): T => {\n  part._$setValue(value, directiveParent);\n  return part;\n};\n\n// A sentinal value that can never appear as a part value except when set by\n// live(). Used to force a dirty-check to fail and cause a re-render.\nconst RESET_VALUE = {};\n\n/**\n * Sets the committed value of a ChildPart directly without triggering the\n * commit stage of the part.\n *\n * This is useful in cases where a directive needs to update the part such\n * that the next update detects a value change or not. When value is omitted,\n * the next update will be guaranteed to be detected as a change.\n *\n * @param part\n * @param value\n */\nexport const setCommittedValue = (part: Part, value: unknown = RESET_VALUE) =>\n  (part._$committedValue = value);\n\n/**\n * Returns the committed value of a ChildPart.\n *\n * The committed value is used for change detection and efficient updates of\n * the part. It can differ from the value set by the template or directive in\n * cases where the template value is transformed before being commited.\n *\n * - `TemplateResult`s are committed as a `TemplateInstance`\n * - Iterables are committed as `Array<ChildPart>`\n * - All other types are committed as the template value or value returned or\n *   set by a directive.\n *\n * @param part\n */\nexport const getCommittedValue = (part: ChildPart) => part._$committedValue;\n\n/**\n * Removes a ChildPart from the DOM, including any of its content.\n *\n * @param part The Part to remove\n */\nexport const removePart = (part: ChildPart) => {\n  part._$notifyConnectionChanged?.(false, true);\n  let start: ChildNode | null = part._$startNode;\n  const end: ChildNode | null = wrap(part._$endNode!).nextSibling;\n  while (start !== end) {\n    const n: ChildNode | null = wrap(start!).nextSibling;\n    (wrap(start!) as ChildNode).remove();\n    start = n;\n  }\n};\n\nexport const clearPart = (part: ChildPart) => {\n  part._$clear();\n};\n"]}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/development/directive.d.ts b/front_end/third_party/lit-html/package/development/directive.d.ts
index 5b4dcf1964ec047be24db2b0220898abbbbb711c..d63131209747d14d1c564c6c7417243adf642cce 100644
--- a/front_end/third_party/lit-html/package/development/directive.d.ts
+++ b/front_end/third_party/lit-html/package/development/directive.d.ts
@@ -3,8 +3,8 @@  * @license
  * Copyright 2017 Google LLC
  * SPDX-License-Identifier: BSD-3-Clause
  */
-import { Disconnectable, Part } from './lit-html';
+import { Disconnectable, Part } from './lit-html.js';
-export { AttributePart, BooleanAttributePart, ChildPart, ElementPart, EventPart, Part, PropertyPart, } from './lit-html';
+export { AttributePart, BooleanAttributePart, ChildPart, ElementPart, EventPart, Part, PropertyPart, } from './lit-html.js';
 export interface DirectiveClass {
     new (part: PartInfo): Directive;
 }




diff --git a/front_end/third_party/lit-html/package/development/directive.d.ts.map b/front_end/third_party/lit-html/package/development/directive.d.ts.map
index 2a13ef5347324c817dcf999bf7eee866220463e3..38fa290590548e7172695af33880356ee05345dc 100644
--- a/front_end/third_party/lit-html/package/development/directive.d.ts.map
+++ b/front_end/third_party/lit-html/package/development/directive.d.ts.map
@@ -1 +1 @@
-{"version":3,"file":"directive.d.ts","sourceRoot":"","sources":["../src/directive.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAC,cAAc,EAAE,IAAI,EAAC,MAAM,YAAY,CAAC;AAEhD,OAAO,EACL,aAAa,EACb,oBAAoB,EACpB,SAAS,EACT,WAAW,EACX,SAAS,EACT,IAAI,EACJ,YAAY,GACb,MAAM,YAAY,CAAC;AAEpB,MAAM,WAAW,cAAc;IAC7B,KAAK,IAAI,EAAE,QAAQ,GAAG,SAAS,CAAC;CACjC;AAED;;;GAGG;AACH,oBAAY,mBAAmB,CAAC,CAAC,SAAS,SAAS,IAAI,UAAU,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC;AAE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,SAAS,8GAMlB,CAAC;AAEL;;;;GAIG;AACH,8BAAsB,SAAU,YAAW,cAAc;gBAkB3C,SAAS,EAAE,QAAQ;IAG/B,IAAI,aAAa,YAEhB;IAiBD,QAAQ,CAAC,MAAM,CAAC,GAAG,KAAK,EAAE,KAAK,CAAC,OAAO,CAAC,GAAG,OAAO;IAElD,MAAM,CAAC,KAAK,EAAE,IAAI,EAAE,KAAK,EAAE,KAAK,CAAC,OAAO,CAAC,GAAG,OAAO;CAGpD"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/development/directive.js.map b/front_end/third_party/lit-html/package/development/directive.js.map
index 3697aa37d2009f0487ccadee835a2816a84236af..8fe0afc6e5714020e1198142fb51a3113544cdc4 100644
--- a/front_end/third_party/lit-html/package/development/directive.js.map
+++ b/front_end/third_party/lit-html/package/development/directive.js.map
@@ -1 +1 @@
-{"version":3,"file":"directive.js","sourceRoot":"","sources":["../src/directive.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAqCH,MAAM,CAAC,MAAM,QAAQ,GAAG;IACtB,SAAS,EAAE,CAAC;IACZ,KAAK,EAAE,CAAC;IACR,QAAQ,EAAE,CAAC;IACX,iBAAiB,EAAE,CAAC;IACpB,KAAK,EAAE,CAAC;IACR,OAAO,EAAE,CAAC;CACF,CAAC;AA+BX;;;GAGG;AACH,MAAM,CAAC,MAAM,SAAS,GACpB,CAA2B,CAAI,EAAE,EAAE,CACnC,CAAC,GAAG,MAA4C,EAAsB,EAAE,CAAC,CAAC;IACxE,4CAA4C;IAC5C,CAAC,iBAAiB,CAAC,EAAE,CAAC;IACtB,MAAM;CACP,CAAC,CAAC;AAEL;;;;GAIG;AACH,MAAM,OAAgB,SAAS;IAkB7B,YAAY,SAAmB,IAAG,CAAC;IAEnC,mEAAmE;IACnE,IAAI,aAAa;QACf,OAAO,IAAI,CAAC,QAAQ,CAAC,aAAa,CAAC;IACrC,CAAC;IAED,gBAAgB;IAChB,YAAY,CACV,IAAU,EACV,MAAsB,EACtB,cAAkC;QAElC,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC;QACnB,IAAI,CAAC,QAAQ,GAAG,MAAM,CAAC;QACvB,IAAI,CAAC,gBAAgB,GAAG,cAAc,CAAC;IACzC,CAAC;IACD,gBAAgB;IAChB,SAAS,CAAC,IAAU,EAAE,KAAqB;QACzC,OAAO,IAAI,CAAC,MAAM,CAAC,IAAI,EAAE,KAAK,CAAC,CAAC;IAClC,CAAC;IAID,MAAM,CAAC,KAAW,EAAE,KAAqB;QACvC,OAAO,IAAI,CAAC,MAAM,CAAC,GAAG,KAAK,CAAC,CAAC;IAC/B,CAAC;CACF","sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {Disconnectable, Part} from './lit-html';\n\nexport {\n  AttributePart,\n  BooleanAttributePart,\n  ChildPart,\n  ElementPart,\n  EventPart,\n  Part,\n  PropertyPart,\n} from './lit-html';\n\nexport interface DirectiveClass {\n  new (part: PartInfo): Directive;\n}\n\n/**\n * This utility type extracts the signature of a directive class's render()\n * method so we can use it for the type of the generated directive function.\n */\nexport type DirectiveParameters<C extends Directive> = Parameters<C['render']>;\n\n/**\n * A generated directive function doesn't evaluate the directive, but just\n * returns a DirectiveResult object that captures the arguments.\n */\nexport interface DirectiveResult<C extends DirectiveClass = DirectiveClass> {\n  /**\n   * This property needs to remain unminified.\n   * @internal */\n  ['_$litDirective$']: C;\n  /** @internal */\n  values: DirectiveParameters<InstanceType<C>>;\n}\n\nexport const PartType = {\n  ATTRIBUTE: 1,\n  CHILD: 2,\n  PROPERTY: 3,\n  BOOLEAN_ATTRIBUTE: 4,\n  EVENT: 5,\n  ELEMENT: 6,\n} as const;\n\nexport type PartType = typeof PartType[keyof typeof PartType];\n\nexport interface ChildPartInfo {\n  readonly type: typeof PartType.CHILD;\n}\n\nexport interface AttributePartInfo {\n  readonly type:\n    | typeof PartType.ATTRIBUTE\n    | typeof PartType.PROPERTY\n    | typeof PartType.BOOLEAN_ATTRIBUTE\n    | typeof PartType.EVENT;\n  readonly strings?: ReadonlyArray<string>;\n  readonly name: string;\n  readonly tagName: string;\n}\n\nexport interface ElementPartInfo {\n  readonly type: typeof PartType.ELEMENT;\n}\n\n/**\n * Information about the part a directive is bound to.\n *\n * This is useful for checking that a directive is attached to a valid part,\n * such as with directive that can only be used on attribute bindings.\n */\nexport type PartInfo = ChildPartInfo | AttributePartInfo | ElementPartInfo;\n\n/**\n * Creates a user-facing directive function from a Directive class. This\n * function has the same parameters as the directive's render() method.\n */\nexport const directive =\n  <C extends DirectiveClass>(c: C) =>\n  (...values: DirectiveParameters<InstanceType<C>>): DirectiveResult<C> => ({\n    // This property needs to remain unminified.\n    ['_$litDirective$']: c,\n    values,\n  });\n\n/**\n * Base class for creating custom directives. Users should extend this class,\n * implement `render` and/or `update`, and then pass their subclass to\n * `directive`.\n */\nexport abstract class Directive implements Disconnectable {\n  //@internal\n  __part!: Part;\n  //@internal\n  __attributeIndex: number | undefined;\n  //@internal\n  __directive?: Directive;\n\n  //@internal\n  _$parent!: Disconnectable;\n\n  // These will only exist on the AsyncDirective subclass\n  //@internal\n  _$disconnectableChildren?: Set<Disconnectable>;\n  // This property needs to remain unminified.\n  //@internal\n  ['_$notifyDirectiveConnectionChanged']?(isConnected: boolean): void;\n\n  constructor(_partInfo: PartInfo) {}\n\n  // See comment in Disconnectable interface for why this is a getter\n  get _$isConnected() {\n    return this._$parent._$isConnected;\n  }\n\n  /** @internal */\n  _$initialize(\n    part: Part,\n    parent: Disconnectable,\n    attributeIndex: number | undefined\n  ) {\n    this.__part = part;\n    this._$parent = parent;\n    this.__attributeIndex = attributeIndex;\n  }\n  /** @internal */\n  _$resolve(part: Part, props: Array<unknown>): unknown {\n    return this.update(part, props);\n  }\n\n  abstract render(...props: Array<unknown>): unknown;\n\n  update(_part: Part, props: Array<unknown>): unknown {\n    return this.render(...props);\n  }\n}\n"]}
\ No newline at end of file
+{"version":3,"file":"directive.js","sourceRoot":"","sources":["../src/directive.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAqCH,MAAM,CAAC,MAAM,QAAQ,GAAG;IACtB,SAAS,EAAE,CAAC;IACZ,KAAK,EAAE,CAAC;IACR,QAAQ,EAAE,CAAC;IACX,iBAAiB,EAAE,CAAC;IACpB,KAAK,EAAE,CAAC;IACR,OAAO,EAAE,CAAC;CACF,CAAC;AA+BX;;;GAGG;AACH,MAAM,CAAC,MAAM,SAAS,GACpB,CAA2B,CAAI,EAAE,EAAE,CACnC,CAAC,GAAG,MAA4C,EAAsB,EAAE,CAAC,CAAC;IACxE,4CAA4C;IAC5C,CAAC,iBAAiB,CAAC,EAAE,CAAC;IACtB,MAAM;CACP,CAAC,CAAC;AAEL;;;;GAIG;AACH,MAAM,OAAgB,SAAS;IAkB7B,YAAY,SAAmB,IAAG,CAAC;IAEnC,mEAAmE;IACnE,IAAI,aAAa;QACf,OAAO,IAAI,CAAC,QAAQ,CAAC,aAAa,CAAC;IACrC,CAAC;IAED,gBAAgB;IAChB,YAAY,CACV,IAAU,EACV,MAAsB,EACtB,cAAkC;QAElC,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC;QACnB,IAAI,CAAC,QAAQ,GAAG,MAAM,CAAC;QACvB,IAAI,CAAC,gBAAgB,GAAG,cAAc,CAAC;IACzC,CAAC;IACD,gBAAgB;IAChB,SAAS,CAAC,IAAU,EAAE,KAAqB;QACzC,OAAO,IAAI,CAAC,MAAM,CAAC,IAAI,EAAE,KAAK,CAAC,CAAC;IAClC,CAAC;IAID,MAAM,CAAC,KAAW,EAAE,KAAqB;QACvC,OAAO,IAAI,CAAC,MAAM,CAAC,GAAG,KAAK,CAAC,CAAC;IAC/B,CAAC;CACF","sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {Disconnectable, Part} from './lit-html.js';\n\nexport {\n  AttributePart,\n  BooleanAttributePart,\n  ChildPart,\n  ElementPart,\n  EventPart,\n  Part,\n  PropertyPart,\n} from './lit-html.js';\n\nexport interface DirectiveClass {\n  new (part: PartInfo): Directive;\n}\n\n/**\n * This utility type extracts the signature of a directive class's render()\n * method so we can use it for the type of the generated directive function.\n */\nexport type DirectiveParameters<C extends Directive> = Parameters<C['render']>;\n\n/**\n * A generated directive function doesn't evaluate the directive, but just\n * returns a DirectiveResult object that captures the arguments.\n */\nexport interface DirectiveResult<C extends DirectiveClass = DirectiveClass> {\n  /**\n   * This property needs to remain unminified.\n   * @internal */\n  ['_$litDirective$']: C;\n  /** @internal */\n  values: DirectiveParameters<InstanceType<C>>;\n}\n\nexport const PartType = {\n  ATTRIBUTE: 1,\n  CHILD: 2,\n  PROPERTY: 3,\n  BOOLEAN_ATTRIBUTE: 4,\n  EVENT: 5,\n  ELEMENT: 6,\n} as const;\n\nexport type PartType = typeof PartType[keyof typeof PartType];\n\nexport interface ChildPartInfo {\n  readonly type: typeof PartType.CHILD;\n}\n\nexport interface AttributePartInfo {\n  readonly type:\n    | typeof PartType.ATTRIBUTE\n    | typeof PartType.PROPERTY\n    | typeof PartType.BOOLEAN_ATTRIBUTE\n    | typeof PartType.EVENT;\n  readonly strings?: ReadonlyArray<string>;\n  readonly name: string;\n  readonly tagName: string;\n}\n\nexport interface ElementPartInfo {\n  readonly type: typeof PartType.ELEMENT;\n}\n\n/**\n * Information about the part a directive is bound to.\n *\n * This is useful for checking that a directive is attached to a valid part,\n * such as with directive that can only be used on attribute bindings.\n */\nexport type PartInfo = ChildPartInfo | AttributePartInfo | ElementPartInfo;\n\n/**\n * Creates a user-facing directive function from a Directive class. This\n * function has the same parameters as the directive's render() method.\n */\nexport const directive =\n  <C extends DirectiveClass>(c: C) =>\n  (...values: DirectiveParameters<InstanceType<C>>): DirectiveResult<C> => ({\n    // This property needs to remain unminified.\n    ['_$litDirective$']: c,\n    values,\n  });\n\n/**\n * Base class for creating custom directives. Users should extend this class,\n * implement `render` and/or `update`, and then pass their subclass to\n * `directive`.\n */\nexport abstract class Directive implements Disconnectable {\n  //@internal\n  __part!: Part;\n  //@internal\n  __attributeIndex: number | undefined;\n  //@internal\n  __directive?: Directive;\n\n  //@internal\n  _$parent!: Disconnectable;\n\n  // These will only exist on the AsyncDirective subclass\n  //@internal\n  _$disconnectableChildren?: Set<Disconnectable>;\n  // This property needs to remain unminified.\n  //@internal\n  ['_$notifyDirectiveConnectionChanged']?(isConnected: boolean): void;\n\n  constructor(_partInfo: PartInfo) {}\n\n  // See comment in Disconnectable interface for why this is a getter\n  get _$isConnected() {\n    return this._$parent._$isConnected;\n  }\n\n  /** @internal */\n  _$initialize(\n    part: Part,\n    parent: Disconnectable,\n    attributeIndex: number | undefined\n  ) {\n    this.__part = part;\n    this._$parent = parent;\n    this.__attributeIndex = attributeIndex;\n  }\n  /** @internal */\n  _$resolve(part: Part, props: Array<unknown>): unknown {\n    return this.update(part, props);\n  }\n\n  abstract render(...props: Array<unknown>): unknown;\n\n  update(_part: Part, props: Array<unknown>): unknown {\n    return this.render(...props);\n  }\n}\n"]}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/development/directives/async-replace.d.ts b/front_end/third_party/lit-html/package/development/directives/async-replace.d.ts
index 8023644c87ef68d31718788c8046b8503fb40a72..a033aa56dfda5ea480cfdca5dc5411a05bd9e70e 100644
--- a/front_end/third_party/lit-html/package/development/directives/async-replace.d.ts
+++ b/front_end/third_party/lit-html/package/development/directives/async-replace.d.ts
@@ -4,8 +4,8 @@  * Copyright 2017 Google LLC
  * SPDX-License-Identifier: BSD-3-Clause
  */
 import { ChildPart, noChange } from '../lit-html.js';
+ * Copyright 2017 Google LLC
 import { DirectiveParameters } from '../directive.js';
-import { AsyncDirective } from '../async-directive.js';
 declare type Mapper<T> = (v: T, index?: number) => unknown;
 export declare class AsyncReplaceDirective extends AsyncDirective {
     private __value?;




diff --git a/front_end/third_party/lit-html/package/development/directives/async-replace.d.ts.map b/front_end/third_party/lit-html/package/development/directives/async-replace.d.ts.map
index 2b39dc3d2e2cceda216f9ac85159605b03d519a9..a5e6430022ab1e73bf549c08b74a04d6d2b00b7c 100644
--- a/front_end/third_party/lit-html/package/development/directives/async-replace.d.ts.map
+++ b/front_end/third_party/lit-html/package/development/directives/async-replace.d.ts.map
@@ -1 +1 @@
-{"version":3,"file":"async-replace.d.ts","sourceRoot":"","sources":["../../src/directives/async-replace.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAC,SAAS,EAAE,QAAQ,EAAC,MAAM,gBAAgB,CAAC;AACnD,OAAO,EAAY,mBAAmB,EAAC,MAAM,iBAAiB,CAAC;AAC/D,OAAO,EAAC,cAAc,EAAC,MAAM,uBAAuB,CAAC;AAGrD,aAAK,MAAM,CAAC,CAAC,IAAI,CAAC,CAAC,EAAE,CAAC,EAAE,KAAK,CAAC,EAAE,MAAM,KAAK,OAAO,CAAC;AAEnD,qBAAa,qBAAsB,SAAQ,cAAc;IACvD,OAAO,CAAC,OAAO,CAAC,CAAyB;IACzC,OAAO,CAAC,UAAU,CAA2B;IAC7C,OAAO,CAAC,QAAQ,CAAgB;IAIhC,MAAM,CAAC,CAAC,EAAE,KAAK,EAAE,aAAa,CAAC,CAAC,CAAC,EAAE,OAAO,CAAC,EAAE,MAAM,CAAC,CAAC,CAAC;IAI7C,MAAM,CACb,KAAK,EAAE,SAAS,EAChB,CAAC,KAAK,EAAE,MAAM,CAAC,EAAE,mBAAmB,CAAC,IAAI,CAAC;IAqD5C,SAAS,CAAC,WAAW,CAAC,KAAK,EAAE,OAAO,EAAE,MAAM,EAAE,MAAM;IAI3C,YAAY;IAKZ,WAAW;CAIrB;AAED;;;;;;;;;;;;;;;;;GAiBG;AACH,eAAO,MAAM,YAAY,mJAAmC,CAAC"}
\ No newline at end of file
+{"version":3,"file":"async-replace.d.ts","sourceRoot":"","sources":["../../src/directives/async-replace.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAC,SAAS,EAAE,QAAQ,EAAC,MAAM,gBAAgB,CAAC;AACnD,OAAO,EACL,cAAc,EAEd,mBAAmB,EACpB,MAAM,uBAAuB,CAAC;AAG/B,aAAK,MAAM,CAAC,CAAC,IAAI,CAAC,CAAC,EAAE,CAAC,EAAE,KAAK,CAAC,EAAE,MAAM,KAAK,OAAO,CAAC;AAEnD,qBAAa,qBAAsB,SAAQ,cAAc;IACvD,OAAO,CAAC,OAAO,CAAC,CAAyB;IACzC,OAAO,CAAC,UAAU,CAA2B;IAC7C,OAAO,CAAC,QAAQ,CAAgB;IAIhC,MAAM,CAAC,CAAC,EAAE,KAAK,EAAE,aAAa,CAAC,CAAC,CAAC,EAAE,OAAO,CAAC,EAAE,MAAM,CAAC,CAAC,CAAC;IAI7C,MAAM,CACb,KAAK,EAAE,SAAS,EAChB,CAAC,KAAK,EAAE,MAAM,CAAC,EAAE,mBAAmB,CAAC,IAAI,CAAC;IAqD5C,SAAS,CAAC,WAAW,CAAC,KAAK,EAAE,OAAO,EAAE,MAAM,EAAE,MAAM;IAI3C,YAAY;IAKZ,WAAW;CAIrB;AAED;;;;;;;;;;;;;;;;;GAiBG;AACH,eAAO,MAAM,YAAY,mJAAmC,CAAC"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/development/directives/async-replace.js b/front_end/third_party/lit-html/package/development/directives/async-replace.js
index d652ee9f146b4171242912f54919d4aca631128c..7a9f81f495046953fa2c90c5ac5dffeff73f95d6 100644
--- a/front_end/third_party/lit-html/package/development/directives/async-replace.js
+++ b/front_end/third_party/lit-html/package/development/directives/async-replace.js
@@ -4,8 +4,8 @@  * Copyright 2017 Google LLC
  * SPDX-License-Identifier: BSD-3-Clause
  */
 import { noChange } from '../lit-html.js';
-import { directive } from '../directive.js';
 import { AsyncDirective } from '../async-directive.js';
+import { Pauser, PseudoWeakRef, forAwaitOf } from './private-async-helpers.js';
 import { Pauser, PseudoWeakRef, forAwaitOf } from './private-async-helpers.js';
 export class AsyncReplaceDirective extends AsyncDirective {
     constructor() {




diff --git a/front_end/third_party/lit-html/package/development/directives/async-replace.js.map b/front_end/third_party/lit-html/package/development/directives/async-replace.js.map
index c0f95206346a06683a86e36e36fabf9dbe2bf988..12dfc85cf212c5cca9972a73911229bdf95b8956 100644
--- a/front_end/third_party/lit-html/package/development/directives/async-replace.js.map
+++ b/front_end/third_party/lit-html/package/development/directives/async-replace.js.map
@@ -1 +1 @@
-{"version":3,"file":"async-replace.js","sourceRoot":"","sources":["../../src/directives/async-replace.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAY,QAAQ,EAAC,MAAM,gBAAgB,CAAC;AACnD,OAAO,EAAC,SAAS,EAAsB,MAAM,iBAAiB,CAAC;AAC/D,OAAO,EAAC,cAAc,EAAC,MAAM,uBAAuB,CAAC;AACrD,OAAO,EAAC,MAAM,EAAE,aAAa,EAAE,UAAU,EAAC,MAAM,4BAA4B,CAAC;AAI7E,MAAM,OAAO,qBAAsB,SAAQ,cAAc;IAAzD;;QAEU,eAAU,GAAG,IAAI,aAAa,CAAC,IAAI,CAAC,CAAC;QACrC,aAAQ,GAAG,IAAI,MAAM,EAAE,CAAC;IA4ElC,CAAC;IA1EC,yEAAyE;IACzE,6DAA6D;IAC7D,MAAM,CAAI,KAAuB,EAAE,OAAmB;QACpD,OAAO,QAAQ,CAAC;IAClB,CAAC;IAEQ,MAAM,CACb,KAAgB,EAChB,CAAC,KAAK,EAAE,MAAM,CAA4B;QAE1C,0EAA0E;QAC1E,6CAA6C;QAC7C,IAAI,CAAC,IAAI,CAAC,WAAW,EAAE;YACrB,IAAI,CAAC,YAAY,EAAE,CAAC;SACrB;QACD,kEAAkE;QAClE,kBAAkB;QAClB,IAAI,KAAK,KAAK,IAAI,CAAC,OAAO,EAAE;YAC1B,OAAO;SACR;QACD,IAAI,CAAC,OAAO,GAAG,KAAK,CAAC;QACrB,IAAI,CAAC,GAAG,CAAC,CAAC;QACV,MAAM,EAAC,UAAU,EAAE,QAAQ,EAAE,QAAQ,EAAE,MAAM,EAAC,GAAG,IAAI,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;;GAiBG;AACH,MAAM,CAAC,MAAM,YAAY,GAAG,SAAS,CAAC,qBAAqB,CAAC,CAAC","sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {ChildPart, noChange} from '../lit-html.js';\nimport {directive, DirectiveParameters} from '../directive.js';\nimport {AsyncDirective} from '../async-directive.js';\nimport {Pauser, PseudoWeakRef, forAwaitOf} from './private-async-helpers.js';\n\ntype Mapper<T> = (v: T, index?: number) => unknown;\n\nexport class AsyncReplaceDirective extends AsyncDirective {\n  private __value?: AsyncIterable<unknown>;\n  private __weakThis = new PseudoWeakRef(this);\n  private __pauser = new Pauser();\n\n  // @ts-expect-error value not used, but we want a nice parameter for docs\n  // eslint-disable-next-line @typescript-eslint/no-unused-vars\n  render<T>(value: AsyncIterable<T>, _mapper?: Mapper<T>) {\n    return noChange;\n  }\n\n  override update(\n    _part: ChildPart,\n    [value, mapper]: DirectiveParameters<this>\n  ) {\n    // If our initial render occurs while disconnected, ensure that the pauser\n    // and weakThis are in the disconnected state\n    if (!this.isConnected) {\n      this.disconnected();\n    }\n    // If we've already set up this particular iterable, we don't need\n    // to do anything.\n    if (value === this.__value) {\n      return;\n    }\n    this.__value = value;\n    let i = 0;\n    const {__weakThis: weakThis, __pauser: pauser} = this;\n    // Note, the callback avoids closing over `this` so that the directive\n    // can be gc'ed before the promise resolves; instead `this` is retrieved\n    // from `weakThis`, which can break the hard reference in the closure when\n    // the directive disconnects\n    forAwaitOf(value, async (v: unknown) => {\n      // The while loop here handles the case that the connection state\n      // thrashes, causing the pauser to resume and then get re-paused\n      while (pauser.get()) {\n        await pauser.get();\n      }\n      // If the callback gets here and there is no `this`, it means that the\n      // directive has been disconnected and garbage collected and we don't\n      // need to do anything else\n      const _this = weakThis.deref();\n      if (_this !== undefined) {\n        // Check to make sure that value is the still the current value of\n        // the part, and if not bail because a new value owns this part\n        if (_this.__value !== value) {\n          return false;\n        }\n\n        // As a convenience, because functional-programming-style\n        // transforms of iterables and async iterables requires a library,\n        // we accept a mapper function. This is especially convenient for\n        // rendering a template for each item.\n        if (mapper !== undefined) {\n          v = mapper(v, i);\n        }\n\n        _this.commitValue(v, i);\n        i++;\n      }\n      return true;\n    });\n    return noChange;\n  }\n\n  // Override point for AsyncAppend to append rather than replace\n  protected commitValue(value: unknown, _index: number) {\n    this.setValue(value);\n  }\n\n  override disconnected() {\n    this.__weakThis.disconnect();\n    this.__pauser.pause();\n  }\n\n  override reconnected() {\n    this.__weakThis.reconnect(this);\n    this.__pauser.resume();\n  }\n}\n\n/**\n * A directive that renders the items of an async iterable[1], replacing\n * previous values with new values, so that only one value is ever rendered\n * at a time. This directive may be used in any expression type.\n *\n * Async iterables are objects with a `[Symbol.asyncIterator]` method, which\n * returns an iterator who's `next()` method returns a Promise. When a new\n * value is available, the Promise resolves and the value is rendered to the\n * Part controlled by the directive. If another value other than this\n * directive has been set on the Part, the iterable will no longer be listened\n * to and new values won't be written to the Part.\n *\n * [1]: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/for-await...of\n *\n * @param value An async iterable\n * @param mapper An optional function that maps from (value, index) to another\n *     value. Useful for generating templates for each item in the iterable.\n */\nexport const asyncReplace = directive(AsyncReplaceDirective);\n"]}
\ No newline at end of file
+{"version":3,"file":"async-replace.js","sourceRoot":"","sources":["../../src/directives/async-replace.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAY,QAAQ,EAAC,MAAM,gBAAgB,CAAC;AACnD,OAAO,EACL,cAAc,EACd,SAAS,GAEV,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EAAC,MAAM,EAAE,aAAa,EAAE,UAAU,EAAC,MAAM,4BAA4B,CAAC;AAI7E,MAAM,OAAO,qBAAsB,SAAQ,cAAc;IAAzD;;QAEU,eAAU,GAAG,IAAI,aAAa,CAAC,IAAI,CAAC,CAAC;QACrC,aAAQ,GAAG,IAAI,MAAM,EAAE,CAAC;IA4ElC,CAA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,CAAC,EAAE,CAAC,CAAC,CAAC;gBACxB,CAAC,EAAE,CAAC;aACL;YACD,OAAO,IAAI,CAAC;QACd,CAAC,CAAC,CAAC;QACH,OAAO,QAAQ,CAAC;IAClB,CAAC;IAED,+DAA+D;IACrD,WAAW,CAAC,KAAc,EAAE,MAAc;QAClD,IAAI,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC;IACvB,CAAC;IAEQ,YAAY;QACnB,IAAI,CAAC,UAAU,CAAC,UAAU,EAAE,CAAC;QAC7B,IAAI,CAAC,QAAQ,CAAC,KAAK,EAAE,CAAC;IACxB,CAAC;IAEQ,WAAW;QAClB,IAAI,CAAC,UAAU,CAAC,SAAS,CAAC,IAAI,CAAC,CAAC;QAChC,IAAI,CAAC,QAAQ,CAAC,MAAM,EAAE,CAAC;IACzB,CAAC;CACF;AAED;;;;;;;;;;;;;;;;;GAiBG;AACH,MAAM,CAAC,MAAM,YAAY,GAAG,SAAS,CAAC,qBAAqB,CAAC,CAAC","sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {ChildPart, noChange} from '../lit-html.js';\nimport {\n  AsyncDirective,\n  directive,\n  DirectiveParameters,\n} from '../async-directive.js';\nimport {Pauser, PseudoWeakRef, forAwaitOf} from './private-async-helpers.js';\n\ntype Mapper<T> = (v: T, index?: number) => unknown;\n\nexport class AsyncReplaceDirective extends AsyncDirective {\n  private __value?: AsyncIterable<unknown>;\n  private __weakThis = new PseudoWeakRef(this);\n  private __pauser = new Pauser();\n\n  // @ts-expect-error value not used, but we want a nice parameter for docs\n  // eslint-disable-next-line @typescript-eslint/no-unused-vars\n  render<T>(value: AsyncIterable<T>, _mapper?: Mapper<T>) {\n    return noChange;\n  }\n\n  override update(\n    _part: ChildPart,\n    [value, mapper]: DirectiveParameters<this>\n  ) {\n    // If our initial render occurs while disconnected, ensure that the pauser\n    // and weakThis are in the disconnected state\n    if (!this.isConnected) {\n      this.disconnected();\n    }\n    // If we've already set up this particular iterable, we don't need\n    // to do anything.\n    if (value === this.__value) {\n      return;\n    }\n    this.__value = value;\n    let i = 0;\n    const {__weakThis: weakThis, __pauser: pauser} = this;\n    // Note, the callback avoids closing over `this` so that the directive\n    // can be gc'ed before the promise resolves; instead `this` is retrieved\n    // from `weakThis`, which can break the hard reference in the closure when\n    // the directive disconnects\n    forAwaitOf(value, async (v: unknown) => {\n      // The while loop here handles the case that the connection state\n      // thrashes, causing the pauser to resume and then get re-paused\n      while (pauser.get()) {\n        await pauser.get();\n      }\n      // If the callback gets here and there is no `this`, it means that the\n      // directive has been disconnected and garbage collected and we don't\n      // need to do anything else\n      const _this = weakThis.deref();\n      if (_this !== undefined) {\n        // Check to make sure that value is the still the current value of\n        // the part, and if not bail because a new value owns this part\n        if (_this.__value !== value) {\n          return false;\n        }\n\n        // As a convenience, because functional-programming-style\n        // transforms of iterables and async iterables requires a library,\n        // we accept a mapper function. This is especially convenient for\n        // rendering a template for each item.\n        if (mapper !== undefined) {\n          v = mapper(v, i);\n        }\n\n        _this.commitValue(v, i);\n        i++;\n      }\n      return true;\n    });\n    return noChange;\n  }\n\n  // Override point for AsyncAppend to append rather than replace\n  protected commitValue(value: unknown, _index: number) {\n    this.setValue(value);\n  }\n\n  override disconnected() {\n    this.__weakThis.disconnect();\n    this.__pauser.pause();\n  }\n\n  override reconnected() {\n    this.__weakThis.reconnect(this);\n    this.__pauser.resume();\n  }\n}\n\n/**\n * A directive that renders the items of an async iterable[1], replacing\n * previous values with new values, so that only one value is ever rendered\n * at a time. This directive may be used in any expression type.\n *\n * Async iterables are objects with a `[Symbol.asyncIterator]` method, which\n * returns an iterator who's `next()` method returns a Promise. When a new\n * value is available, the Promise resolves and the value is rendered to the\n * Part controlled by the directive. If another value other than this\n * directive has been set on the Part, the iterable will no longer be listened\n * to and new values won't be written to the Part.\n *\n * [1]: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/for-await...of\n *\n * @param value An async iterable\n * @param mapper An optional function that maps from (value, index) to another\n *     value. Useful for generating templates for each item in the iterable.\n */\nexport const asyncReplace = directive(AsyncReplaceDirective);\n"]}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/development/directives/keyed.d.ts b/front_end/third_party/lit-html/package/development/directives/keyed.d.ts
index b1c0cb83c4f56f50b43d2b11e9395fc5fec91af4..457237ff8fda898923e35f2b222027e6d777ff6b 100644
--- a/front_end/third_party/lit-html/package/development/directives/keyed.d.ts
+++ b/front_end/third_party/lit-html/package/development/directives/keyed.d.ts
@@ -19,5 +19,10 @@  * with code that expects new data to generate new HTML elements, such as some
  * animation techniques.
  */
 export declare const keyed: (k: unknown, v: unknown) => import("../directive.js").DirectiveResult<typeof Keyed>;
+/**
  * @license
+ * @license
+ * directive's return type.
+ */
+export type { Keyed };
 //# sourceMappingURL=keyed.d.ts.map
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/development/directives/keyed.d.ts.map b/front_end/third_party/lit-html/package/development/directives/keyed.d.ts.map
index 753e04195329d2cd49058042fe2d0bc5882e6784..51064775152698be98ff17e00a7ee74c7cd3ce12 100644
--- a/front_end/third_party/lit-html/package/development/directives/keyed.d.ts.map
+++ b/front_end/third_party/lit-html/package/development/directives/keyed.d.ts.map
@@ -1 +1 @@
-{"version":3,"file":"keyed.d.ts","sourceRoot":"","sources":["../../src/directives/keyed.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAGH,OAAO,EAEL,SAAS,EACT,SAAS,EACT,mBAAmB,EACpB,MAAM,iBAAiB,CAAC;AAGzB,cAAM,KAAM,SAAQ,SAAS;IAC3B,GAAG,EAAE,OAAO,CAAW;IAEvB,MAAM,CAAC,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,OAAO;IAKpB,MAAM,CAAC,IAAI,EAAE,SAAS,EAAE,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,mBAAmB,CAAC,IAAI,CAAC;CAUnE;AAED;;;;;;;;GAQG;AACH,eAAO,MAAM,KAAK,qFAAmB,CAAC"}
\ No newline at end of file
+{"version":3,"file":"keyed.d.ts","sourceRoot":"","sources":["../../src/directives/keyed.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAGH,OAAO,EAEL,SAAS,EACT,SAAS,EACT,mBAAmB,EACpB,MAAM,iBAAiB,CAAC;AAGzB,cAAM,KAAM,SAAQ,SAAS;IAC3B,GAAG,EAAE,OAAO,CAAW;IAEvB,MAAM,CAAC,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,OAAO;IAKpB,MAAM,CAAC,IAAI,EAAE,SAAS,EAAE,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,mBAAmB,CAAC,IAAI,CAAC;CAUnE;AAED;;;;;;;;GAQG;AACH,eAAO,MAAM,KAAK,qFAAmB,CAAC;AAEtC;;;GAGG;AACH,YAAY,EAAC,KAAK,EAAC,CAAC"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/development/directives/keyed.js.map b/front_end/third_party/lit-html/package/development/directives/keyed.js.map
index c7813c4051fa74e8f186c7b75faf036efdc42804..0029801fa651cc0e6c41a7b3e0095c52fc1e4f57 100644
--- a/front_end/third_party/lit-html/package/development/directives/keyed.js.map
+++ b/front_end/third_party/lit-html/package/development/directives/keyed.js.map
@@ -1 +1 @@
-{"version":3,"file":"keyed.js","sourceRoot":"","sources":["../../src/directives/keyed.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAC,OAAO,EAAC,MAAM,gBAAgB,CAAC;AACvC,OAAO,EACL,SAAS,EACT,SAAS,GAGV,MAAM,iBAAiB,CAAC;AACzB,OAAO,EAAC,iBAAiB,EAAC,MAAM,yBAAyB,CAAC;AAE1D,MAAM,KAAM,SAAQ,SAAS;IAA7B;;QACE,QAAG,GAAY,OAAO,CAAC;IAiBzB,CAAC;IAfC,MAAM,CAAC,CAAU,EAAE,CAAU;QAC3B,IAAI,CAAC,GAAG,GAAG,CAAC,CAAC;QACb,OAAO,CAAC,CAAC;IACX,CAAC;IAEQ,MAAM,CAAC,IAAe,EAAE,CAAC,CAAC,EAAE,CAAC,CAA4B;QAChE,IAAI,CAAC,KAAK,IAAI,CAAC,GAAG,EAAE;YAClB,+DAA+D;YAC/D,gEAAgE;YAChE,0BAA0B;YAC1B,iBAAiB,CAAC,IAAI,CAAC,CAAC;YACxB,IAAI,CAAC,GAAG,GAAG,CAAC,CAAC;SACd;QACD,OAAO,CAAC,CAAC;IACX,CAAC;CACF;AAED;;;;;;;;GAQG;AACH,MAAM,CAAC,MAAM,KAAK,GAAG,SAAS,CAAC,KAAK,CAAC,CAAC","sourcesContent":["/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {nothing} from '../lit-html.js';\nimport {\n  directive,\n  Directive,\n  ChildPart,\n  DirectiveParameters,\n} from '../directive.js';\nimport {setCommittedValue} from '../directive-helpers.js';\n\nclass Keyed extends Directive {\n  key: unknown = nothing;\n\n  render(k: unknown, v: unknown) {\n    this.key = k;\n    return v;\n  }\n\n  override update(part: ChildPart, [k, v]: DirectiveParameters<this>) {\n    if (k !== this.key) {\n      // Clear the part before returning a value. The one-arg form of\n      // setCommittedValue sets the value to a sentinel which forces a\n      // commit the next render.\n      setCommittedValue(part);\n      this.key = k;\n    }\n    return v;\n  }\n}\n\n/**\n * Associates a renderable value with a unique key. When the key changes, the\n * previous DOM is removed and disposed before rendering the next value, even\n * if the value - such as a template - is the same.\n *\n * This is useful for forcing re-renders of stateful components, or working\n * with code that expects new data to generate new HTML elements, such as some\n * animation techniques.\n */\nexport const keyed = directive(Keyed);\n"]}
\ No newline at end of file
+{"version":3,"file":"keyed.js","sourceRoot":"","sources":["../../src/directives/keyed.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAC,OAAO,EAAC,MAAM,gBAAgB,CAAC;AACvC,OAAO,EACL,SAAS,EACT,SAAS,GAGV,MAAM,iBAAiB,CAAC;AACzB,OAAO,EAAC,iBAAiB,EAAC,MAAM,yBAAyB,CAAC;AAE1D,MAAM,KAAM,SAAQ,SAAS;IAA7B;;QACE,QAAG,GAAY,OAAO,CAAC;IAiBzB,CAAC;IAfC,MAAM,CAAC,CAAU,EAAE,CAAU;QAC3B,IAAI,CAAC,GAAG,GAAG,CAAC,CAAC;QACb,OAAO,CAAC,CAAC;IACX,CAAC;IAEQ,MAAM,CAAC,IAAe,EAAE,CAAC,CAAC,EAAE,CAAC,CAA4B;QAChE,IAAI,CAAC,KAAK,IAAI,CAAC,GAAG,EAAE;YAClB,+DAA+D;YAC/D,gEAAgE;YAChE,0BAA0B;YAC1B,iBAAiB,CAAC,IAAI,CAAC,CAAC;YACxB,IAAI,CAAC,GAAG,GAAG,CAAC,CAAC;SACd;QACD,OAAO,CAAC,CAAC;IACX,CAAC;CACF;AAED;;;;;;;;GAQG;AACH,MAAM,CAAC,MAAM,KAAK,GAAG,SAAS,CAAC,KAAK,CAAC,CAAC","sourcesContent":["/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {nothing} from '../lit-html.js';\nimport {\n  directive,\n  Directive,\n  ChildPart,\n  DirectiveParameters,\n} from '../directive.js';\nimport {setCommittedValue} from '../directive-helpers.js';\n\nclass Keyed extends Directive {\n  key: unknown = nothing;\n\n  render(k: unknown, v: unknown) {\n    this.key = k;\n    return v;\n  }\n\n  override update(part: ChildPart, [k, v]: DirectiveParameters<this>) {\n    if (k !== this.key) {\n      // Clear the part before returning a value. The one-arg form of\n      // setCommittedValue sets the value to a sentinel which forces a\n      // commit the next render.\n      setCommittedValue(part);\n      this.key = k;\n    }\n    return v;\n  }\n}\n\n/**\n * Associates a renderable value with a unique key. When the key changes, the\n * previous DOM is removed and disposed before rendering the next value, even\n * if the value - such as a template - is the same.\n *\n * This is useful for forcing re-renders of stateful components, or working\n * with code that expects new data to generate new HTML elements, such as some\n * animation techniques.\n */\nexport const keyed = directive(Keyed);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {Keyed};\n"]}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/development/directives/live.d.ts b/front_end/third_party/lit-html/package/development/directives/live.d.ts
index 23d46f261d7a280f0dc3e8046202d9ae6d036f89..f472de738a54e4fab2425e7f8cf60a75c7aceb0e 100644
--- a/front_end/third_party/lit-html/package/development/directives/live.d.ts
+++ b/front_end/third_party/lit-html/package/development/directives/live.d.ts
@@ -28,7 +28,7 @@  * ```js
  * html`<input .value=${live(x)}>`
  * ```
  *
- * @license
+ * Copyright 2020 Google LLC
 import { Directive, DirectiveParameters, PartInfo } from '../directive.js';
  * the new value is equal to the live value, does nothing. This means that
  * `live()` should not be used when the binding will cause a type conversion. If




diff --git a/front_end/third_party/lit-html/package/development/directives/live.js b/front_end/third_party/lit-html/package/development/directives/live.js
index fd37e226b84f1e97d833f7d5e89a9c1dd27f40e0..c9954b06699ee7018506419d764e5eeebb7b0983 100644
--- a/front_end/third_party/lit-html/package/development/directives/live.js
+++ b/front_end/third_party/lit-html/package/development/directives/live.js
@@ -67,7 +67,7 @@  * ```js
  * html`<input .value=${live(x)}>`
  * ```
  *
- * `live()` performs a strict equality check agains the live DOM value, and if
+ * `live()` performs a strict equality check against the live DOM value, and if
  * the new value is equal to the live value, does nothing. This means that
  * `live()` should not be used when the binding will cause a type conversion. If
  * you use `live()` with an attribute binding, make sure that only strings are




diff --git a/front_end/third_party/lit-html/package/development/directives/live.js.map b/front_end/third_party/lit-html/package/development/directives/live.js.map
index 605efb30e6a5f0d56200fb5097cc5ce77ba3a052..f3de5eb29425a4771e7f3ad2e519c9e71db75674 100644
--- a/front_end/third_party/lit-html/package/development/directives/live.js.map
+++ b/front_end/third_party/lit-html/package/development/directives/live.js.map
@@ -1 +1 @@
-{"version":3,"file":"live.js","sourceRoot":"","sources":["../../src/directives/live.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAgB,QAAQ,EAAE,OAAO,EAAC,MAAM,gBAA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ACjB;SACF;aAAM,IAAI,IAAI,CAAC,IAAI,KAAK,QAAQ,CAAC,SAAS,EAAE;YAC3C,IAAI,OAAO,CAAC,YAAY,CAAC,IAAI,CAAC,KAAK,MAAM,CAAC,KAAK,CAAC,EAAE;gBAChD,OAAO,QAAQ,CAAC;aACjB;SACF;QACD,sEAAsE;QACtE,yBAAyB;QACzB,iBAAiB,CAAC,IAAI,CAAC,CAAC;QACxB,OAAO,KAAK,CAAC;IACf,CAAC;CACF;AAED;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AACH,MAAM,CAAC,MAAM,IAAI,GAAG,SAAS,CAAC,aAAa,CAAC,CAAC","sourcesContent":["/**\n * @license\n * Copyright 2020 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {AttributePart, noChange, nothing} from '../lit-html.js';\nimport {\n  directive,\n  Directive,\n  DirectiveParameters,\n  PartInfo,\n  PartType,\n} from '../directive.js';\nimport {isSingleExpression, setCommittedValue} from '../directive-helpers.js';\n\nclass LiveDirective extends Directive {\n  constructor(partInfo: PartInfo) {\n    super(partInfo);\n    if (\n      !(\n        partInfo.type === PartType.PROPERTY ||\n        partInfo.type === PartType.ATTRIBUTE ||\n        partInfo.type === PartType.BOOLEAN_ATTRIBUTE\n      )\n    ) {\n      throw new Error(\n        'The `live` directive is not allowed on child or event bindings'\n      );\n    }\n    if (!isSingleExpression(partInfo)) {\n      throw new Error('`live` bindings can only contain a single expression');\n    }\n  }\n\n  render(value: unknown) {\n    return value;\n  }\n\n  override update(part: AttributePart, [value]: DirectiveParameters<this>) {\n    if (value === noChange || value === nothing) {\n      return value;\n    }\n    const element = part.element;\n    const name = part.name;\n\n    if (part.type === PartType.PROPERTY) {\n      // eslint-disable-next-line @typescript-eslint/no-explicit-any\n      if (value === (element as any)[name]) {\n        return noChange;\n      }\n    } else if (part.type === PartType.BOOLEAN_ATTRIBUTE) {\n      if (!!value === element.hasAttribute(name)) {\n        return noChange;\n      }\n    } else if (part.type === PartType.ATTRIBUTE) {\n      if (element.getAttribute(name) === String(value)) {\n        return noChange;\n      }\n    }\n    // Resets the part's value, causing its dirty-check to fail so that it\n    // always sets the value.\n    setCommittedValue(part);\n    return value;\n  }\n}\n\n/**\n * Checks binding values against live DOM values, instead of previously bound\n * values, when determining whether to update the value.\n *\n * This is useful for cases where the DOM value may change from outside of\n * lit-html, such as with a binding to an `<input>` element's `value` property,\n * a content editable elements text, or to a custom element that changes it's\n * own properties or attributes.\n *\n * In these cases if the DOM value changes, but the value set through lit-html\n * bindings hasn't, lit-html won't know to update the DOM value and will leave\n * it alone. If this is not what you want--if you want to overwrite the DOM\n * value with the bound value no matter what--use the `live()` directive:\n *\n * ```js\n * html`<input .value=${live(x)}>`\n * ```\n *\n * `live()` performs a strict equality check agains the live DOM value, and if\n * the new value is equal to the live value, does nothing. This means that\n * `live()` should not be used when the binding will cause a type conversion. If\n * you use `live()` with an attribute binding, make sure that only strings are\n * passed in, or the binding will update every render.\n */\nexport const live = directive(LiveDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {LiveDirective};\n"]}
\ No newline at end of file
+{"version":3,"file":"live.js","sourceRoot":"","sources":["../../src/directives/live.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAgB,QAAQ,EAAE,OAAO,EAAC,MAAM,gBAAgB,CAAC;AAChE,OAAO,EACL,SAAS,EACT,SAAS,EAGT,QAAQ,GACT,MAAM,iBAAiB,CAAC;AACzB,OAAO,EAAC,kBAAkB,EAAE,iBAAiB,EAAC,MAAM,yBAAyB,CAAC;AAE9E,MAAM,aAAc,SAAQ,SAAS;IACnC,YAAY,QAAkB;QAC5B,KAAK,CAAC,QAAQ,CAAC,CAAC;QAChB,IACE,CAAC,CACC,QAAQ,CAAC,IAAI,KAAK,QAAQ,CAAC,QAAQ;YACnC,QAAQ,CAAC,IAAI,KAAK,QAAQ,CAAC,SAAS;YACpC,QAAQ,CAAC,IAAI,KAAK,QAAQ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C,CAAC","sourcesContent":["/**\n * @license\n * Copyright 2020 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {AttributePart, noChange, nothing} from '../lit-html.js';\nimport {\n  directive,\n  Directive,\n  DirectiveParameters,\n  PartInfo,\n  PartType,\n} from '../directive.js';\nimport {isSingleExpression, setCommittedValue} from '../directive-helpers.js';\n\nclass LiveDirective extends Directive {\n  constructor(partInfo: PartInfo) {\n    super(partInfo);\n    if (\n      !(\n        partInfo.type === PartType.PROPERTY ||\n        partInfo.type === PartType.ATTRIBUTE ||\n        partInfo.type === PartType.BOOLEAN_ATTRIBUTE\n      )\n    ) {\n      throw new Error(\n        'The `live` directive is not allowed on child or event bindings'\n      );\n    }\n    if (!isSingleExpression(partInfo)) {\n      throw new Error('`live` bindings can only contain a single expression');\n    }\n  }\n\n  render(value: unknown) {\n    return value;\n  }\n\n  override update(part: AttributePart, [value]: DirectiveParameters<this>) {\n    if (value === noChange || value === nothing) {\n      return value;\n    }\n    const element = part.element;\n    const name = part.name;\n\n    if (part.type === PartType.PROPERTY) {\n      // eslint-disable-next-line @typescript-eslint/no-explicit-any\n      if (value === (element as any)[name]) {\n        return noChange;\n      }\n    } else if (part.type === PartType.BOOLEAN_ATTRIBUTE) {\n      if (!!value === element.hasAttribute(name)) {\n        return noChange;\n      }\n    } else if (part.type === PartType.ATTRIBUTE) {\n      if (element.getAttribute(name) === String(value)) {\n        return noChange;\n      }\n    }\n    // Resets the part's value, causing its dirty-check to fail so that it\n    // always sets the value.\n    setCommittedValue(part);\n    return value;\n  }\n}\n\n/**\n * Checks binding values against live DOM values, instead of previously bound\n * values, when determining whether to update the value.\n *\n * This is useful for cases where the DOM value may change from outside of\n * lit-html, such as with a binding to an `<input>` element's `value` property,\n * a content editable elements text, or to a custom element that changes it's\n * own properties or attributes.\n *\n * In these cases if the DOM value changes, but the value set through lit-html\n * bindings hasn't, lit-html won't know to update the DOM value and will leave\n * it alone. If this is not what you want--if you want to overwrite the DOM\n * value with the bound value no matter what--use the `live()` directive:\n *\n * ```js\n * html`<input .value=${live(x)}>`\n * ```\n *\n * `live()` performs a strict equality check against the live DOM value, and if\n * the new value is equal to the live value, does nothing. This means that\n * `live()` should not be used when the binding will cause a type conversion. If\n * you use `live()` with an attribute binding, make sure that only strings are\n * passed in, or the binding will update every render.\n */\nexport const live = directive(LiveDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {LiveDirective};\n"]}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/development/directives/private-async-helpers.js.map b/front_end/third_party/lit-html/package/development/directives/private-async-helpers.js.map
index 4e12d97b4e9a1855e4ebfd60fb418684dfa044af..dce6db01f11199680bec25d7a15d6ee86f5277e6 100644
--- a/front_end/third_party/lit-html/package/development/directives/private-async-helpers.js.map
+++ b/front_end/third_party/lit-html/package/development/directives/private-async-helpers.js.map
@@ -1 +1 @@
-{"version":3,"file":"private-async-helpers.js","sourceRoot":"","sources":["../../src/directives/private-async-helpers.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,+EAA+E;AAC/E,gFAAgF;AAChF,aAAa;AAEb;;;;;GAKG;AACH,MAAM,CAAC,MAAM,UAAU,GAAG,KAAK,EAC7B,QAA0B,EAC1B,QAAwC,EACxC,EAAE;IACF,IAAI,KAAK,EAAE,MAAM,CAAC,IAAI,QAAQ,EAAE;QAC9B,IAAI,CAAC,MAAM,QAAQ,CAAC,CAAC,CAAC,CAAC,KAAK,KAAK,EAAE;YACjC,OAAO;SACR;KACF;AACH,CAAC,CAAC;AAEF;;;;;GAKG;AACH,MAAM,OAAO,aAAa;IAExB,YAAY,GAAM;QAChB,IAAI,CAAC,IAAI,GAAG,GAAG,CAAC;IAClB,CAAC;IACD;;OAEG;IACH,UAAU;QACR,IAAI,CAAC,IAAI,GAAG,SAAS,CAAC;IACxB,CAAC;IACD;;OAEG;IACH,SAAS,CAAC,GAAM;QACd,IAAI,CAAC,IAAI,GAAG,GAAG,CAAC;IAClB,CAAC;IACD;;OAEG;IACH,KAAK;QACH,OAAO,IAAI,CAAC,IAAI,CAAC;IACnB,CAAC;CACF;AAED;;GAEG;AACH,MAAM,OAAO,MAAM;IAAnB;QACU,aAAQ,GAAmB,SAAS,CAAC;QACrC,aAAQ,GAAgB,SAAS,CAAC;IAwB5C,CAAC;IAvBC;;;;;;OAMG;IACH,GAAG;QACD,OAAO,IAAI,CAAC,QAAQ,CAAC;IACvB,CAAC;IACD;;OAEG;IACH,KAAK;;QACH,MAAA,IAAI,CAAC,QAAQ,oCAAb,IAAI,CAAC,QAAQ,GAAK,IAAI,OAAO,CAAC,CAAC,OAAO,EAAE,EAAE,CAAC,CAAC,IAAI,CAAC,QAAQ,GAAG,OAAO,CAAC,CAAC,EAAC;IACxE,CAAC;IACD;;OAEG;IACH,MAAM;;QACJ,MAAA,IAAI,CAAC,QAAQ,+CAAb,IAAI,CAAa,CAAC;QAClB,IAAI,CAAC,QAAQ,GAAG,IAAI,CAAC,QAAQ,GAAG,SAAS,CAAC;IAC5C,CAAC;CACF","sourcesContent":["/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n// Note, this module is not included in package exports so that it's private to\n// our first-party directives. If it ends up being useful, we can open it up and\n// export it.\n\n/**\n * Helper to iterate an AsyncIterable in its own closure.\n * @param iterable The iterable to iterate\n * @param callback The callback to call for each value. If the callback returns\n * `false`, the loop will be broken.\n */\nexport const forAwaitOf = async <T>(\n  iterable: AsyncIterable<T>,\n  callback: (value: T) => Promise<boolean>\n) => {\n  for await (const v of iterable) {\n    if ((await callback(v)) === false) {\n      return;\n    }\n  }\n};\n\n/**\n * Holds a reference to an instance that can be disconnected and reconnected,\n * so that a closure over the ref (e.g. in a then function to a promise) does\n * not strongly hold a ref to the instance. Approximates a WeakRef but must\n * be manually connected & disconnected to the backing instance.\n */\nexport class PseudoWeakRef<T> {\n  private _ref?: T;\n  constructor(ref: T) {\n    this._ref = ref;\n  }\n  /**\n   * Disassociates the ref with the backing instance.\n   */\n  disconnect() {\n    this._ref = undefined;\n  }\n  /**\n   * Reassociates the ref with the backing instance.\n   */\n  reconnect(ref: T) {\n    this._ref = ref;\n  }\n  /**\n   * Retrieves the backing instance (will be undefined when disconnected)\n   */\n  deref() {\n    return this._ref;\n  }\n}\n\n/**\n * A helper to pause and resume waiting on a condition in an async function\n */\nexport class Pauser {\n  private _promise?: Promise<void> = undefined;\n  private _resolve?: () => void = undefined;\n  /**\n   * When paused, returns a promise to be awaited; when unpaused, returns\n   * undefined. Note that in the microtask between the pauser being resumed\n   * an an await of this promise resolving, the pauser could be paused again,\n   * hence callers should check the promise in a loop when awaiting.\n   * @returns A promise to be awaited when paused or undefined\n   */\n  get() {\n    return this._promise;\n  }\n  /**\n   * Creates a promise to be awaited\n   */\n  pause() {\n    this._promise ??= new Promise((resolve) => (this._resolve = resolve));\n  }\n  /**\n   * Resolves the promise which may be awaited\n   */\n  resume() {\n    this._resolve?.();\n    this._promise = this._resolve = undefined;\n  }\n}\n"]}
\ No newline at end of file
+{"version":3,"file":"private-async-helpers.js","sourceRoot":"","sources":["../../src/directives/private-async-helpers.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,+EAA+E;AAC/E,gFAAgF;AAChF,aAAa;AAEb;;;;;GAKG;AACH,MAAM,CAAC,MAAM,UAAU,GAAG,KAAK,EAC7B,QAA0B,EAC1B,QAAwC,EACxC,EAAE;IACF,IAAI,KAAK,EAAE,MAAM,CAAC,IAAI,QAAQ,EAAE;QAC9B,IAAI,CAAC,MAAM,QAAQ,CAAC,CAAC,CAAC,CAAC,KAAK,KAAK,EAAE;YACjC,OAAO;SACR;KACF;AACH,CAAC,CAAC;AAEF;;;;;GAKG;AACH,MAAM,OAAO,aAAa;IAExB,YAAY,GAAM;QAChB,IAAI,CAAC,IAAI,GAAG,GAAG,CAAC;IAClB,CAAC;IACD;;OAEG;IACH,UAAU;QACR,IAAI,CAAC,IAAI,GAAG,SAAS,CAAC;IACxB,CAAC;IACD;;OAEG;IACH,SAAS,CAAC,GAAM;QACd,IAAI,CAAC,IAAI,GAAG,GAAG,CAAC;IAClB,CAAC;IACD;;OAEG;IACH,KAAK;QACH,OAAO,IAAI,CAAC,IAAI,CAAC;IACnB,CAAC;CACF;AAED;;GAEG;AACH,MAAM,OAAO,MAAM;IAAnB;QACU,aAAQ,GAAmB,SAAS,CAAC;QACrC,aAAQ,GAAgB,SAAS,CAAC;IAwB5C,CAAC;IAvBC;;;;;;OAMG;IACH,GAAG;QACD,OAAO,IAAI,CAAC,QAAQ,CAAC;IACvB,CAAC;IACD;;OAEG;IACH,KAAK;;QACH,MAAA,IAAI,CAAC,QAAQ,oCAAb,IAAI,CAAC,QAAQ,GAAK,IAAI,OAAO,CAAC,CAAC,OAAO,EAAE,EAAE,CAAC,CAAC,IAAI,CAAC,QAAQ,GAAG,OAAO,CAAC,CAAC,EAAC;IACxE,CAAC;IACD;;OAEG;IACH,MAAM;;QACJ,MAAA,IAAI,CAAC,QAAQ,oDAAI,CAAC;QAClB,IAAI,CAAC,QAAQ,GAAG,IAAI,CAAC,QAAQ,GAAG,SAAS,CAAC;IAC5C,CAAC;CACF","sourcesContent":["/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n// Note, this module is not included in package exports so that it's private to\n// our first-party directives. If it ends up being useful, we can open it up and\n// export it.\n\n/**\n * Helper to iterate an AsyncIterable in its own closure.\n * @param iterable The iterable to iterate\n * @param callback The callback to call for each value. If the callback returns\n * `false`, the loop will be broken.\n */\nexport const forAwaitOf = async <T>(\n  iterable: AsyncIterable<T>,\n  callback: (value: T) => Promise<boolean>\n) => {\n  for await (const v of iterable) {\n    if ((await callback(v)) === false) {\n      return;\n    }\n  }\n};\n\n/**\n * Holds a reference to an instance that can be disconnected and reconnected,\n * so that a closure over the ref (e.g. in a then function to a promise) does\n * not strongly hold a ref to the instance. Approximates a WeakRef but must\n * be manually connected & disconnected to the backing instance.\n */\nexport class PseudoWeakRef<T> {\n  private _ref?: T;\n  constructor(ref: T) {\n    this._ref = ref;\n  }\n  /**\n   * Disassociates the ref with the backing instance.\n   */\n  disconnect() {\n    this._ref = undefined;\n  }\n  /**\n   * Reassociates the ref with the backing instance.\n   */\n  reconnect(ref: T) {\n    this._ref = ref;\n  }\n  /**\n   * Retrieves the backing instance (will be undefined when disconnected)\n   */\n  deref() {\n    return this._ref;\n  }\n}\n\n/**\n * A helper to pause and resume waiting on a condition in an async function\n */\nexport class Pauser {\n  private _promise?: Promise<void> = undefined;\n  private _resolve?: () => void = undefined;\n  /**\n   * When paused, returns a promise to be awaited; when unpaused, returns\n   * undefined. Note that in the microtask between the pauser being resumed\n   * an an await of this promise resolving, the pauser could be paused again,\n   * hence callers should check the promise in a loop when awaiting.\n   * @returns A promise to be awaited when paused or undefined\n   */\n  get() {\n    return this._promise;\n  }\n  /**\n   * Creates a promise to be awaited\n   */\n  pause() {\n    this._promise ??= new Promise((resolve) => (this._resolve = resolve));\n  }\n  /**\n   * Resolves the promise which may be awaited\n   */\n  resume() {\n    this._resolve?.();\n    this._promise = this._resolve = undefined;\n  }\n}\n"]}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/development/directives/ref.d.ts b/front_end/third_party/lit-html/package/development/directives/ref.d.ts
index 8bbdd84c7c18bec80f86150035519990d2ace589..f31fb09984a8e568ccc9656fec721259a7717cd8 100644
--- a/front_end/third_party/lit-html/package/development/directives/ref.d.ts
+++ b/front_end/third_party/lit-html/package/development/directives/ref.d.ts
@@ -24,7 +24,7 @@ export declare type RefOrCallback = Ref | ((el: Element | undefined) => void);
 declare class RefDirective extends AsyncDirective {
     private _element?;
     private _ref?;
-    private _context;
+    private _context?;
     render(_ref: RefOrCallback): symbol;
     update(part: ElementPart, [ref]: Parameters<this['render']>): symbol;
     private _updateRefValue;




diff --git a/front_end/third_party/lit-html/package/development/directives/ref.d.ts.map b/front_end/third_party/lit-html/package/development/directives/ref.d.ts.map
index 79938c2667cc5231d01b1aeea0acd11f880352cd..db599943d3cb06bdff4235b0efbcb6bd03727d08 100644
--- a/front_end/third_party/lit-html/package/development/directives/ref.d.ts.map
+++ b/front_end/third_party/lit-html/package/development/directives/ref.d.ts.map
@@ -1 +1 @@
-{"version":3,"file":"ref.d.ts","sourceRoot":"","sources":["../../src/directives/ref.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,OAAO,EAAU,WAAW,EAAC,MAAM,gBAAgB,CAAC;AACpD,OAAO,EAAY,cAAc,EAAC,MAAM,uBAAuB,CAAC;AAEhE;;GAEG;AACH,eAAO,MAAM,SAAS,2BAAkC,CAAC;AAEzD;;GAEG;AACH,cAAM,GAAG,CAAC,CAAC,GAAG,OAAO;IACnB;;;OAGG;IACH,QAAQ,CAAC,KAAK,CAAC,EAAE,CAAC,CAAC;CACpB;AAED,YAAY,EAAC,GAAG,EAAC,CAAC;AAYlB,oBAAY,aAAa,GAAG,GAAG,GAAG,CAAC,CAAC,EAAE,EAAE,OAAO,GAAG,SAAS,KAAK,IAAI,CAAC,CAAC;AAEtE,cAAM,YAAa,SAAQ,cAAc;IACvC,OAAO,CAAC,QAAQ,CAAC,CAAU;IAC3B,OAAO,CAAC,IAAI,CAAC,CAAgB;IAC7B,OAAO,CAAC,QAAQ,CAAU;IAE1B,MAAM,CAAC,IAAI,EAAE,aAAa;IAIjB,MAAM,CAAC,IAAI,EAAE,WAAW,EAAE,CAAC,GAAG,CAAC,EAAE,UAAU,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;IAiBpE,OAAO,CAAC,eAAe;IAqBvB,OAAO,KAAK,kBAAkB,GAI7B;IAEQ,YAAY;IAUZ,WAAW;CAKrB;AAED;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AACH,eAAO,MAAM,GAAG,yFAA0B,CAAC;AAE3C;;;GAGG;AACH,YAAY,EAAC,YAAY,EAAC,CAAC"}
\ No newline at end of file
+{"version":3,"file":"ref.d.ts","sourceRoot":"","sources":["../../src/directives/ref.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,OAAO,EAAU,WAAW,EAAC,MAAM,gBAAgB,CAAC;AACpD,OAAO,EAAY,cAAc,EAAC,MAAM,uBAAuB,CAAC;AAEhE;;GAEG;AACH,eAAO,MAAM,SAAS,2BAAkC,CAAC;AAEzD;;GAEG;AACH,cAAM,GAAG,CAAC,CAAC,GAAG,OAAO;IACnB;;;OAGG;IACH,QAAQ,CAAC,KAAK,CAAC,EAAE,CAAC,CAAC;CACpB;AAED,YAAY,EAAC,GAAG,EAAC,CAAC;AAgBlB,oBAAY,aAAa,GAAG,GAAG,GAAG,CAAC,CAAC,EAAE,EAAE,OAAO,GAAG,SAAS,KAAK,IAAI,CAAC,CAAC;AAEtE,cAAM,YAAa,SAAQ,cAAc;IACvC,OAAO,CAAC,QAAQ,CAAC,CAAU;IAC3B,OAAO,CAAC,IAAI,CAAC,CAAgB;IAC7B,OAAO,CAAC,QAAQ,CAAC,CAAS;IAE1B,MAAM,CAAC,IAAI,EAAE,aAAa;IAIjB,MAAM,CAAC,IAAI,EAAE,WAAW,EAAE,CAAC,GAAG,CAAC,EAAE,UAAU,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;IAiBpE,OAAO,CAAC,eAAe;IA+BvB,OAAO,KAAK,kBAAkB,GAM7B;IAEQ,YAAY;IAUZ,WAAW;CAKrB;AAED;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AACH,eAAO,MAAM,GAAG,yFAA0B,CAAC;AAE3C;;;GAGG;AACH,YAAY,EAAC,YAAY,EAAC,CAAC"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/development/directives/ref.js b/front_end/third_party/lit-html/package/development/directives/ref.js
index 400d9c1ddb12ae1e4a34f84ba4ecaef123f29b69..586ce26ab427d6230d2df68e512c2695d848293b 100644
--- a/front_end/third_party/lit-html/package/development/directives/ref.js
+++ b/front_end/third_party/lit-html/package/development/directives/ref.js
@@ -16,8 +16,10 @@ class Ref {
 }
 // When callbacks are used for refs, this map tracks the last value the callback
 // was called with, for ensuring a directive doesn't clear the ref if the ref
-// has already been rendered to a new spot
+// has already been rendered to a new spot. It is double-keyed on both the
-const lastElementForCallback = new WeakMap();
+// context (`options.host`) and the callback, since we auto-bind class methods
+// to `options.host`.
+const lastElementForContextAndCallback = new WeakMap();
 class RefDirective extends AsyncDirective {
     render(_ref) {
         return nothing;
@@ -40,14 +42,24 @@         }
         return nothing;
     }
     _updateRefValue(element) {
+        var _a;
         if (typeof this._ref === 'function') {
             // If the current ref was called with a previous value, call with
             // `undefined`; We do this to ensure callbacks are called in a consistent
             // way regardless of whether a ref might be moving up in the tree (in
             // which case it would otherwise be called with the new value before the
             // previous one unsets it) and down in the tree (where it would be unset
+            // before being set). Note that element lookup is keyed by
+            // both the context and the callback, since we allow passing unbound
+            // functions that are called on options.host, and we want to treat
+export const createRef = () => new Ref();
  * SPDX-License-Identifier: BSD-3-Clause
- * @license
+            const context = (_a = this._context) !== null && _a !== void 0 ? _a : globalThis;
+            let lastElementForCallback = lastElementForContextAndCallback.get(context);
+            if (lastElementForCallback === undefined) {
+                lastElementForCallback = new WeakMap();
+                lastElementForContextAndCallback.set(context, lastElementForCallback);
+            }
             if (lastElementForCallback.get(this._ref) !== undefined) {
                 this._ref.call(this._context, undefined);
             }
@@ -62,10 +74,11 @@             this._ref.value = element;
         }
     }
     get _lastElementForRef() {
-        var _a;
+        var _a, _b, _c;
         return typeof this._ref === 'function'
-            ? lastElementForCallback.get(this._ref)
+            ? (_b = lastElementForContextAndCallback
+                .get((_a = this._context) !== null && _a !== void 0 ? _a : globalThis)) === null || _b === void 0 ? void 0 : _b.get(this._ref)
-            : (_a = this._ref) === null || _a === void 0 ? void 0 : _a.value;
+            : (_c = this._ref) === null || _c === void 0 ? void 0 : _c.value;
     }
     disconnected() {
         // Only clear the box if our element is still the one in it (i.e. another




diff --git a/front_end/third_party/lit-html/package/development/directives/ref.js.map b/front_end/third_party/lit-html/package/development/directives/ref.js.map
index 500985673721d97cd129d73357443ca6692c02ab..c80ec3110f2c562236b311cdf299f124cc534a68 100644
--- a/front_end/third_party/lit-html/package/development/directives/ref.js.map
+++ b/front_end/third_party/lit-html/package/development/directives/ref.js.map
@@ -1 +1 @@
-{"version":3,"file":"ref.js","sourceRoot":"","sources":["../../src/directives/ref.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,OAAO,EAAC,OAAO,EAAc,MAAM,gBAAgB,CAAC;AACpD,OAAO,EAAC,SAAS,EAAE,cAAc,EAAC,MAAM,uBAAuB,CAAC;AAEhE;;GAEG;AACH,MAAM,CAAC,MAAM,SAAS,GAAG,GAAgB,EAAE,CAAC,IAAI,GAAG,EAAK,CAAC;AAEzD;;GAEG;AACH,MAAM,GAAG;CAMR;AAQD,gFAAgF;AAChF,6EAA6E;AAC7E,0CAA0C;AAC1C,MAAM,sBAAsB,GAC1B,IAAI,OAAO,EAAE,CAAC;AAIhB,MAAM,YAAa,SAAQ,cAAc;IAKvC,MAAM,CAAC,IAAmB;QACxB,OAAO,OAAO,CAAC;IACjB,CAAC;IAEQ,MAAM,CAAC,IAAiB,EAAE,CAAC,GAAG,CAA6B;;QAClE,MAAM,UAAU,GAAG,GAAG,KAAK,IAAI,CAAC,IAAI,CAAC;QACrC,IAAI,UAAU,IAAI,IAAI,CAAC,IAAI,KAAK,SAAS,EAAE;YACzC,+CAA+C;YAC/C,iCAAiC;YACjC,IAAI,CAAC,eAAe,CAAC,SAAS,CAAC,CAAC;SACjC;QACD,IAAI,UAAU,IAAI,IAAI,CAAC,kBAAkB,KAAK,IAAI,CAAC,QAAQ,EAAE;YAC3D,uDAAuD;YACvD,+CAA+C;YAC/C,IAAI,CAAC,IAAI,GAAG,GAAG,CAAC;YAChB,IAAI,CAAC,QAAQ,GAAG,MAAA,IAAI,CAAC,OAAO,0CAAE,IAAI,CAAC;YACnC,IAAI,CAAC,eAAe,CAAC,CAAC,IAAI,CAAC,QAAQ,GAAG,IAAI,CAAC,OAAO,CAAC,CAAC,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;;;;;;;;;;;;;;;;;;;;;;GAwBG;AACH,MAAM,CAAC,MAAM,GAAG,GAAG,SAAS,CAAC,YAAY,CAAC,CAAC","sourcesContent":["/**\n * @license\n * Copyright 2020 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\nimport {nothing, ElementPart} from '../lit-html.js';\nimport {directive, AsyncDirective} from '../async-directive.js';\n\n/**\n * Creates a new Ref object, which is container for a reference to an element.\n */\nexport const createRef = <T = Element>() => new Ref<T>();\n\n/**\n * An object that holds a ref value.\n */\nclass Ref<T = Element> {\n  /**\n   * The current Element value of the ref, or else `undefined` if the ref is no\n   * longer rendered.\n   */\n  readonly value?: T;\n}\n\nexport type {Ref};\n\ninterface RefInternal {\n  value: Element | undefined;\n}\n\n// When callbacks are used for refs, this map tracks the last value the callback\n// was called with, for ensuring a directive doesn't clear the ref if the ref\n// has already been rendered to a new spot\nconst lastElementForCallback: WeakMap<Function, Element | undefined> =\n  new WeakMap();\n\nexport type RefOrCallback = Ref | ((el: Element | undefined) => void);\n\nclass RefDirective extends AsyncDirective {\n  private _element?: Element;\n  private _ref?: RefOrCallback;\n  private _context: unknown;\n\n  render(_ref: RefOrCallback) {\n    return nothing;\n  }\n\n  override update(part: ElementPart, [ref]: Parameters<this['render']>) {\n    const refChanged = ref !== this._ref;\n    if (refChanged && this._ref !== undefined) {\n      // The ref passed to the directive has changed;\n      // unset the previous ref's value\n      this._updateRefValue(undefined);\n    }\n    if (refChanged || this._lastElementForRef !== this._element) {\n      // We either got a new ref or this is the first render;\n      // store the ref/element & update the ref value\n      this._ref = ref;\n      this._context = part.options?.host;\n      this._updateRefValue((this._element = part.element));\n    }\n    return nothing;\n  }\n\n  private _updateRefValue(element: Element | undefined) {\n    if (typeof this._ref === 'function') {\n      // If the current ref was called with a previous value, call with\n      // `undefined`; We do this to ensure callbacks are called in a consistent\n      // way regardless of whether a ref might be moving up in the tree (in\n      // which case it would otherwise be called with the new value before the\n      // previous one unsets it) and down in the tree (where it would be unset\n      // before being set)\n      if (lastElementForCallback.get(this._ref) !== undefined) {\n        this._ref.call(this._context, undefined);\n      }\n      lastElementForCallback.set(this._ref, element);\n      // Call the ref with the new element value\n      if (element !== undefined) {\n        this._ref.call(this._context, element);\n      }\n    } else {\n      (this._ref as RefInternal)!.value = element;\n    }\n  }\n\n  private get _lastElementForRef() {\n    return typeof this._ref === 'function'\n      ? lastElementForCallback.get(this._ref)\n      : this._ref?.value;\n  }\n\n  override disconnected() {\n    // Only clear the box if our element is still the one in it (i.e. another\n    // directive instance hasn't rendered its element to it before us); that\n    // only happens in the event of the directive being cleared (not via manual\n    // disconnection)\n    if (this._lastElementForRef === this._element) {\n      this._updateRefValue(undefined);\n    }\n  }\n\n  override reconnected() {\n    // If we were manually disconnected, we can safely put our element back in\n    // the box, since no rendering could have occurred to change its state\n    this._updateRefValue(this._element);\n  }\n}\n\n/**\n * Sets the value of a Ref object or calls a ref callback with the element it's\n * bound to.\n *\n * A Ref object acts as a container for a reference to an element. A ref\n * callback is a function that takes an element as its only argument.\n *\n * The ref directive sets the value of the Ref object or calls the ref callback\n * during rendering, if the referenced element changed.\n *\n * Note: If a ref callback is rendered to a different element position or is\n * removed in a subsequent render, it will first be called with `undefined`,\n * followed by another call with the new element it was rendered to (if any).\n *\n * ```js\n * // Using Ref object\n * const inputRef = createRef();\n * render(html`<input ${ref(inputRef)}>`, container);\n * inputRef.value.focus();\n *\n * // Using callback\n * const callback = (inputElement) => inputElement.focus();\n * render(html`<input ${ref(callback)}>`, container);\n * ```\n */\nexport const ref = directive(RefDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {RefDirective};\n"]}
\ No newline at end of file
+{"version":3,"file":"ref.js","sourceRoot":"","sources":["../../src/directives/ref.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,OAAO,EAAC,OAAO,EAAc,MAAM,gBAAgB,CAAC;AACpD,OAAO,EAAC,SAAS,EAAE,cAAc,EAAC,MAAM,uBAAuB,C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AClB,0EAA0E;QAC1E,sEAAsE;QACtE,IAAI,CAAC,eAAe,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;IACtC,CAAC;CACF;AAED;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AACH,MAAM,CAAC,MAAM,GAAG,GAAG,SAAS,CAAC,YAAY,CAAC,CAAC","sourcesContent":["/**\n * @license\n * Copyright 2020 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\nimport {nothing, ElementPart} from '../lit-html.js';\nimport {directive, AsyncDirective} from '../async-directive.js';\n\n/**\n * Creates a new Ref object, which is container for a reference to an element.\n */\nexport const createRef = <T = Element>() => new Ref<T>();\n\n/**\n * An object that holds a ref value.\n */\nclass Ref<T = Element> {\n  /**\n   * The current Element value of the ref, or else `undefined` if the ref is no\n   * longer rendered.\n   */\n  readonly value?: T;\n}\n\nexport type {Ref};\n\ninterface RefInternal {\n  value: Element | undefined;\n}\n\n// When callbacks are used for refs, this map tracks the last value the callback\n// was called with, for ensuring a directive doesn't clear the ref if the ref\n// has already been rendered to a new spot. It is double-keyed on both the\n// context (`options.host`) and the callback, since we auto-bind class methods\n// to `options.host`.\nconst lastElementForContextAndCallback: WeakMap<\n  object,\n  WeakMap<Function, Element | undefined>\n> = new WeakMap();\n\nexport type RefOrCallback = Ref | ((el: Element | undefined) => void);\n\nclass RefDirective extends AsyncDirective {\n  private _element?: Element;\n  private _ref?: RefOrCallback;\n  private _context?: object;\n\n  render(_ref: RefOrCallback) {\n    return nothing;\n  }\n\n  override update(part: ElementPart, [ref]: Parameters<this['render']>) {\n    const refChanged = ref !== this._ref;\n    if (refChanged && this._ref !== undefined) {\n      // The ref passed to the directive has changed;\n      // unset the previous ref's value\n      this._updateRefValue(undefined);\n    }\n    if (refChanged || this._lastElementForRef !== this._element) {\n      // We either got a new ref or this is the first render;\n      // store the ref/element & update the ref value\n      this._ref = ref;\n      this._context = part.options?.host;\n      this._updateRefValue((this._element = part.element));\n    }\n    return nothing;\n  }\n\n  private _updateRefValue(element: Element | undefined) {\n    if (typeof this._ref === 'function') {\n      // If the current ref was called with a previous value, call with\n      // `undefined`; We do this to ensure callbacks are called in a consistent\n      // way regardless of whether a ref might be moving up in the tree (in\n      // which case it would otherwise be called with the new value before the\n      // previous one unsets it) and down in the tree (where it would be unset\n      // before being set). Note that element lookup is keyed by\n      // both the context and the callback, since we allow passing unbound\n      // functions that are called on options.host, and we want to treat\n      // these as unique \"instances\" of a function.\n      const context = this._context ?? globalThis;\n      let lastElementForCallback =\n        lastElementForContextAndCallback.get(context);\n      if (lastElementForCallback === undefined) {\n        lastElementForCallback = new WeakMap();\n        lastElementForContextAndCallback.set(context, lastElementForCallback);\n      }\n      if (lastElementForCallback.get(this._ref) !== undefined) {\n        this._ref.call(this._context, undefined);\n      }\n      lastElementForCallback.set(this._ref, element);\n      // Call the ref with the new element value\n      if (element !== undefined) {\n        this._ref.call(this._context, element);\n      }\n    } else {\n      (this._ref as RefInternal)!.value = element;\n    }\n  }\n\n  private get _lastElementForRef() {\n    return typeof this._ref === 'function'\n      ? lastElementForContextAndCallback\n          .get(this._context ?? globalThis)\n          ?.get(this._ref)\n      : this._ref?.value;\n  }\n\n  override disconnected() {\n    // Only clear the box if our element is still the one in it (i.e. another\n    // directive instance hasn't rendered its element to it before us); that\n    // only happens in the event of the directive being cleared (not via manual\n    // disconnection)\n    if (this._lastElementForRef === this._element) {\n      this._updateRefValue(undefined);\n    }\n  }\n\n  override reconnected() {\n    // If we were manually disconnected, we can safely put our element back in\n    // the box, since no rendering could have occurred to change its state\n    this._updateRefValue(this._element);\n  }\n}\n\n/**\n * Sets the value of a Ref object or calls a ref callback with the element it's\n * bound to.\n *\n * A Ref object acts as a container for a reference to an element. A ref\n * callback is a function that takes an element as its only argument.\n *\n * The ref directive sets the value of the Ref object or calls the ref callback\n * during rendering, if the referenced element changed.\n *\n * Note: If a ref callback is rendered to a different element position or is\n * removed in a subsequent render, it will first be called with `undefined`,\n * followed by another call with the new element it was rendered to (if any).\n *\n * ```js\n * // Using Ref object\n * const inputRef = createRef();\n * render(html`<input ${ref(inputRef)}>`, container);\n * inputRef.value.focus();\n *\n * // Using callback\n * const callback = (inputElement) => inputElement.focus();\n * render(html`<input ${ref(callback)}>`, container);\n * ```\n */\nexport const ref = directive(RefDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {RefDirective};\n"]}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/development/directives/style-map.d.ts b/front_end/third_party/lit-html/package/development/directives/style-map.d.ts
index 29c6cfe33a59cb58f9bf80eb81d83b2b9b085f2f..dd74ecededf7f6deed4c9430754c4a35bb87f192 100644
--- a/front_end/third_party/lit-html/package/development/directives/style-map.d.ts
+++ b/front_end/third_party/lit-html/package/development/directives/style-map.d.ts
@@ -13,12 +13,12 @@  * `'background-color'`, or a valid JavaScript camel case property name
  * for CSSStyleDeclaration like `backgroundColor`.
  */
 export interface StyleInfo {
-    readonly [name: string]: string | undefined | null;
+    [name: string]: string | undefined | null;
 }
 declare class StyleMapDirective extends Directive {
     _previousStyleProperties?: Set<string>;
     constructor(partInfo: PartInfo);
-/**
+ * Copyright 2018 Google LLC
  *
     update(part: AttributePart, [styleInfo]: DirectiveParameters<this>): string | typeof noChange;
 }
@@ -26,24 +26,26 @@ /**
  * A directive that applies CSS properties to an element.
  *
  * `styleMap` can only be used in the `style` attribute and must be the only
+ * expression in the attribute. It takes the property names in the
+ * {@link StyleInfo styleInfo} object and adds the property values as CSS
+ * SPDX-License-Identifier: BSD-3-Clause
  * @license
+ * SPDX-License-Identifier: BSD-3-Clause
  * Copyright 2018 Google LLC
- * @license
+ * SPDX-License-Identifier: BSD-3-Clause
  * SPDX-License-Identifier: BSD-3-Clause
- * @license
+ * SPDX-License-Identifier: BSD-3-Clause
  */
- * @license
+ * SPDX-License-Identifier: BSD-3-Clause
 import { AttributePart, noChange } from '../lit-html.js';
- * assumed to be camelCased JavaScript property names and set on the element's
- * style object using property assignment, allowing the style object to
- * translate JavaScript-style names to CSS property names.
  *
  * For example `styleMap({backgroundColor: 'red', 'border-top': '5px', '--size':
  * '0'})` sets the `background-color`, `border-top` and `--size` properties.
  *
  * @param styleInfo
+ * @see {@link https://lit.dev/docs/templates/directives/#stylemap styleMap code samples on Lit.dev}
  */
-export declare const styleMap: (styleInfo: StyleInfo) => import("../directive.js").DirectiveResult<typeof StyleMapDirective>;
+export declare const styleMap: (styleInfo: Readonly<StyleInfo>) => import("../directive.js").DirectiveResult<typeof StyleMapDirective>;
 /**
  * The type of the class that powers this directive. Necessary for naming the
  * directive's return type.




diff --git a/front_end/third_party/lit-html/package/development/directives/style-map.d.ts.map b/front_end/third_party/lit-html/package/development/directives/style-map.d.ts.map
index d154524f9692d5bfc5fc39038e9f39a685fc097f..220c753bdc870ad51fa51076b8a60945a2e396d0 100644
--- a/front_end/third_party/lit-html/package/development/directives/style-map.d.ts.map
+++ b/front_end/third_party/lit-html/package/development/directives/style-map.d.ts.map
@@ -1 +1 @@
-{"version":3,"file":"style-map.d.ts","sourceRoot":"","sources":["../../src/directives/style-map.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAC,aAAa,EAAE,QAAQ,EAAC,MAAM,gBAAgB,CAAC;AACvD,OAAO,EAEL,SAAS,EACT,mBAAmB,EACnB,QAAQ,EAET,MAAM,iBAAiB,CAAC;AAEzB;;;;;;GAMG;AACH,MAAM,WAAW,SAAS;IACxB,QAAQ,EAAE,IAAI,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS,GAAG,IAAI,CAAC;CACpD;AAED,cAAM,iBAAkB,SAAQ,SAAS;IACvC,wBAAwB,CAAC,EAAE,GAAG,CAAC,MAAM,CAAC,CAAC;gBAE3B,QAAQ,EAAE,QAAQ;IAc9B,MAAM,CAAC,SAAS,EAAE,SAAS;IAoBlB,MAAM,CAAC,IAAI,EAAE,aAAa,EAAE,CAAC,SAAS,CAAC,EAAE,mBAAmB,CAAC,IAAI,CAAC;CA4C5E;AAED;;;;;;;;;;;;;;;;GAgBG;AACH,eAAO,MAAM,QAAQ,+FAA+B,CAAC;AAErD;;;GAGG;AACH,YAAY,EAAC,iBAAiB,EAAC,CAAC"}
\ No newline at end of file
+{"version":3,"file":"style-map.d.ts","sourceRoot":"","sources":["../../src/directives/style-map.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAC,aAAa,EAAE,QAAQ,EAAC,MAAM,gBAAgB,CAAC;AACvD,OAAO,EAEL,SAAS,EACT,mBAAmB,EACnB,QAAQ,EAET,MAAM,iBAAiB,CAAC;AAEzB;;;;;;GAMG;AACH,MAAM,WAAW,SAAS;IACxB,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS,GAAG,IAAI,CAAC;CAC3C;AAED,cAAM,iBAAkB,SAAQ,SAAS;IACvC,wBAAwB,CAAC,EAAE,GAAG,CAAC,MAAM,CAAC,CAAC;gBAE3B,QAAQ,EAAE,QAAQ;IAc9B,MAAM,CAAC,SAAS,EAAE,QAAQ,CAAC,SAAS,CAAC;IAoB5B,MAAM,CAAC,IAAI,EAAE,aAAa,EAAE,CAAC,SAAS,CAAC,EAAE,mBAAmB,CAAC,IAAI,CAAC;CA4C5E;AAED;;;;;;;;;;;;;;;;;GAiBG;AACH,eAAO,MAAM,QAAQ,yGAA+B,CAAC;AAErD;;;GAGG;AACH,YAAY,EAAC,iBAAiB,EAAC,CAAC"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/development/directives/style-map.js b/front_end/third_party/lit-html/package/development/directives/style-map.js
index 03acb66ae8eacaa01d7c5d8b778a8f6a3e508f37..45de8d5e099cf5f8e57fc465a374ea27dc743f37 100644
--- a/front_end/third_party/lit-html/package/development/directives/style-map.js
+++ b/front_end/third_party/lit-html/package/development/directives/style-map.js
@@ -83,23 +83,24 @@ /**
  * A directive that applies CSS properties to an element.
  *
  * `styleMap` can only be used in the `style` attribute and must be the only
- * expression in the attribute. It takes the property names in the `styleInfo`
- * object and adds the property values as CSS properties. Property names with
-import { directive, Directive, PartType, } from '../directive.js';
+class StyleMapDirective extends Directive {
  * Copyright 2018 Google LLC
-import { directive, Directive, PartType, } from '../directive.js';
+class StyleMapDirective extends Directive {
  * SPDX-License-Identifier: BSD-3-Clause
-import { directive, Directive, PartType, } from '../directive.js';
+class StyleMapDirective extends Directive {
  */
-import { directive, Directive, PartType, } from '../directive.js';
+class StyleMapDirective extends Directive {
 import { noChange } from '../lit-html.js';
+class StyleMapDirective extends Directive {
 import { directive, Directive, PartType, } from '../directive.js';
-import { directive, Directive, PartType, } from '../directive.js';
+ * and set on the element's style object using property assignment, allowing the
+ * style object to translate JavaScript-style names to CSS property names.
  *
  * For example `styleMap({backgroundColor: 'red', 'border-top': '5px', '--size':
  * '0'})` sets the `background-color`, `border-top` and `--size` properties.
  *
 class StyleMapDirective extends Directive {
+    constructor(partInfo) {
  */
 export const styleMap = directive(StyleMapDirective);
 //# sourceMappingURL=style-map.js.map
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/development/directives/style-map.js.map b/front_end/third_party/lit-html/package/development/directives/style-map.js.map
index 3ee053c218f501fbdb80b862c7b3aa31acbfa294..7e2cf9cd66cf2f6c6267783ef91923880d19d94c 100644
--- a/front_end/third_party/lit-html/package/development/directives/style-map.js.map
+++ b/front_end/third_party/lit-html/package/development/directives/style-map.js.map
@@ -1 +1 @@
-{"version":3,"file":"style-map.js","sourceRoot":"","sources":["../../src/directives/style-map.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAgB,QAAQ,EAAC,MAAM,gBAAgB,CAAC;AACvD,OAAO,EACL,SAAS,EACT,SAAS,EAGT,QAAQ,GACT,MAAM,iBAAiB,CAAC;AAazB,MAAM,iBAAkB,SAAQ,SAAS;IAGvC,YAAY,QAAkB;;QAC5B,KAAK,CAAC,QAAQ,CAAC,CAAC;QAChB,IACE,QAAQ,CAAC,IAAI,KAAK,QAAQ,CAAC,SAAS;YACpC,QAAQ,C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E;YAC9C,wDAAwD;YACxD,IAAI,SAAS,CAAC,IAAI,CAAC,IAAI,IAAI,EAAE;gBAC3B,IAAI,CAAC,wBAAyB,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC;gBAC5C,IAAI,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE;oBACtB,KAAK,CAAC,cAAc,CAAC,IAAI,CAAC,CAAC;iBAC5B;qBAAM;oBACL,kEAAkE;oBAClE,+GAA+G;oBAC/G,8DAA8D;oBAC7D,KAAa,CAAC,IAAI,CAAC,GAAG,EAAE,CAAC;iBAC3B;aACF;QACH,CAAC,CAAC,CAAC;QAEH,2BAA2B;QAC3B,KAAK,MAAM,IAAI,IAAI,SAAS,EAAE;YAC5B,MAAM,KAAK,GAAG,SAAS,CAAC,IAAI,CAAC,CAAC;YAC9B,IAAI,KAAK,IAAI,IAAI,EAAE;gBACjB,IAAI,CAAC,wBAAwB,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC;gBACxC,IAAI,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE;oBACtB,KAAK,CAAC,WAAW,CAAC,IAAI,EAAE,KAAK,CAAC,CAAC;iBAChC;qBAAM;oBACL,8DAA8D;oBAC7D,KAAa,CAAC,IAAI,CAAC,GAAG,KAAK,CAAC;iBAC9B;aACF;SACF;QACD,OAAO,QAAQ,CAAC;IAClB,CAAC;CACF;AAED;;;;;;;;;;;;;;;;GAgBG;AACH,MAAM,CAAC,MAAM,QAAQ,GAAG,SAAS,CAAC,iBAAiB,CAAC,CAAC","sourcesContent":["/**\n * @license\n * Copyright 2018 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {AttributePart, noChange} from '../lit-html.js';\nimport {\n  directive,\n  Directive,\n  DirectiveParameters,\n  PartInfo,\n  PartType,\n} from '../directive.js';\n\n/**\n * A key-value set of CSS properties and values.\n *\n * The key should be either a valid CSS property name string, like\n * `'background-color'`, or a valid JavaScript camel case property name\n * for CSSStyleDeclaration like `backgroundColor`.\n */\nexport interface StyleInfo {\n  readonly [name: string]: string | undefined | null;\n}\n\nclass StyleMapDirective extends Directive {\n  _previousStyleProperties?: Set<string>;\n\n  constructor(partInfo: PartInfo) {\n    super(partInfo);\n    if (\n      partInfo.type !== PartType.ATTRIBUTE ||\n      partInfo.name !== 'style' ||\n      (partInfo.strings?.length as number) > 2\n    ) {\n      throw new Error(\n        'The `styleMap` directive must be used in the `style` attribute ' +\n          'and must be the only part in the attribute.'\n      );\n    }\n  }\n\n  render(styleInfo: StyleInfo) {\n    return Object.keys(styleInfo).reduce((style, prop) => {\n      const value = styleInfo[prop];\n      if (value == null) {\n        return style;\n      }\n      // Convert property names from camel-case to dash-case, i.e.:\n      //  `backgroundColor` -> `background-color`\n      // Vendor-prefixed names need an extra `-` appended to front:\n      //  `webkitAppearance` -> `-webkit-appearance`\n      // Exception is any property name containing a dash, including\n      // custom properties; we assume these are already dash-cased i.e.:\n      //  `--my-button-color` --> `--my-button-color`\n      prop = prop\n        .replace(/(?:^(webkit|moz|ms|o)|)(?=[A-Z])/g, '-$&')\n        .toLowerCase();\n      return style + `${prop}:${value};`;\n    }, '');\n  }\n\n  override update(part: AttributePart, [styleInfo]: DirectiveParameters<this>) {\n    const {style} = part.element as HTMLElement;\n\n    if (this._previousStyleProperties === undefined) {\n      this._previousStyleProperties = new Set();\n      for (const name in styleInfo) {\n        this._previousStyleProperties.add(name);\n      }\n      return this.render(styleInfo);\n    }\n\n    // Remove old properties that no longer exist in styleInfo\n    // We use forEach() instead of for-of so that re don't require down-level\n    // iteration.\n    this._previousStyleProperties!.forEach((name) => {\n      // If the name isn't in styleInfo or it's null/undefined\n      if (styleInfo[name] == null) {\n        this._previousStyleProperties!.delete(name);\n        if (name.includes('-')) {\n          style.removeProperty(name);\n        } else {\n          // Note reset using empty string (vs null) as IE11 does not always\n          // reset via null (https://developer.mozilla.org/en-US/docs/Web/API/ElementCSSInlineStyle/style#setting_styles)\n          // eslint-disable-next-line @typescript-eslint/no-explicit-any\n          (style as any)[name] = '';\n        }\n      }\n    });\n\n    // Add or update properties\n    for (const name in styleInfo) {\n      const value = styleInfo[name];\n      if (value != null) {\n        this._previousStyleProperties.add(name);\n        if (name.includes('-')) {\n          style.setProperty(name, value);\n        } else {\n          // eslint-disable-next-line @typescript-eslint/no-explicit-any\n          (style as any)[name] = value;\n        }\n      }\n    }\n    return noChange;\n  }\n}\n\n/**\n * A directive that applies CSS properties to an element.\n *\n * `styleMap` can only be used in the `style` attribute and must be the only\n * expression in the attribute. It takes the property names in the `styleInfo`\n * object and adds the property values as CSS properties. Property names with\n * dashes (`-`) are assumed to be valid CSS property names and set on the\n * element's style object using `setProperty()`. Names without dashes are\n * assumed to be camelCased JavaScript property names and set on the element's\n * style object using property assignment, allowing the style object to\n * translate JavaScript-style names to CSS property names.\n *\n * For example `styleMap({backgroundColor: 'red', 'border-top': '5px', '--size':\n * '0'})` sets the `background-color`, `border-top` and `--size` properties.\n *\n * @param styleInfo\n */\nexport const styleMap = directive(StyleMapDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {StyleMapDirective};\n"]}
\ No newline at end of file
+{"version":3,"file":"style-map.js","sourceRoot":"","sources":["../../src/directives/style-map.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAgB,QAAQ,EAAC,MAAM,gBAAgB,CAAC;AACvD,OAAO,EACL,SAAS,EACT,SAAS,EAGT,QAAQ,GACT,MAAM,iBAAiB,CAAC;AAazB,MAAM,iBAAkB,SAAQ,SAAS;IAGvC,YAAY,QAAkB;;QAC5B,KAAK,CAAC,QAAQ,CAAC,CAAC;QAChB,IACE,QAAQ,CAAC,IAAI,KAAK,QAAQ,CAAC,SAAS;YACpC,QAAQ,CAAC,IAAI,KAAK,OAAO;YACzB,CAAC,MAAA,QAAQ,CAAC,OAAO,0CAAE,MAAiB,IAAG,CAAC,EACxC;YACA,MAAM,IAAI,KAAK,CACb,iEAAiE;gBAC/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C;gBAC5C,IAAI,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE;oBACtB,KAAK,CAAC,cAAc,CAAC,IAAI,CAAC,CAAC;iBAC5B;qBAAM;oBACL,kEAAkE;oBAClE,+GAA+G;oBAC/G,8DAA8D;oBAC7D,KAAa,CAAC,IAAI,CAAC,GAAG,EAAE,CAAC;iBAC3B;aACF;QACH,CAAC,CAAC,CAAC;QAEH,2BAA2B;QAC3B,KAAK,MAAM,IAAI,IAAI,SAAS,EAAE;YAC5B,MAAM,KAAK,GAAG,SAAS,CAAC,IAAI,CAAC,CAAC;YAC9B,IAAI,KAAK,IAAI,IAAI,EAAE;gBACjB,IAAI,CAAC,wBAAwB,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC;gBACxC,IAAI,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE;oBACtB,KAAK,CAAC,WAAW,CAAC,IAAI,EAAE,KAAK,CAAC,CAAC;iBAChC;qBAAM;oBACL,8DAA8D;oBAC7D,KAAa,CAAC,IAAI,CAAC,GAAG,KAAK,CAAC;iBAC9B;aACF;SACF;QACD,OAAO,QAAQ,CAAC;IAClB,CAAC;CACF;AAED;;;;;;;;;;;;;;;;;GAiBG;AACH,MAAM,CAAC,MAAM,QAAQ,GAAG,SAAS,CAAC,iBAAiB,CAAC,CAAC","sourcesContent":["/**\n * @license\n * Copyright 2018 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {AttributePart, noChange} from '../lit-html.js';\nimport {\n  directive,\n  Directive,\n  DirectiveParameters,\n  PartInfo,\n  PartType,\n} from '../directive.js';\n\n/**\n * A key-value set of CSS properties and values.\n *\n * The key should be either a valid CSS property name string, like\n * `'background-color'`, or a valid JavaScript camel case property name\n * for CSSStyleDeclaration like `backgroundColor`.\n */\nexport interface StyleInfo {\n  [name: string]: string | undefined | null;\n}\n\nclass StyleMapDirective extends Directive {\n  _previousStyleProperties?: Set<string>;\n\n  constructor(partInfo: PartInfo) {\n    super(partInfo);\n    if (\n      partInfo.type !== PartType.ATTRIBUTE ||\n      partInfo.name !== 'style' ||\n      (partInfo.strings?.length as number) > 2\n    ) {\n      throw new Error(\n        'The `styleMap` directive must be used in the `style` attribute ' +\n          'and must be the only part in the attribute.'\n      );\n    }\n  }\n\n  render(styleInfo: Readonly<StyleInfo>) {\n    return Object.keys(styleInfo).reduce((style, prop) => {\n      const value = styleInfo[prop];\n      if (value == null) {\n        return style;\n      }\n      // Convert property names from camel-case to dash-case, i.e.:\n      //  `backgroundColor` -> `background-color`\n      // Vendor-prefixed names need an extra `-` appended to front:\n      //  `webkitAppearance` -> `-webkit-appearance`\n      // Exception is any property name containing a dash, including\n      // custom properties; we assume these are already dash-cased i.e.:\n      //  `--my-button-color` --> `--my-button-color`\n      prop = prop\n        .replace(/(?:^(webkit|moz|ms|o)|)(?=[A-Z])/g, '-$&')\n        .toLowerCase();\n      return style + `${prop}:${value};`;\n    }, '');\n  }\n\n  override update(part: AttributePart, [styleInfo]: DirectiveParameters<this>) {\n    const {style} = part.element as HTMLElement;\n\n    if (this._previousStyleProperties === undefined) {\n      this._previousStyleProperties = new Set();\n      for (const name in styleInfo) {\n        this._previousStyleProperties.add(name);\n      }\n      return this.render(styleInfo);\n    }\n\n    // Remove old properties that no longer exist in styleInfo\n    // We use forEach() instead of for-of so that re don't require down-level\n    // iteration.\n    this._previousStyleProperties!.forEach((name) => {\n      // If the name isn't in styleInfo or it's null/undefined\n      if (styleInfo[name] == null) {\n        this._previousStyleProperties!.delete(name);\n        if (name.includes('-')) {\n          style.removeProperty(name);\n        } else {\n          // Note reset using empty string (vs null) as IE11 does not always\n          // reset via null (https://developer.mozilla.org/en-US/docs/Web/API/ElementCSSInlineStyle/style#setting_styles)\n          // eslint-disable-next-line @typescript-eslint/no-explicit-any\n          (style as any)[name] = '';\n        }\n      }\n    });\n\n    // Add or update properties\n    for (const name in styleInfo) {\n      const value = styleInfo[name];\n      if (value != null) {\n        this._previousStyleProperties.add(name);\n        if (name.includes('-')) {\n          style.setProperty(name, value);\n        } else {\n          // eslint-disable-next-line @typescript-eslint/no-explicit-any\n          (style as any)[name] = value;\n        }\n      }\n    }\n    return noChange;\n  }\n}\n\n/**\n * A directive that applies CSS properties to an element.\n *\n * `styleMap` can only be used in the `style` attribute and must be the only\n * expression in the attribute. It takes the property names in the\n * {@link StyleInfo styleInfo} object and adds the property values as CSS\n * properties. Property names with dashes (`-`) are assumed to be valid CSS\n * property names and set on the element's style object using `setProperty()`.\n * Names without dashes are assumed to be camelCased JavaScript property names\n * and set on the element's style object using property assignment, allowing the\n * style object to translate JavaScript-style names to CSS property names.\n *\n * For example `styleMap({backgroundColor: 'red', 'border-top': '5px', '--size':\n * '0'})` sets the `background-color`, `border-top` and `--size` properties.\n *\n * @param styleInfo\n * @see {@link https://lit.dev/docs/templates/directives/#stylemap styleMap code samples on Lit.dev}\n */\nexport const styleMap = directive(StyleMapDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {StyleMapDirective};\n"]}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/development/directives/until.d.ts.map b/front_end/third_party/lit-html/package/development/directives/until.d.ts.map
index 00242b561c4c14c4c0e3fe5e482dea182e7423c6..07633ffea472a38ebc15e01d3e291497a424cbcf 100644
--- a/front_end/third_party/lit-html/package/development/directives/until.d.ts.map
+++ b/front_end/third_party/lit-html/package/development/directives/until.d.ts.map
@@ -1 +1 @@
-{"version":3,"file":"until.d.ts","sourceRoot":"","sources":["../../src/directives/until.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAC,IAAI,EAAW,MAAM,gBAAgB,CAAC;AAG9C,OAAO,EAAC,cAAc,EAAC,MAAM,uBAAuB,CAAC;AASrD,qBAAa,cAAe,SAAQ,cAAc;IAChD,OAAO,CAAC,mBAAmB,CAAqB;IAChD,OAAO,CAAC,QAAQ,CAAiB;IACjC,OAAO,CAAC,UAAU,CAA2B;IAC7C,OAAO,CAAC,QAAQ,CAAgB;IAEhC,MAAM,CAAC,GAAG,IAAI,EAAE,KAAK,CAAC,OAAO,CAAC;IAIrB,MAAM,CAAC,KAAK,EAAE,IAAI,EAAE,IAAI,EAAE,KAAK,CAAC,OAAO,CAAC;IAuExC,YAAY;IAKZ,WAAW;CAIrB;AAED;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,eAAO,MAAM,KAAK,4FAA4B,CAAC;AAE/C;;;GAGG"}
\ No newline at end of file
+{"version":3,"file":"until.d.ts","sourceRoot":"","sources":["../../src/directives/until.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAC,IAAI,EAAW,MAAM,gBAAgB,CAAC;AAE9C,OAAO,EAAY,cAAc,EAAC,MAAM,uBAAuB,CAAC;AAShE,qBAAa,cAAe,SAAQ,cAAc;IAChD,OAAO,CAAC,mBAAmB,CAAqB;IAChD,OAAO,CAAC,QAAQ,CAAiB;IACjC,OAAO,CAAC,UAAU,CAA2B;IAC7C,OAAO,CAAC,QAAQ,CAAgB;IAEhC,MAAM,CAAC,GAAG,IAAI,EAAE,KAAK,CAAC,OAAO,CAAC;IAIrB,MAAM,CAAC,KAAK,EAAE,IAAI,EAAE,IAAI,EAAE,KAAK,CAAC,OAAO,CAAC;IAuExC,YAAY;IAKZ,WAAW;CAIrB;AAED;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,eAAO,MAAM,KAAK,4FAA4B,CAAC;AAE/C;;;GAGG"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/development/directives/until.js b/front_end/third_party/lit-html/package/development/directives/until.js
index 4f51e1ebc5756da50806259aa144ec88502ccf13..9074ff944ba995e1df7e5f870c2acf170371fe06 100644
--- a/front_end/third_party/lit-html/package/development/directives/until.js
+++ b/front_end/third_party/lit-html/package/development/directives/until.js
@@ -4,9 +4,8 @@  * Copyright 2017 Google LLC
  * SPDX-License-Identifier: BSD-3-Clause
  */
 import { noChange } from '../lit-html.js';
-import { directive } from '../directive.js';
 import { isPrimitive } from '../directive-helpers.js';
-import { AsyncDirective } from '../async-directive.js';
+import { directive, AsyncDirective } from '../async-directive.js';
 import { Pauser, PseudoWeakRef } from './private-async-helpers.js';
 const isPromise = (x) => {
     return !isPrimitive(x) && typeof x.then === 'function';




diff --git a/front_end/third_party/lit-html/package/development/directives/until.js.map b/front_end/third_party/lit-html/package/development/directives/until.js.map
index aa0c46346a2a2d64605583a5c4981106f7797415..7eac1befd5d623962789fbafd5bb632ac0ab85a8 100644
--- a/front_end/third_party/lit-html/package/development/directives/until.js.map
+++ b/front_end/third_party/lit-html/package/development/directives/until.js.map
@@ -1 +1 @@
-{"version":3,"file":"until.js","sourceRoot":"","sources":["../../src/directives/until.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAO,QAAQ,EAAC,MAAM,gBAAgB,CAAC;AAC9C,OAAO,EAAC,SAAS,EAAC,MAAM,iBAAiB,CAAC;AAC1C,OAAO,EAAC,WAAW,EAAC,MAAM,yBAAyB,CAAC;AACpD,OAAO,EAAC,cAAc,EAAC,MAAM,uBAAuB,CAAC;AACrD,OAAO,EAAC,MAAM,EAAE,aAAa,EAAC,MAAM,4BAA4B,CAAC;AAEjE,MAAM,SAAS,GAAG,CAAC,CAAU,EAAE,EAAE;IAC/B,OAAO,CAAC,WAAW,CAAC,CAAC,CAAC,IAAI,OAAQ,CAAsB,CAAC,IAAI,KAAK,UAAU,CAAC;AAC/E,CAAC,CAAC;AACF,mCAAmC;AACnC,MAAM,SAAS,GAAG,UAAU,CAAC;AAE7B,MAAM,OAAO,cAAe,SAAQ,cAAc;IAAlD;;QACU,wBAAmB,GAAW,SAAS,CAAC;QACxC,aAAQ,GAAc,EAAE,CAAC;QACzB,eAAU,GAAG,IAAI,aAAa,CAAC,IAAI,CAAC,CAAC;QACrC,aAAQ,GAAG,IAAI,MAAM,EAAE,CAAC;IAsFlC,CAAC;IApFC,MAAM,CAAC,GAAG,IAAoB;;QAC5B,OAAO,MAAA,IAAI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AC,CAAC,IAAI,CAAC,KAAK,EAAE,MAAe,EAAE,EAAE;gBACpD,8DAA8D;gBAC9D,iEAAiE;gBACjE,gEAAgE;gBAChE,OAAO,MAAM,CAAC,GAAG,EAAE,EAAE;oBACnB,MAAM,MAAM,CAAC,GAAG,EAAE,CAAC;iBACpB;gBACD,sEAAsE;gBACtE,qEAAqE;gBACrE,2BAA2B;gBAC3B,MAAM,KAAK,GAAG,QAAQ,CAAC,KAAK,EAAE,CAAC;gBAC/B,IAAI,KAAK,KAAK,SAAS,EAAE;oBACvB,MAAM,KAAK,GAAG,KAAK,CAAC,QAAQ,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;oBAC5C,uEAAuE;oBACvE,mEAAmE;oBACnE,qDAAqD;oBACrD,IAAI,KAAK,GAAG,CAAC,CAAC,IAAI,KAAK,GAAG,KAAK,CAAC,mBAAmB,EAAE;wBACnD,KAAK,CAAC,mBAAmB,GAAG,KAAK,CAAC;wBAClC,KAAK,CAAC,QAAQ,CAAC,MAAM,CAAC,CAAC;qBACxB;iBACF;YACH,CAAC,CAAC,CAAC;SACJ;QAED,OAAO,QAAQ,CAAC;IAClB,CAAC;IAEQ,YAAY;QACnB,IAAI,CAAC,UAAU,CAAC,UAAU,EAAE,CAAC;QAC7B,IAAI,CAAC,QAAQ,CAAC,KAAK,EAAE,CAAC;IACxB,CAAC;IAEQ,WAAW;QAClB,IAAI,CAAC,UAAU,CAAC,SAAS,CAAC,IAAI,CAAC,CAAC;QAChC,IAAI,CAAC,QAAQ,CAAC,MAAM,EAAE,CAAC;IACzB,CAAC;CACF;AAED;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,MAAM,CAAC,MAAM,KAAK,GAAG,SAAS,CAAC,cAAc,CAAC,CAAC;AAE/C;;;GAGG;AACH,gCAAgC","sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {Part, noChange} from '../lit-html.js';\nimport {directive} from '../directive.js';\nimport {isPrimitive} from '../directive-helpers.js';\nimport {AsyncDirective} from '../async-directive.js';\nimport {Pauser, PseudoWeakRef} from './private-async-helpers.js';\n\nconst isPromise = (x: unknown) => {\n  return !isPrimitive(x) && typeof (x as {then?: unknown}).then === 'function';\n};\n// Effectively infinity, but a SMI.\nconst _infinity = 0x3fffffff;\n\nexport class UntilDirective extends AsyncDirective {\n  private __lastRenderedIndex: number = _infinity;\n  private __values: unknown[] = [];\n  private __weakThis = new PseudoWeakRef(this);\n  private __pauser = new Pauser();\n\n  render(...args: Array<unknown>) {\n    return args.find((x) => !isPromise(x)) ?? noChange;\n  }\n\n  override update(_part: Part, args: Array<unknown>) {\n    const previousValues = this.__values;\n    let previousLength = previousValues.length;\n    this.__values = args;\n\n    const weakThis = this.__weakThis;\n    const pauser = this.__pauser;\n\n    // If our initial render occurs while disconnected, ensure that the pauser\n    // and weakThis are in the disconnected state\n    if (!this.isConnected) {\n      this.disconnected();\n    }\n\n    for (let i = 0; i < args.length; i++) {\n      // If we've rendered a higher-priority value already, stop.\n      if (i > this.__lastRenderedIndex) {\n        break;\n      }\n\n      const value = args[i];\n\n      // Render non-Promise values immediately\n      if (!isPromise(value)) {\n        this.__lastRenderedIndex = i;\n        // Since a lower-priority value will never overwrite a higher-priority\n        // synchronous value, we can stop processing now.\n        return value;\n      }\n\n      // If this is a Promise we've already handled, skip it.\n      if (i < previousLength && value === previousValues[i]) {\n        continue;\n      }\n\n      // We have a Promise that we haven't seen before, so priorities may have\n      // changed. Forget what we rendered before.\n      this.__lastRenderedIndex = _infinity;\n      previousLength = 0;\n\n      // Note, the callback avoids closing over `this` so that the directive\n      // can be gc'ed before the promise resolves; instead `this` is retrieved\n      // from `weakThis`, which can break the hard reference in the closure when\n      // the directive disconnects\n      Promise.resolve(value).then(async (result: unknown) => {\n        // If we're disconnected, wait until we're (maybe) reconnected\n        // The while loop here handles the case that the connection state\n        // thrashes, causing the pauser to resume and then get re-paused\n        while (pauser.get()) {\n          await pauser.get();\n        }\n        // If the callback gets here and there is no `this`, it means that the\n        // directive has been disconnected and garbage collected and we don't\n        // need to do anything else\n        const _this = weakThis.deref();\n        if (_this !== undefined) {\n          const index = _this.__values.indexOf(value);\n          // If state.values doesn't contain the value, we've re-rendered without\n          // the value, so don't render it. Then, only render if the value is\n          // higher-priority than what's already been rendered.\n          if (index > -1 && index < _this.__lastRenderedIndex) {\n            _this.__lastRenderedIndex = index;\n            _this.setValue(result);\n          }\n        }\n      });\n    }\n\n    return noChange;\n  }\n\n  override disconnected() {\n    this.__weakThis.disconnect();\n    this.__pauser.pause();\n  }\n\n  override reconnected() {\n    this.__weakThis.reconnect(this);\n    this.__pauser.resume();\n  }\n}\n\n/**\n * Renders one of a series of values, including Promises, to a Part.\n *\n * Values are rendered in priority order, with the first argument having the\n * highest priority and the last argument having the lowest priority. If a\n * value is a Promise, low-priority values will be rendered until it resolves.\n *\n * The priority of values can be used to create placeholder content for async\n * data. For example, a Promise with pending content can be the first,\n * highest-priority, argument, and a non_promise loading indicator template can\n * be used as the second, lower-priority, argument. The loading indicator will\n * render immediately, and the primary content will render when the Promise\n * resolves.\n *\n * Example:\n *\n * ```js\n * const content = fetch('./content.txt').then(r => r.text());\n * html`${until(content, html`<span>Loading...</span>`)}`\n * ```\n */\nexport const until = directive(UntilDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\n// export type {UntilDirective};\n"]}
\ No newline at end of file
+{"version":3,"file":"until.js","sourceRoot":"","sources":["../../src/directives/until.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAO,QAAQ,EAAC,MAAM,gBAAgB,CAAC;AAC9C,OAAO,EAAC,WAAW,EAAC,MAAM,yBAAyB,CAAC;AACpD,OAAO,EAAC,SAAS,EAAE,cAAc,EAAC,MAAM,uBAAuB,CAAC;AAChE,OAAO,EAAC,MAAM,EAAE,aAAa,EAAC,MAAM,4BAA4B,CAAC;AAEjE,MAAM,SAAS,GAAG,CAAC,CAAU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AC;QAC7B,IAAI,CAAC,QAAQ,CAAC,KAAK,EAAE,CAAC;IACxB,CAAC;IAEQ,WAAW;QAClB,IAAI,CAAC,UAAU,CAAC,SAAS,CAAC,IAAI,CAAC,CAAC;QAChC,IAAI,CAAC,QAAQ,CAAC,MAAM,EAAE,CAAC;IACzB,CAAC;CACF;AAED;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,MAAM,CAAC,MAAM,KAAK,GAAG,SAAS,CAAC,cAAc,CAAC,CAAC;AAE/C;;;GAGG;AACH,gCAAgC","sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {Part, noChange} from '../lit-html.js';\nimport {isPrimitive} from '../directive-helpers.js';\nimport {directive, AsyncDirective} from '../async-directive.js';\nimport {Pauser, PseudoWeakRef} from './private-async-helpers.js';\n\nconst isPromise = (x: unknown) => {\n  return !isPrimitive(x) && typeof (x as {then?: unknown}).then === 'function';\n};\n// Effectively infinity, but a SMI.\nconst _infinity = 0x3fffffff;\n\nexport class UntilDirective extends AsyncDirective {\n  private __lastRenderedIndex: number = _infinity;\n  private __values: unknown[] = [];\n  private __weakThis = new PseudoWeakRef(this);\n  private __pauser = new Pauser();\n\n  render(...args: Array<unknown>) {\n    return args.find((x) => !isPromise(x)) ?? noChange;\n  }\n\n  override update(_part: Part, args: Array<unknown>) {\n    const previousValues = this.__values;\n    let previousLength = previousValues.length;\n    this.__values = args;\n\n    const weakThis = this.__weakThis;\n    const pauser = this.__pauser;\n\n    // If our initial render occurs while disconnected, ensure that the pauser\n    // and weakThis are in the disconnected state\n    if (!this.isConnected) {\n      this.disconnected();\n    }\n\n    for (let i = 0; i < args.length; i++) {\n      // If we've rendered a higher-priority value already, stop.\n      if (i > this.__lastRenderedIndex) {\n        break;\n      }\n\n      const value = args[i];\n\n      // Render non-Promise values immediately\n      if (!isPromise(value)) {\n        this.__lastRenderedIndex = i;\n        // Since a lower-priority value will never overwrite a higher-priority\n        // synchronous value, we can stop processing now.\n        return value;\n      }\n\n      // If this is a Promise we've already handled, skip it.\n      if (i < previousLength && value === previousValues[i]) {\n        continue;\n      }\n\n      // We have a Promise that we haven't seen before, so priorities may have\n      // changed. Forget what we rendered before.\n      this.__lastRenderedIndex = _infinity;\n      previousLength = 0;\n\n      // Note, the callback avoids closing over `this` so that the directive\n      // can be gc'ed before the promise resolves; instead `this` is retrieved\n      // from `weakThis`, which can break the hard reference in the closure when\n      // the directive disconnects\n      Promise.resolve(value).then(async (result: unknown) => {\n        // If we're disconnected, wait until we're (maybe) reconnected\n        // The while loop here handles the case that the connection state\n        // thrashes, causing the pauser to resume and then get re-paused\n        while (pauser.get()) {\n          await pauser.get();\n        }\n        // If the callback gets here and there is no `this`, it means that the\n        // directive has been disconnected and garbage collected and we don't\n        // need to do anything else\n        const _this = weakThis.deref();\n        if (_this !== undefined) {\n          const index = _this.__values.indexOf(value);\n          // If state.values doesn't contain the value, we've re-rendered without\n          // the value, so don't render it. Then, only render if the value is\n          // higher-priority than what's already been rendered.\n          if (index > -1 && index < _this.__lastRenderedIndex) {\n            _this.__lastRenderedIndex = index;\n            _this.setValue(result);\n          }\n        }\n      });\n    }\n\n    return noChange;\n  }\n\n  override disconnected() {\n    this.__weakThis.disconnect();\n    this.__pauser.pause();\n  }\n\n  override reconnected() {\n    this.__weakThis.reconnect(this);\n    this.__pauser.resume();\n  }\n}\n\n/**\n * Renders one of a series of values, including Promises, to a Part.\n *\n * Values are rendered in priority order, with the first argument having the\n * highest priority and the last argument having the lowest priority. If a\n * value is a Promise, low-priority values will be rendered until it resolves.\n *\n * The priority of values can be used to create placeholder content for async\n * data. For example, a Promise with pending content can be the first,\n * highest-priority, argument, and a non_promise loading indicator template can\n * be used as the second, lower-priority, argument. The loading indicator will\n * render immediately, and the primary content will render when the Promise\n * resolves.\n *\n * Example:\n *\n * ```js\n * const content = fetch('./content.txt').then(r => r.text());\n * html`${until(content, html`<span>Loading...</span>`)}`\n * ```\n */\nexport const until = directive(UntilDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\n// export type {UntilDirective};\n"]}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/development/experimental-hydrate.d.ts.map b/front_end/third_party/lit-html/package/development/experimental-hydrate.d.ts.map
index 6bdc8b9070ad7a05c2a972ec7fad4694a2e0ce57..a73a8100656db2bed58e6e30f1081a11989c5537 100644
--- a/front_end/third_party/lit-html/package/development/experimental-hydrate.d.ts.map
+++ b/front_end/third_party/lit-html/package/development/experimental-hydrate.d.ts.map
@@ -1 +1 @@
-{"version":3,"file":"experimental-hydrate.d.ts","sourceRoot":"","sources":["../src/experimental-hydrate.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,KAAK,EAAC,cAAc,EAAC,MAAM,eAAe,CAAC;AAElD,OAAO,EAAW,aAAa,EAAO,MAAM,eAAe,CAAC;AA8D5D;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAwCG;AACH,eAAO,MAAM,OAAO,cACP,OAAO,aACP,OAAO,GAAG,gBAAgB,YAC5B,QAAQ,aAAa,CAAC,SAiEhC,CAAC;AAqPF,eAAO,MAAM,uBAAuB,mBAAoB,cAAc,WASrE,CAAC"}
\ No newline at end of file
+{"version":3,"file":"experimental-hydrate.d.ts","sourceRoot":"","sources":["../src/experimental-hydrate.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,KAAK,EAAC,cAAc,EAAC,MAAM,eAAe,CAAC;AAElD,OAAO,EAAW,aAAa,EAAO,MAAM,eAAe,CAAC;AA8D5D;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAwCG;AACH,eAAO,MAAM,OAAO,cACP,OAAO,aACP,OAAO,GAAG,gBAAgB,YAC5B,QAAQ,aAAa,CAAC,SA4DhC,CAAC;AAsPF,eAAO,MAAM,uBAAuB,mBAAoB,cAAc,WASrE,CAAC"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/development/experimental-hydrate.js b/front_end/third_party/lit-html/package/development/experimental-hydrate.js
index 4ef237cb1e64d561ef21adeb090966d711755b27..ba8d4ec73101726a849d63ff937c5f87a3c8f2bc 100644
--- a/front_end/third_party/lit-html/package/development/experimental-hydrate.js
+++ b/front_end/third_party/lit-html/package/development/experimental-hydrate.js
@@ -84,12 +84,6 @@             // Create and hydrate attribute parts into the current ChildPart on the
             // stack
             createAttributeParts(marker, stack, options);
 import { PartType } from './directive.js';
-import { noChange, _$LH } from './lit-html.js';
-            const parent = marker.parentElement;
-            if (parent.hasAttribute('defer-hydration')) {
-                parent.removeAttribute('defer-hydration');
-            }
-import { PartType } from './directive.js';
 /**
         else if (markerText.startsWith('/lit-part')) {
             // Close the current ChildPart, and pop the previous one off the stack
@@ -250,7 +245,13 @@     // the previousSibling; for non-void elements, the comment is guaranteed
     // to be the first child of the element (i.e. it won't have a previousSibling
     // meaning it should use the parentElement)
  * @license
+    // Walk the DOM looking for part marker comments
+    if (node === null) {
+        throw new Error('could not find node for attribute parts');
+ * SPDX-License-Identifier: BSD-3-Clause
 import { PartType } from './directive.js';
+    // Remove `defer-hydration` attribute, if any
+    node.removeAttribute('defer-hydration');
     const state = stack[stack.length - 1];
     if (state.type === 'template-instance') {
         const instance = state.instance;




diff --git a/front_end/third_party/lit-html/package/development/experimental-hydrate.js.map b/front_end/third_party/lit-html/package/development/experimental-hydrate.js.map
index 995727233420bd42787afc57149f0d7a4b12debe..cbed342dea91d08c8f58158ae4e9df0c1d701150 100644
--- a/front_end/third_party/lit-html/package/development/experimental-hydrate.js.map
+++ b/front_end/third_party/lit-html/package/development/experimental-hydrate.js.map
@@ -1 +1 @@
-{"version":3,"file":"experimental-hydrate.js","sourceRoot":"","sources":["../src/experimental-hydrate.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAIH,OAAO,EAAC,QAAQ,EAAiB,IAAI,EAAC,MAAM,eAAe,CAAC;AAC5D,OAAO,EAAoB,QAAQ,EAAC,MAAM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C;SAC3B;KACF;SAAM;QACL,MAAM,IAAI,KAAK,CAAC,gBAAgB,CAAC,CAAC;KACnC;AACH,CAAC,CAAC;AAEF,8DAA8D;AAC9D,MAAM,UAAU,GAAG,CAAC,CAAC;AACrB,8EAA8E;AAC9E,0DAA0D;AAC1D,iEAAiE;AACjE,oEAAoE;AACpE,SAAS;AACT,4EAA4E;AAC5E,qBAAqB;AACrB,gCAAgC;AAChC,8DAA8D;AAC9D,iEAAiE;AACjE,iDAAiD;AACjD,MAAM,CAAC,MAAM,uBAAuB,GAAG,CAAC,cAA8B,EAAE,EAAE;IACxE,MAAM,MAAM,GAAG,IAAI,WAAW,CAAC,UAAU,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IAEtD,KAAK,MAAM,CAAC,IAAI,cAAc,CAAC,OAAO,EAAE;QACtC,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,CAAC,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE;YACjC,MAAM,CAAC,CAAC,GAAG,UAAU,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC,GAAG,UAAU,CAAC,GAAG,EAAE,CAAC,GAAG,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC;SAC1E;KACF;IACD,OAAO,IAAI,CAAC,MAAM,CAAC,YAAY,CAAC,GAAG,IAAI,UAAU,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC;AACrE,CAAC,CAAC","sourcesContent":["/**\n * @license\n * Copyright 2019 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport type {TemplateResult} from './lit-html.js';\n\nimport {noChange, RenderOptions, _$LH} from './lit-html.js';\nimport {AttributePartInfo, PartType} from './directive.js';\nimport {\n  isPrimitive,\n  isSingleExpression,\n  isTemplateResult,\n} from './directive-helpers.js';\n\nconst {\n  _TemplateInstance: TemplateInstance,\n  _isIterable: isIterable,\n  _resolveDirective: resolveDirective,\n  _ChildPart: ChildPart,\n  _ElementPart: ElementPart,\n} = _$LH;\n\ntype ChildPart = InstanceType<typeof ChildPart>;\ntype TemplateInstance = InstanceType<typeof TemplateInstance>;\n\n/**\n * Information needed to rehydrate a single TemplateResult.\n */\ntype ChildPartState =\n  | {\n      type: 'leaf';\n      /** The ChildPart that the result is rendered to */\n      part: ChildPart;\n    }\n  | {\n      type: 'iterable';\n      /** The ChildPart that the result is rendered to */\n      part: ChildPart;\n      value: Iterable<unknown>;\n      iterator: Iterator<unknown>;\n      done: boolean;\n    }\n  | {\n      type: 'template-instance';\n      /** The ChildPart that the result is rendered to */\n      part: ChildPart;\n\n      result: TemplateResult;\n\n      /** The TemplateInstance created from the TemplateResult */\n      instance: TemplateInstance;\n\n      /**\n       * The index of the next Template part to be hydrated. This is mutable and\n       * updated as the tree walk discovers new part markers at the right level in\n       * the template instance tree.  Note there is only one Template part per\n       * attribute with (one or more) bindings.\n       */\n      templatePartIndex: number;\n\n      /**\n       * The index of the next TemplateInstance part to be hydrated. This is used\n       * to retrieve the value from the TemplateResult and initialize the\n       * TemplateInstance parts' values for dirty-checking on first render.\n       */\n      instancePartIndex: number;\n    };\n\n/**\n * hydrate() operates on a container with server-side rendered content and\n * restores the client side data structures needed for lit-html updates such as\n * TemplateInstances and Parts. After calling `hydrate`, lit-html will behave as\n * if it initially rendered the DOM, and any subsequent updates will update\n * efficiently, the same as if lit-html had rendered the DOM on the client.\n *\n * hydrate() must be called on DOM that adheres the to lit-ssr structure for\n * parts. ChildParts must be represented with both a start and end comment\n * marker, and ChildParts that contain a TemplateInstance must have the template\n * digest written into the comment data.\n *\n * Since render() encloses its output in a ChildPart, there must always be a root\n * ChildPart.\n *\n * Example (using for # ... for annotations in HTML)\n *\n * Given this input:\n *\n *   html`<div class=${x}>${y}</div>`\n *\n * The SSR DOM is:\n *\n *   <!--lit-part AEmR7W+R0Ak=-->  # Start marker for the root ChildPart created\n *                                 # by render(). Includes the digest of the\n *                                 # template\n *   <div class=\"TEST_X\">\n *     <!--lit-node 0--> # Indicates there are attribute bindings here\n *                           # The number is the depth-first index of the parent\n *                           # node in the template.\n *     <!--lit-part-->  # Start marker for the ${x} expression\n *     TEST_Y\n *     <!--/lit-part-->  # End marker for the ${x} expression\n *   </div>\n *\n *   <!--/lit-part-->  # End marker for the root ChildPart\n *\n * @param rootValue\n * @param container\n * @param userOptions\n */\nexport const hydrate = (\n  rootValue: unknown,\n  container: Element | DocumentFragment,\n  options: Partial<RenderOptions> = {}\n) => {\n  // TODO(kschaaf): Do we need a helper for _$litPart$ (\"part for node\")?\n  // This property needs to remain unminified.\n  // eslint-disable-next-line @typescript-eslint/no-explicit-any\n  if ((container as any)['_$litPart$'] !== undefined) {\n    throw new Error('container already contains a live render');\n  }\n\n  // Since render() creates a ChildPart to render into, we'll always have\n  // exactly one root part. We need to hold a reference to it so we can set\n  // it in the parts cache.\n  let rootPart: ChildPart | undefined = undefined;\n\n  // When we are in-between ChildPart markers, this is the current ChildPart.\n  // It's needed to be able to set the ChildPart's endNode when we see a\n  // close marker\n  let currentChildPart: ChildPart | undefined = undefined;\n\n  // Used to remember parent template state as we recurse into nested\n  // templates\n  const stack: Array<ChildPartState> = [];\n\n  const walker = document.createTreeWalker(\n    container,\n    NodeFilter.SHOW_COMMENT,\n    null,\n    false\n  );\n  let marker: Comment | null;\n\n  // Walk the DOM looking for part marker comments\n  while ((marker = walker.nextNode() as Comment | null) !== null) {\n    const markerText = marker.data;\n    if (markerText.startsWith('lit-part')) {\n      if (stack.length === 0 && rootPart !== undefined) {\n        throw new Error('there must be only one root part per container');\n      }\n      // Create a new ChildPart and push it onto the stack\n      currentChildPart = openChildPart(rootValue, marker, stack, options);\n      rootPart ??= currentChildPart;\n    } else if (markerText.startsWith('lit-node')) {\n      // Create and hydrate attribute parts into the current ChildPart on the\n      // stack\n      createAttributeParts(marker, stack, options);\n      // Remove `defer-hydration` attribute, if any\n      const parent = marker.parentElement!;\n      if (parent.hasAttribute('defer-hydration')) {\n        parent.removeAttribute('defer-hydration');\n      }\n    } else if (markerText.startsWith('/lit-part')) {\n      // Close the current ChildPart, and pop the previous one off the stack\n      if (stack.length === 1 && currentChildPart !== rootPart) {\n        throw new Error('internal error');\n      }\n      currentChildPart = closeChildPart(marker, currentChildPart, stack);\n    }\n  }\n  console.assert(\n    rootPart !== undefined,\n    'there should be exactly one root part in a render container'\n  );\n  // This property needs to remain unminified.\n  // eslint-disable-next-line @typescript-eslint/no-explicit-any\n  (container as any)['_$litPart$'] = rootPart;\n};\n\nconst openChildPart = (\n  rootValue: unknown,\n  marker: Comment,\n  stack: Array<ChildPartState>,\n  options: RenderOptions\n) => {\n  let value: unknown;\n  // We know the startNode now. We'll know the endNode when we get to\n  // the matching marker and set it in closeChildPart()\n  // TODO(kschaaf): Current constructor takes both nodes\n  let part;\n  if (stack.length === 0) {\n    part = new ChildPart(marker, null, undefined, options);\n    value = rootValue;\n  } else {\n    const state = stack[stack.length - 1];\n    if (state.type === 'template-instance') {\n      part = new ChildPart(marker, null, state.instance, options);\n      state.instance._parts.push(part);\n      value = state.result.values[state.instancePartIndex++];\n      state.templatePartIndex++;\n    } else if (state.type === 'iterable') {\n      part = new ChildPart(marker, null, state.part, options);\n      const result = state.iterator.next();\n      if (result.done) {\n        value = undefined;\n        state.done = true;\n        throw new Error('Unhandled shorter than expected iterable');\n      } else {\n        value = result.value;\n      }\n      (state.part._$committedValue as Array<ChildPart>).push(part);\n    } else {\n      // state.type === 'leaf'\n      // TODO(kschaaf): This is unexpected, and likely a result of a primitive\n      // been rendered on the client when a TemplateResult was rendered on the\n      // server; this part will be hydrated but not used. We can detect it, but\n      // we need to decide what to do in this case. Note that this part won't be\n      // retained by any parent TemplateInstance, since a primitive had been\n      // rendered in its place.\n      // https://github.com/lit/lit/issues/1434\n      // throw new Error('Hydration value mismatch: Found a TemplateInstance' +\n      //  'where a leaf value was expected');\n      part = new ChildPart(marker, null, state.part, options);\n    }\n  }\n\n  // Initialize the ChildPart state depending on the type of value and push\n  // it onto the stack. This logic closely follows the ChildPart commit()\n  // cascade order:\n  // 1. directive\n  // 2. noChange\n  // 3. primitive (note strings must be handled before iterables, since they\n  //    are iterable)\n  // 4. TemplateResult\n  // 5. Node (not yet implemented, but fallback handling is fine)\n  // 6. Iterable\n  // 7. nothing (handled in fallback)\n  // 8. Fallback for everything else\n  value = resolveDirective(part, value);\n  if (value === noChange) {\n    stack.push({part, type: 'leaf'});\n  } else if (isPrimitive(value)) {\n    stack.push({part, type: 'leaf'});\n    part._$committedValue = value;\n    // TODO(kschaaf): We can detect when a primitive is being hydrated on the\n    // client where a TemplateResult was rendered on the server, but we need to\n    // decide on a strategy for what to do next.\n    // https://github.com/lit/lit/issues/1434\n    // if (marker.data !== 'lit-part') {\n    //   throw new Error('Hydration value mismatch: Primitive found where TemplateResult expected');\n    // }\n  } else if (isTemplateResult(value)) {\n    // Check for a template result digest\n    const markerWithDigest = `lit-part ${digestForTemplateResult(value)}`;\n    if (marker.data === markerWithDigest) {\n      const template = ChildPart.prototype._$getTemplate(value);\n      const instance = new TemplateInstance(template, part);\n      stack.push({\n        type: 'template-instance',\n        instance,\n        part,\n        templatePartIndex: 0,\n        instancePartIndex: 0,\n        result: value,\n      });\n      // For TemplateResult values, we set the part value to the\n      // generated TemplateInstance\n      part._$committedValue = instance;\n    } else {\n      // TODO: if this isn't the server-rendered template, do we\n      // need to stop hydrating this subtree? Clear it? Add tests.\n      throw new Error(\n        'Hydration value mismatch: Unexpected TemplateResult rendered to part'\n      );\n    }\n  } else if (isIterable(value)) {\n    // currentChildPart.value will contain an array of ChildParts\n    stack.push({\n      part: part,\n      type: 'iterable',\n      value,\n      iterator: value[Symbol.iterator](),\n      done: false,\n    });\n    part._$committedValue = [];\n  } else {\n    // Fallback for everything else (nothing, Objects, Functions,\n    // etc.): we just initialize the part's value\n    // Note that `Node` value types are not currently supported during\n    // SSR, so that part of the cascade is missing.\n    stack.push({part: part, type: 'leaf'});\n    part._$committedValue = value == null ? '' : value;\n  }\n  return part;\n};\n\nconst closeChildPart = (\n  marker: Comment,\n  part: ChildPart | undefined,\n  stack: Array<ChildPartState>\n): ChildPart | undefined => {\n  if (part === undefined) {\n    throw new Error('unbalanced part marker');\n  }\n\n  part._$endNode = marker;\n\n  const currentState = stack.pop()!;\n\n  if (currentState.type === 'iterable') {\n    if (!currentState.iterator.next().done) {\n      throw new Error('unexpected longer than expected iterable');\n    }\n  }\n\n  if (stack.length > 0) {\n    const state = stack[stack.length - 1];\n    return state.part;\n  } else {\n    return undefined;\n  }\n};\n\nconst createAttributeParts = (\n  comment: Comment,\n  stack: Array<ChildPartState>,\n  options: RenderOptions\n) => {\n  // Get the nodeIndex from DOM. We're only using this for an integrity\n  // check right now, we might not need it.\n  const match = /lit-node (\\d+)/.exec(comment.data)!;\n  const nodeIndex = parseInt(match[1]);\n\n  // For void elements, the node the comment was referring to will be\n  // the previousSibling; for non-void elements, the comment is guaranteed\n  // to be the first child of the element (i.e. it won't have a previousSibling\n  // meaning it should use the parentElement)\n  const node = comment.previousSibling ?? comment.parentElement;\n\n  const state = stack[stack.length - 1];\n  if (state.type === 'template-instance') {\n    const instance = state.instance;\n    // eslint-disable-next-line no-constant-condition\n    while (true) {\n      // If the next template part is in attribute-position on the current node,\n      // create the instance part for it and prime its state\n      const templatePart = instance._$template.parts[state.templatePartIndex];\n      if (\n        templatePart === undefined ||\n        (templatePart.type !== PartType.ATTRIBUTE &&\n          templatePart.type !== PartType.ELEMENT) ||\n        templatePart.index !== nodeIndex\n      ) {\n        break;\n      }\n\n      if (templatePart.type === PartType.ATTRIBUTE) {\n        // The instance part is created based on the constructor saved in the\n        // template part\n        const instancePart = new templatePart.ctor(\n          node as HTMLElement,\n          templatePart.name,\n          templatePart.strings,\n          state.instance,\n          options\n        );\n\n        const value = isSingleExpression(\n          instancePart as unknown as AttributePartInfo\n        )\n          ? state.result.values[state.instancePartIndex]\n          : state.result.values;\n\n        // Setting the attribute value primes committed value with the resolved\n        // directive value; we only then commit that value for event/property\n        // parts since those were not serialized, and pass `noCommit` for the\n        // others to avoid perf impact of touching the DOM unnecessarily\n        const noCommit = !(\n          instancePart.type === PartType.EVENT ||\n          instancePart.type === PartType.PROPERTY\n        );\n        instancePart._$setValue(\n          value,\n          instancePart,\n          state.instancePartIndex,\n          noCommit\n        );\n        state.instancePartIndex += templatePart.strings.length - 1;\n        instance._parts.push(instancePart);\n      } else {\n        // templatePart.type === PartType.ELEMENT\n        const instancePart = new ElementPart(\n          node as HTMLElement,\n          state.instance,\n          options\n        );\n        resolveDirective(\n          instancePart,\n          state.result.values[state.instancePartIndex++]\n        );\n        instance._parts.push(instancePart);\n      }\n      state.templatePartIndex++;\n    }\n  } else {\n    throw new Error('internal error');\n  }\n};\n\n// Number of 32 bit elements to use to create template digests\nconst digestSize = 2;\n// We need to specify a digest to use across rendering environments. This is a\n// simple digest build from a DJB2-ish hash modified from:\n// https://github.com/darkskyapp/string-hash/blob/master/index.js\n// It has been changed to an array of hashes to add additional bits.\n// Goals:\n//  - Extremely low collision rate. We may not be able to detect collisions.\n//  - Extremely fast.\n//  - Extremely small code size.\n//  - Safe to include in HTML comment text or attribute value.\n//  - Easily specifiable and implementable in multiple languages.\n// We don't care about cryptographic suitability.\nexport const digestForTemplateResult = (templateResult: TemplateResult) => {\n  const hashes = new Uint32Array(digestSize).fill(5381);\n\n  for (const s of templateResult.strings) {\n    for (let i = 0; i < s.length; i++) {\n      hashes[i % digestSize] = (hashes[i % digestSize] * 33) ^ s.charCodeAt(i);\n    }\n  }\n  return btoa(String.fromCharCode(...new Uint8Array(hashes.buffer)));\n};\n"]}
\ No newline at end of file
+{"version":3,"file":"experimental-hydrate.js","sourceRoot":"","sources":["../src/experimental-hydrate.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAIH,OAAO,EAAC,QAAQ,EAAiB,IAAI,EAAC,MAAM,eAAe,CAAC;AAC5D,OAAO,EAAoB,QAAQ,EAAC,MAAM,gBAAgB,CAAC;AAC3D,OAAO,EACL,WAAW,EACX,kBAAkB,EAClB,gBAAgB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AC,CAAC;AAEF,8DAA8D;AAC9D,MAAM,UAAU,GAAG,CAAC,CAAC;AACrB,8EAA8E;AAC9E,0DAA0D;AAC1D,iEAAiE;AACjE,oEAAoE;AACpE,SAAS;AACT,4EAA4E;AAC5E,qBAAqB;AACrB,gCAAgC;AAChC,8DAA8D;AAC9D,iEAAiE;AACjE,iDAAiD;AACjD,MAAM,CAAC,MAAM,uBAAuB,GAAG,CAAC,cAA8B,EAAE,EAAE;IACxE,MAAM,MAAM,GAAG,IAAI,WAAW,CAAC,UAAU,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IAEtD,KAAK,MAAM,CAAC,IAAI,cAAc,CAAC,OAAO,EAAE;QACtC,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,CAAC,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE;YACjC,MAAM,CAAC,CAAC,GAAG,UAAU,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC,GAAG,UAAU,CAAC,GAAG,EAAE,CAAC,GAAG,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC;SAC1E;KACF;IACD,OAAO,IAAI,CAAC,MAAM,CAAC,YAAY,CAAC,GAAG,IAAI,UAAU,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC;AACrE,CAAC,CAAC","sourcesContent":["/**\n * @license\n * Copyright 2019 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport type {TemplateResult} from './lit-html.js';\n\nimport {noChange, RenderOptions, _$LH} from './lit-html.js';\nimport {AttributePartInfo, PartType} from './directive.js';\nimport {\n  isPrimitive,\n  isSingleExpression,\n  isTemplateResult,\n} from './directive-helpers.js';\n\nconst {\n  _TemplateInstance: TemplateInstance,\n  _isIterable: isIterable,\n  _resolveDirective: resolveDirective,\n  _ChildPart: ChildPart,\n  _ElementPart: ElementPart,\n} = _$LH;\n\ntype ChildPart = InstanceType<typeof ChildPart>;\ntype TemplateInstance = InstanceType<typeof TemplateInstance>;\n\n/**\n * Information needed to rehydrate a single TemplateResult.\n */\ntype ChildPartState =\n  | {\n      type: 'leaf';\n      /** The ChildPart that the result is rendered to */\n      part: ChildPart;\n    }\n  | {\n      type: 'iterable';\n      /** The ChildPart that the result is rendered to */\n      part: ChildPart;\n      value: Iterable<unknown>;\n      iterator: Iterator<unknown>;\n      done: boolean;\n    }\n  | {\n      type: 'template-instance';\n      /** The ChildPart that the result is rendered to */\n      part: ChildPart;\n\n      result: TemplateResult;\n\n      /** The TemplateInstance created from the TemplateResult */\n      instance: TemplateInstance;\n\n      /**\n       * The index of the next Template part to be hydrated. This is mutable and\n       * updated as the tree walk discovers new part markers at the right level in\n       * the template instance tree.  Note there is only one Template part per\n       * attribute with (one or more) bindings.\n       */\n      templatePartIndex: number;\n\n      /**\n       * The index of the next TemplateInstance part to be hydrated. This is used\n       * to retrieve the value from the TemplateResult and initialize the\n       * TemplateInstance parts' values for dirty-checking on first render.\n       */\n      instancePartIndex: number;\n    };\n\n/**\n * hydrate() operates on a container with server-side rendered content and\n * restores the client side data structures needed for lit-html updates such as\n * TemplateInstances and Parts. After calling `hydrate`, lit-html will behave as\n * if it initially rendered the DOM, and any subsequent updates will update\n * efficiently, the same as if lit-html had rendered the DOM on the client.\n *\n * hydrate() must be called on DOM that adheres the to lit-ssr structure for\n * parts. ChildParts must be represented with both a start and end comment\n * marker, and ChildParts that contain a TemplateInstance must have the template\n * digest written into the comment data.\n *\n * Since render() encloses its output in a ChildPart, there must always be a root\n * ChildPart.\n *\n * Example (using for # ... for annotations in HTML)\n *\n * Given this input:\n *\n *   html`<div class=${x}>${y}</div>`\n *\n * The SSR DOM is:\n *\n *   <!--lit-part AEmR7W+R0Ak=-->  # Start marker for the root ChildPart created\n *                                 # by render(). Includes the digest of the\n *                                 # template\n *   <div class=\"TEST_X\">\n *     <!--lit-node 0--> # Indicates there are attribute bindings here\n *                           # The number is the depth-first index of the parent\n *                           # node in the template.\n *     <!--lit-part-->  # Start marker for the ${x} expression\n *     TEST_Y\n *     <!--/lit-part-->  # End marker for the ${x} expression\n *   </div>\n *\n *   <!--/lit-part-->  # End marker for the root ChildPart\n *\n * @param rootValue\n * @param container\n * @param userOptions\n */\nexport const hydrate = (\n  rootValue: unknown,\n  container: Element | DocumentFragment,\n  options: Partial<RenderOptions> = {}\n) => {\n  // TODO(kschaaf): Do we need a helper for _$litPart$ (\"part for node\")?\n  // This property needs to remain unminified.\n  // eslint-disable-next-line @typescript-eslint/no-explicit-any\n  if ((container as any)['_$litPart$'] !== undefined) {\n    throw new Error('container already contains a live render');\n  }\n\n  // Since render() creates a ChildPart to render into, we'll always have\n  // exactly one root part. We need to hold a reference to it so we can set\n  // it in the parts cache.\n  let rootPart: ChildPart | undefined = undefined;\n\n  // When we are in-between ChildPart markers, this is the current ChildPart.\n  // It's needed to be able to set the ChildPart's endNode when we see a\n  // close marker\n  let currentChildPart: ChildPart | undefined = undefined;\n\n  // Used to remember parent template state as we recurse into nested\n  // templates\n  const stack: Array<ChildPartState> = [];\n\n  const walker = document.createTreeWalker(\n    container,\n    NodeFilter.SHOW_COMMENT,\n    null,\n    false\n  );\n  let marker: Comment | null;\n\n  // Walk the DOM looking for part marker comments\n  while ((marker = walker.nextNode() as Comment | null) !== null) {\n    const markerText = marker.data;\n    if (markerText.startsWith('lit-part')) {\n      if (stack.length === 0 && rootPart !== undefined) {\n        throw new Error('there must be only one root part per container');\n      }\n      // Create a new ChildPart and push it onto the stack\n      currentChildPart = openChildPart(rootValue, marker, stack, options);\n      rootPart ??= currentChildPart;\n    } else if (markerText.startsWith('lit-node')) {\n      // Create and hydrate attribute parts into the current ChildPart on the\n      // stack\n      createAttributeParts(marker, stack, options);\n    } else if (markerText.startsWith('/lit-part')) {\n      // Close the current ChildPart, and pop the previous one off the stack\n      if (stack.length === 1 && currentChildPart !== rootPart) {\n        throw new Error('internal error');\n      }\n      currentChildPart = closeChildPart(marker, currentChildPart, stack);\n    }\n  }\n  console.assert(\n    rootPart !== undefined,\n    'there should be exactly one root part in a render container'\n  );\n  // This property needs to remain unminified.\n  // eslint-disable-next-line @typescript-eslint/no-explicit-any\n  (container as any)['_$litPart$'] = rootPart;\n};\n\nconst openChildPart = (\n  rootValue: unknown,\n  marker: Comment,\n  stack: Array<ChildPartState>,\n  options: RenderOptions\n) => {\n  let value: unknown;\n  // We know the startNode now. We'll know the endNode when we get to\n  // the matching marker and set it in closeChildPart()\n  // TODO(kschaaf): Current constructor takes both nodes\n  let part;\n  if (stack.length === 0) {\n    part = new ChildPart(marker, null, undefined, options);\n    value = rootValue;\n  } else {\n    const state = stack[stack.length - 1];\n    if (state.type === 'template-instance') {\n      part = new ChildPart(marker, null, state.instance, options);\n      state.instance._parts.push(part);\n      value = state.result.values[state.instancePartIndex++];\n      state.templatePartIndex++;\n    } else if (state.type === 'iterable') {\n      part = new ChildPart(marker, null, state.part, options);\n      const result = state.iterator.next();\n      if (result.done) {\n        value = undefined;\n        state.done = true;\n        throw new Error('Unhandled shorter than expected iterable');\n      } else {\n        value = result.value;\n      }\n      (state.part._$committedValue as Array<ChildPart>).push(part);\n    } else {\n      // state.type === 'leaf'\n      // TODO(kschaaf): This is unexpected, and likely a result of a primitive\n      // been rendered on the client when a TemplateResult was rendered on the\n      // server; this part will be hydrated but not used. We can detect it, but\n      // we need to decide what to do in this case. Note that this part won't be\n      // retained by any parent TemplateInstance, since a primitive had been\n      // rendered in its place.\n      // https://github.com/lit/lit/issues/1434\n      // throw new Error('Hydration value mismatch: Found a TemplateInstance' +\n      //  'where a leaf value was expected');\n      part = new ChildPart(marker, null, state.part, options);\n    }\n  }\n\n  // Initialize the ChildPart state depending on the type of value and push\n  // it onto the stack. This logic closely follows the ChildPart commit()\n  // cascade order:\n  // 1. directive\n  // 2. noChange\n  // 3. primitive (note strings must be handled before iterables, since they\n  //    are iterable)\n  // 4. TemplateResult\n  // 5. Node (not yet implemented, but fallback handling is fine)\n  // 6. Iterable\n  // 7. nothing (handled in fallback)\n  // 8. Fallback for everything else\n  value = resolveDirective(part, value);\n  if (value === noChange) {\n    stack.push({part, type: 'leaf'});\n  } else if (isPrimitive(value)) {\n    stack.push({part, type: 'leaf'});\n    part._$committedValue = value;\n    // TODO(kschaaf): We can detect when a primitive is being hydrated on the\n    // client where a TemplateResult was rendered on the server, but we need to\n    // decide on a strategy for what to do next.\n    // https://github.com/lit/lit/issues/1434\n    // if (marker.data !== 'lit-part') {\n    //   throw new Error('Hydration value mismatch: Primitive found where TemplateResult expected');\n    // }\n  } else if (isTemplateResult(value)) {\n    // Check for a template result digest\n    const markerWithDigest = `lit-part ${digestForTemplateResult(value)}`;\n    if (marker.data === markerWithDigest) {\n      const template = ChildPart.prototype._$getTemplate(value);\n      const instance = new TemplateInstance(template, part);\n      stack.push({\n        type: 'template-instance',\n        instance,\n        part,\n        templatePartIndex: 0,\n        instancePartIndex: 0,\n        result: value,\n      });\n      // For TemplateResult values, we set the part value to the\n      // generated TemplateInstance\n      part._$committedValue = instance;\n    } else {\n      // TODO: if this isn't the server-rendered template, do we\n      // need to stop hydrating this subtree? Clear it? Add tests.\n      throw new Error(\n        'Hydration value mismatch: Unexpected TemplateResult rendered to part'\n      );\n    }\n  } else if (isIterable(value)) {\n    // currentChildPart.value will contain an array of ChildParts\n    stack.push({\n      part: part,\n      type: 'iterable',\n      value,\n      iterator: value[Symbol.iterator](),\n      done: false,\n    });\n    part._$committedValue = [];\n  } else {\n    // Fallback for everything else (nothing, Objects, Functions,\n    // etc.): we just initialize the part's value\n    // Note that `Node` value types are not currently supported during\n    // SSR, so that part of the cascade is missing.\n    stack.push({part: part, type: 'leaf'});\n    part._$committedValue = value == null ? '' : value;\n  }\n  return part;\n};\n\nconst closeChildPart = (\n  marker: Comment,\n  part: ChildPart | undefined,\n  stack: Array<ChildPartState>\n): ChildPart | undefined => {\n  if (part === undefined) {\n    throw new Error('unbalanced part marker');\n  }\n\n  part._$endNode = marker;\n\n  const currentState = stack.pop()!;\n\n  if (currentState.type === 'iterable') {\n    if (!currentState.iterator.next().done) {\n      throw new Error('unexpected longer than expected iterable');\n    }\n  }\n\n  if (stack.length > 0) {\n    const state = stack[stack.length - 1];\n    return state.part;\n  } else {\n    return undefined;\n  }\n};\n\nconst createAttributeParts = (\n  comment: Comment,\n  stack: Array<ChildPartState>,\n  options: RenderOptions\n) => {\n  // Get the nodeIndex from DOM. We're only using this for an integrity\n  // check right now, we might not need it.\n  const match = /lit-node (\\d+)/.exec(comment.data)!;\n  const nodeIndex = parseInt(match[1]);\n\n  // For void elements, the node the comment was referring to will be\n  // the previousSibling; for non-void elements, the comment is guaranteed\n  // to be the first child of the element (i.e. it won't have a previousSibling\n  // meaning it should use the parentElement)\n  const node = comment.previousElementSibling ?? comment.parentElement;\n  if (node === null) {\n    throw new Error('could not find node for attribute parts');\n  }\n  // Remove `defer-hydration` attribute, if any\n  node.removeAttribute('defer-hydration');\n\n  const state = stack[stack.length - 1];\n  if (state.type === 'template-instance') {\n    const instance = state.instance;\n    // eslint-disable-next-line no-constant-condition\n    while (true) {\n      // If the next template part is in attribute-position on the current node,\n      // create the instance part for it and prime its state\n      const templatePart = instance._$template.parts[state.templatePartIndex];\n      if (\n        templatePart === undefined ||\n        (templatePart.type !== PartType.ATTRIBUTE &&\n          templatePart.type !== PartType.ELEMENT) ||\n        templatePart.index !== nodeIndex\n      ) {\n        break;\n      }\n\n      if (templatePart.type === PartType.ATTRIBUTE) {\n        // The instance part is created based on the constructor saved in the\n        // template part\n        const instancePart = new templatePart.ctor(\n          node as HTMLElement,\n          templatePart.name,\n          templatePart.strings,\n          state.instance,\n          options\n        );\n\n        const value = isSingleExpression(\n          instancePart as unknown as AttributePartInfo\n        )\n          ? state.result.values[state.instancePartIndex]\n          : state.result.values;\n\n        // Setting the attribute value primes committed value with the resolved\n        // directive value; we only then commit that value for event/property\n        // parts since those were not serialized, and pass `noCommit` for the\n        // others to avoid perf impact of touching the DOM unnecessarily\n        const noCommit = !(\n          instancePart.type === PartType.EVENT ||\n          instancePart.type === PartType.PROPERTY\n        );\n        instancePart._$setValue(\n          value,\n          instancePart,\n          state.instancePartIndex,\n          noCommit\n        );\n        state.instancePartIndex += templatePart.strings.length - 1;\n        instance._parts.push(instancePart);\n      } else {\n        // templatePart.type === PartType.ELEMENT\n        const instancePart = new ElementPart(node, state.instance, options);\n        resolveDirective(\n          instancePart,\n          state.result.values[state.instancePartIndex++]\n        );\n        instance._parts.push(instancePart);\n      }\n      state.templatePartIndex++;\n    }\n  } else {\n    throw new Error('internal error');\n  }\n};\n\n// Number of 32 bit elements to use to create template digests\nconst digestSize = 2;\n// We need to specify a digest to use across rendering environments. This is a\n// simple digest build from a DJB2-ish hash modified from:\n// https://github.com/darkskyapp/string-hash/blob/master/index.js\n// It has been changed to an array of hashes to add additional bits.\n// Goals:\n//  - Extremely low collision rate. We may not be able to detect collisions.\n//  - Extremely fast.\n//  - Extremely small code size.\n//  - Safe to include in HTML comment text or attribute value.\n//  - Easily specifiable and implementable in multiple languages.\n// We don't care about cryptographic suitability.\nexport const digestForTemplateResult = (templateResult: TemplateResult) => {\n  const hashes = new Uint32Array(digestSize).fill(5381);\n\n  for (const s of templateResult.strings) {\n    for (let i = 0; i < s.length; i++) {\n      hashes[i % digestSize] = (hashes[i % digestSize] * 33) ^ s.charCodeAt(i);\n    }\n  }\n  return btoa(String.fromCharCode(...new Uint8Array(hashes.buffer)));\n};\n"]}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/development/is-server.d.ts b/front_end/third_party/lit-html/package/development/is-server.d.ts
new file mode 100644
index 0000000000000000000000000000000000000000..072c7b0f9621d390225751ef49d124e4582c9b98
--- /dev/null
+++ b/front_end/third_party/lit-html/package/development/is-server.d.ts
@@ -0,0 +1,15 @@
+/**
+ * @license
+ * Copyright 2022 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */
+/**
+ * A boolean that will be `true` in server environments like Node, and `false`
+ * in browser environments. Note that your server environment or toolchain must
+ * support the `"node"` export condition for this to be `true`.
+ *
+ * This can be used when authoring components to change behavior based on
+ * whether or not the component is executing in an SSR context.
+ */
+export declare const isServer = false;
+//# sourceMappingURL=is-server.d.ts.map
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/development/is-server.d.ts.map b/front_end/third_party/lit-html/package/development/is-server.d.ts.map
new file mode 100644
index 0000000000000000000000000000000000000000..6ea3f651d3377761598e4e4bf606b246e728dd6a
--- /dev/null
+++ b/front_end/third_party/lit-html/package/development/is-server.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"is-server.d.ts","sourceRoot":"","sources":["../src/is-server.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAWH;;;;;;;GAOG;AACH,eAAO,MAAM,QAAQ,QAAY,CAAC"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/development/is-server.js b/front_end/third_party/lit-html/package/development/is-server.js
new file mode 100644
index 0000000000000000000000000000000000000000..260de116ea219b44afc5af1a6a4327b377619225
--- /dev/null
+++ b/front_end/third_party/lit-html/package/development/is-server.js
@@ -0,0 +1,22 @@
+/**
+ * @license
+ * Copyright 2022 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */
+/**
+ * @fileoverview
+ *
+ * This file exports a boolean const whose value will depend on what environment
+ * the module is being imported from.
+ */
+const NODE_MODE = false;
+/**
+ * A boolean that will be `true` in server environments like Node, and `false`
+ * in browser environments. Note that your server environment or toolchain must
+ * support the `"node"` export condition for this to be `true`.
+ *
+ * This can be used when authoring components to change behavior based on
+ * whether or not the component is executing in an SSR context.
+ */
+export const isServer = NODE_MODE;
+//# sourceMappingURL=is-server.js.map
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/development/is-server.js.map b/front_end/third_party/lit-html/package/development/is-server.js.map
new file mode 100644
index 0000000000000000000000000000000000000000..033db3f64bfbda3ce1d7262f12ce5b40848305f1
--- /dev/null
+++ b/front_end/third_party/lit-html/package/development/is-server.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"is-server.js","sourceRoot":"","sources":["../src/is-server.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH;;;;;GAKG;AAEH,MAAM,SAAS,GAAG,KAAK,CAAC;AAExB;;;;;;;GAOG;AACH,MAAM,CAAC,MAAM,QAAQ,GAAG,SAAS,CAAC","sourcesContent":["/**\n * @license\n * Copyright 2022 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n/**\n * @fileoverview\n *\n * This file exports a boolean const whose value will depend on what environment\n * the module is being imported from.\n */\n\nconst NODE_MODE = false;\n\n/**\n * A boolean that will be `true` in server environments like Node, and `false`\n * in browser environments. Note that your server environment or toolchain must\n * support the `\"node\"` export condition for this to be `true`.\n *\n * This can be used when authoring components to change behavior based on\n * whether or not the component is executing in an SSR context.\n */\nexport const isServer = NODE_MODE;\n"]}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/development/lit-html.d.ts b/front_end/third_party/lit-html/package/development/lit-html.d.ts
index b5cd586743d4efd1e8ba3a0a9668472317bc2305..85fb1146d0c9222ae7524dd244068e21e637a816 100644
--- a/front_end/third_party/lit-html/package/development/lit-html.d.ts
+++ b/front_end/third_party/lit-html/package/development/lit-html.d.ts
@@ -183,9 +183,19 @@ declare const CHILD_PART = 2;
 declare const ELEMENT_PART = 6;
 declare const COMMENT_PART = 7;
 /**
+ * The return type of the template tag functions, {@linkcode html} and
+ * {@linkcode svg}.
+ *
+ * A `TemplateResult` object holds all the information about a template
+ * expression required to render it: the template strings, expression values,
+ * and type of template (html or svg).
+ *
+ * `TemplateResult` objects do not create any DOM on their own. To create or
+            options: RenderOptions | undefined;
 /**
- * @license
+            options: RenderOptions | undefined;
  * @license
+ *
  */
 export declare type TemplateResult<T extends ResultType = ResultType> = {
     ['_$litType$']: T;
@@ -301,19 +311,6 @@      * render to change the connected state of the part.
      */
     isConnected?: boolean;
  * Contains types that are part of the unstable debug API.
-import type { Directive } from './directive.js';
-/**
- * Renders a value, usually a lit-html TemplateResult, to the container.
- * @param value
- * @param container
- * @param options
- */
-export declare const render: {
-    (value: unknown, container: HTMLElement | DocumentFragment, options?: RenderOptions | undefined): RootPart;
-    setSanitizer: (newSanitizer: SanitizerFactory) => void;
-    createSanitizer: SanitizerFactory;
-    _testOnlyClearSanitizerFactoryDoNotCallOrElse: () => void;
-export declare namespace LitUnstable {
 import type { Directive } from './directive.js';
 export interface DirectiveParent {
     _$parent?: DirectiveParent;
@@ -518,5 +515,36 @@     _BooleanAttributePart: typeof BooleanAttributePart;
     _EventPart: typeof EventPart;
     _PropertyPart: typeof PropertyPart;
     _ElementPart: typeof ElementPart;
+};
+/**
+ * Renders a value, usually a lit-html TemplateResult, to the container.
+ *
+ * This example renders the text "Hello, Zoe!" inside a paragraph tag, appending
+ * it to the container `document.body`.
+ *
+ * ```js
+ * import {html, render} from 'lit';
+ *
+ * const name = "Zoe";
+ * render(html`<p>Hello, ${name}!</p>`, document.body);
+ * ```
+ *
+ * @param value Any [renderable
+ *   value](https://lit.dev/docs/templates/expressions/#child-expressions),
+ *   typically a {@linkcode TemplateResult} created by evaluating a template tag
+ *   like {@linkcode html} or {@linkcode svg}.
+ * @param container A DOM container to render to. The first render will append
+ *   the rendered value to the container, and subsequent renders will
+ *   efficiently update the rendered value if the same result type was
+ *   previously rendered there.
+ * @param options See {@linkcode RenderOptions} for options documentation.
+ * @see
+ * {@link https://lit.dev/docs/libraries/standalone-templates/#rendering-lit-html-templates| Rendering Lit HTML Templates}
+ */
+export declare const render: {
+    (value: unknown, container: HTMLElement | DocumentFragment, options?: RenderOptions): RootPart;
+    setSanitizer: (newSanitizer: SanitizerFactory) => void;
+    createSanitizer: SanitizerFactory;
+    _testOnlyClearSanitizerFactoryDoNotCallOrElse: () => void;
 };
 //# sourceMappingURL=lit-html.d.ts.map
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/development/lit-html.d.ts.map b/front_end/third_party/lit-html/package/development/lit-html.d.ts.map
index b4047751484d4c2cfa501bc8693823281df316d2..fb6d83a795c1a39543895c0f20561d96bcb331ce 100644
--- a/front_end/third_party/lit-html/package/development/lit-html.d.ts.map
+++ b/front_end/third_party/lit-html/package/development/lit-html.d.ts.map
@@ -1 +1 @@
-{"version":3,"file":"lit-html.d.ts","sourceRoot":"","sources":["../src/lit-html.ts"],"names":[],"mappings":"AAAA;;;;GAIG;;AAGH,OAAO,KAAK,EAAC,SAAS,EAA4B,MAAM,gBAAgB,CAAC;AAMzE;;;;;GAKG;AAEH,yBAAiB,WAAW,CAAC;IAC3B;;;;;;;;OAQG;IAEH,UAAiB,QAAQ,CAAC;QACxB,KAAY,KAAK,GACb,YAAY,GACZ,oBAAoB,GACpB,8BAA8B,GAC9B,gBAAgB,GAChB,WAAW,GACX,SAAS,GACT,eAAe,GACf,YAAY,CAAC;QACjB,UAAiB,YAAY;YAC3B,IAAI,EAAE,eAAe,CAAC;YACtB,QAAQ,EAAE,QAAQ,CAAC;YACnB,OAAO,EAAE,oBAAoB,CAAC;YAC9B,gBAAgB,EAAE,mBAAmB,CAAC;YACtC,KAAK,EAAE,YAAY,EAAE,CAAC;SACvB;QACD,UAAiB,WAAW;YAC1B,IAAI,EAAE,cAAc,CAAC;YACrB,EAAE,EAAE,MAAM,CAAC;YACX,KAAK,EAAE,OAAO,CAAC;YACf,SAAS,EAAE,WAAW,GAAG,gBAAgB,CAAC;YAC1C,OAAO,EAAE,aAAa,GAAG,SAAS,CAAC;YACnC,IAAI,EAAE,SAAS,GAAG,SAAS,CAAC;SAC7B;QACD,UAAiB,SAAS;YACxB,IAAI,EAAE,YAAY,CAAC;YACnB,EAAE,EAAE,MAAM,CAAC;YACX,KAAK,EAAE,OAAO,CAAC;YACf,SAAS,EAAE,WAAW,GAAG,gBAAgB,CAAC;YAC1C,OAAO,EAAE,aAAa,GAAG,SAAS,CAAC;YACnC,IAAI,EAAE,SAAS,CAAC;SACjB;QACD,UAAiB,oBAAoB;YACnC,IAAI,EAAE,uBAAuB,CAAC;YAC9B,QAAQ,EAAE,QAAQ,GAAG,gBAAgB,CAAC;YACtC,QAAQ,EAAE,gBA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AAM,CAAC,EAC9B,MAAM,EAAE,cAAc,EACtB,OAAO,EAAE,aAAa,GAAG,SAAS;IA0EpC,WAAW,CAAC,KAAK,EAAE,KAAK;CAOzB;AAED,YAAY,EAAC,WAAW,EAAC,CAAC;AAC1B,cAAM,WAAY,YAAW,cAAc;IAkBhC,OAAO,EAAE,OAAO;IAjBzB,QAAQ,CAAC,IAAI,KAAgB;IAM7B,gBAAgB,EAAE,SAAS,CAAC;IAQ5B,OAAO,EAAE,aAAa,GAAG,SAAS,CAAC;gBAG1B,OAAO,EAAE,OAAO,EACvB,MAAM,EAAE,cAAc,EACtB,OAAO,EAAE,aAAa,GAAG,SAAS;IAOpC,IAAI,aAAa,YAEhB;IAED,UAAU,CAAC,KAAK,EAAE,OAAO,GAAG,IAAI;CASjC;AAED;;;;;;;;;;;;;;;;;GAiBG;AACH,eAAO,MAAM,IAAI;;;;;gCA33CN,oBAAoB,QACvB,UAAU,KACf,CAAC,WAAW,EAAE,MAAM,MAAM,GAAG,SAAS,CAAC,CAAC;;yBAlThB,OAAO;;;;;;;;CA6rDjC,CAAC;AAmBF;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AACH,eAAO,MAAM,MAAM;YACV,OAAO,aACH,WAAW,GAAG,gBAAgB,YAC/B,aAAa,GACtB,QAAQ;iCAvyDyB,gBAAgB;;;CAi1DnD,CAAC"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/development/lit-html.js b/front_end/third_party/lit-html/package/development/lit-html.js
index e5c08814a85562d21424132ae77ce1294f8b6664..473f11d58804506ef9dbb4e9ea60ca98545f2252 100644
--- a/front_end/third_party/lit-html/package/development/lit-html.js
+++ b/front_end/third_party/lit-html/package/development/lit-html.js
@@ -8,6 +8,10 @@ const DEV_MODE = true;
 const ENABLE_EXTRA_SECURITY_HOOKS = true;
 const ENABLE_SHADYDOM_NOPATCH = true;
 /**
+ * considered safe by construction.
+// Use window for browser builds because IE11 doesn't have globalThis.
+const global = NODE_MODE ? globalThis : window;
+/**
  * Useful for visualizing and logging insights into what the Lit template system is doing.
  *
  * Compiled out of prod mode builds.
@@ -15,12 +19,13 @@  */
 const debugLogEvent = DEV_MODE
     ? (event) => {
 /**
- */
+        createHTML: (s) => s,
             .emitLitDebugLogEvents;
         if (!shouldEmit) {
             return;
         }
- * @license
+/**
+    })
             detail: event,
         }));
     }
@@ -29,35 +34,30 @@ // Used for connecting beginRender and endRender events when there are nested
 // renders when errors are thrown preventing an endRender event from being
 // called.
 let debugLogRenderId = 0;
-/**
- * `true` if we're building for google3 with temporary back-compat helpers.
- * This export is not present in prod builds.
- * @internal
- */
-export const INTERNAL = true;
 let issueWarning;
 if (DEV_MODE) {
-    (_a = globalThis.litIssuedWarnings) !== null && _a !== void 0 ? _a : (globalThis.litIssuedWarnings = new Set());
+    (_a = global.litIssuedWarnings) !== null && _a !== void 0 ? _a : (global.litIssuedWarnings = new Set());
     // Issue a warning, if we haven't already.
     issueWarning = (code, warning) => {
         warning += code
             ? ` See https://lit.dev/msg/${code} for more information.`
             : '';
- * SPDX-License-Identifier: BSD-3-Clause
 /**
+const noopSanitizer = (_node, _name, _type) => identityFunction;
             console.warn(warning);
+// after.
  * SPDX-License-Identifier: BSD-3-Clause
- * Copyright 2017 Google LLC
         }
     };
     issueWarning('dev-mode', `Lit is in dev mode. Not recommended for production!`);
 }
 const wrap = ENABLE_SHADYDOM_NOPATCH &&
-    ((_b = window.ShadyDOM) === null || _b === void 0 ? void 0 : _b.inUse) &&
+    ((_b = global.ShadyDOM) === null || _b === void 0 ? void 0 : _b.inUse) &&
-    ((_c = window.ShadyDOM) === null || _c === void 0 ? void 0 : _c.noPatch) === true
+    ((_c = global.ShadyDOM) === null || _c === void 0 ? void 0 : _c.noPatch) === true
- */
+/**
+        return;
     : (node) => node;
-const trustedTypes = globalThis.trustedTypes;
+const trustedTypes = global.trustedTypes;
 /**
  * Our TrustedTypePolicy for HTML which is declared using the html template
  * tag function.
@@ -106,20 +106,26 @@ const markerMatch = '?' + marker;
 // Text used to insert a comment marker node. We use processing instruction
 // syntax because it's slightly smaller, but parses as a comment node.
 const nodeMarker = `<${markerMatch}>`;
+// after.
 const ENABLE_SHADYDOM_NOPATCH = true;
 /**
+            ` setSanitizeDOMValueFactory should be called at most once.`);
+        createTreeWalker() {
+            return {};
+        },
+    }
+    : document;
 // Creates a dynamic marker. We never have to search for these in the DOM.
 const createMarker = (v = '') => d.createComment(v);
 const isPrimitive = (value) => value === null || (typeof value != 'object' && typeof value != 'function');
 const isArray = Array.isArray;
-const isIterable = (value) => {
-const ENABLE_SHADYDOM_NOPATCH = true;
+ * Useful for visualizing and logging insights into what the Lit template system is doing.
 const DEV_MODE = true;
-    return isArray(value) ||
+ */
-        // eslint-disable-next-line @typescript-eslint/no-explicit-any
+    // eslint-disable-next-line @typescript-eslint/no-explicit-any
  * Useful for visualizing and logging insights into what the Lit template system is doing.
 const DEV_MODE = true;
- * @license
+var _a, _b, _c, _d;
 const SPACE_CHAR = `[ \t\n\f\r]`;
 const ATTR_VALUE_CHAR = `[^ \t\n\f\r"'\`<>=]`;
 const NAME_CHAR = `[^\\s"'>=/]`;
@@ -282,86 +288,24 @@  * or attr. This restriction simplifies the cache lookup, which is on the hot
  * path for rendering.
  */
 const templateCache = new WeakMap();
-/**
- * Renders a value, usually a lit-html TemplateResult, to the container.
- * @param value
- * @param container
- * @param options
- */
- * @license
 // renders when errors are thrown preventing an endRender event from being
-    var _a, _b, _c;
-    const renderId = DEV_MODE ? debugLogRenderId++ : 0;
-    const partOwnerNode = (_a = options === null || options === void 0 ? void 0 : options.renderBefore) !== null && _a !== void 0 ? _a : container;
-    // This property needs to remain unminified.
-    // eslint-disable-next-line @typescript-eslint/no-explicit-any
-    let part = partOwnerNode['_$litPart$'];
-    debugLogEvent === null || debugLogEvent === void 0 ? void 0 : debugLogEvent({
-    }
  * SPDX-License-Identifier: BSD-3-Clause
  * @license
-    (_a = globalThis.litIssuedWarnings) !== null && _a !== void 0 ? _a : (globalThis.litIssuedWarnings = new Set());
-    }
 var _a, _b, _c, _d;
-        container,
+ */
-        options,
-        part,
-    });
-    : undefined;
 /**
  * @license
-            console.warn(warning);
-        // Internal modification: don't clear container to match lit-html 2.0
-        if (INTERNAL &&
-            ((_c = options) === null || _c === void 0 ? void 0 : _c.clearContainerForLit2MigrationOnly) ===
-    : undefined;
 var _a, _b, _c, _d;
-            let n = container.firstChild;
-            // Clear only up to the `endNode` aka `renderBefore` node.
-            while (n && n !== endNode) {
-                const next = n.nextSibling;
-                n.remove();
-                n = next;
-            }
-        }
-        // This property needs to remain unminified.
-        // eslint-disable-next-line @typescript-eslint/no-explicit-any
-        partOwnerNode['_$litPart$'] = part = new ChildPart(container.insertBefore(createMarker(), endNode), endNode, undefined, options !== null && options !== void 0 ? options : {});
-    }
-    part._$setValue(value);
-    debugLogEvent === null || debugLogEvent === void 0 ? void 0 : debugLogEvent({
-// Used for connecting beginRender and endRender events when there are nested
 var _a, _b, _c, _d;
  * @license
-    (_a = globalThis.litIssuedWarnings) !== null && _a !== void 0 ? _a : (globalThis.litIssuedWarnings = new Set());
-    }
 var _a, _b, _c, _d;
-    }
 const DEV_MODE = true;
-        options,
-        part,
-    : undefined;
+/**
-// Used for connecting beginRender and endRender events when there are nested
 const DEV_MODE = true;
 const DEV_MODE = true;
- * @license
-if (ENABLE_EXTRA_SECURITY_HOOKS) {
-    render.setSanitizer = setSanitizer;
-// renders when errors are thrown preventing an endRender event from being
+/**
-    if (DEV_MODE) {
-        render._testOnlyClearSanitizerFactoryDoNotCallOrElse =
-            _testOnlyClearSanitizerFactoryDoNotCallOrElse;
-    }
-}
-const walker = d.createTreeWalker(d, 129 /* NodeFilter.SHOW_{ELEMENT|COMMENT} */, null, false);
-let sanitizerFactoryInternal = noopSanitizer;
-/**
- * Returns an HTML string for the given TemplateStringsArray and result type
-// renders when errors are thrown preventing an endRender event from being
 const DEV_MODE = true;
-// renders when errors are thrown preventing an endRender event from being
 const ENABLE_EXTRA_SECURITY_HOOKS = true;
- * `ChildPart`s and suffixes on bound attributes denoting the `AttributeParts`.
  *
  * @param strings template strings array
  * @param type HTML or SVG
@@ -516,16 +461,30 @@     // TemplateStringArray objects.
     if (!Array.isArray(strings) || !strings.hasOwnProperty('raw')) {
         let message = 'invalid template strings array';
         if (DEV_MODE) {
- * SPDX-License-Identifier: BSD-3-Clause
+            message = `
+          Internal Error: expected template strings to be an array
+          with a 'raw' field. Faking a template strings array by
+/**
+// a valid element name and attribute name. We don't support dynamic names (yet)
+// we stay in the same state.
  * Copyright 2017 Google LLC
- * SPDX-License-Identifier: BSD-3-Clause
+/**
+const ENABLE_EXTRA_SECURITY_HOOKS = true;
  * SPDX-License-Identifier: BSD-3-Clause
- * SPDX-License-Identifier: BSD-3-Clause
+/**
+const ENABLE_EXTRA_SECURITY_HOOKS = true;
  */
- * SPDX-License-Identifier: BSD-3-Clause
+/**
+const ENABLE_EXTRA_SECURITY_HOOKS = true;
 var _a, _b, _c, _d;
- * SPDX-License-Identifier: BSD-3-Clause
+/**
+const ENABLE_EXTRA_SECURITY_HOOKS = true;
 const DEV_MODE = true;
+          https://github.com/lit/lit/issues/new?template=bug_report.md
+          and include information about your build tooling, if any.
+        `
+                .trim()
+                .replace(/\n */g, '\n');
         }
         throw new Error(message);
     }
@@ -889,6 +848,7 @@     get endNode() {
         return this._$endNode;
     }
     _$setValue(value, directiveParent = this) {
+        var _a;
         if (DEV_MODE && this.parentNode === null) {
             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.`);
         }
@@ -919,6 +879,12 @@         else if (value['_$litType$'] !== undefined) {
             this._commitTemplateResult(value);
         }
         else if (value.nodeType !== undefined) {
+            if (DEV_MODE && ((_a = this.options) === null || _a === void 0 ? void 0 : _a.host) === value) {
+                this._commitText(`[probable mistake: rendered a template's host in itself ` +
+                    `(commonly caused by writing \${this} in a template]`);
+                console.warn(`Attempted to render the template host`, value, `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.`);
+                return;
+            }
             this._commitNode(value);
         }
         else if (isIterable(value)) {
@@ -1460,23 +1426,102 @@ };
 // Apply polyfills if available
 const polyfillSupport = DEV_MODE
  * Useful for visualizing and logging insights into what the Lit template system is doing.
-const wrap = ENABLE_SHADYDOM_NOPATCH &&
+    return isArray(value) ||
  * Useful for visualizing and logging insights into what the Lit template system is doing.
-    ((_b = window.ShadyDOM) === null || _b === void 0 ? void 0 : _b.inUse) &&
+        // eslint-disable-next-line @typescript-eslint/no-explicit-any
 polyfillSupport === null || polyfillSupport === void 0 ? void 0 : polyfillSupport(Template, ChildPart);
 // IMPORTANT: do not change the property name or the assignment expression.
 // This line will be used in regexes to search for lit-html usage.
 /**
+        typeof ((_a = value) === null || _a === void 0 ? void 0 : _a[Symbol.iterator]) === 'function';
+if (DEV_MODE && global.litHtmlVersions.length > 1) {
+/**
  */
+ * SPDX-License-Identifier: BSD-3-Clause
+        `Loading multiple versions is not recommended.`);
+}
+/**
  * @license
+        }));
+ *
 /**
+const ATTR_VALUE_CHAR = `[^ \t\n\f\r"'\`<>=]`;
+ * it to the container `document.body`.
+ *
+ * ```js
+ *
  */
+ *
+ * const name = "Zoe";
+ * render(html`<p>Hello, ${name}!</p>`, document.body);
+ * ```
+ *
+ * @param value Any [renderable
+ *   value](https://lit.dev/docs/templates/expressions/#child-expressions),
+ *   typically a {@linkcode TemplateResult} created by evaluating a template tag
+ *   like {@linkcode html} or {@linkcode svg}.
+ * @param container A DOM container to render to. The first render will append
+// we also dynamically create a regex to find the matching end tags for raw
  * Copyright 2017 Google LLC
 /**
+ *   (comment start) or (tag) or (dynamic tag binding)
+ *   previously rendered there.
+ * @param options See {@linkcode RenderOptions} for options documentation.
+ * @see
+ * {@link https://lit.dev/docs/libraries/standalone-templates/#rendering-lit-html-templates| Rendering Lit HTML Templates}
+ */
+export const render = (value, container, options) => {
+    var _a, _b;
+// text elements.
+        // Give a clearer error message than
+        //     Uncaught TypeError: Cannot read properties of null (reading
+        //     '_$litPart$')
+        // which reads like an internal Lit error.
+// text elements.
  */
+    }
+    const renderId = DEV_MODE ? debugLogRenderId++ : 0;
+    const partOwnerNode = (_a = options === null || options === void 0 ? void 0 : options.renderBefore) !== null && _a !== void 0 ? _a : container;
+    // This property needs to remain unminified.
+    // eslint-disable-next-line @typescript-eslint/no-explicit-any
+    let part = partOwnerNode['_$litPart$'];
+    debugLogEvent === null || debugLogEvent === void 0 ? void 0 : debugLogEvent({
+    }
  * SPDX-License-Identifier: BSD-3-Clause
+        id: renderId,
+        value,
+        container,
+        options,
+        part,
+    });
+    : undefined;
 /**
+        const endNode = (_b = options === null || options === void 0 ? void 0 : options.renderBefore) !== null && _b !== void 0 ? _b : null;
+        // This property needs to remain unminified.
+        // eslint-disable-next-line @typescript-eslint/no-explicit-any
+        partOwnerNode['_$litPart$'] = part = new ChildPart(container.insertBefore(createMarker(), endNode), endNode, undefined, options !== null && options !== void 0 ? options : {});
+    }
+    part._$setValue(value);
+    debugLogEvent === null || debugLogEvent === void 0 ? void 0 : debugLogEvent({
+        kind: 'end render',
+        id: renderId,
+        value,
+        container,
+        options,
+        part,
+    : undefined;
+ * @license
  */
+const DEV_MODE = true;
+};
+ * @license
  */
+const ENABLE_EXTRA_SECURITY_HOOKS = true;
+    render.setSanitizer = setSanitizer;
+    render.createSanitizer = createSanitizer;
+    if (DEV_MODE) {
+        render._testOnlyClearSanitizerFactoryDoNotCallOrElse =
+            _testOnlyClearSanitizerFactoryDoNotCallOrElse;
+    }
 }
 //# sourceMappingURL=lit-html.js.map
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/development/lit-html.js.map b/front_end/third_party/lit-html/package/development/lit-html.js.map
index 60662e443ff0083f110325d74909e91ec83bff79..5765dc1f2404fc2835f703122e1e2ac32a26e7f6 100644
--- a/front_end/third_party/lit-html/package/development/lit-html.js.map
+++ b/front_end/third_party/lit-html/package/development/lit-html.js.map
@@ -1 +1 @@
-{"version":3,"file":"lit-html.js","sourceRoot":"","sources":["../src/lit-html.ts"],"names":[],"mappings":"AAAA;;;;GAIG;;AAKH,MAAM,QAAQ,GAAG,IAAI,CAAC;AACtB,MAAM,2BAA2B,GAAG,IAAI,CAAC;AACzC,MAAM,uBAAuB,GAAG,IAAI,CAAC;AA8KrC;;;;GAIG;AACH,MAAM,aAAa,GAAG,QAAQ;IAC5B,CAAC,CAAC,CAAC,KAAiC,EAAE,EAAE;QACpC,MAAM,UAAU,GAAI,MAAwC;aACzD,qBAAqB,CAAC;QACzB,IAAI,CAAC,UAAU,EAAE;YACf,OAAO;SACR;QACD,MAAM,CAAC,aAAa,CAClB,IAAI,WAAW,CAA6B,WAAW,EAAE;YACvD,MAAM,EAAE,KAAK;SACd,CAAC,CACH,CAAC;IACJ,CAAC;IACH,CAAC,CAAC,SAAS,CAAC;AACd,6EAA6E;AAC7E,0EAA0E;AAC1E,UAAU;AACV,IAAI,gBAAgB,GAAG,CAAC,CAAC;AAEzB;;;;GAIG;AACH,MAAM,CAAC,MAAM,QAAQ,GAAG,IAAI,CAAC;AAE7B,IAAI,YAAqD,CAAC;AAE1D,IAAI,QAAQ,EAAE;IACZ,MAAA,UAAU,CAAC,iBAAiB,oCAA5B,UAAU,CAAC,iBAAiB,GAAK,IAAI,GAAG,EAAE,EAAC;IAE3C,0CAA0C;IAC1C,YAAY,GAAG,CAAC,IAAY,EAAE,OAAe,EAAE,EAAE;QAC/C,OAAO,IAAI,IAAI;YACb,CAAC,CAAC,4BAA4B,IAAI,wBAAwB;YAC1D,CAAC,CAAC,EAAE,CAAC;QACP,IAAI,CAAC,UAAU,CAAC,iBAAkB,CAAC,GAAG,CAAC,OAAO,CAAC,EAAE;YAC/C,OAAO,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;YACtB,UAAU,CAAC,iBAAkB,CAAC,GAAG,CAAC,OAAO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AAE,YAAY;IAC3B,YAAY,EAAE,WAAW;CAC1B,CAAC;AAEF,+BAA+B;AAC/B,MAAM,eAAe,GAAG,QAAQ;IAC9B,CAAC,CAAC,MAAM,CAAC,6BAA6B;IACtC,CAAC,CAAC,MAAM,CAAC,sBAAsB,CAAC;AAClC,eAAe,aAAf,eAAe,uBAAf,eAAe,CAAG,QAAQ,EAAE,SAAS,CAAC,CAAC;AAEvC,2EAA2E;AAC3E,kEAAkE;AAClE,OAAC,UAAU,CAAC,eAAe,oCAA1B,UAAU,CAAC,eAAe,GAAK,EAAE,EAAC,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;AAClD,IAAI,QAAQ,IAAI,UAAU,CAAC,eAAe,CAAC,MAAM,GAAG,CAAC,EAAE;IACrD,YAAa,CACX,mBAAmB,EACnB,mCAAmC;QACjC,+CAA+C,CAClD,CAAC;CACH","sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n// IMPORTANT: these imports must be type-only\nimport type {Directive, DirectiveResult, PartInfo} from './directive.js';\n\nconst DEV_MODE = true;\nconst ENABLE_EXTRA_SECURITY_HOOKS = true;\nconst ENABLE_SHADYDOM_NOPATCH = true;\n\n/**\n * Contains types that are part of the unstable debug API.\n *\n * Everything in this API is not stable and may change or be removed in the future,\n * even on patch releases.\n */\n// eslint-disable-next-line @typescript-eslint/no-namespace\nexport namespace LitUnstable {\n  /**\n   * When Lit is running in dev mode and `window.emitLitDebugLogEvents` is true,\n   * we will emit 'lit-debug' events to window, with live details about the update and render\n   * lifecycle. These can be useful for writing debug tooling and visualizations.\n   *\n   * Please be aware that running with window.emitLitDebugLogEvents has performance overhead,\n   * making certain operations that are normally very cheap (like a no-op render) much slower,\n   * because we must copy data and dispatch events.\n   */\n  // eslint-disable-next-line @typescript-eslint/no-namespace\n  export namespace DebugLog {\n    export type Entry =\n      | TemplatePrep\n      | TemplateInstantiated\n      | TemplateInstantiatedAndUpdated\n      | TemplateUpdating\n      | BeginRender\n      | EndRender\n      | CommitPartEntry\n      | SetPartValue;\n    export interface TemplatePrep {\n      kind: 'template prep';\n      template: Template;\n      strings: TemplateStringsArray;\n      clonableTemplate: HTMLTemplateElement;\n      parts: TemplatePart[];\n    }\n    export interface BeginRender {\n      kind: 'begin render';\n      id: number;\n      value: unknown;\n      container: HTMLElement | DocumentFragment;\n      options: RenderOptions | undefined;\n      part: ChildPart | undefined;\n    }\n    export interface EndRender {\n      kind: 'end render';\n      id: number;\n      value: unknown;\n      container: HTMLElement | DocumentFragment;\n      options: RenderOptions | undefined;\n      part: ChildPart;\n    }\n    export interface TemplateInstantiated {\n      kind: 'template instantiated';\n      template: Template | CompiledTemplate;\n      instance: TemplateInstance;\n      options: RenderOptions | undefined;\n      fragment: Node;\n      parts: Array<Part | undefined>;\n      values: unknown[];\n    }\n    export interface TemplateInstantiatedAndUpdated {\n      kind: 'template instantiated and updated';\n      template: Template | CompiledTemplate;\n      instance: TemplateInstance;\n      options: RenderOptions | undefined;\n      fragment: Node;\n      parts: Array<Part | undefined>;\n      values: unknown[];\n    }\n    export interface TemplateUpdating {\n      kind: 'template updating';\n      template: Template | CompiledTemplate;\n      instance: TemplateInstance;\n      options: RenderOptions | undefined;\n      parts: Array<Part | undefined>;\n      values: unknown[];\n    }\n    export interface SetPartValue {\n      kind: 'set part';\n      part: Part;\n      value: unknown;\n      valueIndex: number;\n      values: unknown[];\n      templateInstance: TemplateInstance;\n    }\n\n    export type CommitPartEntry =\n      | CommitNothingToChildEntry\n      | CommitText\n      | CommitNode\n      | CommitAttribute\n      | CommitProperty\n      | CommitBooleanAttribute\n      | CommitEventListener\n      | CommitToElementBinding;\n\n    export interface CommitNothingToChildEntry {\n      kind: 'commit nothing to child';\n      start: ChildNode;\n      end: ChildNode | null;\n      parent: Disconnectable | undefined;\n      options: RenderOptions | undefined;\n    }\n\n    export interface CommitText {\n      kind: 'commit text';\n      node: Text;\n      value: unknown;\n      options: RenderOptions | undefined;\n    }\n\n    export interface CommitNode {\n      kind: 'commit node';\n      start: Node;\n      parent: Disconnectable | undefined;\n      value: Node;\n      options: RenderOptions | undefined;\n    }\n\n    export interface CommitAttribute {\n      kind: 'commit attribute';\n      element: Element;\n      name: string;\n      value: unknown;\n      options: RenderOptions | undefined;\n    }\n\n    export interface CommitProperty {\n      kind: 'commit property';\n      element: Element;\n      name: string;\n      value: unknown;\n      options: RenderOptions | undefined;\n    }\n\n    export interface CommitBooleanAttribute {\n      kind: 'commit boolean attribute';\n      element: Element;\n      name: string;\n      value: boolean;\n      options: RenderOptions | undefined;\n    }\n\n    export interface CommitEventListener {\n      kind: 'commit event listener';\n      element: Element;\n      name: string;\n      value: unknown;\n      oldListener: unknown;\n      options: RenderOptions | undefined;\n      // True if we're removing the old event listener (e.g. because settings changed, or value is nothing)\n      removeListener: boolean;\n      // True if we're adding a new event listener (e.g. because first render, or settings changed)\n      addListener: boolean;\n    }\n\n    export interface CommitToElementBinding {\n      kind: 'commit to element binding';\n      element: Element;\n      value: unknown;\n      options: RenderOptions | undefined;\n    }\n  }\n}\n\ninterface DebugLoggingWindow {\n  // Even in dev mode, we generally don't want to emit these events, as that's\n  // another level of cost, so only emit them when DEV_MODE is true _and_ when\n  // window.emitLitDebugEvents is true.\n  emitLitDebugLogEvents?: boolean;\n}\n\n/**\n * Useful for visualizing and logging insights into what the Lit template system is doing.\n *\n * Compiled out of prod mode builds.\n */\nconst debugLogEvent = DEV_MODE\n  ? (event: LitUnstable.DebugLog.Entry) => {\n      const shouldEmit = (window as unknown as DebugLoggingWindow)\n        .emitLitDebugLogEvents;\n      if (!shouldEmit) {\n        return;\n      }\n      window.dispatchEvent(\n        new CustomEvent<LitUnstable.DebugLog.Entry>('lit-debug', {\n          detail: event,\n        })\n      );\n    }\n  : undefined;\n// Used for connecting beginRender and endRender events when there are nested\n// renders when errors are thrown preventing an endRender event from being\n// called.\nlet debugLogRenderId = 0;\n\n/**\n * `true` if we're building for google3 with temporary back-compat helpers.\n * This export is not present in prod builds.\n * @internal\n */\nexport const INTERNAL = true;\n\nlet issueWarning: (code: string, warning: string) => void;\n\nif (DEV_MODE) {\n  globalThis.litIssuedWarnings ??= new Set();\n\n  // Issue a warning, if we haven't already.\n  issueWarning = (code: string, warning: string) => {\n    warning += code\n      ? ` See https://lit.dev/msg/${code} for more information.`\n      : '';\n    if (!globalThis.litIssuedWarnings!.has(warning)) {\n      console.warn(warning);\n      globalThis.litIssuedWarnings!.add(warning);\n    }\n  };\n\n  issueWarning(\n    'dev-mode',\n    `Lit is in dev mode. Not recommended for production!`\n  );\n}\n\nconst wrap =\n  ENABLE_SHADYDOM_NOPATCH &&\n  window.ShadyDOM?.inUse &&\n  window.ShadyDOM?.noPatch === true\n    ? window.ShadyDOM!.wrap\n    : (node: Node) => node;\n\nconst trustedTypes = (globalThis as unknown as Partial<Window>).trustedTypes;\n\n/**\n * Our TrustedTypePolicy for HTML which is declared using the html template\n * tag function.\n *\n * That HTML is a developer-authored constant, and is parsed with innerHTML\n * before any untrusted expressions have been mixed in. Therefor it is\n * considered safe by construction.\n */\nconst policy = trustedTypes\n  ? trustedTypes.createPolicy('lit-html', {\n      createHTML: (s) => s,\n    })\n  : undefined;\n\n/**\n * Used to sanitize any value before it is written into the DOM. This can be\n * used to implement a security policy of allowed and disallowed values in\n * order to prevent XSS attacks.\n *\n * One way of using this callback would be to check attributes and properties\n * against a list of high risk fields, and require that values written to such\n * fields be instances of a class which is safe by construction. Closure's Safe\n * HTML Types is one implementation of this technique (\n * https://github.com/google/safe-html-types/blob/master/doc/safehtml-types.md).\n * The TrustedTypes polyfill in API-only mode could also be used as a basis\n * for this technique (https://github.com/WICG/trusted-types).\n *\n * @param node The HTML node (usually either a #text node or an Element) that\n *     is being written to. Note that this is just an exemplar node, the write\n *     may take place against another instance of the same class of node.\n * @param name The name of an attribute or property (for example, 'href').\n * @param type Indicates whether the write that's about to be performed will\n *     be to a property or a node.\n * @return A function that will sanitize this class of writes.\n */\nexport type SanitizerFactory = (\n  node: Node,\n  name: string,\n  type: 'property' | 'attribute'\n) => ValueSanitizer;\n\n/**\n * A function which can sanitize values that will be written to a specific kind\n * of DOM sink.\n *\n * See SanitizerFactory.\n *\n * @param value The value to sanitize. Will be the actual value passed into\n *     the lit-html template literal, so this could be of any type.\n * @return The value to write to the DOM. Usually the same as the input value,\n *     unless sanitization is needed.\n */\nexport type ValueSanitizer = (value: unknown) => unknown;\n\nconst identityFunction: ValueSanitizer = (value: unknown) => value;\nconst noopSanitizer: SanitizerFactory = (\n  _node: Node,\n  _name: string,\n  _type: 'property' | 'attribute'\n) => identityFunction;\n\n/** Sets the global sanitizer factory. */\nconst setSanitizer = (newSanitizer: SanitizerFactory) => {\n  if (!ENABLE_EXTRA_SECURITY_HOOKS) {\n    return;\n  }\n  if (sanitizerFactoryInternal !== noopSanitizer) {\n    throw new Error(\n      `Attempted to overwrite existing lit-html security policy.` +\n        ` setSanitizeDOMValueFactory should be called at most once.`\n    );\n  }\n  sanitizerFactoryInternal = newSanitizer;\n};\n\n/**\n * Only used in internal tests, not a part of the public API.\n */\nconst _testOnlyClearSanitizerFactoryDoNotCallOrElse = () => {\n  sanitizerFactoryInternal = noopSanitizer;\n};\n\nconst createSanitizer: SanitizerFactory = (node, name, type) => {\n  return sanitizerFactoryInternal(node, name, type);\n};\n\n// Added to an attribute name to mark the attribute as bound so we can find\n// it easily.\nconst boundAttributeSuffix = '$lit$';\n\n// This marker is used in many syntactic positions in HTML, so it must be\n// a valid element name and attribute name. We don't support dynamic names (yet)\n// but this at least ensures that the parse tree is closer to the template\n// intention.\nconst marker = `lit$${String(Math.random()).slice(9)}$`;\n\n// String used to tell if a comment is a marker comment\nconst markerMatch = '?' + marker;\n\n// Text used to insert a comment marker node. We use processing instruction\n// syntax because it's slightly smaller, but parses as a comment node.\nconst nodeMarker = `<${markerMatch}>`;\n\nconst d = document;\n\n// Creates a dynamic marker. We never have to search for these in the DOM.\nconst createMarker = (v = '') => d.createComment(v);\n\n// https://tc39.github.io/ecma262/#sec-typeof-operator\ntype Primitive = null | undefined | boolean | number | string | symbol | bigint;\nconst isPrimitive = (value: unknown): value is Primitive =>\n  value === null || (typeof value != 'object' && typeof value != 'function');\nconst isArray = Array.isArray;\nconst isIterable = (value: unknown): value is Iterable<unknown> =>\n  isArray(value) ||\n  // eslint-disable-next-line @typescript-eslint/no-explicit-any\n  typeof (value as any)?.[Symbol.iterator] === 'function';\n\nconst SPACE_CHAR = `[ \\t\\n\\f\\r]`;\nconst ATTR_VALUE_CHAR = `[^ \\t\\n\\f\\r\"'\\`<>=]`;\nconst NAME_CHAR = `[^\\\\s\"'>=/]`;\n\n// These regexes represent the five parsing states that we care about in the\n// Template's HTML scanner. They match the *end* of the state they're named\n// after.\n// Depending on the match, we transition to a new state. If there's no match,\n// we stay in the same state.\n// Note that the regexes are stateful. We utilize lastIndex and sync it\n// across the multiple regexes used. In addition to the five regexes below\n// we also dynamically create a regex to find the matching end tags for raw\n// text elements.\n\n/**\n * End of text is: `<` followed by:\n *   (comment start) or (tag) or (dynamic tag binding)\n */\nconst textEndRegex = /<(?:(!--|\\/[^a-zA-Z])|(\\/?[a-zA-Z][^>\\s]*)|(\\/?$))/g;\nconst COMMENT_START = 1;\nconst TAG_NAME = 2;\nconst DYNAMIC_TAG_NAME = 3;\n\nconst commentEndRegex = /-->/g;\n/**\n * Comments not started with <!--, like </{, can be ended by a single `>`\n */\nconst comment2EndRegex = />/g;\n\n/**\n * The tagEnd regex matches the end of the \"inside an opening\" tag syntax\n * position. It either matches a `>`, an attribute-like sequence, or the end\n * of the string after a space (attribute-name position ending).\n *\n * See attributes in the HTML spec:\n * https://www.w3.org/TR/html5/syntax.html#elements-attributes\n *\n * \" \\t\\n\\f\\r\" are HTML space characters:\n * https://infra.spec.whatwg.org/#ascii-whitespace\n *\n * So an attribute is:\n *  * The name: any character except a whitespace character, (\"), ('), \">\",\n *    \"=\", or \"/\". Note: this is different from the HTML spec which also excludes control characters.\n *  * Followed by zero or more space characters\n *  * Followed by \"=\"\n *  * Followed by zero or more space characters\n *  * Followed by:\n *    * Any character except space, ('), (\"), \"<\", \">\", \"=\", (`), or\n *    * (\") then any non-(\"), or\n *    * (') then any non-(')\n */\nconst tagEndRegex = new RegExp(\n  `>|${SPACE_CHAR}(?:(${NAME_CHAR}+)(${SPACE_CHAR}*=${SPACE_CHAR}*(?:${ATTR_VALUE_CHAR}|(\"|')|))|$)`,\n  'g'\n);\nconst ENTIRE_MATCH = 0;\nconst ATTRIBUTE_NAME = 1;\nconst SPACES_AND_EQUALS = 2;\nconst QUOTE_CHAR = 3;\n\nconst singleQuoteAttrEndRegex = /'/g;\nconst doubleQuoteAttrEndRegex = /\"/g;\n/**\n * Matches the raw text elements.\n *\n * Comments are not parsed within raw text elements, so we need to search their\n * text content for marker strings.\n */\nconst rawTextElement = /^(?:script|style|textarea|title)$/i;\n\n/** TemplateResult types */\nconst HTML_RESULT = 1;\nconst SVG_RESULT = 2;\n\ntype ResultType = typeof HTML_RESULT | typeof SVG_RESULT;\n\n// TemplatePart types\n// IMPORTANT: these must match the values in PartType\nconst ATTRIBUTE_PART = 1;\nconst CHILD_PART = 2;\nconst PROPERTY_PART = 3;\nconst BOOLEAN_ATTRIBUTE_PART = 4;\nconst EVENT_PART = 5;\nconst ELEMENT_PART = 6;\nconst COMMENT_PART = 7;\n\n/**\n * The return type of the template tag functions.\n */\nexport type TemplateResult<T extends ResultType = ResultType> = {\n  // This property needs to remain unminified.\n  ['_$litType$']: T;\n  strings: TemplateStringsArray;\n  values: unknown[];\n};\n\nexport type HTMLTemplateResult = TemplateResult<typeof HTML_RESULT>;\n\nexport type SVGTemplateResult = TemplateResult<typeof SVG_RESULT>;\n\nexport interface CompiledTemplateResult {\n  // This is a factory in order to make template initialization lazy\n  // and allow ShadyRenderOptions scope to be passed in.\n  // This property needs to remain unminified.\n  ['_$litType$']: CompiledTemplate;\n  values: unknown[];\n}\n\nexport interface CompiledTemplate extends Omit<Template, 'el'> {\n  // el is overridden to be optional. We initialize it on first render\n  el?: HTMLTemplateElement;\n\n  // The prepared HTML string to create a template element from.\n  h: TrustedHTML;\n}\n\n/**\n * Generates a template literal tag function that returns a TemplateResult with\n * the given result type.\n */\nconst tag =\n  <T extends ResultType>(type: T) =>\n  (strings: TemplateStringsArray, ...values: unknown[]): TemplateResult<T> => {\n    // Warn against templates octal escape sequences\n    // We do this here rather than in render so that the warning is closer to the\n    // template definition.\n    if (DEV_MODE && strings.some((s) => s === undefined)) {\n      console.warn(\n        'Some template strings are undefined.\\n' +\n          'This is probably caused by illegal octal escape sequences.'\n      );\n    }\n    return {\n      // This property needs to remain unminified.\n      ['_$litType$']: type,\n      strings,\n      values,\n    };\n  };\n\n/**\n * Interprets a template literal as an HTML template that can efficiently\n * render to and update a container.\n *\n * ```ts\n * const header = (title: string) => html`<h1>${title}</h1>`;\n * ```\n *\n * The `html` tag returns a description of the DOM to render as a value. It is\n * lazy, meaning no work is done until the template is rendered. When rendering,\n * if a template comes from the same expression as a previously rendered result,\n * it's efficiently updated instead of replaced.\n */\nexport const html = tag(HTML_RESULT);\n\n/**\n * Interprets a template literal as an SVG fragment that can efficiently\n * render to and update a container.\n *\n * ```ts\n * const rect = svg`<rect width=\"10\" height=\"10\"></rect>`;\n *\n * const myImage = html`\n *   <svg viewBox=\"0 0 10 10\" xmlns=\"http://www.w3.org/2000/svg\">\n *     ${rect}\n *   </svg>`;\n * ```\n *\n * The `svg` *tag function* should only be used for SVG fragments, or elements\n * that would be contained **inside** an `<svg>` HTML element. A common error is\n * placing an `<svg>` *element* in a template tagged with the `svg` tag\n * function. The `<svg>` element is an HTML element and should be used within a\n * template tagged with the {@linkcode html} tag function.\n *\n * In LitElement usage, it's invalid to return an SVG fragment from the\n * `render()` method, as the SVG fragment will be contained within the element's\n * shadow root and thus cannot be used within an `<svg>` HTML element.\n */\nexport const svg = tag(SVG_RESULT);\n\n/**\n * A sentinel value that signals that a value was handled by a directive and\n * should not be written to the DOM.\n */\nexport const noChange = Symbol.for('lit-noChange');\n\n/**\n * A sentinel value that signals a ChildPart to fully clear its content.\n *\n * ```ts\n * const button = html`${\n *  user.isAdmin\n *    ? html`<button>DELETE</button>`\n *    : nothing\n * }`;\n * ```\n *\n * Prefer using `nothing` over other falsy values as it provides a consistent\n * behavior between various expression binding contexts.\n *\n * In child expressions, `undefined`, `null`, `''`, and `nothing` all behave the\n * same and render no nodes. In attribute expressions, `nothing` _removes_ the\n * attribute, while `undefined` and `null` will render an empty string. In\n * property expressions `nothing` becomes `undefined`.\n */\nexport const nothing = Symbol.for('lit-nothing');\n\n/**\n * The cache of prepared templates, keyed by the tagged TemplateStringsArray\n * and _not_ accounting for the specific template tag used. This means that\n * template tags cannot be dynamic - the must statically be one of html, svg,\n * or attr. This restriction simplifies the cache lookup, which is on the hot\n * path for rendering.\n */\nconst templateCache = new WeakMap<TemplateStringsArray, Template>();\n\n/**\n * Object specifying options for controlling lit-html rendering. Note that\n * while `render` may be called multiple times on the same `container` (and\n * `renderBefore` reference node) to efficiently update the rendered content,\n * only the options passed in during the first render are respected during\n * the lifetime of renders to that unique `container` + `renderBefore`\n * combination.\n */\nexport interface RenderOptions {\n  /**\n   * An object to use as the `this` value for event listeners. It's often\n   * useful to set this to the host component rendering a template.\n   */\n  host?: object;\n  /**\n   * A DOM node before which to render content in the container.\n   */\n  renderBefore?: ChildNode | null;\n  /**\n   * Node used for cloning the template (`importNode` will be called on this\n   * node). This controls the `ownerDocument` of the rendered DOM, along with\n   * any inherited context. Defaults to the global `document`.\n   */\n  creationScope?: {importNode(node: Node, deep?: boolean): Node};\n  /**\n   * The initial connected state for the top-level part being rendered. If no\n   * `isConnected` option is set, `AsyncDirective`s will be connected by\n   * default. Set to `false` if the initial render occurs in a disconnected tree\n   * and `AsyncDirective`s should see `isConnected === false` for their initial\n   * render. The `part.setConnected()` method must be used subsequent to initial\n   * render to change the connected state of the part.\n   */\n  isConnected?: boolean;\n}\n\n/**\n * Internally we can export this interface and change the type of\n * render()'s options.\n */\ninterface InternalRenderOptions extends RenderOptions {\n  /**\n   * An internal-only migration flag\n   * @internal\n   */\n  clearContainerForLit2MigrationOnly?: boolean;\n}\n\n/**\n * Renders a value, usually a lit-html TemplateResult, to the container.\n * @param value\n * @param container\n * @param options\n */\nexport const render = (\n  value: unknown,\n  container: HTMLElement | DocumentFragment,\n  options?: RenderOptions\n): RootPart => {\n  const renderId = DEV_MODE ? debugLogRenderId++ : 0;\n  const partOwnerNode = options?.renderBefore ?? container;\n  // This property needs to remain unminified.\n  // eslint-disable-next-line @typescript-eslint/no-explicit-any\n  let part: ChildPart = (partOwnerNode as any)['_$litPart$'];\n  debugLogEvent?.({\n    kind: 'begin render',\n    id: renderId,\n    value,\n    container,\n    options,\n    part,\n  });\n  if (part === undefined) {\n    const endNode = options?.renderBefore ?? null;\n    // Internal modification: don't clear container to match lit-html 2.0\n    if (\n      INTERNAL &&\n      (options as InternalRenderOptions)?.clearContainerForLit2MigrationOnly ===\n        true\n    ) {\n      let n = container.firstChild;\n      // Clear only up to the `endNode` aka `renderBefore` node.\n      while (n && n !== endNode) {\n        const next = n.nextSibling;\n        n.remove();\n        n = next;\n      }\n    }\n    // This property needs to remain unminified.\n    // eslint-disable-next-line @typescript-eslint/no-explicit-any\n    (partOwnerNode as any)['_$litPart$'] = part = new ChildPart(\n      container.insertBefore(createMarker(), endNode),\n      endNode,\n      undefined,\n      options ?? {}\n    );\n  }\n  part._$setValue(value);\n  debugLogEvent?.({\n    kind: 'end render',\n    id: renderId,\n    value,\n    container,\n    options,\n    part,\n  });\n  return part as RootPart;\n};\n\nif (ENABLE_EXTRA_SECURITY_HOOKS) {\n  render.setSanitizer = setSanitizer;\n  render.createSanitizer = createSanitizer;\n  if (DEV_MODE) {\n    render._testOnlyClearSanitizerFactoryDoNotCallOrElse =\n      _testOnlyClearSanitizerFactoryDoNotCallOrElse;\n  }\n}\n\nconst walker = d.createTreeWalker(\n  d,\n  129 /* NodeFilter.SHOW_{ELEMENT|COMMENT} */,\n  null,\n  false\n);\n\nlet sanitizerFactoryInternal: SanitizerFactory = noopSanitizer;\n\n//\n// Classes only below here, const variable declarations only above here...\n//\n// Keeping variable declarations and classes together improves minification.\n// Interfaces and type aliases can be interleaved freely.\n//\n\n// Type for classes that have a `_directive` or `_directives[]` field, used by\n// `resolveDirective`\nexport interface DirectiveParent {\n  _$parent?: DirectiveParent;\n  _$isConnected: boolean;\n  __directive?: Directive;\n  __directives?: Array<Directive | undefined>;\n}\n\n/**\n * Returns an HTML string for the given TemplateStringsArray and result type\n * (HTML or SVG), along with the case-sensitive bound attribute names in\n * template order. The HTML contains comment comment markers denoting the\n * `ChildPart`s and suffixes on bound attributes denoting the `AttributeParts`.\n *\n * @param strings template strings array\n * @param type HTML or SVG\n * @return Array containing `[html, attrNames]` (array returned for terseness,\n *     to avoid object fields since this code is shared with non-minified SSR\n *     code)\n */\nconst getTemplateHtml = (\n  strings: TemplateStringsArray,\n  type: ResultType\n): [TrustedHTML, Array<string | undefined>] => {\n  // Insert makers into the template HTML to represent the position of\n  // bindings. The following code scans the template strings to determine the\n  // syntactic position of the bindings. They can be in text position, where\n  // we insert an HTML comment, attribute value position, where we insert a\n  // sentinel string and re-write the attribute name, or inside a tag where\n  // we insert the sentinel string.\n  const l = strings.length - 1;\n  // Stores the case-sensitive bound attribute names in the order of their\n  // parts. ElementParts are also reflected in this array as undefined\n  // rather than a string, to disambiguate from attribute bindings.\n  const attrNames: Array<string | undefined> = [];\n  let html = type === SVG_RESULT ? '<svg>' : '';\n\n  // When we're inside a raw text tag (not it's text content), the regex\n  // will still be tagRegex so we can find attributes, but will switch to\n  // this regex when the tag ends.\n  let rawTextEndRegex: RegExp | undefined;\n\n  // The current parsing state, represented as a reference to one of the\n  // regexes\n  let regex = textEndRegex;\n\n  for (let i = 0; i < l; i++) {\n    const s = strings[i];\n    // The index of the end of the last attribute name. When this is\n    // positive at end of a string, it means we're in an attribute value\n    // position and need to rewrite the attribute name.\n    // We also use a special value of -2 to indicate that we encountered\n    // the end of a string in attribute name position.\n    let attrNameEndIndex = -1;\n    let attrName: string | undefined;\n    let lastIndex = 0;\n    let match!: RegExpExecArray | null;\n\n    // The conditions in this loop handle the current parse state, and the\n    // assignments to the `regex` variable are the state transitions.\n    while (lastIndex < s.length) {\n      // Make sure we start searching from where we previously left off\n      regex.lastIndex = lastIndex;\n      match = regex.exec(s);\n      if (match === null) {\n        break;\n      }\n      lastIndex = regex.lastIndex;\n      if (regex === textEndRegex) {\n        if (match[COMMENT_START] === '!--') {\n          regex = commentEndRegex;\n        } else if (match[COMMENT_START] !== undefined) {\n          // We started a weird comment, like </{\n          regex = comment2EndRegex;\n        } else if (match[TAG_NAME] !== undefined) {\n          if (rawTextElement.test(match[TAG_NAME])) {\n            // Record if we encounter a raw-text element. We'll switch to\n            // this regex at the end of the tag.\n            rawTextEndRegex = new RegExp(`</${match[TAG_NAME]}`, 'g');\n          }\n          regex = tagEndRegex;\n        } else if (match[DYNAMIC_TAG_NAME] !== undefined) {\n          if (DEV_MODE) {\n            throw new Error(\n              'Bindings in tag names are not supported. Please use static templates instead. ' +\n                'See https://lit.dev/docs/templates/expressions/#static-expressions'\n            );\n          }\n          regex = tagEndRegex;\n        }\n      } else if (regex === tagEndRegex) {\n        if (match[ENTIRE_MATCH] === '>') {\n          // End of a tag. If we had started a raw-text element, use that\n          // regex\n          regex = rawTextEndRegex ?? textEndRegex;\n          // We may be ending an unquoted attribute value, so make sure we\n          // clear any pending attrNameEndIndex\n          attrNameEndIndex = -1;\n        } else if (match[ATTRIBUTE_NAME] === undefined) {\n          // Attribute name position\n          attrNameEndIndex = -2;\n        } else {\n          attrNameEndIndex = regex.lastIndex - match[SPACES_AND_EQUALS].length;\n          attrName = match[ATTRIBUTE_NAME];\n          regex =\n            match[QUOTE_CHAR] === undefined\n              ? tagEndRegex\n              : match[QUOTE_CHAR] === '\"'\n              ? doubleQuoteAttrEndRegex\n              : singleQuoteAttrEndRegex;\n        }\n      } else if (\n        regex === doubleQuoteAttrEndRegex ||\n        regex === singleQuoteAttrEndRegex\n      ) {\n        regex = tagEndRegex;\n      } else if (regex === commentEndRegex || regex === comment2EndRegex) {\n        regex = textEndRegex;\n      } else {\n        // Not one of the five state regexes, so it must be the dynamically\n        // created raw text regex and we're at the close of that element.\n        regex = tagEndRegex;\n        rawTextEndRegex = undefined;\n      }\n    }\n\n    if (DEV_MODE) {\n      // If we have a attrNameEndIndex, which indicates that we should\n      // rewrite the attribute name, assert that we're in a valid attribute\n      // position - either in a tag, or a quoted attribute value.\n      console.assert(\n        attrNameEndIndex === -1 ||\n          regex === tagEndRegex ||\n          regex === singleQuoteAttrEndRegex ||\n          regex === doubleQuoteAttrEndRegex,\n        'unexpected parse state B'\n      );\n    }\n\n    // We have four cases:\n    //  1. We're in text position, and not in a raw text element\n    //     (regex === textEndRegex): insert a comment marker.\n    //  2. We have a non-negative attrNameEndIndex which means we need to\n    //     rewrite the attribute name to add a bound attribute suffix.\n    //  3. We're at the non-first binding in a multi-binding attribute, use a\n    //     plain marker.\n    //  4. We're somewhere else inside the tag. If we're in attribute name\n    //     position (attrNameEndIndex === -2), add a sequential suffix to\n    //     generate a unique attribute name.\n\n    // Detect a binding next to self-closing tag end and insert a space to\n    // separate the marker from the tag end:\n    const end =\n      regex === tagEndRegex && strings[i + 1].startsWith('/>') ? ' ' : '';\n    html +=\n      regex === textEndRegex\n        ? s + nodeMarker\n        : attrNameEndIndex >= 0\n        ? (attrNames.push(attrName!),\n          s.slice(0, attrNameEndIndex) +\n            boundAttributeSuffix +\n            s.slice(attrNameEndIndex)) +\n          marker +\n          end\n        : s +\n          marker +\n          (attrNameEndIndex === -2 ? (attrNames.push(undefined), i) : end);\n  }\n\n  const htmlResult: string | TrustedHTML =\n    html + (strings[l] || '<?>') + (type === SVG_RESULT ? '</svg>' : '');\n\n  // A security check to prevent spoofing of Lit template results.\n  // In the future, we may be able to replace this with Array.isTemplateObject,\n  // though we might need to make that check inside of the html and svg\n  // functions, because precompiled templates don't come in as\n  // TemplateStringArray objects.\n  if (!Array.isArray(strings) || !strings.hasOwnProperty('raw')) {\n    let message = 'invalid template strings array';\n    if (DEV_MODE) {\n      message =\n        `Internal Error: expected template strings to be an array ` +\n        `with a 'raw' field. 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    }\n    throw new Error(message);\n  }\n  // Returned as an array for terseness\n  return [\n    policy !== undefined\n      ? policy.createHTML(htmlResult)\n      : (htmlResult as unknown as TrustedHTML),\n    attrNames,\n  ];\n};\n\n/** @internal */\nexport type {Template};\nclass Template {\n  /** @internal */\n  el!: HTMLTemplateElement;\n  /** @internal */\n  parts: Array<TemplatePart> = [];\n\n  constructor(\n    // This property needs to remain unminified.\n    {strings, ['_$litType$']: type}: TemplateResult,\n    options?: RenderOptions\n  ) {\n    let node: Node | null;\n    let nodeIndex = 0;\n    let attrNameIndex = 0;\n    const partCount = strings.length - 1;\n    const parts = this.parts;\n\n    // Create template element\n    const [html, attrNames] = getTemplateHtml(strings, type);\n    this.el = Template.createElement(html, options);\n    walker.currentNode = this.el.content;\n\n    // Reparent SVG nodes into template root\n    if (type === SVG_RESULT) {\n      const content = this.el.content;\n      const svgElement = content.firstChild!;\n      svgElement.remove();\n      content.append(...svgElement.childNodes);\n    }\n\n    // Walk the template to find binding markers and create TemplateParts\n    while ((node = walker.nextNode()) !== null && parts.length < partCount) {\n      if (node.nodeType === 1) {\n        if (DEV_MODE) {\n          const tag = (node as Element).localName;\n          // Warn if `textarea` includes an expression and throw if `template`\n          // does since these are not supported. We do this by checking\n          // innerHTML for anything that looks like a marker. This catches\n          // cases like bindings in textarea there markers turn into text nodes.\n          if (\n            /^(?:textarea|template)$/i!.test(tag) &&\n            (node as Element).innerHTML.includes(marker)\n          ) {\n            const m =\n              `Expressions are not supported inside \\`${tag}\\` ` +\n              `elements. See https://lit.dev/msg/expression-in-${tag} for more ` +\n              `information.`;\n            if (tag === 'template') {\n              throw new Error(m);\n            } else issueWarning('', m);\n          }\n        }\n        // TODO (justinfagnani): for attempted dynamic tag names, we don't\n        // increment the bindingIndex, and it'll be off by 1 in the element\n        // and off by two after it.\n        if ((node as Element).hasAttributes()) {\n          // We defer removing bound attributes because on IE we might not be\n          // iterating attributes in their template order, and would sometimes\n          // remove an attribute that we still need to create a part for.\n          const attrsToRemove = [];\n          for (const name of (node as Element).getAttributeNames()) {\n            // `name` is the name of the attribute we're iterating over, but not\n            // _neccessarily_ the name of the attribute we will create a part\n            // for. They can be different in browsers that don't iterate on\n            // attributes in source order. In that case the attrNames array\n            // contains the attribute name we'll process next. We only need the\n            // attribute name here to know if we should process a bound attribute\n            // on this element.\n            if (\n              name.endsWith(boundAttributeSuffix) ||\n              name.startsWith(marker)\n            ) {\n              const realName = attrNames[attrNameIndex++];\n              attrsToRemove.push(name);\n              if (realName !== undefined) {\n                // Lowercase for case-sensitive SVG attributes like viewBox\n                const value = (node as Element).getAttribute(\n                  realName.toLowerCase() + boundAttributeSuffix\n                )!;\n                const statics = value.split(marker);\n                const m = /([.?@])?(.*)/.exec(realName)!;\n                parts.push({\n                  type: ATTRIBUTE_PART,\n                  index: nodeIndex,\n                  name: m[2],\n                  strings: statics,\n                  ctor:\n                    m[1] === '.'\n                      ? PropertyPart\n                      : m[1] === '?'\n                      ? BooleanAttributePart\n                      : m[1] === '@'\n                      ? EventPart\n                      : AttributePart,\n                });\n              } else {\n                parts.push({\n                  type: ELEMENT_PART,\n                  index: nodeIndex,\n                });\n              }\n            }\n          }\n          for (const name of attrsToRemove) {\n            (node as Element).removeAttribute(name);\n          }\n        }\n        // TODO (justinfagnani): benchmark the regex against testing for each\n        // of the 3 raw text element names.\n        if (rawTextElement.test((node as Element).tagName)) {\n          // For raw text elements we need to split the text content on\n          // markers, create a Text node for each segment, and create\n          // a TemplatePart for each marker.\n          const strings = (node as Element).textContent!.split(marker);\n          const lastIndex = strings.length - 1;\n          if (lastIndex > 0) {\n            (node as Element).textContent = trustedTypes\n              ? (trustedTypes.emptyScript as unknown as '')\n              : '';\n            // Generate a new text node for each literal section\n            // These nodes are also used as the markers for node parts\n            // We can't use empty text nodes as markers because they're\n            // normalized when cloning in IE (could simplify when\n            // IE is no longer supported)\n            for (let i = 0; i < lastIndex; i++) {\n              (node as Element).append(strings[i], createMarker());\n              // Walk past the marker node we just added\n              walker.nextNode();\n              parts.push({type: CHILD_PART, index: ++nodeIndex});\n            }\n            // Note because this marker is added after the walker's current\n            // node, it will be walked to in the outer loop (and ignored), so\n            // we don't need to adjust nodeIndex here\n            (node as Element).append(strings[lastIndex], createMarker());\n          }\n        }\n      } else if (node.nodeType === 8) {\n        const data = (node as Comment).data;\n        if (data === markerMatch) {\n          parts.push({type: CHILD_PART, index: nodeIndex});\n        } else {\n          let i = -1;\n          while ((i = (node as Comment).data.indexOf(marker, i + 1)) !== -1) {\n            // Comment node has a binding marker inside, make an inactive part\n            // The binding won't work, but subsequent bindings will\n            parts.push({type: COMMENT_PART, index: nodeIndex});\n            // Move to the end of the match\n            i += marker.length - 1;\n          }\n        }\n      }\n      nodeIndex++;\n    }\n    debugLogEvent?.({\n      kind: 'template prep',\n      template: this,\n      clonableTemplate: this.el,\n      parts: this.parts,\n      strings,\n    });\n  }\n\n  // Overridden via `litHtmlPolyfillSupport` to provide platform support.\n  /** @nocollapse */\n  static createElement(html: TrustedHTML, _options?: RenderOptions) {\n    const el = d.createElement('template');\n    el.innerHTML = html as unknown as string;\n    return el;\n  }\n}\n\nexport interface Disconnectable {\n  _$parent?: Disconnectable;\n  _$disconnectableChildren?: Set<Disconnectable>;\n  // Rather than hold connection state on instances, Disconnectables recursively\n  // fetch the connection state from the RootPart they are connected in via\n  // getters up the Disconnectable tree via _$parent references. This pushes the\n  // cost of tracking the isConnected state to `AsyncDirectives`, and avoids\n  // needing to pass all Disconnectables (parts, template instances, and\n  // directives) their connection state each time it changes, which would be\n  // costly for trees that have no AsyncDirectives.\n  _$isConnected: boolean;\n}\n\nfunction resolveDirective(\n  part: ChildPart | AttributePart | ElementPart,\n  value: unknown,\n  parent: DirectiveParent = part,\n  attributeIndex?: number\n): unknown {\n  // Bail early if the value is explicitly noChange. Note, this means any\n  // nested directive is still attached and is not run.\n  if (value === noChange) {\n    return value;\n  }\n  let currentDirective =\n    attributeIndex !== undefined\n      ? (parent as AttributePart).__directives?.[attributeIndex]\n      : (parent as ChildPart | ElementPart | Directive).__directive;\n  const nextDirectiveConstructor = isPrimitive(value)\n    ? undefined\n    : // This property needs to remain unminified.\n      (value as DirectiveResult)['_$litDirective$'];\n  if (currentDirective?.constructor !== nextDirectiveConstructor) {\n    // This property needs to remain unminified.\n    currentDirective?.['_$notifyDirectiveConnectionChanged']?.(false);\n    if (nextDirectiveConstructor === undefined) {\n      currentDirective = undefined;\n    } else {\n      currentDirective = new nextDirectiveConstructor(part as PartInfo);\n      currentDirective._$initialize(part, parent, attributeIndex);\n    }\n    if (attributeIndex !== undefined) {\n      ((parent as AttributePart).__directives ??= [])[attributeIndex] =\n        currentDirective;\n    } else {\n      (parent as ChildPart | Directive).__directive = currentDirective;\n    }\n  }\n  if (currentDirective !== undefined) {\n    value = resolveDirective(\n      part,\n      currentDirective._$resolve(part, (value as DirectiveResult).values),\n      currentDirective,\n      attributeIndex\n    );\n  }\n  return value;\n}\n\n/**\n * An updateable instance of a Template. Holds references to the Parts used to\n * update the template instance.\n */\nclass TemplateInstance implements Disconnectable {\n  /** @internal */\n  _$template: Template;\n  /** @internal */\n  _parts: Array<Part | undefined> = [];\n\n  /** @internal */\n  _$parent: ChildPart;\n  /** @internal */\n  _$disconnectableChildren?: Set<Disconnectable> = undefined;\n\n  constructor(template: Template, parent: ChildPart) {\n    this._$template = template;\n    this._$parent = parent;\n  }\n\n  // Called by ChildPart parentNode getter\n  get parentNode() {\n    return this._$parent.parentNode;\n  }\n\n  // See comment in Disconnectable interface for why this is a getter\n  get _$isConnected() {\n    return this._$parent._$isConnected;\n  }\n\n  // This method is separate from the constructor because we need to return a\n  // DocumentFragment and we don't want to hold onto it with an instance field.\n  _clone(options: RenderOptions | undefined) {\n    const {\n      el: {content},\n      parts: parts,\n    } = this._$template;\n    const fragment = (options?.creationScope ?? d).importNode(content, true);\n    walker.currentNode = fragment;\n\n    let node = walker.nextNode()!;\n    let nodeIndex = 0;\n    let partIndex = 0;\n    let templatePart = parts[0];\n\n    while (templatePart !== undefined) {\n      if (nodeIndex === templatePart.index) {\n        let part: Part | undefined;\n        if (templatePart.type === CHILD_PART) {\n          part = new ChildPart(\n            node as HTMLElement,\n            node.nextSibling,\n            this,\n            options\n          );\n        } else if (templatePart.type === ATTRIBUTE_PART) {\n          part = new templatePart.ctor(\n            node as HTMLElement,\n            templatePart.name,\n            templatePart.strings,\n            this,\n            options\n          );\n        } else if (templatePart.type === ELEMENT_PART) {\n          part = new ElementPart(node as HTMLElement, this, options);\n        }\n        this._parts.push(part);\n        templatePart = parts[++partIndex];\n      }\n      if (nodeIndex !== templatePart?.index) {\n        node = walker.nextNode()!;\n        nodeIndex++;\n      }\n    }\n    return fragment;\n  }\n\n  _update(values: Array<unknown>) {\n    let i = 0;\n    for (const part of this._parts) {\n      if (part !== undefined) {\n        debugLogEvent?.({\n          kind: 'set part',\n          part,\n          value: values[i],\n          valueIndex: i,\n          values,\n          templateInstance: this,\n        });\n        if ((part as AttributePart).strings !== undefined) {\n          (part as AttributePart)._$setValue(values, part as AttributePart, i);\n          // The number of values the part consumes is part.strings.length - 1\n          // since values are in between template spans. We increment i by 1\n          // later in the loop, so increment it by part.strings.length - 2 here\n          i += (part as AttributePart).strings!.length - 2;\n        } else {\n          part._$setValue(values[i]);\n        }\n      }\n      i++;\n    }\n  }\n}\n\n/*\n * Parts\n */\ntype AttributeTemplatePart = {\n  readonly type: typeof ATTRIBUTE_PART;\n  readonly index: number;\n  readonly name: string;\n  /** @internal */\n  readonly ctor: typeof AttributePart;\n  /** @internal */\n  readonly strings: ReadonlyArray<string>;\n};\ntype NodeTemplatePart = {\n  readonly type: typeof CHILD_PART;\n  readonly index: number;\n};\ntype ElementTemplatePart = {\n  readonly type: typeof ELEMENT_PART;\n  readonly index: number;\n};\ntype CommentTemplatePart = {\n  readonly type: typeof COMMENT_PART;\n  readonly index: number;\n};\n\n/**\n * A TemplatePart represents a dynamic part in a template, before the template\n * is instantiated. When a template is instantiated Parts are created from\n * TemplateParts.\n */\ntype TemplatePart =\n  | NodeTemplatePart\n  | AttributeTemplatePart\n  | ElementTemplatePart\n  | CommentTemplatePart;\n\nexport type Part =\n  | ChildPart\n  | AttributePart\n  | PropertyPart\n  | BooleanAttributePart\n  | ElementPart\n  | EventPart;\n\nexport type {ChildPart};\nclass ChildPart implements Disconnectable {\n  readonly type = CHILD_PART;\n  readonly options: RenderOptions | undefined;\n  _$committedValue: unknown = nothing;\n  /** @internal */\n  __directive?: Directive;\n  /** @internal */\n  _$startNode: ChildNode;\n  /** @internal */\n  _$endNode: ChildNode | null;\n  private _textSanitizer: ValueSanitizer | undefined;\n  /** @internal */\n  _$parent: Disconnectable | undefined;\n  /**\n   * Connection state for RootParts only (i.e. ChildPart without _$parent\n   * returned from top-level `render`). This field is unsed otherwise. The\n   * intention would clearer if we made `RootPart` a subclass of `ChildPart`\n   * with this field (and a different _$isConnected getter), but the subclass\n   * caused a perf regression, possibly due to making call sites polymorphic.\n   * @internal\n   */\n  __isConnected: boolean;\n\n  // See comment in Disconnectable interface for why this is a getter\n  get _$isConnected() {\n    // ChildParts that are not at the root should always be created with a\n    // parent; only RootChildNode's won't, so they return the local isConnected\n    // state\n    return this._$parent?._$isConnected ?? this.__isConnected;\n  }\n\n  // The following fields will be patched onto ChildParts when required by\n  // AsyncDirective\n  /** @internal */\n  _$disconnectableChildren?: Set<Disconnectable> = undefined;\n  /** @internal */\n  _$notifyConnectionChanged?(\n    isConnected: boolean,\n    removeFromParent?: boolean,\n    from?: number\n  ): void;\n  /** @internal */\n  _$reparentDisconnectables?(parent: Disconnectable): void;\n\n  constructor(\n    startNode: ChildNode,\n    endNode: ChildNode | null,\n    parent: TemplateInstance | ChildPart | undefined,\n    options: RenderOptions | undefined\n  ) {\n    this._$startNode = startNode;\n    this._$endNode = endNode;\n    this._$parent = parent;\n    this.options = options;\n    // Note __isConnected is only ever accessed on RootParts (i.e. when there is\n    // no _$parent); the value on a non-root-part is \"don't care\", but checking\n    // for parent would be more code\n    this.__isConnected = options?.isConnected ?? true;\n    if (ENABLE_EXTRA_SECURITY_HOOKS) {\n      // Explicitly initialize for consistent class shape.\n      this._textSanitizer = undefined;\n    }\n  }\n\n  /**\n   * The parent node into which the part renders its content.\n   *\n   * A ChildPart's content consists of a range of adjacent child nodes of\n   * `.parentNode`, possibly bordered by 'marker nodes' (`.startNode` and\n   * `.endNode`).\n   *\n   * - If both `.startNode` and `.endNode` are non-null, then the part's content\n   * consists of all siblings between `.startNode` and `.endNode`, exclusively.\n   *\n   * - If `.startNode` is non-null but `.endNode` is null, then the part's\n   * content consists of all siblings following `.startNode`, up to and\n   * including the last child of `.parentNode`. If `.endNode` is non-null, then\n   * `.startNode` will always be non-null.\n   *\n   * - If both `.endNode` and `.startNode` are null, then the part's content\n   * consists of all child nodes of `.parentNode`.\n   */\n  get parentNode(): Node {\n    let parentNode: Node = wrap(this._$startNode).parentNode!;\n    const parent = this._$parent;\n    if (\n      parent !== undefined &&\n      parentNode.nodeType === 11 /* Node.DOCUMENT_FRAGMENT */\n    ) {\n      // If the parentNode is a DocumentFragment, it may be because the DOM is\n      // still in the cloned fragment during initial render; if so, get the real\n      // parentNode the part will be committed into by asking the parent.\n      parentNode = (parent as ChildPart | TemplateInstance).parentNode;\n    }\n    return parentNode;\n  }\n\n  /**\n   * The part's leading marker node, if any. See `.parentNode` for more\n   * information.\n   */\n  get startNode(): Node | null {\n    return this._$startNode;\n  }\n\n  /**\n   * The part's trailing marker node, if any. See `.parentNode` for more\n   * information.\n   */\n  get endNode(): Node | null {\n    return this._$endNode;\n  }\n\n  _$setValue(value: unknown, directiveParent: DirectiveParent = this): void {\n    if (DEV_MODE && this.parentNode === null) {\n      throw new Error(\n        `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.`\n      );\n    }\n    value = resolveDirective(this, value, directiveParent);\n    if (isPrimitive(value)) {\n      // Non-rendering child values. It's important that these do not render\n      // empty text nodes to avoid issues with preventing default <slot>\n      // fallback content.\n      if (value === nothing || value == null || value === '') {\n        if (this._$committedValue !== nothing) {\n          debugLogEvent?.({\n            kind: 'commit nothing to child',\n            start: this._$startNode,\n            end: this._$endNode,\n            parent: this._$parent,\n            options: this.options,\n          });\n          this._$clear();\n        }\n        this._$committedValue = nothing;\n      } else if (value !== this._$committedValue && value !== noChange) {\n        this._commitText(value);\n      }\n      // This property needs to remain unminified.\n    } else if ((value as TemplateResult)['_$litType$'] !== undefined) {\n      this._commitTemplateResult(value as TemplateResult);\n    } else if ((value as Node).nodeType !== undefined) {\n      this._commitNode(value as Node);\n    } else if (isIterable(value)) {\n      this._commitIterable(value);\n    } else {\n      // Fallback, will render the string representation\n      this._commitText(value);\n    }\n  }\n\n  private _insert<T extends Node>(node: T, ref = this._$endNode) {\n    return wrap(wrap(this._$startNode).parentNode!).insertBefore(node, ref);\n  }\n\n  private _commitNode(value: Node): void {\n    if (this._$committedValue !== value) {\n      this._$clear();\n      if (\n        ENABLE_EXTRA_SECURITY_HOOKS &&\n        sanitizerFactoryInternal !== noopSanitizer\n      ) {\n        const parentNodeName = this._$startNode.parentNode?.nodeName;\n        if (parentNodeName === 'STYLE' || parentNodeName === 'SCRIPT') {\n          let message = 'Forbidden';\n          if (DEV_MODE) {\n            if (parentNodeName === 'STYLE') {\n              message =\n                `Lit does not support binding inside style nodes. ` +\n                `This is a security risk, as style injection attacks can ` +\n                `exfiltrate data and spoof UIs. ` +\n                `Consider instead using css\\`...\\` literals ` +\n                `to compose styles, and make do dynamic styling with ` +\n                `css custom properties, ::parts, <slot>s, ` +\n                `and by mutating the DOM rather than stylesheets.`;\n            } else {\n              message =\n                `Lit does not support binding inside script nodes. ` +\n                `This is a security risk, as it could allow arbitrary ` +\n                `code execution.`;\n            }\n          }\n          throw new Error(message);\n        }\n      }\n      debugLogEvent?.({\n        kind: 'commit node',\n        start: this._$startNode,\n        parent: this._$parent,\n        value: value,\n        options: this.options,\n      });\n      this._$committedValue = this._insert(value);\n    }\n  }\n\n  private _commitText(value: unknown): void {\n    // If the committed value is a primitive it means we called _commitText on\n    // the previous render, and we know that this._$startNode.nextSibling is a\n    // Text node. We can now just replace the text content (.data) of the node.\n    if (\n      this._$committedValue !== nothing &&\n      isPrimitive(this._$committedValue)\n    ) {\n      const node = wrap(this._$startNode).nextSibling as Text;\n      if (ENABLE_EXTRA_SECURITY_HOOKS) {\n        if (this._textSanitizer === undefined) {\n          this._textSanitizer = createSanitizer(node, 'data', 'property');\n        }\n        value = this._textSanitizer(value);\n      }\n      debugLogEvent?.({\n        kind: 'commit text',\n        node,\n        value,\n        options: this.options,\n      });\n      (node as Text).data = value as string;\n    } else {\n      if (ENABLE_EXTRA_SECURITY_HOOKS) {\n        const textNode = document.createTextNode('');\n        this._commitNode(textNode);\n        // When setting text content, for security purposes it matters a lot\n        // what the parent is. For example, <style> and <script> need to be\n        // handled with care, while <span> does not. So first we need to put a\n        // text node into the document, then we can sanitize its content.\n        if (this._textSanitizer === undefined) {\n          this._textSanitizer = createSanitizer(textNode, 'data', 'property');\n        }\n        value = this._textSanitizer(value);\n        debugLogEvent?.({\n          kind: 'commit text',\n          node: textNode,\n          value,\n          options: this.options,\n        });\n        textNode.data = value as string;\n      } else {\n        this._commitNode(d.createTextNode(value as string));\n        debugLogEvent?.({\n          kind: 'commit text',\n          node: wrap(this._$startNode).nextSibling as Text,\n          value,\n          options: this.options,\n        });\n      }\n    }\n    this._$committedValue = value;\n  }\n\n  private _commitTemplateResult(\n    result: TemplateResult | CompiledTemplateResult\n  ): void {\n    // This property needs to remain unminified.\n    const {values, ['_$litType$']: type} = result;\n    // If $litType$ is a number, result is a plain TemplateResult and we get\n    // the template from the template cache. If not, result is a\n    // CompiledTemplateResult and _$litType$ is a CompiledTemplate and we need\n    // to create the <template> element the first time we see it.\n    const template: Template | CompiledTemplate =\n      typeof type === 'number'\n        ? this._$getTemplate(result as TemplateResult)\n        : (type.el === undefined &&\n            (type.el = Template.createElement(type.h, this.options)),\n          type);\n\n    if ((this._$committedValue as TemplateInstance)?._$template === template) {\n      debugLogEvent?.({\n        kind: 'template updating',\n        template,\n        instance: this._$committedValue as TemplateInstance,\n        parts: (this._$committedValue as TemplateInstance)._parts,\n        options: this.options,\n        values,\n      });\n      (this._$committedValue as TemplateInstance)._update(values);\n    } else {\n      const instance = new TemplateInstance(template as Template, this);\n      const fragment = instance._clone(this.options);\n      debugLogEvent?.({\n        kind: 'template instantiated',\n        template,\n        instance,\n        parts: instance._parts,\n        options: this.options,\n        fragment,\n        values,\n      });\n      instance._update(values);\n      debugLogEvent?.({\n        kind: 'template instantiated and updated',\n        template,\n        instance,\n        parts: instance._parts,\n        options: this.options,\n        fragment,\n        values,\n      });\n      this._commitNode(fragment);\n      this._$committedValue = instance;\n    }\n  }\n\n  // Overridden via `litHtmlPolyfillSupport` to provide platform support.\n  /** @internal */\n  _$getTemplate(result: TemplateResult) {\n    let template = templateCache.get(result.strings);\n    if (template === undefined) {\n      templateCache.set(result.strings, (template = new Template(result)));\n    }\n    return template;\n  }\n\n  private _commitIterable(value: Iterable<unknown>): void {\n    // For an Iterable, we create a new InstancePart per item, then set its\n    // value to the item. This is a little bit of overhead for every item in\n    // an Iterable, but it lets us recurse easily and efficiently update Arrays\n    // of TemplateResults that will be commonly returned from expressions like:\n    // array.map((i) => html`${i}`), by reusing existing TemplateInstances.\n\n    // If value is an array, then the previous render was of an\n    // iterable and value will contain the ChildParts from the previous\n    // render. If value is not an array, clear this part and make a new\n    // array for ChildParts.\n    if (!isArray(this._$committedValue)) {\n      this._$committedValue = [];\n      this._$clear();\n    }\n\n    // Lets us keep track of how many items we stamped so we can clear leftover\n    // items from a previous render\n    const itemParts = this._$committedValue as ChildPart[];\n    let partIndex = 0;\n    let itemPart: ChildPart | undefined;\n\n    for (const item of value) {\n      if (partIndex === itemParts.length) {\n        // If no existing part, create a new one\n        // TODO (justinfagnani): test perf impact of always creating two parts\n        // instead of sharing parts between nodes\n        // https://github.com/lit/lit/issues/1266\n        itemParts.push(\n          (itemPart = new ChildPart(\n            this._insert(createMarker()),\n            this._insert(createMarker()),\n            this,\n            this.options\n          ))\n        );\n      } else {\n        // Reuse an existing part\n        itemPart = itemParts[partIndex];\n      }\n      itemPart._$setValue(item);\n      partIndex++;\n    }\n\n    if (partIndex < itemParts.length) {\n      // itemParts always have end nodes\n      this._$clear(\n        itemPart && wrap(itemPart._$endNode!).nextSibling,\n        partIndex\n      );\n      // Truncate the parts array so _value reflects the current state\n      itemParts.length = partIndex;\n    }\n  }\n\n  /**\n   * Removes the nodes contained within this Part from the DOM.\n   *\n   * @param start Start node to clear from, for clearing a subset of the part's\n   *     DOM (used when truncating iterables)\n   * @param from  When `start` is specified, the index within the iterable from\n   *     which ChildParts are being removed, used for disconnecting directives in\n   *     those Parts.\n   *\n   * @internal\n   */\n  _$clear(\n    start: ChildNode | null = wrap(this._$startNode).nextSibling,\n    from?: number\n  ) {\n    this._$notifyConnectionChanged?.(false, true, from);\n    while (start && start !== this._$endNode) {\n      const n = wrap(start!).nextSibling;\n      (wrap(start!) as Element).remove();\n      start = n;\n    }\n  }\n  /**\n   * Implementation of RootPart's `isConnected`. Note that this metod\n   * should only be called on `RootPart`s (the `ChildPart` returned from a\n   * top-level `render()` call). It has no effect on non-root ChildParts.\n   * @param isConnected Whether to set\n   * @internal\n   */\n  setConnected(isConnected: boolean) {\n    if (this._$parent === undefined) {\n      this.__isConnected = isConnected;\n      this._$notifyConnectionChanged?.(isConnected);\n    } else if (DEV_MODE) {\n      throw new Error(\n        'part.setConnected() may only be called on a ' +\n          'RootPart returned from render().'\n      );\n    }\n  }\n}\n\n/**\n * A top-level `ChildPart` returned from `render` that manages the connected\n * state of `AsyncDirective`s created throughout the tree below it.\n */\nexport interface RootPart extends ChildPart {\n  /**\n   * Sets the connection state for `AsyncDirective`s contained within this root\n   * ChildPart.\n   *\n   * lit-html does not automatically monitor the connectedness of DOM rendered;\n   * as such, it is the responsibility of the caller to `render` to ensure that\n   * `part.setConnected(false)` is called before the part object is potentially\n   * discarded, to ensure that `AsyncDirective`s have a chance to dispose of\n   * any resources being held. If a `RootPart` that was prevously\n   * disconnected is subsequently re-connected (and its `AsyncDirective`s should\n   * re-connect), `setConnected(true)` should be called.\n   *\n   * @param isConnected Whether directives within this tree should be connected\n   * or not\n   */\n  setConnected(isConnected: boolean): void;\n}\n\nexport type {AttributePart};\nclass AttributePart implements Disconnectable {\n  readonly type = ATTRIBUTE_PART as\n    | typeof ATTRIBUTE_PART\n    | typeof PROPERTY_PART\n    | typeof BOOLEAN_ATTRIBUTE_PART\n    | typeof EVENT_PART;\n  readonly element: HTMLElement;\n  readonly name: string;\n  readonly options: RenderOptions | undefined;\n\n  /**\n   * If this attribute part represents an interpolation, this contains the\n   * static strings of the interpolation. For single-value, complete bindings,\n   * this is undefined.\n   */\n  readonly strings?: ReadonlyArray<string>;\n  /** @internal */\n  _$committedValue: unknown | Array<unknown> = nothing;\n  /** @internal */\n  __directives?: Array<Directive | undefined>;\n  /** @internal */\n  _$parent: Disconnectable;\n  /** @internal */\n  _$disconnectableChildren?: Set<Disconnectable> = undefined;\n\n  protected _sanitizer: ValueSanitizer | undefined;\n\n  get tagName() {\n    return this.element.tagName;\n  }\n\n  // See comment in Disconnectable interface for why this is a getter\n  get _$isConnected() {\n    return this._$parent._$isConnected;\n  }\n\n  constructor(\n    element: HTMLElement,\n    name: string,\n    strings: ReadonlyArray<string>,\n    parent: Disconnectable,\n    options: RenderOptions | undefined\n  ) {\n    this.element = element;\n    this.name = name;\n    this._$parent = parent;\n    this.options = options;\n    if (strings.length > 2 || strings[0] !== '' || strings[1] !== '') {\n      this._$committedValue = new Array(strings.length - 1).fill(new String());\n      this.strings = strings;\n    } else {\n      this._$committedValue = nothing;\n    }\n    if (ENABLE_EXTRA_SECURITY_HOOKS) {\n      this._sanitizer = undefined;\n    }\n  }\n\n  /**\n   * Sets the value of this part by resolving the value from possibly multiple\n   * values and static strings and committing it to the DOM.\n   * If this part is single-valued, `this._strings` will be undefined, and the\n   * method will be called with a single value argument. If this part is\n   * multi-value, `this._strings` will be defined, and the method is called\n   * with the value array of the part's owning TemplateInstance, and an offset\n   * into the value array from which the values should be read.\n   * This method is overloaded this way to eliminate short-lived array slices\n   * of the template instance values, and allow a fast-path for single-valued\n   * parts.\n   *\n   * @param value The part value, or an array of values for multi-valued parts\n   * @param valueIndex the index to start reading values from. `undefined` for\n   *   single-valued parts\n   * @param noCommit causes the part to not commit its value to the DOM. Used\n   *   in hydration to prime attribute parts with their first-rendered value,\n   *   but not set the attribute, and in SSR to no-op the DOM operation and\n   *   capture the value for serialization.\n   *\n   * @internal\n   */\n  _$setValue(\n    value: unknown | Array<unknown>,\n    directiveParent: DirectiveParent = this,\n    valueIndex?: number,\n    noCommit?: boolean\n  ) {\n    const strings = this.strings;\n\n    // Whether any of the values has changed, for dirty-checking\n    let change = false;\n\n    if (strings === undefined) {\n      // Single-value binding case\n      value = resolveDirective(this, value, directiveParent, 0);\n      change =\n        !isPrimitive(value) ||\n        (value !== this._$committedValue && value !== noChange);\n      if (change) {\n        this._$committedValue = value;\n      }\n    } else {\n      // Interpolation case\n      const values = value as Array<unknown>;\n      value = strings[0];\n\n      let i, v;\n      for (i = 0; i < strings.length - 1; i++) {\n        v = resolveDirective(this, values[valueIndex! + i], directiveParent, i);\n\n        if (v === noChange) {\n          // If the user-provided value is `noChange`, use the previous value\n          v = (this._$committedValue as Array<unknown>)[i];\n        }\n        change ||=\n          !isPrimitive(v) || v !== (this._$committedValue as Array<unknown>)[i];\n        if (v === nothing) {\n          value = nothing;\n        } else if (value !== nothing) {\n          value += (v ?? '') + strings[i + 1];\n        }\n        // We always record each value, even if one is `nothing`, for future\n        // change detection.\n        (this._$committedValue as Array<unknown>)[i] = v;\n      }\n    }\n    if (change && !noCommit) {\n      this._commitValue(value);\n    }\n  }\n\n  /** @internal */\n  _commitValue(value: unknown) {\n    if (value === nothing) {\n      (wrap(this.element) as Element).removeAttribute(this.name);\n    } else {\n      if (ENABLE_EXTRA_SECURITY_HOOKS) {\n        if (this._sanitizer === undefined) {\n          this._sanitizer = sanitizerFactoryInternal(\n            this.element,\n            this.name,\n            'attribute'\n          );\n        }\n        value = this._sanitizer(value ?? '');\n      }\n      debugLogEvent?.({\n        kind: 'commit attribute',\n        element: this.element,\n        name: this.name,\n        value,\n        options: this.options,\n      });\n      (wrap(this.element) as Element).setAttribute(\n        this.name,\n        (value ?? '') as string\n      );\n    }\n  }\n}\n\nexport type {PropertyPart};\nclass PropertyPart extends AttributePart {\n  override readonly type = PROPERTY_PART;\n\n  /** @internal */\n  override _commitValue(value: unknown) {\n    if (ENABLE_EXTRA_SECURITY_HOOKS) {\n      if (this._sanitizer === undefined) {\n        this._sanitizer = sanitizerFactoryInternal(\n          this.element,\n          this.name,\n          'property'\n        );\n      }\n      value = this._sanitizer(value);\n    }\n    debugLogEvent?.({\n      kind: 'commit property',\n      element: this.element,\n      name: this.name,\n      value,\n      options: this.options,\n    });\n    // eslint-disable-next-line @typescript-eslint/no-explicit-any\n    (this.element as any)[this.name] = value === nothing ? undefined : value;\n  }\n}\n\n// Temporary workaround for https://crbug.com/993268\n// Currently, any attribute starting with \"on\" is considered to be a\n// TrustedScript source. Such boolean attributes must be set to the equivalent\n// trusted emptyScript value.\nconst emptyStringForBooleanAttribute = trustedTypes\n  ? (trustedTypes.emptyScript as unknown as '')\n  : '';\n\nexport type {BooleanAttributePart};\nclass BooleanAttributePart extends AttributePart {\n  override readonly type = BOOLEAN_ATTRIBUTE_PART;\n\n  /** @internal */\n  override _commitValue(value: unknown) {\n    debugLogEvent?.({\n      kind: 'commit boolean attribute',\n      element: this.element,\n      name: this.name,\n      value: !!(value && value !== nothing),\n      options: this.options,\n    });\n    if (value && value !== nothing) {\n      (wrap(this.element) as Element).setAttribute(\n        this.name,\n        emptyStringForBooleanAttribute\n      );\n    } else {\n      (wrap(this.element) as Element).removeAttribute(this.name);\n    }\n  }\n}\n\ntype EventListenerWithOptions = EventListenerOrEventListenerObject &\n  Partial<AddEventListenerOptions>;\n\n/**\n * An AttributePart that manages an event listener via add/removeEventListener.\n *\n * This part works by adding itself as the event listener on an element, then\n * delegating to the value passed to it. This reduces the number of calls to\n * add/removeEventListener if the listener changes frequently, such as when an\n * inline function is used as a listener.\n *\n * Because event options are passed when adding listeners, we must take case\n * to add and remove the part as a listener when the event options change.\n */\nexport type {EventPart};\nclass EventPart extends AttributePart {\n  override readonly type = EVENT_PART;\n\n  constructor(\n    element: HTMLElement,\n    name: string,\n    strings: ReadonlyArray<string>,\n    parent: Disconnectable,\n    options: RenderOptions | undefined\n  ) {\n    super(element, name, strings, parent, options);\n\n    if (DEV_MODE && this.strings !== undefined) {\n      throw new Error(\n        `A \\`<${element.localName}>\\` has a \\`@${name}=...\\` listener with ` +\n          'invalid content. Event listeners in templates must have exactly ' +\n          'one expression and no surrounding text.'\n      );\n    }\n  }\n\n  // EventPart does not use the base _$setValue/_resolveValue implementation\n  // since the dirty checking is more complex\n  /** @internal */\n  override _$setValue(\n    newListener: unknown,\n    directiveParent: DirectiveParent = this\n  ) {\n    newListener =\n      resolveDirective(this, newListener, directiveParent, 0) ?? nothing;\n    if (newListener === noChange) {\n      return;\n    }\n    const oldListener = this._$committedValue;\n\n    // If the new value is nothing or any options change we have to remove the\n    // part as a listener.\n    const shouldRemoveListener =\n      (newListener === nothing && oldListener !== nothing) ||\n      (newListener as EventListenerWithOptions).capture !==\n        (oldListener as EventListenerWithOptions).capture ||\n      (newListener as EventListenerWithOptions).once !==\n        (oldListener as EventListenerWithOptions).once ||\n      (newListener as EventListenerWithOptions).passive !==\n        (oldListener as EventListenerWithOptions).passive;\n\n    // If the new value is not nothing and we removed the listener, we have\n    // to add the part as a listener.\n    const shouldAddListener =\n      newListener !== nothing &&\n      (oldListener === nothing || shouldRemoveListener);\n\n    debugLogEvent?.({\n      kind: 'commit event listener',\n      element: this.element,\n      name: this.name,\n      value: newListener,\n      options: this.options,\n      removeListener: shouldRemoveListener,\n      addListener: shouldAddListener,\n      oldListener,\n    });\n    if (shouldRemoveListener) {\n      this.element.removeEventListener(\n        this.name,\n        this,\n        oldListener as EventListenerWithOptions\n      );\n    }\n    if (shouldAddListener) {\n      // Beware: IE11 and Chrome 41 don't like using the listener as the\n      // options object. Figure out how to deal w/ this in IE11 - maybe\n      // patch addEventListener?\n      this.element.addEventListener(\n        this.name,\n        this,\n        newListener as EventListenerWithOptions\n      );\n    }\n    this._$committedValue = newListener;\n  }\n\n  handleEvent(event: Event) {\n    if (typeof this._$committedValue === 'function') {\n      this._$committedValue.call(this.options?.host ?? this.element, event);\n    } else {\n      (this._$committedValue as EventListenerObject).handleEvent(event);\n    }\n  }\n}\n\nexport type {ElementPart};\nclass ElementPart implements Disconnectable {\n  readonly type = ELEMENT_PART;\n\n  /** @internal */\n  __directive?: Directive;\n\n  // This is to ensure that every Part has a _$committedValue\n  _$committedValue: undefined;\n\n  /** @internal */\n  _$parent!: Disconnectable;\n\n  /** @internal */\n  _$disconnectableChildren?: Set<Disconnectable> = undefined;\n\n  options: RenderOptions | undefined;\n\n  constructor(\n    public element: Element,\n    parent: Disconnectable,\n    options: RenderOptions | undefined\n  ) {\n    this._$parent = parent;\n    this.options = options;\n  }\n\n  // See comment in Disconnectable interface for why this is a getter\n  get _$isConnected() {\n    return this._$parent._$isConnected;\n  }\n\n  _$setValue(value: unknown): void {\n    debugLogEvent?.({\n      kind: 'commit to element binding',\n      element: this.element,\n      value,\n      options: this.options,\n    });\n    resolveDirective(this, value);\n  }\n}\n\n/**\n * END USERS SHOULD NOT RELY ON THIS OBJECT.\n *\n * Private exports for use by other Lit packages, not intended for use by\n * external users.\n *\n * We currently do not make a mangled rollup build of the lit-ssr code. In order\n * to keep a number of (otherwise private) top-level exports  mangled in the\n * client side code, we export a _$LH object containing those members (or\n * helper methods for accessing private fields of those members), and then\n * re-export them for use in lit-ssr. This keeps lit-ssr agnostic to whether the\n * client-side code is being used in `dev` mode or `prod` mode.\n *\n * This has a unique name, to disambiguate it from private exports in\n * lit-element, which re-exports all of lit-html.\n *\n * @private\n */\nexport const _$LH = {\n  // Used in lit-ssr\n  _boundAttributeSuffix: boundAttributeSuffix,\n  _marker: marker,\n  _markerMatch: markerMatch,\n  _HTML_RESULT: HTML_RESULT,\n  _getTemplateHtml: getTemplateHtml,\n  // Used in hydrate\n  _TemplateInstance: TemplateInstance,\n  _isIterable: isIterable,\n  _resolveDirective: resolveDirective,\n  // Used in tests and private-ssr-support\n  _ChildPart: ChildPart,\n  _AttributePart: AttributePart,\n  _BooleanAttributePart: BooleanAttributePart,\n  _EventPart: EventPart,\n  _PropertyPart: PropertyPart,\n  _ElementPart: ElementPart,\n};\n\n// Apply polyfills if available\nconst polyfillSupport = DEV_MODE\n  ? window.litHtmlPolyfillSupportDevMode\n  : window.litHtmlPolyfillSupport;\npolyfillSupport?.(Template, ChildPart);\n\n// IMPORTANT: do not change the property name or the assignment expression.\n// This line will be used in regexes to search for lit-html usage.\n(globalThis.litHtmlVersions ??= []).push('2.2.1');\nif (DEV_MODE && globalThis.litHtmlVersions.length > 1) {\n  issueWarning!(\n    'multiple-versions',\n    `Multiple versions of Lit loaded. ` +\n      `Loading multiple versions is not recommended.`\n  );\n}\n"]}
\ No newline at end of file
+{"version":3,"file":"lit-html.js","sourceRoot":"","sources":["../src/lit-html.ts"],"names":[],"mappings":"AAAA;;;;GAIG;;AAKH,MAAM,QAAQ,GAAG,IAAI,CAAC;AACtB,MAAM,2BAA2B,GAAG,IAAI,CAAC;AACzC,MAAM,uBAAuB,GAAG,IAAI,CAAC;AACrC,MAAM,SAAS,GAAG,KAAK,CAAC;AACxB,sEAAsE;AACtE,MAAM,MAAM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E,EAAE,OAAO,CAAC,EAC/C,OAAO,EACP,SAAS,EACT,OAAO,aAAP,OAAO,cAAP,OAAO,GAAI,EAAE,CACd,CAAC;KACH;IACD,IAAI,CAAC,UAAU,CAAC,KAAK,CAAC,CAAC;IACvB,aAAa,aAAb,aAAa,uBAAb,aAAa,CAAG;QACd,IAAI,EAAE,YAAY;QAClB,EAAE,EAAE,QAAQ;QACZ,KAAK;QACL,SAAS;QACT,OAAO;QACP,IAAI;KACL,CAAC,CAAC;IACH,OAAO,IAAgB,CAAC;AAC1B,CAAC,CAAC;AAEF,IAAI,2BAA2B,EAAE;IAC/B,MAAM,CAAC,YAAY,GAAG,YAAY,CAAC;IACnC,MAAM,CAAC,eAAe,GAAG,eAAe,CAAC;IACzC,IAAI,QAAQ,EAAE;QACZ,MAAM,CAAC,6CAA6C;YAClD,6CAA6C,CAAC;KACjD;CACF","sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n// IMPORTANT: these imports must be type-only\nimport type {Directive, DirectiveResult, PartInfo} from './directive.js';\n\nconst DEV_MODE = true;\nconst ENABLE_EXTRA_SECURITY_HOOKS = true;\nconst ENABLE_SHADYDOM_NOPATCH = true;\nconst NODE_MODE = false;\n// Use window for browser builds because IE11 doesn't have globalThis.\nconst global = NODE_MODE ? globalThis : window;\n\n/**\n * Contains types that are part of the unstable debug API.\n *\n * Everything in this API is not stable and may change or be removed in the future,\n * even on patch releases.\n */\n// eslint-disable-next-line @typescript-eslint/no-namespace\nexport namespace LitUnstable {\n  /**\n   * When Lit is running in dev mode and `window.emitLitDebugLogEvents` is true,\n   * we will emit 'lit-debug' events to window, with live details about the update and render\n   * lifecycle. These can be useful for writing debug tooling and visualizations.\n   *\n   * Please be aware that running with window.emitLitDebugLogEvents has performance overhead,\n   * making certain operations that are normally very cheap (like a no-op render) much slower,\n   * because we must copy data and dispatch events.\n   */\n  // eslint-disable-next-line @typescript-eslint/no-namespace\n  export namespace DebugLog {\n    export type Entry =\n      | TemplatePrep\n      | TemplateInstantiated\n      | TemplateInstantiatedAndUpdated\n      | TemplateUpdating\n      | BeginRender\n      | EndRender\n      | CommitPartEntry\n      | SetPartValue;\n    export interface TemplatePrep {\n      kind: 'template prep';\n      template: Template;\n      strings: TemplateStringsArray;\n      clonableTemplate: HTMLTemplateElement;\n      parts: TemplatePart[];\n    }\n    export interface BeginRender {\n      kind: 'begin render';\n      id: number;\n      value: unknown;\n      container: HTMLElement | DocumentFragment;\n      options: RenderOptions | undefined;\n      part: ChildPart | undefined;\n    }\n    export interface EndRender {\n      kind: 'end render';\n      id: number;\n      value: unknown;\n      container: HTMLElement | DocumentFragment;\n      options: RenderOptions | undefined;\n      part: ChildPart;\n    }\n    export interface TemplateInstantiated {\n      kind: 'template instantiated';\n      template: Template | CompiledTemplate;\n      instance: TemplateInstance;\n      options: RenderOptions | undefined;\n      fragment: Node;\n      parts: Array<Part | undefined>;\n      values: unknown[];\n    }\n    export interface TemplateInstantiatedAndUpdated {\n      kind: 'template instantiated and updated';\n      template: Template | CompiledTemplate;\n      instance: TemplateInstance;\n      options: RenderOptions | undefined;\n      fragment: Node;\n      parts: Array<Part | undefined>;\n      values: unknown[];\n    }\n    export interface TemplateUpdating {\n      kind: 'template updating';\n      template: Template | CompiledTemplate;\n      instance: TemplateInstance;\n      options: RenderOptions | undefined;\n      parts: Array<Part | undefined>;\n      values: unknown[];\n    }\n    export interface SetPartValue {\n      kind: 'set part';\n      part: Part;\n      value: unknown;\n      valueIndex: number;\n      values: unknown[];\n      templateInstance: TemplateInstance;\n    }\n\n    export type CommitPartEntry =\n      | CommitNothingToChildEntry\n      | CommitText\n      | CommitNode\n      | CommitAttribute\n      | CommitProperty\n      | CommitBooleanAttribute\n      | CommitEventListener\n      | CommitToElementBinding;\n\n    export interface CommitNothingToChildEntry {\n      kind: 'commit nothing to child';\n      start: ChildNode;\n      end: ChildNode | null;\n      parent: Disconnectable | undefined;\n      options: RenderOptions | undefined;\n    }\n\n    export interface CommitText {\n      kind: 'commit text';\n      node: Text;\n      value: unknown;\n      options: RenderOptions | undefined;\n    }\n\n    export interface CommitNode {\n      kind: 'commit node';\n      start: Node;\n      parent: Disconnectable | undefined;\n      value: Node;\n      options: RenderOptions | undefined;\n    }\n\n    export interface CommitAttribute {\n      kind: 'commit attribute';\n      element: Element;\n      name: string;\n      value: unknown;\n      options: RenderOptions | undefined;\n    }\n\n    export interface CommitProperty {\n      kind: 'commit property';\n      element: Element;\n      name: string;\n      value: unknown;\n      options: RenderOptions | undefined;\n    }\n\n    export interface CommitBooleanAttribute {\n      kind: 'commit boolean attribute';\n      element: Element;\n      name: string;\n      value: boolean;\n      options: RenderOptions | undefined;\n    }\n\n    export interface CommitEventListener {\n      kind: 'commit event listener';\n      element: Element;\n      name: string;\n      value: unknown;\n      oldListener: unknown;\n      options: RenderOptions | undefined;\n      // True if we're removing the old event listener (e.g. because settings changed, or value is nothing)\n      removeListener: boolean;\n      // True if we're adding a new event listener (e.g. because first render, or settings changed)\n      addListener: boolean;\n    }\n\n    export interface CommitToElementBinding {\n      kind: 'commit to element binding';\n      element: Element;\n      value: unknown;\n      options: RenderOptions | undefined;\n    }\n  }\n}\n\ninterface DebugLoggingWindow {\n  // Even in dev mode, we generally don't want to emit these events, as that's\n  // another level of cost, so only emit them when DEV_MODE is true _and_ when\n  // window.emitLitDebugEvents is true.\n  emitLitDebugLogEvents?: boolean;\n}\n\n/**\n * Useful for visualizing and logging insights into what the Lit template system is doing.\n *\n * Compiled out of prod mode builds.\n */\nconst debugLogEvent = DEV_MODE\n  ? (event: LitUnstable.DebugLog.Entry) => {\n      const shouldEmit = (global as unknown as DebugLoggingWindow)\n        .emitLitDebugLogEvents;\n      if (!shouldEmit) {\n        return;\n      }\n      global.dispatchEvent(\n        new CustomEvent<LitUnstable.DebugLog.Entry>('lit-debug', {\n          detail: event,\n        })\n      );\n    }\n  : undefined;\n// Used for connecting beginRender and endRender events when there are nested\n// renders when errors are thrown preventing an endRender event from being\n// called.\nlet debugLogRenderId = 0;\n\nlet issueWarning: (code: string, warning: string) => void;\n\nif (DEV_MODE) {\n  global.litIssuedWarnings ??= new Set();\n\n  // Issue a warning, if we haven't already.\n  issueWarning = (code: string, warning: string) => {\n    warning += code\n      ? ` See https://lit.dev/msg/${code} for more information.`\n      : '';\n    if (!global.litIssuedWarnings!.has(warning)) {\n      console.warn(warning);\n      global.litIssuedWarnings!.add(warning);\n    }\n  };\n\n  issueWarning(\n    'dev-mode',\n    `Lit is in dev mode. Not recommended for production!`\n  );\n}\n\nconst wrap =\n  ENABLE_SHADYDOM_NOPATCH &&\n  global.ShadyDOM?.inUse &&\n  global.ShadyDOM?.noPatch === true\n    ? global.ShadyDOM!.wrap\n    : (node: Node) => node;\n\nconst trustedTypes = (global as unknown as Partial<Window>).trustedTypes;\n\n/**\n * Our TrustedTypePolicy for HTML which is declared using the html template\n * tag function.\n *\n * That HTML is a developer-authored constant, and is parsed with innerHTML\n * before any untrusted expressions have been mixed in. Therefor it is\n * considered safe by construction.\n */\nconst policy = trustedTypes\n  ? trustedTypes.createPolicy('lit-html', {\n      createHTML: (s) => s,\n    })\n  : undefined;\n\n/**\n * Used to sanitize any value before it is written into the DOM. This can be\n * used to implement a security policy of allowed and disallowed values in\n * order to prevent XSS attacks.\n *\n * One way of using this callback would be to check attributes and properties\n * against a list of high risk fields, and require that values written to such\n * fields be instances of a class which is safe by construction. Closure's Safe\n * HTML Types is one implementation of this technique (\n * https://github.com/google/safe-html-types/blob/master/doc/safehtml-types.md).\n * The TrustedTypes polyfill in API-only mode could also be used as a basis\n * for this technique (https://github.com/WICG/trusted-types).\n *\n * @param node The HTML node (usually either a #text node or an Element) that\n *     is being written to. Note that this is just an exemplar node, the write\n *     may take place against another instance of the same class of node.\n * @param name The name of an attribute or property (for example, 'href').\n * @param type Indicates whether the write that's about to be performed will\n *     be to a property or a node.\n * @return A function that will sanitize this class of writes.\n */\nexport type SanitizerFactory = (\n  node: Node,\n  name: string,\n  type: 'property' | 'attribute'\n) => ValueSanitizer;\n\n/**\n * A function which can sanitize values that will be written to a specific kind\n * of DOM sink.\n *\n * See SanitizerFactory.\n *\n * @param value The value to sanitize. Will be the actual value passed into\n *     the lit-html template literal, so this could be of any type.\n * @return The value to write to the DOM. Usually the same as the input value,\n *     unless sanitization is needed.\n */\nexport type ValueSanitizer = (value: unknown) => unknown;\n\nconst identityFunction: ValueSanitizer = (value: unknown) => value;\nconst noopSanitizer: SanitizerFactory = (\n  _node: Node,\n  _name: string,\n  _type: 'property' | 'attribute'\n) => identityFunction;\n\n/** Sets the global sanitizer factory. */\nconst setSanitizer = (newSanitizer: SanitizerFactory) => {\n  if (!ENABLE_EXTRA_SECURITY_HOOKS) {\n    return;\n  }\n  if (sanitizerFactoryInternal !== noopSanitizer) {\n    throw new Error(\n      `Attempted to overwrite existing lit-html security policy.` +\n        ` setSanitizeDOMValueFactory should be called at most once.`\n    );\n  }\n  sanitizerFactoryInternal = newSanitizer;\n};\n\n/**\n * Only used in internal tests, not a part of the public API.\n */\nconst _testOnlyClearSanitizerFactoryDoNotCallOrElse = () => {\n  sanitizerFactoryInternal = noopSanitizer;\n};\n\nconst createSanitizer: SanitizerFactory = (node, name, type) => {\n  return sanitizerFactoryInternal(node, name, type);\n};\n\n// Added to an attribute name to mark the attribute as bound so we can find\n// it easily.\nconst boundAttributeSuffix = '$lit$';\n\n// This marker is used in many syntactic positions in HTML, so it must be\n// a valid element name and attribute name. We don't support dynamic names (yet)\n// but this at least ensures that the parse tree is closer to the template\n// intention.\nconst marker = `lit$${String(Math.random()).slice(9)}$`;\n\n// String used to tell if a comment is a marker comment\nconst markerMatch = '?' + marker;\n\n// Text used to insert a comment marker node. We use processing instruction\n// syntax because it's slightly smaller, but parses as a comment node.\nconst nodeMarker = `<${markerMatch}>`;\n\nconst d =\n  NODE_MODE && global.document === undefined\n    ? ({\n        createTreeWalker() {\n          return {};\n        },\n      } as unknown as Document)\n    : document;\n\n// Creates a dynamic marker. We never have to search for these in the DOM.\nconst createMarker = (v = '') => d.createComment(v);\n\n// https://tc39.github.io/ecma262/#sec-typeof-operator\ntype Primitive = null | undefined | boolean | number | string | symbol | bigint;\nconst isPrimitive = (value: unknown): value is Primitive =>\n  value === null || (typeof value != 'object' && typeof value != 'function');\nconst isArray = Array.isArray;\nconst isIterable = (value: unknown): value is Iterable<unknown> =>\n  isArray(value) ||\n  // eslint-disable-next-line @typescript-eslint/no-explicit-any\n  typeof (value as any)?.[Symbol.iterator] === 'function';\n\nconst SPACE_CHAR = `[ \\t\\n\\f\\r]`;\nconst ATTR_VALUE_CHAR = `[^ \\t\\n\\f\\r\"'\\`<>=]`;\nconst NAME_CHAR = `[^\\\\s\"'>=/]`;\n\n// These regexes represent the five parsing states that we care about in the\n// Template's HTML scanner. They match the *end* of the state they're named\n// after.\n// Depending on the match, we transition to a new state. If there's no match,\n// we stay in the same state.\n// Note that the regexes are stateful. We utilize lastIndex and sync it\n// across the multiple regexes used. In addition to the five regexes below\n// we also dynamically create a regex to find the matching end tags for raw\n// text elements.\n\n/**\n * End of text is: `<` followed by:\n *   (comment start) or (tag) or (dynamic tag binding)\n */\nconst textEndRegex = /<(?:(!--|\\/[^a-zA-Z])|(\\/?[a-zA-Z][^>\\s]*)|(\\/?$))/g;\nconst COMMENT_START = 1;\nconst TAG_NAME = 2;\nconst DYNAMIC_TAG_NAME = 3;\n\nconst commentEndRegex = /-->/g;\n/**\n * Comments not started with <!--, like </{, can be ended by a single `>`\n */\nconst comment2EndRegex = />/g;\n\n/**\n * The tagEnd regex matches the end of the \"inside an opening\" tag syntax\n * position. It either matches a `>`, an attribute-like sequence, or the end\n * of the string after a space (attribute-name position ending).\n *\n * See attributes in the HTML spec:\n * https://www.w3.org/TR/html5/syntax.html#elements-attributes\n *\n * \" \\t\\n\\f\\r\" are HTML space characters:\n * https://infra.spec.whatwg.org/#ascii-whitespace\n *\n * So an attribute is:\n *  * The name: any character except a whitespace character, (\"), ('), \">\",\n *    \"=\", or \"/\". Note: this is different from the HTML spec which also excludes control characters.\n *  * Followed by zero or more space characters\n *  * Followed by \"=\"\n *  * Followed by zero or more space characters\n *  * Followed by:\n *    * Any character except space, ('), (\"), \"<\", \">\", \"=\", (`), or\n *    * (\") then any non-(\"), or\n *    * (') then any non-(')\n */\nconst tagEndRegex = new RegExp(\n  `>|${SPACE_CHAR}(?:(${NAME_CHAR}+)(${SPACE_CHAR}*=${SPACE_CHAR}*(?:${ATTR_VALUE_CHAR}|(\"|')|))|$)`,\n  'g'\n);\nconst ENTIRE_MATCH = 0;\nconst ATTRIBUTE_NAME = 1;\nconst SPACES_AND_EQUALS = 2;\nconst QUOTE_CHAR = 3;\n\nconst singleQuoteAttrEndRegex = /'/g;\nconst doubleQuoteAttrEndRegex = /\"/g;\n/**\n * Matches the raw text elements.\n *\n * Comments are not parsed within raw text elements, so we need to search their\n * text content for marker strings.\n */\nconst rawTextElement = /^(?:script|style|textarea|title)$/i;\n\n/** TemplateResult types */\nconst HTML_RESULT = 1;\nconst SVG_RESULT = 2;\n\ntype ResultType = typeof HTML_RESULT | typeof SVG_RESULT;\n\n// TemplatePart types\n// IMPORTANT: these must match the values in PartType\nconst ATTRIBUTE_PART = 1;\nconst CHILD_PART = 2;\nconst PROPERTY_PART = 3;\nconst BOOLEAN_ATTRIBUTE_PART = 4;\nconst EVENT_PART = 5;\nconst ELEMENT_PART = 6;\nconst COMMENT_PART = 7;\n\n/**\n * The return type of the template tag functions, {@linkcode html} and\n * {@linkcode svg}.\n *\n * A `TemplateResult` object holds all the information about a template\n * expression required to render it: the template strings, expression values,\n * and type of template (html or svg).\n *\n * `TemplateResult` objects do not create any DOM on their own. To create or\n * update DOM you need to render the `TemplateResult`. See\n * [Rendering](https://lit.dev/docs/components/rendering) for more information.\n *\n */\nexport type TemplateResult<T extends ResultType = ResultType> = {\n  // This property needs to remain unminified.\n  ['_$litType$']: T;\n  strings: TemplateStringsArray;\n  values: unknown[];\n};\n\nexport type HTMLTemplateResult = TemplateResult<typeof HTML_RESULT>;\n\nexport type SVGTemplateResult = TemplateResult<typeof SVG_RESULT>;\n\nexport interface CompiledTemplateResult {\n  // This is a factory in order to make template initialization lazy\n  // and allow ShadyRenderOptions scope to be passed in.\n  // This property needs to remain unminified.\n  ['_$litType$']: CompiledTemplate;\n  values: unknown[];\n}\n\nexport interface CompiledTemplate extends Omit<Template, 'el'> {\n  // el is overridden to be optional. We initialize it on first render\n  el?: HTMLTemplateElement;\n\n  // The prepared HTML string to create a template element from.\n  h: TrustedHTML;\n}\n\n/**\n * Generates a template literal tag function that returns a TemplateResult with\n * the given result type.\n */\nconst tag =\n  <T extends ResultType>(type: T) =>\n  (strings: TemplateStringsArray, ...values: unknown[]): TemplateResult<T> => {\n    // Warn against templates octal escape sequences\n    // We do this here rather than in render so that the warning is closer to the\n    // template definition.\n    if (DEV_MODE && strings.some((s) => s === undefined)) {\n      console.warn(\n        'Some template strings are undefined.\\n' +\n          'This is probably caused by illegal octal escape sequences.'\n      );\n    }\n    return {\n      // This property needs to remain unminified.\n      ['_$litType$']: type,\n      strings,\n      values,\n    };\n  };\n\n/**\n * Interprets a template literal as an HTML template that can efficiently\n * render to and update a container.\n *\n * ```ts\n * const header = (title: string) => html`<h1>${title}</h1>`;\n * ```\n *\n * The `html` tag returns a description of the DOM to render as a value. It is\n * lazy, meaning no work is done until the template is rendered. When rendering,\n * if a template comes from the same expression as a previously rendered result,\n * it's efficiently updated instead of replaced.\n */\nexport const html = tag(HTML_RESULT);\n\n/**\n * Interprets a template literal as an SVG fragment that can efficiently\n * render to and update a container.\n *\n * ```ts\n * const rect = svg`<rect width=\"10\" height=\"10\"></rect>`;\n *\n * const myImage = html`\n *   <svg viewBox=\"0 0 10 10\" xmlns=\"http://www.w3.org/2000/svg\">\n *     ${rect}\n *   </svg>`;\n * ```\n *\n * The `svg` *tag function* should only be used for SVG fragments, or elements\n * that would be contained **inside** an `<svg>` HTML element. A common error is\n * placing an `<svg>` *element* in a template tagged with the `svg` tag\n * function. The `<svg>` element is an HTML element and should be used within a\n * template tagged with the {@linkcode html} tag function.\n *\n * In LitElement usage, it's invalid to return an SVG fragment from the\n * `render()` method, as the SVG fragment will be contained within the element's\n * shadow root and thus cannot be used within an `<svg>` HTML element.\n */\nexport const svg = tag(SVG_RESULT);\n\n/**\n * A sentinel value that signals that a value was handled by a directive and\n * should not be written to the DOM.\n */\nexport const noChange = Symbol.for('lit-noChange');\n\n/**\n * A sentinel value that signals a ChildPart to fully clear its content.\n *\n * ```ts\n * const button = html`${\n *  user.isAdmin\n *    ? html`<button>DELETE</button>`\n *    : nothing\n * }`;\n * ```\n *\n * Prefer using `nothing` over other falsy values as it provides a consistent\n * behavior between various expression binding contexts.\n *\n * In child expressions, `undefined`, `null`, `''`, and `nothing` all behave the\n * same and render no nodes. In attribute expressions, `nothing` _removes_ the\n * attribute, while `undefined` and `null` will render an empty string. In\n * property expressions `nothing` becomes `undefined`.\n */\nexport const nothing = Symbol.for('lit-nothing');\n\n/**\n * The cache of prepared templates, keyed by the tagged TemplateStringsArray\n * and _not_ accounting for the specific template tag used. This means that\n * template tags cannot be dynamic - the must statically be one of html, svg,\n * or attr. This restriction simplifies the cache lookup, which is on the hot\n * path for rendering.\n */\nconst templateCache = new WeakMap<TemplateStringsArray, Template>();\n\n/**\n * Object specifying options for controlling lit-html rendering. Note that\n * while `render` may be called multiple times on the same `container` (and\n * `renderBefore` reference node) to efficiently update the rendered content,\n * only the options passed in during the first render are respected during\n * the lifetime of renders to that unique `container` + `renderBefore`\n * combination.\n */\nexport interface RenderOptions {\n  /**\n   * An object to use as the `this` value for event listeners. It's often\n   * useful to set this to the host component rendering a template.\n   */\n  host?: object;\n  /**\n   * A DOM node before which to render content in the container.\n   */\n  renderBefore?: ChildNode | null;\n  /**\n   * Node used for cloning the template (`importNode` will be called on this\n   * node). This controls the `ownerDocument` of the rendered DOM, along with\n   * any inherited context. Defaults to the global `document`.\n   */\n  creationScope?: {importNode(node: Node, deep?: boolean): Node};\n  /**\n   * The initial connected state for the top-level part being rendered. If no\n   * `isConnected` option is set, `AsyncDirective`s will be connected by\n   * default. Set to `false` if the initial render occurs in a disconnected tree\n   * and `AsyncDirective`s should see `isConnected === false` for their initial\n   * render. The `part.setConnected()` method must be used subsequent to initial\n   * render to change the connected state of the part.\n   */\n  isConnected?: boolean;\n}\n\nconst walker = d.createTreeWalker(\n  d,\n  129 /* NodeFilter.SHOW_{ELEMENT|COMMENT} */,\n  null,\n  false\n);\n\nlet sanitizerFactoryInternal: SanitizerFactory = noopSanitizer;\n\n//\n// Classes only below here, const variable declarations only above here...\n//\n// Keeping variable declarations and classes together improves minification.\n// Interfaces and type aliases can be interleaved freely.\n//\n\n// Type for classes that have a `_directive` or `_directives[]` field, used by\n// `resolveDirective`\nexport interface DirectiveParent {\n  _$parent?: DirectiveParent;\n  _$isConnected: boolean;\n  __directive?: Directive;\n  __directives?: Array<Directive | undefined>;\n}\n\n/**\n * Returns an HTML string for the given TemplateStringsArray and result type\n * (HTML or SVG), along with the case-sensitive bound attribute names in\n * template order. The HTML contains comment markers denoting the `ChildPart`s\n * and suffixes on bound attributes denoting the `AttributeParts`.\n *\n * @param strings template strings array\n * @param type HTML or SVG\n * @return Array containing `[html, attrNames]` (array returned for terseness,\n *     to avoid object fields since this code is shared with non-minified SSR\n *     code)\n */\nconst getTemplateHtml = (\n  strings: TemplateStringsArray,\n  type: ResultType\n): [TrustedHTML, Array<string | undefined>] => {\n  // Insert makers into the template HTML to represent the position of\n  // bindings. The following code scans the template strings to determine the\n  // syntactic position of the bindings. They can be in text position, where\n  // we insert an HTML comment, attribute value position, where we insert a\n  // sentinel string and re-write the attribute name, or inside a tag where\n  // we insert the sentinel string.\n  const l = strings.length - 1;\n  // Stores the case-sensitive bound attribute names in the order of their\n  // parts. ElementParts are also reflected in this array as undefined\n  // rather than a string, to disambiguate from attribute bindings.\n  const attrNames: Array<string | undefined> = [];\n  let html = type === SVG_RESULT ? '<svg>' : '';\n\n  // When we're inside a raw text tag (not it's text content), the regex\n  // will still be tagRegex so we can find attributes, but will switch to\n  // this regex when the tag ends.\n  let rawTextEndRegex: RegExp | undefined;\n\n  // The current parsing state, represented as a reference to one of the\n  // regexes\n  let regex = textEndRegex;\n\n  for (let i = 0; i < l; i++) {\n    const s = strings[i];\n    // The index of the end of the last attribute name. When this is\n    // positive at end of a string, it means we're in an attribute value\n    // position and need to rewrite the attribute name.\n    // We also use a special value of -2 to indicate that we encountered\n    // the end of a string in attribute name position.\n    let attrNameEndIndex = -1;\n    let attrName: string | undefined;\n    let lastIndex = 0;\n    let match!: RegExpExecArray | null;\n\n    // The conditions in this loop handle the current parse state, and the\n    // assignments to the `regex` variable are the state transitions.\n    while (lastIndex < s.length) {\n      // Make sure we start searching from where we previously left off\n      regex.lastIndex = lastIndex;\n      match = regex.exec(s);\n      if (match === null) {\n        break;\n      }\n      lastIndex = regex.lastIndex;\n      if (regex === textEndRegex) {\n        if (match[COMMENT_START] === '!--') {\n          regex = commentEndRegex;\n        } else if (match[COMMENT_START] !== undefined) {\n          // We started a weird comment, like </{\n          regex = comment2EndRegex;\n        } else if (match[TAG_NAME] !== undefined) {\n          if (rawTextElement.test(match[TAG_NAME])) {\n            // Record if we encounter a raw-text element. We'll switch to\n            // this regex at the end of the tag.\n            rawTextEndRegex = new RegExp(`</${match[TAG_NAME]}`, 'g');\n          }\n          regex = tagEndRegex;\n        } else if (match[DYNAMIC_TAG_NAME] !== undefined) {\n          if (DEV_MODE) {\n            throw new Error(\n              'Bindings in tag names are not supported. Please use static templates instead. ' +\n                'See https://lit.dev/docs/templates/expressions/#static-expressions'\n            );\n          }\n          regex = tagEndRegex;\n        }\n      } else if (regex === tagEndRegex) {\n        if (match[ENTIRE_MATCH] === '>') {\n          // End of a tag. If we had started a raw-text element, use that\n          // regex\n          regex = rawTextEndRegex ?? textEndRegex;\n          // We may be ending an unquoted attribute value, so make sure we\n          // clear any pending attrNameEndIndex\n          attrNameEndIndex = -1;\n        } else if (match[ATTRIBUTE_NAME] === undefined) {\n          // Attribute name position\n          attrNameEndIndex = -2;\n        } else {\n          attrNameEndIndex = regex.lastIndex - match[SPACES_AND_EQUALS].length;\n          attrName = match[ATTRIBUTE_NAME];\n          regex =\n            match[QUOTE_CHAR] === undefined\n              ? tagEndRegex\n              : match[QUOTE_CHAR] === '\"'\n              ? doubleQuoteAttrEndRegex\n              : singleQuoteAttrEndRegex;\n        }\n      } else if (\n        regex === doubleQuoteAttrEndRegex ||\n        regex === singleQuoteAttrEndRegex\n      ) {\n        regex = tagEndRegex;\n      } else if (regex === commentEndRegex || regex === comment2EndRegex) {\n        regex = textEndRegex;\n      } else {\n        // Not one of the five state regexes, so it must be the dynamically\n        // created raw text regex and we're at the close of that element.\n        regex = tagEndRegex;\n        rawTextEndRegex = undefined;\n      }\n    }\n\n    if (DEV_MODE) {\n      // If we have a attrNameEndIndex, which indicates that we should\n      // rewrite the attribute name, assert that we're in a valid attribute\n      // position - either in a tag, or a quoted attribute value.\n      console.assert(\n        attrNameEndIndex === -1 ||\n          regex === tagEndRegex ||\n          regex === singleQuoteAttrEndRegex ||\n          regex === doubleQuoteAttrEndRegex,\n        'unexpected parse state B'\n      );\n    }\n\n    // We have four cases:\n    //  1. We're in text position, and not in a raw text element\n    //     (regex === textEndRegex): insert a comment marker.\n    //  2. We have a non-negative attrNameEndIndex which means we need to\n    //     rewrite the attribute name to add a bound attribute suffix.\n    //  3. We're at the non-first binding in a multi-binding attribute, use a\n    //     plain marker.\n    //  4. We're somewhere else inside the tag. If we're in attribute name\n    //     position (attrNameEndIndex === -2), add a sequential suffix to\n    //     generate a unique attribute name.\n\n    // Detect a binding next to self-closing tag end and insert a space to\n    // separate the marker from the tag end:\n    const end =\n      regex === tagEndRegex && strings[i + 1].startsWith('/>') ? ' ' : '';\n    html +=\n      regex === textEndRegex\n        ? s + nodeMarker\n        : attrNameEndIndex >= 0\n        ? (attrNames.push(attrName!),\n          s.slice(0, attrNameEndIndex) +\n            boundAttributeSuffix +\n            s.slice(attrNameEndIndex)) +\n          marker +\n          end\n        : s +\n          marker +\n          (attrNameEndIndex === -2 ? (attrNames.push(undefined), i) : end);\n  }\n\n  const htmlResult: string | TrustedHTML =\n    html + (strings[l] || '<?>') + (type === SVG_RESULT ? '</svg>' : '');\n\n  // A security check to prevent spoofing of Lit template results.\n  // In the future, we may be able to replace this with Array.isTemplateObject,\n  // though we might need to make that check inside of the html and svg\n  // functions, because precompiled templates don't come in as\n  // TemplateStringArray objects.\n  if (!Array.isArray(strings) || !strings.hasOwnProperty('raw')) {\n    let message = 'invalid template strings array';\n    if (DEV_MODE) {\n      message = `\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\n          If you're using the html or svg tagged template functions normally\n          and 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        `\n        .trim()\n        .replace(/\\n */g, '\\n');\n    }\n    throw new Error(message);\n  }\n  // Returned as an array for terseness\n  return [\n    policy !== undefined\n      ? policy.createHTML(htmlResult)\n      : (htmlResult as unknown as TrustedHTML),\n    attrNames,\n  ];\n};\n\n/** @internal */\nexport type {Template};\nclass Template {\n  /** @internal */\n  el!: HTMLTemplateElement;\n  /** @internal */\n  parts: Array<TemplatePart> = [];\n\n  constructor(\n    // This property needs to remain unminified.\n    {strings, ['_$litType$']: type}: TemplateResult,\n    options?: RenderOptions\n  ) {\n    let node: Node | null;\n    let nodeIndex = 0;\n    let attrNameIndex = 0;\n    const partCount = strings.length - 1;\n    const parts = this.parts;\n\n    // Create template element\n    const [html, attrNames] = getTemplateHtml(strings, type);\n    this.el = Template.createElement(html, options);\n    walker.currentNode = this.el.content;\n\n    // Reparent SVG nodes into template root\n    if (type === SVG_RESULT) {\n      const content = this.el.content;\n      const svgElement = content.firstChild!;\n      svgElement.remove();\n      content.append(...svgElement.childNodes);\n    }\n\n    // Walk the template to find binding markers and create TemplateParts\n    while ((node = walker.nextNode()) !== null && parts.length < partCount) {\n      if (node.nodeType === 1) {\n        if (DEV_MODE) {\n          const tag = (node as Element).localName;\n          // Warn if `textarea` includes an expression and throw if `template`\n          // does since these are not supported. We do this by checking\n          // innerHTML for anything that looks like a marker. This catches\n          // cases like bindings in textarea there markers turn into text nodes.\n          if (\n            /^(?:textarea|template)$/i!.test(tag) &&\n            (node as Element).innerHTML.includes(marker)\n          ) {\n            const m =\n              `Expressions are not supported inside \\`${tag}\\` ` +\n              `elements. See https://lit.dev/msg/expression-in-${tag} for more ` +\n              `information.`;\n            if (tag === 'template') {\n              throw new Error(m);\n            } else issueWarning('', m);\n          }\n        }\n        // TODO (justinfagnani): for attempted dynamic tag names, we don't\n        // increment the bindingIndex, and it'll be off by 1 in the element\n        // and off by two after it.\n        if ((node as Element).hasAttributes()) {\n          // We defer removing bound attributes because on IE we might not be\n          // iterating attributes in their template order, and would sometimes\n          // remove an attribute that we still need to create a part for.\n          const attrsToRemove = [];\n          for (const name of (node as Element).getAttributeNames()) {\n            // `name` is the name of the attribute we're iterating over, but not\n            // _neccessarily_ the name of the attribute we will create a part\n            // for. They can be different in browsers that don't iterate on\n            // attributes in source order. In that case the attrNames array\n            // contains the attribute name we'll process next. We only need the\n            // attribute name here to know if we should process a bound attribute\n            // on this element.\n            if (\n              name.endsWith(boundAttributeSuffix) ||\n              name.startsWith(marker)\n            ) {\n              const realName = attrNames[attrNameIndex++];\n              attrsToRemove.push(name);\n              if (realName !== undefined) {\n                // Lowercase for case-sensitive SVG attributes like viewBox\n                const value = (node as Element).getAttribute(\n                  realName.toLowerCase() + boundAttributeSuffix\n                )!;\n                const statics = value.split(marker);\n                const m = /([.?@])?(.*)/.exec(realName)!;\n                parts.push({\n                  type: ATTRIBUTE_PART,\n                  index: nodeIndex,\n                  name: m[2],\n                  strings: statics,\n                  ctor:\n                    m[1] === '.'\n                      ? PropertyPart\n                      : m[1] === '?'\n                      ? BooleanAttributePart\n                      : m[1] === '@'\n                      ? EventPart\n                      : AttributePart,\n                });\n              } else {\n                parts.push({\n                  type: ELEMENT_PART,\n                  index: nodeIndex,\n                });\n              }\n            }\n          }\n          for (const name of attrsToRemove) {\n            (node as Element).removeAttribute(name);\n          }\n        }\n        // TODO (justinfagnani): benchmark the regex against testing for each\n        // of the 3 raw text element names.\n        if (rawTextElement.test((node as Element).tagName)) {\n          // For raw text elements we need to split the text content on\n          // markers, create a Text node for each segment, and create\n          // a TemplatePart for each marker.\n          const strings = (node as Element).textContent!.split(marker);\n          const lastIndex = strings.length - 1;\n          if (lastIndex > 0) {\n            (node as Element).textContent = trustedTypes\n              ? (trustedTypes.emptyScript as unknown as '')\n              : '';\n            // Generate a new text node for each literal section\n            // These nodes are also used as the markers for node parts\n            // We can't use empty text nodes as markers because they're\n            // normalized when cloning in IE (could simplify when\n            // IE is no longer supported)\n            for (let i = 0; i < lastIndex; i++) {\n              (node as Element).append(strings[i], createMarker());\n              // Walk past the marker node we just added\n              walker.nextNode();\n              parts.push({type: CHILD_PART, index: ++nodeIndex});\n            }\n            // Note because this marker is added after the walker's current\n            // node, it will be walked to in the outer loop (and ignored), so\n            // we don't need to adjust nodeIndex here\n            (node as Element).append(strings[lastIndex], createMarker());\n          }\n        }\n      } else if (node.nodeType === 8) {\n        const data = (node as Comment).data;\n        if (data === markerMatch) {\n          parts.push({type: CHILD_PART, index: nodeIndex});\n        } else {\n          let i = -1;\n          while ((i = (node as Comment).data.indexOf(marker, i + 1)) !== -1) {\n            // Comment node has a binding marker inside, make an inactive part\n            // The binding won't work, but subsequent bindings will\n            parts.push({type: COMMENT_PART, index: nodeIndex});\n            // Move to the end of the match\n            i += marker.length - 1;\n          }\n        }\n      }\n      nodeIndex++;\n    }\n    debugLogEvent?.({\n      kind: 'template prep',\n      template: this,\n      clonableTemplate: this.el,\n      parts: this.parts,\n      strings,\n    });\n  }\n\n  // Overridden via `litHtmlPolyfillSupport` to provide platform support.\n  /** @nocollapse */\n  static createElement(html: TrustedHTML, _options?: RenderOptions) {\n    const el = d.createElement('template');\n    el.innerHTML = html as unknown as string;\n    return el;\n  }\n}\n\nexport interface Disconnectable {\n  _$parent?: Disconnectable;\n  _$disconnectableChildren?: Set<Disconnectable>;\n  // Rather than hold connection state on instances, Disconnectables recursively\n  // fetch the connection state from the RootPart they are connected in via\n  // getters up the Disconnectable tree via _$parent references. This pushes the\n  // cost of tracking the isConnected state to `AsyncDirectives`, and avoids\n  // needing to pass all Disconnectables (parts, template instances, and\n  // directives) their connection state each time it changes, which would be\n  // costly for trees that have no AsyncDirectives.\n  _$isConnected: boolean;\n}\n\nfunction resolveDirective(\n  part: ChildPart | AttributePart | ElementPart,\n  value: unknown,\n  parent: DirectiveParent = part,\n  attributeIndex?: number\n): unknown {\n  // Bail early if the value is explicitly noChange. Note, this means any\n  // nested directive is still attached and is not run.\n  if (value === noChange) {\n    return value;\n  }\n  let currentDirective =\n    attributeIndex !== undefined\n      ? (parent as AttributePart).__directives?.[attributeIndex]\n      : (parent as ChildPart | ElementPart | Directive).__directive;\n  const nextDirectiveConstructor = isPrimitive(value)\n    ? undefined\n    : // This property needs to remain unminified.\n      (value as DirectiveResult)['_$litDirective$'];\n  if (currentDirective?.constructor !== nextDirectiveConstructor) {\n    // This property needs to remain unminified.\n    currentDirective?.['_$notifyDirectiveConnectionChanged']?.(false);\n    if (nextDirectiveConstructor === undefined) {\n      currentDirective = undefined;\n    } else {\n      currentDirective = new nextDirectiveConstructor(part as PartInfo);\n      currentDirective._$initialize(part, parent, attributeIndex);\n    }\n    if (attributeIndex !== undefined) {\n      ((parent as AttributePart).__directives ??= [])[attributeIndex] =\n        currentDirective;\n    } else {\n      (parent as ChildPart | Directive).__directive = currentDirective;\n    }\n  }\n  if (currentDirective !== undefined) {\n    value = resolveDirective(\n      part,\n      currentDirective._$resolve(part, (value as DirectiveResult).values),\n      currentDirective,\n      attributeIndex\n    );\n  }\n  return value;\n}\n\n/**\n * An updateable instance of a Template. Holds references to the Parts used to\n * update the template instance.\n */\nclass TemplateInstance implements Disconnectable {\n  /** @internal */\n  _$template: Template;\n  /** @internal */\n  _parts: Array<Part | undefined> = [];\n\n  /** @internal */\n  _$parent: ChildPart;\n  /** @internal */\n  _$disconnectableChildren?: Set<Disconnectable> = undefined;\n\n  constructor(template: Template, parent: ChildPart) {\n    this._$template = template;\n    this._$parent = parent;\n  }\n\n  // Called by ChildPart parentNode getter\n  get parentNode() {\n    return this._$parent.parentNode;\n  }\n\n  // See comment in Disconnectable interface for why this is a getter\n  get _$isConnected() {\n    return this._$parent._$isConnected;\n  }\n\n  // This method is separate from the constructor because we need to return a\n  // DocumentFragment and we don't want to hold onto it with an instance field.\n  _clone(options: RenderOptions | undefined) {\n    const {\n      el: {content},\n      parts: parts,\n    } = this._$template;\n    const fragment = (options?.creationScope ?? d).importNode(content, true);\n    walker.currentNode = fragment;\n\n    let node = walker.nextNode()!;\n    let nodeIndex = 0;\n    let partIndex = 0;\n    let templatePart = parts[0];\n\n    while (templatePart !== undefined) {\n      if (nodeIndex === templatePart.index) {\n        let part: Part | undefined;\n        if (templatePart.type === CHILD_PART) {\n          part = new ChildPart(\n            node as HTMLElement,\n            node.nextSibling,\n            this,\n            options\n          );\n        } else if (templatePart.type === ATTRIBUTE_PART) {\n          part = new templatePart.ctor(\n            node as HTMLElement,\n            templatePart.name,\n            templatePart.strings,\n            this,\n            options\n          );\n        } else if (templatePart.type === ELEMENT_PART) {\n          part = new ElementPart(node as HTMLElement, this, options);\n        }\n        this._parts.push(part);\n        templatePart = parts[++partIndex];\n      }\n      if (nodeIndex !== templatePart?.index) {\n        node = walker.nextNode()!;\n        nodeIndex++;\n      }\n    }\n    return fragment;\n  }\n\n  _update(values: Array<unknown>) {\n    let i = 0;\n    for (const part of this._parts) {\n      if (part !== undefined) {\n        debugLogEvent?.({\n          kind: 'set part',\n          part,\n          value: values[i],\n          valueIndex: i,\n          values,\n          templateInstance: this,\n        });\n        if ((part as AttributePart).strings !== undefined) {\n          (part as AttributePart)._$setValue(values, part as AttributePart, i);\n          // The number of values the part consumes is part.strings.length - 1\n          // since values are in between template spans. We increment i by 1\n          // later in the loop, so increment it by part.strings.length - 2 here\n          i += (part as AttributePart).strings!.length - 2;\n        } else {\n          part._$setValue(values[i]);\n        }\n      }\n      i++;\n    }\n  }\n}\n\n/*\n * Parts\n */\ntype AttributeTemplatePart = {\n  readonly type: typeof ATTRIBUTE_PART;\n  readonly index: number;\n  readonly name: string;\n  /** @internal */\n  readonly ctor: typeof AttributePart;\n  /** @internal */\n  readonly strings: ReadonlyArray<string>;\n};\ntype NodeTemplatePart = {\n  readonly type: typeof CHILD_PART;\n  readonly index: number;\n};\ntype ElementTemplatePart = {\n  readonly type: typeof ELEMENT_PART;\n  readonly index: number;\n};\ntype CommentTemplatePart = {\n  readonly type: typeof COMMENT_PART;\n  readonly index: number;\n};\n\n/**\n * A TemplatePart represents a dynamic part in a template, before the template\n * is instantiated. When a template is instantiated Parts are created from\n * TemplateParts.\n */\ntype TemplatePart =\n  | NodeTemplatePart\n  | AttributeTemplatePart\n  | ElementTemplatePart\n  | CommentTemplatePart;\n\nexport type Part =\n  | ChildPart\n  | AttributePart\n  | PropertyPart\n  | BooleanAttributePart\n  | ElementPart\n  | EventPart;\n\nexport type {ChildPart};\nclass ChildPart implements Disconnectable {\n  readonly type = CHILD_PART;\n  readonly options: RenderOptions | undefined;\n  _$committedValue: unknown = nothing;\n  /** @internal */\n  __directive?: Directive;\n  /** @internal */\n  _$startNode: ChildNode;\n  /** @internal */\n  _$endNode: ChildNode | null;\n  private _textSanitizer: ValueSanitizer | undefined;\n  /** @internal */\n  _$parent: Disconnectable | undefined;\n  /**\n   * Connection state for RootParts only (i.e. ChildPart without _$parent\n   * returned from top-level `render`). This field is unsed otherwise. The\n   * intention would clearer if we made `RootPart` a subclass of `ChildPart`\n   * with this field (and a different _$isConnected getter), but the subclass\n   * caused a perf regression, possibly due to making call sites polymorphic.\n   * @internal\n   */\n  __isConnected: boolean;\n\n  // See comment in Disconnectable interface for why this is a getter\n  get _$isConnected() {\n    // ChildParts that are not at the root should always be created with a\n    // parent; only RootChildNode's won't, so they return the local isConnected\n    // state\n    return this._$parent?._$isConnected ?? this.__isConnected;\n  }\n\n  // The following fields will be patched onto ChildParts when required by\n  // AsyncDirective\n  /** @internal */\n  _$disconnectableChildren?: Set<Disconnectable> = undefined;\n  /** @internal */\n  _$notifyConnectionChanged?(\n    isConnected: boolean,\n    removeFromParent?: boolean,\n    from?: number\n  ): void;\n  /** @internal */\n  _$reparentDisconnectables?(parent: Disconnectable): void;\n\n  constructor(\n    startNode: ChildNode,\n    endNode: ChildNode | null,\n    parent: TemplateInstance | ChildPart | undefined,\n    options: RenderOptions | undefined\n  ) {\n    this._$startNode = startNode;\n    this._$endNode = endNode;\n    this._$parent = parent;\n    this.options = options;\n    // Note __isConnected is only ever accessed on RootParts (i.e. when there is\n    // no _$parent); the value on a non-root-part is \"don't care\", but checking\n    // for parent would be more code\n    this.__isConnected = options?.isConnected ?? true;\n    if (ENABLE_EXTRA_SECURITY_HOOKS) {\n      // Explicitly initialize for consistent class shape.\n      this._textSanitizer = undefined;\n    }\n  }\n\n  /**\n   * The parent node into which the part renders its content.\n   *\n   * A ChildPart's content consists of a range of adjacent child nodes of\n   * `.parentNode`, possibly bordered by 'marker nodes' (`.startNode` and\n   * `.endNode`).\n   *\n   * - If both `.startNode` and `.endNode` are non-null, then the part's content\n   * consists of all siblings between `.startNode` and `.endNode`, exclusively.\n   *\n   * - If `.startNode` is non-null but `.endNode` is null, then the part's\n   * content consists of all siblings following `.startNode`, up to and\n   * including the last child of `.parentNode`. If `.endNode` is non-null, then\n   * `.startNode` will always be non-null.\n   *\n   * - If both `.endNode` and `.startNode` are null, then the part's content\n   * consists of all child nodes of `.parentNode`.\n   */\n  get parentNode(): Node {\n    let parentNode: Node = wrap(this._$startNode).parentNode!;\n    const parent = this._$parent;\n    if (\n      parent !== undefined &&\n      parentNode.nodeType === 11 /* Node.DOCUMENT_FRAGMENT */\n    ) {\n      // If the parentNode is a DocumentFragment, it may be because the DOM is\n      // still in the cloned fragment during initial render; if so, get the real\n      // parentNode the part will be committed into by asking the parent.\n      parentNode = (parent as ChildPart | TemplateInstance).parentNode;\n    }\n    return parentNode;\n  }\n\n  /**\n   * The part's leading marker node, if any. See `.parentNode` for more\n   * information.\n   */\n  get startNode(): Node | null {\n    return this._$startNode;\n  }\n\n  /**\n   * The part's trailing marker node, if any. See `.parentNode` for more\n   * information.\n   */\n  get endNode(): Node | null {\n    return this._$endNode;\n  }\n\n  _$setValue(value: unknown, directiveParent: DirectiveParent = this): void {\n    if (DEV_MODE && this.parentNode === null) {\n      throw new Error(\n        `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.`\n      );\n    }\n    value = resolveDirective(this, value, directiveParent);\n    if (isPrimitive(value)) {\n      // Non-rendering child values. It's important that these do not render\n      // empty text nodes to avoid issues with preventing default <slot>\n      // fallback content.\n      if (value === nothing || value == null || value === '') {\n        if (this._$committedValue !== nothing) {\n          debugLogEvent?.({\n            kind: 'commit nothing to child',\n            start: this._$startNode,\n            end: this._$endNode,\n            parent: this._$parent,\n            options: this.options,\n          });\n          this._$clear();\n        }\n        this._$committedValue = nothing;\n      } else if (value !== this._$committedValue && value !== noChange) {\n        this._commitText(value);\n      }\n      // This property needs to remain unminified.\n    } else if ((value as TemplateResult)['_$litType$'] !== undefined) {\n      this._commitTemplateResult(value as TemplateResult);\n    } else if ((value as Node).nodeType !== undefined) {\n      if (DEV_MODE && this.options?.host === value) {\n        this._commitText(\n          `[probable mistake: rendered a template's host in itself ` +\n            `(commonly caused by writing \\${this} in a template]`\n        );\n        console.warn(\n          `Attempted to render the template host`,\n          value,\n          `inside itself. This is almost always a mistake, and in dev mode `,\n          `we render some warning text. In production however, we'll `,\n          `render it, which will usually result in an error, and sometimes `,\n          `in the element disappearing from the DOM.`\n        );\n        return;\n      }\n      this._commitNode(value as Node);\n    } else if (isIterable(value)) {\n      this._commitIterable(value);\n    } else {\n      // Fallback, will render the string representation\n      this._commitText(value);\n    }\n  }\n\n  private _insert<T extends Node>(node: T, ref = this._$endNode) {\n    return wrap(wrap(this._$startNode).parentNode!).insertBefore(node, ref);\n  }\n\n  private _commitNode(value: Node): void {\n    if (this._$committedValue !== value) {\n      this._$clear();\n      if (\n        ENABLE_EXTRA_SECURITY_HOOKS &&\n        sanitizerFactoryInternal !== noopSanitizer\n      ) {\n        const parentNodeName = this._$startNode.parentNode?.nodeName;\n        if (parentNodeName === 'STYLE' || parentNodeName === 'SCRIPT') {\n          let message = 'Forbidden';\n          if (DEV_MODE) {\n            if (parentNodeName === 'STYLE') {\n              message =\n                `Lit does not support binding inside style nodes. ` +\n                `This is a security risk, as style injection attacks can ` +\n                `exfiltrate data and spoof UIs. ` +\n                `Consider instead using css\\`...\\` literals ` +\n                `to compose styles, and make do dynamic styling with ` +\n                `css custom properties, ::parts, <slot>s, ` +\n                `and by mutating the DOM rather than stylesheets.`;\n            } else {\n              message =\n                `Lit does not support binding inside script nodes. ` +\n                `This is a security risk, as it could allow arbitrary ` +\n                `code execution.`;\n            }\n          }\n          throw new Error(message);\n        }\n      }\n      debugLogEvent?.({\n        kind: 'commit node',\n        start: this._$startNode,\n        parent: this._$parent,\n        value: value,\n        options: this.options,\n      });\n      this._$committedValue = this._insert(value);\n    }\n  }\n\n  private _commitText(value: unknown): void {\n    // If the committed value is a primitive it means we called _commitText on\n    // the previous render, and we know that this._$startNode.nextSibling is a\n    // Text node. We can now just replace the text content (.data) of the node.\n    if (\n      this._$committedValue !== nothing &&\n      isPrimitive(this._$committedValue)\n    ) {\n      const node = wrap(this._$startNode).nextSibling as Text;\n      if (ENABLE_EXTRA_SECURITY_HOOKS) {\n        if (this._textSanitizer === undefined) {\n          this._textSanitizer = createSanitizer(node, 'data', 'property');\n        }\n        value = this._textSanitizer(value);\n      }\n      debugLogEvent?.({\n        kind: 'commit text',\n        node,\n        value,\n        options: this.options,\n      });\n      (node as Text).data = value as string;\n    } else {\n      if (ENABLE_EXTRA_SECURITY_HOOKS) {\n        const textNode = document.createTextNode('');\n        this._commitNode(textNode);\n        // When setting text content, for security purposes it matters a lot\n        // what the parent is. For example, <style> and <script> need to be\n        // handled with care, while <span> does not. So first we need to put a\n        // text node into the document, then we can sanitize its content.\n        if (this._textSanitizer === undefined) {\n          this._textSanitizer = createSanitizer(textNode, 'data', 'property');\n        }\n        value = this._textSanitizer(value);\n        debugLogEvent?.({\n          kind: 'commit text',\n          node: textNode,\n          value,\n          options: this.options,\n        });\n        textNode.data = value as string;\n      } else {\n        this._commitNode(d.createTextNode(value as string));\n        debugLogEvent?.({\n          kind: 'commit text',\n          node: wrap(this._$startNode).nextSibling as Text,\n          value,\n          options: this.options,\n        });\n      }\n    }\n    this._$committedValue = value;\n  }\n\n  private _commitTemplateResult(\n    result: TemplateResult | CompiledTemplateResult\n  ): void {\n    // This property needs to remain unminified.\n    const {values, ['_$litType$']: type} = result;\n    // If $litType$ is a number, result is a plain TemplateResult and we get\n    // the template from the template cache. If not, result is a\n    // CompiledTemplateResult and _$litType$ is a CompiledTemplate and we need\n    // to create the <template> element the first time we see it.\n    const template: Template | CompiledTemplate =\n      typeof type === 'number'\n        ? this._$getTemplate(result as TemplateResult)\n        : (type.el === undefined &&\n            (type.el = Template.createElement(type.h, this.options)),\n          type);\n\n    if ((this._$committedValue as TemplateInstance)?._$template === template) {\n      debugLogEvent?.({\n        kind: 'template updating',\n        template,\n        instance: this._$committedValue as TemplateInstance,\n        parts: (this._$committedValue as TemplateInstance)._parts,\n        options: this.options,\n        values,\n      });\n      (this._$committedValue as TemplateInstance)._update(values);\n    } else {\n      const instance = new TemplateInstance(template as Template, this);\n      const fragment = instance._clone(this.options);\n      debugLogEvent?.({\n        kind: 'template instantiated',\n        template,\n        instance,\n        parts: instance._parts,\n        options: this.options,\n        fragment,\n        values,\n      });\n      instance._update(values);\n      debugLogEvent?.({\n        kind: 'template instantiated and updated',\n        template,\n        instance,\n        parts: instance._parts,\n        options: this.options,\n        fragment,\n        values,\n      });\n      this._commitNode(fragment);\n      this._$committedValue = instance;\n    }\n  }\n\n  // Overridden via `litHtmlPolyfillSupport` to provide platform support.\n  /** @internal */\n  _$getTemplate(result: TemplateResult) {\n    let template = templateCache.get(result.strings);\n    if (template === undefined) {\n      templateCache.set(result.strings, (template = new Template(result)));\n    }\n    return template;\n  }\n\n  private _commitIterable(value: Iterable<unknown>): void {\n    // For an Iterable, we create a new InstancePart per item, then set its\n    // value to the item. This is a little bit of overhead for every item in\n    // an Iterable, but it lets us recurse easily and efficiently update Arrays\n    // of TemplateResults that will be commonly returned from expressions like:\n    // array.map((i) => html`${i}`), by reusing existing TemplateInstances.\n\n    // If value is an array, then the previous render was of an\n    // iterable and value will contain the ChildParts from the previous\n    // render. If value is not an array, clear this part and make a new\n    // array for ChildParts.\n    if (!isArray(this._$committedValue)) {\n      this._$committedValue = [];\n      this._$clear();\n    }\n\n    // Lets us keep track of how many items we stamped so we can clear leftover\n    // items from a previous render\n    const itemParts = this._$committedValue as ChildPart[];\n    let partIndex = 0;\n    let itemPart: ChildPart | undefined;\n\n    for (const item of value) {\n      if (partIndex === itemParts.length) {\n        // If no existing part, create a new one\n        // TODO (justinfagnani): test perf impact of always creating two parts\n        // instead of sharing parts between nodes\n        // https://github.com/lit/lit/issues/1266\n        itemParts.push(\n          (itemPart = new ChildPart(\n            this._insert(createMarker()),\n            this._insert(createMarker()),\n            this,\n            this.options\n          ))\n        );\n      } else {\n        // Reuse an existing part\n        itemPart = itemParts[partIndex];\n      }\n      itemPart._$setValue(item);\n      partIndex++;\n    }\n\n    if (partIndex < itemParts.length) {\n      // itemParts always have end nodes\n      this._$clear(\n        itemPart && wrap(itemPart._$endNode!).nextSibling,\n        partIndex\n      );\n      // Truncate the parts array so _value reflects the current state\n      itemParts.length = partIndex;\n    }\n  }\n\n  /**\n   * Removes the nodes contained within this Part from the DOM.\n   *\n   * @param start Start node to clear from, for clearing a subset of the part's\n   *     DOM (used when truncating iterables)\n   * @param from  When `start` is specified, the index within the iterable from\n   *     which ChildParts are being removed, used for disconnecting directives in\n   *     those Parts.\n   *\n   * @internal\n   */\n  _$clear(\n    start: ChildNode | null = wrap(this._$startNode).nextSibling,\n    from?: number\n  ) {\n    this._$notifyConnectionChanged?.(false, true, from);\n    while (start && start !== this._$endNode) {\n      const n = wrap(start!).nextSibling;\n      (wrap(start!) as Element).remove();\n      start = n;\n    }\n  }\n  /**\n   * Implementation of RootPart's `isConnected`. Note that this metod\n   * should only be called on `RootPart`s (the `ChildPart` returned from a\n   * top-level `render()` call). It has no effect on non-root ChildParts.\n   * @param isConnected Whether to set\n   * @internal\n   */\n  setConnected(isConnected: boolean) {\n    if (this._$parent === undefined) {\n      this.__isConnected = isConnected;\n      this._$notifyConnectionChanged?.(isConnected);\n    } else if (DEV_MODE) {\n      throw new Error(\n        'part.setConnected() may only be called on a ' +\n          'RootPart returned from render().'\n      );\n    }\n  }\n}\n\n/**\n * A top-level `ChildPart` returned from `render` that manages the connected\n * state of `AsyncDirective`s created throughout the tree below it.\n */\nexport interface RootPart extends ChildPart {\n  /**\n   * Sets the connection state for `AsyncDirective`s contained within this root\n   * ChildPart.\n   *\n   * lit-html does not automatically monitor the connectedness of DOM rendered;\n   * as such, it is the responsibility of the caller to `render` to ensure that\n   * `part.setConnected(false)` is called before the part object is potentially\n   * discarded, to ensure that `AsyncDirective`s have a chance to dispose of\n   * any resources being held. If a `RootPart` that was prevously\n   * disconnected is subsequently re-connected (and its `AsyncDirective`s should\n   * re-connect), `setConnected(true)` should be called.\n   *\n   * @param isConnected Whether directives within this tree should be connected\n   * or not\n   */\n  setConnected(isConnected: boolean): void;\n}\n\nexport type {AttributePart};\nclass AttributePart implements Disconnectable {\n  readonly type = ATTRIBUTE_PART as\n    | typeof ATTRIBUTE_PART\n    | typeof PROPERTY_PART\n    | typeof BOOLEAN_ATTRIBUTE_PART\n    | typeof EVENT_PART;\n  readonly element: HTMLElement;\n  readonly name: string;\n  readonly options: RenderOptions | undefined;\n\n  /**\n   * If this attribute part represents an interpolation, this contains the\n   * static strings of the interpolation. For single-value, complete bindings,\n   * this is undefined.\n   */\n  readonly strings?: ReadonlyArray<string>;\n  /** @internal */\n  _$committedValue: unknown | Array<unknown> = nothing;\n  /** @internal */\n  __directives?: Array<Directive | undefined>;\n  /** @internal */\n  _$parent: Disconnectable;\n  /** @internal */\n  _$disconnectableChildren?: Set<Disconnectable> = undefined;\n\n  protected _sanitizer: ValueSanitizer | undefined;\n\n  get tagName() {\n    return this.element.tagName;\n  }\n\n  // See comment in Disconnectable interface for why this is a getter\n  get _$isConnected() {\n    return this._$parent._$isConnected;\n  }\n\n  constructor(\n    element: HTMLElement,\n    name: string,\n    strings: ReadonlyArray<string>,\n    parent: Disconnectable,\n    options: RenderOptions | undefined\n  ) {\n    this.element = element;\n    this.name = name;\n    this._$parent = parent;\n    this.options = options;\n    if (strings.length > 2 || strings[0] !== '' || strings[1] !== '') {\n      this._$committedValue = new Array(strings.length - 1).fill(new String());\n      this.strings = strings;\n    } else {\n      this._$committedValue = nothing;\n    }\n    if (ENABLE_EXTRA_SECURITY_HOOKS) {\n      this._sanitizer = undefined;\n    }\n  }\n\n  /**\n   * Sets the value of this part by resolving the value from possibly multiple\n   * values and static strings and committing it to the DOM.\n   * If this part is single-valued, `this._strings` will be undefined, and the\n   * method will be called with a single value argument. If this part is\n   * multi-value, `this._strings` will be defined, and the method is called\n   * with the value array of the part's owning TemplateInstance, and an offset\n   * into the value array from which the values should be read.\n   * This method is overloaded this way to eliminate short-lived array slices\n   * of the template instance values, and allow a fast-path for single-valued\n   * parts.\n   *\n   * @param value The part value, or an array of values for multi-valued parts\n   * @param valueIndex the index to start reading values from. `undefined` for\n   *   single-valued parts\n   * @param noCommit causes the part to not commit its value to the DOM. Used\n   *   in hydration to prime attribute parts with their first-rendered value,\n   *   but not set the attribute, and in SSR to no-op the DOM operation and\n   *   capture the value for serialization.\n   *\n   * @internal\n   */\n  _$setValue(\n    value: unknown | Array<unknown>,\n    directiveParent: DirectiveParent = this,\n    valueIndex?: number,\n    noCommit?: boolean\n  ) {\n    const strings = this.strings;\n\n    // Whether any of the values has changed, for dirty-checking\n    let change = false;\n\n    if (strings === undefined) {\n      // Single-value binding case\n      value = resolveDirective(this, value, directiveParent, 0);\n      change =\n        !isPrimitive(value) ||\n        (value !== this._$committedValue && value !== noChange);\n      if (change) {\n        this._$committedValue = value;\n      }\n    } else {\n      // Interpolation case\n      const values = value as Array<unknown>;\n      value = strings[0];\n\n      let i, v;\n      for (i = 0; i < strings.length - 1; i++) {\n        v = resolveDirective(this, values[valueIndex! + i], directiveParent, i);\n\n        if (v === noChange) {\n          // If the user-provided value is `noChange`, use the previous value\n          v = (this._$committedValue as Array<unknown>)[i];\n        }\n        change ||=\n          !isPrimitive(v) || v !== (this._$committedValue as Array<unknown>)[i];\n        if (v === nothing) {\n          value = nothing;\n        } else if (value !== nothing) {\n          value += (v ?? '') + strings[i + 1];\n        }\n        // We always record each value, even if one is `nothing`, for future\n        // change detection.\n        (this._$committedValue as Array<unknown>)[i] = v;\n      }\n    }\n    if (change && !noCommit) {\n      this._commitValue(value);\n    }\n  }\n\n  /** @internal */\n  _commitValue(value: unknown) {\n    if (value === nothing) {\n      (wrap(this.element) as Element).removeAttribute(this.name);\n    } else {\n      if (ENABLE_EXTRA_SECURITY_HOOKS) {\n        if (this._sanitizer === undefined) {\n          this._sanitizer = sanitizerFactoryInternal(\n            this.element,\n            this.name,\n            'attribute'\n          );\n        }\n        value = this._sanitizer(value ?? '');\n      }\n      debugLogEvent?.({\n        kind: 'commit attribute',\n        element: this.element,\n        name: this.name,\n        value,\n        options: this.options,\n      });\n      (wrap(this.element) as Element).setAttribute(\n        this.name,\n        (value ?? '') as string\n      );\n    }\n  }\n}\n\nexport type {PropertyPart};\nclass PropertyPart extends AttributePart {\n  override readonly type = PROPERTY_PART;\n\n  /** @internal */\n  override _commitValue(value: unknown) {\n    if (ENABLE_EXTRA_SECURITY_HOOKS) {\n      if (this._sanitizer === undefined) {\n        this._sanitizer = sanitizerFactoryInternal(\n          this.element,\n          this.name,\n          'property'\n        );\n      }\n      value = this._sanitizer(value);\n    }\n    debugLogEvent?.({\n      kind: 'commit property',\n      element: this.element,\n      name: this.name,\n      value,\n      options: this.options,\n    });\n    // eslint-disable-next-line @typescript-eslint/no-explicit-any\n    (this.element as any)[this.name] = value === nothing ? undefined : value;\n  }\n}\n\n// Temporary workaround for https://crbug.com/993268\n// Currently, any attribute starting with \"on\" is considered to be a\n// TrustedScript source. Such boolean attributes must be set to the equivalent\n// trusted emptyScript value.\nconst emptyStringForBooleanAttribute = trustedTypes\n  ? (trustedTypes.emptyScript as unknown as '')\n  : '';\n\nexport type {BooleanAttributePart};\nclass BooleanAttributePart extends AttributePart {\n  override readonly type = BOOLEAN_ATTRIBUTE_PART;\n\n  /** @internal */\n  override _commitValue(value: unknown) {\n    debugLogEvent?.({\n      kind: 'commit boolean attribute',\n      element: this.element,\n      name: this.name,\n      value: !!(value && value !== nothing),\n      options: this.options,\n    });\n    if (value && value !== nothing) {\n      (wrap(this.element) as Element).setAttribute(\n        this.name,\n        emptyStringForBooleanAttribute\n      );\n    } else {\n      (wrap(this.element) as Element).removeAttribute(this.name);\n    }\n  }\n}\n\ntype EventListenerWithOptions = EventListenerOrEventListenerObject &\n  Partial<AddEventListenerOptions>;\n\n/**\n * An AttributePart that manages an event listener via add/removeEventListener.\n *\n * This part works by adding itself as the event listener on an element, then\n * delegating to the value passed to it. This reduces the number of calls to\n * add/removeEventListener if the listener changes frequently, such as when an\n * inline function is used as a listener.\n *\n * Because event options are passed when adding listeners, we must take case\n * to add and remove the part as a listener when the event options change.\n */\nexport type {EventPart};\nclass EventPart extends AttributePart {\n  override readonly type = EVENT_PART;\n\n  constructor(\n    element: HTMLElement,\n    name: string,\n    strings: ReadonlyArray<string>,\n    parent: Disconnectable,\n    options: RenderOptions | undefined\n  ) {\n    super(element, name, strings, parent, options);\n\n    if (DEV_MODE && this.strings !== undefined) {\n      throw new Error(\n        `A \\`<${element.localName}>\\` has a \\`@${name}=...\\` listener with ` +\n          'invalid content. Event listeners in templates must have exactly ' +\n          'one expression and no surrounding text.'\n      );\n    }\n  }\n\n  // EventPart does not use the base _$setValue/_resolveValue implementation\n  // since the dirty checking is more complex\n  /** @internal */\n  override _$setValue(\n    newListener: unknown,\n    directiveParent: DirectiveParent = this\n  ) {\n    newListener =\n      resolveDirective(this, newListener, directiveParent, 0) ?? nothing;\n    if (newListener === noChange) {\n      return;\n    }\n    const oldListener = this._$committedValue;\n\n    // If the new value is nothing or any options change we have to remove the\n    // part as a listener.\n    const shouldRemoveListener =\n      (newListener === nothing && oldListener !== nothing) ||\n      (newListener as EventListenerWithOptions).capture !==\n        (oldListener as EventListenerWithOptions).capture ||\n      (newListener as EventListenerWithOptions).once !==\n        (oldListener as EventListenerWithOptions).once ||\n      (newListener as EventListenerWithOptions).passive !==\n        (oldListener as EventListenerWithOptions).passive;\n\n    // If the new value is not nothing and we removed the listener, we have\n    // to add the part as a listener.\n    const shouldAddListener =\n      newListener !== nothing &&\n      (oldListener === nothing || shouldRemoveListener);\n\n    debugLogEvent?.({\n      kind: 'commit event listener',\n      element: this.element,\n      name: this.name,\n      value: newListener,\n      options: this.options,\n      removeListener: shouldRemoveListener,\n      addListener: shouldAddListener,\n      oldListener,\n    });\n    if (shouldRemoveListener) {\n      this.element.removeEventListener(\n        this.name,\n        this,\n        oldListener as EventListenerWithOptions\n      );\n    }\n    if (shouldAddListener) {\n      // Beware: IE11 and Chrome 41 don't like using the listener as the\n      // options object. Figure out how to deal w/ this in IE11 - maybe\n      // patch addEventListener?\n      this.element.addEventListener(\n        this.name,\n        this,\n        newListener as EventListenerWithOptions\n      );\n    }\n    this._$committedValue = newListener;\n  }\n\n  handleEvent(event: Event) {\n    if (typeof this._$committedValue === 'function') {\n      this._$committedValue.call(this.options?.host ?? this.element, event);\n    } else {\n      (this._$committedValue as EventListenerObject).handleEvent(event);\n    }\n  }\n}\n\nexport type {ElementPart};\nclass ElementPart implements Disconnectable {\n  readonly type = ELEMENT_PART;\n\n  /** @internal */\n  __directive?: Directive;\n\n  // This is to ensure that every Part has a _$committedValue\n  _$committedValue: undefined;\n\n  /** @internal */\n  _$parent!: Disconnectable;\n\n  /** @internal */\n  _$disconnectableChildren?: Set<Disconnectable> = undefined;\n\n  options: RenderOptions | undefined;\n\n  constructor(\n    public element: Element,\n    parent: Disconnectable,\n    options: RenderOptions | undefined\n  ) {\n    this._$parent = parent;\n    this.options = options;\n  }\n\n  // See comment in Disconnectable interface for why this is a getter\n  get _$isConnected() {\n    return this._$parent._$isConnected;\n  }\n\n  _$setValue(value: unknown): void {\n    debugLogEvent?.({\n      kind: 'commit to element binding',\n      element: this.element,\n      value,\n      options: this.options,\n    });\n    resolveDirective(this, value);\n  }\n}\n\n/**\n * END USERS SHOULD NOT RELY ON THIS OBJECT.\n *\n * Private exports for use by other Lit packages, not intended for use by\n * external users.\n *\n * We currently do not make a mangled rollup build of the lit-ssr code. In order\n * to keep a number of (otherwise private) top-level exports  mangled in the\n * client side code, we export a _$LH object containing those members (or\n * helper methods for accessing private fields of those members), and then\n * re-export them for use in lit-ssr. This keeps lit-ssr agnostic to whether the\n * client-side code is being used in `dev` mode or `prod` mode.\n *\n * This has a unique name, to disambiguate it from private exports in\n * lit-element, which re-exports all of lit-html.\n *\n * @private\n */\nexport const _$LH = {\n  // Used in lit-ssr\n  _boundAttributeSuffix: boundAttributeSuffix,\n  _marker: marker,\n  _markerMatch: markerMatch,\n  _HTML_RESULT: HTML_RESULT,\n  _getTemplateHtml: getTemplateHtml,\n  // Used in hydrate\n  _TemplateInstance: TemplateInstance,\n  _isIterable: isIterable,\n  _resolveDirective: resolveDirective,\n  // Used in tests and private-ssr-support\n  _ChildPart: ChildPart,\n  _AttributePart: AttributePart,\n  _BooleanAttributePart: BooleanAttributePart,\n  _EventPart: EventPart,\n  _PropertyPart: PropertyPart,\n  _ElementPart: ElementPart,\n};\n\n// Apply polyfills if available\nconst polyfillSupport = DEV_MODE\n  ? global.litHtmlPolyfillSupportDevMode\n  : global.litHtmlPolyfillSupport;\npolyfillSupport?.(Template, ChildPart);\n\n// IMPORTANT: do not change the property name or the assignment expression.\n// This line will be used in regexes to search for lit-html usage.\n(global.litHtmlVersions ??= []).push('2.4.0');\nif (DEV_MODE && global.litHtmlVersions.length > 1) {\n  issueWarning!(\n    'multiple-versions',\n    `Multiple versions of Lit loaded. ` +\n      `Loading multiple versions is not recommended.`\n  );\n}\n\n/**\n * Renders a value, usually a lit-html TemplateResult, to the container.\n *\n * This example renders the text \"Hello, Zoe!\" inside a paragraph tag, appending\n * it to the container `document.body`.\n *\n * ```js\n * import {html, render} from 'lit';\n *\n * const name = \"Zoe\";\n * render(html`<p>Hello, ${name}!</p>`, document.body);\n * ```\n *\n * @param value Any [renderable\n *   value](https://lit.dev/docs/templates/expressions/#child-expressions),\n *   typically a {@linkcode TemplateResult} created by evaluating a template tag\n *   like {@linkcode html} or {@linkcode svg}.\n * @param container A DOM container to render to. The first render will append\n *   the rendered value to the container, and subsequent renders will\n *   efficiently update the rendered value if the same result type was\n *   previously rendered there.\n * @param options See {@linkcode RenderOptions} for options documentation.\n * @see\n * {@link https://lit.dev/docs/libraries/standalone-templates/#rendering-lit-html-templates| Rendering Lit HTML Templates}\n */\nexport const render = (\n  value: unknown,\n  container: HTMLElement | DocumentFragment,\n  options?: RenderOptions\n): RootPart => {\n  if (DEV_MODE && container == null) {\n    // Give a clearer error message than\n    //     Uncaught TypeError: Cannot read properties of null (reading\n    //     '_$litPart$')\n    // which reads like an internal Lit error.\n    throw new TypeError(`The container to render into may not be ${container}`);\n  }\n  const renderId = DEV_MODE ? debugLogRenderId++ : 0;\n  const partOwnerNode = options?.renderBefore ?? container;\n  // This property needs to remain unminified.\n  // eslint-disable-next-line @typescript-eslint/no-explicit-any\n  let part: ChildPart = (partOwnerNode as any)['_$litPart$'];\n  debugLogEvent?.({\n    kind: 'begin render',\n    id: renderId,\n    value,\n    container,\n    options,\n    part,\n  });\n  if (part === undefined) {\n    const endNode = options?.renderBefore ?? null;\n    // This property needs to remain unminified.\n    // eslint-disable-next-line @typescript-eslint/no-explicit-any\n    (partOwnerNode as any)['_$litPart$'] = part = new ChildPart(\n      container.insertBefore(createMarker(), endNode),\n      endNode,\n      undefined,\n      options ?? {}\n    );\n  }\n  part._$setValue(value);\n  debugLogEvent?.({\n    kind: 'end render',\n    id: renderId,\n    value,\n    container,\n    options,\n    part,\n  });\n  return part as RootPart;\n};\n\nif (ENABLE_EXTRA_SECURITY_HOOKS) {\n  render.setSanitizer = setSanitizer;\n  render.createSanitizer = createSanitizer;\n  if (DEV_MODE) {\n    render._testOnlyClearSanitizerFactoryDoNotCallOrElse =\n      _testOnlyClearSanitizerFactoryDoNotCallOrElse;\n  }\n}\n"]}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/development/polyfill-support.js b/front_end/third_party/lit-html/package/development/polyfill-support.js
index 77521aba526adc5089fc4df1fc35ea2937863b05..11139ef48bae17e8f03e163f90b23c443dab53a8 100644
--- a/front_end/third_party/lit-html/package/development/polyfill-support.js
+++ b/front_end/third_party/lit-html/package/development/polyfill-support.js
@@ -118,7 +118,7 @@      */
     var setValue = childPartProto._$setValue;
     childPartProto._$setValue = function (value, directiveParent) {
 /**
-// scope.
+            var style = template.content.querySelector('style');
         if (directiveParent === void 0) { directiveParent = this; }
         var container = wrap(this._$startNode).parentNode;
         var scope = (_a = this.options) === null || _a === void 0 ? void 0 : _a.scope;
@@ -144,7 +144,7 @@             // Get the template for this result or create a dummy one if a result
             // is not being rendered.
             // This property needs to remain unminified.
 /**
-    // );
+            if (style !== null) {
                 ? this._$committedValue._$template.el
                 : document.createElement('template');
             prepareStyles(scope, template);
@@ -152,7 +152,7 @@             // Note, this is the temporary startNode.
             renderContainer.removeChild(renderContainerMarker);
             // When using native Shadow DOM, include prepared style in shadowRoot.
 /**
-        return name !== undefined && !styledScopes.has(name);
+                template.content.appendChild(style);
                 var style = template.content.querySelector('style');
                 if (style !== null) {
                     renderContainer.appendChild(style.cloneNode(true));




diff --git a/front_end/third_party/lit-html/package/development/polyfill-support.js.map b/front_end/third_party/lit-html/package/development/polyfill-support.js.map
index 12d7e652275942780944fb2ce8774c4fc3e42a20..2e3402f61bab35bdac3009eed5097db56074317e 100644
--- a/front_end/third_party/lit-html/package/development/polyfill-support.js.map
+++ b/front_end/third_party/lit-html/package/development/polyfill-support.js.map
@@ -1 +1 @@
-{"version":3,"file":"polyfill-support.js","sourceRoot":"","sources":["../src/polyfill-support.ts"],"names":[],"mappings":"AAAA;;;;GAIG;;AA4EH,0EAA0E;AAC1E,SAAS;AACT,IAAM,YAAY,GAAgB,IAAI,GAAG,EAAE,CAAC;AAC5C,+EAA+E;AAC/E,2CAA2C;AAC3C,IAAM,aAAa,GAA0B,IAAI,GAAG,EAAE,CAAC;AAEvD,IAAM,uBAAuB,GAAG,IAAI,CAAC;AAErC,sEAAsE;AACtE,WAAW;AACX,kCAAkC;AAClC,IAAI,QAAQ,GAAG,IAAI,CAAC;AAEpB;;;;GAIG;AACH,IAAM,eAAe,GAA+C,UAClE,QAAsC,EACtC,SAAwC;;IAExC,yEAAyE;IACzE,gEAAgE;IAChE,uDAAuD;IACvD,IACE,MAAM,CAAC,QAAQ,KAAK,SAAS;QAC7B,CAAC,MAAM,CAAC,QAAQ,CAAC,YAAY,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,SAAS,CAAC,EAC5D;QACA,OAAO;KACR;IAED,eAAe;IACf,wDAAwD;IACxD,4CAA4C;IAC5C,KAAK;IAEL,IAAM,IAAI,GACR,uBAAuB;SACvB,MAAA,MAAM,CAAC,QAAQ,0CAAE,KAAK,CAAA;QACtB,CAAA,MAAA,MAAM,CAAC,QAAQ,0CAAE,OAAO,MAAK,IAAI;QAC/B,CAAC,CAAC,MAAM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jD,IAAI,QAAQ,KAAK,SAAS,EAAE;YAC1B,aAAa,CAAC,GAAG,CACf,MAAM,CAAC,OAAO,EACd,CAAC,QAAQ,GAAG,IAAI,QAAQ,CAAC,MAAM,EAAE,IAAI,CAAC,OAAO,CAAC,CAAC,CAChD,CAAC;SACH;QACD,OAAO,QAAQ,CAAC;IAClB,CAAC,CAAC;AACJ,CAAC,CAAC;AAEF,IAAI,uBAAuB,EAAE;IAC3B,eAAe,CAAC,gBAAgB,GAAG,uBAAuB,CAAC;CAC5D;AAED,IAAI,QAAQ,EAAE;IACZ,MAAA,UAAU,CAAC,6BAA6B,oCAAxC,UAAU,CAAC,6BAA6B,GAAK,eAAe,EAAC;CAC9D;KAAM;IACL,MAAA,UAAU,CAAC,sBAAsB,oCAAjC,UAAU,CAAC,sBAAsB,GAAK,eAAe,EAAC;CACvD","sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n/**\n * lit-html patch to support browsers without native web components.\n *\n * This module should be used in addition to loading the web components\n * polyfills via @webcomponents/webcomponentjs. When using those polyfills\n * support for polyfilled Shadow DOM is automatic via the ShadyDOM polyfill.\n * Scoping classes are added to DOM nodes to facilitate CSS scoping that\n * simulates the style scoping Shadow DOM provides. ShadyDOM does this scoping\n * to all elements added to the DOM. This module provides an important\n * optimization for this process by pre-scoping lit-html template\n * DOM. This means ShadyDOM does not have to scope each instance of the\n * template DOM. Instead, each template is scoped only once.\n *\n * Creating scoped CSS is not covered by this module. It is, however, integrated\n * into the lit-element and @lit/reactive-element packages. See the ShadyCSS docs\n * for how to apply scoping to CSS:\n * https://github.com/webcomponents/polyfills/tree/master/packages/shadycss#usage.\n *\n * @packageDocumentation\n */\n\nexport {};\n\ninterface RenderOptions {\n  readonly renderBefore?: ChildNode | null;\n  scope?: string;\n}\n\ninterface ShadyTemplateResult {\n  strings: TemplateStringsArray;\n  // This property needs to remain unminified.\n  ['_$litType$']?: string;\n}\n\n// Note, this is a dummy type as the full type here is big.\ninterface Directive {\n  __directive?: Directive;\n}\n\ninterface DirectiveParent {\n  _$parent?: DirectiveParent;\n  __directive?: Directive;\n  __directives?: Array<Directive | undefined>;\n}\n\ninterface PatchableChildPartConstructor {\n  // eslint-disable-next-line @typescript-eslint/no-explicit-any, @typescript-eslint/no-misused-new\n  new (...args: any[]): PatchableChildPart;\n}\n\ninterface PatchableChildPart {\n  __directive?: Directive;\n  _$committedValue: unknown;\n  _$startNode: ChildNode;\n  _$endNode: ChildNode | null;\n  options: RenderOptions;\n  _$setValue(value: unknown, directiveParent: DirectiveParent): void;\n  _$getTemplate(result: ShadyTemplateResult): HTMLTemplateElement;\n}\n\ninterface PatchableTemplate {\n  el: HTMLTemplateElement;\n}\n\ninterface PatchableTemplateConstructor {\n  // eslint-disable-next-line @typescript-eslint/no-explicit-any, @typescript-eslint/no-misused-new\n  new (...args: any[]): PatchableTemplate;\n  createElement(html: string, options?: RenderOptions): HTMLTemplateElement;\n}\n\ninterface PatchableTemplateInstance {\n  _$template: PatchableTemplate;\n}\n\n// Scopes that have had styling prepared. Note, must only be done once per\n// scope.\nconst styledScopes: Set<string> = new Set();\n// Map of css per scope. This is collected during first scope render, used when\n// styling is prepared, and then discarded.\nconst scopeCssStore: Map<string, string[]> = new Map();\n\nconst ENABLE_SHADYDOM_NOPATCH = true;\n\n// Note, explicitly use `var` here so that this can be re-defined when\n// bundled.\n// eslint-disable-next-line no-var\nvar DEV_MODE = true;\n\n/**\n * lit-html patches. These properties cannot be renamed.\n * * ChildPart.prototype._$getTemplate\n * * ChildPart.prototype._$setValue\n */\nconst polyfillSupport: NonNullable<typeof litHtmlPolyfillSupport> = (\n  Template: PatchableTemplateConstructor,\n  ChildPart: PatchableChildPartConstructor\n) => {\n  // polyfill-support is only needed if ShadyCSS or the ApplyShim is in use\n  // We test at the point of patching, which makes it safe to load\n  // webcomponentsjs and polyfill-support in either order\n  if (\n    window.ShadyCSS === undefined ||\n    (window.ShadyCSS.nativeShadow && !window.ShadyCSS.ApplyShim)\n  ) {\n    return;\n  }\n\n  // console.log(\n  //   '%c Making lit-html compatible with ShadyDOM/CSS.',\n  //   'color: lightgreen; font-style: italic'\n  // );\n\n  const wrap =\n    ENABLE_SHADYDOM_NOPATCH &&\n    window.ShadyDOM?.inUse &&\n    window.ShadyDOM?.noPatch === true\n      ? window.ShadyDOM!.wrap\n      : (node: Node) => node;\n\n  const needsPrepareStyles = (name: string | undefined) =>\n    name !== undefined && !styledScopes.has(name);\n\n  const cssForScope = (name: string) => {\n    let scopeCss = scopeCssStore.get(name);\n    if (scopeCss === undefined) {\n      scopeCssStore.set(name, (scopeCss = []));\n    }\n    return scopeCss;\n  };\n\n  const prepareStyles = (name: string, template: HTMLTemplateElement) => {\n    // Get styles\n    const scopeCss = cssForScope(name);\n    const hasScopeCss = scopeCss.length !== 0;\n    if (hasScopeCss) {\n      const style = document.createElement('style');\n      style.textContent = scopeCss.join('\\n');\n      // Note, it's important to add the style to the *end* of the template so\n      // it doesn't mess up part indices.\n      template.content.appendChild(style);\n    }\n    // Mark this scope as styled.\n    styledScopes.add(name);\n    // Remove stored data since it's no longer needed.\n    scopeCssStore.delete(name);\n    // ShadyCSS removes scopes and removes the style under ShadyDOM and leaves\n    // it under native Shadow DOM\n    window.ShadyCSS!.prepareTemplateStyles(template, name);\n    // Note, under native Shadow DOM, the style is added to the beginning of the\n    // template. It must be moved to the *end* of the template so it doesn't\n    // mess up part indices.\n    if (hasScopeCss && window.ShadyCSS!.nativeShadow) {\n      // If there were styles but the CSS text was empty, ShadyCSS will\n      // eliminate the style altogether, so the style here could be null\n      const style = template.content.querySelector('style');\n      if (style !== null) {\n        template.content.appendChild(style);\n      }\n    }\n  };\n\n  const scopedTemplateCache = new Map<\n    string | undefined,\n    Map<TemplateStringsArray, PatchableTemplate>\n  >();\n\n  /**\n   * Override to extract style elements from the template\n   * and store all style.textContent in the shady scope data.\n   * Note, it's ok to patch Template since it's only used via ChildPart.\n   */\n  const originalCreateElement = Template.createElement;\n  Template.createElement = function (html: string, options?: RenderOptions) {\n    const element = originalCreateElement.call(Template, html, options);\n    const scope = options?.scope;\n    if (scope !== undefined) {\n      if (!window.ShadyCSS!.nativeShadow) {\n        window.ShadyCSS!.prepareTemplateDom(element, scope);\n      }\n      // Process styles only if this scope is being prepared. Otherwise,\n      // leave styles as is for back compat with Lit1.\n      if (needsPrepareStyles(scope)) {\n        const scopeCss = cssForScope(scope);\n        // Remove styles and store textContent.\n        const styles = element.content.querySelectorAll(\n          'style'\n        ) as NodeListOf<HTMLStyleElement>;\n        // Store the css in this template in the scope css and remove the <style>\n        // from the template _before_ the node-walk captures part indices\n        scopeCss.push(\n          ...Array.from(styles).map((style) => {\n            style.parentNode?.removeChild(style);\n            return style.textContent!;\n          })\n        );\n      }\n    }\n    return element;\n  };\n\n  const renderContainer = document.createDocumentFragment();\n  const renderContainerMarker = document.createComment('');\n\n  const childPartProto = ChildPart.prototype;\n  /**\n   * Patch to apply gathered css via ShadyCSS. This is done only once per scope.\n   */\n  const setValue = childPartProto._$setValue;\n  childPartProto._$setValue = function (\n    this: PatchableChildPart,\n    value: unknown,\n    directiveParent: DirectiveParent = this\n  ) {\n    const container = wrap(this._$startNode).parentNode!;\n    const scope = this.options?.scope;\n    if (container instanceof ShadowRoot && needsPrepareStyles(scope)) {\n      // Note, @apply requires outer => inner scope rendering on initial\n      // scope renders to apply property values correctly. Style preparation\n      // is tied to rendering into `shadowRoot`'s and this is typically done by\n      // custom elements. If this is done in `connectedCallback`, as is typical,\n      // the code below ensures the right order since content is rendered\n      // into a fragment first so the hosting element can prepare styles first.\n      // If rendering is done in the constructor, this won't work, but that's\n      // not supported in ShadyDOM anyway.\n      const startNode = this._$startNode;\n      const endNode = this._$endNode;\n\n      // Temporarily move this part into the renderContainer.\n      renderContainer.appendChild(renderContainerMarker);\n      this._$startNode = renderContainerMarker;\n      this._$endNode = null;\n\n      // Note, any nested template results render here and their styles will\n      // be extracted and collected.\n      setValue.call(this, value, directiveParent);\n\n      // Get the template for this result or create a dummy one if a result\n      // is not being rendered.\n      // This property needs to remain unminified.\n      const template = (value as ShadyTemplateResult)?.['_$litType$']\n        ? (this._$committedValue as PatchableTemplateInstance)._$template.el\n        : document.createElement('template');\n      prepareStyles(scope!, template);\n\n      // Note, this is the temporary startNode.\n      renderContainer.removeChild(renderContainerMarker);\n      // When using native Shadow DOM, include prepared style in shadowRoot.\n      if (window.ShadyCSS?.nativeShadow) {\n        const style = template.content.querySelector('style');\n        if (style !== null) {\n          renderContainer.appendChild(style.cloneNode(true));\n        }\n      }\n      container.insertBefore(renderContainer, endNode);\n      // Move part back to original container.\n      this._$startNode = startNode;\n      this._$endNode = endNode;\n    } else {\n      setValue.call(this, value, directiveParent);\n    }\n  };\n\n  /**\n   * Patch ChildPart._$getTemplate to look up templates in a cache bucketed\n   * by element name.\n   */\n  childPartProto._$getTemplate = function (\n    this: PatchableChildPart,\n    result: ShadyTemplateResult\n  ) {\n    const scope = this.options?.scope;\n    let templateCache = scopedTemplateCache.get(scope);\n    if (templateCache === undefined) {\n      scopedTemplateCache.set(scope, (templateCache = new Map()));\n    }\n    let template = templateCache.get(result.strings);\n    if (template === undefined) {\n      templateCache.set(\n        result.strings,\n        (template = new Template(result, this.options))\n      );\n    }\n    return template;\n  };\n};\n\nif (ENABLE_SHADYDOM_NOPATCH) {\n  polyfillSupport.noPatchSupported = ENABLE_SHADYDOM_NOPATCH;\n}\n\nif (DEV_MODE) {\n  globalThis.litHtmlPolyfillSupportDevMode ??= polyfillSupport;\n} else {\n  globalThis.litHtmlPolyfillSupport ??= polyfillSupport;\n}\n"]}
\ No newline at end of file
+{"version":3,"file":"polyfill-support.js","sourceRoot":"","sources":["../src/polyfill-support.ts"],"names":[],"mappings":"AAAA;;;;GAIG;;AA4EH,0EAA0E;AAC1E,SAAS;AACT,IAAM,YAAY,GAAgB,IAAI,GAAG,EAAE,CAAC;AAC5C,+EAA+E;AAC/E,2CAA2C;AAC3C,IAAM,aAAa,GAA0B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identifier: BSD-3-Clause\n */\n\n/**\n * lit-html patch to support browsers without native web components.\n *\n * This module should be used in addition to loading the web components\n * polyfills via @webcomponents/webcomponentjs. When using those polyfills\n * support for polyfilled Shadow DOM is automatic via the ShadyDOM polyfill.\n * Scoping classes are added to DOM nodes to facilitate CSS scoping that\n * simulates the style scoping Shadow DOM provides. ShadyDOM does this scoping\n * to all elements added to the DOM. This module provides an important\n * optimization for this process by pre-scoping lit-html template\n * DOM. This means ShadyDOM does not have to scope each instance of the\n * template DOM. Instead, each template is scoped only once.\n *\n * Creating scoped CSS is not covered by this module. It is, however, integrated\n * into the lit-element and @lit/reactive-element packages. See the ShadyCSS docs\n * for how to apply scoping to CSS:\n * https://github.com/webcomponents/polyfills/tree/master/packages/shadycss#usage.\n *\n * @packageDocumentation\n */\n\nexport {};\n\ninterface RenderOptions {\n  readonly renderBefore?: ChildNode | null;\n  scope?: string;\n}\n\ninterface ShadyTemplateResult {\n  strings: TemplateStringsArray;\n  // This property needs to remain unminified.\n  ['_$litType$']?: string;\n}\n\n// Note, this is a dummy type as the full type here is big.\ninterface Directive {\n  __directive?: Directive;\n}\n\ninterface DirectiveParent {\n  _$parent?: DirectiveParent;\n  __directive?: Directive;\n  __directives?: Array<Directive | undefined>;\n}\n\ninterface PatchableChildPartConstructor {\n  // eslint-disable-next-line @typescript-eslint/no-explicit-any, @typescript-eslint/no-misused-new\n  new (...args: any[]): PatchableChildPart;\n}\n\ninterface PatchableChildPart {\n  __directive?: Directive;\n  _$committedValue: unknown;\n  _$startNode: ChildNode;\n  _$endNode: ChildNode | null;\n  options: RenderOptions;\n  _$setValue(value: unknown, directiveParent: DirectiveParent): void;\n  _$getTemplate(result: ShadyTemplateResult): HTMLTemplateElement;\n}\n\ninterface PatchableTemplate {\n  el: HTMLTemplateElement;\n}\n\ninterface PatchableTemplateConstructor {\n  // eslint-disable-next-line @typescript-eslint/no-explicit-any, @typescript-eslint/no-misused-new\n  new (...args: any[]): PatchableTemplate;\n  createElement(html: string, options?: RenderOptions): HTMLTemplateElement;\n}\n\ninterface PatchableTemplateInstance {\n  _$template: PatchableTemplate;\n}\n\n// Scopes that have had styling prepared. Note, must only be done once per\n// scope.\nconst styledScopes: Set<string> = new Set();\n// Map of css per scope. This is collected during first scope render, used when\n// styling is prepared, and then discarded.\nconst scopeCssStore: Map<string, string[]> = new Map();\n\nconst ENABLE_SHADYDOM_NOPATCH = true;\n\n// Note, explicitly use `var` here so that this can be re-defined when\n// bundled.\n// eslint-disable-next-line no-var\nvar DEV_MODE = true;\n\n/**\n * lit-html patches. These properties cannot be renamed.\n * * ChildPart.prototype._$getTemplate\n * * ChildPart.prototype._$setValue\n */\nconst polyfillSupport: NonNullable<typeof litHtmlPolyfillSupport> = (\n  Template: PatchableTemplateConstructor,\n  ChildPart: PatchableChildPartConstructor\n) => {\n  // polyfill-support is only needed if ShadyCSS or the ApplyShim is in use\n  // We test at the point of patching, which makes it safe to load\n  // webcomponentsjs and polyfill-support in either order\n  if (\n    window.ShadyCSS === undefined ||\n    (window.ShadyCSS.nativeShadow && !window.ShadyCSS.ApplyShim)\n  ) {\n    return;\n  }\n\n  // console.log(\n  //   '%c Making lit-html compatible with ShadyDOM/CSS.',\n  //   'color: lightgreen; font-style: italic'\n  // );\n\n  const wrap =\n    ENABLE_SHADYDOM_NOPATCH &&\n    window.ShadyDOM?.inUse &&\n    window.ShadyDOM?.noPatch === true\n      ? window.ShadyDOM!.wrap\n      : (node: Node) => node;\n\n  const needsPrepareStyles = (name: string | undefined) =>\n    name !== undefined && !styledScopes.has(name);\n\n  const cssForScope = (name: string) => {\n    let scopeCss = scopeCssStore.get(name);\n    if (scopeCss === undefined) {\n      scopeCssStore.set(name, (scopeCss = []));\n    }\n    return scopeCss;\n  };\n\n  const prepareStyles = (name: string, template: HTMLTemplateElement) => {\n    // Get styles\n    const scopeCss = cssForScope(name);\n    const hasScopeCss = scopeCss.length !== 0;\n    if (hasScopeCss) {\n      const style = document.createElement('style');\n      style.textContent = scopeCss.join('\\n');\n      // Note, it's important to add the style to the *end* of the template so\n      // it doesn't mess up part indices.\n      template.content.appendChild(style);\n    }\n    // Mark this scope as styled.\n    styledScopes.add(name);\n    // Remove stored data since it's no longer needed.\n    scopeCssStore.delete(name);\n    // ShadyCSS removes scopes and removes the style under ShadyDOM and leaves\n    // it under native Shadow DOM\n    window.ShadyCSS!.prepareTemplateStyles(template, name);\n    // Note, under native Shadow DOM, the style is added to the beginning of the\n    // template. It must be moved to the *end* of the template so it doesn't\n    // mess up part indices.\n    if (hasScopeCss && window.ShadyCSS!.nativeShadow) {\n      // If there were styles but the CSS text was empty, ShadyCSS will\n      // eliminate the style altogether, so the style here could be null\n      const style = template.content.querySelector('style');\n      if (style !== null) {\n        template.content.appendChild(style);\n      }\n    }\n  };\n\n  const scopedTemplateCache = new Map<\n    string | undefined,\n    Map<TemplateStringsArray, PatchableTemplate>\n  >();\n\n  /**\n   * Override to extract style elements from the template\n   * and store all style.textContent in the shady scope data.\n   * Note, it's ok to patch Template since it's only used via ChildPart.\n   */\n  const originalCreateElement = Template.createElement;\n  Template.createElement = function (html: string, options?: RenderOptions) {\n    const element = originalCreateElement.call(Template, html, options);\n    const scope = options?.scope;\n    if (scope !== undefined) {\n      if (!window.ShadyCSS!.nativeShadow) {\n        window.ShadyCSS!.prepareTemplateDom(element, scope);\n      }\n      // Process styles only if this scope is being prepared. Otherwise,\n      // leave styles as is for back compat with Lit1.\n      if (needsPrepareStyles(scope)) {\n        const scopeCss = cssForScope(scope);\n        // Remove styles and store textContent.\n        const styles = element.content.querySelectorAll(\n          'style'\n        ) as NodeListOf<HTMLStyleElement>;\n        // Store the css in this template in the scope css and remove the <style>\n        // from the template _before_ the node-walk captures part indices\n        scopeCss.push(\n          ...Array.from(styles).map((style) => {\n            style.parentNode?.removeChild(style);\n            return style.textContent!;\n          })\n        );\n      }\n    }\n    return element;\n  };\n\n  const renderContainer = document.createDocumentFragment();\n  const renderContainerMarker = document.createComment('');\n\n  const childPartProto = ChildPart.prototype;\n  /**\n   * Patch to apply gathered css via ShadyCSS. This is done only once per scope.\n   */\n  const setValue = childPartProto._$setValue;\n  childPartProto._$setValue = function (\n    this: PatchableChildPart,\n    value: unknown,\n    directiveParent: DirectiveParent = this\n  ) {\n    const container = wrap(this._$startNode).parentNode!;\n    const scope = this.options?.scope;\n    if (container instanceof ShadowRoot && needsPrepareStyles(scope)) {\n      // Note, @apply requires outer => inner scope rendering on initial\n      // scope renders to apply property values correctly. Style preparation\n      // is tied to rendering into `shadowRoot`'s and this is typically done by\n      // custom elements. If this is done in `connectedCallback`, as is typical,\n      // the code below ensures the right order since content is rendered\n      // into a fragment first so the hosting element can prepare styles first.\n      // If rendering is done in the constructor, this won't work, but that's\n      // not supported in ShadyDOM anyway.\n      const startNode = this._$startNode;\n      const endNode = this._$endNode;\n\n      // Temporarily move this part into the renderContainer.\n      renderContainer.appendChild(renderContainerMarker);\n      this._$startNode = renderContainerMarker;\n      this._$endNode = null;\n\n      // Note, any nested template results render here and their styles will\n      // be extracted and collected.\n      setValue.call(this, value, directiveParent);\n\n      // Get the template for this result or create a dummy one if a result\n      // is not being rendered.\n      // This property needs to remain unminified.\n      const template = (value as ShadyTemplateResult)?.['_$litType$']\n        ? (this._$committedValue as PatchableTemplateInstance)._$template.el\n        : document.createElement('template');\n      prepareStyles(scope!, template);\n\n      // Note, this is the temporary startNode.\n      renderContainer.removeChild(renderContainerMarker);\n      // When using native Shadow DOM, include prepared style in shadowRoot.\n      if (window.ShadyCSS?.nativeShadow) {\n        const style = template.content.querySelector('style');\n        if (style !== null) {\n          renderContainer.appendChild(style.cloneNode(true));\n        }\n      }\n      container.insertBefore(renderContainer, endNode);\n      // Move part back to original container.\n      this._$startNode = startNode;\n      this._$endNode = endNode;\n    } else {\n      setValue.call(this, value, directiveParent);\n    }\n  };\n\n  /**\n   * Patch ChildPart._$getTemplate to look up templates in a cache bucketed\n   * by element name.\n   */\n  childPartProto._$getTemplate = function (\n    this: PatchableChildPart,\n    result: ShadyTemplateResult\n  ) {\n    const scope = this.options?.scope;\n    let templateCache = scopedTemplateCache.get(scope);\n    if (templateCache === undefined) {\n      scopedTemplateCache.set(scope, (templateCache = new Map()));\n    }\n    let template = templateCache.get(result.strings);\n    if (template === undefined) {\n      templateCache.set(\n        result.strings,\n        (template = new Template(result, this.options))\n      );\n    }\n    return template;\n  };\n};\n\nif (ENABLE_SHADYDOM_NOPATCH) {\n  polyfillSupport.noPatchSupported = ENABLE_SHADYDOM_NOPATCH;\n}\n\nif (DEV_MODE) {\n  globalThis.litHtmlPolyfillSupportDevMode ??= polyfillSupport;\n} else {\n  globalThis.litHtmlPolyfillSupport ??= polyfillSupport;\n}\n"]}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/development/private-ssr-support.d.ts b/front_end/third_party/lit-html/package/development/private-ssr-support.d.ts
index 7f05335becf6ca8b86af3b8fc9d6fe46384e3bc8..c781687efec0eac385852a866d086c90876c38a5 100644
--- a/front_end/third_party/lit-html/package/development/private-ssr-support.d.ts
+++ b/front_end/third_party/lit-html/package/development/private-ssr-support.d.ts
@@ -22,8 +22,8 @@     boundAttributeSuffix: string;
     marker: string;
     markerMatch: string;
     HTML_RESULT: number;
+ */
  * @license
- * Copyright 2019 Google LLC
     overrideDirectiveResolve: (directiveClass: new (part: PartInfo) => Directive & {
         render(): unknown;
     }, resolveOverrideFn: (directive: Directive, values: unknown[]) => unknown) => {
@@ -43,7 +43,7 @@         };
     };
     setDirectiveClass(value: DirectiveResult, directiveClass: DirectiveClass): void;
     getAttributePartCommittedValue: (part: AttributePart, value: unknown, index: number | undefined) => unknown;
- * SPDX-License-Identifier: BSD-3-Clause
+ */
  * Copyright 2019 Google LLC
     resolveDirective: (part: import("./lit-html.js").ChildPart | AttributePart | import("./lit-html.js").ElementPart, value: unknown, parent?: import("./lit-html.js").DirectiveParent, attributeIndex?: number | undefined) => unknown;
     AttributePart: typeof AttributePart;




diff --git a/front_end/third_party/lit-html/package/development/private-ssr-support.d.ts.map b/front_end/third_party/lit-html/package/development/private-ssr-support.d.ts.map
index 4f3d848609fdb23d0eb9af41bc154218075fe735..8fa45a29f67b6e8b44c0454bb263bdefa4e96154 100644
--- a/front_end/third_party/lit-html/package/development/private-ssr-support.d.ts.map
+++ b/front_end/third_party/lit-html/package/development/private-ssr-support.d.ts.map
@@ -1 +1 @@
-{"version":3,"file":"private-ssr-support.d.ts","sourceRoot":"","sources":["../src/private-ssr-support.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EACL,SAAS,EACT,QAAQ,EACR,cAAc,EACd,eAAe,EAChB,MAAM,gBAAgB,CAAC;AACxB,OAAO,EAEL,aAAa,EAEb,IAAI,EACJ,cAAc,EACf,MAAM,eAAe,CAAC;AACvB,YAAY,EAAC,QAAQ,EAAC,MAAM,eAAe,CAAC;AAE5C;;;;;;;;;;GAUG;AACH,eAAO,MAAM,IAAI;;;;;;0DAOc,QAAQ,KAAK,SAAS,GAAG;QAAC,MAAM,IAAI,OAAO,CAAA;KAAC,iCACxC,SAAS,UAAU,OAAO,EAAE,KAAK,OAAO;mBAD5C,QAAQ;4BAKzB,SAAS,SACR,IAAI,UACH,OAAO,EAAE,GAChB,OAAO;;;;;;;;;gEARmD,OAAO;;;;6BAY/C,eAAe,kBAAkB,cAAc;2CAKhE,aAAa,SACZ,OAAO,SACP,MAAM,GAAG,SAAS;6DAYgB,cAAc;;;;;;;CAU1D,CAAC"}
\ No newline at end of file
+{"version":3,"file":"private-ssr-support.d.ts","sourceRoot":"","sources":["../src/private-ssr-support.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EACL,SAAS,EACT,QAAQ,EACR,cAAc,EACd,eAAe,EAChB,MAAM,gBAAgB,CAAC;AACxB,OAAO,EAEL,aAAa,EAEb,IAAI,EACJ,cAAc,EACf,MAAM,eAAe,CAAC;AACvB,YAAY,EAAC,QAAQ,EAAC,MAAM,eAAe,CAAC;AAE5C;;;;;;;;;;GAUG;AACH,eAAO,MAAM,IAAI;;;;;;0DAOc,QAAQ,KAAK,SAAS,GAAG;QAAC,MAAM,IAAI,OAAO,CAAA;KAAC,iCACxC,SAAS,UAAU,OAAO,EAAE,KAAK,OAAO;mBAD5C,QAAQ;4BAKzB,SAAS,SACR,IAAI,UACH,OAAO,EAAE,GAChB,OAAO;;;;;;;;;gEARmD,OAAO;;;;6BAY/C,eAAe,kBAAkB,cAAc;2CAKhE,aAAa,SACZ,OAAO,SACP,MAAM,GAAG,SAAS;sCAYO,MAAM,KAAG,cAAc;;;;;;;CAU1D,CAAC"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/development/static.d.ts b/front_end/third_party/lit-html/package/development/static.d.ts
index ab33a1c151956f0b4d5045ba0eb6cb020e73a50e..6987051bf977b736fbd7f5f99e8e4625e01f2e2b 100644
--- a/front_end/third_party/lit-html/package/development/static.d.ts
+++ b/front_end/third_party/lit-html/package/development/static.d.ts
@@ -4,6 +4,32 @@  * Copyright 2020 Google LLC
  * SPDX-License-Identifier: BSD-3-Clause
  */
 import { html as coreHtml, svg as coreSvg, TemplateResult } from './lit-html.js';
+export interface StaticValue {
+    /** The value to interpolate as-is into the template. */
+    _$litStatic$: string;
+    /**
+     * A value that can't be decoded from ordinary JSON, make it harder for
+     * a attacker-controlled data that goes through JSON.parse to produce a valid
+     * StaticValue.
+     */
+    r: typeof brand;
+}
+/**
+ * Prevents JSON injection attacks.
+ *
+ * The goals of this brand:
+ *   1) fast to check
+ *   2) code is small on the wire
+ *   3) multiple versions of Lit in a single page will all produce mutually
+ *      interoperable StaticValues
+ *   4) normal JSON.parse (without an unusual reviver) can not produce a
+ *      StaticValue
+ *
+ * Symbols satisfy (1), (2), and (4). We use Symbol.for to satisfy (3), but
+ * we don't care about the key, so we break ties via (2) and use the empty
+ * string.
+ */
+declare const brand: unique symbol;
 /**
  * Wraps a string so that it behaves like part of the static template
  * strings instead of a dynamic value.
@@ -18,10 +44,8 @@  *
  * Static values can be changed, but they will cause a complete re-render
  * since they effectively create a new template.
  */
-export declare const unsafeStatic: (value: string) => {
-/**
+ */
  * strings instead of a dynamic value.
-};
 /**
  * Tags a string literal so that it behaves like part of the static template
  * strings instead of a dynamic value.
@@ -36,9 +60,7 @@  *
  * Static values can be changed, but they will cause a complete re-render since
  * they effectively create a new template.
  */
-export declare const literal: (strings: TemplateStringsArray, ...values: unknown[]) => {
-    _$litStatic$: unknown;
-/**
+ */
  *
 /**
  * Wraps a lit-html template tag (`html` or `svg`) to add static value support.
@@ -58,4 +80,5 @@  *
  * Includes static value support from `lit-html/static.js`.
  */
 export declare const svg: (strings: TemplateStringsArray, ...values: unknown[]) => TemplateResult;
+export {};
 //# sourceMappingURL=static.d.ts.map
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/development/static.d.ts.map b/front_end/third_party/lit-html/package/development/static.d.ts.map
index 2208152802c19f26f1791ebeb5238ace1b9d7a9c..6fd5b7f937e80ed6b09388df3a66eeeff5a36d52 100644
--- a/front_end/third_party/lit-html/package/development/static.d.ts.map
+++ b/front_end/third_party/lit-html/package/development/static.d.ts.map
@@ -1 +1 @@
-{"version":3,"file":"static.d.ts","sourceRoot":"","sources":["../src/static.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAKH,OAAO,EAAC,IAAI,IAAI,QAAQ,EAAE,GAAG,IAAI,OAAO,EAAE,cAAc,EAAC,MAAM,eAAe,CAAC;AAE/E;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,YAAY,UAAW,MAAM;;CAExC,CAAC;AAaH;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,OAAO,YACT,oBAAoB,aAClB,OAAO,EAAE;;CAMpB,CAAC;AAMH;;GAEG;AACH,eAAO,MAAM,UAAU,YACX,eAAe,GAAG,cAAc,eAChC,oBAAoB,aAAa,OAAO,EAAE,KAAG,cAmDtD,CAAC;AAEJ;;;;;GAKG;AACH,eAAO,MAAM,IAAI,YA3DL,oBAAoB,aAAa,OAAO,EAAE,KAAG,cA2DjB,CAAC;AAEzC;;;;;GAKG;AACH,eAAO,MAAM,GAAG,YAnEJ,oBAAoB,aAAa,OAAO,EAAE,KAAG,cAmEnB,CAAC"}
\ No newline at end of file
+{"version":3,"file":"static.d.ts","sourceRoot":"","sources":["../src/static.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAKH,OAAO,EAAC,IAAI,IAAI,QAAQ,EAAE,GAAG,IAAI,OAAO,EAAE,cAAc,EAAC,MAAM,eAAe,CAAC;AAE/E,MAAM,WAAW,WAAW;IAC1B,wDAAwD;IACxD,YAAY,EAAE,MAAM,CAAC;IAErB;;;;OAIG;IACH,CAAC,EAAE,OAAO,KAAK,CAAC;CACjB;AAED;;;;;;;;;;;;;;GAcG;AACH,QAAA,MAAM,KAAK,eAAiB,CAAC;AAU7B;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,YAAY,UAAW,MAAM,KAAG,WAG3C,CAAC;AAaH;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,OAAO,YACT,oBAAoB,aAClB,OAAO,EAAE,KACnB,WAMD,CAAC;AAIH;;GAEG;AACH,eAAO,MAAM,UAAU,YACX,eAAe,GAAG,cAAc,eAChC,oBAAoB,aAAa,OAAO,EAAE,KAAG,cAkDtD,CAAC;AAEJ;;;;;GAKG;AACH,eAAO,MAAM,IAAI,YA1DL,oBAAoB,aAAa,OAAO,EAAE,KAAG,cA0DjB,CAAC;AAEzC;;;;;GAKG;AACH,eAAO,MAAM,GAAG,YAlEJ,oBAAoB,aAAa,OAAO,EAAE,KAAG,cAkEnB,CAAC"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/development/static.js b/front_end/third_party/lit-html/package/development/static.js
index 22ab73fb1cad65be9558ae9655ca7440e94dafcc..9223a7330ea71512e72583109a8c01593e464adb 100644
--- a/front_end/third_party/lit-html/package/development/static.js
+++ b/front_end/third_party/lit-html/package/development/static.js
@@ -7,6 +7,29 @@ // Any new exports need to be added to the export statement in
 // `packages/lit/src/index.all.ts`.
 import { html as coreHtml, svg as coreSvg } from './lit-html.js';
 /**
+ * Prevents JSON injection attacks.
+ *
+ * The goals of this brand:
+ *   1) fast to check
+ *   2) code is small on the wire
+ *   3) multiple versions of Lit in a single page will all produce mutually
+ *      interoperable StaticValues
+ *   4) normal JSON.parse (without an unusual reviver) can not produce a
+ *      StaticValue
+ *
+ * Symbols satisfy (1), (2), and (4). We use Symbol.for to satisfy (3), but
+ * we don't care about the key, so we break ties via (2) and use the empty
+ * string.
+ */
+const brand = Symbol.for('');
+/** Safely extracts the string part of a StaticValue. */
+const unwrapStaticValue = (value) => {
+    if ((value === null || value === void 0 ? void 0 : value.r) !== brand) {
+        return undefined;
+    }
+    return value === null || value === void 0 ? void 0 : value['_$litStatic$'];
+};
+/**
  * Wraps a string so that it behaves like part of the static template
  * strings instead of a dynamic value.
  *
@@ -22,6 +45,7 @@  * since they effectively create a new template.
  */
 export const unsafeStatic = (value) => ({
     ['_$litStatic$']: value,
+    r: brand,
 });
 const textFromStatic = (value) => {
     if (value['_$litStatic$'] !== undefined) {
@@ -48,6 +72,7 @@  * they effectively create a new template.
  */
 export const literal = (strings, ...values) => ({
     ['_$litStatic$']: values.reduce((acc, v, idx) => acc + textFromStatic(v) + strings[idx + 1], strings[0]),
+    r: brand,
 });
 const stringsCache = new Map();
 /**
@@ -55,8 +80,6 @@  * Wraps a lit-html template tag (`html` or `svg`) to add static value support.
  */
 export const withStatic = (coreTag) => (strings, ...values) => {
  * SPDX-License-Identifier: BSD-3-Clause
-/**
- * SPDX-License-Identifier: BSD-3-Clause
  * @license
     let staticValue;
     let dynamicValue;
@@ -72,8 +95,7 @@         // so that we treat a run of template strings and unsafe static values as
         // a single template string.
         while (i < l &&
             ((dynamicValue = values[i]),
-                (staticValue = (_a = dynamicValue) === null || _a === void 0 ? void 0 : _a['_$litStatic$'])) !==
-                undefined) {
+                (staticValue = unwrapStaticValue(dynamicValue))) !== undefined) {
             s += staticValue + strings[++i];
             hasStatics = true;
         }




diff --git a/front_end/third_party/lit-html/package/development/static.js.map b/front_end/third_party/lit-html/package/development/static.js.map
index e3e000219bdf210cc3d6b192400bd8e8ace43107..e5bc46ed729bdecb7b0235e06ec657aeb4359682 100644
--- a/front_end/third_party/lit-html/package/development/static.js.map
+++ b/front_end/third_party/lit-html/package/development/static.js.map
@@ -1 +1 @@
-{"version":3,"file":"static.js","sourceRoot":"","sources":["../src/static.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,8DAA8D;AAC9D,mCAAmC;AAEnC,OAAO,EAAC,IAAI,IAAI,QAAQ,EAAE,GAAG,IAAI,OAAO,EAAiB,MAAM,eAAe,CAAC;AAE/E;;;;;;;;;;;;;GAaG;AACH,MAAM,CAAC,MAAM,YAAY,GAAG,CAAC,KAAa,EAAE,EAAE,CAAC,CAAC;IAC9C,CAAC,cAAc,CAAC,EAAE,KAAK;CACxB,CAAC,CAAC;AAEH,MAAM,cAAc,GAAG,CAAC,KAAkB,EAAE,EAAE;IAC5C,IAAI,KAAK,CAAC,cAAc,CAAC,KAAK,SAAS,EAAE;QACvC,OAAO,KAAK,CAAC,cAAc,CAAC,CAAC;KAC9B;SAAM;QACL,MAAM,IAAI,KAAK,CACb,kEAAkE,KAAK;+CAC9B,CAC1C,CAAC;KACH;AACH,CAAC,CAAC;AAEF;;;;;;;;;;;;;GAaG;AACH,MAAM,CAAC,MAAM,OAAO,GAAG,CACrB,OAA6B,EAC7B,GAAG,MAAiB,EACpB,EAAE,CAAC,CAAC;IACJ,CAAC,cAAc,CAAC,EAAE,MAAM,CAAC,MAAM,CAC7B,CAAC,GAAG,EAAE,CAAC,EAAE,GAAG,EAAE,EAAE,CAAC,GAAG,GAAG,cAAc,CAAC,CAAgB,CAAC,GAAG,OAAO,CAAC,GAAG,GAAG,CAAC,CAAC,EAC1E,OAAO,CAAC,CAAC,CAAC,CACX;CACF,CAAC,CAAC;AAIH,MAAM,YAAY,GAAG,IAAI,GAAG,EAAgC,CAAC;AAE7D;;GAEG;AACH,MAAM,CAAC,MAAM,UAA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AmE;YACnE,qCAAqC;YACrC,8DAA8D;YAC7D,aAAqB,CAAC,GAAG,GAAG,aAAa,CAAC;YAC3C,YAAY,CAAC,GAAG,CACd,GAAG,EACH,CAAC,OAAO,GAAG,aAAgD,CAAC,CAC7D,CAAC;SACH;QACD,MAAM,GAAG,aAAa,CAAC;KACxB;IACD,OAAO,OAAO,CAAC,OAAO,EAAE,GAAG,MAAM,CAAC,CAAC;AACrC,CAAC,CAAC;AAEJ;;;;;GAKG;AACH,MAAM,CAAC,MAAM,IAAI,GAAG,UAAU,CAAC,QAAQ,CAAC,CAAC;AAEzC;;;;;GAKG;AACH,MAAM,CAAC,MAAM,GAAG,GAAG,UAAU,CAAC,OAAO,CAAC,CAAC","sourcesContent":["/**\n * @license\n * Copyright 2020 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n// Any new exports need to be added to the export statement in\n// `packages/lit/src/index.all.ts`.\n\nimport {html as coreHtml, svg as coreSvg, TemplateResult} from './lit-html.js';\n\n/**\n * Wraps a string so that it behaves like part of the static template\n * strings instead of a dynamic value.\n *\n * Users must take care to ensure that adding the static string to the template\n * results in well-formed HTML, or else templates may break unexpectedly.\n *\n * Note that this function is unsafe to use on untrusted content, as it will be\n * directly parsed into HTML. Do not pass user input to this function\n * without sanitizing it.\n *\n * Static values can be changed, but they will cause a complete re-render\n * since they effectively create a new template.\n */\nexport const unsafeStatic = (value: string) => ({\n  ['_$litStatic$']: value,\n});\n\nconst textFromStatic = (value: StaticValue) => {\n  if (value['_$litStatic$'] !== undefined) {\n    return value['_$litStatic$'];\n  } else {\n    throw new Error(\n      `Value passed to 'literal' function must be a 'literal' result: ${value}. Use 'unsafeStatic' to pass non-literal values, but\n            take care to ensure page security.`\n    );\n  }\n};\n\n/**\n * Tags a string literal so that it behaves like part of the static template\n * strings instead of a dynamic value.\n *\n * The only values that may be used in template expressions are other tagged\n * `literal` results or `unsafeStatic` values (note that untrusted content\n * should never be passed to `unsafeStatic`).\n *\n * Users must take care to ensure that adding the static string to the template\n * results in well-formed HTML, or else templates may break unexpectedly.\n *\n * Static values can be changed, but they will cause a complete re-render since\n * they effectively create a new template.\n */\nexport const literal = (\n  strings: TemplateStringsArray,\n  ...values: unknown[]\n) => ({\n  ['_$litStatic$']: values.reduce(\n    (acc, v, idx) => acc + textFromStatic(v as StaticValue) + strings[idx + 1],\n    strings[0]\n  ),\n});\n\ntype StaticValue = ReturnType<typeof unsafeStatic>;\n\nconst stringsCache = new Map<string, TemplateStringsArray>();\n\n/**\n * Wraps a lit-html template tag (`html` or `svg`) to add static value support.\n */\nexport const withStatic =\n  (coreTag: typeof coreHtml | typeof coreSvg) =>\n  (strings: TemplateStringsArray, ...values: unknown[]): TemplateResult => {\n    const l = values.length;\n    let staticValue: string | undefined;\n    let dynamicValue: unknown;\n    const staticStrings: Array<string> = [];\n    const dynamicValues: Array<unknown> = [];\n    let i = 0;\n    let hasStatics = false;\n    let s: string;\n\n    while (i < l) {\n      s = strings[i];\n      // Collect any unsafeStatic values, and their following template strings\n      // so that we treat a run of template strings and unsafe static values as\n      // a single template string.\n      while (\n        i < l &&\n        ((dynamicValue = values[i]),\n        (staticValue = (dynamicValue as StaticValue)?.['_$litStatic$'])) !==\n          undefined\n      ) {\n        s += staticValue + strings[++i];\n        hasStatics = true;\n      }\n      dynamicValues.push(dynamicValue);\n      staticStrings.push(s);\n      i++;\n    }\n    // If the last value isn't static (which would have consumed the last\n    // string), then we need to add the last string.\n    if (i === l) {\n      staticStrings.push(strings[l]);\n    }\n\n    if (hasStatics) {\n      const key = staticStrings.join('$$lit$$');\n      strings = stringsCache.get(key)!;\n      if (strings === undefined) {\n        // Beware: in general this pattern is unsafe, and doing so may bypass\n        // lit's security checks and allow an attacker to execute arbitrary\n        // code and inject arbitrary content.\n        // eslint-disable-next-line @typescript-eslint/no-explicit-any\n        (staticStrings as any).raw = staticStrings;\n        stringsCache.set(\n          key,\n          (strings = staticStrings as unknown as TemplateStringsArray)\n        );\n      }\n      values = dynamicValues;\n    }\n    return coreTag(strings, ...values);\n  };\n\n/**\n * Interprets a template literal as an HTML template that can efficiently\n * render to and update a container.\n *\n * Includes static value support from `lit-html/static.js`.\n */\nexport const html = withStatic(coreHtml);\n\n/**\n * Interprets a template literal as an SVG template that can efficiently\n * render to and update a container.\n *\n * Includes static value support from `lit-html/static.js`.\n */\nexport const svg = withStatic(coreSvg);\n"]}
\ No newline at end of file
+{"version":3,"file":"static.js","sourceRoot":"","sources":["../src/static.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,8DAA8D;AAC9D,mCAAmC;AAEnC,OAAO,EAAC,IAAI,IAAI,QAAQ,EAAE,GAAG,IAAI,OAAO,EAAiB,MAAM,eAAe,CAAC;AAc/E;;;;;;;;;;;;;;GAcG;AACH,MAAM,KAAK,GAAG,MAAM,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;AAE7B,wDAAwD;AACxD,MAAM,iBAAiB,GAAG,CAAC,KAAc,EAAsB,EAAE;IAC/D,IAAI,CAAC,KAA8B,aAA9B,KAAK,uBAAL,KAAK,CAA2B,CAAC,MAAK,KAAK,EAAE;QAChD,OAAO,SAAS,CAAC;KAClB;IACD,OAAQ,KAA8B,aAA9B,KAAK,uBAAL,KAAK,CAA4B,cAAc,CAAC,CAAC;AAC3D,CAAC,CAAC;AAEF;;;;;;;;;;;;;GAaG;AACH,MAAM,CAAC,MAAM,YAAY,GAAG,CAAC,KAAa,EAAe,EAAE,CAAC,CAAC;IAC3D,CAAC,cAAc,CAAC,EAAE,KAAK;IACvB,CAAC,EAAE,KAAK;CACT,CAAC,CAAC;AAEH,MAAM,cAAc,GAAG,CAAC,KAAkB,EAAE,EAAE;IAC5C,IAAI,KAAK,CAAC,cAAc,CAAC,KAAK,SAAS,EAAE;QACvC,OAAO,KAAK,CAAC,cAAc,CAAC,CAAC;KAC9B;SAAM;QACL,MAAM,IAAI,KAAK,CACb,kEAAkE,KAAK;+CAC9B,CAC1C,CAAC;KACH;AACH,CAAC,CAAC;AA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aAAa,CAAC,IAAI,CAAC,YAAY,CAAC,CAAC;QACjC,aAAa,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;QACtB,CAAC,EAAE,CAAC;KACL;IACD,qEAAqE;IACrE,gDAAgD;IAChD,IAAI,CAAC,KAAK,CAAC,EAAE;QACX,aAAa,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC;KAChC;IAED,IAAI,UAAU,EAAE;QACd,MAAM,GAAG,GAAG,aAAa,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC;QAC1C,OAAO,GAAG,YAAY,CAAC,GAAG,CAAC,GAAG,CAAE,CAAC;QACjC,IAAI,OAAO,KAAK,SAAS,EAAE;YACzB,qEAAqE;YACrE,mEAAmE;YACnE,qCAAqC;YACrC,8DAA8D;YAC7D,aAAqB,CAAC,GAAG,GAAG,aAAa,CAAC;YAC3C,YAAY,CAAC,GAAG,CACd,GAAG,EACH,CAAC,OAAO,GAAG,aAAgD,CAAC,CAC7D,CAAC;SACH;QACD,MAAM,GAAG,aAAa,CAAC;KACxB;IACD,OAAO,OAAO,CAAC,OAAO,EAAE,GAAG,MAAM,CAAC,CAAC;AACrC,CAAC,CAAC;AAEJ;;;;;GAKG;AACH,MAAM,CAAC,MAAM,IAAI,GAAG,UAAU,CAAC,QAAQ,CAAC,CAAC;AAEzC;;;;;GAKG;AACH,MAAM,CAAC,MAAM,GAAG,GAAG,UAAU,CAAC,OAAO,CAAC,CAAC","sourcesContent":["/**\n * @license\n * Copyright 2020 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n// Any new exports need to be added to the export statement in\n// `packages/lit/src/index.all.ts`.\n\nimport {html as coreHtml, svg as coreSvg, TemplateResult} from './lit-html.js';\n\nexport interface StaticValue {\n  /** The value to interpolate as-is into the template. */\n  _$litStatic$: string;\n\n  /**\n   * A value that can't be decoded from ordinary JSON, make it harder for\n   * a attacker-controlled data that goes through JSON.parse to produce a valid\n   * StaticValue.\n   */\n  r: typeof brand;\n}\n\n/**\n * Prevents JSON injection attacks.\n *\n * The goals of this brand:\n *   1) fast to check\n *   2) code is small on the wire\n *   3) multiple versions of Lit in a single page will all produce mutually\n *      interoperable StaticValues\n *   4) normal JSON.parse (without an unusual reviver) can not produce a\n *      StaticValue\n *\n * Symbols satisfy (1), (2), and (4). We use Symbol.for to satisfy (3), but\n * we don't care about the key, so we break ties via (2) and use the empty\n * string.\n */\nconst brand = Symbol.for('');\n\n/** Safely extracts the string part of a StaticValue. */\nconst unwrapStaticValue = (value: unknown): string | undefined => {\n  if ((value as Partial<StaticValue>)?.r !== brand) {\n    return undefined;\n  }\n  return (value as Partial<StaticValue>)?.['_$litStatic$'];\n};\n\n/**\n * Wraps a string so that it behaves like part of the static template\n * strings instead of a dynamic value.\n *\n * Users must take care to ensure that adding the static string to the template\n * results in well-formed HTML, or else templates may break unexpectedly.\n *\n * Note that this function is unsafe to use on untrusted content, as it will be\n * directly parsed into HTML. Do not pass user input to this function\n * without sanitizing it.\n *\n * Static values can be changed, but they will cause a complete re-render\n * since they effectively create a new template.\n */\nexport const unsafeStatic = (value: string): StaticValue => ({\n  ['_$litStatic$']: value,\n  r: brand,\n});\n\nconst textFromStatic = (value: StaticValue) => {\n  if (value['_$litStatic$'] !== undefined) {\n    return value['_$litStatic$'];\n  } else {\n    throw new Error(\n      `Value passed to 'literal' function must be a 'literal' result: ${value}. Use 'unsafeStatic' to pass non-literal values, but\n            take care to ensure page security.`\n    );\n  }\n};\n\n/**\n * Tags a string literal so that it behaves like part of the static template\n * strings instead of a dynamic value.\n *\n * The only values that may be used in template expressions are other tagged\n * `literal` results or `unsafeStatic` values (note that untrusted content\n * should never be passed to `unsafeStatic`).\n *\n * Users must take care to ensure that adding the static string to the template\n * results in well-formed HTML, or else templates may break unexpectedly.\n *\n * Static values can be changed, but they will cause a complete re-render since\n * they effectively create a new template.\n */\nexport const literal = (\n  strings: TemplateStringsArray,\n  ...values: unknown[]\n): StaticValue => ({\n  ['_$litStatic$']: values.reduce(\n    (acc, v, idx) => acc + textFromStatic(v as StaticValue) + strings[idx + 1],\n    strings[0]\n  ) as string,\n  r: brand,\n});\n\nconst stringsCache = new Map<string, TemplateStringsArray>();\n\n/**\n * Wraps a lit-html template tag (`html` or `svg`) to add static value support.\n */\nexport const withStatic =\n  (coreTag: typeof coreHtml | typeof coreSvg) =>\n  (strings: TemplateStringsArray, ...values: unknown[]): TemplateResult => {\n    const l = values.length;\n    let staticValue: string | undefined;\n    let dynamicValue: unknown;\n    const staticStrings: Array<string> = [];\n    const dynamicValues: Array<unknown> = [];\n    let i = 0;\n    let hasStatics = false;\n    let s: string;\n\n    while (i < l) {\n      s = strings[i];\n      // Collect any unsafeStatic values, and their following template strings\n      // so that we treat a run of template strings and unsafe static values as\n      // a single template string.\n      while (\n        i < l &&\n        ((dynamicValue = values[i]),\n        (staticValue = unwrapStaticValue(dynamicValue))) !== undefined\n      ) {\n        s += staticValue + strings[++i];\n        hasStatics = true;\n      }\n      dynamicValues.push(dynamicValue);\n      staticStrings.push(s);\n      i++;\n    }\n    // If the last value isn't static (which would have consumed the last\n    // string), then we need to add the last string.\n    if (i === l) {\n      staticStrings.push(strings[l]);\n    }\n\n    if (hasStatics) {\n      const key = staticStrings.join('$$lit$$');\n      strings = stringsCache.get(key)!;\n      if (strings === undefined) {\n        // Beware: in general this pattern is unsafe, and doing so may bypass\n        // lit's security checks and allow an attacker to execute arbitrary\n        // code and inject arbitrary content.\n        // eslint-disable-next-line @typescript-eslint/no-explicit-any\n        (staticStrings as any).raw = staticStrings;\n        stringsCache.set(\n          key,\n          (strings = staticStrings as unknown as TemplateStringsArray)\n        );\n      }\n      values = dynamicValues;\n    }\n    return coreTag(strings, ...values);\n  };\n\n/**\n * Interprets a template literal as an HTML template that can efficiently\n * render to and update a container.\n *\n * Includes static value support from `lit-html/static.js`.\n */\nexport const html = withStatic(coreHtml);\n\n/**\n * Interprets a template literal as an SVG template that can efficiently\n * render to and update a container.\n *\n * Includes static value support from `lit-html/static.js`.\n */\nexport const svg = withStatic(coreSvg);\n"]}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/directive-helpers.d.ts b/front_end/third_party/lit-html/package/directive-helpers.d.ts
index 8b633940b82e38fbf14c663bd099e57cea186c80..300a0eb693eeced333744bf55af4796a52b03ceb 100644
--- a/front_end/third_party/lit-html/package/directive-helpers.d.ts
+++ b/front_end/third_party/lit-html/package/directive-helpers.d.ts
@@ -20,7 +20,7 @@ export declare type TemplateResultType = typeof TemplateResultType[keyof typeof TemplateResultType];
 /**
  * Tests if a value is a TemplateResult.
  */
-export declare const isTemplateResult: (value: unknown, type?: TemplateResultType | undefined) => value is TemplateResult<1 | 2>;
+export declare const isTemplateResult: (value: unknown, type?: TemplateResultType) => value is TemplateResult<1 | 2>;
 /**
  * Tests if a value is a DirectiveResult.
  */




diff --git a/front_end/third_party/lit-html/package/directive-helpers.d.ts.map b/front_end/third_party/lit-html/package/directive-helpers.d.ts.map
index eabd5ba2dffb495f35fee4140132e032cc0fc4a1..995ce2c39a686cb065adf7c6db0844ef2678852a 100644
--- a/front_end/third_party/lit-html/package/directive-helpers.d.ts.map
+++ b/front_end/third_party/lit-html/package/directive-helpers.d.ts.map
@@ -1 +1 @@
-{"version":3,"file":"directive-helpers.d.ts","sourceRoot":"","sources":["../src/directive-helpers.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAO,IAAI,EAAE,eAAe,EAAE,cAAc,EAAC,MAAM,eAAe,CAAC;AAC1E,OAAO,EACL,eAAe,EACf,cAAc,EACd,QAAQ,EAET,MAAM,gBAAgB,CAAC;AACxB,aAAK,SAAS,GAAG,IAAI,GAAG,SAAS,GAAG,OAAO,GAAG,MAAM,GAAG,MAAM,GAAG,MAAM,GAAG,MAAM,CAAC;AAehF;;;;GAIG;AACH,eAAO,MAAM,WAAW,UAAW,OAAO,uBACkC,CAAC;AAE7E,eAAO,MAAM,kBAAkB;;;CAGrB,CAAC;AAEX,oBAAY,kBAAkB,GAC5B,OAAO,kBAAkB,CAAC,MAAM,OAAO,kBAAkB,CAAC,CAAC;AAE7D;;GAEG;AACH,eAAO,MAAM,gBAAgB,UACpB,OAAO,0EAMwC,CAAC;AAEzD;;GAEG;AACH,eAAO,MAAM,iBAAiB,UAAW,OAAO,6CAEe,CAAC;AAEhE;;GAEG;AACH,eAAO,MAAM,iBAAiB,UAAW,OAAO,KAAG,cAAc,GAAG,SAEnB,CAAC;AAElD;;;;;;;GAOG;AACH,eAAO,MAAM,kBAAkB,SAAU,QAAQ,YACE,CAAC;AAIpD;;;;;;;;;;;GAWG;AACH,eAAO,MAAM,UAAU,wMAqDtB,CAAC;AAEF;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,iBAAiB,gEAErB,OAAO,oBACG,eAAe,MAIjC,CAAC;AAMF;;;;;;;;;;GAUG;AACH,eAAO,MAAM,iBAAiB,SAAU,IAAI,UAAS,OAAO,YAC3B,CAAC;AAElC;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,iBAAiB,sDAA6C,CAAC;AAE5E;;;;GAIG;AACH,eAAO,MAAM,UAAU,mDAStB,CAAC;AAEF,eAAO,MAAM,SAAS,mDAErB,CAAC"}
\ No newline at end of file
+{"version":3,"file":"directive-helpers.d.ts","sourceRoot":"","sources":["../src/directive-helpers.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAO,IAAI,EAAE,eAAe,EAAE,cAAc,EAAC,MAAM,eAAe,CAAC;AAC1E,OAAO,EACL,eAAe,EACf,cAAc,EACd,QAAQ,EAET,MAAM,gBAAgB,CAAC;AACxB,aAAK,SAAS,GAAG,IAAI,GAAG,SAAS,GAAG,OAAO,GAAG,MAAM,GAAG,MAAM,GAAG,MAAM,GAAG,MAAM,CAAC;AAehF;;;;GAIG;AACH,eAAO,MAAM,WAAW,UAAW,OAAO,uBACkC,CAAC;AAE7E,eAAO,MAAM,kBAAkB;;;CAGrB,CAAC;AAEX,oBAAY,kBAAkB,GAC5B,OAAO,kBAAkB,CAAC,MAAM,OAAO,kBAAkB,CAAC,CAAC;AAE7D;;GAEG;AACH,eAAO,MAAM,gBAAgB,UACpB,OAAO,SACP,kBAAkB,mCAK6B,CAAC;AAEzD;;GAEG;AACH,eAAO,MAAM,iBAAiB,UAAW,OAAO,6CAEe,CAAC;AAEhE;;GAEG;AACH,eAAO,MAAM,iBAAiB,UAAW,OAAO,KAAG,cAAc,GAAG,SAEnB,CAAC;AAElD;;;;;;;GAOG;AACH,eAAO,MAAM,kBAAkB,SAAU,QAAQ,YACE,CAAC;AAIpD;;;;;;;;;;;GAWG;AACH,eAAO,MAAM,UAAU,wMAqDtB,CAAC;AAEF;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,iBAAiB,gEAErB,OAAO,oBACG,eAAe,MAIjC,CAAC;AAMF;;;;;;;;;;GAUG;AACH,eAAO,MAAM,iBAAiB,SAAU,IAAI,UAAS,OAAO,YAC3B,CAAC;AAElC;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,iBAAiB,sDAA6C,CAAC;AAE5E;;;;GAIG;AACH,eAAO,MAAM,UAAU,mDAStB,CAAC;AAEF,eAAO,MAAM,SAAS,mDAErB,CAAC"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/directive-helpers.js b/front_end/third_party/lit-html/package/directive-helpers.js
index 4e742a48d29c143ebf708cf87c04779b38199b42..edb030ce3caa489e1ae5824e114ff533c9383899 100644
--- a/front_end/third_party/lit-html/package/directive-helpers.js
+++ b/front_end/third_party/lit-html/package/directive-helpers.js
@@ -3,5 +3,5 @@ /**
  * @license
  * Copyright 2020 Google LLC
  * SPDX-License-Identifier: BSD-3-Clause
- */const{H:i}=o,t=o=>null===o||"object"!=typeof o&&"function"!=typeof o,n={HTML:1,SVG:2},v=(o,i)=>{var t,n;return void 0===i?void 0!==(null===(t=o)||void 0===t?void 0:t._$litType$):(null===(n=o)||void 0===n?void 0:n._$litType$)===i},l=o=>{var i;return void 0!==(null===(i=o)||void 0===i?void 0:i._$litDirective$)},d=o=>{var i;return null===(i=o)||void 0===i?void 0:i._$litDirective$},r=o=>void 0===o.strings,e=()=>document.createComment(""),u=(o,t,n)=>{var v;const l=o._$AA.parentNode,d=void 0===t?o._$AB:t._$AA;if(void 0===n){const t=l.insertBefore(e(),d),v=l.insertBefore(e(),d);n=new i(t,v,o,o.options)}else{const i=n._$AB.nextSibling,t=n._$AM,r=t!==o;if(r){let i;null===(v=n._$AQ)||void 0===v||v.call(n,o),n._$AM=o,void 0!==n._$AP&&(i=o._$AU)!==t._$AU&&n._$AP(i)}if(i!==d||r){let o=n._$AA;for(;o!==i;){const i=o.nextSibling;l.insertBefore(o,d),o=i}}}return n},c=(o,i,t=o)=>(o._$AI(i,t),o),f={},s=(o,i=f)=>o._$AH=i,a=o=>o._$AH,m=o=>{var i;null===(i=o._$AP)||void 0===i||i.call(o,!1,!0);let t=o._$AA;const n=o._$AB.nextSibling;for(;t!==n;){const o=t.nextSibling;t.remove(),t=o}},p=o=>{o._$AR()};export{n as TemplateResultType,p as clearPart,a as getCommittedValue,d as getDirectiveClass,u as insertPart,l as isDirectiveResult,t as isPrimitive,r as isSingleExpression,v as isTemplateResult,m as removePart,c as setChildPartValue,s as setCommittedValue};
+ */const{I:l}=o,t=o=>null===o||"object"!=typeof o&&"function"!=typeof o,i={HTML:1,SVG:2},n=(o,l)=>void 0===l?void 0!==(null==o?void 0:o._$litType$):(null==o?void 0:o._$litType$)===l,d=o=>void 0!==(null==o?void 0:o._$litDirective$),v=o=>null==o?void 0:o._$litDirective$,e=o=>void 0===o.strings,c=()=>document.createComment(""),r=(o,t,i)=>{var n;const d=o._$AA.parentNode,v=void 0===t?o._$AB:t._$AA;if(void 0===i){const t=d.insertBefore(c(),v),n=d.insertBefore(c(),v);i=new l(t,n,o,o.options)}else{const l=i._$AB.nextSibling,t=i._$AM,e=t!==o;if(e){let l;null===(n=i._$AQ)||void 0===n||n.call(i,o),i._$AM=o,void 0!==i._$AP&&(l=o._$AU)!==t._$AU&&i._$AP(l)}if(l!==v||e){let o=i._$AA;for(;o!==l;){const l=o.nextSibling;d.insertBefore(o,v),o=l}}}return i},u=(o,l,t=o)=>(o._$AI(l,t),o),f={},s=(o,l=f)=>o._$AH=l,m=o=>o._$AH,p=o=>{var l;null===(l=o._$AP)||void 0===l||l.call(o,!1,!0);let t=o._$AA;const i=o._$AB.nextSibling;for(;t!==i;){const o=t.nextSibling;t.remove(),t=o}},a=o=>{o._$AR()};export{i as TemplateResultType,a as clearPart,m as getCommittedValue,v as getDirectiveClass,r as insertPart,d as isDirectiveResult,t as isPrimitive,e as isSingleExpression,n as isTemplateResult,p as removePart,u as setChildPartValue,s as setCommittedValue};
 //# sourceMappingURL=directive-helpers.js.map




diff --git a/front_end/third_party/lit-html/package/directive-helpers.js.map b/front_end/third_party/lit-html/package/directive-helpers.js.map
index be58049619702cd3614090aa46e42c68c74923f8..3135a7e80557186b8aae04c1805b567cc95ea54d 100644
--- a/front_end/third_party/lit-html/package/directive-helpers.js.map
+++ b/front_end/third_party/lit-html/package/directive-helpers.js.map
@@ -1 +1 @@
-{"version":3,"file":"directive-helpers.js","sources":["src/directive-helpers.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2020 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {_$LH, Part, DirectiveParent, TemplateResult} from './lit-html.js';\nimport {\n  DirectiveResult,\n  DirectiveClass,\n  PartInfo,\n  AttributePartInfo,\n} from './directive.js';\ntype Primitive = null | undefined | boolean | number | string | symbol | bigint;\n\nconst {_ChildPart: ChildPart} = _$LH;\n\ntype ChildPart = InstanceType<typeof ChildPart>;\n\nconst ENABLE_SHADYDOM_NOPATCH = true;\n\nconst wrap =\n  ENABLE_SHADYDOM_NOPATCH &&\n  window.ShadyDOM?.inUse &&\n  window.ShadyDOM?.noPatch === true\n    ? window.ShadyDOM!.wrap\n    : (node: Node) => node;\n\n/**\n * Tests if a value is a primitive value.\n *\n * See https://tc39.github.io/ecma262/#sec-typeof-operator\n */\nexport const isPrimitive = (value: unknown): value is Primitive =>\n  value === null || (typeof value != 'object' && typeof value != 'function');\n\nexport const TemplateResultType = {\n  HTML: 1,\n  SVG: 2,\n} as const;\n\nexport type TemplateResultType =\n  typeof TemplateResultType[keyof typeof TemplateResultType];\n\n/**\n * Tests if a value is a TemplateResult.\n */\nexport const isTemplateResult = (\n  value: unknown,\n  type?: TemplateResultType\n): value is TemplateResult =>\n  type === undefined\n    ? // This property needs to remain unminified.\n      (value as TemplateResult)?.['_$litType$'] !== undefined\n    : (value as TemplateResult)?.['_$litType$'] === type;\n\n/**\n * Tests if a value is a DirectiveResult.\n */\nexport const isDirectiveResult = (value: unknown): value is DirectiveResult =>\n  // This property needs to remain unminified.\n  (value as DirectiveResult)?.['_$litDirective$'] !== undefined;\n\n/**\n * Retrieves the Directive class for a DirectiveResult\n */\nexport const getDirectiveClass = (value: unknown): DirectiveClass | undefined =>\n  // This property needs to remain unminified.\n  (value as DirectiveResult)?.['_$litDirective$'];\n\n/**\n * Tests whether a part has only a single-expression with no strings to\n * interpolate between.\n *\n * Only AttributePart and PropertyPart can have multiple expressions.\n * Multi-expression parts have a `strings` property and single-expression\n * parts do not.\n */\nexport const isSingleExpression = (part: PartInfo) =>\n  (part as AttributePartInfo).strings === undefined;\n\nconst createMarker = () => document.createComment('');\n\n/**\n * Inserts a ChildPart into the given container ChildPart's DOM, either at the\n * end of the container ChildPart, or before the optional `refPart`.\n *\n * This does not add the part to the containerPart's committed value. That must\n * be done by callers.\n *\n * @param containerPart Part within which to add the new ChildPart\n * @param refPart Part before which to add the new ChildPart; when omitted the\n *     part added to the end of the `containerPart`\n * @param part Part to insert, or undefined to create a new part\n */\nexport const insertPart = (\n  containerPart: ChildPart,\n  refPart?: ChildPart,\n  part?: ChildPart\n): ChildPart => {\n  const container = wrap(containerPart._$startNode).parentNode!;\n\n  const refNode =\n    refPart === undefined ? containerPart._$endNode : refPart._$startNode;\n\n  if (part === undefined) {\n    const startNode = wrap(container).insertBefore(createMarker(), refNode);\n    const endNode = wrap(container).insertBefore(createMarker(), refNode);\n    part = new ChildPart(\n      startNode,\n      endNode,\n      containerPart,\n      containerPart.options\n    );\n  } else {\n    const endNode = wrap(part._$endNode!).nextSibling;\n    const oldParent = part._$parent;\n    const parentChanged = oldParent !== containerPart;\n    if (parentChanged) {\n      part._$reparentDisconnectables?.(containerPart);\n      // Note that although `_$reparentDisconnectables` updates the part's\n      // `_$parent` reference after unlinking from its current parent, that\n      // method only exists if Disconnectables are present, so we need to\n      // unconditionally set it here\n      part._$parent = containerPart;\n      // Since the _$isConnected getter is somewhat costly, only\n      // read it once we know the subtree has directives that need\n      // to be notified\n      let newConnectionState;\n      if (\n        part._$notifyConnectionChanged !== undefined &&\n        (newConnectionState = containerPart._$isConnected) !==\n          oldParent!._$isConnected\n      ) {\n        part._$notifyConnectionChanged(newConnectionState);\n      }\n    }\n    if (endNode !== refNode || parentChanged) {\n      let start: Node | null = part._$startNode;\n      while (start !== endNode) {\n        const n: Node | null = wrap(start!).nextSibling;\n        wrap(container).insertBefore(start!, refNode);\n        start = n;\n      }\n    }\n  }\n\n  return part;\n};\n\n/**\n * Sets the value of a Part.\n *\n * Note that this should only be used to set/update the value of user-created\n * parts (i.e. those created using `insertPart`); it should not be used\n * by directives to set the value of the directive's container part. Directives\n * should return a value from `update`/`render` to update their part state.\n *\n * For directives that require setting their part value asynchronously, they\n * should extend `AsyncDirective` and call `this.setValue()`.\n *\n * @param part Part to set\n * @param value Value to set\n * @param index For `AttributePart`s, the index to set\n * @param directiveParent Used internally; should not be set by user\n */\nexport const setChildPartValue = <T extends ChildPart>(\n  part: T,\n  value: unknown,\n  directiveParent: DirectiveParent = part\n): T => {\n  part._$setValue(value, directiveParent);\n  return part;\n};\n\n// A sentinal value that can never appear as a part value except when set by\n// live(). Used to force a dirty-check to fail and cause a re-render.\nconst RESET_VALUE = {};\n\n/**\n * Sets the committed value of a ChildPart directly without triggering the\n * commit stage of the part.\n *\n * This is useful in cases where a directive needs to update the part such\n * that the next update detects a value change or not. When value is omitted,\n * the next update will be guaranteed to be detected as a change.\n *\n * @param part\n * @param value\n */\nexport const setCommittedValue = (part: Part, value: unknown = RESET_VALUE) =>\n  (part._$committedValue = value);\n\n/**\n * Returns the committed value of a ChildPart.\n *\n * The committed value is used for change detection and efficient updates of\n * the part. It can differ from the value set by the template or directive in\n * cases where the template value is transformed before being commited.\n *\n * - `TemplateResult`s are committed as a `TemplateInstance`\n * - Iterables are committed as `Array<ChildPart>`\n * - All other types are committed as the template value or value returned or\n *   set by a directive.\n *\n * @param part\n */\nexport const getCommittedValue = (part: ChildPart) => part._$committedValue;\n\n/**\n * Removes a ChildPart from the DOM, including any of its content.\n *\n * @param part The Part to remove\n */\nexport const removePart = (part: ChildPart) => {\n  part._$notifyConnectionChanged?.(false, true);\n  let start: ChildNode | null = part._$startNode;\n  const end: ChildNode | null = wrap(part._$endNode!).nextSibling;\n  while (start !== end) {\n    const n: ChildNode | null = wrap(start!).nextSibling;\n    (wrap(start!) as ChildNode).remove();\n    start = n;\n  }\n};\n\nexport const clearPart = (part: ChildPart) => {\n  part._$clear();\n};\n"],"names":["_ChildPart","ChildPart","_$LH","isPrimitive","value","TemplateResultType","HTML","SVG","isTemplateResult","type","undefined","isDirectiveResult","getDirectiveClass","isSingleExpression","part","strings","createMarker","document","createComment","insertPart","containerPart","refPart","container","_$startNode","parentNode","refNode","_$endNode","startNode","insertBefore","endNode","options","nextSibling","oldParent","_$parent","parentChanged","newConnectionState","_$reparentDisconnectables","_$notifyConnectionChanged","_$isConnected","start","n","setChildPartValue","directiveParent","_$setValue","RESET_VALUE","setCommittedValue","_$committedValue","getCommittedValue","removePart","end","remove","clearPart","_$clear"],"mappings":";;;;;GAeA,MAAOA,EAAYC,GAAaC,EAkBnBC,EAAeC,GAChB,OAAVA,GAAmC,iBAATA,GAAqC,mBAATA,EAE3CC,EAAqB,CAChCC,KAAM,EACNC,IAAK,GASMC,EAAmB,CAC9BJ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,GAAO,GACxC,IAAIyB,EAA0BzB,EAAKS,KACnC,MAAM0B,EAA6BnC,EAAKY,KAAYK,YACpD,KAAOQ,IAAUU,GAAK,CACpB,MAAMT,EAA2BD,EAAQR,YACnCQ,EAAsBW,SAC5BX,EAAQC,IAICW,EAAarC,IACxBA,EAAKsC"}
\ No newline at end of file
+{"version":3,"file":"directive-helpers.js","sources":["src/directive-helpers.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2020 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {_$LH, Part, DirectiveParent, TemplateResult} from './lit-html.js';\nimport {\n  DirectiveResult,\n  DirectiveClass,\n  PartInfo,\n  AttributePartInfo,\n} from './directive.js';\ntype Primitive = null | undefined | boolean | number | string | symbol | bigint;\n\nconst {_ChildPart: ChildPart} = _$LH;\n\ntype ChildPart = InstanceType<typeof ChildPart>;\n\nconst ENABLE_SHADYDOM_NOPATCH = true;\n\nconst wrap =\n  ENABLE_SHADYDOM_NOPATCH &&\n  window.ShadyDOM?.inUse &&\n  window.ShadyDOM?.noPatch === true\n    ? window.ShadyDOM!.wrap\n    : (node: Node) => node;\n\n/**\n * Tests if a value is a primitive value.\n *\n * See https://tc39.github.io/ecma262/#sec-typeof-operator\n */\nexport const isPrimitive = (value: unknown): value is Primitive =>\n  value === null || (typeof value != 'object' && typeof value != 'function');\n\nexport const TemplateResultType = {\n  HTML: 1,\n  SVG: 2,\n} as const;\n\nexport type TemplateResultType =\n  typeof TemplateResultType[keyof typeof TemplateResultType];\n\n/**\n * Tests if a value is a TemplateResult.\n */\nexport const isTemplateResult = (\n  value: unknown,\n  type?: TemplateResultType\n): value is TemplateResult =>\n  type === undefined\n    ? // This property needs to remain unminified.\n      (value as TemplateResult)?.['_$litType$'] !== undefined\n    : (value as TemplateResult)?.['_$litType$'] === type;\n\n/**\n * Tests if a value is a DirectiveResult.\n */\nexport const isDirectiveResult = (value: unknown): value is DirectiveResult =>\n  // This property needs to remain unminified.\n  (value as DirectiveResult)?.['_$litDirective$'] !== undefined;\n\n/**\n * Retrieves the Directive class for a DirectiveResult\n */\nexport const getDirectiveClass = (value: unknown): DirectiveClass | undefined =>\n  // This property needs to remain unminified.\n  (value as DirectiveResult)?.['_$litDirective$'];\n\n/**\n * Tests whether a part has only a single-expression with no strings to\n * interpolate between.\n *\n * Only AttributePart and PropertyPart can have multiple expressions.\n * Multi-expression parts have a `strings` property and single-expression\n * parts do not.\n */\nexport const isSingleExpression = (part: PartInfo) =>\n  (part as AttributePartInfo).strings === undefined;\n\nconst createMarker = () => document.createComment('');\n\n/**\n * Inserts a ChildPart into the given container ChildPart's DOM, either at the\n * end of the container ChildPart, or before the optional `refPart`.\n *\n * This does not add the part to the containerPart's committed value. That must\n * be done by callers.\n *\n * @param containerPart Part within which to add the new ChildPart\n * @param refPart Part before which to add the new ChildPart; when omitted the\n *     part added to the end of the `containerPart`\n * @param part Part to insert, or undefined to create a new part\n */\nexport const insertPart = (\n  containerPart: ChildPart,\n  refPart?: ChildPart,\n  part?: ChildPart\n): ChildPart => {\n  const container = wrap(containerPart._$startNode).parentNode!;\n\n  const refNode =\n    refPart === undefined ? containerPart._$endNode : refPart._$startNode;\n\n  if (part === undefined) {\n    const startNode = wrap(container).insertBefore(createMarker(), refNode);\n    const endNode = wrap(container).insertBefore(createMarker(), refNode);\n    part = new ChildPart(\n      startNode,\n      endNode,\n      containerPart,\n      containerPart.options\n    );\n  } else {\n    const endNode = wrap(part._$endNode!).nextSibling;\n    const oldParent = part._$parent;\n    const parentChanged = oldParent !== containerPart;\n    if (parentChanged) {\n      part._$reparentDisconnectables?.(containerPart);\n      // Note that although `_$reparentDisconnectables` updates the part's\n      // `_$parent` reference after unlinking from its current parent, that\n      // method only exists if Disconnectables are present, so we need to\n      // unconditionally set it here\n      part._$parent = containerPart;\n      // Since the _$isConnected getter is somewhat costly, only\n      // read it once we know the subtree has directives that need\n      // to be notified\n      let newConnectionState;\n      if (\n        part._$notifyConnectionChanged !== undefined &&\n        (newConnectionState = containerPart._$isConnected) !==\n          oldParent!._$isConnected\n      ) {\n        part._$notifyConnectionChanged(newConnectionState);\n      }\n    }\n    if (endNode !== refNode || parentChanged) {\n      let start: Node | null = part._$startNode;\n      while (start !== endNode) {\n        const n: Node | null = wrap(start!).nextSibling;\n        wrap(container).insertBefore(start!, refNode);\n        start = n;\n      }\n    }\n  }\n\n  return part;\n};\n\n/**\n * Sets the value of a Part.\n *\n * Note that this should only be used to set/update the value of user-created\n * parts (i.e. those created using `insertPart`); it should not be used\n * by directives to set the value of the directive's container part. Directives\n * should return a value from `update`/`render` to update their part state.\n *\n * For directives that require setting their part value asynchronously, they\n * should extend `AsyncDirective` and call `this.setValue()`.\n *\n * @param part Part to set\n * @param value Value to set\n * @param index For `AttributePart`s, the index to set\n * @param directiveParent Used internally; should not be set by user\n */\nexport const setChildPartValue = <T extends ChildPart>(\n  part: T,\n  value: unknown,\n  directiveParent: DirectiveParent = part\n): T => {\n  part._$setValue(value, directiveParent);\n  return part;\n};\n\n// A sentinal value that can never appear as a part value except when set by\n// live(). Used to force a dirty-check to fail and cause a re-render.\nconst RESET_VALUE = {};\n\n/**\n * Sets the committed value of a ChildPart directly without triggering the\n * commit stage of the part.\n *\n * This is useful in cases where a directive needs to update the part such\n * that the next update detects a value change or not. When value is omitted,\n * the next update will be guaranteed to be detected as a change.\n *\n * @param part\n * @param value\n */\nexport const setCommittedValue = (part: Part, value: unknown = RESET_VALUE) =>\n  (part._$committedValue = value);\n\n/**\n * Returns the committed value of a ChildPart.\n *\n * The committed value is used for change detection and efficient updates of\n * the part. It can differ from the value set by the template or directive in\n * cases where the template value is transformed before being commited.\n *\n * - `TemplateResult`s are committed as a `TemplateInstance`\n * - Iterables are committed as `Array<ChildPart>`\n * - All other types are committed as the template value or value returned or\n *   set by a directive.\n *\n * @param part\n */\nexport const getCommittedValue = (part: ChildPart) => part._$committedValue;\n\n/**\n * Removes a ChildPart from the DOM, including any of its content.\n *\n * @param part The Part to remove\n */\nexport const removePart = (part: ChildPart) => {\n  part._$notifyConnectionChanged?.(false, true);\n  let start: ChildNode | null = part._$startNode;\n  const end: ChildNode | null = wrap(part._$endNode!).nextSibling;\n  while (start !== end) {\n    const n: ChildNode | null = wrap(start!).nextSibling;\n    (wrap(start!) as ChildNode).remove();\n    start = n;\n  }\n};\n\nexport const clearPart = (part: ChildPart) => {\n  part._$clear();\n};\n"],"names":["_ChildPart","ChildPart","_$LH","isPrimitive","value","TemplateResultType","HTML","SVG","isTemplateResult","type","undefined","isDirectiveResult","getDirectiveClass","isSingleExpression","part","strings","createMarker","document","createComment","insertPart","containerPart","refPart","container","_$startNode","parentNode","refNode","_$endNode","startNode","insertBefore","endNode","options","nextSibling","oldParent","_$parent","parentChanged","newConnectionState","_a","_$reparentDisconnectables","call","_$notifyConnectionChanged","_$isConnected","start","n","setChildPartValue","directiveParent","_$setValue","RESET_VALUE","setCommittedValue","_$committedValue","getCommittedValue","removePart","end","remove","clearPart","_$clear"],"mappings":";;;;;GAeA,MAAOA,EAAYC,GAAaC,EAkBnBC,EAAeC,GAChB,OAAVA,GAAmC,iBAATA,GAAqC,mBAATA,EAE3CC,EAAqB,CAChCC,KAAM,EACNC,IAAK,GASMC,EAAmB,CAC9BJ,EACAK,SAESC,IAATD,OAEkDC,KAA7CN,aAAK,EAALA,EAAuC,aACvCA,aAAK,EAALA,EAAuC,cAAMK,EAKvCE,EAAqBP,QAEoBM,KAAnDN,aAAA,EAAAA,EAA6C,iBAKnCQ,EAAqBR,GAE/BA,aAAK,EAALA,EAA6C,gBAUnCS,EAAsBC,QACOJ,IAAvCI,EAA2BC,QAExBC,EAAe,IAAMC,SAASC,cAAc,IAcrCC,EAAa,CACxBC,EACAC,EACAP,WAEA,MAAMQ,EAAiBF,EAAcG,KAAaC,WAE5CC,OACQf,IAAZW,EAAwBD,EAAcM,KAAYL,EAAQE,KAE5D,QAAab,IAATI,EAAoB,CACtB,MAAMa,EAAiBL,EAAWM,aAAaZ,IAAgBS,GACzDI,EAAeP,EAAWM,aAAaZ,IAAgBS,GAC7DX,EAAO,IAAIb,EACT0B,EACAE,EACAT,EACAA,EAAcU,QAEjB,KAAM,CACL,MAAMD,EAAef,EAAKY,KAAYK,YAChCC,EAAYlB,EAAKmB,KACjBC,EAAgBF,IAAcZ,EACpC,GAAIc,EAAe,CAUjB,IAAIC,EAT6B,QAAjCC,EAAAtB,EAAKuB,YAA4B,IAAAD,GAAAA,EAAAE,KAAAxB,EAAAM,GAKjCN,EAAKmB,KAAWb,OAMqBV,IAAnCI,EAAKyB,OACJJ,EAAqBf,EAAcoB,QAClCR,EAAWQ,MAEb1B,EAAKyB,KAA0BJ,EAElC,CACD,GAAIN,IAAYJ,GAAWS,EAAe,CACxC,IAAIO,EAAqB3B,EAAKS,KAC9B,KAAOkB,IAAUZ,GAAS,CACxB,MAAMa,EAAsBD,EAAQV,YAC/BT,EAAWM,aAAaa,EAAQhB,GACrCgB,EAAQC,CACT,CACF,CACF,CAED,OAAO5B,CAAI,EAmBA6B,EAAoB,CAC/B7B,EACAV,EACAwC,EAAmC9B,KAEnCA,EAAK+B,KAAWzC,EAAOwC,GAChB9B,GAKHgC,EAAc,CAAA,EAaPC,EAAoB,CAACjC,EAAYV,EAAiB0C,IAC5DhC,EAAKkC,KAAmB5C,EAgBd6C,EAAqBnC,GAAoBA,EAAKkC,KAO9CE,EAAcpC,UACK,QAA9BsB,EAAAtB,EAAKyB,YAAyB,IAAAH,GAAAA,EAAAE,KAAAxB,GAAG,GAAO,GACxC,IAAI2B,EAA0B3B,EAAKS,KACnC,MAAM4B,EAA6BrC,EAAKY,KAAYK,YACpD,KAAOU,IAAUU,GAAK,CACpB,MAAMT,EAA2BD,EAAQV,YACnCU,EAAsBW,SAC5BX,EAAQC,CACT,GAGUW,EAAavC,IACxBA,EAAKwC,MAAS"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/directive.d.ts b/front_end/third_party/lit-html/package/directive.d.ts
index 5b4dcf1964ec047be24db2b0220898abbbbb711c..d63131209747d14d1c564c6c7417243adf642cce 100644
--- a/front_end/third_party/lit-html/package/directive.d.ts
+++ b/front_end/third_party/lit-html/package/directive.d.ts
@@ -3,8 +3,8 @@  * @license
  * Copyright 2017 Google LLC
  * SPDX-License-Identifier: BSD-3-Clause
  */
-import { Disconnectable, Part } from './lit-html';
+import { Disconnectable, Part } from './lit-html.js';
-export { AttributePart, BooleanAttributePart, ChildPart, ElementPart, EventPart, Part, PropertyPart, } from './lit-html';
+export { AttributePart, BooleanAttributePart, ChildPart, ElementPart, EventPart, Part, PropertyPart, } from './lit-html.js';
 export interface DirectiveClass {
     new (part: PartInfo): Directive;
 }




diff --git a/front_end/third_party/lit-html/package/directive.d.ts.map b/front_end/third_party/lit-html/package/directive.d.ts.map
index 2a13ef5347324c817dcf999bf7eee866220463e3..38fa290590548e7172695af33880356ee05345dc 100644
--- a/front_end/third_party/lit-html/package/directive.d.ts.map
+++ b/front_end/third_party/lit-html/package/directive.d.ts.map
@@ -1 +1 @@
-{"version":3,"file":"directive.d.ts","sourceRoot":"","sources":["../src/directive.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAC,cAAc,EAAE,IAAI,EAAC,MAAM,YAAY,CAAC;AAEhD,OAAO,EACL,aAAa,EACb,oBAAoB,EACpB,SAAS,EACT,WAAW,EACX,SAAS,EACT,IAAI,EACJ,YAAY,GACb,MAAM,YAAY,CAAC;AAEpB,MAAM,WAAW,cAAc;IAC7B,KAAK,IAAI,EAAE,QAAQ,GAAG,SAAS,CAAC;CACjC;AAED;;;GAGG;AACH,oBAAY,mBAAmB,CAAC,CAAC,SAAS,SAAS,IAAI,UAAU,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC;AAE/E;;;GAGG;AACH,MAAM,WAAW,eAAe,CAAC,CAAC,SAAS,cAAc,GAAG,cAAc;CAOzE;AAED,eAAO,MAAM,QAAQ;;;;;;;CAOX,CAAC;AAEX,oBAAY,QAAQ,GAAG,OAAO,QAAQ,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,KAAK,EAAE,KAAK,CAAC,OAAO,CAAC,GAAG,OAAO;IAElD,MAAM,CAAC,KAAK,EAAE,IAAI,EAAE,KAAK,EAAE,KAAK,CAAC,OAAO,CAAC,GAAG,OAAO;CAGpD"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/directive.js.map b/front_end/third_party/lit-html/package/directive.js.map
index afcf7a4dcb697673085993c0fdbc3ba6037afea2..ec4f7b8e7d0d21217b9e4c380095607b387d8170 100644
--- a/front_end/third_party/lit-html/package/directive.js.map
+++ b/front_end/third_party/lit-html/package/directive.js.map
@@ -1 +1 @@
-{"version":3,"file":"directive.js","sources":["src/directive.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {Disconnectable, Part} from './lit-html';\n\nexport {\n  AttributePart,\n  BooleanAttributePart,\n  ChildPart,\n  ElementPart,\n  EventPart,\n  Part,\n  PropertyPart,\n} from './lit-html';\n\nexport interface DirectiveClass {\n  new (part: PartInfo): Directive;\n}\n\n/**\n * This utility type extracts the signature of a directive class's render()\n * method so we can use it for the type of the generated directive function.\n */\nexport type DirectiveParameters<C extends Directive> = Parameters<C['render']>;\n\n/**\n * A generated directive function doesn't evaluate the directive, but just\n * returns a DirectiveResult object that captures the arguments.\n */\nexport interface DirectiveResult<C extends DirectiveClass = DirectiveClass> {\n  /**\n   * This property needs to remain unminified.\n   * @internal */\n  ['_$litDirective$']: C;\n  /** @internal */\n  values: DirectiveParameters<InstanceType<C>>;\n}\n\nexport const PartType = {\n  ATTRIBUTE: 1,\n  CHILD: 2,\n  PROPERTY: 3,\n  BOOLEAN_ATTRIBUTE: 4,\n  EVENT: 5,\n  ELEMENT: 6,\n} as const;\n\nexport type PartType = typeof PartType[keyof typeof PartType];\n\nexport interface ChildPartInfo {\n  readonly type: typeof PartType.CHILD;\n}\n\nexport interface AttributePartInfo {\n  readonly type:\n    | typeof PartType.ATTRIBUTE\n    | typeof PartType.PROPERTY\n    | typeof PartType.BOOLEAN_ATTRIBUTE\n    | typeof PartType.EVENT;\n  readonly strings?: ReadonlyArray<string>;\n  readonly name: string;\n  readonly tagName: string;\n}\n\nexport interface ElementPartInfo {\n  readonly type: typeof PartType.ELEMENT;\n}\n\n/**\n * Information about the part a directive is bound to.\n *\n * This is useful for checking that a directive is attached to a valid part,\n * such as with directive that can only be used on attribute bindings.\n */\nexport type PartInfo = ChildPartInfo | AttributePartInfo | ElementPartInfo;\n\n/**\n * Creates a user-facing directive function from a Directive class. This\n * function has the same parameters as the directive's render() method.\n */\nexport const directive =\n  <C extends DirectiveClass>(c: C) =>\n  (...values: DirectiveParameters<InstanceType<C>>): DirectiveResult<C> => ({\n    // This property needs to remain unminified.\n    ['_$litDirective$']: c,\n    values,\n  });\n\n/**\n * Base class for creating custom directives. Users should extend this class,\n * implement `render` and/or `update`, and then pass their subclass to\n * `directive`.\n */\nexport abstract class Directive implements Disconnectable {\n  //@internal\n  __part!: Part;\n  //@internal\n  __attributeIndex: number | undefined;\n  //@internal\n  __directive?: Directive;\n\n  //@internal\n  _$parent!: Disconnectable;\n\n  // These will only exist on the AsyncDirective subclass\n  //@internal\n  _$disconnectableChildren?: Set<Disconnectable>;\n  // This property needs to remain unminified.\n  //@internal\n  ['_$notifyDirectiveConnectionChanged']?(isConnected: boolean): void;\n\n  constructor(_partInfo: PartInfo) {}\n\n  // See comment in Disconnectable interface for why this is a getter\n  get _$isConnected() {\n    return this._$parent._$isConnected;\n  }\n\n  /** @internal */\n  _$initialize(\n    part: Part,\n    parent: Disconnectable,\n    attributeIndex: number | undefined\n  ) {\n    this.__part = part;\n    this._$parent = parent;\n    this.__attributeIndex = attributeIndex;\n  }\n  /** @internal */\n  _$resolve(part: Part, props: Array<unknown>): unknown {\n    return this.update(part, props);\n  }\n\n  abstract render(...props: Array<unknown>): unknown;\n\n  update(_part: Part, props: Array<unknown>): unknown {\n    return this.render(...props);\n  }\n}\n"],"names":["PartType","ATTRIBUTE","CHILD","PROPERTY","BOOLEAN_ATTRIBUTE","EVENT","ELEMENT","directive","c","values","_$litDirective$","Directive","constructor","_partInfo","_$isConnected","this","_$parent","_$initialize","part","parent","attributeIndex","__part","__attributeIndex","_$resolve","props","update","_part","render"],"mappings":";;;;;MAyCaA,EAAW,CACtBC,UAAW,EACXC,MAAO,EACPC,SAAU,EACVC,kBAAmB,EACnBC,MAAO,EACPC,QAAS,GAoCEC,EACgBC,GAC3B,IAAIC,MAEFC,gBAAqBF,EACrBC,OAAAA,UAQkBE,EAkBpBC,YAAYC,IAGRC,WACF,OAAOC,KAAKC,KAASF,KAIvBG,KACEC,EACAC,EACAC,GAEAL,KAAKM,KAASH,EACdH,KAAKC,KAAWG,EAChBJ,KAAKO,KAAmBF,EAG1BG,KAAUL,EAAYM,GACpB,OAAOT,KAAKU,OAAOP,EAAMM,GAK3BC,OAAOC,EAAaF,GAClB,OAAOT,KAAKY,UAAUH"}
\ No newline at end of file
+{"version":3,"file":"directive.js","sources":["src/directive.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {Disconnectable, Part} from './lit-html.js';\n\nexport {\n  AttributePart,\n  BooleanAttributePart,\n  ChildPart,\n  ElementPart,\n  EventPart,\n  Part,\n  PropertyPart,\n} from './lit-html.js';\n\nexport interface DirectiveClass {\n  new (part: PartInfo): Directive;\n}\n\n/**\n * This utility type extracts the signature of a directive class's render()\n * method so we can use it for the type of the generated directive function.\n */\nexport type DirectiveParameters<C extends Directive> = Parameters<C['render']>;\n\n/**\n * A generated directive function doesn't evaluate the directive, but just\n * returns a DirectiveResult object that captures the arguments.\n */\nexport interface DirectiveResult<C extends DirectiveClass = DirectiveClass> {\n  /**\n   * This property needs to remain unminified.\n   * @internal */\n  ['_$litDirective$']: C;\n  /** @internal */\n  values: DirectiveParameters<InstanceType<C>>;\n}\n\nexport const PartType = {\n  ATTRIBUTE: 1,\n  CHILD: 2,\n  PROPERTY: 3,\n  BOOLEAN_ATTRIBUTE: 4,\n  EVENT: 5,\n  ELEMENT: 6,\n} as const;\n\nexport type PartType = typeof PartType[keyof typeof PartType];\n\nexport interface ChildPartInfo {\n  readonly type: typeof PartType.CHILD;\n}\n\nexport interface AttributePartInfo {\n  readonly type:\n    | typeof PartType.ATTRIBUTE\n    | typeof PartType.PROPERTY\n    | typeof PartType.BOOLEAN_ATTRIBUTE\n    | typeof PartType.EVENT;\n  readonly strings?: ReadonlyArray<string>;\n  readonly name: string;\n  readonly tagName: string;\n}\n\nexport interface ElementPartInfo {\n  readonly type: typeof PartType.ELEMENT;\n}\n\n/**\n * Information about the part a directive is bound to.\n *\n * This is useful for checking that a directive is attached to a valid part,\n * such as with directive that can only be used on attribute bindings.\n */\nexport type PartInfo = ChildPartInfo | AttributePartInfo | ElementPartInfo;\n\n/**\n * Creates a user-facing directive function from a Directive class. This\n * function has the same parameters as the directive's render() method.\n */\nexport const directive =\n  <C extends DirectiveClass>(c: C) =>\n  (...values: DirectiveParameters<InstanceType<C>>): DirectiveResult<C> => ({\n    // This property needs to remain unminified.\n    ['_$litDirective$']: c,\n    values,\n  });\n\n/**\n * Base class for creating custom directives. Users should extend this class,\n * implement `render` and/or `update`, and then pass their subclass to\n * `directive`.\n */\nexport abstract class Directive implements Disconnectable {\n  //@internal\n  __part!: Part;\n  //@internal\n  __attributeIndex: number | undefined;\n  //@internal\n  __directive?: Directive;\n\n  //@internal\n  _$parent!: Disconnectable;\n\n  // These will only exist on the AsyncDirective subclass\n  //@internal\n  _$disconnectableChildren?: Set<Disconnectable>;\n  // This property needs to remain unminified.\n  //@internal\n  ['_$notifyDirectiveConnectionChanged']?(isConnected: boolean): void;\n\n  constructor(_partInfo: PartInfo) {}\n\n  // See comment in Disconnectable interface for why this is a getter\n  get _$isConnected() {\n    return this._$parent._$isConnected;\n  }\n\n  /** @internal */\n  _$initialize(\n    part: Part,\n    parent: Disconnectable,\n    attributeIndex: number | undefined\n  ) {\n    this.__part = part;\n    this._$parent = parent;\n    this.__attributeIndex = attributeIndex;\n  }\n  /** @internal */\n  _$resolve(part: Part, props: Array<unknown>): unknown {\n    return this.update(part, props);\n  }\n\n  abstract render(...props: Array<unknown>): unknown;\n\n  update(_part: Part, props: Array<unknown>): unknown {\n    return this.render(...props);\n  }\n}\n"],"names":["PartType","ATTRIBUTE","CHILD","PROPERTY","BOOLEAN_ATTRIBUTE","EVENT","ELEMENT","directive","c","values","_$litDirective$","Directive","constructor","_partInfo","_$isConnected","this","_$parent","_$initialize","part","parent","attributeIndex","__part","__attributeIndex","_$resolve","props","update","_part","render"],"mappings":";;;;;AAyCa,MAAAA,EAAW,CACtBC,UAAW,EACXC,MAAO,EACPC,SAAU,EACVC,kBAAmB,EACnBC,MAAO,EACPC,QAAS,GAoCEC,EACgBC,GAC3B,IAAIC,KAAsE,CAExEC,gBAAqBF,EACrBC,iBAQkBE,EAkBpBC,YAAYC,GAAuB,CAG/BC,WACF,OAAOC,KAAKC,KAASF,IACtB,CAGDG,KACEC,EACAC,EACAC,GAEAL,KAAKM,KAASH,EACdH,KAAKC,KAAWG,EAChBJ,KAAKO,KAAmBF,CACzB,CAEDG,KAAUL,EAAYM,GACpB,OAAOT,KAAKU,OAAOP,EAAMM,EAC1B,CAIDC,OAAOC,EAAaF,GAClB,OAAOT,KAAKY,UAAUH,EACvB"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/directives/async-append.js b/front_end/third_party/lit-html/package/directives/async-append.js
index d0ff7a2c5788222a709b9e8601ff8aac0714d668..1f1dd0eea86d0215b4a9ee0c6551977ae487cb48 100644
--- a/front_end/third_party/lit-html/package/directives/async-append.js
+++ b/front_end/third_party/lit-html/package/directives/async-append.js
@@ -3,5 +3,5 @@ /**
  * @license
  * Copyright 2017 Google LLC
  * SPDX-License-Identifier: BSD-3-Clause
- */const c=r(class extends s{constructor(r){if(super(r),r.type!==e.CHILD)throw Error("asyncAppend can only be used in child expressions")}update(r,e){return this._$CX=r,super.update(r,e)}commitValue(r,e){0===e&&t(this._$CX);const s=o(this._$CX);i(s,r)}});export{c as asyncAppend};
+ */const c=r(class extends s{constructor(r){if(super(r),r.type!==e.CHILD)throw Error("asyncAppend can only be used in child expressions")}update(r,e){return this._$Ctt=r,super.update(r,e)}commitValue(r,e){0===e&&t(this._$Ctt);const s=o(this._$Ctt);i(s,r)}});export{c as asyncAppend};
 //# sourceMappingURL=async-append.js.map




diff --git a/front_end/third_party/lit-html/package/directives/async-append.js.map b/front_end/third_party/lit-html/package/directives/async-append.js.map
index 973eb53195ba5572cfd32fdec453105f1cd7b55f..2bbee46576731ce7d23db20d8f7d70bff05963c1 100644
--- a/front_end/third_party/lit-html/package/directives/async-append.js.map
+++ b/front_end/third_party/lit-html/package/directives/async-append.js.map
@@ -1 +1 @@
-{"version":3,"file":"async-append.js","sources":["../src/directives/async-append.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {ChildPart} from '../lit-html.js';\nimport {\n  directive,\n  DirectiveParameters,\n  PartInfo,\n  PartType,\n} from '../directive.js';\nimport {AsyncReplaceDirective} from './async-replace.js';\nimport {\n  clearPart,\n  insertPart,\n  setChildPartValue,\n} from '../directive-helpers.js';\n\nclass AsyncAppendDirective extends AsyncReplaceDirective {\n  private __childPart!: ChildPart;\n\n  // Override AsyncReplace to narrow the allowed part type to ChildPart only\n  constructor(partInfo: PartInfo) {\n    super(partInfo);\n    if (partInfo.type !== PartType.CHILD) {\n      throw new Error('asyncAppend can only be used in child expressions');\n    }\n  }\n\n  // Override AsyncReplace to save the part since we need to append into it\n  override update(part: ChildPart, params: DirectiveParameters<this>) {\n    this.__childPart = part;\n    return super.update(part, params);\n  }\n\n  // Override AsyncReplace to append rather than replace\n  protected override commitValue(value: unknown, index: number) {\n    // When we get the first value, clear the part. This lets the\n    // previous value display until we can replace it.\n    if (index === 0) {\n      clearPart(this.__childPart);\n    }\n    // Create and insert a new part and set its value to the next value\n    const newPart = insertPart(this.__childPart);\n    setChildPartValue(newPart, value);\n  }\n}\n\n/**\n * A directive that renders the items of an async iterable[1], appending new\n * values after previous values, similar to the built-in support for iterables.\n * This directive is usable only in child expressions.\n *\n * Async iterables are objects with a [Symbol.asyncIterator] method, which\n * returns an iterator who's `next()` method returns a Promise. When a new\n * value is available, the Promise resolves and the value is appended to the\n * Part controlled by the directive. If another value other than this\n * directive has been set on the Part, the iterable will no longer be listened\n * to and new values won't be written to the Part.\n *\n * [1]: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/for-await...of\n *\n * @param value An async iterable\n * @param mapper An optional function that maps from (value, index) to another\n *     value. Useful for generating templates for each item in the iterable.\n */\nexport const asyncAppend = directive(AsyncAppendDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {AsyncAppendDirective};\n"],"names":["asyncAppend","directive","AsyncReplaceDirective","constructor","partInfo","super","type","PartType","CHILD","Error","update","part","params","this","__childPart","commitValue","value","index","clearPart","newPart","insertPart","setChildPartValue"],"mappings":";;;;;SAoEaA,EAAcC,EAhD3B,cAAmCC,EAIjCC,YAAYC,GAEV,GADAC,MAAMD,GACFA,EAASE,OAASC,EAASC,MAC7B,MAAUC,MAAM,qDAKXC,OAAOC,EAAiBC,GAE/B,OADAC,KAAKC,KAAcH,EACZN,MAAMK,OAAOC,EAAMC,GAITG,YAAYC,EAAgBC,GAG/B,IAAVA,GACFC,EAAUL,KAAKC,MAGjB,MAAMK,EAAUC,EAAWP,KAAKC,MAChCO,EAAkBF,EAASH"}
\ No newline at end of file
+{"version":3,"file":"async-append.js","sources":["../src/directives/async-append.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {ChildPart} from '../lit-html.js';\nimport {\n  directive,\n  DirectiveParameters,\n  PartInfo,\n  PartType,\n} from '../directive.js';\nimport {AsyncReplaceDirective} from './async-replace.js';\nimport {\n  clearPart,\n  insertPart,\n  setChildPartValue,\n} from '../directive-helpers.js';\n\nclass AsyncAppendDirective extends AsyncReplaceDirective {\n  private __childPart!: ChildPart;\n\n  // Override AsyncReplace to narrow the allowed part type to ChildPart only\n  constructor(partInfo: PartInfo) {\n    super(partInfo);\n    if (partInfo.type !== PartType.CHILD) {\n      throw new Error('asyncAppend can only be used in child expressions');\n    }\n  }\n\n  // Override AsyncReplace to save the part since we need to append into it\n  override update(part: ChildPart, params: DirectiveParameters<this>) {\n    this.__childPart = part;\n    return super.update(part, params);\n  }\n\n  // Override AsyncReplace to append rather than replace\n  protected override commitValue(value: unknown, index: number) {\n    // When we get the first value, clear the part. This lets the\n    // previous value display until we can replace it.\n    if (index === 0) {\n      clearPart(this.__childPart);\n    }\n    // Create and insert a new part and set its value to the next value\n    const newPart = insertPart(this.__childPart);\n    setChildPartValue(newPart, value);\n  }\n}\n\n/**\n * A directive that renders the items of an async iterable[1], appending new\n * values after previous values, similar to the built-in support for iterables.\n * This directive is usable only in child expressions.\n *\n * Async iterables are objects with a [Symbol.asyncIterator] method, which\n * returns an iterator who's `next()` method returns a Promise. When a new\n * value is available, the Promise resolves and the value is appended to the\n * Part controlled by the directive. If another value other than this\n * directive has been set on the Part, the iterable will no longer be listened\n * to and new values won't be written to the Part.\n *\n * [1]: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/for-await...of\n *\n * @param value An async iterable\n * @param mapper An optional function that maps from (value, index) to another\n *     value. Useful for generating templates for each item in the iterable.\n */\nexport const asyncAppend = directive(AsyncAppendDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {AsyncAppendDirective};\n"],"names":["asyncAppend","directive","AsyncReplaceDirective","constructor","partInfo","super","type","PartType","CHILD","Error","update","part","params","this","__childPart","commitValue","value","index","clearPart","newPart","insertPart","setChildPartValue"],"mappings":";;;;;SAoEaA,EAAcC,EAhD3B,cAAmCC,EAIjCC,YAAYC,GAEV,GADAC,MAAMD,GACFA,EAASE,OAASC,EAASC,MAC7B,MAAUC,MAAM,oDAEnB,CAGQC,OAAOC,EAAiBC,GAE/B,OADAC,KAAKC,MAAcH,EACZN,MAAMK,OAAOC,EAAMC,EAC3B,CAGkBG,YAAYC,EAAgBC,GAG/B,IAAVA,GACFC,EAAUL,KAAKC,OAGjB,MAAMK,EAAUC,EAAWP,KAAKC,OAChCO,EAAkBF,EAASH,EAC5B"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/directives/async-replace.d.ts b/front_end/third_party/lit-html/package/directives/async-replace.d.ts
index 8023644c87ef68d31718788c8046b8503fb40a72..a033aa56dfda5ea480cfdca5dc5411a05bd9e70e 100644
--- a/front_end/third_party/lit-html/package/directives/async-replace.d.ts
+++ b/front_end/third_party/lit-html/package/directives/async-replace.d.ts
@@ -4,8 +4,8 @@  * Copyright 2017 Google LLC
  * SPDX-License-Identifier: BSD-3-Clause
  */
 import { ChildPart, noChange } from '../lit-html.js';
+ * Copyright 2017 Google LLC
 import { DirectiveParameters } from '../directive.js';
-import { AsyncDirective } from '../async-directive.js';
 declare type Mapper<T> = (v: T, index?: number) => unknown;
 export declare class AsyncReplaceDirective extends AsyncDirective {
     private __value?;




diff --git a/front_end/third_party/lit-html/package/directives/async-replace.d.ts.map b/front_end/third_party/lit-html/package/directives/async-replace.d.ts.map
index 2b39dc3d2e2cceda216f9ac85159605b03d519a9..a5e6430022ab1e73bf549c08b74a04d6d2b00b7c 100644
--- a/front_end/third_party/lit-html/package/directives/async-replace.d.ts.map
+++ b/front_end/third_party/lit-html/package/directives/async-replace.d.ts.map
@@ -1 +1 @@
-{"version":3,"file":"async-replace.d.ts","sourceRoot":"","sources":["../../src/directives/async-replace.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAC,SAAS,EAAE,QAAQ,EAAC,MAAM,gBAAgB,CAAC;AACnD,OAAO,EAAY,mBAAmB,EAAC,MAAM,iBAAiB,CAAC;AAC/D,OAAO,EAAC,cAAc,E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C,EAAE,MAAM,CAAC,CAAC,CAAC;IAI7C,MAAM,CACb,KAAK,EAAE,SAAS,EAChB,CAAC,KAAK,EAAE,MAAM,CAAC,EAAE,mBAAmB,CAAC,IAAI,CAAC;IAqD5C,SAAS,CAAC,WAAW,CAAC,KAAK,EAAE,OAAO,EAAE,MAAM,EAAE,MAAM;IAI3C,YAAY;IAKZ,WAAW;CAIrB;AAED;;;;;;;;;;;;;;;;;GAiBG;AACH,eAAO,MAAM,YAAY,mJAAmC,CAAC"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/directives/async-replace.js b/front_end/third_party/lit-html/package/directives/async-replace.js
index 53f22851c6af6cb342a67c4df86bb9e21b1dfa98..2004fa85246eece06298d8cfc9ca84a60bada31d 100644
--- a/front_end/third_party/lit-html/package/directives/async-replace.js
+++ b/front_end/third_party/lit-html/package/directives/async-replace.js
@@ -1,7 +1,7 @@
-import{noChange as t}from"../lit-html.js";import{directive as i}from"../directive.js";import{AsyncDirective as s}from"../async-directive.js";import{PseudoWeakRef as r,Pauser as e,forAwaitOf as n}from"./private-async-helpers.js";
+import{noChange as t}from"../lit-html.js";import{AsyncDirective as i}from"../async-directive.js";import{PseudoWeakRef as s,Pauser as r,forAwaitOf as e}from"./private-async-helpers.js";import{directive as n}from"../directive.js";
 /**
  * @license
  * Copyright 2017 Google LLC
  * SPDX-License-Identifier: BSD-3-Clause
- */class o extends s{constructor(){super(...arguments),this._$CG=new r(this),this._$CK=new e}render(i,s){return t}update(i,[s,r]){if(this.isConnected||this.disconnected(),s===this._$CJ)return;this._$CJ=s;let e=0;const{_$CG:o,_$CK:h}=this;return n(s,(async t=>{for(;h.get();)await h.get();const i=o.deref();if(void 0!==i){if(i._$CJ!==s)return!1;void 0!==r&&(t=r(t,e)),i.commitValue(t,e),e++}return!0})),t}commitValue(t,i){this.setValue(t)}disconnected(){this._$CG.disconnect(),this._$CK.pause()}reconnected(){this._$CG.reconnect(this),this._$CK.resume()}}const h=i(o);export{o as AsyncReplaceDirective,h as asyncReplace};
+ */class o extends i{constructor(){super(...arguments),this._$CK=new s(this),this._$CX=new r}render(i,s){return t}update(i,[s,r]){if(this.isConnected||this.disconnected(),s===this._$CJ)return;this._$CJ=s;let n=0;const{_$CK:o,_$CX:h}=this;return e(s,(async t=>{for(;h.get();)await h.get();const i=o.deref();if(void 0!==i){if(i._$CJ!==s)return!1;void 0!==r&&(t=r(t,n)),i.commitValue(t,n),n++}return!0})),t}commitValue(t,i){this.setValue(t)}disconnected(){this._$CK.disconnect(),this._$CX.pause()}reconnected(){this._$CK.reconnect(this),this._$CX.resume()}}const h=n(o);export{o as AsyncReplaceDirective,h as asyncReplace};
 //# sourceMappingURL=async-replace.js.map




diff --git a/front_end/third_party/lit-html/package/directives/async-replace.js.map b/front_end/third_party/lit-html/package/directives/async-replace.js.map
index 19d5333a9002a343d0cd48baef99c4add5b7dae0..f9f7c82f02ab6b3f6cf4462dde70f57b21233aae 100644
--- a/front_end/third_party/lit-html/package/directives/async-replace.js.map
+++ b/front_end/third_party/lit-html/package/directives/async-replace.js.map
@@ -1 +1 @@
-{"version":3,"file":"async-replace.js","sources":["../src/directives/async-replace.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {ChildPart, noChange} from '../lit-html.js';\nimport {directive, DirectiveParameters} from '../directive.js';\nimport {AsyncDirective} from '../async-directive.js';\nimport {Pauser, PseudoWeakRef, forAwaitOf} from './private-async-helpers.js';\n\ntype Mapper<T> = (v: T, index?: number) => unknown;\n\nexport class AsyncReplaceDirective extends AsyncDirective {\n  private __value?: AsyncIterable<unknown>;\n  private __weakThis = new PseudoWeakRef(this);\n  private __pauser = new Pauser();\n\n  // @ts-expect-error value not used, but we want a nice parameter for docs\n  // eslint-disable-next-line @typescript-eslint/no-unused-vars\n  render<T>(value: AsyncIterable<T>, _mapper?: Mapper<T>) {\n    return noChange;\n  }\n\n  override update(\n    _part: ChildPart,\n    [value, mapper]: DirectiveParameters<this>\n  ) {\n    // If our initial render occurs while disconnected, ensure that the pauser\n    // and weakThis are in the disconnected state\n    if (!this.isConnected) {\n      this.disconnected();\n    }\n    // If we've already set up this particular iterable, we don't need\n    // to do anything.\n    if (value === this.__value) {\n      return;\n    }\n    this.__value = value;\n    let i = 0;\n    const {__weakThis: weakThis, __pauser: pauser} = this;\n    // Note, the callback avoids closing over `this` so that the directive\n    // can be gc'ed before the promise resolves; instead `this` is retrieved\n    // from `weakThis`, which can break the hard reference in the closure when\n    // the directive disconnects\n    forAwaitOf(value, async (v: unknown) => {\n      // The while loop here handles the case that the connection state\n      // thrashes, causing the pauser to resume and then get re-paused\n      while (pauser.get()) {\n        await pauser.get();\n      }\n      // If the callback gets here and there is no `this`, it means that the\n      // directive has been disconnected and garbage collected and we don't\n      // need to do anything else\n      const _this = weakThis.deref();\n      if (_this !== undefined) {\n        // Check to make sure that value is the still the current value of\n        // the part, and if not bail because a new value owns this part\n        if (_this.__value !== value) {\n          return false;\n        }\n\n        // As a convenience, because functional-programming-style\n        // transforms of iterables and async iterables requires a library,\n        // we accept a mapper function. This is especially convenient for\n        // rendering a template for each item.\n        if (mapper !== undefined) {\n          v = mapper(v, i);\n        }\n\n        _this.commitValue(v, i);\n        i++;\n      }\n      return true;\n    });\n    return noChange;\n  }\n\n  // Override point for AsyncAppend to append rather than replace\n  protected commitValue(value: unknown, _index: number) {\n    this.setValue(value);\n  }\n\n  override disconnected() {\n    this.__weakThis.disconnect();\n    this.__pauser.pause();\n  }\n\n  override reconnected() {\n    this.__weakThis.reconnect(this);\n    this.__pauser.resume();\n  }\n}\n\n/**\n * A directive that renders the items of an async iterable[1], replacing\n * previous values with new values, so that only one value is ever rendered\n * at a time. This directive may be used in any expression type.\n *\n * Async iterables are objects with a `[Symbol.asyncIterator]` method, which\n * returns an iterator who's `next()` method returns a Promise. When a new\n * value is available, the Promise resolves and the value is rendered to the\n * Part controlled by the directive. If another value other than this\n * directive has been set on the Part, the iterable will no longer be listened\n * to and new values won't be written to the Part.\n *\n * [1]: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/for-await...of\n *\n * @param value An async iterable\n * @param mapper An optional function that maps from (value, index) to another\n *     value. Useful for generating templates for each item in the iterable.\n */\nexport const asyncReplace = directive(AsyncReplaceDirective);\n"],"names":["AsyncReplaceDirective","AsyncDirective","constructor","this","PseudoWeakRef","Pauser","render","value","_mapper","noChange","update","_part","mapper","isConnected","disconnected","__value","i","__weakThis","weakThis","__pauser","pauser","forAwaitOf","async","v","get","_this","deref","undefined","commitValue","_index","setValue","disconnect","pause","reconnected","reconnect","resume","asyncReplace","directive"],"mappings":";;;;;SAaaA,UAA8BC,EAA3CC,kCAEUC,UAAa,IAAIC,EAAcD,MAC/BA,UAAW,IAAIE,EAIvBC,OAAUC,EAAyBC,GACjC,OAAOC,EAGAC,OACPC,GACCJ,EAAOK,IASR,GALKT,KAAKU,aACRV,KAAKW,eAIHP,IAAUJ,KAAKY,KACjB,OAEFZ,KAAKY,KAAUR,EACf,IAAIS,EAAI,EACR,MAAOC,KAAYC,EAAUC,KAAUC,GAAUjB,KAmCjD,OA9BAkB,EAAWd,GAAOe,MAAOC,IAGvB,KAAOH,EAAOI,aACNJ,EAAOI,MAKf,MAAMC,EAAQP,EAASQ,QACvB,QAAcC,IAAVF,EAAqB,CAGvB,GAAIA,EAAMV,OAAYR,EACpB,OAAO,OAOMoB,IAAXf,IACFW,EAAIX,EAAOW,EAAGP,IAGhBS,EAAMG,YAAYL,EAAGP,GACrBA,IAEF,OAAO,KAEFP,EAICmB,YAAYrB,EAAgBsB,GACpC1B,KAAK2B,SAASvB,GAGPO,eACPX,KAAKc,KAAWc,aAChB5B,KAAKgB,KAASa,QAGPC,cACP9B,KAAKc,KAAWiB,UAAU/B,MAC1BA,KAAKgB,KAASgB,gBAsBLC,EAAeC,EAAUrC"}
\ No newline at end of file
+{"version":3,"file":"async-replace.js","sources":["../src/directives/async-replace.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {ChildPart, noChange} from '../lit-html.js';\nimport {\n  AsyncDirective,\n  directive,\n  DirectiveParameters,\n} from '../async-directive.js';\nimport {Pauser, PseudoWeakRef, forAwaitOf} from './private-async-helpers.js';\n\ntype Mapper<T> = (v: T, index?: number) => unknown;\n\nexport class AsyncReplaceDirective extends AsyncDirective {\n  private __value?: AsyncIterable<unknown>;\n  private __weakThis = new PseudoWeakRef(this);\n  private __pauser = new Pauser();\n\n  // @ts-expect-error value not used, but we want a nice parameter for docs\n  // eslint-disable-next-line @typescript-eslint/no-unused-vars\n  render<T>(value: AsyncIterable<T>, _mapper?: Mapper<T>) {\n    return noChange;\n  }\n\n  override update(\n    _part: ChildPart,\n    [value, mapper]: DirectiveParameters<this>\n  ) {\n    // If our initial render occurs while disconnected, ensure that the pauser\n    // and weakThis are in the disconnected state\n    if (!this.isConnected) {\n      this.disconnected();\n    }\n    // If we've already set up this particular iterable, we don't need\n    // to do anything.\n    if (value === this.__value) {\n      return;\n    }\n    this.__value = value;\n    let i = 0;\n    const {__weakThis: weakThis, __pauser: pauser} = this;\n    // Note, the callback avoids closing over `this` so that the directive\n    // can be gc'ed before the promise resolves; instead `this` is retrieved\n    // from `weakThis`, which can break the hard reference in the closure when\n    // the directive disconnects\n    forAwaitOf(value, async (v: unknown) => {\n      // The while loop here handles the case that the connection state\n      // thrashes, causing the pauser to resume and then get re-paused\n      while (pauser.get()) {\n        await pauser.get();\n      }\n      // If the callback gets here and there is no `this`, it means that the\n      // directive has been disconnected and garbage collected and we don't\n      // need to do anything else\n      const _this = weakThis.deref();\n      if (_this !== undefined) {\n        // Check to make sure that value is the still the current value of\n        // the part, and if not bail because a new value owns this part\n        if (_this.__value !== value) {\n          return false;\n        }\n\n        // As a convenience, because functional-programming-style\n        // transforms of iterables and async iterables requires a library,\n        // we accept a mapper function. This is especially convenient for\n        // rendering a template for each item.\n        if (mapper !== undefined) {\n          v = mapper(v, i);\n        }\n\n        _this.commitValue(v, i);\n        i++;\n      }\n      return true;\n    });\n    return noChange;\n  }\n\n  // Override point for AsyncAppend to append rather than replace\n  protected commitValue(value: unknown, _index: number) {\n    this.setValue(value);\n  }\n\n  override disconnected() {\n    this.__weakThis.disconnect();\n    this.__pauser.pause();\n  }\n\n  override reconnected() {\n    this.__weakThis.reconnect(this);\n    this.__pauser.resume();\n  }\n}\n\n/**\n * A directive that renders the items of an async iterable[1], replacing\n * previous values with new values, so that only one value is ever rendered\n * at a time. This directive may be used in any expression type.\n *\n * Async iterables are objects with a `[Symbol.asyncIterator]` method, which\n * returns an iterator who's `next()` method returns a Promise. When a new\n * value is available, the Promise resolves and the value is rendered to the\n * Part controlled by the directive. If another value other than this\n * directive has been set on the Part, the iterable will no longer be listened\n * to and new values won't be written to the Part.\n *\n * [1]: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/for-await...of\n *\n * @param value An async iterable\n * @param mapper An optional function that maps from (value, index) to another\n *     value. Useful for generating templates for each item in the iterable.\n */\nexport const asyncReplace = directive(AsyncReplaceDirective);\n"],"names":["AsyncReplaceDirective","AsyncDirective","constructor","this","__weakThis","PseudoWeakRef","__pauser","Pauser","render","value","_mapper","noChange","update","_part","mapper","isConnected","disconnected","__value","i","weakThis","pauser","forAwaitOf","async","v","get","_this","deref","undefined","commitValue","_index","setValue","disconnect","pause","reconnected","reconnect","resume","asyncReplace","directive"],"mappings":";;;;;GAgBM,MAAOA,UAA8BC,EAA3CC,kCAEUC,KAAAC,KAAa,IAAIC,EAAcF,MAC/BA,KAAAG,KAAW,IAAIC,CA4ExB,CAxECC,OAAUC,EAAyBC,GACjC,OAAOC,CACR,CAEQC,OACPC,GACCJ,EAAOK,IASR,GALKX,KAAKY,aACRZ,KAAKa,eAIHP,IAAUN,KAAKc,KACjB,OAEFd,KAAKc,KAAUR,EACf,IAAIS,EAAI,EACR,MAAOd,KAAYe,EAAUb,KAAUc,GAAUjB,KAmCjD,OA9BAkB,EAAWZ,GAAOa,MAAOC,IAGvB,KAAOH,EAAOI,aACNJ,EAAOI,MAKf,MAAMC,EAAQN,EAASO,QACvB,QAAcC,IAAVF,EAAqB,CAGvB,GAAIA,EAAMR,OAAYR,EACpB,OAAO,OAOMkB,IAAXb,IACFS,EAAIT,EAAOS,EAAGL,IAGhBO,EAAMG,YAAYL,EAAGL,GACrBA,GACD,CACD,OAAO,CAAI,IAENP,CACR,CAGSiB,YAAYnB,EAAgBoB,GACpC1B,KAAK2B,SAASrB,EACf,CAEQO,eACPb,KAAKC,KAAW2B,aAChB5B,KAAKG,KAAS0B,OACf,CAEQC,cACP9B,KAAKC,KAAW8B,UAAU/B,MAC1BA,KAAKG,KAAS6B,QACf,QAqBUC,EAAeC,EAAUrC"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/directives/cache.js b/front_end/third_party/lit-html/package/directives/cache.js
index eef14a353bd50b020b488faf2bef6eddee02e63e..9feae196384fb423dfdcaf2301539c9540518a72 100644
--- a/front_end/third_party/lit-html/package/directives/cache.js
+++ b/front_end/third_party/lit-html/package/directives/cache.js
@@ -3,5 +3,5 @@ /**
  * @license
  * Copyright 2017 Google LLC
  * SPDX-License-Identifier: BSD-3-Clause
- */const d=s(class extends e{constructor(t){super(t),this.tt=new WeakMap}render(t){return[t]}update(s,[e]){if(o(this.it)&&(!o(e)||this.it.strings!==e.strings)){const e=r(s).pop();let o=this.tt.get(this.it.strings);if(void 0===o){const s=document.createDocumentFragment();o=t(i,s),o.setConnected(!1),this.tt.set(this.it.strings,o)}h(o,[e]),n(o,void 0,e)}if(o(e)){if(!o(this.it)||this.it.strings!==e.strings){const t=this.tt.get(e.strings);if(void 0!==t){const i=r(t).pop();c(s),n(s,void 0,i),h(s,[i])}}this.it=e}else this.it=void 0;return this.render(e)}});export{d as cache};
+ */const d=s(class extends e{constructor(t){super(t),this.et=new WeakMap}render(t){return[t]}update(s,[e]){if(o(this.it)&&(!o(e)||this.it.strings!==e.strings)){const e=r(s).pop();let o=this.et.get(this.it.strings);if(void 0===o){const s=document.createDocumentFragment();o=t(i,s),o.setConnected(!1),this.et.set(this.it.strings,o)}h(o,[e]),n(o,void 0,e)}if(o(e)){if(!o(this.it)||this.it.strings!==e.strings){const t=this.et.get(e.strings);if(void 0!==t){const i=r(t).pop();c(s),n(s,void 0,i),h(s,[i])}}this.it=e}else this.it=void 0;return this.render(e)}});export{d as cache};
 //# sourceMappingURL=cache.js.map




diff --git a/front_end/third_party/lit-html/package/directives/cache.js.map b/front_end/third_party/lit-html/package/directives/cache.js.map
index c79fa3746c2ddec06c7dc955c20835798f174963..5f0b1ead1384c23fc6d32651163c75ddb29e8802 100644
--- a/front_end/third_party/lit-html/package/directives/cache.js.map
+++ b/front_end/third_party/lit-html/package/directives/cache.js.map
@@ -1 +1 @@
-{"version":3,"file":"cache.js","sources":["../src/directives/cache.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {\n  TemplateResult,\n  ChildPart,\n  RootPart,\n  render,\n  nothing,\n} from '../lit-html.js';\nimport {\n  directive,\n  Directive,\n  DirectiveParameters,\n  PartInfo,\n} from '../directive.js';\nimport {\n  clearPart,\n  getCommittedValue,\n  insertPart,\n  isTemplateResult,\n  setCommittedValue,\n} from '../directive-helpers.js';\n\nclass CacheDirective extends Directive {\n  private _templateCache = new WeakMap<TemplateStringsArray, RootPart>();\n  private _value?: TemplateResult;\n\n  constructor(partInfo: PartInfo) {\n    super(partInfo);\n  }\n\n  render(v: unknown) {\n    // Return an array of the value to induce lit-html to create a ChildPart\n    // for the value that we can move into the cache.\n    return [v];\n  }\n\n  override update(containerPart: ChildPart, [v]: DirectiveParameters<this>) {\n    // If the previous value is a TemplateResult and the new value is not,\n    // or is a different Template as the previous value, move the child part\n    // into the cache.\n    if (\n      isTemplateResult(this._value) &&\n      (!isTemplateResult(v) || this._value.strings !== v.strings)\n    ) {\n      // This is always an array because we return [v] in render()\n      const partValue = getCommittedValue(containerPart) as Array<ChildPart>;\n      const childPart = partValue.pop()!;\n      let cachedContainerPart = this._templateCache.get(this._value.strings);\n      if (cachedContainerPart === undefined) {\n        const fragment = document.createDocumentFragment();\n        cachedContainerPart = render(nothing, fragment);\n        cachedContainerPart.setConnected(false);\n        this._templateCache.set(this._value.strings, cachedContainerPart);\n      }\n      // Move into cache\n      setCommittedValue(cachedContainerPart, [childPart]);\n      insertPart(cachedContainerPart, undefined, childPart);\n    }\n    // If the new value is a TemplateResult and the previous value is not,\n    // or is a different Template as the previous value, restore the child\n    // part from the cache.\n    if (isTemplateResult(v)) {\n      if (!isTemplateResult(this._value) || this._value.strings !== v.strings) {\n        const cachedContainerPart = this._templateCache.get(v.strings);\n        if (cachedContainerPart !== undefined) {\n          // Move the cached part back into the container part value\n          const partValue = getCommittedValue(\n            cachedContainerPart\n          ) as Array<ChildPart>;\n          const cachedPart = partValue.pop()!;\n          // Move cached part back into DOM\n          clearPart(containerPart);\n          insertPart(containerPart, undefined, cachedPart);\n          setCommittedValue(containerPart, [cachedPart]);\n        }\n      }\n      this._value = v;\n    } else {\n      this._value = undefined;\n    }\n    return this.render(v);\n  }\n}\n\n/**\n * Enables fast switching between multiple templates by caching the DOM nodes\n * and TemplateInstances produced by the templates.\n *\n * Example:\n *\n * ```js\n * let checked = false;\n *\n * html`\n *   ${cache(checked ? html`input is checked` : html`input is not checked`)}\n * `\n * ```\n */\nexport const cache = directive(CacheDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {CacheDirective};\n"],"names":["cache","directive","Directive","constructor","partInfo","super","this","WeakMap","render","v","update","containerPart","isTemplateResult","_value","strings","childPart","getCommittedValue","pop","cachedContainerPart","_templateCache","get","undefined","fragment","document","createDocumentFragment","nothing","setConnected","set","setCommittedValue","insertPart","cachedPart","clearPart"],"mappings":";;;;;SAuGaA,EAAQC,EA5ErB,cAA6BC,EAI3BC,YAAYC,GACVC,MAAMD,GAJAE,QAAiB,IAAIC,QAO7BC,OAAOC,GAGL,MAAO,CAACA,GAGDC,OAAOC,GAA2BF,IAIzC,GACEG,EAAiBN,KAAKO,OACpBD,EAAiBH,IAAMH,KAAKO,GAAOC,UAAYL,EAAEK,SACnD,CAEA,MACMC,EADYC,EAAkBL,GACRM,MAC5B,IAAIC,EAAsBZ,KAAKa,GAAeC,IAAId,KAAKO,GAAOC,SAC9D,QAA4BO,IAAxBH,EAAmC,CACrC,MAAMI,EAAWC,SAASC,yBAC1BN,EAAsBV,EAAOiB,EAASH,GACtCJ,EAAoBQ,cAAa,GACjCpB,KAAKa,GAAeQ,IAAIrB,KAAKO,GAAOC,QAASI,GAG/CU,EAAkBV,EAAqB,CAACH,IACxCc,EAAWX,OAAqBG,EAAWN,GAK7C,GAAIH,EAAiBH,GAAI,CACvB,IAAKG,EAAiBN,KAAKO,KAAWP,KAAKO,GAAOC,UAAYL,EAAEK,QAAS,CACvE,MAAMI,EAAsBZ,KAAKa,GAAeC,IAAIX,EAAEK,SACtD,QAA4BO,IAAxBH,EAAmC,CAErC,MAGMY,EAHYd,EAChBE,GAE2BD,MAE7Bc,EAAUpB,GACVkB,EAAWlB,OAAeU,EAAWS,GACrCF,EAAkBjB,EAAe,CAACmB,KAGtCxB,KAAKO,GAASJ,OAEdH,KAAKO,QAASQ,EAEhB,OAAOf,KAAKE,OAAOC"}
\ No newline at end of file
+{"version":3,"file":"cache.js","sources":["../src/directives/cache.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {\n  TemplateResult,\n  ChildPart,\n  RootPart,\n  render,\n  nothing,\n} from '../lit-html.js';\nimport {\n  directive,\n  Directive,\n  DirectiveParameters,\n  PartInfo,\n} from '../directive.js';\nimport {\n  clearPart,\n  getCommittedValue,\n  insertPart,\n  isTemplateResult,\n  setCommittedValue,\n} from '../directive-helpers.js';\n\nclass CacheDirective extends Directive {\n  private _templateCache = new WeakMap<TemplateStringsArray, RootPart>();\n  private _value?: TemplateResult;\n\n  constructor(partInfo: PartInfo) {\n    super(partInfo);\n  }\n\n  render(v: unknown) {\n    // Return an array of the value to induce lit-html to create a ChildPart\n    // for the value that we can move into the cache.\n    return [v];\n  }\n\n  override update(containerPart: ChildPart, [v]: DirectiveParameters<this>) {\n    // If the previous value is a TemplateResult and the new value is not,\n    // or is a different Template as the previous value, move the child part\n    // into the cache.\n    if (\n      isTemplateResult(this._value) &&\n      (!isTemplateResult(v) || this._value.strings !== v.strings)\n    ) {\n      // This is always an array because we return [v] in render()\n      const partValue = getCommittedValue(containerPart) as Array<ChildPart>;\n      const childPart = partValue.pop()!;\n      let cachedContainerPart = this._templateCache.get(this._value.strings);\n      if (cachedContainerPart === undefined) {\n        const fragment = document.createDocumentFragment();\n        cachedContainerPart = render(nothing, fragment);\n        cachedContainerPart.setConnected(false);\n        this._templateCache.set(this._value.strings, cachedContainerPart);\n      }\n      // Move into cache\n      setCommittedValue(cachedContainerPart, [childPart]);\n      insertPart(cachedContainerPart, undefined, childPart);\n    }\n    // If the new value is a TemplateResult and the previous value is not,\n    // or is a different Template as the previous value, restore the child\n    // part from the cache.\n    if (isTemplateResult(v)) {\n      if (!isTemplateResult(this._value) || this._value.strings !== v.strings) {\n        const cachedContainerPart = this._templateCache.get(v.strings);\n        if (cachedContainerPart !== undefined) {\n          // Move the cached part back into the container part value\n          const partValue = getCommittedValue(\n            cachedContainerPart\n          ) as Array<ChildPart>;\n          const cachedPart = partValue.pop()!;\n          // Move cached part back into DOM\n          clearPart(containerPart);\n          insertPart(containerPart, undefined, cachedPart);\n          setCommittedValue(containerPart, [cachedPart]);\n        }\n      }\n      this._value = v;\n    } else {\n      this._value = undefined;\n    }\n    return this.render(v);\n  }\n}\n\n/**\n * Enables fast switching between multiple templates by caching the DOM nodes\n * and TemplateInstances produced by the templates.\n *\n * Example:\n *\n * ```js\n * let checked = false;\n *\n * html`\n *   ${cache(checked ? html`input is checked` : html`input is not checked`)}\n * `\n * ```\n */\nexport const cache = directive(CacheDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {CacheDirective};\n"],"names":["cache","directive","Directive","constructor","partInfo","super","this","_templateCache","WeakMap","render","v","update","containerPart","isTemplateResult","_value","strings","childPart","getCommittedValue","pop","cachedContainerPart","get","undefined","fragment","document","createDocumentFragment","nothing","setConnected","set","setCommittedValue","insertPart","cachedPart","clearPart"],"mappings":";;;;;SAuGaA,EAAQC,EA5ErB,cAA6BC,EAI3BC,YAAYC,GACVC,MAAMD,GAJAE,KAAAC,GAAiB,IAAIC,OAK5B,CAEDC,OAAOC,GAGL,MAAO,CAACA,EACT,CAEQC,OAAOC,GAA2BF,IAIzC,GACEG,EAAiBP,KAAKQ,OACpBD,EAAiBH,IAAMJ,KAAKQ,GAAOC,UAAYL,EAAEK,SACnD,CAEA,MACMC,EADYC,EAAkBL,GACRM,MAC5B,IAAIC,EAAsBb,KAAKC,GAAea,IAAId,KAAKQ,GAAOC,SAC9D,QAA4BM,IAAxBF,EAAmC,CACrC,MAAMG,EAAWC,SAASC,yBAC1BL,EAAsBV,EAAOgB,EAASH,GACtCH,EAAoBO,cAAa,GACjCpB,KAAKC,GAAeoB,IAAIrB,KAAKQ,GAAOC,QAASI,EAC9C,CAEDS,EAAkBT,EAAqB,CAACH,IACxCa,EAAWV,OAAqBE,EAAWL,EAC5C,CAID,GAAIH,EAAiBH,GAAI,CACvB,IAAKG,EAAiBP,KAAKQ,KAAWR,KAAKQ,GAAOC,UAAYL,EAAEK,QAAS,CACvE,MAAMI,EAAsBb,KAAKC,GAAea,IAAIV,EAAEK,SACtD,QAA4BM,IAAxBF,EAAmC,CAErC,MAGMW,EAHYb,EAChBE,GAE2BD,MAE7Ba,EAAUnB,GACViB,EAAWjB,OAAeS,EAAWS,GACrCF,EAAkBhB,EAAe,CAACkB,GACnC,CACF,CACDxB,KAAKQ,GAASJ,CACf,MACCJ,KAAKQ,QAASO,EAEhB,OAAOf,KAAKG,OAAOC,EACpB"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/directives/choose.js.map b/front_end/third_party/lit-html/package/directives/choose.js.map
index e0e9f909372466fd0f108e0d8b2df6dc8e4e87e4..88834c16e333b8d077ceca197906f782a0919076 100644
--- a/front_end/third_party/lit-html/package/directives/choose.js.map
+++ b/front_end/third_party/lit-html/package/directives/choose.js.map
@@ -1 +1 @@
-{"version":3,"file":"choose.js","sources":["../src/directives/choose.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n/**\n * Chooses and evaluates a template function from a list based on matching\n * the given `value` to a case.\n *\n * Cases are structured as `[caseValue, func]`. `value` is matched to\n * `caseValue` by strict equality. The first match is selected. Case values\n * can be of any type including primitives, objects, and symbols.\n *\n * This is similar to a switch statement, but as an expression and without\n * fallthrough.\n *\n * @example\n *\n * ```ts\n * render() {\n *   return html`\n *     ${choose(this.section, [\n *       ['home', () => html`<h1>Home</h1>`],\n *       ['about', () => html`<h1>About</h1>`]\n *     ],\n *     () => html`<h1>Error</h1>`)}\n *   `;\n * }\n * ```\n */\nexport const choose = <T, V>(\n  value: T,\n  cases: Array<[T, () => V]>,\n  defaultCase?: () => V\n) => {\n  for (const c of cases) {\n    const caseValue = c[0];\n    if (caseValue === value) {\n      const fn = c[1];\n      return fn();\n    }\n  }\n  return defaultCase?.();\n};\n"],"names":["choose","value","cases","defaultCase","c","fn"],"mappings":";;;;;MA+BaA,EAAS,CACpBC,EACAC,EACAC,KAEA,IAAK,MAAMC,KAAKF,EAEd,GADkBE,EAAE,KACFH,EAEhB,OAAOI,EADID,EAAE,MAIjB,OAAOD,MAAAA,SAAAA"}
\ No newline at end of file
+{"version":3,"file":"choose.js","sources":["../src/directives/choose.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n/**\n * Chooses and evaluates a template function from a list based on matching\n * the given `value` to a case.\n *\n * Cases are structured as `[caseValue, func]`. `value` is matched to\n * `caseValue` by strict equality. The first match is selected. Case values\n * can be of any type including primitives, objects, and symbols.\n *\n * This is similar to a switch statement, but as an expression and without\n * fallthrough.\n *\n * @example\n *\n * ```ts\n * render() {\n *   return html`\n *     ${choose(this.section, [\n *       ['home', () => html`<h1>Home</h1>`],\n *       ['about', () => html`<h1>About</h1>`]\n *     ],\n *     () => html`<h1>Error</h1>`)}\n *   `;\n * }\n * ```\n */\nexport const choose = <T, V>(\n  value: T,\n  cases: Array<[T, () => V]>,\n  defaultCase?: () => V\n) => {\n  for (const c of cases) {\n    const caseValue = c[0];\n    if (caseValue === value) {\n      const fn = c[1];\n      return fn();\n    }\n  }\n  return defaultCase?.();\n};\n"],"names":["choose","value","cases","defaultCase","c","fn"],"mappings":";;;;;AA+Ba,MAAAA,EAAS,CACpBC,EACAC,EACAC,KAEA,IAAK,MAAMC,KAAKF,EAEd,GADkBE,EAAE,KACFH,EAEhB,OAAOI,EADID,EAAE,MAIjB,OAAOD,aAAA,EAAAA,GAAe"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/directives/class-map.js b/front_end/third_party/lit-html/package/directives/class-map.js
index eb4b43fb0ff17a37ae7ec6f911fe513f8c7e7c5b..427d0485997231363cdfe58f3c9425839972a8d3 100644
--- a/front_end/third_party/lit-html/package/directives/class-map.js
+++ b/front_end/third_party/lit-html/package/directives/class-map.js
@@ -3,5 +3,5 @@ /**
  * @license
  * Copyright 2018 Google LLC
  * SPDX-License-Identifier: BSD-3-Clause
- */const o=i(class extends s{constructor(t){var i;if(super(t),t.type!==r.ATTRIBUTE||"class"!==t.name||(null===(i=t.strings)||void 0===i?void 0:i.length)>2)throw Error("`classMap()` can only be used in the `class` attribute and must be the only part in the attribute.")}render(t){return" "+Object.keys(t).filter((i=>t[i])).join(" ")+" "}update(i,[s]){var r,o;if(void 0===this.et){this.et=new Set,void 0!==i.strings&&(this.st=new Set(i.strings.join(" ").split(/\s/).filter((t=>""!==t))));for(const t in s)s[t]&&!(null===(r=this.st)||void 0===r?void 0:r.has(t))&&this.et.add(t);return this.render(s)}const e=i.element.classList;this.et.forEach((t=>{t in s||(e.remove(t),this.et.delete(t))}));for(const t in s){const i=!!s[t];i===this.et.has(t)||(null===(o=this.st)||void 0===o?void 0:o.has(t))||(i?(e.add(t),this.et.add(t)):(e.remove(t),this.et.delete(t)))}return t}});export{o as classMap};
+ */const o=i(class extends s{constructor(t){var i;if(super(t),t.type!==r.ATTRIBUTE||"class"!==t.name||(null===(i=t.strings)||void 0===i?void 0:i.length)>2)throw Error("`classMap()` can only be used in the `class` attribute and must be the only part in the attribute.")}render(t){return" "+Object.keys(t).filter((i=>t[i])).join(" ")+" "}update(i,[s]){var r,o;if(void 0===this.nt){this.nt=new Set,void 0!==i.strings&&(this.st=new Set(i.strings.join(" ").split(/\s/).filter((t=>""!==t))));for(const t in s)s[t]&&!(null===(r=this.st)||void 0===r?void 0:r.has(t))&&this.nt.add(t);return this.render(s)}const e=i.element.classList;this.nt.forEach((t=>{t in s||(e.remove(t),this.nt.delete(t))}));for(const t in s){const i=!!s[t];i===this.nt.has(t)||(null===(o=this.st)||void 0===o?void 0:o.has(t))||(i?(e.add(t),this.nt.add(t)):(e.remove(t),this.nt.delete(t)))}return t}});export{o as classMap};
 //# sourceMappingURL=class-map.js.map




diff --git a/front_end/third_party/lit-html/package/directives/class-map.js.map b/front_end/third_party/lit-html/package/directives/class-map.js.map
index 239bc5aab0e157d15428a8e3b974a383fef51268..65c8959665a9ba5ae630d9fd2b60885f4acbd33c 100644
--- a/front_end/third_party/lit-html/package/directives/class-map.js.map
+++ b/front_end/third_party/lit-html/package/directives/class-map.js.map
@@ -1 +1 @@
-{"version":3,"file":"class-map.js","sources":["../src/directives/class-map.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2018 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {AttributePart, noChange} from '../lit-html.js';\nimport {\n  directive,\n  Directive,\n  DirectiveParameters,\n  PartInfo,\n  PartType,\n} from '../directive.js';\n\n/**\n * A key-value set of class names to truthy values.\n */\nexport interface ClassInfo {\n  readonly [name: string]: string | boolean | number;\n}\n\nclass ClassMapDirective extends Directive {\n  /**\n   * Stores the ClassInfo object applied to a given AttributePart.\n   * Used to unset existing values when a new ClassInfo object is applied.\n   */\n  private _previousClasses?: Set<string>;\n  private _staticClasses?: Set<string>;\n\n  constructor(partInfo: PartInfo) {\n    super(partInfo);\n    if (\n      partInfo.type !== PartType.ATTRIBUTE ||\n      partInfo.name !== 'class' ||\n      (partInfo.strings?.length as number) > 2\n    ) {\n      throw new Error(\n        '`classMap()` can only be used in the `class` attribute ' +\n          'and must be the only part in the attribute.'\n      );\n    }\n  }\n\n  render(classInfo: ClassInfo) {\n    // Add spaces to ensure separation from static classes\n    return (\n      ' ' +\n      Object.keys(classInfo)\n        .filter((key) => classInfo[key])\n        .join(' ') +\n      ' '\n    );\n  }\n\n  override update(part: AttributePart, [classInfo]: DirectiveParameters<this>) {\n    // Remember dynamic classes on the first render\n    if (this._previousClasses === undefined) {\n      this._previousClasses = new Set();\n      if (part.strings !== undefined) {\n        this._staticClasses = new Set(\n          part.strings\n            .join(' ')\n            .split(/\\s/)\n            .filter((s) => s !== '')\n        );\n      }\n      for (const name in classInfo) {\n        if (classInfo[name] && !this._staticClasses?.has(name)) {\n          this._previousClasses.add(name);\n        }\n      }\n      return this.render(classInfo);\n    }\n\n    const classList = part.element.classList;\n\n    // Remove old classes that no longer apply\n    // We use forEach() instead of for-of so that we don't require down-level\n    // iteration.\n    this._previousClasses.forEach((name) => {\n      if (!(name in classInfo)) {\n        classList.remove(name);\n        this._previousClasses!.delete(name);\n      }\n    });\n\n    // Add or remove classes based on their classMap value\n    for (const name in classInfo) {\n      // We explicitly want a loose truthy check of `value` because it seems\n      // more convenient that '' and 0 are skipped.\n      const value = !!classInfo[name];\n      if (\n        value !== this._previousClasses.has(name) &&\n        !this._staticClasses?.has(name)\n      ) {\n        if (value) {\n          classList.add(name);\n          this._previousClasses.add(name);\n        } else {\n          classList.remove(name);\n          this._previousClasses.delete(name);\n        }\n      }\n    }\n    return noChange;\n  }\n}\n\n/**\n * A directive that applies dynamic CSS classes.\n *\n * This must be used in the `class` attribute and must be the only part used in\n * the attribute. It takes each property in the `classInfo` argument and adds\n * the property name to the element's `classList` if the property value is\n * truthy; if the property value is falsey, the property name is removed from\n * the element's `class`.\n *\n * For example `{foo: bar}` applies the class `foo` if the value of `bar` is\n * truthy.\n *\n * @param classInfo\n */\nexport const classMap = directive(ClassMapDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {ClassMapDirective};\n"],"names":["classMap","directive","Directive","constructor","partInfo","super","type","PartType","ATTRIBUTE","name","strings","length","Error","render","classInfo","Object","keys","filter","key","join","update","part","undefined","this","_previousClasses","Set","_staticClasses","split","s","has","add","classList","element","forEach","remove","delete","value","noChange"],"mappings":";;;;;SA2HaA,EAAWC,EArGxB,cAAgCC,EAQ9BC,YAAYC,SAEV,GADAC,MAAMD,GAEJA,EAASE,OAASC,EAASC,WACT,UAAlBJ,EAASK,iBACRL,EAASM,8BAASC,QAAoB,EAEvC,MAAUC,MACR,sGAMNC,OAAOC,GAEL,MACE,IACAC,OAAOC,KAAKF,GACTG,QAAQC,GAAQJ,EAAUI,KAC1BC,KAAK,KACR,IAIKC,OAAOC,GAAsBP,YAEpC,QAA8BQ,IAA1BC,KAAKC,GAAgC,CACvCD,KAAKC,GAAmB,IAAIC,SACPH,IAAjBD,EAAKX,UACPa,KAAKG,GAAiB,IAAID,IACxBJ,EAAKX,QACFS,KAAK,KACLQ,MAAM,MACNV,QAAQW,GAAY,KAANA,MAGrB,IAAK,MAAMnB,KAAQK,EACbA,EAAUL,gBAAUc,KAAKG,yBAAgBG,IAAIpB,KAC/Cc,KAAKC,GAAiBM,IAAIrB,GAG9B,OAAOc,KAAKV,OAAOC,GAGrB,MAAMiB,EAAYV,EAAKW,QAAQD,UAK/BR,KAAKC,GAAiBS,SAASxB,IACvBA,KAAQK,IACZiB,EAAUG,OAAOzB,GACjBc,KAAKC,GAAkBW,OAAO1B,OAKlC,IAAK,MAAMA,KAAQK,EAAW,CAG5B,MAAMsB,IAAUtB,EAAUL,GAExB2B,IAAUb,KAAKC,GAAiBK,IAAIpB,eACnCc,KAAKG,yBAAgBG,IAAIpB,MAEtB2B,GACFL,EAAUD,IAAIrB,GACdc,KAAKC,GAAiBM,IAAIrB,KAE1BsB,EAAUG,OAAOzB,GACjBc,KAAKC,GAAiBW,OAAO1B,KAInC,OAAO4B"}
\ No newline at end of file
+{"version":3,"file":"class-map.js","sources":["../src/directives/class-map.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2018 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {AttributePart, noChange} from '../lit-html.js';\nimport {\n  directive,\n  Directive,\n  DirectiveParameters,\n  PartInfo,\n  PartType,\n} from '../directive.js';\n\n/**\n * A key-value set of class names to truthy values.\n */\nexport interface ClassInfo {\n  readonly [name: string]: string | boolean | number;\n}\n\nclass ClassMapDirective extends Directive {\n  /**\n   * Stores the ClassInfo object applied to a given AttributePart.\n   * Used to unset existing values when a new ClassInfo object is applied.\n   */\n  private _previousClasses?: Set<string>;\n  private _staticClasses?: Set<string>;\n\n  constructor(partInfo: PartInfo) {\n    super(partInfo);\n    if (\n      partInfo.type !== PartType.ATTRIBUTE ||\n      partInfo.name !== 'class' ||\n      (partInfo.strings?.length as number) > 2\n    ) {\n      throw new Error(\n        '`classMap()` can only be used in the `class` attribute ' +\n          'and must be the only part in the attribute.'\n      );\n    }\n  }\n\n  render(classInfo: ClassInfo) {\n    // Add spaces to ensure separation from static classes\n    return (\n      ' ' +\n      Object.keys(classInfo)\n        .filter((key) => classInfo[key])\n        .join(' ') +\n      ' '\n    );\n  }\n\n  override update(part: AttributePart, [classInfo]: DirectiveParameters<this>) {\n    // Remember dynamic classes on the first render\n    if (this._previousClasses === undefined) {\n      this._previousClasses = new Set();\n      if (part.strings !== undefined) {\n        this._staticClasses = new Set(\n          part.strings\n            .join(' ')\n            .split(/\\s/)\n            .filter((s) => s !== '')\n        );\n      }\n      for (const name in classInfo) {\n        if (classInfo[name] && !this._staticClasses?.has(name)) {\n          this._previousClasses.add(name);\n        }\n      }\n      return this.render(classInfo);\n    }\n\n    const classList = part.element.classList;\n\n    // Remove old classes that no longer apply\n    // We use forEach() instead of for-of so that we don't require down-level\n    // iteration.\n    this._previousClasses.forEach((name) => {\n      if (!(name in classInfo)) {\n        classList.remove(name);\n        this._previousClasses!.delete(name);\n      }\n    });\n\n    // Add or remove classes based on their classMap value\n    for (const name in classInfo) {\n      // We explicitly want a loose truthy check of `value` because it seems\n      // more convenient that '' and 0 are skipped.\n      const value = !!classInfo[name];\n      if (\n        value !== this._previousClasses.has(name) &&\n        !this._staticClasses?.has(name)\n      ) {\n        if (value) {\n          classList.add(name);\n          this._previousClasses.add(name);\n        } else {\n          classList.remove(name);\n          this._previousClasses.delete(name);\n        }\n      }\n    }\n    return noChange;\n  }\n}\n\n/**\n * A directive that applies dynamic CSS classes.\n *\n * This must be used in the `class` attribute and must be the only part used in\n * the attribute. It takes each property in the `classInfo` argument and adds\n * the property name to the element's `classList` if the property value is\n * truthy; if the property value is falsey, the property name is removed from\n * the element's `class`.\n *\n * For example `{foo: bar}` applies the class `foo` if the value of `bar` is\n * truthy.\n *\n * @param classInfo\n */\nexport const classMap = directive(ClassMapDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {ClassMapDirective};\n"],"names":["classMap","directive","Directive","constructor","partInfo","super","type","PartType","ATTRIBUTE","name","_a","strings","length","Error","render","classInfo","Object","keys","filter","key","join","update","part","undefined","this","_previousClasses","Set","_staticClasses","split","s","has","add","classList","element","forEach","remove","delete","value","_b","noChange"],"mappings":";;;;;SA2HaA,EAAWC,EArGxB,cAAgCC,EAQ9BC,YAAYC,SAEV,GADAC,MAAMD,GAEJA,EAASE,OAASC,EAASC,WACT,UAAlBJ,EAASK,eACRC,EAAAN,EAASO,8BAASC,QAAoB,EAEvC,MAAUC,MACR,qGAIL,CAEDC,OAAOC,GAEL,MACE,IACAC,OAAOC,KAAKF,GACTG,QAAQC,GAAQJ,EAAUI,KAC1BC,KAAK,KACR,GAEH,CAEQC,OAAOC,GAAsBP,YAEpC,QAA8BQ,IAA1BC,KAAKC,GAAgC,CACvCD,KAAKC,GAAmB,IAAIC,SACPH,IAAjBD,EAAKX,UACPa,KAAKG,GAAiB,IAAID,IACxBJ,EAAKX,QACFS,KAAK,KACLQ,MAAM,MACNV,QAAQW,GAAY,KAANA,MAGrB,IAAK,MAAMpB,KAAQM,EACbA,EAAUN,MAA+B,QAArBC,EAAAc,KAAKG,UAAgB,IAAAjB,OAAA,EAAAA,EAAAoB,IAAIrB,KAC/Ce,KAAKC,GAAiBM,IAAItB,GAG9B,OAAOe,KAAKV,OAAOC,EACpB,CAED,MAAMiB,EAAYV,EAAKW,QAAQD,UAK/BR,KAAKC,GAAiBS,SAASzB,IACvBA,KAAQM,IACZiB,EAAUG,OAAO1B,GACjBe,KAAKC,GAAkBW,OAAO3B,GAC/B,IAIH,IAAK,MAAMA,KAAQM,EAAW,CAG5B,MAAMsB,IAAUtB,EAAUN,GAExB4B,IAAUb,KAAKC,GAAiBK,IAAIrB,KACd,QAArB6B,EAAAd,KAAKG,UAAgB,IAAAW,OAAA,EAAAA,EAAAR,IAAIrB,MAEtB4B,GACFL,EAAUD,IAAItB,GACde,KAAKC,GAAiBM,IAAItB,KAE1BuB,EAAUG,OAAO1B,GACjBe,KAAKC,GAAiBW,OAAO3B,IAGlC,CACD,OAAO8B,CACR"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/directives/guard.js b/front_end/third_party/lit-html/package/directives/guard.js
index 02cf72d2c27909df78d48f8da15cd34326d1e42b..3813f9ef4262ee078451a0dfbe78dc3bd8336644 100644
--- a/front_end/third_party/lit-html/package/directives/guard.js
+++ b/front_end/third_party/lit-html/package/directives/guard.js
@@ -4,5 +4,5 @@  * @license
  * Copyright 2018 Google LLC
  * SPDX-License-Identifier: BSD-3-Clause
  */
-const e={},i=t(class extends s{constructor(){super(...arguments),this.nt=e}render(r,t){return t()}update(t,[s,e]){if(Array.isArray(s)){if(Array.isArray(this.nt)&&this.nt.length===s.length&&s.every(((r,t)=>r===this.nt[t])))return r}else if(this.nt===s)return r;return this.nt=Array.isArray(s)?Array.from(s):s,this.render(s,e)}});export{i as guard};
+const e={},i=t(class extends s{constructor(){super(...arguments),this.ot=e}render(r,t){return t()}update(t,[s,e]){if(Array.isArray(s)){if(Array.isArray(this.ot)&&this.ot.length===s.length&&s.every(((r,t)=>r===this.ot[t])))return r}else if(this.ot===s)return r;return this.ot=Array.isArray(s)?Array.from(s):s,this.render(s,e)}});export{i as guard};
 //# sourceMappingURL=guard.js.map




diff --git a/front_end/third_party/lit-html/package/directives/guard.js.map b/front_end/third_party/lit-html/package/directives/guard.js.map
index 3f49fb915a9e370748eadbfb9d644cd6af016599..8b6d8efc93fc0c41078a7aeed41dac71a8a1b4cb 100644
--- a/front_end/third_party/lit-html/package/directives/guard.js.map
+++ b/front_end/third_party/lit-html/package/directives/guard.js.map
@@ -1 +1 @@
-{"version":3,"file":"guard.js","sources":["../src/directives/guard.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2018 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {noChange, Part} from '../lit-html.js';\nimport {directive, Directive, DirectiveParameters} from '../directive.js';\n\n// A sentinal that indicates guard() hasn't rendered anything yet\nconst initialValue = {};\n\nclass GuardDirective extends Directive {\n  private _previousValue: unknown = initialValue;\n\n  render(_value: unknown, f: () => unknown) {\n    return f();\n  }\n\n  override update(_part: Part, [value, f]: DirectiveParameters<this>) {\n    if (Array.isArray(value)) {\n      // Dirty-check arrays by item\n      if (\n        Array.isArray(this._previousValue) &&\n        this._previousValue.length === value.length &&\n        value.every((v, i) => v === (this._previousValue as Array<unknown>)[i])\n      ) {\n        return noChange;\n      }\n    } else if (this._previousValue === value) {\n      // Dirty-check non-arrays by identity\n      return noChange;\n    }\n\n    // Copy the value if it's an array so that if it's mutated we don't forget\n    // what the previous values were.\n    this._previousValue = Array.isArray(value) ? Array.from(value) : value;\n    const r = this.render(value, f);\n    return r;\n  }\n}\n\n/**\n * Prevents re-render of a template function until a single value or an array of\n * values changes.\n *\n * Values are checked against previous values with strict equality (`===`), and\n * so the check won't detect nested property changes inside objects or arrays.\n * Arrays values have each item checked against the previous value at the same\n * index with strict equality. Nested arrays are also checked only by strict\n * equality.\n *\n * Example:\n *\n * ```js\n * html`\n *   <div>\n *     ${guard([user.id, company.id], () => html`...`)}\n *   </div>\n * `\n * ```\n *\n * In this case, the template only rerenders if either `user.id` or `company.id`\n * changes.\n *\n * guard() is useful with immutable data patterns, by preventing expensive work\n * until data updates.\n *\n * Example:\n *\n * ```js\n * html`\n *   <div>\n *     ${guard([immutableItems], () => immutableItems.map(i => html`${i}`))}\n *   </div>\n * `\n * ```\n *\n * In this case, items are mapped over only when the array reference changes.\n *\n * @param value the value to check before re-rendering\n * @param f the template function\n */\nexport const guard = directive(GuardDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {GuardDirective};\n"],"names":["initialValue","guard","directive","Directive","constructor","this","render","_value","f","update","_part","value","Array","isArray","_previousValue","length","every","v","i","noChange","from"],"mappings":";;;;;;AAUA,MAAMA,EAAe,GAyERC,EAAQC,EAvErB,cAA6BC,EAA7BC,kCACUC,QAA0BL,EAElCM,OAAOC,EAAiBC,GACtB,OAAOA,IAGAC,OAAOC,GAAcC,EAAOH,IACnC,GAAII,MAAMC,QAAQF,IAEhB,GACEC,MAAMC,QAAQR,KAAKS,KACnBT,KAAKS,GAAeC,SAAWJ,EAAMI,QACrCJ,EAAMK,OAAM,CAACC,EAAGC,IAAMD,IAAOZ,KAAKS,GAAkCI,KAEpE,OAAOC,OAEJ,GAAId,KAAKS,KAAmBH,EAEjC,OAAOQ,EAOT,OAFAd,KAAKS,GAAiBF,MAAMC,QAAQF,GAASC,MAAMQ,KAAKT,GAASA,EACvDN,KAAKC,OAAOK,EAAOH"}
\ No newline at end of file
+{"version":3,"file":"guard.js","sources":["../src/directives/guard.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2018 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {noChange, Part} from '../lit-html.js';\nimport {directive, Directive, DirectiveParameters} from '../directive.js';\n\n// A sentinal that indicates guard() hasn't rendered anything yet\nconst initialValue = {};\n\nclass GuardDirective extends Directive {\n  private _previousValue: unknown = initialValue;\n\n  render(_value: unknown, f: () => unknown) {\n    return f();\n  }\n\n  override update(_part: Part, [value, f]: DirectiveParameters<this>) {\n    if (Array.isArray(value)) {\n      // Dirty-check arrays by item\n      if (\n        Array.isArray(this._previousValue) &&\n        this._previousValue.length === value.length &&\n        value.every((v, i) => v === (this._previousValue as Array<unknown>)[i])\n      ) {\n        return noChange;\n      }\n    } else if (this._previousValue === value) {\n      // Dirty-check non-arrays by identity\n      return noChange;\n    }\n\n    // Copy the value if it's an array so that if it's mutated we don't forget\n    // what the previous values were.\n    this._previousValue = Array.isArray(value) ? Array.from(value) : value;\n    const r = this.render(value, f);\n    return r;\n  }\n}\n\n/**\n * Prevents re-render of a template function until a single value or an array of\n * values changes.\n *\n * Values are checked against previous values with strict equality (`===`), and\n * so the check won't detect nested property changes inside objects or arrays.\n * Arrays values have each item checked against the previous value at the same\n * index with strict equality. Nested arrays are also checked only by strict\n * equality.\n *\n * Example:\n *\n * ```js\n * html`\n *   <div>\n *     ${guard([user.id, company.id], () => html`...`)}\n *   </div>\n * `\n * ```\n *\n * In this case, the template only rerenders if either `user.id` or `company.id`\n * changes.\n *\n * guard() is useful with immutable data patterns, by preventing expensive work\n * until data updates.\n *\n * Example:\n *\n * ```js\n * html`\n *   <div>\n *     ${guard([immutableItems], () => immutableItems.map(i => html`${i}`))}\n *   </div>\n * `\n * ```\n *\n * In this case, items are mapped over only when the array reference changes.\n *\n * @param value the value to check before re-rendering\n * @param f the template function\n */\nexport const guard = directive(GuardDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {GuardDirective};\n"],"names":["initialValue","guard","directive","Directive","constructor","this","_previousValue","render","_value","f","update","_part","value","Array","isArray","length","every","v","i","noChange","from"],"mappings":";;;;;;AAUA,MAAMA,EAAe,CAAA,EAyERC,EAAQC,EAvErB,cAA6BC,EAA7BC,kCACUC,KAAcC,GAAYN,CA2BnC,CAzBCO,OAAOC,EAAiBC,GACtB,OAAOA,GACR,CAEQC,OAAOC,GAAcC,EAAOH,IACnC,GAAII,MAAMC,QAAQF,IAEhB,GACEC,MAAMC,QAAQT,KAAKC,KACnBD,KAAKC,GAAeS,SAAWH,EAAMG,QACrCH,EAAMI,OAAM,CAACC,EAAGC,IAAMD,IAAOZ,KAAKC,GAAkCY,KAEpE,OAAOC,OAEJ,GAAId,KAAKC,KAAmBM,EAEjC,OAAOO,EAOT,OAFAd,KAAKC,GAAiBO,MAAMC,QAAQF,GAASC,MAAMO,KAAKR,GAASA,EACvDP,KAAKE,OAAOK,EAAOH,EAE9B"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/directives/if-defined.js.map b/front_end/third_party/lit-html/package/directives/if-defined.js.map
index 6d9000837264c2bfd2df5537a6cf3957521ffda8..a88f2079cf05faca61d5f7afcbbae326ab7677f8 100644
--- a/front_end/third_party/lit-html/package/directives/if-defined.js.map
+++ b/front_end/third_party/lit-html/package/directives/if-defined.js.map
@@ -1 +1 @@
-{"version":3,"file":"if-defined.js","sources":["../src/directives/if-defined.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2018 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {nothing} from '../lit-html.js';\n\n/**\n * For AttributeParts, sets the attribute if the value is defined and removes\n * the attribute if the value is undefined.\n *\n * For other part types, this directive is a no-op.\n */\nexport const ifDefined = <T>(value: T) => value ?? nothing;\n"],"names":["ifDefined","value","nothing"],"mappings":";;;;;SAcaA,EAAgBC,GAAaA,MAAAA,EAAAA,EAASC"}
\ No newline at end of file
+{"version":3,"file":"if-defined.js","sources":["../src/directives/if-defined.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2018 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {nothing} from '../lit-html.js';\n\n/**\n * For AttributeParts, sets the attribute if the value is defined and removes\n * the attribute if the value is undefined.\n *\n * For other part types, this directive is a no-op.\n */\nexport const ifDefined = <T>(value: T) => value ?? nothing;\n"],"names":["ifDefined","value","nothing"],"mappings":";;;;;GAca,MAAAA,EAAgBC,GAAaA,QAAAA,EAASC"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/directives/join.js.map b/front_end/third_party/lit-html/package/directives/join.js.map
index ab847feb6a11d0ec2aa34962522cf8aa54d000d3..27d394d4c93a5a9642a2454f5c8d007db642eb5c 100644
--- a/front_end/third_party/lit-html/package/directives/join.js.map
+++ b/front_end/third_party/lit-html/package/directives/join.js.map
@@ -1 +1 @@
-{"version":3,"file":"join.js","sources":["../src/directives/join.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n/**\n * Returns an iterable containing the values in `items` interleaved with the\n * `joiner` value.\n *\n * @example\n *\n * ```ts\n * render() {\n *   return html`\n *     ${join(items, html`<span class=\"separator\">|</span>`)}\n *   `;\n * }\n */\nexport function join<I, J>(\n  items: Iterable<I> | undefined,\n  joiner: (index: number) => J\n): Iterable<I | J>;\nexport function join<I, J>(\n  items: Iterable<I> | undefined,\n  joiner: J\n): Iterable<I | J>;\nexport function* join<I, J>(items: Iterable<I> | undefined, joiner: J) {\n  const isFunction = typeof joiner === 'function';\n  if (items !== undefined) {\n    let i = -1;\n    for (const value of items) {\n      if (i > -1) {\n        yield isFunction ? joiner(i) : joiner;\n      }\n      i++;\n      yield value;\n    }\n  }\n}\n"],"names":["join","items","joiner","isFunction","undefined","i","value"],"mappings":";;;;;SA2BiBA,EAAWC,EAAgCC,GAC1D,MAAMC,EAA+B,mBAAXD,EAC1B,QAAcE,IAAVH,EAAqB,CACvB,IAAII,GAAK,EACT,IAAK,MAAMC,KAASL,EACdI,GAAK,UACDF,EAAaD,EAAOG,GAAKH,GAEjCG,UACMC"}
\ No newline at end of file
+{"version":3,"file":"join.js","sources":["../src/directives/join.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n/**\n * Returns an iterable containing the values in `items` interleaved with the\n * `joiner` value.\n *\n * @example\n *\n * ```ts\n * render() {\n *   return html`\n *     ${join(items, html`<span class=\"separator\">|</span>`)}\n *   `;\n * }\n */\nexport function join<I, J>(\n  items: Iterable<I> | undefined,\n  joiner: (index: number) => J\n): Iterable<I | J>;\nexport function join<I, J>(\n  items: Iterable<I> | undefined,\n  joiner: J\n): Iterable<I | J>;\nexport function* join<I, J>(items: Iterable<I> | undefined, joiner: J) {\n  const isFunction = typeof joiner === 'function';\n  if (items !== undefined) {\n    let i = -1;\n    for (const value of items) {\n      if (i > -1) {\n        yield isFunction ? joiner(i) : joiner;\n      }\n      i++;\n      yield value;\n    }\n  }\n}\n"],"names":["join","items","joiner","isFunction","undefined","i","value"],"mappings":";;;;;SA2BiBA,EAAWC,EAAgCC,GAC1D,MAAMC,EAA+B,mBAAXD,EAC1B,QAAcE,IAAVH,EAAqB,CACvB,IAAII,GAAK,EACT,IAAK,MAAMC,KAASL,EACdI,GAAK,UACDF,EAAaD,EAAOG,GAAKH,GAEjCG,UACMC,CAET,CACH"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/directives/keyed.d.ts b/front_end/third_party/lit-html/package/directives/keyed.d.ts
index b1c0cb83c4f56f50b43d2b11e9395fc5fec91af4..457237ff8fda898923e35f2b222027e6d777ff6b 100644
--- a/front_end/third_party/lit-html/package/directives/keyed.d.ts
+++ b/front_end/third_party/lit-html/package/directives/keyed.d.ts
@@ -19,5 +19,10 @@  * with code that expects new data to generate new HTML elements, such as some
  * animation techniques.
  */
 export declare const keyed: (k: unknown, v: unknown) => import("../directive.js").DirectiveResult<typeof Keyed>;
+/**
  * @license
+ * @license
+ * directive's return type.
+ */
+export type { Keyed };
 //# sourceMappingURL=keyed.d.ts.map
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/directives/keyed.d.ts.map b/front_end/third_party/lit-html/package/directives/keyed.d.ts.map
index 753e04195329d2cd49058042fe2d0bc5882e6784..51064775152698be98ff17e00a7ee74c7cd3ce12 100644
--- a/front_end/third_party/lit-html/package/directives/keyed.d.ts.map
+++ b/front_end/third_party/lit-html/package/directives/keyed.d.ts.map
@@ -1 +1 @@
-{"version":3,"file":"keyed.d.ts","sourceRoot":"","sources":["../../src/directives/keyed.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAGH,OAAO,EAEL,SAAS,EACT,SAAS,EACT,mBAAmB,EACpB,MAAM,iBAAiB,CAAC;AAGzB,cAAM,KAAM,SAAQ,SAAS;IAC3B,GAAG,EAAE,OAAO,CAAW;IAEvB,MAAM,CAAC,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,OAAO;IAKpB,MAAM,CAAC,IAAI,EAAE,SAAS,EAAE,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,mBAAmB,CAAC,IAAI,CAAC;CAUnE;AAED;;;;;;;;GAQG;AACH,eAAO,MAAM,KAAK,qFAAmB,CAAC"}
\ No newline at end of file
+{"version":3,"file":"keyed.d.ts","sourceRoot":"","sources":["../../src/directives/keyed.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAGH,OAAO,EAEL,SAAS,EACT,SAAS,EACT,mBAAmB,EACpB,MAAM,iBAAiB,CAAC;AAGzB,cAAM,KAAM,SAAQ,SAAS;IAC3B,GAAG,EAAE,OAAO,CAAW;IAEvB,MAAM,CAAC,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,OAAO;IAKpB,MAAM,CAAC,IAAI,EAAE,SAAS,EAAE,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,mBAAmB,CAAC,IAAI,CAAC;CAUnE;AAED;;;;;;;;GAQG;AACH,eAAO,MAAM,KAAK,qFAAmB,CAAC;AAEtC;;;GAGG;AACH,YAAY,EAAC,KAAK,EAAC,CAAC"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/directives/keyed.js.map b/front_end/third_party/lit-html/package/directives/keyed.js.map
index 9bdda22692c1c88a68e7d95fb1295cbfbf7b8b8c..a78f711444d66d04ecbd81e8f29bba727ee0ce7d 100644
--- a/front_end/third_party/lit-html/package/directives/keyed.js.map
+++ b/front_end/third_party/lit-html/package/directives/keyed.js.map
@@ -1 +1 @@
-{"version":3,"file":"keyed.js","sources":["../src/directives/keyed.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {nothing} from '../lit-html.js';\nimport {\n  directive,\n  Directive,\n  ChildPart,\n  DirectiveParameters,\n} from '../directive.js';\nimport {setCommittedValue} from '../directive-helpers.js';\n\nclass Keyed extends Directive {\n  key: unknown = nothing;\n\n  render(k: unknown, v: unknown) {\n    this.key = k;\n    return v;\n  }\n\n  override update(part: ChildPart, [k, v]: DirectiveParameters<this>) {\n    if (k !== this.key) {\n      // Clear the part before returning a value. The one-arg form of\n      // setCommittedValue sets the value to a sentinel which forces a\n      // commit the next render.\n      setCommittedValue(part);\n      this.key = k;\n    }\n    return v;\n  }\n}\n\n/**\n * Associates a renderable value with a unique key. When the key changes, the\n * previous DOM is removed and disposed before rendering the next value, even\n * if the value - such as a template - is the same.\n *\n * This is useful for forcing re-renders of stateful components, or working\n * with code that expects new data to generate new HTML elements, such as some\n * animation techniques.\n */\nexport const keyed = directive(Keyed);\n"],"names":["keyed","directive","Directive","constructor","this","nothing","render","k","v","key","update","part","setCommittedValue"],"mappings":";;;;;SA4CaA,EAAQC,EA7BrB,cAAoBC,EAApBC,kCACEC,SAAeC,EAEfC,OAAOC,EAAYC,GAEjB,OADAJ,KAAKK,IAAMF,EACJC,EAGAE,OAAOC,GAAkBJ,EAAGC,IAQnC,OAPID,IAAMH,KAAKK,MAIbG,EAAkBD,GAClBP,KAAKK,IAAMF,GAENC"}
\ No newline at end of file
+{"version":3,"file":"keyed.js","sources":["../src/directives/keyed.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {nothing} from '../lit-html.js';\nimport {\n  directive,\n  Directive,\n  ChildPart,\n  DirectiveParameters,\n} from '../directive.js';\nimport {setCommittedValue} from '../directive-helpers.js';\n\nclass Keyed extends Directive {\n  key: unknown = nothing;\n\n  render(k: unknown, v: unknown) {\n    this.key = k;\n    return v;\n  }\n\n  override update(part: ChildPart, [k, v]: DirectiveParameters<this>) {\n    if (k !== this.key) {\n      // Clear the part before returning a value. The one-arg form of\n      // setCommittedValue sets the value to a sentinel which forces a\n      // commit the next render.\n      setCommittedValue(part);\n      this.key = k;\n    }\n    return v;\n  }\n}\n\n/**\n * Associates a renderable value with a unique key. When the key changes, the\n * previous DOM is removed and disposed before rendering the next value, even\n * if the value - such as a template - is the same.\n *\n * This is useful for forcing re-renders of stateful components, or working\n * with code that expects new data to generate new HTML elements, such as some\n * animation techniques.\n */\nexport const keyed = directive(Keyed);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {Keyed};\n"],"names":["keyed","directive","Directive","constructor","this","key","nothing","render","k","v","update","part","setCommittedValue"],"mappings":";;;;;SA4CaA,EAAQC,EA7BrB,cAAoBC,EAApBC,kCACEC,KAAGC,IAAYC,CAiBhB,CAfCC,OAAOC,EAAYC,GAEjB,OADAL,KAAKC,IAAMG,EACJC,CACR,CAEQC,OAAOC,GAAkBH,EAAGC,IAQnC,OAPID,IAAMJ,KAAKC,MAIbO,EAAkBD,GAClBP,KAAKC,IAAMG,GAENC,CACR"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/directives/live.d.ts b/front_end/third_party/lit-html/package/directives/live.d.ts
index 23d46f261d7a280f0dc3e8046202d9ae6d036f89..f472de738a54e4fab2425e7f8cf60a75c7aceb0e 100644
--- a/front_end/third_party/lit-html/package/directives/live.d.ts
+++ b/front_end/third_party/lit-html/package/directives/live.d.ts
@@ -28,7 +28,7 @@  * ```js
  * html`<input .value=${live(x)}>`
  * ```
  *
- * @license
+ * Copyright 2020 Google LLC
 import { Directive, DirectiveParameters, PartInfo } from '../directive.js';
  * the new value is equal to the live value, does nothing. This means that
  * `live()` should not be used when the binding will cause a type conversion. If




diff --git a/front_end/third_party/lit-html/package/directives/live.js.map b/front_end/third_party/lit-html/package/directives/live.js.map
index 7c9bdfd0d856126a31797cf197e82bcb3a0831a9..0aa92c83d9d4e11e1c6e77b0f1130d53ce522786 100644
--- a/front_end/third_party/lit-html/package/directives/live.js.map
+++ b/front_end/third_party/lit-html/package/directives/live.js.map
@@ -1 +1 @@
-{"version":3,"file":"live.js","sources":["../src/directives/live.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2020 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {AttributePart, noChange, nothing} from '../lit-html.js';\nimport {\n  directive,\n  Directive,\n  DirectiveParameters,\n  PartInfo,\n  PartType,\n} from '../directive.js';\nimport {isSingleExpression, setCommittedValue} from '../directive-helpers.js';\n\nclass LiveDirective extends Directive {\n  constructor(partInfo: PartInfo) {\n    super(partInfo);\n    if (\n      !(\n        partInfo.type === PartType.PROPERTY ||\n        partInfo.type === PartType.ATTRIBUTE ||\n        partInfo.type === PartType.BOOLEAN_ATTRIBUTE\n      )\n    ) {\n      throw new Error(\n        'The `live` directive is not allowed on child or event bindings'\n      );\n    }\n    if (!isSingleExpression(partInfo)) {\n      throw new Error('`live` bindings can only contain a single expression');\n    }\n  }\n\n  render(value: unknown) {\n    return value;\n  }\n\n  override update(part: AttributePart, [value]: DirectiveParameters<this>) {\n    if (value === noChange || value === nothing) {\n      return value;\n    }\n    const element = part.element;\n    const name = part.name;\n\n    if (part.type === PartType.PROPERTY) {\n      // eslint-disable-next-line @typescript-eslint/no-explicit-any\n      if (value === (element as any)[name]) {\n        return noChange;\n      }\n    } else if (part.type === PartType.BOOLEAN_ATTRIBUTE) {\n      if (!!value === element.hasAttribute(name)) {\n        return noChange;\n      }\n    } else if (part.type === PartType.ATTRIBUTE) {\n      if (element.getAttribute(name) === String(value)) {\n        return noChange;\n      }\n    }\n    // Resets the part's value, causing its dirty-check to fail so that it\n    // always sets the value.\n    setCommittedValue(part);\n    return value;\n  }\n}\n\n/**\n * Checks binding values against live DOM values, instead of previously bound\n * values, when determining whether to update the value.\n *\n * This is useful for cases where the DOM value may change from outside of\n * lit-html, such as with a binding to an `<input>` element's `value` property,\n * a content editable elements text, or to a custom element that changes it's\n * own properties or attributes.\n *\n * In these cases if the DOM value changes, but the value set through lit-html\n * bindings hasn't, lit-html won't know to update the DOM value and will leave\n * it alone. If this is not what you want--if you want to overwrite the DOM\n * value with the bound value no matter what--use the `live()` directive:\n *\n * ```js\n * html`<input .value=${live(x)}>`\n * ```\n *\n * `live()` performs a strict equality check agains the live DOM value, and if\n * the new value is equal to the live value, does nothing. This means that\n * `live()` should not be used when the binding will cause a type conversion. If\n * you use `live()` with an attribute binding, make sure that only strings are\n * passed in, or the binding will update every render.\n */\nexport const live = directive(LiveDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {LiveDirective};\n"],"names":["live","directive","Directive","constructor","partInfo","super","type","PartType","PROPERTY","ATTRIBUTE","BOOLEAN_ATTRIBUTE","Error","isSingleExpression","render","value","update","part","noChange","nothing","element","name","hasAttribute","getAttribute","String","setCommittedValue"],"mappings":";;;;;SA2FaA,EAAOC,EA3EpB,cAA4BC,EAC1BC,YAAYC,GAEV,GADAC,MAAMD,GAGFA,EAASE,OAASC,EAASC,UAC3BJ,EAASE,OAASC,EAASE,WAC3BL,EAASE,OAASC,EAASG,kBAG7B,MAAUC,MACR,kEAGJ,IAAKC,EAAmBR,GACtB,MAAUO,MAAM,wDAIpBE,OAAOC,GACL,OAAOA,EAGAC,OAAOC,GAAsBF,IACpC,GAAIA,IAAUG,GAAYH,IAAUI,EAClC,OAAOJ,EAET,MAAMK,EAAUH,EAAKG,QACfC,EAAOJ,EAAKI,KAElB,GAAIJ,EAAKV,OAASC,EAASC,UAEzB,GAAIM,IAAWK,EAAgBC,GAC7B,OAAOH,OAEJ,GAAID,EAAKV,OAASC,EAASG,mBAChC,KAAMI,IAAUK,EAAQE,aAAaD,GACnC,OAAOH,OAEJ,GAAID,EAAKV,OAASC,EAASE,WAC5BU,EAAQG,aAAaF,KAAiBN,EAAPS,GACjC,OAAON,EAMX,OADAO,EAAkBR,GACXF"}
\ No newline at end of file
+{"version":3,"file":"live.js","sources":["../src/directives/live.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2020 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {AttributePart, noChange, nothing} from '../lit-html.js';\nimport {\n  directive,\n  Directive,\n  DirectiveParameters,\n  PartInfo,\n  PartType,\n} from '../directive.js';\nimport {isSingleExpression, setCommittedValue} from '../directive-helpers.js';\n\nclass LiveDirective extends Directive {\n  constructor(partInfo: PartInfo) {\n    super(partInfo);\n    if (\n      !(\n        partInfo.type === PartType.PROPERTY ||\n        partInfo.type === PartType.ATTRIBUTE ||\n        partInfo.type === PartType.BOOLEAN_ATTRIBUTE\n      )\n    ) {\n      throw new Error(\n        'The `live` directive is not allowed on child or event bindings'\n      );\n    }\n    if (!isSingleExpression(partInfo)) {\n      throw new Error('`live` bindings can only contain a single expression');\n    }\n  }\n\n  render(value: unknown) {\n    return value;\n  }\n\n  override update(part: AttributePart, [value]: DirectiveParameters<this>) {\n    if (value === noChange || value === nothing) {\n      return value;\n    }\n    const element = part.element;\n    const name = part.name;\n\n    if (part.type === PartType.PROPERTY) {\n      // eslint-disable-next-line @typescript-eslint/no-explicit-any\n      if (value === (element as any)[name]) {\n        return noChange;\n      }\n    } else if (part.type === PartType.BOOLEAN_ATTRIBUTE) {\n      if (!!value === element.hasAttribute(name)) {\n        return noChange;\n      }\n    } else if (part.type === PartType.ATTRIBUTE) {\n      if (element.getAttribute(name) === String(value)) {\n        return noChange;\n      }\n    }\n    // Resets the part's value, causing its dirty-check to fail so that it\n    // always sets the value.\n    setCommittedValue(part);\n    return value;\n  }\n}\n\n/**\n * Checks binding values against live DOM values, instead of previously bound\n * values, when determining whether to update the value.\n *\n * This is useful for cases where the DOM value may change from outside of\n * lit-html, such as with a binding to an `<input>` element's `value` property,\n * a content editable elements text, or to a custom element that changes it's\n * own properties or attributes.\n *\n * In these cases if the DOM value changes, but the value set through lit-html\n * bindings hasn't, lit-html won't know to update the DOM value and will leave\n * it alone. If this is not what you want--if you want to overwrite the DOM\n * value with the bound value no matter what--use the `live()` directive:\n *\n * ```js\n * html`<input .value=${live(x)}>`\n * ```\n *\n * `live()` performs a strict equality check against the live DOM value, and if\n * the new value is equal to the live value, does nothing. This means that\n * `live()` should not be used when the binding will cause a type conversion. If\n * you use `live()` with an attribute binding, make sure that only strings are\n * passed in, or the binding will update every render.\n */\nexport const live = directive(LiveDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {LiveDirective};\n"],"names":["live","directive","Directive","constructor","partInfo","super","type","PartType","PROPERTY","ATTRIBUTE","BOOLEAN_ATTRIBUTE","Error","isSingleExpression","render","value","update","part","noChange","nothing","element","name","hasAttribute","getAttribute","String","setCommittedValue"],"mappings":";;;;;SA2FaA,EAAOC,EA3EpB,cAA4BC,EAC1BC,YAAYC,GAEV,GADAC,MAAMD,GAGFA,EAASE,OAASC,EAASC,UAC3BJ,EAASE,OAASC,EAASE,WAC3BL,EAASE,OAASC,EAASG,kBAG7B,MAAUC,MACR,kEAGJ,IAAKC,EAAmBR,GACtB,MAAUO,MAAM,uDAEnB,CAEDE,OAAOC,GACL,OAAOA,CACR,CAEQC,OAAOC,GAAsBF,IACpC,GAAIA,IAAUG,GAAYH,IAAUI,EAClC,OAAOJ,EAET,MAAMK,EAAUH,EAAKG,QACfC,EAAOJ,EAAKI,KAElB,GAAIJ,EAAKV,OAASC,EAASC,UAEzB,GAAIM,IAAWK,EAAgBC,GAC7B,OAAOH,OAEJ,GAAID,EAAKV,OAASC,EAASG,mBAChC,KAAMI,IAAUK,EAAQE,aAAaD,GACnC,OAAOH,OAEJ,GAAID,EAAKV,OAASC,EAASE,WAC5BU,EAAQG,aAAaF,KAAiBN,EAAPS,GACjC,OAAON,EAMX,OADAO,EAAkBR,GACXF,CACR"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/directives/map.js.map b/front_end/third_party/lit-html/package/directives/map.js.map
index adf18f8db4f48ee66d2d6e92198801bbce9ee9ad..7c6188c2b6b5a2a9414b1d0e685b438e57f02a12 100644
--- a/front_end/third_party/lit-html/package/directives/map.js.map
+++ b/front_end/third_party/lit-html/package/directives/map.js.map
@@ -1 +1 @@
-{"version":3,"file":"map.js","sources":["../src/directives/map.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n/**\n * Returns an iterable containing the result of calling `f(value)` on each\n * value in `items`.\n *\n * @example\n *\n * ```ts\n * render() {\n *   return html`\n *     <ul>\n *       ${map(items, (i) => html`<li>${i}</li>`)}\n *     </ul>\n *   `;\n * }\n * ```\n */\nexport function* map<T>(\n  items: Iterable<T> | undefined,\n  f: (value: T, index: number) => unknown\n) {\n  if (items !== undefined) {\n    let i = 0;\n    for (const value of items) {\n      yield f(value, i++);\n    }\n  }\n}\n"],"names":["map","items","f","undefined","i","value"],"mappings":";;;;;SAsBiBA,EACfC,EACAC,GAEA,QAAcC,IAAVF,EAAqB,CACvB,IAAIG,EAAI,EACR,IAAK,MAAMC,KAASJ,QACZC,EAAEG,EAAOD"}
\ No newline at end of file
+{"version":3,"file":"map.js","sources":["../src/directives/map.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n/**\n * Returns an iterable containing the result of calling `f(value)` on each\n * value in `items`.\n *\n * @example\n *\n * ```ts\n * render() {\n *   return html`\n *     <ul>\n *       ${map(items, (i) => html`<li>${i}</li>`)}\n *     </ul>\n *   `;\n * }\n * ```\n */\nexport function* map<T>(\n  items: Iterable<T> | undefined,\n  f: (value: T, index: number) => unknown\n) {\n  if (items !== undefined) {\n    let i = 0;\n    for (const value of items) {\n      yield f(value, i++);\n    }\n  }\n}\n"],"names":["map","items","f","undefined","i","value"],"mappings":";;;;;SAsBiBA,EACfC,EACAC,GAEA,QAAcC,IAAVF,EAAqB,CACvB,IAAIG,EAAI,EACR,IAAK,MAAMC,KAASJ,QACZC,EAAEG,EAAOD,IAElB,CACH"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/directives/private-async-helpers.js b/front_end/third_party/lit-html/package/directives/private-async-helpers.js
index 56a4e786f4f416b8acf6b63d0fad6b8725721b59..f4d381db49c222219a97e782e68a12aad8711ed8 100644
--- a/front_end/third_party/lit-html/package/directives/private-async-helpers.js
+++ b/front_end/third_party/lit-html/package/directives/private-async-helpers.js
@@ -3,5 +3,5 @@  * @license
  * Copyright 2021 Google LLC
  * SPDX-License-Identifier: BSD-3-Clause
  */
-const t=async(t,s)=>{for await(const i of t)if(!1===await s(i))return};class s{constructor(t){this.U=t}disconnect(){this.U=void 0}reconnect(t){this.U=t}deref(){return this.U}}class i{constructor(){this.Y=void 0,this.q=void 0}get(){return this.Y}pause(){var t;null!==(t=this.Y)&&void 0!==t||(this.Y=new Promise((t=>this.q=t)))}resume(){var t;null===(t=this.q)||void 0===t||t.call(this),this.Y=this.q=void 0}}export{i as Pauser,s as PseudoWeakRef,t as forAwaitOf};
+const t=async(t,s)=>{for await(const i of t)if(!1===await s(i))return};class s{constructor(t){this.Y=t}disconnect(){this.Y=void 0}reconnect(t){this.Y=t}deref(){return this.Y}}class i{constructor(){this.Z=void 0,this.q=void 0}get(){return this.Z}pause(){var t;null!==(t=this.Z)&&void 0!==t||(this.Z=new Promise((t=>this.q=t)))}resume(){var t;null===(t=this.q)||void 0===t||t.call(this),this.Z=this.q=void 0}}export{i as Pauser,s as PseudoWeakRef,t as forAwaitOf};
 //# sourceMappingURL=private-async-helpers.js.map




diff --git a/front_end/third_party/lit-html/package/directives/private-async-helpers.js.map b/front_end/third_party/lit-html/package/directives/private-async-helpers.js.map
index 96d8ae15af94e31a2b0f961dc2e46ea7a985868f..a5549abdb694dcc6a8a86c673079884c2749cf16 100644
--- a/front_end/third_party/lit-html/package/directives/private-async-helpers.js.map
+++ b/front_end/third_party/lit-html/package/directives/private-async-helpers.js.map
@@ -1 +1 @@
-{"version":3,"file":"private-async-helpers.js","sources":["../src/directives/private-async-helpers.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n// Note, this module is not included in package exports so that it's private to\n// our first-party directives. If it ends up being useful, we can open it up and\n// export it.\n\n/**\n * Helper to iterate an AsyncIterable in its own closure.\n * @param iterable The iterable to iterate\n * @param callback The callback to call for each value. If the callback returns\n * `false`, the loop will be broken.\n */\nexport const forAwaitOf = async <T>(\n  iterable: AsyncIterable<T>,\n  callback: (value: T) => Promise<boolean>\n) => {\n  for await (const v of iterable) {\n    if ((await callback(v)) === false) {\n      return;\n    }\n  }\n};\n\n/**\n * Holds a reference to an instance that can be disconnected and reconnected,\n * so that a closure over the ref (e.g. in a then function to a promise) does\n * not strongly hold a ref to the instance. Approximates a WeakRef but must\n * be manually connected & disconnected to the backing instance.\n */\nexport class PseudoWeakRef<T> {\n  private _ref?: T;\n  constructor(ref: T) {\n    this._ref = ref;\n  }\n  /**\n   * Disassociates the ref with the backing instance.\n   */\n  disconnect() {\n    this._ref = undefined;\n  }\n  /**\n   * Reassociates the ref with the backing instance.\n   */\n  reconnect(ref: T) {\n    this._ref = ref;\n  }\n  /**\n   * Retrieves the backing instance (will be undefined when disconnected)\n   */\n  deref() {\n    return this._ref;\n  }\n}\n\n/**\n * A helper to pause and resume waiting on a condition in an async function\n */\nexport class Pauser {\n  private _promise?: Promise<void> = undefined;\n  private _resolve?: () => void = undefined;\n  /**\n   * When paused, returns a promise to be awaited; when unpaused, returns\n   * undefined. Note that in the microtask between the pauser being resumed\n   * an an await of this promise resolving, the pauser could be paused again,\n   * hence callers should check the promise in a loop when awaiting.\n   * @returns A promise to be awaited when paused or undefined\n   */\n  get() {\n    return this._promise;\n  }\n  /**\n   * Creates a promise to be awaited\n   */\n  pause() {\n    this._promise ??= new Promise((resolve) => (this._resolve = resolve));\n  }\n  /**\n   * Resolves the promise which may be awaited\n   */\n  resume() {\n    this._resolve?.();\n    this._promise = this._resolve = undefined;\n  }\n}\n"],"names":["forAwaitOf","async","iterable","callback","v","PseudoWeakRef","constructor","ref","this","_ref","disconnect","undefined","reconnect","deref","Pauser","get","_promise","pause","Promise","resolve","_resolve","resume"],"mappings":";;;;;MAgBaA,EAAaC,MACxBC,EACAC,KAEA,UAAW,MAAMC,KAAKF,EACpB,IAA4B,UAAjBC,EAASC,GAClB,cAWOC,EAEXC,YAAYC,GACVC,KAAKC,EAAOF,EAKdG,aACEF,KAAKC,OAAOE,EAKdC,UAAUL,GACRC,KAAKC,EAAOF,EAKdM,QACE,OAAOL,KAAKC,SAOHK,EAAbR,cACUE,YAA2BG,EAC3BH,YAAwBG,EAQhCI,MACE,OAAOP,KAAKQ,EAKdC,wBACET,KAAKQ,iBAALR,KAAKQ,EAAa,IAAIE,SAASC,GAAaX,KAAKY,EAAWD,KAK9DE,yBACEb,KAAKY,uBAALZ,MACAA,KAAKQ,EAAWR,KAAKY,OAAWT"}
\ No newline at end of file
+{"version":3,"file":"private-async-helpers.js","sources":["../src/directives/private-async-helpers.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n// Note, this module is not included in package exports so that it's private to\n// our first-party directives. If it ends up being useful, we can open it up and\n// export it.\n\n/**\n * Helper to iterate an AsyncIterable in its own closure.\n * @param iterable The iterable to iterate\n * @param callback The callback to call for each value. If the callback returns\n * `false`, the loop will be broken.\n */\nexport const forAwaitOf = async <T>(\n  iterable: AsyncIterable<T>,\n  callback: (value: T) => Promise<boolean>\n) => {\n  for await (const v of iterable) {\n    if ((await callback(v)) === false) {\n      return;\n    }\n  }\n};\n\n/**\n * Holds a reference to an instance that can be disconnected and reconnected,\n * so that a closure over the ref (e.g. in a then function to a promise) does\n * not strongly hold a ref to the instance. Approximates a WeakRef but must\n * be manually connected & disconnected to the backing instance.\n */\nexport class PseudoWeakRef<T> {\n  private _ref?: T;\n  constructor(ref: T) {\n    this._ref = ref;\n  }\n  /**\n   * Disassociates the ref with the backing instance.\n   */\n  disconnect() {\n    this._ref = undefined;\n  }\n  /**\n   * Reassociates the ref with the backing instance.\n   */\n  reconnect(ref: T) {\n    this._ref = ref;\n  }\n  /**\n   * Retrieves the backing instance (will be undefined when disconnected)\n   */\n  deref() {\n    return this._ref;\n  }\n}\n\n/**\n * A helper to pause and resume waiting on a condition in an async function\n */\nexport class Pauser {\n  private _promise?: Promise<void> = undefined;\n  private _resolve?: () => void = undefined;\n  /**\n   * When paused, returns a promise to be awaited; when unpaused, returns\n   * undefined. Note that in the microtask between the pauser being resumed\n   * an an await of this promise resolving, the pauser could be paused again,\n   * hence callers should check the promise in a loop when awaiting.\n   * @returns A promise to be awaited when paused or undefined\n   */\n  get() {\n    return this._promise;\n  }\n  /**\n   * Creates a promise to be awaited\n   */\n  pause() {\n    this._promise ??= new Promise((resolve) => (this._resolve = resolve));\n  }\n  /**\n   * Resolves the promise which may be awaited\n   */\n  resume() {\n    this._resolve?.();\n    this._promise = this._resolve = undefined;\n  }\n}\n"],"names":["forAwaitOf","async","iterable","callback","v","PseudoWeakRef","constructor","ref","this","_ref","disconnect","undefined","reconnect","deref","Pauser","_promise","_resolve","get","pause","_a","Promise","resolve","resume","call"],"mappings":";;;;;AAgBa,MAAAA,EAAaC,MACxBC,EACAC,KAEA,UAAW,MAAMC,KAAKF,EACpB,IAA4B,UAAjBC,EAASC,GAClB,MAEH,QASUC,EAEXC,YAAYC,GACVC,KAAKC,EAAOF,CACb,CAIDG,aACEF,KAAKC,OAAOE,CACb,CAIDC,UAAUL,GACRC,KAAKC,EAAOF,CACb,CAIDM,QACE,OAAOL,KAAKC,CACb,QAMUK,EAAbR,cACUE,KAAQO,OAAmBJ,EAC3BH,KAAQQ,OAAgBL,CAwBjC,CAhBCM,MACE,OAAOT,KAAKO,CACb,CAIDG,cACE,QAAAC,EAAAX,KAAKO,SAAL,IAAAI,IAAAX,KAAKO,EAAa,IAAIK,SAASC,GAAab,KAAKQ,EAAWK,IAC7D,CAIDC,eACe,QAAbH,EAAAX,KAAKQ,SAAQ,IAAAG,GAAAA,EAAAI,KAAAf,MACbA,KAAKO,EAAWP,KAAKQ,OAAWL,CACjC"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/directives/range.js.map b/front_end/third_party/lit-html/package/directives/range.js.map
index 3bd678ec87d091c039f1f68003d03037f7ff5e68..fcc27836fcd5024def04c64bf46280453097e7e8 100644
--- a/front_end/third_party/lit-html/package/directives/range.js.map
+++ b/front_end/third_party/lit-html/package/directives/range.js.map
@@ -1 +1 @@
-{"version":3,"file":"range.js","sources":["../src/directives/range.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n/**\n * Returns an iterable of integers from `start` to `end` (exclusive)\n * incrementing by `step`.\n *\n * If `start` is omitted, the range starts at `0`. `step` defaults to `1`.\n *\n * @example\n *\n * ```ts\n * render() {\n *   return html`\n *     ${map(range(8), () => html`<div class=\"cell\"></div>`)}\n *   `;\n * }\n * ```\n */\nexport function range(end: number): Iterable<number>;\nexport function range(\n  start: number,\n  end: number,\n  step?: number\n): Iterable<number>;\nexport function* range(startOrEnd: number, end?: number, step = 1) {\n  const start = end === undefined ? 0 : startOrEnd;\n  end ??= startOrEnd;\n  for (let i = start; step > 0 ? i < end : end < i; i += step) {\n    yield i;\n  }\n}\n"],"names":["range","startOrEnd","end","step","start","undefined","i"],"mappings":";;;;;SA4BiBA,EAAMC,EAAoBC,EAAcC,EAAO,GAC9D,MAAMC,OAAgBC,IAARH,EAAoB,EAAID,EACtCC,MAAAA,IAAAA,EAAQD,GACR,IAAK,IAAIK,EAAIF,EAAOD,EAAO,EAAIG,EAAIJ,EAAMA,EAAMI,EAAGA,GAAKH,QAC/CG"}
\ No newline at end of file
+{"version":3,"file":"range.js","sources":["../src/directives/range.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n/**\n * Returns an iterable of integers from `start` to `end` (exclusive)\n * incrementing by `step`.\n *\n * If `start` is omitted, the range starts at `0`. `step` defaults to `1`.\n *\n * @example\n *\n * ```ts\n * render() {\n *   return html`\n *     ${map(range(8), () => html`<div class=\"cell\"></div>`)}\n *   `;\n * }\n * ```\n */\nexport function range(end: number): Iterable<number>;\nexport function range(\n  start: number,\n  end: number,\n  step?: number\n): Iterable<number>;\nexport function* range(startOrEnd: number, end?: number, step = 1) {\n  const start = end === undefined ? 0 : startOrEnd;\n  end ??= startOrEnd;\n  for (let i = start; step > 0 ? i < end : end < i; i += step) {\n    yield i;\n  }\n}\n"],"names":["range","startOrEnd","end","step","start","undefined","i"],"mappings":";;;;;AA4BM,SAAWA,EAAMC,EAAoBC,EAAcC,EAAO,GAC9D,MAAMC,OAAgBC,IAARH,EAAoB,EAAID,EACtCC,UAAAA,EAAQD,GACR,IAAK,IAAIK,EAAIF,EAAOD,EAAO,EAAIG,EAAIJ,EAAMA,EAAMI,EAAGA,GAAKH,QAC/CG,CAEV"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/directives/ref.d.ts b/front_end/third_party/lit-html/package/directives/ref.d.ts
index 8bbdd84c7c18bec80f86150035519990d2ace589..f31fb09984a8e568ccc9656fec721259a7717cd8 100644
--- a/front_end/third_party/lit-html/package/directives/ref.d.ts
+++ b/front_end/third_party/lit-html/package/directives/ref.d.ts
@@ -24,7 +24,7 @@ export declare type RefOrCallback = Ref | ((el: Element | undefined) => void);
 declare class RefDirective extends AsyncDirective {
     private _element?;
     private _ref?;
-    private _context;
+    private _context?;
     render(_ref: RefOrCallback): symbol;
     update(part: ElementPart, [ref]: Parameters<this['render']>): symbol;
     private _updateRefValue;




diff --git a/front_end/third_party/lit-html/package/directives/ref.d.ts.map b/front_end/third_party/lit-html/package/directives/ref.d.ts.map
index 79938c2667cc5231d01b1aeea0acd11f880352cd..db599943d3cb06bdff4235b0efbcb6bd03727d08 100644
--- a/front_end/third_party/lit-html/package/directives/ref.d.ts.map
+++ b/front_end/third_party/lit-html/package/directives/ref.d.ts.map
@@ -1 +1 @@
-{"version":3,"file":"ref.d.ts","sourceRoot":"","sources":["../../src/directives/ref.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,OAAO,EAAU,WAAW,EAAC,MAAM,gBAAgB,CAAC;AACpD,OAAO,EAAY,cAAc,EAAC,MAAM,uBAAuB,CAAC;AAEhE;;GAEG;AACH,eAAO,MAAM,SAAS,2BAAkC,CAAC;AAEzD;;GAEG;AACH,cAAM,GAAG,CAAC,CAAC,GAAG,OAAO;IACnB;;;OAGG;IACH,QAAQ,CAAC,KAAK,CAAC,EAAE,CAAC,CAAC;CACpB;AAED,YAAY,EAAC,GAAG,EAAC,CAAC;AAYlB,oBAAY,aAAa,GAAG,GAAG,GAAG,CAAC,CAAC,EAAE,EAAE,OAAO,GAAG,SAAS,KAAK,IAAI,CAAC,CAAC;AAEtE,cAAM,YAAa,SAAQ,cAAc;IACvC,OAAO,CAAC,QAAQ,CAAC,CAAU;IAC3B,OAAO,CAAC,IAAI,CAAC,CAAgB;IAC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AAe;IA+BvB,OAAO,KAAK,kBAAkB,GAM7B;IAEQ,YAAY;IAUZ,WAAW;CAKrB;AAED;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AACH,eAAO,MAAM,GAAG,yFAA0B,CAAC;AAE3C;;;GAGG;AACH,YAAY,EAAC,YAAY,EAAC,CAAC"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/directives/ref.js b/front_end/third_party/lit-html/package/directives/ref.js
index 49bb846c80d6dd701d92e4a67411687cd8bc80fe..afc6213168482af0a61cb409ab02056b28599949 100644
--- a/front_end/third_party/lit-html/package/directives/ref.js
+++ b/front_end/third_party/lit-html/package/directives/ref.js
@@ -1,7 +1,7 @@
-import{nothing as t}from"../lit-html.js";import{AsyncDirective as i}from"../async-directive.js";import{directive as s}from"../directive.js";
+import{nothing as i}from"../lit-html.js";import{AsyncDirective as t}from"../async-directive.js";import{directive as s}from"../directive.js";
 /**
  * @license
  * Copyright 2020 Google LLC
  * SPDX-License-Identifier: BSD-3-Clause
- */const e=()=>new o;class o{}const h=new WeakMap,n=s(class extends i{render(i){return t}update(i,[s]){var e;const o=s!==this.U;return o&&void 0!==this.U&&this.ot(void 0),(o||this.rt!==this.lt)&&(this.U=s,this.ht=null===(e=i.options)||void 0===e?void 0:e.host,this.ot(this.lt=i.element)),t}ot(t){"function"==typeof this.U?(void 0!==h.get(this.U)&&this.U.call(this.ht,void 0),h.set(this.U,t),void 0!==t&&this.U.call(this.ht,t)):this.U.value=t}get rt(){var t;return"function"==typeof this.U?h.get(this.U):null===(t=this.U)||void 0===t?void 0:t.value}disconnected(){this.rt===this.lt&&this.ot(void 0)}reconnected(){this.ot(this.lt)}});export{e as createRef,n as ref};
+ */const e=()=>new o;class o{}const h=new WeakMap,n=s(class extends t{render(t){return i}update(t,[s]){var e;const o=s!==this.Y;return o&&void 0!==this.Y&&this.rt(void 0),(o||this.lt!==this.ct)&&(this.Y=s,this.dt=null===(e=t.options)||void 0===e?void 0:e.host,this.rt(this.ct=t.element)),i}rt(i){var t;if("function"==typeof this.Y){const s=null!==(t=this.dt)&&void 0!==t?t:globalThis;let e=h.get(s);void 0===e&&(e=new WeakMap,h.set(s,e)),void 0!==e.get(this.Y)&&this.Y.call(this.dt,void 0),e.set(this.Y,i),void 0!==i&&this.Y.call(this.dt,i)}else this.Y.value=i}get lt(){var i,t,s;return"function"==typeof this.Y?null===(t=h.get(null!==(i=this.dt)&&void 0!==i?i:globalThis))||void 0===t?void 0:t.get(this.Y):null===(s=this.Y)||void 0===s?void 0:s.value}disconnected(){this.lt===this.ct&&this.rt(void 0)}reconnected(){this.rt(this.ct)}});export{e as createRef,n as ref};
 //# sourceMappingURL=ref.js.map




diff --git a/front_end/third_party/lit-html/package/directives/ref.js.map b/front_end/third_party/lit-html/package/directives/ref.js.map
index e6c4a99fca79f237f60acef47214938a4ce3b42d..e70fd2e8b4302b0da3b2535be6bd7658e417dae5 100644
--- a/front_end/third_party/lit-html/package/directives/ref.js.map
+++ b/front_end/third_party/lit-html/package/directives/ref.js.map
@@ -1 +1 @@
-{"version":3,"file":"ref.js","sources":["../src/directives/ref.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2020 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\nimport {nothing, ElementPart} from '../lit-html.js';\nimport {directive, AsyncDirective} from '../async-directive.js';\n\n/**\n * Creates a new Ref object, which is container for a reference to an element.\n */\nexport const createRef = <T = Element>() => new Ref<T>();\n\n/**\n * An object that holds a ref value.\n */\nclass Ref<T = Element> {\n  /**\n   * The current Element value of the ref, or else `undefined` if the ref is no\n   * longer rendered.\n   */\n  readonly value?: T;\n}\n\nexport type {Ref};\n\ninterface RefInternal {\n  value: Element | undefined;\n}\n\n// When callbacks are used for refs, this map tracks the last value the callback\n// was called with, for ensuring a directive doesn't clear the ref if the ref\n// has already been rendered to a new spot\nconst lastElementForCallback: WeakMap<Function, Element | undefined> =\n  new WeakMap();\n\nexport type RefOrCallback = Ref | ((el: Element | undefined) => void);\n\nclass RefDirective extends AsyncDirective {\n  private _element?: Element;\n  private _ref?: RefOrCallback;\n  private _context: unknown;\n\n  render(_ref: RefOrCallback) {\n    return nothing;\n  }\n\n  override update(part: ElementPart, [ref]: Parameters<this['render']>) {\n    const refChanged = ref !== this._ref;\n    if (refChanged && this._ref !== undefined) {\n      // The ref passed to the directive has changed;\n      // unset the previous ref's value\n      this._updateRefValue(undefined);\n    }\n    if (refChanged || this._lastElementForRef !== this._element) {\n      // We either got a new ref or this is the first render;\n      // store the ref/element & update the ref value\n      this._ref = ref;\n      this._context = part.options?.host;\n      this._updateRefValue((this._element = part.element));\n    }\n    return nothing;\n  }\n\n  private _updateRefValue(element: Element | undefined) {\n    if (typeof this._ref === 'function') {\n      // If the current ref was called with a previous value, call with\n      // `undefined`; We do this to ensure callbacks are called in a consistent\n      // way regardless of whether a ref might be moving up in the tree (in\n      // which case it would otherwise be called with the new value before the\n      // previous one unsets it) and down in the tree (where it would be unset\n      // before being set)\n      if (lastElementForCallback.get(this._ref) !== undefined) {\n        this._ref.call(this._context, undefined);\n      }\n      lastElementForCallback.set(this._ref, element);\n      // Call the ref with the new element value\n      if (element !== undefined) {\n        this._ref.call(this._context, element);\n      }\n    } else {\n      (this._ref as RefInternal)!.value = element;\n    }\n  }\n\n  private get _lastElementForRef() {\n    return typeof this._ref === 'function'\n      ? lastElementForCallback.get(this._ref)\n      : this._ref?.value;\n  }\n\n  override disconnected() {\n    // Only clear the box if our element is still the one in it (i.e. another\n    // directive instance hasn't rendered its element to it before us); that\n    // only happens in the event of the directive being cleared (not via manual\n    // disconnection)\n    if (this._lastElementForRef === this._element) {\n      this._updateRefValue(undefined);\n    }\n  }\n\n  override reconnected() {\n    // If we were manually disconnected, we can safely put our element back in\n    // the box, since no rendering could have occurred to change its state\n    this._updateRefValue(this._element);\n  }\n}\n\n/**\n * Sets the value of a Ref object or calls a ref callback with the element it's\n * bound to.\n *\n * A Ref object acts as a container for a reference to an element. A ref\n * callback is a function that takes an element as its only argument.\n *\n * The ref directive sets the value of the Ref object or calls the ref callback\n * during rendering, if the referenced element changed.\n *\n * Note: If a ref callback is rendered to a different element position or is\n * removed in a subsequent render, it will first be called with `undefined`,\n * followed by another call with the new element it was rendered to (if any).\n *\n * ```js\n * // Using Ref object\n * const inputRef = createRef();\n * render(html`<input ${ref(inputRef)}>`, container);\n * inputRef.value.focus();\n *\n * // Using callback\n * const callback = (inputElement) => inputElement.focus();\n * render(html`<input ${ref(callback)}>`, container);\n * ```\n */\nexport const ref = directive(RefDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {RefDirective};\n"],"names":["createRef","Ref","lastElementForCallback","WeakMap","ref","directive","AsyncDirective","render","_ref","nothing","update","part","refChanged","this","undefined","_updateRefValue","_lastElementForRef","_element","_context","options","host","element","get","call","set","value","disconnected","reconnected"],"mappings":";;;;;SAWaA,EAAY,IAAmB,IAAIC,EAKhD,MAAMA,GAiBN,MAAMC,EACJ,IAAIC,QAmGOC,EAAMC,EA/FnB,cAA2BC,EAKzBC,OAAOC,GACL,OAAOC,EAGAC,OAAOC,GAAoBP,UAClC,MAAMQ,EAAaR,IAAQS,KAAKL,EAahC,OAZII,QAA4BE,IAAdD,KAAKL,GAGrBK,KAAKE,QAAgBD,IAEnBF,GAAcC,KAAKG,KAAuBH,KAAKI,MAGjDJ,KAAKL,EAAOJ,EACZS,KAAKK,aAAWP,EAAKQ,8BAASC,KAC9BP,KAAKE,GAAiBF,KAAKI,GAAWN,EAAKU,UAEtCZ,EAGDM,GAAgBM,GACG,mBAAdR,KAAKL,QAOgCM,IAA1CZ,EAAuBoB,IAAIT,KAAKL,IAClCK,KAAKL,EAAKe,KAAKV,KAAKK,QAAUJ,GAEhCZ,EAAuBsB,IAAIX,KAAKL,EAAMa,QAEtBP,IAAZO,GACFR,KAAKL,EAAKe,KAAKV,KAAKK,GAAUG,IAG/BR,KAAKL,EAAsBiB,MAAQJ,EAI5BL,eACV,MAA4B,mBAAdH,KAAKL,EACfN,EAAuBoB,IAAIT,KAAKL,aAChCK,KAAKL,wBAAMiB,MAGRC,eAKHb,KAAKG,KAAuBH,KAAKI,IACnCJ,KAAKE,QAAgBD,GAIhBa,cAGPd,KAAKE,GAAgBF,KAAKI"}
\ No newline at end of file
+{"version":3,"file":"ref.js","sources":["../src/directives/ref.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2020 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\nimport {nothing, ElementPart} from '../lit-html.js';\nimport {directive, AsyncDirective} from '../async-directive.js';\n\n/**\n * Creates a new Ref object, which is container for a reference to an element.\n */\nexport const createRef = <T = Element>() => new Ref<T>();\n\n/**\n * An object that holds a ref value.\n */\nclass Ref<T = Element> {\n  /**\n   * The current Element value of the ref, or else `undefined` if the ref is no\n   * longer rendered.\n   */\n  readonly value?: T;\n}\n\nexport type {Ref};\n\ninterface RefInternal {\n  value: Element | undefined;\n}\n\n// When callbacks are used for refs, this map tracks the last value the callback\n// was called with, for ensuring a directive doesn't clear the ref if the ref\n// has already been rendered to a new spot. It is double-keyed on both the\n// context (`options.host`) and the callback, since we auto-bind class methods\n// to `options.host`.\nconst lastElementForContextAndCallback: WeakMap<\n  object,\n  WeakMap<Function, Element | undefined>\n> = new WeakMap();\n\nexport type RefOrCallback = Ref | ((el: Element | undefined) => void);\n\nclass RefDirective extends AsyncDirective {\n  private _element?: Element;\n  private _ref?: RefOrCallback;\n  private _context?: object;\n\n  render(_ref: RefOrCallback) {\n    return nothing;\n  }\n\n  override update(part: ElementPart, [ref]: Parameters<this['render']>) {\n    const refChanged = ref !== this._ref;\n    if (refChanged && this._ref !== undefined) {\n      // The ref passed to the directive has changed;\n      // unset the previous ref's value\n      this._updateRefValue(undefined);\n    }\n    if (refChanged || this._lastElementForRef !== this._element) {\n      // We either got a new ref or this is the first render;\n      // store the ref/element & update the ref value\n      this._ref = ref;\n      this._context = part.options?.host;\n      this._updateRefValue((this._element = part.element));\n    }\n    return nothing;\n  }\n\n  private _updateRefValue(element: Element | undefined) {\n    if (typeof this._ref === 'function') {\n      // If the current ref was called with a previous value, call with\n      // `undefined`; We do this to ensure callbacks are called in a consistent\n      // way regardless of whether a ref might be moving up in the tree (in\n      // which case it would otherwise be called with the new value before the\n      // previous one unsets it) and down in the tree (where it would be unset\n      // before being set). Note that element lookup is keyed by\n      // both the context and the callback, since we allow passing unbound\n      // functions that are called on options.host, and we want to treat\n      // these as unique \"instances\" of a function.\n      const context = this._context ?? globalThis;\n      let lastElementForCallback =\n        lastElementForContextAndCallback.get(context);\n      if (lastElementForCallback === undefined) {\n        lastElementForCallback = new WeakMap();\n        lastElementForContextAndCallback.set(context, lastElementForCallback);\n      }\n      if (lastElementForCallback.get(this._ref) !== undefined) {\n        this._ref.call(this._context, undefined);\n      }\n      lastElementForCallback.set(this._ref, element);\n      // Call the ref with the new element value\n      if (element !== undefined) {\n        this._ref.call(this._context, element);\n      }\n    } else {\n      (this._ref as RefInternal)!.value = element;\n    }\n  }\n\n  private get _lastElementForRef() {\n    return typeof this._ref === 'function'\n      ? lastElementForContextAndCallback\n          .get(this._context ?? globalThis)\n          ?.get(this._ref)\n      : this._ref?.value;\n  }\n\n  override disconnected() {\n    // Only clear the box if our element is still the one in it (i.e. another\n    // directive instance hasn't rendered its element to it before us); that\n    // only happens in the event of the directive being cleared (not via manual\n    // disconnection)\n    if (this._lastElementForRef === this._element) {\n      this._updateRefValue(undefined);\n    }\n  }\n\n  override reconnected() {\n    // If we were manually disconnected, we can safely put our element back in\n    // the box, since no rendering could have occurred to change its state\n    this._updateRefValue(this._element);\n  }\n}\n\n/**\n * Sets the value of a Ref object or calls a ref callback with the element it's\n * bound to.\n *\n * A Ref object acts as a container for a reference to an element. A ref\n * callback is a function that takes an element as its only argument.\n *\n * The ref directive sets the value of the Ref object or calls the ref callback\n * during rendering, if the referenced element changed.\n *\n * Note: If a ref callback is rendered to a different element position or is\n * removed in a subsequent render, it will first be called with `undefined`,\n * followed by another call with the new element it was rendered to (if any).\n *\n * ```js\n * // Using Ref object\n * const inputRef = createRef();\n * render(html`<input ${ref(inputRef)}>`, container);\n * inputRef.value.focus();\n *\n * // Using callback\n * const callback = (inputElement) => inputElement.focus();\n * render(html`<input ${ref(callback)}>`, container);\n * ```\n */\nexport const ref = directive(RefDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {RefDirective};\n"],"names":["createRef","Ref","lastElementForContextAndCallback","WeakMap","ref","directive","AsyncDirective","render","_ref","nothing","update","part","refChanged","this","undefined","_updateRefValue","_lastElementForRef","_element","_context","_a","options","host","element","context","globalThis","lastElementForCallback","get","set","call","value","_b","_c","disconnected","reconnected"],"mappings":";;;;;GAWa,MAAAA,EAAY,IAAmB,IAAIC,EAKhD,MAAMA,GAmBN,MAAMC,EAGF,IAAIC,QA+GKC,EAAMC,EA3GnB,cAA2BC,EAKzBC,OAAOC,GACL,OAAOC,CACR,CAEQC,OAAOC,GAAoBP,UAClC,MAAMQ,EAAaR,IAAQS,KAAKL,EAahC,OAZII,QAA4BE,IAAdD,KAAKL,GAGrBK,KAAKE,QAAgBD,IAEnBF,GAAcC,KAAKG,KAAuBH,KAAKI,MAGjDJ,KAAKL,EAAOJ,EACZS,KAAKK,GAAyB,QAAdC,EAAAR,EAAKS,eAAS,IAAAD,OAAA,EAAAA,EAAAE,KAC9BR,KAAKE,GAAiBF,KAAKI,GAAWN,EAAKW,UAEtCb,CACR,CAEOM,GAAgBO,SACtB,GAAyB,mBAAdT,KAAKL,EAAqB,CAUnC,MAAMe,EAAuB,QAAbJ,EAAAN,KAAKK,UAAQ,IAAAC,EAAAA,EAAIK,WACjC,IAAIC,EACFvB,EAAiCwB,IAAIH,QACRT,IAA3BW,IACFA,EAAyB,IAAItB,QAC7BD,EAAiCyB,IAAIJ,EAASE,SAEFX,IAA1CW,EAAuBC,IAAIb,KAAKL,IAClCK,KAAKL,EAAKoB,KAAKf,KAAKK,QAAUJ,GAEhCW,EAAuBE,IAAId,KAAKL,EAAMc,QAEtBR,IAAZQ,GACFT,KAAKL,EAAKoB,KAAKf,KAAKK,GAAUI,EAEjC,MACET,KAAKL,EAAsBqB,MAAQP,CAEvC,CAEWN,mBACV,MAA4B,mBAAdH,KAAKL,EAEoB,UADnCN,EACGwB,IAAqB,QAAjBP,EAAAN,KAAKK,UAAY,IAAAC,EAAAA,EAAAK,mBAAW,IAAAM,OAAA,EAAAA,EAC/BJ,IAAIb,KAAKL,GACJ,QAATuB,EAAAlB,KAAKL,SAAI,IAAAuB,OAAA,EAAAA,EAAEF,KAChB,CAEQG,eAKHnB,KAAKG,KAAuBH,KAAKI,IACnCJ,KAAKE,QAAgBD,EAExB,CAEQmB,cAGPpB,KAAKE,GAAgBF,KAAKI,GAC3B"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/directives/repeat.js b/front_end/third_party/lit-html/package/directives/repeat.js
index 4f78f038e9e69e12a00186bcaa2637133c19fde2..f93d72b902d4a1565f4b7fac73f2715d2b74b1f1 100644
--- a/front_end/third_party/lit-html/package/directives/repeat.js
+++ b/front_end/third_party/lit-html/package/directives/repeat.js
@@ -4,5 +4,5 @@  * @license
  * Copyright 2017 Google LLC
  * SPDX-License-Identifier: BSD-3-Clause
  */
-const u=(e,s,t)=>{const r=new Map;for(let l=s;l<=t;l++)r.set(e[l],l);return r},c=s(class extends t{constructor(e){if(super(e),e.type!==r.CHILD)throw Error("repeat() can only be used in text expressions")}dt(e,s,t){let r;void 0===t?t=s:void 0!==s&&(r=s);const l=[],o=[];let i=0;for(const s of e)l[i]=r?r(s,i):i,o[i]=t(s,i),i++;return{values:o,keys:l}}render(e,s,t){return this.dt(e,s,t).values}update(s,[t,r,c]){var d;const a=l(s),{values:p,keys:v}=this.dt(t,r,c);if(!Array.isArray(a))return this.ut=v,p;const h=null!==(d=this.ut)&&void 0!==d?d:this.ut=[],m=[];let y,x,j=0,k=a.length-1,w=0,A=p.length-1;for(;j<=k&&w<=A;)if(null===a[j])j++;else if(null===a[k])k--;else if(h[j]===v[w])m[w]=o(a[j],p[w]),j++,w++;else if(h[k]===v[A])m[A]=o(a[k],p[A]),k--,A--;else if(h[j]===v[A])m[A]=o(a[j],p[A]),i(s,m[A+1],a[j]),j++,A--;else if(h[k]===v[w])m[w]=o(a[k],p[w]),i(s,a[j],a[k]),k--,w++;else if(void 0===y&&(y=u(v,w,A),x=u(h,j,k)),y.has(h[j]))if(y.has(h[k])){const e=x.get(v[w]),t=void 0!==e?a[e]:null;if(null===t){const e=i(s,a[j]);o(e,p[w]),m[w]=e}else m[w]=o(t,p[w]),i(s,a[j],t),a[e]=null;w++}else n(a[k]),k--;else n(a[j]),j++;for(;w<=A;){const e=i(s,m[A+1]);o(e,p[w]),m[w++]=e}for(;j<=k;){const e=a[j++];null!==e&&n(e)}return this.ut=v,f(s,m),e}});export{c as repeat};
+const u=(e,s,t)=>{const r=new Map;for(let l=s;l<=t;l++)r.set(e[l],l);return r},c=s(class extends t{constructor(e){if(super(e),e.type!==r.CHILD)throw Error("repeat() can only be used in text expressions")}ht(e,s,t){let r;void 0===t?t=s:void 0!==s&&(r=s);const l=[],o=[];let i=0;for(const s of e)l[i]=r?r(s,i):i,o[i]=t(s,i),i++;return{values:o,keys:l}}render(e,s,t){return this.ht(e,s,t).values}update(s,[t,r,c]){var d;const a=l(s),{values:p,keys:v}=this.ht(t,r,c);if(!Array.isArray(a))return this.ut=v,p;const h=null!==(d=this.ut)&&void 0!==d?d:this.ut=[],m=[];let y,x,j=0,k=a.length-1,w=0,A=p.length-1;for(;j<=k&&w<=A;)if(null===a[j])j++;else if(null===a[k])k--;else if(h[j]===v[w])m[w]=o(a[j],p[w]),j++,w++;else if(h[k]===v[A])m[A]=o(a[k],p[A]),k--,A--;else if(h[j]===v[A])m[A]=o(a[j],p[A]),i(s,m[A+1],a[j]),j++,A--;else if(h[k]===v[w])m[w]=o(a[k],p[w]),i(s,a[j],a[k]),k--,w++;else if(void 0===y&&(y=u(v,w,A),x=u(h,j,k)),y.has(h[j]))if(y.has(h[k])){const e=x.get(v[w]),t=void 0!==e?a[e]:null;if(null===t){const e=i(s,a[j]);o(e,p[w]),m[w]=e}else m[w]=o(t,p[w]),i(s,a[j],t),a[e]=null;w++}else n(a[k]),k--;else n(a[j]),j++;for(;w<=A;){const e=i(s,m[A+1]);o(e,p[w]),m[w++]=e}for(;j<=k;){const e=a[j++];null!==e&&n(e)}return this.ut=v,f(s,m),e}});export{c as repeat};
 //# sourceMappingURL=repeat.js.map




diff --git a/front_end/third_party/lit-html/package/directives/repeat.js.map b/front_end/third_party/lit-html/package/directives/repeat.js.map
index 2dbecc748029ea36abc2823e92b6609b5984ab17..b2fe298f94d028e7beb1d83bbb078be532b14269 100644
--- a/front_end/third_party/lit-html/package/directives/repeat.js.map
+++ b/front_end/third_party/lit-html/package/directives/repeat.js.map
@@ -1 +1 @@
-{"version":3,"file":"repeat.js","sources":["../src/directives/repeat.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {ChildPart, noChange} from '../lit-html.js';\nimport {directive, Directive, PartInfo, PartType} from '../directive.js';\nimport {\n  insertPart,\n  getCommittedValue,\n  removePart,\n  setCommittedValue,\n  setChildPartValue,\n} from '../directive-helpers.js';\n\nexport type KeyFn<T> = (item: T, index: number) => unknown;\nexport type ItemTemplate<T> = (item: T, index: number) => unknown;\n\n// Helper for generating a map of array item to its index over a subset\n// of an array (used to lazily generate `newKeyToIndexMap` and\n// `oldKeyToIndexMap`)\nconst generateMap = (list: unknown[], start: number, end: number) => {\n  const map = new Map<unknown, number>();\n  for (let i = start; i <= end; i++) {\n    map.set(list[i], i);\n  }\n  return map;\n};\n\nclass RepeatDirective extends Directive {\n  private _itemKeys?: unknown[];\n\n  constructor(partInfo: PartInfo) {\n    super(partInfo);\n    if (partInfo.type !== PartType.CHILD) {\n      throw new Error('repeat() can only be used in text expressions');\n    }\n  }\n\n  private _getValuesAndKeys<T>(\n    items: Iterable<T>,\n    keyFnOrTemplate: KeyFn<T> | ItemTemplate<T>,\n    template?: ItemTemplate<T>\n  ) {\n    let keyFn: KeyFn<T> | undefined;\n    if (template === undefined) {\n      template = keyFnOrTemplate;\n    } else if (keyFnOrTemplate !== undefined) {\n      keyFn = keyFnOrTemplate as KeyFn<T>;\n    }\n    const keys = [];\n    const values = [];\n    let index = 0;\n    for (const item of items) {\n      keys[index] = keyFn ? keyFn(item, index) : index;\n      values[index] = template!(item, index);\n      index++;\n    }\n    return {\n      values,\n      keys,\n    };\n  }\n\n  render<T>(items: Iterable<T>, template: ItemTemplate<T>): Array<unknown>;\n  render<T>(\n    items: Iterable<T>,\n    keyFn: KeyFn<T> | ItemTemplate<T>,\n    template: ItemTemplate<T>\n  ): Array<unknown>;\n  render<T>(\n    items: Iterable<T>,\n    keyFnOrTemplate: KeyFn<T> | ItemTemplate<T>,\n    template?: ItemTemplate<T>\n  ) {\n    return this._getValuesAndKeys(items, keyFnOrTemplate, template).values;\n  }\n\n  override update<T>(\n    containerPart: ChildPart,\n    [items, keyFnOrTemplate, template]: [\n      Iterable<T>,\n      KeyFn<T> | ItemTemplate<T>,\n      ItemTemplate<T>\n    ]\n  ) {\n    // Old part & key lists are retrieved from the last update (which may\n    // be primed by hydration)\n    const oldParts = getCommittedValue(\n      containerPart\n    ) as Array<ChildPart | null>;\n    const {values: newValues, keys: newKeys} = this._getValuesAndKeys(\n      items,\n      keyFnOrTemplate,\n      template\n    );\n\n    // We check that oldParts, the committed value, is an Array as an\n    // indicator that the previous value came from a repeat() call. If\n    // oldParts is not an Array then this is the first render and we return\n    // an array for lit-html's array handling to render, and remember the\n    // keys.\n    if (!Array.isArray(oldParts)) {\n      this._itemKeys = newKeys;\n      return newValues;\n    }\n\n    // In SSR hydration it's possible for oldParts to be an arrray but for us\n    // to not have item keys because the update() hasn't run yet. We set the\n    // keys to an empty array. This will cause all oldKey/newKey comparisons\n    // to fail and execution to fall to the last nested brach below which\n    // reuses the oldPart.\n    const oldKeys = (this._itemKeys ??= []);\n\n    // New part list will be built up as we go (either reused from\n    // old parts or created for new keys in this update). This is\n    // saved in the above cache at the end of the update.\n    const newParts: ChildPart[] = [];\n\n    // Maps from key to index for current and previous update; these\n    // are generated lazily only when needed as a performance\n    // optimization, since they are only required for multiple\n    // non-contiguous changes in the list, which are less common.\n    let newKeyToIndexMap!: Map<unknown, number>;\n    let oldKeyToIndexMap!: Map<unknown, number>;\n\n    // Head and tail pointers to old parts and new values\n    let oldHead = 0;\n    let oldTail = oldParts.length - 1;\n    let newHead = 0;\n    let newTail = newValues.length - 1;\n\n    // Overview of O(n) reconciliation algorithm (general approach\n    // based on ideas found in ivi, vue, snabbdom, etc.):\n    //\n    // * We start with the list of old parts and new values (and\n    //   arrays of their respective keys), head/tail pointers into\n    //   each, and we build up the new list of parts by updating\n    //   (and when needed, moving) old parts or creating new ones.\n    //   The initial scenario might look like this (for brevity of\n    //   the diagrams, the numbers in the array reflect keys\n    //   associated with the old parts or new values, although keys\n    //   and parts/values are actually stored in parallel arrays\n    //   indexed using the same head/tail pointers):\n    //\n    //      oldHead v                 v oldTail\n    //   oldKeys:  [0, 1, 2, 3, 4, 5, 6]\n    //   newParts: [ ,  ,  ,  ,  ,  ,  ]\n    //   newKeys:  [0, 2, 1, 4, 3, 7, 6] <- reflects the user's new\n    //                                      item order\n    //      newHead ^                 ^ newTail\n    //\n    // * Iterate old & new lists from both sides, updating,\n    //   swapping, or removing parts at the head/tail locations\n    //   until neither head nor tail can move.\n    //\n    // * Example below: keys at head pointers match, so update old\n    //   part 0 in-place (no need to move it) and record part 0 in\n    //   the `newParts` list. The last thing we do is advance the\n    //   `oldHead` and `newHead` pointers (will be reflected in the\n    //   next diagram).\n    //\n    //      oldHead v                 v oldTail\n    //   oldKeys:  [0, 1, 2, 3, 4, 5, 6]\n    //   newParts: [0,  ,  ,  ,  ,  ,  ] <- heads matched: update 0\n    //   newKeys:  [0, 2, 1, 4, 3, 7, 6]    and advance both oldHead\n    //                                      & newHead\n    //      newHead ^                 ^ newTail\n    //\n    // * Example below: head pointers don't match, but tail\n    //   pointers do, so update part 6 in place (no need to move\n    //   it), and record part 6 in the `newParts` list. Last,\n    //   advance the `oldTail` and `oldHead` pointers.\n    //\n    //         oldHead v              v oldTail\n    //   oldKeys:  [0, 1, 2, 3, 4, 5, 6]\n    //   newParts: [0,  ,  ,  ,  ,  , 6] <- tails matched: update 6\n    //   newKeys:  [0, 2, 1, 4, 3, 7, 6]    and advance both oldTail\n    //                                      & newTail\n    //         newHead ^              ^ newTail\n    //\n    // * If neither head nor tail match; next check if one of the\n    //   old head/tail items was removed. We first need to generate\n    //   the reverse map of new keys to index (`newKeyToIndexMap`),\n    //   which is done once lazily as a performance optimization,\n    //   since we only hit this case if multiple non-contiguous\n    //   changes were made. Note that for contiguous removal\n    //   anywhere in the list, the head and tails would advance\n    //   from either end and pass each other before we get to this\n    //   case and removals would be handled in the final while loop\n    //   without needing to generate the map.\n    //\n    // * Example below: The key at `oldTail` was removed (no longer\n    //   in the `newKeyToIndexMap`), so remove that part from the\n    //   DOM and advance just the `oldTail` pointer.\n    //\n    //         oldHead v           v oldTail\n    //   oldKeys:  [0, 1, 2, 3, 4, 5, 6]\n    //   newParts: [0,  ,  ,  ,  ,  , 6] <- 5 not in new map: remove\n    //   newKeys:  [0, 2, 1, 4, 3, 7, 6]    5 and advance oldTail\n    //         newHead ^           ^ newTail\n    //\n    // * Once head and tail cannot move, any mismatches are due to\n    //   either new or moved items; if a new key is in the previous\n    //   \"old key to old index\" map, move the old part to the new\n    //   location, otherwise create and insert a new part. Note\n    //   that when moving an old part we null its position in the\n    //   oldParts array if it lies between the head and tail so we\n    //   know to skip it when the pointers get there.\n    //\n    // * Example below: neither head nor tail match, and neither\n    //   were removed; so find the `newHead` key in the\n    //   `oldKeyToIndexMap`, and move that old part's DOM into the\n    //   next head position (before `oldParts[oldHead]`). Last,\n    //   null the part in the `oldPart` array since it was\n    //   somewhere in the remaining oldParts still to be scanned\n    //   (between the head and tail pointers) so that we know to\n    //   skip that old part on future iterations.\n    //\n    //         oldHead v        v oldTail\n    //   oldKeys:  [0, 1, -, 3, 4, 5, 6]\n    //   newParts: [0, 2,  ,  ,  ,  , 6] <- stuck: update & move 2\n    //   newKeys:  [0, 2, 1, 4, 3, 7, 6]    into place and advance\n    //                                      newHead\n    //         newHead ^           ^ newTail\n    //\n    // * Note that for moves/insertions like the one above, a part\n    //   inserted at the head pointer is inserted before the\n    //   current `oldParts[oldHead]`, and a part inserted at the\n    //   tail pointer is inserted before `newParts[newTail+1]`. The\n    //   seeming asymmetry lies in the fact that new parts are\n    //   moved into place outside in, so to the right of the head\n    //   pointer are old parts, and to the right of the tail\n    //   pointer are new parts.\n    //\n    // * We always restart back from the top of the algorithm,\n    //   allowing matching and simple updates in place to\n    //   continue...\n    //\n    // * Example below: the head pointers once again match, so\n    //   simply update part 1 and record it in the `newParts`\n    //   array.  Last, advance both head pointers.\n    //\n    //         oldHead v        v oldTail\n    //   oldKeys:  [0, 1, -, 3, 4, 5, 6]\n    //   newParts: [0, 2, 1,  ,  ,  , 6] <- heads matched: update 1\n    //   newKeys:  [0, 2, 1, 4, 3, 7, 6]    and advance both oldHead\n    //                                      & newHead\n    //            newHead ^        ^ newTail\n    //\n    // * As mentioned above, items that were moved as a result of\n    //   being stuck (the final else clause in the code below) are\n    //   marked with null, so we always advance old pointers over\n    //   these so we're comparing the next actual old value on\n    //   either end.\n    //\n    // * Example below: `oldHead` is null (already placed in\n    //   newParts), so advance `oldHead`.\n    //\n    //            oldHead v     v oldTail\n    //   oldKeys:  [0, 1, -, 3, 4, 5, 6] <- old head already used:\n    //   newParts: [0, 2, 1,  ,  ,  , 6]    advance oldHead\n    //   newKeys:  [0, 2, 1, 4, 3, 7, 6]\n    //               newHead ^     ^ newTail\n    //\n    // * Note it's not critical to mark old parts as null when they\n    //   are moved from head to tail or tail to head, since they\n    //   will be outside the pointer range and never visited again.\n    //\n    // * Example below: Here the old tail key matches the new head\n    //   key, so the part at the `oldTail` position and move its\n    //   DOM to the new head position (before `oldParts[oldHead]`).\n    //   Last, advance `oldTail` and `newHead` pointers.\n    //\n    //               oldHead v  v oldTail\n    //   oldKeys:  [0, 1, -, 3, 4, 5, 6]\n    //   newParts: [0, 2, 1, 4,  ,  , 6] <- old tail matches new\n    //   newKeys:  [0, 2, 1, 4, 3, 7, 6]   head: update & move 4,\n    //                                     advance oldTail & newHead\n    //               newHead ^     ^ newTail\n    //\n    // * Example below: Old and new head keys match, so update the\n    //   old head part in place, and advance the `oldHead` and\n    //   `newHead` pointers.\n    //\n    //               oldHead v oldTail\n    //   oldKeys:  [0, 1, -, 3, 4, 5, 6]\n    //   newParts: [0, 2, 1, 4, 3,   ,6] <- heads match: update 3\n    //   newKeys:  [0, 2, 1, 4, 3, 7, 6]    and advance oldHead &\n    //                                      newHead\n    //                  newHead ^  ^ newTail\n    //\n    // * Once the new or old pointers move past each other then all\n    //   we have left is additions (if old list exhausted) or\n    //   removals (if new list exhausted). Those are handled in the\n    //   final while loops at the end.\n    //\n    // * Example below: `oldHead` exceeded `oldTail`, so we're done\n    //   with the main loop.  Create the remaining part and insert\n    //   it at the new head position, and the update is complete.\n    //\n    //                   (oldHead > oldTail)\n    //   oldKeys:  [0, 1, -, 3, 4, 5, 6]\n    //   newParts: [0, 2, 1, 4, 3, 7 ,6] <- create and insert 7\n    //   newKeys:  [0, 2, 1, 4, 3, 7, 6]\n    //                     newHead ^ newTail\n    //\n    // * Note that the order of the if/else clauses is not\n    //   important to the algorithm, as long as the null checks\n    //   come first (to ensure we're always working on valid old\n    //   parts) and that the final else clause comes last (since\n    //   that's where the expensive moves occur). The order of\n    //   remaining clauses is is just a simple guess at which cases\n    //   will be most common.\n    //\n    // * Note, we could calculate the longest\n    //   increasing subsequence (LIS) of old items in new position,\n    //   and only move those not in the LIS set. However that costs\n    //   O(nlogn) time and adds a bit more code, and only helps\n    //   make rare types of mutations require fewer moves. The\n    //   above handles removes, adds, reversal, swaps, and single\n    //   moves of contiguous items in linear time, in the minimum\n    //   number of moves. As the number of multiple moves where LIS\n    //   might help approaches a random shuffle, the LIS\n    //   optimization becomes less helpful, so it seems not worth\n    //   the code at this point. Could reconsider if a compelling\n    //   case arises.\n\n    while (oldHead <= oldTail && newHead <= newTail) {\n      if (oldParts[oldHead] === null) {\n        // `null` means old part at head has already been used\n        // below; skip\n        oldHead++;\n      } else if (oldParts[oldTail] === null) {\n        // `null` means old part at tail has already been used\n        // below; skip\n        oldTail--;\n      } else if (oldKeys[oldHead] === newKeys[newHead]) {\n        // Old head matches new head; update in place\n        newParts[newHead] = setChildPartValue(\n          oldParts[oldHead]!,\n          newValues[newHead]\n        );\n        oldHead++;\n        newHead++;\n      } else if (oldKeys[oldTail] === newKeys[newTail]) {\n        // Old tail matches new tail; update in place\n        newParts[newTail] = setChildPartValue(\n          oldParts[oldTail]!,\n          newValues[newTail]\n        );\n        oldTail--;\n        newTail--;\n      } else if (oldKeys[oldHead] === newKeys[newTail]) {\n        // Old head matches new tail; update and move to new tail\n        newParts[newTail] = setChildPartValue(\n          oldParts[oldHead]!,\n          newValues[newTail]\n        );\n        insertPart(containerPart, newParts[newTail + 1], oldParts[oldHead]!);\n        oldHead++;\n        newTail--;\n      } else if (oldKeys[oldTail] === newKeys[newHead]) {\n        // Old tail matches new head; update and move to new head\n        newParts[newHead] = setChildPartValue(\n          oldParts[oldTail]!,\n          newValues[newHead]\n        );\n        insertPart(containerPart, oldParts[oldHead]!, oldParts[oldTail]!);\n        oldTail--;\n        newHead++;\n      } else {\n        if (newKeyToIndexMap === undefined) {\n          // Lazily generate key-to-index maps, used for removals &\n          // moves below\n          newKeyToIndexMap = generateMap(newKeys, newHead, newTail);\n          oldKeyToIndexMap = generateMap(oldKeys, oldHead, oldTail);\n        }\n        if (!newKeyToIndexMap.has(oldKeys[oldHead])) {\n          // Old head is no longer in new list; remove\n          removePart(oldParts[oldHead]!);\n          oldHead++;\n        } else if (!newKeyToIndexMap.has(oldKeys[oldTail])) {\n          // Old tail is no longer in new list; remove\n          removePart(oldParts[oldTail]!);\n          oldTail--;\n        } else {\n          // Any mismatches at this point are due to additions or\n          // moves; see if we have an old part we can reuse and move\n          // into place\n          const oldIndex = oldKeyToIndexMap.get(newKeys[newHead]);\n          const oldPart = oldIndex !== undefined ? oldParts[oldIndex] : null;\n          if (oldPart === null) {\n            // No old part for this value; create a new one and\n            // insert it\n            const newPart = insertPart(containerPart, oldParts[oldHead]!);\n            setChildPartValue(newPart, newValues[newHead]);\n            newParts[newHead] = newPart;\n          } else {\n            // Reuse old part\n            newParts[newHead] = setChildPartValue(oldPart, newValues[newHead]);\n            insertPart(containerPart, oldParts[oldHead]!, oldPart);\n            // This marks the old part as having been used, so that\n            // it will be skipped in the first two checks above\n            oldParts[oldIndex as number] = null;\n          }\n          newHead++;\n        }\n      }\n    }\n    // Add parts for any remaining new values\n    while (newHead <= newTail) {\n      // For all remaining additions, we insert before last new\n      // tail, since old pointers are no longer valid\n      const newPart = insertPart(containerPart, newParts[newTail + 1]);\n      setChildPartValue(newPart, newValues[newHead]);\n      newParts[newHead++] = newPart;\n    }\n    // Remove any remaining unused old parts\n    while (oldHead <= oldTail) {\n      const oldPart = oldParts[oldHead++];\n      if (oldPart !== null) {\n        removePart(oldPart);\n      }\n    }\n\n    // Save order of new parts for next round\n    this._itemKeys = newKeys;\n    // Directly set part value, bypassing it's dirty-checking\n    setCommittedValue(containerPart, newParts);\n    return noChange;\n  }\n}\n\nexport interface RepeatDirectiveFn {\n  <T>(\n    items: Iterable<T>,\n    keyFnOrTemplate: KeyFn<T> | ItemTemplate<T>,\n    template?: ItemTemplate<T>\n  ): unknown;\n  <T>(items: Iterable<T>, template: ItemTemplate<T>): unknown;\n  <T>(\n    items: Iterable<T>,\n    keyFn: KeyFn<T> | ItemTemplate<T>,\n    template: ItemTemplate<T>\n  ): unknown;\n}\n\n/**\n * A directive that repeats a series of values (usually `TemplateResults`)\n * generated from an iterable, and updates those items efficiently when the\n * iterable changes based on user-provided `keys` associated with each item.\n *\n * Note that if a `keyFn` is provided, strict key-to-DOM mapping is maintained,\n * meaning previous DOM for a given key is moved into the new position if\n * needed, and DOM will never be reused with values for different keys (new DOM\n * will always be created for new keys). This is generally the most efficient\n * way to use `repeat` since it performs minimum unnecessary work for insertions\n * and removals.\n *\n * The `keyFn` takes two parameters, the item and its index, and returns a unique key value.\n *\n * ```js\n * html`\n *   <ol>\n *     ${repeat(this.items, (item) => item.id, (item, index) => {\n *       return html`<li>${index}: ${item.name}</li>`;\n *     })}\n *   </ol>\n * `\n * ```\n *\n * **Important**: If providing a `keyFn`, keys *must* be unique for all items in a\n * given call to `repeat`. The behavior when two or more items have the same key\n * is undefined.\n *\n * If no `keyFn` is provided, this directive will perform similar to mapping\n * items to values, and DOM will be reused against potentially different items.\n */\nexport const repeat = directive(RepeatDirective) as RepeatDirectiveFn;\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {RepeatDirective};\n"],"names":["generateMap","list","start","end","map","Map","i","set","repeat","directive","Directive","constructor","partInfo","super","type","PartType","CHILD","Error","_getValuesAndKeys","items","keyFnOrTemplate","template","keyFn","undefined","keys","values","index","item","render","this","update","containerPart","oldParts","getCommittedValue","newValues","newKeys","Array","isArray","_itemKeys","oldKeys","newParts","newKeyToIndexMap","oldKeyToIndexMap","oldHead","oldTail","length","newHead","newTail","setChildPartValue","insertPart","has","oldIndex","get","oldPart","newPart","removePart","setCommittedValue","noChange"],"mappings":";;;;;;AAsBA,MAAMA,EAAc,CAACC,EAAiBC,EAAeC,KACnD,MAAMC,EAAM,IAAIC,IAChB,IAAK,IAAIC,EAAIJ,EAAOI,GAAKH,EAAKG,IAC5BF,EAAIG,IAAIN,EAAKK,GAAIA,GAEnB,OAAOF,GAqcII,EAASC,EAlctB,cAA8BC,EAG5BC,YAAYC,GAEV,GADAC,MAAMD,GACFA,EAASE,OAASC,EAASC,MAC7B,MAAUC,MAAM,iDAIZC,GACNC,EACAC,EACAC,GAEA,IAAIC,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AWlB,EAAeC,EAASW,GAAWX,EAASY,IACvDA,IACAE,SAQA,QANyBvB,IAArBkB,IAGFA,EAAmBzC,EAAYmC,EAASW,EAASC,GACjDL,EAAmB1C,EAAYuC,EAASI,EAASC,IAE9CH,EAAiBS,IAAIX,EAAQI,IAI3B,GAAKF,EAAiBS,IAAIX,EAAQK,IAIlC,CAIL,MAAMO,EAAWT,EAAiBU,IAAIjB,EAAQW,IACxCO,OAAuB9B,IAAb4B,EAAyBnB,EAASmB,GAAY,KAC9D,GAAgB,OAAZE,EAAkB,CAGpB,MAAMC,EAAUL,EAAWlB,EAAeC,EAASW,IACnDK,EAAkBM,EAASpB,EAAUY,IACrCN,EAASM,GAAWQ,OAGpBd,EAASM,GAAWE,EAAkBK,EAASnB,EAAUY,IACzDG,EAAWlB,EAAeC,EAASW,GAAWU,GAG9CrB,EAASmB,GAAsB,KAEjCL,SAtBAS,EAAWvB,EAASY,IACpBA,SALAW,EAAWvB,EAASW,IACpBA,IA8BN,KAAOG,GAAWC,GAAS,CAGzB,MAAMO,EAAUL,EAAWlB,EAAeS,EAASO,EAAU,IAC7DC,EAAkBM,EAASpB,EAAUY,IACrCN,EAASM,KAAaQ,EAGxB,KAAOX,GAAWC,GAAS,CACzB,MAAMS,EAAUrB,EAASW,KACT,OAAZU,GACFE,EAAWF,GAQf,OAHAxB,KAAKS,GAAYH,EAEjBqB,EAAkBzB,EAAeS,GAC1BiB"}
\ No newline at end of file
+{"version":3,"file":"repeat.js","sources":["../src/directives/repeat.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {ChildPart, noChange} from '../lit-html.js';\nimport {directive, Directive, PartInfo, PartType} from '../directive.js';\nimport {\n  insertPart,\n  getCommittedValue,\n  removePart,\n  setCommittedValue,\n  setChildPartValue,\n} from '../directive-helpers.js';\n\nexport type KeyFn<T> = (item: T, index: number) => unknown;\nexport type ItemTemplate<T> = (item: T, index: number) => unknown;\n\n// Helper for generating a map of array item to its index over a subset\n// of an array (used to lazily generate `newKeyToIndexMap` and\n// `oldKeyToIndexMap`)\nconst generateMap = (list: unknown[], start: number, end: number) => {\n  const map = new Map<unknown, number>();\n  for (let i = start; i <= end; i++) {\n    map.set(list[i], i);\n  }\n  return map;\n};\n\nclass RepeatDirective extends Directive {\n  private _itemKeys?: unknown[];\n\n  constructor(partInfo: PartInfo) {\n    super(partInfo);\n    if (partInfo.type !== PartType.CHILD) {\n      throw new Error('repeat() can only be used in text expressions');\n    }\n  }\n\n  private _getValuesAndKeys<T>(\n    items: Iterable<T>,\n    keyFnOrTemplate: KeyFn<T> | ItemTemplate<T>,\n    template?: ItemTemplate<T>\n  ) {\n    let keyFn: KeyFn<T> | undefined;\n    if (template === undefined) {\n      template = keyFnOrTemplate;\n    } else if (keyFnOrTemplate !== undefined) {\n      keyFn = keyFnOrTemplate as KeyFn<T>;\n    }\n    const keys = [];\n    const values = [];\n    let index = 0;\n    for (const item of items) {\n      keys[index] = keyFn ? keyFn(item, index) : index;\n      values[index] = template!(item, index);\n      index++;\n    }\n    return {\n      values,\n      keys,\n    };\n  }\n\n  render<T>(items: Iterable<T>, template: ItemTemplate<T>): Array<unknown>;\n  render<T>(\n    items: Iterable<T>,\n    keyFn: KeyFn<T> | ItemTemplate<T>,\n    template: ItemTemplate<T>\n  ): Array<unknown>;\n  render<T>(\n    items: Iterable<T>,\n    keyFnOrTemplate: KeyFn<T> | ItemTemplate<T>,\n    template?: ItemTemplate<T>\n  ) {\n    return this._getValuesAndKeys(items, keyFnOrTemplate, template).values;\n  }\n\n  override update<T>(\n    containerPart: ChildPart,\n    [items, keyFnOrTemplate, template]: [\n      Iterable<T>,\n      KeyFn<T> | ItemTemplate<T>,\n      ItemTemplate<T>\n    ]\n  ) {\n    // Old part & key lists are retrieved from the last update (which may\n    // be primed by hydration)\n    const oldParts = getCommittedValue(\n      containerPart\n    ) as Array<ChildPart | null>;\n    const {values: newValues, keys: newKeys} = this._getValuesAndKeys(\n      items,\n      keyFnOrTemplate,\n      template\n    );\n\n    // We check that oldParts, the committed value, is an Array as an\n    // indicator that the previous value came from a repeat() call. If\n    // oldParts is not an Array then this is the first render and we return\n    // an array for lit-html's array handling to render, and remember the\n    // keys.\n    if (!Array.isArray(oldParts)) {\n      this._itemKeys = newKeys;\n      return newValues;\n    }\n\n    // In SSR hydration it's possible for oldParts to be an arrray but for us\n    // to not have item keys because the update() hasn't run yet. We set the\n    // keys to an empty array. This will cause all oldKey/newKey comparisons\n    // to fail and execution to fall to the last nested brach below which\n    // reuses the oldPart.\n    const oldKeys = (this._itemKeys ??= []);\n\n    // New part list will be built up as we go (either reused from\n    // old parts or created for new keys in this update). This is\n    // saved in the above cache at the end of the update.\n    const newParts: ChildPart[] = [];\n\n    // Maps from key to index for current and previous update; these\n    // are generated lazily only when needed as a performance\n    // optimization, since they are only required for multiple\n    // non-contiguous changes in the list, which are less common.\n    let newKeyToIndexMap!: Map<unknown, number>;\n    let oldKeyToIndexMap!: Map<unknown, number>;\n\n    // Head and tail pointers to old parts and new values\n    let oldHead = 0;\n    let oldTail = oldParts.length - 1;\n    let newHead = 0;\n    let newTail = newValues.length - 1;\n\n    // Overview of O(n) reconciliation algorithm (general approach\n    // based on ideas found in ivi, vue, snabbdom, etc.):\n    //\n    // * We start with the list of old parts and new values (and\n    //   arrays of their respective keys), head/tail pointers into\n    //   each, and we build up the new list of parts by updating\n    //   (and when needed, moving) old parts or creating new ones.\n    //   The initial scenario might look like this (for brevity of\n    //   the diagrams, the numbers in the array reflect keys\n    //   associated with the old parts or new values, although keys\n    //   and parts/values are actually stored in parallel arrays\n    //   indexed using the same head/tail pointers):\n    //\n    //      oldHead v                 v oldTail\n    //   oldKeys:  [0, 1, 2, 3, 4, 5, 6]\n    //   newParts: [ ,  ,  ,  ,  ,  ,  ]\n    //   newKeys:  [0, 2, 1, 4, 3, 7, 6] <- reflects the user's new\n    //                                      item order\n    //      newHead ^                 ^ newTail\n    //\n    // * Iterate old & new lists from both sides, updating,\n    //   swapping, or removing parts at the head/tail locations\n    //   until neither head nor tail can move.\n    //\n    // * Example below: keys at head pointers match, so update old\n    //   part 0 in-place (no need to move it) and record part 0 in\n    //   the `newParts` list. The last thing we do is advance the\n    //   `oldHead` and `newHead` pointers (will be reflected in the\n    //   next diagram).\n    //\n    //      oldHead v                 v oldTail\n    //   oldKeys:  [0, 1, 2, 3, 4, 5, 6]\n    //   newParts: [0,  ,  ,  ,  ,  ,  ] <- heads matched: update 0\n    //   newKeys:  [0, 2, 1, 4, 3, 7, 6]    and advance both oldHead\n    //                                      & newHead\n    //      newHead ^                 ^ newTail\n    //\n    // * Example below: head pointers don't match, but tail\n    //   pointers do, so update part 6 in place (no need to move\n    //   it), and record part 6 in the `newParts` list. Last,\n    //   advance the `oldTail` and `oldHead` pointers.\n    //\n    //         oldHead v              v oldTail\n    //   oldKeys:  [0, 1, 2, 3, 4, 5, 6]\n    //   newParts: [0,  ,  ,  ,  ,  , 6] <- tails matched: update 6\n    //   newKeys:  [0, 2, 1, 4, 3, 7, 6]    and advance both oldTail\n    //                                      & newTail\n    //         newHead ^              ^ newTail\n    //\n    // * If neither head nor tail match; next check if one of the\n    //   old head/tail items was removed. We first need to generate\n    //   the reverse map of new keys to index (`newKeyToIndexMap`),\n    //   which is done once lazily as a performance optimization,\n    //   since we only hit this case if multiple non-contiguous\n    //   changes were made. Note that for contiguous removal\n    //   anywhere in the list, the head and tails would advance\n    //   from either end and pass each other before we get to this\n    //   case and removals would be handled in the final while loop\n    //   without needing to generate the map.\n    //\n    // * Example below: The key at `oldTail` was removed (no longer\n    //   in the `newKeyToIndexMap`), so remove that part from the\n    //   DOM and advance just the `oldTail` pointer.\n    //\n    //         oldHead v           v oldTail\n    //   oldKeys:  [0, 1, 2, 3, 4, 5, 6]\n    //   newParts: [0,  ,  ,  ,  ,  , 6] <- 5 not in new map: remove\n    //   newKeys:  [0, 2, 1, 4, 3, 7, 6]    5 and advance oldTail\n    //         newHead ^           ^ newTail\n    //\n    // * Once head and tail cannot move, any mismatches are due to\n    //   either new or moved items; if a new key is in the previous\n    //   \"old key to old index\" map, move the old part to the new\n    //   location, otherwise create and insert a new part. Note\n    //   that when moving an old part we null its position in the\n    //   oldParts array if it lies between the head and tail so we\n    //   know to skip it when the pointers get there.\n    //\n    // * Example below: neither head nor tail match, and neither\n    //   were removed; so find the `newHead` key in the\n    //   `oldKeyToIndexMap`, and move that old part's DOM into the\n    //   next head position (before `oldParts[oldHead]`). Last,\n    //   null the part in the `oldPart` array since it was\n    //   somewhere in the remaining oldParts still to be scanned\n    //   (between the head and tail pointers) so that we know to\n    //   skip that old part on future iterations.\n    //\n    //         oldHead v        v oldTail\n    //   oldKeys:  [0, 1, -, 3, 4, 5, 6]\n    //   newParts: [0, 2,  ,  ,  ,  , 6] <- stuck: update & move 2\n    //   newKeys:  [0, 2, 1, 4, 3, 7, 6]    into place and advance\n    //                                      newHead\n    //         newHead ^           ^ newTail\n    //\n    // * Note that for moves/insertions like the one above, a part\n    //   inserted at the head pointer is inserted before the\n    //   current `oldParts[oldHead]`, and a part inserted at the\n    //   tail pointer is inserted before `newParts[newTail+1]`. The\n    //   seeming asymmetry lies in the fact that new parts are\n    //   moved into place outside in, so to the right of the head\n    //   pointer are old parts, and to the right of the tail\n    //   pointer are new parts.\n    //\n    // * We always restart back from the top of the algorithm,\n    //   allowing matching and simple updates in place to\n    //   continue...\n    //\n    // * Example below: the head pointers once again match, so\n    //   simply update part 1 and record it in the `newParts`\n    //   array.  Last, advance both head pointers.\n    //\n    //         oldHead v        v oldTail\n    //   oldKeys:  [0, 1, -, 3, 4, 5, 6]\n    //   newParts: [0, 2, 1,  ,  ,  , 6] <- heads matched: update 1\n    //   newKeys:  [0, 2, 1, 4, 3, 7, 6]    and advance both oldHead\n    //                                      & newHead\n    //            newHead ^        ^ newTail\n    //\n    // * As mentioned above, items that were moved as a result of\n    //   being stuck (the final else clause in the code below) are\n    //   marked with null, so we always advance old pointers over\n    //   these so we're comparing the next actual old value on\n    //   either end.\n    //\n    // * Example below: `oldHead` is null (already placed in\n    //   newParts), so advance `oldHead`.\n    //\n    //            oldHead v     v oldTail\n    //   oldKeys:  [0, 1, -, 3, 4, 5, 6] <- old head already used:\n    //   newParts: [0, 2, 1,  ,  ,  , 6]    advance oldHead\n    //   newKeys:  [0, 2, 1, 4, 3, 7, 6]\n    //               newHead ^     ^ newTail\n    //\n    // * Note it's not critical to mark old parts as null when they\n    //   are moved from head to tail or tail to head, since they\n    //   will be outside the pointer range and never visited again.\n    //\n    // * Example below: Here the old tail key matches the new head\n    //   key, so the part at the `oldTail` position and move its\n    //   DOM to the new head position (before `oldParts[oldHead]`).\n    //   Last, advance `oldTail` and `newHead` pointers.\n    //\n    //               oldHead v  v oldTail\n    //   oldKeys:  [0, 1, -, 3, 4, 5, 6]\n    //   newParts: [0, 2, 1, 4,  ,  , 6] <- old tail matches new\n    //   newKeys:  [0, 2, 1, 4, 3, 7, 6]   head: update & move 4,\n    //                                     advance oldTail & newHead\n    //               newHead ^     ^ newTail\n    //\n    // * Example below: Old and new head keys match, so update the\n    //   old head part in place, and advance the `oldHead` and\n    //   `newHead` pointers.\n    //\n    //               oldHead v oldTail\n    //   oldKeys:  [0, 1, -, 3, 4, 5, 6]\n    //   newParts: [0, 2, 1, 4, 3,   ,6] <- heads match: update 3\n    //   newKeys:  [0, 2, 1, 4, 3, 7, 6]    and advance oldHead &\n    //                                      newHead\n    //                  newHead ^  ^ newTail\n    //\n    // * Once the new or old pointers move past each other then all\n    //   we have left is additions (if old list exhausted) or\n    //   removals (if new list exhausted). Those are handled in the\n    //   final while loops at the end.\n    //\n    // * Example below: `oldHead` exceeded `oldTail`, so we're done\n    //   with the main loop.  Create the remaining part and insert\n    //   it at the new head position, and the update is complete.\n    //\n    //                   (oldHead > oldTail)\n    //   oldKeys:  [0, 1, -, 3, 4, 5, 6]\n    //   newParts: [0, 2, 1, 4, 3, 7 ,6] <- create and insert 7\n    //   newKeys:  [0, 2, 1, 4, 3, 7, 6]\n    //                     newHead ^ newTail\n    //\n    // * Note that the order of the if/else clauses is not\n    //   important to the algorithm, as long as the null checks\n    //   come first (to ensure we're always working on valid old\n    //   parts) and that the final else clause comes last (since\n    //   that's where the expensive moves occur). The order of\n    //   remaining clauses is is just a simple guess at which cases\n    //   will be most common.\n    //\n    // * Note, we could calculate the longest\n    //   increasing subsequence (LIS) of old items in new position,\n    //   and only move those not in the LIS set. However that costs\n    //   O(nlogn) time and adds a bit more code, and only helps\n    //   make rare types of mutations require fewer moves. The\n    //   above handles removes, adds, reversal, swaps, and single\n    //   moves of contiguous items in linear time, in the minimum\n    //   number of moves. As the number of multiple moves where LIS\n    //   might help approaches a random shuffle, the LIS\n    //   optimization becomes less helpful, so it seems not worth\n    //   the code at this point. Could reconsider if a compelling\n    //   case arises.\n\n    while (oldHead <= oldTail && newHead <= newTail) {\n      if (oldParts[oldHead] === null) {\n        // `null` means old part at head has already been used\n        // below; skip\n        oldHead++;\n      } else if (oldParts[oldTail] === null) {\n        // `null` means old part at tail has already been used\n        // below; skip\n        oldTail--;\n      } else if (oldKeys[oldHead] === newKeys[newHead]) {\n        // Old head matches new head; update in place\n        newParts[newHead] = setChildPartValue(\n          oldParts[oldHead]!,\n          newValues[newHead]\n        );\n        oldHead++;\n        newHead++;\n      } else if (oldKeys[oldTail] === newKeys[newTail]) {\n        // Old tail matches new tail; update in place\n        newParts[newTail] = setChildPartValue(\n          oldParts[oldTail]!,\n          newValues[newTail]\n        );\n        oldTail--;\n        newTail--;\n      } else if (oldKeys[oldHead] === newKeys[newTail]) {\n        // Old head matches new tail; update and move to new tail\n        newParts[newTail] = setChildPartValue(\n          oldParts[oldHead]!,\n          newValues[newTail]\n        );\n        insertPart(containerPart, newParts[newTail + 1], oldParts[oldHead]!);\n        oldHead++;\n        newTail--;\n      } else if (oldKeys[oldTail] === newKeys[newHead]) {\n        // Old tail matches new head; update and move to new head\n        newParts[newHead] = setChildPartValue(\n          oldParts[oldTail]!,\n          newValues[newHead]\n        );\n        insertPart(containerPart, oldParts[oldHead]!, oldParts[oldTail]!);\n        oldTail--;\n        newHead++;\n      } else {\n        if (newKeyToIndexMap === undefined) {\n          // Lazily generate key-to-index maps, used for removals &\n          // moves below\n          newKeyToIndexMap = generateMap(newKeys, newHead, newTail);\n          oldKeyToIndexMap = generateMap(oldKeys, oldHead, oldTail);\n        }\n        if (!newKeyToIndexMap.has(oldKeys[oldHead])) {\n          // Old head is no longer in new list; remove\n          removePart(oldParts[oldHead]!);\n          oldHead++;\n        } else if (!newKeyToIndexMap.has(oldKeys[oldTail])) {\n          // Old tail is no longer in new list; remove\n          removePart(oldParts[oldTail]!);\n          oldTail--;\n        } else {\n          // Any mismatches at this point are due to additions or\n          // moves; see if we have an old part we can reuse and move\n          // into place\n          const oldIndex = oldKeyToIndexMap.get(newKeys[newHead]);\n          const oldPart = oldIndex !== undefined ? oldParts[oldIndex] : null;\n          if (oldPart === null) {\n            // No old part for this value; create a new one and\n            // insert it\n            const newPart = insertPart(containerPart, oldParts[oldHead]!);\n            setChildPartValue(newPart, newValues[newHead]);\n            newParts[newHead] = newPart;\n          } else {\n            // Reuse old part\n            newParts[newHead] = setChildPartValue(oldPart, newValues[newHead]);\n            insertPart(containerPart, oldParts[oldHead]!, oldPart);\n            // This marks the old part as having been used, so that\n            // it will be skipped in the first two checks above\n            oldParts[oldIndex as number] = null;\n          }\n          newHead++;\n        }\n      }\n    }\n    // Add parts for any remaining new values\n    while (newHead <= newTail) {\n      // For all remaining additions, we insert before last new\n      // tail, since old pointers are no longer valid\n      const newPart = insertPart(containerPart, newParts[newTail + 1]);\n      setChildPartValue(newPart, newValues[newHead]);\n      newParts[newHead++] = newPart;\n    }\n    // Remove any remaining unused old parts\n    while (oldHead <= oldTail) {\n      const oldPart = oldParts[oldHead++];\n      if (oldPart !== null) {\n        removePart(oldPart);\n      }\n    }\n\n    // Save order of new parts for next round\n    this._itemKeys = newKeys;\n    // Directly set part value, bypassing it's dirty-checking\n    setCommittedValue(containerPart, newParts);\n    return noChange;\n  }\n}\n\nexport interface RepeatDirectiveFn {\n  <T>(\n    items: Iterable<T>,\n    keyFnOrTemplate: KeyFn<T> | ItemTemplate<T>,\n    template?: ItemTemplate<T>\n  ): unknown;\n  <T>(items: Iterable<T>, template: ItemTemplate<T>): unknown;\n  <T>(\n    items: Iterable<T>,\n    keyFn: KeyFn<T> | ItemTemplate<T>,\n    template: ItemTemplate<T>\n  ): unknown;\n}\n\n/**\n * A directive that repeats a series of values (usually `TemplateResults`)\n * generated from an iterable, and updates those items efficiently when the\n * iterable changes based on user-provided `keys` associated with each item.\n *\n * Note that if a `keyFn` is provided, strict key-to-DOM mapping is maintained,\n * meaning previous DOM for a given key is moved into the new position if\n * needed, and DOM will never be reused with values for different keys (new DOM\n * will always be created for new keys). This is generally the most efficient\n * way to use `repeat` since it performs minimum unnecessary work for insertions\n * and removals.\n *\n * The `keyFn` takes two parameters, the item and its index, and returns a unique key value.\n *\n * ```js\n * html`\n *   <ol>\n *     ${repeat(this.items, (item) => item.id, (item, index) => {\n *       return html`<li>${index}: ${item.name}</li>`;\n *     })}\n *   </ol>\n * `\n * ```\n *\n * **Important**: If providing a `keyFn`, keys *must* be unique for all items in a\n * given call to `repeat`. The behavior when two or more items have the same key\n * is undefined.\n *\n * If no `keyFn` is provided, this directive will perform similar to mapping\n * items to values, and DOM will be reused against potentially different items.\n */\nexport const repeat = directive(RepeatDirective) as RepeatDirectiveFn;\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {RepeatDirective};\n"],"names":["generateMap","list","start","end","map","Map","i","set","repeat","directive","Directive","constructor","partInfo","super","type","PartType","CHILD","Error","_getValuesAndKeys","items","keyFnOrTemplate","template","keyFn","undefined","keys","values","index","item","render","this","update","containerPart","oldParts","getCommittedValue","newValues","newKeys","Array","isArray","_itemKeys","oldKeys","_a","newParts","newKeyToIndexMap","oldKeyToIndexMap","oldHead","oldTail","length","newHead","newTail","setChildPartValue","insertPart","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,OAAZU,GACFE,EAAWF,EAEd,CAMD,OAHAzB,KAAKS,GAAYH,EAEjBsB,EAAkB1B,EAAeU,GAC1BiB,CACR"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/directives/style-map.d.ts b/front_end/third_party/lit-html/package/directives/style-map.d.ts
index 29c6cfe33a59cb58f9bf80eb81d83b2b9b085f2f..dd74ecededf7f6deed4c9430754c4a35bb87f192 100644
--- a/front_end/third_party/lit-html/package/directives/style-map.d.ts
+++ b/front_end/third_party/lit-html/package/directives/style-map.d.ts
@@ -13,12 +13,12 @@  * `'background-color'`, or a valid JavaScript camel case property name
  * for CSSStyleDeclaration like `backgroundColor`.
  */
 export interface StyleInfo {
-    readonly [name: string]: string | undefined | null;
+    [name: string]: string | undefined | null;
 }
 declare class StyleMapDirective extends Directive {
     _previousStyleProperties?: Set<string>;
     constructor(partInfo: PartInfo);
-/**
+ * Copyright 2018 Google LLC
  *
     update(part: AttributePart, [styleInfo]: DirectiveParameters<this>): string | typeof noChange;
 }
@@ -26,24 +26,26 @@ /**
  * A directive that applies CSS properties to an element.
  *
  * `styleMap` can only be used in the `style` attribute and must be the only
+ * expression in the attribute. It takes the property names in the
+ * {@link StyleInfo styleInfo} object and adds the property values as CSS
+ * SPDX-License-Identifier: BSD-3-Clause
  * @license
+ * SPDX-License-Identifier: BSD-3-Clause
  * Copyright 2018 Google LLC
- * @license
+ * SPDX-License-Identifier: BSD-3-Clause
  * SPDX-License-Identifier: BSD-3-Clause
- * @license
+ * SPDX-License-Identifier: BSD-3-Clause
  */
- * @license
+ * SPDX-License-Identifier: BSD-3-Clause
 import { AttributePart, noChange } from '../lit-html.js';
- * assumed to be camelCased JavaScript property names and set on the element's
- * style object using property assignment, allowing the style object to
- * translate JavaScript-style names to CSS property names.
  *
  * For example `styleMap({backgroundColor: 'red', 'border-top': '5px', '--size':
  * '0'})` sets the `background-color`, `border-top` and `--size` properties.
  *
  * @param styleInfo
+ * @see {@link https://lit.dev/docs/templates/directives/#stylemap styleMap code samples on Lit.dev}
  */
-export declare const styleMap: (styleInfo: StyleInfo) => import("../directive.js").DirectiveResult<typeof StyleMapDirective>;
+export declare const styleMap: (styleInfo: Readonly<StyleInfo>) => import("../directive.js").DirectiveResult<typeof StyleMapDirective>;
 /**
  * The type of the class that powers this directive. Necessary for naming the
  * directive's return type.




diff --git a/front_end/third_party/lit-html/package/directives/style-map.d.ts.map b/front_end/third_party/lit-html/package/directives/style-map.d.ts.map
index d154524f9692d5bfc5fc39038e9f39a685fc097f..220c753bdc870ad51fa51076b8a60945a2e396d0 100644
--- a/front_end/third_party/lit-html/package/directives/style-map.d.ts.map
+++ b/front_end/third_party/lit-html/package/directives/style-map.d.ts.map
@@ -1 +1 @@
-{"version":3,"file":"style-map.d.ts","sourceRoot":"","sources":["../../src/directives/style-map.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAC,aAAa,EAAE,QAAQ,EAAC,MAAM,gBAAgB,CAAC;AACvD,OAAO,EAEL,SAAS,EACT,mBAAmB,EACnB,QAAQ,EAET,MAAM,iBAAiB,CAAC;AAEzB;;;;;;GAMG;AACH,MAAM,WAAW,SAAS;IACxB,QAAQ,EAAE,IAAI,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS,GAAG,IAAI,CAAC;CACpD;AAED,cAAM,iBAAkB,SAAQ,SAAS;IACvC,wBAAwB,CAAC,EAAE,GAAG,CAAC,MAAM,CAAC,CAAC;gBAE3B,QAAQ,EAAE,QAAQ;IAc9B,MAAM,CAAC,SAAS,EAAE,SAAS;IAoBlB,MAAM,CAAC,IAAI,EAAE,aAAa,EAAE,CAAC,SAAS,CAAC,EAAE,mBAAmB,CAAC,IAAI,CAAC;CA4C5E;AAED;;;;;;;;;;;;;;;;GAgBG;AACH,eAAO,MAAM,QAAQ,+FAA+B,CAAC;AAErD;;;GAGG;AACH,YAAY,EAAC,iBAAiB,EAAC,CAAC"}
\ No newline at end of file
+{"version":3,"file":"style-map.d.ts","sourceRoot":"","sources":["../../src/directives/style-map.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAC,aAAa,EAAE,QAAQ,EAAC,MAAM,gBAAgB,CAAC;AACvD,OAAO,EAEL,SAAS,EACT,mBAAmB,EACnB,QAAQ,EAET,MAAM,iBAAiB,CAAC;AAEzB;;;;;;GAMG;AACH,MAAM,WAAW,SAAS;IACxB,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS,GAAG,IAAI,CAAC;CAC3C;AAED,cAAM,iBAAkB,SAAQ,SAAS;IACvC,wBAAwB,CAAC,EAAE,GAAG,CAAC,MAAM,CAAC,CAAC;gBAE3B,QAAQ,EAAE,QAAQ;IAc9B,MAAM,CAAC,SAAS,EAAE,QAAQ,CAAC,SAAS,CAAC;IAoB5B,MAAM,CAAC,IAAI,EAAE,aAAa,EAAE,CAAC,SAAS,CAAC,EAAE,mBAAmB,CAAC,IAAI,CAAC;CA4C5E;AAED;;;;;;;;;;;;;;;;;GAiBG;AACH,eAAO,MAAM,QAAQ,yGAA+B,CAAC;AAErD;;;GAGG;AACH,YAAY,EAAC,iBAAiB,EAAC,CAAC"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/directives/style-map.js b/front_end/third_party/lit-html/package/directives/style-map.js
index da1264ac7449e7d1f62e29f35c5d6117aa605ab3..c89e0067e4cb7a275c858754150fa62918f8f26d 100644
--- a/front_end/third_party/lit-html/package/directives/style-map.js
+++ b/front_end/third_party/lit-html/package/directives/style-map.js
@@ -3,5 +3,5 @@ /**
  * @license
  * Copyright 2018 Google LLC
  * SPDX-License-Identifier: BSD-3-Clause
- */const i=e(class extends r{constructor(t){var e;if(super(t),t.type!==s.ATTRIBUTE||"style"!==t.name||(null===(e=t.strings)||void 0===e?void 0:e.length)>2)throw Error("The `styleMap` directive must be used in the `style` attribute and must be the only part in the attribute.")}render(t){return Object.keys(t).reduce(((e,r)=>{const s=t[r];return null==s?e:e+`${r=r.replace(/(?:^(webkit|moz|ms|o)|)(?=[A-Z])/g,"-$&").toLowerCase()}:${s};`}),"")}update(e,[r]){const{style:s}=e.element;if(void 0===this.ct){this.ct=new Set;for(const t in r)this.ct.add(t);return this.render(r)}this.ct.forEach((t=>{null==r[t]&&(this.ct.delete(t),t.includes("-")?s.removeProperty(t):s[t]="")}));for(const t in r){const e=r[t];null!=e&&(this.ct.add(t),t.includes("-")?s.setProperty(t,e):s[t]=e)}return t}});export{i as styleMap};
+ */const i=e(class extends r{constructor(t){var e;if(super(t),t.type!==s.ATTRIBUTE||"style"!==t.name||(null===(e=t.strings)||void 0===e?void 0:e.length)>2)throw Error("The `styleMap` directive must be used in the `style` attribute and must be the only part in the attribute.")}render(t){return Object.keys(t).reduce(((e,r)=>{const s=t[r];return null==s?e:e+`${r=r.replace(/(?:^(webkit|moz|ms|o)|)(?=[A-Z])/g,"-$&").toLowerCase()}:${s};`}),"")}update(e,[r]){const{style:s}=e.element;if(void 0===this.vt){this.vt=new Set;for(const t in r)this.vt.add(t);return this.render(r)}this.vt.forEach((t=>{null==r[t]&&(this.vt.delete(t),t.includes("-")?s.removeProperty(t):s[t]="")}));for(const t in r){const e=r[t];null!=e&&(this.vt.add(t),t.includes("-")?s.setProperty(t,e):s[t]=e)}return t}});export{i as styleMap};
 //# sourceMappingURL=style-map.js.map




diff --git a/front_end/third_party/lit-html/package/directives/style-map.js.map b/front_end/third_party/lit-html/package/directives/style-map.js.map
index d851e537d794918080b3cda068f6f1ff5971037b..19fe1b314238d010c68287274f7fd3f150d832d0 100644
--- a/front_end/third_party/lit-html/package/directives/style-map.js.map
+++ b/front_end/third_party/lit-html/package/directives/style-map.js.map
@@ -1 +1 @@
-{"version":3,"file":"style-map.js","sources":["../src/directives/style-map.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2018 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {AttributePart, noChange} from '../lit-html.js';\nimport {\n  directive,\n  Directive,\n  DirectiveParameters,\n  PartInfo,\n  PartType,\n} from '../directive.js';\n\n/**\n * A key-value set of CSS properties and values.\n *\n * The key should be either a valid CSS property name string, like\n * `'background-color'`, or a valid JavaScript camel case property name\n * for CSSStyleDeclaration like `backgroundColor`.\n */\nexport interface StyleInfo {\n  readonly [name: string]: string | undefined | null;\n}\n\nclass StyleMapDirective extends Directive {\n  _previousStyleProperties?: Set<string>;\n\n  constructor(partInfo: PartInfo) {\n    super(partInfo);\n    if (\n      partInfo.type !== PartType.ATTRIBUTE ||\n      partInfo.name !== 'style' ||\n      (partInfo.strings?.length as number) > 2\n    ) {\n      throw new Error(\n        'The `styleMap` directive must be used in the `style` attribute ' +\n          'and must be the only part in the attribute.'\n      );\n    }\n  }\n\n  render(styleInfo: StyleInfo) {\n    return Object.keys(styleInfo).reduce((style, prop) => {\n      const value = styleInfo[prop];\n      if (value == null) {\n        return style;\n      }\n      // Convert property names from camel-case to dash-case, i.e.:\n      //  `backgroundColor` -> `background-color`\n      // Vendor-prefixed names need an extra `-` appended to front:\n      //  `webkitAppearance` -> `-webkit-appearance`\n      // Exception is any property name containing a dash, including\n      // custom properties; we assume these are already dash-cased i.e.:\n      //  `--my-button-color` --> `--my-button-color`\n      prop = prop\n        .replace(/(?:^(webkit|moz|ms|o)|)(?=[A-Z])/g, '-$&')\n        .toLowerCase();\n      return style + `${prop}:${value};`;\n    }, '');\n  }\n\n  override update(part: AttributePart, [styleInfo]: DirectiveParameters<this>) {\n    const {style} = part.element as HTMLElement;\n\n    if (this._previousStyleProperties === undefined) {\n      this._previousStyleProperties = new Set();\n      for (const name in styleInfo) {\n        this._previousStyleProperties.add(name);\n      }\n      return this.render(styleInfo);\n    }\n\n    // Remove old properties that no longer exist in styleInfo\n    // We use forEach() instead of for-of so that re don't require down-level\n    // iteration.\n    this._previousStyleProperties!.forEach((name) => {\n      // If the name isn't in styleInfo or it's null/undefined\n      if (styleInfo[name] == null) {\n        this._previousStyleProperties!.delete(name);\n        if (name.includes('-')) {\n          style.removeProperty(name);\n        } else {\n          // Note reset using empty string (vs null) as IE11 does not always\n          // reset via null (https://developer.mozilla.org/en-US/docs/Web/API/ElementCSSInlineStyle/style#setting_styles)\n          // eslint-disable-next-line @typescript-eslint/no-explicit-any\n          (style as any)[name] = '';\n        }\n      }\n    });\n\n    // Add or update properties\n    for (const name in styleInfo) {\n      const value = styleInfo[name];\n      if (value != null) {\n        this._previousStyleProperties.add(name);\n        if (name.includes('-')) {\n          style.setProperty(name, value);\n        } else {\n          // eslint-disable-next-line @typescript-eslint/no-explicit-any\n          (style as any)[name] = value;\n        }\n      }\n    }\n    return noChange;\n  }\n}\n\n/**\n * A directive that applies CSS properties to an element.\n *\n * `styleMap` can only be used in the `style` attribute and must be the only\n * expression in the attribute. It takes the property names in the `styleInfo`\n * object and adds the property values as CSS properties. Property names with\n * dashes (`-`) are assumed to be valid CSS property names and set on the\n * element's style object using `setProperty()`. Names without dashes are\n * assumed to be camelCased JavaScript property names and set on the element's\n * style object using property assignment, allowing the style object to\n * translate JavaScript-style names to CSS property names.\n *\n * For example `styleMap({backgroundColor: 'red', 'border-top': '5px', '--size':\n * '0'})` sets the `background-color`, `border-top` and `--size` properties.\n *\n * @param styleInfo\n */\nexport const styleMap = directive(StyleMapDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {StyleMapDirective};\n"],"names":["styleMap","directive","Directive","constructor","partInfo","super","type","PartType","ATTRIBUTE","name","strings","length","Error","render","styleInfo","Object","keys","reduce","style","prop","value","replace","toLowerCase","update","part","element","undefined","this","_previousStyleProperties","Set","add","forEach","delete","includes","removeProperty","setProperty","noChange"],"mappings":";;;;;SA8HaA,EAAWC,EApGxB,cAAgCC,EAG9BC,YAAYC,SAEV,GADAC,MAAMD,GAEJA,EAASE,OAASC,EAASC,WACT,UAAlBJ,EAASK,iBACRL,EAASM,8BAASC,QAAoB,EAEvC,MAAUC,MACR,8GAMNC,OAAOC,GACL,OAAOC,OAAOC,KAAKF,GAAWG,QAAO,CAACC,EAAOC,KAC3C,MAAMC,EAAQN,EAAUK,GACxB,OAAa,MAATC,EACKF,EAYFA,EAAQ,GAHfC,EAAOA,EACJE,QAAQ,oCAAqC,OAC7CC,iBACuBF,OACzB,IAGIG,OAAOC,GAAsBV,IACpC,MAAMI,MAACA,GAASM,EAAKC,QAErB,QAAsCC,IAAlCC,KAAKC,GAAwC,CAC/CD,KAAKC,GAA2B,IAAIC,IACpC,IAAK,MAAMpB,KAAQK,EACjBa,KAAKC,GAAyBE,IAAIrB,GAEpC,OAAOkB,KAAKd,OAAOC,GAMrBa,KAAKC,GAA0BG,SAAStB,IAEf,MAAnBK,EAAUL,KACZkB,KAAKC,GAA0BI,OAAOvB,GAClCA,EAAKwB,SAAS,KAChBf,EAAMgB,eAAezB,GAKpBS,EAAcT,GAAQ,OAM7B,IAAK,MAAMA,KAAQK,EAAW,CAC5B,MAAMM,EAAQN,EAAUL,GACX,MAATW,IACFO,KAAKC,GAAyBE,IAAIrB,GAC9BA,EAAKwB,SAAS,KAChBf,EAAMiB,YAAY1B,EAAMW,GAGvBF,EAAcT,GAAQW,GAI7B,OAAOgB"}
\ No newline at end of file
+{"version":3,"file":"style-map.js","sources":["../src/directives/style-map.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2018 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {AttributePart, noChange} from '../lit-html.js';\nimport {\n  directive,\n  Directive,\n  DirectiveParameters,\n  PartInfo,\n  PartType,\n} from '../directive.js';\n\n/**\n * A key-value set of CSS properties and values.\n *\n * The key should be either a valid CSS property name string, like\n * `'background-color'`, or a valid JavaScript camel case property name\n * for CSSStyleDeclaration like `backgroundColor`.\n */\nexport interface StyleInfo {\n  [name: string]: string | undefined | null;\n}\n\nclass StyleMapDirective extends Directive {\n  _previousStyleProperties?: Set<string>;\n\n  constructor(partInfo: PartInfo) {\n    super(partInfo);\n    if (\n      partInfo.type !== PartType.ATTRIBUTE ||\n      partInfo.name !== 'style' ||\n      (partInfo.strings?.length as number) > 2\n    ) {\n      throw new Error(\n        'The `styleMap` directive must be used in the `style` attribute ' +\n          'and must be the only part in the attribute.'\n      );\n    }\n  }\n\n  render(styleInfo: Readonly<StyleInfo>) {\n    return Object.keys(styleInfo).reduce((style, prop) => {\n      const value = styleInfo[prop];\n      if (value == null) {\n        return style;\n      }\n      // Convert property names from camel-case to dash-case, i.e.:\n      //  `backgroundColor` -> `background-color`\n      // Vendor-prefixed names need an extra `-` appended to front:\n      //  `webkitAppearance` -> `-webkit-appearance`\n      // Exception is any property name containing a dash, including\n      // custom properties; we assume these are already dash-cased i.e.:\n      //  `--my-button-color` --> `--my-button-color`\n      prop = prop\n        .replace(/(?:^(webkit|moz|ms|o)|)(?=[A-Z])/g, '-$&')\n        .toLowerCase();\n      return style + `${prop}:${value};`;\n    }, '');\n  }\n\n  override update(part: AttributePart, [styleInfo]: DirectiveParameters<this>) {\n    const {style} = part.element as HTMLElement;\n\n    if (this._previousStyleProperties === undefined) {\n      this._previousStyleProperties = new Set();\n      for (const name in styleInfo) {\n        this._previousStyleProperties.add(name);\n      }\n      return this.render(styleInfo);\n    }\n\n    // Remove old properties that no longer exist in styleInfo\n    // We use forEach() instead of for-of so that re don't require down-level\n    // iteration.\n    this._previousStyleProperties!.forEach((name) => {\n      // If the name isn't in styleInfo or it's null/undefined\n      if (styleInfo[name] == null) {\n        this._previousStyleProperties!.delete(name);\n        if (name.includes('-')) {\n          style.removeProperty(name);\n        } else {\n          // Note reset using empty string (vs null) as IE11 does not always\n          // reset via null (https://developer.mozilla.org/en-US/docs/Web/API/ElementCSSInlineStyle/style#setting_styles)\n          // eslint-disable-next-line @typescript-eslint/no-explicit-any\n          (style as any)[name] = '';\n        }\n      }\n    });\n\n    // Add or update properties\n    for (const name in styleInfo) {\n      const value = styleInfo[name];\n      if (value != null) {\n        this._previousStyleProperties.add(name);\n        if (name.includes('-')) {\n          style.setProperty(name, value);\n        } else {\n          // eslint-disable-next-line @typescript-eslint/no-explicit-any\n          (style as any)[name] = value;\n        }\n      }\n    }\n    return noChange;\n  }\n}\n\n/**\n * A directive that applies CSS properties to an element.\n *\n * `styleMap` can only be used in the `style` attribute and must be the only\n * expression in the attribute. It takes the property names in the\n * {@link StyleInfo styleInfo} object and adds the property values as CSS\n * properties. Property names with dashes (`-`) are assumed to be valid CSS\n * property names and set on the element's style object using `setProperty()`.\n * Names without dashes are assumed to be camelCased JavaScript property names\n * and set on the element's style object using property assignment, allowing the\n * style object to translate JavaScript-style names to CSS property names.\n *\n * For example `styleMap({backgroundColor: 'red', 'border-top': '5px', '--size':\n * '0'})` sets the `background-color`, `border-top` and `--size` properties.\n *\n * @param styleInfo\n * @see {@link https://lit.dev/docs/templates/directives/#stylemap styleMap code samples on Lit.dev}\n */\nexport const styleMap = directive(StyleMapDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {StyleMapDirective};\n"],"names":["styleMap","directive","Directive","constructor","partInfo","super","type","PartType","ATTRIBUTE","name","_a","strings","length","Error","render","styleInfo","Object","keys","reduce","style","prop","value","replace","toLowerCase","update","part","element","undefined","this","_previousStyleProperties","Set","add","forEach","delete","includes","removeProperty","setProperty","noChange"],"mappings":";;;;;SA+HaA,EAAWC,EArGxB,cAAgCC,EAG9BC,YAAYC,SAEV,GADAC,MAAMD,GAEJA,EAASE,OAASC,EAASC,WACT,UAAlBJ,EAASK,eACRC,EAAAN,EAASO,8BAASC,QAAoB,EAEvC,MAAUC,MACR,6GAIL,CAEDC,OAAOC,GACL,OAAOC,OAAOC,KAAKF,GAAWG,QAAO,CAACC,EAAOC,KAC3C,MAAMC,EAAQN,EAAUK,GACxB,OAAa,MAATC,EACKF,EAYFA,EAAQ,GAHfC,EAAOA,EACJE,QAAQ,oCAAqC,OAC7CC,iBACuBF,IAAQ,GACjC,GACJ,CAEQG,OAAOC,GAAsBV,IACpC,MAAMI,MAACA,GAASM,EAAKC,QAErB,QAAsCC,IAAlCC,KAAKC,GAAwC,CAC/CD,KAAKC,GAA2B,IAAIC,IACpC,IAAK,MAAMrB,KAAQM,EACjBa,KAAKC,GAAyBE,IAAItB,GAEpC,OAAOmB,KAAKd,OAAOC,EACpB,CAKDa,KAAKC,GAA0BG,SAASvB,IAEf,MAAnBM,EAAUN,KACZmB,KAAKC,GAA0BI,OAAOxB,GAClCA,EAAKyB,SAAS,KAChBf,EAAMgB,eAAe1B,GAKpBU,EAAcV,GAAQ,GAE1B,IAIH,IAAK,MAAMA,KAAQM,EAAW,CAC5B,MAAMM,EAAQN,EAAUN,GACX,MAATY,IACFO,KAAKC,GAAyBE,IAAItB,GAC9BA,EAAKyB,SAAS,KAChBf,EAAMiB,YAAY3B,EAAMY,GAGvBF,EAAcV,GAAQY,EAG5B,CACD,OAAOgB,CACR"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/directives/template-content.js b/front_end/third_party/lit-html/package/directives/template-content.js
index eaad6b8dc6cf6b3a93ac2eba87a68ab55f51e9f1..df30e5b53a3d78d76e55ef72f7d08cce66477cb0 100644
--- a/front_end/third_party/lit-html/package/directives/template-content.js
+++ b/front_end/third_party/lit-html/package/directives/template-content.js
@@ -3,5 +3,5 @@ /**
  * @license
  * Copyright 2020 Google LLC
  * SPDX-License-Identifier: BSD-3-Clause
- */const o=r(class extends e{constructor(t){if(super(t),t.type!==n.CHILD)throw Error("templateContent can only be used in child bindings")}render(r){return this.vt===r?t:(this.vt=r,document.importNode(r.content,!0))}});export{o as templateContent};
+ */const o=r(class extends e{constructor(t){if(super(t),t.type!==n.CHILD)throw Error("templateContent can only be used in child bindings")}render(r){return this.ft===r?t:(this.ft=r,document.importNode(r.content,!0))}});export{o as templateContent};
 //# sourceMappingURL=template-content.js.map




diff --git a/front_end/third_party/lit-html/package/directives/template-content.js.map b/front_end/third_party/lit-html/package/directives/template-content.js.map
index 9c46923048ce791d93e4ecdea2dd47888382e2f1..fdcc7bea672cabd7eb9cfee1f6186f8568442441 100644
--- a/front_end/third_party/lit-html/package/directives/template-content.js.map
+++ b/front_end/third_party/lit-html/package/directives/template-content.js.map
@@ -1 +1 @@
-{"version":3,"file":"template-content.js","sources":["../src/directives/template-content.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2020 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {noChange} from '../lit-html.js';\nimport {directive, Directive, PartInfo, PartType} from '../directive.js';\n\nclass TemplateContentDirective extends Directive {\n  private _previousTemplate?: HTMLTemplateElement;\n\n  constructor(partInfo: PartInfo) {\n    super(partInfo);\n    if (partInfo.type !== PartType.CHILD) {\n      throw new Error('templateContent can only be used in child bindings');\n    }\n  }\n\n  render(template: HTMLTemplateElement) {\n    if (this._previousTemplate === template) {\n      return noChange;\n    }\n    this._previousTemplate = template;\n    return document.importNode(template.content, true);\n  }\n}\n\n/**\n * Renders the content of a template element as HTML.\n *\n * Note, the template should be developer controlled and not user controlled.\n * Rendering a user-controlled template with this directive\n * could lead to cross-site-scripting vulnerabilities.\n */\nexport const templateContent = directive(TemplateContentDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {TemplateContentDirective};\n"],"names":["templateContent","directive","Directive","constructor","partInfo","super","type","PartType","CHILD","Error","render","template","this","_previousTemplate","noChange","document","importNode","content"],"mappings":";;;;;SAmCaA,EAAkBC,EA1B/B,cAAuCC,EAGrCC,YAAYC,GAEV,GADAC,MAAMD,GACFA,EAASE,OAASC,EAASC,MAC7B,MAAUC,MAAM,sDAIpBC,OAAOC,GACL,OAAIC,KAAKC,KAAsBF,EACtBG,GAETF,KAAKC,GAAoBF,EAClBI,SAASC,WAAWL,EAASM,SAAS"}
\ No newline at end of file
+{"version":3,"file":"template-content.js","sources":["../src/directives/template-content.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2020 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {noChange} from '../lit-html.js';\nimport {directive, Directive, PartInfo, PartType} from '../directive.js';\n\nclass TemplateContentDirective extends Directive {\n  private _previousTemplate?: HTMLTemplateElement;\n\n  constructor(partInfo: PartInfo) {\n    super(partInfo);\n    if (partInfo.type !== PartType.CHILD) {\n      throw new Error('templateContent can only be used in child bindings');\n    }\n  }\n\n  render(template: HTMLTemplateElement) {\n    if (this._previousTemplate === template) {\n      return noChange;\n    }\n    this._previousTemplate = template;\n    return document.importNode(template.content, true);\n  }\n}\n\n/**\n * Renders the content of a template element as HTML.\n *\n * Note, the template should be developer controlled and not user controlled.\n * Rendering a user-controlled template with this directive\n * could lead to cross-site-scripting vulnerabilities.\n */\nexport const templateContent = directive(TemplateContentDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {TemplateContentDirective};\n"],"names":["templateContent","directive","Directive","constructor","partInfo","super","type","PartType","CHILD","Error","render","template","this","_previousTemplate","noChange","document","importNode","content"],"mappings":";;;;;SAmCaA,EAAkBC,EA1B/B,cAAuCC,EAGrCC,YAAYC,GAEV,GADAC,MAAMD,GACFA,EAASE,OAASC,EAASC,MAC7B,MAAUC,MAAM,qDAEnB,CAEDC,OAAOC,GACL,OAAIC,KAAKC,KAAsBF,EACtBG,GAETF,KAAKC,GAAoBF,EAClBI,SAASC,WAAWL,EAASM,SAAS,GAC9C"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/directives/unsafe-html.js b/front_end/third_party/lit-html/package/directives/unsafe-html.js
index ce5c438061ab61549176cef49ecd2792a6997a13..2e0425779ba9df456717556f9544e4ea4a93bbe3 100644
--- a/front_end/third_party/lit-html/package/directives/unsafe-html.js
+++ b/front_end/third_party/lit-html/package/directives/unsafe-html.js
@@ -3,5 +3,5 @@ /**
  * @license
  * Copyright 2017 Google LLC
  * SPDX-License-Identifier: BSD-3-Clause
- */class e extends r{constructor(i){if(super(i),this.it=t,i.type!==s.CHILD)throw Error(this.constructor.directiveName+"() can only be used in child bindings")}render(r){if(r===t||null==r)return this.ft=void 0,this.it=r;if(r===i)return r;if("string"!=typeof r)throw Error(this.constructor.directiveName+"() called with a non-string value");if(r===this.it)return this.ft;this.it=r;const s=[r];return s.raw=s,this.ft={_$litType$:this.constructor.resultType,strings:s,values:[]}}}e.directiveName="unsafeHTML",e.resultType=1;const o=n(e);export{e as UnsafeHTMLDirective,o as unsafeHTML};
+ */class e extends r{constructor(i){if(super(i),this.it=t,i.type!==s.CHILD)throw Error(this.constructor.directiveName+"() can only be used in child bindings")}render(r){if(r===t||null==r)return this._t=void 0,this.it=r;if(r===i)return r;if("string"!=typeof r)throw Error(this.constructor.directiveName+"() called with a non-string value");if(r===this.it)return this._t;this.it=r;const s=[r];return s.raw=s,this._t={_$litType$:this.constructor.resultType,strings:s,values:[]}}}e.directiveName="unsafeHTML",e.resultType=1;const o=n(e);export{e as UnsafeHTMLDirective,o as unsafeHTML};
 //# sourceMappingURL=unsafe-html.js.map




diff --git a/front_end/third_party/lit-html/package/directives/unsafe-html.js.map b/front_end/third_party/lit-html/package/directives/unsafe-html.js.map
index fd70e339287688f1232cd0cfcaf9a7e4c28ec6bc..706abff383478775050b7b5a5a19560cdfd5f933 100644
--- a/front_end/third_party/lit-html/package/directives/unsafe-html.js.map
+++ b/front_end/third_party/lit-html/package/directives/unsafe-html.js.map
@@ -1 +1 @@
-{"version":3,"file":"unsafe-html.js","sources":["../src/directives/unsafe-html.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {nothing, TemplateResult, noChange} from '../lit-html.js';\nimport {directive, Directive, PartInfo, PartType} from '../directive.js';\n\nconst HTML_RESULT = 1;\n\nexport class UnsafeHTMLDirective extends Directive {\n  static directiveName = 'unsafeHTML';\n  static resultType = HTML_RESULT;\n\n  private _value: unknown = nothing;\n  private _templateResult?: TemplateResult;\n\n  constructor(partInfo: PartInfo) {\n    super(partInfo);\n    if (partInfo.type !== PartType.CHILD) {\n      throw new Error(\n        `${\n          (this.constructor as typeof UnsafeHTMLDirective).directiveName\n        }() can only be used in child bindings`\n      );\n    }\n  }\n\n  render(value: string | typeof nothing | typeof noChange | undefined | null) {\n    if (value === nothing || value == null) {\n      this._templateResult = undefined;\n      return (this._value = value);\n    }\n    if (value === noChange) {\n      return value;\n    }\n    if (typeof value != 'string') {\n      throw new Error(\n        `${\n          (this.constructor as typeof UnsafeHTMLDirective).directiveName\n        }() called with a non-string value`\n      );\n    }\n    if (value === this._value) {\n      return this._templateResult;\n    }\n    this._value = value;\n    const strings = [value] as unknown as TemplateStringsArray;\n    // eslint-disable-next-line @typescript-eslint/no-explicit-any\n    (strings as any).raw = strings;\n    // WARNING: impersonating a TemplateResult like this is extremely\n    // dangerous. Third-party directives should not do this.\n    return (this._templateResult = {\n      // Cast to a known set of integers that satisfy ResultType so that we\n      // don't have to export ResultType and possibly encourage this pattern.\n      // This property needs to remain unminified.\n      ['_$litType$']: (this.constructor as typeof UnsafeHTMLDirective)\n        .resultType as 1 | 2,\n      strings,\n      values: [],\n    });\n  }\n}\n\n/**\n * Renders the result as HTML, rather than text.\n *\n * The values `undefined`, `null`, and `nothing`, will all result in no content\n * (empty string) being rendered.\n *\n * Note, this is unsafe to use with any user-provided input that hasn't been\n * sanitized or escaped, as it may lead to cross-site-scripting\n * vulnerabilities.\n */\nexport const unsafeHTML = directive(UnsafeHTMLDirective);\n"],"names":["UnsafeHTMLDirective","Directive","constructor","partInfo","super","this","nothing","type","PartType","CHILD","Error","directiveName","render","value","_templateResult","undefined","_value","noChange","strings","raw","_$litType$","resultType","values","unsafeHTML","directive"],"mappings":";;;;;SAWaA,UAA4BC,EAOvCC,YAAYC,GAEV,GADAC,MAAMD,GAJAE,QAAkBC,EAKpBH,EAASI,OAASC,EAASC,MAC7B,MAAUC,MAELL,KAAKH,YAA2CS,cADnD,yCAONC,OAAOC,GACL,GAAIA,IAAUP,GAAoB,MAATO,EAEvB,OADAR,KAAKS,QAAkBC,EACfV,KAAKW,GAASH,EAExB,GAAIA,IAAUI,EACZ,OAAOJ,EAET,GAAoB,iBAATA,EACT,MAAUH,MAELL,KAAKH,YAA2CS,cADnD,qCAKJ,GAAIE,IAAUR,KAAKW,GACjB,OAAOX,KAAKS,GAEdT,KAAKW,GAASH,EACd,MAAMK,EAAU,CAACL,GAKjB,OAHCK,EAAgBC,IAAMD,EAGfb,KAAKS,GAAkB,CAI7BM,WAAiBf,KAAKH,YACnBmB,WACHH,QAAAA,EACAI,OAAQ,KAhDLtB,gBAAgB,aAChBA,aAJW,QAkEPuB,EAAaC,EAAUxB"}
\ No newline at end of file
+{"version":3,"file":"unsafe-html.js","sources":["../src/directives/unsafe-html.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {nothing, TemplateResult, noChange} from '../lit-html.js';\nimport {directive, Directive, PartInfo, PartType} from '../directive.js';\n\nconst HTML_RESULT = 1;\n\nexport class UnsafeHTMLDirective extends Directive {\n  static directiveName = 'unsafeHTML';\n  static resultType = HTML_RESULT;\n\n  private _value: unknown = nothing;\n  private _templateResult?: TemplateResult;\n\n  constructor(partInfo: PartInfo) {\n    super(partInfo);\n    if (partInfo.type !== PartType.CHILD) {\n      throw new Error(\n        `${\n          (this.constructor as typeof UnsafeHTMLDirective).directiveName\n        }() can only be used in child bindings`\n      );\n    }\n  }\n\n  render(value: string | typeof nothing | typeof noChange | undefined | null) {\n    if (value === nothing || value == null) {\n      this._templateResult = undefined;\n      return (this._value = value);\n    }\n    if (value === noChange) {\n      return value;\n    }\n    if (typeof value != 'string') {\n      throw new Error(\n        `${\n          (this.constructor as typeof UnsafeHTMLDirective).directiveName\n        }() called with a non-string value`\n      );\n    }\n    if (value === this._value) {\n      return this._templateResult;\n    }\n    this._value = value;\n    const strings = [value] as unknown as TemplateStringsArray;\n    // eslint-disable-next-line @typescript-eslint/no-explicit-any\n    (strings as any).raw = strings;\n    // WARNING: impersonating a TemplateResult like this is extremely\n    // dangerous. Third-party directives should not do this.\n    return (this._templateResult = {\n      // Cast to a known set of integers that satisfy ResultType so that we\n      // don't have to export ResultType and possibly encourage this pattern.\n      // This property needs to remain unminified.\n      ['_$litType$']: (this.constructor as typeof UnsafeHTMLDirective)\n        .resultType as 1 | 2,\n      strings,\n      values: [],\n    });\n  }\n}\n\n/**\n * Renders the result as HTML, rather than text.\n *\n * The values `undefined`, `null`, and `nothing`, will all result in no content\n * (empty string) being rendered.\n *\n * Note, this is unsafe to use with any user-provided input that hasn't been\n * sanitized or escaped, as it may lead to cross-site-scripting\n * vulnerabilities.\n */\nexport const unsafeHTML = directive(UnsafeHTMLDirective);\n"],"names":["UnsafeHTMLDirective","Directive","constructor","partInfo","super","this","_value","nothing","type","PartType","CHILD","Error","directiveName","render","value","_templateResult","undefined","noChange","strings","raw","_$litType$","resultType","values","unsafeHTML","directive"],"mappings":";;;;;GAWM,MAAOA,UAA4BC,EAOvCC,YAAYC,GAEV,GADAC,MAAMD,GAJAE,KAAMC,GAAYC,EAKpBJ,EAASK,OAASC,EAASC,MAC7B,MAAUC,MAELN,KAAKH,YAA2CU,cADnD,wCAKL,CAEDC,OAAOC,GACL,GAAIA,IAAUP,GAAoB,MAATO,EAEvB,OADAT,KAAKU,QAAkBC,EACfX,KAAKC,GAASQ,EAExB,GAAIA,IAAUG,EACZ,OAAOH,EAET,GAAoB,iBAATA,EACT,MAAUH,MAELN,KAAKH,YAA2CU,cADnD,qCAKJ,GAAIE,IAAUT,KAAKC,GACjB,OAAOD,KAAKU,GAEdV,KAAKC,GAASQ,EACd,MAAMI,EAAU,CAACJ,GAKjB,OAHCI,EAAgBC,IAAMD,EAGfb,KAAKU,GAAkB,CAI7BK,WAAiBf,KAAKH,YACnBmB,WACHH,UACAI,OAAQ,GAEX,EAlDMtB,EAAaY,cAAG,aAChBZ,EAAUqB,WAJC,QAkEPE,EAAaC,EAAUxB"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/directives/unsafe-svg.js.map b/front_end/third_party/lit-html/package/directives/unsafe-svg.js.map
index 780d7a2190a64bb4bd9c78454076a9a4814d6fd6..dfc59484b25e0e2b5912addf9490671eb0497fdd 100644
--- a/front_end/third_party/lit-html/package/directives/unsafe-svg.js.map
+++ b/front_end/third_party/lit-html/package/directives/unsafe-svg.js.map
@@ -1 +1 @@
-{"version":3,"file":"unsafe-svg.js","sources":["../src/directives/unsafe-svg.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {directive} from '../directive.js';\nimport {UnsafeHTMLDirective} from './unsafe-html.js';\n\nconst SVG_RESULT = 2;\n\nclass UnsafeSVGDirective extends UnsafeHTMLDirective {\n  static override directiveName = 'unsafeSVG';\n  static override resultType = SVG_RESULT;\n}\n\n/**\n * Renders the result as SVG, rather than text.\n *\n * The values `undefined`, `null`, and `nothing`, will all result in no content\n * (empty string) being rendered.\n *\n * Note, this is unsafe to use with any user-provided input that hasn't been\n * sanitized or escaped, as it may lead to cross-site-scripting\n * vulnerabilities.\n */\nexport const unsafeSVG = directive(UnsafeSVGDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {UnsafeSVGDirective};\n"],"names":["UnsafeSVGDirective","UnsafeHTMLDirective","unsafeSVG","directive"],"mappings":";;;;;GAWA,MAAMA,UAA2BC,GACfD,gBAAgB,YAChBA,aAJC,QAiBNE,EAAYC,EAAUH"}
\ No newline at end of file
+{"version":3,"file":"unsafe-svg.js","sources":["../src/directives/unsafe-svg.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {directive} from '../directive.js';\nimport {UnsafeHTMLDirective} from './unsafe-html.js';\n\nconst SVG_RESULT = 2;\n\nclass UnsafeSVGDirective extends UnsafeHTMLDirective {\n  static override directiveName = 'unsafeSVG';\n  static override resultType = SVG_RESULT;\n}\n\n/**\n * Renders the result as SVG, rather than text.\n *\n * The values `undefined`, `null`, and `nothing`, will all result in no content\n * (empty string) being rendered.\n *\n * Note, this is unsafe to use with any user-provided input that hasn't been\n * sanitized or escaped, as it may lead to cross-site-scripting\n * vulnerabilities.\n */\nexport const unsafeSVG = directive(UnsafeSVGDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {UnsafeSVGDirective};\n"],"names":["UnsafeSVGDirective","UnsafeHTMLDirective","directiveName","resultType","unsafeSVG","directive"],"mappings":";;;;;GAWA,MAAMA,UAA2BC,GACfD,EAAaE,cAAG,YAChBF,EAAUG,WAJT,QAiBNC,EAAYC,EAAUL"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/directives/until.d.ts.map b/front_end/third_party/lit-html/package/directives/until.d.ts.map
index 00242b561c4c14c4c0e3fe5e482dea182e7423c6..07633ffea472a38ebc15e01d3e291497a424cbcf 100644
--- a/front_end/third_party/lit-html/package/directives/until.d.ts.map
+++ b/front_end/third_party/lit-html/package/directives/until.d.ts.map
@@ -1 +1 @@
-{"version":3,"file":"until.d.ts","sourceRoot":"","sources":["../../src/directives/until.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAC,IAAI,EAAW,MAAM,gBAAgB,CAAC;AAG9C,OAAO,EAAC,cAAc,EAAC,MAAM,uBAAuB,CAAC;AASrD,qBAAa,cAAe,SAAQ,cAAc;IAChD,OAAO,CAAC,mBAAmB,CAAqB;IAChD,OAAO,CAAC,QAAQ,CAAiB;IACjC,OAAO,CAAC,UAAU,CAA2B;IAC7C,OAAO,CAAC,QAAQ,CAAgB;IAEhC,MAAM,CAAC,GAAG,IAAI,EAAE,KAAK,CAAC,OAAO,CAAC;IAIrB,MAAM,CAAC,KAAK,EAAE,IAAI,EAAE,IAAI,EAAE,KAAK,CAAC,OAAO,CAAC;IAuExC,YAAY;IAKZ,WAAW;CAIrB;AAED;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,eAAO,MAAM,KAAK,4FAA4B,CAAC;AAE/C;;;GAGG"}
\ No newline at end of file
+{"version":3,"file":"until.d.ts","sourceRoot":"","sources":["../../src/directives/until.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAC,IAAI,EAAW,MAAM,gBAAgB,CAAC;AAE9C,OAAO,EAAY,cAAc,EAAC,MAAM,uBAAuB,CAAC;AAShE,qBAAa,cAAe,SAAQ,cAAc;IAChD,OAAO,CAAC,mBAAmB,CAAqB;IAChD,OAAO,CAAC,QAAQ,CAAiB;IACjC,OAAO,CAAC,UAAU,CAA2B;IAC7C,OAAO,CAAC,QAAQ,CAAgB;IAEhC,MAAM,CAAC,GAAG,IAAI,EAAE,KAAK,CAAC,OAAO,CAAC;IAIrB,MAAM,CAAC,KAAK,EAAE,IAAI,EAAE,IAAI,EAAE,KAAK,CAAC,OAAO,CAAC;IAuExC,YAAY;IAKZ,WAAW;CAIrB;AAED;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,eAAO,MAAM,KAAK,4FAA4B,CAAC;AAE/C;;;GAGG"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/directives/until.js b/front_end/third_party/lit-html/package/directives/until.js
index cf8a7e2d68119e0656b3b5ed66d0b4d90278dbbb..0799066d82ad9526ee13c832b9266f08ee714f0f 100644
--- a/front_end/third_party/lit-html/package/directives/until.js
+++ b/front_end/third_party/lit-html/package/directives/until.js
@@ -1,7 +1,7 @@
-import{noChange as t}from"../lit-html.js";import{directive as s}from"../directive.js";import{isPrimitive as i}from"../directive-helpers.js";import{AsyncDirective as r}from"../async-directive.js";import{PseudoWeakRef as e,Pauser as o}from"./private-async-helpers.js";
+import{noChange as t}from"../lit-html.js";import{isPrimitive as s}from"../directive-helpers.js";import{AsyncDirective as i}from"../async-directive.js";import{PseudoWeakRef as r,Pauser as e}from"./private-async-helpers.js";import{directive as o}from"../directive.js";
 /**
  * @license
  * Copyright 2017 Google LLC
  * SPDX-License-Identifier: BSD-3-Clause
- */const n=t=>!i(t)&&"function"==typeof t.then;class h extends r{constructor(){super(...arguments),this._$Cwt=1073741823,this._$Cyt=[],this._$CG=new e(this),this._$CK=new o}render(...s){var i;return null!==(i=s.find((t=>!n(t))))&&void 0!==i?i:t}update(s,i){const r=this._$Cyt;let e=r.length;this._$Cyt=i;const o=this._$CG,h=this._$CK;this.isConnected||this.disconnected();for(let t=0;t<i.length&&!(t>this._$Cwt);t++){const s=i[t];if(!n(s))return this._$Cwt=t,s;t<e&&s===r[t]||(this._$Cwt=1073741823,e=0,Promise.resolve(s).then((async t=>{for(;h.get();)await h.get();const i=o.deref();if(void 0!==i){const r=i._$Cyt.indexOf(s);r>-1&&r<i._$Cwt&&(i._$Cwt=r,i.setValue(t))}})))}return t}disconnected(){this._$CG.disconnect(),this._$CK.pause()}reconnected(){this._$CG.reconnect(this),this._$CK.resume()}}const c=s(h);export{h as UntilDirective,c as until};
+ */const n=t=>!s(t)&&"function"==typeof t.then;class h extends i{constructor(){super(...arguments),this._$Cwt=1073741823,this._$Cyt=[],this._$CK=new r(this),this._$CX=new e}render(...s){var i;return null!==(i=s.find((t=>!n(t))))&&void 0!==i?i:t}update(s,i){const r=this._$Cyt;let e=r.length;this._$Cyt=i;const o=this._$CK,h=this._$CX;this.isConnected||this.disconnected();for(let t=0;t<i.length&&!(t>this._$Cwt);t++){const s=i[t];if(!n(s))return this._$Cwt=t,s;t<e&&s===r[t]||(this._$Cwt=1073741823,e=0,Promise.resolve(s).then((async t=>{for(;h.get();)await h.get();const i=o.deref();if(void 0!==i){const r=i._$Cyt.indexOf(s);r>-1&&r<i._$Cwt&&(i._$Cwt=r,i.setValue(t))}})))}return t}disconnected(){this._$CK.disconnect(),this._$CX.pause()}reconnected(){this._$CK.reconnect(this),this._$CX.resume()}}const c=o(h);export{h as UntilDirective,c as until};
 //# sourceMappingURL=until.js.map




diff --git a/front_end/third_party/lit-html/package/directives/until.js.map b/front_end/third_party/lit-html/package/directives/until.js.map
index 4250216cad1377d3ea3e9d30b5ec15154ca1f2bb..1f4f6dbef05422fee8c451bbae423b3b1ab27bf9 100644
--- a/front_end/third_party/lit-html/package/directives/until.js.map
+++ b/front_end/third_party/lit-html/package/directives/until.js.map
@@ -1 +1 @@
-{"version":3,"file":"until.js","sources":["../src/directives/until.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {Part, noChange} from '../lit-html.js';\nimport {directive} from '../directive.js';\nimport {isPrimitive} from '../directive-helpers.js';\nimport {AsyncDirective} from '../async-directive.js';\nimport {Pauser, PseudoWeakRef} from './private-async-helpers.js';\n\nconst isPromise = (x: unknown) => {\n  return !isPrimitive(x) && typeof (x as {then?: unknown}).then === 'function';\n};\n// Effectively infinity, but a SMI.\nconst _infinity = 0x3fffffff;\n\nexport class UntilDirective extends AsyncDirective {\n  private __lastRenderedIndex: number = _infinity;\n  private __values: unknown[] = [];\n  private __weakThis = new PseudoWeakRef(this);\n  private __pauser = new Pauser();\n\n  render(...args: Array<unknown>) {\n    return args.find((x) => !isPromise(x)) ?? noChange;\n  }\n\n  override update(_part: Part, args: Array<unknown>) {\n    const previousValues = this.__values;\n    let previousLength = previousValues.length;\n    this.__values = args;\n\n    const weakThis = this.__weakThis;\n    const pauser = this.__pauser;\n\n    // If our initial render occurs while disconnected, ensure that the pauser\n    // and weakThis are in the disconnected state\n    if (!this.isConnected) {\n      this.disconnected();\n    }\n\n    for (let i = 0; i < args.length; i++) {\n      // If we've rendered a higher-priority value already, stop.\n      if (i > this.__lastRenderedIndex) {\n        break;\n      }\n\n      const value = args[i];\n\n      // Render non-Promise values immediately\n      if (!isPromise(value)) {\n        this.__lastRenderedIndex = i;\n        // Since a lower-priority value will never overwrite a higher-priority\n        // synchronous value, we can stop processing now.\n        return value;\n      }\n\n      // If this is a Promise we've already handled, skip it.\n      if (i < previousLength && value === previousValues[i]) {\n        continue;\n      }\n\n      // We have a Promise that we haven't seen before, so priorities may have\n      // changed. Forget what we rendered before.\n      this.__lastRenderedIndex = _infinity;\n      previousLength = 0;\n\n      // Note, the callback avoids closing over `this` so that the directive\n      // can be gc'ed before the promise resolves; instead `this` is retrieved\n      // from `weakThis`, which can break the hard reference in the closure when\n      // the directive disconnects\n      Promise.resolve(value).then(async (result: unknown) => {\n        // If we're disconnected, wait until we're (maybe) reconnected\n        // The while loop here handles the case that the connection state\n        // thrashes, causing the pauser to resume and then get re-paused\n        while (pauser.get()) {\n          await pauser.get();\n        }\n        // If the callback gets here and there is no `this`, it means that the\n        // directive has been disconnected and garbage collected and we don't\n        // need to do anything else\n        const _this = weakThis.deref();\n        if (_this !== undefined) {\n          const index = _this.__values.indexOf(value);\n          // If state.values doesn't contain the value, we've re-rendered without\n          // the value, so don't render it. Then, only render if the value is\n          // higher-priority than what's already been rendered.\n          if (index > -1 && index < _this.__lastRenderedIndex) {\n            _this.__lastRenderedIndex = index;\n            _this.setValue(result);\n          }\n        }\n      });\n    }\n\n    return noChange;\n  }\n\n  override disconnected() {\n    this.__weakThis.disconnect();\n    this.__pauser.pause();\n  }\n\n  override reconnected() {\n    this.__weakThis.reconnect(this);\n    this.__pauser.resume();\n  }\n}\n\n/**\n * Renders one of a series of values, including Promises, to a Part.\n *\n * Values are rendered in priority order, with the first argument having the\n * highest priority and the last argument having the lowest priority. If a\n * value is a Promise, low-priority values will be rendered until it resolves.\n *\n * The priority of values can be used to create placeholder content for async\n * data. For example, a Promise with pending content can be the first,\n * highest-priority, argument, and a non_promise loading indicator template can\n * be used as the second, lower-priority, argument. The loading indicator will\n * render immediately, and the primary content will render when the Promise\n * resolves.\n *\n * Example:\n *\n * ```js\n * const content = fetch('./content.txt').then(r => r.text());\n * html`${until(content, html`<span>Loading...</span>`)}`\n * ```\n */\nexport const until = directive(UntilDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\n// export type {UntilDirective};\n"],"names":["isPromise","x","isPrimitive","then","UntilDirective","AsyncDirective","constructor","this","PseudoWeakRef","Pauser","render","args","find","noChange","update","_part","previousValues","__values","previousLength","length","weakThis","__weakThis","pauser","__pauser","isConnected","disconnected","i","__lastRenderedIndex","value","Promise","resolve","async","result","get","_this","deref","undefined","index","indexOf","setValue","disconnect","pause","reconnected","reconnect","resume","until","directive"],"mappings":";;;;;GAYA,MAAMA,EAAaC,IACTC,EAAYD,IAA8C,mBAAhCA,EAAuBE,WAK9CC,UAAuBC,EAApCC,kCACUC,WAHQ,WAIRA,WAAsB,GACtBA,UAAa,IAAIC,EAAcD,MAC/BA,UAAW,IAAIE,EAEvBC,UAAUC,SACR,iBAAOA,EAAKC,MAAMX,IAAOD,EAAUC,oBAAOY,EAGnCC,OAAOC,EAAaJ,GAC3B,MAAMK,EAAiBT,KAAKU,MAC5B,IAAIC,EAAiBF,EAAeG,OACpCZ,KAAKU,MAAWN,EAEhB,MAAMS,EAAWb,KAAKc,KAChBC,EAASf,KAAKgB,KAIfhB,KAAKiB,aACRjB,KAAKkB,eAGP,IAAK,IAAIC,EAAI,EAAGA,EAAIf,EAAKQ,UAEnBO,EAAInB,KAAKoB,OAFkBD,IAAK,CAMpC,MAAME,EAAQjB,EAAKe,GAGnB,IAAK1B,EAAU4B,GAIb,OAHArB,KAAKoB,MAAsBD,EAGpBE,EAILF,EAAIR,GAAkBU,IAAUZ,EAAeU,KAMnDnB,KAAKoB,MAjDO,WAkDZT,EAAiB,EAMjBW,QAAQC,QAAQF,GAAOzB,MAAK4B,MAAOC,IAIjC,KAAOV,EAAOW,aACNX,EAAOW,MAKf,MAAMC,EAAQd,EAASe,QACvB,QAAcC,IAAVF,EAAqB,CACvB,MAAMG,EAAQH,EAAMjB,MAASqB,QAAQV,GAIjCS,GAAS,GAAKA,EAAQH,EAAMP,QAC9BO,EAAMP,MAAsBU,EAC5BH,EAAMK,SAASP,SAMvB,OAAOnB,EAGAY,eACPlB,KAAKc,KAAWmB,aAChBjC,KAAKgB,KAASkB,QAGPC,cACPnC,KAAKc,KAAWsB,UAAUpC,MAC1BA,KAAKgB,KAASqB,gBAyBLC,EAAQC,EAAU1C"}
\ No newline at end of file
+{"version":3,"file":"until.js","sources":["../src/directives/until.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {Part, noChange} from '../lit-html.js';\nimport {isPrimitive} from '../directive-helpers.js';\nimport {directive, AsyncDirective} from '../async-directive.js';\nimport {Pauser, PseudoWeakRef} from './private-async-helpers.js';\n\nconst isPromise = (x: unknown) => {\n  return !isPrimitive(x) && typeof (x as {then?: unknown}).then === 'function';\n};\n// Effectively infinity, but a SMI.\nconst _infinity = 0x3fffffff;\n\nexport class UntilDirective extends AsyncDirective {\n  private __lastRenderedIndex: number = _infinity;\n  private __values: unknown[] = [];\n  private __weakThis = new PseudoWeakRef(this);\n  private __pauser = new Pauser();\n\n  render(...args: Array<unknown>) {\n    return args.find((x) => !isPromise(x)) ?? noChange;\n  }\n\n  override update(_part: Part, args: Array<unknown>) {\n    const previousValues = this.__values;\n    let previousLength = previousValues.length;\n    this.__values = args;\n\n    const weakThis = this.__weakThis;\n    const pauser = this.__pauser;\n\n    // If our initial render occurs while disconnected, ensure that the pauser\n    // and weakThis are in the disconnected state\n    if (!this.isConnected) {\n      this.disconnected();\n    }\n\n    for (let i = 0; i < args.length; i++) {\n      // If we've rendered a higher-priority value already, stop.\n      if (i > this.__lastRenderedIndex) {\n        break;\n      }\n\n      const value = args[i];\n\n      // Render non-Promise values immediately\n      if (!isPromise(value)) {\n        this.__lastRenderedIndex = i;\n        // Since a lower-priority value will never overwrite a higher-priority\n        // synchronous value, we can stop processing now.\n        return value;\n      }\n\n      // If this is a Promise we've already handled, skip it.\n      if (i < previousLength && value === previousValues[i]) {\n        continue;\n      }\n\n      // We have a Promise that we haven't seen before, so priorities may have\n      // changed. Forget what we rendered before.\n      this.__lastRenderedIndex = _infinity;\n      previousLength = 0;\n\n      // Note, the callback avoids closing over `this` so that the directive\n      // can be gc'ed before the promise resolves; instead `this` is retrieved\n      // from `weakThis`, which can break the hard reference in the closure when\n      // the directive disconnects\n      Promise.resolve(value).then(async (result: unknown) => {\n        // If we're disconnected, wait until we're (maybe) reconnected\n        // The while loop here handles the case that the connection state\n        // thrashes, causing the pauser to resume and then get re-paused\n        while (pauser.get()) {\n          await pauser.get();\n        }\n        // If the callback gets here and there is no `this`, it means that the\n        // directive has been disconnected and garbage collected and we don't\n        // need to do anything else\n        const _this = weakThis.deref();\n        if (_this !== undefined) {\n          const index = _this.__values.indexOf(value);\n          // If state.values doesn't contain the value, we've re-rendered without\n          // the value, so don't render it. Then, only render if the value is\n          // higher-priority than what's already been rendered.\n          if (index > -1 && index < _this.__lastRenderedIndex) {\n            _this.__lastRenderedIndex = index;\n            _this.setValue(result);\n          }\n        }\n      });\n    }\n\n    return noChange;\n  }\n\n  override disconnected() {\n    this.__weakThis.disconnect();\n    this.__pauser.pause();\n  }\n\n  override reconnected() {\n    this.__weakThis.reconnect(this);\n    this.__pauser.resume();\n  }\n}\n\n/**\n * Renders one of a series of values, including Promises, to a Part.\n *\n * Values are rendered in priority order, with the first argument having the\n * highest priority and the last argument having the lowest priority. If a\n * value is a Promise, low-priority values will be rendered until it resolves.\n *\n * The priority of values can be used to create placeholder content for async\n * data. For example, a Promise with pending content can be the first,\n * highest-priority, argument, and a non_promise loading indicator template can\n * be used as the second, lower-priority, argument. The loading indicator will\n * render immediately, and the primary content will render when the Promise\n * resolves.\n *\n * Example:\n *\n * ```js\n * const content = fetch('./content.txt').then(r => r.text());\n * html`${until(content, html`<span>Loading...</span>`)}`\n * ```\n */\nexport const until = directive(UntilDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\n// export type {UntilDirective};\n"],"names":["isPromise","x","isPrimitive","then","UntilDirective","AsyncDirective","constructor","this","__lastRenderedIndex","__values","__weakThis","PseudoWeakRef","__pauser","Pauser","render","args","find","_a","noChange","update","_part","previousValues","previousLength","length","weakThis","pauser","isConnected","disconnected","i","value","Promise","resolve","async","result","get","_this","deref","undefined","index","indexOf","setValue","disconnect","pause","reconnected","reconnect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




diff --git a/front_end/third_party/lit-html/package/directives/when.js.map b/front_end/third_party/lit-html/package/directives/when.js.map
index 8445e16722d6790883cfe9ede6ec0f24918b3cc2..45fa857bcf9d7e155f057bb414fa2658c7e3860c 100644
--- a/front_end/third_party/lit-html/package/directives/when.js.map
+++ b/front_end/third_party/lit-html/package/directives/when.js.map
@@ -1 +1 @@
-{"version":3,"file":"when.js","sources":["../src/directives/when.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n/**\n * When `condition` is true, returns the result of calling `trueCase()`, else\n * returns the result of calling `falseCase()` if `falseCase` is defined.\n *\n * This is a convenience wrapper around a ternary expression that makes it a\n * little nicer to write an inline conditional without an else.\n *\n * @example\n *\n * ```ts\n * render() {\n *   return html`\n *     ${when(this.user, () => html`User: ${this.user.username}`, () => html`Sign In...`)}\n *   `;\n * }\n * ```\n */\nexport function when<T, F>(\n  condition: true,\n  trueCase: () => T,\n  falseCase?: () => F\n): T;\nexport function when<T, F = undefined>(\n  condition: false,\n  trueCase: () => T,\n  falseCase?: () => F\n): F;\nexport function when<T, F = undefined>(\n  condition: unknown,\n  trueCase: () => T,\n  falseCase?: () => F\n): T | F;\nexport function when(\n  condition: unknown,\n  trueCase: () => unknown,\n  falseCase?: () => unknown\n): unknown {\n  return condition ? trueCase() : falseCase?.();\n}\n"],"names":["when","condition","trueCase","falseCase"],"mappings":";;;;;SAsCgBA,EACdC,EACAC,EACAC,GAEA,OAAOF,EAAYC,IAAaC,MAAAA,SAAAA"}
\ No newline at end of file
+{"version":3,"file":"when.js","sources":["../src/directives/when.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n/**\n * When `condition` is true, returns the result of calling `trueCase()`, else\n * returns the result of calling `falseCase()` if `falseCase` is defined.\n *\n * This is a convenience wrapper around a ternary expression that makes it a\n * little nicer to write an inline conditional without an else.\n *\n * @example\n *\n * ```ts\n * render() {\n *   return html`\n *     ${when(this.user, () => html`User: ${this.user.username}`, () => html`Sign In...`)}\n *   `;\n * }\n * ```\n */\nexport function when<T, F>(\n  condition: true,\n  trueCase: () => T,\n  falseCase?: () => F\n): T;\nexport function when<T, F = undefined>(\n  condition: false,\n  trueCase: () => T,\n  falseCase?: () => F\n): F;\nexport function when<T, F = undefined>(\n  condition: unknown,\n  trueCase: () => T,\n  falseCase?: () => F\n): T | F;\nexport function when(\n  condition: unknown,\n  trueCase: () => unknown,\n  falseCase?: () => unknown\n): unknown {\n  return condition ? trueCase() : falseCase?.();\n}\n"],"names":["when","condition","trueCase","falseCase"],"mappings":";;;;;SAsCgBA,EACdC,EACAC,EACAC,GAEA,OAAOF,EAAYC,IAAaC,aAAA,EAAAA,GAClC"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/experimental-hydrate.d.ts.map b/front_end/third_party/lit-html/package/experimental-hydrate.d.ts.map
index 6bdc8b9070ad7a05c2a972ec7fad4694a2e0ce57..a73a8100656db2bed58e6e30f1081a11989c5537 100644
--- a/front_end/third_party/lit-html/package/experimental-hydrate.d.ts.map
+++ b/front_end/third_party/lit-html/package/experimental-hydrate.d.ts.map
@@ -1 +1 @@
-{"version":3,"file":"experimental-hydrate.d.ts","sourceRoot":"","sources":["../src/experimental-hydrate.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,KAAK,EAAC,cAAc,EAAC,MAAM,eAAe,CAAC;AAElD,OAAO,EAAW,aAAa,EAAO,MAAM,eAAe,CAAC;AA8D5D;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAwCG;AACH,eAAO,MAAM,OAAO,cACP,OAAO,aACP,OAAO,GAAG,gBAAgB,YAC5B,QAAQ,aAAa,CAAC,SAiEhC,CAAC;AAqPF,eAAO,MAAM,uBAAuB,mBAAoB,cAAc,WASrE,CAAC"}
\ No newline at end of file
+{"version":3,"file":"experimental-hydrate.d.ts","sourceRoot":"","sources":["../src/experimental-hydrate.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,KAAK,EAAC,cAAc,EAAC,MAAM,eAAe,CAAC;AAElD,OAAO,EAAW,aAAa,EAAO,MAAM,eAAe,CAAC;AA8D5D;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAwCG;AACH,eAAO,MAAM,OAAO,cACP,OAAO,aACP,OAAO,GAAG,gBAAgB,YAC5B,QAAQ,aAAa,CAAC,SA4DhC,CAAC;AAsPF,eAAO,MAAM,uBAAuB,mBAAoB,cAAc,WASrE,CAAC"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/experimental-hydrate.js b/front_end/third_party/lit-html/package/experimental-hydrate.js
index c2c9ca0726e9ee9b3e8685d7df4b6213f06b7590..cc8da5fd4cbc1ab09ea8e6d92f05dd32b9a46dde 100644
--- a/front_end/third_party/lit-html/package/experimental-hydrate.js
+++ b/front_end/third_party/lit-html/package/experimental-hydrate.js
@@ -3,5 +3,5 @@ /**
  * @license
  * Copyright 2019 Google LLC
  * SPDX-License-Identifier: BSD-3-Clause
- */const{R:i,D:a,j:s,H:c,Z:d}=t,p=(e,t,r={})=>{if(void 0!==t._$litPart$)throw Error("container already contains a live render");let n,o;const l=[],i=document.createTreeWalker(t,NodeFilter.SHOW_COMMENT,null,!1);let a;for(;null!==(a=i.nextNode());){const t=a.data;if(t.startsWith("lit-part")){if(0===l.length&&void 0!==n)throw Error("there must be only one root part per container");o=f(e,a,l,r),null!=n||(n=o)}else if(t.startsWith("lit-node")){u(a,l,r);const e=a.parentElement;e.hasAttribute("defer-hydration")&&e.removeAttribute("defer-hydration")}else if(t.startsWith("/lit-part")){if(1===l.length&&o!==n)throw Error("internal error");o=h(a,o,l)}}console.assert(void 0!==n,"there should be exactly one root part in a render container"),t._$litPart$=n},f=(t,r,l,d)=>{let p,f;if(0===l.length)f=new c(r,null,void 0,d),p=t;else{const e=l[l.length-1];if("template-instance"===e.type)f=new c(r,null,e.instance,d),e.instance.v.push(f),p=e.result.values[e.instancePartIndex++],e.templatePartIndex++;else if("iterable"===e.type){f=new c(r,null,e.part,d);const t=e.iterator.next();if(t.done)throw p=void 0,e.done=!0,Error("Unhandled shorter than expected iterable");p=t.value,e.part._$AH.push(f)}else f=new c(r,null,e.part,d)}if(p=s(f,p),p===e)l.push({part:f,type:"leaf"});else if(n(p))l.push({part:f,type:"leaf"}),f._$AH=p;else if(o(p)){const e="lit-part "+m(p);if(r.data!==e)throw Error("Hydration value mismatch: Unexpected TemplateResult rendered to part");{const e=c.prototype._$AC(p),t=new i(e,f);l.push({type:"template-instance",instance:t,part:f,templatePartIndex:0,instancePartIndex:0,result:p}),f._$AH=t}}else a(p)?(l.push({part:f,type:"iterable",value:p,iterator:p[Symbol.iterator](),done:!1}),f._$AH=[]):(l.push({part:f,type:"leaf"}),f._$AH=null==p?"":p);return f},h=(e,t,r)=>{if(void 0===t)throw Error("unbalanced part marker");t._$AB=e;const n=r.pop();if("iterable"===n.type&&!n.iterator.next().done)throw Error("unexpected longer than expected iterable");if(r.length>0)return r[r.length-1].part},u=(e,t,n)=>{var o;const i=/lit-node (\d+)/.exec(e.data),a=parseInt(i[1]),c=null!==(o=e.previousSibling)&&void 0!==o?o:e.parentElement,p=t[t.length-1];if("template-instance"!==p.type)throw Error("internal error");{const e=p.instance;for(;;){const t=e._$AD.parts[p.templatePartIndex];if(void 0===t||t.type!==r.ATTRIBUTE&&t.type!==r.ELEMENT||t.index!==a)break;if(t.type===r.ATTRIBUTE){const o=new t.ctor(c,t.name,t.strings,p.instance,n),i=l(o)?p.result.values[p.instancePartIndex]:p.result.values,a=!(o.type===r.EVENT||o.type===r.PROPERTY);o._$AI(i,o,p.instancePartIndex,a),p.instancePartIndex+=t.strings.length-1,e.v.push(o)}else{const t=new d(c,p.instance,n);s(t,p.result.values[p.instancePartIndex++]),e.v.push(t)}p.templatePartIndex++}}},m=e=>{const t=new Uint32Array(2).fill(5381);for(const r of e.strings)for(let e=0;e<r.length;e++)t[e%2]=33*t[e%2]^r.charCodeAt(e);return btoa(String.fromCharCode(...new Uint8Array(t.buffer)))};export{m as digestForTemplateResult,p as hydrate};
+ */const{R:i,D:a,V:s,I:c,F:d}=t,f=(e,t,r={})=>{if(void 0!==t._$litPart$)throw Error("container already contains a live render");let n,o;const l=[],i=document.createTreeWalker(t,NodeFilter.SHOW_COMMENT,null,!1);let a;for(;null!==(a=i.nextNode());){const t=a.data;if(t.startsWith("lit-part")){if(0===l.length&&void 0!==n)throw Error("there must be only one root part per container");o=p(e,a,l,r),null!=n||(n=o)}else if(t.startsWith("lit-node"))h(a,l,r);else if(t.startsWith("/lit-part")){if(1===l.length&&o!==n)throw Error("internal error");o=u(a,o,l)}}console.assert(void 0!==n,"there should be exactly one root part in a render container"),t._$litPart$=n},p=(t,r,l,d)=>{let f,p;if(0===l.length)p=new c(r,null,void 0,d),f=t;else{const e=l[l.length-1];if("template-instance"===e.type)p=new c(r,null,e.instance,d),e.instance.u.push(p),f=e.result.values[e.instancePartIndex++],e.templatePartIndex++;else if("iterable"===e.type){p=new c(r,null,e.part,d);const t=e.iterator.next();if(t.done)throw f=void 0,e.done=!0,Error("Unhandled shorter than expected iterable");f=t.value,e.part._$AH.push(p)}else p=new c(r,null,e.part,d)}if(f=s(p,f),f===e)l.push({part:p,type:"leaf"});else if(n(f))l.push({part:p,type:"leaf"}),p._$AH=f;else if(o(f)){const e="lit-part "+m(f);if(r.data!==e)throw Error("Hydration value mismatch: Unexpected TemplateResult rendered to part");{const e=c.prototype._$AC(f),t=new i(e,p);l.push({type:"template-instance",instance:t,part:p,templatePartIndex:0,instancePartIndex:0,result:f}),p._$AH=t}}else a(f)?(l.push({part:p,type:"iterable",value:f,iterator:f[Symbol.iterator](),done:!1}),p._$AH=[]):(l.push({part:p,type:"leaf"}),p._$AH=null==f?"":f);return p},u=(e,t,r)=>{if(void 0===t)throw Error("unbalanced part marker");t._$AB=e;const n=r.pop();if("iterable"===n.type&&!n.iterator.next().done)throw Error("unexpected longer than expected iterable");if(r.length>0)return r[r.length-1].part},h=(e,t,n)=>{var o;const i=/lit-node (\d+)/.exec(e.data),a=parseInt(i[1]),c=null!==(o=e.previousElementSibling)&&void 0!==o?o:e.parentElement;if(null===c)throw Error("could not find node for attribute parts");c.removeAttribute("defer-hydration");const f=t[t.length-1];if("template-instance"!==f.type)throw Error("internal error");{const e=f.instance;for(;;){const t=e._$AD.parts[f.templatePartIndex];if(void 0===t||t.type!==r.ATTRIBUTE&&t.type!==r.ELEMENT||t.index!==a)break;if(t.type===r.ATTRIBUTE){const o=new t.ctor(c,t.name,t.strings,f.instance,n),i=l(o)?f.result.values[f.instancePartIndex]:f.result.values,a=!(o.type===r.EVENT||o.type===r.PROPERTY);o._$AI(i,o,f.instancePartIndex,a),f.instancePartIndex+=t.strings.length-1,e.u.push(o)}else{const t=new d(c,f.instance,n);s(t,f.result.values[f.instancePartIndex++]),e.u.push(t)}f.templatePartIndex++}}},m=e=>{const t=new Uint32Array(2).fill(5381);for(const r of e.strings)for(let e=0;e<r.length;e++)t[e%2]=33*t[e%2]^r.charCodeAt(e);return btoa(String.fromCharCode(...new Uint8Array(t.buffer)))};export{m as digestForTemplateResult,f as hydrate};
 //# sourceMappingURL=experimental-hydrate.js.map




diff --git a/front_end/third_party/lit-html/package/experimental-hydrate.js.map b/front_end/third_party/lit-html/package/experimental-hydrate.js.map
index 9adb711b2bb17e909c3508ee7c80b088accfb940..185651b19ac1ea2537da5dd486d74f2119b8cf47 100644
--- a/front_end/third_party/lit-html/package/experimental-hydrate.js.map
+++ b/front_end/third_party/lit-html/package/experimental-hydrate.js.map
@@ -1 +1 @@
-{"version":3,"file":"experimental-hydrate.js","sources":["src/experimental-hydrate.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2019 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport type {TemplateResult} from './lit-html.js';\n\nimport {noChange, RenderOptions, _$LH} from './lit-html.js';\nimport {AttributePartInfo, PartType} from './directive.js';\nimport {\n  isPrimitive,\n  isSingleExpression,\n  isTemplateResult,\n} from './directive-helpers.js';\n\nconst {\n  _TemplateInstance: TemplateInstance,\n  _isIterable: isIterable,\n  _resolveDirective: resolveDirective,\n  _ChildPart: ChildPart,\n  _ElementPart: ElementPart,\n} = _$LH;\n\ntype ChildPart = InstanceType<typeof ChildPart>;\ntype TemplateInstance = InstanceType<typeof TemplateInstance>;\n\n/**\n * Information needed to rehydrate a single TemplateResult.\n */\ntype ChildPartState =\n  | {\n      type: 'leaf';\n      /** The ChildPart that the result is rendered to */\n      part: ChildPart;\n    }\n  | {\n      type: 'iterable';\n      /** The ChildPart that the result is rendered to */\n      part: ChildPart;\n      value: Iterable<unknown>;\n      iterator: Iterator<unknown>;\n      done: boolean;\n    }\n  | {\n      type: 'template-instance';\n      /** The ChildPart that the result is rendered to */\n      part: ChildPart;\n\n      result: TemplateResult;\n\n      /** The TemplateInstance created from the TemplateResult */\n      instance: TemplateInstance;\n\n      /**\n       * The index of the next Template part to be hydrated. This is mutable and\n       * updated as the tree walk discovers new part markers at the right level in\n       * the template instance tree.  Note there is only one Template part per\n       * attribute with (one or more) bindings.\n       */\n      templatePartIndex: number;\n\n      /**\n       * The index of the next TemplateInstance part to be hydrated. This is used\n       * to retrieve the value from the TemplateResult and initialize the\n       * TemplateInstance parts' values for dirty-checking on first render.\n       */\n      instancePartIndex: number;\n    };\n\n/**\n * hydrate() operates on a container with server-side rendered content and\n * restores the client side data structures needed for lit-html updates such as\n * TemplateInstances and Parts. After calling `hydrate`, lit-html will behave as\n * if it initially rendered the DOM, and any subsequent updates will update\n * efficiently, the same as if lit-html had rendered the DOM on the client.\n *\n * hydrate() must be called on DOM that adheres the to lit-ssr structure for\n * parts. ChildParts must be represented with both a start and end comment\n * marker, and ChildParts that contain a TemplateInstance must have the template\n * digest written into the comment data.\n *\n * Since render() encloses its output in a ChildPart, there must always be a root\n * ChildPart.\n *\n * Example (using for # ... for annotations in HTML)\n *\n * Given this input:\n *\n *   html`<div class=${x}>${y}</div>`\n *\n * The SSR DOM is:\n *\n *   <!--lit-part AEmR7W+R0Ak=-->  # Start marker for the root ChildPart created\n *                                 # by render(). Includes the digest of the\n *                                 # template\n *   <div class=\"TEST_X\">\n *     <!--lit-node 0--> # Indicates there are attribute bindings here\n *                           # The number is the depth-first index of the parent\n *                           # node in the template.\n *     <!--lit-part-->  # Start marker for the ${x} expression\n *     TEST_Y\n *     <!--/lit-part-->  # End marker for the ${x} expression\n *   </div>\n *\n *   <!--/lit-part-->  # End marker for the root ChildPart\n *\n * @param rootValue\n * @param container\n * @param userOptions\n */\nexport const hydrate = (\n  rootValue: unknown,\n  container: Element | DocumentFragment,\n  options: Partial<RenderOptions> = {}\n) => {\n  // TODO(kschaaf): Do we need a helper for _$litPart$ (\"part for node\")?\n  // This property needs to remain unminified.\n  // eslint-disable-next-line @typescript-eslint/no-explicit-any\n  if ((container as any)['_$litPart$'] !== undefined) {\n    throw new Error('container already contains a live render');\n  }\n\n  // Since render() creates a ChildPart to render into, we'll always have\n  // exactly one root part. We need to hold a reference to it so we can set\n  // it in the parts cache.\n  let rootPart: ChildPart | undefined = undefined;\n\n  // When we are in-between ChildPart markers, this is the current ChildPart.\n  // It's needed to be able to set the ChildPart's endNode when we see a\n  // close marker\n  let currentChildPart: ChildPart | undefined = undefined;\n\n  // Used to remember parent template state as we recurse into nested\n  // templates\n  const stack: Array<ChildPartState> = [];\n\n  const walker = document.createTreeWalker(\n    container,\n    NodeFilter.SHOW_COMMENT,\n    null,\n    false\n  );\n  let marker: Comment | null;\n\n  // Walk the DOM looking for part marker comments\n  while ((marker = walker.nextNode() as Comment | null) !== null) {\n    const markerText = marker.data;\n    if (markerText.startsWith('lit-part')) {\n      if (stack.length === 0 && rootPart !== undefined) {\n        throw new Error('there must be only one root part per container');\n      }\n      // Create a new ChildPart and push it onto the stack\n      currentChildPart = openChildPart(rootValue, marker, stack, options);\n      rootPart ??= currentChildPart;\n    } else if (markerText.startsWith('lit-node')) {\n      // Create and hydrate attribute parts into the current ChildPart on the\n      // stack\n      createAttributeParts(marker, stack, options);\n      // Remove `defer-hydration` attribute, if any\n      const parent = marker.parentElement!;\n      if (parent.hasAttribute('defer-hydration')) {\n        parent.removeAttribute('defer-hydration');\n      }\n    } else if (markerText.startsWith('/lit-part')) {\n      // Close the current ChildPart, and pop the previous one off the stack\n      if (stack.length === 1 && currentChildPart !== rootPart) {\n        throw new Error('internal error');\n      }\n      currentChildPart = closeChildPart(marker, currentChildPart, stack);\n    }\n  }\n  console.assert(\n    rootPart !== undefined,\n    'there should be exactly one root part in a render container'\n  );\n  // This property needs to remain unminified.\n  // eslint-disable-next-line @typescript-eslint/no-explicit-any\n  (container as any)['_$litPart$'] = rootPart;\n};\n\nconst openChildPart = (\n  rootValue: unknown,\n  marker: Comment,\n  stack: Array<ChildPartState>,\n  options: RenderOptions\n) => {\n  let value: unknown;\n  // We know the startNode now. We'll know the endNode when we get to\n  // the matching marker and set it in closeChildPart()\n  // TODO(kschaaf): Current constructor takes both nodes\n  let part;\n  if (stack.length === 0) {\n    part = new ChildPart(marker, null, undefined, options);\n    value = rootValue;\n  } else {\n    const state = stack[stack.length - 1];\n    if (state.type === 'template-instance') {\n      part = new ChildPart(marker, null, state.instance, options);\n      state.instance._parts.push(part);\n      value = state.result.values[state.instancePartIndex++];\n      state.templatePartIndex++;\n    } else if (state.type === 'iterable') {\n      part = new ChildPart(marker, null, state.part, options);\n      const result = state.iterator.next();\n      if (result.done) {\n        value = undefined;\n        state.done = true;\n        throw new Error('Unhandled shorter than expected iterable');\n      } else {\n        value = result.value;\n      }\n      (state.part._$committedValue as Array<ChildPart>).push(part);\n    } else {\n      // state.type === 'leaf'\n      // TODO(kschaaf): This is unexpected, and likely a result of a primitive\n      // been rendered on the client when a TemplateResult was rendered on the\n      // server; this part will be hydrated but not used. We can detect it, but\n      // we need to decide what to do in this case. Note that this part won't be\n      // retained by any parent TemplateInstance, since a primitive had been\n      // rendered in its place.\n      // https://github.com/lit/lit/issues/1434\n      // throw new Error('Hydration value mismatch: Found a TemplateInstance' +\n      //  'where a leaf value was expected');\n      part = new ChildPart(marker, null, state.part, options);\n    }\n  }\n\n  // Initialize the ChildPart state depending on the type of value and push\n  // it onto the stack. This logic closely follows the ChildPart commit()\n  // cascade order:\n  // 1. directive\n  // 2. noChange\n  // 3. primitive (note strings must be handled before iterables, since they\n  //    are iterable)\n  // 4. TemplateResult\n  // 5. Node (not yet implemented, but fallback handling is fine)\n  // 6. Iterable\n  // 7. nothing (handled in fallback)\n  // 8. Fallback for everything else\n  value = resolveDirective(part, value);\n  if (value === noChange) {\n    stack.push({part, type: 'leaf'});\n  } else if (isPrimitive(value)) {\n    stack.push({part, type: 'leaf'});\n    part._$committedValue = value;\n    // TODO(kschaaf): We can detect when a primitive is being hydrated on the\n    // client where a TemplateResult was rendered on the server, but we need to\n    // decide on a strategy for what to do next.\n    // https://github.com/lit/lit/issues/1434\n    // if (marker.data !== 'lit-part') {\n    //   throw new Error('Hydration value mismatch: Primitive found where TemplateResult expected');\n    // }\n  } else if (isTemplateResult(value)) {\n    // Check for a template result digest\n    const markerWithDigest = `lit-part ${digestForTemplateResult(value)}`;\n    if (marker.data === markerWithDigest) {\n      const template = ChildPart.prototype._$getTemplate(value);\n      const instance = new TemplateInstance(template, part);\n      stack.push({\n        type: 'template-instance',\n        instance,\n        part,\n        templatePartIndex: 0,\n        instancePartIndex: 0,\n        result: value,\n      });\n      // For TemplateResult values, we set the part value to the\n      // generated TemplateInstance\n      part._$committedValue = instance;\n    } else {\n      // TODO: if this isn't the server-rendered template, do we\n      // need to stop hydrating this subtree? Clear it? Add tests.\n      throw new Error(\n        'Hydration value mismatch: Unexpected TemplateResult rendered to part'\n      );\n    }\n  } else if (isIterable(value)) {\n    // currentChildPart.value will contain an array of ChildParts\n    stack.push({\n      part: part,\n      type: 'iterable',\n      value,\n      iterator: value[Symbol.iterator](),\n      done: false,\n    });\n    part._$committedValue = [];\n  } else {\n    // Fallback for everything else (nothing, Objects, Functions,\n    // etc.): we just initialize the part's value\n    // Note that `Node` value types are not currently supported during\n    // SSR, so that part of the cascade is missing.\n    stack.push({part: part, type: 'leaf'});\n    part._$committedValue = value == null ? '' : value;\n  }\n  return part;\n};\n\nconst closeChildPart = (\n  marker: Comment,\n  part: ChildPart | undefined,\n  stack: Array<ChildPartState>\n): ChildPart | undefined => {\n  if (part === undefined) {\n    throw new Error('unbalanced part marker');\n  }\n\n  part._$endNode = marker;\n\n  const currentState = stack.pop()!;\n\n  if (currentState.type === 'iterable') {\n    if (!currentState.iterator.next().done) {\n      throw new Error('unexpected longer than expected iterable');\n    }\n  }\n\n  if (stack.length > 0) {\n    const state = stack[stack.length - 1];\n    return state.part;\n  } else {\n    return undefined;\n  }\n};\n\nconst createAttributeParts = (\n  comment: Comment,\n  stack: Array<ChildPartState>,\n  options: RenderOptions\n) => {\n  // Get the nodeIndex from DOM. We're only using this for an integrity\n  // check right now, we might not need it.\n  const match = /lit-node (\\d+)/.exec(comment.data)!;\n  const nodeIndex = parseInt(match[1]);\n\n  // For void elements, the node the comment was referring to will be\n  // the previousSibling; for non-void elements, the comment is guaranteed\n  // to be the first child of the element (i.e. it won't have a previousSibling\n  // meaning it should use the parentElement)\n  const node = comment.previousSibling ?? comment.parentElement;\n\n  const state = stack[stack.length - 1];\n  if (state.type === 'template-instance') {\n    const instance = state.instance;\n    // eslint-disable-next-line no-constant-condition\n    while (true) {\n      // If the next template part is in attribute-position on the current node,\n      // create the instance part for it and prime its state\n      const templatePart = instance._$template.parts[state.templatePartIndex];\n      if (\n        templatePart === undefined ||\n        (templatePart.type !== PartType.ATTRIBUTE &&\n          templatePart.type !== PartType.ELEMENT) ||\n        templatePart.index !== nodeIndex\n      ) {\n        break;\n      }\n\n      if (templatePart.type === PartType.ATTRIBUTE) {\n        // The instance part is created based on the constructor saved in the\n        // template part\n        const instancePart = new templatePart.ctor(\n          node as HTMLElement,\n          templatePart.name,\n          templatePart.strings,\n          state.instance,\n          options\n        );\n\n        const value = isSingleExpression(\n          instancePart as unknown as AttributePartInfo\n        )\n          ? state.result.values[state.instancePartIndex]\n          : state.result.values;\n\n        // Setting the attribute value primes committed value with the resolved\n        // directive value; we only then commit that value for event/property\n        // parts since those were not serialized, and pass `noCommit` for the\n        // others to avoid perf impact of touching the DOM unnecessarily\n        const noCommit = !(\n          instancePart.type === PartType.EVENT ||\n          instancePart.type === PartType.PROPERTY\n        );\n        instancePart._$setValue(\n          value,\n          instancePart,\n          state.instancePartIndex,\n          noCommit\n        );\n        state.instancePartIndex += templatePart.strings.length - 1;\n        instance._parts.push(instancePart);\n      } else {\n        // templatePart.type === PartType.ELEMENT\n        const instancePart = new ElementPart(\n          node as HTMLElement,\n          state.instance,\n          options\n        );\n        resolveDirective(\n          instancePart,\n          state.result.values[state.instancePartIndex++]\n        );\n        instance._parts.push(instancePart);\n      }\n      state.templatePartIndex++;\n    }\n  } else {\n    throw new Error('internal error');\n  }\n};\n\n// Number of 32 bit elements to use to create template digests\nconst digestSize = 2;\n// We need to specify a digest to use across rendering environments. This is a\n// simple digest build from a DJB2-ish hash modified from:\n// https://github.com/darkskyapp/string-hash/blob/master/index.js\n// It has been changed to an array of hashes to add additional bits.\n// Goals:\n//  - Extremely low collision rate. We may not be able to detect collisions.\n//  - Extremely fast.\n//  - Extremely small code size.\n//  - Safe to include in HTML comment text or attribute value.\n//  - Easily specifiable and implementable in multiple languages.\n// We don't care about cryptographic suitability.\nexport const digestForTemplateResult = (templateResult: TemplateResult) => {\n  const hashes = new Uint32Array(digestSize).fill(5381);\n\n  for (const s of templateResult.strings) {\n    for (let i = 0; i < s.length; i++) {\n      hashes[i % digestSize] = (hashes[i % digestSize] * 33) ^ s.charCodeAt(i);\n    }\n  }\n  return btoa(String.fromCharCode(...new Uint8Array(hashes.buffer)));\n};\n"],"names":["_TemplateInstance","TemplateInstance","_isIterable","isIterable","_resolveDirective","resolveDirective","_ChildPart","ChildPart","_ElementPart","ElementPart","_$LH","hydrate","rootValue","container","options","undefined","Error","rootPart","currentChildPart","stack","walker","document","createTreeWalker","NodeFilter","SHOW_COMMENT","marker","nextNode","markerText","data","startsWith","length","openChildPart","createAttributeParts","parent","parentElement","hasAttribute","removeAttribute","closeChildPart","console","assert","value","part","state","type","instance","_parts","push","result","values","instancePartIndex","templatePartIndex","iterator","next","done","_$committedValue","noChange","isPrimitive","isTemplateResult","markerWithDigest","digestForTemplateResult","template","prototype","_$getTemplate","Symbol","_$endNode","currentState","pop","comment","match","exec","nodeIndex","parseInt","node","previousSibling","templatePart","_$template","parts","PartType","ATTRIBUTE","ELEMENT","index","instancePart","ctor","name","strings","isSingleExpression","noCommit","EVENT","PROPERTY","_$setValue","templateResult","hashes","Uint32Array","fill","s","i","charCodeAt","btoa","String","fromCharCode","Uint8Array","buffer"],"mappings":";;;;;GAgBA,MACEA,EAAmBC,EACnBC,EAAaC,EACbC,EAAmBC,EACnBC,EAAYC,EACZC,EAAcC,GACZC,EAyFSC,EAAU,CACrBC,EACAC,EACAC,EAAkC,MAKlC,QAAyCC,IAApCF,EAA8B,WACjC,MAAUG,MAAM,4CAMlB,IAAIC,EAKAC,EAIJ,MAAMC,EAA+B,GAE/BC,EAASC,SAASC,iBACtBT,EACAU,WAAWC,aACX,MACA,GAEF,IAAIC,EAGJ,KAA0D,QAAlDA,EAASL,EAAOM,aAAwC,CAC9D,MAAMC,EAAaF,EAAOG,KAC1B,GAAID,EAAWE,WAAW,YAAa,CACrC,GAAqB,IAAjBV,EAAMW,aAA6Bf,IAAbE,EACxB,MAAUD,MAAM,kDAGlBE,EAAmBa,EAAcnB,EAAWa,EAAQN,EAAOL,GAC3DG,MAAAA,IAAAA,EAAaC,QACR,GAAIS,EAAWE,WAAW,YAAa,CAG5CG,EAAqBP,EAAQN,EAAOL,GAEpC,MAAMmB,EAASR,EAAOS,cAClBD,EAAOE,aAAa,oBACtBF,EAAOG,gBAAgB,wBAEpB,GAAIT,EAAWE,WAAW,aAAc,CAE7C,GAAqB,IAAjBV,EAAMW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G,EAAe,IAAIP,EAAaQ,KACpCV,EACAE,EAAaS,KACbT,EAAaU,QACb1C,EAAME,SACN9B,GAGI0B,EAAQ6C,EACZJ,GAEEvC,EAAMK,OAAOC,OAAON,EAAMO,mBAC1BP,EAAMK,OAAOC,OAMXsC,IACJL,EAAatC,OAASkC,EAASU,OAC/BN,EAAatC,OAASkC,EAASW,UAEjCP,EAAaQ,KACXjD,EACAyC,EACAvC,EAAMO,kBACNqC,GAEF5C,EAAMO,mBAAqByB,EAAaU,QAAQtD,OAAS,EACzDc,EAASC,EAAOC,KAAKmC,OAChB,CAEL,MAAMA,EAAe,IAAIxE,EACvB+D,EACA9B,EAAME,SACN9B,GAEFT,EACE4E,EACAvC,EAAMK,OAAOC,OAAON,EAAMO,sBAE5BL,EAASC,EAAOC,KAAKmC,GAEvBvC,EAAMQ,uBAoBCS,EAA2B+B,IACtC,MAAMC,EAAS,IAAIC,YAbF,GAa0BC,KAAK,MAEhD,IAAK,MAAMC,KAAKJ,EAAeN,QAC7B,IAAK,IAAIW,EAAI,EAAGA,EAAID,EAAEhE,OAAQiE,IAC5BJ,EAAOI,EAjBM,GAiBsC,GAAzBJ,EAAOI,EAjBpB,GAiB4CD,EAAEE,WAAWD,GAG1E,OAAOE,KAAKC,OAAOC,gBAAgB,IAAIC,WAAWT,EAAOU"}
\ No newline at end of file
+{"version":3,"file":"experimental-hydrate.js","sources":["src/experimental-hydrate.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2019 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport type {TemplateResult} from './lit-html.js';\n\nimport {noChange, RenderOptions, _$LH} from './lit-html.js';\nimport {AttributePartInfo, PartType} from './directive.js';\nimport {\n  isPrimitive,\n  isSingleExpression,\n  isTemplateResult,\n} from './directive-helpers.js';\n\nconst {\n  _TemplateInstance: TemplateInstance,\n  _isIterable: isIterable,\n  _resolveDirective: resolveDirective,\n  _ChildPart: ChildPart,\n  _ElementPart: ElementPart,\n} = _$LH;\n\ntype ChildPart = InstanceType<typeof ChildPart>;\ntype TemplateInstance = InstanceType<typeof TemplateInstance>;\n\n/**\n * Information needed to rehydrate a single TemplateResult.\n */\ntype ChildPartState =\n  | {\n      type: 'leaf';\n      /** The ChildPart that the result is rendered to */\n      part: ChildPart;\n    }\n  | {\n      type: 'iterable';\n      /** The ChildPart that the result is rendered to */\n      part: ChildPart;\n      value: Iterable<unknown>;\n      iterator: Iterator<unknown>;\n      done: boolean;\n    }\n  | {\n      type: 'template-instance';\n      /** The ChildPart that the result is rendered to */\n      part: ChildPart;\n\n      result: TemplateResult;\n\n      /** The TemplateInstance created from the TemplateResult */\n      instance: TemplateInstance;\n\n      /**\n       * The index of the next Template part to be hydrated. This is mutable and\n       * updated as the tree walk discovers new part markers at the right level in\n       * the template instance tree.  Note there is only one Template part per\n       * attribute with (one or more) bindings.\n       */\n      templatePartIndex: number;\n\n      /**\n       * The index of the next TemplateInstance part to be hydrated. This is used\n       * to retrieve the value from the TemplateResult and initialize the\n       * TemplateInstance parts' values for dirty-checking on first render.\n       */\n      instancePartIndex: number;\n    };\n\n/**\n * hydrate() operates on a container with server-side rendered content and\n * restores the client side data structures needed for lit-html updates such as\n * TemplateInstances and Parts. After calling `hydrate`, lit-html will behave as\n * if it initially rendered the DOM, and any subsequent updates will update\n * efficiently, the same as if lit-html had rendered the DOM on the client.\n *\n * hydrate() must be called on DOM that adheres the to lit-ssr structure for\n * parts. ChildParts must be represented with both a start and end comment\n * marker, and ChildParts that contain a TemplateInstance must have the template\n * digest written into the comment data.\n *\n * Since render() encloses its output in a ChildPart, there must always be a root\n * ChildPart.\n *\n * Example (using for # ... for annotations in HTML)\n *\n * Given this input:\n *\n *   html`<div class=${x}>${y}</div>`\n *\n * The SSR DOM is:\n *\n *   <!--lit-part AEmR7W+R0Ak=-->  # Start marker for the root ChildPart created\n *                                 # by render(). Includes the digest of the\n *                                 # template\n *   <div class=\"TEST_X\">\n *     <!--lit-node 0--> # Indicates there are attribute bindings here\n *                           # The number is the depth-first index of the parent\n *                           # node in the template.\n *     <!--lit-part-->  # Start marker for the ${x} expression\n *     TEST_Y\n *     <!--/lit-part-->  # End marker for the ${x} expression\n *   </div>\n *\n *   <!--/lit-part-->  # End marker for the root ChildPart\n *\n * @param rootValue\n * @param container\n * @param userOptions\n */\nexport const hydrate = (\n  rootValue: unknown,\n  container: Element | DocumentFragment,\n  options: Partial<RenderOptions> = {}\n) => {\n  // TODO(kschaaf): Do we need a helper for _$litPart$ (\"part for node\")?\n  // This property needs to remain unminified.\n  // eslint-disable-next-line @typescript-eslint/no-explicit-any\n  if ((container as any)['_$litPart$'] !== undefined) {\n    throw new Error('container already contains a live render');\n  }\n\n  // Since render() creates a ChildPart to render into, we'll always have\n  // exactly one root part. We need to hold a reference to it so we can set\n  // it in the parts cache.\n  let rootPart: ChildPart | undefined = undefined;\n\n  // When we are in-between ChildPart markers, this is the current ChildPart.\n  // It's needed to be able to set the ChildPart's endNode when we see a\n  // close marker\n  let currentChildPart: ChildPart | undefined = undefined;\n\n  // Used to remember parent template state as we recurse into nested\n  // templates\n  const stack: Array<ChildPartState> = [];\n\n  const walker = document.createTreeWalker(\n    container,\n    NodeFilter.SHOW_COMMENT,\n    null,\n    false\n  );\n  let marker: Comment | null;\n\n  // Walk the DOM looking for part marker comments\n  while ((marker = walker.nextNode() as Comment | null) !== null) {\n    const markerText = marker.data;\n    if (markerText.startsWith('lit-part')) {\n      if (stack.length === 0 && rootPart !== undefined) {\n        throw new Error('there must be only one root part per container');\n      }\n      // Create a new ChildPart and push it onto the stack\n      currentChildPart = openChildPart(rootValue, marker, stack, options);\n      rootPart ??= currentChildPart;\n    } else if (markerText.startsWith('lit-node')) {\n      // Create and hydrate attribute parts into the current ChildPart on the\n      // stack\n      createAttributeParts(marker, stack, options);\n    } else if (markerText.startsWith('/lit-part')) {\n      // Close the current ChildPart, and pop the previous one off the stack\n      if (stack.length === 1 && currentChildPart !== rootPart) {\n        throw new Error('internal error');\n      }\n      currentChildPart = closeChildPart(marker, currentChildPart, stack);\n    }\n  }\n  console.assert(\n    rootPart !== undefined,\n    'there should be exactly one root part in a render container'\n  );\n  // This property needs to remain unminified.\n  // eslint-disable-next-line @typescript-eslint/no-explicit-any\n  (container as any)['_$litPart$'] = rootPart;\n};\n\nconst openChildPart = (\n  rootValue: unknown,\n  marker: Comment,\n  stack: Array<ChildPartState>,\n  options: RenderOptions\n) => {\n  let value: unknown;\n  // We know the startNode now. We'll know the endNode when we get to\n  // the matching marker and set it in closeChildPart()\n  // TODO(kschaaf): Current constructor takes both nodes\n  let part;\n  if (stack.length === 0) {\n    part = new ChildPart(marker, null, undefined, options);\n    value = rootValue;\n  } else {\n    const state = stack[stack.length - 1];\n    if (state.type === 'template-instance') {\n      part = new ChildPart(marker, null, state.instance, options);\n      state.instance._parts.push(part);\n      value = state.result.values[state.instancePartIndex++];\n      state.templatePartIndex++;\n    } else if (state.type === 'iterable') {\n      part = new ChildPart(marker, null, state.part, options);\n      const result = state.iterator.next();\n      if (result.done) {\n        value = undefined;\n        state.done = true;\n        throw new Error('Unhandled shorter than expected iterable');\n      } else {\n        value = result.value;\n      }\n      (state.part._$committedValue as Array<ChildPart>).push(part);\n    } else {\n      // state.type === 'leaf'\n      // TODO(kschaaf): This is unexpected, and likely a result of a primitive\n      // been rendered on the client when a TemplateResult was rendered on the\n      // server; this part will be hydrated but not used. We can detect it, but\n      // we need to decide what to do in this case. Note that this part won't be\n      // retained by any parent TemplateInstance, since a primitive had been\n      // rendered in its place.\n      // https://github.com/lit/lit/issues/1434\n      // throw new Error('Hydration value mismatch: Found a TemplateInstance' +\n      //  'where a leaf value was expected');\n      part = new ChildPart(marker, null, state.part, options);\n    }\n  }\n\n  // Initialize the ChildPart state depending on the type of value and push\n  // it onto the stack. This logic closely follows the ChildPart commit()\n  // cascade order:\n  // 1. directive\n  // 2. noChange\n  // 3. primitive (note strings must be handled before iterables, since they\n  //    are iterable)\n  // 4. TemplateResult\n  // 5. Node (not yet implemented, but fallback handling is fine)\n  // 6. Iterable\n  // 7. nothing (handled in fallback)\n  // 8. Fallback for everything else\n  value = resolveDirective(part, value);\n  if (value === noChange) {\n    stack.push({part, type: 'leaf'});\n  } else if (isPrimitive(value)) {\n    stack.push({part, type: 'leaf'});\n    part._$committedValue = value;\n    // TODO(kschaaf): We can detect when a primitive is being hydrated on the\n    // client where a TemplateResult was rendered on the server, but we need to\n    // decide on a strategy for what to do next.\n    // https://github.com/lit/lit/issues/1434\n    // if (marker.data !== 'lit-part') {\n    //   throw new Error('Hydration value mismatch: Primitive found where TemplateResult expected');\n    // }\n  } else if (isTemplateResult(value)) {\n    // Check for a template result digest\n    const markerWithDigest = `lit-part ${digestForTemplateResult(value)}`;\n    if (marker.data === markerWithDigest) {\n      const template = ChildPart.prototype._$getTemplate(value);\n      const instance = new TemplateInstance(template, part);\n      stack.push({\n        type: 'template-instance',\n        instance,\n        part,\n        templatePartIndex: 0,\n        instancePartIndex: 0,\n        result: value,\n      });\n      // For TemplateResult values, we set the part value to the\n      // generated TemplateInstance\n      part._$committedValue = instance;\n    } else {\n      // TODO: if this isn't the server-rendered template, do we\n      // need to stop hydrating this subtree? Clear it? Add tests.\n      throw new Error(\n        'Hydration value mismatch: Unexpected TemplateResult rendered to part'\n      );\n    }\n  } else if (isIterable(value)) {\n    // currentChildPart.value will contain an array of ChildParts\n    stack.push({\n      part: part,\n      type: 'iterable',\n      value,\n      iterator: value[Symbol.iterator](),\n      done: false,\n    });\n    part._$committedValue = [];\n  } else {\n    // Fallback for everything else (nothing, Objects, Functions,\n    // etc.): we just initialize the part's value\n    // Note that `Node` value types are not currently supported during\n    // SSR, so that part of the cascade is missing.\n    stack.push({part: part, type: 'leaf'});\n    part._$committedValue = value == null ? '' : value;\n  }\n  return part;\n};\n\nconst closeChildPart = (\n  marker: Comment,\n  part: ChildPart | undefined,\n  stack: Array<ChildPartState>\n): ChildPart | undefined => {\n  if (part === undefined) {\n    throw new Error('unbalanced part marker');\n  }\n\n  part._$endNode = marker;\n\n  const currentState = stack.pop()!;\n\n  if (currentState.type === 'iterable') {\n    if (!currentState.iterator.next().done) {\n      throw new Error('unexpected longer than expected iterable');\n    }\n  }\n\n  if (stack.length > 0) {\n    const state = stack[stack.length - 1];\n    return state.part;\n  } else {\n    return undefined;\n  }\n};\n\nconst createAttributeParts = (\n  comment: Comment,\n  stack: Array<ChildPartState>,\n  options: RenderOptions\n) => {\n  // Get the nodeIndex from DOM. We're only using this for an integrity\n  // check right now, we might not need it.\n  const match = /lit-node (\\d+)/.exec(comment.data)!;\n  const nodeIndex = parseInt(match[1]);\n\n  // For void elements, the node the comment was referring to will be\n  // the previousSibling; for non-void elements, the comment is guaranteed\n  // to be the first child of the element (i.e. it won't have a previousSibling\n  // meaning it should use the parentElement)\n  const node = comment.previousElementSibling ?? comment.parentElement;\n  if (node === null) {\n    throw new Error('could not find node for attribute parts');\n  }\n  // Remove `defer-hydration` attribute, if any\n  node.removeAttribute('defer-hydration');\n\n  const state = stack[stack.length - 1];\n  if (state.type === 'template-instance') {\n    const instance = state.instance;\n    // eslint-disable-next-line no-constant-condition\n    while (true) {\n      // If the next template part is in attribute-position on the current node,\n      // create the instance part for it and prime its state\n      const templatePart = instance._$template.parts[state.templatePartIndex];\n      if (\n        templatePart === undefined ||\n        (templatePart.type !== PartType.ATTRIBUTE &&\n          templatePart.type !== PartType.ELEMENT) ||\n        templatePart.index !== nodeIndex\n      ) {\n        break;\n      }\n\n      if (templatePart.type === PartType.ATTRIBUTE) {\n        // The instance part is created based on the constructor saved in the\n        // template part\n        const instancePart = new templatePart.ctor(\n          node as HTMLElement,\n          templatePart.name,\n          templatePart.strings,\n          state.instance,\n          options\n        );\n\n        const value = isSingleExpression(\n          instancePart as unknown as AttributePartInfo\n        )\n          ? state.result.values[state.instancePartIndex]\n          : state.result.values;\n\n        // Setting the attribute value primes committed value with the resolved\n        // directive value; we only then commit that value for event/property\n        // parts since those were not serialized, and pass `noCommit` for the\n        // others to avoid perf impact of touching the DOM unnecessarily\n        const noCommit = !(\n          instancePart.type === PartType.EVENT ||\n          instancePart.type === PartType.PROPERTY\n        );\n        instancePart._$setValue(\n          value,\n          instancePart,\n          state.instancePartIndex,\n          noCommit\n        );\n        state.instancePartIndex += templatePart.strings.length - 1;\n        instance._parts.push(instancePart);\n      } else {\n        // templatePart.type === PartType.ELEMENT\n        const instancePart = new ElementPart(node, state.instance, options);\n        resolveDirective(\n          instancePart,\n          state.result.values[state.instancePartIndex++]\n        );\n        instance._parts.push(instancePart);\n      }\n      state.templatePartIndex++;\n    }\n  } else {\n    throw new Error('internal error');\n  }\n};\n\n// Number of 32 bit elements to use to create template digests\nconst digestSize = 2;\n// We need to specify a digest to use across rendering environments. This is a\n// simple digest build from a DJB2-ish hash modified from:\n// https://github.com/darkskyapp/string-hash/blob/master/index.js\n// It has been changed to an array of hashes to add additional bits.\n// Goals:\n//  - Extremely low collision rate. We may not be able to detect collisions.\n//  - Extremely fast.\n//  - Extremely small code size.\n//  - Safe to include in HTML comment text or attribute value.\n//  - Easily specifiable and implementable in multiple languages.\n// We don't care about cryptographic suitability.\nexport const digestForTemplateResult = (templateResult: TemplateResult) => {\n  const hashes = new Uint32Array(digestSize).fill(5381);\n\n  for (const s of templateResult.strings) {\n    for (let i = 0; i < s.length; i++) {\n      hashes[i % digestSize] = (hashes[i % digestSize] * 33) ^ s.charCodeAt(i);\n    }\n  }\n  return btoa(String.fromCharCode(...new Uint8Array(hashes.buffer)));\n};\n"],"names":["_TemplateInstance","TemplateInstance","_isIterable","isIterable","_resolveDirective","resolveDirective","_ChildPart","ChildPart","_ElementPart","ElementPart","_$LH","hydrate","rootValue","container","options","undefined","Error","rootPart","currentChildPart","stack","walker","document","createTreeWalker","NodeFilter","SHOW_COMMENT","marker","nextNode","markerText","data","startsWith","length","openChildPart","createAttributeParts","closeChildPart","console","assert","value","part","state","type","instance","_parts","push","result","values","instancePartIndex","templatePartIndex","iterator","next","done","_$committedValue","noChange","isPrimitive","isTemplateResult","markerWithDigest","digestForTemplateResult","template","prototype","_$getTemplate","Symbol","_$endNode","currentState","pop","comment","match","exec","nodeIndex","parseInt","node","_a","previousElementSibling","parentElement","removeAttribute","templatePart","_$template","parts","PartType","ATTRIBUTE","ELEMENT","index","instancePart","ctor","name","strings","isSingleExpression","noCommit","EVENT","PROPERTY","_$setValue","templateResult","hashes","Uint32Array","fill","s","i","charCodeAt","btoa","String","fromCharCode","Uint8Array","buffer"],"mappings":";;;;;GAgBA,MACEA,EAAmBC,EACnBC,EAAaC,EACbC,EAAmBC,EACnBC,EAAYC,EACZC,EAAcC,GACZC,EAyFSC,EAAU,CACrBC,EACAC,EACAC,EAAkC,CAAA,KAKlC,QAAyCC,IAApCF,EAA8B,WACjC,MAAUG,MAAM,4CAMlB,IAAIC,EAKAC,EAIJ,MAAMC,EAA+B,GAE/BC,EAASC,SAASC,iBACtBT,EACAU,WAAWC,aACX,MACA,GAEF,IAAIC,EAGJ,KAA0D,QAAlDA,EAASL,EAAOM,aAAwC,CAC9D,MAAMC,EAAaF,EAAOG,KAC1B,GAAID,EAAWE,WAAW,YAAa,CACrC,GAAqB,IAAjBV,EAAMW,aAA6Bf,IAAbE,EACxB,MAAUD,MAAM,kDAGlBE,EAAmBa,EAAcnB,EAAWa,EAAQN,EAAOL,GAC3DG,UAAAA,EAAaC,EACd,MAAM,GAAIS,EAAWE,WAAW,YAG/BG,EAAqBP,EAAQN,EAAOL,QAC/B,GAAIa,EAAWE,WAAW,aAAc,CAE7C,GAAqB,IAAjBV,EAAMW,QAAgBZ,IAAqBD,EAC7C,MAAUD,MAAM,kBAElBE,EAAmBe,EAAeR,EAAQP,EAAkBC,EAC7D,CACF,CACDe,QAAQC,YACOpB,IAAbE,EACA,+DAIDJ,EAA8B,WAAII,CAAQ,EAGvCc,EAAgB,CACpBnB,EACAa,EACAN,EACAL,KAEA,IAAIsB,EAIAC,EACJ,GAAqB,IAAjBlB,EAAMW,OACRO,EAAO,IAAI9B,EAAUkB,EAAQ,UAAMV,EAAWD,GAC9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OAC/BN,EAAazC,OAASqC,EAASW,UAEjCP,EAAaQ,KACXpD,EACA4C,EACA1C,EAAMO,kBACNwC,GAEF/C,EAAMO,mBAAqB4B,EAAaU,QAAQrD,OAAS,EACzDU,EAASC,EAAOC,KAAKsC,EACtB,KAAM,CAEL,MAAMA,EAAe,IAAIvE,EAAY2D,EAAM9B,EAAME,SAAU1B,GAC3DT,EACE2E,EACA1C,EAAMK,OAAOC,OAAON,EAAMO,sBAE5BL,EAASC,EAAOC,KAAKsC,EACtB,CACD1C,EAAMQ,mBACP,CACF,CAEA,EAgBUS,EAA2BkC,IACtC,MAAMC,EAAS,IAAIC,YAbF,GAa0BC,KAAK,MAEhD,IAAK,MAAMC,KAAKJ,EAAeN,QAC7B,IAAK,IAAIW,EAAI,EAAGA,EAAID,EAAE/D,OAAQgE,IAC5BJ,EAAOI,EAjBM,GAiBsC,GAAzBJ,EAAOI,EAjBpB,GAiB4CD,EAAEE,WAAWD,GAG1E,OAAOE,KAAKC,OAAOC,gBAAgB,IAAIC,WAAWT,EAAOU,SAAS"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/is-server.d.ts b/front_end/third_party/lit-html/package/is-server.d.ts
new file mode 100644
index 0000000000000000000000000000000000000000..072c7b0f9621d390225751ef49d124e4582c9b98
--- /dev/null
+++ b/front_end/third_party/lit-html/package/is-server.d.ts
@@ -0,0 +1,15 @@
+/**
+ * @license
+ * Copyright 2022 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */
+/**
+ * A boolean that will be `true` in server environments like Node, and `false`
+ * in browser environments. Note that your server environment or toolchain must
+ * support the `"node"` export condition for this to be `true`.
+ *
+ * This can be used when authoring components to change behavior based on
+ * whether or not the component is executing in an SSR context.
+ */
+export declare const isServer = false;
+//# sourceMappingURL=is-server.d.ts.map
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/is-server.d.ts.map b/front_end/third_party/lit-html/package/is-server.d.ts.map
new file mode 100644
index 0000000000000000000000000000000000000000..6ea3f651d3377761598e4e4bf606b246e728dd6a
--- /dev/null
+++ b/front_end/third_party/lit-html/package/is-server.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"is-server.d.ts","sourceRoot":"","sources":["../src/is-server.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAWH;;;;;;;GAOG;AACH,eAAO,MAAM,QAAQ,QAAY,CAAC"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/is-server.js b/front_end/third_party/lit-html/package/is-server.js
new file mode 100644
index 0000000000000000000000000000000000000000..fa9df6fa0fd961c39bab858ca852725b58f43a6c
--- /dev/null
+++ b/front_end/third_party/lit-html/package/is-server.js
@@ -0,0 +1,7 @@
+/**
+ * @license
+ * Copyright 2022 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */
+const o=!1;export{o as isServer};
+//# sourceMappingURL=is-server.js.map




diff --git a/front_end/third_party/lit-html/package/is-server.js.map b/front_end/third_party/lit-html/package/is-server.js.map
new file mode 100644
index 0000000000000000000000000000000000000000..442e0213cf8fd009414cfc1c643b174e331534cb
--- /dev/null
+++ b/front_end/third_party/lit-html/package/is-server.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"is-server.js","sources":["src/is-server.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2022 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n/**\n * @fileoverview\n *\n * This file exports a boolean const whose value will depend on what environment\n * the module is being imported from.\n */\n\nconst NODE_MODE = false;\n\n/**\n * A boolean that will be `true` in server environments like Node, and `false`\n * in browser environments. Note that your server environment or toolchain must\n * support the `\"node\"` export condition for this to be `true`.\n *\n * This can be used when authoring components to change behavior based on\n * whether or not the component is executing in an SSR context.\n */\nexport const isServer = NODE_MODE;\n"],"names":["isServer"],"mappings":";;;;;AAaA,MAUaA,GAVK"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/lit-html.d.ts b/front_end/third_party/lit-html/package/lit-html.d.ts
index b5cd586743d4efd1e8ba3a0a9668472317bc2305..85fb1146d0c9222ae7524dd244068e21e637a816 100644
--- a/front_end/third_party/lit-html/package/lit-html.d.ts
+++ b/front_end/third_party/lit-html/package/lit-html.d.ts
@@ -183,9 +183,19 @@ declare const CHILD_PART = 2;
 declare const ELEMENT_PART = 6;
 declare const COMMENT_PART = 7;
 /**
+ * The return type of the template tag functions, {@linkcode html} and
+ * {@linkcode svg}.
+ *
+ * A `TemplateResult` object holds all the information about a template
+ * expression required to render it: the template strings, expression values,
+ * and type of template (html or svg).
+ *
+ * `TemplateResult` objects do not create any DOM on their own. To create or
+            options: RenderOptions | undefined;
 /**
- * @license
+            options: RenderOptions | undefined;
  * @license
+ *
  */
 export declare type TemplateResult<T extends ResultType = ResultType> = {
     ['_$litType$']: T;
@@ -301,19 +311,6 @@      * render to change the connected state of the part.
      */
     isConnected?: boolean;
  * Contains types that are part of the unstable debug API.
-import type { Directive } from './directive.js';
-/**
- * Renders a value, usually a lit-html TemplateResult, to the container.
- * @param value
- * @param container
- * @param options
- */
-export declare const render: {
-    (value: unknown, container: HTMLElement | DocumentFragment, options?: RenderOptions | undefined): RootPart;
-    setSanitizer: (newSanitizer: SanitizerFactory) => void;
-    createSanitizer: SanitizerFactory;
-    _testOnlyClearSanitizerFactoryDoNotCallOrElse: () => void;
-export declare namespace LitUnstable {
 import type { Directive } from './directive.js';
 export interface DirectiveParent {
     _$parent?: DirectiveParent;
@@ -518,5 +515,36 @@     _BooleanAttributePart: typeof BooleanAttributePart;
     _EventPart: typeof EventPart;
     _PropertyPart: typeof PropertyPart;
     _ElementPart: typeof ElementPart;
+};
+/**
+ * Renders a value, usually a lit-html TemplateResult, to the container.
+ *
+ * This example renders the text "Hello, Zoe!" inside a paragraph tag, appending
+ * it to the container `document.body`.
+ *
+ * ```js
+ * import {html, render} from 'lit';
+ *
+ * const name = "Zoe";
+ * render(html`<p>Hello, ${name}!</p>`, document.body);
+ * ```
+ *
+ * @param value Any [renderable
+ *   value](https://lit.dev/docs/templates/expressions/#child-expressions),
+ *   typically a {@linkcode TemplateResult} created by evaluating a template tag
+ *   like {@linkcode html} or {@linkcode svg}.
+ * @param container A DOM container to render to. The first render will append
+ *   the rendered value to the container, and subsequent renders will
+ *   efficiently update the rendered value if the same result type was
+ *   previously rendered there.
+ * @param options See {@linkcode RenderOptions} for options documentation.
+ * @see
+ * {@link https://lit.dev/docs/libraries/standalone-templates/#rendering-lit-html-templates| Rendering Lit HTML Templates}
+ */
+export declare const render: {
+    (value: unknown, container: HTMLElement | DocumentFragment, options?: RenderOptions): RootPart;
+    setSanitizer: (newSanitizer: SanitizerFactory) => void;
+    createSanitizer: SanitizerFactory;
+    _testOnlyClearSanitizerFactoryDoNotCallOrElse: () => void;
 };
 //# sourceMappingURL=lit-html.d.ts.map
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/lit-html.d.ts.map b/front_end/third_party/lit-html/package/lit-html.d.ts.map
index b4047751484d4c2cfa501bc8693823281df316d2..fb6d83a795c1a39543895c0f20561d96bcb331ce 100644
--- a/front_end/third_party/lit-html/package/lit-html.d.ts.map
+++ b/front_end/third_party/lit-html/package/lit-html.d.ts.map
@@ -1 +1 @@
-{"version":3,"file":"lit-html.d.ts","sourceRoot":"","sources":["../src/lit-html.ts"],"names":[],"mappings":"AAAA;;;;GAIG;;AAGH,OAAO,KAAK,EAAC,SAAS,EAA4B,MAAM,gBAAgB,CAAC;AAMzE;;;;;GAKG;AAEH,yBAAiB,WAAW,CAAC;IAC3B;;;;;;;;OAQG;IAEH,UAAiB,QAAQ,CAAC;QACxB,KAAY,KAAK,GACb,YAAY,GACZ,oBAAoB,GACpB,8BAA8B,GAC9B,gBAAgB,GAChB,WAAW,GACX,SAAS,GACT,eAAe,GACf,YAAY,CAAC;QACjB,UAAiB,YAAY;YAC3B,IAAI,EAAE,eAAe,CAAC;YACtB,QAAQ,EAAE,QAAQ,CAAC;YACnB,OAAO,EAAE,oBAAoB,CAAC;YAC9B,gBAAgB,EAAE,mBAAmB,CAAC;YACt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AAE,MAAM,MAAM,GAAG,SAAS,CAAC,CAAC;;yBAlThB,OAAO;;;;;;;;CA6rDjC,CAAC;AAmBF;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AACH,eAAO,MAAM,MAAM;YACV,OAAO,aACH,WAAW,GAAG,gBAAgB,YAC/B,aAAa,GACtB,QAAQ;iCAvyDyB,gBAAgB;;;CAi1DnD,CAAC"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/lit-html.js b/front_end/third_party/lit-html/package/lit-html.js
index 0174dbd4cc60e5068024700562a7fb606a089aa1..5c306f39983e8f1b1b56324677ad0fb8d69a8b86 100644
--- a/front_end/third_party/lit-html/package/lit-html.js
+++ b/front_end/third_party/lit-html/package/lit-html.js
@@ -3,5 +3,5 @@  * @license
  * Copyright 2017 Google LLC
  * SPDX-License-Identifier: BSD-3-Clause
  */
-var t;const i=globalThis.trustedTypes,s=i?i.createPolicy("lit-html",{createHTML:t=>t}):void 0,e=`lit$${(Math.random()+"").slice(9)}$`,o="?"+e,n=`<${o}>`,l=document,h=(t="")=>l.createComment(t),r=t=>null===t||"object"!=typeof t&&"function"!=typeof t,d=Array.isArray,u=t=>{var i;return d(t)||"function"==typeof(null===(i=t)||void 0===i?void 0:i[Symbol.iterator])},c=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,v=/-->/g,a=/>/g,f=/>|[ 	\n\r](?:([^\s"'>=/]+)([ 	\n\r]*=[ 	\n\r]*(?:[^ 	\n\r"'`<>=]|("|')|))|$)/g,_=/'/g,m=/"/g,g=/^(?:script|style|textarea|title)$/i,p=t=>(i,...s)=>({_$litType$:t,strings:i,values:s}),$=p(1),y=p(2),b=Symbol.for("lit-noChange"),w=Symbol.for("lit-nothing"),T=new WeakMap,x=(t,i,s)=>{var e,o;const n=null!==(e=null==s?void 0:s.renderBefore)&&void 0!==e?e:i;let l=n._$litPart$;if(void 0===l){const t=null!==(o=null==s?void 0:s.renderBefore)&&void 0!==o?o:null;n._$litPart$=l=new N(i.insertBefore(h(),t),t,void 0,null!=s?s:{})}return l._$AI(t),l},A=l.createTreeWalker(l,129,null,!1),C=(t,i)=>{const o=t.length-1,l=[];let h,r=2===i?"<svg>":"",d=c;for(let i=0;i<o;i++){const s=t[i];let o,u,p=-1,$=0;for(;$<s.length&&(d.lastIndex=$,u=d.exec(s),null!==u);)$=d.lastIndex,d===c?"!--"===u[1]?d=v:void 0!==u[1]?d=a:void 0!==u[2]?(g.test(u[2])&&(h=RegExp("</"+u[2],"g")),d=f):void 0!==u[3]&&(d=f):d===f?">"===u[0]?(d=null!=h?h:c,p=-1):void 0===u[1]?p=-2:(p=d.lastIndex-u[2].length,o=u[1],d=void 0===u[3]?f:'"'===u[3]?m:_):d===m||d===_?d=f:d===v||d===a?d=c:(d=f,h=void 0);const y=d===f&&t[i+1].startsWith("/>")?" ":"";r+=d===c?s+n:p>=0?(l.push(o),s.slice(0,p)+"$lit$"+s.slice(p)+e+y):s+e+(-2===p?(l.push(void 0),i):y)}const u=r+(t[o]||"<?>")+(2===i?"</svg>":"");if(!Array.isArray(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return[void 0!==s?s.createHTML(u):u,l]};class E{constructor({strings:t,_$litType$:s},n){let l;this.parts=[];let r=0,d=0;const u=t.length-1,c=this.parts,[v,a]=C(t,s);if(this.el=E.createElement(v,n),A.currentNode=this.el.content,2===s){const t=this.el.content,i=t.firstChild;i.remove(),t.append(...i.childNodes)}for(;null!==(l=A.nextNode())&&c.length<u;){if(1===l.nodeType){if(l.hasAttributes()){const t=[];for(const i of l.getAttributeNames())if(i.endsWith("$lit$")||i.startsWith(e)){const s=a[d++];if(t.push(i),void 0!==s){const t=l.getAttribute(s.toLowerCase()+"$lit$").split(e),i=/([.?@])?(.*)/.exec(s);c.push({type:1,index:r,name:i[2],strings:t,ctor:"."===i[1]?M:"?"===i[1]?H:"@"===i[1]?I:S})}else c.push({type:6,index:r})}for(const i of t)l.removeAttribute(i)}if(g.test(l.tagName)){const t=l.textContent.split(e),s=t.length-1;if(s>0){l.textContent=i?i.emptyScript:"";for(let i=0;i<s;i++)l.append(t[i],h()),A.nextNode(),c.push({type:2,index:++r});l.append(t[s],h())}}}else if(8===l.nodeType)if(l.data===o)c.push({type:2,index:r});else{let t=-1;for(;-1!==(t=l.data.indexOf(e,t+1));)c.push({type:7,index:r}),t+=e.length-1}r++}}static createElement(t,i){const s=l.createElement("template");return s.innerHTML=t,s}}function P(t,i,s=t,e){var o,n,l,h;if(i===b)return i;let d=void 0!==e?null===(o=s._$Cl)||void 0===o?void 0:o[e]:s._$Cu;const u=r(i)?void 0:i._$litDirective$;return(null==d?void 0:d.constructor)!==u&&(null===(n=null==d?void 0:d._$AO)||void 0===n||n.call(d,!1),void 0===u?d=void 0:(d=new u(t),d._$AT(t,s,e)),void 0!==e?(null!==(l=(h=s)._$Cl)&&void 0!==l?l:h._$Cl=[])[e]=d:s._$Cu=d),void 0!==d&&(i=P(t,d._$AS(t,i.values),d,e)),i}class V{constructor(t,i){this.v=[],this._$AN=void 0,this._$AD=t,this._$AM=i}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}p(t){var i;const{el:{content:s},parts:e}=this._$AD,o=(null!==(i=null==t?void 0:t.creationScope)&&void 0!==i?i:l).importNode(s,!0);A.currentNode=o;let n=A.nextNode(),h=0,r=0,d=e[0];for(;void 0!==d;){if(h===d.index){let i;2===d.type?i=new N(n,n.nextSibling,this,t):1===d.type?i=new d.ctor(n,d.name,d.strings,this,t):6===d.type&&(i=new L(n,this,t)),this.v.push(i),d=e[++r]}h!==(null==d?void 0:d.index)&&(n=A.nextNode(),h++)}return o}m(t){let i=0;for(const s of this.v)void 0!==s&&(void 0!==s.strings?(s._$AI(t,s,i),i+=s.strings.length-2):s._$AI(t[i])),i++}}class N{constructor(t,i,s,e){var o;this.type=2,this._$AH=w,this._$AN=void 0,this._$AA=t,this._$AB=i,this._$AM=s,this.options=e,this._$Cg=null===(o=null==e?void 0:e.isConnected)||void 0===o||o}get _$AU(){var t,i;return null!==(i=null===(t=this._$AM)||void 0===t?void 0:t._$AU)&&void 0!==i?i:this._$Cg}get parentNode(){let t=this._$AA.parentNode;const i=this._$AM;return void 0!==i&&11===t.nodeType&&(t=i.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,i=this){t=P(this,t,i),r(t)?t===w||null==t||""===t?(this._$AH!==w&&this._$AR(),this._$AH=w):t!==this._$AH&&t!==b&&this.$(t):void 0!==t._$litType$?this.T(t):void 0!==t.nodeType?this.k(t):u(t)?this.S(t):this.$(t)}A(t,i=this._$AB){return this._$AA.parentNode.insertBefore(t,i)}k(t){this._$AH!==t&&(this._$AR(),this._$AH=this.A(t))}$(t){this._$AH!==w&&r(this._$AH)?this._$AA.nextSibling.data=t:this.k(l.createTextNode(t)),this._$AH=t}T(t){var i;const{values:s,_$litType$:e}=t,o="number"==typeof e?this._$AC(t):(void 0===e.el&&(e.el=E.createElement(e.h,this.options)),e);if((null===(i=this._$AH)||void 0===i?void 0:i._$AD)===o)this._$AH.m(s);else{const t=new V(o,this),i=t.p(this.options);t.m(s),this.k(i),this._$AH=t}}_$AC(t){let i=T.get(t.strings);return void 0===i&&T.set(t.strings,i=new E(t)),i}S(t){d(this._$AH)||(this._$AH=[],this._$AR());const i=this._$AH;let s,e=0;for(const o of t)e===i.length?i.push(s=new N(this.A(h()),this.A(h()),this,this.options)):s=i[e],s._$AI(o),e++;e<i.length&&(this._$AR(s&&s._$AB.nextSibling,e),i.length=e)}_$AR(t=this._$AA.nextSibling,i){var s;for(null===(s=this._$AP)||void 0===s||s.call(this,!1,!0,i);t&&t!==this._$AB;){const i=t.nextSibling;t.remove(),t=i}}setConnected(t){var i;void 0===this._$AM&&(this._$Cg=t,null===(i=this._$AP)||void 0===i||i.call(this,t))}}class S{constructor(t,i,s,e,o){this.type=1,this._$AH=w,this._$AN=void 0,this.element=t,this.name=i,this._$AM=e,this.options=o,s.length>2||""!==s[0]||""!==s[1]?(this._$AH=Array(s.length-1).fill(new String),this.strings=s):this._$AH=w}get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}_$AI(t,i=this,s,e){const o=this.strings;let n=!1;if(void 0===o)t=P(this,t,i,0),n=!r(t)||t!==this._$AH&&t!==b,n&&(this._$AH=t);else{const e=t;let l,h;for(t=o[0],l=0;l<o.length-1;l++)h=P(this,e[s+l],i,l),h===b&&(h=this._$AH[l]),n||(n=!r(h)||h!==this._$AH[l]),h===w?t=w:t!==w&&(t+=(null!=h?h:"")+o[l+1]),this._$AH[l]=h}n&&!e&&this.C(t)}C(t){t===w?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,null!=t?t:"")}}class M extends S{constructor(){super(...arguments),this.type=3}C(t){this.element[this.name]=t===w?void 0:t}}const k=i?i.emptyScript:"";class H extends S{constructor(){super(...arguments),this.type=4}C(t){t&&t!==w?this.element.setAttribute(this.name,k):this.element.removeAttribute(this.name)}}class I extends S{constructor(t,i,s,e,o){super(t,i,s,e,o),this.type=5}_$AI(t,i=this){var s;if((t=null!==(s=P(this,t,i,0))&&void 0!==s?s:w)===b)return;const e=this._$AH,o=t===w&&e!==w||t.capture!==e.capture||t.once!==e.once||t.passive!==e.passive,n=t!==w&&(e===w||o);o&&this.element.removeEventListener(this.name,this,e),n&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){var i,s;"function"==typeof this._$AH?this._$AH.call(null!==(s=null===(i=this.options)||void 0===i?void 0:i.host)&&void 0!==s?s:this.element,t):this._$AH.handleEvent(t)}}class L{constructor(t,i,s){this.element=t,this.type=6,this._$AN=void 0,this._$AM=i,this.options=s}get _$AU(){return this._$AM._$AU}_$AI(t){P(this,t)}}const R={P:"$lit$",L:e,V:o,I:1,N:C,R:V,D:u,j:P,H:N,O:S,F:H,B:I,W:M,Z:L},z=window.litHtmlPolyfillSupport;null==z||z(E,N),(null!==(t=globalThis.litHtmlVersions)&&void 0!==t?t:globalThis.litHtmlVersions=[]).push("2.2.1");export{R as _$LH,$ as html,b as noChange,w as nothing,x as render,y as svg};
+var t;const i=window,s=i.trustedTypes,e=s?s.createPolicy("lit-html",{createHTML:t=>t}):void 0,o=`lit$${(Math.random()+"").slice(9)}$`,n="?"+o,l=`<${n}>`,h=document,r=(t="")=>h.createComment(t),d=t=>null===t||"object"!=typeof t&&"function"!=typeof t,u=Array.isArray,c=t=>u(t)||"function"==typeof(null==t?void 0:t[Symbol.iterator]),v=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,a=/-->/g,f=/>/g,_=RegExp(">|[ \t\n\f\r](?:([^\\s\"'>=/]+)([ \t\n\f\r]*=[ \t\n\f\r]*(?:[^ \t\n\f\r\"'`<>=]|(\"|')|))|$)","g"),m=/'/g,p=/"/g,$=/^(?:script|style|textarea|title)$/i,g=t=>(i,...s)=>({_$litType$:t,strings:i,values:s}),y=g(1),w=g(2),x=Symbol.for("lit-noChange"),b=Symbol.for("lit-nothing"),T=new WeakMap,A=h.createTreeWalker(h,129,null,!1),E=(t,i)=>{const s=t.length-1,n=[];let h,r=2===i?"<svg>":"",d=v;for(let i=0;i<s;i++){const s=t[i];let e,u,c=-1,g=0;for(;g<s.length&&(d.lastIndex=g,u=d.exec(s),null!==u);)g=d.lastIndex,d===v?"!--"===u[1]?d=a:void 0!==u[1]?d=f:void 0!==u[2]?($.test(u[2])&&(h=RegExp("</"+u[2],"g")),d=_):void 0!==u[3]&&(d=_):d===_?">"===u[0]?(d=null!=h?h:v,c=-1):void 0===u[1]?c=-2:(c=d.lastIndex-u[2].length,e=u[1],d=void 0===u[3]?_:'"'===u[3]?p:m):d===p||d===m?d=_:d===a||d===f?d=v:(d=_,h=void 0);const y=d===_&&t[i+1].startsWith("/>")?" ":"";r+=d===v?s+l:c>=0?(n.push(e),s.slice(0,c)+"$lit$"+s.slice(c)+o+y):s+o+(-2===c?(n.push(void 0),i):y)}const u=r+(t[s]||"<?>")+(2===i?"</svg>":"");if(!Array.isArray(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return[void 0!==e?e.createHTML(u):u,n]};class C{constructor({strings:t,_$litType$:i},e){let l;this.parts=[];let h=0,d=0;const u=t.length-1,c=this.parts,[v,a]=E(t,i);if(this.el=C.createElement(v,e),A.currentNode=this.el.content,2===i){const t=this.el.content,i=t.firstChild;i.remove(),t.append(...i.childNodes)}for(;null!==(l=A.nextNode())&&c.length<u;){if(1===l.nodeType){if(l.hasAttributes()){const t=[];for(const i of l.getAttributeNames())if(i.endsWith("$lit$")||i.startsWith(o)){const s=a[d++];if(t.push(i),void 0!==s){const t=l.getAttribute(s.toLowerCase()+"$lit$").split(o),i=/([.?@])?(.*)/.exec(s);c.push({type:1,index:h,name:i[2],strings:t,ctor:"."===i[1]?M:"?"===i[1]?k:"@"===i[1]?H:S})}else c.push({type:6,index:h})}for(const i of t)l.removeAttribute(i)}if($.test(l.tagName)){const t=l.textContent.split(o),i=t.length-1;if(i>0){l.textContent=s?s.emptyScript:"";for(let s=0;s<i;s++)l.append(t[s],r()),A.nextNode(),c.push({type:2,index:++h});l.append(t[i],r())}}}else if(8===l.nodeType)if(l.data===n)c.push({type:2,index:h});else{let t=-1;for(;-1!==(t=l.data.indexOf(o,t+1));)c.push({type:7,index:h}),t+=o.length-1}h++}}static createElement(t,i){const s=h.createElement("template");return s.innerHTML=t,s}}function P(t,i,s=t,e){var o,n,l,h;if(i===x)return i;let r=void 0!==e?null===(o=s._$Co)||void 0===o?void 0:o[e]:s._$Cl;const u=d(i)?void 0:i._$litDirective$;return(null==r?void 0:r.constructor)!==u&&(null===(n=null==r?void 0:r._$AO)||void 0===n||n.call(r,!1),void 0===u?r=void 0:(r=new u(t),r._$AT(t,s,e)),void 0!==e?(null!==(l=(h=s)._$Co)&&void 0!==l?l:h._$Co=[])[e]=r:s._$Cl=r),void 0!==r&&(i=P(t,r._$AS(t,i.values),r,e)),i}class V{constructor(t,i){this.u=[],this._$AN=void 0,this._$AD=t,this._$AM=i}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}v(t){var i;const{el:{content:s},parts:e}=this._$AD,o=(null!==(i=null==t?void 0:t.creationScope)&&void 0!==i?i:h).importNode(s,!0);A.currentNode=o;let n=A.nextNode(),l=0,r=0,d=e[0];for(;void 0!==d;){if(l===d.index){let i;2===d.type?i=new N(n,n.nextSibling,this,t):1===d.type?i=new d.ctor(n,d.name,d.strings,this,t):6===d.type&&(i=new I(n,this,t)),this.u.push(i),d=e[++r]}l!==(null==d?void 0:d.index)&&(n=A.nextNode(),l++)}return o}p(t){let i=0;for(const s of this.u)void 0!==s&&(void 0!==s.strings?(s._$AI(t,s,i),i+=s.strings.length-2):s._$AI(t[i])),i++}}class N{constructor(t,i,s,e){var o;this.type=2,this._$AH=b,this._$AN=void 0,this._$AA=t,this._$AB=i,this._$AM=s,this.options=e,this._$Cm=null===(o=null==e?void 0:e.isConnected)||void 0===o||o}get _$AU(){var t,i;return null!==(i=null===(t=this._$AM)||void 0===t?void 0:t._$AU)&&void 0!==i?i:this._$Cm}get parentNode(){let t=this._$AA.parentNode;const i=this._$AM;return void 0!==i&&11===t.nodeType&&(t=i.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,i=this){t=P(this,t,i),d(t)?t===b||null==t||""===t?(this._$AH!==b&&this._$AR(),this._$AH=b):t!==this._$AH&&t!==x&&this.g(t):void 0!==t._$litType$?this.$(t):void 0!==t.nodeType?this.T(t):c(t)?this.k(t):this.g(t)}O(t,i=this._$AB){return this._$AA.parentNode.insertBefore(t,i)}T(t){this._$AH!==t&&(this._$AR(),this._$AH=this.O(t))}g(t){this._$AH!==b&&d(this._$AH)?this._$AA.nextSibling.data=t:this.T(h.createTextNode(t)),this._$AH=t}$(t){var i;const{values:s,_$litType$:e}=t,o="number"==typeof e?this._$AC(t):(void 0===e.el&&(e.el=C.createElement(e.h,this.options)),e);if((null===(i=this._$AH)||void 0===i?void 0:i._$AD)===o)this._$AH.p(s);else{const t=new V(o,this),i=t.v(this.options);t.p(s),this.T(i),this._$AH=t}}_$AC(t){let i=T.get(t.strings);return void 0===i&&T.set(t.strings,i=new C(t)),i}k(t){u(this._$AH)||(this._$AH=[],this._$AR());const i=this._$AH;let s,e=0;for(const o of t)e===i.length?i.push(s=new N(this.O(r()),this.O(r()),this,this.options)):s=i[e],s._$AI(o),e++;e<i.length&&(this._$AR(s&&s._$AB.nextSibling,e),i.length=e)}_$AR(t=this._$AA.nextSibling,i){var s;for(null===(s=this._$AP)||void 0===s||s.call(this,!1,!0,i);t&&t!==this._$AB;){const i=t.nextSibling;t.remove(),t=i}}setConnected(t){var i;void 0===this._$AM&&(this._$Cm=t,null===(i=this._$AP)||void 0===i||i.call(this,t))}}class S{constructor(t,i,s,e,o){this.type=1,this._$AH=b,this._$AN=void 0,this.element=t,this.name=i,this._$AM=e,this.options=o,s.length>2||""!==s[0]||""!==s[1]?(this._$AH=Array(s.length-1).fill(new String),this.strings=s):this._$AH=b}get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}_$AI(t,i=this,s,e){const o=this.strings;let n=!1;if(void 0===o)t=P(this,t,i,0),n=!d(t)||t!==this._$AH&&t!==x,n&&(this._$AH=t);else{const e=t;let l,h;for(t=o[0],l=0;l<o.length-1;l++)h=P(this,e[s+l],i,l),h===x&&(h=this._$AH[l]),n||(n=!d(h)||h!==this._$AH[l]),h===b?t=b:t!==b&&(t+=(null!=h?h:"")+o[l+1]),this._$AH[l]=h}n&&!e&&this.j(t)}j(t){t===b?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,null!=t?t:"")}}class M extends S{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===b?void 0:t}}const R=s?s.emptyScript:"";class k extends S{constructor(){super(...arguments),this.type=4}j(t){t&&t!==b?this.element.setAttribute(this.name,R):this.element.removeAttribute(this.name)}}class H extends S{constructor(t,i,s,e,o){super(t,i,s,e,o),this.type=5}_$AI(t,i=this){var s;if((t=null!==(s=P(this,t,i,0))&&void 0!==s?s:b)===x)return;const e=this._$AH,o=t===b&&e!==b||t.capture!==e.capture||t.once!==e.once||t.passive!==e.passive,n=t!==b&&(e===b||o);o&&this.element.removeEventListener(this.name,this,e),n&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){var i,s;"function"==typeof this._$AH?this._$AH.call(null!==(s=null===(i=this.options)||void 0===i?void 0:i.host)&&void 0!==s?s:this.element,t):this._$AH.handleEvent(t)}}class I{constructor(t,i,s){this.element=t,this.type=6,this._$AN=void 0,this._$AM=i,this.options=s}get _$AU(){return this._$AM._$AU}_$AI(t){P(this,t)}}const L={P:"$lit$",A:o,M:n,C:1,L:E,R:V,D:c,V:P,I:N,H:S,N:k,U:H,B:M,F:I},z=i.litHtmlPolyfillSupport;null==z||z(C,N),(null!==(t=i.litHtmlVersions)&&void 0!==t?t:i.litHtmlVersions=[]).push("2.4.0");const Z=(t,i,s)=>{var e,o;const n=null!==(e=null==s?void 0:s.renderBefore)&&void 0!==e?e:i;let l=n._$litPart$;if(void 0===l){const t=null!==(o=null==s?void 0:s.renderBefore)&&void 0!==o?o:null;n._$litPart$=l=new N(i.insertBefore(r(),t),t,void 0,null!=s?s:{})}return l._$AI(t),l};export{L as _$LH,y as html,x as noChange,b as nothing,Z as render,w as svg};
 //# sourceMappingURL=lit-html.js.map




diff --git a/front_end/third_party/lit-html/package/lit-html.js.map b/front_end/third_party/lit-html/package/lit-html.js.map
index 3273fab785687a4399aafbce51c76c7412c166f2..5f408a2efc978c37c2bc93bd4cb278015c660746 100644
--- a/front_end/third_party/lit-html/package/lit-html.js.map
+++ b/front_end/third_party/lit-html/package/lit-html.js.map
@@ -1 +1 @@
-{"version":3,"file":"lit-html.js","sources":["src/lit-html.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n// IMPORTANT: these imports must be type-only\nimport type {Directive, DirectiveResult, PartInfo} from './directive.js';\n\nconst DEV_MODE = true;\nconst ENABLE_EXTRA_SECURITY_HOOKS = true;\nconst ENABLE_SHADYDOM_NOPATCH = true;\n\n/**\n * Contains types that are part of the unstable debug API.\n *\n * Everything in this API is not stable and may change or be removed in the future,\n * even on patch releases.\n */\n// eslint-disable-next-line @typescript-eslint/no-namespace\nexport namespace LitUnstable {\n  /**\n   * When Lit is running in dev mode and `window.emitLitDebugLogEvents` is true,\n   * we will emit 'lit-debug' events to window, with live details about the update and render\n   * lifecycle. These can be useful for writing debug tooling and visualizations.\n   *\n   * Please be aware that running with window.emitLitDebugLogEvents has performance overhead,\n   * making certain operations that are normally very cheap (like a no-op render) much slower,\n   * because we must copy data and dispatch events.\n   */\n  // eslint-disable-next-line @typescript-eslint/no-namespace\n  export namespace DebugLog {\n    export type Entry =\n      | TemplatePrep\n      | TemplateInstantiated\n      | TemplateInstantiatedAndUpdated\n      | TemplateUpdating\n      | BeginRender\n      | EndRender\n      | CommitPartEntry\n      | SetPartValue;\n    export interface TemplatePrep {\n      kind: 'template prep';\n      template: Template;\n      strings: TemplateStringsArray;\n      clonableTemplate: HTMLTemplateElement;\n      parts: TemplatePart[];\n    }\n    export interface BeginRender {\n      kind: 'begin render';\n      id: number;\n      value: unknown;\n      container: HTMLElement | DocumentFragment;\n      options: RenderOptions | undefined;\n      part: ChildPart | undefined;\n    }\n    export interface EndRender {\n      kind: 'end render';\n      id: number;\n      value: unknown;\n      container: HTMLElement | DocumentFragment;\n      options: RenderOptions | undefined;\n      part: ChildPart;\n    }\n    export interface TemplateInstantiated {\n      kind: 'template instantiated';\n      template: Template | CompiledTemplate;\n      instance: TemplateInstance;\n      options: RenderOptions | undefined;\n      fragment: Node;\n      parts: Array<Part | undefined>;\n      values: unknown[];\n    }\n    export interface TemplateInstantiatedAndUpdated {\n      kind: 'template instantiated and updated';\n      template: Template | CompiledTemplate;\n      instance: TemplateInstance;\n      options: RenderOptions | undefined;\n      fragment: Node;\n      parts: Array<Part | undefined>;\n      values: unknown[];\n    }\n    export interface TemplateUpdating {\n      kind: 'template updating';\n      template: Template | CompiledTemplate;\n      instance: TemplateInstance;\n      options: RenderOptions | undefined;\n      parts: Array<Part | undefined>;\n      values: unknown[];\n    }\n    export interface SetPartValue {\n      kind: 'set part';\n      part: Part;\n      value: unknown;\n      valueIndex: number;\n      values: unknown[];\n      templateInstance: TemplateInstance;\n    }\n\n    export type CommitPartEntry =\n      | CommitNothingToChildEntry\n      | CommitText\n      | CommitNode\n      | CommitAttribute\n      | CommitProperty\n      | CommitBooleanAttribute\n      | CommitEventListener\n      | CommitToElementBinding;\n\n    export interface CommitNothingToChildEntry {\n      kind: 'commit nothing to child';\n      start: ChildNode;\n      end: ChildNode | null;\n      parent: Disconnectable | undefined;\n      options: RenderOptions | undefined;\n    }\n\n    export interface CommitText {\n      kind: 'commit text';\n      node: Text;\n      value: unknown;\n      options: RenderOptions | undefined;\n    }\n\n    export interface CommitNode {\n      kind: 'commit node';\n      start: Node;\n      parent: Disconnectable | undefined;\n      value: Node;\n      options: RenderOptions | undefined;\n    }\n\n    export interface CommitAttribute {\n      kind: 'commit attribute';\n      element: Element;\n      name: string;\n      value: unknown;\n      options: RenderOptions | undefined;\n    }\n\n    export interface CommitProperty {\n      kind: 'commit property';\n      element: Element;\n      name: string;\n      value: unknown;\n      options: RenderOptions | undefined;\n    }\n\n    export interface CommitBooleanAttribute {\n      kind: 'commit boolean attribute';\n      element: Element;\n      name: string;\n      value: boolean;\n      options: RenderOptions | undefined;\n    }\n\n    export interface CommitEventListener {\n      kind: 'commit event listener';\n      element: Element;\n      name: string;\n      value: unknown;\n      oldListener: unknown;\n      options: RenderOptions | undefined;\n      // True if we're removing the old event listener (e.g. because settings changed, or value is nothing)\n      removeListener: boolean;\n      // True if we're adding a new event listener (e.g. because first render, or settings changed)\n      addListener: boolean;\n    }\n\n    export interface CommitToElementBinding {\n      kind: 'commit to element binding';\n      element: Element;\n      value: unknown;\n      options: RenderOptions | undefined;\n    }\n  }\n}\n\ninterface DebugLoggingWindow {\n  // Even in dev mode, we generally don't want to emit these events, as that's\n  // another level of cost, so only emit them when DEV_MODE is true _and_ when\n  // window.emitLitDebugEvents is true.\n  emitLitDebugLogEvents?: boolean;\n}\n\n/**\n * Useful for visualizing and logging insights into what the Lit template system is doing.\n *\n * Compiled out of prod mode builds.\n */\nconst debugLogEvent = DEV_MODE\n  ? (event: LitUnstable.DebugLog.Entry) => {\n      const shouldEmit = (window as unknown as DebugLoggingWindow)\n        .emitLitDebugLogEvents;\n      if (!shouldEmit) {\n        return;\n      }\n      window.dispatchEvent(\n        new CustomEvent<LitUnstable.DebugLog.Entry>('lit-debug', {\n          detail: event,\n        })\n      );\n    }\n  : undefined;\n// Used for connecting beginRender and endRender events when there are nested\n// renders when errors are thrown preventing an endRender event from being\n// called.\nlet debugLogRenderId = 0;\n\n/**\n * `true` if we're building for google3 with temporary back-compat helpers.\n * This export is not present in prod builds.\n * @internal\n */\nexport const INTERNAL = true;\n\nlet issueWarning: (code: string, warning: string) => void;\n\nif (DEV_MODE) {\n  globalThis.litIssuedWarnings ??= new Set();\n\n  // Issue a warning, if we haven't already.\n  issueWarning = (code: string, warning: string) => {\n    warning += code\n      ? ` See https://lit.dev/msg/${code} for more information.`\n      : '';\n    if (!globalThis.litIssuedWarnings!.has(warning)) {\n      console.warn(warning);\n      globalThis.litIssuedWarnings!.add(warning);\n    }\n  };\n\n  issueWarning(\n    'dev-mode',\n    `Lit is in dev mode. Not recommended for production!`\n  );\n}\n\nconst wrap =\n  ENABLE_SHADYDOM_NOPATCH &&\n  window.ShadyDOM?.inUse &&\n  window.ShadyDOM?.noPatch === true\n    ? window.ShadyDOM!.wrap\n    : (node: Node) => node;\n\nconst trustedTypes = (globalThis as unknown as Partial<Window>).trustedTypes;\n\n/**\n * Our TrustedTypePolicy for HTML which is declared using the html template\n * tag function.\n *\n * That HTML is a developer-authored constant, and is parsed with innerHTML\n * before any untrusted expressions have been mixed in. Therefor it is\n * considered safe by construction.\n */\nconst policy = trustedTypes\n  ? trustedTypes.createPolicy('lit-html', {\n      createHTML: (s) => s,\n    })\n  : undefined;\n\n/**\n * Used to sanitize any value before it is written into the DOM. This can be\n * used to implement a security policy of allowed and disallowed values in\n * order to prevent XSS attacks.\n *\n * One way of using this callback would be to check attributes and properties\n * against a list of high risk fields, and require that values written to such\n * fields be instances of a class which is safe by construction. Closure's Safe\n * HTML Types is one implementation of this technique (\n * https://github.com/google/safe-html-types/blob/master/doc/safehtml-types.md).\n * The TrustedTypes polyfill in API-only mode could also be used as a basis\n * for this technique (https://github.com/WICG/trusted-types).\n *\n * @param node The HTML node (usually either a #text node or an Element) that\n *     is being written to. Note that this is just an exemplar node, the write\n *     may take place against another instance of the same class of node.\n * @param name The name of an attribute or property (for example, 'href').\n * @param type Indicates whether the write that's about to be performed will\n *     be to a property or a node.\n * @return A function that will sanitize this class of writes.\n */\nexport type SanitizerFactory = (\n  node: Node,\n  name: string,\n  type: 'property' | 'attribute'\n) => ValueSanitizer;\n\n/**\n * A function which can sanitize values that will be written to a specific kind\n * of DOM sink.\n *\n * See SanitizerFactory.\n *\n * @param value The value to sanitize. Will be the actual value passed into\n *     the lit-html template literal, so this could be of any type.\n * @return The value to write to the DOM. Usually the same as the input value,\n *     unless sanitization is needed.\n */\nexport type ValueSanitizer = (value: unknown) => unknown;\n\nconst identityFunction: ValueSanitizer = (value: unknown) => value;\nconst noopSanitizer: SanitizerFactory = (\n  _node: Node,\n  _name: string,\n  _type: 'property' | 'attribute'\n) => identityFunction;\n\n/** Sets the global sanitizer factory. */\nconst setSanitizer = (newSanitizer: SanitizerFactory) => {\n  if (!ENABLE_EXTRA_SECURITY_HOOKS) {\n    return;\n  }\n  if (sanitizerFactoryInternal !== noopSanitizer) {\n    throw new Error(\n      `Attempted to overwrite existing lit-html security policy.` +\n        ` setSanitizeDOMValueFactory should be called at most once.`\n    );\n  }\n  sanitizerFactoryInternal = newSanitizer;\n};\n\n/**\n * Only used in internal tests, not a part of the public API.\n */\nconst _testOnlyClearSanitizerFactoryDoNotCallOrElse = () => {\n  sanitizerFactoryInternal = noopSanitizer;\n};\n\nconst createSanitizer: SanitizerFactory = (node, name, type) => {\n  return sanitizerFactoryInternal(node, name, type);\n};\n\n// Added to an attribute name to mark the attribute as bound so we can find\n// it easily.\nconst boundAttributeSuffix = '$lit$';\n\n// This marker is used in many syntactic positions in HTML, so it must be\n// a valid element name and attribute name. We don't support dynamic names (yet)\n// but this at least ensures that the parse tree is closer to the template\n// intention.\nconst marker = `lit$${String(Math.random()).slice(9)}$`;\n\n// String used to tell if a comment is a marker comment\nconst markerMatch = '?' + marker;\n\n// Text used to insert a comment marker node. We use processing instruction\n// syntax because it's slightly smaller, but parses as a comment node.\nconst nodeMarker = `<${markerMatch}>`;\n\nconst d = document;\n\n// Creates a dynamic marker. We never have to search for these in the DOM.\nconst createMarker = (v = '') => d.createComment(v);\n\n// https://tc39.github.io/ecma262/#sec-typeof-operator\ntype Primitive = null | undefined | boolean | number | string | symbol | bigint;\nconst isPrimitive = (value: unknown): value is Primitive =>\n  value === null || (typeof value != 'object' && typeof value != 'function');\nconst isArray = Array.isArray;\nconst isIterable = (value: unknown): value is Iterable<unknown> =>\n  isArray(value) ||\n  // eslint-disable-next-line @typescript-eslint/no-explicit-any\n  typeof (value as any)?.[Symbol.iterator] === 'function';\n\nconst SPACE_CHAR = `[ \\t\\n\\f\\r]`;\nconst ATTR_VALUE_CHAR = `[^ \\t\\n\\f\\r\"'\\`<>=]`;\nconst NAME_CHAR = `[^\\\\s\"'>=/]`;\n\n// These regexes represent the five parsing states that we care about in the\n// Template's HTML scanner. They match the *end* of the state they're named\n// after.\n// Depending on the match, we transition to a new state. If there's no match,\n// we stay in the same state.\n// Note that the regexes are stateful. We utilize lastIndex and sync it\n// across the multiple regexes used. In addition to the five regexes below\n// we also dynamically create a regex to find the matching end tags for raw\n// text elements.\n\n/**\n * End of text is: `<` followed by:\n *   (comment start) or (tag) or (dynamic tag binding)\n */\nconst textEndRegex = /<(?:(!--|\\/[^a-zA-Z])|(\\/?[a-zA-Z][^>\\s]*)|(\\/?$))/g;\nconst COMMENT_START = 1;\nconst TAG_NAME = 2;\nconst DYNAMIC_TAG_NAME = 3;\n\nconst commentEndRegex = /-->/g;\n/**\n * Comments not started with <!--, like </{, can be ended by a single `>`\n */\nconst comment2EndRegex = />/g;\n\n/**\n * The tagEnd regex matches the end of the \"inside an opening\" tag syntax\n * position. It either matches a `>`, an attribute-like sequence, or the end\n * of the string after a space (attribute-name position ending).\n *\n * See attributes in the HTML spec:\n * https://www.w3.org/TR/html5/syntax.html#elements-attributes\n *\n * \" \\t\\n\\f\\r\" are HTML space characters:\n * https://infra.spec.whatwg.org/#ascii-whitespace\n *\n * So an attribute is:\n *  * The name: any character except a whitespace character, (\"), ('), \">\",\n *    \"=\", or \"/\". Note: this is different from the HTML spec which also excludes control characters.\n *  * Followed by zero or more space characters\n *  * Followed by \"=\"\n *  * Followed by zero or more space characters\n *  * Followed by:\n *    * Any character except space, ('), (\"), \"<\", \">\", \"=\", (`), or\n *    * (\") then any non-(\"), or\n *    * (') then any non-(')\n */\nconst tagEndRegex = new RegExp(\n  `>|${SPACE_CHAR}(?:(${NAME_CHAR}+)(${SPACE_CHAR}*=${SPACE_CHAR}*(?:${ATTR_VALUE_CHAR}|(\"|')|))|$)`,\n  'g'\n);\nconst ENTIRE_MATCH = 0;\nconst ATTRIBUTE_NAME = 1;\nconst SPACES_AND_EQUALS = 2;\nconst QUOTE_CHAR = 3;\n\nconst singleQuoteAttrEndRegex = /'/g;\nconst doubleQuoteAttrEndRegex = /\"/g;\n/**\n * Matches the raw text elements.\n *\n * Comments are not parsed within raw text elements, so we need to search their\n * text content for marker strings.\n */\nconst rawTextElement = /^(?:script|style|textarea|title)$/i;\n\n/** TemplateResult types */\nconst HTML_RESULT = 1;\nconst SVG_RESULT = 2;\n\ntype ResultType = typeof HTML_RESULT | typeof SVG_RESULT;\n\n// TemplatePart types\n// IMPORTANT: these must match the values in PartType\nconst ATTRIBUTE_PART = 1;\nconst CHILD_PART = 2;\nconst PROPERTY_PART = 3;\nconst BOOLEAN_ATTRIBUTE_PART = 4;\nconst EVENT_PART = 5;\nconst ELEMENT_PART = 6;\nconst COMMENT_PART = 7;\n\n/**\n * The return type of the template tag functions.\n */\nexport type TemplateResult<T extends ResultType = ResultType> = {\n  // This property needs to remain unminified.\n  ['_$litType$']: T;\n  strings: TemplateStringsArray;\n  values: unknown[];\n};\n\nexport type HTMLTemplateResult = TemplateResult<typeof HTML_RESULT>;\n\nexport type SVGTemplateResult = TemplateResult<typeof SVG_RESULT>;\n\nexport interface CompiledTemplateResult {\n  // This is a factory in order to make template initialization lazy\n  // and allow ShadyRenderOptions scope to be passed in.\n  // This property needs to remain unminified.\n  ['_$litType$']: CompiledTemplate;\n  values: unknown[];\n}\n\nexport interface CompiledTemplate extends Omit<Template, 'el'> {\n  // el is overridden to be optional. We initialize it on first render\n  el?: HTMLTemplateElement;\n\n  // The prepared HTML string to create a template element from.\n  h: TrustedHTML;\n}\n\n/**\n * Generates a template literal tag function that returns a TemplateResult with\n * the given result type.\n */\nconst tag =\n  <T extends ResultType>(type: T) =>\n  (strings: TemplateStringsArray, ...values: unknown[]): TemplateResult<T> => {\n    // Warn against templates octal escape sequences\n    // We do this here rather than in render so that the warning is closer to the\n    // template definition.\n    if (DEV_MODE && strings.some((s) => s === undefined)) {\n      console.warn(\n        'Some template strings are undefined.\\n' +\n          'This is probably caused by illegal octal escape sequences.'\n      );\n    }\n    return {\n      // This property needs to remain unminified.\n      ['_$litType$']: type,\n      strings,\n      values,\n    };\n  };\n\n/**\n * Interprets a template literal as an HTML template that can efficiently\n * render to and update a container.\n *\n * ```ts\n * const header = (title: string) => html`<h1>${title}</h1>`;\n * ```\n *\n * The `html` tag returns a description of the DOM to render as a value. It is\n * lazy, meaning no work is done until the template is rendered. When rendering,\n * if a template comes from the same expression as a previously rendered result,\n * it's efficiently updated instead of replaced.\n */\nexport const html = tag(HTML_RESULT);\n\n/**\n * Interprets a template literal as an SVG fragment that can efficiently\n * render to and update a container.\n *\n * ```ts\n * const rect = svg`<rect width=\"10\" height=\"10\"></rect>`;\n *\n * const myImage = html`\n *   <svg viewBox=\"0 0 10 10\" xmlns=\"http://www.w3.org/2000/svg\">\n *     ${rect}\n *   </svg>`;\n * ```\n *\n * The `svg` *tag function* should only be used for SVG fragments, or elements\n * that would be contained **inside** an `<svg>` HTML element. A common error is\n * placing an `<svg>` *element* in a template tagged with the `svg` tag\n * function. The `<svg>` element is an HTML element and should be used within a\n * template tagged with the {@linkcode html} tag function.\n *\n * In LitElement usage, it's invalid to return an SVG fragment from the\n * `render()` method, as the SVG fragment will be contained within the element's\n * shadow root and thus cannot be used within an `<svg>` HTML element.\n */\nexport const svg = tag(SVG_RESULT);\n\n/**\n * A sentinel value that signals that a value was handled by a directive and\n * should not be written to the DOM.\n */\nexport const noChange = Symbol.for('lit-noChange');\n\n/**\n * A sentinel value that signals a ChildPart to fully clear its content.\n *\n * ```ts\n * const button = html`${\n *  user.isAdmin\n *    ? html`<button>DELETE</button>`\n *    : nothing\n * }`;\n * ```\n *\n * Prefer using `nothing` over other falsy values as it provides a consistent\n * behavior between various expression binding contexts.\n *\n * In child expressions, `undefined`, `null`, `''`, and `nothing` all behave the\n * same and render no nodes. In attribute expressions, `nothing` _removes_ the\n * attribute, while `undefined` and `null` will render an empty string. In\n * property expressions `nothing` becomes `undefined`.\n */\nexport const nothing = Symbol.for('lit-nothing');\n\n/**\n * The cache of prepared templates, keyed by the tagged TemplateStringsArray\n * and _not_ accounting for the specific template tag used. This means that\n * template tags cannot be dynamic - the must statically be one of html, svg,\n * or attr. This restriction simplifies the cache lookup, which is on the hot\n * path for rendering.\n */\nconst templateCache = new WeakMap<TemplateStringsArray, Template>();\n\n/**\n * Object specifying options for controlling lit-html rendering. Note that\n * while `render` may be called multiple times on the same `container` (and\n * `renderBefore` reference node) to efficiently update the rendered content,\n * only the options passed in during the first render are respected during\n * the lifetime of renders to that unique `container` + `renderBefore`\n * combination.\n */\nexport interface RenderOptions {\n  /**\n   * An object to use as the `this` value for event listeners. It's often\n   * useful to set this to the host component rendering a template.\n   */\n  host?: object;\n  /**\n   * A DOM node before which to render content in the container.\n   */\n  renderBefore?: ChildNode | null;\n  /**\n   * Node used for cloning the template (`importNode` will be called on this\n   * node). This controls the `ownerDocument` of the rendered DOM, along with\n   * any inherited context. Defaults to the global `document`.\n   */\n  creationScope?: {importNode(node: Node, deep?: boolean): Node};\n  /**\n   * The initial connected state for the top-level part being rendered. If no\n   * `isConnected` option is set, `AsyncDirective`s will be connected by\n   * default. Set to `false` if the initial render occurs in a disconnected tree\n   * and `AsyncDirective`s should see `isConnected === false` for their initial\n   * render. The `part.setConnected()` method must be used subsequent to initial\n   * render to change the connected state of the part.\n   */\n  isConnected?: boolean;\n}\n\n/**\n * Internally we can export this interface and change the type of\n * render()'s options.\n */\ninterface InternalRenderOptions extends RenderOptions {\n  /**\n   * An internal-only migration flag\n   * @internal\n   */\n  clearContainerForLit2MigrationOnly?: boolean;\n}\n\n/**\n * Renders a value, usually a lit-html TemplateResult, to the container.\n * @param value\n * @param container\n * @param options\n */\nexport const render = (\n  value: unknown,\n  container: HTMLElement | DocumentFragment,\n  options?: RenderOptions\n): RootPart => {\n  const renderId = DEV_MODE ? debugLogRenderId++ : 0;\n  const partOwnerNode = options?.renderBefore ?? container;\n  // This property needs to remain unminified.\n  // eslint-disable-next-line @typescript-eslint/no-explicit-any\n  let part: ChildPart = (partOwnerNode as any)['_$litPart$'];\n  debugLogEvent?.({\n    kind: 'begin render',\n    id: renderId,\n    value,\n    container,\n    options,\n    part,\n  });\n  if (part === undefined) {\n    const endNode = options?.renderBefore ?? null;\n    // Internal modification: don't clear container to match lit-html 2.0\n    if (\n      INTERNAL &&\n      (options as InternalRenderOptions)?.clearContainerForLit2MigrationOnly ===\n        true\n    ) {\n      let n = container.firstChild;\n      // Clear only up to the `endNode` aka `renderBefore` node.\n      while (n && n !== endNode) {\n        const next = n.nextSibling;\n        n.remove();\n        n = next;\n      }\n    }\n    // This property needs to remain unminified.\n    // eslint-disable-next-line @typescript-eslint/no-explicit-any\n    (partOwnerNode as any)['_$litPart$'] = part = new ChildPart(\n      container.insertBefore(createMarker(), endNode),\n      endNode,\n      undefined,\n      options ?? {}\n    );\n  }\n  part._$setValue(value);\n  debugLogEvent?.({\n    kind: 'end render',\n    id: renderId,\n    value,\n    container,\n    options,\n    part,\n  });\n  return part as RootPart;\n};\n\nif (ENABLE_EXTRA_SECURITY_HOOKS) {\n  render.setSanitizer = setSanitizer;\n  render.createSanitizer = createSanitizer;\n  if (DEV_MODE) {\n    render._testOnlyClearSanitizerFactoryDoNotCallOrElse =\n      _testOnlyClearSanitizerFactoryDoNotCallOrElse;\n  }\n}\n\nconst walker = d.createTreeWalker(\n  d,\n  129 /* NodeFilter.SHOW_{ELEMENT|COMMENT} */,\n  null,\n  false\n);\n\nlet sanitizerFactoryInternal: SanitizerFactory = noopSanitizer;\n\n//\n// Classes only below here, const variable declarations only above here...\n//\n// Keeping variable declarations and classes together improves minification.\n// Interfaces and type aliases can be interleaved freely.\n//\n\n// Type for classes that have a `_directive` or `_directives[]` field, used by\n// `resolveDirective`\nexport interface DirectiveParent {\n  _$parent?: DirectiveParent;\n  _$isConnected: boolean;\n  __directive?: Directive;\n  __directives?: Array<Directive | undefined>;\n}\n\n/**\n * Returns an HTML string for the given TemplateStringsArray and result type\n * (HTML or SVG), along with the case-sensitive bound attribute names in\n * template order. The HTML contains comment comment markers denoting the\n * `ChildPart`s and suffixes on bound attributes denoting the `AttributeParts`.\n *\n * @param strings template strings array\n * @param type HTML or SVG\n * @return Array containing `[html, attrNames]` (array returned for terseness,\n *     to avoid object fields since this code is shared with non-minified SSR\n *     code)\n */\nconst getTemplateHtml = (\n  strings: TemplateStringsArray,\n  type: ResultType\n): [TrustedHTML, Array<string | undefined>] => {\n  // Insert makers into the template HTML to represent the position of\n  // bindings. The following code scans the template strings to determine the\n  // syntactic position of the bindings. They can be in text position, where\n  // we insert an HTML comment, attribute value position, where we insert a\n  // sentinel string and re-write the attribute name, or inside a tag where\n  // we insert the sentinel string.\n  const l = strings.length - 1;\n  // Stores the case-sensitive bound attribute names in the order of their\n  // parts. ElementParts are also reflected in this array as undefined\n  // rather than a string, to disambiguate from attribute bindings.\n  const attrNames: Array<string | undefined> = [];\n  let html = type === SVG_RESULT ? '<svg>' : '';\n\n  // When we're inside a raw text tag (not it's text content), the regex\n  // will still be tagRegex so we can find attributes, but will switch to\n  // this regex when the tag ends.\n  let rawTextEndRegex: RegExp | undefined;\n\n  // The current parsing state, represented as a reference to one of the\n  // regexes\n  let regex = textEndRegex;\n\n  for (let i = 0; i < l; i++) {\n    const s = strings[i];\n    // The index of the end of the last attribute name. When this is\n    // positive at end of a string, it means we're in an attribute value\n    // position and need to rewrite the attribute name.\n    // We also use a special value of -2 to indicate that we encountered\n    // the end of a string in attribute name position.\n    let attrNameEndIndex = -1;\n    let attrName: string | undefined;\n    let lastIndex = 0;\n    let match!: RegExpExecArray | null;\n\n    // The conditions in this loop handle the current parse state, and the\n    // assignments to the `regex` variable are the state transitions.\n    while (lastIndex < s.length) {\n      // Make sure we start searching from where we previously left off\n      regex.lastIndex = lastIndex;\n      match = regex.exec(s);\n      if (match === null) {\n        break;\n      }\n      lastIndex = regex.lastIndex;\n      if (regex === textEndRegex) {\n        if (match[COMMENT_START] === '!--') {\n          regex = commentEndRegex;\n        } else if (match[COMMENT_START] !== undefined) {\n          // We started a weird comment, like </{\n          regex = comment2EndRegex;\n        } else if (match[TAG_NAME] !== undefined) {\n          if (rawTextElement.test(match[TAG_NAME])) {\n            // Record if we encounter a raw-text element. We'll switch to\n            // this regex at the end of the tag.\n            rawTextEndRegex = new RegExp(`</${match[TAG_NAME]}`, 'g');\n          }\n          regex = tagEndRegex;\n        } else if (match[DYNAMIC_TAG_NAME] !== undefined) {\n          if (DEV_MODE) {\n            throw new Error(\n              'Bindings in tag names are not supported. Please use static templates instead. ' +\n                'See https://lit.dev/docs/templates/expressions/#static-expressions'\n            );\n          }\n          regex = tagEndRegex;\n        }\n      } else if (regex === tagEndRegex) {\n        if (match[ENTIRE_MATCH] === '>') {\n          // End of a tag. If we had started a raw-text element, use that\n          // regex\n          regex = rawTextEndRegex ?? textEndRegex;\n          // We may be ending an unquoted attribute value, so make sure we\n          // clear any pending attrNameEndIndex\n          attrNameEndIndex = -1;\n        } else if (match[ATTRIBUTE_NAME] === undefined) {\n          // Attribute name position\n          attrNameEndIndex = -2;\n        } else {\n          attrNameEndIndex = regex.lastIndex - match[SPACES_AND_EQUALS].length;\n          attrName = match[ATTRIBUTE_NAME];\n          regex =\n            match[QUOTE_CHAR] === undefined\n              ? tagEndRegex\n              : match[QUOTE_CHAR] === '\"'\n              ? doubleQuoteAttrEndRegex\n              : singleQuoteAttrEndRegex;\n        }\n      } else if (\n        regex === doubleQuoteAttrEndRegex ||\n        regex === singleQuoteAttrEndRegex\n      ) {\n        regex = tagEndRegex;\n      } else if (regex === commentEndRegex || regex === comment2EndRegex) {\n        regex = textEndRegex;\n      } else {\n        // Not one of the five state regexes, so it must be the dynamically\n        // created raw text regex and we're at the close of that element.\n        regex = tagEndRegex;\n        rawTextEndRegex = undefined;\n      }\n    }\n\n    if (DEV_MODE) {\n      // If we have a attrNameEndIndex, which indicates that we should\n      // rewrite the attribute name, assert that we're in a valid attribute\n      // position - either in a tag, or a quoted attribute value.\n      console.assert(\n        attrNameEndIndex === -1 ||\n          regex === tagEndRegex ||\n          regex === singleQuoteAttrEndRegex ||\n          regex === doubleQuoteAttrEndRegex,\n        'unexpected parse state B'\n      );\n    }\n\n    // We have four cases:\n    //  1. We're in text position, and not in a raw text element\n    //     (regex === textEndRegex): insert a comment marker.\n    //  2. We have a non-negative attrNameEndIndex which means we need to\n    //     rewrite the attribute name to add a bound attribute suffix.\n    //  3. We're at the non-first binding in a multi-binding attribute, use a\n    //     plain marker.\n    //  4. We're somewhere else inside the tag. If we're in attribute name\n    //     position (attrNameEndIndex === -2), add a sequential suffix to\n    //     generate a unique attribute name.\n\n    // Detect a binding next to self-closing tag end and insert a space to\n    // separate the marker from the tag end:\n    const end =\n      regex === tagEndRegex && strings[i + 1].startsWith('/>') ? ' ' : '';\n    html +=\n      regex === textEndRegex\n        ? s + nodeMarker\n        : attrNameEndIndex >= 0\n        ? (attrNames.push(attrName!),\n          s.slice(0, attrNameEndIndex) +\n            boundAttributeSuffix +\n            s.slice(attrNameEndIndex)) +\n          marker +\n          end\n        : s +\n          marker +\n          (attrNameEndIndex === -2 ? (attrNames.push(undefined), i) : end);\n  }\n\n  const htmlResult: string | TrustedHTML =\n    html + (strings[l] || '<?>') + (type === SVG_RESULT ? '</svg>' : '');\n\n  // A security check to prevent spoofing of Lit template results.\n  // In the future, we may be able to replace this with Array.isTemplateObject,\n  // though we might need to make that check inside of the html and svg\n  // functions, because precompiled templates don't come in as\n  // TemplateStringArray objects.\n  if (!Array.isArray(strings) || !strings.hasOwnProperty('raw')) {\n    let message = 'invalid template strings array';\n    if (DEV_MODE) {\n      message =\n        `Internal Error: expected template strings to be an array ` +\n        `with a 'raw' field. 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    }\n    throw new Error(message);\n  }\n  // Returned as an array for terseness\n  return [\n    policy !== undefined\n      ? policy.createHTML(htmlResult)\n      : (htmlResult as unknown as TrustedHTML),\n    attrNames,\n  ];\n};\n\n/** @internal */\nexport type {Template};\nclass Template {\n  /** @internal */\n  el!: HTMLTemplateElement;\n  /** @internal */\n  parts: Array<TemplatePart> = [];\n\n  constructor(\n    // This property needs to remain unminified.\n    {strings, ['_$litType$']: type}: TemplateResult,\n    options?: RenderOptions\n  ) {\n    let node: Node | null;\n    let nodeIndex = 0;\n    let attrNameIndex = 0;\n    const partCount = strings.length - 1;\n    const parts = this.parts;\n\n    // Create template element\n    const [html, attrNames] = getTemplateHtml(strings, type);\n    this.el = Template.createElement(html, options);\n    walker.currentNode = this.el.content;\n\n    // Reparent SVG nodes into template root\n    if (type === SVG_RESULT) {\n      const content = this.el.content;\n      const svgElement = content.firstChild!;\n      svgElement.remove();\n      content.append(...svgElement.childNodes);\n    }\n\n    // Walk the template to find binding markers and create TemplateParts\n    while ((node = walker.nextNode()) !== null && parts.length < partCount) {\n      if (node.nodeType === 1) {\n        if (DEV_MODE) {\n          const tag = (node as Element).localName;\n          // Warn if `textarea` includes an expression and throw if `template`\n          // does since these are not supported. We do this by checking\n          // innerHTML for anything that looks like a marker. This catches\n          // cases like bindings in textarea there markers turn into text nodes.\n          if (\n            /^(?:textarea|template)$/i!.test(tag) &&\n            (node as Element).innerHTML.includes(marker)\n          ) {\n            const m =\n              `Expressions are not supported inside \\`${tag}\\` ` +\n              `elements. See https://lit.dev/msg/expression-in-${tag} for more ` +\n              `information.`;\n            if (tag === 'template') {\n              throw new Error(m);\n            } else issueWarning('', m);\n          }\n        }\n        // TODO (justinfagnani): for attempted dynamic tag names, we don't\n        // increment the bindingIndex, and it'll be off by 1 in the element\n        // and off by two after it.\n        if ((node as Element).hasAttributes()) {\n          // We defer removing bound attributes because on IE we might not be\n          // iterating attributes in their template order, and would sometimes\n          // remove an attribute that we still need to create a part for.\n          const attrsToRemove = [];\n          for (const name of (node as Element).getAttributeNames()) {\n            // `name` is the name of the attribute we're iterating over, but not\n            // _neccessarily_ the name of the attribute we will create a part\n            // for. They can be different in browsers that don't iterate on\n            // attributes in source order. In that case the attrNames array\n            // contains the attribute name we'll process next. We only need the\n            // attribute name here to know if we should process a bound attribute\n            // on this element.\n            if (\n              name.endsWith(boundAttributeSuffix) ||\n              name.startsWith(marker)\n            ) {\n              const realName = attrNames[attrNameIndex++];\n              attrsToRemove.push(name);\n              if (realName !== undefined) {\n                // Lowercase for case-sensitive SVG attributes like viewBox\n                const value = (node as Element).getAttribute(\n                  realName.toLowerCase() + boundAttributeSuffix\n                )!;\n                const statics = value.split(marker);\n                const m = /([.?@])?(.*)/.exec(realName)!;\n                parts.push({\n                  type: ATTRIBUTE_PART,\n                  index: nodeIndex,\n                  name: m[2],\n                  strings: statics,\n                  ctor:\n                    m[1] === '.'\n                      ? PropertyPart\n                      : m[1] === '?'\n                      ? BooleanAttributePart\n                      : m[1] === '@'\n                      ? EventPart\n                      : AttributePart,\n                });\n              } else {\n                parts.push({\n                  type: ELEMENT_PART,\n                  index: nodeIndex,\n                });\n              }\n            }\n          }\n          for (const name of attrsToRemove) {\n            (node as Element).removeAttribute(name);\n          }\n        }\n        // TODO (justinfagnani): benchmark the regex against testing for each\n        // of the 3 raw text element names.\n        if (rawTextElement.test((node as Element).tagName)) {\n          // For raw text elements we need to split the text content on\n          // markers, create a Text node for each segment, and create\n          // a TemplatePart for each marker.\n          const strings = (node as Element).textContent!.split(marker);\n          const lastIndex = strings.length - 1;\n          if (lastIndex > 0) {\n            (node as Element).textContent = trustedTypes\n              ? (trustedTypes.emptyScript as unknown as '')\n              : '';\n            // Generate a new text node for each literal section\n            // These nodes are also used as the markers for node parts\n            // We can't use empty text nodes as markers because they're\n            // normalized when cloning in IE (could simplify when\n            // IE is no longer supported)\n            for (let i = 0; i < lastIndex; i++) {\n              (node as Element).append(strings[i], createMarker());\n              // Walk past the marker node we just added\n              walker.nextNode();\n              parts.push({type: CHILD_PART, index: ++nodeIndex});\n            }\n            // Note because this marker is added after the walker's current\n            // node, it will be walked to in the outer loop (and ignored), so\n            // we don't need to adjust nodeIndex here\n            (node as Element).append(strings[lastIndex], createMarker());\n          }\n        }\n      } else if (node.nodeType === 8) {\n        const data = (node as Comment).data;\n        if (data === markerMatch) {\n          parts.push({type: CHILD_PART, index: nodeIndex});\n        } else {\n          let i = -1;\n          while ((i = (node as Comment).data.indexOf(marker, i + 1)) !== -1) {\n            // Comment node has a binding marker inside, make an inactive part\n            // The binding won't work, but subsequent bindings will\n            parts.push({type: COMMENT_PART, index: nodeIndex});\n            // Move to the end of the match\n            i += marker.length - 1;\n          }\n        }\n      }\n      nodeIndex++;\n    }\n    debugLogEvent?.({\n      kind: 'template prep',\n      template: this,\n      clonableTemplate: this.el,\n      parts: this.parts,\n      strings,\n    });\n  }\n\n  // Overridden via `litHtmlPolyfillSupport` to provide platform support.\n  /** @nocollapse */\n  static createElement(html: TrustedHTML, _options?: RenderOptions) {\n    const el = d.createElement('template');\n    el.innerHTML = html as unknown as string;\n    return el;\n  }\n}\n\nexport interface Disconnectable {\n  _$parent?: Disconnectable;\n  _$disconnectableChildren?: Set<Disconnectable>;\n  // Rather than hold connection state on instances, Disconnectables recursively\n  // fetch the connection state from the RootPart they are connected in via\n  // getters up the Disconnectable tree via _$parent references. This pushes the\n  // cost of tracking the isConnected state to `AsyncDirectives`, and avoids\n  // needing to pass all Disconnectables (parts, template instances, and\n  // directives) their connection state each time it changes, which would be\n  // costly for trees that have no AsyncDirectives.\n  _$isConnected: boolean;\n}\n\nfunction resolveDirective(\n  part: ChildPart | AttributePart | ElementPart,\n  value: unknown,\n  parent: DirectiveParent = part,\n  attributeIndex?: number\n): unknown {\n  // Bail early if the value is explicitly noChange. Note, this means any\n  // nested directive is still attached and is not run.\n  if (value === noChange) {\n    return value;\n  }\n  let currentDirective =\n    attributeIndex !== undefined\n      ? (parent as AttributePart).__directives?.[attributeIndex]\n      : (parent as ChildPart | ElementPart | Directive).__directive;\n  const nextDirectiveConstructor = isPrimitive(value)\n    ? undefined\n    : // This property needs to remain unminified.\n      (value as DirectiveResult)['_$litDirective$'];\n  if (currentDirective?.constructor !== nextDirectiveConstructor) {\n    // This property needs to remain unminified.\n    currentDirective?.['_$notifyDirectiveConnectionChanged']?.(false);\n    if (nextDirectiveConstructor === undefined) {\n      currentDirective = undefined;\n    } else {\n      currentDirective = new nextDirectiveConstructor(part as PartInfo);\n      currentDirective._$initialize(part, parent, attributeIndex);\n    }\n    if (attributeIndex !== undefined) {\n      ((parent as AttributePart).__directives ??= [])[attributeIndex] =\n        currentDirective;\n    } else {\n      (parent as ChildPart | Directive).__directive = currentDirective;\n    }\n  }\n  if (currentDirective !== undefined) {\n    value = resolveDirective(\n      part,\n      currentDirective._$resolve(part, (value as DirectiveResult).values),\n      currentDirective,\n      attributeIndex\n    );\n  }\n  return value;\n}\n\n/**\n * An updateable instance of a Template. Holds references to the Parts used to\n * update the template instance.\n */\nclass TemplateInstance implements Disconnectable {\n  /** @internal */\n  _$template: Template;\n  /** @internal */\n  _parts: Array<Part | undefined> = [];\n\n  /** @internal */\n  _$parent: ChildPart;\n  /** @internal */\n  _$disconnectableChildren?: Set<Disconnectable> = undefined;\n\n  constructor(template: Template, parent: ChildPart) {\n    this._$template = template;\n    this._$parent = parent;\n  }\n\n  // Called by ChildPart parentNode getter\n  get parentNode() {\n    return this._$parent.parentNode;\n  }\n\n  // See comment in Disconnectable interface for why this is a getter\n  get _$isConnected() {\n    return this._$parent._$isConnected;\n  }\n\n  // This method is separate from the constructor because we need to return a\n  // DocumentFragment and we don't want to hold onto it with an instance field.\n  _clone(options: RenderOptions | undefined) {\n    const {\n      el: {content},\n      parts: parts,\n    } = this._$template;\n    const fragment = (options?.creationScope ?? d).importNode(content, true);\n    walker.currentNode = fragment;\n\n    let node = walker.nextNode()!;\n    let nodeIndex = 0;\n    let partIndex = 0;\n    let templatePart = parts[0];\n\n    while (templatePart !== undefined) {\n      if (nodeIndex === templatePart.index) {\n        let part: Part | undefined;\n        if (templatePart.type === CHILD_PART) {\n          part = new ChildPart(\n            node as HTMLElement,\n            node.nextSibling,\n            this,\n            options\n          );\n        } else if (templatePart.type === ATTRIBUTE_PART) {\n          part = new templatePart.ctor(\n            node as HTMLElement,\n            templatePart.name,\n            templatePart.strings,\n            this,\n            options\n          );\n        } else if (templatePart.type === ELEMENT_PART) {\n          part = new ElementPart(node as HTMLElement, this, options);\n        }\n        this._parts.push(part);\n        templatePart = parts[++partIndex];\n      }\n      if (nodeIndex !== templatePart?.index) {\n        node = walker.nextNode()!;\n        nodeIndex++;\n      }\n    }\n    return fragment;\n  }\n\n  _update(values: Array<unknown>) {\n    let i = 0;\n    for (const part of this._parts) {\n      if (part !== undefined) {\n        debugLogEvent?.({\n          kind: 'set part',\n          part,\n          value: values[i],\n          valueIndex: i,\n          values,\n          templateInstance: this,\n        });\n        if ((part as AttributePart).strings !== undefined) {\n          (part as AttributePart)._$setValue(values, part as AttributePart, i);\n          // The number of values the part consumes is part.strings.length - 1\n          // since values are in between template spans. We increment i by 1\n          // later in the loop, so increment it by part.strings.length - 2 here\n          i += (part as AttributePart).strings!.length - 2;\n        } else {\n          part._$setValue(values[i]);\n        }\n      }\n      i++;\n    }\n  }\n}\n\n/*\n * Parts\n */\ntype AttributeTemplatePart = {\n  readonly type: typeof ATTRIBUTE_PART;\n  readonly index: number;\n  readonly name: string;\n  /** @internal */\n  readonly ctor: typeof AttributePart;\n  /** @internal */\n  readonly strings: ReadonlyArray<string>;\n};\ntype NodeTemplatePart = {\n  readonly type: typeof CHILD_PART;\n  readonly index: number;\n};\ntype ElementTemplatePart = {\n  readonly type: typeof ELEMENT_PART;\n  readonly index: number;\n};\ntype CommentTemplatePart = {\n  readonly type: typeof COMMENT_PART;\n  readonly index: number;\n};\n\n/**\n * A TemplatePart represents a dynamic part in a template, before the template\n * is instantiated. When a template is instantiated Parts are created from\n * TemplateParts.\n */\ntype TemplatePart =\n  | NodeTemplatePart\n  | AttributeTemplatePart\n  | ElementTemplatePart\n  | CommentTemplatePart;\n\nexport type Part =\n  | ChildPart\n  | AttributePart\n  | PropertyPart\n  | BooleanAttributePart\n  | ElementPart\n  | EventPart;\n\nexport type {ChildPart};\nclass ChildPart implements Disconnectable {\n  readonly type = CHILD_PART;\n  readonly options: RenderOptions | undefined;\n  _$committedValue: unknown = nothing;\n  /** @internal */\n  __directive?: Directive;\n  /** @internal */\n  _$startNode: ChildNode;\n  /** @internal */\n  _$endNode: ChildNode | null;\n  private _textSanitizer: ValueSanitizer | undefined;\n  /** @internal */\n  _$parent: Disconnectable | undefined;\n  /**\n   * Connection state for RootParts only (i.e. ChildPart without _$parent\n   * returned from top-level `render`). This field is unsed otherwise. The\n   * intention would clearer if we made `RootPart` a subclass of `ChildPart`\n   * with this field (and a different _$isConnected getter), but the subclass\n   * caused a perf regression, possibly due to making call sites polymorphic.\n   * @internal\n   */\n  __isConnected: boolean;\n\n  // See comment in Disconnectable interface for why this is a getter\n  get _$isConnected() {\n    // ChildParts that are not at the root should always be created with a\n    // parent; only RootChildNode's won't, so they return the local isConnected\n    // state\n    return this._$parent?._$isConnected ?? this.__isConnected;\n  }\n\n  // The following fields will be patched onto ChildParts when required by\n  // AsyncDirective\n  /** @internal */\n  _$disconnectableChildren?: Set<Disconnectable> = undefined;\n  /** @internal */\n  _$notifyConnectionChanged?(\n    isConnected: boolean,\n    removeFromParent?: boolean,\n    from?: number\n  ): void;\n  /** @internal */\n  _$reparentDisconnectables?(parent: Disconnectable): void;\n\n  constructor(\n    startNode: ChildNode,\n    endNode: ChildNode | null,\n    parent: TemplateInstance | ChildPart | undefined,\n    options: RenderOptions | undefined\n  ) {\n    this._$startNode = startNode;\n    this._$endNode = endNode;\n    this._$parent = parent;\n    this.options = options;\n    // Note __isConnected is only ever accessed on RootParts (i.e. when there is\n    // no _$parent); the value on a non-root-part is \"don't care\", but checking\n    // for parent would be more code\n    this.__isConnected = options?.isConnected ?? true;\n    if (ENABLE_EXTRA_SECURITY_HOOKS) {\n      // Explicitly initialize for consistent class shape.\n      this._textSanitizer = undefined;\n    }\n  }\n\n  /**\n   * The parent node into which the part renders its content.\n   *\n   * A ChildPart's content consists of a range of adjacent child nodes of\n   * `.parentNode`, possibly bordered by 'marker nodes' (`.startNode` and\n   * `.endNode`).\n   *\n   * - If both `.startNode` and `.endNode` are non-null, then the part's content\n   * consists of all siblings between `.startNode` and `.endNode`, exclusively.\n   *\n   * - If `.startNode` is non-null but `.endNode` is null, then the part's\n   * content consists of all siblings following `.startNode`, up to and\n   * including the last child of `.parentNode`. If `.endNode` is non-null, then\n   * `.startNode` will always be non-null.\n   *\n   * - If both `.endNode` and `.startNode` are null, then the part's content\n   * consists of all child nodes of `.parentNode`.\n   */\n  get parentNode(): Node {\n    let parentNode: Node = wrap(this._$startNode).parentNode!;\n    const parent = this._$parent;\n    if (\n      parent !== undefined &&\n      parentNode.nodeType === 11 /* Node.DOCUMENT_FRAGMENT */\n    ) {\n      // If the parentNode is a DocumentFragment, it may be because the DOM is\n      // still in the cloned fragment during initial render; if so, get the real\n      // parentNode the part will be committed into by asking the parent.\n      parentNode = (parent as ChildPart | TemplateInstance).parentNode;\n    }\n    return parentNode;\n  }\n\n  /**\n   * The part's leading marker node, if any. See `.parentNode` for more\n   * information.\n   */\n  get startNode(): Node | null {\n    return this._$startNode;\n  }\n\n  /**\n   * The part's trailing marker node, if any. See `.parentNode` for more\n   * information.\n   */\n  get endNode(): Node | null {\n    return this._$endNode;\n  }\n\n  _$setValue(value: unknown, directiveParent: DirectiveParent = this): void {\n    if (DEV_MODE && this.parentNode === null) {\n      throw new Error(\n        `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.`\n      );\n    }\n    value = resolveDirective(this, value, directiveParent);\n    if (isPrimitive(value)) {\n      // Non-rendering child values. It's important that these do not render\n      // empty text nodes to avoid issues with preventing default <slot>\n      // fallback content.\n      if (value === nothing || value == null || value === '') {\n        if (this._$committedValue !== nothing) {\n          debugLogEvent?.({\n            kind: 'commit nothing to child',\n            start: this._$startNode,\n            end: this._$endNode,\n            parent: this._$parent,\n            options: this.options,\n          });\n          this._$clear();\n        }\n        this._$committedValue = nothing;\n      } else if (value !== this._$committedValue && value !== noChange) {\n        this._commitText(value);\n      }\n      // This property needs to remain unminified.\n    } else if ((value as TemplateResult)['_$litType$'] !== undefined) {\n      this._commitTemplateResult(value as TemplateResult);\n    } else if ((value as Node).nodeType !== undefined) {\n      this._commitNode(value as Node);\n    } else if (isIterable(value)) {\n      this._commitIterable(value);\n    } else {\n      // Fallback, will render the string representation\n      this._commitText(value);\n    }\n  }\n\n  private _insert<T extends Node>(node: T, ref = this._$endNode) {\n    return wrap(wrap(this._$startNode).parentNode!).insertBefore(node, ref);\n  }\n\n  private _commitNode(value: Node): void {\n    if (this._$committedValue !== value) {\n      this._$clear();\n      if (\n        ENABLE_EXTRA_SECURITY_HOOKS &&\n        sanitizerFactoryInternal !== noopSanitizer\n      ) {\n        const parentNodeName = this._$startNode.parentNode?.nodeName;\n        if (parentNodeName === 'STYLE' || parentNodeName === 'SCRIPT') {\n          let message = 'Forbidden';\n          if (DEV_MODE) {\n            if (parentNodeName === 'STYLE') {\n              message =\n                `Lit does not support binding inside style nodes. ` +\n                `This is a security risk, as style injection attacks can ` +\n                `exfiltrate data and spoof UIs. ` +\n                `Consider instead using css\\`...\\` literals ` +\n                `to compose styles, and make do dynamic styling with ` +\n                `css custom properties, ::parts, <slot>s, ` +\n                `and by mutating the DOM rather than stylesheets.`;\n            } else {\n              message =\n                `Lit does not support binding inside script nodes. ` +\n                `This is a security risk, as it could allow arbitrary ` +\n                `code execution.`;\n            }\n          }\n          throw new Error(message);\n        }\n      }\n      debugLogEvent?.({\n        kind: 'commit node',\n        start: this._$startNode,\n        parent: this._$parent,\n        value: value,\n        options: this.options,\n      });\n      this._$committedValue = this._insert(value);\n    }\n  }\n\n  private _commitText(value: unknown): void {\n    // If the committed value is a primitive it means we called _commitText on\n    // the previous render, and we know that this._$startNode.nextSibling is a\n    // Text node. We can now just replace the text content (.data) of the node.\n    if (\n      this._$committedValue !== nothing &&\n      isPrimitive(this._$committedValue)\n    ) {\n      const node = wrap(this._$startNode).nextSibling as Text;\n      if (ENABLE_EXTRA_SECURITY_HOOKS) {\n        if (this._textSanitizer === undefined) {\n          this._textSanitizer = createSanitizer(node, 'data', 'property');\n        }\n        value = this._textSanitizer(value);\n      }\n      debugLogEvent?.({\n        kind: 'commit text',\n        node,\n        value,\n        options: this.options,\n      });\n      (node as Text).data = value as string;\n    } else {\n      if (ENABLE_EXTRA_SECURITY_HOOKS) {\n        const textNode = document.createTextNode('');\n        this._commitNode(textNode);\n        // When setting text content, for security purposes it matters a lot\n        // what the parent is. For example, <style> and <script> need to be\n        // handled with care, while <span> does not. So first we need to put a\n        // text node into the document, then we can sanitize its content.\n        if (this._textSanitizer === undefined) {\n          this._textSanitizer = createSanitizer(textNode, 'data', 'property');\n        }\n        value = this._textSanitizer(value);\n        debugLogEvent?.({\n          kind: 'commit text',\n          node: textNode,\n          value,\n          options: this.options,\n        });\n        textNode.data = value as string;\n      } else {\n        this._commitNode(d.createTextNode(value as string));\n        debugLogEvent?.({\n          kind: 'commit text',\n          node: wrap(this._$startNode).nextSibling as Text,\n          value,\n          options: this.options,\n        });\n      }\n    }\n    this._$committedValue = value;\n  }\n\n  private _commitTemplateResult(\n    result: TemplateResult | CompiledTemplateResult\n  ): void {\n    // This property needs to remain unminified.\n    const {values, ['_$litType$']: type} = result;\n    // If $litType$ is a number, result is a plain TemplateResult and we get\n    // the template from the template cache. If not, result is a\n    // CompiledTemplateResult and _$litType$ is a CompiledTemplate and we need\n    // to create the <template> element the first time we see it.\n    const template: Template | CompiledTemplate =\n      typeof type === 'number'\n        ? this._$getTemplate(result as TemplateResult)\n        : (type.el === undefined &&\n            (type.el = Template.createElement(type.h, this.options)),\n          type);\n\n    if ((this._$committedValue as TemplateInstance)?._$template === template) {\n      debugLogEvent?.({\n        kind: 'template updating',\n        template,\n        instance: this._$committedValue as TemplateInstance,\n        parts: (this._$committedValue as TemplateInstance)._parts,\n        options: this.options,\n        values,\n      });\n      (this._$committedValue as TemplateInstance)._update(values);\n    } else {\n      const instance = new TemplateInstance(template as Template, this);\n      const fragment = instance._clone(this.options);\n      debugLogEvent?.({\n        kind: 'template instantiated',\n        template,\n        instance,\n        parts: instance._parts,\n        options: this.options,\n        fragment,\n        values,\n      });\n      instance._update(values);\n      debugLogEvent?.({\n        kind: 'template instantiated and updated',\n        template,\n        instance,\n        parts: instance._parts,\n        options: this.options,\n        fragment,\n        values,\n      });\n      this._commitNode(fragment);\n      this._$committedValue = instance;\n    }\n  }\n\n  // Overridden via `litHtmlPolyfillSupport` to provide platform support.\n  /** @internal */\n  _$getTemplate(result: TemplateResult) {\n    let template = templateCache.get(result.strings);\n    if (template === undefined) {\n      templateCache.set(result.strings, (template = new Template(result)));\n    }\n    return template;\n  }\n\n  private _commitIterable(value: Iterable<unknown>): void {\n    // For an Iterable, we create a new InstancePart per item, then set its\n    // value to the item. This is a little bit of overhead for every item in\n    // an Iterable, but it lets us recurse easily and efficiently update Arrays\n    // of TemplateResults that will be commonly returned from expressions like:\n    // array.map((i) => html`${i}`), by reusing existing TemplateInstances.\n\n    // If value is an array, then the previous render was of an\n    // iterable and value will contain the ChildParts from the previous\n    // render. If value is not an array, clear this part and make a new\n    // array for ChildParts.\n    if (!isArray(this._$committedValue)) {\n      this._$committedValue = [];\n      this._$clear();\n    }\n\n    // Lets us keep track of how many items we stamped so we can clear leftover\n    // items from a previous render\n    const itemParts = this._$committedValue as ChildPart[];\n    let partIndex = 0;\n    let itemPart: ChildPart | undefined;\n\n    for (const item of value) {\n      if (partIndex === itemParts.length) {\n        // If no existing part, create a new one\n        // TODO (justinfagnani): test perf impact of always creating two parts\n        // instead of sharing parts between nodes\n        // https://github.com/lit/lit/issues/1266\n        itemParts.push(\n          (itemPart = new ChildPart(\n            this._insert(createMarker()),\n            this._insert(createMarker()),\n            this,\n            this.options\n          ))\n        );\n      } else {\n        // Reuse an existing part\n        itemPart = itemParts[partIndex];\n      }\n      itemPart._$setValue(item);\n      partIndex++;\n    }\n\n    if (partIndex < itemParts.length) {\n      // itemParts always have end nodes\n      this._$clear(\n        itemPart && wrap(itemPart._$endNode!).nextSibling,\n        partIndex\n      );\n      // Truncate the parts array so _value reflects the current state\n      itemParts.length = partIndex;\n    }\n  }\n\n  /**\n   * Removes the nodes contained within this Part from the DOM.\n   *\n   * @param start Start node to clear from, for clearing a subset of the part's\n   *     DOM (used when truncating iterables)\n   * @param from  When `start` is specified, the index within the iterable from\n   *     which ChildParts are being removed, used for disconnecting directives in\n   *     those Parts.\n   *\n   * @internal\n   */\n  _$clear(\n    start: ChildNode | null = wrap(this._$startNode).nextSibling,\n    from?: number\n  ) {\n    this._$notifyConnectionChanged?.(false, true, from);\n    while (start && start !== this._$endNode) {\n      const n = wrap(start!).nextSibling;\n      (wrap(start!) as Element).remove();\n      start = n;\n    }\n  }\n  /**\n   * Implementation of RootPart's `isConnected`. Note that this metod\n   * should only be called on `RootPart`s (the `ChildPart` returned from a\n   * top-level `render()` call). It has no effect on non-root ChildParts.\n   * @param isConnected Whether to set\n   * @internal\n   */\n  setConnected(isConnected: boolean) {\n    if (this._$parent === undefined) {\n      this.__isConnected = isConnected;\n      this._$notifyConnectionChanged?.(isConnected);\n    } else if (DEV_MODE) {\n      throw new Error(\n        'part.setConnected() may only be called on a ' +\n          'RootPart returned from render().'\n      );\n    }\n  }\n}\n\n/**\n * A top-level `ChildPart` returned from `render` that manages the connected\n * state of `AsyncDirective`s created throughout the tree below it.\n */\nexport interface RootPart extends ChildPart {\n  /**\n   * Sets the connection state for `AsyncDirective`s contained within this root\n   * ChildPart.\n   *\n   * lit-html does not automatically monitor the connectedness of DOM rendered;\n   * as such, it is the responsibility of the caller to `render` to ensure that\n   * `part.setConnected(false)` is called before the part object is potentially\n   * discarded, to ensure that `AsyncDirective`s have a chance to dispose of\n   * any resources being held. If a `RootPart` that was prevously\n   * disconnected is subsequently re-connected (and its `AsyncDirective`s should\n   * re-connect), `setConnected(true)` should be called.\n   *\n   * @param isConnected Whether directives within this tree should be connected\n   * or not\n   */\n  setConnected(isConnected: boolean): void;\n}\n\nexport type {AttributePart};\nclass AttributePart implements Disconnectable {\n  readonly type = ATTRIBUTE_PART as\n    | typeof ATTRIBUTE_PART\n    | typeof PROPERTY_PART\n    | typeof BOOLEAN_ATTRIBUTE_PART\n    | typeof EVENT_PART;\n  readonly element: HTMLElement;\n  readonly name: string;\n  readonly options: RenderOptions | undefined;\n\n  /**\n   * If this attribute part represents an interpolation, this contains the\n   * static strings of the interpolation. For single-value, complete bindings,\n   * this is undefined.\n   */\n  readonly strings?: ReadonlyArray<string>;\n  /** @internal */\n  _$committedValue: unknown | Array<unknown> = nothing;\n  /** @internal */\n  __directives?: Array<Directive | undefined>;\n  /** @internal */\n  _$parent: Disconnectable;\n  /** @internal */\n  _$disconnectableChildren?: Set<Disconnectable> = undefined;\n\n  protected _sanitizer: ValueSanitizer | undefined;\n\n  get tagName() {\n    return this.element.tagName;\n  }\n\n  // See comment in Disconnectable interface for why this is a getter\n  get _$isConnected() {\n    return this._$parent._$isConnected;\n  }\n\n  constructor(\n    element: HTMLElement,\n    name: string,\n    strings: ReadonlyArray<string>,\n    parent: Disconnectable,\n    options: RenderOptions | undefined\n  ) {\n    this.element = element;\n    this.name = name;\n    this._$parent = parent;\n    this.options = options;\n    if (strings.length > 2 || strings[0] !== '' || strings[1] !== '') {\n      this._$committedValue = new Array(strings.length - 1).fill(new String());\n      this.strings = strings;\n    } else {\n      this._$committedValue = nothing;\n    }\n    if (ENABLE_EXTRA_SECURITY_HOOKS) {\n      this._sanitizer = undefined;\n    }\n  }\n\n  /**\n   * Sets the value of this part by resolving the value from possibly multiple\n   * values and static strings and committing it to the DOM.\n   * If this part is single-valued, `this._strings` will be undefined, and the\n   * method will be called with a single value argument. If this part is\n   * multi-value, `this._strings` will be defined, and the method is called\n   * with the value array of the part's owning TemplateInstance, and an offset\n   * into the value array from which the values should be read.\n   * This method is overloaded this way to eliminate short-lived array slices\n   * of the template instance values, and allow a fast-path for single-valued\n   * parts.\n   *\n   * @param value The part value, or an array of values for multi-valued parts\n   * @param valueIndex the index to start reading values from. `undefined` for\n   *   single-valued parts\n   * @param noCommit causes the part to not commit its value to the DOM. Used\n   *   in hydration to prime attribute parts with their first-rendered value,\n   *   but not set the attribute, and in SSR to no-op the DOM operation and\n   *   capture the value for serialization.\n   *\n   * @internal\n   */\n  _$setValue(\n    value: unknown | Array<unknown>,\n    directiveParent: DirectiveParent = this,\n    valueIndex?: number,\n    noCommit?: boolean\n  ) {\n    const strings = this.strings;\n\n    // Whether any of the values has changed, for dirty-checking\n    let change = false;\n\n    if (strings === undefined) {\n      // Single-value binding case\n      value = resolveDirective(this, value, directiveParent, 0);\n      change =\n        !isPrimitive(value) ||\n        (value !== this._$committedValue && value !== noChange);\n      if (change) {\n        this._$committedValue = value;\n      }\n    } else {\n      // Interpolation case\n      const values = value as Array<unknown>;\n      value = strings[0];\n\n      let i, v;\n      for (i = 0; i < strings.length - 1; i++) {\n        v = resolveDirective(this, values[valueIndex! + i], directiveParent, i);\n\n        if (v === noChange) {\n          // If the user-provided value is `noChange`, use the previous value\n          v = (this._$committedValue as Array<unknown>)[i];\n        }\n        change ||=\n          !isPrimitive(v) || v !== (this._$committedValue as Array<unknown>)[i];\n        if (v === nothing) {\n          value = nothing;\n        } else if (value !== nothing) {\n          value += (v ?? '') + strings[i + 1];\n        }\n        // We always record each value, even if one is `nothing`, for future\n        // change detection.\n        (this._$committedValue as Array<unknown>)[i] = v;\n      }\n    }\n    if (change && !noCommit) {\n      this._commitValue(value);\n    }\n  }\n\n  /** @internal */\n  _commitValue(value: unknown) {\n    if (value === nothing) {\n      (wrap(this.element) as Element).removeAttribute(this.name);\n    } else {\n      if (ENABLE_EXTRA_SECURITY_HOOKS) {\n        if (this._sanitizer === undefined) {\n          this._sanitizer = sanitizerFactoryInternal(\n            this.element,\n            this.name,\n            'attribute'\n          );\n        }\n        value = this._sanitizer(value ?? '');\n      }\n      debugLogEvent?.({\n        kind: 'commit attribute',\n        element: this.element,\n        name: this.name,\n        value,\n        options: this.options,\n      });\n      (wrap(this.element) as Element).setAttribute(\n        this.name,\n        (value ?? '') as string\n      );\n    }\n  }\n}\n\nexport type {PropertyPart};\nclass PropertyPart extends AttributePart {\n  override readonly type = PROPERTY_PART;\n\n  /** @internal */\n  override _commitValue(value: unknown) {\n    if (ENABLE_EXTRA_SECURITY_HOOKS) {\n      if (this._sanitizer === undefined) {\n        this._sanitizer = sanitizerFactoryInternal(\n          this.element,\n          this.name,\n          'property'\n        );\n      }\n      value = this._sanitizer(value);\n    }\n    debugLogEvent?.({\n      kind: 'commit property',\n      element: this.element,\n      name: this.name,\n      value,\n      options: this.options,\n    });\n    // eslint-disable-next-line @typescript-eslint/no-explicit-any\n    (this.element as any)[this.name] = value === nothing ? undefined : value;\n  }\n}\n\n// Temporary workaround for https://crbug.com/993268\n// Currently, any attribute starting with \"on\" is considered to be a\n// TrustedScript source. Such boolean attributes must be set to the equivalent\n// trusted emptyScript value.\nconst emptyStringForBooleanAttribute = trustedTypes\n  ? (trustedTypes.emptyScript as unknown as '')\n  : '';\n\nexport type {BooleanAttributePart};\nclass BooleanAttributePart extends AttributePart {\n  override readonly type = BOOLEAN_ATTRIBUTE_PART;\n\n  /** @internal */\n  override _commitValue(value: unknown) {\n    debugLogEvent?.({\n      kind: 'commit boolean attribute',\n      element: this.element,\n      name: this.name,\n      value: !!(value && value !== nothing),\n      options: this.options,\n    });\n    if (value && value !== nothing) {\n      (wrap(this.element) as Element).setAttribute(\n        this.name,\n        emptyStringForBooleanAttribute\n      );\n    } else {\n      (wrap(this.element) as Element).removeAttribute(this.name);\n    }\n  }\n}\n\ntype EventListenerWithOptions = EventListenerOrEventListenerObject &\n  Partial<AddEventListenerOptions>;\n\n/**\n * An AttributePart that manages an event listener via add/removeEventListener.\n *\n * This part works by adding itself as the event listener on an element, then\n * delegating to the value passed to it. This reduces the number of calls to\n * add/removeEventListener if the listener changes frequently, such as when an\n * inline function is used as a listener.\n *\n * Because event options are passed when adding listeners, we must take case\n * to add and remove the part as a listener when the event options change.\n */\nexport type {EventPart};\nclass EventPart extends AttributePart {\n  override readonly type = EVENT_PART;\n\n  constructor(\n    element: HTMLElement,\n    name: string,\n    strings: ReadonlyArray<string>,\n    parent: Disconnectable,\n    options: RenderOptions | undefined\n  ) {\n    super(element, name, strings, parent, options);\n\n    if (DEV_MODE && this.strings !== undefined) {\n      throw new Error(\n        `A \\`<${element.localName}>\\` has a \\`@${name}=...\\` listener with ` +\n          'invalid content. Event listeners in templates must have exactly ' +\n          'one expression and no surrounding text.'\n      );\n    }\n  }\n\n  // EventPart does not use the base _$setValue/_resolveValue implementation\n  // since the dirty checking is more complex\n  /** @internal */\n  override _$setValue(\n    newListener: unknown,\n    directiveParent: DirectiveParent = this\n  ) {\n    newListener =\n      resolveDirective(this, newListener, directiveParent, 0) ?? nothing;\n    if (newListener === noChange) {\n      return;\n    }\n    const oldListener = this._$committedValue;\n\n    // If the new value is nothing or any options change we have to remove the\n    // part as a listener.\n    const shouldRemoveListener =\n      (newListener === nothing && oldListener !== nothing) ||\n      (newListener as EventListenerWithOptions).capture !==\n        (oldListener as EventListenerWithOptions).capture ||\n      (newListener as EventListenerWithOptions).once !==\n        (oldListener as EventListenerWithOptions).once ||\n      (newListener as EventListenerWithOptions).passive !==\n        (oldListener as EventListenerWithOptions).passive;\n\n    // If the new value is not nothing and we removed the listener, we have\n    // to add the part as a listener.\n    const shouldAddListener =\n      newListener !== nothing &&\n      (oldListener === nothing || shouldRemoveListener);\n\n    debugLogEvent?.({\n      kind: 'commit event listener',\n      element: this.element,\n      name: this.name,\n      value: newListener,\n      options: this.options,\n      removeListener: shouldRemoveListener,\n      addListener: shouldAddListener,\n      oldListener,\n    });\n    if (shouldRemoveListener) {\n      this.element.removeEventListener(\n        this.name,\n        this,\n        oldListener as EventListenerWithOptions\n      );\n    }\n    if (shouldAddListener) {\n      // Beware: IE11 and Chrome 41 don't like using the listener as the\n      // options object. Figure out how to deal w/ this in IE11 - maybe\n      // patch addEventListener?\n      this.element.addEventListener(\n        this.name,\n        this,\n        newListener as EventListenerWithOptions\n      );\n    }\n    this._$committedValue = newListener;\n  }\n\n  handleEvent(event: Event) {\n    if (typeof this._$committedValue === 'function') {\n      this._$committedValue.call(this.options?.host ?? this.element, event);\n    } else {\n      (this._$committedValue as EventListenerObject).handleEvent(event);\n    }\n  }\n}\n\nexport type {ElementPart};\nclass ElementPart implements Disconnectable {\n  readonly type = ELEMENT_PART;\n\n  /** @internal */\n  __directive?: Directive;\n\n  // This is to ensure that every Part has a _$committedValue\n  _$committedValue: undefined;\n\n  /** @internal */\n  _$parent!: Disconnectable;\n\n  /** @internal */\n  _$disconnectableChildren?: Set<Disconnectable> = undefined;\n\n  options: RenderOptions | undefined;\n\n  constructor(\n    public element: Element,\n    parent: Disconnectable,\n    options: RenderOptions | undefined\n  ) {\n    this._$parent = parent;\n    this.options = options;\n  }\n\n  // See comment in Disconnectable interface for why this is a getter\n  get _$isConnected() {\n    return this._$parent._$isConnected;\n  }\n\n  _$setValue(value: unknown): void {\n    debugLogEvent?.({\n      kind: 'commit to element binding',\n      element: this.element,\n      value,\n      options: this.options,\n    });\n    resolveDirective(this, value);\n  }\n}\n\n/**\n * END USERS SHOULD NOT RELY ON THIS OBJECT.\n *\n * Private exports for use by other Lit packages, not intended for use by\n * external users.\n *\n * We currently do not make a mangled rollup build of the lit-ssr code. In order\n * to keep a number of (otherwise private) top-level exports  mangled in the\n * client side code, we export a _$LH object containing those members (or\n * helper methods for accessing private fields of those members), and then\n * re-export them for use in lit-ssr. This keeps lit-ssr agnostic to whether the\n * client-side code is being used in `dev` mode or `prod` mode.\n *\n * This has a unique name, to disambiguate it from private exports in\n * lit-element, which re-exports all of lit-html.\n *\n * @private\n */\nexport const _$LH = {\n  // Used in lit-ssr\n  _boundAttributeSuffix: boundAttributeSuffix,\n  _marker: marker,\n  _markerMatch: markerMatch,\n  _HTML_RESULT: HTML_RESULT,\n  _getTemplateHtml: getTemplateHtml,\n  // Used in hydrate\n  _TemplateInstance: TemplateInstance,\n  _isIterable: isIterable,\n  _resolveDirective: resolveDirective,\n  // Used in tests and private-ssr-support\n  _ChildPart: ChildPart,\n  _AttributePart: AttributePart,\n  _BooleanAttributePart: BooleanAttributePart,\n  _EventPart: EventPart,\n  _PropertyPart: PropertyPart,\n  _ElementPart: ElementPart,\n};\n\n// Apply polyfills if available\nconst polyfillSupport = DEV_MODE\n  ? window.litHtmlPolyfillSupportDevMode\n  : window.litHtmlPolyfillSupport;\npolyfillSupport?.(Template, ChildPart);\n\n// IMPORTANT: do not change the property name or the assignment expression.\n// This line will be used in regexes to search for lit-html usage.\n(globalThis.litHtmlVersions ??= []).push('2.2.1');\nif (DEV_MODE && globalThis.litHtmlVersions.length > 1) {\n  issueWarning!(\n    'multiple-versions',\n    `Multiple versions of Lit loaded. ` +\n      `Loading multiple versions is not recommended.`\n  );\n}\n"],"names":["trustedTypes","globalThis","policy","createPolicy","createHTML","s","undefined","marker","Math","random","String","slice","markerMatch","nodeMarker","d","document","createMarker","v","createComment","isPrimitive","value","isArray","Array","isIterable","Symbol","iterator","textEndRegex","commentEndRegex","comment2EndRegex","tagEndRegex","singleQuoteAttrEndRegex","doubleQuoteAttrEndRegex","rawTextElement","tag","type","strings","values","_$litType$","html","svg","noChange","for","nothing","templateCache","WeakMap","render","container","options","partOwnerNode","renderBefore","part","endNode","ChildPart","insertBefore","_$setValue","walker","createTreeWalker","getTemplateHtml","l","length","attrNames","rawTextEndRegex","regex","i","attrName","match","attrNameEndIndex","lastIndex","exec","test","RegExp","end","startsWith","push","htmlResult","hasOwnProperty","Error","Template","constructor","node","this","nodeIndex","attrNameIndex","partCount","parts","el","createElement","currentNode","content","svgElement","firstChild","remove","append","childNodes","nextNode","nodeType","hasAttributes","attrsToRemove","name","getAttributeNames","endsWith","realName","statics","getAttribute","toLowerCase","split","m","index","ctor","PropertyPart","BooleanAttributePart","EventPart","AttributePart","removeAttribute","tagName","textContent","emptyScript","data","indexOf","static","_options","innerHTML","resolveDirective","parent","attributeIndex","currentDirective","__directives","__directive","nextDirectiveConstructor","_$initialize","_$resolve","TemplateInstance","template","_$template","_$parent","parentNode","_$isConnected","_clone","fragment","creationScope","importNode","partIndex","templatePart","nextSibling","ElementPart","_parts","_update","startNode","_$startNode","_$endNode","__isConnected","isConnected","directiveParent","_$committedValue","_$clear","_commitText","_commitTemplateResult","_commitNode","_commitIterable","_insert","ref","createTextNode","result","_$getTemplate","h","instance","get","set","itemParts","itemPart","item","start","from","_$notifyConnectionChanged","n","setConnected","element","fill","valueIndex","noCommit","change","_commitValue","setAttribute","emptyStringForBooleanAttribute","super","newListener","oldListener","shouldRemoveListener","capture","once","passive","shouldAddListener","removeEventListener","addEventListener","handleEvent","event","call","host","_$LH","_boundAttributeSuffix","_marker","_markerMatch","_HTML_RESULT","_getTemplateHtml","_TemplateInstance","_isIterable","_resolveDirective","_ChildPart","_AttributePart","_BooleanAttributePart","_EventPart","_PropertyPart","_ElementPart","polyfillSupport","window","litHtmlPolyfillSupport","litHtmlVersions"],"mappings":";;;;;MA8OA,MAOMA,EAAgBC,WAA0CD,aAU1DE,EAASF,EACXA,EAAaG,aAAa,WAAY,CACpCC,WAAaC,GAAMA,SAErBC,EAkFEC,EAAS,QAAcC,KAAKC,SAAZC,IAAsBC,MAAM,MAG5CC,EAAc,IAAML,EAIpBM,EAAa,IAAID,KAEjBE,EAAIC,SAGJC,EAAe,CAACC,EAAI,KAAOH,EAAEI,cAAcD,GAI3CE,EAAeC,GACT,OAAVA,GAAmC,iBAATA,GAAqC,mBAATA,EAClDC,EAAUC,MAAMD,QAChBE,EAAcH,UAClB,OAAAC,EAAQD,IAEqC,6BAArCA,wBAAgBI,OAAOC,YAoB3BC,EAAe,sDAKfC,EAAkB,OAIlBC,EAAmB,KAwBnBC,EAAc,oFASdC,EAA0B,KAC1BC,EAA0B,KAO1BC,EAAiB,qCAoDjBC,EACmBC,GACvB,CAACC,KAAkCC,KAU1B,CAELC,WAAgBH,EAChBC,QAAAA,EACAC,OAAAA,IAiBOE,EAAOL,EAlFA,GA2GPM,EAAMN,EA1GA,GAgHNO,EAAWhB,OAAOiB,IAAI,gBAqBtBC,EAAUlB,OAAOiB,IAAI,eAS5BE,EAAgB,IAAIC,QAuDbC,EAAS,CACpBzB,EACA0B,EACAC,aAGA,MAAMC,YAAgBD,MAAAA,SAAAA,EAASE,4BAAgBH,EAG/C,IAAII,EAAmBF,EAAkC,WASzD,QAAa1C,IA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E,EAS/C0E,KAAKsD,KAAWX,EAChB3C,KAAKjC,QAAUA,EAIbyF,WACF,OAAOxD,KAAKsD,KAASE,KAGvBlF,KAAWlC,GAOTsG,EAAiB1C,KAAM5D,UAsBdkL,EAAO,CAElBC,EAtvD2B,QAuvD3BC,EAASjM,EACTkM,EAAc7L,EACd8L,EAppDkB,EAqpDlBC,EAAkBlJ,EAElBmJ,EAAmBzE,EACnB0E,EAAatL,EACbuL,EAAmBpF,EAEnBqF,EAAY3J,EACZ4J,EAAgBhG,EAChBiG,EAAuBnG,EACvBoG,EAAYnG,EACZoG,EAAetG,EACfuG,EAAcpE,GAIVqE,EAEFC,OAAOC,uBACXF,MAAAA,GAAAA,EAAkBxI,EAAUzB,cAI3BnD,WAAWuN,+BAAXvN,WAAWuN,gBAAoB,IAAI/I,KAAK"}
\ No newline at end of file
+{"version":3,"file":"lit-html.js","sources":["src/lit-html.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n// IMPORTANT: these imports must be type-only\nimport type {Directive, DirectiveResult, PartInfo} from './directive.js';\n\nconst DEV_MODE = true;\nconst ENABLE_EXTRA_SECURITY_HOOKS = true;\nconst ENABLE_SHADYDOM_NOPATCH = true;\nconst NODE_MODE = false;\n// Use window for browser builds because IE11 doesn't have globalThis.\nconst global = NODE_MODE ? globalThis : window;\n\n/**\n * Contains types that are part of the unstable debug API.\n *\n * Everything in this API is not stable and may change or be removed in the future,\n * even on patch releases.\n */\n// eslint-disable-next-line @typescript-eslint/no-namespace\nexport namespace LitUnstable {\n  /**\n   * When Lit is running in dev mode and `window.emitLitDebugLogEvents` is true,\n   * we will emit 'lit-debug' events to window, with live details about the update and render\n   * lifecycle. These can be useful for writing debug tooling and visualizations.\n   *\n   * Please be aware that running with window.emitLitDebugLogEvents has performance overhead,\n   * making certain operations that are normally very cheap (like a no-op render) much slower,\n   * because we must copy data and dispatch events.\n   */\n  // eslint-disable-next-line @typescript-eslint/no-namespace\n  export namespace DebugLog {\n    export type Entry =\n      | TemplatePrep\n      | TemplateInstantiated\n      | TemplateInstantiatedAndUpdated\n      | TemplateUpdating\n      | BeginRender\n      | EndRender\n      | CommitPartEntry\n      | SetPartValue;\n    export interface TemplatePrep {\n      kind: 'template prep';\n      template: Template;\n      strings: TemplateStringsArray;\n      clonableTemplate: HTMLTemplateElement;\n      parts: TemplatePart[];\n    }\n    export interface BeginRender {\n      kind: 'begin render';\n      id: number;\n      value: unknown;\n      container: HTMLElement | DocumentFragment;\n      options: RenderOptions | undefined;\n      part: ChildPart | undefined;\n    }\n    export interface EndRender {\n      kind: 'end render';\n      id: number;\n      value: unknown;\n      container: HTMLElement | DocumentFragment;\n      options: RenderOptions | undefined;\n      part: ChildPart;\n    }\n    export interface TemplateInstantiated {\n      kind: 'template instantiated';\n      template: Template | CompiledTemplate;\n      instance: TemplateInstance;\n      options: RenderOptions | undefined;\n      fragment: Node;\n      parts: Array<Part | undefined>;\n      values: unknown[];\n    }\n    export interface TemplateInstantiatedAndUpdated {\n      kind: 'template instantiated and updated';\n      template: Template | CompiledTemplate;\n      instance: TemplateInstance;\n      options: RenderOptions | undefined;\n      fragment: Node;\n      parts: Array<Part | undefined>;\n      values: unknown[];\n    }\n    export interface TemplateUpdating {\n      kind: 'template updating';\n      template: Template | CompiledTemplate;\n      instance: TemplateInstance;\n      options: RenderOptions | undefined;\n      parts: Array<Part | undefined>;\n      values: unknown[];\n    }\n    export interface SetPartValue {\n      kind: 'set part';\n      part: Part;\n      value: unknown;\n      valueIndex: number;\n      values: unknown[];\n      templateInstance: TemplateInstance;\n    }\n\n    export type CommitPartEntry =\n      | CommitNothingToChildEntry\n      | CommitText\n      | CommitNode\n      | CommitAttribute\n      | CommitProperty\n      | CommitBooleanAttribute\n      | CommitEventListener\n      | CommitToElementBinding;\n\n    export interface CommitNothingToChildEntry {\n      kind: 'commit nothing to child';\n      start: ChildNode;\n      end: ChildNode | null;\n      parent: Disconnectable | undefined;\n      options: RenderOptions | undefined;\n    }\n\n    export interface CommitText {\n      kind: 'commit text';\n      node: Text;\n      value: unknown;\n      options: RenderOptions | undefined;\n    }\n\n    export interface CommitNode {\n      kind: 'commit node';\n      start: Node;\n      parent: Disconnectable | undefined;\n      value: Node;\n      options: RenderOptions | undefined;\n    }\n\n    export interface CommitAttribute {\n      kind: 'commit attribute';\n      element: Element;\n      name: string;\n      value: unknown;\n      options: RenderOptions | undefined;\n    }\n\n    export interface CommitProperty {\n      kind: 'commit property';\n      element: Element;\n      name: string;\n      value: unknown;\n      options: RenderOptions | undefined;\n    }\n\n    export interface CommitBooleanAttribute {\n      kind: 'commit boolean attribute';\n      element: Element;\n      name: string;\n      value: boolean;\n      options: RenderOptions | undefined;\n    }\n\n    export interface CommitEventListener {\n      kind: 'commit event listener';\n      element: Element;\n      name: string;\n      value: unknown;\n      oldListener: unknown;\n      options: RenderOptions | undefined;\n      // True if we're removing the old event listener (e.g. because settings changed, or value is nothing)\n      removeListener: boolean;\n      // True if we're adding a new event listener (e.g. because first render, or settings changed)\n      addListener: boolean;\n    }\n\n    export interface CommitToElementBinding {\n      kind: 'commit to element binding';\n      element: Element;\n      value: unknown;\n      options: RenderOptions | undefined;\n    }\n  }\n}\n\ninterface DebugLoggingWindow {\n  // Even in dev mode, we generally don't want to emit these events, as that's\n  // another level of cost, so only emit them when DEV_MODE is true _and_ when\n  // window.emitLitDebugEvents is true.\n  emitLitDebugLogEvents?: boolean;\n}\n\n/**\n * Useful for visualizing and logging insights into what the Lit template system is doing.\n *\n * Compiled out of prod mode builds.\n */\nconst debugLogEvent = DEV_MODE\n  ? (event: LitUnstable.DebugLog.Entry) => {\n      const shouldEmit = (global as unknown as DebugLoggingWindow)\n        .emitLitDebugLogEvents;\n      if (!shouldEmit) {\n        return;\n      }\n      global.dispatchEvent(\n        new CustomEvent<LitUnstable.DebugLog.Entry>('lit-debug', {\n          detail: event,\n        })\n      );\n    }\n  : undefined;\n// Used for connecting beginRender and endRender events when there are nested\n// renders when errors are thrown preventing an endRender event from being\n// called.\nlet debugLogRenderId = 0;\n\nlet issueWarning: (code: string, warning: string) => void;\n\nif (DEV_MODE) {\n  global.litIssuedWarnings ??= new Set();\n\n  // Issue a warning, if we haven't already.\n  issueWarning = (code: string, warning: string) => {\n    warning += code\n      ? ` See https://lit.dev/msg/${code} for more information.`\n      : '';\n    if (!global.litIssuedWarnings!.has(warning)) {\n      console.warn(warning);\n      global.litIssuedWarnings!.add(warning);\n    }\n  };\n\n  issueWarning(\n    'dev-mode',\n    `Lit is in dev mode. Not recommended for production!`\n  );\n}\n\nconst wrap =\n  ENABLE_SHADYDOM_NOPATCH &&\n  global.ShadyDOM?.inUse &&\n  global.ShadyDOM?.noPatch === true\n    ? global.ShadyDOM!.wrap\n    : (node: Node) => node;\n\nconst trustedTypes = (global as unknown as Partial<Window>).trustedTypes;\n\n/**\n * Our TrustedTypePolicy for HTML which is declared using the html template\n * tag function.\n *\n * That HTML is a developer-authored constant, and is parsed with innerHTML\n * before any untrusted expressions have been mixed in. Therefor it is\n * considered safe by construction.\n */\nconst policy = trustedTypes\n  ? trustedTypes.createPolicy('lit-html', {\n      createHTML: (s) => s,\n    })\n  : undefined;\n\n/**\n * Used to sanitize any value before it is written into the DOM. This can be\n * used to implement a security policy of allowed and disallowed values in\n * order to prevent XSS attacks.\n *\n * One way of using this callback would be to check attributes and properties\n * against a list of high risk fields, and require that values written to such\n * fields be instances of a class which is safe by construction. Closure's Safe\n * HTML Types is one implementation of this technique (\n * https://github.com/google/safe-html-types/blob/master/doc/safehtml-types.md).\n * The TrustedTypes polyfill in API-only mode could also be used as a basis\n * for this technique (https://github.com/WICG/trusted-types).\n *\n * @param node The HTML node (usually either a #text node or an Element) that\n *     is being written to. Note that this is just an exemplar node, the write\n *     may take place against another instance of the same class of node.\n * @param name The name of an attribute or property (for example, 'href').\n * @param type Indicates whether the write that's about to be performed will\n *     be to a property or a node.\n * @return A function that will sanitize this class of writes.\n */\nexport type SanitizerFactory = (\n  node: Node,\n  name: string,\n  type: 'property' | 'attribute'\n) => ValueSanitizer;\n\n/**\n * A function which can sanitize values that will be written to a specific kind\n * of DOM sink.\n *\n * See SanitizerFactory.\n *\n * @param value The value to sanitize. Will be the actual value passed into\n *     the lit-html template literal, so this could be of any type.\n * @return The value to write to the DOM. Usually the same as the input value,\n *     unless sanitization is needed.\n */\nexport type ValueSanitizer = (value: unknown) => unknown;\n\nconst identityFunction: ValueSanitizer = (value: unknown) => value;\nconst noopSanitizer: SanitizerFactory = (\n  _node: Node,\n  _name: string,\n  _type: 'property' | 'attribute'\n) => identityFunction;\n\n/** Sets the global sanitizer factory. */\nconst setSanitizer = (newSanitizer: SanitizerFactory) => {\n  if (!ENABLE_EXTRA_SECURITY_HOOKS) {\n    return;\n  }\n  if (sanitizerFactoryInternal !== noopSanitizer) {\n    throw new Error(\n      `Attempted to overwrite existing lit-html security policy.` +\n        ` setSanitizeDOMValueFactory should be called at most once.`\n    );\n  }\n  sanitizerFactoryInternal = newSanitizer;\n};\n\n/**\n * Only used in internal tests, not a part of the public API.\n */\nconst _testOnlyClearSanitizerFactoryDoNotCallOrElse = () => {\n  sanitizerFactoryInternal = noopSanitizer;\n};\n\nconst createSanitizer: SanitizerFactory = (node, name, type) => {\n  return sanitizerFactoryInternal(node, name, type);\n};\n\n// Added to an attribute name to mark the attribute as bound so we can find\n// it easily.\nconst boundAttributeSuffix = '$lit$';\n\n// This marker is used in many syntactic positions in HTML, so it must be\n// a valid element name and attribute name. We don't support dynamic names (yet)\n// but this at least ensures that the parse tree is closer to the template\n// intention.\nconst marker = `lit$${String(Math.random()).slice(9)}$`;\n\n// String used to tell if a comment is a marker comment\nconst markerMatch = '?' + marker;\n\n// Text used to insert a comment marker node. We use processing instruction\n// syntax because it's slightly smaller, but parses as a comment node.\nconst nodeMarker = `<${markerMatch}>`;\n\nconst d =\n  NODE_MODE && global.document === undefined\n    ? ({\n        createTreeWalker() {\n          return {};\n        },\n      } as unknown as Document)\n    : document;\n\n// Creates a dynamic marker. We never have to search for these in the DOM.\nconst createMarker = (v = '') => d.createComment(v);\n\n// https://tc39.github.io/ecma262/#sec-typeof-operator\ntype Primitive = null | undefined | boolean | number | string | symbol | bigint;\nconst isPrimitive = (value: unknown): value is Primitive =>\n  value === null || (typeof value != 'object' && typeof value != 'function');\nconst isArray = Array.isArray;\nconst isIterable = (value: unknown): value is Iterable<unknown> =>\n  isArray(value) ||\n  // eslint-disable-next-line @typescript-eslint/no-explicit-any\n  typeof (value as any)?.[Symbol.iterator] === 'function';\n\nconst SPACE_CHAR = `[ \\t\\n\\f\\r]`;\nconst ATTR_VALUE_CHAR = `[^ \\t\\n\\f\\r\"'\\`<>=]`;\nconst NAME_CHAR = `[^\\\\s\"'>=/]`;\n\n// These regexes represent the five parsing states that we care about in the\n// Template's HTML scanner. They match the *end* of the state they're named\n// after.\n// Depending on the match, we transition to a new state. If there's no match,\n// we stay in the same state.\n// Note that the regexes are stateful. We utilize lastIndex and sync it\n// across the multiple regexes used. In addition to the five regexes below\n// we also dynamically create a regex to find the matching end tags for raw\n// text elements.\n\n/**\n * End of text is: `<` followed by:\n *   (comment start) or (tag) or (dynamic tag binding)\n */\nconst textEndRegex = /<(?:(!--|\\/[^a-zA-Z])|(\\/?[a-zA-Z][^>\\s]*)|(\\/?$))/g;\nconst COMMENT_START = 1;\nconst TAG_NAME = 2;\nconst DYNAMIC_TAG_NAME = 3;\n\nconst commentEndRegex = /-->/g;\n/**\n * Comments not started with <!--, like </{, can be ended by a single `>`\n */\nconst comment2EndRegex = />/g;\n\n/**\n * The tagEnd regex matches the end of the \"inside an opening\" tag syntax\n * position. It either matches a `>`, an attribute-like sequence, or the end\n * of the string after a space (attribute-name position ending).\n *\n * See attributes in the HTML spec:\n * https://www.w3.org/TR/html5/syntax.html#elements-attributes\n *\n * \" \\t\\n\\f\\r\" are HTML space characters:\n * https://infra.spec.whatwg.org/#ascii-whitespace\n *\n * So an attribute is:\n *  * The name: any character except a whitespace character, (\"), ('), \">\",\n *    \"=\", or \"/\". Note: this is different from the HTML spec which also excludes control characters.\n *  * Followed by zero or more space characters\n *  * Followed by \"=\"\n *  * Followed by zero or more space characters\n *  * Followed by:\n *    * Any character except space, ('), (\"), \"<\", \">\", \"=\", (`), or\n *    * (\") then any non-(\"), or\n *    * (') then any non-(')\n */\nconst tagEndRegex = new RegExp(\n  `>|${SPACE_CHAR}(?:(${NAME_CHAR}+)(${SPACE_CHAR}*=${SPACE_CHAR}*(?:${ATTR_VALUE_CHAR}|(\"|')|))|$)`,\n  'g'\n);\nconst ENTIRE_MATCH = 0;\nconst ATTRIBUTE_NAME = 1;\nconst SPACES_AND_EQUALS = 2;\nconst QUOTE_CHAR = 3;\n\nconst singleQuoteAttrEndRegex = /'/g;\nconst doubleQuoteAttrEndRegex = /\"/g;\n/**\n * Matches the raw text elements.\n *\n * Comments are not parsed within raw text elements, so we need to search their\n * text content for marker strings.\n */\nconst rawTextElement = /^(?:script|style|textarea|title)$/i;\n\n/** TemplateResult types */\nconst HTML_RESULT = 1;\nconst SVG_RESULT = 2;\n\ntype ResultType = typeof HTML_RESULT | typeof SVG_RESULT;\n\n// TemplatePart types\n// IMPORTANT: these must match the values in PartType\nconst ATTRIBUTE_PART = 1;\nconst CHILD_PART = 2;\nconst PROPERTY_PART = 3;\nconst BOOLEAN_ATTRIBUTE_PART = 4;\nconst EVENT_PART = 5;\nconst ELEMENT_PART = 6;\nconst COMMENT_PART = 7;\n\n/**\n * The return type of the template tag functions, {@linkcode html} and\n * {@linkcode svg}.\n *\n * A `TemplateResult` object holds all the information about a template\n * expression required to render it: the template strings, expression values,\n * and type of template (html or svg).\n *\n * `TemplateResult` objects do not create any DOM on their own. To create or\n * update DOM you need to render the `TemplateResult`. See\n * [Rendering](https://lit.dev/docs/components/rendering) for more information.\n *\n */\nexport type TemplateResult<T extends ResultType = ResultType> = {\n  // This property needs to remain unminified.\n  ['_$litType$']: T;\n  strings: TemplateStringsArray;\n  values: unknown[];\n};\n\nexport type HTMLTemplateResult = TemplateResult<typeof HTML_RESULT>;\n\nexport type SVGTemplateResult = TemplateResult<typeof SVG_RESULT>;\n\nexport interface CompiledTemplateResult {\n  // This is a factory in order to make template initialization lazy\n  // and allow ShadyRenderOptions scope to be passed in.\n  // This property needs to remain unminified.\n  ['_$litType$']: CompiledTemplate;\n  values: unknown[];\n}\n\nexport interface CompiledTemplate extends Omit<Template, 'el'> {\n  // el is overridden to be optional. We initialize it on first render\n  el?: HTMLTemplateElement;\n\n  // The prepared HTML string to create a template element from.\n  h: TrustedHTML;\n}\n\n/**\n * Generates a template literal tag function that returns a TemplateResult with\n * the given result type.\n */\nconst tag =\n  <T extends ResultType>(type: T) =>\n  (strings: TemplateStringsArray, ...values: unknown[]): TemplateResult<T> => {\n    // Warn against templates octal escape sequences\n    // We do this here rather than in render so that the warning is closer to the\n    // template definition.\n    if (DEV_MODE && strings.some((s) => s === undefined)) {\n      console.warn(\n        'Some template strings are undefined.\\n' +\n          'This is probably caused by illegal octal escape sequences.'\n      );\n    }\n    return {\n      // This property needs to remain unminified.\n      ['_$litType$']: type,\n      strings,\n      values,\n    };\n  };\n\n/**\n * Interprets a template literal as an HTML template that can efficiently\n * render to and update a container.\n *\n * ```ts\n * const header = (title: string) => html`<h1>${title}</h1>`;\n * ```\n *\n * The `html` tag returns a description of the DOM to render as a value. It is\n * lazy, meaning no work is done until the template is rendered. When rendering,\n * if a template comes from the same expression as a previously rendered result,\n * it's efficiently updated instead of replaced.\n */\nexport const html = tag(HTML_RESULT);\n\n/**\n * Interprets a template literal as an SVG fragment that can efficiently\n * render to and update a container.\n *\n * ```ts\n * const rect = svg`<rect width=\"10\" height=\"10\"></rect>`;\n *\n * const myImage = html`\n *   <svg viewBox=\"0 0 10 10\" xmlns=\"http://www.w3.org/2000/svg\">\n *     ${rect}\n *   </svg>`;\n * ```\n *\n * The `svg` *tag function* should only be used for SVG fragments, or elements\n * that would be contained **inside** an `<svg>` HTML element. A common error is\n * placing an `<svg>` *element* in a template tagged with the `svg` tag\n * function. The `<svg>` element is an HTML element and should be used within a\n * template tagged with the {@linkcode html} tag function.\n *\n * In LitElement usage, it's invalid to return an SVG fragment from the\n * `render()` method, as the SVG fragment will be contained within the element's\n * shadow root and thus cannot be used within an `<svg>` HTML element.\n */\nexport const svg = tag(SVG_RESULT);\n\n/**\n * A sentinel value that signals that a value was handled by a directive and\n * should not be written to the DOM.\n */\nexport const noChange = Symbol.for('lit-noChange');\n\n/**\n * A sentinel value that signals a ChildPart to fully clear its content.\n *\n * ```ts\n * const button = html`${\n *  user.isAdmin\n *    ? html`<button>DELETE</button>`\n *    : nothing\n * }`;\n * ```\n *\n * Prefer using `nothing` over other falsy values as it provides a consistent\n * behavior between various expression binding contexts.\n *\n * In child expressions, `undefined`, `null`, `''`, and `nothing` all behave the\n * same and render no nodes. In attribute expressions, `nothing` _removes_ the\n * attribute, while `undefined` and `null` will render an empty string. In\n * property expressions `nothing` becomes `undefined`.\n */\nexport const nothing = Symbol.for('lit-nothing');\n\n/**\n * The cache of prepared templates, keyed by the tagged TemplateStringsArray\n * and _not_ accounting for the specific template tag used. This means that\n * template tags cannot be dynamic - the must statically be one of html, svg,\n * or attr. This restriction simplifies the cache lookup, which is on the hot\n * path for rendering.\n */\nconst templateCache = new WeakMap<TemplateStringsArray, Template>();\n\n/**\n * Object specifying options for controlling lit-html rendering. Note that\n * while `render` may be called multiple times on the same `container` (and\n * `renderBefore` reference node) to efficiently update the rendered content,\n * only the options passed in during the first render are respected during\n * the lifetime of renders to that unique `container` + `renderBefore`\n * combination.\n */\nexport interface RenderOptions {\n  /**\n   * An object to use as the `this` value for event listeners. It's often\n   * useful to set this to the host component rendering a template.\n   */\n  host?: object;\n  /**\n   * A DOM node before which to render content in the container.\n   */\n  renderBefore?: ChildNode | null;\n  /**\n   * Node used for cloning the template (`importNode` will be called on this\n   * node). This controls the `ownerDocument` of the rendered DOM, along with\n   * any inherited context. Defaults to the global `document`.\n   */\n  creationScope?: {importNode(node: Node, deep?: boolean): Node};\n  /**\n   * The initial connected state for the top-level part being rendered. If no\n   * `isConnected` option is set, `AsyncDirective`s will be connected by\n   * default. Set to `false` if the initial render occurs in a disconnected tree\n   * and `AsyncDirective`s should see `isConnected === false` for their initial\n   * render. The `part.setConnected()` method must be used subsequent to initial\n   * render to change the connected state of the part.\n   */\n  isConnected?: boolean;\n}\n\nconst walker = d.createTreeWalker(\n  d,\n  129 /* NodeFilter.SHOW_{ELEMENT|COMMENT} */,\n  null,\n  false\n);\n\nlet sanitizerFactoryInternal: SanitizerFactory = noopSanitizer;\n\n//\n// Classes only below here, const variable declarations only above here...\n//\n// Keeping variable declarations and classes together improves minification.\n// Interfaces and type aliases can be interleaved freely.\n//\n\n// Type for classes that have a `_directive` or `_directives[]` field, used by\n// `resolveDirective`\nexport interface DirectiveParent {\n  _$parent?: DirectiveParent;\n  _$isConnected: boolean;\n  __directive?: Directive;\n  __directives?: Array<Directive | undefined>;\n}\n\n/**\n * Returns an HTML string for the given TemplateStringsArray and result type\n * (HTML or SVG), along with the case-sensitive bound attribute names in\n * template order. The HTML contains comment markers denoting the `ChildPart`s\n * and suffixes on bound attributes denoting the `AttributeParts`.\n *\n * @param strings template strings array\n * @param type HTML or SVG\n * @return Array containing `[html, attrNames]` (array returned for terseness,\n *     to avoid object fields since this code is shared with non-minified SSR\n *     code)\n */\nconst getTemplateHtml = (\n  strings: TemplateStringsArray,\n  type: ResultType\n): [TrustedHTML, Array<string | undefined>] => {\n  // Insert makers into the template HTML to represent the position of\n  // bindings. The following code scans the template strings to determine the\n  // syntactic position of the bindings. They can be in text position, where\n  // we insert an HTML comment, attribute value position, where we insert a\n  // sentinel string and re-write the attribute name, or inside a tag where\n  // we insert the sentinel string.\n  const l = strings.length - 1;\n  // Stores the case-sensitive bound attribute names in the order of their\n  // parts. ElementParts are also reflected in this array as undefined\n  // rather than a string, to disambiguate from attribute bindings.\n  const attrNames: Array<string | undefined> = [];\n  let html = type === SVG_RESULT ? '<svg>' : '';\n\n  // When we're inside a raw text tag (not it's text content), the regex\n  // will still be tagRegex so we can find attributes, but will switch to\n  // this regex when the tag ends.\n  let rawTextEndRegex: RegExp | undefined;\n\n  // The current parsing state, represented as a reference to one of the\n  // regexes\n  let regex = textEndRegex;\n\n  for (let i = 0; i < l; i++) {\n    const s = strings[i];\n    // The index of the end of the last attribute name. When this is\n    // positive at end of a string, it means we're in an attribute value\n    // position and need to rewrite the attribute name.\n    // We also use a special value of -2 to indicate that we encountered\n    // the end of a string in attribute name position.\n    let attrNameEndIndex = -1;\n    let attrName: string | undefined;\n    let lastIndex = 0;\n    let match!: RegExpExecArray | null;\n\n    // The conditions in this loop handle the current parse state, and the\n    // assignments to the `regex` variable are the state transitions.\n    while (lastIndex < s.length) {\n      // Make sure we start searching from where we previously left off\n      regex.lastIndex = lastIndex;\n      match = regex.exec(s);\n      if (match === null) {\n        break;\n      }\n      lastIndex = regex.lastIndex;\n      if (regex === textEndRegex) {\n        if (match[COMMENT_START] === '!--') {\n          regex = commentEndRegex;\n        } else if (match[COMMENT_START] !== undefined) {\n          // We started a weird comment, like </{\n          regex = comment2EndRegex;\n        } else if (match[TAG_NAME] !== undefined) {\n          if (rawTextElement.test(match[TAG_NAME])) {\n            // Record if we encounter a raw-text element. We'll switch to\n            // this regex at the end of the tag.\n            rawTextEndRegex = new RegExp(`</${match[TAG_NAME]}`, 'g');\n          }\n          regex = tagEndRegex;\n        } else if (match[DYNAMIC_TAG_NAME] !== undefined) {\n          if (DEV_MODE) {\n            throw new Error(\n              'Bindings in tag names are not supported. Please use static templates instead. ' +\n                'See https://lit.dev/docs/templates/expressions/#static-expressions'\n            );\n          }\n          regex = tagEndRegex;\n        }\n      } else if (regex === tagEndRegex) {\n        if (match[ENTIRE_MATCH] === '>') {\n          // End of a tag. If we had started a raw-text element, use that\n          // regex\n          regex = rawTextEndRegex ?? textEndRegex;\n          // We may be ending an unquoted attribute value, so make sure we\n          // clear any pending attrNameEndIndex\n          attrNameEndIndex = -1;\n        } else if (match[ATTRIBUTE_NAME] === undefined) {\n          // Attribute name position\n          attrNameEndIndex = -2;\n        } else {\n          attrNameEndIndex = regex.lastIndex - match[SPACES_AND_EQUALS].length;\n          attrName = match[ATTRIBUTE_NAME];\n          regex =\n            match[QUOTE_CHAR] === undefined\n              ? tagEndRegex\n              : match[QUOTE_CHAR] === '\"'\n              ? doubleQuoteAttrEndRegex\n              : singleQuoteAttrEndRegex;\n        }\n      } else if (\n        regex === doubleQuoteAttrEndRegex ||\n        regex === singleQuoteAttrEndRegex\n      ) {\n        regex = tagEndRegex;\n      } else if (regex === commentEndRegex || regex === comment2EndRegex) {\n        regex = textEndRegex;\n      } else {\n        // Not one of the five state regexes, so it must be the dynamically\n        // created raw text regex and we're at the close of that element.\n        regex = tagEndRegex;\n        rawTextEndRegex = undefined;\n      }\n    }\n\n    if (DEV_MODE) {\n      // If we have a attrNameEndIndex, which indicates that we should\n      // rewrite the attribute name, assert that we're in a valid attribute\n      // position - either in a tag, or a quoted attribute value.\n      console.assert(\n        attrNameEndIndex === -1 ||\n          regex === tagEndRegex ||\n          regex === singleQuoteAttrEndRegex ||\n          regex === doubleQuoteAttrEndRegex,\n        'unexpected parse state B'\n      );\n    }\n\n    // We have four cases:\n    //  1. We're in text position, and not in a raw text element\n    //     (regex === textEndRegex): insert a comment marker.\n    //  2. We have a non-negative attrNameEndIndex which means we need to\n    //     rewrite the attribute name to add a bound attribute suffix.\n    //  3. We're at the non-first binding in a multi-binding attribute, use a\n    //     plain marker.\n    //  4. We're somewhere else inside the tag. If we're in attribute name\n    //     position (attrNameEndIndex === -2), add a sequential suffix to\n    //     generate a unique attribute name.\n\n    // Detect a binding next to self-closing tag end and insert a space to\n    // separate the marker from the tag end:\n    const end =\n      regex === tagEndRegex && strings[i + 1].startsWith('/>') ? ' ' : '';\n    html +=\n      regex === textEndRegex\n        ? s + nodeMarker\n        : attrNameEndIndex >= 0\n        ? (attrNames.push(attrName!),\n          s.slice(0, attrNameEndIndex) +\n            boundAttributeSuffix +\n            s.slice(attrNameEndIndex)) +\n          marker +\n          end\n        : s +\n          marker +\n          (attrNameEndIndex === -2 ? (attrNames.push(undefined), i) : end);\n  }\n\n  const htmlResult: string | TrustedHTML =\n    html + (strings[l] || '<?>') + (type === SVG_RESULT ? '</svg>' : '');\n\n  // A security check to prevent spoofing of Lit template results.\n  // In the future, we may be able to replace this with Array.isTemplateObject,\n  // though we might need to make that check inside of the html and svg\n  // functions, because precompiled templates don't come in as\n  // TemplateStringArray objects.\n  if (!Array.isArray(strings) || !strings.hasOwnProperty('raw')) {\n    let message = 'invalid template strings array';\n    if (DEV_MODE) {\n      message = `\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\n          If you're using the html or svg tagged template functions normally\n          and 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        `\n        .trim()\n        .replace(/\\n */g, '\\n');\n    }\n    throw new Error(message);\n  }\n  // Returned as an array for terseness\n  return [\n    policy !== undefined\n      ? policy.createHTML(htmlResult)\n      : (htmlResult as unknown as TrustedHTML),\n    attrNames,\n  ];\n};\n\n/** @internal */\nexport type {Template};\nclass Template {\n  /** @internal */\n  el!: HTMLTemplateElement;\n  /** @internal */\n  parts: Array<TemplatePart> = [];\n\n  constructor(\n    // This property needs to remain unminified.\n    {strings, ['_$litType$']: type}: TemplateResult,\n    options?: RenderOptions\n  ) {\n    let node: Node | null;\n    let nodeIndex = 0;\n    let attrNameIndex = 0;\n    const partCount = strings.length - 1;\n    const parts = this.parts;\n\n    // Create template element\n    const [html, attrNames] = getTemplateHtml(strings, type);\n    this.el = Template.createElement(html, options);\n    walker.currentNode = this.el.content;\n\n    // Reparent SVG nodes into template root\n    if (type === SVG_RESULT) {\n      const content = this.el.content;\n      const svgElement = content.firstChild!;\n      svgElement.remove();\n      content.append(...svgElement.childNodes);\n    }\n\n    // Walk the template to find binding markers and create TemplateParts\n    while ((node = walker.nextNode()) !== null && parts.length < partCount) {\n      if (node.nodeType === 1) {\n        if (DEV_MODE) {\n          const tag = (node as Element).localName;\n          // Warn if `textarea` includes an expression and throw if `template`\n          // does since these are not supported. We do this by checking\n          // innerHTML for anything that looks like a marker. This catches\n          // cases like bindings in textarea there markers turn into text nodes.\n          if (\n            /^(?:textarea|template)$/i!.test(tag) &&\n            (node as Element).innerHTML.includes(marker)\n          ) {\n            const m =\n              `Expressions are not supported inside \\`${tag}\\` ` +\n              `elements. See https://lit.dev/msg/expression-in-${tag} for more ` +\n              `information.`;\n            if (tag === 'template') {\n              throw new Error(m);\n            } else issueWarning('', m);\n          }\n        }\n        // TODO (justinfagnani): for attempted dynamic tag names, we don't\n        // increment the bindingIndex, and it'll be off by 1 in the element\n        // and off by two after it.\n        if ((node as Element).hasAttributes()) {\n          // We defer removing bound attributes because on IE we might not be\n          // iterating attributes in their template order, and would sometimes\n          // remove an attribute that we still need to create a part for.\n          const attrsToRemove = [];\n          for (const name of (node as Element).getAttributeNames()) {\n            // `name` is the name of the attribute we're iterating over, but not\n            // _neccessarily_ the name of the attribute we will create a part\n            // for. They can be different in browsers that don't iterate on\n            // attributes in source order. In that case the attrNames array\n            // contains the attribute name we'll process next. We only need the\n            // attribute name here to know if we should process a bound attribute\n            // on this element.\n            if (\n              name.endsWith(boundAttributeSuffix) ||\n              name.startsWith(marker)\n            ) {\n              const realName = attrNames[attrNameIndex++];\n              attrsToRemove.push(name);\n              if (realName !== undefined) {\n                // Lowercase for case-sensitive SVG attributes like viewBox\n                const value = (node as Element).getAttribute(\n                  realName.toLowerCase() + boundAttributeSuffix\n                )!;\n                const statics = value.split(marker);\n                const m = /([.?@])?(.*)/.exec(realName)!;\n                parts.push({\n                  type: ATTRIBUTE_PART,\n                  index: nodeIndex,\n                  name: m[2],\n                  strings: statics,\n                  ctor:\n                    m[1] === '.'\n                      ? PropertyPart\n                      : m[1] === '?'\n                      ? BooleanAttributePart\n                      : m[1] === '@'\n                      ? EventPart\n                      : AttributePart,\n                });\n              } else {\n                parts.push({\n                  type: ELEMENT_PART,\n                  index: nodeIndex,\n                });\n              }\n            }\n          }\n          for (const name of attrsToRemove) {\n            (node as Element).removeAttribute(name);\n          }\n        }\n        // TODO (justinfagnani): benchmark the regex against testing for each\n        // of the 3 raw text element names.\n        if (rawTextElement.test((node as Element).tagName)) {\n          // For raw text elements we need to split the text content on\n          // markers, create a Text node for each segment, and create\n          // a TemplatePart for each marker.\n          const strings = (node as Element).textContent!.split(marker);\n          const lastIndex = strings.length - 1;\n          if (lastIndex > 0) {\n            (node as Element).textContent = trustedTypes\n              ? (trustedTypes.emptyScript as unknown as '')\n              : '';\n            // Generate a new text node for each literal section\n            // These nodes are also used as the markers for node parts\n            // We can't use empty text nodes as markers because they're\n            // normalized when cloning in IE (could simplify when\n            // IE is no longer supported)\n            for (let i = 0; i < lastIndex; i++) {\n              (node as Element).append(strings[i], createMarker());\n              // Walk past the marker node we just added\n              walker.nextNode();\n              parts.push({type: CHILD_PART, index: ++nodeIndex});\n            }\n            // Note because this marker is added after the walker's current\n            // node, it will be walked to in the outer loop (and ignored), so\n            // we don't need to adjust nodeIndex here\n            (node as Element).append(strings[lastIndex], createMarker());\n          }\n        }\n      } else if (node.nodeType === 8) {\n        const data = (node as Comment).data;\n        if (data === markerMatch) {\n          parts.push({type: CHILD_PART, index: nodeIndex});\n        } else {\n          let i = -1;\n          while ((i = (node as Comment).data.indexOf(marker, i + 1)) !== -1) {\n            // Comment node has a binding marker inside, make an inactive part\n            // The binding won't work, but subsequent bindings will\n            parts.push({type: COMMENT_PART, index: nodeIndex});\n            // Move to the end of the match\n            i += marker.length - 1;\n          }\n        }\n      }\n      nodeIndex++;\n    }\n    debugLogEvent?.({\n      kind: 'template prep',\n      template: this,\n      clonableTemplate: this.el,\n      parts: this.parts,\n      strings,\n    });\n  }\n\n  // Overridden via `litHtmlPolyfillSupport` to provide platform support.\n  /** @nocollapse */\n  static createElement(html: TrustedHTML, _options?: RenderOptions) {\n    const el = d.createElement('template');\n    el.innerHTML = html as unknown as string;\n    return el;\n  }\n}\n\nexport interface Disconnectable {\n  _$parent?: Disconnectable;\n  _$disconnectableChildren?: Set<Disconnectable>;\n  // Rather than hold connection state on instances, Disconnectables recursively\n  // fetch the connection state from the RootPart they are connected in via\n  // getters up the Disconnectable tree via _$parent references. This pushes the\n  // cost of tracking the isConnected state to `AsyncDirectives`, and avoids\n  // needing to pass all Disconnectables (parts, template instances, and\n  // directives) their connection state each time it changes, which would be\n  // costly for trees that have no AsyncDirectives.\n  _$isConnected: boolean;\n}\n\nfunction resolveDirective(\n  part: ChildPart | AttributePart | ElementPart,\n  value: unknown,\n  parent: DirectiveParent = part,\n  attributeIndex?: number\n): unknown {\n  // Bail early if the value is explicitly noChange. Note, this means any\n  // nested directive is still attached and is not run.\n  if (value === noChange) {\n    return value;\n  }\n  let currentDirective =\n    attributeIndex !== undefined\n      ? (parent as AttributePart).__directives?.[attributeIndex]\n      : (parent as ChildPart | ElementPart | Directive).__directive;\n  const nextDirectiveConstructor = isPrimitive(value)\n    ? undefined\n    : // This property needs to remain unminified.\n      (value as DirectiveResult)['_$litDirective$'];\n  if (currentDirective?.constructor !== nextDirectiveConstructor) {\n    // This property needs to remain unminified.\n    currentDirective?.['_$notifyDirectiveConnectionChanged']?.(false);\n    if (nextDirectiveConstructor === undefined) {\n      currentDirective = undefined;\n    } else {\n      currentDirective = new nextDirectiveConstructor(part as PartInfo);\n      currentDirective._$initialize(part, parent, attributeIndex);\n    }\n    if (attributeIndex !== undefined) {\n      ((parent as AttributePart).__directives ??= [])[attributeIndex] =\n        currentDirective;\n    } else {\n      (parent as ChildPart | Directive).__directive = currentDirective;\n    }\n  }\n  if (currentDirective !== undefined) {\n    value = resolveDirective(\n      part,\n      currentDirective._$resolve(part, (value as DirectiveResult).values),\n      currentDirective,\n      attributeIndex\n    );\n  }\n  return value;\n}\n\n/**\n * An updateable instance of a Template. Holds references to the Parts used to\n * update the template instance.\n */\nclass TemplateInstance implements Disconnectable {\n  /** @internal */\n  _$template: Template;\n  /** @internal */\n  _parts: Array<Part | undefined> = [];\n\n  /** @internal */\n  _$parent: ChildPart;\n  /** @internal */\n  _$disconnectableChildren?: Set<Disconnectable> = undefined;\n\n  constructor(template: Template, parent: ChildPart) {\n    this._$template = template;\n    this._$parent = parent;\n  }\n\n  // Called by ChildPart parentNode getter\n  get parentNode() {\n    return this._$parent.parentNode;\n  }\n\n  // See comment in Disconnectable interface for why this is a getter\n  get _$isConnected() {\n    return this._$parent._$isConnected;\n  }\n\n  // This method is separate from the constructor because we need to return a\n  // DocumentFragment and we don't want to hold onto it with an instance field.\n  _clone(options: RenderOptions | undefined) {\n    const {\n      el: {content},\n      parts: parts,\n    } = this._$template;\n    const fragment = (options?.creationScope ?? d).importNode(content, true);\n    walker.currentNode = fragment;\n\n    let node = walker.nextNode()!;\n    let nodeIndex = 0;\n    let partIndex = 0;\n    let templatePart = parts[0];\n\n    while (templatePart !== undefined) {\n      if (nodeIndex === templatePart.index) {\n        let part: Part | undefined;\n        if (templatePart.type === CHILD_PART) {\n          part = new ChildPart(\n            node as HTMLElement,\n            node.nextSibling,\n            this,\n            options\n          );\n        } else if (templatePart.type === ATTRIBUTE_PART) {\n          part = new templatePart.ctor(\n            node as HTMLElement,\n            templatePart.name,\n            templatePart.strings,\n            this,\n            options\n          );\n        } else if (templatePart.type === ELEMENT_PART) {\n          part = new ElementPart(node as HTMLElement, this, options);\n        }\n        this._parts.push(part);\n        templatePart = parts[++partIndex];\n      }\n      if (nodeIndex !== templatePart?.index) {\n        node = walker.nextNode()!;\n        nodeIndex++;\n      }\n    }\n    return fragment;\n  }\n\n  _update(values: Array<unknown>) {\n    let i = 0;\n    for (const part of this._parts) {\n      if (part !== undefined) {\n        debugLogEvent?.({\n          kind: 'set part',\n          part,\n          value: values[i],\n          valueIndex: i,\n          values,\n          templateInstance: this,\n        });\n        if ((part as AttributePart).strings !== undefined) {\n          (part as AttributePart)._$setValue(values, part as AttributePart, i);\n          // The number of values the part consumes is part.strings.length - 1\n          // since values are in between template spans. We increment i by 1\n          // later in the loop, so increment it by part.strings.length - 2 here\n          i += (part as AttributePart).strings!.length - 2;\n        } else {\n          part._$setValue(values[i]);\n        }\n      }\n      i++;\n    }\n  }\n}\n\n/*\n * Parts\n */\ntype AttributeTemplatePart = {\n  readonly type: typeof ATTRIBUTE_PART;\n  readonly index: number;\n  readonly name: string;\n  /** @internal */\n  readonly ctor: typeof AttributePart;\n  /** @internal */\n  readonly strings: ReadonlyArray<string>;\n};\ntype NodeTemplatePart = {\n  readonly type: typeof CHILD_PART;\n  readonly index: number;\n};\ntype ElementTemplatePart = {\n  readonly type: typeof ELEMENT_PART;\n  readonly index: number;\n};\ntype CommentTemplatePart = {\n  readonly type: typeof COMMENT_PART;\n  readonly index: number;\n};\n\n/**\n * A TemplatePart represents a dynamic part in a template, before the template\n * is instantiated. When a template is instantiated Parts are created from\n * TemplateParts.\n */\ntype TemplatePart =\n  | NodeTemplatePart\n  | AttributeTemplatePart\n  | ElementTemplatePart\n  | CommentTemplatePart;\n\nexport type Part =\n  | ChildPart\n  | AttributePart\n  | PropertyPart\n  | BooleanAttributePart\n  | ElementPart\n  | EventPart;\n\nexport type {ChildPart};\nclass ChildPart implements Disconnectable {\n  readonly type = CHILD_PART;\n  readonly options: RenderOptions | undefined;\n  _$committedValue: unknown = nothing;\n  /** @internal */\n  __directive?: Directive;\n  /** @internal */\n  _$startNode: ChildNode;\n  /** @internal */\n  _$endNode: ChildNode | null;\n  private _textSanitizer: ValueSanitizer | undefined;\n  /** @internal */\n  _$parent: Disconnectable | undefined;\n  /**\n   * Connection state for RootParts only (i.e. ChildPart without _$parent\n   * returned from top-level `render`). This field is unsed otherwise. The\n   * intention would clearer if we made `RootPart` a subclass of `ChildPart`\n   * with this field (and a different _$isConnected getter), but the subclass\n   * caused a perf regression, possibly due to making call sites polymorphic.\n   * @internal\n   */\n  __isConnected: boolean;\n\n  // See comment in Disconnectable interface for why this is a getter\n  get _$isConnected() {\n    // ChildParts that are not at the root should always be created with a\n    // parent; only RootChildNode's won't, so they return the local isConnected\n    // state\n    return this._$parent?._$isConnected ?? this.__isConnected;\n  }\n\n  // The following fields will be patched onto ChildParts when required by\n  // AsyncDirective\n  /** @internal */\n  _$disconnectableChildren?: Set<Disconnectable> = undefined;\n  /** @internal */\n  _$notifyConnectionChanged?(\n    isConnected: boolean,\n    removeFromParent?: boolean,\n    from?: number\n  ): void;\n  /** @internal */\n  _$reparentDisconnectables?(parent: Disconnectable): void;\n\n  constructor(\n    startNode: ChildNode,\n    endNode: ChildNode | null,\n    parent: TemplateInstance | ChildPart | undefined,\n    options: RenderOptions | undefined\n  ) {\n    this._$startNode = startNode;\n    this._$endNode = endNode;\n    this._$parent = parent;\n    this.options = options;\n    // Note __isConnected is only ever accessed on RootParts (i.e. when there is\n    // no _$parent); the value on a non-root-part is \"don't care\", but checking\n    // for parent would be more code\n    this.__isConnected = options?.isConnected ?? true;\n    if (ENABLE_EXTRA_SECURITY_HOOKS) {\n      // Explicitly initialize for consistent class shape.\n      this._textSanitizer = undefined;\n    }\n  }\n\n  /**\n   * The parent node into which the part renders its content.\n   *\n   * A ChildPart's content consists of a range of adjacent child nodes of\n   * `.parentNode`, possibly bordered by 'marker nodes' (`.startNode` and\n   * `.endNode`).\n   *\n   * - If both `.startNode` and `.endNode` are non-null, then the part's content\n   * consists of all siblings between `.startNode` and `.endNode`, exclusively.\n   *\n   * - If `.startNode` is non-null but `.endNode` is null, then the part's\n   * content consists of all siblings following `.startNode`, up to and\n   * including the last child of `.parentNode`. If `.endNode` is non-null, then\n   * `.startNode` will always be non-null.\n   *\n   * - If both `.endNode` and `.startNode` are null, then the part's content\n   * consists of all child nodes of `.parentNode`.\n   */\n  get parentNode(): Node {\n    let parentNode: Node = wrap(this._$startNode).parentNode!;\n    const parent = this._$parent;\n    if (\n      parent !== undefined &&\n      parentNode.nodeType === 11 /* Node.DOCUMENT_FRAGMENT */\n    ) {\n      // If the parentNode is a DocumentFragment, it may be because the DOM is\n      // still in the cloned fragment during initial render; if so, get the real\n      // parentNode the part will be committed into by asking the parent.\n      parentNode = (parent as ChildPart | TemplateInstance).parentNode;\n    }\n    return parentNode;\n  }\n\n  /**\n   * The part's leading marker node, if any. See `.parentNode` for more\n   * information.\n   */\n  get startNode(): Node | null {\n    return this._$startNode;\n  }\n\n  /**\n   * The part's trailing marker node, if any. See `.parentNode` for more\n   * information.\n   */\n  get endNode(): Node | null {\n    return this._$endNode;\n  }\n\n  _$setValue(value: unknown, directiveParent: DirectiveParent = this): void {\n    if (DEV_MODE && this.parentNode === null) {\n      throw new Error(\n        `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.`\n      );\n    }\n    value = resolveDirective(this, value, directiveParent);\n    if (isPrimitive(value)) {\n      // Non-rendering child values. It's important that these do not render\n      // empty text nodes to avoid issues with preventing default <slot>\n      // fallback content.\n      if (value === nothing || value == null || value === '') {\n        if (this._$committedValue !== nothing) {\n          debugLogEvent?.({\n            kind: 'commit nothing to child',\n            start: this._$startNode,\n            end: this._$endNode,\n            parent: this._$parent,\n            options: this.options,\n          });\n          this._$clear();\n        }\n        this._$committedValue = nothing;\n      } else if (value !== this._$committedValue && value !== noChange) {\n        this._commitText(value);\n      }\n      // This property needs to remain unminified.\n    } else if ((value as TemplateResult)['_$litType$'] !== undefined) {\n      this._commitTemplateResult(value as TemplateResult);\n    } else if ((value as Node).nodeType !== undefined) {\n      if (DEV_MODE && this.options?.host === value) {\n        this._commitText(\n          `[probable mistake: rendered a template's host in itself ` +\n            `(commonly caused by writing \\${this} in a template]`\n        );\n        console.warn(\n          `Attempted to render the template host`,\n          value,\n          `inside itself. This is almost always a mistake, and in dev mode `,\n          `we render some warning text. In production however, we'll `,\n          `render it, which will usually result in an error, and sometimes `,\n          `in the element disappearing from the DOM.`\n        );\n        return;\n      }\n      this._commitNode(value as Node);\n    } else if (isIterable(value)) {\n      this._commitIterable(value);\n    } else {\n      // Fallback, will render the string representation\n      this._commitText(value);\n    }\n  }\n\n  private _insert<T extends Node>(node: T, ref = this._$endNode) {\n    return wrap(wrap(this._$startNode).parentNode!).insertBefore(node, ref);\n  }\n\n  private _commitNode(value: Node): void {\n    if (this._$committedValue !== value) {\n      this._$clear();\n      if (\n        ENABLE_EXTRA_SECURITY_HOOKS &&\n        sanitizerFactoryInternal !== noopSanitizer\n      ) {\n        const parentNodeName = this._$startNode.parentNode?.nodeName;\n        if (parentNodeName === 'STYLE' || parentNodeName === 'SCRIPT') {\n          let message = 'Forbidden';\n          if (DEV_MODE) {\n            if (parentNodeName === 'STYLE') {\n              message =\n                `Lit does not support binding inside style nodes. ` +\n                `This is a security risk, as style injection attacks can ` +\n                `exfiltrate data and spoof UIs. ` +\n                `Consider instead using css\\`...\\` literals ` +\n                `to compose styles, and make do dynamic styling with ` +\n                `css custom properties, ::parts, <slot>s, ` +\n                `and by mutating the DOM rather than stylesheets.`;\n            } else {\n              message =\n                `Lit does not support binding inside script nodes. ` +\n                `This is a security risk, as it could allow arbitrary ` +\n                `code execution.`;\n            }\n          }\n          throw new Error(message);\n        }\n      }\n      debugLogEvent?.({\n        kind: 'commit node',\n        start: this._$startNode,\n        parent: this._$parent,\n        value: value,\n        options: this.options,\n      });\n      this._$committedValue = this._insert(value);\n    }\n  }\n\n  private _commitText(value: unknown): void {\n    // If the committed value is a primitive it means we called _commitText on\n    // the previous render, and we know that this._$startNode.nextSibling is a\n    // Text node. We can now just replace the text content (.data) of the node.\n    if (\n      this._$committedValue !== nothing &&\n      isPrimitive(this._$committedValue)\n    ) {\n      const node = wrap(this._$startNode).nextSibling as Text;\n      if (ENABLE_EXTRA_SECURITY_HOOKS) {\n        if (this._textSanitizer === undefined) {\n          this._textSanitizer = createSanitizer(node, 'data', 'property');\n        }\n        value = this._textSanitizer(value);\n      }\n      debugLogEvent?.({\n        kind: 'commit text',\n        node,\n        value,\n        options: this.options,\n      });\n      (node as Text).data = value as string;\n    } else {\n      if (ENABLE_EXTRA_SECURITY_HOOKS) {\n        const textNode = document.createTextNode('');\n        this._commitNode(textNode);\n        // When setting text content, for security purposes it matters a lot\n        // what the parent is. For example, <style> and <script> need to be\n        // handled with care, while <span> does not. So first we need to put a\n        // text node into the document, then we can sanitize its content.\n        if (this._textSanitizer === undefined) {\n          this._textSanitizer = createSanitizer(textNode, 'data', 'property');\n        }\n        value = this._textSanitizer(value);\n        debugLogEvent?.({\n          kind: 'commit text',\n          node: textNode,\n          value,\n          options: this.options,\n        });\n        textNode.data = value as string;\n      } else {\n        this._commitNode(d.createTextNode(value as string));\n        debugLogEvent?.({\n          kind: 'commit text',\n          node: wrap(this._$startNode).nextSibling as Text,\n          value,\n          options: this.options,\n        });\n      }\n    }\n    this._$committedValue = value;\n  }\n\n  private _commitTemplateResult(\n    result: TemplateResult | CompiledTemplateResult\n  ): void {\n    // This property needs to remain unminified.\n    const {values, ['_$litType$']: type} = result;\n    // If $litType$ is a number, result is a plain TemplateResult and we get\n    // the template from the template cache. If not, result is a\n    // CompiledTemplateResult and _$litType$ is a CompiledTemplate and we need\n    // to create the <template> element the first time we see it.\n    const template: Template | CompiledTemplate =\n      typeof type === 'number'\n        ? this._$getTemplate(result as TemplateResult)\n        : (type.el === undefined &&\n            (type.el = Template.createElement(type.h, this.options)),\n          type);\n\n    if ((this._$committedValue as TemplateInstance)?._$template === template) {\n      debugLogEvent?.({\n        kind: 'template updating',\n        template,\n        instance: this._$committedValue as TemplateInstance,\n        parts: (this._$committedValue as TemplateInstance)._parts,\n        options: this.options,\n        values,\n      });\n      (this._$committedValue as TemplateInstance)._update(values);\n    } else {\n      const instance = new TemplateInstance(template as Template, this);\n      const fragment = instance._clone(this.options);\n      debugLogEvent?.({\n        kind: 'template instantiated',\n        template,\n        instance,\n        parts: instance._parts,\n        options: this.options,\n        fragment,\n        values,\n      });\n      instance._update(values);\n      debugLogEvent?.({\n        kind: 'template instantiated and updated',\n        template,\n        instance,\n        parts: instance._parts,\n        options: this.options,\n        fragment,\n        values,\n      });\n      this._commitNode(fragment);\n      this._$committedValue = instance;\n    }\n  }\n\n  // Overridden via `litHtmlPolyfillSupport` to provide platform support.\n  /** @internal */\n  _$getTemplate(result: TemplateResult) {\n    let template = templateCache.get(result.strings);\n    if (template === undefined) {\n      templateCache.set(result.strings, (template = new Template(result)));\n    }\n    return template;\n  }\n\n  private _commitIterable(value: Iterable<unknown>): void {\n    // For an Iterable, we create a new InstancePart per item, then set its\n    // value to the item. This is a little bit of overhead for every item in\n    // an Iterable, but it lets us recurse easily and efficiently update Arrays\n    // of TemplateResults that will be commonly returned from expressions like:\n    // array.map((i) => html`${i}`), by reusing existing TemplateInstances.\n\n    // If value is an array, then the previous render was of an\n    // iterable and value will contain the ChildParts from the previous\n    // render. If value is not an array, clear this part and make a new\n    // array for ChildParts.\n    if (!isArray(this._$committedValue)) {\n      this._$committedValue = [];\n      this._$clear();\n    }\n\n    // Lets us keep track of how many items we stamped so we can clear leftover\n    // items from a previous render\n    const itemParts = this._$committedValue as ChildPart[];\n    let partIndex = 0;\n    let itemPart: ChildPart | undefined;\n\n    for (const item of value) {\n      if (partIndex === itemParts.length) {\n        // If no existing part, create a new one\n        // TODO (justinfagnani): test perf impact of always creating two parts\n        // instead of sharing parts between nodes\n        // https://github.com/lit/lit/issues/1266\n        itemParts.push(\n          (itemPart = new ChildPart(\n            this._insert(createMarker()),\n            this._insert(createMarker()),\n            this,\n            this.options\n          ))\n        );\n      } else {\n        // Reuse an existing part\n        itemPart = itemParts[partIndex];\n      }\n      itemPart._$setValue(item);\n      partIndex++;\n    }\n\n    if (partIndex < itemParts.length) {\n      // itemParts always have end nodes\n      this._$clear(\n        itemPart && wrap(itemPart._$endNode!).nextSibling,\n        partIndex\n      );\n      // Truncate the parts array so _value reflects the current state\n      itemParts.length = partIndex;\n    }\n  }\n\n  /**\n   * Removes the nodes contained within this Part from the DOM.\n   *\n   * @param start Start node to clear from, for clearing a subset of the part's\n   *     DOM (used when truncating iterables)\n   * @param from  When `start` is specified, the index within the iterable from\n   *     which ChildParts are being removed, used for disconnecting directives in\n   *     those Parts.\n   *\n   * @internal\n   */\n  _$clear(\n    start: ChildNode | null = wrap(this._$startNode).nextSibling,\n    from?: number\n  ) {\n    this._$notifyConnectionChanged?.(false, true, from);\n    while (start && start !== this._$endNode) {\n      const n = wrap(start!).nextSibling;\n      (wrap(start!) as Element).remove();\n      start = n;\n    }\n  }\n  /**\n   * Implementation of RootPart's `isConnected`. Note that this metod\n   * should only be called on `RootPart`s (the `ChildPart` returned from a\n   * top-level `render()` call). It has no effect on non-root ChildParts.\n   * @param isConnected Whether to set\n   * @internal\n   */\n  setConnected(isConnected: boolean) {\n    if (this._$parent === undefined) {\n      this.__isConnected = isConnected;\n      this._$notifyConnectionChanged?.(isConnected);\n    } else if (DEV_MODE) {\n      throw new Error(\n        'part.setConnected() may only be called on a ' +\n          'RootPart returned from render().'\n      );\n    }\n  }\n}\n\n/**\n * A top-level `ChildPart` returned from `render` that manages the connected\n * state of `AsyncDirective`s created throughout the tree below it.\n */\nexport interface RootPart extends ChildPart {\n  /**\n   * Sets the connection state for `AsyncDirective`s contained within this root\n   * ChildPart.\n   *\n   * lit-html does not automatically monitor the connectedness of DOM rendered;\n   * as such, it is the responsibility of the caller to `render` to ensure that\n   * `part.setConnected(false)` is called before the part object is potentially\n   * discarded, to ensure that `AsyncDirective`s have a chance to dispose of\n   * any resources being held. If a `RootPart` that was prevously\n   * disconnected is subsequently re-connected (and its `AsyncDirective`s should\n   * re-connect), `setConnected(true)` should be called.\n   *\n   * @param isConnected Whether directives within this tree should be connected\n   * or not\n   */\n  setConnected(isConnected: boolean): void;\n}\n\nexport type {AttributePart};\nclass AttributePart implements Disconnectable {\n  readonly type = ATTRIBUTE_PART as\n    | typeof ATTRIBUTE_PART\n    | typeof PROPERTY_PART\n    | typeof BOOLEAN_ATTRIBUTE_PART\n    | typeof EVENT_PART;\n  readonly element: HTMLElement;\n  readonly name: string;\n  readonly options: RenderOptions | undefined;\n\n  /**\n   * If this attribute part represents an interpolation, this contains the\n   * static strings of the interpolation. For single-value, complete bindings,\n   * this is undefined.\n   */\n  readonly strings?: ReadonlyArray<string>;\n  /** @internal */\n  _$committedValue: unknown | Array<unknown> = nothing;\n  /** @internal */\n  __directives?: Array<Directive | undefined>;\n  /** @internal */\n  _$parent: Disconnectable;\n  /** @internal */\n  _$disconnectableChildren?: Set<Disconnectable> = undefined;\n\n  protected _sanitizer: ValueSanitizer | undefined;\n\n  get tagName() {\n    return this.element.tagName;\n  }\n\n  // See comment in Disconnectable interface for why this is a getter\n  get _$isConnected() {\n    return this._$parent._$isConnected;\n  }\n\n  constructor(\n    element: HTMLElement,\n    name: string,\n    strings: ReadonlyArray<string>,\n    parent: Disconnectable,\n    options: RenderOptions | undefined\n  ) {\n    this.element = element;\n    this.name = name;\n    this._$parent = parent;\n    this.options = options;\n    if (strings.length > 2 || strings[0] !== '' || strings[1] !== '') {\n      this._$committedValue = new Array(strings.length - 1).fill(new String());\n      this.strings = strings;\n    } else {\n      this._$committedValue = nothing;\n    }\n    if (ENABLE_EXTRA_SECURITY_HOOKS) {\n      this._sanitizer = undefined;\n    }\n  }\n\n  /**\n   * Sets the value of this part by resolving the value from possibly multiple\n   * values and static strings and committing it to the DOM.\n   * If this part is single-valued, `this._strings` will be undefined, and the\n   * method will be called with a single value argument. If this part is\n   * multi-value, `this._strings` will be defined, and the method is called\n   * with the value array of the part's owning TemplateInstance, and an offset\n   * into the value array from which the values should be read.\n   * This method is overloaded this way to eliminate short-lived array slices\n   * of the template instance values, and allow a fast-path for single-valued\n   * parts.\n   *\n   * @param value The part value, or an array of values for multi-valued parts\n   * @param valueIndex the index to start reading values from. `undefined` for\n   *   single-valued parts\n   * @param noCommit causes the part to not commit its value to the DOM. Used\n   *   in hydration to prime attribute parts with their first-rendered value,\n   *   but not set the attribute, and in SSR to no-op the DOM operation and\n   *   capture the value for serialization.\n   *\n   * @internal\n   */\n  _$setValue(\n    value: unknown | Array<unknown>,\n    directiveParent: DirectiveParent = this,\n    valueIndex?: number,\n    noCommit?: boolean\n  ) {\n    const strings = this.strings;\n\n    // Whether any of the values has changed, for dirty-checking\n    let change = false;\n\n    if (strings === undefined) {\n      // Single-value binding case\n      value = resolveDirective(this, value, directiveParent, 0);\n      change =\n        !isPrimitive(value) ||\n        (value !== this._$committedValue && value !== noChange);\n      if (change) {\n        this._$committedValue = value;\n      }\n    } else {\n      // Interpolation case\n      const values = value as Array<unknown>;\n      value = strings[0];\n\n      let i, v;\n      for (i = 0; i < strings.length - 1; i++) {\n        v = resolveDirective(this, values[valueIndex! + i], directiveParent, i);\n\n        if (v === noChange) {\n          // If the user-provided value is `noChange`, use the previous value\n          v = (this._$committedValue as Array<unknown>)[i];\n        }\n        change ||=\n          !isPrimitive(v) || v !== (this._$committedValue as Array<unknown>)[i];\n        if (v === nothing) {\n          value = nothing;\n        } else if (value !== nothing) {\n          value += (v ?? '') + strings[i + 1];\n        }\n        // We always record each value, even if one is `nothing`, for future\n        // change detection.\n        (this._$committedValue as Array<unknown>)[i] = v;\n      }\n    }\n    if (change && !noCommit) {\n      this._commitValue(value);\n    }\n  }\n\n  /** @internal */\n  _commitValue(value: unknown) {\n    if (value === nothing) {\n      (wrap(this.element) as Element).removeAttribute(this.name);\n    } else {\n      if (ENABLE_EXTRA_SECURITY_HOOKS) {\n        if (this._sanitizer === undefined) {\n          this._sanitizer = sanitizerFactoryInternal(\n            this.element,\n            this.name,\n            'attribute'\n          );\n        }\n        value = this._sanitizer(value ?? '');\n      }\n      debugLogEvent?.({\n        kind: 'commit attribute',\n        element: this.element,\n        name: this.name,\n        value,\n        options: this.options,\n      });\n      (wrap(this.element) as Element).setAttribute(\n        this.name,\n        (value ?? '') as string\n      );\n    }\n  }\n}\n\nexport type {PropertyPart};\nclass PropertyPart extends AttributePart {\n  override readonly type = PROPERTY_PART;\n\n  /** @internal */\n  override _commitValue(value: unknown) {\n    if (ENABLE_EXTRA_SECURITY_HOOKS) {\n      if (this._sanitizer === undefined) {\n        this._sanitizer = sanitizerFactoryInternal(\n          this.element,\n          this.name,\n          'property'\n        );\n      }\n      value = this._sanitizer(value);\n    }\n    debugLogEvent?.({\n      kind: 'commit property',\n      element: this.element,\n      name: this.name,\n      value,\n      options: this.options,\n    });\n    // eslint-disable-next-line @typescript-eslint/no-explicit-any\n    (this.element as any)[this.name] = value === nothing ? undefined : value;\n  }\n}\n\n// Temporary workaround for https://crbug.com/993268\n// Currently, any attribute starting with \"on\" is considered to be a\n// TrustedScript source. Such boolean attributes must be set to the equivalent\n// trusted emptyScript value.\nconst emptyStringForBooleanAttribute = trustedTypes\n  ? (trustedTypes.emptyScript as unknown as '')\n  : '';\n\nexport type {BooleanAttributePart};\nclass BooleanAttributePart extends AttributePart {\n  override readonly type = BOOLEAN_ATTRIBUTE_PART;\n\n  /** @internal */\n  override _commitValue(value: unknown) {\n    debugLogEvent?.({\n      kind: 'commit boolean attribute',\n      element: this.element,\n      name: this.name,\n      value: !!(value && value !== nothing),\n      options: this.options,\n    });\n    if (value && value !== nothing) {\n      (wrap(this.element) as Element).setAttribute(\n        this.name,\n        emptyStringForBooleanAttribute\n      );\n    } else {\n      (wrap(this.element) as Element).removeAttribute(this.name);\n    }\n  }\n}\n\ntype EventListenerWithOptions = EventListenerOrEventListenerObject &\n  Partial<AddEventListenerOptions>;\n\n/**\n * An AttributePart that manages an event listener via add/removeEventListener.\n *\n * This part works by adding itself as the event listener on an element, then\n * delegating to the value passed to it. This reduces the number of calls to\n * add/removeEventListener if the listener changes frequently, such as when an\n * inline function is used as a listener.\n *\n * Because event options are passed when adding listeners, we must take case\n * to add and remove the part as a listener when the event options change.\n */\nexport type {EventPart};\nclass EventPart extends AttributePart {\n  override readonly type = EVENT_PART;\n\n  constructor(\n    element: HTMLElement,\n    name: string,\n    strings: ReadonlyArray<string>,\n    parent: Disconnectable,\n    options: RenderOptions | undefined\n  ) {\n    super(element, name, strings, parent, options);\n\n    if (DEV_MODE && this.strings !== undefined) {\n      throw new Error(\n        `A \\`<${element.localName}>\\` has a \\`@${name}=...\\` listener with ` +\n          'invalid content. Event listeners in templates must have exactly ' +\n          'one expression and no surrounding text.'\n      );\n    }\n  }\n\n  // EventPart does not use the base _$setValue/_resolveValue implementation\n  // since the dirty checking is more complex\n  /** @internal */\n  override _$setValue(\n    newListener: unknown,\n    directiveParent: DirectiveParent = this\n  ) {\n    newListener =\n      resolveDirective(this, newListener, directiveParent, 0) ?? nothing;\n    if (newListener === noChange) {\n      return;\n    }\n    const oldListener = this._$committedValue;\n\n    // If the new value is nothing or any options change we have to remove the\n    // part as a listener.\n    const shouldRemoveListener =\n      (newListener === nothing && oldListener !== nothing) ||\n      (newListener as EventListenerWithOptions).capture !==\n        (oldListener as EventListenerWithOptions).capture ||\n      (newListener as EventListenerWithOptions).once !==\n        (oldListener as EventListenerWithOptions).once ||\n      (newListener as EventListenerWithOptions).passive !==\n        (oldListener as EventListenerWithOptions).passive;\n\n    // If the new value is not nothing and we removed the listener, we have\n    // to add the part as a listener.\n    const shouldAddListener =\n      newListener !== nothing &&\n      (oldListener === nothing || shouldRemoveListener);\n\n    debugLogEvent?.({\n      kind: 'commit event listener',\n      element: this.element,\n      name: this.name,\n      value: newListener,\n      options: this.options,\n      removeListener: shouldRemoveListener,\n      addListener: shouldAddListener,\n      oldListener,\n    });\n    if (shouldRemoveListener) {\n      this.element.removeEventListener(\n        this.name,\n        this,\n        oldListener as EventListenerWithOptions\n      );\n    }\n    if (shouldAddListener) {\n      // Beware: IE11 and Chrome 41 don't like using the listener as the\n      // options object. Figure out how to deal w/ this in IE11 - maybe\n      // patch addEventListener?\n      this.element.addEventListener(\n        this.name,\n        this,\n        newListener as EventListenerWithOptions\n      );\n    }\n    this._$committedValue = newListener;\n  }\n\n  handleEvent(event: Event) {\n    if (typeof this._$committedValue === 'function') {\n      this._$committedValue.call(this.options?.host ?? this.element, event);\n    } else {\n      (this._$committedValue as EventListenerObject).handleEvent(event);\n    }\n  }\n}\n\nexport type {ElementPart};\nclass ElementPart implements Disconnectable {\n  readonly type = ELEMENT_PART;\n\n  /** @internal */\n  __directive?: Directive;\n\n  // This is to ensure that every Part has a _$committedValue\n  _$committedValue: undefined;\n\n  /** @internal */\n  _$parent!: Disconnectable;\n\n  /** @internal */\n  _$disconnectableChildren?: Set<Disconnectable> = undefined;\n\n  options: RenderOptions | undefined;\n\n  constructor(\n    public element: Element,\n    parent: Disconnectable,\n    options: RenderOptions | undefined\n  ) {\n    this._$parent = parent;\n    this.options = options;\n  }\n\n  // See comment in Disconnectable interface for why this is a getter\n  get _$isConnected() {\n    return this._$parent._$isConnected;\n  }\n\n  _$setValue(value: unknown): void {\n    debugLogEvent?.({\n      kind: 'commit to element binding',\n      element: this.element,\n      value,\n      options: this.options,\n    });\n    resolveDirective(this, value);\n  }\n}\n\n/**\n * END USERS SHOULD NOT RELY ON THIS OBJECT.\n *\n * Private exports for use by other Lit packages, not intended for use by\n * external users.\n *\n * We currently do not make a mangled rollup build of the lit-ssr code. In order\n * to keep a number of (otherwise private) top-level exports  mangled in the\n * client side code, we export a _$LH object containing those members (or\n * helper methods for accessing private fields of those members), and then\n * re-export them for use in lit-ssr. This keeps lit-ssr agnostic to whether the\n * client-side code is being used in `dev` mode or `prod` mode.\n *\n * This has a unique name, to disambiguate it from private exports in\n * lit-element, which re-exports all of lit-html.\n *\n * @private\n */\nexport const _$LH = {\n  // Used in lit-ssr\n  _boundAttributeSuffix: boundAttributeSuffix,\n  _marker: marker,\n  _markerMatch: markerMatch,\n  _HTML_RESULT: HTML_RESULT,\n  _getTemplateHtml: getTemplateHtml,\n  // Used in hydrate\n  _TemplateInstance: TemplateInstance,\n  _isIterable: isIterable,\n  _resolveDirective: resolveDirective,\n  // Used in tests and private-ssr-support\n  _ChildPart: ChildPart,\n  _AttributePart: AttributePart,\n  _BooleanAttributePart: BooleanAttributePart,\n  _EventPart: EventPart,\n  _PropertyPart: PropertyPart,\n  _ElementPart: ElementPart,\n};\n\n// Apply polyfills if available\nconst polyfillSupport = DEV_MODE\n  ? global.litHtmlPolyfillSupportDevMode\n  : global.litHtmlPolyfillSupport;\npolyfillSupport?.(Template, ChildPart);\n\n// IMPORTANT: do not change the property name or the assignment expression.\n// This line will be used in regexes to search for lit-html usage.\n(global.litHtmlVersions ??= []).push('2.4.0');\nif (DEV_MODE && global.litHtmlVersions.length > 1) {\n  issueWarning!(\n    'multiple-versions',\n    `Multiple versions of Lit loaded. ` +\n      `Loading multiple versions is not recommended.`\n  );\n}\n\n/**\n * Renders a value, usually a lit-html TemplateResult, to the container.\n *\n * This example renders the text \"Hello, Zoe!\" inside a paragraph tag, appending\n * it to the container `document.body`.\n *\n * ```js\n * import {html, render} from 'lit';\n *\n * const name = \"Zoe\";\n * render(html`<p>Hello, ${name}!</p>`, document.body);\n * ```\n *\n * @param value Any [renderable\n *   value](https://lit.dev/docs/templates/expressions/#child-expressions),\n *   typically a {@linkcode TemplateResult} created by evaluating a template tag\n *   like {@linkcode html} or {@linkcode svg}.\n * @param container A DOM container to render to. The first render will append\n *   the rendered value to the container, and subsequent renders will\n *   efficiently update the rendered value if the same result type was\n *   previously rendered there.\n * @param options See {@linkcode RenderOptions} for options documentation.\n * @see\n * {@link https://lit.dev/docs/libraries/standalone-templates/#rendering-lit-html-templates| Rendering Lit HTML Templates}\n */\nexport const render = (\n  value: unknown,\n  container: HTMLElement | DocumentFragment,\n  options?: RenderOptions\n): RootPart => {\n  if (DEV_MODE && container == null) {\n    // Give a clearer error message than\n    //     Uncaught TypeError: Cannot read properties of null (reading\n    //     '_$litPart$')\n    // which reads like an internal Lit error.\n    throw new TypeError(`The container to render into may not be ${container}`);\n  }\n  const renderId = DEV_MODE ? debugLogRenderId++ : 0;\n  const partOwnerNode = options?.renderBefore ?? container;\n  // This property needs to remain unminified.\n  // eslint-disable-next-line @typescript-eslint/no-explicit-any\n  let part: ChildPart = (partOwnerNode as any)['_$litPart$'];\n  debugLogEvent?.({\n    kind: 'begin render',\n    id: renderId,\n    value,\n    container,\n    options,\n    part,\n  });\n  if (part === undefined) {\n    const endNode = options?.renderBefore ?? null;\n    // This property needs to remain unminified.\n    // eslint-disable-next-line @typescript-eslint/no-explicit-any\n    (partOwnerNode as any)['_$litPart$'] = part = new ChildPart(\n      container.insertBefore(createMarker(), endNode),\n      endNode,\n      undefined,\n      options ?? {}\n    );\n  }\n  part._$setValue(value);\n  debugLogEvent?.({\n    kind: 'end render',\n    id: renderId,\n    value,\n    container,\n    options,\n    part,\n  });\n  return part as RootPart;\n};\n\nif (ENABLE_EXTRA_SECURITY_HOOKS) {\n  render.setSanitizer = setSanitizer;\n  render.createSanitizer = createSanitizer;\n  if (DEV_MODE) {\n    render._testOnlyClearSanitizerFactoryDoNotCallOrElse =\n      _testOnlyClearSanitizerFactoryDoNotCallOrElse;\n  }\n}\n"],"names":["global","window","trustedTypes","policy","createPolicy","createHTML","s","undefined","marker","Math","random","String","slice","markerMatch","nodeMarker","d","document","createMarker","v","createComment","isPrimitive","value","isArray","Array","isIterable","Symbol","iterator","textEndRegex","commentEndRegex","comment2EndRegex","tagEndRegex","RegExp","singleQuoteAttrEndRegex","doubleQuoteAttrEndRegex","rawTextElement","tag","type","strings","values","_$litType$","html","svg","noChange","for","nothing","templateCache","WeakMap","walker","createTreeWalker","getTemplateHtml","l","length","attrNames","rawTextEndRegex","regex","i","attrName","match","attrNameEndIndex","lastIndex","exec","test","end","startsWith","push","htmlResult","hasOwnProperty","Error","Template","constructor","options","node","this","parts","nodeIndex","attrNameIndex","partCount","el","createElement","currentNode","content","svgElement","firstChild","remove","append","childNodes","nextNode","nodeType","hasAttributes","attrsToRemove","name","getAttributeNames","endsWith","realName","statics","getAttribute","toLowerCase","split","m","index","ctor","PropertyPart","BooleanAttributePart","EventPart","AttributePart","removeAttribute","tagName","textContent","emptyScript","data","indexOf","static","_options","innerHTML","resolveDirective","part","parent","attributeIndex","currentDirective","_a","__directives","__directive","nextDirectiveConstructor","_b","call","_$initialize","_c","_d","_$resolve","TemplateInstance","template","_parts","_$disconnectableChildren","_$template","_$parent","parentNode","_$isConnected","_clone","fragment","creationScope","importNode","partIndex","templatePart","ChildPart","nextSibling","ElementPart","_update","_$setValue","startNode","endNode","_$committedValue","_$startNode","_$endNode","__isConnected","isConnected","directiveParent","_$clear","_commitText","_commitTemplateResult","_commitNode","_commitIterable","_insert","ref","insertBefore","createTextNode","result","_$getTemplate","h","instance","get","set","itemParts","itemPart","item","start","from","_$notifyConnectionChanged","n","setConnected","element","fill","valueIndex","noCommit","change","_commitValue","setAttribute","emptyStringForBooleanAttribute","super","newListener","oldListener","shouldRemoveListener","capture","once","passive","shouldAddListener","removeEventListener","addEventListener","handleEvent","event","host","_$LH","_boundAttributeSuffix","_marker","_markerMatch","_HTML_RESULT","_getTemplateHtml","_TemplateInstance","_isIterable","_resolveDirective","_ChildPart","_AttributePart","_BooleanAttributePart","_EventPart","_PropertyPart","_ElementPart","polyfillSupport","litHtmlPolyfillSupport","litHtmlVersions","render","container","partOwnerNode","renderBefore"],"mappings":";;;;;MAcA,MAAMA,EAAkCC,OAmOlCC,EAAgBF,EAAsCE,aAUtDC,EAASD,EACXA,EAAaE,aAAa,WAAY,CACpCC,WAAaC,GAAMA,SAErBC,EAkFEC,EAAS,QAAcC,KAAKC,SAAZC,IAAsBC,MAAM,MAG5CC,EAAc,IAAML,EAIpBM,EAAa,IAAID,KAEjBE,EAOAC,SAGAC,EAAe,CAACC,EAAI,KAAOH,EAAEI,cAAcD,GAI3CE,EAAeC,GACT,OAAVA,GAAmC,iBAATA,GAAqC,mBAATA,EAClDC,EAAUC,MAAMD,QAChBE,EAAcH,GAClBC,EAAQD,IAEqC,mBAArCA,eAAAA,EAAgBI,OAAOC,WAoB3BC,EAAe,sDAKfC,EAAkB,OAIlBC,EAAmB,KAwBnBC,EAAkBC,OACtB,+FACA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G,EACZ8G,EAAehH,EACfiH,EAAcrE,GAIVsE,EAEFvN,EAAOwN,uBACXD,SAAAA,EAAkBnJ,EAAU2E,IAIL,QAAvBhB,EAAC/H,EAAOyN,uBAAe,IAAA1F,EAAAA,EAAtB/H,EAAOyN,gBAAoB,IAAIzJ,KAAK,SAkCxB,MAAA0J,EAAS,CACpBrM,EACAsM,EACArJ,aAUA,MAAMsJ,EAAyC,QAAzBrG,EAAAjD,aAAA,EAAAA,EAASuJ,oBAAgB,IAAAtG,EAAAA,EAAAoG,EAG/C,IAAIxG,EAAmByG,EAAkC,WASzD,QAAarN,IAAT4G,EAAoB,CACtB,MAAMkC,EAAmC,QAAzB1B,EAAArD,aAAA,EAAAA,EAASuJ,oBAAgB,IAAAlG,EAAAA,EAAA,KAGxCiG,EAAkC,WAAIzG,EAAO,IAAI4B,EAChD4E,EAAUxD,aAAalJ,IAAgBoI,GACvCA,OACA9I,EACA+D,QAAAA,EAAW,CAAA,EAEd,CAUD,OATA6C,EAAKgC,KAAW9H,GAST8F,CAAgB"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/node/async-directive.js b/front_end/third_party/lit-html/package/node/async-directive.js
new file mode 100644
index 0000000000000000000000000000000000000000..0aee36624b515a54342b2647c7c115179c140dc3
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/async-directive.js
@@ -0,0 +1,7 @@
+import{isSingleExpression as i}from"./directive-helpers.js";import{Directive as t,PartType as e}from"./directive.js";export{Directive,PartType,directive}from"./directive.js";
+/**
+ * @license
+ * Copyright 2017 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */const s=(i,t)=>{var e,o;const r=i._$AN;if(void 0===r)return!1;for(const i of r)null===(o=(e=i)._$AO)||void 0===o||o.call(e,t,!1),s(i,t);return!0},o=i=>{let t,e;do{if(void 0===(t=i._$AM))break;e=t._$AN,e.delete(i),i=t}while(0===(null==e?void 0:e.size))},r=i=>{for(let t;t=i._$AM;i=t){let e=t._$AN;if(void 0===e)t._$AN=e=new Set;else if(e.has(i))break;e.add(i),l(t)}};function n(i){void 0!==this._$AN?(o(this),this._$AM=i,r(this)):this._$AM=i}function h(i,t=!1,e=0){const r=this._$AH,n=this._$AN;if(void 0!==n&&0!==n.size)if(t)if(Array.isArray(r))for(let i=e;i<r.length;i++)s(r[i],!1),o(r[i]);else null!=r&&(s(r,!1),o(r));else s(this,i)}const l=i=>{var t,s,o,r;i.type==e.CHILD&&(null!==(t=(o=i)._$AP)&&void 0!==t||(o._$AP=h),null!==(s=(r=i)._$AQ)&&void 0!==s||(r._$AQ=n))};class c extends t{constructor(){super(...arguments),this._$AN=void 0}_$AT(i,t,e){super._$AT(i,t,e),r(this),this.isConnected=i._$AU}_$AO(i,t=!0){var e,r;i!==this.isConnected&&(this.isConnected=i,i?null===(e=this.reconnected)||void 0===e||e.call(this):null===(r=this.disconnected)||void 0===r||r.call(this)),t&&(s(this,i),o(this))}setValue(t){if(i(this._$Ct))this._$Ct._$AI(t,this);else{const i=[...this._$Ct._$AH];i[this._$Ci]=t,this._$Ct._$AI(i,this,0)}}disconnected(){}reconnected(){}}export{c as AsyncDirective};
+//# sourceMappingURL=async-directive.js.map




diff --git a/front_end/third_party/lit-html/package/node/async-directive.js.map b/front_end/third_party/lit-html/package/node/async-directive.js.map
new file mode 100644
index 0000000000000000000000000000000000000000..b6fa96d000ba0ff713c1a49d3fc1763c1f7351b8
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/async-directive.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"async-directive.js","sources":["../src/async-directive.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n/**\n * Overview:\n *\n * This module is designed to add support for an async `setValue` API and\n * `disconnected` callback to directives with the least impact on the core\n * runtime or payload when that feature is not used.\n *\n * The strategy is to introduce a `AsyncDirective` subclass of\n * `Directive` that climbs the \"parent\" tree in its constructor to note which\n * branches of lit-html's \"logical tree\" of data structures contain such\n * directives and thus need to be crawled when a subtree is being cleared (or\n * manually disconnected) in order to run the `disconnected` callback.\n *\n * The \"nodes\" of the logical tree include Parts, TemplateInstances (for when a\n * TemplateResult is committed to a value of a ChildPart), and Directives; these\n * all implement a common interface called `DisconnectableChild`. Each has a\n * `_$parent` reference which is set during construction in the core code, and a\n * `_$disconnectableChildren` field which is initially undefined.\n *\n * The sparse tree created by means of the `AsyncDirective` constructor\n * crawling up the `_$parent` tree and placing a `_$disconnectableChildren` Set\n * on each parent that includes each child that contains a\n * `AsyncDirective` directly or transitively via its children. In order to\n * notify connection state changes and disconnect (or reconnect) a tree, the\n * `_$notifyConnectionChanged` API is patched onto ChildParts as a directive\n * climbs the parent tree, which is called by the core when clearing a part if\n * it exists. When called, that method iterates over the sparse tree of\n * Set<DisconnectableChildren> built up by AsyncDirectives, and calls\n * `_$notifyDirectiveConnectionChanged` on any directives that are encountered\n * in that tree, running the required callbacks.\n *\n * A given \"logical tree\" of lit-html data-structures might look like this:\n *\n *  ChildPart(N1) _$dC=[D2,T3]\n *   ._directive\n *     AsyncDirective(D2)\n *   ._value // user value was TemplateResult\n *     TemplateInstance(T3) _$dC=[A4,A6,N10,N12]\n *      ._parts[]\n *        AttributePart(A4) _$dC=[D5]\n *         ._directives[]\n *           AsyncDirective(D5)\n *        AttributePart(A6) _$dC=[D7,D8]\n *         ._directives[]\n *           AsyncDirective(D7)\n *           Directive(D8) _$dC=[D9]\n *            ._directive\n *              AsyncDirective(D9)\n *        ChildPart(N10) _$dC=[D11]\n *         ._directive\n *           AsyncDirective(D11)\n *         ._value\n *           string\n *        ChildPart(N12) _$dC=[D13,N14,N16]\n *         ._directive\n *           AsyncDirective(D13)\n *         ._value // user value was iterable\n *           Array<ChildPart>\n *             ChildPart(N14) _$dC=[D15]\n *              ._value\n *                string\n *             ChildPart(N16) _$dC=[D17,T18]\n *              ._directive\n *                AsyncDirective(D17)\n *              ._value // user value was TemplateResult\n *                TemplateInstance(T18) _$dC=[A19,A21,N25]\n *                 ._parts[]\n *                   AttributePart(A19) _$dC=[D20]\n *                    ._directives[]\n *                      AsyncDirective(D20)\n *                   AttributePart(A21) _$dC=[22,23]\n *                    ._directives[]\n *                      AsyncDirective(D22)\n *                      Directive(D23) _$dC=[D24]\n *                       ._directive\n *                         AsyncDirective(D24)\n *                   ChildPart(N25) _$dC=[D26]\n *                    ._directive\n *                      AsyncDirective(D26)\n *                    ._value\n *                      string\n *\n * Example 1: The directive in ChildPart(N12) updates and returns `nothing`. The\n * ChildPart will _clear() itself, and so we need to disconnect the \"value\" of\n * the ChildPart (but not its directive). In this case, when `_clear()` calls\n * `_$notifyConnectionChanged()`, we don't iterate all of the\n * _$disconnectableChildren, rather we do a value-specific disconnection: i.e.\n * since the _value was an Array<ChildPart> (because an iterable had been\n * committed), we iterate the array of ChildParts (N14, N16) and run\n * `setConnected` on them (which does recurse down the full tree of\n * `_$disconnectableChildren` below it, and also removes N14 and N16 from N12's\n * `_$disconnectableChildren`). Once the values have been disconnected, we then\n * check whether the ChildPart(N12)'s list of `_$disconnectableChildren` is empty\n * (and would remove it from its parent TemplateInstance(T3) if so), but since\n * it would still contain its directive D13, it stays in the disconnectable\n * tree.\n *\n * Example 2: In the course of Example 1, `setConnected` will reach\n * ChildPart(N16); in this case the entire part is being disconnected, so we\n * simply iterate all of N16's `_$disconnectableChildren` (D17,T18) and\n * recursively run `setConnected` on them. Note that we only remove children\n * from `_$disconnectableChildren` for the top-level values being disconnected\n * on a clear; doing this bookkeeping lower in the tree is wasteful since it's\n * all being thrown away.\n *\n * Example 3: If the LitElement containing the entire tree above becomes\n * disconnected, it will run `childPart.setConnected()` (which calls\n * `childPart._$notifyConnectionChanged()` if it exists); in this case, we\n * recursively run `setConnected()` over the entire tree, without removing any\n * children from `_$disconnectableChildren`, since this tree is required to\n * re-connect the tree, which does the same operation, simply passing\n * `isConnected: true` down the tree, signaling which callback to run.\n */\n\nimport {AttributePart, ChildPart, Disconnectable, Part} from './lit-html.js';\nimport {isSingleExpression} from './directive-helpers.js';\nimport {Directive, PartInfo, PartType} from './directive.js';\nexport * from './directive.js';\n\nconst DEV_MODE = true;\n\n/**\n * Recursively walks down the tree of Parts/TemplateInstances/Directives to set\n * the connected state of directives and run `disconnected`/ `reconnected`\n * callbacks.\n *\n * @return True if there were children to disconnect; false otherwise\n */\nconst notifyChildrenConnectedChanged = (\n  parent: Disconnectable,\n  isConnected: boolean\n): boolean => {\n  const children = parent._$disconnectableChildren;\n  if (children === undefined) {\n    return false;\n  }\n  for (const obj of children) {\n    // The existence of `_$notifyDirectiveConnectionChanged` is used as a \"brand\" to\n    // disambiguate AsyncDirectives from other DisconnectableChildren\n    // (as opposed to using an instanceof check to know when to call it); the\n    // redundancy of \"Directive\" in the API name is to avoid conflicting with\n    // `_$notifyConnectionChanged`, which exists `ChildParts` which are also in\n    // this list\n    // Disconnect Directive (and any nested directives contained within)\n    // This property needs to remain unminified.\n    (obj as AsyncDirective)['_$notifyDirectiveConnectionChanged']?.(\n      isConnected,\n      false\n    );\n    // Disconnect Part/TemplateInstance\n    notifyChildrenConnectedChanged(obj, isConnected);\n  }\n  return true;\n};\n\n/**\n * Removes the given child from its parent list of disconnectable children, and\n * if the parent list becomes empty as a result, removes the parent from its\n * parent, and so forth up the tree when that causes subsequent parent lists to\n * become empty.\n */\nconst removeDisconnectableFromParent = (obj: Disconnectable) => {\n  let parent, children;\n  do {\n    if ((parent = obj._$parent) === undefined) {\n      break;\n    }\n    children = parent._$disconnectableChildren!;\n    children.delete(obj);\n    obj = parent;\n  } while (children?.size === 0);\n};\n\nconst addDisconnectableToParent = (obj: Disconnectable) => {\n  // Climb the parent tree, creating a sparse tree of children needing\n  // disconnection\n  for (let parent; (parent = obj._$parent); obj = parent) {\n    let children = parent._$disconnectableChildren;\n    if (children === undefined) {\n      parent._$disconnectableChildren = children = new Set();\n    } else if (children.has(obj)) {\n      // Once we've reached a parent that already contains this child, we\n      // can short-circuit\n      break;\n    }\n    children.add(obj);\n    installDisconnectAPI(parent);\n  }\n};\n\n/**\n * Changes the parent reference of the ChildPart, and updates the sparse tree of\n * Disconnectable children accordingly.\n *\n * Note, this method will be patched onto ChildPart instances and called from\n * the core code when parts are moved between different parents.\n */\nfunction reparentDisconnectables(this: ChildPart, newParent: Disconnectable) {\n  if (this._$disconnectableChildren !== undefined) {\n    removeDisconnectableFromParent(this);\n    this._$parent = newParent;\n    addDisconnectableToParent(this);\n  } else {\n    this._$parent = newParent;\n  }\n}\n\n/**\n * Sets the connected state on any directives contained within the committed\n * value of this part (i.e. within a TemplateInstance or iterable of\n * ChildParts) and runs their `disconnected`/`reconnected`s, as well as within\n * any directives stored on the ChildPart (when `valueOnly` is false).\n *\n * `isClearingValue` should be passed as `true` on a top-level part that is\n * clearing itself, and not as a result of recursively disconnecting directives\n * as part of a `clear` operation higher up the tree. This both ensures that any\n * directive on this ChildPart that produced a value that caused the clear\n * operation is not disconnected, and also serves as a performance optimization\n * to avoid needless bookkeeping when a subtree is going away; when clearing a\n * subtree, only the top-most part need to remove itself from the parent.\n *\n * `fromPartIndex` is passed only in the case of a partial `_clear` running as a\n * result of truncating an iterable.\n *\n * Note, this method will be patched onto ChildPart instances and called from the\n * core code when parts are cleared or the connection state is changed by the\n * user.\n */\nfunction notifyChildPartConnectedChanged(\n  this: ChildPart,\n  isConnected: boolean,\n  isClearingValue = false,\n  fromPartIndex = 0\n) {\n  const value = this._$committedValue;\n  const children = this._$disconnectableChildren;\n  if (children === undefined || children.size === 0) {\n    return;\n  }\n  if (isClearingValue) {\n    if (Array.isArray(value)) {\n      // Iterable case: Any ChildParts created by the iterable should be\n      // disconnected and removed from this ChildPart's disconnectable\n      // children (starting at `fromPartIndex` in the case of truncation)\n      for (let i = fromPartIndex; i < value.length; i++) {\n        notifyChildrenConnectedChanged(value[i], false);\n        removeDisconnectableFromParent(value[i]);\n      }\n    } else if (value != null) {\n      // TemplateInstance case: If the value has disconnectable children (will\n      // only be in the case that it is a TemplateInstance), we disconnect it\n      // and remove it from this ChildPart's disconnectable children\n      notifyChildrenConnectedChanged(value as Disconnectable, false);\n      removeDisconnectableFromParent(value as Disconnectable);\n    }\n  } else {\n    notifyChildrenConnectedChanged(this, isConnected);\n  }\n}\n\n/**\n * Patches disconnection API onto ChildParts.\n */\nconst installDisconnectAPI = (obj: Disconnectable) => {\n  if ((obj as ChildPart).type == PartType.CHILD) {\n    (obj as ChildPart)._$notifyConnectionChanged ??=\n      notifyChildPartConnectedChanged;\n    (obj as ChildPart)._$reparentDisconnectables ??= reparentDisconnectables;\n  }\n};\n\n/**\n * An abstract `Directive` base class whose `disconnected` method will be\n * called when the part containing the directive is cleared as a result of\n * re-rendering, or when the user calls `part.setConnected(false)` on\n * a part that was previously rendered containing the directive (as happens\n * when e.g. a LitElement disconnects from the DOM).\n *\n * If `part.setConnected(true)` is subsequently called on a\n * containing part, the directive's `reconnected` method will be called prior\n * to its next `update`/`render` callbacks. When implementing `disconnected`,\n * `reconnected` should also be implemented to be compatible with reconnection.\n *\n * Note that updates may occur while the directive is disconnected. As such,\n * directives should generally check the `this.isConnected` flag during\n * render/update to determine whether it is safe to subscribe to resources\n * that may prevent garbage collection.\n */\nexport abstract class AsyncDirective extends Directive {\n  // As opposed to other Disconnectables, AsyncDirectives always get notified\n  // when the RootPart connection changes, so the public `isConnected`\n  // is a locally stored variable initialized via its part's getter and synced\n  // via `_$notifyDirectiveConnectionChanged`. This is cheaper than using\n  // the _$isConnected getter, which has to look back up the tree each time.\n  /**\n   * The connection state for this Directive.\n   */\n  isConnected!: boolean;\n\n  // @internal\n  override _$disconnectableChildren?: Set<Disconnectable> = undefined;\n  /**\n   * Initialize the part with internal fields\n   * @param part\n   * @param parent\n   * @param attributeIndex\n   */\n  override _$initialize(\n    part: Part,\n    parent: Disconnectable,\n    attributeIndex: number | undefined\n  ) {\n    super._$initialize(part, parent, attributeIndex);\n    addDisconnectableToParent(this);\n    this.isConnected = part._$isConnected;\n  }\n  // This property needs to remain unminified.\n  /**\n   * Called from the core code when a directive is going away from a part (in\n   * which case `shouldRemoveFromParent` should be true), and from the\n   * `setChildrenConnected` helper function when recursively changing the\n   * connection state of a tree (in which case `shouldRemoveFromParent` should\n   * be false).\n   *\n   * @param isConnected\n   * @param isClearingDirective - True when the directive itself is being\n   *     removed; false when the tree is being disconnected\n   * @internal\n   */\n  override ['_$notifyDirectiveConnectionChanged'](\n    isConnected: boolean,\n    isClearingDirective = true\n  ) {\n    if (isConnected !== this.isConnected) {\n      this.isConnected = isConnected;\n      if (isConnected) {\n        this.reconnected?.();\n      } else {\n        this.disconnected?.();\n      }\n    }\n    if (isClearingDirective) {\n      notifyChildrenConnectedChanged(this, isConnected);\n      removeDisconnectableFromParent(this);\n    }\n  }\n\n  /**\n   * Sets the value of the directive's Part outside the normal `update`/`render`\n   * lifecycle of a directive.\n   *\n   * This method should not be called synchronously from a directive's `update`\n   * or `render`.\n   *\n   * @param directive The directive to update\n   * @param value The value to set\n   */\n  setValue(value: unknown) {\n    if (isSingleExpression(this.__part as unknown as PartInfo)) {\n      this.__part._$setValue(value, this);\n    } else {\n      // this.__attributeIndex will be defined in this case, but\n      // assert it in dev mode\n      if (DEV_MODE && this.__attributeIndex === undefined) {\n        throw new Error(`Expected this.__attributeIndex to be a number`);\n      }\n      const newValues = [...(this.__part._$committedValue as Array<unknown>)];\n      newValues[this.__attributeIndex!] = value;\n      (this.__part as AttributePart)._$setValue(newValues, this, 0);\n    }\n  }\n\n  /**\n   * User callbacks for implementing logic to release any resources/subscriptions\n   * that may have been retained by this directive. Since directives may also be\n   * re-connected, `reconnected` should also be implemented to restore the\n   * working state of the directive prior to the next render.\n   */\n  protected disconnected() {}\n  protected reconnected() {}\n}\n"],"names":["notifyChildrenConnectedChanged","parent","isConnected","children","_$disconnectableChildren","undefined","obj","_b","_a","removeDisconnectableFromParent","_$parent","delete","size","addDisconnectableToParent","Set","has","add","installDisconnectAPI","reparentDisconnectables","newParent","this","notifyChildPartConnectedChanged","isClearingValue","fromPartIndex","value","_$committedValue","Array","isArray","i","length","type","PartType","CHILD","_c","_$notifyConnectionChanged","_d","_$reparentDisconnectables","AsyncDirective","Directive","constructor","_$initialize","part","attributeIndex","super","_$isConnected","_$AO","isClearingDirective","reconnected","call","disconnected","setValue","isSingleExpression","__part","_$setValue","newValues","__attributeIndex"],"mappings":";;;;;GAsIA,MAAMA,EAAiC,CACrCC,EACAC,aAEA,MAAMC,EAAWF,EAAOG,KACxB,QAAiBC,IAAbF,EACF,OAAO,EAET,IAAK,MAAMG,KAAOH,UAShBI,GAAAC,EAACF,GAA2D,4BAC1DJ,GACA,GAGFF,EAA+BM,EAAKJ,GAEtC,OAAO,CAAI,EASPO,EAAkCH,IACtC,IAAIL,EAAQE,EACZ,EAAG,CACD,QAAgCE,KAA3BJ,EAASK,EAAII,MAChB,MAEFP,EAAWF,EAAOG,KAClBD,EAASQ,OAAOL,GAChBA,EAAML,QACoB,KAAnBE,aAAQ,EAARA,EAAUS,MAAY,EAG3BC,EAA6BP,IAGjC,IAAK,IAAIL,EAASA,EAASK,EAAII,KAAWJ,EAAML,EAAQ,CACtD,IAAIE,EAAWF,EAAOG,KACtB,QAAiBC,IAAbF,EACFF,EAAOG,KAA2BD,EAAW,IAAIW,SAC5C,GAAIX,EAASY,IAAIT,GAGtB,MAEFH,EAASa,IAAIV,GACbW,EAAqBhB,EACtB,GAUH,SAASiB,EAAyCC,QACVd,IAAlCe,KAAKhB,MACPK,EAA+BW,MAC/BA,KAAKV,KAAWS,EAChBN,EAA0BO,OAE1BA,KAAKV,KAAWS,CAEpB,CAuBA,SAASE,EAEPnB,EACAoB,GAAkB,EAClBC,EAAgB,GAEhB,MAAMC,EAAQJ,KAAKK,KACbtB,EAAWiB,KAAKhB,KACtB,QAAiBC,IAAbF,GAA4C,IAAlBA,EAASS,KAGvC,GAAIU,EACF,GAAII,MAAMC,QAAQH,GAIhB,IAAK,IAAII,EAAIL,EAAeK,EAAIJ,EAAMK,OAAQD,IAC5C5B,EAA+BwB,EAAMI,IAAI,GACzCnB,EAA+Be,EAAMI,SAErB,MAATJ,IAITxB,EAA+BwB,GAAyB,GACxDf,EAA+Be,SAGjCxB,EAA+BoB,KAAMlB,EAEzC,CAKA,MAAMe,EAAwBX,gBACvBA,EAAkBwB,MAAQC,EAASC,gBACtCxB,GAAAyB,EAAC3B,GAAkB4B,sBAAAA,KACjBb,WACFd,GAAA4B,EAAC7B,GAAkB8B,sBAAAA,KAA8BlB,GAClD,EAoBG,MAAgBmB,UAAuBC,EAA7CC,kCAYWnB,KAAwBhB,UAAyBC,CAgF3D,CAzEUmC,KACPC,EACAxC,EACAyC,GAEAC,MAAMH,KAAaC,EAAMxC,EAAQyC,GACjC7B,EAA0BO,MAC1BA,KAAKlB,YAAcuC,EAAKG,IACzB,CAcQC,KACP3C,EACA4C,GAAsB,WAElB5C,IAAgBkB,KAAKlB,cACvBkB,KAAKlB,YAAcA,EACfA,EACc,QAAhBM,EAAAY,KAAK2B,mBAAW,IAAAvC,GAAAA,EAAAwC,KAAA5B,MAEC,QAAjBb,EAAAa,KAAK6B,oBAAY,IAAA1C,GAAAA,EAAAyC,KAAA5B,OAGjB0B,IACF9C,EAA+BoB,KAAMlB,GACrCO,EAA+BW,MAElC,CAYD8B,SAAS1B,GACP,GAAI2B,EAAmB/B,KAAKgC,MAC1BhC,KAAKgC,KAAOC,KAAW7B,EAAOJ,UACzB,CAML,MAAMkC,EAAY,IAAKlC,KAAKgC,KAAO3B,MACnC6B,EAAUlC,KAAKmC,MAAqB/B,EACnCJ,KAAKgC,KAAyBC,KAAWC,EAAWlC,KAAM,EAC5D,CACF,CAQS6B,eAAiB,CACjBF,cAAgB"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/node/directive-helpers.js b/front_end/third_party/lit-html/package/node/directive-helpers.js
new file mode 100644
index 0000000000000000000000000000000000000000..edb030ce3caa489e1ae5824e114ff533c9383899
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directive-helpers.js
@@ -0,0 +1,7 @@
+import{_$LH as o}from"./lit-html.js";
+/**
+ * @license
+ * Copyright 2020 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */const{I:l}=o,t=o=>null===o||"object"!=typeof o&&"function"!=typeof o,i={HTML:1,SVG:2},n=(o,l)=>void 0===l?void 0!==(null==o?void 0:o._$litType$):(null==o?void 0:o._$litType$)===l,d=o=>void 0!==(null==o?void 0:o._$litDirective$),v=o=>null==o?void 0:o._$litDirective$,e=o=>void 0===o.strings,c=()=>document.createComment(""),r=(o,t,i)=>{var n;const d=o._$AA.parentNode,v=void 0===t?o._$AB:t._$AA;if(void 0===i){const t=d.insertBefore(c(),v),n=d.insertBefore(c(),v);i=new l(t,n,o,o.options)}else{const l=i._$AB.nextSibling,t=i._$AM,e=t!==o;if(e){let l;null===(n=i._$AQ)||void 0===n||n.call(i,o),i._$AM=o,void 0!==i._$AP&&(l=o._$AU)!==t._$AU&&i._$AP(l)}if(l!==v||e){let o=i._$AA;for(;o!==l;){const l=o.nextSibling;d.insertBefore(o,v),o=l}}}return i},u=(o,l,t=o)=>(o._$AI(l,t),o),f={},s=(o,l=f)=>o._$AH=l,m=o=>o._$AH,p=o=>{var l;null===(l=o._$AP)||void 0===l||l.call(o,!1,!0);let t=o._$AA;const i=o._$AB.nextSibling;for(;t!==i;){const o=t.nextSibling;t.remove(),t=o}},a=o=>{o._$AR()};export{i as TemplateResultType,a as clearPart,m as getCommittedValue,v as getDirectiveClass,r as insertPart,d as isDirectiveResult,t as isPrimitive,e as isSingleExpression,n as isTemplateResult,p as removePart,u as setChildPartValue,s as setCommittedValue};
+//# sourceMappingURL=directive-helpers.js.map




diff --git a/front_end/third_party/lit-html/package/node/directive-helpers.js.map b/front_end/third_party/lit-html/package/node/directive-helpers.js.map
new file mode 100644
index 0000000000000000000000000000000000000000..c773b4a6ca90b4d2d7abee922112f21fc3ac9b83
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directive-helpers.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"directive-helpers.js","sources":["../src/directive-helpers.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2020 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {_$LH, Part, DirectiveParent, TemplateResult} from './lit-html.js';\nimport {\n  DirectiveResult,\n  DirectiveClass,\n  PartInfo,\n  AttributePartInfo,\n} from './directive.js';\ntype Primitive = null | undefined | boolean | number | string | symbol | bigint;\n\nconst {_ChildPart: ChildPart} = _$LH;\n\ntype ChildPart = InstanceType<typeof ChildPart>;\n\nconst ENABLE_SHADYDOM_NOPATCH = true;\n\nconst wrap =\n  ENABLE_SHADYDOM_NOPATCH &&\n  window.ShadyDOM?.inUse &&\n  window.ShadyDOM?.noPatch === true\n    ? window.ShadyDOM!.wrap\n    : (node: Node) => node;\n\n/**\n * Tests if a value is a primitive value.\n *\n * See https://tc39.github.io/ecma262/#sec-typeof-operator\n */\nexport const isPrimitive = (value: unknown): value is Primitive =>\n  value === null || (typeof value != 'object' && typeof value != 'function');\n\nexport const TemplateResultType = {\n  HTML: 1,\n  SVG: 2,\n} as const;\n\nexport type TemplateResultType =\n  typeof TemplateResultType[keyof typeof TemplateResultType];\n\n/**\n * Tests if a value is a TemplateResult.\n */\nexport const isTemplateResult = (\n  value: unknown,\n  type?: TemplateResultType\n): value is TemplateResult =>\n  type === undefined\n    ? // This property needs to remain unminified.\n      (value as TemplateResult)?.['_$litType$'] !== undefined\n    : (value as TemplateResult)?.['_$litType$'] === type;\n\n/**\n * Tests if a value is a DirectiveResult.\n */\nexport const isDirectiveResult = (value: unknown): value is DirectiveResult =>\n  // This property needs to remain unminified.\n  (value as DirectiveResult)?.['_$litDirective$'] !== undefined;\n\n/**\n * Retrieves the Directive class for a DirectiveResult\n */\nexport const getDirectiveClass = (value: unknown): DirectiveClass | undefined =>\n  // This property needs to remain unminified.\n  (value as DirectiveResult)?.['_$litDirective$'];\n\n/**\n * Tests whether a part has only a single-expression with no strings to\n * interpolate between.\n *\n * Only AttributePart and PropertyPart can have multiple expressions.\n * Multi-expression parts have a `strings` property and single-expression\n * parts do not.\n */\nexport const isSingleExpression = (part: PartInfo) =>\n  (part as AttributePartInfo).strings === undefined;\n\nconst createMarker = () => document.createComment('');\n\n/**\n * Inserts a ChildPart into the given container ChildPart's DOM, either at the\n * end of the container ChildPart, or before the optional `refPart`.\n *\n * This does not add the part to the containerPart's committed value. That must\n * be done by callers.\n *\n * @param containerPart Part within which to add the new ChildPart\n * @param refPart Part before which to add the new ChildPart; when omitted the\n *     part added to the end of the `containerPart`\n * @param part Part to insert, or undefined to create a new part\n */\nexport const insertPart = (\n  containerPart: ChildPart,\n  refPart?: ChildPart,\n  part?: ChildPart\n): ChildPart => {\n  const container = wrap(containerPart._$startNode).parentNode!;\n\n  const refNode =\n    refPart === undefined ? containerPart._$endNode : refPart._$startNode;\n\n  if (part === undefined) {\n    const startNode = wrap(container).insertBefore(createMarker(), refNode);\n    const endNode = wrap(container).insertBefore(createMarker(), refNode);\n    part = new ChildPart(\n      startNode,\n      endNode,\n      containerPart,\n      containerPart.options\n    );\n  } else {\n    const endNode = wrap(part._$endNode!).nextSibling;\n    const oldParent = part._$parent;\n    const parentChanged = oldParent !== containerPart;\n    if (parentChanged) {\n      part._$reparentDisconnectables?.(containerPart);\n      // Note that although `_$reparentDisconnectables` updates the part's\n      // `_$parent` reference after unlinking from its current parent, that\n      // method only exists if Disconnectables are present, so we need to\n      // unconditionally set it here\n      part._$parent = containerPart;\n      // Since the _$isConnected getter is somewhat costly, only\n      // read it once we know the subtree has directives that need\n      // to be notified\n      let newConnectionState;\n      if (\n        part._$notifyConnectionChanged !== undefined &&\n        (newConnectionState = containerPart._$isConnected) !==\n          oldParent!._$isConnected\n      ) {\n        part._$notifyConnectionChanged(newConnectionState);\n      }\n    }\n    if (endNode !== refNode || parentChanged) {\n      let start: Node | null = part._$startNode;\n      while (start !== endNode) {\n        const n: Node | null = wrap(start!).nextSibling;\n        wrap(container).insertBefore(start!, refNode);\n        start = n;\n      }\n    }\n  }\n\n  return part;\n};\n\n/**\n * Sets the value of a Part.\n *\n * Note that this should only be used to set/update the value of user-created\n * parts (i.e. those created using `insertPart`); it should not be used\n * by directives to set the value of the directive's container part. Directives\n * should return a value from `update`/`render` to update their part state.\n *\n * For directives that require setting their part value asynchronously, they\n * should extend `AsyncDirective` and call `this.setValue()`.\n *\n * @param part Part to set\n * @param value Value to set\n * @param index For `AttributePart`s, the index to set\n * @param directiveParent Used internally; should not be set by user\n */\nexport const setChildPartValue = <T extends ChildPart>(\n  part: T,\n  value: unknown,\n  directiveParent: DirectiveParent = part\n): T => {\n  part._$setValue(value, directiveParent);\n  return part;\n};\n\n// A sentinal value that can never appear as a part value except when set by\n// live(). Used to force a dirty-check to fail and cause a re-render.\nconst RESET_VALUE = {};\n\n/**\n * Sets the committed value of a ChildPart directly without triggering the\n * commit stage of the part.\n *\n * This is useful in cases where a directive needs to update the part such\n * that the next update detects a value change or not. When value is omitted,\n * the next update will be guaranteed to be detected as a change.\n *\n * @param part\n * @param value\n */\nexport const setCommittedValue = (part: Part, value: unknown = RESET_VALUE) =>\n  (part._$committedValue = value);\n\n/**\n * Returns the committed value of a ChildPart.\n *\n * The committed value is used for change detection and efficient updates of\n * the part. It can differ from the value set by the template or directive in\n * cases where the template value is transformed before being commited.\n *\n * - `TemplateResult`s are committed as a `TemplateInstance`\n * - Iterables are committed as `Array<ChildPart>`\n * - All other types are committed as the template value or value returned or\n *   set by a directive.\n *\n * @param part\n */\nexport const getCommittedValue = (part: ChildPart) => part._$committedValue;\n\n/**\n * Removes a ChildPart from the DOM, including any of its content.\n *\n * @param part The Part to remove\n */\nexport const removePart = (part: ChildPart) => {\n  part._$notifyConnectionChanged?.(false, true);\n  let start: ChildNode | null = part._$startNode;\n  const end: ChildNode | null = wrap(part._$endNode!).nextSibling;\n  while (start !== end) {\n    const n: ChildNode | null = wrap(start!).nextSibling;\n    (wrap(start!) as ChildNode).remove();\n    start = n;\n  }\n};\n\nexport const clearPart = (part: ChildPart) => {\n  part._$clear();\n};\n"],"names":["_ChildPart","ChildPart","_$LH","isPrimitive","value","TemplateResultType","HTML","SVG","isTemplateResult","type","undefined","isDirectiveResult","getDirectiveClass","isSingleExpression","part","strings","createMarker","document","createComment","insertPart","containerPart","refPart","container","_$startNode","parentNode","refNode","_$endNode","startNode","insertBefore","endNode","options","nextSibling","oldParent","_$parent","parentChanged","newConnectionState","_a","_$reparentDisconnectables","call","_$notifyConnectionChanged","_$isConnected","start","n","setChildPartValue","directiveParent","_$setValue","RESET_VALUE","setCommittedValue","_$committedValue","getCommittedValue","removePart","end","remove","clearPart","_$clear"],"mappings":";;;;;GAeA,MAAOA,EAAYC,GAAaC,EAkBnBC,EAAeC,GAChB,OAAVA,GAAmC,iBAATA,GAAqC,mBAATA,EAE3CC,EAAqB,CAChCC,KAAM,EACNC,IAAK,GASMC,EAAmB,CAC9BJ,EACAK,SAESC,IAATD,OAEkDC,KAA7CN,aAAK,EAALA,EAAuC,aACvCA,aAAK,EAALA,EAAuC,cAAMK,EAKvCE,EAAqBP,QAEoBM,KAAnDN,aAAA,EAAAA,EAA6C,iBAKnCQ,EAAqBR,GAE/BA,aAAK,EAALA,EAA6C,gBAUnCS,EAAsBC,QACOJ,IAAvCI,EAA2BC,QAExBC,EAAe,IAAMC,SAASC,cAAc,IAcrCC,EAAa,CACxBC,EACAC,EACAP,WAEA,MAAMQ,EAAiBF,EAAcG,KAAaC,WAE5CC,OACQf,IAAZW,EAAwBD,EAAcM,KAAYL,EAAQE,KAE5D,QAAab,IAATI,EAAoB,CACtB,MAAMa,EAAiBL,EAAWM,aAAaZ,IAAgBS,GACzDI,EAAeP,EAAWM,aAAaZ,IAAgBS,GAC7DX,EAAO,IAAIb,EACT0B,EACAE,EACAT,EACAA,EAAcU,QAEjB,KAAM,CACL,MAAMD,EAAef,EAAKY,KAAYK,YAChCC,EAAYlB,EAAKmB,KACjBC,EAAgBF,IAAcZ,EACpC,GAAIc,EAAe,CAUjB,IAAIC,EAT6B,QAAjCC,EAAAtB,EAAKuB,YAA4B,IAAAD,GAAAA,EAAAE,KAAAxB,EAAAM,GAKjCN,EAAKmB,KAAWb,OAMqBV,IAAnCI,EAAKyB,OACJJ,EAAqBf,EAAcoB,QAClCR,EAAWQ,MAEb1B,EAAKyB,KAA0BJ,EAElC,CACD,GAAIN,IAAYJ,GAAWS,EAAe,CACxC,IAAIO,EAAqB3B,EAAKS,KAC9B,KAAOkB,IAAUZ,GAAS,CACxB,MAAMa,EAAsBD,EAAQV,YAC/BT,EAAWM,aAAaa,EAAQhB,GACrCgB,EAAQC,CACT,CACF,CACF,CAED,OAAO5B,CAAI,EAmBA6B,EAAoB,CAC/B7B,EACAV,EACAwC,EAAmC9B,KAEnCA,EAAK+B,KAAWzC,EAAOwC,GAChB9B,GAKHgC,EAAc,CAAA,EAaPC,EAAoB,CAACjC,EAAYV,EAAiB0C,IAC5DhC,EAAKkC,KAAmB5C,EAgBd6C,EAAqBnC,GAAoBA,EAAKkC,KAO9CE,EAAcpC,UACK,QAA9BsB,EAAAtB,EAAKyB,YAAyB,IAAAH,GAAAA,EAAAE,KAAAxB,GAAG,GAAO,GACxC,IAAI2B,EAA0B3B,EAAKS,KACnC,MAAM4B,EAA6BrC,EAAKY,KAAYK,YACpD,KAAOU,IAAUU,GAAK,CACpB,MAAMT,EAA2BD,EAAQV,YACnCU,EAAsBW,SAC5BX,EAAQC,CACT,GAGUW,EAAavC,IACxBA,EAAKwC,MAAS"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/node/directive.js b/front_end/third_party/lit-html/package/node/directive.js
new file mode 100644
index 0000000000000000000000000000000000000000..55f5580bb34b4cec7197939ee70b97672ca4460b
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directive.js
@@ -0,0 +1,7 @@
+/**
+ * @license
+ * Copyright 2017 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */
+const t={ATTRIBUTE:1,CHILD:2,PROPERTY:3,BOOLEAN_ATTRIBUTE:4,EVENT:5,ELEMENT:6},e=t=>(...e)=>({_$litDirective$:t,values:e});class i{constructor(t){}get _$AU(){return this._$AM._$AU}_$AT(t,e,i){this._$Ct=t,this._$AM=e,this._$Ci=i}_$AS(t,e){return this.update(t,e)}update(t,e){return this.render(...e)}}export{i as Directive,t as PartType,e as directive};
+//# sourceMappingURL=directive.js.map




diff --git a/front_end/third_party/lit-html/package/node/directive.js.map b/front_end/third_party/lit-html/package/node/directive.js.map
new file mode 100644
index 0000000000000000000000000000000000000000..12c082b4e2dad9cdebeb7733e0566d9d1889668d
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directive.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"directive.js","sources":["../src/directive.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {Disconnectable, Part} from './lit-html.js';\n\nexport {\n  AttributePart,\n  BooleanAttributePart,\n  ChildPart,\n  ElementPart,\n  EventPart,\n  Part,\n  PropertyPart,\n} from './lit-html.js';\n\nexport interface DirectiveClass {\n  new (part: PartInfo): Directive;\n}\n\n/**\n * This utility type extracts the signature of a directive class's render()\n * method so we can use it for the type of the generated directive function.\n */\nexport type DirectiveParameters<C extends Directive> = Parameters<C['render']>;\n\n/**\n * A generated directive function doesn't evaluate the directive, but just\n * returns a DirectiveResult object that captures the arguments.\n */\nexport interface DirectiveResult<C extends DirectiveClass = DirectiveClass> {\n  /**\n   * This property needs to remain unminified.\n   * @internal */\n  ['_$litDirective$']: C;\n  /** @internal */\n  values: DirectiveParameters<InstanceType<C>>;\n}\n\nexport const PartType = {\n  ATTRIBUTE: 1,\n  CHILD: 2,\n  PROPERTY: 3,\n  BOOLEAN_ATTRIBUTE: 4,\n  EVENT: 5,\n  ELEMENT: 6,\n} as const;\n\nexport type PartType = typeof PartType[keyof typeof PartType];\n\nexport interface ChildPartInfo {\n  readonly type: typeof PartType.CHILD;\n}\n\nexport interface AttributePartInfo {\n  readonly type:\n    | typeof PartType.ATTRIBUTE\n    | typeof PartType.PROPERTY\n    | typeof PartType.BOOLEAN_ATTRIBUTE\n    | typeof PartType.EVENT;\n  readonly strings?: ReadonlyArray<string>;\n  readonly name: string;\n  readonly tagName: string;\n}\n\nexport interface ElementPartInfo {\n  readonly type: typeof PartType.ELEMENT;\n}\n\n/**\n * Information about the part a directive is bound to.\n *\n * This is useful for checking that a directive is attached to a valid part,\n * such as with directive that can only be used on attribute bindings.\n */\nexport type PartInfo = ChildPartInfo | AttributePartInfo | ElementPartInfo;\n\n/**\n * Creates a user-facing directive function from a Directive class. This\n * function has the same parameters as the directive's render() method.\n */\nexport const directive =\n  <C extends DirectiveClass>(c: C) =>\n  (...values: DirectiveParameters<InstanceType<C>>): DirectiveResult<C> => ({\n    // This property needs to remain unminified.\n    ['_$litDirective$']: c,\n    values,\n  });\n\n/**\n * Base class for creating custom directives. Users should extend this class,\n * implement `render` and/or `update`, and then pass their subclass to\n * `directive`.\n */\nexport abstract class Directive implements Disconnectable {\n  //@internal\n  __part!: Part;\n  //@internal\n  __attributeIndex: number | undefined;\n  //@internal\n  __directive?: Directive;\n\n  //@internal\n  _$parent!: Disconnectable;\n\n  // These will only exist on the AsyncDirective subclass\n  //@internal\n  _$disconnectableChildren?: Set<Disconnectable>;\n  // This property needs to remain unminified.\n  //@internal\n  ['_$notifyDirectiveConnectionChanged']?(isConnected: boolean): void;\n\n  constructor(_partInfo: PartInfo) {}\n\n  // See comment in Disconnectable interface for why this is a getter\n  get _$isConnected() {\n    return this._$parent._$isConnected;\n  }\n\n  /** @internal */\n  _$initialize(\n    part: Part,\n    parent: Disconnectable,\n    attributeIndex: number | undefined\n  ) {\n    this.__part = part;\n    this._$parent = parent;\n    this.__attributeIndex = attributeIndex;\n  }\n  /** @internal */\n  _$resolve(part: Part, props: Array<unknown>): unknown {\n    return this.update(part, props);\n  }\n\n  abstract render(...props: Array<unknown>): unknown;\n\n  update(_part: Part, props: Array<unknown>): unknown {\n    return this.render(...props);\n  }\n}\n"],"names":["PartType","ATTRIBUTE","CHILD","PROPERTY","BOOLEAN_ATTRIBUTE","EVENT","ELEMENT","directive","c","values","_$litDirective$","Directive","constructor","_partInfo","_$isConnected","this","_$parent","_$initialize","part","parent","attributeIndex","__part","__attributeIndex","_$resolve","props","update","_part","render"],"mappings":";;;;;AAyCa,MAAAA,EAAW,CACtBC,UAAW,EACXC,MAAO,EACPC,SAAU,EACVC,kBAAmB,EACnBC,MAAO,EACPC,QAAS,GAoCEC,EACgBC,GAC3B,IAAIC,KAAsE,CAExEC,gBAAqBF,EACrBC,iBAQkBE,EAkBpBC,YAAYC,GAAuB,CAG/BC,WACF,OAAOC,KAAKC,KAASF,IACtB,CAGDG,KACEC,EACAC,EACAC,GAEAL,KAAKM,KAASH,EACdH,KAAKC,KAAWG,EAChBJ,KAAKO,KAAmBF,CACzB,CAEDG,KAAUL,EAAYM,GACpB,OAAOT,KAAKU,OAAOP,EAAMM,EAC1B,CAIDC,OAAOC,EAAaF,GAClB,OAAOT,KAAKY,UAAUH,EACvB"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/node/directives/async-append.js b/front_end/third_party/lit-html/package/node/directives/async-append.js
new file mode 100644
index 0000000000000000000000000000000000000000..1f1dd0eea86d0215b4a9ee0c6551977ae487cb48
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/async-append.js
@@ -0,0 +1,7 @@
+import{directive as r,PartType as e}from"../directive.js";import{AsyncReplaceDirective as s}from"./async-replace.js";import{clearPart as t,insertPart as o,setChildPartValue as i}from"../directive-helpers.js";
+/**
+ * @license
+ * Copyright 2017 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */const c=r(class extends s{constructor(r){if(super(r),r.type!==e.CHILD)throw Error("asyncAppend can only be used in child expressions")}update(r,e){return this._$Ctt=r,super.update(r,e)}commitValue(r,e){0===e&&t(this._$Ctt);const s=o(this._$Ctt);i(s,r)}});export{c as asyncAppend};
+//# sourceMappingURL=async-append.js.map




diff --git a/front_end/third_party/lit-html/package/node/directives/async-append.js.map b/front_end/third_party/lit-html/package/node/directives/async-append.js.map
new file mode 100644
index 0000000000000000000000000000000000000000..e24bc5e3449513f2665568a0e5187c7f80160831
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/async-append.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"async-append.js","sources":["../../src/directives/async-append.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {ChildPart} from '../lit-html.js';\nimport {\n  directive,\n  DirectiveParameters,\n  PartInfo,\n  PartType,\n} from '../directive.js';\nimport {AsyncReplaceDirective} from './async-replace.js';\nimport {\n  clearPart,\n  insertPart,\n  setChildPartValue,\n} from '../directive-helpers.js';\n\nclass AsyncAppendDirective extends AsyncReplaceDirective {\n  private __childPart!: ChildPart;\n\n  // Override AsyncReplace to narrow the allowed part type to ChildPart only\n  constructor(partInfo: PartInfo) {\n    super(partInfo);\n    if (partInfo.type !== PartType.CHILD) {\n      throw new Error('asyncAppend can only be used in child expressions');\n    }\n  }\n\n  // Override AsyncReplace to save the part since we need to append into it\n  override update(part: ChildPart, params: DirectiveParameters<this>) {\n    this.__childPart = part;\n    return super.update(part, params);\n  }\n\n  // Override AsyncReplace to append rather than replace\n  protected override commitValue(value: unknown, index: number) {\n    // When we get the first value, clear the part. This lets the\n    // previous value display until we can replace it.\n    if (index === 0) {\n      clearPart(this.__childPart);\n    }\n    // Create and insert a new part and set its value to the next value\n    const newPart = insertPart(this.__childPart);\n    setChildPartValue(newPart, value);\n  }\n}\n\n/**\n * A directive that renders the items of an async iterable[1], appending new\n * values after previous values, similar to the built-in support for iterables.\n * This directive is usable only in child expressions.\n *\n * Async iterables are objects with a [Symbol.asyncIterator] method, which\n * returns an iterator who's `next()` method returns a Promise. When a new\n * value is available, the Promise resolves and the value is appended to the\n * Part controlled by the directive. If another value other than this\n * directive has been set on the Part, the iterable will no longer be listened\n * to and new values won't be written to the Part.\n *\n * [1]: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/for-await...of\n *\n * @param value An async iterable\n * @param mapper An optional function that maps from (value, index) to another\n *     value. Useful for generating templates for each item in the iterable.\n */\nexport const asyncAppend = directive(AsyncAppendDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {AsyncAppendDirective};\n"],"names":["asyncAppend","directive","AsyncReplaceDirective","constructor","partInfo","super","type","PartType","CHILD","Error","update","part","params","this","__childPart","commitValue","value","index","clearPart","newPart","insertPart","setChildPartValue"],"mappings":";;;;;SAoEaA,EAAcC,EAhD3B,cAAmCC,EAIjCC,YAAYC,GAEV,GADAC,MAAMD,GACFA,EAASE,OAASC,EAASC,MAC7B,MAAUC,MAAM,oDAEnB,CAGQC,OAAOC,EAAiBC,GAE/B,OADAC,KAAKC,MAAcH,EACZN,MAAMK,OAAOC,EAAMC,EAC3B,CAGkBG,YAAYC,EAAgBC,GAG/B,IAAVA,GACFC,EAAUL,KAAKC,OAGjB,MAAMK,EAAUC,EAAWP,KAAKC,OAChCO,EAAkBF,EAASH,EAC5B"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/node/directives/async-replace.js b/front_end/third_party/lit-html/package/node/directives/async-replace.js
new file mode 100644
index 0000000000000000000000000000000000000000..2004fa85246eece06298d8cfc9ca84a60bada31d
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/async-replace.js
@@ -0,0 +1,7 @@
+import{noChange as t}from"../lit-html.js";import{AsyncDirective as i}from"../async-directive.js";import{PseudoWeakRef as s,Pauser as r,forAwaitOf as e}from"./private-async-helpers.js";import{directive as n}from"../directive.js";
+/**
+ * @license
+ * Copyright 2017 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */class o extends i{constructor(){super(...arguments),this._$CK=new s(this),this._$CX=new r}render(i,s){return t}update(i,[s,r]){if(this.isConnected||this.disconnected(),s===this._$CJ)return;this._$CJ=s;let n=0;const{_$CK:o,_$CX:h}=this;return e(s,(async t=>{for(;h.get();)await h.get();const i=o.deref();if(void 0!==i){if(i._$CJ!==s)return!1;void 0!==r&&(t=r(t,n)),i.commitValue(t,n),n++}return!0})),t}commitValue(t,i){this.setValue(t)}disconnected(){this._$CK.disconnect(),this._$CX.pause()}reconnected(){this._$CK.reconnect(this),this._$CX.resume()}}const h=n(o);export{o as AsyncReplaceDirective,h as asyncReplace};
+//# sourceMappingURL=async-replace.js.map




diff --git a/front_end/third_party/lit-html/package/node/directives/async-replace.js.map b/front_end/third_party/lit-html/package/node/directives/async-replace.js.map
new file mode 100644
index 0000000000000000000000000000000000000000..13bf2746e0658a25cd4c7fc8a31e6fb8207a21b9
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/async-replace.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"async-replace.js","sources":["../../src/directives/async-replace.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {ChildPart, noChange} from '../lit-html.js';\nimport {\n  AsyncDirective,\n  directive,\n  DirectiveParameters,\n} from '../async-directive.js';\nimport {Pauser, PseudoWeakRef, forAwaitOf} from './private-async-helpers.js';\n\ntype Mapper<T> = (v: T, index?: number) => unknown;\n\nexport class AsyncReplaceDirective extends AsyncDirective {\n  private __value?: AsyncIterable<unknown>;\n  private __weakThis = new PseudoWeakRef(this);\n  private __pauser = new Pauser();\n\n  // @ts-expect-error value not used, but we want a nice parameter for docs\n  // eslint-disable-next-line @typescript-eslint/no-unused-vars\n  render<T>(value: AsyncIterable<T>, _mapper?: Mapper<T>) {\n    return noChange;\n  }\n\n  override update(\n    _part: ChildPart,\n    [value, mapper]: DirectiveParameters<this>\n  ) {\n    // If our initial render occurs while disconnected, ensure that the pauser\n    // and weakThis are in the disconnected state\n    if (!this.isConnected) {\n      this.disconnected();\n    }\n    // If we've already set up this particular iterable, we don't need\n    // to do anything.\n    if (value === this.__value) {\n      return;\n    }\n    this.__value = value;\n    let i = 0;\n    const {__weakThis: weakThis, __pauser: pauser} = this;\n    // Note, the callback avoids closing over `this` so that the directive\n    // can be gc'ed before the promise resolves; instead `this` is retrieved\n    // from `weakThis`, which can break the hard reference in the closure when\n    // the directive disconnects\n    forAwaitOf(value, async (v: unknown) => {\n      // The while loop here handles the case that the connection state\n      // thrashes, causing the pauser to resume and then get re-paused\n      while (pauser.get()) {\n        await pauser.get();\n      }\n      // If the callback gets here and there is no `this`, it means that the\n      // directive has been disconnected and garbage collected and we don't\n      // need to do anything else\n      const _this = weakThis.deref();\n      if (_this !== undefined) {\n        // Check to make sure that value is the still the current value of\n        // the part, and if not bail because a new value owns this part\n        if (_this.__value !== value) {\n          return false;\n        }\n\n        // As a convenience, because functional-programming-style\n        // transforms of iterables and async iterables requires a library,\n        // we accept a mapper function. This is especially convenient for\n        // rendering a template for each item.\n        if (mapper !== undefined) {\n          v = mapper(v, i);\n        }\n\n        _this.commitValue(v, i);\n        i++;\n      }\n      return true;\n    });\n    return noChange;\n  }\n\n  // Override point for AsyncAppend to append rather than replace\n  protected commitValue(value: unknown, _index: number) {\n    this.setValue(value);\n  }\n\n  override disconnected() {\n    this.__weakThis.disconnect();\n    this.__pauser.pause();\n  }\n\n  override reconnected() {\n    this.__weakThis.reconnect(this);\n    this.__pauser.resume();\n  }\n}\n\n/**\n * A directive that renders the items of an async iterable[1], replacing\n * previous values with new values, so that only one value is ever rendered\n * at a time. This directive may be used in any expression type.\n *\n * Async iterables are objects with a `[Symbol.asyncIterator]` method, which\n * returns an iterator who's `next()` method returns a Promise. When a new\n * value is available, the Promise resolves and the value is rendered to the\n * Part controlled by the directive. If another value other than this\n * directive has been set on the Part, the iterable will no longer be listened\n * to and new values won't be written to the Part.\n *\n * [1]: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/for-await...of\n *\n * @param value An async iterable\n * @param mapper An optional function that maps from (value, index) to another\n *     value. Useful for generating templates for each item in the iterable.\n */\nexport const asyncReplace = directive(AsyncReplaceDirective);\n"],"names":["AsyncReplaceDirective","AsyncDirective","constructor","this","__weakThis","PseudoWeakRef","__pauser","Pauser","render","value","_mapper","noChange","update","_part","mapper","isConnected","disconnected","__value","i","weakThis","pauser","forAwaitOf","async","v","get","_this","deref","undefined","commitValue","_index","setValue","disconnect","pause","reconnected","reconnect","resume","asyncReplace","directive"],"mappings":";;;;;GAgBM,MAAOA,UAA8BC,EAA3CC,kCAEUC,KAAAC,KAAa,IAAIC,EAAcF,MAC/BA,KAAAG,KAAW,IAAIC,CA4ExB,CAxECC,OAAUC,EAAyBC,GACjC,OAAOC,CACR,CAEQC,OACPC,GACCJ,EAAOK,IASR,GALKX,KAAKY,aACRZ,KAAKa,eAIHP,IAAUN,KAAKc,KACjB,OAEFd,KAAKc,KAAUR,EACf,IAAIS,EAAI,EACR,MAAOd,KAAYe,EAAUb,KAAUc,GAAUjB,KAmCjD,OA9BAkB,EAAWZ,GAAOa,MAAOC,IAGvB,KAAOH,EAAOI,aACNJ,EAAOI,MAKf,MAAMC,EAAQN,EAASO,QACvB,QAAcC,IAAVF,EAAqB,CAGvB,GAAIA,EAAMR,OAAYR,EACpB,OAAO,OAOMkB,IAAXb,IACFS,EAAIT,EAAOS,EAAGL,IAGhBO,EAAMG,YAAYL,EAAGL,GACrBA,GACD,CACD,OAAO,CAAI,IAENP,CACR,CAGSiB,YAAYnB,EAAgBoB,GACpC1B,KAAK2B,SAASrB,EACf,CAEQO,eACPb,KAAKC,KAAW2B,aAChB5B,KAAKG,KAAS0B,OACf,CAEQC,cACP9B,KAAKC,KAAW8B,UAAU/B,MAC1BA,KAAKG,KAAS6B,QACf,QAqBUC,EAAeC,EAAUrC"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/node/directives/cache.js b/front_end/third_party/lit-html/package/node/directives/cache.js
new file mode 100644
index 0000000000000000000000000000000000000000..9feae196384fb423dfdcaf2301539c9540518a72
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/cache.js
@@ -0,0 +1,7 @@
+import{render as t,nothing as i}from"../lit-html.js";import{directive as s,Directive as e}from"../directive.js";import{isTemplateResult as o,getCommittedValue as r,setCommittedValue as h,insertPart as n,clearPart as c}from"../directive-helpers.js";
+/**
+ * @license
+ * Copyright 2017 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */const d=s(class extends e{constructor(t){super(t),this.et=new WeakMap}render(t){return[t]}update(s,[e]){if(o(this.it)&&(!o(e)||this.it.strings!==e.strings)){const e=r(s).pop();let o=this.et.get(this.it.strings);if(void 0===o){const s=document.createDocumentFragment();o=t(i,s),o.setConnected(!1),this.et.set(this.it.strings,o)}h(o,[e]),n(o,void 0,e)}if(o(e)){if(!o(this.it)||this.it.strings!==e.strings){const t=this.et.get(e.strings);if(void 0!==t){const i=r(t).pop();c(s),n(s,void 0,i),h(s,[i])}}this.it=e}else this.it=void 0;return this.render(e)}});export{d as cache};
+//# sourceMappingURL=cache.js.map




diff --git a/front_end/third_party/lit-html/package/node/directives/cache.js.map b/front_end/third_party/lit-html/package/node/directives/cache.js.map
new file mode 100644
index 0000000000000000000000000000000000000000..fbbf589afee1914cb67bea7a3234c9e7cc94ca6d
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/cache.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"cache.js","sources":["../../src/directives/cache.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {\n  TemplateResult,\n  ChildPart,\n  RootPart,\n  render,\n  nothing,\n} from '../lit-html.js';\nimport {\n  directive,\n  Directive,\n  DirectiveParameters,\n  PartInfo,\n} from '../directive.js';\nimport {\n  clearPart,\n  getCommittedValue,\n  insertPart,\n  isTemplateResult,\n  setCommittedValue,\n} from '../directive-helpers.js';\n\nclass CacheDirective extends Directive {\n  private _templateCache = new WeakMap<TemplateStringsArray, RootPart>();\n  private _value?: TemplateResult;\n\n  constructor(partInfo: PartInfo) {\n    super(partInfo);\n  }\n\n  render(v: unknown) {\n    // Return an array of the value to induce lit-html to create a ChildPart\n    // for the value that we can move into the cache.\n    return [v];\n  }\n\n  override update(containerPart: ChildPart, [v]: DirectiveParameters<this>) {\n    // If the previous value is a TemplateResult and the new value is not,\n    // or is a different Template as the previous value, move the child part\n    // into the cache.\n    if (\n      isTemplateResult(this._value) &&\n      (!isTemplateResult(v) || this._value.strings !== v.strings)\n    ) {\n      // This is always an array because we return [v] in render()\n      const partValue = getCommittedValue(containerPart) as Array<ChildPart>;\n      const childPart = partValue.pop()!;\n      let cachedContainerPart = this._templateCache.get(this._value.strings);\n      if (cachedContainerPart === undefined) {\n        const fragment = document.createDocumentFragment();\n        cachedContainerPart = render(nothing, fragment);\n        cachedContainerPart.setConnected(false);\n        this._templateCache.set(this._value.strings, cachedContainerPart);\n      }\n      // Move into cache\n      setCommittedValue(cachedContainerPart, [childPart]);\n      insertPart(cachedContainerPart, undefined, childPart);\n    }\n    // If the new value is a TemplateResult and the previous value is not,\n    // or is a different Template as the previous value, restore the child\n    // part from the cache.\n    if (isTemplateResult(v)) {\n      if (!isTemplateResult(this._value) || this._value.strings !== v.strings) {\n        const cachedContainerPart = this._templateCache.get(v.strings);\n        if (cachedContainerPart !== undefined) {\n          // Move the cached part back into the container part value\n          const partValue = getCommittedValue(\n            cachedContainerPart\n          ) as Array<ChildPart>;\n          const cachedPart = partValue.pop()!;\n          // Move cached part back into DOM\n          clearPart(containerPart);\n          insertPart(containerPart, undefined, cachedPart);\n          setCommittedValue(containerPart, [cachedPart]);\n        }\n      }\n      this._value = v;\n    } else {\n      this._value = undefined;\n    }\n    return this.render(v);\n  }\n}\n\n/**\n * Enables fast switching between multiple templates by caching the DOM nodes\n * and TemplateInstances produced by the templates.\n *\n * Example:\n *\n * ```js\n * let checked = false;\n *\n * html`\n *   ${cache(checked ? html`input is checked` : html`input is not checked`)}\n * `\n * ```\n */\nexport const cache = directive(CacheDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {CacheDirective};\n"],"names":["cache","directive","Directive","constructor","partInfo","super","this","_templateCache","WeakMap","render","v","update","containerPart","isTemplateResult","_value","strings","childPart","getCommittedValue","pop","cachedContainerPart","get","undefined","fragment","document","createDocumentFragment","nothing","setConnected","set","setCommittedValue","insertPart","cachedPart","clearPart"],"mappings":";;;;;SAuGaA,EAAQC,EA5ErB,cAA6BC,EAI3BC,YAAYC,GACVC,MAAMD,GAJAE,KAAAC,GAAiB,IAAIC,OAK5B,CAEDC,OAAOC,GAGL,MAAO,CAACA,EACT,CAEQC,OAAOC,GAA2BF,IAIzC,GACEG,EAAiBP,KAAKQ,OACpBD,EAAiBH,IAAMJ,KAAKQ,GAAOC,UAAYL,EAAEK,SACnD,CAEA,MACMC,EADYC,EAAkBL,GACRM,MAC5B,IAAIC,EAAsBb,KAAKC,GAAea,IAAId,KAAKQ,GAAOC,SAC9D,QAA4BM,IAAxBF,EAAmC,CACrC,MAAMG,EAAWC,SAASC,yBAC1BL,EAAsBV,EAAOgB,EAASH,GACtCH,EAAoBO,cAAa,GACjCpB,KAAKC,GAAeoB,IAAIrB,KAAKQ,GAAOC,QAASI,EAC9C,CAEDS,EAAkBT,EAAqB,CAACH,IACxCa,EAAWV,OAAqBE,EAAWL,EAC5C,CAID,GAAIH,EAAiBH,GAAI,CACvB,IAAKG,EAAiBP,KAAKQ,KAAWR,KAAKQ,GAAOC,UAAYL,EAAEK,QAAS,CACvE,MAAMI,EAAsBb,KAAKC,GAAea,IAAIV,EAAEK,SACtD,QAA4BM,IAAxBF,EAAmC,CAErC,MAGMW,EAHYb,EAChBE,GAE2BD,MAE7Ba,EAAUnB,GACViB,EAAWjB,OAAeS,EAAWS,GACrCF,EAAkBhB,EAAe,CAACkB,GACnC,CACF,CACDxB,KAAKQ,GAASJ,CACf,MACCJ,KAAKQ,QAASO,EAEhB,OAAOf,KAAKG,OAAOC,EACpB"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/node/directives/choose.js b/front_end/third_party/lit-html/package/node/directives/choose.js
new file mode 100644
index 0000000000000000000000000000000000000000..7d07c33e77ca0c07e595f4aecfdd68a65c5f7843
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/choose.js
@@ -0,0 +1,7 @@
+/**
+ * @license
+ * Copyright 2021 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */
+const o=(o,r,n)=>{for(const n of r)if(n[0]===o)return(0,n[1])();return null==n?void 0:n()};export{o as choose};
+//# sourceMappingURL=choose.js.map




diff --git a/front_end/third_party/lit-html/package/node/directives/choose.js.map b/front_end/third_party/lit-html/package/node/directives/choose.js.map
new file mode 100644
index 0000000000000000000000000000000000000000..ea3e0688c4ac66e84d347486fa4443aa33a8dc50
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/choose.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"choose.js","sources":["../../src/directives/choose.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n/**\n * Chooses and evaluates a template function from a list based on matching\n * the given `value` to a case.\n *\n * Cases are structured as `[caseValue, func]`. `value` is matched to\n * `caseValue` by strict equality. The first match is selected. Case values\n * can be of any type including primitives, objects, and symbols.\n *\n * This is similar to a switch statement, but as an expression and without\n * fallthrough.\n *\n * @example\n *\n * ```ts\n * render() {\n *   return html`\n *     ${choose(this.section, [\n *       ['home', () => html`<h1>Home</h1>`],\n *       ['about', () => html`<h1>About</h1>`]\n *     ],\n *     () => html`<h1>Error</h1>`)}\n *   `;\n * }\n * ```\n */\nexport const choose = <T, V>(\n  value: T,\n  cases: Array<[T, () => V]>,\n  defaultCase?: () => V\n) => {\n  for (const c of cases) {\n    const caseValue = c[0];\n    if (caseValue === value) {\n      const fn = c[1];\n      return fn();\n    }\n  }\n  return defaultCase?.();\n};\n"],"names":["choose","value","cases","defaultCase","c","fn"],"mappings":";;;;;AA+Ba,MAAAA,EAAS,CACpBC,EACAC,EACAC,KAEA,IAAK,MAAMC,KAAKF,EAEd,GADkBE,EAAE,KACFH,EAEhB,OAAOI,EADID,EAAE,MAIjB,OAAOD,aAAA,EAAAA,GAAe"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/node/directives/class-map.js b/front_end/third_party/lit-html/package/node/directives/class-map.js
new file mode 100644
index 0000000000000000000000000000000000000000..427d0485997231363cdfe58f3c9425839972a8d3
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/class-map.js
@@ -0,0 +1,7 @@
+import{noChange as t}from"../lit-html.js";import{directive as i,Directive as s,PartType as r}from"../directive.js";
+/**
+ * @license
+ * Copyright 2018 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */const o=i(class extends s{constructor(t){var i;if(super(t),t.type!==r.ATTRIBUTE||"class"!==t.name||(null===(i=t.strings)||void 0===i?void 0:i.length)>2)throw Error("`classMap()` can only be used in the `class` attribute and must be the only part in the attribute.")}render(t){return" "+Object.keys(t).filter((i=>t[i])).join(" ")+" "}update(i,[s]){var r,o;if(void 0===this.nt){this.nt=new Set,void 0!==i.strings&&(this.st=new Set(i.strings.join(" ").split(/\s/).filter((t=>""!==t))));for(const t in s)s[t]&&!(null===(r=this.st)||void 0===r?void 0:r.has(t))&&this.nt.add(t);return this.render(s)}const e=i.element.classList;this.nt.forEach((t=>{t in s||(e.remove(t),this.nt.delete(t))}));for(const t in s){const i=!!s[t];i===this.nt.has(t)||(null===(o=this.st)||void 0===o?void 0:o.has(t))||(i?(e.add(t),this.nt.add(t)):(e.remove(t),this.nt.delete(t)))}return t}});export{o as classMap};
+//# sourceMappingURL=class-map.js.map




diff --git a/front_end/third_party/lit-html/package/node/directives/class-map.js.map b/front_end/third_party/lit-html/package/node/directives/class-map.js.map
new file mode 100644
index 0000000000000000000000000000000000000000..57cfc7d12297a497d6256a2bb03cb6dbb5d87bd0
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/class-map.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"class-map.js","sources":["../../src/directives/class-map.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2018 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {AttributePart, noChange} from '../lit-html.js';\nimport {\n  directive,\n  Directive,\n  DirectiveParameters,\n  PartInfo,\n  PartType,\n} from '../directive.js';\n\n/**\n * A key-value set of class names to truthy values.\n */\nexport interface ClassInfo {\n  readonly [name: string]: string | boolean | number;\n}\n\nclass ClassMapDirective extends Directive {\n  /**\n   * Stores the ClassInfo object applied to a given AttributePart.\n   * Used to unset existing values when a new ClassInfo object is applied.\n   */\n  private _previousClasses?: Set<string>;\n  private _staticClasses?: Set<string>;\n\n  constructor(partInfo: PartInfo) {\n    super(partInfo);\n    if (\n      partInfo.type !== PartType.ATTRIBUTE ||\n      partInfo.name !== 'class' ||\n      (partInfo.strings?.length as number) > 2\n    ) {\n      throw new Error(\n        '`classMap()` can only be used in the `class` attribute ' +\n          'and must be the only part in the attribute.'\n      );\n    }\n  }\n\n  render(classInfo: ClassInfo) {\n    // Add spaces to ensure separation from static classes\n    return (\n      ' ' +\n      Object.keys(classInfo)\n        .filter((key) => classInfo[key])\n        .join(' ') +\n      ' '\n    );\n  }\n\n  override update(part: AttributePart, [classInfo]: DirectiveParameters<this>) {\n    // Remember dynamic classes on the first render\n    if (this._previousClasses === undefined) {\n      this._previousClasses = new Set();\n      if (part.strings !== undefined) {\n        this._staticClasses = new Set(\n          part.strings\n            .join(' ')\n            .split(/\\s/)\n            .filter((s) => s !== '')\n        );\n      }\n      for (const name in classInfo) {\n        if (classInfo[name] && !this._staticClasses?.has(name)) {\n          this._previousClasses.add(name);\n        }\n      }\n      return this.render(classInfo);\n    }\n\n    const classList = part.element.classList;\n\n    // Remove old classes that no longer apply\n    // We use forEach() instead of for-of so that we don't require down-level\n    // iteration.\n    this._previousClasses.forEach((name) => {\n      if (!(name in classInfo)) {\n        classList.remove(name);\n        this._previousClasses!.delete(name);\n      }\n    });\n\n    // Add or remove classes based on their classMap value\n    for (const name in classInfo) {\n      // We explicitly want a loose truthy check of `value` because it seems\n      // more convenient that '' and 0 are skipped.\n      const value = !!classInfo[name];\n      if (\n        value !== this._previousClasses.has(name) &&\n        !this._staticClasses?.has(name)\n      ) {\n        if (value) {\n          classList.add(name);\n          this._previousClasses.add(name);\n        } else {\n          classList.remove(name);\n          this._previousClasses.delete(name);\n        }\n      }\n    }\n    return noChange;\n  }\n}\n\n/**\n * A directive that applies dynamic CSS classes.\n *\n * This must be used in the `class` attribute and must be the only part used in\n * the attribute. It takes each property in the `classInfo` argument and adds\n * the property name to the element's `classList` if the property value is\n * truthy; if the property value is falsey, the property name is removed from\n * the element's `class`.\n *\n * For example `{foo: bar}` applies the class `foo` if the value of `bar` is\n * truthy.\n *\n * @param classInfo\n */\nexport const classMap = directive(ClassMapDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {ClassMapDirective};\n"],"names":["classMap","directive","Directive","constructor","partInfo","super","type","PartType","ATTRIBUTE","name","_a","strings","length","Error","render","classInfo","Object","keys","filter","key","join","update","part","undefined","this","_previousClasses","Set","_staticClasses","split","s","has","add","classList","element","forEach","remove","delete","value","_b","noChange"],"mappings":";;;;;SA2HaA,EAAWC,EArGxB,cAAgCC,EAQ9BC,YAAYC,SAEV,GADAC,MAAMD,GAEJA,EAASE,OAASC,EAASC,WACT,UAAlBJ,EAASK,eACRC,EAAAN,EAASO,8BAASC,QAAoB,EAEvC,MAAUC,MACR,qGAIL,CAEDC,OAAOC,GAEL,MACE,IACAC,OAAOC,KAAKF,GACTG,QAAQC,GAAQJ,EAAUI,KAC1BC,KAAK,KACR,GAEH,CAEQC,OAAOC,GAAsBP,YAEpC,QAA8BQ,IAA1BC,KAAKC,GAAgC,CACvCD,KAAKC,GAAmB,IAAIC,SACPH,IAAjBD,EAAKX,UACPa,KAAKG,GAAiB,IAAID,IACxBJ,EAAKX,QACFS,KAAK,KACLQ,MAAM,MACNV,QAAQW,GAAY,KAANA,MAGrB,IAAK,MAAMpB,KAAQM,EACbA,EAAUN,MAA+B,QAArBC,EAAAc,KAAKG,UAAgB,IAAAjB,OAAA,EAAAA,EAAAoB,IAAIrB,KAC/Ce,KAAKC,GAAiBM,IAAItB,GAG9B,OAAOe,KAAKV,OAAOC,EACpB,CAED,MAAMiB,EAAYV,EAAKW,QAAQD,UAK/BR,KAAKC,GAAiBS,SAASzB,IACvBA,KAAQM,IACZiB,EAAUG,OAAO1B,GACjBe,KAAKC,GAAkBW,OAAO3B,GAC/B,IAIH,IAAK,MAAMA,KAAQM,EAAW,CAG5B,MAAMsB,IAAUtB,EAAUN,GAExB4B,IAAUb,KAAKC,GAAiBK,IAAIrB,KACd,QAArB6B,EAAAd,KAAKG,UAAgB,IAAAW,OAAA,EAAAA,EAAAR,IAAIrB,MAEtB4B,GACFL,EAAUD,IAAItB,GACde,KAAKC,GAAiBM,IAAItB,KAE1BuB,EAAUG,OAAO1B,GACjBe,KAAKC,GAAiBW,OAAO3B,IAGlC,CACD,OAAO8B,CACR"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/node/directives/guard.js b/front_end/third_party/lit-html/package/node/directives/guard.js
new file mode 100644
index 0000000000000000000000000000000000000000..3813f9ef4262ee078451a0dfbe78dc3bd8336644
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/guard.js
@@ -0,0 +1,8 @@
+import{noChange as r}from"../lit-html.js";import{directive as t,Directive as s}from"../directive.js";
+/**
+ * @license
+ * Copyright 2018 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */
+const e={},i=t(class extends s{constructor(){super(...arguments),this.ot=e}render(r,t){return t()}update(t,[s,e]){if(Array.isArray(s)){if(Array.isArray(this.ot)&&this.ot.length===s.length&&s.every(((r,t)=>r===this.ot[t])))return r}else if(this.ot===s)return r;return this.ot=Array.isArray(s)?Array.from(s):s,this.render(s,e)}});export{i as guard};
+//# sourceMappingURL=guard.js.map




diff --git a/front_end/third_party/lit-html/package/node/directives/guard.js.map b/front_end/third_party/lit-html/package/node/directives/guard.js.map
new file mode 100644
index 0000000000000000000000000000000000000000..4eb9fb3b105c901941b6534b5567605d9148beff
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/guard.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"guard.js","sources":["../../src/directives/guard.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2018 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {noChange, Part} from '../lit-html.js';\nimport {directive, Directive, DirectiveParameters} from '../directive.js';\n\n// A sentinal that indicates guard() hasn't rendered anything yet\nconst initialValue = {};\n\nclass GuardDirective extends Directive {\n  private _previousValue: unknown = initialValue;\n\n  render(_value: unknown, f: () => unknown) {\n    return f();\n  }\n\n  override update(_part: Part, [value, f]: DirectiveParameters<this>) {\n    if (Array.isArray(value)) {\n      // Dirty-check arrays by item\n      if (\n        Array.isArray(this._previousValue) &&\n        this._previousValue.length === value.length &&\n        value.every((v, i) => v === (this._previousValue as Array<unknown>)[i])\n      ) {\n        return noChange;\n      }\n    } else if (this._previousValue === value) {\n      // Dirty-check non-arrays by identity\n      return noChange;\n    }\n\n    // Copy the value if it's an array so that if it's mutated we don't forget\n    // what the previous values were.\n    this._previousValue = Array.isArray(value) ? Array.from(value) : value;\n    const r = this.render(value, f);\n    return r;\n  }\n}\n\n/**\n * Prevents re-render of a template function until a single value or an array of\n * values changes.\n *\n * Values are checked against previous values with strict equality (`===`), and\n * so the check won't detect nested property changes inside objects or arrays.\n * Arrays values have each item checked against the previous value at the same\n * index with strict equality. Nested arrays are also checked only by strict\n * equality.\n *\n * Example:\n *\n * ```js\n * html`\n *   <div>\n *     ${guard([user.id, company.id], () => html`...`)}\n *   </div>\n * `\n * ```\n *\n * In this case, the template only rerenders if either `user.id` or `company.id`\n * changes.\n *\n * guard() is useful with immutable data patterns, by preventing expensive work\n * until data updates.\n *\n * Example:\n *\n * ```js\n * html`\n *   <div>\n *     ${guard([immutableItems], () => immutableItems.map(i => html`${i}`))}\n *   </div>\n * `\n * ```\n *\n * In this case, items are mapped over only when the array reference changes.\n *\n * @param value the value to check before re-rendering\n * @param f the template function\n */\nexport const guard = directive(GuardDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {GuardDirective};\n"],"names":["initialValue","guard","directive","Directive","constructor","this","_previousValue","render","_value","f","update","_part","value","Array","isArray","length","every","v","i","noChange","from"],"mappings":";;;;;;AAUA,MAAMA,EAAe,CAAA,EAyERC,EAAQC,EAvErB,cAA6BC,EAA7BC,kCACUC,KAAcC,GAAYN,CA2BnC,CAzBCO,OAAOC,EAAiBC,GACtB,OAAOA,GACR,CAEQC,OAAOC,GAAcC,EAAOH,IACnC,GAAII,MAAMC,QAAQF,IAEhB,GACEC,MAAMC,QAAQT,KAAKC,KACnBD,KAAKC,GAAeS,SAAWH,EAAMG,QACrCH,EAAMI,OAAM,CAACC,EAAGC,IAAMD,IAAOZ,KAAKC,GAAkCY,KAEpE,OAAOC,OAEJ,GAAId,KAAKC,KAAmBM,EAEjC,OAAOO,EAOT,OAFAd,KAAKC,GAAiBO,MAAMC,QAAQF,GAASC,MAAMO,KAAKR,GAASA,EACvDP,KAAKE,OAAOK,EAAOH,EAE9B"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/node/directives/if-defined.js b/front_end/third_party/lit-html/package/node/directives/if-defined.js
new file mode 100644
index 0000000000000000000000000000000000000000..4081d3e04a3e75c543f80c57996c051b328ad525
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/if-defined.js
@@ -0,0 +1,7 @@
+import{nothing as t}from"../lit-html.js";
+/**
+ * @license
+ * Copyright 2018 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */const l=l=>null!=l?l:t;export{l as ifDefined};
+//# sourceMappingURL=if-defined.js.map




diff --git a/front_end/third_party/lit-html/package/node/directives/if-defined.js.map b/front_end/third_party/lit-html/package/node/directives/if-defined.js.map
new file mode 100644
index 0000000000000000000000000000000000000000..1db437710a9c7ecc534682dc811a22213d7c2d0c
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/if-defined.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"if-defined.js","sources":["../../src/directives/if-defined.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2018 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {nothing} from '../lit-html.js';\n\n/**\n * For AttributeParts, sets the attribute if the value is defined and removes\n * the attribute if the value is undefined.\n *\n * For other part types, this directive is a no-op.\n */\nexport const ifDefined = <T>(value: T) => value ?? nothing;\n"],"names":["ifDefined","value","nothing"],"mappings":";;;;;GAca,MAAAA,EAAgBC,GAAaA,QAAAA,EAASC"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/node/directives/join.js b/front_end/third_party/lit-html/package/node/directives/join.js
new file mode 100644
index 0000000000000000000000000000000000000000..6428f2d1b51aa5ecf9fc5273788763a4df5c3ecf
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/join.js
@@ -0,0 +1,7 @@
+/**
+ * @license
+ * Copyright 2021 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */
+function*o(o,t){const f="function"==typeof t;if(void 0!==o){let i=-1;for(const n of o)i>-1&&(yield f?t(i):t),i++,yield n}}export{o as join};
+//# sourceMappingURL=join.js.map




diff --git a/front_end/third_party/lit-html/package/node/directives/join.js.map b/front_end/third_party/lit-html/package/node/directives/join.js.map
new file mode 100644
index 0000000000000000000000000000000000000000..3ef0756ee77d06e0d293d5650aaecb46f213b0ee
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/join.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"join.js","sources":["../../src/directives/join.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n/**\n * Returns an iterable containing the values in `items` interleaved with the\n * `joiner` value.\n *\n * @example\n *\n * ```ts\n * render() {\n *   return html`\n *     ${join(items, html`<span class=\"separator\">|</span>`)}\n *   `;\n * }\n */\nexport function join<I, J>(\n  items: Iterable<I> | undefined,\n  joiner: (index: number) => J\n): Iterable<I | J>;\nexport function join<I, J>(\n  items: Iterable<I> | undefined,\n  joiner: J\n): Iterable<I | J>;\nexport function* join<I, J>(items: Iterable<I> | undefined, joiner: J) {\n  const isFunction = typeof joiner === 'function';\n  if (items !== undefined) {\n    let i = -1;\n    for (const value of items) {\n      if (i > -1) {\n        yield isFunction ? joiner(i) : joiner;\n      }\n      i++;\n      yield value;\n    }\n  }\n}\n"],"names":["join","items","joiner","isFunction","undefined","i","value"],"mappings":";;;;;SA2BiBA,EAAWC,EAAgCC,GAC1D,MAAMC,EAA+B,mBAAXD,EAC1B,QAAcE,IAAVH,EAAqB,CACvB,IAAII,GAAK,EACT,IAAK,MAAMC,KAASL,EACdI,GAAK,UACDF,EAAaD,EAAOG,GAAKH,GAEjCG,UACMC,CAET,CACH"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/node/directives/keyed.js b/front_end/third_party/lit-html/package/node/directives/keyed.js
new file mode 100644
index 0000000000000000000000000000000000000000..43c6598075e13deafc21ff6a91ce0c1dabc8aac9
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/keyed.js
@@ -0,0 +1,7 @@
+import{nothing as r}from"../lit-html.js";import{directive as t,Directive as e}from"../directive.js";import{setCommittedValue as s}from"../directive-helpers.js";
+/**
+ * @license
+ * Copyright 2021 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */const i=t(class extends e{constructor(){super(...arguments),this.key=r}render(r,t){return this.key=r,t}update(r,[t,e]){return t!==this.key&&(s(r),this.key=t),e}});export{i as keyed};
+//# sourceMappingURL=keyed.js.map




diff --git a/front_end/third_party/lit-html/package/node/directives/keyed.js.map b/front_end/third_party/lit-html/package/node/directives/keyed.js.map
new file mode 100644
index 0000000000000000000000000000000000000000..f1e29300156b066787a7fbf2a329dcc412049c84
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/keyed.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"keyed.js","sources":["../../src/directives/keyed.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {nothing} from '../lit-html.js';\nimport {\n  directive,\n  Directive,\n  ChildPart,\n  DirectiveParameters,\n} from '../directive.js';\nimport {setCommittedValue} from '../directive-helpers.js';\n\nclass Keyed extends Directive {\n  key: unknown = nothing;\n\n  render(k: unknown, v: unknown) {\n    this.key = k;\n    return v;\n  }\n\n  override update(part: ChildPart, [k, v]: DirectiveParameters<this>) {\n    if (k !== this.key) {\n      // Clear the part before returning a value. The one-arg form of\n      // setCommittedValue sets the value to a sentinel which forces a\n      // commit the next render.\n      setCommittedValue(part);\n      this.key = k;\n    }\n    return v;\n  }\n}\n\n/**\n * Associates a renderable value with a unique key. When the key changes, the\n * previous DOM is removed and disposed before rendering the next value, even\n * if the value - such as a template - is the same.\n *\n * This is useful for forcing re-renders of stateful components, or working\n * with code that expects new data to generate new HTML elements, such as some\n * animation techniques.\n */\nexport const keyed = directive(Keyed);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {Keyed};\n"],"names":["keyed","directive","Directive","constructor","this","key","nothing","render","k","v","update","part","setCommittedValue"],"mappings":";;;;;SA4CaA,EAAQC,EA7BrB,cAAoBC,EAApBC,kCACEC,KAAGC,IAAYC,CAiBhB,CAfCC,OAAOC,EAAYC,GAEjB,OADAL,KAAKC,IAAMG,EACJC,CACR,CAEQC,OAAOC,GAAkBH,EAAGC,IAQnC,OAPID,IAAMJ,KAAKC,MAIbO,EAAkBD,GAClBP,KAAKC,IAAMG,GAENC,CACR"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/node/directives/live.js b/front_end/third_party/lit-html/package/node/directives/live.js
new file mode 100644
index 0000000000000000000000000000000000000000..dcc97db8558feed257a87f5dbed30a9130539ddc
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/live.js
@@ -0,0 +1,7 @@
+import{noChange as r,nothing as e}from"../lit-html.js";import{directive as i,Directive as t,PartType as n}from"../directive.js";import{isSingleExpression as o,setCommittedValue as s}from"../directive-helpers.js";
+/**
+ * @license
+ * Copyright 2020 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */const l=i(class extends t{constructor(r){if(super(r),r.type!==n.PROPERTY&&r.type!==n.ATTRIBUTE&&r.type!==n.BOOLEAN_ATTRIBUTE)throw Error("The `live` directive is not allowed on child or event bindings");if(!o(r))throw Error("`live` bindings can only contain a single expression")}render(r){return r}update(i,[t]){if(t===r||t===e)return t;const o=i.element,l=i.name;if(i.type===n.PROPERTY){if(t===o[l])return r}else if(i.type===n.BOOLEAN_ATTRIBUTE){if(!!t===o.hasAttribute(l))return r}else if(i.type===n.ATTRIBUTE&&o.getAttribute(l)===t+"")return r;return s(i),t}});export{l as live};
+//# sourceMappingURL=live.js.map




diff --git a/front_end/third_party/lit-html/package/node/directives/live.js.map b/front_end/third_party/lit-html/package/node/directives/live.js.map
new file mode 100644
index 0000000000000000000000000000000000000000..f94807f48d1c45b72e2ed3df4fe5c0eb2bb8137c
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/live.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"live.js","sources":["../../src/directives/live.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2020 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {AttributePart, noChange, nothing} from '../lit-html.js';\nimport {\n  directive,\n  Directive,\n  DirectiveParameters,\n  PartInfo,\n  PartType,\n} from '../directive.js';\nimport {isSingleExpression, setCommittedValue} from '../directive-helpers.js';\n\nclass LiveDirective extends Directive {\n  constructor(partInfo: PartInfo) {\n    super(partInfo);\n    if (\n      !(\n        partInfo.type === PartType.PROPERTY ||\n        partInfo.type === PartType.ATTRIBUTE ||\n        partInfo.type === PartType.BOOLEAN_ATTRIBUTE\n      )\n    ) {\n      throw new Error(\n        'The `live` directive is not allowed on child or event bindings'\n      );\n    }\n    if (!isSingleExpression(partInfo)) {\n      throw new Error('`live` bindings can only contain a single expression');\n    }\n  }\n\n  render(value: unknown) {\n    return value;\n  }\n\n  override update(part: AttributePart, [value]: DirectiveParameters<this>) {\n    if (value === noChange || value === nothing) {\n      return value;\n    }\n    const element = part.element;\n    const name = part.name;\n\n    if (part.type === PartType.PROPERTY) {\n      // eslint-disable-next-line @typescript-eslint/no-explicit-any\n      if (value === (element as any)[name]) {\n        return noChange;\n      }\n    } else if (part.type === PartType.BOOLEAN_ATTRIBUTE) {\n      if (!!value === element.hasAttribute(name)) {\n        return noChange;\n      }\n    } else if (part.type === PartType.ATTRIBUTE) {\n      if (element.getAttribute(name) === String(value)) {\n        return noChange;\n      }\n    }\n    // Resets the part's value, causing its dirty-check to fail so that it\n    // always sets the value.\n    setCommittedValue(part);\n    return value;\n  }\n}\n\n/**\n * Checks binding values against live DOM values, instead of previously bound\n * values, when determining whether to update the value.\n *\n * This is useful for cases where the DOM value may change from outside of\n * lit-html, such as with a binding to an `<input>` element's `value` property,\n * a content editable elements text, or to a custom element that changes it's\n * own properties or attributes.\n *\n * In these cases if the DOM value changes, but the value set through lit-html\n * bindings hasn't, lit-html won't know to update the DOM value and will leave\n * it alone. If this is not what you want--if you want to overwrite the DOM\n * value with the bound value no matter what--use the `live()` directive:\n *\n * ```js\n * html`<input .value=${live(x)}>`\n * ```\n *\n * `live()` performs a strict equality check against the live DOM value, and if\n * the new value is equal to the live value, does nothing. This means that\n * `live()` should not be used when the binding will cause a type conversion. If\n * you use `live()` with an attribute binding, make sure that only strings are\n * passed in, or the binding will update every render.\n */\nexport const live = directive(LiveDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {LiveDirective};\n"],"names":["live","directive","Directive","constructor","partInfo","super","type","PartType","PROPERTY","ATTRIBUTE","BOOLEAN_ATTRIBUTE","Error","isSingleExpression","render","value","update","part","noChange","nothing","element","name","hasAttribute","getAttribute","String","setCommittedValue"],"mappings":";;;;;SA2FaA,EAAOC,EA3EpB,cAA4BC,EAC1BC,YAAYC,GAEV,GADAC,MAAMD,GAGFA,EAASE,OAASC,EAASC,UAC3BJ,EAASE,OAASC,EAASE,WAC3BL,EAASE,OAASC,EAASG,kBAG7B,MAAUC,MACR,kEAGJ,IAAKC,EAAmBR,GACtB,MAAUO,MAAM,uDAEnB,CAEDE,OAAOC,GACL,OAAOA,CACR,CAEQC,OAAOC,GAAsBF,IACpC,GAAIA,IAAUG,GAAYH,IAAUI,EAClC,OAAOJ,EAET,MAAMK,EAAUH,EAAKG,QACfC,EAAOJ,EAAKI,KAElB,GAAIJ,EAAKV,OAASC,EAASC,UAEzB,GAAIM,IAAWK,EAAgBC,GAC7B,OAAOH,OAEJ,GAAID,EAAKV,OAASC,EAASG,mBAChC,KAAMI,IAAUK,EAAQE,aAAaD,GACnC,OAAOH,OAEJ,GAAID,EAAKV,OAASC,EAASE,WAC5BU,EAAQG,aAAaF,KAAiBN,EAAPS,GACjC,OAAON,EAMX,OADAO,EAAkBR,GACXF,CACR"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/node/directives/map.js b/front_end/third_party/lit-html/package/node/directives/map.js
new file mode 100644
index 0000000000000000000000000000000000000000..1f1ae5fd73c77547e09ad7f28745a145132a016b
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/map.js
@@ -0,0 +1,7 @@
+/**
+ * @license
+ * Copyright 2021 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */
+function*o(o,f){if(void 0!==o){let i=0;for(const t of o)yield f(t,i++)}}export{o as map};
+//# sourceMappingURL=map.js.map




diff --git a/front_end/third_party/lit-html/package/node/directives/map.js.map b/front_end/third_party/lit-html/package/node/directives/map.js.map
new file mode 100644
index 0000000000000000000000000000000000000000..d2c14c3472f445d546902978931ba8a2309c53fc
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/map.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"map.js","sources":["../../src/directives/map.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n/**\n * Returns an iterable containing the result of calling `f(value)` on each\n * value in `items`.\n *\n * @example\n *\n * ```ts\n * render() {\n *   return html`\n *     <ul>\n *       ${map(items, (i) => html`<li>${i}</li>`)}\n *     </ul>\n *   `;\n * }\n * ```\n */\nexport function* map<T>(\n  items: Iterable<T> | undefined,\n  f: (value: T, index: number) => unknown\n) {\n  if (items !== undefined) {\n    let i = 0;\n    for (const value of items) {\n      yield f(value, i++);\n    }\n  }\n}\n"],"names":["map","items","f","undefined","i","value"],"mappings":";;;;;SAsBiBA,EACfC,EACAC,GAEA,QAAcC,IAAVF,EAAqB,CACvB,IAAIG,EAAI,EACR,IAAK,MAAMC,KAASJ,QACZC,EAAEG,EAAOD,IAElB,CACH"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/node/directives/private-async-helpers.js b/front_end/third_party/lit-html/package/node/directives/private-async-helpers.js
new file mode 100644
index 0000000000000000000000000000000000000000..f4d381db49c222219a97e782e68a12aad8711ed8
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/private-async-helpers.js
@@ -0,0 +1,7 @@
+/**
+ * @license
+ * Copyright 2021 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */
+const t=async(t,s)=>{for await(const i of t)if(!1===await s(i))return};class s{constructor(t){this.Y=t}disconnect(){this.Y=void 0}reconnect(t){this.Y=t}deref(){return this.Y}}class i{constructor(){this.Z=void 0,this.q=void 0}get(){return this.Z}pause(){var t;null!==(t=this.Z)&&void 0!==t||(this.Z=new Promise((t=>this.q=t)))}resume(){var t;null===(t=this.q)||void 0===t||t.call(this),this.Z=this.q=void 0}}export{i as Pauser,s as PseudoWeakRef,t as forAwaitOf};
+//# sourceMappingURL=private-async-helpers.js.map




diff --git a/front_end/third_party/lit-html/package/node/directives/private-async-helpers.js.map b/front_end/third_party/lit-html/package/node/directives/private-async-helpers.js.map
new file mode 100644
index 0000000000000000000000000000000000000000..837e789a0dcd326b4dd26a5902cdfeb79056c1d3
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/private-async-helpers.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"private-async-helpers.js","sources":["../../src/directives/private-async-helpers.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n// Note, this module is not included in package exports so that it's private to\n// our first-party directives. If it ends up being useful, we can open it up and\n// export it.\n\n/**\n * Helper to iterate an AsyncIterable in its own closure.\n * @param iterable The iterable to iterate\n * @param callback The callback to call for each value. If the callback returns\n * `false`, the loop will be broken.\n */\nexport const forAwaitOf = async <T>(\n  iterable: AsyncIterable<T>,\n  callback: (value: T) => Promise<boolean>\n) => {\n  for await (const v of iterable) {\n    if ((await callback(v)) === false) {\n      return;\n    }\n  }\n};\n\n/**\n * Holds a reference to an instance that can be disconnected and reconnected,\n * so that a closure over the ref (e.g. in a then function to a promise) does\n * not strongly hold a ref to the instance. Approximates a WeakRef but must\n * be manually connected & disconnected to the backing instance.\n */\nexport class PseudoWeakRef<T> {\n  private _ref?: T;\n  constructor(ref: T) {\n    this._ref = ref;\n  }\n  /**\n   * Disassociates the ref with the backing instance.\n   */\n  disconnect() {\n    this._ref = undefined;\n  }\n  /**\n   * Reassociates the ref with the backing instance.\n   */\n  reconnect(ref: T) {\n    this._ref = ref;\n  }\n  /**\n   * Retrieves the backing instance (will be undefined when disconnected)\n   */\n  deref() {\n    return this._ref;\n  }\n}\n\n/**\n * A helper to pause and resume waiting on a condition in an async function\n */\nexport class Pauser {\n  private _promise?: Promise<void> = undefined;\n  private _resolve?: () => void = undefined;\n  /**\n   * When paused, returns a promise to be awaited; when unpaused, returns\n   * undefined. Note that in the microtask between the pauser being resumed\n   * an an await of this promise resolving, the pauser could be paused again,\n   * hence callers should check the promise in a loop when awaiting.\n   * @returns A promise to be awaited when paused or undefined\n   */\n  get() {\n    return this._promise;\n  }\n  /**\n   * Creates a promise to be awaited\n   */\n  pause() {\n    this._promise ??= new Promise((resolve) => (this._resolve = resolve));\n  }\n  /**\n   * Resolves the promise which may be awaited\n   */\n  resume() {\n    this._resolve?.();\n    this._promise = this._resolve = undefined;\n  }\n}\n"],"names":["forAwaitOf","async","iterable","callback","v","PseudoWeakRef","constructor","ref","this","_ref","disconnect","undefined","reconnect","deref","Pauser","_promise","_resolve","get","pause","_a","Promise","resolve","resume","call"],"mappings":";;;;;AAgBa,MAAAA,EAAaC,MACxBC,EACAC,KAEA,UAAW,MAAMC,KAAKF,EACpB,IAA4B,UAAjBC,EAASC,GAClB,MAEH,QASUC,EAEXC,YAAYC,GACVC,KAAKC,EAAOF,CACb,CAIDG,aACEF,KAAKC,OAAOE,CACb,CAIDC,UAAUL,GACRC,KAAKC,EAAOF,CACb,CAIDM,QACE,OAAOL,KAAKC,CACb,QAMUK,EAAbR,cACUE,KAAQO,OAAmBJ,EAC3BH,KAAQQ,OAAgBL,CAwBjC,CAhBCM,MACE,OAAOT,KAAKO,CACb,CAIDG,cACE,QAAAC,EAAAX,KAAKO,SAAL,IAAAI,IAAAX,KAAKO,EAAa,IAAIK,SAASC,GAAab,KAAKQ,EAAWK,IAC7D,CAIDC,eACe,QAAbH,EAAAX,KAAKQ,SAAQ,IAAAG,GAAAA,EAAAI,KAAAf,MACbA,KAAKO,EAAWP,KAAKQ,OAAWL,CACjC"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/node/directives/range.js b/front_end/third_party/lit-html/package/node/directives/range.js
new file mode 100644
index 0000000000000000000000000000000000000000..58ccb0232c28f46448989d60fb7ec383c6c12676
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/range.js
@@ -0,0 +1,7 @@
+/**
+ * @license
+ * Copyright 2021 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */
+function*o(o,l,n=1){const t=void 0===l?0:o;null!=l||(l=o);for(let o=t;n>0?o<l:l<o;o+=n)yield o}export{o as range};
+//# sourceMappingURL=range.js.map




diff --git a/front_end/third_party/lit-html/package/node/directives/range.js.map b/front_end/third_party/lit-html/package/node/directives/range.js.map
new file mode 100644
index 0000000000000000000000000000000000000000..262995a49d1d93924a5b8153fcf7ef41e1394606
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/range.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"range.js","sources":["../../src/directives/range.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n/**\n * Returns an iterable of integers from `start` to `end` (exclusive)\n * incrementing by `step`.\n *\n * If `start` is omitted, the range starts at `0`. `step` defaults to `1`.\n *\n * @example\n *\n * ```ts\n * render() {\n *   return html`\n *     ${map(range(8), () => html`<div class=\"cell\"></div>`)}\n *   `;\n * }\n * ```\n */\nexport function range(end: number): Iterable<number>;\nexport function range(\n  start: number,\n  end: number,\n  step?: number\n): Iterable<number>;\nexport function* range(startOrEnd: number, end?: number, step = 1) {\n  const start = end === undefined ? 0 : startOrEnd;\n  end ??= startOrEnd;\n  for (let i = start; step > 0 ? i < end : end < i; i += step) {\n    yield i;\n  }\n}\n"],"names":["range","startOrEnd","end","step","start","undefined","i"],"mappings":";;;;;AA4BM,SAAWA,EAAMC,EAAoBC,EAAcC,EAAO,GAC9D,MAAMC,OAAgBC,IAARH,EAAoB,EAAID,EACtCC,UAAAA,EAAQD,GACR,IAAK,IAAIK,EAAIF,EAAOD,EAAO,EAAIG,EAAIJ,EAAMA,EAAMI,EAAGA,GAAKH,QAC/CG,CAEV"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/node/directives/ref.js b/front_end/third_party/lit-html/package/node/directives/ref.js
new file mode 100644
index 0000000000000000000000000000000000000000..afc6213168482af0a61cb409ab02056b28599949
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/ref.js
@@ -0,0 +1,7 @@
+import{nothing as i}from"../lit-html.js";import{AsyncDirective as t}from"../async-directive.js";import{directive as s}from"../directive.js";
+/**
+ * @license
+ * Copyright 2020 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */const e=()=>new o;class o{}const h=new WeakMap,n=s(class extends t{render(t){return i}update(t,[s]){var e;const o=s!==this.Y;return o&&void 0!==this.Y&&this.rt(void 0),(o||this.lt!==this.ct)&&(this.Y=s,this.dt=null===(e=t.options)||void 0===e?void 0:e.host,this.rt(this.ct=t.element)),i}rt(i){var t;if("function"==typeof this.Y){const s=null!==(t=this.dt)&&void 0!==t?t:globalThis;let e=h.get(s);void 0===e&&(e=new WeakMap,h.set(s,e)),void 0!==e.get(this.Y)&&this.Y.call(this.dt,void 0),e.set(this.Y,i),void 0!==i&&this.Y.call(this.dt,i)}else this.Y.value=i}get lt(){var i,t,s;return"function"==typeof this.Y?null===(t=h.get(null!==(i=this.dt)&&void 0!==i?i:globalThis))||void 0===t?void 0:t.get(this.Y):null===(s=this.Y)||void 0===s?void 0:s.value}disconnected(){this.lt===this.ct&&this.rt(void 0)}reconnected(){this.rt(this.ct)}});export{e as createRef,n as ref};
+//# sourceMappingURL=ref.js.map




diff --git a/front_end/third_party/lit-html/package/node/directives/ref.js.map b/front_end/third_party/lit-html/package/node/directives/ref.js.map
new file mode 100644
index 0000000000000000000000000000000000000000..efad03440f2c903264db82739206ba7643aedad2
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/ref.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"ref.js","sources":["../../src/directives/ref.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2020 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\nimport {nothing, ElementPart} from '../lit-html.js';\nimport {directive, AsyncDirective} from '../async-directive.js';\n\n/**\n * Creates a new Ref object, which is container for a reference to an element.\n */\nexport const createRef = <T = Element>() => new Ref<T>();\n\n/**\n * An object that holds a ref value.\n */\nclass Ref<T = Element> {\n  /**\n   * The current Element value of the ref, or else `undefined` if the ref is no\n   * longer rendered.\n   */\n  readonly value?: T;\n}\n\nexport type {Ref};\n\ninterface RefInternal {\n  value: Element | undefined;\n}\n\n// When callbacks are used for refs, this map tracks the last value the callback\n// was called with, for ensuring a directive doesn't clear the ref if the ref\n// has already been rendered to a new spot. It is double-keyed on both the\n// context (`options.host`) and the callback, since we auto-bind class methods\n// to `options.host`.\nconst lastElementForContextAndCallback: WeakMap<\n  object,\n  WeakMap<Function, Element | undefined>\n> = new WeakMap();\n\nexport type RefOrCallback = Ref | ((el: Element | undefined) => void);\n\nclass RefDirective extends AsyncDirective {\n  private _element?: Element;\n  private _ref?: RefOrCallback;\n  private _context?: object;\n\n  render(_ref: RefOrCallback) {\n    return nothing;\n  }\n\n  override update(part: ElementPart, [ref]: Parameters<this['render']>) {\n    const refChanged = ref !== this._ref;\n    if (refChanged && this._ref !== undefined) {\n      // The ref passed to the directive has changed;\n      // unset the previous ref's value\n      this._updateRefValue(undefined);\n    }\n    if (refChanged || this._lastElementForRef !== this._element) {\n      // We either got a new ref or this is the first render;\n      // store the ref/element & update the ref value\n      this._ref = ref;\n      this._context = part.options?.host;\n      this._updateRefValue((this._element = part.element));\n    }\n    return nothing;\n  }\n\n  private _updateRefValue(element: Element | undefined) {\n    if (typeof this._ref === 'function') {\n      // If the current ref was called with a previous value, call with\n      // `undefined`; We do this to ensure callbacks are called in a consistent\n      // way regardless of whether a ref might be moving up in the tree (in\n      // which case it would otherwise be called with the new value before the\n      // previous one unsets it) and down in the tree (where it would be unset\n      // before being set). Note that element lookup is keyed by\n      // both the context and the callback, since we allow passing unbound\n      // functions that are called on options.host, and we want to treat\n      // these as unique \"instances\" of a function.\n      const context = this._context ?? globalThis;\n      let lastElementForCallback =\n        lastElementForContextAndCallback.get(context);\n      if (lastElementForCallback === undefined) {\n        lastElementForCallback = new WeakMap();\n        lastElementForContextAndCallback.set(context, lastElementForCallback);\n      }\n      if (lastElementForCallback.get(this._ref) !== undefined) {\n        this._ref.call(this._context, undefined);\n      }\n      lastElementForCallback.set(this._ref, element);\n      // Call the ref with the new element value\n      if (element !== undefined) {\n        this._ref.call(this._context, element);\n      }\n    } else {\n      (this._ref as RefInternal)!.value = element;\n    }\n  }\n\n  private get _lastElementForRef() {\n    return typeof this._ref === 'function'\n      ? lastElementForContextAndCallback\n          .get(this._context ?? globalThis)\n          ?.get(this._ref)\n      : this._ref?.value;\n  }\n\n  override disconnected() {\n    // Only clear the box if our element is still the one in it (i.e. another\n    // directive instance hasn't rendered its element to it before us); that\n    // only happens in the event of the directive being cleared (not via manual\n    // disconnection)\n    if (this._lastElementForRef === this._element) {\n      this._updateRefValue(undefined);\n    }\n  }\n\n  override reconnected() {\n    // If we were manually disconnected, we can safely put our element back in\n    // the box, since no rendering could have occurred to change its state\n    this._updateRefValue(this._element);\n  }\n}\n\n/**\n * Sets the value of a Ref object or calls a ref callback with the element it's\n * bound to.\n *\n * A Ref object acts as a container for a reference to an element. A ref\n * callback is a function that takes an element as its only argument.\n *\n * The ref directive sets the value of the Ref object or calls the ref callback\n * during rendering, if the referenced element changed.\n *\n * Note: If a ref callback is rendered to a different element position or is\n * removed in a subsequent render, it will first be called with `undefined`,\n * followed by another call with the new element it was rendered to (if any).\n *\n * ```js\n * // Using Ref object\n * const inputRef = createRef();\n * render(html`<input ${ref(inputRef)}>`, container);\n * inputRef.value.focus();\n *\n * // Using callback\n * const callback = (inputElement) => inputElement.focus();\n * render(html`<input ${ref(callback)}>`, container);\n * ```\n */\nexport const ref = directive(RefDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {RefDirective};\n"],"names":["createRef","Ref","lastElementForContextAndCallback","WeakMap","ref","directive","AsyncDirective","render","_ref","nothing","update","part","refChanged","this","undefined","_updateRefValue","_lastElementForRef","_element","_context","_a","options","host","element","context","globalThis","lastElementForCallback","get","set","call","value","_b","_c","disconnected","reconnected"],"mappings":";;;;;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B,KAAKE,GAAgBF,KAAKI,GAC3B"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/node/directives/repeat.js b/front_end/third_party/lit-html/package/node/directives/repeat.js
new file mode 100644
index 0000000000000000000000000000000000000000..f93d72b902d4a1565f4b7fac73f2715d2b74b1f1
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/repeat.js
@@ -0,0 +1,8 @@
+import{noChange as e}from"../lit-html.js";import{directive as s,Directive as t,PartType as r}from"../directive.js";import{getCommittedValue as l,setChildPartValue as o,insertPart as i,removePart as n,setCommittedValue as f}from"../directive-helpers.js";
+/**
+ * @license
+ * Copyright 2017 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */
+const u=(e,s,t)=>{const r=new Map;for(let l=s;l<=t;l++)r.set(e[l],l);return r},c=s(class extends t{constructor(e){if(super(e),e.type!==r.CHILD)throw Error("repeat() can only be used in text expressions")}ht(e,s,t){let r;void 0===t?t=s:void 0!==s&&(r=s);const l=[],o=[];let i=0;for(const s of e)l[i]=r?r(s,i):i,o[i]=t(s,i),i++;return{values:o,keys:l}}render(e,s,t){return this.ht(e,s,t).values}update(s,[t,r,c]){var d;const a=l(s),{values:p,keys:v}=this.ht(t,r,c);if(!Array.isArray(a))return this.ut=v,p;const h=null!==(d=this.ut)&&void 0!==d?d:this.ut=[],m=[];let y,x,j=0,k=a.length-1,w=0,A=p.length-1;for(;j<=k&&w<=A;)if(null===a[j])j++;else if(null===a[k])k--;else if(h[j]===v[w])m[w]=o(a[j],p[w]),j++,w++;else if(h[k]===v[A])m[A]=o(a[k],p[A]),k--,A--;else if(h[j]===v[A])m[A]=o(a[j],p[A]),i(s,m[A+1],a[j]),j++,A--;else if(h[k]===v[w])m[w]=o(a[k],p[w]),i(s,a[j],a[k]),k--,w++;else if(void 0===y&&(y=u(v,w,A),x=u(h,j,k)),y.has(h[j]))if(y.has(h[k])){const e=x.get(v[w]),t=void 0!==e?a[e]:null;if(null===t){const e=i(s,a[j]);o(e,p[w]),m[w]=e}else m[w]=o(t,p[w]),i(s,a[j],t),a[e]=null;w++}else n(a[k]),k--;else n(a[j]),j++;for(;w<=A;){const e=i(s,m[A+1]);o(e,p[w]),m[w++]=e}for(;j<=k;){const e=a[j++];null!==e&&n(e)}return this.ut=v,f(s,m),e}});export{c as repeat};
+//# sourceMappingURL=repeat.js.map




diff --git a/front_end/third_party/lit-html/package/node/directives/repeat.js.map b/front_end/third_party/lit-html/package/node/directives/repeat.js.map
new file mode 100644
index 0000000000000000000000000000000000000000..be5295c33afbfb8b3fc6265c987c4f965b7c65b4
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/repeat.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"repeat.js","sources":["../../src/directives/repeat.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {ChildPart, noChange} from '../lit-html.js';\nimport {directive, Directive, PartInfo, PartType} from '../directive.js';\nimport {\n  insertPart,\n  getCommittedValue,\n  removePart,\n  setCommittedValue,\n  setChildPartValue,\n} from '../directive-helpers.js';\n\nexport type KeyFn<T> = (item: T, index: number) => unknown;\nexport type ItemTemplate<T> = (item: T, index: number) => unknown;\n\n// Helper for generating a map of array item to its index over a subset\n// of an array (used to lazily generate `newKeyToIndexMap` and\n// `oldKeyToIndexMap`)\nconst generateMap = (list: unknown[], start: number, end: number) => {\n  const map = new Map<unknown, number>();\n  for (let i = start; i <= end; i++) {\n    map.set(list[i], i);\n  }\n  return map;\n};\n\nclass RepeatDirective extends Directive {\n  private _itemKeys?: unknown[];\n\n  constructor(partInfo: PartInfo) {\n    super(partInfo);\n    if (partInfo.type !== PartType.CHILD) {\n      throw new Error('repeat() can only be used in text expressions');\n    }\n  }\n\n  private _getValuesAndKeys<T>(\n    items: Iterable<T>,\n    keyFnOrTemplate: KeyFn<T> | ItemTemplate<T>,\n    template?: ItemTemplate<T>\n  ) {\n    let keyFn: KeyFn<T> | undefined;\n    if (template === undefined) {\n      template = keyFnOrTemplate;\n    } else if (keyFnOrTemplate !== undefined) {\n      keyFn = keyFnOrTemplate as KeyFn<T>;\n    }\n    const keys = [];\n    const values = [];\n    let index = 0;\n    for (const item of items) {\n      keys[index] = keyFn ? keyFn(item, index) : index;\n      values[index] = template!(item, index);\n      index++;\n    }\n    return {\n      values,\n      keys,\n    };\n  }\n\n  render<T>(items: Iterable<T>, template: ItemTemplate<T>): Array<unknown>;\n  render<T>(\n    items: Iterable<T>,\n    keyFn: KeyFn<T> | ItemTemplate<T>,\n    template: ItemTemplate<T>\n  ): Array<unknown>;\n  render<T>(\n    items: Iterable<T>,\n    keyFnOrTemplate: KeyFn<T> | ItemTemplate<T>,\n    template?: ItemTemplate<T>\n  ) {\n    return this._getValuesAndKeys(items, keyFnOrTemplate, template).values;\n  }\n\n  override update<T>(\n    containerPart: ChildPart,\n    [items, keyFnOrTemplate, template]: [\n      Iterable<T>,\n      KeyFn<T> | ItemTemplate<T>,\n      ItemTemplate<T>\n    ]\n  ) {\n    // Old part & key lists are retrieved from the last update (which may\n    // be primed by hydration)\n    const oldParts = getCommittedValue(\n      containerPart\n    ) as Array<ChildPart | null>;\n    const {values: newValues, keys: newKeys} = this._getValuesAndKeys(\n      items,\n      keyFnOrTemplate,\n      template\n    );\n\n    // We check that oldParts, the committed value, is an Array as an\n    // indicator that the previous value came from a repeat() call. If\n    // oldParts is not an Array then this is the first render and we return\n    // an array for lit-html's array handling to render, and remember the\n    // keys.\n    if (!Array.isArray(oldParts)) {\n      this._itemKeys = newKeys;\n      return newValues;\n    }\n\n    // In SSR hydration it's possible for oldParts to be an arrray but for us\n    // to not have item keys because the update() hasn't run yet. We set the\n    // keys to an empty array. This will cause all oldKey/newKey comparisons\n    // to fail and execution to fall to the last nested brach below which\n    // reuses the oldPart.\n    const oldKeys = (this._itemKeys ??= []);\n\n    // New part list will be built up as we go (either reused from\n    // old parts or created for new keys in this update). This is\n    // saved in the above cache at the end of the update.\n    const newParts: ChildPart[] = [];\n\n    // Maps from key to index for current and previous update; these\n    // are generated lazily only when needed as a performance\n    // optimization, since they are only required for multiple\n    // non-contiguous changes in the list, which are less common.\n    let newKeyToIndexMap!: Map<unknown, number>;\n    let oldKeyToIndexMap!: Map<unknown, number>;\n\n    // Head and tail pointers to old parts and new values\n    let oldHead = 0;\n    let oldTail = oldParts.length - 1;\n    let newHead = 0;\n    let newTail = newValues.length - 1;\n\n    // Overview of O(n) reconciliation algorithm (general approach\n    // based on ideas found in ivi, vue, snabbdom, etc.):\n    //\n    // * We start with the list of old parts and new values (and\n    //   arrays of their respective keys), head/tail pointers into\n    //   each, and we build up the new list of parts by updating\n    //   (and when needed, moving) old parts or creating new ones.\n    //   The initial scenario might look like this (for brevity of\n    //   the diagrams, the numbers in the array reflect keys\n    //   associated with the old parts or new values, although keys\n    //   and parts/values are actually stored in parallel arrays\n    //   indexed using the same head/tail pointers):\n    //\n    //      oldHead v                 v oldTail\n    //   oldKeys:  [0, 1, 2, 3, 4, 5, 6]\n    //   newParts: [ ,  ,  ,  ,  ,  ,  ]\n    //   newKeys:  [0, 2, 1, 4, 3, 7, 6] <- reflects the user's new\n    //                                      item order\n    //      newHead ^                 ^ newTail\n    //\n    // * Iterate old & new lists from both sides, updating,\n    //   swapping, or removing parts at the head/tail locations\n    //   until neither head nor tail can move.\n    //\n    // * Example below: keys at head pointers match, so update old\n    //   part 0 in-place (no need to move it) and record part 0 in\n    //   the `newParts` list. The last thing we do is advance the\n    //   `oldHead` and `newHead` pointers (will be reflected in the\n    //   next diagram).\n    //\n    //      oldHead v                 v oldTail\n    //   oldKeys:  [0, 1, 2, 3, 4, 5, 6]\n    //   newParts: [0,  ,  ,  ,  ,  ,  ] <- heads matched: update 0\n    //   newKeys:  [0, 2, 1, 4, 3, 7, 6]    and advance both oldHead\n    //                                      & newHead\n    //      newHead ^                 ^ newTail\n    //\n    // * Example below: head pointers don't match, but tail\n    //   pointers do, so update part 6 in place (no need to move\n    //   it), and record part 6 in the `newParts` list. Last,\n    //   advance the `oldTail` and `oldHead` pointers.\n    //\n    //         oldHead v              v oldTail\n    //   oldKeys:  [0, 1, 2, 3, 4, 5, 6]\n    //   newParts: [0,  ,  ,  ,  ,  , 6] <- tails matched: update 6\n    //   newKeys:  [0, 2, 1, 4, 3, 7, 6]    and advance both oldTail\n    //                                      & newTail\n    //         newHead ^              ^ newTail\n    //\n    // * If neither head nor tail match; next check if one of the\n    //   old head/tail items was removed. We first need to generate\n    //   the reverse map of new keys to index (`newKeyToIndexMap`),\n    //   which is done once lazily as a performance optimization,\n    //   since we only hit this case if multiple non-contiguous\n    //   changes were made. Note that for contiguous removal\n    //   anywhere in the list, the head and tails would advance\n    //   from either end and pass each other before we get to this\n    //   case and removals would be handled in the final while loop\n    //   without needing to generate the map.\n    //\n    // * Example below: The key at `oldTail` was removed (no longer\n    //   in the `newKeyToIndexMap`), so remove that part from the\n    //   DOM and advance just the `oldTail` pointer.\n    //\n    //         oldHead v           v oldTail\n    //   oldKeys:  [0, 1, 2, 3, 4, 5, 6]\n    //   newParts: [0,  ,  ,  ,  ,  , 6] <- 5 not in new map: remove\n    //   newKeys:  [0, 2, 1, 4, 3, 7, 6]    5 and advance oldTail\n    //         newHead ^           ^ newTail\n    //\n    // * Once head and tail cannot move, any mismatches are due to\n    //   either new or moved items; if a new key is in the previous\n    //   \"old key to old index\" map, move the old part to the new\n    //   location, otherwise create and insert a new part. Note\n    //   that when moving an old part we null its position in the\n    //   oldParts array if it lies between the head and tail so we\n    //   know to skip it when the pointers get there.\n    //\n    // * Example below: neither head nor tail match, and neither\n    //   were removed; so find the `newHead` key in the\n    //   `oldKeyToIndexMap`, and move that old part's DOM into the\n    //   next head position (before `oldParts[oldHead]`). Last,\n    //   null the part in the `oldPart` array since it was\n    //   somewhere in the remaining oldParts still to be scanned\n    //   (between the head and tail pointers) so that we know to\n    //   skip that old part on future iterations.\n    //\n    //         oldHead v        v oldTail\n    //   oldKeys:  [0, 1, -, 3, 4, 5, 6]\n    //   newParts: [0, 2,  ,  ,  ,  , 6] <- stuck: update & move 2\n    //   newKeys:  [0, 2, 1, 4, 3, 7, 6]    into place and advance\n    //                                      newHead\n    //         newHead ^           ^ newTail\n    //\n    // * Note that for moves/insertions like the one above, a part\n    //   inserted at the head pointer is inserted before the\n    //   current `oldParts[oldHead]`, and a part inserted at the\n    //   tail pointer is inserted before `newParts[newTail+1]`. The\n    //   seeming asymmetry lies in the fact that new parts are\n    //   moved into place outside in, so to the right of the head\n    //   pointer are old parts, and to the right of the tail\n    //   pointer are new parts.\n    //\n    // * We always restart back from the top of the algorithm,\n    //   allowing matching and simple updates in place to\n    //   continue...\n    //\n    // * Example below: the head pointers once again match, so\n    //   simply update part 1 and record it in the `newParts`\n    //   array.  Last, advance both head pointers.\n    //\n    //         oldHead v        v oldTail\n    //   oldKeys:  [0, 1, -, 3, 4, 5, 6]\n    //   newParts: [0, 2, 1,  ,  ,  , 6] <- heads matched: update 1\n    //   newKeys:  [0, 2, 1, 4, 3, 7, 6]    and advance both oldHead\n    //                                      & newHead\n    //            newHead ^        ^ newTail\n    //\n    // * As mentioned above, items that were moved as a result of\n    //   being stuck (the final else clause in the code below) are\n    //   marked with null, so we always advance old pointers over\n    //   these so we're comparing the next actual old value on\n    //   either end.\n    //\n    // * Example below: `oldHead` is null (already placed in\n    //   newParts), so advance `oldHead`.\n    //\n    //            oldHead v     v oldTail\n    //   oldKeys:  [0, 1, -, 3, 4, 5, 6] <- old head already used:\n    //   newParts: [0, 2, 1,  ,  ,  , 6]    advance oldHead\n    //   newKeys:  [0, 2, 1, 4, 3, 7, 6]\n    //               newHead ^     ^ newTail\n    //\n    // * Note it's not critical to mark old parts as null when they\n    //   are moved from head to tail or tail to head, since they\n    //   will be outside the pointer range and never visited again.\n    //\n    // * Example below: Here the old tail key matches the new head\n    //   key, so the part at the `oldTail` position and move its\n    //   DOM to the new head position (before `oldParts[oldHead]`).\n    //   Last, advance `oldTail` and `newHead` pointers.\n    //\n    //               oldHead v  v oldTail\n    //   oldKeys:  [0, 1, -, 3, 4, 5, 6]\n    //   newParts: [0, 2, 1, 4,  ,  , 6] <- old tail matches new\n    //   newKeys:  [0, 2, 1, 4, 3, 7, 6]   head: update & move 4,\n    //                                     advance oldTail & newHead\n    //               newHead ^     ^ newTail\n    //\n    // * Example below: Old and new head keys match, so update the\n    //   old head part in place, and advance the `oldHead` and\n    //   `newHead` pointers.\n    //\n    //               oldHead v oldTail\n    //   oldKeys:  [0, 1, -, 3, 4, 5, 6]\n    //   newParts: [0, 2, 1, 4, 3,   ,6] <- heads match: update 3\n    //   newKeys:  [0, 2, 1, 4, 3, 7, 6]    and advance oldHead &\n    //                                      newHead\n    //                  newHead ^  ^ newTail\n    //\n    // * Once the new or old pointers move past each other then all\n    //   we have left is additions (if old list exhausted) or\n    //   removals (if new list exhausted). Those are handled in the\n    //   final while loops at the end.\n    //\n    // * Example below: `oldHead` exceeded `oldTail`, so we're done\n    //   with the main loop.  Create the remaining part and insert\n    //   it at the new head position, and the update is complete.\n    //\n    //                   (oldHead > oldTail)\n    //   oldKeys:  [0, 1, -, 3, 4, 5, 6]\n    //   newParts: [0, 2, 1, 4, 3, 7 ,6] <- create and insert 7\n    //   newKeys:  [0, 2, 1, 4, 3, 7, 6]\n    //                     newHead ^ newTail\n    //\n    // * Note that the order of the if/else clauses is not\n    //   important to the algorithm, as long as the null checks\n    //   come first (to ensure we're always working on valid old\n    //   parts) and that the final else clause comes last (since\n    //   that's where the expensive moves occur). The order of\n    //   remaining clauses is is just a simple guess at which cases\n    //   will be most common.\n    //\n    // * Note, we could calculate the longest\n    //   increasing subsequence (LIS) of old items in new position,\n    //   and only move those not in the LIS set. However that costs\n    //   O(nlogn) time and adds a bit more code, and only helps\n    //   make rare types of mutations require fewer moves. The\n    //   above handles removes, adds, reversal, swaps, and single\n    //   moves of contiguous items in linear time, in the minimum\n    //   number of moves. As the number of multiple moves where LIS\n    //   might help approaches a random shuffle, the LIS\n    //   optimization becomes less helpful, so it seems not worth\n    //   the code at this point. Could reconsider if a compelling\n    //   case arises.\n\n    while (oldHead <= oldTail && newHead <= newTail) {\n      if (oldParts[oldHead] === null) {\n        // `null` means old part at head has already been used\n        // below; skip\n        oldHead++;\n      } else if (oldParts[oldTail] === null) {\n        // `null` means old part at tail has already been used\n        // below; skip\n        oldTail--;\n      } else if (oldKeys[oldHead] === newKeys[newHead]) {\n        // Old head matches new head; update in place\n        newParts[newHead] = setChildPartValue(\n          oldParts[oldHead]!,\n          newValues[newHead]\n        );\n        oldHead++;\n        newHead++;\n      } else if (oldKeys[oldTail] === newKeys[newTail]) {\n        // Old tail matches new tail; update in place\n        newParts[newTail] = setChildPartValue(\n          oldParts[oldTail]!,\n          newValues[newTail]\n        );\n        oldTail--;\n        newTail--;\n      } else if (oldKeys[oldHead] === newKeys[newTail]) {\n        // Old head matches new tail; update and move to new tail\n        newParts[newTail] = setChildPartValue(\n          oldParts[oldHead]!,\n          newValues[newTail]\n        );\n        insertPart(containerPart, newParts[newTail + 1], oldParts[oldHead]!);\n        oldHead++;\n        newTail--;\n      } else if (oldKeys[oldTail] === newKeys[newHead]) {\n        // Old tail matches new head; update and move to new head\n        newParts[newHead] = setChildPartValue(\n          oldParts[oldTail]!,\n          newValues[newHead]\n        );\n        insertPart(containerPart, oldParts[oldHead]!, oldParts[oldTail]!);\n        oldTail--;\n        newHead++;\n      } else {\n        if (newKeyToIndexMap === undefined) {\n          // Lazily generate key-to-index maps, used for removals &\n          // moves below\n          newKeyToIndexMap = generateMap(newKeys, newHead, newTail);\n          oldKeyToIndexMap = generateMap(oldKeys, oldHead, oldTail);\n        }\n        if (!newKeyToIndexMap.has(oldKeys[oldHead])) {\n          // Old head is no longer in new list; remove\n          removePart(oldParts[oldHead]!);\n          oldHead++;\n        } else if (!newKeyToIndexMap.has(oldKeys[oldTail])) {\n          // Old tail is no longer in new list; remove\n          removePart(oldParts[oldTail]!);\n          oldTail--;\n        } else {\n          // Any mismatches at this point are due to additions or\n          // moves; see if we have an old part we can reuse and move\n          // into place\n          const oldIndex = oldKeyToIndexMap.get(newKeys[newHead]);\n          const oldPart = oldIndex !== undefined ? oldParts[oldIndex] : null;\n          if (oldPart === null) {\n            // No old part for this value; create a new one and\n            // insert it\n            const newPart = insertPart(containerPart, oldParts[oldHead]!);\n            setChildPartValue(newPart, newValues[newHead]);\n            newParts[newHead] = newPart;\n          } else {\n            // Reuse old part\n            newParts[newHead] = setChildPartValue(oldPart, newValues[newHead]);\n            insertPart(containerPart, oldParts[oldHead]!, oldPart);\n            // This marks the old part as having been used, so that\n            // it will be skipped in the first two checks above\n            oldParts[oldIndex as number] = null;\n          }\n          newHead++;\n        }\n      }\n    }\n    // Add parts for any remaining new values\n    while (newHead <= newTail) {\n      // For all remaining additions, we insert before last new\n      // tail, since old pointers are no longer valid\n      const newPart = insertPart(containerPart, newParts[newTail + 1]);\n      setChildPartValue(newPart, newValues[newHead]);\n      newParts[newHead++] = newPart;\n    }\n    // Remove any remaining unused old parts\n    while (oldHead <= oldTail) {\n      const oldPart = oldParts[oldHead++];\n      if (oldPart !== null) {\n        removePart(oldPart);\n      }\n    }\n\n    // Save order of new parts for next round\n    this._itemKeys = newKeys;\n    // Directly set part value, bypassing it's dirty-checking\n    setCommittedValue(containerPart, newParts);\n    return noChange;\n  }\n}\n\nexport interface RepeatDirectiveFn {\n  <T>(\n    items: Iterable<T>,\n    keyFnOrTemplate: KeyFn<T> | ItemTemplate<T>,\n    template?: ItemTemplate<T>\n  ): unknown;\n  <T>(items: Iterable<T>, template: ItemTemplate<T>): unknown;\n  <T>(\n    items: Iterable<T>,\n    keyFn: KeyFn<T> | ItemTemplate<T>,\n    template: ItemTemplate<T>\n  ): unknown;\n}\n\n/**\n * A directive that repeats a series of values (usually `TemplateResults`)\n * generated from an iterable, and updates those items efficiently when the\n * iterable changes based on user-provided `keys` associated with each item.\n *\n * Note that if a `keyFn` is provided, strict key-to-DOM mapping is maintained,\n * meaning previous DOM for a given key is moved into the new position if\n * needed, and DOM will never be reused with values for different keys (new DOM\n * will always be created for new keys). This is generally the most efficient\n * way to use `repeat` since it performs minimum unnecessary work for insertions\n * and removals.\n *\n * The `keyFn` takes two parameters, the item and its index, and returns a unique key value.\n *\n * ```js\n * html`\n *   <ol>\n *     ${repeat(this.items, (item) => item.id, (item, index) => {\n *       return html`<li>${index}: ${item.name}</li>`;\n *     })}\n *   </ol>\n * `\n * ```\n *\n * **Important**: If providing a `keyFn`, keys *must* be unique for all items in a\n * given call to `repeat`. The behavior when two or more items have the same key\n * is undefined.\n *\n * If no `keyFn` is provided, this directive will perform similar to mapping\n * items to values, and DOM will be reused against potentially different items.\n */\nexport const repeat = directive(RepeatDirective) as RepeatDirectiveFn;\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {RepeatDirective};\n"],"names":["generateMap","list","start","end","map","Map","i","set","repeat","directive","Directive","constructor","partInfo","super","type","PartType","CHILD","Error","_getValuesAndKeys","items","keyFnOrTemplate","template","keyFn","undefined","keys","values","index","item","render","this","update","containerPart","oldParts","getCommittedValue","newValues","newKeys","Array","isArray","_itemKeys","oldKeys","_a","newParts","newKeyToIndexMap","oldKeyToIndexMap","oldHead","oldTail","length","newHead","newTail","setChildPartValue","insertPart","has","oldIndex","get","oldPart","newPart","removePart","setCommittedValue","noChange"],"mappings":";;;;;;AAsBA,MAAMA,EAAc,CAACC,EAAiBC,EAAeC,KACnD,MAAMC,EAAM,IAAIC,IAChB,IAAK,IAAIC,EAAIJ,EAAOI,GAAKH,EAAKG,IAC5BF,EAAIG,IAAIN,EAAKK,GAAIA,GAEnB,OAAOF,CAAG,EAqcCI,EAASC,EAlctB,cAA8BC,EAG5BC,YAAYC,GAEV,GADAC,MAAMD,GACFA,EAASE,OAASC,EAASC,MAC7B,MAAUC,MAAM,gDAEnB,CAEOC,GACNC,EACAC,EACAC,GAEA,IAAIC,OACaC,IAAbF,EACFA,EAAWD,OACkBG,IAApBH,IACTE,EAAQF,GAEV,MAAMI,EAAO,GACPC,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SAQA,QANyBxB,IAArBmB,IAGFA,EAAmB1C,EAAYmC,EAASY,EAASC,GACjDL,EAAmB3C,EAAYuC,EAASK,EAASC,IAE9CH,EAAiBS,IAAIZ,EAAQK,IAI3B,GAAKF,EAAiBS,IAAIZ,EAAQM,IAIlC,CAIL,MAAMO,EAAWT,EAAiBU,IAAIlB,EAAQY,IACxCO,OAAuB/B,IAAb6B,EAAyBpB,EAASoB,GAAY,KAC9D,GAAgB,OAAZE,EAAkB,CAGpB,MAAMC,EAAUL,EAAWnB,EAAeC,EAASY,IACnDK,EAAkBM,EAASrB,EAAUa,IACrCN,EAASM,GAAWQ,CACrB,MAECd,EAASM,GAAWE,EAAkBK,EAASpB,EAAUa,IACzDG,EAAWnB,EAAeC,EAASY,GAAWU,GAG9CtB,EAASoB,GAAsB,KAEjCL,GACD,MAvBCS,EAAWxB,EAASa,IACpBA,SALAW,EAAWxB,EAASY,IACpBA,IA8BN,KAAOG,GAAWC,GAAS,CAGzB,MAAMO,EAAUL,EAAWnB,EAAeU,EAASO,EAAU,IAC7DC,EAAkBM,EAASrB,EAAUa,IACrCN,EAASM,KAAaQ,CACvB,CAED,KAAOX,GAAWC,GAAS,CACzB,MAAMS,EAAUtB,EAASY,KACT,OAAZU,GACFE,EAAWF,EAEd,CAMD,OAHAzB,KAAKS,GAAYH,EAEjBsB,EAAkB1B,EAAeU,GAC1BiB,CACR"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/node/directives/style-map.js b/front_end/third_party/lit-html/package/node/directives/style-map.js
new file mode 100644
index 0000000000000000000000000000000000000000..c89e0067e4cb7a275c858754150fa62918f8f26d
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/style-map.js
@@ -0,0 +1,7 @@
+import{noChange as t}from"../lit-html.js";import{directive as e,Directive as r,PartType as s}from"../directive.js";
+/**
+ * @license
+ * Copyright 2018 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */const i=e(class extends r{constructor(t){var e;if(super(t),t.type!==s.ATTRIBUTE||"style"!==t.name||(null===(e=t.strings)||void 0===e?void 0:e.length)>2)throw Error("The `styleMap` directive must be used in the `style` attribute and must be the only part in the attribute.")}render(t){return Object.keys(t).reduce(((e,r)=>{const s=t[r];return null==s?e:e+`${r=r.replace(/(?:^(webkit|moz|ms|o)|)(?=[A-Z])/g,"-$&").toLowerCase()}:${s};`}),"")}update(e,[r]){const{style:s}=e.element;if(void 0===this.vt){this.vt=new Set;for(const t in r)this.vt.add(t);return this.render(r)}this.vt.forEach((t=>{null==r[t]&&(this.vt.delete(t),t.includes("-")?s.removeProperty(t):s[t]="")}));for(const t in r){const e=r[t];null!=e&&(this.vt.add(t),t.includes("-")?s.setProperty(t,e):s[t]=e)}return t}});export{i as styleMap};
+//# sourceMappingURL=style-map.js.map




diff --git a/front_end/third_party/lit-html/package/node/directives/style-map.js.map b/front_end/third_party/lit-html/package/node/directives/style-map.js.map
new file mode 100644
index 0000000000000000000000000000000000000000..7cc17d9e70a2482032e29139df5a53b99e458f3c
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/style-map.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"style-map.js","sources":["../../src/directives/style-map.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2018 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {AttributePart, noChange} from '../lit-html.js';\nimport {\n  directive,\n  Directive,\n  DirectiveParameters,\n  PartInfo,\n  PartType,\n} from '../directive.js';\n\n/**\n * A key-value set of CSS properties and values.\n *\n * The key should be either a valid CSS property name string, like\n * `'background-color'`, or a valid JavaScript camel case property name\n * for CSSStyleDeclaration like `backgroundColor`.\n */\nexport interface StyleInfo {\n  [name: string]: string | undefined | null;\n}\n\nclass StyleMapDirective extends Directive {\n  _previousStyleProperties?: Set<string>;\n\n  constructor(partInfo: PartInfo) {\n    super(partInfo);\n    if (\n      partInfo.type !== PartType.ATTRIBUTE ||\n      partInfo.name !== 'style' ||\n      (partInfo.strings?.length as number) > 2\n    ) {\n      throw new Error(\n        'The `styleMap` directive must be used in the `style` attribute ' +\n          'and must be the only part in the attribute.'\n      );\n    }\n  }\n\n  render(styleInfo: Readonly<StyleInfo>) {\n    return Object.keys(styleInfo).reduce((style, prop) => {\n      const value = styleInfo[prop];\n      if (value == null) {\n        return style;\n      }\n      // Convert property names from camel-case to dash-case, i.e.:\n      //  `backgroundColor` -> `background-color`\n      // Vendor-prefixed names need an extra `-` appended to front:\n      //  `webkitAppearance` -> `-webkit-appearance`\n      // Exception is any property name containing a dash, including\n      // custom properties; we assume these are already dash-cased i.e.:\n      //  `--my-button-color` --> `--my-button-color`\n      prop = prop\n        .replace(/(?:^(webkit|moz|ms|o)|)(?=[A-Z])/g, '-$&')\n        .toLowerCase();\n      return style + `${prop}:${value};`;\n    }, '');\n  }\n\n  override update(part: AttributePart, [styleInfo]: DirectiveParameters<this>) {\n    const {style} = part.element as HTMLElement;\n\n    if (this._previousStyleProperties === undefined) {\n      this._previousStyleProperties = new Set();\n      for (const name in styleInfo) {\n        this._previousStyleProperties.add(name);\n      }\n      return this.render(styleInfo);\n    }\n\n    // Remove old properties that no longer exist in styleInfo\n    // We use forEach() instead of for-of so that re don't require down-level\n    // iteration.\n    this._previousStyleProperties!.forEach((name) => {\n      // If the name isn't in styleInfo or it's null/undefined\n      if (styleInfo[name] == null) {\n        this._previousStyleProperties!.delete(name);\n        if (name.includes('-')) {\n          style.removeProperty(name);\n        } else {\n          // Note reset using empty string (vs null) as IE11 does not always\n          // reset via null (https://developer.mozilla.org/en-US/docs/Web/API/ElementCSSInlineStyle/style#setting_styles)\n          // eslint-disable-next-line @typescript-eslint/no-explicit-any\n          (style as any)[name] = '';\n        }\n      }\n    });\n\n    // Add or update properties\n    for (const name in styleInfo) {\n      const value = styleInfo[name];\n      if (value != null) {\n        this._previousStyleProperties.add(name);\n        if (name.includes('-')) {\n          style.setProperty(name, value);\n        } else {\n          // eslint-disable-next-line @typescript-eslint/no-explicit-any\n          (style as any)[name] = value;\n        }\n      }\n    }\n    return noChange;\n  }\n}\n\n/**\n * A directive that applies CSS properties to an element.\n *\n * `styleMap` can only be used in the `style` attribute and must be the only\n * expression in the attribute. It takes the property names in the\n * {@link StyleInfo styleInfo} object and adds the property values as CSS\n * properties. Property names with dashes (`-`) are assumed to be valid CSS\n * property names and set on the element's style object using `setProperty()`.\n * Names without dashes are assumed to be camelCased JavaScript property names\n * and set on the element's style object using property assignment, allowing the\n * style object to translate JavaScript-style names to CSS property names.\n *\n * For example `styleMap({backgroundColor: 'red', 'border-top': '5px', '--size':\n * '0'})` sets the `background-color`, `border-top` and `--size` properties.\n *\n * @param styleInfo\n * @see {@link https://lit.dev/docs/templates/directives/#stylemap styleMap code samples on Lit.dev}\n */\nexport const styleMap = directive(StyleMapDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {StyleMapDirective};\n"],"names":["styleMap","directive","Directive","constructor","partInfo","super","type","PartType","ATTRIBUTE","name","_a","strings","length","Error","render","styleInfo","Object","keys","reduce","style","prop","value","replace","toLowerCase","update","part","element","undefined","this","_previousStyleProperties","Set","add","forEach","delete","includes","removeProperty","setProperty","noChange"],"mappings":";;;;;SA+HaA,EAAWC,EArGxB,cAAgCC,EAG9BC,YAAYC,SAEV,GADAC,MAAMD,GAEJA,EAASE,OAASC,EAASC,WACT,UAAlBJ,EAASK,eACRC,EAAAN,EAASO,8BAASC,QAAoB,EAEvC,MAAUC,MACR,6GAIL,CAEDC,OAAOC,GACL,OAAOC,OAAOC,KAAKF,GAAWG,QAAO,CAACC,EAAOC,KAC3C,MAAMC,EAAQN,EAAUK,GACxB,OAAa,MAATC,EACKF,EAYFA,EAAQ,GAHfC,EAAOA,EACJE,QAAQ,oCAAqC,OAC7CC,iBACuBF,IAAQ,GACjC,GACJ,CAEQG,OAAOC,GAAsBV,IACpC,MAAMI,MAACA,GAASM,EAAKC,QAErB,QAAsCC,IAAlCC,KAAKC,GAAwC,CAC/CD,KAAKC,GAA2B,IAAIC,IACpC,IAAK,MAAMrB,KAAQM,EACjBa,KAAKC,GAAyBE,IAAItB,GAEpC,OAAOmB,KAAKd,OAAOC,EACpB,CAKDa,KAAKC,GAA0BG,SAASvB,IAEf,MAAnBM,EAAUN,KACZmB,KAAKC,GAA0BI,OAAOxB,GAClCA,EAAKyB,SAAS,KAChBf,EAAMgB,eAAe1B,GAKpBU,EAAcV,GAAQ,GAE1B,IAIH,IAAK,MAAMA,KAAQM,EAAW,CAC5B,MAAMM,EAAQN,EAAUN,GACX,MAATY,IACFO,KAAKC,GAAyBE,IAAItB,GAC9BA,EAAKyB,SAAS,KAChBf,EAAMiB,YAAY3B,EAAMY,GAGvBF,EAAcV,GAAQY,EAG5B,CACD,OAAOgB,CACR"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/node/directives/template-content.js b/front_end/third_party/lit-html/package/node/directives/template-content.js
new file mode 100644
index 0000000000000000000000000000000000000000..df30e5b53a3d78d76e55ef72f7d08cce66477cb0
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/template-content.js
@@ -0,0 +1,7 @@
+import{noChange as t}from"../lit-html.js";import{directive as r,Directive as e,PartType as n}from"../directive.js";
+/**
+ * @license
+ * Copyright 2020 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */const o=r(class extends e{constructor(t){if(super(t),t.type!==n.CHILD)throw Error("templateContent can only be used in child bindings")}render(r){return this.ft===r?t:(this.ft=r,document.importNode(r.content,!0))}});export{o as templateContent};
+//# sourceMappingURL=template-content.js.map




diff --git a/front_end/third_party/lit-html/package/node/directives/template-content.js.map b/front_end/third_party/lit-html/package/node/directives/template-content.js.map
new file mode 100644
index 0000000000000000000000000000000000000000..7d06c6e5f362dad1794c24a1b5aab1d9580945b7
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/template-content.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"template-content.js","sources":["../../src/directives/template-content.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2020 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {noChange} from '../lit-html.js';\nimport {directive, Directive, PartInfo, PartType} from '../directive.js';\n\nclass TemplateContentDirective extends Directive {\n  private _previousTemplate?: HTMLTemplateElement;\n\n  constructor(partInfo: PartInfo) {\n    super(partInfo);\n    if (partInfo.type !== PartType.CHILD) {\n      throw new Error('templateContent can only be used in child bindings');\n    }\n  }\n\n  render(template: HTMLTemplateElement) {\n    if (this._previousTemplate === template) {\n      return noChange;\n    }\n    this._previousTemplate = template;\n    return document.importNode(template.content, true);\n  }\n}\n\n/**\n * Renders the content of a template element as HTML.\n *\n * Note, the template should be developer controlled and not user controlled.\n * Rendering a user-controlled template with this directive\n * could lead to cross-site-scripting vulnerabilities.\n */\nexport const templateContent = directive(TemplateContentDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {TemplateContentDirective};\n"],"names":["templateContent","directive","Directive","constructor","partInfo","super","type","PartType","CHILD","Error","render","template","this","_previousTemplate","noChange","document","importNode","content"],"mappings":";;;;;SAmCaA,EAAkBC,EA1B/B,cAAuCC,EAGrCC,YAAYC,GAEV,GADAC,MAAMD,GACFA,EAASE,OAASC,EAASC,MAC7B,MAAUC,MAAM,qDAEnB,CAEDC,OAAOC,GACL,OAAIC,KAAKC,KAAsBF,EACtBG,GAETF,KAAKC,GAAoBF,EAClBI,SAASC,WAAWL,EAASM,SAAS,GAC9C"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/node/directives/unsafe-html.js b/front_end/third_party/lit-html/package/node/directives/unsafe-html.js
new file mode 100644
index 0000000000000000000000000000000000000000..2e0425779ba9df456717556f9544e4ea4a93bbe3
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/unsafe-html.js
@@ -0,0 +1,7 @@
+import{nothing as t,noChange as i}from"../lit-html.js";import{Directive as r,PartType as s,directive as n}from"../directive.js";
+/**
+ * @license
+ * Copyright 2017 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */class e extends r{constructor(i){if(super(i),this.it=t,i.type!==s.CHILD)throw Error(this.constructor.directiveName+"() can only be used in child bindings")}render(r){if(r===t||null==r)return this._t=void 0,this.it=r;if(r===i)return r;if("string"!=typeof r)throw Error(this.constructor.directiveName+"() called with a non-string value");if(r===this.it)return this._t;this.it=r;const s=[r];return s.raw=s,this._t={_$litType$:this.constructor.resultType,strings:s,values:[]}}}e.directiveName="unsafeHTML",e.resultType=1;const o=n(e);export{e as UnsafeHTMLDirective,o as unsafeHTML};
+//# sourceMappingURL=unsafe-html.js.map




diff --git a/front_end/third_party/lit-html/package/node/directives/unsafe-html.js.map b/front_end/third_party/lit-html/package/node/directives/unsafe-html.js.map
new file mode 100644
index 0000000000000000000000000000000000000000..28c99b60ddbdb959f531ae5bbc2a469cc9b62e3e
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/unsafe-html.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"unsafe-html.js","sources":["../../src/directives/unsafe-html.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {nothing, TemplateResult, noChange} from '../lit-html.js';\nimport {directive, Directive, PartInfo, PartType} from '../directive.js';\n\nconst HTML_RESULT = 1;\n\nexport class UnsafeHTMLDirective extends Directive {\n  static directiveName = 'unsafeHTML';\n  static resultType = HTML_RESULT;\n\n  private _value: unknown = nothing;\n  private _templateResult?: TemplateResult;\n\n  constructor(partInfo: PartInfo) {\n    super(partInfo);\n    if (partInfo.type !== PartType.CHILD) {\n      throw new Error(\n        `${\n          (this.constructor as typeof UnsafeHTMLDirective).directiveName\n        }() can only be used in child bindings`\n      );\n    }\n  }\n\n  render(value: string | typeof nothing | typeof noChange | undefined | null) {\n    if (value === nothing || value == null) {\n      this._templateResult = undefined;\n      return (this._value = value);\n    }\n    if (value === noChange) {\n      return value;\n    }\n    if (typeof value != 'string') {\n      throw new Error(\n        `${\n          (this.constructor as typeof UnsafeHTMLDirective).directiveName\n        }() called with a non-string value`\n      );\n    }\n    if (value === this._value) {\n      return this._templateResult;\n    }\n    this._value = value;\n    const strings = [value] as unknown as TemplateStringsArray;\n    // eslint-disable-next-line @typescript-eslint/no-explicit-any\n    (strings as any).raw = strings;\n    // WARNING: impersonating a TemplateResult like this is extremely\n    // dangerous. Third-party directives should not do this.\n    return (this._templateResult = {\n      // Cast to a known set of integers that satisfy ResultType so that we\n      // don't have to export ResultType and possibly encourage this pattern.\n      // This property needs to remain unminified.\n      ['_$litType$']: (this.constructor as typeof UnsafeHTMLDirective)\n        .resultType as 1 | 2,\n      strings,\n      values: [],\n    });\n  }\n}\n\n/**\n * Renders the result as HTML, rather than text.\n *\n * The values `undefined`, `null`, and `nothing`, will all result in no content\n * (empty string) being rendered.\n *\n * Note, this is unsafe to use with any user-provided input that hasn't been\n * sanitized or escaped, as it may lead to cross-site-scripting\n * vulnerabilities.\n */\nexport const unsafeHTML = directive(UnsafeHTMLDirective);\n"],"names":["UnsafeHTMLDirective","Directive","constructor","partInfo","super","this","_value","nothing","type","PartType","CHILD","Error","directiveName","render","value","_templateResult","undefined","noChange","strings","raw","_$litType$","resultType","values","unsafeHTML","directive"],"mappings":";;;;;GAWM,MAAOA,UAA4BC,EAOvCC,YAAYC,GAEV,GADAC,MAAMD,GAJAE,KAAMC,GAAYC,EAKpBJ,EAASK,OAASC,EAASC,MAC7B,MAAUC,MAELN,KAAKH,YAA2CU,cADnD,wCAKL,CAEDC,OAAOC,GACL,GAAIA,IAAUP,GAAoB,MAATO,EAEvB,OADAT,KAAKU,QAAkBC,EACfX,KAAKC,GAASQ,EAExB,GAAIA,IAAUG,EACZ,OAAOH,EAET,GAAoB,iBAATA,EACT,MAAUH,MAELN,KAAKH,YAA2CU,cADnD,qCAKJ,GAAIE,IAAUT,KAAKC,GACjB,OAAOD,KAAKU,GAEdV,KAAKC,GAASQ,EACd,MAAMI,EAAU,CAACJ,GAKjB,OAHCI,EAAgBC,IAAMD,EAGfb,KAAKU,GAAkB,CAI7BK,WAAiBf,KAAKH,YACnBmB,WACHH,UACAI,OAAQ,GAEX,EAlDMtB,EAAaY,cAAG,aAChBZ,EAAUqB,WAJC,QAkEPE,EAAaC,EAAUxB"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/node/directives/unsafe-svg.js b/front_end/third_party/lit-html/package/node/directives/unsafe-svg.js
new file mode 100644
index 0000000000000000000000000000000000000000..9390021f6de1cb0cacae2bb103e5879b5dc0a858
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/unsafe-svg.js
@@ -0,0 +1,7 @@
+import{directive as s}from"../directive.js";import{UnsafeHTMLDirective as e}from"./unsafe-html.js";
+/**
+ * @license
+ * Copyright 2017 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */class t extends e{}t.directiveName="unsafeSVG",t.resultType=2;const o=s(t);export{o as unsafeSVG};
+//# sourceMappingURL=unsafe-svg.js.map




diff --git a/front_end/third_party/lit-html/package/node/directives/unsafe-svg.js.map b/front_end/third_party/lit-html/package/node/directives/unsafe-svg.js.map
new file mode 100644
index 0000000000000000000000000000000000000000..dc5b1b0a4846a76e582623243a01a618b6a6467d
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/unsafe-svg.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"unsafe-svg.js","sources":["../../src/directives/unsafe-svg.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {directive} from '../directive.js';\nimport {UnsafeHTMLDirective} from './unsafe-html.js';\n\nconst SVG_RESULT = 2;\n\nclass UnsafeSVGDirective extends UnsafeHTMLDirective {\n  static override directiveName = 'unsafeSVG';\n  static override resultType = SVG_RESULT;\n}\n\n/**\n * Renders the result as SVG, rather than text.\n *\n * The values `undefined`, `null`, and `nothing`, will all result in no content\n * (empty string) being rendered.\n *\n * Note, this is unsafe to use with any user-provided input that hasn't been\n * sanitized or escaped, as it may lead to cross-site-scripting\n * vulnerabilities.\n */\nexport const unsafeSVG = directive(UnsafeSVGDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\nexport type {UnsafeSVGDirective};\n"],"names":["UnsafeSVGDirective","UnsafeHTMLDirective","directiveName","resultType","unsafeSVG","directive"],"mappings":";;;;;GAWA,MAAMA,UAA2BC,GACfD,EAAaE,cAAG,YAChBF,EAAUG,WAJT,QAiBNC,EAAYC,EAAUL"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/node/directives/until.js b/front_end/third_party/lit-html/package/node/directives/until.js
new file mode 100644
index 0000000000000000000000000000000000000000..0799066d82ad9526ee13c832b9266f08ee714f0f
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/until.js
@@ -0,0 +1,7 @@
+import{noChange as t}from"../lit-html.js";import{isPrimitive as s}from"../directive-helpers.js";import{AsyncDirective as i}from"../async-directive.js";import{PseudoWeakRef as r,Pauser as e}from"./private-async-helpers.js";import{directive as o}from"../directive.js";
+/**
+ * @license
+ * Copyright 2017 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */const n=t=>!s(t)&&"function"==typeof t.then;class h extends i{constructor(){super(...arguments),this._$Cwt=1073741823,this._$Cyt=[],this._$CK=new r(this),this._$CX=new e}render(...s){var i;return null!==(i=s.find((t=>!n(t))))&&void 0!==i?i:t}update(s,i){const r=this._$Cyt;let e=r.length;this._$Cyt=i;const o=this._$CK,h=this._$CX;this.isConnected||this.disconnected();for(let t=0;t<i.length&&!(t>this._$Cwt);t++){const s=i[t];if(!n(s))return this._$Cwt=t,s;t<e&&s===r[t]||(this._$Cwt=1073741823,e=0,Promise.resolve(s).then((async t=>{for(;h.get();)await h.get();const i=o.deref();if(void 0!==i){const r=i._$Cyt.indexOf(s);r>-1&&r<i._$Cwt&&(i._$Cwt=r,i.setValue(t))}})))}return t}disconnected(){this._$CK.disconnect(),this._$CX.pause()}reconnected(){this._$CK.reconnect(this),this._$CX.resume()}}const c=o(h);export{h as UntilDirective,c as until};
+//# sourceMappingURL=until.js.map




diff --git a/front_end/third_party/lit-html/package/node/directives/until.js.map b/front_end/third_party/lit-html/package/node/directives/until.js.map
new file mode 100644
index 0000000000000000000000000000000000000000..3c86c3b7627f669b4ae2e8747c95073d6ed9431b
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/until.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"until.js","sources":["../../src/directives/until.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {Part, noChange} from '../lit-html.js';\nimport {isPrimitive} from '../directive-helpers.js';\nimport {directive, AsyncDirective} from '../async-directive.js';\nimport {Pauser, PseudoWeakRef} from './private-async-helpers.js';\n\nconst isPromise = (x: unknown) => {\n  return !isPrimitive(x) && typeof (x as {then?: unknown}).then === 'function';\n};\n// Effectively infinity, but a SMI.\nconst _infinity = 0x3fffffff;\n\nexport class UntilDirective extends AsyncDirective {\n  private __lastRenderedIndex: number = _infinity;\n  private __values: unknown[] = [];\n  private __weakThis = new PseudoWeakRef(this);\n  private __pauser = new Pauser();\n\n  render(...args: Array<unknown>) {\n    return args.find((x) => !isPromise(x)) ?? noChange;\n  }\n\n  override update(_part: Part, args: Array<unknown>) {\n    const previousValues = this.__values;\n    let previousLength = previousValues.length;\n    this.__values = args;\n\n    const weakThis = this.__weakThis;\n    const pauser = this.__pauser;\n\n    // If our initial render occurs while disconnected, ensure that the pauser\n    // and weakThis are in the disconnected state\n    if (!this.isConnected) {\n      this.disconnected();\n    }\n\n    for (let i = 0; i < args.length; i++) {\n      // If we've rendered a higher-priority value already, stop.\n      if (i > this.__lastRenderedIndex) {\n        break;\n      }\n\n      const value = args[i];\n\n      // Render non-Promise values immediately\n      if (!isPromise(value)) {\n        this.__lastRenderedIndex = i;\n        // Since a lower-priority value will never overwrite a higher-priority\n        // synchronous value, we can stop processing now.\n        return value;\n      }\n\n      // If this is a Promise we've already handled, skip it.\n      if (i < previousLength && value === previousValues[i]) {\n        continue;\n      }\n\n      // We have a Promise that we haven't seen before, so priorities may have\n      // changed. Forget what we rendered before.\n      this.__lastRenderedIndex = _infinity;\n      previousLength = 0;\n\n      // Note, the callback avoids closing over `this` so that the directive\n      // can be gc'ed before the promise resolves; instead `this` is retrieved\n      // from `weakThis`, which can break the hard reference in the closure when\n      // the directive disconnects\n      Promise.resolve(value).then(async (result: unknown) => {\n        // If we're disconnected, wait until we're (maybe) reconnected\n        // The while loop here handles the case that the connection state\n        // thrashes, causing the pauser to resume and then get re-paused\n        while (pauser.get()) {\n          await pauser.get();\n        }\n        // If the callback gets here and there is no `this`, it means that the\n        // directive has been disconnected and garbage collected and we don't\n        // need to do anything else\n        const _this = weakThis.deref();\n        if (_this !== undefined) {\n          const index = _this.__values.indexOf(value);\n          // If state.values doesn't contain the value, we've re-rendered without\n          // the value, so don't render it. Then, only render if the value is\n          // higher-priority than what's already been rendered.\n          if (index > -1 && index < _this.__lastRenderedIndex) {\n            _this.__lastRenderedIndex = index;\n            _this.setValue(result);\n          }\n        }\n      });\n    }\n\n    return noChange;\n  }\n\n  override disconnected() {\n    this.__weakThis.disconnect();\n    this.__pauser.pause();\n  }\n\n  override reconnected() {\n    this.__weakThis.reconnect(this);\n    this.__pauser.resume();\n  }\n}\n\n/**\n * Renders one of a series of values, including Promises, to a Part.\n *\n * Values are rendered in priority order, with the first argument having the\n * highest priority and the last argument having the lowest priority. If a\n * value is a Promise, low-priority values will be rendered until it resolves.\n *\n * The priority of values can be used to create placeholder content for async\n * data. For example, a Promise with pending content can be the first,\n * highest-priority, argument, and a non_promise loading indicator template can\n * be used as the second, lower-priority, argument. The loading indicator will\n * render immediately, and the primary content will render when the Promise\n * resolves.\n *\n * Example:\n *\n * ```js\n * const content = fetch('./content.txt').then(r => r.text());\n * html`${until(content, html`<span>Loading...</span>`)}`\n * ```\n */\nexport const until = directive(UntilDirective);\n\n/**\n * The type of the class that powers this directive. Necessary for naming the\n * directive's return type.\n */\n// export type {UntilDirective};\n"],"names":["isPromise","x","isPrimitive","then","UntilDirective","AsyncDirective","constructor","this","__lastRenderedIndex","__values","__weakThis","PseudoWeakRef","__pauser","Pauser","render","args","find","_a","noChange","update","_part","previousValues","previousLength","length","weakThis","pauser","isConnected","disconnected","i","value","Promise","resolve","async","result","get","_this","deref","undefined","index","indexOf","setValue","disconnect","pause","reconnected","reconnect","resume","until","directive"],"mappings":";;;;;GAWA,MAAMA,EAAaC,IACTC,EAAYD,IAA8C,mBAAhCA,EAAuBE,KAKrD,MAAOC,UAAuBC,EAApCC,kCACUC,KAAmBC,MAHX,WAIRD,KAAQE,MAAc,GACtBF,KAAAG,KAAa,IAAIC,EAAcJ,MAC/BA,KAAAK,KAAW,IAAIC,CAsFxB,CApFCC,UAAUC,SACR,OAAsC,UAA/BA,EAAKC,MAAMf,IAAOD,EAAUC,YAAG,IAAAgB,EAAAA,EAAIC,CAC3C,CAEQC,OAAOC,EAAaL,GAC3B,MAAMM,EAAiBd,KAAKE,MAC5B,IAAIa,EAAiBD,EAAeE,OACpChB,KAAKE,MAAWM,EAEhB,MAAMS,EAAWjB,KAAKG,KAChBe,EAASlB,KAAKK,KAIfL,KAAKmB,aACRnB,KAAKoB,eAGP,IAAK,IAAIC,EAAI,EAAGA,EAAIb,EAAKQ,UAEnBK,EAAIrB,KAAKC,OAFkBoB,IAAK,CAMpC,MAAMC,EAAQd,EAAKa,GAGnB,IAAK5B,EAAU6B,GAIb,OAHAtB,KAAKC,MAAsBoB,EAGpBC,EAILD,EAAIN,GAAkBO,IAAUR,EAAeO,KAMnDrB,KAAKC,MAjDO,WAkDZc,EAAiB,EAMjBQ,QAAQC,QAAQF,GAAO1B,MAAK6B,MAAOC,IAIjC,KAAOR,EAAOS,aACNT,EAAOS,MAKf,MAAMC,EAAQX,EAASY,QACvB,QAAcC,IAAVF,EAAqB,CACvB,MAAMG,EAAQH,EAAM1B,MAAS8B,QAAQV,GAIjCS,GAAS,GAAKA,EAAQH,EAAM3B,QAC9B2B,EAAM3B,MAAsB8B,EAC5BH,EAAMK,SAASP,GAElB,KAEJ,CAED,OAAOf,CACR,CAEQS,eACPpB,KAAKG,KAAW+B,aAChBlC,KAAKK,KAAS8B,OACf,CAEQC,cACPpC,KAAKG,KAAWkC,UAAUrC,MAC1BA,KAAKK,KAASiC,QACf,QAwBUC,EAAQC,EAAU3C"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/node/directives/when.js b/front_end/third_party/lit-html/package/node/directives/when.js
new file mode 100644
index 0000000000000000000000000000000000000000..70a4b679c14330d8291a5bff0ce17aaf2998e829
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/when.js
@@ -0,0 +1,7 @@
+/**
+ * @license
+ * Copyright 2021 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */
+function n(n,o,r){return n?o():null==r?void 0:r()}export{n as when};
+//# sourceMappingURL=when.js.map




diff --git a/front_end/third_party/lit-html/package/node/directives/when.js.map b/front_end/third_party/lit-html/package/node/directives/when.js.map
new file mode 100644
index 0000000000000000000000000000000000000000..97e0e85de8fbb52019be40f94d572e1e4e3d31f6
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/directives/when.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"when.js","sources":["../../src/directives/when.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n/**\n * When `condition` is true, returns the result of calling `trueCase()`, else\n * returns the result of calling `falseCase()` if `falseCase` is defined.\n *\n * This is a convenience wrapper around a ternary expression that makes it a\n * little nicer to write an inline conditional without an else.\n *\n * @example\n *\n * ```ts\n * render() {\n *   return html`\n *     ${when(this.user, () => html`User: ${this.user.username}`, () => html`Sign In...`)}\n *   `;\n * }\n * ```\n */\nexport function when<T, F>(\n  condition: true,\n  trueCase: () => T,\n  falseCase?: () => F\n): T;\nexport function when<T, F = undefined>(\n  condition: false,\n  trueCase: () => T,\n  falseCase?: () => F\n): F;\nexport function when<T, F = undefined>(\n  condition: unknown,\n  trueCase: () => T,\n  falseCase?: () => F\n): T | F;\nexport function when(\n  condition: unknown,\n  trueCase: () => unknown,\n  falseCase?: () => unknown\n): unknown {\n  return condition ? trueCase() : falseCase?.();\n}\n"],"names":["when","condition","trueCase","falseCase"],"mappings":";;;;;SAsCgBA,EACdC,EACAC,EACAC,GAEA,OAAOF,EAAYC,IAAaC,aAAA,EAAAA,GAClC"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/node/experimental-hydrate.js b/front_end/third_party/lit-html/package/node/experimental-hydrate.js
new file mode 100644
index 0000000000000000000000000000000000000000..cc8da5fd4cbc1ab09ea8e6d92f05dd32b9a46dde
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/experimental-hydrate.js
@@ -0,0 +1,7 @@
+import{noChange as e,_$LH as t}from"./lit-html.js";import{PartType as r}from"./directive.js";import{isPrimitive as n,isTemplateResult as o,isSingleExpression as l}from"./directive-helpers.js";
+/**
+ * @license
+ * Copyright 2019 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */const{R:i,D:a,V:s,I:c,F:d}=t,f=(e,t,r={})=>{if(void 0!==t._$litPart$)throw Error("container already contains a live render");let n,o;const l=[],i=document.createTreeWalker(t,NodeFilter.SHOW_COMMENT,null,!1);let a;for(;null!==(a=i.nextNode());){const t=a.data;if(t.startsWith("lit-part")){if(0===l.length&&void 0!==n)throw Error("there must be only one root part per container");o=p(e,a,l,r),null!=n||(n=o)}else if(t.startsWith("lit-node"))h(a,l,r);else if(t.startsWith("/lit-part")){if(1===l.length&&o!==n)throw Error("internal error");o=u(a,o,l)}}console.assert(void 0!==n,"there should be exactly one root part in a render container"),t._$litPart$=n},p=(t,r,l,d)=>{let f,p;if(0===l.length)p=new c(r,null,void 0,d),f=t;else{const e=l[l.length-1];if("template-instance"===e.type)p=new c(r,null,e.instance,d),e.instance.u.push(p),f=e.result.values[e.instancePartIndex++],e.templatePartIndex++;else if("iterable"===e.type){p=new c(r,null,e.part,d);const t=e.iterator.next();if(t.done)throw f=void 0,e.done=!0,Error("Unhandled shorter than expected iterable");f=t.value,e.part._$AH.push(p)}else p=new c(r,null,e.part,d)}if(f=s(p,f),f===e)l.push({part:p,type:"leaf"});else if(n(f))l.push({part:p,type:"leaf"}),p._$AH=f;else if(o(f)){const e="lit-part "+m(f);if(r.data!==e)throw Error("Hydration value mismatch: Unexpected TemplateResult rendered to part");{const e=c.prototype._$AC(f),t=new i(e,p);l.push({type:"template-instance",instance:t,part:p,templatePartIndex:0,instancePartIndex:0,result:f}),p._$AH=t}}else a(f)?(l.push({part:p,type:"iterable",value:f,iterator:f[Symbol.iterator](),done:!1}),p._$AH=[]):(l.push({part:p,type:"leaf"}),p._$AH=null==f?"":f);return p},u=(e,t,r)=>{if(void 0===t)throw Error("unbalanced part marker");t._$AB=e;const n=r.pop();if("iterable"===n.type&&!n.iterator.next().done)throw Error("unexpected longer than expected iterable");if(r.length>0)return r[r.length-1].part},h=(e,t,n)=>{var o;const i=/lit-node (\d+)/.exec(e.data),a=parseInt(i[1]),c=null!==(o=e.previousElementSibling)&&void 0!==o?o:e.parentElement;if(null===c)throw Error("could not find node for attribute parts");c.removeAttribute("defer-hydration");const f=t[t.length-1];if("template-instance"!==f.type)throw Error("internal error");{const e=f.instance;for(;;){const t=e._$AD.parts[f.templatePartIndex];if(void 0===t||t.type!==r.ATTRIBUTE&&t.type!==r.ELEMENT||t.index!==a)break;if(t.type===r.ATTRIBUTE){const o=new t.ctor(c,t.name,t.strings,f.instance,n),i=l(o)?f.result.values[f.instancePartIndex]:f.result.values,a=!(o.type===r.EVENT||o.type===r.PROPERTY);o._$AI(i,o,f.instancePartIndex,a),f.instancePartIndex+=t.strings.length-1,e.u.push(o)}else{const t=new d(c,f.instance,n);s(t,f.result.values[f.instancePartIndex++]),e.u.push(t)}f.templatePartIndex++}}},m=e=>{const t=new Uint32Array(2).fill(5381);for(const r of e.strings)for(let e=0;e<r.length;e++)t[e%2]=33*t[e%2]^r.charCodeAt(e);return btoa(String.fromCharCode(...new Uint8Array(t.buffer)))};export{m as digestForTemplateResult,f as hydrate};
+//# sourceMappingURL=experimental-hydrate.js.map




diff --git a/front_end/third_party/lit-html/package/node/experimental-hydrate.js.map b/front_end/third_party/lit-html/package/node/experimental-hydrate.js.map
new file mode 100644
index 0000000000000000000000000000000000000000..f4c670ffb65b6268ccb482146bf1b26a4d650440
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/experimental-hydrate.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"experimental-hydrate.js","sources":["../src/experimental-hydrate.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2019 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport type {TemplateResult} from './lit-html.js';\n\nimport {noChange, RenderOptions, _$LH} from './lit-html.js';\nimport {AttributePartInfo, PartType} from './directive.js';\nimport {\n  isPrimitive,\n  isSingleExpression,\n  isTemplateResult,\n} from './directive-helpers.js';\n\nconst {\n  _TemplateInstance: TemplateInstance,\n  _isIterable: isIterable,\n  _resolveDirective: resolveDirective,\n  _ChildPart: ChildPart,\n  _ElementPart: ElementPart,\n} = _$LH;\n\ntype ChildPart = InstanceType<typeof ChildPart>;\ntype TemplateInstance = InstanceType<typeof TemplateInstance>;\n\n/**\n * Information needed to rehydrate a single TemplateResult.\n */\ntype ChildPartState =\n  | {\n      type: 'leaf';\n      /** The ChildPart that the result is rendered to */\n      part: ChildPart;\n    }\n  | {\n      type: 'iterable';\n      /** The ChildPart that the result is rendered to */\n      part: ChildPart;\n      value: Iterable<unknown>;\n      iterator: Iterator<unknown>;\n      done: boolean;\n    }\n  | {\n      type: 'template-instance';\n      /** The ChildPart that the result is rendered to */\n      part: ChildPart;\n\n      result: TemplateResult;\n\n      /** The TemplateInstance created from the TemplateResult */\n      instance: TemplateInstance;\n\n      /**\n       * The index of the next Template part to be hydrated. This is mutable and\n       * updated as the tree walk discovers new part markers at the right level in\n       * the template instance tree.  Note there is only one Template part per\n       * attribute with (one or more) bindings.\n       */\n      templatePartIndex: number;\n\n      /**\n       * The index of the next TemplateInstance part to be hydrated. This is used\n       * to retrieve the value from the TemplateResult and initialize the\n       * TemplateInstance parts' values for dirty-checking on first render.\n       */\n      instancePartIndex: number;\n    };\n\n/**\n * hydrate() operates on a container with server-side rendered content and\n * restores the client side data structures needed for lit-html updates such as\n * TemplateInstances and Parts. After calling `hydrate`, lit-html will behave as\n * if it initially rendered the DOM, and any subsequent updates will update\n * efficiently, the same as if lit-html had rendered the DOM on the client.\n *\n * hydrate() must be called on DOM that adheres the to lit-ssr structure for\n * parts. ChildParts must be represented with both a start and end comment\n * marker, and ChildParts that contain a TemplateInstance must have the template\n * digest written into the comment data.\n *\n * Since render() encloses its output in a ChildPart, there must always be a root\n * ChildPart.\n *\n * Example (using for # ... for annotations in HTML)\n *\n * Given this input:\n *\n *   html`<div class=${x}>${y}</div>`\n *\n * The SSR DOM is:\n *\n *   <!--lit-part AEmR7W+R0Ak=-->  # Start marker for the root ChildPart created\n *                                 # by render(). Includes the digest of the\n *                                 # template\n *   <div class=\"TEST_X\">\n *     <!--lit-node 0--> # Indicates there are attribute bindings here\n *                           # The number is the depth-first index of the parent\n *                           # node in the template.\n *     <!--lit-part-->  # Start marker for the ${x} expression\n *     TEST_Y\n *     <!--/lit-part-->  # End marker for the ${x} expression\n *   </div>\n *\n *   <!--/lit-part-->  # End marker for the root ChildPart\n *\n * @param rootValue\n * @param container\n * @param userOptions\n */\nexport const hydrate = (\n  rootValue: unknown,\n  container: Element | DocumentFragment,\n  options: Partial<RenderOptions> = {}\n) => {\n  // TODO(kschaaf): Do we need a helper for _$litPart$ (\"part for node\")?\n  // This property needs to remain unminified.\n  // eslint-disable-next-line @typescript-eslint/no-explicit-any\n  if ((container as any)['_$litPart$'] !== undefined) {\n    throw new Error('container already contains a live render');\n  }\n\n  // Since render() creates a ChildPart to render into, we'll always have\n  // exactly one root part. We need to hold a reference to it so we can set\n  // it in the parts cache.\n  let rootPart: ChildPart | undefined = undefined;\n\n  // When we are in-between ChildPart markers, this is the current ChildPart.\n  // It's needed to be able to set the ChildPart's endNode when we see a\n  // close marker\n  let currentChildPart: ChildPart | undefined = undefined;\n\n  // Used to remember parent template state as we recurse into nested\n  // templates\n  const stack: Array<ChildPartState> = [];\n\n  const walker = document.createTreeWalker(\n    container,\n    NodeFilter.SHOW_COMMENT,\n    null,\n    false\n  );\n  let marker: Comment | null;\n\n  // Walk the DOM looking for part marker comments\n  while ((marker = walker.nextNode() as Comment | null) !== null) {\n    const markerText = marker.data;\n    if (markerText.startsWith('lit-part')) {\n      if (stack.length === 0 && rootPart !== undefined) {\n        throw new Error('there must be only one root part per container');\n      }\n      // Create a new ChildPart and push it onto the stack\n      currentChildPart = openChildPart(rootValue, marker, stack, options);\n      rootPart ??= currentChildPart;\n    } else if (markerText.startsWith('lit-node')) {\n      // Create and hydrate attribute parts into the current ChildPart on the\n      // stack\n      createAttributeParts(marker, stack, options);\n    } else if (markerText.startsWith('/lit-part')) {\n      // Close the current ChildPart, and pop the previous one off the stack\n      if (stack.length === 1 && currentChildPart !== rootPart) {\n        throw new Error('internal error');\n      }\n      currentChildPart = closeChildPart(marker, currentChildPart, stack);\n    }\n  }\n  console.assert(\n    rootPart !== undefined,\n    'there should be exactly one root part in a render container'\n  );\n  // This property needs to remain unminified.\n  // eslint-disable-next-line @typescript-eslint/no-explicit-any\n  (container as any)['_$litPart$'] = rootPart;\n};\n\nconst openChildPart = (\n  rootValue: unknown,\n  marker: Comment,\n  stack: Array<ChildPartState>,\n  options: RenderOptions\n) => {\n  let value: unknown;\n  // We know the startNode now. We'll know the endNode when we get to\n  // the matching marker and set it in closeChildPart()\n  // TODO(kschaaf): Current constructor takes both nodes\n  let part;\n  if (stack.length === 0) {\n    part = new ChildPart(marker, null, undefined, options);\n    value = rootValue;\n  } else {\n    const state = stack[stack.length - 1];\n    if (state.type === 'template-instance') {\n      part = new ChildPart(marker, null, state.instance, options);\n      state.instance._parts.push(part);\n      value = state.result.values[state.instancePartIndex++];\n      state.templatePartIndex++;\n    } else if (state.type === 'iterable') {\n      part = new ChildPart(marker, null, state.part, options);\n      const result = state.iterator.next();\n      if (result.done) {\n        value = undefined;\n        state.done = true;\n        throw new Error('Unhandled shorter than expected iterable');\n      } else {\n        value = result.value;\n      }\n      (state.part._$committedValue as Array<ChildPart>).push(part);\n    } else {\n      // state.type === 'leaf'\n      // TODO(kschaaf): This is unexpected, and likely a result of a primitive\n      // been rendered on the client when a TemplateResult was rendered on the\n      // server; this part will be hydrated but not used. We can detect it, but\n      // we need to decide what to do in this case. Note that this part won't be\n      // retained by any parent TemplateInstance, since a primitive had been\n      // rendered in its place.\n      // https://github.com/lit/lit/issues/1434\n      // throw new Error('Hydration value mismatch: Found a TemplateInstance' +\n      //  'where a leaf value was expected');\n      part = new ChildPart(marker, null, state.part, options);\n    }\n  }\n\n  // Initialize the ChildPart state depending on the type of value and push\n  // it onto the stack. This logic closely follows the ChildPart commit()\n  // cascade order:\n  // 1. directive\n  // 2. noChange\n  // 3. primitive (note strings must be handled before iterables, since they\n  //    are iterable)\n  // 4. TemplateResult\n  // 5. Node (not yet implemented, but fallback handling is fine)\n  // 6. Iterable\n  // 7. nothing (handled in fallback)\n  // 8. Fallback for everything else\n  value = resolveDirective(part, value);\n  if (value === noChange) {\n    stack.push({part, type: 'leaf'});\n  } else if (isPrimitive(value)) {\n    stack.push({part, type: 'leaf'});\n    part._$committedValue = value;\n    // TODO(kschaaf): We can detect when a primitive is being hydrated on the\n    // client where a TemplateResult was rendered on the server, but we need to\n    // decide on a strategy for what to do next.\n    // https://github.com/lit/lit/issues/1434\n    // if (marker.data !== 'lit-part') {\n    //   throw new Error('Hydration value mismatch: Primitive found where TemplateResult expected');\n    // }\n  } else if (isTemplateResult(value)) {\n    // Check for a template result digest\n    const markerWithDigest = `lit-part ${digestForTemplateResult(value)}`;\n    if (marker.data === markerWithDigest) {\n      const template = ChildPart.prototype._$getTemplate(value);\n      const instance = new TemplateInstance(template, part);\n      stack.push({\n        type: 'template-instance',\n        instance,\n        part,\n        templatePartIndex: 0,\n        instancePartIndex: 0,\n        result: value,\n      });\n      // For TemplateResult values, we set the part value to the\n      // generated TemplateInstance\n      part._$committedValue = instance;\n    } else {\n      // TODO: if this isn't the server-rendered template, do we\n      // need to stop hydrating this subtree? Clear it? Add tests.\n      throw new Error(\n        'Hydration value mismatch: Unexpected TemplateResult rendered to part'\n      );\n    }\n  } else if (isIterable(value)) {\n    // currentChildPart.value will contain an array of ChildParts\n    stack.push({\n      part: part,\n      type: 'iterable',\n      value,\n      iterator: value[Symbol.iterator](),\n      done: false,\n    });\n    part._$committedValue = [];\n  } else {\n    // Fallback for everything else (nothing, Objects, Functions,\n    // etc.): we just initialize the part's value\n    // Note that `Node` value types are not currently supported during\n    // SSR, so that part of the cascade is missing.\n    stack.push({part: part, type: 'leaf'});\n    part._$committedValue = value == null ? '' : value;\n  }\n  return part;\n};\n\nconst closeChildPart = (\n  marker: Comment,\n  part: ChildPart | undefined,\n  stack: Array<ChildPartState>\n): ChildPart | undefined => {\n  if (part === undefined) {\n    throw new Error('unbalanced part marker');\n  }\n\n  part._$endNode = marker;\n\n  const currentState = stack.pop()!;\n\n  if (currentState.type === 'iterable') {\n    if (!currentState.iterator.next().done) {\n      throw new Error('unexpected longer than expected iterable');\n    }\n  }\n\n  if (stack.length > 0) {\n    const state = stack[stack.length - 1];\n    return state.part;\n  } else {\n    return undefined;\n  }\n};\n\nconst createAttributeParts = (\n  comment: Comment,\n  stack: Array<ChildPartState>,\n  options: RenderOptions\n) => {\n  // Get the nodeIndex from DOM. We're only using this for an integrity\n  // check right now, we might not need it.\n  const match = /lit-node (\\d+)/.exec(comment.data)!;\n  const nodeIndex = parseInt(match[1]);\n\n  // For void elements, the node the comment was referring to will be\n  // the previousSibling; for non-void elements, the comment is guaranteed\n  // to be the first child of the element (i.e. it won't have a previousSibling\n  // meaning it should use the parentElement)\n  const node = comment.previousElementSibling ?? comment.parentElement;\n  if (node === null) {\n    throw new Error('could not find node for attribute parts');\n  }\n  // Remove `defer-hydration` attribute, if any\n  node.removeAttribute('defer-hydration');\n\n  const state = stack[stack.length - 1];\n  if (state.type === 'template-instance') {\n    const instance = state.instance;\n    // eslint-disable-next-line no-constant-condition\n    while (true) {\n      // If the next template part is in attribute-position on the current node,\n      // create the instance part for it and prime its state\n      const templatePart = instance._$template.parts[state.templatePartIndex];\n      if (\n        templatePart === undefined ||\n        (templatePart.type !== PartType.ATTRIBUTE &&\n          templatePart.type !== PartType.ELEMENT) ||\n        templatePart.index !== nodeIndex\n      ) {\n        break;\n      }\n\n      if (templatePart.type === PartType.ATTRIBUTE) {\n        // The instance part is created based on the constructor saved in the\n        // template part\n        const instancePart = new templatePart.ctor(\n          node as HTMLElement,\n          templatePart.name,\n          templatePart.strings,\n          state.instance,\n          options\n        );\n\n        const value = isSingleExpression(\n          instancePart as unknown as AttributePartInfo\n        )\n          ? state.result.values[state.instancePartIndex]\n          : state.result.values;\n\n        // Setting the attribute value primes committed value with the resolved\n        // directive value; we only then commit that value for event/property\n        // parts since those were not serialized, and pass `noCommit` for the\n        // others to avoid perf impact of touching the DOM unnecessarily\n        const noCommit = !(\n          instancePart.type === PartType.EVENT ||\n          instancePart.type === PartType.PROPERTY\n        );\n        instancePart._$setValue(\n          value,\n          instancePart,\n          state.instancePartIndex,\n          noCommit\n        );\n        state.instancePartIndex += templatePart.strings.length - 1;\n        instance._parts.push(instancePart);\n      } else {\n        // templatePart.type === PartType.ELEMENT\n        const instancePart = new ElementPart(node, state.instance, options);\n        resolveDirective(\n          instancePart,\n          state.result.values[state.instancePartIndex++]\n        );\n        instance._parts.push(instancePart);\n      }\n      state.templatePartIndex++;\n    }\n  } else {\n    throw new Error('internal error');\n  }\n};\n\n// Number of 32 bit elements to use to create template digests\nconst digestSize = 2;\n// We need to specify a digest to use across rendering environments. This is a\n// simple digest build from a DJB2-ish hash modified from:\n// https://github.com/darkskyapp/string-hash/blob/master/index.js\n// It has been changed to an array of hashes to add additional bits.\n// Goals:\n//  - Extremely low collision rate. We may not be able to detect collisions.\n//  - Extremely fast.\n//  - Extremely small code size.\n//  - Safe to include in HTML comment text or attribute value.\n//  - Easily specifiable and implementable in multiple languages.\n// We don't care about cryptographic suitability.\nexport const digestForTemplateResult = (templateResult: TemplateResult) => {\n  const hashes = new Uint32Array(digestSize).fill(5381);\n\n  for (const s of templateResult.strings) {\n    for (let i = 0; i < s.length; i++) {\n      hashes[i % digestSize] = (hashes[i % digestSize] * 33) ^ s.charCodeAt(i);\n    }\n  }\n  return btoa(String.fromCharCode(...new Uint8Array(hashes.buffer)));\n};\n"],"names":["_TemplateInstance","TemplateInstance","_isIterable","isIterable","_resolveDirective","resolveDirective","_ChildPart","ChildPart","_ElementPart","ElementPart","_$LH","hydrate","rootValue","container","options","undefined","Error","rootPart","currentChildPart","stack","walker","document","createTreeWalker","NodeFilter","SHOW_COMMENT","marker","nextNode","markerText","data","startsWith","length","openChildPart","createAttributeParts","closeChildPart","console","assert","value","part","state","type","instance","_parts","push","result","values","instancePartIndex","templatePartIndex","iterator","next","done","_$committedValue","noChange","isPrimitive","isTemplateResult","markerWithDigest","digestForTemplateResult","template","prototype","_$getTemplate","Symbol","_$endNode","currentState","pop","comment","match","exec","nodeIndex","parseInt","node","_a","previousElementSibling","parentElement","removeAttribute","templatePart","_$template","parts","PartType","ATTRIBUTE","ELEMENT","index","instancePart","ctor","name","strings","isSingleExpression","noCommit","EVENT","PROPERTY","_$setValue","templateResult","hashes","Uint32Array","fill","s","i","charCodeAt","btoa","String","fromCharCode","Uint8Array","buffer"],"mappings":";;;;;GAgBA,MACEA,EAAmBC,EACnBC,EAAaC,EACbC,EAAmBC,EACnBC,EAAYC,EACZC,EAAcC,GACZC,EAyFSC,EAAU,CACrBC,EACAC,EACAC,EAAkC,CAAA,KAKlC,QAAyCC,IAApCF,EAA8B,WACjC,MAAUG,MAAM,4CAMlB,IAAIC,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IW,EAAI,EAAGA,EAAID,EAAE/D,OAAQgE,IAC5BJ,EAAOI,EAjBM,GAiBsC,GAAzBJ,EAAOI,EAjBpB,GAiB4CD,EAAEE,WAAWD,GAG1E,OAAOE,KAAKC,OAAOC,gBAAgB,IAAIC,WAAWT,EAAOU,SAAS"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/node/is-server.js b/front_end/third_party/lit-html/package/node/is-server.js
new file mode 100644
index 0000000000000000000000000000000000000000..74d8b39d035b5990e39d7b32fdab500b0ce75ece
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/is-server.js
@@ -0,0 +1,7 @@
+/**
+ * @license
+ * Copyright 2022 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */
+const o=!0;export{o as isServer};
+//# sourceMappingURL=is-server.js.map




diff --git a/front_end/third_party/lit-html/package/node/is-server.js.map b/front_end/third_party/lit-html/package/node/is-server.js.map
new file mode 100644
index 0000000000000000000000000000000000000000..c33a60038c9a7426ac4e3fd71c61e0798a1b6ef9
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/is-server.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"is-server.js","sources":["../src/is-server.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2022 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n/**\n * @fileoverview\n *\n * This file exports a boolean const whose value will depend on what environment\n * the module is being imported from.\n */\n\nconst NODE_MODE = false;\n\n/**\n * A boolean that will be `true` in server environments like Node, and `false`\n * in browser environments. Note that your server environment or toolchain must\n * support the `\"node\"` export condition for this to be `true`.\n *\n * This can be used when authoring components to change behavior based on\n * whether or not the component is executing in an SSR context.\n */\nexport const isServer = NODE_MODE;\n"],"names":["isServer"],"mappings":";;;;;AAaA,MAUaA,GAVb"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/node/lit-html.js b/front_end/third_party/lit-html/package/node/lit-html.js
new file mode 100644
index 0000000000000000000000000000000000000000..66cec13492b3c4e964572203d274961414dc8bf5
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/lit-html.js
@@ -0,0 +1,7 @@
+/**
+ * @license
+ * Copyright 2017 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */
+var t;const i=globalThis,s=i.trustedTypes,e=s?s.createPolicy("lit-html",{createHTML:t=>t}):void 0,o=`lit$${(Math.random()+"").slice(9)}$`,n="?"+o,l=`<${n}>`,h=void 0===i.document?{createTreeWalker:()=>({})}:document,r=(t="")=>h.createComment(t),d=t=>null===t||"object"!=typeof t&&"function"!=typeof t,u=Array.isArray,c=t=>u(t)||"function"==typeof(null==t?void 0:t[Symbol.iterator]),v=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,a=/-->/g,f=/>/g,_=RegExp(">|[ \t\n\f\r](?:([^\\s\"'>=/]+)([ \t\n\f\r]*=[ \t\n\f\r]*(?:[^ \t\n\f\r\"'`<>=]|(\"|')|))|$)","g"),m=/'/g,p=/"/g,g=/^(?:script|style|textarea|title)$/i,$=t=>(i,...s)=>({_$litType$:t,strings:i,values:s}),y=$(1),x=$(2),T=Symbol.for("lit-noChange"),b=Symbol.for("lit-nothing"),w=new WeakMap,A=h.createTreeWalker(h,129,null,!1),E=(t,i)=>{const s=t.length-1,n=[];let h,r=2===i?"<svg>":"",d=v;for(let i=0;i<s;i++){const s=t[i];let e,u,c=-1,$=0;for(;$<s.length&&(d.lastIndex=$,u=d.exec(s),null!==u);)$=d.lastIndex,d===v?"!--"===u[1]?d=a:void 0!==u[1]?d=f:void 0!==u[2]?(g.test(u[2])&&(h=RegExp("</"+u[2],"g")),d=_):void 0!==u[3]&&(d=_):d===_?">"===u[0]?(d=null!=h?h:v,c=-1):void 0===u[1]?c=-2:(c=d.lastIndex-u[2].length,e=u[1],d=void 0===u[3]?_:'"'===u[3]?p:m):d===p||d===m?d=_:d===a||d===f?d=v:(d=_,h=void 0);const y=d===_&&t[i+1].startsWith("/>")?" ":"";r+=d===v?s+l:c>=0?(n.push(e),s.slice(0,c)+"$lit$"+s.slice(c)+o+y):s+o+(-2===c?(n.push(void 0),i):y)}const u=r+(t[s]||"<?>")+(2===i?"</svg>":"");if(!Array.isArray(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return[void 0!==e?e.createHTML(u):u,n]};class C{constructor({strings:t,_$litType$:i},e){let l;this.parts=[];let h=0,d=0;const u=t.length-1,c=this.parts,[v,a]=E(t,i);if(this.el=C.createElement(v,e),A.currentNode=this.el.content,2===i){const t=this.el.content,i=t.firstChild;i.remove(),t.append(...i.childNodes)}for(;null!==(l=A.nextNode())&&c.length<u;){if(1===l.nodeType){if(l.hasAttributes()){const t=[];for(const i of l.getAttributeNames())if(i.endsWith("$lit$")||i.startsWith(o)){const s=a[d++];if(t.push(i),void 0!==s){const t=l.getAttribute(s.toLowerCase()+"$lit$").split(o),i=/([.?@])?(.*)/.exec(s);c.push({type:1,index:h,name:i[2],strings:t,ctor:"."===i[1]?M:"?"===i[1]?R:"@"===i[1]?H:S})}else c.push({type:6,index:h})}for(const i of t)l.removeAttribute(i)}if(g.test(l.tagName)){const t=l.textContent.split(o),i=t.length-1;if(i>0){l.textContent=s?s.emptyScript:"";for(let s=0;s<i;s++)l.append(t[s],r()),A.nextNode(),c.push({type:2,index:++h});l.append(t[i],r())}}}else if(8===l.nodeType)if(l.data===n)c.push({type:2,index:h});else{let t=-1;for(;-1!==(t=l.data.indexOf(o,t+1));)c.push({type:7,index:h}),t+=o.length-1}h++}}static createElement(t,i){const s=h.createElement("template");return s.innerHTML=t,s}}function P(t,i,s=t,e){var o,n,l,h;if(i===T)return i;let r=void 0!==e?null===(o=s._$Co)||void 0===o?void 0:o[e]:s._$Cl;const u=d(i)?void 0:i._$litDirective$;return(null==r?void 0:r.constructor)!==u&&(null===(n=null==r?void 0:r._$AO)||void 0===n||n.call(r,!1),void 0===u?r=void 0:(r=new u(t),r._$AT(t,s,e)),void 0!==e?(null!==(l=(h=s)._$Co)&&void 0!==l?l:h._$Co=[])[e]=r:s._$Cl=r),void 0!==r&&(i=P(t,r._$AS(t,i.values),r,e)),i}class V{constructor(t,i){this.u=[],this._$AN=void 0,this._$AD=t,this._$AM=i}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}v(t){var i;const{el:{content:s},parts:e}=this._$AD,o=(null!==(i=null==t?void 0:t.creationScope)&&void 0!==i?i:h).importNode(s,!0);A.currentNode=o;let n=A.nextNode(),l=0,r=0,d=e[0];for(;void 0!==d;){if(l===d.index){let i;2===d.type?i=new N(n,n.nextSibling,this,t):1===d.type?i=new d.ctor(n,d.name,d.strings,this,t):6===d.type&&(i=new I(n,this,t)),this.u.push(i),d=e[++r]}l!==(null==d?void 0:d.index)&&(n=A.nextNode(),l++)}return o}p(t){let i=0;for(const s of this.u)void 0!==s&&(void 0!==s.strings?(s._$AI(t,s,i),i+=s.strings.length-2):s._$AI(t[i])),i++}}class N{constructor(t,i,s,e){var o;this.type=2,this._$AH=b,this._$AN=void 0,this._$AA=t,this._$AB=i,this._$AM=s,this.options=e,this._$Cm=null===(o=null==e?void 0:e.isConnected)||void 0===o||o}get _$AU(){var t,i;return null!==(i=null===(t=this._$AM)||void 0===t?void 0:t._$AU)&&void 0!==i?i:this._$Cm}get parentNode(){let t=this._$AA.parentNode;const i=this._$AM;return void 0!==i&&11===t.nodeType&&(t=i.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,i=this){t=P(this,t,i),d(t)?t===b||null==t||""===t?(this._$AH!==b&&this._$AR(),this._$AH=b):t!==this._$AH&&t!==T&&this.g(t):void 0!==t._$litType$?this.$(t):void 0!==t.nodeType?this.T(t):c(t)?this.k(t):this.g(t)}O(t,i=this._$AB){return this._$AA.parentNode.insertBefore(t,i)}T(t){this._$AH!==t&&(this._$AR(),this._$AH=this.O(t))}g(t){this._$AH!==b&&d(this._$AH)?this._$AA.nextSibling.data=t:this.T(h.createTextNode(t)),this._$AH=t}$(t){var i;const{values:s,_$litType$:e}=t,o="number"==typeof e?this._$AC(t):(void 0===e.el&&(e.el=C.createElement(e.h,this.options)),e);if((null===(i=this._$AH)||void 0===i?void 0:i._$AD)===o)this._$AH.p(s);else{const t=new V(o,this),i=t.v(this.options);t.p(s),this.T(i),this._$AH=t}}_$AC(t){let i=w.get(t.strings);return void 0===i&&w.set(t.strings,i=new C(t)),i}k(t){u(this._$AH)||(this._$AH=[],this._$AR());const i=this._$AH;let s,e=0;for(const o of t)e===i.length?i.push(s=new N(this.O(r()),this.O(r()),this,this.options)):s=i[e],s._$AI(o),e++;e<i.length&&(this._$AR(s&&s._$AB.nextSibling,e),i.length=e)}_$AR(t=this._$AA.nextSibling,i){var s;for(null===(s=this._$AP)||void 0===s||s.call(this,!1,!0,i);t&&t!==this._$AB;){const i=t.nextSibling;t.remove(),t=i}}setConnected(t){var i;void 0===this._$AM&&(this._$Cm=t,null===(i=this._$AP)||void 0===i||i.call(this,t))}}class S{constructor(t,i,s,e,o){this.type=1,this._$AH=b,this._$AN=void 0,this.element=t,this.name=i,this._$AM=e,this.options=o,s.length>2||""!==s[0]||""!==s[1]?(this._$AH=Array(s.length-1).fill(new String),this.strings=s):this._$AH=b}get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}_$AI(t,i=this,s,e){const o=this.strings;let n=!1;if(void 0===o)t=P(this,t,i,0),n=!d(t)||t!==this._$AH&&t!==T,n&&(this._$AH=t);else{const e=t;let l,h;for(t=o[0],l=0;l<o.length-1;l++)h=P(this,e[s+l],i,l),h===T&&(h=this._$AH[l]),n||(n=!d(h)||h!==this._$AH[l]),h===b?t=b:t!==b&&(t+=(null!=h?h:"")+o[l+1]),this._$AH[l]=h}n&&!e&&this.j(t)}j(t){t===b?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,null!=t?t:"")}}class M extends S{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===b?void 0:t}}const k=s?s.emptyScript:"";class R extends S{constructor(){super(...arguments),this.type=4}j(t){t&&t!==b?this.element.setAttribute(this.name,k):this.element.removeAttribute(this.name)}}class H extends S{constructor(t,i,s,e,o){super(t,i,s,e,o),this.type=5}_$AI(t,i=this){var s;if((t=null!==(s=P(this,t,i,0))&&void 0!==s?s:b)===T)return;const e=this._$AH,o=t===b&&e!==b||t.capture!==e.capture||t.once!==e.once||t.passive!==e.passive,n=t!==b&&(e===b||o);o&&this.element.removeEventListener(this.name,this,e),n&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){var i,s;"function"==typeof this._$AH?this._$AH.call(null!==(s=null===(i=this.options)||void 0===i?void 0:i.host)&&void 0!==s?s:this.element,t):this._$AH.handleEvent(t)}}class I{constructor(t,i,s){this.element=t,this.type=6,this._$AN=void 0,this._$AM=i,this.options=s}get _$AU(){return this._$AM._$AU}_$AI(t){P(this,t)}}const L={P:"$lit$",A:o,M:n,C:1,L:E,R:V,D:c,V:P,I:N,H:S,N:R,U:H,B:M,F:I},z=i.litHtmlPolyfillSupport;null==z||z(C,N),(null!==(t=i.litHtmlVersions)&&void 0!==t?t:i.litHtmlVersions=[]).push("2.4.0");const W=(t,i,s)=>{var e,o;const n=null!==(e=null==s?void 0:s.renderBefore)&&void 0!==e?e:i;let l=n._$litPart$;if(void 0===l){const t=null!==(o=null==s?void 0:s.renderBefore)&&void 0!==o?o:null;n._$litPart$=l=new N(i.insertBefore(r(),t),t,void 0,null!=s?s:{})}return l._$AI(t),l};export{L as _$LH,y as html,T as noChange,b as nothing,W as render,x as svg};
+//# sourceMappingURL=lit-html.js.map




diff --git a/front_end/third_party/lit-html/package/node/lit-html.js.map b/front_end/third_party/lit-html/package/node/lit-html.js.map
new file mode 100644
index 0000000000000000000000000000000000000000..270558876dca4a24bfb41823730d49c9e222279e
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/lit-html.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"lit-html.js","sources":["../src/lit-html.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n// IMPORTANT: these imports must be type-only\nimport type {Directive, DirectiveResult, PartInfo} from './directive.js';\n\nconst DEV_MODE = true;\nconst ENABLE_EXTRA_SECURITY_HOOKS = true;\nconst ENABLE_SHADYDOM_NOPATCH = true;\nconst NODE_MODE = false;\n// Use window for browser builds because IE11 doesn't have globalThis.\nconst global = NODE_MODE ? globalThis : window;\n\n/**\n * Contains types that are part of the unstable debug API.\n *\n * Everything in this API is not stable and may change or be removed in the future,\n * even on patch releases.\n */\n// eslint-disable-next-line @typescript-eslint/no-namespace\nexport namespace LitUnstable {\n  /**\n   * When Lit is running in dev mode and `window.emitLitDebugLogEvents` is true,\n   * we will emit 'lit-debug' events to window, with live details about the update and render\n   * lifecycle. These can be useful for writing debug tooling and visualizations.\n   *\n   * Please be aware that running with window.emitLitDebugLogEvents has performance overhead,\n   * making certain operations that are normally very cheap (like a no-op render) much slower,\n   * because we must copy data and dispatch events.\n   */\n  // eslint-disable-next-line @typescript-eslint/no-namespace\n  export namespace DebugLog {\n    export type Entry =\n      | TemplatePrep\n      | TemplateInstantiated\n      | TemplateInstantiatedAndUpdated\n      | TemplateUpdating\n      | BeginRender\n      | EndRender\n      | CommitPartEntry\n      | SetPartValue;\n    export interface TemplatePrep {\n      kind: 'template prep';\n      template: Template;\n      strings: TemplateStringsArray;\n      clonableTemplate: HTMLTemplateElement;\n      parts: TemplatePart[];\n    }\n    export interface BeginRender {\n      kind: 'begin render';\n      id: number;\n      value: unknown;\n      container: HTMLElement | DocumentFragment;\n      options: RenderOptions | undefined;\n      part: ChildPart | undefined;\n    }\n    export interface EndRender {\n      kind: 'end render';\n      id: number;\n      value: unknown;\n      container: HTMLElement | DocumentFragment;\n      options: RenderOptions | undefined;\n      part: ChildPart;\n    }\n    export interface TemplateInstantiated {\n      kind: 'template instantiated';\n      template: Template | CompiledTemplate;\n      instance: TemplateInstance;\n      options: RenderOptions | undefined;\n      fragment: Node;\n      parts: Array<Part | undefined>;\n      values: unknown[];\n    }\n    export interface TemplateInstantiatedAndUpdated {\n      kind: 'template instantiated and updated';\n      template: Template | CompiledTemplate;\n      instance: TemplateInstance;\n      options: RenderOptions | undefined;\n      fragment: Node;\n      parts: Array<Part | undefined>;\n      values: unknown[];\n    }\n    export interface TemplateUpdating {\n      kind: 'template updating';\n      template: Template | CompiledTemplate;\n      instance: TemplateInstance;\n      options: RenderOptions | undefined;\n      parts: Array<Part | undefined>;\n      values: unknown[];\n    }\n    export interface SetPartValue {\n      kind: 'set part';\n      part: Part;\n      value: unknown;\n      valueIndex: number;\n      values: unknown[];\n      templateInstance: TemplateInstance;\n    }\n\n    export type CommitPartEntry =\n      | CommitNothingToChildEntry\n      | CommitText\n      | CommitNode\n      | CommitAttribute\n      | CommitProperty\n      | CommitBooleanAttribute\n      | CommitEventListener\n      | CommitToElementBinding;\n\n    export interface CommitNothingToChildEntry {\n      kind: 'commit nothing to child';\n      start: ChildNode;\n      end: ChildNode | null;\n      parent: Disconnectable | undefined;\n      options: RenderOptions | undefined;\n    }\n\n    export interface CommitText {\n      kind: 'commit text';\n      node: Text;\n      value: unknown;\n      options: RenderOptions | undefined;\n    }\n\n    export interface CommitNode {\n      kind: 'commit node';\n      start: Node;\n      parent: Disconnectable | undefined;\n      value: Node;\n      options: RenderOptions | undefined;\n    }\n\n    export interface CommitAttribute {\n      kind: 'commit attribute';\n      element: Element;\n      name: string;\n      value: unknown;\n      options: RenderOptions | undefined;\n    }\n\n    export interface CommitProperty {\n      kind: 'commit property';\n      element: Element;\n      name: string;\n      value: unknown;\n      options: RenderOptions | undefined;\n    }\n\n    export interface CommitBooleanAttribute {\n      kind: 'commit boolean attribute';\n      element: Element;\n      name: string;\n      value: boolean;\n      options: RenderOptions | undefined;\n    }\n\n    export interface CommitEventListener {\n      kind: 'commit event listener';\n      element: Element;\n      name: string;\n      value: unknown;\n      oldListener: unknown;\n      options: RenderOptions | undefined;\n      // True if we're removing the old event listener (e.g. because settings changed, or value is nothing)\n      removeListener: boolean;\n      // True if we're adding a new event listener (e.g. because first render, or settings changed)\n      addListener: boolean;\n    }\n\n    export interface CommitToElementBinding {\n      kind: 'commit to element binding';\n      element: Element;\n      value: unknown;\n      options: RenderOptions | undefined;\n    }\n  }\n}\n\ninterface DebugLoggingWindow {\n  // Even in dev mode, we generally don't want to emit these events, as that's\n  // another level of cost, so only emit them when DEV_MODE is true _and_ when\n  // window.emitLitDebugEvents is true.\n  emitLitDebugLogEvents?: boolean;\n}\n\n/**\n * Useful for visualizing and logging insights into what the Lit template system is doing.\n *\n * Compiled out of prod mode builds.\n */\nconst debugLogEvent = DEV_MODE\n  ? (event: LitUnstable.DebugLog.Entry) => {\n      const shouldEmit = (global as unknown as DebugLoggingWindow)\n        .emitLitDebugLogEvents;\n      if (!shouldEmit) {\n        return;\n      }\n      global.dispatchEvent(\n        new CustomEvent<LitUnstable.DebugLog.Entry>('lit-debug', {\n          detail: event,\n        })\n      );\n    }\n  : undefined;\n// Used for connecting beginRender and endRender events when there are nested\n// renders when errors are thrown preventing an endRender event from being\n// called.\nlet debugLogRenderId = 0;\n\nlet issueWarning: (code: string, warning: string) => void;\n\nif (DEV_MODE) {\n  global.litIssuedWarnings ??= new Set();\n\n  // Issue a warning, if we haven't already.\n  issueWarning = (code: string, warning: string) => {\n    warning += code\n      ? ` See https://lit.dev/msg/${code} for more information.`\n      : '';\n    if (!global.litIssuedWarnings!.has(warning)) {\n      console.warn(warning);\n      global.litIssuedWarnings!.add(warning);\n    }\n  };\n\n  issueWarning(\n    'dev-mode',\n    `Lit is in dev mode. Not recommended for production!`\n  );\n}\n\nconst wrap =\n  ENABLE_SHADYDOM_NOPATCH &&\n  global.ShadyDOM?.inUse &&\n  global.ShadyDOM?.noPatch === true\n    ? global.ShadyDOM!.wrap\n    : (node: Node) => node;\n\nconst trustedTypes = (global as unknown as Partial<Window>).trustedTypes;\n\n/**\n * Our TrustedTypePolicy for HTML which is declared using the html template\n * tag function.\n *\n * That HTML is a developer-authored constant, and is parsed with innerHTML\n * before any untrusted expressions have been mixed in. Therefor it is\n * considered safe by construction.\n */\nconst policy = trustedTypes\n  ? trustedTypes.createPolicy('lit-html', {\n      createHTML: (s) => s,\n    })\n  : undefined;\n\n/**\n * Used to sanitize any value before it is written into the DOM. This can be\n * used to implement a security policy of allowed and disallowed values in\n * order to prevent XSS attacks.\n *\n * One way of using this callback would be to check attributes and properties\n * against a list of high risk fields, and require that values written to such\n * fields be instances of a class which is safe by construction. Closure's Safe\n * HTML Types is one implementation of this technique (\n * https://github.com/google/safe-html-types/blob/master/doc/safehtml-types.md).\n * The TrustedTypes polyfill in API-only mode could also be used as a basis\n * for this technique (https://github.com/WICG/trusted-types).\n *\n * @param node The HTML node (usually either a #text node or an Element) that\n *     is being written to. Note that this is just an exemplar node, the write\n *     may take place against another instance of the same class of node.\n * @param name The name of an attribute or property (for example, 'href').\n * @param type Indicates whether the write that's about to be performed will\n *     be to a property or a node.\n * @return A function that will sanitize this class of writes.\n */\nexport type SanitizerFactory = (\n  node: Node,\n  name: string,\n  type: 'property' | 'attribute'\n) => ValueSanitizer;\n\n/**\n * A function which can sanitize values that will be written to a specific kind\n * of DOM sink.\n *\n * See SanitizerFactory.\n *\n * @param value The value to sanitize. Will be the actual value passed into\n *     the lit-html template literal, so this could be of any type.\n * @return The value to write to the DOM. Usually the same as the input value,\n *     unless sanitization is needed.\n */\nexport type ValueSanitizer = (value: unknown) => unknown;\n\nconst identityFunction: ValueSanitizer = (value: unknown) => value;\nconst noopSanitizer: SanitizerFactory = (\n  _node: Node,\n  _name: string,\n  _type: 'property' | 'attribute'\n) => identityFunction;\n\n/** Sets the global sanitizer factory. */\nconst setSanitizer = (newSanitizer: SanitizerFactory) => {\n  if (!ENABLE_EXTRA_SECURITY_HOOKS) {\n    return;\n  }\n  if (sanitizerFactoryInternal !== noopSanitizer) {\n    throw new Error(\n      `Attempted to overwrite existing lit-html security policy.` +\n        ` setSanitizeDOMValueFactory should be called at most once.`\n    );\n  }\n  sanitizerFactoryInternal = newSanitizer;\n};\n\n/**\n * Only used in internal tests, not a part of the public API.\n */\nconst _testOnlyClearSanitizerFactoryDoNotCallOrElse = () => {\n  sanitizerFactoryInternal = noopSanitizer;\n};\n\nconst createSanitizer: SanitizerFactory = (node, name, type) => {\n  return sanitizerFactoryInternal(node, name, type);\n};\n\n// Added to an attribute name to mark the attribute as bound so we can find\n// it easily.\nconst boundAttributeSuffix = '$lit$';\n\n// This marker is used in many syntactic positions in HTML, so it must be\n// a valid element name and attribute name. We don't support dynamic names (yet)\n// but this at least ensures that the parse tree is closer to the template\n// intention.\nconst marker = `lit$${String(Math.random()).slice(9)}$`;\n\n// String used to tell if a comment is a marker comment\nconst markerMatch = '?' + marker;\n\n// Text used to insert a comment marker node. We use processing instruction\n// syntax because it's slightly smaller, but parses as a comment node.\nconst nodeMarker = `<${markerMatch}>`;\n\nconst d =\n  NODE_MODE && global.document === undefined\n    ? ({\n        createTreeWalker() {\n          return {};\n        },\n      } as unknown as Document)\n    : document;\n\n// Creates a dynamic marker. We never have to search for these in the DOM.\nconst createMarker = (v = '') => d.createComment(v);\n\n// https://tc39.github.io/ecma262/#sec-typeof-operator\ntype Primitive = null | undefined | boolean | number | string | symbol | bigint;\nconst isPrimitive = (value: unknown): value is Primitive =>\n  value === null || (typeof value != 'object' && typeof value != 'function');\nconst isArray = Array.isArray;\nconst isIterable = (value: unknown): value is Iterable<unknown> =>\n  isArray(value) ||\n  // eslint-disable-next-line @typescript-eslint/no-explicit-any\n  typeof (value as any)?.[Symbol.iterator] === 'function';\n\nconst SPACE_CHAR = `[ \\t\\n\\f\\r]`;\nconst ATTR_VALUE_CHAR = `[^ \\t\\n\\f\\r\"'\\`<>=]`;\nconst NAME_CHAR = `[^\\\\s\"'>=/]`;\n\n// These regexes represent the five parsing states that we care about in the\n// Template's HTML scanner. They match the *end* of the state they're named\n// after.\n// Depending on the match, we transition to a new state. If there's no match,\n// we stay in the same state.\n// Note that the regexes are stateful. We utilize lastIndex and sync it\n// across the multiple regexes used. In addition to the five regexes below\n// we also dynamically create a regex to find the matching end tags for raw\n// text elements.\n\n/**\n * End of text is: `<` followed by:\n *   (comment start) or (tag) or (dynamic tag binding)\n */\nconst textEndRegex = /<(?:(!--|\\/[^a-zA-Z])|(\\/?[a-zA-Z][^>\\s]*)|(\\/?$))/g;\nconst COMMENT_START = 1;\nconst TAG_NAME = 2;\nconst DYNAMIC_TAG_NAME = 3;\n\nconst commentEndRegex = /-->/g;\n/**\n * Comments not started with <!--, like </{, can be ended by a single `>`\n */\nconst comment2EndRegex = />/g;\n\n/**\n * The tagEnd regex matches the end of the \"inside an opening\" tag syntax\n * position. It either matches a `>`, an attribute-like sequence, or the end\n * of the string after a space (attribute-name position ending).\n *\n * See attributes in the HTML spec:\n * https://www.w3.org/TR/html5/syntax.html#elements-attributes\n *\n * \" \\t\\n\\f\\r\" are HTML space characters:\n * https://infra.spec.whatwg.org/#ascii-whitespace\n *\n * So an attribute is:\n *  * The name: any character except a whitespace character, (\"), ('), \">\",\n *    \"=\", or \"/\". Note: this is different from the HTML spec which also excludes control characters.\n *  * Followed by zero or more space characters\n *  * Followed by \"=\"\n *  * Followed by zero or more space characters\n *  * Followed by:\n *    * Any character except space, ('), (\"), \"<\", \">\", \"=\", (`), or\n *    * (\") then any non-(\"), or\n *    * (') then any non-(')\n */\nconst tagEndRegex = new RegExp(\n  `>|${SPACE_CHAR}(?:(${NAME_CHAR}+)(${SPACE_CHAR}*=${SPACE_CHAR}*(?:${ATTR_VALUE_CHAR}|(\"|')|))|$)`,\n  'g'\n);\nconst ENTIRE_MATCH = 0;\nconst ATTRIBUTE_NAME = 1;\nconst SPACES_AND_EQUALS = 2;\nconst QUOTE_CHAR = 3;\n\nconst singleQuoteAttrEndRegex = /'/g;\nconst doubleQuoteAttrEndRegex = /\"/g;\n/**\n * Matches the raw text elements.\n *\n * Comments are not parsed within raw text elements, so we need to search their\n * text content for marker strings.\n */\nconst rawTextElement = /^(?:script|style|textarea|title)$/i;\n\n/** TemplateResult types */\nconst HTML_RESULT = 1;\nconst SVG_RESULT = 2;\n\ntype ResultType = typeof HTML_RESULT | typeof SVG_RESULT;\n\n// TemplatePart types\n// IMPORTANT: these must match the values in PartType\nconst ATTRIBUTE_PART = 1;\nconst CHILD_PART = 2;\nconst PROPERTY_PART = 3;\nconst BOOLEAN_ATTRIBUTE_PART = 4;\nconst EVENT_PART = 5;\nconst ELEMENT_PART = 6;\nconst COMMENT_PART = 7;\n\n/**\n * The return type of the template tag functions, {@linkcode html} and\n * {@linkcode svg}.\n *\n * A `TemplateResult` object holds all the information about a template\n * expression required to render it: the template strings, expression values,\n * and type of template (html or svg).\n *\n * `TemplateResult` objects do not create any DOM on their own. To create or\n * update DOM you need to render the `TemplateResult`. See\n * [Rendering](https://lit.dev/docs/components/rendering) for more information.\n *\n */\nexport type TemplateResult<T extends ResultType = ResultType> = {\n  // This property needs to remain unminified.\n  ['_$litType$']: T;\n  strings: TemplateStringsArray;\n  values: unknown[];\n};\n\nexport type HTMLTemplateResult = TemplateResult<typeof HTML_RESULT>;\n\nexport type SVGTemplateResult = TemplateResult<typeof SVG_RESULT>;\n\nexport interface CompiledTemplateResult {\n  // This is a factory in order to make template initialization lazy\n  // and allow ShadyRenderOptions scope to be passed in.\n  // This property needs to remain unminified.\n  ['_$litType$']: CompiledTemplate;\n  values: unknown[];\n}\n\nexport interface CompiledTemplate extends Omit<Template, 'el'> {\n  // el is overridden to be optional. We initialize it on first render\n  el?: HTMLTemplateElement;\n\n  // The prepared HTML string to create a template element from.\n  h: TrustedHTML;\n}\n\n/**\n * Generates a template literal tag function that returns a TemplateResult with\n * the given result type.\n */\nconst tag =\n  <T extends ResultType>(type: T) =>\n  (strings: TemplateStringsArray, ...values: unknown[]): TemplateResult<T> => {\n    // Warn against templates octal escape sequences\n    // We do this here rather than in render so that the warning is closer to the\n    // template definition.\n    if (DEV_MODE && strings.some((s) => s === undefined)) {\n      console.warn(\n        'Some template strings are undefined.\\n' +\n          'This is probably caused by illegal octal escape sequences.'\n      );\n    }\n    return {\n      // This property needs to remain unminified.\n      ['_$litType$']: type,\n      strings,\n      values,\n    };\n  };\n\n/**\n * Interprets a template literal as an HTML template that can efficiently\n * render to and update a container.\n *\n * ```ts\n * const header = (title: string) => html`<h1>${title}</h1>`;\n * ```\n *\n * The `html` tag returns a description of the DOM to render as a value. It is\n * lazy, meaning no work is done until the template is rendered. When rendering,\n * if a template comes from the same expression as a previously rendered result,\n * it's efficiently updated instead of replaced.\n */\nexport const html = tag(HTML_RESULT);\n\n/**\n * Interprets a template literal as an SVG fragment that can efficiently\n * render to and update a container.\n *\n * ```ts\n * const rect = svg`<rect width=\"10\" height=\"10\"></rect>`;\n *\n * const myImage = html`\n *   <svg viewBox=\"0 0 10 10\" xmlns=\"http://www.w3.org/2000/svg\">\n *     ${rect}\n *   </svg>`;\n * ```\n *\n * The `svg` *tag function* should only be used for SVG fragments, or elements\n * that would be contained **inside** an `<svg>` HTML element. A common error is\n * placing an `<svg>` *element* in a template tagged with the `svg` tag\n * function. The `<svg>` element is an HTML element and should be used within a\n * template tagged with the {@linkcode html} tag function.\n *\n * In LitElement usage, it's invalid to return an SVG fragment from the\n * `render()` method, as the SVG fragment will be contained within the element's\n * shadow root and thus cannot be used within an `<svg>` HTML element.\n */\nexport const svg = tag(SVG_RESULT);\n\n/**\n * A sentinel value that signals that a value was handled by a directive and\n * should not be written to the DOM.\n */\nexport const noChange = Symbol.for('lit-noChange');\n\n/**\n * A sentinel value that signals a ChildPart to fully clear its content.\n *\n * ```ts\n * const button = html`${\n *  user.isAdmin\n *    ? html`<button>DELETE</button>`\n *    : nothing\n * }`;\n * ```\n *\n * Prefer using `nothing` over other falsy values as it provides a consistent\n * behavior between various expression binding contexts.\n *\n * In child expressions, `undefined`, `null`, `''`, and `nothing` all behave the\n * same and render no nodes. In attribute expressions, `nothing` _removes_ the\n * attribute, while `undefined` and `null` will render an empty string. In\n * property expressions `nothing` becomes `undefined`.\n */\nexport const nothing = Symbol.for('lit-nothing');\n\n/**\n * The cache of prepared templates, keyed by the tagged TemplateStringsArray\n * and _not_ accounting for the specific template tag used. This means that\n * template tags cannot be dynamic - the must statically be one of html, svg,\n * or attr. This restriction simplifies the cache lookup, which is on the hot\n * path for rendering.\n */\nconst templateCache = new WeakMap<TemplateStringsArray, Template>();\n\n/**\n * Object specifying options for controlling lit-html rendering. Note that\n * while `render` may be called multiple times on the same `container` (and\n * `renderBefore` reference node) to efficiently update the rendered content,\n * only the options passed in during the first render are respected during\n * the lifetime of renders to that unique `container` + `renderBefore`\n * combination.\n */\nexport interface RenderOptions {\n  /**\n   * An object to use as the `this` value for event listeners. It's often\n   * useful to set this to the host component rendering a template.\n   */\n  host?: object;\n  /**\n   * A DOM node before which to render content in the container.\n   */\n  renderBefore?: ChildNode | null;\n  /**\n   * Node used for cloning the template (`importNode` will be called on this\n   * node). This controls the `ownerDocument` of the rendered DOM, along with\n   * any inherited context. Defaults to the global `document`.\n   */\n  creationScope?: {importNode(node: Node, deep?: boolean): Node};\n  /**\n   * The initial connected state for the top-level part being rendered. If no\n   * `isConnected` option is set, `AsyncDirective`s will be connected by\n   * default. Set to `false` if the initial render occurs in a disconnected tree\n   * and `AsyncDirective`s should see `isConnected === false` for their initial\n   * render. The `part.setConnected()` method must be used subsequent to initial\n   * render to change the connected state of the part.\n   */\n  isConnected?: boolean;\n}\n\nconst walker = d.createTreeWalker(\n  d,\n  129 /* NodeFilter.SHOW_{ELEMENT|COMMENT} */,\n  null,\n  false\n);\n\nlet sanitizerFactoryInternal: SanitizerFactory = noopSanitizer;\n\n//\n// Classes only below here, const variable declarations only above here...\n//\n// Keeping variable declarations and classes together improves minification.\n// Interfaces and type aliases can be interleaved freely.\n//\n\n// Type for classes that have a `_directive` or `_directives[]` field, used by\n// `resolveDirective`\nexport interface DirectiveParent {\n  _$parent?: DirectiveParent;\n  _$isConnected: boolean;\n  __directive?: Directive;\n  __directives?: Array<Directive | undefined>;\n}\n\n/**\n * Returns an HTML string for the given TemplateStringsArray and result type\n * (HTML or SVG), along with the case-sensitive bound attribute names in\n * template order. The HTML contains comment markers denoting the `ChildPart`s\n * and suffixes on bound attributes denoting the `AttributeParts`.\n *\n * @param strings template strings array\n * @param type HTML or SVG\n * @return Array containing `[html, attrNames]` (array returned for terseness,\n *     to avoid object fields since this code is shared with non-minified SSR\n *     code)\n */\nconst getTemplateHtml = (\n  strings: TemplateStringsArray,\n  type: ResultType\n): [TrustedHTML, Array<string | undefined>] => {\n  // Insert makers into the template HTML to represent the position of\n  // bindings. The following code scans the template strings to determine the\n  // syntactic position of the bindings. They can be in text position, where\n  // we insert an HTML comment, attribute value position, where we insert a\n  // sentinel string and re-write the attribute name, or inside a tag where\n  // we insert the sentinel string.\n  const l = strings.length - 1;\n  // Stores the case-sensitive bound attribute names in the order of their\n  // parts. ElementParts are also reflected in this array as undefined\n  // rather than a string, to disambiguate from attribute bindings.\n  const attrNames: Array<string | undefined> = [];\n  let html = type === SVG_RESULT ? '<svg>' : '';\n\n  // When we're inside a raw text tag (not it's text content), the regex\n  // will still be tagRegex so we can find attributes, but will switch to\n  // this regex when the tag ends.\n  let rawTextEndRegex: RegExp | undefined;\n\n  // The current parsing state, represented as a reference to one of the\n  // regexes\n  let regex = textEndRegex;\n\n  for (let i = 0; i < l; i++) {\n    const s = strings[i];\n    // The index of the end of the last attribute name. When this is\n    // positive at end of a string, it means we're in an attribute value\n    // position and need to rewrite the attribute name.\n    // We also use a special value of -2 to indicate that we encountered\n    // the end of a string in attribute name position.\n    let attrNameEndIndex = -1;\n    let attrName: string | undefined;\n    let lastIndex = 0;\n    let match!: RegExpExecArray | null;\n\n    // The conditions in this loop handle the current parse state, and the\n    // assignments to the `regex` variable are the state transitions.\n    while (lastIndex < s.length) {\n      // Make sure we start searching from where we previously left off\n      regex.lastIndex = lastIndex;\n      match = regex.exec(s);\n      if (match === null) {\n        break;\n      }\n      lastIndex = regex.lastIndex;\n      if (regex === textEndRegex) {\n        if (match[COMMENT_START] === '!--') {\n          regex = commentEndRegex;\n        } else if (match[COMMENT_START] !== undefined) {\n          // We started a weird comment, like </{\n          regex = comment2EndRegex;\n        } else if (match[TAG_NAME] !== undefined) {\n          if (rawTextElement.test(match[TAG_NAME])) {\n            // Record if we encounter a raw-text element. We'll switch to\n            // this regex at the end of the tag.\n            rawTextEndRegex = new RegExp(`</${match[TAG_NAME]}`, 'g');\n          }\n          regex = tagEndRegex;\n        } else if (match[DYNAMIC_TAG_NAME] !== undefined) {\n          if (DEV_MODE) {\n            throw new Error(\n              'Bindings in tag names are not supported. Please use static templates instead. ' +\n                'See https://lit.dev/docs/templates/expressions/#static-expressions'\n            );\n          }\n          regex = tagEndRegex;\n        }\n      } else if (regex === tagEndRegex) {\n        if (match[ENTIRE_MATCH] === '>') {\n          // End of a tag. If we had started a raw-text element, use that\n          // regex\n          regex = rawTextEndRegex ?? textEndRegex;\n          // We may be ending an unquoted attribute value, so make sure we\n          // clear any pending attrNameEndIndex\n          attrNameEndIndex = -1;\n        } else if (match[ATTRIBUTE_NAME] === undefined) {\n          // Attribute name position\n          attrNameEndIndex = -2;\n        } else {\n          attrNameEndIndex = regex.lastIndex - match[SPACES_AND_EQUALS].length;\n          attrName = match[ATTRIBUTE_NAME];\n          regex =\n            match[QUOTE_CHAR] === undefined\n              ? tagEndRegex\n              : match[QUOTE_CHAR] === '\"'\n              ? doubleQuoteAttrEndRegex\n              : singleQuoteAttrEndRegex;\n        }\n      } else if (\n        regex === doubleQuoteAttrEndRegex ||\n        regex === singleQuoteAttrEndRegex\n      ) {\n        regex = tagEndRegex;\n      } else if (regex === commentEndRegex || regex === comment2EndRegex) {\n        regex = textEndRegex;\n      } else {\n        // Not one of the five state regexes, so it must be the dynamically\n        // created raw text regex and we're at the close of that element.\n        regex = tagEndRegex;\n        rawTextEndRegex = undefined;\n      }\n    }\n\n    if (DEV_MODE) {\n      // If we have a attrNameEndIndex, which indicates that we should\n      // rewrite the attribute name, assert that we're in a valid attribute\n      // position - either in a tag, or a quoted attribute value.\n      console.assert(\n        attrNameEndIndex === -1 ||\n          regex === tagEndRegex ||\n          regex === singleQuoteAttrEndRegex ||\n          regex === doubleQuoteAttrEndRegex,\n        'unexpected parse state B'\n      );\n    }\n\n    // We have four cases:\n    //  1. We're in text position, and not in a raw text element\n    //     (regex === textEndRegex): insert a comment marker.\n    //  2. We have a non-negative attrNameEndIndex which means we need to\n    //     rewrite the attribute name to add a bound attribute suffix.\n    //  3. We're at the non-first binding in a multi-binding attribute, use a\n    //     plain marker.\n    //  4. We're somewhere else inside the tag. If we're in attribute name\n    //     position (attrNameEndIndex === -2), add a sequential suffix to\n    //     generate a unique attribute name.\n\n    // Detect a binding next to self-closing tag end and insert a space to\n    // separate the marker from the tag end:\n    const end =\n      regex === tagEndRegex && strings[i + 1].startsWith('/>') ? ' ' : '';\n    html +=\n      regex === textEndRegex\n        ? s + nodeMarker\n        : attrNameEndIndex >= 0\n        ? (attrNames.push(attrName!),\n          s.slice(0, attrNameEndIndex) +\n            boundAttributeSuffix +\n            s.slice(attrNameEndIndex)) +\n          marker +\n          end\n        : s +\n          marker +\n          (attrNameEndIndex === -2 ? (attrNames.push(undefined), i) : end);\n  }\n\n  const htmlResult: string | TrustedHTML =\n    html + (strings[l] || '<?>') + (type === SVG_RESULT ? '</svg>' : '');\n\n  // A security check to prevent spoofing of Lit template results.\n  // In the future, we may be able to replace this with Array.isTemplateObject,\n  // though we might need to make that check inside of the html and svg\n  // functions, because precompiled templates don't come in as\n  // TemplateStringArray objects.\n  if (!Array.isArray(strings) || !strings.hasOwnProperty('raw')) {\n    let message = 'invalid template strings array';\n    if (DEV_MODE) {\n      message = `\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\n          If you're using the html or svg tagged template functions normally\n          and 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        `\n        .trim()\n        .replace(/\\n */g, '\\n');\n    }\n    throw new Error(message);\n  }\n  // Returned as an array for terseness\n  return [\n    policy !== undefined\n      ? policy.createHTML(htmlResult)\n      : (htmlResult as unknown as TrustedHTML),\n    attrNames,\n  ];\n};\n\n/** @internal */\nexport type {Template};\nclass Template {\n  /** @internal */\n  el!: HTMLTemplateElement;\n  /** @internal */\n  parts: Array<TemplatePart> = [];\n\n  constructor(\n    // This property needs to remain unminified.\n    {strings, ['_$litType$']: type}: TemplateResult,\n    options?: RenderOptions\n  ) {\n    let node: Node | null;\n    let nodeIndex = 0;\n    let attrNameIndex = 0;\n    const partCount = strings.length - 1;\n    const parts = this.parts;\n\n    // Create template element\n    const [html, attrNames] = getTemplateHtml(strings, type);\n    this.el = Template.createElement(html, options);\n    walker.currentNode = this.el.content;\n\n    // Reparent SVG nodes into template root\n    if (type === SVG_RESULT) {\n      const content = this.el.content;\n      const svgElement = content.firstChild!;\n      svgElement.remove();\n      content.append(...svgElement.childNodes);\n    }\n\n    // Walk the template to find binding markers and create TemplateParts\n    while ((node = walker.nextNode()) !== null && parts.length < partCount) {\n      if (node.nodeType === 1) {\n        if (DEV_MODE) {\n          const tag = (node as Element).localName;\n          // Warn if `textarea` includes an expression and throw if `template`\n          // does since these are not supported. We do this by checking\n          // innerHTML for anything that looks like a marker. This catches\n          // cases like bindings in textarea there markers turn into text nodes.\n          if (\n            /^(?:textarea|template)$/i!.test(tag) &&\n            (node as Element).innerHTML.includes(marker)\n          ) {\n            const m =\n              `Expressions are not supported inside \\`${tag}\\` ` +\n              `elements. See https://lit.dev/msg/expression-in-${tag} for more ` +\n              `information.`;\n            if (tag === 'template') {\n              throw new Error(m);\n            } else issueWarning('', m);\n          }\n        }\n        // TODO (justinfagnani): for attempted dynamic tag names, we don't\n        // increment the bindingIndex, and it'll be off by 1 in the element\n        // and off by two after it.\n        if ((node as Element).hasAttributes()) {\n          // We defer removing bound attributes because on IE we might not be\n          // iterating attributes in their template order, and would sometimes\n          // remove an attribute that we still need to create a part for.\n          const attrsToRemove = [];\n          for (const name of (node as Element).getAttributeNames()) {\n            // `name` is the name of the attribute we're iterating over, but not\n            // _neccessarily_ the name of the attribute we will create a part\n            // for. They can be different in browsers that don't iterate on\n            // attributes in source order. In that case the attrNames array\n            // contains the attribute name we'll process next. We only need the\n            // attribute name here to know if we should process a bound attribute\n            // on this element.\n            if (\n              name.endsWith(boundAttributeSuffix) ||\n              name.startsWith(marker)\n            ) {\n              const realName = attrNames[attrNameIndex++];\n              attrsToRemove.push(name);\n              if (realName !== undefined) {\n                // Lowercase for case-sensitive SVG attributes like viewBox\n                const value = (node as Element).getAttribute(\n                  realName.toLowerCase() + boundAttributeSuffix\n                )!;\n                const statics = value.split(marker);\n                const m = /([.?@])?(.*)/.exec(realName)!;\n                parts.push({\n                  type: ATTRIBUTE_PART,\n                  index: nodeIndex,\n                  name: m[2],\n                  strings: statics,\n                  ctor:\n                    m[1] === '.'\n                      ? PropertyPart\n                      : m[1] === '?'\n                      ? BooleanAttributePart\n                      : m[1] === '@'\n                      ? EventPart\n                      : AttributePart,\n                });\n              } else {\n                parts.push({\n                  type: ELEMENT_PART,\n                  index: nodeIndex,\n                });\n              }\n            }\n          }\n          for (const name of attrsToRemove) {\n            (node as Element).removeAttribute(name);\n          }\n        }\n        // TODO (justinfagnani): benchmark the regex against testing for each\n        // of the 3 raw text element names.\n        if (rawTextElement.test((node as Element).tagName)) {\n          // For raw text elements we need to split the text content on\n          // markers, create a Text node for each segment, and create\n          // a TemplatePart for each marker.\n          const strings = (node as Element).textContent!.split(marker);\n          const lastIndex = strings.length - 1;\n          if (lastIndex > 0) {\n            (node as Element).textContent = trustedTypes\n              ? (trustedTypes.emptyScript as unknown as '')\n              : '';\n            // Generate a new text node for each literal section\n            // These nodes are also used as the markers for node parts\n            // We can't use empty text nodes as markers because they're\n            // normalized when cloning in IE (could simplify when\n            // IE is no longer supported)\n            for (let i = 0; i < lastIndex; i++) {\n              (node as Element).append(strings[i], createMarker());\n              // Walk past the marker node we just added\n              walker.nextNode();\n              parts.push({type: CHILD_PART, index: ++nodeIndex});\n            }\n            // Note because this marker is added after the walker's current\n            // node, it will be walked to in the outer loop (and ignored), so\n            // we don't need to adjust nodeIndex here\n            (node as Element).append(strings[lastIndex], createMarker());\n          }\n        }\n      } else if (node.nodeType === 8) {\n        const data = (node as Comment).data;\n        if (data === markerMatch) {\n          parts.push({type: CHILD_PART, index: nodeIndex});\n        } else {\n          let i = -1;\n          while ((i = (node as Comment).data.indexOf(marker, i + 1)) !== -1) {\n            // Comment node has a binding marker inside, make an inactive part\n            // The binding won't work, but subsequent bindings will\n            parts.push({type: COMMENT_PART, index: nodeIndex});\n            // Move to the end of the match\n            i += marker.length - 1;\n          }\n        }\n      }\n      nodeIndex++;\n    }\n    debugLogEvent?.({\n      kind: 'template prep',\n      template: this,\n      clonableTemplate: this.el,\n      parts: this.parts,\n      strings,\n    });\n  }\n\n  // Overridden via `litHtmlPolyfillSupport` to provide platform support.\n  /** @nocollapse */\n  static createElement(html: TrustedHTML, _options?: RenderOptions) {\n    const el = d.createElement('template');\n    el.innerHTML = html as unknown as string;\n    return el;\n  }\n}\n\nexport interface Disconnectable {\n  _$parent?: Disconnectable;\n  _$disconnectableChildren?: Set<Disconnectable>;\n  // Rather than hold connection state on instances, Disconnectables recursively\n  // fetch the connection state from the RootPart they are connected in via\n  // getters up the Disconnectable tree via _$parent references. This pushes the\n  // cost of tracking the isConnected state to `AsyncDirectives`, and avoids\n  // needing to pass all Disconnectables (parts, template instances, and\n  // directives) their connection state each time it changes, which would be\n  // costly for trees that have no AsyncDirectives.\n  _$isConnected: boolean;\n}\n\nfunction resolveDirective(\n  part: ChildPart | AttributePart | ElementPart,\n  value: unknown,\n  parent: DirectiveParent = part,\n  attributeIndex?: number\n): unknown {\n  // Bail early if the value is explicitly noChange. Note, this means any\n  // nested directive is still attached and is not run.\n  if (value === noChange) {\n    return value;\n  }\n  let currentDirective =\n    attributeIndex !== undefined\n      ? (parent as AttributePart).__directives?.[attributeIndex]\n      : (parent as ChildPart | ElementPart | Directive).__directive;\n  const nextDirectiveConstructor = isPrimitive(value)\n    ? undefined\n    : // This property needs to remain unminified.\n      (value as DirectiveResult)['_$litDirective$'];\n  if (currentDirective?.constructor !== nextDirectiveConstructor) {\n    // This property needs to remain unminified.\n    currentDirective?.['_$notifyDirectiveConnectionChanged']?.(false);\n    if (nextDirectiveConstructor === undefined) {\n      currentDirective = undefined;\n    } else {\n      currentDirective = new nextDirectiveConstructor(part as PartInfo);\n      currentDirective._$initialize(part, parent, attributeIndex);\n    }\n    if (attributeIndex !== undefined) {\n      ((parent as AttributePart).__directives ??= [])[attributeIndex] =\n        currentDirective;\n    } else {\n      (parent as ChildPart | Directive).__directive = currentDirective;\n    }\n  }\n  if (currentDirective !== undefined) {\n    value = resolveDirective(\n      part,\n      currentDirective._$resolve(part, (value as DirectiveResult).values),\n      currentDirective,\n      attributeIndex\n    );\n  }\n  return value;\n}\n\n/**\n * An updateable instance of a Template. Holds references to the Parts used to\n * update the template instance.\n */\nclass TemplateInstance implements Disconnectable {\n  /** @internal */\n  _$template: Template;\n  /** @internal */\n  _parts: Array<Part | undefined> = [];\n\n  /** @internal */\n  _$parent: ChildPart;\n  /** @internal */\n  _$disconnectableChildren?: Set<Disconnectable> = undefined;\n\n  constructor(template: Template, parent: ChildPart) {\n    this._$template = template;\n    this._$parent = parent;\n  }\n\n  // Called by ChildPart parentNode getter\n  get parentNode() {\n    return this._$parent.parentNode;\n  }\n\n  // See comment in Disconnectable interface for why this is a getter\n  get _$isConnected() {\n    return this._$parent._$isConnected;\n  }\n\n  // This method is separate from the constructor because we need to return a\n  // DocumentFragment and we don't want to hold onto it with an instance field.\n  _clone(options: RenderOptions | undefined) {\n    const {\n      el: {content},\n      parts: parts,\n    } = this._$template;\n    const fragment = (options?.creationScope ?? d).importNode(content, true);\n    walker.currentNode = fragment;\n\n    let node = walker.nextNode()!;\n    let nodeIndex = 0;\n    let partIndex = 0;\n    let templatePart = parts[0];\n\n    while (templatePart !== undefined) {\n      if (nodeIndex === templatePart.index) {\n        let part: Part | undefined;\n        if (templatePart.type === CHILD_PART) {\n          part = new ChildPart(\n            node as HTMLElement,\n            node.nextSibling,\n            this,\n            options\n          );\n        } else if (templatePart.type === ATTRIBUTE_PART) {\n          part = new templatePart.ctor(\n            node as HTMLElement,\n            templatePart.name,\n            templatePart.strings,\n            this,\n            options\n          );\n        } else if (templatePart.type === ELEMENT_PART) {\n          part = new ElementPart(node as HTMLElement, this, options);\n        }\n        this._parts.push(part);\n        templatePart = parts[++partIndex];\n      }\n      if (nodeIndex !== templatePart?.index) {\n        node = walker.nextNode()!;\n        nodeIndex++;\n      }\n    }\n    return fragment;\n  }\n\n  _update(values: Array<unknown>) {\n    let i = 0;\n    for (const part of this._parts) {\n      if (part !== undefined) {\n        debugLogEvent?.({\n          kind: 'set part',\n          part,\n          value: values[i],\n          valueIndex: i,\n          values,\n          templateInstance: this,\n        });\n        if ((part as AttributePart).strings !== undefined) {\n          (part as AttributePart)._$setValue(values, part as AttributePart, i);\n          // The number of values the part consumes is part.strings.length - 1\n          // since values are in between template spans. We increment i by 1\n          // later in the loop, so increment it by part.strings.length - 2 here\n          i += (part as AttributePart).strings!.length - 2;\n        } else {\n          part._$setValue(values[i]);\n        }\n      }\n      i++;\n    }\n  }\n}\n\n/*\n * Parts\n */\ntype AttributeTemplatePart = {\n  readonly type: typeof ATTRIBUTE_PART;\n  readonly index: number;\n  readonly name: string;\n  /** @internal */\n  readonly ctor: typeof AttributePart;\n  /** @internal */\n  readonly strings: ReadonlyArray<string>;\n};\ntype NodeTemplatePart = {\n  readonly type: typeof CHILD_PART;\n  readonly index: number;\n};\ntype ElementTemplatePart = {\n  readonly type: typeof ELEMENT_PART;\n  readonly index: number;\n};\ntype CommentTemplatePart = {\n  readonly type: typeof COMMENT_PART;\n  readonly index: number;\n};\n\n/**\n * A TemplatePart represents a dynamic part in a template, before the template\n * is instantiated. When a template is instantiated Parts are created from\n * TemplateParts.\n */\ntype TemplatePart =\n  | NodeTemplatePart\n  | AttributeTemplatePart\n  | ElementTemplatePart\n  | CommentTemplatePart;\n\nexport type Part =\n  | ChildPart\n  | AttributePart\n  | PropertyPart\n  | BooleanAttributePart\n  | ElementPart\n  | EventPart;\n\nexport type {ChildPart};\nclass ChildPart implements Disconnectable {\n  readonly type = CHILD_PART;\n  readonly options: RenderOptions | undefined;\n  _$committedValue: unknown = nothing;\n  /** @internal */\n  __directive?: Directive;\n  /** @internal */\n  _$startNode: ChildNode;\n  /** @internal */\n  _$endNode: ChildNode | null;\n  private _textSanitizer: ValueSanitizer | undefined;\n  /** @internal */\n  _$parent: Disconnectable | undefined;\n  /**\n   * Connection state for RootParts only (i.e. ChildPart without _$parent\n   * returned from top-level `render`). This field is unsed otherwise. The\n   * intention would clearer if we made `RootPart` a subclass of `ChildPart`\n   * with this field (and a different _$isConnected getter), but the subclass\n   * caused a perf regression, possibly due to making call sites polymorphic.\n   * @internal\n   */\n  __isConnected: boolean;\n\n  // See comment in Disconnectable interface for why this is a getter\n  get _$isConnected() {\n    // ChildParts that are not at the root should always be created with a\n    // parent; only RootChildNode's won't, so they return the local isConnected\n    // state\n    return this._$parent?._$isConnected ?? this.__isConnected;\n  }\n\n  // The following fields will be patched onto ChildParts when required by\n  // AsyncDirective\n  /** @internal */\n  _$disconnectableChildren?: Set<Disconnectable> = undefined;\n  /** @internal */\n  _$notifyConnectionChanged?(\n    isConnected: boolean,\n    removeFromParent?: boolean,\n    from?: number\n  ): void;\n  /** @internal */\n  _$reparentDisconnectables?(parent: Disconnectable): void;\n\n  constructor(\n    startNode: ChildNode,\n    endNode: ChildNode | null,\n    parent: TemplateInstance | ChildPart | undefined,\n    options: RenderOptions | undefined\n  ) {\n    this._$startNode = startNode;\n    this._$endNode = endNode;\n    this._$parent = parent;\n    this.options = options;\n    // Note __isConnected is only ever accessed on RootParts (i.e. when there is\n    // no _$parent); the value on a non-root-part is \"don't care\", but checking\n    // for parent would be more code\n    this.__isConnected = options?.isConnected ?? true;\n    if (ENABLE_EXTRA_SECURITY_HOOKS) {\n      // Explicitly initialize for consistent class shape.\n      this._textSanitizer = undefined;\n    }\n  }\n\n  /**\n   * The parent node into which the part renders its content.\n   *\n   * A ChildPart's content consists of a range of adjacent child nodes of\n   * `.parentNode`, possibly bordered by 'marker nodes' (`.startNode` and\n   * `.endNode`).\n   *\n   * - If both `.startNode` and `.endNode` are non-null, then the part's content\n   * consists of all siblings between `.startNode` and `.endNode`, exclusively.\n   *\n   * - If `.startNode` is non-null but `.endNode` is null, then the part's\n   * content consists of all siblings following `.startNode`, up to and\n   * including the last child of `.parentNode`. If `.endNode` is non-null, then\n   * `.startNode` will always be non-null.\n   *\n   * - If both `.endNode` and `.startNode` are null, then the part's content\n   * consists of all child nodes of `.parentNode`.\n   */\n  get parentNode(): Node {\n    let parentNode: Node = wrap(this._$startNode).parentNode!;\n    const parent = this._$parent;\n    if (\n      parent !== undefined &&\n      parentNode.nodeType === 11 /* Node.DOCUMENT_FRAGMENT */\n    ) {\n      // If the parentNode is a DocumentFragment, it may be because the DOM is\n      // still in the cloned fragment during initial render; if so, get the real\n      // parentNode the part will be committed into by asking the parent.\n      parentNode = (parent as ChildPart | TemplateInstance).parentNode;\n    }\n    return parentNode;\n  }\n\n  /**\n   * The part's leading marker node, if any. See `.parentNode` for more\n   * information.\n   */\n  get startNode(): Node | null {\n    return this._$startNode;\n  }\n\n  /**\n   * The part's trailing marker node, if any. See `.parentNode` for more\n   * information.\n   */\n  get endNode(): Node | null {\n    return this._$endNode;\n  }\n\n  _$setValue(value: unknown, directiveParent: DirectiveParent = this): void {\n    if (DEV_MODE && this.parentNode === null) {\n      throw new Error(\n        `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.`\n      );\n    }\n    value = resolveDirective(this, value, directiveParent);\n    if (isPrimitive(value)) {\n      // Non-rendering child values. It's important that these do not render\n      // empty text nodes to avoid issues with preventing default <slot>\n      // fallback content.\n      if (value === nothing || value == null || value === '') {\n        if (this._$committedValue !== nothing) {\n          debugLogEvent?.({\n            kind: 'commit nothing to child',\n            start: this._$startNode,\n            end: this._$endNode,\n            parent: this._$parent,\n            options: this.options,\n          });\n          this._$clear();\n        }\n        this._$committedValue = nothing;\n      } else if (value !== this._$committedValue && value !== noChange) {\n        this._commitText(value);\n      }\n      // This property needs to remain unminified.\n    } else if ((value as TemplateResult)['_$litType$'] !== undefined) {\n      this._commitTemplateResult(value as TemplateResult);\n    } else if ((value as Node).nodeType !== undefined) {\n      if (DEV_MODE && this.options?.host === value) {\n        this._commitText(\n          `[probable mistake: rendered a template's host in itself ` +\n            `(commonly caused by writing \\${this} in a template]`\n        );\n        console.warn(\n          `Attempted to render the template host`,\n          value,\n          `inside itself. This is almost always a mistake, and in dev mode `,\n          `we render some warning text. In production however, we'll `,\n          `render it, which will usually result in an error, and sometimes `,\n          `in the element disappearing from the DOM.`\n        );\n        return;\n      }\n      this._commitNode(value as Node);\n    } else if (isIterable(value)) {\n      this._commitIterable(value);\n    } else {\n      // Fallback, will render the string representation\n      this._commitText(value);\n    }\n  }\n\n  private _insert<T extends Node>(node: T, ref = this._$endNode) {\n    return wrap(wrap(this._$startNode).parentNode!).insertBefore(node, ref);\n  }\n\n  private _commitNode(value: Node): void {\n    if (this._$committedValue !== value) {\n      this._$clear();\n      if (\n        ENABLE_EXTRA_SECURITY_HOOKS &&\n        sanitizerFactoryInternal !== noopSanitizer\n      ) {\n        const parentNodeName = this._$startNode.parentNode?.nodeName;\n        if (parentNodeName === 'STYLE' || parentNodeName === 'SCRIPT') {\n          let message = 'Forbidden';\n          if (DEV_MODE) {\n            if (parentNodeName === 'STYLE') {\n              message =\n                `Lit does not support binding inside style nodes. ` +\n                `This is a security risk, as style injection attacks can ` +\n                `exfiltrate data and spoof UIs. ` +\n                `Consider instead using css\\`...\\` literals ` +\n                `to compose styles, and make do dynamic styling with ` +\n                `css custom properties, ::parts, <slot>s, ` +\n                `and by mutating the DOM rather than stylesheets.`;\n            } else {\n              message =\n                `Lit does not support binding inside script nodes. ` +\n                `This is a security risk, as it could allow arbitrary ` +\n                `code execution.`;\n            }\n          }\n          throw new Error(message);\n        }\n      }\n      debugLogEvent?.({\n        kind: 'commit node',\n        start: this._$startNode,\n        parent: this._$parent,\n        value: value,\n        options: this.options,\n      });\n      this._$committedValue = this._insert(value);\n    }\n  }\n\n  private _commitText(value: unknown): void {\n    // If the committed value is a primitive it means we called _commitText on\n    // the previous render, and we know that this._$startNode.nextSibling is a\n    // Text node. We can now just replace the text content (.data) of the node.\n    if (\n      this._$committedValue !== nothing &&\n      isPrimitive(this._$committedValue)\n    ) {\n      const node = wrap(this._$startNode).nextSibling as Text;\n      if (ENABLE_EXTRA_SECURITY_HOOKS) {\n        if (this._textSanitizer === undefined) {\n          this._textSanitizer = createSanitizer(node, 'data', 'property');\n        }\n        value = this._textSanitizer(value);\n      }\n      debugLogEvent?.({\n        kind: 'commit text',\n        node,\n        value,\n        options: this.options,\n      });\n      (node as Text).data = value as string;\n    } else {\n      if (ENABLE_EXTRA_SECURITY_HOOKS) {\n        const textNode = document.createTextNode('');\n        this._commitNode(textNode);\n        // When setting text content, for security purposes it matters a lot\n        // what the parent is. For example, <style> and <script> need to be\n        // handled with care, while <span> does not. So first we need to put a\n        // text node into the document, then we can sanitize its content.\n        if (this._textSanitizer === undefined) {\n          this._textSanitizer = createSanitizer(textNode, 'data', 'property');\n        }\n        value = this._textSanitizer(value);\n        debugLogEvent?.({\n          kind: 'commit text',\n          node: textNode,\n          value,\n          options: this.options,\n        });\n        textNode.data = value as string;\n      } else {\n        this._commitNode(d.createTextNode(value as string));\n        debugLogEvent?.({\n          kind: 'commit text',\n          node: wrap(this._$startNode).nextSibling as Text,\n          value,\n          options: this.options,\n        });\n      }\n    }\n    this._$committedValue = value;\n  }\n\n  private _commitTemplateResult(\n    result: TemplateResult | CompiledTemplateResult\n  ): void {\n    // This property needs to remain unminified.\n    const {values, ['_$litType$']: type} = result;\n    // If $litType$ is a number, result is a plain TemplateResult and we get\n    // the template from the template cache. If not, result is a\n    // CompiledTemplateResult and _$litType$ is a CompiledTemplate and we need\n    // to create the <template> element the first time we see it.\n    const template: Template | CompiledTemplate =\n      typeof type === 'number'\n        ? this._$getTemplate(result as TemplateResult)\n        : (type.el === undefined &&\n            (type.el = Template.createElement(type.h, this.options)),\n          type);\n\n    if ((this._$committedValue as TemplateInstance)?._$template === template) {\n      debugLogEvent?.({\n        kind: 'template updating',\n        template,\n        instance: this._$committedValue as TemplateInstance,\n        parts: (this._$committedValue as TemplateInstance)._parts,\n        options: this.options,\n        values,\n      });\n      (this._$committedValue as TemplateInstance)._update(values);\n    } else {\n      const instance = new TemplateInstance(template as Template, this);\n      const fragment = instance._clone(this.options);\n      debugLogEvent?.({\n        kind: 'template instantiated',\n        template,\n        instance,\n        parts: instance._parts,\n        options: this.options,\n        fragment,\n        values,\n      });\n      instance._update(values);\n      debugLogEvent?.({\n        kind: 'template instantiated and updated',\n        template,\n        instance,\n        parts: instance._parts,\n        options: this.options,\n        fragment,\n        values,\n      });\n      this._commitNode(fragment);\n      this._$committedValue = instance;\n    }\n  }\n\n  // Overridden via `litHtmlPolyfillSupport` to provide platform support.\n  /** @internal */\n  _$getTemplate(result: TemplateResult) {\n    let template = templateCache.get(result.strings);\n    if (template === undefined) {\n      templateCache.set(result.strings, (template = new Template(result)));\n    }\n    return template;\n  }\n\n  private _commitIterable(value: Iterable<unknown>): void {\n    // For an Iterable, we create a new InstancePart per item, then set its\n    // value to the item. This is a little bit of overhead for every item in\n    // an Iterable, but it lets us recurse easily and efficiently update Arrays\n    // of TemplateResults that will be commonly returned from expressions like:\n    // array.map((i) => html`${i}`), by reusing existing TemplateInstances.\n\n    // If value is an array, then the previous render was of an\n    // iterable and value will contain the ChildParts from the previous\n    // render. If value is not an array, clear this part and make a new\n    // array for ChildParts.\n    if (!isArray(this._$committedValue)) {\n      this._$committedValue = [];\n      this._$clear();\n    }\n\n    // Lets us keep track of how many items we stamped so we can clear leftover\n    // items from a previous render\n    const itemParts = this._$committedValue as ChildPart[];\n    let partIndex = 0;\n    let itemPart: ChildPart | undefined;\n\n    for (const item of value) {\n      if (partIndex === itemParts.length) {\n        // If no existing part, create a new one\n        // TODO (justinfagnani): test perf impact of always creating two parts\n        // instead of sharing parts between nodes\n        // https://github.com/lit/lit/issues/1266\n        itemParts.push(\n          (itemPart = new ChildPart(\n            this._insert(createMarker()),\n            this._insert(createMarker()),\n            this,\n            this.options\n          ))\n        );\n      } else {\n        // Reuse an existing part\n        itemPart = itemParts[partIndex];\n      }\n      itemPart._$setValue(item);\n      partIndex++;\n    }\n\n    if (partIndex < itemParts.length) {\n      // itemParts always have end nodes\n      this._$clear(\n        itemPart && wrap(itemPart._$endNode!).nextSibling,\n        partIndex\n      );\n      // Truncate the parts array so _value reflects the current state\n      itemParts.length = partIndex;\n    }\n  }\n\n  /**\n   * Removes the nodes contained within this Part from the DOM.\n   *\n   * @param start Start node to clear from, for clearing a subset of the part's\n   *     DOM (used when truncating iterables)\n   * @param from  When `start` is specified, the index within the iterable from\n   *     which ChildParts are being removed, used for disconnecting directives in\n   *     those Parts.\n   *\n   * @internal\n   */\n  _$clear(\n    start: ChildNode | null = wrap(this._$startNode).nextSibling,\n    from?: number\n  ) {\n    this._$notifyConnectionChanged?.(false, true, from);\n    while (start && start !== this._$endNode) {\n      const n = wrap(start!).nextSibling;\n      (wrap(start!) as Element).remove();\n      start = n;\n    }\n  }\n  /**\n   * Implementation of RootPart's `isConnected`. Note that this metod\n   * should only be called on `RootPart`s (the `ChildPart` returned from a\n   * top-level `render()` call). It has no effect on non-root ChildParts.\n   * @param isConnected Whether to set\n   * @internal\n   */\n  setConnected(isConnected: boolean) {\n    if (this._$parent === undefined) {\n      this.__isConnected = isConnected;\n      this._$notifyConnectionChanged?.(isConnected);\n    } else if (DEV_MODE) {\n      throw new Error(\n        'part.setConnected() may only be called on a ' +\n          'RootPart returned from render().'\n      );\n    }\n  }\n}\n\n/**\n * A top-level `ChildPart` returned from `render` that manages the connected\n * state of `AsyncDirective`s created throughout the tree below it.\n */\nexport interface RootPart extends ChildPart {\n  /**\n   * Sets the connection state for `AsyncDirective`s contained within this root\n   * ChildPart.\n   *\n   * lit-html does not automatically monitor the connectedness of DOM rendered;\n   * as such, it is the responsibility of the caller to `render` to ensure that\n   * `part.setConnected(false)` is called before the part object is potentially\n   * discarded, to ensure that `AsyncDirective`s have a chance to dispose of\n   * any resources being held. If a `RootPart` that was prevously\n   * disconnected is subsequently re-connected (and its `AsyncDirective`s should\n   * re-connect), `setConnected(true)` should be called.\n   *\n   * @param isConnected Whether directives within this tree should be connected\n   * or not\n   */\n  setConnected(isConnected: boolean): void;\n}\n\nexport type {AttributePart};\nclass AttributePart implements Disconnectable {\n  readonly type = ATTRIBUTE_PART as\n    | typeof ATTRIBUTE_PART\n    | typeof PROPERTY_PART\n    | typeof BOOLEAN_ATTRIBUTE_PART\n    | typeof EVENT_PART;\n  readonly element: HTMLElement;\n  readonly name: string;\n  readonly options: RenderOptions | undefined;\n\n  /**\n   * If this attribute part represents an interpolation, this contains the\n   * static strings of the interpolation. For single-value, complete bindings,\n   * this is undefined.\n   */\n  readonly strings?: ReadonlyArray<string>;\n  /** @internal */\n  _$committedValue: unknown | Array<unknown> = nothing;\n  /** @internal */\n  __directives?: Array<Directive | undefined>;\n  /** @internal */\n  _$parent: Disconnectable;\n  /** @internal */\n  _$disconnectableChildren?: Set<Disconnectable> = undefined;\n\n  protected _sanitizer: ValueSanitizer | undefined;\n\n  get tagName() {\n    return this.element.tagName;\n  }\n\n  // See comment in Disconnectable interface for why this is a getter\n  get _$isConnected() {\n    return this._$parent._$isConnected;\n  }\n\n  constructor(\n    element: HTMLElement,\n    name: string,\n    strings: ReadonlyArray<string>,\n    parent: Disconnectable,\n    options: RenderOptions | undefined\n  ) {\n    this.element = element;\n    this.name = name;\n    this._$parent = parent;\n    this.options = options;\n    if (strings.length > 2 || strings[0] !== '' || strings[1] !== '') {\n      this._$committedValue = new Array(strings.length - 1).fill(new String());\n      this.strings = strings;\n    } else {\n      this._$committedValue = nothing;\n    }\n    if (ENABLE_EXTRA_SECURITY_HOOKS) {\n      this._sanitizer = undefined;\n    }\n  }\n\n  /**\n   * Sets the value of this part by resolving the value from possibly multiple\n   * values and static strings and committing it to the DOM.\n   * If this part is single-valued, `this._strings` will be undefined, and the\n   * method will be called with a single value argument. If this part is\n   * multi-value, `this._strings` will be defined, and the method is called\n   * with the value array of the part's owning TemplateInstance, and an offset\n   * into the value array from which the values should be read.\n   * This method is overloaded this way to eliminate short-lived array slices\n   * of the template instance values, and allow a fast-path for single-valued\n   * parts.\n   *\n   * @param value The part value, or an array of values for multi-valued parts\n   * @param valueIndex the index to start reading values from. `undefined` for\n   *   single-valued parts\n   * @param noCommit causes the part to not commit its value to the DOM. Used\n   *   in hydration to prime attribute parts with their first-rendered value,\n   *   but not set the attribute, and in SSR to no-op the DOM operation and\n   *   capture the value for serialization.\n   *\n   * @internal\n   */\n  _$setValue(\n    value: unknown | Array<unknown>,\n    directiveParent: DirectiveParent = this,\n    valueIndex?: number,\n    noCommit?: boolean\n  ) {\n    const strings = this.strings;\n\n    // Whether any of the values has changed, for dirty-checking\n    let change = false;\n\n    if (strings === undefined) {\n      // Single-value binding case\n      value = resolveDirective(this, value, directiveParent, 0);\n      change =\n        !isPrimitive(value) ||\n        (value !== this._$committedValue && value !== noChange);\n      if (change) {\n        this._$committedValue = value;\n      }\n    } else {\n      // Interpolation case\n      const values = value as Array<unknown>;\n      value = strings[0];\n\n      let i, v;\n      for (i = 0; i < strings.length - 1; i++) {\n        v = resolveDirective(this, values[valueIndex! + i], directiveParent, i);\n\n        if (v === noChange) {\n          // If the user-provided value is `noChange`, use the previous value\n          v = (this._$committedValue as Array<unknown>)[i];\n        }\n        change ||=\n          !isPrimitive(v) || v !== (this._$committedValue as Array<unknown>)[i];\n        if (v === nothing) {\n          value = nothing;\n        } else if (value !== nothing) {\n          value += (v ?? '') + strings[i + 1];\n        }\n        // We always record each value, even if one is `nothing`, for future\n        // change detection.\n        (this._$committedValue as Array<unknown>)[i] = v;\n      }\n    }\n    if (change && !noCommit) {\n      this._commitValue(value);\n    }\n  }\n\n  /** @internal */\n  _commitValue(value: unknown) {\n    if (value === nothing) {\n      (wrap(this.element) as Element).removeAttribute(this.name);\n    } else {\n      if (ENABLE_EXTRA_SECURITY_HOOKS) {\n        if (this._sanitizer === undefined) {\n          this._sanitizer = sanitizerFactoryInternal(\n            this.element,\n            this.name,\n            'attribute'\n          );\n        }\n        value = this._sanitizer(value ?? '');\n      }\n      debugLogEvent?.({\n        kind: 'commit attribute',\n        element: this.element,\n        name: this.name,\n        value,\n        options: this.options,\n      });\n      (wrap(this.element) as Element).setAttribute(\n        this.name,\n        (value ?? '') as string\n      );\n    }\n  }\n}\n\nexport type {PropertyPart};\nclass PropertyPart extends AttributePart {\n  override readonly type = PROPERTY_PART;\n\n  /** @internal */\n  override _commitValue(value: unknown) {\n    if (ENABLE_EXTRA_SECURITY_HOOKS) {\n      if (this._sanitizer === undefined) {\n        this._sanitizer = sanitizerFactoryInternal(\n          this.element,\n          this.name,\n          'property'\n        );\n      }\n      value = this._sanitizer(value);\n    }\n    debugLogEvent?.({\n      kind: 'commit property',\n      element: this.element,\n      name: this.name,\n      value,\n      options: this.options,\n    });\n    // eslint-disable-next-line @typescript-eslint/no-explicit-any\n    (this.element as any)[this.name] = value === nothing ? undefined : value;\n  }\n}\n\n// Temporary workaround for https://crbug.com/993268\n// Currently, any attribute starting with \"on\" is considered to be a\n// TrustedScript source. Such boolean attributes must be set to the equivalent\n// trusted emptyScript value.\nconst emptyStringForBooleanAttribute = trustedTypes\n  ? (trustedTypes.emptyScript as unknown as '')\n  : '';\n\nexport type {BooleanAttributePart};\nclass BooleanAttributePart extends AttributePart {\n  override readonly type = BOOLEAN_ATTRIBUTE_PART;\n\n  /** @internal */\n  override _commitValue(value: unknown) {\n    debugLogEvent?.({\n      kind: 'commit boolean attribute',\n      element: this.element,\n      name: this.name,\n      value: !!(value && value !== nothing),\n      options: this.options,\n    });\n    if (value && value !== nothing) {\n      (wrap(this.element) as Element).setAttribute(\n        this.name,\n        emptyStringForBooleanAttribute\n      );\n    } else {\n      (wrap(this.element) as Element).removeAttribute(this.name);\n    }\n  }\n}\n\ntype EventListenerWithOptions = EventListenerOrEventListenerObject &\n  Partial<AddEventListenerOptions>;\n\n/**\n * An AttributePart that manages an event listener via add/removeEventListener.\n *\n * This part works by adding itself as the event listener on an element, then\n * delegating to the value passed to it. This reduces the number of calls to\n * add/removeEventListener if the listener changes frequently, such as when an\n * inline function is used as a listener.\n *\n * Because event options are passed when adding listeners, we must take case\n * to add and remove the part as a listener when the event options change.\n */\nexport type {EventPart};\nclass EventPart extends AttributePart {\n  override readonly type = EVENT_PART;\n\n  constructor(\n    element: HTMLElement,\n    name: string,\n    strings: ReadonlyArray<string>,\n    parent: Disconnectable,\n    options: RenderOptions | undefined\n  ) {\n    super(element, name, strings, parent, options);\n\n    if (DEV_MODE && this.strings !== undefined) {\n      throw new Error(\n        `A \\`<${element.localName}>\\` has a \\`@${name}=...\\` listener with ` +\n          'invalid content. Event listeners in templates must have exactly ' +\n          'one expression and no surrounding text.'\n      );\n    }\n  }\n\n  // EventPart does not use the base _$setValue/_resolveValue implementation\n  // since the dirty checking is more complex\n  /** @internal */\n  override _$setValue(\n    newListener: unknown,\n    directiveParent: DirectiveParent = this\n  ) {\n    newListener =\n      resolveDirective(this, newListener, directiveParent, 0) ?? nothing;\n    if (newListener === noChange) {\n      return;\n    }\n    const oldListener = this._$committedValue;\n\n    // If the new value is nothing or any options change we have to remove the\n    // part as a listener.\n    const shouldRemoveListener =\n      (newListener === nothing && oldListener !== nothing) ||\n      (newListener as EventListenerWithOptions).capture !==\n        (oldListener as EventListenerWithOptions).capture ||\n      (newListener as EventListenerWithOptions).once !==\n        (oldListener as EventListenerWithOptions).once ||\n      (newListener as EventListenerWithOptions).passive !==\n        (oldListener as EventListenerWithOptions).passive;\n\n    // If the new value is not nothing and we removed the listener, we have\n    // to add the part as a listener.\n    const shouldAddListener =\n      newListener !== nothing &&\n      (oldListener === nothing || shouldRemoveListener);\n\n    debugLogEvent?.({\n      kind: 'commit event listener',\n      element: this.element,\n      name: this.name,\n      value: newListener,\n      options: this.options,\n      removeListener: shouldRemoveListener,\n      addListener: shouldAddListener,\n      oldListener,\n    });\n    if (shouldRemoveListener) {\n      this.element.removeEventListener(\n        this.name,\n        this,\n        oldListener as EventListenerWithOptions\n      );\n    }\n    if (shouldAddListener) {\n      // Beware: IE11 and Chrome 41 don't like using the listener as the\n      // options object. Figure out how to deal w/ this in IE11 - maybe\n      // patch addEventListener?\n      this.element.addEventListener(\n        this.name,\n        this,\n        newListener as EventListenerWithOptions\n      );\n    }\n    this._$committedValue = newListener;\n  }\n\n  handleEvent(event: Event) {\n    if (typeof this._$committedValue === 'function') {\n      this._$committedValue.call(this.options?.host ?? this.element, event);\n    } else {\n      (this._$committedValue as EventListenerObject).handleEvent(event);\n    }\n  }\n}\n\nexport type {ElementPart};\nclass ElementPart implements Disconnectable {\n  readonly type = ELEMENT_PART;\n\n  /** @internal */\n  __directive?: Directive;\n\n  // This is to ensure that every Part has a _$committedValue\n  _$committedValue: undefined;\n\n  /** @internal */\n  _$parent!: Disconnectable;\n\n  /** @internal */\n  _$disconnectableChildren?: Set<Disconnectable> = undefined;\n\n  options: RenderOptions | undefined;\n\n  constructor(\n    public element: Element,\n    parent: Disconnectable,\n    options: RenderOptions | undefined\n  ) {\n    this._$parent = parent;\n    this.options = options;\n  }\n\n  // See comment in Disconnectable interface for why this is a getter\n  get _$isConnected() {\n    return this._$parent._$isConnected;\n  }\n\n  _$setValue(value: unknown): void {\n    debugLogEvent?.({\n      kind: 'commit to element binding',\n      element: this.element,\n      value,\n      options: this.options,\n    });\n    resolveDirective(this, value);\n  }\n}\n\n/**\n * END USERS SHOULD NOT RELY ON THIS OBJECT.\n *\n * Private exports for use by other Lit packages, not intended for use by\n * external users.\n *\n * We currently do not make a mangled rollup build of the lit-ssr code. In order\n * to keep a number of (otherwise private) top-level exports  mangled in the\n * client side code, we export a _$LH object containing those members (or\n * helper methods for accessing private fields of those members), and then\n * re-export them for use in lit-ssr. This keeps lit-ssr agnostic to whether the\n * client-side code is being used in `dev` mode or `prod` mode.\n *\n * This has a unique name, to disambiguate it from private exports in\n * lit-element, which re-exports all of lit-html.\n *\n * @private\n */\nexport const _$LH = {\n  // Used in lit-ssr\n  _boundAttributeSuffix: boundAttributeSuffix,\n  _marker: marker,\n  _markerMatch: markerMatch,\n  _HTML_RESULT: HTML_RESULT,\n  _getTemplateHtml: getTemplateHtml,\n  // Used in hydrate\n  _TemplateInstance: TemplateInstance,\n  _isIterable: isIterable,\n  _resolveDirective: resolveDirective,\n  // Used in tests and private-ssr-support\n  _ChildPart: ChildPart,\n  _AttributePart: AttributePart,\n  _BooleanAttributePart: BooleanAttributePart,\n  _EventPart: EventPart,\n  _PropertyPart: PropertyPart,\n  _ElementPart: ElementPart,\n};\n\n// Apply polyfills if available\nconst polyfillSupport = DEV_MODE\n  ? global.litHtmlPolyfillSupportDevMode\n  : global.litHtmlPolyfillSupport;\npolyfillSupport?.(Template, ChildPart);\n\n// IMPORTANT: do not change the property name or the assignment expression.\n// This line will be used in regexes to search for lit-html usage.\n(global.litHtmlVersions ??= []).push('2.4.0');\nif (DEV_MODE && global.litHtmlVersions.length > 1) {\n  issueWarning!(\n    'multiple-versions',\n    `Multiple versions of Lit loaded. ` +\n      `Loading multiple versions is not recommended.`\n  );\n}\n\n/**\n * Renders a value, usually a lit-html TemplateResult, to the container.\n *\n * This example renders the text \"Hello, Zoe!\" inside a paragraph tag, appending\n * it to the container `document.body`.\n *\n * ```js\n * import {html, render} from 'lit';\n *\n * const name = \"Zoe\";\n * render(html`<p>Hello, ${name}!</p>`, document.body);\n * ```\n *\n * @param value Any [renderable\n *   value](https://lit.dev/docs/templates/expressions/#child-expressions),\n *   typically a {@linkcode TemplateResult} created by evaluating a template tag\n *   like {@linkcode html} or {@linkcode svg}.\n * @param container A DOM container to render to. The first render will append\n *   the rendered value to the container, and subsequent renders will\n *   efficiently update the rendered value if the same result type was\n *   previously rendered there.\n * @param options See {@linkcode RenderOptions} for options documentation.\n * @see\n * {@link https://lit.dev/docs/libraries/standalone-templates/#rendering-lit-html-templates| Rendering Lit HTML Templates}\n */\nexport const render = (\n  value: unknown,\n  container: HTMLElement | DocumentFragment,\n  options?: RenderOptions\n): RootPart => {\n  if (DEV_MODE && container == null) {\n    // Give a clearer error message than\n    //     Uncaught TypeError: Cannot read properties of null (reading\n    //     '_$litPart$')\n    // which reads like an internal Lit error.\n    throw new TypeError(`The container to render into may not be ${container}`);\n  }\n  const renderId = DEV_MODE ? debugLogRenderId++ : 0;\n  const partOwnerNode = options?.renderBefore ?? container;\n  // This property needs to remain unminified.\n  // eslint-disable-next-line @typescript-eslint/no-explicit-any\n  let part: ChildPart = (partOwnerNode as any)['_$litPart$'];\n  debugLogEvent?.({\n    kind: 'begin render',\n    id: renderId,\n    value,\n    container,\n    options,\n    part,\n  });\n  if (part === undefined) {\n    const endNode = options?.renderBefore ?? null;\n    // This property needs to remain unminified.\n    // eslint-disable-next-line @typescript-eslint/no-explicit-any\n    (partOwnerNode as any)['_$litPart$'] = part = new ChildPart(\n      container.insertBefore(createMarker(), endNode),\n      endNode,\n      undefined,\n      options ?? {}\n    );\n  }\n  part._$setValue(value);\n  debugLogEvent?.({\n    kind: 'end render',\n    id: renderId,\n    value,\n    container,\n    options,\n    part,\n  });\n  return part as RootPart;\n};\n\nif (ENABLE_EXTRA_SECURITY_HOOKS) {\n  render.setSanitizer = setSanitizer;\n  render.createSanitizer = createSanitizer;\n  if (DEV_MODE) {\n    render._testOnlyClearSanitizerFactoryDoNotCallOrElse =\n      _testOnlyClearSanitizerFactoryDoNotCallOrElse;\n  }\n}\n"],"names":["global","globalThis","trustedTypes","policy","createPolicy","createHTML","s","undefined","marker","Math","random","String","slice","markerMatch","nodeMarker","d","document","createTreeWalker","createMarker","v","createComment","isPrimitive","value","isArray","Array","isIterable","Symbol","iterator","textEndRegex","commentEndRegex","comment2EndRegex","tagEndRegex","RegExp","singleQuoteAttrEndRegex","doubleQuoteAttrEndRegex","rawTextElement","tag","type","strings","values","_$litType$","html","svg","noChange","for","nothing","templateCache","WeakMap","walker","getTemplateHtml","l","length","attrNames","rawTextEndRegex","regex","i","attrName","match","attrNameEndIndex","lastIndex","exec","test","end","startsWith","push","htmlResult","hasOwnProperty","Error","Template","constructor","options","node","this","parts","nodeIndex","attrNameIndex","partCount","el","createElement","currentNode","content","svgElement","firstChild","remove","append","childNodes","nextNode","nodeType","hasAttributes","attrsToRemove","name","getAttributeNames","endsWith","realName","statics","getAttribute","toLowerCase","split","m","index","ctor","PropertyPart","BooleanAttributePart","EventPart","AttributePart","removeAttribute","tagName","textContent","emptyScript","data","indexOf","static","_options","innerHTML","resolveDirective","part","parent","attributeIndex","currentDirective","_a","__directives","__directive","nextDirectiveConstructor","_b","call","_$initialize","_c","_d","_$resolve","TemplateInstance","template","_parts","_$disconnectableChildren","_$template","_$parent","parentNode","_$isConnected","_clone","fragment","creationScope","importNode","partIndex","templatePart","ChildPart","nextSibling","ElementPart","_update","_$setValue","startNode","endNode","_$committedValue","_$startNode","_$endNode","__isConnected","isConnected","directiveParent","_$clear","_commitText","_commitTemplateResult","_commitNode","_commitIterable","_insert","ref","insertBefore","createTextNode","result","_$getTemplate","h","instance","get","set","itemParts","itemPart","item","start","from","_$notifyConnectionChanged","n","setConnected","element","fill","valueIndex","noCommit","change","_commitValue","setAttribute","emptyStringForBooleanAttribute","super","newListener","oldListener","shouldRemoveListener","capture","once","passive","shouldAddListener","removeEventListener","addEventListener","handleEvent","event","host","_$LH","_boundAttributeSuffix","_marker","_markerMatch","_HTML_RESULT","_getTemplateHtml","_TemplateInstance","_isIterable","_resolveDirective","_ChildPart","_AttributePart","_BooleanAttributePart","_EventPart","_PropertyPart","_ElementPart","polyfillSupport","litHtmlPolyfillSupport","litHtmlVersions","render","container","partOwnerNode","renderBefore"],"mappings":";;;;;MAcA,MAAMA,EAAqBC,WAmOrBC,EAAgBF,EAAsCE,aAUtDC,EAASD,EACXA,EAAaE,aAAa,WAAY,CACpCC,WAAaC,GAAMA,SAErBC,EAkFEC,EAAS,QAAcC,KAAKC,SAAZC,IAAsBC,MAAM,MAG5CC,EAAc,IAAML,EAIpBM,EAAa,IAAID,KAEjBE,OAC6BR,IAApBP,EAAOgB,SACf,CACCC,iBAAgB,KACP,KAGXD,SAGAE,EAAe,CAACC,EAAI,KAAOJ,EAAEK,cAAcD,GAI3CE,EAAeC,GACT,OAAVA,GAAmC,iBAATA,GAAqC,mBAATA,EAClDC,EAAUC,MAAMD,QAChBE,EAAcH,GAClBC,EAAQD,IAEqC,mBAArCA,eAAAA,EAAgBI,OAAOC,WAoB3BC,EAAe,sDAKfC,EAAkB,OAIlBC,EAAmB,KAwBnBC,EAAkBC,OACtB,+FACA,KAOIC,EAA0B,KAC1BC,EAA0B,KAO1BC,EAAiB,qCA8DjBC,EACmBC,GACvB,CAACC,KAAkCC,KAU1B,CAELC,WAAgBH,EAChBC,UACAC,WAiBOE,EAAOL,EA5FA,GAqHPM,EAAMN,EApHA,GA0HNO,EAAWjB,OAAOkB,IAAI,gBAqBtBC,EAAUnB,OAAOkB,IAAI,eAS5BE,EAAgB,IAAIC,QAqCpBC,EAASjC,EAAEE,iBACfF,EACA,IACA,MACA,GAiCIkC,EAAkB,CACtBX,EACAD,KAQA,MAAMa,EAAIZ,EAAQa,OAAS,EAIrBC,EAAuC,GAC7C,IAKIC,EALAZ,EAjPa,IAiPNJ,EAAsB,QAAU,GASvCiB,EAAQ1B,EAEZ,IAAK,IAAI2B,EAAI,EAAGA,EAAIL,EAAGK,IAAK,CAC1B,MAAMjD,EAAIgC,EAAQiB,GAMlB,IACIC,EAEAC,EA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A+D,QAAAA,EAAW,CAAA,EAEd,CAUD,OATA6C,EAAKgC,KAAW7H,GAST6F,CAAgB"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/node/polyfill-support.js b/front_end/third_party/lit-html/package/node/polyfill-support.js
new file mode 100644
index 0000000000000000000000000000000000000000..5b062545b256ef4da50822bfd8fbb98534242887
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/polyfill-support.js
@@ -0,0 +1,7 @@
+/**
+ * @license
+ * Copyright 2017 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */
+var i,n=new Set,o=new Map,t=function(i,t){var d,v;if(void 0!==window.ShadyCSS&&(!window.ShadyCSS.nativeShadow||window.ShadyCSS.ApplyShim)){var l=(null===(d=window.ShadyDOM)||void 0===d?void 0:d.inUse)&&!0===(null===(v=window.ShadyDOM)||void 0===v?void 0:v.noPatch)?window.ShadyDOM.wrap:function(i){return i},u=function(i){return void 0!==i&&!n.has(i)},r=function(i){var n=o.get(i);return void 0===n&&o.set(i,n=[]),n},w=new Map,a=i.createElement;i.createElement=function(n,o){var t=a.call(i,n,o),d=null==o?void 0:o.scope;if(void 0!==d&&(window.ShadyCSS.nativeShadow||window.ShadyCSS.prepareTemplateDom(t,d),u(d))){var v=r(d),l=t.content.querySelectorAll("style");v.push.apply(v,Array.from(l).map((function(i){var n;return null===(n=i.parentNode)||void 0===n||n.removeChild(i),i.textContent})))}return t};var e=document.createDocumentFragment(),s=document.createComment(""),h=t.prototype,c=h._$AI;h._$AI=function(i,t){var d,v;void 0===t&&(t=this);var w=l(this._$AA).parentNode,a=null===(d=this.options)||void 0===d?void 0:d.scope;if(w instanceof ShadowRoot&&u(a)){var h=this._$AA,f=this._$AB;e.appendChild(s),this._$AA=s,this._$AB=null,c.call(this,i,t);var m=(null==i?void 0:i._$litType$)?this._$AH._$AD.el:document.createElement("template");if(function(i,t){var d,v=r(i),l=0!==v.length;l&&((d=document.createElement("style")).textContent=v.join("\n"),t.content.appendChild(d)),n.add(i),o.delete(i),window.ShadyCSS.prepareTemplateStyles(t,i),l&&window.ShadyCSS.nativeShadow&&null!==(d=t.content.querySelector("style"))&&t.content.appendChild(d)}(a,m),e.removeChild(s),null===(v=window.ShadyCSS)||void 0===v?void 0:v.nativeShadow){var y=m.content.querySelector("style");null!==y&&e.appendChild(y.cloneNode(!0))}w.insertBefore(e,f),this._$AA=h,this._$AB=f}else c.call(this,i,t)},h._$AC=function(n){var o,t=null===(o=this.options)||void 0===o?void 0:o.scope,d=w.get(t);void 0===d&&w.set(t,d=new Map);var v=d.get(n.strings);return void 0===v&&d.set(n.strings,v=new i(n,this.options)),v}}};t.noPatchSupported=!0,null!==(i=globalThis.litHtmlPolyfillSupportDevMode)&&void 0!==i||(globalThis.litHtmlPolyfillSupportDevMode=t);
+//# sourceMappingURL=polyfill-support.js.map




diff --git a/front_end/third_party/lit-html/package/node/polyfill-support.js.map b/front_end/third_party/lit-html/package/node/polyfill-support.js.map
new file mode 100644
index 0000000000000000000000000000000000000000..b18d95c80b630d384fb48366d5c764fb996c3fa5
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/polyfill-support.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"polyfill-support.js","sources":["../src/polyfill-support.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n/**\n * lit-html patch to support browsers without native web components.\n *\n * This module should be used in addition to loading the web components\n * polyfills via @webcomponents/webcomponentjs. When using those polyfills\n * support for polyfilled Shadow DOM is automatic via the ShadyDOM polyfill.\n * Scoping classes are added to DOM nodes to facilitate CSS scoping that\n * simulates the style scoping Shadow DOM provides. ShadyDOM does this scoping\n * to all elements added to the DOM. This module provides an important\n * optimization for this process by pre-scoping lit-html template\n * DOM. This means ShadyDOM does not have to scope each instance of the\n * template DOM. Instead, each template is scoped only once.\n *\n * Creating scoped CSS is not covered by this module. It is, however, integrated\n * into the lit-element and @lit/reactive-element packages. See the ShadyCSS docs\n * for how to apply scoping to CSS:\n * https://github.com/webcomponents/polyfills/tree/master/packages/shadycss#usage.\n *\n * @packageDocumentation\n */\n\nexport {};\n\ninterface RenderOptions {\n  readonly renderBefore?: ChildNode | null;\n  scope?: string;\n}\n\ninterface ShadyTemplateResult {\n  strings: TemplateStringsArray;\n  // This property needs to remain unminified.\n  ['_$litType$']?: string;\n}\n\n// Note, this is a dummy type as the full type here is big.\ninterface Directive {\n  __directive?: Directive;\n}\n\ninterface DirectiveParent {\n  _$parent?: DirectiveParent;\n  __directive?: Directive;\n  __directives?: Array<Directive | undefined>;\n}\n\ninterface PatchableChildPartConstructor {\n  // eslint-disable-next-line @typescript-eslint/no-explicit-any, @typescript-eslint/no-misused-new\n  new (...args: any[]): PatchableChildPart;\n}\n\ninterface PatchableChildPart {\n  __directive?: Directive;\n  _$committedValue: unknown;\n  _$startNode: ChildNode;\n  _$endNode: ChildNode | null;\n  options: RenderOptions;\n  _$setValue(value: unknown, directiveParent: DirectiveParent): void;\n  _$getTemplate(result: ShadyTemplateResult): HTMLTemplateElement;\n}\n\ninterface PatchableTemplate {\n  el: HTMLTemplateElement;\n}\n\ninterface PatchableTemplateConstructor {\n  // eslint-disable-next-line @typescript-eslint/no-explicit-any, @typescript-eslint/no-misused-new\n  new (...args: any[]): PatchableTemplate;\n  createElement(html: string, options?: RenderOptions): HTMLTemplateElement;\n}\n\ninterface PatchableTemplateInstance {\n  _$template: PatchableTemplate;\n}\n\n// Scopes that have had styling prepared. Note, must only be done once per\n// scope.\nconst styledScopes: Set<string> = new Set();\n// Map of css per scope. This is collected during first scope render, used when\n// styling is prepared, and then discarded.\nconst scopeCssStore: Map<string, string[]> = new Map();\n\nconst ENABLE_SHADYDOM_NOPATCH = true;\n\n// Note, explicitly use `var` here so that this can be re-defined when\n// bundled.\n// eslint-disable-next-line no-var\nvar DEV_MODE = true;\n\n/**\n * lit-html patches. These properties cannot be renamed.\n * * ChildPart.prototype._$getTemplate\n * * ChildPart.prototype._$setValue\n */\nconst polyfillSupport: NonNullable<typeof litHtmlPolyfillSupport> = (\n  Template: PatchableTemplateConstructor,\n  ChildPart: PatchableChildPartConstructor\n) => {\n  // polyfill-support is only needed if ShadyCSS or the ApplyShim is in use\n  // We test at the point of patching, which makes it safe to load\n  // webcomponentsjs and polyfill-support in either order\n  if (\n    window.ShadyCSS === undefined ||\n    (window.ShadyCSS.nativeShadow && !window.ShadyCSS.ApplyShim)\n  ) {\n    return;\n  }\n\n  // console.log(\n  //   '%c Making lit-html compatible with ShadyDOM/CSS.',\n  //   'color: lightgreen; font-style: italic'\n  // );\n\n  const wrap =\n    ENABLE_SHADYDOM_NOPATCH &&\n    window.ShadyDOM?.inUse &&\n    window.ShadyDOM?.noPatch === true\n      ? window.ShadyDOM!.wrap\n      : (node: Node) => node;\n\n  const needsPrepareStyles = (name: string | undefined) =>\n    name !== undefined && !styledScopes.has(name);\n\n  const cssForScope = (name: string) => {\n    let scopeCss = scopeCssStore.get(name);\n    if (scopeCss === undefined) {\n      scopeCssStore.set(name, (scopeCss = []));\n    }\n    return scopeCss;\n  };\n\n  const prepareStyles = (name: string, template: HTMLTemplateElement) => {\n    // Get styles\n    const scopeCss = cssForScope(name);\n    const hasScopeCss = scopeCss.length !== 0;\n    if (hasScopeCss) {\n      const style = document.createElement('style');\n      style.textContent = scopeCss.join('\\n');\n      // Note, it's important to add the style to the *end* of the template so\n      // it doesn't mess up part indices.\n      template.content.appendChild(style);\n    }\n    // Mark this scope as styled.\n    styledScopes.add(name);\n    // Remove stored data since it's no longer needed.\n    scopeCssStore.delete(name);\n    // ShadyCSS removes scopes and removes the style under ShadyDOM and leaves\n    // it under native Shadow DOM\n    window.ShadyCSS!.prepareTemplateStyles(template, name);\n    // Note, under native Shadow DOM, the style is added to the beginning of the\n    // template. It must be moved to the *end* of the template so it doesn't\n    // mess up part indices.\n    if (hasScopeCss && window.ShadyCSS!.nativeShadow) {\n      // If there were styles but the CSS text was empty, ShadyCSS will\n      // eliminate the style altogether, so the style here could be null\n      const style = template.content.querySelector('style');\n      if (style !== null) {\n        template.content.appendChild(style);\n      }\n    }\n  };\n\n  const scopedTemplateCache = new Map<\n    string | undefined,\n    Map<TemplateStringsArray, PatchableTemplate>\n  >();\n\n  /**\n   * Override to extract style elements from the template\n   * and store all style.textContent in the shady scope data.\n   * Note, it's ok to patch Template since it's only used via ChildPart.\n   */\n  const originalCreateElement = Template.createElement;\n  Template.createElement = function (html: string, options?: RenderOptions) {\n    const element = originalCreateElement.call(Template, html, options);\n    const scope = options?.scope;\n    if (scope !== undefined) {\n      if (!window.ShadyCSS!.nativeShadow) {\n        window.ShadyCSS!.prepareTemplateDom(element, scope);\n      }\n      // Process styles only if this scope is being prepared. Otherwise,\n      // leave styles as is for back compat with Lit1.\n      if (needsPrepareStyles(scope)) {\n        const scopeCss = cssForScope(scope);\n        // Remove styles and store textContent.\n        const styles = element.content.querySelectorAll(\n          'style'\n        ) as NodeListOf<HTMLStyleElement>;\n        // Store the css in this template in the scope css and remove the <style>\n        // from the template _before_ the node-walk captures part indices\n        scopeCss.push(\n          ...Array.from(styles).map((style) => {\n            style.parentNode?.removeChild(style);\n            return style.textContent!;\n          })\n        );\n      }\n    }\n    return element;\n  };\n\n  const renderContainer = document.createDocumentFragment();\n  const renderContainerMarker = document.createComment('');\n\n  const childPartProto = ChildPart.prototype;\n  /**\n   * Patch to apply gathered css via ShadyCSS. This is done only once per scope.\n   */\n  const setValue = childPartProto._$setValue;\n  childPartProto._$setValue = function (\n    this: PatchableChildPart,\n    value: unknown,\n    directiveParent: DirectiveParent = this\n  ) {\n    const container = wrap(this._$startNode).parentNode!;\n    const scope = this.options?.scope;\n    if (container instanceof ShadowRoot && needsPrepareStyles(scope)) {\n      // Note, @apply requires outer => inner scope rendering on initial\n      // scope renders to apply property values correctly. Style preparation\n      // is tied to rendering into `shadowRoot`'s and this is typically done by\n      // custom elements. If this is done in `connectedCallback`, as is typical,\n      // the code below ensures the right order since content is rendered\n      // into a fragment first so the hosting element can prepare styles first.\n      // If rendering is done in the constructor, this won't work, but that's\n      // not supported in ShadyDOM anyway.\n      const startNode = this._$startNode;\n      const endNode = this._$endNode;\n\n      // Temporarily move this part into the renderContainer.\n      renderContainer.appendChild(renderContainerMarker);\n      this._$startNode = renderContainerMarker;\n      this._$endNode = null;\n\n      // Note, any nested template results render here and their styles will\n      // be extracted and collected.\n      setValue.call(this, value, directiveParent);\n\n      // Get the template for this result or create a dummy one if a result\n      // is not being rendered.\n      // This property needs to remain unminified.\n      const template = (value as ShadyTemplateResult)?.['_$litType$']\n        ? (this._$committedValue as PatchableTemplateInstance)._$template.el\n        : document.createElement('template');\n      prepareStyles(scope!, template);\n\n      // Note, this is the temporary startNode.\n      renderContainer.removeChild(renderContainerMarker);\n      // When using native Shadow DOM, include prepared style in shadowRoot.\n      if (window.ShadyCSS?.nativeShadow) {\n        const style = template.content.querySelector('style');\n        if (style !== null) {\n          renderContainer.appendChild(style.cloneNode(true));\n        }\n      }\n      container.insertBefore(renderContainer, endNode);\n      // Move part back to original container.\n      this._$startNode = startNode;\n      this._$endNode = endNode;\n    } else {\n      setValue.call(this, value, directiveParent);\n    }\n  };\n\n  /**\n   * Patch ChildPart._$getTemplate to look up templates in a cache bucketed\n   * by element name.\n   */\n  childPartProto._$getTemplate = function (\n    this: PatchableChildPart,\n    result: ShadyTemplateResult\n  ) {\n    const scope = this.options?.scope;\n    let templateCache = scopedTemplateCache.get(scope);\n    if (templateCache === undefined) {\n      scopedTemplateCache.set(scope, (templateCache = new Map()));\n    }\n    let template = templateCache.get(result.strings);\n    if (template === undefined) {\n      templateCache.set(\n        result.strings,\n        (template = new Template(result, this.options))\n      );\n    }\n    return template;\n  };\n};\n\nif (ENABLE_SHADYDOM_NOPATCH) {\n  polyfillSupport.noPatchSupported = ENABLE_SHADYDOM_NOPATCH;\n}\n\nif (DEV_MODE) {\n  globalThis.litHtmlPolyfillSupportDevMode ??= polyfillSupport;\n} else {\n  globalThis.litHtmlPolyfillSupport ??= polyfillSupport;\n}\n"],"names":["styledScopes","Set","scopeCssStore","Map","polyfillSupport","Template","ChildPart","undefined","window","ShadyCSS","nativeShadow","ApplyShim","wrap","_a","ShadyDOM","inUse","_b","noPatch","node","needsPrepareStyles","name","has","cssForScope","scopeCss","get","set","scopedTemplateCache","originalCreateElement","createElement","html","options","element","call","scope","prepareTemplateDom","styles","content","querySelectorAll","push","apply","Array","from","map","style","parentNode","removeChild","textContent","renderContainer","document","createDocumentFragment","renderContainerMarker","createComment","childPartProto","prototype","setValue","_$setValue","value","directiveParent","this","container","_$startNode","ShadowRoot","startNode","endNode","_$endNode","appendChild","template","_$committedValue","_$template","el","hasScopeCss","length","join","add","delete","prepareTemplateStyles","querySelector","prepareStyles","cloneNode","insertBefore","_$getTemplate","result","templateCache","strings","noPatchSupported","globalThis","litHtmlPolyfillSupportDevMode"],"mappings":";;;;;MAkFMA,EAA4B,IAAIC,IAGhCC,EAAuC,IAAIC,IAc3CC,EAA8D,SAClEC,EACAC,WAKA,QACsBC,IAApBC,OAAOC,YACND,OAAOC,SAASC,cAAiBF,OAAOC,SAASE,WAFpD,CAYA,IAAMC,GAEW,QAAfC,EAAAL,OAAOM,gBAAQ,IAAAD,OAAA,EAAAA,EAAEE,SACY,KAAZ,UAAjBP,OAAOM,gBAAU,IAAAE,OAAA,EAAAA,EAAAC,SACbT,OAAOM,SAAUF,KACjB,SAACM,GAAe,OAAAA,GAEhBC,EAAqB,SAACC,GAC1B,YAASb,IAATa,IAAuBpB,EAAaqB,IAAID,EAAxC,EAEIE,EAAc,SAACF,GACnB,IAAIG,EAAWrB,EAAcsB,IAAIJ,GAIjC,YAHiBb,IAAbgB,GACFrB,EAAcuB,IAAIL,EAAOG,EAAW,IAE/BA,CACT,EAiCMG,EAAsB,IAAIvB,IAU1BwB,EAAwBtB,EAASuB,cACvCvB,EAASuB,cAAgB,SAAUC,EAAcC,GAC/C,IAAMC,EAAUJ,EAAsBK,KAAK3B,EAAUwB,EAAMC,GACrDG,EAAQH,aAAA,E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GrBZ,OAAOC,SAAUkE,sBAAsBT,EAAU9C,GAI7CkD,GAAe9D,OAAOC,SAAUC,cAIpB,QADRiC,EAAQuB,EAAS9B,QAAQwC,cAAc,WAE3CV,EAAS9B,QAAQ6B,YAAYtB,EAGnC,CAmFIkC,CAAc5C,EAAQiC,GAGtBnB,EAAgBF,YAAYK,GAET,UAAf1C,OAAOC,gBAAQ,IAAAO,OAAA,EAAAA,EAAEN,aAAc,CACjC,IAAMiC,EAAQuB,EAAS9B,QAAQwC,cAAc,SAC/B,OAAVjC,GACFI,EAAgBkB,YAAYtB,EAAMmC,WAAU,GAE/C,CACDnB,EAAUoB,aAAahC,EAAiBgB,GAExCL,KAAKE,KAAcE,EACnBJ,KAAKM,KAAYD,CAClB,MACCT,EAAStB,KAAK0B,KAAMF,EAAOC,EAE/B,EAMAL,EAAe4B,KAAgB,SAE7BC,SAEMhD,EAAoB,QAAZpB,EAAA6C,KAAK5B,eAAO,IAAAjB,OAAA,EAAAA,EAAEoB,MACxBiD,EAAgBxD,EAAoBF,IAAIS,QACtB1B,IAAlB2E,GACFxD,EAAoBD,IAAIQ,EAAQiD,EAAgB,IAAI/E,KAEtD,IAAI+D,EAAWgB,EAAc1D,IAAIyD,EAAOE,SAOxC,YANiB5E,IAAb2D,GACFgB,EAAczD,IACZwD,EAAOE,QACNjB,EAAW,IAAI7D,EAAS4E,EAAQvB,KAAK5B,UAGnCoC,CACT,CAlLC,CAmLH,EAGE9D,EAAgBgF,kBA9Mc,EAkNU,QAAxCvE,EAAAwE,WAAWC,qCAA6B,IAAAzE,IAAxCwE,WAAWC,8BAAkClF"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/node/private-ssr-support.js b/front_end/third_party/lit-html/package/node/private-ssr-support.js
new file mode 100644
index 0000000000000000000000000000000000000000..b2fc51c3b62907490229fd07915f2b4c7beb24d7
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/private-ssr-support.js
@@ -0,0 +1,7 @@
+import{_$LH as t,noChange as e}from"./lit-html.js";
+/**
+ * @license
+ * Copyright 2019 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */const r={boundAttributeSuffix:t.P,marker:t.A,markerMatch:t.M,HTML_RESULT:t.C,getTemplateHtml:t.L,overrideDirectiveResolve:(t,e)=>class extends t{_$AS(t,r){return e(this,r)}},setDirectiveClass(t,e){t._$litDirective$=e},getAttributePartCommittedValue:(t,r,i)=>{let a=e;return t.j=t=>a=t,t._$AI(r,t,i),a},connectedDisconnectable:t=>({...t,_$AU:!0}),resolveDirective:t.V,AttributePart:t.H,PropertyPart:t.B,BooleanAttributePart:t.N,EventPart:t.U,ElementPart:t.F};export{r as _$LH};
+//# sourceMappingURL=private-ssr-support.js.map




diff --git a/front_end/third_party/lit-html/package/node/private-ssr-support.js.map b/front_end/third_party/lit-html/package/node/private-ssr-support.js.map
new file mode 100644
index 0000000000000000000000000000000000000000..8b930f2971e4db15a3a9be9cfb7d4f3137284ea1
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/private-ssr-support.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"private-ssr-support.js","sources":["../src/private-ssr-support.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2019 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {\n  Directive,\n  PartInfo,\n  DirectiveClass,\n  DirectiveResult,\n} from './directive.js';\nimport {\n  _$LH as p,\n  AttributePart,\n  noChange,\n  Part,\n  Disconnectable,\n} from './lit-html.js';\nexport type {Template} from './lit-html.js';\n\n/**\n * END USERS SHOULD NOT RELY ON THIS OBJECT.\n *\n * We currently do not make a mangled rollup build of the lit-ssr code. In order\n * to keep a number of (otherwise private) top-level exports mangled in the\n * client side code, we export a _$LH object containing those members (or\n * helper methods for accessing private fields of those members), and then\n * re-export them for use in lit-ssr. This keeps lit-ssr agnostic to whether the\n * client-side code is being used in `dev` mode or `prod` mode.\n * @private\n */\nexport const _$LH = {\n  boundAttributeSuffix: p._boundAttributeSuffix,\n  marker: p._marker,\n  markerMatch: p._markerMatch,\n  HTML_RESULT: p._HTML_RESULT,\n  getTemplateHtml: p._getTemplateHtml,\n  overrideDirectiveResolve: (\n    directiveClass: new (part: PartInfo) => Directive & {render(): unknown},\n    resolveOverrideFn: (directive: Directive, values: unknown[]) => unknown\n  ) =>\n    class extends directiveClass {\n      override _$resolve(\n        this: Directive,\n        _part: Part,\n        values: unknown[]\n      ): unknown {\n        return resolveOverrideFn(this, values);\n      }\n    },\n  setDirectiveClass(value: DirectiveResult, directiveClass: DirectiveClass) {\n    // This property needs to remain unminified.\n    value['_$litDirective$'] = directiveClass;\n  },\n  getAttributePartCommittedValue: (\n    part: AttributePart,\n    value: unknown,\n    index: number | undefined\n  ) => {\n    // Use the part setter to resolve directives/concatenate multiple parts\n    // into a final value (captured by passing in a commitValue override)\n    let committedValue: unknown = noChange;\n    // Note that _commitValue need not be in `stableProperties` because this\n    // method is only run on `AttributePart`s created by lit-ssr using the same\n    // version of the library as this file\n    part._commitValue = (value: unknown) => (committedValue = value);\n    part._$setValue(value, part, index);\n    return committedValue;\n  },\n  connectedDisconnectable: (props?: object): Disconnectable => ({\n    ...props,\n    _$isConnected: true,\n  }),\n  resolveDirective: p._resolveDirective,\n  AttributePart: p._AttributePart,\n  PropertyPart: p._PropertyPart,\n  BooleanAttributePart: p._BooleanAttributePart,\n  EventPart: p._EventPart,\n  ElementPart: p._ElementPart,\n};\n"],"names":["_$LH","boundAttributeSuffix","p","_boundAttributeSuffix","marker","_marker","markerMatch","_markerMatch","HTML_RESULT","_HTML_RESULT","getTemplateHtml","_getTemplateHtml","overrideDirectiveResolve","directiveClass","resolveOverrideFn","_$resolve","_part","values","this","setDirectiveClass","value","getAttributePartCommittedValue","part","index","committedValue","noChange","_commitValue","_$setValue","connectedDisconnectable","props","_$isConnected","resolveDirective","_resolveDirective","AttributePart","_AttributePart","PropertyPart","_PropertyPart","BooleanAttributePart","_BooleanAttributePart","EventPart","_EventPart","ElementPart","_ElementPart"],"mappings":";;;;;GAgCa,MAAAA,EAAO,CAClBC,qBAAsBC,EAAEC,EACxBC,OAAQF,EAAEG,EACVC,YAAaJ,EAAEK,EACfC,YAAaN,EAAEO,EACfC,gBAAiBR,EAAES,EACnBC,yBAA0B,CACxBC,EACAC,IAEA,cAAcD,EACHE,KAEPC,EACAC,GAEA,OAAOH,EAAkBI,KAAMD,EAChC,GAELE,kBAAkBC,EAAwBP,GAExCO,EAAuB,gBAAIP,CAC5B,EACDQ,+BAAgC,CAC9BC,EACAF,EACAG,KAIA,IAAIC,EAA0BC,EAM9B,OAFAH,EAAKI,EAAgBN,GAAoBI,EAAiBJ,EAC1DE,EAAKK,KAAWP,EAAOE,EAAMC,GACtBC,CAAc,EAEvBI,wBAA0BC,IAAoC,IACzDA,EACHC,MAAe,IAEjBC,iBAAkB7B,EAAE8B,EACpBC,cAAe/B,EAAEgC,EACjBC,aAAcjC,EAAEkC,EAChBC,qBAAsBnC,EAAEoC,EACxBC,UAAWrC,EAAEsC,EACbC,YAAavC,EAAEwC"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/node/static.js b/front_end/third_party/lit-html/package/node/static.js
new file mode 100644
index 0000000000000000000000000000000000000000..99e662ec6390d69efa8a2bae137e952b10e5aefd
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/static.js
@@ -0,0 +1,7 @@
+import{html as t,svg as r}from"./lit-html.js";
+/**
+ * @license
+ * Copyright 2020 Google LLC
+ * SPDX-License-Identifier: BSD-3-Clause
+ */const e=Symbol.for(""),l=t=>{if((null==t?void 0:t.r)===e)return null==t?void 0:t._$litStatic$},o=t=>({_$litStatic$:t,r:e}),i=(t,...r)=>({_$litStatic$:r.reduce(((r,e,l)=>r+(t=>{if(void 0!==t._$litStatic$)return t._$litStatic$;throw Error(`Value passed to 'literal' function must be a 'literal' result: ${t}. Use 'unsafeStatic' to pass non-literal values, but\n            take care to ensure page security.`)})(e)+t[l+1]),t[0]),r:e}),s=new Map,a=t=>(r,...e)=>{const o=e.length;let i,a;const n=[],u=[];let c,$=0,f=!1;for(;$<o;){for(c=r[$];$<o&&void 0!==(a=e[$],i=l(a));)c+=i+r[++$],f=!0;u.push(a),n.push(c),$++}if($===o&&n.push(r[o]),f){const t=n.join("$$lit$$");void 0===(r=s.get(t))&&(n.raw=n,s.set(t,r=n)),e=u}return t(r,...e)},n=a(t),u=a(r);export{n as html,i as literal,u as svg,o as unsafeStatic,a as withStatic};
+//# sourceMappingURL=static.js.map




diff --git a/front_end/third_party/lit-html/package/node/static.js.map b/front_end/third_party/lit-html/package/node/static.js.map
new file mode 100644
index 0000000000000000000000000000000000000000..d94dcfd73ece5f42be18601e506076631cac6f42
--- /dev/null
+++ b/front_end/third_party/lit-html/package/node/static.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"static.js","sources":["../src/static.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2020 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n// Any new exports need to be added to the export statement in\n// `packages/lit/src/index.all.ts`.\n\nimport {html as coreHtml, svg as coreSvg, TemplateResult} from './lit-html.js';\n\nexport interface StaticValue {\n  /** The value to interpolate as-is into the template. */\n  _$litStatic$: string;\n\n  /**\n   * A value that can't be decoded from ordinary JSON, make it harder for\n   * a attacker-controlled data that goes through JSON.parse to produce a valid\n   * StaticValue.\n   */\n  r: typeof brand;\n}\n\n/**\n * Prevents JSON injection attacks.\n *\n * The goals of this brand:\n *   1) fast to check\n *   2) code is small on the wire\n *   3) multiple versions of Lit in a single page will all produce mutually\n *      interoperable StaticValues\n *   4) normal JSON.parse (without an unusual reviver) can not produce a\n *      StaticValue\n *\n * Symbols satisfy (1), (2), and (4). We use Symbol.for to satisfy (3), but\n * we don't care about the key, so we break ties via (2) and use the empty\n * string.\n */\nconst brand = Symbol.for('');\n\n/** Safely extracts the string part of a StaticValue. */\nconst unwrapStaticValue = (value: unknown): string | undefined => {\n  if ((value as Partial<StaticValue>)?.r !== brand) {\n    return undefined;\n  }\n  return (value as Partial<StaticValue>)?.['_$litStatic$'];\n};\n\n/**\n * Wraps a string so that it behaves like part of the static template\n * strings instead of a dynamic value.\n *\n * Users must take care to ensure that adding the static string to the template\n * results in well-formed HTML, or else templates may break unexpectedly.\n *\n * Note that this function is unsafe to use on untrusted content, as it will be\n * directly parsed into HTML. Do not pass user input to this function\n * without sanitizing it.\n *\n * Static values can be changed, but they will cause a complete re-render\n * since they effectively create a new template.\n */\nexport const unsafeStatic = (value: string): StaticValue => ({\n  ['_$litStatic$']: value,\n  r: brand,\n});\n\nconst textFromStatic = (value: StaticValue) => {\n  if (value['_$litStatic$'] !== undefined) {\n    return value['_$litStatic$'];\n  } else {\n    throw new Error(\n      `Value passed to 'literal' function must be a 'literal' result: ${value}. Use 'unsafeStatic' to pass non-literal values, but\n            take care to ensure page security.`\n    );\n  }\n};\n\n/**\n * Tags a string literal so that it behaves like part of the static template\n * strings instead of a dynamic value.\n *\n * The only values that may be used in template expressions are other tagged\n * `literal` results or `unsafeStatic` values (note that untrusted content\n * should never be passed to `unsafeStatic`).\n *\n * Users must take care to ensure that adding the static string to the template\n * results in well-formed HTML, or else templates may break unexpectedly.\n *\n * Static values can be changed, but they will cause a complete re-render since\n * they effectively create a new template.\n */\nexport const literal = (\n  strings: TemplateStringsArray,\n  ...values: unknown[]\n): StaticValue => ({\n  ['_$litStatic$']: values.reduce(\n    (acc, v, idx) => acc + textFromStatic(v as StaticValue) + strings[idx + 1],\n    strings[0]\n  ) as string,\n  r: brand,\n});\n\nconst stringsCache = new Map<string, TemplateStringsArray>();\n\n/**\n * Wraps a lit-html template tag (`html` or `svg`) to add static value support.\n */\nexport const withStatic =\n  (coreTag: typeof coreHtml | typeof coreSvg) =>\n  (strings: TemplateStringsArray, ...values: unknown[]): TemplateResult => {\n    const l = values.length;\n    let staticValue: string | undefined;\n    let dynamicValue: unknown;\n    const staticStrings: Array<string> = [];\n    const dynamicValues: Array<unknown> = [];\n    let i = 0;\n    let hasStatics = false;\n    let s: string;\n\n    while (i < l) {\n      s = strings[i];\n      // Collect any unsafeStatic values, and their following template strings\n      // so that we treat a run of template strings and unsafe static values as\n      // a single template string.\n      while (\n        i < l &&\n        ((dynamicValue = values[i]),\n        (staticValue = unwrapStaticValue(dynamicValue))) !== undefined\n      ) {\n        s += staticValue + strings[++i];\n        hasStatics = true;\n      }\n      dynamicValues.push(dynamicValue);\n      staticStrings.push(s);\n      i++;\n    }\n    // If the last value isn't static (which would have consumed the last\n    // string), then we need to add the last string.\n    if (i === l) {\n      staticStrings.push(strings[l]);\n    }\n\n    if (hasStatics) {\n      const key = staticStrings.join('$$lit$$');\n      strings = stringsCache.get(key)!;\n      if (strings === undefined) {\n        // Beware: in general this pattern is unsafe, and doing so may bypass\n        // lit's security checks and allow an attacker to execute arbitrary\n        // code and inject arbitrary content.\n        // eslint-disable-next-line @typescript-eslint/no-explicit-any\n        (staticStrings as any).raw = staticStrings;\n        stringsCache.set(\n          key,\n          (strings = staticStrings as unknown as TemplateStringsArray)\n        );\n      }\n      values = dynamicValues;\n    }\n    return coreTag(strings, ...values);\n  };\n\n/**\n * Interprets a template literal as an HTML template that can efficiently\n * render to and update a container.\n *\n * Includes static value support from `lit-html/static.js`.\n */\nexport const html = withStatic(coreHtml);\n\n/**\n * Interprets a template literal as an SVG template that can efficiently\n * render to and update a container.\n *\n * Includes static value support from `lit-html/static.js`.\n */\nexport const svg = withStatic(coreSvg);\n"],"names":["brand","Symbol","for","unwrapStaticValue","value","r","unsafeStatic","_$litStatic$","literal","strings","values","reduce","acc","v","idx","undefined","Error","textFromStatic","stringsCache","Map","withStatic","coreTag","l","length","staticValue","dynamicValue","staticStrings","dynamicValues","s","i","hasStatics","push","key","join","get","raw","set","html","coreHtml","svg","coreSvg"],"mappings":";;;;;GAsCA,MAAMA,EAAQC,OAAOC,IAAI,IAGnBC,EAAqBC,IACzB,IAAKA,aAAK,EAALA,EAAgCC,KAAML,EAG3C,OAAQI,aAAK,EAALA,EAA+C,YAAC,EAiB7CE,EAAgBF,IAAgC,CAC3DG,aAAkBH,EAClBC,EAAGL,IA4BQQ,EAAU,CACrBC,KACGC,KACc,CACjBH,aAAkBG,EAAOC,QACvB,CAACC,EAAKC,EAAGC,IAAQF,EA9BE,CAACR,IACtB,QAA8BW,IAA1BX,EAAoB,aACtB,OAAOA,EAAoB,aAE3B,MAAUY,MACR,kEAAkEZ,wGAGrE,EAsBwBa,CAAeJ,GAAoBJ,EAAQK,EAAM,IACxEL,EAAQ,IAEVJ,EAAGL,IAGCkB,EAAe,IAAIC,IAKZC,EACVC,GACD,CAACZ,KAAkCC,KACjC,MAAMY,EAAIZ,EAAOa,OACjB,IAAIC,EACAC,EACJ,MAAMC,EAA+B,GAC/BC,EAAgC,GACtC,IAEIC,EAFAC,EAAI,EACJC,GAAa,EAGjB,KAAOD,EAAIP,GAAG,CAKZ,IAJAM,EAAInB,EAAQoB,GAKVA,EAAIP,QAEiDP,KADnDU,EAAef,EAAOmB,GACvBL,EAAcrB,EAAkBsB,KAEjCG,GAAKJ,EAAcf,IAAUoB,GAC7BC,GAAa,EAEfH,EAAcI,KAAKN,GACnBC,EAAcK,KAAKH,GACnBC,GACD,CAOD,GAJIA,IAAMP,GACRI,EAAcK,KAAKtB,EAAQa,IAGzBQ,EAAY,CACd,MAAME,EAAMN,EAAcO,KAAK,gBAEflB,KADhBN,EAAUS,EAAagB,IAAIF,MAMxBN,EAAsBS,IAAMT,EAC7BR,EAAakB,IACXJ,EACCvB,EAAUiB,IAGfhB,EAASiB,CACV,CACD,OAAON,EAAQZ,KAAYC,EAAO,EASzB2B,EAAOjB,EAAWkB,GAQlBC,EAAMnB,EAAWoB"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/package.json b/front_end/third_party/lit-html/package/package.json
index cc449f36eb1f789f2a374c9a5cd66fc61fa29e30..bf06df9d8742569d9e52c3ce2132d72556e96985 100644
--- a/front_end/third_party/lit-html/package/package.json
+++ b/front_end/third_party/lit-html/package/package.json
@@ -1,6 +1,6 @@
 {
   "name": "lit-html",
-  "version": "2.2.1",
+  "version": "2.4.0",
   "description": "HTML templates literals in JavaScript",
   "license": "BSD-3-Clause",
   "repository": {
@@ -15,233 +15,458 @@   "type": "module",
   "exports": {
     ".": {
 {
+      "default": "./directives/join.js"
+      "node": "./node/lit-html.js",
+{
     "type": "git",
       "default": "./lit-html.js"
     },
     "./async-directive.js": {
+      "types": "./development/async-directive.d.ts",
+      "node": "./node/async-directive.js",
       "development": "./development/async-directive.js",
       "default": "./async-directive.js"
     },
     "./directive-helpers.js": {
+      "types": "./development/directive-helpers.d.ts",
+      "node": "./node/directive-helpers.js",
       "development": "./development/directive-helpers.js",
       "default": "./directive-helpers.js"
     },
     "./directive.js": {
+      "types": "./development/directive.d.ts",
+      "node": "./node/directive.js",
       "development": "./development/directive.js",
       "default": "./directive.js"
     },
     "./directives/async-append.js": {
+      "types": "./development/directives/async-append.d.ts",
+      "node": "./node/directives/async-append.js",
       "development": "./development/directives/async-append.js",
       "default": "./directives/async-append.js"
     },
     "./directives/async-replace.js": {
+      "types": "./development/directives/async-replace.d.ts",
+      "node": "./node/directives/async-replace.js",
       "development": "./development/directives/async-replace.js",
       "default": "./directives/async-replace.js"
     },
     "./directives/cache.js": {
+      "types": "./development/directives/cache.d.ts",
+      "node": "./node/directives/cache.js",
       "development": "./development/directives/cache.js",
       "default": "./directives/cache.js"
     },
     "./directives/choose.js": {
+      "types": "./development/directives/choose.d.ts",
+      "node": "./node/directives/choose.js",
       "development": "./development/directives/choose.js",
       "default": "./directives/choose.js"
     },
     "./directives/class-map.js": {
+      "types": "./development/directives/class-map.d.ts",
+      "node": "./node/directives/class-map.js",
       "development": "./development/directives/class-map.js",
       "default": "./directives/class-map.js"
     },
     "./directives/guard.js": {
+      "types": "./development/directives/guard.d.ts",
+      "node": "./node/directives/guard.js",
       "development": "./development/directives/guard.js",
       "default": "./directives/guard.js"
     },
     "./directives/if-defined.js": {
+      "types": "./development/directives/if-defined.d.ts",
+      "node": "./node/directives/if-defined.js",
       "development": "./development/directives/if-defined.js",
       "default": "./directives/if-defined.js"
     },
     "./directives/join.js": {
+      "types": "./development/directives/join.d.ts",
+      "node": "./node/directives/join.js",
       "development": "./development/directives/join.js",
       "default": "./directives/join.js"
     },
     "./directives/keyed.js": {
+      "types": "./development/directives/keyed.d.ts",
+      "node": "./node/directives/keyed.js",
       "development": "./development/directives/keyed.js",
       "default": "./directives/keyed.js"
     },
     "./directives/live.js": {
+      "types": "./development/directives/live.d.ts",
+      "node": "./node/directives/live.js",
       "development": "./development/directives/live.js",
       "default": "./directives/live.js"
     },
     "./directives/map.js": {
+      "types": "./development/directives/map.d.ts",
+      "node": "./node/directives/map.js",
       "development": "./development/directives/map.js",
       "default": "./directives/map.js"
     },
     "./directives/range.js": {
+      "types": "./development/directives/range.d.ts",
+      "node": "./node/directives/range.js",
       "development": "./development/directives/range.js",
       "default": "./directives/range.js"
     },
     "./directives/ref.js": {
+      "types": "./development/directives/ref.d.ts",
+      "node": "./node/directives/ref.js",
       "development": "./development/directives/ref.js",
       "default": "./directives/ref.js"
     },
     "./directives/repeat.js": {
+      "types": "./development/directives/repeat.d.ts",
+      "node": "./node/directives/repeat.js",
       "development": "./development/directives/repeat.js",
       "default": "./directives/repeat.js"
     },
     "./directives/style-map.js": {
+      "types": "./development/directives/style-map.d.ts",
+      "node": "./node/directives/style-map.js",
       "development": "./development/directives/style-map.js",
       "default": "./directives/style-map.js"
     },
     "./directives/template-content.js": {
+      "types": "./development/directives/template-content.d.ts",
+      "node": "./node/directives/template-content.js",
       "development": "./development/directives/template-content.js",
       "default": "./directives/template-content.js"
     },
     "./directives/unsafe-html.js": {
+      "types": "./development/directives/unsafe-html.d.ts",
+      "node": "./node/directives/unsafe-html.js",
       "development": "./development/directives/unsafe-html.js",
       "default": "./directives/unsafe-html.js"
     },
     "./directives/unsafe-svg.js": {
+      "types": "./development/directives/unsafe-svg.d.ts",
+      "node": "./node/directives/unsafe-svg.js",
       "development": "./development/directives/unsafe-svg.js",
       "default": "./directives/unsafe-svg.js"
     },
     "./directives/until.js": {
+      "types": "./development/directives/until.d.ts",
+      "node": "./node/directives/until.js",
       "development": "./development/directives/until.js",
       "default": "./directives/until.js"
     },
     "./directives/when.js": {
+      "types": "./development/directives/when.d.ts",
+      "node": "./node/directives/when.js",
       "development": "./development/directives/when.js",
       "default": "./directives/when.js"
     },
     "./experimental-hydrate.js": {
+      "types": "./development/experimental-hydrate.d.ts",
+      "node": "./node/experimental-hydrate.js",
       "development": "./development/experimental-hydrate.js",
       "default": "./experimental-hydrate.js"
     },
     "./polyfill-support.js": {
+      "types": "./development/polyfill-support.d.ts",
+      "node": "./node/polyfill-support.js",
       "development": "./development/polyfill-support.js",
       "default": "./polyfill-support.js"
     },
     "./private-ssr-support.js": {
+      "types": "./development/private-ssr-support.d.ts",
+      "node": "./node/private-ssr-support.js",
       "development": "./development/private-ssr-support.js",
       "default": "./private-ssr-support.js"
     },
     "./static.js": {
+      "types": "./development/static.d.ts",
+      "node": "./node/static.js",
       "development": "./development/static.js",
       "default": "./static.js"
 {
+    "directory": "packages/lit-html"
+  "name": "lit-html",
+    "url": "https://github.com/lit/lit.git",
+      "types": "./development/is-server.d.ts",
+  "name": "lit-html",
 {
+      "development": "./development/is-server.js",
+      "default": "./is-server.js"
   },
+{
   },
-  "name": "lit-html",
   },
+  "name": "lit-html",
+      "development": "./development/async-directive.js",
   "version": "2.2.1",
+  "name": "lit-html",
 {
   "description": "HTML templates literals in JavaScript",
+  "name": "lit-html",
 {
   "license": "BSD-3-Clause",
+  "name": "lit-html",
 {
   "repository": {
+  "name": "lit-html",
 {
     "type": "git",
+  "name": "lit-html",
 {
     "url": "https://github.com/lit/lit.git",
+  "name": "lit-html",
 {
     "directory": "packages/lit-html"
   "author": "Google LLC",
+  "name": "lit-html",
+      "default": "./async-directive.js"
+      "default": "./async-directive.js"
 {
+    "test:prod": "wireit",
+    "test:node": "wireit"
 {
 {
+      "development": "./development/lit-html.js",
   "author": "Google LLC",
+    "url": "https://github.com/lit/lit.git",
+    "/directive-helpers.{d.ts,d.ts.map,js,js.map}",
+{
   "name": "lit-html",
 {
+  "name": "lit-html",
 {
+    "/lit-html.{d.ts,d.ts.map,js,js.map}",
+  "homepage": "https://lit.dev/",
   "version": "2.2.1",
 {
+      "development": "./development/directive-helpers.js",
 {
+      "default": "./directive-helpers.js"
+      "default": "./async-directive.js"
   "description": "HTML templates literals in JavaScript",
 {
+    "./directive.js": {
 {
+      "development": "./development/directive.js",
+      "default": "./async-directive.js"
   "license": "BSD-3-Clause",
-  "author": "Google LLC",
+      "default": "./async-directive.js"
   "repository": {
 {
+    "./directives/async-append.js": {
+  "wireit": {
+    "build": {
+      "dependencies": [
+    "./directive-helpers.js": {
+    "./directive-helpers.js": {
 {
+        "build:ts:types",
+        "build:version-stability-test"
+      ]
 {
+    "directory": "packages/lit-html"
+    "build:ts": {
+      "#comment": "Note this also builds polyfill-support via a TypeScript project reference.",
+    "./directive-helpers.js": {
     "type": "git",
-  "author": "Google LLC",
+    "./directive-helpers.js": {
     "url": "https://github.com/lit/lit.git",
+      "files": [
+        "src/**/*.ts",
+      "development": "./development/directive-helpers.js",
 {
+        "tsconfig.polyfill-support.json"
+      ],
+      "output": [
+        "development/**/*.{js,js.map,d.ts,d.ts.map}",
+        "tsconfig.tsbuildinfo",
+        "tsconfig.polyfill-support.tsbuildinfo"
+      ]
     },
-{
+    "build:ts:types": {
+      "command": "treemirror development . \"**/*.d.ts{,.map}\"",
   "name": "lit-html",
+    "./directives/async-append.js": {
+      "default": "./directive-helpers.js"
+      "default": "./directive-helpers.js"
 {
+      ],
+      "files": [],
   "name": "lit-html",
+    "./directives/guard.js": {
+        "*.d.ts{,.map}",
+        "directives/*.d.ts{,.map}"
+      ]
 {
+    "directory": "packages/lit-html"
+    "build:rollup": {
+      "command": "rollup -c",
+      "dependencies": [
+      "default": "./directive-helpers.js"
 {
   "name": "lit-html",
+      "default": "./directives/class-map.js"
   "name": "lit-html",
+      "development": "./development/directives/choose.js",
+        "rollup.config.js",
+        "../../rollup-common.js",
+        "src/test/*_test.html",
+        "src/test/polyfill-support/*_test.html"
+      ],
+      "output": [
+    "./directive.js": {
 {
   "name": "lit-html",
+    "./directives/range.js": {
+    "./directive.js": {
   "version": "2.2.1",
+        "experimental-hydrate.js{,.map}",
+        "lit-html.js{,.map}",
+        "polyfill-support.js{,.map}",
+        "private-ssr-support.js{,.map}",
+        "static.js{,.map}",
+        "is-server.js{,.map}",
+        "directives/*.js{,.map}",
+      "development": "./development/directive.js",
 {
   "name": "lit-html",
+      "development": "./development/directives/style-map.js",
+        "test/polyfill-support/*_test.html",
+      "development": "./development/directive.js",
   "description": "HTML templates literals in JavaScript",
-{
   "name": "lit-html",
+    "type": "git",
   "license": "BSD-3-Clause",
+      ]
 {
+    "directory": "packages/lit-html"
   "name": "lit-html",
+    "type": "git",
   "repository": {
-{
       "development": "./development/directive.js",
+    "type": "git",
+      "dependencies": [
+      "default": "./directive-helpers.js"
 {
   "name": "lit-html",
+      "default": "./directives/class-map.js"
+      "files": [
+      "development": "./development/directive.js",
     "url": "https://github.com/lit/lit.git",
-{
+        "rollup.config.js",
   "name": "lit-html",
+    "type": "git",
     "directory": "packages/lit-html"
-{
+      "development": "./development/directive-helpers.js",
   "version": "2.2.1",
+      "output": [
+      "default": "./directive.js"
-{
+  "name": "lit-html",
   "version": "2.2.1",
+  "description": "HTML templates literals in JavaScript",
 {
+    "directory": "packages/lit-html"
+      "default": "./directive.js"
 {
+      "command": "rollup -c --environment=CHECKSIZE",
+      "dependencies": [
+      "default": "./directive-helpers.js"
 {
+      "development": "./development/directive-helpers.js",
   "version": "2.2.1",
   "name": "lit-html",
+      "development": "./development/directives/choose.js",
-{
+        "rollup.config.js",
+        "../../rollup-common.js"
+      "development": "./development/directive-helpers.js",
   "version": "2.2.1",
+      "default": "./directive.js"
   "version": "2.2.1",
 {
+    "directory": "packages/lit-html"
+    "check-version": {
+      "command": "node scripts/check-version-tracker.js",
+  "name": "lit-html",
   "version": "2.2.1",
+    "directory": "packages/lit-html"
+        "scripts/check-version-tracker.js",
+        "package.json",
+        "src/lit-html.ts"
+  "name": "lit-html",
   "description": "HTML templates literals in JavaScript",
+  "version": "2.2.1",
+      "output": []
 {
+    "directory": "packages/lit-html"
+    "test": {
+      "dependencies": [
+        "test:dev",
+        "test:prod",
+        "test:node",
+    "./directives/async-append.js": {
   "version": "2.2.1",
+      ]
+    },
+    "test:dev": {
+    "./directives/async-append.js": {
   "license": "BSD-3-Clause",
+      "dependencies": [
+    "./directive-helpers.js": {
 {
+        "../tests:build"
+      ],
+      "files": [],
+      "default": "./directive.js"
   "version": "2.2.1",
-  "repository": {
 {
-  "version": "2.2.1",
+    "directory": "packages/lit-html"
+    "./directives/async-append.js": {
     "type": "git",
+      "command": "MODE=prod node ../tests/run-web-tests.js \"development/**/*_test.(js|html)\" --config ../tests/web-test-runner.config.js",
+      "dependencies": [
+        "build:rollup",
+    "./directive-helpers.js": {
 {
+        "build:version-stability-test",
+        "../tests:build"
+      "development": "./development/directive-helpers.js",
   "version": "2.2.1",
+      "files": [],
+  "name": "lit-html",
     "url": "https://github.com/lit/lit.git",
+  "version": "2.2.1",
 {
+    "directory": "packages/lit-html"
   "version": "2.2.1",
+      "command": "node development/test/node-imports.js",
+      "default": "./async-directive.js"
     "directory": "packages/lit-html"
+    "./directive-helpers.js": {
 {
+        "build:rollup"
+  "name": "lit-html",
   "description": "HTML templates literals in JavaScript",
+  "version": "2.2.1",
+      "files": [],
+      "output": []
+{
+{
 {
-  "description": "HTML templates literals in JavaScript",
 {
+      "development": "./development/directives/async-append.js",
 {
-  "description": "HTML templates literals in JavaScript",
+      "default": "./directives/async-append.js"
+  },
+  "main": "lit-html.js",
   "name": "lit-html",
 {
-  "description": "HTML templates literals in JavaScript",
   "version": "2.2.1",
+  "license": "BSD-3-Clause",
+    "@webcomponents/shadycss": "^1.8.0",
 {
-    "./directives/guard.js": {
+    "./directives/choose.js": {
 {
-      "development": "./development/directives/guard.js",
+      "development": "./development/directives/choose.js",
+    "@lit-internal/scripts": "^1.0.0"
   },
   "typings": "lit-html.d.ts",
   "directories": {




diff --git a/front_end/third_party/lit-html/package/polyfill-support.js b/front_end/third_party/lit-html/package/polyfill-support.js
index b76a397470812e4ae8273dbb3cd121d9e0b0d173..3999c1bcd16fa554c55e7f3da7efab49213c653e 100644
--- a/front_end/third_party/lit-html/package/polyfill-support.js
+++ b/front_end/third_party/lit-html/package/polyfill-support.js
@@ -3,5 +3,5 @@ /**
      * @license
      * Copyright 2017 Google LLC
      * SPDX-License-Identifier: BSD-3-Clause
-     */var i,n=new Set,o=new Map;null!==(i=globalThis.litHtmlPolyfillSupport)&&void 0!==i||(globalThis.litHtmlPolyfillSupport=function(i,t){if(void 0!==window.ShadyCSS&&(!window.ShadyCSS.nativeShadow||window.ShadyCSS.ApplyShim)){var d=function(i){return void 0!==i&&!n.has(i)},v=function(i){var n=o.get(i);return void 0===n&&o.set(i,n=[]),n},e=new Map,u=i.createElement;i.createElement=function(n,o){var t=u.call(i,n,o),e=null==o?void 0:o.scope;if(void 0!==e&&(window.ShadyCSS.nativeShadow||window.ShadyCSS.prepareTemplateDom(t,e),d(e))){var l=v(e),r=t.content.querySelectorAll("style");l.push.apply(l,Array.from(r).map((function(i){var n;return null===(n=i.parentNode)||void 0===n||n.removeChild(i),i.textContent})))}return t};var l=document.createDocumentFragment(),r=document.createComment(""),a=t.prototype,s=a._$AI;a._$AI=function(i,t){var e,u,a;void 0===t&&(t=this);var w=this._$AA.parentNode,f=null===(e=this.options)||void 0===e?void 0:e.scope;if(w instanceof ShadowRoot&&d(f)){var c=this._$AA,h=this._$AB;l.appendChild(r),this._$AA=r,this._$AB=null,s.call(this,i,t);var y=(null===(u=i)||void 0===u?void 0:u._$litType$)?this._$AH._$AD.el:document.createElement("template");if(function(i,t){var d,e=v(i),u=0!==e.length;u&&((d=document.createElement("style")).textContent=e.join("\n"),t.content.appendChild(d)),n.add(i),o.delete(i),window.ShadyCSS.prepareTemplateStyles(t,i),u&&window.ShadyCSS.nativeShadow&&null!==(d=t.content.querySelector("style"))&&t.content.appendChild(d)}(f,y),l.removeChild(r),null===(a=window.ShadyCSS)||void 0===a?void 0:a.nativeShadow){var m=y.content.querySelector("style");null!==m&&l.appendChild(m.cloneNode(!0))}w.insertBefore(l,h),this._$AA=c,this._$AB=h}else s.call(this,i,t)},a._$AC=function(n){var o,t=null===(o=this.options)||void 0===o?void 0:o.scope,d=e.get(t);void 0===d&&e.set(t,d=new Map);var v=d.get(n.strings);return void 0===v&&d.set(n.strings,v=new i(n,this.options)),v}}})}));
+     */var i,n=new Set,o=new Map;null!==(i=globalThis.litHtmlPolyfillSupport)&&void 0!==i||(globalThis.litHtmlPolyfillSupport=function(i,t){if(void 0!==window.ShadyCSS&&(!window.ShadyCSS.nativeShadow||window.ShadyCSS.ApplyShim)){var d=function(i){return void 0!==i&&!n.has(i)},e=function(i){var n=o.get(i);return void 0===n&&o.set(i,n=[]),n},v=new Map,u=i.createElement;i.createElement=function(n,o){var t=u.call(i,n,o),v=null==o?void 0:o.scope;if(void 0!==v&&(window.ShadyCSS.nativeShadow||window.ShadyCSS.prepareTemplateDom(t,v),d(v))){var l=e(v),r=t.content.querySelectorAll("style");l.push.apply(l,Array.from(r).map((function(i){var n;return null===(n=i.parentNode)||void 0===n||n.removeChild(i),i.textContent})))}return t};var l=document.createDocumentFragment(),r=document.createComment(""),a=t.prototype,s=a._$AI;a._$AI=function(i,t){var v,u;void 0===t&&(t=this);var a=this._$AA.parentNode,w=null===(v=this.options)||void 0===v?void 0:v.scope;if(a instanceof ShadowRoot&&d(w)){var f=this._$AA,c=this._$AB;l.appendChild(r),this._$AA=r,this._$AB=null,s.call(this,i,t);var h=(null==i?void 0:i._$litType$)?this._$AH._$AD.el:document.createElement("template");if(function(i,t){var d,v=e(i),u=0!==v.length;u&&((d=document.createElement("style")).textContent=v.join("\n"),t.content.appendChild(d)),n.add(i),o.delete(i),window.ShadyCSS.prepareTemplateStyles(t,i),u&&window.ShadyCSS.nativeShadow&&null!==(d=t.content.querySelector("style"))&&t.content.appendChild(d)}(w,h),l.removeChild(r),null===(u=window.ShadyCSS)||void 0===u?void 0:u.nativeShadow){var y=h.content.querySelector("style");null!==y&&l.appendChild(y.cloneNode(!0))}a.insertBefore(l,c),this._$AA=f,this._$AB=c}else s.call(this,i,t)},a._$AC=function(n){var o,t=null===(o=this.options)||void 0===o?void 0:o.scope,d=v.get(t);void 0===d&&v.set(t,d=new Map);var e=d.get(n.strings);return void 0===e&&d.set(n.strings,e=new i(n,this.options)),e}}})}));
 //# sourceMappingURL=polyfill-support.js.map




diff --git a/front_end/third_party/lit-html/package/polyfill-support.js.map b/front_end/third_party/lit-html/package/polyfill-support.js.map
index 2319420146b443d6d1ab25e4036bb27c75618fc3..6b5531583fe0728022acc96ef8920ba6287d8ea3 100644
--- a/front_end/third_party/lit-html/package/polyfill-support.js.map
+++ b/front_end/third_party/lit-html/package/polyfill-support.js.map
@@ -1 +1 @@
-{"version":3,"file":"polyfill-support.js","sources":["src/polyfill-support.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n/**\n * lit-html patch to support browsers without native web components.\n *\n * This module should be used in addition to loading the web components\n * polyfills via @webcomponents/webcomponentjs. When using those polyfills\n * support for polyfilled Shadow DOM is automatic via the ShadyDOM polyfill.\n * Scoping classes are added to DOM nodes to facilitate CSS scoping that\n * simulates the style scoping Shadow DOM provides. ShadyDOM does this scoping\n * to all elements added to the DOM. This module provides an important\n * optimization for this process by pre-scoping lit-html template\n * DOM. This means ShadyDOM does not have to scope each instance of the\n * template DOM. Instead, each template is scoped only once.\n *\n * Creating scoped CSS is not covered by this module. It is, however, integrated\n * into the lit-element and @lit/reactive-element packages. See the ShadyCSS docs\n * for how to apply scoping to CSS:\n * https://github.com/webcomponents/polyfills/tree/master/packages/shadycss#usage.\n *\n * @packageDocumentation\n */\n\nexport {};\n\ninterface RenderOptions {\n  readonly renderBefore?: ChildNode | null;\n  scope?: string;\n}\n\ninterface ShadyTemplateResult {\n  strings: TemplateStringsArray;\n  // This property needs to remain unminified.\n  ['_$litType$']?: string;\n}\n\n// Note, this is a dummy type as the full type here is big.\ninterface Directive {\n  __directive?: Directive;\n}\n\ninterface DirectiveParent {\n  _$parent?: DirectiveParent;\n  __directive?: Directive;\n  __directives?: Array<Directive | undefined>;\n}\n\ninterface PatchableChildPartConstructor {\n  // eslint-disable-next-line @typescript-eslint/no-explicit-any, @typescript-eslint/no-misused-new\n  new (...args: any[]): PatchableChildPart;\n}\n\ninterface PatchableChildPart {\n  __directive?: Directive;\n  _$committedValue: unknown;\n  _$startNode: ChildNode;\n  _$endNode: ChildNode | null;\n  options: RenderOptions;\n  _$setValue(value: unknown, directiveParent: DirectiveParent): void;\n  _$getTemplate(result: ShadyTemplateResult): HTMLTemplateElement;\n}\n\ninterface PatchableTemplate {\n  el: HTMLTemplateElement;\n}\n\ninterface PatchableTemplateConstructor {\n  // eslint-disable-next-line @typescript-eslint/no-explicit-any, @typescript-eslint/no-misused-new\n  new (...args: any[]): PatchableTemplate;\n  createElement(html: string, options?: RenderOptions): HTMLTemplateElement;\n}\n\ninterface PatchableTemplateInstance {\n  _$template: PatchableTemplate;\n}\n\n// Scopes that have had styling prepared. Note, must only be done once per\n// scope.\nconst styledScopes: Set<string> = new Set();\n// Map of css per scope. This is collected during first scope render, used when\n// styling is prepared, and then discarded.\nconst scopeCssStore: Map<string, string[]> = new Map();\n\nconst ENABLE_SHADYDOM_NOPATCH = true;\n\n// Note, explicitly use `var` here so that this can be re-defined when\n// bundled.\n// eslint-disable-next-line no-var\nvar DEV_MODE = true;\n\n/**\n * lit-html patches. These properties cannot be renamed.\n * * ChildPart.prototype._$getTemplate\n * * ChildPart.prototype._$setValue\n */\nconst polyfillSupport: NonNullable<typeof litHtmlPolyfillSupport> = (\n  Template: PatchableTemplateConstructor,\n  ChildPart: PatchableChildPartConstructor\n) => {\n  // polyfill-support is only needed if ShadyCSS or the ApplyShim is in use\n  // We test at the point of patching, which makes it safe to load\n  // webcomponentsjs and polyfill-support in either order\n  if (\n    window.ShadyCSS === undefined ||\n    (window.ShadyCSS.nativeShadow && !window.ShadyCSS.ApplyShim)\n  ) {\n    return;\n  }\n\n  // console.log(\n  //   '%c Making lit-html compatible with ShadyDOM/CSS.',\n  //   'color: lightgreen; font-style: italic'\n  // );\n\n  const wrap =\n    ENABLE_SHADYDOM_NOPATCH &&\n    window.ShadyDOM?.inUse &&\n    window.ShadyDOM?.noPatch === true\n      ? window.ShadyDOM!.wrap\n      : (node: Node) => node;\n\n  const needsPrepareStyles = (name: string | undefined) =>\n    name !== undefined && !styledScopes.has(name);\n\n  const cssForScope = (name: string) => {\n    let scopeCss = scopeCssStore.get(name);\n    if (scopeCss === undefined) {\n      scopeCssStore.set(name, (scopeCss = []));\n    }\n    return scopeCss;\n  };\n\n  const prepareStyles = (name: string, template: HTMLTemplateElement) => {\n    // Get styles\n    const scopeCss = cssForScope(name);\n    const hasScopeCss = scopeCss.length !== 0;\n    if (hasScopeCss) {\n      const style = document.createElement('style');\n      style.textContent = scopeCss.join('\\n');\n      // Note, it's important to add the style to the *end* of the template so\n      // it doesn't mess up part indices.\n      template.content.appendChild(style);\n    }\n    // Mark this scope as styled.\n    styledScopes.add(name);\n    // Remove stored data since it's no longer needed.\n    scopeCssStore.delete(name);\n    // ShadyCSS removes scopes and removes the style under ShadyDOM and leaves\n    // it under native Shadow DOM\n    window.ShadyCSS!.prepareTemplateStyles(template, name);\n    // Note, under native Shadow DOM, the style is added to the beginning of the\n    // template. It must be moved to the *end* of the template so it doesn't\n    // mess up part indices.\n    if (hasScopeCss && window.ShadyCSS!.nativeShadow) {\n      // If there were styles but the CSS text was empty, ShadyCSS will\n      // eliminate the style altogether, so the style here could be null\n      const style = template.content.querySelector('style');\n      if (style !== null) {\n        template.content.appendChild(style);\n      }\n    }\n  };\n\n  const scopedTemplateCache = new Map<\n    string | undefined,\n    Map<TemplateStringsArray, PatchableTemplate>\n  >();\n\n  /**\n   * Override to extract style elements from the template\n   * and store all style.textContent in the shady scope data.\n   * Note, it's ok to patch Template since it's only used via ChildPart.\n   */\n  const originalCreateElement = Template.createElement;\n  Template.createElement = function (html: string, options?: RenderOptions) {\n    const element = originalCreateElement.call(Template, html, options);\n    const scope = options?.scope;\n    if (scope !== undefined) {\n      if (!window.ShadyCSS!.nativeShadow) {\n        window.ShadyCSS!.prepareTemplateDom(element, scope);\n      }\n      // Process styles only if this scope is being prepared. Otherwise,\n      // leave styles as is for back compat with Lit1.\n      if (needsPrepareStyles(scope)) {\n        const scopeCss = cssForScope(scope);\n        // Remove styles and store textContent.\n        const styles = element.content.querySelectorAll(\n          'style'\n        ) as NodeListOf<HTMLStyleElement>;\n        // Store the css in this template in the scope css and remove the <style>\n        // from the template _before_ the node-walk captures part indices\n        scopeCss.push(\n          ...Array.from(styles).map((style) => {\n            style.parentNode?.removeChild(style);\n            return style.textContent!;\n          })\n        );\n      }\n    }\n    return element;\n  };\n\n  const renderContainer = document.createDocumentFragment();\n  const renderContainerMarker = document.createComment('');\n\n  const childPartProto = ChildPart.prototype;\n  /**\n   * Patch to apply gathered css via ShadyCSS. This is done only once per scope.\n   */\n  const setValue = childPartProto._$setValue;\n  childPartProto._$setValue = function (\n    this: PatchableChildPart,\n    value: unknown,\n    directiveParent: DirectiveParent = this\n  ) {\n    const container = wrap(this._$startNode).parentNode!;\n    const scope = this.options?.scope;\n    if (container instanceof ShadowRoot && needsPrepareStyles(scope)) {\n      // Note, @apply requires outer => inner scope rendering on initial\n      // scope renders to apply property values correctly. Style preparation\n      // is tied to rendering into `shadowRoot`'s and this is typically done by\n      // custom elements. If this is done in `connectedCallback`, as is typical,\n      // the code below ensures the right order since content is rendered\n      // into a fragment first so the hosting element can prepare styles first.\n      // If rendering is done in the constructor, this won't work, but that's\n      // not supported in ShadyDOM anyway.\n      const startNode = this._$startNode;\n      const endNode = this._$endNode;\n\n      // Temporarily move this part into the renderContainer.\n      renderContainer.appendChild(renderContainerMarker);\n      this._$startNode = renderContainerMarker;\n      this._$endNode = null;\n\n      // Note, any nested template results render here and their styles will\n      // be extracted and collected.\n      setValue.call(this, value, directiveParent);\n\n      // Get the template for this result or create a dummy one if a result\n      // is not being rendered.\n      // This property needs to remain unminified.\n      const template = (value as ShadyTemplateResult)?.['_$litType$']\n        ? (this._$committedValue as PatchableTemplateInstance)._$template.el\n        : document.createElement('template');\n      prepareStyles(scope!, template);\n\n      // Note, this is the temporary startNode.\n      renderContainer.removeChild(renderContainerMarker);\n      // When using native Shadow DOM, include prepared style in shadowRoot.\n      if (window.ShadyCSS?.nativeShadow) {\n        const style = template.content.querySelector('style');\n        if (style !== null) {\n          renderContainer.appendChild(style.cloneNode(true));\n        }\n      }\n      container.insertBefore(renderContainer, endNode);\n      // Move part back to original container.\n      this._$startNode = startNode;\n      this._$endNode = endNode;\n    } else {\n      setValue.call(this, value, directiveParent);\n    }\n  };\n\n  /**\n   * Patch ChildPart._$getTemplate to look up templates in a cache bucketed\n   * by element name.\n   */\n  childPartProto._$getTemplate = function (\n    this: PatchableChildPart,\n    result: ShadyTemplateResult\n  ) {\n    const scope = this.options?.scope;\n    let templateCache = scopedTemplateCache.get(scope);\n    if (templateCache === undefined) {\n      scopedTemplateCache.set(scope, (templateCache = new Map()));\n    }\n    let template = templateCache.get(result.strings);\n    if (template === undefined) {\n      templateCache.set(\n        result.strings,\n        (template = new Template(result, this.options))\n      );\n    }\n    return template;\n  };\n};\n\nif (ENABLE_SHADYDOM_NOPATCH) {\n  polyfillSupport.noPatchSupported = ENABLE_SHADYDOM_NOPATCH;\n}\n\nif (DEV_MODE) {\n  globalThis.litHtmlPolyfillSupportDevMode ??= polyfillSupport;\n} else {\n  globalThis.litHtmlPolyfillSupport ??= polyfillSupport;\n}\n"],"names":["styledScopes","Set","scopeCssStore","Map","globalThis","litHtmlPolyfillSupport","Template","ChildPart","undefined","window","ShadyCSS","nativeShadow","ApplyShim","needsPrepareStyles","name","has","cssForScope","scopeCss","get","set","scopedTemplateCache","originalCreateElement","createElement","html","options","element","call","scope","prepareTemplateDom","styles","content","querySelectorAll","push","Array","from","map","style","parentNode","removeChild","textContent","renderContainer","document","createDocumentFragment","renderContainerMarker","createComment","childPartProto","prototype","setValue","_$setValue","value","directiveParent","container","this","_$startNode","ShadowRoot","startNode","endNode","_$endNode","appendChild","template","_$committedValue","_$template","el","hasScopeCss","length","join","add","delete","prepareTemplateStyles","querySelector","prepareStyles","cloneNode","insertBefore","_$getTemplate","result","templateCache","strings"],"mappings":";;;;;aAkFMA,EAA4B,IAAIC,IAGhCC,EAAuC,IAAIC,cAsN/CC,WAAWC,sCAAXD,WAAWC,uBAxMuD,SAClEC,EACAC,GAKA,QACsBC,IAApBC,OAAOC,YACND,OAAOC,SAASC,cAAiBF,OAAOC,SAASE,WAFpD,CAYA,IAOMC,EAAqB,SAACC,GAC1B,YAASN,IAATM,IAAuBd,EAAae,IAAID,IAEpCE,EAAc,SAACF,GACnB,IAAIG,EAAWf,EAAcgB,IAAIJ,GAIjC,YAHiBN,IAAbS,GACFf,EAAciB,IAAIL,EAAOG,EAAW,IAE/BA,GAkCHG,EAAsB,IAAIjB,IAU1BkB,EAAwBf,EAASgB,cACvChB,EAASgB,cAAgB,SAAUC,EAAcC,GAC/C,IAAMC,EAAUJ,EAAsBK,KAAKpB,EAAUiB,EAAMC,GACrDG,EAAQH,MAAAA,SAAAA,EAASG,MACvB,QAAcnB,IAAVmB,IACGlB,OAAOC,SAAUC,cACpBF,OAAOC,SAAUkB,mBAAmBH,EAASE,GAI3Cd,EAAmBc,IAAQ,CAC7B,IAAMV,EAAWD,EAAYW,GAEvBE,EAASJ,EAAQK,QAAQC,iBAC7B,SAIFd,EAASe,WAATf,EACKgB,MAAMC,KAAKL,GAAQM,KAAI,SAACC,SAEzB,iBADAA,EAAMC,2BAAYC,YAAYF,GACvBA,EAAMG,gBAKrB,OAAOd,GAGT,IAAMe,EAAkBC,SAASC,yBAC3BC,EAAwB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ASG,MACxBgD,EAAgBvD,EAAoBF,IAAIS,QACtBnB,IAAlBmE,GACFvD,EAAoBD,IAAIQ,EAAQgD,EAAgB,IAAIxE,KAEtD,IAAIwD,EAAWgB,EAAczD,IAAIwD,EAAOE,SAOxC,YANiBpE,IAAbmD,GACFgB,EAAcxD,IACZuD,EAAOE,QACNjB,EAAW,IAAIrD,EAASoE,EAAQtB,KAAK5B,UAGnCmC"}
\ No newline at end of file
+{"version":3,"file":"polyfill-support.js","sources":["src/polyfill-support.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n/**\n * lit-html patch to support browsers without native web components.\n *\n * This module should be used in addition to loading the web components\n * polyfills via @webcomponents/webcomponentjs. When using those polyfills\n * support for polyfilled Shadow DOM is automatic via the ShadyDOM polyfill.\n * Scoping classes are added to DOM nodes to facilitate CSS scoping that\n * simulates the style scoping Shadow DOM provides. ShadyDOM does this scoping\n * to all elements added to the DOM. This module provides an important\n * optimization for this process by pre-scoping lit-html template\n * DOM. This means ShadyDOM does not have to scope each instance of the\n * template DOM. Instead, each template is scoped only once.\n *\n * Creating scoped CSS is not covered by this module. It is, however, integrated\n * into the lit-element and @lit/reactive-element packages. See the ShadyCSS docs\n * for how to apply scoping to CSS:\n * https://github.com/webcomponents/polyfills/tree/master/packages/shadycss#usage.\n *\n * @packageDocumentation\n */\n\nexport {};\n\ninterface RenderOptions {\n  readonly renderBefore?: ChildNode | null;\n  scope?: string;\n}\n\ninterface ShadyTemplateResult {\n  strings: TemplateStringsArray;\n  // This property needs to remain unminified.\n  ['_$litType$']?: string;\n}\n\n// Note, this is a dummy type as the full type here is big.\ninterface Directive {\n  __directive?: Directive;\n}\n\ninterface DirectiveParent {\n  _$parent?: DirectiveParent;\n  __directive?: Directive;\n  __directives?: Array<Directive | undefined>;\n}\n\ninterface PatchableChildPartConstructor {\n  // eslint-disable-next-line @typescript-eslint/no-explicit-any, @typescript-eslint/no-misused-new\n  new (...args: any[]): PatchableChildPart;\n}\n\ninterface PatchableChildPart {\n  __directive?: Directive;\n  _$committedValue: unknown;\n  _$startNode: ChildNode;\n  _$endNode: ChildNode | null;\n  options: RenderOptions;\n  _$setValue(value: unknown, directiveParent: DirectiveParent): void;\n  _$getTemplate(result: ShadyTemplateResult): HTMLTemplateElement;\n}\n\ninterface PatchableTemplate {\n  el: HTMLTemplateElement;\n}\n\ninterface PatchableTemplateConstructor {\n  // eslint-disable-next-line @typescript-eslint/no-explicit-any, @typescript-eslint/no-misused-new\n  new (...args: any[]): PatchableTemplate;\n  createElement(html: string, options?: RenderOptions): HTMLTemplateElement;\n}\n\ninterface PatchableTemplateInstance {\n  _$template: PatchableTemplate;\n}\n\n// Scopes that have had styling prepared. Note, must only be done once per\n// scope.\nconst styledScopes: Set<string> = new Set();\n// Map of css per scope. This is collected during first scope render, used when\n// styling is prepared, and then discarded.\nconst scopeCssStore: Map<string, string[]> = new Map();\n\nconst ENABLE_SHADYDOM_NOPATCH = true;\n\n// Note, explicitly use `var` here so that this can be re-defined when\n// bundled.\n// eslint-disable-next-line no-var\nvar DEV_MODE = true;\n\n/**\n * lit-html patches. These properties cannot be renamed.\n * * ChildPart.prototype._$getTemplate\n * * ChildPart.prototype._$setValue\n */\nconst polyfillSupport: NonNullable<typeof litHtmlPolyfillSupport> = (\n  Template: PatchableTemplateConstructor,\n  ChildPart: PatchableChildPartConstructor\n) => {\n  // polyfill-support is only needed if ShadyCSS or the ApplyShim is in use\n  // We test at the point of patching, which makes it safe to load\n  // webcomponentsjs and polyfill-support in either order\n  if (\n    window.ShadyCSS === undefined ||\n    (window.ShadyCSS.nativeShadow && !window.ShadyCSS.ApplyShim)\n  ) {\n    return;\n  }\n\n  // console.log(\n  //   '%c Making lit-html compatible with ShadyDOM/CSS.',\n  //   'color: lightgreen; font-style: italic'\n  // );\n\n  const wrap =\n    ENABLE_SHADYDOM_NOPATCH &&\n    window.ShadyDOM?.inUse &&\n    window.ShadyDOM?.noPatch === true\n      ? window.ShadyDOM!.wrap\n      : (node: Node) => node;\n\n  const needsPrepareStyles = (name: string | undefined) =>\n    name !== undefined && !styledScopes.has(name);\n\n  const cssForScope = (name: string) => {\n    let scopeCss = scopeCssStore.get(name);\n    if (scopeCss === undefined) {\n      scopeCssStore.set(name, (scopeCss = []));\n    }\n    return scopeCss;\n  };\n\n  const prepareStyles = (name: string, template: HTMLTemplateElement) => {\n    // Get styles\n    const scopeCss = cssForScope(name);\n    const hasScopeCss = scopeCss.length !== 0;\n    if (hasScopeCss) {\n      const style = document.createElement('style');\n      style.textContent = scopeCss.join('\\n');\n      // Note, it's important to add the style to the *end* of the template so\n      // it doesn't mess up part indices.\n      template.content.appendChild(style);\n    }\n    // Mark this scope as styled.\n    styledScopes.add(name);\n    // Remove stored data since it's no longer needed.\n    scopeCssStore.delete(name);\n    // ShadyCSS removes scopes and removes the style under ShadyDOM and leaves\n    // it under native Shadow DOM\n    window.ShadyCSS!.prepareTemplateStyles(template, name);\n    // Note, under native Shadow DOM, the style is added to the beginning of the\n    // template. It must be moved to the *end* of the template so it doesn't\n    // mess up part indices.\n    if (hasScopeCss && window.ShadyCSS!.nativeShadow) {\n      // If there were styles but the CSS text was empty, ShadyCSS will\n      // eliminate the style altogether, so the style here could be null\n      const style = template.content.querySelector('style');\n      if (style !== null) {\n        template.content.appendChild(style);\n      }\n    }\n  };\n\n  const scopedTemplateCache = new Map<\n    string | undefined,\n    Map<TemplateStringsArray, PatchableTemplate>\n  >();\n\n  /**\n   * Override to extract style elements from the template\n   * and store all style.textContent in the shady scope data.\n   * Note, it's ok to patch Template since it's only used via ChildPart.\n   */\n  const originalCreateElement = Template.createElement;\n  Template.createElement = function (html: string, options?: RenderOptions) {\n    const element = originalCreateElement.call(Template, html, options);\n    const scope = options?.scope;\n    if (scope !== undefined) {\n      if (!window.ShadyCSS!.nativeShadow) {\n        window.ShadyCSS!.prepareTemplateDom(element, scope);\n      }\n      // Process styles only if this scope is being prepared. Otherwise,\n      // leave styles as is for back compat with Lit1.\n      if (needsPrepareStyles(scope)) {\n        const scopeCss = cssForScope(scope);\n        // Remove styles and store textContent.\n        const styles = element.content.querySelectorAll(\n          'style'\n        ) as NodeListOf<HTMLStyleElement>;\n        // Store the css in this template in the scope css and remove the <style>\n        // from the template _before_ the node-walk captures part indices\n        scopeCss.push(\n          ...Array.from(styles).map((style) => {\n            style.parentNode?.removeChild(style);\n            return style.textContent!;\n          })\n        );\n      }\n    }\n    return element;\n  };\n\n  const renderContainer = document.createDocumentFragment();\n  const renderContainerMarker = document.createComment('');\n\n  const childPartProto = ChildPart.prototype;\n  /**\n   * Patch to apply gathered css via ShadyCSS. This is done only once per scope.\n   */\n  const setValue = childPartProto._$setValue;\n  childPartProto._$setValue = function (\n    this: PatchableChildPart,\n    value: unknown,\n    directiveParent: DirectiveParent = this\n  ) {\n    const container = wrap(this._$startNode).parentNode!;\n    const scope = this.options?.scope;\n    if (container instanceof ShadowRoot && needsPrepareStyles(scope)) {\n      // Note, @apply requires outer => inner scope rendering on initial\n      // scope renders to apply property values correctly. Style preparation\n      // is tied to rendering into `shadowRoot`'s and this is typically done by\n      // custom elements. If this is done in `connectedCallback`, as is typical,\n      // the code below ensures the right order since content is rendered\n      // into a fragment first so the hosting element can prepare styles first.\n      // If rendering is done in the constructor, this won't work, but that's\n      // not supported in ShadyDOM anyway.\n      const startNode = this._$startNode;\n      const endNode = this._$endNode;\n\n      // Temporarily move this part into the renderContainer.\n      renderContainer.appendChild(renderContainerMarker);\n      this._$startNode = renderContainerMarker;\n      this._$endNode = null;\n\n      // Note, any nested template results render here and their styles will\n      // be extracted and collected.\n      setValue.call(this, value, directiveParent);\n\n      // Get the template for this result or create a dummy one if a result\n      // is not being rendered.\n      // This property needs to remain unminified.\n      const template = (value as ShadyTemplateResult)?.['_$litType$']\n        ? (this._$committedValue as PatchableTemplateInstance)._$template.el\n        : document.createElement('template');\n      prepareStyles(scope!, template);\n\n      // Note, this is the temporary startNode.\n      renderContainer.removeChild(renderContainerMarker);\n      // When using native Shadow DOM, include prepared style in shadowRoot.\n      if (window.ShadyCSS?.nativeShadow) {\n        const style = template.content.querySelector('style');\n        if (style !== null) {\n          renderContainer.appendChild(style.cloneNode(true));\n        }\n      }\n      container.insertBefore(renderContainer, endNode);\n      // Move part back to original container.\n      this._$startNode = startNode;\n      this._$endNode = endNode;\n    } else {\n      setValue.call(this, value, directiveParent);\n    }\n  };\n\n  /**\n   * Patch ChildPart._$getTemplate to look up templates in a cache bucketed\n   * by element name.\n   */\n  childPartProto._$getTemplate = function (\n    this: PatchableChildPart,\n    result: ShadyTemplateResult\n  ) {\n    const scope = this.options?.scope;\n    let templateCache = scopedTemplateCache.get(scope);\n    if (templateCache === undefined) {\n      scopedTemplateCache.set(scope, (templateCache = new Map()));\n    }\n    let template = templateCache.get(result.strings);\n    if (template === undefined) {\n      templateCache.set(\n        result.strings,\n        (template = new Template(result, this.options))\n      );\n    }\n    return template;\n  };\n};\n\nif (ENABLE_SHADYDOM_NOPATCH) {\n  polyfillSupport.noPatchSupported = ENABLE_SHADYDOM_NOPATCH;\n}\n\nif (DEV_MODE) {\n  globalThis.litHtmlPolyfillSupportDevMode ??= polyfillSupport;\n} else {\n  globalThis.litHtmlPolyfillSupport ??= polyfillSupport;\n}\n"],"names":["styledScopes","Set","scopeCssStore","Map","_b","globalThis","litHtmlPolyfillSupport","Template","ChildPart","undefined","window","ShadyCSS","nativeShadow","ApplyShim","needsPrepareStyles","name","has","cssForScope","scopeCss","get","set","scopedTemplateCache","originalCreateElement","createElement","html","options","element","call","scope","prepareTemplateDom","styles","content","querySelectorAll","push","apply","Array","from","map","style","_a","parentNode","removeChild","textContent","renderContainer","document","createDocumentFragment","renderContainerMarker","createComment","childPartProto","prototype","setValue","_$setValue","value","directiveParent","this","container","_$startNode","ShadowRoot","startNode","endNode","_$endNode","appendChild","template","_$committedValue","_$template","el","hasScopeCss","length","join","add","delete","prepareTemplateStyles","querySelector","prepareStyles","cloneNode","insertBefore","_$getTempl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AAlBqE,GACFzD,EAAoBD,IAAIQ,EAAQkD,EAAgB,IAAI3E,KAEtD,IAAI2D,EAAWgB,EAAc3D,IAAI0D,EAAOE,SAOxC,YANiBtE,IAAbqD,GACFgB,EAAc1D,IACZyD,EAAOE,QACNjB,EAAW,IAAIvD,EAASsE,EAAQvB,KAAK7B,UAGnCqC,CACT,CAlLC,CAmLH"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/private-ssr-support.d.ts b/front_end/third_party/lit-html/package/private-ssr-support.d.ts
index 7f05335becf6ca8b86af3b8fc9d6fe46384e3bc8..c781687efec0eac385852a866d086c90876c38a5 100644
--- a/front_end/third_party/lit-html/package/private-ssr-support.d.ts
+++ b/front_end/third_party/lit-html/package/private-ssr-support.d.ts
@@ -22,8 +22,8 @@     boundAttributeSuffix: string;
     marker: string;
     markerMatch: string;
     HTML_RESULT: number;
+ */
  * @license
- * Copyright 2019 Google LLC
     overrideDirectiveResolve: (directiveClass: new (part: PartInfo) => Directive & {
         render(): unknown;
     }, resolveOverrideFn: (directive: Directive, values: unknown[]) => unknown) => {
@@ -43,7 +43,7 @@         };
     };
     setDirectiveClass(value: DirectiveResult, directiveClass: DirectiveClass): void;
     getAttributePartCommittedValue: (part: AttributePart, value: unknown, index: number | undefined) => unknown;
- * SPDX-License-Identifier: BSD-3-Clause
+ */
  * Copyright 2019 Google LLC
     resolveDirective: (part: import("./lit-html.js").ChildPart | AttributePart | import("./lit-html.js").ElementPart, value: unknown, parent?: import("./lit-html.js").DirectiveParent, attributeIndex?: number | undefined) => unknown;
     AttributePart: typeof AttributePart;




diff --git a/front_end/third_party/lit-html/package/private-ssr-support.d.ts.map b/front_end/third_party/lit-html/package/private-ssr-support.d.ts.map
index 4f3d848609fdb23d0eb9af41bc154218075fe735..8fa45a29f67b6e8b44c0454bb263bdefa4e96154 100644
--- a/front_end/third_party/lit-html/package/private-ssr-support.d.ts.map
+++ b/front_end/third_party/lit-html/package/private-ssr-support.d.ts.map
@@ -1 +1 @@
-{"version":3,"file":"private-ssr-support.d.ts","sourceRoot":"","sources":["../src/private-ssr-support.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EACL,SAAS,EACT,QAAQ,EACR,cAAc,EACd,eAAe,EAChB,MAAM,gBAAgB,CAAC;AACxB,OAAO,EAEL,aAAa,EAEb,IAAI,EACJ,cAAc,EACf,MAAM,eAAe,CAAC;AACvB,YAAY,EAAC,QAAQ,EAAC,MAAM,eAAe,CAAC;AAE5C;;;;;;;;;;GAUG;AACH,eAAO,MAAM,IAAI;;;;;;0DAOc,QAAQ,KAAK,SAAS,GAAG;QAAC,MAAM,IAAI,OAAO,CAAA;KAAC,iCACxC,SAAS,UAAU,OAAO,EAAE,KAAK,OAAO;mBAD5C,QAAQ;4BAKzB,SAAS,SACR,IAAI,UACH,OAAO,EAAE,GAChB,OAAO;;;;;;;;;gEARmD,OAAO;;;;6BAY/C,eAAe,kBAAkB,cAAc;2CAKhE,aAAa,SACZ,OAAO,SACP,MAAM,GAAG,SAAS;6DAYgB,cAAc;;;;;;;CAU1D,CAAC"}
\ No newline at end of file
+{"version":3,"file":"private-ssr-support.d.ts","sourceRoot":"","sources":["../src/private-ssr-support.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EACL,SAAS,EACT,QAAQ,EACR,cAAc,EACd,eAAe,EAChB,MAAM,gBAAgB,CAAC;AACxB,OAAO,EAEL,aAAa,EAEb,IAAI,EACJ,cAAc,EACf,MAAM,eAAe,CAAC;AACvB,YAAY,EAAC,QAAQ,EAAC,MAAM,eAAe,CAAC;AAE5C;;;;;;;;;;GAUG;AACH,eAAO,MAAM,IAAI;;;;;;0DAOc,QAAQ,KAAK,SAAS,GAAG;QAAC,MAAM,IAAI,OAAO,CAAA;KAAC,iCACxC,SAAS,UAAU,OAAO,EAAE,KAAK,OAAO;mBAD5C,QAAQ;4BAKzB,SAAS,SACR,IAAI,UACH,OAAO,EAAE,GAChB,OAAO;;;;;;;;;gEARmD,OAAO;;;;6BAY/C,eAAe,kBAAkB,cAAc;2CAKhE,aAAa,SACZ,OAAO,SACP,MAAM,GAAG,SAAS;sCAYO,MAAM,KAAG,cAAc;;;;;;;CAU1D,CAAC"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/private-ssr-support.js b/front_end/third_party/lit-html/package/private-ssr-support.js
index 5220fbbf23db509fd601e3507c61a75811e41955..b2fc51c3b62907490229fd07915f2b4c7beb24d7 100644
--- a/front_end/third_party/lit-html/package/private-ssr-support.js
+++ b/front_end/third_party/lit-html/package/private-ssr-support.js
@@ -3,5 +3,5 @@ /**
  * @license
  * Copyright 2019 Google LLC
  * SPDX-License-Identifier: BSD-3-Clause
- */const r={boundAttributeSuffix:t.P,marker:t.L,markerMatch:t.V,HTML_RESULT:t.I,getTemplateHtml:t.N,overrideDirectiveResolve:(t,e)=>class extends t{_$AS(t,r){return e(this,r)}},setDirectiveClass(t,e){t._$litDirective$=e},getAttributePartCommittedValue:(t,r,i)=>{let a=e;return t.C=t=>a=t,t._$AI(r,t,i),a},connectedDisconnectable:t=>({...t,_$AU:!0}),resolveDirective:t.j,AttributePart:t.O,PropertyPart:t.W,BooleanAttributePart:t.F,EventPart:t.B,ElementPart:t.Z};export{r as _$LH};
+ */const r={boundAttributeSuffix:t.P,marker:t.A,markerMatch:t.M,HTML_RESULT:t.C,getTemplateHtml:t.L,overrideDirectiveResolve:(t,e)=>class extends t{_$AS(t,r){return e(this,r)}},setDirectiveClass(t,e){t._$litDirective$=e},getAttributePartCommittedValue:(t,r,i)=>{let a=e;return t.j=t=>a=t,t._$AI(r,t,i),a},connectedDisconnectable:t=>({...t,_$AU:!0}),resolveDirective:t.V,AttributePart:t.H,PropertyPart:t.B,BooleanAttributePart:t.N,EventPart:t.U,ElementPart:t.F};export{r as _$LH};
 //# sourceMappingURL=private-ssr-support.js.map




diff --git a/front_end/third_party/lit-html/package/private-ssr-support.js.map b/front_end/third_party/lit-html/package/private-ssr-support.js.map
index 104db61ad69620c3f9c9e1864433e5292318669a..78dfced2b09ca6e53d2ccd870e09ae89cd36eec5 100644
--- a/front_end/third_party/lit-html/package/private-ssr-support.js.map
+++ b/front_end/third_party/lit-html/package/private-ssr-support.js.map
@@ -1 +1 @@
-{"version":3,"file":"private-ssr-support.js","sources":["src/private-ssr-support.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2019 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {\n  Directive,\n  PartInfo,\n  DirectiveClass,\n  DirectiveResult,\n} from './directive.js';\nimport {\n  _$LH as p,\n  AttributePart,\n  noChange,\n  Part,\n  Disconnectable,\n} from './lit-html.js';\nexport type {Template} from './lit-html.js';\n\n/**\n * END USERS SHOULD NOT RELY ON THIS OBJECT.\n *\n * We currently do not make a mangled rollup build of the lit-ssr code. In order\n * to keep a number of (otherwise private) top-level exports mangled in the\n * client side code, we export a _$LH object containing those members (or\n * helper methods for accessing private fields of those members), and then\n * re-export them for use in lit-ssr. This keeps lit-ssr agnostic to whether the\n * client-side code is being used in `dev` mode or `prod` mode.\n * @private\n */\nexport const _$LH = {\n  boundAttributeSuffix: p._boundAttributeSuffix,\n  marker: p._marker,\n  markerMatch: p._markerMatch,\n  HTML_RESULT: p._HTML_RESULT,\n  getTemplateHtml: p._getTemplateHtml,\n  overrideDirectiveResolve: (\n    directiveClass: new (part: PartInfo) => Directive & {render(): unknown},\n    resolveOverrideFn: (directive: Directive, values: unknown[]) => unknown\n  ) =>\n    class extends directiveClass {\n      override _$resolve(\n        this: Directive,\n        _part: Part,\n        values: unknown[]\n      ): unknown {\n        return resolveOverrideFn(this, values);\n      }\n    },\n  setDirectiveClass(value: DirectiveResult, directiveClass: DirectiveClass) {\n    // This property needs to remain unminified.\n    value['_$litDirective$'] = directiveClass;\n  },\n  getAttributePartCommittedValue: (\n    part: AttributePart,\n    value: unknown,\n    index: number | undefined\n  ) => {\n    // Use the part setter to resolve directives/concatenate multiple parts\n    // into a final value (captured by passing in a commitValue override)\n    let committedValue: unknown = noChange;\n    // Note that _commitValue need not be in `stableProperties` because this\n    // method is only run on `AttributePart`s created by lit-ssr using the same\n    // version of the library as this file\n    part._commitValue = (value: unknown) => (committedValue = value);\n    part._$setValue(value, part, index);\n    return committedValue;\n  },\n  connectedDisconnectable: (props?: object): Disconnectable => ({\n    ...props,\n    _$isConnected: true,\n  }),\n  resolveDirective: p._resolveDirective,\n  AttributePart: p._AttributePart,\n  PropertyPart: p._PropertyPart,\n  BooleanAttributePart: p._BooleanAttributePart,\n  EventPart: p._EventPart,\n  ElementPart: p._ElementPart,\n};\n"],"names":["_$LH","boundAttributeSuffix","p","_boundAttributeSuffix","marker","_marker","markerMatch","_markerMatch","HTML_RESULT","_HTML_RESULT","getTemplateHtml","_getTemplateHtml","overrideDirectiveResolve","directiveClass","resolveOverrideFn","_$resolve","_part","values","this","setDirectiveClass","value","getAttributePartCommittedValue","part","index","committedValue","noChange","_commitValue","_$setValue","connectedDisconnectable","props","_$isConnected","resolveDirective","_resolveDirective","AttributePart","_AttributePart","PropertyPart","_PropertyPart","BooleanAttributePart","_BooleanAttributePart","EventPart","_EventPart","ElementPart","_ElementPart"],"mappings":";;;;;SAgCaA,EAAO,CAClBC,qBAAsBC,EAAEC,EACxBC,OAAQF,EAAEG,EACVC,YAAaJ,EAAEK,EACfC,YAAaN,EAAEO,EACfC,gBAAiBR,EAAES,EACnBC,yBAA0B,CACxBC,EACAC,IAEA,cAAcD,EACHE,KAEPC,EACAC,GAEA,OAAOH,EAAkBI,KAAMD,KAGrCE,kBAAkBC,EAAwBP,GAExCO,EAAuB,gBAAIP,GAE7BQ,+BAAgC,CAC9BC,EACAF,EACAG,KAIA,IAAIC,EAA0BC,EAM9B,OAFAH,EAAKI,EAAgBN,GAAoBI,EAAiBJ,EAC1DE,EAAKK,KAAWP,EAAOE,EAAMC,GACtBC,GAETI,wBAA0BC,QACrBA,EACHC,MAAe,IAEjBC,iBAAkB7B,EAAE8B,EACpBC,cAAe/B,EAAEgC,EACjBC,aAAcjC,EAAEkC,EAChBC,qBAAsBnC,EAAEoC,EACxBC,UAAWrC,EAAEsC,EACbC,YAAavC,EAAEwC"}
\ No newline at end of file
+{"version":3,"file":"private-ssr-support.js","sources":["src/private-ssr-support.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2019 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {\n  Directive,\n  PartInfo,\n  DirectiveClass,\n  DirectiveResult,\n} from './directive.js';\nimport {\n  _$LH as p,\n  AttributePart,\n  noChange,\n  Part,\n  Disconnectable,\n} from './lit-html.js';\nexport type {Template} from './lit-html.js';\n\n/**\n * END USERS SHOULD NOT RELY ON THIS OBJECT.\n *\n * We currently do not make a mangled rollup build of the lit-ssr code. In order\n * to keep a number of (otherwise private) top-level exports mangled in the\n * client side code, we export a _$LH object containing those members (or\n * helper methods for accessing private fields of those members), and then\n * re-export them for use in lit-ssr. This keeps lit-ssr agnostic to whether the\n * client-side code is being used in `dev` mode or `prod` mode.\n * @private\n */\nexport const _$LH = {\n  boundAttributeSuffix: p._boundAttributeSuffix,\n  marker: p._marker,\n  markerMatch: p._markerMatch,\n  HTML_RESULT: p._HTML_RESULT,\n  getTemplateHtml: p._getTemplateHtml,\n  overrideDirectiveResolve: (\n    directiveClass: new (part: PartInfo) => Directive & {render(): unknown},\n    resolveOverrideFn: (directive: Directive, values: unknown[]) => unknown\n  ) =>\n    class extends directiveClass {\n      override _$resolve(\n        this: Directive,\n        _part: Part,\n        values: unknown[]\n      ): unknown {\n        return resolveOverrideFn(this, values);\n      }\n    },\n  setDirectiveClass(value: DirectiveResult, directiveClass: DirectiveClass) {\n    // This property needs to remain unminified.\n    value['_$litDirective$'] = directiveClass;\n  },\n  getAttributePartCommittedValue: (\n    part: AttributePart,\n    value: unknown,\n    index: number | undefined\n  ) => {\n    // Use the part setter to resolve directives/concatenate multiple parts\n    // into a final value (captured by passing in a commitValue override)\n    let committedValue: unknown = noChange;\n    // Note that _commitValue need not be in `stableProperties` because this\n    // method is only run on `AttributePart`s created by lit-ssr using the same\n    // version of the library as this file\n    part._commitValue = (value: unknown) => (committedValue = value);\n    part._$setValue(value, part, index);\n    return committedValue;\n  },\n  connectedDisconnectable: (props?: object): Disconnectable => ({\n    ...props,\n    _$isConnected: true,\n  }),\n  resolveDirective: p._resolveDirective,\n  AttributePart: p._AttributePart,\n  PropertyPart: p._PropertyPart,\n  BooleanAttributePart: p._BooleanAttributePart,\n  EventPart: p._EventPart,\n  ElementPart: p._ElementPart,\n};\n"],"names":["_$LH","boundAttributeSuffix","p","_boundAttributeSuffix","marker","_marker","markerMatch","_markerMatch","HTML_RESULT","_HTML_RESULT","getTemplateHtml","_getTemplateHtml","overrideDirectiveResolve","directiveClass","resolveOverrideFn","_$resolve","_part","values","this","setDirectiveClass","value","getAttributePartCommittedValue","part","index","committedValue","noChange","_commitValue","_$setValue","connectedDisconnectable","props","_$isConnected","resolveDirective","_resolveDirective","AttributePart","_AttributePart","PropertyPart","_PropertyPart","BooleanAttributePart","_BooleanAttributePart","EventPart","_EventPart","ElementPart","_ElementPart"],"mappings":";;;;;GAgCa,MAAAA,EAAO,CAClBC,qBAAsBC,EAAEC,EACxBC,OAAQF,EAAEG,EACVC,YAAaJ,EAAEK,EACfC,YAAaN,EAAEO,EACfC,gBAAiBR,EAAES,EACnBC,yBAA0B,CACxBC,EACAC,IAEA,cAAcD,EACHE,KAEPC,EACAC,GAEA,OAAOH,EAAkBI,KAAMD,EAChC,GAELE,kBAAkBC,EAAwBP,GAExCO,EAAuB,gBAAIP,CAC5B,EACDQ,+BAAgC,CAC9BC,EACAF,EACAG,KAIA,IAAIC,EAA0BC,EAM9B,OAFAH,EAAKI,EAAgBN,GAAoBI,EAAiBJ,EAC1DE,EAAKK,KAAWP,EAAOE,EAAMC,GACtBC,CAAc,EAEvBI,wBAA0BC,IAAoC,IACzDA,EACHC,MAAe,IAEjBC,iBAAkB7B,EAAE8B,EACpBC,cAAe/B,EAAEgC,EACjBC,aAAcjC,EAAEkC,EAChBC,qBAAsBnC,EAAEoC,EACxBC,UAAWrC,EAAEsC,EACbC,YAAavC,EAAEwC"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/static.d.ts b/front_end/third_party/lit-html/package/static.d.ts
index ab33a1c151956f0b4d5045ba0eb6cb020e73a50e..6987051bf977b736fbd7f5f99e8e4625e01f2e2b 100644
--- a/front_end/third_party/lit-html/package/static.d.ts
+++ b/front_end/third_party/lit-html/package/static.d.ts
@@ -4,6 +4,32 @@  * Copyright 2020 Google LLC
  * SPDX-License-Identifier: BSD-3-Clause
  */
 import { html as coreHtml, svg as coreSvg, TemplateResult } from './lit-html.js';
+export interface StaticValue {
+    /** The value to interpolate as-is into the template. */
+    _$litStatic$: string;
+    /**
+     * A value that can't be decoded from ordinary JSON, make it harder for
+     * a attacker-controlled data that goes through JSON.parse to produce a valid
+     * StaticValue.
+     */
+    r: typeof brand;
+}
+/**
+ * Prevents JSON injection attacks.
+ *
+ * The goals of this brand:
+ *   1) fast to check
+ *   2) code is small on the wire
+ *   3) multiple versions of Lit in a single page will all produce mutually
+ *      interoperable StaticValues
+ *   4) normal JSON.parse (without an unusual reviver) can not produce a
+ *      StaticValue
+ *
+ * Symbols satisfy (1), (2), and (4). We use Symbol.for to satisfy (3), but
+ * we don't care about the key, so we break ties via (2) and use the empty
+ * string.
+ */
+declare const brand: unique symbol;
 /**
  * Wraps a string so that it behaves like part of the static template
  * strings instead of a dynamic value.
@@ -18,10 +44,8 @@  *
  * Static values can be changed, but they will cause a complete re-render
  * since they effectively create a new template.
  */
-export declare const unsafeStatic: (value: string) => {
-/**
+ */
  * strings instead of a dynamic value.
-};
 /**
  * Tags a string literal so that it behaves like part of the static template
  * strings instead of a dynamic value.
@@ -36,9 +60,7 @@  *
  * Static values can be changed, but they will cause a complete re-render since
  * they effectively create a new template.
  */
-export declare const literal: (strings: TemplateStringsArray, ...values: unknown[]) => {
-    _$litStatic$: unknown;
-/**
+ */
  *
 /**
  * Wraps a lit-html template tag (`html` or `svg`) to add static value support.
@@ -58,4 +80,5 @@  *
  * Includes static value support from `lit-html/static.js`.
  */
 export declare const svg: (strings: TemplateStringsArray, ...values: unknown[]) => TemplateResult;
+export {};
 //# sourceMappingURL=static.d.ts.map
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/static.d.ts.map b/front_end/third_party/lit-html/package/static.d.ts.map
index 2208152802c19f26f1791ebeb5238ace1b9d7a9c..6fd5b7f937e80ed6b09388df3a66eeeff5a36d52 100644
--- a/front_end/third_party/lit-html/package/static.d.ts.map
+++ b/front_end/third_party/lit-html/package/static.d.ts.map
@@ -1 +1 @@
-{"version":3,"file":"static.d.ts","sourceRoot":"","sources":["../src/static.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAKH,OAAO,EAAC,IAAI,IAAI,QAAQ,EAAE,GAAG,IAAI,OAAO,EAAE,cAAc,EAAC,MAAM,eAAe,CAAC;AAE/E;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,YAAY,UAAW,MAAM;;CAExC,CAAC;AAaH;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,OAAO,YACT,oBAAoB,aAClB,OAAO,EAAE;;CAMpB,CAAC;AAMH;;GAEG;AACH,eAAO,MAAM,UAAU,YACX,eAAe,GAAG,cAAc,eAChC,oBAAoB,aAAa,OAAO,EAAE,KAAG,cAmDtD,CAAC;AAEJ;;;;;GAKG;AACH,eAAO,MAAM,IAAI,YA3DL,oBAAoB,aAAa,OAAO,EAAE,KAAG,cA2DjB,CAAC;AAEzC;;;;;GAKG;AACH,eAAO,MAAM,GAAG,YAnEJ,oBAAoB,aAAa,OAAO,EAAE,KAAG,cAmEnB,CAAC"}
\ No newline at end of file
+{"version":3,"file":"static.d.ts","sourceRoot":"","sources":["../src/static.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAKH,OAAO,EAAC,IAAI,IAAI,QAAQ,EAAE,GAAG,IAAI,OAAO,EAAE,cAAc,EAAC,MAAM,eAAe,CAAC;AAE/E,MAAM,WAAW,WAAW;IAC1B,wDAAwD;IACxD,YAAY,EAAE,MAAM,CAAC;IAErB;;;;OAIG;IACH,CAAC,EAAE,OAAO,KAAK,CAAC;CACjB;AAED;;;;;;;;;;;;;;GAcG;AACH,QAAA,MAAM,KAAK,eAAiB,CAAC;AAU7B;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,YAAY,UAAW,MAAM,KAAG,WAG3C,CAAC;AAaH;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,OAAO,YACT,oBAAoB,aAClB,OAAO,EAAE,KACnB,WAMD,CAAC;AAIH;;GAEG;AACH,eAAO,MAAM,UAAU,YACX,eAAe,GAAG,cAAc,eAChC,oBAAoB,aAAa,OAAO,EAAE,KAAG,cAkDtD,CAAC;AAEJ;;;;;GAKG;AACH,eAAO,MAAM,IAAI,YA1DL,oBAAoB,aAAa,OAAO,EAAE,KAAG,cA0DjB,CAAC;AAEzC;;;;;GAKG;AACH,eAAO,MAAM,GAAG,YAlEJ,oBAAoB,aAAa,OAAO,EAAE,KAAG,cAkEnB,CAAC"}
\ No newline at end of file




diff --git a/front_end/third_party/lit-html/package/static.js b/front_end/third_party/lit-html/package/static.js
index f82a6598c61565ee79d8bf557d14158942191851..99e662ec6390d69efa8a2bae137e952b10e5aefd 100644
--- a/front_end/third_party/lit-html/package/static.js
+++ b/front_end/third_party/lit-html/package/static.js
@@ -1,7 +1,7 @@
-import{html as t,svg as e}from"./lit-html.js";
+import{html as t,svg as r}from"./lit-html.js";
 /**
  * @license
  * Copyright 2020 Google LLC
  * SPDX-License-Identifier: BSD-3-Clause
- */const o=t=>({_$litStatic$:t}),r=(t,...e)=>({_$litStatic$:e.reduce(((e,o,r)=>e+(t=>{if(void 0!==t._$litStatic$)return t._$litStatic$;throw Error(`Value passed to 'literal' function must be a 'literal' result: ${t}. Use 'unsafeStatic' to pass non-literal values, but\n            take care to ensure page security.`)})(o)+t[r+1]),t[0])}),i=new Map,a=t=>(e,...o)=>{var r;const a=o.length;let l,s;const n=[],u=[];let c,$=0,v=!1;for(;$<a;){for(c=e[$];$<a&&void 0!==(s=o[$],l=null===(r=s)||void 0===r?void 0:r._$litStatic$);)c+=l+e[++$],v=!0;u.push(s),n.push(c),$++}if($===a&&n.push(e[a]),v){const t=n.join("$$lit$$");void 0===(e=i.get(t))&&(n.raw=n,i.set(t,e=n)),o=u}return t(e,...o)},l=a(t),s=a(e);export{l as html,r as literal,s as svg,o as unsafeStatic,a as withStatic};
+ */const e=Symbol.for(""),l=t=>{if((null==t?void 0:t.r)===e)return null==t?void 0:t._$litStatic$},o=t=>({_$litStatic$:t,r:e}),i=(t,...r)=>({_$litStatic$:r.reduce(((r,e,l)=>r+(t=>{if(void 0!==t._$litStatic$)return t._$litStatic$;throw Error(`Value passed to 'literal' function must be a 'literal' result: ${t}. Use 'unsafeStatic' to pass non-literal values, but\n            take care to ensure page security.`)})(e)+t[l+1]),t[0]),r:e}),s=new Map,a=t=>(r,...e)=>{const o=e.length;let i,a;const n=[],u=[];let c,$=0,f=!1;for(;$<o;){for(c=r[$];$<o&&void 0!==(a=e[$],i=l(a));)c+=i+r[++$],f=!0;u.push(a),n.push(c),$++}if($===o&&n.push(r[o]),f){const t=n.join("$$lit$$");void 0===(r=s.get(t))&&(n.raw=n,s.set(t,r=n)),e=u}return t(r,...e)},n=a(t),u=a(r);export{n as html,i as literal,u as svg,o as unsafeStatic,a as withStatic};
 //# sourceMappingURL=static.js.map




diff --git a/front_end/third_party/lit-html/package/static.js.map b/front_end/third_party/lit-html/package/static.js.map
index 1335d2711163f6d76d289e4957692baef7471066..b8cf7c7a05b7d8ae17cb0a575d5cd2ab8dc426fc 100644
--- a/front_end/third_party/lit-html/package/static.js.map
+++ b/front_end/third_party/lit-html/package/static.js.map
@@ -1 +1 @@
-{"version":3,"file":"static.js","sources":["src/static.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2020 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n// Any new exports need to be added to the export statement in\n// `packages/lit/src/index.all.ts`.\n\nimport {html as coreHtml, svg as coreSvg, TemplateResult} from './lit-html.js';\n\n/**\n * Wraps a string so that it behaves like part of the static template\n * strings instead of a dynamic value.\n *\n * Users must take care to ensure that adding the static string to the template\n * results in well-formed HTML, or else templates may break unexpectedly.\n *\n * Note that this function is unsafe to use on untrusted content, as it will be\n * directly parsed into HTML. Do not pass user input to this function\n * without sanitizing it.\n *\n * Static values can be changed, but they will cause a complete re-render\n * since they effectively create a new template.\n */\nexport const unsafeStatic = (value: string) => ({\n  ['_$litStatic$']: value,\n});\n\nconst textFromStatic = (value: StaticValue) => {\n  if (value['_$litStatic$'] !== undefined) {\n    return value['_$litStatic$'];\n  } else {\n    throw new Error(\n      `Value passed to 'literal' function must be a 'literal' result: ${value}. Use 'unsafeStatic' to pass non-literal values, but\n            take care to ensure page security.`\n    );\n  }\n};\n\n/**\n * Tags a string literal so that it behaves like part of the static template\n * strings instead of a dynamic value.\n *\n * The only values that may be used in template expressions are other tagged\n * `literal` results or `unsafeStatic` values (note that untrusted content\n * should never be passed to `unsafeStatic`).\n *\n * Users must take care to ensure that adding the static string to the template\n * results in well-formed HTML, or else templates may break unexpectedly.\n *\n * Static values can be changed, but they will cause a complete re-render since\n * they effectively create a new template.\n */\nexport const literal = (\n  strings: TemplateStringsArray,\n  ...values: unknown[]\n) => ({\n  ['_$litStatic$']: values.reduce(\n    (acc, v, idx) => acc + textFromStatic(v as StaticValue) + strings[idx + 1],\n    strings[0]\n  ),\n});\n\ntype StaticValue = ReturnType<typeof unsafeStatic>;\n\nconst stringsCache = new Map<string, TemplateStringsArray>();\n\n/**\n * Wraps a lit-html template tag (`html` or `svg`) to add static value support.\n */\nexport const withStatic =\n  (coreTag: typeof coreHtml | typeof coreSvg) =>\n  (strings: TemplateStringsArray, ...values: unknown[]): TemplateResult => {\n    const l = values.length;\n    let staticValue: string | undefined;\n    let dynamicValue: unknown;\n    const staticStrings: Array<string> = [];\n    const dynamicValues: Array<unknown> = [];\n    let i = 0;\n    let hasStatics = false;\n    let s: string;\n\n    while (i < l) {\n      s = strings[i];\n      // Collect any unsafeStatic values, and their following template strings\n      // so that we treat a run of template strings and unsafe static values as\n      // a single template string.\n      while (\n        i < l &&\n        ((dynamicValue = values[i]),\n        (staticValue = (dynamicValue as StaticValue)?.['_$litStatic$'])) !==\n          undefined\n      ) {\n        s += staticValue + strings[++i];\n        hasStatics = true;\n      }\n      dynamicValues.push(dynamicValue);\n      staticStrings.push(s);\n      i++;\n    }\n    // If the last value isn't static (which would have consumed the last\n    // string), then we need to add the last string.\n    if (i === l) {\n      staticStrings.push(strings[l]);\n    }\n\n    if (hasStatics) {\n      const key = staticStrings.join('$$lit$$');\n      strings = stringsCache.get(key)!;\n      if (strings === undefined) {\n        // Beware: in general this pattern is unsafe, and doing so may bypass\n        // lit's security checks and allow an attacker to execute arbitrary\n        // code and inject arbitrary content.\n        // eslint-disable-next-line @typescript-eslint/no-explicit-any\n        (staticStrings as any).raw = staticStrings;\n        stringsCache.set(\n          key,\n          (strings = staticStrings as unknown as TemplateStringsArray)\n        );\n      }\n      values = dynamicValues;\n    }\n    return coreTag(strings, ...values);\n  };\n\n/**\n * Interprets a template literal as an HTML template that can efficiently\n * render to and update a container.\n *\n * Includes static value support from `lit-html/static.js`.\n */\nexport const html = withStatic(coreHtml);\n\n/**\n * Interprets a template literal as an SVG template that can efficiently\n * render to and update a container.\n *\n * Includes static value support from `lit-html/static.js`.\n */\nexport const svg = withStatic(coreSvg);\n"],"names":["unsafeStatic","value","_$litStatic$","literal","strings","values","reduce","acc","v","idx","undefined","Error","textFromStatic","stringsCache","Map","withStatic","coreTag","l","length","staticValue","dynamicValue","staticStrings","dynamicValues","s","i","hasStatics","push","key","join","get","raw","set","html","coreHtml","svg","coreSvg"],"mappings":";;;;;SAyBaA,EAAgBC,KAC3BC,aAAkBD,IA4BPE,EAAU,CACrBC,KACGC,MAEHH,aAAkBG,EAAOC,QACvB,CAACC,EAAKC,EAAGC,IAAQF,EA9BE,CAACN,IACtB,QAA8BS,IAA1BT,EAAoB,aACtB,OAAOA,EAAoB,aAE3B,MAAUU,MACR,kEAAkEV,0GAyB7CW,CAAeJ,GAAoBJ,EAAQK,EAAM,IACxEL,EAAQ,MAMNS,EAAe,IAAIC,IAKZC,EACVC,GACD,CAACZ,KAAkCC,WACjC,MAAMY,EAAIZ,EAAOa,OACjB,IAAIC,EACAC,EACJ,MAAMC,EAA+B,GAC/BC,EAAgC,GACtC,IAEIC,EAFAC,EAAI,EACJC,GAAa,EAGjB,KAAOD,EAAIP,GAAG,CAKZ,IAJAM,EAAInB,EAAQoB,GAKVA,EAAIP,QAGFP,KAFAU,EAAef,EAAOmB,GACvBL,YAAeC,wBAA6C,eAG7DG,GAAKJ,EAAcf,IAAUoB,GAC7BC,GAAa,EAEfH,EAAcI,KAAKN,GACnBC,EAAcK,KAAKH,GACnBC,IAQF,GAJIA,IAAMP,GACRI,EAAcK,KAAKtB,EAAQa,IAGzBQ,EAAY,CACd,MAAME,EAAMN,EAAcO,KAAK,gBAEflB,KADhBN,EAAUS,EAAagB,IAAIF,MAMxBN,EAAsBS,IAAMT,EAC7BR,EAAakB,IACXJ,EACCvB,EAAUiB,IAGfhB,EAASiB,EAEX,OAAON,EAAQZ,KAAYC,IASlB2B,EAAOjB,EAAWkB,GAQlBC,EAAMnB,EAAWoB"}
\ No newline at end of file
+{"version":3,"file":"static.js","sources":["src/static.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2020 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n// Any new exports need to be added to the export statement in\n// `packages/lit/src/index.all.ts`.\n\nimport {html as coreHtml, svg as coreSvg, TemplateResult} from './lit-html.js';\n\nexport interface StaticValue {\n  /** The value to interpolate as-is into the template. */\n  _$litStatic$: string;\n\n  /**\n   * A value that can't be decoded from ordinary JSON, make it harder for\n   * a attacker-controlled data that goes through JSON.parse to produce a valid\n   * StaticValue.\n   */\n  r: typeof brand;\n}\n\n/**\n * Prevents JSON injection attacks.\n *\n * The goals of this brand:\n *   1) fast to check\n *   2) code is small on the wire\n *   3) multiple versions of Lit in a single page will all produce mutually\n *      interoperable StaticValues\n *   4) normal JSON.parse (without an unusual reviver) can not produce a\n *      StaticValue\n *\n * Symbols satisfy (1), (2), and (4). We use Symbol.for to satisfy (3), but\n * we don't care about the key, so we break ties via (2) and use the empty\n * string.\n */\nconst brand = Symbol.for('');\n\n/** Safely extracts the string part of a StaticValue. */\nconst unwrapStaticValue = (value: unknown): string | undefined => {\n  if ((value as Partial<StaticValue>)?.r !== brand) {\n    return undefined;\n  }\n  return (value as Partial<StaticValue>)?.['_$litStatic$'];\n};\n\n/**\n * Wraps a string so that it behaves like part of the static template\n * strings instead of a dynamic value.\n *\n * Users must take care to ensure that adding the static string to the template\n * results in well-formed HTML, or else templates may break unexpectedly.\n *\n * Note that this function is unsafe to use on untrusted content, as it will be\n * directly parsed into HTML. Do not pass user input to this function\n * without sanitizing it.\n *\n * Static values can be changed, but they will cause a complete re-render\n * since they effectively create a new template.\n */\nexport const unsafeStatic = (value: string): StaticValue => ({\n  ['_$litStatic$']: value,\n  r: brand,\n});\n\nconst textFromStatic = (value: StaticValue) => {\n  if (value['_$litStatic$'] !== undefined) {\n    return value['_$litStatic$'];\n  } else {\n    throw new Error(\n      `Value passed to 'literal' function must be a 'literal' result: ${value}. Use 'unsafeStatic' to pass non-literal values, but\n            take care to ensure page security.`\n    );\n  }\n};\n\n/**\n * Tags a string literal so that it behaves like part of the static template\n * strings instead of a dynamic value.\n *\n * The only values that may be used in template expressions are other tagged\n * `literal` results or `unsafeStatic` values (note that untrusted content\n * should never be passed to `unsafeStatic`).\n *\n * Users must take care to ensure that adding the static string to the template\n * results in well-formed HTML, or else templates may break unexpectedly.\n *\n * Static values can be changed, but they will cause a complete re-render since\n * they effectively create a new template.\n */\nexport const literal = (\n  strings: TemplateStringsArray,\n  ...values: unknown[]\n): StaticValue => ({\n  ['_$litStatic$']: values.reduce(\n    (acc, v, idx) => acc + textFromStatic(v as StaticValue) + strings[idx + 1],\n    strings[0]\n  ) as string,\n  r: brand,\n});\n\nconst stringsCache = new Map<string, TemplateStringsArray>();\n\n/**\n * Wraps a lit-html template tag (`html` or `svg`) to add static value support.\n */\nexport const withStatic =\n  (coreTag: typeof coreHtml | typeof coreSvg) =>\n  (strings: TemplateStringsArray, ...values: unknown[]): TemplateResult => {\n    const l = values.length;\n    let staticValue: string | undefined;\n    let dynamicValue: unknown;\n    const staticStrings: Array<string> = [];\n    const dynamicValues: Array<unknown> = [];\n    let i = 0;\n    let hasStatics = false;\n    let s: string;\n\n    while (i < l) {\n      s = strings[i];\n      // Collect any unsafeStatic values, and their following template strings\n      // so that we treat a run of template strings and unsafe static values as\n      // a single template string.\n      while (\n        i < l &&\n        ((dynamicValue = values[i]),\n        (staticValue = unwrapStaticValue(dynamicValue))) !== undefined\n      ) {\n        s += staticValue + strings[++i];\n        hasStatics = true;\n      }\n      dynamicValues.push(dynamicValue);\n      staticStrings.push(s);\n      i++;\n    }\n    // If the last value isn't static (which would have consumed the last\n    // string), then we need to add the last string.\n    if (i === l) {\n      staticStrings.push(strings[l]);\n    }\n\n    if (hasStatics) {\n      const key = staticStrings.join('$$lit$$');\n      strings = stringsCache.get(key)!;\n      if (strings === undefined) {\n        // Beware: in general this pattern is unsafe, and doing so may bypass\n        // lit's security checks and allow an attacker to execute arbitrary\n        // code and inject arbitrary content.\n        // eslint-disable-next-line @typescript-eslint/no-explicit-any\n        (staticStrings as any).raw = staticStrings;\n        stringsCache.set(\n          key,\n          (strings = staticStrings as unknown as TemplateStringsArray)\n        );\n      }\n      values = dynamicValues;\n    }\n    return coreTag(strings, ...values);\n  };\n\n/**\n * Interprets a template literal as an HTML template that can efficiently\n * render to and update a container.\n *\n * Includes static value support from `lit-html/static.js`.\n */\nexport const html = withStatic(coreHtml);\n\n/**\n * Interprets a template literal as an SVG template that can efficiently\n * render to and update a container.\n *\n * Includes static value support from `lit-html/static.js`.\n */\nexport const svg = withStatic(coreSvg);\n"],"names":["brand","Symbol","for","unwrapStaticValue","value","r","unsafeStatic","_$litStatic$","literal","strings","values","reduce","acc","v","idx","undefined","Error","textFromStatic","stringsCache","Map","withStatic","coreTag","l","length","staticValue","dynamicValue","staticStrings","dynamicValues","s","i","hasStatics","push","key","join","get","raw","set","html","coreHtml","svg","coreSvg"],"mappings":";;;;;GAsCA,MAAMA,EAAQC,OAAOC,IAAI,IAGnBC,EAAqBC,IACzB,IAAKA,aAAK,EAALA,EAAgCC,KAAML,EAG3C,OAAQI,aAAK,EAALA,EAA+C,YAAC,EAiB7CE,EAAgBF,IAAgC,CAC3DG,aAAkBH,EAClBC,EAAGL,IA4BQQ,EAAU,CACrBC,KACGC,KACc,CACjBH,aAAkBG,EAAOC,QACvB,CAACC,EAAKC,EAAGC,IAAQF,EA9BE,CAACR,IACtB,QAA8BW,IAA1BX,EAAoB,aACtB,OAAOA,EAAoB,aAE3B,MAAUY,MACR,kEAAkEZ,wGAGrE,EAsBwBa,CAAeJ,GAAoBJ,EAAQK,EAAM,IACxEL,EAAQ,IAEVJ,EAAGL,IAGCkB,EAAe,IAAIC,IAKZC,EACVC,GACD,CAACZ,KAAkCC,KACjC,MAAMY,EAAIZ,EAAOa,OACjB,IAAIC,EACAC,EACJ,MAAMC,EAA+B,GAC/BC,EAAgC,GACtC,IAEIC,EAFAC,EAAI,EACJC,GAAa,EAGjB,KAAOD,EAAIP,GAAG,CAKZ,IAJAM,EAAInB,EAAQoB,GAKVA,EAAIP,QAEiDP,KADnDU,EAAef,EAAOmB,GACvBL,EAAcrB,EAAkBsB,KAEjCG,GAAKJ,EAAcf,IAAUoB,GAC7BC,GAAa,EAEfH,EAAcI,KAAKN,GACnBC,EAAcK,KAAKH,GACnBC,GACD,CAOD,GAJIA,IAAMP,GACRI,EAAcK,KAAKtB,EAAQa,IAGzBQ,EAAY,CACd,MAAME,EAAMN,EAAcO,KAAK,gBAEflB,KADhBN,EAAUS,EAAagB,IAAIF,MAMxBN,EAAsBS,IAAMT,EAC7BR,EAAakB,IACXJ,EACCvB,EAAUiB,IAGfhB,EAASiB,CACV,CACD,OAAON,EAAQZ,KAAYC,EAAO,EASzB2B,EAAOjB,EAAWkB,GAQlBC,EAAMnB,EAAWoB"}
\ No newline at end of file