Sha256: 4c8d1a9205117332dc0578c6bc0578bb10a92824bd7be057cecc0db9beb0c8c1
Contents?: true
Size: 585 Bytes
Versions: 51
Compression:
Stored size: 585 Bytes
Contents
import {controller} from '@github/catalyst' @controller class PageHeaderElement extends HTMLElement { menuItemClick(event: Event) { const currentTarget = event.currentTarget as HTMLButtonElement const id = currentTarget?.getAttribute('data-for') if (id) { document.getElementById(id)?.click() } } } declare global { interface Window { PageHeaderElement: typeof PageHeaderElement } } if (!window.customElements.get('page-header')) { window.PageHeaderElement = PageHeaderElement window.customElements.define('page-header', PageHeaderElement) }
Version data entries
51 entries across 51 versions & 1 rubygems