Skip to content

Commit 3966bb1

Browse files
authored
feat(bridge-ui): remove fee padding (#18546)
1 parent 0ef7fd6 commit 3966bb1

File tree

5 files changed

+97
-613
lines changed

5 files changed

+97
-613
lines changed

packages/bridge-ui/src/components/Transactions/Dialogs/DesktopDetailsDialog.svelte

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -227,7 +227,7 @@
227227
</span>
228228

229229
<span class="font-bold text-positive-sentiment">Waiting for transaction to be processed</span>
230-
<span class="text-secondary-content">Depending on your direction, this can take up to 24hs</span>
230+
<span class="text-secondary-content">Depending on your direction, this can take up to 4hs</span>
231231
</div>
232232

233233
<div class="f-col">

packages/bridge-ui/src/components/Transactions/Rows/FungibleTransactionRow.svelte

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@
103103
: mobileContainerClasses;
104104
105105
$: commonColumnClasses = classNames(' relative items-end');
106-
$: desktopColumnClasses = classNames(commonColumnClasses, 'w-1/6 f-row justify-center items-center');
106+
$: desktopColumnClasses = classNames(commonColumnClasses, 'w-1/6 f-row justify-center md:justify-start items-center');
107107
$: tabletColumnClasses = classNames(
108108
commonColumnClasses,
109109
'w-1/4 f-row text-left start items-center text-sm space-y-[10px]',

packages/bridge-ui/src/i18n/en.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@
4040
},
4141
"alerts": {
4242
"not_enough_funds": "You do not have enough ETH to cover the processing fee and transaction fee. Please add more ETH to your wallet (>= 0.0015 ETH).",
43-
"slow_bridging": "Please note: Bridging to L1 will take around 24hrs!",
43+
"slow_bridging": "Please note: Bridging to L1 will take around 4hs!",
4444
"smart_contract_wallet": "It seems you are using a smart contract wallet. Please double check that the recipient matches your wallet on the destination or change it accordingly.",
4545
"wrapped_eth": "You are bridging wrapped ETH. Please be aware that un-wrapping will only work on the original chain of the token, <span class=\"font-bold\">NOT</span> on the destination."
4646
},

packages/bridge-ui/src/libs/fee/recommendProcessingFee.ts

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -94,20 +94,20 @@ export async function recommendProcessingFee({
9494
if (!estimatedMsgGaslimit) throw new Error('Unable to calculate fee');
9595

9696
// Initial fee multiplicator and add fallback
97-
let feeMultiplicator: number = parseInt(PUBLIC_FEE_MULTIPLIER);
98-
99-
if (gasPrice <= parseGwei('0.05')) {
100-
feeMultiplicator = 4;
101-
log(`gasPrice {formatGwei(gasPrice)} is less than 0.5 gwei, setting feeMultiplicator to 4`);
102-
} else if (gasPrice <= parseGwei('0.1') && gasPrice > parseGwei('0.05')) {
103-
feeMultiplicator = 3;
104-
log(
105-
`gasPrice ${formatGwei(gasPrice)} is less than 0.1 gwei and more than 0.05 gwei, setting feeMultiplicator to 3`,
106-
);
107-
} else {
108-
feeMultiplicator = 2;
109-
log(`gasPrice ${formatGwei(gasPrice)} is more than 0.1 gwei, setting feeMultiplicator to 2`);
110-
}
97+
const feeMultiplicator: number = parseInt(PUBLIC_FEE_MULTIPLIER) || 1;
98+
99+
// if (gasPrice <= parseGwei('0.05')) {
100+
// feeMultiplicator = 4;
101+
// log(`gasPrice {formatGwei(gasPrice)} is less than 0.5 gwei, setting feeMultiplicator to 4`);
102+
// } else if (gasPrice <= parseGwei('0.1') && gasPrice > parseGwei('0.05')) {
103+
// feeMultiplicator = 3;
104+
// log(
105+
// `gasPrice ${formatGwei(gasPrice)} is less than 0.1 gwei and more than 0.05 gwei, setting feeMultiplicator to 3`,
106+
// );
107+
// } else {
108+
// feeMultiplicator = 2;
109+
// log(`gasPrice ${formatGwei(gasPrice)} is more than 0.1 gwei, setting feeMultiplicator to 2`);
110+
// }
111111

112112
const fee = estimatedMsgGaslimit * Number(gasPrice) * feeMultiplicator;
113113
return BigInt(fee);

0 commit comments

Comments
 (0)