PluginProbe
Code Block Pro – Beautiful Syntax Highlighting / 1.13.0
Code Block Pro – Beautiful Syntax Highlighting v1.13.0
1.27.1 1.27.2 1.27.3 1.27.4 1.27.5 1.27.6 1.27.7 1.28.0 1.3.0 1.4.0 1.5.0 1.5.1 1.5.2 1.6.0 1.7.0 1.8.0 1.9.0 1.9.1 1.9.2 1.9.3 trunk 1.1.0 1.10.0 1.11.0 1.11.1 All 63 releases
code-block-pro / build / shiki / languages / astro.tmLanguage.json

astro.tmLanguage.json in Code Block Pro – Beautiful Syntax Highlighting 1.13.0, at build/shiki/languages/astro.tmLanguage.json

724 lines 18.0 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 {
2 "name": "astro",
3 "scopeName": "source.astro",
4 "fileTypes": ["astro"],
5 "injections": {
6 "L:(meta.script.astro) (meta.lang.json) - (meta source)": {
7 "patterns": [
8 {
9 "begin": "(?<=>)(?!</)",
10 "end": "(?=</)",
11 "name": "meta.embedded.block.astro",
12 "contentName": "source.json",
13 "patterns": [
14 {
15 "include": "source.json"
16 }
17 ]
18 }
19 ]
20 },
21 "L:(meta.script.astro) (meta.lang.js | meta.lang.javascript | meta.lang.partytown | meta.lang.node) - (meta source)": {
22 "patterns": [
23 {
24 "begin": "(?<=>)(?!</)",
25 "end": "(?=</)",
26 "name": "meta.embedded.block.astro",
27 "contentName": "source.js",
28 "patterns": [
29 {
30 "include": "source.js"
31 }
32 ]
33 }
34 ]
35 },
36 "L:(meta.script.astro) (meta.lang.ts | meta.lang.typescript) - (meta source)": {
37 "patterns": [
38 {
39 "begin": "(?<=>)(?!</)",
40 "end": "(?=</)",
41 "name": "meta.embedded.block.astro",
42 "contentName": "source.ts",
43 "patterns": [
44 {
45 "include": "source.ts"
46 }
47 ]
48 }
49 ]
50 },
51 "L:meta.script.astro - meta.lang - (meta source)": {
52 "patterns": [
53 {
54 "begin": "(?<=>)(?!</)",
55 "end": "(?=</)",
56 "name": "meta.embedded.block.astro",
57 "contentName": "source.js",
58 "patterns": [
59 {
60 "include": "source.js"
61 }
62 ]
63 }
64 ]
65 },
66 "L:meta.style.astro meta.lang.stylus - (meta source)": {
67 "patterns": [
68 {
69 "begin": "(?<=>)(?!</)",
70 "end": "(?=</)",
71 "name": "meta.embedded.block.astro",
72 "contentName": "source.stylus",
73 "patterns": [
74 {
75 "include": "source.stylus"
76 }
77 ]
78 }
79 ]
80 },
81 "L:meta.style.astro meta.lang.sass - (meta source)": {
82 "patterns": [
83 {
84 "begin": "(?<=>)(?!</)",
85 "end": "(?=</)",
86 "name": "meta.embedded.block.astro",
87 "contentName": "source.sass",
88 "patterns": [
89 {
90 "include": "source.sass"
91 }
92 ]
93 }
94 ]
95 },
96 "L:meta.style.astro meta.lang.css - (meta source)": {
97 "patterns": [
98 {
99 "begin": "(?<=>)(?!</)",
100 "end": "(?=</)",
101 "name": "meta.embedded.block.astro",
102 "contentName": "source.css",
103 "patterns": [
104 {
105 "include": "source.css"
106 }
107 ]
108 }
109 ]
110 },
111 "L:meta.style.astro meta.lang.scss - (meta source)": {
112 "patterns": [
113 {
114 "begin": "(?<=>)(?!</)",
115 "end": "(?=</)",
116 "name": "meta.embedded.block.astro",
117 "contentName": "source.css.scss",
118 "patterns": [
119 {
120 "include": "source.css.scss"
121 }
122 ]
123 }
124 ]
125 },
126 "L:meta.style.astro meta.lang.less - (meta source)": {
127 "patterns": [
128 {
129 "begin": "(?<=>)(?!</)",
130 "end": "(?=</)",
131 "name": "meta.embedded.block.astro",
132 "contentName": "source.css.less",
133 "patterns": [
134 {
135 "include": "source.css.less"
136 }
137 ]
138 }
139 ]
140 },
141 "L:meta.style.astro meta.lang.postcss - (meta source)": {
142 "patterns": [
143 {
144 "begin": "(?<=>)(?!</)",
145 "end": "(?=</)",
146 "name": "meta.embedded.block.astro",
147 "contentName": "source.css.postcss",
148 "patterns": [
149 {
150 "include": "source.css.postcss"
151 }
152 ]
153 }
154 ]
155 },
156 "L:meta.style.astro - meta.lang - (meta source)": {
157 "patterns": [
158 {
159 "begin": "(?<=>)(?!</)",
160 "end": "(?=</)",
161 "name": "meta.embedded.block.astro",
162 "contentName": "source.css",
163 "patterns": [
164 {
165 "include": "source.css"
166 }
167 ]
168 }
169 ]
170 }
171 },
172 "patterns": [
173 {
174 "include": "#scope"
175 },
176 {
177 "include": "#frontmatter"
178 }
179 ],
180 "repository": {
181 "frontmatter": {
182 "begin": "\\A(-{3})\\s*$",
183 "end": "(^|\\G)(-{3})|\\.{3}\\s*$",
184 "beginCaptures": {
185 "1": {
186 "name": "comment"
187 }
188 },
189 "endCaptures": {
190 "2": {
191 "name": "comment"
192 }
193 },
194 "contentName": "source.ts",
195 "patterns": [
196 {
197 "include": "source.ts"
198 }
199 ]
200 },
201 "scope": {
202 "patterns": [
203 {
204 "include": "#comments"
205 },
206 {
207 "include": "#tags"
208 },
209 {
210 "include": "#interpolation"
211 },
212 {
213 "begin": "(?<=>|})",
214 "end": "(?=<|{)",
215 "name": "text.astro"
216 }
217 ]
218 },
219 "comments": {
220 "begin": "<!--",
221 "end": "-->",
222 "captures": {
223 "0": {
224 "name": "punctuation.definition.comment.astro"
225 }
226 },
227 "name": "comment.block.astro",
228 "patterns": [
229 {
230 "match": "\\G-?>|<!--(?!>)|<!-(?=-->)|--!>",
231 "name": "invalid.illegal.characters-not-allowed-here.astro"
232 }
233 ]
234 },
235 "interpolation": {
236 "patterns": [
237 {
238 "begin": "\\{",
239 "end": "\\}",
240 "beginCaptures": {
241 "0": {
242 "name": "punctuation.section.embedded.begin.astro"
243 }
244 },
245 "endCaptures": {
246 "0": {
247 "name": "punctuation.section.embedded.end.astro"
248 }
249 },
250 "contentName": "meta.embedded.expression.astro source.tsx",
251 "patterns": [
252 {
253 "begin": "\\G\\s*(?={)",
254 "end": "(?<=})",
255 "patterns": [
256 {
257 "include": "source.tsx#object-literal"
258 }
259 ]
260 },
261 {
262 "include": "source.tsx"
263 }
264 ]
265 }
266 ]
267 },
268 "attributes": {
269 "patterns": [
270 {
271 "include": "#attributes-events"
272 },
273 {
274 "include": "#attributes-keyvalue"
275 },
276 {
277 "include": "#attributes-interpolated"
278 }
279 ]
280 },
281 "attributes-events": {
282 "begin": "(on(s(croll|t(orage|alled)|u(spend|bmit)|e(curitypolicyviolation|ek(ing|ed)|lect))|hashchange|c(hange|o(ntextmenu|py)|u(t|echange)|l(ick|ose)|an(cel|play(through)?))|t(imeupdate|oggle)|in(put|valid)|o(nline|ffline)|d(urationchange|r(op|ag(start|over|e(n(ter|d)|xit)|leave)?)|blclick)|un(handledrejection|load)|p(opstate|lay(ing)?|a(ste|use|ge(show|hide))|rogress)|e(nded|rror|mptied)|volumechange|key(down|up|press)|focus|w(heel|aiting)|l(oad(start|e(nd|d(data|metadata)))?|anguagechange)|a(uxclick|fterprint|bort)|r(e(s(ize|et)|jectionhandled)|atechange)|m(ouse(o(ut|ver)|down|up|enter|leave|move)|essage(error)?)|b(efore(unload|print)|lur)))(?![\\\\w:-])",
283 "beginCaptures": {
284 "0": {
285 "patterns": [
286 {
287 "match": ".*",
288 "name": "entity.other.attribute-name.astro"
289 }
290 ]
291 }
292 },
293 "end": "(?=\\s*+[^=\\s])",
294 "name": "meta.attribute.$1.astro",
295 "patterns": [
296 {
297 "begin": "=",
298 "beginCaptures": {
299 "0": {
300 "name": "punctuation.separator.key-value.astro"
301 }
302 },
303 "end": "(?<=[^\\s=])(?!\\s*=)|(?=/?>)",
304 "patterns": [
305 {
306 "begin": "(?=[^\\s=<>`/]|/(?!>))",
307 "end": "(?!\\G)",
308 "name": "meta.embedded.line.js",
309 "patterns": [
310 {
311 "match": "(([^\\s\\\"'=<>`/]|/(?!>))+)",
312 "name": "string.unquoted.astro",
313 "captures": [
314 {
315 "0": {
316 "name": "source.js"
317 }
318 },
319 {
320 "1": {
321 "patterns": [
322 {
323 "include": "source.js"
324 }
325 ]
326 }
327 }
328 ]
329 },
330 {
331 "begin": "(['\"])",
332 "end": "\\1",
333 "beginCaptures": {
334 "0": {
335 "name": "punctuation.definition.string.begin.astro"
336 }
337 },
338 "endCaptures": {
339 "0": {
340 "name": "punctuation.definition.string.end.astro"
341 }
342 },
343 "name": "string.quoted.astro",
344 "patterns": [
345 {
346 "match": "([^\\n\\\"/]|/(?![/*]))+",
347 "captures": {
348 "0": {
349 "patterns": [
350 {
351 "include": "source.js"
352 }
353 ]
354 }
355 }
356 },
357 {
358 "begin": "//",
359 "beginCaptures": {
360 "0": {
361 "name": "punctuation.definition.comment.js"
362 }
363 },
364 "end": "(?=\\\")|\\n",
365 "name": "comment.line.double-slash.js"
366 },
367 {
368 "begin": "/\\*",
369 "beginCaptures": {
370 "0": {
371 "name": "punctuation.definition.comment.begin.js"
372 }
373 },
374 "end": "(?=\\\")|\\*/",
375 "endCaptures": {
376 "0": {
377 "name": "punctuation.definition.comment.end.js"
378 }
379 },
380 "name": "comment.block.js"
381 }
382 ]
383 }
384 ]
385 }
386 ]
387 }
388 ]
389 },
390 "attributes-interpolated": {
391 "begin": "(?<!:|=)\\s*({)",
392 "end": "(\\})",
393 "contentName": "meta.embedded.expression.astro source.tsx",
394 "patterns": [
395 {
396 "include": "source.tsx"
397 }
398 ]
399 },
400 "attributes-keyvalue": {
401 "begin": "([_@$[:alpha:]][:._\\-$[:alnum:]]*)",
402 "beginCaptures": {
403 "0": {
404 "patterns": [
405 {
406 "match": ".*",
407 "name": "entity.other.attribute-name.astro"
408 }
409 ]
410 }
411 },
412 "end": "(?=\\s*+[^=\\s])",
413 "name": "meta.attribute.$1.astro",
414 "patterns": [
415 {
416 "begin": "=",
417 "beginCaptures": {
418 "0": {
419 "name": "punctuation.separator.key-value.astro"
420 }
421 },
422 "end": "(?<=[^\\s=])(?!\\s*=)|(?=/?>)",
423 "patterns": [
424 {
425 "include": "#attributes-value"
426 }
427 ]
428 }
429 ]
430 },
431 "attributes-value": {
432 "patterns": [
433 {
434 "include": "#interpolation"
435 },
436 {
437 "match": "([^\\s\"'=<>`/]|/(?!>))+",
438 "name": "string.unquoted.astro"
439 },
440 {
441 "begin": "(['\"])",
442 "end": "\\1",
443 "beginCaptures": {
444 "0": {
445 "name": "punctuation.definition.string.begin.astro"
446 }
447 },
448 "endCaptures": {
449 "0": {
450 "name": "punctuation.definition.string.end.astro"
451 }
452 },
453 "name": "string.quoted.astro"
454 },
455 {
456 "begin": "(`)",
457 "end": "\\1",
458 "name": "string.template.astro",
459 "patterns": [
460 {
461 "include": "source.tsx#template-substitution-element"
462 }
463 ]
464 }
465 ]
466 },
467 "tags": {
468 "patterns": [
469 {
470 "include": "#tags-raw"
471 },
472 {
473 "include": "#tags-lang"
474 },
475 {
476 "include": "#tags-void"
477 },
478 {
479 "include": "#tags-general-end"
480 },
481 {
482 "include": "#tags-general-start"
483 }
484 ]
485 },
486 "tags-name": {
487 "patterns": [
488 {
489 "match": "[A-Z][a-zA-Z0-9_]*",
490 "name": "support.class.component.astro"
491 },
492 {
493 "match": "[a-z][\\w0-9:]*-[\\w0-9:-]*",
494 "name": "meta.tag.custom.astro entity.name.tag.astro"
495 },
496 {
497 "match": "[a-z][\\w0-9:-]*",
498 "name": "entity.name.tag.astro"
499 }
500 ]
501 },
502 "tags-start-attributes": {
503 "begin": "\\G",
504 "end": "(?=/?>)",
505 "name": "meta.tag.start.astro",
506 "patterns": [
507 {
508 "include": "#attributes"
509 }
510 ]
511 },
512 "tags-lang-start-attributes": {
513 "begin": "\\G",
514 "end": "(?=/>)|>",
515 "endCaptures": {
516 "0": {
517 "name": "punctuation.definition.tag.end.astro"
518 }
519 },
520 "name": "meta.tag.start.astro",
521 "patterns": [
522 {
523 "include": "#attributes"
524 }
525 ]
526 },
527 "tags-start-node": {
528 "match": "(<)([^/\\s>/]*)",
529 "captures": {
530 "1": {
531 "name": "punctuation.definition.tag.begin.astro"
532 },
533 "2": {
534 "patterns": [
535 {
536 "include": "#tags-name"
537 }
538 ]
539 }
540 },
541 "name": "meta.tag.start.astro"
542 },
543 "tags-end-node": {
544 "match": "(</)(.*?)\\s*(>)|(/>)",
545 "captures": {
546 "1": {
547 "name": "meta.tag.end.astro punctuation.definition.tag.begin.astro"
548 },
549 "2": {
550 "name": "meta.tag.end.astro",
551 "patterns": [
552 {
553 "include": "#tags-name"
554 }
555 ]
556 },
557 "3": {
558 "name": "meta.tag.end.astro punctuation.definition.tag.end.astro"
559 },
560 "4": {
561 "name": "meta.tag.start.astro punctuation.definition.tag.end.astro"
562 }
563 }
564 },
565 "tags-raw": {
566 "begin": "<([^/?!\\s<>]+)(?=[^>]+is:raw).*?",
567 "beginCaptures": {
568 "0": {
569 "patterns": [
570 {
571 "include": "#tags-start-node"
572 }
573 ]
574 }
575 },
576 "end": "</\\1\\s*>|/>",
577 "endCaptures": {
578 "0": {
579 "patterns": [
580 {
581 "include": "#tags-end-node"
582 }
583 ]
584 }
585 },
586 "name": "meta.scope.tag.$1.astro meta.raw.astro",
587 "contentName": "source.unknown",
588 "patterns": [
589 {
590 "include": "#tags-lang-start-attributes"
591 }
592 ]
593 },
594 "tags-lang": {
595 "begin": "<(script|style)",
596 "end": "</\\1\\s*>|/>",
597 "beginCaptures": {
598 "0": {
599 "patterns": [
600 {
601 "include": "#tags-start-node"
602 }
603 ]
604 }
605 },
606 "endCaptures": {
607 "0": {
608 "patterns": [
609 {
610 "include": "#tags-end-node"
611 }
612 ]
613 }
614 },
615 "name": "meta.scope.tag.$1.astro meta.$1.astro",
616 "patterns": [
617 {
618 "begin": "\\G(?=\\s*[^>]*?(type|lang)\\s*=\\s*(['\"]|)(?:text\\/)?(application\\/ld\\+json)\\2)",
619 "end": "(?=</|/>)",
620 "name": "meta.lang.json.astro",
621 "patterns": [
622 {
623 "include": "#tags-lang-start-attributes"
624 }
625 ]
626 },
627 {
628 "begin": "\\G(?=\\s*[^>]*?(type|lang)\\s*=\\s*(['\"]|)(module)\\2)",
629 "end": "(?=</|/>)",
630 "name": "meta.lang.javascript.astro",
631 "patterns": [
632 {
633 "include": "#tags-lang-start-attributes"
634 }
635 ]
636 },
637 {
638 "begin": "\\G(?=\\s*[^>]*?(type|lang)\\s*=\\s*(['\"]|)(?:text/|application/)?([\\w\\/+]+)\\2)",
639 "end": "(?=</|/>)",
640 "name": "meta.lang.$3.astro",
641 "patterns": [
642 {
643 "include": "#tags-lang-start-attributes"
644 }
645 ]
646 },
647 {
648 "include": "#tags-lang-start-attributes"
649 }
650 ]
651 },
652 "tags-void": {
653 "begin": "(<)(area|base|br|col|embed|hr|img|input|link|meta|param|source|track|wbr)(?=\\s|/?>)",
654 "beginCaptures": {
655 "1": {
656 "name": "punctuation.definition.tag.begin.astro"
657 },
658 "2": {
659 "name": "entity.name.tag.astro"
660 }
661 },
662 "end": "/?>",
663 "endCaptures": {
664 "0": {
665 "name": "punctuation.definition.tag.begin.astro"
666 }
667 },
668 "name": "meta.tag.void.astro",
669 "patterns": [
670 {
671 "include": "#attributes"
672 }
673 ]
674 },
675 "tags-general-start": {
676 "begin": "(<)([^/\\s>/]*)",
677 "end": "(/?>)",
678 "beginCaptures": {
679 "0": {
680 "patterns": [
681 {
682 "include": "#tags-start-node"
683 }
684 ]
685 }
686 },
687 "endCaptures": {
688 "1": {
689 "name": "meta.tag.start.astro punctuation.definition.tag.end.astro"
690 }
691 },
692 "name": "meta.scope.tag.$2.astro",
693 "patterns": [
694 {
695 "include": "#tags-start-attributes"
696 }
697 ]
698 },
699 "tags-general-end": {
700 "begin": "(</)([^/\\s>]*)",
701 "end": "(>)",
702 "beginCaptures": {
703 "1": {
704 "name": "meta.tag.end.astro punctuation.definition.tag.begin.astro"
705 },
706 "2": {
707 "name": "meta.tag.end.astro",
708 "patterns": [
709 {
710 "include": "#tags-name"
711 }
712 ]
713 }
714 },
715 "endCaptures": {
716 "1": {
717 "name": "meta.tag.end.astro punctuation.definition.tag.end.astro"
718 }
719 },
720 "name": "meta.scope.tag.$2.astro"
721 }
722 }
723 }
724