@aiao/code-editor-react 0.0.9 → 0.0.11
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 +5 -5
- 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-4oLq9F9B-CiG9J_wS.js +0 -944
- package/dist/index-9NH8hlZ--ZzqmPLCF.js +0 -342
- package/dist/index-BFXNCCbG-LloeVRnr.js +0 -253
- package/dist/index-BLHYcXXK-BxaAXMNw.js +0 -101
- package/dist/index-BQU3Rb2C-DeyQP3x_.js +0 -290
- package/dist/index-Bg18ePld-Di0FNEJ4.js +0 -157
- package/dist/index-Bp5lqnbN-BM2h2Xfi.js +0 -555
- package/dist/index-Bqzq8A1N-Dn1yj5KO.js +0 -59
- package/dist/index-Bx-s4g99-QIFA9lMK.js +0 -76
- package/dist/index-BxX25QmV-Cnf0cb51.js +0 -248
- package/dist/index-CFCzgc33-MPwtm3eY.js +0 -1917
- package/dist/index-CL7JTU9M-Bl8j0-fU.js +0 -136
- package/dist/index-CgClvcTI.js +0 -35617
- package/dist/index-CipmEceX-D1vXXSTd.js +0 -74
- package/dist/index-Cv4vvpa2-B8Ojlo_m.js +0 -1305
- package/dist/index-D4hhdPbZ-DXEZQFco.js +0 -6152
- package/dist/index-DhNQ8g9I-CjBYiskZ.js +0 -270
- package/dist/index-Djp53tAP-DnPgUG4S.js +0 -94
- package/dist/index-KlsAFhIj-Dzil0Vr8.js +0 -566
- package/dist/index-OntZqtu6-DPgaaGGJ.js +0 -305
- package/dist/index-PGnZjMCR-BPDty4q0.js +0 -301
- package/dist/index-TyYoYgss-BIjAZ6j1.js +0 -613
- package/dist/index-oMSPmlXA-CoPtKzNe.js +0 -960
- package/dist/index-rQC6Gbk0-BZ6M0IzM.js +0 -138
- 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,487 +0,0 @@
|
|
|
1
|
-
var x = [
|
|
2
|
-
"-type",
|
|
3
|
-
"-spec",
|
|
4
|
-
"-export_type",
|
|
5
|
-
"-opaque"
|
|
6
|
-
], S = [
|
|
7
|
-
"after",
|
|
8
|
-
"begin",
|
|
9
|
-
"catch",
|
|
10
|
-
"case",
|
|
11
|
-
"cond",
|
|
12
|
-
"end",
|
|
13
|
-
"fun",
|
|
14
|
-
"if",
|
|
15
|
-
"let",
|
|
16
|
-
"of",
|
|
17
|
-
"query",
|
|
18
|
-
"receive",
|
|
19
|
-
"try",
|
|
20
|
-
"when"
|
|
21
|
-
], z = /[\->,;]/, W = [
|
|
22
|
-
"->",
|
|
23
|
-
";",
|
|
24
|
-
","
|
|
25
|
-
], U = [
|
|
26
|
-
"and",
|
|
27
|
-
"andalso",
|
|
28
|
-
"band",
|
|
29
|
-
"bnot",
|
|
30
|
-
"bor",
|
|
31
|
-
"bsl",
|
|
32
|
-
"bsr",
|
|
33
|
-
"bxor",
|
|
34
|
-
"div",
|
|
35
|
-
"not",
|
|
36
|
-
"or",
|
|
37
|
-
"orelse",
|
|
38
|
-
"rem",
|
|
39
|
-
"xor"
|
|
40
|
-
], A = /[\+\-\*\/<>=\|:!]/, E = [
|
|
41
|
-
"=",
|
|
42
|
-
"+",
|
|
43
|
-
"-",
|
|
44
|
-
"*",
|
|
45
|
-
"/",
|
|
46
|
-
">",
|
|
47
|
-
">=",
|
|
48
|
-
"<",
|
|
49
|
-
"=<",
|
|
50
|
-
"=:=",
|
|
51
|
-
"==",
|
|
52
|
-
"=/=",
|
|
53
|
-
"/=",
|
|
54
|
-
"||",
|
|
55
|
-
"<-",
|
|
56
|
-
"!"
|
|
57
|
-
], Z = /[<\(\[\{]/, d = [
|
|
58
|
-
"<<",
|
|
59
|
-
"(",
|
|
60
|
-
"[",
|
|
61
|
-
"{"
|
|
62
|
-
], q = /[>\)\]\}]/, y = [
|
|
63
|
-
"}",
|
|
64
|
-
"]",
|
|
65
|
-
")",
|
|
66
|
-
">>"
|
|
67
|
-
], T = [
|
|
68
|
-
"is_atom",
|
|
69
|
-
"is_binary",
|
|
70
|
-
"is_bitstring",
|
|
71
|
-
"is_boolean",
|
|
72
|
-
"is_float",
|
|
73
|
-
"is_function",
|
|
74
|
-
"is_integer",
|
|
75
|
-
"is_list",
|
|
76
|
-
"is_number",
|
|
77
|
-
"is_pid",
|
|
78
|
-
"is_port",
|
|
79
|
-
"is_record",
|
|
80
|
-
"is_reference",
|
|
81
|
-
"is_tuple",
|
|
82
|
-
"atom",
|
|
83
|
-
"binary",
|
|
84
|
-
"bitstring",
|
|
85
|
-
"boolean",
|
|
86
|
-
"function",
|
|
87
|
-
"integer",
|
|
88
|
-
"list",
|
|
89
|
-
"number",
|
|
90
|
-
"pid",
|
|
91
|
-
"port",
|
|
92
|
-
"record",
|
|
93
|
-
"reference",
|
|
94
|
-
"tuple"
|
|
95
|
-
], D = [
|
|
96
|
-
"abs",
|
|
97
|
-
"adler32",
|
|
98
|
-
"adler32_combine",
|
|
99
|
-
"alive",
|
|
100
|
-
"apply",
|
|
101
|
-
"atom_to_binary",
|
|
102
|
-
"atom_to_list",
|
|
103
|
-
"binary_to_atom",
|
|
104
|
-
"binary_to_existing_atom",
|
|
105
|
-
"binary_to_list",
|
|
106
|
-
"binary_to_term",
|
|
107
|
-
"bit_size",
|
|
108
|
-
"bitstring_to_list",
|
|
109
|
-
"byte_size",
|
|
110
|
-
"check_process_code",
|
|
111
|
-
"contact_binary",
|
|
112
|
-
"crc32",
|
|
113
|
-
"crc32_combine",
|
|
114
|
-
"date",
|
|
115
|
-
"decode_packet",
|
|
116
|
-
"delete_module",
|
|
117
|
-
"disconnect_node",
|
|
118
|
-
"element",
|
|
119
|
-
"erase",
|
|
120
|
-
"exit",
|
|
121
|
-
"float",
|
|
122
|
-
"float_to_list",
|
|
123
|
-
"garbage_collect",
|
|
124
|
-
"get",
|
|
125
|
-
"get_keys",
|
|
126
|
-
"group_leader",
|
|
127
|
-
"halt",
|
|
128
|
-
"hd",
|
|
129
|
-
"integer_to_list",
|
|
130
|
-
"internal_bif",
|
|
131
|
-
"iolist_size",
|
|
132
|
-
"iolist_to_binary",
|
|
133
|
-
"is_alive",
|
|
134
|
-
"is_atom",
|
|
135
|
-
"is_binary",
|
|
136
|
-
"is_bitstring",
|
|
137
|
-
"is_boolean",
|
|
138
|
-
"is_float",
|
|
139
|
-
"is_function",
|
|
140
|
-
"is_integer",
|
|
141
|
-
"is_list",
|
|
142
|
-
"is_number",
|
|
143
|
-
"is_pid",
|
|
144
|
-
"is_port",
|
|
145
|
-
"is_process_alive",
|
|
146
|
-
"is_record",
|
|
147
|
-
"is_reference",
|
|
148
|
-
"is_tuple",
|
|
149
|
-
"length",
|
|
150
|
-
"link",
|
|
151
|
-
"list_to_atom",
|
|
152
|
-
"list_to_binary",
|
|
153
|
-
"list_to_bitstring",
|
|
154
|
-
"list_to_existing_atom",
|
|
155
|
-
"list_to_float",
|
|
156
|
-
"list_to_integer",
|
|
157
|
-
"list_to_pid",
|
|
158
|
-
"list_to_tuple",
|
|
159
|
-
"load_module",
|
|
160
|
-
"make_ref",
|
|
161
|
-
"module_loaded",
|
|
162
|
-
"monitor_node",
|
|
163
|
-
"node",
|
|
164
|
-
"node_link",
|
|
165
|
-
"node_unlink",
|
|
166
|
-
"nodes",
|
|
167
|
-
"notalive",
|
|
168
|
-
"now",
|
|
169
|
-
"open_port",
|
|
170
|
-
"pid_to_list",
|
|
171
|
-
"port_close",
|
|
172
|
-
"port_command",
|
|
173
|
-
"port_connect",
|
|
174
|
-
"port_control",
|
|
175
|
-
"pre_loaded",
|
|
176
|
-
"process_flag",
|
|
177
|
-
"process_info",
|
|
178
|
-
"processes",
|
|
179
|
-
"purge_module",
|
|
180
|
-
"put",
|
|
181
|
-
"register",
|
|
182
|
-
"registered",
|
|
183
|
-
"round",
|
|
184
|
-
"self",
|
|
185
|
-
"setelement",
|
|
186
|
-
"size",
|
|
187
|
-
"spawn",
|
|
188
|
-
"spawn_link",
|
|
189
|
-
"spawn_monitor",
|
|
190
|
-
"spawn_opt",
|
|
191
|
-
"split_binary",
|
|
192
|
-
"statistics",
|
|
193
|
-
"term_to_binary",
|
|
194
|
-
"time",
|
|
195
|
-
"throw",
|
|
196
|
-
"tl",
|
|
197
|
-
"trunc",
|
|
198
|
-
"tuple_size",
|
|
199
|
-
"tuple_to_list",
|
|
200
|
-
"unlink",
|
|
201
|
-
"unregister",
|
|
202
|
-
"whereis"
|
|
203
|
-
], f = /[\w@Ø-ÞÀ-Öß-öø-ÿ]/, N = /[0-7]{1,3}|[bdefnrstv\\"']|\^[a-zA-Z]|x[0-9a-zA-Z]{2}|x{[0-9a-zA-Z]+}/;
|
|
204
|
-
function O(t, r) {
|
|
205
|
-
if (r.in_string)
|
|
206
|
-
return r.in_string = !k(t), a(r, t, "string");
|
|
207
|
-
if (r.in_atom)
|
|
208
|
-
return r.in_atom = !h(t), a(r, t, "atom");
|
|
209
|
-
if (t.eatSpace())
|
|
210
|
-
return a(r, t, "whitespace");
|
|
211
|
-
if (!_(r) && t.match(/-\s*[a-zß-öø-ÿ][\wØ-ÞÀ-Öß-öø-ÿ]*/))
|
|
212
|
-
return o(t.current(), x) ? a(r, t, "type") : a(r, t, "attribute");
|
|
213
|
-
var e = t.next();
|
|
214
|
-
if (e == "%")
|
|
215
|
-
return t.skipToEnd(), a(r, t, "comment");
|
|
216
|
-
if (e == ":")
|
|
217
|
-
return a(r, t, "colon");
|
|
218
|
-
if (e == "?")
|
|
219
|
-
return t.eatSpace(), t.eatWhile(f), a(r, t, "macro");
|
|
220
|
-
if (e == "#")
|
|
221
|
-
return t.eatSpace(), t.eatWhile(f), a(r, t, "record");
|
|
222
|
-
if (e == "$")
|
|
223
|
-
return t.next() == "\\" && !t.match(N) ? a(r, t, "error") : a(r, t, "number");
|
|
224
|
-
if (e == ".")
|
|
225
|
-
return a(r, t, "dot");
|
|
226
|
-
if (e == "'") {
|
|
227
|
-
if (!(r.in_atom = !h(t))) {
|
|
228
|
-
if (t.match(/\s*\/\s*[0-9]/, !1))
|
|
229
|
-
return t.match(/\s*\/\s*[0-9]/, !0), a(r, t, "fun");
|
|
230
|
-
if (t.match(/\s*\(/, !1) || t.match(/\s*:/, !1))
|
|
231
|
-
return a(r, t, "function");
|
|
232
|
-
}
|
|
233
|
-
return a(r, t, "atom");
|
|
234
|
-
}
|
|
235
|
-
if (e == '"')
|
|
236
|
-
return r.in_string = !k(t), a(r, t, "string");
|
|
237
|
-
if (/[A-Z_Ø-ÞÀ-Ö]/.test(e))
|
|
238
|
-
return t.eatWhile(f), a(r, t, "variable");
|
|
239
|
-
if (/[a-z_ß-öø-ÿ]/.test(e)) {
|
|
240
|
-
if (t.eatWhile(f), t.match(/\s*\/\s*[0-9]/, !1))
|
|
241
|
-
return t.match(/\s*\/\s*[0-9]/, !0), a(r, t, "fun");
|
|
242
|
-
var n = t.current();
|
|
243
|
-
return o(n, S) ? a(r, t, "keyword") : o(n, U) ? a(r, t, "operator") : t.match(/\s*\(/, !1) ? o(n, D) && (_(r).token != ":" || _(r, 2).token == "erlang") ? a(r, t, "builtin") : o(n, T) ? a(r, t, "guard") : a(r, t, "function") : $(t) == ":" ? n == "erlang" ? a(r, t, "builtin") : a(r, t, "function") : o(n, ["true", "false"]) ? a(r, t, "boolean") : a(r, t, "atom");
|
|
244
|
-
}
|
|
245
|
-
var u = /[0-9]/, i = /[0-9a-zA-Z]/;
|
|
246
|
-
return u.test(e) ? (t.eatWhile(u), t.eat("#") ? t.eatWhile(i) || t.backUp(1) : t.eat(".") && (t.eatWhile(u) ? t.eat(/[eE]/) && (t.eat(/[-+]/) ? t.eatWhile(u) || t.backUp(2) : t.eatWhile(u) || t.backUp(1)) : t.backUp(1)), a(r, t, "number")) : b(t, Z, d) ? a(r, t, "open_paren") : b(t, q, y) ? a(r, t, "close_paren") : g(t, z, W) ? a(r, t, "separator") : g(t, A, E) ? a(r, t, "operator") : a(r, t, null);
|
|
247
|
-
}
|
|
248
|
-
function b(t, r, e) {
|
|
249
|
-
if (t.current().length == 1 && r.test(t.current())) {
|
|
250
|
-
for (t.backUp(1); r.test(t.peek()); )
|
|
251
|
-
if (t.next(), o(t.current(), e))
|
|
252
|
-
return !0;
|
|
253
|
-
t.backUp(t.current().length - 1);
|
|
254
|
-
}
|
|
255
|
-
return !1;
|
|
256
|
-
}
|
|
257
|
-
function g(t, r, e) {
|
|
258
|
-
if (t.current().length == 1 && r.test(t.current())) {
|
|
259
|
-
for (; r.test(t.peek()); )
|
|
260
|
-
t.next();
|
|
261
|
-
for (; 0 < t.current().length; ) {
|
|
262
|
-
if (o(t.current(), e))
|
|
263
|
-
return !0;
|
|
264
|
-
t.backUp(1);
|
|
265
|
-
}
|
|
266
|
-
t.next();
|
|
267
|
-
}
|
|
268
|
-
return !1;
|
|
269
|
-
}
|
|
270
|
-
function k(t) {
|
|
271
|
-
return v(t, '"', "\\");
|
|
272
|
-
}
|
|
273
|
-
function h(t) {
|
|
274
|
-
return v(t, "'", "\\");
|
|
275
|
-
}
|
|
276
|
-
function v(t, r, e) {
|
|
277
|
-
for (; !t.eol(); ) {
|
|
278
|
-
var n = t.next();
|
|
279
|
-
if (n == r)
|
|
280
|
-
return !0;
|
|
281
|
-
n == e && t.next();
|
|
282
|
-
}
|
|
283
|
-
return !1;
|
|
284
|
-
}
|
|
285
|
-
function $(t) {
|
|
286
|
-
var r = t.match(/^\s*([^\s%])/, !1);
|
|
287
|
-
return r ? r[1] : "";
|
|
288
|
-
}
|
|
289
|
-
function o(t, r) {
|
|
290
|
-
return -1 < r.indexOf(t);
|
|
291
|
-
}
|
|
292
|
-
function a(t, r, e) {
|
|
293
|
-
switch (C(t, j(e, r)), e) {
|
|
294
|
-
case "atom":
|
|
295
|
-
return "atom";
|
|
296
|
-
case "attribute":
|
|
297
|
-
return "attribute";
|
|
298
|
-
case "boolean":
|
|
299
|
-
return "atom";
|
|
300
|
-
case "builtin":
|
|
301
|
-
return "builtin";
|
|
302
|
-
case "close_paren":
|
|
303
|
-
return null;
|
|
304
|
-
case "colon":
|
|
305
|
-
return null;
|
|
306
|
-
case "comment":
|
|
307
|
-
return "comment";
|
|
308
|
-
case "dot":
|
|
309
|
-
return null;
|
|
310
|
-
case "error":
|
|
311
|
-
return "error";
|
|
312
|
-
case "fun":
|
|
313
|
-
return "meta";
|
|
314
|
-
case "function":
|
|
315
|
-
return "tag";
|
|
316
|
-
case "guard":
|
|
317
|
-
return "property";
|
|
318
|
-
case "keyword":
|
|
319
|
-
return "keyword";
|
|
320
|
-
case "macro":
|
|
321
|
-
return "macroName";
|
|
322
|
-
case "number":
|
|
323
|
-
return "number";
|
|
324
|
-
case "open_paren":
|
|
325
|
-
return null;
|
|
326
|
-
case "operator":
|
|
327
|
-
return "operator";
|
|
328
|
-
case "record":
|
|
329
|
-
return "bracket";
|
|
330
|
-
case "separator":
|
|
331
|
-
return null;
|
|
332
|
-
case "string":
|
|
333
|
-
return "string";
|
|
334
|
-
case "type":
|
|
335
|
-
return "def";
|
|
336
|
-
case "variable":
|
|
337
|
-
return "variable";
|
|
338
|
-
default:
|
|
339
|
-
return null;
|
|
340
|
-
}
|
|
341
|
-
}
|
|
342
|
-
function w(t, r, e, n) {
|
|
343
|
-
return {
|
|
344
|
-
token: t,
|
|
345
|
-
column: r,
|
|
346
|
-
indent: e,
|
|
347
|
-
type: n
|
|
348
|
-
};
|
|
349
|
-
}
|
|
350
|
-
function j(t, r) {
|
|
351
|
-
return w(
|
|
352
|
-
r.current(),
|
|
353
|
-
r.column(),
|
|
354
|
-
r.indentation(),
|
|
355
|
-
t
|
|
356
|
-
);
|
|
357
|
-
}
|
|
358
|
-
function B(t) {
|
|
359
|
-
return w(t, 0, 0, t);
|
|
360
|
-
}
|
|
361
|
-
function _(t, r) {
|
|
362
|
-
var e = t.tokenStack.length, n = r || 1;
|
|
363
|
-
return e < n ? !1 : t.tokenStack[e - n];
|
|
364
|
-
}
|
|
365
|
-
function C(t, r) {
|
|
366
|
-
r.type == "comment" || r.type == "whitespace" || (t.tokenStack = F(t.tokenStack, r), t.tokenStack = G(t.tokenStack));
|
|
367
|
-
}
|
|
368
|
-
function F(t, r) {
|
|
369
|
-
var e = t.length - 1;
|
|
370
|
-
return 0 < e && t[e].type === "record" && r.type === "dot" ? t.pop() : (0 < e && t[e].type === "group" && t.pop(), t.push(r)), t;
|
|
371
|
-
}
|
|
372
|
-
function G(t) {
|
|
373
|
-
if (!t.length) return t;
|
|
374
|
-
var r = t.length - 1;
|
|
375
|
-
if (t[r].type === "dot")
|
|
376
|
-
return [];
|
|
377
|
-
if (r > 1 && t[r].type === "fun" && t[r - 1].token === "fun")
|
|
378
|
-
return t.slice(0, r - 1);
|
|
379
|
-
switch (t[r].token) {
|
|
380
|
-
case "}":
|
|
381
|
-
return s(t, { g: ["{"] });
|
|
382
|
-
case "]":
|
|
383
|
-
return s(t, { i: ["["] });
|
|
384
|
-
case ")":
|
|
385
|
-
return s(t, { i: ["("] });
|
|
386
|
-
case ">>":
|
|
387
|
-
return s(t, { i: ["<<"] });
|
|
388
|
-
case "end":
|
|
389
|
-
return s(t, { i: ["begin", "case", "fun", "if", "receive", "try"] });
|
|
390
|
-
case ",":
|
|
391
|
-
return s(t, { e: [
|
|
392
|
-
"begin",
|
|
393
|
-
"try",
|
|
394
|
-
"when",
|
|
395
|
-
"->",
|
|
396
|
-
",",
|
|
397
|
-
"(",
|
|
398
|
-
"[",
|
|
399
|
-
"{",
|
|
400
|
-
"<<"
|
|
401
|
-
] });
|
|
402
|
-
case "->":
|
|
403
|
-
return s(t, {
|
|
404
|
-
r: ["when"],
|
|
405
|
-
m: ["try", "if", "case", "receive"]
|
|
406
|
-
});
|
|
407
|
-
case ";":
|
|
408
|
-
return s(t, { E: ["case", "fun", "if", "receive", "try", "when"] });
|
|
409
|
-
case "catch":
|
|
410
|
-
return s(t, { e: ["try"] });
|
|
411
|
-
case "of":
|
|
412
|
-
return s(t, { e: ["case"] });
|
|
413
|
-
case "after":
|
|
414
|
-
return s(t, { e: ["receive", "try"] });
|
|
415
|
-
default:
|
|
416
|
-
return t;
|
|
417
|
-
}
|
|
418
|
-
}
|
|
419
|
-
function s(t, r) {
|
|
420
|
-
for (var e in r)
|
|
421
|
-
for (var n = t.length - 1, u = r[e], i = n - 1; -1 < i; i--)
|
|
422
|
-
if (o(t[i].token, u)) {
|
|
423
|
-
var c = t.slice(0, i);
|
|
424
|
-
switch (e) {
|
|
425
|
-
case "m":
|
|
426
|
-
return c.concat(t[i]).concat(t[n]);
|
|
427
|
-
case "r":
|
|
428
|
-
return c.concat(t[n]);
|
|
429
|
-
case "i":
|
|
430
|
-
return c;
|
|
431
|
-
case "g":
|
|
432
|
-
return c.concat(B("group"));
|
|
433
|
-
case "E":
|
|
434
|
-
return c.concat(t[i]);
|
|
435
|
-
case "e":
|
|
436
|
-
return c.concat(t[i]);
|
|
437
|
-
}
|
|
438
|
-
}
|
|
439
|
-
return e == "E" ? [] : t;
|
|
440
|
-
}
|
|
441
|
-
function H(t, r, e) {
|
|
442
|
-
var n, u = I(r), i = _(t, 1), c = _(t, 2);
|
|
443
|
-
return t.in_string || t.in_atom ? null : c ? i.token == "when" ? i.column + e.unit : u === "when" && c.type === "function" ? c.indent + e.unit : u === "(" && i.token === "fun" ? i.column + 3 : u === "catch" && (n = m(t, ["try"])) ? n.column : o(u, ["end", "after", "of"]) ? (n = m(t, ["begin", "case", "fun", "if", "receive", "try"]), n ? n.column : null) : o(u, y) ? (n = m(t, d), n ? n.column : null) : o(i.token, [",", "|", "||"]) || o(u, [",", "|", "||"]) ? (n = P(t), n ? n.column + n.token.length : e.unit) : i.token == "->" ? o(c.token, ["receive", "case", "if", "try"]) ? c.column + e.unit + e.unit : c.column + e.unit : o(i.token, d) ? i.column + i.token.length : (n = Q(t), l(n) ? n.column + e.unit : 0) : 0;
|
|
444
|
-
}
|
|
445
|
-
function I(t) {
|
|
446
|
-
var r = t.match(/,|[a-z]+|\}|\]|\)|>>|\|+|\(/);
|
|
447
|
-
return l(r) && r.index === 0 ? r[0] : "";
|
|
448
|
-
}
|
|
449
|
-
function P(t) {
|
|
450
|
-
var r = t.tokenStack.slice(0, -1), e = p(r, "type", ["open_paren"]);
|
|
451
|
-
return l(r[e]) ? r[e] : !1;
|
|
452
|
-
}
|
|
453
|
-
function Q(t) {
|
|
454
|
-
var r = t.tokenStack, e = p(r, "type", ["open_paren", "separator", "keyword"]), n = p(r, "type", ["operator"]);
|
|
455
|
-
return l(e) && l(n) && e < n ? r[e + 1] : l(e) ? r[e] : !1;
|
|
456
|
-
}
|
|
457
|
-
function m(t, r) {
|
|
458
|
-
var e = t.tokenStack, n = p(e, "token", r);
|
|
459
|
-
return l(e[n]) ? e[n] : !1;
|
|
460
|
-
}
|
|
461
|
-
function p(t, r, e) {
|
|
462
|
-
for (var n = t.length - 1; -1 < n; n--)
|
|
463
|
-
if (o(t[n][r], e))
|
|
464
|
-
return n;
|
|
465
|
-
return !1;
|
|
466
|
-
}
|
|
467
|
-
function l(t) {
|
|
468
|
-
return t !== !1 && t != null;
|
|
469
|
-
}
|
|
470
|
-
const R = {
|
|
471
|
-
name: "erlang",
|
|
472
|
-
startState() {
|
|
473
|
-
return {
|
|
474
|
-
tokenStack: [],
|
|
475
|
-
in_string: !1,
|
|
476
|
-
in_atom: !1
|
|
477
|
-
};
|
|
478
|
-
},
|
|
479
|
-
token: O,
|
|
480
|
-
indent: H,
|
|
481
|
-
languageData: {
|
|
482
|
-
commentTokens: { line: "%" }
|
|
483
|
-
}
|
|
484
|
-
};
|
|
485
|
-
export {
|
|
486
|
-
R as erlang
|
|
487
|
-
};
|
|
@@ -1,65 +0,0 @@
|
|
|
1
|
-
import { k as e } from "./simple-mode-mNVtnu0l-BC8mf7KF.js";
|
|
2
|
-
const n = e({
|
|
3
|
-
start: [
|
|
4
|
-
// comments
|
|
5
|
-
{ regex: /#?!.*/, token: "comment" },
|
|
6
|
-
// strings """, multiline --> state
|
|
7
|
-
{ regex: /"""/, token: "string", next: "string3" },
|
|
8
|
-
{ regex: /(STRING:)(\s)/, token: ["keyword", null], next: "string2" },
|
|
9
|
-
{ regex: /\S*?"/, token: "string", next: "string" },
|
|
10
|
-
// numbers: dec, hex, unicode, bin, fractional, complex
|
|
11
|
-
{ regex: /(?:0x[\d,a-f]+)|(?:0o[0-7]+)|(?:0b[0,1]+)|(?:\-?\d+.?\d*)(?=\s)/, token: "number" },
|
|
12
|
-
//{regex: /[+-]?/} //fractional
|
|
13
|
-
// definition: defining word, defined word, etc
|
|
14
|
-
{ regex: /((?:GENERIC)|\:?\:)(\s+)(\S+)(\s+)(\()/, token: ["keyword", null, "def", null, "bracket"], next: "stack" },
|
|
15
|
-
// method definition: defining word, type, defined word, etc
|
|
16
|
-
{ regex: /(M\:)(\s+)(\S+)(\s+)(\S+)/, token: ["keyword", null, "def", null, "tag"] },
|
|
17
|
-
// vocabulary using --> state
|
|
18
|
-
{ regex: /USING\:/, token: "keyword", next: "vocabulary" },
|
|
19
|
-
// vocabulary definition/use
|
|
20
|
-
{ regex: /(USE\:|IN\:)(\s+)(\S+)(?=\s|$)/, token: ["keyword", null, "tag"] },
|
|
21
|
-
// definition: a defining word, defined word
|
|
22
|
-
{ regex: /(\S+\:)(\s+)(\S+)(?=\s|$)/, token: ["keyword", null, "def"] },
|
|
23
|
-
// "keywords", incl. ; t f . [ ] { } defining words
|
|
24
|
-
{ regex: /(?:;|\\|t|f|if|loop|while|until|do|PRIVATE>|<PRIVATE|\.|\S*\[|\]|\S*\{|\})(?=\s|$)/, token: "keyword" },
|
|
25
|
-
// <constructors> and the like
|
|
26
|
-
{ regex: /\S+[\)>\.\*\?]+(?=\s|$)/, token: "builtin" },
|
|
27
|
-
{ regex: /[\)><]+\S+(?=\s|$)/, token: "builtin" },
|
|
28
|
-
// operators
|
|
29
|
-
{ regex: /(?:[\+\-\=\/\*<>])(?=\s|$)/, token: "keyword" },
|
|
30
|
-
// any id (?)
|
|
31
|
-
{ regex: /\S+/, token: "variable" },
|
|
32
|
-
{ regex: /\s+|./, token: null }
|
|
33
|
-
],
|
|
34
|
-
vocabulary: [
|
|
35
|
-
{ regex: /;/, token: "keyword", next: "start" },
|
|
36
|
-
{ regex: /\S+/, token: "tag" },
|
|
37
|
-
{ regex: /\s+|./, token: null }
|
|
38
|
-
],
|
|
39
|
-
string: [
|
|
40
|
-
{ regex: /(?:[^\\]|\\.)*?"/, token: "string", next: "start" },
|
|
41
|
-
{ regex: /.*/, token: "string" }
|
|
42
|
-
],
|
|
43
|
-
string2: [
|
|
44
|
-
{ regex: /^;/, token: "keyword", next: "start" },
|
|
45
|
-
{ regex: /.*/, token: "string" }
|
|
46
|
-
],
|
|
47
|
-
string3: [
|
|
48
|
-
{ regex: /(?:[^\\]|\\.)*?"""/, token: "string", next: "start" },
|
|
49
|
-
{ regex: /.*/, token: "string" }
|
|
50
|
-
],
|
|
51
|
-
stack: [
|
|
52
|
-
{ regex: /\)/, token: "bracket", next: "start" },
|
|
53
|
-
{ regex: /--/, token: "bracket" },
|
|
54
|
-
{ regex: /\S+/, token: "meta" },
|
|
55
|
-
{ regex: /\s+|./, token: null }
|
|
56
|
-
],
|
|
57
|
-
languageData: {
|
|
58
|
-
name: "factor",
|
|
59
|
-
dontIndentStates: ["start", "vocabulary", "string", "string3", "stack"],
|
|
60
|
-
commentTokens: { line: "!" }
|
|
61
|
-
}
|
|
62
|
-
});
|
|
63
|
-
export {
|
|
64
|
-
n as factor
|
|
65
|
-
};
|
|
@@ -1,103 +0,0 @@
|
|
|
1
|
-
var s = {
|
|
2
|
-
term: !0,
|
|
3
|
-
method: !0,
|
|
4
|
-
accu: !0,
|
|
5
|
-
rule: !0,
|
|
6
|
-
then: !0,
|
|
7
|
-
is: !0,
|
|
8
|
-
and: !0,
|
|
9
|
-
or: !0,
|
|
10
|
-
if: !0,
|
|
11
|
-
default: !0
|
|
12
|
-
}, c = {
|
|
13
|
-
var_input: !0,
|
|
14
|
-
var_output: !0,
|
|
15
|
-
fuzzify: !0,
|
|
16
|
-
defuzzify: !0,
|
|
17
|
-
function_block: !0,
|
|
18
|
-
ruleblock: !0
|
|
19
|
-
}, o = {
|
|
20
|
-
end_ruleblock: !0,
|
|
21
|
-
end_defuzzify: !0,
|
|
22
|
-
end_function_block: !0,
|
|
23
|
-
end_fuzzify: !0,
|
|
24
|
-
end_var: !0
|
|
25
|
-
}, d = {
|
|
26
|
-
true: !0,
|
|
27
|
-
false: !0,
|
|
28
|
-
nan: !0,
|
|
29
|
-
real: !0,
|
|
30
|
-
min: !0,
|
|
31
|
-
max: !0,
|
|
32
|
-
cog: !0,
|
|
33
|
-
cogs: !0
|
|
34
|
-
}, i = /[+\-*&^%:=<>!|\/]/;
|
|
35
|
-
function a(t, e) {
|
|
36
|
-
var r = t.next();
|
|
37
|
-
if (/[\d\.]/.test(r))
|
|
38
|
-
return r == "." ? t.match(/^[0-9]+([eE][\-+]?[0-9]+)?/) : r == "0" ? t.match(/^[xX][0-9a-fA-F]+/) || t.match(/^0[0-7]+/) : t.match(/^[0-9]*\.?[0-9]*([eE][\-+]?[0-9]+)?/), "number";
|
|
39
|
-
if (r == "/" || r == "(") {
|
|
40
|
-
if (t.eat("*"))
|
|
41
|
-
return e.tokenize = l, l(t, e);
|
|
42
|
-
if (t.eat("/"))
|
|
43
|
-
return t.skipToEnd(), "comment";
|
|
44
|
-
}
|
|
45
|
-
if (i.test(r))
|
|
46
|
-
return t.eatWhile(i), "operator";
|
|
47
|
-
t.eatWhile(/[\w\$_\xa1-\uffff]/);
|
|
48
|
-
var n = t.current().toLowerCase();
|
|
49
|
-
return s.propertyIsEnumerable(n) || c.propertyIsEnumerable(n) || o.propertyIsEnumerable(n) ? "keyword" : d.propertyIsEnumerable(n) ? "atom" : "variable";
|
|
50
|
-
}
|
|
51
|
-
function l(t, e) {
|
|
52
|
-
for (var r = !1, n; n = t.next(); ) {
|
|
53
|
-
if ((n == "/" || n == ")") && r) {
|
|
54
|
-
e.tokenize = a;
|
|
55
|
-
break;
|
|
56
|
-
}
|
|
57
|
-
r = n == "*";
|
|
58
|
-
}
|
|
59
|
-
return "comment";
|
|
60
|
-
}
|
|
61
|
-
function f(t, e, r, n, u) {
|
|
62
|
-
this.indented = t, this.column = e, this.type = r, this.align = n, this.prev = u;
|
|
63
|
-
}
|
|
64
|
-
function m(t, e, r) {
|
|
65
|
-
return t.context = new f(t.indented, e, r, null, t.context);
|
|
66
|
-
}
|
|
67
|
-
function p(t) {
|
|
68
|
-
if (t.context.prev) {
|
|
69
|
-
var e = t.context.type;
|
|
70
|
-
return e == "end_block" && (t.indented = t.context.indented), t.context = t.context.prev;
|
|
71
|
-
}
|
|
72
|
-
}
|
|
73
|
-
const k = {
|
|
74
|
-
name: "fcl",
|
|
75
|
-
startState: function(t) {
|
|
76
|
-
return {
|
|
77
|
-
tokenize: null,
|
|
78
|
-
context: new f(-t, 0, "top", !1),
|
|
79
|
-
indented: 0,
|
|
80
|
-
startOfLine: !0
|
|
81
|
-
};
|
|
82
|
-
},
|
|
83
|
-
token: function(t, e) {
|
|
84
|
-
var r = e.context;
|
|
85
|
-
if (t.sol() && (r.align == null && (r.align = !1), e.indented = t.indentation(), e.startOfLine = !0), t.eatSpace()) return null;
|
|
86
|
-
var n = (e.tokenize || a)(t, e);
|
|
87
|
-
if (n == "comment") return n;
|
|
88
|
-
r.align == null && (r.align = !0);
|
|
89
|
-
var u = t.current().toLowerCase();
|
|
90
|
-
return c.propertyIsEnumerable(u) ? m(e, t.column(), "end_block") : o.propertyIsEnumerable(u) && p(e), e.startOfLine = !1, n;
|
|
91
|
-
},
|
|
92
|
-
indent: function(t, e, r) {
|
|
93
|
-
if (t.tokenize != a && t.tokenize != null) return 0;
|
|
94
|
-
var n = t.context, u = o.propertyIsEnumerable(e);
|
|
95
|
-
return n.align ? n.column + (u ? 0 : 1) : n.indented + (u ? 0 : r.unit);
|
|
96
|
-
},
|
|
97
|
-
languageData: {
|
|
98
|
-
commentTokens: { line: "//", block: { open: "(*", close: "*)" } }
|
|
99
|
-
}
|
|
100
|
-
};
|
|
101
|
-
export {
|
|
102
|
-
k as fcl
|
|
103
|
-
};
|