<!--
操作栏组件
@Author: linqian
@Date: 2021-07-28 14:23
-->
<template>
  <dg-row class="opt-bar">
    <dg-button
      v-for="(item, index) in pageOptList"
      :key="index"
      type="primary"
      :icon="item | optIcon"
      @click="handleSubmitPageOpt(item)"
      >{{ item }}</dg-button
    >
     <slot></slot>
  </dg-row>
</template>

<script>
export default {
  props: {
    pageOptList: {
      type: Array,
      default: () => []
    }
  },
  components: {},
  data() {
    return {};
  },
  computed: {},
  methods: {
      handleSubmitPageOpt(type) {
          this.$emit("submitPageOpt", type);
      }
  },
  created() {},
  mounted() {}
};
</script>

<style lang='scss' scoped>
.opt-bar {
    border-top: 1px dashed rgba(0,0,0,.15);
}
</style>