Commit f48e1500 authored by Kushal Pandya's avatar Kushal Pandya

Merge branch 'djadmin-dast-feedback-alerts' into 'master'

Add feedback alert from user in DAST On-demand Scans

See merge request gitlab-org/gitlab!43374
parents b3c7771f 0887c359
......@@ -22,7 +22,7 @@ export default {
},
data() {
return {
isDismissed: 'false',
isDismissed: false,
};
},
computed: {
......@@ -30,12 +30,12 @@ export default {
return `${slugifyWithUnderscore(this.featureName)}_feedback_dismissed`;
},
showAlert() {
return this.isDismissed === 'false';
return !this.isDismissed;
},
},
methods: {
dismissFeedbackAlert() {
this.isDismissed = 'true';
this.isDismissed = true;
},
},
};
......@@ -43,16 +43,12 @@ export default {
<template>
<div v-show="showAlert">
<local-storage-sync
:value="isDismissed"
:storage-key="storageKey"
@input="dismissFeedbackAlert"
/>
<local-storage-sync v-model="isDismissed" :storage-key="storageKey" as-json />
<gl-alert v-if="showAlert" class="gl-mt-5" @dismiss="dismissFeedbackAlert">
<gl-sprintf
:message="
__(
'We’ve been making changes to %{featureName} and we’d love your feedback %{linkStart}in this issue%{linkEnd} to help us improve the experience.',
'Please share your feedback about %{featureName} %{linkStart}in this issue%{linkEnd} to help us improve the experience.',
)
"
>
......
......@@ -19,6 +19,7 @@ import glFeatureFlagsMixin from '~/vue_shared/mixins/gl_feature_flags_mixin';
import { s__ } from '~/locale';
import { redirectTo } from '~/lib/utils/url_utility';
import dastOnDemandScanCreateMutation from '../graphql/dast_on_demand_scan_create.mutation.graphql';
import DismissibleFeedbackAlert from '~/vue_shared/components/dismissible_feedback_alert.vue';
const ERROR_RUN_SCAN = 'ERROR_RUN_SCAN';
const ERROR_FETCH_SCANNER_PROFILES = 'ERROR_FETCH_SCANNER_PROFILES';
......@@ -52,6 +53,7 @@ export default {
GlDropdownItem,
GlSkeletonLoader,
GlSprintf,
DismissibleFeedbackAlert,
},
directives: {
GlTooltip: GlTooltipDirective,
......@@ -231,6 +233,15 @@ export default {
<template>
<gl-form @submit.prevent="onSubmit">
<!--
This is a temporary change to solicit feedback from users
and shall be removed in https://gitlab.com/gitlab-org/gitlab/-/issues/255889
-->
<dismissible-feedback-alert
feature-name="on-demand DAST scans"
feedback-link="https://gitlab.com/gitlab-org/gitlab/-/issues/249684"
/>
<header class="gl-mb-6">
<h2>{{ s__('OnDemandScans|New on-demand DAST scan') }}</h2>
<p>
......
---
title: Add feedback alert in DAST On-demand Scans
merge_request: 43374
author:
type: added
......@@ -19050,6 +19050,9 @@ msgstr ""
msgid "Please set a new password before proceeding."
msgstr ""
msgid "Please share your feedback about %{featureName} %{linkStart}in this issue%{linkEnd} to help us improve the experience."
msgstr ""
msgid "Please solve the reCAPTCHA"
msgstr ""
......@@ -28781,9 +28784,6 @@ msgstr ""
msgid "Welcome to your issue board!"
msgstr ""
msgid "We’ve been making changes to %{featureName} and we’d love your feedback %{linkStart}in this issue%{linkEnd} to help us improve the experience."
msgstr ""
msgid "What are you searching for?"
msgstr ""
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment