@teipublisher/pb-components 2.26.1-next.3 → 3.0.0
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.
- package/.github/workflows/main.yml +3 -3
- package/.github/workflows/node.js.yml +3 -3
- package/.github/workflows/release.js.yml +4 -4
- package/.releaserc.json +2 -2
- package/CHANGELOG.md +262 -11
- package/Dockerfile +78 -70
- package/css/components.css +5 -5
- package/css/leaflet/images/layers.png +0 -0
- package/dist/demo/components.css +46 -1
- package/dist/demo/pb-browse-docs2.html +1 -1
- package/dist/demo/pb-dialog.html +3 -5
- package/dist/demo/pb-drawer2.html +1 -1
- package/dist/demo/pb-facsimile.html +2 -2
- package/dist/demo/pb-grid.html +19 -6
- package/dist/demo/pb-leaflet-map.html +1 -1
- package/dist/demo/pb-login.html +0 -2
- package/dist/demo/pb-message.html +1 -2
- package/dist/demo/pb-progress.html +2 -2
- package/dist/demo/pb-repeat.html +1 -3
- package/dist/demo/pb-search.html +7 -4
- package/dist/demo/pb-search3.html +1 -1
- package/dist/demo/pb-search4.html +2 -2
- package/dist/demo/pb-view3.html +1 -1
- package/dist/{iron-form-3b8dcaa7.js → iron-form-dfb3e3b1.js} +95 -95
- package/dist/paper-checkbox-645e1077.js +200 -0
- package/dist/{paper-icon-button-b1d31571.js → paper-icon-button-984162bd.js} +1 -1
- package/dist/{paper-checkbox-515a5284.js → paper-inky-focus-behavior-fa16796b.js} +58 -247
- package/dist/{paper-listbox-a3b7175c.js → paper-listbox-5f5d1cec.js} +152 -162
- package/dist/pb-code-editor.js +25 -20
- package/dist/pb-component-docs.js +68 -64
- package/dist/pb-components-bundle.js +1983 -2293
- package/dist/pb-edit-app.js +167 -107
- package/dist/pb-elements.json +176 -120
- package/dist/{pb-i18n-0611135a.js → pb-i18n-4cc00bfe.js} +1 -1
- package/dist/pb-leaflet-map.js +23 -23
- package/dist/pb-mei.js +56 -41
- package/dist/{pb-mixin-b1caa22e.js → pb-mixin-886ece32.js} +1 -1
- package/dist/pb-odd-editor.js +1023 -782
- package/dist/pb-tify.js +2 -2
- package/dist/vaadin-element-mixin-beb74ffd.js +545 -0
- package/gh-pages.js +5 -3
- package/i18n/common/en.json +6 -0
- package/i18n/common/pl.json +2 -2
- package/lib/openseadragon.min.js +6 -6
- package/package.json +3 -3
- package/pb-elements.json +176 -120
- package/src/assets/components.css +5 -5
- package/src/authority/airtable.js +20 -21
- package/src/authority/anton.js +129 -129
- package/src/authority/custom.js +23 -21
- package/src/authority/geonames.js +38 -32
- package/src/authority/gnd.js +50 -42
- package/src/authority/kbga.js +137 -134
- package/src/authority/metagrid.js +44 -46
- package/src/authority/reconciliation.js +66 -67
- package/src/authority/registry.js +4 -4
- package/src/docs/pb-component-docs.js +2 -2
- package/src/docs/pb-component-view.js +5 -5
- package/src/docs/pb-components-list.js +2 -2
- package/src/docs/pb-demo-snippet.js +2 -2
- package/src/dts-client.js +299 -297
- package/src/dts-select-endpoint.js +90 -82
- package/src/parse-date-service.js +184 -135
- package/src/pb-ajax.js +158 -171
- package/src/pb-authority-lookup.js +191 -156
- package/src/pb-autocomplete.js +292 -280
- package/src/pb-blacklab-highlight.js +264 -259
- package/src/pb-blacklab-results.js +236 -221
- package/src/pb-browse-docs.js +540 -475
- package/src/pb-browse.js +68 -65
- package/src/pb-clipboard.js +79 -76
- package/src/pb-code-editor.js +110 -102
- package/src/pb-code-highlight.js +209 -204
- package/src/pb-codepen.js +79 -72
- package/src/pb-collapse.js +211 -151
- package/src/pb-combo-box.js +190 -190
- package/src/pb-components-bundle.js +1 -1
- package/src/pb-components.js +1 -0
- package/src/pb-custom-form.js +173 -153
- package/src/pb-dialog.js +98 -62
- package/src/pb-document.js +89 -90
- package/src/pb-download.js +212 -196
- package/src/pb-drawer.js +145 -148
- package/src/pb-edit-app.js +301 -229
- package/src/pb-edit-xml.js +100 -97
- package/src/pb-events.js +114 -107
- package/src/pb-facs-link.js +104 -102
- package/src/pb-facsimile.js +474 -410
- package/src/pb-formula.js +151 -153
- package/src/pb-geolocation.js +129 -131
- package/src/pb-grid-action.js +53 -56
- package/src/pb-grid.js +231 -228
- package/src/pb-highlight.js +140 -140
- package/src/pb-hotkeys.js +40 -42
- package/src/pb-i18n.js +101 -104
- package/src/pb-image-strip.js +84 -78
- package/src/pb-lang.js +142 -57
- package/src/pb-leaflet-map.js +488 -485
- package/src/pb-link.js +126 -124
- package/src/pb-load.js +431 -429
- package/src/pb-login.js +299 -244
- package/src/pb-manage-odds.js +352 -336
- package/src/pb-map-icon.js +89 -89
- package/src/pb-map-layer.js +85 -85
- package/src/pb-markdown.js +90 -99
- package/src/pb-media-query.js +74 -72
- package/src/pb-mei.js +306 -295
- package/src/pb-message.js +139 -97
- package/src/pb-mixin.js +269 -264
- package/src/pb-navigation.js +80 -95
- package/src/pb-observable.js +38 -38
- package/src/pb-odd-editor.js +1054 -958
- package/src/pb-odd-elementspec-editor.js +349 -298
- package/src/pb-odd-model-editor.js +1075 -909
- package/src/pb-odd-parameter-editor.js +200 -178
- package/src/pb-odd-rendition-editor.js +136 -124
- package/src/pb-page.js +431 -422
- package/src/pb-paginate.js +228 -179
- package/src/pb-panel.js +198 -182
- package/src/pb-popover-themes.js +15 -8
- package/src/pb-popover.js +296 -287
- package/src/pb-print-preview.js +127 -127
- package/src/pb-progress.js +51 -51
- package/src/pb-repeat.js +105 -104
- package/src/pb-restricted.js +84 -77
- package/src/pb-search.js +256 -228
- package/src/pb-select-feature.js +127 -120
- package/src/pb-select-odd.js +132 -124
- package/src/pb-select-template.js +89 -78
- package/src/pb-select.js +251 -227
- package/src/pb-split-list.js +179 -174
- package/src/pb-svg.js +80 -79
- package/src/pb-table-column.js +54 -54
- package/src/pb-table-grid.js +221 -203
- package/src/pb-tabs.js +61 -63
- package/src/pb-tify.js +154 -154
- package/src/pb-timeline.js +382 -249
- package/src/pb-toggle-feature.js +195 -187
- package/src/pb-upload.js +184 -174
- package/src/pb-version.js +30 -30
- package/src/pb-view-annotate.js +135 -98
- package/src/pb-view.js +1282 -1270
- package/src/pb-zoom.js +127 -45
- package/src/polymer-hack.js +1 -1
- package/src/search-result-service.js +256 -223
- package/src/seed-element.js +13 -20
- package/src/settings.js +4 -4
- package/src/theming.js +98 -91
- package/src/urls.js +289 -289
- package/src/utils.js +53 -51
- package/css/pb-styles.css +0 -51
- package/dist/vaadin-element-mixin-fe4a4883.js +0 -527
- package/src/assets/pb-styles.css +0 -51
- package/src/pb-light-dom.js +0 -41
package/dist/pb-code-editor.js
CHANGED
|
@@ -1,22 +1,27 @@
|
|
|
1
|
-
import{p as e,h as t,c as i,L as o}from"./pb-mixin-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
1
|
+
import{p as e,h as t,c as i,L as o}from"./pb-mixin-886ece32.js";import{J as n,X as s}from"./jinn-codemirror-da0e2d1f.js";import{t as r}from"./pb-i18n-4cc00bfe.js";class l extends n{constructor(){super(),this.unwrap=!1,this.schema=null,this.schemaRoot=null}connectedCallback(){this.schema=this.getAttribute("schema"),this.schemaRoot=this.getAttribute("schema-root"),this.unwrap=this.hasAttribute("unwrap"),super.connectedCallback();const e=this.getAttribute("wrapper");if(e){const t=new DOMParser;let i=t.parseFromString(e,"application/xml"),o=i.getElementsByTagName("parsererror"),n=null;if(o.length)console.error("<jinn-xml-editor> Invalid XML for wrapper attribute: %s",(new XMLSerializer).serializeToString(i));else{if(n=i.firstElementChild,n&&this.hasAttribute("code")){const e=this.getAttribute("code")||"";i=t.parseFromString(e,"application/xml"),o=i.getElementsByTagName("parsererror"),o.length?console.error("<jinn-xml-editor> Invalid XML for code attribute: %s",(new XMLSerializer).serializeToString(i)):i.firstElementChild&&n.appendChild(i.firstElementChild)}this.setValue(n)}}}configure(){var e;const t=this.getToolbarControls(null==(e=this.shadowRoot)?void 0:e.querySelector("[name=toolbar]")),i=this.hasAttribute("check-namespace");this._config=new s(this,t,this.namespace,i,this.unwrap)}emitUpdateEvent(e){if(!this.unwrap)return super.emitUpdateEvent(e);this.updateValue(),super.emitUpdateEvent(this._wrapper)}updateValue(){var e,t;if(!this._wrapper)return console.log("no wrapper !!!"),null;if(this._wrapper.replaceChildren(),this._value)if(this._value instanceof NodeList)for(let t=0;t<this._value.length;t++){const i=this._wrapper.ownerDocument.importNode(this._value[t],!0);null==(e=this._wrapper)||e.appendChild(i)}else{if(!(this._value instanceof Node))throw console.error("<xml-editor> Value is not a node"),new Error("value is not a node");null==(t=this._wrapper)||t.appendChild(this._value)}else console.log("xml editor value is empty")}setValue(e){var t,i;if(!this.unwrap)return super.setValue(e);if((null==(t=this._config)?void 0:t.setFromValue(this._wrapper))===(null==(i=this._config)?void 0:i.setFromValue(e)))return!1;if(e||(this._wrapper=null),"string"==typeof e){const t=(new DOMParser).parseFromString(e,"application/xml");if(!t.firstElementChild)return!1;e=t.firstElementChild}return this._wrapper=e,this._value=null==e?void 0:e.childNodes,!0}getValue(){if(!this.unwrap)return super.getValue();if(!this._wrapper)return null;if(!(this._wrapper instanceof Element))throw new Error("Value is not a node");return this.updateValue(),this._wrapper}}customElements.get("jinn-xml-editor")||window.customElements.define("jinn-xml-editor",l);const a='\n :host {\n display: block;\n width: 100%;\n }\n jinn-codemirror {\n font-size: 1rem;\n display:block;\n width:100%;\n }\n jinn-codemirror[valid="true"] {\n outline: thin solid green;\n }\n jinn-codemirror[valid="false"] {\n outline: thin solid red;\n }\n #leiden-editor {\n margin-bottom:0.5rem;\n }\n [slot=toolbar] {\n display: flex;\n }\n .hidden {\n display: none;\n }\n #close-leiden {\n margin-left: .75rem;\n font-weight: bold;\n }',d=["Shift","Alt","Meta","Control","ArrowLeft","ArrowRight","ArrowDown","ArrowUp","PageDown","PageUp","Home","End"],h={leiden_plus:"Leiden+",edcs:"EDCS/EDH",default:"Petrae"};function c(e){const t=[];return Object.entries(h).forEach(([i,o])=>{t.push(`<option value="${i}" ${i===e?"selected":""}>${o}</option>`)}),`<select name="modes">${t.join("\n")}</select>`}class u extends HTMLElement{constructor(){super(),this.mode="leiden_plus",this.placeholder="",this.showLeiden=!1,this.xmlEditor=null,this.valid=!0,this.unwrap=!1,this.schema=null,this.schemaRoot=null,this.modeSelect=!1,this.attachShadow({mode:"open"})}set value(e){this.xmlEditor.value=e}get value(){return this.xmlEditor.value}connectedCallback(){var e,t,i,o;this.unwrap=this.hasAttribute("unwrap"),this.schema=this.getAttribute("schema"),this.schemaRoot=this.getAttribute("schema-root"),this.modeSelect=this.hasAttribute("mode-select"),this.mode=this.getAttribute("mode")||"leiden_plus",this.placeholder=this.getAttribute("placeholder")||"",this.showLeiden=this.hasAttribute("show-leiden"),this.shadowRoot.innerHTML=`\n <style>\n ${a}\n </style>\n <jinn-codemirror id="leiden-editor" class="${this.showLeiden?"":"hidden"}" mode="${this.mode}">\n <div slot="toolbar">\n ${this.modeSelect?c(this.mode):""}\n <slot name="leiden-toolbar"></slot>\n <button part="button" id="close-leiden">Close</button>\n </div>\n </jinn-codemirror>\n <jinn-xml-editor id="xml-editor" ${this.unwrap?"unwrap":""} schema="${this.schema}"\n schema-root="${this.schemaRoot}" placeholder="${this.placeholder}">\n <div slot="toolbar">\n <button part="button" id="import" title="Import from Leiden markup">Leiden Editor</button>\n <slot name="xml-toolbar"></slot>\n </div>\n </jinn-xml-editor>\n `,this.xmlEditor=null==(e=this.shadowRoot)?void 0:e.querySelector("#xml-editor");const n=null==(t=this.shadowRoot)?void 0:t.querySelector("#leiden-editor"),s=null==(i=this.shadowRoot)?void 0:i.querySelector("#import"),r=null==(o=this.shadowRoot)?void 0:o.querySelector("#close-leiden");if(!(this.xmlEditor&&n&&s&&r))throw new Error("One or more components were not initialized");let l=!0,h=this.showLeiden;n.addEventListener("update",e=>{e.stopPropagation(),this.showLeiden=!1,l&&(this.xmlEditor.content=e.detail.content),l=!0}),this.xmlEditor.addEventListener("keyup",e=>{if(h){if(d.indexOf(e.key)>-1)return;p()}});const u=()=>{s.classList.add("hidden"),n.classList.remove("hidden"),h=!0,n.focus()},p=()=>{var e;n.classList.add("hidden"),s.classList.remove("hidden"),h=!1,null==(e=this.xmlEditor)||e.focus(),l=!1,null==n||n.clear()},m=()=>{var e;if(n.classList.contains("hidden")||this.showLeiden)if(this.xmlEditor.content.length>0){if(!this.valid)return void alert("The XML contains errors. Cannot convert to Leiden+");const t=null==(e=this.xmlEditor)?void 0:e.value;l=!1,n.setMode("leiden_plus",!1),u(),this.unwrap&&t instanceof Element?n.value=t.childNodes:n.value=t}else u(),n.value="";else p()};s.addEventListener("click",()=>{m()}),r.addEventListener("click",()=>{p()}),this.xmlEditor.addEventListener("invalid",e=>{e.stopPropagation(),this.valid=!1,this.setAttribute("valid",this.valid.toString()),this.dispatchEvent(new CustomEvent("invalid",{detail:e.detail,composed:!0,bubbles:!0}))}),this.xmlEditor.addEventListener("valid",e=>{e.stopPropagation(),this.valid=!0,this.setAttribute("valid",this.valid.toString()),this.dispatchEvent(new CustomEvent("valid",{detail:e.detail,composed:!0,bubbles:!0}))}),this.xmlEditor.addEventListener("update",()=>{this.showLeiden&&m(),this.showLeiden=!1},{once:!0})}}customElements.get("jinn-epidoc-editor")||window.customElements.define("jinn-epidoc-editor",u);class p extends(e(o)){static get properties(){return Object.assign(Object.assign({},super.properties),{},{code:{type:String,reflect:!0},mode:{type:String},label:{type:String},placeholder:{type:String},tabSize:{type:Number},linter:{attribute:!0}})}constructor(){super(),this.code="",this.mode="xml",this.placeholder="odd.editor.model.empty",this.tabSize=2,this.label="",this.linter="",this._editor=null}connectedCallback(){super.connectedCallback()}firstUpdated(){super.firstUpdated(),this._editor=this.shadowRoot.getElementById("editor")}render(){return t`
|
|
2
|
+
<div class="label">${this.label}</div>
|
|
3
|
+
<jinn-codemirror
|
|
4
|
+
id="editor"
|
|
5
|
+
mode="${this.mode}"
|
|
6
|
+
code="${this.code}"
|
|
7
|
+
placeholder="${r(this.placeholder)}"
|
|
8
|
+
></jinn-codemirror>
|
|
9
|
+
`}getSource(){return this._editor?this._editor.value:""}_setCode(){this.dispatchEvent(new CustomEvent("code-changed",{composed:!0,bubbles:!0,detail:{code:this.getSource()}}))}refresh(){}static get styles(){return i`
|
|
10
|
+
:host {
|
|
11
|
+
display: block;
|
|
12
|
+
width: 100%;
|
|
13
|
+
margin: 0;
|
|
14
|
+
position: relative;
|
|
15
|
+
color: inherit;
|
|
16
|
+
}
|
|
12
17
|
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
18
|
+
#editor {
|
|
19
|
+
width: 100%;
|
|
20
|
+
height: auto;
|
|
21
|
+
}
|
|
17
22
|
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
+
.label {
|
|
24
|
+
color: var(--paper-grey-500);
|
|
25
|
+
margin-bottom: 5px;
|
|
26
|
+
}
|
|
27
|
+
`}}customElements.define("pb-code-editor",p);export{p as PbCodeEditor};
|
|
@@ -3101,62 +3101,66 @@ Mo({_template:ua`
|
|
|
3101
3101
|
* @author Lea Verou <https://lea.verou.me>
|
|
3102
3102
|
* @namespace
|
|
3103
3103
|
* @public
|
|
3104
|
-
*/function oc(e){const t=document.querySelector("script[src*=pb-components]");return t?new URL(e,t.src).href:new URL(e,window.location.href).href}function ac(e,t,n){const i=getComputedStyle(e).getPropertyValue(t);if(i)try{return JSON.parse(i)}catch(e){return n}return n}"undefined"!=typeof module&&module.exports&&(module.exports=sc),"undefined"!=typeof global&&(global.Prism=sc),sc.languages.markup={comment:{pattern:/<!--(?:(?!<!--)[\s\S])*?-->/,greedy:!0},prolog:{pattern:/<\?[\s\S]+?\?>/,greedy:!0},doctype:{pattern:/<!DOCTYPE(?:[^>"'[\]]|"[^"]*"|'[^']*')+(?:\[(?:[^<"'\]]|"[^"]*"|'[^']*'|<(?!!--)|<!--(?:[^-]|-(?!->))*-->)*\]\s*)?>/i,greedy:!0,inside:{"internal-subset":{pattern:/(^[^\[]*\[)[\s\S]+(?=\]>$)/,lookbehind:!0,greedy:!0,inside:null},string:{pattern:/"[^"]*"|'[^']*'/,greedy:!0},punctuation:/^<!|>$|[[\]]/,"doctype-tag":/^DOCTYPE/i,name:/[^\s<>'"]+/}},cdata:{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,greedy:!0},tag:{pattern:/<\/?(?!\d)[^\s>\/=$<%]+(?:\s(?:\s*[^\s>\/=]+(?:\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))|(?=[\s/>])))+)?\s*\/?>/,greedy:!0,inside:{tag:{pattern:/^<\/?[^\s>\/]+/,inside:{punctuation:/^<\/?/,namespace:/^[^\s>\/:]+:/}},"special-attr":[],"attr-value":{pattern:/=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+)/,inside:{punctuation:[{pattern:/^=/,alias:"attr-equals"},{pattern:/^(\s*)["']|["']$/,lookbehind:!0}]}},punctuation:/\/?>/,"attr-name":{pattern:/[^\s>\/]+/,inside:{namespace:/^[^\s>\/:]+:/}}}},entity:[{pattern:/&[\da-z]{1,8};/i,alias:"named-entity"},/&#x?[\da-f]{1,8};/i]},sc.languages.markup.tag.inside["attr-value"].inside.entity=sc.languages.markup.entity,sc.languages.markup.doctype.inside["internal-subset"].inside=sc.languages.markup,sc.hooks.add("wrap",(function(e){"entity"===e.type&&(e.attributes.title=e.content.replace(/&/,"&"))})),Object.defineProperty(sc.languages.markup.tag,"addInlined",{value:function(e,t){var n={};n["language-"+t]={pattern:/(^<!\[CDATA\[)[\s\S]+?(?=\]\]>$)/i,lookbehind:!0,inside:sc.languages[t]},n.cdata=/^<!\[CDATA\[|\]\]>$/i;var i={"included-cdata":{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,inside:n}};i["language-"+t]={pattern:/[\s\S]+/,inside:sc.languages[t]};var r={};r[e]={pattern:RegExp(/(<__[^>]*>)(?:<!\[CDATA\[(?:[^\]]|\](?!\]>))*\]\]>|(?!<!\[CDATA\[)[\s\S])*?(?=<\/__>)/.source.replace(/__/g,(function(){return e})),"i"),lookbehind:!0,greedy:!0,inside:i},sc.languages.insertBefore("markup","cdata",r)}}),Object.defineProperty(sc.languages.markup.tag,"addAttribute",{value:function(e,t){sc.languages.markup.tag.inside["special-attr"].push({pattern:RegExp(/(^|["'\s])/.source+"(?:"+e+")"+/\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))/.source,"i"),lookbehind:!0,inside:{"attr-name":/^[^\s=]+/,"attr-value":{pattern:/=[\s\S]+/,inside:{value:{pattern:/(^=\s*(["']|(?!["'])))\S[\s\S]*(?=\2$)/,lookbehind:!0,alias:[t,"language-"+t],inside:sc.languages[t]},punctuation:[{pattern:/^=/,alias:"attr-equals"},/"|'/]}}}})}}),sc.languages.html=sc.languages.markup,sc.languages.mathml=sc.languages.markup,sc.languages.svg=sc.languages.markup,sc.languages.xml=sc.languages.extend("markup",{}),sc.languages.ssml=sc.languages.xml,sc.languages.atom=sc.languages.xml,sc.languages.rss=sc.languages.xml,function(e){var t=/(?:"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n])*')/;e.languages.css={comment:/\/\*[\s\S]*?\*\//,atrule:{pattern:RegExp("@[\\w-](?:"+/[^;{\s"']|\s+(?!\s)/.source+"|"+t.source+")*?"+/(?:;|(?=\s*\{))/.source),inside:{rule:/^@[\w-]+/,"selector-function-argument":{pattern:/(\bselector\s*\(\s*(?![\s)]))(?:[^()\s]|\s+(?![\s)])|\((?:[^()]|\([^()]*\))*\))+(?=\s*\))/,lookbehind:!0,alias:"selector"},keyword:{pattern:/(^|[^\w-])(?:and|not|only|or)(?![\w-])/,lookbehind:!0}}},url:{pattern:RegExp("\\burl\\((?:"+t.source+"|"+/(?:[^\\\r\n()"']|\\[\s\S])*/.source+")\\)","i"),greedy:!0,inside:{function:/^url/i,punctuation:/^\(|\)$/,string:{pattern:RegExp("^"+t.source+"$"),alias:"url"}}},selector:{pattern:RegExp("(^|[{}\\s])[^{}\\s](?:[^{};\"'\\s]|\\s+(?![\\s{])|"+t.source+")*(?=\\s*\\{)"),lookbehind:!0},string:{pattern:t,greedy:!0},property:{pattern:/(^|[^-\w\xA0-\uFFFF])(?!\s)[-_a-z\xA0-\uFFFF](?:(?!\s)[-\w\xA0-\uFFFF])*(?=\s*:)/i,lookbehind:!0},important:/!important\b/i,function:{pattern:/(^|[^-a-z0-9])[-a-z0-9]+(?=\()/i,lookbehind:!0},punctuation:/[(){};:,]/},e.languages.css.atrule.inside.rest=e.languages.css;var n=e.languages.markup;n&&(n.tag.addInlined("style","css"),n.tag.addAttribute("style","css"))}(sc),sc.languages.clike={comment:[{pattern:/(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0},"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|trait)\s+|\bcatch\s+\()[\w.\\]+/i,lookbehind:!0,inside:{punctuation:/[.\\]/}},keyword:/\b(?:break|catch|continue|do|else|finally|for|function|if|in|instanceof|new|null|return|throw|try|while)\b/,boolean:/\b(?:false|true)\b/,function:/\b\w+(?=\()/,number:/\b0x[\da-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?/i,operator:/[<>]=?|[!=]=?=?|--?|\+\+?|&&?|\|\|?|[?*/~^%]/,punctuation:/[{}[\];(),.:]/},sc.languages.javascript=sc.languages.extend("clike",{"class-name":[sc.languages.clike["class-name"],{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$A-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\.(?:constructor|prototype))/,lookbehind:!0}],keyword:[{pattern:/((?:^|\})\s*)catch\b/,lookbehind:!0},{pattern:/(^|[^.]|\.\.\.\s*)\b(?:as|assert(?=\s*\{)|async(?=\s*(?:function\b|\(|[$\w\xA0-\uFFFF]|$))|await|break|case|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally(?=\s*(?:\{|$))|for|from(?=\s*(?:['"]|$))|function|(?:get|set)(?=\s*(?:[#\[$\w\xA0-\uFFFF]|$))|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)\b/,lookbehind:!0}],function:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*(?:\.\s*(?:apply|bind|call)\s*)?\()/,number:{pattern:RegExp(/(^|[^\w$])/.source+"(?:"+/NaN|Infinity/.source+"|"+/0[bB][01]+(?:_[01]+)*n?/.source+"|"+/0[oO][0-7]+(?:_[0-7]+)*n?/.source+"|"+/0[xX][\dA-Fa-f]+(?:_[\dA-Fa-f]+)*n?/.source+"|"+/\d+(?:_\d+)*n/.source+"|"+/(?:\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\.\d+(?:_\d+)*)(?:[Ee][+-]?\d+(?:_\d+)*)?/.source+")"+/(?![\w$])/.source),lookbehind:!0},operator:/--|\+\+|\*\*=?|=>|&&=?|\|\|=?|[!=]==|<<=?|>>>?=?|[-+*/%&|^!=<>]=?|\.{3}|\?\?=?|\?\.?|[~:]/}),sc.languages.javascript["class-name"][0].pattern=/(\b(?:class|extends|implements|instanceof|interface|new)\s+)[\w.\\]+/,sc.languages.insertBefore("javascript","keyword",{regex:{pattern:RegExp(/((?:^|[^$\w\xA0-\uFFFF."'\])\s]|\b(?:return|yield))\s*)/.source+/\//.source+"(?:"+/(?:\[(?:[^\]\\\r\n]|\\.)*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}/.source+"|"+/(?:\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.)*\])*\])*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}v[dgimyus]{0,7}/.source+")"+/(?=(?:\s|\/\*(?:[^*]|\*(?!\/))*\*\/)*(?:$|[\r\n,.;:})\]]|\/\/))/.source),lookbehind:!0,greedy:!0,inside:{"regex-source":{pattern:/^(\/)[\s\S]+(?=\/[a-z]*$)/,lookbehind:!0,alias:"language-regex",inside:sc.languages.regex},"regex-delimiter":/^\/|\/$/,"regex-flags":/^[a-z]+$/}},"function-variable":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*[=:]\s*(?:async\s*)?(?:\bfunction\b|(?:\((?:[^()]|\([^()]*\))*\)|(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/,alias:"function"},parameter:[{pattern:/(function(?:\s+(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)?\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\))/,lookbehind:!0,inside:sc.languages.javascript},{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=>)/i,lookbehind:!0,inside:sc.languages.javascript},{pattern:/(\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*=>)/,lookbehind:!0,inside:sc.languages.javascript},{pattern:/((?:\b|\s|^)(?!(?:as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)(?![$\w\xA0-\uFFFF]))(?:(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*)\(\s*|\]\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*\{)/,lookbehind:!0,inside:sc.languages.javascript}],constant:/\b[A-Z](?:[A-Z_]|\dx?)*\b/}),sc.languages.insertBefore("javascript","string",{hashbang:{pattern:/^#!.*/,greedy:!0,alias:"comment"},"template-string":{pattern:/`(?:\\[\s\S]|\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}|(?!\$\{)[^\\`])*`/,greedy:!0,inside:{"template-punctuation":{pattern:/^`|`$/,alias:"string"},interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,lookbehind:!0,inside:{"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:"punctuation"},rest:sc.languages.javascript}},string:/[\s\S]+/}},"string-property":{pattern:/((?:^|[,{])[ \t]*)(["'])(?:\\(?:\r\n|[\s\S])|(?!\2)[^\\\r\n])*\2(?=\s*:)/m,lookbehind:!0,greedy:!0,alias:"property"}}),sc.languages.insertBefore("javascript","operator",{"literal-property":{pattern:/((?:^|[,{])[ \t]*)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*:)/m,lookbehind:!0,alias:"property"}}),sc.languages.markup&&(sc.languages.markup.tag.addInlined("script","javascript"),sc.languages.markup.tag.addAttribute(/on(?:abort|blur|change|click|composition(?:end|start|update)|dblclick|error|focus(?:in|out)?|key(?:down|up)|load|mouse(?:down|enter|leave|move|out|over|up)|reset|resize|scroll|select|slotchange|submit|unload|wheel)/.source,"javascript")),sc.languages.js=sc.languages.javascript,function(){if(void 0!==sc&&"undefined"!=typeof document){Element.prototype.matches||(Element.prototype.matches=Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector);var e="Loading…",t=function(e,t){return"✖ Error "+e+" while fetching file: "+t},n="✖ Error: File does not exist or is empty",i={js:"javascript",py:"python",rb:"ruby",ps1:"powershell",psm1:"powershell",sh:"bash",bat:"batch",h:"c",tex:"latex"},r="data-src-status",s="loading",o="loaded",a="failed",l="pre[data-src]:not(["+r+'="'+o+'"]):not(['+r+'="'+s+'"])';sc.hooks.add("before-highlightall",(function(e){e.selector+=", "+l})),sc.hooks.add("before-sanity-check",(function(t){var n=t.element;if(n.matches(l)){t.code="",n.setAttribute(r,s);var c=n.appendChild(document.createElement("CODE"));c.textContent=e;var p=n.getAttribute("data-src"),u=t.language;if("none"===u){var f=(/\.(\w+)$/.exec(p)||[,"none"])[1];u=i[f]||f}sc.util.setLanguage(c,u),sc.util.setLanguage(n,u);var m=sc.plugins.autoloader;m&&m.loadLanguages(u),h(p,(function(e){n.setAttribute(r,o);var t=d(n.getAttribute("data-range"));if(t){var i=e.split(/\r\n?|\n/g),s=t[0],a=null==t[1]?i.length:t[1];s<0&&(s+=i.length),s=Math.max(0,Math.min(s-1,i.length)),a<0&&(a+=i.length),a=Math.max(0,Math.min(a,i.length)),e=i.slice(s,a).join("\n"),n.hasAttribute("data-start")||n.setAttribute("data-start",String(s+1))}c.textContent=e,sc.highlightElement(c)}),(function(e){n.setAttribute(r,a),c.textContent=e}))}})),sc.plugins.fileHighlight={highlight:function(e){for(var t,n=(e||document).querySelectorAll(l),i=0;t=n[i++];)sc.highlightElement(t)}};var c=!1;sc.fileHighlight=function(){c||(console.warn("Prism.fileHighlight is deprecated. Use `Prism.plugins.fileHighlight.highlight` instead."),c=!0),sc.plugins.fileHighlight.highlight.apply(this,arguments)}}function h(e,i,r){var s=new XMLHttpRequest;s.open("GET",e,!0),s.onreadystatechange=function(){4==s.readyState&&(s.status<400&&s.responseText?i(s.responseText):s.status>=400?r(t(s.status,s.statusText)):r(n))},s.send(null)}function d(e){var t=/^\s*(\d+)\s*(?:(,)\s*(?:(\d+)\s*)?)?$/.exec(e||"");if(t){var n=Number(t[1]),i=t[2],r=t[3];return i?r?[n,Number(r)]:[n,void 0]:[n,n]}}}(),function(e){e.languages.xquery=e.languages.extend("markup",{"xquery-comment":{pattern:/\(:[\s\S]*?:\)/,greedy:!0,alias:"comment"},string:{pattern:/(["'])(?:\1\1|(?!\1)[\s\S])*\1/,greedy:!0},extension:{pattern:/\(#.+?#\)/,alias:"symbol"},variable:/\$[-\w:]+/,axis:{pattern:/(^|[^-])(?:ancestor(?:-or-self)?|attribute|child|descendant(?:-or-self)?|following(?:-sibling)?|parent|preceding(?:-sibling)?|self)(?=::)/,lookbehind:!0,alias:"operator"},"keyword-operator":{pattern:/(^|[^:-])\b(?:and|castable as|div|eq|except|ge|gt|idiv|instance of|intersect|is|le|lt|mod|ne|or|union)\b(?=$|[^:-])/,lookbehind:!0,alias:"operator"},keyword:{pattern:/(^|[^:-])\b(?:as|ascending|at|base-uri|boundary-space|case|cast as|collation|construction|copy-namespaces|declare|default|descending|else|empty (?:greatest|least)|encoding|every|external|for|function|if|import|in|inherit|lax|let|map|module|namespace|no-inherit|no-preserve|option|order(?: by|ed|ing)?|preserve|return|satisfies|schema|some|stable|strict|strip|then|to|treat as|typeswitch|unordered|validate|variable|version|where|xquery)\b(?=$|[^:-])/,lookbehind:!0},function:/[\w-]+(?::[\w-]+)*(?=\s*\()/,"xquery-element":{pattern:/(element\s+)[\w-]+(?::[\w-]+)*/,lookbehind:!0,alias:"tag"},"xquery-attribute":{pattern:/(attribute\s+)[\w-]+(?::[\w-]+)*/,lookbehind:!0,alias:"attr-name"},builtin:{pattern:/(^|[^:-])\b(?:attribute|comment|document|element|processing-instruction|text|xs:(?:ENTITIES|ENTITY|ID|IDREFS?|NCName|NMTOKENS?|NOTATION|Name|QName|anyAtomicType|anyType|anyURI|base64Binary|boolean|byte|date|dateTime|dayTimeDuration|decimal|double|duration|float|gDay|gMonth|gMonthDay|gYear|gYearMonth|hexBinary|int|integer|language|long|negativeInteger|nonNegativeInteger|nonPositiveInteger|normalizedString|positiveInteger|short|string|time|token|unsigned(?:Byte|Int|Long|Short)|untyped(?:Atomic)?|yearMonthDuration))\b(?=$|[^:-])/,lookbehind:!0},number:/\b\d+(?:\.\d+)?(?:E[+-]?\d+)?/,operator:[/[+*=?|@]|\.\.?|:=|!=|<[=<]?|>[=>]?/,{pattern:/(\s)-(?=\s)/,lookbehind:!0}],punctuation:/[[\](){},;:/]/}),e.languages.xquery.tag.pattern=/<\/?(?!\d)[^\s>\/=$<%]+(?:\s+[^\s>\/=]+(?:=(?:("|')(?:\\[\s\S]|\{(?!\{)(?:\{(?:\{[^{}]*\}|[^{}])*\}|[^{}])+\}|(?!\1)[^\\])*\1|[^\s'">=]+))?)*\s*\/?>/,e.languages.xquery.tag.inside["attr-value"].pattern=/=(?:("|')(?:\\[\s\S]|\{(?!\{)(?:\{(?:\{[^{}]*\}|[^{}])*\}|[^{}])+\}|(?!\1)[^\\])*\1|[^\s'">=]+)/,e.languages.xquery.tag.inside["attr-value"].inside.punctuation=/^="|"$/,e.languages.xquery.tag.inside["attr-value"].inside.expression={pattern:/\{(?!\{)(?:\{(?:\{[^{}]*\}|[^{}])*\}|[^{}])+\}/,inside:e.languages.xquery,alias:"language-xquery"};var t=function(e){return"string"==typeof e?e:"string"==typeof e.content?e.content:e.content.map(t).join("")},n=function(i){for(var r=[],s=0;s<i.length;s++){var o=i[s],a=!1;if("string"!=typeof o&&("tag"===o.type&&o.content[0]&&"tag"===o.content[0].type?"</"===o.content[0].content[0].content?r.length>0&&r[r.length-1].tagName===t(o.content[0].content[1])&&r.pop():"/>"===o.content[o.content.length-1].content||r.push({tagName:t(o.content[0].content[1]),openedBraces:0}):!(r.length>0&&"punctuation"===o.type&&"{"===o.content)||i[s+1]&&"punctuation"===i[s+1].type&&"{"===i[s+1].content||i[s-1]&&"plain-text"===i[s-1].type&&"{"===i[s-1].content?r.length>0&&r[r.length-1].openedBraces>0&&"punctuation"===o.type&&"}"===o.content?r[r.length-1].openedBraces--:"comment"!==o.type&&(a=!0):r[r.length-1].openedBraces++),(a||"string"==typeof o)&&r.length>0&&0===r[r.length-1].openedBraces){var l=t(o);s<i.length-1&&("string"==typeof i[s+1]||"plain-text"===i[s+1].type)&&(l+=t(i[s+1]),i.splice(s+1,1)),s>0&&("string"==typeof i[s-1]||"plain-text"===i[s-1].type)&&(l=t(i[s-1])+l,i.splice(s-1,1),s--),/^\s+$/.test(l)?i[s]=l:i[s]=new e.Token("plain-text",l,null,l)}o.content&&"string"!=typeof o.content&&n(o.content)}};e.hooks.add("after-tokenize",(function(e){"xquery"===e.language&&n(e.tokens)}))}(Prism),function(){if("undefined"!=typeof Prism){var e=Object.assign||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n]);return e},t={"remove-trailing":"boolean","remove-indent":"boolean","left-trim":"boolean","right-trim":"boolean","break-lines":"number",indent:"number","remove-initial-line-feed":"boolean","tabs-to-spaces":"number","spaces-to-tabs":"number"};n.prototype={setDefaults:function(t){this.defaults=e(this.defaults,t)},normalize:function(t,n){for(var r in n=e(this.defaults,n)){var s=i(r);"normalize"!==r&&"setDefaults"!==s&&n[r]&&this[s]&&(t=this[s].call(this,t,n[r]))}return t},leftTrim:function(e){return e.replace(/^\s+/,"")},rightTrim:function(e){return e.replace(/\s+$/,"")},tabsToSpaces:function(e,t){return t=0|t||4,e.replace(/\t/g,new Array(++t).join(" "))},spacesToTabs:function(e,t){return t=0|t||4,e.replace(RegExp(" {"+t+"}","g"),"\t")},removeTrailing:function(e){return e.replace(/\s*?$/gm,"")},removeInitialLineFeed:function(e){return e.replace(/^(?:\r?\n|\r)/,"")},removeIndent:function(e){var t=e.match(/^[^\S\n\r]*(?=\S)/gm);return t&&t[0].length?(t.sort((function(e,t){return e.length-t.length})),t[0].length?e.replace(RegExp("^"+t[0],"gm"),""):e):e},indent:function(e,t){return e.replace(/^[^\S\n\r]*(?=\S)/gm,new Array(++t).join("\t")+"$&")},breakLines:function(e,t){t=!0===t?80:0|t||80;for(var n=e.split("\n"),i=0;i<n.length;++i)if(!(r(n[i])<=t)){for(var s=n[i].split(/(\s+)/g),o=0,a=0;a<s.length;++a){var l=r(s[a]);(o+=l)>t&&(s[a]="\n"+s[a],o=l)}n[i]=s.join("")}return n.join("\n")}},"undefined"!=typeof module&&module.exports&&(module.exports=n),Prism.plugins.NormalizeWhitespace=new n({"remove-trailing":!0,"remove-indent":!0,"left-trim":!0,"right-trim":!0}),Prism.hooks.add("before-sanity-check",(function(e){var n=Prism.plugins.NormalizeWhitespace;if((!e.settings||!1!==e.settings["whitespace-normalization"])&&Prism.util.isActive(e.element,"whitespace-normalization",!0))if(e.element&&e.element.parentNode||!e.code){var i=e.element.parentNode;if(e.code&&i&&"pre"===i.nodeName.toLowerCase()){for(var r in null==e.settings&&(e.settings={}),t)if(Object.hasOwnProperty.call(t,r)){var s=t[r];if(i.hasAttribute("data-"+r))try{var o=JSON.parse(i.getAttribute("data-"+r)||"true");typeof o===s&&(e.settings[r]=o)}catch(e){}}for(var a=i.childNodes,l="",c="",h=!1,d=0;d<a.length;++d){var p=a[d];p==e.element?h=!0:"#text"===p.nodeName&&(h?c+=p.nodeValue:l+=p.nodeValue,i.removeChild(p),--d)}if(e.element.children.length&&Prism.plugins.KeepMarkup){var u=l+e.element.innerHTML+c;e.element.innerHTML=n.normalize(u,e.settings),e.code=e.element.textContent}else e.code=l+e.code+c,e.code=n.normalize(e.code,e.settings)}}else e.code=n.normalize(e.code,e.settings)}))}function n(t){this.defaults=e({},t)}function i(e){return e.replace(/-(\w)/g,(function(e,t){return t.toUpperCase()}))}function r(e){for(var t=0,n=0;n<e.length;++n)e.charCodeAt(n)=="\t".charCodeAt(0)&&(t+=3);return e.length+t}}(),function(){if("undefined"!=typeof Prism&&"undefined"!=typeof document){var e="line-numbers",t=/\n(?!$)/g,n=Prism.plugins.lineNumbers={getLine:function(t,n){if("PRE"===t.tagName&&t.classList.contains(e)){var i=t.querySelector(".line-numbers-rows");if(i){var r=parseInt(t.getAttribute("data-start"),10)||1,s=r+(i.children.length-1);n<r&&(n=r),n>s&&(n=s);var o=n-r;return i.children[o]}}},resize:function(e){r([e])},assumeViewportIndependence:!0},i=void 0;window.addEventListener("resize",(function(){n.assumeViewportIndependence&&i===window.innerWidth||(i=window.innerWidth,r(Array.prototype.slice.call(document.querySelectorAll("pre."+e))))})),Prism.hooks.add("complete",(function(n){if(n.code){var i=n.element,s=i.parentNode;if(s&&/pre/i.test(s.nodeName)&&!i.querySelector(".line-numbers-rows")&&Prism.util.isActive(i,e)){i.classList.remove(e),s.classList.add(e);var o,a=n.code.match(t),l=a?a.length+1:1,c=new Array(l+1).join("<span></span>");(o=document.createElement("span")).setAttribute("aria-hidden","true"),o.className="line-numbers-rows",o.innerHTML=c,s.hasAttribute("data-start")&&(s.style.counterReset="linenumber "+(parseInt(s.getAttribute("data-start"),10)-1)),n.element.appendChild(o),r([s]),Prism.hooks.run("line-numbers",n)}}})),Prism.hooks.add("line-numbers",(function(e){e.plugins=e.plugins||{},e.plugins.lineNumbers=!0}))}function r(e){if(0!=(e=e.filter((function(e){var t=s(e)["white-space"];return"pre-wrap"===t||"pre-line"===t}))).length){var n=e.map((function(e){var n=e.querySelector("code"),i=e.querySelector(".line-numbers-rows");if(n&&i){var r=e.querySelector(".line-numbers-sizer"),s=n.textContent.split(t);r||((r=document.createElement("span")).className="line-numbers-sizer",n.appendChild(r)),r.innerHTML="0",r.style.display="block";var o=r.getBoundingClientRect().height;return r.innerHTML="",{element:e,lines:s,lineHeights:[],oneLinerHeight:o,sizer:r}}})).filter(Boolean);n.forEach((function(e){var t=e.sizer,n=e.lines,i=e.lineHeights,r=e.oneLinerHeight;i[n.length-1]=void 0,n.forEach((function(e,n){if(e&&e.length>1){var s=t.appendChild(document.createElement("span"));s.style.display="block",s.textContent=e}else i[n]=r}))})),n.forEach((function(e){for(var t=e.sizer,n=e.lineHeights,i=0,r=0;r<n.length;r++)void 0===n[r]&&(n[r]=t.children[i++].getBoundingClientRect().height)})),n.forEach((function(e){var t=e.sizer,n=e.element.querySelector(".line-numbers-rows");t.style.display="none",t.innerHTML="",e.lineHeights.forEach((function(e,t){n.children[t].style.height=e+"px"}))}))}}function s(e){return e?window.getComputedStyle?getComputedStyle(e):e.currentStyle||null:null}}(),window.TeiPublisher||(window.TeiPublisher={},TeiPublisher.url=new URL(window.location.href));const lc=new Map;function cc(e,t){lc.has(e)?t(lc.get(e)):document.addEventListener(e,n=>{lc.set(e,n.detail),t(n.detail)},{once:!0})}!function(){if("undefined"!=typeof document&&!("adoptedStyleSheets"in document)){var e="ShadyCSS"in window&&!ShadyCSS.nativeShadow,t=document.implementation.createHTMLDocument(""),n=new WeakMap,i="object"==typeof DOMException?Error:DOMException,r=Object.defineProperty,s=Array.prototype.forEach,o=/@import.+?;?$/gm,a=["addRule","deleteRule","insertRule","removeRule"],l=CSSStyleSheet.prototype;l.replace=function(){return Promise.reject(new i("Can't call replace on non-constructed CSSStyleSheets."))},l.replaceSync=function(){throw new i("Failed to execute 'replaceSync' on 'CSSStyleSheet': Can't call replaceSync on non-constructed CSSStyleSheets.")};var c=new WeakMap,h=new WeakMap,d=new WeakMap,p=new WeakMap,u=D.prototype;u.replace=function(e){try{return this.replaceSync(e),Promise.resolve(this)}catch(e){return Promise.reject(e)}},u.replaceSync=function(e){if(I(this),"string"==typeof e){var t=this;c.get(t).textContent=x(e),p.set(t,[]),h.get(t).forEach((function(e){e.isConnected()&&z(t,N(t,e))}))}},r(u,"cssRules",{configurable:!0,enumerable:!0,get:function(){return I(this),c.get(this).sheet.cssRules}}),r(u,"media",{configurable:!0,enumerable:!0,get:function(){return I(this),c.get(this).sheet.media}}),a.forEach((function(e){u[e]=function(){var t=this;I(t);var n=arguments;p.get(t).push({method:e,args:n}),h.get(t).forEach((function(i){if(i.isConnected()){var r=N(t,i).sheet;r[e].apply(r,n)}}));var i=c.get(t).sheet;return i[e].apply(i,n)}})),r(D,Symbol.hasInstance,{configurable:!0,value:T});var f={childList:!0,subtree:!0},m=new WeakMap,g=new WeakMap,_=new WeakMap,y=new WeakMap;if(j.prototype={isConnected:function(){var e=g.get(this);return e instanceof Document?"loading"!==e.readyState:k(e.host)},connect:function(){var e=H(this);y.get(this).observe(e,f),_.get(this).length>0&&$(this),F(e,(function(e){M(e).connect()}))},disconnect:function(){y.get(this).disconnect()},update:function(e){var t=this,n=g.get(t)===document?"Document":"ShadowRoot";if(!Array.isArray(e))throw new TypeError("Failed to set the 'adoptedStyleSheets' property on "+n+": Iterator getter is not callable.");if(!e.every(T))throw new TypeError("Failed to set the 'adoptedStyleSheets' property on "+n+": Failed to convert value to 'CSSStyleSheet'");if(e.some(E))throw new TypeError("Failed to set the 'adoptedStyleSheets' property on "+n+": Can't adopt non-constructed stylesheets");t.sheets=e;var i=_.get(t),r=S(e);C(i,r).forEach((function(e){A(N(e,t)),R(e,t)})),_.set(t,r),t.isConnected()&&r.length>0&&$(t)}},window.CSSStyleSheet=D,L(Document),"ShadowRoot"in window){L(ShadowRoot);var b=Element.prototype,v=b.attachShadow;b.attachShadow=function(e){var t=v.call(this,e);return"closed"===e.mode&&n.set(this,t),t}}var w=M(document);w.isConnected()?w.connect():document.addEventListener("DOMContentLoaded",w.connect.bind(w))}function x(e){var t=e.replace(o,"");return t!==e&&console.warn("@import rules are not allowed here. See https://github.com/WICG/construct-stylesheets/issues/119#issuecomment-588352418"),t.trim()}function k(e){return"isConnected"in e?e.isConnected:document.contains(e)}function S(e){return e.filter((function(t,n){return e.indexOf(t)===n}))}function C(e,t){return e.filter((function(e){return-1===t.indexOf(e)}))}function A(e){e.parentNode.removeChild(e)}function P(e){return e.shadowRoot||n.get(e)}function T(e){return"object"==typeof e&&(u.isPrototypeOf(e)||l.isPrototypeOf(e))}function E(e){return"object"==typeof e&&l.isPrototypeOf(e)}function O(e,t){var n=document.createElement("style");return d.get(e).set(t,n),h.get(e).push(t),n}function N(e,t){return d.get(e).get(t)}function R(e,t){d.get(e).delete(t),h.set(e,h.get(e).filter((function(e){return e!==t})))}function z(e,t){requestAnimationFrame((function(){t.textContent=c.get(e).textContent,p.get(e).forEach((function(e){return t.sheet[e.method].apply(t.sheet,e.args)}))}))}function I(e){if(!c.has(e))throw new TypeError("Illegal invocation")}function D(){var e=this,n=document.createElement("style");t.body.appendChild(n),c.set(e,n),h.set(e,[]),d.set(e,new WeakMap),p.set(e,[])}function M(e){var t=m.get(e);return t||(t=new j(e),m.set(e,t)),t}function L(e){r(e.prototype,"adoptedStyleSheets",{configurable:!0,enumerable:!0,get:function(){return M(this).sheets},set:function(e){M(this).update(e)}})}function F(e,t){for(var n=document.createNodeIterator(e,NodeFilter.SHOW_ELEMENT,(function(e){return P(e)?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_REJECT}),null,!1),i=void 0;i=n.nextNode();)t(P(i))}function B(e,t){return t instanceof HTMLStyleElement&&_.get(e).some((function(t){return N(t,e)}))}function H(e){var t=g.get(e);return t instanceof Document?t.body:t}function $(e){var t=document.createDocumentFragment(),n=_.get(e),i=y.get(e),r=H(e);i.disconnect(),n.forEach((function(n){t.appendChild(N(n,e)||O(n,e))})),r.insertBefore(t,null),i.observe(r,f),n.forEach((function(t){z(t,N(t,e))}))}function j(t){var n=this;n.sheets=[],g.set(n,t),_.set(n,[]),y.set(n,new MutationObserver((function(t,i){document?t.forEach((function(t){e||s.call(t.addedNodes,(function(e){e instanceof Element&&F(e,(function(e){M(e).connect()}))})),s.call(t.removedNodes,(function(t){t instanceof Element&&(B(n,t)&&$(n),e||F(t,(function(e){M(e).disconnect()})))}))})):i.disconnect()})))}}();const hc=new Map;function dc(e){const t=document.querySelector("pb-page");if(!t)return null;const n=t.stylesheet;if(!n)return null;const i=uc(e).join("|");if(hc.has(i))return hc.get(i);const r=new RegExp(`^(${i})\\b`);let s=null;const o=pc(n.cssRules,r,[]);return o.length>0&&(s=new CSSStyleSheet,s.replaceSync(o.join(""))),console.log("<theming> caching stylesheet for %s",i),hc.set(i,s),s}function pc(e,t,n){for(let i=0;i<e.length;i++){const r=e[i];if(r instanceof CSSStyleRule){if(t.test(r.selectorText)){const e=r.cssText.replace(t,":host($1) ");n.push(e)}}else r instanceof CSSMediaRule?(n.push(`\n@media ${r.conditionText} {\n`),pc(r.cssRules,t,n),n.push("\n}\n")):r instanceof CSSFontFaceRule||n.push(r.cssText)}return n}function uc(e){const t=[e.localName];return e.id&&t.push("#"+e.id),e.classList.forEach(e=>t.push("."+e)),t}const fc=e=>class extends e{connectedCallback(){super.connectedCallback(),cc("pb-page-ready",e=>{const t=dc(this);t&&(this.shadowRoot.adoptedStyleSheets=[...this.shadowRoot.adoptedStyleSheets,t])})}},mc=new Map;function gc(e){const t="default"===e?"prism.css":`prism-${e}.css`;if(mc.has(t))return console.log("Using cached theme: %s",t),mc.get(t);const n=new Promise(n=>{const i=oc("../css/prismjs/")+t;console.log("<pb-code-highlight> loading theme %s from %s",e,i),fetch(i).then(e=>e.text()).catch(()=>n("")).then(e=>{n(j`<style>${e}</style>`)})});return mc.set(t,n),n}class _c extends(fc(ue)){static get properties(){return{language:{type:String},code:{type:String},theme:{type:String},lineNumbers:{type:Boolean,attribute:"line-numbers"},_themeStyles:{type:String}}}constructor(){super(),this.language="xml",this.theme="default",this.lineNumbers=!1,this._themeStyles=null}connectedCallback(){super.connectedCallback();let e=this.getAttribute("theme");null===e&&(e=ac(this,"--pb-code-highlight-theme","default"),this.setAttribute("theme",e))}firstUpdated(){if(super.firstUpdated(),!this.code){const e=this.querySelector("template");this.code=e?Prism.plugins.NormalizeWhitespace.normalize(e.innerHTML):Prism.plugins.NormalizeWhitespace.normalize(this.textContent)}}attributeChangedCallback(e,t,n){switch(super.attributeChangedCallback(e,t,n),e){case"theme":gc(n).then(e=>{this._themeStyles=e})}}updated(e){if(super.updated(e),e.has("code")){const e=this.shadowRoot.getElementById("pb-code-highlight");if(null!=e){const t=document.createElement("code");t.textContent=this.code,e.replaceChildren(t)}this.highlight()}}highlight(){Prism.highlightAllUnder(this.shadowRoot)}render(){return this.code?j`
|
|
3105
|
-
|
|
3106
|
-
|
|
3107
|
-
|
|
3108
|
-
|
|
3109
|
-
|
|
3110
|
-
|
|
3111
|
-
|
|
3112
|
-
|
|
3113
|
-
|
|
3114
|
-
|
|
3115
|
-
|
|
3116
|
-
|
|
3117
|
-
|
|
3118
|
-
|
|
3119
|
-
|
|
3120
|
-
|
|
3121
|
-
|
|
3104
|
+
*/function oc(e){const t=document.querySelector("script[src*=pb-components]");return t?new URL(e,t.src).href:new URL(e,window.location.href).href}function ac(e,t,n){const i=getComputedStyle(e).getPropertyValue(t);if(i)try{return JSON.parse(i)}catch(e){return n}return n}"undefined"!=typeof module&&module.exports&&(module.exports=sc),"undefined"!=typeof global&&(global.Prism=sc),sc.languages.markup={comment:{pattern:/<!--(?:(?!<!--)[\s\S])*?-->/,greedy:!0},prolog:{pattern:/<\?[\s\S]+?\?>/,greedy:!0},doctype:{pattern:/<!DOCTYPE(?:[^>"'[\]]|"[^"]*"|'[^']*')+(?:\[(?:[^<"'\]]|"[^"]*"|'[^']*'|<(?!!--)|<!--(?:[^-]|-(?!->))*-->)*\]\s*)?>/i,greedy:!0,inside:{"internal-subset":{pattern:/(^[^\[]*\[)[\s\S]+(?=\]>$)/,lookbehind:!0,greedy:!0,inside:null},string:{pattern:/"[^"]*"|'[^']*'/,greedy:!0},punctuation:/^<!|>$|[[\]]/,"doctype-tag":/^DOCTYPE/i,name:/[^\s<>'"]+/}},cdata:{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,greedy:!0},tag:{pattern:/<\/?(?!\d)[^\s>\/=$<%]+(?:\s(?:\s*[^\s>\/=]+(?:\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))|(?=[\s/>])))+)?\s*\/?>/,greedy:!0,inside:{tag:{pattern:/^<\/?[^\s>\/]+/,inside:{punctuation:/^<\/?/,namespace:/^[^\s>\/:]+:/}},"special-attr":[],"attr-value":{pattern:/=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+)/,inside:{punctuation:[{pattern:/^=/,alias:"attr-equals"},{pattern:/^(\s*)["']|["']$/,lookbehind:!0}]}},punctuation:/\/?>/,"attr-name":{pattern:/[^\s>\/]+/,inside:{namespace:/^[^\s>\/:]+:/}}}},entity:[{pattern:/&[\da-z]{1,8};/i,alias:"named-entity"},/&#x?[\da-f]{1,8};/i]},sc.languages.markup.tag.inside["attr-value"].inside.entity=sc.languages.markup.entity,sc.languages.markup.doctype.inside["internal-subset"].inside=sc.languages.markup,sc.hooks.add("wrap",(function(e){"entity"===e.type&&(e.attributes.title=e.content.replace(/&/,"&"))})),Object.defineProperty(sc.languages.markup.tag,"addInlined",{value:function(e,t){var n={};n["language-"+t]={pattern:/(^<!\[CDATA\[)[\s\S]+?(?=\]\]>$)/i,lookbehind:!0,inside:sc.languages[t]},n.cdata=/^<!\[CDATA\[|\]\]>$/i;var i={"included-cdata":{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,inside:n}};i["language-"+t]={pattern:/[\s\S]+/,inside:sc.languages[t]};var r={};r[e]={pattern:RegExp(/(<__[^>]*>)(?:<!\[CDATA\[(?:[^\]]|\](?!\]>))*\]\]>|(?!<!\[CDATA\[)[\s\S])*?(?=<\/__>)/.source.replace(/__/g,(function(){return e})),"i"),lookbehind:!0,greedy:!0,inside:i},sc.languages.insertBefore("markup","cdata",r)}}),Object.defineProperty(sc.languages.markup.tag,"addAttribute",{value:function(e,t){sc.languages.markup.tag.inside["special-attr"].push({pattern:RegExp(/(^|["'\s])/.source+"(?:"+e+")"+/\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))/.source,"i"),lookbehind:!0,inside:{"attr-name":/^[^\s=]+/,"attr-value":{pattern:/=[\s\S]+/,inside:{value:{pattern:/(^=\s*(["']|(?!["'])))\S[\s\S]*(?=\2$)/,lookbehind:!0,alias:[t,"language-"+t],inside:sc.languages[t]},punctuation:[{pattern:/^=/,alias:"attr-equals"},/"|'/]}}}})}}),sc.languages.html=sc.languages.markup,sc.languages.mathml=sc.languages.markup,sc.languages.svg=sc.languages.markup,sc.languages.xml=sc.languages.extend("markup",{}),sc.languages.ssml=sc.languages.xml,sc.languages.atom=sc.languages.xml,sc.languages.rss=sc.languages.xml,function(e){var t=/(?:"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n])*')/;e.languages.css={comment:/\/\*[\s\S]*?\*\//,atrule:{pattern:RegExp("@[\\w-](?:"+/[^;{\s"']|\s+(?!\s)/.source+"|"+t.source+")*?"+/(?:;|(?=\s*\{))/.source),inside:{rule:/^@[\w-]+/,"selector-function-argument":{pattern:/(\bselector\s*\(\s*(?![\s)]))(?:[^()\s]|\s+(?![\s)])|\((?:[^()]|\([^()]*\))*\))+(?=\s*\))/,lookbehind:!0,alias:"selector"},keyword:{pattern:/(^|[^\w-])(?:and|not|only|or)(?![\w-])/,lookbehind:!0}}},url:{pattern:RegExp("\\burl\\((?:"+t.source+"|"+/(?:[^\\\r\n()"']|\\[\s\S])*/.source+")\\)","i"),greedy:!0,inside:{function:/^url/i,punctuation:/^\(|\)$/,string:{pattern:RegExp("^"+t.source+"$"),alias:"url"}}},selector:{pattern:RegExp("(^|[{}\\s])[^{}\\s](?:[^{};\"'\\s]|\\s+(?![\\s{])|"+t.source+")*(?=\\s*\\{)"),lookbehind:!0},string:{pattern:t,greedy:!0},property:{pattern:/(^|[^-\w\xA0-\uFFFF])(?!\s)[-_a-z\xA0-\uFFFF](?:(?!\s)[-\w\xA0-\uFFFF])*(?=\s*:)/i,lookbehind:!0},important:/!important\b/i,function:{pattern:/(^|[^-a-z0-9])[-a-z0-9]+(?=\()/i,lookbehind:!0},punctuation:/[(){};:,]/},e.languages.css.atrule.inside.rest=e.languages.css;var n=e.languages.markup;n&&(n.tag.addInlined("style","css"),n.tag.addAttribute("style","css"))}(sc),sc.languages.clike={comment:[{pattern:/(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0},"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|trait)\s+|\bcatch\s+\()[\w.\\]+/i,lookbehind:!0,inside:{punctuation:/[.\\]/}},keyword:/\b(?:break|catch|continue|do|else|finally|for|function|if|in|instanceof|new|null|return|throw|try|while)\b/,boolean:/\b(?:false|true)\b/,function:/\b\w+(?=\()/,number:/\b0x[\da-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?/i,operator:/[<>]=?|[!=]=?=?|--?|\+\+?|&&?|\|\|?|[?*/~^%]/,punctuation:/[{}[\];(),.:]/},sc.languages.javascript=sc.languages.extend("clike",{"class-name":[sc.languages.clike["class-name"],{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$A-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\.(?:constructor|prototype))/,lookbehind:!0}],keyword:[{pattern:/((?:^|\})\s*)catch\b/,lookbehind:!0},{pattern:/(^|[^.]|\.\.\.\s*)\b(?:as|assert(?=\s*\{)|async(?=\s*(?:function\b|\(|[$\w\xA0-\uFFFF]|$))|await|break|case|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally(?=\s*(?:\{|$))|for|from(?=\s*(?:['"]|$))|function|(?:get|set)(?=\s*(?:[#\[$\w\xA0-\uFFFF]|$))|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)\b/,lookbehind:!0}],function:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*(?:\.\s*(?:apply|bind|call)\s*)?\()/,number:{pattern:RegExp(/(^|[^\w$])/.source+"(?:"+/NaN|Infinity/.source+"|"+/0[bB][01]+(?:_[01]+)*n?/.source+"|"+/0[oO][0-7]+(?:_[0-7]+)*n?/.source+"|"+/0[xX][\dA-Fa-f]+(?:_[\dA-Fa-f]+)*n?/.source+"|"+/\d+(?:_\d+)*n/.source+"|"+/(?:\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\.\d+(?:_\d+)*)(?:[Ee][+-]?\d+(?:_\d+)*)?/.source+")"+/(?![\w$])/.source),lookbehind:!0},operator:/--|\+\+|\*\*=?|=>|&&=?|\|\|=?|[!=]==|<<=?|>>>?=?|[-+*/%&|^!=<>]=?|\.{3}|\?\?=?|\?\.?|[~:]/}),sc.languages.javascript["class-name"][0].pattern=/(\b(?:class|extends|implements|instanceof|interface|new)\s+)[\w.\\]+/,sc.languages.insertBefore("javascript","keyword",{regex:{pattern:RegExp(/((?:^|[^$\w\xA0-\uFFFF."'\])\s]|\b(?:return|yield))\s*)/.source+/\//.source+"(?:"+/(?:\[(?:[^\]\\\r\n]|\\.)*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}/.source+"|"+/(?:\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.)*\])*\])*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}v[dgimyus]{0,7}/.source+")"+/(?=(?:\s|\/\*(?:[^*]|\*(?!\/))*\*\/)*(?:$|[\r\n,.;:})\]]|\/\/))/.source),lookbehind:!0,greedy:!0,inside:{"regex-source":{pattern:/^(\/)[\s\S]+(?=\/[a-z]*$)/,lookbehind:!0,alias:"language-regex",inside:sc.languages.regex},"regex-delimiter":/^\/|\/$/,"regex-flags":/^[a-z]+$/}},"function-variable":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*[=:]\s*(?:async\s*)?(?:\bfunction\b|(?:\((?:[^()]|\([^()]*\))*\)|(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/,alias:"function"},parameter:[{pattern:/(function(?:\s+(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)?\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\))/,lookbehind:!0,inside:sc.languages.javascript},{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=>)/i,lookbehind:!0,inside:sc.languages.javascript},{pattern:/(\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*=>)/,lookbehind:!0,inside:sc.languages.javascript},{pattern:/((?:\b|\s|^)(?!(?:as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)(?![$\w\xA0-\uFFFF]))(?:(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*)\(\s*|\]\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*\{)/,lookbehind:!0,inside:sc.languages.javascript}],constant:/\b[A-Z](?:[A-Z_]|\dx?)*\b/}),sc.languages.insertBefore("javascript","string",{hashbang:{pattern:/^#!.*/,greedy:!0,alias:"comment"},"template-string":{pattern:/`(?:\\[\s\S]|\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}|(?!\$\{)[^\\`])*`/,greedy:!0,inside:{"template-punctuation":{pattern:/^`|`$/,alias:"string"},interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,lookbehind:!0,inside:{"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:"punctuation"},rest:sc.languages.javascript}},string:/[\s\S]+/}},"string-property":{pattern:/((?:^|[,{])[ \t]*)(["'])(?:\\(?:\r\n|[\s\S])|(?!\2)[^\\\r\n])*\2(?=\s*:)/m,lookbehind:!0,greedy:!0,alias:"property"}}),sc.languages.insertBefore("javascript","operator",{"literal-property":{pattern:/((?:^|[,{])[ \t]*)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*:)/m,lookbehind:!0,alias:"property"}}),sc.languages.markup&&(sc.languages.markup.tag.addInlined("script","javascript"),sc.languages.markup.tag.addAttribute(/on(?:abort|blur|change|click|composition(?:end|start|update)|dblclick|error|focus(?:in|out)?|key(?:down|up)|load|mouse(?:down|enter|leave|move|out|over|up)|reset|resize|scroll|select|slotchange|submit|unload|wheel)/.source,"javascript")),sc.languages.js=sc.languages.javascript,function(){if(void 0!==sc&&"undefined"!=typeof document){Element.prototype.matches||(Element.prototype.matches=Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector);var e="Loading…",t=function(e,t){return"✖ Error "+e+" while fetching file: "+t},n="✖ Error: File does not exist or is empty",i={js:"javascript",py:"python",rb:"ruby",ps1:"powershell",psm1:"powershell",sh:"bash",bat:"batch",h:"c",tex:"latex"},r="data-src-status",s="loading",o="loaded",a="failed",l="pre[data-src]:not(["+r+'="'+o+'"]):not(['+r+'="'+s+'"])';sc.hooks.add("before-highlightall",(function(e){e.selector+=", "+l})),sc.hooks.add("before-sanity-check",(function(t){var n=t.element;if(n.matches(l)){t.code="",n.setAttribute(r,s);var c=n.appendChild(document.createElement("CODE"));c.textContent=e;var p=n.getAttribute("data-src"),u=t.language;if("none"===u){var f=(/\.(\w+)$/.exec(p)||[,"none"])[1];u=i[f]||f}sc.util.setLanguage(c,u),sc.util.setLanguage(n,u);var m=sc.plugins.autoloader;m&&m.loadLanguages(u),h(p,(function(e){n.setAttribute(r,o);var t=d(n.getAttribute("data-range"));if(t){var i=e.split(/\r\n?|\n/g),s=t[0],a=null==t[1]?i.length:t[1];s<0&&(s+=i.length),s=Math.max(0,Math.min(s-1,i.length)),a<0&&(a+=i.length),a=Math.max(0,Math.min(a,i.length)),e=i.slice(s,a).join("\n"),n.hasAttribute("data-start")||n.setAttribute("data-start",String(s+1))}c.textContent=e,sc.highlightElement(c)}),(function(e){n.setAttribute(r,a),c.textContent=e}))}})),sc.plugins.fileHighlight={highlight:function(e){for(var t,n=(e||document).querySelectorAll(l),i=0;t=n[i++];)sc.highlightElement(t)}};var c=!1;sc.fileHighlight=function(){c||(console.warn("Prism.fileHighlight is deprecated. Use `Prism.plugins.fileHighlight.highlight` instead."),c=!0),sc.plugins.fileHighlight.highlight.apply(this,arguments)}}function h(e,i,r){var s=new XMLHttpRequest;s.open("GET",e,!0),s.onreadystatechange=function(){4==s.readyState&&(s.status<400&&s.responseText?i(s.responseText):s.status>=400?r(t(s.status,s.statusText)):r(n))},s.send(null)}function d(e){var t=/^\s*(\d+)\s*(?:(,)\s*(?:(\d+)\s*)?)?$/.exec(e||"");if(t){var n=Number(t[1]),i=t[2],r=t[3];return i?r?[n,Number(r)]:[n,void 0]:[n,n]}}}(),function(e){e.languages.xquery=e.languages.extend("markup",{"xquery-comment":{pattern:/\(:[\s\S]*?:\)/,greedy:!0,alias:"comment"},string:{pattern:/(["'])(?:\1\1|(?!\1)[\s\S])*\1/,greedy:!0},extension:{pattern:/\(#.+?#\)/,alias:"symbol"},variable:/\$[-\w:]+/,axis:{pattern:/(^|[^-])(?:ancestor(?:-or-self)?|attribute|child|descendant(?:-or-self)?|following(?:-sibling)?|parent|preceding(?:-sibling)?|self)(?=::)/,lookbehind:!0,alias:"operator"},"keyword-operator":{pattern:/(^|[^:-])\b(?:and|castable as|div|eq|except|ge|gt|idiv|instance of|intersect|is|le|lt|mod|ne|or|union)\b(?=$|[^:-])/,lookbehind:!0,alias:"operator"},keyword:{pattern:/(^|[^:-])\b(?:as|ascending|at|base-uri|boundary-space|case|cast as|collation|construction|copy-namespaces|declare|default|descending|else|empty (?:greatest|least)|encoding|every|external|for|function|if|import|in|inherit|lax|let|map|module|namespace|no-inherit|no-preserve|option|order(?: by|ed|ing)?|preserve|return|satisfies|schema|some|stable|strict|strip|then|to|treat as|typeswitch|unordered|validate|variable|version|where|xquery)\b(?=$|[^:-])/,lookbehind:!0},function:/[\w-]+(?::[\w-]+)*(?=\s*\()/,"xquery-element":{pattern:/(element\s+)[\w-]+(?::[\w-]+)*/,lookbehind:!0,alias:"tag"},"xquery-attribute":{pattern:/(attribute\s+)[\w-]+(?::[\w-]+)*/,lookbehind:!0,alias:"attr-name"},builtin:{pattern:/(^|[^:-])\b(?:attribute|comment|document|element|processing-instruction|text|xs:(?:ENTITIES|ENTITY|ID|IDREFS?|NCName|NMTOKENS?|NOTATION|Name|QName|anyAtomicType|anyType|anyURI|base64Binary|boolean|byte|date|dateTime|dayTimeDuration|decimal|double|duration|float|gDay|gMonth|gMonthDay|gYear|gYearMonth|hexBinary|int|integer|language|long|negativeInteger|nonNegativeInteger|nonPositiveInteger|normalizedString|positiveInteger|short|string|time|token|unsigned(?:Byte|Int|Long|Short)|untyped(?:Atomic)?|yearMonthDuration))\b(?=$|[^:-])/,lookbehind:!0},number:/\b\d+(?:\.\d+)?(?:E[+-]?\d+)?/,operator:[/[+*=?|@]|\.\.?|:=|!=|<[=<]?|>[=>]?/,{pattern:/(\s)-(?=\s)/,lookbehind:!0}],punctuation:/[[\](){},;:/]/}),e.languages.xquery.tag.pattern=/<\/?(?!\d)[^\s>\/=$<%]+(?:\s+[^\s>\/=]+(?:=(?:("|')(?:\\[\s\S]|\{(?!\{)(?:\{(?:\{[^{}]*\}|[^{}])*\}|[^{}])+\}|(?!\1)[^\\])*\1|[^\s'">=]+))?)*\s*\/?>/,e.languages.xquery.tag.inside["attr-value"].pattern=/=(?:("|')(?:\\[\s\S]|\{(?!\{)(?:\{(?:\{[^{}]*\}|[^{}])*\}|[^{}])+\}|(?!\1)[^\\])*\1|[^\s'">=]+)/,e.languages.xquery.tag.inside["attr-value"].inside.punctuation=/^="|"$/,e.languages.xquery.tag.inside["attr-value"].inside.expression={pattern:/\{(?!\{)(?:\{(?:\{[^{}]*\}|[^{}])*\}|[^{}])+\}/,inside:e.languages.xquery,alias:"language-xquery"};var t=function(e){return"string"==typeof e?e:"string"==typeof e.content?e.content:e.content.map(t).join("")},n=function(i){for(var r=[],s=0;s<i.length;s++){var o=i[s],a=!1;if("string"!=typeof o&&("tag"===o.type&&o.content[0]&&"tag"===o.content[0].type?"</"===o.content[0].content[0].content?r.length>0&&r[r.length-1].tagName===t(o.content[0].content[1])&&r.pop():"/>"===o.content[o.content.length-1].content||r.push({tagName:t(o.content[0].content[1]),openedBraces:0}):!(r.length>0&&"punctuation"===o.type&&"{"===o.content)||i[s+1]&&"punctuation"===i[s+1].type&&"{"===i[s+1].content||i[s-1]&&"plain-text"===i[s-1].type&&"{"===i[s-1].content?r.length>0&&r[r.length-1].openedBraces>0&&"punctuation"===o.type&&"}"===o.content?r[r.length-1].openedBraces--:"comment"!==o.type&&(a=!0):r[r.length-1].openedBraces++),(a||"string"==typeof o)&&r.length>0&&0===r[r.length-1].openedBraces){var l=t(o);s<i.length-1&&("string"==typeof i[s+1]||"plain-text"===i[s+1].type)&&(l+=t(i[s+1]),i.splice(s+1,1)),s>0&&("string"==typeof i[s-1]||"plain-text"===i[s-1].type)&&(l=t(i[s-1])+l,i.splice(s-1,1),s--),/^\s+$/.test(l)?i[s]=l:i[s]=new e.Token("plain-text",l,null,l)}o.content&&"string"!=typeof o.content&&n(o.content)}};e.hooks.add("after-tokenize",(function(e){"xquery"===e.language&&n(e.tokens)}))}(Prism),function(){if("undefined"!=typeof Prism){var e=Object.assign||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n]);return e},t={"remove-trailing":"boolean","remove-indent":"boolean","left-trim":"boolean","right-trim":"boolean","break-lines":"number",indent:"number","remove-initial-line-feed":"boolean","tabs-to-spaces":"number","spaces-to-tabs":"number"};n.prototype={setDefaults:function(t){this.defaults=e(this.defaults,t)},normalize:function(t,n){for(var r in n=e(this.defaults,n)){var s=i(r);"normalize"!==r&&"setDefaults"!==s&&n[r]&&this[s]&&(t=this[s].call(this,t,n[r]))}return t},leftTrim:function(e){return e.replace(/^\s+/,"")},rightTrim:function(e){return e.replace(/\s+$/,"")},tabsToSpaces:function(e,t){return t=0|t||4,e.replace(/\t/g,new Array(++t).join(" "))},spacesToTabs:function(e,t){return t=0|t||4,e.replace(RegExp(" {"+t+"}","g"),"\t")},removeTrailing:function(e){return e.replace(/\s*?$/gm,"")},removeInitialLineFeed:function(e){return e.replace(/^(?:\r?\n|\r)/,"")},removeIndent:function(e){var t=e.match(/^[^\S\n\r]*(?=\S)/gm);return t&&t[0].length?(t.sort((function(e,t){return e.length-t.length})),t[0].length?e.replace(RegExp("^"+t[0],"gm"),""):e):e},indent:function(e,t){return e.replace(/^[^\S\n\r]*(?=\S)/gm,new Array(++t).join("\t")+"$&")},breakLines:function(e,t){t=!0===t?80:0|t||80;for(var n=e.split("\n"),i=0;i<n.length;++i)if(!(r(n[i])<=t)){for(var s=n[i].split(/(\s+)/g),o=0,a=0;a<s.length;++a){var l=r(s[a]);(o+=l)>t&&(s[a]="\n"+s[a],o=l)}n[i]=s.join("")}return n.join("\n")}},"undefined"!=typeof module&&module.exports&&(module.exports=n),Prism.plugins.NormalizeWhitespace=new n({"remove-trailing":!0,"remove-indent":!0,"left-trim":!0,"right-trim":!0}),Prism.hooks.add("before-sanity-check",(function(e){var n=Prism.plugins.NormalizeWhitespace;if((!e.settings||!1!==e.settings["whitespace-normalization"])&&Prism.util.isActive(e.element,"whitespace-normalization",!0))if(e.element&&e.element.parentNode||!e.code){var i=e.element.parentNode;if(e.code&&i&&"pre"===i.nodeName.toLowerCase()){for(var r in null==e.settings&&(e.settings={}),t)if(Object.hasOwnProperty.call(t,r)){var s=t[r];if(i.hasAttribute("data-"+r))try{var o=JSON.parse(i.getAttribute("data-"+r)||"true");typeof o===s&&(e.settings[r]=o)}catch(e){}}for(var a=i.childNodes,l="",c="",h=!1,d=0;d<a.length;++d){var p=a[d];p==e.element?h=!0:"#text"===p.nodeName&&(h?c+=p.nodeValue:l+=p.nodeValue,i.removeChild(p),--d)}if(e.element.children.length&&Prism.plugins.KeepMarkup){var u=l+e.element.innerHTML+c;e.element.innerHTML=n.normalize(u,e.settings),e.code=e.element.textContent}else e.code=l+e.code+c,e.code=n.normalize(e.code,e.settings)}}else e.code=n.normalize(e.code,e.settings)}))}function n(t){this.defaults=e({},t)}function i(e){return e.replace(/-(\w)/g,(function(e,t){return t.toUpperCase()}))}function r(e){for(var t=0,n=0;n<e.length;++n)e.charCodeAt(n)=="\t".charCodeAt(0)&&(t+=3);return e.length+t}}(),function(){if("undefined"!=typeof Prism&&"undefined"!=typeof document){var e="line-numbers",t=/\n(?!$)/g,n=Prism.plugins.lineNumbers={getLine:function(t,n){if("PRE"===t.tagName&&t.classList.contains(e)){var i=t.querySelector(".line-numbers-rows");if(i){var r=parseInt(t.getAttribute("data-start"),10)||1,s=r+(i.children.length-1);n<r&&(n=r),n>s&&(n=s);var o=n-r;return i.children[o]}}},resize:function(e){r([e])},assumeViewportIndependence:!0},i=void 0;window.addEventListener("resize",(function(){n.assumeViewportIndependence&&i===window.innerWidth||(i=window.innerWidth,r(Array.prototype.slice.call(document.querySelectorAll("pre."+e))))})),Prism.hooks.add("complete",(function(n){if(n.code){var i=n.element,s=i.parentNode;if(s&&/pre/i.test(s.nodeName)&&!i.querySelector(".line-numbers-rows")&&Prism.util.isActive(i,e)){i.classList.remove(e),s.classList.add(e);var o,a=n.code.match(t),l=a?a.length+1:1,c=new Array(l+1).join("<span></span>");(o=document.createElement("span")).setAttribute("aria-hidden","true"),o.className="line-numbers-rows",o.innerHTML=c,s.hasAttribute("data-start")&&(s.style.counterReset="linenumber "+(parseInt(s.getAttribute("data-start"),10)-1)),n.element.appendChild(o),r([s]),Prism.hooks.run("line-numbers",n)}}})),Prism.hooks.add("line-numbers",(function(e){e.plugins=e.plugins||{},e.plugins.lineNumbers=!0}))}function r(e){if(0!=(e=e.filter((function(e){var t=s(e)["white-space"];return"pre-wrap"===t||"pre-line"===t}))).length){var n=e.map((function(e){var n=e.querySelector("code"),i=e.querySelector(".line-numbers-rows");if(n&&i){var r=e.querySelector(".line-numbers-sizer"),s=n.textContent.split(t);r||((r=document.createElement("span")).className="line-numbers-sizer",n.appendChild(r)),r.innerHTML="0",r.style.display="block";var o=r.getBoundingClientRect().height;return r.innerHTML="",{element:e,lines:s,lineHeights:[],oneLinerHeight:o,sizer:r}}})).filter(Boolean);n.forEach((function(e){var t=e.sizer,n=e.lines,i=e.lineHeights,r=e.oneLinerHeight;i[n.length-1]=void 0,n.forEach((function(e,n){if(e&&e.length>1){var s=t.appendChild(document.createElement("span"));s.style.display="block",s.textContent=e}else i[n]=r}))})),n.forEach((function(e){for(var t=e.sizer,n=e.lineHeights,i=0,r=0;r<n.length;r++)void 0===n[r]&&(n[r]=t.children[i++].getBoundingClientRect().height)})),n.forEach((function(e){var t=e.sizer,n=e.element.querySelector(".line-numbers-rows");t.style.display="none",t.innerHTML="",e.lineHeights.forEach((function(e,t){n.children[t].style.height=e+"px"}))}))}}function s(e){return e?window.getComputedStyle?getComputedStyle(e):e.currentStyle||null:null}}(),window.TeiPublisher||(window.TeiPublisher={},TeiPublisher.url=new URL(window.location.href));const lc=new Map;function cc(e,t){lc.has(e)?t(lc.get(e)):document.addEventListener(e,n=>{lc.set(e,n.detail),t(n.detail)},{once:!0})}function hc(){const e=document.querySelector("pb-page");if(!e)return null;const t=e.stylesheet;return t||null}!function(){if("undefined"!=typeof document&&!("adoptedStyleSheets"in document)){var e="ShadyCSS"in window&&!ShadyCSS.nativeShadow,t=document.implementation.createHTMLDocument(""),n=new WeakMap,i="object"==typeof DOMException?Error:DOMException,r=Object.defineProperty,s=Array.prototype.forEach,o=/@import.+?;?$/gm,a=["addRule","deleteRule","insertRule","removeRule"],l=CSSStyleSheet.prototype;l.replace=function(){return Promise.reject(new i("Can't call replace on non-constructed CSSStyleSheets."))},l.replaceSync=function(){throw new i("Failed to execute 'replaceSync' on 'CSSStyleSheet': Can't call replaceSync on non-constructed CSSStyleSheets.")};var c=new WeakMap,h=new WeakMap,d=new WeakMap,p=new WeakMap,u=D.prototype;u.replace=function(e){try{return this.replaceSync(e),Promise.resolve(this)}catch(e){return Promise.reject(e)}},u.replaceSync=function(e){if(I(this),"string"==typeof e){var t=this;c.get(t).textContent=x(e),p.set(t,[]),h.get(t).forEach((function(e){e.isConnected()&&z(t,N(t,e))}))}},r(u,"cssRules",{configurable:!0,enumerable:!0,get:function(){return I(this),c.get(this).sheet.cssRules}}),r(u,"media",{configurable:!0,enumerable:!0,get:function(){return I(this),c.get(this).sheet.media}}),a.forEach((function(e){u[e]=function(){var t=this;I(t);var n=arguments;p.get(t).push({method:e,args:n}),h.get(t).forEach((function(i){if(i.isConnected()){var r=N(t,i).sheet;r[e].apply(r,n)}}));var i=c.get(t).sheet;return i[e].apply(i,n)}})),r(D,Symbol.hasInstance,{configurable:!0,value:T});var f={childList:!0,subtree:!0},m=new WeakMap,g=new WeakMap,_=new WeakMap,y=new WeakMap;if(j.prototype={isConnected:function(){var e=g.get(this);return e instanceof Document?"loading"!==e.readyState:k(e.host)},connect:function(){var e=H(this);y.get(this).observe(e,f),_.get(this).length>0&&$(this),F(e,(function(e){M(e).connect()}))},disconnect:function(){y.get(this).disconnect()},update:function(e){var t=this,n=g.get(t)===document?"Document":"ShadowRoot";if(!Array.isArray(e))throw new TypeError("Failed to set the 'adoptedStyleSheets' property on "+n+": Iterator getter is not callable.");if(!e.every(T))throw new TypeError("Failed to set the 'adoptedStyleSheets' property on "+n+": Failed to convert value to 'CSSStyleSheet'");if(e.some(E))throw new TypeError("Failed to set the 'adoptedStyleSheets' property on "+n+": Can't adopt non-constructed stylesheets");t.sheets=e;var i=_.get(t),r=S(e);C(i,r).forEach((function(e){A(N(e,t)),R(e,t)})),_.set(t,r),t.isConnected()&&r.length>0&&$(t)}},window.CSSStyleSheet=D,L(Document),"ShadowRoot"in window){L(ShadowRoot);var b=Element.prototype,v=b.attachShadow;b.attachShadow=function(e){var t=v.call(this,e);return"closed"===e.mode&&n.set(this,t),t}}var w=M(document);w.isConnected()?w.connect():document.addEventListener("DOMContentLoaded",w.connect.bind(w))}function x(e){var t=e.replace(o,"");return t!==e&&console.warn("@import rules are not allowed here. See https://github.com/WICG/construct-stylesheets/issues/119#issuecomment-588352418"),t.trim()}function k(e){return"isConnected"in e?e.isConnected:document.contains(e)}function S(e){return e.filter((function(t,n){return e.indexOf(t)===n}))}function C(e,t){return e.filter((function(e){return-1===t.indexOf(e)}))}function A(e){e.parentNode.removeChild(e)}function P(e){return e.shadowRoot||n.get(e)}function T(e){return"object"==typeof e&&(u.isPrototypeOf(e)||l.isPrototypeOf(e))}function E(e){return"object"==typeof e&&l.isPrototypeOf(e)}function O(e,t){var n=document.createElement("style");return d.get(e).set(t,n),h.get(e).push(t),n}function N(e,t){return d.get(e).get(t)}function R(e,t){d.get(e).delete(t),h.set(e,h.get(e).filter((function(e){return e!==t})))}function z(e,t){requestAnimationFrame((function(){t.textContent=c.get(e).textContent,p.get(e).forEach((function(e){return t.sheet[e.method].apply(t.sheet,e.args)}))}))}function I(e){if(!c.has(e))throw new TypeError("Illegal invocation")}function D(){var e=this,n=document.createElement("style");t.body.appendChild(n),c.set(e,n),h.set(e,[]),d.set(e,new WeakMap),p.set(e,[])}function M(e){var t=m.get(e);return t||(t=new j(e),m.set(e,t)),t}function L(e){r(e.prototype,"adoptedStyleSheets",{configurable:!0,enumerable:!0,get:function(){return M(this).sheets},set:function(e){M(this).update(e)}})}function F(e,t){for(var n=document.createNodeIterator(e,NodeFilter.SHOW_ELEMENT,(function(e){return P(e)?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_REJECT}),null,!1),i=void 0;i=n.nextNode();)t(P(i))}function B(e,t){return t instanceof HTMLStyleElement&&_.get(e).some((function(t){return N(t,e)}))}function H(e){var t=g.get(e);return t instanceof Document?t.body:t}function $(e){var t=document.createDocumentFragment(),n=_.get(e),i=y.get(e),r=H(e);i.disconnect(),n.forEach((function(n){t.appendChild(N(n,e)||O(n,e))})),r.insertBefore(t,null),i.observe(r,f),n.forEach((function(t){z(t,N(t,e))}))}function j(t){var n=this;n.sheets=[],g.set(n,t),_.set(n,[]),y.set(n,new MutationObserver((function(t,i){document?t.forEach((function(t){e||s.call(t.addedNodes,(function(e){e instanceof Element&&F(e,(function(e){M(e).connect()}))})),s.call(t.removedNodes,(function(t){t instanceof Element&&(B(n,t)&&$(n),e||F(t,(function(e){M(e).disconnect()})))}))})):i.disconnect()})))}}();const dc=e=>class extends e{connectedCallback(){super.connectedCallback(),cc("pb-page-ready",e=>{const t=hc();t&&(this.shadowRoot.adoptedStyleSheets=[...this.shadowRoot.adoptedStyleSheets,t])})}},pc=new Map;function uc(e){const t="default"===e?"prism.css":`prism-${e}.css`;if(pc.has(t))return console.log("Using cached theme: %s",t),pc.get(t);const n=new Promise(n=>{const i=oc("../css/prismjs/")+t;console.log("<pb-code-highlight> loading theme %s from %s",e,i),fetch(i).then(e=>e.text()).catch(()=>n("")).then(e=>{n(j`<style>
|
|
3105
|
+
${e}
|
|
3106
|
+
</style>`)})});return pc.set(t,n),n}class fc extends(dc(ue)){static get properties(){return{language:{type:String},code:{type:String},theme:{type:String},lineNumbers:{type:Boolean,attribute:"line-numbers"},_themeStyles:{type:String}}}constructor(){super(),this.language="xml",this.theme="default",this.lineNumbers=!1,this._themeStyles=null}connectedCallback(){super.connectedCallback();let e=this.getAttribute("theme");null===e&&(e=ac(this,"--pb-code-highlight-theme","default"),this.setAttribute("theme",e))}firstUpdated(){if(super.firstUpdated(),!this.code){const e=this.querySelector("template");this.code=e?Prism.plugins.NormalizeWhitespace.normalize(e.innerHTML):Prism.plugins.NormalizeWhitespace.normalize(this.textContent)}}attributeChangedCallback(e,t,n){switch(super.attributeChangedCallback(e,t,n),e){case"theme":uc(n).then(e=>{this._themeStyles=e})}}updated(e){if(super.updated(e),e.has("code")){const e=this.shadowRoot.getElementById("pb-code-highlight");if(null!=e){const t=document.createElement("code");t.textContent=this.code,e.replaceChildren(t)}this.highlight()}}highlight(){Prism.highlightAllUnder(this.shadowRoot)}render(){return this.code?j`
|
|
3107
|
+
${this._themeStyles}
|
|
3108
|
+
<pre
|
|
3109
|
+
id="pb-code-highlight"
|
|
3110
|
+
class="${this.lineNumbers?"line-numbers":""} language-${this.language}"
|
|
3111
|
+
><code>${this.code}</code></pre>
|
|
3112
|
+
`:j`<pre class="line-numbers"><code><code></pre>`}static get styles(){return de`
|
|
3113
|
+
:host {
|
|
3114
|
+
display: block;
|
|
3115
|
+
}
|
|
3116
|
+
pre[class*='language-'] {
|
|
3117
|
+
margin: 0;
|
|
3118
|
+
}
|
|
3119
|
+
code[class*='language-'] {
|
|
3120
|
+
white-space: var(--pb-code-highlight-white-space, pre);
|
|
3121
|
+
}
|
|
3122
|
+
pre.line-numbers {
|
|
3123
|
+
position: relative;
|
|
3124
|
+
padding-left: 3.8em;
|
|
3125
|
+
counter-reset: linenumber;
|
|
3126
|
+
}
|
|
3122
3127
|
|
|
3123
|
-
|
|
3124
|
-
|
|
3125
|
-
|
|
3126
|
-
|
|
3128
|
+
pre.line-numbers > code {
|
|
3129
|
+
position: relative;
|
|
3130
|
+
white-space: inherit;
|
|
3131
|
+
}
|
|
3127
3132
|
|
|
3128
|
-
|
|
3129
|
-
|
|
3130
|
-
|
|
3131
|
-
|
|
3132
|
-
|
|
3133
|
-
|
|
3134
|
-
|
|
3135
|
-
|
|
3136
|
-
|
|
3137
|
-
|
|
3138
|
-
-webkit-user-select: none;
|
|
3139
|
-
-moz-user-select: none;
|
|
3140
|
-
-ms-user-select: none;
|
|
3141
|
-
user-select: none;
|
|
3133
|
+
.line-numbers .line-numbers-rows {
|
|
3134
|
+
position: absolute;
|
|
3135
|
+
pointer-events: none;
|
|
3136
|
+
top: 0;
|
|
3137
|
+
font-size: 100%;
|
|
3138
|
+
left: -3.8em;
|
|
3139
|
+
width: 3em; /* works for line-numbers below 1000 lines */
|
|
3140
|
+
letter-spacing: -1px;
|
|
3141
|
+
border-right: 1px solid #999;
|
|
3142
3142
|
|
|
3143
|
-
|
|
3143
|
+
-webkit-user-select: none;
|
|
3144
|
+
-moz-user-select: none;
|
|
3145
|
+
-ms-user-select: none;
|
|
3146
|
+
user-select: none;
|
|
3147
|
+
}
|
|
3144
3148
|
|
|
3145
|
-
|
|
3146
|
-
|
|
3147
|
-
|
|
3148
|
-
|
|
3149
|
-
|
|
3150
|
-
|
|
3149
|
+
.line-numbers-rows > span {
|
|
3150
|
+
pointer-events: none;
|
|
3151
|
+
display: block;
|
|
3152
|
+
counter-increment: linenumber;
|
|
3153
|
+
height: auto !important;
|
|
3154
|
+
}
|
|
3151
3155
|
|
|
3152
|
-
|
|
3153
|
-
|
|
3154
|
-
|
|
3155
|
-
|
|
3156
|
-
|
|
3157
|
-
|
|
3158
|
-
|
|
3159
|
-
|
|
3156
|
+
.line-numbers-rows > span:before {
|
|
3157
|
+
content: counter(linenumber);
|
|
3158
|
+
color: #999;
|
|
3159
|
+
display: block;
|
|
3160
|
+
padding-right: 0.8em;
|
|
3161
|
+
text-align: right;
|
|
3162
|
+
}
|
|
3163
|
+
`}}customElements.define("pb-code-highlight",fc);const mc=new window.marked.Renderer;function gc(e){return e?j`${bl(window.marked(e))}`:null}function _c(e,t,n=!1){return t?j`
|
|
3160
3164
|
<section>
|
|
3161
3165
|
<h2>${e}</h2>
|
|
3162
3166
|
<table>
|
|
@@ -3170,12 +3174,12 @@ Mo({_template:ua`
|
|
|
3170
3174
|
<tbody>
|
|
3171
3175
|
${t.map(e=>j`<tr>
|
|
3172
3176
|
<td>${e.name}</td>
|
|
3173
|
-
<td>${
|
|
3177
|
+
<td>${gc(e.description)}</td>
|
|
3174
3178
|
${n?j`<td>${e.default}</td>`:null}</tr>`)}
|
|
3175
3179
|
</tbody>
|
|
3176
3180
|
</table>
|
|
3177
3181
|
</section>
|
|
3178
|
-
`:null}
|
|
3182
|
+
`:null}mc.code=function(e,t,n){return`<pb-code-highlight language="${t}" line-numbers>\n <template>${e}</template>\n </pb-code-highlight>`},window.marked.setOptions({renderer:mc});class yc extends ue{static get properties(){return{defaultTitle:{type:String,attribute:"default-title"},_target:{type:String,reflect:!0},_api:{type:String,reflect:!0},_component:{type:Object},_tab:{type:Number}}}constructor(){super(),this._tab=0,this._component=null,this.defaultTitle="Webcomponents API"}show(e,t=0){this._tab=t,this._component=e}clear(){this._component=null,this._tab=0}render(){return j`
|
|
3179
3183
|
<app-header-layout>
|
|
3180
3184
|
<app-header>
|
|
3181
3185
|
<app-toolbar>
|
|
@@ -3191,13 +3195,13 @@ Mo({_template:ua`
|
|
|
3191
3195
|
<div id="api">
|
|
3192
3196
|
${this._component?j`
|
|
3193
3197
|
<p class="description">
|
|
3194
|
-
${
|
|
3198
|
+
${gc(this._component.description)}
|
|
3195
3199
|
</p>
|
|
3196
|
-
${
|
|
3200
|
+
${_c("Slots",this._component.slots)}
|
|
3197
3201
|
${this._renderPropertiesSection()}
|
|
3198
|
-
${
|
|
3199
|
-
${
|
|
3200
|
-
${
|
|
3202
|
+
${_c("Events",this._component.events)}
|
|
3203
|
+
${_c("CSS Properties",this._component.cssProperties,!0)}
|
|
3204
|
+
${_c("CSS Parts",this._component.cssParts)}
|
|
3201
3205
|
`:null}
|
|
3202
3206
|
</div>`:j`<iframe id="iframe" class="${this._tab>0?"":"hidden"}" src="${this._getDemo()}"></iframe>`}
|
|
3203
3207
|
</main>
|
|
@@ -3222,7 +3226,7 @@ Mo({_template:ua`
|
|
|
3222
3226
|
</tr>
|
|
3223
3227
|
</tbody>
|
|
3224
3228
|
</table>
|
|
3225
|
-
${e.description?j`<p>${
|
|
3229
|
+
${e.description?j`<p>${gc(e.description)}</p>`:null}
|
|
3226
3230
|
</div>
|
|
3227
3231
|
`)}_getDemo(){if(0===this._tab)return null;const e=Object.keys(this._component.demo)[this._tab-1];return this._target?`${e}?_target=${this._target}&_api=${this._api}`:e}_showDemo(e){this._tab=e,this._pushState()}_showApi(){this._tab=0,this._pushState()}_pushState(){const e=`#${this._component.name}.${this._tab}`;history.pushState({component:this._component,tab:this._tab},"view component",e)}static get styles(){return de`
|
|
3228
3232
|
:host {
|
|
@@ -3243,7 +3247,7 @@ Mo({_template:ua`
|
|
|
3243
3247
|
}
|
|
3244
3248
|
|
|
3245
3249
|
h1, h2 {
|
|
3246
|
-
font-family: "Oswald",Verdana,"Helvetica", sans-serif;
|
|
3250
|
+
font-family: "Oswald",Verdana,"Helvetica", sans-serif;
|
|
3247
3251
|
font-weight: 400;
|
|
3248
3252
|
line-height: 1.2;
|
|
3249
3253
|
}
|
|
@@ -3274,7 +3278,7 @@ Mo({_template:ua`
|
|
|
3274
3278
|
margin-left: 10px;
|
|
3275
3279
|
margin-right: 20px;
|
|
3276
3280
|
}
|
|
3277
|
-
|
|
3281
|
+
|
|
3278
3282
|
iframe {
|
|
3279
3283
|
border: 0;
|
|
3280
3284
|
width: 100%;
|
|
@@ -3292,7 +3296,7 @@ Mo({_template:ua`
|
|
|
3292
3296
|
padding-bottom: 8px;
|
|
3293
3297
|
border-bottom: 1px solid #a0a0a0;
|
|
3294
3298
|
}
|
|
3295
|
-
|
|
3299
|
+
|
|
3296
3300
|
td {
|
|
3297
3301
|
padding: 8px 4px;
|
|
3298
3302
|
width: 25%;
|
|
@@ -3312,7 +3316,7 @@ Mo({_template:ua`
|
|
|
3312
3316
|
font-size: .85em;
|
|
3313
3317
|
text-align: left;
|
|
3314
3318
|
}
|
|
3315
|
-
`}}customElements.define("pb-component-view",
|
|
3319
|
+
`}}customElements.define("pb-component-view",yc);class bc extends ue{static get properties(){return{file:{type:String},demo:{type:String},_target:{type:String,reflect:!0},_api:{type:String,reflect:!0},_json:{type:Object},_demosOnly:{type:Boolean}}}constructor(){super(),this.file=null,this.demo=null,this._target=null,this.view=null}connectedCallback(){super.connectedCallback();const e=new URL(window.location).searchParams.get("_target");e&&(this._target=e);const t=new URL(window.location).searchParams.get("_api");t&&(this._api=t),window.addEventListener("popstate",e=>{e.state?this.view.show(e.state.component,e.state.tab):this.view.clear()}),document.addEventListener("pb-api-component",e=>{const{component:t,tab:n}=e.detail,i=`#${t.name}.${n}`;history.pushState({component:t,tab:n},"view component",i),this.view.show(t,n)})}firstUpdated(){super.firstUpdated(),this.view=this.shadowRoot.getElementById("view"),this._load().then(()=>{const{hash:e}=window.location;if(e){const t=e.substring(1).split("."),n=t[0],i=t[1];if(n&&i){const e=this._json.tags.find(e=>e.name===n);e&&this.view.show(e,parseInt(i))}}})}_load(){return new Promise(e=>{fetch(this.file).then(e=>e.json()).then(t=>{this._loadDemos(t).then(t=>{this._json=t,e(t)})})})}_loadDemos(e){return new Promise(t=>{this.demo?fetch(this.demo).then(e=>e.json()).then(n=>{this._demos=n,e.tags.forEach(e=>{n[e.name]?e.demo=n[e.name]:e.demo=null}),t(e)}):t(e)})}_filter(){this._demosOnly=this.shadowRoot.getElementById("filter").checked}render(){return j`
|
|
3316
3320
|
<app-drawer-layout>
|
|
3317
3321
|
<app-drawer id="drawer" align="left" slot="drawer" persistent>
|
|
3318
3322
|
<slot name="logo"></slot>
|
|
@@ -3333,4 +3337,4 @@ Mo({_template:ua`
|
|
|
3333
3337
|
#filter {
|
|
3334
3338
|
margin: 20px 10px;
|
|
3335
3339
|
}
|
|
3336
|
-
`}}customElements.define("pb-component-docs",
|
|
3340
|
+
`}}customElements.define("pb-component-docs",bc);export{bc as PbComponentDocs};
|