Commit 962420c0 authored by Phil Hughes's avatar Phil Hughes

Added tooltips to tree list header buttons in Web IDE

Closes #50141
parent 9964b678
<script> <script>
import Icon from '~/vue_shared/components/icon.vue'; import Icon from '~/vue_shared/components/icon.vue';
import tooltip from '~/vue_shared/directives/tooltip';
export default { export default {
directives: {
tooltip,
},
components: { components: {
Icon, Icon,
}, },
...@@ -26,6 +30,11 @@ export default { ...@@ -26,6 +30,11 @@ export default {
default: true, default: true,
}, },
}, },
computed: {
tooltipTitle() {
return this.showLabel ? '' : this.label;
},
},
methods: { methods: {
clicked() { clicked() {
this.$emit('click'); this.$emit('click');
...@@ -36,7 +45,9 @@ export default { ...@@ -36,7 +45,9 @@ export default {
<template> <template>
<button <button
v-tooltip
:aria-label="label" :aria-label="label"
:title="tooltipTitle"
type="button" type="button"
class="btn-blank" class="btn-blank"
@click.stop.prevent="clicked" @click.stop.prevent="clicked"
......
---
title: Added tooltips to tree list header
merge_request:
author:
type: added
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