<script setup lang="ts">
	import { useRouter, useRoute } from 'vue-router'
	import { FlowType } from '@/types/enum'
	const router = useRouter()
	const route = useRoute()
	import { ref, computed } from 'vue'
	import HeaderTitle from '@/components/HeaderTitle.vue'
	import FooterNavigation from '@/components/FooterNavigation.vue'
	import RouteCache from '@/components/RouteCache.vue'
	import profile from './profile.vue'
	const props = defineProps({})
	const emit = defineEmits([])
	const profileRef = ref(null)
	const handleClickProfile = () => {
		profileRef.value.open()
	}
	const notShowFooter = computed(() => route.query.flowType !== FlowType.HISTORY)
</script>
<template>
	<div class="workshop">
		<header-title @clickProfile="handleClickProfile" />
		<RouteCache view-type="1" />
		<footer-navigation v-if="notShowFooter" />
		<template>
			<profile ref="profileRef" />
		</template>
	</div>
	
</template>
<style scoped lang="less">
	.workshop {
		width: 100%;
		height: 100%;
		display: flex;
		flex-direction: column;
		> .routeCache {
			flex: 1;
		}
	}
</style>