24 lines
No EOL
456 B
TypeScript
24 lines
No EOL
456 B
TypeScript
import { ref } from 'vue'
|
|
|
|
const isNavigationVisible = ref(false)
|
|
|
|
export const useNavigation = () => {
|
|
const toggleNavigation = () => {
|
|
isNavigationVisible.value = !isNavigationVisible.value
|
|
}
|
|
|
|
const showNavigation = () => {
|
|
isNavigationVisible.value = true
|
|
}
|
|
|
|
const hideNavigation = () => {
|
|
isNavigationVisible.value = false
|
|
}
|
|
|
|
return {
|
|
isNavigationVisible,
|
|
toggleNavigation,
|
|
showNavigation,
|
|
hideNavigation
|
|
}
|
|
} |