restore checkbox and other small ui rearrangements

This commit is contained in:
Jan-Peter Klein
2025-03-17 16:10:16 +01:00
parent a3b8297e23
commit 6231c5b8b3
4 changed files with 44 additions and 27 deletions
@@ -7,26 +7,29 @@
<?import javafx.scene.image.ImageView?>
<?import javafx.scene.layout.Region?>
<?import javafx.scene.layout.VBox?>
<?import javafx.scene.control.CheckBox?>
<VBox xmlns:fx="http://javafx.com/fxml"
xmlns="http://javafx.com/javafx"
fx:controller="org.cryptomator.ui.addvaultwizard.ChooseExistingVaultController"
prefWidth="450"
prefHeight="480"
spacing="24"
alignment="CENTER">
prefHeight="480">
<padding>
<Insets topRightBottomLeft="24"/>
</padding>
<children>
<ImageView VBox.vgrow="ALWAYS" fitWidth="400" preserveRatio="true" smooth="true" image="${controller.screenshot}"/>
<Label text="%addvaultwizard.existing.instruction" wrapText="true"/>
<Label text="%addvaultwizard.existing.instruction" wrapText="true">
<padding>
<Insets bottom="6" top="6"/>
</padding>
</Label>
<CheckBox fx:id="restoreCheckBox" text="%addvaultwizard.existing.instruction.restore" wrapText="true"/>
<Region VBox.vgrow="ALWAYS"/>
<ButtonBar buttonMinWidth="120" buttonOrder="+CX">
<buttons>
<Button text="%addvaultwizard.existing.restore" ButtonBar.buttonData="NEXT_FORWARD" onAction="#restoreVaultConfigWithRecoveryKey" />
<Button text="%addvaultwizard.existing.restore" ButtonBar.buttonData="NEXT_FORWARD" onAction="#restoreVaultConfigWithRecoveryKey" visible="${controller.restoreButtonVisible}" />
<Button text="%addvaultwizard.existing.chooseBtn" ButtonBar.buttonData="NEXT_FORWARD" onAction="#chooseFileAndNext" defaultButton="true"/>
</buttons>
</ButtonBar>
@@ -16,7 +16,7 @@
fx:controller="org.cryptomator.ui.recoverykey.RecoveryKeyIsHubVaultController"
minWidth="400"
maxWidth="400"
minHeight="145"
minHeight="204"
spacing="12"
alignment="TOP_CENTER">
<padding>
@@ -34,19 +34,22 @@
</Group>
<VBox HBox.hgrow="ALWAYS">
<Label styleClass="label-large" text="Hub Vault or not?" wrapText="true">
<Label styleClass="label-large" text="%recoveryKey.recover.onBoarding.title" wrapText="true">
<padding>
<Insets bottom="6" top="6"/>
</padding>
</Label>
<Label text="%recoveryKey.recover.onBoarding.message" wrapText="true"/>
<Label text="%recoveryKey.recover.onBoarding.description" wrapText="true">
<padding>
<Insets bottom="6" top="6"/>
</padding>
</Label>
<Label text="If your Vault is an Hub Vault you can restore the vault config .... Otherwise you need the recovery key of the vault to restore the config files." wrapText="true"/>
<Region VBox.vgrow="ALWAYS" minHeight="18"/>
<ButtonBar buttonMinWidth="120" buttonOrder="+C">
<buttons>
<Button text="%generic.button.close" ButtonBar.buttonData="CANCEL_CLOSE" cancelButton="true" onAction="#close"/>
<Button text="Use RecoveryKey" ButtonBar.buttonData="CANCEL_CLOSE" defaultButton="true" onAction="#recover"/>
<Button text="%recoveryKey.recover.onBoarding.confirm" ButtonBar.buttonData="CANCEL_CLOSE" defaultButton="true" onAction="#recover"/>
</buttons>
</ButtonBar>
</VBox>