UNPKG

@senx/discovery-code

Version:

Discovery Code Editor

1 lines 8.69 MB
var __extends=this&&this.__extends||function(){var e=function(t,n){e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)if(Object.prototype.hasOwnProperty.call(t,n))e[n]=t[n]};return e(t,n)};return function(t,n){if(typeof n!=="function"&&n!==null)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");e(t,n);function i(){this.constructor=t}t.prototype=n===null?Object.create(n):(i.prototype=n.prototype,new i)}}();var __assign=this&&this.__assign||function(){__assign=Object.assign||function(e){for(var t,n=1,i=arguments.length;n<i;n++){t=arguments[n];for(var r in t)if(Object.prototype.hasOwnProperty.call(t,r))e[r]=t[r]}return e};return __assign.apply(this,arguments)};var __awaiter=this&&this.__awaiter||function(e,t,n,i){function r(e){return e instanceof n?e:new n((function(t){t(e)}))}return new(n||(n=Promise))((function(n,a){function o(e){try{c(i.next(e))}catch(e){a(e)}}function s(e){try{c(i["throw"](e))}catch(e){a(e)}}function c(e){e.done?n(e.value):r(e.value).then(o,s)}c((i=i.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var n={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},i,r,a,o;return o={next:s(0),throw:s(1),return:s(2)},typeof Symbol==="function"&&(o[Symbol.iterator]=function(){return this}),o;function s(e){return function(t){return c([e,t])}}function c(s){if(i)throw new TypeError("Generator is already executing.");while(o&&(o=0,s[0]&&(n=0)),n)try{if(i=1,r&&(a=s[0]&2?r["return"]:s[0]?r["throw"]||((a=r["return"])&&a.call(r),0):r.next)&&!(a=a.call(r,s[1])).done)return a;if(r=0,a)s=[s[0]&2,a.value];switch(s[0]){case 0:case 1:a=s;break;case 4:n.label++;return{value:s[1],done:false};case 5:n.label++;r=s[1];s=[0];continue;case 7:s=n.ops.pop();n.trys.pop();continue;default:if(!(a=n.trys,a=a.length>0&&a[a.length-1])&&(s[0]===6||s[0]===2)){n=0;continue}if(s[0]===3&&(!a||s[1]>a[0]&&s[1]<a[3])){n.label=s[1];break}if(s[0]===6&&n.label<a[1]){n.label=a[1];a=s;break}if(a&&n.label<a[2]){n.label=a[2];n.ops.push(s);break}if(a[2])n.ops.pop();n.trys.pop();continue}s=t.call(e,n)}catch(e){s=[6,e];r=0}finally{i=a=0}if(s[0]&5)throw s[1];return{value:s[0]?s[1]:void 0,done:true}}};var __rest=this&&this.__rest||function(e,t){var n={};for(var i in e)if(Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0)n[i]=e[i];if(e!=null&&typeof Object.getOwnPropertySymbols==="function")for(var r=0,i=Object.getOwnPropertySymbols(e);r<i.length;r++){if(t.indexOf(i[r])<0&&Object.prototype.propertyIsEnumerable.call(e,i[r]))n[i[r]]=e[i[r]]}return n};var __asyncValues=this&&this.__asyncValues||function(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],n;return t?t.call(e):(e=typeof __values==="function"?__values(e):e[Symbol.iterator](),n={},i("next"),i("throw"),i("return"),n[Symbol.asyncIterator]=function(){return this},n);function i(t){n[t]=e[t]&&function(n){return new Promise((function(i,a){n=e[t](n),r(i,a,n.done,n.value)}))}}function r(e,t,n,i){Promise.resolve(i).then((function(t){e({value:t,done:n})}),t)}};var __spreadArray=this&&this.__spreadArray||function(e,t,n){if(n||arguments.length===2)for(var i=0,r=t.length,a;i<r;i++){if(a||!(i in t)){if(!a)a=Array.prototype.slice.call(t,0,i);a[i]=t[i]}}return e.concat(a||Array.prototype.slice.call(t))};var __values=this&&this.__values||function(e){var t=typeof Symbol==="function"&&Symbol.iterator,n=t&&e[t],i=0;if(n)return n.call(e);if(e&&typeof e.length==="number")return{next:function(){if(e&&i>=e.length)e=void 0;return{value:e&&e[i++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")};var _p,_q,_r,_s,_t,_u,_v,_w,_x,_y,_z,_0;import{r as registerInstance,c as createEvent,h as h$1,g as getElement}from"./index-165203c2.js";import{C as Config,U as Utils$1,W as WarpScriptParser,E as EditorConfig}from"./warpScriptParser-0c58c8fd.js";var Logger=function(){function e(e,t){if(t===void 0){t=false}this.isDebug=false;this.className=e.name;this.isDebug=t}e.prototype.setDebug=function(e){this.isDebug=e};e.prototype.log=function(e,t,n){var i=[];i.push("[".concat(this.className,"] ").concat(t.join(" - ")));i=i.concat(n);switch(e){case LEVEL.DEBUG:{if(this.isDebug){console.debug.apply(console,i)}break}case LEVEL.ERROR:{console.error.apply(console,i);break}case LEVEL.INFO:{console.log.apply(console,i);break}case LEVEL.WARN:{console.warn.apply(console,i);break}default:{if(this.isDebug){console.log.apply(console,i)}}}};e.prototype.debug=function(e){var t=[];for(var n=1;n<arguments.length;n++){t[n-1]=arguments[n]}this.log(LEVEL.DEBUG,e,t)};e.prototype.error=function(e){var t=[];for(var n=1;n<arguments.length;n++){t[n-1]=arguments[n]}this.log(LEVEL.ERROR,e,t)};e.prototype.warn=function(e){var t=[];for(var n=1;n<arguments.length;n++){t[n-1]=arguments[n]}this.log(LEVEL.WARN,e,t)};e.prototype.info=function(e){var t=[];for(var n=1;n<arguments.length;n++){t[n-1]=arguments[n]}this.log(LEVEL.INFO,e,t)};return e}();var LEVEL;(function(e){e[e["DEBUG"]=0]="DEBUG";e[e["ERROR"]=1]="ERROR";e[e["WARN"]=2]="WARN";e[e["INFO"]=3]="INFO"})(LEVEL||(LEVEL={}));function tail(e,t){if(t===void 0){t=0}return e[e.length-(1+t)]}function tail2(e){if(e.length===0){throw new Error("Invalid tail call")}return[e.slice(0,e.length-1),e[e.length-1]]}function equals$2(e,t,n){if(n===void 0){n=function(e,t){return e===t}}if(e===t){return true}if(!e||!t){return false}if(e.length!==t.length){return false}for(var i=0,r=e.length;i<r;i++){if(!n(e[i],t[i])){return false}}return true}function removeFastWithoutKeepingOrder(e,t){var n=e.length-1;if(t<n){e[t]=e[n]}e.pop()}function binarySearch(e,t,n){return binarySearch2(e.length,(function(i){return n(e[i],t)}))}function binarySearch2(e,t){var n=0,i=e-1;while(n<=i){var r=(n+i)/2|0;var a=t(r);if(a<0){n=r+1}else if(a>0){i=r-1}else{return r}}return-(n+1)}function quickSelect(e,t,n){e=e|0;if(e>=t.length){throw new TypeError("invalid index")}var i=t[Math.floor(t.length*Math.random())];var r=[];var a=[];var o=[];for(var s=0,c=t;s<c.length;s++){var l=c[s];var u=n(l,i);if(u<0){r.push(l)}else if(u>0){a.push(l)}else{o.push(l)}}if(e<r.length){return quickSelect(e,r,n)}else if(e<r.length+o.length){return o[0]}else{return quickSelect(e-(r.length+o.length),a,n)}}function groupBy(e,t){var n=[];var i=undefined;for(var r=0,a=e.slice(0).sort(t);r<a.length;r++){var o=a[r];if(!i||t(i[0],o)!==0){i=[o];n.push(i)}else{i.push(o)}}return n}function groupAdjacentBy(e,t){var n,i,r,a,o;return __generator(this,(function(s){switch(s.label){case 0:r=0,a=e;s.label=1;case 1:if(!(r<a.length))return[3,7];o=a[r];if(!(i!==undefined&&t(i,o)))return[3,2];n.push(o);return[3,5];case 2:if(!n)return[3,4];return[4,n];case 3:s.sent();s.label=4;case 4:n=[o];s.label=5;case 5:i=o;s.label=6;case 6:r++;return[3,1];case 7:if(!n)return[3,9];return[4,n];case 8:s.sent();s.label=9;case 9:return[2]}}))}function forEachAdjacent(e,t){for(var n=0;n<=e.length;n++){t(n===0?undefined:e[n-1],n===e.length?undefined:e[n])}}function forEachWithNeighbors(e,t){for(var n=0;n<e.length;n++){t(n===0?undefined:e[n-1],e[n],n+1===e.length?undefined:e[n+1])}}function coalesce(e){return e.filter((function(e){return!!e}))}function coalesceInPlace(e){var t=0;for(var n=0;n<e.length;n++){if(!!e[n]){e[t]=e[n];t+=1}}e.length=t}function isFalsyOrEmpty(e){return!Array.isArray(e)||e.length===0}function isNonEmptyArray(e){return Array.isArray(e)&&e.length>0}function distinct(e,t){if(t===void 0){t=function(e){return e}}var n=new Set;return e.filter((function(e){var i=t(e);if(n.has(i)){return false}n.add(i);return true}))}function firstOrDefault(e,t){return e.length>0?e[0]:t}function range(e,t){var n=typeof t==="number"?e:0;if(typeof t==="number"){n=e}else{n=0;t=e}var i=[];if(n<=t){for(var r=n;r<t;r++){i.push(r)}}else{for(var r=n;r>t;r--){i.push(r)}}return i}function arrayInsert(e,t,n){var i=e.slice(0,t);var r=e.slice(t);return i.concat(n,r)}function pushToStart(e,t){var n=e.indexOf(t);if(n>-1){e.splice(n,1);e.unshift(t)}}function pushToEnd(e,t){var n=e.indexOf(t);if(n>-1){e.splice(n,1);e.push(t)}}function pushMany(e,t){for(var n=0,i=t;n<i.length;n++){var r=i[n];e.push(r)}}function asArray(e){return Array.isArray(e)?e:[e]}function insertInto(e,t,n){var i=getActualStartIndex(e,t);var r=e.length;var a=n.length;e.length=r+a;for(var o=r-1;o>=i;o--){e[o+a]=e[o]}for(var o=0;o<a;o++){e[o+i]=n[o]}}function splice$1(e,t,n,i){var r=getActualStartIndex(e,t);var a=e.splice(r,n);if(a===undefined){a=[]}insertInto(e,r,i);return a}function getActualStartIndex(e,t){return t<0?Math.max(t+e.length,0):Math.min(t,e.length)}var CompareResult;(function(e){function t(e){return e<0}e.isLessThan=t;function n(e){return e<=0}e.isLessThanOrEqual=n;function i(e){return e>0}e.isGreaterThan=i;function r(e){return e===0}e.isNeitherLessOrGreaterThan=r;e.greaterThan=1;e.lessThan=-1;e.neitherLessOrGreaterThan=0})(CompareResult||(CompareResult={}));function compareBy(e,t){return function(n,i){return t(e(n),e(i))}}function tieBreakComparators(){var e=[];for(var t=0;t<arguments.length;t++){e[t]=arguments[t]}return function(t,n){for(var i=0,r=e;i<r.length;i++){var a=r[i];var o=a(t,n);if(!CompareResult.isNeitherLessOrGreaterThan(o)){return o}}return CompareResult.neitherLessOrGreaterThan}}var numberComparator=function(e,t){return e-t};var booleanComparator=function(e,t){return numberComparator(e?1:0,t?1:0)};function reverseOrder(e){return function(t,n){return-e(t,n)}}var ArrayQueue=function(){function e(e){this.items=e;this.firstIdx=0;this.lastIdx=this.items.length-1}Object.defineProperty(e.prototype,"length",{get:function(){return this.lastIdx-this.firstIdx+1},enumerable:false,configurable:true});e.prototype.takeWhile=function(e){var t=this.firstIdx;while(t<this.items.length&&e(this.items[t])){t++}var n=t===this.firstIdx?null:this.items.slice(this.firstIdx,t);this.firstIdx=t;return n};e.prototype.takeFromEndWhile=function(e){var t=this.lastIdx;while(t>=0&&e(this.items[t])){t--}var n=t===this.lastIdx?null:this.items.slice(t+1,this.lastIdx+1);this.lastIdx=t;return n};e.prototype.peek=function(){if(this.length===0){return undefined}return this.items[this.firstIdx]};e.prototype.dequeue=function(){var e=this.items[this.firstIdx];this.firstIdx++;return e};e.prototype.takeCount=function(e){var t=this.items.slice(this.firstIdx,this.firstIdx+e);this.firstIdx+=e;return t};return e}();var CallbackIterable=function(){function e(e){this.iterate=e}e.prototype.toArray=function(){var e=[];this.iterate((function(t){e.push(t);return true}));return e};e.prototype.filter=function(t){var n=this;return new e((function(e){return n.iterate((function(n){return t(n)?e(n):true}))}))};e.prototype.map=function(t){var n=this;return new e((function(e){return n.iterate((function(n){return e(t(n))}))}))};e.prototype.findLast=function(e){var t;this.iterate((function(n){if(e(n)){t=n}return true}));return t};e.prototype.findLastMaxBy=function(e){var t;var n=true;this.iterate((function(i){if(n||CompareResult.isGreaterThan(e(i,t))){n=false;t=i}return true}));return t};return e}();CallbackIterable.empty=new CallbackIterable((function(e){}));function isString$2(e){return typeof e==="string"}function isObject(e){return typeof e==="object"&&e!==null&&!Array.isArray(e)&&!(e instanceof RegExp)&&!(e instanceof Date)}function isTypedArray(e){var t=Object.getPrototypeOf(Uint8Array);return typeof e==="object"&&e instanceof t}function isNumber$1(e){return typeof e==="number"&&!isNaN(e)}function isIterable(e){return!!e&&typeof e[Symbol.iterator]==="function"}function isBoolean(e){return e===true||e===false}function isUndefined(e){return typeof e==="undefined"}function isDefined(e){return!isUndefinedOrNull(e)}function isUndefinedOrNull(e){return isUndefined(e)||e===null}function assertType(e,t){if(!e){throw new Error(t?"Unexpected type, expected '".concat(t,"'"):"Unexpected type")}}function assertIsDefined(e){if(isUndefinedOrNull(e)){throw new Error("Assertion Failed: argument is undefined or null")}return e}function isFunction(e){return typeof e==="function"}function validateConstraints(e,t){var n=Math.min(e.length,t.length);for(var i=0;i<n;i++){validateConstraint(e[i],t[i])}}function validateConstraint(e,t){if(isString$2(t)){if(typeof e!==t){throw new Error("argument does not match constraint: typeof ".concat(t))}}else if(isFunction(t)){try{if(e instanceof t){return}}catch(e){}if(!isUndefinedOrNull(e)&&e.constructor===t){return}if(t.length===1&&t.call(undefined,e)===true){return}throw new Error("argument does not match one of these constraints: arg instanceof constraint, arg.constructor === constraint, nor constraint(arg) === true")}}function deepClone(e){if(!e||typeof e!=="object"){return e}if(e instanceof RegExp){return e}var t=Array.isArray(e)?[]:{};Object.entries(e).forEach((function(e){var n=e[0],i=e[1];t[n]=i&&typeof i==="object"?deepClone(i):i}));return t}function deepFreeze(e){if(!e||typeof e!=="object"){return e}var t=[e];while(t.length>0){var n=t.shift();Object.freeze(n);for(var i in n){if(_hasOwnProperty.call(n,i)){var r=n[i];if(typeof r==="object"&&!Object.isFrozen(r)&&!isTypedArray(r)){t.push(r)}}}}return e}var _hasOwnProperty=Object.prototype.hasOwnProperty;function cloneAndChange(e,t){return _cloneAndChange(e,t,new Set)}function _cloneAndChange(e,t,n){if(isUndefinedOrNull(e)){return e}var i=t(e);if(typeof i!=="undefined"){return i}if(Array.isArray(e)){var r=[];for(var a=0,o=e;a<o.length;a++){var s=o[a];r.push(_cloneAndChange(s,t,n))}return r}if(isObject(e)){if(n.has(e)){throw new Error("Cannot clone recursive data-structure")}n.add(e);var c={};for(var l in e){if(_hasOwnProperty.call(e,l)){c[l]=_cloneAndChange(e[l],t,n)}}n.delete(e);return c}return e}function mixin(e,t,n){if(n===void 0){n=true}if(!isObject(e)){return t}if(isObject(t)){Object.keys(t).forEach((function(i){if(i in e){if(n){if(isObject(e[i])&&isObject(t[i])){mixin(e[i],t[i],n)}else{e[i]=t[i]}}}else{e[i]=t[i]}}))}return e}function equals$1(e,t){if(e===t){return true}if(e===null||e===undefined||t===null||t===undefined){return false}if(typeof e!==typeof t){return false}if(typeof e!=="object"){return false}if(Array.isArray(e)!==Array.isArray(t)){return false}var n;var i;if(Array.isArray(e)){if(e.length!==t.length){return false}for(n=0;n<e.length;n++){if(!equals$1(e[n],t[n])){return false}}}else{var r=[];for(i in e){r.push(i)}r.sort();var a=[];for(i in t){a.push(i)}a.sort();if(!equals$1(r,a)){return false}for(n=0;n<r.length;n++){if(!equals$1(e[r[n]],t[r[n]])){return false}}}return true}function getAllPropertyNames(e){var t=[];while(Object.prototype!==e){t=t.concat(Object.getOwnPropertyNames(e));e=Object.getPrototypeOf(e)}return t}function getAllMethodNames(e){var t=[];for(var n=0,i=getAllPropertyNames(e);n<i.length;n++){var r=i[n];if(typeof e[r]==="function"){t.push(r)}}return t}function createProxyObject$1(e,t){var n=function(e){return function(){var n=Array.prototype.slice.call(arguments,0);return t(e,n)}};var i={};for(var r=0,a=e;r<a.length;r++){var o=a[r];i[o]=n(o)}return i}var global$2=typeof global!=="undefined"?global:typeof self!=="undefined"?self:typeof window!=="undefined"?window:{};function defaultSetTimout(){throw new Error("setTimeout has not been defined")}function defaultClearTimeout(){throw new Error("clearTimeout has not been defined")}var cachedSetTimeout=defaultSetTimout;var cachedClearTimeout=defaultClearTimeout;if(typeof global$2.setTimeout==="function"){cachedSetTimeout=setTimeout}if(typeof global$2.clearTimeout==="function"){cachedClearTimeout=clearTimeout}function runTimeout(e){if(cachedSetTimeout===setTimeout){return setTimeout(e,0)}if((cachedSetTimeout===defaultSetTimout||!cachedSetTimeout)&&setTimeout){cachedSetTimeout=setTimeout;return setTimeout(e,0)}try{return cachedSetTimeout(e,0)}catch(t){try{return cachedSetTimeout.call(null,e,0)}catch(t){return cachedSetTimeout.call(this,e,0)}}}function runClearTimeout(e){if(cachedClearTimeout===clearTimeout){return clearTimeout(e)}if((cachedClearTimeout===defaultClearTimeout||!cachedClearTimeout)&&clearTimeout){cachedClearTimeout=clearTimeout;return clearTimeout(e)}try{return cachedClearTimeout(e)}catch(t){try{return cachedClearTimeout.call(null,e)}catch(t){return cachedClearTimeout.call(this,e)}}}var queue=[];var draining=false;var currentQueue;var queueIndex=-1;function cleanUpNextTick(){if(!draining||!currentQueue){return}draining=false;if(currentQueue.length){queue=currentQueue.concat(queue)}else{queueIndex=-1}if(queue.length){drainQueue()}}function drainQueue(){if(draining){return}var e=runTimeout(cleanUpNextTick);draining=true;var t=queue.length;while(t){currentQueue=queue;queue=[];while(++queueIndex<t){if(currentQueue){currentQueue[queueIndex].run()}}queueIndex=-1;t=queue.length}currentQueue=null;draining=false;runClearTimeout(e)}function nextTick(e){var t=new Array(arguments.length-1);if(arguments.length>1){for(var n=1;n<arguments.length;n++){t[n-1]=arguments[n]}}queue.push(new Item(e,t));if(queue.length===1&&!draining){runTimeout(drainQueue)}}function Item(e,t){this.fun=e;this.array=t}Item.prototype.run=function(){this.fun.apply(null,this.array)};var title="browser";var platform$1="browser";var browser=true;var env$1={};var argv=[];var version="";var versions={};var release={};var config={};function noop(){}var on=noop;var addListener=noop;var once$1=noop;var off=noop;var removeListener=noop;var removeAllListeners=noop;var emit=noop;function binding(e){throw new Error("process.binding is not supported")}function cwd$1(){return"/"}function chdir(e){throw new Error("process.chdir is not supported")}function umask(){return 0}var performance$1=global$2.performance||{};var performanceNow=performance$1.now||performance$1.mozNow||performance$1.msNow||performance$1.oNow||performance$1.webkitNow||function(){return(new Date).getTime()};function hrtime(e){var t=performanceNow.call(performance$1)*.001;var n=Math.floor(t);var i=Math.floor(t%1*1e9);if(e){n=n-e[0];i=i-e[1];if(i<0){n--;i+=1e9}}return[n,i]}var startTime=new Date;function uptime(){var e=new Date;var t=e-startTime;return t/1e3}var browser$1={nextTick:nextTick,title:title,browser:browser,env:env$1,argv:argv,version:version,versions:versions,on:on,addListener:addListener,once:once$1,off:off,removeListener:removeListener,removeAllListeners:removeAllListeners,emit:emit,binding:binding,cwd:cwd$1,chdir:chdir,umask:umask,hrtime:hrtime,platform:platform$1,release:release,config:config,uptime:uptime};var process=browser$1;var isPseudo=typeof document!=="undefined"&&document.location&&document.location.hash.indexOf("pseudo=true")>=0;function _format$1(e,t){var n;if(t.length===0){n=e}else{n=e.replace(/\{(\d+)\}/g,(function(e,n){var i=n[0];var r=t[i];var a=e;if(typeof r==="string"){a=r}else if(typeof r==="number"||typeof r==="boolean"||r===void 0||r===null){a=String(r)}return a}))}if(isPseudo){n="["+n.replace(/[aouei]/g,"$&$&")+"]"}return n}function localize(e,t){var n=[];for(var i=2;i<arguments.length;i++){n[i-2]=arguments[i]}return _format$1(t,n)}function localize2(e,t){var n=[];for(var i=2;i<arguments.length;i++){n[i-2]=arguments[i]}var r=_format$1(t,n);return{value:r,original:r}}function getConfiguredDefaultLocale(e){return undefined}var _a$4;var LANGUAGE_DEFAULT="en";var _isWindows=false;var _isMacintosh=false;var _isLinux=false;var _isNative=false;var _isWeb=false;var _isIOS=false;var _isMobile=false;var _locale=undefined;var _language=LANGUAGE_DEFAULT;var _userAgent=undefined;var $globalThis=globalThis;var nodeProcess=undefined;if(typeof $globalThis.vscode!=="undefined"&&typeof $globalThis.vscode.process!=="undefined"){nodeProcess=$globalThis.vscode.process}else if(typeof process!=="undefined"){nodeProcess=process}var isElectronProcess=typeof((_a$4=nodeProcess===null||nodeProcess===void 0?void 0:nodeProcess.versions)===null||_a$4===void 0?void 0:_a$4.electron)==="string";var isElectronRenderer=isElectronProcess&&(nodeProcess===null||nodeProcess===void 0?void 0:nodeProcess.type)==="renderer";if(typeof navigator==="object"&&!isElectronRenderer){_userAgent=navigator.userAgent;_isWindows=_userAgent.indexOf("Windows")>=0;_isMacintosh=_userAgent.indexOf("Macintosh")>=0;_isIOS=(_userAgent.indexOf("Macintosh")>=0||_userAgent.indexOf("iPad")>=0||_userAgent.indexOf("iPhone")>=0)&&!!navigator.maxTouchPoints&&navigator.maxTouchPoints>0;_isLinux=_userAgent.indexOf("Linux")>=0;_isMobile=(_userAgent===null||_userAgent===void 0?void 0:_userAgent.indexOf("Mobi"))>=0;_isWeb=true;getConfiguredDefaultLocale(localize({key:"ensureLoaderPluginIsLoaded",comment:["{Locked}"]},"_"));_locale=LANGUAGE_DEFAULT;_language=_locale}else if(typeof nodeProcess==="object"){_isWindows=nodeProcess.platform==="win32";_isMacintosh=nodeProcess.platform==="darwin";_isLinux=nodeProcess.platform==="linux";_locale=LANGUAGE_DEFAULT;_language=LANGUAGE_DEFAULT;var rawNlsConfig=nodeProcess.env["VSCODE_NLS_CONFIG"];if(rawNlsConfig){try{var nlsConfig=JSON.parse(rawNlsConfig);var resolved=nlsConfig.availableLanguages["*"];_locale=nlsConfig.locale;_language=resolved?resolved:LANGUAGE_DEFAULT}catch(e){}}_isNative=true}else{console.error("Unable to resolve platform.")}var isWindows=_isWindows;var isMacintosh=_isMacintosh;var isLinux=_isLinux;var isNative=_isNative;var isWeb=_isWeb;var isWebWorker=_isWeb&&typeof $globalThis.importScripts==="function";var webWorkerOrigin=isWebWorker?$globalThis.origin:undefined;var isIOS=_isIOS;var isMobile=_isMobile;var userAgent$1=_userAgent;var language=_language;var setTimeout0IsFaster=typeof $globalThis.postMessage==="function"&&!$globalThis.importScripts;var setTimeout0=function(){if(setTimeout0IsFaster){var e=[];$globalThis.addEventListener("message",(function(t){if(t.data&&t.data.vscodeScheduleAsyncWork){for(var n=0,i=e.length;n<i;n++){var r=e[n];if(r.id===t.data.vscodeScheduleAsyncWork){e.splice(n,1);r.callback();return}}}}));var t=0;return function(n){var i=++t;e.push({id:i,callback:n});$globalThis.postMessage({vscodeScheduleAsyncWork:i},"*")}}return function(e){return setTimeout(e)}}();var OS=_isMacintosh||_isIOS?2:_isWindows?1:3;var _isLittleEndian=true;var _isLittleEndianComputed=false;function isLittleEndian(){if(!_isLittleEndianComputed){_isLittleEndianComputed=true;var e=new Uint8Array(2);e[0]=1;e[1]=2;var t=new Uint16Array(e.buffer);_isLittleEndian=t[0]===(2<<8)+1}return _isLittleEndian}var isChrome$1=!!(userAgent$1&&userAgent$1.indexOf("Chrome")>=0);var isFirefox$1=!!(userAgent$1&&userAgent$1.indexOf("Firefox")>=0);var isSafari$1=!!(!isChrome$1&&(userAgent$1&&userAgent$1.indexOf("Safari")>=0));var isEdge=!!(userAgent$1&&userAgent$1.indexOf("Edg/")>=0);!!(userAgent$1&&userAgent$1.indexOf("Android")>=0);var EDITOR_MODEL_DEFAULTS={tabSize:4,indentSize:4,insertSpaces:true,detectIndentation:true,trimAutoWhitespace:true,largeFileOptimizations:true,bracketPairColorizationOptions:{enabled:true,independentColorPoolPerBracketType:false}};var Iterable;(function(e){function t(e){return e&&typeof e==="object"&&typeof e[Symbol.iterator]==="function"}e.is=t;var n=Object.freeze([]);function i(){return n}e.empty=i;function r(e){return __generator(this,(function(t){switch(t.label){case 0:return[4,e];case 1:t.sent();return[2]}}))}e.single=r;function a(e){if(t(e)){return e}else{return r(e)}}e.wrap=a;function o(e){return e||n}e.from=o;function s(e){var t;return __generator(this,(function(n){switch(n.label){case 0:t=e.length-1;n.label=1;case 1:if(!(t>=0))return[3,4];return[4,e[t]];case 2:n.sent();n.label=3;case 3:t--;return[3,1];case 4:return[2]}}))}e.reverse=s;function c(e){return!e||e[Symbol.iterator]().next().done===true}e.isEmpty=c;function l(e){return e[Symbol.iterator]().next().value}e.first=l;function u(e,t){for(var n=0,i=e;n<i.length;n++){var r=i[n];if(t(r)){return true}}return false}e.some=u;function h(e,t){for(var n=0,i=e;n<i.length;n++){var r=i[n];if(t(r)){return r}}return undefined}e.find=h;function d(e,t){var n,i,r;return __generator(this,(function(a){switch(a.label){case 0:n=0,i=e;a.label=1;case 1:if(!(n<i.length))return[3,4];r=i[n];if(!t(r))return[3,3];return[4,r];case 2:a.sent();a.label=3;case 3:n++;return[3,1];case 4:return[2]}}))}e.filter=d;function p(e,t){var n,i,r,a;return __generator(this,(function(o){switch(o.label){case 0:n=0;i=0,r=e;o.label=1;case 1:if(!(i<r.length))return[3,4];a=r[i];return[4,t(a,n++)];case 2:o.sent();o.label=3;case 3:i++;return[3,1];case 4:return[2]}}))}e.map=p;function f(){var e,t,n,i;var r=[];for(e=0;e<arguments.length;e++){r[e]=arguments[e]}return __generator(this,(function(e){switch(e.label){case 0:t=0,n=r;e.label=1;case 1:if(!(t<n.length))return[3,4];i=n[t];return[5,__values(i)];case 2:e.sent();e.label=3;case 3:t++;return[3,1];case 4:return[2]}}))}e.concat=f;function m(e,t,n){var i=n;for(var r=0,a=e;r<a.length;r++){var o=a[r];i=t(i,o)}return i}e.reduce=m;function g(e,t,n){if(n===void 0){n=e.length}return __generator(this,(function(i){switch(i.label){case 0:if(t<0){t+=e.length}if(n<0){n+=e.length}else if(n>e.length){n=e.length}i.label=1;case 1:if(!(t<n))return[3,4];return[4,e[t]];case 2:i.sent();i.label=3;case 3:t++;return[3,1];case 4:return[2]}}))}e.slice=g;function v(t,n){var i;if(n===void 0){n=Number.POSITIVE_INFINITY}var r=[];if(n===0){return[r,t]}var a=t[Symbol.iterator]();for(var o=0;o<n;o++){var s=a.next();if(s.done){return[r,e.empty()]}r.push(s.value)}return[r,(i={},i[Symbol.iterator]=function(){return a},i)]}e.consume=v})(Iterable||(Iterable={}));var Node$2=function(){function e(t){this.element=t;this.next=e.Undefined;this.prev=e.Undefined}return e}();Node$2.Undefined=new Node$2(undefined);var LinkedList=function(){function e(){this._first=Node$2.Undefined;this._last=Node$2.Undefined;this._size=0}Object.defineProperty(e.prototype,"size",{get:function(){return this._size},enumerable:false,configurable:true});e.prototype.isEmpty=function(){return this._first===Node$2.Undefined};e.prototype.clear=function(){var e=this._first;while(e!==Node$2.Undefined){var t=e.next;e.prev=Node$2.Undefined;e.next=Node$2.Undefined;e=t}this._first=Node$2.Undefined;this._last=Node$2.Undefined;this._size=0};e.prototype.unshift=function(e){return this._insert(e,false)};e.prototype.push=function(e){return this._insert(e,true)};e.prototype._insert=function(e,t){var n=this;var i=new Node$2(e);if(this._first===Node$2.Undefined){this._first=i;this._last=i}else if(t){var r=this._last;this._last=i;i.prev=r;r.next=i}else{var a=this._first;this._first=i;i.next=a;a.prev=i}this._size+=1;var o=false;return function(){if(!o){o=true;n._remove(i)}}};e.prototype.shift=function(){if(this._first===Node$2.Undefined){return undefined}else{var e=this._first.element;this._remove(this._first);return e}};e.prototype.pop=function(){if(this._last===Node$2.Undefined){return undefined}else{var e=this._last.element;this._remove(this._last);return e}};e.prototype._remove=function(e){if(e.prev!==Node$2.Undefined&&e.next!==Node$2.Undefined){var t=e.prev;t.next=e.next;e.next.prev=t}else if(e.prev===Node$2.Undefined&&e.next===Node$2.Undefined){this._first=Node$2.Undefined;this._last=Node$2.Undefined}else if(e.next===Node$2.Undefined){this._last=this._last.prev;this._last.next=Node$2.Undefined}else if(e.prev===Node$2.Undefined){this._first=this._first.next;this._first.prev=Node$2.Undefined}this._size-=1};e.prototype[Symbol.iterator]=function(){var e;return __generator(this,(function(t){switch(t.label){case 0:e=this._first;t.label=1;case 1:if(!(e!==Node$2.Undefined))return[3,3];return[4,e.element];case 2:t.sent();e=e.next;return[3,1];case 3:return[2]}}))};return e}();var USUAL_WORD_SEPARATORS="`~!@#$%^&*()-=+[{]}\\|;:'\",.<>/?";function createWordRegExp(e){if(e===void 0){e=""}var t="(-?\\d*\\.\\d\\w*)|([^";for(var n=0,i=USUAL_WORD_SEPARATORS;n<i.length;n++){var r=i[n];if(e.indexOf(r)>=0){continue}t+="\\"+r}t+="\\s]+)";return new RegExp(t,"g")}var DEFAULT_WORD_REGEXP=createWordRegExp();function ensureValidWordDefinition(e){var t=DEFAULT_WORD_REGEXP;if(e&&e instanceof RegExp){if(!e.global){var n="g";if(e.ignoreCase){n+="i"}if(e.multiline){n+="m"}if(e.unicode){n+="u"}t=new RegExp(e.source,n)}else{t=e}}t.lastIndex=0;return t}var _defaultConfig=new LinkedList;_defaultConfig.unshift({maxLen:1e3,windowSize:15,timeBudget:150});function getWordAtText(e,t,n,i,r){t=ensureValidWordDefinition(t);if(!r){r=Iterable.first(_defaultConfig)}if(n.length>r.maxLen){var a=e-r.maxLen/2;if(a<0){a=0}else{i+=a}n=n.substring(a,e+r.maxLen/2);return getWordAtText(e,t,n,i,r)}var o=Date.now();var s=e-1-i;var c=-1;var l=null;for(var u=1;;u++){if(Date.now()-o>=r.timeBudget){break}var h=s-r.windowSize*u;t.lastIndex=Math.max(0,h);var d=_findRegexMatchEnclosingPosition(t,n,s,c);if(!d&&l){break}l=d;if(h<=0){break}c=h}if(l){var p={word:l[0],startColumn:i+1+l.index,endColumn:i+1+l.index+l[0].length};t.lastIndex=0;return p}return null}function _findRegexMatchEnclosingPosition(e,t,n,i){var r;while(r=e.exec(t)){var a=r.index||0;if(a<=n&&e.lastIndex>=n){return r}else if(i>0&&a>i){return null}}return null}var MINIMAP_GUTTER_WIDTH=8;var ConfigurationChangedEvent=function(){function e(e){this._values=e}e.prototype.hasChanged=function(e){return this._values[e]};return e}();var ComputeOptionsMemory=function(){function e(){this.stableMinimapLayoutInput=null;this.stableFitMaxMinimapScale=0;this.stableFitRemainingWidth=0}return e}();var BaseEditorOption=function(){function e(e,t,n,i){this.id=e;this.name=t;this.defaultValue=n;this.schema=i}e.prototype.applyUpdate=function(e,t){return applyUpdate(e,t)};e.prototype.compute=function(e,t,n){return n};return e}();var ApplyUpdateResult=function(){function e(e,t){this.newValue=e;this.didChange=t}return e}();function applyUpdate(e,t){if(typeof e!=="object"||typeof t!=="object"||!e||!t){return new ApplyUpdateResult(t,e!==t)}if(Array.isArray(e)||Array.isArray(t)){var n=Array.isArray(e)&&Array.isArray(t)&&equals$2(e,t);return new ApplyUpdateResult(t,!n)}var i=false;for(var r in t){if(t.hasOwnProperty(r)){var a=applyUpdate(e[r],t[r]);if(a.didChange){e[r]=a.newValue;i=true}}}return new ApplyUpdateResult(e,i)}var ComputedEditorOption=function(){function e(e){this.schema=undefined;this.id=e;this.name="_never_";this.defaultValue=undefined}e.prototype.applyUpdate=function(e,t){return applyUpdate(e,t)};e.prototype.validate=function(e){return this.defaultValue};return e}();var SimpleEditorOption=function(){function e(e,t,n,i){this.id=e;this.name=t;this.defaultValue=n;this.schema=i}e.prototype.applyUpdate=function(e,t){return applyUpdate(e,t)};e.prototype.validate=function(e){if(typeof e==="undefined"){return this.defaultValue}return e};e.prototype.compute=function(e,t,n){return n};return e}();function boolean(e,t){if(typeof e==="undefined"){return t}if(e==="false"){return false}return Boolean(e)}var EditorBooleanOption=function(e){__extends(t,e);function t(t,n,i,r){if(r===void 0){r=undefined}if(typeof r!=="undefined"){r.type="boolean";r.default=i}return e.call(this,t,n,i,r)||this}t.prototype.validate=function(e){return boolean(e,this.defaultValue)};return t}(SimpleEditorOption);function clampedInt(e,t,n,i){if(typeof e==="undefined"){return t}var r=parseInt(e,10);if(isNaN(r)){return t}r=Math.max(n,r);r=Math.min(i,r);return r|0}var EditorIntOption=function(e){__extends(t,e);function t(t,n,i,r,a,o){if(o===void 0){o=undefined}var s=this;if(typeof o!=="undefined"){o.type="integer";o.default=i;o.minimum=r;o.maximum=a}s=e.call(this,t,n,i,o)||this;s.minimum=r;s.maximum=a;return s}t.clampedInt=function(e,t,n,i){return clampedInt(e,t,n,i)};t.prototype.validate=function(e){return t.clampedInt(e,this.defaultValue,this.minimum,this.maximum)};return t}(SimpleEditorOption);function clampedFloat(e,t,n,i){if(typeof e==="undefined"){return t}var r=EditorFloatOption.float(e,t);return EditorFloatOption.clamp(r,n,i)}var EditorFloatOption=function(e){__extends(t,e);function t(t,n,i,r,a){var o=this;if(typeof a!=="undefined"){a.type="number";a.default=i}o=e.call(this,t,n,i,a)||this;o.validationFn=r;return o}t.clamp=function(e,t,n){if(e<t){return t}if(e>n){return n}return e};t.float=function(e,t){if(typeof e==="number"){return e}if(typeof e==="undefined"){return t}var n=parseFloat(e);return isNaN(n)?t:n};t.prototype.validate=function(e){return this.validationFn(t.float(e,this.defaultValue))};return t}(SimpleEditorOption);var EditorStringOption=function(e){__extends(t,e);function t(t,n,i,r){if(r===void 0){r=undefined}if(typeof r!=="undefined"){r.type="string";r.default=i}return e.call(this,t,n,i,r)||this}t.string=function(e,t){if(typeof e!=="string"){return t}return e};t.prototype.validate=function(e){return t.string(e,this.defaultValue)};return t}(SimpleEditorOption);function stringSet(e,t,n,i){if(typeof e!=="string"){return t}if(i&&e in i){return i[e]}if(n.indexOf(e)===-1){return t}return e}var EditorStringEnumOption=function(e){__extends(t,e);function t(t,n,i,r,a){if(a===void 0){a=undefined}var o=this;if(typeof a!=="undefined"){a.type="string";a.enum=r;a.default=i}o=e.call(this,t,n,i,a)||this;o._allowedValues=r;return o}t.prototype.validate=function(e){return stringSet(e,this.defaultValue,this._allowedValues)};return t}(SimpleEditorOption);var EditorEnumOption=function(e){__extends(t,e);function t(t,n,i,r,a,o,s){if(s===void 0){s=undefined}var c=this;if(typeof s!=="undefined"){s.type="string";s.enum=a;s.default=r}c=e.call(this,t,n,i,s)||this;c._allowedValues=a;c._convert=o;return c}t.prototype.validate=function(e){if(typeof e!=="string"){return this.defaultValue}if(this._allowedValues.indexOf(e)===-1){return this.defaultValue}return this._convert(e)};return t}(BaseEditorOption);function _autoIndentFromString(e){switch(e){case"none":return 0;case"keep":return 1;case"brackets":return 2;case"advanced":return 3;case"full":return 4}}var EditorAccessibilitySupport=function(e){__extends(t,e);function t(){return e.call(this,2,"accessibilitySupport",0,{type:"string",enum:["auto","on","off"],enumDescriptions:[localize("accessibilitySupport.auto","Use platform APIs to detect when a Screen Reader is attached."),localize("accessibilitySupport.on","Optimize for usage with a Screen Reader."),localize("accessibilitySupport.off","Assume a screen reader is not attached.")],default:"auto",tags:["accessibility"],description:localize("accessibilitySupport","Controls if the UI should run in a mode where it is optimized for screen readers.")})||this}t.prototype.validate=function(e){switch(e){case"auto":return 0;case"off":return 1;case"on":return 2}return this.defaultValue};t.prototype.compute=function(e,t,n){if(n===0){return e.accessibilitySupport}return n};return t}(BaseEditorOption);var EditorComments=function(e){__extends(t,e);function t(){var t={insertSpace:true,ignoreEmptyLines:true};return e.call(this,23,"comments",t,{"editor.comments.insertSpace":{type:"boolean",default:t.insertSpace,description:localize("comments.insertSpace","Controls whether a space character is inserted when commenting.")},"editor.comments.ignoreEmptyLines":{type:"boolean",default:t.ignoreEmptyLines,description:localize("comments.ignoreEmptyLines","Controls if empty lines should be ignored with toggle, add or remove actions for line comments.")}})||this}t.prototype.validate=function(e){if(!e||typeof e!=="object"){return this.defaultValue}var t=e;return{insertSpace:boolean(t.insertSpace,this.defaultValue.insertSpace),ignoreEmptyLines:boolean(t.ignoreEmptyLines,this.defaultValue.ignoreEmptyLines)}};return t}(BaseEditorOption);function _cursorBlinkingStyleFromString(e){switch(e){case"blink":return 1;case"smooth":return 2;case"phase":return 3;case"expand":return 4;case"solid":return 5}}var TextEditorCursorStyle$1;(function(e){e[e["Line"]=1]="Line";e[e["Block"]=2]="Block";e[e["Underline"]=3]="Underline";e[e["LineThin"]=4]="LineThin";e[e["BlockOutline"]=5]="BlockOutline";e[e["UnderlineThin"]=6]="UnderlineThin"})(TextEditorCursorStyle$1||(TextEditorCursorStyle$1={}));function _cursorStyleFromString(e){switch(e){case"line":return TextEditorCursorStyle$1.Line;case"block":return TextEditorCursorStyle$1.Block;case"underline":return TextEditorCursorStyle$1.Underline;case"line-thin":return TextEditorCursorStyle$1.LineThin;case"block-outline":return TextEditorCursorStyle$1.BlockOutline;case"underline-thin":return TextEditorCursorStyle$1.UnderlineThin}}var EditorClassName=function(e){__extends(t,e);function t(){return e.call(this,140)||this}t.prototype.compute=function(e,t,n){var i=["monaco-editor"];if(t.get(39)){i.push(t.get(39))}if(e.extraEditorClassName){i.push(e.extraEditorClassName)}if(t.get(73)==="default"){i.push("mouse-default")}else if(t.get(73)==="copy"){i.push("mouse-copy")}if(t.get(110)){i.push("showUnused")}if(t.get(138)){i.push("showDeprecated")}return i.join(" ")};return t}(ComputedEditorOption);var EditorEmptySelectionClipboard=function(e){__extends(t,e);function t(){return e.call(this,37,"emptySelectionClipboard",true,{description:localize("emptySelectionClipboard","Controls whether copying without a selection copies the current line.")})||this}t.prototype.compute=function(e,t,n){return n&&e.emptySelectionClipboard};return t}(EditorBooleanOption);var EditorFind=function(e){__extends(t,e);function t(){var t={cursorMoveOnType:true,seedSearchStringFromSelection:"always",autoFindInSelection:"never",globalFindClipboard:false,addExtraSpaceOnTop:true,loop:true};return e.call(this,41,"find",t,{"editor.find.cursorMoveOnType":{type:"boolean",default:t.cursorMoveOnType,description:localize("find.cursorMoveOnType","Controls whether the cursor should jump to find matches while typing.")},"editor.find.seedSearchStringFromSelection":{type:"string",enum:["never","always","selection"],default:t.seedSearchStringFromSelection,enumDescriptions:[localize("editor.find.seedSearchStringFromSelection.never","Never seed search string from the editor selection."),localize("editor.find.seedSearchStringFromSelection.always","Always seed search string from the editor selection, including word at cursor position."),localize("editor.find.seedSearchStringFromSelection.selection","Only seed search string from the editor selection.")],description:localize("find.seedSearchStringFromSelection","Controls whether the search string in the Find Widget is seeded from the editor selection.")},"editor.find.autoFindInSelection":{type:"string",enum:["never","always","multiline"],default:t.autoFindInSelection,enumDescriptions:[localize("editor.find.autoFindInSelection.never","Never turn on Find in Selection automatically (default)."),localize("editor.find.autoFindInSelection.always","Always turn on Find in Selection automatically."),localize("editor.find.autoFindInSelection.multiline","Turn on Find in Selection automatically when multiple lines of content are selected.")],description:localize("find.autoFindInSelection","Controls the condition for turning on Find in Selection automatically.")},"editor.find.globalFindClipboard":{type:"boolean",default:t.globalFindClipboard,description:localize("find.globalFindClipboard","Controls whether the Find Widget should read or modify the shared find clipboard on macOS."),included:isMacintosh},"editor.find.addExtraSpaceOnTop":{type:"boolean",default:t.addExtraSpaceOnTop,description:localize("find.addExtraSpaceOnTop","Controls whether the Find Widget should add extra lines on top of the editor. When true, you can scroll beyond the first line when the Find Widget is visible.")},"editor.find.loop":{type:"boolean",default:t.loop,description:localize("find.loop","Controls whether the search automatically restarts from the beginning (or the end) when no further matches can be found.")}})||this}t.prototype.validate=function(e){if(!e||typeof e!=="object"){return this.defaultValue}var t=e;return{cursorMoveOnType:boolean(t.cursorMoveOnType,this.defaultValue.cursorMoveOnType),seedSearchStringFromSelection:typeof e.seedSearchStringFromSelection==="boolean"?e.seedSearchStringFromSelection?"always":"never":stringSet(t.seedSearchStringFromSelection,this.defaultValue.seedSearchStringFromSelection,["never","always","selection"]),autoFindInSelection:typeof e.autoFindInSelection==="boolean"?e.autoFindInSelection?"always":"never":stringSet(t.autoFindInSelection,this.defaultValue.autoFindInSelection,["never","always","multiline"]),globalFindClipboard:boolean(t.globalFindClipboard,this.defaultValue.globalFindClipboard),addExtraSpaceOnTop:boolean(t.addExtraSpaceOnTop,this.defaultValue.addExtraSpaceOnTop),loop:boolean(t.loop,this.defaultValue.loop)}};return t}(BaseEditorOption);var EditorFontLigatures=function(e){__extends(t,e);function t(){return e.call(this,51,"fontLigatures",t.OFF,{anyOf:[{type:"boolean",description:localize("fontLigatures","Enables/Disables font ligatures ('calt' and 'liga' font features). Change this to a string for fine-grained control of the 'font-feature-settings' CSS property.")},{type:"string",description:localize("fontFeatureSettings","Explicit 'font-feature-settings' CSS property. A boolean can be passed instead if one only needs to turn on/off ligatures.")}],description:localize("fontLigaturesGeneral","Configures font ligatures or font features. Can be either a boolean to enable/disable ligatures or a string for the value of the CSS 'font-feature-settings' property."),default:false})||this}t.prototype.validate=function(e){if(typeof e==="undefined"){return this.defaultValue}if(typeof e==="string"){if(e==="false"){return t.OFF}if(e==="true"){return t.ON}return e}if(Boolean(e)){return t.ON}return t.OFF};return t}(BaseEditorOption);EditorFontLigatures.OFF='"liga" off, "calt" off';EditorFontLigatures.ON='"liga" on, "calt" on';var EditorFontVariations=function(e){__extends(t,e);function t(){return e.call(this,54,"fontVariations",t.OFF,{anyOf:[{type:"boolean",description:localize("fontVariations","Enables/Disables the translation from font-weight to font-variation-settings. Change this to a string for fine-grained control of the 'font-variation-settings' CSS property.")},{type:"string",description:localize("fontVariationSettings","Explicit 'font-variation-settings' CSS property. A boolean can be passed instead if one only needs to translate font-weight to font-variation-settings.")}],description:localize("fontVariationsGeneral","Configures font variations. Can be either a boolean to enable/disable the translation from font-weight to font-variation-settings or a string for the value of the CSS 'font-variation-settings' property."),default:false})||this}t.prototype.validate=function(e){if(typeof e==="undefined"){return this.defaultValue}if(typeof e==="string"){if(e==="false"){return t.OFF}if(e==="true"){return t.TRANSLATE}return e}if(Boolean(e)){return t.TRANSLATE}return t.OFF};t.prototype.compute=function(e,t,n){return e.fontInfo.fontVariationSettings};return t}(BaseEditorOption);EditorFontVariations.OFF="normal";EditorFontVariations.TRANSLATE="translate";var EditorFontInfo=function(e){__extends(t,e);function t(){return e.call(this,50)||this}t.prototype.compute=function(e,t,n){return e.fontInfo};return t}(ComputedEditorOption);var EditorFontSize=function(e){__extends(t,e);function t(){return e.call(this,52,"fontSize",EDITOR_FONT_DEFAULTS.fontSize,{type:"number",minimum:6,maximum:100,default:EDITOR_FONT_DEFAULTS.fontSize,description:localize("fontSize","Controls the font size in pixels.")})||this}t.prototype.validate=function(e){var t=EditorFloatOption.float(e,this.defaultValue);if(t===0){return EDITOR_FONT_DEFAULTS.fontSize}return EditorFloatOption.clamp(t,6,100)};t.prototype.compute=function(e,t,n){return e.fontInfo.fontSize};return t}(SimpleEditorOption);var EditorFontWeight=function(e){__extends(t,e);function t(){return e.call(this,53,"fontWeight",EDITOR_FONT_DEFAULTS.fontWeight,{anyOf:[{type:"number",minimum:t.MINIMUM_VALUE,maximum:t.MAXIMUM_VALUE,errorMessage:localize("fontWeightErrorMessage",'Only "normal" and "bold" keywords or numbers between 1 and 1000 are allowed.')},{type:"string",pattern:"^(normal|bold|1000|[1-9][0-9]{0,2})$"},{enum:t.SUGGESTION_VALUES}],default:EDITOR_FONT_DEFAULTS.fontWeight,description:localize("fontWeight",'Controls the font weight. Accepts "normal" and "bold" keywords or numbers between 1 and 1000.')})||this}t.prototype.validate=function(e){if(e==="normal"||e==="bold"){return e}return String(EditorIntOption.clampedInt(e,EDITOR_FONT_DEFAULTS.fontWeight,t.MINIMUM_VALUE,t.MAXIMUM_VALUE))};return t}(BaseEditorOption);EditorFontWeight.SUGGESTION_VALUES=["normal","bold","100","200","300","400","500","600","700","800","900"];EditorFontWeight.MINIMUM_VALUE=1;EditorFontWeight.MAXIMUM_VALUE=1e3;var EditorGoToLocation=function(e){__extends(t,e);function t(){var t={multiple:"peek",multipleDefinitions:"peek",multipleTypeDefinitions:"peek",multipleDeclarations:"peek",multipleImplementations:"peek",multipleReferences:"peek",alternativeDefinitionCommand:"editor.action.goToReferences",alternativeTypeDefinitionCommand:"editor.action.goToReferences",alternativeDeclarationCommand:"editor.action.goToReferences",alternativeImplementationCommand:"",alternativeReferenceCommand:""};var n={type:"string",enum:["peek","gotoAndPeek","goto"],default:t.multiple,enumDescriptions:[localize("editor.gotoLocation.multiple.peek","Show Peek view of the results (default)"),localize("editor.gotoLocation.multiple.gotoAndPeek","Go to the primary result and show a Peek view"),localize("editor.gotoLocation.multiple.goto","Go to the primary result and enable Peek-less navigation to others")]};var i=["","editor.action.referenceSearch.trigger","editor.action.goToReferences","editor.action.peekImplementation","editor.action.goToImplementation","editor.action.peekTypeDefinition","editor.action.goToTypeDefinition","editor.action.peekDeclaration","editor.action.revealDeclaration","editor.action.peekDefinition","editor.action.revealDefinitionAside","editor.action.revealDefinition"];return e.call(this,58,"gotoLocation",t,{"editor.gotoLocation.multiple":{deprecationMessage:localize("editor.gotoLocation.multiple.deprecated","This setting is deprecated, please use separate settings like 'editor.editor.gotoLocation.multipleDefinitions' or 'editor.editor.gotoLocation.multipleImplementations' instead.")},"editor.gotoLocation.multipleDefinitions":__assign({description:localize("editor.editor.gotoLocation.multipleDefinitions","Controls the behavior the 'Go to Definition'-command when multiple target locations exist.")},n),"editor.gotoLocation.multipleTypeDefinitions":__assign({description:localize("editor.editor.gotoLocation.multipleTypeDefinitions","Controls the behavior the 'Go to Type Definition'-command when multiple target locations exist.")},n),"editor.gotoLocation.multipleDeclarations":__assign({description:localize("editor.editor.gotoLocation.multipleDeclarations","Controls the behavior the 'Go to Declaration'-command when multiple target locations exist.")},n),"editor.gotoLocation.multipleImplementations":__assign({description:localize("editor.editor.gotoLocation.multipleImplemenattions","Controls the behavior the 'Go to Implementations'-command when multiple target locations exist.")},n),"editor.gotoLocation.multipleReferences":__assign({description:localize("editor.editor.gotoLocation.multipleReferences","Controls the behavior the 'Go to References'-command when multiple target locations exist.")},n),"editor.gotoLocation.alternativeDefinitionCommand":{type:"string",default:t.alternativeDefinitionCommand,enum:i,description:localize("alternativeDefinitionCommand","Alternative command id that is being executed when the result of 'Go to Definition' is the current location.")},"editor.gotoLocation.alternativeTypeDefinitionCommand":{type:"string",default:t.alternativeTypeDefinitionCommand,enum:i,description:localize("alternativeTypeDefinitionCommand","Alternative command id that is being executed when the result of 'Go to Type Definition' is the current location.")},"editor.gotoLocation.alternativeDeclarationCommand":{type:"string",default:t.alternativeDeclarationCommand,enum:i,description:localize("alternativeDeclarationCommand","Alternative command id that is being executed when the result of 'Go to Declaration' is the current location.")},"editor.gotoLocation.alternativeImplementationCommand":{type:"string",default:t.alternativeImplementationCommand,enum:i,description:localize("alternativeImplementationCommand","Alternative command id that is being executed when the result of 'Go to Implementation' is the current location.")},"editor.gotoLocation.alternativeReferenceCommand":{type:"string",default:t.alternativeReferenceCommand,enum:i,description:localize("alternativeReferenceCommand","Alternative command id that is being executed when the result of 'Go to Reference' is the current location.")}})||this}t.prototype.validate=function(e){var t,n,i,r,a;if(!e||typeof e!=="object"){return this.defaultValue}var o=e;return{multiple:stringSet(o.multiple,this.defaultValue.multiple,["peek","gotoAndPeek","goto"]),multipleDefinitions:(t=o.multipleDefinitions)!==null&&t!==void 0?t:stringSet(o.multipleDefinitions,"peek",["peek","gotoAndPeek","goto"]),multipleTypeDefinitions:(n=o.multipleTypeDefinitions)!==null&&n!==void 0?n:stringSet(o.multipleTypeDefinitions,"peek",["peek","gotoAndPeek","goto"]),multipleDeclarations:(i=o.multipleDeclarations)!==null&&i!==void 0?i:stringSet(o.multipleDeclarations,"peek",["peek","gotoAndPeek","goto"]),multipleImplementations:(r=o.multipleImplementations)!==null&&r!==void 0?r:stringSet(o.multipleImplementations,"peek",["peek","gotoAndPeek","goto"]),multipleReferences:(a=o.multipleReferences)!==null&&a!==void 0?a:stringSet(o.multipleReferences,"peek",["peek","gotoAndPeek","goto"]),alternativeDefinitionCommand:EditorStringOption.string(o.alternativeDefinitionCommand,this.defaultValue.alternativeDefinitionCommand),alternativeTypeDefinitionCommand:EditorStringOption.string(o.alternativeTypeDefinitionCommand,this.defaultValue.alternativeTypeDefinitionCommand),alternativeDeclarationCommand:EditorStringOption.string(o.alternativeDeclarationCommand,this.defaultValue.alternativeDeclarationCommand),alternativeImplementationCommand:EditorStringOption.string(o.alternativeImplementationCommand,this.defaultValue.alternativeImplementationCommand),alternativeReferenceCommand:EditorStringOption.string(o.