|
|
@ -1,23 +1,12 @@ |
|
|
|
<script lang="ts" setup> |
|
|
|
<script lang="ts" setup> |
|
|
|
const { isLeftSidebarOpen: _isLeftSidebarOpen } = storeToRefs(useSidebarStore()) |
|
|
|
const { isLeftSidebarOpen } = storeToRefs(useSidebarStore()) |
|
|
|
const isLeftSidebarOpen = ref(_isLeftSidebarOpen.value) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
const { isMobileMode } = useGlobal() |
|
|
|
const { isMobileMode } = useGlobal() |
|
|
|
|
|
|
|
|
|
|
|
watch(_isLeftSidebarOpen, (val) => { |
|
|
|
|
|
|
|
if (val) { |
|
|
|
|
|
|
|
isLeftSidebarOpen.value = true |
|
|
|
|
|
|
|
} else { |
|
|
|
|
|
|
|
setTimeout(() => { |
|
|
|
|
|
|
|
isLeftSidebarOpen.value = false |
|
|
|
|
|
|
|
}, 300) |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
}) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
const onClick = () => { |
|
|
|
const onClick = () => { |
|
|
|
if (_isLeftSidebarOpen.value) return |
|
|
|
if (isLeftSidebarOpen.value) return |
|
|
|
|
|
|
|
|
|
|
|
_isLeftSidebarOpen.value = !_isLeftSidebarOpen.value |
|
|
|
isLeftSidebarOpen.value = !isLeftSidebarOpen.value |
|
|
|
} |
|
|
|
} |
|
|
|
</script> |
|
|
|
</script> |
|
|
|
|
|
|
|
|
|
|
|