1export default function Dropdown(elm) { 2 const target = elm.querySelector('.dropdown-toggle').getAttribute('id'); 3 const toggleContent = elm.querySelector('[aria-labelledby="' + target + '"]'); 4 elm.querySelector('.dropdown-toggle').addEventListener('click', () => { 5 toggleContent.classList.toggle('open'); 6 if (toggleContent.classList.contains('open')) { 7 elm.querySelector('.dropdown-toggle').setAttribute('aria-expanded', true); 8 } else { 9 elm.querySelector('.dropdown-toggle').setAttribute('aria-expanded', false); 10 } 11 }) 12}
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.