site/node_modules/shiki/dist/langs/groovy.mjs

7 lines
21 KiB
JavaScript
Raw Normal View History

2024-10-14 06:09:33 +00:00
const lang = Object.freeze({ "displayName": "Groovy", "name": "groovy", "patterns": [{ "captures": { "1": { "name": "punctuation.definition.comment.groovy" } }, "match": "^(#!).+$\\n", "name": "comment.line.hashbang.groovy" }, { "captures": { "1": { "name": "keyword.other.package.groovy" }, "2": { "name": "storage.modifier.package.groovy" }, "3": { "name": "punctuation.terminator.groovy" } }, "match": "^\\s*(package)\\b(?:\\s*([^ ;$]+)\\s*(;)?)?", "name": "meta.package.groovy" }, { "begin": "(import static)\\b\\s*", "beginCaptures": { "1": { "name": "keyword.other.import.static.groovy" } }, "captures": { "1": { "name": "keyword.other.import.groovy" }, "2": { "name": "storage.modifier.import.groovy" }, "3": { "name": "punctuation.terminator.groovy" } }, "contentName": "storage.modifier.import.groovy", "end": "\\s*(?:$|(?=%>)(;))", "endCaptures": { "1": { "name": "punctuation.terminator.groovy" } }, "name": "meta.import.groovy", "patterns": [{ "match": "\\.", "name": "punctuation.separator.groovy" }, { "match": "\\s", "name": "invalid.illegal.character_not_allowed_here.groovy" }] }, { "begin": "(import)\\b\\s*", "beginCaptures": { "1": { "name": "keyword.other.import.groovy" } }, "captures": { "1": { "name": "keyword.other.import.groovy" }, "2": { "name": "storage.modifier.import.groovy" }, "3": { "name": "punctuation.terminator.groovy" } }, "contentName": "storage.modifier.import.groovy", "end": "\\s*(?:$|(?=%>)|(;))", "endCaptures": { "1": { "name": "punctuation.terminator.groovy" } }, "name": "meta.import.groovy", "patterns": [{ "match": "\\.", "name": "punctuation.separator.groovy" }, { "match": "\\s", "name": "invalid.illegal.character_not_allowed_here.groovy" }] }, { "captures": { "1": { "name": "keyword.other.import.groovy" }, "2": { "name": "keyword.other.import.static.groovy" }, "3": { "name": "storage.modifier.import.groovy" }, "4": { "name": "punctuation.terminator.groovy" } }, "match": "^\\s*(import)(?:\\s+(static)\\s+)\\b(?:\\s*([^ ;$]+)\\s*(;)?)?", "name": "meta.import.groovy" }, { "include": "#groovy" }], "repository": { "annotations": { "patterns": [{ "begin": "(?<!\\.)(@[^ (]+)(\\()", "beginCaptures": { "1": { "name": "storage.type.annotation.groovy" }, "2": { "name": "punctuation.definition.annotation-arguments.begin.groovy" } }, "end": "(\\))", "endCaptures": { "1": { "name": "punctuation.definition.annotation-arguments.end.groovy" } }, "name": "meta.declaration.annotation.groovy", "patterns": [{ "captures": { "1": { "name": "constant.other.key.groovy" }, "2": { "name": "keyword.operator.assignment.groovy" } }, "match": "(\\w*)\\s*(=)" }, { "include": "#values" }, { "match": ",", "name": "punctuation.definition.seperator.groovy" }] }, { "match": "(?<!\\.)@\\S+", "name": "storage.type.annotation.groovy" }] }, "anonymous-classes-and-new": { "begin": "\\bnew\\b", "beginCaptures": { "0": { "name": "keyword.control.new.groovy" } }, "end": "(?<=\\)|\\])(?!\\s*{)|(?<=})|(?=[;])|$", "patterns": [{ "begin": "(\\w+)\\s*(?=\\[)", "beginCaptures": { "1": { "name": "storage.type.groovy" } }, "end": "}|(?=\\s*(?:,|;|\\)))|$", "patterns": [{ "begin": "\\[", "end": "\\]", "patterns": [{ "include": "#groovy" }] }, { "begin": "{", "end": "(?=})", "patterns": [{ "include": "#groovy" }] }] }, { "begin": "(?=\\w.*\\(?)", "end": "(?<=\\))|$", "patterns": [{ "include": "#object-types" }, { "begin": "\\(", "beginCaptures": { "1": { "name": "storage.type.groovy" } }, "end": "\\)", "patterns": [{ "include": "#groovy" }] }] }, { "begin": "{", "end": "}", "name": "meta.inner-class.groovy", "patterns": [{ "include": "#class-body" }] }] }, "braces": { "begin": "\\{", "end": "\\}", "patterns": [{ "include": "#groovy-code" }] }, "class": { "begin": "(?=\\w?[\\w\\s]*(?:class|(?:@)?interface|enum)\\s+\\w+)", "end": "}", "endCaptures": { "0": { "name": "punctuation.section.class.end.groovy" } }, "name": "meta.definition.class.groovy", "patterns": [{ "include": "#storage-modifiers" }, { "include": "#comments" }, { "captures": { "1": { "name": "storage.modifier.groovy" }, "2": { "name": "entity.name.type.class.groovy" } }, "match": "(class
var groovy = [
lang
];
export { groovy as default };