fix: typos and switch statement string literals

remove console log

fix last typo
This commit is contained in:
rinzlxr 2021-03-25 04:17:33 +02:00 committed by Iuri Matias
parent 7c4bae5240
commit 0abaa61067
2 changed files with 10 additions and 21 deletions

View File

@ -72,21 +72,10 @@ Item {
width: 624
anchors.horizontalCenter: parent.horizontalCenter
StyledText {
id: sectionTitle
text: ""
anchors.left: parent.left
anchors.leftMargin: Style.current.bigPadding
anchors.top: parent.top
anchors.topMargin: Style.current.bigPadding
font.weight: Font.Bold
font.pixelSize: 20
}
Rectangle {
id: circleAt
anchors.top: sectionTitle.bottom
anchors.topMargin: Style.current.bigPadding
anchors.top: parent.top
anchors.topMargin: Style.current.bigPadding*2
anchors.horizontalCenter: parent.horizontalCenter
width: 60
height: 60
@ -143,17 +132,17 @@ Item {
loading = false;
ensStatus = ensResult;
switch(ensResult){
case Constants.ens_available:
case Constants.ens_owned:
case Constants.ens_connected:
case Constants.ens_connected_dkey:
case "available":
case "owned":
case "connected":
case "connected-different-key":
valid = true;
validationMessage = Constants.ensState[ensResult]
break;
case Constants.ens_taken:
validationMessage = !isStatus ? Constants.ensState['taken_custom'] : Constants.ensState['taken'];
case "taken":
validationMessage = Constants.ensState[!isStatus ? 'taken-custom' : 'taken']
break;
case Constants.already_connected:
case "already-connected":
validationMessage = Constants.ensState[ensResult]
break;
}

View File

@ -144,7 +144,7 @@ QtObject {
//% "Continuing will connect this username with your chat key."
"owned": qsTrId("ens-username-owned-continue"),
//% " Username available!"
"availabe": qsTrId("ens-username-available"),
"available": qsTrId("ens-username-available"),
//% "Username is already connected with your chat key and can be used inside Status."
"already-connected": qsTrId("ens-username-already-added"),
//% "This user name is owned by you and connected with your chat key. Continue to set `Show my ENS username in chats`."