summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Greiling <mike@pixelcog.com>2017-03-02 01:27:52 -0600
committerMike Greiling <mike@pixelcog.com>2017-03-03 16:47:38 -0600
commit1f9743310054273b98e423b6dc5e99a5bc9fd7a2 (patch)
treec57f9865006cb66b07c80e674d89fa6ad5178ff4
parent5f464f98f1ff86caac02eca207704c1961b07be1 (diff)
downloadgitlab-ce-1f9743310054273b98e423b6dc5e99a5bc9fd7a2.tar.gz
merge lib_chart into graphs bundle
-rw-r--r--app/assets/javascripts/graphs/graphs_bundle.js2
-rw-r--r--app/assets/javascripts/lib/chart.js3
-rw-r--r--app/views/projects/graphs/charts.html.haml1
-rw-r--r--app/views/projects/graphs/show.html.haml1
-rw-r--r--app/views/projects/pipelines/charts.html.haml1
-rw-r--r--config/webpack.config.js1
6 files changed, 2 insertions, 7 deletions
diff --git a/app/assets/javascripts/graphs/graphs_bundle.js b/app/assets/javascripts/graphs/graphs_bundle.js
index ea5afbd9d29..a433c7ba8f0 100644
--- a/app/assets/javascripts/graphs/graphs_bundle.js
+++ b/app/assets/javascripts/graphs/graphs_bundle.js
@@ -1,4 +1,6 @@
+import Chart from 'vendor/Chart';
import ContributorsStatGraph from './stat_graph_contributors';
// export to global scope
+window.Chart = Chart;
window.ContributorsStatGraph = ContributorsStatGraph;
diff --git a/app/assets/javascripts/lib/chart.js b/app/assets/javascripts/lib/chart.js
deleted file mode 100644
index 9b011d89e93..00000000000
--- a/app/assets/javascripts/lib/chart.js
+++ /dev/null
@@ -1,3 +0,0 @@
-/* eslint-disable func-names, space-before-function-paren */
-
-window.Chart = require('vendor/Chart');
diff --git a/app/views/projects/graphs/charts.html.haml b/app/views/projects/graphs/charts.html.haml
index d3bce45e974..fa28db6c71f 100644
--- a/app/views/projects/graphs/charts.html.haml
+++ b/app/views/projects/graphs/charts.html.haml
@@ -1,7 +1,6 @@
- @no_container = true
- page_title "Charts"
- content_for :page_specific_javascripts do
- = page_specific_javascript_bundle_tag('lib_chart')
= page_specific_javascript_bundle_tag('graphs')
= render "projects/commits/head"
diff --git a/app/views/projects/graphs/show.html.haml b/app/views/projects/graphs/show.html.haml
index d89dfe31e47..05291c65b50 100644
--- a/app/views/projects/graphs/show.html.haml
+++ b/app/views/projects/graphs/show.html.haml
@@ -1,7 +1,6 @@
- @no_container = true
- page_title "Contributors"
- content_for :page_specific_javascripts do
- = page_specific_javascript_bundle_tag('lib_chart')
= page_specific_javascript_bundle_tag('graphs')
= render 'projects/commits/head'
diff --git a/app/views/projects/pipelines/charts.html.haml b/app/views/projects/pipelines/charts.html.haml
index 8ffdfa1a2cf..fbf783afe44 100644
--- a/app/views/projects/pipelines/charts.html.haml
+++ b/app/views/projects/pipelines/charts.html.haml
@@ -1,7 +1,6 @@
- @no_container = true
- page_title "Charts", "Pipelines"
- content_for :page_specific_javascripts do
- = page_specific_javascript_bundle_tag('lib_chart')
= page_specific_javascript_bundle_tag('graphs')
= render 'head'
diff --git a/config/webpack.config.js b/config/webpack.config.js
index 904ac36df4c..243007be4b7 100644
--- a/config/webpack.config.js
+++ b/config/webpack.config.js
@@ -40,7 +40,6 @@ var config = {
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',
vue_pipelines: './vue_pipelines_index/index.js',
},