@aiao/code-editor-react 0.0.9 → 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.
Files changed (121) hide show
  1. package/dist/index.js +118 -2
  2. package/package.json +4 -4
  3. package/dist/apl-B2DGVGxc-Dd6D39pP.js +0 -76
  4. package/dist/asciiarmor-2LVJmxlE-CAn4gnoC.js +0 -34
  5. package/dist/asn1-jKiBa2Ya-xsKwdyq9.js +0 -95
  6. package/dist/asterisk-DS281yxp-B5eTWk_B.js +0 -271
  7. package/dist/brainfuck-C_p9pTT8-DKVQ9poL.js +0 -34
  8. package/dist/clike-BMALKCNj-Ck7Gc35_.js +0 -620
  9. package/dist/clojure-CCKyeQKf-N9sg777Z.js +0 -800
  10. package/dist/cmake-CuaCgAKt-BbEgXraO.js +0 -28
  11. package/dist/cobol-BlTKFDRj-CHCoWafp.js +0 -72
  12. package/dist/coffeescript-BVCvwO8I-Z15ai5ac.js +0 -179
  13. package/dist/commonlisp-D_kxz07b-Ce7sn14o.js +0 -75
  14. package/dist/crystal-D309uH6_-DS6LrXoE.js +0 -217
  15. package/dist/css-BkF-NPzE-DiJu9Nkd.js +0 -1553
  16. package/dist/cypher-BMq4Fwjl-Ml-omWgp.js +0 -68
  17. package/dist/d-BZcgY6La-KCW6-bIm.js +0 -127
  18. package/dist/diff-Cg9d_RX2-C01qBVFc.js +0 -18
  19. package/dist/dockerfile-DFX8bq9N-BIbYUQV0.js +0 -194
  20. package/dist/dtd-CtLokQ-U-DCbNdeIA.js +0 -84
  21. package/dist/dylan-QYeExnWK-DIUVpsct.js +0 -234
  22. package/dist/ebnf-DUPDuY4r-7HIXKmWn.js +0 -78
  23. package/dist/ecl-CiXN-g_D-DOI-W0if.js +0 -121
  24. package/dist/eiffel-yQhjl4T1-DIX8Ceq1.js +0 -110
  25. package/dist/elm-CNT9vbN0-BcYlydpO.js +0 -108
  26. package/dist/erlang-CFOYdy9e-DULXsFZl.js +0 -487
  27. package/dist/factor-Clf6BoVk-DBb2EHMF.js +0 -65
  28. package/dist/fcl-CPC2WYrI-CuXG3fcK.js +0 -103
  29. package/dist/forth-BmxRyE9S-BcFwWpeL.js +0 -60
  30. package/dist/fortran-9bvPyrOW-CuLcq-Iu.js +0 -442
  31. package/dist/gas-cpmYfFX2-sZgGhMxB.js +0 -183
  32. package/dist/gherkin-CJuwpceU-BRrr8yjO.js +0 -34
  33. package/dist/groovy-DZeT_VM--CmF8wcSo.js +0 -146
  34. package/dist/haskell-CxiO_7JL-BuULsXvv.js +0 -375
  35. package/dist/haxe-70NVW1pR-CM27SfgM.js +0 -359
  36. package/dist/http-D9LttvKF-j9E8oQ7o.js +0 -44
  37. package/dist/idl-B6TRFYjl-B6TRFYjl.js +0 -947
  38. package/dist/index-4oLq9F9B-CiG9J_wS.js +0 -944
  39. package/dist/index-9NH8hlZ--ZzqmPLCF.js +0 -342
  40. package/dist/index-BFXNCCbG-LloeVRnr.js +0 -253
  41. package/dist/index-BLHYcXXK-BxaAXMNw.js +0 -101
  42. package/dist/index-BQU3Rb2C-DeyQP3x_.js +0 -290
  43. package/dist/index-Bg18ePld-Di0FNEJ4.js +0 -157
  44. package/dist/index-Bp5lqnbN-BM2h2Xfi.js +0 -555
  45. package/dist/index-Bqzq8A1N-Dn1yj5KO.js +0 -59
  46. package/dist/index-Bx-s4g99-QIFA9lMK.js +0 -76
  47. package/dist/index-BxX25QmV-Cnf0cb51.js +0 -248
  48. package/dist/index-CFCzgc33-MPwtm3eY.js +0 -1917
  49. package/dist/index-CL7JTU9M-Bl8j0-fU.js +0 -136
  50. package/dist/index-CgClvcTI.js +0 -35617
  51. package/dist/index-CipmEceX-D1vXXSTd.js +0 -74
  52. package/dist/index-Cv4vvpa2-B8Ojlo_m.js +0 -1305
  53. package/dist/index-D4hhdPbZ-DXEZQFco.js +0 -6152
  54. package/dist/index-DhNQ8g9I-CjBYiskZ.js +0 -270
  55. package/dist/index-Djp53tAP-DnPgUG4S.js +0 -94
  56. package/dist/index-KlsAFhIj-Dzil0Vr8.js +0 -566
  57. package/dist/index-OntZqtu6-DPgaaGGJ.js +0 -305
  58. package/dist/index-PGnZjMCR-BPDty4q0.js +0 -301
  59. package/dist/index-TyYoYgss-BIjAZ6j1.js +0 -613
  60. package/dist/index-oMSPmlXA-CoPtKzNe.js +0 -960
  61. package/dist/index-rQC6Gbk0-BZ6M0IzM.js +0 -138
  62. package/dist/javascript-DOuB9oqA-BxiygWgm.js +0 -691
  63. package/dist/julia-DpvXAuO6-Bk_IfD8X.js +0 -241
  64. package/dist/livescript-CanGTf8u-Cx6PrvS4.js +0 -272
  65. package/dist/lua-XplVlWi_-8f8obHzY.js +0 -217
  66. package/dist/mathematica-jaRHnSxC-B83gQsL2.js +0 -35
  67. package/dist/mbox-BctzC1hL-Hg5U2B4l.js +0 -76
  68. package/dist/mirc-CFBPAOaF-CfzSSk9W.js +0 -72
  69. package/dist/mllike-BSnXJBGA-Ao1NpT2u.js +0 -272
  70. package/dist/modelica-vUgVs--1-BObVpYBg.js +0 -93
  71. package/dist/mscgen-Cpl0NYLN-DqNArLGH.js +0 -104
  72. package/dist/mumps-CQoS1kWX-CkTUOQnt.js +0 -25
  73. package/dist/nginx-zDPm3Z74-DJk4KP7N.js +0 -87
  74. package/dist/nsis-BCLyjY7m-C2MffOQ3.js +0 -62
  75. package/dist/ntriples-CsNjv2QF-C4aZn3EO.js +0 -79
  76. package/dist/octave-C8PmmSRH-DM5vTWlU.js +0 -143
  77. package/dist/oz-Ce8aN8oE-BcJM4SVy.js +0 -151
  78. package/dist/pascal-De0D6mP7-D7DGFFKL.js +0 -77
  79. package/dist/perl-B4bSCe1C-6aIa2glS.js +0 -915
  80. package/dist/pig-D24Z8EXi-BD-qt5FU.js +0 -54
  81. package/dist/powershell-DkYVfTzP-Blt1Rodi.js +0 -249
  82. package/dist/properties-Dn9wna3M-EOOwnCnk.js +0 -26
  83. package/dist/protobuf-BPIjwpzm-DAButU8_.js +0 -49
  84. package/dist/pug-TGXr6c5j-C9HfQ86E.js +0 -248
  85. package/dist/puppet-nyd4dhjf-CGzH5dsa.js +0 -45
  86. package/dist/python-BkR3uSy8-CjDnyp3B.js +0 -313
  87. package/dist/q-DyHZGnqm-DGuqeH_T.js +0 -86
  88. package/dist/r-LKEuhEGI-BFQhJnTP.js +0 -104
  89. package/dist/rpm-IznJm2Xc-CbZqrWCM.js +0 -57
  90. package/dist/ruby-CcYfvIk6-DzPSfSGo.js +0 -228
  91. package/dist/sas-7E8yHoCW-D726Uzkw.js +0 -105
  92. package/dist/scheme-DjibxsNh-Bp5gVFkm.js +0 -124
  93. package/dist/shell-C0C2sNA_-BTeYg6ir.js +0 -182
  94. package/dist/sieve-Bwz7vjP5-Cw8iTBf7.js +0 -72
  95. package/dist/simple-mode-mNVtnu0l-BC8mf7KF.js +0 -89
  96. package/dist/smalltalk-Bhddl2pB-B7URiJSp.js +0 -48
  97. package/dist/solr-BNlsLglM-BM2OpfTI.js +0 -41
  98. package/dist/sparql-FarWu_Gb-FN_uQNd4.js +0 -197
  99. package/dist/spreadsheet-C-cy4P5N-5CSTwVYq.js +0 -49
  100. package/dist/sql-CfG5lQ3l-Bd4dgm_8.js +0 -278
  101. package/dist/stex-Du4h4KAU-QOov_zHj.js +0 -129
  102. package/dist/stylus-CAdqWld3-BcRBbBxD.js +0 -250
  103. package/dist/swift-DSxqR9R6-2Hz4NOoF.js +0 -230
  104. package/dist/tcl-xfoLljhY-DAZBRGQI.js +0 -81
  105. package/dist/textile-D1AWE-pc-DuiIfEnb.js +0 -295
  106. package/dist/tiddlywiki-5wqsXtSk-WuF_8VUv.js +0 -155
  107. package/dist/tiki-__Kn3CeS-CWcR9ib_.js +0 -181
  108. package/dist/toml-DWAmxCjl-CyJoDzs6.js +0 -56
  109. package/dist/troff-D2UO-fKf-DVoIzS-O.js +0 -35
  110. package/dist/ttcn-Bsa4sfRm-hoy08sYQ.js +0 -123
  111. package/dist/ttcn-cfg-Bac_acMi-DaC4kQpd.js +0 -88
  112. package/dist/turtle-xwJUxoPV-fs94wdNM.js +0 -80
  113. package/dist/vb-c2kQGd6--DU726qF0.js +0 -74
  114. package/dist/vbscript-1f_Dhg5H-DriA32xD.js +0 -324
  115. package/dist/velocity-DJd0pTTC-BG368IR6.js +0 -96
  116. package/dist/verilog-CiS1jyi5-giQA8J-e.js +0 -259
  117. package/dist/vhdl-T9HkrbI2-BJ8LEDog.js +0 -106
  118. package/dist/webidl-CjfDENEo-BM8KXKJ5.js +0 -155
  119. package/dist/xquery-Ct6lEb4B-C5KDc61l.js +0 -422
  120. package/dist/yacas-C0absKBh-B82QJ76F.js +0 -73
  121. package/dist/z80-Pki2zAjW-B0IQoIbR.js +0 -61
@@ -1,72 +0,0 @@
1
- function a(t) {
2
- for (var e = {}, n = t.split(" "), r = 0; r < n.length; ++r) e[n[r]] = !0;
3
- return e;
4
- }
5
- var l = a("if elsif else stop require"), s = a("true false not");
6
- function i(t, e) {
7
- var n = t.next();
8
- if (n == "/" && t.eat("*"))
9
- return e.tokenize = o, o(t, e);
10
- if (n === "#")
11
- return t.skipToEnd(), "comment";
12
- if (n == '"')
13
- return e.tokenize = p(n), e.tokenize(t, e);
14
- if (n == "(")
15
- return e._indent.push("("), e._indent.push("{"), null;
16
- if (n === "{")
17
- return e._indent.push("{"), null;
18
- if (n == ")" && (e._indent.pop(), e._indent.pop()), n === "}")
19
- return e._indent.pop(), null;
20
- if (n == "," || n == ";" || /[{}\(\),;]/.test(n))
21
- return null;
22
- if (/\d/.test(n))
23
- return t.eatWhile(/[\d]/), t.eat(/[KkMmGg]/), "number";
24
- if (n == ":")
25
- return t.eatWhile(/[a-zA-Z_]/), t.eatWhile(/[a-zA-Z0-9_]/), "operator";
26
- t.eatWhile(/\w/);
27
- var r = t.current();
28
- return r == "text" && t.eat(":") ? (e.tokenize = f, "string") : l.propertyIsEnumerable(r) ? "keyword" : s.propertyIsEnumerable(r) ? "atom" : null;
29
- }
30
- function f(t, e) {
31
- return e._multiLineString = !0, t.sol() ? (t.next() == "." && t.eol() && (e._multiLineString = !1, e.tokenize = i), "string") : (t.eatSpace(), t.peek() == "#" ? (t.skipToEnd(), "comment") : (t.skipToEnd(), "string"));
32
- }
33
- function o(t, e) {
34
- for (var n = !1, r; (r = t.next()) != null; ) {
35
- if (n && r == "/") {
36
- e.tokenize = i;
37
- break;
38
- }
39
- n = r == "*";
40
- }
41
- return "comment";
42
- }
43
- function p(t) {
44
- return function(e, n) {
45
- for (var r = !1, u; (u = e.next()) != null && !(u == t && !r); )
46
- r = !r && u == "\\";
47
- return r || (n.tokenize = i), "string";
48
- };
49
- }
50
- const d = {
51
- name: "sieve",
52
- startState: function(t) {
53
- return {
54
- tokenize: i,
55
- baseIndent: t || 0,
56
- _indent: []
57
- };
58
- },
59
- token: function(t, e) {
60
- return t.eatSpace() ? null : (e.tokenize || i)(t, e);
61
- },
62
- indent: function(t, e, n) {
63
- var r = t._indent.length;
64
- return e && e[0] == "}" && r--, r < 0 && (r = 0), r * n.unit;
65
- },
66
- languageData: {
67
- indentOnInput: /^\s*\}$/
68
- }
69
- };
70
- export {
71
- d as sieve
72
- };
@@ -1,89 +0,0 @@
1
- function x(t) {
2
- g(t, "start");
3
- var e = {}, n = t.languageData || {}, d = !1;
4
- for (var u in t) if (u != n && t.hasOwnProperty(u))
5
- for (var o = e[u] = [], r = t[u], a = 0; a < r.length; a++) {
6
- var i = r[a];
7
- o.push(new h(i, t)), (i.indent || i.dedent) && (d = !0);
8
- }
9
- return {
10
- name: n.name,
11
- startState: function() {
12
- return { state: "start", pending: null, indent: d ? [] : null };
13
- },
14
- copyState: function(s) {
15
- var l = { state: s.state, pending: s.pending, indent: s.indent && s.indent.slice(0) };
16
- return s.stack && (l.stack = s.stack.slice(0)), l;
17
- },
18
- token: f(e),
19
- indent: k(e, n),
20
- mergeTokens: n.mergeTokens,
21
- languageData: n
22
- };
23
- }
24
- function g(t, e) {
25
- if (!t.hasOwnProperty(e))
26
- throw new Error("Undefined state " + e + " in simple mode");
27
- }
28
- function p(t, e) {
29
- if (!t) return /(?:)/;
30
- var n = "";
31
- return t instanceof RegExp ? (t.ignoreCase && (n = "i"), t.unicode && (n += "u"), t = t.source) : t = String(t), new RegExp("^(?:" + t + ")", n);
32
- }
33
- function c(t) {
34
- if (!t) return null;
35
- if (t.apply) return t;
36
- if (typeof t == "string") return t.replace(/\./g, " ");
37
- for (var e = [], n = 0; n < t.length; n++)
38
- e.push(t[n] && t[n].replace(/\./g, " "));
39
- return e;
40
- }
41
- function h(t, e) {
42
- (t.next || t.push) && g(e, t.next || t.push), this.regex = p(t.regex), this.token = c(t.token), this.data = t;
43
- }
44
- function f(t) {
45
- return function(e, n) {
46
- if (n.pending) {
47
- var d = n.pending.shift();
48
- return n.pending.length == 0 && (n.pending = null), e.pos += d.text.length, d.token;
49
- }
50
- for (var u = t[n.state], o = 0; o < u.length; o++) {
51
- var r = u[o], a = (!r.data.sol || e.sol()) && e.match(r.regex);
52
- if (a) {
53
- r.data.next ? n.state = r.data.next : r.data.push ? ((n.stack || (n.stack = [])).push(n.state), n.state = r.data.push) : r.data.pop && n.stack && n.stack.length && (n.state = n.stack.pop()), r.data.indent && n.indent.push(e.indentation() + e.indentUnit), r.data.dedent && n.indent.pop();
54
- var i = r.token;
55
- if (i && i.apply && (i = i(a)), a.length > 2 && r.token && typeof r.token != "string") {
56
- n.pending = [];
57
- for (var s = 2; s < a.length; s++)
58
- a[s] && n.pending.push({ text: a[s], token: r.token[s - 1] });
59
- return e.backUp(a[0].length - (a[1] ? a[1].length : 0)), i[0];
60
- } else return i && i.join ? i[0] : i;
61
- }
62
- }
63
- return e.next(), null;
64
- };
65
- }
66
- function k(t, e) {
67
- return function(n, d) {
68
- if (n.indent == null || e.dontIndentStates && e.dontIndentStates.indexOf(n.state) > -1)
69
- return null;
70
- var u = n.indent.length - 1, o = t[n.state];
71
- t: for (; ; ) {
72
- for (var r = 0; r < o.length; r++) {
73
- var a = o[r];
74
- if (a.data.dedent && a.data.dedentIfLineStart !== !1) {
75
- var i = a.regex.exec(d);
76
- if (i && i[0]) {
77
- u--, (a.next || a.push) && (o = t[a.next || a.push]), d = d.slice(i[0].length);
78
- continue t;
79
- }
80
- }
81
- }
82
- break;
83
- }
84
- return u < 0 ? 0 : n.indent[u];
85
- };
86
- }
87
- export {
88
- x as k
89
- };
@@ -1,48 +0,0 @@
1
- var o = /[+\-\/\\*~<>=@%|&?!.,:;^]/, p = /true|false|nil|self|super|thisContext/, r = function(t, e) {
2
- this.next = t, this.parent = e;
3
- }, s = function(t, e, n) {
4
- this.name = t, this.context = e, this.eos = n;
5
- }, x = function() {
6
- this.context = new r(h, null), this.expectVariable = !0, this.indentation = 0, this.userIndentationDelta = 0;
7
- };
8
- x.prototype.userIndent = function(t, e) {
9
- this.userIndentationDelta = t > 0 ? t / e - this.indentation : 0;
10
- };
11
- var h = function(t, e, n) {
12
- var a = new s(null, e, !1), i = t.next();
13
- return i === '"' ? a = l(t, new r(l, e)) : i === "'" ? a = u(t, new r(u, e)) : i === "#" ? t.peek() === "'" ? (t.next(), a = c(t, new r(c, e))) : t.eatWhile(/[^\s.{}\[\]()]/) ? a.name = "string.special" : a.name = "meta" : i === "$" ? (t.next() === "<" && (t.eatWhile(/[^\s>]/), t.next()), a.name = "string.special") : i === "|" && n.expectVariable ? a.context = new r(d, e) : /[\[\]{}()]/.test(i) ? (a.name = "bracket", a.eos = /[\[{(]/.test(i), i === "[" ? n.indentation++ : i === "]" && (n.indentation = Math.max(0, n.indentation - 1))) : o.test(i) ? (t.eatWhile(o), a.name = "operator", a.eos = i !== ";") : /\d/.test(i) ? (t.eatWhile(/[\w\d]/), a.name = "number") : /[\w_]/.test(i) ? (t.eatWhile(/[\w\d_]/), a.name = n.expectVariable ? p.test(t.current()) ? "keyword" : "variable" : null) : a.eos = n.expectVariable, a;
14
- }, l = function(t, e) {
15
- return t.eatWhile(/[^"]/), new s("comment", t.eat('"') ? e.parent : e, !0);
16
- }, u = function(t, e) {
17
- return t.eatWhile(/[^']/), new s("string", t.eat("'") ? e.parent : e, !1);
18
- }, c = function(t, e) {
19
- return t.eatWhile(/[^']/), new s("string.special", t.eat("'") ? e.parent : e, !1);
20
- }, d = function(t, e) {
21
- var n = new s(null, e, !1), a = t.next();
22
- return a === "|" ? (n.context = e.parent, n.eos = !0) : (t.eatWhile(/[^|]/), n.name = "variable"), n;
23
- };
24
- const f = {
25
- name: "smalltalk",
26
- startState: function() {
27
- return new x();
28
- },
29
- token: function(t, e) {
30
- if (e.userIndent(t.indentation(), t.indentUnit), t.eatSpace())
31
- return null;
32
- var n = e.context.next(t, e.context, e);
33
- return e.context = n.context, e.expectVariable = n.eos, n.name;
34
- },
35
- blankLine: function(t, e) {
36
- t.userIndent(0, e);
37
- },
38
- indent: function(t, e, n) {
39
- var a = t.context.next === h && e && e.charAt(0) === "]" ? -1 : t.userIndentationDelta;
40
- return (t.indentation + a) * n.unit;
41
- },
42
- languageData: {
43
- indentOnInput: /^\s*\]$/
44
- }
45
- };
46
- export {
47
- f as smalltalk
48
- };
@@ -1,41 +0,0 @@
1
- var i = /[^\s\|\!\+\-\*\?\~\^\&\:\(\)\[\]\{\}\"\\]/, a = /[\|\!\+\-\*\?\~\^\&]/, c = /^(OR|AND|NOT|TO)$/;
2
- function f(n) {
3
- return parseFloat(n).toString() === n;
4
- }
5
- function k(n) {
6
- return function(t, e) {
7
- for (var r = !1, u; (u = t.next()) != null && !(u == n && !r); )
8
- r = !r && u == "\\";
9
- return r || (e.tokenize = o), "string";
10
- };
11
- }
12
- function s(n) {
13
- return function(t, e) {
14
- return n == "|" ? t.eat(/\|/) : n == "&" && t.eat(/\&/), e.tokenize = o, "operator";
15
- };
16
- }
17
- function l(n) {
18
- return function(t, e) {
19
- for (var r = n; (n = t.peek()) && n.match(i) != null; )
20
- r += t.next();
21
- return e.tokenize = o, c.test(r) ? "operator" : f(r) ? "number" : t.peek() == ":" ? "propertyName" : "string";
22
- };
23
- }
24
- function o(n, t) {
25
- var e = n.next();
26
- return e == '"' ? t.tokenize = k(e) : a.test(e) ? t.tokenize = s(e) : i.test(e) && (t.tokenize = l(e)), t.tokenize != o ? t.tokenize(n, t) : null;
27
- }
28
- const p = {
29
- name: "solr",
30
- startState: function() {
31
- return {
32
- tokenize: o
33
- };
34
- },
35
- token: function(n, t) {
36
- return n.eatSpace() ? null : t.tokenize(n, t);
37
- }
38
- };
39
- export {
40
- p as solr
41
- };
@@ -1,197 +0,0 @@
1
- var u;
2
- function f(e) {
3
- return new RegExp("^(?:" + e.join("|") + ")$", "i");
4
- }
5
- var p = f([
6
- "str",
7
- "lang",
8
- "langmatches",
9
- "datatype",
10
- "bound",
11
- "sameterm",
12
- "isiri",
13
- "isuri",
14
- "iri",
15
- "uri",
16
- "bnode",
17
- "count",
18
- "sum",
19
- "min",
20
- "max",
21
- "avg",
22
- "sample",
23
- "group_concat",
24
- "rand",
25
- "abs",
26
- "ceil",
27
- "floor",
28
- "round",
29
- "concat",
30
- "substr",
31
- "strlen",
32
- "replace",
33
- "ucase",
34
- "lcase",
35
- "encode_for_uri",
36
- "contains",
37
- "strstarts",
38
- "strends",
39
- "strbefore",
40
- "strafter",
41
- "year",
42
- "month",
43
- "day",
44
- "hours",
45
- "minutes",
46
- "seconds",
47
- "timezone",
48
- "tz",
49
- "now",
50
- "uuid",
51
- "struuid",
52
- "md5",
53
- "sha1",
54
- "sha256",
55
- "sha384",
56
- "sha512",
57
- "coalesce",
58
- "if",
59
- "strlang",
60
- "strdt",
61
- "isnumeric",
62
- "regex",
63
- "exists",
64
- "isblank",
65
- "isliteral",
66
- "a",
67
- "bind"
68
- ]), m = f([
69
- "base",
70
- "prefix",
71
- "select",
72
- "distinct",
73
- "reduced",
74
- "construct",
75
- "describe",
76
- "ask",
77
- "from",
78
- "named",
79
- "where",
80
- "order",
81
- "limit",
82
- "offset",
83
- "filter",
84
- "optional",
85
- "graph",
86
- "by",
87
- "asc",
88
- "desc",
89
- "as",
90
- "having",
91
- "undef",
92
- "values",
93
- "group",
94
- "minus",
95
- "in",
96
- "not",
97
- "service",
98
- "silent",
99
- "using",
100
- "insert",
101
- "delete",
102
- "union",
103
- "true",
104
- "false",
105
- "with",
106
- "data",
107
- "copy",
108
- "to",
109
- "move",
110
- "add",
111
- "create",
112
- "drop",
113
- "clear",
114
- "load",
115
- "into"
116
- ]), F = /[*+\-<>=&|\^\/!\?]/, s = "[A-Za-z_\\-0-9]", x = new RegExp("[A-Za-z]"), g = new RegExp("((" + s + "|\\.)*(" + s + "))?:");
117
- function d(e, t) {
118
- var n = e.next();
119
- if (u = null, n == "$" || n == "?")
120
- return n == "?" && e.match(/\s/, !1) ? "operator" : (e.match(/^[A-Za-z0-9_\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][A-Za-z0-9_\u00B7\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u037D\u037F-\u1FFF\u200C-\u200D\u203F-\u2040\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]*/), "variableName.local");
121
- if (n == "<" && !e.match(/^[\s\u00a0=]/, !1))
122
- return e.match(/^[^\s\u00a0>]*>?/), "atom";
123
- if (n == '"' || n == "'")
124
- return t.tokenize = h(n), t.tokenize(e, t);
125
- if (/[{}\(\),\.;\[\]]/.test(n))
126
- return u = n, "bracket";
127
- if (n == "#")
128
- return e.skipToEnd(), "comment";
129
- if (F.test(n))
130
- return "operator";
131
- if (n == ":")
132
- return l(e), "atom";
133
- if (n == "@")
134
- return e.eatWhile(/[a-z\d\-]/i), "meta";
135
- if (x.test(n) && e.match(g))
136
- return l(e), "atom";
137
- e.eatWhile(/[_\w\d]/);
138
- var a = e.current();
139
- return p.test(a) ? "builtin" : m.test(a) ? "keyword" : "variable";
140
- }
141
- function l(e) {
142
- e.match(/(\.(?=[\w_\-\\%])|[:\w_-]|\\[-\\_~.!$&'()*+,;=/?#@%]|%[a-f\d][a-f\d])+/i);
143
- }
144
- function h(e) {
145
- return function(t, n) {
146
- for (var a = !1, r; (r = t.next()) != null; ) {
147
- if (r == e && !a) {
148
- n.tokenize = d;
149
- break;
150
- }
151
- a = !a && r == "\\";
152
- }
153
- return "string";
154
- };
155
- }
156
- function o(e, t, n) {
157
- e.context = { prev: e.context, indent: e.indent, col: n, type: t };
158
- }
159
- function i(e) {
160
- e.indent = e.context.indent, e.context = e.context.prev;
161
- }
162
- const v = {
163
- name: "sparql",
164
- startState: function() {
165
- return {
166
- tokenize: d,
167
- context: null,
168
- indent: 0,
169
- col: 0
170
- };
171
- },
172
- token: function(e, t) {
173
- if (e.sol() && (t.context && t.context.align == null && (t.context.align = !1), t.indent = e.indentation()), e.eatSpace()) return null;
174
- var n = t.tokenize(e, t);
175
- if (n != "comment" && t.context && t.context.align == null && t.context.type != "pattern" && (t.context.align = !0), u == "(") o(t, ")", e.column());
176
- else if (u == "[") o(t, "]", e.column());
177
- else if (u == "{") o(t, "}", e.column());
178
- else if (/[\]\}\)]/.test(u)) {
179
- for (; t.context && t.context.type == "pattern"; ) i(t);
180
- t.context && u == t.context.type && (i(t), u == "}" && t.context && t.context.type == "pattern" && i(t));
181
- } else u == "." && t.context && t.context.type == "pattern" ? i(t) : /atom|string|variable/.test(n) && t.context && (/[\}\]]/.test(t.context.type) ? o(t, "pattern", e.column()) : t.context.type == "pattern" && !t.context.align && (t.context.align = !0, t.context.col = e.column()));
182
- return n;
183
- },
184
- indent: function(e, t, n) {
185
- var a = t && t.charAt(0), r = e.context;
186
- if (/[\]\}]/.test(a))
187
- for (; r && r.type == "pattern"; ) r = r.prev;
188
- var c = r && a == r.type;
189
- return r ? r.type == "pattern" ? r.col : r.align ? r.col + (c ? 0 : 1) : r.indent + (c ? 0 : n.unit) : 0;
190
- },
191
- languageData: {
192
- commentTokens: { line: "#" }
193
- }
194
- };
195
- export {
196
- v as sparql
197
- };
@@ -1,49 +0,0 @@
1
- const e = {
2
- name: "spreadsheet",
3
- startState: function() {
4
- return {
5
- stringType: null,
6
- stack: []
7
- };
8
- },
9
- token: function(t, a) {
10
- if (t) {
11
- switch (a.stack.length === 0 && (t.peek() == '"' || t.peek() == "'") && (a.stringType = t.peek(), t.next(), a.stack.unshift("string")), a.stack[0]) {
12
- case "string":
13
- for (; a.stack[0] === "string" && !t.eol(); )
14
- t.peek() === a.stringType ? (t.next(), a.stack.shift()) : t.peek() === "\\" ? (t.next(), t.next()) : t.match(/^.[^\\\"\']*/);
15
- return "string";
16
- case "characterClass":
17
- for (; a.stack[0] === "characterClass" && !t.eol(); )
18
- t.match(/^[^\]\\]+/) || t.match(/^\\./) || a.stack.shift();
19
- return "operator";
20
- }
21
- var s = t.peek();
22
- switch (s) {
23
- case "[":
24
- return t.next(), a.stack.unshift("characterClass"), "bracket";
25
- case ":":
26
- return t.next(), "operator";
27
- case "\\":
28
- return t.match(/\\[a-z]+/) ? "string.special" : (t.next(), "atom");
29
- case ".":
30
- case ",":
31
- case ";":
32
- case "*":
33
- case "-":
34
- case "+":
35
- case "^":
36
- case "<":
37
- case "/":
38
- case "=":
39
- return t.next(), "atom";
40
- case "$":
41
- return t.next(), "builtin";
42
- }
43
- return t.match(/\d+/) ? t.match(/^\w+/) ? "error" : "number" : t.match(/^[a-zA-Z_]\w*/) ? t.match(/(?=[\(.])/, !1) ? "keyword" : "variable" : ["[", "]", "(", ")", "{", "}"].indexOf(s) != -1 ? (t.next(), "bracket") : (t.eatSpace() || t.next(), null);
44
- }
45
- }
46
- };
47
- export {
48
- e as spreadsheet
49
- };