How to make a tooltip with blurred background in Vue.js?

1.2k Views Asked by At

Image How to make something like this? I have tried using v-tooltip and Vuetify but it wasn't a success. Is the best option to make background-color of #body grey and there is no other solution?

1

There are 1 best solutions below

0
scheric1 On BEST ANSWER

I think you want something like the z-index overlay https://vuetifyjs.com/en/components/overlays/#z-index

You could use that to highlight the button and then trigger the tooltip at the same time.

<template>
  <v-row justify="center">
    <v-btn
      class="white--text"
      color="teal"
      @click="overlay = !overlay"
    >
      Show Overlay
    </v-btn>

    <v-overlay
      :z-index="zIndex"
      :value="overlay"
    >
      <v-btn
        class="white--text"
        color="teal"
        @click="overlay = false"
      >
        Hide Overlay
      </v-btn>
    </v-overlay>
  </v-row>
</template>
<script>
  export default {
    data: () => ({
      overlay: false,
      zIndex: 0,
    }),
  }
</script>