function a(){let s=document.getElementById("vscode-markdown-preview-data");if(s){let e=s.getAttribute("data-strings");if(e)return JSON.parse(e)}throw new Error("Could not load strings")}var n=class{#e=!1;#s=!1;#t;#r;constructor(e){this.#r=e,document.addEventListener("securitypolicyviolation",()=>{this.#n()}),window.addEventListener("message",t=>{t?.data&&t.data.name==="vscode-did-block-svg"&&this.#n()})}setPoster(e){this.#t=e,this.#s&&this.#o()}#n(){this.#s=!0,this.#o()}#o(){let e=a(),t=this.#r.settings;if(this.#e||t.disableSecurityWarnings||!this.#t)return;this.#e=!0;let r=document.createElement("a");r.innerText=e.cspAlertMessageText,r.setAttribute("id","code-csp-warning"),r.setAttribute("title",e.cspAlertMessageTitle),r.setAttribute("role","button"),r.setAttribute("aria-label",e.cspAlertMessageLabel),r.onclick=()=>{this.#t.postMessage("showPreviewSecuritySelector",{source:t.source})},document.body.appendChild(r)}};var o=class{#e=[];#s=!1;#t;constructor(){let e=t=>{if(!(t instanceof Event))return;let r=t.target?.dataset.source;r&&this.#e.push(r)};window.addEventListener("DOMContentLoaded",()=>{for(let t of document.getElementsByClassName("code-user-style"))t.dataset.source&&(t.onerror=e)}),window.addEventListener("load",()=>{this.#e.length&&(this.#s=!0,this.#t?.postMessage("previewStyleLoadError",{unloadedStyles:this.#e}))})}setPoster(e){this.#t=e,this.#s&&e.postMessage("previewStyleLoadError",{unloadedStyles:this.#e})}};function l(s){let e=document.getElementById("vscode-markdown-preview-data");if(e){let t=e.getAttribute(s);if(t)return t}throw new Error(`Could not load data for ${s}`)}function d(s){return JSON.parse(l(s))}var i=class{#e=d("data-settings");get settings(){return this.#e}updateSettings(e){this.#e=e}};window.cspAlerter=new n(new i);window.styleLoadingMonitor=new o;
