From 7f6fde499f38807283ab99a6714f76d829be1907 Mon Sep 17 00:00:00 2001 From: GitLab Bot Date: Fri, 21 Aug 2020 21:10:01 +0000 Subject: [PATCH] Add latest changes from gitlab-org/gitlab@master --- .rubocop.yml | 5 + .../components/customize_homepage_banner.vue | 36 +++ app/views/dashboard/projects/index.html.haml | 3 +- ...emove_old_external_diff_migration_index.rb | 3 +- doc/README.md | 2 +- doc/administration/audit_events.md | 1 + doc/administration/instance_limits.md | 2 +- doc/api/pipelines.md | 4 +- doc/ci/README.md | 2 +- doc/ci/introduction/index.md | 2 +- doc/ci/junit_test_reports.md | 280 +---------------- doc/ci/metrics_reports.md | 2 +- doc/ci/pipelines/job_artifacts.md | 10 +- doc/ci/unit_test_reports.md | 286 ++++++++++++++++++ doc/development/cicd/index.md | 2 +- .../img/merge_request_analytics_v13_3.png | Bin 54156 -> 0 bytes .../img/mr_throughput_chart_v13_3.png | Bin 0 -> 62510 bytes .../img/mr_throughput_table_v13_3.png | Bin 0 -> 55637 bytes doc/user/analytics/index.md | 3 +- doc/user/analytics/merge_request_analytics.md | 41 ++- .../img/pipeline_security_v13_3.gif | Bin 548942 -> 0 bytes .../img/project_security_dashboard_v13_3.png | Bin 0 -> 168847 bytes .../security_dashboard/index.md | 8 +- doc/user/project/merge_requests/index.md | 2 +- .../testing_and_reports_in_merge_requests.md | 2 +- .../migration/complex_indexes_require_name.rb | 53 ++++ .../customize_homepage_banner_spec.js | 60 +++- .../complex_indexes_require_name_spec.rb | 78 +++++ 28 files changed, 581 insertions(+), 306 deletions(-) create mode 100644 doc/ci/unit_test_reports.md delete mode 100644 doc/user/analytics/img/merge_request_analytics_v13_3.png create mode 100644 doc/user/analytics/img/mr_throughput_chart_v13_3.png create mode 100644 doc/user/analytics/img/mr_throughput_table_v13_3.png delete mode 100644 doc/user/application_security/security_dashboard/img/pipeline_security_v13_3.gif create mode 100644 doc/user/application_security/security_dashboard/img/project_security_dashboard_v13_3.png create mode 100644 rubocop/cop/migration/complex_indexes_require_name.rb create mode 100644 spec/rubocop/cop/migration/complex_indexes_require_name_spec.rb diff --git a/.rubocop.yml b/.rubocop.yml index f3a264d1f2f..a00ca6199c2 100644 --- a/.rubocop.yml +++ b/.rubocop.yml @@ -509,3 +509,8 @@ Cop/PutGroupRoutesUnderScope: Include: - 'config/routes/group.rb' - 'ee/config/routes/group.rb' + +Migration/ComplexIndexesRequireName: + Exclude: + - !ruby/regexp /\Adb\/(post_)?migrate\/201.*\.rb\z/ + - !ruby/regexp /\Adb\/(post_)?migrate\/20200[1-7].*\.rb\z/ diff --git a/app/assets/javascripts/pages/dashboard/projects/index/components/customize_homepage_banner.vue b/app/assets/javascripts/pages/dashboard/projects/index/components/customize_homepage_banner.vue index 6b907f31a37..9fa441348c7 100644 --- a/app/assets/javascripts/pages/dashboard/projects/index/components/customize_homepage_banner.vue +++ b/app/assets/javascripts/pages/dashboard/projects/index/components/customize_homepage_banner.vue @@ -2,11 +2,15 @@ import { GlBanner } from '@gitlab/ui'; import { s__ } from '~/locale'; import axios from '~/lib/utils/axios_utils'; +import Tracking from '~/tracking'; + +const trackingMixin = Tracking.mixin(); export default { components: { GlBanner, }, + mixins: [trackingMixin], inject: { svgPath: { default: '', @@ -20,6 +24,9 @@ export default { calloutsFeatureId: { default: '', }, + trackLabel: { + default: '', + }, }, i18n: { title: s__('CustomizeHomepageBanner|Do you want to customize this page?'), @@ -31,8 +38,19 @@ export default { data() { return { visible: true, + tracking: { + label: this.trackLabel, + }, }; }, + created() { + this.$nextTick(() => { + this.addTrackingAttributesToButton(); + }); + }, + mounted() { + this.trackOnShow(); + }, methods: { handleClose() { axios @@ -45,6 +63,23 @@ export default { }); this.visible = false; + this.track('click_dismiss'); + }, + trackOnShow() { + if (this.visible) this.track('show_home_page_banner'); + }, + addTrackingAttributesToButton() { + // we can't directly add these on the button like we need to due to + // button not being modifiable currently + // https://gitlab.com/gitlab-org/gitlab-ui/-/blob/9209ec424e5cca14bc8a1b5c9fa12636d8c83dad/src/components/base/banner/banner.vue#L60 + const button = this.$refs.banner.$el.querySelector( + `[href='${this.preferencesBehaviorPath}']`, + ); + + if (button) { + button.setAttribute('data-track-event', 'click_go_to_preferences'); + button.setAttribute('data-track-label', this.trackLabel); + } }, }, }; @@ -53,6 +88,7 @@ export default {