UNPKG

@paraboly/pwc-multi-filter

Version:

A wrapper over pwc-tabview and pwc-filter. Provides means of dynamically managing multiple filters via a single component.

33 lines (30 loc) 1.12 kB
import { r as registerInstance, c as createEvent, h, d as getElement } from './core-ba89e169.js'; const PwcTabviewTab = class { constructor(hostRef) { registerInstance(this, hostRef); this.defaultActive = false; this.active = this.defaultActive; this.tabModified = createEvent(this, "tabModified", 7); } titleWatchHandler() { this.tabModified.emit(); } activeWatchHandler(newValue) { if (newValue === null || newValue === undefined) { this.active = this.defaultActive; } } componentWillRender() { this.activeWatchHandler(this.active); } render() { return h("slot", null); } get root() { return getElement(this); } static get watchers() { return { "title": ["titleWatchHandler"], "active": ["activeWatchHandler"] }; } static get style() { return "pwc-tabview-tab {\n display: none;\n border: 1px solid black;\n padding: 10px;\n background-color: white;\n}\n\npwc-tabview-tab[active] {\n display: block;\n}"; } }; export { PwcTabviewTab as pwc_tabview_tab };