advent22/ui/src/components/bulma/Button.vue

30 lines
552 B
Vue

<template>
<button class="button">
<span v-if="icon !== undefined" class="icon">
<font-awesome-icon :icon="icon" />
</span>
<span v-if="text !== ''">{{ text }}</span>
</button>
</template>
<script lang="ts">
import { Options, Vue } from "vue-class-component";
@Options({
props: {
icon: {
type: String,
required: false,
},
text: {
type: String,
required: false,
default: "",
},
},
})
export default class extends Vue {
public icon?: string;
public text!: string;
}
</script>