.<template lang="pug">
img._icon(
  v-on="$listeners"
  :src="'/icon/' + name"
  :style="style"
)
</template>

<script>
export default {
  props: {
    name: {
      type: String,
      required: true,
    },

    size: {
      type: Number,
      default: 20,
    },
  },

  computed: {
    style() {
      return {
        width: this.size + "px",
        height: this.size + "px",
      }
    },
  },
}
</script>
