<template>
  <div class="seq-class">
    <Button v-if="addFlag"  type="primary" shape="circle" icon="md-add" size="small" @click="add" :disabled="addDisabled"></Button>
    <Button v-if="deleteFlag" type="error" style="margin-left:3px" shape="circle" icon="md-remove" size="small" @click="del" :disabled="delDisabled"></Button>
  </div>
</template>

<script>
export default {
  name: 'SeqButton',
  props: {
    addDisabled: {
      type: Boolean,
      default: false
    },
    delDisabled: {
      type: Boolean,
      default: false
    },
    //删除按钮
    deleteFlag:{
      type: [Boolean, Function],
      default: true
    },
    //新增按钮
    addFlag:{
      type: Boolean,
      default: true
    },

  },
  data() {
    return {}
  },
  methods: {
    add() {
      this.$emit('add')
    },
    del() {
      this.$emit('del')
    }
  },
  created() {
  }
}
</script>

<style scoped>
.seq-class{
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 22;
}
/deep/.ivu-btn-small{
  width: 20px!important;
  height: 20px!important;
  display: flex;
  justify-content: center;
}

</style>
