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
1
Merge Requests
1
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
nexedi
gitlab-ce
Commits
d718209b
Commit
d718209b
authored
Jun 14, 2014
by
Job van der Voort
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
responsive sidebar on dashboard
parent
8b6dd9d4
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
7 additions
and
7 deletions
+7
-7
app/assets/javascripts/sidebar.js.coffee
app/assets/javascripts/sidebar.js.coffee
+4
-2
app/assets/stylesheets/generic/sidebar.scss
app/assets/stylesheets/generic/sidebar.scss
+2
-4
app/views/dashboard/show.html.haml
app/views/dashboard/show.html.haml
+1
-1
No files found.
app/assets/javascripts/sidebar.js.coffee
View file @
d718209b
responsive_resize
=
->
current_width
=
$
(
window
).
width
()
if
current_width
<
985
$
(
'.side'
).
addClass
(
"ui right wide sidebar"
)
$
(
'.
responsive-
side'
).
addClass
(
"ui right wide sidebar"
)
else
$
(
'.side'
).
removeClass
(
"ui right wide sidebar"
)
$
(
'.
responsive-
side'
).
removeClass
(
"ui right wide sidebar"
)
$
->
# Depending on window size, set the sidebar offscreen.
responsive_resize
()
$
(
'.ui.sidebar'
)
...
...
@@ -22,6 +23,7 @@ $ ->
container
.
sidebar
"hide"
if
not
container
.
is
(
e
.
target
)
and
container
.
has
(
e
.
target
).
length
is
0
return
# On resize, check if sidebar should be offscreen.
$
(
window
).
resize
->
responsive_resize
()
return
app/assets/stylesheets/generic/sidebar.scss
View file @
d718209b
...
...
@@ -7,12 +7,11 @@
}
.sidebar-expand-button
{
background
:
#f
ff
;
background
:
#f
9f9f9
;
color
:
#555
;
padding
:
10px
15
px
;
padding
:
9px
12px
6px
14
px
;
border
:
1px
solid
#E1E1E1
;
border-right
:
0
;
border-radius
:
3px
;
position
:
fixed
;
top
:
108px
;
right
:
0px
;
...
...
@@ -22,7 +21,6 @@
-moz-transition
:
all
0
.4s
;
-webkit-transition
:
all
0
.4s
;
&
:hover
{
background
:
#ddd
;
color
:
#333
;
...
...
app/views/dashboard/show.html.haml
View file @
d718209b
...
...
@@ -2,7 +2,7 @@
.dashboard.row
.activities.col-md-8
=
render
'activities'
.side.col-md-4
.side.col-md-4
.responsive-side
=
render
'sidebar'
.sidebar-expand-button.hidden-lg.hidden-md
...
...
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