major-project-dashboard-entry.vue 1.88 KB
<template>
  <workbench-card title="大项目部驾驶舱" :subtitle="$catName('医美') + '经营看板'" icon="el-icon-data-analysis" tone="purple">
    <div class="entry" @click="go">
      <div class="entry__icon"><i class="el-icon-data-analysis" /></div>
      <div class="entry__text">
        <div class="entry__title">进入大项目部战略决策中心</div>
        <div class="entry__sub">查看{{ $catName('医美') }}业绩、趋势与门店排行</div>
      </div>
      <i class="el-icon-arrow-right entry__arrow" />
    </div>
  </workbench-card>
</template>

<script>
import WorkbenchCard from '../workbench-card.vue'

export default {
  name: 'WidgetMajorProjectDashboardEntry',
  components: { WorkbenchCard },
  methods: {
    go() {
      this.$router.push('/extend/majorProjectDashboard').catch(() => {})
    }
  }
}
</script>

<style lang="scss" scoped>
.entry {
  display: flex;
  align-items: center;
  padding: 14px;
  border-radius: 10px;
  background: #faf5ff;
  border: 1px solid #e9d5ff;
  cursor: pointer;
  height: 100%;
  min-height: 72px;
  transition: box-shadow 200ms ease, border-color 200ms ease;

  &:hover {
    border-color: #c084fc;
    box-shadow: 0 4px 14px rgba(139, 92, 246, 0.12);
  }
}

.entry__icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: #f3e8ff;
  color: #8b5cf6;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  margin-right: 12px;
  flex-shrink: 0;
}

.entry__title { font-size: 15px; font-weight: 600; color: #1e293b; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.entry__sub { margin-top: 4px; font-size: 12px; color: #94a3b8; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.entry__text { flex: 1; min-width: 0; }
.entry__arrow { color: #94a3b8; font-size: 16px; }

@media (prefers-reduced-motion: reduce) {
  .entry { transition: none !important; }
}
</style>