<template>
  <div class="LayerDrawer lightOrDark">
    <div class="title">
      <span
        :style="{
          color: '#0081FF',
          fontSize: '23px',
          marginLeft: '20px',
        }"
      >
        |
      </span>
      <span style="font-size: 23px"> 操作 </span>
      <CloseOutlined
        @click="setLayerDrawerShow"
        :style="{ position: 'absolute', left: '300px', fontSize: '20px' }"
      />
    </div>
    <a-divider />
    <div>
      <a-button type="primary" class="blue line-up"> <FormOutlined />编辑样式 </a-button>
    </div>
    <a-divider />
    <div>
      <div class="item">
        <div class="item-title"> 123 </div>
        <div class="item-value"> 456 </div>
      </div>
    </div>
    <a-divider />
    <div class="item-button">
      <a-button style="width: 100px"> 取消 </a-button>
      <a-button style="width: 100px" type="primary" class="blue line-up"> 确认 </a-button>
    </div>
    <a-divider />
    <div class="item-yangshi">
      <a-radio-group v-model:value="yangshiOrJiaohu" button-style="solid">
        <a-radio-button value="1">&emsp;&emsp;样式&emsp;&emsp;</a-radio-button>
        <a-radio-button value="0">&emsp;&emsp;交互&emsp;&emsp;</a-radio-button>
      </a-radio-group>
    </div>
  </div>
</template>
<script lang="ts" setup>
  import { ref, defineEmits, defineProps } from 'vue';
  import { FormOutlined, CloseOutlined } from '@ant-design/icons-vue';

  const props = defineProps(['layerDrawerShowData']);
  const emits = defineEmits(['setLayerDrawerShow']);
  const yangshiOrJiaohu = ref('1');

  // 操作
  function setLayerDrawerShow(item) {
    emits('setLayerDrawerShow', false);
  }
</script>
<style lang="less" scoped>
  html[data-theme='light'] {
    .lightOrDark {
      background-color: #fff;
    }
  }
  [data-theme='dark'] {
    .lightOrDark {
      background-color: #000000;
    }
  }

  .LayerDrawer {
    position: absolute;
    width: 350px;
    bottom: 30px;
    height: calc(100% - 30px);
  }
  .title {
    margin-top: 15px;
    height: 25px;
  }
  .blue {
    background-color: #0081ff;
  }
  .line-up {
    margin-left: 10px;
  }

  .item-header {
    width: 100%;
    border-bottom: 1px solid #088eda;
  }
  .item {
    // border: 1px solid #088eda;
    width: calc(100% - 20px);
    height: 30px;
    line-height: 30px;
    margin-left: 10px;
    line-height: 30px;
  }

  .item-title {
    width: 40%;
    float: left;
    font-size: 12px;
    border: 1px solid #088eda;
    text-overflow: ellipsis;
    overflow: hidden;
    white-space: nowrap;
  }
  .item-value {
    width: calc(60%);
    float: left;
    font-size: 12px;
    border-top: 1px solid #088eda;
    border-bottom: 1px solid #088eda;
    border-right: 1px solid #088eda;
    text-overflow: ellipsis;
    overflow: hidden;
    white-space: nowrap;
  }

  .item-button {
    display: flex;
    justify-content: center;
    width: 100%;
  }

  .item-yangshi {
    display: flex;
    justify-content: center;
    width: 100%;
  }
</style>
