Skip to main content

getWidget()

returns the widget attached to a tabbar cell

getWidget(): any;

Returns:

An object of a widget attached to a cell.

Example

const tabbar = new dhx.Tabbar("tabbar_container", {
mode: "top",
css: "dhx_widget--bordered",
views: [
{ id: "vilnius", tab: "Vilnius" },
{ tab: "dataview", id: "dataview"}
]
});

const dataview = new dhx.DataView(null, {
template: dataviewTemplate,
itemsInRow: 3,
gap: "10px"
});

dataview.data.parse(dataset);

tabbar.getCell("dataview").attach(dataview);

// id - the id of a cell a widget is attached to
const widget = tabbar.getCell("dataview").getWidget();