Вход Регистрация
Файл: error-kitty/node_modules/highlight.js/lib/languages/haml.js
Строк: 79
<?php
module
.exports // TODO support filter tags like :javascript, support inline HTML
function(hljs) {
  return {
    
case_insensitivetrue,
    
contains: [
      {
        
className'doctype',
        
begin'^!!!( (5|1\.1|Strict|Frameset|Basic|Mobile|RDFa|XML\b.*))?$',
        
relevance10
      
},
      {
        
className'comment',
        
// FIXME these comments should be allowed to span indented lines
        
begin'^\s*(!=#|=#|-#|/).*$',
        
relevance0
      
},
      {
        
begin'^\s*(-|=|!=)(?!#)',
        
starts: {
          
end'\n',
          
subLanguage'ruby'
        
}
      },
      {
        
className'tag',
        
begin'^\s*%',
        
contains: [
          {
            
className'title',
            
begin'\w+'
          
},
          {
            
className'value',
            
begin'[#\.]\w+'
          
},
          {
            
begin'{\s*',
            
end'\s*}',
            
excludeEndtrue,
            
contains: [
              {
                
//className: 'attribute',
                
begin':\w+\s*=>',
                
end',\s+',
                
returnBegintrue,
                
endsWithParenttrue,
                
contains: [
                  {
                    
className'symbol',
                    
begin':\w+'
                  
},
                  {
                    
className'string',
                    
begin'"',
                    
end'"'
                  
},
                  {
                    
className'string',
                    
begin''',
                    end: '''
                  
},
                  {
                    
begin'\w+',
                    
relevance0
                  
}
                ]
              }
            ]
          },
          {
            
begin'\(\s*',
            
end'\s*\)',
            
excludeEndtrue,
            
contains: [
              {
                
//className: 'attribute',
                
begin'\w+\s*=',
                
end'\s+',
                
returnBegintrue,
                
endsWithParenttrue,
                
contains: [
                  {
                    
className'attribute',
                    
begin'\w+',
                    
relevance0
                  
},
                  {
                    
className'string',
                    
begin'"',
                    
end'"'
                  
},
                  {
                    
className'string',
                    
begin''',
                    end: '''
                  
},
                  {
                    
begin'\w+',
                    
relevance0
                  
}
                ]
              }
            ]
          }
        ]
      },
      {
        
className'bullet',
        
begin'^\s*[=~]\s*',
        
relevance0
      
},
      {
        
begin'#{',
        
starts: {
          
end'}',
          
subLanguage'ruby'
        
}
      }
    ]
  };
};
?>
Онлайн: 0
Реклама