Commit a739e1a9 authored by Jarek Ostrowski's avatar Jarek Ostrowski

Update todo vue tooltip with gl-tooltip

MR: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/47810
parent 13a73325
<script> <script>
import { GlLoadingIcon, GlIcon } from '@gitlab/ui'; import { GlLoadingIcon, GlIcon, GlTooltipDirective } from '@gitlab/ui';
import { __ } from '~/locale'; import { __ } from '~/locale';
import tooltip from '~/vue_shared/directives/tooltip';
const MARK_TEXT = __('Mark as done'); const MARK_TEXT = __('Mark as done');
const TODO_TEXT = __('Add a To-Do'); const TODO_TEXT = __('Add a To-Do');
export default { export default {
directives: {
tooltip,
},
components: { components: {
GlIcon, GlIcon,
GlLoadingIcon, GlLoadingIcon,
}, },
directives: {
GlTooltip: GlTooltipDirective,
},
props: { props: {
issuableId: { issuableId: {
type: Number, type: Number,
...@@ -71,16 +70,13 @@ export default { ...@@ -71,16 +70,13 @@ export default {
<template> <template>
<button <button
v-tooltip v-gl-tooltip.left.viewport
:class="buttonClasses" :class="buttonClasses"
:title="buttonTooltip" :title="buttonTooltip"
:aria-label="buttonLabel" :aria-label="buttonLabel"
:data-issuable-id="issuableId" :data-issuable-id="issuableId"
:data-issuable-type="issuableType" :data-issuable-type="issuableType"
type="button" type="button"
data-container="body"
data-placement="left"
data-boundary="viewport"
@click="handleButtonClick" @click="handleButtonClick"
> >
<gl-icon <gl-icon
......
...@@ -4,13 +4,8 @@ exports[`SidebarTodo template renders component container element with proper da ...@@ -4,13 +4,8 @@ exports[`SidebarTodo template renders component container element with proper da
<button <button
aria-label="Mark as done" aria-label="Mark as done"
class="btn btn-default btn-todo issuable-header-btn float-right" class="btn btn-default btn-todo issuable-header-btn float-right"
data-boundary="viewport"
data-container="body"
data-issuable-id="1" data-issuable-id="1"
data-issuable-type="epic" data-issuable-type="epic"
data-original-title=""
data-placement="left"
title=""
type="button" type="button"
> >
<gl-icon-stub <gl-icon-stub
......
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