dart-RUYNNH7F.js 6.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279
  1. import "./chunk-2LSFTFF7.js";
  2. // node_modules/.pnpm/monaco-editor@0.38.0/node_modules/monaco-editor/esm/vs/basic-languages/dart/dart.js
  3. var conf = {
  4. comments: {
  5. lineComment: "//",
  6. blockComment: ["/*", "*/"]
  7. },
  8. brackets: [
  9. ["{", "}"],
  10. ["[", "]"],
  11. ["(", ")"]
  12. ],
  13. autoClosingPairs: [
  14. { open: "{", close: "}" },
  15. { open: "[", close: "]" },
  16. { open: "(", close: ")" },
  17. { open: "'", close: "'", notIn: ["string", "comment"] },
  18. { open: '"', close: '"', notIn: ["string"] },
  19. { open: "`", close: "`", notIn: ["string", "comment"] },
  20. { open: "/**", close: " */", notIn: ["string"] }
  21. ],
  22. surroundingPairs: [
  23. { open: "{", close: "}" },
  24. { open: "[", close: "]" },
  25. { open: "(", close: ")" },
  26. { open: "<", close: ">" },
  27. { open: "'", close: "'" },
  28. { open: "(", close: ")" },
  29. { open: '"', close: '"' },
  30. { open: "`", close: "`" }
  31. ],
  32. folding: {
  33. markers: {
  34. start: /^\s*\s*#?region\b/,
  35. end: /^\s*\s*#?endregion\b/
  36. }
  37. }
  38. };
  39. var language = {
  40. defaultToken: "invalid",
  41. tokenPostfix: ".dart",
  42. keywords: [
  43. "abstract",
  44. "dynamic",
  45. "implements",
  46. "show",
  47. "as",
  48. "else",
  49. "import",
  50. "static",
  51. "assert",
  52. "enum",
  53. "in",
  54. "super",
  55. "async",
  56. "export",
  57. "interface",
  58. "switch",
  59. "await",
  60. "extends",
  61. "is",
  62. "sync",
  63. "break",
  64. "external",
  65. "library",
  66. "this",
  67. "case",
  68. "factory",
  69. "mixin",
  70. "throw",
  71. "catch",
  72. "false",
  73. "new",
  74. "true",
  75. "class",
  76. "final",
  77. "null",
  78. "try",
  79. "const",
  80. "finally",
  81. "on",
  82. "typedef",
  83. "continue",
  84. "for",
  85. "operator",
  86. "var",
  87. "covariant",
  88. "Function",
  89. "part",
  90. "void",
  91. "default",
  92. "get",
  93. "rethrow",
  94. "while",
  95. "deferred",
  96. "hide",
  97. "return",
  98. "with",
  99. "do",
  100. "if",
  101. "set",
  102. "yield"
  103. ],
  104. typeKeywords: ["int", "double", "String", "bool"],
  105. operators: [
  106. "+",
  107. "-",
  108. "*",
  109. "/",
  110. "~/",
  111. "%",
  112. "++",
  113. "--",
  114. "==",
  115. "!=",
  116. ">",
  117. "<",
  118. ">=",
  119. "<=",
  120. "=",
  121. "-=",
  122. "/=",
  123. "%=",
  124. ">>=",
  125. "^=",
  126. "+=",
  127. "*=",
  128. "~/=",
  129. "<<=",
  130. "&=",
  131. "!=",
  132. "||",
  133. "&&",
  134. "&",
  135. "|",
  136. "^",
  137. "~",
  138. "<<",
  139. ">>",
  140. "!",
  141. ">>>",
  142. "??",
  143. "?",
  144. ":",
  145. "|="
  146. ],
  147. symbols: /[=><!~?:&|+\-*\/\^%]+/,
  148. escapes: /\\(?:[abfnrtv\\"']|x[0-9A-Fa-f]{1,4}|u[0-9A-Fa-f]{4}|U[0-9A-Fa-f]{8})/,
  149. digits: /\d+(_+\d+)*/,
  150. octaldigits: /[0-7]+(_+[0-7]+)*/,
  151. binarydigits: /[0-1]+(_+[0-1]+)*/,
  152. hexdigits: /[[0-9a-fA-F]+(_+[0-9a-fA-F]+)*/,
  153. regexpctl: /[(){}\[\]\$\^|\-*+?\.]/,
  154. regexpesc: /\\(?:[bBdDfnrstvwWn0\\\/]|@regexpctl|c[A-Z]|x[0-9a-fA-F]{2}|u[0-9a-fA-F]{4})/,
  155. tokenizer: {
  156. root: [[/[{}]/, "delimiter.bracket"], { include: "common" }],
  157. common: [
  158. [
  159. /[a-z_$][\w$]*/,
  160. {
  161. cases: {
  162. "@typeKeywords": "type.identifier",
  163. "@keywords": "keyword",
  164. "@default": "identifier"
  165. }
  166. }
  167. ],
  168. [/[A-Z_$][\w\$]*/, "type.identifier"],
  169. { include: "@whitespace" },
  170. [
  171. /\/(?=([^\\\/]|\\.)+\/([gimsuy]*)(\s*)(\.|;|,|\)|\]|\}|$))/,
  172. { token: "regexp", bracket: "@open", next: "@regexp" }
  173. ],
  174. [/@[a-zA-Z]+/, "annotation"],
  175. [/[()\[\]]/, "@brackets"],
  176. [/[<>](?!@symbols)/, "@brackets"],
  177. [/!(?=([^=]|$))/, "delimiter"],
  178. [
  179. /@symbols/,
  180. {
  181. cases: {
  182. "@operators": "delimiter",
  183. "@default": ""
  184. }
  185. }
  186. ],
  187. [/(@digits)[eE]([\-+]?(@digits))?/, "number.float"],
  188. [/(@digits)\.(@digits)([eE][\-+]?(@digits))?/, "number.float"],
  189. [/0[xX](@hexdigits)n?/, "number.hex"],
  190. [/0[oO]?(@octaldigits)n?/, "number.octal"],
  191. [/0[bB](@binarydigits)n?/, "number.binary"],
  192. [/(@digits)n?/, "number"],
  193. [/[;,.]/, "delimiter"],
  194. [/"([^"\\]|\\.)*$/, "string.invalid"],
  195. [/'([^'\\]|\\.)*$/, "string.invalid"],
  196. [/"/, "string", "@string_double"],
  197. [/'/, "string", "@string_single"]
  198. ],
  199. whitespace: [
  200. [/[ \t\r\n]+/, ""],
  201. [/\/\*\*(?!\/)/, "comment.doc", "@jsdoc"],
  202. [/\/\*/, "comment", "@comment"],
  203. [/\/\/\/.*$/, "comment.doc"],
  204. [/\/\/.*$/, "comment"]
  205. ],
  206. comment: [
  207. [/[^\/*]+/, "comment"],
  208. [/\*\//, "comment", "@pop"],
  209. [/[\/*]/, "comment"]
  210. ],
  211. jsdoc: [
  212. [/[^\/*]+/, "comment.doc"],
  213. [/\*\//, "comment.doc", "@pop"],
  214. [/[\/*]/, "comment.doc"]
  215. ],
  216. regexp: [
  217. [
  218. /(\{)(\d+(?:,\d*)?)(\})/,
  219. ["regexp.escape.control", "regexp.escape.control", "regexp.escape.control"]
  220. ],
  221. [
  222. /(\[)(\^?)(?=(?:[^\]\\\/]|\\.)+)/,
  223. ["regexp.escape.control", { token: "regexp.escape.control", next: "@regexrange" }]
  224. ],
  225. [/(\()(\?:|\?=|\?!)/, ["regexp.escape.control", "regexp.escape.control"]],
  226. [/[()]/, "regexp.escape.control"],
  227. [/@regexpctl/, "regexp.escape.control"],
  228. [/[^\\\/]/, "regexp"],
  229. [/@regexpesc/, "regexp.escape"],
  230. [/\\\./, "regexp.invalid"],
  231. [/(\/)([gimsuy]*)/, [{ token: "regexp", bracket: "@close", next: "@pop" }, "keyword.other"]]
  232. ],
  233. regexrange: [
  234. [/-/, "regexp.escape.control"],
  235. [/\^/, "regexp.invalid"],
  236. [/@regexpesc/, "regexp.escape"],
  237. [/[^\]]/, "regexp"],
  238. [
  239. /\]/,
  240. {
  241. token: "regexp.escape.control",
  242. next: "@pop",
  243. bracket: "@close"
  244. }
  245. ]
  246. ],
  247. string_double: [
  248. [/[^\\"\$]+/, "string"],
  249. [/[^\\"]+/, "string"],
  250. [/@escapes/, "string.escape"],
  251. [/\\./, "string.escape.invalid"],
  252. [/"/, "string", "@pop"],
  253. [/\$\w+/, "identifier"]
  254. ],
  255. string_single: [
  256. [/[^\\'\$]+/, "string"],
  257. [/@escapes/, "string.escape"],
  258. [/\\./, "string.escape.invalid"],
  259. [/'/, "string", "@pop"],
  260. [/\$\w+/, "identifier"]
  261. ]
  262. }
  263. };
  264. export {
  265. conf,
  266. language
  267. };
  268. /*! Bundled license information:
  269. monaco-editor/esm/vs/basic-languages/dart/dart.js:
  270. (*!-----------------------------------------------------------------------------
  271. * Copyright (c) Microsoft Corporation. All rights reserved.
  272. * Version: 0.38.0(0e330ae453813de4e6cf272460fb79c7117073d0)
  273. * Released under the MIT license
  274. * https://github.com/microsoft/monaco-editor/blob/main/LICENSE.txt
  275. *-----------------------------------------------------------------------------*)
  276. */
  277. //# sourceMappingURL=dart-RUYNNH7F.js.map