diff --git a/src/constants/apps-consts.ts b/src/constants/apps-consts.ts index 5f44e549..f159326c 100644 --- a/src/constants/apps-consts.ts +++ b/src/constants/apps-consts.ts @@ -20,14 +20,14 @@ export const APPS_CONSTS = [ }, { name: 'Settings', - subText: 'Lookup network activity and statistics.', + subText: 'Manage your wallet settings.', url: '/settings', private: true, hidden: true, }, { - name: 'Partners', - subText: 'Lookup network activity and statistics.', + name: 'Foundation', + subText: 'Tools for foundation members.', url: '/foundation', private: true, hidden: true, diff --git a/src/redux/slices/app-config.ts b/src/redux/slices/app-config.ts index 3ea577ff..9b44cec7 100644 --- a/src/redux/slices/app-config.ts +++ b/src/redux/slices/app-config.ts @@ -57,7 +57,7 @@ const appConfigSlice = createSlice({ }, updateApps(state, { payload }) { if (payload) { - state.apps.find(elem => elem.name === 'Partners') + state.apps.find(elem => elem.name === 'Foundation') let t = state.apps t[4].hidden = false state.apps = [...t] @@ -71,7 +71,7 @@ const appConfigSlice = createSlice({ extraReducers: builder => { builder.addCase(updateAuthStatus.fulfilled, (state, { payload }) => { if (store.getters['Platform/isOfferCreator']) { - state.apps.find(elem => elem.name === 'Partners') + state.apps.find(elem => elem.name === 'Foundation') let t = state.apps t[4].hidden = false state.apps = [...t] diff --git a/src/views/access/LoadComponent.tsx b/src/views/access/LoadComponent.tsx index 46c84b08..29669209 100644 --- a/src/views/access/LoadComponent.tsx +++ b/src/views/access/LoadComponent.tsx @@ -1,5 +1,6 @@ import React, { useEffect, useRef, useState } from 'react' import { mountAccessComponents } from 'wallet/mountAccessComponents' +import store from 'wallet/store' import { useAppDispatch } from '../../hooks/reduxHooks' import { useEffectOnce } from '../../hooks/useEffectOnce' import { updateAccount, updateValues } from '../../redux/slices/app-config' @@ -10,10 +11,14 @@ const LoadComponent = ({ type, props }) => { const [updateStore, setUpdateStore] = useState(null) const dispatch = useAppDispatch() const setAccount = account => dispatch(updateAccount(account)) + async function updateAuth() { + await store.dispatch('Platform/updateAddressStates') + dispatch(updateAuthStatus(updateStore?.isAuth)) + } useEffect(() => { dispatch(updateValues(updateStore)) if (updateStore?.isAuth) { - dispatch(updateAuthStatus(updateStore?.isAuth)) + updateAuth() } }, [updateStore]) // eslint-disable-line react-hooks/exhaustive-deps diff --git a/src/views/landing/LandingPage.tsx b/src/views/landing/LandingPage.tsx index 9e658b2c..284197c2 100644 --- a/src/views/landing/LandingPage.tsx +++ b/src/views/landing/LandingPage.tsx @@ -41,7 +41,7 @@ export default function LandingPage() { {allApps?.map((app, index) => { if ( !app.hidden && - (app.private === false || (app.name === 'Partners' && isAuth)) + (app.private === false || (app.name === 'Foundation' && isAuth)) ) return (