diff --git a/apps/web/cypress/e2e/pages/main.page.js b/apps/web/cypress/e2e/pages/main.page.js index 229e7e963d..5a770954af 100644 --- a/apps/web/cypress/e2e/pages/main.page.js +++ b/apps/web/cypress/e2e/pages/main.page.js @@ -4,6 +4,8 @@ const acceptSelection = 'Save settings' const executeStr = 'Execute' const connectedOwnerBlock = '[data-testid="open-account-center"]' export const modalDialogCloseBtn = '[data-testid="modal-dialog-close-btn"]' +const closeOutreachPopupBtn = 'button[aria-label="close outreach popup"]' + export const noRelayAttemptsError = 'Not enough relay attempts remaining' export function checkElementBackgroundColor(element, color) { @@ -204,6 +206,16 @@ export function acceptCookies2() { }) } +export function closeOutreachPopup() { + cy.wait(1000) + cy.get('body').then(($body) => { + if ($body.find(closeOutreachPopupBtn).length > 0) { + cy.get(closeOutreachPopupBtn).click() + cy.wait(500) + } + }) +} + export function verifyOwnerConnected(prefix = 'sep:') { cy.get(connectedOwnerBlock).should('contain', prefix) } diff --git a/apps/web/cypress/support/utils/wallet.js b/apps/web/cypress/support/utils/wallet.js index 93673c2164..9a75493d36 100644 --- a/apps/web/cypress/support/utils/wallet.js +++ b/apps/web/cypress/support/utils/wallet.js @@ -1,3 +1,5 @@ +import * as main from '../../e2e/pages/main.page' + const onboardv2 = 'onboard-v2' const pkInput = '[data-testid="private-key-input"]' const pkConnectBtn = '[data-testid="pk-connect-btn"]' @@ -42,7 +44,7 @@ export function connectSigner(signer) { function enterPrivateKey() { cy.wait(3000) - cy.get('body').then(($body) => { + return cy.get('body').then(($body) => { if ($body.find(pkInput).length > 0) { cy.get(pkInput) .find('input') @@ -65,5 +67,7 @@ export function connectSigner(signer) { }) } - enterPrivateKey() + enterPrivateKey().then(() => { + main.closeOutreachPopup() + }) } diff --git a/apps/web/src/components/common/TokenIcon/index.tsx b/apps/web/src/components/common/TokenIcon/index.tsx index 3df24157ed..232c08e245 100644 --- a/apps/web/src/components/common/TokenIcon/index.tsx +++ b/apps/web/src/components/common/TokenIcon/index.tsx @@ -19,7 +19,7 @@ const TokenIcon = ({ }): ReactElement => { const src = useMemo(() => { return logoUri?.replace(COINGECKO_THUMB, COINGECKO_SMALL) - }, []) + }, [logoUri]) return ( { > {options?.map((owner) => ( - + {!isOptionEnabled(owner) && ( Already signed diff --git a/apps/web/src/features/targetedOutreach/components/OutreachPopup/OutreachPopup.tsx b/apps/web/src/features/targetedOutreach/components/OutreachPopup/OutreachPopup.tsx index 929e2637b7..3fe0a5f440 100644 --- a/apps/web/src/features/targetedOutreach/components/OutreachPopup/OutreachPopup.tsx +++ b/apps/web/src/features/targetedOutreach/components/OutreachPopup/OutreachPopup.tsx @@ -124,7 +124,7 @@ const OutreachPopup = (): ReactElement | null => { - +