@aiao/code-editor-react 0.0.8 → 0.0.10
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/index.js +118 -2
- package/package.json +7 -4
- package/dist/apl-B2DGVGxc-Dd6D39pP.js +0 -76
- package/dist/asciiarmor-2LVJmxlE-CAn4gnoC.js +0 -34
- package/dist/asn1-jKiBa2Ya-xsKwdyq9.js +0 -95
- package/dist/asterisk-DS281yxp-B5eTWk_B.js +0 -271
- package/dist/brainfuck-C_p9pTT8-DKVQ9poL.js +0 -34
- package/dist/clike-BMALKCNj-Ck7Gc35_.js +0 -620
- package/dist/clojure-CCKyeQKf-N9sg777Z.js +0 -800
- package/dist/cmake-CuaCgAKt-BbEgXraO.js +0 -28
- package/dist/cobol-BlTKFDRj-CHCoWafp.js +0 -72
- package/dist/coffeescript-BVCvwO8I-Z15ai5ac.js +0 -179
- package/dist/commonlisp-D_kxz07b-Ce7sn14o.js +0 -75
- package/dist/crystal-D309uH6_-DS6LrXoE.js +0 -217
- package/dist/css-BkF-NPzE-DiJu9Nkd.js +0 -1553
- package/dist/cypher-BMq4Fwjl-Ml-omWgp.js +0 -68
- package/dist/d-BZcgY6La-KCW6-bIm.js +0 -127
- package/dist/diff-Cg9d_RX2-C01qBVFc.js +0 -18
- package/dist/dockerfile-DFX8bq9N-BIbYUQV0.js +0 -194
- package/dist/dtd-CtLokQ-U-DCbNdeIA.js +0 -84
- package/dist/dylan-QYeExnWK-DIUVpsct.js +0 -234
- package/dist/ebnf-DUPDuY4r-7HIXKmWn.js +0 -78
- package/dist/ecl-CiXN-g_D-DOI-W0if.js +0 -121
- package/dist/eiffel-yQhjl4T1-DIX8Ceq1.js +0 -110
- package/dist/elm-CNT9vbN0-BcYlydpO.js +0 -108
- package/dist/erlang-CFOYdy9e-DULXsFZl.js +0 -487
- package/dist/factor-Clf6BoVk-DBb2EHMF.js +0 -65
- package/dist/fcl-CPC2WYrI-CuXG3fcK.js +0 -103
- package/dist/forth-BmxRyE9S-BcFwWpeL.js +0 -60
- package/dist/fortran-9bvPyrOW-CuLcq-Iu.js +0 -442
- package/dist/gas-cpmYfFX2-sZgGhMxB.js +0 -183
- package/dist/gherkin-CJuwpceU-BRrr8yjO.js +0 -34
- package/dist/groovy-DZeT_VM--CmF8wcSo.js +0 -146
- package/dist/haskell-CxiO_7JL-BuULsXvv.js +0 -375
- package/dist/haxe-70NVW1pR-CM27SfgM.js +0 -359
- package/dist/http-D9LttvKF-j9E8oQ7o.js +0 -44
- package/dist/idl-B6TRFYjl-B6TRFYjl.js +0 -947
- package/dist/index-BMiCCEB1-CFMNJD60.js +0 -305
- package/dist/index-BNuasEBW-DZ41gDvf.js +0 -94
- package/dist/index-Bg1KDWyt-C0dA4q7z.js +0 -290
- package/dist/index-BuVm7ZG6-CVgdIGdI.js +0 -1305
- package/dist/index-BvS1cnHq-CvzF_kJP.js +0 -613
- package/dist/index-C44L0DmY-y7wRzM46.js +0 -138
- package/dist/index-C71CZfUx-BtWSxfva.js +0 -247
- package/dist/index-CGKWrtgc.js +0 -29766
- package/dist/index-CQ6JWNwi-DowNkPcb.js +0 -566
- package/dist/index-CpRVx97--DylNh-Zi.js +0 -342
- package/dist/index-CqvQj6d--nBAN1vpF.js +0 -270
- package/dist/index-CrbQBmWq-DmiRVF9u.js +0 -157
- package/dist/index-CzovO10m-DDglzqnG.js +0 -301
- package/dist/index-D0BZOY-S-rNSlBO9l.js +0 -101
- package/dist/index-D0svJS59-f8ZA2hgC.js +0 -555
- package/dist/index-D93XVMi1-CZ_Q2QZM.js +0 -136
- package/dist/index-DEB5VK0f-iiwOciBu.js +0 -252
- package/dist/index-Dp8osI_J-DDFW8XvK.js +0 -960
- package/dist/index-Ds4AioqO-Cg_BlAEI.js +0 -1917
- package/dist/index-Dy-OpkyQ-DcLuBsQT.js +0 -76
- package/dist/index-Dyi9rNIT-B7p7Dpus.js +0 -391
- package/dist/index-ZJkjD9tT-DJQk0ayW.js +0 -74
- package/dist/index-qH2lMs0G-Co53S8h3.js +0 -944
- package/dist/index-srIksFxX-BLrX1cGK.js +0 -59
- package/dist/javascript-DOuB9oqA-BxiygWgm.js +0 -691
- package/dist/julia-DpvXAuO6-Bk_IfD8X.js +0 -241
- package/dist/livescript-CanGTf8u-Cx6PrvS4.js +0 -272
- package/dist/lua-XplVlWi_-8f8obHzY.js +0 -217
- package/dist/mathematica-jaRHnSxC-B83gQsL2.js +0 -35
- package/dist/mbox-BctzC1hL-Hg5U2B4l.js +0 -76
- package/dist/mirc-CFBPAOaF-CfzSSk9W.js +0 -72
- package/dist/mllike-BSnXJBGA-Ao1NpT2u.js +0 -272
- package/dist/modelica-vUgVs--1-BObVpYBg.js +0 -93
- package/dist/mscgen-Cpl0NYLN-DqNArLGH.js +0 -104
- package/dist/mumps-CQoS1kWX-CkTUOQnt.js +0 -25
- package/dist/nginx-zDPm3Z74-DJk4KP7N.js +0 -87
- package/dist/nsis-BCLyjY7m-C2MffOQ3.js +0 -62
- package/dist/ntriples-CsNjv2QF-C4aZn3EO.js +0 -79
- package/dist/octave-C8PmmSRH-DM5vTWlU.js +0 -143
- package/dist/oz-Ce8aN8oE-BcJM4SVy.js +0 -151
- package/dist/pascal-De0D6mP7-D7DGFFKL.js +0 -77
- package/dist/perl-B4bSCe1C-6aIa2glS.js +0 -915
- package/dist/pig-D24Z8EXi-BD-qt5FU.js +0 -54
- package/dist/powershell-DkYVfTzP-Blt1Rodi.js +0 -249
- package/dist/properties-Dn9wna3M-EOOwnCnk.js +0 -26
- package/dist/protobuf-BPIjwpzm-DAButU8_.js +0 -49
- package/dist/pug-TGXr6c5j-C9HfQ86E.js +0 -248
- package/dist/puppet-nyd4dhjf-CGzH5dsa.js +0 -45
- package/dist/python-BkR3uSy8-CjDnyp3B.js +0 -313
- package/dist/q-DyHZGnqm-DGuqeH_T.js +0 -86
- package/dist/r-LKEuhEGI-BFQhJnTP.js +0 -104
- package/dist/rpm-IznJm2Xc-CbZqrWCM.js +0 -57
- package/dist/ruby-CcYfvIk6-DzPSfSGo.js +0 -228
- package/dist/sas-7E8yHoCW-D726Uzkw.js +0 -105
- package/dist/scheme-DjibxsNh-Bp5gVFkm.js +0 -124
- package/dist/shell-C0C2sNA_-BTeYg6ir.js +0 -182
- package/dist/sieve-Bwz7vjP5-Cw8iTBf7.js +0 -72
- package/dist/simple-mode-mNVtnu0l-BC8mf7KF.js +0 -89
- package/dist/smalltalk-Bhddl2pB-B7URiJSp.js +0 -48
- package/dist/solr-BNlsLglM-BM2OpfTI.js +0 -41
- package/dist/sparql-FarWu_Gb-FN_uQNd4.js +0 -197
- package/dist/spreadsheet-C-cy4P5N-5CSTwVYq.js +0 -49
- package/dist/sql-CfG5lQ3l-Bd4dgm_8.js +0 -278
- package/dist/stex-Du4h4KAU-QOov_zHj.js +0 -129
- package/dist/stylus-CAdqWld3-BcRBbBxD.js +0 -250
- package/dist/swift-DSxqR9R6-2Hz4NOoF.js +0 -230
- package/dist/tcl-xfoLljhY-DAZBRGQI.js +0 -81
- package/dist/textile-D1AWE-pc-DuiIfEnb.js +0 -295
- package/dist/tiddlywiki-5wqsXtSk-WuF_8VUv.js +0 -155
- package/dist/tiki-__Kn3CeS-CWcR9ib_.js +0 -181
- package/dist/toml-DWAmxCjl-CyJoDzs6.js +0 -56
- package/dist/troff-D2UO-fKf-DVoIzS-O.js +0 -35
- package/dist/ttcn-Bsa4sfRm-hoy08sYQ.js +0 -123
- package/dist/ttcn-cfg-Bac_acMi-DaC4kQpd.js +0 -88
- package/dist/turtle-xwJUxoPV-fs94wdNM.js +0 -80
- package/dist/vb-c2kQGd6--DU726qF0.js +0 -74
- package/dist/vbscript-1f_Dhg5H-DriA32xD.js +0 -324
- package/dist/velocity-DJd0pTTC-BG368IR6.js +0 -96
- package/dist/verilog-CiS1jyi5-giQA8J-e.js +0 -259
- package/dist/vhdl-T9HkrbI2-BJ8LEDog.js +0 -106
- package/dist/webidl-CjfDENEo-BM8KXKJ5.js +0 -155
- package/dist/xquery-Ct6lEb4B-C5KDc61l.js +0 -422
- package/dist/yacas-C0absKBh-B82QJ76F.js +0 -73
- package/dist/z80-Pki2zAjW-B0IQoIbR.js +0 -61
|
@@ -1,359 +0,0 @@
|
|
|
1
|
-
function l(t) {
|
|
2
|
-
return { type: t, style: "keyword" };
|
|
3
|
-
}
|
|
4
|
-
var _ = l("keyword a"), z = l("keyword b"), k = l("keyword c"), M = l("operator"), T = { type: "atom", style: "atom" }, w = { type: "attribute", style: "attribute" }, f = l("typedef"), I = {
|
|
5
|
-
if: _,
|
|
6
|
-
while: _,
|
|
7
|
-
else: z,
|
|
8
|
-
do: z,
|
|
9
|
-
try: z,
|
|
10
|
-
return: k,
|
|
11
|
-
break: k,
|
|
12
|
-
continue: k,
|
|
13
|
-
new: k,
|
|
14
|
-
throw: k,
|
|
15
|
-
var: l("var"),
|
|
16
|
-
inline: w,
|
|
17
|
-
static: w,
|
|
18
|
-
using: l("import"),
|
|
19
|
-
public: w,
|
|
20
|
-
private: w,
|
|
21
|
-
cast: l("cast"),
|
|
22
|
-
import: l("import"),
|
|
23
|
-
macro: l("macro"),
|
|
24
|
-
function: l("function"),
|
|
25
|
-
catch: l("catch"),
|
|
26
|
-
untyped: l("untyped"),
|
|
27
|
-
callback: l("cb"),
|
|
28
|
-
for: l("for"),
|
|
29
|
-
switch: l("switch"),
|
|
30
|
-
case: l("case"),
|
|
31
|
-
default: l("default"),
|
|
32
|
-
in: M,
|
|
33
|
-
never: l("property_access"),
|
|
34
|
-
trace: l("trace"),
|
|
35
|
-
class: f,
|
|
36
|
-
abstract: f,
|
|
37
|
-
enum: f,
|
|
38
|
-
interface: f,
|
|
39
|
-
typedef: f,
|
|
40
|
-
extends: f,
|
|
41
|
-
implements: f,
|
|
42
|
-
dynamic: f,
|
|
43
|
-
true: T,
|
|
44
|
-
false: T,
|
|
45
|
-
null: T
|
|
46
|
-
}, E = /[+\-*&%=<>!?|]/;
|
|
47
|
-
function N(t, e, r) {
|
|
48
|
-
return e.tokenize = r, r(t, e);
|
|
49
|
-
}
|
|
50
|
-
function B(t, e) {
|
|
51
|
-
for (var r = !1, a; (a = t.next()) != null; ) {
|
|
52
|
-
if (a == e && !r)
|
|
53
|
-
return !0;
|
|
54
|
-
r = !r && a == "\\";
|
|
55
|
-
}
|
|
56
|
-
}
|
|
57
|
-
var f, F;
|
|
58
|
-
function d(t, e, r) {
|
|
59
|
-
return f = t, F = r, e;
|
|
60
|
-
}
|
|
61
|
-
function A(t, e) {
|
|
62
|
-
var r = t.next();
|
|
63
|
-
if (r == '"' || r == "'")
|
|
64
|
-
return N(t, e, Q(r));
|
|
65
|
-
if (/[\[\]{}\(\),;\:\.]/.test(r))
|
|
66
|
-
return d(r);
|
|
67
|
-
if (r == "0" && t.eat(/x/i))
|
|
68
|
-
return t.eatWhile(/[\da-f]/i), d("number", "number");
|
|
69
|
-
if (/\d/.test(r) || r == "-" && t.eat(/\d/))
|
|
70
|
-
return t.match(/^\d*(?:\.\d*(?!\.))?(?:[eE][+\-]?\d+)?/), d("number", "number");
|
|
71
|
-
if (e.reAllowed && r == "~" && t.eat(/\//))
|
|
72
|
-
return B(t, "/"), t.eatWhile(/[gimsu]/), d("regexp", "string.special");
|
|
73
|
-
if (r == "/")
|
|
74
|
-
return t.eat("*") ? N(t, e, R) : t.eat("/") ? (t.skipToEnd(), d("comment", "comment")) : (t.eatWhile(E), d("operator", null, t.current()));
|
|
75
|
-
if (r == "#")
|
|
76
|
-
return t.skipToEnd(), d("conditional", "meta");
|
|
77
|
-
if (r == "@")
|
|
78
|
-
return t.eat(/:/), t.eatWhile(/[\w_]/), d("metadata", "meta");
|
|
79
|
-
if (E.test(r))
|
|
80
|
-
return t.eatWhile(E), d("operator", null, t.current());
|
|
81
|
-
var a;
|
|
82
|
-
if (/[A-Z]/.test(r))
|
|
83
|
-
return t.eatWhile(/[\w_<>]/), a = t.current(), d("type", "type", a);
|
|
84
|
-
t.eatWhile(/[\w_]/);
|
|
85
|
-
var a = t.current(), i = I.propertyIsEnumerable(a) && I[a];
|
|
86
|
-
return i && e.kwAllowed ? d(i.type, i.style, a) : d("variable", "variable", a);
|
|
87
|
-
}
|
|
88
|
-
function Q(t) {
|
|
89
|
-
return function(e, r) {
|
|
90
|
-
return B(e, t) && (r.tokenize = A), d("string", "string");
|
|
91
|
-
};
|
|
92
|
-
}
|
|
93
|
-
function R(t, e) {
|
|
94
|
-
for (var r = !1, a; a = t.next(); ) {
|
|
95
|
-
if (a == "/" && r) {
|
|
96
|
-
e.tokenize = A;
|
|
97
|
-
break;
|
|
98
|
-
}
|
|
99
|
-
r = a == "*";
|
|
100
|
-
}
|
|
101
|
-
return d("comment", "comment");
|
|
102
|
-
}
|
|
103
|
-
var j = { atom: !0, number: !0, variable: !0, string: !0, regexp: !0 };
|
|
104
|
-
function q(t, e, r, a, i, s) {
|
|
105
|
-
this.indented = t, this.column = e, this.type = r, this.prev = i, this.info = s, a != null && (this.align = a);
|
|
106
|
-
}
|
|
107
|
-
function U(t, e) {
|
|
108
|
-
for (var r = t.localVars; r; r = r.next)
|
|
109
|
-
if (r.name == e) return !0;
|
|
110
|
-
}
|
|
111
|
-
function X(t, e, r, a, i) {
|
|
112
|
-
var s = t.cc;
|
|
113
|
-
for (u.state = t, u.stream = i, u.marked = null, u.cc = s, t.lexical.hasOwnProperty("align") || (t.lexical.align = !0); ; ) {
|
|
114
|
-
var x = s.length ? s.pop() : v;
|
|
115
|
-
if (x(r, a)) {
|
|
116
|
-
for (; s.length && s[s.length - 1].lex; )
|
|
117
|
-
s.pop()();
|
|
118
|
-
return u.marked ? u.marked : r == "variable" && U(t, a) ? "variableName.local" : r == "variable" && Y(t, a) ? "variableName.special" : e;
|
|
119
|
-
}
|
|
120
|
-
}
|
|
121
|
-
}
|
|
122
|
-
function Y(t, e) {
|
|
123
|
-
if (/[a-z]/.test(e.charAt(0)))
|
|
124
|
-
return !1;
|
|
125
|
-
for (var r = t.importedtypes.length, a = 0; a < r; a++)
|
|
126
|
-
if (t.importedtypes[a] == e) return !0;
|
|
127
|
-
}
|
|
128
|
-
function C(t) {
|
|
129
|
-
for (var e = u.state, r = e.importedtypes; r; r = r.next)
|
|
130
|
-
if (r.name == t) return;
|
|
131
|
-
e.importedtypes = { name: t, next: e.importedtypes };
|
|
132
|
-
}
|
|
133
|
-
var u = { state: null, marked: null, cc: null };
|
|
134
|
-
function b() {
|
|
135
|
-
for (var t = arguments.length - 1; t >= 0; t--) u.cc.push(arguments[t]);
|
|
136
|
-
}
|
|
137
|
-
function n() {
|
|
138
|
-
return b.apply(null, arguments), !0;
|
|
139
|
-
}
|
|
140
|
-
function $(t, e) {
|
|
141
|
-
for (var r = e; r; r = r.next)
|
|
142
|
-
if (r.name == t) return !0;
|
|
143
|
-
return !1;
|
|
144
|
-
}
|
|
145
|
-
function S(t) {
|
|
146
|
-
var e = u.state;
|
|
147
|
-
if (e.context) {
|
|
148
|
-
if (u.marked = "def", $(t, e.localVars)) return;
|
|
149
|
-
e.localVars = { name: t, next: e.localVars };
|
|
150
|
-
} else if (e.globalVars) {
|
|
151
|
-
if ($(t, e.globalVars)) return;
|
|
152
|
-
e.globalVars = { name: t, next: e.globalVars };
|
|
153
|
-
}
|
|
154
|
-
}
|
|
155
|
-
var tt = { name: "this", next: null };
|
|
156
|
-
function O() {
|
|
157
|
-
u.state.context || (u.state.localVars = tt), u.state.context = { prev: u.state.context, vars: u.state.localVars };
|
|
158
|
-
}
|
|
159
|
-
function V() {
|
|
160
|
-
u.state.localVars = u.state.context.vars, u.state.context = u.state.context.prev;
|
|
161
|
-
}
|
|
162
|
-
V.lex = !0;
|
|
163
|
-
function c(t, e) {
|
|
164
|
-
var r = function() {
|
|
165
|
-
var a = u.state;
|
|
166
|
-
a.lexical = new q(a.indented, u.stream.column(), t, null, a.lexical, e);
|
|
167
|
-
};
|
|
168
|
-
return r.lex = !0, r;
|
|
169
|
-
}
|
|
170
|
-
function o() {
|
|
171
|
-
var t = u.state;
|
|
172
|
-
t.lexical.prev && (t.lexical.type == ")" && (t.indented = t.lexical.indented), t.lexical = t.lexical.prev);
|
|
173
|
-
}
|
|
174
|
-
o.lex = !0;
|
|
175
|
-
function p(t) {
|
|
176
|
-
function e(r) {
|
|
177
|
-
return r == t ? n() : t == ";" ? b() : n(e);
|
|
178
|
-
}
|
|
179
|
-
return e;
|
|
180
|
-
}
|
|
181
|
-
function v(t) {
|
|
182
|
-
return t == "@" ? n(H) : t == "var" ? n(c("vardef"), P, p(";"), o) : t == "keyword a" ? n(c("form"), m, v, o) : t == "keyword b" ? n(c("form"), v, o) : t == "{" ? n(c("}"), O, Z, o, V) : t == ";" ? n() : t == "attribute" ? n(G) : t == "function" ? n(g) : t == "for" ? n(
|
|
183
|
-
c("form"),
|
|
184
|
-
p("("),
|
|
185
|
-
c(")"),
|
|
186
|
-
ut,
|
|
187
|
-
p(")"),
|
|
188
|
-
o,
|
|
189
|
-
v,
|
|
190
|
-
o
|
|
191
|
-
) : t == "variable" ? n(c("stat"), nt) : t == "switch" ? n(
|
|
192
|
-
c("form"),
|
|
193
|
-
m,
|
|
194
|
-
c("}", "switch"),
|
|
195
|
-
p("{"),
|
|
196
|
-
Z,
|
|
197
|
-
o,
|
|
198
|
-
o
|
|
199
|
-
) : t == "case" ? n(m, p(":")) : t == "default" ? n(p(":")) : t == "catch" ? n(
|
|
200
|
-
c("form"),
|
|
201
|
-
O,
|
|
202
|
-
p("("),
|
|
203
|
-
L,
|
|
204
|
-
p(")"),
|
|
205
|
-
v,
|
|
206
|
-
o,
|
|
207
|
-
V
|
|
208
|
-
) : t == "import" ? n(J, p(";")) : t == "typedef" ? n(rt) : b(c("stat"), m, p(";"), o);
|
|
209
|
-
}
|
|
210
|
-
function m(t) {
|
|
211
|
-
return j.hasOwnProperty(t) || t == "type" ? n(y) : t == "function" ? n(g) : t == "keyword c" ? n(D) : t == "(" ? n(c(")"), D, p(")"), o, y) : t == "operator" ? n(m) : t == "[" ? n(c("]"), h(D, "]"), o, y) : t == "{" ? n(c("}"), h(it, "}"), o, y) : n();
|
|
212
|
-
}
|
|
213
|
-
function D(t) {
|
|
214
|
-
return t.match(/[;\}\)\],]/) ? b() : b(m);
|
|
215
|
-
}
|
|
216
|
-
function y(t, e) {
|
|
217
|
-
if (t == "operator" && /\+\+|--/.test(e)) return n(y);
|
|
218
|
-
if (t == "operator" || t == ":") return n(m);
|
|
219
|
-
if (t != ";") {
|
|
220
|
-
if (t == "(") return n(c(")"), h(m, ")"), o, y);
|
|
221
|
-
if (t == ".") return n(at, y);
|
|
222
|
-
if (t == "[") return n(c("]"), m, p("]"), o, y);
|
|
223
|
-
}
|
|
224
|
-
}
|
|
225
|
-
function G(t) {
|
|
226
|
-
if (t == "attribute") return n(G);
|
|
227
|
-
if (t == "function") return n(g);
|
|
228
|
-
if (t == "var") return n(P);
|
|
229
|
-
}
|
|
230
|
-
function H(t) {
|
|
231
|
-
if (t == ":" || t == "variable") return n(H);
|
|
232
|
-
if (t == "(") return n(c(")"), h(et, ")"), o, v);
|
|
233
|
-
}
|
|
234
|
-
function et(t) {
|
|
235
|
-
if (t == "variable") return n();
|
|
236
|
-
}
|
|
237
|
-
function J(t, e) {
|
|
238
|
-
if (t == "variable" && /[A-Z]/.test(e.charAt(0)))
|
|
239
|
-
return C(e), n();
|
|
240
|
-
if (t == "variable" || t == "property" || t == "." || e == "*") return n(J);
|
|
241
|
-
}
|
|
242
|
-
function rt(t, e) {
|
|
243
|
-
if (t == "variable" && /[A-Z]/.test(e.charAt(0)))
|
|
244
|
-
return C(e), n();
|
|
245
|
-
if (t == "type" && /[A-Z]/.test(e.charAt(0)))
|
|
246
|
-
return n();
|
|
247
|
-
}
|
|
248
|
-
function nt(t) {
|
|
249
|
-
return t == ":" ? n(o, v) : b(y, p(";"), o);
|
|
250
|
-
}
|
|
251
|
-
function at(t) {
|
|
252
|
-
if (t == "variable")
|
|
253
|
-
return u.marked = "property", n();
|
|
254
|
-
}
|
|
255
|
-
function it(t) {
|
|
256
|
-
if (t == "variable" && (u.marked = "property"), j.hasOwnProperty(t)) return n(p(":"), m);
|
|
257
|
-
}
|
|
258
|
-
function h(t, e) {
|
|
259
|
-
function r(a) {
|
|
260
|
-
return a == "," ? n(t, r) : a == e ? n() : n(p(e));
|
|
261
|
-
}
|
|
262
|
-
return function(a) {
|
|
263
|
-
return a == e ? n() : b(t, r);
|
|
264
|
-
};
|
|
265
|
-
}
|
|
266
|
-
function Z(t) {
|
|
267
|
-
return t == "}" ? n() : b(v, Z);
|
|
268
|
-
}
|
|
269
|
-
function P(t, e) {
|
|
270
|
-
return t == "variable" ? (S(e), n(W, K)) : n();
|
|
271
|
-
}
|
|
272
|
-
function K(t, e) {
|
|
273
|
-
if (e == "=") return n(m, K);
|
|
274
|
-
if (t == ",") return n(P);
|
|
275
|
-
}
|
|
276
|
-
function ut(t, e) {
|
|
277
|
-
return t == "variable" ? (S(e), n(ot, m)) : b();
|
|
278
|
-
}
|
|
279
|
-
function ot(t, e) {
|
|
280
|
-
if (e == "in") return n();
|
|
281
|
-
}
|
|
282
|
-
function g(t, e) {
|
|
283
|
-
if (t == "variable" || t == "type")
|
|
284
|
-
return S(e), n(g);
|
|
285
|
-
if (e == "new") return n(g);
|
|
286
|
-
if (t == "(") return n(c(")"), O, h(L, ")"), o, W, v, V);
|
|
287
|
-
}
|
|
288
|
-
function W(t) {
|
|
289
|
-
if (t == ":") return n(lt);
|
|
290
|
-
}
|
|
291
|
-
function lt(t) {
|
|
292
|
-
if (t == "type" || t == "variable") return n();
|
|
293
|
-
if (t == "{") return n(c("}"), h(ct, "}"), o);
|
|
294
|
-
}
|
|
295
|
-
function ct(t) {
|
|
296
|
-
if (t == "variable") return n(W);
|
|
297
|
-
}
|
|
298
|
-
function L(t, e) {
|
|
299
|
-
if (t == "variable")
|
|
300
|
-
return S(e), n(W);
|
|
301
|
-
}
|
|
302
|
-
const ft = {
|
|
303
|
-
name: "haxe",
|
|
304
|
-
startState: function(t) {
|
|
305
|
-
var e = ["Int", "Float", "String", "Void", "Std", "Bool", "Dynamic", "Array"], r = {
|
|
306
|
-
tokenize: A,
|
|
307
|
-
reAllowed: !0,
|
|
308
|
-
kwAllowed: !0,
|
|
309
|
-
cc: [],
|
|
310
|
-
lexical: new q(-t, 0, "block", !1),
|
|
311
|
-
importedtypes: e,
|
|
312
|
-
context: null,
|
|
313
|
-
indented: 0
|
|
314
|
-
};
|
|
315
|
-
return r;
|
|
316
|
-
},
|
|
317
|
-
token: function(t, e) {
|
|
318
|
-
if (t.sol() && (e.lexical.hasOwnProperty("align") || (e.lexical.align = !1), e.indented = t.indentation()), t.eatSpace()) return null;
|
|
319
|
-
var r = e.tokenize(t, e);
|
|
320
|
-
return f == "comment" ? r : (e.reAllowed = !!(f == "operator" || f == "keyword c" || f.match(/^[\[{}\(,;:]$/)), e.kwAllowed = f != ".", X(e, r, f, F, t));
|
|
321
|
-
},
|
|
322
|
-
indent: function(t, e, r) {
|
|
323
|
-
if (t.tokenize != A) return 0;
|
|
324
|
-
var a = e && e.charAt(0), i = t.lexical;
|
|
325
|
-
i.type == "stat" && a == "}" && (i = i.prev);
|
|
326
|
-
var s = i.type, x = a == s;
|
|
327
|
-
return s == "vardef" ? i.indented + 4 : s == "form" && a == "{" ? i.indented : s == "stat" || s == "form" ? i.indented + r.unit : i.info == "switch" && !x ? i.indented + (/^(?:case|default)\b/.test(e) ? r.unit : 2 * r.unit) : i.align ? i.column + (x ? 0 : 1) : i.indented + (x ? 0 : r.unit);
|
|
328
|
-
},
|
|
329
|
-
languageData: {
|
|
330
|
-
indentOnInput: /^\s*[{}]$/,
|
|
331
|
-
commentTokens: { line: "//", block: { open: "/*", close: "*/" } }
|
|
332
|
-
}
|
|
333
|
-
}, st = {
|
|
334
|
-
name: "hxml",
|
|
335
|
-
startState: function() {
|
|
336
|
-
return {
|
|
337
|
-
define: !1,
|
|
338
|
-
inString: !1
|
|
339
|
-
};
|
|
340
|
-
},
|
|
341
|
-
token: function(t, e) {
|
|
342
|
-
var i = t.peek(), r = t.sol();
|
|
343
|
-
if (i == "#")
|
|
344
|
-
return t.skipToEnd(), "comment";
|
|
345
|
-
if (r && i == "-") {
|
|
346
|
-
var a = "variable-2";
|
|
347
|
-
return t.eat(/-/), t.peek() == "-" && (t.eat(/-/), a = "keyword a"), t.peek() == "D" && (t.eat(/[D]/), a = "keyword c", e.define = !0), t.eatWhile(/[A-Z]/i), a;
|
|
348
|
-
}
|
|
349
|
-
var i = t.peek();
|
|
350
|
-
return e.inString == !1 && i == "'" && (e.inString = !0, t.next()), e.inString == !0 ? (t.skipTo("'") || t.skipToEnd(), t.peek() == "'" && (t.next(), e.inString = !1), "string") : (t.next(), null);
|
|
351
|
-
},
|
|
352
|
-
languageData: {
|
|
353
|
-
commentTokens: { line: "#" }
|
|
354
|
-
}
|
|
355
|
-
};
|
|
356
|
-
export {
|
|
357
|
-
ft as haxe,
|
|
358
|
-
st as hxml
|
|
359
|
-
};
|
|
@@ -1,44 +0,0 @@
|
|
|
1
|
-
function e(t, n) {
|
|
2
|
-
return t.skipToEnd(), n.cur = u, "error";
|
|
3
|
-
}
|
|
4
|
-
function i(t, n) {
|
|
5
|
-
return t.match(/^HTTP\/\d\.\d/) ? (n.cur = a, "keyword") : t.match(/^[A-Z]+/) && /[ \t]/.test(t.peek()) ? (n.cur = s, "keyword") : e(t, n);
|
|
6
|
-
}
|
|
7
|
-
function a(t, n) {
|
|
8
|
-
var r = t.match(/^\d+/);
|
|
9
|
-
if (!r) return e(t, n);
|
|
10
|
-
n.cur = d;
|
|
11
|
-
var c = Number(r[0]);
|
|
12
|
-
return c >= 100 && c < 400 ? "atom" : "error";
|
|
13
|
-
}
|
|
14
|
-
function d(t, n) {
|
|
15
|
-
return t.skipToEnd(), n.cur = u, null;
|
|
16
|
-
}
|
|
17
|
-
function s(t, n) {
|
|
18
|
-
return t.eatWhile(/\S/), n.cur = f, "string.special";
|
|
19
|
-
}
|
|
20
|
-
function f(t, n) {
|
|
21
|
-
return t.match(/^HTTP\/\d\.\d$/) ? (n.cur = u, "keyword") : e(t, n);
|
|
22
|
-
}
|
|
23
|
-
function u(t) {
|
|
24
|
-
return t.sol() && !t.eat(/[ \t]/) ? t.match(/^.*?:/) ? "atom" : (t.skipToEnd(), "error") : (t.skipToEnd(), "string");
|
|
25
|
-
}
|
|
26
|
-
function o(t) {
|
|
27
|
-
return t.skipToEnd(), null;
|
|
28
|
-
}
|
|
29
|
-
const p = {
|
|
30
|
-
name: "http",
|
|
31
|
-
token: function(t, n) {
|
|
32
|
-
var r = n.cur;
|
|
33
|
-
return r != u && r != o && t.eatSpace() ? null : r(t, n);
|
|
34
|
-
},
|
|
35
|
-
blankLine: function(t) {
|
|
36
|
-
t.cur = o;
|
|
37
|
-
},
|
|
38
|
-
startState: function() {
|
|
39
|
-
return { cur: i };
|
|
40
|
-
}
|
|
41
|
-
};
|
|
42
|
-
export {
|
|
43
|
-
p as http
|
|
44
|
-
};
|