feat(settings/profile): add bio and social links to profile view
closes: #6797
This commit is contained in:
parent
7adfb515a9
commit
88ad09f7c2
|
@ -31,6 +31,8 @@ StatusModal {
|
|||
property string userNickname: ""
|
||||
property string userEnsName: ""
|
||||
property string userIcon: ""
|
||||
property string userBio: ""
|
||||
property string userSocialLinks: ""
|
||||
property int userTrustStatus: Constants.trustStatus.unknown
|
||||
property int outgoingVerificationStatus: Constants.verificationStatus.unverified
|
||||
property int incomingVerificationStatus: Constants.verificationStatus.unverified
|
||||
|
@ -73,12 +75,15 @@ StatusModal {
|
|||
function openPopup(publicKey, state = "") {
|
||||
// All this should be improved more, but for now we leave it like this.
|
||||
const contactDetails = Utils.getContactDetailsAsJson(publicKey);
|
||||
|
||||
userPublicKey = publicKey;
|
||||
userDisplayName = contactDetails.displayName;
|
||||
userName = contactDetails.alias;
|
||||
userNickname = contactDetails.localNickname;
|
||||
userEnsName = contactDetails.name;
|
||||
userIcon = contactDetails.largeImage;
|
||||
userBio = contactDetails.bio;
|
||||
userSocialLinks = contactDetails.socialLinks;
|
||||
userIsEnsVerified = contactDetails.ensVerified;
|
||||
userIsBlocked = contactDetails.isBlocked;
|
||||
isAddedContact = contactDetails.isAdded;
|
||||
|
@ -193,12 +198,15 @@ StatusModal {
|
|||
profileStore: popup.profileStore
|
||||
contactsStore: popup.contactsStore
|
||||
|
||||
|
||||
userPublicKey: popup.userPublicKey
|
||||
userDisplayName: popup.userDisplayName
|
||||
userName: popup.userName
|
||||
userNickname: popup.userNickname
|
||||
userEnsName: popup.userEnsName
|
||||
userIcon: popup.userIcon
|
||||
userBio: popup.userBio
|
||||
userSocialLinks: popup.userSocialLinks
|
||||
userIsEnsVerified: popup.userIsEnsVerified
|
||||
userIsBlocked: popup.userIsBlocked
|
||||
isAddedContact: popup.isAddedContact
|
||||
|
|
|
@ -17,6 +17,8 @@ import StatusQ.Components 0.1
|
|||
import StatusQ.Controls 0.1
|
||||
import StatusQ.Popups 0.1
|
||||
|
||||
import "../panels"
|
||||
|
||||
Rectangle {
|
||||
id: root
|
||||
|
||||
|
@ -25,12 +27,15 @@ Rectangle {
|
|||
property var profileStore
|
||||
property var contactsStore
|
||||
|
||||
|
||||
property string userPublicKey: profileStore.pubkey
|
||||
property string userDisplayName: profileStore.displayName
|
||||
property string userName: profileStore.username
|
||||
property string userNickname: profileStore.details.localNickname
|
||||
property string userEnsName: profileStore.ensName
|
||||
property string userIcon: profileStore.profileLargeImage
|
||||
property string userBio: profileStore.bio
|
||||
property string userSocialLinks: profileStore.socialLinksJson
|
||||
property string text: ""
|
||||
|
||||
property bool userIsEnsVerified: profileStore.details.ensVerified
|
||||
|
@ -190,6 +195,15 @@ Rectangle {
|
|||
statusText: qsTr("Blocked")
|
||||
}
|
||||
|
||||
ProfileBioSocialsPanel {
|
||||
Layout.fillWidth: true
|
||||
Layout.leftMargin: 16
|
||||
Layout.rightMargin: 16
|
||||
|
||||
bio: root.userBio
|
||||
userSocialLinksJson: root.userSocialLinks
|
||||
}
|
||||
|
||||
StatusDescriptionListItem {
|
||||
Layout.fillWidth: true
|
||||
visible: !showVerifyIdentitySection && !showVerificationPendingSection && !showIdentityVerified
|
||||
|
|
Loading…
Reference in New Issue