UNPKG

@ribajs/bs4

Version:

Bootstrap 4 module for Riba.js

46 lines (45 loc) 1.92 kB
import { TemplatesComponent, ScopeBase } from "@ribajs/core"; interface AccordionItem { title: string; content: string; show: boolean; iconDirection: "left" | "left-up" | "up" | "up-right" | "right" | "right-down" | "down" | "down-left"; } interface Scope extends ScopeBase { items: AccordionItem[]; toggle: Bs4AccordionComponent["toggle"]; show: Bs4AccordionComponent["show"]; hide: Bs4AccordionComponent["hide"]; collapseIconSrc?: string; collapseIconSize: number; showOnlyOne: boolean; } export declare class Bs4AccordionComponent extends TemplatesComponent { static tagName: string; protected autobind: boolean; protected templateAttributes: { name: string; required: boolean; }[]; static get observedAttributes(): string[]; scope: Scope; constructor(); hide(item: AccordionItem, index: number): void; show(item: AccordionItem, index: number): void; toggle(item: AccordionItem, index: number): void; protected initItemEventListeners(item: AccordionItem, element: HTMLElement): void; protected getContentChildByIndex(): Element | undefined; protected onShow(element: HTMLElement, item: AccordionItem): void; protected onHide(element: HTMLElement, item: AccordionItem): void; protected transformTemplateAttributes(attributes: any): any; protected triggerVisibilityChangedForElement(element: Element, visible: boolean): void; protected connectedCallback(): void; protected init(observedAttributes: string[]): Promise<void>; protected beforeBind(): Promise<any>; protected afterBind(): Promise<any>; protected requiredAttributes(): string[]; protected parsedAttributeChangedCallback(attributeName: string, oldValue: any, newValue: any, namespace: string | null): void; protected disconnectedCallback(): void; protected template(): Promise<string | null>; } export {};