Sha256: a237799c32111810caaf2848c211b0d415831e25d4e4e8ffd7c3a4a2a81d7a4f
Contents?: true
Size: 747 Bytes
Versions: 18
Compression:
Stored size: 747 Bytes
Contents
import {MDCTopAppBar} from '@material/top-app-bar/index'; import {VBaseComponent} from './base-component'; import {hookupComponents} from './base-component'; import {eventHandlerMixin} from './mixins/event-handler'; export function initHeader(e) { console.debug('\tHeader'); hookupComponents(e, '.v-header', VHeader, MDCTopAppBar); } export class VHeader extends eventHandlerMixin(VBaseComponent) { constructor(element, mdcComponent, root) { super(element, mdcComponent); element.addEventListener('MDCTopAppBar:nav', function() { var event = new Event('v:header:item-click',{bubbles: true, composed: true}); // Dispatch the event. element.dispatchEvent(event); }); } }
Version data entries
18 entries across 18 versions & 2 rubygems