<template>
  <view class="admin-page">
    <view class="admin-card header-card">
      <text class="title">微信菜单</text>
    </view>
    
    <view class="admin-card content-card menu-editor-wrap">
      <!-- 微信菜单编辑器的模拟界面 -->
      <view class="phone-preview">
        <view class="phone-header">
          <text class="status-bar">1:21 AM</text>
          <view class="nav-bar">
            <text class="back">返回</text>
            <text class="user-icon">👤</text>
          </view>
        </view>
        <view class="phone-body">
          <!-- 菜单展示区域 -->
          <view class="menu-display">
            <view class="menu-bottom">
              <view class="keyboard-icon">⌨️</view>
              <view class="menu-items">
                <view class="menu-item">手机111</view>
                <view class="menu-item active">商品分类</view>
                <view class="menu-item">+</view>
              </view>
            </view>
          </view>
        </view>
      </view>
      
      <view class="menu-settings">
        <view class="tip-box">
          <text>点击左侧菜单进行编辑</text>
        </view>
        <!-- 这里将来可以放菜单编辑表单 -->
      </view>
    </view>
  </view>
</template>

<script setup lang="uts">
// 微信菜单页面逻辑
</script>

<style scoped>
.menu-editor-wrap {
  display: flex;
  flex-direction: row;
  padding: 40px;
  gap: 40px;
  min-height: 600px;
}

.phone-preview {
  width: 320px;
  height: 560px;
  border: 1px solid #ddd;
  border-radius: 30px;
  overflow: hidden;
  background-color: #f5f5f5;
  display: flex;
  flex-direction: column;
}

.phone-header {
  background-color: #333;
  color: #fff;
  padding: 10px 15px;
}

.nav-bar {
  display: flex;
  justify-content: space-between;
  margin-top: 10px;
}

.phone-body {
  flex: 1;
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}

.menu-bottom {
  height: 50px;
  background-color: #fff;
  border-top: 1px solid #eee;
  display: flex;
  align-items: center;
}

.keyboard-icon {
  width: 50px;
  text-align: center;
  border-right: 1px solid #eee;
}

.menu-items {
  flex: 1;
  display: flex;
}

.menu-item {
  flex: 1;
  text-align: center;
  line-height: 50px;
  border-right: 1px solid #eee;
  font-size: 14px;
}

.menu-item.active {
  border: 2px solid #2d8cf0;
  background-color: #f0f7ff;
}

.menu-settings {
  flex: 1;
  background-color: #fff;
}

.tip-box {
  padding: 20px;
  background-color: #f8f8f9;
  border-radius: 4px;
  color: #808695;
}
</style>
