Refactor private key input message
This commit is contained in:
parent
7c1e70c50d
commit
a29077ece1
16
index.html
16
index.html
@ -221,9 +221,7 @@
|
|||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
<small class="form-text">
|
<small class="form-text">
|
||||||
Enter a private key in WIF format for any supported blockchain
|
Enter a private key (DOGE, BTC, FLO, LTC).
|
||||||
(DOGE, BTC, FLO, LTC). All equivalent blockchain addresses will
|
|
||||||
be recovered.
|
|
||||||
</small>
|
</small>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@ -1141,7 +1139,6 @@
|
|||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
function translateAddress() {
|
function translateAddress() {
|
||||||
const wif = document.getElementById("translateWIF").value.trim();
|
const wif = document.getElementById("translateWIF").value.trim();
|
||||||
if (!wif) {
|
if (!wif) {
|
||||||
@ -1177,11 +1174,15 @@
|
|||||||
|
|
||||||
for (const chain of ["DOGE", "FLO", "BTC", "LTC"]) {
|
for (const chain of ["DOGE", "FLO", "BTC", "LTC"]) {
|
||||||
if (result[chain]) {
|
if (result[chain]) {
|
||||||
|
|
||||||
|
const badgeClass = chain === "DOGE" ? "PRIMARY" : "SECONDARY";
|
||||||
|
const badgeStyle = chain === "DOGE" ? "primary" : "secondary";
|
||||||
|
|
||||||
formattedResult += `
|
formattedResult += `
|
||||||
<div class="blockchain-section">
|
<div class="blockchain-section">
|
||||||
<div class="blockchain-header">
|
<div class="blockchain-header">
|
||||||
<h4><i class="fas fa-coins"></i> ${chain}</h4>
|
<h4><i class="fas fa-coins"></i> ${chain}</h4>
|
||||||
<div class="blockchain-badge">PRIMARY</div>
|
<div class="blockchain-badge ${badgeStyle}">${badgeClass}</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="detail-row">
|
<div class="detail-row">
|
||||||
<label><i class="fas fa-map-marker-alt"></i> ${chain} Address</label>
|
<label><i class="fas fa-map-marker-alt"></i> ${chain} Address</label>
|
||||||
@ -1205,9 +1206,7 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
document.getElementById("translateResult").innerHTML =
|
document.getElementById("translateResult").innerHTML = formattedResult;
|
||||||
formattedResult;
|
|
||||||
|
|
||||||
storedTranslateResults.recoverTranslate = formattedResult;
|
storedTranslateResults.recoverTranslate = formattedResult;
|
||||||
notify("Addresses recovered successfully!", "success");
|
notify("Addresses recovered successfully!", "success");
|
||||||
} catch (err) {
|
} catch (err) {
|
||||||
@ -1237,7 +1236,6 @@
|
|||||||
setButtonLoading("recoverBtn", false);
|
setButtonLoading("recoverBtn", false);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function translateDirectAddress() {
|
function translateDirectAddress() {
|
||||||
const address = document
|
const address = document
|
||||||
.getElementById("addressToTranslate")
|
.getElementById("addressToTranslate")
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user