Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: fix wallet setup kick-off automatically in the Reset Wallet flow #863

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/apps/popup/pages/stakes/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -414,8 +414,8 @@ export const StakesPage = () => {
{stakeStep === StakeSteps.Confirm
? getConfirmButtonText()
: stakeStep === StakeSteps.Success
? 'Done'
: 'Next'}
? 'Done'
: 'Next'}
</Trans>
</Button>
</FooterButtonsContainer>
Expand Down
4 changes: 2 additions & 2 deletions src/apps/popup/pages/transfer/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -437,8 +437,8 @@ export const TransferPage = () => {
{transferStep === TransactionSteps.Confirm
? 'Send'
: transferStep === TransactionSteps.Success
? 'Done'
: 'Next'}
? 'Done'
: 'Next'}
</Trans>
</Button>
</FooterButtonsContainer>
Expand Down
7 changes: 6 additions & 1 deletion src/background/close-window-by-reload-extension.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import browser from 'webextension-polyfill';

import { isSafariBuild } from '@src/utils';
import { isFirefoxBuild, isSafariBuild } from '@src/utils';

// It's hacky for Safari browser => browser.runtime.reload();
// window.close() method can only be called on windows that were opened by a script using the Window.open() method.
Expand All @@ -9,6 +9,11 @@ import { isSafariBuild } from '@src/utils';
// WARNING: IT WILL RELOAD ENTIRE EXTENSION
export function closeWindowByReloadExtension() {
if (isSafariBuild) {
browser.tabs.create({ url: 'onboarding.html', active: true });
browser.runtime.reload();
return;
}
if (isFirefoxBuild) {
browser.runtime.reload();
return;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,8 @@ export const useMapAccountDeploysListWithPendingTransactions = (
accountDeploys != null
? [...filteredTransactions, ...accountDeploys]
: mappedPendingTransactions.length > 0
? mappedPendingTransactions
: null;
? mappedPendingTransactions
: null;

return {
accountDeploysListWithPendingTransactions
Expand Down
4 changes: 2 additions & 2 deletions src/libs/ui/components/avatar/avatar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,8 @@ export const Avatar = ({
? 'assets/icons/connected-dark.svg'
: 'assets/icons/connected-dark-big.svg'
: displayContext === 'header'
? 'assets/icons/connected-light.svg'
: 'assets/icons/connected-light-big.svg';
? 'assets/icons/connected-light.svg'
: 'assets/icons/connected-light-big.svg';

if (withConnectedStatus && isConnected !== undefined) {
return (
Expand Down
4 changes: 2 additions & 2 deletions src/libs/ui/components/checkbox/checkbox.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,8 @@ export function Checkbox({
? 'assets/icons/checkbox-square-checked.svg'
: 'assets/icons/checkbox-square.svg'
: checked
? 'assets/icons/checkbox-checked.svg'
: 'assets/icons/checkbox.svg';
? 'assets/icons/checkbox-checked.svg'
: 'assets/icons/checkbox.svg';

return (
<StyledFlexRow
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@ const ConnectionStatusBadgeContainer = styled(
displayContext === 'accountList'
? null
: isConnected
? hexToRGBA(theme.color.contentPositive, '.12')
: theme.color.backgroundSecondary};
? hexToRGBA(theme.color.contentPositive, '.12')
: theme.color.backgroundSecondary};
`;

export function ConnectionStatusBadge({
Expand Down
4 changes: 2 additions & 2 deletions src/libs/ui/components/secret-phrase-words-view/word-tag.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ const WordContainer = styled(FlexRow)<DisabledOrSelected & IsEmptyWord>`
disabled
? theme.color.contentSecondary
: selected
? theme.color.contentOnFill
: 'inherit'};
? theme.color.contentOnFill
: 'inherit'};
border-radius: 6px;
cursor: ${({ onClick, disabled }) =>
onClick && !disabled ? 'pointer' : 'auto'};
Expand Down
1 change: 1 addition & 0 deletions src/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ export const getUrlOrigin = (url: string | undefined) => {
};

export const isSafariBuild = process.env.BROWSER === Browser.Safari;
export const isFirefoxBuild = process.env.BROWSER === Browser.Firefox;

export const isValidU64 = (value?: string): boolean => {
if (!value) {
Expand Down
Loading