[WIP] Добавил анимацию сайдбара

This commit is contained in:
megavrilinvv
2023-05-31 17:40:52 +03:00
parent 415528a62f
commit 3424b0bb26
2 changed files with 87 additions and 75 deletions

View File

@@ -1,7 +1,7 @@
<template lang="pug">
.w-full.flex.gap-x-2
calendar-open-sidebar(v-if="isOpen", :open-sidebar="openSidebar")
calendar-sidebar(v-else, :open-sidebar="openSidebar")
calendar-open-sidebar(:class="{'close': !isOpen, 'active': isOpen}" :open-sidebar="openSidebar")
calendar-sidebar.-ml-2(v-if="!isOpen", :open-sidebar="openSidebar")
calendar-wrapper
</template>
@@ -27,3 +27,17 @@ export default {
},
};
</script>
<style lang="sass" scoped>
.close
opacity: 0
width: 0px
height: 0
transition: opacity 0.2s, width 0.3s
.active
opacity: 1
width: 232px
height: 100%
transition: opacity 0.5s, width 0.3s
</style>