Updated: Comment #0

Problem/Motivation

Vertical Tabs are intentionally disabled when viewed in a narrow viewport. Which means that any code that assumes it can call tabHide() or tabShow() will break.

This is the case for filter.admin.js. It doesn't break, but it also stops showing/hiding the <details> (which are converted into Vertical Tabs when the screen is sufficiently wide) that contains a filter's settings when the corresponding filter is enabled/disabled.

Proposed resolution

Just show/hide the <details> element containing filter settings instead when Vertical Tabs aren't enabled.

Remaining tasks

None.

User interface changes

None.

API changes

None.

Discovered thanks to #2102019-4: Vertical tabs looks broken on small screens.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Wim Leers’s picture

Status: Active » Needs review
FileSize
2.29 KB
Wim Leers’s picture

Issue tags: +JavaScript

.

nod_’s picture

Status: Needs review » Needs work

This should mess with the open attribute instead of show/hide from jQuery

Wim Leers’s picture

Status: Needs work » Needs review

Huh? It already was using .tabShow() before. I'm merely fixing it. If using the open attribute is the better solution, that's fine, but that's an improvement task, this is a bug fix!

nod_’s picture

Status: Needs review » Reviewed & tested by the community

That works, it's not a matter of collapsing/expanding details element, it's a matter of showing them or not to begin with. That works.

webchick’s picture

Status: Reviewed & tested by the community » Fixed

Committed and pushed to 8.x. Thanks!

Wim Leers’s picture

Issue tags: -sprint

Hurray! :)

Automatically closed -- issue fixed for 2 weeks with no activity.