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
Boxiang Sun
gitlab-ce
Commits
f8909396
Commit
f8909396
authored
7 years ago
by
Mike Greiling
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
refactor Wikis class to ES module syntax
parent
5d342378
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
3 additions
and
7 deletions
+3
-7
app/assets/javascripts/dispatcher.js
app/assets/javascripts/dispatcher.js
+2
-1
app/assets/javascripts/main.js
app/assets/javascripts/main.js
+0
-1
app/assets/javascripts/wikis.js
app/assets/javascripts/wikis.js
+1
-5
No files found.
app/assets/javascripts/dispatcher.js
View file @
f8909396
...
...
@@ -53,6 +53,7 @@ import UsersSelect from './users_select';
import
RefSelectDropdown
from
'
./ref_select_dropdown
'
;
import
GfmAutoComplete
from
'
./gfm_auto_complete
'
;
import
ShortcutsBlob
from
'
./shortcuts_blob
'
;
import
Wikis
from
'
./wikis
'
;
import
ZenMode
from
'
./zen_mode
'
;
import
initSettingsPanels
from
'
./settings_panels
'
;
import
initExperimentalFlags
from
'
./experimental_flags
'
;
...
...
@@ -483,7 +484,7 @@ import OAuthRememberMe from './oauth_remember_me';
new
NotificationsDropdown
();
break
;
case
'
wikis
'
:
new
gl
.
Wikis
();
new
Wikis
();
shortcut_handler
=
new
ShortcutsWiki
();
new
ZenMode
();
new
gl
.
GLForm
(
$
(
'
.wiki-form
'
),
true
);
...
...
This diff is collapsed.
Click to expand it.
app/assets/javascripts/main.js
View file @
f8909396
...
...
@@ -161,7 +161,6 @@ import './username_validator';
import
'
./users_select
'
;
import
'
./version_check_image
'
;
import
'
./visibility_select
'
;
import
'
./wikis
'
;
// eslint-disable-next-line global-require, import/no-commonjs
if
(
process
.
env
.
NODE_ENV
!==
'
production
'
)
require
(
'
./test_utils/
'
);
...
...
This diff is collapsed.
Click to expand it.
app/assets/javascripts/wikis.js
View file @
f8909396
/* eslint-disable no-param-reassign */
/* global Breakpoints */
import
'
vendor/jquery.nicescroll
'
;
import
'
./breakpoints
'
;
class
Wikis
{
export
default
class
Wikis
{
constructor
()
{
this
.
bp
=
Breakpoints
.
get
();
this
.
sidebarEl
=
document
.
querySelector
(
'
.js-wiki-sidebar
'
);
...
...
@@ -63,6 +62,3 @@ class Wikis {
}
}
}
window
.
gl
=
window
.
gl
||
{};
window
.
gl
.
Wikis
=
Wikis
;
This diff is collapsed.
Click to expand it.
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