evilSpins v1
This commit is contained in:
@@ -62,6 +62,10 @@ export const useUiStore = defineStore('ui', {
|
||||
},
|
||||
|
||||
getters: {
|
||||
isBoxSelected: () => {
|
||||
const dataStore = useDataStore()
|
||||
return dataStore.boxes.some((box) => box.state === 'box-selected')
|
||||
},
|
||||
getSelectedBox: () => {
|
||||
const dataStore = useDataStore()
|
||||
return (dataStore.boxes as Box[]).find((box) => box.state === 'box-selected') || null
|
||||
|
||||
Reference in New Issue
Block a user