Skip to content

Commit f227e50

Browse files
author
deathaxe
committed
ST4126+
1 parent 30efda3 commit f227e50

File tree

1 file changed

+0
-139
lines changed

1 file changed

+0
-139
lines changed

Vue Component.sublime-syntax

-139
Original file line numberDiff line numberDiff line change
@@ -12,41 +12,6 @@ file_extensions:
1212
- wpy
1313

1414
variables:
15-
# CSS specific variables
16-
# ======================
17-
18-
# Embedded script and style syntaxes may be wrapped into html comments for
19-
# historical reasons. The following patterns match them, while maintaining
20-
# correct boundaries of embedded source scopes. That's required to enable
21-
# embedded syntax's comment toggling in the first and last line.
22-
#
23-
# see:
24-
# - https://github.com/sublimehq/Packages/issues/2322
25-
# - https://github.com/sublimehq/sublime_text/issues/4701
26-
script_content_begin: |-
27-
(?x:
28-
# whitespace followed by opening html comment begin punctuation
29-
\s*(<!--)
30-
# or any other non-whitespace character ahead
31-
| (?=\s*(?!<!--)\S)
32-
# or beginning of a line
33-
| ^
34-
)
35-
script_content_end: |-
36-
(?x:
37-
# optional html comment end punctuation followed by </script> tag
38-
(?: (\s*) (-->) \s* )? (?=</(?i:script){{tag_name_break_char}})
39-
# or standalone html comment end punctuation in a line
40-
| ^ (\s*) (-->) \s* $
41-
)
42-
style_content_begin: '{{script_content_begin}}'
43-
style_content_end: |-
44-
(?x:
45-
# optional html comment end punctuation followed by </style> tag
46-
(?: (\s*) (-->) \s* )? (?=</(?i:style){{tag_name_break_char}})
47-
# or standalone html comment end punctuation in a line
48-
| ^ (\s*) (-->) \s* $
49-
)
5015

5116
# Vue specific variables
5217
# ======================
@@ -69,30 +34,11 @@ contexts:
6934

7035
tag-html:
7136
- meta_prepend: true
72-
- include: script-tag
73-
- include: style-tag
7437
- include: i18n-tag
7538
- include: template-tag
7639

7740
###[ SCRIPT TAG ]#############################################################
7841

79-
script-tag:
80-
# required until ST4113
81-
- match: (<)((?i:script)){{tag_name_break}}
82-
captures:
83-
1: punctuation.definition.tag.begin.html
84-
2: entity.name.tag.script.html
85-
push: script-javascript
86-
- match: (</)((?i:script){{tag_name_break}})
87-
captures:
88-
1: punctuation.definition.tag.begin.html
89-
2: entity.name.tag.script.html
90-
push: script-close-tag-content
91-
92-
script-close-tag-content:
93-
- meta_scope: meta.tag.script.end.html
94-
- include: tag-end
95-
9642
script-common:
9743
- meta_prepend: true
9844
- include: script-lang-attribute
@@ -198,30 +144,6 @@ contexts:
198144
3: source.coffee.embedded.html
199145
4: comment.block.html punctuation.definition.comment.end.html
200146

201-
script-javascript:
202-
# required until ST4113
203-
- meta_scope: meta.tag.script.begin.html
204-
- match: '>'
205-
scope: punctuation.definition.tag.end.html
206-
set: script-javascript-content
207-
- include: script-common
208-
209-
script-javascript-content:
210-
# required until ST4113
211-
- meta_include_prototype: false
212-
- match: '{{script_content_begin}}'
213-
captures:
214-
1: comment.block.html punctuation.definition.comment.begin.html
215-
pop: 1 # make sure to match only once
216-
embed: scope:source.js
217-
embed_scope: source.js.embedded.html
218-
escape: '{{script_content_end}}'
219-
escape_captures:
220-
1: source.js.embedded.html
221-
2: comment.block.html punctuation.definition.comment.end.html
222-
3: source.js.embedded.html
223-
4: comment.block.html punctuation.definition.comment.end.html
224-
225147
script-jsx:
226148
- meta_include_prototype: false
227149
- meta_scope: meta.tag.script.begin.html
@@ -316,23 +238,6 @@ contexts:
316238

317239
###[ STYLE TAG ]##############################################################
318240

319-
style-tag:
320-
# required until ST4113
321-
- match: (<)((?i:style)){{tag_name_break}}
322-
captures:
323-
1: punctuation.definition.tag.begin.html
324-
2: entity.name.tag.style.html
325-
push: style-css
326-
- match: (</)((?i:style){{tag_name_break}})
327-
captures:
328-
1: punctuation.definition.tag.begin.html
329-
2: entity.name.tag.style.html
330-
push: style-close-tag-content
331-
332-
style-close-tag-content:
333-
- meta_scope: meta.tag.style.end.html
334-
- include: tag-end
335-
336241
style-common:
337242
- meta_prepend: true
338243
- include: style-lang-attribute
@@ -392,30 +297,6 @@ contexts:
392297
- tag-lang-attribute-meta
393298
- tag-generic-attribute-value
394299

395-
style-css:
396-
# required until ST4113
397-
- meta_scope: meta.tag.style.begin.html
398-
- match: '>'
399-
scope: punctuation.definition.tag.end.html
400-
set: style-css-content
401-
- include: style-common
402-
403-
style-css-content:
404-
# required until ST4113
405-
- meta_include_prototype: false
406-
- match: '{{style_content_begin}}'
407-
captures:
408-
1: comment.block.html punctuation.definition.comment.begin.html
409-
pop: 1 # make sure to match only once
410-
embed: scope:source.css
411-
embed_scope: source.css.embedded.html
412-
escape: '{{style_content_end}}'
413-
escape_captures:
414-
1: source.css.embedded.html
415-
2: comment.block.html punctuation.definition.comment.end.html
416-
3: source.css.embedded.html
417-
4: comment.block.html punctuation.definition.comment.end.html
418-
419300
style-less:
420301
- meta_scope: meta.tag.style.begin.html
421302
- match: '>'
@@ -701,26 +582,6 @@ contexts:
701582
- meta_prepend: true
702583
- include: vue-directive
703584

704-
tag-class-attribute-value:
705-
# required until ST4113
706-
- meta_prepend: true
707-
- meta_include_prototype: false
708-
709-
tag-generic-attribute-value:
710-
# required until ST4113
711-
- meta_prepend: true
712-
- meta_include_prototype: false
713-
714-
tag-href-attribute-value:
715-
# required until ST4113
716-
- meta_prepend: true
717-
- meta_include_prototype: false
718-
719-
tag-id-attribute-value:
720-
# required until ST4113
721-
- meta_prepend: true
722-
- meta_include_prototype: false
723-
724585
tag-lang-attribute-meta:
725586
# required until ST4184 (PR #4061)
726587
- meta_include_prototype: false

0 commit comments

Comments
 (0)