<template>
  <div class="page-idle" @click="goToMenu">
    <IdlePlayer @click="goToMenu" />
  </div>
</template>

<script setup>
import { onMounted } from 'vue'
import { useRouter } from 'vue-router'
import { useScreenStore } from '@/stores/screen'
import IdlePlayer from '@/components/IdlePlayer.vue'

const router = useRouter()
const screenStore = useScreenStore()

const goToMenu = () => {
  router.push('/menu')
}

onMounted(() => {
  screenStore.fetchScreenTheme()
  screenStore.fetchPlayPlan()
  screenStore.fetchRobotStatus()
})
</script>

<style scoped>
.page-idle {
  width: 100vw;
  height: 100vh;
  overflow: hidden;
}
</style>
