This commit is contained in:
Pierre Minik Lynge 2021-01-28 23:52:11 +00:00
parent d19b93d9f0
commit 5bd38fbbf1

View file

@ -438,15 +438,13 @@
</subscopes> </subscopes>
</scope> </scope>
<!-- Style --> <!-- SASS -->
<scope name="html.embedded.style" spell-check="false" lookup="documentation"> <scope name="html.embedded.block.style" spell-check="false" lookup="documentation">
<starts-with> <starts-with>
<expression>(?=&lt;(?i:style)\b)</expression> <expression>(?=&lt;(?i:style)\b)(?=[^&gt;]*lang=('sass'|\"sass\"))(?![^/&gt;]*/&gt;\s*$)</expression>
</starts-with> </starts-with>
<ends-with> <ends-with />
<expression>(?=&lt;/(?i:style)\b)</expression> <subscopes anchored="true" skip-whitespace="false">
</ends-with>
<subscopes>
<scope name="html.tag.style.open"> <scope name="html.tag.style.open">
<symbol type="tag-style"> <symbol type="tag-style">
<context behavior="start" group-by-name="true"> <context behavior="start" group-by-name="true">
@ -461,10 +459,130 @@
<expression>/?&gt;</expression> <expression>/?&gt;</expression>
</ends-with> </ends-with>
<subscopes> <subscopes>
<include syntax="self" collection="attributes" /> <include syntax="html" collection="attributes" />
</subscopes> </subscopes>
</scope> </scope>
<scope name="html.embedded.style.content"> <scope name="html.embedded.block.style.content">
<starts-with>
<expression>(?&lt;=&gt;)</expression>
</starts-with>
<ends-with>
<expression>(?=&lt;/(?i:style)\b)</expression>
</ends-with>
<subsyntax name="sass">
<cut-off>
<expression>(?=&lt;/(?i:style)\b)</expression>
</cut-off>
</subsyntax>
</scope>
</subscopes>
</scope>
<!-- SCSS -->
<scope name="html.embedded.block.style" spell-check="false" lookup="documentation">
<starts-with>
<expression>(?=&lt;(?i:style)\b)(?=[^&gt;]*lang=('scss'|\"scss\"))(?![^/&gt;]*/&gt;\s*$)</expression>
</starts-with>
<ends-with />
<subscopes anchored="true" skip-whitespace="false">
<scope name="html.tag.style.open">
<symbol type="tag-style">
<context behavior="start" group-by-name="true">
<auto-close string="&lt;/" completion="${name}&gt;" />
</context>
</symbol>
<starts-with>
<expression>&lt;((?i:style))</expression>
<capture number="1" name="html.tag.name" />
</starts-with>
<ends-with>
<expression>/?&gt;</expression>
</ends-with>
<subscopes>
<include syntax="html" collection="attributes" />
</subscopes>
</scope>
<scope name="html.embedded.block.style.content">
<starts-with>
<expression>(?&lt;=&gt;)</expression>
</starts-with>
<ends-with>
<expression>(?=&lt;/(?i:style)\b)</expression>
</ends-with>
<subsyntax name="scss">
<cut-off>
<expression>(?=&lt;/(?i:style)\b)</expression>
</cut-off>
</subsyntax>
</scope>
</subscopes>
</scope>
<!-- LESS -->
<scope name="html.embedded.block.style" spell-check="false" lookup="documentation">
<starts-with>
<expression>(?=&lt;(?i:style)\b)(?=[^&gt;]*lang=('less'|\"less\"))(?![^/&gt;]*/&gt;\s*$)</expression>
</starts-with>
<ends-with />
<subscopes anchored="true" skip-whitespace="false">
<scope name="html.tag.style.open">
<symbol type="tag-style">
<context behavior="start" group-by-name="true">
<auto-close string="&lt;/" completion="${name}&gt;" />
</context>
</symbol>
<starts-with>
<expression>&lt;((?i:style))</expression>
<capture number="1" name="html.tag.name" />
</starts-with>
<ends-with>
<expression>/?&gt;</expression>
</ends-with>
<subscopes>
<include syntax="html" collection="attributes" />
</subscopes>
</scope>
<scope name="html.embedded.block.style.content">
<starts-with>
<expression>(?&lt;=&gt;)</expression>
</starts-with>
<ends-with>
<expression>(?=&lt;/(?i:style)\b)</expression>
</ends-with>
<subsyntax name="less">
<cut-off>
<expression>(?=&lt;/(?i:style)\b)</expression>
</cut-off>
</subsyntax>
</scope>
</subscopes>
</scope>
<!-- CSS -->
<scope name="html.embedded.block.style" spell-check="false" lookup="documentation">
<starts-with>
<expression>(?=&lt;(?i:style)\b)</expression>
</starts-with>
<ends-with />
<subscopes anchored="true" skip-whitespace="false">
<scope name="html.tag.style.open">
<symbol type="tag-style">
<context behavior="start" group-by-name="true">
<auto-close string="&lt;/" completion="${name}&gt;" />
</context>
</symbol>
<starts-with>
<expression>&lt;((?i:style))</expression>
<capture number="1" name="html.tag.name" />
</starts-with>
<ends-with>
<expression>/?&gt;</expression>
</ends-with>
<subscopes>
<include syntax="html" collection="attributes" />
</subscopes>
</scope>
<scope name="html.embedded.block.style.content">
<starts-with> <starts-with>
<expression>(?&lt;=&gt;)</expression> <expression>(?&lt;=&gt;)</expression>
</starts-with> </starts-with>
@ -473,7 +591,7 @@
</ends-with> </ends-with>
<subsyntax name="css"> <subsyntax name="css">
<cut-off> <cut-off>
<expression>(?=&lt;/(?i:style|head|body|div)\b)</expression> <expression>(?=&lt;/(?i:style)\b)</expression>
</cut-off> </cut-off>
</subsyntax> </subsyntax>
</scope> </scope>