From 7a3df06eb573d36142bd1a8e03c5ce8752d300b3 Mon Sep 17 00:00:00 2001 From: Florian Dold Date: Wed, 24 May 2017 15:10:37 +0200 Subject: fix build issues and add typedoc --- node_modules/highlight.js/lib/languages/flix.js | 44 +++++++++++++++++++++++++ 1 file changed, 44 insertions(+) create mode 100644 node_modules/highlight.js/lib/languages/flix.js (limited to 'node_modules/highlight.js/lib/languages/flix.js') diff --git a/node_modules/highlight.js/lib/languages/flix.js b/node_modules/highlight.js/lib/languages/flix.js new file mode 100644 index 000000000..ccaeab9d2 --- /dev/null +++ b/node_modules/highlight.js/lib/languages/flix.js @@ -0,0 +1,44 @@ +module.exports = function (hljs) { + + var CHAR = { + className: 'string', + begin: /'(.|\\[xXuU][a-zA-Z0-9]+)'/ + }; + + var STRING = { + className: 'string', + variants: [ + { + begin: '"', end: '"' + } + ] + }; + + var NAME = { + className: 'title', + begin: /[^0-9\n\t "'(),.`{}\[\]:;][^\n\t "'(),.`{}\[\]:;]+|[^0-9\n\t "'(),.`{}\[\]:;=]/ + }; + + var METHOD = { + className: 'function', + beginKeywords: 'def', + end: /[:={\[(\n;]/, + excludeEnd: true, + contains: [NAME] + }; + + return { + keywords: { + literal: 'true false', + keyword: 'case class def else enum if impl import in lat rel index let match namespace switch type yield with' + }, + contains: [ + hljs.C_LINE_COMMENT_MODE, + hljs.C_BLOCK_COMMENT_MODE, + CHAR, + STRING, + METHOD, + hljs.C_NUMBER_MODE + ] + }; +}; \ No newline at end of file -- cgit v1.2.3