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
6495c449
Commit
6495c449
authored
Jan 21, 2022
by
Phil Hughes
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Converted draft note pending label to GlBadge
Closes
https://gitlab.com/gitlab-org/gitlab/-/issues/344296
parent
25b5e9d9
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
5 additions
and
12 deletions
+5
-12
app/assets/javascripts/batch_comments/components/draft_note.vue
...sets/javascripts/batch_comments/components/draft_note.vue
+3
-4
ee/app/assets/stylesheets/components/batch_comments/draft_note.scss
...ets/stylesheets/components/batch_comments/draft_note.scss
+0
-6
spec/frontend/batch_comments/components/draft_note_spec.js
spec/frontend/batch_comments/components/draft_note_spec.js
+2
-2
No files found.
app/assets/javascripts/batch_comments/components/draft_note.vue
View file @
6495c449
<
script
>
import
{
GlButton
,
GlSafeHtmlDirective
}
from
'
@gitlab/ui
'
;
import
{
GlButton
,
GlSafeHtmlDirective
,
GlBadge
}
from
'
@gitlab/ui
'
;
import
{
mapActions
,
mapGetters
,
mapState
}
from
'
vuex
'
;
import
NoteableNote
from
'
~/notes/components/noteable_note.vue
'
;
import
PublishButton
from
'
./publish_button.vue
'
;
...
...
@@ -9,6 +9,7 @@ export default {
NoteableNote
,
PublishButton
,
GlButton
,
GlBadge
,
},
directives
:
{
SafeHtml
:
GlSafeHtmlDirective
,
...
...
@@ -100,9 +101,7 @@ export default {
@
toggleResolveStatus=
"toggleResolveDiscussion(draft.id)"
>
<template
#note-header-info
>
<strong
class=
"badge draft-pending-label gl-mr-2"
>
{{
__
(
'
Pending
'
)
}}
</strong>
<gl-badge
variant=
"warning"
class=
"gl-mr-2"
>
{{
__
(
'
Pending
'
)
}}
</gl-badge>
</
template
>
</noteable-note>
</ul>
...
...
ee/app/assets/stylesheets/components/batch_comments/draft_note.scss
View file @
6495c449
...
...
@@ -30,12 +30,6 @@ button[disabled] {
}
}
.draft-pending-label
{
background
:
$orange-500
;
color
:
$white
;
vertical-align
:
text-top
;
}
.note.draft-note
{
margin
:
0
0
$gl-padding
;
padding
:
0
;
...
...
spec/frontend/batch_comments/components/draft_note_spec.js
View file @
6495c449
import
{
nextTick
}
from
'
vue
'
;
import
{
GlButton
}
from
'
@gitlab/ui
'
;
import
{
GlButton
,
GlBadge
}
from
'
@gitlab/ui
'
;
import
{
getByRole
}
from
'
@testing-library/dom
'
;
import
{
shallowMount
}
from
'
@vue/test-utils
'
;
import
{
stubComponent
}
from
'
helpers/stub_component
'
;
...
...
@@ -56,7 +56,7 @@ describe('Batch comments draft note component', () => {
it
(
'
renders template
'
,
()
=>
{
createComponent
();
expect
(
wrapper
.
find
(
'
.draft-pending-label
'
).
exists
()).
toBe
(
true
);
expect
(
wrapper
.
find
Component
(
GlBadge
).
exists
()).
toBe
(
true
);
const
note
=
wrapper
.
find
(
NoteableNote
);
...
...
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