diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-01-22 03:08:47 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-01-22 03:08:47 +0300 |
commit | 66ce6a78f6203652c34bd0532b63c394d5394cc4 (patch) | |
tree | 67408e003b1c4136bb8e35c1e9ac049563c1f1d5 /app/assets | |
parent | 1c23b3f1315ba1da3c3765acd34feb5c05bc7704 (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/assets')
5 files changed, 23 insertions, 16 deletions
diff --git a/app/assets/javascripts/monitoring/components/charts/time_series.vue b/app/assets/javascripts/monitoring/components/charts/time_series.vue index 0d442f14aea..8b1a9f6f770 100644 --- a/app/assets/javascripts/monitoring/components/charts/time_series.vue +++ b/app/assets/javascripts/monitoring/components/charts/time_series.vue @@ -311,7 +311,10 @@ export default { <gl-tooltip :target="() => $refs.graphTitle" :disabled="!showTitleTooltip"> {{ graphData.title }} </gl-tooltip> - <div class="prometheus-graph-widgets js-graph-widgets flex-fill"> + <div + class="prometheus-graph-widgets js-graph-widgets flex-fill" + data-qa-selector="prometheus_graph_widgets" + > <slot></slot> </div> </div> diff --git a/app/assets/javascripts/monitoring/components/dashboard.vue b/app/assets/javascripts/monitoring/components/dashboard.vue index 2c51252be39..8c33e13e2f0 100644 --- a/app/assets/javascripts/monitoring/components/dashboard.vue +++ b/app/assets/javascripts/monitoring/components/dashboard.vue @@ -342,7 +342,7 @@ export default { </script> <template> - <div class="prometheus-graphs"> + <div class="prometheus-graphs" data-qa-selector="prometheus_graphs"> <div class="prometheus-graphs-header gl-p-3 pb-0 border-bottom bg-gray-light"> <div class="row"> <template v-if="environmentsEndpoint"> diff --git a/app/assets/javascripts/monitoring/components/panel_type.vue b/app/assets/javascripts/monitoring/components/panel_type.vue index ec6a41d0540..5d4f3425ad0 100644 --- a/app/assets/javascripts/monitoring/components/panel_type.vue +++ b/app/assets/javascripts/monitoring/components/panel_type.vue @@ -138,6 +138,7 @@ export default { v-gl-tooltip class="ml-auto mx-3" toggle-class="btn btn-transparent border-0" + data-qa-selector="prometheus_widgets_dropdown" :right="true" :no-caret="true" :title="__('More actions')" @@ -161,7 +162,11 @@ export default { > {{ __('Generate link to chart') }} </gl-dropdown-item> - <gl-dropdown-item v-if="alertWidgetAvailable" v-gl-modal="`alert-modal-${index}`"> + <gl-dropdown-item + v-if="alertWidgetAvailable" + v-gl-modal="`alert-modal-${index}`" + data-qa-selector="alert_widget_menu_item" + > {{ __('Alerts') }} </gl-dropdown-item> </gl-dropdown> diff --git a/app/assets/javascripts/notes.js b/app/assets/javascripts/notes.js index 4195ea6425f..5756532d18d 100644 --- a/app/assets/javascripts/notes.js +++ b/app/assets/javascripts/notes.js @@ -11,7 +11,7 @@ old_notes_spec.js is the spec for the legacy, jQuery notes application. It has n */ import $ from 'jquery'; -import _ from 'underscore'; +import { escape, uniqueId } from 'lodash'; import Cookies from 'js-cookie'; import Autosize from 'autosize'; import 'jquery.caret'; // required by at.js @@ -1449,7 +1449,7 @@ export default class Notes { return { // eslint-disable-next-line no-jquery/no-serialize formData: $form.serialize(), - formContent: _.escape(content), + formContent: escape(content), formAction: $form.attr('action'), formContentOriginal: content, }; @@ -1516,18 +1516,16 @@ export default class Notes { `<li id="${uniqueId}" class="note being-posted fade-in-half timeline-entry"> <div class="timeline-entry-inner"> <div class="timeline-icon"> - <a href="/${_.escape(currentUsername)}"> + <a href="/${escape(currentUsername)}"> <img class="avatar s40" src="${currentUserAvatar}" /> </a> </div> <div class="timeline-content ${discussionClass}"> <div class="note-header"> <div class="note-header-info"> - <a href="/${_.escape(currentUsername)}"> - <span class="d-none d-sm-inline-block bold">${_.escape( - currentUsername, - )}</span> - <span class="note-headline-light">${_.escape(currentUsername)}</span> + <a href="/${escape(currentUsername)}"> + <span class="d-none d-sm-inline-block bold">${escape(currentUsername)}</span> + <span class="note-headline-light">${escape(currentUsername)}</span> </a> </div> </div> @@ -1541,8 +1539,8 @@ export default class Notes { </li>`, ); - $tempNote.find('.d-none.d-sm-inline-block').text(_.escape(currentUserFullname)); - $tempNote.find('.note-headline-light').text(`@${_.escape(currentUsername)}`); + $tempNote.find('.d-none.d-sm-inline-block').text(escape(currentUserFullname)); + $tempNote.find('.note-headline-light').text(`@${escape(currentUsername)}`); return $tempNote; } @@ -1627,7 +1625,7 @@ export default class Notes { // Show placeholder note if (tempFormContent) { - noteUniqueId = _.uniqueId('tempNote_'); + noteUniqueId = uniqueId('tempNote_'); $notesContainer.append( this.createPlaceholderNote({ formContent: tempFormContent, @@ -1642,7 +1640,7 @@ export default class Notes { // Show placeholder system note if (hasQuickActions) { - systemNoteUniqueId = _.uniqueId('tempSystemNote_'); + systemNoteUniqueId = uniqueId('tempSystemNote_'); $notesContainer.append( this.createPlaceholderSystemNote({ formContent: this.getQuickActionDescription( @@ -1825,7 +1823,7 @@ export default class Notes { }) .catch(() => { // Submission failed, revert back to original note - $noteBodyText.html(_.escape(cachedNoteBodyText)); + $noteBodyText.html(escape(cachedNoteBodyText)); $editingNote.removeClass('being-posted fade-in'); $editingNote.find('.fa.fa-spinner').remove(); diff --git a/app/assets/javascripts/pipelines/components/pipelines_table_row.vue b/app/assets/javascripts/pipelines/components/pipelines_table_row.vue index afb8439511f..33f5199aabe 100644 --- a/app/assets/javascripts/pipelines/components/pipelines_table_row.vue +++ b/app/assets/javascripts/pipelines/components/pipelines_table_row.vue @@ -331,6 +331,7 @@ export default { :loading="isRetrying" :disabled="isRetrying" container-class="js-pipelines-retry-button btn btn-default btn-retry" + data-qa-selector="pipeline_retry_button" @click="handleRetryClick" > <icon name="repeat" /> |