diff --git a/api-console/README.md b/api-console/README.md
index c2b84ad..939b407 100644
--- a/api-console/README.md
+++ b/api-console/README.md
@@ -10,6 +10,4 @@ Based on https://github.com/mulesoft/api-console
## Embedding the output into extension
-1. Remove `sw.js` and `workbox-*.js` files.
-
-1. Rename the javascript file that is formatted like `204c1d73.js` to `apic-build.js` and copy the folder contents (except `index.html`) to `../extension/assets/api-console/`.
+Rename the javascript file that is formatted like `204c1d73.js` to `apic-build.js`, then copy this file and `vendor.js` to `../extension/assets/api-console/`.
diff --git a/api-console/package-lock.json b/api-console/package-lock.json
index 83c3829..4a66f5e 100644
--- a/api-console/package-lock.json
+++ b/api-console/package-lock.json
@@ -10,7 +10,7 @@
"license": "MIT",
"dependencies": {
"api-console": "^6.4.9",
- "fs-extra": "^9.1.0"
+ "fs-extra": "^10.0.0"
},
"devDependencies": {
"@open-wc/building-rollup": "^1.10.0",
@@ -23,7 +23,7 @@
"lint-staged": "^10.5.4",
"postcss": "^8.2.13",
"rimraf": "^3.0.2",
- "rollup": "^2.46.0",
+ "rollup": "^2.47.0",
"rollup-plugin-cpy": "^2.0.1",
"rollup-plugin-postcss": "^4.0.0",
"uglify-js": "^3.13.5"
@@ -3449,14 +3449,6 @@
"node": ">=8"
}
},
- "node_modules/at-least-node": {
- "version": "1.0.0",
- "resolved": "https://registry.npmjs.org/at-least-node/-/at-least-node-1.0.0.tgz",
- "integrity": "sha512-+q/t7Ekv1EDY2l6Gda6LLiX14rU9TV20Wa3ofeQmwPFZbOMo9DXrLbOjFaaclkXKWidIaopwAObQDqwWtGUjqg==",
- "engines": {
- "node": ">= 4.0.0"
- }
- },
"node_modules/atob": {
"version": "2.1.2",
"resolved": "https://registry.npmjs.org/atob/-/atob-2.1.2.tgz",
@@ -6475,17 +6467,16 @@
}
},
"node_modules/fs-extra": {
- "version": "9.1.0",
- "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.1.0.tgz",
- "integrity": "sha512-hcg3ZmepS30/7BSFqRvoo3DOMQu7IjqxO5nCDt+zM9XWjb33Wg7ziNT+Qvqbuc3+gWpzO02JubVyk2G4Zvo1OQ==",
+ "version": "10.0.0",
+ "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-10.0.0.tgz",
+ "integrity": "sha512-C5owb14u9eJwizKGdchcDUQeFtlSHHthBk8pbX9Vc1PFZrLombudjDnNns88aYslCyF6IY5SUw3Roz6xShcEIQ==",
"dependencies": {
- "at-least-node": "^1.0.0",
"graceful-fs": "^4.2.0",
"jsonfile": "^6.0.1",
"universalify": "^2.0.0"
},
"engines": {
- "node": ">=10"
+ "node": ">=12"
}
},
"node_modules/fs.realpath": {
@@ -12260,9 +12251,9 @@
}
},
"node_modules/rollup": {
- "version": "2.46.0",
- "resolved": "https://registry.npmjs.org/rollup/-/rollup-2.46.0.tgz",
- "integrity": "sha512-qPGoUBNl+Z8uNu0z7pD3WPTABWRbcOwIrO/5ccDJzmrtzn0LVf6Lj91+L5CcWhXl6iWf23FQ6m8Jkl2CmN1O7Q==",
+ "version": "2.47.0",
+ "resolved": "https://registry.npmjs.org/rollup/-/rollup-2.47.0.tgz",
+ "integrity": "sha512-rqBjgq9hQfW0vRmz+0S062ORRNJXvwRpzxhFXORvar/maZqY6za3rgQ/p1Glg+j1hnc1GtYyQCPiAei95uTElg==",
"dev": true,
"bin": {
"rollup": "dist/bin/rollup"
@@ -17769,11 +17760,6 @@
"integrity": "sha512-Z7tMw1ytTXt5jqMcOP+OQteU1VuNK9Y02uuJtKQ1Sv69jXQKKg5cibLwGJow8yzZP+eAc18EmLGPal0bp36rvQ==",
"dev": true
},
- "at-least-node": {
- "version": "1.0.0",
- "resolved": "https://registry.npmjs.org/at-least-node/-/at-least-node-1.0.0.tgz",
- "integrity": "sha512-+q/t7Ekv1EDY2l6Gda6LLiX14rU9TV20Wa3ofeQmwPFZbOMo9DXrLbOjFaaclkXKWidIaopwAObQDqwWtGUjqg=="
- },
"atob": {
"version": "2.1.2",
"resolved": "https://registry.npmjs.org/atob/-/atob-2.1.2.tgz",
@@ -20308,11 +20294,10 @@
}
},
"fs-extra": {
- "version": "9.1.0",
- "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.1.0.tgz",
- "integrity": "sha512-hcg3ZmepS30/7BSFqRvoo3DOMQu7IjqxO5nCDt+zM9XWjb33Wg7ziNT+Qvqbuc3+gWpzO02JubVyk2G4Zvo1OQ==",
+ "version": "10.0.0",
+ "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-10.0.0.tgz",
+ "integrity": "sha512-C5owb14u9eJwizKGdchcDUQeFtlSHHthBk8pbX9Vc1PFZrLombudjDnNns88aYslCyF6IY5SUw3Roz6xShcEIQ==",
"requires": {
- "at-least-node": "^1.0.0",
"graceful-fs": "^4.2.0",
"jsonfile": "^6.0.1",
"universalify": "^2.0.0"
@@ -25105,9 +25090,9 @@
}
},
"rollup": {
- "version": "2.46.0",
- "resolved": "https://registry.npmjs.org/rollup/-/rollup-2.46.0.tgz",
- "integrity": "sha512-qPGoUBNl+Z8uNu0z7pD3WPTABWRbcOwIrO/5ccDJzmrtzn0LVf6Lj91+L5CcWhXl6iWf23FQ6m8Jkl2CmN1O7Q==",
+ "version": "2.47.0",
+ "resolved": "https://registry.npmjs.org/rollup/-/rollup-2.47.0.tgz",
+ "integrity": "sha512-rqBjgq9hQfW0vRmz+0S062ORRNJXvwRpzxhFXORvar/maZqY6za3rgQ/p1Glg+j1hnc1GtYyQCPiAei95uTElg==",
"dev": true,
"requires": {
"fsevents": "~2.3.1"
diff --git a/api-console/package.json b/api-console/package.json
index 61b8cec..cb9af56 100644
--- a/api-console/package.json
+++ b/api-console/package.json
@@ -12,7 +12,7 @@
},
"dependencies": {
"api-console": "^6.4.9",
- "fs-extra": "^9.1.0"
+ "fs-extra": "^10.0.0"
},
"devDependencies": {
"@open-wc/building-rollup": "^1.10.0",
@@ -25,7 +25,7 @@
"lint-staged": "^10.5.4",
"postcss": "^8.2.13",
"rimraf": "^3.0.2",
- "rollup": "^2.46.0",
+ "rollup": "^2.47.0",
"rollup-plugin-cpy": "^2.0.1",
"rollup-plugin-postcss": "^4.0.0",
"uglify-js": "^3.13.5"
diff --git a/api-console/src/api-console-app.js b/api-console/src/api-console-app.js
new file mode 100644
index 0000000..7c67659
--- /dev/null
+++ b/api-console/src/api-console-app.js
@@ -0,0 +1,20 @@
+import { html } from 'lit-element';
+import { ApiConsoleApp } from 'api-console/src/ApiConsoleApp.js';
+
+/* This class overrides ApiConsoleApp methods to customize existing API Console features */
+class CustomApiConsoleApp extends ApiConsoleApp {
+ /*
+ * Override _helpersTemplate() to remove redundant 'oauth-authorization'
+ * elements since they are already created in the 'api-request-editor' element somehow.
+ */
+ _helpersTemplate() {
+ super._helpersTemplate();
+ return html`
+
${0}
`),s,this.infoMessage):"",e?U(Dr||(Dr=Vr`${0}
`),i,e):"")}_labelTemplate(){const{_labelClass:e,_ariaLabelledBy:t}=this;return U(Ur||(Ur=Vr`${0}
`),s,this.infoMessage):"",e?D(Hr||(Hr=Br`${0}
`),i,e):"")}_labelTemplate(){const{_labelClass:e,_ariaLabelledBy:t}=this;return D(Dr||(Dr=Br`Add a header to the HTTP request.
${0} `),this[Lu]())}[Du](e,t){return U(Sm||(Sm=Pm`Add a header to the HTTP request.
${0} `),this[Iu]())}[Hu](e,t){return D(km||(km=Om`${0}
`),b,m):"",u?U(cb||(cb=hb`${0}
`),f,u):"")}static get formAssociated(){return!0}get form(){return this._internals&&this._internals.form||null}get validationStates(){return this._validationStates}set validationStates(e){const t=this._validationStates;t!==e&&(this._validationStates=e,this.requestUpdate&&this.requestUpdate("validationStates",t),this._hasValidationMessage=!(!e||!e.length),this._validationStatesChanged(e),this.dispatchEvent(new CustomEvent("validationstates-changed",{detail:{value:e}})))}get hasValidationMessage(){return this._hasValidationMessage}get _hasValidationMessage(){return this.__hasValidationMessage}set _hasValidationMessage(e){const t=this.__hasValidationMessage;t!==e&&(this.__hasValidationMessage=e,this.requestUpdate&&this.requestUpdate("hasValidationMessage",t),this.__hasValidationMessage=e,this.dispatchEvent(new CustomEvent("hasvalidationmessage-changed",{detail:{value:e}})))}get autoValidate(){return this._autoValidate}set autoValidate(e){this._autoValidate!==e&&(this._autoValidate=e,this._autoValidateChanged(e))}get invalidMessage(){return this._invalidMessage}set invalidMessage(e){const t=this._invalidMessage;t!==e&&(this._invalidMessage=e,this.requestUpdate&&this.requestUpdate("invalidMessage",t),this._hasValidationMessage=this.invalid&&!!e)}get _labelClass(){const e=!!this.value;let t="label";return e&&this.noLabelFloat?t+=" hidden":t+=e?" floating":" resting",(this._formDisabled||this.disabled)&&(t+=" form-disabled"),this.compatibility&&(t+=" compatibility"),t}get _infoAddonClass(){let e="info";return!!this.invalidMessage&&this.invalid&&(e+=" label-hidden"),e}get _errorAddonClass(){let e="invalid";return this.invalid||(e+=" label-hidden"),this.infoMessage&&(e+=" info-offset"),e}get _triggerClass(){let e="trigger-button";return(this._formDisabled||this.disabled)&&(e+=" form-disabled"),e}get _inputContainerClass(){let e="input-container";return(this._formDisabled||this.disabled)&&(e+=" form-disabled"),e}get selectedItem(){return this._selectedItem}get _selectedItem(){return this.__selectedItem}set _selectedItem(e){this.__selectedItem!==e&&(this.__selectedItem=e,this._selectedItemChanged(e))}get opened(){return this._opened||!1}set opened(e){const t=this._opened;t!==e&&(e&&(this._disabled||this._formDisabled)||(this._opened=e,this.requestUpdate("opened",t),this._openedChanged(e),this.dispatchEvent(new CustomEvent("opened-changed",{detail:{value:e}}))))}get contentElement(){const e=this.shadowRoot.querySelector('slot[name="dropdown-content"]');if(!e)return null;const t=e.assignedElements();for(let e=0,i=t.length;e{t.removeAttribute("role")}),1e3))}}window.customElements.define("anypoint-dropdown-menu",db);let pb,ub,mb=e=>e;window.customElements.define("json-table-primitive-teaser",class extends ne{get styles(){return ie(pb||(pb=mb`:host{display:block;margin:4px 0}:host([opened]) .primitive-wrapper{max-height:none}.primitive-wrapper{max-height:var(--json-table-primitive-teaser-max-heigth,160px);overflow:hidden;padding:4px 0}[hidden]{display:none!important}.toggle{font-size:inherit;color:inherit;margin-top:12px;display:inline-block}`))}render(){const{_isOverflow:e,opened:t}=this;return U(ub||(ub=mb` +${0}
`),b,m):"",u?D(lb||(lb=cb`${0}
`),f,u):"")}static get formAssociated(){return!0}get form(){return this._internals&&this._internals.form||null}get validationStates(){return this._validationStates}set validationStates(e){const t=this._validationStates;t!==e&&(this._validationStates=e,this.requestUpdate&&this.requestUpdate("validationStates",t),this._hasValidationMessage=!(!e||!e.length),this._validationStatesChanged(e),this.dispatchEvent(new CustomEvent("validationstates-changed",{detail:{value:e}})))}get hasValidationMessage(){return this._hasValidationMessage}get _hasValidationMessage(){return this.__hasValidationMessage}set _hasValidationMessage(e){const t=this.__hasValidationMessage;t!==e&&(this.__hasValidationMessage=e,this.requestUpdate&&this.requestUpdate("hasValidationMessage",t),this.__hasValidationMessage=e,this.dispatchEvent(new CustomEvent("hasvalidationmessage-changed",{detail:{value:e}})))}get autoValidate(){return this._autoValidate}set autoValidate(e){this._autoValidate!==e&&(this._autoValidate=e,this._autoValidateChanged(e))}get invalidMessage(){return this._invalidMessage}set invalidMessage(e){const t=this._invalidMessage;t!==e&&(this._invalidMessage=e,this.requestUpdate&&this.requestUpdate("invalidMessage",t),this._hasValidationMessage=this.invalid&&!!e)}get _labelClass(){const e=!!this.value;let t="label";return e&&this.noLabelFloat?t+=" hidden":t+=e?" floating":" resting",(this._formDisabled||this.disabled)&&(t+=" form-disabled"),this.compatibility&&(t+=" compatibility"),t}get _infoAddonClass(){let e="info";return!!this.invalidMessage&&this.invalid&&(e+=" label-hidden"),e}get _errorAddonClass(){let e="invalid";return this.invalid||(e+=" label-hidden"),this.infoMessage&&(e+=" info-offset"),e}get _triggerClass(){let e="trigger-button";return(this._formDisabled||this.disabled)&&(e+=" form-disabled"),e}get _inputContainerClass(){let e="input-container";return(this._formDisabled||this.disabled)&&(e+=" form-disabled"),e}get selectedItem(){return this._selectedItem}get _selectedItem(){return this.__selectedItem}set _selectedItem(e){this.__selectedItem!==e&&(this.__selectedItem=e,this._selectedItemChanged(e))}get opened(){return this._opened||!1}set opened(e){const t=this._opened;t!==e&&(e&&(this._disabled||this._formDisabled)||(this._opened=e,this.requestUpdate("opened",t),this._openedChanged(e),this.dispatchEvent(new CustomEvent("opened-changed",{detail:{value:e}}))))}get contentElement(){const e=this.shadowRoot.querySelector('slot[name="dropdown-content"]');if(!e)return null;const t=e.assignedElements();for(let e=0,i=t.length;e{t.removeAttribute("role")}),1e3))}}window.customElements.define("anypoint-dropdown-menu",hb);let db,pb,ub=e=>e;window.customElements.define("json-table-primitive-teaser",class extends se{get styles(){return te(db||(db=ub`:host{display:block;margin:4px 0}:host([opened]) .primitive-wrapper{max-height:none}.primitive-wrapper{max-height:var(--json-table-primitive-teaser-max-heigth,160px);overflow:hidden;padding:4px 0}[hidden]{display:none!important}.toggle{font-size:inherit;color:inherit;margin-top:12px;display:inline-block}`))}render(){const{_isOverflow:e,opened:t}=this;return D(pb||(pb=ub`+ `),this.styles,e?this._rawTemplate():this._highlightedTemplate())}_highlightedTemplate(){return D(qb||(qb=Db``),this.code)}static get properties(){return{code:{type:String},lang:{type:String},languages:{type:Object},raw:{type:Boolean}}}get code(){return this._code}set code(e){this._code!==e&&(this._code=e,this._highlight())}get lang(){return this._lang}set lang(e){this._lang!==e&&(this._lang=e,this._highlight())}get raw(){return this._raw}set raw(e){this._raw!==e&&(this._raw=e,this._rawChanged())}get _output(){return this.shadowRoot.querySelector("code")}constructor(){super(),this.languages={}}firstUpdated(){this.__results&&!this.raw&&(this._output.innerHTML+=this.__results,this.__results=void 0)}reset(){const e=this._output;e&&(e.innerHTML="")}async _rawChanged(){await this.requestUpdate(),this.raw||this._highlight()}_highlight(){const{code:e,lang:t,raw:i}=this;!e&&t||i||(this.reset(),this._highlightDebounce||(this._highlightDebounce=!0,setTimeout((()=>{this._highlightDebounce=!1,this._tokenize(this.code,this.lang)}))))}_tokenize(e,t){const i=this._detectLang(e,t),s={code:e,grammar:i,language:t};Prism.hooks.run("before-highlight",s);const n=Prism.highlight(e,i,t),a=this._output;a?a.innerHTML+=n:(this.__results||(this.__results=""),this.__results+=n)}_handleLinks(e){const t=e.target;if("a"!==t.localName)return;const i=e.ctrlKey||e.metaKey;e.preventDefault(),e.stopPropagation(),e.stopImmediatePropagation();const s=t.href;i?this._dispatchNewRequest(s):this._dispatchChangeUrl(s)}_dispatchChangeUrl(e){this.dispatchEvent(new CustomEvent("url-change-action",{detail:{url:e},bubbles:!0,cancelable:!0,composed:!0}))}_dispatchNewRequest(e){Yp.appendRequest(this,{method:"GET",url:e})}_detectLang(e,t){if(!t)return e.match(/^\s*)?Prism.languages.markup:Prism.languages.javascript;if(this.languages[t])return this.languages[t];if(Prism.languages[t])return Prism.languages[t];switch(t.substr(0,2)){case"js":case"es":case"mj":return Prism.languages.javascript;case"c":return Prism.languages.clike;default:return Prism.languages.markup}}});let Ub;var Bb=te(Ub||(Ub=(e=>e)`:host{display:block;background-color:inherit}.code-wrapper{padding:0}[hidden]{display:none!important}.union-toggle{outline:0;background-color:var(--api-type-document-union-button-background-color,transparent);color:var(--api-type-document-union-button-color,#000);border-width:1px;border-color:var(--api-body-document-media-button-border-color,#a3b11d);border-style:solid}.union-toggle[activated]{background-color:var(--api-type-document-union-button-active-background-color,#cddc39);color:var(--api-type-document-union-button-active-color,#000)}.action-button[active]{background-color:var(--api-resource-example-document-button-active-background-color,#cddc39);color:var(--api-resource-example-document-button-active-color,currentColor)}.action-button[active][focused],.union-toggle[focused]{outline:auto}.union-type-selector{margin:0 8px 12px 0}.code-wrapper.scalar{padding-top:1px}.example-actions{display:flex;align-items:center;flex-direction:row;justify-content:flex-end;flex-wrap:wrap;flex:1}anypoint-button{margin-bottom:8px;height:28px}api-example-render{background-color:inherit}api-example-render,json-table{overflow:auto;max-width:100%}`));let Vb,Fb,jb,Kb,Wb,Gb,Jb,Zb,Xb,Yb=e=>e;window.customElements.define("api-example-render",class extends se{get styles(){return Bb}static get properties(){return{example:{type:Object},mediaType:{type:String},isJson:{type:Boolean},selectedUnion:{type:Number},table:{type:Boolean},renderTable:{type:Boolean},sourceOpened:{type:Boolean},noActions:{type:Boolean},compatibility:{type:Boolean}}}get table(){return this._table}set table(e){const t=this._table;t!==e&&(this._table=e,this.requestUpdate("table",t),this.dispatchEvent(new CustomEvent("table-changed",{composed:!0,detail:{value:e}})))}get mediaType(){return this._mediaType}set mediaType(e){const t=this._mediaType;t!==e&&(this._mediaType=e,this.requestUpdate("mediaType",t),this._dataChanged())}get example(){return this._example}set example(e){const t=this._example;t!==e&&(this._example=e,this.requestUpdate("example",t),this._dataChanged(),this.selectedUnion=0)}get sourceOpened(){return this._sourceOpened}set sourceOpened(e){const t=this._sourceOpened;t!==e&&(this._sourceOpened=e,this.requestUpdate("sourceOpened",t),this._dataChanged())}constructor(){super(),this.sourceOpened=!1,this.compatibility=!1,this.table=!1,this.renderTable=!1,this.isJson=!1,this.noActions=!1,this.sourceOpened=!1,this.selectedUnion=void 0,this.mediaType=void 0}_computeIsJson(e,t){if(!e)return!1;if(!t)return!1;try{return"object"==typeof JSON.parse(t)}catch(e){return!1}}_computeHasRaw(e,t){return!!t&&String(t)!==String(e)}_dataChanged(){this.__changeDebouncer||(this.__changeDebouncer=!0,setTimeout((()=>{this.__changeDebouncer=!1,this._renderCode()})))}_renderCode(){const{example:e}=this;if(this._langValue=void 0,this._codeValue=void 0,e&&(e.value||!e.values)){if(this.sourceOpened)this._codeValue=String(e.raw),this._langValue="yaml";else{const t=String(e.value);if(t.length>1e4)this._codeValue=t;else if(t||!1===t||0===t){let e;const i=this.mediaType;i&&(-1!==i.indexOf("json")?e="json":-1!==i.indexOf("xml")&&(e="xml")),this._codeValue=t,this._langValue=e||this.mediaType}else this._codeValue="(no value in example)"}this.requestUpdate()}}_copyToClipboard(e){const t=e.target;this.shadowRoot.querySelector("clipboard-copy").copy()?t.innerText="Done":t.innerText="Error",t.disabled=!0,"part"in t&&(t.part.add("content-action-button-disabled"),t.part.add("code-content-action-button-disabled")),setTimeout((()=>this._resetCopyButtonState(t)),1e3)}_resetCopyButtonState(e){e.innerText="Copy",e.disabled=!1,"part"in e&&(e.part.remove("content-action-button-disabled"),e.part.remove("code-content-action-button-disabled")),e.focus()}_computeUnionExamples(e,t){if(!(void 0===e||e<0)&&t&&t.values)return t.values[e]}_toggleTable(e){const{target:t}=e,{value:i}=e.detail;this.table=i,i&&this.sourceOpened&&(this.sourceOpened=!i),this._toggleActionButtonCssPart(t,i)}_toggleSourceOpened(e){const{target:t}=e,{value:i}=e.detail;this.sourceOpened=i,i&&this.table&&(this.table=!i),this._toggleActionButtonCssPart(t,i)}_toggleActionButtonCssPart(e,t){if(!("part"in e))return;const i=["content-action-button-active","code-content-action-button-active"];for(let s=0,n=i.length;s`),this._handleLinks)}_rawTemplate(){return U(Db||(Db=Ub`-
+`),this._handleLinks)}_rawTemplate(){return D(Hb||(Hb=Db``),this.code)}static get properties(){return{code:{type:String},lang:{type:String},languages:{type:Object},raw:{type:Boolean}}}get code(){return this._code}set code(e){this._code!==e&&(this._code=e,this._highlight())}get lang(){return this._lang}set lang(e){this._lang!==e&&(this._lang=e,this._highlight())}get raw(){return this._raw}set raw(e){this._raw!==e&&(this._raw=e,this._rawChanged())}get _output(){return this.shadowRoot.querySelector("code")}constructor(){super(),this.languages={}}firstUpdated(){this.__results&&!this.raw&&(this._output.innerHTML+=this.__results,this.__results=void 0)}reset(){const e=this._output;e&&(e.innerHTML="")}async _rawChanged(){await this.requestUpdate(),this.raw||this._highlight()}_highlight(){const{code:e,lang:t,raw:i}=this;!e&&t||i||(this.reset(),this._highlightDebounce||(this._highlightDebounce=!0,setTimeout((()=>{this._highlightDebounce=!1,this._tokenize(this.code,this.lang)}))))}_tokenize(e,t){const i=this._detectLang(e,t),s={code:e,grammar:i,language:t};Prism.hooks.run("before-highlight",s);const n=Prism.highlight(e,i,t),a=this._output;a?a.innerHTML+=n:(this.__results||(this.__results=""),this.__results+=n)}_handleLinks(e){const t=e.target;if("a"!==t.localName)return;const i=e.ctrlKey||e.metaKey;e.preventDefault(),e.stopPropagation(),e.stopImmediatePropagation();const s=t.href;i?this._dispatchNewRequest(s):this._dispatchChangeUrl(s)}_dispatchChangeUrl(e){this.dispatchEvent(new CustomEvent("url-change-action",{detail:{url:e},bubbles:!0,cancelable:!0,composed:!0}))}_dispatchNewRequest(e){Qp.appendRequest(this,{method:"GET",url:e})}_detectLang(e,t){if(!t)return e.match(/^\s*)?Prism.languages.markup:Prism.languages.javascript;if(this.languages[t])return this.languages[t];if(Prism.languages[t])return Prism.languages[t];switch(t.substr(0,2)){case"js":case"es":case"mj":return Prism.languages.javascript;case"c":return Prism.languages.clike;default:return Prism.languages.markup}}});let Bb;var Vb=ie(Bb||(Bb=(e=>e)`:host{display:block;background-color:inherit}.code-wrapper{padding:0}[hidden]{display:none!important}.union-toggle{outline:0;background-color:var(--api-type-document-union-button-background-color,transparent);color:var(--api-type-document-union-button-color,#000);border-width:1px;border-color:var(--api-body-document-media-button-border-color,#a3b11d);border-style:solid}.union-toggle[activated]{background-color:var(--api-type-document-union-button-active-background-color,#cddc39);color:var(--api-type-document-union-button-active-color,#000)}.action-button[active]{background-color:var(--api-resource-example-document-button-active-background-color,#cddc39);color:var(--api-resource-example-document-button-active-color,currentColor)}.action-button[active][focused],.union-toggle[focused]{outline:auto}.union-type-selector{margin:0 8px 12px 0}.code-wrapper.scalar{padding-top:1px}.example-actions{display:flex;align-items:center;flex-direction:row;justify-content:flex-end;flex-wrap:wrap;flex:1}anypoint-button{margin-bottom:8px;height:28px}api-example-render{background-color:inherit}api-example-render,json-table{overflow:auto;max-width:100%}`));let Fb,jb,Kb,Wb,Gb,Jb,Zb,Xb,Yb,Qb=e=>e;window.customElements.define("api-example-render",class extends ne{get styles(){return Vb}static get properties(){return{example:{type:Object},mediaType:{type:String},isJson:{type:Boolean},selectedUnion:{type:Number},table:{type:Boolean},renderTable:{type:Boolean},sourceOpened:{type:Boolean},noActions:{type:Boolean},compatibility:{type:Boolean}}}get table(){return this._table}set table(e){const t=this._table;t!==e&&(this._table=e,this.requestUpdate("table",t),this.dispatchEvent(new CustomEvent("table-changed",{composed:!0,detail:{value:e}})))}get mediaType(){return this._mediaType}set mediaType(e){const t=this._mediaType;t!==e&&(this._mediaType=e,this.requestUpdate("mediaType",t),this._dataChanged())}get example(){return this._example}set example(e){const t=this._example;t!==e&&(this._example=e,this.requestUpdate("example",t),this._dataChanged(),this.selectedUnion=0)}get sourceOpened(){return this._sourceOpened}set sourceOpened(e){const t=this._sourceOpened;t!==e&&(this._sourceOpened=e,this.requestUpdate("sourceOpened",t),this._dataChanged())}constructor(){super(),this.sourceOpened=!1,this.compatibility=!1,this.table=!1,this.renderTable=!1,this.isJson=!1,this.noActions=!1,this.sourceOpened=!1,this.selectedUnion=void 0,this.mediaType=void 0}_computeIsJson(e,t){if(!e)return!1;if(!t)return!1;try{return"object"==typeof JSON.parse(t)}catch(e){return!1}}_computeHasRaw(e,t){return!!t&&String(t)!==String(e)}_dataChanged(){this.__changeDebouncer||(this.__changeDebouncer=!0,setTimeout((()=>{this.__changeDebouncer=!1,this._renderCode()})))}_renderCode(){const{example:e}=this;if(this._langValue=void 0,this._codeValue=void 0,e&&(e.value||!e.values)){if(this.sourceOpened)this._codeValue=String(e.raw),this._langValue="yaml";else{const t=String(e.value);if(t.length>1e4)this._codeValue=t;else if(t||!1===t||0===t){let e;const i=this.mediaType;i&&(-1!==i.indexOf("json")?e="json":-1!==i.indexOf("xml")&&(e="xml")),this._codeValue=t,this._langValue=e||this.mediaType}else this._codeValue="(no value in example)"}this.requestUpdate()}}_copyToClipboard(e){const t=e.target;this.shadowRoot.querySelector("clipboard-copy").copy()?t.innerText="Done":t.innerText="Error",t.disabled=!0,"part"in t&&(t.part.add("content-action-button-disabled"),t.part.add("code-content-action-button-disabled")),setTimeout((()=>this._resetCopyButtonState(t)),1e3)}_resetCopyButtonState(e){e.innerText="Copy",e.disabled=!1,"part"in e&&(e.part.remove("content-action-button-disabled"),e.part.remove("code-content-action-button-disabled")),e.focus()}_computeUnionExamples(e,t){if(!(void 0===e||e<0)&&t&&t.values)return t.values[e]}_toggleTable(e){const{target:t}=e,{value:i}=e.detail;this.table=i,i&&this.sourceOpened&&(this.sourceOpened=!i),this._toggleActionButtonCssPart(t,i)}_toggleSourceOpened(e){const{target:t}=e,{value:i}=e.detail;this.sourceOpened=i,i&&this.table&&(this.table=!i),this._toggleActionButtonCssPart(t,i)}_toggleActionButtonCssPart(e,t){if(!("part"in e))return;const i=["content-action-button-active","code-content-action-button-active"];for(let s=0,n=i.length;s${0}
-e.title)),{selectedUnion:s}=this,n=this._computeUnionExamples(s,e);return U(Fb||(Fb=Qb` Any of: ${0}${0} `),i.map(((e,t)=>U(jb||(jb=Qb`${0} `),s===t,this._selectUnion,t,this.compatibility,e,e))),n?U(Kb||(Kb=Qb``),n,this.isJson,this.mediaType,this.table,this.renderTable,this.noActions):"")}_headerTemplate(e){if(!(!this.noActions&&!e.isScalar))return"";const{compatibility:t}=this,i=this._computeHasRaw(e.value,e.raw),s=this._computeIsJson(this.isJson,e.value);return U(Wb||(Wb=Qb` `),this._copyToClipboard,t,s?U(Gb||(Gb=Qb`Copy ${0} ${0}Table view `),this.table,this._toggleTable,t):"",i?U(Jb||(Jb=Qb`Source view `),this.sourceOpened,this._toggleSourceOpened,t):"")}_renderExample(e){const t=e.value,i=this._computeIsJson(this.isJson,t),s=this.renderTable&&i;return U(Zb||(Zb=Qb` ${0} ${0}`),this._headerTemplate(e),s?U(Xb||(Xb=Qb``),t):"",e.isScalar?"scalar":"",s,this._codeValue,this._langValue)}render(){const{example:e}=this;if(!e)return"";const t=!(!e||!e.hasUnion);return U(Yb||(Yb=Qb` +
'+(i?e:c(e,!0))+"
\n":""+(i?e:c(e,!0))+"
"},a.prototype.blockquote=function(e){return"\n"+e+"\n"},a.prototype.html=function(e){return e},a.prototype.heading=function(e,t,i,s){return this.options.headerIds?"
"+e+"
\n"},a.prototype.table=function(e,t){return t&&(t=""+t+""),""+e+"
"},a.prototype.br=function(){return this.options.xhtml?""+c(e.message+"",!0)+"";throw e}}y.exec=y,w.options=w.setOptions=function(e){return g(w.defaults,e),w},w.getDefaults=function(){return{baseUrl:null,breaks:!1,gfm:!0,headerIds:!0,headerPrefix:"",highlight:null,langPrefix:"language-",mangle:!0,pedantic:!1,renderer:new a,sanitize:!1,sanitizer:null,silent:!1,smartLists:!1,smartypants:!1,xhtml:!1}},w.defaults=w.getDefaults(),w.Parser=o,w.parser=o.parse,w.Renderer=a,w.TextRenderer=r,w.Lexer=i,w.lexer=i.lex,w.InlineLexer=n,w.inlineLexer=n.output,w.Slugger=l,w.parse=w,"undefined"!=typeof module&&"object"==typeof exports?module.exports=w:"function"==typeof define&&define.amd?define((function(){return w})):e.marked=w}(window||("undefined"!=typeof window?window:global));var iv=Object.freeze({__proto__:null});window.marked||(window.marked=iv);let sv,nv,av=e=>e;window.customElements.define("arc-marked",class extends ne{get styles(){return ie(sv||(sv=av`:host{display:block;padding:4px}`))}static get properties(){return{markdown:{type:String},breaks:{type:Boolean},pedantic:{type:Boolean},renderer:{type:Function},sanitize:{type:Boolean},sanitizer:{type:Function},disableRemoteSanitization:{type:Boolean},smartypants:{type:Boolean}}}get markdown(){return this._markdown}set markdown(e){const t=this._markdown;t!==e&&(this._markdown=e,this.renderMarkdown(),this.requestUpdate("markdown",t))}get breaks(){return this._breaks}set breaks(e){const t=this._breaks;t!==e&&(this._breaks=e,this.renderMarkdown(),this.requestUpdate("breaks",t))}get pedantic(){return this._pedantic}set pedantic(e){const t=this._pedantic;t!==e&&(this._pedantic=e,this.renderMarkdown(),this.requestUpdate("pedantic",t))}get renderer(){return this._renderer}set renderer(e){const t=this._renderer;t!==e&&(this._renderer=e,this.renderMarkdown(),this.requestUpdate("renderer",t))}get sanitize(){return this._sanitize}set sanitize(e){const t=this._sanitize;t!==e&&(this._sanitize=e,this.renderMarkdown(),this.requestUpdate("sanitize",t))}get sanitizer(){return this._sanitizer}set sanitizer(e){const t=this._sanitizer;t!==e&&(this._sanitizer=e,this.renderMarkdown(),this.requestUpdate("sanitizer",t))}get smartypants(){return this._smartypants}set smartypants(e){const t=this._smartypants;t!==e&&(this._smartypants=e,this.renderMarkdown(),this.requestUpdate("smartypants",t))}constructor(){super(),this.breaks=!1,this.pedantic=!1,this.sanitize=!1,this.disableRemoteSanitization=!1,this.smartypants=!1}firstUpdated(){if(this._outputElement=this.outputElement,this.markdown)return void this.renderMarkdown();if(this._markdownElement=this.querySelector('[type="text/markdown"]'),!this._markdownElement)return;this._markdownElement.src&&this._request(this._markdownElement.src),""!==this._markdownElement.textContent.trim()&&(this.markdown=this._unindent(this._markdownElement.textContent));new MutationObserver(this._onScriptAttributeChanged.bind(this)).observe(this._markdownElement,{attributes:!0})}connectedCallback(){super.connectedCallback(),this._attached=!0,this._outputElement=this.outputElement,this.renderMarkdown()}disconnectedCallback(){super.disconnectedCallback(),this._attached=!1}unindent(e){return this._unindent(e)}get outputElement(){const e=this.shadowRoot.querySelector("slot");if(!e)return null;return e.assignedNodes().find((e=>1===e.nodeType&&"markdown-html"===e.getAttribute("slot")))||this.shadowRoot.querySelector("#content")}renderMarkdown(){if(!this._attached)return;if(!this._outputElement)return;if(!this.markdown)return void(this._outputElement.innerHTML="");const e=new marked.Renderer;this.renderer&&this.renderer(e);const t=this.markdown,i={renderer:e,highlight:this._highlight.bind(this),breaks:this.breaks,pedantic:this.pedantic,smartypants:this.smartypants};let s=marked(t,i);if(this.sanitize)if(this.sanitizer)s=this.sanitizer(s);else{const e=tv.sanitize(s);s="string"==typeof e?e:e.toString()}this._outputElement.innerHTML=s,this.dispatchEvent(new CustomEvent("marked-render-complete")),this.dispatchEvent(new CustomEvent("markedrendercomplete"))}_highlight(e,t){const i=new CustomEvent("syntax-highlight",{composed:!0,bubbles:!0,detail:{code:e,lang:t}});return this.dispatchEvent(i),i.detail.code||e}_unindent(e){if(!e)return e;const t=e.replace(/\t/g," ").split("\n"),i=t.reduce(((e,t)=>{if(/^\s*$/.test(t))return e;const i=t.match(/^(\s*)/)[0].length;return null===e||i
'+(i?e:c(e,!0))+"
\n":""+(i?e:c(e,!0))+"
"},a.prototype.blockquote=function(e){return"\n"+e+"\n"},a.prototype.html=function(e){return e},a.prototype.heading=function(e,t,i,s){return this.options.headerIds?"
"+e+"
\n"},a.prototype.table=function(e,t){return t&&(t=""+t+""),""+e+"
"},a.prototype.br=function(){return this.options.xhtml?""+c(e.message+"",!0)+"";throw e}}y.exec=y,w.options=w.setOptions=function(e){return g(w.defaults,e),w},w.getDefaults=function(){return{baseUrl:null,breaks:!1,gfm:!0,headerIds:!0,headerPrefix:"",highlight:null,langPrefix:"language-",mangle:!0,pedantic:!1,renderer:new a,sanitize:!1,sanitizer:null,silent:!1,smartLists:!1,smartypants:!1,xhtml:!1}},w.defaults=w.getDefaults(),w.Parser=o,w.parser=o.parse,w.Renderer=a,w.TextRenderer=r,w.Lexer=i,w.lexer=i.lex,w.InlineLexer=n,w.inlineLexer=n.output,w.Slugger=l,w.parse=w,"undefined"!=typeof module&&"object"==typeof exports?module.exports=w:"function"==typeof define&&define.amd?define((function(){return w})):e.marked=w}(window||("undefined"!=typeof window?window:global));var tv=Object.freeze({__proto__:null});window.marked||(window.marked=tv);let iv,sv,nv=e=>e;window.customElements.define("arc-marked",class extends se{get styles(){return te(iv||(iv=nv`:host{display:block;padding:4px}`))}static get properties(){return{markdown:{type:String},breaks:{type:Boolean},pedantic:{type:Boolean},renderer:{type:Function},sanitize:{type:Boolean},sanitizer:{type:Function},disableRemoteSanitization:{type:Boolean},smartypants:{type:Boolean}}}get markdown(){return this._markdown}set markdown(e){const t=this._markdown;t!==e&&(this._markdown=e,this.renderMarkdown(),this.requestUpdate("markdown",t))}get breaks(){return this._breaks}set breaks(e){const t=this._breaks;t!==e&&(this._breaks=e,this.renderMarkdown(),this.requestUpdate("breaks",t))}get pedantic(){return this._pedantic}set pedantic(e){const t=this._pedantic;t!==e&&(this._pedantic=e,this.renderMarkdown(),this.requestUpdate("pedantic",t))}get renderer(){return this._renderer}set renderer(e){const t=this._renderer;t!==e&&(this._renderer=e,this.renderMarkdown(),this.requestUpdate("renderer",t))}get sanitize(){return this._sanitize}set sanitize(e){const t=this._sanitize;t!==e&&(this._sanitize=e,this.renderMarkdown(),this.requestUpdate("sanitize",t))}get sanitizer(){return this._sanitizer}set sanitizer(e){const t=this._sanitizer;t!==e&&(this._sanitizer=e,this.renderMarkdown(),this.requestUpdate("sanitizer",t))}get smartypants(){return this._smartypants}set smartypants(e){const t=this._smartypants;t!==e&&(this._smartypants=e,this.renderMarkdown(),this.requestUpdate("smartypants",t))}constructor(){super(),this.breaks=!1,this.pedantic=!1,this.sanitize=!1,this.disableRemoteSanitization=!1,this.smartypants=!1}firstUpdated(){if(this._outputElement=this.outputElement,this.markdown)return void this.renderMarkdown();if(this._markdownElement=this.querySelector('[type="text/markdown"]'),!this._markdownElement)return;this._markdownElement.src&&this._request(this._markdownElement.src),""!==this._markdownElement.textContent.trim()&&(this.markdown=this._unindent(this._markdownElement.textContent));new MutationObserver(this._onScriptAttributeChanged.bind(this)).observe(this._markdownElement,{attributes:!0})}connectedCallback(){super.connectedCallback(),this._attached=!0,this._outputElement=this.outputElement,this.renderMarkdown()}disconnectedCallback(){super.disconnectedCallback(),this._attached=!1}unindent(e){return this._unindent(e)}get outputElement(){const e=this.shadowRoot.querySelector("slot");if(!e)return null;return e.assignedNodes().find((e=>1===e.nodeType&&"markdown-html"===e.getAttribute("slot")))||this.shadowRoot.querySelector("#content")}renderMarkdown(){if(!this._attached)return;if(!this._outputElement)return;if(!this.markdown)return void(this._outputElement.innerHTML="");const e=new marked.Renderer;this.renderer&&this.renderer(e);const t=this.markdown,i={renderer:e,highlight:this._highlight.bind(this),breaks:this.breaks,pedantic:this.pedantic,smartypants:this.smartypants};let s=marked(t,i);if(this.sanitize)if(this.sanitizer)s=this.sanitizer(s);else{const e=ev.sanitize(s);s="string"==typeof e?e:e.toString()}this._outputElement.innerHTML=s,this.dispatchEvent(new CustomEvent("marked-render-complete")),this.dispatchEvent(new CustomEvent("markedrendercomplete"))}_highlight(e,t){const i=new CustomEvent("syntax-highlight",{composed:!0,bubbles:!0,detail:{code:e,lang:t}});return this.dispatchEvent(i),i.detail.code||e}_unindent(e){if(!e)return e;const t=e.replace(/\t/g," ").split("\n"),i=t.reduce(((e,t)=>{if(/^\s*$/.test(t))return e;const i=t.match(/^(\s*)/)[0].length;return null===e||i
Properties inherited from ${0}.
`),e.label):U(Wv||(Wv=Yv`Properties defined inline.
`)),this.amf,e.type,this.narrow,this.noExamplesActions,this._renderMainExample,this.compatibility,this.mediaType,this.graph)))):""}render(){let e="content-action-button, code-content-action-button, content-action-button-disabled, ";e+="code-content-action-button-disabled content-action-button-active, ",e+="code-content-action-button-active, code-wrapper, example-code-wrapper, markdown-html";const t=this.mediaTypes||[];return U(Gv||(Gv=Yv` + `),this.styles,this.compatibility,this.amf,e,this._hasProperty(e,this.ns.w3.shacl.defaultValueStr)?this._listItemTemplate("Default value","This value is used as a default value",this.ns.w3.shacl.defaultValueStr):"",this._hasProperty(e,this.ns.w3.shacl.pattern)?this._listItemTemplate("Pattern","Regular expression value for this property",this.ns.w3.shacl.pattern):"",this._hasProperty(e,this.ns.w3.shacl.minInclusive)?this._listItemTemplate("Min value","Minimum numeric value possible to set on this property",this.ns.w3.shacl.minInclusive):"",this._hasProperty(e,this.ns.w3.shacl.maxInclusive)?this._listItemTemplate("Max value","Maximum numeric value possible to set on this property",this.ns.w3.shacl.maxInclusive):"",this._hasProperty(e,this.ns.w3.shacl.multipleOf)?this._listItemTemplate("Multiple of","The numeric value has to be multipliable by this value",this.ns.w3.shacl.multipleOf):"",this.isFile?this._filePropertiesTemplate():this._nonFilePropertiesTemplate(),this.isEnum?this._enumTemplate():"",!this._hasExamples,this.amf,e,this.mediaType,this.propertyName,this.compatibility,this.noExamplesActions,!this._hasMediaType,this._examplesChanged,this._hasExamplesHandler)}}window.customElements.define("property-range-document",Mv);let Rv;var Nv=te(Rv||(Rv=(e=>e)`:host{display:block;font-size:var(--arc-font-body1-font-size);font-weight:var(--arc-font-body1-font-weight);line-height:var(--arc-font-body1-line-height)}property-shape-document{padding:12px 0}:last-of-type,property-shape-document:last-of-type{border-bottom:none}.array-children{box-sizing:border-box;padding-left:12px;border-left:2px var(--property-shape-document-array-color,#8bc34a) solid}:host([hasparenttype]) .array-children{padding-left:0;border-left:none}.inheritance-label{font-size:var(--api-type-document-inheritance-label-font-size,16px)}.media-type-selector{margin:20px 0}.media-toggle{outline:0;color:var(--api-type-document-media-button-color,#000);background-color:var(--api-type-document-media-button-background-color,#fff);border-width:1px;border-color:var(--api-type-document-media-button-border-color,#a3b11d);border-style:solid}.media-toggle[activated]{background-color:var(--api-type-document-media-button-active-background-color,#cddc39)}.any-of-toggle,.one-of-toggle,.union-toggle{outline:0;background-color:var(--api-type-document-union-button-background-color,#fff);color:var(--api-type-document-union-button-color,#000);border-width:1px;border-color:var(--api-type-document-media-button-border-color,#a3b11d);border-style:solid}.any-of-toggle[activated],.one-of-toggle[activated],.union-toggle[activated]{background-color:var(--api-type-document-union-button-active-background-color,#cddc39);color:var(--api-type-document-union-button-active-color,#000)}.union-type-selector{margin:12px 0}`));let zv,Iv,Lv,qv,Hv,Dv,Uv,Bv,Vv,Fv,jv,Kv,Wv,Gv,Jv,Zv,Xv=e=>e;class Yv extends(av(se)){get styles(){return Nv}static get properties(){return{type:{type:Object},mediaType:{type:String},mediaTypes:{type:Array},selectedMediaType:{type:Number},_resolvedType:{type:Object},parentTypeName:{type:String},hasParentType:{type:Boolean},isScalar:{type:Boolean},isArray:{type:Boolean},isObject:{type:Boolean},isUnion:{type:Boolean},isAnd:{type:Boolean},isOneOf:{type:Boolean},isAnyOf:{type:Boolean},unionTypes:{type:Array},oneOfTypes:{type:Array},anyOfTypes:{type:Array},andTypes:{type:Array},selectedUnion:{type:Number},selectedOneOf:{type:Number},selectedAnyOf:{type:Number},narrow:{type:Boolean},noMainExample:{type:Boolean},selectedBodyId:{type:String},_hasExamples:{type:Boolean},_renderMainExample:{type:Boolean},renderReadOnly:{type:Boolean}}}get type(){return this._type}set type(e){const t=this._type;t!==e&&(this._type=e,this.requestUpdate("type",t),this._resolvedType=this._resolve(e),this.__typeChanged())}get mediaTypes(){return this._mediaTypes}set mediaTypes(e){const t=this._mediaTypes;t!==e&&(this._mediaTypes=e,this.requestUpdate("mediaTypes",t),this._mediaTypesChanged(e))}get parentTypeName(){return this._parentTypeName}set parentTypeName(e){const t=this._parentTypeName;t!==e&&(this._parentTypeName=e,this.requestUpdate("parentTypeName",t),this.hasParentType=!!e)}get unionTypes(){return this._unionTypes}set unionTypes(e){const t=this._unionTypes;t!==e&&(this._unionTypes=e,this.requestUpdate("unionTypes",t),this._multiTypesChanged("selectedUnion",e))}get oneOfTypes(){return this._oneOfTypes}set oneOfTypes(e){const t=this._oneOfTypes;t!==e&&(this._oneOfTypes=e,this.requestUpdate("oneOfTypes",t),this._multiTypesChanged("selectedOneOf",e))}get anyOfTypes(){return this._anyOfTypes}set anyOfTypes(e){const t=this._anyOfTypes;t!==e&&(this._anyOfTypes=e,this.requestUpdate("anyOfTypes",t),this._multiTypesChanged("selectedAnyOf",e))}get noMainExample(){return this._noMainExample}set noMainExample(e){const t=this._noMainExample;t!==e&&(this._noMainExample=e,this.requestUpdate("noMainExample",t),this._renderMainExample=this._computeRenderMainExample(e,this._hasExamples))}get _hasExamples(){return this.__hasExamples}set _hasExamples(e){const t=this.__hasExamples;t!==e&&(this.__hasExamples=e,this.requestUpdate("_hasExamples",t),this._renderMainExample=this._computeRenderMainExample(this.noMainExample,e))}constructor(){super(),this.hasParentType=!1,this.narrow=!1,this.selectedBodyId=void 0,this.selectedUnion=void 0,this.selectedOneOf=void 0,this.selectedAnyOf=void 0,this.renderReadOnly=!1,this._isPropertyReadOnly=this._isPropertyReadOnly.bind(this)}connectedCallback(){super.connectedCallback&&super.connectedCallback(),window.ShadyCSS&&window.ShadyCSS.styleElement(this)}_computeRenderMainExample(e,t){return!(e||!t)}__typeChanged(){this.__typeChangeDebouncer||(this.__typeChangeDebouncer=!0,setTimeout((()=>{this.__typeChangeDebouncer=!1,this._typeChanged(this._resolvedType)})))}_typeChanged(e){if(!e)return;let t=!1,i=!1,s=!1,n=!1,a=!1,r=!1,o=!1,l="";if(e instanceof Array)s=!0;else if(this._hasType(e,this.ns.aml.vocabularies.shapes.ScalarShape)||this._hasType(e,this.ns.aml.vocabularies.shapes.NilShape))t=!0;else if(this._hasType(e,this.ns.aml.vocabularies.shapes.UnionShape))n=!0,l=this._getAmfKey(this.ns.aml.vocabularies.shapes.anyOf),this.unionTypes=this._computeTypes(e,l);else if(this._hasProperty(e,this.ns.w3.shacl.xone))r=!0,l=this._getAmfKey(this.ns.w3.shacl.xone),this.oneOfTypes=this._computeTypes(e,l);else if(this._hasProperty(e,this.ns.w3.shacl.or))o=!0,l=this._getAmfKey(this.ns.w3.shacl.or),this.anyOfTypes=this._computeTypes(e,l);else if(this._hasType(e,this.ns.aml.vocabularies.shapes.ArrayShape)){i=!0;const t=this._getAmfKey(this.ns.aml.vocabularies.shapes.items);let s=this._ensureArray(e[t]);if(s){s=s[0];const e=this._getAmfKey(this.ns.w3.shacl.and);e in s&&(i=!1,a=!0,this.andTypes=this._computeAndTypes(s[e]))}}else if(this._hasType(e,this.ns.w3.shacl.NodeShape))s=!0;else if(this._hasType(e,this.ns.aml.vocabularies.shapes.AnyShape)){const i=this._getAmfKey(this.ns.w3.shacl.and);i in e?(a=!0,this.andTypes=this._computeAndTypes(e[i])):t=!0}this.isScalar=t,this.isArray=i,this.isObject=s,this.isUnion=n,this.isAnd=a,this.isOneOf=r,this.isAnyOf=o}_computeArrayParentName(e){return e||""}_multiTypesChanged(e,t){t&&(this[e]=0)}_selectType(e,t){const i=t.target,s=Number(i.dataset.index);Number.isNaN(s)||(this[e]===s?i.active=!0:this[e]=s)}_computeProperty(e,t,i){if(!e)return;const s=e[t];if(!s)return;let n=s[i];if(n){if(Array.isArray(n)&&([n]=n),this._hasType(n,this.ns.aml.vocabularies.shapes.ArrayShape)){n=this._resolve(n);const e=this._getAmfKey(this.ns.aml.vocabularies.shapes.items),t=this._ensureArray(n[e]);if(t&&1===t.length){let e=t[0];return Array.isArray(e)&&([e]=e),e=this._resolve(e),e}}return Array.isArray(n)&&([n]=n),this._resolve(n)}}_computeProperties(e){if(!e)return;if(Array.isArray(e))return e;const t=this._getAmfKey(this.ns.w3.shacl.property);return this._filterReadOnlyProperties(this._ensureArray(e[t]))}_computeAndTypes(e){if(e&&e.length)return e.map((e=>{Array.isArray(e)&&([e]=e),e=this._resolve(e);let t=this._getValue(e,this.ns.aml.vocabularies.core.name);return t||(t=this._getValue(e,this.ns.w3.shacl.name)),t&&0===t.indexOf("item")&&(t=void 0),{label:t,type:e}}))}_mediaTypesChanged(e){e&&e instanceof Array&&e.length?1===e.length?(this.renderMediaSelector=!1,this.mediaType=e[0]):(this.renderMediaSelector=!0,this.mediaType=e[0],this.selectedMediaType=0):this.renderMediaSelector=!1}_mediaTypeActive(e,t){return e===t}_selectMediaType(e){const t=e.target,i=Number(t.dataset.index);Number.isNaN(i)||(i!==this.selectedMediaType?(this.selectedMediaType=i,this.mediaType=this.mediaTypes[i]):t.active=!0)}_hasExamplesHandler(e){const{value:t}=e.detail;this._hasExamples=t}_objectTemplate(){const e=this._computeProperties(this._resolvedType);return e&&e.length?e.map((e=>D(zv||(zv=Xv`Properties inherited from ${0}.
`),e.label):D(Kv||(Kv=Xv`Properties defined inline.
`)),this.amf,e.type,this.narrow,this.noExamplesActions,this._renderMainExample,this.compatibility,this.mediaType,this.graph)))):""}render(){let e="content-action-button, code-content-action-button, content-action-button-disabled, ";e+="code-content-action-button-disabled content-action-button-active, ",e+="code-content-action-button-active, code-wrapper, example-code-wrapper, markdown-html";const t=this.mediaTypes||[];return D(Wv||(Wv=Xv`Any instance of data is allowed.
The API file specifies body for this request but it does not specify the data model.
Any instance of data is allowed.
The API file specifies body for this request but it does not specify the data model.
Headers are not required by this endpoint
`)))}static get properties(){return{amf:{type:Object},headers:{type:Array},opened:{type:Boolean},narrow:{type:Boolean,reflect:!0},compatibility:{type:Boolean},headerLevel:{type:Number},graph:{type:Boolean}}}constructor(){super(),this.headerLevel=2,this.headers=void 0,this.amf=void 0,this.narrow=!1,this.compatibility=!1,this.graph=!1}_computeToggleActionLabel(e){return e?"Hide":"Show"}_computeToggleIconClass(e){let t="toggle-icon";return e&&(t+=" opened"),t}toggle(){this.opened=!this.opened}});let Jw;var Zw=ie(Jw||(Jw=(e=>e)`:host{display:block}arc-marked{margin-top:8px;padding:0}.no-info{font-style:italic}.codes-selector{border-bottom:1px #e5e5e5 solid}api-links-document{margin-top:20px}`));let Xw;var Yw=ie(Xw||(Xw=(e=>e)`:host{display:block}.links-header{font-size:1.2rem;margin:.8em 0}.link-header{font-size:1.1rem;margin:1em 0 .4em 0;font-weight:500}.operation-id{display:flex;flex-direction:row;margin:.2em 0}.operation-name{margin-left:8px;font-weight:500}.mapping-table{margin:12px 0!important}`));let Qw,ex,tx,ix,sx,nx=e=>e;class ax extends(sg(ne)){get styles(){return[Sf,Yw]}static get properties(){return{links:{type:Array}}}render(){const{links:e,styles:t}=this;return e&&e.length?U(Qw||(Qw=nx` + `),this.styles,this.toggle,e,a,n,this._computeToggleActionLabel(e),this._computeToggleIconClass(e),e,o?D(jw||(jw=Ww`Headers are not required by this endpoint
`)))}static get properties(){return{amf:{type:Object},headers:{type:Array},opened:{type:Boolean},narrow:{type:Boolean,reflect:!0},compatibility:{type:Boolean},headerLevel:{type:Number},graph:{type:Boolean}}}constructor(){super(),this.headerLevel=2,this.headers=void 0,this.amf=void 0,this.narrow=!1,this.compatibility=!1,this.graph=!1}_computeToggleActionLabel(e){return e?"Hide":"Show"}_computeToggleIconClass(e){let t="toggle-icon";return e&&(t+=" opened"),t}toggle(){this.opened=!this.opened}});let Gw;var Jw=te(Gw||(Gw=(e=>e)`:host{display:block}arc-marked{margin-top:8px;padding:0}.no-info{font-style:italic}.codes-selector{border-bottom:1px #e5e5e5 solid}api-links-document{margin-top:20px}`));let Zw;var Xw=te(Zw||(Zw=(e=>e)`:host{display:block}.links-header{font-size:1.2rem;margin:.8em 0}.link-header{font-size:1.1rem;margin:1em 0 .4em 0;font-weight:500}.operation-id{display:flex;flex-direction:row;margin:.2em 0}.operation-name{margin-left:8px;font-weight:500}.mapping-table{margin:12px 0!important}`));let Yw,Qw,ex,tx,ix,sx=e=>e;class nx extends(ig(se)){get styles(){return[kf,Xw]}static get properties(){return{links:{type:Array}}}render(){const{links:e,styles:t}=this;return e&&e.length?D(Yw||(Yw=sx`Variable | Expression |
---|
Variable | Expression |
---|
No description provided
`)):"")}_codesSelectorTemplate(){const{codes:e,selected:t}=this;return e&&e.length?U(lx||(lx=yx`No description provided
`)):"")}_codesSelectorTemplate(){const{codes:e,selected:t}=this;return e&&e.length?D(ox||(ox=mx`
`),this.styles,this._copyToClipboard)}static get properties(){return{url:{type:String},method:{type:String},headers:{type:Array},payload:{type:String},compatibility:{type:Boolean}}}get url(){return this._url}get method(){return this._method}get headers(){return this._headers}get payload(){return this._payload}set url(e){const t=this._url;t!==e&&(this._url=e,this.requestUpdate("url",t),this._valuesChanged())}set method(e){const t=this._method;t!==e&&(this._method=e,this.requestUpdate("method",t),this._valuesChanged())}set headers(e){const t=this._headers;t!==e&&(this._headers=e,this.requestUpdate("headers",t),this._valuesChanged())}set payload(e){const t=this._payload;t!==e&&(this._payload=e,this.requestUpdate("payload",t),this._valuesChanged())}get _code(){return this.shadowRoot.querySelector("code")}connectedCallback(){super.connectedCallback(),this.__valuesDebouncer||this._valuesChanged()}disconnectedCallback(){super.disconnectedCallback(),this._clearValueTimeout()}_clearValueTimeout(){this.__valuesDebouncer&&(clearTimeout(this.__valuesDebouncer),this.__valuesDebouncer=void 0)}_valuesChanged(){this._clearValueTimeout(),this.__valuesDebouncer=setTimeout((()=>{this.__valuesDebouncer=void 0,this._processCommand()}))}_processCommand(){const{url:e,method:t,headers:i,payload:s}=this;let n=this._computeCommand(e,t,i,s);n=n?this._highlight(n,this.lang):"",this._code.innerHTML=n}_computeCommand(e,t,i,s){return`${e} ${t} ${i} ${s}`}_highlight(e,t){const i=new CustomEvent("syntax-highlight",{bubbles:!0,cancelable:!0,composed:!0,detail:{code:e,lang:t}});return this.dispatchEvent(i),i.detail.code||e}urlDetails(e){if(wx[e])return wx[e];const t=e||this.url,i={path:"",port:"",hostValue:"",autoPort:!1};if(!t)return i;let s;try{s=new URL(t)}catch(e){return"/"===t[0]&&(i.path=t,i.port="80"),i}let n=s.hostname;n&&(n=decodeURIComponent(n));let{port:a}=s;a||(i.autoPort=!0,a="https:"===s.protocol?"443":"80"),i.port=String(a),i.hostValue=n;const r=s.search;let o=s.pathname;return o=o?decodeURIComponent(o):"/",r&&(o+=r),i.path=o,wx[t]=i,i}_copyToClipboard(){const e=this._code;if(!e)return;const t=e.innerText;if(this._beforeCopy(t))return;const i=document.createElement("textarea");i.value=t,i.setAttribute("readonly",""),i.style.position="absolute",i.style.left="-9999px",document.body.appendChild(i);const s=document.getSelection().rangeCount>0&&document.getSelection().getRangeAt(0);i.select();try{document.execCommand("copy")}catch(e){}document.body.removeChild(i),document.getSelection().removeAllRanges(),s&&document.getSelection().addRange(s)}_beforeCopy(e){const t=new CustomEvent("content-copy",{detail:{value:e},bubbles:!0,cancelable:!0,composed:!0});return this.dispatchEvent(t),t.defaultPrevented}}!function(e){e.languages.http={"request-line":{pattern:/^(?:POST|GET|PUT|DELETE|OPTIONS|PATCH|TRACE|CONNECT)\s(?:https?:\/\/|\/)\S+\sHTTP\/[0-9.]+/m,inside:{property:/^(?:POST|GET|PUT|DELETE|OPTIONS|PATCH|TRACE|CONNECT)\b/,"attr-name":/:\w+/}},"response-status":{pattern:/^HTTP\/1.[01] \d.*/m,inside:{property:{pattern:/(^HTTP\/1.[01] )\d.*/i,lookbehind:!0}}},"header-name":{pattern:/^[\w-]+:(?=.)/m,alias:"keyword"}};var t,i,s,n=e.languages,a={"application/javascript":n.javascript,"application/json":n.json||n.javascript,"application/xml":n.xml,"text/xml":n.xml,"text/html":n.html,"text/css":n.css},r={"application/json":!0,"application/xml":!0};for(var o in a)if(a[o]){t=t||{};var l=r[o]?(s=(i=o).replace(/^[a-z]+\//,""),"(?:"+i+"|\\w+/(?:[\\w.-]+\\+)+"+s+"(?![+\\w.-]))"):o;t[o.replace(/\//g,"-")]={pattern:RegExp("(content-type:\\s*"+l+".*)(?:\\r?\\n|\\r){2}[\\s\\S]*","i"),lookbehind:!0,inside:a[o]}}t&&e.languages.insertBefore("http","header-name",t)}(Prism);window.customElements.define("raw-http-snippet",class extends xx{get lang(){return"http"}_computeCommand(e,t,i,s){if(!e||!t)return"";const n=this.urlDetails(e);let a=`${t} ${n.path} HTTP/1.1\n`;return n.hostValue&&(a+=`Host: ${n.hostValue}:${n.port}\n`),a+=this._genHeadersPart(i),a+=this._genPayloadPart(s),a}_genHeadersPart(e){let t="";if(e&&e instanceof Array)for(let i=0,s=e.length;i
`),this.styles,this._copyToClipboard)}static get properties(){return{url:{type:String},method:{type:String},headers:{type:Array},payload:{type:String},compatibility:{type:Boolean}}}get url(){return this._url}get method(){return this._method}get headers(){return this._headers}get payload(){return this._payload}set url(e){const t=this._url;t!==e&&(this._url=e,this.requestUpdate("url",t),this._valuesChanged())}set method(e){const t=this._method;t!==e&&(this._method=e,this.requestUpdate("method",t),this._valuesChanged())}set headers(e){const t=this._headers;t!==e&&(this._headers=e,this.requestUpdate("headers",t),this._valuesChanged())}set payload(e){const t=this._payload;t!==e&&(this._payload=e,this.requestUpdate("payload",t),this._valuesChanged())}get _code(){return this.shadowRoot.querySelector("code")}connectedCallback(){super.connectedCallback(),this.__valuesDebouncer||this._valuesChanged()}disconnectedCallback(){super.disconnectedCallback(),this._clearValueTimeout()}_clearValueTimeout(){this.__valuesDebouncer&&(clearTimeout(this.__valuesDebouncer),this.__valuesDebouncer=void 0)}_valuesChanged(){this._clearValueTimeout(),this.__valuesDebouncer=setTimeout((()=>{this.__valuesDebouncer=void 0,this._processCommand()}))}_processCommand(){const{url:e,method:t,headers:i,payload:s}=this;let n=this._computeCommand(e,t,i,s);n=n?this._highlight(n,this.lang):"",this._code.innerHTML=n}_computeCommand(e,t,i,s){return`${e} ${t} ${i} ${s}`}_highlight(e,t){const i=new CustomEvent("syntax-highlight",{bubbles:!0,cancelable:!0,composed:!0,detail:{code:e,lang:t}});return this.dispatchEvent(i),i.detail.code||e}urlDetails(e){if(vx[e])return vx[e];const t=e||this.url,i={path:"",port:"",hostValue:"",autoPort:!1};if(!t)return i;let s;try{s=new URL(t)}catch(e){return"/"===t[0]&&(i.path=t,i.port="80"),i}let n=s.hostname;n&&(n=decodeURIComponent(n));let{port:a}=s;a||(i.autoPort=!0,a="https:"===s.protocol?"443":"80"),i.port=String(a),i.hostValue=n;const r=s.search;let o=s.pathname;return o=o?decodeURIComponent(o):"/",r&&(o+=r),i.path=o,vx[t]=i,i}_copyToClipboard(){const e=this._code;if(!e)return;const t=e.innerText;if(this._beforeCopy(t))return;const i=document.createElement("textarea");i.value=t,i.setAttribute("readonly",""),i.style.position="absolute",i.style.left="-9999px",document.body.appendChild(i);const s=document.getSelection().rangeCount>0&&document.getSelection().getRangeAt(0);i.select();try{document.execCommand("copy")}catch(e){}document.body.removeChild(i),document.getSelection().removeAllRanges(),s&&document.getSelection().addRange(s)}_beforeCopy(e){const t=new CustomEvent("content-copy",{detail:{value:e},bubbles:!0,cancelable:!0,composed:!0});return this.dispatchEvent(t),t.defaultPrevented}}!function(e){e.languages.http={"request-line":{pattern:/^(?:POST|GET|PUT|DELETE|OPTIONS|PATCH|TRACE|CONNECT)\s(?:https?:\/\/|\/)\S+\sHTTP\/[0-9.]+/m,inside:{property:/^(?:POST|GET|PUT|DELETE|OPTIONS|PATCH|TRACE|CONNECT)\b/,"attr-name":/:\w+/}},"response-status":{pattern:/^HTTP\/1.[01] \d.*/m,inside:{property:{pattern:/(^HTTP\/1.[01] )\d.*/i,lookbehind:!0}}},"header-name":{pattern:/^[\w-]+:(?=.)/m,alias:"keyword"}};var t,i,s,n=e.languages,a={"application/javascript":n.javascript,"application/json":n.json||n.javascript,"application/xml":n.xml,"text/xml":n.xml,"text/html":n.html,"text/css":n.css},r={"application/json":!0,"application/xml":!0};for(var o in a)if(a[o]){t=t||{};var l=r[o]?(s=(i=o).replace(/^[a-z]+\//,""),"(?:"+i+"|\\w+/(?:[\\w.-]+\\+)+"+s+"(?![+\\w.-]))"):o;t[o.replace(/\//g,"-")]={pattern:RegExp("(content-type:\\s*"+l+".*)(?:\\r?\\n|\\r){2}[\\s\\S]*","i"),lookbehind:!0,inside:a[o]}}t&&e.languages.insertBefore("http","header-name",t)}(Prism);window.customElements.define("raw-http-snippet",class extends wx{get lang(){return"http"}_computeCommand(e,t,i,s){if(!e||!t)return"";const n=this.urlDetails(e);let a=`${t} ${n.path} HTTP/1.1\n`;return n.hostValue&&(a+=`Host: ${n.hostValue}:${n.port}\n`),a+=this._genHeadersPart(i),a+=this._genPayloadPart(s),a}_genHeadersPart(e){let t="";if(e&&e instanceof Array)for(let i=0,s=e.length;i${0}
${0}
${0}
${0}
${0}
`),e):"",t?U(vk||(vk=Sk`${0}
`),t):"",i?U(wk||(wk=Sk`${0}
`),i):"",s&&s.length?U(xk||(xk=Sk` ${0}
`),e):"",t?D(_k||(_k=kk`${0}
`),t):"",i?D(vk||(vk=kk`${0}
`),i):"",s&&s.length?D(wk||(wk=kk` ${0}
`),s):"",n?U(Yk||(Yk=gS`Operation ID: ${0}`),n):"")}_getUrlTemplate(){return U(Qk||(Qk=gS`${0}
`),s):"",n?D(Xk||(Xk=yS`Operation ID: ${0}`),n):"")}_getUrlTemplate(){return D(Yk||(Yk=yS`Set this redirect URI in OAuth 2.0 provider settings.
${0}
${0}
Set this redirect URI in OAuth 2.0 provider settings.
${0}
${0}
No headers are defined for this endpoint
`))}[Du](e,t){return U(XM||(XM=nR`No headers are defined for this endpoint
`))}[Hu](e,t){return D(ZM||(ZM=sR`This endpoint does not declare body properties
`)),0!==r.length&&i?U(iN||(iN=sN`This endpoint does not declare body properties
`)),0!==r.length&&i?D(tN||(tN=iN`