Drupal is a registered trademark of Dries Buytaert
Protected Pages 3.0.0 Major update available for module protected_pages (3.0.0). Commerce Core 3.3.8 Minor update available for module commerce (3.3.8). Search API HTML Element Filter 1.0.7 Minor update available for module search_api_html_element_filter (1.0.7). Layout Builder Reorder 2.0.1 Minor update available for module layout_builder_reorder (2.0.1). Ban 1.1.0 Minor update available for module ban (1.1.0). Field Formatter Range 2.0.0 Major update available for module field_formatter_range (2.0.0). Field Formatter Range 8.x-1.8 Minor update available for module field_formatter_range (8.x-1.8). UI Patterns (SDC in Drupal UI) 2.0.18 Minor update available for module ui_patterns (2.0.18). Search API Solr 4.3.11 Module search_api_solr updated after 14 months of inactivity (4.3.11). Provus Mega Menu Module provus_mega_menu crossed 1,000 active installs.

This module provides an expandable table style for Drupal Views. It allows you to hide content in the last column of a table row, which can then be revealed by clicking on the row. This is useful for displaying additional details without cluttering the main table view.

Provides an expandable table style plugin.

How to use

  1. Set up your view
  2. Configure a display to use the "Expandable table" style
  3. Put the portion that should expand into the last column
  4. When your view renders, the last column will initially be hidden, and will expand when the row is clicked

Frontend considerations

  • The expandable row is literally another row in the markup of the table. If you're targeting odd/even rows for striping, you may need to adjust CSS accordingly.
  • The trigger (the small, initially displaying row) and target (the expanding row) may be targeted using tr[data-views-expandable-table-trigger] and tr[data-views-expandable-table-target] selectors accordingly.
  • The expanded class is applied to both the trigger and target rows when expanded.
  • The views-expandable-table-hover class is applied to both the trigger and target rows when either is hovered.
  • The trigger element can be configured to use the entire row (default), or to append a new element to the first or last visible column of the row (configurable).
  • If views bulk operations are on the table, the second column is selected when the 'First visible' value is used.
  • The trigger element can be configured to appear before the columns content or after the columns content. (Additional styling adjustments may be needed depending on which option you use.)

Activity

Total releases
3
First release
May 2025
Latest release
1 year ago
Releases (12 mo)
0 ▼ from 3
Maintenance
Dormant

Release Timeline

Releases

Version Type Release date
1.0.0-rc5 Pre-release May 13, 2025
1.0.0-rc4 Pre-release May 12, 2025
1.0.0-rc3 Pre-release May 12, 2025