respec 34.1.4 → 34.1.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
- window.respecVersion="34.1.4",function(){"use strict";const e=!!window.require;if(!e){const e=function(e,t){const n=e.map((e=>{if(!(e in window.require.modules))throw new Error(`Unsupported dependency name: ${e}`);return window.require.modules[e]}));Promise.all(n).then((e=>t(...e)))};e.modules={},window.require=e}function t(t,n){e||(window.require.modules[t]=n)}const n=new EventTarget;function r(e,t){if(n.dispatchEvent(new CustomEvent(e,{detail:t})),window.parent===window.self)return;const r=String(JSON.stringify(t?.stack||t));window.parent.postMessage({topic:e,args:r},window.parent.location.origin)}function s(e,t,r={once:!1}){n.addEventListener(e,(e=>t(e.detail)),r)}t("core/pubsubhub",{sub:s});const i=["githubToken","githubUser"];const o=document.documentElement;o&&!o.hasAttribute("lang")&&(o.lang="en",o.hasAttribute("dir")||(o.dir="ltr"));const a={},c=o.lang;var l=Object.freeze({__proto__:null,l10n:a,lang:c,name:"core/l10n",run:function(e){e.l10n=a[c]||a.en}});let u,d;const p=new WeakMap,f=new WeakMap,h=new WeakMap,m=new WeakMap,g=new WeakMap;let b={get(e,t,n){if(e instanceof IDBTransaction){if("done"===t)return f.get(e);if("objectStoreNames"===t)return e.objectStoreNames||h.get(e);if("store"===t)return n.objectStoreNames[1]?void 0:n.objectStore(n.objectStoreNames[0])}return v(e[t])},set:(e,t,n)=>(e[t]=n,!0),has:(e,t)=>e instanceof IDBTransaction&&("done"===t||"store"===t)||t in e};function y(e){return e!==IDBDatabase.prototype.transaction||"objectStoreNames"in IDBTransaction.prototype?(d||(d=[IDBCursor.prototype.advance,IDBCursor.prototype.continue,IDBCursor.prototype.continuePrimaryKey])).includes(e)?function(...t){return e.apply($(this),t),v(p.get(this))}:function(...t){return v(e.apply($(this),t))}:function(t,...n){const r=e.call($(this),t,...n);return h.set(r,t.sort?t.sort():[t]),v(r)}}function w(e){return"function"==typeof e?y(e):(e instanceof IDBTransaction&&function(e){if(f.has(e))return;const t=new Promise(((t,n)=>{const r=()=>{e.removeEventListener("complete",s),e.removeEventListener("error",i),e.removeEventListener("abort",i)},s=()=>{t(),r()},i=()=>{n(e.error||new DOMException("AbortError","AbortError")),r()};e.addEventListener("complete",s),e.addEventListener("error",i),e.addEventListener("abort",i)}));f.set(e,t)}(e),t=e,(u||(u=[IDBDatabase,IDBObjectStore,IDBIndex,IDBCursor,IDBTransaction])).some((e=>t instanceof e))?new Proxy(e,b):e);var t}function v(e){if(e instanceof IDBRequest)return function(e){const t=new Promise(((t,n)=>{const r=()=>{e.removeEventListener("success",s),e.removeEventListener("error",i)},s=()=>{t(v(e.result)),r()},i=()=>{n(e.error),r()};e.addEventListener("success",s),e.addEventListener("error",i)}));return t.then((t=>{t instanceof IDBCursor&&p.set(t,e)})).catch((()=>{})),g.set(t,e),t}(e);if(m.has(e))return m.get(e);const t=w(e);return t!==e&&(m.set(e,t),g.set(t,e)),t}const $=e=>g.get(e);const k=["get","getKey","getAll","getAllKeys","count"],x=["put","add","delete","clear"],_=new Map;function C(e,t){if(!(e instanceof IDBDatabase)||t in e||"string"!=typeof t)return;if(_.get(t))return _.get(t);const n=t.replace(/FromIndex$/,""),r=t!==n,s=x.includes(n);if(!(n in(r?IDBIndex:IDBObjectStore).prototype)||!s&&!k.includes(n))return;const i=async function(e,...t){const i=this.transaction(e,s?"readwrite":"readonly");let o=i.store;return r&&(o=o.index(t.shift())),(await Promise.all([o[n](...t),s&&i.done]))[0]};return _.set(t,i),i}b=(e=>({...e,get:(t,n,r)=>C(t,n)||e.get(t,n,r),has:(t,n)=>!!C(t,n)||e.has(t,n)}))(b);var S=Object.freeze({__proto__:null,deleteDB:function(e,{blocked:t}={}){const n=indexedDB.deleteDatabase(e);return t&&n.addEventListener("blocked",(e=>t(e.oldVersion,e))),v(n).then((()=>{}))},openDB:function(e,t,{blocked:n,upgrade:r,blocking:s,terminated:i}={}){const o=indexedDB.open(e,t),a=v(o);return r&&o.addEventListener("upgradeneeded",(e=>{r(v(o.result),e.oldVersion,e.newVersion,v(o.transaction),e)})),n&&o.addEventListener("blocked",(e=>n(e.oldVersion,e.newVersion,e))),a.then((e=>{i&&e.addEventListener("close",(()=>i())),s&&e.addEventListener("versionchange",(e=>s(e.oldVersion,e.newVersion,e)))})).catch((()=>{})),a},unwrap:$,wrap:v});function R(e,t,n,r,s,{level:i="error",autofix:o,ruleName:a}={}){function c(n){return n>0?e.slice(t,t+n):e.slice(Math.max(t+n,0),t)}function l(n,{precedes:r}={}){const s=n.map((e=>e.trivia+e.value)).join(""),i=e[t];return"eof"===i.type?s:r?s+i.trivia:s.slice(i.trivia.length)}const u="eof"!==e[t].type?e[t].line:e.length>1?e[t-1].line:1,d=function(e){const t=e.split("\n");return t[t.length-1]}(l(c(-5),{precedes:!0})),p=c(5),f=l(p),h=d+f.split("\n")[0]+"\n"+(" ".repeat(d.length)+"^"),m="Syntax"===s?"since":"inside",g=`${s} error at line ${u}${e.name?` in ${e.name}`:""}${n&&n.name?`, ${m} \`${n.partial?"partial ":""}${function(e){const t=[e];for(;e&&e.parent;){const{parent:n}=e;t.unshift(n),e=n}return t.map((e=>function(e,t){let n=e;return t&&(n+=` ${t}`),n}(e.type,e.name))).join(" -> ")}(n)}\``:""}:\n${h}`;return{message:`${g} ${r}`,bareMessage:r,context:g,line:u,sourceName:e.name,level:i,ruleName:a,autofix:o,input:f,tokens:p}}function E(e,t,n,r){return R(e,t,n,r,"Syntax")}function A(e,t,n,r,s={}){return s.ruleName=n,R(t.source,e.index,t,r,"Validation",s)}class T{constructor({source:e,tokens:t}){Object.defineProperties(this,{source:{value:e},tokens:{value:t,writable:!0},parent:{value:null,writable:!0},this:{value:this}})}toJSON(){const e={type:void 0,name:void 0,inheritance:void 0};let t=this;for(;t!==Object.prototype;){const n=Object.getOwnPropertyDescriptors(t);for(const[t,r]of Object.entries(n))(r.enumerable||r.get)&&(e[t]=this[t]);t=Object.getPrototypeOf(t)}return e}}function L(e,t,{useNullableInner:n}={}){if(!e.union){const r=t.unique.get(e.idlType);if(!r)return;if("typedef"===r.type){const{typedefIncludesDictionary:n}=t.cache;if(n.has(r))return n.get(r);t.cache.typedefIncludesDictionary.set(r,void 0);const s=L(r.idlType,t);if(t.cache.typedefIncludesDictionary.set(r,s),s)return{reference:e,dictionary:s.dictionary}}if("dictionary"===r.type&&(n||!e.nullable))return{reference:e,dictionary:r}}for(const n of e.subtype){const e=L(n,t);if(e)return n.union?e:{reference:n,dictionary:e.dictionary}}}function P(e,t){if(t.cache.dictionaryIncludesRequiredField.has(e))return t.cache.dictionaryIncludesRequiredField.get(e);t.cache.dictionaryIncludesRequiredField.set(e,void 0);let n=e.members.some((e=>e.required));if(!n&&e.inheritance){const r=t.unique.get(e.inheritance);r?P(r,t)&&(n=!0):n=!0}return t.cache.dictionaryIncludesRequiredField.set(e,n),n}class I extends Array{constructor({source:e,tokens:t}){super(),Object.defineProperties(this,{source:{value:e},tokens:{value:t},parent:{value:null,writable:!0}})}}class D extends T{static parser(e,t){return()=>{const n=e.consumeKind(t);if(n)return new D({source:e.source,tokens:{value:n}})}}get value(){return J(this.tokens.value.value)}write(e){return e.ts.wrap([e.token(this.tokens.value),e.token(this.tokens.separator)])}}class N extends D{static parse(e){const t=e.consumeKind("eof");if(t)return new N({source:e.source,tokens:{value:t}})}get type(){return"eof"}}function O(e,t){return X(e,{parser:D.parser(e,t),listName:t+" list"})}const j=["identifier","decimal","integer","string"],M=new Map([...["NoInterfaceObject","LenientSetter","LenientThis","TreatNonObjectAsNull","Unforgeable"].map((e=>[e,`Legacy${e}`])),["NamedConstructor","LegacyFactoryFunction"],["OverrideBuiltins","LegacyOverrideBuiltIns"],["TreatNullAs","LegacyNullToEmptyString"]]);function z(e){for(const t of j){const n=O(e,t);if(n.length)return n}e.error("Expected identifiers, strings, decimals, or integers but none found")}class U extends T{static parse(e){const t={assign:e.consume("=")},n=le(new U({source:e.source,tokens:t}));if(n.list=[],t.assign){if(t.asterisk=e.consume("*"),t.asterisk)return n.this;t.secondaryName=e.consumeKind(...j)}return t.open=e.consume("("),t.open?(n.list=n.rhsIsList?z(e):ne(e),t.close=e.consume(")")||e.error("Unexpected token in extended attribute argument list")):t.assign&&!t.secondaryName&&e.error("No right hand side to extended attribute assignment"),n.this}get rhsIsList(){return this.tokens.assign&&!this.tokens.asterisk&&!this.tokens.secondaryName}get rhsType(){return this.rhsIsList?this.list[0].tokens.value.type+"-list":this.tokens.asterisk?"*":this.tokens.secondaryName?this.tokens.secondaryName.type:null}write(e){const{rhsType:t}=this;return e.ts.wrap([e.token(this.tokens.assign),e.token(this.tokens.asterisk),e.reference_token(this.tokens.secondaryName,this.parent),e.token(this.tokens.open),...this.list.map((n=>"identifier-list"===t?e.identifier(n,this.parent):n.write(e))),e.token(this.tokens.close)])}}class q extends T{static parse(e){const t=e.consumeKind("identifier");if(t)return new q({source:e.source,tokens:{name:t},params:U.parse(e)})}constructor({source:e,tokens:t,params:n}){super({source:e,tokens:t}),n.parent=this,Object.defineProperty(this,"params",{value:n})}get type(){return"extended-attribute"}get name(){return this.tokens.name.value}get rhs(){const{rhsType:e,tokens:t,list:n}=this.params;if(!e)return null;return{type:e,value:this.params.rhsIsList?n:this.params.tokens.secondaryName?J(t.secondaryName.value):null}}get arguments(){const{rhsIsList:e,list:t}=this.params;return!t||e?[]:t}*validate(e){const{name:t}=this;if("LegacyNoInterfaceObject"===t){const e="`[LegacyNoInterfaceObject]` extended attribute is an undesirable feature that may be removed from Web IDL in the future. Refer to the [relevant upstream PR](https://github.com/whatwg/webidl/pull/609) for more information.";yield A(this.tokens.name,this,"no-nointerfaceobject",e,{level:"warning"})}else if(M.has(t)){const e=`\`[${t}]\` extended attribute is a legacy feature that is now renamed to \`[${M.get(t)}]\`. Refer to the [relevant upstream PR](https://github.com/whatwg/webidl/pull/870) for more information.`;yield A(this.tokens.name,this,"renamed-legacy",e,{level:"warning",autofix:(n=this,()=>{const{name:e}=n;n.tokens.name.value=M.get(e),"TreatNullAs"===e&&(n.params.tokens={})})})}var n;for(const t of this.arguments)yield*t.validate(e)}write(e){return e.ts.wrap([e.ts.trivia(this.tokens.name.trivia),e.ts.extendedAttribute(e.ts.wrap([e.ts.extendedAttributeReference(this.name),this.params.write(e)])),e.token(this.tokens.separator)])}}class W extends I{static parse(e){const t={};t.open=e.consume("[");const n=new W({source:e.source,tokens:t});return t.open?(n.push(...X(e,{parser:q.parse,listName:"extended attribute"})),t.close=e.consume("]")||e.error("Expected a closing token for the extended attribute list"),n.length||(e.unconsume(t.close.index),e.error("An extended attribute list must not be empty")),e.probe("[")&&e.error("Illegal double extended attribute lists, consider merging them"),n):n}*validate(e){for(const t of this)yield*t.validate(e)}write(e){return this.length?e.ts.wrap([e.token(this.tokens.open),...this.map((t=>t.write(e))),e.token(this.tokens.close)]):""}}function F(e,t){const n=e.consume("?");n&&(t.tokens.nullable=n),e.probe("?")&&e.error("Can't nullable more than once")}function B(e,t){let n=function(e,t){const n=e.consume("FrozenArray","ObservableArray","Promise","sequence","record");if(!n)return;const r=le(new H({source:e.source,tokens:{base:n}}));switch(r.tokens.open=e.consume("<")||e.error(`No opening bracket after ${n.value}`),n.value){case"Promise":{e.probe("[")&&e.error("Promise type cannot have extended attribute");const n=se(e,t)||e.error("Missing Promise subtype");r.subtype.push(n);break}case"sequence":case"FrozenArray":case"ObservableArray":{const s=re(e,t)||e.error(`Missing ${n.value} subtype`);r.subtype.push(s);break}case"record":{e.probe("[")&&e.error("Record key cannot have extended attribute");const n=e.consume(...pe)||e.error(`Record key must be one of: ${pe.join(", ")}`),s=new H({source:e.source,tokens:{base:n}});s.tokens.separator=e.consume(",")||e.error("Missing comma after record key type"),s.type=t;const i=re(e,t)||e.error("Error parsing generic type record");r.subtype.push(s,i);break}}return r.idlType||e.error(`Error parsing generic type ${n.value}`),r.tokens.close=e.consume(">")||e.error(`Missing closing bracket after ${n.value}`),r.this}(e,t)||te(e);if(!n){const t=e.consumeKind("identifier")||e.consume(...pe,...de);if(!t)return;n=new H({source:e.source,tokens:{base:t}}),e.probe("<")&&e.error(`Unsupported generic type ${t.value}`)}return"Promise"===n.generic&&e.probe("?")&&e.error("Promise type cannot be nullable"),n.type=t||null,F(e,n),n.nullable&&"any"===n.idlType&&e.error("Type `any` cannot be made nullable"),n}class H extends T{static parse(e,t){return B(e,t)||function(e,t){const n={};if(n.open=e.consume("("),!n.open)return;const r=le(new H({source:e.source,tokens:n}));for(r.type=t||null;;){const t=re(e)||e.error("No type after open parenthesis or 'or' in union type");"any"===t.idlType&&e.error("Type `any` cannot be included in a union type"),"Promise"===t.generic&&e.error("Type `Promise` cannot be included in a union type"),r.subtype.push(t);const n=e.consume("or");if(!n)break;t.tokens.separator=n}return r.idlType.length<2&&e.error("At least two types are expected in a union type but found less"),n.close=e.consume(")")||e.error("Unterminated union type"),F(e,r),r.this}(e,t)}constructor({source:e,tokens:t}){super({source:e,tokens:t}),Object.defineProperty(this,"subtype",{value:[],writable:!0}),this.extAttrs=new W({source:e,tokens:{}})}get generic(){return this.subtype.length&&this.tokens.base?this.tokens.base.value:""}get nullable(){return Boolean(this.tokens.nullable)}get union(){return Boolean(this.subtype.length)&&!this.tokens.base}get idlType(){if(this.subtype.length)return this.subtype;return J([this.tokens.prefix,this.tokens.base,this.tokens.postfix].filter((e=>e)).map((e=>e.value)).join(" "))}*validate(e){if(yield*this.extAttrs.validate(e),"void"===this.idlType){const e="`void` is now replaced by `undefined`. Refer to the [relevant GitHub issue](https://github.com/whatwg/webidl/issues/60) for more information.";yield A(this.tokens.base,this,"replace-void",e,{autofix:(t=this,()=>{t.tokens.base.value="undefined"})})}var t;const n=!this.union&&e.unique.get(this.idlType),r=this.union?this:n&&"typedef"===n.type?n.idlType:void 0;if(r&&this.nullable){const{reference:t}=L(r,e)||{};if(t){const e=(this.union?t:this).tokens.base,n="Nullable union cannot include a dictionary type.";yield A(e,this,"no-nullable-union-dict",n)}}else for(const t of this.subtype)yield*t.validate(e)}write(e){return e.ts.wrap([this.extAttrs.write(e),(()=>{if(this.union||this.generic)return e.ts.wrap([e.token(this.tokens.base,e.ts.generic),e.token(this.tokens.open),...this.subtype.map((t=>t.write(e))),e.token(this.tokens.close)]);const t=this.tokens.prefix||this.tokens.base,n=this.tokens.prefix?[this.tokens.prefix.value,e.ts.trivia(this.tokens.base.trivia)]:[],r=e.reference(e.ts.wrap([...n,this.tokens.base.value,e.token(this.tokens.postfix)]),{unescaped:this.idlType,context:this});return e.ts.wrap([e.ts.trivia(t.trivia),r])})(),e.token(this.tokens.nullable),e.token(this.tokens.separator)])}}class G extends T{static parse(e){const t=e.consume("=");if(!t)return null;const n=Q(e)||e.consumeKind("string")||e.consume("null","[","{")||e.error("No value for default"),r=[n];if("["===n.value){const t=e.consume("]")||e.error("Default sequence value must be empty");r.push(t)}else if("{"===n.value){const t=e.consume("}")||e.error("Default dictionary value must be empty");r.push(t)}return new G({source:e.source,tokens:{assign:t},expression:r})}constructor({source:e,tokens:t,expression:n}){super({source:e,tokens:t}),n.parent=this,Object.defineProperty(this,"expression",{value:n})}get type(){return ee(this.expression[0]).type}get value(){return ee(this.expression[0]).value}get negative(){return ee(this.expression[0]).negative}write(e){return e.ts.wrap([e.token(this.tokens.assign),...this.expression.map((t=>e.token(t)))])}}class V extends T{static parse(e){const t=e.position,n={},r=le(new V({source:e.source,tokens:n}));return r.extAttrs=W.parse(e),n.optional=e.consume("optional"),r.idlType=re(e,"argument-type"),r.idlType?(n.optional||(n.variadic=e.consume("...")),n.name=e.consumeKind("identifier")||e.consume(...fe),n.name?(r.default=n.optional?G.parse(e):null,r.this):e.unconsume(t)):e.unconsume(t)}get type(){return"argument"}get optional(){return!!this.tokens.optional}get variadic(){return!!this.tokens.variadic}get name(){return J(this.tokens.name.value)}*validate(e){yield*this.extAttrs.validate(e),yield*this.idlType.validate(e);const t=L(this.idlType,e,{useNullableInner:!0});if(t)if(this.idlType.nullable){const e="Dictionary arguments cannot be nullable.";yield A(this.tokens.name,this,"no-nullable-dict-arg",e)}else if(this.optional){if(!this.default){const e="Optional dictionary arguments must have a default value of `{}`.";yield A(this.tokens.name,this,"dict-arg-default",e,{autofix:Y(this)})}}else if(this.parent&&!P(t.dictionary,e)&&function(e){const t=e.parent.arguments||e.parent.list,n=t.indexOf(e);return!t.slice(n+1).some((e=>!e.optional))}(this)){const e="Dictionary argument must be optional if it has no required fields";yield A(this.tokens.name,this,"dict-arg-optional",e,{autofix:(n=this,()=>{const e=ce(n.idlType);n.tokens.optional={...e,type:"optional",value:"optional"},e.trivia=" ",Y(n)()})})}var n}write(e){return e.ts.wrap([this.extAttrs.write(e),e.token(this.tokens.optional),e.ts.type(this.idlType.write(e)),e.token(this.tokens.variadic),e.name_token(this.tokens.name,{data:this}),this.default?this.default.write(e):"",e.token(this.tokens.separator)])}}function Y(e){return()=>{e.default=G.parse(new be(" = {}"))}}class K extends T{static parse(e,{special:t,regular:n}={}){const r={special:t},s=le(new K({source:e.source,tokens:r}));return t&&"stringifier"===t.value&&(r.termination=e.consume(";"),r.termination)?(s.arguments=[],s):(t||n||(r.special=e.consume("getter","setter","deleter")),s.idlType=se(e)||e.error("Missing return type"),r.name=e.consumeKind("identifier")||e.consume("includes"),r.open=e.consume("(")||e.error("Invalid operation"),s.arguments=ne(e),r.close=e.consume(")")||e.error("Unterminated operation"),r.termination=e.consume(";")||e.error("Unterminated operation, expected `;`"),s.this)}get type(){return"operation"}get name(){const{name:e}=this.tokens;return e?J(e.value):""}get special(){return this.tokens.special?this.tokens.special.value:""}*validate(e){if(yield*this.extAttrs.validate(e),!this.name&&["","static"].includes(this.special)){const e="Regular or static operations must have both a return type and an identifier.";yield A(this.tokens.open,this,"incomplete-op",e)}this.idlType&&(yield*this.idlType.validate(e));for(const t of this.arguments)yield*t.validate(e)}write(e){const{parent:t}=this,n=this.idlType?[e.ts.type(this.idlType.write(e)),e.name_token(this.tokens.name,{data:this,parent:t}),e.token(this.tokens.open),e.ts.wrap(this.arguments.map((t=>t.write(e)))),e.token(this.tokens.close)]:[];return e.ts.definition(e.ts.wrap([this.extAttrs.write(e),this.tokens.name?e.token(this.tokens.special):e.token(this.tokens.special,e.ts.nameless,{data:this,parent:t}),...n,e.token(this.tokens.termination)]),{data:this,parent:t})}}class Z extends T{static parse(e,{special:t,noInherit:n=!1,readonly:r=!1}={}){const s=e.position,i={special:t},o=le(new Z({source:e.source,tokens:i}));if(t||n||(i.special=e.consume("inherit")),"inherit"===o.special&&e.probe("readonly")&&e.error("Inherited attributes cannot be read-only"),i.readonly=e.consume("readonly"),r&&!i.readonly&&e.probe("attribute")&&e.error("Attributes must be readonly in this context"),i.base=e.consume("attribute"),i.base)return o.idlType=re(e,"attribute-type")||e.error("Attribute lacks a type"),i.name=e.consumeKind("identifier")||e.consume("async","required")||e.error("Attribute lacks a name"),i.termination=e.consume(";")||e.error("Unterminated attribute, expected `;`"),o.this;e.unconsume(s)}get type(){return"attribute"}get special(){return this.tokens.special?this.tokens.special.value:""}get readonly(){return!!this.tokens.readonly}get name(){return J(this.tokens.name.value)}*validate(e){if(yield*this.extAttrs.validate(e),yield*this.idlType.validate(e),["sequence","record"].includes(this.idlType.generic)){const e=`Attributes cannot accept ${this.idlType.generic} types.`;yield A(this.tokens.name,this,"attr-invalid-type",e)}{const{reference:t}=L(this.idlType,e)||{};if(t){const e=(this.idlType.union?t:this.idlType).tokens.base,n="Attributes cannot accept dictionary types.";yield A(e,this,"attr-invalid-type",n)}}if(this.readonly&&function(e,t){if(e.union)return!1;if(e.extAttrs.some((e=>"EnforceRange"===e.name)))return!0;const n=t.unique.get(e.idlType);return"typedef"===n?.type&&n.idlType.extAttrs.some((e=>"EnforceRange"===e.name))}(this.idlType,e)){const e=this.idlType.tokens.base,t="Readonly attributes cannot accept [EnforceRange] extended attribute.";yield A(e,this,"attr-invalid-type",t)}}write(e){const{parent:t}=this;return e.ts.definition(e.ts.wrap([this.extAttrs.write(e),e.token(this.tokens.special),e.token(this.tokens.readonly),e.token(this.tokens.base),e.ts.type(this.idlType.write(e)),e.name_token(this.tokens.name,{data:this,parent:t}),e.token(this.tokens.termination)]),{data:this,parent:t})}}function J(e){return e.startsWith("_")?e.slice(1):e}function X(e,{parser:t,allowDangler:n,listName:r="list"}){const s=t(e);if(!s)return[];s.tokens.separator=e.consume(",");const i=[s];for(;s.tokens.separator;){const s=t(e);if(!s){n||e.error(`Trailing comma in ${r}`);break}if(s.tokens.separator=e.consume(","),i.push(s),!s.tokens.separator)break}return i}function Q(e){return e.consumeKind("decimal","integer")||e.consume("true","false","Infinity","-Infinity","NaN")}function ee({type:e,value:t}){switch(e){case"decimal":case"integer":return{type:"number",value:t};case"string":return{type:"string",value:t.slice(1,-1)}}switch(t){case"true":case"false":return{type:"boolean",value:"true"===t};case"Infinity":case"-Infinity":return{type:"Infinity",negative:t.startsWith("-")};case"[":return{type:"sequence",value:[]};case"{":return{type:"dictionary"};default:return{type:t}}}function te(e){const{source:t}=e,n=function(){const n=e.consume("unsigned"),r=e.consume("short","long");if(r){const s=e.consume("long");return new H({source:t,tokens:{prefix:n,base:r,postfix:s}})}n&&e.error("Failed to parse integer type")}()||function(){const n=e.consume("unrestricted"),r=e.consume("float","double");if(r)return new H({source:t,tokens:{prefix:n,base:r}});n&&e.error("Failed to parse float type")}();if(n)return n;const r=e.consume("bigint","boolean","byte","octet","undefined");return r?new H({source:t,tokens:{base:r}}):void 0}function ne(e){return X(e,{parser:V.parse,listName:"arguments list"})}function re(e,t){const n=W.parse(e),r=H.parse(e,t);return r&&(le(r).extAttrs=n),r}function se(e,t){const n=H.parse(e,t||"return-type");if(n)return n;const r=e.consume("void");if(r){const t=new H({source:e.source,tokens:{base:r}});return t.type="return-type",t}}function ie(e){const t=e.consume("stringifier");if(!t)return;return Z.parse(e,{special:t})||K.parse(e,{special:t})||e.error("Unterminated stringifier")}function oe(e){const t=e.split("\n");if(t.length){const e=t[t.length-1].match(/^\s+/);if(e)return e[0]}return""}function ae(e){return()=>{if(e.extAttrs.length){const t=new be("Exposed=Window,"),n=q.parse(t);n.tokens.separator=t.consume(",");const r=e.extAttrs[0];/^\s/.test(r.tokens.name.trivia)||(r.tokens.name.trivia=` ${r.tokens.name.trivia}`),e.extAttrs.unshift(n)}else{le(e).extAttrs=W.parse(new be("[Exposed=Window]"));const t=e.tokens.base.trivia;e.extAttrs.tokens.open.trivia=t,e.tokens.base.trivia=`\n${oe(t)}`}}}function ce(e){if(e.extAttrs.length)return e.extAttrs.tokens.open;if("operation"===e.type&&!e.special)return ce(e.idlType);return Object.values(e.tokens).sort(((e,t)=>e.index-t.index))[0]}function le(e,t){if(t||(t=e),!e)return e;return new Proxy(e,{get(e,t){const n=e[t];return Array.isArray(n)&&"source"!==t?le(n,e):n},set(e,n,r){if(e[n]=r,!r)return!0;if(Array.isArray(r))for(const e of r)void 0!==e.parent&&(e.parent=t);else void 0!==r.parent&&(r.parent=t);return!0}})}const ue={decimal:/-?(?=[0-9]*\.|[0-9]+[eE])(([0-9]+\.[0-9]*|[0-9]*\.[0-9]+)([Ee][-+]?[0-9]+)?|[0-9]+[Ee][-+]?[0-9]+)/y,integer:/-?(0([Xx][0-9A-Fa-f]+|[0-7]*)|[1-9][0-9]*)/y,identifier:/[_-]?[A-Za-z][0-9A-Z_a-z-]*/y,string:/"[^"]*"/y,whitespace:/[\t\n\r ]+/y,comment:/\/\/.*|\/\*[\s\S]*?\*\//y,other:/[^\t\n\r 0-9A-Za-z]/y},de=["ArrayBuffer","DataView","Int8Array","Int16Array","Int32Array","Uint8Array","Uint16Array","Uint32Array","Uint8ClampedArray","BigInt64Array","BigUint64Array","Float32Array","Float64Array","any","object","symbol"],pe=["ByteString","DOMString","USVString"],fe=["async","attribute","callback","const","constructor","deleter","dictionary","enum","getter","includes","inherit","interface","iterable","maplike","namespace","partial","required","setlike","setter","static","stringifier","typedef","unrestricted"],he=["-Infinity","FrozenArray","Infinity","NaN","ObservableArray","Promise","bigint","boolean","byte","double","false","float","long","mixin","null","octet","optional","or","readonly","record","sequence","short","true","undefined","unsigned","void"].concat(fe,pe,de),me=["(",")",",","...",":",";","<","=",">","?","*","[","]","{","}"],ge=["_constructor","toString","_toString"];class be{constructor(e){this.source=function(e){const t=[];let n=0,r="",s=1,i=0;for(;n<e.length;){const a=e.charAt(n);let c=-1;if(/[\t\n\r ]/.test(a)?c=o("whitespace",{noFlushTrivia:!0}):"/"===a&&(c=o("comment",{noFlushTrivia:!0})),-1!==c){const e=t.pop().value;s+=(e.match(/\n/g)||[]).length,r+=e,i-=1}else if(/[-0-9.A-Z_a-z]/.test(a)){if(c=o("decimal"),-1===c&&(c=o("integer")),-1===c){c=o("identifier");const e=t.length-1,n=t[e];if(-1!==c){if(ge.includes(n.value)){const r=`${J(n.value)} is a reserved identifier and must not be used.`;throw new ye(E(t,e,null,r))}he.includes(n.value)&&(n.type="inline")}}}else'"'===a&&(c=o("string"));for(const o of me)if(e.startsWith(o,n)){t.push({type:"inline",value:o,trivia:r,line:s,index:i}),r="",n+=o.length,c=n;break}if(-1===c&&(c=o("other")),-1===c)throw new Error("Token stream not progressing");n=c,i+=1}return t.push({type:"eof",value:"",trivia:r,line:s,index:i}),t;function o(o,{noFlushTrivia:a}={}){const c=ue[o];c.lastIndex=n;const l=c.exec(e);return l?(t.push({type:o,value:l[0],trivia:r,line:s,index:i}),a||(r=""),c.lastIndex):-1}}(e),this.position=0}error(e){throw new ye(E(this.source,this.position,this.current,e))}probeKind(e){return this.source.length>this.position&&this.source[this.position].type===e}probe(e){return this.probeKind("inline")&&this.source[this.position].value===e}consumeKind(...e){for(const t of e){if(!this.probeKind(t))continue;const e=this.source[this.position];return this.position++,e}}consume(...e){if(!this.probeKind("inline"))return;const t=this.source[this.position];for(const n of e)if(t.value===n)return this.position++,t}consumeIdentifier(e){if(this.probeKind("identifier")&&this.source[this.position].value===e)return this.consumeKind("identifier")}unconsume(e){this.position=e}}class ye extends Error{constructor({message:e,bareMessage:t,context:n,line:r,sourceName:s,input:i,tokens:o}){super(e),this.name="WebIDLParseError",this.bareMessage=t,this.context=n,this.line=r,this.sourceName=s,this.input=i,this.tokens=o}}class we extends D{static parse(e){const t=e.consumeKind("string");if(t)return new we({source:e.source,tokens:{value:t}})}get type(){return"enum-value"}get value(){return super.value.slice(1,-1)}write(e){const{parent:t}=this;return e.ts.wrap([e.ts.trivia(this.tokens.value.trivia),e.ts.definition(e.ts.wrap(['"',e.ts.name(this.value,{data:this,parent:t}),'"']),{data:this,parent:t}),e.token(this.tokens.separator)])}}class ve extends T{static parse(e){const t={};if(t.base=e.consume("enum"),!t.base)return;t.name=e.consumeKind("identifier")||e.error("No name for enum");const n=le(new ve({source:e.source,tokens:t}));return e.current=n.this,t.open=e.consume("{")||e.error("Bodyless enum"),n.values=X(e,{parser:we.parse,allowDangler:!0,listName:"enumeration"}),e.probeKind("string")&&e.error("No comma between enum values"),t.close=e.consume("}")||e.error("Unexpected value in enum"),n.values.length||e.error("No value in enum"),t.termination=e.consume(";")||e.error("No semicolon after enum"),n.this}get type(){return"enum"}get name(){return J(this.tokens.name.value)}write(e){return e.ts.definition(e.ts.wrap([this.extAttrs.write(e),e.token(this.tokens.base),e.name_token(this.tokens.name,{data:this}),e.token(this.tokens.open),e.ts.wrap(this.values.map((t=>t.write(e)))),e.token(this.tokens.close),e.token(this.tokens.termination)]),{data:this})}}class $e extends T{static parse(e){const t=e.consumeKind("identifier");if(!t)return;const n={target:t};if(n.includes=e.consume("includes"),n.includes)return n.mixin=e.consumeKind("identifier")||e.error("Incomplete includes statement"),n.termination=e.consume(";")||e.error("No terminating ; for includes statement"),new $e({source:e.source,tokens:n});e.unconsume(t.index)}get type(){return"includes"}get target(){return J(this.tokens.target.value)}get includes(){return J(this.tokens.mixin.value)}write(e){return e.ts.definition(e.ts.wrap([this.extAttrs.write(e),e.reference_token(this.tokens.target,this),e.token(this.tokens.includes),e.reference_token(this.tokens.mixin,this),e.token(this.tokens.termination)]),{data:this})}}class ke extends T{static parse(e){const t={},n=le(new ke({source:e.source,tokens:t}));if(t.base=e.consume("typedef"),t.base)return n.idlType=re(e,"typedef-type")||e.error("Typedef lacks a type"),t.name=e.consumeKind("identifier")||e.error("Typedef lacks a name"),e.current=n.this,t.termination=e.consume(";")||e.error("Unterminated typedef, expected `;`"),n.this}get type(){return"typedef"}get name(){return J(this.tokens.name.value)}*validate(e){yield*this.idlType.validate(e)}write(e){return e.ts.definition(e.ts.wrap([this.extAttrs.write(e),e.token(this.tokens.base),e.ts.type(this.idlType.write(e)),e.name_token(this.tokens.name,{data:this}),e.token(this.tokens.termination)]),{data:this})}}class xe extends T{static parse(e,t){const n={base:t},r=le(new xe({source:e.source,tokens:n}));return n.name=e.consumeKind("identifier")||e.error("Callback lacks a name"),e.current=r.this,n.assign=e.consume("=")||e.error("Callback lacks an assignment"),r.idlType=se(e)||e.error("Callback lacks a return type"),n.open=e.consume("(")||e.error("Callback lacks parentheses for arguments"),r.arguments=ne(e),n.close=e.consume(")")||e.error("Unterminated callback"),n.termination=e.consume(";")||e.error("Unterminated callback, expected `;`"),r.this}get type(){return"callback"}get name(){return J(this.tokens.name.value)}*validate(e){yield*this.extAttrs.validate(e),yield*this.idlType.validate(e)}write(e){return e.ts.definition(e.ts.wrap([this.extAttrs.write(e),e.token(this.tokens.base),e.name_token(this.tokens.name,{data:this}),e.token(this.tokens.assign),e.ts.type(this.idlType.write(e)),e.token(this.tokens.open),...this.arguments.map((t=>t.write(e))),e.token(this.tokens.close),e.token(this.tokens.termination)]),{data:this})}}class _e extends T{static parse(e,t,{inheritable:n,allowedMembers:r}){const{tokens:s,type:i}=t;for(s.name=e.consumeKind("identifier")||e.error(`Missing name in ${i}`),e.current=t,t=le(t),n&&Object.assign(s,function(e){const t=e.consume(":");return t?{colon:t,inheritance:e.consumeKind("identifier")||e.error("Inheritance lacks a type")}:{}}(e)),s.open=e.consume("{")||e.error(`Bodyless ${i}`),t.members=[];;){if(s.close=e.consume("}"),s.close)return s.termination=e.consume(";")||e.error(`Missing semicolon after ${i}`),t.this;const n=W.parse(e);let o;for(const[t,...n]of r)if(o=le(t(e,...n)),o)break;o||e.error("Unknown member"),o.extAttrs=n,t.members.push(o.this)}}get partial(){return!!this.tokens.partial}get name(){return J(this.tokens.name.value)}get inheritance(){return this.tokens.inheritance?J(this.tokens.inheritance.value):null}*validate(e){for(const t of this.members)t.validate&&(yield*t.validate(e))}write(e){return e.ts.definition(e.ts.wrap([this.extAttrs.write(e),e.token(this.tokens.callback),e.token(this.tokens.partial),e.token(this.tokens.base),e.token(this.tokens.mixin),e.name_token(this.tokens.name,{data:this}),(()=>this.tokens.inheritance?e.ts.wrap([e.token(this.tokens.colon),e.ts.trivia(this.tokens.inheritance.trivia),e.ts.inheritance(e.reference(this.tokens.inheritance.value,{context:this}))]):"")(),e.token(this.tokens.open),e.ts.wrap(this.members.map((t=>t.write(e)))),e.token(this.tokens.close),e.token(this.tokens.termination)]),{data:this})}}class Ce extends T{static parse(e){const t={};if(t.base=e.consume("const"),!t.base)return;let n=te(e);if(!n){const t=e.consumeKind("identifier")||e.error("Const lacks a type");n=new H({source:e.source,tokens:{base:t}})}e.probe("?")&&e.error("Unexpected nullable constant type"),n.type="const-type",t.name=e.consumeKind("identifier")||e.error("Const lacks a name"),t.assign=e.consume("=")||e.error("Const lacks value assignment"),t.value=Q(e)||e.error("Const lacks a value"),t.termination=e.consume(";")||e.error("Unterminated const, expected `;`");const r=new Ce({source:e.source,tokens:t});return le(r).idlType=n,r}get type(){return"const"}get name(){return J(this.tokens.name.value)}get value(){return ee(this.tokens.value)}write(e){const{parent:t}=this;return e.ts.definition(e.ts.wrap([this.extAttrs.write(e),e.token(this.tokens.base),e.ts.type(this.idlType.write(e)),e.name_token(this.tokens.name,{data:this,parent:t}),e.token(this.tokens.assign),e.token(this.tokens.value),e.token(this.tokens.termination)]),{data:this,parent:t})}}class Se extends T{static parse(e){const t=e.position,n=le(new Se({source:e.source,tokens:{}})),{tokens:r}=n;if(r.readonly=e.consume("readonly"),r.readonly||(r.async=e.consume("async")),r.base=r.readonly?e.consume("maplike","setlike"):r.async?e.consume("iterable"):e.consume("iterable","maplike","setlike"),!r.base)return void e.unconsume(t);const{type:s}=n,i="maplike"===s,o=i||"iterable"===s,a=n.async&&"iterable"===s;r.open=e.consume("<")||e.error(`Missing less-than sign \`<\` in ${s} declaration`);const c=re(e)||e.error(`Missing a type argument in ${s} declaration`);return n.idlType=[c],n.arguments=[],o&&(c.tokens.separator=e.consume(","),c.tokens.separator?n.idlType.push(re(e)):i&&e.error(`Missing second type argument in ${s} declaration`)),r.close=e.consume(">")||e.error(`Missing greater-than sign \`>\` in ${s} declaration`),e.probe("(")&&(a?(r.argsOpen=e.consume("("),n.arguments.push(...ne(e)),r.argsClose=e.consume(")")||e.error("Unterminated async iterable argument list")):e.error("Arguments are only allowed for `async iterable`")),r.termination=e.consume(";")||e.error(`Missing semicolon after ${s} declaration`),n.this}get type(){return this.tokens.base.value}get readonly(){return!!this.tokens.readonly}get async(){return!!this.tokens.async}*validate(e){for(const t of this.idlType)yield*t.validate(e);for(const t of this.arguments)yield*t.validate(e)}write(e){return e.ts.definition(e.ts.wrap([this.extAttrs.write(e),e.token(this.tokens.readonly),e.token(this.tokens.async),e.token(this.tokens.base,e.ts.generic),e.token(this.tokens.open),e.ts.wrap(this.idlType.map((t=>t.write(e)))),e.token(this.tokens.close),e.token(this.tokens.argsOpen),e.ts.wrap(this.arguments.map((t=>t.write(e)))),e.token(this.tokens.argsClose),e.token(this.tokens.termination)]),{data:this,parent:this.parent})}}class Re extends T{static parse(e){const t=e.consume("constructor");if(!t)return;const n={base:t};n.open=e.consume("(")||e.error("No argument list in constructor");const r=ne(e);n.close=e.consume(")")||e.error("Unterminated constructor"),n.termination=e.consume(";")||e.error("No semicolon after constructor");const s=new Re({source:e.source,tokens:n});return le(s).arguments=r,s}get type(){return"constructor"}*validate(e){for(const t of this.arguments)yield*t.validate(e)}write(e){const{parent:t}=this;return e.ts.definition(e.ts.wrap([this.extAttrs.write(e),e.token(this.tokens.base,e.ts.nameless,{data:this,parent:t}),e.token(this.tokens.open),e.ts.wrap(this.arguments.map((t=>t.write(e)))),e.token(this.tokens.close),e.token(this.tokens.termination)]),{data:this,parent:t})}}function Ee(e){const t=e.consume("static");if(!t)return;return Z.parse(e,{special:t})||K.parse(e,{special:t})||e.error("No body in static member")}class Ae extends _e{static parse(e,t,{partial:n=null}={}){const r={partial:n,base:t};return _e.parse(e,new Ae({source:e.source,tokens:r}),{inheritable:!n,allowedMembers:[[Ce.parse],[Re.parse],[Ee],[ie],[Se.parse],[Z.parse],[K.parse]]})}get type(){return"interface"}*validate(e){if(yield*this.extAttrs.validate(e),!this.partial&&this.extAttrs.every((e=>"Exposed"!==e.name))){const e="Interfaces must have `[Exposed]` extended attribute. To fix, add, for example, `[Exposed=Window]`. Please also consider carefully if your interface should also be exposed in a Worker scope. Refer to the [WebIDL spec section on Exposed](https://heycam.github.io/webidl/#Exposed) for more information.";yield A(this.tokens.name,this,"require-exposed",e,{autofix:ae(this)})}const t=this.extAttrs.filter((e=>"Constructor"===e.name));for(const e of t){const t="Constructors should now be represented as a `constructor()` operation on the interface instead of `[Constructor]` extended attribute. Refer to the [WebIDL spec section on constructor operations](https://heycam.github.io/webidl/#idl-constructors) for more information.";yield A(e.tokens.name,this,"constructor-member",t,{autofix:Te(this,e)})}if(this.extAttrs.some((e=>"Global"===e.name))){const e=this.extAttrs.filter((e=>"LegacyFactoryFunction"===e.name));for(const t of e){const e="Interfaces marked as `[Global]` cannot have factory functions.";yield A(t.tokens.name,this,"no-constructible-global",e)}const t=this.members.filter((e=>"constructor"===e.type));for(const e of t){const t="Interfaces marked as `[Global]` cannot have constructors.";yield A(e.tokens.base,this,"no-constructible-global",t)}}yield*super.validate(e),this.partial||(yield*function*(e,t){const n=function(e){const t=o(e);return{statics:new Set(t.filter((e=>"static"===e.special)).map((e=>e.name))),nonstatics:new Set(t.filter((e=>"static"!==e.special)).map((e=>e.name)))}}(t),r=e.partials.get(t.name)||[],s=e.mixinMap.get(t.name)||[];for(const e of[...r,...s]){const r=o(e),s=r.filter((e=>"static"===e.special)),a=r.filter((e=>"static"!==e.special));yield*i(s,n.statics,e,t),yield*i(a,n.nonstatics,e,t),s.forEach((e=>n.statics.add(e.name))),a.forEach((e=>n.nonstatics.add(e.name)))}function*i(e,t,n,r){for(const s of e){const{name:e}=s;if(e&&t.has(e)){const t=`The ${"static"===s.special?"static ":""}operation "${e}" has already been defined for the base interface "${r.name}" either in itself or in a mixin`;yield A(s.tokens.name,n,"no-cross-overload",t)}}}function o(e){return e.members.filter((({type:e})=>"operation"===e))}}(e,this))}}function Te(e,t){return e=le(e),()=>{const n=oe(e.extAttrs.tokens.open.trivia),r=e.members.length?oe(ce(e.members[0]).trivia):function(e){const t=oe(e),n=t.includes("\t")?"\t":" ";return t+n}(n),s=Re.parse(new be(`\n${r}constructor();`));s.extAttrs=new W({source:e.source,tokens:{}}),le(s).arguments=t.arguments;const i=function(e,t){const n=e.slice().reverse().findIndex(t);return-1===n?n:e.length-n-1}(e.members,(e=>"constructor"===e.type));e.members.splice(i+1,0,s);const{close:o}=e.tokens;o.trivia.includes("\n")||(o.trivia+=`\n${n}`);const{extAttrs:a}=e,c=a.indexOf(t),l=a.splice(c,1);a.length?a.length===c?a[c-1].tokens.separator=void 0:a[c].tokens.name.trivia.trim()||(a[c].tokens.name.trivia=l[0].tokens.name.trivia):a.tokens.open=a.tokens.close=void 0}}class Le extends _e{static parse(e,t,{partial:n}={}){const r={partial:n,base:t};if(r.mixin=e.consume("mixin"),r.mixin)return _e.parse(e,new Le({source:e.source,tokens:r}),{allowedMembers:[[Ce.parse],[ie],[Z.parse,{noInherit:!0}],[K.parse,{regular:!0}]]})}get type(){return"interface mixin"}}class Pe extends T{static parse(e){const t={},n=le(new Pe({source:e.source,tokens:t}));return n.extAttrs=W.parse(e),t.required=e.consume("required"),n.idlType=re(e,"dictionary-type")||e.error("Dictionary member lacks a type"),t.name=e.consumeKind("identifier")||e.error("Dictionary member lacks a name"),n.default=G.parse(e),t.required&&n.default&&e.error("Required member must not have a default"),t.termination=e.consume(";")||e.error("Unterminated dictionary member, expected `;`"),n.this}get type(){return"field"}get name(){return J(this.tokens.name.value)}get required(){return!!this.tokens.required}*validate(e){yield*this.idlType.validate(e)}write(e){const{parent:t}=this;return e.ts.definition(e.ts.wrap([this.extAttrs.write(e),e.token(this.tokens.required),e.ts.type(this.idlType.write(e)),e.name_token(this.tokens.name,{data:this,parent:t}),this.default?this.default.write(e):"",e.token(this.tokens.termination)]),{data:this,parent:t})}}class Ie extends _e{static parse(e,{partial:t}={}){const n={partial:t};if(n.base=e.consume("dictionary"),n.base)return _e.parse(e,new Ie({source:e.source,tokens:n}),{inheritable:!t,allowedMembers:[[Pe.parse]]})}get type(){return"dictionary"}}class De extends _e{static parse(e,{partial:t}={}){const n={partial:t};if(n.base=e.consume("namespace"),n.base)return _e.parse(e,new De({source:e.source,tokens:n}),{allowedMembers:[[Z.parse,{noInherit:!0,readonly:!0}],[Ce.parse],[K.parse,{regular:!0}]]})}get type(){return"namespace"}*validate(e){if(!this.partial&&this.extAttrs.every((e=>"Exposed"!==e.name))){const e="Namespaces must have [Exposed] extended attribute. To fix, add, for example, [Exposed=Window]. Please also consider carefully if your namespace should also be exposed in a Worker scope. Refer to the [WebIDL spec section on Exposed](https://heycam.github.io/webidl/#Exposed) for more information.";yield A(this.tokens.name,this,"require-exposed",e,{autofix:ae(this)})}yield*super.validate(e)}}class Ne extends _e{static parse(e,t,{partial:n=null}={}){const r={callback:t};if(r.base=e.consume("interface"),r.base)return _e.parse(e,new Ne({source:e.source,tokens:r}),{inheritable:!n,allowedMembers:[[Ce.parse],[K.parse,{regular:!0}]]})}get type(){return"callback interface"}}function Oe(e,t){const n=e.source;function r(t){e.error(t)}function s(...t){return e.consume(...t)}function i(t){const n=s("interface");if(!n)return;return Le.parse(e,n,t)||Ae.parse(e,n,t)||r("Interface has no proper body")}function o(){if(t.productions)for(const n of t.productions){const t=n(e);if(t)return t}return function(){const t=s("callback");if(t)return e.probe("interface")?Ne.parse(e,t):xe.parse(e,t)}()||i()||function(){const t=s("partial");if(t)return Ie.parse(e,{partial:t})||i({partial:t})||De.parse(e,{partial:t})||r("Partial doesn't apply to anything")}()||Ie.parse(e)||ve.parse(e)||ke.parse(e)||$e.parse(e)||De.parse(e)}const a=function(){if(!n.length)return[];const s=[];for(;;){const t=W.parse(e),n=o();if(!n){t.length&&r("Stray extended attributes");break}le(n).extAttrs=t,s.push(n)}const i=N.parse(e);return t.concrete&&s.push(i),s}();return e.position<n.length&&r("Unrecognised tokens"),a}function je(e){return e}const Me={wrap:e=>e.join(""),trivia:je,name:je,reference:je,type:je,generic:je,nameless:je,inheritance:je,definition:je,extendedAttribute:je,extendedAttributeReference:je};class ze{constructor(e){this.ts=Object.assign({},Me,e)}reference(e,{unescaped:t,context:n}){return t||(t=e.startsWith("_")?e.slice(1):e),this.ts.reference(e,t,n)}token(e,t=je,...n){if(!e)return"";const r=t(e.value,...n);return this.ts.wrap([this.ts.trivia(e.trivia),r])}reference_token(e,t){return this.token(e,this.reference.bind(this),{context:t})}name_token(e,t){return this.token(e,this.ts.name,t)}identifier(e,t){return this.ts.wrap([this.reference_token(e.tokens.value,t),this.token(e.tokens.separator)])}}function Ue(e,t){const n=new Map,r=e.filter((e=>"includes"===e.type));for(const e of r){const r=t.get(e.includes);if(!r)continue;const s=n.get(e.target);s?s.push(r):n.set(e.target,[r])}return n}function*qe(e){const t=function(e){const t=new Map,n=new Set,r=new Map;for(const s of e)if(s.partial){const e=r.get(s.name);e?e.push(s):r.set(s.name,[s])}else s.name&&(t.has(s.name)?n.add(s):t.set(s.name,s));return{all:e,unique:t,partials:r,duplicates:n,mixinMap:Ue(e,t),cache:{typedefIncludesDictionary:new WeakMap,dictionaryIncludesRequiredField:new WeakMap}}}(e);for(const e of t.all)e.validate&&(yield*e.validate(t));yield*function*({unique:e,duplicates:t}){for(const n of t){const{name:t}=n,r=`The name "${t}" of type "${e.get(t).type}" was already seen`;yield A(n.tokens.name,n,"no-duplicate",r)}}(t)}var We=Object.freeze({__proto__:null,WebIDLParseError:ye,parse:function(e,t={}){const n=new be(e);return void 0!==t.sourceName&&(n.source.name=t.sourceName),Oe(n,t)},validate:function(e){return[...qe((t=e,t.flat?t.flat():[].concat(...t)))];var t},write:function(e,{templates:t=Me}={}){t=Object.assign({},Me,t);const n=new ze(t);return t.wrap(e.map((e=>e.write(n))))}});const Fe=/^[!#$%&'*+-.^`|~\w]+$/,Be=/[\u000A\u000D\u0009\u0020]/u,He=/^[\u0009\u{0020}-\{u0073}\u{0080}-\u{00FF}]+$/u;function Ge(e,t,n){(t&&""!==t&&!e.has(t)&&He.test(n)||null===n)&&e.set(t.toLowerCase(),n)}function Ve(){return{async:!1,baseUrl:null,breaks:!1,extensions:null,gfm:!0,headerIds:!0,headerPrefix:"",highlight:null,hooks:null,langPrefix:"language-",mangle:!0,pedantic:!1,renderer:null,sanitize:!1,sanitizer:null,silent:!1,smartypants:!1,tokenizer:null,walkTokens:null,xhtml:!1}}let Ye={async:!1,baseUrl:null,breaks:!1,extensions:null,gfm:!0,headerIds:!0,headerPrefix:"",highlight:null,hooks:null,langPrefix:"language-",mangle:!0,pedantic:!1,renderer:null,sanitize:!1,sanitizer:null,silent:!1,smartypants:!1,tokenizer:null,walkTokens:null,xhtml:!1};const Ke=/[&<>"']/,Ze=new RegExp(Ke.source,"g"),Je=/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,Xe=new RegExp(Je.source,"g"),Qe={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"},et=e=>Qe[e];function tt(e,t){if(t){if(Ke.test(e))return e.replace(Ze,et)}else if(Je.test(e))return e.replace(Xe,et);return e}const nt=/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/gi;function rt(e){return e.replace(nt,((e,t)=>"colon"===(t=t.toLowerCase())?":":"#"===t.charAt(0)?"x"===t.charAt(1)?String.fromCharCode(parseInt(t.substring(2),16)):String.fromCharCode(+t.substring(1)):""))}const st=/(^|[^\[])\^/g;function it(e,t){e="string"==typeof e?e:e.source,t=t||"";const n={replace:(t,r)=>(r=(r=r.source||r).replace(st,"$1"),e=e.replace(t,r),n),getRegex:()=>new RegExp(e,t)};return n}const ot=/[^\w:]/g,at=/^$|^[a-z][a-z0-9+.-]*:|^[?#]/i;function ct(e,t,n){if(e){let e;try{e=decodeURIComponent(rt(n)).replace(ot,"").toLowerCase()}catch(e){return null}if(0===e.indexOf("javascript:")||0===e.indexOf("vbscript:")||0===e.indexOf("data:"))return null}t&&!at.test(n)&&(n=function(e,t){lt[" "+e]||(ut.test(e)?lt[" "+e]=e+"/":lt[" "+e]=mt(e,"/",!0));const n=-1===(e=lt[" "+e]).indexOf(":");return"//"===t.substring(0,2)?n?t:e.replace(dt,"$1")+t:"/"===t.charAt(0)?n?t:e.replace(pt,"$1")+t:e+t}(t,n));try{n=encodeURI(n).replace(/%25/g,"%")}catch(e){return null}return n}const lt={},ut=/^[^:]+:\/*[^/]*$/,dt=/^([^:]+:)[\s\S]*$/,pt=/^([^:]+:\/*[^/]*)[\s\S]*$/;const ft={exec:function(){}};function ht(e,t){const n=e.replace(/\|/g,((e,t,n)=>{let r=!1,s=t;for(;--s>=0&&"\\"===n[s];)r=!r;return r?"|":" |"})).split(/ \|/);let r=0;if(n[0].trim()||n.shift(),n.length>0&&!n[n.length-1].trim()&&n.pop(),n.length>t)n.splice(t);else for(;n.length<t;)n.push("");for(;r<n.length;r++)n[r]=n[r].trim().replace(/\\\|/g,"|");return n}function mt(e,t,n){const r=e.length;if(0===r)return"";let s=0;for(;s<r;){const i=e.charAt(r-s-1);if(i!==t||n){if(i===t||!n)break;s++}else s++}return e.slice(0,r-s)}function gt(e,t){if(t<1)return"";let n="";for(;t>1;)1&t&&(n+=e),t>>=1,e+=e;return n+e}function bt(e,t,n,r){const s=t.href,i=t.title?tt(t.title):null,o=e[1].replace(/\\([\[\]])/g,"$1");if("!"!==e[0].charAt(0)){r.state.inLink=!0;const e={type:"link",raw:n,href:s,title:i,text:o,tokens:r.inlineTokens(o)};return r.state.inLink=!1,e}return{type:"image",raw:n,href:s,title:i,text:tt(o)}}class yt{constructor(e){this.options=e||Ye}space(e){const t=this.rules.block.newline.exec(e);if(t&&t[0].length>0)return{type:"space",raw:t[0]}}code(e){const t=this.rules.block.code.exec(e);if(t){const e=t[0].replace(/^ {1,4}/gm,"");return{type:"code",raw:t[0],codeBlockStyle:"indented",text:this.options.pedantic?e:mt(e,"\n")}}}fences(e){const t=this.rules.block.fences.exec(e);if(t){const e=t[0],n=function(e,t){const n=e.match(/^(\s+)(?:```)/);if(null===n)return t;const r=n[1];return t.split("\n").map((e=>{const t=e.match(/^\s+/);if(null===t)return e;const[n]=t;return n.length>=r.length?e.slice(r.length):e})).join("\n")}(e,t[3]||"");return{type:"code",raw:e,lang:t[2]?t[2].trim().replace(this.rules.inline._escapes,"$1"):t[2],text:n}}}heading(e){const t=this.rules.block.heading.exec(e);if(t){let e=t[2].trim();if(/#$/.test(e)){const t=mt(e,"#");this.options.pedantic?e=t.trim():t&&!/ $/.test(t)||(e=t.trim())}return{type:"heading",raw:t[0],depth:t[1].length,text:e,tokens:this.lexer.inline(e)}}}hr(e){const t=this.rules.block.hr.exec(e);if(t)return{type:"hr",raw:t[0]}}blockquote(e){const t=this.rules.block.blockquote.exec(e);if(t){const e=t[0].replace(/^ *>[ \t]?/gm,""),n=this.lexer.state.top;this.lexer.state.top=!0;const r=this.lexer.blockTokens(e);return this.lexer.state.top=n,{type:"blockquote",raw:t[0],tokens:r,text:e}}}list(e){let t=this.rules.block.list.exec(e);if(t){let n,r,s,i,o,a,c,l,u,d,p,f,h=t[1].trim();const m=h.length>1,g={type:"list",raw:"",ordered:m,start:m?+h.slice(0,-1):"",loose:!1,items:[]};h=m?`\\d{1,9}\\${h.slice(-1)}`:`\\${h}`,this.options.pedantic&&(h=m?h:"[*+-]");const b=new RegExp(`^( {0,3}${h})((?:[\t ][^\\n]*)?(?:\\n|$))`);for(;e&&(f=!1,t=b.exec(e))&&!this.rules.block.hr.test(e);){if(n=t[0],e=e.substring(n.length),l=t[2].split("\n",1)[0].replace(/^\t+/,(e=>" ".repeat(3*e.length))),u=e.split("\n",1)[0],this.options.pedantic?(i=2,p=l.trimLeft()):(i=t[2].search(/[^ ]/),i=i>4?1:i,p=l.slice(i),i+=t[1].length),a=!1,!l&&/^ *$/.test(u)&&(n+=u+"\n",e=e.substring(u.length+1),f=!0),!f){const t=new RegExp(`^ {0,${Math.min(3,i-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ \t][^\\n]*)?(?:\\n|$))`),r=new RegExp(`^ {0,${Math.min(3,i-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),s=new RegExp(`^ {0,${Math.min(3,i-1)}}(?:\`\`\`|~~~)`),o=new RegExp(`^ {0,${Math.min(3,i-1)}}#`);for(;e&&(d=e.split("\n",1)[0],u=d,this.options.pedantic&&(u=u.replace(/^ {1,4}(?=( {4})*[^ ])/g," ")),!s.test(u))&&!o.test(u)&&!t.test(u)&&!r.test(e);){if(u.search(/[^ ]/)>=i||!u.trim())p+="\n"+u.slice(i);else{if(a)break;if(l.search(/[^ ]/)>=4)break;if(s.test(l))break;if(o.test(l))break;if(r.test(l))break;p+="\n"+u}a||u.trim()||(a=!0),n+=d+"\n",e=e.substring(d.length+1),l=u.slice(i)}}g.loose||(c?g.loose=!0:/\n *\n *$/.test(n)&&(c=!0)),this.options.gfm&&(r=/^\[[ xX]\] /.exec(p),r&&(s="[ ] "!==r[0],p=p.replace(/^\[[ xX]\] +/,""))),g.items.push({type:"list_item",raw:n,task:!!r,checked:s,loose:!1,text:p}),g.raw+=n}g.items[g.items.length-1].raw=n.trimRight(),g.items[g.items.length-1].text=p.trimRight(),g.raw=g.raw.trimRight();const y=g.items.length;for(o=0;o<y;o++)if(this.lexer.state.top=!1,g.items[o].tokens=this.lexer.blockTokens(g.items[o].text,[]),!g.loose){const e=g.items[o].tokens.filter((e=>"space"===e.type)),t=e.length>0&&e.some((e=>/\n.*\n/.test(e.raw)));g.loose=t}if(g.loose)for(o=0;o<y;o++)g.items[o].loose=!0;return g}}html(e){const t=this.rules.block.html.exec(e);if(t){const e={type:"html",raw:t[0],pre:!this.options.sanitizer&&("pre"===t[1]||"script"===t[1]||"style"===t[1]),text:t[0]};if(this.options.sanitize){const n=this.options.sanitizer?this.options.sanitizer(t[0]):tt(t[0]);e.type="paragraph",e.text=n,e.tokens=this.lexer.inline(n)}return e}}def(e){const t=this.rules.block.def.exec(e);if(t){const e=t[1].toLowerCase().replace(/\s+/g," "),n=t[2]?t[2].replace(/^<(.*)>$/,"$1").replace(this.rules.inline._escapes,"$1"):"",r=t[3]?t[3].substring(1,t[3].length-1).replace(this.rules.inline._escapes,"$1"):t[3];return{type:"def",tag:e,raw:t[0],href:n,title:r}}}table(e){const t=this.rules.block.table.exec(e);if(t){const e={type:"table",header:ht(t[1]).map((e=>({text:e}))),align:t[2].replace(/^ *|\| *$/g,"").split(/ *\| */),rows:t[3]&&t[3].trim()?t[3].replace(/\n[ \t]*$/,"").split("\n"):[]};if(e.header.length===e.align.length){e.raw=t[0];let n,r,s,i,o=e.align.length;for(n=0;n<o;n++)/^ *-+: *$/.test(e.align[n])?e.align[n]="right":/^ *:-+: *$/.test(e.align[n])?e.align[n]="center":/^ *:-+ *$/.test(e.align[n])?e.align[n]="left":e.align[n]=null;for(o=e.rows.length,n=0;n<o;n++)e.rows[n]=ht(e.rows[n],e.header.length).map((e=>({text:e})));for(o=e.header.length,r=0;r<o;r++)e.header[r].tokens=this.lexer.inline(e.header[r].text);for(o=e.rows.length,r=0;r<o;r++)for(i=e.rows[r],s=0;s<i.length;s++)i[s].tokens=this.lexer.inline(i[s].text);return e}}}lheading(e){const t=this.rules.block.lheading.exec(e);if(t)return{type:"heading",raw:t[0],depth:"="===t[2].charAt(0)?1:2,text:t[1],tokens:this.lexer.inline(t[1])}}paragraph(e){const t=this.rules.block.paragraph.exec(e);if(t){const e="\n"===t[1].charAt(t[1].length-1)?t[1].slice(0,-1):t[1];return{type:"paragraph",raw:t[0],text:e,tokens:this.lexer.inline(e)}}}text(e){const t=this.rules.block.text.exec(e);if(t)return{type:"text",raw:t[0],text:t[0],tokens:this.lexer.inline(t[0])}}escape(e){const t=this.rules.inline.escape.exec(e);if(t)return{type:"escape",raw:t[0],text:tt(t[1])}}tag(e){const t=this.rules.inline.tag.exec(e);if(t)return!this.lexer.state.inLink&&/^<a /i.test(t[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&/^<\/a>/i.test(t[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&/^<(pre|code|kbd|script)(\s|>)/i.test(t[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&/^<\/(pre|code|kbd|script)(\s|>)/i.test(t[0])&&(this.lexer.state.inRawBlock=!1),{type:this.options.sanitize?"text":"html",raw:t[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,text:this.options.sanitize?this.options.sanitizer?this.options.sanitizer(t[0]):tt(t[0]):t[0]}}link(e){const t=this.rules.inline.link.exec(e);if(t){const e=t[2].trim();if(!this.options.pedantic&&/^</.test(e)){if(!/>$/.test(e))return;const t=mt(e.slice(0,-1),"\\");if((e.length-t.length)%2==0)return}else{const e=function(e,t){if(-1===e.indexOf(t[1]))return-1;const n=e.length;let r=0,s=0;for(;s<n;s++)if("\\"===e[s])s++;else if(e[s]===t[0])r++;else if(e[s]===t[1]&&(r--,r<0))return s;return-1}(t[2],"()");if(e>-1){const n=(0===t[0].indexOf("!")?5:4)+t[1].length+e;t[2]=t[2].substring(0,e),t[0]=t[0].substring(0,n).trim(),t[3]=""}}let n=t[2],r="";if(this.options.pedantic){const e=/^([^'"]*[^\s])\s+(['"])(.*)\2/.exec(n);e&&(n=e[1],r=e[3])}else r=t[3]?t[3].slice(1,-1):"";return n=n.trim(),/^</.test(n)&&(n=this.options.pedantic&&!/>$/.test(e)?n.slice(1):n.slice(1,-1)),bt(t,{href:n?n.replace(this.rules.inline._escapes,"$1"):n,title:r?r.replace(this.rules.inline._escapes,"$1"):r},t[0],this.lexer)}}reflink(e,t){let n;if((n=this.rules.inline.reflink.exec(e))||(n=this.rules.inline.nolink.exec(e))){let e=(n[2]||n[1]).replace(/\s+/g," ");if(e=t[e.toLowerCase()],!e){const e=n[0].charAt(0);return{type:"text",raw:e,text:e}}return bt(n,e,n[0],this.lexer)}}emStrong(e,t,n=""){let r=this.rules.inline.emStrong.lDelim.exec(e);if(!r)return;if(r[3]&&n.match(/[\p{L}\p{N}]/u))return;const s=r[1]||r[2]||"";if(!s||s&&(""===n||this.rules.inline.punctuation.exec(n))){const n=r[0].length-1;let s,i,o=n,a=0;const c="*"===r[0][0]?this.rules.inline.emStrong.rDelimAst:this.rules.inline.emStrong.rDelimUnd;for(c.lastIndex=0,t=t.slice(-1*e.length+n);null!=(r=c.exec(t));){if(s=r[1]||r[2]||r[3]||r[4]||r[5]||r[6],!s)continue;if(i=s.length,r[3]||r[4]){o+=i;continue}if((r[5]||r[6])&&n%3&&!((n+i)%3)){a+=i;continue}if(o-=i,o>0)continue;i=Math.min(i,i+o+a);const t=e.slice(0,n+r.index+(r[0].length-s.length)+i);if(Math.min(n,i)%2){const e=t.slice(1,-1);return{type:"em",raw:t,text:e,tokens:this.lexer.inlineTokens(e)}}const c=t.slice(2,-2);return{type:"strong",raw:t,text:c,tokens:this.lexer.inlineTokens(c)}}}}codespan(e){const t=this.rules.inline.code.exec(e);if(t){let e=t[2].replace(/\n/g," ");const n=/[^ ]/.test(e),r=/^ /.test(e)&&/ $/.test(e);return n&&r&&(e=e.substring(1,e.length-1)),e=tt(e,!0),{type:"codespan",raw:t[0],text:e}}}br(e){const t=this.rules.inline.br.exec(e);if(t)return{type:"br",raw:t[0]}}del(e){const t=this.rules.inline.del.exec(e);if(t)return{type:"del",raw:t[0],text:t[2],tokens:this.lexer.inlineTokens(t[2])}}autolink(e,t){const n=this.rules.inline.autolink.exec(e);if(n){let e,r;return"@"===n[2]?(e=tt(this.options.mangle?t(n[1]):n[1]),r="mailto:"+e):(e=tt(n[1]),r=e),{type:"link",raw:n[0],text:e,href:r,tokens:[{type:"text",raw:e,text:e}]}}}url(e,t){let n;if(n=this.rules.inline.url.exec(e)){let e,r;if("@"===n[2])e=tt(this.options.mangle?t(n[0]):n[0]),r="mailto:"+e;else{let t;do{t=n[0],n[0]=this.rules.inline._backpedal.exec(n[0])[0]}while(t!==n[0]);e=tt(n[0]),r="www."===n[1]?"http://"+n[0]:n[0]}return{type:"link",raw:n[0],text:e,href:r,tokens:[{type:"text",raw:e,text:e}]}}}inlineText(e,t){const n=this.rules.inline.text.exec(e);if(n){let e;return e=this.lexer.state.inRawBlock?this.options.sanitize?this.options.sanitizer?this.options.sanitizer(n[0]):tt(n[0]):n[0]:tt(this.options.smartypants?t(n[0]):n[0]),{type:"text",raw:n[0],text:e}}}}const wt={newline:/^(?: *(?:\n|$))+/,code:/^( {4}[^\n]+(?:\n(?: *(?:\n|$))*)?)+/,fences:/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,hr:/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,heading:/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,blockquote:/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/,list:/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/,html:"^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n *)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$))",def:/^ {0,3}\[(label)\]: *(?:\n *)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n *)?| *\n *)(title))? *(?:\n+|$)/,table:ft,lheading:/^((?:.|\n(?!\n))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,_paragraph:/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,text:/^[^\n]+/,_label:/(?!\s*\])(?:\\.|[^\[\]\\])+/,_title:/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/};wt.def=it(wt.def).replace("label",wt._label).replace("title",wt._title).getRegex(),wt.bullet=/(?:[*+-]|\d{1,9}[.)])/,wt.listItemStart=it(/^( *)(bull) */).replace("bull",wt.bullet).getRegex(),wt.list=it(wt.list).replace(/bull/g,wt.bullet).replace("hr","\\n+(?=\\1?(?:(?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$))").replace("def","\\n+(?="+wt.def.source+")").getRegex(),wt._tag="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|section|source|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",wt._comment=/<!--(?!-?>)[\s\S]*?(?:-->|$)/,wt.html=it(wt.html,"i").replace("comment",wt._comment).replace("tag",wt._tag).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),wt.paragraph=it(wt._paragraph).replace("hr",wt.hr).replace("heading"," {0,3}#{1,6} ").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",wt._tag).getRegex(),wt.blockquote=it(wt.blockquote).replace("paragraph",wt.paragraph).getRegex(),wt.normal={...wt},wt.gfm={...wt.normal,table:"^ *([^\\n ].*\\|.*)\\n {0,3}(?:\\| *)?(:?-+:? *(?:\\| *:?-+:? *)*)(?:\\| *)?(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)"},wt.gfm.table=it(wt.gfm.table).replace("hr",wt.hr).replace("heading"," {0,3}#{1,6} ").replace("blockquote"," {0,3}>").replace("code"," {4}[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",wt._tag).getRegex(),wt.gfm.paragraph=it(wt._paragraph).replace("hr",wt.hr).replace("heading"," {0,3}#{1,6} ").replace("|lheading","").replace("table",wt.gfm.table).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",wt._tag).getRegex(),wt.pedantic={...wt.normal,html:it("^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:\"[^\"]*\"|'[^']*'|\\s[^'\"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))").replace("comment",wt._comment).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:ft,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:it(wt.normal._paragraph).replace("hr",wt.hr).replace("heading"," *#{1,6} *[^\n]").replace("lheading",wt.lheading).replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").getRegex()};const vt={escape:/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,autolink:/^<(scheme:[^\s\x00-\x1f<>]*|email)>/,url:ft,tag:"^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>",link:/^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/,reflink:/^!?\[(label)\]\[(ref)\]/,nolink:/^!?\[(ref)\](?:\[\])?/,reflinkSearch:"reflink|nolink(?!\\()",emStrong:{lDelim:/^(?:\*+(?:([punct_])|[^\s*]))|^_+(?:([punct*])|([^\s_]))/,rDelimAst:/^(?:[^_*\\]|\\.)*?\_\_(?:[^_*\\]|\\.)*?\*(?:[^_*\\]|\\.)*?(?=\_\_)|(?:[^*\\]|\\.)+(?=[^*])|[punct_](\*+)(?=[\s]|$)|(?:[^punct*_\s\\]|\\.)(\*+)(?=[punct_\s]|$)|[punct_\s](\*+)(?=[^punct*_\s])|[\s](\*+)(?=[punct_])|[punct_](\*+)(?=[punct_])|(?:[^punct*_\s\\]|\\.)(\*+)(?=[^punct*_\s])/,rDelimUnd:/^(?:[^_*\\]|\\.)*?\*\*(?:[^_*\\]|\\.)*?\_(?:[^_*\\]|\\.)*?(?=\*\*)|(?:[^_\\]|\\.)+(?=[^_])|[punct*](\_+)(?=[\s]|$)|(?:[^punct*_\s\\]|\\.)(\_+)(?=[punct*\s]|$)|[punct*\s](\_+)(?=[^punct*_\s])|[\s](\_+)(?=[punct*])|[punct*](\_+)(?=[punct*])/},code:/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,br:/^( {2,}|\\)\n(?!\s*$)/,del:ft,text:/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/,punctuation:/^([\spunctuation])/};function $t(e){return e.replace(/---/g,"—").replace(/--/g,"–").replace(/(^|[-\u2014/(\[{"\s])'/g,"$1‘").replace(/'/g,"’").replace(/(^|[-\u2014/(\[{\u2018\s])"/g,"$1“").replace(/"/g,"”").replace(/\.{3}/g,"…")}function kt(e){let t,n,r="";const s=e.length;for(t=0;t<s;t++)n=e.charCodeAt(t),Math.random()>.5&&(n="x"+n.toString(16)),r+="&#"+n+";";return r}vt._punctuation="!\"#$%&'()+\\-.,/:;<=>?@\\[\\]`^{|}~",vt.punctuation=it(vt.punctuation).replace(/punctuation/g,vt._punctuation).getRegex(),vt.blockSkip=/\[[^\]]*?\]\([^\)]*?\)|`[^`]*?`|<[^>]*?>/g,vt.escapedEmSt=/(?:^|[^\\])(?:\\\\)*\\[*_]/g,vt._comment=it(wt._comment).replace("(?:--\x3e|$)","--\x3e").getRegex(),vt.emStrong.lDelim=it(vt.emStrong.lDelim).replace(/punct/g,vt._punctuation).getRegex(),vt.emStrong.rDelimAst=it(vt.emStrong.rDelimAst,"g").replace(/punct/g,vt._punctuation).getRegex(),vt.emStrong.rDelimUnd=it(vt.emStrong.rDelimUnd,"g").replace(/punct/g,vt._punctuation).getRegex(),vt._escapes=/\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/g,vt._scheme=/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/,vt._email=/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/,vt.autolink=it(vt.autolink).replace("scheme",vt._scheme).replace("email",vt._email).getRegex(),vt._attribute=/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/,vt.tag=it(vt.tag).replace("comment",vt._comment).replace("attribute",vt._attribute).getRegex(),vt._label=/(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/,vt._href=/<(?:\\.|[^\n<>\\])+>|[^\s\x00-\x1f]*/,vt._title=/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/,vt.link=it(vt.link).replace("label",vt._label).replace("href",vt._href).replace("title",vt._title).getRegex(),vt.reflink=it(vt.reflink).replace("label",vt._label).replace("ref",wt._label).getRegex(),vt.nolink=it(vt.nolink).replace("ref",wt._label).getRegex(),vt.reflinkSearch=it(vt.reflinkSearch,"g").replace("reflink",vt.reflink).replace("nolink",vt.nolink).getRegex(),vt.normal={...vt},vt.pedantic={...vt.normal,strong:{start:/^__|\*\*/,middle:/^__(?=\S)([\s\S]*?\S)__(?!_)|^\*\*(?=\S)([\s\S]*?\S)\*\*(?!\*)/,endAst:/\*\*(?!\*)/g,endUnd:/__(?!_)/g},em:{start:/^_|\*/,middle:/^()\*(?=\S)([\s\S]*?\S)\*(?!\*)|^_(?=\S)([\s\S]*?\S)_(?!_)/,endAst:/\*(?!\*)/g,endUnd:/_(?!_)/g},link:it(/^!?\[(label)\]\((.*?)\)/).replace("label",vt._label).getRegex(),reflink:it(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",vt._label).getRegex()},vt.gfm={...vt.normal,escape:it(vt.escape).replace("])","~|])").getRegex(),_extended_email:/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/,url:/^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/,_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])([\s\S]*?[^\s~])\1(?=[^~]|$)/,text:/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|https?:\/\/|ftp:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/},vt.gfm.url=it(vt.gfm.url,"i").replace("email",vt.gfm._extended_email).getRegex(),vt.breaks={...vt.gfm,br:it(vt.br).replace("{2,}","*").getRegex(),text:it(vt.gfm.text).replace("\\b_","\\b_| {2,}\\n").replace(/\{2,\}/g,"*").getRegex()};class xt{constructor(e){this.tokens=[],this.tokens.links=Object.create(null),this.options=e||Ye,this.options.tokenizer=this.options.tokenizer||new yt,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options,this.tokenizer.lexer=this,this.inlineQueue=[],this.state={inLink:!1,inRawBlock:!1,top:!0};const t={block:wt.normal,inline:vt.normal};this.options.pedantic?(t.block=wt.pedantic,t.inline=vt.pedantic):this.options.gfm&&(t.block=wt.gfm,this.options.breaks?t.inline=vt.breaks:t.inline=vt.gfm),this.tokenizer.rules=t}static get rules(){return{block:wt,inline:vt}}static lex(e,t){return new xt(t).lex(e)}static lexInline(e,t){return new xt(t).inlineTokens(e)}lex(e){let t;for(e=e.replace(/\r\n|\r/g,"\n"),this.blockTokens(e,this.tokens);t=this.inlineQueue.shift();)this.inlineTokens(t.src,t.tokens);return this.tokens}blockTokens(e,t=[]){let n,r,s,i;for(e=this.options.pedantic?e.replace(/\t/g," ").replace(/^ +$/gm,""):e.replace(/^( *)(\t+)/gm,((e,t,n)=>t+" ".repeat(n.length)));e;)if(!(this.options.extensions&&this.options.extensions.block&&this.options.extensions.block.some((r=>!!(n=r.call({lexer:this},e,t))&&(e=e.substring(n.raw.length),t.push(n),!0)))))if(n=this.tokenizer.space(e))e=e.substring(n.raw.length),1===n.raw.length&&t.length>0?t[t.length-1].raw+="\n":t.push(n);else if(n=this.tokenizer.code(e))e=e.substring(n.raw.length),r=t[t.length-1],!r||"paragraph"!==r.type&&"text"!==r.type?t.push(n):(r.raw+="\n"+n.raw,r.text+="\n"+n.text,this.inlineQueue[this.inlineQueue.length-1].src=r.text);else if(n=this.tokenizer.fences(e))e=e.substring(n.raw.length),t.push(n);else if(n=this.tokenizer.heading(e))e=e.substring(n.raw.length),t.push(n);else if(n=this.tokenizer.hr(e))e=e.substring(n.raw.length),t.push(n);else if(n=this.tokenizer.blockquote(e))e=e.substring(n.raw.length),t.push(n);else if(n=this.tokenizer.list(e))e=e.substring(n.raw.length),t.push(n);else if(n=this.tokenizer.html(e))e=e.substring(n.raw.length),t.push(n);else if(n=this.tokenizer.def(e))e=e.substring(n.raw.length),r=t[t.length-1],!r||"paragraph"!==r.type&&"text"!==r.type?this.tokens.links[n.tag]||(this.tokens.links[n.tag]={href:n.href,title:n.title}):(r.raw+="\n"+n.raw,r.text+="\n"+n.raw,this.inlineQueue[this.inlineQueue.length-1].src=r.text);else if(n=this.tokenizer.table(e))e=e.substring(n.raw.length),t.push(n);else if(n=this.tokenizer.lheading(e))e=e.substring(n.raw.length),t.push(n);else{if(s=e,this.options.extensions&&this.options.extensions.startBlock){let t=1/0;const n=e.slice(1);let r;this.options.extensions.startBlock.forEach((function(e){r=e.call({lexer:this},n),"number"==typeof r&&r>=0&&(t=Math.min(t,r))})),t<1/0&&t>=0&&(s=e.substring(0,t+1))}if(this.state.top&&(n=this.tokenizer.paragraph(s)))r=t[t.length-1],i&&"paragraph"===r.type?(r.raw+="\n"+n.raw,r.text+="\n"+n.text,this.inlineQueue.pop(),this.inlineQueue[this.inlineQueue.length-1].src=r.text):t.push(n),i=s.length!==e.length,e=e.substring(n.raw.length);else if(n=this.tokenizer.text(e))e=e.substring(n.raw.length),r=t[t.length-1],r&&"text"===r.type?(r.raw+="\n"+n.raw,r.text+="\n"+n.text,this.inlineQueue.pop(),this.inlineQueue[this.inlineQueue.length-1].src=r.text):t.push(n);else if(e){const t="Infinite loop on byte: "+e.charCodeAt(0);if(this.options.silent){console.error(t);break}throw new Error(t)}}return this.state.top=!0,t}inline(e,t=[]){return this.inlineQueue.push({src:e,tokens:t}),t}inlineTokens(e,t=[]){let n,r,s,i,o,a,c=e;if(this.tokens.links){const e=Object.keys(this.tokens.links);if(e.length>0)for(;null!=(i=this.tokenizer.rules.inline.reflinkSearch.exec(c));)e.includes(i[0].slice(i[0].lastIndexOf("[")+1,-1))&&(c=c.slice(0,i.index)+"["+gt("a",i[0].length-2)+"]"+c.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;null!=(i=this.tokenizer.rules.inline.blockSkip.exec(c));)c=c.slice(0,i.index)+"["+gt("a",i[0].length-2)+"]"+c.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);for(;null!=(i=this.tokenizer.rules.inline.escapedEmSt.exec(c));)c=c.slice(0,i.index+i[0].length-2)+"++"+c.slice(this.tokenizer.rules.inline.escapedEmSt.lastIndex),this.tokenizer.rules.inline.escapedEmSt.lastIndex--;for(;e;)if(o||(a=""),o=!1,!(this.options.extensions&&this.options.extensions.inline&&this.options.extensions.inline.some((r=>!!(n=r.call({lexer:this},e,t))&&(e=e.substring(n.raw.length),t.push(n),!0)))))if(n=this.tokenizer.escape(e))e=e.substring(n.raw.length),t.push(n);else if(n=this.tokenizer.tag(e))e=e.substring(n.raw.length),r=t[t.length-1],r&&"text"===n.type&&"text"===r.type?(r.raw+=n.raw,r.text+=n.text):t.push(n);else if(n=this.tokenizer.link(e))e=e.substring(n.raw.length),t.push(n);else if(n=this.tokenizer.reflink(e,this.tokens.links))e=e.substring(n.raw.length),r=t[t.length-1],r&&"text"===n.type&&"text"===r.type?(r.raw+=n.raw,r.text+=n.text):t.push(n);else if(n=this.tokenizer.emStrong(e,c,a))e=e.substring(n.raw.length),t.push(n);else if(n=this.tokenizer.codespan(e))e=e.substring(n.raw.length),t.push(n);else if(n=this.tokenizer.br(e))e=e.substring(n.raw.length),t.push(n);else if(n=this.tokenizer.del(e))e=e.substring(n.raw.length),t.push(n);else if(n=this.tokenizer.autolink(e,kt))e=e.substring(n.raw.length),t.push(n);else if(this.state.inLink||!(n=this.tokenizer.url(e,kt))){if(s=e,this.options.extensions&&this.options.extensions.startInline){let t=1/0;const n=e.slice(1);let r;this.options.extensions.startInline.forEach((function(e){r=e.call({lexer:this},n),"number"==typeof r&&r>=0&&(t=Math.min(t,r))})),t<1/0&&t>=0&&(s=e.substring(0,t+1))}if(n=this.tokenizer.inlineText(s,$t))e=e.substring(n.raw.length),"_"!==n.raw.slice(-1)&&(a=n.raw.slice(-1)),o=!0,r=t[t.length-1],r&&"text"===r.type?(r.raw+=n.raw,r.text+=n.text):t.push(n);else if(e){const t="Infinite loop on byte: "+e.charCodeAt(0);if(this.options.silent){console.error(t);break}throw new Error(t)}}else e=e.substring(n.raw.length),t.push(n);return t}}let _t=class{constructor(e){this.options=e||Ye}code(e,t,n){const r=(t||"").match(/\S*/)[0];if(this.options.highlight){const t=this.options.highlight(e,r);null!=t&&t!==e&&(n=!0,e=t)}return e=e.replace(/\n$/,"")+"\n",r?'<pre><code class="'+this.options.langPrefix+tt(r)+'">'+(n?e:tt(e,!0))+"</code></pre>\n":"<pre><code>"+(n?e:tt(e,!0))+"</code></pre>\n"}blockquote(e){return`<blockquote>\n${e}</blockquote>\n`}html(e){return e}heading(e,t,n,r){if(this.options.headerIds){return`<h${t} id="${this.options.headerPrefix+r.slug(n)}">${e}</h${t}>\n`}return`<h${t}>${e}</h${t}>\n`}hr(){return this.options.xhtml?"<hr/>\n":"<hr>\n"}list(e,t,n){const r=t?"ol":"ul";return"<"+r+(t&&1!==n?' start="'+n+'"':"")+">\n"+e+"</"+r+">\n"}listitem(e){return`<li>${e}</li>\n`}checkbox(e){return"<input "+(e?'checked="" ':"")+'disabled="" type="checkbox"'+(this.options.xhtml?" /":"")+"> "}paragraph(e){return`<p>${e}</p>\n`}table(e,t){return t&&(t=`<tbody>${t}</tbody>`),"<table>\n<thead>\n"+e+"</thead>\n"+t+"</table>\n"}tablerow(e){return`<tr>\n${e}</tr>\n`}tablecell(e,t){const n=t.header?"th":"td";return(t.align?`<${n} align="${t.align}">`:`<${n}>`)+e+`</${n}>\n`}strong(e){return`<strong>${e}</strong>`}em(e){return`<em>${e}</em>`}codespan(e){return`<code>${e}</code>`}br(){return this.options.xhtml?"<br/>":"<br>"}del(e){return`<del>${e}</del>`}link(e,t,n){if(null===(e=ct(this.options.sanitize,this.options.baseUrl,e)))return n;let r='<a href="'+e+'"';return t&&(r+=' title="'+t+'"'),r+=">"+n+"</a>",r}image(e,t,n){if(null===(e=ct(this.options.sanitize,this.options.baseUrl,e)))return n;let r=`<img src="${e}" alt="${n}"`;return t&&(r+=` title="${t}"`),r+=this.options.xhtml?"/>":">",r}text(e){return e}};class Ct{strong(e){return e}em(e){return e}codespan(e){return e}del(e){return e}html(e){return e}text(e){return e}link(e,t,n){return""+n}image(e,t,n){return""+n}br(){return""}}class St{constructor(){this.seen={}}serialize(e){return e.toLowerCase().trim().replace(/<[!\/a-z].*?>/gi,"").replace(/[\u2000-\u206F\u2E00-\u2E7F\\'!"#$%&()*+,./:;<=>?@[\]^`{|}~]/g,"").replace(/\s/g,"-")}getNextSafeSlug(e,t){let n=e,r=0;if(this.seen.hasOwnProperty(n)){r=this.seen[e];do{r++,n=e+"-"+r}while(this.seen.hasOwnProperty(n))}return t||(this.seen[e]=r,this.seen[n]=0),n}slug(e,t={}){const n=this.serialize(e);return this.getNextSafeSlug(n,t.dryrun)}}class Rt{constructor(e){this.options=e||Ye,this.options.renderer=this.options.renderer||new _t,this.renderer=this.options.renderer,this.renderer.options=this.options,this.textRenderer=new Ct,this.slugger=new St}static parse(e,t){return new Rt(t).parse(e)}static parseInline(e,t){return new Rt(t).parseInline(e)}parse(e,t=!0){let n,r,s,i,o,a,c,l,u,d,p,f,h,m,g,b,y,w,v,$="";const k=e.length;for(n=0;n<k;n++)if(d=e[n],this.options.extensions&&this.options.extensions.renderers&&this.options.extensions.renderers[d.type]&&(v=this.options.extensions.renderers[d.type].call({parser:this},d),!1!==v||!["space","hr","heading","code","table","blockquote","list","html","paragraph","text"].includes(d.type)))$+=v||"";else switch(d.type){case"space":continue;case"hr":$+=this.renderer.hr();continue;case"heading":$+=this.renderer.heading(this.parseInline(d.tokens),d.depth,rt(this.parseInline(d.tokens,this.textRenderer)),this.slugger);continue;case"code":$+=this.renderer.code(d.text,d.lang,d.escaped);continue;case"table":for(l="",c="",i=d.header.length,r=0;r<i;r++)c+=this.renderer.tablecell(this.parseInline(d.header[r].tokens),{header:!0,align:d.align[r]});for(l+=this.renderer.tablerow(c),u="",i=d.rows.length,r=0;r<i;r++){for(a=d.rows[r],c="",o=a.length,s=0;s<o;s++)c+=this.renderer.tablecell(this.parseInline(a[s].tokens),{header:!1,align:d.align[s]});u+=this.renderer.tablerow(c)}$+=this.renderer.table(l,u);continue;case"blockquote":u=this.parse(d.tokens),$+=this.renderer.blockquote(u);continue;case"list":for(p=d.ordered,f=d.start,h=d.loose,i=d.items.length,u="",r=0;r<i;r++)g=d.items[r],b=g.checked,y=g.task,m="",g.task&&(w=this.renderer.checkbox(b),h?g.tokens.length>0&&"paragraph"===g.tokens[0].type?(g.tokens[0].text=w+" "+g.tokens[0].text,g.tokens[0].tokens&&g.tokens[0].tokens.length>0&&"text"===g.tokens[0].tokens[0].type&&(g.tokens[0].tokens[0].text=w+" "+g.tokens[0].tokens[0].text)):g.tokens.unshift({type:"text",text:w}):m+=w),m+=this.parse(g.tokens,h),u+=this.renderer.listitem(m,y,b);$+=this.renderer.list(u,p,f);continue;case"html":$+=this.renderer.html(d.text);continue;case"paragraph":$+=this.renderer.paragraph(this.parseInline(d.tokens));continue;case"text":for(u=d.tokens?this.parseInline(d.tokens):d.text;n+1<k&&"text"===e[n+1].type;)d=e[++n],u+="\n"+(d.tokens?this.parseInline(d.tokens):d.text);$+=t?this.renderer.paragraph(u):u;continue;default:{const e='Token with "'+d.type+'" type was not found.';if(this.options.silent)return void console.error(e);throw new Error(e)}}return $}parseInline(e,t){t=t||this.renderer;let n,r,s,i="";const o=e.length;for(n=0;n<o;n++)if(r=e[n],this.options.extensions&&this.options.extensions.renderers&&this.options.extensions.renderers[r.type]&&(s=this.options.extensions.renderers[r.type].call({parser:this},r),!1!==s||!["escape","html","link","image","strong","em","codespan","br","del","text"].includes(r.type)))i+=s||"";else switch(r.type){case"escape":case"text":i+=t.text(r.text);break;case"html":i+=t.html(r.text);break;case"link":i+=t.link(r.href,r.title,this.parseInline(r.tokens,t));break;case"image":i+=t.image(r.href,r.title,r.text);break;case"strong":i+=t.strong(this.parseInline(r.tokens,t));break;case"em":i+=t.em(this.parseInline(r.tokens,t));break;case"codespan":i+=t.codespan(r.text);break;case"br":i+=t.br();break;case"del":i+=t.del(this.parseInline(r.tokens,t));break;default:{const e='Token with "'+r.type+'" type was not found.';if(this.options.silent)return void console.error(e);throw new Error(e)}}return i}}class Et{constructor(e){this.options=e||Ye}static passThroughHooks=new Set(["preprocess","postprocess"]);preprocess(e){return e}postprocess(e){return e}}function At(e,t){return(n,r,s)=>{"function"==typeof r&&(s=r,r=null);const i={...r},o=function(e,t,n){return r=>{if(r.message+="\nPlease report this to https://github.com/markedjs/marked.",e){const e="<p>An error occurred:</p><pre>"+tt(r.message+"",!0)+"</pre>";return t?Promise.resolve(e):n?void n(null,e):e}if(t)return Promise.reject(r);if(!n)throw r;n(r)}}((r={...Tt.defaults,...i}).silent,r.async,s);if(null==n)return o(new Error("marked(): input parameter is undefined or null"));if("string"!=typeof n)return o(new Error("marked(): input parameter is of type "+Object.prototype.toString.call(n)+", string expected"));if(function(e){e&&e.sanitize&&!e.silent&&console.warn("marked(): sanitize and sanitizer parameters are deprecated since version 0.7.0, should not be used and will be removed in the future. Read more here: https://marked.js.org/#/USING_ADVANCED.md#options")}(r),r.hooks&&(r.hooks.options=r),s){const i=r.highlight;let a;try{r.hooks&&(n=r.hooks.preprocess(n)),a=e(n,r)}catch(e){return o(e)}const c=function(e){let n;if(!e)try{r.walkTokens&&Tt.walkTokens(a,r.walkTokens),n=t(a,r),r.hooks&&(n=r.hooks.postprocess(n))}catch(t){e=t}return r.highlight=i,e?o(e):s(null,n)};if(!i||i.length<3)return c();if(delete r.highlight,!a.length)return c();let l=0;return Tt.walkTokens(a,(function(e){"code"===e.type&&(l++,setTimeout((()=>{i(e.text,e.lang,(function(t,n){if(t)return c(t);null!=n&&n!==e.text&&(e.text=n,e.escaped=!0),l--,0===l&&c()}))}),0))})),void(0===l&&c())}if(r.async)return Promise.resolve(r.hooks?r.hooks.preprocess(n):n).then((t=>e(t,r))).then((e=>r.walkTokens?Promise.all(Tt.walkTokens(e,r.walkTokens)).then((()=>e)):e)).then((e=>t(e,r))).then((e=>r.hooks?r.hooks.postprocess(e):e)).catch(o);try{r.hooks&&(n=r.hooks.preprocess(n));const s=e(n,r);r.walkTokens&&Tt.walkTokens(s,r.walkTokens);let i=t(s,r);return r.hooks&&(i=r.hooks.postprocess(i)),i}catch(e){return o(e)}}}function Tt(e,t,n){return At(xt.lex,Rt.parse)(e,t,n)}Tt.options=Tt.setOptions=function(e){var t;return Tt.defaults={...Tt.defaults,...e},t=Tt.defaults,Ye=t,Tt},Tt.getDefaults=Ve,Tt.defaults=Ye,Tt.use=function(...e){const t=Tt.defaults.extensions||{renderers:{},childTokens:{}};e.forEach((e=>{const n={...e};if(n.async=Tt.defaults.async||n.async||!1,e.extensions&&(e.extensions.forEach((e=>{if(!e.name)throw new Error("extension name required");if(e.renderer){const n=t.renderers[e.name];t.renderers[e.name]=n?function(...t){let r=e.renderer.apply(this,t);return!1===r&&(r=n.apply(this,t)),r}:e.renderer}if(e.tokenizer){if(!e.level||"block"!==e.level&&"inline"!==e.level)throw new Error("extension level must be 'block' or 'inline'");t[e.level]?t[e.level].unshift(e.tokenizer):t[e.level]=[e.tokenizer],e.start&&("block"===e.level?t.startBlock?t.startBlock.push(e.start):t.startBlock=[e.start]:"inline"===e.level&&(t.startInline?t.startInline.push(e.start):t.startInline=[e.start]))}e.childTokens&&(t.childTokens[e.name]=e.childTokens)})),n.extensions=t),e.renderer){const t=Tt.defaults.renderer||new _t;for(const n in e.renderer){const r=t[n];t[n]=(...s)=>{let i=e.renderer[n].apply(t,s);return!1===i&&(i=r.apply(t,s)),i}}n.renderer=t}if(e.tokenizer){const t=Tt.defaults.tokenizer||new yt;for(const n in e.tokenizer){const r=t[n];t[n]=(...s)=>{let i=e.tokenizer[n].apply(t,s);return!1===i&&(i=r.apply(t,s)),i}}n.tokenizer=t}if(e.hooks){const t=Tt.defaults.hooks||new Et;for(const n in e.hooks){const r=t[n];Et.passThroughHooks.has(n)?t[n]=s=>{if(Tt.defaults.async)return Promise.resolve(e.hooks[n].call(t,s)).then((e=>r.call(t,e)));const i=e.hooks[n].call(t,s);return r.call(t,i)}:t[n]=(...s)=>{let i=e.hooks[n].apply(t,s);return!1===i&&(i=r.apply(t,s)),i}}n.hooks=t}if(e.walkTokens){const t=Tt.defaults.walkTokens;n.walkTokens=function(n){let r=[];return r.push(e.walkTokens.call(this,n)),t&&(r=r.concat(t.call(this,n))),r}}Tt.setOptions(n)}))},Tt.walkTokens=function(e,t){let n=[];for(const r of e)switch(n=n.concat(t.call(Tt,r)),r.type){case"table":for(const e of r.header)n=n.concat(Tt.walkTokens(e.tokens,t));for(const e of r.rows)for(const r of e)n=n.concat(Tt.walkTokens(r.tokens,t));break;case"list":n=n.concat(Tt.walkTokens(r.items,t));break;default:Tt.defaults.extensions&&Tt.defaults.extensions.childTokens&&Tt.defaults.extensions.childTokens[r.type]?Tt.defaults.extensions.childTokens[r.type].forEach((function(e){n=n.concat(Tt.walkTokens(r[e],t))})):r.tokens&&(n=n.concat(Tt.walkTokens(r.tokens,t)))}return n},Tt.parseInline=At(xt.lexInline,Rt.parseInline),Tt.Parser=Rt,Tt.parser=Rt.parse,Tt.Renderer=_t,Tt.TextRenderer=Ct,Tt.Lexer=xt,Tt.lexer=xt.lex,Tt.Tokenizer=yt,Tt.Slugger=St,Tt.Hooks=Et,Tt.parse=Tt,Tt.options,Tt.setOptions,Tt.use,Tt.walkTokens,Tt.parseInline;"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self&&self;function Lt(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Pt,It={exports:{}};Pt=It,function(e,t){Pt.exports=t()}(0,(function(){var e=[],t=[],n={},r={},s={};function i(e){return"string"==typeof e?new RegExp("^"+e+"$","i"):e}function o(e,t){return e===t?t:e===e.toLowerCase()?t.toLowerCase():e===e.toUpperCase()?t.toUpperCase():e[0]===e[0].toUpperCase()?t.charAt(0).toUpperCase()+t.substr(1).toLowerCase():t.toLowerCase()}function a(e,t){return e.replace(/\$(\d{1,2})/g,(function(e,n){return t[n]||""}))}function c(e,t){return e.replace(t[0],(function(n,r){var s=a(t[1],arguments);return o(""===n?e[r-1]:n,s)}))}function l(e,t,r){if(!e.length||n.hasOwnProperty(e))return t;for(var s=r.length;s--;){var i=r[s];if(i[0].test(t))return c(t,i)}return t}function u(e,t,n){return function(r){var s=r.toLowerCase();return t.hasOwnProperty(s)?o(r,s):e.hasOwnProperty(s)?o(r,e[s]):l(s,r,n)}}function d(e,t,n,r){return function(r){var s=r.toLowerCase();return!!t.hasOwnProperty(s)||!e.hasOwnProperty(s)&&l(s,s,n)===s}}function p(e,t,n){return(n?t+" ":"")+(1===t?p.singular(e):p.plural(e))}return p.plural=u(s,r,e),p.isPlural=d(s,r,e),p.singular=u(r,s,t),p.isSingular=d(r,s,t),p.addPluralRule=function(t,n){e.push([i(t),n])},p.addSingularRule=function(e,n){t.push([i(e),n])},p.addUncountableRule=function(e){"string"!=typeof e?(p.addPluralRule(e,"$0"),p.addSingularRule(e,"$0")):n[e.toLowerCase()]=!0},p.addIrregularRule=function(e,t){t=t.toLowerCase(),e=e.toLowerCase(),s[e]=t,r[t]=e},[["I","we"],["me","us"],["he","they"],["she","they"],["them","them"],["myself","ourselves"],["yourself","yourselves"],["itself","themselves"],["herself","themselves"],["himself","themselves"],["themself","themselves"],["is","are"],["was","were"],["has","have"],["this","these"],["that","those"],["echo","echoes"],["dingo","dingoes"],["volcano","volcanoes"],["tornado","tornadoes"],["torpedo","torpedoes"],["genus","genera"],["viscus","viscera"],["stigma","stigmata"],["stoma","stomata"],["dogma","dogmata"],["lemma","lemmata"],["schema","schemata"],["anathema","anathemata"],["ox","oxen"],["axe","axes"],["die","dice"],["yes","yeses"],["foot","feet"],["eave","eaves"],["goose","geese"],["tooth","teeth"],["quiz","quizzes"],["human","humans"],["proof","proofs"],["carve","carves"],["valve","valves"],["looey","looies"],["thief","thieves"],["groove","grooves"],["pickaxe","pickaxes"],["passerby","passersby"]].forEach((function(e){return p.addIrregularRule(e[0],e[1])})),[[/s?$/i,"s"],[/[^\u0000-\u007F]$/i,"$0"],[/([^aeiou]ese)$/i,"$1"],[/(ax|test)is$/i,"$1es"],[/(alias|[^aou]us|t[lm]as|gas|ris)$/i,"$1es"],[/(e[mn]u)s?$/i,"$1s"],[/([^l]ias|[aeiou]las|[ejzr]as|[iu]am)$/i,"$1"],[/(alumn|syllab|vir|radi|nucle|fung|cact|stimul|termin|bacill|foc|uter|loc|strat)(?:us|i)$/i,"$1i"],[/(alumn|alg|vertebr)(?:a|ae)$/i,"$1ae"],[/(seraph|cherub)(?:im)?$/i,"$1im"],[/(her|at|gr)o$/i,"$1oes"],[/(agend|addend|millenni|dat|extrem|bacteri|desiderat|strat|candelabr|errat|ov|symposi|curricul|automat|quor)(?:a|um)$/i,"$1a"],[/(apheli|hyperbat|periheli|asyndet|noumen|phenomen|criteri|organ|prolegomen|hedr|automat)(?:a|on)$/i,"$1a"],[/sis$/i,"ses"],[/(?:(kni|wi|li)fe|(ar|l|ea|eo|oa|hoo)f)$/i,"$1$2ves"],[/([^aeiouy]|qu)y$/i,"$1ies"],[/([^ch][ieo][ln])ey$/i,"$1ies"],[/(x|ch|ss|sh|zz)$/i,"$1es"],[/(matr|cod|mur|sil|vert|ind|append)(?:ix|ex)$/i,"$1ices"],[/\b((?:tit)?m|l)(?:ice|ouse)$/i,"$1ice"],[/(pe)(?:rson|ople)$/i,"$1ople"],[/(child)(?:ren)?$/i,"$1ren"],[/eaux$/i,"$0"],[/m[ae]n$/i,"men"],["thou","you"]].forEach((function(e){return p.addPluralRule(e[0],e[1])})),[[/s$/i,""],[/(ss)$/i,"$1"],[/(wi|kni|(?:after|half|high|low|mid|non|night|[^\w]|^)li)ves$/i,"$1fe"],[/(ar|(?:wo|[ae])l|[eo][ao])ves$/i,"$1f"],[/ies$/i,"y"],[/\b([pl]|zomb|(?:neck|cross)?t|coll|faer|food|gen|goon|group|lass|talk|goal|cut)ies$/i,"$1ie"],[/\b(mon|smil)ies$/i,"$1ey"],[/\b((?:tit)?m|l)ice$/i,"$1ouse"],[/(seraph|cherub)im$/i,"$1"],[/(x|ch|ss|sh|zz|tto|go|cho|alias|[^aou]us|t[lm]as|gas|(?:her|at|gr)o|[aeiou]ris)(?:es)?$/i,"$1"],[/(analy|diagno|parenthe|progno|synop|the|empha|cri|ne)(?:sis|ses)$/i,"$1sis"],[/(movie|twelve|abuse|e[mn]u)s$/i,"$1"],[/(test)(?:is|es)$/i,"$1is"],[/(alumn|syllab|vir|radi|nucle|fung|cact|stimul|termin|bacill|foc|uter|loc|strat)(?:us|i)$/i,"$1us"],[/(agend|addend|millenni|dat|extrem|bacteri|desiderat|strat|candelabr|errat|ov|symposi|curricul|quor)a$/i,"$1um"],[/(apheli|hyperbat|periheli|asyndet|noumen|phenomen|criteri|organ|prolegomen|hedr|automat)a$/i,"$1on"],[/(alumn|alg|vertebr)ae$/i,"$1a"],[/(cod|mur|sil|vert|ind)ices$/i,"$1ex"],[/(matr|append)ices$/i,"$1ix"],[/(pe)(rson|ople)$/i,"$1rson"],[/(child)ren$/i,"$1"],[/(eau)x?$/i,"$1"],[/men$/i,"man"]].forEach((function(e){return p.addSingularRule(e[0],e[1])})),["adulthood","advice","agenda","aid","aircraft","alcohol","ammo","analytics","anime","athletics","audio","bison","blood","bream","buffalo","butter","carp","cash","chassis","chess","clothing","cod","commerce","cooperation","corps","debris","diabetes","digestion","elk","energy","equipment","excretion","expertise","firmware","flounder","fun","gallows","garbage","graffiti","hardware","headquarters","health","herpes","highjinks","homework","housework","information","jeans","justice","kudos","labour","literature","machinery","mackerel","mail","media","mews","moose","music","mud","manga","news","only","personnel","pike","plankton","pliers","police","pollution","premises","rain","research","rice","salmon","scissors","series","sewage","shambles","shrimp","software","species","staff","swine","tennis","traffic","transportation","trout","tuna","wealth","welfare","whiting","wildebeest","wildlife","you",/pok[eé]mon$/i,/[^aeiou]ese$/i,/deer$/i,/fish$/i,/measles$/i,/o[iu]s$/i,/pox$/i,/sheep$/i].forEach(p.addUncountableRule),p}));var Dt=Lt(It.exports),Nt=function(e){var t={};try{t.WeakMap=WeakMap}catch(u){t.WeakMap=function(e,t){var n=t.defineProperty,r=t.hasOwnProperty,s=i.prototype;return s.delete=function(e){return this.has(e)&&delete e[this._]},s.get=function(e){return this.has(e)?e[this._]:void 0},s.has=function(e){return r.call(e,this._)},s.set=function(e,t){return n(e,this._,{configurable:!0,value:t}),this},i;function i(t){n(this,"_",{value:"_@ungap/weakmap"+e++}),t&&t.forEach(o,this)}function o(e){this.set(e[0],e[1])}}(Math.random(),Object)}var n=t.WeakMap,r={};try{r.WeakSet=WeakSet}catch(u){!function(e,t){var n=s.prototype;function s(){t(this,"_",{value:"_@ungap/weakmap"+e++})}n.add=function(e){return this.has(e)||t(e,this._,{value:!0,configurable:!0}),this},n.has=function(e){return this.hasOwnProperty.call(e,this._)},n.delete=function(e){return this.has(e)&&delete e[this._]},r.WeakSet=s}(Math.random(),Object.defineProperty)}function s(e,t,n,r,s,i){for(var o=("selectedIndex"in t),a=o;r<s;){var c,l=e(n[r],1);t.insertBefore(l,i),o&&a&&l.selected&&(a=!a,c=t.selectedIndex,t.selectedIndex=c<0?r:d.call(t.querySelectorAll("option"),l)),r++}}function i(e,t){return e==t}function o(e){return e}function a(e,t,n,r,s,i,o){var a=i-s;if(a<1)return-1;for(;a<=n-t;){for(var c=t,l=s;c<n&&l<i&&o(e[c],r[l]);)c++,l++;if(l===i)return t;t=c+1}return-1}function c(e,t,n,r,s){return n<r?e(t[n],0):0<n?e(t[n-1],-0).nextSibling:s}function l(e,t,n,r){for(;n<r;)f(e(t[n++],-1))}var u=r.WeakSet,d=[].indexOf,p=function(e,t,n){for(var r=1,s=t;r<s;){var i=(r+s)/2>>>0;n<e[i]?s=i:r=1+i}return r},f=function(e){return(e.remove||function(){var e=this.parentNode;e&&e.removeChild(this)}).call(e)};function h(e,t,n,r){for(var u=(r=r||{}).compare||i,d=r.node||o,f=null==r.before?null:d(r.before,0),h=t.length,m=h,g=0,b=n.length,y=0;g<m&&y<b&&u(t[g],n[y]);)g++,y++;for(;g<m&&y<b&&u(t[m-1],n[b-1]);)m--,b--;var w=g===m,v=y===b;if(w&&v)return n;if(w&&y<b)return s(d,e,n,y,b,c(d,t,g,h,f)),n;if(v&&g<m)return l(d,t,g,m),n;var $=m-g,k=b-y,x=-1;if($<k){if(-1<(x=a(n,y,b,t,g,m,u)))return s(d,e,n,y,x,d(t[g],0)),s(d,e,n,x+$,b,c(d,t,m,h,f)),n}else if(k<$&&-1<(x=a(t,g,m,n,y,b,u)))return l(d,t,g,x),l(d,t,x+k,m),n;return $<2||k<2?(s(d,e,n,y,b,d(t[g],0)),l(d,t,g,m)):$==k&&function(e,t,n,r,s,i){for(;r<s&&i(n[r],e[t-1]);)r++,t--;return 0===t}(n,b,t,g,m,u)?s(d,e,n,y,b,c(d,t,m,h,f)):function(e,t,n,r,i,o,a,c,u,d,f,h,m){!function(e,t,n,r,i,o,a,c,u){for(var d=[],p=e.length,f=a,h=0;h<p;)switch(e[h++]){case 0:i++,f++;break;case 1:d.push(r[i]),s(t,n,r,i++,i,f<c?t(o[f],0):u);break;case-1:f++}for(h=0;h<p;)switch(e[h++]){case 0:a++;break;case-1:-1<d.indexOf(o[a])?a++:l(t,o,a++,a)}}(function(e,t,n,r,s,i,o){var a,c,l,u,d,p,f=n+i,h=[];e:for(b=0;b<=f;b++){if(50<b)return null;for(p=b-1,u=b?h[b-1]:[0,0],d=h[b]=[],a=-b;a<=b;a+=2){for(c=(l=a===-b||a!==b&&u[p+a-1]<u[p+a+1]?u[p+a+1]:u[p+a-1]+1)-a;l<i&&c<n&&o(r[s+l],e[t+c]);)l++,c++;if(l===i&&c===n)break e;d[b+a]=l}}for(var m=Array(b/2+f/2),g=m.length-1,b=h.length-1;0<=b;b--){for(;0<l&&0<c&&o(r[s+l-1],e[t+c-1]);)m[g--]=0,l--,c--;if(!b)break;p=b-1,u=b?h[b-1]:[0,0],(a=l-c)==-b||a!==b&&u[p+a-1]<u[p+a+1]?(c--,m[g--]=1):(l--,m[g--]=-1)}return m}(n,r,o,a,c,d,h)||function(e,t,n,r,s,i,o,a){var c=0,l=r<a?r:a,u=Array(l++),d=Array(l);d[0]=-1;for(var f=1;f<l;f++)d[f]=o;for(var h=s.slice(i,o),m=t;m<n;m++){var g,b=h.indexOf(e[m]);-1<b&&-1<(c=p(d,l,g=b+i))&&(d[c]=g,u[c]={newi:m,oldi:g,prev:u[c-1]})}for(c=--l,--o;d[c]>o;)--c;l=a+r-c;var y=Array(l),w=u[c];for(--n;w;){for(var v=w.newi,$=w.oldi;v<n;)y[--l]=1,--n;for(;$<o;)y[--l]=-1,--o;y[--l]=0,--n,--o,w=w.prev}for(;t<=n;)y[--l]=1,--n;for(;i<=o;)y[--l]=-1,--o;return y}(n,r,i,o,a,c,u,d),e,t,n,r,a,c,f,m)}(d,e,n,y,b,k,t,g,m,$,h,u,f),n}var m={};function g(t,n){n=n||{};var r=e.createEvent("CustomEvent");return r.initCustomEvent(t,!!n.bubbles,!!n.cancelable,n.detail),r}m.CustomEvent="function"==typeof CustomEvent?CustomEvent:(g["prototype"]=new g("").constructor.prototype,g);var b=m.CustomEvent,y={};try{y.Map=Map}catch(u){y.Map=function(){var e=0,t=[],n=[];return{delete:function(s){var i=r(s);return i&&(t.splice(e,1),n.splice(e,1)),i},forEach:function(e,r){t.forEach((function(t,s){e.call(r,n[s],t,this)}),this)},get:function(t){return r(t)?n[e]:void 0},has:r,set:function(s,i){return n[r(s)?e:t.push(s)-1]=i,this}};function r(n){return-1<(e=t.indexOf(n))}}}var w=y.Map;function v(){return this}function $(e,t){var n="_"+e+"$";return{get:function(){return this[n]||k(this,n,t.call(this,e))},set:function(e){k(this,n,e)}}}var k=function(e,t,n){return Object.defineProperty(e,t,{configurable:!0,value:"function"==typeof n?function(){return e._wire$=n.apply(this,arguments)}:n})[t]};Object.defineProperties(v.prototype,{ELEMENT_NODE:{value:1},nodeType:{value:-1}});var x,_,C,S,R,E,A={},T={},L=[],P=T.hasOwnProperty,I=0,D={attributes:A,define:function(e,t){e.indexOf("-")<0?(e in T||(I=L.push(e)),T[e]=t):A[e]=t},invoke:function(e,t){for(var n=0;n<I;n++){var r=L[n];if(P.call(e,r))return T[r](e[r],t)}}},N=Array.isArray||(_=(x={}.toString).call([]),function(e){return x.call(e)===_}),O=(C=e,S="fragment",E="content"in M(R="template")?function(e){var t=M(R);return t.innerHTML=e,t.content}:function(e){var t,n=M(S),r=M(R);return j(n,/^[^\S]*?<(col(?:group)?|t(?:head|body|foot|r|d|h))/i.test(e)?(t=RegExp.$1,r.innerHTML="<table>"+e+"</table>",r.querySelectorAll(t)):(r.innerHTML=e,r.childNodes)),n},function(e,t){return("svg"===t?function(e){var t=M(S),n=M("div");return n.innerHTML='<svg xmlns="http://www.w3.org/2000/svg">'+e+"</svg>",j(t,n.firstChild.childNodes),t}:E)(e)});function j(e,t){for(var n=t.length;n--;)e.appendChild(t[0])}function M(e){return e===S?C.createDocumentFragment():C.createElementNS("http://www.w3.org/1999/xhtml",e)}var z,U,q,W,F,B,H,G,V,Y=(U="appendChild",q="cloneNode",W="createTextNode",B=(F="importNode")in(z=e),(H=z.createDocumentFragment())[U](z[W]("g")),H[U](z[W]("")),(B?z[F](H,!0):H[q](!0)).childNodes.length<2?function e(t,n){for(var r=t[q](),s=t.childNodes||[],i=s.length,o=0;n&&o<i;o++)r[U](e(s[o],n));return r}:B?z[F]:function(e,t){return e[q](!!t)}),K="".trim||function(){return String(this).replace(/^\s+|\s+/g,"")},Z="-"+Math.random().toFixed(6)+"%",J=!1;try{G=e.createElement("template"),V="tabindex","content"in G&&(G.innerHTML="<p "+V+'="'+Z+'"></p>',G.content.childNodes[0].getAttribute(V)==Z)||(Z="_dt: "+Z.slice(1,-1)+";",J=!0)}catch(u){}var X="\x3c!--"+Z+"--\x3e",Q=/^(?:style|textarea)$/i,ee=/^(?:area|base|br|col|embed|hr|img|input|keygen|link|menuitem|meta|param|source|track|wbr)$/i,te=" \\f\\n\\r\\t",ne="[^"+te+"\\/>\"'=]+",re="["+te+"]+"+ne,se="<([A-Za-z]+[A-Za-z0-9:._-]*)((?:",ie="(?:\\s*=\\s*(?:'[^']*?'|\"[^\"]*?\"|<[^>]*?>|"+ne.replace("\\/","")+"))?)",oe=new RegExp(se+re+ie+"+)(["+te+"]*/?>)","g"),ae=new RegExp(se+re+ie+"*)(["+te+"]*/>)","g"),ce=new RegExp("("+re+"\\s*=\\s*)(['\"]?)"+X+"\\2","gi");function le(e,t,n,r){return"<"+t+n.replace(ce,ue)+r}function ue(e,t,n){return t+(n||'"')+Z+(n||'"')}function de(e,t,n){return ee.test(t)?e:"<"+t+n+"></"+t+">"}var pe=J?function(e,t){var n=t.join(" ");return t.slice.call(e,0).sort((function(e,t){return n.indexOf(e.name)<=n.indexOf(t.name)?-1:1}))}:function(e,t){return t.slice.call(e,0)};function fe(t,n,r,s){for(var i=t.childNodes,o=i.length,a=0;a<o;){var c=i[a];switch(c.nodeType){case 1:var l=s.concat(a);!function(t,n,r,s){for(var i,o=t.attributes,a=[],c=[],l=pe(o,r),u=l.length,d=0;d<u;){var p=l[d++],f=p.value===Z;if(f||1<(i=p.value.split(X)).length){var h=p.name;if(a.indexOf(h)<0){a.push(h);var m=r.shift().replace(f?/^(?:|[\S\s]*?\s)(\S+?)\s*=\s*('|")?$/:new RegExp("^(?:|[\\S\\s]*?\\s)("+h+")\\s*=\\s*('|\")[\\S\\s]*","i"),"$1"),g=o[m]||o[m.toLowerCase()];if(f)n.push(he(g,s,m,null));else{for(var b=i.length-2;b--;)r.shift();n.push(he(g,s,m,i))}}c.push(p)}}for(var y=((d=0)<(u=c.length)&&J&&!("ownerSVGElement"in t));d<u;){var w=c[d++];y&&(w.value=""),t.removeAttribute(w.name)}var v=t.nodeName;if(/^script$/i.test(v)){var $=e.createElement(v);for(u=o.length,d=0;d<u;)$.setAttributeNode(o[d++].cloneNode(!0));$.textContent=t.textContent,t.parentNode.replaceChild($,t)}}(c,n,r,l),fe(c,n,r,l);break;case 8:var u=c.textContent;if(u===Z)r.shift(),n.push(Q.test(t.nodeName)?me(t,s):{type:"any",node:c,path:s.concat(a)});else switch(u.slice(0,2)){case"/*":if("*/"!==u.slice(-2))break;case"👻":t.removeChild(c),a--,o--}break;case 3:Q.test(t.nodeName)&&K.call(c.textContent)===X&&(r.shift(),n.push(me(t,s)))}a++}}function he(e,t,n,r){return{type:"attr",node:e,path:t,name:n,sparse:r}}function me(e,t){return{type:"text",node:e,path:t}}var ge,be=(ge=new n,{get:function(e){return ge.get(e)},set:function(e,t){return ge.set(e,t),t}});function ye(e,t){var n=(e.convert||function(e){return e.join(X).replace(ae,de).replace(oe,le)})(t),r=e.transform;r&&(n=r(n));var s=O(n,e.type);ve(s);var i=[];return fe(s,i,t.slice(0),[]),{content:s,updates:function(n){for(var r=[],s=i.length,o=0,a=0;o<s;){var c=i[o++],l=function(e,t){for(var n=t.length,r=0;r<n;)e=e.childNodes[t[r++]];return e}(n,c.path);switch(c.type){case"any":r.push({fn:e.any(l,[]),sparse:!1});break;case"attr":var u=c.sparse,d=e.attribute(l,c.name,c.node);null===u?r.push({fn:d,sparse:!1}):(a+=u.length-2,r.push({fn:d,sparse:!0,values:u}));break;case"text":r.push({fn:e.text(l),sparse:!1}),l.textContent=""}}return s+=a,function(){var e=arguments.length;if(s!==e-1)throw new Error(e-1+" values instead of "+s+"\n"+t.join("${value}"));for(var i=1,o=1;i<e;){var a=r[i-o];if(a.sparse){var c=a.values,l=c[0],u=1,d=c.length;for(o+=d-2;u<d;)l+=arguments[i++]+c[u++];a.fn(l)}else a.fn(arguments[i++])}return n}}}}var we=[];function ve(e){for(var t=e.childNodes,n=t.length;n--;){var r=t[n];1!==r.nodeType&&0===K.call(r.textContent).length&&e.removeChild(r)}}var $e,ke,xe=($e=/acit|ex(?:s|g|n|p|$)|rph|ows|mnc|ntw|ine[ch]|zoo|^ord/i,ke=/([^A-Z])([A-Z]+)/g,function(e,t){return"ownerSVGElement"in e?function(e,t){var n;return(n=t?t.cloneNode(!0):(e.setAttribute("style","--hyper:style;"),e.getAttributeNode("style"))).value="",e.setAttributeNode(n),Ce(n,!0)}(e,t):Ce(e.style,!1)});function _e(e,t,n){return t+"-"+n.toLowerCase()}function Ce(e,t){var n,r;return function(s){var i,o,a,c;switch(typeof s){case"object":if(s){if("object"===n){if(!t&&r!==s)for(o in r)o in s||(e[o]="")}else t?e.value="":e.cssText="";for(o in i=t?{}:e,s)a="number"!=typeof(c=s[o])||$e.test(o)?c:c+"px",!t&&/^--/.test(o)?i.setProperty(o,a):i[o]=a;n="object",t?e.value=function(e){var t,n=[];for(t in e)n.push(t.replace(ke,_e),":",e[t],";");return n.join("")}(r=i):r=s;break}default:r!=s&&(n="string",r=s,t?e.value=s||"":e.cssText=s||"")}}}var Se,Re,Ee=(Se=[].slice,(Re=Ae.prototype).ELEMENT_NODE=1,Re.nodeType=111,Re.remove=function(e){var t,n=this.childNodes,r=this.firstChild,s=this.lastChild;return this._=null,e&&2===n.length?s.parentNode.removeChild(s):((t=this.ownerDocument.createRange()).setStartBefore(e?n[1]:r),t.setEndAfter(s),t.deleteContents()),r},Re.valueOf=function(e){var t=this._,n=null==t;if(n&&(t=this._=this.ownerDocument.createDocumentFragment()),n||e)for(var r=this.childNodes,s=0,i=r.length;s<i;s++)t.appendChild(r[s]);return t},Ae);function Ae(e){var t=this.childNodes=Se.call(e,0);this.firstChild=t[0],this.lastChild=t[t.length-1],this.ownerDocument=t[0].ownerDocument,this._=null}function Te(e){return{html:e}}function Le(e,t){switch(e.nodeType){case qe:return 1/t<0?t?e.remove(!0):e.lastChild:t?e.valueOf(!0):e.firstChild;case Ue:return Le(e.render(),t);default:return e}}function Pe(e,t){t(e.placeholder),"text"in e?Promise.resolve(e.text).then(String).then(t):"any"in e?Promise.resolve(e.any).then(t):"html"in e?Promise.resolve(e.html).then(Te).then(t):Promise.resolve(D.invoke(e,t)).then(t)}function Ie(e){return null!=e&&"then"in e}var De,Ne,Oe,je,Me,ze="ownerSVGElement",Ue=v.prototype.nodeType,qe=Ee.prototype.nodeType,We=(Ne=(De={Event:b,WeakSet:u}).Event,Oe=De.WeakSet,je=!0,Me=null,function(e){return je&&(je=!je,Me=new Oe,function(e){var t=new Oe,n=new Oe;try{new MutationObserver(o).observe(e,{subtree:!0,childList:!0})}catch(t){var r=0,s=[],i=function(e){s.push(e),clearTimeout(r),r=setTimeout((function(){o(s.splice(r=0,s.length))}),0)};e.addEventListener("DOMNodeRemoved",(function(e){i({addedNodes:[],removedNodes:[e.target]})}),!0),e.addEventListener("DOMNodeInserted",(function(e){i({addedNodes:[e.target],removedNodes:[]})}),!0)}function o(e){for(var r,s=e.length,i=0;i<s;i++)a((r=e[i]).removedNodes,"disconnected",n,t),a(r.addedNodes,"connected",t,n)}function a(e,t,n,r){for(var s,i=new Ne(t),o=e.length,a=0;a<o;1===(s=e[a++]).nodeType&&function e(t,n,r,s,i){Me.has(t)&&!s.has(t)&&(i.delete(t),s.add(t),t.dispatchEvent(n));for(var o=t.children||[],a=o.length,c=0;c<a;e(o[c++],n,r,s,i));}(s,i,t,n,r));}}(e.ownerDocument)),Me.add(e),e}),Fe=/^(?:form|list)$/i,Be=[].slice;function He(t){return this.type=t,function(t){var n=we,r=ve;return function(s){var i,o,a;return n!==s&&(i=t,o=n=s,a=be.get(o)||be.set(o,ye(i,o)),r=a.updates(Y.call(e,a.content,!0))),r.apply(null,arguments)}}(this)}var Ge=!(He.prototype={attribute:function(e,t,n){var r,s=ze in e;if("style"===t)return xe(e,n,s);if("."===t.slice(0,1))return l=e,u=t.slice(1),s?function(e){try{l[u]=e}catch(t){l.setAttribute(u,e)}}:function(e){l[u]=e};if("?"===t.slice(0,1))return o=e,a=t.slice(1),function(e){c!==!!e&&((c=!!e)?o.setAttribute(a,""):o.removeAttribute(a))};if(/^on/.test(t)){var i=t.slice(2);return"connected"===i||"disconnected"===i?We(e):t.toLowerCase()in e&&(i=i.toLowerCase()),function(t){r!==t&&(r&&e.removeEventListener(i,r,!1),(r=t)&&e.addEventListener(i,t,!1))}}if("data"===t||!s&&t in e&&!Fe.test(t))return function(n){r!==n&&(r=n,e[t]!==n&&null==n?(e[t]="",e.removeAttribute(t)):e[t]=n)};if(t in D.attributes)return function(n){var s=D.attributes[t](e,n);r!==s&&(null==(r=s)?e.removeAttribute(t):e.setAttribute(t,s))};var o,a,c,l,u,d=!1,p=n.cloneNode(!0);return function(t){r!==t&&(r=t,p.value!==t&&(null==t?(d&&(d=!1,e.removeAttributeNode(p)),p.value=t):(p.value=t,d||(d=!0,e.setAttributeNode(p)))))}},any:function(e,t){var n,r={node:Le,before:e},s=ze in e?"svg":"html",i=!1;return function o(a){switch(typeof a){case"string":case"number":case"boolean":i?n!==a&&(n=a,t[0].textContent=a):(i=!0,n=a,t=h(e.parentNode,t,[(c=a,e.ownerDocument.createTextNode(c))],r));break;case"function":o(a(e));break;case"object":case"undefined":if(null==a){i=!1,t=h(e.parentNode,t,[],r);break}default:if(i=!1,N(n=a))if(0===a.length)t.length&&(t=h(e.parentNode,t,[],r));else switch(typeof a[0]){case"string":case"number":case"boolean":o({html:a});break;case"object":if(N(a[0])&&(a=a.concat.apply([],a)),Ie(a[0])){Promise.all(a).then(o);break}default:t=h(e.parentNode,t,a,r)}else"ELEMENT_NODE"in a?t=h(e.parentNode,t,11===a.nodeType?Be.call(a.childNodes):[a],r):Ie(a)?a.then(o):"placeholder"in a?Pe(a,o):"text"in a?o(String(a.text)):"any"in a?o(a.any):"html"in a?t=h(e.parentNode,t,Be.call(O([].concat(a.html).join(""),s).childNodes),r):o("length"in a?Be.call(a):D.invoke(a,o))}var c}},text:function(e){var t;return function n(r){var s;t!==r&&("object"==(s=typeof(t=r))&&r?Ie(r)?r.then(n):"placeholder"in r?Pe(r,n):n("text"in r?String(r.text):"any"in r?r.any:"html"in r?[].concat(r.html).join(""):"length"in r?Be.call(r).join(""):D.invoke(r,n)):"function"==s?n(r(e)):e.textContent=null==r?"":r)}}}),Ve=function(t){var r,s,i,o,a=(r=(e.defaultView.navigator||{}).userAgent,/(Firefox|Safari)\/(\d+)/.test(r)&&!/(Chrom[eium]+|Android)\/(\d+)/.test(r)),c=!("raw"in t)||t.propertyIsEnumerable("raw")||!Object.isFrozen(t.raw);return a||c?(s={},i=function(e){for(var t=".",n=0;n<e.length;n++)t+=e[n].length+"."+e[n];return s[t]||(s[t]=e)},Ve=c?i:(o=new n,function(e){return o.get(e)||(n=i(t=e),o.set(t,n),n);var t,n})):Ge=!0,Ye(t)};function Ye(e){return Ge?e:Ve(e)}function Ke(e){for(var t=arguments.length,n=[Ye(e)],r=1;r<t;)n.push(arguments[r++]);return n}var Ze=new n,Je=function(e){var t,n,r;return function(){var s=Ke.apply(null,arguments);return r!==s[0]?(r=s[0],n=new He(e),t=Qe(n.apply(n,s))):n.apply(n,s),t}},Xe=function(e,t){var n=t.indexOf(":"),r=Ze.get(e),s=t;return-1<n&&(s=t.slice(n+1),t=t.slice(0,n)||"html"),r||Ze.set(e,r={}),r[s]||(r[s]=Je(t))},Qe=function(e){var t=e.childNodes,n=t.length;return 1===n?t[0]:n?new Ee(t):e},et=new n;function tt(){var e=et.get(this),t=Ke.apply(null,arguments);return e&&e.template===t[0]?e.tagger.apply(null,t):function(e){var t=new He(ze in this?"svg":"html");et.set(this,{tagger:t,template:e}),this.textContent="",this.appendChild(t.apply(null,arguments))}.apply(this,t),this}var nt,rt,st,it,ot=D.define,at=He.prototype;function ct(e){return arguments.length<2?null==e?Je("html"):"string"==typeof e?ct.wire(null,e):"raw"in e?Je("html")(e):"nodeType"in e?ct.bind(e):Xe(e,"html"):("raw"in e?Je("html"):ct.wire).apply(null,arguments)}return ct.Component=v,ct.bind=function(e){return tt.bind(e)},ct.define=ot,ct.diff=h,(ct.hyper=ct).observe=We,ct.tagger=at,ct.wire=function(e,t){return null==e?Je(t||"html"):Xe(e,t||"html")},ct._={WeakMap:n,WeakSet:u},nt=Je,rt=new n,st=Object.create,it=function(e,t){var n={w:null,p:null};return t.set(e,n),n},Object.defineProperties(v,{for:{configurable:!0,value:function(e,t){return function(e,t,r,s){var i,o,a,c=t.get(e)||it(e,t);switch(typeof s){case"object":case"function":var l=c.w||(c.w=new n);return l.get(s)||(i=l,o=s,a=new e(r),i.set(o,a),a);default:var u=c.p||(c.p=st(null));return u[s]||(u[s]=new e(r))}}(this,rt.get(e)||(r=e,s=new w,rt.set(r,s),s),e,null==t?"default":t);var r,s}}}),Object.defineProperties(v.prototype,{handleEvent:{value:function(e){var t=e.currentTarget;this["getAttribute"in t&&t.getAttribute("data-call")||"on"+e.type](e)}},html:$("html",nt),svg:$("svg",nt),state:$("state",(function(){return this.defaultState})),defaultState:{get:function(){return{}}},dispatch:{value:function(e,t){var n=this._wire$;if(n){var r=new b(e,{bubbles:!0,cancelable:!0,detail:t});return r.component=this,(n.dispatchEvent?n:n.firstChild).dispatchEvent(r)}return!1}},setState:{value:function(e,t){var n=this.state,r="function"==typeof e?e.call(this,n):e;for(var s in r)n[s]=r[s];return!1!==t&&this.render(),this}}}),ct}(document);const Ot=Nt,jt=S,Mt=Tt,zt=class{constructor(e){const{type:t,subtype:n,params:r}=function(e){if(!(e=e.trim()))throw new TypeError("Invalid input.");let t="",n="",r="",s=null,i=new Map,o="type",a=Array.from(e);for(let e=0;e<a.length;e++){const c=a[e];switch(o){case"type":if("/"===c){o="subtype";continue}t+=c;break;case"subtype":if(";"===c){o="param-start";continue}n+=c;break;case"param-start":if(Be.test(c)||";"===c)continue;r+=c,o="param-name";break;case"param-name":if("="===c||";"===c){if("="===c){o="param-value",s=null;continue}i.set(r.toLowerCase(),null),r="";continue}r+=c;break;case"param-value":if('"'==c){o="collect-quoted-string";continue}if(";"===c){s=s.trimEnd(),o="param-start",Ge(i,r,s),r="";continue}s="string"==typeof s?s+c:c;break;case"collect-quoted-string":if('"'===c){Ge(i,r,s),o="ignore-input-until-next-param",r="",s=null;continue}if("\\"===c)continue;s="string"==typeof s?s+c:c;break;case"ignore-input-until-next-param":if(";"!==c)continue;o="param-start";break;default:throw new Error(`State machine error - unknown parser mode: ${o} `)}}r&&Ge(i,r,s);if(""===t.trim()||!Fe.test(t))throw new TypeError("Invalid type");if(""===n.trim()||!Fe.test(n))throw new TypeError("Invalid subtype");return{type:t,subtype:n,params:Object.fromEntries(i.entries())}}(e);this.type=t.trim().toLowerCase(),this.subtype=n.trimEnd().toLowerCase(),this.parameters=new Map(Object.entries(r))}get essence(){return`${this.type}/${this.subtype}`}toString(){return function(e){const{parameters:t,essence:n}=e;if(!t.size)return n;let r=";";for(const[e,n]of t.entries())r+=e,null!==n?Fe.test(n)?r+=`=${n}`:r+=`="${n}"`:r+='=""',r+=";";return e.essence+r.slice(0,-1)}(this)}},Ut=Dt,qt=We;function Wt(e){if(!e)return e;const t=e.trimEnd().split("\n");for(;t.length&&!t[0].trim();)t.shift();const n=t.filter((e=>e.trim())).map((e=>e.search(/[^\s]/))),r=Math.min(...n);return t.map((e=>e.slice(r))).join("\n")}var Ft=Object.freeze({__proto__:null,name:"core/reindent",reindent:Wt,run:function(){for(const e of document.getElementsByTagName("pre"))e.innerHTML=Wt(e.innerHTML)}});const Bt=/-/g;const Ht=new Intl.DateTimeFormat(["sv-SE"],{timeZone:"UTC",year:"numeric",month:"2-digit",day:"2-digit"}),Gt="en"===c||c.startsWith("en-")?"en-AU":c,Vt=new Intl.DateTimeFormat(Gt,{timeZone:"UTC",year:"numeric",month:"long",day:"en-AU"===Gt?"2-digit":"numeric"}),Yt=".informative, .note, .issue, .example, .ednote, .practice, .introductory";function Kt(e){const t=new URL(e.href,document.baseURI),n=document.createElement("link");let{href:r}=t;switch(n.rel=e.hint,n.rel){case"dns-prefetch":case"preconnect":r=t.origin,(e.corsMode||t.origin!==document.location.origin)&&(n.crossOrigin=e.corsMode||"anonymous");break;case"preload":"as"in e&&n.setAttribute("as",e.as),e.corsMode&&(n.crossOrigin=e.corsMode)}return n.href=r,e.dontRemove||n.classList.add("removeOnSave"),n}function Zt(e){e.querySelectorAll(".remove, script[data-requiremodule]").forEach((e=>{e.remove()}))}function Jt(e,t="long"){const n=new Intl.ListFormat(c,{style:t,type:e});return(e,t)=>{let r=0;return n.formatToParts(e).map((({type:n,value:s})=>"element"===n&&t?t(s,r++,e):s))}}const Xt=Jt("conjunction"),Qt=Jt("disjunction");function en(e,t){return Xt(e,t).join("")}function tn(e,t){return Qt(e,t).join("")}function nn(e){return e.replace(/&/g,"&amp;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/</g,"&lt;")}function rn(e){return e.trim().replace(/\s+/g," ")}function sn(e,t=c){return t=t.toLowerCase(),new Proxy(e,{get(e,n){const r=on(e,n,t)||e.en[n];if(!r)throw new Error(`No l10n data for key: "${n}"`);return r}})}function on(e,t,n=c){return e[n=n.toLowerCase()]?.[t]||e[n.match(/^(\w{2,3})-.+$/)?.[1]]?.[t]}function an(e,t=""){return Ht.format(e).replace(Bt,t)}function cn(e,t,...n){const r=[this,e,...n];if(t){const n=t.split(/\s+/);for(const t of n){const n=window[t];if(n)try{e=n.apply(this,r)}catch(e){En(`call to \`${t}()\` failed with: ${e}.`,"utils/runTransforms",{hint:"See developer console for stack trace."}),console.error(e)}}}return e}async function ln(e,t=864e5){const n=new Request(e),r=new URL(n.url);let s,i;if("caches"in window)try{if(s=await caches.open(r.origin),i=await s.match(n),i&&new Date(i.headers.get("Expires"))>new Date)return i}catch(e){console.error("Failed to use Cache API.",e)}const o=await fetch(n);if(!o.ok&&i)return console.warn(`Returning a stale cached response for ${r}`),i;if(s&&o.ok){const e=o.clone(),r=new Headers(o.headers),i=new Date(Date.now()+t);r.set("Expires",i.toISOString());const a=new Response(await e.blob(),{headers:r});await s.put(n,a).catch(console.error)}return o}function un(e,t=(e=>e)){const n=e.map(t),r=n.slice(0,-1).map((e=>Ot`${e}, `));return Ot`${r}${n[n.length-1]}`}function dn(e,t){return[].concat(Xt(e,t)).map((e=>"string"==typeof e?Ot`${e}`:e))}function pn(e,t=""){const n=function(e){let t=0;for(const n of e)t=Math.imul(31,t)+n.charCodeAt(0)|0;return String(t)}(rn(e.textContent));return fn(e,t,n)}function fn(e,t="",n="",r=!1){if(e.id)return e.id;n||(n=(e.title?e.title:e.textContent).trim());let s=r?n:n.toLowerCase();if(s=s.trim().normalize("NFD").replace(/[\u0300-\u036f]/g,"").replace(/\W+/gim,"-").replace(/^-+/,"").replace(/-+$/,""),s?!/\.$/.test(s)&&/^[a-z]/i.test(t||s)||(s=`x${s}`):s="generatedID",t&&(s=`${t}-${s}`),e.ownerDocument.getElementById(s)){let t=0,n=`${s}-${t}`;for(;e.ownerDocument.getElementById(n);)t+=1,n=`${s}-${t}`;s=n}return e.id=s,s}function hn(e){const t=new Set,n="ltNodefault"in e.dataset?"":rn(e.textContent),r=e.children[0];if(e.dataset.lt?e.dataset.lt.split("|").map((e=>rn(e))).forEach((e=>t.add(e))):1===e.childNodes.length&&1===e.getElementsByTagName("abbr").length&&r.title?t.add(r.title):'""'===e.textContent&&t.add("the-empty-string"),t.add(n),t.delete(""),e.dataset.localLt){e.dataset.localLt.split("|").forEach((e=>t.add(rn(e))))}return[...t]}function mn(e,t,n={copyAttributes:!0}){if(e.localName===t)return e;const r=e.ownerDocument.createElement(t);if(n.copyAttributes)for(const{name:t,value:n}of e.attributes)r.setAttribute(t,n);return r.append(...e.childNodes),e.replaceWith(r),r}function gn(e,t){const n=t.closest(Yt);let r=!1;if(n&&(r=!t.closest(".normative")||!n.querySelector(".normative")),e.startsWith("!")){if(r)return{type:"informative",illegal:!0};r=!1}else e.startsWith("?")&&(r=!0);return{type:r?"informative":"normative",illegal:!1}}function bn(e,t){return t.append(...e.childNodes),e.appendChild(t),e}function yn(e){const t=[];for(const n of function*(e){let t=e;for(;t.previousElementSibling;)t=t.previousElementSibling,yield t}(e))"section"===n.localName&&t.push(n);return t}function wn(e,t){const n=[];let r=e.parentElement;for(;r;){const e=r.closest(t);if(!e)break;n.push(e),r=e.parentElement}return n}function vn(e){const{previousSibling:t}=e;if(!t||t.nodeType!==Node.TEXT_NODE)return"";const n=t.textContent.lastIndexOf("\n");if(-1===n)return"";const r=t.textContent.slice(n+1);return/\S/.test(r)?"":r}class $n extends Set{constructor(e=[]){super();for(const t of e)this.add(t)}add(e){return this.has(e)||this.getCanonicalKey(e)?this:super.add(e)}has(e){return super.has(e)||[...this.keys()].some((t=>t.toLowerCase()===e.toLowerCase()))}delete(e){return super.has(e)?super.delete(e):super.delete(this.getCanonicalKey(e))}getCanonicalKey(e){return super.has(e)?e:[...this.keys()].find((t=>t.toLowerCase()===e.toLowerCase()))}}function kn(e){const t=e.cloneNode(!0);return t.querySelectorAll("[id]").forEach((e=>e.removeAttribute("id"))),t.querySelectorAll("dfn").forEach((e=>{mn(e,"span",{copyAttributes:!1})})),t.hasAttribute("id")&&t.removeAttribute("id"),xn(t),t}function xn(e){const t=document.createTreeWalker(e,NodeFilter.SHOW_COMMENT);for(const e of[..._n(t)])e.remove()}function*_n(e){for(;e.nextNode();)yield e.currentNode}class Cn extends Map{constructor(e=[]){return super(),e.forEach((([e,t])=>{this.set(e,t)})),this}set(e,t){return super.set(e.toLowerCase(),t),this}get(e){return super.get(e.toLowerCase())}has(e){return super.has(e.toLowerCase())}delete(e){return super.delete(e.toLowerCase())}}class Sn extends Error{constructor(e,t,n){super(e);const r=n.isWarning?"ReSpecWarning":"ReSpecError";Object.assign(this,{message:e,plugin:t,name:r,...n}),n.elements&&n.elements.forEach((t=>function(e,t,n){e.classList.add("respec-offending-element"),e.hasAttribute("title")||e.setAttribute("title",n||t),e.id||fn(e,"respec-offender")}(t,e,n.title)))}toJSON(){const{message:e,name:t,stack:n}=this,{plugin:r,hint:s,elements:i,title:o,details:a}=this;return{message:e,name:t,plugin:r,hint:s,elements:i,title:o,details:a,stack:n}}}function Rn(e,t,n={}){const s={...n,isWarning:!1};r("error",new Sn(e,t,s))}function En(e,t,n={}){const s={...n,isWarning:!0};r("warn",new Sn(e,t,s))}function An(e){return e?`\`${e}\``:""}function Tn(e,{quotes:t}={quotes:!1}){return tn(e,t?e=>An(Pn(e)):An)}function Ln(e,{quotes:t}={quotes:!1}){return en(e,t?e=>An(Pn(e)):An)}function Pn(e){return String(e)?`"${e}"`:""}function In(e,...t){return Wt(e.map(((e,n)=>{const r=t[n];if(!r)return e;if(!r.startsWith("[")&&!r.endsWith("]"))return e+r;const[s,i]=r.slice(1,-1).split("|");if(i){return`${e}[${s}](${new URL(i,"https://respec.org/docs/")})`}return`${e}[\`${s}\`](https://respec.org/docs/#${s})`})).join(""))}const Dn=new Map([["text/html","html"],["application/xml","xml"]]);function Nn(e,t=document){const n=Dn.get(e);if(!n){const t=[...Dn.values()].join(", ");throw new TypeError(`Invalid format: ${e}. Expected one of: ${t}.`)}const r=On(n,t);return`data:${e};charset=utf-8,${encodeURIComponent(r)}`}function On(e,t){const n=t.cloneNode(!0);!function(e){const{head:t,body:n,documentElement:s}=e;xn(e),e.querySelectorAll(".removeOnSave, #toc-nav").forEach((e=>e.remove())),n.classList.remove("toc-sidebar"),Zt(s);const i=e.createDocumentFragment(),o=e.querySelector("meta[name='viewport']");o&&t.firstChild!==o&&i.appendChild(o);let a=e.querySelector("meta[charset], meta[content*='charset=']");a||(a=Ot`<meta charset="utf-8" />`);i.appendChild(a);const c=`ReSpec ${window.respecVersion||"Developer Channel"}`,l=Ot`
1
+ window.respecVersion="34.1.6",function(){"use strict";const e=!!window.require;if(!e){const e=function(e,t){const n=e.map((e=>{if(!(e in window.require.modules))throw new Error(`Unsupported dependency name: ${e}`);return window.require.modules[e]}));Promise.all(n).then((e=>t(...e)))};e.modules={},window.require=e}function t(t,n){e||(window.require.modules[t]=n)}const n=new EventTarget;function r(e,t){if(n.dispatchEvent(new CustomEvent(e,{detail:t})),window.parent===window.self)return;const r=String(JSON.stringify(t?.stack||t));window.parent.postMessage({topic:e,args:r},window.parent.location.origin)}function s(e,t,r={once:!1}){n.addEventListener(e,(e=>t(e.detail)),r)}t("core/pubsubhub",{sub:s});const i=["githubToken","githubUser"];const o=document.documentElement;o&&!o.hasAttribute("lang")&&(o.lang="en",o.hasAttribute("dir")||(o.dir="ltr"));const a={},c=o.lang;var l=Object.freeze({__proto__:null,l10n:a,lang:c,name:"core/l10n",run:function(e){e.l10n=a[c]||a.en}});let u,d;const p=new WeakMap,f=new WeakMap,h=new WeakMap,m=new WeakMap,g=new WeakMap;let b={get(e,t,n){if(e instanceof IDBTransaction){if("done"===t)return f.get(e);if("objectStoreNames"===t)return e.objectStoreNames||h.get(e);if("store"===t)return n.objectStoreNames[1]?void 0:n.objectStore(n.objectStoreNames[0])}return v(e[t])},set:(e,t,n)=>(e[t]=n,!0),has:(e,t)=>e instanceof IDBTransaction&&("done"===t||"store"===t)||t in e};function y(e){return e!==IDBDatabase.prototype.transaction||"objectStoreNames"in IDBTransaction.prototype?(d||(d=[IDBCursor.prototype.advance,IDBCursor.prototype.continue,IDBCursor.prototype.continuePrimaryKey])).includes(e)?function(...t){return e.apply($(this),t),v(p.get(this))}:function(...t){return v(e.apply($(this),t))}:function(t,...n){const r=e.call($(this),t,...n);return h.set(r,t.sort?t.sort():[t]),v(r)}}function w(e){return"function"==typeof e?y(e):(e instanceof IDBTransaction&&function(e){if(f.has(e))return;const t=new Promise(((t,n)=>{const r=()=>{e.removeEventListener("complete",s),e.removeEventListener("error",i),e.removeEventListener("abort",i)},s=()=>{t(),r()},i=()=>{n(e.error||new DOMException("AbortError","AbortError")),r()};e.addEventListener("complete",s),e.addEventListener("error",i),e.addEventListener("abort",i)}));f.set(e,t)}(e),t=e,(u||(u=[IDBDatabase,IDBObjectStore,IDBIndex,IDBCursor,IDBTransaction])).some((e=>t instanceof e))?new Proxy(e,b):e);var t}function v(e){if(e instanceof IDBRequest)return function(e){const t=new Promise(((t,n)=>{const r=()=>{e.removeEventListener("success",s),e.removeEventListener("error",i)},s=()=>{t(v(e.result)),r()},i=()=>{n(e.error),r()};e.addEventListener("success",s),e.addEventListener("error",i)}));return t.then((t=>{t instanceof IDBCursor&&p.set(t,e)})).catch((()=>{})),g.set(t,e),t}(e);if(m.has(e))return m.get(e);const t=w(e);return t!==e&&(m.set(e,t),g.set(t,e)),t}const $=e=>g.get(e);const k=["get","getKey","getAll","getAllKeys","count"],x=["put","add","delete","clear"],_=new Map;function S(e,t){if(!(e instanceof IDBDatabase)||t in e||"string"!=typeof t)return;if(_.get(t))return _.get(t);const n=t.replace(/FromIndex$/,""),r=t!==n,s=x.includes(n);if(!(n in(r?IDBIndex:IDBObjectStore).prototype)||!s&&!k.includes(n))return;const i=async function(e,...t){const i=this.transaction(e,s?"readwrite":"readonly");let o=i.store;return r&&(o=o.index(t.shift())),(await Promise.all([o[n](...t),s&&i.done]))[0]};return _.set(t,i),i}b=(e=>({...e,get:(t,n,r)=>S(t,n)||e.get(t,n,r),has:(t,n)=>!!S(t,n)||e.has(t,n)}))(b);var C=Object.freeze({__proto__:null,deleteDB:function(e,{blocked:t}={}){const n=indexedDB.deleteDatabase(e);return t&&n.addEventListener("blocked",(e=>t(e.oldVersion,e))),v(n).then((()=>{}))},openDB:function(e,t,{blocked:n,upgrade:r,blocking:s,terminated:i}={}){const o=indexedDB.open(e,t),a=v(o);return r&&o.addEventListener("upgradeneeded",(e=>{r(v(o.result),e.oldVersion,e.newVersion,v(o.transaction),e)})),n&&o.addEventListener("blocked",(e=>n(e.oldVersion,e.newVersion,e))),a.then((e=>{i&&e.addEventListener("close",(()=>i())),s&&e.addEventListener("versionchange",(e=>s(e.oldVersion,e.newVersion,e)))})).catch((()=>{})),a},unwrap:$,wrap:v});function R(e,t,n,r,s,{level:i="error",autofix:o,ruleName:a}={}){function c(n){return n>0?e.slice(t,t+n):e.slice(Math.max(t+n,0),t)}function l(n,{precedes:r}={}){const s=n.map((e=>e.trivia+e.value)).join(""),i=e[t];return"eof"===i.type?s:r?s+i.trivia:s.slice(i.trivia.length)}const u="eof"!==e[t].type?e[t].line:e.length>1?e[t-1].line:1,d=function(e){const t=e.split("\n");return t[t.length-1]}(l(c(-5),{precedes:!0})),p=c(5),f=l(p),h=d+f.split("\n")[0]+"\n"+(" ".repeat(d.length)+"^"),m="Syntax"===s?"since":"inside",g=`${s} error at line ${u}${e.name?` in ${e.name}`:""}${n&&n.name?`, ${m} \`${n.partial?"partial ":""}${function(e){const t=[e];for(;e&&e.parent;){const{parent:n}=e;t.unshift(n),e=n}return t.map((e=>function(e,t){let n=e;return t&&(n+=` ${t}`),n}(e.type,e.name))).join(" -> ")}(n)}\``:""}:\n${h}`;return{message:`${g} ${r}`,bareMessage:r,context:g,line:u,sourceName:e.name,level:i,ruleName:a,autofix:o,input:f,tokens:p}}function E(e,t,n,r){return R(e,t,n,r,"Syntax")}function A(e,t,n,r,s={}){return s.ruleName=n,R(t.source,e.index,t,r,"Validation",s)}class T{constructor({source:e,tokens:t}){Object.defineProperties(this,{source:{value:e},tokens:{value:t,writable:!0},parent:{value:null,writable:!0},this:{value:this}})}toJSON(){const e={type:void 0,name:void 0,inheritance:void 0};let t=this;for(;t!==Object.prototype;){const n=Object.getOwnPropertyDescriptors(t);for(const[t,r]of Object.entries(n))(r.enumerable||r.get)&&(e[t]=this[t]);t=Object.getPrototypeOf(t)}return e}}function L(e,t,{useNullableInner:n}={}){if(!e.union){const r=t.unique.get(e.idlType);if(!r)return;if("typedef"===r.type){const{typedefIncludesDictionary:n}=t.cache;if(n.has(r))return n.get(r);t.cache.typedefIncludesDictionary.set(r,void 0);const s=L(r.idlType,t);if(t.cache.typedefIncludesDictionary.set(r,s),s)return{reference:e,dictionary:s.dictionary}}if("dictionary"===r.type&&(n||!e.nullable))return{reference:e,dictionary:r}}for(const n of e.subtype){const e=L(n,t);if(e)return n.union?e:{reference:n,dictionary:e.dictionary}}}function P(e,t){if(t.cache.dictionaryIncludesRequiredField.has(e))return t.cache.dictionaryIncludesRequiredField.get(e);t.cache.dictionaryIncludesRequiredField.set(e,void 0);let n=e.members.some((e=>e.required));if(!n&&e.inheritance){const r=t.unique.get(e.inheritance);r?P(r,t)&&(n=!0):n=!0}return t.cache.dictionaryIncludesRequiredField.set(e,n),n}class I extends Array{constructor({source:e,tokens:t}){super(),Object.defineProperties(this,{source:{value:e},tokens:{value:t},parent:{value:null,writable:!0}})}}class D extends T{static parser(e,t){return()=>{const n=e.consumeKind(t);if(n)return new D({source:e.source,tokens:{value:n}})}}get value(){return X(this.tokens.value.value)}write(e){return e.ts.wrap([e.token(this.tokens.value),e.token(this.tokens.separator)])}}class N extends D{static parse(e){const t=e.consumeKind("eof");if(t)return new N({source:e.source,tokens:{value:t}})}get type(){return"eof"}}function O(e,t){return Q(e,{parser:D.parser(e,t),listName:t+" list"})}const j=["identifier","decimal","integer","string"],M=new Map([...["NoInterfaceObject","LenientSetter","LenientThis","TreatNonObjectAsNull","Unforgeable"].map((e=>[e,`Legacy${e}`])),["NamedConstructor","LegacyFactoryFunction"],["OverrideBuiltins","LegacyOverrideBuiltIns"],["TreatNullAs","LegacyNullToEmptyString"]]);function z(e){for(const t of j){const n=O(e,t);if(n.length)return n}e.error("Expected identifiers, strings, decimals, or integers but none found")}class U extends T{static parse(e){const t={assign:e.consume("=")},n=ue(new U({source:e.source,tokens:t}));if(n.list=[],t.assign){if(t.asterisk=e.consume("*"),t.asterisk)return n.this;t.secondaryName=e.consumeKind(...j)}return t.open=e.consume("("),t.open?(n.list=n.rhsIsList?z(e):re(e),t.close=e.consume(")")||e.error("Unexpected token in extended attribute argument list")):t.assign&&!t.secondaryName&&e.error("No right hand side to extended attribute assignment"),n.this}get rhsIsList(){return this.tokens.assign&&!this.tokens.asterisk&&!this.tokens.secondaryName}get rhsType(){return this.rhsIsList?this.list[0].tokens.value.type+"-list":this.tokens.asterisk?"*":this.tokens.secondaryName?this.tokens.secondaryName.type:null}write(e){const{rhsType:t}=this;return e.ts.wrap([e.token(this.tokens.assign),e.token(this.tokens.asterisk),e.reference_token(this.tokens.secondaryName,this.parent),e.token(this.tokens.open),...this.list.map((n=>"identifier-list"===t?e.identifier(n,this.parent):n.write(e))),e.token(this.tokens.close)])}}class q extends T{static parse(e){const t=e.consumeKind("identifier");if(t)return new q({source:e.source,tokens:{name:t},params:U.parse(e)})}constructor({source:e,tokens:t,params:n}){super({source:e,tokens:t}),n.parent=this,Object.defineProperty(this,"params",{value:n})}get type(){return"extended-attribute"}get name(){return this.tokens.name.value}get rhs(){const{rhsType:e,tokens:t,list:n}=this.params;if(!e)return null;return{type:e,value:this.params.rhsIsList?n:this.params.tokens.secondaryName?X(t.secondaryName.value):null}}get arguments(){const{rhsIsList:e,list:t}=this.params;return!t||e?[]:t}*validate(e){const{name:t}=this;if("LegacyNoInterfaceObject"===t){const e="`[LegacyNoInterfaceObject]` extended attribute is an undesirable feature that may be removed from Web IDL in the future. Refer to the [relevant upstream PR](https://github.com/whatwg/webidl/pull/609) for more information.";yield A(this.tokens.name,this,"no-nointerfaceobject",e,{level:"warning"})}else if(M.has(t)){const e=`\`[${t}]\` extended attribute is a legacy feature that is now renamed to \`[${M.get(t)}]\`. Refer to the [relevant upstream PR](https://github.com/whatwg/webidl/pull/870) for more information.`;yield A(this.tokens.name,this,"renamed-legacy",e,{level:"warning",autofix:(n=this,()=>{const{name:e}=n;n.tokens.name.value=M.get(e),"TreatNullAs"===e&&(n.params.tokens={})})})}var n;for(const t of this.arguments)yield*t.validate(e)}write(e){return e.ts.wrap([e.ts.trivia(this.tokens.name.trivia),e.ts.extendedAttribute(e.ts.wrap([e.ts.extendedAttributeReference(this.name),this.params.write(e)])),e.token(this.tokens.separator)])}}class W extends I{static parse(e){const t={};t.open=e.consume("[");const n=new W({source:e.source,tokens:t});return t.open?(n.push(...Q(e,{parser:q.parse,listName:"extended attribute"})),t.close=e.consume("]")||e.error("Expected a closing token for the extended attribute list"),n.length||(e.unconsume(t.close.index),e.error("An extended attribute list must not be empty")),e.probe("[")&&e.error("Illegal double extended attribute lists, consider merging them"),n):n}*validate(e){for(const t of this)yield*t.validate(e)}write(e){return this.length?e.ts.wrap([e.token(this.tokens.open),...this.map((t=>t.write(e))),e.token(this.tokens.close)]):""}}function F(e,t){const n=e.consume("?");n&&(t.tokens.nullable=n),e.probe("?")&&e.error("Can't nullable more than once")}function B(e,t){let n=function(e,t){const n=e.consume("FrozenArray","ObservableArray","Promise","sequence","record");if(!n)return;const r=ue(new H({source:e.source,tokens:{base:n}}));switch(r.tokens.open=e.consume("<")||e.error(`No opening bracket after ${n.value}`),n.value){case"Promise":{e.probe("[")&&e.error("Promise type cannot have extended attribute");const n=ie(e,t)||e.error("Missing Promise subtype");r.subtype.push(n);break}case"sequence":case"FrozenArray":case"ObservableArray":{const s=se(e,t)||e.error(`Missing ${n.value} subtype`);r.subtype.push(s);break}case"record":{e.probe("[")&&e.error("Record key cannot have extended attribute");const n=e.consume(...fe)||e.error(`Record key must be one of: ${fe.join(", ")}`),s=new H({source:e.source,tokens:{base:n}});s.tokens.separator=e.consume(",")||e.error("Missing comma after record key type"),s.type=t;const i=se(e,t)||e.error("Error parsing generic type record");r.subtype.push(s,i);break}}return r.idlType||e.error(`Error parsing generic type ${n.value}`),r.tokens.close=e.consume(">")||e.error(`Missing closing bracket after ${n.value}`),r.this}(e,t)||ne(e);if(!n){const t=e.consumeKind("identifier")||e.consume(...fe,...pe);if(!t)return;n=new H({source:e.source,tokens:{base:t}}),e.probe("<")&&e.error(`Unsupported generic type ${t.value}`)}return"Promise"===n.generic&&e.probe("?")&&e.error("Promise type cannot be nullable"),n.type=t||null,F(e,n),n.nullable&&"any"===n.idlType&&e.error("Type `any` cannot be made nullable"),n}class H extends T{static parse(e,t){return B(e,t)||function(e,t){const n={};if(n.open=e.consume("("),!n.open)return;const r=ue(new H({source:e.source,tokens:n}));for(r.type=t||null;;){const n=se(e,t)||e.error("No type after open parenthesis or 'or' in union type");"any"===n.idlType&&e.error("Type `any` cannot be included in a union type"),"Promise"===n.generic&&e.error("Type `Promise` cannot be included in a union type"),r.subtype.push(n);const s=e.consume("or");if(!s)break;n.tokens.separator=s}return r.idlType.length<2&&e.error("At least two types are expected in a union type but found less"),n.close=e.consume(")")||e.error("Unterminated union type"),F(e,r),r.this}(e,t)}constructor({source:e,tokens:t}){super({source:e,tokens:t}),Object.defineProperty(this,"subtype",{value:[],writable:!0}),this.extAttrs=new W({source:e,tokens:{}})}get generic(){return this.subtype.length&&this.tokens.base?this.tokens.base.value:""}get nullable(){return Boolean(this.tokens.nullable)}get union(){return Boolean(this.subtype.length)&&!this.tokens.base}get idlType(){if(this.subtype.length)return this.subtype;return X([this.tokens.prefix,this.tokens.base,this.tokens.postfix].filter((e=>e)).map((e=>e.value)).join(" "))}*validate(e){if(yield*this.extAttrs.validate(e),"BufferSource"===this.idlType)for(const e of[this.extAttrs,this.parent?.extAttrs])for(const t of e){if("AllowShared"!==t.name)continue;const n="`[AllowShared] BufferSource` is now replaced with AllowSharedBufferSource.";yield A(this.tokens.base,this,"migrate-allowshared",n,{autofix:G(this,t,e)})}if("void"===this.idlType){const e="`void` is now replaced by `undefined`. Refer to the [relevant GitHub issue](https://github.com/whatwg/webidl/issues/60) for more information.";yield A(this.tokens.base,this,"replace-void",e,{autofix:(t=this,()=>{t.tokens.base.value="undefined"})})}var t;const n=!this.union&&e.unique.get(this.idlType),r=this.union?this:n&&"typedef"===n.type?n.idlType:void 0;if(r&&this.nullable){const{reference:t}=L(r,e)||{};if(t){const e=(this.union?t:this).tokens.base,n="Nullable union cannot include a dictionary type.";yield A(e,this,"no-nullable-union-dict",n)}}else for(const t of this.subtype)yield*t.validate(e)}write(e){return e.ts.wrap([this.extAttrs.write(e),(()=>{if(this.union||this.generic)return e.ts.wrap([e.token(this.tokens.base,e.ts.generic),e.token(this.tokens.open),...this.subtype.map((t=>t.write(e))),e.token(this.tokens.close)]);const t=this.tokens.prefix||this.tokens.base,n=this.tokens.prefix?[this.tokens.prefix.value,e.ts.trivia(this.tokens.base.trivia)]:[],r=e.reference(e.ts.wrap([...n,this.tokens.base.value,e.token(this.tokens.postfix)]),{unescaped:this.idlType,context:this});return e.ts.wrap([e.ts.trivia(t.trivia),r])})(),e.token(this.tokens.nullable),e.token(this.tokens.separator)])}}function G(e,t,n){return()=>{const r=n.indexOf(t);n.splice(r,1),!n.length&&e.tokens.base.trivia.match(/^\s$/)&&(e.tokens.base.trivia=""),e.tokens.base.value="AllowSharedBufferSource"}}class V extends T{static parse(e){const t=e.consume("=");if(!t)return null;const n=ee(e)||e.consumeKind("string")||e.consume("null","[","{")||e.error("No value for default"),r=[n];if("["===n.value){const t=e.consume("]")||e.error("Default sequence value must be empty");r.push(t)}else if("{"===n.value){const t=e.consume("}")||e.error("Default dictionary value must be empty");r.push(t)}return new V({source:e.source,tokens:{assign:t},expression:r})}constructor({source:e,tokens:t,expression:n}){super({source:e,tokens:t}),n.parent=this,Object.defineProperty(this,"expression",{value:n})}get type(){return te(this.expression[0]).type}get value(){return te(this.expression[0]).value}get negative(){return te(this.expression[0]).negative}write(e){return e.ts.wrap([e.token(this.tokens.assign),...this.expression.map((t=>e.token(t)))])}}class Y extends T{static parse(e){const t=e.position,n={},r=ue(new Y({source:e.source,tokens:n}));return r.extAttrs=W.parse(e),n.optional=e.consume("optional"),r.idlType=se(e,"argument-type"),r.idlType?(n.optional||(n.variadic=e.consume("...")),n.name=e.consumeKind("identifier")||e.consume(...he),n.name?(r.default=n.optional?V.parse(e):null,r.this):e.unconsume(t)):e.unconsume(t)}get type(){return"argument"}get optional(){return!!this.tokens.optional}get variadic(){return!!this.tokens.variadic}get name(){return X(this.tokens.name.value)}*validate(e){yield*this.extAttrs.validate(e),yield*this.idlType.validate(e);const t=L(this.idlType,e,{useNullableInner:!0});if(t)if(this.idlType.nullable){const e="Dictionary arguments cannot be nullable.";yield A(this.tokens.name,this,"no-nullable-dict-arg",e)}else if(this.optional){if(!this.default){const e="Optional dictionary arguments must have a default value of `{}`.";yield A(this.tokens.name,this,"dict-arg-default",e,{autofix:K(this)})}}else if(this.parent&&!P(t.dictionary,e)&&function(e){const t=e.parent.arguments||e.parent.list,n=t.indexOf(e);return!t.slice(n+1).some((e=>!e.optional))}(this)){const e="Dictionary argument must be optional if it has no required fields";yield A(this.tokens.name,this,"dict-arg-optional",e,{autofix:(n=this,()=>{const e=le(n.idlType);n.tokens.optional={...e,type:"optional",value:"optional"},e.trivia=" ",K(n)()})})}var n}write(e){return e.ts.wrap([this.extAttrs.write(e),e.token(this.tokens.optional),e.ts.type(this.idlType.write(e)),e.token(this.tokens.variadic),e.name_token(this.tokens.name,{data:this}),this.default?this.default.write(e):"",e.token(this.tokens.separator)])}}function K(e){return()=>{e.default=V.parse(new ye(" = {}"))}}class Z extends T{static parse(e,{special:t,regular:n}={}){const r={special:t},s=ue(new Z({source:e.source,tokens:r}));return t&&"stringifier"===t.value&&(r.termination=e.consume(";"),r.termination)?(s.arguments=[],s):(t||n||(r.special=e.consume("getter","setter","deleter")),s.idlType=ie(e)||e.error("Missing return type"),r.name=e.consumeKind("identifier")||e.consume("includes"),r.open=e.consume("(")||e.error("Invalid operation"),s.arguments=re(e),r.close=e.consume(")")||e.error("Unterminated operation"),r.termination=e.consume(";")||e.error("Unterminated operation, expected `;`"),s.this)}get type(){return"operation"}get name(){const{name:e}=this.tokens;return e?X(e.value):""}get special(){return this.tokens.special?this.tokens.special.value:""}*validate(e){if(yield*this.extAttrs.validate(e),!this.name&&["","static"].includes(this.special)){const e="Regular or static operations must have both a return type and an identifier.";yield A(this.tokens.open,this,"incomplete-op",e)}this.idlType&&(yield*this.idlType.validate(e));for(const t of this.arguments)yield*t.validate(e)}write(e){const{parent:t}=this,n=this.idlType?[e.ts.type(this.idlType.write(e)),e.name_token(this.tokens.name,{data:this,parent:t}),e.token(this.tokens.open),e.ts.wrap(this.arguments.map((t=>t.write(e)))),e.token(this.tokens.close)]:[];return e.ts.definition(e.ts.wrap([this.extAttrs.write(e),this.tokens.name?e.token(this.tokens.special):e.token(this.tokens.special,e.ts.nameless,{data:this,parent:t}),...n,e.token(this.tokens.termination)]),{data:this,parent:t})}}class J extends T{static parse(e,{special:t,noInherit:n=!1,readonly:r=!1}={}){const s=e.position,i={special:t},o=ue(new J({source:e.source,tokens:i}));if(t||n||(i.special=e.consume("inherit")),"inherit"===o.special&&e.probe("readonly")&&e.error("Inherited attributes cannot be read-only"),i.readonly=e.consume("readonly"),r&&!i.readonly&&e.probe("attribute")&&e.error("Attributes must be readonly in this context"),i.base=e.consume("attribute"),i.base)return o.idlType=se(e,"attribute-type")||e.error("Attribute lacks a type"),i.name=e.consumeKind("identifier")||e.consume("async","required")||e.error("Attribute lacks a name"),i.termination=e.consume(";")||e.error("Unterminated attribute, expected `;`"),o.this;e.unconsume(s)}get type(){return"attribute"}get special(){return this.tokens.special?this.tokens.special.value:""}get readonly(){return!!this.tokens.readonly}get name(){return X(this.tokens.name.value)}*validate(e){if(yield*this.extAttrs.validate(e),yield*this.idlType.validate(e),["sequence","record"].includes(this.idlType.generic)){const e=`Attributes cannot accept ${this.idlType.generic} types.`;yield A(this.tokens.name,this,"attr-invalid-type",e)}{const{reference:t}=L(this.idlType,e)||{};if(t){const e=(this.idlType.union?t:this.idlType).tokens.base,n="Attributes cannot accept dictionary types.";yield A(e,this,"attr-invalid-type",n)}}if(this.readonly&&function(e,t){if(e.union)return!1;if(e.extAttrs.some((e=>"EnforceRange"===e.name)))return!0;const n=t.unique.get(e.idlType);return"typedef"===n?.type&&n.idlType.extAttrs.some((e=>"EnforceRange"===e.name))}(this.idlType,e)){const e=this.idlType.tokens.base,t="Readonly attributes cannot accept [EnforceRange] extended attribute.";yield A(e,this,"attr-invalid-type",t)}}write(e){const{parent:t}=this;return e.ts.definition(e.ts.wrap([this.extAttrs.write(e),e.token(this.tokens.special),e.token(this.tokens.readonly),e.token(this.tokens.base),e.ts.type(this.idlType.write(e)),e.name_token(this.tokens.name,{data:this,parent:t}),e.token(this.tokens.termination)]),{data:this,parent:t})}}function X(e){return e.startsWith("_")?e.slice(1):e}function Q(e,{parser:t,allowDangler:n,listName:r="list"}){const s=t(e);if(!s)return[];s.tokens.separator=e.consume(",");const i=[s];for(;s.tokens.separator;){const s=t(e);if(!s){n||e.error(`Trailing comma in ${r}`);break}if(s.tokens.separator=e.consume(","),i.push(s),!s.tokens.separator)break}return i}function ee(e){return e.consumeKind("decimal","integer")||e.consume("true","false","Infinity","-Infinity","NaN")}function te({type:e,value:t}){switch(e){case"decimal":case"integer":return{type:"number",value:t};case"string":return{type:"string",value:t.slice(1,-1)}}switch(t){case"true":case"false":return{type:"boolean",value:"true"===t};case"Infinity":case"-Infinity":return{type:"Infinity",negative:t.startsWith("-")};case"[":return{type:"sequence",value:[]};case"{":return{type:"dictionary"};default:return{type:t}}}function ne(e){const{source:t}=e,n=function(){const n=e.consume("unsigned"),r=e.consume("short","long");if(r){const s=e.consume("long");return new H({source:t,tokens:{prefix:n,base:r,postfix:s}})}n&&e.error("Failed to parse integer type")}()||function(){const n=e.consume("unrestricted"),r=e.consume("float","double");if(r)return new H({source:t,tokens:{prefix:n,base:r}});n&&e.error("Failed to parse float type")}();if(n)return n;const r=e.consume("bigint","boolean","byte","octet","undefined");return r?new H({source:t,tokens:{base:r}}):void 0}function re(e){return Q(e,{parser:Y.parse,listName:"arguments list"})}function se(e,t){const n=W.parse(e),r=H.parse(e,t);return r&&(ue(r).extAttrs=n),r}function ie(e,t){const n=H.parse(e,t||"return-type");if(n)return n;const r=e.consume("void");if(r){const t=new H({source:e.source,tokens:{base:r}});return t.type="return-type",t}}function oe(e){const t=e.consume("stringifier");if(!t)return;return J.parse(e,{special:t})||Z.parse(e,{special:t})||e.error("Unterminated stringifier")}function ae(e){const t=e.split("\n");if(t.length){const e=t[t.length-1].match(/^\s+/);if(e)return e[0]}return""}function ce(e){return()=>{if(e.extAttrs.length){const t=new ye("Exposed=Window,"),n=q.parse(t);n.tokens.separator=t.consume(",");const r=e.extAttrs[0];/^\s/.test(r.tokens.name.trivia)||(r.tokens.name.trivia=` ${r.tokens.name.trivia}`),e.extAttrs.unshift(n)}else{ue(e).extAttrs=W.parse(new ye("[Exposed=Window]"));const t=e.tokens.base.trivia;e.extAttrs.tokens.open.trivia=t,e.tokens.base.trivia=`\n${ae(t)}`}}}function le(e){if(e.extAttrs.length)return e.extAttrs.tokens.open;if("operation"===e.type&&!e.special)return le(e.idlType);return Object.values(e.tokens).sort(((e,t)=>e.index-t.index))[0]}function ue(e,t){if(t||(t=e),!e)return e;return new Proxy(e,{get(e,t){const n=e[t];return Array.isArray(n)&&"source"!==t?ue(n,e):n},set(e,n,r){if(e[n]=r,!r)return!0;if(Array.isArray(r))for(const e of r)void 0!==e.parent&&(e.parent=t);else void 0!==r.parent&&(r.parent=t);return!0}})}const de={decimal:/-?(?=[0-9]*\.|[0-9]+[eE])(([0-9]+\.[0-9]*|[0-9]*\.[0-9]+)([Ee][-+]?[0-9]+)?|[0-9]+[Ee][-+]?[0-9]+)/y,integer:/-?(0([Xx][0-9A-Fa-f]+|[0-7]*)|[1-9][0-9]*)/y,identifier:/[_-]?[A-Za-z][0-9A-Z_a-z-]*/y,string:/"[^"]*"/y,whitespace:/[\t\n\r ]+/y,comment:/\/\/.*|\/\*[\s\S]*?\*\//y,other:/[^\t\n\r 0-9A-Za-z]/y},pe=["ArrayBuffer","SharedArrayBuffer","DataView","Int8Array","Int16Array","Int32Array","Uint8Array","Uint16Array","Uint32Array","Uint8ClampedArray","BigInt64Array","BigUint64Array","Float32Array","Float64Array","any","object","symbol"],fe=["ByteString","DOMString","USVString"],he=["async","attribute","callback","const","constructor","deleter","dictionary","enum","getter","includes","inherit","interface","iterable","maplike","namespace","partial","required","setlike","setter","static","stringifier","typedef","unrestricted"],me=["-Infinity","FrozenArray","Infinity","NaN","ObservableArray","Promise","bigint","boolean","byte","double","false","float","long","mixin","null","octet","optional","or","readonly","record","sequence","short","true","undefined","unsigned","void"].concat(he,fe,pe),ge=["(",")",",","...",":",";","<","=",">","?","*","[","]","{","}"],be=["_constructor","toString","_toString"];class ye{constructor(e){this.source=function(e){const t=[];let n=0,r="",s=1,i=0;for(;n<e.length;){const a=e.charAt(n);let c=-1;if(/[\t\n\r ]/.test(a)?c=o("whitespace",{noFlushTrivia:!0}):"/"===a&&(c=o("comment",{noFlushTrivia:!0})),-1!==c){const e=t.pop().value;s+=(e.match(/\n/g)||[]).length,r+=e,i-=1}else if(/[-0-9.A-Z_a-z]/.test(a)){if(c=o("decimal"),-1===c&&(c=o("integer")),-1===c){c=o("identifier");const e=t.length-1,n=t[e];if(-1!==c){if(be.includes(n.value)){const r=`${X(n.value)} is a reserved identifier and must not be used.`;throw new we(E(t,e,null,r))}me.includes(n.value)&&(n.type="inline")}}}else'"'===a&&(c=o("string"));for(const o of ge)if(e.startsWith(o,n)){t.push({type:"inline",value:o,trivia:r,line:s,index:i}),r="",n+=o.length,c=n;break}if(-1===c&&(c=o("other")),-1===c)throw new Error("Token stream not progressing");n=c,i+=1}return t.push({type:"eof",value:"",trivia:r,line:s,index:i}),t;function o(o,{noFlushTrivia:a}={}){const c=de[o];c.lastIndex=n;const l=c.exec(e);return l?(t.push({type:o,value:l[0],trivia:r,line:s,index:i}),a||(r=""),c.lastIndex):-1}}(e),this.position=0}error(e){throw new we(E(this.source,this.position,this.current,e))}probeKind(e){return this.source.length>this.position&&this.source[this.position].type===e}probe(e){return this.probeKind("inline")&&this.source[this.position].value===e}consumeKind(...e){for(const t of e){if(!this.probeKind(t))continue;const e=this.source[this.position];return this.position++,e}}consume(...e){if(!this.probeKind("inline"))return;const t=this.source[this.position];for(const n of e)if(t.value===n)return this.position++,t}consumeIdentifier(e){if(this.probeKind("identifier")&&this.source[this.position].value===e)return this.consumeKind("identifier")}unconsume(e){this.position=e}}class we extends Error{constructor({message:e,bareMessage:t,context:n,line:r,sourceName:s,input:i,tokens:o}){super(e),this.name="WebIDLParseError",this.bareMessage=t,this.context=n,this.line=r,this.sourceName=s,this.input=i,this.tokens=o}}class ve extends D{static parse(e){const t=e.consumeKind("string");if(t)return new ve({source:e.source,tokens:{value:t}})}get type(){return"enum-value"}get value(){return super.value.slice(1,-1)}write(e){const{parent:t}=this;return e.ts.wrap([e.ts.trivia(this.tokens.value.trivia),e.ts.definition(e.ts.wrap(['"',e.ts.name(this.value,{data:this,parent:t}),'"']),{data:this,parent:t}),e.token(this.tokens.separator)])}}class $e extends T{static parse(e){const t={};if(t.base=e.consume("enum"),!t.base)return;t.name=e.consumeKind("identifier")||e.error("No name for enum");const n=ue(new $e({source:e.source,tokens:t}));return e.current=n.this,t.open=e.consume("{")||e.error("Bodyless enum"),n.values=Q(e,{parser:ve.parse,allowDangler:!0,listName:"enumeration"}),e.probeKind("string")&&e.error("No comma between enum values"),t.close=e.consume("}")||e.error("Unexpected value in enum"),n.values.length||e.error("No value in enum"),t.termination=e.consume(";")||e.error("No semicolon after enum"),n.this}get type(){return"enum"}get name(){return X(this.tokens.name.value)}write(e){return e.ts.definition(e.ts.wrap([this.extAttrs.write(e),e.token(this.tokens.base),e.name_token(this.tokens.name,{data:this}),e.token(this.tokens.open),e.ts.wrap(this.values.map((t=>t.write(e)))),e.token(this.tokens.close),e.token(this.tokens.termination)]),{data:this})}}class ke extends T{static parse(e){const t=e.consumeKind("identifier");if(!t)return;const n={target:t};if(n.includes=e.consume("includes"),n.includes)return n.mixin=e.consumeKind("identifier")||e.error("Incomplete includes statement"),n.termination=e.consume(";")||e.error("No terminating ; for includes statement"),new ke({source:e.source,tokens:n});e.unconsume(t.index)}get type(){return"includes"}get target(){return X(this.tokens.target.value)}get includes(){return X(this.tokens.mixin.value)}write(e){return e.ts.definition(e.ts.wrap([this.extAttrs.write(e),e.reference_token(this.tokens.target,this),e.token(this.tokens.includes),e.reference_token(this.tokens.mixin,this),e.token(this.tokens.termination)]),{data:this})}}class xe extends T{static parse(e){const t={},n=ue(new xe({source:e.source,tokens:t}));if(t.base=e.consume("typedef"),t.base)return n.idlType=se(e,"typedef-type")||e.error("Typedef lacks a type"),t.name=e.consumeKind("identifier")||e.error("Typedef lacks a name"),e.current=n.this,t.termination=e.consume(";")||e.error("Unterminated typedef, expected `;`"),n.this}get type(){return"typedef"}get name(){return X(this.tokens.name.value)}*validate(e){yield*this.idlType.validate(e)}write(e){return e.ts.definition(e.ts.wrap([this.extAttrs.write(e),e.token(this.tokens.base),e.ts.type(this.idlType.write(e)),e.name_token(this.tokens.name,{data:this}),e.token(this.tokens.termination)]),{data:this})}}class _e extends T{static parse(e,t){const n={base:t},r=ue(new _e({source:e.source,tokens:n}));return n.name=e.consumeKind("identifier")||e.error("Callback lacks a name"),e.current=r.this,n.assign=e.consume("=")||e.error("Callback lacks an assignment"),r.idlType=ie(e)||e.error("Callback lacks a return type"),n.open=e.consume("(")||e.error("Callback lacks parentheses for arguments"),r.arguments=re(e),n.close=e.consume(")")||e.error("Unterminated callback"),n.termination=e.consume(";")||e.error("Unterminated callback, expected `;`"),r.this}get type(){return"callback"}get name(){return X(this.tokens.name.value)}*validate(e){yield*this.extAttrs.validate(e),yield*this.idlType.validate(e)}write(e){return e.ts.definition(e.ts.wrap([this.extAttrs.write(e),e.token(this.tokens.base),e.name_token(this.tokens.name,{data:this}),e.token(this.tokens.assign),e.ts.type(this.idlType.write(e)),e.token(this.tokens.open),...this.arguments.map((t=>t.write(e))),e.token(this.tokens.close),e.token(this.tokens.termination)]),{data:this})}}class Se extends T{static parse(e,t,{inheritable:n,allowedMembers:r}){const{tokens:s,type:i}=t;for(s.name=e.consumeKind("identifier")||e.error(`Missing name in ${i}`),e.current=t,t=ue(t),n&&Object.assign(s,function(e){const t=e.consume(":");return t?{colon:t,inheritance:e.consumeKind("identifier")||e.error("Inheritance lacks a type")}:{}}(e)),s.open=e.consume("{")||e.error(`Bodyless ${i}`),t.members=[];;){if(s.close=e.consume("}"),s.close)return s.termination=e.consume(";")||e.error(`Missing semicolon after ${i}`),t.this;const n=W.parse(e);let o;for(const[t,...n]of r)if(o=ue(t(e,...n)),o)break;o||e.error("Unknown member"),o.extAttrs=n,t.members.push(o.this)}}get partial(){return!!this.tokens.partial}get name(){return X(this.tokens.name.value)}get inheritance(){return this.tokens.inheritance?X(this.tokens.inheritance.value):null}*validate(e){for(const t of this.members)t.validate&&(yield*t.validate(e))}write(e){return e.ts.definition(e.ts.wrap([this.extAttrs.write(e),e.token(this.tokens.callback),e.token(this.tokens.partial),e.token(this.tokens.base),e.token(this.tokens.mixin),e.name_token(this.tokens.name,{data:this}),(()=>this.tokens.inheritance?e.ts.wrap([e.token(this.tokens.colon),e.ts.trivia(this.tokens.inheritance.trivia),e.ts.inheritance(e.reference(this.tokens.inheritance.value,{context:this}))]):"")(),e.token(this.tokens.open),e.ts.wrap(this.members.map((t=>t.write(e)))),e.token(this.tokens.close),e.token(this.tokens.termination)]),{data:this})}}class Ce extends T{static parse(e){const t={};if(t.base=e.consume("const"),!t.base)return;let n=ne(e);if(!n){const t=e.consumeKind("identifier")||e.error("Const lacks a type");n=new H({source:e.source,tokens:{base:t}})}e.probe("?")&&e.error("Unexpected nullable constant type"),n.type="const-type",t.name=e.consumeKind("identifier")||e.error("Const lacks a name"),t.assign=e.consume("=")||e.error("Const lacks value assignment"),t.value=ee(e)||e.error("Const lacks a value"),t.termination=e.consume(";")||e.error("Unterminated const, expected `;`");const r=new Ce({source:e.source,tokens:t});return ue(r).idlType=n,r}get type(){return"const"}get name(){return X(this.tokens.name.value)}get value(){return te(this.tokens.value)}write(e){const{parent:t}=this;return e.ts.definition(e.ts.wrap([this.extAttrs.write(e),e.token(this.tokens.base),e.ts.type(this.idlType.write(e)),e.name_token(this.tokens.name,{data:this,parent:t}),e.token(this.tokens.assign),e.token(this.tokens.value),e.token(this.tokens.termination)]),{data:this,parent:t})}}class Re extends T{static parse(e){const t=e.position,n=ue(new Re({source:e.source,tokens:{}})),{tokens:r}=n;if(r.readonly=e.consume("readonly"),r.readonly||(r.async=e.consume("async")),r.base=r.readonly?e.consume("maplike","setlike"):r.async?e.consume("iterable"):e.consume("iterable","maplike","setlike"),!r.base)return void e.unconsume(t);const{type:s}=n,i="maplike"===s,o=i||"iterable"===s,a=n.async&&"iterable"===s;r.open=e.consume("<")||e.error(`Missing less-than sign \`<\` in ${s} declaration`);const c=se(e)||e.error(`Missing a type argument in ${s} declaration`);return n.idlType=[c],n.arguments=[],o&&(c.tokens.separator=e.consume(","),c.tokens.separator?n.idlType.push(se(e)):i&&e.error(`Missing second type argument in ${s} declaration`)),r.close=e.consume(">")||e.error(`Missing greater-than sign \`>\` in ${s} declaration`),e.probe("(")&&(a?(r.argsOpen=e.consume("("),n.arguments.push(...re(e)),r.argsClose=e.consume(")")||e.error("Unterminated async iterable argument list")):e.error("Arguments are only allowed for `async iterable`")),r.termination=e.consume(";")||e.error(`Missing semicolon after ${s} declaration`),n.this}get type(){return this.tokens.base.value}get readonly(){return!!this.tokens.readonly}get async(){return!!this.tokens.async}*validate(e){for(const t of this.idlType)yield*t.validate(e);for(const t of this.arguments)yield*t.validate(e)}write(e){return e.ts.definition(e.ts.wrap([this.extAttrs.write(e),e.token(this.tokens.readonly),e.token(this.tokens.async),e.token(this.tokens.base,e.ts.generic),e.token(this.tokens.open),e.ts.wrap(this.idlType.map((t=>t.write(e)))),e.token(this.tokens.close),e.token(this.tokens.argsOpen),e.ts.wrap(this.arguments.map((t=>t.write(e)))),e.token(this.tokens.argsClose),e.token(this.tokens.termination)]),{data:this,parent:this.parent})}}class Ee extends T{static parse(e){const t=e.consume("constructor");if(!t)return;const n={base:t};n.open=e.consume("(")||e.error("No argument list in constructor");const r=re(e);n.close=e.consume(")")||e.error("Unterminated constructor"),n.termination=e.consume(";")||e.error("No semicolon after constructor");const s=new Ee({source:e.source,tokens:n});return ue(s).arguments=r,s}get type(){return"constructor"}*validate(e){for(const t of this.arguments)yield*t.validate(e)}write(e){const{parent:t}=this;return e.ts.definition(e.ts.wrap([this.extAttrs.write(e),e.token(this.tokens.base,e.ts.nameless,{data:this,parent:t}),e.token(this.tokens.open),e.ts.wrap(this.arguments.map((t=>t.write(e)))),e.token(this.tokens.close),e.token(this.tokens.termination)]),{data:this,parent:t})}}function Ae(e){const t=e.consume("static");if(!t)return;return J.parse(e,{special:t})||Z.parse(e,{special:t})||e.error("No body in static member")}class Te extends Se{static parse(e,t,{extMembers:n=[],partial:r=null}={}){const s={partial:r,base:t};return Se.parse(e,new Te({source:e.source,tokens:s}),{inheritable:!r,allowedMembers:[...n,[Ce.parse],[Ee.parse],[Ae],[oe],[Re.parse],[J.parse],[Z.parse]]})}get type(){return"interface"}*validate(e){if(yield*this.extAttrs.validate(e),!this.partial&&this.extAttrs.every((e=>"Exposed"!==e.name))){const e="Interfaces must have `[Exposed]` extended attribute. To fix, add, for example, `[Exposed=Window]`. Please also consider carefully if your interface should also be exposed in a Worker scope. Refer to the [WebIDL spec section on Exposed](https://heycam.github.io/webidl/#Exposed) for more information.";yield A(this.tokens.name,this,"require-exposed",e,{autofix:ce(this)})}const t=this.extAttrs.filter((e=>"Constructor"===e.name));for(const e of t){const t="Constructors should now be represented as a `constructor()` operation on the interface instead of `[Constructor]` extended attribute. Refer to the [WebIDL spec section on constructor operations](https://heycam.github.io/webidl/#idl-constructors) for more information.";yield A(e.tokens.name,this,"constructor-member",t,{autofix:Le(this,e)})}if(this.extAttrs.some((e=>"Global"===e.name))){const e=this.extAttrs.filter((e=>"LegacyFactoryFunction"===e.name));for(const t of e){const e="Interfaces marked as `[Global]` cannot have factory functions.";yield A(t.tokens.name,this,"no-constructible-global",e)}const t=this.members.filter((e=>"constructor"===e.type));for(const e of t){const t="Interfaces marked as `[Global]` cannot have constructors.";yield A(e.tokens.base,this,"no-constructible-global",t)}}yield*super.validate(e),this.partial||(yield*function*(e,t){const n=function(e){const t=o(e);return{statics:new Set(t.filter((e=>"static"===e.special)).map((e=>e.name))),nonstatics:new Set(t.filter((e=>"static"!==e.special)).map((e=>e.name)))}}(t),r=e.partials.get(t.name)||[],s=e.mixinMap.get(t.name)||[];for(const e of[...r,...s]){const r=o(e),s=r.filter((e=>"static"===e.special)),a=r.filter((e=>"static"!==e.special));yield*i(s,n.statics,e,t),yield*i(a,n.nonstatics,e,t),s.forEach((e=>n.statics.add(e.name))),a.forEach((e=>n.nonstatics.add(e.name)))}function*i(e,t,n,r){for(const s of e){const{name:e}=s;if(e&&t.has(e)){const t=`The ${"static"===s.special?"static ":""}operation "${e}" has already been defined for the base interface "${r.name}" either in itself or in a mixin`;yield A(s.tokens.name,n,"no-cross-overload",t)}}}function o(e){return e.members.filter((({type:e})=>"operation"===e))}}(e,this))}}function Le(e,t){return e=ue(e),()=>{const n=ae(e.extAttrs.tokens.open.trivia),r=e.members.length?ae(le(e.members[0]).trivia):function(e){const t=ae(e),n=t.includes("\t")?"\t":" ";return t+n}(n),s=Ee.parse(new ye(`\n${r}constructor();`));s.extAttrs=new W({source:e.source,tokens:{}}),ue(s).arguments=t.arguments;const i=function(e,t){const n=e.slice().reverse().findIndex(t);return-1===n?n:e.length-n-1}(e.members,(e=>"constructor"===e.type));e.members.splice(i+1,0,s);const{close:o}=e.tokens;o.trivia.includes("\n")||(o.trivia+=`\n${n}`);const{extAttrs:a}=e,c=a.indexOf(t),l=a.splice(c,1);a.length?a.length===c?a[c-1].tokens.separator=void 0:a[c].tokens.name.trivia.trim()||(a[c].tokens.name.trivia=l[0].tokens.name.trivia):a.tokens.open=a.tokens.close=void 0}}class Pe extends Se{static parse(e,t,{extMembers:n=[],partial:r}={}){const s={partial:r,base:t};if(s.mixin=e.consume("mixin"),s.mixin)return Se.parse(e,new Pe({source:e.source,tokens:s}),{allowedMembers:[...n,[Ce.parse],[oe],[J.parse,{noInherit:!0}],[Z.parse,{regular:!0}]]})}get type(){return"interface mixin"}}class Ie extends T{static parse(e){const t={},n=ue(new Ie({source:e.source,tokens:t}));return n.extAttrs=W.parse(e),t.required=e.consume("required"),n.idlType=se(e,"dictionary-type")||e.error("Dictionary member lacks a type"),t.name=e.consumeKind("identifier")||e.error("Dictionary member lacks a name"),n.default=V.parse(e),t.required&&n.default&&e.error("Required member must not have a default"),t.termination=e.consume(";")||e.error("Unterminated dictionary member, expected `;`"),n.this}get type(){return"field"}get name(){return X(this.tokens.name.value)}get required(){return!!this.tokens.required}*validate(e){yield*this.idlType.validate(e)}write(e){const{parent:t}=this;return e.ts.definition(e.ts.wrap([this.extAttrs.write(e),e.token(this.tokens.required),e.ts.type(this.idlType.write(e)),e.name_token(this.tokens.name,{data:this,parent:t}),this.default?this.default.write(e):"",e.token(this.tokens.termination)]),{data:this,parent:t})}}class De extends Se{static parse(e,{extMembers:t=[],partial:n}={}){const r={partial:n};if(r.base=e.consume("dictionary"),r.base)return Se.parse(e,new De({source:e.source,tokens:r}),{inheritable:!n,allowedMembers:[...t,[Ie.parse]]})}get type(){return"dictionary"}}class Ne extends Se{static parse(e,{extMembers:t=[],partial:n}={}){const r={partial:n};if(r.base=e.consume("namespace"),r.base)return Se.parse(e,new Ne({source:e.source,tokens:r}),{allowedMembers:[...t,[J.parse,{noInherit:!0,readonly:!0}],[Ce.parse],[Z.parse,{regular:!0}]]})}get type(){return"namespace"}*validate(e){if(!this.partial&&this.extAttrs.every((e=>"Exposed"!==e.name))){const e="Namespaces must have [Exposed] extended attribute. To fix, add, for example, [Exposed=Window]. Please also consider carefully if your namespace should also be exposed in a Worker scope. Refer to the [WebIDL spec section on Exposed](https://heycam.github.io/webidl/#Exposed) for more information.";yield A(this.tokens.name,this,"require-exposed",e,{autofix:ce(this)})}yield*super.validate(e)}}class Oe extends Se{static parse(e,t,{extMembers:n=[]}={}){const r={callback:t};if(r.base=e.consume("interface"),r.base)return Se.parse(e,new Oe({source:e.source,tokens:r}),{allowedMembers:[...n,[Ce.parse],[Z.parse,{regular:!0}]]})}get type(){return"callback interface"}}function je(e,t){const n=e.source;function r(t){e.error(t)}function s(...t){return e.consume(...t)}function i(n){const i=s("interface");if(i)return Pe.parse(e,i,{...n,...t?.extensions?.mixin})||Te.parse(e,i,{...n,...t?.extensions?.interface})||r("Interface has no proper body")}function o(){if(t.productions)for(const n of t.productions){const t=n(e);if(t)return t}return function(){const n=s("callback");if(n)return e.probe("interface")?Oe.parse(e,n,{...t?.extensions?.callbackInterface}):_e.parse(e,n)}()||i()||function(){const n=s("partial");if(n)return De.parse(e,{partial:n,...t?.extensions?.dictionary})||i({partial:n})||Ne.parse(e,{partial:n,...t?.extensions?.namespace})||r("Partial doesn't apply to anything")}()||De.parse(e,t?.extensions?.dictionary)||$e.parse(e)||xe.parse(e)||ke.parse(e)||Ne.parse(e,t?.extensions?.namespace)}const a=function(){if(!n.length)return[];const s=[];for(;;){const t=W.parse(e),n=o();if(!n){t.length&&r("Stray extended attributes");break}ue(n).extAttrs=t,s.push(n)}const i=N.parse(e);return t.concrete&&s.push(i),s}();return e.position<n.length&&r("Unrecognised tokens"),a}function Me(e){return e}const ze={wrap:e=>e.join(""),trivia:Me,name:Me,reference:Me,type:Me,generic:Me,nameless:Me,inheritance:Me,definition:Me,extendedAttribute:Me,extendedAttributeReference:Me};class Ue{constructor(e){this.ts=Object.assign({},ze,e)}reference(e,{unescaped:t,context:n}){return t||(t=e.startsWith("_")?e.slice(1):e),this.ts.reference(e,t,n)}token(e,t=Me,...n){if(!e)return"";const r=t(e.value,...n);return this.ts.wrap([this.ts.trivia(e.trivia),r])}reference_token(e,t){return this.token(e,this.reference.bind(this),{context:t})}name_token(e,t){return this.token(e,this.ts.name,t)}identifier(e,t){return this.ts.wrap([this.reference_token(e.tokens.value,t),this.token(e.tokens.separator)])}}function qe(e,t){const n=new Map,r=e.filter((e=>"includes"===e.type));for(const e of r){const r=t.get(e.includes);if(!r)continue;const s=n.get(e.target);s?s.push(r):n.set(e.target,[r])}return n}function*We(e){const t=function(e){const t=new Map,n=new Set,r=new Map;for(const s of e)if(s.partial){const e=r.get(s.name);e?e.push(s):r.set(s.name,[s])}else s.name&&(t.has(s.name)?n.add(s):t.set(s.name,s));return{all:e,unique:t,partials:r,duplicates:n,mixinMap:qe(e,t),cache:{typedefIncludesDictionary:new WeakMap,dictionaryIncludesRequiredField:new WeakMap}}}(e);for(const e of t.all)e.validate&&(yield*e.validate(t));yield*function*({unique:e,duplicates:t}){for(const n of t){const{name:t}=n,r=`The name "${t}" of type "${e.get(t).type}" was already seen`;yield A(n.tokens.name,n,"no-duplicate",r)}}(t)}var Fe=Object.freeze({__proto__:null,WebIDLParseError:we,parse:function(e,t={}){const n=new ye(e);return void 0!==t.sourceName&&(n.source.name=t.sourceName),je(n,t)},validate:function(e){return[...We((t=e,t.flat?t.flat():[].concat(...t)))];var t},write:function(e,{templates:t=ze}={}){t=Object.assign({},ze,t);const n=new Ue(t);return t.wrap(e.map((e=>e.write(n))))}});const Be=/^[!#$%&'*+-.^`|~\w]+$/,He=/[\u000A\u000D\u0009\u0020]/u,Ge=/^[\u0009\u{0020}-\{u0073}\u{0080}-\u{00FF}]+$/u;function Ve(e,t,n){(t&&""!==t&&!e.has(t)&&Ge.test(n)||null===n)&&e.set(t.toLowerCase(),n)}function Ye(){return{async:!1,baseUrl:null,breaks:!1,extensions:null,gfm:!0,headerIds:!0,headerPrefix:"",highlight:null,hooks:null,langPrefix:"language-",mangle:!0,pedantic:!1,renderer:null,sanitize:!1,sanitizer:null,silent:!1,smartypants:!1,tokenizer:null,walkTokens:null,xhtml:!1}}let Ke={async:!1,baseUrl:null,breaks:!1,extensions:null,gfm:!0,headerIds:!0,headerPrefix:"",highlight:null,hooks:null,langPrefix:"language-",mangle:!0,pedantic:!1,renderer:null,sanitize:!1,sanitizer:null,silent:!1,smartypants:!1,tokenizer:null,walkTokens:null,xhtml:!1};const Ze=/[&<>"']/,Je=new RegExp(Ze.source,"g"),Xe=/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,Qe=new RegExp(Xe.source,"g"),et={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"},tt=e=>et[e];function nt(e,t){if(t){if(Ze.test(e))return e.replace(Je,tt)}else if(Xe.test(e))return e.replace(Qe,tt);return e}const rt=/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/gi;function st(e){return e.replace(rt,((e,t)=>"colon"===(t=t.toLowerCase())?":":"#"===t.charAt(0)?"x"===t.charAt(1)?String.fromCharCode(parseInt(t.substring(2),16)):String.fromCharCode(+t.substring(1)):""))}const it=/(^|[^\[])\^/g;function ot(e,t){e="string"==typeof e?e:e.source,t=t||"";const n={replace:(t,r)=>(r=(r=r.source||r).replace(it,"$1"),e=e.replace(t,r),n),getRegex:()=>new RegExp(e,t)};return n}const at=/[^\w:]/g,ct=/^$|^[a-z][a-z0-9+.-]*:|^[?#]/i;function lt(e,t,n){if(e){let e;try{e=decodeURIComponent(st(n)).replace(at,"").toLowerCase()}catch(e){return null}if(0===e.indexOf("javascript:")||0===e.indexOf("vbscript:")||0===e.indexOf("data:"))return null}t&&!ct.test(n)&&(n=function(e,t){ut[" "+e]||(dt.test(e)?ut[" "+e]=e+"/":ut[" "+e]=gt(e,"/",!0));const n=-1===(e=ut[" "+e]).indexOf(":");return"//"===t.substring(0,2)?n?t:e.replace(pt,"$1")+t:"/"===t.charAt(0)?n?t:e.replace(ft,"$1")+t:e+t}(t,n));try{n=encodeURI(n).replace(/%25/g,"%")}catch(e){return null}return n}const ut={},dt=/^[^:]+:\/*[^/]*$/,pt=/^([^:]+:)[\s\S]*$/,ft=/^([^:]+:\/*[^/]*)[\s\S]*$/;const ht={exec:function(){}};function mt(e,t){const n=e.replace(/\|/g,((e,t,n)=>{let r=!1,s=t;for(;--s>=0&&"\\"===n[s];)r=!r;return r?"|":" |"})).split(/ \|/);let r=0;if(n[0].trim()||n.shift(),n.length>0&&!n[n.length-1].trim()&&n.pop(),n.length>t)n.splice(t);else for(;n.length<t;)n.push("");for(;r<n.length;r++)n[r]=n[r].trim().replace(/\\\|/g,"|");return n}function gt(e,t,n){const r=e.length;if(0===r)return"";let s=0;for(;s<r;){const i=e.charAt(r-s-1);if(i!==t||n){if(i===t||!n)break;s++}else s++}return e.slice(0,r-s)}function bt(e,t){if(t<1)return"";let n="";for(;t>1;)1&t&&(n+=e),t>>=1,e+=e;return n+e}function yt(e,t,n,r){const s=t.href,i=t.title?nt(t.title):null,o=e[1].replace(/\\([\[\]])/g,"$1");if("!"!==e[0].charAt(0)){r.state.inLink=!0;const e={type:"link",raw:n,href:s,title:i,text:o,tokens:r.inlineTokens(o)};return r.state.inLink=!1,e}return{type:"image",raw:n,href:s,title:i,text:nt(o)}}class wt{constructor(e){this.options=e||Ke}space(e){const t=this.rules.block.newline.exec(e);if(t&&t[0].length>0)return{type:"space",raw:t[0]}}code(e){const t=this.rules.block.code.exec(e);if(t){const e=t[0].replace(/^ {1,4}/gm,"");return{type:"code",raw:t[0],codeBlockStyle:"indented",text:this.options.pedantic?e:gt(e,"\n")}}}fences(e){const t=this.rules.block.fences.exec(e);if(t){const e=t[0],n=function(e,t){const n=e.match(/^(\s+)(?:```)/);if(null===n)return t;const r=n[1];return t.split("\n").map((e=>{const t=e.match(/^\s+/);if(null===t)return e;const[n]=t;return n.length>=r.length?e.slice(r.length):e})).join("\n")}(e,t[3]||"");return{type:"code",raw:e,lang:t[2]?t[2].trim().replace(this.rules.inline._escapes,"$1"):t[2],text:n}}}heading(e){const t=this.rules.block.heading.exec(e);if(t){let e=t[2].trim();if(/#$/.test(e)){const t=gt(e,"#");this.options.pedantic?e=t.trim():t&&!/ $/.test(t)||(e=t.trim())}return{type:"heading",raw:t[0],depth:t[1].length,text:e,tokens:this.lexer.inline(e)}}}hr(e){const t=this.rules.block.hr.exec(e);if(t)return{type:"hr",raw:t[0]}}blockquote(e){const t=this.rules.block.blockquote.exec(e);if(t){const e=t[0].replace(/^ *>[ \t]?/gm,""),n=this.lexer.state.top;this.lexer.state.top=!0;const r=this.lexer.blockTokens(e);return this.lexer.state.top=n,{type:"blockquote",raw:t[0],tokens:r,text:e}}}list(e){let t=this.rules.block.list.exec(e);if(t){let n,r,s,i,o,a,c,l,u,d,p,f,h=t[1].trim();const m=h.length>1,g={type:"list",raw:"",ordered:m,start:m?+h.slice(0,-1):"",loose:!1,items:[]};h=m?`\\d{1,9}\\${h.slice(-1)}`:`\\${h}`,this.options.pedantic&&(h=m?h:"[*+-]");const b=new RegExp(`^( {0,3}${h})((?:[\t ][^\\n]*)?(?:\\n|$))`);for(;e&&(f=!1,t=b.exec(e))&&!this.rules.block.hr.test(e);){if(n=t[0],e=e.substring(n.length),l=t[2].split("\n",1)[0].replace(/^\t+/,(e=>" ".repeat(3*e.length))),u=e.split("\n",1)[0],this.options.pedantic?(i=2,p=l.trimLeft()):(i=t[2].search(/[^ ]/),i=i>4?1:i,p=l.slice(i),i+=t[1].length),a=!1,!l&&/^ *$/.test(u)&&(n+=u+"\n",e=e.substring(u.length+1),f=!0),!f){const t=new RegExp(`^ {0,${Math.min(3,i-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ \t][^\\n]*)?(?:\\n|$))`),r=new RegExp(`^ {0,${Math.min(3,i-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),s=new RegExp(`^ {0,${Math.min(3,i-1)}}(?:\`\`\`|~~~)`),o=new RegExp(`^ {0,${Math.min(3,i-1)}}#`);for(;e&&(d=e.split("\n",1)[0],u=d,this.options.pedantic&&(u=u.replace(/^ {1,4}(?=( {4})*[^ ])/g," ")),!s.test(u))&&!o.test(u)&&!t.test(u)&&!r.test(e);){if(u.search(/[^ ]/)>=i||!u.trim())p+="\n"+u.slice(i);else{if(a)break;if(l.search(/[^ ]/)>=4)break;if(s.test(l))break;if(o.test(l))break;if(r.test(l))break;p+="\n"+u}a||u.trim()||(a=!0),n+=d+"\n",e=e.substring(d.length+1),l=u.slice(i)}}g.loose||(c?g.loose=!0:/\n *\n *$/.test(n)&&(c=!0)),this.options.gfm&&(r=/^\[[ xX]\] /.exec(p),r&&(s="[ ] "!==r[0],p=p.replace(/^\[[ xX]\] +/,""))),g.items.push({type:"list_item",raw:n,task:!!r,checked:s,loose:!1,text:p}),g.raw+=n}g.items[g.items.length-1].raw=n.trimRight(),g.items[g.items.length-1].text=p.trimRight(),g.raw=g.raw.trimRight();const y=g.items.length;for(o=0;o<y;o++)if(this.lexer.state.top=!1,g.items[o].tokens=this.lexer.blockTokens(g.items[o].text,[]),!g.loose){const e=g.items[o].tokens.filter((e=>"space"===e.type)),t=e.length>0&&e.some((e=>/\n.*\n/.test(e.raw)));g.loose=t}if(g.loose)for(o=0;o<y;o++)g.items[o].loose=!0;return g}}html(e){const t=this.rules.block.html.exec(e);if(t){const e={type:"html",raw:t[0],pre:!this.options.sanitizer&&("pre"===t[1]||"script"===t[1]||"style"===t[1]),text:t[0]};if(this.options.sanitize){const n=this.options.sanitizer?this.options.sanitizer(t[0]):nt(t[0]);e.type="paragraph",e.text=n,e.tokens=this.lexer.inline(n)}return e}}def(e){const t=this.rules.block.def.exec(e);if(t){const e=t[1].toLowerCase().replace(/\s+/g," "),n=t[2]?t[2].replace(/^<(.*)>$/,"$1").replace(this.rules.inline._escapes,"$1"):"",r=t[3]?t[3].substring(1,t[3].length-1).replace(this.rules.inline._escapes,"$1"):t[3];return{type:"def",tag:e,raw:t[0],href:n,title:r}}}table(e){const t=this.rules.block.table.exec(e);if(t){const e={type:"table",header:mt(t[1]).map((e=>({text:e}))),align:t[2].replace(/^ *|\| *$/g,"").split(/ *\| */),rows:t[3]&&t[3].trim()?t[3].replace(/\n[ \t]*$/,"").split("\n"):[]};if(e.header.length===e.align.length){e.raw=t[0];let n,r,s,i,o=e.align.length;for(n=0;n<o;n++)/^ *-+: *$/.test(e.align[n])?e.align[n]="right":/^ *:-+: *$/.test(e.align[n])?e.align[n]="center":/^ *:-+ *$/.test(e.align[n])?e.align[n]="left":e.align[n]=null;for(o=e.rows.length,n=0;n<o;n++)e.rows[n]=mt(e.rows[n],e.header.length).map((e=>({text:e})));for(o=e.header.length,r=0;r<o;r++)e.header[r].tokens=this.lexer.inline(e.header[r].text);for(o=e.rows.length,r=0;r<o;r++)for(i=e.rows[r],s=0;s<i.length;s++)i[s].tokens=this.lexer.inline(i[s].text);return e}}}lheading(e){const t=this.rules.block.lheading.exec(e);if(t)return{type:"heading",raw:t[0],depth:"="===t[2].charAt(0)?1:2,text:t[1],tokens:this.lexer.inline(t[1])}}paragraph(e){const t=this.rules.block.paragraph.exec(e);if(t){const e="\n"===t[1].charAt(t[1].length-1)?t[1].slice(0,-1):t[1];return{type:"paragraph",raw:t[0],text:e,tokens:this.lexer.inline(e)}}}text(e){const t=this.rules.block.text.exec(e);if(t)return{type:"text",raw:t[0],text:t[0],tokens:this.lexer.inline(t[0])}}escape(e){const t=this.rules.inline.escape.exec(e);if(t)return{type:"escape",raw:t[0],text:nt(t[1])}}tag(e){const t=this.rules.inline.tag.exec(e);if(t)return!this.lexer.state.inLink&&/^<a /i.test(t[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&/^<\/a>/i.test(t[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&/^<(pre|code|kbd|script)(\s|>)/i.test(t[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&/^<\/(pre|code|kbd|script)(\s|>)/i.test(t[0])&&(this.lexer.state.inRawBlock=!1),{type:this.options.sanitize?"text":"html",raw:t[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,text:this.options.sanitize?this.options.sanitizer?this.options.sanitizer(t[0]):nt(t[0]):t[0]}}link(e){const t=this.rules.inline.link.exec(e);if(t){const e=t[2].trim();if(!this.options.pedantic&&/^</.test(e)){if(!/>$/.test(e))return;const t=gt(e.slice(0,-1),"\\");if((e.length-t.length)%2==0)return}else{const e=function(e,t){if(-1===e.indexOf(t[1]))return-1;const n=e.length;let r=0,s=0;for(;s<n;s++)if("\\"===e[s])s++;else if(e[s]===t[0])r++;else if(e[s]===t[1]&&(r--,r<0))return s;return-1}(t[2],"()");if(e>-1){const n=(0===t[0].indexOf("!")?5:4)+t[1].length+e;t[2]=t[2].substring(0,e),t[0]=t[0].substring(0,n).trim(),t[3]=""}}let n=t[2],r="";if(this.options.pedantic){const e=/^([^'"]*[^\s])\s+(['"])(.*)\2/.exec(n);e&&(n=e[1],r=e[3])}else r=t[3]?t[3].slice(1,-1):"";return n=n.trim(),/^</.test(n)&&(n=this.options.pedantic&&!/>$/.test(e)?n.slice(1):n.slice(1,-1)),yt(t,{href:n?n.replace(this.rules.inline._escapes,"$1"):n,title:r?r.replace(this.rules.inline._escapes,"$1"):r},t[0],this.lexer)}}reflink(e,t){let n;if((n=this.rules.inline.reflink.exec(e))||(n=this.rules.inline.nolink.exec(e))){let e=(n[2]||n[1]).replace(/\s+/g," ");if(e=t[e.toLowerCase()],!e){const e=n[0].charAt(0);return{type:"text",raw:e,text:e}}return yt(n,e,n[0],this.lexer)}}emStrong(e,t,n=""){let r=this.rules.inline.emStrong.lDelim.exec(e);if(!r)return;if(r[3]&&n.match(/[\p{L}\p{N}]/u))return;const s=r[1]||r[2]||"";if(!s||s&&(""===n||this.rules.inline.punctuation.exec(n))){const n=r[0].length-1;let s,i,o=n,a=0;const c="*"===r[0][0]?this.rules.inline.emStrong.rDelimAst:this.rules.inline.emStrong.rDelimUnd;for(c.lastIndex=0,t=t.slice(-1*e.length+n);null!=(r=c.exec(t));){if(s=r[1]||r[2]||r[3]||r[4]||r[5]||r[6],!s)continue;if(i=s.length,r[3]||r[4]){o+=i;continue}if((r[5]||r[6])&&n%3&&!((n+i)%3)){a+=i;continue}if(o-=i,o>0)continue;i=Math.min(i,i+o+a);const t=e.slice(0,n+r.index+(r[0].length-s.length)+i);if(Math.min(n,i)%2){const e=t.slice(1,-1);return{type:"em",raw:t,text:e,tokens:this.lexer.inlineTokens(e)}}const c=t.slice(2,-2);return{type:"strong",raw:t,text:c,tokens:this.lexer.inlineTokens(c)}}}}codespan(e){const t=this.rules.inline.code.exec(e);if(t){let e=t[2].replace(/\n/g," ");const n=/[^ ]/.test(e),r=/^ /.test(e)&&/ $/.test(e);return n&&r&&(e=e.substring(1,e.length-1)),e=nt(e,!0),{type:"codespan",raw:t[0],text:e}}}br(e){const t=this.rules.inline.br.exec(e);if(t)return{type:"br",raw:t[0]}}del(e){const t=this.rules.inline.del.exec(e);if(t)return{type:"del",raw:t[0],text:t[2],tokens:this.lexer.inlineTokens(t[2])}}autolink(e,t){const n=this.rules.inline.autolink.exec(e);if(n){let e,r;return"@"===n[2]?(e=nt(this.options.mangle?t(n[1]):n[1]),r="mailto:"+e):(e=nt(n[1]),r=e),{type:"link",raw:n[0],text:e,href:r,tokens:[{type:"text",raw:e,text:e}]}}}url(e,t){let n;if(n=this.rules.inline.url.exec(e)){let e,r;if("@"===n[2])e=nt(this.options.mangle?t(n[0]):n[0]),r="mailto:"+e;else{let t;do{t=n[0],n[0]=this.rules.inline._backpedal.exec(n[0])[0]}while(t!==n[0]);e=nt(n[0]),r="www."===n[1]?"http://"+n[0]:n[0]}return{type:"link",raw:n[0],text:e,href:r,tokens:[{type:"text",raw:e,text:e}]}}}inlineText(e,t){const n=this.rules.inline.text.exec(e);if(n){let e;return e=this.lexer.state.inRawBlock?this.options.sanitize?this.options.sanitizer?this.options.sanitizer(n[0]):nt(n[0]):n[0]:nt(this.options.smartypants?t(n[0]):n[0]),{type:"text",raw:n[0],text:e}}}}const vt={newline:/^(?: *(?:\n|$))+/,code:/^( {4}[^\n]+(?:\n(?: *(?:\n|$))*)?)+/,fences:/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,hr:/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,heading:/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,blockquote:/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/,list:/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/,html:"^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n *)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$))",def:/^ {0,3}\[(label)\]: *(?:\n *)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n *)?| *\n *)(title))? *(?:\n+|$)/,table:ht,lheading:/^((?:.|\n(?!\n))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,_paragraph:/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,text:/^[^\n]+/,_label:/(?!\s*\])(?:\\.|[^\[\]\\])+/,_title:/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/};vt.def=ot(vt.def).replace("label",vt._label).replace("title",vt._title).getRegex(),vt.bullet=/(?:[*+-]|\d{1,9}[.)])/,vt.listItemStart=ot(/^( *)(bull) */).replace("bull",vt.bullet).getRegex(),vt.list=ot(vt.list).replace(/bull/g,vt.bullet).replace("hr","\\n+(?=\\1?(?:(?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$))").replace("def","\\n+(?="+vt.def.source+")").getRegex(),vt._tag="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|section|source|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",vt._comment=/<!--(?!-?>)[\s\S]*?(?:-->|$)/,vt.html=ot(vt.html,"i").replace("comment",vt._comment).replace("tag",vt._tag).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),vt.paragraph=ot(vt._paragraph).replace("hr",vt.hr).replace("heading"," {0,3}#{1,6} ").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",vt._tag).getRegex(),vt.blockquote=ot(vt.blockquote).replace("paragraph",vt.paragraph).getRegex(),vt.normal={...vt},vt.gfm={...vt.normal,table:"^ *([^\\n ].*\\|.*)\\n {0,3}(?:\\| *)?(:?-+:? *(?:\\| *:?-+:? *)*)(?:\\| *)?(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)"},vt.gfm.table=ot(vt.gfm.table).replace("hr",vt.hr).replace("heading"," {0,3}#{1,6} ").replace("blockquote"," {0,3}>").replace("code"," {4}[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",vt._tag).getRegex(),vt.gfm.paragraph=ot(vt._paragraph).replace("hr",vt.hr).replace("heading"," {0,3}#{1,6} ").replace("|lheading","").replace("table",vt.gfm.table).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",vt._tag).getRegex(),vt.pedantic={...vt.normal,html:ot("^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:\"[^\"]*\"|'[^']*'|\\s[^'\"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))").replace("comment",vt._comment).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:ht,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:ot(vt.normal._paragraph).replace("hr",vt.hr).replace("heading"," *#{1,6} *[^\n]").replace("lheading",vt.lheading).replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").getRegex()};const $t={escape:/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,autolink:/^<(scheme:[^\s\x00-\x1f<>]*|email)>/,url:ht,tag:"^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>",link:/^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/,reflink:/^!?\[(label)\]\[(ref)\]/,nolink:/^!?\[(ref)\](?:\[\])?/,reflinkSearch:"reflink|nolink(?!\\()",emStrong:{lDelim:/^(?:\*+(?:([punct_])|[^\s*]))|^_+(?:([punct*])|([^\s_]))/,rDelimAst:/^(?:[^_*\\]|\\.)*?\_\_(?:[^_*\\]|\\.)*?\*(?:[^_*\\]|\\.)*?(?=\_\_)|(?:[^*\\]|\\.)+(?=[^*])|[punct_](\*+)(?=[\s]|$)|(?:[^punct*_\s\\]|\\.)(\*+)(?=[punct_\s]|$)|[punct_\s](\*+)(?=[^punct*_\s])|[\s](\*+)(?=[punct_])|[punct_](\*+)(?=[punct_])|(?:[^punct*_\s\\]|\\.)(\*+)(?=[^punct*_\s])/,rDelimUnd:/^(?:[^_*\\]|\\.)*?\*\*(?:[^_*\\]|\\.)*?\_(?:[^_*\\]|\\.)*?(?=\*\*)|(?:[^_\\]|\\.)+(?=[^_])|[punct*](\_+)(?=[\s]|$)|(?:[^punct*_\s\\]|\\.)(\_+)(?=[punct*\s]|$)|[punct*\s](\_+)(?=[^punct*_\s])|[\s](\_+)(?=[punct*])|[punct*](\_+)(?=[punct*])/},code:/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,br:/^( {2,}|\\)\n(?!\s*$)/,del:ht,text:/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/,punctuation:/^([\spunctuation])/};function kt(e){return e.replace(/---/g,"—").replace(/--/g,"–").replace(/(^|[-\u2014/(\[{"\s])'/g,"$1‘").replace(/'/g,"’").replace(/(^|[-\u2014/(\[{\u2018\s])"/g,"$1“").replace(/"/g,"”").replace(/\.{3}/g,"…")}function xt(e){let t,n,r="";const s=e.length;for(t=0;t<s;t++)n=e.charCodeAt(t),Math.random()>.5&&(n="x"+n.toString(16)),r+="&#"+n+";";return r}$t._punctuation="!\"#$%&'()+\\-.,/:;<=>?@\\[\\]`^{|}~",$t.punctuation=ot($t.punctuation).replace(/punctuation/g,$t._punctuation).getRegex(),$t.blockSkip=/\[[^\]]*?\]\([^\)]*?\)|`[^`]*?`|<[^>]*?>/g,$t.escapedEmSt=/(?:^|[^\\])(?:\\\\)*\\[*_]/g,$t._comment=ot(vt._comment).replace("(?:--\x3e|$)","--\x3e").getRegex(),$t.emStrong.lDelim=ot($t.emStrong.lDelim).replace(/punct/g,$t._punctuation).getRegex(),$t.emStrong.rDelimAst=ot($t.emStrong.rDelimAst,"g").replace(/punct/g,$t._punctuation).getRegex(),$t.emStrong.rDelimUnd=ot($t.emStrong.rDelimUnd,"g").replace(/punct/g,$t._punctuation).getRegex(),$t._escapes=/\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/g,$t._scheme=/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/,$t._email=/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/,$t.autolink=ot($t.autolink).replace("scheme",$t._scheme).replace("email",$t._email).getRegex(),$t._attribute=/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/,$t.tag=ot($t.tag).replace("comment",$t._comment).replace("attribute",$t._attribute).getRegex(),$t._label=/(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/,$t._href=/<(?:\\.|[^\n<>\\])+>|[^\s\x00-\x1f]*/,$t._title=/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/,$t.link=ot($t.link).replace("label",$t._label).replace("href",$t._href).replace("title",$t._title).getRegex(),$t.reflink=ot($t.reflink).replace("label",$t._label).replace("ref",vt._label).getRegex(),$t.nolink=ot($t.nolink).replace("ref",vt._label).getRegex(),$t.reflinkSearch=ot($t.reflinkSearch,"g").replace("reflink",$t.reflink).replace("nolink",$t.nolink).getRegex(),$t.normal={...$t},$t.pedantic={...$t.normal,strong:{start:/^__|\*\*/,middle:/^__(?=\S)([\s\S]*?\S)__(?!_)|^\*\*(?=\S)([\s\S]*?\S)\*\*(?!\*)/,endAst:/\*\*(?!\*)/g,endUnd:/__(?!_)/g},em:{start:/^_|\*/,middle:/^()\*(?=\S)([\s\S]*?\S)\*(?!\*)|^_(?=\S)([\s\S]*?\S)_(?!_)/,endAst:/\*(?!\*)/g,endUnd:/_(?!_)/g},link:ot(/^!?\[(label)\]\((.*?)\)/).replace("label",$t._label).getRegex(),reflink:ot(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",$t._label).getRegex()},$t.gfm={...$t.normal,escape:ot($t.escape).replace("])","~|])").getRegex(),_extended_email:/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/,url:/^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/,_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])([\s\S]*?[^\s~])\1(?=[^~]|$)/,text:/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|https?:\/\/|ftp:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/},$t.gfm.url=ot($t.gfm.url,"i").replace("email",$t.gfm._extended_email).getRegex(),$t.breaks={...$t.gfm,br:ot($t.br).replace("{2,}","*").getRegex(),text:ot($t.gfm.text).replace("\\b_","\\b_| {2,}\\n").replace(/\{2,\}/g,"*").getRegex()};class _t{constructor(e){this.tokens=[],this.tokens.links=Object.create(null),this.options=e||Ke,this.options.tokenizer=this.options.tokenizer||new wt,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options,this.tokenizer.lexer=this,this.inlineQueue=[],this.state={inLink:!1,inRawBlock:!1,top:!0};const t={block:vt.normal,inline:$t.normal};this.options.pedantic?(t.block=vt.pedantic,t.inline=$t.pedantic):this.options.gfm&&(t.block=vt.gfm,this.options.breaks?t.inline=$t.breaks:t.inline=$t.gfm),this.tokenizer.rules=t}static get rules(){return{block:vt,inline:$t}}static lex(e,t){return new _t(t).lex(e)}static lexInline(e,t){return new _t(t).inlineTokens(e)}lex(e){let t;for(e=e.replace(/\r\n|\r/g,"\n"),this.blockTokens(e,this.tokens);t=this.inlineQueue.shift();)this.inlineTokens(t.src,t.tokens);return this.tokens}blockTokens(e,t=[]){let n,r,s,i;for(e=this.options.pedantic?e.replace(/\t/g," ").replace(/^ +$/gm,""):e.replace(/^( *)(\t+)/gm,((e,t,n)=>t+" ".repeat(n.length)));e;)if(!(this.options.extensions&&this.options.extensions.block&&this.options.extensions.block.some((r=>!!(n=r.call({lexer:this},e,t))&&(e=e.substring(n.raw.length),t.push(n),!0)))))if(n=this.tokenizer.space(e))e=e.substring(n.raw.length),1===n.raw.length&&t.length>0?t[t.length-1].raw+="\n":t.push(n);else if(n=this.tokenizer.code(e))e=e.substring(n.raw.length),r=t[t.length-1],!r||"paragraph"!==r.type&&"text"!==r.type?t.push(n):(r.raw+="\n"+n.raw,r.text+="\n"+n.text,this.inlineQueue[this.inlineQueue.length-1].src=r.text);else if(n=this.tokenizer.fences(e))e=e.substring(n.raw.length),t.push(n);else if(n=this.tokenizer.heading(e))e=e.substring(n.raw.length),t.push(n);else if(n=this.tokenizer.hr(e))e=e.substring(n.raw.length),t.push(n);else if(n=this.tokenizer.blockquote(e))e=e.substring(n.raw.length),t.push(n);else if(n=this.tokenizer.list(e))e=e.substring(n.raw.length),t.push(n);else if(n=this.tokenizer.html(e))e=e.substring(n.raw.length),t.push(n);else if(n=this.tokenizer.def(e))e=e.substring(n.raw.length),r=t[t.length-1],!r||"paragraph"!==r.type&&"text"!==r.type?this.tokens.links[n.tag]||(this.tokens.links[n.tag]={href:n.href,title:n.title}):(r.raw+="\n"+n.raw,r.text+="\n"+n.raw,this.inlineQueue[this.inlineQueue.length-1].src=r.text);else if(n=this.tokenizer.table(e))e=e.substring(n.raw.length),t.push(n);else if(n=this.tokenizer.lheading(e))e=e.substring(n.raw.length),t.push(n);else{if(s=e,this.options.extensions&&this.options.extensions.startBlock){let t=1/0;const n=e.slice(1);let r;this.options.extensions.startBlock.forEach((function(e){r=e.call({lexer:this},n),"number"==typeof r&&r>=0&&(t=Math.min(t,r))})),t<1/0&&t>=0&&(s=e.substring(0,t+1))}if(this.state.top&&(n=this.tokenizer.paragraph(s)))r=t[t.length-1],i&&"paragraph"===r.type?(r.raw+="\n"+n.raw,r.text+="\n"+n.text,this.inlineQueue.pop(),this.inlineQueue[this.inlineQueue.length-1].src=r.text):t.push(n),i=s.length!==e.length,e=e.substring(n.raw.length);else if(n=this.tokenizer.text(e))e=e.substring(n.raw.length),r=t[t.length-1],r&&"text"===r.type?(r.raw+="\n"+n.raw,r.text+="\n"+n.text,this.inlineQueue.pop(),this.inlineQueue[this.inlineQueue.length-1].src=r.text):t.push(n);else if(e){const t="Infinite loop on byte: "+e.charCodeAt(0);if(this.options.silent){console.error(t);break}throw new Error(t)}}return this.state.top=!0,t}inline(e,t=[]){return this.inlineQueue.push({src:e,tokens:t}),t}inlineTokens(e,t=[]){let n,r,s,i,o,a,c=e;if(this.tokens.links){const e=Object.keys(this.tokens.links);if(e.length>0)for(;null!=(i=this.tokenizer.rules.inline.reflinkSearch.exec(c));)e.includes(i[0].slice(i[0].lastIndexOf("[")+1,-1))&&(c=c.slice(0,i.index)+"["+bt("a",i[0].length-2)+"]"+c.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;null!=(i=this.tokenizer.rules.inline.blockSkip.exec(c));)c=c.slice(0,i.index)+"["+bt("a",i[0].length-2)+"]"+c.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);for(;null!=(i=this.tokenizer.rules.inline.escapedEmSt.exec(c));)c=c.slice(0,i.index+i[0].length-2)+"++"+c.slice(this.tokenizer.rules.inline.escapedEmSt.lastIndex),this.tokenizer.rules.inline.escapedEmSt.lastIndex--;for(;e;)if(o||(a=""),o=!1,!(this.options.extensions&&this.options.extensions.inline&&this.options.extensions.inline.some((r=>!!(n=r.call({lexer:this},e,t))&&(e=e.substring(n.raw.length),t.push(n),!0)))))if(n=this.tokenizer.escape(e))e=e.substring(n.raw.length),t.push(n);else if(n=this.tokenizer.tag(e))e=e.substring(n.raw.length),r=t[t.length-1],r&&"text"===n.type&&"text"===r.type?(r.raw+=n.raw,r.text+=n.text):t.push(n);else if(n=this.tokenizer.link(e))e=e.substring(n.raw.length),t.push(n);else if(n=this.tokenizer.reflink(e,this.tokens.links))e=e.substring(n.raw.length),r=t[t.length-1],r&&"text"===n.type&&"text"===r.type?(r.raw+=n.raw,r.text+=n.text):t.push(n);else if(n=this.tokenizer.emStrong(e,c,a))e=e.substring(n.raw.length),t.push(n);else if(n=this.tokenizer.codespan(e))e=e.substring(n.raw.length),t.push(n);else if(n=this.tokenizer.br(e))e=e.substring(n.raw.length),t.push(n);else if(n=this.tokenizer.del(e))e=e.substring(n.raw.length),t.push(n);else if(n=this.tokenizer.autolink(e,xt))e=e.substring(n.raw.length),t.push(n);else if(this.state.inLink||!(n=this.tokenizer.url(e,xt))){if(s=e,this.options.extensions&&this.options.extensions.startInline){let t=1/0;const n=e.slice(1);let r;this.options.extensions.startInline.forEach((function(e){r=e.call({lexer:this},n),"number"==typeof r&&r>=0&&(t=Math.min(t,r))})),t<1/0&&t>=0&&(s=e.substring(0,t+1))}if(n=this.tokenizer.inlineText(s,kt))e=e.substring(n.raw.length),"_"!==n.raw.slice(-1)&&(a=n.raw.slice(-1)),o=!0,r=t[t.length-1],r&&"text"===r.type?(r.raw+=n.raw,r.text+=n.text):t.push(n);else if(e){const t="Infinite loop on byte: "+e.charCodeAt(0);if(this.options.silent){console.error(t);break}throw new Error(t)}}else e=e.substring(n.raw.length),t.push(n);return t}}let St=class{constructor(e){this.options=e||Ke}code(e,t,n){const r=(t||"").match(/\S*/)[0];if(this.options.highlight){const t=this.options.highlight(e,r);null!=t&&t!==e&&(n=!0,e=t)}return e=e.replace(/\n$/,"")+"\n",r?'<pre><code class="'+this.options.langPrefix+nt(r)+'">'+(n?e:nt(e,!0))+"</code></pre>\n":"<pre><code>"+(n?e:nt(e,!0))+"</code></pre>\n"}blockquote(e){return`<blockquote>\n${e}</blockquote>\n`}html(e){return e}heading(e,t,n,r){if(this.options.headerIds){return`<h${t} id="${this.options.headerPrefix+r.slug(n)}">${e}</h${t}>\n`}return`<h${t}>${e}</h${t}>\n`}hr(){return this.options.xhtml?"<hr/>\n":"<hr>\n"}list(e,t,n){const r=t?"ol":"ul";return"<"+r+(t&&1!==n?' start="'+n+'"':"")+">\n"+e+"</"+r+">\n"}listitem(e){return`<li>${e}</li>\n`}checkbox(e){return"<input "+(e?'checked="" ':"")+'disabled="" type="checkbox"'+(this.options.xhtml?" /":"")+"> "}paragraph(e){return`<p>${e}</p>\n`}table(e,t){return t&&(t=`<tbody>${t}</tbody>`),"<table>\n<thead>\n"+e+"</thead>\n"+t+"</table>\n"}tablerow(e){return`<tr>\n${e}</tr>\n`}tablecell(e,t){const n=t.header?"th":"td";return(t.align?`<${n} align="${t.align}">`:`<${n}>`)+e+`</${n}>\n`}strong(e){return`<strong>${e}</strong>`}em(e){return`<em>${e}</em>`}codespan(e){return`<code>${e}</code>`}br(){return this.options.xhtml?"<br/>":"<br>"}del(e){return`<del>${e}</del>`}link(e,t,n){if(null===(e=lt(this.options.sanitize,this.options.baseUrl,e)))return n;let r='<a href="'+e+'"';return t&&(r+=' title="'+t+'"'),r+=">"+n+"</a>",r}image(e,t,n){if(null===(e=lt(this.options.sanitize,this.options.baseUrl,e)))return n;let r=`<img src="${e}" alt="${n}"`;return t&&(r+=` title="${t}"`),r+=this.options.xhtml?"/>":">",r}text(e){return e}};class Ct{strong(e){return e}em(e){return e}codespan(e){return e}del(e){return e}html(e){return e}text(e){return e}link(e,t,n){return""+n}image(e,t,n){return""+n}br(){return""}}class Rt{constructor(){this.seen={}}serialize(e){return e.toLowerCase().trim().replace(/<[!\/a-z].*?>/gi,"").replace(/[\u2000-\u206F\u2E00-\u2E7F\\'!"#$%&()*+,./:;<=>?@[\]^`{|}~]/g,"").replace(/\s/g,"-")}getNextSafeSlug(e,t){let n=e,r=0;if(this.seen.hasOwnProperty(n)){r=this.seen[e];do{r++,n=e+"-"+r}while(this.seen.hasOwnProperty(n))}return t||(this.seen[e]=r,this.seen[n]=0),n}slug(e,t={}){const n=this.serialize(e);return this.getNextSafeSlug(n,t.dryrun)}}class Et{constructor(e){this.options=e||Ke,this.options.renderer=this.options.renderer||new St,this.renderer=this.options.renderer,this.renderer.options=this.options,this.textRenderer=new Ct,this.slugger=new Rt}static parse(e,t){return new Et(t).parse(e)}static parseInline(e,t){return new Et(t).parseInline(e)}parse(e,t=!0){let n,r,s,i,o,a,c,l,u,d,p,f,h,m,g,b,y,w,v,$="";const k=e.length;for(n=0;n<k;n++)if(d=e[n],this.options.extensions&&this.options.extensions.renderers&&this.options.extensions.renderers[d.type]&&(v=this.options.extensions.renderers[d.type].call({parser:this},d),!1!==v||!["space","hr","heading","code","table","blockquote","list","html","paragraph","text"].includes(d.type)))$+=v||"";else switch(d.type){case"space":continue;case"hr":$+=this.renderer.hr();continue;case"heading":$+=this.renderer.heading(this.parseInline(d.tokens),d.depth,st(this.parseInline(d.tokens,this.textRenderer)),this.slugger);continue;case"code":$+=this.renderer.code(d.text,d.lang,d.escaped);continue;case"table":for(l="",c="",i=d.header.length,r=0;r<i;r++)c+=this.renderer.tablecell(this.parseInline(d.header[r].tokens),{header:!0,align:d.align[r]});for(l+=this.renderer.tablerow(c),u="",i=d.rows.length,r=0;r<i;r++){for(a=d.rows[r],c="",o=a.length,s=0;s<o;s++)c+=this.renderer.tablecell(this.parseInline(a[s].tokens),{header:!1,align:d.align[s]});u+=this.renderer.tablerow(c)}$+=this.renderer.table(l,u);continue;case"blockquote":u=this.parse(d.tokens),$+=this.renderer.blockquote(u);continue;case"list":for(p=d.ordered,f=d.start,h=d.loose,i=d.items.length,u="",r=0;r<i;r++)g=d.items[r],b=g.checked,y=g.task,m="",g.task&&(w=this.renderer.checkbox(b),h?g.tokens.length>0&&"paragraph"===g.tokens[0].type?(g.tokens[0].text=w+" "+g.tokens[0].text,g.tokens[0].tokens&&g.tokens[0].tokens.length>0&&"text"===g.tokens[0].tokens[0].type&&(g.tokens[0].tokens[0].text=w+" "+g.tokens[0].tokens[0].text)):g.tokens.unshift({type:"text",text:w}):m+=w),m+=this.parse(g.tokens,h),u+=this.renderer.listitem(m,y,b);$+=this.renderer.list(u,p,f);continue;case"html":$+=this.renderer.html(d.text);continue;case"paragraph":$+=this.renderer.paragraph(this.parseInline(d.tokens));continue;case"text":for(u=d.tokens?this.parseInline(d.tokens):d.text;n+1<k&&"text"===e[n+1].type;)d=e[++n],u+="\n"+(d.tokens?this.parseInline(d.tokens):d.text);$+=t?this.renderer.paragraph(u):u;continue;default:{const e='Token with "'+d.type+'" type was not found.';if(this.options.silent)return void console.error(e);throw new Error(e)}}return $}parseInline(e,t){t=t||this.renderer;let n,r,s,i="";const o=e.length;for(n=0;n<o;n++)if(r=e[n],this.options.extensions&&this.options.extensions.renderers&&this.options.extensions.renderers[r.type]&&(s=this.options.extensions.renderers[r.type].call({parser:this},r),!1!==s||!["escape","html","link","image","strong","em","codespan","br","del","text"].includes(r.type)))i+=s||"";else switch(r.type){case"escape":case"text":i+=t.text(r.text);break;case"html":i+=t.html(r.text);break;case"link":i+=t.link(r.href,r.title,this.parseInline(r.tokens,t));break;case"image":i+=t.image(r.href,r.title,r.text);break;case"strong":i+=t.strong(this.parseInline(r.tokens,t));break;case"em":i+=t.em(this.parseInline(r.tokens,t));break;case"codespan":i+=t.codespan(r.text);break;case"br":i+=t.br();break;case"del":i+=t.del(this.parseInline(r.tokens,t));break;default:{const e='Token with "'+r.type+'" type was not found.';if(this.options.silent)return void console.error(e);throw new Error(e)}}return i}}class At{constructor(e){this.options=e||Ke}static passThroughHooks=new Set(["preprocess","postprocess"]);preprocess(e){return e}postprocess(e){return e}}function Tt(e,t){return(n,r,s)=>{"function"==typeof r&&(s=r,r=null);const i={...r},o=function(e,t,n){return r=>{if(r.message+="\nPlease report this to https://github.com/markedjs/marked.",e){const e="<p>An error occurred:</p><pre>"+nt(r.message+"",!0)+"</pre>";return t?Promise.resolve(e):n?void n(null,e):e}if(t)return Promise.reject(r);if(!n)throw r;n(r)}}((r={...Lt.defaults,...i}).silent,r.async,s);if(null==n)return o(new Error("marked(): input parameter is undefined or null"));if("string"!=typeof n)return o(new Error("marked(): input parameter is of type "+Object.prototype.toString.call(n)+", string expected"));if(function(e){e&&e.sanitize&&!e.silent&&console.warn("marked(): sanitize and sanitizer parameters are deprecated since version 0.7.0, should not be used and will be removed in the future. Read more here: https://marked.js.org/#/USING_ADVANCED.md#options")}(r),r.hooks&&(r.hooks.options=r),s){const i=r.highlight;let a;try{r.hooks&&(n=r.hooks.preprocess(n)),a=e(n,r)}catch(e){return o(e)}const c=function(e){let n;if(!e)try{r.walkTokens&&Lt.walkTokens(a,r.walkTokens),n=t(a,r),r.hooks&&(n=r.hooks.postprocess(n))}catch(t){e=t}return r.highlight=i,e?o(e):s(null,n)};if(!i||i.length<3)return c();if(delete r.highlight,!a.length)return c();let l=0;return Lt.walkTokens(a,(function(e){"code"===e.type&&(l++,setTimeout((()=>{i(e.text,e.lang,(function(t,n){if(t)return c(t);null!=n&&n!==e.text&&(e.text=n,e.escaped=!0),l--,0===l&&c()}))}),0))})),void(0===l&&c())}if(r.async)return Promise.resolve(r.hooks?r.hooks.preprocess(n):n).then((t=>e(t,r))).then((e=>r.walkTokens?Promise.all(Lt.walkTokens(e,r.walkTokens)).then((()=>e)):e)).then((e=>t(e,r))).then((e=>r.hooks?r.hooks.postprocess(e):e)).catch(o);try{r.hooks&&(n=r.hooks.preprocess(n));const s=e(n,r);r.walkTokens&&Lt.walkTokens(s,r.walkTokens);let i=t(s,r);return r.hooks&&(i=r.hooks.postprocess(i)),i}catch(e){return o(e)}}}function Lt(e,t,n){return Tt(_t.lex,Et.parse)(e,t,n)}Lt.options=Lt.setOptions=function(e){var t;return Lt.defaults={...Lt.defaults,...e},t=Lt.defaults,Ke=t,Lt},Lt.getDefaults=Ye,Lt.defaults=Ke,Lt.use=function(...e){const t=Lt.defaults.extensions||{renderers:{},childTokens:{}};e.forEach((e=>{const n={...e};if(n.async=Lt.defaults.async||n.async||!1,e.extensions&&(e.extensions.forEach((e=>{if(!e.name)throw new Error("extension name required");if(e.renderer){const n=t.renderers[e.name];t.renderers[e.name]=n?function(...t){let r=e.renderer.apply(this,t);return!1===r&&(r=n.apply(this,t)),r}:e.renderer}if(e.tokenizer){if(!e.level||"block"!==e.level&&"inline"!==e.level)throw new Error("extension level must be 'block' or 'inline'");t[e.level]?t[e.level].unshift(e.tokenizer):t[e.level]=[e.tokenizer],e.start&&("block"===e.level?t.startBlock?t.startBlock.push(e.start):t.startBlock=[e.start]:"inline"===e.level&&(t.startInline?t.startInline.push(e.start):t.startInline=[e.start]))}e.childTokens&&(t.childTokens[e.name]=e.childTokens)})),n.extensions=t),e.renderer){const t=Lt.defaults.renderer||new St;for(const n in e.renderer){const r=t[n];t[n]=(...s)=>{let i=e.renderer[n].apply(t,s);return!1===i&&(i=r.apply(t,s)),i}}n.renderer=t}if(e.tokenizer){const t=Lt.defaults.tokenizer||new wt;for(const n in e.tokenizer){const r=t[n];t[n]=(...s)=>{let i=e.tokenizer[n].apply(t,s);return!1===i&&(i=r.apply(t,s)),i}}n.tokenizer=t}if(e.hooks){const t=Lt.defaults.hooks||new At;for(const n in e.hooks){const r=t[n];At.passThroughHooks.has(n)?t[n]=s=>{if(Lt.defaults.async)return Promise.resolve(e.hooks[n].call(t,s)).then((e=>r.call(t,e)));const i=e.hooks[n].call(t,s);return r.call(t,i)}:t[n]=(...s)=>{let i=e.hooks[n].apply(t,s);return!1===i&&(i=r.apply(t,s)),i}}n.hooks=t}if(e.walkTokens){const t=Lt.defaults.walkTokens;n.walkTokens=function(n){let r=[];return r.push(e.walkTokens.call(this,n)),t&&(r=r.concat(t.call(this,n))),r}}Lt.setOptions(n)}))},Lt.walkTokens=function(e,t){let n=[];for(const r of e)switch(n=n.concat(t.call(Lt,r)),r.type){case"table":for(const e of r.header)n=n.concat(Lt.walkTokens(e.tokens,t));for(const e of r.rows)for(const r of e)n=n.concat(Lt.walkTokens(r.tokens,t));break;case"list":n=n.concat(Lt.walkTokens(r.items,t));break;default:Lt.defaults.extensions&&Lt.defaults.extensions.childTokens&&Lt.defaults.extensions.childTokens[r.type]?Lt.defaults.extensions.childTokens[r.type].forEach((function(e){n=n.concat(Lt.walkTokens(r[e],t))})):r.tokens&&(n=n.concat(Lt.walkTokens(r.tokens,t)))}return n},Lt.parseInline=Tt(_t.lexInline,Et.parseInline),Lt.Parser=Et,Lt.parser=Et.parse,Lt.Renderer=St,Lt.TextRenderer=Ct,Lt.Lexer=_t,Lt.lexer=_t.lex,Lt.Tokenizer=wt,Lt.Slugger=Rt,Lt.Hooks=At,Lt.parse=Lt,Lt.options,Lt.setOptions,Lt.use,Lt.walkTokens,Lt.parseInline;"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self&&self;function Pt(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var It,Dt={exports:{}};It=Dt,function(e,t){It.exports=t()}(0,(function(){var e=[],t=[],n={},r={},s={};function i(e){return"string"==typeof e?new RegExp("^"+e+"$","i"):e}function o(e,t){return e===t?t:e===e.toLowerCase()?t.toLowerCase():e===e.toUpperCase()?t.toUpperCase():e[0]===e[0].toUpperCase()?t.charAt(0).toUpperCase()+t.substr(1).toLowerCase():t.toLowerCase()}function a(e,t){return e.replace(/\$(\d{1,2})/g,(function(e,n){return t[n]||""}))}function c(e,t){return e.replace(t[0],(function(n,r){var s=a(t[1],arguments);return o(""===n?e[r-1]:n,s)}))}function l(e,t,r){if(!e.length||n.hasOwnProperty(e))return t;for(var s=r.length;s--;){var i=r[s];if(i[0].test(t))return c(t,i)}return t}function u(e,t,n){return function(r){var s=r.toLowerCase();return t.hasOwnProperty(s)?o(r,s):e.hasOwnProperty(s)?o(r,e[s]):l(s,r,n)}}function d(e,t,n,r){return function(r){var s=r.toLowerCase();return!!t.hasOwnProperty(s)||!e.hasOwnProperty(s)&&l(s,s,n)===s}}function p(e,t,n){return(n?t+" ":"")+(1===t?p.singular(e):p.plural(e))}return p.plural=u(s,r,e),p.isPlural=d(s,r,e),p.singular=u(r,s,t),p.isSingular=d(r,s,t),p.addPluralRule=function(t,n){e.push([i(t),n])},p.addSingularRule=function(e,n){t.push([i(e),n])},p.addUncountableRule=function(e){"string"!=typeof e?(p.addPluralRule(e,"$0"),p.addSingularRule(e,"$0")):n[e.toLowerCase()]=!0},p.addIrregularRule=function(e,t){t=t.toLowerCase(),e=e.toLowerCase(),s[e]=t,r[t]=e},[["I","we"],["me","us"],["he","they"],["she","they"],["them","them"],["myself","ourselves"],["yourself","yourselves"],["itself","themselves"],["herself","themselves"],["himself","themselves"],["themself","themselves"],["is","are"],["was","were"],["has","have"],["this","these"],["that","those"],["echo","echoes"],["dingo","dingoes"],["volcano","volcanoes"],["tornado","tornadoes"],["torpedo","torpedoes"],["genus","genera"],["viscus","viscera"],["stigma","stigmata"],["stoma","stomata"],["dogma","dogmata"],["lemma","lemmata"],["schema","schemata"],["anathema","anathemata"],["ox","oxen"],["axe","axes"],["die","dice"],["yes","yeses"],["foot","feet"],["eave","eaves"],["goose","geese"],["tooth","teeth"],["quiz","quizzes"],["human","humans"],["proof","proofs"],["carve","carves"],["valve","valves"],["looey","looies"],["thief","thieves"],["groove","grooves"],["pickaxe","pickaxes"],["passerby","passersby"]].forEach((function(e){return p.addIrregularRule(e[0],e[1])})),[[/s?$/i,"s"],[/[^\u0000-\u007F]$/i,"$0"],[/([^aeiou]ese)$/i,"$1"],[/(ax|test)is$/i,"$1es"],[/(alias|[^aou]us|t[lm]as|gas|ris)$/i,"$1es"],[/(e[mn]u)s?$/i,"$1s"],[/([^l]ias|[aeiou]las|[ejzr]as|[iu]am)$/i,"$1"],[/(alumn|syllab|vir|radi|nucle|fung|cact|stimul|termin|bacill|foc|uter|loc|strat)(?:us|i)$/i,"$1i"],[/(alumn|alg|vertebr)(?:a|ae)$/i,"$1ae"],[/(seraph|cherub)(?:im)?$/i,"$1im"],[/(her|at|gr)o$/i,"$1oes"],[/(agend|addend|millenni|dat|extrem|bacteri|desiderat|strat|candelabr|errat|ov|symposi|curricul|automat|quor)(?:a|um)$/i,"$1a"],[/(apheli|hyperbat|periheli|asyndet|noumen|phenomen|criteri|organ|prolegomen|hedr|automat)(?:a|on)$/i,"$1a"],[/sis$/i,"ses"],[/(?:(kni|wi|li)fe|(ar|l|ea|eo|oa|hoo)f)$/i,"$1$2ves"],[/([^aeiouy]|qu)y$/i,"$1ies"],[/([^ch][ieo][ln])ey$/i,"$1ies"],[/(x|ch|ss|sh|zz)$/i,"$1es"],[/(matr|cod|mur|sil|vert|ind|append)(?:ix|ex)$/i,"$1ices"],[/\b((?:tit)?m|l)(?:ice|ouse)$/i,"$1ice"],[/(pe)(?:rson|ople)$/i,"$1ople"],[/(child)(?:ren)?$/i,"$1ren"],[/eaux$/i,"$0"],[/m[ae]n$/i,"men"],["thou","you"]].forEach((function(e){return p.addPluralRule(e[0],e[1])})),[[/s$/i,""],[/(ss)$/i,"$1"],[/(wi|kni|(?:after|half|high|low|mid|non|night|[^\w]|^)li)ves$/i,"$1fe"],[/(ar|(?:wo|[ae])l|[eo][ao])ves$/i,"$1f"],[/ies$/i,"y"],[/\b([pl]|zomb|(?:neck|cross)?t|coll|faer|food|gen|goon|group|lass|talk|goal|cut)ies$/i,"$1ie"],[/\b(mon|smil)ies$/i,"$1ey"],[/\b((?:tit)?m|l)ice$/i,"$1ouse"],[/(seraph|cherub)im$/i,"$1"],[/(x|ch|ss|sh|zz|tto|go|cho|alias|[^aou]us|t[lm]as|gas|(?:her|at|gr)o|[aeiou]ris)(?:es)?$/i,"$1"],[/(analy|diagno|parenthe|progno|synop|the|empha|cri|ne)(?:sis|ses)$/i,"$1sis"],[/(movie|twelve|abuse|e[mn]u)s$/i,"$1"],[/(test)(?:is|es)$/i,"$1is"],[/(alumn|syllab|vir|radi|nucle|fung|cact|stimul|termin|bacill|foc|uter|loc|strat)(?:us|i)$/i,"$1us"],[/(agend|addend|millenni|dat|extrem|bacteri|desiderat|strat|candelabr|errat|ov|symposi|curricul|quor)a$/i,"$1um"],[/(apheli|hyperbat|periheli|asyndet|noumen|phenomen|criteri|organ|prolegomen|hedr|automat)a$/i,"$1on"],[/(alumn|alg|vertebr)ae$/i,"$1a"],[/(cod|mur|sil|vert|ind)ices$/i,"$1ex"],[/(matr|append)ices$/i,"$1ix"],[/(pe)(rson|ople)$/i,"$1rson"],[/(child)ren$/i,"$1"],[/(eau)x?$/i,"$1"],[/men$/i,"man"]].forEach((function(e){return p.addSingularRule(e[0],e[1])})),["adulthood","advice","agenda","aid","aircraft","alcohol","ammo","analytics","anime","athletics","audio","bison","blood","bream","buffalo","butter","carp","cash","chassis","chess","clothing","cod","commerce","cooperation","corps","debris","diabetes","digestion","elk","energy","equipment","excretion","expertise","firmware","flounder","fun","gallows","garbage","graffiti","hardware","headquarters","health","herpes","highjinks","homework","housework","information","jeans","justice","kudos","labour","literature","machinery","mackerel","mail","media","mews","moose","music","mud","manga","news","only","personnel","pike","plankton","pliers","police","pollution","premises","rain","research","rice","salmon","scissors","series","sewage","shambles","shrimp","software","species","staff","swine","tennis","traffic","transportation","trout","tuna","wealth","welfare","whiting","wildebeest","wildlife","you",/pok[eé]mon$/i,/[^aeiou]ese$/i,/deer$/i,/fish$/i,/measles$/i,/o[iu]s$/i,/pox$/i,/sheep$/i].forEach(p.addUncountableRule),p}));var Nt=Pt(Dt.exports),Ot=function(e){var t={};try{t.WeakMap=WeakMap}catch(u){t.WeakMap=function(e,t){var n=t.defineProperty,r=t.hasOwnProperty,s=i.prototype;return s.delete=function(e){return this.has(e)&&delete e[this._]},s.get=function(e){return this.has(e)?e[this._]:void 0},s.has=function(e){return r.call(e,this._)},s.set=function(e,t){return n(e,this._,{configurable:!0,value:t}),this},i;function i(t){n(this,"_",{value:"_@ungap/weakmap"+e++}),t&&t.forEach(o,this)}function o(e){this.set(e[0],e[1])}}(Math.random(),Object)}var n=t.WeakMap,r={};try{r.WeakSet=WeakSet}catch(u){!function(e,t){var n=s.prototype;function s(){t(this,"_",{value:"_@ungap/weakmap"+e++})}n.add=function(e){return this.has(e)||t(e,this._,{value:!0,configurable:!0}),this},n.has=function(e){return this.hasOwnProperty.call(e,this._)},n.delete=function(e){return this.has(e)&&delete e[this._]},r.WeakSet=s}(Math.random(),Object.defineProperty)}function s(e,t,n,r,s,i){for(var o=("selectedIndex"in t),a=o;r<s;){var c,l=e(n[r],1);t.insertBefore(l,i),o&&a&&l.selected&&(a=!a,c=t.selectedIndex,t.selectedIndex=c<0?r:d.call(t.querySelectorAll("option"),l)),r++}}function i(e,t){return e==t}function o(e){return e}function a(e,t,n,r,s,i,o){var a=i-s;if(a<1)return-1;for(;a<=n-t;){for(var c=t,l=s;c<n&&l<i&&o(e[c],r[l]);)c++,l++;if(l===i)return t;t=c+1}return-1}function c(e,t,n,r,s){return n<r?e(t[n],0):0<n?e(t[n-1],-0).nextSibling:s}function l(e,t,n,r){for(;n<r;)f(e(t[n++],-1))}var u=r.WeakSet,d=[].indexOf,p=function(e,t,n){for(var r=1,s=t;r<s;){var i=(r+s)/2>>>0;n<e[i]?s=i:r=1+i}return r},f=function(e){return(e.remove||function(){var e=this.parentNode;e&&e.removeChild(this)}).call(e)};function h(e,t,n,r){for(var u=(r=r||{}).compare||i,d=r.node||o,f=null==r.before?null:d(r.before,0),h=t.length,m=h,g=0,b=n.length,y=0;g<m&&y<b&&u(t[g],n[y]);)g++,y++;for(;g<m&&y<b&&u(t[m-1],n[b-1]);)m--,b--;var w=g===m,v=y===b;if(w&&v)return n;if(w&&y<b)return s(d,e,n,y,b,c(d,t,g,h,f)),n;if(v&&g<m)return l(d,t,g,m),n;var $=m-g,k=b-y,x=-1;if($<k){if(-1<(x=a(n,y,b,t,g,m,u)))return s(d,e,n,y,x,d(t[g],0)),s(d,e,n,x+$,b,c(d,t,m,h,f)),n}else if(k<$&&-1<(x=a(t,g,m,n,y,b,u)))return l(d,t,g,x),l(d,t,x+k,m),n;return $<2||k<2?(s(d,e,n,y,b,d(t[g],0)),l(d,t,g,m)):$==k&&function(e,t,n,r,s,i){for(;r<s&&i(n[r],e[t-1]);)r++,t--;return 0===t}(n,b,t,g,m,u)?s(d,e,n,y,b,c(d,t,m,h,f)):function(e,t,n,r,i,o,a,c,u,d,f,h,m){!function(e,t,n,r,i,o,a,c,u){for(var d=[],p=e.length,f=a,h=0;h<p;)switch(e[h++]){case 0:i++,f++;break;case 1:d.push(r[i]),s(t,n,r,i++,i,f<c?t(o[f],0):u);break;case-1:f++}for(h=0;h<p;)switch(e[h++]){case 0:a++;break;case-1:-1<d.indexOf(o[a])?a++:l(t,o,a++,a)}}(function(e,t,n,r,s,i,o){var a,c,l,u,d,p,f=n+i,h=[];e:for(b=0;b<=f;b++){if(50<b)return null;for(p=b-1,u=b?h[b-1]:[0,0],d=h[b]=[],a=-b;a<=b;a+=2){for(c=(l=a===-b||a!==b&&u[p+a-1]<u[p+a+1]?u[p+a+1]:u[p+a-1]+1)-a;l<i&&c<n&&o(r[s+l],e[t+c]);)l++,c++;if(l===i&&c===n)break e;d[b+a]=l}}for(var m=Array(b/2+f/2),g=m.length-1,b=h.length-1;0<=b;b--){for(;0<l&&0<c&&o(r[s+l-1],e[t+c-1]);)m[g--]=0,l--,c--;if(!b)break;p=b-1,u=b?h[b-1]:[0,0],(a=l-c)==-b||a!==b&&u[p+a-1]<u[p+a+1]?(c--,m[g--]=1):(l--,m[g--]=-1)}return m}(n,r,o,a,c,d,h)||function(e,t,n,r,s,i,o,a){var c=0,l=r<a?r:a,u=Array(l++),d=Array(l);d[0]=-1;for(var f=1;f<l;f++)d[f]=o;for(var h=s.slice(i,o),m=t;m<n;m++){var g,b=h.indexOf(e[m]);-1<b&&-1<(c=p(d,l,g=b+i))&&(d[c]=g,u[c]={newi:m,oldi:g,prev:u[c-1]})}for(c=--l,--o;d[c]>o;)--c;l=a+r-c;var y=Array(l),w=u[c];for(--n;w;){for(var v=w.newi,$=w.oldi;v<n;)y[--l]=1,--n;for(;$<o;)y[--l]=-1,--o;y[--l]=0,--n,--o,w=w.prev}for(;t<=n;)y[--l]=1,--n;for(;i<=o;)y[--l]=-1,--o;return y}(n,r,i,o,a,c,u,d),e,t,n,r,a,c,f,m)}(d,e,n,y,b,k,t,g,m,$,h,u,f),n}var m={};function g(t,n){n=n||{};var r=e.createEvent("CustomEvent");return r.initCustomEvent(t,!!n.bubbles,!!n.cancelable,n.detail),r}m.CustomEvent="function"==typeof CustomEvent?CustomEvent:(g["prototype"]=new g("").constructor.prototype,g);var b=m.CustomEvent,y={};try{y.Map=Map}catch(u){y.Map=function(){var e=0,t=[],n=[];return{delete:function(s){var i=r(s);return i&&(t.splice(e,1),n.splice(e,1)),i},forEach:function(e,r){t.forEach((function(t,s){e.call(r,n[s],t,this)}),this)},get:function(t){return r(t)?n[e]:void 0},has:r,set:function(s,i){return n[r(s)?e:t.push(s)-1]=i,this}};function r(n){return-1<(e=t.indexOf(n))}}}var w=y.Map;function v(){return this}function $(e,t){var n="_"+e+"$";return{get:function(){return this[n]||k(this,n,t.call(this,e))},set:function(e){k(this,n,e)}}}var k=function(e,t,n){return Object.defineProperty(e,t,{configurable:!0,value:"function"==typeof n?function(){return e._wire$=n.apply(this,arguments)}:n})[t]};Object.defineProperties(v.prototype,{ELEMENT_NODE:{value:1},nodeType:{value:-1}});var x,_,S,C,R,E,A={},T={},L=[],P=T.hasOwnProperty,I=0,D={attributes:A,define:function(e,t){e.indexOf("-")<0?(e in T||(I=L.push(e)),T[e]=t):A[e]=t},invoke:function(e,t){for(var n=0;n<I;n++){var r=L[n];if(P.call(e,r))return T[r](e[r],t)}}},N=Array.isArray||(_=(x={}.toString).call([]),function(e){return x.call(e)===_}),O=(S=e,C="fragment",E="content"in M(R="template")?function(e){var t=M(R);return t.innerHTML=e,t.content}:function(e){var t,n=M(C),r=M(R);return j(n,/^[^\S]*?<(col(?:group)?|t(?:head|body|foot|r|d|h))/i.test(e)?(t=RegExp.$1,r.innerHTML="<table>"+e+"</table>",r.querySelectorAll(t)):(r.innerHTML=e,r.childNodes)),n},function(e,t){return("svg"===t?function(e){var t=M(C),n=M("div");return n.innerHTML='<svg xmlns="http://www.w3.org/2000/svg">'+e+"</svg>",j(t,n.firstChild.childNodes),t}:E)(e)});function j(e,t){for(var n=t.length;n--;)e.appendChild(t[0])}function M(e){return e===C?S.createDocumentFragment():S.createElementNS("http://www.w3.org/1999/xhtml",e)}var z,U,q,W,F,B,H,G,V,Y=(U="appendChild",q="cloneNode",W="createTextNode",B=(F="importNode")in(z=e),(H=z.createDocumentFragment())[U](z[W]("g")),H[U](z[W]("")),(B?z[F](H,!0):H[q](!0)).childNodes.length<2?function e(t,n){for(var r=t[q](),s=t.childNodes||[],i=s.length,o=0;n&&o<i;o++)r[U](e(s[o],n));return r}:B?z[F]:function(e,t){return e[q](!!t)}),K="".trim||function(){return String(this).replace(/^\s+|\s+/g,"")},Z="-"+Math.random().toFixed(6)+"%",J=!1;try{G=e.createElement("template"),V="tabindex","content"in G&&(G.innerHTML="<p "+V+'="'+Z+'"></p>',G.content.childNodes[0].getAttribute(V)==Z)||(Z="_dt: "+Z.slice(1,-1)+";",J=!0)}catch(u){}var X="\x3c!--"+Z+"--\x3e",Q=/^(?:style|textarea)$/i,ee=/^(?:area|base|br|col|embed|hr|img|input|keygen|link|menuitem|meta|param|source|track|wbr)$/i,te=" \\f\\n\\r\\t",ne="[^"+te+"\\/>\"'=]+",re="["+te+"]+"+ne,se="<([A-Za-z]+[A-Za-z0-9:._-]*)((?:",ie="(?:\\s*=\\s*(?:'[^']*?'|\"[^\"]*?\"|<[^>]*?>|"+ne.replace("\\/","")+"))?)",oe=new RegExp(se+re+ie+"+)(["+te+"]*/?>)","g"),ae=new RegExp(se+re+ie+"*)(["+te+"]*/>)","g"),ce=new RegExp("("+re+"\\s*=\\s*)(['\"]?)"+X+"\\2","gi");function le(e,t,n,r){return"<"+t+n.replace(ce,ue)+r}function ue(e,t,n){return t+(n||'"')+Z+(n||'"')}function de(e,t,n){return ee.test(t)?e:"<"+t+n+"></"+t+">"}var pe=J?function(e,t){var n=t.join(" ");return t.slice.call(e,0).sort((function(e,t){return n.indexOf(e.name)<=n.indexOf(t.name)?-1:1}))}:function(e,t){return t.slice.call(e,0)};function fe(t,n,r,s){for(var i=t.childNodes,o=i.length,a=0;a<o;){var c=i[a];switch(c.nodeType){case 1:var l=s.concat(a);!function(t,n,r,s){for(var i,o=t.attributes,a=[],c=[],l=pe(o,r),u=l.length,d=0;d<u;){var p=l[d++],f=p.value===Z;if(f||1<(i=p.value.split(X)).length){var h=p.name;if(a.indexOf(h)<0){a.push(h);var m=r.shift().replace(f?/^(?:|[\S\s]*?\s)(\S+?)\s*=\s*('|")?$/:new RegExp("^(?:|[\\S\\s]*?\\s)("+h+")\\s*=\\s*('|\")[\\S\\s]*","i"),"$1"),g=o[m]||o[m.toLowerCase()];if(f)n.push(he(g,s,m,null));else{for(var b=i.length-2;b--;)r.shift();n.push(he(g,s,m,i))}}c.push(p)}}for(var y=((d=0)<(u=c.length)&&J&&!("ownerSVGElement"in t));d<u;){var w=c[d++];y&&(w.value=""),t.removeAttribute(w.name)}var v=t.nodeName;if(/^script$/i.test(v)){var $=e.createElement(v);for(u=o.length,d=0;d<u;)$.setAttributeNode(o[d++].cloneNode(!0));$.textContent=t.textContent,t.parentNode.replaceChild($,t)}}(c,n,r,l),fe(c,n,r,l);break;case 8:var u=c.textContent;if(u===Z)r.shift(),n.push(Q.test(t.nodeName)?me(t,s):{type:"any",node:c,path:s.concat(a)});else switch(u.slice(0,2)){case"/*":if("*/"!==u.slice(-2))break;case"👻":t.removeChild(c),a--,o--}break;case 3:Q.test(t.nodeName)&&K.call(c.textContent)===X&&(r.shift(),n.push(me(t,s)))}a++}}function he(e,t,n,r){return{type:"attr",node:e,path:t,name:n,sparse:r}}function me(e,t){return{type:"text",node:e,path:t}}var ge,be=(ge=new n,{get:function(e){return ge.get(e)},set:function(e,t){return ge.set(e,t),t}});function ye(e,t){var n=(e.convert||function(e){return e.join(X).replace(ae,de).replace(oe,le)})(t),r=e.transform;r&&(n=r(n));var s=O(n,e.type);ve(s);var i=[];return fe(s,i,t.slice(0),[]),{content:s,updates:function(n){for(var r=[],s=i.length,o=0,a=0;o<s;){var c=i[o++],l=function(e,t){for(var n=t.length,r=0;r<n;)e=e.childNodes[t[r++]];return e}(n,c.path);switch(c.type){case"any":r.push({fn:e.any(l,[]),sparse:!1});break;case"attr":var u=c.sparse,d=e.attribute(l,c.name,c.node);null===u?r.push({fn:d,sparse:!1}):(a+=u.length-2,r.push({fn:d,sparse:!0,values:u}));break;case"text":r.push({fn:e.text(l),sparse:!1}),l.textContent=""}}return s+=a,function(){var e=arguments.length;if(s!==e-1)throw new Error(e-1+" values instead of "+s+"\n"+t.join("${value}"));for(var i=1,o=1;i<e;){var a=r[i-o];if(a.sparse){var c=a.values,l=c[0],u=1,d=c.length;for(o+=d-2;u<d;)l+=arguments[i++]+c[u++];a.fn(l)}else a.fn(arguments[i++])}return n}}}}var we=[];function ve(e){for(var t=e.childNodes,n=t.length;n--;){var r=t[n];1!==r.nodeType&&0===K.call(r.textContent).length&&e.removeChild(r)}}var $e,ke,xe=($e=/acit|ex(?:s|g|n|p|$)|rph|ows|mnc|ntw|ine[ch]|zoo|^ord/i,ke=/([^A-Z])([A-Z]+)/g,function(e,t){return"ownerSVGElement"in e?function(e,t){var n;return(n=t?t.cloneNode(!0):(e.setAttribute("style","--hyper:style;"),e.getAttributeNode("style"))).value="",e.setAttributeNode(n),Se(n,!0)}(e,t):Se(e.style,!1)});function _e(e,t,n){return t+"-"+n.toLowerCase()}function Se(e,t){var n,r;return function(s){var i,o,a,c;switch(typeof s){case"object":if(s){if("object"===n){if(!t&&r!==s)for(o in r)o in s||(e[o]="")}else t?e.value="":e.cssText="";for(o in i=t?{}:e,s)a="number"!=typeof(c=s[o])||$e.test(o)?c:c+"px",!t&&/^--/.test(o)?i.setProperty(o,a):i[o]=a;n="object",t?e.value=function(e){var t,n=[];for(t in e)n.push(t.replace(ke,_e),":",e[t],";");return n.join("")}(r=i):r=s;break}default:r!=s&&(n="string",r=s,t?e.value=s||"":e.cssText=s||"")}}}var Ce,Re,Ee=(Ce=[].slice,(Re=Ae.prototype).ELEMENT_NODE=1,Re.nodeType=111,Re.remove=function(e){var t,n=this.childNodes,r=this.firstChild,s=this.lastChild;return this._=null,e&&2===n.length?s.parentNode.removeChild(s):((t=this.ownerDocument.createRange()).setStartBefore(e?n[1]:r),t.setEndAfter(s),t.deleteContents()),r},Re.valueOf=function(e){var t=this._,n=null==t;if(n&&(t=this._=this.ownerDocument.createDocumentFragment()),n||e)for(var r=this.childNodes,s=0,i=r.length;s<i;s++)t.appendChild(r[s]);return t},Ae);function Ae(e){var t=this.childNodes=Ce.call(e,0);this.firstChild=t[0],this.lastChild=t[t.length-1],this.ownerDocument=t[0].ownerDocument,this._=null}function Te(e){return{html:e}}function Le(e,t){switch(e.nodeType){case qe:return 1/t<0?t?e.remove(!0):e.lastChild:t?e.valueOf(!0):e.firstChild;case Ue:return Le(e.render(),t);default:return e}}function Pe(e,t){t(e.placeholder),"text"in e?Promise.resolve(e.text).then(String).then(t):"any"in e?Promise.resolve(e.any).then(t):"html"in e?Promise.resolve(e.html).then(Te).then(t):Promise.resolve(D.invoke(e,t)).then(t)}function Ie(e){return null!=e&&"then"in e}var De,Ne,Oe,je,Me,ze="ownerSVGElement",Ue=v.prototype.nodeType,qe=Ee.prototype.nodeType,We=(Ne=(De={Event:b,WeakSet:u}).Event,Oe=De.WeakSet,je=!0,Me=null,function(e){return je&&(je=!je,Me=new Oe,function(e){var t=new Oe,n=new Oe;try{new MutationObserver(o).observe(e,{subtree:!0,childList:!0})}catch(t){var r=0,s=[],i=function(e){s.push(e),clearTimeout(r),r=setTimeout((function(){o(s.splice(r=0,s.length))}),0)};e.addEventListener("DOMNodeRemoved",(function(e){i({addedNodes:[],removedNodes:[e.target]})}),!0),e.addEventListener("DOMNodeInserted",(function(e){i({addedNodes:[e.target],removedNodes:[]})}),!0)}function o(e){for(var r,s=e.length,i=0;i<s;i++)a((r=e[i]).removedNodes,"disconnected",n,t),a(r.addedNodes,"connected",t,n)}function a(e,t,n,r){for(var s,i=new Ne(t),o=e.length,a=0;a<o;1===(s=e[a++]).nodeType&&function e(t,n,r,s,i){Me.has(t)&&!s.has(t)&&(i.delete(t),s.add(t),t.dispatchEvent(n));for(var o=t.children||[],a=o.length,c=0;c<a;e(o[c++],n,r,s,i));}(s,i,t,n,r));}}(e.ownerDocument)),Me.add(e),e}),Fe=/^(?:form|list)$/i,Be=[].slice;function He(t){return this.type=t,function(t){var n=we,r=ve;return function(s){var i,o,a;return n!==s&&(i=t,o=n=s,a=be.get(o)||be.set(o,ye(i,o)),r=a.updates(Y.call(e,a.content,!0))),r.apply(null,arguments)}}(this)}var Ge=!(He.prototype={attribute:function(e,t,n){var r,s=ze in e;if("style"===t)return xe(e,n,s);if("."===t.slice(0,1))return l=e,u=t.slice(1),s?function(e){try{l[u]=e}catch(t){l.setAttribute(u,e)}}:function(e){l[u]=e};if("?"===t.slice(0,1))return o=e,a=t.slice(1),function(e){c!==!!e&&((c=!!e)?o.setAttribute(a,""):o.removeAttribute(a))};if(/^on/.test(t)){var i=t.slice(2);return"connected"===i||"disconnected"===i?We(e):t.toLowerCase()in e&&(i=i.toLowerCase()),function(t){r!==t&&(r&&e.removeEventListener(i,r,!1),(r=t)&&e.addEventListener(i,t,!1))}}if("data"===t||!s&&t in e&&!Fe.test(t))return function(n){r!==n&&(r=n,e[t]!==n&&null==n?(e[t]="",e.removeAttribute(t)):e[t]=n)};if(t in D.attributes)return function(n){var s=D.attributes[t](e,n);r!==s&&(null==(r=s)?e.removeAttribute(t):e.setAttribute(t,s))};var o,a,c,l,u,d=!1,p=n.cloneNode(!0);return function(t){r!==t&&(r=t,p.value!==t&&(null==t?(d&&(d=!1,e.removeAttributeNode(p)),p.value=t):(p.value=t,d||(d=!0,e.setAttributeNode(p)))))}},any:function(e,t){var n,r={node:Le,before:e},s=ze in e?"svg":"html",i=!1;return function o(a){switch(typeof a){case"string":case"number":case"boolean":i?n!==a&&(n=a,t[0].textContent=a):(i=!0,n=a,t=h(e.parentNode,t,[(c=a,e.ownerDocument.createTextNode(c))],r));break;case"function":o(a(e));break;case"object":case"undefined":if(null==a){i=!1,t=h(e.parentNode,t,[],r);break}default:if(i=!1,N(n=a))if(0===a.length)t.length&&(t=h(e.parentNode,t,[],r));else switch(typeof a[0]){case"string":case"number":case"boolean":o({html:a});break;case"object":if(N(a[0])&&(a=a.concat.apply([],a)),Ie(a[0])){Promise.all(a).then(o);break}default:t=h(e.parentNode,t,a,r)}else"ELEMENT_NODE"in a?t=h(e.parentNode,t,11===a.nodeType?Be.call(a.childNodes):[a],r):Ie(a)?a.then(o):"placeholder"in a?Pe(a,o):"text"in a?o(String(a.text)):"any"in a?o(a.any):"html"in a?t=h(e.parentNode,t,Be.call(O([].concat(a.html).join(""),s).childNodes),r):o("length"in a?Be.call(a):D.invoke(a,o))}var c}},text:function(e){var t;return function n(r){var s;t!==r&&("object"==(s=typeof(t=r))&&r?Ie(r)?r.then(n):"placeholder"in r?Pe(r,n):n("text"in r?String(r.text):"any"in r?r.any:"html"in r?[].concat(r.html).join(""):"length"in r?Be.call(r).join(""):D.invoke(r,n)):"function"==s?n(r(e)):e.textContent=null==r?"":r)}}}),Ve=function(t){var r,s,i,o,a=(r=(e.defaultView.navigator||{}).userAgent,/(Firefox|Safari)\/(\d+)/.test(r)&&!/(Chrom[eium]+|Android)\/(\d+)/.test(r)),c=!("raw"in t)||t.propertyIsEnumerable("raw")||!Object.isFrozen(t.raw);return a||c?(s={},i=function(e){for(var t=".",n=0;n<e.length;n++)t+=e[n].length+"."+e[n];return s[t]||(s[t]=e)},Ve=c?i:(o=new n,function(e){return o.get(e)||(n=i(t=e),o.set(t,n),n);var t,n})):Ge=!0,Ye(t)};function Ye(e){return Ge?e:Ve(e)}function Ke(e){for(var t=arguments.length,n=[Ye(e)],r=1;r<t;)n.push(arguments[r++]);return n}var Ze=new n,Je=function(e){var t,n,r;return function(){var s=Ke.apply(null,arguments);return r!==s[0]?(r=s[0],n=new He(e),t=Qe(n.apply(n,s))):n.apply(n,s),t}},Xe=function(e,t){var n=t.indexOf(":"),r=Ze.get(e),s=t;return-1<n&&(s=t.slice(n+1),t=t.slice(0,n)||"html"),r||Ze.set(e,r={}),r[s]||(r[s]=Je(t))},Qe=function(e){var t=e.childNodes,n=t.length;return 1===n?t[0]:n?new Ee(t):e},et=new n;function tt(){var e=et.get(this),t=Ke.apply(null,arguments);return e&&e.template===t[0]?e.tagger.apply(null,t):function(e){var t=new He(ze in this?"svg":"html");et.set(this,{tagger:t,template:e}),this.textContent="",this.appendChild(t.apply(null,arguments))}.apply(this,t),this}var nt,rt,st,it,ot=D.define,at=He.prototype;function ct(e){return arguments.length<2?null==e?Je("html"):"string"==typeof e?ct.wire(null,e):"raw"in e?Je("html")(e):"nodeType"in e?ct.bind(e):Xe(e,"html"):("raw"in e?Je("html"):ct.wire).apply(null,arguments)}return ct.Component=v,ct.bind=function(e){return tt.bind(e)},ct.define=ot,ct.diff=h,(ct.hyper=ct).observe=We,ct.tagger=at,ct.wire=function(e,t){return null==e?Je(t||"html"):Xe(e,t||"html")},ct._={WeakMap:n,WeakSet:u},nt=Je,rt=new n,st=Object.create,it=function(e,t){var n={w:null,p:null};return t.set(e,n),n},Object.defineProperties(v,{for:{configurable:!0,value:function(e,t){return function(e,t,r,s){var i,o,a,c=t.get(e)||it(e,t);switch(typeof s){case"object":case"function":var l=c.w||(c.w=new n);return l.get(s)||(i=l,o=s,a=new e(r),i.set(o,a),a);default:var u=c.p||(c.p=st(null));return u[s]||(u[s]=new e(r))}}(this,rt.get(e)||(r=e,s=new w,rt.set(r,s),s),e,null==t?"default":t);var r,s}}}),Object.defineProperties(v.prototype,{handleEvent:{value:function(e){var t=e.currentTarget;this["getAttribute"in t&&t.getAttribute("data-call")||"on"+e.type](e)}},html:$("html",nt),svg:$("svg",nt),state:$("state",(function(){return this.defaultState})),defaultState:{get:function(){return{}}},dispatch:{value:function(e,t){var n=this._wire$;if(n){var r=new b(e,{bubbles:!0,cancelable:!0,detail:t});return r.component=this,(n.dispatchEvent?n:n.firstChild).dispatchEvent(r)}return!1}},setState:{value:function(e,t){var n=this.state,r="function"==typeof e?e.call(this,n):e;for(var s in r)n[s]=r[s];return!1!==t&&this.render(),this}}}),ct}(document);const jt=Ot,Mt=C,zt=Lt,Ut=class{constructor(e){const{type:t,subtype:n,params:r}=function(e){if(!(e=e.trim()))throw new TypeError("Invalid input.");let t="",n="",r="",s=null,i=new Map,o="type",a=Array.from(e);for(let e=0;e<a.length;e++){const c=a[e];switch(o){case"type":if("/"===c){o="subtype";continue}t+=c;break;case"subtype":if(";"===c){o="param-start";continue}n+=c;break;case"param-start":if(He.test(c)||";"===c)continue;r+=c,o="param-name";break;case"param-name":if("="===c||";"===c){if("="===c){o="param-value",s=null;continue}i.set(r.toLowerCase(),null),r="";continue}r+=c;break;case"param-value":if('"'==c){o="collect-quoted-string";continue}if(";"===c){s=s.trimEnd(),o="param-start",Ve(i,r,s),r="";continue}s="string"==typeof s?s+c:c;break;case"collect-quoted-string":if('"'===c){Ve(i,r,s),o="ignore-input-until-next-param",r="",s=null;continue}if("\\"===c)continue;s="string"==typeof s?s+c:c;break;case"ignore-input-until-next-param":if(";"!==c)continue;o="param-start";break;default:throw new Error(`State machine error - unknown parser mode: ${o} `)}}r&&Ve(i,r,s);if(""===t.trim()||!Be.test(t))throw new TypeError("Invalid type");if(""===n.trim()||!Be.test(n))throw new TypeError("Invalid subtype");return{type:t,subtype:n,params:Object.fromEntries(i.entries())}}(e);this.type=t.trim().toLowerCase(),this.subtype=n.trimEnd().toLowerCase(),this.parameters=new Map(Object.entries(r))}get essence(){return`${this.type}/${this.subtype}`}toString(){return function(e){const{parameters:t,essence:n}=e;if(!t.size)return n;let r=";";for(const[e,n]of t.entries())r+=e,null!==n?Be.test(n)?r+=`=${n}`:r+=`="${n}"`:r+='=""',r+=";";return e.essence+r.slice(0,-1)}(this)}},qt=Nt,Wt=Fe;function Ft(e){if(!e)return e;const t=e.trimEnd().split("\n");for(;t.length&&!t[0].trim();)t.shift();const n=t.filter((e=>e.trim())).map((e=>e.search(/[^\s]/))),r=Math.min(...n);return t.map((e=>e.slice(r))).join("\n")}var Bt=Object.freeze({__proto__:null,name:"core/reindent",reindent:Ft,run:function(){for(const e of document.getElementsByTagName("pre"))e.innerHTML=Ft(e.innerHTML)}});const Ht=/-/g;const Gt=new Intl.DateTimeFormat(["sv-SE"],{timeZone:"UTC",year:"numeric",month:"2-digit",day:"2-digit"}),Vt="en"===c||c.startsWith("en-")?"en-AU":c,Yt=new Intl.DateTimeFormat(Vt,{timeZone:"UTC",year:"numeric",month:"long",day:"en-AU"===Vt?"2-digit":"numeric"}),Kt=".informative, .note, .issue, .example, .ednote, .practice, .introductory";function Zt(e){const t=new URL(e.href,document.baseURI),n=document.createElement("link");let{href:r}=t;switch(n.rel=e.hint,n.rel){case"dns-prefetch":case"preconnect":r=t.origin,(e.corsMode||t.origin!==document.location.origin)&&(n.crossOrigin=e.corsMode||"anonymous");break;case"preload":"as"in e&&n.setAttribute("as",e.as),e.corsMode&&(n.crossOrigin=e.corsMode)}return n.href=r,e.dontRemove||n.classList.add("removeOnSave"),n}function Jt(e){e.querySelectorAll(".remove, script[data-requiremodule]").forEach((e=>{e.remove()}))}function Xt(e,t="long"){const n=new Intl.ListFormat(c,{style:t,type:e});return(e,t)=>{let r=0;return n.formatToParts(e).map((({type:n,value:s})=>"element"===n&&t?t(s,r++,e):s))}}const Qt=Xt("conjunction"),en=Xt("disjunction");function tn(e,t){return Qt(e,t).join("")}function nn(e,t){return en(e,t).join("")}function rn(e){return e.replace(/&/g,"&amp;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/</g,"&lt;")}function sn(e){return e.trim().replace(/\s+/g," ")}function on(e,t=c){return t=t.toLowerCase(),new Proxy(e,{get(e,n){const r=an(e,n,t)||e.en[n];if(!r)throw new Error(`No l10n data for key: "${n}"`);return r}})}function an(e,t,n=c){return e[n=n.toLowerCase()]?.[t]||e[n.match(/^(\w{2,3})-.+$/)?.[1]]?.[t]}function cn(e,t=""){return Gt.format(e).replace(Ht,t)}function ln(e,t,...n){const r=[this,e,...n];if(t){const n=t.split(/\s+/);for(const t of n){const n=window[t];if(n)try{e=n.apply(this,r)}catch(e){An(`call to \`${t}()\` failed with: ${e}.`,"utils/runTransforms",{hint:"See developer console for stack trace."}),console.error(e)}}}return e}async function un(e,t=864e5){const n=new Request(e),r=new URL(n.url);let s,i;if("caches"in window)try{if(s=await caches.open(r.origin),i=await s.match(n),i&&new Date(i.headers.get("Expires"))>new Date)return i}catch(e){console.error("Failed to use Cache API.",e)}const o=await fetch(n);if(!o.ok&&i)return console.warn(`Returning a stale cached response for ${r}`),i;if(s&&o.ok){const e=o.clone(),r=new Headers(o.headers),i=new Date(Date.now()+t);r.set("Expires",i.toISOString());const a=new Response(await e.blob(),{headers:r});await s.put(n,a).catch(console.error)}return o}function dn(e,t=(e=>e)){const n=e.map(t),r=n.slice(0,-1).map((e=>jt`${e}, `));return jt`${r}${n[n.length-1]}`}function pn(e,t){return[].concat(Qt(e,t)).map((e=>"string"==typeof e?jt`${e}`:e))}function fn(e,t=""){const n=function(e){let t=0;for(const n of e)t=Math.imul(31,t)+n.charCodeAt(0)|0;return String(t)}(sn(e.textContent));return hn(e,t,n)}function hn(e,t="",n="",r=!1){if(e.id)return e.id;n||(n=(e.title?e.title:e.textContent).trim());let s=r?n:n.toLowerCase();if(s=s.trim().normalize("NFD").replace(/[\u0300-\u036f]/g,"").replace(/\W+/gim,"-").replace(/^-+/,"").replace(/-+$/,""),s?!/\.$/.test(s)&&/^[a-z]/i.test(t||s)||(s=`x${s}`):s="generatedID",t&&(s=`${t}-${s}`),e.ownerDocument.getElementById(s)){let t=0,n=`${s}-${t}`;for(;e.ownerDocument.getElementById(n);)t+=1,n=`${s}-${t}`;s=n}return e.id=s,s}function mn(e){const t=new Set,n="ltNodefault"in e.dataset?"":sn(e.textContent),r=e.children[0];if(e.dataset.lt?e.dataset.lt.split("|").map((e=>sn(e))).forEach((e=>t.add(e))):1===e.childNodes.length&&1===e.getElementsByTagName("abbr").length&&r.title?t.add(r.title):'""'===e.textContent&&t.add("the-empty-string"),t.add(n),t.delete(""),e.dataset.localLt){e.dataset.localLt.split("|").forEach((e=>t.add(sn(e))))}return[...t]}function gn(e,t,n={copyAttributes:!0}){if(e.localName===t)return e;const r=e.ownerDocument.createElement(t);if(n.copyAttributes)for(const{name:t,value:n}of e.attributes)r.setAttribute(t,n);return r.append(...e.childNodes),e.replaceWith(r),r}function bn(e,t){const n=t.closest(Kt);let r=!1;if(n&&(r=!t.closest(".normative")||!n.querySelector(".normative")),e.startsWith("!")){if(r)return{type:"informative",illegal:!0};r=!1}else e.startsWith("?")&&(r=!0);return{type:r?"informative":"normative",illegal:!1}}function yn(e,t){return t.append(...e.childNodes),e.appendChild(t),e}function wn(e){const t=[];for(const n of function*(e){let t=e;for(;t.previousElementSibling;)t=t.previousElementSibling,yield t}(e))"section"===n.localName&&t.push(n);return t}function vn(e,t){const n=[];let r=e.parentElement;for(;r;){const e=r.closest(t);if(!e)break;n.push(e),r=e.parentElement}return n}function $n(e){const{previousSibling:t}=e;if(!t||t.nodeType!==Node.TEXT_NODE)return"";const n=t.textContent.lastIndexOf("\n");if(-1===n)return"";const r=t.textContent.slice(n+1);return/\S/.test(r)?"":r}class kn extends Set{constructor(e=[]){super();for(const t of e)this.add(t)}add(e){return this.has(e)||this.getCanonicalKey(e)?this:super.add(e)}has(e){return super.has(e)||[...this.keys()].some((t=>t.toLowerCase()===e.toLowerCase()))}delete(e){return super.has(e)?super.delete(e):super.delete(this.getCanonicalKey(e))}getCanonicalKey(e){return super.has(e)?e:[...this.keys()].find((t=>t.toLowerCase()===e.toLowerCase()))}}function xn(e){const t=e.cloneNode(!0);return t.querySelectorAll("[id]").forEach((e=>e.removeAttribute("id"))),t.querySelectorAll("dfn").forEach((e=>{gn(e,"span",{copyAttributes:!1})})),t.hasAttribute("id")&&t.removeAttribute("id"),_n(t),t}function _n(e){const t=document.createTreeWalker(e,NodeFilter.SHOW_COMMENT);for(const e of[...Sn(t)])e.remove()}function*Sn(e){for(;e.nextNode();)yield e.currentNode}class Cn extends Map{constructor(e=[]){return super(),e.forEach((([e,t])=>{this.set(e,t)})),this}set(e,t){return super.set(e.toLowerCase(),t),this}get(e){return super.get(e.toLowerCase())}has(e){return super.has(e.toLowerCase())}delete(e){return super.delete(e.toLowerCase())}}class Rn extends Error{constructor(e,t,n){super(e);const r=n.isWarning?"ReSpecWarning":"ReSpecError";Object.assign(this,{message:e,plugin:t,name:r,...n}),n.elements&&n.elements.forEach((t=>function(e,t,n){e.classList.add("respec-offending-element"),e.hasAttribute("title")||e.setAttribute("title",n||t),e.id||hn(e,"respec-offender")}(t,e,n.title)))}toJSON(){const{message:e,name:t,stack:n}=this,{plugin:r,hint:s,elements:i,title:o,details:a}=this;return{message:e,name:t,plugin:r,hint:s,elements:i,title:o,details:a,stack:n}}}function En(e,t,n={}){const s={...n,isWarning:!1};r("error",new Rn(e,t,s))}function An(e,t,n={}){const s={...n,isWarning:!0};r("warn",new Rn(e,t,s))}function Tn(e){return e?`\`${e}\``:""}function Ln(e,{quotes:t}={quotes:!1}){return nn(e,t?e=>Tn(In(e)):Tn)}function Pn(e,{quotes:t}={quotes:!1}){return tn(e,t?e=>Tn(In(e)):Tn)}function In(e){return String(e)?`"${e}"`:""}function Dn(e,...t){return Ft(e.map(((e,n)=>{const r=t[n];if(!r)return e;if(!r.startsWith("[")&&!r.endsWith("]"))return e+r;const[s,i]=r.slice(1,-1).split("|");if(i){return`${e}[${s}](${new URL(i,"https://respec.org/docs/")})`}return`${e}[\`${s}\`](https://respec.org/docs/#${s})`})).join(""))}const Nn=new Map([["text/html","html"],["application/xml","xml"]]);function On(e,t=document){const n=Nn.get(e);if(!n){const t=[...Nn.values()].join(", ");throw new TypeError(`Invalid format: ${e}. Expected one of: ${t}.`)}const r=jn(n,t);return`data:${e};charset=utf-8,${encodeURIComponent(r)}`}function jn(e,t){const n=t.cloneNode(!0);!function(e){const{head:t,body:n,documentElement:s}=e;_n(e),e.querySelectorAll(".removeOnSave, #toc-nav").forEach((e=>e.remove())),n.classList.remove("toc-sidebar"),Jt(s);const i=e.createDocumentFragment(),o=e.querySelector("meta[name='viewport']");o&&t.firstChild!==o&&i.appendChild(o);let a=e.querySelector("meta[charset], meta[content*='charset=']");a||(a=jt`<meta charset="utf-8" />`);i.appendChild(a);const c=`ReSpec ${window.respecVersion||"Developer Channel"}`,l=jt`
2
2
  <meta name="generator" content="${c}" />
3
- `;i.appendChild(l),t.prepend(i),r("beforesave",s)}(n);let s="";if("xml"===e)s=(new XMLSerializer).serializeToString(n);else!function(e){e.querySelectorAll("style").forEach((e=>{e.innerHTML=`\n${e.innerHTML}\n`})),e.querySelectorAll("head > *").forEach((e=>{e.outerHTML=`\n${e.outerHTML}`}))}(n),n.doctype&&(s+=(new XMLSerializer).serializeToString(n.doctype)),s+=n.documentElement.outerHTML;return s}t("core/exporter",{rsDocToDataURL:Nn});class jn{constructor(){this._respecDonePromise=new Promise((e=>{s("end-all",(()=>e()),{once:!0})})),this.errors=[],this.warnings=[],s("error",(e=>{console.error(e,e.toJSON()),this.errors.push(e)})),s("warn",(e=>{console.warn(e,e.toJSON()),this.warnings.push(e)}))}get version(){return window.respecVersion}get ready(){return this._respecDonePromise}async toHTML(){return On("html",document)}}const Mn="core/post-process";const zn="core/pre-process";const Un="core/base-runner";async function qn(e){!function(){const e=new jn;Object.defineProperty(document,"respec",{value:e})}(),r("start-all",respecConfig),function(e){const t={},n=e=>Object.assign(t,e);n(e),s("amend-user-config",n),s("end-all",(()=>{const e=document.createElement("script");e.id="initialUserConfig",e.type="application/json";for(const e of i)e in t&&delete t[e];e.innerHTML=JSON.stringify(t,null,2),document.head.appendChild(e)}))}(respecConfig),function(e){const t=new URLSearchParams(document.location.search),n=Array.from(t).filter((([e,t])=>!!e&&!!t)).map((([e,t])=>{const n=decodeURIComponent(e),r=decodeURIComponent(t.replace(/%3D/g,"="));let s;try{s=JSON.parse(r)}catch{s=r}return[n,s]})),s=Object.fromEntries(n);Object.assign(e,s),r("amend-user-config",s)}(respecConfig),performance.mark(`${Un}-start`),await async function(e){if(Array.isArray(e.preProcess)){const t=e.preProcess.filter((e=>{const t="function"==typeof e;return t||Rn("Every item in `preProcess` must be a JS function.",zn),t})).map((async t=>{try{return await t(e,document)}catch(e){Rn(`Function ${t.name} threw an error during \`preProcess\`.`,zn,{hint:"See developer console."}),console.error(e)}}));await Promise.all(t)}}(respecConfig);const t=e.filter((e=>{return(t=e)&&(t.run||t.Plugin);var t}));t.forEach((e=>!e.name&&console.warn("Plugin lacks name:",e))),respecConfig.state={},await async function(e,t){for(const n of e.filter((e=>e.prepare)))try{await n.prepare(t)}catch(e){console.error(e)}}(t,respecConfig),await async function(e,t){for(const n of e){const e=n.name||"";try{await new Promise((async(r,s)=>{const i=setTimeout((()=>{const t=`Plugin ${e} took too long.`;console.error(t,n),s(new Error(t))}),15e3);performance.mark(`${e}-start`);try{n.Plugin?(await new n.Plugin(t).run(),r()):n.run&&(await n.run(t),r())}catch(e){s(e)}finally{clearTimeout(i),performance.mark(`${e}-end`),performance.measure(e,`${e}-start`,`${e}-end`)}}))}catch(e){console.error(e)}}}(t,respecConfig),respecConfig.state={},r("plugins-done",respecConfig),await async function(e){if(Array.isArray(e.postProcess)){const t=e.postProcess.filter((e=>{const t="function"==typeof e;return t||Rn("Every item in `postProcess` must be a JS function.",Mn),t})).map((async t=>{try{return await t(e,document)}catch(e){Rn(`Function ${t.name} threw an error during \`postProcess\`.`,Mn,{hint:"See developer console."}),console.error(e)}}));await Promise.all(t)}"function"==typeof e.afterEnd&&await e.afterEnd(e,document)}(respecConfig),r("end-all"),Zt(document),performance.mark(`${Un}-end`),performance.measure(Un,`${Un}-start`,`${Un}-end`)}var Wn=String.raw`.respec-modal .close-button{position:absolute;z-index:inherit;padding:.2em;font-weight:700;cursor:pointer;margin-left:5px;border:none;background:0 0}
3
+ `;i.appendChild(l),t.prepend(i),r("beforesave",s)}(n);let s="";if("xml"===e)s=(new XMLSerializer).serializeToString(n);else!function(e){e.querySelectorAll("style").forEach((e=>{e.innerHTML=`\n${e.innerHTML}\n`})),e.querySelectorAll("head > *").forEach((e=>{e.outerHTML=`\n${e.outerHTML}`}))}(n),n.doctype&&(s+=(new XMLSerializer).serializeToString(n.doctype)),s+=n.documentElement.outerHTML;return s}t("core/exporter",{rsDocToDataURL:On});class Mn{constructor(){this._respecDonePromise=new Promise((e=>{s("end-all",(()=>e()),{once:!0})})),this.errors=[],this.warnings=[],s("error",(e=>{console.error(e,e.toJSON()),this.errors.push(e)})),s("warn",(e=>{console.warn(e,e.toJSON()),this.warnings.push(e)}))}get version(){return window.respecVersion}get ready(){return this._respecDonePromise}async toHTML(){return jn("html",document)}}const zn="core/post-process";const Un="core/pre-process";const qn="core/base-runner";async function Wn(e){!function(){const e=new Mn;Object.defineProperty(document,"respec",{value:e})}(),r("start-all",respecConfig),function(e){const t={},n=e=>Object.assign(t,e);n(e),s("amend-user-config",n),s("end-all",(()=>{const e=document.createElement("script");e.id="initialUserConfig",e.type="application/json";for(const e of i)e in t&&delete t[e];e.innerHTML=JSON.stringify(t,null,2),document.head.appendChild(e)}))}(respecConfig),function(e){const t=new URLSearchParams(document.location.search),n=Array.from(t).filter((([e,t])=>!!e&&!!t)).map((([e,t])=>{const n=decodeURIComponent(e),r=decodeURIComponent(t.replace(/%3D/g,"="));let s;try{s=JSON.parse(r)}catch{s=r}return[n,s]})),s=Object.fromEntries(n);Object.assign(e,s),r("amend-user-config",s)}(respecConfig),performance.mark(`${qn}-start`),await async function(e){if(Array.isArray(e.preProcess)){const t=e.preProcess.filter((e=>{const t="function"==typeof e;return t||En("Every item in `preProcess` must be a JS function.",Un),t})).map((async t=>{try{return await t(e,document)}catch(e){En(`Function ${t.name} threw an error during \`preProcess\`.`,Un,{hint:"See developer console."}),console.error(e)}}));await Promise.all(t)}}(respecConfig);const t=e.filter((e=>{return(t=e)&&(t.run||t.Plugin);var t}));t.forEach((e=>!e.name&&console.warn("Plugin lacks name:",e))),respecConfig.state={},await async function(e,t){for(const n of e.filter((e=>e.prepare)))try{await n.prepare(t)}catch(e){console.error(e)}}(t,respecConfig),await async function(e,t){for(const n of e){const e=n.name||"";try{await new Promise((async(r,s)=>{const i=setTimeout((()=>{const t=`Plugin ${e} took too long.`;console.error(t,n),s(new Error(t))}),15e3);performance.mark(`${e}-start`);try{n.Plugin?(await new n.Plugin(t).run(),r()):n.run&&(await n.run(t),r())}catch(e){s(e)}finally{clearTimeout(i),performance.mark(`${e}-end`),performance.measure(e,`${e}-start`,`${e}-end`)}}))}catch(e){console.error(e)}}}(t,respecConfig),respecConfig.state={},r("plugins-done",respecConfig),await async function(e){if(Array.isArray(e.postProcess)){const t=e.postProcess.filter((e=>{const t="function"==typeof e;return t||En("Every item in `postProcess` must be a JS function.",zn),t})).map((async t=>{try{return await t(e,document)}catch(e){En(`Function ${t.name} threw an error during \`postProcess\`.`,zn,{hint:"See developer console."}),console.error(e)}}));await Promise.all(t)}"function"==typeof e.afterEnd&&await e.afterEnd(e,document)}(respecConfig),r("end-all"),Jt(document),performance.mark(`${qn}-end`),performance.measure(qn,`${qn}-start`,`${qn}-end`)}var Fn=String.raw`.respec-modal .close-button{position:absolute;z-index:inherit;padding:.2em;font-weight:700;cursor:pointer;margin-left:5px;border:none;background:0 0}
4
4
  #respec-ui{position:fixed;display:flex;flex-direction:row-reverse;top:20px;right:20px;width:202px;text-align:right;z-index:9000}
5
5
  #respec-pill,.respec-info-button{height:2.4em;background:#fff;color:#787878;border:1px solid #ccc;box-shadow:1px 1px 8px 0 rgba(100,100,100,.5);padding:.2em 0}
6
6
  .respec-info-button{border:none;opacity:.75;border-radius:2em;margin-right:1em;min-width:3.5em;will-change:opacity}
@@ -64,42 +64,42 @@ to{margin-top:0;border:1px solid #ccc;border-radius:0;box-shadow:1px 1px 8px 0 r
64
64
  .respec-iframe:not(.ready){background:url(https://respec.org/xref/loader.gif) no-repeat center}
65
65
  .respec-iframe+a[href]{font-size:.9rem;float:right;margin:0 .5em .5em;border-bottom-width:1px}
66
66
  p:is(.respec-hint,.respec-occurrences){display:block;margin-top:.5em}
67
- .respec-plugin{text-align:right;color:rgb(120,120,120,.5);font-size:.6em}`;const Fn=/&gt;/gm,Bn=/&amp;/gm;class Hn extends Mt.Renderer{code(e,t,n){const{language:r,...s}=Hn.parseInfoString(t);if(/(^webidl$)/i.test(r))return`<pre class="idl">${e}</pre>`;const i=super.code(e,r,n),{example:o,illegalExample:a}=s;if(!o&&!a)return i;const c=o||a,l=`${r} ${o?"example":"illegal-example"}`;return i.replace("<pre>",`<pre title="${c}" class="${l}">`)}image(e,t,n){if(!t)return super.image(e,t,n);return String.raw`
67
+ .respec-plugin{text-align:right;color:rgb(120,120,120,.5);font-size:.6em}`;const Bn=/&gt;/gm,Hn=/&amp;/gm;class Gn extends zt.Renderer{code(e,t,n){const{language:r,...s}=Gn.parseInfoString(t);if(/(^webidl$)/i.test(r))return`<pre class="idl">${e}</pre>`;const i=super.code(e,r,n),{example:o,illegalExample:a}=s;if(!o&&!a)return i;const c=o||a,l=`${r} ${o?"example":"illegal-example"}`;return i.replace("<pre>",`<pre title="${c}" class="${l}">`)}image(e,t,n){if(!t)return super.image(e,t,n);return String.raw`
68
68
  <figure>
69
69
  <img src="${e}" alt="${n}" />
70
70
  <figcaption>${t}</figcaption>
71
71
  </figure>
72
- `}static parseInfoString(e){const t=e.search(/\s/);if(-1===t)return{language:e};const n=e.slice(0,t),r=e.slice(t+1);let s;if(r)try{s=JSON.parse(`{ ${r} }`)}catch(e){console.error(e)}return{language:n,...s}}heading(e,t,n,r){const s=/(.+)\s+{#([\w-]+)}$/;if(s.test(e)){const[,n,r]=e.match(s);return`<h${t} id="${r}">${n}</h${t}>`}return super.heading(e,t,n,r)}}const Gn={sanitize:!1,gfm:!0,headerIds:!1,langPrefix:"",renderer:new Hn};function Vn(e,t={inline:!1}){const n=Wt(e).replace(Fn,">").replace(Bn,"&");return t.inline?Mt.parseInline(n,Gn):Mt.parse(n,Gn)}function Yn(e){for(const t of e.getElementsByTagName("pre"))t.prepend("\n");e.innerHTML=Vn(e.innerHTML)}const Kn=(Zn="[data-format='markdown']:not(body)",e=>{const t=e.querySelectorAll(Zn);return t.forEach(Yn),Array.from(t)});var Zn;var Jn=Object.freeze({__proto__:null,markdownToHtml:Vn,name:"core/markdown",run:function(e){const t=!!document.querySelector("[data-format=markdown]:not(body)"),n="markdown"===e.format;if(!n&&!t)return;if(!n)return void Kn(document.body);const r=document.getElementById("respec-ui");r.remove();const s=document.body.cloneNode(!0);!function(e,t){const n=e.querySelectorAll(t);for(const e of n){const{innerHTML:t}=e;if(/^<\w/.test(t.trimStart()))continue;const n=t.split("\n"),r=n.slice(0,2).join("\n"),s=n.slice(-2).join("\n");if(r.trim()&&e.prepend("\n\n"),s.trim()){const t=vn(e);e.append(`\n\n${t}`)}}}(s,"[data-format=markdown], section, div, address, article, aside, figure, header, main"),Yn(s),function(e){Array.from(e).forEach((e=>{e.replaceWith(e.textContent)}))}(s.querySelectorAll(".nolinks a[href]")),s.append(r),document.body.replaceWith(s)}});function Xn(e,t){e&&Array.from(t).forEach((([t,n])=>{e.setAttribute(`aria-${t}`,n)}))}!function(){const e=document.createElement("style");e.id="respec-ui-styles",e.textContent=Wn,e.classList.add("removeOnSave"),document.head.appendChild(e)}();const Qn=Ot`<div id="respec-ui" class="removeOnSave" hidden></div>`,er=Ot`<ul
72
+ `}static parseInfoString(e){const t=e.search(/\s/);if(-1===t)return{language:e};const n=e.slice(0,t),r=e.slice(t+1);let s;if(r)try{s=JSON.parse(`{ ${r} }`)}catch(e){console.error(e)}return{language:n,...s}}heading(e,t,n,r){const s=/(.+)\s+{#([\w-]+)}$/;if(s.test(e)){const[,n,r]=e.match(s);return`<h${t} id="${r}">${n}</h${t}>`}return super.heading(e,t,n,r)}}const Vn={sanitize:!1,gfm:!0,headerIds:!1,langPrefix:"",renderer:new Gn};function Yn(e,t={inline:!1}){const n=Ft(e).replace(Bn,">").replace(Hn,"&");return t.inline?zt.parseInline(n,Vn):zt.parse(n,Vn)}function Kn(e){for(const t of e.getElementsByTagName("pre"))t.prepend("\n");e.innerHTML=Yn(e.innerHTML)}const Zn=(Jn="[data-format='markdown']:not(body)",e=>{const t=e.querySelectorAll(Jn);return t.forEach(Kn),Array.from(t)});var Jn;var Xn=Object.freeze({__proto__:null,markdownToHtml:Yn,name:"core/markdown",run:function(e){const t=!!document.querySelector("[data-format=markdown]:not(body)"),n="markdown"===e.format;if(!n&&!t)return;if(!n)return void Zn(document.body);const r=document.getElementById("respec-ui");r.remove();const s=document.body.cloneNode(!0);!function(e,t){const n=e.querySelectorAll(t);for(const e of n){const{innerHTML:t}=e;if(/^<\w/.test(t.trimStart()))continue;const n=t.split("\n"),r=n.slice(0,2).join("\n"),s=n.slice(-2).join("\n");if(r.trim()&&e.prepend("\n\n"),s.trim()){const t=$n(e);e.append(`\n\n${t}`)}}}(s,"[data-format=markdown], section, div, address, article, aside, figure, header, main"),Kn(s),function(e){Array.from(e).forEach((e=>{e.replaceWith(e.textContent)}))}(s.querySelectorAll(".nolinks a[href]")),s.append(r),document.body.replaceWith(s)}});function Qn(e,t){e&&Array.from(t).forEach((([t,n])=>{e.setAttribute(`aria-${t}`,n)}))}!function(){const e=document.createElement("style");e.id="respec-ui-styles",e.textContent=Fn,e.classList.add("removeOnSave"),document.head.appendChild(e)}();const er=jt`<div id="respec-ui" class="removeOnSave" hidden></div>`,tr=jt`<ul
73
73
  id="respec-menu"
74
74
  role="menu"
75
75
  aria-labelledby="respec-pill"
76
76
  hidden
77
- ></ul>`,tr=Ot`<button
77
+ ></ul>`,nr=jt`<button
78
78
  class="close-button"
79
- onclick=${()=>pr.closeModal()}
79
+ onclick=${()=>fr.closeModal()}
80
80
  title="Close"
81
81
  >
82
82
 
83
- </button>`;let nr,rr;window.addEventListener("load",(()=>lr(er)));const sr=[],ir=[],or={};s("start-all",(()=>document.body.prepend(Qn)),{once:!0}),s("end-all",(()=>document.body.prepend(Qn)),{once:!0});const ar=Ot`<button id="respec-pill" disabled>ReSpec</button>`;function cr(){er.classList.toggle("respec-hidden"),er.classList.toggle("respec-visible"),er.hidden=!er.hidden}function lr(e){const t=e.querySelectorAll("a[href]:not([disabled]), button:not([disabled]), textarea:not([disabled]), input:not([disabled]), select:not([disabled])"),n=t[0],r=t[t.length-1];n&&n.focus(),e.addEventListener("keydown",(e=>{"Tab"===e.key&&(e.shiftKey?document.activeElement===n&&(r.focus(),e.preventDefault()):document.activeElement===r&&(n.focus(),e.preventDefault()))}))}Qn.appendChild(ar),ar.addEventListener("click",(e=>{e.stopPropagation(),ar.setAttribute("aria-expanded",String(er.hidden)),cr(),er.querySelector("li:first-child button").focus()})),document.documentElement.addEventListener("click",(()=>{er.hidden||cr()})),Qn.appendChild(er),er.addEventListener("keydown",(e=>{"Escape"!==e.key||er.hidden||(ar.setAttribute("aria-expanded",String(er.hidden)),cr(),ar.focus())}));const ur=new Map([["controls","respec-menu"],["expanded","false"],["haspopup","true"],["label","ReSpec Menu"]]);function dr(e,t,n,r){t.push(e),or.hasOwnProperty(n)||(or[n]=function(e,t,n){const r=Ot`<button
83
+ </button>`;let rr,sr;window.addEventListener("load",(()=>ur(tr)));const ir=[],or=[],ar={};s("start-all",(()=>document.body.prepend(er)),{once:!0}),s("end-all",(()=>document.body.prepend(er)),{once:!0});const cr=jt`<button id="respec-pill" disabled>ReSpec</button>`;function lr(){tr.classList.toggle("respec-hidden"),tr.classList.toggle("respec-visible"),tr.hidden=!tr.hidden}function ur(e){const t=e.querySelectorAll("a[href]:not([disabled]), button:not([disabled]), textarea:not([disabled]), input:not([disabled]), select:not([disabled])"),n=t[0],r=t[t.length-1];n&&n.focus(),e.addEventListener("keydown",(e=>{"Tab"===e.key&&(e.shiftKey?document.activeElement===n&&(r.focus(),e.preventDefault()):document.activeElement===r&&(n.focus(),e.preventDefault()))}))}er.appendChild(cr),cr.addEventListener("click",(e=>{e.stopPropagation(),cr.setAttribute("aria-expanded",String(tr.hidden)),lr(),tr.querySelector("li:first-child button").focus()})),document.documentElement.addEventListener("click",(()=>{tr.hidden||lr()})),er.appendChild(tr),tr.addEventListener("keydown",(e=>{"Escape"!==e.key||tr.hidden||(cr.setAttribute("aria-expanded",String(tr.hidden)),lr(),cr.focus())}));const dr=new Map([["controls","respec-menu"],["expanded","false"],["haspopup","true"],["label","ReSpec Menu"]]);function pr(e,t,n,r){t.push(e),ar.hasOwnProperty(n)||(ar[n]=function(e,t,n){const r=jt`<button
84
84
  id="${`respec-pill-${e}`}"
85
85
  class="respec-info-button"
86
- ></button>`;r.addEventListener("click",(()=>{r.setAttribute("aria-expanded","true");const s=Ot`<ol class="${`respec-${e}-list`}"></ol>`;for(const e of t){const t=document.createRange().createContextualFragment(fr(e)),n=document.createElement("li");t.firstElementChild===t.lastElementChild?n.append(...t.firstElementChild.childNodes):n.appendChild(t),s.appendChild(n)}pr.freshModal(n,s,r)}));const s=new Map([["expanded","false"],["haspopup","true"],["controls",`respec-pill-${e}-modal`]]);return Xn(r,s),r}(n,t,r),Qn.appendChild(or[n]));const s=or[n];s.textContent=t.length;const i=1===t.length?Ut.singular(r):r;Xn(s,new Map([["label",`${t.length} ${i}`]]))}Xn(ar,ur);const pr={show(){try{Qn.hidden=!1}catch(e){console.error(e)}},hide(){Qn.hidden=!0},enable(){ar.removeAttribute("disabled")},addCommand(e,t,n,r){r=r||"";const s=`respec-button-${e.toLowerCase().replace(/\s+/,"-")}`,i=Ot`<button id="${s}" class="respec-option">
86
+ ></button>`;r.addEventListener("click",(()=>{r.setAttribute("aria-expanded","true");const s=jt`<ol class="${`respec-${e}-list`}"></ol>`;for(const e of t){const t=document.createRange().createContextualFragment(hr(e)),n=document.createElement("li");t.firstElementChild===t.lastElementChild?n.append(...t.firstElementChild.childNodes):n.appendChild(t),s.appendChild(n)}fr.freshModal(n,s,r)}));const s=new Map([["expanded","false"],["haspopup","true"],["controls",`respec-pill-${e}-modal`]]);return Qn(r,s),r}(n,t,r),er.appendChild(ar[n]));const s=ar[n];s.textContent=t.length;const i=1===t.length?qt.singular(r):r;Qn(s,new Map([["label",`${t.length} ${i}`]]))}Qn(cr,dr);const fr={show(){try{er.hidden=!1}catch(e){console.error(e)}},hide(){er.hidden=!0},enable(){cr.removeAttribute("disabled")},addCommand(e,t,n,r){r=r||"";const s=`respec-button-${e.toLowerCase().replace(/\s+/,"-")}`,i=jt`<button id="${s}" class="respec-option">
87
87
  <span class="respec-cmd-icon" aria-hidden="true">${r}</span> ${e}…
88
- </button>`,o=Ot`<li role="menuitem">${i}</li>`;return o.addEventListener("click",t),er.appendChild(o),i},error(e){dr(e,sr,"error","ReSpec Errors")},warning(e){dr(e,ir,"warning","ReSpec Warnings")},closeModal(e){rr&&(rr.classList.remove("respec-show-overlay"),rr.classList.add("respec-hide-overlay"),rr.addEventListener("transitionend",(()=>{rr.remove(),rr=null}))),e&&e.setAttribute("aria-expanded","false"),nr&&(nr.remove(),nr=null,ar.focus())},freshModal(e,t,n){nr&&nr.remove(),rr&&rr.remove(),rr=Ot`<div id="respec-overlay" class="removeOnSave"></div>`;const r=`${n.id}-modal`,s=`${r}-heading`;nr=Ot`<div
88
+ </button>`,o=jt`<li role="menuitem">${i}</li>`;return o.addEventListener("click",t),tr.appendChild(o),i},error(e){pr(e,ir,"error","ReSpec Errors")},warning(e){pr(e,or,"warning","ReSpec Warnings")},closeModal(e){sr&&(sr.classList.remove("respec-show-overlay"),sr.classList.add("respec-hide-overlay"),sr.addEventListener("transitionend",(()=>{sr.remove(),sr=null}))),e&&e.setAttribute("aria-expanded","false"),rr&&(rr.remove(),rr=null,cr.focus())},freshModal(e,t,n){rr&&rr.remove(),sr&&sr.remove(),sr=jt`<div id="respec-overlay" class="removeOnSave"></div>`;const r=`${n.id}-modal`,s=`${r}-heading`;rr=jt`<div
89
89
  id="${r}"
90
90
  class="respec-modal removeOnSave"
91
91
  role="dialog"
92
92
  aria-labelledby="${s}"
93
93
  >
94
- ${tr}
94
+ ${nr}
95
95
  <h3 id="${s}">${e}</h3>
96
96
  <div class="inside">${t}</div>
97
- </div>`;const i=new Map([["labelledby",s]]);Xn(nr,i),document.body.append(rr,nr),rr.addEventListener("click",(()=>this.closeModal(n))),rr.classList.toggle("respec-show-overlay"),nr.hidden=!1,lr(nr)}};function fr(e){if("string"==typeof e)return e;const t=e.plugin?`<p class="respec-plugin">(plugin: "${e.plugin}")</p>`:"",n=e.hint?`\n${Vn(`<p class="respec-hint"><strong>How to fix:</strong> ${Wt(e.hint)}`,{inline:!e.hint.includes("\n")})}\n`:"",r=Array.isArray(e.elements)?`<p class="respec-occurrences">Occurred <strong>${e.elements.length}</strong> times at:</p>\n ${Vn(e.elements.map(hr).join("\n"))}`:"",s=e.details?`\n\n<details>\n${e.details}\n</details>\n`:"";return`${Vn(`**${e.message}**`,{inline:!0})}${n}${r}${s}${t}`}function hr(e){return`* [\`<${e.localName}>\`](#${e.id}) element`}async function mr(e){try{pr.show(),await async function(){"loading"===document.readyState&&await new Promise((e=>document.addEventListener("DOMContentLoaded",e)))}(),await qn(e)}finally{pr.enable()}}document.addEventListener("keydown",(e=>{"Escape"===e.key&&pr.closeModal()})),window.respecUI=pr,s("error",(e=>pr.error(e))),s("warn",(e=>pr.warning(e))),window.addEventListener("error",(e=>{console.error(e.error,e.message,e)}));const gr=[Promise.resolve().then((function(){return br})),Promise.resolve().then((function(){return l})),Promise.resolve().then((function(){return vr})),Promise.resolve().then((function(){return ps})),Promise.resolve().then((function(){return ms})),Promise.resolve().then((function(){return ys})),Promise.resolve().then((function(){return _s})),Promise.resolve().then((function(){return Ps})),Promise.resolve().then((function(){return Jn})),Promise.resolve().then((function(){return Ft})),Promise.resolve().then((function(){return Ns})),Promise.resolve().then((function(){return Ms})),Promise.resolve().then((function(){return os})),Promise.resolve().then((function(){return qs})),Promise.resolve().then((function(){return Ws})),Promise.resolve().then((function(){return Hs})),Promise.resolve().then((function(){return eo})),Promise.resolve().then((function(){return ro})),Promise.resolve().then((function(){return mo})),Promise.resolve().then((function(){return go})),Promise.resolve().then((function(){return vo})),Promise.resolve().then((function(){return Co})),Promise.resolve().then((function(){return To})),Promise.resolve().then((function(){return Io})),Promise.resolve().then((function(){return No})),Promise.resolve().then((function(){return ra})),Promise.resolve().then((function(){return $i})),Promise.resolve().then((function(){return xa})),Promise.resolve().then((function(){return Ma})),Promise.resolve().then((function(){return fa})),Promise.resolve().then((function(){return Pi})),Promise.resolve().then((function(){return Ja})),Promise.resolve().then((function(){return Qa})),Promise.resolve().then((function(){return Es})),Promise.resolve().then((function(){return ec})),Promise.resolve().then((function(){return tc})),Promise.resolve().then((function(){return lc})),Promise.resolve().then((function(){return dc})),Promise.resolve().then((function(){return fc})),Promise.resolve().then((function(){return wc})),Promise.resolve().then((function(){return Rc})),Promise.resolve().then((function(){return Lc})),Promise.resolve().then((function(){return Nc})),Promise.resolve().then((function(){return zc})),Promise.resolve().then((function(){return Hc})),Promise.resolve().then((function(){return Gc})),Promise.resolve().then((function(){return Xc})),Promise.resolve().then((function(){return il})),Promise.resolve().then((function(){return Bo})),Promise.resolve().then((function(){return pl})),Promise.resolve().then((function(){return bl})),Promise.resolve().then((function(){return xl})),Promise.resolve().then((function(){return Cl})),Promise.resolve().then((function(){return Rl})),Promise.resolve().then((function(){return Nl})),Promise.resolve().then((function(){return Ml})),Promise.resolve().then((function(){return Fl})),Promise.resolve().then((function(){return Bl})),Promise.resolve().then((function(){return Gl})),Promise.resolve().then((function(){return Kl})),Promise.resolve().then((function(){return Ql})),Promise.resolve().then((function(){return nu})),Promise.resolve().then((function(){return ou})),Promise.resolve().then((function(){return lu})),Promise.resolve().then((function(){return hu})),Promise.resolve().then((function(){return bu})),Promise.resolve().then((function(){return vu})),Promise.resolve().then((function(){return Su})),Promise.resolve().then((function(){return Au})),Promise.resolve().then((function(){return Pu})),Promise.resolve().then((function(){return Ou})),Promise.resolve().then((function(){return Uu}))];Promise.all(gr).then((e=>mr(e))).catch((e=>console.error(e)));var br=Object.freeze({__proto__:null,name:"core/location-hash",run:function(){location.hash&&document.respec.ready.then((()=>{let e=decodeURIComponent(location.hash).substr(1);const t=document.getElementById(e),n=/\W/.test(e);if(!t&&n){const t=e.replace(/[\W]+/gim,"-").replace(/^-+/,"").replace(/-+$/,"");document.getElementById(t)&&(e=t)}location.hash=`#${e}`}))}});const yr="w3c/group";async function wr(e){let t="",n=e;e.includes("/")&&([t,n]=e.split("/",2));const r=new URL(`${n}/${t}`,"https://respec.org/w3c/groups/"),s=await ln(r.href);if(s.ok){const e=await s.json(),{id:t,name:n,patentURI:r,patentPolicy:i,type:o,wgURI:a}=e;return{wg:n,wgId:t,wgURI:a,wgPatentURI:r,wgPatentPolicy:i,groupType:o}}const i=await s.text();let o,a=`Failed to fetch group details (HTTP: ${s.status}).`;409===s.status?[a,o]=i.split("\n",2):404===s.status&&(o=In`See the list of [supported group names](https://respec.org/w3c/groups/) to use with the ${"[group]"} configuration option.`),Rn(a,yr,{hint:o})}var vr=Object.freeze({__proto__:null,name:yr,run:async function(e){if(!e.group)return;const{group:t}=e,n=Array.isArray(t)?await async function(e){const t=await Promise.all(e.map(wr)),n={wg:[],wgId:[],wgURI:[],wgPatentURI:[],wgPatentPolicy:[],groupType:[]};for(const e of t.filter((e=>e)))for(const t of Object.keys(n))n[t].push(e[t]);return n}(t):await wr(t);Object.assign(e,n)}});function $r(e){if(!e.key){const t="Found a link without `key` attribute in the configuration. See dev console.";return En(t,"core/templates/show-link"),void console.warn(t,e)}return Ot`
97
+ </div>`;const i=new Map([["labelledby",s]]);Qn(rr,i),document.body.append(sr,rr),sr.addEventListener("click",(()=>this.closeModal(n))),sr.classList.toggle("respec-show-overlay"),rr.hidden=!1,ur(rr)}};function hr(e){if("string"==typeof e)return e;const t=e.plugin?`<p class="respec-plugin">(plugin: "${e.plugin}")</p>`:"",n=e.hint?`\n${Yn(`<p class="respec-hint"><strong>How to fix:</strong> ${Ft(e.hint)}`,{inline:!e.hint.includes("\n")})}\n`:"",r=Array.isArray(e.elements)?`<p class="respec-occurrences">Occurred <strong>${e.elements.length}</strong> times at:</p>\n ${Yn(e.elements.map(mr).join("\n"))}`:"",s=e.details?`\n\n<details>\n${e.details}\n</details>\n`:"";return`${Yn(`**${e.message}**`,{inline:!0})}${n}${r}${s}${t}`}function mr(e){return`* [\`<${e.localName}>\`](#${e.id}) element`}async function gr(e){try{fr.show(),await async function(){"loading"===document.readyState&&await new Promise((e=>document.addEventListener("DOMContentLoaded",e)))}(),await Wn(e)}finally{fr.enable()}}document.addEventListener("keydown",(e=>{"Escape"===e.key&&fr.closeModal()})),window.respecUI=fr,s("error",(e=>fr.error(e))),s("warn",(e=>fr.warning(e))),window.addEventListener("error",(e=>{console.error(e.error,e.message,e)}));const br=[Promise.resolve().then((function(){return yr})),Promise.resolve().then((function(){return l})),Promise.resolve().then((function(){return $r})),Promise.resolve().then((function(){return fs})),Promise.resolve().then((function(){return gs})),Promise.resolve().then((function(){return ws})),Promise.resolve().then((function(){return Ss})),Promise.resolve().then((function(){return Is})),Promise.resolve().then((function(){return Xn})),Promise.resolve().then((function(){return Bt})),Promise.resolve().then((function(){return Os})),Promise.resolve().then((function(){return zs})),Promise.resolve().then((function(){return as})),Promise.resolve().then((function(){return Ws})),Promise.resolve().then((function(){return Fs})),Promise.resolve().then((function(){return Gs})),Promise.resolve().then((function(){return to})),Promise.resolve().then((function(){return so})),Promise.resolve().then((function(){return go})),Promise.resolve().then((function(){return bo})),Promise.resolve().then((function(){return $o})),Promise.resolve().then((function(){return Co})),Promise.resolve().then((function(){return Lo})),Promise.resolve().then((function(){return Do})),Promise.resolve().then((function(){return Oo})),Promise.resolve().then((function(){return sa})),Promise.resolve().then((function(){return ki})),Promise.resolve().then((function(){return _a})),Promise.resolve().then((function(){return za})),Promise.resolve().then((function(){return ha})),Promise.resolve().then((function(){return Ii})),Promise.resolve().then((function(){return Xa})),Promise.resolve().then((function(){return ec})),Promise.resolve().then((function(){return As})),Promise.resolve().then((function(){return tc})),Promise.resolve().then((function(){return nc})),Promise.resolve().then((function(){return uc})),Promise.resolve().then((function(){return pc})),Promise.resolve().then((function(){return hc})),Promise.resolve().then((function(){return vc})),Promise.resolve().then((function(){return Ec})),Promise.resolve().then((function(){return Pc})),Promise.resolve().then((function(){return Oc})),Promise.resolve().then((function(){return Uc})),Promise.resolve().then((function(){return Gc})),Promise.resolve().then((function(){return Vc})),Promise.resolve().then((function(){return Qc})),Promise.resolve().then((function(){return ol})),Promise.resolve().then((function(){return Ho})),Promise.resolve().then((function(){return fl})),Promise.resolve().then((function(){return yl})),Promise.resolve().then((function(){return _l})),Promise.resolve().then((function(){return Cl})),Promise.resolve().then((function(){return El})),Promise.resolve().then((function(){return Ol})),Promise.resolve().then((function(){return zl})),Promise.resolve().then((function(){return Bl})),Promise.resolve().then((function(){return Hl})),Promise.resolve().then((function(){return Vl})),Promise.resolve().then((function(){return Zl})),Promise.resolve().then((function(){return eu})),Promise.resolve().then((function(){return ru})),Promise.resolve().then((function(){return au})),Promise.resolve().then((function(){return uu})),Promise.resolve().then((function(){return mu})),Promise.resolve().then((function(){return yu})),Promise.resolve().then((function(){return $u})),Promise.resolve().then((function(){return Ru})),Promise.resolve().then((function(){return Tu})),Promise.resolve().then((function(){return Iu})),Promise.resolve().then((function(){return ju})),Promise.resolve().then((function(){return qu}))];Promise.all(br).then((e=>gr(e))).catch((e=>console.error(e)));var yr=Object.freeze({__proto__:null,name:"core/location-hash",run:function(){location.hash&&document.respec.ready.then((()=>{let e=decodeURIComponent(location.hash).substr(1);const t=document.getElementById(e),n=/\W/.test(e);if(!t&&n){const t=e.replace(/[\W]+/gim,"-").replace(/^-+/,"").replace(/-+$/,"");document.getElementById(t)&&(e=t)}location.hash=`#${e}`}))}});const wr="w3c/group";async function vr(e){let t="",n=e;e.includes("/")&&([t,n]=e.split("/",2));const r=new URL(`${n}/${t}`,"https://respec.org/w3c/groups/"),s=await un(r.href);if(s.ok){const e=await s.json(),{id:t,name:n,patentURI:r,patentPolicy:i,type:o,wgURI:a}=e;return{wg:n,wgId:t,wgURI:a,wgPatentURI:r,wgPatentPolicy:i,groupType:o}}const i=await s.text();let o,a=`Failed to fetch group details (HTTP: ${s.status}).`;409===s.status?[a,o]=i.split("\n",2):404===s.status&&(o=Dn`See the list of [supported group names](https://respec.org/w3c/groups/) to use with the ${"[group]"} configuration option.`),En(a,wr,{hint:o})}var $r=Object.freeze({__proto__:null,name:wr,run:async function(e){if(!e.group)return;const{group:t}=e,n=Array.isArray(t)?await async function(e){const t=await Promise.all(e.map(vr)),n={wg:[],wgId:[],wgURI:[],wgPatentURI:[],wgPatentPolicy:[],groupType:[]};for(const e of t.filter((e=>e)))for(const t of Object.keys(n))n[t].push(e[t]);return n}(t):await vr(t);Object.assign(e,n)}});function kr(e){if(!e.key){const t="Found a link without `key` attribute in the configuration. See dev console.";return An(t,"core/templates/show-link"),void console.warn(t,e)}return jt`
98
98
  <dt class="${e.class?e.class:null}">${e.key}</dt>
99
- ${e.data?e.data.map(kr):kr(e)}
100
- `}function kr(e){return Ot`<dd class="${e.class?e.class:null}">
101
- ${e.href?Ot`<a href="${e.href}">${e.value||e.href}</a>`:e.value}
102
- </dd>`}const xr="core/templates/show-logo";function _r(e,t){const n=Ot`<a href="${e.url||null}" class="logo"
99
+ ${e.data?e.data.map(xr):xr(e)}
100
+ `}function xr(e){return jt`<dd class="${e.class?e.class:null}">
101
+ ${e.href?jt`<a href="${e.href}">${e.value||e.href}</a>`:e.value}
102
+ </dd>`}const _r="core/templates/show-logo";function Sr(e,t){const n=jt`<a href="${e.url||null}" class="logo"
103
103
  ><img
104
104
  alt="${e.alt||null}"
105
105
  crossorigin
@@ -108,123 +108,123 @@ p:is(.respec-hint,.respec-occurrences){display:block;margin-top:.5em}
108
108
  src="${e.src||null}"
109
109
  width="${e.width||null}"
110
110
  />
111
- </a>`;if(!e.alt){const r=In`Add the missing "\`alt\`" property describing the logo. See ${"[logos]"} for more information.`;Rn(`Logo at index ${t}${e.src?`, with \`src\` ${e.src}, `:""} is missing required "\`alt\`" property.`,xr,{hint:r,elements:[n]})}if(!e.src){const e=In`The \`src\` property is required on every logo. See ${"[logos]"} for more information.`;Rn(`Logo at index ${t} is missing "\`src\`" property.`,xr,{hint:e,elements:[n]})}return n}const Cr="core/templates/show-people",Sr=sn({en:{until:e=>Ot` Until ${e} `},es:{until:e=>Ot` Hasta ${e} `},ko:{until:e=>Ot` ${e} 이전 `},ja:{until:e=>Ot` ${e} 以前 `},de:{until:e=>Ot` bis ${e} `},zh:{until:e=>Ot` 直到 ${e} `}});function Rr(e,t){const n=e[t];if(!Array.isArray(n)||!n.length)return;const r=(s=t,function(e,t){const n="https://respec.org/docs/",r=`See [person](${n}#person) configuration for available options.`,i=`Error processing the [person object](${n}#person) at index ${t} of the "[\`${s}\`](${n}#${s})" configuration option.`;if(!e.name)return Rn(`${i} Missing required property \`"name"\`.`,Cr,{hint:r}),!1;if(e.orcid){const{orcid:n}=e,r=new URL(n,"https://orcid.org/");if("https://orcid.org"!==r.origin){const n=`${i} ORCID "${e.orcid}" at index ${t} is invalid.`,s=`The origin should be "https://orcid.org", not "${r.origin}".`;return Rn(n,Cr,{hint:s}),!1}const s=r.pathname.slice(1).replace(/\/$/,"");if(!/^\d{4}-\d{4}-\d{4}-\d{3}(\d|X)$/.test(s))return Rn(`${i} ORCID "${s}" has wrong format.`,Cr,{hint:'ORCIDs have the format "1234-1234-1234-1234."'}),!1;if(!function(e){const t=e[e.length-1],n=(12-e.split("").slice(0,-1).filter((e=>/\d/.test(e))).map(Number).reduce(((e,t)=>2*(e+t)),0)%11)%11,r=10===n?"X":String(n);return t===r}(n))return Rn(`${i} ORCID "${n}" failed checksum check.`,Cr,{hint:"Please check that the ORCID is valid."}),!1;e.orcid=r.href}return e.retiredDate&&(o=e.retiredDate,"Invalid Date"===(/\d{4}-\d{2}-\d{2}/.test(o)?new Date(o):"Invalid Date").toString())?(Rn(`${i} The property "\`retiredDate\`" is not a valid date.`,Cr,{hint:`The expected format is YYYY-MM-DD. ${r}`}),!1):!(e.hasOwnProperty("extras")&&!function(e,t,n){return Array.isArray(e)?e.every(((e,r)=>{switch(!0){case"object"!=typeof e:return Rn(`${n}. Member "extra" at index ${r} is not an object.`,Cr,{hint:t}),!1;case!e.hasOwnProperty("name"):return Rn(`${n} \`PersonExtra\` object at index ${r} is missing required "name" member.`,Cr,{hint:t}),!1;case"string"==typeof e.name&&""===e.name.trim():return Rn(`${n} \`PersonExtra\` object at index ${r} "name" can't be empty.`,Cr,{hint:t}),!1}return!0})):(Rn(`${n}. A person's "extras" member must be an array.`,Cr,{hint:t}),!1)}(e.extras,r,i))&&(e.url&&e.mailto&&En(`${i} Has both "url" and "mailto" property.`,Cr,{hint:`Please choose either "url" or "mailto" ("url" is preferred). ${r}`}),e.companyURL&&!e.company&&En(`${i} Has a "\`companyURL\`" property but no "\`company\`" property.`,Cr,{hint:`Please add a "\`company\`" property. ${r}.`}),!0);var o});var s;return n.filter(r).map(Er)}function Er(e){const t=[e.name],n=[e.company],r=e.w3cid||null,s=[];if(e.mailto&&(e.url=`mailto:${e.mailto}`),e.url){const n="mailto:"===new URL(e.url,document.location.href).protocol?"ed_mailto u-email email p-name":"u-url url p-name fn";s.push(Ot`<a class="${n}" href="${e.url}">${t}</a>`)}else s.push(Ot`<span class="p-name fn">${t}</span>`);if(e.orcid&&s.push(Ot`<a class="p-name orcid" href="${e.orcid}">${Ot`<svg
112
- width="16"
113
- height="16"
114
- xmlns="http://www.w3.org/2000/svg"
115
- viewBox="0 0 256 256"
116
- >
117
- <style>
118
- .st1 {
119
- fill: #fff;
120
- }
121
- </style>
122
- <path
123
- d="M256 128c0 70.7-57.3 128-128 128S0 198.7 0 128 57.3 0 128 0s128 57.3 128 128z"
124
- fill="#a6ce39"
125
- />
126
- <path
127
- class="st1"
128
- d="M86.3 186.2H70.9V79.1h15.4v107.1zM108.9 79.1h41.6c39.6 0 57 28.3 57 53.6 0 27.5-21.5 53.6-56.8 53.6h-41.8V79.1zm15.4 93.3h24.5c34.9 0 42.9-26.5 42.9-39.7C191.7 111.2 178 93 148 93h-23.7v79.4zM88.7 56.8c0 5.5-4.5 10.1-10.1 10.1s-10.1-4.6-10.1-10.1c0-5.6 4.5-10.1 10.1-10.1s10.1 4.6 10.1 10.1z"
129
- />
130
- </svg>`}</a>`),e.company){const t="p-org org h-org",r=e.companyURL?Ot`<a class="${t}" href="${e.companyURL}">${n}</a>`:Ot`<span class="${t}">${n}</span>`;s.push(Ot` (${r})`)}e.note&&s.push(document.createTextNode(` (${e.note})`)),e.extras&&s.push(...e.extras.map((e=>Ot`, ${function(e){const t=e.class||null,{name:n,href:r}=e;return r?Ot`<a href="${r}" class="${t}">${n}</a>`:Ot`<span class="${t}">${n}</span>`}(e)}`)));const{retiredDate:i}=e;if(e.retiredDate){const e=Ot`<time datetime="${i}"
131
- >${Vt.format(new Date(i))}</time
132
- >`;s.push(Ot` - ${Sr.until(e)} `)}return Ot`<dd
111
+ </a>`;if(!e.alt){const r=Dn`Add the missing "\`alt\`" property describing the logo. See ${"[logos]"} for more information.`;En(`Logo at index ${t}${e.src?`, with \`src\` ${e.src}, `:""} is missing required "\`alt\`" property.`,_r,{hint:r,elements:[n]})}if(!e.src){const e=Dn`The \`src\` property is required on every logo. See ${"[logos]"} for more information.`;En(`Logo at index ${t} is missing "\`src\`" property.`,_r,{hint:e,elements:[n]})}return n}const Cr="core/templates/show-people",Rr=on({en:{until:e=>jt` Until ${e} `},es:{until:e=>jt` Hasta ${e} `},ko:{until:e=>jt` ${e} 이전 `},ja:{until:e=>jt` ${e} 以前 `},de:{until:e=>jt` bis ${e} `},zh:{until:e=>jt` 直到 ${e} `}});function Er(e,t){const n=e[t];if(!Array.isArray(n)||!n.length)return;const r=(s=t,function(e,t){const n="https://respec.org/docs/",r=`See [person](${n}#person) configuration for available options.`,i=`Error processing the [person object](${n}#person) at index ${t} of the "[\`${s}\`](${n}#${s})" configuration option.`;if(!e.name)return En(`${i} Missing required property \`"name"\`.`,Cr,{hint:r}),!1;if(e.orcid){const{orcid:n}=e,r=new URL(n,"https://orcid.org/");if("https://orcid.org"!==r.origin){const n=`${i} ORCID "${e.orcid}" at index ${t} is invalid.`,s=`The origin should be "https://orcid.org", not "${r.origin}".`;return En(n,Cr,{hint:s}),!1}const s=r.pathname.slice(1).replace(/\/$/,"");if(!/^\d{4}-\d{4}-\d{4}-\d{3}(\d|X)$/.test(s))return En(`${i} ORCID "${s}" has wrong format.`,Cr,{hint:'ORCIDs have the format "1234-1234-1234-1234."'}),!1;if(!function(e){const t=e[e.length-1],n=(12-e.split("").slice(0,-1).filter((e=>/\d/.test(e))).map(Number).reduce(((e,t)=>2*(e+t)),0)%11)%11,r=10===n?"X":String(n);return t===r}(n))return En(`${i} ORCID "${n}" failed checksum check.`,Cr,{hint:"Please check that the ORCID is valid."}),!1;e.orcid=r.href}return e.retiredDate&&(o=e.retiredDate,"Invalid Date"===(/\d{4}-\d{2}-\d{2}/.test(o)?new Date(o):"Invalid Date").toString())?(En(`${i} The property "\`retiredDate\`" is not a valid date.`,Cr,{hint:`The expected format is YYYY-MM-DD. ${r}`}),!1):!(e.hasOwnProperty("extras")&&!function(e,t,n){return Array.isArray(e)?e.every(((e,r)=>{switch(!0){case"object"!=typeof e:return En(`${n}. Member "extra" at index ${r} is not an object.`,Cr,{hint:t}),!1;case!e.hasOwnProperty("name"):return En(`${n} \`PersonExtra\` object at index ${r} is missing required "name" member.`,Cr,{hint:t}),!1;case"string"==typeof e.name&&""===e.name.trim():return En(`${n} \`PersonExtra\` object at index ${r} "name" can't be empty.`,Cr,{hint:t}),!1}return!0})):(En(`${n}. A person's "extras" member must be an array.`,Cr,{hint:t}),!1)}(e.extras,r,i))&&(e.url&&e.mailto&&An(`${i} Has both "url" and "mailto" property.`,Cr,{hint:`Please choose either "url" or "mailto" ("url" is preferred). ${r}`}),e.companyURL&&!e.company&&An(`${i} Has a "\`companyURL\`" property but no "\`company\`" property.`,Cr,{hint:`Please add a "\`company\`" property. ${r}.`}),!0);var o});var s;return n.filter(r).map(Ar)}function Ar(e){const t=[e.name],n=[e.company],r=e.w3cid||null,s=[];if(e.mailto&&(e.url=`mailto:${e.mailto}`),e.url){const n="mailto:"===new URL(e.url,document.location.href).protocol?"ed_mailto u-email email p-name":"u-url url p-name fn";s.push(jt`<a class="${n}" href="${e.url}">${t}</a>`)}else s.push(jt`<span class="p-name fn">${t}</span>`);if(e.orcid&&s.push(jt`<a class="p-name orcid" href="${e.orcid}">${jt`<svg
112
+ width="16"
113
+ height="16"
114
+ xmlns="http://www.w3.org/2000/svg"
115
+ viewBox="0 0 256 256"
116
+ >
117
+ <style>
118
+ .st1 {
119
+ fill: #fff;
120
+ }
121
+ </style>
122
+ <path
123
+ d="M256 128c0 70.7-57.3 128-128 128S0 198.7 0 128 57.3 0 128 0s128 57.3 128 128z"
124
+ fill="#a6ce39"
125
+ />
126
+ <path
127
+ class="st1"
128
+ d="M86.3 186.2H70.9V79.1h15.4v107.1zM108.9 79.1h41.6c39.6 0 57 28.3 57 53.6 0 27.5-21.5 53.6-56.8 53.6h-41.8V79.1zm15.4 93.3h24.5c34.9 0 42.9-26.5 42.9-39.7C191.7 111.2 178 93 148 93h-23.7v79.4zM88.7 56.8c0 5.5-4.5 10.1-10.1 10.1s-10.1-4.6-10.1-10.1c0-5.6 4.5-10.1 10.1-10.1s10.1 4.6 10.1 10.1z"
129
+ />
130
+ </svg>`}</a>`),e.company){const t="p-org org h-org",r=e.companyURL?jt`<a class="${t}" href="${e.companyURL}">${n}</a>`:jt`<span class="${t}">${n}</span>`;s.push(jt` (${r})`)}e.note&&s.push(document.createTextNode(` (${e.note})`)),e.extras&&s.push(...e.extras.map((e=>jt`, ${function(e){const t=e.class||null,{name:n,href:r}=e;return r?jt`<a href="${r}" class="${t}">${n}</a>`:jt`<span class="${t}">${n}</span>`}(e)}`)));const{retiredDate:i}=e;if(e.retiredDate){const e=jt`<time datetime="${i}"
131
+ >${Yt.format(new Date(i))}</time
132
+ >`;s.push(jt` - ${Rr.until(e)} `)}return jt`<dd
133
133
  class="editor p-author h-card vcard"
134
134
  data-editor-id="${r}"
135
135
  >
136
136
  ${s}
137
- </dd>`}const Ar=sn({en:{archives:"archives",author:"Author:",authors:"Authors:",commit_history:"Commit history",edited_in_place:"edited in place",editor:"Editor:",editors:"Editors:",feedback:"Feedback:",former_editor:"Former editor:",former_editors:"Former editors:",history:"History:",implementation_report:"Implementation report:",latest_editors_draft:"Latest editor's draft:",latest_published_version:"Latest published version:",latest_recommendation:"Latest Recommendation:",message_topic:"… message topic …",more_details_about_this_doc:"More details about this document",multiple_alternates:e=>`This document is also available in ${e?"these non-normative formats":"this non-normative format"}:`,prev_editor_draft:"Previous editor's draft:",prev_recommendation:"Previous Recommendation:",prev_version:"Previous version:",publication_history:"Publication history",test_suite:"Test suite:",this_version:"This version:",with_subject_line:"with subject line",your_topic_here:"YOUR TOPIC HERE"},ko:{author:"저자:",authors:"저자:",editor:"편집자:",editors:"편집자:",former_editor:"이전 편집자:",former_editors:"이전 편집자:",latest_editors_draft:"최신 편집 초안:",latest_published_version:"최신 버전:",this_version:"현재 버전:"},zh:{author:"作者:",authors:"作者:",commit_history:"Git提交历史",editor:"编辑:",editors:"编辑:",feedback:"反馈:",former_editor:"原编辑:",former_editors:"原编辑:",history:"历史:",implementation_report:"实现报告:",latest_editors_draft:"最新编辑草稿:",latest_published_version:"最新发布版本:",latest_recommendation:"最新发布的正式推荐标准:",message_topic:"… 邮件主题 …",prev_editor_draft:"上一版编辑草稿:",prev_recommendation:"上一版正式推荐标准:",prev_version:"上一版:",test_suite:"测试套件:",this_version:"本版本:"},ja:{archives:"アーカイブ",author:"著者:",authors:"著者:",commit_history:"更新履歴",edited_in_place:"改版なく更新",editor:"編者:",editors:"編者:",feedback:"フィードバック:",former_editor:"以前の版の編者:",former_editors:"以前の版の編者:",history:"履歴:",implementation_report:"実装レポート:",latest_editors_draft:"最新の編集用草案:",latest_published_version:"最新バージョン:",latest_recommendation:"最新の勧告版:",message_topic:"… メール件名 …",more_details_about_this_doc:"この文書についてのより詳細",prev_editor_draft:"前回の編集用草案:",prev_recommendation:"前回の勧告版:",prev_version:"前回のバージョン:",publication_history:"公表履歴",test_suite:"テストスイート:",this_version:"このバージョン:",with_subject_line:"次の件名で"},nl:{author:"Auteur:",authors:"Auteurs:",editor:"Redacteur:",editors:"Redacteurs:",latest_editors_draft:"Laatste werkversie:",latest_published_version:"Laatst gepubliceerde versie:",this_version:"Deze versie:"},es:{archives:"archivos",author:"Autor:",authors:"Autores:",commit_history:"Historial de cambios",edited_in_place:"editado en lugar",editor:"Editor:",editors:"Editores:",feedback:"Comentarios:",former_editor:"Antiguo editor:",former_editors:"Antiguos editores:",history:"Historia:",implementation_report:"Informe de implementación:",latest_editors_draft:"Última versión del editor:",latest_published_version:"Última versión publicada:",latest_recommendation:"Recomendación más reciente:",message_topic:"… detalles de mensaje …",more_details_about_this_doc:"Más detalles sobre este documento:",publication_history:"Historial de publicación",prev_editor_draft:"Última versión del editor:",prev_recommendation:"Última Recomendación:",prev_version:"Última versión:",test_suite:"Suite de pruebas:",this_version:"Esta versión:",with_subject_line:"con línea de asunto",your_topic_here:"TU SUJETO AQUÍ"},de:{archives:"Archiv",author:"Autor/in:",authors:"Autor/innen:",commit_history:"Commit-Historie",edited_in_place:"zuletzt geändert am",editor:"Redaktion:",editors:"Redaktion:",feedback:"Feedback:",former_editor:"Frühere Mitwirkende:",former_editors:"Frühere Mitwirkende:",history:"Verlauf:",implementation_report:"Umsetzungsbericht:",latest_editors_draft:"Letzter Entwurf:",latest_published_version:"Letzte publizierte Fassung:",latest_recommendation:"Aktuellste Empfehlung:",more_details_about_this_doc:"Mehr Informationen über dieses Dokument",multiple_alternates:e=>`Dieses Dokument ist ebenfalls in ${e?"diesen nicht-normativen Formaten verfügbar":"diesem nicht-normativen Format verfügbar"}:`,prev_editor_draft:"Vorheriger Entwurf:",prev_recommendation:"Vorherige Empfehlung:",prev_version:"Vorherige Version:",publication_history:"Veröffentlichungsverlauf",test_suite:"Testumgebung:",this_version:"Diese Fassung:"}});function Tr(e){let t=document.querySelector("h2#subtitle");return t&&t.parentElement?(t.remove(),e.subtitle=t.textContent.trim()):e.subtitle&&(t=document.createElement("h2"),t.textContent=e.subtitle,t.id="subtitle"),t&&t.classList.add("subtitle"),t}var Lr=(e,t)=>(s("beforesave",(e=>{e.querySelector(".head details").open=!0})),Ot`<div class="head">
138
- ${e.logos.length?Ot`<p class="logos">${e.logos.map(_r)}</p>`:""}
139
- ${document.querySelector("h1#title")} ${Tr(e)}
140
- <p id="w3c-state">${function(e){const t=e.isCR||e.isCRY?e.longStatus:e.textStatus,n=e.prependW3C?Ot`<a href="https://www.w3.org/standards/types#${e.specStatus}"
137
+ </dd>`}const Tr=on({en:{archives:"archives",author:"Author:",authors:"Authors:",commit_history:"Commit history",edited_in_place:"edited in place",editor:"Editor:",editors:"Editors:",feedback:"Feedback:",former_editor:"Former editor:",former_editors:"Former editors:",history:"History:",implementation_report:"Implementation report:",latest_editors_draft:"Latest editor's draft:",latest_published_version:"Latest published version:",latest_recommendation:"Latest Recommendation:",message_topic:"… message topic …",more_details_about_this_doc:"More details about this document",multiple_alternates:e=>`This document is also available in ${e?"these non-normative formats":"this non-normative format"}:`,prev_editor_draft:"Previous editor's draft:",prev_recommendation:"Previous Recommendation:",prev_version:"Previous version:",publication_history:"Publication history",test_suite:"Test suite:",this_version:"This version:",with_subject_line:"with subject line",your_topic_here:"YOUR TOPIC HERE"},ko:{author:"저자:",authors:"저자:",editor:"편집자:",editors:"편집자:",former_editor:"이전 편집자:",former_editors:"이전 편집자:",latest_editors_draft:"최신 편집 초안:",latest_published_version:"최신 버전:",this_version:"현재 버전:"},zh:{author:"作者:",authors:"作者:",commit_history:"Git提交历史",editor:"编辑:",editors:"编辑:",feedback:"反馈:",former_editor:"原编辑:",former_editors:"原编辑:",history:"历史:",implementation_report:"实现报告:",latest_editors_draft:"最新编辑草稿:",latest_published_version:"最新发布版本:",latest_recommendation:"最新发布的正式推荐标准:",message_topic:"… 邮件主题 …",prev_editor_draft:"上一版编辑草稿:",prev_recommendation:"上一版正式推荐标准:",prev_version:"上一版:",test_suite:"测试套件:",this_version:"本版本:"},ja:{archives:"アーカイブ",author:"著者:",authors:"著者:",commit_history:"更新履歴",edited_in_place:"改版なく更新",editor:"編者:",editors:"編者:",feedback:"フィードバック:",former_editor:"以前の版の編者:",former_editors:"以前の版の編者:",history:"履歴:",implementation_report:"実装レポート:",latest_editors_draft:"最新の編集用草案:",latest_published_version:"最新バージョン:",latest_recommendation:"最新の勧告版:",message_topic:"… メール件名 …",more_details_about_this_doc:"この文書についてのより詳細",prev_editor_draft:"前回の編集用草案:",prev_recommendation:"前回の勧告版:",prev_version:"前回のバージョン:",publication_history:"公表履歴",test_suite:"テストスイート:",this_version:"このバージョン:",with_subject_line:"次の件名で"},nl:{author:"Auteur:",authors:"Auteurs:",editor:"Redacteur:",editors:"Redacteurs:",latest_editors_draft:"Laatste werkversie:",latest_published_version:"Laatst gepubliceerde versie:",this_version:"Deze versie:"},es:{archives:"archivos",author:"Autor:",authors:"Autores:",commit_history:"Historial de cambios",edited_in_place:"editado en lugar",editor:"Editor:",editors:"Editores:",feedback:"Comentarios:",former_editor:"Antiguo editor:",former_editors:"Antiguos editores:",history:"Historia:",implementation_report:"Informe de implementación:",latest_editors_draft:"Última versión del editor:",latest_published_version:"Última versión publicada:",latest_recommendation:"Recomendación más reciente:",message_topic:"… detalles de mensaje …",more_details_about_this_doc:"Más detalles sobre este documento:",publication_history:"Historial de publicación",prev_editor_draft:"Última versión del editor:",prev_recommendation:"Última Recomendación:",prev_version:"Última versión:",test_suite:"Suite de pruebas:",this_version:"Esta versión:",with_subject_line:"con línea de asunto",your_topic_here:"TU SUJETO AQUÍ"},de:{archives:"Archiv",author:"Autor/in:",authors:"Autor/innen:",commit_history:"Commit-Historie",edited_in_place:"zuletzt geändert am",editor:"Redaktion:",editors:"Redaktion:",feedback:"Feedback:",former_editor:"Frühere Mitwirkende:",former_editors:"Frühere Mitwirkende:",history:"Verlauf:",implementation_report:"Umsetzungsbericht:",latest_editors_draft:"Letzter Entwurf:",latest_published_version:"Letzte publizierte Fassung:",latest_recommendation:"Aktuellste Empfehlung:",more_details_about_this_doc:"Mehr Informationen über dieses Dokument",multiple_alternates:e=>`Dieses Dokument ist ebenfalls in ${e?"diesen nicht-normativen Formaten verfügbar":"diesem nicht-normativen Format verfügbar"}:`,prev_editor_draft:"Vorheriger Entwurf:",prev_recommendation:"Vorherige Empfehlung:",prev_version:"Vorherige Version:",publication_history:"Veröffentlichungsverlauf",test_suite:"Testumgebung:",this_version:"Diese Fassung:"}});function Lr(e){let t=document.querySelector("h2#subtitle");return t&&t.parentElement?(t.remove(),e.subtitle=t.textContent.trim()):e.subtitle&&(t=document.createElement("h2"),t.textContent=e.subtitle,t.id="subtitle"),t&&t.classList.add("subtitle"),t}var Pr=(e,t)=>(s("beforesave",(e=>{e.querySelector(".head details").open=!0})),jt`<div class="head">
138
+ ${e.logos.length?jt`<p class="logos">${e.logos.map(Sr)}</p>`:""}
139
+ ${document.querySelector("h1#title")} ${Lr(e)}
140
+ <p id="w3c-state">${function(e){const t=e.isCR||e.isCRY?e.longStatus:e.textStatus,n=e.prependW3C?jt`<a href="https://www.w3.org/standards/types#${e.specStatus}"
141
141
  >W3C ${t}</a
142
- >`:Ot`${t}`;return Ot`${n}${" "}
142
+ >`:jt`${t}`;return jt`${n}${" "}
143
143
  <time class="dt-published" datetime="${e.dashDate}"
144
- >${Vt.format(e.publishDate)}</time
145
- >${e.modificationDate?Ot`, ${Ar.edited_in_place}${" "}
144
+ >${Yt.format(e.publishDate)}</time
145
+ >${e.modificationDate?jt`, ${Tr.edited_in_place}${" "}
146
146
  <time
147
147
  class="dt-modified"
148
- datetime="${Ht.format(e.modificationDate)}"
149
- >${Vt.format(e.modificationDate)}</time
148
+ datetime="${Gt.format(e.modificationDate)}"
149
+ >${Yt.format(e.modificationDate)}</time
150
150
  >`:""}`}(e)}</p>
151
151
  <details open="${localStorage.getItem("tr-metadata")||"true"}">
152
- <summary>${Ar.more_details_about_this_doc}</summary>
152
+ <summary>${Tr.more_details_about_this_doc}</summary>
153
153
  <dl>
154
- ${e.thisVersion?Ot`<dt>${Ar.this_version}</dt>
154
+ ${e.thisVersion?jt`<dt>${Tr.this_version}</dt>
155
155
  <dd>
156
156
  <a class="u-url" href="${e.thisVersion}"
157
157
  >${e.thisVersion}</a
158
158
  >
159
159
  </dd>`:""}
160
- ${"latestVersion"in e?Ot`<dt>${Ar.latest_published_version}</dt>
160
+ ${"latestVersion"in e?jt`<dt>${Tr.latest_published_version}</dt>
161
161
  <dd>
162
- ${e.latestVersion?Ot`<a href="${e.latestVersion}"
162
+ ${e.latestVersion?jt`<a href="${e.latestVersion}"
163
163
  >${e.latestVersion}</a
164
164
  >`:"none"}
165
165
  </dd>`:""}
166
- ${e.edDraftURI?Ot`
167
- <dt>${Ar.latest_editors_draft}</dt>
166
+ ${e.edDraftURI?jt`
167
+ <dt>${Tr.latest_editors_draft}</dt>
168
168
  <dd><a href="${e.edDraftURI}">${e.edDraftURI}</a></dd>
169
169
  `:""}
170
- ${e.historyURI||e.github?Ot`<dt>${Ar.history}</dt>
171
- ${e.historyURI?Ot`<dd>
170
+ ${e.historyURI||e.github?jt`<dt>${Tr.history}</dt>
171
+ ${e.historyURI?jt`<dd>
172
172
  <a href="${e.historyURI}">${e.historyURI}</a>
173
173
  </dd>`:""}
174
- ${e.github?Ot`<dd>
174
+ ${e.github?jt`<dd>
175
175
  <a href="${e.github.commitHistoryURL}"
176
- >${Ar.commit_history}</a
176
+ >${Tr.commit_history}</a
177
177
  >
178
178
  </dd>`:""}`:""}
179
- ${e.testSuiteURI?Ot`
180
- <dt>${Ar.test_suite}</dt>
179
+ ${e.testSuiteURI?jt`
180
+ <dt>${Tr.test_suite}</dt>
181
181
  <dd><a href="${e.testSuiteURI}">${e.testSuiteURI}</a></dd>
182
182
  `:""}
183
- ${e.implementationReportURI?Ot`
184
- <dt>${Ar.implementation_report}</dt>
183
+ ${e.implementationReportURI?jt`
184
+ <dt>${Tr.implementation_report}</dt>
185
185
  <dd>
186
186
  <a href="${e.implementationReportURI}"
187
187
  >${e.implementationReportURI}</a
188
188
  >
189
189
  </dd>
190
190
  `:""}
191
- ${e.prevED?Ot`
192
- <dt>${Ar.prev_editor_draft}</dt>
191
+ ${e.prevED?jt`
192
+ <dt>${Tr.prev_editor_draft}</dt>
193
193
  <dd><a href="${e.prevED}">${e.prevED}</a></dd>
194
194
  `:""}
195
- ${e.showPreviousVersion?Ot`
196
- <dt>${Ar.prev_version}</dt>
195
+ ${e.showPreviousVersion?jt`
196
+ <dt>${Tr.prev_version}</dt>
197
197
  <dd><a href="${e.prevVersion}">${e.prevVersion}</a></dd>
198
198
  `:""}
199
- ${e.prevRecURI?e.isRec?Ot`
200
- <dt>${Ar.prev_recommendation}</dt>
199
+ ${e.prevRecURI?e.isRec?jt`
200
+ <dt>${Tr.prev_recommendation}</dt>
201
201
  <dd><a href="${e.prevRecURI}">${e.prevRecURI}</a></dd>
202
- `:Ot`
203
- <dt>${Ar.latest_recommendation}</dt>
202
+ `:jt`
203
+ <dt>${Tr.latest_recommendation}</dt>
204
204
  <dd><a href="${e.prevRecURI}">${e.prevRecURI}</a></dd>
205
205
  `:""}
206
- ${e.editors.length?Ot`
207
- <dt>${e.editors.length>1?Ar.editors:Ar.editor}</dt>
208
- ${Rr(e,"editors")}
206
+ ${e.editors.length?jt`
207
+ <dt>${e.editors.length>1?Tr.editors:Tr.editor}</dt>
208
+ ${Er(e,"editors")}
209
209
  `:""}
210
- ${e.formerEditors.length?Ot`
210
+ ${e.formerEditors.length?jt`
211
211
  <dt>
212
- ${e.formerEditors.length>1?Ar.former_editors:Ar.former_editor}
212
+ ${e.formerEditors.length>1?Tr.former_editors:Tr.former_editor}
213
213
  </dt>
214
- ${Rr(e,"formerEditors")}
214
+ ${Er(e,"formerEditors")}
215
215
  `:""}
216
- ${e.authors.length?Ot`
217
- <dt>${e.authors.length>1?Ar.authors:Ar.author}</dt>
218
- ${Rr(e,"authors")}
216
+ ${e.authors.length?jt`
217
+ <dt>${e.authors.length>1?Tr.authors:Tr.author}</dt>
218
+ ${Er(e,"authors")}
219
219
  `:""}
220
- ${e.github||e.wgPublicList?Ot`<dt>${Ar.feedback}</dt>
221
- ${Pr(e)}`:""}
222
- ${e.errata?Ot`<dt>Errata:</dt>
220
+ ${e.github||e.wgPublicList?jt`<dt>${Tr.feedback}</dt>
221
+ ${Ir(e)}`:""}
222
+ ${e.errata?jt`<dt>Errata:</dt>
223
223
  <dd><a href="${e.errata}">Errata exists</a>.</dd>`:""}
224
- ${e.otherLinks?e.otherLinks.map($r):""}
224
+ ${e.otherLinks?e.otherLinks.map(kr):""}
225
225
  </dl>
226
226
  </details>
227
- ${e.isRec?Ot`<p>
227
+ ${e.isRec?jt`<p>
228
228
  See also
229
229
  <a
230
230
  href="${`https://www.w3.org/Translations/?technology=${e.shortName}`}"
@@ -232,25 +232,25 @@ p:is(.respec-hint,.respec-occurrences){display:block;margin-top:.5em}
232
232
  <strong>translations</strong></a
233
233
  >.
234
234
  </p>`:""}
235
- ${e.alternateFormats?Ot`<p>
236
- ${Ar.multiple_alternates(t.multipleAlternates)}
235
+ ${e.alternateFormats?jt`<p>
236
+ ${Tr.multiple_alternates(t.multipleAlternates)}
237
237
  ${t.alternatesHTML}
238
238
  </p>`:""}
239
- ${function(e){const t=document.querySelector(".copyright");if(t)return t.remove(),t;if(e.isUnofficial&&e.licenseInfo)return Ot`<p class="copyright">
239
+ ${function(e){const t=document.querySelector(".copyright");if(t)return t.remove(),t;if(e.isUnofficial&&e.licenseInfo)return jt`<p class="copyright">
240
240
  Copyright &copy;
241
241
  ${e.copyrightStart?`${e.copyrightStart}-`:""}${e.publishYear}
242
242
  the document editors/authors.
243
- ${"unlicensed"!==e.licenseInfo.name?Ot`Text is available under the
243
+ ${"unlicensed"!==e.licenseInfo.name?jt`Text is available under the
244
244
  <a rel="license" href="${e.licenseInfo.url}"
245
245
  >${e.licenseInfo.name}</a
246
246
  >; additional terms may apply.`:""}
247
- </p>`;return function(e){return Ot`<p class="copyright">
247
+ </p>`;return function(e){return jt`<p class="copyright">
248
248
  <a href="https://www.w3.org/Consortium/Legal/ipr-notice#Copyright"
249
249
  >Copyright</a
250
250
  >
251
251
  &copy;
252
252
  ${e.copyrightStart?`${e.copyrightStart}-`:""}${e.publishYear}
253
- ${e.additionalCopyrightHolders?Ot` ${[e.additionalCopyrightHolders]} &amp; `:""}
253
+ ${e.additionalCopyrightHolders?jt` ${[e.additionalCopyrightHolders]} &amp; `:""}
254
254
  <a href="https://www.w3.org/">World Wide Web Consortium</a>.
255
255
  <abbr title="World Wide Web Consortium">W3C</abbr><sup>&reg;</sup>
256
256
  <a href="https://www.w3.org/Consortium/Legal/ipr-notice#Legal_Disclaimer"
@@ -258,54 +258,54 @@ p:is(.respec-hint,.respec-occurrences){display:block;margin-top:.5em}
258
258
  >,
259
259
  <a href="https://www.w3.org/Consortium/Legal/ipr-notice#W3C_Trademarks"
260
260
  >trademark</a
261
- >${function(e){const{url:t,short:n,name:r}=e;if("unlicensed"===r)return Ot`. <span class="issue">THIS DOCUMENT IS UNLICENSED</span>.`;return Ot` and
261
+ >${function(e){const{url:t,short:n,name:r}=e;if("unlicensed"===r)return jt`. <span class="issue">THIS DOCUMENT IS UNLICENSED</span>.`;return jt` and
262
262
  <a rel="license" href="${t}" title="${r}">${n}</a> rules apply.`}(e.licenseInfo)}
263
263
  </p>`}(e)}(e)}
264
264
  <hr title="Separator for header" />
265
- </div>`);function Pr(e){const t=[];if(e.github){const{repoURL:n,issuesURL:r,newIssuesURL:s,pullsURL:i,fullName:o}=e.github;t.push(Ot`<dd>
265
+ </div>`);function Ir(e){const t=[];if(e.github){const{repoURL:n,issuesURL:r,newIssuesURL:s,pullsURL:i,fullName:o}=e.github;t.push(jt`<dd>
266
266
  <a href="${n}">GitHub ${o}</a>
267
267
  (<a href="${i}">pull requests</a>,
268
268
  <a href="${s}">new issue</a>,
269
269
  <a href="${r}">open issues</a>)
270
- </dd>`)}if(e.wgPublicList){const n=new URL(`mailto:${e.wgPublicList}@w3.org`),r=e.subjectPrefix??`[${e.shortName}] ${Ar.your_topic_here}`,s=Ot`<a
270
+ </dd>`)}if(e.wgPublicList){const n=new URL(`mailto:${e.wgPublicList}@w3.org`),r=e.subjectPrefix??`[${e.shortName}] ${Tr.your_topic_here}`,s=jt`<a
271
271
  href="${n.href}?subject=${encodeURIComponent(r)}"
272
272
  >${n.pathname}</a
273
- >`,i=e.subjectPrefix||Ot`[${e.shortName}] <em>${Ar.message_topic}</em>`,o=Ot`${Ar.with_subject_line}${" "}
274
- <kbd>${i}</kbd>`,a=new URL(e.wgPublicList,"https://lists.w3.org/Archives/Public/"),c=Ot`(<a href="${a}" rel="discussion"
275
- >${Ar.archives}</a
276
- >)`;t.push(Ot`<dd>${s} ${o} ${c}</dd>`)}return t}var Ir=(e,t)=>{const n=document.querySelector(".copyright");n&&n.remove();const r=document.querySelector("h1#title"),s=r.cloneNode(!0);return Ot`<div class="head">
277
- ${e.logos.length?Ot`<p class="logos">${e.logos.map(_r)}</p>`:""}
278
- ${r} ${Tr(e)}
273
+ >`,i=e.subjectPrefix||jt`[${e.shortName}] <em>${Tr.message_topic}</em>`,o=jt`${Tr.with_subject_line}${" "}
274
+ <kbd>${i}</kbd>`,a=new URL(e.wgPublicList,"https://lists.w3.org/Archives/Public/"),c=jt`(<a href="${a}" rel="discussion"
275
+ >${Tr.archives}</a
276
+ >)`;t.push(jt`<dd>${s} ${o} ${c}</dd>`)}return t}var Dr=(e,t)=>{const n=document.querySelector(".copyright");n&&n.remove();const r=document.querySelector("h1#title"),s=r.cloneNode(!0);return jt`<div class="head">
277
+ ${e.logos.length?jt`<p class="logos">${e.logos.map(Sr)}</p>`:""}
278
+ ${r} ${Lr(e)}
279
279
  <p id="w3c-state">
280
280
  <a href="https://www.w3.org/standards/types#reports"
281
281
  >${e.longStatus}</a
282
282
  >
283
283
  <time class="dt-published" datetime="${e.dashDate}"
284
- >${Vt.format(e.publishDate)}</time
284
+ >${Yt.format(e.publishDate)}</time
285
285
  >
286
286
  </p>
287
287
  <dl>
288
- ${e.thisVersion?Ot`<dt>${Ar.this_version}</dt>
288
+ ${e.thisVersion?jt`<dt>${Tr.this_version}</dt>
289
289
  <dd>
290
290
  <a class="u-url" href="${e.thisVersion}"
291
291
  >${e.thisVersion}</a
292
292
  >
293
293
  </dd>`:""}
294
- ${"latestVersion"in e?Ot`<dt>${Ar.latest_published_version}</dt>
294
+ ${"latestVersion"in e?jt`<dt>${Tr.latest_published_version}</dt>
295
295
  <dd>
296
- ${e.latestVersion?Ot`<a href="${e.latestVersion}"
296
+ ${e.latestVersion?jt`<a href="${e.latestVersion}"
297
297
  >${e.latestVersion}</a
298
298
  >`:"none"}
299
299
  </dd>`:""}
300
- ${e.edDraftURI?Ot`
301
- <dt>${Ar.latest_editors_draft}</dt>
300
+ ${e.edDraftURI?jt`
301
+ <dt>${Tr.latest_editors_draft}</dt>
302
302
  <dd><a href="${e.edDraftURI}">${e.edDraftURI}</a></dd>
303
303
  `:""}
304
- ${e.testSuiteURI?Ot`
304
+ ${e.testSuiteURI?jt`
305
305
  <dt>Test suite:</dt>
306
306
  <dd><a href="${e.testSuiteURI}">${e.testSuiteURI}</a></dd>
307
307
  `:""}
308
- ${e.implementationReportURI?Ot`
308
+ ${e.implementationReportURI?jt`
309
309
  <dt>Implementation report:</dt>
310
310
  <dd>
311
311
  <a href="${e.implementationReportURI}"
@@ -313,49 +313,49 @@ p:is(.respec-hint,.respec-occurrences){display:block;margin-top:.5em}
313
313
  >
314
314
  </dd>
315
315
  `:""}
316
- ${e.prevVersion?Ot`
316
+ ${e.prevVersion?jt`
317
317
  <dt>Previous version:</dt>
318
318
  <dd><a href="${e.prevVersion}">${e.prevVersion}</a></dd>
319
319
  `:""}
320
- ${e.isCGFinal?"":Ot`
321
- ${e.prevED?Ot`
320
+ ${e.isCGFinal?"":jt`
321
+ ${e.prevED?jt`
322
322
  <dt>Previous editor's draft:</dt>
323
323
  <dd><a href="${e.prevED}">${e.prevED}</a></dd>
324
324
  `:""}
325
325
  `}
326
- ${e.editors.length?Ot`
327
- <dt>${e.editors.length>1?Ar.editors:Ar.editor}</dt>
328
- ${Rr(e,"editors")}
326
+ ${e.editors.length?jt`
327
+ <dt>${e.editors.length>1?Tr.editors:Tr.editor}</dt>
328
+ ${Er(e,"editors")}
329
329
  `:""}
330
- ${e.formerEditors.length?Ot`
330
+ ${e.formerEditors.length?jt`
331
331
  <dt>
332
- ${e.formerEditors.length>1?Ar.former_editors:Ar.former_editor}
332
+ ${e.formerEditors.length>1?Tr.former_editors:Tr.former_editor}
333
333
  </dt>
334
- ${Rr(e,"formerEditors")}
334
+ ${Er(e,"formerEditors")}
335
335
  `:""}
336
- ${e.authors.length?Ot`
337
- <dt>${e.authors.length>1?Ar.authors:Ar.author}</dt>
338
- ${Rr(e,"authors")}
336
+ ${e.authors.length?jt`
337
+ <dt>${e.authors.length>1?Tr.authors:Tr.author}</dt>
338
+ ${Er(e,"authors")}
339
339
  `:""}
340
- ${e.github||e.wgPublicList?Ot`<dt>${Ar.feedback}</dt>
341
- ${Pr(e)}`:""}
342
- ${e.otherLinks?e.otherLinks.map($r):""}
340
+ ${e.github||e.wgPublicList?jt`<dt>${Tr.feedback}</dt>
341
+ ${Ir(e)}`:""}
342
+ ${e.otherLinks?e.otherLinks.map(kr):""}
343
343
  </dl>
344
- ${e.alternateFormats?Ot`<p>
344
+ ${e.alternateFormats?jt`<p>
345
345
  ${t.multipleAlternates?"This document is also available in these non-normative formats:":"This document is also available in this non-normative format:"}
346
346
  ${t.alternatesHTML}
347
347
  </p>`:""}
348
- ${n||Ot`<p class="copyright">
348
+ ${n||jt`<p class="copyright">
349
349
  <a href="https://www.w3.org/Consortium/Legal/ipr-notice#Copyright"
350
350
  >Copyright</a
351
351
  >
352
352
  &copy;
353
353
  ${e.copyrightStart?`${e.copyrightStart}-`:""}${e.publishYear}
354
- ${e.additionalCopyrightHolders?Ot` ${[e.additionalCopyrightHolders]} &amp; `:""}
354
+ ${e.additionalCopyrightHolders?jt` ${[e.additionalCopyrightHolders]} &amp; `:""}
355
355
  the Contributors to the ${s.childNodes}
356
356
  Specification, published by the
357
357
  <a href="${e.wgURI}">${e.wg}</a> under the
358
- ${e.isCGFinal?Ot`
358
+ ${e.isCGFinal?jt`
359
359
  <a href="https://www.w3.org/community/about/agreements/fsa/"
360
360
  >W3C Community Final Specification Agreement (FSA)</a
361
361
  >. A human-readable
@@ -364,7 +364,7 @@ p:is(.respec-hint,.respec-occurrences){display:block;margin-top:.5em}
364
364
  >summary</a
365
365
  >
366
366
  is available.
367
- `:Ot`
367
+ `:jt`
368
368
  <a href="https://www.w3.org/community/about/agreements/cla/"
369
369
  >W3C Community Contributor License Agreement (CLA)</a
370
370
  >. A human-readable
@@ -376,47 +376,47 @@ p:is(.respec-hint,.respec-occurrences){display:block;margin-top:.5em}
376
376
  `}
377
377
  </p>`}
378
378
  <hr title="Separator for header" />
379
- </div>`};const Dr=sn({en:{sotd:"Status of This Document",status_at_publication:Ot`This section describes the status of this
379
+ </div>`};const Nr=on({en:{sotd:"Status of This Document",status_at_publication:jt`This section describes the status of this
380
380
  document at the time of its publication. A list of current W3C
381
381
  publications and the latest revision of this technical report can be found
382
382
  in the <a href="https://www.w3.org/TR/">W3C technical reports index</a> at
383
- https://www.w3.org/TR/.`},ko:{sotd:"현재 문서의 상태",status_at_publication:Ot`이 부분은 현재 문서의 발행 당시 상태에 대해
383
+ https://www.w3.org/TR/.`},ko:{sotd:"현재 문서의 상태",status_at_publication:jt`이 부분은 현재 문서의 발행 당시 상태에 대해
384
384
  기술합니다. W3C 발행 문서의 최신 목록 및 테크니컬 리포트 최신판을
385
385
  https://www.w3.org/TR/ 의
386
386
  <a href="https://www.w3.org/TR/">W3C technical reports index</a> 에서
387
- 열람할 수 있습니다.`},zh:{sotd:"关于本文档",status_at_publication:Ot`本章节描述了本文档的发布状态。W3C的文档列表和最新版本可通过<a href="https://www.w3.org/TR/">W3C技术报告</a>索引访问。`},ja:{sotd:"この文書の位置付け",status_at_publication:Ot`この節には、公開時点でのこの文書の位置づけが記されている。現時点でのW3Cの発行文書とこのテクニカルレポートの最新版は、下記から参照できる。
387
+ 열람할 수 있습니다.`},zh:{sotd:"关于本文档",status_at_publication:jt`本章节描述了本文档的发布状态。W3C的文档列表和最新版本可通过<a href="https://www.w3.org/TR/">W3C技术报告</a>索引访问。`},ja:{sotd:"この文書の位置付け",status_at_publication:jt`この節には、公開時点でのこの文書の位置づけが記されている。現時点でのW3Cの発行文書とこのテクニカルレポートの最新版は、下記から参照できる。
388
388
  <a href="https://www.w3.org/TR/">W3C technical reports index</a>
389
- (https://www.w3.org/TR/)`},nl:{sotd:"Status van dit document"},es:{sotd:"Estado de este Document",status_at_publication:Ot`Esta sección describe el estado del presente
389
+ (https://www.w3.org/TR/)`},nl:{sotd:"Status van dit document"},es:{sotd:"Estado de este Document",status_at_publication:jt`Esta sección describe el estado del presente
390
390
  documento al momento de su publicación. Una lista de las publicaciones
391
391
  actuales del W3C y la última revisión del presente informe técnico puede
392
392
  hallarse en http://www.w3.org/TR/
393
393
  <a href="https://www.w3.org/TR/">el índice de informes técnicos</a> del
394
- W3C.`},de:{sotd:"Status dieses Dokuments",status_at_publication:Ot`Dieser Abschnitt beschreibt den Status des
394
+ W3C.`},de:{sotd:"Status dieses Dokuments",status_at_publication:jt`Dieser Abschnitt beschreibt den Status des
395
395
  Dokuments zum Zeitpunkt der Publikation. Eine Liste der aktuellen
396
396
  Publikatinen des W3C und die aktuellste Fassung dieser Spezifikation kann
397
397
  im <a href="https://www.w3.org/TR/">W3C technical reports index</a> unter
398
- https://www.w3.org/TR/ abgerufen werden.`}}),Nr="https://www.w3.org/2021/Process-20211102/";function Or(e){return/^[aeiou]/i.test(e)?`an ${e}`:`a ${e}`}var jr=(e,t)=>Ot`
399
- <h2>${Dr.sotd}</h2>
400
- ${e.isPreview?Mr(e):""}
401
- ${e.isUnofficial?function(e){const{additionalContent:t}=e;return Ot`
398
+ https://www.w3.org/TR/ abgerufen werden.`}}),Or="https://www.w3.org/2023/Process-20230612/";function jr(e){return/^[aeiou]/i.test(e)?`an ${e}`:`a ${e}`}var Mr=(e,t)=>jt`
399
+ <h2>${Nr.sotd}</h2>
400
+ ${e.isPreview?zr(e):""}
401
+ ${e.isUnofficial?function(e){const{additionalContent:t}=e;return jt`
402
402
  <p>
403
403
  This document is a draft of a potential specification. It has no official
404
404
  standing of any kind and does not represent the support or consensus of
405
405
  any standards organization.
406
406
  </p>
407
407
  ${t}
408
- `}(t):e.isTagFinding?t.additionalContent:e.isNoTrack?function(e,t){const{isMO:n}=e,{additionalContent:r}=t;return Ot`
408
+ `}(t):e.isTagFinding?t.additionalContent:e.isNoTrack?function(e,t){const{isMO:n}=e,{additionalContent:r}=t;return jt`
409
409
  <p>
410
410
  This document is merely a W3C-internal
411
411
  ${n?"member-confidential":""} document. It has no official standing
412
412
  of any kind and does not represent consensus of the W3C Membership.
413
413
  </p>
414
414
  ${r}
415
- `}(e,t):Ot`
416
- <p><em>${Dr.status_at_publication}</em></p>
417
- ${e.isMemberSubmission?function(e,t){return Ot`
415
+ `}(e,t):jt`
416
+ <p><em>${Nr.status_at_publication}</em></p>
417
+ ${e.isMemberSubmission?function(e,t){return jt`
418
418
  ${t.additionalContent}
419
- ${e.isMemberSubmission?function(e){const t=`https://www.w3.org/Submission/${e.publishDate.getUTCFullYear()}/${e.submissionCommentNumber}/Comment/`,n="PP2017"===e.wgPatentPolicy?"https://www.w3.org/Consortium/Patent-Policy-20170801/":"https://www.w3.org/Consortium/Patent-Policy/";return Ot`<p>
419
+ ${e.isMemberSubmission?function(e){const t=`https://www.w3.org/Submission/${e.publishDate.getUTCFullYear()}/${e.submissionCommentNumber}/Comment/`,n="PP2017"===e.wgPatentPolicy?"https://www.w3.org/Consortium/Patent-Policy-20170801/":"https://www.w3.org/Consortium/Patent-Policy/";return jt`<p>
420
420
  By publishing this document, W3C acknowledges that the
421
421
  <a href="${e.thisVersion}">Submitting Members</a> have made a formal
422
422
  Submission request to W3C for discussion. Publication of this document by
@@ -438,35 +438,35 @@ p:is(.respec-hint,.respec-occurrences){display:block;margin-top:.5em}
438
438
  >list of acknowledged W3C Member Submissions</a
439
439
  >.
440
440
  </p>`}(e):""}
441
- `}(e,t):Ot`
441
+ `}(e,t):jt`
442
442
  ${e.sotdAfterWGinfo?"":t.additionalContent}
443
- ${e.overrideStatus?"":Ot` ${function(e){if(!e.wg)return;let t=null;if(e.isRec&&e.revisionTypes&&e.revisionTypes.length){const n=e.revisionTypes.includes("proposed-addition"),r=e.revisionTypes.includes("proposed-correction"),s=e.revisionTypes.includes("addition"),i=e.revisionTypes.includes("correction");n&&r||s&&i?t=Ot`It includes
444
- ${n?Ot`<a href="${Nr}#proposed-amendments">
443
+ ${e.overrideStatus?"":jt` ${function(e){if(!e.wg)return;let t=null;if(e.isRec&&e.revisionTypes&&e.revisionTypes.length){const n=e.revisionTypes.includes("proposed-addition"),r=e.revisionTypes.includes("proposed-correction"),s=e.revisionTypes.includes("addition"),i=e.revisionTypes.includes("correction");n&&r||s&&i?t=jt`It includes
444
+ ${n?jt`<a href="${Or}#proposed-amendments">
445
445
  proposed amendments</a
446
- >`:Ot`<a href="${Nr}#candidate-amendments">
446
+ >`:jt`<a href="${Or}#candidate-amendments">
447
447
  candidate amendments</a
448
448
  >`},
449
449
  introducing substantive changes and new features since the previous
450
- Recommendation.`:n||s?t=Ot`It includes
451
- ${n?Ot`<a href="${Nr}#proposed-addition">
450
+ Recommendation.`:n||s?t=jt`It includes
451
+ ${n?jt`<a href="${Or}#proposed-addition">
452
452
  proposed additions</a
453
- >`:Ot`<a href="${Nr}#candidate-addition">
453
+ >`:jt`<a href="${Or}#candidate-addition">
454
454
  candidate additions</a
455
455
  >`},
456
- introducing new features since the previous Recommendation.`:(r||i)&&(t=Ot`It includes
457
- ${r?Ot`<a href="${Nr}#proposed-correction">
456
+ introducing new features since the previous Recommendation.`:(r||i)&&(t=jt`It includes
457
+ ${r?jt`<a href="${Or}#proposed-correction">
458
458
  proposed corrections</a
459
- >`:Ot`<a href="${Nr}#candidate-correction">
459
+ >`:jt`<a href="${Or}#candidate-correction">
460
460
  candidate corrections</a
461
- >`}.`)}const n=Gr[e.specStatus]?Ot` using the
462
- <a href="${Nr}#recs-and-notes"
463
- >${Gr[e.specStatus]} track</a
464
- >`:"";return Ot`<p>
465
- This document was published by ${zr(e)} as
466
- ${Or(e.longStatus)}${n}. ${t}
461
+ >`}.`)}const n=Vr[e.specStatus]?jt` using the
462
+ <a href="${Or}#recs-and-notes"
463
+ >${Vr[e.specStatus]} track</a
464
+ >`:"";return jt`<p>
465
+ This document was published by ${Ur(e)} as
466
+ ${jr(e.longStatus)}${n}. ${t}
467
467
  </p>`}(e)} `}
468
468
  ${e.sotdAfterWGinfo?t.additionalContent:""}
469
- ${e.isRec?function(e){const{updateableRec:t,revisionTypes:n=[],revisedRecEnd:r}=e;let s="";n.includes("proposed-addition")?s="additions":n.includes("proposed-correction")&&(s="corrections");return Ot`
469
+ ${e.isRec?function(e){const{updateableRec:t,revisionTypes:n=[],revisedRecEnd:r}=e;let s="";n.includes("proposed-addition")?s="additions":n.includes("proposed-correction")&&(s="corrections");return jt`
470
470
  <p>
471
471
  W3C recommends the wide deployment of this specification as a standard for
472
472
  the Web.
@@ -481,59 +481,59 @@ p:is(.respec-hint,.respec-occurrences){display:block;margin-top:.5em}
481
481
  >royalty-free licensing</a
482
482
  >
483
483
  for implementations.
484
- ${t?Ot`Future updates to this Recommendation may incorporate
485
- <a href="${Nr}#allow-new-features">new features</a>.`:""}
484
+ ${t?jt`Future updates to this Recommendation may incorporate
485
+ <a href="${Or}#allow-new-features">new features</a>.`:""}
486
486
  </p>
487
- ${n.includes("addition")?Ot`<p class="addition">
487
+ ${n.includes("addition")?jt`<p class="addition">
488
488
  Candidate additions are marked in the document.
489
489
  </p>`:""}
490
- ${n.includes("correction")?Ot`<p class="correction">
490
+ ${n.includes("correction")?jt`<p class="correction">
491
491
  Candidate corrections are marked in the document.
492
492
  </p>`:""}
493
- ${n.includes("proposed-addition")?Ot`<p class="addition proposed">
493
+ ${n.includes("proposed-addition")?jt`<p class="addition proposed">
494
494
  Proposed additions are marked in the document.
495
495
  </p>`:""}
496
- ${n.includes("proposed-correction")?Ot`<p class="correction proposed">
496
+ ${n.includes("proposed-correction")?jt`<p class="correction proposed">
497
497
  Proposed corrections are marked in the document.
498
498
  </p>`:""}
499
- ${s?Ot`<p>
499
+ ${s?jt`<p>
500
500
  The W3C Membership and other interested parties are invited to review
501
501
  the proposed ${s} and send comments through
502
- ${Vt.format(r)}. Advisory Committee Representatives
502
+ ${Yt.format(r)}. Advisory Committee Representatives
503
503
  should consult their
504
504
  <a href="https://www.w3.org/2002/09/wbs/myQuestionnaires"
505
505
  >WBS questionnaires</a
506
506
  >.
507
507
  </p>`:""}
508
- `}(e):function(e){let t=null,n=null,r=Ot`Publication as ${Or(e.textStatus)} does not
509
- imply endorsement by W3C and its Members.`,s=Ot`<p>
508
+ `}(e):function(e){let t=null,n=null,r=jt`Publication as ${jr(e.textStatus)} does not
509
+ imply endorsement by W3C and its Members.`,s=jt`<p>
510
510
  This is a draft document and may be updated, replaced or obsoleted by other
511
511
  documents at any time. It is inappropriate to cite this document as other
512
512
  than work in progress.
513
- ${e.updateableRec?Ot`Future updates to this specification may incorporate
514
- <a href="${Nr}#allow-new-features">new features</a>.`:""}
515
- </p>`;"DISC"===e.specStatus&&(s=Ot`<p>
513
+ ${e.updateableRec?jt`Future updates to this specification may incorporate
514
+ <a href="${Or}#allow-new-features">new features</a>.`:""}
515
+ </p>`;"DISC"===e.specStatus&&(s=jt`<p>
516
516
  Publication as a Discontinued Draft implies that this document is no
517
517
  longer intended to advance or to be maintained. It is inappropriate to
518
518
  cite this document as other than abandoned work.
519
- </p>`);const i=Ot`<p>
519
+ </p>`);const i=jt`<p>
520
520
  This document is maintained and updated at any time. Some parts of this
521
521
  document are work in progress.
522
- </p>`;switch(e.specStatus){case"STMT":r=Ot`<p>
522
+ </p>`;switch(e.specStatus){case"STMT":r=jt`<p>
523
523
  A W3C Statement is a specification that, after extensive
524
524
  consensus-building, has received the endorsement of the
525
525
  <abbr title="World Wide Web Consortium">W3C</abbr> and its Members.
526
- </p>`;break;case"RY":r=Ot`<p>W3C recommends the wide usage of this registry.</p>
526
+ </p>`;break;case"RY":r=jt`<p>W3C recommends the wide usage of this registry.</p>
527
527
  <p>
528
528
  A W3C Registry is a specification that, after extensive
529
529
  consensus-building, has received the endorsement of the
530
530
  <abbr title="World Wide Web Consortium">W3C</abbr> and its Members.
531
- </p>`;break;case"CRD":t=Ot`A Candidate Recommendation Draft integrates
531
+ </p>`;break;case"CRD":t=jt`A Candidate Recommendation Draft integrates
532
532
  changes from the previous Candidate Recommendation that the Working Group
533
- intends to include in a subsequent Candidate Recommendation Snapshot.`,"LS"===e.pubMode&&(s=i);break;case"CRYD":t=Ot`A Candidate Registry Draft integrates changes
533
+ intends to include in a subsequent Candidate Recommendation Snapshot.`,"LS"===e.pubMode&&(s=i);break;case"CRYD":t=jt`A Candidate Registry Draft integrates changes
534
534
  from the previous Candidate Registry Snapshot that the Working Group
535
- intends to include in a subsequent Candidate Registry Snapshot.`,"LS"===e.pubMode&&(s=i);break;case"CRY":t=Ot`A Candidate Registry Snapshot has received
536
- <a href="${Nr}#dfn-wide-review">wide review</a>.`,n=Ot`<p>
535
+ intends to include in a subsequent Candidate Registry Snapshot.`,"LS"===e.pubMode&&(s=i);break;case"CRY":t=jt`A Candidate Registry Snapshot has received
536
+ <a href="${Or}#dfn-wide-review">wide review</a>.`,n=jt`<p>
537
537
  The W3C Membership and other interested parties are invited to review
538
538
  the document and send comments through ${e.humanPREnd}. Advisory
539
539
  Committee Representatives should consult their
@@ -541,37 +541,37 @@ p:is(.respec-hint,.respec-occurrences){display:block;margin-top:.5em}
541
541
  >WBS questionnaires</a
542
542
  >. Note that substantive technical comments were expected during the
543
543
  Candidate Recommendation review period that ended ${e.humanCREnd}.
544
- </p>`;break;case"CR":t=Ot`A Candidate Recommendation Snapshot has received
545
- <a href="${Nr}#dfn-wide-review">wide review</a>, is intended to
544
+ </p>`;break;case"CR":t=jt`A Candidate Recommendation Snapshot has received
545
+ <a href="${Or}#dfn-wide-review">wide review</a>, is intended to
546
546
  gather
547
547
  <a href="${e.implementationReportURI}">implementation experience</a>,
548
548
  and has commitments from Working Group members to
549
549
  <a href="https://www.w3.org/Consortium/Patent-Policy/#sec-Requirements"
550
550
  >royalty-free licensing</a
551
551
  >
552
- for implementations.`,s=Ot`${e.updateableRec?Ot`Future updates to this specification may incorporate
553
- <a href="${Nr}#allow-new-features">new features</a>.`:""}`,n="LS"===e.pubMode?Ot`<p>
552
+ for implementations.`,s=jt`${e.updateableRec?jt`Future updates to this specification may incorporate
553
+ <a href="${Or}#allow-new-features">new features</a>.`:""}`,n="LS"===e.pubMode?jt`<p>
554
554
  Comments are welcome at any time but most especially before
555
- ${Vt.format(e.crEnd)}.
556
- </p>`:Ot`<p>
555
+ ${Yt.format(e.crEnd)}.
556
+ </p>`:jt`<p>
557
557
  This Candidate Recommendation is not expected to advance to Proposed
558
- Recommendation any earlier than ${Vt.format(e.crEnd)}.
559
- </p>`;break;case"PR":n=Ot`<p>
558
+ Recommendation any earlier than ${Yt.format(e.crEnd)}.
559
+ </p>`;break;case"PR":n=jt`<p>
560
560
  The W3C Membership and other interested parties are invited to review
561
- the document and send comments through ${Vt.format(e.prEnd)}.
561
+ the document and send comments through ${Yt.format(e.prEnd)}.
562
562
  Advisory Committee Representatives should consult their
563
563
  <a href="https://www.w3.org/2002/09/wbs/myQuestionnaires"
564
564
  >WBS questionnaires</a
565
565
  >. Note that substantive technical comments were expected during the
566
566
  Candidate Recommendation review period that ended
567
- ${Vt.format(e.crEnd)}.
568
- </p>`;break;case"DNOTE":r=Ot`${e.textStatus}s are not endorsed by
569
- <abbr title="World Wide Web Consortium">W3C</abbr> nor its Members.`;break;case"NOTE":r=Ot`This ${e.textStatus} is endorsed by
570
- ${zr(e)}, but is not endorsed by
567
+ ${Yt.format(e.crEnd)}.
568
+ </p>`;break;case"DNOTE":r=jt`${e.textStatus}s are not endorsed by
569
+ <abbr title="World Wide Web Consortium">W3C</abbr> nor its Members.`;break;case"NOTE":r=jt`This ${e.textStatus} is endorsed by
570
+ ${Ur(e)}, but is not endorsed by
571
571
  <abbr title="World Wide Web Consortium">W3C</abbr> itself nor its
572
- Members.`}return Ot`<p>${r} ${t}</p>
572
+ Members.`}return jt`<p>${r} ${t}</p>
573
573
  ${s} ${n}`}(e)}
574
- ${function(e){const{isNote:t,isRegistry:n,wgId:r,multipleWGs:s,wgPatentHTML:i,wgPatentURI:o,wgPatentPolicy:a}=e,c="PP2017"===a?"https://www.w3.org/Consortium/Patent-Policy-20170801/":"https://www.w3.org/Consortium/Patent-Policy/",l=t||n?Ot`
574
+ ${function(e){const{isNote:t,isRegistry:n,wgId:r,multipleWGs:s,wgPatentHTML:i,wgPatentURI:o,wgPatentPolicy:a}=e,c="PP2017"===a?"https://www.w3.org/Consortium/Patent-Policy-20170801/":"https://www.w3.org/Consortium/Patent-Policy/",l=t||n?jt`
575
575
  The
576
576
  <a href="${c}"
577
577
  >${"PP2017"===a?"1 August 2017 ":""}W3C Patent
@@ -579,17 +579,17 @@ p:is(.respec-hint,.respec-occurrences){display:block;margin-top:.5em}
579
579
  >
580
580
  does not carry any licensing requirements or commitments on this
581
581
  document.
582
- `:Ot`
582
+ `:jt`
583
583
  This document was produced by ${s?"groups":"a group"}
584
584
  operating under the
585
585
  <a href="${c}"
586
586
  >${"PP2017"===a?"1 August 2017 ":""}W3C Patent
587
587
  Policy</a
588
588
  >.
589
- `;return Ot`<p data-deliverer="${t||n?r:null}">
589
+ `;return jt`<p data-deliverer="${t||n?r:null}">
590
590
  ${l}
591
- ${t||n?"":Ot`
592
- ${s?Ot` W3C maintains ${i} `:Ot`
591
+ ${t||n?"":jt`
592
+ ${s?jt` W3C maintains ${i} `:jt`
593
593
  W3C maintains a
594
594
  <a href="${[o]}" rel="disclosure"
595
595
  >public list of any patent disclosures</a
@@ -608,17 +608,17 @@ p:is(.respec-hint,.respec-occurrences){display:block;margin-top:.5em}
608
608
  </p>`}(e)}
609
609
  <p>
610
610
  This document is governed by the
611
- <a id="w3c_process_revision" href="${Nr}"
612
- >2 November 2021 W3C Process Document</a
611
+ <a id="w3c_process_revision" href="${Or}"
612
+ >12 June 2023 W3C Process Document</a
613
613
  >.
614
614
  </p>
615
615
  `}
616
616
  `}
617
617
  ${t.additionalSections}
618
- `;function Mr(e){const{prUrl:t,prNumber:n,edDraftURI:r}=e;return Ot`<details class="annoying-warning" open="">
618
+ `;function zr(e){const{prUrl:t,prNumber:n,edDraftURI:r}=e;return jt`<details class="annoying-warning" open="">
619
619
  <summary>
620
620
  This is a
621
- preview${t&&n?Ot`
621
+ preview${t&&n?jt`
622
622
  of pull request
623
623
  <a href="${t}">#${n}</a>
624
624
  `:""}
@@ -626,25 +626,25 @@ p:is(.respec-hint,.respec-occurrences){display:block;margin-top:.5em}
626
626
  <p>
627
627
  Do not attempt to implement this version of the specification. Do not
628
628
  reference this version as authoritative in any way.
629
- ${r?Ot`
629
+ ${r?jt`
630
630
  Instead, see
631
631
  <a href="${r}">${r}</a> for the Editor's draft.
632
632
  `:""}
633
633
  </p>
634
- </details>`}function zr(e){return Array.isArray(e.wg)?dn(e.wg,((t,n)=>Ot`the <a href="${e.wgURI[n]}">${t}</a>`)):e.wg?Ot`the <a href="${e.wgURI}">${e.wg}</a>`:void 0}var Ur=(e,t)=>Ot`
635
- <h2>${Dr.sotd}</h2>
636
- ${e.isPreview?Mr(e):""}
634
+ </details>`}function Ur(e){return Array.isArray(e.wg)?pn(e.wg,((t,n)=>jt`the <a href="${e.wgURI[n]}">${t}</a>`)):e.wg?jt`the <a href="${e.wgURI}">${e.wg}</a>`:void 0}var qr=(e,t)=>jt`
635
+ <h2>${Nr.sotd}</h2>
636
+ ${e.isPreview?zr(e):""}
637
637
  <p>
638
638
  This specification was published by the
639
639
  <a href="${e.wgURI}">${e.wg}</a>. It is not a W3C Standard nor is it
640
640
  on the W3C Standards Track.
641
- ${e.isCGFinal?Ot`
641
+ ${e.isCGFinal?jt`
642
642
  Please note that under the
643
643
  <a href="https://www.w3.org/community/about/agreements/final/"
644
644
  >W3C Community Final Specification Agreement (FSA)</a
645
645
  >
646
646
  other conditions apply.
647
- `:Ot`
647
+ `:jt`
648
648
  Please note that under the
649
649
  <a href="https://www.w3.org/community/about/agreements/cla/"
650
650
  >W3C Community Contributor License Agreement (CLA)</a
@@ -657,19 +657,19 @@ p:is(.respec-hint,.respec-occurrences){display:block;margin-top:.5em}
657
657
  >.
658
658
  </p>
659
659
  ${e.sotdAfterWGinfo?"":t.additionalContent}
660
- ${!e.github&&e.wgPublicList?function(e,t){const{mailToWGPublicListWithSubject:n,mailToWGPublicListSubscription:r}=t,{wgPublicList:s,subjectPrefix:i}=e;return Ot`<p>
660
+ ${!e.github&&e.wgPublicList?function(e,t){const{mailToWGPublicListWithSubject:n,mailToWGPublicListSubscription:r}=t,{wgPublicList:s,subjectPrefix:i}=e;return jt`<p>
661
661
  If you wish to make comments regarding this document, please send them to
662
662
  <a href="${n}">${s}@w3.org</a>
663
663
  (<a href="${r}">subscribe</a>,
664
- <a href="${`https://lists.w3.org/Archives/Public/${s}/`}">archives</a>)${i?Ot` with <code>${i}</code> at the start of your email's
664
+ <a href="${`https://lists.w3.org/Archives/Public/${s}/`}">archives</a>)${i?jt` with <code>${i}</code> at the start of your email's
665
665
  subject`:""}.
666
666
  </p>`}(e,t):""}
667
- ${e.github?function(e,t){if(e.github||e.wgPublicList)return Ot`<p>
668
- ${e.github?Ot`
667
+ ${e.github?function(e,t){if(e.github||e.wgPublicList)return jt`<p>
668
+ ${e.github?jt`
669
669
  <a href="${e.issueBase}">GitHub Issues</a> are preferred for
670
670
  discussion of this specification.
671
671
  `:""}
672
- ${e.wgPublicList?Ot`
672
+ ${e.wgPublicList?jt`
673
673
  ${e.github&&e.wgPublicList?"Alternatively, you can send comments to our mailing list.":"Comments regarding this document are welcome."}
674
674
  Please send them to
675
675
  <a href="${t.mailToWGPublicListWithSubject}"
@@ -679,23 +679,23 @@ p:is(.respec-hint,.respec-occurrences){display:block;margin-top:.5em}
679
679
  <a
680
680
  href="${`https://lists.w3.org/Archives/Public/${e.wgPublicList}/`}"
681
681
  >archives</a
682
- >)${e.subjectPrefix?Ot` with <code>${e.subjectPrefix}</code> at the start of your
682
+ >)${e.subjectPrefix?jt` with <code>${e.subjectPrefix}</code> at the start of your
683
683
  email's subject`:""}.
684
684
  `:""}
685
685
  </p>`}(e,t):""}
686
686
  ${e.sotdAfterWGinfo?t.additionalContent:""}
687
687
  ${t.additionalSections}
688
- `;const qr="w3c/headers";function Wr(e){return new URL(e,"https://www.w3.org/").href}const Fr={LS:"WD",LD:"WD",FPWD:"WD","Member-SUBM":"SUBM"},Br={DNOTE:"Group Draft Note",NOTE:"Group Note",STMT:"Statement","Member-SUBM":"Member Submission",MO:"Member-Only Document",ED:"Editor's Draft",LS:"Living Standard",LD:"Living Document",FPWD:"First Public Working Draft",WD:"Working Draft",CR:"Candidate Recommendation",CRD:"Candidate Recommendation",PR:"Proposed Recommendation",PER:"Proposed Edited Recommendation",REC:"Recommendation",DISC:"Discontinued Draft",RSCND:"Rescinded Recommendation",DRY:"Draft Registry",CRYD:"Candidate Registry",CRY:"Candidate Registry",RY:"Registry",unofficial:"Unofficial Draft",UD:"Unofficial Draft",base:"",finding:"TAG Finding","draft-finding":"Draft TAG Finding","editor-draft-finding":"Draft TAG Finding","CG-DRAFT":"Draft Community Group Report","CG-FINAL":"Final Community Group Report","BG-DRAFT":"Draft Business Group Report","BG-FINAL":"Final Business Group Report"},Hr={...Br,CR:"Candidate Recommendation Snapshot",CRD:"Candidate Recommendation Draft",CRY:"Candidate Registry Snapshot",CRYD:"Candidate Registry Draft"},Gr={DNOTE:"Note",NOTE:"Note",STMT:"Note","WG-NOTE":"Note","IG-NOTE":"Note",FPWD:"Recommendation",WD:"Recommendation",CR:"Recommendation",CRD:"Recommendation",PR:"Recommendation",REC:"Recommendation",DISC:"Recommendation",RSCND:"Recommendation",DRY:"Registry",CRYD:"Registry",CRY:"Registry",RY:"Registry"},Vr=["DNOTE","NOTE","STMT"],Yr=["CR","CRD","DISC","FPWD","PER","PR","REC","RSCND","WD"],Kr=["DRY","CRY","CRYD","RY"],Zr=["draft-finding","finding","editor-draft-finding"],Jr=["CG-DRAFT","CG-FINAL"],Xr=["BG-DRAFT","BG-FINAL"],Qr=[...Jr,...Xr],es=[...Vr,...Yr,...Kr],ts=["base",...Jr,...Xr,"editor-draft-finding","draft-finding","finding","MO","unofficial"],ns=new Map([["cc0",{name:"Creative Commons 0 Public Domain Dedication",short:"CC0",url:"https://creativecommons.org/publicdomain/zero/1.0/"}],["w3c-software",{name:"W3C Software Notice and License",short:"W3C Software",url:"https://www.w3.org/Consortium/Legal/2002/copyright-software-20021231"}],["w3c-software-doc",{name:"W3C Software and Document Notice and License",short:"permissive document license",url:"https://www.w3.org/Consortium/Legal/2023/software-license"}],["cc-by",{name:"Creative Commons Attribution 4.0 International Public License",short:"CC-BY",url:"https://creativecommons.org/licenses/by/4.0/legalcode"}],["document",{name:"W3C Document License",short:"document use",url:"https://www.w3.org/Consortium/Legal/copyright-documents"}],["dual",{name:"W3C Dual License",short:"dual license",url:"https://www.w3.org/Consortium/Legal/2013/copyright-documents-dual.html"}],[void 0,{name:"unlicensed",url:null,short:"UNLICENSED"}]]),rs=["PP2017","PP2020"];function ss(e,t,n=new Date){const r=e[t]?new Date(e[t]):new Date(n);if(Number.isFinite(r.valueOf())){const e=Ht.format(r);return new Date(e)}return Rn(In`${t} is not a valid date: "${e[t]}". Expected format 'YYYY-MM-DD'.`,qr),new Date(Ht.format(new Date))}function is(e,{isTagFinding:t=!1}){const n=e.cloneNode(!0),r=document.createDocumentFragment();for(;n.hasChildNodes()&&(n.nodeType!==Node.ELEMENT_NODE||"section"!==n.firstChild.localName);)r.appendChild(n.firstChild);if(t&&!r.hasChildNodes()){En(In`ReSpec does not support automated SotD generation for TAG findings.`,qr,{hint:"Please add the prerequisite content in the 'sotd' section."})}return{additionalContent:r,additionalSections:n.childNodes}}var os=Object.freeze({__proto__:null,W3CNotes:Vr,bgStatus:Xr,cgStatus:Jr,cgbgStatus:Qr,licenses:ns,name:qr,noTrackStatus:ts,recTrackStatus:Yr,registryTrackStatus:Kr,run:async function(e){if(e.isBasic="base"===e.specStatus,e.isCGBG=Qr.includes(e.specStatus),e.isCGFinal=e.isCGBG&&e.specStatus.endsWith("G-FINAL"),e.isCR="CR"===e.specStatus||"CRD"===e.specStatus,e.isCRDraft="CRD"===e.specStatus,e.isCRY="CRY"===e.specStatus||"CRYD"===e.specStatus,e.isEd="ED"===e.specStatus,e.isMemberSubmission="Member-SUBM"===e.specStatus,e.isMO="MO"===e.specStatus,e.isNote=Vr.includes(e.specStatus),e.isNoTrack=ts.includes(e.specStatus),e.isPER="PER"===e.specStatus,e.isPR="PR"===e.specStatus,e.isRecTrack=Yr.includes(e.specStatus),e.isRec=e.isRecTrack&&"REC"===e.specStatus,e.isRegistry=Kr.includes(e.specStatus),e.isRegular=!e.isCGBG&&!e.isBasic,e.isTagEditorFinding="editor-draft-finding"===e.specStatus,e.isTagFinding=Zr.includes(e.specStatus),e.isUnofficial="unofficial"===e.specStatus,e.licenseInfo=function(e){let t;if("string"==typeof e.license){const n=e.license.toLowerCase();if(ns.has(n))t=n;else{const t=`The license "\`${e.license}\`" is not supported.`,n=In`Please set
689
- ${"[license]"} to one of: ${Tn([...ns.keys()].filter((e=>e)),{quotes:!0})}. If in doubt, remove \`license\` and let ReSpec pick one for you.`;Rn(t,qr,{hint:n})}}if(e.isUnofficial&&!t&&(t="cc-by"),!e.isUnofficial&&["cc-by","cc0"].includes(t)){const t=In`Please set ${"[license]"} to \`"w3c-software-doc"\` instead.`;Rn(In`License "\`${e.license}\`" is not allowed for W3C Specifications.`,qr,{hint:t})}return ns.get(t)}(e),e.prependW3C=!e.isBasic&&!e.isUnofficial,e.longStatus=Hr[e.specStatus],e.textStatus=Br[e.specStatus],e.showPreviousVersion=!1,e.isRegular&&!e.shortName){const e=In`Please set ${"[shortName]"} to a short name for the specification.`;Rn(In`The ${"[shortName]"} configuration option is required for this kind of document.`,qr,{hint:e})}if(e.publishDate=ss(e,"publishDate",document.lastModified),e.publishYear=e.publishDate.getUTCFullYear(),e.modificationDate&&(e.modificationDate=ss(e,"modificationDate",document.lastModified)),e.isRecTrack&&!e.github&&!e.wgPublicList){const e=In`Use the ${"[github]"} configuration option to add a link to a repository. Alternatively use ${"[wgPublicList]"} to link to a mailing list.`;Rn("W3C Process requires a either a link to a public repository or mailing list.",qr,{hint:e})}if(e.isEd&&!e.edDraftURI){const e=In`Please set ${"[edDraftURI]"} to the URL of the Editor's Draft. Alternatively, use the set ${"[github]"} option, which automatically sets it for you.`;En(In`Editor's Drafts should set ${"[edDraftURI]"} configuration option.`,qr,{hint:e})}const t=function(e){const{specStatus:t,group:n}=e;if(es.includes(t)||"wg"===e.groupType)return"/TR";switch(t){case"CG-FINAL":case"BG-FINAL":return`/community/reports/${n}`;case"finding":case"draft-finding":return"/2001/tag/doc";case"Member-SUBM":return"/Submission"}return""}(e);if(t&&!e.thisVersion){const n=Fr[e.specStatus]||e.specStatus,{shortName:r,publishDate:s}=e,i=`${n}-${r}-${an(s)}`,o=[...es,"Member-SUBM"].includes(e.specStatus)?`${s.getUTCFullYear()}/`:"";e.thisVersion=Wr(`${t}/${o}${i}/`)}e.isEd&&(e.thisVersion=e.edDraftURI),e.isCGBG&&function(e){const t=Br[e.specStatus],n=e.latestVersion?new URL(Wr(e.latestVersion)):null;if(!e.wg){return void Rn(In`The ${"[group]"} configuration option is required for this kind of document (${t}).`,qr)}if(e.isCGFinal){if(!1===("https://www.w3.org"===n?.origin||"https://w3.org/"===n?.origin)){Rn(In`For ${t}, the ${"[latestVersion]"} URL must point to somewhere at https://www.w3.org/.`,qr,{hint:"Ask a W3C Team Member for a W3C URL where the report can be published."})}}}(e),null!==e.latestVersion&&(e.latestVersion=e.latestVersion?Wr(e.latestVersion):Wr(`${t}/${e.shortName}/`)),e.latestVersion&&function(e){const t=new URL(e.latestVersion);if(("https://www.w3.org"===t.origin||"https://w3.org/"===t.origin)&&t.pathname.startsWith("/TR/")&&!1===["ED",...es].includes(e.specStatus)){const t=In`Ask a W3C Team Member for a W3C URL where the report can be published and change ${"[latestVersion]"} to something else.`;Rn(In`Documents with a status of \`"${e.specStatus}"\` can't be published on the W3C's /TR/ (Technical Report) space.`,qr,{hint:t})}}(e);const n=`${t}/${e.shortName}`;if(e.previousPublishDate){if(!e.previousMaturity&&!e.isTagFinding){Rn(In`${"[`previousPublishDate`]"} is set, but missing ${"[`previousMaturity`]"}.`,qr)}e.previousPublishDate=ss(e,"previousPublishDate");const r=Fr[e.previousMaturity]??e.previousMaturity;if(e.isTagFinding&&e.latestVersion){const t=Ht.format(e.publishDate);e.thisVersion=Wr(`${n}-${t}`);const r=Ht.format(e.previousPublishDate);e.prevVersion=Wr(`${n}-${r}}`)}else if(e.isCGBG||e.isBasic)e.prevVersion=e.prevVersion||"";else{const n=e.previousPublishDate.getUTCFullYear(),{shortName:s}=e,i=an(e.previousPublishDate);e.prevVersion=Wr(`${t}/${n}/${r}-${s}-${i}/`)}}e.prevRecShortname&&!e.prevRecURI&&(e.prevRecURI=Wr(`${t}/${e.prevRecShortname}`));for(let t=0;t<e.editors.length;t++){const n=e.editors[t];"retiredDate"in n&&(e.formerEditors.push(n),e.editors.splice(t--,1))}if(0===e.editors.length){const e=In`Add one or more editors using the ${"[editors]"} configuration option.`;Rn("At least one editor is required.",qr,{hint:e})}else e.editors.length&&e.isRecTrack&&e.editors.forEach(((e,t)=>{if(e.w3cid)return;const n=In`See ${"[w3cid]"} for instructions for how to retrieve it and add it.`;Rn(In`Editor ${e.name?`"${e.name}"`:`number ${t+1}`} is missing their ${"[w3cid]"}.`,qr,{hint:n})}));if(e.alternateFormats?.some((({uri:e,label:t})=>!e||!t))){Rn(In`Every ${"[`alternateFormats`]"} entry must have a \`uri\` and a \`label\`.`,qr)}if(e.copyrightStart==e.publishYear&&(e.copyrightStart=""),e.isRec&&!e.errata&&!e.revisionTypes?.length){const e=In`Add an ${"[errata]"} URL to your ${"[respecConfig]"}.`;Rn("Recommendations must have an errata link.",qr,{hint:e})}e.dashDate=Ht.format(e.publishDate),e.publishISODate=e.publishDate.toISOString(),e.shortISODate=Ht.format(e.publishDate),function(e){if(!e.wgPatentPolicy)return;const t=new Set([].concat(e.wgPatentPolicy));if(t.size&&![...t].every((e=>rs.includes(e)))){const e=In`Invalid ${"[wgPatentPolicy]"} value(s): ${Ln([...t].filter((e=>!rs.includes(e))))}.`,n=`Please use one of: ${Tn(rs)}.`;Rn(e,qr,{hint:n})}if(1!==t.size){const e="When collaborating across multiple groups, they must use the same patent policy.",n=In`For ${"[wgPatentPolicy]"}, please check the patent policies of each group. The patent policies were: ${[...t].join(", ")}.`;Rn(e,qr,{hint:n})}e.wgPatentPolicy=[...t][0]}(e),await async function(e){if(!e.shortName||null===e.historyURI||!e.latestVersion)return;const t=e.isEd||es.includes(e.specStatus);if(e.historyURI&&!t){const t=In`Please remove ${"[historyURI]"}.`;return Rn(In`The ${"[historyURI]"} can't be used with non /TR/ documents.`,qr,{hint:t}),void(e.historyURI=null)}const n=new URL(e.historyURI??`${e.shortName}/`,"https://www.w3.org/standards/history/");if(e.historyURI&&t||["FPWD","DNOTE","NOTE","DRY"].includes(e.specStatus))return void(e.historyURI=n.href);try{const t=await fetch(n,{method:"HEAD"});t.ok&&(e.historyURI=t.url)}catch{}}(e),e.isTagEditorFinding&&(delete e.thisVersion,delete e.latestVersion),e.isTagFinding&&(e.showPreviousVersion=!!e.previousPublishDate);const s={get multipleAlternates(){return e.alternateFormats&&e.alternateFormats.length>1},get alternatesHTML(){return e.alternateFormats&&dn(e.alternateFormats.map((({label:e})=>e)),((t,n)=>{const r=e.alternateFormats[n];return Ot`<a
688
+ `;const Wr="w3c/headers";function Fr(e){return new URL(e,"https://www.w3.org/").href}const Br={LS:"WD",LD:"WD",FPWD:"WD","Member-SUBM":"SUBM"},Hr={DNOTE:"Group Draft Note",NOTE:"Group Note",STMT:"Statement","Member-SUBM":"Member Submission",MO:"Member-Only Document",ED:"Editor's Draft",LS:"Living Standard",LD:"Living Document",FPWD:"First Public Working Draft",WD:"Working Draft",CR:"Candidate Recommendation",CRD:"Candidate Recommendation",PR:"Proposed Recommendation",PER:"Proposed Edited Recommendation",REC:"Recommendation",DISC:"Discontinued Draft",RSCND:"Rescinded Recommendation",DRY:"Draft Registry",CRYD:"Candidate Registry",CRY:"Candidate Registry",RY:"Registry",unofficial:"Unofficial Draft",UD:"Unofficial Draft",base:"",finding:"TAG Finding","draft-finding":"Draft TAG Finding","editor-draft-finding":"Draft TAG Finding","CG-DRAFT":"Draft Community Group Report","CG-FINAL":"Final Community Group Report","BG-DRAFT":"Draft Business Group Report","BG-FINAL":"Final Business Group Report"},Gr={...Hr,CR:"Candidate Recommendation Snapshot",CRD:"Candidate Recommendation Draft",CRY:"Candidate Registry Snapshot",CRYD:"Candidate Registry Draft"},Vr={DNOTE:"Note",NOTE:"Note",STMT:"Note","WG-NOTE":"Note","IG-NOTE":"Note",FPWD:"Recommendation",WD:"Recommendation",CR:"Recommendation",CRD:"Recommendation",PR:"Recommendation",REC:"Recommendation",DISC:"Recommendation",RSCND:"Recommendation",DRY:"Registry",CRYD:"Registry",CRY:"Registry",RY:"Registry"},Yr=["DNOTE","NOTE","STMT"],Kr=["CR","CRD","DISC","FPWD","PER","PR","REC","RSCND","WD"],Zr=["DRY","CRY","CRYD","RY"],Jr=["draft-finding","finding","editor-draft-finding"],Xr=["CG-DRAFT","CG-FINAL"],Qr=["BG-DRAFT","BG-FINAL"],es=[...Xr,...Qr],ts=[...Yr,...Kr,...Zr],ns=["base",...Xr,...Qr,"editor-draft-finding","draft-finding","finding","MO","unofficial"],rs=new Map([["cc0",{name:"Creative Commons 0 Public Domain Dedication",short:"CC0",url:"https://creativecommons.org/publicdomain/zero/1.0/"}],["w3c-software",{name:"W3C Software Notice and License",short:"W3C Software",url:"https://www.w3.org/Consortium/Legal/2002/copyright-software-20021231"}],["w3c-software-doc",{name:"W3C Software and Document Notice and License",short:"permissive document license",url:"https://www.w3.org/Consortium/Legal/2023/software-license"}],["cc-by",{name:"Creative Commons Attribution 4.0 International Public License",short:"CC-BY",url:"https://creativecommons.org/licenses/by/4.0/legalcode"}],["document",{name:"W3C Document License",short:"document use",url:"https://www.w3.org/Consortium/Legal/copyright-documents"}],["dual",{name:"W3C Dual License",short:"dual license",url:"https://www.w3.org/Consortium/Legal/2013/copyright-documents-dual.html"}],[void 0,{name:"unlicensed",url:null,short:"UNLICENSED"}]]),ss=["PP2017","PP2020"];function is(e,t,n=new Date){const r=e[t]?new Date(e[t]):new Date(n);if(Number.isFinite(r.valueOf())){const e=Gt.format(r);return new Date(e)}return En(Dn`${t} is not a valid date: "${e[t]}". Expected format 'YYYY-MM-DD'.`,Wr),new Date(Gt.format(new Date))}function os(e,{isTagFinding:t=!1}){const n=e.cloneNode(!0),r=document.createDocumentFragment();for(;n.hasChildNodes()&&(n.nodeType!==Node.ELEMENT_NODE||"section"!==n.firstChild.localName);)r.appendChild(n.firstChild);if(t&&!r.hasChildNodes()){An(Dn`ReSpec does not support automated SotD generation for TAG findings.`,Wr,{hint:"Please add the prerequisite content in the 'sotd' section."})}return{additionalContent:r,additionalSections:n.childNodes}}var as=Object.freeze({__proto__:null,W3CNotes:Yr,bgStatus:Qr,cgStatus:Xr,cgbgStatus:es,licenses:rs,name:Wr,noTrackStatus:ns,recTrackStatus:Kr,registryTrackStatus:Zr,run:async function(e){if(e.isBasic="base"===e.specStatus,e.isCGBG=es.includes(e.specStatus),e.isCGFinal=e.isCGBG&&e.specStatus.endsWith("G-FINAL"),e.isCR="CR"===e.specStatus||"CRD"===e.specStatus,e.isCRDraft="CRD"===e.specStatus,e.isCRY="CRY"===e.specStatus||"CRYD"===e.specStatus,e.isEd="ED"===e.specStatus,e.isMemberSubmission="Member-SUBM"===e.specStatus,e.isMO="MO"===e.specStatus,e.isNote=Yr.includes(e.specStatus),e.isNoTrack=ns.includes(e.specStatus),e.isPER="PER"===e.specStatus,e.isPR="PR"===e.specStatus,e.isRecTrack=Kr.includes(e.specStatus),e.isRec=e.isRecTrack&&"REC"===e.specStatus,e.isRegistry=Zr.includes(e.specStatus),e.isRegular=!e.isCGBG&&!e.isBasic,e.isTagEditorFinding="editor-draft-finding"===e.specStatus,e.isTagFinding=Jr.includes(e.specStatus),e.isUnofficial="unofficial"===e.specStatus,e.licenseInfo=function(e){let t;if("string"==typeof e.license){const n=e.license.toLowerCase();if(rs.has(n))t=n;else{const t=`The license "\`${e.license}\`" is not supported.`,n=Dn`Please set
689
+ ${"[license]"} to one of: ${Ln([...rs.keys()].filter((e=>e)),{quotes:!0})}. If in doubt, remove \`license\` and let ReSpec pick one for you.`;En(t,Wr,{hint:n})}}if(e.isUnofficial&&!t&&(t="cc-by"),!e.isUnofficial&&["cc-by","cc0"].includes(t)){const t=Dn`Please set ${"[license]"} to \`"w3c-software-doc"\` instead.`;En(Dn`License "\`${e.license}\`" is not allowed for W3C Specifications.`,Wr,{hint:t})}return rs.get(t)}(e),e.prependW3C=!e.isBasic&&!e.isUnofficial,e.longStatus=Gr[e.specStatus],e.textStatus=Hr[e.specStatus],e.showPreviousVersion=!1,e.isRegular&&!e.shortName){const e=Dn`Please set ${"[shortName]"} to a short name for the specification.`;En(Dn`The ${"[shortName]"} configuration option is required for this kind of document.`,Wr,{hint:e})}if(e.publishDate=is(e,"publishDate",document.lastModified),e.publishYear=e.publishDate.getUTCFullYear(),e.modificationDate&&(e.modificationDate=is(e,"modificationDate",document.lastModified)),e.isRecTrack&&!e.github&&!e.wgPublicList){const e=Dn`Use the ${"[github]"} configuration option to add a link to a repository. Alternatively use ${"[wgPublicList]"} to link to a mailing list.`;En("W3C Process requires a either a link to a public repository or mailing list.",Wr,{hint:e})}if(e.isEd&&!e.edDraftURI){const e=Dn`Please set ${"[edDraftURI]"} to the URL of the Editor's Draft. Alternatively, use the set ${"[github]"} option, which automatically sets it for you.`;An(Dn`Editor's Drafts should set ${"[edDraftURI]"} configuration option.`,Wr,{hint:e})}const t=function(e){const{specStatus:t,group:n}=e;if(ts.includes(t)||"wg"===e.groupType)return"/TR";switch(t){case"CG-FINAL":case"BG-FINAL":return`/community/reports/${n}`;case"finding":case"draft-finding":return"/2001/tag/doc";case"Member-SUBM":return"/Submission"}return""}(e);if(t&&!e.thisVersion){const n=Br[e.specStatus]||e.specStatus,{shortName:r,publishDate:s}=e,i=`${n}-${r}-${cn(s)}`,o=[...ts,"Member-SUBM"].includes(e.specStatus)?`${s.getUTCFullYear()}/`:"";e.thisVersion=Fr(`${t}/${o}${i}/`)}e.isEd&&(e.thisVersion=e.edDraftURI),e.isCGBG&&function(e){const t=Hr[e.specStatus],n=e.latestVersion?new URL(Fr(e.latestVersion)):null;if(!e.wg){return void En(Dn`The ${"[group]"} configuration option is required for this kind of document (${t}).`,Wr)}if(e.isCGFinal){if(!1===("https://www.w3.org"===n?.origin||"https://w3.org/"===n?.origin)){En(Dn`For ${t}, the ${"[latestVersion]"} URL must point to somewhere at https://www.w3.org/.`,Wr,{hint:"Ask a W3C Team Member for a W3C URL where the report can be published."})}}}(e),null!==e.latestVersion&&(e.latestVersion=e.latestVersion?Fr(e.latestVersion):Fr(`${t}/${e.shortName}/`)),e.latestVersion&&function(e){const t=new URL(e.latestVersion);if(("https://www.w3.org"===t.origin||"https://w3.org/"===t.origin)&&t.pathname.startsWith("/TR/")&&!1===["ED",...ts].includes(e.specStatus)){const t=Dn`Ask a W3C Team Member for a W3C URL where the report can be published and change ${"[latestVersion]"} to something else.`;En(Dn`Documents with a status of \`"${e.specStatus}"\` can't be published on the W3C's /TR/ (Technical Report) space.`,Wr,{hint:t})}}(e);const n=`${t}/${e.shortName}`;if(e.previousPublishDate){if(!e.previousMaturity&&!e.isTagFinding){En(Dn`${"[`previousPublishDate`]"} is set, but missing ${"[`previousMaturity`]"}.`,Wr)}e.previousPublishDate=is(e,"previousPublishDate");const r=Br[e.previousMaturity]??e.previousMaturity;if(e.isTagFinding&&e.latestVersion){const t=Gt.format(e.publishDate);e.thisVersion=Fr(`${n}-${t}`);const r=Gt.format(e.previousPublishDate);e.prevVersion=Fr(`${n}-${r}}`)}else if(e.isCGBG||e.isBasic)e.prevVersion=e.prevVersion||"";else{const n=e.previousPublishDate.getUTCFullYear(),{shortName:s}=e,i=cn(e.previousPublishDate);e.prevVersion=Fr(`${t}/${n}/${r}-${s}-${i}/`)}}e.prevRecShortname&&!e.prevRecURI&&(e.prevRecURI=Fr(`${t}/${e.prevRecShortname}`));for(let t=0;t<e.editors.length;t++){const n=e.editors[t];"retiredDate"in n&&(e.formerEditors.push(n),e.editors.splice(t--,1))}if(0===e.editors.length){const e=Dn`Add one or more editors using the ${"[editors]"} configuration option.`;En("At least one editor is required.",Wr,{hint:e})}else e.editors.length&&e.isRecTrack&&e.editors.forEach(((e,t)=>{if(e.w3cid)return;const n=Dn`See ${"[w3cid]"} for instructions for how to retrieve it and add it.`;En(Dn`Editor ${e.name?`"${e.name}"`:`number ${t+1}`} is missing their ${"[w3cid]"}.`,Wr,{hint:n})}));if(e.alternateFormats?.some((({uri:e,label:t})=>!e||!t))){En(Dn`Every ${"[`alternateFormats`]"} entry must have a \`uri\` and a \`label\`.`,Wr)}if(e.copyrightStart==e.publishYear&&(e.copyrightStart=""),e.isRec&&!e.errata&&!e.revisionTypes?.length){const e=Dn`Add an ${"[errata]"} URL to your ${"[respecConfig]"}.`;En("Recommendations must have an errata link.",Wr,{hint:e})}e.dashDate=Gt.format(e.publishDate),e.publishISODate=e.publishDate.toISOString(),e.shortISODate=Gt.format(e.publishDate),function(e){if(!e.wgPatentPolicy)return;const t=new Set([].concat(e.wgPatentPolicy));if(t.size&&![...t].every((e=>ss.includes(e)))){const e=Dn`Invalid ${"[wgPatentPolicy]"} value(s): ${Pn([...t].filter((e=>!ss.includes(e))))}.`,n=`Please use one of: ${Ln(ss)}.`;En(e,Wr,{hint:n})}if(1!==t.size){const e="When collaborating across multiple groups, they must use the same patent policy.",n=Dn`For ${"[wgPatentPolicy]"}, please check the patent policies of each group. The patent policies were: ${[...t].join(", ")}.`;En(e,Wr,{hint:n})}e.wgPatentPolicy=[...t][0]}(e),await async function(e){if(!e.shortName||null===e.historyURI||!e.latestVersion)return;const t=e.isEd||ts.includes(e.specStatus);if(e.historyURI&&!t){const t=Dn`Please remove ${"[historyURI]"}.`;return En(Dn`The ${"[historyURI]"} can't be used with non /TR/ documents.`,Wr,{hint:t}),void(e.historyURI=null)}const n=new URL(e.historyURI??`${e.shortName}/`,"https://www.w3.org/standards/history/");if(e.historyURI&&t||["FPWD","DNOTE","NOTE","DRY"].includes(e.specStatus))return void(e.historyURI=n.href);try{const t=await fetch(n,{method:"HEAD"});t.ok&&(e.historyURI=t.url)}catch{}}(e),e.isTagEditorFinding&&(delete e.thisVersion,delete e.latestVersion),e.isTagFinding&&(e.showPreviousVersion=!!e.previousPublishDate);const s={get multipleAlternates(){return e.alternateFormats&&e.alternateFormats.length>1},get alternatesHTML(){return e.alternateFormats&&pn(e.alternateFormats.map((({label:e})=>e)),((t,n)=>{const r=e.alternateFormats[n];return jt`<a
690
690
  rel="alternate"
691
691
  href="${r.uri}"
692
692
  hreflang="${r?.lang??null}"
693
693
  type="${r?.type??null}"
694
694
  >${r.label}</a
695
- >`}))}},i=(e.isCGBG?Ir:Lr)(e,s);document.body.prepend(i),document.body.classList.add("h-entry");const o=document.getElementById("sotd")||document.createElement("section");if((e.isCGBG||!e.isNoTrack||e.isTagFinding)&&!o.id){Rn("A Status of This Document must include at least on custom paragraph.",qr,{elements:[o],hint:"Add a `<p>` in the 'sotd' section that reflects the status of this specification."})}o.id=o.id||"sotd",o.classList.add("introductory");const a=[e.wg,e.wgURI,e.wgPatentURI];if(a.some((e=>Array.isArray(e)))&&!a.every((e=>Array.isArray(e)))){const e=In`Use the ${"[group]"} option with an array instead.`;Rn(In`If one of ${"[wg]"}, ${"[wgURI]"}, or ${"[wgPatentURI]"} is an array, they all have to be.`,qr,{hint:e})}if(Array.isArray(e.wg)?(e.multipleWGs=e.wg.length>1,e.wgPatentHTML=dn(e.wg,((t,n)=>Ot`a
695
+ >`}))}},i=(e.isCGBG?Dr:Pr)(e,s);document.body.prepend(i),document.body.classList.add("h-entry");const o=document.getElementById("sotd")||document.createElement("section");if((e.isCGBG||!e.isNoTrack||e.isTagFinding)&&!o.id){En("A Status of This Document must include at least on custom paragraph.",Wr,{elements:[o],hint:"Add a `<p>` in the 'sotd' section that reflects the status of this specification."})}o.id=o.id||"sotd",o.classList.add("introductory");const a=[e.wg,e.wgURI,e.wgPatentURI];if(a.some((e=>Array.isArray(e)))&&!a.every((e=>Array.isArray(e)))){const e=Dn`Use the ${"[group]"} option with an array instead.`;En(Dn`If one of ${"[wg]"}, ${"[wgURI]"}, or ${"[wgPatentURI]"} is an array, they all have to be.`,Wr,{hint:e})}if(Array.isArray(e.wg)?(e.multipleWGs=e.wg.length>1,e.wgPatentHTML=pn(e.wg,((t,n)=>jt`a
696
696
  <a href="${e.wgPatentURI[n]}" rel="disclosure"
697
697
  >public list of any patent disclosures (${t})</a
698
- >`))):e.multipleWGs=!1,e.isPR&&!e.crEnd){Rn(In`${"[specStatus]"} is "PR" but no ${"[crEnd]"} is specified in the ${"[respecConfig]"} (needed to indicate end of previous CR).`,qr)}if(e.isCR&&!e.crEnd){Rn(In`${"[specStatus]"} is "CR", but no ${"[crEnd]"} is specified in the ${"[respecConfig]"}.`,qr)}if(e.crEnd=ss(e,"crEnd"),e.isPr&&!e.prEnd){Rn(In`${"[specStatus]"} is "PR" but no ${"[prEnd]"} is specified in the ${"[respecConfig]"}.`,qr)}if(e.prEnd=ss(e,"prEnd"),e.isPER&&!e.perEnd){Rn(In`${"[specStatus]"} is "PER", but no ${"[perEnd]"} is specified.`,qr)}if(e.perEnd=ss(e,"perEnd"),e.hasOwnProperty("updateableRec")){const t=In`Add an ${"[`updateable-rec`|#updateable-rec-class]"} CSS class to the Status of This Document section instead.`;En("Configuration option `updateableRec` is deprecated.",qr,{hint:t}),e.updateableRec&&o.classList.add("updateable-rec")}e.updateableRec=o.classList.contains("updateable-rec");const c=["addition","correction","proposed-addition","proposed-correction"];if(e.isRec&&e.revisionTypes?.length>0){if(e.revisionTypes.some((e=>!c.includes(e)))){const t=In`${"[specStatus]"} is "REC" with unknown ${"[revisionTypes]"}: '${Tn(e.revisionTypes.filter((e=>!c.includes(e))))}'.`,n=In`The valid values for ${"[revisionTypes]"} are: ${Tn(c)}.`;Rn(t,qr,{hint:n})}if((e.revisionTypes.includes("proposed-addition")||e.revisionTypes.includes("addition"))&&!e.updateableRec){Rn(In`${"[specStatus]"} is "REC" with proposed additions but the Recommendation is not marked as allowing new features.`,qr)}}if("REC"===e.specStatus&&e.updateableRec&&e.revisionTypes&&e.revisionTypes.length>0&&["proposed-addition","proposed-correction"].some((t=>e.revisionTypes.includes(t)))&&!e.revisedRecEnd){Rn(In`${"[specStatus]"} is "REC" with proposed corrections or additions but no ${"[revisedRecEnd]"} is specified in the ${"[respecConfig]"}.`,qr)}if(e.revisedRecEnd=ss(e,"revisedRecEnd"),e.noRecTrack&&Yr.includes(e.specStatus)){const t=In`Document configured as ${"[noRecTrack]"}, but its status ("${e.specStatus}") puts it on the W3C Rec Track.`,n=Tn(Yr,{quotes:!0});Rn(t,qr,{hint:`Status **can't** be any of: ${n}.`})}if(o.classList.contains("override")||Ot.bind(o)`${function(e,t){const n={...is(t,e),get mailToWGPublicList(){return`mailto:${e.wgPublicList}@w3.org`},get mailToWGPublicListWithSubject(){const t=e.subjectPrefix?`?subject=${encodeURIComponent(e.subjectPrefix)}`:"";return this.mailToWGPublicList+t},get mailToWGPublicListSubscription(){return`mailto:${e.wgPublicList}-request@w3.org?subject=subscribe`}};return(e.isCGBG?Ur:jr)(e,n)}(e,o)}`,!e.implementationReportURI&&e.isCR){const e=In`CR documents must have an ${"[implementationReportURI]"} that describes the [implementation experience](https://www.w3.org/2019/Process-20190301/#implementation-experience).`;Rn(In`Missing ${"[implementationReportURI]"} configuration option in ${"[respecConfig]"}.`,qr,{hint:e})}if(!e.implementationReportURI&&e.isPR){En(In`PR documents should include an ${"[implementationReportURI]"}, which needs to link to a document that describes the [implementation experience](https://www.w3.org/2019/Process-20190301/#implementation-experience).`,qr)}r("amend-user-config",{publishISODate:e.publishISODate,generatedSubtitle:rn(document.getElementById("w3c-state")?.textContent??"")})},status2text:Br,status2track:Gr,tagStatus:Zr,trStatus:es});const as={lint:{"no-headingless-sections":!0,"no-http-props":!0,"no-unused-vars":!1,"check-punctuation":!1,"local-refs-exist":!0,"check-internal-slots":!1,"check-charset":!1,"privsec-section":!1},pluralize:!0,specStatus:"base",highlightVars:!0,addSectionLinks:!0},cs="w3c/defaults",ls={src:"https://www.w3.org/StyleSheets/TR/2021/logos/W3C",alt:"W3C",height:48,width:72,url:"https://www.w3.org/"},us={alt:"W3C Member Submission",href:"https://www.w3.org/Submission/",src:"https://www.w3.org/Icons/member_subm-v.svg",width:"211",height:"48"},ds={lint:{"privsec-section":!1,"required-sections":!0,"wpt-tests-exist":!1,"informative-dfn":"warn","no-unused-dfns":"warn",a11y:!1},doJsonLd:!1,logos:[],xref:!0,wgId:"",otherLinks:[],excludeGithubLinks:!0,subtitle:"",prevVersion:"",formerEditors:[],editors:[],authors:[]};var ps=Object.freeze({__proto__:null,name:cs,run:function(e){const t=!1!==e.lint&&{...as.lint,...ds.lint,...e.lint};Object.assign(e,{...as,...ds,...e,lint:t}),"unofficial"===e.specStatus||e.hasOwnProperty("license")||(e.license="w3c-software-doc"),function(e){const{specStatus:t,groupType:n,group:r}=e;if(!t){const t=In`Select an appropriate status from ${"[specStatus]"} based on your W3C group. If in doubt, use \`"unofficial"\`.`;return Rn(In`The ${"[specStatus]"} configuration option is required.`,cs,{hint:t}),void(e.specStatus="base")}if(void 0===Br[t]){const n=In`The ${"[specStatus]"} "\`${t}\`" is not supported at for this type of document.`,r=In`set ${"[specStatus]"} to one of: ${Tn(Object.keys(Br),{quotes:!0})}.`;return Rn(n,cs,{hint:r}),void(e.specStatus="base")}switch(n){case"cg":if(![...Jr,"unofficial","UD"].includes(t)){const n=In`W3C Community Group documents can't use \`"${t}"\` for the ${"[specStatus]"} configuration option.`,r=Tn(Jr,{quotes:!0});Rn(n,cs,{hint:`Please use one of: ${r}. Automatically falling back to \`"CG-DRAFT"\`.`}),e.specStatus="CG-DRAFT"}break;case"bg":if(![...Xr,"unofficial","UD"].includes(t)){const n=In`W3C Business Group documents can't use \`"${t}"\` for the ${"[specStatus]"} configuration option.`,r=Tn(Xr,{quotes:!0});Rn(n,cs,{hint:`Please use one of: ${r}. Automatically falling back to \`"BG-DRAFT"\`.`}),e.specStatus="BG-DRAFT"}break;case"wg":if(![...es,"unofficial","UD","ED"].includes(t)){const e=In`Pleas see ${"[specStatus]"} for appropriate status for W3C Working Group documents.`;Rn(In`W3C Working Group documents can't use \`"${t}"\` for the ${"[specStatus]"} configuration option.`,cs,{hint:e})}break;case"other":if("tag"===r&&!["ED",...es,...Zr].includes(t)){const n=In`The W3C Technical Architecture Group's documents can't use \`"${t}"\` for the ${"[specStatus]"} configuration option.`,r=Tn(["ED",...es,...Zr],{quotes:!0});Rn(n,cs,{hint:`Please use one of: ${r}. Automatically falling back to \`"unofficial"\`.`}),e.specStatus="unofficial"}break;default:if(!e.wgId&&!["unofficial","base","UD","Member-SUBM"].includes(e.specStatus)){const t="Document is not associated with a [W3C group](https://respec.org/w3c/groups/). Defaulting to 'base' status.",n=In`Use the ${"[group]"} configuration option to associated this document with a W3C group.`;e.specStatus="base",Rn(t,cs,{hint:n})}}}(e),function(e){const{specStatus:t,wg:n}=e,r=[...Yr,...Kr,...Vr,...Zr,"ED"].includes(t),s=n&&n.length&&r,i=["Member-SUBM"].includes(t);(s||i)&&(e.logos.unshift(ls),"Member-SUBM"===t&&e.logos.push(us))}(e)}});var fs=String.raw`@keyframes pop{
698
+ >`))):e.multipleWGs=!1,e.isPR&&!e.crEnd){En(Dn`${"[specStatus]"} is "PR" but no ${"[crEnd]"} is specified in the ${"[respecConfig]"} (needed to indicate end of previous CR).`,Wr)}if(e.isCR&&!e.crEnd){En(Dn`${"[specStatus]"} is "CR", but no ${"[crEnd]"} is specified in the ${"[respecConfig]"}.`,Wr)}if(e.crEnd=is(e,"crEnd"),e.isPr&&!e.prEnd){En(Dn`${"[specStatus]"} is "PR" but no ${"[prEnd]"} is specified in the ${"[respecConfig]"}.`,Wr)}if(e.prEnd=is(e,"prEnd"),e.isPER&&!e.perEnd){En(Dn`${"[specStatus]"} is "PER", but no ${"[perEnd]"} is specified.`,Wr)}if(e.perEnd=is(e,"perEnd"),e.hasOwnProperty("updateableRec")){const t=Dn`Add an ${"[`updateable-rec`|#updateable-rec-class]"} CSS class to the Status of This Document section instead.`;An("Configuration option `updateableRec` is deprecated.",Wr,{hint:t}),e.updateableRec&&o.classList.add("updateable-rec")}e.updateableRec=o.classList.contains("updateable-rec");const c=["addition","correction","proposed-addition","proposed-correction"];if(e.isRec&&e.revisionTypes?.length>0){if(e.revisionTypes.some((e=>!c.includes(e)))){const t=Dn`${"[specStatus]"} is "REC" with unknown ${"[revisionTypes]"}: '${Ln(e.revisionTypes.filter((e=>!c.includes(e))))}'.`,n=Dn`The valid values for ${"[revisionTypes]"} are: ${Ln(c)}.`;En(t,Wr,{hint:n})}if((e.revisionTypes.includes("proposed-addition")||e.revisionTypes.includes("addition"))&&!e.updateableRec){En(Dn`${"[specStatus]"} is "REC" with proposed additions but the Recommendation is not marked as allowing new features.`,Wr)}}if("REC"===e.specStatus&&e.updateableRec&&e.revisionTypes&&e.revisionTypes.length>0&&["proposed-addition","proposed-correction"].some((t=>e.revisionTypes.includes(t)))&&!e.revisedRecEnd){En(Dn`${"[specStatus]"} is "REC" with proposed corrections or additions but no ${"[revisedRecEnd]"} is specified in the ${"[respecConfig]"}.`,Wr)}if(e.revisedRecEnd=is(e,"revisedRecEnd"),e.noRecTrack&&Kr.includes(e.specStatus)){const t=Dn`Document configured as ${"[noRecTrack]"}, but its status ("${e.specStatus}") puts it on the W3C Rec Track.`,n=Ln(Kr,{quotes:!0});En(t,Wr,{hint:`Status **can't** be any of: ${n}.`})}if(o.classList.contains("override")||jt.bind(o)`${function(e,t){const n={...os(t,e),get mailToWGPublicList(){return`mailto:${e.wgPublicList}@w3.org`},get mailToWGPublicListWithSubject(){const t=e.subjectPrefix?`?subject=${encodeURIComponent(e.subjectPrefix)}`:"";return this.mailToWGPublicList+t},get mailToWGPublicListSubscription(){return`mailto:${e.wgPublicList}-request@w3.org?subject=subscribe`}};return(e.isCGBG?qr:Mr)(e,n)}(e,o)}`,!e.implementationReportURI&&e.isCR){const e=Dn`CR documents must have an ${"[implementationReportURI]"} that describes the [implementation experience](https://www.w3.org/2019/Process-20190301/#implementation-experience).`;En(Dn`Missing ${"[implementationReportURI]"} configuration option in ${"[respecConfig]"}.`,Wr,{hint:e})}if(!e.implementationReportURI&&e.isPR){An(Dn`PR documents should include an ${"[implementationReportURI]"}, which needs to link to a document that describes the [implementation experience](https://www.w3.org/2019/Process-20190301/#implementation-experience).`,Wr)}r("amend-user-config",{publishISODate:e.publishISODate,generatedSubtitle:sn(document.getElementById("w3c-state")?.textContent??"")})},status2text:Hr,status2track:Vr,tagStatus:Jr,trStatus:ts});const cs={lint:{"no-headingless-sections":!0,"no-http-props":!0,"no-unused-vars":!1,"check-punctuation":!1,"local-refs-exist":!0,"check-internal-slots":!1,"check-charset":!1,"privsec-section":!1},pluralize:!0,specStatus:"base",highlightVars:!0,addSectionLinks:!0},ls="w3c/defaults",us={src:"https://www.w3.org/StyleSheets/TR/2021/logos/W3C",alt:"W3C",height:48,width:72,url:"https://www.w3.org/"},ds={alt:"W3C Member Submission",href:"https://www.w3.org/Submission/",src:"https://www.w3.org/Icons/member_subm-v.svg",width:"211",height:"48"},ps={lint:{"privsec-section":!1,"required-sections":!0,"wpt-tests-exist":!1,"informative-dfn":"warn","no-unused-dfns":"warn",a11y:!1},doJsonLd:!1,logos:[],xref:!0,wgId:"",otherLinks:[],excludeGithubLinks:!0,subtitle:"",prevVersion:"",formerEditors:[],editors:[],authors:[]};var fs=Object.freeze({__proto__:null,name:ls,run:function(e){const t=!1!==e.lint&&{...cs.lint,...ps.lint,...e.lint};Object.assign(e,{...cs,...ps,...e,lint:t}),"unofficial"===e.specStatus||e.hasOwnProperty("license")||(e.license="w3c-software-doc"),function(e){const{specStatus:t,groupType:n,group:r}=e;if(!t){const t=Dn`Select an appropriate status from ${"[specStatus]"} based on your W3C group. If in doubt, use \`"unofficial"\`.`;return En(Dn`The ${"[specStatus]"} configuration option is required.`,ls,{hint:t}),void(e.specStatus="base")}if(void 0===Hr[t]){const n=Dn`The ${"[specStatus]"} "\`${t}\`" is not supported at for this type of document.`,r=Dn`set ${"[specStatus]"} to one of: ${Ln(Object.keys(Hr),{quotes:!0})}.`;return En(n,ls,{hint:r}),void(e.specStatus="base")}switch(n){case"cg":if(![...Xr,"unofficial","UD"].includes(t)){const n=Dn`W3C Community Group documents can't use \`"${t}"\` for the ${"[specStatus]"} configuration option.`,r=Ln(Xr,{quotes:!0});En(n,ls,{hint:`Please use one of: ${r}. Automatically falling back to \`"CG-DRAFT"\`.`}),e.specStatus="CG-DRAFT"}break;case"bg":if(![...Qr,"unofficial","UD"].includes(t)){const n=Dn`W3C Business Group documents can't use \`"${t}"\` for the ${"[specStatus]"} configuration option.`,r=Ln(Qr,{quotes:!0});En(n,ls,{hint:`Please use one of: ${r}. Automatically falling back to \`"BG-DRAFT"\`.`}),e.specStatus="BG-DRAFT"}break;case"wg":if(![...ts,"unofficial","UD","ED"].includes(t)){const e=Dn`Pleas see ${"[specStatus]"} for appropriate status for W3C Working Group documents.`;En(Dn`W3C Working Group documents can't use \`"${t}"\` for the ${"[specStatus]"} configuration option.`,ls,{hint:e})}break;case"other":if("tag"===r&&!["ED",...ts,...Jr].includes(t)){const n=Dn`The W3C Technical Architecture Group's documents can't use \`"${t}"\` for the ${"[specStatus]"} configuration option.`,r=Ln(["ED",...ts,...Jr],{quotes:!0});En(n,ls,{hint:`Please use one of: ${r}. Automatically falling back to \`"unofficial"\`.`}),e.specStatus="unofficial"}break;default:if(!e.wgId&&!["unofficial","base","UD","Member-SUBM"].includes(e.specStatus)){const t="Document is not associated with a [W3C group](https://respec.org/w3c/groups/). Defaulting to 'base' status.",n=Dn`Use the ${"[group]"} configuration option to associated this document with a W3C group.`;e.specStatus="base",En(t,ls,{hint:n})}}}(e),function(e){const{specStatus:t,wg:n}=e,r=[...Kr,...Zr,...Yr,...Jr,"ED"].includes(t),s=n&&n.length&&r,i=["Member-SUBM"].includes(t);(s||i)&&(e.logos.unshift(us),"Member-SUBM"===t&&e.logos.push(ds))}(e)}});var hs=String.raw`@keyframes pop{
699
699
  0%{transform:scale(1,1)}
700
700
  25%{transform:scale(1.25,1.25);opacity:.75}
701
701
  100%{transform:scale(1,1)}
@@ -750,71 +750,71 @@ dd{margin-left:0}
750
750
  }
751
751
  @media print{
752
752
  .removeOnSave{display:none}
753
- }`;const hs=function(){const e=document.createElement("style");return e.id="respec-mainstyle",e.textContent=fs,document.head.appendChild(e),e}();var ms=Object.freeze({__proto__:null,name:"core/style",run:function(e){e.noReSpecCSS&&hs.remove()}});function gs(){const e=Ot`<script src="https://www.w3.org/scripts/TR/2021/fixup.js">`;location.hash&&e.addEventListener("load",(()=>{window.location.href=location.hash}),{once:!0}),document.body.appendChild(e)}const bs=function(){const e=[{hint:"preconnect",href:"https://www.w3.org"},{hint:"preload",href:"https://www.w3.org/scripts/TR/2021/fixup.js",as:"script"},{hint:"preload",href:"https://www.w3.org/StyleSheets/TR/2021/base.css",as:"style"},{hint:"preload",href:"https://www.w3.org/StyleSheets/TR/2021/logos/W3C",as:"image",corsMode:"anonymous"}],t=document.createDocumentFragment();for(const n of e.map(Kt))t.appendChild(n);return t}();bs.appendChild(Ot`<link
754
- rel="stylesheet"
755
- href="https://www.w3.org/StyleSheets/TR/2021/base.css"
756
- class="removeOnSave"
757
- />`),document.head.querySelector("meta[name=viewport]")||bs.prepend(Ot`<meta
753
+ }`;const ms=function(){const e=document.createElement("style");return e.id="respec-mainstyle",e.textContent=hs,document.head.appendChild(e),e}();var gs=Object.freeze({__proto__:null,name:"core/style",run:function(e){e.noReSpecCSS&&ms.remove()}});function bs(){const e=jt`<script src="https://www.w3.org/scripts/TR/2021/fixup.js">`;location.hash&&e.addEventListener("load",(()=>{window.location.href=location.hash}),{once:!0}),document.body.appendChild(e)}const ys=function(){const e=[{hint:"preconnect",href:"https://www.w3.org"},{hint:"preload",href:"https://www.w3.org/scripts/TR/2021/fixup.js",as:"script"},{hint:"preload",href:"https://www.w3.org/StyleSheets/TR/2021/base.css",as:"style"},{hint:"preload",href:"https://www.w3.org/StyleSheets/TR/2021/logos/W3C",as:"image",corsMode:"anonymous"}],t=document.createDocumentFragment();for(const n of e.map(Zt))t.appendChild(n);return t}();ys.appendChild(jt`<link
754
+ rel="stylesheet"
755
+ href="https://www.w3.org/StyleSheets/TR/2021/base.css"
756
+ class="removeOnSave"
757
+ />`),document.head.querySelector("meta[name=viewport]")||ys.prepend(jt`<meta
758
758
  name="viewport"
759
759
  content="width=device-width, initial-scale=1, shrink-to-fit=no"
760
- />`),document.head.prepend(bs);var ys=Object.freeze({__proto__:null,name:"w3c/style",run:function(e){const t=e.specStatus?.toUpperCase()??"";let n="";const r=[...Yr,...Kr,...Vr,"ED","MEMBER-SUBM"].includes(t)&&e.wgId;switch(t){case"WD":case"FPWD":n=r?"W3C-WD":"base.css";break;case"CG-DRAFT":case"CG-FINAL":case"BG-DRAFT":case"BG-FINAL":n=t.toLowerCase();break;case"UD":case"UNOFFICIAL":n="W3C-UD";break;case"FINDING":case"DRAFT-FINDING":case"EDITOR-DRAFT-FINDING":case"BASE":n="base.css";break;case"MEMBER-SUBM":n="W3C-Member-SUBM";break;default:n=r?`W3C-${e.specStatus}`:"base.css"}e.noToc||s("end-all",gs,{once:!0});const i=new URL(`/StyleSheets/TR/2021/${n}`,"https://www.w3.org/");var o;!function(e,t){const n=[].concat(t).map((t=>{const n=e.createElement("link");return n.rel="stylesheet",n.href=t,n})).reduce(((e,t)=>(e.appendChild(t),e)),e.createDocumentFragment());e.head.appendChild(n)}(document,i.href),s("beforesave",(o=i,e=>{const t=e.querySelector(`head link[href="${o}"]`);e.querySelector("head").append(t)}))}});const ws="core/github";let vs,$s;const ks=new Promise(((e,t)=>{vs=e,$s=e=>{Rn(e,ws),t(new Error(e))}})),xs=sn({en:{file_a_bug:"File an issue",participate:"Participate:",commit_history:"Commit history"},ko:{participate:"참여"},zh:{file_a_bug:"反馈错误",participate:"参与:"},ja:{commit_history:"変更履歴",file_a_bug:"問題報告",participate:"参加方法:"},nl:{commit_history:"Revisiehistorie",file_a_bug:"Dien een melding in",participate:"Doe mee:"},es:{commit_history:"Historia de cambios",file_a_bug:"Nota un bug",participate:"Participe:"},de:{commit_history:"Revisionen",file_a_bug:"Fehler melden",participate:"Mitmachen:"}});var _s=Object.freeze({__proto__:null,github:ks,name:ws,run:async function(e){if(!e.hasOwnProperty("github")||!e.github)return void vs(null);if("object"==typeof e.github&&!e.github.hasOwnProperty("repoURL")){const e=In`Config option ${"[github]"} is missing property \`repoURL\`.`;return void $s(e)}let t,n=e.github.repoURL||e.github;n.endsWith("/")||(n+="/");try{t=new URL(n,"https://github.com")}catch{const e=In`${"[github]"} configuration option is not a valid URL? (${n}).`;return void $s(e)}if("https://github.com"!==t.origin){const e=In`${"[github]"} configuration option must be HTTPS and pointing to GitHub. (${t.href}).`;return void $s(e)}const[r,s]=t.pathname.split("/").filter((e=>e));if(!r||!s){const e=In`${"[github]"} URL needs a path. For example, "w3c/my-spec".`;return void $s(e)}const i=e.github.branch||"gh-pages",o=new URL("./issues/",t).href,a=new URL(`./commits/${e.github.branch??""}`,t.href),c={edDraftURI:`https://${r.toLowerCase()}.github.io/${s}/`,githubToken:void 0,githubUser:void 0,issueBase:o,atRiskBase:o,otherLinks:[],pullBase:new URL("./pulls/",t).href,shortName:s};let l="https://respec.org/github";if(e.githubAPI)if(new URL(e.githubAPI).hostname===window.parent.location.hostname)l=e.githubAPI;else{En("The `githubAPI` configuration option is private and should not be added manually.",ws)}if(!e.excludeGithubLinks){const n={key:xs.participate,data:[{value:`GitHub ${r}/${s}`,href:t},{value:xs.file_a_bug,href:c.issueBase},{value:xs.commit_history,href:a.href},{value:"Pull requests",href:c.pullBase}]};e.otherLinks||(e.otherLinks=[]),e.otherLinks.unshift(n)}const u={branch:i,repoURL:t.href,apiBase:l,fullName:`${r}/${s}`,issuesURL:o,pullsURL:c.pullBase,newIssuesURL:new URL("./new/choose",o).href,commitHistoryURL:a.href};vs(u);const d={...c,...e,github:u,githubAPI:l};Object.assign(e,d)}});class Cs{constructor(e){this.doc=e,this.root=e.createDocumentFragment(),this.stack=[this.root],this.current=this.root}findPosition(e){return parseInt(e.tagName.charAt(1),10)}findParent(e){let t;for(;e>0;)if(e--,t=this.stack[e],t)return t}findHeader({firstChild:e}){for(;e;){if(/H[1-6]/.test(e.tagName))return e;e=e.nextSibling}return null}addHeader(e){const t=this.doc.createElement("section"),n=this.findPosition(e);t.appendChild(e),this.findParent(n).appendChild(t),this.stack[n]=t,this.stack.length=n+1,this.current=t}addSection(e){const t=this.findHeader(e),n=t?this.findPosition(t):1,r=this.findParent(n);t&&e.removeChild(t),e.appendChild(Ss(e)),t&&e.prepend(t),r.appendChild(e),this.current=r}addElement(e){this.current.appendChild(e)}}function Ss(e){const t=new Cs(e.ownerDocument);for(;e.firstChild;){const n=e.firstChild;switch(n.localName){case"h1":case"h2":case"h3":case"h4":case"h5":case"h6":t.addHeader(n);break;case"section":t.addSection(n);break;default:t.addElement(n)}}return t.root}function Rs(e){const t=Ss(e);if("section"===t.firstElementChild.localName&&"section"===e.localName){const n=t.firstElementChild;n.remove(),e.append(...n.childNodes)}else e.textContent="";e.appendChild(t)}var Es=Object.freeze({__proto__:null,name:"core/sections",restructure:Rs,run:function(){Rs(document.body)}});const As="core/data-include";function Ts(e,t,n){const r=document.querySelector(`[data-include-id=${t}]`),s=cn(e,r.dataset.oninclude,n),i="string"==typeof r.dataset.includeReplace;!function(e,t,{replace:n}){const{includeFormat:r}=e.dataset;let s=t;"markdown"===r&&(s=Vn(s)),"text"===r?e.textContent=s:e.innerHTML=s,"markdown"===r&&Rs(e),n&&e.replaceWith(...e.childNodes)}(r,s,{replace:i}),i||function(e){["data-include","data-include-format","data-include-replace","data-include-id","oninclude"].forEach((t=>e.removeAttribute(t)))}(r)}async function Ls(e,t){const n=e.querySelectorAll("[data-include]"),r=Array.from(n).map((async e=>{const n=e.dataset.include;if(!n)return;const r=`include-${String(Math.random()).slice(2)}`;e.dataset.includeId=r;try{const s=await fetch(n);Ts(await s.text(),r,n),t<3&&await Ls(e,t+1)}catch(t){const r=`\`data-include\` failed: \`${n}\` (${t.message}).`;console.error(r,e,t),Rn(r,As,{elements:[e]})}}));await Promise.all(r)}var Ps=Object.freeze({__proto__:null,name:As,run:async function(){await Ls(document,1)}});const Is="core/title",Ds=sn({en:{default_title:"No Title"},de:{default_title:"Kein Titel"},zh:{default_title:"无标题"}});var Ns=Object.freeze({__proto__:null,name:Is,run:function(e){const t=document.querySelector("h1#title")||Ot`<h1 id="title"></h1>`;if(t.isConnected&&""===t.textContent.trim()){Rn('The document is missing a title, so using a default title. To fix this, please give your document a `<title>`. If you need special markup in the document\'s title, please use a `<h1 id="title">`.',Is,{title:"Document is missing a title",elements:[t]})}t.id||(t.id="title"),t.classList.add("title"),function(e,t){t.isConnected||(t.textContent=document.title||`${Ds.default_title}`);const n=document.createElement("h1");n.innerHTML=t.innerHTML.replace(/:<br>/g,": ").replace(/<br>/g," - ");let r=rn(n.textContent);if(e.isPreview&&e.prNumber){const n=e.prUrl||`${e.github.repoURL}pull/${e.prNumber}`,{childNodes:s}=Ot`
760
+ />`),document.head.prepend(ys);var ws=Object.freeze({__proto__:null,name:"w3c/style",run:function(e){const t=e.specStatus?.toUpperCase()??"";let n="";const r=[...Kr,...Zr,...Yr,"ED","MEMBER-SUBM"].includes(t)&&e.wgId;switch(t){case"WD":case"FPWD":n=r?"W3C-WD":"base.css";break;case"CG-DRAFT":case"CG-FINAL":case"BG-DRAFT":case"BG-FINAL":n=t.toLowerCase();break;case"UD":case"UNOFFICIAL":n="W3C-UD";break;case"FINDING":case"DRAFT-FINDING":case"EDITOR-DRAFT-FINDING":case"BASE":n="base.css";break;case"MEMBER-SUBM":n="W3C-Member-SUBM";break;default:n=r?`W3C-${e.specStatus}`:"base.css"}e.noToc||s("end-all",bs,{once:!0});const i=new URL(`/StyleSheets/TR/2021/${n}`,"https://www.w3.org/");var o;!function(e,t){const n=[].concat(t).map((t=>{const n=e.createElement("link");return n.rel="stylesheet",n.href=t,n})).reduce(((e,t)=>(e.appendChild(t),e)),e.createDocumentFragment());e.head.appendChild(n)}(document,i.href),s("beforesave",(o=i,e=>{const t=e.querySelector(`head link[href="${o}"]`);e.querySelector("head").append(t)}))}});const vs="core/github";let $s,ks;const xs=new Promise(((e,t)=>{$s=e,ks=e=>{En(e,vs),t(new Error(e))}})),_s=on({en:{file_a_bug:"File an issue",participate:"Participate:",commit_history:"Commit history"},ko:{participate:"참여"},zh:{file_a_bug:"反馈错误",participate:"参与:"},ja:{commit_history:"変更履歴",file_a_bug:"問題報告",participate:"参加方法:"},nl:{commit_history:"Revisiehistorie",file_a_bug:"Dien een melding in",participate:"Doe mee:"},es:{commit_history:"Historia de cambios",file_a_bug:"Nota un bug",participate:"Participe:"},de:{commit_history:"Revisionen",file_a_bug:"Fehler melden",participate:"Mitmachen:"}});var Ss=Object.freeze({__proto__:null,github:xs,name:vs,run:async function(e){if(!e.hasOwnProperty("github")||!e.github)return void $s(null);if("object"==typeof e.github&&!e.github.hasOwnProperty("repoURL")){const e=Dn`Config option ${"[github]"} is missing property \`repoURL\`.`;return void ks(e)}let t,n=e.github.repoURL||e.github;n.endsWith("/")||(n+="/");try{t=new URL(n,"https://github.com")}catch{const e=Dn`${"[github]"} configuration option is not a valid URL? (${n}).`;return void ks(e)}if("https://github.com"!==t.origin){const e=Dn`${"[github]"} configuration option must be HTTPS and pointing to GitHub. (${t.href}).`;return void ks(e)}const[r,s]=t.pathname.split("/").filter((e=>e));if(!r||!s){const e=Dn`${"[github]"} URL needs a path. For example, "w3c/my-spec".`;return void ks(e)}const i=e.github.branch||"gh-pages",o=new URL("./issues/",t).href,a=new URL(`./commits/${e.github.branch??""}`,t.href),c={edDraftURI:`https://${r.toLowerCase()}.github.io/${s}/`,githubToken:void 0,githubUser:void 0,issueBase:o,atRiskBase:o,otherLinks:[],pullBase:new URL("./pulls/",t).href,shortName:s};let l="https://respec.org/github";if(e.githubAPI)if(new URL(e.githubAPI).hostname===window.parent.location.hostname)l=e.githubAPI;else{An("The `githubAPI` configuration option is private and should not be added manually.",vs)}if(!e.excludeGithubLinks){const n={key:_s.participate,data:[{value:`GitHub ${r}/${s}`,href:t},{value:_s.file_a_bug,href:c.issueBase},{value:_s.commit_history,href:a.href},{value:"Pull requests",href:c.pullBase}]};e.otherLinks||(e.otherLinks=[]),e.otherLinks.unshift(n)}const u={branch:i,repoURL:t.href,apiBase:l,fullName:`${r}/${s}`,issuesURL:o,pullsURL:c.pullBase,newIssuesURL:new URL("./new/choose",o).href,commitHistoryURL:a.href};$s(u);const d={...c,...e,github:u,githubAPI:l};Object.assign(e,d)}});class Cs{constructor(e){this.doc=e,this.root=e.createDocumentFragment(),this.stack=[this.root],this.current=this.root}findPosition(e){return parseInt(e.tagName.charAt(1),10)}findParent(e){let t;for(;e>0;)if(e--,t=this.stack[e],t)return t}findHeader({firstChild:e}){for(;e;){if(/H[1-6]/.test(e.tagName))return e;e=e.nextSibling}return null}addHeader(e){const t=this.doc.createElement("section"),n=this.findPosition(e);t.appendChild(e),this.findParent(n).appendChild(t),this.stack[n]=t,this.stack.length=n+1,this.current=t}addSection(e){const t=this.findHeader(e),n=t?this.findPosition(t):1,r=this.findParent(n);t&&e.removeChild(t),e.appendChild(Rs(e)),t&&e.prepend(t),r.appendChild(e),this.current=r}addElement(e){this.current.appendChild(e)}}function Rs(e){const t=new Cs(e.ownerDocument);for(;e.firstChild;){const n=e.firstChild;switch(n.localName){case"h1":case"h2":case"h3":case"h4":case"h5":case"h6":t.addHeader(n);break;case"section":t.addSection(n);break;default:t.addElement(n)}}return t.root}function Es(e){const t=Rs(e);if("section"===t.firstElementChild.localName&&"section"===e.localName){const n=t.firstElementChild;n.remove(),e.append(...n.childNodes)}else e.textContent="";e.appendChild(t)}var As=Object.freeze({__proto__:null,name:"core/sections",restructure:Es,run:function(){Es(document.body)}});const Ts="core/data-include";function Ls(e,t,n){const r=document.querySelector(`[data-include-id=${t}]`),s=ln(e,r.dataset.oninclude,n),i="string"==typeof r.dataset.includeReplace;!function(e,t,{replace:n}){const{includeFormat:r}=e.dataset;let s=t;"markdown"===r&&(s=Yn(s)),"text"===r?e.textContent=s:e.innerHTML=s,"markdown"===r&&Es(e),n&&e.replaceWith(...e.childNodes)}(r,s,{replace:i}),i||function(e){["data-include","data-include-format","data-include-replace","data-include-id","oninclude"].forEach((t=>e.removeAttribute(t)))}(r)}async function Ps(e,t){const n=e.querySelectorAll("[data-include]"),r=Array.from(n).map((async e=>{const n=e.dataset.include;if(!n)return;const r=`include-${String(Math.random()).slice(2)}`;e.dataset.includeId=r;try{const s=await fetch(n);Ls(await s.text(),r,n),t<3&&await Ps(e,t+1)}catch(t){const r=`\`data-include\` failed: \`${n}\` (${t.message}).`;console.error(r,e,t),En(r,Ts,{elements:[e]})}}));await Promise.all(r)}var Is=Object.freeze({__proto__:null,name:Ts,run:async function(){await Ps(document,1)}});const Ds="core/title",Ns=on({en:{default_title:"No Title"},de:{default_title:"Kein Titel"},zh:{default_title:"无标题"}});var Os=Object.freeze({__proto__:null,name:Ds,run:function(e){const t=document.querySelector("h1#title")||jt`<h1 id="title"></h1>`;if(t.isConnected&&""===t.textContent.trim()){En('The document is missing a title, so using a default title. To fix this, please give your document a `<title>`. If you need special markup in the document\'s title, please use a `<h1 id="title">`.',Ds,{title:"Document is missing a title",elements:[t]})}t.id||(t.id="title"),t.classList.add("title"),function(e,t){t.isConnected||(t.textContent=document.title||`${Ns.default_title}`);const n=document.createElement("h1");n.innerHTML=t.innerHTML.replace(/:<br>/g,": ").replace(/<br>/g," - ");let r=sn(n.textContent);if(e.isPreview&&e.prNumber){const n=e.prUrl||`${e.github.repoURL}pull/${e.prNumber}`,{childNodes:s}=jt`
761
761
  Preview of PR <a href="${n}">#${e.prNumber}</a>:
762
- `;t.prepend(...s),r=`Preview of PR #${e.prNumber}: ${r}`}document.title=r,e.title=r}(e,t),document.body.prepend(t)}});const Os="w3c/level",js=sn({en:{level:"Level"}});var Ms=Object.freeze({__proto__:null,name:Os,run:function(e){if(!e.hasOwnProperty("level"))return;const t=document.querySelector("h1#title"),n=parseInt(e.level);if(!Number.isInteger(n)||n<0){Rn(`The \`level\` configuration option must be a number greater or equal to 0. It is currently set to \`${n}\``,Os,{title:"Invalid level config.",elements:[t]})}else t.append(` ${js.level} ${n}`),document.title=`${document.title} ${js.level} ${n}`,e.shortName=`${e.shortName}-${n}`,e.level=n}});const zs="w3c/abstract",Us=sn({en:{abstract:"Abstract"},ko:{abstract:"요약"},zh:{abstract:"摘要"},ja:{abstract:"要約"},nl:{abstract:"Samenvatting"},es:{abstract:"Resumen"},de:{abstract:"Zusammenfassung"}});var qs=Object.freeze({__proto__:null,name:zs,run:async function(){const e=function(){const e=document.querySelector("#abstract");if(e)switch(e.localName){case"section":return e;case"div":return mn(e,"section");default:return Rn("The abstract should be a `<section>` element.",zs,{elements:[e]}),e}const t=Us.abstract.toLowerCase();for(const e of document.querySelectorAll("h2, h3, h4, h5, h6")){if(rn(e.textContent).toLowerCase()===t)return e.closest("section")}return null}();if(e)e.classList.add("introductory"),e.id="abstract",e.querySelector("h2")||e.prepend(Ot`<h2>${Us.abstract}</h2>`);else{Rn('Document must have one `<section id="abstract">`.',zs)}}});var Ws=Object.freeze({__proto__:null,name:"core/data-transform",run:function(){document.querySelectorAll("[data-transform]").forEach((e=>{e.innerHTML=cn(e.innerHTML,e.dataset.transform),e.removeAttribute("data-transform")}))}});const Fs="core/dfn-abbr";function Bs(e){const t=(n=e).dataset.abbr?n.dataset.abbr:n.textContent.match(/\b([a-z])/gi).join("").toUpperCase();var n;const r=e.textContent.replace(/\s\s+/g," ").trim();e.insertAdjacentHTML("afterend",` (<abbr title="${r}">${t}</abbr>)`);const s=e.dataset.lt||"";e.dataset.lt=s.split("|").filter((e=>e.trim())).concat(t).join("|")}var Hs=Object.freeze({__proto__:null,name:Fs,run:function(){const e=document.querySelectorAll("[data-abbr]");for(const t of e){const{localName:e}=t;if("dfn"===e)Bs(t);else{Rn(`\`data-abbr\` attribute not supported on \`${e}\` elements.`,Fs,{elements:[t],title:"Error: unsupported."})}}}});const Gs=/^[a-z]+(\s+[a-z]+)+\??$/,Vs=/\B"([^"]*)"\B/,Ys=/^(\w+)\(([^\\)]*)\)(?:\|(\w+)(?:\((?:([^\\)]*))\))?)?$/,Ks=/\[\[(\w+(?: +\w+)*)\]\](\([^)]*\))?$/,Zs=/^((?:\[\[)?(?:\w+(?: +\w+)*)(?:\]\])?)$/,Js=/^(?:\w+)\??$/,Xs=/^(\w+)\["([\w- ]*)"\]$/,Qs=/\.?(\w+\(.*\)$)/,ei=/\/(.+)/,ti=/\[\[.+\]\]/;function ni(e){const{identifier:t,renderParent:n,nullable:r}=e;if(n)return Ot`<a
762
+ `;t.prepend(...s),r=`Preview of PR #${e.prNumber}: ${r}`}document.title=r,e.title=r}(e,t),document.body.prepend(t)}});const js="w3c/level",Ms=on({en:{level:"Level"}});var zs=Object.freeze({__proto__:null,name:js,run:function(e){if(!e.hasOwnProperty("level"))return;const t=document.querySelector("h1#title"),n=parseInt(e.level);if(!Number.isInteger(n)||n<0){En(`The \`level\` configuration option must be a number greater or equal to 0. It is currently set to \`${n}\``,js,{title:"Invalid level config.",elements:[t]})}else t.append(` ${Ms.level} ${n}`),document.title=`${document.title} ${Ms.level} ${n}`,e.shortName=`${e.shortName}-${n}`,e.level=n}});const Us="w3c/abstract",qs=on({en:{abstract:"Abstract"},ko:{abstract:"요약"},zh:{abstract:"摘要"},ja:{abstract:"要約"},nl:{abstract:"Samenvatting"},es:{abstract:"Resumen"},de:{abstract:"Zusammenfassung"}});var Ws=Object.freeze({__proto__:null,name:Us,run:async function(){const e=function(){const e=document.querySelector("#abstract");if(e)switch(e.localName){case"section":return e;case"div":return gn(e,"section");default:return En("The abstract should be a `<section>` element.",Us,{elements:[e]}),e}const t=qs.abstract.toLowerCase();for(const e of document.querySelectorAll("h2, h3, h4, h5, h6")){if(sn(e.textContent).toLowerCase()===t)return e.closest("section")}return null}();if(e)e.classList.add("introductory"),e.id="abstract",e.querySelector("h2")||e.prepend(jt`<h2>${qs.abstract}</h2>`);else{En('Document must have one `<section id="abstract">`.',Us)}}});var Fs=Object.freeze({__proto__:null,name:"core/data-transform",run:function(){document.querySelectorAll("[data-transform]").forEach((e=>{e.innerHTML=ln(e.innerHTML,e.dataset.transform),e.removeAttribute("data-transform")}))}});const Bs="core/dfn-abbr";function Hs(e){const t=(n=e).dataset.abbr?n.dataset.abbr:n.textContent.match(/\b([a-z])/gi).join("").toUpperCase();var n;const r=e.textContent.replace(/\s\s+/g," ").trim();e.insertAdjacentHTML("afterend",` (<abbr title="${r}">${t}</abbr>)`);const s=e.dataset.lt||"";e.dataset.lt=s.split("|").filter((e=>e.trim())).concat(t).join("|")}var Gs=Object.freeze({__proto__:null,name:Bs,run:function(){const e=document.querySelectorAll("[data-abbr]");for(const t of e){const{localName:e}=t;if("dfn"===e)Hs(t);else{En(`\`data-abbr\` attribute not supported on \`${e}\` elements.`,Bs,{elements:[t],title:"Error: unsupported."})}}}});const Vs=/^[a-z]+(\s+[a-z]+)+\??$/,Ys=/\B"([^"]*)"\B/,Ks=/^(\w+)\(([^\\)]*)\)(?:\|(\w+)(?:\((?:([^\\)]*))\))?)?$/,Zs=/\[\[(\w+(?: +\w+)*)\]\](\([^)]*\))?$/,Js=/^((?:\[\[)?(?:\w+(?: +\w+)*)(?:\]\])?)$/,Xs=/^(?:\w+)\??$/,Qs=/^(\w+)\["([\w- ]*)"\]$/,ei=/\.?(\w+\(.*\)$)/,ti=/\/(.+)/,ni=/\[\[.+\]\]/;function ri(e){const{identifier:t,renderParent:n,nullable:r}=e;if(n)return jt`<a
763
763
  data-xref-type="_IDL_"
764
764
  data-link-type="idl"
765
765
  data-lt="${t}"
766
766
  ><code>${t+(r?"?":"")}</code></a
767
- >`}function ri(e){const{identifier:t,parent:n,slotType:r,renderParent:s,args:i}=e,{identifier:o}=n||{},a="method"===r,c=a?Ot`(${un(i,si)})`:null,l=a?`(${i.join(", ")})`:"";return Ot`${n&&s?".":""}<a
767
+ >`}function si(e){const{identifier:t,parent:n,slotType:r,renderParent:s,args:i}=e,{identifier:o}=n||{},a="method"===r,c=a?jt`(${dn(i,ii)})`:null,l=a?`(${i.join(", ")})`:"";return jt`${n&&s?".":""}<a
768
768
  data-xref-type="${r}"
769
769
  data-link-type="${r}"
770
770
  data-link-for="${o}"
771
771
  data-xref-for="${o}"
772
772
  data-lt="${`[[${t}]]${l}`}"
773
773
  ><code>[[${t}]]${c}</code></a
774
- >`}function si(e,t,n){if(t<n.length-1)return Ot`<var>${e}</var>`;const r=e.split(/(^\.{3})(.+)/),s=r.length>1,i=s?r[2]:r[0];return Ot`${s?"...":null}<var>${i}</var>`}function ii(e){const{parent:t,identifier:n,renderParent:r}=e,{identifier:s}=t||{};return Ot`${r?".":""}<a
774
+ >`}function ii(e,t,n){if(t<n.length-1)return jt`<var>${e}</var>`;const r=e.split(/(^\.{3})(.+)/),s=r.length>1,i=s?r[2]:r[0];return jt`${s?"...":null}<var>${i}</var>`}function oi(e){const{parent:t,identifier:n,renderParent:r}=e,{identifier:s}=t||{};return jt`${r?".":""}<a
775
775
  data-link-type="idl"
776
776
  data-xref-type="attribute|dict-member|const"
777
777
  data-link-for="${s}"
778
778
  data-xref-for="${s}"
779
779
  ><code>${n}</code></a
780
- >`}function oi(e){const{args:t,identifier:n,type:r,parent:s,renderParent:i}=e,{renderText:o,renderArgs:a}=e,{identifier:c}=s||{},l=un(a||t,si),u=`${n}(${t.join(", ")})`;return Ot`${s&&i?".":""}<a
780
+ >`}function ai(e){const{args:t,identifier:n,type:r,parent:s,renderParent:i}=e,{renderText:o,renderArgs:a}=e,{identifier:c}=s||{},l=dn(a||t,ii),u=`${n}(${t.join(", ")})`;return jt`${s&&i?".":""}<a
781
781
  data-link-type="idl"
782
782
  data-xref-type="${r}"
783
783
  data-link-for="${c}"
784
784
  data-xref-for="${c}"
785
785
  data-lt="${u}"
786
786
  ><code>${o||n}</code></a
787
- >${!o||a?Ot`<code>(${l})</code>`:""}`}function ai(e){const{identifier:t,enumValue:n,parent:r}=e,s=r?r.identifier:t;return Ot`"<a
787
+ >${!o||a?jt`<code>(${l})</code>`:""}`}function ci(e){const{identifier:t,enumValue:n,parent:r}=e,s=r?r.identifier:t;return jt`"<a
788
788
  data-link-type="idl"
789
789
  data-xref-type="enum-value"
790
790
  data-link-for="${s}"
791
791
  data-xref-for="${s}"
792
792
  data-lt="${n?null:"the-empty-string"}"
793
793
  ><code>${n}</code></a
794
- >"`}function ci(e){const{identifier:t}=e;return Ot`"<a
794
+ >"`}function li(e){const{identifier:t}=e;return jt`"<a
795
795
  data-link-type="idl"
796
796
  data-cite="webidl"
797
797
  data-xref-type="exception"
798
798
  ><code>${t}</code></a
799
- >"`}function li(e){const{identifier:t,nullable:n}=e;return Ot`<a
799
+ >"`}function ui(e){const{identifier:t,nullable:n}=e;return jt`<a
800
800
  data-link-type="idl"
801
801
  data-cite="webidl"
802
802
  data-xref-type="interface"
803
803
  data-lt="${t}"
804
804
  ><code>${t+(n?"?":"")}</code></a
805
- >`}function ui(e){let t;try{t=function(e){const t=ti.test(e),n=t?ei:Qs,[r,s]=e.split(n);if(t&&r&&!s)throw new SyntaxError(`Internal slot missing "for" part. Expected \`{{ InterfaceName/${r}}}\` }.`);const i=r.split(/[./]/).concat(s).filter((e=>e&&e.trim())).map((e=>e.trim())),o=!e.includes("/"),a=[];for(;i.length;){const t=i.pop();if(Ys.test(t)){const[,e,n,r,s]=t.match(Ys),i=n.split(/,\s*/).filter((e=>e)),c=r?.trim(),l=s?.split(/,\s*/).filter((e=>e));a.push({type:"method",identifier:e,args:i,renderParent:o,renderText:c,renderArgs:l})}else if(Xs.test(t)){const[,e,n]=t.match(Xs);a.push({type:"enum",identifier:e,enumValue:n,renderParent:o})}else if(Vs.test(t)){const[,e]=t.match(Vs);o?a.push({type:"exception",identifier:e}):a.push({type:"enum",enumValue:e,renderParent:o})}else if(Ks.test(t)){const[,e,n]=t.match(Ks),r=n?"method":"attribute",s=n?.slice(1,-1).split(/,\s*/).filter((e=>e));a.push({type:"internal-slot",slotType:r,identifier:e,args:s,renderParent:o})}else if(Zs.test(t)&&i.length){const[,e]=t.match(Zs);a.push({type:"attribute",identifier:e,renderParent:o})}else if(Gs.test(t)){const e=t.endsWith("?"),n=e?t.slice(0,-1):t;a.push({type:"idl-primitive",identifier:n,renderParent:o,nullable:e})}else{if(!Js.test(t)||0!==i.length)throw new SyntaxError(`IDL micro-syntax parsing error in \`{{ ${e} }}\``);{const e=t.endsWith("?"),n=e?t.slice(0,-1):t;a.push({type:"base",identifier:n,renderParent:o,nullable:e})}}}return a.forEach(((e,t,n)=>{e.parent=n[t+1]||null})),a.reverse()}(e)}catch(t){const n=Ot`<span>{{ ${e} }}</span>`,r="Error: Invalid inline IDL string.";return Rn(t.message,"core/inlines",{title:r,elements:[n]}),n}const n=Ot(document.createDocumentFragment()),r=[];for(const e of t)switch(e.type){case"base":{const t=ni(e);t&&r.push(t);break}case"attribute":r.push(ii(e));break;case"internal-slot":r.push(ri(e));break;case"method":r.push(oi(e));break;case"enum":r.push(ai(e));break;case"exception":r.push(ci(e));break;case"idl-primitive":r.push(li(e));break;default:throw new Error("Unknown type.")}return n`${r}`}const di=new Set(["alias","reference"]),pi=async function(){const e=await jt.openDB("respec-biblio2",12,{upgrade(e){Array.from(e.objectStoreNames).map((t=>e.deleteObjectStore(t)));e.createObjectStore("alias",{keyPath:"id"}).createIndex("aliasOf","aliasOf",{unique:!1}),e.createObjectStore("reference",{keyPath:"id"})}}),t=Date.now();for(const n of[...di]){const r=e.transaction(n,"readwrite").store,s=IDBKeyRange.lowerBound(t);let i=await r.openCursor(s);for(;i?.value;){const e=i.value;(void 0===e.expires||e.expires<t)&&await r.delete(e.id),i=await i.continue()}}return e}();const fi={get ready(){return pi},async find(e){return await this.isAlias(e)&&(e=await this.resolveAlias(e)),await this.get("reference",e)},async has(e,t){if(!di.has(e))throw new TypeError(`Invalid type: ${e}`);if(!t)throw new TypeError("id is required");const n=(await this.ready).transaction(e,"readonly").store,r=IDBKeyRange.only(t);return!!await n.openCursor(r)},async isAlias(e){return await this.has("alias",e)},async resolveAlias(e){if(!e)throw new TypeError("id is required");const t=(await this.ready).transaction("alias","readonly").store,n=IDBKeyRange.only(e),r=await t.openCursor(n);return r?r.value.aliasOf:r},async get(e,t){if(!di.has(e))throw new TypeError(`Invalid type: ${e}`);if(!t)throw new TypeError("id is required");const n=(await this.ready).transaction(e,"readonly").store,r=IDBKeyRange.only(t),s=await n.openCursor(r);return s?s.value:s},async addAll(e,t){if(!e)return;const n={alias:[],reference:[]};for(const r of Object.keys(e)){const s={id:r,...e[r],expires:t};s.aliasOf?n.alias.push(s):n.reference.push(s)}const r=[...di].flatMap((e=>n[e].map((t=>this.add(e,t)))));await Promise.all(r)},async add(e,t){if(!di.has(e))throw new TypeError(`Invalid type: ${e}`);if("object"!=typeof t)throw new TypeError("details should be an object");if("alias"===e&&!t.hasOwnProperty("aliasOf"))throw new TypeError("Invalid alias object.");const n=await this.ready;let r=await this.has(e,t.id);if(r){if((await this.get(e,t.id))?.expires<Date.now()){const{store:s}=n.transaction(e,"readwrite");await s.delete(t.id),r=!1}}const{store:s}=n.transaction(e,"readwrite");return r?await s.put(t):await s.add(t)},async close(){(await this.ready).close()},async clear(){const e=await this.ready,t=[...di],n=e.transaction(t,"readwrite"),r=t.map((e=>n.objectStore(e).clear()));await Promise.all(r)}},hi={},mi=new URL("https://api.specref.org/bibrefs?refs="),gi=Kt({hint:"dns-prefetch",href:mi.origin});let bi;document.head.appendChild(gi);const yi=new Promise((e=>{bi=e}));async function wi(e,t={forceUpdate:!1}){const n=[...new Set(e)].filter((e=>e.trim()));if(!n.length||!1===navigator.onLine)return null;let r;try{r=await fetch(mi.href+n.join(","))}catch(e){return console.error(e),null}if(!t.forceUpdate&&!r.ok||200!==r.status)return null;const s=await r.json(),i=Date.now()+36e5;try{const e=r.headers.has("Expires")?Math.min(Date.parse(r.headers.get("Expires")),i):i;await fi.addAll(s,e)}catch(e){console.error(e)}return s}async function vi(e){const t=await yi;if(!t.hasOwnProperty(e))return null;const n=t[e];return n.aliasOf?await vi(n.aliasOf):n}var $i=Object.freeze({__proto__:null,Plugin:class{constructor(e){this.conf=e}normalizeReferences(){const e=new Set([...this.conf.normativeReferences].map((e=>e.toLowerCase())));Array.from(this.conf.informativeReferences).filter((t=>e.has(t.toLowerCase()))).forEach((e=>this.conf.informativeReferences.delete(e)))}getRefKeys(){return{informativeReferences:Array.from(this.conf.informativeReferences),normativeReferences:Array.from(this.conf.normativeReferences)}}async run(){this.conf.localBiblio||(this.conf.localBiblio={}),this.conf.biblio=hi;const e=Object.keys(this.conf.localBiblio).filter((e=>this.conf.localBiblio[e].hasOwnProperty("aliasOf"))).map((e=>this.conf.localBiblio[e].aliasOf)).filter((e=>!this.conf.localBiblio.hasOwnProperty(e)));this.normalizeReferences();const t=this.getRefKeys(),n=Array.from(new Set(t.normativeReferences.concat(t.informativeReferences).filter((e=>!this.conf.localBiblio.hasOwnProperty(e))).concat(e).sort())),r=n.length?await async function(e){const t=[];try{await fi.ready;const n=e.map((async e=>({id:e,data:await fi.find(e)})));t.push(...await Promise.all(n))}catch(n){t.push(...e.map((e=>({id:e,data:null})))),console.warn(n)}return t}(n):[],s={hasData:[],noData:[]};r.forEach((e=>{(e.data?s.hasData:s.noData).push(e)})),s.hasData.forEach((e=>{hi[e.id]=e.data}));const i=s.noData.map((e=>e.id));if(i.length){const e=await wi(i,{forceUpdate:!0});Object.assign(hi,e)}Object.assign(hi,this.conf.localBiblio),(()=>{bi(this.conf.biblio)})()}},biblio:hi,name:"core/biblio",resolveRef:vi,updateFromNetwork:wi});const ki="core/render-biblio",xi=sn({en:{info_references:"Informative references",norm_references:"Normative references",references:"References",reference_not_found:"Reference not found."},ko:{references:"참조"},nl:{info_references:"Informatieve referenties",norm_references:"Normatieve referenties",references:"Referenties"},es:{info_references:"Referencias informativas",norm_references:"Referencias normativas",references:"Referencias",reference_not_found:"Referencia no encontrada."},ja:{info_references:"参照用参考文献",norm_references:"規範的参考文献",references:"参考文献"},de:{info_references:"Weiterführende Informationen",norm_references:"Normen und Spezifikationen",references:"Referenzen"},zh:{info_references:"非规范性引用",norm_references:"规范性引用",references:"参考文献"}}),_i=new Map([["CR","W3C Candidate Recommendation"],["ED","W3C Editor's Draft"],["LCWD","W3C Last Call Working Draft"],["NOTE","W3C Working Group Note"],["PER","W3C Proposed Edited Recommendation"],["PR","W3C Proposed Recommendation"],["REC","W3C Recommendation"],["WD","W3C Working Draft"]]),Ci=(Si=".",e=>{const t=e.trim();return!t||t.endsWith(Si)?t:t+Si});var Si;function Ri(e,t){const{goodRefs:n,badRefs:r}=function(e){const t=[],n=[];for(const r of e)r.refcontent?t.push(r):n.push(r);return{goodRefs:t,badRefs:n}}(e.map(Ei)),s=function(e){const t=new Map;for(const n of e)t.has(n.refcontent.id)||t.set(n.refcontent.id,n);return[...t.values()]}(n),i=s.concat(r).sort(((e,t)=>e.ref.toLocaleLowerCase().localeCompare(t.ref.toLocaleLowerCase()))),o=Ot`<section>
805
+ >`}function di(e){let t;try{t=function(e){const t=ni.test(e),n=t?ti:ei,[r,s]=e.split(n);if(t&&r&&!s)throw new SyntaxError(`Internal slot missing "for" part. Expected \`{{ InterfaceName/${r}}}\` }.`);const i=r.split(/[./]/).concat(s).filter((e=>e&&e.trim())).map((e=>e.trim())),o=!e.includes("/"),a=[];for(;i.length;){const t=i.pop();if(Ks.test(t)){const[,e,n,r,s]=t.match(Ks),i=n.split(/,\s*/).filter((e=>e)),c=r?.trim(),l=s?.split(/,\s*/).filter((e=>e));a.push({type:"method",identifier:e,args:i,renderParent:o,renderText:c,renderArgs:l})}else if(Qs.test(t)){const[,e,n]=t.match(Qs);a.push({type:"enum",identifier:e,enumValue:n,renderParent:o})}else if(Ys.test(t)){const[,e]=t.match(Ys);o?a.push({type:"exception",identifier:e}):a.push({type:"enum",enumValue:e,renderParent:o})}else if(Zs.test(t)){const[,e,n]=t.match(Zs),r=n?"method":"attribute",s=n?.slice(1,-1).split(/,\s*/).filter((e=>e));a.push({type:"internal-slot",slotType:r,identifier:e,args:s,renderParent:o})}else if(Js.test(t)&&i.length){const[,e]=t.match(Js);a.push({type:"attribute",identifier:e,renderParent:o})}else if(Vs.test(t)){const e=t.endsWith("?"),n=e?t.slice(0,-1):t;a.push({type:"idl-primitive",identifier:n,renderParent:o,nullable:e})}else{if(!Xs.test(t)||0!==i.length)throw new SyntaxError(`IDL micro-syntax parsing error in \`{{ ${e} }}\``);{const e=t.endsWith("?"),n=e?t.slice(0,-1):t;a.push({type:"base",identifier:n,renderParent:o,nullable:e})}}}return a.forEach(((e,t,n)=>{e.parent=n[t+1]||null})),a.reverse()}(e)}catch(t){const n=jt`<span>{{ ${e} }}</span>`,r="Error: Invalid inline IDL string.";return En(t.message,"core/inlines",{title:r,elements:[n]}),n}const n=jt(document.createDocumentFragment()),r=[];for(const e of t)switch(e.type){case"base":{const t=ri(e);t&&r.push(t);break}case"attribute":r.push(oi(e));break;case"internal-slot":r.push(si(e));break;case"method":r.push(ai(e));break;case"enum":r.push(ci(e));break;case"exception":r.push(li(e));break;case"idl-primitive":r.push(ui(e));break;default:throw new Error("Unknown type.")}return n`${r}`}const pi=new Set(["alias","reference"]),fi=async function(){const e=await Mt.openDB("respec-biblio2",12,{upgrade(e){Array.from(e.objectStoreNames).map((t=>e.deleteObjectStore(t)));e.createObjectStore("alias",{keyPath:"id"}).createIndex("aliasOf","aliasOf",{unique:!1}),e.createObjectStore("reference",{keyPath:"id"})}}),t=Date.now();for(const n of[...pi]){const r=e.transaction(n,"readwrite").store,s=IDBKeyRange.lowerBound(t);let i=await r.openCursor(s);for(;i?.value;){const e=i.value;(void 0===e.expires||e.expires<t)&&await r.delete(e.id),i=await i.continue()}}return e}();const hi={get ready(){return fi},async find(e){return await this.isAlias(e)&&(e=await this.resolveAlias(e)),await this.get("reference",e)},async has(e,t){if(!pi.has(e))throw new TypeError(`Invalid type: ${e}`);if(!t)throw new TypeError("id is required");const n=(await this.ready).transaction(e,"readonly").store,r=IDBKeyRange.only(t);return!!await n.openCursor(r)},async isAlias(e){return await this.has("alias",e)},async resolveAlias(e){if(!e)throw new TypeError("id is required");const t=(await this.ready).transaction("alias","readonly").store,n=IDBKeyRange.only(e),r=await t.openCursor(n);return r?r.value.aliasOf:r},async get(e,t){if(!pi.has(e))throw new TypeError(`Invalid type: ${e}`);if(!t)throw new TypeError("id is required");const n=(await this.ready).transaction(e,"readonly").store,r=IDBKeyRange.only(t),s=await n.openCursor(r);return s?s.value:s},async addAll(e,t){if(!e)return;const n={alias:[],reference:[]};for(const r of Object.keys(e)){const s={id:r,...e[r],expires:t};s.aliasOf?n.alias.push(s):n.reference.push(s)}const r=[...pi].flatMap((e=>n[e].map((t=>this.add(e,t)))));await Promise.all(r)},async add(e,t){if(!pi.has(e))throw new TypeError(`Invalid type: ${e}`);if("object"!=typeof t)throw new TypeError("details should be an object");if("alias"===e&&!t.hasOwnProperty("aliasOf"))throw new TypeError("Invalid alias object.");const n=await this.ready;let r=await this.has(e,t.id);if(r){if((await this.get(e,t.id))?.expires<Date.now()){const{store:s}=n.transaction(e,"readwrite");await s.delete(t.id),r=!1}}const{store:s}=n.transaction(e,"readwrite");return r?await s.put(t):await s.add(t)},async close(){(await this.ready).close()},async clear(){const e=await this.ready,t=[...pi],n=e.transaction(t,"readwrite"),r=t.map((e=>n.objectStore(e).clear()));await Promise.all(r)}},mi={},gi=new URL("https://api.specref.org/bibrefs?refs="),bi=Zt({hint:"dns-prefetch",href:gi.origin});let yi;document.head.appendChild(bi);const wi=new Promise((e=>{yi=e}));async function vi(e,t={forceUpdate:!1}){const n=[...new Set(e)].filter((e=>e.trim()));if(!n.length||!1===navigator.onLine)return null;let r;try{r=await fetch(gi.href+n.join(","))}catch(e){return console.error(e),null}if(!t.forceUpdate&&!r.ok||200!==r.status)return null;const s=await r.json(),i=Date.now()+36e5;try{const e=r.headers.has("Expires")?Math.min(Date.parse(r.headers.get("Expires")),i):i;await hi.addAll(s,e)}catch(e){console.error(e)}return s}async function $i(e){const t=await wi;if(!t.hasOwnProperty(e))return null;const n=t[e];return n.aliasOf?await $i(n.aliasOf):n}var ki=Object.freeze({__proto__:null,Plugin:class{constructor(e){this.conf=e}normalizeReferences(){const e=new Set([...this.conf.normativeReferences].map((e=>e.toLowerCase())));Array.from(this.conf.informativeReferences).filter((t=>e.has(t.toLowerCase()))).forEach((e=>this.conf.informativeReferences.delete(e)))}getRefKeys(){return{informativeReferences:Array.from(this.conf.informativeReferences),normativeReferences:Array.from(this.conf.normativeReferences)}}async run(){this.conf.localBiblio||(this.conf.localBiblio={}),this.conf.biblio=mi;const e=Object.keys(this.conf.localBiblio).filter((e=>this.conf.localBiblio[e].hasOwnProperty("aliasOf"))).map((e=>this.conf.localBiblio[e].aliasOf)).filter((e=>!this.conf.localBiblio.hasOwnProperty(e)));this.normalizeReferences();const t=this.getRefKeys(),n=Array.from(new Set(t.normativeReferences.concat(t.informativeReferences).filter((e=>!this.conf.localBiblio.hasOwnProperty(e))).concat(e).sort())),r=n.length?await async function(e){const t=[];try{await hi.ready;const n=e.map((async e=>({id:e,data:await hi.find(e)})));t.push(...await Promise.all(n))}catch(n){t.push(...e.map((e=>({id:e,data:null})))),console.warn(n)}return t}(n):[],s={hasData:[],noData:[]};r.forEach((e=>{(e.data?s.hasData:s.noData).push(e)})),s.hasData.forEach((e=>{mi[e.id]=e.data}));const i=s.noData.map((e=>e.id));if(i.length){const e=await vi(i,{forceUpdate:!0});Object.assign(mi,e)}Object.assign(mi,this.conf.localBiblio),(()=>{yi(this.conf.biblio)})()}},biblio:mi,name:"core/biblio",resolveRef:$i,updateFromNetwork:vi});const xi="core/render-biblio",_i=on({en:{info_references:"Informative references",norm_references:"Normative references",references:"References",reference_not_found:"Reference not found."},ko:{references:"참조"},nl:{info_references:"Informatieve referenties",norm_references:"Normatieve referenties",references:"Referenties"},es:{info_references:"Referencias informativas",norm_references:"Referencias normativas",references:"Referencias",reference_not_found:"Referencia no encontrada."},ja:{info_references:"参照用参考文献",norm_references:"規範的参考文献",references:"参考文献"},de:{info_references:"Weiterführende Informationen",norm_references:"Normen und Spezifikationen",references:"Referenzen"},zh:{info_references:"非规范性引用",norm_references:"规范性引用",references:"参考文献"}}),Si=new Map([["CR","W3C Candidate Recommendation"],["ED","W3C Editor's Draft"],["LCWD","W3C Last Call Working Draft"],["NOTE","W3C Working Group Note"],["PER","W3C Proposed Edited Recommendation"],["PR","W3C Proposed Recommendation"],["REC","W3C Recommendation"],["WD","W3C Working Draft"]]),Ci=(Ri=".",e=>{const t=e.trim();return!t||t.endsWith(Ri)?t:t+Ri});var Ri;function Ei(e,t){const{goodRefs:n,badRefs:r}=function(e){const t=[],n=[];for(const r of e)r.refcontent?t.push(r):n.push(r);return{goodRefs:t,badRefs:n}}(e.map(Ai)),s=function(e){const t=new Map;for(const n of e)t.has(n.refcontent.id)||t.set(n.refcontent.id,n);return[...t.values()]}(n),i=s.concat(r).sort(((e,t)=>e.ref.toLocaleLowerCase().localeCompare(t.ref.toLocaleLowerCase()))),o=jt`<section>
806
806
  <h3>${t}</h3>
807
- <dl class="bibliography">${i.map(Ti)}</dl>
808
- </section>`;fn(o,"",t);const a=function(e){return e.reduce(((e,t)=>{const n=t.refcontent.id;return(e.has(n)?e.get(n):e.set(n,[]).get(n)).push(t.ref),e}),new Map)}(n);return function(e,t){e.map((({ref:e,refcontent:n})=>{const r=`#bib-${e.toLowerCase()}`,s=t.get(n.id).map((e=>`a.bibref[href="#bib-${e.toLowerCase()}"]`)).join(",");return{refUrl:r,elems:document.querySelectorAll(s),refcontent:n}})).forEach((({refUrl:e,elems:t,refcontent:n})=>{t.forEach((t=>{t.setAttribute("href",e),t.setAttribute("title",n.title),t.dataset.linkType="biblio"}))}))}(s,a),function(e){for(const{ref:t}of e){const e=[...document.querySelectorAll(`a.bibref[href="#bib-${t.toLowerCase()}"]`)].filter((({textContent:e})=>e.toLowerCase()===t.toLowerCase()));Rn(`Reference "[${t}]" not found.`,ki,{hint:`Search for ["${t}"](https://www.specref.org?q=${t}) on Specref to see if it exists or if it's misspelled.`,elements:e})}}(r),o}function Ei(e){let t=hi[e],n=e;const r=new Set([n]);for(;t&&t.aliasOf;)if(r.has(t.aliasOf)){t=null;Rn(`Circular reference in biblio DB between [\`${e}\`] and [\`${n}\`].`,ki)}else n=t.aliasOf,t=hi[n],r.add(n);return t&&!t.id&&(t.id=e.toLowerCase()),{ref:e,refcontent:t}}function Ai(e,t){const n=e.replace(/^(!|\?)/,""),r=`#bib-${n.toLowerCase()}`,s=Ot`<cite
807
+ <dl class="bibliography">${i.map(Li)}</dl>
808
+ </section>`;hn(o,"",t);const a=function(e){return e.reduce(((e,t)=>{const n=t.refcontent.id;return(e.has(n)?e.get(n):e.set(n,[]).get(n)).push(t.ref),e}),new Map)}(n);return function(e,t){e.map((({ref:e,refcontent:n})=>{const r=`#bib-${e.toLowerCase()}`,s=t.get(n.id).map((e=>`a.bibref[href="#bib-${e.toLowerCase()}"]`)).join(",");return{refUrl:r,elems:document.querySelectorAll(s),refcontent:n}})).forEach((({refUrl:e,elems:t,refcontent:n})=>{t.forEach((t=>{t.setAttribute("href",e),t.setAttribute("title",n.title),t.dataset.linkType="biblio"}))}))}(s,a),function(e){for(const{ref:t}of e){const e=[...document.querySelectorAll(`a.bibref[href="#bib-${t.toLowerCase()}"]`)].filter((({textContent:e})=>e.toLowerCase()===t.toLowerCase()));En(`Reference "[${t}]" not found.`,xi,{hint:`Search for ["${t}"](https://www.specref.org?q=${t}) on Specref to see if it exists or if it's misspelled.`,elements:e})}}(r),o}function Ai(e){let t=mi[e],n=e;const r=new Set([n]);for(;t&&t.aliasOf;)if(r.has(t.aliasOf)){t=null;En(`Circular reference in biblio DB between [\`${e}\`] and [\`${n}\`].`,xi)}else n=t.aliasOf,t=mi[n],r.add(n);return t&&!t.id&&(t.id=e.toLowerCase()),{ref:e,refcontent:t}}function Ti(e,t){const n=e.replace(/^(!|\?)/,""),r=`#bib-${n.toLowerCase()}`,s=jt`<cite
809
809
  ><a class="bibref" href="${r}" data-link-type="biblio">${t||n}</a></cite
810
- >`;return t?s:Ot`[${s}]`}function Ti(e){const{ref:t,refcontent:n}=e,r=`bib-${t.toLowerCase()}`;return Ot`
810
+ >`;return t?s:jt`[${s}]`}function Li(e){const{ref:t,refcontent:n}=e,r=`bib-${t.toLowerCase()}`;return jt`
811
811
  <dt id="${r}">[${t}]</dt>
812
812
  <dd>
813
- ${n?{html:Li(n)}:Ot`<em class="respec-offending-element"
814
- >${xi.reference_not_found}</em
813
+ ${n?{html:Pi(n)}:jt`<em class="respec-offending-element"
814
+ >${_i.reference_not_found}</em
815
815
  >`}
816
816
  </dd>
817
- `}function Li(e){if("string"==typeof e)return e;let t=`<cite>${e.title}</cite>`;return t=e.href?`<a href="${e.href}">${t}</a>. `:`${t}. `,e.authors&&e.authors.length&&(t+=e.authors.join("; "),e.etAl&&(t+=" et al"),t+=". "),e.publisher&&(t=`${t} ${Ci(e.publisher)} `),e.date&&(t+=`${e.date}. `),e.status&&(t+=`${_i.get(e.status)||e.status}. `),e.href&&(t+=`URL: <a href="${e.href}">${e.href}</a>`),t}var Pi=Object.freeze({__proto__:null,name:ki,renderInlineCitation:Ai,run:function(e){const t=Array.from(e.informativeReferences),n=Array.from(e.normativeReferences);if(!t.length&&!n.length)return;const r=document.querySelector("section#references")||Ot`<section id="references"></section>`;if(document.querySelector("section#references > :is(h2, h1)")||r.prepend(Ot`<h1>${xi.references}</h1>`),r.classList.add("appendix"),n.length){const e=Ri(n,xi.norm_references);r.appendChild(e)}if(t.length){const e=Ri(t,xi.info_references);r.appendChild(e)}document.body.appendChild(r)}});const Ii="core/inlines",Di={},Ni=e=>new RegExp(e.map((e=>e.source)).join("|")),Oi=sn({en:{rfc2119Keywords:()=>Ni([/\bMUST(?:\s+NOT)?\b/,/\bSHOULD(?:\s+NOT)?\b/,/\bSHALL(?:\s+NOT)?\b/,/\bMAY\b/,/\b(?:NOT\s+)?REQUIRED\b/,/\b(?:NOT\s+)?RECOMMENDED\b/,/\bOPTIONAL\b/])},de:{rfc2119Keywords:()=>Ni([/\bMUSS\b/,/\bMÜSSEN\b/,/\bERFORDERLICH\b/,/\b(?:NICHT\s+)?NÖTIG\b/,/\bDARF(?:\s+NICHT)?\b/,/\bDÜRFEN(?:\s+NICHT)?\b/,/\bVERBOTEN\b/,/\bSOLL(?:\s+NICHT)?\b/,/\bSOLLEN(?:\s+NICHT)?\b/,/\b(?:NICHT\s+)?EMPFOHLEN\b/,/\bKANN\b/,/\bKÖNNEN\b/,/\bOPTIONAL\b/])}}),ji=/(?:`[^`]+`)(?!`)/,Mi=/(?:{{[^}]+\?*}})/,zi=/\B\|\w[\w\s]*(?:\s*:[\w\s&;<>]+\??)?\|\B/,Ui=/(?:\[\[(?:!|\\|\?)?[\w.-]+(?:|[^\]]+)?\]\])/,qi=/(?:\[\[\[(?:!|\\|\?)?#?[\w-.]+\]\]\])/,Wi=/(?:\[=[^=]+=\])/,Fi=/(?:\[\^[^^]+\^\])/;function Bi(e){const t=e.slice(2,-2).trim(),[n,r,s]=t.split("/",3).map((e=>e&&e.trim())).filter((e=>!!e)),[i,o,a]=t.startsWith("/")?["element-attr",null,n]:s?["attr-value",`${n}/${r}`,s]:r?["element-attr",n,r]:["element",null,n];return Ot`<code
817
+ `}function Pi(e){if("string"==typeof e)return e;let t=`<cite>${e.title}</cite>`;return t=e.href?`<a href="${e.href}">${t}</a>. `:`${t}. `,e.authors&&e.authors.length&&(t+=e.authors.join("; "),e.etAl&&(t+=" et al"),t+=". "),e.publisher&&(t=`${t} ${Ci(e.publisher)} `),e.date&&(t+=`${e.date}. `),e.status&&(t+=`${Si.get(e.status)||e.status}. `),e.href&&(t+=`URL: <a href="${e.href}">${e.href}</a>`),t}var Ii=Object.freeze({__proto__:null,name:xi,renderInlineCitation:Ti,run:function(e){const t=Array.from(e.informativeReferences),n=Array.from(e.normativeReferences);if(!t.length&&!n.length)return;const r=document.querySelector("section#references")||jt`<section id="references"></section>`;if(document.querySelector("section#references > :is(h2, h1)")||r.prepend(jt`<h1>${_i.references}</h1>`),r.classList.add("appendix"),n.length){const e=Ei(n,_i.norm_references);r.appendChild(e)}if(t.length){const e=Ei(t,_i.info_references);r.appendChild(e)}document.body.appendChild(r)}});const Di="core/inlines",Ni={},Oi=e=>new RegExp(e.map((e=>e.source)).join("|")),ji=on({en:{rfc2119Keywords:()=>Oi([/\bMUST(?:\s+NOT)?\b/,/\bSHOULD(?:\s+NOT)?\b/,/\bSHALL(?:\s+NOT)?\b/,/\bMAY\b/,/\b(?:NOT\s+)?REQUIRED\b/,/\b(?:NOT\s+)?RECOMMENDED\b/,/\bOPTIONAL\b/])},de:{rfc2119Keywords:()=>Oi([/\bMUSS\b/,/\bMÜSSEN\b/,/\bERFORDERLICH\b/,/\b(?:NICHT\s+)?NÖTIG\b/,/\bDARF(?:\s+NICHT)?\b/,/\bDÜRFEN(?:\s+NICHT)?\b/,/\bVERBOTEN\b/,/\bSOLL(?:\s+NICHT)?\b/,/\bSOLLEN(?:\s+NICHT)?\b/,/\b(?:NICHT\s+)?EMPFOHLEN\b/,/\bKANN\b/,/\bKÖNNEN\b/,/\bOPTIONAL\b/])}}),Mi=/(?:`[^`]+`)(?!`)/,zi=/(?:{{[^}]+\?*}})/,Ui=/\B\|\w[\w\s]*(?:\s*:[\w\s&;<>]+\??)?\|\B/,qi=/(?:\[\[(?:!|\\|\?)?[\w.-]+(?:|[^\]]+)?\]\])/,Wi=/(?:\[\[\[(?:!|\\|\?)?#?[\w-.]+\]\]\])/,Fi=/(?:\[=[^=]+=\])/,Bi=/(?:\[\^[^^]+\^\])/;function Hi(e){const t=e.slice(2,-2).trim(),[n,r,s]=t.split("/",3).map((e=>e&&e.trim())).filter((e=>!!e)),[i,o,a]=t.startsWith("/")?["element-attr",null,n]:s?["attr-value",`${n}/${r}`,s]:r?["element-attr",n,r]:["element",null,n];return jt`<code
818
818
  ><a
819
819
  data-xref-type="${i}"
820
820
  data-xref-for="${o}"
@@ -822,47 +822,47 @@ dd{margin-left:0}
822
822
  data-link-for="${o}"
823
823
  >${a}</a
824
824
  ></code
825
- >`}function Hi(e){const t=rn(e),n=Ot`<em class="rfc2119">${t}</em>`;return Di[t]=!0,n}function Gi(e){const t=e.slice(3,-3).trim();return t.startsWith("#")?Ot`<a href="${t}" data-matched-text="${e}"></a>`:Ot`<a data-cite="${t}" data-matched-text="${e}"></a>`}function Vi(e,t){const n=rn(e.slice(2,-2));if(n.startsWith("\\"))return e.replace("\\","");const r=ui(n);return!!t.parentElement.closest("dfn")?Xi(`\`${r.textContent}\``):r}function Yi(e,t,n){const r=e.slice(2,-2);if(r.startsWith("\\"))return[`[[${r.slice(1)}]]`];const[s,i]=r.split("|").map(rn),{type:o,illegal:a}=gn(s,t.parentElement),c=Ai(s,i),l=s.replace(/^(!|\?)/,"");if(a&&!n.normativeReferences.has(l)){const e=c.childNodes[1]||c;En("Normative references in informative sections are not allowed. ",Ii,{elements:[e],hint:`Remove '!' from the start of the reference \`[[${r}]]\``})}return"informative"!==o||a?n.normativeReferences.add(l):n.informativeReferences.add(l),c.childNodes[1]?c.childNodes:[c]}function Ki(e,t,n){return"ABBR"===t.parentElement.tagName?e:Ot`<abbr title="${n.get(e)}">${e}</abbr>`}function Zi(e){const t=e.slice(1,-1).split(":",2),[n,r]=t.map((e=>e.trim()));return Ot`<var data-type="${r}">${n}</var>`}function Ji(e){const t=function(e){const t=e=>e.replace("%%","/").split("/").map(rn).join("/"),n=e.replace("\\/","%%"),r=n.lastIndexOf("/");if(-1===r)return[t(n)];const s=n.substring(0,r),i=n.substring(r+1,n.length);return[t(s),t(i)]}(e=e.slice(2,-2)),[n,r]=2===t.length?t:[null,t[0]],[s,i]=r.includes("|")?r.split("|",2).map((e=>e.trim())):[null,r],o=Qi(i),a=n?rn(n):null;return Ot`<a
825
+ >`}function Gi(e){const t=sn(e),n=jt`<em class="rfc2119">${t}</em>`;return Ni[t]=!0,n}function Vi(e){const t=e.slice(3,-3).trim();return t.startsWith("#")?jt`<a href="${t}" data-matched-text="${e}"></a>`:jt`<a data-cite="${t}" data-matched-text="${e}"></a>`}function Yi(e,t){const n=sn(e.slice(2,-2));if(n.startsWith("\\"))return e.replace("\\","");const r=di(n);return!!t.parentElement.closest("dfn")?Qi(`\`${r.textContent}\``):r}function Ki(e,t,n){const r=e.slice(2,-2);if(r.startsWith("\\"))return[`[[${r.slice(1)}]]`];const[s,i]=r.split("|").map(sn),{type:o,illegal:a}=bn(s,t.parentElement),c=Ti(s,i),l=s.replace(/^(!|\?)/,"");if(a&&!n.normativeReferences.has(l)){const e=c.childNodes[1]||c;An("Normative references in informative sections are not allowed. ",Di,{elements:[e],hint:`Remove '!' from the start of the reference \`[[${r}]]\``})}return"informative"!==o||a?n.normativeReferences.add(l):n.informativeReferences.add(l),c.childNodes[1]?c.childNodes:[c]}function Zi(e,t,n){return"ABBR"===t.parentElement.tagName?e:jt`<abbr title="${n.get(e)}">${e}</abbr>`}function Ji(e){const t=e.slice(1,-1).split(":",2),[n,r]=t.map((e=>e.trim()));return jt`<var data-type="${r}">${n}</var>`}function Xi(e){const t=function(e){const t=e=>e.replace("%%","/").split("/").map(sn).join("/"),n=e.replace("\\/","%%"),r=n.lastIndexOf("/");if(-1===r)return[t(n)];const s=n.substring(0,r),i=n.substring(r+1,n.length);return[t(s),t(i)]}(e=e.slice(2,-2)),[n,r]=2===t.length?t:[null,t[0]],[s,i]=r.includes("|")?r.split("|",2).map((e=>e.trim())):[null,r],o=eo(i),a=n?sn(n):null;return jt`<a
826
826
  data-link-type="dfn|abstract-op"
827
827
  data-link-for="${a}"
828
828
  data-xref-for="${a}"
829
829
  data-lt="${s}"
830
830
  >${o}</a
831
- >`}function Xi(e){const t=e.slice(1,-1);return Ot`<code>${t}</code>`}function Qi(e){return ji.test(e)?e.split(/(`[^`]+`)(?!`)/).map((e=>e.startsWith("`")?Xi(e):Qi(e))):document.createTextNode(e)}var eo=Object.freeze({__proto__:null,name:Ii,rfc2119Usage:Di,run:function(e){const t=new Map;document.normalize(),document.querySelector("section#conformance")||document.body.classList.add("informative"),e.normativeReferences=new $n,e.informativeReferences=new $n,e.respecRFC2119||(e.respecRFC2119=Di);const n=document.querySelectorAll("abbr[title]:not(.exclude)");for(const{textContent:e,title:r}of n){const n=rn(e),s=rn(r);t.set(n,s)}const r=t.size?new RegExp(`(?:\\b${[...t.keys()].join("\\b)|(?:\\b")}\\b)`):null,s=function(e,t=[],n={wsNodes:!0}){const r=t.join(", "),s=document.createNodeIterator(e,NodeFilter.SHOW_TEXT,(e=>n.wsNodes||e.data.trim()?r&&e.parentElement.closest(r)?NodeFilter.FILTER_REJECT:NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_REJECT)),i=[];let o;for(;o=s.nextNode();)i.push(o);return i}(document.body,["#respec-ui",".head","pre","svg"],{wsNodes:!1}),i=Oi.rfc2119Keywords(),o=new RegExp(`(${Ni([i,Mi,zi,Ui,qi,Wi,ji,Fi,...r?[r]:[]]).source})`);for(const n of s){const r=n.data.split(o);if(1===r.length)continue;const s=document.createDocumentFragment();let a=!0;for(const o of r)if(a=!a,a)switch(!0){case o.startsWith("{{"):s.append(Vi(o,n));break;case o.startsWith("[[["):s.append(Gi(o));break;case o.startsWith("[["):s.append(...Yi(o,n,e));break;case o.startsWith("|"):s.append(Zi(o));break;case o.startsWith("[="):s.append(Ji(o));break;case o.startsWith("`"):s.append(Xi(o));break;case o.startsWith("[^"):s.append(Bi(o));break;case t.has(o):s.append(Ki(o,n,t));break;case i.test(o):s.append(Hi(o))}else s.append(o);n.replaceWith(s)}}});const to="w3c/conformance",no=sn({en:{conformance:"Conformance",normativity:"As well as sections marked as non-normative, all authoring guidelines, diagrams, examples, and notes in this specification are non-normative. Everything else in this specification is normative.",keywordInterpretation:(e,t)=>Ot`<p>
831
+ >`}function Qi(e){const t=e.slice(1,-1);return jt`<code>${t}</code>`}function eo(e){return Mi.test(e)?e.split(/(`[^`]+`)(?!`)/).map((e=>e.startsWith("`")?Qi(e):eo(e))):document.createTextNode(e)}var to=Object.freeze({__proto__:null,name:Di,rfc2119Usage:Ni,run:function(e){const t=new Map;document.normalize(),document.querySelector("section#conformance")||document.body.classList.add("informative"),e.normativeReferences=new kn,e.informativeReferences=new kn,e.respecRFC2119||(e.respecRFC2119=Ni);const n=document.querySelectorAll("abbr[title]:not(.exclude)");for(const{textContent:e,title:r}of n){const n=sn(e),s=sn(r);t.set(n,s)}const r=t.size?new RegExp(`(?:\\b${[...t.keys()].join("\\b)|(?:\\b")}\\b)`):null,s=function(e,t=[],n={wsNodes:!0}){const r=t.join(", "),s=document.createNodeIterator(e,NodeFilter.SHOW_TEXT,(e=>n.wsNodes||e.data.trim()?r&&e.parentElement.closest(r)?NodeFilter.FILTER_REJECT:NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_REJECT)),i=[];let o;for(;o=s.nextNode();)i.push(o);return i}(document.body,["#respec-ui",".head","pre","svg"],{wsNodes:!1}),i=ji.rfc2119Keywords(),o=new RegExp(`(${Oi([i,zi,Ui,qi,Wi,Fi,Mi,Bi,...r?[r]:[]]).source})`);for(const n of s){const r=n.data.split(o);if(1===r.length)continue;const s=document.createDocumentFragment();let a=!0;for(const o of r)if(a=!a,a)switch(!0){case o.startsWith("{{"):s.append(Yi(o,n));break;case o.startsWith("[[["):s.append(Vi(o));break;case o.startsWith("[["):s.append(...Ki(o,n,e));break;case o.startsWith("|"):s.append(Ji(o));break;case o.startsWith("[="):s.append(Xi(o));break;case o.startsWith("`"):s.append(Qi(o));break;case o.startsWith("[^"):s.append(Hi(o));break;case t.has(o):s.append(Zi(o,n,t));break;case i.test(o):s.append(Gi(o))}else s.append(o);n.replaceWith(s)}}});const no="w3c/conformance",ro=on({en:{conformance:"Conformance",normativity:"As well as sections marked as non-normative, all authoring guidelines, diagrams, examples, and notes in this specification are non-normative. Everything else in this specification is normative.",keywordInterpretation:(e,t)=>jt`<p>
832
832
  The key word${t?"s":""} ${e} in this document
833
833
  ${t?"are":"is"} to be interpreted as described in
834
834
  <a href="https://datatracker.ietf.org/doc/html/bcp14">BCP 14</a>
835
- ${Ai("RFC2119")} ${Ai("RFC8174")}
835
+ ${Ti("RFC2119")} ${Ti("RFC8174")}
836
836
  when, and only when, they appear in all capitals, as shown here.
837
- </p>`},de:{conformance:"Anforderungen",normativity:"Neben den explizit als nicht-normativ gekennzeichneten Abschnitten sind auch alle Diagramme, Beispiele und Hinweise in diesem Dokument nicht normativ. Alle anderen Angaben sind normativ.",keywordInterpretation:(e,t)=>Ot`<p>
837
+ </p>`},de:{conformance:"Anforderungen",normativity:"Neben den explizit als nicht-normativ gekennzeichneten Abschnitten sind auch alle Diagramme, Beispiele und Hinweise in diesem Dokument nicht normativ. Alle anderen Angaben sind normativ.",keywordInterpretation:(e,t)=>jt`<p>
838
838
  ${t?"Die Schlüsselwörter":"Das Schlüsselwort"} ${e} in
839
839
  diesem Dokument ${t?"sind":"ist"} gemäß
840
840
  <a href="https://datatracker.ietf.org/doc/html/bcp14">BCP 14</a>
841
- ${Ai("RFC2119")} ${Ai("RFC8174")}
841
+ ${Ti("RFC2119")} ${Ti("RFC8174")}
842
842
  und unter Berücksichtigung von
843
843
  <a href="https://github.com/adfinis-sygroup/2119/blob/master/2119de.rst"
844
844
  >2119de</a
845
845
  >
846
846
  zu interpretieren, wenn und nur wenn ${t?"sie":"es"} wie hier
847
847
  gezeigt durchgehend groß geschrieben wurde${t?"n":""}.
848
- </p>`}});var ro=Object.freeze({__proto__:null,name:to,run:function(e){const t=document.querySelector("section#conformance");if(t&&!t.classList.contains("override")&&function(e,t){const n=[...Object.keys(Di)];n.length&&(t.normativeReferences.add("RFC2119"),t.normativeReferences.add("RFC8174"));const r=dn(n.sort(),(e=>Ot`<em class="rfc2119">${e}</em>`)),s=n.length>1,i=Ot`
849
- <h1>${no.conformance}</h1>
850
- <p>${no.normativity}</p>
851
- ${n.length?no.keywordInterpretation(r,s):null}
852
- `;e.prepend(...i.childNodes)}(t,e),!t&&Object.keys(Di).length){En("Document uses RFC2119 keywords but lacks a conformance section.",to,{hint:'Please add a `<section id="conformance">`.'})}}});function so(e,t,n,r){try{switch(t){case"element-attr":return document.createAttribute(e),!0;case"element":return document.createElement(e),!0}}catch(s){Rn(`Invalid ${t} name "${e}": ${s.message}`,r,{hint:`Check that the ${t} name is allowed per the XML's Name production for ${t}.`,elements:[n]})}return!1}function io(e,t,n,r){if(/^[a-z]+(-[a-z]+)*$/i.test(e))return!0;return Rn(`Invalid ${t} name "${e}".`,r,{hint:`Check that the ${t} name is allowed per the naming rules for this type.`,elements:[n]}),!1}const oo=new Cn;function ao(e,t){for(const n of t)oo.has(n)||oo.set(n,new Set),oo.get(n).add(e)}const co="core/dfn",lo=new Map([["abstract-op",{requiresFor:!1}],["attr-value",{requiresFor:!0,associateWith:"a markup attribute",validator:io}],["element",{requiresFor:!1,validator:so}],["element-attr",{requiresFor:!1,validator:so}],["element-state",{requiresFor:!0,associateWith:"a markup attribute",validator:io}],["event",{requiresFor:!1,validator:io}],["http-header",{requiresFor:!1}],["media-type",{requiresFor:!1,validator:function(e,t,n,r){try{const t=new zt(e);if(t.toString()!==e)throw new Error(`Input doesn't match its canonical form: "${t}".`)}catch(s){return Rn(`Invalid ${t} "${e}": ${s.message}.`,r,{hint:"Check that the MIME type has both a type and a sub-type, and that it's in a canonical form (e.g., `text/plain`).",elements:[n]}),!1}return!0}}],["scheme",{requiresFor:!1,validator:io}],["permission",{requiresFor:!1,validator:function(e,t,n,r){return e.startsWith('"')&&e.endsWith('"')?io(e.slice(1,-1),t,n,r):(Rn(`Invalid ${t} "${e}".`,r,{hint:`Check that the ${t} is quoted with double quotes.`,elements:[n]}),!1)}}]]),uo=[...lo.keys()];function po(e,t){let n="";switch(!0){case uo.some((t=>e.classList.contains(t))):n=[...e.classList].find((e=>lo.has(e))),function(e,t,n){const r=lo.get(t);if(r.requiresFor&&!n.dataset.dfnFor){const e=In`Definition of type "\`${t}\`" requires a ${"[data-dfn-for]"} attribute.`,{associateWith:s}=r,i=In`Use a ${"[data-dfn-for]"} attribute to associate this with ${s}.`;Rn(e,co,{hint:i,elements:[n]})}r.validator&&r.validator(e,t,n,co)}(t,n,e);break;case Ks.test(t):n=function(e,t){t.dataset.hasOwnProperty("idl")||(t.dataset.idl="");const n=t.closest("[data-dfn-for]");t!==n&&n?.dataset.dfnFor&&(t.dataset.dfnFor=n.dataset.dfnFor);if(!t.dataset.dfnFor){const n=In`Use a ${"[data-dfn-for]"} attribute to associate this dfn with a WebIDL interface.`;Rn(`Internal slot "${e}" must be associated with a WebIDL interface.`,co,{hint:n,elements:[t]})}t.matches(".export, [data-export]")||(t.dataset.noexport="");const r=e.endsWith(")")?"method":"attribute";if(!t.dataset.dfnType)return r;const s=["attribute","method"],{dfnType:i}=t.dataset;if(!s.includes(i)||r!==i){const n=In`Invalid ${"[data-dfn-type]"} attribute on internal slot.`,i=`The only allowed types are: ${Tn(s,{quotes:!0})}. The slot "${e}" seems to be a "${An(r)}"?`;return Rn(n,co,{hint:i,elements:[t]}),"dfn"}return i}(t,e)}if(!n&&!e.matches("[data-dfn-type]")){n=e.closest("[data-dfn-type]")?.dataset.dfnType}n&&!e.dataset.dfnType&&(e.dataset.dfnType=n)}function fo(e){switch(!0){case e.matches(".export.no-export"):Rn(In`Declares both "${"[no-export]"}" and "${"[export]"}" CSS class.`,co,{elements:[e],hint:"Please use only one."});break;case e.matches(".no-export, [data-noexport]"):if(e.matches("[data-export]")){Rn(In`Declares ${"[no-export]"} CSS class, but also has a "${"[data-export]"}" attribute.`,co,{elements:[e],hint:"Please chose only one."}),delete e.dataset.export}e.dataset.noexport="";break;case e.matches(":is(.export):not([data-noexport], .no-export)"):e.dataset.export=""}}function ho(){const e=document.querySelectorAll("dfn:is([data-dfn-type=''],:not([data-dfn-type]))");for(const t of e)t.dataset.dfnType="dfn";const t=document.querySelectorAll("dfn:not([data-noexport], [data-export], [data-dfn-type='dfn'], [data-cite])");for(const e of t)e.dataset.export=""}var mo=Object.freeze({__proto__:null,name:co,run:function(){for(const e of document.querySelectorAll("dfn")){const t=hn(e);if(ao(e,t),e.dataset.cite&&/\b#\b/.test(e.dataset.cite))continue;const[n]=t;po(e,n),fo(e),1===t.length&&n===rn(e.textContent)||(e.dataset.lt=t.join("|"))}s("plugins-done",ho)}});var go=Object.freeze({__proto__:null,name:"core/pluralize",run:function(e){if(!e.pluralize)return;const t=function(){const e=new Set;document.querySelectorAll("a:not([href])").forEach((t=>{const n=rn(t.textContent).toLowerCase();e.add(n),t.dataset.lt&&e.add(t.dataset.lt)}));const t=new Set;return document.querySelectorAll("dfn:not([data-lt-noDefault])").forEach((e=>{const n=rn(e.textContent).toLowerCase();t.add(n),e.dataset.lt&&e.dataset.lt.split("|").forEach((e=>t.add(e))),e.dataset.localLt&&e.dataset.localLt.split("|").forEach((e=>t.add(e)))})),function(n){const r=rn(n).toLowerCase(),s=Ut.isSingular(r)?Ut.plural(r):Ut.singular(r);return e.has(s)&&!t.has(s)?s:""}}();document.querySelectorAll("dfn:not([data-lt-no-plural]):not([data-lt-noDefault])").forEach((e=>{const n=[e.textContent];e.dataset.lt&&n.push(...e.dataset.lt.split("|")),e.dataset.localLt&&n.push(...e.dataset.localLt.split("|"));const r=new Set(n.map(t).filter((e=>e)));if(r.size){const t=e.dataset.plurals?e.dataset.plurals.split("|"):[],n=[...new Set([...t,...r])];e.dataset.plurals=n.join("|"),ao(e,n)}}))}});var bo=String.raw`span.example-title{text-transform:none}
848
+ </p>`}});var so=Object.freeze({__proto__:null,name:no,run:function(e){const t=document.querySelector("section#conformance");if(t&&!t.classList.contains("override")&&function(e,t){const n=[...Object.keys(Ni)];n.length&&(t.normativeReferences.add("RFC2119"),t.normativeReferences.add("RFC8174"));const r=pn(n.sort(),(e=>jt`<em class="rfc2119">${e}</em>`)),s=n.length>1,i=jt`
849
+ <h1>${ro.conformance}</h1>
850
+ <p>${ro.normativity}</p>
851
+ ${n.length?ro.keywordInterpretation(r,s):null}
852
+ `;e.prepend(...i.childNodes)}(t,e),!t&&Object.keys(Ni).length){An("Document uses RFC2119 keywords but lacks a conformance section.",no,{hint:'Please add a `<section id="conformance">`.'})}}});function io(e,t,n,r){try{switch(t){case"element-attr":return document.createAttribute(e),!0;case"element":return document.createElement(e),!0}}catch(s){En(`Invalid ${t} name "${e}": ${s.message}`,r,{hint:`Check that the ${t} name is allowed per the XML's Name production for ${t}.`,elements:[n]})}return!1}function oo(e,t,n,r){if(/^[a-z]+(-[a-z]+)*$/i.test(e))return!0;return En(`Invalid ${t} name "${e}".`,r,{hint:`Check that the ${t} name is allowed per the naming rules for this type.`,elements:[n]}),!1}const ao=new Cn;function co(e,t){for(const n of t)ao.has(n)||ao.set(n,new Set),ao.get(n).add(e)}const lo="core/dfn",uo=new Map([["abstract-op",{requiresFor:!1}],["attr-value",{requiresFor:!0,associateWith:"a markup attribute",validator:oo}],["element",{requiresFor:!1,validator:io}],["element-attr",{requiresFor:!1,validator:io}],["element-state",{requiresFor:!0,associateWith:"a markup attribute",validator:oo}],["event",{requiresFor:!1,validator:oo}],["http-header",{requiresFor:!1}],["media-type",{requiresFor:!1,validator:function(e,t,n,r){try{const t=new Ut(e);if(t.toString()!==e)throw new Error(`Input doesn't match its canonical form: "${t}".`)}catch(s){return En(`Invalid ${t} "${e}": ${s.message}.`,r,{hint:"Check that the MIME type has both a type and a sub-type, and that it's in a canonical form (e.g., `text/plain`).",elements:[n]}),!1}return!0}}],["scheme",{requiresFor:!1,validator:oo}],["permission",{requiresFor:!1,validator:function(e,t,n,r){return e.startsWith('"')&&e.endsWith('"')?oo(e.slice(1,-1),t,n,r):(En(`Invalid ${t} "${e}".`,r,{hint:`Check that the ${t} is quoted with double quotes.`,elements:[n]}),!1)}}]]),po=[...uo.keys()];function fo(e,t){let n="";switch(!0){case po.some((t=>e.classList.contains(t))):n=[...e.classList].find((e=>uo.has(e))),function(e,t,n){const r=uo.get(t);if(r.requiresFor&&!n.dataset.dfnFor){const e=Dn`Definition of type "\`${t}\`" requires a ${"[data-dfn-for]"} attribute.`,{associateWith:s}=r,i=Dn`Use a ${"[data-dfn-for]"} attribute to associate this with ${s}.`;En(e,lo,{hint:i,elements:[n]})}r.validator&&r.validator(e,t,n,lo)}(t,n,e);break;case Zs.test(t):n=function(e,t){t.dataset.hasOwnProperty("idl")||(t.dataset.idl="");const n=t.closest("[data-dfn-for]");t!==n&&n?.dataset.dfnFor&&(t.dataset.dfnFor=n.dataset.dfnFor);if(!t.dataset.dfnFor){const n=Dn`Use a ${"[data-dfn-for]"} attribute to associate this dfn with a WebIDL interface.`;En(`Internal slot "${e}" must be associated with a WebIDL interface.`,lo,{hint:n,elements:[t]})}t.matches(".export, [data-export]")||(t.dataset.noexport="");const r=e.endsWith(")")?"method":"attribute";if(!t.dataset.dfnType)return r;const s=["attribute","method"],{dfnType:i}=t.dataset;if(!s.includes(i)||r!==i){const n=Dn`Invalid ${"[data-dfn-type]"} attribute on internal slot.`,i=`The only allowed types are: ${Ln(s,{quotes:!0})}. The slot "${e}" seems to be a "${Tn(r)}"?`;return En(n,lo,{hint:i,elements:[t]}),"dfn"}return i}(t,e)}if(!n&&!e.matches("[data-dfn-type]")){n=e.closest("[data-dfn-type]")?.dataset.dfnType}n&&!e.dataset.dfnType&&(e.dataset.dfnType=n)}function ho(e){switch(!0){case e.matches(".export.no-export"):En(Dn`Declares both "${"[no-export]"}" and "${"[export]"}" CSS class.`,lo,{elements:[e],hint:"Please use only one."});break;case e.matches(".no-export, [data-noexport]"):if(e.matches("[data-export]")){En(Dn`Declares ${"[no-export]"} CSS class, but also has a "${"[data-export]"}" attribute.`,lo,{elements:[e],hint:"Please chose only one."}),delete e.dataset.export}e.dataset.noexport="";break;case e.matches(":is(.export):not([data-noexport], .no-export)"):e.dataset.export=""}}function mo(){const e=document.querySelectorAll("dfn:is([data-dfn-type=''],:not([data-dfn-type]))");for(const t of e)t.dataset.dfnType="dfn";const t=document.querySelectorAll("dfn:not([data-noexport], [data-export], [data-dfn-type='dfn'], [data-cite])");for(const e of t)e.dataset.export=""}var go=Object.freeze({__proto__:null,name:lo,run:function(){for(const e of document.querySelectorAll("dfn")){const t=mn(e);if(co(e,t),e.dataset.cite&&/\b#\b/.test(e.dataset.cite))continue;const[n]=t;fo(e,n),ho(e),1===t.length&&n===sn(e.textContent)||(e.dataset.lt=t.join("|"))}s("plugins-done",mo)}});var bo=Object.freeze({__proto__:null,name:"core/pluralize",run:function(e){if(!e.pluralize)return;const t=function(){const e=new Set;document.querySelectorAll("a:not([href])").forEach((t=>{const n=sn(t.textContent).toLowerCase();e.add(n),t.dataset.lt&&e.add(t.dataset.lt)}));const t=new Set;return document.querySelectorAll("dfn:not([data-lt-noDefault])").forEach((e=>{const n=sn(e.textContent).toLowerCase();t.add(n),e.dataset.lt&&e.dataset.lt.split("|").forEach((e=>t.add(e))),e.dataset.localLt&&e.dataset.localLt.split("|").forEach((e=>t.add(e)))})),function(n){const r=sn(n).toLowerCase(),s=qt.isSingular(r)?qt.plural(r):qt.singular(r);return e.has(s)&&!t.has(s)?s:""}}();document.querySelectorAll("dfn:not([data-lt-no-plural]):not([data-lt-noDefault])").forEach((e=>{const n=[e.textContent];e.dataset.lt&&n.push(...e.dataset.lt.split("|")),e.dataset.localLt&&n.push(...e.dataset.localLt.split("|"));const r=new Set(n.map(t).filter((e=>e)));if(r.size){const t=e.dataset.plurals?e.dataset.plurals.split("|"):[],n=[...new Set([...t,...r])];e.dataset.plurals=n.join("|"),co(e,n)}}))}});var yo=String.raw`span.example-title{text-transform:none}
853
853
  :is(aside,div).example,div.illegal-example{padding:.5em;margin:1em 0;position:relative;clear:both}
854
854
  div.illegal-example{color:red}
855
855
  div.illegal-example p{color:#000}
856
856
  :is(aside,div).example{border-left-width:.5em;border-left-style:solid;border-color:#e0cb52;background:#fcfaee}
857
857
  aside.example div.example{border-left-width:.1em;border-color:#999;background:#fff}
858
- .example pre{background-color:rgba(0,0,0,.03)}`;const yo=sn({en:{example:"Example"},nl:{example:"Voorbeeld"},es:{example:"Ejemplo"},ko:{example:"예시"},ja:{example:"例"},de:{example:"Beispiel"},zh:{example:"例"}});function wo(e,t,n){n.title=e.title,n.title&&e.removeAttribute("title");const r=t>0?` ${t}`:"",s=n.title?Ot`<span class="example-title">: ${n.title}</span>`:"";return Ot`<div class="marker">
859
- <a class="self-link">${yo.example}<bdi>${r}</bdi></a
858
+ .example pre{background-color:rgba(0,0,0,.03)}`;const wo=on({en:{example:"Example"},nl:{example:"Voorbeeld"},es:{example:"Ejemplo"},ko:{example:"예시"},ja:{example:"例"},de:{example:"Beispiel"},zh:{example:"例"}});function vo(e,t,n){n.title=e.title,n.title&&e.removeAttribute("title");const r=t>0?` ${t}`:"",s=n.title?jt`<span class="example-title">: ${n.title}</span>`:"";return jt`<div class="marker">
859
+ <a class="self-link">${wo.example}<bdi>${r}</bdi></a
860
860
  >${s}
861
- </div>`}var vo=Object.freeze({__proto__:null,name:"core/examples",run:function(){const e=document.querySelectorAll("pre.example, pre.illegal-example, aside.example");if(!e.length)return;document.head.insertBefore(Ot`<style>
862
- ${bo}
863
- </style>`,document.querySelector("link"));let t=0;e.forEach((e=>{const n=e.classList.contains("illegal-example"),r={number:t,illegal:n},{title:s}=e;if("aside"===e.localName){++t;const n=wo(e,t,r);e.prepend(n);const i=fn(e,"example",s||String(t));n.querySelector("a.self-link").href=`#${i}`}else{const n=!!e.closest("aside");n||++t,r.content=e.innerHTML,e.classList.remove("example","illegal-example");const i=e.id?e.id:null;i&&e.removeAttribute("id");const o=wo(e,n?0:t,r),a=Ot`<div class="example" id="${i}">
861
+ </div>`}var $o=Object.freeze({__proto__:null,name:"core/examples",run:function(){const e=document.querySelectorAll("pre.example, pre.illegal-example, aside.example");if(!e.length)return;document.head.insertBefore(jt`<style>
862
+ ${yo}
863
+ </style>`,document.querySelector("link"));let t=0;e.forEach((e=>{const n=e.classList.contains("illegal-example"),r={number:t,illegal:n},{title:s}=e;if("aside"===e.localName){++t;const n=vo(e,t,r);e.prepend(n);const i=hn(e,"example",s||String(t));n.querySelector("a.self-link").href=`#${i}`}else{const n=!!e.closest("aside");n||++t,r.content=e.innerHTML,e.classList.remove("example","illegal-example");const i=e.id?e.id:null;i&&e.removeAttribute("id");const o=vo(e,n?0:t,r),a=jt`<div class="example" id="${i}">
864
864
  ${o} ${e.cloneNode(!0)}
865
- </div>`;fn(a,"example",s||String(t));a.querySelector("a.self-link").href=`#${a.id}`,e.replaceWith(a)}}))}});var $o=String.raw`.issue-label{text-transform:initial}
865
+ </div>`;hn(a,"example",s||String(t));a.querySelector("a.self-link").href=`#${a.id}`,e.replaceWith(a)}}))}});var ko=String.raw`.issue-label{text-transform:initial}
866
866
  .warning>p:first-child{margin-top:0}
867
867
  .warning{padding:.5em;border-left-width:.5em;border-left-style:solid}
868
868
  span.warning{padding:.1em .5em .15em}
@@ -872,31 +872,31 @@ span.warning{padding:.1em .5em .15em}
872
872
  .warning-title:before{content:"⚠";font-size:1.3em;float:left;padding-right:.3em;margin-top:-.3em}
873
873
  li.task-list-item{list-style:none}
874
874
  input.task-list-item-checkbox{margin:0 .35em .25em -1.6em;vertical-align:middle}
875
- .issue a.respec-gh-label{padding:5px;margin:0 2px 0 2px;font-size:10px;text-transform:none;text-decoration:none;font-weight:700;border-radius:4px;position:relative;bottom:2px;border:none;display:inline-block}`;const ko="core/issues-notes",xo=sn({en:{editors_note:"Editor's note",feature_at_risk:"(Feature at Risk) Issue",issue:"Issue",issue_summary:"Issue summary",no_issues_in_spec:"There are no issues listed in this specification.",note:"Note",warning:"Warning"},ja:{note:"注",editors_note:"編者注",feature_at_risk:"(変更の可能性のある機能) Issue",issue:"Issue",issue_summary:"Issue の要約",no_issues_in_spec:"この仕様には未解決の issues は含まれていません.",warning:"警告"},nl:{editors_note:"Redactionele noot",issue_summary:"Lijst met issues",no_issues_in_spec:"Er zijn geen problemen vermeld in deze specificatie.",note:"Noot",warning:"Waarschuwing"},es:{editors_note:"Nota de editor",issue:"Cuestión",issue_summary:"Resumen de la cuestión",note:"Nota",no_issues_in_spec:"No hay problemas enumerados en esta especificación.",warning:"Aviso"},de:{editors_note:"Redaktioneller Hinweis",issue:"Frage",issue_summary:"Offene Fragen",no_issues_in_spec:"Diese Spezifikation enthält keine offenen Fragen.",note:"Hinweis",warning:"Warnung"},zh:{editors_note:"编者注",feature_at_risk:"(有可能变动的特性)Issue",issue:"Issue",issue_summary:"Issue 总结",no_issues_in_spec:"本规范中未列出任何 issue。",note:"注",warning:"警告"}});function _o(e,t,n){const r=function(){if(document.querySelector(".issue[data-number]"))return e=>{if(e.dataset.number)return Number(e.dataset.number)};let e=0;return t=>{if(t.classList.contains("issue")&&"span"!==t.localName)return++e}}(),s=document.createElement("ul");e.forEach((e=>{const{type:i,displayType:o,isFeatureAtRisk:a}=function(e){const t=e.classList.contains("issue"),n=e.classList.contains("warning"),r=e.classList.contains("ednote"),s=e.classList.contains("atrisk"),i=t?"issue":n?"warning":r?"ednote":"note",o=t?s?xo.feature_at_risk:xo.issue:n?xo.warning:r?xo.editors_note:xo.note;return{type:i,displayType:o,isFeatureAtRisk:s}}(e),c="issue"===i,l="span"===e.localName,{number:u}=e.dataset,d={type:i,inline:l,title:e.title,number:r(e)};if(!l){const r=Ot`<div class="${a?`${i} atrisk`:i}" role="${"note"===i?"note":null}"></div>`,l=document.createElement("span"),p=Ot`<div role="heading" class="${`${i}-title marker`}">${l}</div>`;fn(p,"h",i);let f,h=o;if(e.id?(r.id=e.id,e.removeAttribute("id")):fn(r,"issue-container",d.number?`number-${d.number}`:""),c){if(void 0!==d.number&&(h+=` ${d.number}`),e.dataset.hasOwnProperty("number")){const e=function(e,t,{isFeatureAtRisk:n=!1}={}){if(!n&&t.issueBase)return Ot`<a href="${t.issueBase+e}" />`;if(n&&t.atRiskBase)return Ot`<a href="${t.atRiskBase+e}" />`}(u,n,{isFeatureAtRisk:a});if(e&&(l.before(e),e.append(l)),l.classList.add("issue-number"),f=t.get(u),!f){En(`Failed to fetch issue number ${u}.`,ko)}f&&!d.title&&(d.title=f.title)}s.append(function(e,t,n){const r=`${e}${t.number?` ${t.number}`:""}`,s=t.title?Ot`<span style="text-transform: none">: ${t.title}</span>`:"";return Ot`<li><a href="${`#${n}`}">${r}</a>${s}</li>`}(xo.issue,d,r.id))}if(l.textContent=h,d.title){e.removeAttribute("title");const{repoURL:t=""}=n.github||{},s=f?f.labels:[];f&&"CLOSED"===f.state&&r.classList.add("closed"),p.append(function(e,t,n){const r=e.map((e=>function(e,t){const{color:n,name:r}=e,s=new URL("./issues/",t);s.searchParams.set("q",`is:issue is:open label:"${e.name}"`);const i=function(e){const[t,n,r]=[e.slice(0,2),e.slice(2,4),e.slice(4,6)],[s,i,o]=[t,n,r].map((e=>parseInt(e,16)/255)).map((e=>e<=.04045?e/12.92:((e+.055)/1.055)**2.4));return.2126*s+.7152*i+.0722*o>.179?"#000":"#fff"}(n),o=`GitHub label: ${r}`;return Ot` <a
875
+ .issue a.respec-gh-label{padding:5px;margin:0 2px 0 2px;font-size:10px;text-transform:none;text-decoration:none;font-weight:700;border-radius:4px;position:relative;bottom:2px;border:none;display:inline-block}`;const xo="core/issues-notes",_o=on({en:{editors_note:"Editor's note",feature_at_risk:"(Feature at Risk) Issue",issue:"Issue",issue_summary:"Issue summary",no_issues_in_spec:"There are no issues listed in this specification.",note:"Note",warning:"Warning"},ja:{note:"注",editors_note:"編者注",feature_at_risk:"(変更の可能性のある機能) Issue",issue:"Issue",issue_summary:"Issue の要約",no_issues_in_spec:"この仕様には未解決の issues は含まれていません.",warning:"警告"},nl:{editors_note:"Redactionele noot",issue_summary:"Lijst met issues",no_issues_in_spec:"Er zijn geen problemen vermeld in deze specificatie.",note:"Noot",warning:"Waarschuwing"},es:{editors_note:"Nota de editor",issue:"Cuestión",issue_summary:"Resumen de la cuestión",note:"Nota",no_issues_in_spec:"No hay problemas enumerados en esta especificación.",warning:"Aviso"},de:{editors_note:"Redaktioneller Hinweis",issue:"Frage",issue_summary:"Offene Fragen",no_issues_in_spec:"Diese Spezifikation enthält keine offenen Fragen.",note:"Hinweis",warning:"Warnung"},zh:{editors_note:"编者注",feature_at_risk:"(有可能变动的特性)Issue",issue:"Issue",issue_summary:"Issue 总结",no_issues_in_spec:"本规范中未列出任何 issue。",note:"注",warning:"警告"}});function So(e,t,n){const r=function(){if(document.querySelector(".issue[data-number]"))return e=>{if(e.dataset.number)return Number(e.dataset.number)};let e=0;return t=>{if(t.classList.contains("issue")&&"span"!==t.localName)return++e}}(),s=document.createElement("ul");e.forEach((e=>{const{type:i,displayType:o,isFeatureAtRisk:a}=function(e){const t=e.classList.contains("issue"),n=e.classList.contains("warning"),r=e.classList.contains("ednote"),s=e.classList.contains("atrisk"),i=t?"issue":n?"warning":r?"ednote":"note",o=t?s?_o.feature_at_risk:_o.issue:n?_o.warning:r?_o.editors_note:_o.note;return{type:i,displayType:o,isFeatureAtRisk:s}}(e),c="issue"===i,l="span"===e.localName,{number:u}=e.dataset,d={type:i,inline:l,title:e.title,number:r(e)};if(!l){const r=jt`<div class="${a?`${i} atrisk`:i}" role="${"note"===i?"note":null}"></div>`,l=document.createElement("span"),p=jt`<div role="heading" class="${`${i}-title marker`}">${l}</div>`;hn(p,"h",i);let f,h=o;if(e.id?(r.id=e.id,e.removeAttribute("id")):hn(r,"issue-container",d.number?`number-${d.number}`:""),c){if(void 0!==d.number&&(h+=` ${d.number}`),e.dataset.hasOwnProperty("number")){const e=function(e,t,{isFeatureAtRisk:n=!1}={}){if(!n&&t.issueBase)return jt`<a href="${t.issueBase+e}" />`;if(n&&t.atRiskBase)return jt`<a href="${t.atRiskBase+e}" />`}(u,n,{isFeatureAtRisk:a});if(e&&(l.before(e),e.append(l)),l.classList.add("issue-number"),f=t.get(u),!f){An(`Failed to fetch issue number ${u}.`,xo)}f&&!d.title&&(d.title=f.title)}s.append(function(e,t,n){const r=`${e}${t.number?` ${t.number}`:""}`,s=t.title?jt`<span style="text-transform: none">: ${t.title}</span>`:"";return jt`<li><a href="${`#${n}`}">${r}</a>${s}</li>`}(_o.issue,d,r.id))}if(l.textContent=h,d.title){e.removeAttribute("title");const{repoURL:t=""}=n.github||{},s=f?f.labels:[];f&&"CLOSED"===f.state&&r.classList.add("closed"),p.append(function(e,t,n){const r=e.map((e=>function(e,t){const{color:n,name:r}=e,s=new URL("./issues/",t);s.searchParams.set("q",`is:issue is:open label:"${e.name}"`);const i=function(e){const[t,n,r]=[e.slice(0,2),e.slice(2,4),e.slice(4,6)],[s,i,o]=[t,n,r].map((e=>parseInt(e,16)/255)).map((e=>e<=.04045?e/12.92:((e+.055)/1.055)**2.4));return.2126*s+.7152*i+.0722*o>.179?"#000":"#fff"}(n),o=`GitHub label: ${r}`;return jt` <a
876
876
  class="respec-gh-label"
877
877
  style="${`background-color: #${n}; color: ${i}`}"
878
878
  href="${s.href}"
879
879
  aria-label="${o}"
880
880
  >${r}</a
881
- >`}(e,n)));r.length&&r.unshift(document.createTextNode(" "));return Ot`<span class="issue-label">: ${t}${r}</span>`}(s,d.title,t))}let m=e;e.replaceWith(r),m.classList.remove(i),m.removeAttribute("data-number"),f&&!m.innerHTML.trim()&&(m=document.createRange().createContextualFragment(f.bodyHTML)),r.append(p,m);const g=wn(p,"section").length+2;p.setAttribute("aria-level",g)}})),function(e){const t=document.getElementById("issue-summary");if(!t)return;const n=t.querySelector("h2, h3, h4, h5, h6");e.hasChildNodes()?t.append(e):t.append(Ot`<p>${xo.no_issues_in_spec}</p>`),(!n||n&&n!==t.firstElementChild)&&t.insertAdjacentHTML("afterbegin",`<h1>${xo.issue_summary}</h1>`)}(s)}var Co=Object.freeze({__proto__:null,name:ko,run:async function(e){const t=document.querySelectorAll(".issue, .note, .warning, .ednote"),n=Array.from(t).filter((e=>e instanceof HTMLElement));if(!n.length)return;const r=await async function(e){if(!e||!e.apiBase)return new Map;const t=[...document.querySelectorAll(".issue[data-number]")].map((e=>Number.parseInt(e.dataset.number,10))).filter((e=>e));if(!t.length)return new Map;const n=new URL("issues",`${e.apiBase}/${e.fullName}/`);n.searchParams.set("issues",t.join(","));const r=await fetch(n.href);if(!r.ok)return Rn(`Error fetching issues from GitHub. (HTTP Status ${r.status}).`,ko),new Map;const s=await r.json();return new Map(Object.entries(s))}(e.github),{head:s}=document;s.insertBefore(Ot`<style>
882
- ${$o}
883
- </style>`,s.querySelector("link")),_o(n,r,e),document.querySelectorAll(".ednote").forEach((e=>{e.classList.remove("ednote"),e.classList.add("note")}))}});const So="core/best-practices",Ro={en:{best_practice:"Best Practice "},ja:{best_practice:"最良実施例 "},de:{best_practice:"Musterbeispiel "},zh:{best_practice:"最佳实践 "}},Eo=sn(Ro),Ao=c in Ro?c:"en";var To=Object.freeze({__proto__:null,name:So,run:function(){const e=document.querySelectorAll(".practicelab"),t=document.getElementById("bp-summary"),n=t?document.createElement("ul"):null;if([...e].forEach(((e,t)=>{const r=fn(e,"bp"),s=Ot`<a class="marker self-link" href="${`#${r}`}"
884
- ><bdi lang="${Ao}">${Eo.best_practice}${t+1}</bdi></a
885
- >`;if(n){const t=Ot`<li>${s}: ${kn(e)}</li>`;n.appendChild(t)}const i=e.closest("div");if(!i)return void e.classList.add("advisement");i.classList.add("advisement");const o=Ot`${s.cloneNode(!0)}: ${e}`;i.prepend(...o.childNodes)})),e.length)t&&(t.appendChild(Ot`<h1>Best Practices Summary</h1>`),t.appendChild(n));else if(t){En("Using best practices summary (#bp-summary) but no best practices found.",So),t.remove()}}});const Lo="core/figures",Po=sn({en:{list_of_figures:"List of Figures",fig:"Figure "},ja:{fig:"図 ",list_of_figures:"図のリスト"},ko:{fig:"그림 ",list_of_figures:"그림 목록"},nl:{fig:"Figuur ",list_of_figures:"Lijst met figuren"},es:{fig:"Figura ",list_of_figures:"Lista de Figuras"},zh:{fig:"图 ",list_of_figures:"规范中包含的图"},de:{fig:"Abbildung",list_of_figures:"Abbildungsverzeichnis"}});var Io=Object.freeze({__proto__:null,name:Lo,run:function(){const e=function(){const e=[];return document.querySelectorAll("figure").forEach(((t,n)=>{const r=t.querySelector("figcaption");if(r)!function(e,t,n){const r=t.textContent;fn(e,"fig",r),bn(t,Ot`<span class="fig-title"></span>`),t.prepend(Ot`<a class="self-link" href="#${e.id}"
886
- >${Po.fig}<bdi class="figno">${n+1}</bdi></a
887
- >`," ")}(t,r,n),e.push(function(e,t){const n=t.cloneNode(!0);return n.querySelectorAll("a").forEach((e=>{mn(e,"span").removeAttribute("href")})),Ot`<li class="tofline">
881
+ >`}(e,n)));r.length&&r.unshift(document.createTextNode(" "));return jt`<span class="issue-label">: ${t}${r}</span>`}(s,d.title,t))}let m=e;e.replaceWith(r),m.classList.remove(i),m.removeAttribute("data-number"),f&&!m.innerHTML.trim()&&(m=document.createRange().createContextualFragment(f.bodyHTML)),r.append(p,m);const g=vn(p,"section").length+2;p.setAttribute("aria-level",g)}})),function(e){const t=document.getElementById("issue-summary");if(!t)return;const n=t.querySelector("h2, h3, h4, h5, h6");e.hasChildNodes()?t.append(e):t.append(jt`<p>${_o.no_issues_in_spec}</p>`),(!n||n&&n!==t.firstElementChild)&&t.insertAdjacentHTML("afterbegin",`<h1>${_o.issue_summary}</h1>`)}(s)}var Co=Object.freeze({__proto__:null,name:xo,run:async function(e){const t=document.querySelectorAll(".issue, .note, .warning, .ednote"),n=Array.from(t).filter((e=>e instanceof HTMLElement));if(!n.length)return;const r=await async function(e){if(!e||!e.apiBase)return new Map;const t=[...document.querySelectorAll(".issue[data-number]")].map((e=>Number.parseInt(e.dataset.number,10))).filter((e=>e));if(!t.length)return new Map;const n=new URL("issues",`${e.apiBase}/${e.fullName}/`);n.searchParams.set("issues",t.join(","));const r=await fetch(n.href);if(!r.ok)return En(`Error fetching issues from GitHub. (HTTP Status ${r.status}).`,xo),new Map;const s=await r.json();return new Map(Object.entries(s))}(e.github),{head:s}=document;s.insertBefore(jt`<style>
882
+ ${ko}
883
+ </style>`,s.querySelector("link")),So(n,r,e),document.querySelectorAll(".ednote").forEach((e=>{e.classList.remove("ednote"),e.classList.add("note")}))}});const Ro="core/best-practices",Eo={en:{best_practice:"Best Practice "},ja:{best_practice:"最良実施例 "},de:{best_practice:"Musterbeispiel "},zh:{best_practice:"最佳实践 "}},Ao=on(Eo),To=c in Eo?c:"en";var Lo=Object.freeze({__proto__:null,name:Ro,run:function(){const e=document.querySelectorAll(".practicelab"),t=document.getElementById("bp-summary"),n=t?document.createElement("ul"):null;if([...e].forEach(((e,t)=>{const r=hn(e,"bp"),s=jt`<a class="marker self-link" href="${`#${r}`}"
884
+ ><bdi lang="${To}">${Ao.best_practice}${t+1}</bdi></a
885
+ >`;if(n){const t=jt`<li>${s}: ${xn(e)}</li>`;n.appendChild(t)}const i=e.closest("div");if(!i)return void e.classList.add("advisement");i.classList.add("advisement");const o=jt`${s.cloneNode(!0)}: ${e}`;i.prepend(...o.childNodes)})),e.length)t&&(t.appendChild(jt`<h1>Best Practices Summary</h1>`),t.appendChild(n));else if(t){An("Using best practices summary (#bp-summary) but no best practices found.",Ro),t.remove()}}});const Po="core/figures",Io=on({en:{list_of_figures:"List of Figures",fig:"Figure "},ja:{fig:"図 ",list_of_figures:"図のリスト"},ko:{fig:"그림 ",list_of_figures:"그림 목록"},nl:{fig:"Figuur ",list_of_figures:"Lijst met figuren"},es:{fig:"Figura ",list_of_figures:"Lista de Figuras"},zh:{fig:"图 ",list_of_figures:"规范中包含的图"},de:{fig:"Abbildung",list_of_figures:"Abbildungsverzeichnis"}});var Do=Object.freeze({__proto__:null,name:Po,run:function(){const e=function(){const e=[];return document.querySelectorAll("figure").forEach(((t,n)=>{const r=t.querySelector("figcaption");if(r)!function(e,t,n){const r=t.textContent;hn(e,"fig",r),yn(t,jt`<span class="fig-title"></span>`),t.prepend(jt`<a class="self-link" href="#${e.id}"
886
+ >${Io.fig}<bdi class="figno">${n+1}</bdi></a
887
+ >`," ")}(t,r,n),e.push(function(e,t){const n=t.cloneNode(!0);return n.querySelectorAll("a").forEach((e=>{gn(e,"span").removeAttribute("href")})),jt`<li class="tofline">
888
888
  <a class="tocxref" href="${`#${e}`}">${n.childNodes}</a>
889
- </li>`}(t.id,r));else{En("Found a `<figure>` without a `<figcaption>`.",Lo,{elements:[t]})}})),e}(),t=document.getElementById("tof");e.length&&t&&(!function(e){if(e.classList.contains("appendix")||e.classList.contains("introductory")||e.closest("section"))return;const t=yn(e);t.every((e=>e.classList.contains("introductory")))?e.classList.add("introductory"):t.some((e=>e.classList.contains("appendix")))&&e.classList.add("appendix")}(t),t.append(Ot`<h1>${Po.list_of_figures}</h1>`,Ot`<ul class="tof">
889
+ </li>`}(t.id,r));else{An("Found a `<figure>` without a `<figcaption>`.",Po,{elements:[t]})}})),e}(),t=document.getElementById("tof");e.length&&t&&(!function(e){if(e.classList.contains("appendix")||e.classList.contains("introductory")||e.closest("section"))return;const t=wn(e);t.every((e=>e.classList.contains("introductory")))?e.classList.add("introductory"):t.some((e=>e.classList.contains("appendix")))&&e.classList.add("appendix")}(t),t.append(jt`<h1>${Io.list_of_figures}</h1>`,jt`<ul class="tof">
890
890
  ${e}
891
- </ul>`))}});const Do=sn({en:{list_of_tables:"List of Tables",table:"Table "}});var No=Object.freeze({__proto__:null,name:"core/tables",run:function(){const e=function(){const e=[];return[...document.querySelectorAll("table.numbered")].filter((e=>!!e.querySelector("caption"))).forEach(((t,n)=>{const r=t.querySelector("caption");!function(e,t,n){const r=t.textContent;fn(e,"table",r),bn(t,Ot`<span class="table-title"></span>`),t.prepend(Ot`<a class="self-link" href="#${e.id}"
892
- >${Do.table}<bdi class="tableno">${n+1}</bdi></a
893
- >`," ")}(t,r,n),e.push(function(e,t){const n=t.cloneNode(!0);for(const e of n.querySelectorAll("a"))mn(e,"span",{copyAttributes:!1});return Ot`<li>
891
+ </ul>`))}});const No=on({en:{list_of_tables:"List of Tables",table:"Table "}});var Oo=Object.freeze({__proto__:null,name:"core/tables",run:function(){const e=function(){const e=[];return[...document.querySelectorAll("table.numbered")].filter((e=>!!e.querySelector("caption"))).forEach(((t,n)=>{const r=t.querySelector("caption");!function(e,t,n){const r=t.textContent;hn(e,"table",r),yn(t,jt`<span class="table-title"></span>`),t.prepend(jt`<a class="self-link" href="#${e.id}"
892
+ >${No.table}<bdi class="tableno">${n+1}</bdi></a
893
+ >`," ")}(t,r,n),e.push(function(e,t){const n=t.cloneNode(!0);for(const e of n.querySelectorAll("a"))gn(e,"span",{copyAttributes:!1});return jt`<li>
894
894
  <a class="tocxref" href="${`#${e}`}"
895
895
  >${n.childNodes}</a
896
896
  >
897
- </li>`}(t.id,r))})),e}(),t=document.querySelector("section#list-of-tables");e.length&&t&&(!function(e){if(e.matches(".appendix, .introductory")||e.closest("section"))return;const t=yn(e);t.every((e=>e.classList.contains("introductory")))?e.classList.add("introductory"):t.some((e=>e.classList.contains("appendix")))&&e.classList.add("appendix")}(t),t.append(Ot`<h1>${Do.list_of_tables}</h1>`,Ot`<ul class="list-of-tables">
897
+ </li>`}(t.id,r))})),e}(),t=document.querySelector("section#list-of-tables");e.length&&t&&(!function(e){if(e.matches(".appendix, .introductory")||e.closest("section"))return;const t=wn(e);t.every((e=>e.classList.contains("introductory")))?e.classList.add("introductory"):t.some((e=>e.classList.contains("appendix")))&&e.classList.add("appendix")}(t),t.append(jt`<h1>${No.list_of_tables}</h1>`,jt`<ul class="list-of-tables">
898
898
  ${e}
899
- </ul>`))}});const Oo=new Set(["callback interface","callback","dictionary","enum","interface mixin","interface","typedef"]);function jo(e,t,{parent:n=""}={}){switch(e.type){case"constructor":case"operation":return function(e,t,n){if(n.includes("!overload"))return Mo(e,t,n);return Mo(e,t,`${n}()`,n)}(e,n,t);default:return Mo(e,n,t)}}function Mo(e,t,...n){const{type:r}=e;for(const e of n){let n="enum-value"===r&&""===e?"the-empty-string":e,s=Uo(n,t,e,r);if(0===s.length&&""!==t){n=`${t}.${n}`;const e=oo.get(n);e&&1===e.size&&(s=[...e],ao(s[0],[n]))}else n=e;if(s.length>1){Rn(`WebIDL identifier \`${e}\` ${t?`for \`${t}\``:""} is defined multiple times`,e,{title:"Duplicate definition.",elements:s})}if(s.length)return s[0]}}function zo(e,t,n,r){if(!e.id){const t=n.toLowerCase(),s=t?`${t}-`:"";let i=r.toLowerCase().replace(/[()]/g,"").replace(/\s/g,"-");""===i&&(i="the-empty-string",e.setAttribute("aria-label","the empty string")),e.id=`dom-${s}${i}`}switch(e.dataset.idl=t.type,e.dataset.title=e.textContent,e.dataset.dfnFor=n,t.type){case"operation":case"attribute":case"field":e.dataset.type=qo(t)}switch(e.querySelector("code")||e.closest("code")||!e.children||bn(e,e.ownerDocument.createElement("code")),t.type){case"attribute":case"constructor":case"operation":!function(e,t){const{local:n,exportable:r}=t,s=e.dataset.lt?new Set(e.dataset.lt.split("|")):new Set;for(const e of r)s.add(e);n.filter((e=>s.has(e))).forEach((e=>s.delete(e))),e.dataset.lt=[...s].join("|"),e.dataset.localLt=n.join("|"),ao(e,[...n,...r])}(e,function(e,t,n){const{type:r}=e,s=`${t}.${n}`;switch(r){case"constructor":case"operation":{const t=`${n}()`,r=`${s}()`,i=function(e,t){const n=[];if(0===t.length)return n;const r=[],s=[];for(const{name:e,optional:n,variadic:i}of t)n||i?s.push(e):r.push(e);const i=r.join(", "),o=`${e}(${i})`;n.push(o);const a=s.map(((t,n)=>{const i=[...r,...s.slice(0,n+1)].join(", ");return`${e}(${i})`}));return n.push(...a),n}(n,e.arguments);return{local:[s,r,n],exportable:[t,...i]}}case"attribute":return{local:[s],exportable:[n]}}}(t,n,r))}return e}function Uo(e,t,n,r){const s=oo.get(e);if(!s||0===s.size)return[];const i=[...s],o=i.filter((e=>{if("dfn"===e.dataset.dfnType)return!1;const n=e.closest("[data-dfn-for]");return n&&n.dataset.dfnFor===t}));if(0===o.length&&""===t&&1===i.length)return i[0].textContent===n?i:[];if(Oo.has(r)&&i.length){const e=i.find((e=>e.textContent.trim()===n));if(e)return[e]}return o}function qo(e={}){const{idlType:t,generic:n,union:r}=e;return void 0===t?"":"string"==typeof t?t:n||(r?t.map(qo).join("|"):qo(t))}const Wo=function(){const e=document.createElement("button");return e.innerHTML='<svg height="16" viewBox="0 0 14 16" width="14"><path fill-rule="evenodd" d="M2 13h4v1H2v-1zm5-6H2v1h5V7zm2 3V8l-3 3 3 3v-2h5v-2H9zM4.5 9H2v1h2.5V9zM2 12h2.5v-1H2v1zm9 1h1v2c-.02.28-.11.52-.3.7-.19.18-.42.28-.7.3H1c-.55 0-1-.45-1-1V4c0-.55.45-1 1-1h3c0-1.11.89-2 2-2 1.11 0 2 .89 2 2h3c.55 0 1 .45 1 1v5h-1V6H1v9h10v-2zM2 5h8c0-.55-.45-1-1-1H8c-.55 0-1-.45-1-1s-.45-1-1-1-1 .45-1 1-.45 1-1 1H3c-.55 0-1 .45-1 1z"/></svg>',e.title="Copy IDL to clipboard",e.classList.add("respec-button-copy-paste","removeOnSave"),e}();function Fo(e){const t=e.closest("pre.idl").cloneNode(!0);t.querySelector(".idlHeader").remove();const{textContent:n}=t,r=Wo.cloneNode(!0);r.addEventListener("click",(()=>{navigator.clipboard.writeText(n)})),e.append(r)}var Bo=Object.freeze({__proto__:null,addCopyIDLButton:Fo,name:"core/webidl-clipboard"});var Ho=String.raw`pre.idl{padding:1em;position:relative}
899
+ </ul>`))}});const jo=new Set(["callback interface","callback","dictionary","enum","interface mixin","interface","typedef"]);function Mo(e,t,{parent:n=""}={}){switch(e.type){case"constructor":case"operation":return function(e,t,n){if(n.includes("!overload"))return zo(e,t,n);return zo(e,t,`${n}()`,n)}(e,n,t);default:return zo(e,n,t)}}function zo(e,t,...n){const{type:r}=e;for(const e of n){let n="enum-value"===r&&""===e?"the-empty-string":e,s=qo(n,t,e,r);if(0===s.length&&""!==t){n=`${t}.${n}`;const e=ao.get(n);e&&1===e.size&&(s=[...e],co(s[0],[n]))}else n=e;if(s.length>1){En(`WebIDL identifier \`${e}\` ${t?`for \`${t}\``:""} is defined multiple times`,e,{title:"Duplicate definition.",elements:s})}if(s.length)return s[0]}}function Uo(e,t,n,r){if(!e.id){const t=n.toLowerCase(),s=t?`${t}-`:"";let i=r.toLowerCase().replace(/[()]/g,"").replace(/\s/g,"-");""===i&&(i="the-empty-string",e.setAttribute("aria-label","the empty string")),e.id=`dom-${s}${i}`}switch(e.dataset.idl=t.type,e.dataset.title=e.textContent,e.dataset.dfnFor=n,t.type){case"operation":case"attribute":case"field":e.dataset.type=Wo(t)}switch(e.querySelector("code")||e.closest("code")||!e.children||yn(e,e.ownerDocument.createElement("code")),t.type){case"attribute":case"constructor":case"operation":!function(e,t){const{local:n,exportable:r}=t,s=e.dataset.lt?new Set(e.dataset.lt.split("|")):new Set;for(const e of r)s.add(e);n.filter((e=>s.has(e))).forEach((e=>s.delete(e))),e.dataset.lt=[...s].join("|"),e.dataset.localLt=n.join("|"),co(e,[...n,...r])}(e,function(e,t,n){const{type:r}=e,s=`${t}.${n}`;switch(r){case"constructor":case"operation":{const t=`${n}()`,r=`${s}()`,i=function(e,t){const n=[];if(0===t.length)return n;const r=[],s=[];for(const{name:e,optional:n,variadic:i}of t)n||i?s.push(e):r.push(e);const i=r.join(", "),o=`${e}(${i})`;n.push(o);const a=s.map(((t,n)=>{const i=[...r,...s.slice(0,n+1)].join(", ");return`${e}(${i})`}));return n.push(...a),n}(n,e.arguments);return{local:[s,r,n],exportable:[t,...i]}}case"attribute":return{local:[s],exportable:[n]}}}(t,n,r))}return e}function qo(e,t,n,r){const s=ao.get(e);if(!s||0===s.size)return[];const i=[...s],o=i.filter((e=>{if("dfn"===e.dataset.dfnType)return!1;const n=e.closest("[data-dfn-for]");return n&&n.dataset.dfnFor===t}));if(0===o.length&&""===t&&1===i.length)return i[0].textContent===n?i:[];if(jo.has(r)&&i.length){const e=i.find((e=>e.textContent.trim()===n));if(e)return[e]}return o}function Wo(e={}){const{idlType:t,generic:n,union:r}=e;return void 0===t?"":"string"==typeof t?t:n||(r?t.map(Wo).join("|"):Wo(t))}const Fo=function(){const e=document.createElement("button");return e.innerHTML='<svg height="16" viewBox="0 0 14 16" width="14"><path fill-rule="evenodd" d="M2 13h4v1H2v-1zm5-6H2v1h5V7zm2 3V8l-3 3 3 3v-2h5v-2H9zM4.5 9H2v1h2.5V9zM2 12h2.5v-1H2v1zm9 1h1v2c-.02.28-.11.52-.3.7-.19.18-.42.28-.7.3H1c-.55 0-1-.45-1-1V4c0-.55.45-1 1-1h3c0-1.11.89-2 2-2 1.11 0 2 .89 2 2h3c.55 0 1 .45 1 1v5h-1V6H1v9h10v-2zM2 5h8c0-.55-.45-1-1-1H8c-.55 0-1-.45-1-1s-.45-1-1-1-1 .45-1 1-.45 1-1 1H3c-.55 0-1 .45-1 1z"/></svg>',e.title="Copy IDL to clipboard",e.classList.add("respec-button-copy-paste","removeOnSave"),e}();function Bo(e){const t=e.closest("pre.idl").cloneNode(!0);t.querySelector(".idlHeader").remove();const{textContent:n}=t,r=Fo.cloneNode(!0);r.addEventListener("click",(()=>{navigator.clipboard.writeText(n)})),e.append(r)}var Ho=Object.freeze({__proto__:null,addCopyIDLButton:Bo,name:"core/webidl-clipboard"});var Go=String.raw`pre.idl{padding:1em;position:relative}
900
900
  pre.idl>code{color:#000}
901
901
  @media print{
902
902
  pre.idl{white-space:pre-wrap}
@@ -921,37 +921,37 @@ a.idlEnumItem{color:#000;border-bottom:1px dotted #ccc;text-decoration:none}
921
921
  .respec-button-copy-paste:is(:disabled,:disabled:hover,.disabled,.disabled:hover){color:rgba(102,102,102,.5);cursor:default;background-color:rgba(229,229,229,.5);background-image:none;border-color:rgba(197,197,197,.5);box-shadow:none}
922
922
  @media print{
923
923
  .respec-button-copy-paste{visibility:hidden}
924
- }`;const Go="core/webidl",Vo=Go,Yo={},Ko={},Zo={wrap:e=>e.flat().filter((e=>""!==e)).map((e=>"string"==typeof e?new Text(e):e)),trivia:e=>e.trim()?Ot`<span class="idlSectionComment">${e}</span>`:e,generic:e=>/^[A-Z]/.test(e)?Ot`<a data-xref-type="interface" data-cite="WEBIDL">${e}</a>`:Ot`<a data-xref-type="dfn" data-cite="WEBIDL">${e}</a>`,reference(e,t,n){if("extended-attribute"===n.type)return e;let r="_IDL_",s=null;if("object"===t)r="interface",s="WEBIDL";return Ot`<a
924
+ }`;const Vo="core/webidl",Yo=Vo,Ko={},Zo={},Jo={wrap:e=>e.flat().filter((e=>""!==e)).map((e=>"string"==typeof e?new Text(e):e)),trivia:e=>e.trim()?jt`<span class="idlSectionComment">${e}</span>`:e,generic:e=>/^[A-Z]/.test(e)?jt`<a data-xref-type="interface" data-cite="WEBIDL">${e}</a>`:jt`<a data-xref-type="dfn" data-cite="WEBIDL">${e}</a>`,reference(e,t,n){if("extended-attribute"===n.type)return e;let r="_IDL_",s=null;if("object"===t)r="interface",s="WEBIDL";return jt`<a
925
925
  data-link-type="${"_IDL_"===r?"idl":r}"
926
926
  data-xref-type="${r}"
927
927
  data-cite="${s}"
928
928
  data-lt="${undefined}"
929
929
  >${e}</a
930
- >`},name(e,{data:t,parent:n}){if(t.idlType&&"argument-type"===t.idlType.type)return Ot`<span class="idlParamName">${e}</span>`;const r=Jo(e,t,n);if("enum-value"!==t.type){const e=n?"idlName":"idlID";r.classList.add(e)}return r},nameless(e,{data:t,parent:n}){switch(t.type){case"operation":case"constructor":return Jo(e,t,n);default:return e}},type:e=>Ot`<span class="idlType">${e}</span>`,inheritance:e=>Ot`<span class="idlSuperclass">${e}</span>`,definition(e,{data:t,parent:n}){const r=function(e){switch(e.type){case"callback interface":return"idlInterface";case"operation":return"idlMethod";case"field":return"idlMember";case"enum-value":return"idlEnumItem";case"callback function":return"idlCallback"}return`idl${e.type[0].toUpperCase()}${e.type.slice(1)}`}(t);switch(t.type){case"includes":case"enum-value":return Ot`<span class="${r}">${e}</span>`}const s=n?n.name:"",{name:i,idlId:o}=Qo(t,s);return Ot`<span
930
+ >`},name(e,{data:t,parent:n}){if(t.idlType&&"argument-type"===t.idlType.type)return jt`<span class="idlParamName">${e}</span>`;const r=Xo(e,t,n);if("enum-value"!==t.type){const e=n?"idlName":"idlID";r.classList.add(e)}return r},nameless(e,{data:t,parent:n}){switch(t.type){case"operation":case"constructor":return Xo(e,t,n);default:return e}},type:e=>jt`<span class="idlType">${e}</span>`,inheritance:e=>jt`<span class="idlSuperclass">${e}</span>`,definition(e,{data:t,parent:n}){const r=function(e){switch(e.type){case"callback interface":return"idlInterface";case"operation":return"idlMethod";case"field":return"idlMember";case"enum-value":return"idlEnumItem";case"callback function":return"idlCallback"}return`idl${e.type[0].toUpperCase()}${e.type.slice(1)}`}(t);switch(t.type){case"includes":case"enum-value":return jt`<span class="${r}">${e}</span>`}const s=n?n.name:"",{name:i,idlId:o}=ea(t,s);return jt`<span
931
931
  class="${r}"
932
932
  id="${o}"
933
933
  data-idl
934
934
  data-title="${i}"
935
935
  >${e}</span
936
- >`},extendedAttribute:e=>Ot`<span class="extAttr">${e}</span>`,extendedAttributeReference:e=>Ot`<a data-xref-type="extended-attribute">${e}</a>`};function Jo(e,t,n){const r=n?n.name:"",{name:s}=Qo(t,r),i=jo(t,s,{parent:r}),o=function(e){switch(e){case"operation":return"method";case"field":return"dict-member";case"callback interface":case"interface mixin":return"interface";default:return e}}(t.type);if(i){t.partial||(i.matches("[data-noexport]")||(i.dataset.export=""),i.dataset.dfnType=o),zo(i,t,r,s);const n=`#${i.id}`;return Ot`<a
936
+ >`},extendedAttribute:e=>jt`<span class="extAttr">${e}</span>`,extendedAttributeReference:e=>jt`<a data-xref-type="extended-attribute">${e}</a>`};function Xo(e,t,n){const r=n?n.name:"",{name:s}=ea(t,r),i=Mo(t,s,{parent:r}),o=function(e){switch(e){case"operation":return"method";case"field":return"dict-member";case"callback interface":case"interface mixin":return"interface";default:return e}}(t.type);if(i){t.partial||(i.matches("[data-noexport]")||(i.dataset.export=""),i.dataset.dfnType=o),Uo(i,t,r,s);const n=`#${i.id}`;return jt`<a
937
937
  data-link-for="${r}"
938
938
  data-link-type="${o}"
939
939
  href="${n}"
940
940
  class="internalDFN"
941
941
  ><code>${e}</code></a
942
- >`}const a="operation"===t.type&&"toJSON"===t.name&&t.extAttrs.some((({name:e})=>"Default"===e));if(a)return Ot`<a data-link-type="dfn" data-lt="default toJSON steps"
942
+ >`}const a="operation"===t.type&&"toJSON"===t.name&&t.extAttrs.some((({name:e})=>"Default"===e));if(a)return jt`<a data-link-type="dfn" data-lt="default toJSON steps"
943
943
  >${e}</a
944
- >`;if(!t.partial){const n=Ot`<dfn data-export data-dfn-type="${o}"
944
+ >`;if(!t.partial){const n=jt`<dfn data-export data-dfn-type="${o}"
945
945
  >${e}</dfn
946
- >`;return ao(n,[s]),zo(n,t,r,s),n}const c=Ot`<a
946
+ >`;return co(n,[s]),Uo(n,t,r,s),n}const c=jt`<a
947
947
  data-idl="${t.partial?"partial":null}"
948
948
  data-link-type="${o}"
949
949
  data-title="${t.name}"
950
950
  data-xref-type="${o}"
951
951
  >${e}</a
952
- >`;if(s&&"typedef"!==t.type&&!(t.partial&&!i)){const e=In`See ${"using `data-dfn-for`|#data-dfn-for"} in ReSpec's documentation.`;En(`Missing \`<dfn>\` for${r?` \`${r}\`'s`:""} \`${"operation"===t.type?`${s}()`:s}\` ${t.type}.`,Vo,{elements:[c],hint:e})}return c}const Xo=new WeakMap;function Qo(e,t=""){if(Xo.has(e))return Xo.get(e);const n=function(e,t){let n=function(e){switch(e.type){case"enum-value":return e.value;case"operation":return e.name||e.special;default:return e.name||e.type}}(e);let r=function(e,t){if(!t)return`idl-def-${e.toLowerCase()}`;return`idl-def-${t.toLowerCase()}-${e.toLowerCase()}`}((e.special&&""===e.name?"anonymous-":"")+n,t);switch(e.type){case"callback interface":case"dictionary":case"interface":case"interface mixin":r+=function(e){if(!e.partial)return"";Ko[e.name]||(Ko[e.name]=0);return Ko[e.name]+=1,`-partial-${Ko[e.name]}`}(e);break;case"constructor":case"operation":{const s=function(e,t){const n=`${t}.${e}`,r=`${n}()`;let s;Yo[r]||(Yo[r]=0);Yo[n]?s=`!overload-${Yo[n]}`:Yo[n]=0;return Yo[r]+=1,Yo[n]+=1,s||""}(n,t);s?(n+=s,r+=s):e.arguments.length&&(r+=e.arguments.map((e=>`-${e.name.toLowerCase()}`)).join(""));break}}return{name:n,idlId:r}}(e,t);return Xo.set(e,n),n}const ea=["interface","interface mixin","dictionary","namespace","enum","typedef","callback"];function ta(e,t){let n;try{n=qt.parse(e.textContent,{sourceName:String(t)})}catch(t){return Rn(`Failed to parse WebIDL: ${t.bareMessage}.`,Vo,{title:t.bareMessage,details:`<pre>${t.context}</pre>`,elements:[e]}),[]}e.classList.add("def","idl");const r=qt.write(n,{templates:Zo});Ot.bind(e)`${r}`,bn(e,document.createElement("code")),e.querySelectorAll("[data-idl]").forEach((e=>{if(e.dataset.dfnFor)return;const t=e.dataset.title,n=e.dataset.dfnType,r=e.parentElement.closest("[data-idl][data-title]");r&&!ea.includes(n)&&(e.dataset.dfnFor=r.dataset.title),"dfn"===e.localName&&ao(e,[t])}));const s=e.closest("[data-cite], body"),{dataset:i}=s;if(i.cite||(i.cite="WEBIDL"),!/\bwebidl\b/i.test(i.cite)){const e=i.cite.trim().split(/\s+/);i.cite=["WEBIDL",...e].join(" ")}return na(e),n}function na(e){pn(e,"webidl");const t=Ot`<span class="idlHeader"
952
+ >`;if(s&&"typedef"!==t.type&&!(t.partial&&!i)){const e=Dn`See ${"using `data-dfn-for`|#data-dfn-for"} in ReSpec's documentation.`;An(`Missing \`<dfn>\` for${r?` \`${r}\`'s`:""} \`${"operation"===t.type?`${s}()`:s}\` ${t.type}.`,Yo,{elements:[c],hint:e})}return c}const Qo=new WeakMap;function ea(e,t=""){if(Qo.has(e))return Qo.get(e);const n=function(e,t){let n=function(e){switch(e.type){case"enum-value":return e.value;case"operation":return e.name||e.special;default:return e.name||e.type}}(e);let r=function(e,t){if(!t)return`idl-def-${e.toLowerCase()}`;return`idl-def-${t.toLowerCase()}-${e.toLowerCase()}`}((e.special&&""===e.name?"anonymous-":"")+n,t);switch(e.type){case"callback interface":case"dictionary":case"interface":case"interface mixin":r+=function(e){if(!e.partial)return"";Zo[e.name]||(Zo[e.name]=0);return Zo[e.name]+=1,`-partial-${Zo[e.name]}`}(e);break;case"constructor":case"operation":{const s=function(e,t){const n=`${t}.${e}`,r=`${n}()`;let s;Ko[r]||(Ko[r]=0);Ko[n]?s=`!overload-${Ko[n]}`:Ko[n]=0;return Ko[r]+=1,Ko[n]+=1,s||""}(n,t);s?(n+=s,r+=s):e.arguments.length&&(r+=e.arguments.map((e=>`-${e.name.toLowerCase()}`)).join(""));break}}return{name:n,idlId:r}}(e,t);return Qo.set(e,n),n}const ta=["interface","interface mixin","dictionary","namespace","enum","typedef","callback"];function na(e,t){let n;try{n=Wt.parse(e.textContent,{sourceName:String(t)})}catch(t){return En(`Failed to parse WebIDL: ${t.bareMessage}.`,Yo,{title:t.bareMessage,details:`<pre>${t.context}</pre>`,elements:[e]}),[]}e.classList.add("def","idl");const r=Wt.write(n,{templates:Jo});jt.bind(e)`${r}`,yn(e,document.createElement("code")),e.querySelectorAll("[data-idl]").forEach((e=>{if(e.dataset.dfnFor)return;const t=e.dataset.title,n=e.dataset.dfnType,r=e.parentElement.closest("[data-idl][data-title]");r&&!ta.includes(n)&&(e.dataset.dfnFor=r.dataset.title),"dfn"===e.localName&&co(e,[t])}));const s=e.closest("[data-cite], body"),{dataset:i}=s;if(i.cite||(i.cite="WEBIDL"),!/\bwebidl\b/i.test(i.cite)){const e=i.cite.trim().split(/\s+/);i.cite=["WEBIDL",...e].join(" ")}return ra(e),n}function ra(e){fn(e,"webidl");const t=jt`<span class="idlHeader"
953
953
  ><a class="self-link" href="${`#${e.id}`}">WebIDL</a></span
954
- >`;e.prepend(t),Fo(t)}var ra=Object.freeze({__proto__:null,addIDLHeader:na,name:Go,run:async function(){const e=document.querySelectorAll("pre.idl, pre.webidl");if(!e.length)return;const t=document.createElement("style");t.textContent=Ho,document.querySelector("head link, head > *:last-child").before(t);const n=[...e].map(ta),r=qt.validate(n);for(const t of r){let r=`<pre>${nn(t.context)}</pre>`;if(t.autofix){t.autofix();r+=`Try fixing as:\n <pre>${nn(qt.write(n[t.sourceName]))}</pre>`}Rn(`WebIDL validation error: ${t.bareMessage}`,Vo,{details:r,elements:[e[t.sourceName]],title:t.bareMessage})}document.normalize()}});const sa="core/data-cite",ia="__SPEC__";async function oa(e){const{key:t,frag:n,path:r,href:s}=e;let i="",o="";if(t===ia)i=document.location.href;else{const e=await vi(t);if(!e)return null;i=e.href,o=e.title}if(s)i=s;else{if(r){const e=r.startsWith("/")?`.${r}`:r;i=new URL(e,i).href}n&&(i=new URL(n,i).href)}return{href:i,title:o}}function aa(e,t,n){const{href:r,title:s}=t,i=!n.path&&!n.frag;switch(e.localName){case"a":{const t=e;if(""===t.textContent&&"the-empty-string"!==t.dataset.lt&&(t.textContent=s),t.href=r,i){const e=document.createElement("cite");t.replaceWith(e),e.append(t)}break}case"dfn":{const t=document.createElement("a");if(t.href=r,t.dataset.cite=n.key,t.dataset.citePath=n.path,t.dataset.citeFrag=n.frag,e.textContent?bn(e,t):(t.textContent=s,e.append(t)),i){const n=document.createElement("cite");n.append(t),e.append(n)}if("export"in e.dataset){Rn("Exporting an linked external definition is not allowed.",sa,{hint:"Please remove the `data-export` attribute.",elements:[e]}),delete e.dataset.export}e.classList.add("externalDFN"),e.dataset.noExport="";break}}}function ca(e){return t=>{const n=t.search(e);return-1!==n?t.substring(n):""}}const la=ca("#"),ua=ca("/");function da(e){const{dataset:t}=e,{cite:n,citeFrag:r,citePath:s,citeHref:i}=t;if(n.startsWith("#")&&!r){const r=e.parentElement.closest('[data-cite]:not([data-cite^="#"])'),{key:s,isNormative:i}=r?da(r):{key:ia,isNormative:!1};return t.cite=i?s:`?${s}`,t.citeFrag=n.replace("#",""),da(e)}const o=r?`#${r}`:la(n),a=s||ua(n).split("#")[0],{type:c}=gn(n,e),l="normative"===c,u=/^[?|!]/.test(n);return{key:n.split(/[/|#]/)[0].substring(Number(u)),isNormative:l,frag:o,path:a,href:i}}function pa(e){const t=["data-cite","data-cite-frag","data-cite-path"];e.querySelectorAll("a[data-cite], dfn[data-cite]").forEach((e=>t.forEach((t=>e.removeAttribute(t)))))}var fa=Object.freeze({__proto__:null,THIS_SPEC:ia,name:sa,run:async function(){const e=document.querySelectorAll("dfn[data-cite]:not([data-cite='']), a[data-cite]:not([data-cite=''])");await async function(e){const t=e.map(da).map((async e=>({entry:e,result:await vi(e.key)}))),n=(await Promise.all(t)).filter((({result:e})=>null===e)).map((({entry:{key:e}})=>e)),r=await wi(n);r&&Object.assign(hi,r)}([...e]);for(const t of e){const e=t.dataset.cite,n=da(t),r=await oa(n);if(r)aa(t,r,n);else{const n=`Couldn't find a match for "${e}"`;t.dataset.matchedText&&(t.textContent=t.dataset.matchedText),En(n,sa,{elements:[t]})}}s("beforesave",pa)},toCiteDetails:da});const ha="core/link-to-dfn",ma=[],ga={en:{duplicateMsg:e=>`Duplicate definition(s) of '${e}'`,duplicateTitle:"This is defined more than once in the document."},ja:{duplicateMsg:e=>`'${e}' の重複定義`,duplicateTitle:"この文書内で複数回定義されています."},de:{duplicateMsg:e=>`Mehrfache Definition von '${e}'`,duplicateTitle:"Das Dokument enthält mehrere Definitionen dieses Eintrags."},zh:{duplicateMsg:e=>`'${e}' 的重复定义`,duplicateTitle:"在文档中有重复的定义。"}},ba=sn(ga);function ya(e){const t=new Map,n=[];for(const r of oo.get(e)){const{dfnType:s="dfn"}=r.dataset,i=r.dataset.dfnFor?.split(",").map((e=>e.trim()))??[""];for(const o of i){if(t.has(o)&&t.get(o).has(s)){const e=t.get(o).get(s),i="dfn"===e.localName,a="dfn"===r.localName,c=s===(e.dataset.dfnType||"dfn"),l=!o&&!e.dataset.dfnFor||e.dataset.dfnFor?.split(",").map((e=>e.trim())).includes(o);if(i&&a&&c&&l){n.push(r);continue}}t.has(o)||t.set(o,new Map),t.get(o).set(s,r),("idl"in r.dataset||"dfn"!==s)&&t.get(o).set("idl",r),fn(r,"dfn",e)}}return{result:t,duplicates:n}}function wa(e,t){const n=function(e){const t=e.closest("[data-link-for]"),n=t?t.dataset.linkFor:"",r=hn(e).reduce(((e,r)=>{const s=r.split(".");return 2===s.length&&e.push({for:s[0],title:s[1]}),e.push({for:n,title:r}),t||e.push({for:r,title:r}),""!==n&&e.push({for:"",title:r}),e}),[]);return r}(e),r=n.find((e=>t.has(e.title)&&t.get(e.title).has(e.for)));if(!r)return;const s=t.get(r.title).get(r.for),{linkType:i}=e.dataset;if(i){for(const e of i.split("|"))if(s.get(e))return s.get(e);return s.get("dfn")}{const e=r.for?"idl":"dfn";return s.get(e)||s.get("idl")}}function va(e,t,n){let r=!1;const{linkFor:s}=e.dataset,{dfnFor:i}=t.dataset;if(t.dataset.cite)e.dataset.cite=t.dataset.cite;else if(s&&!n.get(s)&&i&&!i.split(",").map((e=>e.trim())).includes(s))r=!0;else if(t.classList.contains("externalDFN")){const n=t.dataset.lt?t.dataset.lt.split("|"):[];e.dataset.lt=n[0]||t.textContent,r=!0}else"partial"!==e.dataset.idl?(e.href=`#${t.id}`,e.classList.add("internalDFN")):r=!0;return e.hasAttribute("data-link-type")||(e.dataset.linkType="idl"in t.dataset?"idl":"dfn"),function(e){if(e.closest("code,pre"))return!0;if(1!==e.childNodes.length)return!1;const[t]=e.childNodes;return"code"===t.localName}(t)&&function(e,t){const n=e.textContent.trim(),r=t.dataset.hasOwnProperty("idl"),s=$a(e)&&$a(t,n);r&&!s||bn(e,document.createElement("code"))}(e,t),!r}function $a(e,t=""){if("a"===e.localName){if(!e.querySelector("code"))return!0}else{const{dataset:n}=e;if(e.textContent.trim()===t)return!0;if(n.title===t)return!0;if(n.lt||n.localLt){const e=[];return n.lt&&e.push(...n.lt.split("|")),n.localLt&&e.push(...n.localLt.split("|")),e.includes(t)}}return!1}function ka(e){e.forEach((e=>{En(`Found linkless \`<a>\` element with text "${e.textContent}" but no matching \`<dfn>\``,ha,{title:"Linking error: not matching `<dfn>`",elements:[e]})}))}var xa=Object.freeze({__proto__:null,name:ha,possibleExternalLinks:ma,run:async function(e){const t=function(){const e=new Cn;for(const t of oo.keys()){const{result:n,duplicates:r}=ya(t);e.set(t,n),r.length>0&&Rn(ba.duplicateMsg(t),ha,{title:ba.duplicateTitle,elements:r})}return e}(),n=[],r=document.querySelectorAll("a[data-cite=''], a:not([href]):not([data-cite]):not(.logo):not(.externalDFN)");for(const e of r){if(!e.dataset?.linkType&&e.dataset?.xrefType){ma.push(e);continue}const r=wa(e,t);if(r){va(e,r,t)||ma.push(e)}else""===e.dataset.cite?n.push(e):ma.push(e)}ka(n),function(e){const{shortName:t=""}=e,n=new RegExp(String.raw`^([?!])?${t}\b([^-])`,"i"),r=document.querySelectorAll("dfn[data-cite]:not([data-cite='']), a[data-cite]:not([data-cite=''])");for(const t of r){t.dataset.cite=t.dataset.cite.replace(n,"$1__SPEC__$2");const{key:r,isNormative:s}=da(t);r!==ia&&(s||e.normativeReferences.has(r)?(e.normativeReferences.add(r),e.informativeReferences.delete(r)):e.informativeReferences.add(r))}}(e),e.xref||ka(ma)}});const _a="xrefs",Ca=3e5;async function Sa(){return await jt.openDB("xref",2,{upgrade(e){[...e.objectStoreNames].forEach((t=>e.deleteObjectStore(t)));e.createObjectStore(_a,{keyPath:"query.id"}).createIndex("byTerm","query.term",{unique:!1})}})}async function Ra(e){const t=new Map;if(await async function(){const e="XREF:LAST_VERSION_CHECK",t=parseInt(localStorage.getItem(e),10),n=Date.now();if(!t)return localStorage.setItem(e,n.toString()),!1;if(n-t<Ca)return!1;const r=new URL("meta/version",Ta).href,s=await fetch(r);if(!s.ok)return!1;const i=await s.text();return localStorage.setItem(e,n.toString()),parseInt(i,10)>t}())return await async function(){try{await Sa().then((e=>e.clear(_a)))}catch(e){console.error(e)}}(),t;const n=new Set(e.map((e=>e.id)));try{const e=await Sa();let r=await e.transaction(_a).store.openCursor();for(;r;)n.has(r.key)&&t.set(r.key,r.value.result),r=await r.continue()}catch(e){console.error(e)}return t}const Ea="core/xref",Aa={"web-platform":["HTML","INFRA","URL","WEBIDL","DOM","FETCH"]},Ta="https://respec.org/xref/",La=[];if(!document.querySelector("link[rel='preconnect'][href='https://respec.org']")){const e=Kt({hint:"preconnect",href:"https://respec.org"});document.head.appendChild(e)}function Pa(e){const t="xrefType"in e.dataset;let n=Ia(e);t||(n=n.toLowerCase());const r=function(e){const t=[];let n=e.closest("[data-cite]");for(;n;){const r=n.dataset.cite.toLowerCase().replace(/[!?]/g,"").split(/\s+/).filter((e=>e));if(r.length&&t.push(r),n===e)break;n=n.parentElement.closest("[data-cite]")}if(n!==e){const n=e.closest("section"),r=[...n?n.querySelectorAll("a.bibref"):[]].map((e=>e.textContent.toLowerCase()));r.length&&t.push(r)}return function(e){const t=[];for(const n of e){const e=t[t.length-1]||[],r=[...new Set(n)].filter((t=>!e.includes(t)));t.push(r.sort())}return t}(t)}(e),s=function(e,t){if(t)return e.dataset.xrefType?e.dataset.xrefType.split("|"):["_IDL_"];return["_CONCEPT_"]}(e,t),i=function(e,t){if(e.dataset.xrefFor)return rn(e.dataset.xrefFor);if(t){const t=e.closest("[data-xref-for]");if(t)return rn(t.dataset.xrefFor)}return null}(e,t);return{id:"",term:n,types:s,...r.length&&{specs:r},..."string"==typeof i&&{for:i}}}function Ia(e){const{lt:t}=e.dataset;let n=t?t.split("|",1)[0]:e.textContent;return n=nn(rn(n)),"the-empty-string"===n?"":n}function Da(e,t,n,r){const{term:s,specs:i=[]}=t,{uri:o,shortname:a,spec:c,normative:l,type:u,for:d}=n,p=i.flat().includes(c)?c:a,f=new URL(o,"https://partial"),{pathname:h}=f,m={cite:p,citePath:h,citeFrag:f.hash.slice(1),type:u};d&&(m.linkFor=d[0]),f.origin&&"https://partial"!==f.origin&&(m.citeHref=f.href),Object.assign(e.dataset,m),function(e,t,n,r,s){if(!function(e){const t=e.closest(".normative"),n=e.closest(Yt);return!n||e===t||t&&n&&n.contains(t)}(e))return void(s.normativeReferences.has(t)||s.informativeReferences.add(t));if(n){const e=s.informativeReferences.has(t)?s.informativeReferences.getCanonicalKey(t):t;return s.normativeReferences.add(e),void s.informativeReferences.delete(e)}La.push({term:r,spec:t,element:e})}(e,p,l,s,r)}function Na(e){const t=JSON.stringify(e,Object.keys(e).sort()),n=(new TextEncoder).encode(t);return crypto.subtle.digest("SHA-1",n).then(Oa)}function Oa(e){return[...new Uint8Array(e)].map((e=>e.toString(16).padStart(2,"0"))).join("")}function ja(e){const t=e.querySelectorAll("a[data-xref-for], a[data-xref-type], a[data-link-for]"),n=["data-xref-for","data-xref-type","data-link-for"];t.forEach((e=>{n.forEach((t=>e.removeAttribute(t)))}))}var Ma=Object.freeze({__proto__:null,API_URL:Ta,getTermFromElement:Ia,informativeRefsInNormative:La,name:Ea,run:async function(e){if(!e.xref)return;const t=function(e){const t={url:Ta,specs:null},n=Object.assign({},t);switch(Array.isArray(e)?"array":typeof e){case"boolean":break;case"string":e.toLowerCase()in Aa?Object.assign(n,{specs:Aa[e.toLowerCase()]}):r(e);break;case"array":Object.assign(n,{specs:e});break;case"object":if(Object.assign(n,e),e.profile){const t=e.profile.toLowerCase();if(t in Aa){const r=(e.specs??[]).concat(Aa[t]);Object.assign(n,{specs:r})}else r(e.profile)}break;default:Rn(`Invalid value for \`xref\` configuration option. Received: "${e}".`,Ea)}return n;function r(e){Rn(`Invalid profile "${e}" in \`respecConfig.xref\`. Please use one of the supported profiles: ${tn(Object.keys(Aa),(e=>`"${e}"`))}.`,Ea)}}(e.xref);if(t.specs){const e=document.body.dataset.cite?document.body.dataset.cite.split(/\s+/):[];document.body.dataset.cite=e.concat(t.specs).join(" ")}const n=ma.concat(function(){const e=document.querySelectorAll(":is(a,dfn)[data-cite]:not([data-cite=''],[data-cite*='#'])"),t=document.querySelectorAll("dfn.externalDFN");return[...e].filter((e=>{if(""===e.textContent.trim())return!1;const t=e.closest("[data-cite]");return!t||""!==t.dataset.cite})).concat(...t)}());if(!n.length)return;const r=[];for(const e of n){const t=Pa(e);t.id=await Na(t),r.push(t)}const i=await async function(e,t){const n=new Set,r=e.filter((e=>!n.has(e.id)&&(n.add(e.id)&&!0))),s=await Ra(r),i=r.filter((e=>!s.get(e.id))),o=await async function(e,t){if(!e.length)return new Map;const n={keys:e},r={method:"POST",body:JSON.stringify(n),headers:{"Content-Type":"application/json"}},s=await fetch(t,r),i=await s.json();return new Map(i.result)}(i,t);o.size&&await async function(e,t){try{const n=(await Sa()).transaction(_a,"readwrite");for(const r of e){const e=t.get(r.id);n.objectStore(_a).add({query:r,result:e})}await n.done}catch(e){console.error(e)}}(r,o);return new Map([...s,...o])}(r,t.url);!function(e,t,n,r){const s={ambiguous:new Map,notFound:new Map};for(let i=0,o=e.length;i<o;i++){if(e[i].closest("[data-no-xref]"))continue;const o=e[i],a=t[i],{id:c}=a,l=n.get(c);if(1===l.length)Da(o,a,l[0],r);else{const e=s[0===l.length?"notFound":"ambiguous"];e.has(c)||e.set(c,{elems:[],results:l,query:a}),e.get(c).elems.push(o)}}!function({ambiguous:e,notFound:t}){const n=(e,t,n=[])=>{const r=new URL(Ta);return r.searchParams.set("term",e),t.for&&r.searchParams.set("for",t.for),r.searchParams.set("types",t.types.join(",")),n.length&&r.searchParams.set("specs",n.join(",")),r.href},r=(e,t)=>In`[See search matches for "${t}"](${e}) or ${"[Learn about this error|#error-term-not-found]"}.`;for(const{query:e,elems:s}of t.values()){const t=e.specs?[...new Set(e.specs.flat())].sort():[],i=Ia(s[0]),o=n(i,e),a=en(t,(e=>`**[${e}]**`)),c=r(o,i);Rn(`Couldn't find "**${i}**"${e.for?`, for **"${e.for}"**, `:""} in this document or other cited documents: ${a}.`,Ea,{title:"No matching definition found.",elements:s,hint:c})}for(const{query:t,elems:s,results:i}of e.values()){const e=[...new Set(i.map((e=>e.shortname)))].sort(),o=en(e,(e=>`**[${e}]**`)),a=Ia(s[0]),c=n(a,t,e),l=t.for?`, for **"${t.for}"**, `:"",u=In`To fix, use the ${"[data-cite]"} attribute to pick the one you mean from the appropriate specification. ${r(c,a)}.`;Rn(`The term "**${a}**"${l} is ambiguous because it's defined in ${o}.`,Ea,{title:"Definition is ambiguous.",elements:s,hint:u})}}(s)}(n,r,i,e),s("beforesave",ja)}});var za=String.raw`ul.index{columns:30ch;column-gap:1.5em}
954
+ >`;e.prepend(t),Bo(t)}var sa=Object.freeze({__proto__:null,addIDLHeader:ra,name:Vo,run:async function(){const e=document.querySelectorAll("pre.idl, pre.webidl");if(!e.length)return;const t=document.createElement("style");t.textContent=Go,document.querySelector("head link, head > *:last-child").before(t);const n=[...e].map(na),r=Wt.validate(n);for(const t of r){let r=`<pre>${rn(t.context)}</pre>`;if(t.autofix){t.autofix();r+=`Try fixing as:\n <pre>${rn(Wt.write(n[t.sourceName]))}</pre>`}En(`WebIDL validation error: ${t.bareMessage}`,Yo,{details:r,elements:[e[t.sourceName]],title:t.bareMessage})}document.normalize()}});const ia="core/data-cite",oa="__SPEC__";async function aa(e){const{key:t,frag:n,path:r,href:s}=e;let i="",o="";if(t===oa)i=document.location.href;else{const e=await $i(t);if(!e)return null;i=e.href,o=e.title}if(s)i=s;else{if(r){const e=r.startsWith("/")?`.${r}`:r;i=new URL(e,i).href}n&&(i=new URL(n,i).href)}return{href:i,title:o}}function ca(e,t,n){const{href:r,title:s}=t,i=!n.path&&!n.frag;switch(e.localName){case"a":{const t=e;if(""===t.textContent&&"the-empty-string"!==t.dataset.lt&&(t.textContent=s),t.href=r,i){const e=document.createElement("cite");t.replaceWith(e),e.append(t)}break}case"dfn":{const t=document.createElement("a");if(t.href=r,t.dataset.cite=n.key,t.dataset.citePath=n.path,t.dataset.citeFrag=n.frag,e.textContent?yn(e,t):(t.textContent=s,e.append(t)),i){const n=document.createElement("cite");n.append(t),e.append(n)}if("export"in e.dataset){En("Exporting an linked external definition is not allowed.",ia,{hint:"Please remove the `data-export` attribute.",elements:[e]}),delete e.dataset.export}e.classList.add("externalDFN"),e.dataset.noExport="";break}}}function la(e){return t=>{const n=t.search(e);return-1!==n?t.substring(n):""}}const ua=la("#"),da=la("/");function pa(e){const{dataset:t}=e,{cite:n,citeFrag:r,citePath:s,citeHref:i}=t;if(n.startsWith("#")&&!r){const r=e.parentElement.closest('[data-cite]:not([data-cite^="#"])'),{key:s,isNormative:i}=r?pa(r):{key:oa,isNormative:!1};return t.cite=i?s:`?${s}`,t.citeFrag=n.replace("#",""),pa(e)}const o=r?`#${r}`:ua(n),a=s||da(n).split("#")[0],{type:c}=bn(n,e),l="normative"===c,u=/^[?|!]/.test(n);return{key:n.split(/[/|#]/)[0].substring(Number(u)),isNormative:l,frag:o,path:a,href:i}}function fa(e){const t=["data-cite","data-cite-frag","data-cite-path"];e.querySelectorAll("a[data-cite], dfn[data-cite]").forEach((e=>t.forEach((t=>e.removeAttribute(t)))))}var ha=Object.freeze({__proto__:null,THIS_SPEC:oa,name:ia,run:async function(){const e=document.querySelectorAll("dfn[data-cite]:not([data-cite='']), a[data-cite]:not([data-cite=''])");await async function(e){const t=e.map(pa).map((async e=>({entry:e,result:await $i(e.key)}))),n=(await Promise.all(t)).filter((({result:e})=>null===e)).map((({entry:{key:e}})=>e)),r=await vi(n);r&&Object.assign(mi,r)}([...e]);for(const t of e){const e=t.dataset.cite,n=pa(t),r=await aa(n);if(r)ca(t,r,n);else{const n=`Couldn't find a match for "${e}"`;t.dataset.matchedText&&(t.textContent=t.dataset.matchedText),An(n,ia,{elements:[t]})}}s("beforesave",fa)},toCiteDetails:pa});const ma="core/link-to-dfn",ga=[],ba={en:{duplicateMsg:e=>`Duplicate definition(s) of '${e}'`,duplicateTitle:"This is defined more than once in the document."},ja:{duplicateMsg:e=>`'${e}' の重複定義`,duplicateTitle:"この文書内で複数回定義されています."},de:{duplicateMsg:e=>`Mehrfache Definition von '${e}'`,duplicateTitle:"Das Dokument enthält mehrere Definitionen dieses Eintrags."},zh:{duplicateMsg:e=>`'${e}' 的重复定义`,duplicateTitle:"在文档中有重复的定义。"}},ya=on(ba);function wa(e){const t=new Map,n=[];for(const r of ao.get(e)){const{dfnType:s="dfn"}=r.dataset,i=r.dataset.dfnFor?.split(",").map((e=>e.trim()))??[""];for(const o of i){if(t.has(o)&&t.get(o).has(s)){const e=t.get(o).get(s),i="dfn"===e.localName,a="dfn"===r.localName,c=s===(e.dataset.dfnType||"dfn"),l=!o&&!e.dataset.dfnFor||e.dataset.dfnFor?.split(",").map((e=>e.trim())).includes(o);if(i&&a&&c&&l){n.push(r);continue}}t.has(o)||t.set(o,new Map),t.get(o).set(s,r),("idl"in r.dataset||"dfn"!==s)&&t.get(o).set("idl",r),hn(r,"dfn",e)}}return{result:t,duplicates:n}}function va(e,t){const n=function(e){const t=e.closest("[data-link-for]"),n=t?t.dataset.linkFor:"",r=mn(e).reduce(((e,r)=>{const s=r.split(".");return 2===s.length&&e.push({for:s[0],title:s[1]}),e.push({for:n,title:r}),t||e.push({for:r,title:r}),""!==n&&e.push({for:"",title:r}),e}),[]);return r}(e),r=n.find((e=>t.has(e.title)&&t.get(e.title).has(e.for)));if(!r)return;const s=t.get(r.title).get(r.for),{linkType:i}=e.dataset;if(i){for(const e of i.split("|"))if(s.get(e))return s.get(e);return s.get("dfn")}{const e=r.for?"idl":"dfn";return s.get(e)||s.get("idl")}}function $a(e,t,n){let r=!1;const{linkFor:s}=e.dataset,{dfnFor:i}=t.dataset;if(t.dataset.cite)e.dataset.cite=t.dataset.cite;else if(s&&!n.get(s)&&i&&!i.split(",").map((e=>e.trim())).includes(s))r=!0;else if(t.classList.contains("externalDFN")){const n=t.dataset.lt?t.dataset.lt.split("|"):[];e.dataset.lt=n[0]||t.textContent,r=!0}else"partial"!==e.dataset.idl?(e.href=`#${t.id}`,e.classList.add("internalDFN")):r=!0;return e.hasAttribute("data-link-type")||(e.dataset.linkType="idl"in t.dataset?"idl":"dfn"),function(e){if(e.closest("code,pre"))return!0;if(1!==e.childNodes.length)return!1;const[t]=e.childNodes;return"code"===t.localName}(t)&&function(e,t){const n=e.textContent.trim(),r=t.dataset.hasOwnProperty("idl"),s=ka(e)&&ka(t,n);r&&!s||yn(e,document.createElement("code"))}(e,t),!r}function ka(e,t=""){if("a"===e.localName){if(!e.querySelector("code"))return!0}else{const{dataset:n}=e;if(e.textContent.trim()===t)return!0;if(n.title===t)return!0;if(n.lt||n.localLt){const e=[];return n.lt&&e.push(...n.lt.split("|")),n.localLt&&e.push(...n.localLt.split("|")),e.includes(t)}}return!1}function xa(e){e.forEach((e=>{An(`Found linkless \`<a>\` element with text "${e.textContent}" but no matching \`<dfn>\``,ma,{title:"Linking error: not matching `<dfn>`",elements:[e]})}))}var _a=Object.freeze({__proto__:null,name:ma,possibleExternalLinks:ga,run:async function(e){const t=function(){const e=new Cn;for(const t of ao.keys()){const{result:n,duplicates:r}=wa(t);e.set(t,n),r.length>0&&En(ya.duplicateMsg(t),ma,{title:ya.duplicateTitle,elements:r})}return e}(),n=[],r=document.querySelectorAll("a[data-cite=''], a:not([href]):not([data-cite]):not(.logo):not(.externalDFN)");for(const e of r){if(!e.dataset?.linkType&&e.dataset?.xrefType){ga.push(e);continue}const r=va(e,t);if(r){$a(e,r,t)||ga.push(e)}else""===e.dataset.cite?n.push(e):ga.push(e)}xa(n),function(e){const{shortName:t=""}=e,n=new RegExp(String.raw`^([?!])?${t}\b([^-])`,"i"),r=document.querySelectorAll("dfn[data-cite]:not([data-cite='']), a[data-cite]:not([data-cite=''])");for(const t of r){t.dataset.cite=t.dataset.cite.replace(n,"$1__SPEC__$2");const{key:r,isNormative:s}=pa(t);r!==oa&&(s||e.normativeReferences.has(r)?(e.normativeReferences.add(r),e.informativeReferences.delete(r)):e.informativeReferences.add(r))}}(e),e.xref||xa(ga)}});const Sa="xrefs",Ca=3e5;async function Ra(){return await Mt.openDB("xref",2,{upgrade(e){[...e.objectStoreNames].forEach((t=>e.deleteObjectStore(t)));e.createObjectStore(Sa,{keyPath:"query.id"}).createIndex("byTerm","query.term",{unique:!1})}})}async function Ea(e){const t=new Map;if(await async function(){const e="XREF:LAST_VERSION_CHECK",t=parseInt(localStorage.getItem(e),10),n=Date.now();if(!t)return localStorage.setItem(e,n.toString()),!1;if(n-t<Ca)return!1;const r=new URL("meta/version",La).href,s=await fetch(r);if(!s.ok)return!1;const i=await s.text();return localStorage.setItem(e,n.toString()),parseInt(i,10)>t}())return await async function(){try{await Ra().then((e=>e.clear(Sa)))}catch(e){console.error(e)}}(),t;const n=new Set(e.map((e=>e.id)));try{const e=await Ra();let r=await e.transaction(Sa).store.openCursor();for(;r;)n.has(r.key)&&t.set(r.key,r.value.result),r=await r.continue()}catch(e){console.error(e)}return t}const Aa="core/xref",Ta={"web-platform":["HTML","INFRA","URL","WEBIDL","DOM","FETCH"]},La="https://respec.org/xref/",Pa=[];if(!document.querySelector("link[rel='preconnect'][href='https://respec.org']")){const e=Zt({hint:"preconnect",href:"https://respec.org"});document.head.appendChild(e)}function Ia(e){const t="xrefType"in e.dataset;let n=Da(e);t||(n=n.toLowerCase());const r=function(e){const t=[];let n=e.closest("[data-cite]");for(;n;){const r=n.dataset.cite.toLowerCase().replace(/[!?]/g,"").split(/\s+/).filter((e=>e));if(r.length&&t.push(r),n===e)break;n=n.parentElement.closest("[data-cite]")}if(n!==e){const n=e.closest("section"),r=[...n?n.querySelectorAll("a.bibref"):[]].map((e=>e.textContent.toLowerCase()));r.length&&t.push(r)}return function(e){const t=[];for(const n of e){const e=t[t.length-1]||[],r=[...new Set(n)].filter((t=>!e.includes(t)));t.push(r.sort())}return t}(t)}(e),s=function(e,t){if(t)return e.dataset.xrefType?e.dataset.xrefType.split("|"):["_IDL_"];return["_CONCEPT_"]}(e,t),i=function(e,t){if(e.dataset.xrefFor)return sn(e.dataset.xrefFor);if(t){const t=e.closest("[data-xref-for]");if(t)return sn(t.dataset.xrefFor)}return null}(e,t);return{id:"",term:n,types:s,...r.length&&{specs:r},..."string"==typeof i&&{for:i}}}function Da(e){const{lt:t}=e.dataset;let n=t?t.split("|",1)[0]:e.textContent;return n=rn(sn(n)),"the-empty-string"===n?"":n}function Na(e,t,n,r){const{term:s,specs:i=[]}=t,{uri:o,shortname:a,spec:c,normative:l,type:u,for:d}=n,p=i.flat().includes(c)?c:a,f=new URL(o,"https://partial"),{pathname:h}=f,m={cite:p,citePath:h,citeFrag:f.hash.slice(1),type:u};d&&(m.linkFor=d[0]),f.origin&&"https://partial"!==f.origin&&(m.citeHref=f.href),Object.assign(e.dataset,m),function(e,t,n,r,s){if(!function(e){const t=e.closest(".normative"),n=e.closest(Kt);return!n||e===t||t&&n&&n.contains(t)}(e))return void(s.normativeReferences.has(t)||s.informativeReferences.add(t));if(n){const e=s.informativeReferences.has(t)?s.informativeReferences.getCanonicalKey(t):t;return s.normativeReferences.add(e),void s.informativeReferences.delete(e)}Pa.push({term:r,spec:t,element:e})}(e,p,l,s,r)}function Oa(e){const t=JSON.stringify(e,Object.keys(e).sort()),n=(new TextEncoder).encode(t);return crypto.subtle.digest("SHA-1",n).then(ja)}function ja(e){return[...new Uint8Array(e)].map((e=>e.toString(16).padStart(2,"0"))).join("")}function Ma(e){const t=e.querySelectorAll("a[data-xref-for], a[data-xref-type], a[data-link-for]"),n=["data-xref-for","data-xref-type","data-link-for"];t.forEach((e=>{n.forEach((t=>e.removeAttribute(t)))}))}var za=Object.freeze({__proto__:null,API_URL:La,getTermFromElement:Da,informativeRefsInNormative:Pa,name:Aa,run:async function(e){if(!e.xref)return;const t=function(e){const t={url:La,specs:null},n=Object.assign({},t);switch(Array.isArray(e)?"array":typeof e){case"boolean":break;case"string":e.toLowerCase()in Ta?Object.assign(n,{specs:Ta[e.toLowerCase()]}):r(e);break;case"array":Object.assign(n,{specs:e});break;case"object":if(Object.assign(n,e),e.profile){const t=e.profile.toLowerCase();if(t in Ta){const r=(e.specs??[]).concat(Ta[t]);Object.assign(n,{specs:r})}else r(e.profile)}break;default:En(`Invalid value for \`xref\` configuration option. Received: "${e}".`,Aa)}return n;function r(e){En(`Invalid profile "${e}" in \`respecConfig.xref\`. Please use one of the supported profiles: ${nn(Object.keys(Ta),(e=>`"${e}"`))}.`,Aa)}}(e.xref);if(t.specs){const e=document.body.dataset.cite?document.body.dataset.cite.split(/\s+/):[];document.body.dataset.cite=e.concat(t.specs).join(" ")}const n=ga.concat(function(){const e=document.querySelectorAll(":is(a,dfn)[data-cite]:not([data-cite=''],[data-cite*='#'])"),t=document.querySelectorAll("dfn.externalDFN");return[...e].filter((e=>{if(""===e.textContent.trim())return!1;const t=e.closest("[data-cite]");return!t||""!==t.dataset.cite})).concat(...t)}());if(!n.length)return;const r=[];for(const e of n){const t=Ia(e);t.id=await Oa(t),r.push(t)}const i=await async function(e,t){const n=new Set,r=e.filter((e=>!n.has(e.id)&&(n.add(e.id)&&!0))),s=await Ea(r),i=r.filter((e=>!s.get(e.id))),o=await async function(e,t){if(!e.length)return new Map;const n={keys:e},r={method:"POST",body:JSON.stringify(n),headers:{"Content-Type":"application/json"}},s=await fetch(t,r),i=await s.json();return new Map(i.result)}(i,t);o.size&&await async function(e,t){try{const n=(await Ra()).transaction(Sa,"readwrite");for(const r of e){const e=t.get(r.id);n.objectStore(Sa).add({query:r,result:e})}await n.done}catch(e){console.error(e)}}(r,o);return new Map([...s,...o])}(r,t.url);!function(e,t,n,r){const s={ambiguous:new Map,notFound:new Map};for(let i=0,o=e.length;i<o;i++){if(e[i].closest("[data-no-xref]"))continue;const o=e[i],a=t[i],{id:c}=a,l=n.get(c);if(1===l.length)Na(o,a,l[0],r);else{const e=s[0===l.length?"notFound":"ambiguous"];e.has(c)||e.set(c,{elems:[],results:l,query:a}),e.get(c).elems.push(o)}}!function({ambiguous:e,notFound:t}){const n=(e,t,n=[])=>{const r=new URL(La);return r.searchParams.set("term",e),t.for&&r.searchParams.set("for",t.for),r.searchParams.set("types",t.types.join(",")),n.length&&r.searchParams.set("specs",n.join(",")),r.href},r=(e,t)=>Dn`[See search matches for "${t}"](${e}) or ${"[Learn about this error|#error-term-not-found]"}.`;for(const{query:e,elems:s}of t.values()){const t=e.specs?[...new Set(e.specs.flat())].sort():[],i=Da(s[0]),o=n(i,e),a=tn(t,(e=>`**[${e}]**`)),c=r(o,i);En(`Couldn't find "**${i}**"${e.for?`, for **"${e.for}"**, `:""} in this document or other cited documents: ${a}.`,Aa,{title:"No matching definition found.",elements:s,hint:c})}for(const{query:t,elems:s,results:i}of e.values()){const e=[...new Set(i.map((e=>e.shortname)))].sort(),o=tn(e,(e=>`**[${e}]**`)),a=Da(s[0]),c=n(a,t,e),l=t.for?`, for **"${t.for}"**, `:"",u=Dn`To fix, use the ${"[data-cite]"} attribute to pick the one you mean from the appropriate specification. ${r(c,a)}.`;En(`The term "**${a}**"${l} is ambiguous because it's defined in ${o}.`,Aa,{title:"Definition is ambiguous.",elements:s,hint:u})}}(s)}(n,r,i,e),s("beforesave",Ma)}});var Ua=String.raw`ul.index{columns:30ch;column-gap:1.5em}
955
955
  ul.index li{list-style:inherit}
956
956
  ul.index li span{color:inherit;cursor:pointer;white-space:normal}
957
957
  #index-defined-here ul.index li{font-size:.9rem}
@@ -959,37 +959,37 @@ ul.index code{color:inherit}
959
959
  #index-defined-here .print-only{display:none}
960
960
  @media print{
961
961
  #index-defined-here .print-only{display:initial}
962
- }`;const Ua=sn({en:{heading:"Index",headingExternal:"Terms defined by reference",headlingLocal:"Terms defined by this specification",dfnOf:"definition of"}}),qa=new Set(["attribute","callback","dict-member","dictionary","element-attr","element","enum-value","enum","exception","extended-attribute","interface","method","typedef"]);function Wa(e){const t=e.dataset,n=t.dfnType||t.idl||t.linkType||"";switch(n){case"":case"dfn":return"";default:return n}}function Fa(e){const t=e.closest("[data-dfn-for]:not([data-dfn-for=''])");return t?t.dataset.dfnFor:""}function Ba(e,t,n=""){if(n.startsWith("[[")){return`internal slot for <code>${Fa(e)}</code>`}switch(t){case"dict-member":case"method":case"attribute":case"enum-value":return`${"dict-member"===t?"member":t.replace("-"," ")} for <code>${Fa(e)}</code>`;case"interface":case"dictionary":case"enum":return t;case"constructor":return`for <code>${Fa(e)}</code>`;default:return""}}function Ha(){document.querySelectorAll("#index-defined-here li[data-id]").forEach((e=>e.append((e=>{const t=`§${document.getElementById(e).closest("section").querySelector(".secno").textContent.trim()}`;return Ot`<span class="print-only">${t}</span>`})(e.dataset.id))))}function Ga(){const e=new Set,t=new Map,n=document.querySelectorAll("a[data-cite]");for(const r of n){if(!r.dataset.cite)continue;const{cite:n,citeFrag:s,xrefType:i,linkType:o}=r.dataset;if(!(i||o||n.includes("#")||s))continue;const a=r.href;if(e.has(a))continue;const{type:c,linkFor:l}=r.dataset,u=Ia(r);if(!u)continue;const d=da(r).key.toUpperCase();(t.get(d)||t.set(d,[]).get(d)).push({term:u,type:c,linkFor:l,elem:r}),e.add(a)}return t}function Va(e){const{elem:t}=e,n=function(e){const{term:t,type:n,linkFor:r}=e;let s=t;qa.has(n)&&("extended-attribute"===n&&(s=`[${s}]`),s=`<code>${s}</code>`);const i=Ka.has(t)?"type":Ya.get(n);i&&(s+=` ${i}`);if(r){let e=r;/\s/.test(r)||(e=`<code>${e}</code>`),"element-attr"===n&&(e+=" element"),s+=` (for ${e})`}return s}(e);return Ot`<li>
962
+ }`;const qa=on({en:{heading:"Index",headingExternal:"Terms defined by reference",headlingLocal:"Terms defined by this specification",dfnOf:"definition of"}}),Wa=new Set(["attribute","callback","dict-member","dictionary","element-attr","element","enum-value","enum","exception","extended-attribute","interface","method","typedef"]);function Fa(e){const t=e.dataset,n=t.dfnType||t.idl||t.linkType||"";switch(n){case"":case"dfn":return"";default:return n}}function Ba(e){const t=e.closest("[data-dfn-for]:not([data-dfn-for=''])");return t?t.dataset.dfnFor:""}function Ha(e,t,n=""){if(n.startsWith("[[")){return`internal slot for <code>${Ba(e)}</code>`}switch(t){case"dict-member":case"method":case"attribute":case"enum-value":return`${"dict-member"===t?"member":t.replace("-"," ")} for <code>${Ba(e)}</code>`;case"interface":case"dictionary":case"enum":return t;case"constructor":return`for <code>${Ba(e)}</code>`;default:return""}}function Ga(){document.querySelectorAll("#index-defined-here li[data-id]").forEach((e=>e.append((e=>{const t=`§${document.getElementById(e).closest("section").querySelector(".secno").textContent.trim()}`;return jt`<span class="print-only">${t}</span>`})(e.dataset.id))))}function Va(){const e=new Set,t=new Map,n=document.querySelectorAll("a[data-cite]");for(const r of n){if(!r.dataset.cite)continue;const{cite:n,citeFrag:s,xrefType:i,linkType:o}=r.dataset;if(!(i||o||n.includes("#")||s))continue;const a=r.href;if(e.has(a))continue;const{type:c,linkFor:l}=r.dataset,u=Da(r);if(!u)continue;const d=pa(r).key.toUpperCase();(t.get(d)||t.set(d,[]).get(d)).push({term:u,type:c,linkFor:l,elem:r}),e.add(a)}return t}function Ya(e){const{elem:t}=e,n=function(e){const{term:t,type:n,linkFor:r}=e;let s=t;Wa.has(n)&&("extended-attribute"===n&&(s=`[${s}]`),s=`<code>${s}</code>`);const i=Za.has(t)?"type":Ka.get(n);i&&(s+=` ${i}`);if(r){let e=r;/\s/.test(r)||(e=`<code>${e}</code>`),"element-attr"===n&&(e+=" element"),s+=` (for ${e})`}return s}(e);return jt`<li>
963
963
  <span class="index-term" data-href="${t.href}">${{html:n}}</span>
964
- </li>`}const Ya=new Map([["attribute","attribute"],["element-attr","attribute"],["element","element"],["enum","enum"],["exception","exception"],["extended-attribute","extended attribute"],["interface","interface"]]),Ka=new Set(["boolean","byte","octet","short","unsigned short","long","unsigned long","long long","unsigned long long","float","unrestricted float","double","unrestricted double","undefined","any","object","symbol"]);function Za(e){e.querySelectorAll("#index-defined-elsewhere li[data-spec]").forEach((e=>e.removeAttribute("data-spec"))),e.querySelectorAll("#index-defined-here li[data-id]").forEach((e=>e.removeAttribute("data-id")))}var Ja=Object.freeze({__proto__:null,name:"core/dfn-index",run:function(){const e=document.querySelector("section#index");if(!e)return void s("toc",(()=>{}),{once:!0});const t=document.createElement("style");t.textContent=za,document.head.appendChild(t),e.classList.add("appendix"),e.querySelector("h2, h1")||e.prepend(Ot`<h1>${Ua.heading}</h1>`);const n=Ot`<section id="index-defined-here">
965
- <h3>${Ua.headlingLocal}</h3>
966
- ${function(){const e=function(){const e=new Map,t=document.querySelectorAll("dfn:not([data-cite])");for(const n of t){if(!n.id)continue;const t=rn(n.textContent);(e.get(t)||e.set(t,[]).get(t)).push(n)}return[...e].sort((([e],[t])=>e.slice(e.search(/\w/)).localeCompare(t.slice(t.search(/\w/)))))}();return Ot`<ul class="index">
967
- ${e.map((([e,t])=>function(e,t){const n=(e,t,n)=>{const r=`#${e.id}`;return Ot`<li data-id=${e.id}>
964
+ </li>`}const Ka=new Map([["attribute","attribute"],["element-attr","attribute"],["element","element"],["enum","enum"],["exception","exception"],["extended-attribute","extended attribute"],["interface","interface"]]),Za=new Set(["boolean","byte","octet","short","unsigned short","long","unsigned long","long long","unsigned long long","float","unrestricted float","double","unrestricted double","undefined","any","object","symbol"]);function Ja(e){e.querySelectorAll("#index-defined-elsewhere li[data-spec]").forEach((e=>e.removeAttribute("data-spec"))),e.querySelectorAll("#index-defined-here li[data-id]").forEach((e=>e.removeAttribute("data-id")))}var Xa=Object.freeze({__proto__:null,name:"core/dfn-index",run:function(){const e=document.querySelector("section#index");if(!e)return void s("toc",(()=>{}),{once:!0});const t=document.createElement("style");t.textContent=Ua,document.head.appendChild(t),e.classList.add("appendix"),e.querySelector("h2, h1")||e.prepend(jt`<h1>${qa.heading}</h1>`);const n=jt`<section id="index-defined-here">
965
+ <h3>${qa.headlingLocal}</h3>
966
+ ${function(){const e=function(){const e=new Map,t=document.querySelectorAll("dfn:not([data-cite])");for(const n of t){if(!n.id)continue;const t=sn(n.textContent);(e.get(t)||e.set(t,[]).get(t)).push(n)}return[...e].sort((([e],[t])=>e.slice(e.search(/\w/)).localeCompare(t.slice(t.search(/\w/)))))}();return jt`<ul class="index">
967
+ ${e.map((([e,t])=>function(e,t){const n=(e,t,n)=>{const r=`#${e.id}`;return jt`<li data-id=${e.id}>
968
968
  <a class="index-term" href="${r}">${{html:t}}</a> ${n?{html:n}:""}
969
- </li>`};if(1===t.length){const r=t[0],s=Wa(r),i=function(e,t,n){let r=n;"enum-value"===t&&(r=`"${r}"`);(qa.has(t)||e.dataset.idl||e.closest("code"))&&(r=`<code>${r}</code>`);return r}(r,s,e),o=Ba(r,s,e);return n(r,i,o)}return Ot`<li>
969
+ </li>`};if(1===t.length){const r=t[0],s=Fa(r),i=function(e,t,n){let r=n;"enum-value"===t&&(r=`"${r}"`);(Wa.has(t)||e.dataset.idl||e.closest("code"))&&(r=`<code>${r}</code>`);return r}(r,s,e),o=Ha(r,s,e);return n(r,i,o)}return jt`<li>
970
970
  ${e}
971
971
  <ul>
972
- ${t.map((t=>{const r=Ba(t,Wa(t),e)||Ua.dfnOf;return n(t,r)}))}
972
+ ${t.map((t=>{const r=Ha(t,Fa(t),e)||qa.dfnOf;return n(t,r)}))}
973
973
  </ul>
974
974
  </li>`}(e,t)))}
975
975
  </ul>`}()}
976
- </section>`;e.append(n);const r=Ot`<section id="index-defined-elsewhere">
977
- <h3>${Ua.headingExternal}</h3>
978
- ${function(){const e=[...Ga().entries()].sort((([e],[t])=>e.localeCompare(t)));return Ot`<ul class="index">
979
- ${e.map((([e,t])=>Ot`<li data-spec="${e}">
980
- ${Ai(e)} defines the following:
976
+ </section>`;e.append(n);const r=jt`<section id="index-defined-elsewhere">
977
+ <h3>${qa.headingExternal}</h3>
978
+ ${function(){const e=[...Va().entries()].sort((([e],[t])=>e.localeCompare(t)));return jt`<ul class="index">
979
+ ${e.map((([e,t])=>jt`<li data-spec="${e}">
980
+ ${Ti(e)} defines the following:
981
981
  <ul>
982
- ${t.sort(((e,t)=>e.term.localeCompare(t.term))).map(Va)}
982
+ ${t.sort(((e,t)=>e.term.localeCompare(t.term))).map(Ya)}
983
983
  </ul>
984
984
  </li>`))}
985
985
  </ul>`}()}
986
- </section>`;e.append(r);for(const e of r.querySelectorAll(".index-term"))fn(e,"index-term");s("toc",Ha,{once:!0}),s("beforesave",Za)}});const Xa="core/contrib";var Qa=Object.freeze({__proto__:null,name:Xa,run:async function(e){if(!document.getElementById("gh-contributors"))return;if(!e.github){return void Rn(In`Requested list of contributors from GitHub, but ${"[github]"} configuration option is not set.`,Xa)}const t=e.editors.map((e=>e.name)),n=`${e.github.apiBase}/${e.github.fullName}/`;await async function(e,t){const n=document.getElementById("gh-contributors");if(!n)return;n.textContent="Fetching list of contributors...";const r=await s();null!==r?function(e,t){const n=e.sort(((e,t)=>{const n=e.name||e.login,r=t.name||t.login;return n.toLowerCase().localeCompare(r.toLowerCase())}));if("UL"===t.tagName)return void Ot(t)`${n.map((({name:e,login:t})=>`<li><a href="https://github.com/${t}">${e||t}</a></li>`))}`;const r=n.map((e=>e.name||e.login));t.textContent=en(r)}(r,n):n.textContent="Failed to fetch contributors.";async function s(){const{href:n}=new URL("contributors",t);try{const t=await ln(n);if(!t.ok)throw new Error(`Request to ${n} failed with status code ${t.status}`);return(await t.json()).filter((t=>!e.includes(t.name||t.login)&&!t.login.includes("[bot]")))}catch(e){return Rn("Error loading contributors from GitHub.",Xa),console.error(e),null}}}(t,n)}});var ec=Object.freeze({__proto__:null,name:"core/fix-headers",run:function(){[...document.querySelectorAll("section:not(.introductory)")].map((e=>e.querySelector("h1, h2, h3, h4, h5, h6"))).filter((e=>e)).forEach((e=>{const t=Math.min(function(e,t){const n=[];for(;e!=e.ownerDocument.body;)e.matches(t)&&n.push(e),e=e.parentElement;return n}(e,"section").length+1,6);mn(e,`h${t}`)}))}});var tc=Object.freeze({__proto__:null,name:"core/webidl-index",run:function(){const e=document.querySelector("section#idl-index");if(!e)return;const t=[2,3,4,5,6].map((e=>`h${e}:first-child`)).join(",");if(!e.querySelector(t)){const t=document.createElement("h2");e.title?(t.textContent=e.title,e.removeAttribute("title")):t.textContent="IDL Index",e.prepend(t)}const n=Array.from(document.querySelectorAll("pre.idl:not(.exclude) > code")).filter((e=>!e.closest(Yt)));if(0===n.length){const t="This specification doesn't normatively declare any Web IDL.";return void e.append(t)}const r=document.createElement("pre");r.classList.add("idl","def"),r.id="actual-idl-index",n.map((e=>{const t=document.createDocumentFragment();for(const n of e.children)t.appendChild(n.cloneNode(!0));return t})).forEach((e=>{r.lastChild&&r.append("\n\n"),r.appendChild(e)})),r.querySelectorAll("*[id]").forEach((e=>e.removeAttribute("id"))),e.appendChild(r),bn(r,document.createElement("code")),na(r)}});const nc=["h2","h3","h4","h5","h6"],rc="core/structure",sc=sn({en:{toc:"Table of Contents"},zh:{toc:"内容大纲"},ko:{toc:"목차"},ja:{toc:"目次"},nl:{toc:"Inhoudsopgave"},es:{toc:"Tabla de Contenidos"},de:{toc:"Inhaltsverzeichnis"}});function ic(e,t,{prefix:n=""}={}){let r=!1,s=0,i=1;if(n.length&&!n.endsWith(".")&&(n+="."),0===e.length)return null;const o=Ot`<ol class="toc"></ol>`;for(const a of e){!a.isAppendix||n||r||(s=i,r=!0);let e=a.isIntro?"":r?oc(i-s+1):n+i;const c=e.split(".").length;if(1===c&&(e+=".",a.header.before(document.createComment("OddPage"))),a.isIntro||(i+=1,a.header.prepend(Ot`<bdi class="secno">${e} </bdi>`)),c<=t){const n=a.header.id||a.element.id,r=cc(a.header,n),s=ic(a.subsections,t,{prefix:e});s&&r.append(s),o.append(r)}}return o}function oc(e){let t="";for(;e>0;)e-=1,t=String.fromCharCode(65+e%26)+t,e=Math.floor(e/26);return t}function ac(e){const t=e.querySelectorAll(":scope > section"),n=[];for(const e of t){const t=e.classList.contains("notoc");if(!e.children.length||t)continue;const r=e.children[0];if(!nc.includes(r.localName))continue;const s=r.textContent;fn(e,null,s),n.push({element:e,header:r,title:s,isIntro:Boolean(e.closest(".introductory")),isAppendix:e.classList.contains("appendix"),subsections:ac(e)})}return n}function cc(e,t){const n=Ot`<a href="${`#${t}`}" class="tocxref" />`;var r;return n.append(...e.cloneNode(!0).childNodes),(r=n).querySelectorAll("a").forEach((e=>{const t=mn(e,"span");t.className="formerLink",t.removeAttribute("href")})),r.querySelectorAll("dfn").forEach((e=>{mn(e,"span").removeAttribute("id")})),Ot`<li class="tocline">${n}</li>`}var lc=Object.freeze({__proto__:null,name:rc,run:function(e){if("maxTocLevel"in e==!1&&(e.maxTocLevel=1/0),function(){const e=[...document.querySelectorAll("section:not(.introductory) :is(h1,h2,h3,h4,h5,h6):first-child")].filter((e=>!e.closest("section.introductory")));if(!e.length)return;e.forEach((e=>{const t=`h${Math.min(wn(e,"section").length+1,6)}`;e.localName!==t&&mn(e,t)}))}(),!e.noTOC){!function(){const e=document.querySelectorAll("section[data-max-toc]");for(const t of e){const e=parseInt(t.dataset.maxToc,10);if(e<0||e>6||Number.isNaN(e)){Rn("`data-max-toc` must have a value between 0-6 (inclusive).",rc,{elements:[t]});continue}if(0===e){t.classList.add("notoc");continue}const n=t.querySelectorAll(`:scope > ${Array.from({length:e},(()=>"section")).join(" > ")}`);for(const e of n)e.classList.add("notoc")}}();const t=ic(ac(document.body),e.maxTocLevel);t&&function(e){if(!e)return;const t=Ot`<nav id="toc"></nav>`,n=Ot`<h2 class="introductory">${sc.toc}</h2>`;fn(n),t.append(n,e);const r=document.getElementById("toc")||document.getElementById("sotd")||document.getElementById("abstract");r&&("toc"===r.id?r.replaceWith(t):r.after(t));const s=Ot`<p role="navigation" id="back-to-top">
986
+ </section>`;e.append(r);for(const e of r.querySelectorAll(".index-term"))hn(e,"index-term");s("toc",Ga,{once:!0}),s("beforesave",Ja)}});const Qa="core/contrib";var ec=Object.freeze({__proto__:null,name:Qa,run:async function(e){if(!document.getElementById("gh-contributors"))return;if(!e.github){return void En(Dn`Requested list of contributors from GitHub, but ${"[github]"} configuration option is not set.`,Qa)}const t=e.editors.map((e=>e.name)),n=`${e.github.apiBase}/${e.github.fullName}/`;await async function(e,t){const n=document.getElementById("gh-contributors");if(!n)return;n.textContent="Fetching list of contributors...";const r=await s();null!==r?function(e,t){const n=e.sort(((e,t)=>{const n=e.name||e.login,r=t.name||t.login;return n.toLowerCase().localeCompare(r.toLowerCase())}));if("UL"===t.tagName)return void jt(t)`${n.map((({name:e,login:t})=>`<li><a href="https://github.com/${t}">${e||t}</a></li>`))}`;const r=n.map((e=>e.name||e.login));t.textContent=tn(r)}(r,n):n.textContent="Failed to fetch contributors.";async function s(){const{href:n}=new URL("contributors",t);try{const t=await un(n);if(!t.ok)throw new Error(`Request to ${n} failed with status code ${t.status}`);return(await t.json()).filter((t=>!e.includes(t.name||t.login)&&!t.login.includes("[bot]")))}catch(e){return En("Error loading contributors from GitHub.",Qa),console.error(e),null}}}(t,n)}});var tc=Object.freeze({__proto__:null,name:"core/fix-headers",run:function(){[...document.querySelectorAll("section:not(.introductory)")].map((e=>e.querySelector("h1, h2, h3, h4, h5, h6"))).filter((e=>e)).forEach((e=>{const t=Math.min(function(e,t){const n=[];for(;e!=e.ownerDocument.body;)e.matches(t)&&n.push(e),e=e.parentElement;return n}(e,"section").length+1,6);gn(e,`h${t}`)}))}});var nc=Object.freeze({__proto__:null,name:"core/webidl-index",run:function(){const e=document.querySelector("section#idl-index");if(!e)return;const t=[2,3,4,5,6].map((e=>`h${e}:first-child`)).join(",");if(!e.querySelector(t)){const t=document.createElement("h2");e.title?(t.textContent=e.title,e.removeAttribute("title")):t.textContent="IDL Index",e.prepend(t)}const n=Array.from(document.querySelectorAll("pre.idl:not(.exclude) > code")).filter((e=>!e.closest(Kt)));if(0===n.length){const t="This specification doesn't normatively declare any Web IDL.";return void e.append(t)}const r=document.createElement("pre");r.classList.add("idl","def"),r.id="actual-idl-index",n.map((e=>{const t=document.createDocumentFragment();for(const n of e.children)t.appendChild(n.cloneNode(!0));return t})).forEach((e=>{r.lastChild&&r.append("\n\n"),r.appendChild(e)})),r.querySelectorAll("*[id]").forEach((e=>e.removeAttribute("id"))),e.appendChild(r),yn(r,document.createElement("code")),ra(r)}});const rc=["h2","h3","h4","h5","h6"],sc="core/structure",ic=on({en:{toc:"Table of Contents"},zh:{toc:"内容大纲"},ko:{toc:"목차"},ja:{toc:"目次"},nl:{toc:"Inhoudsopgave"},es:{toc:"Tabla de Contenidos"},de:{toc:"Inhaltsverzeichnis"}});function oc(e,t,{prefix:n=""}={}){let r=!1,s=0,i=1;if(n.length&&!n.endsWith(".")&&(n+="."),0===e.length)return null;const o=jt`<ol class="toc"></ol>`;for(const a of e){!a.isAppendix||n||r||(s=i,r=!0);let e=a.isIntro?"":r?ac(i-s+1):n+i;const c=e.split(".").length;if(1===c&&(e+=".",a.header.before(document.createComment("OddPage"))),a.isIntro||(i+=1,a.header.prepend(jt`<bdi class="secno">${e} </bdi>`)),c<=t){const n=a.header.id||a.element.id,r=lc(a.header,n),s=oc(a.subsections,t,{prefix:e});s&&r.append(s),o.append(r)}}return o}function ac(e){let t="";for(;e>0;)e-=1,t=String.fromCharCode(65+e%26)+t,e=Math.floor(e/26);return t}function cc(e){const t=e.querySelectorAll(":scope > section"),n=[];for(const e of t){const t=e.classList.contains("notoc");if(!e.children.length||t)continue;const r=e.children[0];if(!rc.includes(r.localName))continue;const s=r.textContent;hn(e,null,s),n.push({element:e,header:r,title:s,isIntro:Boolean(e.closest(".introductory")),isAppendix:e.classList.contains("appendix"),subsections:cc(e)})}return n}function lc(e,t){const n=jt`<a href="${`#${t}`}" class="tocxref" />`;var r;return n.append(...e.cloneNode(!0).childNodes),(r=n).querySelectorAll("a").forEach((e=>{const t=gn(e,"span");t.className="formerLink",t.removeAttribute("href")})),r.querySelectorAll("dfn").forEach((e=>{gn(e,"span").removeAttribute("id")})),jt`<li class="tocline">${n}</li>`}var uc=Object.freeze({__proto__:null,name:sc,run:function(e){if("maxTocLevel"in e==!1&&(e.maxTocLevel=1/0),function(){const e=[...document.querySelectorAll("section:not(.introductory) :is(h1,h2,h3,h4,h5,h6):first-child")].filter((e=>!e.closest("section.introductory")));if(!e.length)return;e.forEach((e=>{const t=`h${Math.min(vn(e,"section").length+1,6)}`;e.localName!==t&&gn(e,t)}))}(),!e.noTOC){!function(){const e=document.querySelectorAll("section[data-max-toc]");for(const t of e){const e=parseInt(t.dataset.maxToc,10);if(e<0||e>6||Number.isNaN(e)){En("`data-max-toc` must have a value between 0-6 (inclusive).",sc,{elements:[t]});continue}if(0===e){t.classList.add("notoc");continue}const n=t.querySelectorAll(`:scope > ${Array.from({length:e},(()=>"section")).join(" > ")}`);for(const e of n)e.classList.add("notoc")}}();const t=oc(cc(document.body),e.maxTocLevel);t&&function(e){if(!e)return;const t=jt`<nav id="toc"></nav>`,n=jt`<h2 class="introductory">${ic.toc}</h2>`;hn(n),t.append(n,e);const r=document.getElementById("toc")||document.getElementById("sotd")||document.getElementById("abstract");r&&("toc"===r.id?r.replaceWith(t):r.after(t));const s=jt`<p role="navigation" id="back-to-top">
987
987
  <a href="#title"><abbr title="Back to Top">&uarr;</abbr></a>
988
- </p>`;document.body.append(s)}(t)}r("toc")}});const uc=sn({en:{informative:"This section is non-normative."},nl:{informative:"Dit onderdeel is niet normatief."},ko:{informative:"이 부분은 비규범적입니다."},ja:{informative:"この節は仕様には含まれません."},de:{informative:"Dieser Abschnitt ist nicht normativ."},zh:{informative:"本章节不包含规范性内容。"}});var dc=Object.freeze({__proto__:null,name:"core/informative",run:function(){Array.from(document.querySelectorAll("section.informative")).map((e=>e.querySelector("h2, h3, h4, h5, h6"))).filter((e=>e)).forEach((e=>{e.after(Ot`<p><em>${uc.informative}</em></p>`)}))}});const pc=sn({en:{permalinkLabel(e,t){let n=`Permalink for${t?"":" this"} ${e}`;return t&&(n+=` ${rn(t.textContent)}`),n}}});var fc=Object.freeze({__proto__:null,name:"core/id-headers",run:function(e){const t=document.querySelectorAll("section:not(.head,#abstract,#sotd) h2, h3, h4, h5, h6");for(const n of t){let t=n.id;if(t||(fn(n),t=n.parentElement.id||n.id),!e.addSectionLinks)continue;const r=pc.permalinkLabel(n.closest(".appendix")?"Appendix":"Section",n.querySelector(":scope > bdi.secno")),s=Ot`<div class="header-wrapper"></div>`;n.replaceWith(s);const i=Ot`<a
988
+ </p>`;document.body.append(s)}(t)}r("toc")}});const dc=on({en:{informative:"This section is non-normative."},nl:{informative:"Dit onderdeel is niet normatief."},ko:{informative:"이 부분은 비규범적입니다."},ja:{informative:"この節は仕様には含まれません."},de:{informative:"Dieser Abschnitt ist nicht normativ."},zh:{informative:"本章节不包含规范性内容。"}});var pc=Object.freeze({__proto__:null,name:"core/informative",run:function(){Array.from(document.querySelectorAll("section.informative")).map((e=>e.querySelector("h2, h3, h4, h5, h6"))).filter((e=>e)).forEach((e=>{e.after(jt`<p><em>${dc.informative}</em></p>`)}))}});const fc=on({en:{permalinkLabel(e,t){let n=`Permalink for${t?"":" this"} ${e}`;return t&&(n+=` ${sn(t.textContent)}`),n}}});var hc=Object.freeze({__proto__:null,name:"core/id-headers",run:function(e){const t=document.querySelectorAll("section:not(.head,#abstract,#sotd) h2, h3, h4, h5, h6");for(const n of t){let t=n.id;if(t||(hn(n),t=n.parentElement.id||n.id),!e.addSectionLinks)continue;const r=fc.permalinkLabel(n.closest(".appendix")?"Appendix":"Section",n.querySelector(":scope > bdi.secno")),s=jt`<div class="header-wrapper"></div>`;n.replaceWith(s);const i=jt`<a
989
989
  href="#${t}"
990
990
  class="self-link"
991
991
  aria-label="${r}"
992
- ></a>`;s.append(n,i)}}});var hc=String.raw`.caniuse-stats{display:flex;column-gap:2em}
992
+ ></a>`;s.append(n,i)}}});var mc=String.raw`.caniuse-stats{display:flex;column-gap:2em}
993
993
  .caniuse-group{display:flex;flex:1;flex-direction:column;justify-content:flex-end;flex-basis:auto}
994
994
  .caniuse-browsers{display:flex;align-items:baseline;justify-content:space-between;flex-wrap:wrap;margin-top:.2em;column-gap:.4em;border-bottom:1px solid #ccc;row-gap:.4em;padding-bottom:.4cm}
995
995
  .caniuse-type{align-self:center;border-top:none;text-transform:capitalize;font-size:.8em;margin-top:-.8em;font-weight:700}
@@ -1007,12 +1007,12 @@ img.caniuse-browser{filter:drop-shadow(0 0 .1cm #666)}
1007
1007
  .caniuse-cell.y::before{content:"✔️";padding:.5em}
1008
1008
  .caniuse-cell.n::before{content:"❌";padding:.5em}
1009
1009
  .caniuse-cell:is(.a,.d,.p,.x,.u)::before{content:"⚠️";padding:.5em}
1010
- }`;const mc="core/caniuse",gc="https://respec.org/caniuse/",bc=new Map([["and_chr",{name:"Android Chrome",path:"chrome",type:"mobile"}],["and_ff",{name:"Android Firefox",path:"firefox",type:"mobile"}],["and_uc",{name:"Android UC",path:"uc",type:"mobile"}],["chrome",{name:"Chrome",type:"desktop"}],["edge",{name:"Edge",type:"desktop"}],["firefox",{name:"Firefox",type:"desktop"}],["ios_saf",{name:"iOS Safari",path:"safari-ios",type:"mobile"}],["op_mob",{name:"Opera Mobile",path:"opera",type:"mobile"}],["opera",{name:"Opera",type:"desktop"}],["safari",{name:"Safari",type:"desktop"}],["samsung",{name:"Samsung Internet",path:"samsung-internet",type:"mobile"}]]),yc=new Map([["a","almost supported (aka Partial support)"],["d","disabled by default"],["n","no support, or disabled by default"],["p","no support, but has Polyfill"],["u","unknown support"],["x","requires prefix to work"],["y","supported by default"]]);var wc=Object.freeze({__proto__:null,BROWSERS:bc,name:mc,prepare:function(e){if(!e.caniuse)return;!function(e){const t=new Set(bc.keys());t.delete("op_mob"),t.delete("opera");const n={removeOnSave:!0,browsers:[...t]};if("string"==typeof e.caniuse)return void(e.caniuse={feature:e.caniuse,...n});e.caniuse={...n,...e.caniuse}}(e),function({caniuse:e}){const{browsers:t}=e,n=t.filter((e=>!bc.has(e)));if(n.length){En(In`Invalid browser(s): (${Ln(n,{quotes:!0})}) in the \`browser\` property of ${"[caniuse]"}.`,mc)}}(e);const t=e.caniuse;t.feature&&document.head.appendChild(Ot`<style
1011
- id="caniuse-stylesheet"
1012
- class="${t.removeOnSave?"removeOnSave":""}"
1013
- >
1014
- ${hc}
1015
- </style>`)},run:async function(e){const t=e.caniuse;if(!t?.feature)return;const n=new URL(t.feature,"https://caniuse.com/").href,i=document.querySelector(".head dl"),o=async function(e){const{feature:t,browsers:n,apiURL:r}=e,s=new URL(r||`./${t}`,gc);n.forEach((e=>s.searchParams.append("browsers",e)));const i=await fetch(s);if(!i.ok){const{status:e,statusText:t}=i;throw new Error(`Failed to get caniuse data: (${e}) ${t}`)}return i.json()}(e.caniuse).then((e=>async function(e,{feature:t}){const n=e.result,r=new Map([["desktop",[]],["mobile",[]]]),s=function(e){return(t,{browser:n,version:r,caniuse:s})=>{const{name:i,type:o}=bc.get(n),a=`${i}${r?` version ${r}`:""}`,c=yc.get(s),l=`${e} is ${c} since ${a} on ${o}.`,u=`caniuse-cell ${s}`,d=(p=`${c} since ${a}.`).charAt(0).toUpperCase()+p.slice(1);var p;const f=r||"—",h=function(e){const t=bc.get(e).path??e;return`https://www.w3.org/assets/logos/browser-logos/${t}/${t}.svg`}(n),m=Ot`
1010
+ }`;const gc="core/caniuse",bc="https://respec.org/caniuse/",yc=new Map([["and_chr",{name:"Android Chrome",path:"chrome",type:"mobile"}],["and_ff",{name:"Android Firefox",path:"firefox",type:"mobile"}],["and_uc",{name:"Android UC",path:"uc",type:"mobile"}],["chrome",{name:"Chrome",type:"desktop"}],["edge",{name:"Edge",type:"desktop"}],["firefox",{name:"Firefox",type:"desktop"}],["ios_saf",{name:"iOS Safari",path:"safari-ios",type:"mobile"}],["op_mob",{name:"Opera Mobile",path:"opera",type:"mobile"}],["opera",{name:"Opera",type:"desktop"}],["safari",{name:"Safari",type:"desktop"}],["samsung",{name:"Samsung Internet",path:"samsung-internet",type:"mobile"}]]),wc=new Map([["a","almost supported (aka Partial support)"],["d","disabled by default"],["n","no support, or disabled by default"],["p","no support, but has Polyfill"],["u","unknown support"],["x","requires prefix to work"],["y","supported by default"]]);var vc=Object.freeze({__proto__:null,BROWSERS:yc,name:gc,prepare:function(e){if(!e.caniuse)return;!function(e){const t=new Set(yc.keys());t.delete("op_mob"),t.delete("opera");const n={removeOnSave:!0,browsers:[...t]};if("string"==typeof e.caniuse)return void(e.caniuse={feature:e.caniuse,...n});e.caniuse={...n,...e.caniuse}}(e),function({caniuse:e}){const{browsers:t}=e,n=t.filter((e=>!yc.has(e)));if(n.length){An(Dn`Invalid browser(s): (${Pn(n,{quotes:!0})}) in the \`browser\` property of ${"[caniuse]"}.`,gc)}}(e);const t=e.caniuse;t.feature&&document.head.appendChild(jt`<style
1011
+ id="caniuse-stylesheet"
1012
+ class="${t.removeOnSave?"removeOnSave":""}"
1013
+ >
1014
+ ${mc}
1015
+ </style>`)},run:async function(e){const t=e.caniuse;if(!t?.feature)return;const n=new URL(t.feature,"https://caniuse.com/").href,i=document.querySelector(".head dl"),o=async function(e){const{feature:t,browsers:n,apiURL:r}=e,s=new URL(r||`./${t}`,bc);n.forEach((e=>s.searchParams.append("browsers",e)));const i=await fetch(s);if(!i.ok){const{status:e,statusText:t}=i;throw new Error(`Failed to get caniuse data: (${e}) ${t}`)}return i.json()}(e.caniuse).then((e=>async function(e,{feature:t}){const n=e.result,r=new Map([["desktop",[]],["mobile",[]]]),s=function(e){return(t,{browser:n,version:r,caniuse:s})=>{const{name:i,type:o}=yc.get(n),a=`${i}${r?` version ${r}`:""}`,c=wc.get(s),l=`${e} is ${c} since ${a} on ${o}.`,u=`caniuse-cell ${s}`,d=(p=`${c} since ${a}.`).charAt(0).toUpperCase()+p.slice(1);var p;const f=r||"—",h=function(e){const t=yc.get(e).path??e;return`https://www.w3.org/assets/logos/browser-logos/${t}/${t}.svg`}(n),m=jt`
1016
1016
  <div class="${u}" title="${d}" aria-label="${l}">
1017
1017
  <img
1018
1018
  class="caniuse-browser"
@@ -1022,16 +1022,16 @@ img.caniuse-browser{filter:drop-shadow(0 0 .1cm #666)}
1022
1022
  alt="${i} logo"
1023
1023
  /><span class="browser-version">${f}</span>
1024
1024
  </div>
1025
- `;return t.get(o).push(m),t}}(t);n.reduce(s,r);const i=[...r].filter((([,e])=>e.length)).map((([e,t])=>Ot`<div class="caniuse-group">
1025
+ `;return t.get(o).push(m),t}}(t);n.reduce(s,r);const i=[...r].filter((([,e])=>e.length)).map((([e,t])=>jt`<div class="caniuse-group">
1026
1026
  <div class="caniuse-browsers">${t}</div>
1027
1027
  <div class="caniuse-type"><span>${e}</div>
1028
- </div>`));return i.push(Ot`<a class="caniuse-cell" href="https://caniuse.com/${t}"
1028
+ </div>`));return i.push(jt`<a class="caniuse-cell" href="https://caniuse.com/${t}"
1029
1029
  >More info</a
1030
- >`),i}(e,t))).catch((e=>function(e,t,n){const r=`Failed to retrieve feature "${t.feature}".`,s=In`Please check the feature key on [caniuse.com](https://caniuse.com) and update ${"[caniuse]"}.`;return Rn(r,mc,{hint:s}),console.error(e),Ot`<a href="${n}">caniuse.com</a>`}(e,t,n))),a=Ot`<dt class="caniuse-title">Browser support:</dt>
1030
+ >`),i}(e,t))).catch((e=>function(e,t,n){const r=`Failed to retrieve feature "${t.feature}".`,s=Dn`Please check the feature key on [caniuse.com](https://caniuse.com) and update ${"[caniuse]"}.`;return En(r,gc,{hint:s}),console.error(e),jt`<a href="${n}">caniuse.com</a>`}(e,t,n))),a=jt`<dt class="caniuse-title">Browser support:</dt>
1031
1031
  <dd class="caniuse-stats">
1032
1032
  ${{any:o,placeholder:"Fetching data from caniuse.com..."}}
1033
- </dd>`;i.append(...a.childNodes),await o,r("amend-user-config",{caniuse:t.feature}),t.removeOnSave&&(i.querySelectorAll(".caniuse-browser").forEach((e=>e.classList.add("removeOnSave"))),s("beforesave",(e=>{Ot.bind(e.querySelector(".caniuse-stats"))`
1034
- <a href="${n}">caniuse.com</a>`})))}});var vc=String.raw`.mdn{font-size:.75em;position:absolute;right:.3em;min-width:0;margin-top:3rem}
1033
+ </dd>`;i.append(...a.childNodes),await o,r("amend-user-config",{caniuse:t.feature}),t.removeOnSave&&(i.querySelectorAll(".caniuse-browser").forEach((e=>e.classList.add("removeOnSave"))),s("beforesave",(e=>{jt.bind(e.querySelector(".caniuse-stats"))`
1034
+ <a href="${n}">caniuse.com</a>`})))}});var $c=String.raw`.mdn{font-size:.75em;position:absolute;right:.3em;min-width:0;margin-top:3rem}
1035
1035
  .mdn details{width:100%;margin:1px 0;position:relative;z-index:10;box-sizing:border-box;padding:.4em;padding-top:0}
1036
1036
  .mdn details[open]{min-width:25ch;max-width:32ch;background:#fff;box-shadow:0 1em 3em -.4em rgba(0,0,0,.3),0 0 1px 1px rgba(0,0,0,.05);border-radius:2px;z-index:11;margin-bottom:.4em}
1037
1037
  .mdn summary{text-align:right;cursor:default;margin-right:-.4em}
@@ -1054,33 +1054,33 @@ img.caniuse-browser{filter:drop-shadow(0 0 .1cm #666)}
1054
1054
  .mdn .safari::before{background-image:url(https://www.w3.org/assets/logos/browser-logos/safari/safari.svg)}
1055
1055
  .mdn .safari_ios::before{background-image:url(https://www.w3.org/assets/logos/browser-logos/safari-ios/safari-ios.svg)}
1056
1056
  .mdn .samsunginternet_android::before{background-image:url(https://www.w3.org/assets/logos/browser-logos/samsung-internet/samsung-internet.svg)}
1057
- .mdn .webview_android::before{background-image:url(https://www.w3.org/assets/logos/browser-logos/android-webview/android-webview.png)}`;const $c="core/mdn-annotation",kc="https://w3c.github.io/mdn-spec-links/",xc={chrome:"Chrome",chrome_android:"Chrome Android",edge:"Edge",edge_mobile:"Edge Mobile",firefox:"Firefox",firefox_android:"Firefox Android",opera:"Opera",opera_android:"Opera Android",safari:"Safari",safari_ios:"Safari iOS",samsunginternet_android:"Samsung Internet",webview_android:"WebView Android"},_c=sn({en:{inAllEngines:"This feature is in all major engines.",inSomeEngines:"This feature has limited support."},zh:{inAllEngines:"所有主要引擎均支持此特性。",inSomeEngines:"此功能支持有限。"}});function Cc(e){const t=e.closest("section");if(!t)return;const{previousElementSibling:n}=t;if(n&&n.classList.contains("mdn"))return n;const r=Ot`<aside class="mdn"></aside>`;return t.before(r),r}function Sc(e){const{name:t,slug:n,summary:r,support:s,engines:i}=e,o=n.slice(n.indexOf("/")+1),a=`https://developer.mozilla.org/en-US/docs/Web/${n}`,c=`Expand MDN details for ${t}`,l=function(e){if(3===e.length)return Ot`<span title="${_c.inAllEngines}">✅</span>`;if(e.length<2)return Ot`<span title="${_c.inSomeEngines}">🚫</span>`;return Ot`<span>&emsp;</span>`}(i);return Ot`<details>
1057
+ .mdn .webview_android::before{background-image:url(https://www.w3.org/assets/logos/browser-logos/android-webview/android-webview.png)}`;const kc="core/mdn-annotation",xc="https://w3c.github.io/mdn-spec-links/",_c={chrome:"Chrome",chrome_android:"Chrome Android",edge:"Edge",edge_mobile:"Edge Mobile",firefox:"Firefox",firefox_android:"Firefox Android",opera:"Opera",opera_android:"Opera Android",safari:"Safari",safari_ios:"Safari iOS",samsunginternet_android:"Samsung Internet",webview_android:"WebView Android"},Sc=on({en:{inAllEngines:"This feature is in all major engines.",inSomeEngines:"This feature has limited support."},zh:{inAllEngines:"所有主要引擎均支持此特性。",inSomeEngines:"此功能支持有限。"}});function Cc(e){const t=e.closest("section");if(!t)return;const{previousElementSibling:n}=t;if(n&&n.classList.contains("mdn"))return n;const r=jt`<aside class="mdn"></aside>`;return t.before(r),r}function Rc(e){const{name:t,slug:n,summary:r,support:s,engines:i}=e,o=n.slice(n.indexOf("/")+1),a=`https://developer.mozilla.org/en-US/docs/Web/${n}`,c=`Expand MDN details for ${t}`,l=function(e){if(3===e.length)return jt`<span title="${Sc.inAllEngines}">✅</span>`;if(e.length<2)return jt`<span title="${Sc.inSomeEngines}">🚫</span>`;return jt`<span>&emsp;</span>`}(i);return jt`<details>
1058
1058
  <summary aria-label="${c}"><span>MDN</span>${l}</summary>
1059
1059
  <a title="${r}" href="${a}">${o}</a>
1060
- ${function(e){if(3===e.length)return Ot`<p class="engines-all">${_c.inAllEngines}</p>`;if(e.length<2)return Ot`<p class="engines-some">${_c.inSomeEngines}</p>`}(i)}
1061
- ${s?function(e){function t(e,t,n){const r="Unknown"===t?"?":t,s=`${e} ${t.toLowerCase()}`;return Ot`<tr class="${s}">
1062
- <td>${xc[e]}</td>
1060
+ ${function(e){if(3===e.length)return jt`<p class="engines-all">${Sc.inAllEngines}</p>`;if(e.length<2)return jt`<p class="engines-some">${Sc.inSomeEngines}</p>`}(i)}
1061
+ ${s?function(e){function t(e,t,n){const r="Unknown"===t?"?":t,s=`${e} ${t.toLowerCase()}`;return jt`<tr class="${s}">
1062
+ <td>${_c[e]}</td>
1063
1063
  <td>${n||r}</td>
1064
- </tr>`}function n(e,n){if(n.version_removed)return t(e,"No","");const r=n.version_added;return"boolean"==typeof r?t(e,r?"Yes":"No",""):r?t(e,"Yes",`${r}+`):t(e,"Unknown","")}return Ot`<table>
1065
- ${Object.keys(xc).map((r=>e[r]?n(r,e[r]):t(r,"Unknown","")))}
1066
- </table>`}(s):Ot`<p class="nosupportdata">No support data.</p>`}
1067
- </details>`}var Rc=Object.freeze({__proto__:null,name:$c,run:async function(e){const t=function(e){const{shortName:t,mdn:n}=e;if(!n)return;return"string"==typeof n?n:n.key||t}(e);if(!t)return;const n=await async function(e,t){const{baseJsonPath:n=kc,maxAge:r=864e5}=t,s=new URL(`${e}.json`,n).href,i=await ln(s,r);if(404===i.status){return void Rn(`Could not find MDN data associated with key "${e}".`,$c,{hint:"Please add a valid key to `respecConfig.mdn`"})}return await i.json()}(t,e.mdn);if(!n)return;const r=document.createElement("style");r.textContent=vc,document.head.append(r);for(const e of function(e){return[...document.body.querySelectorAll("[id]:not(script)")].filter((({id:t})=>Array.isArray(e[t])))}(n)){const t=n[e.id],r=Cc(e);if(r)for(const e of t)r.append(Sc(e))}}});const Ec="ui/save-html",Ac=sn({en:{save_snapshot:"Export"},nl:{save_snapshot:"Bewaar Snapshot"},ja:{save_snapshot:"保存する"},de:{save_snapshot:"Exportieren"},zh:{save_snapshot:"导出"}}),Tc=[{id:"respec-save-as-html",ext:"html",title:"HTML",type:"text/html",get href(){return Nn(this.type)}},{id:"respec-save-as-xml",ext:"xhtml",title:"XML",type:"application/xml",get href(){return Nn(this.type)}},{id:"respec-save-as-epub",ext:"epub",title:"EPUB 3",type:"application/epub+zip",get href(){const e=new URL("https://labs.w3.org/r2epub/");return e.searchParams.append("respec","true"),e.searchParams.append("url",document.location.href),e.href}}];var Lc=Object.freeze({__proto__:null,exportDocument:function(e,t){return En("Exporting via ui/save-html module's `exportDocument()` is deprecated and will be removed.",Ec,{hint:"Use core/exporter `rsDocToDataURL()` instead."}),Nn(t)},name:Ec,run:function(e){const t={async show(t){await document.respec.ready;const n=Ot`<div class="respec-save-buttons">
1068
- ${Tc.map((t=>function(e,t){const{id:n,href:r,ext:s,title:i,type:o}=e,a=an(t.publishDate||new Date),c=[t.specStatus,t.shortName||"spec",a].join("-");return Ot`<a
1064
+ </tr>`}function n(e,n){if(n.version_removed)return t(e,"No","");const r=n.version_added;return"boolean"==typeof r?t(e,r?"Yes":"No",""):r?t(e,"Yes",`${r}+`):t(e,"Unknown","")}return jt`<table>
1065
+ ${Object.keys(_c).map((r=>e[r]?n(r,e[r]):t(r,"Unknown","")))}
1066
+ </table>`}(s):jt`<p class="nosupportdata">No support data.</p>`}
1067
+ </details>`}var Ec=Object.freeze({__proto__:null,name:kc,run:async function(e){const t=function(e){const{shortName:t,mdn:n}=e;if(!n)return;return"string"==typeof n?n:n.key||t}(e);if(!t)return;const n=await async function(e,t){const{baseJsonPath:n=xc,maxAge:r=864e5}=t,s=new URL(`${e}.json`,n).href,i=await un(s,r);if(404===i.status){return void En(`Could not find MDN data associated with key "${e}".`,kc,{hint:"Please add a valid key to `respecConfig.mdn`"})}return await i.json()}(t,e.mdn);if(!n)return;const r=document.createElement("style");r.textContent=$c,document.head.append(r);for(const e of function(e){return[...document.body.querySelectorAll("[id]:not(script)")].filter((({id:t})=>Array.isArray(e[t])))}(n)){const t=n[e.id],r=Cc(e);if(r)for(const e of t)r.append(Rc(e))}}});const Ac="ui/save-html",Tc=on({en:{save_snapshot:"Export"},nl:{save_snapshot:"Bewaar Snapshot"},ja:{save_snapshot:"保存する"},de:{save_snapshot:"Exportieren"},zh:{save_snapshot:"导出"}}),Lc=[{id:"respec-save-as-html",ext:"html",title:"HTML",type:"text/html",get href(){return On(this.type)}},{id:"respec-save-as-xml",ext:"xhtml",title:"XML",type:"application/xml",get href(){return On(this.type)}},{id:"respec-save-as-epub",ext:"epub",title:"EPUB 3",type:"application/epub+zip",get href(){const e=new URL("https://labs.w3.org/r2epub/");return e.searchParams.append("respec","true"),e.searchParams.append("url",document.location.href),e.href}}];var Pc=Object.freeze({__proto__:null,exportDocument:function(e,t){return An("Exporting via ui/save-html module's `exportDocument()` is deprecated and will be removed.",Ac,{hint:"Use core/exporter `rsDocToDataURL()` instead."}),On(t)},name:Ac,run:function(e){const t={async show(t){await document.respec.ready;const n=jt`<div class="respec-save-buttons">
1068
+ ${Lc.map((t=>function(e,t){const{id:n,href:r,ext:s,title:i,type:o}=e,a=cn(t.publishDate||new Date),c=[t.specStatus,t.shortName||"spec",a].join("-");return jt`<a
1069
1069
  href="${r}"
1070
1070
  id="${n}"
1071
1071
  download="${c}.${s}"
1072
1072
  type="${o}"
1073
1073
  class="respec-save-button"
1074
- onclick=${()=>pr.closeModal()}
1074
+ onclick=${()=>fr.closeModal()}
1075
1075
  >${i}</a
1076
1076
  >`}(t,e)))}
1077
- </div>`;pr.freshModal(Ac.save_snapshot,n,t)}},n="download"in HTMLAnchorElement.prototype;let r;n&&(r=pr.addCommand(Ac.save_snapshot,(function(){if(!n)return;t.show(r)}),"Ctrl+Shift+Alt+S","💾"))}});const Pc="https://respec.org/specref/",Ic=sn({en:{search_specref:"Search Specref"},nl:{search_specref:"Doorzoek Specref"},ja:{search_specref:"仕様検索"},de:{search_specref:"Spezifikationen durchsuchen"},zh:{search_specref:"搜索 Specref"}}),Dc=pr.addCommand(Ic.search_specref,(function(){const e=Ot`
1078
- <iframe class="respec-iframe" src="${Pc}" onload=${e=>e.target.classList.add("ready")}></iframe>
1079
- <a href="${Pc}" target="_blank">Open Search UI in a new tab</a>
1080
- `;pr.freshModal(Ic.search_specref,e,Dc)}),"Ctrl+Shift+Alt+space","🔎");var Nc=Object.freeze({__proto__:null});const Oc="https://respec.org/xref/",jc=sn({en:{title:"Search definitions"},ja:{title:"定義検索"},de:{title:"Definitionen durchsuchen"},zh:{title:"搜索定义"}}),Mc=pr.addCommand(jc.title,(function(){const e=Ot`
1081
- <iframe class="respec-iframe" src="${Oc}" onload="${e=>e.target.classList.add("ready")}"></iframe>
1082
- <a href="${Oc}" target="_blank">Open Search UI in a new tab</a>
1083
- `;pr.freshModal(jc.title,e,Mc)}),"Ctrl+Shift+Alt+x","📚");var zc=Object.freeze({__proto__:null});const Uc=sn({en:{about_respec:"About"},zh:{about_respec:"关于"},nl:{about_respec:"Over"},ja:{about_respec:"これについて"},de:{about_respec:"Über"}});window.respecVersion=window.respecVersion||"Developer Edition";const qc=document.createElement("div"),Wc=Ot.bind(qc),Fc=pr.addCommand(`${Uc.about_respec} ${window.respecVersion}`,(function(){const e=[];"getEntriesByType"in performance&&performance.getEntriesByType("measure").sort(((e,t)=>t.duration-e.duration)).map((({name:e,duration:t})=>({name:e,duration:t>1e3?`${Math.round(t/1e3)} second(s)`:`${t.toFixed(2)} milliseconds`}))).map(Bc).forEach((t=>{e.push(t)}));Wc`
1077
+ </div>`;fr.freshModal(Tc.save_snapshot,n,t)}},n="download"in HTMLAnchorElement.prototype;let r;n&&(r=fr.addCommand(Tc.save_snapshot,(function(){if(!n)return;t.show(r)}),"Ctrl+Shift+Alt+S","💾"))}});const Ic="https://respec.org/specref/",Dc=on({en:{search_specref:"Search Specref"},nl:{search_specref:"Doorzoek Specref"},ja:{search_specref:"仕様検索"},de:{search_specref:"Spezifikationen durchsuchen"},zh:{search_specref:"搜索 Specref"}}),Nc=fr.addCommand(Dc.search_specref,(function(){const e=jt`
1078
+ <iframe class="respec-iframe" src="${Ic}" onload=${e=>e.target.classList.add("ready")}></iframe>
1079
+ <a href="${Ic}" target="_blank">Open Search UI in a new tab</a>
1080
+ `;fr.freshModal(Dc.search_specref,e,Nc)}),"Ctrl+Shift+Alt+space","🔎");var Oc=Object.freeze({__proto__:null});const jc="https://respec.org/xref/",Mc=on({en:{title:"Search definitions"},ja:{title:"定義検索"},de:{title:"Definitionen durchsuchen"},zh:{title:"搜索定义"}}),zc=fr.addCommand(Mc.title,(function(){const e=jt`
1081
+ <iframe class="respec-iframe" src="${jc}" onload="${e=>e.target.classList.add("ready")}"></iframe>
1082
+ <a href="${jc}" target="_blank">Open Search UI in a new tab</a>
1083
+ `;fr.freshModal(Mc.title,e,zc)}),"Ctrl+Shift+Alt+x","📚");var Uc=Object.freeze({__proto__:null});const qc=on({en:{about_respec:"About"},zh:{about_respec:"关于"},nl:{about_respec:"Over"},ja:{about_respec:"これについて"},de:{about_respec:"Über"}});window.respecVersion=window.respecVersion||"Developer Edition";const Wc=document.createElement("div"),Fc=jt.bind(Wc),Bc=fr.addCommand(`${qc.about_respec} ${window.respecVersion}`,(function(){const e=[];"getEntriesByType"in performance&&performance.getEntriesByType("measure").sort(((e,t)=>t.duration-e.duration)).map((({name:e,duration:t})=>({name:e,duration:t>1e3?`${Math.round(t/1e3)} second(s)`:`${t.toFixed(2)} milliseconds`}))).map(Hc).forEach((t=>{e.push(t)}));Fc`
1084
1084
  <p>
1085
1085
  ReSpec is a document production toolchain, with a notable focus on W3C specifications.
1086
1086
  </p>
@@ -1104,12 +1104,12 @@ img.caniuse-browser{filter:drop-shadow(0 0 .1cm #666)}
1104
1104
  </thead>
1105
1105
  <tbody>${e}</tbody>
1106
1106
  </table>
1107
- `,pr.freshModal(`${Uc.about_respec} - ${window.respecVersion}`,qc,Fc)}),"Ctrl+Shift+Alt+A","ℹ️");function Bc({name:e,duration:t}){return Ot`
1107
+ `,fr.freshModal(`${qc.about_respec} - ${window.respecVersion}`,Wc,Bc)}),"Ctrl+Shift+Alt+A","ℹ️");function Hc({name:e,duration:t}){return jt`
1108
1108
  <tr>
1109
1109
  <td><a href="${`https://github.com/w3c/respec/blob/develop/src/${e}.js`}">${e}</a></td>
1110
1110
  <td>${t}</td>
1111
1111
  </tr>
1112
- `}var Hc=Object.freeze({__proto__:null});var Gc=Object.freeze({__proto__:null,name:"core/seo",run:function(){const e=document.querySelector("#abstract p:first-of-type");if(!e)return;const t=e.textContent.replace(/\s+/," ").trim(),n=document.createElement("meta");n.name="description",n.content=t,document.head.appendChild(n)}});const Vc="w3c/seo",Yc={NOTE:"w3p:NOTE",WD:"w3p:WD",LC:"w3p:LastCall",CR:"w3p:CR",CRD:"w3p:CRD",PR:"w3p:PR",REC:"w3p:REC",PER:"w3p:PER",RSCND:"w3p:RSCND"},Kc=new Set([...Vr,...Yr,...Kr,"BG-FINAL","CG-FINAL","CRY","DRY","draft-finding","finding"]);function Zc({name:e,url:t,mailto:n,company:r,companyURL:s}){const i={type:"Person",name:e,url:t,"foaf:mbox":n};return(r||s)&&(i.worksFor={name:r,url:s}),i}function Jc(e){const{href:t,title:n,href:r}=e,s={id:t,type:"TechArticle",name:n,url:r};return e.authors&&(s.creator=e.authors.map((e=>({name:e})))),e.rawDate&&(s.publishedDate=e.rawDate),e.isbn&&(s.identifier=e.isbn),e.publisher&&(s.publisher={name:e.publisher}),s}var Xc=Object.freeze({__proto__:null,name:Vc,requiresCanonicalLink:Kc,run:async function(e){if((e.canonicalURI||Kc.has(e.specStatus))&&e.shortName){switch(e.canonicalURI){case"edDraft":if(e.edDraftURI)e.canonicalURI=new URL(e.edDraftURI,document.location.href).href;else{En("Canonical URI set to edDraft, but no edDraftURI is set in configuration",Vc),e.canonicalURI=null}break;case"TR":if(e.latestVersion)e.canonicalURI=e.latestVersion;else{En("Canonical URI set to TR, but no shortName is set in configuration",Vc),e.canonicalURI=null}break;default:e.latestVersion&&!e.canonicalURI&&(e.canonicalURI=e.latestVersion)}if(e.canonicalURI){const t=Ot`<link rel="canonical" href="${e.canonicalURI}" />`;document.head.appendChild(t)}e.doJsonLd&&await async function(e,t){const n=Yc[e.specStatus],r=["TechArticle"];n&&r.push(n);const s={"@context":["http://schema.org",{"@vocab":"http://schema.org/","@language":t.documentElement.lang||"en",w3p:"http://www.w3.org/2001/02pd/rec54#",foaf:"http://xmlns.com/foaf/0.1/",datePublished:{"@type":"http://www.w3.org/2001/XMLSchema#date"},inLanguage:{"@language":null},isBasedOn:{"@type":"@id"},license:{"@type":"@id"}}],id:e.canonicalURI||e.thisVersion,type:r,name:document.title,inLanguage:t.documentElement.lang||"en",license:e.licenseInfo?.url,datePublished:e.dashDate,copyrightHolder:{name:"World Wide Web Consortium",url:"https://www.w3.org/"},discussionUrl:e.issueBase,alternativeHeadline:e.subtitle,isBasedOn:e.prevVersion};if(e.additionalCopyrightHolders){const t=Array.isArray(e.additionalCopyrightHolders)?e.additionalCopyrightHolders:[e.additionalCopyrightHolders];s.copyrightHolder=[s.copyrightHolder,...t.map((e=>({name:e})))]}const i=t.head.querySelector("meta[name=description]");i&&(s.description=i.content);e.editors&&(s.editor=e.editors.map(Zc));e.authors&&(s.contributor=e.authors.map(Zc));const o=[...e.normativeReferences,...e.informativeReferences],a=await Promise.all(o.map((e=>vi(e))));s.citation=a.filter((e=>"object"==typeof e)).map(Jc);const c=t.createElement("script");c.type="application/ld+json",c.textContent=JSON.stringify(s,null,2),t.head.appendChild(c)}(e,document)}}});var Qc=String.raw`.hljs{display:block;overflow-x:auto;padding:.5em;color:#383a42;background:#fafafa}
1112
+ `}var Gc=Object.freeze({__proto__:null});var Vc=Object.freeze({__proto__:null,name:"core/seo",run:function(){const e=document.querySelector("#abstract p:first-of-type");if(!e)return;const t=e.textContent.replace(/\s+/," ").trim(),n=document.createElement("meta");n.name="description",n.content=t,document.head.appendChild(n)}});const Yc="w3c/seo",Kc={NOTE:"w3p:NOTE",WD:"w3p:WD",LC:"w3p:LastCall",CR:"w3p:CR",CRD:"w3p:CRD",PR:"w3p:PR",REC:"w3p:REC",PER:"w3p:PER",RSCND:"w3p:RSCND"},Zc=new Set([...Yr,...Kr,...Zr,"BG-FINAL","CG-FINAL","CRY","DRY","draft-finding","finding"]);function Jc({name:e,url:t,mailto:n,company:r,companyURL:s}){const i={type:"Person",name:e,url:t,"foaf:mbox":n};return(r||s)&&(i.worksFor={name:r,url:s}),i}function Xc(e){const{href:t,title:n,href:r}=e,s={id:t,type:"TechArticle",name:n,url:r};return e.authors&&(s.creator=e.authors.map((e=>({name:e})))),e.rawDate&&(s.publishedDate=e.rawDate),e.isbn&&(s.identifier=e.isbn),e.publisher&&(s.publisher={name:e.publisher}),s}var Qc=Object.freeze({__proto__:null,name:Yc,requiresCanonicalLink:Zc,run:async function(e){if((e.canonicalURI||Zc.has(e.specStatus))&&e.shortName){switch(e.canonicalURI){case"edDraft":if(e.edDraftURI)e.canonicalURI=new URL(e.edDraftURI,document.location.href).href;else{An("Canonical URI set to edDraft, but no edDraftURI is set in configuration",Yc),e.canonicalURI=null}break;case"TR":if(e.latestVersion)e.canonicalURI=e.latestVersion;else{An("Canonical URI set to TR, but no shortName is set in configuration",Yc),e.canonicalURI=null}break;default:e.latestVersion&&!e.canonicalURI&&(e.canonicalURI=e.latestVersion)}if(e.canonicalURI){const t=jt`<link rel="canonical" href="${e.canonicalURI}" />`;document.head.appendChild(t)}e.doJsonLd&&await async function(e,t){const n=Kc[e.specStatus],r=["TechArticle"];n&&r.push(n);const s={"@context":["http://schema.org",{"@vocab":"http://schema.org/","@language":t.documentElement.lang||"en",w3p:"http://www.w3.org/2001/02pd/rec54#",foaf:"http://xmlns.com/foaf/0.1/",datePublished:{"@type":"http://www.w3.org/2001/XMLSchema#date"},inLanguage:{"@language":null},isBasedOn:{"@type":"@id"},license:{"@type":"@id"}}],id:e.canonicalURI||e.thisVersion,type:r,name:document.title,inLanguage:t.documentElement.lang||"en",license:e.licenseInfo?.url,datePublished:e.dashDate,copyrightHolder:{name:"World Wide Web Consortium",url:"https://www.w3.org/"},discussionUrl:e.issueBase,alternativeHeadline:e.subtitle,isBasedOn:e.prevVersion};if(e.additionalCopyrightHolders){const t=Array.isArray(e.additionalCopyrightHolders)?e.additionalCopyrightHolders:[e.additionalCopyrightHolders];s.copyrightHolder=[s.copyrightHolder,...t.map((e=>({name:e})))]}const i=t.head.querySelector("meta[name=description]");i&&(s.description=i.content);e.editors&&(s.editor=e.editors.map(Jc));e.authors&&(s.contributor=e.authors.map(Jc));const o=[...e.normativeReferences,...e.informativeReferences],a=await Promise.all(o.map((e=>$i(e))));s.citation=a.filter((e=>"object"==typeof e)).map(Xc);const c=t.createElement("script");c.type="application/ld+json",c.textContent=JSON.stringify(s,null,2),t.head.appendChild(c)}(e,document)}}});var el=String.raw`.hljs{display:block;overflow-x:auto;padding:.5em;color:#383a42;background:#fafafa}
1113
1113
  .hljs-comment,.hljs-quote{color:#717277;font-style:italic}
1114
1114
  .hljs-doctag,.hljs-formula,.hljs-keyword{color:#a626a4}
1115
1115
  .hljs-deletion,.hljs-name,.hljs-section,.hljs-selector-tag,.hljs-subst{color:#ca4706;font-weight:700}
@@ -1120,21 +1120,21 @@ img.caniuse-browser{filter:drop-shadow(0 0 .1cm #666)}
1120
1120
  .hljs-bullet,.hljs-link,.hljs-meta,.hljs-selector-id,.hljs-symbol,.hljs-title{color:#336ae3}
1121
1121
  .hljs-emphasis{font-style:italic}
1122
1122
  .hljs-strong{font-weight:700}
1123
- .hljs-link{text-decoration:underline}`;async function el(e){const t=await fetch(new URL(`../../${e}`,document.currentScript&&document.currentScript.src||new URL("respec-w3c.js",document.baseURI).href));return await t.text()}const tl=Kt({hint:"preload",href:"https://www.w3.org/Tools/respec/respec-highlight",as:"script"});document.head.appendChild(tl);const nl=async function(){const e=await async function(){try{return(await Promise.resolve().then((function(){return qu}))).default}catch{return el("worker/respec-worker.js")}}(),t=URL.createObjectURL(new Blob([e],{type:"application/javascript"}));return new Worker(t)}();t("core/worker",nl.then((e=>({worker:e}))));const rl=function(e,t=0){const n=function*(e,t){for(;;)yield`${e}:${t}`,t++}(e,t);return()=>n.next().value}("highlight");async function sl(e){e.setAttribute("aria-busy","true");const t=(n=e.classList,Array.from(n).filter((e=>"highlight"!==e&&"nolinks"!==e)).map((e=>e.toLowerCase())));var n;let r;try{r=await async function(e,t){const n={action:"highlight",code:e,id:rl(),languages:t},r=await nl;return r.postMessage(n),new Promise(((e,t)=>{const s=setTimeout((()=>{t(new Error("Timed out waiting for highlight."))}),4e3);r.addEventListener("message",(function t(i){const{data:{id:o,language:a,value:c}}=i;o===n.id&&(r.removeEventListener("message",t),clearTimeout(s),e({language:a,value:c}))}))}))}(e.innerText,t)}catch(e){return void console.error(e)}const{language:s,value:i}=r;switch(e.localName){case"pre":e.classList.remove(s),e.innerHTML=`<code class="hljs${s?` ${s}`:""}">${i}</code>`,e.classList.length||e.removeAttribute("class");break;case"code":e.innerHTML=i,e.classList.add("hljs"),s&&e.classList.add(s)}e.setAttribute("aria-busy","false")}var il=Object.freeze({__proto__:null,name:"core/highlight",run:async function(e){if(e.noHighlightCSS)return;const t=[...document.querySelectorAll("\n pre:not(.idl):not(.nohighlight) > code:not(.nohighlight),\n pre:not(.idl):not(.nohighlight),\n code.highlight\n ")].filter((e=>"pre"!==e.localName||!e.querySelector("code")));if(!t.length)return;const n=t.filter((e=>e.textContent.trim())).map(sl);document.head.appendChild(Ot`<style>
1124
- ${Qc}
1125
- </style>`),await Promise.all(n)}});const ol=sn({en:{missing_test_suite_uri:In`Found tests in your spec, but missing ${"[testSuiteURI]"} in your ReSpec config.`,tests:"tests",test:"test"},ja:{missing_test_suite_uri:In`この仕様内にテストの項目を検出しましたが,ReSpec の設定に ${"[testSuiteURI]"} が見つかりません.`,tests:"テスト",test:"テスト"},de:{missing_test_suite_uri:In`Die Spezifikation enthält Tests, aber in der ReSpec-Konfiguration ist keine ${"[testSuiteURI]"} angegeben.`,tests:"Tests",test:"Test"},zh:{missing_test_suite_uri:In`本规范中包含测试,但在 ReSpec 配置中缺少 ${"[testSuiteURI]"}。`,tests:"测试",test:"测试"}}),al="core/data-tests";function cl(e){const t=[],[n]=new URL(e).pathname.split("/").reverse(),r=n.split(".");let[s]=r;if(r.find((e=>"https"===e))){const e=document.createElement("span");e.textContent="🔒",e.setAttribute("aria-label","requires a secure connection"),e.setAttribute("title","Test requires HTTPS"),s=s.replace(".https",""),t.push(e)}if(s.split(".").join("-").split("-").find((e=>"manual"===e))){const e=document.createElement("span");e.textContent="💪",e.setAttribute("aria-label","the test must be run manually"),e.setAttribute("title","Manual test"),s=s.replace("-manual",""),t.push(e)}return Ot`
1123
+ .hljs-link{text-decoration:underline}`;async function tl(e){const t=await fetch(new URL(`../../${e}`,document.currentScript&&document.currentScript.src||new URL("respec-w3c.js",document.baseURI).href));return await t.text()}const nl=Zt({hint:"preload",href:"https://www.w3.org/Tools/respec/respec-highlight",as:"script"});document.head.appendChild(nl);const rl=async function(){const e=await async function(){try{return(await Promise.resolve().then((function(){return Wu}))).default}catch{return tl("worker/respec-worker.js")}}(),t=URL.createObjectURL(new Blob([e],{type:"application/javascript"}));return new Worker(t)}();t("core/worker",rl.then((e=>({worker:e}))));const sl=function(e,t=0){const n=function*(e,t){for(;;)yield`${e}:${t}`,t++}(e,t);return()=>n.next().value}("highlight");async function il(e){e.setAttribute("aria-busy","true");const t=(n=e.classList,Array.from(n).filter((e=>"highlight"!==e&&"nolinks"!==e)).map((e=>e.toLowerCase())));var n;let r;try{r=await async function(e,t){const n={action:"highlight",code:e,id:sl(),languages:t},r=await rl;return r.postMessage(n),new Promise(((e,t)=>{const s=setTimeout((()=>{t(new Error("Timed out waiting for highlight."))}),4e3);r.addEventListener("message",(function t(i){const{data:{id:o,language:a,value:c}}=i;o===n.id&&(r.removeEventListener("message",t),clearTimeout(s),e({language:a,value:c}))}))}))}(e.innerText,t)}catch(e){return void console.error(e)}const{language:s,value:i}=r;switch(e.localName){case"pre":e.classList.remove(s),e.innerHTML=`<code class="hljs${s?` ${s}`:""}">${i}</code>`,e.classList.length||e.removeAttribute("class");break;case"code":e.innerHTML=i,e.classList.add("hljs"),s&&e.classList.add(s)}e.setAttribute("aria-busy","false")}var ol=Object.freeze({__proto__:null,name:"core/highlight",run:async function(e){if(e.noHighlightCSS)return;const t=[...document.querySelectorAll("\n pre:not(.idl):not(.nohighlight) > code:not(.nohighlight),\n pre:not(.idl):not(.nohighlight),\n code.highlight\n ")].filter((e=>"pre"!==e.localName||!e.querySelector("code")));if(!t.length)return;const n=t.filter((e=>e.textContent.trim())).map(il);document.head.appendChild(jt`<style>
1124
+ ${el}
1125
+ </style>`),await Promise.all(n)}});const al=on({en:{missing_test_suite_uri:Dn`Found tests in your spec, but missing ${"[testSuiteURI]"} in your ReSpec config.`,tests:"tests",test:"test"},ja:{missing_test_suite_uri:Dn`この仕様内にテストの項目を検出しましたが,ReSpec の設定に ${"[testSuiteURI]"} が見つかりません.`,tests:"テスト",test:"テスト"},de:{missing_test_suite_uri:Dn`Die Spezifikation enthält Tests, aber in der ReSpec-Konfiguration ist keine ${"[testSuiteURI]"} angegeben.`,tests:"Tests",test:"Test"},zh:{missing_test_suite_uri:Dn`本规范中包含测试,但在 ReSpec 配置中缺少 ${"[testSuiteURI]"}。`,tests:"测试",test:"测试"}}),cl="core/data-tests";function ll(e){const t=[],[n]=new URL(e).pathname.split("/").reverse(),r=n.split(".");let[s]=r;if(r.find((e=>"https"===e))){const e=document.createElement("span");e.textContent="🔒",e.setAttribute("aria-label","requires a secure connection"),e.setAttribute("title","Test requires HTTPS"),s=s.replace(".https",""),t.push(e)}if(s.split(".").join("-").split("-").find((e=>"manual"===e))){const e=document.createElement("span");e.textContent="💪",e.setAttribute("aria-label","the test must be run manually"),e.setAttribute("title","Manual test"),s=s.replace("-manual",""),t.push(e)}return jt`
1126
1126
  <li>
1127
1127
  <a href="${e}">${s}</a>
1128
1128
  ${t}
1129
1129
  </li>
1130
- `}function ll(e,t,n){return e.map((e=>{try{return new URL(e,t).href}catch{En(In`Invalid URL in ${"[data-tests]"} attribute: ${e}.`,al,{elements:[n]})}})).filter((e=>e))}function ul(e,t){const n=e.filter(((e,t,n)=>n.indexOf(e)!==t));if(n.length){const e=In`Duplicate tests found in the ${"[data-tests]"} attribute.`,r=In`To fix, remove duplicates from ${"[data-tests]"}: ${Ln(n,{quotes:!0})}.`;En(e,al,{hint:r,elements:[t]})}}function dl(e){const t=[...new Set(e)];return Ot`
1130
+ `}function ul(e,t,n){return e.map((e=>{try{return new URL(e,t).href}catch{An(Dn`Invalid URL in ${"[data-tests]"} attribute: ${e}.`,cl,{elements:[n]})}})).filter((e=>e))}function dl(e,t){const n=e.filter(((e,t,n)=>n.indexOf(e)!==t));if(n.length){const e=Dn`Duplicate tests found in the ${"[data-tests]"} attribute.`,r=Dn`To fix, remove duplicates from ${"[data-tests]"}: ${Pn(n,{quotes:!0})}.`;An(e,cl,{hint:r,elements:[t]})}}function pl(e){const t=[...new Set(e)];return jt`
1131
1131
  <details class="respec-tests-details removeOnSave">
1132
1132
  <summary>tests: ${t.length}</summary>
1133
1133
  <ul>
1134
- ${t.map(cl)}
1134
+ ${t.map(ll)}
1135
1135
  </ul>
1136
1136
  </details>
1137
- `}var pl=Object.freeze({__proto__:null,name:al,run:function(e){const t=[...document.querySelectorAll("[data-tests]")].filter((e=>e.dataset.tests));if(t.length)if(e.testSuiteURI)for(const n of t){const t=ll(n.dataset.tests.split(/,/gm).map((e=>e.trim())),e.testSuiteURI,n);ul(t,n);const r=dl(t);n.append(r)}else Rn(ol.missing_test_suite_uri,al)}});const fl="core/list-sorter";function hl(e){const t="ascending"===e?1:-1;return({textContent:e},{textContent:n})=>t*e.trim().localeCompare(n.trim())}function ml(e,t){return[...e.querySelectorAll(":scope > li")].sort(hl(t)).reduce(((e,t)=>(e.appendChild(t),e)),document.createDocumentFragment())}function gl(e,t){return[...e.querySelectorAll(":scope > dt")].sort(hl(t)).reduce(((e,t)=>{const{nodeType:n,nodeName:r}=t,s=document.createDocumentFragment();let{nextSibling:i}=t;for(;i&&i.nextSibling;){s.appendChild(i.cloneNode(!0));const{nodeType:e,nodeName:t}=i.nextSibling;if(e===n&&t===r)break;i=i.nextSibling}return s.prepend(t.cloneNode(!0)),e.appendChild(s),e}),document.createDocumentFragment())}var bl=Object.freeze({__proto__:null,name:fl,run:function(){const e=document.querySelectorAll("[data-sort]");for(const t of e){let e;const n=t.dataset.sort||"ascending";switch(t.localName){case"dl":e=gl(t,n);break;case"ol":case"ul":e=ml(t,n);break;default:En(`ReSpec can't sort ${t.localName} elements.`,fl,{elements:[t]})}if(e){const n=document.createRange();n.selectNodeContents(t),n.deleteContents(),t.appendChild(e)}}},sortDefinitionTerms:gl,sortListItems:ml});var yl=String.raw`var:hover{text-decoration:underline;cursor:pointer}
1137
+ `}var fl=Object.freeze({__proto__:null,name:cl,run:function(e){const t=[...document.querySelectorAll("[data-tests]")].filter((e=>e.dataset.tests));if(t.length)if(e.testSuiteURI)for(const n of t){const t=ul(n.dataset.tests.split(/,/gm).map((e=>e.trim())),e.testSuiteURI,n);dl(t,n);const r=pl(t);n.append(r)}else En(al.missing_test_suite_uri,cl)}});const hl="core/list-sorter";function ml(e){const t="ascending"===e?1:-1;return({textContent:e},{textContent:n})=>t*e.trim().localeCompare(n.trim())}function gl(e,t){return[...e.querySelectorAll(":scope > li")].sort(ml(t)).reduce(((e,t)=>(e.appendChild(t),e)),document.createDocumentFragment())}function bl(e,t){return[...e.querySelectorAll(":scope > dt")].sort(ml(t)).reduce(((e,t)=>{const{nodeType:n,nodeName:r}=t,s=document.createDocumentFragment();let{nextSibling:i}=t;for(;i&&i.nextSibling;){s.appendChild(i.cloneNode(!0));const{nodeType:e,nodeName:t}=i.nextSibling;if(e===n&&t===r)break;i=i.nextSibling}return s.prepend(t.cloneNode(!0)),e.appendChild(s),e}),document.createDocumentFragment())}var yl=Object.freeze({__proto__:null,name:hl,run:function(){const e=document.querySelectorAll("[data-sort]");for(const t of e){let e;const n=t.dataset.sort||"ascending";switch(t.localName){case"dl":e=bl(t,n);break;case"ol":case"ul":e=gl(t,n);break;default:An(`ReSpec can't sort ${t.localName} elements.`,hl,{elements:[t]})}if(e){const n=document.createRange();n.selectNodeContents(t),n.deleteContents(),t.appendChild(e)}}},sortDefinitionTerms:bl,sortListItems:gl});var wl=String.raw`var:hover{text-decoration:underline;cursor:pointer}
1138
1138
  var.respec-hl{color:var(--color,#000);background-color:var(--bg-color);box-shadow:0 0 0 2px var(--bg-color)}
1139
1139
  var.respec-hl-c1{--bg-color:#f4d200}
1140
1140
  var.respec-hl-c2{--bg-color:#ff87a2}
@@ -1145,11 +1145,11 @@ var.respec-hl-c6{--bg-color:#82ddff}
1145
1145
  var.respec-hl-c7{--bg-color:#ffbcf2}
1146
1146
  @media print{
1147
1147
  var.respec-hl{background:0 0;color:#000;box-shadow:unset}
1148
- }`;function wl(e){e.stopPropagation();const{target:t}=e,n=function(e){const t=rn(e.textContent),n=e.closest("section"),r=$l(e),s=[...n.querySelectorAll("var")].filter((e=>rn(e.textContent)===t&&e.closest("section")===n)),i=s[0].classList.contains("respec-hl");if(vl.set(r,i),i)return s.forEach((e=>kl(e,r))),[];s.forEach((e=>function(e,t){e.classList.add("respec-hl",t)}(e,r)));return s}(t),r=()=>{const e=$l(t);n.forEach((t=>kl(t,e))),[...vl.keys()].forEach((e=>vl.set(e,!0)))};n.length&&document.body.addEventListener("click",r,{once:!0})}const vl=new Map([["respec-hl-c1",!0],["respec-hl-c2",!0],["respec-hl-c3",!0],["respec-hl-c4",!0],["respec-hl-c5",!0],["respec-hl-c6",!0],["respec-hl-c7",!0]]);function $l(e){const{value:t}=e.classList,n=/respec-hl-\w+/,r=n.test(t)&&t.match(n);return r?r[0]:!0===vl.get("respec-hl-c1")?"respec-hl-c1":[...vl.keys()].find((e=>vl.get(e)))||"respec-hl-c1"}function kl(e,t){e.classList.remove("respec-hl",t),e.classList.length||e.removeAttribute("class")}var xl=Object.freeze({__proto__:null,name:"core/highlight-vars",run:function(e){if(!e.highlightVars)return;const t=document.createElement("style");t.textContent=yl,t.classList.add("removeOnSave"),document.head.appendChild(t),document.querySelectorAll("var").forEach((e=>e.addEventListener("click",wl))),s("beforesave",(e=>{e.querySelectorAll("var.respec-hl").forEach(kl)}))}});var _l=String.raw`var{position:relative;cursor:pointer}
1148
+ }`;function vl(e){e.stopPropagation();const{target:t}=e,n=function(e){const t=sn(e.textContent),n=e.closest("section"),r=kl(e),s=[...n.querySelectorAll("var")].filter((e=>sn(e.textContent)===t&&e.closest("section")===n)),i=s[0].classList.contains("respec-hl");if($l.set(r,i),i)return s.forEach((e=>xl(e,r))),[];s.forEach((e=>function(e,t){e.classList.add("respec-hl",t)}(e,r)));return s}(t),r=()=>{const e=kl(t);n.forEach((t=>xl(t,e))),[...$l.keys()].forEach((e=>$l.set(e,!0)))};n.length&&document.body.addEventListener("click",r,{once:!0})}const $l=new Map([["respec-hl-c1",!0],["respec-hl-c2",!0],["respec-hl-c3",!0],["respec-hl-c4",!0],["respec-hl-c5",!0],["respec-hl-c6",!0],["respec-hl-c7",!0]]);function kl(e){const{value:t}=e.classList,n=/respec-hl-\w+/,r=n.test(t)&&t.match(n);return r?r[0]:!0===$l.get("respec-hl-c1")?"respec-hl-c1":[...$l.keys()].find((e=>$l.get(e)))||"respec-hl-c1"}function xl(e,t){e.classList.remove("respec-hl",t),e.classList.length||e.removeAttribute("class")}var _l=Object.freeze({__proto__:null,name:"core/highlight-vars",run:function(e){if(!e.highlightVars)return;const t=document.createElement("style");t.textContent=wl,t.classList.add("removeOnSave"),document.head.appendChild(t),document.querySelectorAll("var").forEach((e=>e.addEventListener("click",vl))),s("beforesave",(e=>{e.querySelectorAll("var.respec-hl").forEach(xl)}))}});var Sl=String.raw`var{position:relative;cursor:pointer}
1149
1149
  var[data-type]::after,var[data-type]::before{position:absolute;left:50%;top:-6px;opacity:0;transition:opacity .4s;pointer-events:none}
1150
1150
  var[data-type]::before{content:"";transform:translateX(-50%);border-width:4px 6px 0 6px;border-style:solid;border-color:transparent;border-top-color:#000}
1151
1151
  var[data-type]::after{content:attr(data-type);transform:translateX(-50%) translateY(-100%);background:#000;text-align:center;font-family:"Dank Mono","Fira Code",monospace;font-style:normal;padding:6px;border-radius:3px;color:#daca88;text-indent:0;font-weight:400}
1152
- var[data-type]:hover::after,var[data-type]:hover::before{opacity:1}`;var Cl=Object.freeze({__proto__:null,name:"core/data-type",run:function(e){if(!e.highlightVars)return;const t=document.createElement("style");t.textContent=_l,document.head.appendChild(t);let n=null;const r=new Map,s=document.querySelectorAll("section var");for(const e of s){const t=e.closest("section");if(n!==t&&(n=t,r.clear()),e.dataset.type){r.set(e.textContent.trim(),e.dataset.type);continue}const s=r.get(e.textContent.trim());s&&(e.dataset.type=s)}}});var Sl=String.raw`.assert{background:#eee;border-left:.5em solid #aaa;padding:.3em}`;var Rl=Object.freeze({__proto__:null,name:"core/algorithms",run:function(){const e=Array.from(document.querySelectorAll("ol.algorithm li")).filter((e=>e.textContent.trim().startsWith("Assert: ")));if(!e.length)return;for(const t of e){t.classList.add("assert");const e=t.firstChild;e instanceof Text&&e.textContent.startsWith("Assert: ")&&(e.textContent=e.textContent.replace("Assert: ",""),t.prepend(Ot`<a href="https://infra.spec.whatwg.org/#assert">Assert</a>`,": "))}const t=document.createElement("style");t.textContent=Sl,document.head.appendChild(t)}});const El="core/anchor-expander";function Al(e,t,n){const r=e.querySelector(".marker .self-link");if(!r){n.textContent=n.getAttribute("href");return void Rn(`Found matching element "${t}", but it has no title or marker.`,El,{title:"Missing title.",elements:[n]})}const s=kn(r);n.append(...s.childNodes),n.classList.add("box-ref")}function Tl(e,t,n){const r=e.querySelector("figcaption");if(!r){n.textContent=n.getAttribute("href");return void Rn(`Found matching figure "${t}", but figure is lacking a \`<figcaption>\`.`,El,{title:"Missing figcaption in referenced figure.",elements:[n]})}const s=[...kn(r.querySelector(".self-link")).childNodes].map((e=>(e.classList?.remove("figno"),e)));n.append(...s),n.classList.add("fig-ref");const i=r.querySelector(".fig-title");!n.hasAttribute("title")&&i&&(n.title=rn(i.textContent))}function Ll(e,t,n){if(!e.classList.contains("numbered"))return;const r=e.querySelector("caption");if(!r){n.textContent=n.getAttribute("href");return void Rn(`Found matching table "${t}", but table is lacking a \`<caption>\`.`,El,{title:"Missing caption in referenced table.",elements:[n]})}const s=[...kn(r.querySelector(".self-link")).childNodes].map((e=>(e.classList?.remove("tableno"),e)));n.append(...s),n.classList.add("table-ref");const i=r.querySelector(".table-title");!n.hasAttribute("title")&&i&&(n.title=rn(i.textContent))}function Pl(e,t,n){const r=e.querySelector("h6, h5, h4, h3, h2");if(r)Il(r,n),Dl(r,n);else{n.textContent=n.getAttribute("href");Rn("Found matching section, but the section was lacking a heading element.",El,{title:`No matching id in document: "${t}".`,elements:[n]})}}function Il(e,t){const n=e.querySelector(".self-link"),r=[...kn(e).childNodes].filter((e=>!e.classList||!e.classList.contains("self-link")));t.append(...r),n&&t.prepend("§ "),t.classList.add("sec-ref"),t.lastChild.nodeType===Node.TEXT_NODE&&(t.lastChild.textContent=t.lastChild.textContent.trimEnd()),t.querySelectorAll("a").forEach((e=>{const t=mn(e,"span");for(const e of[...t.attributes])t.removeAttributeNode(e)}))}function Dl(e,t){for(const n of["dir","lang"]){if(t.hasAttribute(n))continue;const r=e.closest(`[${n}]`);if(!r)continue;const s=t.closest(`[${n}]`);s&&s.getAttribute(n)===r.getAttribute(n)||t.setAttribute(n,r.getAttribute(n))}}var Nl=Object.freeze({__proto__:null,name:El,run:function(){const e=[...document.querySelectorAll("a[href^='#']:not(.self-link):not([href$='the-empty-string'])")].filter((e=>""===e.textContent.trim()));for(const t of e){const e=t.getAttribute("href").slice(1),n=document.getElementById(e);if(n){switch(n.localName){case"h6":case"h5":case"h4":case"h3":case"h2":Il(n,t);break;case"section":Pl(n,e,t);break;case"figure":Tl(n,e,t);break;case"table":Ll(n,e,t);break;case"aside":case"div":Al(n,e,t);break;default:t.textContent=t.getAttribute("href");Rn("ReSpec doesn't support expanding this kind of reference.",El,{title:`Can't expand "#${e}".`,elements:[t]})}Dl(n,t),t.normalize()}else{t.textContent=t.getAttribute("href");Rn(`Couldn't expand inline reference. The id "${e}" is not in the document.`,El,{title:`No matching id in document: ${e}.`,elements:[t]})}}}});var Ol=String.raw`dfn{cursor:pointer}
1152
+ var[data-type]:hover::after,var[data-type]:hover::before{opacity:1}`;var Cl=Object.freeze({__proto__:null,name:"core/data-type",run:function(e){if(!e.highlightVars)return;const t=document.createElement("style");t.textContent=Sl,document.head.appendChild(t);let n=null;const r=new Map,s=document.querySelectorAll("section var");for(const e of s){const t=e.closest("section");if(n!==t&&(n=t,r.clear()),e.dataset.type){r.set(e.textContent.trim(),e.dataset.type);continue}const s=r.get(e.textContent.trim());s&&(e.dataset.type=s)}}});var Rl=String.raw`.assert{background:#eee;border-left:.5em solid #aaa;padding:.3em}`;var El=Object.freeze({__proto__:null,name:"core/algorithms",run:function(){const e=Array.from(document.querySelectorAll("ol.algorithm li")).filter((e=>e.textContent.trim().startsWith("Assert: ")));if(!e.length)return;for(const t of e){t.classList.add("assert");const e=t.firstChild;e instanceof Text&&e.textContent.startsWith("Assert: ")&&(e.textContent=e.textContent.replace("Assert: ",""),t.prepend(jt`<a href="https://infra.spec.whatwg.org/#assert">Assert</a>`,": "))}const t=document.createElement("style");t.textContent=Rl,document.head.appendChild(t)}});const Al="core/anchor-expander";function Tl(e,t,n){const r=e.querySelector(".marker .self-link");if(!r){n.textContent=n.getAttribute("href");return void En(`Found matching element "${t}", but it has no title or marker.`,Al,{title:"Missing title.",elements:[n]})}const s=xn(r);n.append(...s.childNodes),n.classList.add("box-ref")}function Ll(e,t,n){const r=e.querySelector("figcaption");if(!r){n.textContent=n.getAttribute("href");return void En(`Found matching figure "${t}", but figure is lacking a \`<figcaption>\`.`,Al,{title:"Missing figcaption in referenced figure.",elements:[n]})}const s=[...xn(r.querySelector(".self-link")).childNodes].map((e=>(e.classList?.remove("figno"),e)));n.append(...s),n.classList.add("fig-ref");const i=r.querySelector(".fig-title");!n.hasAttribute("title")&&i&&(n.title=sn(i.textContent))}function Pl(e,t,n){if(!e.classList.contains("numbered"))return;const r=e.querySelector("caption");if(!r){n.textContent=n.getAttribute("href");return void En(`Found matching table "${t}", but table is lacking a \`<caption>\`.`,Al,{title:"Missing caption in referenced table.",elements:[n]})}const s=[...xn(r.querySelector(".self-link")).childNodes].map((e=>(e.classList?.remove("tableno"),e)));n.append(...s),n.classList.add("table-ref");const i=r.querySelector(".table-title");!n.hasAttribute("title")&&i&&(n.title=sn(i.textContent))}function Il(e,t,n){const r=e.querySelector("h6, h5, h4, h3, h2");if(r)Dl(r,n),Nl(r,n);else{n.textContent=n.getAttribute("href");En("Found matching section, but the section was lacking a heading element.",Al,{title:`No matching id in document: "${t}".`,elements:[n]})}}function Dl(e,t){const n=e.querySelector(".self-link"),r=[...xn(e).childNodes].filter((e=>!e.classList||!e.classList.contains("self-link")));t.append(...r),n&&t.prepend("§ "),t.classList.add("sec-ref"),t.lastChild.nodeType===Node.TEXT_NODE&&(t.lastChild.textContent=t.lastChild.textContent.trimEnd()),t.querySelectorAll("a").forEach((e=>{const t=gn(e,"span");for(const e of[...t.attributes])t.removeAttributeNode(e)}))}function Nl(e,t){for(const n of["dir","lang"]){if(t.hasAttribute(n))continue;const r=e.closest(`[${n}]`);if(!r)continue;const s=t.closest(`[${n}]`);s&&s.getAttribute(n)===r.getAttribute(n)||t.setAttribute(n,r.getAttribute(n))}}var Ol=Object.freeze({__proto__:null,name:Al,run:function(){const e=[...document.querySelectorAll("a[href^='#']:not(.self-link):not([href$='the-empty-string'])")].filter((e=>""===e.textContent.trim()));for(const t of e){const e=t.getAttribute("href").slice(1),n=document.getElementById(e);if(n){switch(n.localName){case"h6":case"h5":case"h4":case"h3":case"h2":Dl(n,t);break;case"section":Il(n,e,t);break;case"figure":Ll(n,e,t);break;case"table":Pl(n,e,t);break;case"aside":case"div":Tl(n,e,t);break;default:t.textContent=t.getAttribute("href");En("ReSpec doesn't support expanding this kind of reference.",Al,{title:`Can't expand "#${e}".`,elements:[t]})}Nl(n,t),t.normalize()}else{t.textContent=t.getAttribute("href");En(`Couldn't expand inline reference. The id "${e}" is not in the document.`,Al,{title:`No matching id in document: ${e}.`,elements:[t]})}}}});var jl=String.raw`dfn{cursor:pointer}
1153
1153
  .dfn-panel{position:absolute;z-index:35;min-width:300px;max-width:500px;padding:.5em .75em;margin-top:.6em;font-family:"Helvetica Neue",sans-serif;font-size:small;background:#fff;color:#000;box-shadow:0 1em 3em -.4em rgba(0,0,0,.3),0 0 1px 1px rgba(0,0,0,.05);border-radius:2px}
1154
1154
  .dfn-panel:not(.docked)>.caret{position:absolute;top:-9px}
1155
1155
  .dfn-panel:not(.docked)>.caret::after,.dfn-panel:not(.docked)>.caret::before{content:"";position:absolute;border:10px solid transparent;border-top:0;border-bottom:10px solid #fff;top:0}
@@ -1166,7 +1166,7 @@ var[data-type]:hover::after,var[data-type]:hover::before{opacity:1}`;var Cl=Obje
1166
1166
  .dfn-panel a[href]:hover{border-bottom-width:1px}
1167
1167
  .dfn-panel ul{padding:0}
1168
1168
  .dfn-panel li{margin-left:1em}
1169
- .dfn-panel.docked{position:fixed;left:.5em;top:unset;bottom:2em;margin:0 auto;max-width:calc(100vw - .75em * 2 - .5em - .2em * 2);max-height:30vh;overflow:auto}`;function jl(e){const{id:t}=e,n=e.dataset.href||`#${t}`,r=document.querySelectorAll(`a[href="${n}"]:not(.index-term)`),s=`dfn-panel-for-${e.id}`,i=e.getAttribute("aria-label")||rn(e.textContent),o=Ot`
1169
+ .dfn-panel.docked{position:fixed;left:.5em;top:unset;bottom:2em;margin:0 auto;max-width:calc(100vw - .75em * 2 - .5em - .2em * 2);max-height:30vh;overflow:auto}`;function Ml(e){const{id:t}=e,n=e.dataset.href||`#${t}`,r=document.querySelectorAll(`a[href="${n}"]:not(.index-term)`),s=`dfn-panel-for-${e.id}`,i=e.getAttribute("aria-label")||sn(e.textContent),o=jt`
1170
1170
  <div
1171
1171
  class="dfn-panel"
1172
1172
  id="${s}"
@@ -1183,11 +1183,11 @@ var[data-type]:hover::after,var[data-type]:hover::before{opacity:1}`;var Cl=Obje
1183
1183
  aria-label="Permalink for definition: ${i}. Activate to close this dialog."
1184
1184
  >Permalink</a
1185
1185
  >
1186
- ${function(e){return e.matches("dfn[data-export]")?Ot`<span
1186
+ ${function(e){return e.matches("dfn[data-export]")?jt`<span
1187
1187
  class="marker dfn-exported"
1188
1188
  title="Definition can be referenced by other specifications"
1189
1189
  >exported</span
1190
- >`:null}(e)} ${function(e,t){if(!e.hasAttribute("data-idl"))return null;for(const n of t){if(n.dataset.linkType!==e.dataset.dfnType)continue;const t=n.closest("pre.idl");if(t&&t.id){const e=`#${t.id}`;return Ot`<a
1190
+ >`:null}(e)} ${function(e,t){if(!e.hasAttribute("data-idl"))return null;for(const n of t){if(n.dataset.linkType!==e.dataset.dfnType)continue;const t=n.closest("pre.idl");if(t&&t.id){const e=`#${t.id}`;return jt`<a
1191
1191
  href="${e}"
1192
1192
  class="marker idl-block"
1193
1193
  title="Jump to IDL declaration"
@@ -1195,41 +1195,42 @@ var[data-type]:hover::after,var[data-type]:hover::before{opacity:1}`;var Cl=Obje
1195
1195
  >`}}return null}(e,r)}
1196
1196
  </div>
1197
1197
  <p><b>Referenced in:</b></p>
1198
- ${function(e,t){if(!t.length)return Ot`<ul>
1198
+ ${function(e,t){if(!t.length)return jt`<ul>
1199
1199
  <li>Not referenced in this document.</li>
1200
- </ul>`;const n=new Map;t.forEach(((t,r)=>{const s=t.id||`ref-for-${e}-${r+1}`;t.id||(t.id=s);const i=function(e){const t=e.closest("section");if(!t)return null;const n=t.querySelector("h1, h2, h3, h4, h5, h6");return n?`§ ${rn(n.textContent)}`:null}(t);(n.get(i)||n.set(i,[]).get(i)).push(s)}));const r=([e,t])=>[{title:e,id:t[0],text:e}].concat(t.slice(1).map(((e,t)=>({title:`Reference ${t+2}`,text:`(${t+2})`,id:e})))),s=e=>Ot`<li>
1201
- ${r(e).map((e=>Ot`<a href="#${e.id}" title="${e.title}">${e.text}</a>${" "}`))}
1202
- </li>`;return Ot`<ul>
1200
+ </ul>`;const n=new Map;t.forEach(((t,r)=>{const s=t.id||`ref-for-${e}-${r+1}`;t.id||(t.id=s);const i=function(e){const t=e.closest("section");if(!t)return null;const n=t.querySelector("h1, h2, h3, h4, h5, h6");return n?`§ ${sn(n.textContent)}`:null}(t);(n.get(i)||n.set(i,[]).get(i)).push(s)}));const r=([e,t])=>[{title:e,id:t[0],text:e}].concat(t.slice(1).map(((e,t)=>({title:`Reference ${t+2}`,text:`(${t+2})`,id:e})))),s=e=>jt`<li>
1201
+ ${r(e).map((e=>jt`<a href="#${e.id}" title="${e.title}">${e.text}</a
1202
+ >${" "}`))}
1203
+ </li>`;return jt`<ul>
1203
1204
  ${[...n].map(s)}
1204
1205
  </ul>`}(t,r)}
1205
1206
  </div>
1206
- `;return o}var Ml=Object.freeze({__proto__:null,name:"core/dfn-panel",run:async function(){document.head.insertBefore(Ot`<style>
1207
- ${Ol}
1208
- </style>`,document.querySelector("link"));const e=document.querySelectorAll("dfn[id]:not([data-cite]), #index-defined-elsewhere .index-term"),t=document.createDocumentFragment();for(const n of e)t.append(jl(n)),n.tabIndex=0,n.setAttribute("aria-haspopup","dialog");document.body.append(t);const n=document.createElement("script");n.id="respec-dfn-panel",n.textContent=await async function(){try{return(await Promise.resolve().then((function(){return Wu}))).default}catch{return el("./src/core/dfn-panel.runtime.js")}}(),document.body.append(n)}});const zl="rs-changelog",Ul=class extends HTMLElement{constructor(){super(),this.props={from:this.getAttribute("from"),to:this.getAttribute("to")||"HEAD",filter:"function"==typeof window[this.getAttribute("filter")]?window[this.getAttribute("filter")]:()=>!0}}connectedCallback(){const{from:e,to:t,filter:n}=this.props;Ot.bind(this)`
1207
+ `;return o}var zl=Object.freeze({__proto__:null,name:"core/dfn-panel",run:async function(){document.head.insertBefore(jt`<style>
1208
+ ${jl}
1209
+ </style>`,document.querySelector("link"));const e=document.querySelectorAll("dfn[id]:not([data-cite]), #index-defined-elsewhere .index-term"),t=document.createDocumentFragment();for(const n of e)t.append(Ml(n)),n.tabIndex=0,n.setAttribute("aria-haspopup","dialog");document.body.append(t);const n=document.createElement("script");n.id="respec-dfn-panel",n.textContent=await async function(){try{return(await Promise.resolve().then((function(){return Fu}))).default}catch{return tl("./src/core/dfn-panel.runtime.js")}}(),document.body.append(n)}});const Ul="rs-changelog",ql=class extends HTMLElement{constructor(){super(),this.props={from:this.getAttribute("from"),to:this.getAttribute("to")||"HEAD",filter:"function"==typeof window[this.getAttribute("filter")]?window[this.getAttribute("filter")]:()=>!0}}connectedCallback(){const{from:e,to:t,filter:n}=this.props;jt.bind(this)`
1209
1210
  <ul>
1210
- ${{any:ql(e,t,n).then((e=>async function(e){const{repoURL:t}=await ks;return e.map((e=>{const[n,r=null]=e.message.split(/\(#(\d+)\)/,2),s=`${t}commit/${e.hash}`,i=r&&Ot` (<a href="${r?`${t}pull/${r}`:null}">#${r}</a>)`;return Ot`<li><a href="${s}">${n.trim()}</a>${i}</li>`}))}(e))).catch((e=>Rn(e.message,zl,{elements:[this]}))).finally((()=>{this.dispatchEvent(new CustomEvent("done"))})),placeholder:"Loading list of commits..."}}
1211
+ ${{any:Wl(e,t,n).then((e=>async function(e){const{repoURL:t}=await xs;return e.map((e=>{const[n,r=null]=e.message.split(/\(#(\d+)\)/,2),s=`${t}commit/${e.hash}`,i=r&&jt` (<a href="${r?`${t}pull/${r}`:null}">#${r}</a>)`;return jt`<li><a href="${s}">${n.trim()}</a>${i}</li>`}))}(e))).catch((e=>En(e.message,Ul,{elements:[this]}))).finally((()=>{this.dispatchEvent(new CustomEvent("done"))})),placeholder:"Loading list of commits..."}}
1211
1212
  </ul>
1212
- `}};async function ql(e,t,n){let r;try{const s=await ks;if(!s)throw new Error("`respecConfig.github` is not set");const i=new URL("commits",`${s.apiBase}/${s.fullName}/`);i.searchParams.set("from",e),i.searchParams.set("to",t);const o=await fetch(i.href);if(!o.ok)throw new Error(`Request to ${i} failed with status code ${o.status}`);if(r=await o.json(),!r.length)throw new Error(`No commits between ${e}..${t}.`);r=r.filter(n)}catch(e){const t=`Error loading commits from GitHub. ${e.message}`;throw console.error(e),new Error(t)}return r}const Wl=[Object.freeze({__proto__:null,element:Ul,name:zl})];var Fl=Object.freeze({__proto__:null,name:"core/custom-elements/index",run:async function(){Wl.forEach((e=>{customElements.define(e.name,e.element)}));const e=Wl.map((e=>e.name)).join(", "),t=[...document.querySelectorAll(e)].map((e=>new Promise((t=>e.addEventListener("done",t,{once:!0})))));await Promise.all(t)}});var Bl=Object.freeze({__proto__:null,name:"core/web-monetization",run:function(e){if(!1===e.monetization)return;const{monetization:t}=e,{removeOnSave:n,paymentPointer:r}=function(e){const t={paymentPointer:"$respec.org",removeOnSave:!0};switch(typeof e){case"string":t.paymentPointer=e;break;case"object":e.paymentPointer&&(t.paymentPointer=String(e.paymentPointer)),!1===e.removeOnSave&&(t.removeOnSave=!1)}return t}(t),s=n?"removeOnSave":null;document.head.append(Ot`<meta
1213
- name="monetization"
1214
- content="${r}"
1215
- class="${s}"
1216
- />`)}});const Hl="core/before-save";var Gl=Object.freeze({__proto__:null,name:Hl,run:function(e){if(e.beforeSave)if(Array.isArray(e.beforeSave)&&!e.beforeSave.some((e=>"function"!=typeof e||"AsyncFunction"===e.constructor.name)))s("beforesave",(t=>{!function(e,t){let n=0;for(const r of e)try{r(t)}catch(e){Rn(In`Function ${`\`${r.name}\``||`at position ${n}`}\` threw an error during processing of ${"[beforeSave]"}.`,Hl,{hint:"See developer console."}),console.error(e)}finally{n++}}(e.beforeSave,t.ownerDocument)}),{once:!0});else{Rn(In`${"[beforeSave]"} configuration option must be an array of synchronous JS functions.`,Hl)}}});const Vl="core/linter-rules/check-charset",Yl=sn({en:{msg:"Document must only contain one `<meta>` tag with charset set to 'utf-8'",hint:'Add this line in your document `<head>` section - `<meta charset="utf-8">` or set charset to "utf-8" if not set already.'},zh:{msg:"文档只能包含一个 charset 属性为 utf-8 的 `<meta>` 标签",hint:'将此行添加到文档的 `<head>` 部分—— `<meta charset="utf-8">` 或将 charset 设置为 utf-8(如果尚未设置)。'}});var Kl=Object.freeze({__proto__:null,name:Vl,run:function(e){if(!e.lint?.["check-charset"])return;const t=document.querySelectorAll("meta[charset]"),n=[];for(const e of t)n.push(e.getAttribute("charset").trim().toLowerCase());n.includes("utf-8")&&1===t.length||En(Yl.msg,Vl,{hint:Yl.hint,elements:[...t]})}});const Zl="core/linter-rules/check-punctuation",Jl=[".",":","!","?"],Xl=sn({en:{msg:"`p` elements should end with a punctuation mark.",hint:`Please make sure \`p\` elements end with one of: ${Jl.map((e=>`"${e}"`)).join(", ")}.`}});var Ql=Object.freeze({__proto__:null,name:Zl,run:function(e){if(!e.lint?.["check-punctuation"])return;const t=new RegExp(`[${Jl.join("")}\\]]$|^ *$`,"m"),n=[...document.querySelectorAll("p:not(#back-to-top,#w3c-state)")].filter((e=>!t.test(e.textContent.trim())));n.length&&En(Xl.msg,Zl,{hint:Xl.hint,elements:n})}});const eu="core/linter-rules/check-internal-slots",tu=sn({en:{msg:"Internal slots should be preceded by a '.'",hint:"Add a '.' between the elements mentioned."}});var nu=Object.freeze({__proto__:null,name:eu,run:function(e){if(!e.lint?.["check-internal-slots"])return;const t=[...document.querySelectorAll("var+a")].filter((({previousSibling:{nodeName:e}})=>e&&"VAR"===e));t.length&&En(tu.msg,eu,{hint:tu.hint,elements:t})}});const ru="core/linter-rules/local-refs-exist",su=sn({en:{msg:"Broken local reference found in document.",hint:"Please fix the links mentioned."}});function iu(e){const t=e.getAttribute("href").substring(1),n=e.ownerDocument;return!n.getElementById(t)&&!n.getElementsByName(t).length}var ou=Object.freeze({__proto__:null,name:ru,run:function(e){if(!e.lint?.["local-refs-exist"])return;const t=[...document.querySelectorAll("a[href^='#']")].filter(iu);t.length&&En(su.msg,ru,{hint:su.hint,elements:t})}});const au="core/linter-rules/no-captionless-tables",cu=sn({en:{msg:"All tables marked with class='numbered' must start with a caption element.",hint:"Add a `caption` to the offending table."}});var lu=Object.freeze({__proto__:null,name:au,run:function(e){if(!e.lint?.["no-captionless-tables"])return;const t=[...document.querySelectorAll("table.numbered")].filter((e=>!(e.firstElementChild instanceof HTMLTableCaptionElement)));t.length&&En(cu.msg,au,{hint:cu.hint,elements:t})}});const uu="no-unused-dfns",du="core/linter-rules/no-unused-dfns",pu=sn({en:{msg:e=>`Found definition for "${e}", but nothing links to it. This is usually a spec bug!`,get hint(){return In`
1213
+ `}};async function Wl(e,t,n){let r;try{const s=await xs;if(!s)throw new Error("`respecConfig.github` is not set");const i=new URL("commits",`${s.apiBase}/${s.fullName}/`);i.searchParams.set("from",e),i.searchParams.set("to",t);const o=await fetch(i.href);if(!o.ok)throw new Error(`Request to ${i} failed with status code ${o.status}`);if(r=await o.json(),!r.length)throw new Error(`No commits between ${e}..${t}.`);r=r.filter(n)}catch(e){const t=`Error loading commits from GitHub. ${e.message}`;throw console.error(e),new Error(t)}return r}const Fl=[Object.freeze({__proto__:null,element:ql,name:Ul})];var Bl=Object.freeze({__proto__:null,name:"core/custom-elements/index",run:async function(){Fl.forEach((e=>{customElements.define(e.name,e.element)}));const e=Fl.map((e=>e.name)).join(", "),t=[...document.querySelectorAll(e)].map((e=>new Promise((t=>e.addEventListener("done",t,{once:!0})))));await Promise.all(t)}});var Hl=Object.freeze({__proto__:null,name:"core/web-monetization",run:function(e){if(!1===e.monetization)return;const{monetization:t}=e,{removeOnSave:n,paymentPointer:r}=function(e){const t={paymentPointer:"$respec.org",removeOnSave:!0};switch(typeof e){case"string":t.paymentPointer=e;break;case"object":e.paymentPointer&&(t.paymentPointer=String(e.paymentPointer)),!1===e.removeOnSave&&(t.removeOnSave=!1)}return t}(t),s=n?"removeOnSave":null;document.head.append(jt`<meta
1214
+ name="monetization"
1215
+ content="${r}"
1216
+ class="${s}"
1217
+ />`)}});const Gl="core/before-save";var Vl=Object.freeze({__proto__:null,name:Gl,run:function(e){if(e.beforeSave)if(Array.isArray(e.beforeSave)&&!e.beforeSave.some((e=>"function"!=typeof e||"AsyncFunction"===e.constructor.name)))s("beforesave",(t=>{!function(e,t){let n=0;for(const r of e)try{r(t)}catch(e){En(Dn`Function ${`\`${r.name}\``||`at position ${n}`}\` threw an error during processing of ${"[beforeSave]"}.`,Gl,{hint:"See developer console."}),console.error(e)}finally{n++}}(e.beforeSave,t.ownerDocument)}),{once:!0});else{En(Dn`${"[beforeSave]"} configuration option must be an array of synchronous JS functions.`,Gl)}}});const Yl="core/linter-rules/check-charset",Kl=on({en:{msg:"Document must only contain one `<meta>` tag with charset set to 'utf-8'",hint:'Add this line in your document `<head>` section - `<meta charset="utf-8">` or set charset to "utf-8" if not set already.'},zh:{msg:"文档只能包含一个 charset 属性为 utf-8 的 `<meta>` 标签",hint:'将此行添加到文档的 `<head>` 部分—— `<meta charset="utf-8">` 或将 charset 设置为 utf-8(如果尚未设置)。'}});var Zl=Object.freeze({__proto__:null,name:Yl,run:function(e){if(!e.lint?.["check-charset"])return;const t=document.querySelectorAll("meta[charset]"),n=[];for(const e of t)n.push(e.getAttribute("charset").trim().toLowerCase());n.includes("utf-8")&&1===t.length||An(Kl.msg,Yl,{hint:Kl.hint,elements:[...t]})}});const Jl="core/linter-rules/check-punctuation",Xl=[".",":","!","?"],Ql=on({en:{msg:"`p` elements should end with a punctuation mark.",hint:`Please make sure \`p\` elements end with one of: ${Xl.map((e=>`"${e}"`)).join(", ")}.`}});var eu=Object.freeze({__proto__:null,name:Jl,run:function(e){if(!e.lint?.["check-punctuation"])return;const t=new RegExp(`[${Xl.join("")}\\]]$|^ *$`,"m"),n=[...document.querySelectorAll("p:not(#back-to-top,#w3c-state)")].filter((e=>!t.test(e.textContent.trim())));n.length&&An(Ql.msg,Jl,{hint:Ql.hint,elements:n})}});const tu="core/linter-rules/check-internal-slots",nu=on({en:{msg:"Internal slots should be preceded by a '.'",hint:"Add a '.' between the elements mentioned."}});var ru=Object.freeze({__proto__:null,name:tu,run:function(e){if(!e.lint?.["check-internal-slots"])return;const t=[...document.querySelectorAll("var+a")].filter((({previousSibling:{nodeName:e}})=>e&&"VAR"===e));t.length&&An(nu.msg,tu,{hint:nu.hint,elements:t})}});const su="core/linter-rules/local-refs-exist",iu=on({en:{msg:"Broken local reference found in document.",hint:"Please fix the links mentioned."}});function ou(e){const t=e.getAttribute("href").substring(1),n=e.ownerDocument;return!n.getElementById(t)&&!n.getElementsByName(t).length}var au=Object.freeze({__proto__:null,name:su,run:function(e){if(!e.lint?.["local-refs-exist"])return;const t=[...document.querySelectorAll("a[href^='#']")].filter(ou);t.length&&An(iu.msg,su,{hint:iu.hint,elements:t})}});const cu="core/linter-rules/no-captionless-tables",lu=on({en:{msg:"All tables marked with class='numbered' must start with a caption element.",hint:"Add a `caption` to the offending table."}});var uu=Object.freeze({__proto__:null,name:cu,run:function(e){if(!e.lint?.["no-captionless-tables"])return;const t=[...document.querySelectorAll("table.numbered")].filter((e=>!(e.firstElementChild instanceof HTMLTableCaptionElement)));t.length&&An(lu.msg,cu,{hint:lu.hint,elements:t})}});const du="no-unused-dfns",pu="core/linter-rules/no-unused-dfns",fu=on({en:{msg:e=>`Found definition for "${e}", but nothing links to it. This is usually a spec bug!`,get hint(){return Dn`
1217
1218
  You can do one of the following...
1218
1219
 
1219
1220
  * Add a \`class="lint-ignore"\` attribute the definition.
1220
1221
  * Either remove the definition or change \`<dfn>\` to another type of HTML element.
1221
1222
  * If you meant to ${"[export|#data-export]"} the definition, add \`class="export"\` to the definition.
1222
1223
 
1223
- To silence this warning entirely, set \`lint: { "no-unused-dfns": false }\` in your \`respecConfig\`.`}}});function fu(e){return!document.querySelector(`a[href="#${e.id}"]:not(.index-term, .self-link)`)}var hu=Object.freeze({__proto__:null,name:du,run:function(e){if(!e.lint?.[uu])return;const t="error"===e.lint[uu]?Rn:En;[...document.querySelectorAll("dfn:not(.lint-ignore, [data-export], [data-cite])")].filter(fu).forEach((e=>{const n=[e],r=rn(e.textContent);t(pu.msg(r),du,{elements:n,hint:pu.hint})}))}});const mu="core/linter-rules/no-headingless-sections",gu=sn({en:{msg:"All sections must start with a `h2-6` element.",hint:"Add a `h2-6` to the offending section or use a `<div>`."},nl:{msg:"Alle secties moeten beginnen met een `h2-6` element.",hint:"Voeg een `h2-6` toe aan de conflicterende sectie of gebruik een `<div>`."},zh:{msg:"所有章节(section)都必须以 `h2-6` 元素开头。",hint:"将 `h2-6` 添加到有问题的章节或使用 `<div>`。"}});var bu=Object.freeze({__proto__:null,name:mu,run:function(e){if(!e.lint?.["no-headingless-sections"])return;const t=[...document.querySelectorAll("section:not(.head,#abstract,#sotd)")].filter((({firstElementChild:e})=>!e||!(e.matches(".header-wrapper")||e instanceof HTMLHeadingElement)));t.length&&En(gu.msg,mu,{hint:gu.hint,elements:t})}});const yu="core/linter-rules/no-unused-vars",wu=sn({en:{msg:"Variable was defined, but never used.",hint:"Add a `data-ignore-unused` attribute to the `<var>`."}});var vu=Object.freeze({__proto__:null,name:yu,run:function(e){if(!e.lint?.["no-unused-vars"])return;const t=[],n=e=>!!e.querySelector(":scope > :not(section) ~ .algorithm, :scope > :not(section) .algorithm");for(const e of document.querySelectorAll("section")){if(!n(e))continue;const r=e.querySelectorAll(":scope > :not(section) var");if(!r.length)continue;const s=new Map;for(const e of r){const t=rn(e.textContent);(s.get(t)||s.set(t,[]).get(t)).push(e)}for(const e of s.values())1!==e.length||e[0].hasAttribute("data-ignore-unused")||t.push(e[0])}t.length&&En(wu.msg,yu,{hint:wu.hint,elements:t})}});const $u="required-sections",ku="w3c/linter-rules/required-sections",xu={en:{msg:e=>`W3C Recommendation track documents require a separate "${e}" section.`,hint:e=>In`Add a \`<section>\` with a "${e}" header. See the [Horizontal review guidelines](https://www.w3.org/Guide/documentreview/#how_to_get_horizontal_review).
1224
+ To silence this warning entirely, set \`lint: { "no-unused-dfns": false }\` in your \`respecConfig\`.`}}});function hu(e){return!document.querySelector(`a[href="#${e.id}"]:not(.index-term, .self-link)`)}var mu=Object.freeze({__proto__:null,name:pu,run:function(e){if(!e.lint?.[du])return;const t="error"===e.lint[du]?En:An;[...document.querySelectorAll("dfn:not(.lint-ignore, [data-export], [data-cite])")].filter(hu).forEach((e=>{const n=[e],r=sn(e.textContent);t(fu.msg(r),pu,{elements:n,hint:fu.hint})}))}});const gu="core/linter-rules/no-headingless-sections",bu=on({en:{msg:"All sections must start with a `h2-6` element.",hint:"Add a `h2-6` to the offending section or use a `<div>`."},nl:{msg:"Alle secties moeten beginnen met een `h2-6` element.",hint:"Voeg een `h2-6` toe aan de conflicterende sectie of gebruik een `<div>`."},zh:{msg:"所有章节(section)都必须以 `h2-6` 元素开头。",hint:"将 `h2-6` 添加到有问题的章节或使用 `<div>`。"}});var yu=Object.freeze({__proto__:null,name:gu,run:function(e){if(!e.lint?.["no-headingless-sections"])return;const t=[...document.querySelectorAll("section:not(.head,#abstract,#sotd)")].filter((({firstElementChild:e})=>!e||!(e.matches(".header-wrapper")||e instanceof HTMLHeadingElement)));t.length&&An(bu.msg,gu,{hint:bu.hint,elements:t})}});const wu="core/linter-rules/no-unused-vars",vu=on({en:{msg:"Variable was defined, but never used.",hint:"Add a `data-ignore-unused` attribute to the `<var>`."}});var $u=Object.freeze({__proto__:null,name:wu,run:function(e){if(!e.lint?.["no-unused-vars"])return;const t=[],n=e=>!!e.querySelector(":scope > :not(section) ~ .algorithm, :scope > :not(section) .algorithm");for(const e of document.querySelectorAll("section")){if(!n(e))continue;const r=e.querySelectorAll(":scope > :not(section) var");if(!r.length)continue;const s=new Map;for(const e of r){const t=sn(e.textContent);(s.get(t)||s.set(t,[]).get(t)).push(e)}for(const e of s.values())1!==e.length||e[0].hasAttribute("data-ignore-unused")||t.push(e[0])}t.length&&An(vu.msg,wu,{hint:vu.hint,elements:t})}});const ku="required-sections",xu="w3c/linter-rules/required-sections",_u={en:{msg:e=>`W3C Recommendation track documents require a separate "${e}" section.`,hint:e=>Dn`Add a \`<section>\` with a "${e}" header. See the [Horizontal review guidelines](https://www.w3.org/Guide/documentreview/#how_to_get_horizontal_review).
1224
1225
  If the document is not intended for the W3C Recommendation track, set ${"[noRecTrack]"} to \`true\`
1225
- or turn off the ${`[${$u}]`} linter rule.`,privacy_considerations:"Privacy Considerations",security_considerations:"Security Considerations"},es:{msg:e=>`Documentos que van a ser "W3C Recommendation" requieren una sección "${e}" separada.`,hint:e=>In`Agrega una \`<section>\` con título "${e}". Ver los [Horizontal review guidelines](https://www.w3.org/Guide/documentreview/#how_to_get_horizontal_review).
1226
+ or turn off the ${`[${ku}]`} linter rule.`,privacy_considerations:"Privacy Considerations",security_considerations:"Security Considerations"},es:{msg:e=>`Documentos que van a ser "W3C Recommendation" requieren una sección "${e}" separada.`,hint:e=>Dn`Agrega una \`<section>\` con título "${e}". Ver los [Horizontal review guidelines](https://www.w3.org/Guide/documentreview/#how_to_get_horizontal_review).
1226
1227
  Si el documento no está destinado a ser un W3C Recommendation, puedes poner ${"[noRecTrack]"} a \`true\`
1227
- o apaga la regla de linter ${`[${$u}]`}.`,privacy_considerations:"Consideraciones de privacidad",security_considerations:"Consideraciones de Seguridad"}},_u=sn(xu),Cu=new Set([...Yr]);Cu.delete("DISC"),Vr.forEach((e=>Cu.delete(e)));var Su=Object.freeze({__proto__:null,name:ku,requiresSomeSectionStatus:Cu,run:function(e){if(!e.lint?.[$u])return;if(!on(xu,"privacy_considerations")){return void En("Cannot check for required sections as translations are not available.",ku,{hint:"File an issue to add translations or use a supported language."})}if(e.noRecTrack||!Cu.has(e.specStatus))return;const t="error"===e.lint[$u]?Rn:En,n=new $n([_u.privacy_considerations,_u.security_considerations]),r=document.querySelectorAll("h2, h3, h4, h5, h6");for(const e of r){const t=e.cloneNode(!0);t.querySelectorAll("bdi")?.forEach((e=>e.remove()));const r=rn(t.textContent);if(n.has(r)&&(n.delete(r),0===n.size))return}for(const e of n)t(_u.msg(e),ku,{hint:_u.hint(e)})}});const Ru="core/linter-rules/wpt-tests-exist",Eu=sn({en:{msg:"The following test could not be found in Web Platform Tests:",hint:"Check [wpt.live](https://wpt.live) to see if it was deleted or renamed."}});var Au=Object.freeze({__proto__:null,name:Ru,run:async function(e){if(!e.lint?.["wpt-tests-exist"])return;const t=await async function(e,t){let n;try{const t=new URL(e);if(t.pathname.startsWith("/web-platform-tests/wpt/tree/master/")){const e=/web-platform-tests\/wpt\/tree\/master\/(.+)/;n=t.pathname.match(e)[1].replace(/\//g,"")}else n=t.pathname.replace(/\//g,"")}catch(e){return En("Failed to parse WPT directory from testSuiteURI",`linter/${Ru}`),console.error(e),null}const r=new URL("web-platform-tests/wpt/files",`${t}/`);r.searchParams.set("path",n);const s=await fetch(r);if(!s.ok){return En(`Failed to fetch files from WPT repository. Request failed with error: ${await s.text()} (${s.status})`,`linter/${Ru}`),null}const{entries:i}=await s.json(),o=i.filter((e=>!e.endsWith("/")));return new Set(o)}(e.testSuiteURI,e.githubAPI);if(!t)return;const n=[...document.querySelectorAll("[data-tests]")].filter((e=>e.dataset.tests));for(const e of n)e.dataset.tests.split(/,/gm).map((e=>e.trim().split("#")[0])).filter((e=>e&&!t.has(e))).map((t=>{En(`${Eu.msg} \`${t}\`.`,Ru,{hint:Eu.hint,elements:[e]})}))}});const Tu="core/linter-rules/no-http-props",Lu=sn({en:{msg:In`Insecure URLs are not allowed in ${"[respecConfig]"}.`,hint:"Please change the following properties to 'https://': "},zh:{msg:In`${"[respecConfig]"} 中不允许使用不安全的URL.`,hint:"请将以下属性更改为 https://:"}});var Pu=Object.freeze({__proto__:null,name:Tu,run:function(e){if(!e.lint?.["no-http-props"])return;if(!parent.location.href.startsWith("http"))return;const t=Object.getOwnPropertyNames(e).filter((t=>t.endsWith("URI")&&e[t]||"prevED"===t)).filter((t=>new URL(e[t],parent.location.href).href.startsWith("http://")));if(t.length){const e=en(t,(e=>In`${`[${e}]`}`));En(Lu.msg,Tu,{hint:Lu.hint+e})}}});const Iu="core/linter-rules/a11y",Du=["color-contrast","landmark-one-main","landmark-unique","region"];function Nu(e){const t=[];for(const n of e.split("\n\n")){const[e,...r]=n.split(/^\s{2}/m),s=r.map((e=>`- ${e.trimEnd()}`)).join("\n");t.push(`${e}${s}`)}return t.join("\n\n")}var Ou=Object.freeze({__proto__:null,name:Iu,run:async function(e){if(!e.lint?.a11y&&!e.a11y)return;const t=e.lint?.a11y||e.a11y,n=!0===t?{}:t,r=await async function(e){const{rules:t,...n}=e,r={rules:{...Object.fromEntries(Du.map((e=>[e,{enabled:!1}]))),...t},...n,elementRef:!0,resultTypes:["violations"],reporter:"v1"};let s;try{s=await function(){const e=document.createElement("script");return e.classList.add("remove"),e.src="https://unpkg.com/axe-core@4/axe.min.js",document.head.appendChild(e),new Promise(((t,n)=>{e.onload=()=>t(window.axe),e.onerror=n}))}()}catch(e){return Rn("Failed to load a11y linter.",Iu),console.error(e),[]}try{return(await s.run(document,r)).violations}catch(e){return Rn("Error while looking for a11y issues.",Iu),console.error(e),[]}}(n);for(const e of r){const t=new Map;for(const n of e.nodes){const{failureSummary:e,element:r}=n;(t.get(e)||t.set(e,[]).get(e)).push(r)}const{id:n,help:r,description:s,helpUrl:i}=e,o=`a11y/${n}: ${r}.`;for(const[e,n]of t){const t=Nu(e);En(o,Iu,{details:`\n\n${s}.\n\n${t}. ([Learn more](${i}))`,elements:n})}}}});const ju="informative-dfn",Mu="core/linter-rules/informative-dfn",zu=sn({en:{msg:(e,t)=>`Normative reference to "${e}" found but term is defined "informatively" in "${t}".`,get hint(){return In`
1228
+ o apaga la regla de linter ${`[${ku}]`}.`,privacy_considerations:"Consideraciones de privacidad",security_considerations:"Consideraciones de Seguridad"}},Su=on(_u),Cu=new Set([...Kr]);Cu.delete("DISC"),Yr.forEach((e=>Cu.delete(e)));var Ru=Object.freeze({__proto__:null,name:xu,requiresSomeSectionStatus:Cu,run:function(e){if(!e.lint?.[ku])return;if(!an(_u,"privacy_considerations")){return void An("Cannot check for required sections as translations are not available.",xu,{hint:"File an issue to add translations or use a supported language."})}if(e.noRecTrack||!Cu.has(e.specStatus))return;const t="error"===e.lint[ku]?En:An,n=new kn([Su.privacy_considerations,Su.security_considerations]),r=document.querySelectorAll("h2, h3, h4, h5, h6");for(const e of r){const t=e.cloneNode(!0);t.querySelectorAll("bdi")?.forEach((e=>e.remove()));const r=sn(t.textContent);if(n.has(r)&&(n.delete(r),0===n.size))return}for(const e of n)t(Su.msg(e),xu,{hint:Su.hint(e)})}});const Eu="core/linter-rules/wpt-tests-exist",Au=on({en:{msg:"The following test could not be found in Web Platform Tests:",hint:"Check [wpt.live](https://wpt.live) to see if it was deleted or renamed."}});var Tu=Object.freeze({__proto__:null,name:Eu,run:async function(e){if(!e.lint?.["wpt-tests-exist"])return;const t=await async function(e,t){let n;try{const t=new URL(e);if(t.pathname.startsWith("/web-platform-tests/wpt/tree/master/")){const e=/web-platform-tests\/wpt\/tree\/master\/(.+)/;n=t.pathname.match(e)[1].replace(/\//g,"")}else n=t.pathname.replace(/\//g,"")}catch(e){return An("Failed to parse WPT directory from testSuiteURI",`linter/${Eu}`),console.error(e),null}const r=new URL("web-platform-tests/wpt/files",`${t}/`);r.searchParams.set("path",n);const s=await fetch(r);if(!s.ok){return An(`Failed to fetch files from WPT repository. Request failed with error: ${await s.text()} (${s.status})`,`linter/${Eu}`),null}const{entries:i}=await s.json(),o=i.filter((e=>!e.endsWith("/")));return new Set(o)}(e.testSuiteURI,e.githubAPI);if(!t)return;const n=[...document.querySelectorAll("[data-tests]")].filter((e=>e.dataset.tests));for(const e of n)e.dataset.tests.split(/,/gm).map((e=>e.trim().split("#")[0])).filter((e=>e&&!t.has(e))).map((t=>{An(`${Au.msg} \`${t}\`.`,Eu,{hint:Au.hint,elements:[e]})}))}});const Lu="core/linter-rules/no-http-props",Pu=on({en:{msg:Dn`Insecure URLs are not allowed in ${"[respecConfig]"}.`,hint:"Please change the following properties to 'https://': "},zh:{msg:Dn`${"[respecConfig]"} 中不允许使用不安全的URL.`,hint:"请将以下属性更改为 https://:"}});var Iu=Object.freeze({__proto__:null,name:Lu,run:function(e){if(!e.lint?.["no-http-props"])return;if(!parent.location.href.startsWith("http"))return;const t=Object.getOwnPropertyNames(e).filter((t=>t.endsWith("URI")&&e[t]||"prevED"===t)).filter((t=>new URL(e[t],parent.location.href).href.startsWith("http://")));if(t.length){const e=tn(t,(e=>Dn`${`[${e}]`}`));An(Pu.msg,Lu,{hint:Pu.hint+e})}}});const Du="core/linter-rules/a11y",Nu=["color-contrast","landmark-one-main","landmark-unique","region"];function Ou(e){const t=[];for(const n of e.split("\n\n")){const[e,...r]=n.split(/^\s{2}/m),s=r.map((e=>`- ${e.trimEnd()}`)).join("\n");t.push(`${e}${s}`)}return t.join("\n\n")}var ju=Object.freeze({__proto__:null,name:Du,run:async function(e){if(!e.lint?.a11y&&!e.a11y)return;const t=e.lint?.a11y||e.a11y,n=!0===t?{}:t,r=await async function(e){const{rules:t,...n}=e,r={rules:{...Object.fromEntries(Nu.map((e=>[e,{enabled:!1}]))),...t},...n,elementRef:!0,resultTypes:["violations"],reporter:"v1"};let s;try{s=await function(){const e=document.createElement("script");return e.classList.add("remove"),e.src="https://unpkg.com/axe-core@4/axe.min.js",document.head.appendChild(e),new Promise(((t,n)=>{e.onload=()=>t(window.axe),e.onerror=n}))}()}catch(e){return En("Failed to load a11y linter.",Du),console.error(e),[]}try{return(await s.run(document,r)).violations}catch(e){return En("Error while looking for a11y issues.",Du),console.error(e),[]}}(n);for(const e of r){const t=new Map;for(const n of e.nodes){const{failureSummary:e,element:r}=n;(t.get(e)||t.set(e,[]).get(e)).push(r)}const{id:n,help:r,description:s,helpUrl:i}=e,o=`a11y/${n}: ${r}.`;for(const[e,n]of t){const t=Ou(e);An(o,Du,{details:`\n\n${s}.\n\n${t}. ([Learn more](${i}))`,elements:n})}}}});const Mu="informative-dfn",zu="core/linter-rules/informative-dfn",Uu=on({en:{msg:(e,t)=>`Normative reference to "${e}" found but term is defined "informatively" in "${t}".`,get hint(){return Dn`
1228
1229
  You can do one of the following...
1229
1230
 
1230
1231
  * Get the source definition to be made normative
1231
1232
  * Add a \`class="lint-ignore"\` attribute to the link.
1232
1233
  * Use a local normative proxy for the definition à la \`<dfn data-cite="spec">term</dfn>\`
1233
1234
 
1234
- To silence this warning entirely, set \`lint: { "${ju}": false }\` in your \`respecConfig\`.`}}});var Uu=Object.freeze({__proto__:null,name:Mu,run:function(e){if(!e.lint?.[ju])return;const t="error"===e.lint[ju]?Rn:En;La.forEach((({term:e,spec:n,element:r})=>{r.classList.contains("lint-ignore")||t(zu.msg(e,n),Mu,{title:"Normative reference to non-normative term.",elements:[r],hint:zu.hint})}))}}),qu=Object.freeze({__proto__:null,default:'// ReSpec Worker v1.0.0\n"use strict";\ntry {\n importScripts("https://www.w3.org/Tools/respec/respec-highlight");\n} catch (err) {\n console.error("Network error loading highlighter", err);\n}\n\nself.addEventListener("message", ({ data: originalData }) => {\n const data = Object.assign({}, originalData);\n switch (data.action) {\n case "highlight-load-lang": {\n const { langURL, propName, lang } = data;\n importScripts(langURL);\n self.hljs.registerLanguage(lang, self[propName]);\n break;\n }\n case "highlight": {\n const { code } = data;\n const langs = data.languages.length ? data.languages : undefined;\n try {\n const { value, language } = self.hljs.highlightAuto(code, langs);\n Object.assign(data, { value, language });\n } catch (err) {\n console.error("Could not transform some code?", err);\n // Post back the original code\n Object.assign(data, { value: code, language: "" });\n }\n break;\n }\n }\n self.postMessage(data);\n});\n'}),Wu=Object.freeze({__proto__:null,default:'(() => {\n// @ts-check\nif (document.respec) {\n document.respec.ready.then(setupPanel);\n} else {\n setupPanel();\n}\n\nfunction setupPanel() {\n const listener = panelListener();\n document.body.addEventListener("keydown", listener);\n document.body.addEventListener("click", listener);\n}\n\nfunction panelListener() {\n /** @type {HTMLElement} */\n let panel = null;\n return event => {\n const { target, type } = event;\n\n if (!(target instanceof HTMLElement)) return;\n\n // For keys, we only care about Enter key to activate the panel\n // otherwise it\'s activated via a click.\n if (type === "keydown" && event.key !== "Enter") return;\n\n const action = deriveAction(event);\n\n switch (action) {\n case "show": {\n hidePanel(panel);\n /** @type {HTMLElement} */\n const dfn = target.closest("dfn, .index-term");\n panel = document.getElementById(`dfn-panel-for-${dfn.id}`);\n const coords = deriveCoordinates(event);\n displayPanel(dfn, panel, coords);\n break;\n }\n case "dock": {\n panel.style.left = null;\n panel.style.top = null;\n panel.classList.add("docked");\n break;\n }\n case "hide": {\n hidePanel(panel);\n panel = null;\n break;\n }\n }\n };\n}\n\n/**\n * @param {MouseEvent|KeyboardEvent} event\n */\nfunction deriveCoordinates(event) {\n const target = /** @type HTMLElement */ (event.target);\n\n // We prevent synthetic AT clicks from putting\n // the dialog in a weird place. The AT events sometimes\n // lack coordinates, so they have clientX/Y = 0\n const rect = target.getBoundingClientRect();\n if (\n event instanceof MouseEvent &&\n event.clientX >= rect.left &&\n event.clientY >= rect.top\n ) {\n // The event probably happened inside the bounding rect...\n return { x: event.clientX, y: event.clientY };\n }\n\n // Offset to the middle of the element\n const x = rect.x + rect.width / 2;\n // Placed at the bottom of the element\n const y = rect.y + rect.height;\n return { x, y };\n}\n\n/**\n * @param {Event} event\n */\nfunction deriveAction(event) {\n const target = /** @type {HTMLElement} */ (event.target);\n const hitALink = !!target.closest("a");\n if (target.closest("dfn:not([data-cite]), .index-term")) {\n return hitALink ? "none" : "show";\n }\n if (target.closest(".dfn-panel")) {\n if (hitALink) {\n return target.classList.contains("self-link") ? "hide" : "dock";\n }\n const panel = target.closest(".dfn-panel");\n return panel.classList.contains("docked") ? "hide" : "none";\n }\n if (document.querySelector(".dfn-panel:not([hidden])")) {\n return "hide";\n }\n return "none";\n}\n\n/**\n * @param {HTMLElement} dfn\n * @param {HTMLElement} panel\n * @param {{ x: number, y: number }} clickPosition\n */\nfunction displayPanel(dfn, panel, { x, y }) {\n panel.hidden = false;\n // distance (px) between edge of panel and the pointing triangle (caret)\n const MARGIN = 20;\n\n const dfnRects = dfn.getClientRects();\n // Find the `top` offset when the `dfn` can be spread across multiple lines\n let closestTop = 0;\n let minDiff = Infinity;\n for (const rect of dfnRects) {\n const { top, bottom } = rect;\n const diffFromClickY = Math.abs((top + bottom) / 2 - y);\n if (diffFromClickY < minDiff) {\n minDiff = diffFromClickY;\n closestTop = top;\n }\n }\n\n const top = window.scrollY + closestTop + dfnRects[0].height;\n const left = x - MARGIN;\n panel.style.left = `${left}px`;\n panel.style.top = `${top}px`;\n\n // Find if the panel is flowing out of the window\n const panelRect = panel.getBoundingClientRect();\n const SCREEN_WIDTH = Math.min(window.innerWidth, window.screen.width);\n if (panelRect.right > SCREEN_WIDTH) {\n const newLeft = Math.max(MARGIN, x + MARGIN - panelRect.width);\n const newCaretOffset = left - newLeft;\n panel.style.left = `${newLeft}px`;\n /** @type {HTMLElement} */\n const caret = panel.querySelector(".caret");\n caret.style.left = `${newCaretOffset}px`;\n }\n\n // As it\'s a dialog, we trap focus.\n // TODO: when <dialog> becomes a implemented, we should really\n // use that.\n trapFocus(panel, dfn);\n}\n\n/**\n * @param {HTMLElement} panel\n * @param {HTMLElement} dfn\n * @returns\n */\nfunction trapFocus(panel, dfn) {\n /** @type NodeListOf<HTMLAnchorElement> elements */\n const anchors = panel.querySelectorAll("a[href]");\n // No need to trap focus\n if (!anchors.length) return;\n\n // Move focus to first anchor element\n const first = anchors.item(0);\n first.focus();\n\n const trapListener = createTrapListener(anchors, panel, dfn);\n panel.addEventListener("keydown", trapListener);\n\n // Hiding the panel releases the trap\n const mo = new MutationObserver(records => {\n const [record] = records;\n const target = /** @type HTMLElement */ (record.target);\n if (target.hidden) {\n panel.removeEventListener("keydown", trapListener);\n mo.disconnect();\n }\n });\n mo.observe(panel, { attributes: true, attributeFilter: ["hidden"] });\n}\n\n/**\n *\n * @param {NodeListOf<HTMLAnchorElement>} anchors\n * @param {HTMLElement} panel\n * @param {HTMLElement} dfn\n * @returns\n */\nfunction createTrapListener(anchors, panel, dfn) {\n const lastIndex = anchors.length - 1;\n let currentIndex = 0;\n return event => {\n switch (event.key) {\n // Hitting "Tab" traps us in a nice loop around elements.\n case "Tab": {\n event.preventDefault();\n currentIndex += event.shiftKey ? -1 : +1;\n if (currentIndex < 0) {\n currentIndex = lastIndex;\n } else if (currentIndex > lastIndex) {\n currentIndex = 0;\n }\n anchors.item(currentIndex).focus();\n break;\n }\n\n // Hitting "Enter" on an anchor releases the trap.\n case "Enter":\n hidePanel(panel);\n break;\n\n // Hitting "Escape" returns focus to dfn.\n case "Escape":\n hidePanel(panel);\n dfn.focus();\n return;\n }\n };\n}\n\n/** @param {HTMLElement} panel */\nfunction hidePanel(panel) {\n if (!panel) return;\n panel.hidden = true;\n panel.classList.remove("docked");\n}\n})()'})}();
1235
+ To silence this warning entirely, set \`lint: { "${Mu}": false }\` in your \`respecConfig\`.`}}});var qu=Object.freeze({__proto__:null,name:zu,run:function(e){if(!e.lint?.[Mu])return;const t="error"===e.lint[Mu]?En:An;Pa.forEach((({term:e,spec:n,element:r})=>{r.classList.contains("lint-ignore")||t(Uu.msg(e,n),zu,{title:"Normative reference to non-normative term.",elements:[r],hint:Uu.hint})}))}}),Wu=Object.freeze({__proto__:null,default:'// ReSpec Worker v1.0.0\n"use strict";\ntry {\n importScripts("https://www.w3.org/Tools/respec/respec-highlight");\n} catch (err) {\n console.error("Network error loading highlighter", err);\n}\n\nself.addEventListener("message", ({ data: originalData }) => {\n const data = Object.assign({}, originalData);\n switch (data.action) {\n case "highlight-load-lang": {\n const { langURL, propName, lang } = data;\n importScripts(langURL);\n self.hljs.registerLanguage(lang, self[propName]);\n break;\n }\n case "highlight": {\n const { code } = data;\n const langs = data.languages.length ? data.languages : undefined;\n try {\n const { value, language } = self.hljs.highlightAuto(code, langs);\n Object.assign(data, { value, language });\n } catch (err) {\n console.error("Could not transform some code?", err);\n // Post back the original code\n Object.assign(data, { value: code, language: "" });\n }\n break;\n }\n }\n self.postMessage(data);\n});\n'}),Fu=Object.freeze({__proto__:null,default:'(() => {\n// @ts-check\nif (document.respec) {\n document.respec.ready.then(setupPanel);\n} else {\n setupPanel();\n}\n\nfunction setupPanel() {\n const listener = panelListener();\n document.body.addEventListener("keydown", listener);\n document.body.addEventListener("click", listener);\n}\n\nfunction panelListener() {\n /** @type {HTMLElement} */\n let panel = null;\n return event => {\n const { target, type } = event;\n\n if (!(target instanceof HTMLElement)) return;\n\n // For keys, we only care about Enter key to activate the panel\n // otherwise it\'s activated via a click.\n if (type === "keydown" && event.key !== "Enter") return;\n\n const action = deriveAction(event);\n\n switch (action) {\n case "show": {\n hidePanel(panel);\n /** @type {HTMLElement} */\n const dfn = target.closest("dfn, .index-term");\n panel = document.getElementById(`dfn-panel-for-${dfn.id}`);\n const coords = deriveCoordinates(event);\n displayPanel(dfn, panel, coords);\n break;\n }\n case "dock": {\n panel.style.left = null;\n panel.style.top = null;\n panel.classList.add("docked");\n break;\n }\n case "hide": {\n hidePanel(panel);\n panel = null;\n break;\n }\n }\n };\n}\n\n/**\n * @param {MouseEvent|KeyboardEvent} event\n */\nfunction deriveCoordinates(event) {\n const target = /** @type HTMLElement */ (event.target);\n\n // We prevent synthetic AT clicks from putting\n // the dialog in a weird place. The AT events sometimes\n // lack coordinates, so they have clientX/Y = 0\n const rect = target.getBoundingClientRect();\n if (\n event instanceof MouseEvent &&\n event.clientX >= rect.left &&\n event.clientY >= rect.top\n ) {\n // The event probably happened inside the bounding rect...\n return { x: event.clientX, y: event.clientY };\n }\n\n // Offset to the middle of the element\n const x = rect.x + rect.width / 2;\n // Placed at the bottom of the element\n const y = rect.y + rect.height;\n return { x, y };\n}\n\n/**\n * @param {Event} event\n */\nfunction deriveAction(event) {\n const target = /** @type {HTMLElement} */ (event.target);\n const hitALink = !!target.closest("a");\n if (target.closest("dfn:not([data-cite]), .index-term")) {\n return hitALink ? "none" : "show";\n }\n if (target.closest(".dfn-panel")) {\n if (hitALink) {\n return target.classList.contains("self-link") ? "hide" : "dock";\n }\n const panel = target.closest(".dfn-panel");\n return panel.classList.contains("docked") ? "hide" : "none";\n }\n if (document.querySelector(".dfn-panel:not([hidden])")) {\n return "hide";\n }\n return "none";\n}\n\n/**\n * @param {HTMLElement} dfn\n * @param {HTMLElement} panel\n * @param {{ x: number, y: number }} clickPosition\n */\nfunction displayPanel(dfn, panel, { x, y }) {\n panel.hidden = false;\n // distance (px) between edge of panel and the pointing triangle (caret)\n const MARGIN = 20;\n\n const dfnRects = dfn.getClientRects();\n // Find the `top` offset when the `dfn` can be spread across multiple lines\n let closestTop = 0;\n let minDiff = Infinity;\n for (const rect of dfnRects) {\n const { top, bottom } = rect;\n const diffFromClickY = Math.abs((top + bottom) / 2 - y);\n if (diffFromClickY < minDiff) {\n minDiff = diffFromClickY;\n closestTop = top;\n }\n }\n\n const top = window.scrollY + closestTop + dfnRects[0].height;\n const left = x - MARGIN;\n panel.style.left = `${left}px`;\n panel.style.top = `${top}px`;\n\n // Find if the panel is flowing out of the window\n const panelRect = panel.getBoundingClientRect();\n const SCREEN_WIDTH = Math.min(window.innerWidth, window.screen.width);\n if (panelRect.right > SCREEN_WIDTH) {\n const newLeft = Math.max(MARGIN, x + MARGIN - panelRect.width);\n const newCaretOffset = left - newLeft;\n panel.style.left = `${newLeft}px`;\n /** @type {HTMLElement} */\n const caret = panel.querySelector(".caret");\n caret.style.left = `${newCaretOffset}px`;\n }\n\n // As it\'s a dialog, we trap focus.\n // TODO: when <dialog> becomes a implemented, we should really\n // use that.\n trapFocus(panel, dfn);\n}\n\n/**\n * @param {HTMLElement} panel\n * @param {HTMLElement} dfn\n * @returns\n */\nfunction trapFocus(panel, dfn) {\n /** @type NodeListOf<HTMLAnchorElement> elements */\n const anchors = panel.querySelectorAll("a[href]");\n // No need to trap focus\n if (!anchors.length) return;\n\n // Move focus to first anchor element\n const first = anchors.item(0);\n first.focus();\n\n const trapListener = createTrapListener(anchors, panel, dfn);\n panel.addEventListener("keydown", trapListener);\n\n // Hiding the panel releases the trap\n const mo = new MutationObserver(records => {\n const [record] = records;\n const target = /** @type HTMLElement */ (record.target);\n if (target.hidden) {\n panel.removeEventListener("keydown", trapListener);\n mo.disconnect();\n }\n });\n mo.observe(panel, { attributes: true, attributeFilter: ["hidden"] });\n}\n\n/**\n *\n * @param {NodeListOf<HTMLAnchorElement>} anchors\n * @param {HTMLElement} panel\n * @param {HTMLElement} dfn\n * @returns\n */\nfunction createTrapListener(anchors, panel, dfn) {\n const lastIndex = anchors.length - 1;\n let currentIndex = 0;\n return event => {\n switch (event.key) {\n // Hitting "Tab" traps us in a nice loop around elements.\n case "Tab": {\n event.preventDefault();\n currentIndex += event.shiftKey ? -1 : +1;\n if (currentIndex < 0) {\n currentIndex = lastIndex;\n } else if (currentIndex > lastIndex) {\n currentIndex = 0;\n }\n anchors.item(currentIndex).focus();\n break;\n }\n\n // Hitting "Enter" on an anchor releases the trap.\n case "Enter":\n hidePanel(panel);\n break;\n\n // Hitting "Escape" returns focus to dfn.\n case "Escape":\n hidePanel(panel);\n dfn.focus();\n return;\n }\n };\n}\n\n/** @param {HTMLElement} panel */\nfunction hidePanel(panel) {\n if (!panel) return;\n panel.hidden = true;\n panel.classList.remove("docked");\n}\n})()'})}();
1235
1236
  //# sourceMappingURL=respec-w3c.js.map