Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Léo-Paul Géneau
gitlab-ce
Commits
9d51f866
Commit
9d51f866
authored
Mar 25, 2016
by
Alfredo Sumaran
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Makes autocomplete dropdown look the same as others
parent
8e53cf94
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
62 additions
and
25 deletions
+62
-25
app/assets/javascripts/gl_dropdown.js.coffee
app/assets/javascripts/gl_dropdown.js.coffee
+1
-1
app/assets/javascripts/search_autocomplete.js.coffee
app/assets/javascripts/search_autocomplete.js.coffee
+1
-1
app/assets/stylesheets/framework/dropdowns.scss
app/assets/stylesheets/framework/dropdowns.scss
+40
-18
app/assets/stylesheets/framework/variables.scss
app/assets/stylesheets/framework/variables.scss
+5
-2
app/assets/stylesheets/pages/search.scss
app/assets/stylesheets/pages/search.scss
+11
-0
app/views/layouts/_search.html.haml
app/views/layouts/_search.html.haml
+4
-3
No files found.
app/assets/javascripts/gl_dropdown.js.coffee
View file @
9d51f866
...
...
@@ -300,7 +300,7 @@ class GitLabDropdown
noResults
:
->
html
=
"<li>"
html
+=
"<a
href='#'
class='dropdown-menu-empty-link is-focused'>"
html
+=
"<a class='dropdown-menu-empty-link is-focused'>"
html
+=
"No matching results."
html
+=
"</a>"
html
+=
"</li>"
...
...
app/assets/javascripts/search_autocomplete.js.coffee
View file @
9d51f866
...
...
@@ -260,6 +260,6 @@ class @SearchAutocomplete
restoreMenu
:
->
html
=
"<ul>
<li><a class='is-focused'>Loading...</a></li>
<li><a class='
dropdown-menu-empty-link
is-focused'>Loading...</a></li>
</ul>"
@
dropdownContent
.
html
(
html
)
app/assets/stylesheets/framework/dropdowns.scss
View file @
9d51f866
...
...
@@ -42,7 +42,7 @@
font-size
:
15px
;
text-align
:
left
;
border
:
1px
solid
$dropdown-toggle-border-color
;
border-radius
:
2px
;
border-radius
:
$dropdown-border-radius
;
outline
:
0
;
text-overflow
:
ellipsis
;
white-space
:
nowrap
;
...
...
@@ -75,12 +75,12 @@
width
:
240px
;
margin-top
:
2px
;
margin-bottom
:
0
;
padding
:
10px
;
font-size
:
14px
;
font-size
:
15px
;
font-weight
:
normal
;
padding
:
10px
0
;
background-color
:
$dropdown-bg
;
border
:
1px
solid
$dropdown-border-color
;
border-radius
:
$
border-radius-base
;
border-radius
:
$
dropdown-border-radius
;
box-shadow
:
0
2px
4px
$dropdown-shadow-color
;
&
.is-loading
{
...
...
@@ -101,9 +101,17 @@
li
{
text-align
:
left
;
list-style
:
none
;
padding
:
0
10px
;
}
.divider
{
height
:
1px
;
margin
:
8px
10px
;
padding
:
0
;
background-color
:
$dropdown-divider-color
;
}
.separator
{
width
:
100%
;
height
:
1px
;
margin-top
:
8px
;
...
...
@@ -137,6 +145,17 @@
}
}
}
.dropdown-header
{
color
:
$dropdown-header-color
;
font-size
:
13px
;
line-height
:
22px
;
padding
:
0
10px
10px
;
}
.separator
+
.dropdown-header
{
padding-top
:
2px
;
}
}
.dropdown-menu-paging
{
...
...
@@ -154,6 +173,10 @@
.dropdown-menu-back
{
display
:
block
;
}
.dropdown-content
{
padding
:
0
10px
;
}
}
}
...
...
@@ -218,20 +241,11 @@
}
}
.dropdown-header
{
padding-left
:
5px
;
padding-right
:
5px
;
color
:
$dropdown-header-color
;
font-size
:
13px
;
line-height
:
22px
;
}
.dropdown-title
{
position
:
relative
;
margin-bottom
:
10px
;
padding-left
:
30px
;
padding-right
:
30px
;
padding-bottom
:
10px
;
padding
:
0
0
15px
;
margin
:
0
10px
10px
;
font-weight
:
600
;
line-height
:
1
;
text-align
:
center
;
...
...
@@ -257,21 +271,26 @@
}
.dropdown-menu-close
{
right
:
0
;
right
:
7px
;
width
:
20px
;
height
:
20px
;
top
:
-1px
;
}
.dropdown-menu-back
{
left
:
0
;
left
:
7px
;
top
:
2px
;
}
.dropdown-input
{
position
:
relative
;
margin-bottom
:
10px
;
padding
:
0
10px
;
.fa
{
position
:
absolute
;
top
:
10px
;
right
:
1
0px
;
right
:
2
0px
;
color
:
#c7c7c7
;
font-size
:
12px
;
pointer-events
:
none
;
...
...
@@ -281,6 +300,9 @@
display
:
none
;
cursor
:
pointer
;
pointer-events
:
all
;
right
:
22px
;
top
:
9px
;
font-size
:
14px
;
}
&
.has-value
{
...
...
app/assets/stylesheets/framework/variables.scss
View file @
9d51f866
...
...
@@ -66,7 +66,7 @@ $header-height: 58px;
$fixed-layout-width
:
1280px
;
$gl-avatar-size
:
40px
;
$error-exclamation-point
:
#e62958
;
$border-radius-default
:
3
px
;
$border-radius-default
:
2
px
;
$btn-transparent-color
:
#8f8f8f
;
$ssh-key-icon-color
:
#8f8f8f
;
$ssh-key-icon-size
:
18px
;
...
...
@@ -166,6 +166,7 @@ $regular_font: 'Source Sans Pro', "Helvetica Neue", Helvetica, Arial, sans-serif
/*
* Dropdowns
*/
$dropdown-border-radius
:
2px
;
$dropdown-width
:
300px
;
$dropdown-bg
:
#fff
;
$dropdown-link-color
:
#555
;
...
...
@@ -178,7 +179,7 @@ $dropdown-header-color: #959494;
$dropdown-title-btn-color
:
#bfbfbf
;
$dropdown-input-color
:
#555
;
$dropdown-input-focus-border
:
rgb
(
58
,
171
,
240
);
$dropdown-input-focus-shadow
:
rgba
(
#000
,
.2
);
$dropdown-input-focus-shadow
:
rgba
(
$dropdown-input-focus-border
,
.4
);
$dropdown-loading-bg
:
rgba
(
#fff
,
.6
);
$dropdown-toggle-bg
:
#fff
;
...
...
@@ -198,6 +199,8 @@ $award-emoji-new-btn-icon-color: #dcdcdc;
/*
* Search Box
*/
$search-input-border-color
:
$dropdown-input-focus-border
;
$search-input-focus-shadow-color
:
$dropdown-input-focus-shadow
;
$search-input-width
:
$dropdown-width
;
$location-badge-color
:
#aaa
;
$location-badge-bg
:
$gray-normal
;
...
...
app/assets/stylesheets/pages/search.scss
View file @
9d51f866
...
...
@@ -109,12 +109,23 @@
.dropdown-menu
{
top
:
30px
;
left
:
-5px
;
padding
:
0
;
ul
{
padding
:
10px
0
;
}
}
.dropdown-content
{
max-height
:
300px
;
}
}
&
.search-active
{
form
{
@extend
.form-control
:focus
;
border-color
:
$dropdown-input-focus-border
;
box-shadow
:
0
0
4px
$search-input-focus-shadow-color
;
}
.location-badge
{
...
...
app/views/layouts/_search.html.haml
View file @
9d51f866
...
...
@@ -16,9 +16,10 @@
=
search_field_tag
"search"
,
nil
,
placeholder:
'Search'
,
class:
"search-input dropdown-menu-toggle"
,
spellcheck:
false
,
tabindex:
"1"
,
autocomplete:
'off'
,
data:
{
toggle:
'dropdown'
}
.dropdown-menu.dropdown-select
=
dropdown_content
do
%li
%a
.is-focused
Loading...
%ul
%li
%a
.is-focused.dropdown-menu-empty-link
Loading...
=
dropdown_loading
%i
.search-icon
%i
.clear-icon.js-clear-input
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment