Skip to content
Stand with Ukraine flag

Table with expansion panel

  • Widget
  • 16 installs
  • v1.0.0
  • Jul 30, 2026
  • MIT license
  • v4.2+
Table with expansion panel

Displays entity data as a paginated table where every row can be expanded in place to reveal additional, fully custom detail content. Table columns are driven by data key settings, while the expanded content is generated by a user-supplied JavaScript function and styled with user-supplied CSS — so each row can show extra readings, history, or notes without navigating away from the table.

Widget Type
  • Latest
Category
  • Cards & Info
  • Tables & Lists
Use Cases
  • Asset Tracking
  • Fleet Tracking
  • Environment Monitoring
  • Industrial Automation
  • Smart Building
  • Smart City
  • Smart Energy
  • Smart Home
  • Tank Level Monitoring
  • Waste Management

Table with Expansion Panel

Displays entity data as a table where every row can be expanded in place to reveal additional, fully custom detail content. The expanded content is generated by a user-supplied JavaScript function and styled with user-supplied CSS — so each row can show extra readings, history, or notes without navigating away from the table.

Features

  • Expand/collapse per row — clicking a row (or its chevron button) reveals a detail panel underneath it with a smooth transition; clicking again collapses it.
  • Custom detail content — the expanded panel’s HTML is produced by a widget-level JavaScript function, so it can render anything (formatted text, mini layouts, links, icons) built from the row’s entity and its data.
  • Custom detail styling — an optional CSS block is injected into the widget so the custom detail markup can be styled without touching component code.

Data key configuration

Every data key’s settings dialog has a Show in table toggle. Turn it off to hide that key from the table while still making its value available to the detail content function.

Widget settings

Configured in the widget’s Appearance tab, under Expandable row content:

SettingDescription
Expandable content functionReceives the entity and its full data (every data key, not just the ones shown as columns). Must return an HTML string to render inside the expanded row. If omitted or invalid, the expanded panel stays empty.
Expandable content CSSInjected into a <style> tag scoped to the widget instance, so you can style whatever markup the expandable content function returns.

Example expandable content function

var latest = data.find(function (d) { return d.dataKey.name === 'temperature'; });
var value = latest && latest.data.length ? latest.data[0][1] : 'n/a';
return '<div class="entity-detail">' +
'<b>Entity ID:</b> ' + entityId.id + '<br/>' +
'<b>Latest temperature:</b> ' + value +
'</div>';

Example expandable content CSS

.entity-detail {
font-size: 13px;
color: #444B52;
}

Share Your Widget with the Community

Built a custom widget? Export it as a JSON from ThingsBoard and publish it to the IoT Hub through a simple 4-step wizard (Upload, Listing, Readme, Review & Submit). Share it with thousands of ThingsBoard developers worldwide and get featured in the catalog.