Merge branch 'dropdown-design-update' into 'master'
Updated dropdown CSS This is a start on #3279 by updating the CSS for the dropdown menu. This doesnt include any CSS for the title bar or filter field ![Screen_Shot_2016-03-04_at_12.23.49](/uploads/6f2047ec1b72974334fa56e6895a32be/Screen_Shot_2016-03-04_at_12.23.49.png) See merge request !3092
This commit is contained in:
commit
cb73470b93
7 changed files with 117 additions and 48 deletions
|
@ -11,6 +11,7 @@
|
|||
@import "framework/calendar.scss";
|
||||
@import "framework/callout.scss";
|
||||
@import "framework/common.scss";
|
||||
@import "framework/dropdowns.scss";
|
||||
@import "framework/files.scss";
|
||||
@import "framework/filters.scss";
|
||||
@import "framework/flash.scss";
|
||||
|
|
|
@ -60,25 +60,6 @@ hr {
|
|||
margin: $gl-padding 0;
|
||||
}
|
||||
|
||||
.dropdown-menu {
|
||||
margin: 6px 0 0;
|
||||
}
|
||||
|
||||
.dropdown-menu > li > a {
|
||||
text-shadow: none;
|
||||
}
|
||||
|
||||
.dropdown-menu-align-right {
|
||||
left: auto;
|
||||
right: 0px;
|
||||
}
|
||||
|
||||
.dropdown-menu > li > a:hover,
|
||||
.dropdown-menu > li > a:focus {
|
||||
background: $gl-primary;
|
||||
color: #FFF;
|
||||
}
|
||||
|
||||
.str-truncated {
|
||||
@include str-truncated;
|
||||
}
|
||||
|
|
102
app/assets/stylesheets/framework/dropdowns.scss
Normal file
102
app/assets/stylesheets/framework/dropdowns.scss
Normal file
|
@ -0,0 +1,102 @@
|
|||
.caret {
|
||||
display: inline-block;
|
||||
width: 0;
|
||||
height: 0;
|
||||
margin-left: 2px;
|
||||
vertical-align: middle;
|
||||
border-top: $caret-width-base dashed $dropdown-caret-color;
|
||||
border-right: $caret-width-base solid transparent;
|
||||
border-left: $caret-width-base solid transparent;
|
||||
}
|
||||
|
||||
.dropdown {
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.open {
|
||||
.dropdown-menu {
|
||||
display: block;
|
||||
}
|
||||
}
|
||||
|
||||
.dropdown-menu {
|
||||
display: none;
|
||||
position: absolute;
|
||||
top: 100%;
|
||||
left: 0;
|
||||
z-index: 9999;
|
||||
width: 240px;
|
||||
margin-top: 2px;
|
||||
margin-bottom: 0;
|
||||
padding: 10px 10px;
|
||||
font-size: 14px;
|
||||
font-weight: normal;
|
||||
background-color: $dropdown-bg;
|
||||
border: 1px solid $dropdown-border-color;
|
||||
border-radius: $border-radius-base;
|
||||
box-shadow: 0 2px 4px $dropdown-shadow-color;
|
||||
|
||||
li {
|
||||
text-align: left;
|
||||
list-style: none;
|
||||
}
|
||||
|
||||
.divider {
|
||||
width: 100%;
|
||||
height: 1px;
|
||||
margin-top: 8px;
|
||||
margin-bottom: 8px;
|
||||
background-color: $dropdown-divider-color;
|
||||
}
|
||||
|
||||
a {
|
||||
display: block;
|
||||
position: relative;
|
||||
padding-left: 10px;
|
||||
padding-right: 10px;
|
||||
color: $dropdown-link-color;
|
||||
line-height: 34px;
|
||||
text-overflow: ellipsis;
|
||||
border-radius: 2px;
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
|
||||
&:hover {
|
||||
background-color: $dropdown-link-hover-bg;
|
||||
text-decoration: none;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.dropdown-menu-align-right {
|
||||
left: auto;
|
||||
right: 0;
|
||||
}
|
||||
|
||||
.dropdown-menu-selectable {
|
||||
a {
|
||||
padding-left: 25px;
|
||||
|
||||
&.is-active {
|
||||
&::before {
|
||||
content: "\f00c";
|
||||
position: absolute;
|
||||
left: 4px;
|
||||
top: 8px;
|
||||
font: normal normal normal 14px/1 FontAwesome;
|
||||
font-size: inherit;
|
||||
text-rendering: auto;
|
||||
-webkit-font-smoothing: antialiased;
|
||||
-moz-osx-font-smoothing: grayscale;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.dropdown-header {
|
||||
padding-left: 10px;
|
||||
padding-right: 10px;
|
||||
color: $dropdown-header-color;
|
||||
font-size: 13px;
|
||||
line-height: 22px;
|
||||
}
|
|
@ -22,7 +22,7 @@
|
|||
|
||||
// Components
|
||||
@import "bootstrap/component-animations";
|
||||
@import "bootstrap/dropdowns";
|
||||
// @import "bootstrap/dropdowns";
|
||||
@import "bootstrap/button-groups";
|
||||
@import "bootstrap/input-groups";
|
||||
@import "bootstrap/navs";
|
||||
|
|
|
@ -126,3 +126,15 @@ $deleted: #f77;
|
|||
*/
|
||||
$monospace_font: 'Menlo', 'Liberation Mono', 'Consolas', 'DejaVu Sans Mono', 'Ubuntu Mono', 'Courier New', 'andale mono', 'lucida console', monospace;
|
||||
$regular_font: 'Source Sans Pro', "Helvetica Neue", Helvetica, Arial, sans-serif;
|
||||
|
||||
/*
|
||||
* Dropdowns
|
||||
*/
|
||||
$dropdown-bg: #fff;
|
||||
$dropdown-link-color: #555;
|
||||
$dropdown-link-hover-bg: rgba(#000, .04);
|
||||
$dropdown-border-color: rgba(#000, .1);
|
||||
$dropdown-shadow-color: rgba(#000, .1);
|
||||
$dropdown-divider-color: rgba(#000, .1);
|
||||
$dropdown-header-color: #959494;
|
||||
$dropdown-caret-color: #54565B;
|
||||
|
|
|
@ -49,10 +49,6 @@
|
|||
}
|
||||
}
|
||||
|
||||
.project-home-dropdown {
|
||||
margin: 13px 0px 0;
|
||||
}
|
||||
|
||||
.notifications-btn {
|
||||
margin-top: -28px;
|
||||
|
||||
|
@ -185,29 +181,6 @@
|
|||
}
|
||||
}
|
||||
|
||||
.dropdown-menu {
|
||||
@include box-shadow(rgba(76, 86, 103, 0.247059) 0px 0px 1px 0px, rgba(31, 37, 50, 0.317647) 0px 2px 18px 0px);
|
||||
@include border-radius ($border-radius-default);
|
||||
|
||||
border: none;
|
||||
padding: 10px 0;
|
||||
font-size: 14px;
|
||||
font-weight: 100;
|
||||
|
||||
li a {
|
||||
color: #5f697a;
|
||||
line-height: 30px;
|
||||
|
||||
&:hover {
|
||||
background-color: #3084bb !important;
|
||||
}
|
||||
}
|
||||
|
||||
i {
|
||||
margin-right: 8px;
|
||||
}
|
||||
}
|
||||
|
||||
.project-visibility-level-holder {
|
||||
.radio {
|
||||
margin-bottom: 10px;
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
- else
|
||||
= sort_title_recently_updated
|
||||
%b.caret
|
||||
%ul.dropdown-menu
|
||||
%ul.dropdown-menu.dropdown-menu-align-right
|
||||
%li
|
||||
= link_to explore_projects_filter_path(sort: sort_value_name) do
|
||||
= sort_title_name
|
||||
|
|
Loading…
Reference in a new issue