This repository has been archived on 2024-02-08. You can view files and clone it, but cannot push or open issues or pull requests.
frontend/src/components/input/button.vue

30 lines
631 B
Vue

<template>
<a
class="button"
:class="{
'is-primary': type === 'primary',
'is-outlined': type === 'secondary',
'is-text is-inverted has-no-shadow underline-none': type === 'tertary',
}"
@click="e => $emit('click', e)"
>
<icon :icon="icon" v-if="icon !== ''"/>
<slot></slot>
</a>
</template>
<script>
export default {
name: 'x-button',
props: {
type: {
type: String,
default: 'primary',
},
icon: {
type: String,
default: '',
},
},
}
</script>