Skip to content

Commit 98bebf5

Browse files
[DDW-749] Remove Alonzo tada icon and countdown screen (#2708)
* [DDW-749] Remove tada button from top navigation * [DDW-749] Remove unused variables * [DDW-749] Put staking info route + menu items behind config parameter * [DW-749] remove unused variables from staking after alonzo tada removal * [DDW-749] Remove tadaButton from topBarContainer * [DDW-749] Use config property directly to hide stakingInfoPage * [DDW-749] Update Changelog, Update config for showing info page + tada button * [DDW-749] Put tadaButton behind config parameter * [DDW-749] Add topBarConfig to hide tadaButton * [DDW-749] Updates CHANGELOG * [DDW-749] Adds flow tag Co-authored-by: Nikola Glumac <[email protected]>
1 parent 1628382 commit 98bebf5

File tree

6 files changed

+17
-3
lines changed

6 files changed

+17
-3
lines changed

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22

33
## vNext
44

5+
### Features
6+
7+
- Removed "Alonzo tada" icon and "Alonzo countdown" screen ([PR 2708](https://github.com/input-output-hk/daedalus/pull/2708))
8+
59
### Fixes
610

711
- Fixed transaction timestamps localization ([PR 2702](https://github.com/input-output-hk/daedalus/pull/2702))

source/renderer/app/Routes.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ import WalletTokensPage from './containers/wallet/WalletTokensPage';
3434
import WalletSettingsPage from './containers/wallet/WalletSettingsPage';
3535
import WalletUtxoPage from './containers/wallet/WalletUtxoPage';
3636
import VotingRegistrationPage from './containers/voting/VotingRegistrationPage';
37+
import { IS_STAKING_INFO_PAGE_AVAILABLE } from './config/stakingConfig';
3738

3839
export const Routes = withRouter(() => (
3940
<Route path={ROUTES.ROOT}>
@@ -145,7 +146,9 @@ export const Routes = withRouter(() => (
145146
component={StakingRewardsPage}
146147
/>
147148
<Route path={ROUTES.STAKING.EPOCHS} component={StakingEpochsPage} />
148-
<Route path={ROUTES.STAKING.INFO} component={StakingInfoPage} />
149+
{IS_STAKING_INFO_PAGE_AVAILABLE && (
150+
<Route path={ROUTES.STAKING.INFO} component={StakingInfoPage} />
151+
)}
149152
</Staking>
150153
<Route
151154
path={ROUTES.REDEEM_ITN_REWARDS}

source/renderer/app/config/stakingConfig.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -117,5 +117,6 @@ export const DELEGATION_ACTIONS: {
117117
export const IS_GRID_REWARDS_VIEW_AVAILABLE = !isMainnet && !isFlight;
118118
export const IS_RANKING_DATA_AVAILABLE = true;
119119
export const IS_SATURATION_DATA_AVAILABLE = true;
120+
export const IS_STAKING_INFO_PAGE_AVAILABLE = false;
120121

121122
export const EPOCH_COUNTDOWN_INTERVAL = 1 * 1000; // 1 second | unit: milliseconds
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
// @flow
2+
export const IS_TADA_ICON_AVAILABLE = false;

source/renderer/app/containers/TopBarContainer.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ import menuIconOpened from '../assets/images/menu-opened-ic.inline.svg';
1111
import menuIconClosed from '../assets/images/menu-ic.inline.svg';
1212
import { matchRoute } from '../utils/routing';
1313
import { ROUTES } from '../routes-config';
14+
import { IS_TADA_ICON_AVAILABLE } from '../config/topBarConfig';
1415

1516
type Props = InjectedProps;
1617

@@ -40,7 +41,9 @@ export default class TopBarContainer extends Component<Props> {
4041
const { stakingInfoWasOpen } = staking;
4142
const shouldShowTadaIconAnimation =
4243
isAlonzoActivated && !stakingInfoWasOpen;
43-
const shouldShowTadaIcon = isAlonzoPending || isAlonzoActivated;
44+
const shouldShowTadaIcon =
45+
IS_TADA_ICON_AVAILABLE && (isAlonzoPending || isAlonzoActivated);
46+
4447
const { active, isWalletRoute, hasAnyWallets, hasRewardsWallets } = wallets;
4548
const {
4649
currentRoute,

source/renderer/app/containers/staking/Staking.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ import { ROUTES } from '../../routes-config';
1111
import { buildRoute } from '../../utils/routing';
1212
import type { InjectedContainerProps } from '../../types/injectedPropsType';
1313
import type { NavDropdownProps } from '../../components/navigation/Navigation';
14+
import { IS_STAKING_INFO_PAGE_AVAILABLE } from '../../config/stakingConfig';
1415

1516
type Props = InjectedContainerProps;
1617

@@ -111,7 +112,7 @@ export default class Staking extends Component<Props> {
111112
isActiveNavItem={this.isActiveNavItem}
112113
onNavItemClick={this.handleNavItemClick}
113114
activeItem={app.currentPage}
114-
showInfoTab={shouldShowInfoTab}
115+
showInfoTab={IS_STAKING_INFO_PAGE_AVAILABLE && shouldShowInfoTab}
115116
>
116117
{children}
117118
</StakingWithNavigation>

0 commit comments

Comments
 (0)