/
prop-open-and-close-delay.vue
54 lines (52 loc) 路 1.15 KB
/
prop-open-and-close-delay.vue
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
<template>
<v-row>
<v-col
cols="12"
sm="6"
>
<v-hover
v-slot:default="{ hover }"
open-delay="200"
>
<v-card
:elevation="hover ? 16 : 2"
:class="{ 'on-hover': hover }"
class="mx-auto"
height="350"
max-width="350"
>
<v-card-text class="font-weight-medium mt-12 text-center subtitle-1">
Open Delay (Mouse enter)
</v-card-text>
</v-card>
</v-hover>
</v-col>
<v-col
cols="12"
sm="6"
>
<v-hover
v-slot:default="{ hover }"
close-delay="200"
>
<v-card
:elevation="hover ? 16 : 2"
:class="{ 'on-hover': hover }"
class="mx-auto"
height="350"
max-width="350"
>
<v-card-text class="font-weight-medium mt-12 text-center subtitle-1">
Close Delay (Mouse leave)
</v-card-text>
</v-card>
</v-hover>
</v-col>
</v-row>
</template>
<style lang="sass" scoped>
.v-card.on-hover.theme--dark
background-color: rgba(#FFF, 0.8)
>.v-card__text
color: #000
</style>