4
1
mirror of https://github.com/Qortal/qortal-ui.git synced 2025-02-14 11:15:50 +00:00

added wallet fields

This commit is contained in:
PhilReact 2023-10-26 02:03:29 +03:00
parent ed5253d6d0
commit ce3129ae7e
2 changed files with 82 additions and 52 deletions

View File

@ -1218,6 +1218,7 @@
"profile2": "Go to name registration",
"profile3": "Update profile",
"profile4": "Tagline",
"profile5": "Bio"
"profile5": "Bio",
"profile6": "Wallet Addresses"
}
}

View File

@ -23,8 +23,9 @@ class ProfileModalUpdate extends connect(store)(LitElement) {
onSubmit: { attribute: false },
editContent: { type: Object },
onClose: { attribute: false },
tagline: {type: String},
bio: {type: String}
tagline: { type: String },
bio: { type: String },
wallets: { type: Array },
};
}
@ -34,11 +35,21 @@ class ProfileModalUpdate extends connect(store)(LitElement) {
this.isLoading = false;
this.nodeUrl = this.getNodeUrl();
this.myNode = this.getMyNode();
this.tagline = "";
this.bio = "",
this.walletList = [
"btcWallet", "ltcWallet", "dogeWallet","dgbWallet", "rvnWallet", "arrrWallet"
]
this.tagline = '';
(this.bio = ''),
(this.walletList = [
'btc_Address',
'ltc_Address',
'doge_Address',
'dgb_Address',
'rvn_Address',
'arrr_Address',
]);
let wallets = {};
this.walletList.forEach((item) => {
wallets[item] = '';
});
this.wallets = wallets;
}
static get styles() {
@ -234,7 +245,7 @@ class ProfileModalUpdate extends connect(store)(LitElement) {
<textarea
class="input"
@change=${(e) => {
this.tagline = e.target.value
this.tagline = e.target.value;
}}
.value=${this.tagline}
?disabled=${this.isLoading}
@ -242,7 +253,6 @@ class ProfileModalUpdate extends connect(store)(LitElement) {
placeholder="${translate('profile.profile4')}"
rows="3"
></textarea>
</div>
<div style="height:15px"></div>
<div style="display: flex;flex-direction: column;">
@ -256,7 +266,7 @@ class ProfileModalUpdate extends connect(store)(LitElement) {
<textarea
class="input"
@change=${(e) => {
this.bio = e.target.value
this.bio = e.target.value;
}}
.value=${this.bio}
?disabled=${this.isLoading}
@ -264,7 +274,26 @@ class ProfileModalUpdate extends connect(store)(LitElement) {
placeholder="${translate('profile.profile5')}"
rows="3"
></textarea>
</div>
<div style="height:15px"></div>
<p>${get('profile.profile6')}</p>
<div style="display: flex;flex-direction: column;">
${Object.keys(this.wallets).map((key) => {
return html`
<input
id=${key}
placeholder=${key}
class="input"
.value=${this.wallets[key]}
@change=${(e) => {
this.wallets = {
...this.wallets,
[key]: e.target.value,
};
}}
/>
`;
})}
</div>
</div>
<div