diff --git a/CHANGELOG.md b/CHANGELOG.md
index 6a9003455e..a088b9a071 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -39,6 +39,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
### Changed
- [\#2128](https://github.com/cosmos/voyager/pull/2128) remove loading status on validator page when disconnected from the network @fedekunze
+- [\#2170](https://github.com/cosmos/voyager/pull/2170) bug with card-signed-in and explorer mode @jbibla
- [\#2167](https://github.com/cosmos/voyager/pull/2167) fixed votes showing wrong tally @faboweb
- [\#2167](https://github.com/cosmos/voyager/pull/2167) fixed not being able to deposit less then 1 atom not possible @faboweb
- [\#2167](https://github.com/cosmos/voyager/pull/2167) fixed sorting of proposals @faboweb
diff --git a/app/src/renderer/components/common/CardSignInRequired.vue b/app/src/renderer/components/common/CardSignInRequired.vue
index 85be4bb647..e57c4cb308 100644
--- a/app/src/renderer/components/common/CardSignInRequired.vue
+++ b/app/src/renderer/components/common/CardSignInRequired.vue
@@ -4,7 +4,8 @@
Sign In Required
- This page shows data for your address. To access the page, please
sign in.
+ This page shows data for a specific address. To access the page, please
+
sign in.
diff --git a/app/src/renderer/components/common/TmPage.vue b/app/src/renderer/components/common/TmPage.vue
index ae9fc79e22..660178f1bd 100644
--- a/app/src/renderer/components/common/TmPage.vue
+++ b/app/src/renderer/components/common/TmPage.vue
@@ -14,9 +14,9 @@
-
-
-
+
+
+
(to, from, next) => {
name: `My Delegations`
})
next(to.path)
- } else if (
- !store.state.session.signedIn &&
- to.matched.some(record => record.meta.requiresAuth)
- ) {
- // redirect to session page if auth required
- store.commit(`setSessionModalView`, `welcome`)
- store.commit(`toggleSessionModal`, true)
}
next()
}
@@ -65,7 +58,7 @@ export const startApp = async (
// directive to focus form fields
/* istanbul ignore next */
Vue.directive(`focus`, {
- inserted: function(el) {
+ inserted: function (el) {
el.focus()
}
})
@@ -83,11 +76,11 @@ export const startApp = async (
// handle uncaught errors
/* istanbul ignore next */
- window.addEventListener(`unhandledrejection`, function(event) {
+ window.addEventListener(`unhandledrejection`, function (event) {
Sentry.captureException(event.reason)
})
/* istanbul ignore next */
- window.addEventListener(`error`, function(event) {
+ window.addEventListener(`error`, function (event) {
Sentry.captureException(event.reason)
})
@@ -105,7 +98,7 @@ export const startApp = async (
})
router.beforeEach(routeGuard(store))
-
+
if (urlParams.experimental) {
store.commit(`setExperimentalMode`)
}
diff --git a/test/unit/specs/App.spec.js b/test/unit/specs/App.spec.js
index 3615158a34..f754486b32 100644
--- a/test/unit/specs/App.spec.js
+++ b/test/unit/specs/App.spec.js
@@ -141,6 +141,7 @@ describe(`App Start`, () => {
expect(commit).not.toHaveBeenCalled()
expect(next).toHaveBeenCalled()
})
+
it(`redirects to my validators`, async () => {
const commit = jest.fn()
const store = {
@@ -160,28 +161,6 @@ describe(`App Start`, () => {
guard(to, { fullPath: `/` }, next)
expect(next).toHaveBeenCalledWith(`/staking/my-delegations`)
})
-
- it(`redirects to session page if not logged in`, async () => {
- const commit = jest.fn()
- const store = {
- commit,
- state: { session: { pauseHistory: false, signedIn: false } },
- getters: { session: { pauseHistory: false, signedIn: false } }
- }
- const to = {
- redirectedFrom: ``,
- fullPath: `/wallet`,
- path: `/wallet`,
- name: `Wallet`,
- matched: [{ meta: { requiresAuth: true } }]
- }
- const next = jest.fn()
- const guard = routeGuard(store)
- // from.fullPath !== to.fullPath && !store.getters.user.pauseHistory
- guard(to, { fullPath: `/` }, next)
- expect(commit).toHaveBeenCalledWith(`setSessionModalView`, `welcome`)
- expect(commit).toHaveBeenCalledWith(`toggleSessionModal`, true)
- })
})
it(`activates analytics`, async () => {
diff --git a/test/unit/specs/components/common/__snapshots__/CardSignInRequired.spec.js.snap b/test/unit/specs/components/common/__snapshots__/CardSignInRequired.spec.js.snap
index 081c64fa41..9bec46ef0d 100644
--- a/test/unit/specs/components/common/__snapshots__/CardSignInRequired.spec.js.snap
+++ b/test/unit/specs/components/common/__snapshots__/CardSignInRequired.spec.js.snap
@@ -12,7 +12,8 @@ exports[`CardSignInRequired shows a sign in required card 1`] = `
- This page shows data for your address. To access the page, please
+ This page shows data for a specific address. To access the page, please
+
sign in
diff --git a/test/unit/specs/components/governance/__snapshots__/TabProposals.spec.js.snap b/test/unit/specs/components/governance/__snapshots__/TabProposals.spec.js.snap
index d7ac405872..75edee1ff8 100644
--- a/test/unit/specs/components/governance/__snapshots__/TabProposals.spec.js.snap
+++ b/test/unit/specs/components/governance/__snapshots__/TabProposals.spec.js.snap
@@ -424,7 +424,7 @@ exports[`TabProposals shows a message if there is nothing to display 1`] = `
>
- There are currently no governance proposals on the Cosmos Hub. Submit a new one by clicking the 'Create Proposal' button above.
+ There are currently no governance proposals to display. Click the 'Create Proposal' button to submit a proposal.
diff --git a/test/unit/specs/components/wallet/PageWallet.spec.js b/test/unit/specs/components/wallet/PageWallet.spec.js
index 867ec71858..74837a62e5 100644
--- a/test/unit/specs/components/wallet/PageWallet.spec.js
+++ b/test/unit/specs/components/wallet/PageWallet.spec.js
@@ -39,6 +39,24 @@ describe(`PageWallet`, () => {
expect(wrapper.vm.$el).toMatchSnapshot()
})
+ it(`should show the sending modal`, () => {
+ wrapper.vm.showModal(`STAKE`)
+ expect(wrapper.exists(`send-modal`)).toBe(true)
+ expect(wrapper.vm.$el).toMatchSnapshot()
+ })
+
+ it(`should not show denoms or the faucet button for a user who is not signed in`, () => {
+ $store.getters.session.signedIn = false
+ wrapper = shallowMount(PageWallet, {
+ localVue,
+ mocks: {
+ $store
+ }
+ })
+
+ expect(wrapper.vm.$el).toMatchSnapshot()
+ })
+
it(`should sort the balances by amount desc and denom asc`, () => {
expect(wrapper.vm.filteredBalances.map(x => x.denom)).toEqual([
`fermion`,
@@ -122,12 +140,6 @@ describe(`PageWallet`, () => {
expect(wrapper.exists(`tm-data-loading`)).toBe(true)
})
- it(`should show the sending modal`, () => {
- wrapper.vm.showModal(`STAKE`)
- expect(wrapper.exists(`send-modal`)).toBe(true)
- expect(wrapper.vm.$el).toMatchSnapshot()
- })
-
it(`should call getmoney`, async () => {
await PageWallet.methods.faucet.call({
$store, session: { signedIn: true, address: `cosmos1address` }
diff --git a/test/unit/specs/components/wallet/__snapshots__/PageWallet.spec.js.snap b/test/unit/specs/components/wallet/__snapshots__/PageWallet.spec.js.snap
index 10560d4db7..3f1c504481 100644
--- a/test/unit/specs/components/wallet/__snapshots__/PageWallet.spec.js.snap
+++ b/test/unit/specs/components/wallet/__snapshots__/PageWallet.spec.js.snap
@@ -52,10 +52,59 @@ exports[`PageWallet should display the wallet page 1`] = `
`;
+exports[`PageWallet should not show denoms or the faucet button for a user who is not signed in 1`] = `
+
+
+
+
+ Account empty
+
+
+
+
+
+ This account doesn't have anything in it yet.
+
+
+
+
+
+
+
+
+
+
+
+
+
+`;
+
exports[`PageWallet should show the sending modal 1`] = `