Methods
-
Initializes a new tab group from the given tab pane collection.
This function cycles through the given tab pane DOM nodes, extracts their tab IDs, titles and active states, renders a corresponding tab menu and prepends it to the tab panes common parent DOM node.
The tab menu labels will be set to the value of the
data-tab-titleattribute of each corresponding pane. The last pane with thedata-tab-activeattribute set totruewill be selected by default.If no pane is marked as active, the first one will be preselected.
Name Type Description panesArray.<Node> | NodeList A collection of tab panes to build a tab group menu for. May be a plain array of DOM nodes or a NodeList collection, such as the result of a
querySelectorAll()call or the.childNodesproperty of a DOM node. -
Checks whether the given tab pane node is empty.
Name Type Description paneNode The tab pane to check.
Returns:
Type Description boolean Returns trueif the pane is empty, elsefalse.