Skip to content

Commit e187dc5

Browse files
authored
chore: change send transaction popup title/button (#1672)
- Closes FE-970
1 parent 12b92b5 commit e187dc5

File tree

8 files changed

+20
-15
lines changed

8 files changed

+20
-15
lines changed

.changeset/sour-emus-train.md

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"fuels-wallet": patch
3+
---
4+
5+
chore: change title/button text of Approve transaction screen

.github/workflows/pr.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ jobs:
4545
fetch-depth: 0
4646

4747
- name: CI Setup
48-
uses: FuelLabs/github-actions/setups/node@master
48+
uses: FuelLabs/github-actions/setups/node@58bcd91d7246e40938e1971be0b0fe35b253dff0
4949
with:
5050
node-version: 20.11.0
5151
pnpm-version: 9.5.0

packages/app/playwright/crx/crx.test.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -704,7 +704,7 @@ test.describe('FuelWallet Extension', () => {
704704
);
705705

706706
await hasAriaLabel(approveTransactionPage, 'Confirm Transaction');
707-
await getButtonByText(approveTransactionPage, /Approve/i).click();
707+
await getButtonByText(approveTransactionPage, /Submit/i).click();
708708

709709
await expect(transferStatus).resolves.toBe('success');
710710
const balance = await receiverWallet.getBalance();

packages/app/playwright/e2e/SendTransaction.test.ts

+9-9
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ test.describe('SendTransaction', () => {
6464
await expectButtonToBeEnabled(btnLocator);
6565
await btnLocator.click();
6666

67-
await getButtonByText(page, 'Approve').click();
67+
await getButtonByText(page, 'Submit').click();
6868
await hasText(page, '0.001 ETH');
6969

7070
// Wait for transaction to be confirmed
@@ -102,7 +102,7 @@ test.describe('SendTransaction', () => {
102102

103103
// Approve transaction
104104
await hasText(page, '0.001 ETH');
105-
await getButtonByText(page, 'Approve').click();
105+
await getButtonByText(page, 'Submit').click();
106106

107107
// Wait for transaction to be confirmed
108108
await hasText(page, 'success');
@@ -147,7 +147,7 @@ test.describe('SendTransaction', () => {
147147

148148
// Approve transaction
149149
await hasText(page, `0.01 ${ALT_ASSET.symbol}`);
150-
await getButtonByText(page, 'Approve').click();
150+
await getButtonByText(page, 'Submit').click();
151151

152152
// Wait for transaction to be confirmed
153153
await hasText(page, 'success');
@@ -184,7 +184,7 @@ test.describe('SendTransaction', () => {
184184

185185
await hasText(page, '0.001 ETH');
186186

187-
await getButtonByText(page, 'Approve').click();
187+
await getButtonByText(page, 'Submit').click();
188188
await hasText(page, '0.001 ETH');
189189

190190
// Wait for transaction to be confirmed
@@ -226,7 +226,7 @@ test.describe('SendTransaction', () => {
226226

227227
await hasText(page, '0.001 ETH');
228228

229-
await getButtonByText(page, 'Approve').click();
229+
await getButtonByText(page, 'Submit').click();
230230
await hasText(page, '0.001 ETH');
231231

232232
// Wait for transaction to be confirmed
@@ -271,7 +271,7 @@ test.describe('SendTransaction', () => {
271271
await btnLocatorBeforeApprv.click();
272272

273273
// Waiting button change to Approve in order to get updated fee amount
274-
await page.waitForSelector('button:has-text("Approve")');
274+
await page.waitForSelector('button:has-text("Submit")');
275275
await page.waitForTimeout(1000);
276276

277277
// Going back to select other fee value
@@ -293,13 +293,13 @@ test.describe('SendTransaction', () => {
293293
await btnLocator.click();
294294

295295
// Waiting button change to Approve in order to get updated fee amount
296-
await page.waitForSelector('button:has-text("Approve")');
296+
await page.waitForSelector('button:has-text("Submit")');
297297
await page.waitForTimeout(1000);
298298

299299
await hasText(page, '0.001 ETH');
300300

301301
await page.waitForTimeout(1000);
302-
await getButtonByText(page, 'Approve').click();
302+
await getButtonByText(page, 'Submit').click();
303303
await hasText(page, '0.001 ETH');
304304

305305
// Wait for transaction to be confirmed
@@ -350,7 +350,7 @@ test.describe('SendTransaction', () => {
350350

351351
// Approve transaction
352352
await hasText(page, `${maxAmountAfterFee} ETH`);
353-
await getButtonByText(page, 'Approve').click();
353+
await getButtonByText(page, 'Submit').click();
354354
await hasText(page, `${maxAmountAfterFee} ETH`);
355355

356356
// Wait for transaction to be confirmed

packages/app/src/systems/DApp/hooks/useTransactionRequest.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ const selectors = {
5757
if (state.matches('txSuccess')) return 'Transaction sent';
5858
if (state.matches('txFailed')) return 'Transaction failed';
5959
if (state.matches('sendingTx')) return 'Sending transaction';
60-
return 'Approve Transaction';
60+
return 'Review Transaction';
6161
},
6262
origin: (state: TransactionRequestState) => state.context.input.origin,
6363
originTitle: (state: TransactionRequestState) => state.context.input.title,

packages/app/src/systems/DApp/pages/TransactionRequest/TransactionRequest.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@ export function TransactionRequest() {
130130
isLoading={isLoading || status('sending')}
131131
isDisabled={shouldDisableApproveBtn}
132132
>
133-
Approve
133+
Submit
134134
</Button>
135135
</Layout.BottomBar>
136136
)}

packages/app/src/systems/Transaction/pages/TxApprove/TxApprove.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ export const TxApprove = () => {
7575
isDisabled={ctx.shouldDisableApproveBtn}
7676
onPress={ctx.handlers.approve}
7777
>
78-
Approve
78+
Submit
7979
</Button>
8080
</>
8181
)}

packages/playwright-utils/src/playwright-utils/fuelWalletTestHelper.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ export class FuelWalletTestHelper {
129129
async walletApprove() {
130130
const walletPage = await this.getWalletPopupPage();
131131

132-
const approveButton = getButtonByText(walletPage, 'Approve');
132+
const approveButton = getButtonByText(walletPage, 'Submit');
133133
await approveButton.click();
134134
}
135135

0 commit comments

Comments
 (0)