Permalink
Browse files

Add oneline snippets for html

  • Loading branch information...
1 parent 97fc86e commit b5a95faf2e8587ca0404904b87c421f2754bd8fb Aldis Berjoza committed Jul 24, 2012
Showing with 51 additions and 0 deletions.
  1. +51 −0 snippets/html.snippets
View
@@ -82,3 +82,54 @@ snippet "^(\s*)%([a-zA-Z]+)#([a-zA-Z0-9_-]+)$" "element id" r
endsnippet
+
+
+
+
+
+
+snippet "^(\s*)!\.([a-zA-Z0-9_.-]+)$" "span class" r
+`!p snip.rv=match.group(1)`<span class="`!p snip.rv=match.group(2).replace('.', ' ')`">$1</span>
+endsnippet
+
+snippet "^(\s*)!#([a-zA-Z0-9_-]+)$" "span id" r
+`!p snip.rv=match.group(1)`<span id="`!p snip.rv=match.group(2)`">$1</span>
+endsnippet
+
+
+snippet "^(\s*)!\.([a-zA-Z0-9_.-]+)#([a-zA-Z0-9_-]+)$" "span class id" r
+`!p snip.rv=match.group(1)`<span id="`!p snip.rv=match.group(3)`" class="`!p snip.rv=match.group(2).replace('.', ' ')`">$1</span>
+endsnippet
+
+
+snippet "^(\s*)!#([a-zA-Z0-9_-]+)\.([a-zA-Z0-9_.-]+)$" "span id class" r
+`!p snip.rv=match.group(1)`<span id="`!p snip.rv=match.group(2)`" class="`!p snip.rv=match.group(3).replace('.', ' ')`">$1</span>
+endsnippet
+
+
+
+snippet "^(\s*)%([a-zA-Z]+)\.([a-zA-Z0-9_.-]+)#([a-zA-Z0-9_-]+)$" "div class id" r
+`!p snip.rv=match.group(1)`<`!p snip.rv=match.group(2)` id="`!p snip.rv=match.group(4)`" class="`!p snip.rv=match.group(3).replace('.', ' ')`">$1</`!p snip.rv=match.group(2)`>
+endsnippet
+
+
+snippet "^(\s*)!%([a-zA-Z]+)#([a-zA-Z0-9_-]+)\.([a-zA-Z0-9_.-]+)$" "div id class" r
+`!p snip.rv=match.group(1)`<`!p snip.rv=match.group(2)` id="`!p snip.rv=match.group(3)`" class="`!p snip.rv=match.group(4).replace('.', ' ')`">$1</`!p snip.rv=match.group(2)`>
+endsnippet
+
+
+snippet "^(\s*)!%([a-zA-Z]+)$" "element" r
+`!p snip.rv=match.group(1)`<`!p snip.rv=match.group(2)`>$1</`!p snip.rv=match.group(2)`>
+endsnippet
+
+
+snippet "^(\s*)!%([a-zA-Z]+)\.([a-zA-Z0-9_.-]+)$" "element class" r
+`!p snip.rv=match.group(1)`<`!p snip.rv=match.group(2)` class="`!p snip.rv=match.group(3).replace('.', ' ')`">$1</`!p snip.rv=match.group(2)`>
+endsnippet
+
+
+snippet "^(\s*)!%([a-zA-Z]+)#([a-zA-Z0-9_-]+)$" "element id" r
+`!p snip.rv=match.group(1)`<`!p snip.rv=match.group(2)` id="`!p snip.rv=match.group(3)`">$1</`!p snip.rv=match.group(2)`>
+endsnippet
+
+

0 comments on commit b5a95fa

Please sign in to comment.