<template>
  <div class="mbui">
    <div class="btm-menu"  v-clickoutside="handleoutside" :class="{active:isShow}">
      <div class="brightness"></div>
      <slot name="imgList"></slot>
      <slot name="txtList"></slot>
      <img class="xiala" @click="$emit('close')" :src="require('@/assets/images/jiantou.png')" alt="">
    </div>

    <slot name="btn_zhankai"></slot>
    <slot name="header"></slot>
    <slot name="select"></slot>
  </div>
</template>

<script>
export default {
  props:['isShow'],
  data(){
    return {
    }
  },
  methods:{
    handleoutside(){
      this.$emit('close')
    }
  }
}
</script>

<style lang="less" scoped>
.mbui {
  .btm-menu {
    position: fixed;
    bottom: -50px;
    left: 0;
    z-index: 999;
    width: 100%;
    height: 220px;
    border-radius: 12px 12px 0 0;
    padding: 20px 0 0;
    overflow: hidden;
    max-height: 0;
    box-shadow: 0 -3px 6px rgba(0,0,0,0.6);
    background: rgba(0,0,0,0.4);
    transition: .3s ease all;
    .xiala{
      position: absolute;
      bottom: 30px;
      left: 50%;
      transform: translateX(-50%);
      width: 14px;
      z-index: 1000;
    }
  }
  .active{
    max-height: 220px;
    bottom: 0;
  }
}
</style>
