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
df2b360d
Commit
df2b360d
authored
Sep 09, 2021
by
Dheeraj Joshi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Switch to v-safe-html in awards_list.vue
parent
9cbf90dd
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
2 deletions
+4
-2
app/assets/javascripts/vue_shared/components/awards_list.vue
app/assets/javascripts/vue_shared/components/awards_list.vue
+4
-2
No files found.
app/assets/javascripts/vue_shared/components/awards_list.vue
View file @
df2b360d
<
script
>
<
script
>
import
{
GlIcon
,
GlButton
,
GlTooltipDirective
}
from
'
@gitlab/ui
'
;
import
{
GlIcon
,
GlButton
,
GlTooltipDirective
,
GlSafeHtmlDirective
}
from
'
@gitlab/ui
'
;
import
{
groupBy
}
from
'
lodash
'
;
import
{
groupBy
}
from
'
lodash
'
;
import
EmojiPicker
from
'
~/emoji/components/picker.vue
'
;
import
EmojiPicker
from
'
~/emoji/components/picker.vue
'
;
import
{
__
,
sprintf
}
from
'
~/locale
'
;
import
{
__
,
sprintf
}
from
'
~/locale
'
;
...
@@ -17,6 +17,7 @@ export default {
...
@@ -17,6 +17,7 @@ export default {
},
},
directives
:
{
directives
:
{
GlTooltip
:
GlTooltipDirective
,
GlTooltip
:
GlTooltipDirective
,
SafeHtml
:
GlSafeHtmlDirective
,
},
},
mixins
:
[
glFeatureFlagsMixin
()],
mixins
:
[
glFeatureFlagsMixin
()],
props
:
{
props
:
{
...
@@ -163,6 +164,7 @@ export default {
...
@@ -163,6 +164,7 @@ export default {
this
.
isMenuOpen
=
menuOpen
;
this
.
isMenuOpen
=
menuOpen
;
},
},
},
},
safeHtmlConfig
:
{
ADD_TAGS
:
[
'
gl-emoji
'
]
},
};
};
</
script
>
</
script
>
...
@@ -180,9 +182,9 @@ export default {
...
@@ -180,9 +182,9 @@ export default {
>
>
<template
#emoji
>
<template
#emoji
>
<span
<span
v-safe-html:
[$
options.safeHtmlConfig]=
"awardList.html"
class=
"award-emoji-block"
class=
"award-emoji-block"
data-testid=
"award-html"
data-testid=
"award-html"
v-html=
"awardList.html /* eslint-disable-line vue/no-v-html */"
></span>
></span>
</
template
>
</
template
>
<span
class=
"js-counter"
>
{{ awardList.list.length }}
</span>
<span
class=
"js-counter"
>
{{ awardList.list.length }}
</span>
...
...
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