@codingame/monaco-vscode-api 1.79.5 → 1.79.7-next.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/default-extensions/npm.js +7 -0
- package/dist/{extension-tools-13cf24a4.js → extension-tools-98a21c83.js} +7 -4
- package/dist/files.d.ts +1 -1
- package/dist/languageFeatures.d.ts +1 -1
- package/dist/monaco.d.ts +4 -2
- package/dist/monaco.js +1 -0
- package/dist/rollup-extension-directory-plugin.js +1 -1
- package/dist/rollup-vsix-plugin.js +1 -1
- package/dist/service-override/files.d.ts +61 -17
- package/dist/service-override/files.js +71 -107
- package/dist/service-override/output.js +1 -1
- package/dist/services.d.ts +1 -1
- package/dist/typescript.js +27 -0
- package/dist/vscode/vs/platform/files/common/files.js +6 -1
- package/dist/vscode/vs/workbench/services/textMate/browser/worker/textMate.worker.js +2 -2
- package/dist/vscode-default-extensions/npm/dist/browser/npmBrowserMain.js.extensionResource.js +2 -0
- package/dist/vscode-default-extensions/npm/package.json.js +2 -0
- package/monaco-editor-treemending.patch +780 -780
- package/package.json +1 -1
package/dist/vscode-default-extensions/npm/dist/browser/npmBrowserMain.js.extensionResource.js
ADDED
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
var npmBrowserMain_js = "\"use strict\";var e=require(\"vscode\");function t(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,\"default\")?e.default:e}var n,r={};n=r,(()=>{var t=[,(e,t)=>{(()=>{var e={};(()=>{var t=e;Object.defineProperty(t,\"__esModule\",{value:!0}),t.getErrorStatusDescription=t.xhr=t.configure=void 0,t.configure=(e,t)=>{},t.xhr=async e=>{const t=new Headers;if(e.headers)for(const n in e.headers){const r=e.headers[n];Array.isArray(r)?r.forEach((e=>t.set(n,e))):t.set(n,r)}e.user&&e.password&&t.set(\"Authorization\",\"Basic \"+btoa(e.user+\":\"+e.password));const n={method:e.type,redirect:e.followRedirects>0?\"follow\":\"manual\",mode:\"cors\",headers:t};if(e.data&&(n.body=e.data),e.token){const t=new AbortController;e.token.isCancellationRequested&&t.abort(),e.token.onCancellationRequested((()=>{t.abort()})),n.signal=t.signal}const r=new Request(e.url,n),o=await fetch(r),i={};o.headers.forEach(((e,t)=>{i[t]=e}));const s=await o.arrayBuffer();return new class{constructor(){this.status=o.status,this.headers=i}get responseText(){return(new TextDecoder).decode(s)}get body(){return new Uint8Array(s)}}},t.getErrorStatusDescription=function(e){return String(e)}})();var n=t;for(var r in e)n[r]=e[r];e.__esModule&&Object.defineProperty(n,\"__esModule\",{value:!0})})()},(e,t,n)=>{Object.defineProperty(t,\"__esModule\",{value:!0}),t.xhrDisabled=t.JSONCompletionItemProvider=t.JSONHoverProvider=t.addJSONProviders=void 0;const r=n(3),o=n(8),i=n(10),s=n(9);t.addJSONProviders=function(e,t){const n=[new i.PackageJSONContribution(e,t),new o.BowerJSONContribution(e)],r=[];return n.forEach((e=>{const t=e.getDocumentSelector();r.push(s.languages.registerCompletionItemProvider(t,new c(e),'\"',\":\")),r.push(s.languages.registerHoverProvider(t,new a(e)))})),s.Disposable.from(...r)};class a{constructor(e){this.jsonContribution=e}provideHover(e,t,n){const o=e.offsetAt(t),i=(0,r.getLocation)(e.getText(),o);if(!i.previousNode)return null;const a=i.previousNode;if(a&&a.offset<=o&&o<=a.offset+a.length){const t=this.jsonContribution.getInfoContribution(e.uri,i);if(t)return t.then((t=>({contents:t||[],range:new s.Range(e.positionAt(a.offset),e.positionAt(a.offset+a.length))})))}return null}}t.JSONHoverProvider=a;class c{constructor(e){this.jsonContribution=e}resolveCompletionItem(e,t){if(this.jsonContribution.resolveSuggestion){const t=this.jsonContribution.resolveSuggestion(this.lastResource,e);if(t)return t}return Promise.resolve(e)}provideCompletionItems(e,t,n){this.lastResource=e.uri;const o=this.getCurrentWord(e,t);let i;const a=[];let c=!1;const l=e.offsetAt(t),u=(0,r.getLocation)(e.getText(),l),f=u.previousNode;i=f&&f.offset<=l&&l<=f.offset+f.length&&(\"property\"===f.type||\"string\"===f.type||\"number\"===f.type||\"boolean\"===f.type||\"null\"===f.type)?new s.Range(e.positionAt(f.offset),e.positionAt(f.offset+f.length)):new s.Range(e.positionAt(l-o.length),t);const d={},h={add:e=>{const t=\"string\"==typeof e.label?e.label:e.label.label;d[t]||(d[t]=!0,e.range={replacing:i,inserting:new s.Range(i.start,i.start)},a.push(e))},setAsIncomplete:()=>c=!0,error:e=>console.error(e),log:e=>console.log(e)};let p=null;if(u.isAtPropertyKey){const n=(0,r.createScanner)(e.getText(),!0),i=!u.previousNode||!this.hasColonAfter(n,u.previousNode.offset+u.previousNode.length),s=this.isLast(n,e.offsetAt(t));p=this.jsonContribution.collectPropertySuggestions(e.uri,u,o,i,s,h)}else p=0===u.path.length?this.jsonContribution.collectDefaultSuggestions(e.uri,h):this.jsonContribution.collectValueSuggestions(e.uri,u,h);return p?p.then((()=>a.length>0||c?new s.CompletionList(a,c):null)):null}getCurrentWord(e,t){let n=t.character-1;const r=e.lineAt(t.line).text;for(;n>=0&&-1===' \\t\\n\\r\\v\":{[,'.indexOf(r.charAt(n));)n--;return r.substring(n+1,t.character)}isLast(e,t){e.setPosition(t);let n=e.scan();return 10===n&&2===e.getTokenError()&&(n=e.scan()),2===n||17===n}hasColonAfter(e,t){return e.setPosition(t),6===e.scan()}}t.JSONCompletionItemProvider=c,t.xhrDisabled=()=>Promise.reject({responseText:\"Use of online resources is disabled.\"})},(e,t,n)=>{n.r(t),n.d(t,{applyEdits:()=>k,createScanner:()=>a,findNodeAtLocation:()=>f,findNodeAtOffset:()=>d,format:()=>y,getLocation:()=>c,getNodePath:()=>h,getNodeValue:()=>p,modify:()=>b,parse:()=>l,parseTree:()=>u,printParseErrorCode:()=>v,stripComments:()=>m,visit:()=>g});var r=n(4),o=n(6),i=n(5),s=n(7),a=i.createScanner,c=s.getLocation,l=s.parse,u=s.parseTree,f=s.findNodeAtLocation,d=s.findNodeAtOffset,h=s.getNodePath,p=s.getNodeValue,g=s.visit,m=s.stripComments;function v(e){switch(e){case 1:return\"InvalidSymbol\";case 2:return\"InvalidNumberFormat\";case 3:return\"PropertyNameExpected\";case 4:return\"ValueExpected\";case 5:return\"ColonExpected\";case 6:return\"CommaExpected\";case 7:return\"CloseBraceExpected\";case 8:return\"CloseBracketExpected\";case 9:return\"EndOfFileExpected\";case 10:return\"InvalidCommentToken\";case 11:return\"UnexpectedEndOfComment\";case 12:return\"UnexpectedEndOfString\";case 13:return\"UnexpectedEndOfNumber\";case 14:return\"InvalidUnicode\";case 15:return\"InvalidEscapeCharacter\";case 16:return\"InvalidCharacter\"}return\"<unknown ParseErrorCode>\"}function y(e,t,n){return r.format(e,t,n)}function b(e,t,n,r){return o.setProperty(e,t,n,r.formattingOptions,r.getInsertionIndex)}function k(e,t){for(var n=t.length-1;n>=0;n--)e=o.applyEdit(e,t[n]);return e}},(e,t,n)=>{n.r(t),n.d(t,{format:()=>o,isEOL:()=>s});var r=n(5);function o(e,t,n){var o,a,c,l,u;if(t){for(l=t.offset,u=l+t.length,c=l;c>0&&!s(e,c-1);)c--;for(var f=u;f<e.length&&!s(e,f);)f++;a=e.substring(c,f),o=function(e,t){for(var n=0,r=0,o=t.tabSize||4;n<e.length;){var i=e.charAt(n);if(\" \"===i)r++;else{if(\"\\t\"!==i)break;r+=o}n++}return Math.floor(r/o)}(a,n)}else a=e,o=0,c=0,l=0,u=e.length;var d,h=function(e,t){for(var n=0;n<t.length;n++){var r=t.charAt(n);if(\"\\r\"===r)return n+1<t.length&&\"\\n\"===t.charAt(n+1)?\"\\r\\n\":\"\\r\";if(\"\\n\"===r)return\"\\n\"}return e&&e.eol||\"\\n\"}(n,e),p=!1,g=0;d=n.insertSpaces?i(\" \",n.tabSize||4):\"\\t\";var m=(0,r.createScanner)(a,!1),v=!1;function y(){return h+i(d,o+g)}function b(){var e=m.scan();for(p=!1;15===e||14===e;)p=p||14===e,e=m.scan();return v=16===e||0!==m.getTokenError(),e}var k=[];function C(t,n,r){!v&&n<u&&r>l&&e.substring(n,r)!==t&&k.push({offset:n,length:r-n,content:t})}var w=b();if(17!==w){var T=m.getTokenOffset()+c;C(i(d,o),c,T)}for(;17!==w;){for(var A=m.getTokenOffset()+m.getTokenLength()+c,x=b(),S=\"\";!p&&(12===x||13===x);)C(\" \",A,m.getTokenOffset()+c),A=m.getTokenOffset()+m.getTokenLength()+c,S=12===x?y():\"\",x=b();if(2===x)1!==w&&(g--,S=y());else if(4===x)3!==w&&(g--,S=y());else{switch(w){case 3:case 1:g++,S=y();break;case 5:case 12:S=y();break;case 13:S=p?y():\" \";break;case 6:S=\" \";break;case 10:if(6===x){S=\"\";break}case 7:case 8:case 9:case 11:case 2:case 4:12===x||13===x?S=\" \":5!==x&&17!==x&&(v=!0);break;case 16:v=!0}!p||12!==x&&13!==x||(S=y())}C(S,A,m.getTokenOffset()+c),w=x}return k}function i(e,t){for(var n=\"\",r=0;r<t;r++)n+=e;return n}function s(e,t){return-1!==\"\\r\\n\".indexOf(e.charAt(t))}},(e,t,n)=>{function r(e,t){void 0===t&&(t=!1);var n=e.length,r=0,a=\"\",c=0,l=16,u=0,f=0,d=0,h=0,p=0;function g(t,n){for(var o=0,i=0;o<t||!n;){var s=e.charCodeAt(r);if(s>=48&&s<=57)i=16*i+s-48;else if(s>=65&&s<=70)i=16*i+s-65+10;else{if(!(s>=97&&s<=102))break;i=16*i+s-97+10}r++,o++}return o<t&&(i=-1),i}function m(){if(a=\"\",p=0,c=r,f=u,h=d,r>=n)return c=n,l=17;var t=e.charCodeAt(r);if(o(t)){do{r++,a+=String.fromCharCode(t),t=e.charCodeAt(r)}while(o(t));return l=15}if(i(t))return r++,a+=String.fromCharCode(t),13===t&&10===e.charCodeAt(r)&&(r++,a+=\"\\n\"),u++,d=r,l=14;switch(t){case 123:return r++,l=1;case 125:return r++,l=2;case 91:return r++,l=3;case 93:return r++,l=4;case 58:return r++,l=6;case 44:return r++,l=5;case 34:return r++,a=function(){for(var t=\"\",o=r;;){if(r>=n){t+=e.substring(o,r),p=2;break}var s=e.charCodeAt(r);if(34===s){t+=e.substring(o,r),r++;break}if(92!==s){if(s>=0&&s<=31){if(i(s)){t+=e.substring(o,r),p=2;break}p=6}r++}else{if(t+=e.substring(o,r),++r>=n){p=2;break}switch(e.charCodeAt(r++)){case 34:t+='\"';break;case 92:t+=\"\\\\\";break;case 47:t+=\"/\";break;case 98:t+=\"\\b\";break;case 102:t+=\"\\f\";break;case 110:t+=\"\\n\";break;case 114:t+=\"\\r\";break;case 116:t+=\"\\t\";break;case 117:var a=g(4,!0);a>=0?t+=String.fromCharCode(a):p=4;break;default:p=5}o=r}}return t}(),l=10;case 47:var m=r-1;if(47===e.charCodeAt(r+1)){for(r+=2;r<n&&!i(e.charCodeAt(r));)r++;return a=e.substring(m,r),l=12}if(42===e.charCodeAt(r+1)){r+=2;for(var y=n-1,b=!1;r<y;){var k=e.charCodeAt(r);if(42===k&&47===e.charCodeAt(r+1)){r+=2,b=!0;break}r++,i(k)&&(13===k&&10===e.charCodeAt(r)&&r++,u++,d=r)}return b||(r++,p=1),a=e.substring(m,r),l=13}return a+=String.fromCharCode(t),r++,l=16;case 45:if(a+=String.fromCharCode(t),++r===n||!s(e.charCodeAt(r)))return l=16;case 48:case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:return a+=function(){var t=r;if(48===e.charCodeAt(r))r++;else for(r++;r<e.length&&s(e.charCodeAt(r));)r++;if(r<e.length&&46===e.charCodeAt(r)){if(!(++r<e.length&&s(e.charCodeAt(r))))return p=3,e.substring(t,r);for(r++;r<e.length&&s(e.charCodeAt(r));)r++}var n=r;if(r<e.length&&(69===e.charCodeAt(r)||101===e.charCodeAt(r)))if((++r<e.length&&43===e.charCodeAt(r)||45===e.charCodeAt(r))&&r++,r<e.length&&s(e.charCodeAt(r))){for(r++;r<e.length&&s(e.charCodeAt(r));)r++;n=r}else p=3;return e.substring(t,n)}(),l=11;default:for(;r<n&&v(t);)r++,t=e.charCodeAt(r);if(c!==r){switch(a=e.substring(c,r)){case\"true\":return l=8;case\"false\":return l=9;case\"null\":return l=7}return l=16}return a+=String.fromCharCode(t),r++,l=16}}function v(e){if(o(e)||i(e))return!1;switch(e){case 125:case 93:case 123:case 91:case 34:case 58:case 44:case 47:return!1}return!0}return{setPosition:function(e){r=e,a=\"\",c=0,l=16,p=0},getPosition:function(){return r},scan:t?function(){var e;do{e=m()}while(e>=12&&e<=15);return e}:m,getToken:function(){return l},getTokenValue:function(){return a},getTokenOffset:function(){return c},getTokenLength:function(){return r-c},getTokenStartLine:function(){return f},getTokenStartCharacter:function(){return c-h},getTokenError:function(){return p}}}function o(e){return 32===e||9===e||11===e||12===e||160===e||5760===e||e>=8192&&e<=8203||8239===e||8287===e||12288===e||65279===e}function i(e){return 10===e||13===e||8232===e||8233===e}function s(e){return e>=48&&e<=57}n.r(t),n.d(t,{createScanner:()=>r})},(e,t,n)=>{n.r(t),n.d(t,{applyEdit:()=>c,isWS:()=>l,removeProperty:()=>i,setProperty:()=>s});var r=n(4),o=n(7);function i(e,t,n){return s(e,t,void 0,n)}function s(e,t,n,r,i){for(var s,c=t.slice(),l=(0,o.parseTree)(e,[]),u=void 0,f=void 0;c.length>0&&(f=c.pop(),void 0===(u=(0,o.findNodeAtLocation)(l,c))&&void 0!==n);)\"string\"==typeof f?((s={})[f]=n,n=s):n=[n];if(u){if(\"object\"===u.type&&\"string\"==typeof f&&Array.isArray(u.children)){var d=(0,o.findNodeAtLocation)(u,[f]);if(void 0!==d){if(void 0===n){if(!d.parent)throw new Error(\"Malformed AST\");var h=u.children.indexOf(d.parent),p=void 0,g=d.parent.offset+d.parent.length;return h>0?p=(C=u.children[h-1]).offset+C.length:(p=u.offset+1,u.children.length>1&&(g=u.children[1].offset)),a(e,{offset:p,length:g-p,content:\"\"},r)}return a(e,{offset:d.offset,length:d.length,content:JSON.stringify(n)},r)}if(void 0===n)return[];var m=JSON.stringify(f)+\": \"+JSON.stringify(n),v=i?i(u.children.map((function(e){return e.children[0].value}))):u.children.length,y=void 0;return a(e,y=v>0?{offset:(C=u.children[v-1]).offset+C.length,length:0,content:\",\"+m}:0===u.children.length?{offset:u.offset+1,length:0,content:m}:{offset:u.offset+1,length:0,content:m+\",\"},r)}if(\"array\"===u.type&&\"number\"==typeof f&&Array.isArray(u.children)){if(-1===f)return m=\"\"+JSON.stringify(n),y=void 0,a(e,y=0===u.children.length?{offset:u.offset+1,length:0,content:m}:{offset:(C=u.children[u.children.length-1]).offset+C.length,length:0,content:\",\"+m},r);if(void 0===n&&u.children.length>=0){var b=f,k=u.children[b];if(y=void 0,1===u.children.length)y={offset:u.offset+1,length:u.length-2,content:\"\"};else if(u.children.length-1===b){var C,w=(C=u.children[b-1]).offset+C.length;y={offset:w,length:u.offset+u.length-2-w,content:\"\"}}else y={offset:k.offset,length:u.children[b+1].offset-k.offset,content:\"\"};return a(e,y,r)}throw new Error(\"Array modification not supported yet\")}throw new Error(\"Can not add \"+(\"number\"!=typeof f?\"index\":\"property\")+\" to parent of type \"+u.type)}if(void 0===n)throw new Error(\"Can not delete in empty document\");return a(e,{offset:l?l.offset:0,length:l?l.length:0,content:JSON.stringify(n)},r)}function a(e,t,n){var o=c(e,t),i=t.offset,s=t.offset+t.content.length;if(0===t.length||0===t.content.length){for(;i>0&&!(0,r.isEOL)(o,i-1);)i--;for(;s<o.length&&!(0,r.isEOL)(o,s);)s++}for(var a=(0,r.format)(o,{offset:i,length:s-i},n),l=a.length-1;l>=0;l--){var u=a[l];o=c(o,u),i=Math.min(i,u.offset),s=Math.max(s,u.offset+u.length),s+=u.content.length-u.length}return[{offset:i,length:e.length-(o.length-s)-i,content:o.substring(i,s)}]}function c(e,t){return e.substring(0,t.offset)+t.content+e.substring(t.offset+t.length)}function l(e,t){return-1!==\"\\r\\n \\t\".indexOf(e.charAt(t))}},(e,t,n)=>{n.r(t),n.d(t,{contains:()=>f,findNodeAtLocation:()=>c,findNodeAtOffset:()=>d,getLocation:()=>i,getNodePath:()=>l,getNodeType:()=>g,getNodeValue:()=>u,parse:()=>s,parseTree:()=>a,stripComments:()=>p,visit:()=>h});var r,o=n(5);function i(e,t){var n=[],r=new Object,o=void 0,i={value:{},offset:0,length:0,type:\"object\",parent:void 0},s=!1;function a(e,t,n,r){i.value=e,i.offset=t,i.length=n,i.type=r,i.colonOffset=void 0,o=i}try{h(e,{onObjectBegin:function(e,i){if(t<=e)throw r;o=void 0,s=t>e,n.push(\"\")},onObjectProperty:function(e,o,i){if(t<o)throw r;if(a(e,o,i,\"property\"),n[n.length-1]=e,t<=o+i)throw r},onObjectEnd:function(e,i){if(t<=e)throw r;o=void 0,n.pop()},onArrayBegin:function(e,i){if(t<=e)throw r;o=void 0,n.push(0)},onArrayEnd:function(e,i){if(t<=e)throw r;o=void 0,n.pop()},onLiteralValue:function(e,n,o){if(t<n)throw r;if(a(e,n,o,g(e)),t<=n+o)throw r},onSeparator:function(e,i,a){if(t<=i)throw r;if(\":\"===e&&o&&\"property\"===o.type)o.colonOffset=i,s=!1,o=void 0;else if(\",\"===e){var c=n[n.length-1];\"number\"==typeof c?n[n.length-1]=c+1:(s=!0,n[n.length-1]=\"\"),o=void 0}}})}catch(e){if(e!==r)throw e}return{path:n,previousNode:o,isAtPropertyKey:s,matches:function(e){for(var t=0,r=0;t<e.length&&r<n.length;r++)if(e[t]===n[r]||\"*\"===e[t])t++;else if(\"**\"!==e[t])return!1;return t===e.length}}}function s(e,t,n){void 0===t&&(t=[]),void 0===n&&(n=r.DEFAULT);var o=null,i=[],s=[];function a(e){Array.isArray(i)?i.push(e):null!==o&&(i[o]=e)}return h(e,{onObjectBegin:function(){var e={};a(e),s.push(i),i=e,o=null},onObjectProperty:function(e){o=e},onObjectEnd:function(){i=s.pop()},onArrayBegin:function(){var e=[];a(e),s.push(i),i=e,o=null},onArrayEnd:function(){i=s.pop()},onLiteralValue:a,onError:function(e,n,r){t.push({error:e,offset:n,length:r})}},n),i[0]}function a(e,t,n){void 0===t&&(t=[]),void 0===n&&(n=r.DEFAULT);var o={type:\"array\",offset:-1,length:-1,children:[],parent:void 0};function i(e){\"property\"===o.type&&(o.length=e-o.offset,o=o.parent)}function s(e){return o.children.push(e),e}h(e,{onObjectBegin:function(e){o=s({type:\"object\",offset:e,length:-1,parent:o,children:[]})},onObjectProperty:function(e,t,n){(o=s({type:\"property\",offset:t,length:-1,parent:o,children:[]})).children.push({type:\"string\",value:e,offset:t,length:n,parent:o})},onObjectEnd:function(e,t){i(e+t),o.length=e+t-o.offset,o=o.parent,i(e+t)},onArrayBegin:function(e,t){o=s({type:\"array\",offset:e,length:-1,parent:o,children:[]})},onArrayEnd:function(e,t){o.length=e+t-o.offset,o=o.parent,i(e+t)},onLiteralValue:function(e,t,n){s({type:g(e),offset:t,length:n,parent:o,value:e}),i(t+n)},onSeparator:function(e,t,n){\"property\"===o.type&&(\":\"===e?o.colonOffset=t:\",\"===e&&i(t))},onError:function(e,n,r){t.push({error:e,offset:n,length:r})}},n);var a=o.children[0];return a&&delete a.parent,a}function c(e,t){if(e){for(var n=e,r=0,o=t;r<o.length;r++){var i=o[r];if(\"string\"==typeof i){if(\"object\"!==n.type||!Array.isArray(n.children))return;for(var s=!1,a=0,c=n.children;a<c.length;a++){var l=c[a];if(Array.isArray(l.children)&&l.children[0].value===i){n=l.children[1],s=!0;break}}if(!s)return}else{var u=i;if(\"array\"!==n.type||u<0||!Array.isArray(n.children)||u>=n.children.length)return;n=n.children[u]}}return n}}function l(e){if(!e.parent||!e.parent.children)return[];var t=l(e.parent);if(\"property\"===e.parent.type){var n=e.parent.children[0].value;t.push(n)}else if(\"array\"===e.parent.type){var r=e.parent.children.indexOf(e);-1!==r&&t.push(r)}return t}function u(e){switch(e.type){case\"array\":return e.children.map(u);case\"object\":for(var t=Object.create(null),n=0,r=e.children;n<r.length;n++){var o=r[n],i=o.children[1];i&&(t[o.children[0].value]=u(i))}return t;case\"null\":case\"string\":case\"number\":case\"boolean\":return e.value;default:return}}function f(e,t,n){return void 0===n&&(n=!1),t>=e.offset&&t<e.offset+e.length||n&&t===e.offset+e.length}function d(e,t,n){if(void 0===n&&(n=!1),f(e,t,n)){var r=e.children;if(Array.isArray(r))for(var o=0;o<r.length&&r[o].offset<=t;o++){var i=d(r[o],t,n);if(i)return i}return e}}function h(e,t,n){void 0===n&&(n=r.DEFAULT);var i=(0,o.createScanner)(e,!1);function s(e){return e?function(){return e(i.getTokenOffset(),i.getTokenLength(),i.getTokenStartLine(),i.getTokenStartCharacter())}:function(){return!0}}function a(e){return e?function(t){return e(t,i.getTokenOffset(),i.getTokenLength(),i.getTokenStartLine(),i.getTokenStartCharacter())}:function(){return!0}}var c=s(t.onObjectBegin),l=a(t.onObjectProperty),u=s(t.onObjectEnd),f=s(t.onArrayBegin),d=s(t.onArrayEnd),h=a(t.onLiteralValue),p=a(t.onSeparator),g=s(t.onComment),m=a(t.onError),v=n&&n.disallowComments,y=n&&n.allowTrailingComma;function b(){for(;;){var e=i.scan();switch(i.getTokenError()){case 4:k(14);break;case 5:k(15);break;case 3:k(13);break;case 1:v||k(11);break;case 2:k(12);break;case 6:k(16)}switch(e){case 12:case 13:v?k(10):g();break;case 16:k(1);break;case 15:case 14:break;default:return e}}}function k(e,t,n){if(void 0===t&&(t=[]),void 0===n&&(n=[]),m(e),t.length+n.length>0)for(var r=i.getToken();17!==r;){if(-1!==t.indexOf(r)){b();break}if(-1!==n.indexOf(r))break;r=b()}}function C(e){var t=i.getTokenValue();return e?h(t):l(t),b(),!0}function w(){switch(i.getToken()){case 3:return function(){f(),b();for(var e=!1;4!==i.getToken()&&17!==i.getToken();){if(5===i.getToken()){if(e||k(4,[],[]),p(\",\"),b(),4===i.getToken()&&y)break}else e&&k(6,[],[]);w()||k(4,[],[4,5]),e=!0}return d(),4!==i.getToken()?k(8,[4],[]):b(),!0}();case 1:return function(){c(),b();for(var e=!1;2!==i.getToken()&&17!==i.getToken();){if(5===i.getToken()){if(e||k(4,[],[]),p(\",\"),b(),2===i.getToken()&&y)break}else e&&k(6,[],[]);(10!==i.getToken()?(k(3,[],[2,5]),0):(C(!1),6===i.getToken()?(p(\":\"),b(),w()||k(4,[],[2,5])):k(5,[],[2,5]),1))||k(4,[],[2,5]),e=!0}return u(),2!==i.getToken()?k(7,[2],[]):b(),!0}();case 10:return C(!0);default:return function(){switch(i.getToken()){case 11:var e=0;try{\"number\"!=typeof(e=JSON.parse(i.getTokenValue()))&&(k(2),e=0)}catch(e){k(2)}h(e);break;case 7:h(null);break;case 8:h(!0);break;case 9:h(!1);break;default:return!1}return b(),!0}()}}return b(),17===i.getToken()?!!n.allowEmptyContent||(k(4,[],[]),!1):w()?(17!==i.getToken()&&k(9,[],[]),!0):(k(4,[],[]),!1)}function p(e,t){var n,r,i=(0,o.createScanner)(e),s=[],a=0;do{switch(r=i.getPosition(),n=i.scan()){case 12:case 13:case 17:a!==r&&s.push(e.substring(a,r)),void 0!==t&&s.push(i.getTokenValue().replace(/[^\\r\\n]/g,t)),a=i.getPosition()}}while(17!==n);return s.join(\"\")}function g(e){switch(typeof e){case\"boolean\":return\"boolean\";case\"number\":return\"number\";case\"string\":return\"string\";case\"object\":return e?Array.isArray(e)?\"array\":\"object\":\"null\";default:return\"null\"}}!function(e){e.DEFAULT={allowTrailingComma:!1}}(r||(r={}))},(e,t,n)=>{Object.defineProperty(t,\"__esModule\",{value:!0}),t.BowerJSONContribution=void 0;const r=n(9),o=\"Visual Studio Code\";t.BowerJSONContribution=class{constructor(e){this.topRanked=[\"twitter\",\"bootstrap\",\"angular-1.1.6\",\"angular-latest\",\"angulerjs\",\"d3\",\"myjquery\",\"jq\",\"abcdef1234567890\",\"jQuery\",\"jquery-1.11.1\",\"jquery\",\"sushi-vanilla-x-data\",\"font-awsome\",\"Font-Awesome\",\"font-awesome\",\"fontawesome\",\"html5-boilerplate\",\"impress.js\",\"homebrew\",\"backbone\",\"moment1\",\"momentjs\",\"moment\",\"linux\",\"animate.css\",\"animate-css\",\"reveal.js\",\"jquery-file-upload\",\"blueimp-file-upload\",\"threejs\",\"express\",\"chosen\",\"normalize-css\",\"normalize.css\",\"semantic\",\"semantic-ui\",\"Semantic-UI\",\"modernizr\",\"underscore\",\"underscore1\",\"material-design-icons\",\"ionic\",\"chartjs\",\"Chart.js\",\"nnnick-chartjs\",\"select2-ng\",\"select2-dist\",\"phantom\",\"skrollr\",\"scrollr\",\"less.js\",\"leancss\",\"parser-lib\",\"hui\",\"bootstrap-languages\",\"async\",\"gulp\",\"jquery-pjax\",\"coffeescript\",\"hammer.js\",\"ace\",\"leaflet\",\"jquery-mobile\",\"sweetalert\",\"typeahead.js\",\"soup\",\"typehead.js\",\"sails\",\"codeigniter2\"],this.xhr=e}getDocumentSelector(){return[{language:\"json\",scheme:\"*\",pattern:\"**/bower.json\"},{language:\"json\",scheme:\"*\",pattern:\"**/.bower.json\"}]}isEnabled(){return!!r.workspace.getConfiguration(\"npm\").get(\"fetchOnlinePackageInfo\")}collectDefaultSuggestions(e,t){const n=new r.CompletionItem(r.l10n.t(\"Default bower.json\"));return n.kind=r.CompletionItemKind.Class,n.insertText=new r.SnippetString(JSON.stringify({name:\"${1:name}\",description:\"${2:description}\",authors:[\"${3:author}\"],version:\"${4:1.0.0}\",main:\"${5:pathToMain}\",dependencies:{}},null,\"\\t\")),t.add(n),Promise.resolve(null)}collectPropertySuggestions(e,t,n,i,s,a){if(!this.isEnabled())return null;if(t.matches([\"dependencies\"])||t.matches([\"devDependencies\"])){if(n.length>0){const e=\"https://registry.bower.io/packages/search/\"+encodeURIComponent(n);return this.xhr({url:e,headers:{agent:o}}).then((e=>{if(200!==e.status)return a.error(r.l10n.t(\"Request to the bower repository failed: {0}\",e.responseText)),0;try{const t=JSON.parse(e.responseText);if(Array.isArray(t)){const e=t;for(const t of e){const e=t.name,n=t.description||\"\",o=(new r.SnippetString).appendText(JSON.stringify(e));i&&(o.appendText(\": \").appendPlaceholder(\"latest\"),s||o.appendText(\",\"));const c=new r.CompletionItem(e);c.kind=r.CompletionItemKind.Property,c.insertText=o,c.filterText=JSON.stringify(e),c.documentation=n,a.add(c)}a.setAsIncomplete()}}catch(e){}}),(e=>(a.error(r.l10n.t(\"Request to the bower repository failed: {0}\",e.responseText)),0)))}return this.topRanked.forEach((e=>{const t=(new r.SnippetString).appendText(JSON.stringify(e));i&&(t.appendText(\": \").appendPlaceholder(\"latest\"),s||t.appendText(\",\"));const n=new r.CompletionItem(e);n.kind=r.CompletionItemKind.Property,n.insertText=t,n.filterText=JSON.stringify(e),n.documentation=\"\",a.add(n)})),a.setAsIncomplete(),Promise.resolve(null)}return null}collectValueSuggestions(e,t,n){if(!this.isEnabled())return null;if(t.matches([\"dependencies\",\"*\"])||t.matches([\"devDependencies\",\"*\"])){const e=new r.CompletionItem(r.l10n.t(\"latest\"));e.insertText=new r.SnippetString('\"${1:latest}\"'),e.filterText='\"\"',e.kind=r.CompletionItemKind.Value,e.documentation=\"The latest version of the package\",n.add(e)}return null}resolveSuggestion(e,t){if(t.kind===r.CompletionItemKind.Property&&\"\"===t.documentation){let e=t.label;return\"string\"!=typeof e&&(e=e.label),this.getInfo(e).then((e=>e?(t.documentation=e,t):null))}return null}getInfo(e){const t=\"https://registry.bower.io/packages/\"+encodeURIComponent(e);return this.xhr({url:t,headers:{agent:o}}).then((e=>{try{const t=JSON.parse(e.responseText);if(t&&t.url){let e=t.url;return 0===e.indexOf(\"git://\")&&(e=e.substring(6)),e.length>=4&&\".git\"===e.substr(e.length-4)&&(e=e.substring(0,e.length-4)),e}}catch(e){}}),(()=>{}))}getInfoContribution(e,t){if(!this.isEnabled())return null;if(t.matches([\"dependencies\",\"*\"])||t.matches([\"devDependencies\",\"*\"])){const e=t.path[t.path.length-1];if(\"string\"==typeof e)return this.getInfo(e).then((e=>{if(e){const t=new r.MarkdownString;return t.appendText(e),[t]}return null}))}return null}}},t=>{t.exports=e},(e,t,n)=>{Object.defineProperty(t,\"__esModule\",{value:!0}),t.PackageJSONContribution=void 0;const r=n(9),o=n(11),i=n(12),s=n(13),a=\"Visual Studio Code\";t.PackageJSONContribution=class{getDocumentSelector(){return[{language:\"json\",scheme:\"*\",pattern:\"**/package.json\"}]}constructor(e,t){this.xhr=e,this.npmCommandPath=t,this.mostDependedOn=[\"lodash\",\"async\",\"underscore\",\"request\",\"commander\",\"express\",\"debug\",\"chalk\",\"colors\",\"q\",\"coffee-script\",\"mkdirp\",\"optimist\",\"through2\",\"yeoman-generator\",\"moment\",\"bluebird\",\"glob\",\"gulp-util\",\"minimist\",\"cheerio\",\"pug\",\"redis\",\"node-uuid\",\"socket\",\"io\",\"uglify-js\",\"winston\",\"through\",\"fs-extra\",\"handlebars\",\"body-parser\",\"rimraf\",\"mime\",\"semver\",\"mongodb\",\"jquery\",\"grunt\",\"connect\",\"yosay\",\"underscore\",\"string\",\"xml2js\",\"ejs\",\"mongoose\",\"marked\",\"extend\",\"mocha\",\"superagent\",\"js-yaml\",\"xtend\",\"shelljs\",\"gulp\",\"yargs\",\"browserify\",\"minimatch\",\"react\",\"less\",\"prompt\",\"inquirer\",\"ws\",\"event-stream\",\"inherits\",\"mysql\",\"esprima\",\"jsdom\",\"stylus\",\"when\",\"readable-stream\",\"aws-sdk\",\"concat-stream\",\"chai\",\"Thenable\",\"wrench\"],this.knownScopes=[\"@types\",\"@angular\",\"@babel\",\"@nuxtjs\",\"@vue\",\"@bazel\"]}collectDefaultSuggestions(e,t){const n=new r.CompletionItem(r.l10n.t(\"Default package.json\"));return n.kind=r.CompletionItemKind.Module,n.insertText=new r.SnippetString(JSON.stringify({name:\"${1:name}\",description:\"${2:description}\",authors:\"${3:author}\",version:\"${4:1.0.0}\",main:\"${5:pathToMain}\",dependencies:{}},null,\"\\t\")),t.add(n),Promise.resolve(null)}isEnabled(){return this.npmCommandPath||this.onlineEnabled()}onlineEnabled(){return!!r.workspace.getConfiguration(\"npm\").get(\"fetchOnlinePackageInfo\")}collectPropertySuggestions(e,t,n,o,i,s){if(!this.isEnabled())return null;if(t.matches([\"dependencies\"])||t.matches([\"devDependencies\"])||t.matches([\"optionalDependencies\"])||t.matches([\"peerDependencies\"])){let e;if(n.length>0){if(\"@\"===n[0]){if(-1!==n.indexOf(\"/\"))return this.collectScopedPackages(n,o,i,s);for(const e of this.knownScopes){const t=new r.CompletionItem(e);t.kind=r.CompletionItemKind.Property,t.insertText=(new r.SnippetString).appendText(`\"${e}/`).appendTabstop().appendText('\"'),t.filterText=JSON.stringify(e),t.documentation=\"\",t.command={title:\"\",command:\"editor.action.triggerSuggest\"},s.add(t)}s.setAsIncomplete()}return e=`https://registry.npmjs.org/-/v1/search?size=40&text=${encodeURIComponent(n)}`,this.xhr({url:e,headers:{agent:a}}).then((e=>{if(200!==e.status)return s.error(r.l10n.t(\"Request to the NPM repository failed: {0}\",e.responseText)),0;try{const t=JSON.parse(e.responseText);if(t&&t.objects&&Array.isArray(t.objects)){const e=t.objects;for(const t of e)this.processPackage(t.package,o,i,s)}}catch(e){}s.setAsIncomplete()}),(e=>(s.error(r.l10n.t(\"Request to the NPM repository failed: {0}\",e.responseText)),0)))}return this.mostDependedOn.forEach((e=>{const t=(new r.SnippetString).appendText(JSON.stringify(e));o&&(t.appendText(': \"').appendTabstop().appendText('\"'),i||t.appendText(\",\"));const n=new r.CompletionItem(e);n.kind=r.CompletionItemKind.Property,n.insertText=t,n.filterText=JSON.stringify(e),n.documentation=\"\",s.add(n)})),this.collectScopedPackages(n,o,i,s),s.setAsIncomplete(),Promise.resolve(null)}return null}collectScopedPackages(e,t,n,o){const i=e.split(\"/\");if(2===i.length&&i[0].length>1){const e=i[0].substr(1);let s=i[1];s.length<4&&(s=\"\");const c=`https://registry.npmjs.com/-/v1/search?text=scope:${e}%20${s}&size=250`;return this.xhr({url:c,headers:{agent:a}}).then((e=>{if(200===e.status){try{const r=JSON.parse(e.responseText);if(r&&Array.isArray(r.objects)){const e=r.objects;for(const r of e)this.processPackage(r.package,t,n,o)}}catch(e){}o.setAsIncomplete()}else o.error(r.l10n.t(\"Request to the NPM repository failed: {0}\",e.responseText));return null}))}return Promise.resolve(null)}async collectValueSuggestions(e,t,n){if(!this.isEnabled())return null;if(t.matches([\"dependencies\",\"*\"])||t.matches([\"devDependencies\",\"*\"])||t.matches([\"optionalDependencies\",\"*\"])||t.matches([\"peerDependencies\",\"*\"])){const o=t.path[t.path.length-1];if(\"string\"==typeof o){const t=await this.fetchPackageInfo(o,e);if(t&&t.version){let e=JSON.stringify(t.version),o=new r.CompletionItem(e);o.kind=r.CompletionItemKind.Property,o.insertText=e,o.documentation=r.l10n.t(\"The currently latest version of the package\"),n.add(o),e=JSON.stringify(\"^\"+t.version),o=new r.CompletionItem(e),o.kind=r.CompletionItemKind.Property,o.insertText=e,o.documentation=r.l10n.t(\"Matches the most recent major version (1.x.x)\"),n.add(o),e=JSON.stringify(\"~\"+t.version),o=new r.CompletionItem(e),o.kind=r.CompletionItemKind.Property,o.insertText=e,o.documentation=r.l10n.t(\"Matches the most recent minor version (1.2.x)\"),n.add(o)}}}return null}getDocumentation(e,t,n,o){const i=new r.MarkdownString;return e&&i.appendText(e),t&&(i.appendText(\"\\n\\n\"),i.appendText(n?r.l10n.t(\"Latest version: {0} published {1}\",t,(0,s.fromNow)(Date.parse(n),!0,!0)):r.l10n.t(\"Latest version: {0}\",t))),o&&(i.appendText(\"\\n\\n\"),i.appendText(o)),i}resolveSuggestion(e,t){if(t.kind===r.CompletionItemKind.Property&&!t.documentation){let n=t.label;return\"string\"!=typeof n&&(n=n.label),this.fetchPackageInfo(n,e).then((e=>e?(t.documentation=this.getDocumentation(e.description,e.version,e.time,e.homepage),t):null))}return null}isValidNPMName(e){if(!e||e.length>214||e.match(/^[_.]/))return!1;const t=e.match(/^(?:@([^/]+?)[/])?([^/]+?)$/);if(t){const e=t[1];if(e&&encodeURIComponent(e)!==e)return!1;const n=t[2];return encodeURIComponent(n)===n}return!1}async fetchPackageInfo(e,t){if(!this.isValidNPMName(e))return;let n;return this.npmCommandPath&&(n=await this.npmView(this.npmCommandPath,e,t)),!n&&this.onlineEnabled()&&(n=await this.npmjsView(e)),n}npmView(e,t,n){return new Promise(((r,s)=>{const a=[\"view\",\"--json\",t,\"description\",\"dist-tags.latest\",\"homepage\",\"version\",\"time\"],c=n&&\"file\"===n.scheme?(0,i.dirname)(n.fsPath):void 0;o.execFile(e,a,{cwd:c},((e,t)=>{if(!e)try{const e=JSON.parse(t),n=e[\"dist-tags.latest\"]||e.version;return void r({description:e.description,version:n,time:e.time?.[n],homepage:e.homepage})}catch(e){}r(void 0)}))}))}async npmjsView(e){const t=\"https://registry.npmjs.org/\"+encodeURIComponent(e);try{const e=await this.xhr({url:t,headers:{agent:a}}),n=JSON.parse(e.responseText),r=n[\"dist-tags\"]?.latest||Object.keys(n.versions).pop()||\"\";return{description:n.description||\"\",version:r,time:n.time?.[r],homepage:n.homepage||\"\"}}catch(e){}}getInfoContribution(e,t){if(!this.isEnabled())return null;if(t.matches([\"dependencies\",\"*\"])||t.matches([\"devDependencies\",\"*\"])||t.matches([\"optionalDependencies\",\"*\"])||t.matches([\"peerDependencies\",\"*\"])){const n=t.path[t.path.length-1];if(\"string\"==typeof n)return this.fetchPackageInfo(n,e).then((e=>e?[this.getDocumentation(e.description,e.version,e.time,e.homepage)]:null))}return null}processPackage(e,t,n,o){if(e&&e.name){const i=e.name,s=(new r.SnippetString).appendText(JSON.stringify(i));t&&(s.appendText(': \"'),e.version?s.appendVariable(\"version\",e.version):s.appendTabstop(),s.appendText('\"'),n||s.appendText(\",\"));const a=new r.CompletionItem(i);a.kind=r.CompletionItemKind.Property,a.insertText=s,a.filterText=JSON.stringify(i),a.documentation=this.getDocumentation(e.description,e.version,void 0,e?.links?.homepage),o.add(a)}}}},()=>{},e=>{function t(e){if(\"string\"!=typeof e)throw new TypeError(\"Path must be a string. Received \"+JSON.stringify(e))}function n(e,t){for(var n,r=\"\",o=0,i=-1,s=0,a=0;a<=e.length;++a){if(a<e.length)n=e.charCodeAt(a);else{if(47===n)break;n=47}if(47===n){if(i===a-1||1===s);else if(i!==a-1&&2===s){if(r.length<2||2!==o||46!==r.charCodeAt(r.length-1)||46!==r.charCodeAt(r.length-2))if(r.length>2){var c=r.lastIndexOf(\"/\");if(c!==r.length-1){-1===c?(r=\"\",o=0):o=(r=r.slice(0,c)).length-1-r.lastIndexOf(\"/\"),i=a,s=0;continue}}else if(2===r.length||1===r.length){r=\"\",o=0,i=a,s=0;continue}t&&(r.length>0?r+=\"/..\":r=\"..\",o=2)}else r.length>0?r+=\"/\"+e.slice(i+1,a):r=e.slice(i+1,a),o=a-i-1;i=a,s=0}else 46===n&&-1!==s?++s:s=-1}return r}var r={resolve:function(){for(var e,r=\"\",o=!1,i=arguments.length-1;i>=-1&&!o;i--){var s;i>=0?s=arguments[i]:(void 0===e&&(e=process.cwd()),s=e),t(s),0!==s.length&&(r=s+\"/\"+r,o=47===s.charCodeAt(0))}return r=n(r,!o),o?r.length>0?\"/\"+r:\"/\":r.length>0?r:\".\"},normalize:function(e){if(t(e),0===e.length)return\".\";var r=47===e.charCodeAt(0),o=47===e.charCodeAt(e.length-1);return 0!==(e=n(e,!r)).length||r||(e=\".\"),e.length>0&&o&&(e+=\"/\"),r?\"/\"+e:e},isAbsolute:function(e){return t(e),e.length>0&&47===e.charCodeAt(0)},join:function(){if(0===arguments.length)return\".\";for(var e,n=0;n<arguments.length;++n){var o=arguments[n];t(o),o.length>0&&(void 0===e?e=o:e+=\"/\"+o)}return void 0===e?\".\":r.normalize(e)},relative:function(e,n){if(t(e),t(n),e===n)return\"\";if((e=r.resolve(e))===(n=r.resolve(n)))return\"\";for(var o=1;o<e.length&&47===e.charCodeAt(o);++o);for(var i=e.length,s=i-o,a=1;a<n.length&&47===n.charCodeAt(a);++a);for(var c=n.length-a,l=s<c?s:c,u=-1,f=0;f<=l;++f){if(f===l){if(c>l){if(47===n.charCodeAt(a+f))return n.slice(a+f+1);if(0===f)return n.slice(a+f)}else s>l&&(47===e.charCodeAt(o+f)?u=f:0===f&&(u=0));break}var d=e.charCodeAt(o+f);if(d!==n.charCodeAt(a+f))break;47===d&&(u=f)}var h=\"\";for(f=o+u+1;f<=i;++f)f!==i&&47!==e.charCodeAt(f)||(0===h.length?h+=\"..\":h+=\"/..\");return h.length>0?h+n.slice(a+u):(a+=u,47===n.charCodeAt(a)&&++a,n.slice(a))},_makeLong:function(e){return e},dirname:function(e){if(t(e),0===e.length)return\".\";for(var n=e.charCodeAt(0),r=47===n,o=-1,i=!0,s=e.length-1;s>=1;--s)if(47===(n=e.charCodeAt(s))){if(!i){o=s;break}}else i=!1;return-1===o?r?\"/\":\".\":r&&1===o?\"//\":e.slice(0,o)},basename:function(e,n){if(void 0!==n&&\"string\"!=typeof n)throw new TypeError('\"ext\" argument must be a string');t(e);var r,o=0,i=-1,s=!0;if(void 0!==n&&n.length>0&&n.length<=e.length){if(n.length===e.length&&n===e)return\"\";var a=n.length-1,c=-1;for(r=e.length-1;r>=0;--r){var l=e.charCodeAt(r);if(47===l){if(!s){o=r+1;break}}else-1===c&&(s=!1,c=r+1),a>=0&&(l===n.charCodeAt(a)?-1==--a&&(i=r):(a=-1,i=c))}return o===i?i=c:-1===i&&(i=e.length),e.slice(o,i)}for(r=e.length-1;r>=0;--r)if(47===e.charCodeAt(r)){if(!s){o=r+1;break}}else-1===i&&(s=!1,i=r+1);return-1===i?\"\":e.slice(o,i)},extname:function(e){t(e);for(var n=-1,r=0,o=-1,i=!0,s=0,a=e.length-1;a>=0;--a){var c=e.charCodeAt(a);if(47!==c)-1===o&&(i=!1,o=a+1),46===c?-1===n?n=a:1!==s&&(s=1):-1!==n&&(s=-1);else if(!i){r=a+1;break}}return-1===n||-1===o||0===s||1===s&&n===o-1&&n===r+1?\"\":e.slice(n,o)},format:function(e){if(null===e||\"object\"!=typeof e)throw new TypeError('The \"pathObject\" argument must be of type Object. Received type '+typeof e);return function(e,t){var n=t.dir||t.root,r=t.base||(t.name||\"\")+(t.ext||\"\");return n?n===t.root?n+r:n+e+r:r}(\"/\",e)},parse:function(e){t(e);var n={root:\"\",dir:\"\",base:\"\",ext:\"\",name:\"\"};if(0===e.length)return n;var r,o=e.charCodeAt(0),i=47===o;i?(n.root=\"/\",r=1):r=0;for(var s=-1,a=0,c=-1,l=!0,u=e.length-1,f=0;u>=r;--u)if(47!==(o=e.charCodeAt(u)))-1===c&&(l=!1,c=u+1),46===o?-1===s?s=u:1!==f&&(f=1):-1!==s&&(f=-1);else if(!l){a=u+1;break}return-1===s||-1===c||0===f||1===f&&s===c-1&&s===a+1?-1!==c&&(n.base=n.name=0===a&&i?e.slice(1,c):e.slice(a,c)):(0===a&&i?(n.name=e.slice(1,s),n.base=e.slice(1,c)):(n.name=e.slice(a,s),n.base=e.slice(a,c)),n.ext=e.slice(s,c)),a>0?n.dir=e.slice(0,a-1):i&&(n.dir=\"/\"),n},sep:\"/\",delimiter:\":\",win32:null,posix:null};r.posix=r,e.exports=r},(e,t,n)=>{Object.defineProperty(t,\"__esModule\",{value:!0}),t.fromNow=void 0;const r=n(9),o=3600,i=86400,s=7*i,a=30*i,c=365*i;t.fromNow=function e(t,n,l,u){\"number\"!=typeof t&&(t=t.getTime());const f=Math.round(((new Date).getTime()-t)/1e3);if(f<-30)return r.l10n.t(\"in {0}\",e((new Date).getTime()+1e3*f,!1));if(!u&&f<30)return r.l10n.t(\"now\");let d;return f<60?(d=f,n?1===d?l?r.l10n.t(\"{0} second ago\",d):r.l10n.t(\"{0} sec ago\",d):l?r.l10n.t(\"{0} seconds ago\",d):r.l10n.t(\"{0} secs ago\",d):1===d?l?r.l10n.t(\"{0} second\",d):r.l10n.t(\"{0} sec\",d):l?r.l10n.t(\"{0} seconds\",d):r.l10n.t(\"{0} secs\",d)):f<o?(d=Math.floor(f/60),n?1===d?l?r.l10n.t(\"{0} minute ago\",d):r.l10n.t(\"{0} min ago\",d):l?r.l10n.t(\"{0} minutes ago\",d):r.l10n.t(\"{0} mins ago\",d):1===d?l?r.l10n.t(\"{0} minute\",d):r.l10n.t(\"{0} min\",d):l?r.l10n.t(\"{0} minutes\",d):r.l10n.t(\"{0} mins\",d)):f<i?(d=Math.floor(f/o),n?1===d?l?r.l10n.t(\"{0} hour ago\",d):r.l10n.t(\"{0} hr ago\",d):l?r.l10n.t(\"{0} hours ago\",d):r.l10n.t(\"{0} hrs ago\",d):1===d?l?r.l10n.t(\"{0} hour\",d):r.l10n.t(\"{0} hr\",d):l?r.l10n.t(\"{0} hours\",d):r.l10n.t(\"{0} hrs\",d)):f<s?(d=Math.floor(f/i),n?1===d?r.l10n.t(\"{0} day ago\",d):r.l10n.t(\"{0} days ago\",d):1===d?r.l10n.t(\"{0} day\",d):r.l10n.t(\"{0} days\",d)):f<a?(d=Math.floor(f/s),n?1===d?l?r.l10n.t(\"{0} week ago\",d):r.l10n.t(\"{0} wk ago\",d):l?r.l10n.t(\"{0} weeks ago\",d):r.l10n.t(\"{0} wks ago\",d):1===d?l?r.l10n.t(\"{0} week\",d):r.l10n.t(\"{0} wk\",d):l?r.l10n.t(\"{0} weeks\",d):r.l10n.t(\"{0} wks\",d)):f<c?(d=Math.floor(f/a),n?1===d?l?r.l10n.t(\"{0} month ago\",d):r.l10n.t(\"{0} mo ago\",d):l?r.l10n.t(\"{0} months ago\",d):r.l10n.t(\"{0} mos ago\",d):1===d?l?r.l10n.t(\"{0} month\",d):r.l10n.t(\"{0} mo\",d):l?r.l10n.t(\"{0} months\",d):r.l10n.t(\"{0} mos\",d)):(d=Math.floor(f/c),n?1===d?l?r.l10n.t(\"{0} year ago\",d):r.l10n.t(\"{0} yr ago\",d):l?r.l10n.t(\"{0} years ago\",d):r.l10n.t(\"{0} yrs ago\",d):1===d?l?r.l10n.t(\"{0} year\",d):r.l10n.t(\"{0} yr\",d):l?r.l10n.t(\"{0} years\",d):r.l10n.t(\"{0} yrs\",d))}}],r={};function o(e){var n=r[e];if(void 0!==n)return n.exports;var i=r[e]={exports:{}};return t[e](i,i.exports,o),i.exports}o.d=(e,t)=>{for(var n in t)o.o(t,n)&&!o.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},o.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),o.r=e=>{\"undefined\"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:\"Module\"}),Object.defineProperty(e,\"__esModule\",{value:!0})};var i={};(()=>{var e=i;Object.defineProperty(e,\"__esModule\",{value:!0}),e.deactivate=e.activate=void 0;const t=o(1),n=o(2);e.activate=async function(e){e.subscriptions.push((0,n.addJSONProviders)(t.xhr,void 0))},e.deactivate=function(){}})();var s=n;for(var a in i)s[a]=i[a];i.__esModule&&Object.defineProperty(s,\"__esModule\",{value:!0})})();var o=t(r);module.exports=o;\n";
|
|
2
|
+
export { npmBrowserMain_js as default };
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
var manifest = {name:"npm",publisher:"vscode",displayName:"NPM support for VS Code",description:"Extension to add task support for npm scripts.",version:"1.0.1",license:"MIT",engines:{vscode:"0.10.x"},icon:"images/npm_icon.png",categories:["Other"],enabledApiProposals:["terminalQuickFixProvider"],scripts:{compile:"gulp compile-extension:npm",watch:"gulp watch-extension:npm"},dependencies:{"find-up":"^4.1.0","find-yarn-workspace-root":"^2.0.0","jsonc-parser":"^2.2.1",minimatch:"^3.0.4","request-light":"^0.7.0",which:"^2.0.2","which-pm":"^2.0.0"},devDependencies:{"@types/minimatch":"^3.0.3","@types/node":"16.x","@types/which":"^2.0.0"},resolutions:{"which-pm/load-yaml-file/**/argparse":"1.0.9"},main:"./out/npmMain",browser:"./dist/browser/npmBrowserMain",activationEvents:["onTaskType:npm","onLanguage:json","workspaceContains:package.json"],capabilities:{virtualWorkspaces:{supported:"limited",description:"Functionality that requires running the 'npm' command is not available in virtual workspaces."},untrustedWorkspaces:{supported:"limited",description:"This extension executes tasks, which require trust to run."}},contributes:{languages:[{id:"ignore",extensions:[".npmignore"]},{id:"properties",extensions:[".npmrc"]}],views:{explorer:[{id:"npm",name:"NPM Scripts",when:"npm:showScriptExplorer",icon:"$(json)",visibility:"hidden",contextualTitle:"NPM Scripts"}]},commands:[{command:"npm.runScript",title:"Run",icon:"$(run)"},{command:"npm.debugScript",title:"Debug",icon:"$(debug)"},{command:"npm.openScript",title:"Open"},{command:"npm.runInstall",title:"Run Install"},{command:"npm.refresh",title:"Refresh",icon:"$(refresh)"},{command:"npm.runSelectedScript",title:"Run Script"},{command:"npm.runScriptFromFolder",title:"Run NPM Script in Folder..."},{command:"npm.packageManager",title:"Get Configured Package Manager"}],menus:{commandPalette:[{command:"npm.refresh",when:"false"},{command:"npm.runScript",when:"false"},{command:"npm.debugScript",when:"false"},{command:"npm.openScript",when:"false"},{command:"npm.runInstall",when:"false"},{command:"npm.runSelectedScript",when:"false"},{command:"npm.runScriptFromFolder",when:"false"},{command:"npm.packageManager",when:"false"}],"editor/context":[{command:"npm.runSelectedScript",when:"resourceFilename == 'package.json' && resourceScheme == file",group:"navigation@+1"}],"view/title":[{command:"npm.refresh",when:"view == npm",group:"navigation"}],"view/item/context":[{command:"npm.openScript",when:"view == npm && viewItem == packageJSON",group:"navigation@1"},{command:"npm.runInstall",when:"view == npm && viewItem == packageJSON",group:"navigation@2"},{command:"npm.openScript",when:"view == npm && viewItem == script",group:"navigation@1"},{command:"npm.runScript",when:"view == npm && viewItem == script",group:"navigation@2"},{command:"npm.runScript",when:"view == npm && viewItem == script",group:"inline"},{command:"npm.debugScript",when:"view == npm && viewItem == script",group:"inline"},{command:"npm.debugScript",when:"view == npm && viewItem == script",group:"navigation@3"}],"explorer/context":[{when:"config.npm.enableRunFromFolder && explorerViewletVisible && explorerResourceIsFolder && resourceScheme == file",command:"npm.runScriptFromFolder",group:"2_workspace"}]},configuration:{id:"npm",type:"object",title:"Npm",properties:{"npm.autoDetect":{type:"string","enum":["off","on"],"default":"on",scope:"resource",description:"Controls whether npm scripts should be automatically detected."},"npm.runSilent":{type:"boolean","default":false,scope:"resource",markdownDescription:"Run npm commands with the `--silent` option."},"npm.packageManager":{scope:"resource",type:"string","enum":["auto","npm","yarn","pnpm"],enumDescriptions:["Auto-detect which package manager to use for running scripts based on lock files and installed package managers.","Use npm as the package manager for running scripts.","Use yarn as the package manager for running scripts.","Use pnpm as the package manager for running scripts."],"default":"auto",description:"The package manager used to run scripts."},"npm.exclude":{type:["string","array"],items:{type:"string"},description:"Configure glob patterns for folders that should be excluded from automatic script detection.",scope:"resource"},"npm.enableScriptExplorer":{type:"boolean","default":false,scope:"resource",deprecationMessage:"The NPM Script Explorer is now available in 'Views' menu in the Explorer in all folders.",description:"Enable an explorer view for npm scripts when there is no top-level 'package.json' file."},"npm.enableRunFromFolder":{type:"boolean","default":false,scope:"resource",description:"Enable running npm scripts contained in a folder from the Explorer context menu."},"npm.scriptExplorerAction":{type:"string","enum":["open","run"],markdownDescription:"The default click action used in the NPM Scripts Explorer: `open` or `run`, the default is `open`.",scope:"window","default":"open"},"npm.scriptExplorerExclude":{type:"array",items:{type:"string"},markdownDescription:"An array of regular expressions that indicate which scripts should be excluded from the NPM Scripts view.",scope:"resource","default":[]},"npm.fetchOnlinePackageInfo":{type:"boolean",description:"Fetch data from https://registry.npmjs.org and https://registry.bower.io to provide auto-completion and information on hover features on npm dependencies.","default":true,scope:"window",tags:["usesOnlineServices"]},"npm.scriptHover":{type:"boolean",description:"Display hover with 'Run' and 'Debug' commands for scripts.","default":true,scope:"window"}}},jsonValidation:[{fileMatch:"package.json",url:"https://json.schemastore.org/package"},{fileMatch:"bower.json",url:"https://json.schemastore.org/bower"}],taskDefinitions:[{type:"npm",required:["script"],properties:{script:{type:"string",description:"The npm script to customize."},path:{type:"string",description:"The path to the folder of the package.json file that provides the script. Can be omitted."}},when:"shellExecutionSupported"}],terminalQuickFixes:[{id:"ms-vscode.npm-command",commandLineMatcher:"npm",commandExitResult:"error",outputMatcher:{anchor:"bottom",length:8,lineMatcher:"Did you mean (?:this|one of these)\\?((?:\\n.+?npm .+ #.+)+)",offset:2}}]},repository:{type:"git",url:"https://github.com/microsoft/vscode.git"}};
|
|
2
|
+
export { manifest as default };
|