react-schema-form 1.0.5 → 1.0.7

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/react-schema-form.css +1 -0
  2. package/dist/react-schema-form.js +24552 -5
  3. package/dist/react-schema-form.js.map +1 -0
  4. package/dist/react-schema-form.umd.cjs +76 -168
  5. package/dist/react-schema-form.umd.cjs.map +1 -0
  6. package/package.json +32 -10
  7. package/dist/apl-B2DGVGxc.js +0 -76
  8. package/dist/asciiarmor-2LVJmxlE.js +0 -34
  9. package/dist/asn1-DF4fnRHj.js +0 -93
  10. package/dist/asterisk-DS281yxp.js +0 -271
  11. package/dist/brainfuck-C_p9pTT8.js +0 -34
  12. package/dist/clike-l4mx49Q1.js +0 -621
  13. package/dist/clojure-CCKyeQKf.js +0 -800
  14. package/dist/cmake-CuaCgAKt.js +0 -28
  15. package/dist/cobol-CJVkMW0i.js +0 -73
  16. package/dist/coffeescript-BVCvwO8I.js +0 -179
  17. package/dist/commonlisp-D_kxz07b.js +0 -75
  18. package/dist/crystal-D309uH6_.js +0 -217
  19. package/dist/css-bIlmDBTK.js +0 -1560
  20. package/dist/cypher-BMq4Fwjl.js +0 -68
  21. package/dist/d-BZcgY6La.js +0 -127
  22. package/dist/diff-Cg9d_RX2.js +0 -18
  23. package/dist/dockerfile-CFG_IPGn.js +0 -194
  24. package/dist/dtd-CtLokQ-U.js +0 -84
  25. package/dist/dylan-QYeExnWK.js +0 -234
  26. package/dist/ebnf-Xa2PN7SI.js +0 -77
  27. package/dist/ecl-CiXN-g_D.js +0 -121
  28. package/dist/eiffel-yQhjl4T1.js +0 -110
  29. package/dist/elm-CNT9vbN0.js +0 -108
  30. package/dist/erlang-CFOYdy9e.js +0 -487
  31. package/dist/factor-DJHfQ4a1.js +0 -65
  32. package/dist/fcl-CPC2WYrI.js +0 -103
  33. package/dist/forth-BmxRyE9S.js +0 -60
  34. package/dist/fortran-9bvPyrOW.js +0 -442
  35. package/dist/gas-BdfkXJT_.js +0 -183
  36. package/dist/gherkin-CJuwpceU.js +0 -34
  37. package/dist/groovy-DZeT_VM-.js +0 -146
  38. package/dist/haskell-Bvt3Qq1t.js +0 -375
  39. package/dist/haxe-pdDS1aE8.js +0 -359
  40. package/dist/http-D9LttvKF.js +0 -44
  41. package/dist/idl-B6TRFYjl.js +0 -947
  42. package/dist/index-BE87KcZQ.js +0 -98
  43. package/dist/index-BLB2mjTh.js +0 -312
  44. package/dist/index-Bar6lBni.js +0 -75
  45. package/dist/index-BzGQIlo_.js +0 -134
  46. package/dist/index-BzqHMC7H.js +0 -58
  47. package/dist/index-C1_9PR5w.js +0 -156
  48. package/dist/index-C8EGvqpJ.js +0 -135
  49. package/dist/index-CFDpG1dM.js +0 -243
  50. package/dist/index-Cjv9KcfW.js +0 -93
  51. package/dist/index-CvvBPxcf.js +0 -341
  52. package/dist/index-DDn1Bvsm.js +0 -538
  53. package/dist/index-DeMNkpAe.js +0 -299
  54. package/dist/index-DjyHTjks.js +0 -265
  55. package/dist/index-JL0W82NW.js +0 -598
  56. package/dist/index-RrAWWB2k.js +0 -71
  57. package/dist/index-kp5oFDKj.js +0 -288
  58. package/dist/javascript-CWGekh08.js +0 -690
  59. package/dist/jinja2-DnB6dQmV.js +0 -154
  60. package/dist/julia-DpvXAuO6.js +0 -241
  61. package/dist/livescript-CE_BxZmN.js +0 -272
  62. package/dist/lua-XplVlWi_.js +0 -217
  63. package/dist/main-gT5TlPcm.js +0 -85834
  64. package/dist/mathematica-jaRHnSxC.js +0 -35
  65. package/dist/mbox-BctzC1hL.js +0 -76
  66. package/dist/mirc-CFBPAOaF.js +0 -72
  67. package/dist/mllike-1yy7Y7jE.js +0 -275
  68. package/dist/modelica-vUgVs--1.js +0 -93
  69. package/dist/mscgen-Cpl0NYLN.js +0 -104
  70. package/dist/mumps-CQoS1kWX.js +0 -25
  71. package/dist/nginx-zDPm3Z74.js +0 -89
  72. package/dist/nsis-BtA0qkjU.js +0 -62
  73. package/dist/ntriples-CsNjv2QF.js +0 -79
  74. package/dist/octave-C8PmmSRH.js +0 -143
  75. package/dist/oz-Ce8aN8oE.js +0 -151
  76. package/dist/pascal-ixanSKUz.js +0 -77
  77. package/dist/perl-B4bSCe1C.js +0 -915
  78. package/dist/pig-D24Z8EXi.js +0 -54
  79. package/dist/powershell-DkYVfTzP.js +0 -249
  80. package/dist/properties-Dn9wna3M.js +0 -26
  81. package/dist/protobuf-BPIjwpzm.js +0 -49
  82. package/dist/pug-CW1q1xhQ.js +0 -248
  83. package/dist/puppet-nyd4dhjf.js +0 -45
  84. package/dist/python-B5QdSKoL.js +0 -313
  85. package/dist/q-DXjKs-tC.js +0 -83
  86. package/dist/r-Bz1d3XP0.js +0 -104
  87. package/dist/rpm-IznJm2Xc.js +0 -57
  88. package/dist/ruby-CcYfvIk6.js +0 -228
  89. package/dist/sas-7E8yHoCW.js +0 -105
  90. package/dist/scheme-DjibxsNh.js +0 -124
  91. package/dist/shell-C0C2sNA_.js +0 -182
  92. package/dist/sieve-Bwz7vjP5.js +0 -72
  93. package/dist/simple-mode-HGTvdazT.js +0 -88
  94. package/dist/smalltalk-Bhddl2pB.js +0 -48
  95. package/dist/solr-BNlsLglM.js +0 -41
  96. package/dist/sparql-FarWu_Gb.js +0 -197
  97. package/dist/spreadsheet-C-cy4P5N.js +0 -49
  98. package/dist/sql-uoWIYwDX.js +0 -284
  99. package/dist/stex-92raWT1r.js +0 -129
  100. package/dist/style.css +0 -1
  101. package/dist/stylus-DRcbY16X.js +0 -250
  102. package/dist/swift-DSxqR9R6.js +0 -230
  103. package/dist/tcl-xfoLljhY.js +0 -81
  104. package/dist/textile-D1AWE-pc.js +0 -295
  105. package/dist/tiddlywiki-5wqsXtSk.js +0 -155
  106. package/dist/tiki-D9z-T0ea.js +0 -178
  107. package/dist/toml-BHiuTcfn.js +0 -49
  108. package/dist/troff-D2UO-fKf.js +0 -35
  109. package/dist/ttcn-DmjTzZb6.js +0 -125
  110. package/dist/ttcn-cfg-B2U3U7dn.js +0 -90
  111. package/dist/turtle-xwJUxoPV.js +0 -80
  112. package/dist/vb-c2kQGd6-.js +0 -74
  113. package/dist/vbscript-Dz1TtKsy.js +0 -324
  114. package/dist/velocity-DJd0pTTC.js +0 -96
  115. package/dist/verilog-C4VGD9n1.js +0 -263
  116. package/dist/vhdl-T9HkrbI2.js +0 -106
  117. package/dist/vite.svg +0 -1
  118. package/dist/webidl-CjfDENEo.js +0 -155
  119. package/dist/xquery-xQxle02u.js +0 -426
  120. package/dist/yacas-C0absKBh.js +0 -73
  121. package/dist/z80-C8rPtw-0.js +0 -61
@@ -1,68 +0,0 @@
1
- var l = function(n) {
2
- return new RegExp("^(?:" + n.join("|") + ")$", "i");
3
- }, p = function(n) {
4
- i = null;
5
- var e = n.next();
6
- if (e === '"')
7
- return n.match(/^.*?"/), "string";
8
- if (e === "'")
9
- return n.match(/^.*?'/), "string";
10
- if (/[{}\(\),\.;\[\]]/.test(e))
11
- return i = e, "punctuation";
12
- if (e === "/" && n.eat("/"))
13
- return n.skipToEnd(), "comment";
14
- if (u.test(e))
15
- return n.eatWhile(u), null;
16
- if (n.eatWhile(/[_\w\d]/), n.eat(":"))
17
- return n.eatWhile(/[\w\d_\-]/), "atom";
18
- var t = n.current();
19
- return d.test(t) ? "builtin" : f.test(t) ? "def" : h.test(t) || x.test(t) ? "keyword" : "variable";
20
- }, o = function(n, e, t) {
21
- return n.context = {
22
- prev: n.context,
23
- indent: n.indent,
24
- col: t,
25
- type: e
26
- };
27
- }, c = function(n) {
28
- return n.indent = n.context.indent, n.context = n.context.prev;
29
- }, i, d = l(["abs", "acos", "allShortestPaths", "asin", "atan", "atan2", "avg", "ceil", "coalesce", "collect", "cos", "cot", "count", "degrees", "e", "endnode", "exp", "extract", "filter", "floor", "haversin", "head", "id", "keys", "labels", "last", "left", "length", "log", "log10", "lower", "ltrim", "max", "min", "node", "nodes", "percentileCont", "percentileDisc", "pi", "radians", "rand", "range", "reduce", "rel", "relationship", "relationships", "replace", "reverse", "right", "round", "rtrim", "shortestPath", "sign", "sin", "size", "split", "sqrt", "startnode", "stdev", "stdevp", "str", "substring", "sum", "tail", "tan", "timestamp", "toFloat", "toInt", "toString", "trim", "type", "upper"]), f = l(["all", "and", "any", "contains", "exists", "has", "in", "none", "not", "or", "single", "xor"]), h = l(["as", "asc", "ascending", "assert", "by", "case", "commit", "constraint", "create", "csv", "cypher", "delete", "desc", "descending", "detach", "distinct", "drop", "else", "end", "ends", "explain", "false", "fieldterminator", "foreach", "from", "headers", "in", "index", "is", "join", "limit", "load", "match", "merge", "null", "on", "optional", "order", "periodic", "profile", "remove", "return", "scan", "set", "skip", "start", "starts", "then", "true", "union", "unique", "unwind", "using", "when", "where", "with", "call", "yield"]), x = l(["access", "active", "assign", "all", "alter", "as", "catalog", "change", "copy", "create", "constraint", "constraints", "current", "database", "databases", "dbms", "default", "deny", "drop", "element", "elements", "exists", "from", "grant", "graph", "graphs", "if", "index", "indexes", "label", "labels", "management", "match", "name", "names", "new", "node", "nodes", "not", "of", "on", "or", "password", "populated", "privileges", "property", "read", "relationship", "relationships", "remove", "replace", "required", "revoke", "role", "roles", "set", "show", "start", "status", "stop", "suspended", "to", "traverse", "type", "types", "user", "users", "with", "write"]), u = /[*+\-<>=&|~%^]/;
30
- const g = {
31
- name: "cypher",
32
- startState: function() {
33
- return {
34
- tokenize: p,
35
- context: null,
36
- indent: 0,
37
- col: 0
38
- };
39
- },
40
- token: function(n, e) {
41
- if (n.sol() && (e.context && e.context.align == null && (e.context.align = !1), e.indent = n.indentation()), n.eatSpace())
42
- return null;
43
- var t = e.tokenize(n, e);
44
- if (t !== "comment" && e.context && e.context.align == null && e.context.type !== "pattern" && (e.context.align = !0), i === "(")
45
- o(e, ")", n.column());
46
- else if (i === "[")
47
- o(e, "]", n.column());
48
- else if (i === "{")
49
- o(e, "}", n.column());
50
- else if (/[\]\}\)]/.test(i)) {
51
- for (; e.context && e.context.type === "pattern"; )
52
- c(e);
53
- e.context && i === e.context.type && c(e);
54
- } else i === "." && e.context && e.context.type === "pattern" ? c(e) : /atom|string|variable/.test(t) && e.context && (/[\}\]]/.test(e.context.type) ? o(e, "pattern", n.column()) : e.context.type === "pattern" && !e.context.align && (e.context.align = !0, e.context.col = n.column()));
55
- return t;
56
- },
57
- indent: function(n, e, t) {
58
- var a = e && e.charAt(0), r = n.context;
59
- if (/[\]\}]/.test(a))
60
- for (; r && r.type === "pattern"; )
61
- r = r.prev;
62
- var s = r && a === r.type;
63
- return r ? r.type === "keywords" ? null : r.align ? r.col + (s ? 0 : 1) : r.indent + (s ? 0 : t.unit) : 0;
64
- }
65
- };
66
- export {
67
- g as cypher
68
- };
@@ -1,127 +0,0 @@
1
- function c(e) {
2
- for (var n = {}, t = e.split(" "), i = 0; i < t.length; ++i) n[t[i]] = !0;
3
- return n;
4
- }
5
- var s = "body catch class do else enum for foreach foreach_reverse if in interface mixin out scope struct switch try union unittest version while with";
6
- const l = {
7
- keywords: c("abstract alias align asm assert auto break case cast cdouble cent cfloat const continue debug default delegate delete deprecated export extern final finally function goto immutable import inout invariant is lazy macro module new nothrow override package pragma private protected public pure ref return shared short static super synchronized template this throw typedef typeid typeof volatile __FILE__ __LINE__ __gshared __traits __vector __parameters " + s),
8
- blockKeywords: c(s),
9
- builtin: c("bool byte char creal dchar double float idouble ifloat int ireal long real short ubyte ucent uint ulong ushort wchar wstring void size_t sizediff_t"),
10
- atoms: c("exit failure success true false null"),
11
- hooks: {
12
- "@": function(e, n) {
13
- return e.eatWhile(/[\w\$_]/), "meta";
14
- }
15
- }
16
- };
17
- var w = l.statementIndentUnit, v = l.keywords, x = l.builtin, d = l.blockKeywords, g = l.atoms, p = l.hooks, _ = l.multiLineStrings, h = /[+\-*&%=<>!?|\/]/, o;
18
- function m(e, n) {
19
- var t = e.next();
20
- if (p[t]) {
21
- var i = p[t](e, n);
22
- if (i !== !1) return i;
23
- }
24
- if (t == '"' || t == "'" || t == "`")
25
- return n.tokenize = z(t), n.tokenize(e, n);
26
- if (/[\[\]{}\(\),;\:\.]/.test(t))
27
- return o = t, null;
28
- if (/\d/.test(t))
29
- return e.eatWhile(/[\w\.]/), "number";
30
- if (t == "/") {
31
- if (e.eat("+"))
32
- return n.tokenize = k, k(e, n);
33
- if (e.eat("*"))
34
- return n.tokenize = y, y(e, n);
35
- if (e.eat("/"))
36
- return e.skipToEnd(), "comment";
37
- }
38
- if (h.test(t))
39
- return e.eatWhile(h), "operator";
40
- e.eatWhile(/[\w\$_\xa1-\uffff]/);
41
- var r = e.current();
42
- return v.propertyIsEnumerable(r) ? (d.propertyIsEnumerable(r) && (o = "newstatement"), "keyword") : x.propertyIsEnumerable(r) ? (d.propertyIsEnumerable(r) && (o = "newstatement"), "builtin") : g.propertyIsEnumerable(r) ? "atom" : "variable";
43
- }
44
- function z(e) {
45
- return function(n, t) {
46
- for (var i = !1, r, u = !1; (r = n.next()) != null; ) {
47
- if (r == e && !i) {
48
- u = !0;
49
- break;
50
- }
51
- i = !i && r == "\\";
52
- }
53
- return (u || !(i || _)) && (t.tokenize = null), "string";
54
- };
55
- }
56
- function y(e, n) {
57
- for (var t = !1, i; i = e.next(); ) {
58
- if (i == "/" && t) {
59
- n.tokenize = null;
60
- break;
61
- }
62
- t = i == "*";
63
- }
64
- return "comment";
65
- }
66
- function k(e, n) {
67
- for (var t = !1, i; i = e.next(); ) {
68
- if (i == "/" && t) {
69
- n.tokenize = null;
70
- break;
71
- }
72
- t = i == "+";
73
- }
74
- return "comment";
75
- }
76
- function b(e, n, t, i, r) {
77
- this.indented = e, this.column = n, this.type = t, this.align = i, this.prev = r;
78
- }
79
- function f(e, n, t) {
80
- var i = e.indented;
81
- return e.context && e.context.type == "statement" && (i = e.context.indented), e.context = new b(i, n, t, null, e.context);
82
- }
83
- function a(e) {
84
- var n = e.context.type;
85
- return (n == ")" || n == "]" || n == "}") && (e.indented = e.context.indented), e.context = e.context.prev;
86
- }
87
- const E = {
88
- name: "d",
89
- startState: function(e) {
90
- return {
91
- tokenize: null,
92
- context: new b(-e, 0, "top", !1),
93
- indented: 0,
94
- startOfLine: !0
95
- };
96
- },
97
- token: function(e, n) {
98
- var t = n.context;
99
- if (e.sol() && (t.align == null && (t.align = !1), n.indented = e.indentation(), n.startOfLine = !0), e.eatSpace()) return null;
100
- o = null;
101
- var i = (n.tokenize || m)(e, n);
102
- if (i == "comment" || i == "meta") return i;
103
- if (t.align == null && (t.align = !0), (o == ";" || o == ":" || o == ",") && t.type == "statement") a(n);
104
- else if (o == "{") f(n, e.column(), "}");
105
- else if (o == "[") f(n, e.column(), "]");
106
- else if (o == "(") f(n, e.column(), ")");
107
- else if (o == "}") {
108
- for (; t.type == "statement"; ) t = a(n);
109
- for (t.type == "}" && (t = a(n)); t.type == "statement"; ) t = a(n);
110
- } else o == t.type ? a(n) : ((t.type == "}" || t.type == "top") && o != ";" || t.type == "statement" && o == "newstatement") && f(n, e.column(), "statement");
111
- return n.startOfLine = !1, i;
112
- },
113
- indent: function(e, n, t) {
114
- if (e.tokenize != m && e.tokenize != null) return null;
115
- var i = e.context, r = n && n.charAt(0);
116
- i.type == "statement" && r == "}" && (i = i.prev);
117
- var u = r == i.type;
118
- return i.type == "statement" ? i.indented + (r == "{" ? 0 : w || t.unit) : i.align ? i.column + (u ? 0 : 1) : i.indented + (u ? 0 : t.unit);
119
- },
120
- languageData: {
121
- indentOnInput: /^\s*[{}]$/,
122
- commentTokens: { line: "//", block: { open: "/*", close: "*/" } }
123
- }
124
- };
125
- export {
126
- E as d
127
- };
@@ -1,18 +0,0 @@
1
- var o = {
2
- "+": "inserted",
3
- "-": "deleted",
4
- "@": "meta"
5
- };
6
- const r = {
7
- name: "diff",
8
- token: function(n) {
9
- var e = n.string.search(/[\t ]+?$/);
10
- if (!n.sol() || e === 0)
11
- return n.skipToEnd(), ("error " + (o[n.string.charAt(0)] || "")).replace(/ $/, "");
12
- var i = o[n.peek()] || n.skipToEnd();
13
- return e === -1 ? n.skipToEnd() : n.pos = e, i;
14
- }
15
- };
16
- export {
17
- r as diff
18
- };
@@ -1,194 +0,0 @@
1
- import { s as o } from "./simple-mode-HGTvdazT.js";
2
- var e = "from", s = new RegExp("^(\\s*)\\b(" + e + ")\\b", "i"), n = ["run", "cmd", "entrypoint", "shell"], l = new RegExp("^(\\s*)(" + n.join("|") + ")(\\s+\\[)", "i"), t = "expose", x = new RegExp("^(\\s*)(" + t + ")(\\s+)", "i"), g = [
3
- "arg",
4
- "from",
5
- "maintainer",
6
- "label",
7
- "env",
8
- "add",
9
- "copy",
10
- "volume",
11
- "user",
12
- "workdir",
13
- "onbuild",
14
- "stopsignal",
15
- "healthcheck",
16
- "shell"
17
- ], u = [e, t].concat(n).concat(g), r = "(" + u.join("|") + ")", a = new RegExp("^(\\s*)" + r + "(\\s*)(#.*)?$", "i"), k = new RegExp("^(\\s*)" + r + "(\\s+)", "i");
18
- const m = o({
19
- start: [
20
- // Block comment: This is a line starting with a comment
21
- {
22
- regex: /^\s*#.*$/,
23
- sol: !0,
24
- token: "comment"
25
- },
26
- {
27
- regex: s,
28
- token: [null, "keyword"],
29
- sol: !0,
30
- next: "from"
31
- },
32
- // Highlight an instruction without any arguments (for convenience)
33
- {
34
- regex: a,
35
- token: [null, "keyword", null, "error"],
36
- sol: !0
37
- },
38
- {
39
- regex: l,
40
- token: [null, "keyword", null],
41
- sol: !0,
42
- next: "array"
43
- },
44
- {
45
- regex: x,
46
- token: [null, "keyword", null],
47
- sol: !0,
48
- next: "expose"
49
- },
50
- // Highlight an instruction followed by arguments
51
- {
52
- regex: k,
53
- token: [null, "keyword", null],
54
- sol: !0,
55
- next: "arguments"
56
- },
57
- {
58
- regex: /./,
59
- token: null
60
- }
61
- ],
62
- from: [
63
- {
64
- regex: /\s*$/,
65
- token: null,
66
- next: "start"
67
- },
68
- {
69
- // Line comment without instruction arguments is an error
70
- regex: /(\s*)(#.*)$/,
71
- token: [null, "error"],
72
- next: "start"
73
- },
74
- {
75
- regex: /(\s*\S+\s+)(as)/i,
76
- token: [null, "keyword"],
77
- next: "start"
78
- },
79
- // Fail safe return to start
80
- {
81
- token: null,
82
- next: "start"
83
- }
84
- ],
85
- single: [
86
- {
87
- regex: /(?:[^\\']|\\.)/,
88
- token: "string"
89
- },
90
- {
91
- regex: /'/,
92
- token: "string",
93
- pop: !0
94
- }
95
- ],
96
- double: [
97
- {
98
- regex: /(?:[^\\"]|\\.)/,
99
- token: "string"
100
- },
101
- {
102
- regex: /"/,
103
- token: "string",
104
- pop: !0
105
- }
106
- ],
107
- array: [
108
- {
109
- regex: /\]/,
110
- token: null,
111
- next: "start"
112
- },
113
- {
114
- regex: /"(?:[^\\"]|\\.)*"?/,
115
- token: "string"
116
- }
117
- ],
118
- expose: [
119
- {
120
- regex: /\d+$/,
121
- token: "number",
122
- next: "start"
123
- },
124
- {
125
- regex: /[^\d]+$/,
126
- token: null,
127
- next: "start"
128
- },
129
- {
130
- regex: /\d+/,
131
- token: "number"
132
- },
133
- {
134
- regex: /[^\d]+/,
135
- token: null
136
- },
137
- // Fail safe return to start
138
- {
139
- token: null,
140
- next: "start"
141
- }
142
- ],
143
- arguments: [
144
- {
145
- regex: /^\s*#.*$/,
146
- sol: !0,
147
- token: "comment"
148
- },
149
- {
150
- regex: /"(?:[^\\"]|\\.)*"?$/,
151
- token: "string",
152
- next: "start"
153
- },
154
- {
155
- regex: /"/,
156
- token: "string",
157
- push: "double"
158
- },
159
- {
160
- regex: /'(?:[^\\']|\\.)*'?$/,
161
- token: "string",
162
- next: "start"
163
- },
164
- {
165
- regex: /'/,
166
- token: "string",
167
- push: "single"
168
- },
169
- {
170
- regex: /[^#"']+[\\`]$/,
171
- token: null
172
- },
173
- {
174
- regex: /[^#"']+$/,
175
- token: null,
176
- next: "start"
177
- },
178
- {
179
- regex: /[^#"']+/,
180
- token: null
181
- },
182
- // Fail safe return to start
183
- {
184
- token: null,
185
- next: "start"
186
- }
187
- ],
188
- languageData: {
189
- commentTokens: { line: "#" }
190
- }
191
- });
192
- export {
193
- m as dockerFile
194
- };
@@ -1,84 +0,0 @@
1
- var u;
2
- function r(e, n) {
3
- return u = n, e;
4
- }
5
- function t(e, n) {
6
- var l = e.next();
7
- if (l == "<" && e.eat("!")) {
8
- if (e.eatWhile(/[\-]/))
9
- return n.tokenize = o, o(e, n);
10
- if (e.eatWhile(/[\w]/)) return r("keyword", "doindent");
11
- } else {
12
- if (l == "<" && e.eat("?"))
13
- return n.tokenize = a("meta", "?>"), r("meta", l);
14
- if (l == "#" && e.eatWhile(/[\w]/)) return r("atom", "tag");
15
- if (l == "|") return r("keyword", "separator");
16
- if (l.match(/[\(\)\[\]\-\.,\+\?>]/)) return r(null, l);
17
- if (l.match(/[\[\]]/)) return r("rule", l);
18
- if (l == '"' || l == "'")
19
- return n.tokenize = k(l), n.tokenize(e, n);
20
- if (e.eatWhile(/[a-zA-Z\?\+\d]/)) {
21
- var i = e.current();
22
- return i.substr(i.length - 1, i.length).match(/\?|\+/) !== null && e.backUp(1), r("tag", "tag");
23
- } else return l == "%" || l == "*" ? r("number", "number") : (e.eatWhile(/[\w\\\-_%.{,]/), r(null, null));
24
- }
25
- }
26
- function o(e, n) {
27
- for (var l = 0, i; (i = e.next()) != null; ) {
28
- if (l >= 2 && i == ">") {
29
- n.tokenize = t;
30
- break;
31
- }
32
- l = i == "-" ? l + 1 : 0;
33
- }
34
- return r("comment", "comment");
35
- }
36
- function k(e) {
37
- return function(n, l) {
38
- for (var i = !1, c; (c = n.next()) != null; ) {
39
- if (c == e && !i) {
40
- l.tokenize = t;
41
- break;
42
- }
43
- i = !i && c == "\\";
44
- }
45
- return r("string", "tag");
46
- };
47
- }
48
- function a(e, n) {
49
- return function(l, i) {
50
- for (; !l.eol(); ) {
51
- if (l.match(n)) {
52
- i.tokenize = t;
53
- break;
54
- }
55
- l.next();
56
- }
57
- return e;
58
- };
59
- }
60
- const f = {
61
- name: "dtd",
62
- startState: function() {
63
- return {
64
- tokenize: t,
65
- baseIndent: 0,
66
- stack: []
67
- };
68
- },
69
- token: function(e, n) {
70
- if (e.eatSpace()) return null;
71
- var l = n.tokenize(e, n), i = n.stack[n.stack.length - 1];
72
- return e.current() == "[" || u === "doindent" || u == "[" ? n.stack.push("rule") : u === "endtag" ? n.stack[n.stack.length - 1] = "endtag" : e.current() == "]" || u == "]" || u == ">" && i == "rule" ? n.stack.pop() : u == "[" && n.stack.push("["), l;
73
- },
74
- indent: function(e, n, l) {
75
- var i = e.stack.length;
76
- return n.charAt(0) === "]" ? i-- : n.substr(n.length - 1, n.length) === ">" && (n.substr(0, 1) === "<" || u == "doindent" && n.length > 1 || (u == "doindent" ? i-- : u == ">" && n.length > 1 || u == "tag" && n !== ">" || (u == "tag" && e.stack[e.stack.length - 1] == "rule" ? i-- : u == "tag" ? i++ : n === ">" && e.stack[e.stack.length - 1] == "rule" && u === ">" ? i-- : n === ">" && e.stack[e.stack.length - 1] == "rule" || (n.substr(0, 1) !== "<" && n.substr(0, 1) === ">" ? i = i - 1 : n === ">" || (i = i - 1)))), (u == null || u == "]") && i--), e.baseIndent + i * l.unit;
77
- },
78
- languageData: {
79
- indentOnInput: /^\s*[\]>]$/
80
- }
81
- };
82
- export {
83
- f as dtd
84
- };