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
Jérome Perrin
gitlab-ce
Commits
bf970141
Commit
bf970141
authored
Jun 30, 2016
by
Phil Hughes
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Expiry date on pinned nav cookie
parent
2efee5f6
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
app/assets/javascripts/application.js.coffee
app/assets/javascripts/application.js.coffee
+2
-2
No files found.
app/assets/javascripts/application.js.coffee
View file @
bf970141
...
@@ -261,7 +261,7 @@ $ ->
...
@@ -261,7 +261,7 @@ $ ->
# Sidenav pinning
# Sidenav pinning
if
$window
.
width
()
<
1280
and
$
.
cookie
(
'pin_nav'
)
is
'true'
if
$window
.
width
()
<
1280
and
$
.
cookie
(
'pin_nav'
)
is
'true'
$
.
cookie
(
'pin_nav'
,
'false'
,
{
path
:
'/'
})
$
.
cookie
(
'pin_nav'
,
'false'
,
{
path
:
'/'
,
expires
:
365
*
10
})
$
(
'.page-with-sidebar'
)
$
(
'.page-with-sidebar'
)
.
toggleClass
(
'page-sidebar-collapsed page-sidebar-expanded'
)
.
toggleClass
(
'page-sidebar-collapsed page-sidebar-expanded'
)
.
removeClass
(
'page-sidebar-pinned'
)
.
removeClass
(
'page-sidebar-pinned'
)
...
@@ -292,7 +292,7 @@ $ ->
...
@@ -292,7 +292,7 @@ $ ->
.
toggleClass
(
'header-collapsed header-expanded'
)
.
toggleClass
(
'header-collapsed header-expanded'
)
# Save settings
# Save settings
$
.
cookie
'pin_nav'
,
doPinNav
,
{
path
:
'/'
}
$
.
cookie
'pin_nav'
,
doPinNav
,
{
path
:
'/'
,
expires
:
365
*
10
}
if
$
.
cookie
(
'pin_nav'
)
is
'true'
or
doPinNav
if
$
.
cookie
(
'pin_nav'
)
is
'true'
or
doPinNav
tooltipText
=
'Unpin navigation'
tooltipText
=
'Unpin navigation'
...
...
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