Commit fe964cc2 authored by Mike Greiling's avatar Mike Greiling

migrate all javascript asset bundles and require syntax

parent 55f291e8
...@@ -15,6 +15,8 @@ ...@@ -15,6 +15,8 @@
"filenames" "filenames"
], ],
"rules": { "rules": {
"filenames/match-regex": [2, "^[a-z0-9_]+(.js)?$"] "filenames/match-regex": [2, "^[a-z0-9_]+(.js)?$"],
"import/no-extraneous-dependencies": "off",
"import/no-unresolved": "off"
} }
} }
/* eslint-disable func-names, space-before-function-paren, no-var, quotes, consistent-return, prefer-arrow-callback, comma-dangle, object-shorthand, no-new, max-len */ /* eslint-disable func-names, space-before-function-paren, no-var, quotes, consistent-return, prefer-arrow-callback, comma-dangle, object-shorthand, no-new, max-len, no-multi-spaces, import/newline-after-import */
/* global bp */ /* global bp */
/* global Cookies */ /* global Cookies */
/* global Flash */ /* global Flash */
...@@ -6,62 +6,59 @@ ...@@ -6,62 +6,59 @@
/* global AwardsHandler */ /* global AwardsHandler */
/* global Aside */ /* global Aside */
// This is a manifest file that'll be compiled into including all the files listed below. function requireAll(context) { return context.keys().map(context); }
// Add new JavaScript code in separate files in this directory and they'll automatically
// be included in the compiled file accessible from http://example.com/assets/application.js window.$ = window.jQuery = require('jquery');
// It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the require('jquery-ui/ui/autocomplete');
// the compiled file. require('jquery-ui/ui/datepicker');
// require('jquery-ui/ui/draggable');
/*= require jquery2 */ require('jquery-ui/ui/effect-highlight');
/*= require jquery-ui/autocomplete */ require('jquery-ui/ui/sortable');
/*= require jquery-ui/datepicker */ require('jquery-ujs');
/*= require jquery-ui/draggable */ require('vendor/jquery.endless-scroll');
/*= require jquery-ui/effect-highlight */ require('vendor/jquery.highlight');
/*= require jquery-ui/sortable */ require('vendor/jquery.waitforimages');
/*= require jquery_ujs */ require('vendor/jquery.caret');
/*= require jquery.endless-scroll */ require('vendor/jquery.atwho');
/*= require jquery.highlight */ require('vendor/jquery.scrollTo');
/*= require jquery.waitforimages */ require('vendor/jquery.turbolinks');
/*= require jquery.caret */ window.Cookies = require('vendor/js.cookie');
/*= require jquery.atwho */ require('vendor/turbolinks');
/*= require jquery.scrollTo */ require('./autosave');
/*= require jquery.turbolinks */ require('bootstrap/js/affix');
/*= require js.cookie */ require('bootstrap/js/alert');
/*= require turbolinks */ require('bootstrap/js/button');
/*= require autosave */ require('bootstrap/js/collapse');
/*= require bootstrap/affix */ require('bootstrap/js/dropdown');
/*= require bootstrap/alert */ require('bootstrap/js/modal');
/*= require bootstrap/button */ require('bootstrap/js/scrollspy');
/*= require bootstrap/collapse */ require('bootstrap/js/tab');
/*= require bootstrap/dropdown */ require('bootstrap/js/transition');
/*= require bootstrap/modal */ require('bootstrap/js/tooltip');
/*= require bootstrap/scrollspy */ require('bootstrap/js/popover');
/*= require bootstrap/tab */ require('select2/select2.js');
/*= require bootstrap/transition */ window._ = require('underscore');
/*= require bootstrap/tooltip */ window.Dropzone = require('dropzone');
/*= require bootstrap/popover */ require('mousetrap');
/*= require select2 */ require('mousetrap/plugins/pause/mousetrap-pause');
/*= require underscore */ require('./shortcuts');
/*= require dropzone */ require('./shortcuts_navigation');
/*= require mousetrap */ require('./shortcuts_dashboard_navigation');
/*= require mousetrap/pause */ require('./shortcuts_issuable');
/*= require shortcuts */ require('./shortcuts_network');
/*= require shortcuts_navigation */ require('vendor/jquery.nicescroll');
/*= require shortcuts_dashboard_navigation */ require('vendor/date.format');
/*= require shortcuts_issuable */ requireAll(require.context('./behaviors', false, /^\.\/.*\.(js|es6)$/));
/*= require shortcuts_network */ requireAll(require.context('./blob', false, /^\.\/.*\.(js|es6)$/));
/*= require jquery.nicescroll */ requireAll(require.context('./templates', false, /^\.\/.*\.(js|es6)$/));
/*= require date.format */ requireAll(require.context('./commit', false, /^\.\/.*\.(js|es6)$/));
/*= require_directory ./behaviors */ requireAll(require.context('./extensions', false, /^\.\/.*\.(js|es6)$/));
/*= require_directory ./blob */ requireAll(require.context('./lib/utils', false, /^\.\/.*\.(js|es6)$/));
/*= require_directory ./templates */ requireAll(require.context('./u2f', false, /^\.\/.*\.(js|es6)$/));
/*= require_directory ./commit */ requireAll(require.context('.', false, /^\.\/(?!application).*\.(js|es6)$/));
/*= require_directory ./extensions */ require('vendor/fuzzaldrin-plus');
/*= require_directory ./lib/utils */ window.ES6Promise = require('vendor/es6-promise.auto');
/*= require_directory ./u2f */ window.ES6Promise.polyfill();
/*= require_directory . */
/*= require fuzzaldrin-plus */
/*= require es6-promise.auto */
(function () { (function () {
document.addEventListener('page:fetch', function () { document.addEventListener('page:fetch', function () {
......
/* eslint-disable func-names, space-before-function-paren, wrap-iife, max-len, no-var, spaced-comment, prefer-arrow-callback, consistent-return, one-var, one-var-declaration-per-line, no-unused-vars, no-else-return, prefer-template, quotes, comma-dangle, no-param-reassign, no-void, radix, keyword-spacing, space-before-blocks, brace-style, no-underscore-dangle, no-plusplus, no-return-assign, camelcase, padded-blocks */ /* eslint-disable func-names, space-before-function-paren, wrap-iife, max-len, no-var, spaced-comment, prefer-arrow-callback, consistent-return, one-var, one-var-declaration-per-line, no-unused-vars, no-else-return, prefer-template, quotes, comma-dangle, no-param-reassign, no-void, radix, keyword-spacing, space-before-blocks, brace-style, no-underscore-dangle, no-plusplus, no-return-assign, camelcase, padded-blocks */
/* global Cookies */ /* global Cookies */
var emojiAliases = require('emoji-aliases');
(function() { (function() {
this.AwardsHandler = (function() { this.AwardsHandler = (function() {
var FROM_SENTENCE_REGEX = /(?:, and | and |, )/; //For separating lists produced by ruby's Array#toSentence var FROM_SENTENCE_REGEX = /(?:, and | and |, )/; //For separating lists produced by ruby's Array#toSentence
function AwardsHandler() { function AwardsHandler() {
this.aliases = gl.emojiAliases(); this.aliases = emojiAliases;
$(document).off('click', '.js-add-award').on('click', '.js-add-award', (function(_this) { $(document).off('click', '.js-add-award').on('click', '.js-add-award', (function(_this) {
return function(e) { return function(e) {
e.stopPropagation(); e.stopPropagation();
......
/* eslint-disable func-names, space-before-function-paren, prefer-arrow-callback, no-var, consistent-return, padded-blocks, max-len */ /* eslint-disable func-names, space-before-function-paren, prefer-arrow-callback, no-var, consistent-return, padded-blocks, max-len */
/* global autosize */ /* global autosize */
/*= require jquery.ba-resize */ var autosize = require('vendor/autosize');
/*= require autosize */ require('vendor/jquery.ba-resize');
(function() { (function() {
$(function() { $(function() {
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
// "Meta+Enter" (Mac) or "Ctrl+Enter" (Linux/Windows) key combination, the form // "Meta+Enter" (Mac) or "Ctrl+Enter" (Linux/Windows) key combination, the form
// is submitted. // is submitted.
// //
/*= require extensions/jquery */ require('../extensions/jquery');
// //
// ### Example Markup // ### Example Markup
......
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
// When called on a form with input fields with the `required` attribute, the // When called on a form with input fields with the `required` attribute, the
// form's submit button will be disabled until all required fields have values. // form's submit button will be disabled until all required fields have values.
// //
/*= require extensions/jquery */ require('../extensions/jquery');
// //
// ### Example Markup // ### Example Markup
......
/* eslint-disable padded-blocks, no-param-reassign, comma-dangle */ /* eslint-disable padded-blocks, no-param-reassign, comma-dangle */
/* global Api */ /* global Api */
/*= require blob/template_selector */ require('./template_selector');
((global) => { ((global) => {
class BlobCiYamlSelector extends gl.TemplateSelector { class BlobCiYamlSelector extends gl.TemplateSelector {
......
/* global Api */ /* global Api */
/*= require blob/template_selector */
require('./template_selector');
(() => { (() => {
const global = window.gl || (window.gl = {}); const global = window.gl || (window.gl = {});
......
/* eslint-disable func-names, space-before-function-paren, max-len, one-var, no-var, no-restricted-syntax, vars-on-top, no-use-before-define, no-param-reassign, new-cap, no-underscore-dangle, wrap-iife, prefer-rest-params, padded-blocks */ /* eslint-disable func-names, space-before-function-paren, max-len, one-var, no-var, no-restricted-syntax, vars-on-top, no-use-before-define, no-param-reassign, new-cap, no-underscore-dangle, wrap-iife, prefer-rest-params, padded-blocks */
/* global Api */ /* global Api */
/*= require blob/template_selector */ require('./template_selector');
(function() { (function() {
var extend = function(child, parent) { for (var key in parent) { if (hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; }, var extend = function(child, parent) { for (var key in parent) { if (hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; },
......
/* eslint-disable func-names, space-before-function-paren, max-len, one-var, no-var, no-restricted-syntax, vars-on-top, no-use-before-define, no-param-reassign, new-cap, no-underscore-dangle, wrap-iife, prefer-rest-params, comma-dangle, padded-blocks */ /* eslint-disable func-names, space-before-function-paren, max-len, one-var, no-var, no-restricted-syntax, vars-on-top, no-use-before-define, no-param-reassign, new-cap, no-underscore-dangle, wrap-iife, prefer-rest-params, comma-dangle, padded-blocks */
/* global Api */ /* global Api */
/*= require blob/template_selector */ require('./template_selector');
(function() { (function() {
var extend = function(child, parent) { for (var key in parent) { if (hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; }, var extend = function(child, parent) { for (var key in parent) { if (hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; },
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
/* global EditBlob */ /* global EditBlob */
/* global NewCommitForm */ /* global NewCommitForm */
/*= require_tree . */ require('./edit_blob');
(function() { (function() {
$(function() { $(function() {
......
/* eslint-disable one-var, indent, quote-props, comma-dangle, space-before-function-paren */ /* eslint-disable one-var, indent, quote-props, comma-dangle, space-before-function-paren, import/newline-after-import, no-multi-spaces, max-len */
/* global Vue */ /* global Vue */
/* global BoardService */ /* global BoardService */
//= require vue function requireAll(context) { return context.keys().map(context); }
//= require vue-resource
//= require Sortable window.Vue = require('vue');
//= require_tree ./models window.Vue.use(require('vue-resource'));
//= require_tree ./stores window.Sortable = require('vendor/Sortable');
//= require_tree ./services requireAll(require.context('./models', true, /^\.\/.*\.(js|es6)$/));
//= require_tree ./mixins requireAll(require.context('./stores', true, /^\.\/.*\.(js|es6)$/));
//= require_tree ./filters requireAll(require.context('./services', true, /^\.\/.*\.(js|es6)$/));
//= require ./components/board requireAll(require.context('./mixins', true, /^\.\/.*\.(js|es6)$/));
//= require ./components/board_sidebar requireAll(require.context('./filters', true, /^\.\/.*\.(js|es6)$/));
//= require ./components/new_list_dropdown require('./components/board');
//= require ./vue_resource_interceptor require('./components/board_sidebar');
require('./components/new_list_dropdown');
require('./vue_resource_interceptor');
$(() => { $(() => {
const $boardApp = document.getElementById('board-app'), const $boardApp = document.getElementById('board-app'),
......
...@@ -2,9 +2,9 @@ ...@@ -2,9 +2,9 @@
/* global Vue */ /* global Vue */
/* global Sortable */ /* global Sortable */
//= require ./board_blank_state require('./board_blank_state');
//= require ./board_delete require('./board_delete');
//= require ./board_list require('./board_list');
(() => { (() => {
const Store = gl.issueBoards.BoardsStore; const Store = gl.issueBoards.BoardsStore;
......
...@@ -2,8 +2,8 @@ ...@@ -2,8 +2,8 @@
/* global Vue */ /* global Vue */
/* global Sortable */ /* global Sortable */
//= require ./board_card require('./board_card');
//= require ./board_new_issue require('./board_new_issue');
(() => { (() => {
const Store = gl.issueBoards.BoardsStore; const Store = gl.issueBoards.BoardsStore;
......
/* eslint-disable func-names, space-before-function-paren, one-var, no-var, one-var-declaration-per-line, prefer-template, quotes, no-unused-vars, prefer-arrow-callback, padded-blocks, max-len */ /* eslint-disable func-names, space-before-function-paren, one-var, no-var, one-var-declaration-per-line, prefer-template, quotes, no-unused-vars, prefer-arrow-callback, padded-blocks, max-len */
/* global Clipboard */ /* global Clipboard */
/*= require clipboard */ window.Clipboard = require('vendor/clipboard');
(function() { (function() {
var genericError, genericSuccess, showTooltip; var genericError, genericSuccess, showTooltip;
......
...@@ -2,9 +2,12 @@ ...@@ -2,9 +2,12 @@
/* global Cookies */ /* global Cookies */
/* global Flash */ /* global Flash */
//= require vue window.Vue = require('vue');
//= require_tree ./svg window.Cookies = require('vendor/js.cookie');
//= require_tree .
function requireAll(context) { return context.keys().map(context); }
requireAll(require.context('./svg', false, /^\.\/.*\.(js|es6)$/));
requireAll(require.context('.', false, /^\.\/(?!cycle_analytics_bundle).*\.(js|es6)$/));
$(() => { $(() => {
const OVERVIEW_DIALOG_COOKIE = 'cycle_analytics_help_dismissed'; const OVERVIEW_DIALOG_COOKIE = 'cycle_analytics_help_dismissed';
......
/* eslint-disable func-names, comma-dangle, new-cap, no-new */ /* eslint-disable func-names, comma-dangle, new-cap, no-new, import/newline-after-import, no-multi-spaces, max-len */
/* global Vue */ /* global Vue */
/* global ResolveCount */ /* global ResolveCount */
//= require vue function requireAll(context) { return context.keys().map(context); }
//= require vue-resource
//= require_directory ./models window.Vue = require('vue');
//= require_directory ./stores window.Vue.use(require('vue-resource'));
//= require_directory ./services requireAll(require.context('./models', false, /^\.\/.*\.(js|es6)$/));
//= require_directory ./mixins requireAll(require.context('./stores', false, /^\.\/.*\.(js|es6)$/));
//= require_directory ./components requireAll(require.context('./services', false, /^\.\/.*\.(js|es6)$/));
requireAll(require.context('./mixins', false, /^\.\/.*\.(js|es6)$/));
requireAll(require.context('./components', false, /^\.\/.*\.(js|es6)$/));
$(() => { $(() => {
const COMPONENT_SELECTOR = 'resolve-btn, resolve-discussion-btn, jump-to-discussion, comment-and-resolve-btn'; const COMPONENT_SELECTOR = 'resolve-btn, resolve-discussion-btn, jump-to-discussion, comment-and-resolve-btn';
......
/* eslint-disable func-names, space-before-function-paren, wrap-iife, max-len, one-var, no-var, one-var-declaration-per-line, no-unused-vars, camelcase, quotes, no-useless-concat, prefer-template, quote-props, comma-dangle, object-shorthand, consistent-return, no-plusplus, prefer-arrow-callback, padded-blocks */ /* eslint-disable func-names, space-before-function-paren, wrap-iife, max-len, one-var, no-var, one-var-declaration-per-line, no-unused-vars, camelcase, quotes, no-useless-concat, prefer-template, quote-props, comma-dangle, object-shorthand, consistent-return, no-plusplus, prefer-arrow-callback, padded-blocks */
/* global Dropzone */ /* global Dropzone */
/*= require preview_markdown */ require('./preview_markdown');
(function() { (function() {
this.DropzoneInput = (function() { this.DropzoneInput = (function() {
......
...@@ -2,10 +2,10 @@ ...@@ -2,10 +2,10 @@
/* global Vue */ /* global Vue */
/* global EnvironmentsService */ /* global EnvironmentsService */
//= require vue window.Vue = require('vue');
//= require vue-resource window.Vue.use(require('vue-resource'));
//= require_tree ../services/ require('../services/environments_service');
//= require ./environment_item require('./environment_item');
(() => { (() => {
window.gl = window.gl || {}; window.gl = window.gl || {};
......
/*= require vue */
/* global Vue */ /* global Vue */
window.Vue = require('vue');
(() => { (() => {
window.gl = window.gl || {}; window.gl = window.gl || {};
window.gl.environmentsList = window.gl.environmentsList || {}; window.gl.environmentsList = window.gl.environmentsList || {};
......
/*= require vue */
/* global Vue */ /* global Vue */
window.Vue = require('vue');
(() => { (() => {
window.gl = window.gl || {}; window.gl = window.gl || {};
window.gl.environmentsList = window.gl.environmentsList || {}; window.gl.environmentsList = window.gl.environmentsList || {};
......
/* global Vue */ /* global Vue */
/* global timeago */ /* global timeago */
/*= require timeago */ window.Vue = require('vue');
/*= require lib/utils/text_utility */ window.timeago = require('vendor/timeago');
/*= require vue_common_component/commit */ require('../../lib/utils/text_utility');
/*= require ./environment_actions */ require('../../vue_common_component/commit');
/*= require ./environment_external_url */ require('./environment_actions');
/*= require ./environment_stop */ require('./environment_external_url');
/*= require ./environment_rollback */ require('./environment_stop');
/*= require ./environment_terminal_button */ require('./environment_rollback');
require('./environment_terminal_button');
(() => { (() => {
/** /**
......
/*= require vue */
/* global Vue */ /* global Vue */
window.Vue = require('vue');
(() => { (() => {
window.gl = window.gl || {}; window.gl = window.gl || {};
window.gl.environmentsList = window.gl.environmentsList || {}; window.gl.environmentsList = window.gl.environmentsList || {};
......
/*= require vue */
/* global Vue */ /* global Vue */
window.Vue = require('vue');
(() => { (() => {
window.gl = window.gl || {}; window.gl = window.gl || {};
window.gl.environmentsList = window.gl.environmentsList || {}; window.gl.environmentsList = window.gl.environmentsList || {};
......
/*= require vue */
/* global Vue */ /* global Vue */
window.Vue = require('vue');
(() => { (() => {
window.gl = window.gl || {}; window.gl = window.gl || {};
window.gl.environmentsList = window.gl.environmentsList || {}; window.gl.environmentsList = window.gl.environmentsList || {};
......
//= require vue window.Vue = require('vue');
//= require_tree ./stores/
//= require ./components/environment
//= require ./vue_resource_interceptor
require('./stores/environments_store');
require('./components/environment');
require('./vue_resource_interceptor');
$(() => { $(() => {
window.gl = window.gl || {}; window.gl = window.gl || {};
......
/* globals Vue */ /* globals Vue */
/* eslint-disable no-unused-vars, no-param-reassign */ /* eslint-disable no-unused-vars, no-param-reassign */
class EnvironmentsService { class EnvironmentsService {
constructor(root) { constructor(root) {
......
/* eslint-disable comma-dangle, class-methods-use-this, max-len, space-before-function-paren, arrow-parens, no-param-reassign, padded-blocks */ /* eslint-disable comma-dangle, class-methods-use-this, max-len, space-before-function-paren, arrow-parens, no-param-reassign, padded-blocks */
//= require gl_field_error require('./gl_field_error');
((global) => { ((global) => {
const customValidationFlag = 'gl-field-error-ignore'; const customValidationFlag = 'gl-field-error-ignore';
......
...@@ -3,6 +3,8 @@ ...@@ -3,6 +3,8 @@
/* global DropzoneInput */ /* global DropzoneInput */
/* global autosize */ /* global autosize */
var autosize = require('vendor/autosize');
(function() { (function() {
this.GLForm = (function() { this.GLForm = (function() {
function GLForm(form) { function GLForm(form) {
......
/* eslint-disable func-names, space-before-function-paren */ // require everything else in this directory
// This is a manifest file that'll be compiled into including all the files listed below. function requireAll(context) { return context.keys().map(context); }
// Add new JavaScript code in separate files in this directory and they'll automatically requireAll(require.context('.', false, /^\.\/(?!graphs_bundle).*\.(js|es6)$/));
// be included in the compiled file accessible from http://example.com/assets/application.js
// It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the
// the compiled file.
//
/*= require_tree . */
(function() {
}).call(this);
...@@ -5,7 +5,7 @@ ...@@ -5,7 +5,7 @@
/* global ContributorsStatGraphUtil */ /* global ContributorsStatGraphUtil */
/* global d3 */ /* global d3 */
/*= require d3 */ window.d3 = require('d3');
(function() { (function() {
this.ContributorsStatGraph = (function() { this.ContributorsStatGraph = (function() {
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
/* global d3 */ /* global d3 */
/* global ContributorsGraph */ /* global ContributorsGraph */
/*= require d3 */ window.d3 = require('d3');
(function() { (function() {
var bind = function(fn, me){ return function(){ return fn.apply(me, arguments); }; }, var bind = function(fn, me){ return function(){ return fn.apply(me, arguments); }; },
......
/* eslint-disable wrap-iife, func-names, space-before-function-paren, padded-blocks, prefer-arrow-callback, no-var, max-len */ /* eslint-disable wrap-iife, func-names, space-before-function-paren, padded-blocks, prefer-arrow-callback, no-var, max-len */
(function() { (function() {
$(document).on('todo:toggle', function(e, count) { $(document).on('todo:toggle', function(e, count) {
var $todoPendingCount = $('.todos-pending-count'); var $todoPendingCount = $('.todos-pending-count');
$todoPendingCount.text(gl.text.addDelimiter(count)); $todoPendingCount.text(gl.text.addDelimiter(count));
......
/* eslint-disable func-names, space-before-function-paren, no-var, space-before-blocks, prefer-rest-params, wrap-iife, one-var, no-underscore-dangle, one-var-declaration-per-line, object-shorthand, no-unused-vars, no-new, comma-dangle, consistent-return, quotes, dot-notation, quote-props, prefer-arrow-callback, padded-blocks, max-len */ /* eslint-disable func-names, space-before-function-paren, no-var, space-before-blocks, prefer-rest-params, wrap-iife, one-var, no-underscore-dangle, one-var-declaration-per-line, object-shorthand, no-unused-vars, no-new, comma-dangle, consistent-return, quotes, dot-notation, quote-props, prefer-arrow-callback, padded-blocks, max-len */
/* global Flash */ /* global Flash */
/*= require flash */ require('./flash');
/*= require jquery.waitforimages */ require('vendor/jquery.waitforimages');
/*= require task_list */ require('vendor/task_list');
(function() { (function() {
var bind = function(fn, me){ return function(){ return fn.apply(me, arguments); }; }; var bind = function(fn, me){ return function(){ return fn.apply(me, arguments); }; };
......
/* eslint-disable func-names, space-before-function-paren */ /* eslint-disable func-names, space-before-function-paren */
/*= require Chart */ window.Chart = require('vendor/Chart');
(function() {
}).call(this);
/* eslint-disable func-names, space-before-function-paren */ /* eslint-disable func-names, space-before-function-paren */
/*= require d3 */ window.d3 = require('d3');
(function() {
}).call(this);
...@@ -2,8 +2,8 @@ ...@@ -2,8 +2,8 @@
/* global timeago */ /* global timeago */
/* global dateFormat */ /* global dateFormat */
/*= require timeago */ window.timeago = require('vendor/timeago');
/*= require date.format */ require('vendor/date.format');
(function() { (function() {
(function(w) { (function(w) {
......
(function() {
gl.emojiAliases = function() {
return JSON.parse('<%= Gitlab::AwardEmoji.aliases.to_json %>');
};
}).call(this);
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
// //
// Handles single- and multi-line selection and highlight for blob views. // Handles single- and multi-line selection and highlight for blob views.
// //
/*= require jquery.scrollTo */ require('vendor/jquery.scrollTo');
// //
// ### Example Markup // ### Example Markup
......
...@@ -2,14 +2,14 @@ ...@@ -2,14 +2,14 @@
/* global Vue */ /* global Vue */
/* global Flash */ /* global Flash */
//= require vue window.Vue = require('vue');
//= require ./merge_conflict_store require('./merge_conflict_store');
//= require ./merge_conflict_service require('./merge_conflict_service');
//= require ./mixins/line_conflict_utils require('./mixins/line_conflict_utils');
//= require ./mixins/line_conflict_actions require('./mixins/line_conflict_actions');
//= require ./components/diff_file_editor require('./components/diff_file_editor');
//= require ./components/inline_conflict_lines require('./components/inline_conflict_lines');
//= require ./components/parallel_conflict_lines require('./components/parallel_conflict_lines');
$(() => { $(() => {
const INTERACTIVE_RESOLVE_MODE = 'interactive'; const INTERACTIVE_RESOLVE_MODE = 'interactive';
......
/* eslint-disable func-names, space-before-function-paren, no-var, space-before-blocks, prefer-rest-params, wrap-iife, quotes, no-underscore-dangle, one-var, one-var-declaration-per-line, consistent-return, dot-notation, quote-props, comma-dangle, object-shorthand, padded-blocks, max-len, prefer-arrow-callback */ /* eslint-disable func-names, space-before-function-paren, no-var, space-before-blocks, prefer-rest-params, wrap-iife, quotes, no-underscore-dangle, one-var, one-var-declaration-per-line, consistent-return, dot-notation, quote-props, comma-dangle, object-shorthand, padded-blocks, max-len, prefer-arrow-callback */
/* global MergeRequestTabs */ /* global MergeRequestTabs */
/*= require jquery.waitforimages */ require('vendor/jquery.waitforimages');
/*= require task_list */ require('vendor/task_list');
/*= require merge_request_tabs */ require('./merge_request_tabs');
(function() { (function() {
var bind = function(fn, me){ return function(){ return fn.apply(me, arguments); }; }; var bind = function(fn, me){ return function(){ return fn.apply(me, arguments); }; };
......
/* eslint-disable no-new, class-methods-use-this */ /* eslint-disable no-new, class-methods-use-this */
/* global Breakpoints */ /* global Breakpoints */
/* global Cookies */ /* global Cookies */
/* global DiffNotesApp */
/* global Flash */ /* global Flash */
/*= require js.cookie */ require('./breakpoints');
/*= require breakpoints */ window.Cookies = require('vendor/js.cookie');
require('./flash');
/* eslint-disable max-len */ /* eslint-disable max-len */
// MergeRequestTabs // MergeRequestTabs
......
...@@ -2,13 +2,9 @@ ...@@ -2,13 +2,9 @@
/* global Network */ /* global Network */
/* global ShortcutsNetwork */ /* global ShortcutsNetwork */
// This is a manifest file that'll be compiled into including all the files listed below. // require everything else in this directory
// Add new JavaScript code in separate files in this directory and they'll automatically function requireAll(context) { return context.keys().map(context); }
// be included in the compiled file accessible from http://example.com/assets/application.js requireAll(require.context('.', false, /^\.\/(?!network_bundle).*\.(js|es6)$/));
// It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the
// the compiled file.
//
/*= require_tree . */
(function() { (function() {
$(function() { $(function() {
......
...@@ -4,13 +4,14 @@ ...@@ -4,13 +4,14 @@
/* global Autosave */ /* global Autosave */
/* global ResolveService */ /* global ResolveService */
/*= require autosave */ require('./autosave');
/*= require autosize */ window.autosize = require('vendor/autosize');
/*= require dropzone */ window.Dropzone = require('dropzone');
/*= require dropzone_input */ require('./dropzone_input');
/*= require gfm_auto_complete */ require('./gfm_auto_complete');
/*= require jquery.atwho */ require('vendor/jquery.caret'); // required by jquery.atwho
/*= require task_list */ require('vendor/jquery.atwho');
require('vendor/task_list');
(function() { (function() {
var bind = function(fn, me){ return function(){ return fn.apply(me, arguments); }; }; var bind = function(fn, me){ return function(){ return fn.apply(me, arguments); }; };
......
/* eslint-disable no-new, guard-for-in, no-restricted-syntax, no-continue, padded-blocks, no-param-reassign, max-len */ /* eslint-disable no-new, guard-for-in, no-restricted-syntax, no-continue, padded-blocks, no-param-reassign, max-len */
//= require lib/utils/bootstrap_linked_tabs require('./lib/utils/bootstrap_linked_tabs');
((global) => { ((global) => {
......
/* eslint-disable func-names, space-before-function-paren */ // require everything else in this directory
function requireAll(context) { return context.keys().map(context); }
/*= require_tree . */ requireAll(require.context('.', false, /^\.\/(?!profile_bundle).*\.(js|es6)$/));
(function() {
}).call(this);
/*= require_tree . */ // require everything else in this directory
function requireAll(context) { return context.keys().map(context); }
requireAll(require.context('.', false, /^\.\/(?!protected_branches_bundle).*\.(js|es6)$/));
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
/* global Shortcuts */ /* global Shortcuts */
/* global Mousetrap */ /* global Mousetrap */
/*= require shortcuts */ require('./shortcuts');
(function() { (function() {
var extend = function(child, parent) { for (var key in parent) { if (hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; }, var extend = function(child, parent) { for (var key in parent) { if (hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; },
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
/* global Mousetrap */ /* global Mousetrap */
/* global Shortcuts */ /* global Shortcuts */
/*= require shortcuts */ require('./shortcuts');
(function() { (function() {
var extend = function(child, parent) { for (var key in parent) { if (hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; }, var extend = function(child, parent) { for (var key in parent) { if (hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; },
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
/* global Mousetrap */ /* global Mousetrap */
/* global ShortcutsNavigation */ /* global ShortcutsNavigation */
/*= require shortcuts_navigation */ require('./shortcuts_navigation');
(function() { (function() {
var extend = function(child, parent) { for (var key in parent) { if (hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; }, var extend = function(child, parent) { for (var key in parent) { if (hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; },
......
...@@ -4,8 +4,8 @@ ...@@ -4,8 +4,8 @@
/* global ShortcutsNavigation */ /* global ShortcutsNavigation */
/* global sidebar */ /* global sidebar */
/*= require mousetrap */ require('mousetrap');
/*= require shortcuts_navigation */ require('./shortcuts_navigation');
(function() { (function() {
var extend = function(child, parent) { for (var key in parent) { if (hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; }, var extend = function(child, parent) { for (var key in parent) { if (hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; },
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
/* global Mousetrap */ /* global Mousetrap */
/* global Shortcuts */ /* global Shortcuts */
/*= require shortcuts */ require('./shortcuts');
(function() { (function() {
var extend = function(child, parent) { for (var key in parent) { if (hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; }, var extend = function(child, parent) { for (var key in parent) { if (hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; },
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
/* global Mousetrap */ /* global Mousetrap */
/* global ShortcutsNavigation */ /* global ShortcutsNavigation */
/*= require shortcuts_navigation */ require('./shortcuts_navigation');
(function() { (function() {
var extend = function(child, parent) { for (var key in parent) { if (hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; }, var extend = function(child, parent) { for (var key in parent) { if (hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; },
......
/* eslint-disable func-names, space-before-function-paren, prefer-arrow-callback, no-var, quotes, semi, padded-blocks, max-len */ /* eslint-disable func-names, space-before-function-paren, prefer-arrow-callback, no-var, quotes, semi, padded-blocks, max-len */
/* global ace */ /* global ace */
/*= require_tree . */ // require everything else in this directory
function requireAll(context) { return context.keys().map(context); }
requireAll(require.context('.', false, /^\.\/(?!snippet_bundle).*\.(js|es6)$/));
(function() { (function() {
$(function() { $(function() {
......
//= require vue
//= require vue-resource
(() => { (() => {
/* /*
* SubbableResource can be extended to provide a pubsub-style service for one-off REST * SubbableResource can be extended to provide a pubsub-style service for one-off REST
......
/* eslint-disable prefer-const, comma-dangle, max-len, no-useless-return, object-curly-spacing, no-param-reassign, max-len */ /* eslint-disable prefer-const, comma-dangle, max-len, no-useless-return, object-curly-spacing, no-param-reassign, max-len */
/* global Api */ /* global Api */
/*= require ../blob/template_selector */ require('../blob/template_selector');
((global) => { ((global) => {
class IssuableTemplateSelector extends gl.TemplateSelector { class IssuableTemplateSelector extends gl.TemplateSelector {
......
//= require xterm/encoding-indexes require('vendor/xterm/encoding-indexes.js');
//= require xterm/encoding require('vendor/xterm/encoding.js');
//= require xterm/xterm.js window.Terminal = require('vendor/xterm/xterm.js');
//= require xterm/fit.js require('vendor/xterm/fit.js');
//= require ./terminal.js require('./terminal.js');
$(() => new gl.Terminal({ selector: '#terminal' })); $(() => new gl.Terminal({ selector: '#terminal' }));
/* eslint-disable func-names, space-before-function-paren */ // require everything else in this directory
function requireAll(context) { return context.keys().map(context); }
/*= require_tree . */ requireAll(require.context('.', false, /^\.\/(?!users_bundle).*\.(js|es6)$/));
(function() {
}).call(this);
/*= require vue */
/* global Vue */ /* global Vue */
window.Vue = require('vue');
(() => { (() => {
window.gl = window.gl || {}; window.gl = window.gl || {};
......
/* eslint-disable */
/**
* Simulate sprockets compile order of application.js through CommonJS require statements
*
* Currently exports everything appropriate to window until the scripts that rely on this behavior
* can be refactored.
*
* Test the output from this against sprockets output and it should be almost identical apart from
* webpack's CommonJS wrapper. You can add the following line to webpack.config.js to fix the
* script indentation:
* config.output.sourcePrefix = '';
*/
/*= require jquery2 */
window.jQuery = window.$ = require('jquery');
/*= require jquery-ui/autocomplete */
// depends on jquery-ui/core, jquery-ui/widget, jquery-ui/menu, jquery-ui/position
require('jquery-ui/ui/core');
require('jquery-ui/ui/widget');
require('jquery-ui/ui/position');
require('jquery-ui/ui/menu');
require('jquery-ui/ui/autocomplete');
/*= require jquery-ui/datepicker */
// depends on jquery-ui/core
require('jquery-ui/ui/datepicker');
/*= require jquery-ui/draggable */
// depends on jquery-ui/core, jquery-ui/widget, jquery-ui/mouse
require('jquery-ui/ui/mouse');
require('jquery-ui/ui/draggable');
/*= require jquery-ui/effect-highlight */
// depends on jquery-ui/effect
require('jquery-ui/ui/effect');
require('jquery-ui/ui/effect-highlight');
/*= require jquery-ui/sortable */
// depends on jquery-ui/core, jquery-ui/widget, jquery-ui/mouse
require('jquery-ui/ui/sortable');
/*= require jquery_ujs */
require('jquery-ujs');
/*= require jquery.endless-scroll */
require('vendor/jquery.endless-scroll');
/*= require jquery.highlight */
require('vendor/jquery.highlight');
/*= require jquery.waitforimages */
require('vendor/jquery.waitforimages');
/*= require jquery.atwho */
require('vendor/jquery.caret'); // required by jquery.atwho
require('vendor/jquery.atwho');
/*= require jquery.scrollTo */
require('vendor/jquery.scrollTo');
/*= require jquery.turbolinks */
require('vendor/jquery.turbolinks');
/*= require js.cookie */
window.Cookies = require('vendor/js.cookie');
/*= require turbolinks */
require('vendor/turbolinks');
/*= require autosave */
require('../autosave');
/*= require bootstrap/affix */
require('bootstrap/js/affix');
/*= require bootstrap/alert */
require('bootstrap/js/alert');
/*= require bootstrap/button */
require('bootstrap/js/button');
/*= require bootstrap/collapse */
require('bootstrap/js/collapse');
/*= require bootstrap/dropdown */
require('bootstrap/js/dropdown');
/*= require bootstrap/modal */
require('bootstrap/js/modal');
/*= require bootstrap/scrollspy */
require('bootstrap/js/scrollspy');
/*= require bootstrap/tab */
require('bootstrap/js/tab');
/*= require bootstrap/transition */
require('bootstrap/js/transition');
/*= require bootstrap/tooltip */
require('bootstrap/js/tooltip');
/*= require bootstrap/popover */
require('bootstrap/js/popover');
/*= require select2 */
require('select2/select2.js');
/*= require underscore */
window._ = require('underscore');
/*= require dropzone */
window.Dropzone = require('dropzone');
/*= require mousetrap */
require('mousetrap');
/*= require mousetrap/pause */
require('mousetrap/plugins/pause/mousetrap-pause');
/*= require shortcuts */
require('../shortcuts');
/*= require shortcuts_navigation */
require('../shortcuts_navigation');
/*= require shortcuts_dashboard_navigation */
require('../shortcuts_dashboard_navigation');
/*= require shortcuts_issuable */
require('../shortcuts_issuable');
/*= require shortcuts_network */
require('../shortcuts_network');
/*= require jquery.nicescroll */
require('vendor/jquery.nicescroll');
/*= require date.format */
require('vendor/date.format');
/*= require_directory ./behaviors */
require('vendor/jquery.ba-resize');
window.autosize = require('vendor/autosize');
require('../behaviors/autosize'); // requires vendor/jquery.ba-resize and vendor/autosize
require('../behaviors/details_behavior');
require('../extensions/jquery');
require('../behaviors/quick_submit'); // requires extensions/jquery
require('../behaviors/requires_input');
require('../behaviors/toggler_behavior');
/*= require_directory ./blob */
require('../blob/template_selector');
require('../blob/blob_ci_yaml'); // requires template_selector
require('../blob/blob_file_dropzone');
require('../blob/blob_gitignore_selector');
require('../blob/blob_gitignore_selectors');
require('../blob/blob_license_selector');
require('../blob/blob_license_selectors');
/*= require_directory ./templates */
require('../templates/issuable_template_selector');
require('../templates/issuable_template_selectors');
/*= require_directory ./commit */
require('../commit/file');
require('../commit/image_file');
/*= require_directory ./extensions */
require('../extensions/array');
require('../extensions/element');
/*= require_directory ./lib/utils */
require('../lib/utils/animate');
require('../lib/utils/common_utils');
require('../lib/utils/datetime_utility');
// require('../lib/utils/emoji_aliases.js.erb');
window.gl.emojiAliases = function() { return require('emoji-aliases'); };
require('../lib/utils/jquery.timeago');
require('../lib/utils/notify');
require('../lib/utils/text_utility');
require('../lib/utils/type_utility');
require('../lib/utils/url_utility');
/*= require_directory ./u2f */
require('../u2f/authenticate');
require('../u2f/error');
require('../u2f/register');
require('../u2f/util');
/*= require_directory . */
require('../abuse_reports');
require('../activities');
require('../admin');
require('../api');
require('../aside');
require('../awards_handler');
require('../breakpoints');
require('../broadcast_message');
require('../build');
require('../build_artifacts');
require('../build_variables');
require('../commit');
require('../commits');
require('../compare');
require('../compare_autocomplete');
require('../confirm_danger_modal');
window.Clipboard = require('vendor/clipboard'); // required by copy_to_clipboard
require('../copy_to_clipboard');
require('../create_label');
require('vue'); // required by cycle_analytics
require('../cycle_analytics');
require('../diff');
require('../dispatcher');
require('../preview_markdown');
require('../dropzone_input');
require('../due_date_select');
require('../files_comment_button');
require('../flash');
require('../gfm_auto_complete');
require('../gl_dropdown');
require('../gl_field_errors');
require('../gl_form');
require('../group_avatar');
require('../groups_select');
require('../header');
require('../importer_status');
require('../issuable');
require('../issuable_context');
require('../issuable_form');
require('vendor/task_list'); // required by issue
require('../issue');
require('../issue_status_select');
require('../issues_bulk_assignment');
require('../label_manager');
require('../labels');
require('../labels_select');
require('../layout_nav');
require('../line_highlighter');
require('../logo');
require('../member_expiration_date');
require('../members');
require('../merge_request_tabs');
require('../merge_request');
require('../merge_request_widget');
require('../merged_buttons');
require('../milestone');
require('../milestone_select');
require('../namespace_select');
require('../new_branch_form');
require('../new_commit_form');
require('../notes');
require('../notifications_dropdown');
require('../notifications_form');
require('../pager');
require('../pipelines');
require('../project');
require('../project_avatar');
require('../project_find_file');
require('../project_fork');
require('../project_import');
require('../project_new');
require('../project_select');
require('../project_show');
require('../projects_list');
require('../right_sidebar');
require('../search');
require('../search_autocomplete');
require('../shortcuts_blob');
require('../shortcuts_find_file');
require('../sidebar');
require('../single_file_diff');
require('../snippets_list');
require('../star');
require('../subscription');
require('../subscription_select');
require('../syntax_highlight');
require('../todos');
require('../tree');
require('../user');
require('../user_tabs');
require('../username_validator');
require('../users_select');
require('vendor/latinise'); // required by wikis
require('../wikis');
require('../zen_mode');
/*= require fuzzaldrin-plus */
require('vendor/fuzzaldrin-plus');
require('../application');
/* eslint-disable no-param-reassign */ /* eslint-disable no-param-reassign */
/* global Breakpoints */ /* global Breakpoints */
/*= require latinise */ require('vendor/latinise');
/*= require breakpoints */ require('./breakpoints');
/*= require jquery.nicescroll */ require('vendor/jquery.nicescroll');
((global) => { ((global) => {
const dasherize = str => str.replace(/[_\s]+/g, '-'); const dasherize = str => str.replace(/[_\s]+/g, '-');
......
...@@ -6,11 +6,11 @@ ...@@ -6,11 +6,11 @@
// //
/*= provides zen_mode:enter */ /*= provides zen_mode:enter */
/*= provides zen_mode:leave */ /*= provides zen_mode:leave */
//
/*= require jquery.scrollTo */ require('vendor/jquery.scrollTo');
/*= require dropzone */ window.Dropzone = require('dropzone');
/*= require mousetrap */ require('mousetrap');
/*= require mousetrap/pause */ require('mousetrap/plugins/pause/mousetrap-pause');
// //
// ### Events // ### Events
......
...@@ -2,4 +2,7 @@ module JavascriptHelper ...@@ -2,4 +2,7 @@ module JavascriptHelper
def page_specific_javascript_tag(js) def page_specific_javascript_tag(js)
javascript_include_tag asset_path(js), { "data-turbolinks-track" => true } javascript_include_tag asset_path(js), { "data-turbolinks-track" => true }
end end
def page_specific_javascript_bundle_tag(js)
javascript_include_tag *webpack_asset_paths(js), { "data-turbolinks-track" => true }
end
end end
- content_for :page_specific_javascripts do - content_for :page_specific_javascripts do
= page_specific_javascript_tag('lib/cropper.js') = page_specific_javascript_tag('lib/cropper.js')
= page_specific_javascript_tag('profile/profile_bundle.js') = page_specific_javascript_bundle_tag('profile')
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
- page_title "Edit", @blob.path, @ref - page_title "Edit", @blob.path, @ref
- content_for :page_specific_javascripts do - content_for :page_specific_javascripts do
= page_specific_javascript_tag('lib/ace.js') = page_specific_javascript_tag('lib/ace.js')
= page_specific_javascript_tag('blob_edit/blob_edit_bundle.js') = page_specific_javascript_bundle_tag('blob_edit')
= render "projects/commits/head" = render "projects/commits/head"
%div{ class: container_class } %div{ class: container_class }
......
- page_title "New File", @path.presence, @ref - page_title "New File", @path.presence, @ref
- content_for :page_specific_javascripts do - content_for :page_specific_javascripts do
= page_specific_javascript_tag('lib/ace.js') = page_specific_javascript_tag('lib/ace.js')
= page_specific_javascript_tag('blob_edit/blob_edit_bundle.js') = page_specific_javascript_bundle_tag('blob_edit')
%h3.page-title %h3.page-title
New File New File
......
...@@ -3,8 +3,8 @@ ...@@ -3,8 +3,8 @@
- page_title "Boards" - page_title "Boards"
- content_for :page_specific_javascripts do - content_for :page_specific_javascripts do
= page_specific_javascript_tag('boards/boards_bundle.js') = page_specific_javascript_bundle_tag('boards')
= page_specific_javascript_tag('boards/test_utils/simulate_drag.js') if Rails.env.test? = page_specific_javascript_bundle_tag('boards_test') if Rails.env.test?
%script#js-board-template{ type: "text/x-template" }= render "projects/boards/components/board" %script#js-board-template{ type: "text/x-template" }= render "projects/boards/components/board"
%script#js-board-list-template{ type: "text/x-template" }= render "projects/boards/components/board_list" %script#js-board-list-template{ type: "text/x-template" }= render "projects/boards/components/board_list"
......
- @no_container = true - @no_container = true
- page_title "Cycle Analytics" - page_title "Cycle Analytics"
- content_for :page_specific_javascripts do - content_for :page_specific_javascripts do
= page_specific_javascript_tag("cycle_analytics/cycle_analytics_bundle.js") = page_specific_javascript_bundle_tag('cycle_analytics')
= render "projects/pipelines/head" = render "projects/pipelines/head"
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
= render "projects/pipelines/head" = render "projects/pipelines/head"
- content_for :page_specific_javascripts do - content_for :page_specific_javascripts do
= page_specific_javascript_tag("environments/environments_bundle.js") = page_specific_javascript_bundle_tag("environments")
#environments-list-view{ data: { environments_data: environments_list_data, #environments-list-view{ data: { environments_data: environments_list_data,
"can-create-deployment" => can?(current_user, :create_deployment, @project).to_s, "can-create-deployment" => can?(current_user, :create_deployment, @project).to_s,
......
...@@ -5,8 +5,8 @@ ...@@ -5,8 +5,8 @@
%ul{ class: (container_class) } %ul{ class: (container_class) }
- content_for :page_specific_javascripts do - content_for :page_specific_javascripts do
= page_specific_javascript_tag('lib/chart.js') = page_specific_javascript_bundle_tag('lib_chart')
= page_specific_javascript_tag('graphs/graphs_bundle.js') = page_specific_javascript_bundle_tag('graphs')
= nav_link(action: :show) do = nav_link(action: :show) do
= link_to 'Contributors', namespace_project_graph_path = link_to 'Contributors', namespace_project_graph_path
= nav_link(action: :commits) do = nav_link(action: :commits) do
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
- page_description @merge_request.description - page_description @merge_request.description
- page_card_attributes @merge_request.card_attributes - page_card_attributes @merge_request.card_attributes
- content_for :page_specific_javascripts do - content_for :page_specific_javascripts do
= page_specific_javascript_tag('diff_notes/diff_notes_bundle.js') = page_specific_javascript_bundle_tag('diff_notes')
.merge-request{ 'data-url' => merge_request_path(@merge_request) } .merge-request{ 'data-url' => merge_request_path(@merge_request) }
= render "projects/merge_requests/show/mr_title" = render "projects/merge_requests/show/mr_title"
......
- page_title "Merge Conflicts", "#{@merge_request.title} (#{@merge_request.to_reference}", "Merge Requests" - page_title "Merge Conflicts", "#{@merge_request.title} (#{@merge_request.to_reference}", "Merge Requests"
- content_for :page_specific_javascripts do - content_for :page_specific_javascripts do
= page_specific_javascript_tag('merge_conflicts/merge_conflicts_bundle.js') = page_specific_javascript_bundle_tag('merge_conflicts')
= page_specific_javascript_tag('lib/ace.js') = page_specific_javascript_tag('lib/ace.js')
= render "projects/merge_requests/show/mr_title" = render "projects/merge_requests/show/mr_title"
......
- content_for :page_specific_javascripts do - content_for :page_specific_javascripts do
= page_specific_javascript_tag('merge_request_widget/ci_bundle.js') = page_specific_javascript_bundle_tag('merge_request_widget')
- status_class = @pipeline ? " ci-#{@pipeline.status}" : nil - status_class = @pipeline ? " ci-#{@pipeline.status}" : nil
......
- content_for :page_specific_javascripts do - content_for :page_specific_javascripts do
= page_specific_javascript_tag('merge_request_widget/ci_bundle.js') = page_specific_javascript_bundle_tag('merge_request_widget')
%strong %strong
= icon("spinner spin") = icon("spinner spin")
......
- page_title "Network", @ref - page_title "Network", @ref
- content_for :page_specific_javascripts do - content_for :page_specific_javascripts do
= page_specific_javascript_tag('lib/raphael.js') = page_specific_javascript_tag('lib/raphael.js')
= page_specific_javascript_tag('network/network_bundle.js') = page_specific_javascript_bundle_tag('network')
= render "projects/commits/head" = render "projects/commits/head"
= render "head" = render "head"
%div{ class: container_class } %div{ class: container_class }
......
- page_title "Protected branches" - page_title "Protected branches"
- content_for :page_specific_javascripts do - content_for :page_specific_javascripts do
= page_specific_javascript_tag('protected_branches/protected_branches_bundle.js') = page_specific_javascript_bundle_tag('protected_branches')
.row.prepend-top-default.append-bottom-default .row.prepend-top-default.append-bottom-default
.col-lg-3 .col-lg-3
......
- content_for :page_specific_javascripts do - content_for :page_specific_javascripts do
= page_specific_javascript_tag('lib/ace.js') = page_specific_javascript_tag('lib/ace.js')
= page_specific_javascript_tag('snippet/snippet_bundle.js') = page_specific_javascript_bundle_tag('snippet')
.snippet-form-holder .snippet-form-holder
= form_for @snippet, url: url, html: { class: "form-horizontal snippet-form js-requires-input" } do |f| = form_for @snippet, url: url, html: { class: "form-horizontal snippet-form js-requires-input" } do |f|
...@@ -34,4 +34,3 @@ ...@@ -34,4 +34,3 @@
= link_to "Cancel", namespace_project_snippets_path(@project.namespace, @project), class: "btn btn-cancel" = link_to "Cancel", namespace_project_snippets_path(@project.namespace, @project), class: "btn btn-cancel"
- else - else
= link_to "Cancel", snippets_path(@project), class: "btn btn-cancel" = link_to "Cancel", snippets_path(@project), class: "btn btn-cancel"
- page_title @user.name - page_title @user.name
- page_description @user.bio - page_description @user.bio
- content_for :page_specific_javascripts do - content_for :page_specific_javascripts do
= page_specific_javascript_tag('lib/d3.js') = page_specific_javascript_bundle_tag('lib_d3')
= page_specific_javascript_tag('users/users_bundle.js') = page_specific_javascript_bundle_tag('users')
- header_title @user.name, user_path(@user) - header_title @user.name, user_path(@user)
- @no_container = true - @no_container = true
......
...@@ -96,23 +96,9 @@ module Gitlab ...@@ -96,23 +96,9 @@ module Gitlab
config.assets.precompile << "katex.css" config.assets.precompile << "katex.css"
config.assets.precompile << "katex.js" config.assets.precompile << "katex.js"
config.assets.precompile << "xterm/xterm.css" config.assets.precompile << "xterm/xterm.css"
config.assets.precompile << "graphs/graphs_bundle.js" config.assets.precompile << "lib/ace.js"
config.assets.precompile << "users/users_bundle.js" config.assets.precompile << "lib/cropper.js"
config.assets.precompile << "network/network_bundle.js" config.assets.precompile << "lib/raphael.js"
config.assets.precompile << "profile/profile_bundle.js"
config.assets.precompile << "protected_branches/protected_branches_bundle.js"
config.assets.precompile << "diff_notes/diff_notes_bundle.js"
config.assets.precompile << "merge_request_widget/ci_bundle.js"
config.assets.precompile << "boards/boards_bundle.js"
config.assets.precompile << "cycle_analytics/cycle_analytics_bundle.js"
config.assets.precompile << "merge_conflicts/merge_conflicts_bundle.js"
config.assets.precompile << "boards/test_utils/simulate_drag.js"
config.assets.precompile << "environments/environments_bundle.js"
config.assets.precompile << "blob_edit/blob_edit_bundle.js"
config.assets.precompile << "snippet/snippet_bundle.js"
config.assets.precompile << "terminal/terminal_bundle.js"
config.assets.precompile << "lib/utils/*.js"
config.assets.precompile << "lib/*.js"
config.assets.precompile << "u2f.js" config.assets.precompile << "u2f.js"
config.assets.precompile << "vendor/assets/fonts/*" config.assets.precompile << "vendor/assets/fonts/*"
......
...@@ -12,9 +12,26 @@ var ROOT_PATH = path.resolve(__dirname, '..'); ...@@ -12,9 +12,26 @@ var ROOT_PATH = path.resolve(__dirname, '..');
var DEV_SERVER_PORT = 3808; var DEV_SERVER_PORT = 3808;
var config = { var config = {
context: ROOT_PATH, context: path.join(ROOT_PATH, 'app/assets/javascripts'),
entry: { entry: {
application: './app/assets/javascripts/webpack/application.js' application: './application.js',
blob_edit: './blob_edit/blob_edit_bundle.js',
boards: './boards/boards_bundle.js',
boards_test: './boards/test_utils/simulate_drag.js',
cycle_analytics: './cycle_analytics/cycle_analytics_bundle.js',
diff_notes: './diff_notes/diff_notes_bundle.js',
environments: './environments/environments_bundle.js',
graphs: './graphs/graphs_bundle.js',
merge_conflicts: './merge_conflicts/merge_conflicts_bundle.js',
merge_request_widget: './merge_request_widget/ci_bundle.js',
network: './network/network_bundle.js',
profile: './profile/profile_bundle.js',
protected_branches: './protected_branches/protected_branches_bundle.js',
snippet: './snippet/snippet_bundle.js',
terminal: './terminal/terminal_bundle.js',
users: './users/users_bundle.js',
lib_chart: './lib/chart.js',
lib_d3: './lib/d3.js'
}, },
output: { output: {
......
...@@ -1154,6 +1154,3 @@ Promise.Promise = Promise; ...@@ -1154,6 +1154,3 @@ Promise.Promise = Promise;
return Promise; return Promise;
}))); })));
ES6Promise.polyfill();
//# sourceMappingURL=es6-promise.auto.map
...@@ -16,12 +16,12 @@ ...@@ -16,12 +16,12 @@
/* /*
* CommonJS environment * CommonJS environment
*/ */
module.exports = fit(require('../../xterm')); module.exports = fit(require('./xterm'));
} else if (typeof define == 'function') { } else if (typeof define == 'function') {
/* /*
* Require.js is available * Require.js is available
*/ */
define(['../../xterm'], fit); define(['./xterm'], fit);
} else { } else {
/* /*
* Plain browser environment * Plain browser environment
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment