Commit 2f139937 authored by webchick's avatar webchick

Issue #2208731 by LewisNyman, larowlan: Tour tab increases the height of the toolbar.

parent bd2cfd02
......@@ -10,19 +10,16 @@
[dir="rtl"] .toolbar .toolbar-bar .contextual-toolbar-tab.toolbar-tab {
float: left;
}
.toolbar .toolbar-bar .contextual-toolbar-tab button {
.toolbar .toolbar-bar .contextual-toolbar-tab .toolbar-item {
margin: 0;
padding-bottom: 1em;
padding-top: 1em;
/* Hide tab text. */
padding-left: 1.3333em; /* LTR */
text-indent: -9999px;
line-height: 1em;
}
[dir="rtl"] .toolbar .toolbar-bar .contextual-toolbar-tab button {
[dir="rtl"] .toolbar .toolbar-bar .contextual-toolbar-tab .toolbar-item {
padding-right: 1.3333em;
}
.toolbar .toolbar-bar .contextual-toolbar-tab button.active {
.toolbar .toolbar-bar .contextual-toolbar-tab .toolbar-item.active {
background-image:-moz-linear-gradient(rgb(78,159,234) 0%,rgb(69,132,221) 100%);
background-image:-webkit-gradient(linear,color-stop(0, rgb(78,159,234)),color-stop(1, rgb(69,132,221)));
background-image: -webkit-linear-gradient(top, rgb(78,159,234) 0%, rgb(69,132,221) 100%);
......
......@@ -441,11 +441,9 @@ function shortcut_toolbar() {
'#type' => 'link',
'#title' => t('Shortcuts'),
'#href' => 'admin/config/user-interface/shortcut',
'#options' => array(
'attributes' => array(
'title' => t('Shortcuts'),
'class' => array('toolbar-icon', 'toolbar-icon-shortcut'),
),
'#attributes' => array(
'title' => t('Shortcuts'),
'class' => array('toolbar-icon', 'toolbar-icon-shortcut'),
),
),
'tray' => array(
......
......@@ -14,12 +14,13 @@
-webkit-touch-callout: none;
touch-callout: none;
}
.toolbar a {
.toolbar .toolbar-item {
cursor: pointer;
padding: 1em 1.3333em;
line-height: 1em;
text-decoration: none;
}
.toolbar a:hover {
.toolbar .toolbar-item:hover {
text-decoration: underline;
}
......@@ -34,18 +35,18 @@
[dir="rtl"] .toolbar .toolbar-bar {
box-shadow: 1px 0 3px 1px rgba(0, 0, 0, 0.3333);
}
.toolbar .toolbar-bar a {
.toolbar .toolbar-bar .toolbar-item {
color: #ffffff;
}
.toolbar .toolbar-bar .toolbar-tab > a {
.toolbar .toolbar-bar .toolbar-tab > .toolbar-item {
font-weight: bold;
}
.toolbar .toolbar-bar .toolbar-tab > a:hover {
.toolbar .toolbar-bar .toolbar-tab > .toolbar-item:hover {
background-image: -webkit-linear-gradient(rgba(255, 255, 255, 0.125) 20%, transparent 200%);
background-image: linear-gradient(rgba(255, 255, 255, 0.125) 20%, transparent 200%);
text-decoration: none;
}
.toolbar .toolbar-bar .toolbar-tab > a.active {
.toolbar .toolbar-bar .toolbar-tab > .toolbar-item.active {
background-image: -webkit-linear-gradient(rgba(255, 255, 255, 0.25) 20%, transparent 200%);
background-image: linear-gradient(rgba(255, 255, 255, 0.25) 20%, transparent 200%);
}
......@@ -83,13 +84,17 @@
.toolbar .toolbar-tray-horizontal .toolbar-tray {
background-color: #f5f5f5;
}
.toolbar .toolbar-tray a {
.toolbar-tray a {
color: #565656;
cursor: pointer;
padding: 1em 1.3333em;
text-decoration: none;
}
.toolbar .toolbar-tray a:hover,
.toolbar .toolbar-tray a:active,
.toolbar .toolbar-tray a.active {
.toolbar-tray a:hover,
.toolbar-tray a:active,
.toolbar-tray a.active {
color: #000;
text-decoration: underline;
}
.toolbar .menu {
background-color: #ffffff;
......
......@@ -317,6 +317,8 @@ function toolbar_pre_render_item($element) {
$element['tray']['#wrapper_attributes']['class'][] = 'toolbar-tray';
}
$element['tab']['#attributes']['class'][] = 'toolbar-item';
return $element;
}
......@@ -333,12 +335,10 @@ function toolbar_toolbar() {
'#type' => 'link',
'#title' => t('Back to site'),
'#href' => '<front>',
'#options' => array(
'attributes' => array(
'title' => t('Return to site content'),
'class' => array('toolbar-icon', 'toolbar-icon-escape-admin'),
'data-toolbar-escape-admin' => TRUE,
),
'#attributes' => array(
'title' => t('Return to site content'),
'class' => array('toolbar-icon', 'toolbar-icon-escape-admin'),
'data-toolbar-escape-admin' => TRUE,
),
),
'#wrapper_attributes' => array(
......@@ -389,17 +389,15 @@ function toolbar_toolbar() {
'#type' => 'link',
'#title' => t('Manage'),
'#href' => 'admin',
'#options' => array(
'attributes' => array(
'title' => t('Admin menu'),
'class' => array('toolbar-icon', 'toolbar-icon-menu'),
// A data attribute that indicates to the client to defer loading of
// the admin menu subtrees until this tab is activated. Admin menu
// subtrees will not render to the DOM if this attribute is removed.
// The value of the attribute is intentionally left blank. Only the
// presence of the attribute is necessary.
'data-drupal-subtrees' => '',
),
'#attributes' => array(
'title' => t('Admin menu'),
'class' => array('toolbar-icon', 'toolbar-icon-menu'),
// A data attribute that indicates to the client to defer loading of
// the admin menu subtrees until this tab is activated. Admin menu
// subtrees will not render to the DOM if this attribute is removed.
// The value of the attribute is intentionally left blank. Only the
// presence of the attribute is necessary.
'data-drupal-subtrees' => '',
),
),
'tray' => $menu,
......
......@@ -1689,11 +1689,9 @@ function user_toolbar() {
'#type' => 'link',
'#title' => $user->getUsername(),
'#href' => 'user',
'#options' => array(
'attributes' => array(
'title' => t('My account'),
'class' => array('toolbar-icon', 'toolbar-icon-user'),
),
'#attributes' => array(
'title' => t('My account'),
'class' => array('toolbar-icon', 'toolbar-icon-user'),
),
),
'tray' => array(
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment