virtual sample : create virtual sample store, activate dl image btn
This commit is contained in:
parent
a98665313f
commit
fc576e917b
4 changed files with 147 additions and 8 deletions
11
src/stores/virtualSample.js
Normal file
11
src/stores/virtualSample.js
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
import { defineStore } from "pinia";
|
||||
import { ref, watch } from "vue";
|
||||
|
||||
export const useVirtualSampleStore = defineStore("virtual-sample", () => {
|
||||
const activeTab = ref("dynamic");
|
||||
const currentFile = ref(null);
|
||||
|
||||
watch(activeTab, () => (currentFile.value = null));
|
||||
|
||||
return { activeTab, currentFile };
|
||||
});
|
||||
Loading…
Add table
Add a link
Reference in a new issue