<!-- * @Description: 清除选区工具 * @Author: 王晓颖 * @Date: 2021-03-10 09:50:44 --> <template> <div :style="{'margin': margin}" class="draw-card"> <el-button :disabled="disabled" class="icon-btn" title="清除选区" @click="onDelete('delete')"> <img src="@/assets/global_images/reset.png"> </el-button> </div> </template> <script> export default { name: 'ClearTool', props: { margin: { type: String, default: '0px 8px' }, // 边距 disabled: { type: Boolean, default: true } // 是否不允许操作 }, data() { return {} }, methods: { // 点击框选 onDelete(type) { this.$emit('click', type) } } } </script> <style rel="stylesheet/scss" lang="scss" scoped> .draw-card{ margin: 0px 3px; .icon-btn{ height: 40px; width: 40px; padding: 0px; -moz-box-shadow: 0px 1px 3px #d9d9d9; /* 老的 Firefox */ box-shadow: 0px 1px 3px #d9d9d9; img{ height: 15px; width: 15px; } } } </style>