<template>
  <div class="deviceStatistics card">
    <div class="card-head">
      <div class="title">告警占比</div>
    </div>
    <div class="card-chart">
      <slot name="chart"></slot>
    </div>
  </div>
</template>
<script setup></script>
<style scoped lang="less">
.card {
  height: 100%;
  background: #ffffff;
  padding: 16px 10px;
  box-sizing: border-box;
  position: relative;
  display: flex;
  border-radius: 5px;
  box-shadow: 0px 0px 12px rgba(0, 0, 0, 0.12);
  margin-bottom: 20px;
  .card-chart {
    height: 90%;
    width: 100%;
    margin-top: 30px;
  }

  .card-head {
    position: absolute;
    color: #061451;
    font-size: 18px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transform: translateX(-10px);
    margin-bottom: 20px;
    .title {
      &::before {
        display: inline-block;
        margin-right: 10px;
        content: "";
        width: 2px;
        height: 14px;
        border-radius: 20px;
        background: #061451;
      }
    }
    .search {
      display: flex;
      align-items: center;
    }
  }
}
</style>
