More haml work

This commit is contained in:
Garen Torikian 2012-11-11 22:22:28 -08:00 • committed by nightwing
commit c5a3cac12f
3 changed files with 19 additions and 23 deletions

View file

@ -76,9 +76,9 @@ var HamlHighlightRules = function() {
// "regex": "^( *)(/)\\s*$",
// "next": "state_4"
//},
{
"token": ["meta.tag.haml", "punctuation.definition.tag.haml", "entity.name.tag.haml"],
"regex": /^\s*(?:((%)([\w:]+))|(?=\.|#))/,
{
"token": ["entity.name.tag.haml"],
"regex": /^\s*%[\w:]+/,
"next": "tag_single"
},
{
@ -154,17 +154,17 @@ var HamlHighlightRules = function() {
],*/
"tag_single": [
{
"token": "suport.type.attribute.class.jade",
"token": "entity.other.attribute-name.class.haml",
"regex": "\\.[\\w-]+"
},
{
"token": "suport.type.attribute.id.jade",
"token": "entity.other.attribute-name.id.haml",
"regex": "#[\\w-]+"
},
//{
// "token": "meta.section.attributes.haml",
// "regex": ""
//},
{
"token": "meta.section.attributes.haml",
"regex": "\\{(?=.*\\}|.*\\|\\s*$)"
},
//{
// "token": "meta.section.object.haml",
// "regex": ""
@ -176,11 +176,11 @@ var HamlHighlightRules = function() {
// "token": "punctuation.terminator.tag.haml",
// "regex": "/"
//},
//{
// "token": "TODO",
// "regex": "$|(?!\\.|#|\\{|\\[|=|-|~|/)",
// "next": "start"
//}
{
"token": ["text", "punctuation"],
"regex": "($)|((?!\\.|#|=|-))",
"next": "start"
}
]/*,
"state_7": [
{

View file

@ -206,11 +206,11 @@ var JadeHighlightRules = function() {
],*/
"tag_single": [
{
"token": "suport.type.attribute.class.jade",
"token": "entity.other.attribute-name.class.jade",
"regex": "\\.[\\w-]+"
},
{
"token": "suport.type.attribute.id.jade",
"token": "entity.other.attribute-name.id.jade",
"regex": "#[\\w-]+"
},
{