Commit c01227e4 authored by Michael Le's avatar Michael Le Committed by Enrique Alcántara

Replace popover with GlPopover component

parent 12147d80
<script> <script>
import { GlIcon } from '@gitlab/ui'; import { GlIcon, GlPopover } from '@gitlab/ui';
import { __, sprintf } from '../../../locale'; import { __, sprintf } from '../../../locale';
import popover from '../../../vue_shared/directives/popover'; import popover from '../../../vue_shared/directives/popover';
import { MAX_TITLE_LENGTH, MAX_BODY_LENGTH } from '../../constants'; import { MAX_TITLE_LENGTH, MAX_BODY_LENGTH } from '../../constants';
...@@ -10,6 +10,7 @@ export default { ...@@ -10,6 +10,7 @@ export default {
}, },
components: { components: {
GlIcon, GlIcon,
GlPopover,
}, },
props: { props: {
text: { text: {
...@@ -58,7 +59,7 @@ export default { ...@@ -58,7 +59,7 @@ export default {
}, },
}, },
popoverOptions: { popoverOptions: {
trigger: 'hover', triggers: 'hover',
placement: 'top', placement: 'top',
content: sprintf( content: sprintf(
__(` __(`
...@@ -83,9 +84,16 @@ export default { ...@@ -83,9 +84,16 @@ export default {
<ul class="nav-links"> <ul class="nav-links">
<li> <li>
{{ __('Commit Message') }} {{ __('Commit Message') }}
<span v-popover="$options.popoverOptions" class="form-text text-muted gl-ml-3"> <div id="ide-commit-message-popover-container">
<span id="ide-commit-message-question" class="form-text text-muted gl-ml-3">
<gl-icon name="question" /> <gl-icon name="question" />
</span> </span>
<gl-popover
target="ide-commit-message-question"
container="ide-commit-message-popover-container"
v-bind="$options.popoverOptions"
/>
</div>
</li> </li>
</ul> </ul>
</div> </div>
......
---
title: Update popover to gl-popover on WebIDE commit message
merge_request: 43499
author:
type: other
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment