UNPKG

forms-reactive

Version:

Reactive Form Web Component

43 lines (39 loc) 1.55 kB
import { r as registerInstance, h, H as Host } from './index-c364827c.js'; import { m as menuController } from './index-b276329d.js'; import { g as getIonMode } from './ionic-global-9c20d605.js'; import { u as updateVisibility } from './menu-toggle-util-487a2f2e.js'; import './index-51ff1772.js'; import './hardware-back-button-a8cb5b77.js'; import './index-ad7a76eb.js'; import './helpers-609e93da.js'; import './animation-45b3e295.js'; const menuToggleCss = ":host(.menu-toggle-hidden){display:none}"; const IonMenuToggleStyle0 = menuToggleCss; const MenuToggle = class { constructor(hostRef) { registerInstance(this, hostRef); this.onClick = () => { return menuController.toggle(this.menu); }; this.visible = false; this.menu = undefined; this.autoHide = true; } connectedCallback() { this.visibilityChanged(); } async visibilityChanged() { this.visible = await updateVisibility(this.menu); } render() { const mode = getIonMode(this); const hidden = this.autoHide && !this.visible; return (h(Host, { key: '88e88fa13ac7f10ba3acfe378bd11cda0c7e2749', onClick: this.onClick, "aria-hidden": hidden ? 'true' : null, class: { [mode]: true, 'menu-toggle-hidden': hidden, } }, h("slot", { key: '0a14c7b63eda64702d2fd1b4bc7db4809892842d' }))); } }; MenuToggle.style = IonMenuToggleStyle0; export { MenuToggle as ion_menu_toggle }; //# sourceMappingURL=ion-menu-toggle.entry.js.map