Replace send token dropdown with static display when token is locked
All checks were successful
check / check (push) Successful in 17s
All checks were successful
check / check (push) Successful in 17s
When sending from the address-token view, show the token symbol as plain text instead of a disabled dropdown. ERC-20 tokens include an etherscan link to the contract address. The dropdown is restored when navigating back or entering send from other views.
This commit is contained in:
@@ -338,7 +338,15 @@ function init(ctx) {
|
||||
} else {
|
||||
$("send-token").value = tokenId;
|
||||
}
|
||||
$("send-token").disabled = true;
|
||||
// Hide dropdown, show static token display
|
||||
$("send-token").classList.add("hidden");
|
||||
let staticHtml = escapeHtml(currentSymbol);
|
||||
if (tokenId !== "ETH") {
|
||||
const link = `https://etherscan.io/token/${tokenId}`;
|
||||
staticHtml += ` <a href="${link}" target="_blank" rel="noopener" class="inline-flex items-center">${EXT_ICON}</a>`;
|
||||
}
|
||||
$("send-token-static").innerHTML = staticHtml;
|
||||
$("send-token-static").classList.remove("hidden");
|
||||
updateSendBalance();
|
||||
showView("send");
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user