diff options
Diffstat (limited to 'app/assets/javascripts/notes/components/note_actions/reply_button.vue')
-rw-r--r-- | app/assets/javascripts/notes/components/note_actions/reply_button.vue | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/app/assets/javascripts/notes/components/note_actions/reply_button.vue b/app/assets/javascripts/notes/components/note_actions/reply_button.vue new file mode 100644 index 00000000000..b2f9d7f128a --- /dev/null +++ b/app/assets/javascripts/notes/components/note_actions/reply_button.vue @@ -0,0 +1,40 @@ +<script> +import { mapActions } from 'vuex'; +import { GlTooltipDirective, GlButton } from '@gitlab/ui'; +import Icon from '~/vue_shared/components/icon.vue'; + +export default { + name: 'ReplyButton', + components: { + Icon, + GlButton, + }, + directives: { + GlTooltip: GlTooltipDirective, + }, + props: { + noteId: { + type: String, + required: true, + }, + }, + methods: { + ...mapActions(['convertToDiscussion']), + }, +}; +</script> + +<template> + <div class="note-actions-item"> + <gl-button + ref="button" + v-gl-tooltip.bottom + class="note-action-button" + variant="transparent" + :title="__('Reply to comment')" + @click="convertToDiscussion(noteId)" + > + <icon name="comment" css-classes="link-highlight" /> + </gl-button> + </div> +</template> |