/*!-------------------------------------------------------- * Copyright (C) Microsoft Corporation. All rights reserved. *--------------------------------------------------------*/(async function(){performance.mark("code/didStartRenderer");const h=window.vscode,p=h.process;function y(i){performance.mark("code/willShowPartsSplash"),u(i),performance.mark("code/didShowPartsSplash")}function u(i){let o=i.partsSplash;o&&(i.autoDetectHighContrast&&i.colorScheme.highContrast?(i.colorScheme.dark&&o.baseTheme!=="hc-black"||!i.colorScheme.dark&&o.baseTheme!=="hc-light")&&(o=void 0):i.autoDetectColorScheme&&(i.colorScheme.dark&&o.baseTheme!=="vs-dark"||!i.colorScheme.dark&&o.baseTheme!=="vs")&&(o=void 0)),o&&i.extensionDevelopmentPath&&(o.layoutInfo=void 0);let l,n,d;o?(l=o.baseTheme,n=o.colorInfo.editorBackground,d=o.colorInfo.foreground):i.autoDetectHighContrast&&i.colorScheme.highContrast?i.colorScheme.dark?(l="hc-black",n="#000000",d="#FFFFFF"):(l="hc-light",n="#FFFFFF",d="#000000"):i.autoDetectColorScheme&&(i.colorScheme.dark?(l="vs-dark",n="#1E1E1E",d="#CCCCCC"):(l="vs",n="#FFFFFF",d="#000000"));const c=document.createElement("style");if(c.className="initialShellColors",window.document.head.appendChild(c),c.textContent=`body { background-color: ${n}; color: ${d}; margin: 0; padding: 0; }`,typeof o?.zoomLevel=="number"&&typeof h?.webFrame?.setZoomLevel=="function"&&h.webFrame.setZoomLevel(o.zoomLevel),o?.layoutInfo){const{layoutInfo:t,colorInfo:r}=o,a=document.createElement("div");if(a.id="monaco-parts-splash",a.className=l??"vs-dark",t.windowBorder&&r.windowBorder){const e=document.createElement("div");e.style.position="absolute",e.style.width="calc(100vw - 2px)",e.style.height="calc(100vh - 2px)",e.style.zIndex="1",e.style.border="1px solid var(--window-border-color)",e.style.setProperty("--window-border-color",r.windowBorder),t.windowBorderRadius&&(e.style.borderRadius=t.windowBorderRadius),a.appendChild(e)}if(t.auxiliaryBarWidth===Number.MAX_SAFE_INTEGER?t.auxiliaryBarWidth=window.innerWidth-t.activityBarWidth:t.auxiliaryBarWidth=Math.min(t.auxiliaryBarWidth,window.innerWidth-(t.activityBarWidth+t.editorPartMinWidth+t.sideBarWidth)),t.sideBarWidth=Math.min(t.sideBarWidth,window.innerWidth-(t.activityBarWidth+t.editorPartMinWidth+t.auxiliaryBarWidth)),t.titleBarHeight>0){const e=document.createElement("div");if(e.style.position="absolute",e.style.width="100%",e.style.height=`${t.titleBarHeight}px`,e.style.left="0",e.style.top="0",e.style.backgroundColor=`${r.titleBarBackground}`,e.style["-webkit-app-region"]="drag",a.appendChild(e),r.titleBarBorder){const s=document.createElement("div");s.style.position="absolute",s.style.width="100%",s.style.height="1px",s.style.left="0",s.style.bottom="0",s.style.borderBottom=`1px solid ${r.titleBarBorder}`,e.appendChild(s)}}if(t.activityBarWidth>0){const e=document.createElement("div");if(e.style.position="absolute",e.style.width=`${t.activityBarWidth}px`,e.style.height=`calc(100% - ${t.titleBarHeight+t.statusBarHeight}px)`,e.style.top=`${t.titleBarHeight}px`,t.sideBarSide==="left"?e.style.left="0":e.style.right="0",e.style.backgroundColor=`${r.activityBarBackground}`,a.appendChild(e),r.activityBarBorder){const s=document.createElement("div");s.style.position="absolute",s.style.width="1px",s.style.height="100%",s.style.top="0",t.sideBarSide==="left"?(s.style.right="0",s.style.borderRight=`1px solid ${r.activityBarBorder}`):(s.style.left="0",s.style.borderLeft=`1px solid ${r.activityBarBorder}`),e.appendChild(s)}}if(t.sideBarWidth>0){const e=document.createElement("div");if(e.style.position="absolute",e.style.width=`${t.sideBarWidth}px`,e.style.height=`calc(100% - ${t.titleBarHeight+t.statusBarHeight}px)`,e.style.top=`${t.titleBarHeight}px`,t.sideBarSide==="left"?e.style.left=`${t.activityBarWidth}px`:e.style.right=`${t.activityBarWidth}px`,e.style.backgroundColor=`${r.sideBarBackground}`,a.appendChild(e),r.sideBarBorder){const s=document.createElement("div");s.style.position="absolute",s.style.width="1px",s.style.height="100%",s.style.top="0",s.style.right="0",t.sideBarSide==="left"?s.style.borderRight=`1px solid ${r.sideBarBorder}`:(s.style.left="0",s.style.borderLeft=`1px solid ${r.sideBarBorder}`),e.appendChild(s)}}if(t.auxiliaryBarWidth>0){const e=document.createElement("div");if(e.style.position="absolute",e.style.width=`${t.auxiliaryBarWidth}px`,e.style.height=`calc(100% - ${t.titleBarHeight+t.statusBarHeight}px)`,e.style.top=`${t.titleBarHeight}px`,t.sideBarSide==="left"?e.style.right="0":e.style.left="0",e.style.backgroundColor=`${r.sideBarBackground}`,a.appendChild(e),r.sideBarBorder){const s=document.createElement("div");s.style.position="absolute",s.style.width="1px",s.style.height="100%",s.style.top="0",t.sideBarSide==="left"?(s.style.left="0",s.style.borderLeft=`1px solid ${r.sideBarBorder}`):(s.style.right="0",s.style.borderRight=`1px solid ${r.sideBarBorder}`),e.appendChild(s)}}if(t.statusBarHeight>0){const e=document.createElement("div");if(e.style.position="absolute",e.style.width="100%",e.style.height=`${t.statusBarHeight}px`,e.style.bottom="0",e.style.left="0",i.workspace&&r.statusBarBackground?e.style.backgroundColor=r.statusBarBackground:!i.workspace&&r.statusBarNoFolderBackground&&(e.style.backgroundColor=r.statusBarNoFolderBackground),a.appendChild(e),r.statusBarBorder){const s=document.createElement("div");s.style.position="absolute",s.style.width="100%",s.style.height="1px",s.style.top="0",s.style.borderTop=`1px solid ${r.statusBarBorder}`,e.appendChild(s)}}window.document.body.appendChild(a)}}async function m(i){const o=await f();i?.beforeImport?.(o);const{enableDeveloperKeybindings:l,removeDeveloperKeybindingsAfterLoad:n,developerDeveloperKeybindingsDisposable:d,forceDisableShowDevtoolsOnError:c}=b(o,i);w(o);const t=new URL(`${g(o.appRoot,{isWindows:p.platform==="win32",scheme:"vscode-file",fallbackAuthority:"vscode-app"})}/out/`);globalThis._VSCODE_FILE_ROOT=t.toString(),S(o,t);try{let r;p.env.VSCODE_DEV&&globalThis._VSCODE_USE_RELATIVE_IMPORTS?r="../../../workbench/workbench.desktop.main.js":r=new URL("vs/workbench/workbench.desktop.main.js",t).href;const a=await import(r);return d&&n&&d(),{result:a,configuration:o}}catch(r){throw B(r,l&&!c),r}}async function f(){const i=setTimeout(()=>{console.error("[resolve window config] Could not resolve window configuration within 10 seconds, but will continue to wait...")},1e4);performance.mark("code/willWaitForWindowConfig");const o=await h.context.resolveConfiguration();return performance.mark("code/didWaitForWindowConfig"),clearTimeout(i),o}function b(i,o){const{forceEnableDeveloperKeybindings:l,disallowReloadKeybinding:n,removeDeveloperKeybindingsAfterLoad:d,forceDisableShowDevtoolsOnError:c}=typeof o?.configureDeveloperSettings=="function"?o.configureDeveloperSettings(i):{forceEnableDeveloperKeybindings:!1,disallowReloadKeybinding:!1,removeDeveloperKeybindingsAfterLoad:!1,forceDisableShowDevtoolsOnError:!1},r=!!(!!p.env.VSCODE_DEV||l);let a;return r&&(a=v(n)),{enableDeveloperKeybindings:r,removeDeveloperKeybindingsAfterLoad:d,developerDeveloperKeybindingsDisposable:a,forceDisableShowDevtoolsOnError:c}}function v(i){const o=h.ipcRenderer,l=function(r){return[r.ctrlKey?"ctrl-":"",r.metaKey?"meta-":"",r.altKey?"alt-":"",r.shiftKey?"shift-":"",r.keyCode].join("")},n=p.platform==="darwin"?"meta-alt-73":"ctrl-shift-73",d="123",c=p.platform==="darwin"?"meta-82":"ctrl-82";let t=function(r){const a=l(r);a===n||a===d?o.send("vscode:toggleDevTools"):a===c&&!i&&o.send("vscode:reloadWindow")};return window.addEventListener("keydown",t),function(){t&&(window.removeEventListener("keydown",t),t=void 0)}}function w(i){globalThis._VSCODE_NLS_MESSAGES=i.nls.messages,globalThis._VSCODE_NLS_LANGUAGE=i.nls.language;let o=i.nls.language||"en";o==="zh-tw"?o="zh-Hant":o==="zh-cn"&&(o="zh-Hans"),window.document.documentElement.setAttribute("lang",o)}function B(i,o){o&&h.ipcRenderer.send("vscode:openDevTools"),console.error(`[uncaught exception]: ${i}`),i&&typeof i!="string"&&i.stack&&console.error(i.stack)}function g(i,o){let l=i.replace(/\\/g,"/");l.length>0&&l.charAt(0)!=="/"&&(l=`/${l}`);let n;return o.isWindows&&l.startsWith("//")?n=encodeURI(`${o.scheme||"file"}:${l}`):n=encodeURI(`${o.scheme||"file"}://${o.fallbackAuthority||""}${l}`),n.replace(/#/g,"%23")}function S(i,o){if(!globalThis._VSCODE_DISABLE_CSS_IMPORT_MAP&&Array.isArray(i.cssModules)&&i.cssModules.length>0){performance.mark("code/willAddCssLoader"),globalThis._VSCODE_CSS_LOAD=function(t){const r=document.createElement("link");r.setAttribute("rel","stylesheet"),r.setAttribute("type","text/css"),r.setAttribute("href",t),window.document.head.appendChild(r)};const l={imports:{}};for(const t of i.cssModules){const r=new URL(t,o).href,a=`globalThis._VSCODE_CSS_LOAD('${r}'); `,e=new Blob([a],{type:"application/javascript"});l.imports[r]=URL.createObjectURL(e)}const n=window.trustedTypes?.createPolicy("vscode-bootstrapImportMap",{createScript(t){return t}}),d=JSON.stringify(l,void 0,2),c=document.createElement("script");c.type="importmap",c.setAttribute("nonce","0c6a828f1297"),c.textContent=n?.createScript(d)??d,window.document.head.appendChild(c),performance.mark("code/didAddCssLoader")}}const{result:D,configuration:k}=await m({configureDeveloperSettings:function(i){return{forceDisableShowDevtoolsOnError:typeof i.extensionTestsPath=="string"||i["enable-smoke-test-driver"]===!0,forceEnableDeveloperKeybindings:Array.isArray(i.extensionDevelopmentPath)&&i.extensionDevelopmentPath.length>0,removeDeveloperKeybindingsAfterLoad:!0}},beforeImport:function(i){y(i),Object.defineProperty(window,"vscodeWindowId",{get:()=>i.windowId}),window.requestIdleCallback(()=>{const o=document.createElement("canvas");o.getContext("2d")?.clearRect(0,0,o.width,o.height),o.remove()},{timeout:50}),performance.mark("code/willLoadWorkbenchMain")}});performance.mark("code/didLoadWorkbenchMain"),D.main(k)})(); //# sourceMappingURL=https://main.vscode-cdn.net/sourcemaps/072586267e68ece9a47aa43f8c108e0dcbf44622/core/vs/code/electron-browser/workbench/workbench.js.map