feat: show and hide sidebar - fixed #1716
This commit is contained in:
47
components/smart/HideMenu.vue
Normal file
47
components/smart/HideMenu.vue
Normal file
@@ -0,0 +1,47 @@
|
||||
<template>
|
||||
<div
|
||||
v-tooltip="$t(active ? 'hide_sidebar' : 'show_sidebar')"
|
||||
class="
|
||||
absolute
|
||||
hidden
|
||||
md:flex
|
||||
items-center
|
||||
justify-center
|
||||
px-2
|
||||
py-1
|
||||
bg-brdColor
|
||||
text-fgLightColor
|
||||
hover:text-fgColor
|
||||
my-4
|
||||
z-10
|
||||
rounded-l
|
||||
right-0
|
||||
cursor-pointer
|
||||
"
|
||||
@click="$emit('toggle')"
|
||||
>
|
||||
<i
|
||||
class="
|
||||
transition
|
||||
origin-center
|
||||
transform
|
||||
material-icons
|
||||
pointer-events-none
|
||||
"
|
||||
:class="{ 'rotate-180': active }"
|
||||
>
|
||||
menu_open
|
||||
</i>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
props: {
|
||||
active: {
|
||||
type: Boolean,
|
||||
default: false,
|
||||
},
|
||||
},
|
||||
}
|
||||
</script>
|
||||
Reference in New Issue
Block a user