Browse Source

comments of the PR were taken into account as well as a few small changes in the recoverykey recover dialog

Jan-Peter Klein 2 years ago
parent
commit
ea6318dfc4

+ 2 - 2
src/main/java/org/cryptomator/ui/recoverykey/RecoveryKeyResetPasswordController.java

@@ -49,8 +49,8 @@ public class RecoveryKeyResetPasswordController implements FxController {
 	}
 
 	@FXML
-	public void back() {
-		window.setScene(recoverScene.get());
+	public void close() {
+		window.close();
 	}
 
 	@FXML

+ 1 - 1
src/main/resources/fxml/recoverykey_recover.fxml

@@ -35,7 +35,7 @@
 		<Region VBox.vgrow="ALWAYS"/>
 
 		<VBox alignment="BOTTOM_CENTER" VBox.vgrow="ALWAYS">
-			<ButtonBar buttonMinWidth="120" buttonOrder="C+X">
+			<ButtonBar buttonMinWidth="120" buttonOrder="+CX">
 				<buttons>
 					<Button text="%generic.button.cancel" ButtonBar.buttonData="CANCEL_CLOSE" cancelButton="true" onAction="#close"/>
 					<Button text="%generic.button.next" ButtonBar.buttonData="NEXT_FORWARD" defaultButton="true" onAction="#recover" disable="${!controller.validRecoveryKey}"/>

+ 3 - 3
src/main/resources/fxml/recoverykey_reset_password.fxml

@@ -22,10 +22,10 @@
 		<Region VBox.vgrow="ALWAYS"/>
 
 		<VBox alignment="BOTTOM_CENTER" VBox.vgrow="ALWAYS">
-			<ButtonBar buttonMinWidth="120" buttonOrder="B+I">
+			<ButtonBar buttonMinWidth="120" buttonOrder="+BI">
 				<buttons>
-					<Button text="%generic.button.back" ButtonBar.buttonData="BACK_PREVIOUS" cancelButton="true" onAction="#back"/>
-					<Button text="%generic.button.done" ButtonBar.buttonData="FINISH" defaultButton="true" onAction="#done" disable="${!controller.validPassword}"/>
+					<Button text="%generic.button.cancel" ButtonBar.buttonData="BACK_PREVIOUS" cancelButton="true" onAction="#close"/>
+					<Button text="%generic.button.reset" ButtonBar.buttonData="FINISH" defaultButton="true" onAction="#done" disable="${!controller.validPassword}"/>
 				</buttons>
 			</ButtonBar>
 		</VBox>

+ 3 - 3
src/main/resources/fxml/recoverykey_reset_password_success.fxml

@@ -34,18 +34,18 @@
 	</Group>
 
 	<VBox HBox.hgrow="ALWAYS">
-		<Label styleClass="label-large" text="%passwordReset.success.message" wrapText="true" textAlignment="LEFT">
+		<Label styleClass="label-large" text="%recoveryKey.recover.resetSuccess.message" wrapText="true" textAlignment="LEFT">
 			<padding>
 				<Insets bottom="6" top="6"/>
 			</padding>
 		</Label>
 
-		<Label text="%passwordReset.success.description" wrapText="true" textAlignment="LEFT"/>
+		<Label text="%recoveryKey.recover.resetSuccess.description" wrapText="true" textAlignment="LEFT"/>
 
 		<Region VBox.vgrow="ALWAYS" minHeight="18"/>
 		<ButtonBar buttonMinWidth="120" buttonOrder="+C">
 			<buttons>
-				<Button text="%generic.button.done" ButtonBar.buttonData="CANCEL_CLOSE" defaultButton="true" cancelButton="true" onAction="#close"/>
+				<Button text="%generic.button.close" ButtonBar.buttonData="CANCEL_CLOSE" defaultButton="true" cancelButton="true" onAction="#close"/>
 			</buttons>
 		</ButtonBar>
 	</VBox>

+ 1 - 1
src/main/resources/fxml/recoverykey_success.fxml

@@ -24,7 +24,7 @@
 		<VBox alignment="BOTTOM_CENTER" VBox.vgrow="ALWAYS">
 			<ButtonBar buttonMinWidth="120" buttonOrder="+C">
 				<buttons>
-					<Button text="%generic.button.done" ButtonBar.buttonData="CANCEL_CLOSE" cancelButton="true" onAction="#close"/>
+					<Button text="%generic.button.close" ButtonBar.buttonData="CANCEL_CLOSE" cancelButton="true" onAction="#close"/>
 				</buttons>
 			</ButtonBar>
 		</VBox>

+ 7 - 6
src/main/resources/i18n/strings.properties

@@ -14,6 +14,7 @@ generic.button.copied=Copied!
 generic.button.done=Done
 generic.button.next=Next
 generic.button.print=Print
+generic.button.reset=Reset
 
 # Error
 error.message=An error occurred
@@ -360,7 +361,7 @@ vaultOptions.masterkey.changePasswordBtn=Change Password
 vaultOptions.masterkey.forgetSavedPasswordBtn=Forget Saved Password
 vaultOptions.masterkey.recoveryKeyExplanation=A recovery key is your only means to restore access to a vault if you lose your password.
 vaultOptions.masterkey.showRecoveryKeyBtn=Display Recovery Key
-vaultOptions.masterkey.recoverPasswordBtn=Recover Password
+vaultOptions.masterkey.recoverPasswordBtn=Reset Password
 
 
 # Recovery Key
@@ -370,11 +371,14 @@ recoveryKey.create.message=Password required
 recoveryKey.create.description=Enter the password for "%s" to show its recovery key.
 recoveryKey.display.description=The following recovery key can be used to restore access to "%s":
 recoveryKey.display.StorageHints=Keep it somewhere very secure, e.g.:\n • Store it using a password manager\n • Save it on a USB flash drive\n • Print it on paper
-## Recover Vault
-recoveryKey.recover.title=Recover Vault
+## Reset Password
+recoveryKey.recover.title=Reset Password
 recoveryKey.recover.prompt=Enter your recovery key for "%s":
 recoveryKey.recover.validKey=This is a valid recovery key
 recoveryKey.printout.heading=Cryptomator Recovery Key\n"%s"\n
+### Recovery Key Password Reset Success
+recoveryKey.recover.resetSuccess.message=Password reset successful
+recoveryKey.recover.resetSuccess.description=You can unlock your vault with the new password.
 
 # New Password
 newPassword.promptText=Enter a new password
@@ -388,9 +392,6 @@ passwordStrength.messageLabel.2=Fair
 passwordStrength.messageLabel.3=Strong
 passwordStrength.messageLabel.4=Very strong
 
-#Recovery Key Password Reset Success
-passwordReset.success.message=Password reset done
-passwordReset.success.description=Your password has been successfully reset.
 
 # Quit
 quit.title=Quit Application