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
58af2647
Commit
58af2647
authored
Oct 20, 2017
by
Annabel Dunstone Gray
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Rename new_sidebar in JS
parent
33380f81
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
5 deletions
+5
-5
app/assets/javascripts/contextual_sidebar.js
app/assets/javascripts/contextual_sidebar.js
+2
-2
app/assets/javascripts/layout_nav.js
app/assets/javascripts/layout_nav.js
+3
-3
No files found.
app/assets/javascripts/
new
_sidebar.js
→
app/assets/javascripts/
contextual
_sidebar.js
View file @
58af2647
...
@@ -2,7 +2,7 @@ import Cookies from 'js-cookie';
...
@@ -2,7 +2,7 @@ import Cookies from 'js-cookie';
import
_
from
'
underscore
'
;
import
_
from
'
underscore
'
;
import
bp
from
'
./breakpoints
'
;
import
bp
from
'
./breakpoints
'
;
export
default
class
NewNav
Sidebar
{
export
default
class
Contextual
Sidebar
{
constructor
()
{
constructor
()
{
this
.
initDomElements
();
this
.
initDomElements
();
this
.
render
();
this
.
render
();
...
@@ -55,7 +55,7 @@ export default class NewNavSidebar {
...
@@ -55,7 +55,7 @@ export default class NewNavSidebar {
this
.
$sidebar
.
toggleClass
(
'
sidebar-icons-only
'
,
collapsed
);
this
.
$sidebar
.
toggleClass
(
'
sidebar-icons-only
'
,
collapsed
);
this
.
$page
.
toggleClass
(
'
page-with-icon-sidebar
'
,
breakpoint
===
'
sm
'
?
true
:
collapsed
);
this
.
$page
.
toggleClass
(
'
page-with-icon-sidebar
'
,
breakpoint
===
'
sm
'
?
true
:
collapsed
);
}
}
NewNav
Sidebar
.
setCollapsedCookie
(
collapsed
);
Contextual
Sidebar
.
setCollapsedCookie
(
collapsed
);
this
.
toggleSidebarOverflow
();
this
.
toggleSidebarOverflow
();
}
}
...
...
app/assets/javascripts/layout_nav.js
View file @
58af2647
/* eslint-disable func-names, space-before-function-paren, no-var, prefer-arrow-callback, no-unused-vars, one-var, one-var-declaration-per-line, vars-on-top, max-len */
/* eslint-disable func-names, space-before-function-paren, no-var, prefer-arrow-callback, no-unused-vars, one-var, one-var-declaration-per-line, vars-on-top, max-len */
import
_
from
'
underscore
'
;
import
_
from
'
underscore
'
;
import
Cookies
from
'
js-cookie
'
;
import
Cookies
from
'
js-cookie
'
;
import
NewNavSidebar
from
'
./new
_sidebar
'
;
import
ContextualSidebar
from
'
./contextual
_sidebar
'
;
import
initFlyOutNav
from
'
./fly_out_nav
'
;
import
initFlyOutNav
from
'
./fly_out_nav
'
;
(
function
()
{
(
function
()
{
...
@@ -51,8 +51,8 @@ import initFlyOutNav from './fly_out_nav';
...
@@ -51,8 +51,8 @@ import initFlyOutNav from './fly_out_nav';
});
});
$
(()
=>
{
$
(()
=>
{
const
newNavSidebar
=
new
NewNav
Sidebar
();
const
contextualSidebar
=
new
Contextual
Sidebar
();
newNav
Sidebar
.
bindEvents
();
contextual
Sidebar
.
bindEvents
();
initFlyOutNav
();
initFlyOutNav
();
});
});
...
...
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