If you disable Shortcut, it leaves a white gap. It should collapse, shouldn't it?

CommentFileSizeAuthor
#4 shortcuttoolbar.patch1.66 KBcasey
seven_shortcut_gap.png17.77 KBlisarex

Comments

morbus iff’s picture

Confirmed in Safari.

jbrown’s picture

Status: Reviewed & tested by the community » Active

Also, if Shortcut is enabled, but Toolbar is not, then the Shortcut links are present, but the Shortcut bar is not.

morbus iff’s picture

Title: Disabling Shortcut module leaves a big white gap » Shortcut and Toolbar are interdependent
Component: Seven theme » toolbar.module

This is being caused by toolbar.css:

body.toolbar-drawer {
  padding-top: 6.6em;
}

From my custom theme, it's fixable with:

/* see #645140. */
body.toolbar-drawer {
  padding-top: 3em;
}

One possible core fix is to move the original toolbar-drawer CSS padding into shortcut.css instead.

casey’s picture

StatusFileSize
new1.66 KB

Other modules could also add drawers to the toolbar so #3 is not an option.

We need javascript here. When we use this patch we could also remove the body.toolbar-drawer class.

Adding the stylesheet to the add-remove-shortcut is necessary for situation as mentioned in #2; shortcut enabled, toolbar disabled.

casey’s picture

Status: Active » Needs review
aspilicious’s picture

Status: Needs review » Reviewed & tested by the community

tested this is FIXED now...
setting to RTBC

I found another issue...
When shortcuts are disable you still see the text: Add to default shortcuts... (in stead of the shortcut button/icon)
Is this normal?
Do I need to open thread for that?

webchick’s picture

Status: Active » Fixed

This fixes the annoying gap left on the page when shortcut module is enabled for me. Woo hoo! :D Committed to HEAD.

I was not able to reproduce aspilicious's results in #6, however. When Shortcut module is off, the "Add to shortcuts" disappears from all themes. But if there is a bug here, I don't really see how that could be solved by this patch, so it should indeed be a separate issue.

jbrown’s picture

The problem is that if Shortcut is enabled, but Toolbar is not, then you can't see the shortcut bar, but you can see the add to shortcuts links.

Maybe shortcut should depend on toolbar, so shortcut can't be enabled without toolbar?

Status: Fixed » Closed (fixed)

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

David_Rothstein’s picture

Regarding @jbrown's suggestion to make the Shortcut module depend on Toolbar, see #1262966: Make the Shortcut module depend on the Toolbar module (closed - won't fix).

The problem is that if Shortcut is enabled, but Toolbar is not, then you can't see the shortcut bar, but you can see the add to shortcuts links.

Perhaps it's worth filing a separate issue to make the "add to shortcuts" link only appear if the shortcuts are actually displayed on the current page? Note that this would naturally be solved for Drupal 8 by something like #1164782: The icon to add something to shortcuts wasn't clearly discoverable., though.