<template>
  <div
    class="menuItem"
    :class="{
      menuActive: active,
    }"
  >
    <div class="icon">
      <slot name="icon"></slot>
    </div>
    <div class="menuName">{{ name }}</div>
  </div>
</template>
<script lang="ts" setup>
const props = defineProps<{
  name: string;
  active: boolean;
}>();
</script>
<style lang="scss" scoped>
$selectColor: var(--sy-black);

.menuItem {
  cursor: pointer;
  display: flex;
  align-items: center;
  width: 184px;
  height: 40px;
  .icon {
    margin-left: 27px;
    margin-right: 17px;
  }
  .menuName {
    font-size: 14px;
    font-weight: 400;
    line-height: 20px;
    color: $selectColor;
  }
}
.menuActive {
  background: #e5e5e5;
  border-radius: var(--sy-border-radius);
  .menuName {
    font-weight: 600;
  }
}
</style>
