From ef27d24df056286cdef8ef270921e8a94527988d Mon Sep 17 00:00:00 2001 From: mattn Date: Fri, 6 Jun 2014 13:26:13 +0900 Subject: [PATCH] Fix #210 --- autoload/emmet/lang/html.vim | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/autoload/emmet/lang/html.vim b/autoload/emmet/lang/html.vim index 041c432..6c08eea 100644 --- a/autoload/emmet/lang/html.vim +++ b/autoload/emmet/lang/html.vim @@ -1,6 +1,6 @@ let s:mx = '\([+>]\|[<^]\+\)\{-}\s*' \ .'\((*\)\{-}\s*' -\ .'\([@#.]\{-}[a-zA-Z_\!][a-zA-Z0-9:_\!\-$]*\|{\%([^$}]\+\|\$#\|\${\w\+}\|\$\+\)*}*[ \t\r\n}]*\)' +\ .'\([@#.]\{-}[a-zA-Z_\!][a-zA-Z0-9:_\!\-$]*\|{\%([^$}]\+\|\$#\|\${\w\+}\|\$\+\)*}*[ \t\r\n}]*\|\[[^\]]\+\]\)' \ .'\(' \ .'\%(' \ .'\%(#{[{}a-zA-Z0-9_\-\$]\+\|#[a-zA-Z0-9_\-\$]\+\)' @@ -94,6 +94,10 @@ function! emmet#lang#html#parseIntoTree(abbr, type) let attributes = tag_name . attributes let tag_name = 'div' endif + if tag_name =~ '^\[.*\]$' + let attributes = tag_name . attributes + let tag_name = 'div' + endif let basedirect = basevalue[1] == '-' ? -1 : 1 let basevalue = 0 + abs(basevalue[1:]) if multiplier <= 0 | let multiplier = 1 | endif