@aiao/code-editor-vue 0.0.7 → 0.0.8
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/apl-B2DGVGxc-Dd6D39pP.js +76 -0
- package/dist/asciiarmor-2LVJmxlE-CAn4gnoC.js +34 -0
- package/dist/asn1-jKiBa2Ya-xsKwdyq9.js +95 -0
- package/dist/asterisk-DS281yxp-B5eTWk_B.js +271 -0
- package/dist/brainfuck-C_p9pTT8-DKVQ9poL.js +34 -0
- package/dist/clike-BMALKCNj-Ck7Gc35_.js +620 -0
- package/dist/clojure-CCKyeQKf-N9sg777Z.js +800 -0
- package/dist/cmake-CuaCgAKt-BbEgXraO.js +28 -0
- package/dist/cobol-BlTKFDRj-CHCoWafp.js +72 -0
- package/dist/coffeescript-BVCvwO8I-Z15ai5ac.js +179 -0
- package/dist/commonlisp-D_kxz07b-Ce7sn14o.js +75 -0
- package/dist/crystal-D309uH6_-DS6LrXoE.js +217 -0
- package/dist/css-BkF-NPzE-DiJu9Nkd.js +1553 -0
- package/dist/cypher-BMq4Fwjl-Ml-omWgp.js +68 -0
- package/dist/d-BZcgY6La-KCW6-bIm.js +127 -0
- package/dist/diff-Cg9d_RX2-C01qBVFc.js +18 -0
- package/dist/dockerfile-DFX8bq9N-BIbYUQV0.js +194 -0
- package/dist/dtd-CtLokQ-U-DCbNdeIA.js +84 -0
- package/dist/dylan-QYeExnWK-DIUVpsct.js +234 -0
- package/dist/ebnf-DUPDuY4r-7HIXKmWn.js +78 -0
- package/dist/ecl-CiXN-g_D-DOI-W0if.js +121 -0
- package/dist/eiffel-yQhjl4T1-DIX8Ceq1.js +110 -0
- package/dist/elm-CNT9vbN0-BcYlydpO.js +108 -0
- package/dist/erlang-CFOYdy9e-DULXsFZl.js +487 -0
- package/dist/factor-Clf6BoVk-DBb2EHMF.js +65 -0
- package/dist/fcl-CPC2WYrI-CuXG3fcK.js +103 -0
- package/dist/forth-BmxRyE9S-BcFwWpeL.js +60 -0
- package/dist/fortran-9bvPyrOW-CuLcq-Iu.js +442 -0
- package/dist/gas-cpmYfFX2-sZgGhMxB.js +183 -0
- package/dist/gherkin-CJuwpceU-BRrr8yjO.js +34 -0
- package/dist/groovy-DZeT_VM--CmF8wcSo.js +146 -0
- package/dist/haskell-CxiO_7JL-BuULsXvv.js +375 -0
- package/dist/haxe-70NVW1pR-CM27SfgM.js +359 -0
- package/dist/http-D9LttvKF-j9E8oQ7o.js +44 -0
- package/dist/idl-B6TRFYjl-B6TRFYjl.js +947 -0
- package/dist/index-BMiCCEB1-Bhkem_yf.js +305 -0
- package/dist/index-BNuasEBW-Djq6JMRj.js +94 -0
- package/dist/index-Bg1KDWyt-DaNGMguF.js +290 -0
- package/dist/{index-D6_k5ZgA.js → index-BuVm7ZG6-BZLKs8s6.js} +106 -106
- package/dist/index-BvS1cnHq-DM0hbFEQ.js +613 -0
- package/dist/index-C44L0DmY-BmmnwVzM.js +138 -0
- package/dist/index-C71CZfUx-CXN80Lrt.js +247 -0
- package/dist/{index-BluJGN_u.js → index-CQ6JWNwi-BkIQd0CX.js} +131 -130
- package/dist/index-CpRVx97--qRVKhpm0.js +342 -0
- package/dist/index-CqvQj6d--Cks52f8R.js +270 -0
- package/dist/index-CrbQBmWq-CH-PcW1J.js +157 -0
- package/dist/index-CzovO10m-BGtdggaq.js +301 -0
- package/dist/index-D0BZOY-S-DP1N-_JY.js +101 -0
- package/dist/{index-DcMCsmYb.js → index-D0svJS59-B1ELwWap.js} +79 -78
- package/dist/index-D93XVMi1-BA3BTMNq.js +136 -0
- package/dist/index-DEB5VK0f-DmPMy-wS.js +252 -0
- package/dist/index-Dp8osI_J-_47iGH9z.js +960 -0
- package/dist/index-Ds4AioqO-C6aO_ISw.js +1917 -0
- package/dist/{index-DBgKi_NE.js → index-Dy-OpkyQ-BBMsyHBR.js} +18 -18
- package/dist/index-Dyi9rNIT-DTaMAKyY.js +391 -0
- package/dist/index-ZJkjD9tT-CsDrbsME.js +74 -0
- package/dist/index-qH2lMs0G-VT1Nd_LF.js +944 -0
- package/dist/index-srIksFxX-jkv39JhL.js +59 -0
- package/dist/index-wcsJ2mym.js +31598 -0
- package/dist/index.d.ts +0 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -3
- package/dist/javascript-DOuB9oqA-BxiygWgm.js +691 -0
- package/dist/julia-DpvXAuO6-Bk_IfD8X.js +241 -0
- package/dist/livescript-CanGTf8u-Cx6PrvS4.js +272 -0
- package/dist/lua-XplVlWi_-8f8obHzY.js +217 -0
- package/dist/mathematica-jaRHnSxC-B83gQsL2.js +35 -0
- package/dist/mbox-BctzC1hL-Hg5U2B4l.js +76 -0
- package/dist/mirc-CFBPAOaF-CfzSSk9W.js +72 -0
- package/dist/mllike-BSnXJBGA-Ao1NpT2u.js +272 -0
- package/dist/modelica-vUgVs--1-BObVpYBg.js +93 -0
- package/dist/mscgen-Cpl0NYLN-DqNArLGH.js +104 -0
- package/dist/mumps-CQoS1kWX-CkTUOQnt.js +25 -0
- package/dist/nginx-zDPm3Z74-DJk4KP7N.js +87 -0
- package/dist/nsis-BCLyjY7m-C2MffOQ3.js +62 -0
- package/dist/ntriples-CsNjv2QF-C4aZn3EO.js +79 -0
- package/dist/octave-C8PmmSRH-DM5vTWlU.js +143 -0
- package/dist/oz-Ce8aN8oE-BcJM4SVy.js +151 -0
- package/dist/pascal-De0D6mP7-D7DGFFKL.js +77 -0
- package/dist/perl-B4bSCe1C-6aIa2glS.js +915 -0
- package/dist/pig-D24Z8EXi-BD-qt5FU.js +54 -0
- package/dist/powershell-DkYVfTzP-Blt1Rodi.js +249 -0
- package/dist/properties-Dn9wna3M-EOOwnCnk.js +26 -0
- package/dist/protobuf-BPIjwpzm-DAButU8_.js +49 -0
- package/dist/pug-TGXr6c5j-C9HfQ86E.js +248 -0
- package/dist/puppet-nyd4dhjf-CGzH5dsa.js +45 -0
- package/dist/python-BkR3uSy8-CjDnyp3B.js +313 -0
- package/dist/q-DyHZGnqm-DGuqeH_T.js +86 -0
- package/dist/r-LKEuhEGI-BFQhJnTP.js +104 -0
- package/dist/rpm-IznJm2Xc-CbZqrWCM.js +57 -0
- package/dist/ruby-CcYfvIk6-DzPSfSGo.js +228 -0
- package/dist/sas-7E8yHoCW-D726Uzkw.js +105 -0
- package/dist/scheme-DjibxsNh-Bp5gVFkm.js +124 -0
- package/dist/shell-C0C2sNA_-BTeYg6ir.js +182 -0
- package/dist/sieve-Bwz7vjP5-Cw8iTBf7.js +72 -0
- package/dist/simple-mode-mNVtnu0l-BC8mf7KF.js +89 -0
- package/dist/smalltalk-Bhddl2pB-B7URiJSp.js +48 -0
- package/dist/solr-BNlsLglM-BM2OpfTI.js +41 -0
- package/dist/sparql-FarWu_Gb-FN_uQNd4.js +197 -0
- package/dist/spreadsheet-C-cy4P5N-5CSTwVYq.js +49 -0
- package/dist/sql-CfG5lQ3l-Bd4dgm_8.js +278 -0
- package/dist/stex-Du4h4KAU-QOov_zHj.js +129 -0
- package/dist/stylus-CAdqWld3-BcRBbBxD.js +250 -0
- package/dist/swift-DSxqR9R6-2Hz4NOoF.js +230 -0
- package/dist/tcl-xfoLljhY-DAZBRGQI.js +81 -0
- package/dist/textile-D1AWE-pc-DuiIfEnb.js +295 -0
- package/dist/tiddlywiki-5wqsXtSk-WuF_8VUv.js +155 -0
- package/dist/tiki-__Kn3CeS-CWcR9ib_.js +181 -0
- package/dist/toml-DWAmxCjl-CyJoDzs6.js +56 -0
- package/dist/troff-D2UO-fKf-DVoIzS-O.js +35 -0
- package/dist/ttcn-Bsa4sfRm-hoy08sYQ.js +123 -0
- package/dist/ttcn-cfg-Bac_acMi-DaC4kQpd.js +88 -0
- package/dist/turtle-xwJUxoPV-fs94wdNM.js +80 -0
- package/dist/vb-c2kQGd6--DU726qF0.js +74 -0
- package/dist/vbscript-1f_Dhg5H-DriA32xD.js +324 -0
- package/dist/velocity-DJd0pTTC-BG368IR6.js +96 -0
- package/dist/verilog-CiS1jyi5-giQA8J-e.js +259 -0
- package/dist/vhdl-T9HkrbI2-BJ8LEDog.js +106 -0
- package/dist/webidl-CjfDENEo-BM8KXKJ5.js +155 -0
- package/dist/xquery-Ct6lEb4B-C5KDc61l.js +422 -0
- package/dist/yacas-C0absKBh-B82QJ76F.js +73 -0
- package/dist/z80-Pki2zAjW-B0IQoIbR.js +61 -0
- package/package.json +8 -10
- package/dist/index-3d5LPf68.js +0 -19017
- package/dist/languages.d.ts +0 -3
- package/dist/languages.d.ts.map +0 -1
|
@@ -0,0 +1,691 @@
|
|
|
1
|
+
function ie(b) {
|
|
2
|
+
var ke = b.statementIndent, ue = b.jsonld, ye = b.json || ue, p = b.typescript, L = b.wordCharacters || /[\w$\xa1-\uffff]/, ve = (function() {
|
|
3
|
+
function e(g) {
|
|
4
|
+
return { type: g, style: "keyword" };
|
|
5
|
+
}
|
|
6
|
+
var t = e("keyword a"), n = e("keyword b"), i = e("keyword c"), u = e("keyword d"), c = e("operator"), m = { type: "atom", style: "atom" };
|
|
7
|
+
return {
|
|
8
|
+
if: e("if"),
|
|
9
|
+
while: t,
|
|
10
|
+
with: t,
|
|
11
|
+
else: n,
|
|
12
|
+
do: n,
|
|
13
|
+
try: n,
|
|
14
|
+
finally: n,
|
|
15
|
+
return: u,
|
|
16
|
+
break: u,
|
|
17
|
+
continue: u,
|
|
18
|
+
new: e("new"),
|
|
19
|
+
delete: i,
|
|
20
|
+
void: i,
|
|
21
|
+
throw: i,
|
|
22
|
+
debugger: e("debugger"),
|
|
23
|
+
var: e("var"),
|
|
24
|
+
const: e("var"),
|
|
25
|
+
let: e("var"),
|
|
26
|
+
function: e("function"),
|
|
27
|
+
catch: e("catch"),
|
|
28
|
+
for: e("for"),
|
|
29
|
+
switch: e("switch"),
|
|
30
|
+
case: e("case"),
|
|
31
|
+
default: e("default"),
|
|
32
|
+
in: c,
|
|
33
|
+
typeof: c,
|
|
34
|
+
instanceof: c,
|
|
35
|
+
true: m,
|
|
36
|
+
false: m,
|
|
37
|
+
null: m,
|
|
38
|
+
undefined: m,
|
|
39
|
+
NaN: m,
|
|
40
|
+
Infinity: m,
|
|
41
|
+
this: e("this"),
|
|
42
|
+
class: e("class"),
|
|
43
|
+
super: e("atom"),
|
|
44
|
+
yield: i,
|
|
45
|
+
export: e("export"),
|
|
46
|
+
import: e("import"),
|
|
47
|
+
extends: i,
|
|
48
|
+
await: i
|
|
49
|
+
};
|
|
50
|
+
})(), we = /[+\-*&%=<>!?|~^@]/, Ie = /^@(context|id|value|language|type|container|list|set|reverse|index|base|vocab|graph)"/;
|
|
51
|
+
function Se(e) {
|
|
52
|
+
for (var t = !1, n, i = !1; (n = e.next()) != null; ) {
|
|
53
|
+
if (!t) {
|
|
54
|
+
if (n == "/" && !i) return;
|
|
55
|
+
n == "[" ? i = !0 : i && n == "]" && (i = !1);
|
|
56
|
+
}
|
|
57
|
+
t = !t && n == "\\";
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
var D, M;
|
|
61
|
+
function y(e, t, n) {
|
|
62
|
+
return D = e, M = n, t;
|
|
63
|
+
}
|
|
64
|
+
function O(e, t) {
|
|
65
|
+
var n = e.next();
|
|
66
|
+
if (n == '"' || n == "'")
|
|
67
|
+
return t.tokenize = Ne(n), t.tokenize(e, t);
|
|
68
|
+
if (n == "." && e.match(/^\d[\d_]*(?:[eE][+\-]?[\d_]+)?/))
|
|
69
|
+
return y("number", "number");
|
|
70
|
+
if (n == "." && e.match(".."))
|
|
71
|
+
return y("spread", "meta");
|
|
72
|
+
if (/[\[\]{}\(\),;\:\.]/.test(n))
|
|
73
|
+
return y(n);
|
|
74
|
+
if (n == "=" && e.eat(">"))
|
|
75
|
+
return y("=>", "operator");
|
|
76
|
+
if (n == "0" && e.match(/^(?:x[\dA-Fa-f_]+|o[0-7_]+|b[01_]+)n?/))
|
|
77
|
+
return y("number", "number");
|
|
78
|
+
if (/\d/.test(n))
|
|
79
|
+
return e.match(/^[\d_]*(?:n|(?:\.[\d_]*)?(?:[eE][+\-]?[\d_]+)?)?/), y("number", "number");
|
|
80
|
+
if (n == "/")
|
|
81
|
+
return e.eat("*") ? (t.tokenize = Q, Q(e, t)) : e.eat("/") ? (e.skipToEnd(), y("comment", "comment")) : ct(e, t, 1) ? (Se(e), e.match(/^\b(([gimyus])(?![gimyus]*\2))+\b/), y("regexp", "string.special")) : (e.eat("="), y("operator", "operator", e.current()));
|
|
82
|
+
if (n == "`")
|
|
83
|
+
return t.tokenize = F, F(e, t);
|
|
84
|
+
if (n == "#" && e.peek() == "!")
|
|
85
|
+
return e.skipToEnd(), y("meta", "meta");
|
|
86
|
+
if (n == "#" && e.eatWhile(L))
|
|
87
|
+
return y("variable", "property");
|
|
88
|
+
if (n == "<" && e.match("!--") || n == "-" && e.match("->") && !/\S/.test(e.string.slice(0, e.start)))
|
|
89
|
+
return e.skipToEnd(), y("comment", "comment");
|
|
90
|
+
if (we.test(n))
|
|
91
|
+
return (n != ">" || !t.lexical || t.lexical.type != ">") && (e.eat("=") ? (n == "!" || n == "=") && e.eat("=") : /[<>*+\-|&?]/.test(n) && (e.eat(n), n == ">" && e.eat(n))), n == "?" && e.eat(".") ? y(".") : y("operator", "operator", e.current());
|
|
92
|
+
if (L.test(n)) {
|
|
93
|
+
e.eatWhile(L);
|
|
94
|
+
var i = e.current();
|
|
95
|
+
if (t.lastType != ".") {
|
|
96
|
+
if (ve.propertyIsEnumerable(i)) {
|
|
97
|
+
var u = ve[i];
|
|
98
|
+
return y(u.type, u.style, i);
|
|
99
|
+
}
|
|
100
|
+
if (i == "async" && e.match(/^(\s|\/\*([^*]|\*(?!\/))*?\*\/)*[\[\(\w]/, !1))
|
|
101
|
+
return y("async", "keyword", i);
|
|
102
|
+
}
|
|
103
|
+
return y("variable", "variable", i);
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
function Ne(e) {
|
|
107
|
+
return function(t, n) {
|
|
108
|
+
var i = !1, u;
|
|
109
|
+
if (ue && t.peek() == "@" && t.match(Ie))
|
|
110
|
+
return n.tokenize = O, y("jsonld-keyword", "meta");
|
|
111
|
+
for (; (u = t.next()) != null && !(u == e && !i); )
|
|
112
|
+
i = !i && u == "\\";
|
|
113
|
+
return i || (n.tokenize = O), y("string", "string");
|
|
114
|
+
};
|
|
115
|
+
}
|
|
116
|
+
function Q(e, t) {
|
|
117
|
+
for (var n = !1, i; i = e.next(); ) {
|
|
118
|
+
if (i == "/" && n) {
|
|
119
|
+
t.tokenize = O;
|
|
120
|
+
break;
|
|
121
|
+
}
|
|
122
|
+
n = i == "*";
|
|
123
|
+
}
|
|
124
|
+
return y("comment", "comment");
|
|
125
|
+
}
|
|
126
|
+
function F(e, t) {
|
|
127
|
+
for (var n = !1, i; (i = e.next()) != null; ) {
|
|
128
|
+
if (!n && (i == "`" || i == "$" && e.eat("{"))) {
|
|
129
|
+
t.tokenize = O;
|
|
130
|
+
break;
|
|
131
|
+
}
|
|
132
|
+
n = !n && i == "\\";
|
|
133
|
+
}
|
|
134
|
+
return y("quasi", "string.special", e.current());
|
|
135
|
+
}
|
|
136
|
+
var Pe = "([{}])";
|
|
137
|
+
function oe(e, t) {
|
|
138
|
+
t.fatArrowAt && (t.fatArrowAt = null);
|
|
139
|
+
var n = e.string.indexOf("=>", e.start);
|
|
140
|
+
if (!(n < 0)) {
|
|
141
|
+
if (p) {
|
|
142
|
+
var i = /:\s*(?:\w+(?:<[^>]*>|\[\])?|\{[^}]*\})\s*$/.exec(e.string.slice(e.start, n));
|
|
143
|
+
i && (n = i.index);
|
|
144
|
+
}
|
|
145
|
+
for (var u = 0, c = !1, m = n - 1; m >= 0; --m) {
|
|
146
|
+
var g = e.string.charAt(m), x = Pe.indexOf(g);
|
|
147
|
+
if (x >= 0 && x < 3) {
|
|
148
|
+
if (!u) {
|
|
149
|
+
++m;
|
|
150
|
+
break;
|
|
151
|
+
}
|
|
152
|
+
if (--u == 0) {
|
|
153
|
+
g == "(" && (c = !0);
|
|
154
|
+
break;
|
|
155
|
+
}
|
|
156
|
+
} else if (x >= 3 && x < 6)
|
|
157
|
+
++u;
|
|
158
|
+
else if (L.test(g))
|
|
159
|
+
c = !0;
|
|
160
|
+
else if (/["'\/`]/.test(g))
|
|
161
|
+
for (; ; --m) {
|
|
162
|
+
if (m == 0) return;
|
|
163
|
+
var K = e.string.charAt(m - 1);
|
|
164
|
+
if (K == g && e.string.charAt(m - 2) != "\\") {
|
|
165
|
+
m--;
|
|
166
|
+
break;
|
|
167
|
+
}
|
|
168
|
+
}
|
|
169
|
+
else if (c && !u) {
|
|
170
|
+
++m;
|
|
171
|
+
break;
|
|
172
|
+
}
|
|
173
|
+
}
|
|
174
|
+
c && !u && (t.fatArrowAt = m);
|
|
175
|
+
}
|
|
176
|
+
}
|
|
177
|
+
var Ce = {
|
|
178
|
+
atom: !0,
|
|
179
|
+
number: !0,
|
|
180
|
+
variable: !0,
|
|
181
|
+
string: !0,
|
|
182
|
+
regexp: !0,
|
|
183
|
+
this: !0,
|
|
184
|
+
import: !0,
|
|
185
|
+
"jsonld-keyword": !0
|
|
186
|
+
};
|
|
187
|
+
function be(e, t, n, i, u, c) {
|
|
188
|
+
this.indented = e, this.column = t, this.type = n, this.prev = u, this.info = c, i != null && (this.align = i);
|
|
189
|
+
}
|
|
190
|
+
function We(e, t) {
|
|
191
|
+
for (var n = e.localVars; n; n = n.next)
|
|
192
|
+
if (n.name == t) return !0;
|
|
193
|
+
for (var i = e.context; i; i = i.prev)
|
|
194
|
+
for (var n = i.vars; n; n = n.next)
|
|
195
|
+
if (n.name == t) return !0;
|
|
196
|
+
}
|
|
197
|
+
function Be(e, t, n, i, u) {
|
|
198
|
+
var c = e.cc;
|
|
199
|
+
for (a.state = e, a.stream = u, a.marked = null, a.cc = c, a.style = t, e.lexical.hasOwnProperty("align") || (e.lexical.align = !0); ; ) {
|
|
200
|
+
var m = c.length ? c.pop() : ye ? k : v;
|
|
201
|
+
if (m(n, i)) {
|
|
202
|
+
for (; c.length && c[c.length - 1].lex; )
|
|
203
|
+
c.pop()();
|
|
204
|
+
return a.marked ? a.marked : n == "variable" && We(e, i) ? "variableName.local" : t;
|
|
205
|
+
}
|
|
206
|
+
}
|
|
207
|
+
}
|
|
208
|
+
var a = { state: null, marked: null, cc: null };
|
|
209
|
+
function f() {
|
|
210
|
+
for (var e = arguments.length - 1; e >= 0; e--) a.cc.push(arguments[e]);
|
|
211
|
+
}
|
|
212
|
+
function r() {
|
|
213
|
+
return f.apply(null, arguments), !0;
|
|
214
|
+
}
|
|
215
|
+
function fe(e, t) {
|
|
216
|
+
for (var n = t; n; n = n.next) if (n.name == e) return !0;
|
|
217
|
+
return !1;
|
|
218
|
+
}
|
|
219
|
+
function S(e) {
|
|
220
|
+
var t = a.state;
|
|
221
|
+
if (a.marked = "def", t.context) {
|
|
222
|
+
if (t.lexical.info == "var" && t.context && t.context.block) {
|
|
223
|
+
var n = he(e, t.context);
|
|
224
|
+
if (n != null) {
|
|
225
|
+
t.context = n;
|
|
226
|
+
return;
|
|
227
|
+
}
|
|
228
|
+
} else if (!fe(e, t.localVars)) {
|
|
229
|
+
t.localVars = new G(e, t.localVars);
|
|
230
|
+
return;
|
|
231
|
+
}
|
|
232
|
+
}
|
|
233
|
+
b.globalVars && !fe(e, t.globalVars) && (t.globalVars = new G(e, t.globalVars));
|
|
234
|
+
}
|
|
235
|
+
function he(e, t) {
|
|
236
|
+
if (t)
|
|
237
|
+
if (t.block) {
|
|
238
|
+
var n = he(e, t.prev);
|
|
239
|
+
return n ? n == t.prev ? t : new U(n, t.vars, !0) : null;
|
|
240
|
+
} else return fe(e, t.vars) ? t : new U(t.prev, new G(e, t.vars), !1);
|
|
241
|
+
else return null;
|
|
242
|
+
}
|
|
243
|
+
function R(e) {
|
|
244
|
+
return e == "public" || e == "private" || e == "protected" || e == "abstract" || e == "readonly";
|
|
245
|
+
}
|
|
246
|
+
function U(e, t, n) {
|
|
247
|
+
this.prev = e, this.vars = t, this.block = n;
|
|
248
|
+
}
|
|
249
|
+
function G(e, t) {
|
|
250
|
+
this.name = e, this.next = t;
|
|
251
|
+
}
|
|
252
|
+
var De = new G("this", new G("arguments", null));
|
|
253
|
+
function _() {
|
|
254
|
+
a.state.context = new U(a.state.context, a.state.localVars, !1), a.state.localVars = De;
|
|
255
|
+
}
|
|
256
|
+
function X() {
|
|
257
|
+
a.state.context = new U(a.state.context, a.state.localVars, !0), a.state.localVars = null;
|
|
258
|
+
}
|
|
259
|
+
_.lex = X.lex = !0;
|
|
260
|
+
function V() {
|
|
261
|
+
a.state.localVars = a.state.context.vars, a.state.context = a.state.context.prev;
|
|
262
|
+
}
|
|
263
|
+
V.lex = !0;
|
|
264
|
+
function s(e, t) {
|
|
265
|
+
var n = function() {
|
|
266
|
+
var i = a.state, u = i.indented;
|
|
267
|
+
if (i.lexical.type == "stat") u = i.lexical.indented;
|
|
268
|
+
else for (var c = i.lexical; c && c.type == ")" && c.align; c = c.prev)
|
|
269
|
+
u = c.indented;
|
|
270
|
+
i.lexical = new be(u, a.stream.column(), e, null, i.lexical, t);
|
|
271
|
+
};
|
|
272
|
+
return n.lex = !0, n;
|
|
273
|
+
}
|
|
274
|
+
function o() {
|
|
275
|
+
var e = a.state;
|
|
276
|
+
e.lexical.prev && (e.lexical.type == ")" && (e.indented = e.lexical.indented), e.lexical = e.lexical.prev);
|
|
277
|
+
}
|
|
278
|
+
o.lex = !0;
|
|
279
|
+
function l(e) {
|
|
280
|
+
function t(n) {
|
|
281
|
+
return n == e ? r() : e == ";" || n == "}" || n == ")" || n == "]" ? f() : r(t);
|
|
282
|
+
}
|
|
283
|
+
return t;
|
|
284
|
+
}
|
|
285
|
+
function v(e, t) {
|
|
286
|
+
return e == "var" ? r(s("vardef", t), me, l(";"), o) : e == "keyword a" ? r(s("form"), se, v, o) : e == "keyword b" ? r(s("form"), v, o) : e == "keyword d" ? a.stream.match(/^\s*$/, !1) ? r() : r(s("stat"), N, l(";"), o) : e == "debugger" ? r(l(";")) : e == "{" ? r(s("}"), X, ee, o, V) : e == ";" ? r() : e == "if" ? (a.state.lexical.info == "else" && a.state.cc[a.state.cc.length - 1] == o && a.state.cc.pop()(), r(s("form"), se, v, o, Te)) : e == "function" ? r($) : e == "for" ? r(s("form"), X, je, v, V, o) : e == "class" || p && t == "interface" ? (a.marked = "keyword", r(s("form", e == "class" ? e : t), Oe, o)) : e == "variable" ? p && t == "declare" ? (a.marked = "keyword", r(v)) : p && (t == "module" || t == "enum" || t == "type") && a.stream.match(/^\s*\w/, !1) ? (a.marked = "keyword", t == "enum" ? r(Ee) : t == "type" ? r($e, l("operator"), d, l(";")) : r(s("form"), A, l("{"), s("}"), ee, o, o)) : p && t == "namespace" ? (a.marked = "keyword", r(s("form"), k, v, o)) : p && t == "abstract" ? (a.marked = "keyword", r(v)) : r(s("stat"), Ke) : e == "switch" ? r(
|
|
287
|
+
s("form"),
|
|
288
|
+
se,
|
|
289
|
+
l("{"),
|
|
290
|
+
s("}", "switch"),
|
|
291
|
+
X,
|
|
292
|
+
ee,
|
|
293
|
+
o,
|
|
294
|
+
o,
|
|
295
|
+
V
|
|
296
|
+
) : e == "case" ? r(k, l(":")) : e == "default" ? r(l(":")) : e == "catch" ? r(s("form"), _, Fe, v, o, V) : e == "export" ? r(s("stat"), it, o) : e == "import" ? r(s("stat"), ut, o) : e == "async" ? r(v) : t == "@" ? r(k, v) : f(s("stat"), k, l(";"), o);
|
|
297
|
+
}
|
|
298
|
+
function Fe(e) {
|
|
299
|
+
if (e == "(") return r(I, l(")"));
|
|
300
|
+
}
|
|
301
|
+
function k(e, t) {
|
|
302
|
+
return ge(e, t, !1);
|
|
303
|
+
}
|
|
304
|
+
function h(e, t) {
|
|
305
|
+
return ge(e, t, !0);
|
|
306
|
+
}
|
|
307
|
+
function se(e) {
|
|
308
|
+
return e != "(" ? f() : r(s(")"), N, l(")"), o);
|
|
309
|
+
}
|
|
310
|
+
function ge(e, t, n) {
|
|
311
|
+
if (a.state.fatArrowAt == a.stream.start) {
|
|
312
|
+
var i = n ? Ve : xe;
|
|
313
|
+
if (e == "(") return r(_, s(")"), w(I, ")"), o, l("=>"), i, V);
|
|
314
|
+
if (e == "variable") return f(_, A, l("=>"), i, V);
|
|
315
|
+
}
|
|
316
|
+
var u = n ? P : q;
|
|
317
|
+
return Ce.hasOwnProperty(e) ? r(u) : e == "function" ? r($, u) : e == "class" || p && t == "interface" ? (a.marked = "keyword", r(s("form"), at, o)) : e == "keyword c" || e == "async" ? r(n ? h : k) : e == "(" ? r(s(")"), N, l(")"), o, u) : e == "operator" || e == "spread" ? r(n ? h : k) : e == "[" ? r(s("]"), ft, o, u) : e == "{" ? H(Z, "}", null, u) : e == "quasi" ? f(Y, u) : e == "new" ? r(Ge(n)) : r();
|
|
318
|
+
}
|
|
319
|
+
function N(e) {
|
|
320
|
+
return e.match(/[;\}\)\],]/) ? f() : f(k);
|
|
321
|
+
}
|
|
322
|
+
function q(e, t) {
|
|
323
|
+
return e == "," ? r(N) : P(e, t, !1);
|
|
324
|
+
}
|
|
325
|
+
function P(e, t, n) {
|
|
326
|
+
var i = n == !1 ? q : P, u = n == !1 ? k : h;
|
|
327
|
+
if (e == "=>") return r(_, n ? Ve : xe, V);
|
|
328
|
+
if (e == "operator")
|
|
329
|
+
return /\+\+|--/.test(t) || p && t == "!" ? r(i) : p && t == "<" && a.stream.match(/^([^<>]|<[^<>]*>)*>\s*\(/, !1) ? r(s(">"), w(d, ">"), o, i) : t == "?" ? r(k, l(":"), u) : r(u);
|
|
330
|
+
if (e == "quasi")
|
|
331
|
+
return f(Y, i);
|
|
332
|
+
if (e != ";") {
|
|
333
|
+
if (e == "(") return H(h, ")", "call", i);
|
|
334
|
+
if (e == ".") return r(Le, i);
|
|
335
|
+
if (e == "[") return r(s("]"), N, l("]"), o, i);
|
|
336
|
+
if (p && t == "as")
|
|
337
|
+
return a.marked = "keyword", r(d, i);
|
|
338
|
+
if (e == "regexp")
|
|
339
|
+
return a.state.lastType = a.marked = "operator", a.stream.backUp(a.stream.pos - a.stream.start - 1), r(u);
|
|
340
|
+
}
|
|
341
|
+
}
|
|
342
|
+
function Y(e, t) {
|
|
343
|
+
return e != "quasi" ? f() : t.slice(t.length - 2) != "${" ? r(Y) : r(N, Ue);
|
|
344
|
+
}
|
|
345
|
+
function Ue(e) {
|
|
346
|
+
if (e == "}")
|
|
347
|
+
return a.marked = "string.special", a.state.tokenize = F, r(Y);
|
|
348
|
+
}
|
|
349
|
+
function xe(e) {
|
|
350
|
+
return oe(a.stream, a.state), f(e == "{" ? v : k);
|
|
351
|
+
}
|
|
352
|
+
function Ve(e) {
|
|
353
|
+
return oe(a.stream, a.state), f(e == "{" ? v : h);
|
|
354
|
+
}
|
|
355
|
+
function Ge(e) {
|
|
356
|
+
return function(t) {
|
|
357
|
+
return t == "." ? r(e ? Je : He) : t == "variable" && p ? r(Ze, e ? P : q) : f(e ? h : k);
|
|
358
|
+
};
|
|
359
|
+
}
|
|
360
|
+
function He(e, t) {
|
|
361
|
+
if (t == "target")
|
|
362
|
+
return a.marked = "keyword", r(q);
|
|
363
|
+
}
|
|
364
|
+
function Je(e, t) {
|
|
365
|
+
if (t == "target")
|
|
366
|
+
return a.marked = "keyword", r(P);
|
|
367
|
+
}
|
|
368
|
+
function Ke(e) {
|
|
369
|
+
return e == ":" ? r(o, v) : f(q, l(";"), o);
|
|
370
|
+
}
|
|
371
|
+
function Le(e) {
|
|
372
|
+
if (e == "variable")
|
|
373
|
+
return a.marked = "property", r();
|
|
374
|
+
}
|
|
375
|
+
function Z(e, t) {
|
|
376
|
+
if (e == "async")
|
|
377
|
+
return a.marked = "property", r(Z);
|
|
378
|
+
if (e == "variable" || a.style == "keyword") {
|
|
379
|
+
if (a.marked = "property", t == "get" || t == "set") return r(Me);
|
|
380
|
+
var n;
|
|
381
|
+
return p && a.state.fatArrowAt == a.stream.start && (n = a.stream.match(/^\s*:\s*/, !1)) && (a.state.fatArrowAt = a.stream.pos + n[0].length), r(E);
|
|
382
|
+
} else {
|
|
383
|
+
if (e == "number" || e == "string")
|
|
384
|
+
return a.marked = ue ? "property" : a.style + " property", r(E);
|
|
385
|
+
if (e == "jsonld-keyword")
|
|
386
|
+
return r(E);
|
|
387
|
+
if (p && R(t))
|
|
388
|
+
return a.marked = "keyword", r(Z);
|
|
389
|
+
if (e == "[")
|
|
390
|
+
return r(k, C, l("]"), E);
|
|
391
|
+
if (e == "spread")
|
|
392
|
+
return r(h, E);
|
|
393
|
+
if (t == "*")
|
|
394
|
+
return a.marked = "keyword", r(Z);
|
|
395
|
+
if (e == ":")
|
|
396
|
+
return f(E);
|
|
397
|
+
}
|
|
398
|
+
}
|
|
399
|
+
function Me(e) {
|
|
400
|
+
return e != "variable" ? f(E) : (a.marked = "property", r($));
|
|
401
|
+
}
|
|
402
|
+
function E(e) {
|
|
403
|
+
if (e == ":") return r(h);
|
|
404
|
+
if (e == "(") return f($);
|
|
405
|
+
}
|
|
406
|
+
function w(e, t, n) {
|
|
407
|
+
function i(u, c) {
|
|
408
|
+
if (n ? n.indexOf(u) > -1 : u == ",") {
|
|
409
|
+
var m = a.state.lexical;
|
|
410
|
+
return m.info == "call" && (m.pos = (m.pos || 0) + 1), r(function(g, x) {
|
|
411
|
+
return g == t || x == t ? f() : f(e);
|
|
412
|
+
}, i);
|
|
413
|
+
}
|
|
414
|
+
return u == t || c == t ? r() : n && n.indexOf(";") > -1 ? f(e) : r(l(t));
|
|
415
|
+
}
|
|
416
|
+
return function(u, c) {
|
|
417
|
+
return u == t || c == t ? r() : f(e, i);
|
|
418
|
+
};
|
|
419
|
+
}
|
|
420
|
+
function H(e, t, n) {
|
|
421
|
+
for (var i = 3; i < arguments.length; i++)
|
|
422
|
+
a.cc.push(arguments[i]);
|
|
423
|
+
return r(s(t, n), w(e, t), o);
|
|
424
|
+
}
|
|
425
|
+
function ee(e) {
|
|
426
|
+
return e == "}" ? r() : f(v, ee);
|
|
427
|
+
}
|
|
428
|
+
function C(e, t) {
|
|
429
|
+
if (p) {
|
|
430
|
+
if (e == ":") return r(d);
|
|
431
|
+
if (t == "?") return r(C);
|
|
432
|
+
}
|
|
433
|
+
}
|
|
434
|
+
function Qe(e, t) {
|
|
435
|
+
if (p && (e == ":" || t == "in")) return r(d);
|
|
436
|
+
}
|
|
437
|
+
function Ae(e) {
|
|
438
|
+
if (p && e == ":")
|
|
439
|
+
return a.stream.match(/^\s*\w+\s+is\b/, !1) ? r(k, Re, d) : r(d);
|
|
440
|
+
}
|
|
441
|
+
function Re(e, t) {
|
|
442
|
+
if (t == "is")
|
|
443
|
+
return a.marked = "keyword", r();
|
|
444
|
+
}
|
|
445
|
+
function d(e, t) {
|
|
446
|
+
if (t == "keyof" || t == "typeof" || t == "infer" || t == "readonly")
|
|
447
|
+
return a.marked = "keyword", r(t == "typeof" ? h : d);
|
|
448
|
+
if (e == "variable" || t == "void")
|
|
449
|
+
return a.marked = "type", r(z);
|
|
450
|
+
if (t == "|" || t == "&") return r(d);
|
|
451
|
+
if (e == "string" || e == "number" || e == "atom") return r(z);
|
|
452
|
+
if (e == "[") return r(s("]"), w(d, "]", ","), o, z);
|
|
453
|
+
if (e == "{") return r(s("}"), le, o, z);
|
|
454
|
+
if (e == "(") return r(w(de, ")"), Xe, z);
|
|
455
|
+
if (e == "<") return r(w(d, ">"), d);
|
|
456
|
+
if (e == "quasi") return f(ce, z);
|
|
457
|
+
}
|
|
458
|
+
function Xe(e) {
|
|
459
|
+
if (e == "=>") return r(d);
|
|
460
|
+
}
|
|
461
|
+
function le(e) {
|
|
462
|
+
return e.match(/[\}\)\]]/) ? r() : e == "," || e == ";" ? r(le) : f(J, le);
|
|
463
|
+
}
|
|
464
|
+
function J(e, t) {
|
|
465
|
+
if (e == "variable" || a.style == "keyword")
|
|
466
|
+
return a.marked = "property", r(J);
|
|
467
|
+
if (t == "?" || e == "number" || e == "string")
|
|
468
|
+
return r(J);
|
|
469
|
+
if (e == ":")
|
|
470
|
+
return r(d);
|
|
471
|
+
if (e == "[")
|
|
472
|
+
return r(l("variable"), Qe, l("]"), J);
|
|
473
|
+
if (e == "(")
|
|
474
|
+
return f(B, J);
|
|
475
|
+
if (!e.match(/[;\}\)\],]/))
|
|
476
|
+
return r();
|
|
477
|
+
}
|
|
478
|
+
function ce(e, t) {
|
|
479
|
+
return e != "quasi" ? f() : t.slice(t.length - 2) != "${" ? r(ce) : r(d, Ye);
|
|
480
|
+
}
|
|
481
|
+
function Ye(e) {
|
|
482
|
+
if (e == "}")
|
|
483
|
+
return a.marked = "string.special", a.state.tokenize = F, r(ce);
|
|
484
|
+
}
|
|
485
|
+
function de(e, t) {
|
|
486
|
+
return e == "variable" && a.stream.match(/^\s*[?:]/, !1) || t == "?" ? r(de) : e == ":" ? r(d) : e == "spread" ? r(de) : f(d);
|
|
487
|
+
}
|
|
488
|
+
function z(e, t) {
|
|
489
|
+
if (t == "<") return r(s(">"), w(d, ">"), o, z);
|
|
490
|
+
if (t == "|" || e == "." || t == "&") return r(d);
|
|
491
|
+
if (e == "[") return r(d, l("]"), z);
|
|
492
|
+
if (t == "extends" || t == "implements")
|
|
493
|
+
return a.marked = "keyword", r(d);
|
|
494
|
+
if (t == "?") return r(d, l(":"), d);
|
|
495
|
+
}
|
|
496
|
+
function Ze(e, t) {
|
|
497
|
+
if (t == "<") return r(s(">"), w(d, ">"), o, z);
|
|
498
|
+
}
|
|
499
|
+
function te() {
|
|
500
|
+
return f(d, et);
|
|
501
|
+
}
|
|
502
|
+
function et(e, t) {
|
|
503
|
+
if (t == "=") return r(d);
|
|
504
|
+
}
|
|
505
|
+
function me(e, t) {
|
|
506
|
+
return t == "enum" ? (a.marked = "keyword", r(Ee)) : f(A, C, j, rt);
|
|
507
|
+
}
|
|
508
|
+
function A(e, t) {
|
|
509
|
+
if (p && R(t))
|
|
510
|
+
return a.marked = "keyword", r(A);
|
|
511
|
+
if (e == "variable")
|
|
512
|
+
return S(t), r();
|
|
513
|
+
if (e == "spread") return r(A);
|
|
514
|
+
if (e == "[") return H(tt, "]");
|
|
515
|
+
if (e == "{") return H(ze, "}");
|
|
516
|
+
}
|
|
517
|
+
function ze(e, t) {
|
|
518
|
+
return e == "variable" && !a.stream.match(/^\s*:/, !1) ? (S(t), r(j)) : (e == "variable" && (a.marked = "property"), e == "spread" ? r(A) : e == "}" ? f() : e == "[" ? r(k, l("]"), l(":"), ze) : r(l(":"), A, j));
|
|
519
|
+
}
|
|
520
|
+
function tt() {
|
|
521
|
+
return f(A, j);
|
|
522
|
+
}
|
|
523
|
+
function j(e, t) {
|
|
524
|
+
if (t == "=") return r(h);
|
|
525
|
+
}
|
|
526
|
+
function rt(e) {
|
|
527
|
+
if (e == ",") return r(me);
|
|
528
|
+
}
|
|
529
|
+
function Te(e, t) {
|
|
530
|
+
if (e == "keyword b" && t == "else") return r(s("form", "else"), v, o);
|
|
531
|
+
}
|
|
532
|
+
function je(e, t) {
|
|
533
|
+
if (t == "await") return r(je);
|
|
534
|
+
if (e == "(") return r(s(")"), nt, o);
|
|
535
|
+
}
|
|
536
|
+
function nt(e) {
|
|
537
|
+
return e == "var" ? r(me, W) : e == "variable" ? r(W) : f(W);
|
|
538
|
+
}
|
|
539
|
+
function W(e, t) {
|
|
540
|
+
return e == ")" ? r() : e == ";" ? r(W) : t == "in" || t == "of" ? (a.marked = "keyword", r(k, W)) : f(k, W);
|
|
541
|
+
}
|
|
542
|
+
function $(e, t) {
|
|
543
|
+
if (t == "*")
|
|
544
|
+
return a.marked = "keyword", r($);
|
|
545
|
+
if (e == "variable")
|
|
546
|
+
return S(t), r($);
|
|
547
|
+
if (e == "(") return r(_, s(")"), w(I, ")"), o, Ae, v, V);
|
|
548
|
+
if (p && t == "<") return r(s(">"), w(te, ">"), o, $);
|
|
549
|
+
}
|
|
550
|
+
function B(e, t) {
|
|
551
|
+
if (t == "*")
|
|
552
|
+
return a.marked = "keyword", r(B);
|
|
553
|
+
if (e == "variable")
|
|
554
|
+
return S(t), r(B);
|
|
555
|
+
if (e == "(") return r(_, s(")"), w(I, ")"), o, Ae, V);
|
|
556
|
+
if (p && t == "<") return r(s(">"), w(te, ">"), o, B);
|
|
557
|
+
}
|
|
558
|
+
function $e(e, t) {
|
|
559
|
+
if (e == "keyword" || e == "variable")
|
|
560
|
+
return a.marked = "type", r($e);
|
|
561
|
+
if (t == "<")
|
|
562
|
+
return r(s(">"), w(te, ">"), o);
|
|
563
|
+
}
|
|
564
|
+
function I(e, t) {
|
|
565
|
+
return t == "@" && r(k, I), e == "spread" ? r(I) : p && R(t) ? (a.marked = "keyword", r(I)) : p && e == "this" ? r(C, j) : f(A, C, j);
|
|
566
|
+
}
|
|
567
|
+
function at(e, t) {
|
|
568
|
+
return e == "variable" ? Oe(e, t) : re(e, t);
|
|
569
|
+
}
|
|
570
|
+
function Oe(e, t) {
|
|
571
|
+
if (e == "variable")
|
|
572
|
+
return S(t), r(re);
|
|
573
|
+
}
|
|
574
|
+
function re(e, t) {
|
|
575
|
+
if (t == "<") return r(s(">"), w(te, ">"), o, re);
|
|
576
|
+
if (t == "extends" || t == "implements" || p && e == ",")
|
|
577
|
+
return t == "implements" && (a.marked = "keyword"), r(p ? d : k, re);
|
|
578
|
+
if (e == "{") return r(s("}"), T, o);
|
|
579
|
+
}
|
|
580
|
+
function T(e, t) {
|
|
581
|
+
if (e == "async" || e == "variable" && (t == "static" || t == "get" || t == "set" || p && R(t)) && a.stream.match(/^\s+#?[\w$\xa1-\uffff]/, !1))
|
|
582
|
+
return a.marked = "keyword", r(T);
|
|
583
|
+
if (e == "variable" || a.style == "keyword")
|
|
584
|
+
return a.marked = "property", r(ne, T);
|
|
585
|
+
if (e == "number" || e == "string") return r(ne, T);
|
|
586
|
+
if (e == "[")
|
|
587
|
+
return r(k, C, l("]"), ne, T);
|
|
588
|
+
if (t == "*")
|
|
589
|
+
return a.marked = "keyword", r(T);
|
|
590
|
+
if (p && e == "(") return f(B, T);
|
|
591
|
+
if (e == ";" || e == ",") return r(T);
|
|
592
|
+
if (e == "}") return r();
|
|
593
|
+
if (t == "@") return r(k, T);
|
|
594
|
+
}
|
|
595
|
+
function ne(e, t) {
|
|
596
|
+
if (t == "!" || t == "?") return r(ne);
|
|
597
|
+
if (e == ":") return r(d, j);
|
|
598
|
+
if (t == "=") return r(h);
|
|
599
|
+
var n = a.state.lexical.prev, i = n && n.info == "interface";
|
|
600
|
+
return f(i ? B : $);
|
|
601
|
+
}
|
|
602
|
+
function it(e, t) {
|
|
603
|
+
return t == "*" ? (a.marked = "keyword", r(pe, l(";"))) : t == "default" ? (a.marked = "keyword", r(k, l(";"))) : e == "{" ? r(w(_e, "}"), pe, l(";")) : f(v);
|
|
604
|
+
}
|
|
605
|
+
function _e(e, t) {
|
|
606
|
+
if (t == "as")
|
|
607
|
+
return a.marked = "keyword", r(l("variable"));
|
|
608
|
+
if (e == "variable") return f(h, _e);
|
|
609
|
+
}
|
|
610
|
+
function ut(e) {
|
|
611
|
+
return e == "string" ? r() : e == "(" ? f(k) : e == "." ? f(q) : f(ae, qe, pe);
|
|
612
|
+
}
|
|
613
|
+
function ae(e, t) {
|
|
614
|
+
return e == "{" ? H(ae, "}") : (e == "variable" && S(t), t == "*" && (a.marked = "keyword"), r(ot));
|
|
615
|
+
}
|
|
616
|
+
function qe(e) {
|
|
617
|
+
if (e == ",") return r(ae, qe);
|
|
618
|
+
}
|
|
619
|
+
function ot(e, t) {
|
|
620
|
+
if (t == "as")
|
|
621
|
+
return a.marked = "keyword", r(ae);
|
|
622
|
+
}
|
|
623
|
+
function pe(e, t) {
|
|
624
|
+
if (t == "from")
|
|
625
|
+
return a.marked = "keyword", r(k);
|
|
626
|
+
}
|
|
627
|
+
function ft(e) {
|
|
628
|
+
return e == "]" ? r() : f(w(h, "]"));
|
|
629
|
+
}
|
|
630
|
+
function Ee() {
|
|
631
|
+
return f(s("form"), A, l("{"), s("}"), w(st, "}"), o, o);
|
|
632
|
+
}
|
|
633
|
+
function st() {
|
|
634
|
+
return f(A, j);
|
|
635
|
+
}
|
|
636
|
+
function lt(e, t) {
|
|
637
|
+
return e.lastType == "operator" || e.lastType == "," || we.test(t.charAt(0)) || /[,.]/.test(t.charAt(0));
|
|
638
|
+
}
|
|
639
|
+
function ct(e, t, n) {
|
|
640
|
+
return t.tokenize == O && /^(?:operator|sof|keyword [bcd]|case|new|export|default|spread|[\[{}\(,;:]|=>)$/.test(t.lastType) || t.lastType == "quasi" && /\{\s*$/.test(e.string.slice(0, e.pos - n));
|
|
641
|
+
}
|
|
642
|
+
return {
|
|
643
|
+
name: b.name,
|
|
644
|
+
startState: function(e) {
|
|
645
|
+
var t = {
|
|
646
|
+
tokenize: O,
|
|
647
|
+
lastType: "sof",
|
|
648
|
+
cc: [],
|
|
649
|
+
lexical: new be(-e, 0, "block", !1),
|
|
650
|
+
localVars: b.localVars,
|
|
651
|
+
context: b.localVars && new U(null, null, !1),
|
|
652
|
+
indented: 0
|
|
653
|
+
};
|
|
654
|
+
return b.globalVars && typeof b.globalVars == "object" && (t.globalVars = b.globalVars), t;
|
|
655
|
+
},
|
|
656
|
+
token: function(e, t) {
|
|
657
|
+
if (e.sol() && (t.lexical.hasOwnProperty("align") || (t.lexical.align = !1), t.indented = e.indentation(), oe(e, t)), t.tokenize != Q && e.eatSpace()) return null;
|
|
658
|
+
var n = t.tokenize(e, t);
|
|
659
|
+
return D == "comment" ? n : (t.lastType = D == "operator" && (M == "++" || M == "--") ? "incdec" : D, Be(t, n, D, M, e));
|
|
660
|
+
},
|
|
661
|
+
indent: function(e, t, n) {
|
|
662
|
+
if (e.tokenize == Q || e.tokenize == F) return null;
|
|
663
|
+
if (e.tokenize != O) return 0;
|
|
664
|
+
var i = t && t.charAt(0), u = e.lexical, c;
|
|
665
|
+
if (!/^\s*else\b/.test(t)) for (var m = e.cc.length - 1; m >= 0; --m) {
|
|
666
|
+
var g = e.cc[m];
|
|
667
|
+
if (g == o) u = u.prev;
|
|
668
|
+
else if (g != Te && g != V) break;
|
|
669
|
+
}
|
|
670
|
+
for (; (u.type == "stat" || u.type == "form") && (i == "}" || (c = e.cc[e.cc.length - 1]) && (c == q || c == P) && !/^[,\.=+\-*:?[\(]/.test(t)); )
|
|
671
|
+
u = u.prev;
|
|
672
|
+
ke && u.type == ")" && u.prev.type == "stat" && (u = u.prev);
|
|
673
|
+
var x = u.type, K = i == x;
|
|
674
|
+
return x == "vardef" ? u.indented + (e.lastType == "operator" || e.lastType == "," ? u.info.length + 1 : 0) : x == "form" && i == "{" ? u.indented : x == "form" ? u.indented + n.unit : x == "stat" ? u.indented + (lt(e, t) ? ke || n.unit : 0) : u.info == "switch" && !K && b.doubleIndentSwitch != !1 ? u.indented + (/^(?:case|default)\b/.test(t) ? n.unit : 2 * n.unit) : u.align ? u.column + (K ? 0 : 1) : u.indented + (K ? 0 : n.unit);
|
|
675
|
+
},
|
|
676
|
+
languageData: {
|
|
677
|
+
indentOnInput: /^\s*(?:case .*?:|default:|\{|\})$/,
|
|
678
|
+
commentTokens: ye ? void 0 : { line: "//", block: { open: "/*", close: "*/" } },
|
|
679
|
+
closeBrackets: { brackets: ["(", "[", "{", "'", '"', "`"] },
|
|
680
|
+
wordChars: "$"
|
|
681
|
+
}
|
|
682
|
+
};
|
|
683
|
+
}
|
|
684
|
+
const dt = ie({ name: "javascript" });
|
|
685
|
+
ie({ name: "json", json: !0 });
|
|
686
|
+
const mt = ie({ name: "json", jsonld: !0 });
|
|
687
|
+
ie({ name: "typescript", typescript: !0 });
|
|
688
|
+
export {
|
|
689
|
+
dt as javascript,
|
|
690
|
+
mt as jsonld
|
|
691
|
+
};
|