BaseStub class
Base abstract class for tab stub.
Constructor
constructor(tab: Tab, options: { [option: string]: any })
Class constructor. Descendant classes must call this constructor as follows:
super(tab, options);
tab: Tab
— tab object for created stub.options
— additional stub options.autoShow:boolean
— automatically show stub when selecting the tab with empty list of items. Default value:true
.
Methods
Method | Description | Available from version |
---|---|---|
render(): HTMLElement | Abstract method that returns stub layout. Requires implemented method in descendant classes. | |
getTab(): Tab | Returns tab object for created stub. | |
isAutoShow(): boolean | Returns true when stub is displayed automatically when selecting tab with empty list of items. | |
show(): void | Shows stub. | |
hide(): void | Hides the stub. | |
getOptions(): { [option: string]: any } | Returns collection of arbitrary stub options. | |
getOption(option: string, defaultValue?: any): any | Returns option value. When option is not found, returns value, specified in defaultValue . When defaultValue is not specified, returns null . |
© «Bitrix24», 2001-2024