<script setup>
import {ref} from "vue";

const headerNavSelected = ref(['home'])
</script>

<template>
  <a-layout class="container">
    <a-layout-header class="header">
      <div class="float-left">
        <img class="icon w-12 h-12" src="/icon.png" alt="icon">
        <span class="title mx-3 text-white text-xl">智能服务</span>
      </div>
      <a-menu
          v-model:selected-keys="headerNavSelected"
          theme="dark"
          mode="horizontal"
      >
        <a-menu-item key="home">
          <router-link to="/home">首页</router-link>
        </a-menu-item>
        <a-menu-item key="management">
          <router-link to="/management">管理台</router-link>
        </a-menu-item>
      </a-menu>
      <div class="float-right">

      </div>
    </a-layout-header>
    <router-view/>
  </a-layout>
</template>

<style scoped>
.container {
  min-height: 100vh;
}

.header {
  padding: 0 20px 0 20px;
}
</style>