diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-01-20 15:09:02 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-01-20 15:09:02 +0300 |
commit | 98252e0dd60cbcb316231085e206d9872f243b8a (patch) | |
tree | 304021f4190aabcc74f1359866c0efff84995729 /app/assets/javascripts | |
parent | 2ee5991b42717969af93cb30d863aafab04dff8a (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/assets/javascripts')
-rw-r--r-- | app/assets/javascripts/vue_merge_request_widget/components/deployment/deployment_info.vue | 4 | ||||
-rw-r--r-- | app/assets/javascripts/vue_shared/components/bar_chart.vue | 13 |
2 files changed, 6 insertions, 11 deletions
diff --git a/app/assets/javascripts/vue_merge_request_widget/components/deployment/deployment_info.vue b/app/assets/javascripts/vue_merge_request_widget/components/deployment/deployment_info.vue index db4a4ece002..33db9b87b17 100644 --- a/app/assets/javascripts/vue_merge_request_widget/components/deployment/deployment_info.vue +++ b/app/assets/javascripts/vue_merge_request_widget/components/deployment/deployment_info.vue @@ -32,12 +32,12 @@ export default { }, }, deployedTextMap: { - [MANUAL_DEPLOY]: __('Can deploy manually to'), + [MANUAL_DEPLOY]: __('Can be manually deployed to'), [WILL_DEPLOY]: __('Will deploy to'), [RUNNING]: __('Deploying to'), [SUCCESS]: __('Deployed to'), [FAILED]: __('Failed to deploy to'), - [CANCELED]: __('Canceled deploy to'), + [CANCELED]: __('Canceled deployment to'), }, computed: { deployTimeago() { diff --git a/app/assets/javascripts/vue_shared/components/bar_chart.vue b/app/assets/javascripts/vue_shared/components/bar_chart.vue index ff718eacc5b..25d7bfe515c 100644 --- a/app/assets/javascripts/vue_shared/components/bar_chart.vue +++ b/app/assets/javascripts/vue_shared/components/bar_chart.vue @@ -124,7 +124,9 @@ export default { }, }, mounted() { - this.draw(); + if (!this.allValuesEmpty) { + this.draw(); + } }, methods: { draw() { @@ -151,14 +153,7 @@ export default { this.yScale = d3.scaleLinear().rangeRound([this.vbHeight, 0]); this.xScale.domain(this.graphData.map(d => d.name)); - /* - If we have all-zero graph we want graph to center 0 on axis and not to draw - any kind of ticks on Y axis. Infinity allows us to do that. - - See https://gitlab.com/gitlab-org/gitlab/merge_requests/20627#note_251484582 - for detailed explanation - */ - this.yScale.domain([0, d3.max(this.graphData.map(d => d.value)) || Infinity]); + this.yScale.domain([0, d3.max(this.graphData.map(d => d.value))]); // Zoom/Panning Function this.zoom = d3 |