<!-- แสดง ui การโหลด -->
<template>
  <div>
    <q-inner-loading :showing="loaderVisibility">
      <q-spinner-cube size="80px" color="primary" />
    </q-inner-loading>
  </div>
</template>

<script setup lang="ts">
import { watch, ref } from "vue";
const props = defineProps({
  visibility: Boolean,
});

const loaderVisibility = ref<boolean>(props.visibility);

watch(props, (count, prevCount) => {
  loaderVisibility.value = props.visibility;
});
</script>
