Problem/Motivation

Multiple rows of tabs not spacing properly in Seven theme.

Steps to reproduce

  1. Login in as a administrator that has permissions to view module admin tabs or view a user profile page
  2. Add a module that adds multiple tabs (15-20) on a page, or edit the page's HTML in firebug and create multiple tabs (15-20)
  3. Visit the page (doesn't have to be the User profile page), add multiple rows of tabs, note the lack of spacing between the rows of tabs, see screenshot in #17

The tabs are now wrapping properly in Seven and Bartik themes. However, in Seven, rows of tabs are not spaced properly. Issue exists in both Drupal 7 & Drupal 8.

Proposed resolution

ul.primary li {
  margin: 3px 2px;
}

around line 244 in core/themes/seven/styles.css (D8).

Remaining tasks

Original report by "http://drupal.org/user/555560"> Vc Developer

In the User Profile page as Admin I have 26 tabs and there not wrapping. Does the same with AT Admin theme. Keeps the same layout and I can only access the last 13 tabs. Cube, Rubik and Fubik does wrap the tabs, but does not adjust for the Body Pages so the second row of tabs show halfway underneath the pages.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

ishmael-sanchez’s picture

Version: 7.14 » 8.x-dev
Status: Active » Needs review
FileSize
730 bytes

This does seem like an edge case (26 is a lot and you could use hook_menu_alter to modify the tab listing or create a sub-theme and fix), but I think the tabs shouldn't be hidden by presentational CSS.

There is similar issue #1699058: Not handling multiple tabs..... with AdaptiveTheme but the suggestion to

ul.primary {
    white-space: normal;
}

doesn't fix the issue alone you need to remove the exact height definition as well in ul.primary around line 259 style.css.

In Rubik the body page doesn't adjust because in .primary-tabs in the style.css 185 there is a specific height definition so you could adjust that by creating an admin sub-them and make the CSS work for your use case.

Vc Developer’s picture

FileSize
59.55 KB

Yea, that is what I had to do with Rubik, I changed each link to look like buttons using the same style so it wouldn't look funky when it wraps, plus other minor changes.

Take a look at the screen shoot....

ishmael-sanchez’s picture

@Vc Developer can you test the patch if you have a chance and if it works at expected mark it as reviewed & tested by the community and hopefully we can get this fix committed so everyone can enjoy the fix.

Vc Developer’s picture

Version: 8.x-dev » 7.14

I need to make a correction, but I will still test it on D8. I didn't realize after trying the patch on D7 that my post somehow was for D8. Do I need to create another issue for D7 to get a patch made?

ishmael-sanchez’s picture

Version: 7.14 » 8.x-dev

The problem exists in D8 and D7 so I believe the preferred approach is to fix it in D8 then have the fix trickle down to D7 hence why I marked it D8.

Vc Developer’s picture

Ok.., don't know if there's enough modules for D8 to get over lapping tabs, but I will give it a try and get back with you....

Vc Developer’s picture

I'm running Cygwin on a Windows Web Server 2008 and I get this message when trying to run the patch:

eqmiller@anointed-media /cygdrive/d/wamp/www/drupal-8.x-dev
$ patch -p0 < tab.patch
can't find file to patch at input line 5
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|diff --git a/core/modules/system/system.theme.css b/core/modules/system/system.theme.css
|index d5f41e1..09c1291 100644
|--- a/core/modules/system/system.theme.css
|+++ b/core/modules/system/system.theme.css
--------------------------
File to patch:

P.S. I shorten the name to reduce typing....

ishmael-sanchez’s picture

@Vc Developer try git apply -v [patch-name.patch] (See Making a Drupal patch with Git the Applying a patch section) using that command I was able get the patch to apply cleanly.

For the actual testing of tabs I edited the HTML of the page using firebug and chrome so you can do the same without having to install additional modules to create tabs for you.

Vc Developer’s picture

Is this the reason why Drupal code is in such shambles, because of not properly testing with actual live data configuration? This is the average result of all modules being published. Manipulation is not testing, I can only properly test the patch in D7.

I hope this is put an end too in D8.... Its frustrating taking five steps back for every one, because some other module steps all over another and with just one click of the mouse destroys everything..

I'm smiling while I'm saying this so don't take it personal.. ;)

ishmael-sanchez’s picture

@Vc Developer

I definitely don't think the Drupal code base is in shambles and if you think it is the best part about open source is you can contribute and make it better. Did I take a shortcut, yeah because this is just a presentational issue and if it works, who are you to judge my methods (Just saying). If you can kindly test on D8 and see if my fix works that would be great. Thanks!

xjm’s picture

Thanks for the patch @ishmael-sanchez!

@ishmael-sanchez is correct; we'll want to resolve the issue in D8 first and then backport it to D7. This is part of the process for fixing it in D7, so we can ensure that it doesn't break again once we fix it. It does not mean the patch does not get tested before going into D7--quite the contrary. Patches need to be tested even more thoroughly before they can go into D7 so that we can ensure we don't introduce regressions on production Drupal sites.

@Vc Developer, If you'd like to help test this issue in D7, you can create a D7 version of the patch yourself:

  1. Make the same CSS changes from #1 in D7.
  2. Create a patch with git.
  3. Attach that D7 patc to this issue with a filename like 1699072-D7-do-not-test.patch. (The do-not-test part makes the testbot skip trying to apply the patch, since a D7 patch won't work on D8. See the fine print under the file upload.)

Tagging for manual testing, before-and-after screenshots, and an issue summary.

Shyamala’s picture

Attached Screenshot of Seven & Bartik. The patch fixes disappearing tabs that can not be accessed in Seven. In Bartik the tabs are accessible before & after but the alignment needs to be fixed.

Shyamala’s picture

Title: Not handling multiple tabs..... » Multiple tabs on User Profile page on exceeds page width - doesn't wrap properly.

updating title

Shyamala’s picture

Issue summary: View changes

update issue summary

YesCT’s picture

Status: Needs review » Needs work

needs work based on #12

YesCT’s picture

Status: Needs work » Needs review
Issue tags: -Needs issue summary update, -Needs screenshots, -Needs manual testing, -Needs backport to D7

#1: tab-wrapping-1699072-1.patch queued for re-testing.

Status: Needs review » Needs work
Issue tags: +Needs issue summary update, +Needs screenshots, +Needs manual testing, +Needs backport to D7

The last submitted patch, tab-wrapping-1699072-1.patch, failed testing.

kevinsiji’s picture

It seems that wrapping issue has been fixed by now, and another issue has popped up.

The tabs of lower rows overlap with the upper rows and cannot distinguish them from each other. See the screenshot attached.

Before and after screenshots and patch attached.
Before:
Before

After:
After

Update: Screenshots embedded. Thanks @YesCT

The last submitted patch, seven-multiple-user-tabs-1699072-17.patch, failed testing.

YesCT’s picture

Issue tags: +SprintWeekend2013

@kevinsiji thanks for those screenshots.

To ease reviewing and get reviews faster, embedding of the screenshots in the issue comment is recommended. (See contributor task http://drupal.org/node/1859584 for more info and tips). Also, dreditor makes it really easy to embed attachements.

kevinsiji’s picture

Status: Needs work » Needs review
Shyamala’s picture

Issue tags: +SprintWeekend2013

Thanks kevinsiji for adding the screenshots. The tasks needs the below actions from you:

  • Post which browser the issue was tested on
  • Read through the instructions at http://drupal.org/node/1489010 for instructions on Manual testing. If there are any edits to the steps to reproduce, please add them as well
  • Remove the +Needs manual testing, Needs screenshot tags
Shyamala’s picture

Issue summary: View changes

updating issue summary as per issue summary template

kevinsiji’s picture

The issue is tested on Chrome and Firefox in Ubuntu 12.10.

kevinsiji’s picture

Issue summary: View changes

added links for new contirbutors

YesCT’s picture

star-szr’s picture

Trying to fix tags.

BrockBoland’s picture

Needs an issue summary: http://drupal.org/node/1427826

stevenovy’s picture

Issue summary: View changes

Updated "Steps to reproduce".

stevenovy’s picture

Updated issue summary.

stevenovy’s picture

Title: Multiple tabs on User Profile page on exceeds page width - doesn't wrap properly. » Multiple rows of tabs not spacing properly in Seven theme
Assigned: Unassigned » stevenovy
Issue tags: -Needs issue summary update, -SprintWeekend2013
FileSize
47.18 KB
48.2 KB

Tested patch in #17 in FF 23 and Chrome 29 on Mac OS X 10.8.5. Both worked fine. Embedding screenshots from FF with path /admin/appearance:
before:

20130922_before.png

after:

20130922_after.png

Will test it again with IE on a Windows machine.

stevenovy’s picture

Issue summary: View changes

Updated issue summary.

heddn’s picture

Issue summary: View changes
Issue tags: +Needs reroll
idebr’s picture

FileSize
75.51 KB

Not sure about scoping of this issue, but tabs wrapping is still broken with overlay enabled (see screenshot in attachment)

Otherwise patch works as advertised :)

kevinsiji’s picture

#overlay-tabs is positioned absolute in overlay-child.css of Overlay module. While growing vertically, absolute positioned #overlay-tabs cannot push the #overlay-content down, hence it cannot be wrapped properly in theme layer.

I feel, comment#29 should be filed against Overlay module.

kevinsiji’s picture

It seems tabs in overlay module have made considerable progress here > https://drupal.org/node/1953374

manooh’s picture

Assigned: stevenovy » manooh

Doing the reroll

manooh’s picture

manooh’s picture

Assigned: manooh » Unassigned

Reroll done.

Status: Needs review » Needs work

The last submitted patch, 33: seven-multiple-user-tabs-1699072-33.patch, failed testing.

LewisNyman’s picture

Status: Needs work » Postponed

This work looks great but we might be better off postponing on #1490402: Redesign tabs and the content header which solves this bug.

mgifford’s picture

Status: Postponed » Needs work
Related issues: +#1490402: Redesign tabs and the content header
Bojhan’s picture

Status: Needs work » Fixed

We fixed this, duh! It now wraps to responsive whenever its too long.

mgifford’s picture

Excellent! A bunch of Postponed issues had been fixed, but hadn't ever been marked as Fixed.

Status: Fixed » Closed (fixed)

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