2021-10-13 03:07:42 +02:00
|
|
|
<template>
|
2022-07-27 01:54:32 +02:00
|
|
|
<div :class="`h-${size} w-${size} min-w-${size}`">
|
2022-03-04 02:03:34 +01:00
|
|
|
<component :is="iconComponentName" />
|
2021-10-13 03:07:42 +02:00
|
|
|
</div>
|
|
|
|
</template>
|
|
|
|
|
|
|
|
<script>
|
|
|
|
export default {
|
|
|
|
props: {
|
2022-03-04 02:03:34 +01:00
|
|
|
icon: String,
|
|
|
|
size: {
|
|
|
|
type: Number,
|
|
|
|
default: 5
|
|
|
|
}
|
2021-10-13 03:07:42 +02:00
|
|
|
},
|
|
|
|
data() {
|
|
|
|
return {}
|
|
|
|
},
|
2022-03-04 02:03:34 +01:00
|
|
|
computed: {
|
|
|
|
iconComponentName() {
|
|
|
|
if (this.icon === 'default') return `icons-database-svg`
|
|
|
|
return `icons-${this.icon}-svg`
|
|
|
|
}
|
|
|
|
},
|
2021-10-13 03:07:42 +02:00
|
|
|
methods: {},
|
|
|
|
mounted() {}
|
|
|
|
}
|
|
|
|
</script>
|