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.
We would like to use this module to create tabs on the preview page. Right now the markup is not that easy to navigate.
Long term solution: It would be nice to have twig templates which would be easy to customize.
Short term solution: Adding some classes and wrappers to make the output more easy to traverse.
Suggestion:
.view-mode-list-item
.view-mode-list-item-label
.view-mode-list-item-content
I'll submit a patch for this.
Thanks for the module!
Comment | File | Size | Author |
---|---|---|---|
#2 | view_mode_display--use-easily-traversable-structure--3093964--2.patch | 784 bytes | damontgomery |
Comments
Comment #2
damontgomery CreditAttribution: damontgomery at Palantir.net commentedHere is our patch. It adds the classes:
.view-mode-list-item
.view-mode-list-item-label
.view-mode-list-item-content
This also makes the label a DIV instead of an H1. There shouldn't be multiple H1s on the page and this makes it easy for a theme to set a style for the site.
Comment #4
zach.bimson CreditAttribution: zach.bimson as a volunteer commentedWorks for me! thanks dude..
Comment #5
zach.bimson CreditAttribution: zach.bimson as a volunteer commentedReleased as 2.1