Skip to content

Commit

Permalink
Merge branch 'main-js-tidy-up' into 'master'
Browse files Browse the repository at this point in the history
Tidy up main JS file

See merge request gitlab-org/gitlab-ce!16007
  • Loading branch information
Filipa Lacerda committed Jan 11, 2018
2 parents f09735d + ff0f74a commit 1245d35
Show file tree
Hide file tree
Showing 49 changed files with 145 additions and 140 deletions.
1 change: 0 additions & 1 deletion .eslintrc
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@
],
"globals": {
"__webpack_public_path__": true,
"_": false,
"gl": false,
"gon": false,
"localStorage": false
Expand Down
2 changes: 2 additions & 0 deletions app/assets/javascripts/blob/blob_file_dropzone.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ import { visitUrl } from '../lib/utils/url_utility';
import { HIDDEN_CLASS } from '../lib/utils/constants';
import csrf from '../lib/utils/csrf';

Dropzone.autoDiscover = false;

function toggleLoading($el, $icon, loading) {
if (loading) {
$el.disable();
Expand Down
2 changes: 1 addition & 1 deletion app/assets/javascripts/boards/components/board.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/* eslint-disable comma-dangle, space-before-function-paren, one-var */
/* global Sortable */
import Sortable from 'vendor/Sortable';
import Vue from 'vue';
import AccessorUtilities from '../../lib/utils/accessor';
import boardList from './board_list';
Expand Down
2 changes: 1 addition & 1 deletion app/assets/javascripts/boards/components/board_list.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/* global Sortable */
import Sortable from 'vendor/Sortable';
import boardNewIssue from './board_new_issue';
import boardCard from './board_card.vue';
import eventHub from '../eventhub';
Expand Down
1 change: 1 addition & 0 deletions app/assets/javascripts/create_merge_request_dropdown.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
/* eslint-disable no-new */
import _ from 'underscore';
import Flash from './flash';
import DropLab from './droplab/drop_lab';
import ISetter from './droplab/plugins/input_setter';
Expand Down
2 changes: 2 additions & 0 deletions app/assets/javascripts/dropzone_input.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ import _ from 'underscore';
import './preview_markdown';
import csrf from './lib/utils/csrf';

Dropzone.autoDiscover = false;

export default function dropzoneInput(form) {
const divHover = '<div class="div-dropzone-hover"></div>';
const iconPaperclip = '<i class="fa fa-paperclip div-dropzone-icon"></i>';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/**
* Common code between environmets app and folder view
*/

import _ from 'underscore';
import Visibility from 'visibilityjs';
import Poll from '../../lib/utils/poll';
import {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import _ from 'underscore';
import DropLab from '~/droplab/drop_lab';
import FilteredSearchContainer from './container';

Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import _ from 'underscore';
import { visitUrl } from '../lib/utils/url_utility';
import Flash from '../flash';
import FilteredSearchContainer from './container';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import _ from 'underscore';
import AjaxCache from '../lib/utils/ajax_cache';
import Flash from '../flash';
import FilteredSearchContainer from './container';
Expand Down
1 change: 1 addition & 0 deletions app/assets/javascripts/ide/lib/editor.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import _ from 'underscore';
import DecorationsController from './decorations/controller';
import DirtyDiffController from './diff/controller';
import Disposable from './common/disposable';
Expand Down
2 changes: 2 additions & 0 deletions app/assets/javascripts/ide/stores/utils.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
import _ from 'underscore';

export const dataStructure = () => ({
id: '',
key: '',
Expand Down
2 changes: 1 addition & 1 deletion app/assets/javascripts/label_manager.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/* eslint-disable comma-dangle, class-methods-use-this, no-underscore-dangle, no-param-reassign, no-unused-vars, consistent-return, func-names, space-before-function-paren, max-len */
/* global Sortable */
import Sortable from 'vendor/Sortable';

import Flash from './flash';

Expand Down
Loading

0 comments on commit 1245d35

Please sign in to comment.