Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
a34fe472
Commit
a34fe472
authored
Jul 20, 2020
by
Dheeraj Joshi
Committed by
Andrew Fontaine
Jul 20, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Smartly truncate URLs in DAST Modal
parent
1399d4a0
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
37 additions
and
37 deletions
+37
-37
ee/app/assets/javascripts/vue_shared/security_reports/components/dast_modal.vue
...pts/vue_shared/security_reports/components/dast_modal.vue
+32
-37
ee/changelogs/unreleased/dast-modal-truncation.yml
ee/changelogs/unreleased/dast-modal-truncation.yml
+5
-0
No files found.
ee/app/assets/javascripts/vue_shared/security_reports/components/dast_modal.vue
View file @
a34fe472
<
script
>
import
{
GlModal
,
GlIcon
,
GlSprintf
}
from
'
@gitlab/ui
'
;
import
{
GlModal
,
GlIcon
,
GlSprintf
,
GlTruncate
}
from
'
@gitlab/ui
'
;
import
{
n__
,
__
}
from
'
~/locale
'
;
export
default
{
components
:
{
GlModal
,
GlIcon
,
GlSprintf
},
components
:
{
GlModal
,
GlIcon
,
GlSprintf
,
GlTruncate
},
props
:
{
scannedUrls
:
{
required
:
true
,
...
...
@@ -40,7 +40,7 @@ export default {
variant
:
'
success
'
,
class
:
'
btn-secondary gl-button
'
,
href
:
this
.
downloadLink
,
download
:
true
,
download
:
''
,
'
data-testid
'
:
'
download-button
'
,
},
};
...
...
@@ -56,43 +56,38 @@ export default {
v-bind=
"$options.modal"
:action-secondary=
"downloadButton"
>
<div
class=
"gl-px-3"
>
<!-- heading -->
<div
class=
"gl-display-flex gl-text-gray-600"
>
<div
class=
"gl-w-11"
>
{{
__
(
'
Method
'
)
}}
</div>
<div
class=
"gl-flex-fill-1"
>
{{
__
(
'
URL
'
)
}}
</div>
</div>
<hr
class=
"gl-my-3"
/>
<!-- heading -->
<div
class=
"row gl-text-gray-600"
>
<div
class=
"col-1"
>
{{
__
(
'
Method
'
)
}}
</div>
<div
class=
"col-11"
>
{{
__
(
'
URL
'
)
}}
</div>
</div>
<hr
class=
"gl-my-3"
/>
<!-- rows -->
<div
v-for=
"(url, index) in limitedScannedUrls"
:key=
"index"
class=
"gl-display-flex gl-my-2"
>
<div
class=
"gl-w-11"
>
{{
url
.
requestMethod
.
toUpperCase
()
}}
</div>
<div
class=
"gl-flex-fill-1 gl-overflow-hidden gl-white-space-nowrap gl-text-overflow-ellipsis"
data-testid=
"dast-scanned-url"
>
{{
url
.
url
}}
</div>
<!-- rows -->
<div
v-for=
"(url, index) in limitedScannedUrls"
:key=
"index"
class=
"row gl-my-2"
>
<div
class=
"col-1"
>
{{
url
.
requestMethod
.
toUpperCase
()
}}
</div>
<div
class=
"col-11"
data-testid=
"dast-scanned-url"
>
<gl-truncate
:text=
"url.url"
position=
"middle"
/>
</div>
</div>
<!-- banner -->
<div
v-if=
"downloadLink"
class=
"gl-display-inline-block gl-bg-gray-50 gl-my-3 gl-pl-3 gl-pr-7 gl-py-5"
>
<gl-icon
name=
"bulb"
class=
"gl-vertical-align-middle gl-mr-5"
/>
<b
class=
"gl-vertical-align-middle"
>
<gl-sprintf
:message=
"
__('To view all %
{scannedResourcesCount} scanned URLs, please download the CSV file')
"
>
<template
#scannedResourcesCount
>
{{
scannedResourcesCount
}}
</
template
>
</gl-sprintf>
</b>
</div>
<!-- banner -->
<div
v-if=
"downloadLink"
class=
"gl-display-inline-block gl-bg-gray-50 gl-my-3 gl-pl-3 gl-pr-7 gl-py-5"
>
<gl-icon
name=
"bulb"
class=
"gl-vertical-align-middle gl-mr-5"
/>
<b
class=
"gl-vertical-align-middle"
>
<gl-sprintf
:message=
"
__('To view all %
{scannedResourcesCount} scanned URLs, please download the CSV file')
"
>
<template
#scannedResourcesCount
>
{{
scannedResourcesCount
}}
</
template
>
</gl-sprintf>
</b>
</div>
</gl-modal>
</template>
ee/changelogs/unreleased/dast-modal-truncation.yml
0 → 100644
View file @
a34fe472
---
title
:
Smartly truncate URLs in DAST Modal
merge_request
:
37078
author
:
type
:
changed
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment