Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Problem/Motivation
Links inside the layout tab pane are not clickable.
Steps to reproduce
1. Create a new node page, that uses the layout builder;
2. Go to the layout builder page and create a new section of Layout Builder Tabs type;
3. Add the content to the tab, that contains the link inside (e.g. the Views view);
4. Save the node layout builder and go to the node view page;
5. As a result the link inside the layout builder tab is not clickable;
Proposed resolution
Attach the JS listener to links in a more specific way, e.g.
const $layoutTabLink = $('.layout-tabs ul.tabs a.layout-tabs__tab-link');
Comment | File | Size | Author |
---|---|---|---|
#2 | layout_builder_tabs-3344653-links-inside-tab-pane-not-clickable-2.patch | 6.25 KB | zen1995 |
Comments
Comment #2
zen1995 CreditAttribution: zen1995 at Drupal Ukraine Community, Drupfan commentedAttaching the patch with a basic refactor. Needs review and test from the community.
Comment #3
zen1995 CreditAttribution: zen1995 at Drupal Ukraine Community, Drupfan commentedComment #4
zen1995 CreditAttribution: zen1995 at Drupal Ukraine Community, Drupfan commentedComment #5
delmarr CreditAttribution: delmarr at McGill University commentedI can't reproduce this issue displaying a custom block with a link field in a tab pane. @zen1995 is this specific to views that contain links?
Comment #6
gifthorse CreditAttribution: gifthorse commentedI have a Views block with links in a tab pane and don't see the bug, links work.