Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrandon Labuschagne <blabuschagne@gitlab.com>2019-11-15 17:39:29 +0300
committerAakriti Gupta <agupta@gitlab.com>2019-11-20 12:36:19 +0300
commita416b83b6c0e1b8db9dd9829d16ca420bdb2fbe9 (patch)
tree24b03e0a11d8bc608e8d57f25482de6d90c3a82c /app/assets/javascripts/cycle_analytics
parent9e674f92a3e3f2c4f524517cfa31864525844095 (diff)
Ensure that summary items remain aligned
Default number of items is 3. If this is not the case, then increase the column width of the summary items to cater for 2 items plus the date filter.
Diffstat (limited to 'app/assets/javascripts/cycle_analytics')
-rw-r--r--app/assets/javascripts/cycle_analytics/cycle_analytics_bundle.js6
1 files changed, 6 insertions, 0 deletions
diff --git a/app/assets/javascripts/cycle_analytics/cycle_analytics_bundle.js b/app/assets/javascripts/cycle_analytics/cycle_analytics_bundle.js
index cd67ba5fab8..1074ce0e744 100644
--- a/app/assets/javascripts/cycle_analytics/cycle_analytics_bundle.js
+++ b/app/assets/javascripts/cycle_analytics/cycle_analytics_bundle.js
@@ -58,10 +58,16 @@ export default () => {
service: this.createCycleAnalyticsService(cycleAnalyticsEl.dataset.requestPath),
};
},
+ defaultNumberOfSummaryItems: 3,
computed: {
currentStage() {
return this.store.currentActiveStage();
},
+ summaryTableColumnClass() {
+ return this.state.summary.length === this.$options.defaultNumberOfSummaryItems
+ ? 'col-sm-3'
+ : 'col-sm-4';
+ },
},
created() {
// Conditional check placed here to prevent this method from being called on the