symbol switching fix; max amount

This commit is contained in:
Tim
2024-04-12 16:46:34 -04:00
parent fe1b633c4a
commit 0084847d82
7 changed files with 88 additions and 28 deletions

View File

@@ -92,8 +92,8 @@ export const useStore = defineStore('app', ()=> {
const vaultBalances = ref({}) // indexed by vault addr then by token addr. value is an int
const orders = ref({}) // indexed by vault value is another dictionary with orderIndex as key and order status values
const vault = computed(() => vaults.value.length === 0 ? null : vaults.value[0])
const balances = computed( () => vault.value === null ? {} : vaultBalances.value[vault] || {} )
const vault = computed(() => vaults.value.length === 0 ? null : vaults.value[0] )
const balances = computed( () => vault.value === null ? {} : vaultBalances.value[vault.value] || {} )
const tokens = computed(getTokens)
const factory = computed(() => !chain.value ? null : chain.value.factory)
const helper = computed(() => {console.log('chain helper', chain.value); return !chain.value ? null : chain.value.helper})