<template>
	<div class="container-fluid">
		<ul>
			<li v-for="(route, index) in pageRoutes" :key="index">
				<RouterLink :to="route.path">{{ `${route.path}【${String(route.name)}】` }}</RouterLink>
			</li>
		</ul>

		<RouterView />
	</div>
</template>

<script lang="ts" setup>
import { pageRoutes } from '@/router/module/pageRoutes';
import { userI18nStore } from '@/store/i18n.ts';
import { useI18n } from 'vue-i18n';

const i18nStore = userI18nStore();
const i18n = useI18n();

/**
 * * 切换多语言
 * @param value
 */
const handleI18n = (value: string) => {
	i18n.locale.value = value;
	i18n.mergeLocaleMessage(value, i18nStore.i18n[value]);
};
</script>

<style lang="scss" scoped></style>
