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
a3ef3a6c
Commit
a3ef3a6c
authored
Jan 17, 2022
by
Paul Gascou-Vaillancourt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Make remediated-badge Pajamas compliant
Replaces ad hoc icon with GlBadge's icon prop in remediated_badge.vue.
parent
aed836d7
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
8 deletions
+4
-8
ee/app/assets/javascripts/vulnerabilities/components/remediated_badge.vue
...vascripts/vulnerabilities/components/remediated_badge.vue
+2
-5
ee/spec/frontend/vulnerabilities/remediated_badge_spec.js
ee/spec/frontend/vulnerabilities/remediated_badge_spec.js
+2
-3
No files found.
ee/app/assets/javascripts/vulnerabilities/components/remediated_badge.vue
View file @
a3ef3a6c
<
script
>
import
{
Gl
Icon
,
Gl
Popover
,
GlBadge
}
from
'
@gitlab/ui
'
;
import
{
GlPopover
,
GlBadge
}
from
'
@gitlab/ui
'
;
export
default
{
components
:
{
GlIcon
,
GlPopover
,
GlBadge
,
},
...
...
@@ -25,9 +24,7 @@ export default {
<
template
>
<div
class=
"gl-display-inline-block"
>
<gl-badge
ref=
"badge"
variant=
"info"
>
<gl-icon
name=
"check-circle-dashed"
/>
</gl-badge>
<gl-badge
ref=
"badge"
variant=
"info"
icon=
"check-circle-dashed"
/>
<gl-popover
ref=
"popover"
:content=
"
...
...
ee/spec/frontend/vulnerabilities/remediated_badge_spec.js
View file @
a3ef3a6c
import
{
Gl
Icon
,
Gl
Popover
,
GlBadge
}
from
'
@gitlab/ui
'
;
import
{
GlPopover
,
GlBadge
}
from
'
@gitlab/ui
'
;
import
{
shallowMount
}
from
'
@vue/test-utils
'
;
import
RemediatedBadge
from
'
ee/vulnerabilities/components/remediated_badge.vue
'
;
...
...
@@ -9,7 +9,6 @@ const POPOVER_CONTENT =
describe
(
'
Remediated badge component
'
,
()
=>
{
let
wrapper
;
const
findIcon
=
()
=>
wrapper
.
find
(
GlIcon
);
const
findBadge
=
()
=>
wrapper
.
find
(
GlBadge
);
const
createWrapper
=
()
=>
{
...
...
@@ -23,7 +22,7 @@ describe('Remediated badge component', () => {
afterEach
(()
=>
wrapper
.
destroy
());
it
(
'
should display the correct icon
'
,
()
=>
{
expect
(
find
Icon
().
props
(
'
name
'
)).
toBe
(
'
check-circle-dashed
'
);
expect
(
find
Badge
().
props
(
'
icon
'
)).
toBe
(
'
check-circle-dashed
'
);
});
it
(
'
should link the badge and the popover
'
,
()
=>
{
...
...
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