1
|
{"version":3,"sources":["webpack:///./node_modules/highlight.js/lib/languages/typescript.js"],"names":["module","exports","hljs","KEYWORDS","keyword","literal","built_in","DECORATOR","className","begin","ARGS","end","keywords","contains","QUOTE_STRING_MODE","APOS_STRING_MODE","NUMBER_MODE","PARAMS","excludeBegin","excludeEnd","C_LINE_COMMENT_MODE","C_BLOCK_COMMENT_MODE","NUMBER","variants","C_NUMBER_RE","relevance","SUBST","HTML_TEMPLATE","starts","returnEnd","BACKSLASH_ESCAPE","subLanguage","CSS_TEMPLATE","TEMPLATE_STRING","REGEXP_MODE","aliases","RE_STARTERS_RE","IDENT_RE","returnBegin","beginKeywords","inherit","TITLE_MODE","illegal"],"mappings":"qFAAAA,EAAOC,QAAU,SAASC,GACxB,IACIC,EAAW,CACbC,QACE,mTAKFC,QACE,yCACFC,SACE,6fASAC,EAAY,CACdC,UAAW,OACXC,MAAO,6BAGLC,EACJ,CACED,MAAO,MACPE,IAAK,KACLC,SAAUT,EACVU,SAAU,CACR,OACAX,EAAKY,kBACLZ,EAAKa,iBACLb,EAAKc,cAILC,EAAS,CACXT,UAAW,SACXC,MAAO,KAAME,IAAK,KAClBO,cAAc,EACdC,YAAY,EACZP,SAAUT,EACVU,SAAU,CACRX,EAAKkB,oBACLlB,EAAKmB,qBACLd,EACAG,IAGAY,EAAS,CACXd,UAAW,SACXe,SAAU,CACR,CAAEd,MAAO,qBACT,CAAEA,MAAO,sBACT,CAAEA,MAAOP,EAAKsB,YAAc,OAE9BC,UAAW,GAETC,EAAQ,CACVlB,UAAW,QACXC,MAAO,SAAUE,IAAK,MACtBC,SAAUT,EACVU,SAAU,IAERc,EAAgB,CAClBlB,MAAO,QAASE,IAAK,GACrBiB,OAAQ,CACNjB,IAAK,IAAKkB,WAAW,EACrBhB,SAAU,CACRX,EAAK4B,iBACLJ,GAEFK,YAAa,QAGbC,EAAe,CACjBvB,MAAO,OAAQE,IAAK,GACpBiB,OAAQ,CACNjB,IAAK,IAAKkB,WAAW,EACrBhB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U,qBAEZ,CACEH,MAAO,UAET,CACEA,MAAO,MAAQP,EAAKmC,SAAUZ,UAAW,GAE3ClB,EACAG","file":"highlight/typescript.js?v=132c46c22e5b099b0393","sourcesContent":["module.exports = function(hljs) {\n var JS_IDENT_RE = '[A-Za-z$_][0-9A-Za-z$_]*';\n var KEYWORDS = {\n keyword:\n 'in if for while finally var new function do return void else break catch ' +\n 'instanceof with throw case default try this switch continue typeof delete ' +\n 'let yield const class public private protected get set super ' +\n 'static implements enum export import declare type namespace abstract ' +\n 'as from extends async await',\n literal:\n 'true false null undefined NaN Infinity',\n built_in:\n 'eval isFinite isNaN parseFloat parseInt decodeURI decodeURIComponent ' +\n 'encodeURI encodeURIComponent escape unescape Object Function Boolean Error ' +\n 'EvalError InternalError RangeError ReferenceError StopIteration SyntaxError ' +\n 'TypeError URIError Number Math Date String RegExp Array Float32Array ' +\n 'Float64Array Int16Array Int32Array Int8Array Uint16Array Uint32Array ' +\n 'Uint8Array Uint8ClampedArray ArrayBuffer DataView JSON Intl arguments require ' +\n 'module console window document any number boolean string void Promise'\n };\n\n var DECORATOR = {\n className: 'meta',\n begin: '@' + JS_IDENT_RE,\n };\n\n var ARGS =\n {\n begin: '\\\\(',\n end: /\\)/,\n keywords: KEYWORDS,\n contains: [\n 'self',\n hljs.QUOTE_STRING_MODE,\n hljs.APOS_STRING_MODE,\n hljs.NUMBER_MODE\n ]\n };\n\n var PARAMS = {\n className: 'params',\n begin: /\\(/, end: /\\)/,\n excludeBegin: true,\n excludeEnd: true,\n keywords: KEYWORDS,\n contains: [\n hljs.C_LINE_COMMENT_MODE,\n hljs.C_BLOCK_COMMENT_MODE,\n DECORATOR,\n ARGS\n ]\n };\n var NUMBER = {\n className: 'number',\n variants: [\n { begin: '\\\\b(0[bB][01]+)n?' },\n { begin: '\\\\b(0[oO][0-7]+)n?' },\n { begin: hljs.C_NUMBER_RE + 'n?' }\n ],\n relevance: 0\n };\n var SUBST = {\n className: 'subst',\n begin: '\\\\$\\\\{', end: '\\\\}',\n keywords: KEYWORDS,\n contains: [] // defined later\n };\n var HTML_TEMPLATE = {\n begin: 'html`', end: '',\n starts: {\n end: '`', returnEnd: false,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n SUBST\n ],\n subLanguage: 'xml',\n }\n };\n var CSS_TEMPLATE = {\n begin: 'css`', end: '',\n starts: {\n end: '`', returnEnd: false,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n SUBST\n ],\n subLanguage: 'css',\n }\n };\n var TEMPLATE_STRING = {\n className: 'string',\n begin: '`', end: '`',\n contains: [\n hljs.BACKSLASH_ESCAPE,\n SUBST\n ]\n };\n SUBST.contains = [\n hljs.APOS_STRING_MODE,\n hljs.QUOTE_STRING_MODE,\n HTML_TEMPLATE,\n CSS_TEMPLATE,\n TEMPLATE_STRING,\n NUMBER,\n hljs.REGEXP_MODE\n ];\n\n\n\n return {\n aliases: ['ts'],\n keywords: KEYWORDS,\n contains: [\n {\n className: 'meta',\n begin: /^\\s*['\"]use strict['\"]/\n },\n hljs.APOS_STRING_MODE,\n hljs.QUOTE_STRING_MODE,\n HTML_TEMPLATE,\n CSS_TEMPLATE,\n TEMPLATE_STRING,\n hljs.C_LINE_COMMENT_MODE,\n hljs.C_BLOCK_COMMENT_MODE,\n NUMBER,\n { // \"value\" container\n begin: '(' + hljs.RE_STARTERS_RE + '|\\\\b(case|return|throw)\\\\b)\\\\s*',\n keywords: 'return throw case',\n contains: [\n hljs.C_LINE_COMMENT_MODE,\n hljs.C_BLOCK_COMMENT_MODE,\n hljs.REGEXP_MODE,\n {\n className: 'function',\n begin: '(\\\\(.*?\\\\)|' + hljs.IDENT_RE + ')\\\\s*=>', returnBegin: true,\n end: '\\\\s*=>',\n contains: [\n {\n className: 'params',\n variants: [\n {\n begin: hljs.IDENT_RE\n },\n {\n begin: /\\(\\s*\\)/,\n },\n {\n begin: /\\(/, end: /\\)/,\n excludeBegin: true, excludeEnd: true,\n keywords: KEYWORDS,\n contains: [\n 'self',\n hljs.C_LINE_COMMENT_MODE,\n hljs.C_BLOCK_COMMENT_MODE\n ]\n }\n ]\n }\n ]\n }\n ],\n relevance: 0\n },\n {\n className: 'function',\n beginKeywords: 'function', end: /[\\{;]/, excludeEnd: true,\n keywords: KEYWORDS,\n contains: [\n 'self',\n hljs.inherit(hljs.TITLE_MODE, { begin: JS_IDENT_RE }),\n PARAMS\n ],\n illegal: /%/,\n relevance: 0 // () => {} is more typical in TypeScript\n },\n {\n beginKeywords: 'constructor', end: /[\\{;]/, excludeEnd: true,\n contains: [\n 'self',\n PARAMS\n ]\n },\n { // prevent references like module.id from being higlighted as module definitions\n begin: /module\\./,\n keywords: { built_in: 'module' },\n relevance: 0\n },\n {\n beginKeywords: 'module', end: /\\{/, excludeEnd: true\n },\n {\n beginKeywords: 'interface', end: /\\{/, excludeEnd: true,\n keywords: 'interface extends'\n },\n {\n begin: /\\$[(.]/ // relevance booster for a pattern common to JS libs: `$(something)` and `$.something`\n },\n {\n begin: '\\\\.' + hljs.IDENT_RE, relevance: 0 // hack: prevents detection of keywords after dots\n },\n DECORATOR,\n ARGS\n ]\n };\n};"],"sourceRoot":""}
|