<template>
  <svg class="svg-icon" aria-hidden="true" :style="{ width: size + 'px', height: size + 'px'}">
    <use :href="`#icon-${name}`" />
  </svg>
</template>

<script setup>
defineOptions({ name: 'SvgIcon' })

defineProps({
  name: String,
  size: {
    type: [String, Number],
    default: 30
  }
})
</script>
 
<style lang="scss" scoped>
.svg-icon {
  fill: currentColor;
  vertical-align: middle;
}
</style>