<script setup lang="ts">
import { RouterView } from "vue-router";
import { version } from "../package.json";
import router from "@/router";
import SiteNavigation from "@/components/SiteNavigation.vue";
import NavigationItem from "@/components/NavigationItem.vue";
import SiteFooter from "@/components/SiteFooter.vue";
</script>

<template>
  <SiteNavigation>
    <NavigationItem
      v-for="(route, idx) in router.options.routes"
      :key="idx"
      :icon="route.meta?.icon"
      :href="route.path"
    >{{ $t(`${route.meta?.title}`) }}</NavigationItem>
  </SiteNavigation>

  <main>
    <RouterView />
  </main>

  <SiteFooter>
    v{{ version }} &copy; {{ new Date().getFullYear() }} Sebin Nyshkim
  </SiteFooter>
</template>
