add template and css properties support into DOM.extend
add on spec and fix bug