adrema/resources/js/components/ui/Button.vue

25 lines
597 B
Vue
Raw Normal View History

2023-05-18 01:13:28 +02:00
<template>
<button class="btn btn-primary relative group">
<div :class="{hidden: !isLoading, flex: isLoading}" class="absolute items-center top-0 h-full left-0 ml-2">
<ui-spinner class="border-primary-400 w-6 h-6 group-hover:border-primary-200"></ui-spinner>
</div>
2023-06-07 22:52:02 +02:00
<slot></slot>
2023-05-18 01:13:28 +02:00
</button>
</template>
<script>
import {menuStore} from '../../stores/menuStore.js';
export default {
data: function () {
return {};
},
props: {
isLoading: {
type: Boolean,
default: false,
},
},
};
</script>