Added support for HTML dialog element.