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 / twig.tmLanguage.json

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

1,373 lines 34.5 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 {
2 "fileTypes": ["twig", "html.twig"],
3 "firstLineMatch": "<!(?i:DOCTYPE)|<(?i:html)|<\\?(?i:php)|\\{\\{|\\{%|\\{#",
4 "foldingStartMarker": "(?x)\n (<(?i:body|div|dl|fieldset|form|head|li|ol|script|select|style|table|tbody|tfoot|thead|tr|ul)\\b.*?>\n |<!--(?!.*--\\s*>)\n |^<!--\\ \\#tminclude\\ (?>.*?-->)$\n |\\{%\\s+(autoescape|block|embed|filter|for|if|macro|raw|sandbox|set|spaceless|trans|verbatim)\n )",
5 "foldingStopMarker": "(?x)\n (</(?i:body|div|dl|fieldset|form|head|li|ol|script|select|style|table|tbody|tfoot|thead|tr|ul)>\n |^(?!.*?<!--).*?--\\s*>\n |^<!--\\ end\\ tminclude\\ -->$\n |\\{%\\s+end(autoescape|block|embed|filter|for|if|macro|raw|sandbox|set|spaceless|trans|verbatim)\n )",
6 "keyEquivalent": "^~T",
7 "name": "twig",
8 "patterns": [
9 {
10 "begin": "(<)([a-zA-Z0-9:]++)(?=[^>]*></\\2>)",
11 "beginCaptures": {
12 "1": {
13 "name": "punctuation.definition.tag.html"
14 },
15 "2": {
16 "name": "entity.name.tag.html"
17 }
18 },
19 "end": "(>(<)/)(\\2)(>)",
20 "endCaptures": {
21 "1": {
22 "name": "punctuation.definition.tag.html"
23 },
24 "2": {
25 "name": "meta.scope.between-tag-pair.html"
26 },
27 "3": {
28 "name": "entity.name.tag.html"
29 },
30 "4": {
31 "name": "punctuation.definition.tag.html"
32 }
33 },
34 "name": "meta.tag.any.html",
35 "patterns": [
36 {
37 "include": "#tag-stuff"
38 }
39 ]
40 },
41 {
42 "begin": "(<\\?)(xml)",
43 "captures": {
44 "1": {
45 "name": "punctuation.definition.tag.html"
46 },
47 "2": {
48 "name": "entity.name.tag.xml.html"
49 }
50 },
51 "end": "(\\?>)",
52 "name": "meta.tag.preprocessor.xml.html",
53 "patterns": [
54 {
55 "include": "#tag-generic-attribute"
56 },
57 {
58 "include": "#string-double-quoted"
59 },
60 {
61 "include": "#string-single-quoted"
62 }
63 ]
64 },
65 {
66 "begin": "<!--",
67 "captures": {
68 "0": {
69 "name": "punctuation.definition.comment.html"
70 }
71 },
72 "end": "--\\s*>",
73 "name": "comment.block.html",
74 "patterns": [
75 {
76 "match": "--",
77 "name": "invalid.illegal.bad-comments-or-CDATA.html"
78 },
79 {
80 "include": "#embedded-code"
81 }
82 ]
83 },
84 {
85 "begin": "<!",
86 "captures": {
87 "0": {
88 "name": "punctuation.definition.tag.html"
89 }
90 },
91 "end": ">",
92 "name": "meta.tag.sgml.html",
93 "patterns": [
94 {
95 "begin": "(?i:DOCTYPE)",
96 "captures": {
97 "1": {
98 "name": "entity.name.tag.doctype.html"
99 }
100 },
101 "end": "(?=>)",
102 "name": "meta.tag.sgml.doctype.html",
103 "patterns": [
104 {
105 "match": "\"[^\">]*\"",
106 "name": "string.quoted.double.doctype.identifiers-and-DTDs.html"
107 }
108 ]
109 },
110 {
111 "begin": "\\[CDATA\\[",
112 "end": "]](?=>)",
113 "name": "constant.other.inline-data.html"
114 },
115 {
116 "match": "(\\s*)(?!--|>)\\S(\\s*)",
117 "name": "invalid.illegal.bad-comments-or-CDATA.html"
118 }
119 ]
120 },
121 {
122 "include": "#embedded-code"
123 },
124 {
125 "begin": "(?:^\\s+)?(<)((?i:style))\\b(?![^>]*/>)",
126 "captures": {
127 "1": {
128 "name": "punctuation.definition.tag.html"
129 },
130 "2": {
131 "name": "entity.name.tag.style.html"
132 },
133 "3": {
134 "name": "punctuation.definition.tag.html"
135 }
136 },
137 "end": "(</)((?i:style))(>)(?:\\s*\\n)?",
138 "name": "source.css.embedded.html",
139 "patterns": [
140 {
141 "include": "#tag-stuff"
142 },
143 {
144 "begin": "(>)",
145 "beginCaptures": {
146 "1": {
147 "name": "punctuation.definition.tag.html"
148 }
149 },
150 "end": "(?=</(?i:style))",
151 "patterns": [
152 {
153 "include": "#embedded-code"
154 },
155 {
156 "include": "source.css"
157 }
158 ]
159 }
160 ]
161 },
162 {
163 "begin": "(?:^\\s+)?(<)((?i:script))\\b(?![^>]*/>)",
164 "beginCaptures": {
165 "1": {
166 "name": "punctuation.definition.tag.html"
167 },
168 "2": {
169 "name": "entity.name.tag.script.html"
170 }
171 },
172 "end": "(?<=</(script|SCRIPT))(>)(?:\\s*\\n)?",
173 "endCaptures": {
174 "2": {
175 "name": "punctuation.definition.tag.html"
176 }
177 },
178 "name": "source.js.embedded.html",
179 "patterns": [
180 {
181 "include": "#tag-stuff"
182 },
183 {
184 "begin": "(?<!</(?:script|SCRIPT))(>)",
185 "captures": {
186 "1": {
187 "name": "punctuation.definition.tag.html"
188 },
189 "2": {
190 "name": "entity.name.tag.script.html"
191 }
192 },
193 "end": "(</)((?i:script))",
194 "patterns": [
195 {
196 "captures": {
197 "1": {
198 "name": "punctuation.definition.comment.js"
199 }
200 },
201 "match": "(//).*?((?=</script)|$\\n?)",
202 "name": "comment.line.double-slash.js"
203 },
204 {
205 "begin": "/\\*",
206 "captures": {
207 "0": {
208 "name": "punctuation.definition.comment.js"
209 }
210 },
211 "end": "\\*/|(?=</script)",
212 "name": "comment.block.js"
213 },
214 {
215 "include": "#php"
216 },
217 {
218 "include": "#twig-print-tag"
219 },
220 {
221 "include": "#twig-statement-tag"
222 },
223 {
224 "include": "#twig-comment-tag"
225 },
226 {
227 "include": "source.js"
228 }
229 ]
230 }
231 ]
232 },
233 {
234 "begin": "(?ix) # Enable free spacing mode, case insensitive\n # Make sure our opening js tag has word boundaries\n (?<=\\{\\%\\sjs\\s\\%\\}|\\{\\%\\sincludejs\\s\\%\\})\n ",
235 "comment": "Add JS support to set tags that use the pattern \"css\" in their name",
236 "end": "(?ix)(?=\\{\\%\\sendjs\\s\\%\\}|\\{\\%\\sendincludejs\\s\\%\\})",
237 "name": "source.js.embedded.twig",
238 "patterns": [
239 {
240 "include": "source.js"
241 }
242 ]
243 },
244 {
245 "begin": "(?ix) # Enable free spacing mode, case insensitive\n (?<=\\{\\%\\scss\\s\\%\\}|\\{\\%\\sincludecss\\s\\%\\}|\\{\\%\\sincludehirescss\\s\\%\\})\n ",
246 "comment": "Add CSS support to set tags that use the pattern \"css\" in their name",
247 "end": "(?ix)(?=\\{\\%\\sendcss\\s\\%\\}|\\{\\%\\sendincludecss\\s\\%\\}|\\{\\%\\sendincludehirescss\\s\\%\\})",
248 "name": "source.css.embedded.twig",
249 "patterns": [
250 {
251 "include": "source.css"
252 }
253 ]
254 },
255 {
256 "begin": "(</?)((?i:body|head|html)\\b)",
257 "captures": {
258 "1": {
259 "name": "punctuation.definition.tag.html"
260 },
261 "2": {
262 "name": "entity.name.tag.structure.any.html"
263 }
264 },
265 "end": "(>)",
266 "name": "meta.tag.structure.any.html",
267 "patterns": [
268 {
269 "include": "#tag-stuff"
270 }
271 ]
272 },
273 {
274 "begin": "(</?)((?i:address|blockquote|dd|div|dl|dt|fieldset|form|frame|frameset|h1|h2|h3|h4|h5|h6|iframe|noframes|object|ol|p|ul|applet|center|dir|hr|menu|pre)\\b)",
275 "beginCaptures": {
276 "1": {
277 "name": "punctuation.definition.tag.begin.html"
278 },
279 "2": {
280 "name": "entity.name.tag.block.any.html"
281 }
282 },
283 "end": "(>)",
284 "endCaptures": {
285 "1": {
286 "name": "punctuation.definition.tag.end.html"
287 }
288 },
289 "name": "meta.tag.block.any.html",
290 "patterns": [
291 {
292 "include": "#tag-stuff"
293 }
294 ]
295 },
296 {
297 "begin": "(</?)((?i:a|abbr|acronym|area|b|base|basefont|bdo|big|br|button|caption|cite|code|col|colgroup|del|dfn|em|font|head|html|i|img|input|ins|isindex|kbd|label|legend|li|link|map|meta|noscript|optgroup|option|param|q|s|samp|script|select|small|span|strike|strong|style|sub|sup|table|tbody|td|textarea|tfoot|th|thead|title|tr|tt|u|var)\\b)",
298 "beginCaptures": {
299 "1": {
300 "name": "punctuation.definition.tag.begin.html"
301 },
302 "2": {
303 "name": "entity.name.tag.inline.any.html"
304 }
305 },
306 "end": "((?: ?/)?>)",
307 "endCaptures": {
308 "1": {
309 "name": "punctuation.definition.tag.end.html"
310 }
311 },
312 "name": "meta.tag.inline.any.html",
313 "patterns": [
314 {
315 "include": "#tag-stuff"
316 }
317 ]
318 },
319 {
320 "begin": "(</?)([a-zA-Z0-9:]+)",
321 "beginCaptures": {
322 "1": {
323 "name": "punctuation.definition.tag.begin.html"
324 },
325 "2": {
326 "name": "entity.name.tag.other.html"
327 }
328 },
329 "end": "(>)",
330 "endCaptures": {
331 "1": {
332 "name": "punctuation.definition.tag.end.html"
333 }
334 },
335 "name": "meta.tag.other.html",
336 "patterns": [
337 {
338 "include": "#tag-stuff"
339 }
340 ]
341 },
342 {
343 "include": "#entities"
344 },
345 {
346 "match": "<>",
347 "name": "invalid.illegal.incomplete.html"
348 },
349 {
350 "match": "<",
351 "name": "invalid.illegal.bad-angle-bracket.html"
352 },
353 {
354 "include": "#twig-print-tag"
355 },
356 {
357 "include": "#twig-statement-tag"
358 },
359 {
360 "include": "#twig-comment-tag"
361 }
362 ],
363 "repository": {
364 "embedded-code": {
365 "patterns": [
366 {
367 "include": "#ruby"
368 },
369 {
370 "include": "#php"
371 },
372 {
373 "include": "#twig-print-tag"
374 },
375 {
376 "include": "#twig-statement-tag"
377 },
378 {
379 "include": "#twig-comment-tag"
380 },
381 {
382 "include": "#python"
383 }
384 ]
385 },
386 "entities": {
387 "patterns": [
388 {
389 "captures": {
390 "1": {
391 "name": "punctuation.definition.entity.html"
392 },
393 "3": {
394 "name": "punctuation.definition.entity.html"
395 }
396 },
397 "match": "(&)([a-zA-Z0-9]+|#[0-9]+|#x[0-9a-fA-F]+)(;)",
398 "name": "constant.character.entity.html"
399 },
400 {
401 "match": "&",
402 "name": "invalid.illegal.bad-ampersand.html"
403 }
404 ]
405 },
406 "twig-print-tag": {
407 "begin": "\\{\\{-?",
408 "beginCaptures": {
409 "0": {
410 "name": "punctuation.section.tag.twig"
411 }
412 },
413 "end": "-?\\}\\}",
414 "endCaptures": {
415 "0": {
416 "name": "punctuation.section.tag.twig"
417 }
418 },
419 "name": "meta.tag.template.value.twig",
420 "patterns": [
421 {
422 "include": "#twig-constants"
423 },
424 {
425 "include": "#twig-operators"
426 },
427 {
428 "include": "#twig-functions-warg"
429 },
430 {
431 "include": "#twig-functions"
432 },
433 {
434 "include": "#twig-macros"
435 },
436 {
437 "include": "#twig-objects"
438 },
439 {
440 "include": "#twig-properties"
441 },
442 {
443 "include": "#twig-filters-warg"
444 },
445 {
446 "include": "#twig-filters"
447 },
448 {
449 "include": "#twig-filters-warg-ud"
450 },
451 {
452 "include": "#twig-filters-ud"
453 },
454 {
455 "include": "#twig-strings"
456 },
457 {
458 "include": "#twig-arrays"
459 },
460 {
461 "include": "#twig-hashes"
462 }
463 ]
464 },
465 "twig-statement-tag": {
466 "begin": "\\{%-?",
467 "beginCaptures": {
468 "0": {
469 "name": "punctuation.section.tag.twig"
470 }
471 },
472 "end": "-?%\\}",
473 "endCaptures": {
474 "0": {
475 "name": "punctuation.section.tag.twig"
476 }
477 },
478 "name": "meta.tag.template.block.twig",
479 "patterns": [
480 {
481 "include": "#twig-constants"
482 },
483 {
484 "include": "#twig-keywords"
485 },
486 {
487 "include": "#twig-operators"
488 },
489 {
490 "include": "#twig-functions-warg"
491 },
492 {
493 "include": "#twig-functions"
494 },
495 {
496 "include": "#twig-macros"
497 },
498 {
499 "include": "#twig-filters-warg"
500 },
501 {
502 "include": "#twig-filters"
503 },
504 {
505 "include": "#twig-filters-warg-ud"
506 },
507 {
508 "include": "#twig-filters-ud"
509 },
510 {
511 "include": "#twig-objects"
512 },
513 {
514 "include": "#twig-properties"
515 },
516 {
517 "include": "#twig-strings"
518 },
519 {
520 "include": "#twig-arrays"
521 },
522 {
523 "include": "#twig-hashes"
524 }
525 ]
526 },
527 "twig-comment-tag": {
528 "begin": "\\{#-?",
529 "beginCaptures": {
530 "0": {
531 "name": "punctuation.definition.comment.begin.twig"
532 }
533 },
534 "end": "-?#\\}",
535 "endCaptures": {
536 "0": {
537 "name": "punctuation.definition.comment.end.twig"
538 }
539 },
540 "name": "comment.block.twig"
541 },
542 "twig-constants": {
543 "patterns": [
544 {
545 "match": "(?i)(?<=[\\s\\[\\(\\{:,])(?:true|false|null|none)(?=[\\s\\)\\]\\}\\,])",
546 "name": "constant.language.twig"
547 },
548 {
549 "match": "(?<=[\\s\\[\\(\\{:,]|\\.\\.|\\*\\*)[0-9]+(?:\\.[0-9]+)?(?=[\\s\\)\\]\\}\\,]|\\.\\.|\\*\\*)",
550 "name": "constant.numeric.twig"
551 }
552 ]
553 },
554 "twig-operators": {
555 "patterns": [
556 {
557 "captures": {
558 "1": {
559 "name": "keyword.operator.arithmetic.twig"
560 }
561 },
562 "match": "(?<=\\s)(\\+|-|//?|%|\\*\\*?)(?=\\s)"
563 },
564 {
565 "captures": {
566 "1": {
567 "name": "keyword.operator.assignment.twig"
568 }
569 },
570 "match": "(?<=\\s)(=|~)(?=\\s)"
571 },
572 {
573 "captures": {
574 "1": {
575 "name": "keyword.operator.bitwise.twig"
576 }
577 },
578 "match": "(?<=\\s)(b-(?:and|or|xor))(?=\\s)"
579 },
580 {
581 "captures": {
582 "1": {
583 "name": "keyword.operator.comparison.twig"
584 }
585 },
586 "match": "(?<=\\s)((?:!|=)=|<=?|>=?|(?:not )?in|is(?: not)?|(?:ends|starts) with|matches)(?=\\s)"
587 },
588 {
589 "captures": {
590 "1": {
591 "name": "keyword.operator.logical.twig"
592 }
593 },
594 "match": "(?<=\\s)(\\?|:|and|not|or)(?=\\s)"
595 },
596 {
597 "captures": {
598 "0": {
599 "name": "keyword.operator.other.twig"
600 }
601 },
602 "match": "(?<=[a-zA-Z0-9_\\x{7f}-\\x{ff}\\]\\)'\"])\\.\\.(?=[a-zA-Z0-9_\\x{7f}-\\x{ff}'\"])"
603 },
604 {
605 "captures": {
606 "0": {
607 "name": "keyword.operator.other.twig"
608 }
609 },
610 "match": "(?<=[a-zA-Z0-9_\\x{7f}-\\x{ff}\\]\\}\\)'\"])\\|(?=[a-zA-Z_\\x{7f}-\\x{ff}])"
611 }
612 ]
613 },
614 "twig-objects": {
615 "captures": {
616 "1": {
617 "name": "variable.other.twig"
618 }
619 },
620 "match": "(?<=[\\s\\{\\[\\(:,])([a-zA-Z_\\x{7f}-\\x{ff}][a-zA-Z0-9_\\x{7f}-\\x{ff}]*)(?=[\\s\\}\\[\\]\\(\\)\\.\\|,:])"
621 },
622 "twig-properties": {
623 "patterns": [
624 {
625 "captures": {
626 "1": {
627 "name": "punctuation.separator.property.twig"
628 },
629 "2": {
630 "name": "variable.other.property.twig"
631 }
632 },
633 "match": "(?x)\n (?<=[a-zA-Z0-9_\\x{7f}-\\x{ff}])\n (\\.)([a-zA-Z_\\x{7f}-\\x{ff}][a-zA-Z0-9_\\x{7f}-\\x{ff}]*)\n (?=[\\.\\s\\|\\[\\)\\]\\}:,])\n "
634 },
635 {
636 "begin": "(?x)\n (?<=[a-zA-Z0-9_\\x{7f}-\\x{ff}])\n (\\.)([a-zA-Z_\\x{7f}-\\x{ff}][a-zA-Z0-9_\\x{7f}-\\x{ff}]*)\n (\\()\n ",
637 "beginCaptures": {
638 "1": {
639 "name": "punctuation.separator.property.twig"
640 },
641 "2": {
642 "name": "variable.other.property.twig"
643 },
644 "3": {
645 "name": "punctuation.definition.parameters.begin.twig"
646 }
647 },
648 "end": "\\)",
649 "endCaptures": {
650 "0": {
651 "name": "punctuation.definition.parameters.end.twig"
652 }
653 },
654 "patterns": [
655 {
656 "include": "#twig-constants"
657 },
658 {
659 "include": "#twig-functions-warg"
660 },
661 {
662 "include": "#twig-functions"
663 },
664 {
665 "include": "#twig-macros"
666 },
667 {
668 "include": "#twig-objects"
669 },
670 {
671 "include": "#twig-properties"
672 },
673 {
674 "include": "#twig-filters-warg"
675 },
676 {
677 "include": "#twig-filters"
678 },
679 {
680 "include": "#twig-filters-warg-ud"
681 },
682 {
683 "include": "#twig-filters-ud"
684 },
685 {
686 "include": "#twig-strings"
687 },
688 {
689 "include": "#twig-arrays"
690 }
691 ],
692 "contentName": "meta.function.arguments.twig"
693 },
694 {
695 "captures": {
696 "1": {
697 "name": "punctuation.section.array.begin.twig"
698 },
699 "2": {
700 "name": "variable.other.property.twig"
701 },
702 "3": {
703 "name": "punctuation.section.array.end.twig"
704 },
705 "4": {
706 "name": "punctuation.section.array.begin.twig"
707 },
708 "5": {
709 "name": "variable.other.property.twig"
710 },
711 "6": {
712 "name": "punctuation.section.array.end.twig"
713 },
714 "7": {
715 "name": "punctuation.section.array.begin.twig"
716 },
717 "8": {
718 "name": "variable.other.property.twig"
719 },
720 "9": {
721 "name": "punctuation.section.array.end.twig"
722 }
723 },
724 "match": "(?x)\n (?<=[a-zA-Z0-9_\\x{7f}-\\x{ff}\\]])\n (?:\n (\\[)('[a-zA-Z_\\x{7f}-\\x{ff}][a-zA-Z0-9_\\x{7f}-\\x{ff}]*')(\\])\n |(\\[)(\"[a-zA-Z_\\x{7f}-\\x{ff}][a-zA-Z0-9_\\x{7f}-\\x{ff}]*\")(\\])\n |(\\[)([a-zA-Z_\\x{7f}-\\x{ff}][a-zA-Z0-9_\\x{7f}-\\x{ff}]*)(\\])\n )\n "
725 }
726 ]
727 },
728 "twig-strings": {
729 "patterns": [
730 {
731 "begin": "(?:(?<!\\\\)|(?<=\\\\\\\\))'",
732 "beginCaptures": {
733 "0": {
734 "name": "punctuation.definition.string.begin.twig"
735 }
736 },
737 "end": "(?:(?<!\\\\)|(?<=\\\\\\\\))'",
738 "endCaptures": {
739 "0": {
740 "name": "punctuation.definition.string.end.twig"
741 }
742 },
743 "name": "string.quoted.single.twig"
744 },
745 {
746 "begin": "(?:(?<!\\\\)|(?<=\\\\\\\\))\"",
747 "beginCaptures": {
748 "0": {
749 "name": "punctuation.definition.string.begin.twig"
750 }
751 },
752 "end": "(?:(?<!\\\\)|(?<=\\\\\\\\))\"",
753 "endCaptures": {
754 "0": {
755 "name": "punctuation.definition.string.end.twig"
756 }
757 },
758 "name": "string.quoted.double.twig"
759 }
760 ]
761 },
762 "twig-arrays": {
763 "begin": "(?<=[\\s\\(\\{\\[:,])\\[",
764 "beginCaptures": {
765 "0": {
766 "name": "punctuation.section.array.begin.twig"
767 }
768 },
769 "end": "\\]",
770 "endCaptures": {
771 "0": {
772 "name": "punctuation.section.array.end.twig"
773 }
774 },
775 "patterns": [
776 {
777 "include": "#twig-arrays"
778 },
779 {
780 "include": "#twig-hashes"
781 },
782 {
783 "include": "#twig-constants"
784 },
785 {
786 "include": "#twig-strings"
787 },
788 {
789 "include": "#twig-functions-warg"
790 },
791 {
792 "include": "#twig-functions"
793 },
794 {
795 "include": "#twig-macros"
796 },
797 {
798 "include": "#twig-objects"
799 },
800 {
801 "include": "#twig-properties"
802 },
803 {
804 "include": "#twig-filters-warg"
805 },
806 {
807 "include": "#twig-filters"
808 },
809 {
810 "include": "#twig-filters-warg-ud"
811 },
812 {
813 "include": "#twig-filters-ud"
814 },
815 {
816 "match": ",",
817 "name": "punctuation.separator.object.twig"
818 }
819 ],
820 "name": "meta.array.twig"
821 },
822 "twig-hashes": {
823 "begin": "(?<=[\\s\\(\\{\\[:,])\\{",
824 "beginCaptures": {
825 "0": {
826 "name": "punctuation.section.hash.begin.twig"
827 }
828 },
829 "end": "\\}",
830 "endCaptures": {
831 "0": {
832 "name": "punctuation.section.hash.end.twig"
833 }
834 },
835 "patterns": [
836 {
837 "include": "#twig-hashes"
838 },
839 {
840 "include": "#twig-arrays"
841 },
842 {
843 "include": "#twig-constants"
844 },
845 {
846 "include": "#twig-strings"
847 },
848 {
849 "include": "#twig-functions-warg"
850 },
851 {
852 "include": "#twig-functions"
853 },
854 {
855 "include": "#twig-macros"
856 },
857 {
858 "include": "#twig-objects"
859 },
860 {
861 "include": "#twig-properties"
862 },
863 {
864 "include": "#twig-filters-warg"
865 },
866 {
867 "include": "#twig-filters"
868 },
869 {
870 "include": "#twig-filters-warg-ud"
871 },
872 {
873 "include": "#twig-filters-ud"
874 },
875 {
876 "match": ":",
877 "name": "punctuation.separator.key-value.twig"
878 },
879 {
880 "match": ",",
881 "name": "punctuation.separator.object.twig"
882 }
883 ],
884 "name": "meta.hash.twig"
885 },
886 "twig-keywords": {
887 "match": "(?<=\\s)((?:end)?(?:autoescape|block|embed|filter|for|if|macro|raw|sandbox|set|spaceless|trans|verbatim)|as|do|else|elseif|extends|flush|from|ignore missing|import|include|only|use|with)(?=\\s)",
888 "name": "keyword.control.twig"
889 },
890 "twig-functions-warg": {
891 "begin": "(?<=[\\s\\(\\[\\{:,])(attribute|block|constant|cycle|date|divisible by|dump|include|max|min|parent|random|range|same as|source|template_from_string)(\\()",
892 "beginCaptures": {
893 "1": {
894 "name": "support.function.twig"
895 },
896 "2": {
897 "name": "punctuation.definition.parameters.begin.twig"
898 }
899 },
900 "end": "\\)",
901 "endCaptures": {
902 "0": {
903 "name": "punctuation.definition.parameters.end.twig"
904 }
905 },
906 "patterns": [
907 {
908 "include": "#twig-constants"
909 },
910 {
911 "include": "#twig-functions-warg"
912 },
913 {
914 "include": "#twig-functions"
915 },
916 {
917 "include": "#twig-macros"
918 },
919 {
920 "include": "#twig-objects"
921 },
922 {
923 "include": "#twig-properties"
924 },
925 {
926 "include": "#twig-filters-warg"
927 },
928 {
929 "include": "#twig-filters"
930 },
931 {
932 "include": "#twig-filters-warg-ud"
933 },
934 {
935 "include": "#twig-filters-ud"
936 },
937 {
938 "include": "#twig-strings"
939 },
940 {
941 "include": "#twig-arrays"
942 }
943 ],
944 "contentName": "meta.function.arguments.twig"
945 },
946 "twig-functions": {
947 "captures": {
948 "1": {
949 "name": "support.function.twig"
950 }
951 },
952 "match": "(?<=is\\s)(defined|empty|even|iterable|odd)"
953 },
954 "twig-macros": {
955 "begin": "(?x)\n (?<=[\\s\\(\\[\\{:,])\n ([a-zA-Z_\\x{7f}-\\x{ff}][a-zA-Z0-9_\\x{7f}-\\x{ff}]*)\n (?:\n (\\.)([a-zA-Z_\\x{7f}-\\x{ff}][a-zA-Z0-9_\\x{7f}-\\x{ff}]*)\n )?\n (\\()\n ",
956 "beginCaptures": {
957 "1": {
958 "name": "meta.function-call.twig"
959 },
960 "2": {
961 "name": "punctuation.separator.property.twig"
962 },
963 "3": {
964 "name": "variable.other.property.twig"
965 },
966 "4": {
967 "name": "punctuation.definition.parameters.begin.twig"
968 }
969 },
970 "end": "\\)",
971 "endCaptures": {
972 "0": {
973 "name": "punctuation.definition.parameters.end.twig"
974 }
975 },
976 "patterns": [
977 {
978 "include": "#twig-constants"
979 },
980 {
981 "include": "#twig-operators"
982 },
983 {
984 "include": "#twig-functions-warg"
985 },
986 {
987 "include": "#twig-functions"
988 },
989 {
990 "include": "#twig-macros"
991 },
992 {
993 "include": "#twig-objects"
994 },
995 {
996 "include": "#twig-properties"
997 },
998 {
999 "include": "#twig-filters-warg"
1000 },
1001 {
1002 "include": "#twig-filters"
1003 },
1004 {
1005 "include": "#twig-filters-warg-ud"
1006 },
1007 {
1008 "include": "#twig-filters-ud"
1009 },
1010 {
1011 "include": "#twig-strings"
1012 },
1013 {
1014 "include": "#twig-arrays"
1015 },
1016 {
1017 "include": "#twig-hashes"
1018 }
1019 ],
1020 "contentName": "meta.function.arguments.twig"
1021 },
1022 "twig-filters-warg": {
1023 "begin": "(?<=(?:[a-zA-Z0-9_\\x{7f}-\\x{ff}\\]\\)\\'\\\"]\\|)|\\{%\\sfilter\\s)(batch|convert_encoding|date|date_modify|default|e(?:scape)?|format|join|merge|number_format|replace|round|slice|split|trim)(\\()",
1024 "beginCaptures": {
1025 "1": {
1026 "name": "support.function.twig"
1027 },
1028 "2": {
1029 "name": "punctuation.definition.parameters.begin.twig"
1030 }
1031 },
1032 "end": "\\)",
1033 "endCaptures": {
1034 "0": {
1035 "name": "punctuation.definition.parameters.end.twig"
1036 }
1037 },
1038 "patterns": [
1039 {
1040 "include": "#twig-constants"
1041 },
1042 {
1043 "include": "#twig-functions-warg"
1044 },
1045 {
1046 "include": "#twig-functions"
1047 },
1048 {
1049 "include": "#twig-macros"
1050 },
1051 {
1052 "include": "#twig-objects"
1053 },
1054 {
1055 "include": "#twig-properties"
1056 },
1057 {
1058 "include": "#twig-filters-warg"
1059 },
1060 {
1061 "include": "#twig-filters"
1062 },
1063 {
1064 "include": "#twig-filters-warg-ud"
1065 },
1066 {
1067 "include": "#twig-filters-ud"
1068 },
1069 {
1070 "include": "#twig-strings"
1071 },
1072 {
1073 "include": "#twig-arrays"
1074 },
1075 {
1076 "include": "#twig-hashes"
1077 }
1078 ],
1079 "contentName": "meta.function.arguments.twig"
1080 },
1081 "twig-filters": {
1082 "captures": {
1083 "1": {
1084 "name": "support.function.twig"
1085 }
1086 },
1087 "match": "(?<=(?:[a-zA-Z0-9_\\x{7f}-\\x{ff}\\]\\)\\'\\\"]\\|)|\\{%\\sfilter\\s)(abs|capitalize|e(?:scape)?|first|join|(?:json|url)_encode|keys|last|length|lower|nl2br|number_format|raw|reverse|round|sort|striptags|title|trim|upper)(?=[\\s\\|\\]\\}\\):,]|\\.\\.|\\*\\*)"
1088 },
1089 "twig-filters-warg-ud": {
1090 "begin": "(?<=(?:[a-zA-Z0-9_\\x{7f}-\\x{ff}\\]\\)\\'\\\"]\\|)|\\{%\\sfilter\\s)([a-zA-Z_\\x{7f}-\\x{ff}][a-zA-Z0-9_\\x{7f}-\\x{ff}]*)(\\()",
1091 "beginCaptures": {
1092 "1": {
1093 "name": "meta.function-call.other.twig"
1094 },
1095 "2": {
1096 "name": "punctuation.definition.parameters.begin.twig"
1097 }
1098 },
1099 "end": "\\)",
1100 "endCaptures": {
1101 "0": {
1102 "name": "punctuation.definition.parameters.end.twig"
1103 }
1104 },
1105 "patterns": [
1106 {
1107 "include": "#twig-constants"
1108 },
1109 {
1110 "include": "#twig-functions-warg"
1111 },
1112 {
1113 "include": "#twig-functions"
1114 },
1115 {
1116 "include": "#twig-macros"
1117 },
1118 {
1119 "include": "#twig-objects"
1120 },
1121 {
1122 "include": "#twig-properties"
1123 },
1124 {
1125 "include": "#twig-filters-warg"
1126 },
1127 {
1128 "include": "#twig-filters"
1129 },
1130 {
1131 "include": "#twig-filters-warg-ud"
1132 },
1133 {
1134 "include": "#twig-filters-ud"
1135 },
1136 {
1137 "include": "#twig-strings"
1138 },
1139 {
1140 "include": "#twig-arrays"
1141 },
1142 {
1143 "include": "#twig-hashes"
1144 }
1145 ],
1146 "contentName": "meta.function.arguments.twig"
1147 },
1148 "twig-filters-ud": {
1149 "captures": {
1150 "1": {
1151 "name": "meta.function-call.other.twig"
1152 }
1153 },
1154 "match": "(?<=(?:[a-zA-Z0-9_\\x{7f}-\\x{ff}\\]\\)\\'\\\"]\\|)|\\{%\\sfilter\\s)([a-zA-Z_\\x{7f}-\\x{ff}][a-zA-Z0-9_\\x{7f}-\\x{ff}]*)"
1155 },
1156 "php": {
1157 "begin": "(?=(^\\s*)?<\\?)",
1158 "end": "(?!(^\\s*)?<\\?)",
1159 "patterns": [
1160 {
1161 "include": "source.php"
1162 }
1163 ]
1164 },
1165 "python": {
1166 "begin": "(?:^\\s*)<\\?python(?!.*\\?>)",
1167 "end": "\\?>(?:\\s*$\\n)?",
1168 "name": "source.python.embedded.html",
1169 "patterns": [
1170 {
1171 "include": "source.python"
1172 }
1173 ]
1174 },
1175 "ruby": {
1176 "patterns": [
1177 {
1178 "begin": "<%+#",
1179 "captures": {
1180 "0": {
1181 "name": "punctuation.definition.comment.erb"
1182 }
1183 },
1184 "end": "%>",
1185 "name": "comment.block.erb"
1186 },
1187 {
1188 "begin": "<%+(?!>)=?",
1189 "captures": {
1190 "0": {
1191 "name": "punctuation.section.embedded.ruby"
1192 }
1193 },
1194 "end": "-?%>",
1195 "name": "source.ruby.embedded.html",
1196 "patterns": [
1197 {
1198 "captures": {
1199 "1": {
1200 "name": "punctuation.definition.comment.ruby"
1201 }
1202 },
1203 "match": "(#).*?(?=-?%>)",
1204 "name": "comment.line.number-sign.ruby"
1205 },
1206 {
1207 "include": "source.ruby"
1208 }
1209 ]
1210 },
1211 {
1212 "begin": "<\\?r(?!>)=?",
1213 "captures": {
1214 "0": {
1215 "name": "punctuation.section.embedded.ruby.nitro"
1216 }
1217 },
1218 "end": "-?\\?>",
1219 "name": "source.ruby.nitro.embedded.html",
1220 "patterns": [
1221 {
1222 "captures": {
1223 "1": {
1224 "name": "punctuation.definition.comment.ruby.nitro"
1225 }
1226 },
1227 "match": "(#).*?(?=-?\\?>)",
1228 "name": "comment.line.number-sign.ruby.nitro"
1229 },
1230 {
1231 "include": "source.ruby"
1232 }
1233 ]
1234 }
1235 ]
1236 },
1237 "string-double-quoted": {
1238 "begin": "\"",
1239 "beginCaptures": {
1240 "0": {
1241 "name": "punctuation.definition.string.begin.html"
1242 }
1243 },
1244 "end": "\"",
1245 "endCaptures": {
1246 "0": {
1247 "name": "punctuation.definition.string.end.html"
1248 }
1249 },
1250 "name": "string.quoted.double.html",
1251 "patterns": [
1252 {
1253 "include": "#embedded-code"
1254 },
1255 {
1256 "include": "#entities"
1257 }
1258 ]
1259 },
1260 "string-single-quoted": {
1261 "begin": "'",
1262 "beginCaptures": {
1263 "0": {
1264 "name": "punctuation.definition.string.begin.html"
1265 }
1266 },
1267 "end": "'",
1268 "endCaptures": {
1269 "0": {
1270 "name": "punctuation.definition.string.end.html"
1271 }
1272 },
1273 "name": "string.quoted.single.html",
1274 "patterns": [
1275 {
1276 "include": "#embedded-code"
1277 },
1278 {
1279 "include": "#entities"
1280 }
1281 ]
1282 },
1283 "tag-generic-attribute": {
1284 "match": "\\b([a-zA-Z\\-:]+)",
1285 "name": "entity.other.attribute-name.html"
1286 },
1287 "tag-id-attribute": {
1288 "begin": "\\b(id)\\b\\s*(=)",
1289 "captures": {
1290 "1": {
1291 "name": "entity.other.attribute-name.id.html"
1292 },
1293 "2": {
1294 "name": "punctuation.separator.key-value.html"
1295 }
1296 },
1297 "end": "(?<='|\")",
1298 "name": "meta.attribute-with-value.id.html",
1299 "patterns": [
1300 {
1301 "begin": "\"",
1302 "beginCaptures": {
1303 "0": {
1304 "name": "punctuation.definition.string.begin.html"
1305 }
1306 },
1307 "contentName": "meta.toc-list.id.html",
1308 "end": "\"",
1309 "endCaptures": {
1310 "0": {
1311 "name": "punctuation.definition.string.end.html"
1312 }
1313 },
1314 "name": "string.quoted.double.html",
1315 "patterns": [
1316 {
1317 "include": "#embedded-code"
1318 },
1319 {
1320 "include": "#entities"
1321 }
1322 ]
1323 },
1324 {
1325 "begin": "'",
1326 "beginCaptures": {
1327 "0": {
1328 "name": "punctuation.definition.string.begin.html"
1329 }
1330 },
1331 "contentName": "meta.toc-list.id.html",
1332 "end": "'",
1333 "endCaptures": {
1334 "0": {
1335 "name": "punctuation.definition.string.end.html"
1336 }
1337 },
1338 "name": "string.quoted.single.html",
1339 "patterns": [
1340 {
1341 "include": "#embedded-code"
1342 },
1343 {
1344 "include": "#entities"
1345 }
1346 ]
1347 }
1348 ]
1349 },
1350 "tag-stuff": {
1351 "patterns": [
1352 {
1353 "include": "#tag-id-attribute"
1354 },
1355 {
1356 "include": "#tag-generic-attribute"
1357 },
1358 {
1359 "include": "#string-double-quoted"
1360 },
1361 {
1362 "include": "#string-single-quoted"
1363 },
1364 {
1365 "include": "#embedded-code"
1366 }
1367 ]
1368 }
1369 },
1370 "scopeName": "text.html.twig",
1371 "uuid": "C220B028-86FF-44CB-8A59-27937FC83730"
1372 }
1373