Skip to main content
drupalreleases

Use direct release data with your AI assistant.

Learn more

Same Height

Security covered Under active development 19 sites

This module automatically aligns HTML elements to the same height, ensuring they all match the tallest element within a specified group. It is fully responsive, has no dependencies, and can be configured with unlimited CSS selectors.

Small module providing a library to automagically align HTML elements with each other by setting their height to the tallest.

Fully responsive. Zero dependencies. Unlimited selectors.

How to use

The trick is to attach the library and set the data-same-height attribute with a list of DOM selectors.

For instance in code below, we will align all .item-title together and all .item-description together too.

{{ attach_library('same_height/same_height') }}

{% 
  set sameHeight = [
    '.item-title',
    '.item-description'
  ]
%}

<div class="row" data-same-height="{{ sameHeight|json_encode }}">

  {% for item in items %}
    <div class="col-12 col-md-4 item">
      <h3 class="item-title">{{ item.title }}</h3>
      <p class="item-description">{{ item.description}}</p>
    </div>
  {% endfor %}

</div>
Drupal 8–11

Ask your assistant about Same Height

Check compatibility with your Drupal and PHP version, maintenance and security coverage, from current release data. How it works

Depends on

Dependencies of the latest stable release

No dependencies recorded for this project.

Required by

Tracked projects that depend on this one

No tracked projects depend on this one yet.

Activity

Tracked releases
3
Tracked since
Aug 2023
Latest release
4 weeks ago
Releases (12 mo)
1 ▲ from 0
Maintenance
Active

Release Timeline

Releases

Version Type Core PHP Release date
1.0.2 Stable 8–11 Oct 18, 2026
1.0.1 Stable 8–10 Mar 3, 2024
1.0.0 Stable 8–10 Aug 28, 2023