Skip to content

Commit

Permalink
[DDW-983] Adjustments
Browse files Browse the repository at this point in the history
  • Loading branch information
thedanheller committed Nov 8, 2019
1 parent 8cf6aa8 commit b32ea79
Show file tree
Hide file tree
Showing 9 changed files with 45 additions and 23 deletions.
9 changes: 7 additions & 2 deletions source/renderer/app/components/layout/TopBar.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ export default class TopBar extends Component<Props> {
leftIcon,
activeWallet,
children,
onTransferFunds,
hasAnyWallets,
onTransferFunds,
onWalletAdd,
} = this.props;

Expand All @@ -45,6 +45,11 @@ export default class TopBar extends Component<Props> {
activeWallet.amount > 0 &&
((hasAnyWallets && onTransferFunds) || onWalletAdd);

const onTransferFundsFn =
onTransferFunds && activeWallet
? () => onTransferFunds(activeWallet.id)
: () => {};

const topBarTitle = activeWallet ? (
<span className={styles.walletInfo}>
<span className={styles.walletName}>
Expand Down Expand Up @@ -82,7 +87,7 @@ export default class TopBar extends Component<Props> {
{hasLegacyNotification && (
<LegacyNotification
onLearnMore={() => null}
onTransferFunds={() => onTransferFunds(activeWallet.id)}
onTransferFunds={onTransferFundsFn}
hasAnyWallets={hasAnyWallets}
onWalletAdd={onWalletAdd}
/>
Expand Down
1 change: 0 additions & 1 deletion source/renderer/app/containers/TopBarContainer.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import { observer, inject } from 'mobx-react';
import TopBar from '../components/layout/TopBar';
import NodeSyncStatusIcon from '../components/widgets/NodeSyncStatusIcon';
import NewsFeedIcon from '../components/widgets/NewsFeedIcon';
import WalletCreateDialog from '../components/wallet/WalletCreateDialog';
import WalletTestEnvironmentLabel from '../components/widgets/WalletTestEnvironmentLabel';
import type { InjectedProps } from '../types/injectedPropsType';
import menuIconOpened from '../assets/images/menu-opened-ic.inline.svg';
Expand Down
1 change: 1 addition & 0 deletions source/renderer/app/i18n/locales/de-DE.json
Original file line number Diff line number Diff line change
Expand Up @@ -457,6 +457,7 @@
"wallet.legacy.badge.label": "!!!Legacy",
"wallet.legacy.notification.actionLearnMore": "!!!Learn more",
"wallet.legacy.notification.actionMove": "!!!Move all of the ada from this wallet",
"wallet.legacy.notification.addWallet": "!!!Move all of the ada from this wallet",
"wallet.legacy.notification.description": "!!!This is a legacy wallet which uses legacy addresses and does not support new features. Please move all of the ada from this legacy wallet to one of the wallets where new features are available. You can also create a brand new wallet for your ada in case you don’t want to move ada to one of your existing wallets. A sequence of screens will guide you through the process.",
"wallet.legacy.notification.title": "!!!Move funds from the legacy wallet",
"wallet.navigation.more": "!!!More",
Expand Down
50 changes: 32 additions & 18 deletions source/renderer/app/i18n/locales/defaultMessages.json
Original file line number Diff line number Diff line change
Expand Up @@ -1348,6 +1348,20 @@
"column": 14,
"line": 27
}
},
{
"defaultMessage": "!!!Move all of the ada from this wallet",
"description": "Add wallet action of legacy notification.",
"end": {
"column": 3,
"line": 36
},
"file": "source/renderer/app/components/notifications/LegacyNotification.js",
"id": "wallet.legacy.notification.addWallet",
"start": {
"column": 13,
"line": 32
}
}
],
"path": "source/renderer/app/components/notifications/LegacyNotification.json"
Expand Down Expand Up @@ -7040,125 +7054,125 @@
"description": "Title in the transfer funds form.",
"end": {
"column": 3,
"line": 22
"line": 26
},
"file": "source/renderer/app/components/wallet/transfer-funds/TransferFundsStep2Dialog.js",
"id": "wallet.transferFunds.dialog2.title",
"start": {
"column": 15,
"line": 18
"line": 22
}
},
{
"defaultMessage": "!!!Confirm transfer from the {sourceWalletName}wallet to the {targetWalletName} wallet.",
"description": "description in the transfer funds form.",
"end": {
"column": 3,
"line": 28
"line": 32
},
"file": "source/renderer/app/components/wallet/transfer-funds/TransferFundsStep2Dialog.js",
"id": "wallet.transferFunds.dialog2.label.description",
"start": {
"column": 15,
"line": 23
"line": 27
}
},
{
"defaultMessage": "!!!To",
"description": "Label To in the transfer funds form",
"end": {
"column": 3,
"line": 33
"line": 37
},
"file": "source/renderer/app/components/wallet/transfer-funds/TransferFundsStep2Dialog.js",
"id": "wallet.transferFunds.dialog2.label.to",
"start": {
"column": 11,
"line": 29
"line": 33
}
},
{
"defaultMessage": "!!!Amount",
"description": "Label Amount in the transfer funds form",
"end": {
"column": 3,
"line": 38
"line": 42
},
"file": "source/renderer/app/components/wallet/transfer-funds/TransferFundsStep2Dialog.js",
"id": "wallet.transferFunds.dialog2.label.amount",
"start": {
"column": 15,
"line": 34
"line": 38
}
},
{
"defaultMessage": "!!!Fees",
"description": "Label Fees in the transfer funds form",
"end": {
"column": 3,
"line": 43
"line": 47
},
"file": "source/renderer/app/components/wallet/transfer-funds/TransferFundsStep2Dialog.js",
"id": "wallet.transferFunds.dialog2.label.fees",
"start": {
"column": 13,
"line": 39
"line": 43
}
},
{
"defaultMessage": "!!!Total",
"description": "Total Fees in the transfer funds form",
"end": {
"column": 3,
"line": 48
"line": 52
},
"file": "source/renderer/app/components/wallet/transfer-funds/TransferFundsStep2Dialog.js",
"id": "wallet.transferFunds.dialog2.label.total",
"start": {
"column": 14,
"line": 44
"line": 48
}
},
{
"defaultMessage": "!!!Transfer funds",
"description": "buttonLabel in the transfer funds form.",
"end": {
"column": 3,
"line": 53
"line": 57
},
"file": "source/renderer/app/components/wallet/transfer-funds/TransferFundsStep2Dialog.js",
"id": "wallet.transferFunds.dialog2.label.buttonLabel",
"start": {
"column": 15,
"line": 49
"line": 53
}
},
{
"defaultMessage": "!!!Type your spending password",
"description": "passphraseFieldPlaceholder in the transfer funds form.",
"end": {
"column": 3,
"line": 58
"line": 62
},
"file": "source/renderer/app/components/wallet/transfer-funds/TransferFundsStep2Dialog.js",
"id": "wallet.transferFunds.dialog2.passphraseFieldPlaceholder",
"start": {
"column": 30,
"line": 54
"line": 58
}
},
{
"defaultMessage": "!!!Spending password",
"description": "passphraseLabel in the transfer funds form.",
"end": {
"column": 3,
"line": 63
"line": 67
},
"file": "source/renderer/app/components/wallet/transfer-funds/TransferFundsStep2Dialog.js",
"id": "wallet.transferFunds.dialog2.passphraseLabel",
"start": {
"column": 19,
"line": 59
"line": 63
}
}
],
Expand Down
2 changes: 1 addition & 1 deletion source/renderer/app/i18n/locales/en-US.json
Original file line number Diff line number Diff line change
Expand Up @@ -620,4 +620,4 @@
"wallet.transferFunds.dialog2.passphraseFieldPlaceholder": "Type your spending password",
"wallet.transferFunds.dialog2.passphraseLabel": "Spending password",
"wallet.transferFunds.dialog2.title": "Transfer funds from the legacy wallet"
}
}
1 change: 1 addition & 0 deletions source/renderer/app/i18n/locales/hr-HR.json
Original file line number Diff line number Diff line change
Expand Up @@ -457,6 +457,7 @@
"wallet.legacy.badge.label": "!!!Legacy",
"wallet.legacy.notification.actionLearnMore": "!!!Learn more",
"wallet.legacy.notification.actionMove": "!!!Move all of the ada from this wallet",
"wallet.legacy.notification.addWallet": "!!!Move all of the ada from this wallet",
"wallet.legacy.notification.description": "!!!This is a legacy wallet which uses legacy addresses and does not support new features. Please move all of the ada from this legacy wallet to one of the wallets where new features are available. You can also create a brand new wallet for your ada in case you don’t want to move ada to one of your existing wallets. A sequence of screens will guide you through the process.",
"wallet.legacy.notification.title": "!!!Move funds from the legacy wallet",
"wallet.navigation.more": "!!!More",
Expand Down
2 changes: 1 addition & 1 deletion source/renderer/app/i18n/locales/ja-JP.json
Original file line number Diff line number Diff line change
Expand Up @@ -620,4 +620,4 @@
"wallet.transferFunds.dialog2.passphraseFieldPlaceholder": "送信時パスワードを入力してください",
"wallet.transferFunds.dialog2.passphraseLabel": "送信時パスワード",
"wallet.transferFunds.dialog2.title": "旧ウォレットから資金を移し替える"
}
}
1 change: 1 addition & 0 deletions source/renderer/app/i18n/locales/ko-KR.json
Original file line number Diff line number Diff line change
Expand Up @@ -457,6 +457,7 @@
"wallet.legacy.badge.label": "!!!Legacy",
"wallet.legacy.notification.actionLearnMore": "!!!Learn more",
"wallet.legacy.notification.actionMove": "!!!Move all of the ada from this wallet",
"wallet.legacy.notification.addWallet": "!!!Move all of the ada from this wallet",
"wallet.legacy.notification.description": "!!!This is a legacy wallet which uses legacy addresses and does not support new features. Please move all of the ada from this legacy wallet to one of the wallets where new features are available. You can also create a brand new wallet for your ada in case you don’t want to move ada to one of your existing wallets. A sequence of screens will guide you through the process.",
"wallet.legacy.notification.title": "!!!Move funds from the legacy wallet",
"wallet.navigation.more": "!!!More",
Expand Down
1 change: 1 addition & 0 deletions source/renderer/app/i18n/locales/zh-CN.json
Original file line number Diff line number Diff line change
Expand Up @@ -457,6 +457,7 @@
"wallet.legacy.badge.label": "!!!Legacy",
"wallet.legacy.notification.actionLearnMore": "!!!Learn more",
"wallet.legacy.notification.actionMove": "!!!Move all of the ada from this wallet",
"wallet.legacy.notification.addWallet": "!!!Move all of the ada from this wallet",
"wallet.legacy.notification.description": "!!!This is a legacy wallet which uses legacy addresses and does not support new features. Please move all of the ada from this legacy wallet to one of the wallets where new features are available. You can also create a brand new wallet for your ada in case you don’t want to move ada to one of your existing wallets. A sequence of screens will guide you through the process.",
"wallet.legacy.notification.title": "!!!Move funds from the legacy wallet",
"wallet.navigation.more": "!!!More",
Expand Down

0 comments on commit b32ea79

Please sign in to comment.