Commit 28207308 authored by Nicolò Maria Mezzopera's avatar Nicolò Maria Mezzopera

Merge branch 'Replace-calendar-icon-tooltip-sidebar-ab' into 'master'

Replacing vue shared tooltip on calendar icon

See merge request gitlab-org/gitlab!45059
parents 2576767a a3589f34
<script>
import { GlIcon } from '@gitlab/ui';
import tooltip from '~/vue_shared/directives/tooltip';
import { GlIcon, GlTooltipDirective } from '@gitlab/ui';
export default {
name: 'CollapsedCalendarIcon',
directives: {
tooltip,
GlTooltip: GlTooltipDirective,
},
components: {
GlIcon,
......@@ -41,16 +40,7 @@ export default {
</script>
<template>
<div
v-tooltip
:class="containerClass"
:title="tooltipText"
data-container="body"
data-placement="left"
data-html="true"
data-boundary="viewport"
@click="click"
>
<div v-gl-tooltip.left.viewport :class="containerClass" :title="tooltipText" @click="click">
<gl-icon v-if="showIcon" name="calendar" />
<slot>
<span> {{ text }} </span>
......
---
title: Replacing vue shared tooltip on calendar icon
merge_request: 45059
author:
type: other
......@@ -80,7 +80,7 @@ describe('collapsedGroupedDatePicker', () => {
it('should have tooltip as `Start and due date`', () => {
const icons = vm.$el.querySelectorAll('.sidebar-collapsed-icon');
expect(icons[0].dataset.originalTitle).toBe('Start and due date');
expect(icons[0].title).toBe('Start and due date');
});
});
});
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