|
| 1 | +{ |
| 2 | + "$schema": "https://raw.githubusercontent.com/RedCMD/TmLanguage-Syntax-Highlighter/main/vscode.tmLanguage.schema.json", |
| 3 | + "name": "Schema \"defaultSnippets\" Snippets", |
| 4 | + "scopeName": "source.json.snippets", |
| 5 | + "injectionSelector": [ |
| 6 | + "L:source.json .meta.embedded.defaultSnippets. meta.structure.array.json .meta.embedded.bodyText. string.quoted.double.json -(.meta.embedded.bodyText. meta.structure.dictionary.json) -(.meta.embedded.bodyText. meta.structure.array.json) -(.meta.embedded.defaultSnippets. meta.structure.array.json meta.structure.array.json .meta.embedded.bodyText.) -(.meta.embedded.defaultSnippets. meta.structure.dictionary.json meta.structure.dictionary.json .meta.embedded.bodyText.) -meta.embedded.json.comments.snippets.snippets -comment -source.json.comments", |
| 7 | + "L:source.json .meta.embedded.defaultSnippets. meta.structure.array.json .meta.embedded.body. (string.quoted.double.json | support.type.property-name.json) -(.meta.embedded.defaultSnippets. meta.structure.array.json meta.structure.array.json .meta.embedded.body.) -(.meta.embedded.defaultSnippets. meta.structure.dictionary.json meta.structure.dictionary.json .meta.embedded.body.) -meta.embedded.json.comments.snippets.snippets -comment -source.json.comments" |
| 8 | + ], |
| 9 | + "patterns": [ |
| 10 | + { |
| 11 | + "comment": "https://github.com/microsoft/vscode-textmate/issues/242", |
| 12 | + "include": "source.json.comments.snippets#_pre-load_" |
| 13 | + }, |
| 14 | + { "include": "#body-key" }, |
| 15 | + { "include": "#bodyText-string" }, |
| 16 | + { "include": "#body-string" } |
| 17 | + ], |
| 18 | + "repository": { |
| 19 | + "body-key": { |
| 20 | + "match": "(?<={\\s*+\")\\G(?>[^\\\\\"\\x-\\x1F]++|\\\\.)++|(?<=\")\\G(?>[^\\\\\"\\x-\\x1F]++|\\\\.)++(?=\"\\s*+:)", |
| 21 | + "captures": { |
| 22 | + "0": { |
| 23 | + "name": "meta.embedded.json.comments.snippets.snippets string.json support.type.property-name.json", |
| 24 | + "patterns": [ |
| 25 | + { "include": "source.json.comments.snippets#any" }, |
| 26 | + { "include": "source.json.comments.snippets#body_stringcontent" }, |
| 27 | + { "include": "source.json#stringcontent" } |
| 28 | + ] |
| 29 | + } |
| 30 | + } |
| 31 | + }, |
| 32 | + "bodyText-string": { |
| 33 | + "match": "(?<=\"bodyText\"\\s*+:\\s*+\")\\G(?>[^\\\\\"\\x-\\x1F]++|\\\\.)++", |
| 34 | + "captures": { |
| 35 | + "0": { |
| 36 | + "name": "meta.embedded.json.comments.snippets.snippets string.quoted.double.json", |
| 37 | + "patterns": [ |
| 38 | + { "include": "source.json.comments.snippets#any" }, |
| 39 | + { "include": "source.json.comments.snippets#body_stringcontent" }, |
| 40 | + { "include": "source.json#stringcontent" } |
| 41 | + ] |
| 42 | + } |
| 43 | + } |
| 44 | + }, |
| 45 | + "body-string": { |
| 46 | + "match": "(?<=\")\\G(?>(\\^)?+((?>[^\\\\\"\\x-\\x1F]++|\\\\.)++)|(\\^))", |
| 47 | + "captures": { |
| 48 | + "1": { "name": "keyword.control.unstringify.json.schema" }, |
| 49 | + "2": { |
| 50 | + "name": "meta.embedded.json.comments.snippets.snippets string.quoted.double.json", |
| 51 | + "patterns": [ |
| 52 | + { "include": "source.json.comments.snippets#any" }, |
| 53 | + { "include": "source.json.comments.snippets#body_stringcontent" }, |
| 54 | + { "include": "source.json#stringcontent" } |
| 55 | + ] |
| 56 | + }, |
| 57 | + "3": { "name": "keyword.control.unstringify.json.schema" } |
| 58 | + } |
| 59 | + } |
| 60 | + } |
| 61 | +} |
0 commit comments