select-option-images.html (1041B)
1 <!DOCTYPE html> 2 <html class=reftest-wait> 3 <meta name=fuzzy content="maxDifference=0-41;totalPixels=0-2"> 4 <link rel=author href="mailto:jarhar@chromium.org"> 5 <link rel=help href="https://github.com/whatwg/html/issues/9799"> 6 <link rel=match href="select-option-images-ref.html"> 7 <script src="/resources/testdriver.js"></script> 8 <script src="/resources/testdriver-vendor.js"></script> 9 10 <style> 11 select, select::picker(select) { 12 appearance: base-select; 13 } 14 </style> 15 <select> 16 <button>button</button> 17 <option><img alt="" src="/images/green-16x16.png">green-16x16</option> 18 <option class=two><img alt="" src="/images/red-16x16.png">red-16x16</option> 19 </select> 20 21 <script> 22 (async () => { 23 await test_driver.bless(); 24 const select = document.querySelector('select'); 25 select.showPicker(); 26 // <img> elements should still be rendered after removing and re-appending 27 const option = document.querySelector('option.two'); 28 option.remove(); 29 select.appendChild(option); 30 document.documentElement.classList.remove('reftest-wait'); 31 })(); 32 </script>