I made a box transition while it get bigger, how do I still make it have same transition effect on close cause it closes sharply.
<template>
<div class="hello">
<div @click="biggerbox = !biggerbox;" class="box" :class="{'biggerbox':biggerbox}"></div>
</div>
</template>
<script>
export default {
name: "HelloWorld",
data() {
return {
biggerbox: false
};
}
};
</script>
<style scoped>
.box {
background-color: red;
height: 80px;
width: 90px;
}
.biggerbox {
background-color: red;
height: 180px;
width: 190px;
display: flex;
transition-duration: 1s;
transition-timing-function: ease;
}
</style>
This is the link to the code sand box https://codesandbox.io/s/focused-dew-0pm34?file=/src/components/HelloWorld.vue:338-582