dart-lang / sdk

The Dart SDK, including the VM, JS and Wasm compilers, analysis, core libraries, and more.
https://dart.dev
BSD 3-Clause "New" or "Revised" License
10.06k stars 1.56k forks source link

dart:html: document.getElementById('dialog') returns UnknownElement instead of DialogElement #19638

Open DartBot opened 10 years ago

DartBot commented 10 years ago

This issue was originally filed by alexe.kaigorodov@gmail.com


following code:

const String htmlEL = r''' <dialog id="d1">   <p>foobar</p>   <button>OK</button> </dialog> ''';

void main() {   document.body.appendHtml(htmlEL);   var d1 = document.getElementById('d1');   print("d1 is ${d1.runtimeType}"); }

prints

d1 is UnknownElement

sgjesse commented 10 years ago

Added Library-Html, Triaged labels.

alan-knight commented 9 years ago

In 1.8 it returns HtmlElement rather than UnknownElement but it still seems incorrect.


Removed Priority-Unassigned label. Added Priority-Medium, Accepted labels.