import { defineStore } from 'pinia'; import { ref, watch } from 'vue'; import { Upload } from '@3cr/viewer-types-ts'; export const useUploadStore = defineStore('upload', () => { const showUploads = ref(false); const uploads = ref([]); watch( uploads, (uploads) => { showUploads.value = uploads.length > 0; }, { deep: true }, ); return { uploads, showUploads }; });