mirror of
https://github.com/cryptomator/cryptomator.git
synced 2026-08-21 06:36:01 +00:00
new onboarding dialog
remove is hub vault dialog
This commit is contained in:
@@ -151,7 +151,7 @@ public class ChooseExistingVaultController implements FxController {
|
|||||||
//TODO: optional raus, und mit error dialog arbeiten (UI kram in UI package!) hier nur fehler werfen
|
//TODO: optional raus, und mit error dialog arbeiten (UI kram in UI package!) hier nur fehler werfen
|
||||||
optionalVault.ifPresent(vault -> {
|
optionalVault.ifPresent(vault -> {
|
||||||
ObjectProperty<RecoveryActionType> recoverTypeProperty = new SimpleObjectProperty<>(RecoveryActionType.RESTORE_VAULT_CONFIG);
|
ObjectProperty<RecoveryActionType> recoverTypeProperty = new SimpleObjectProperty<>(RecoveryActionType.RESTORE_VAULT_CONFIG);
|
||||||
recoveryKeyWindow.create(vault, window, recoverTypeProperty).showIsHubVaultDialogWindow();
|
recoveryKeyWindow.create(vault, window, recoverTypeProperty).showOnboardingDialogWindow();
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -40,8 +40,8 @@ public enum FxmlFile {
|
|||||||
QUIT("/fxml/quit.fxml"), //
|
QUIT("/fxml/quit.fxml"), //
|
||||||
QUIT_FORCED("/fxml/quit_forced.fxml"), //
|
QUIT_FORCED("/fxml/quit_forced.fxml"), //
|
||||||
RECOVERYKEY_CREATE("/fxml/recoverykey_create.fxml"), //
|
RECOVERYKEY_CREATE("/fxml/recoverykey_create.fxml"), //
|
||||||
RECOVERYKEY_IS_HUB_VAULT("/fxml/recoverykey_is_hub_vault.fxml"), //
|
|
||||||
RECOVERYKEY_EXPERT_SETTINGS("/fxml/recoverykey_expert_settings.fxml"), //
|
RECOVERYKEY_EXPERT_SETTINGS("/fxml/recoverykey_expert_settings.fxml"), //
|
||||||
|
RECOVERYKEY_ONBOARDING("/fxml/recoverykey_onboarding.fxml"), //
|
||||||
RECOVERYKEY_RECOVER("/fxml/recoverykey_recover.fxml"), //
|
RECOVERYKEY_RECOVER("/fxml/recoverykey_recover.fxml"), //
|
||||||
RECOVERYKEY_RESET_PASSWORD("/fxml/recoverykey_reset_password.fxml"), //
|
RECOVERYKEY_RESET_PASSWORD("/fxml/recoverykey_reset_password.fxml"), //
|
||||||
RECOVERYKEY_SUCCESS("/fxml/recoverykey_success.fxml"), //
|
RECOVERYKEY_SUCCESS("/fxml/recoverykey_success.fxml"), //
|
||||||
|
|||||||
@@ -62,7 +62,7 @@ public class VaultDetailMissingVaultController implements FxController {
|
|||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
ObjectProperty<RecoveryActionType> recoverTypeProperty = new SimpleObjectProperty<>(RecoveryActionType.RESTORE_VAULT_CONFIG);
|
ObjectProperty<RecoveryActionType> recoverTypeProperty = new SimpleObjectProperty<>(RecoveryActionType.RESTORE_VAULT_CONFIG);
|
||||||
recoveryKeyWindow.create(vault.get(), window, recoverTypeProperty).showIsHubVaultDialogWindow();
|
recoveryKeyWindow.create(vault.get(), window, recoverTypeProperty).showOnboardingDialogWindow();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -26,8 +26,8 @@ public interface RecoveryKeyComponent {
|
|||||||
@FxmlScene(FxmlFile.RECOVERYKEY_RECOVER)
|
@FxmlScene(FxmlFile.RECOVERYKEY_RECOVER)
|
||||||
Lazy<Scene> recoverScene();
|
Lazy<Scene> recoverScene();
|
||||||
|
|
||||||
@FxmlScene(FxmlFile.RECOVERYKEY_IS_HUB_VAULT)
|
@FxmlScene(FxmlFile.RECOVERYKEY_ONBOARDING)
|
||||||
Lazy<Scene> recoverIsHubVaultScene();
|
Lazy<Scene> recoverOnboardingScene();
|
||||||
|
|
||||||
default void showRecoveryKeyCreationWindow() {
|
default void showRecoveryKeyCreationWindow() {
|
||||||
Stage stage = window();
|
Stage stage = window();
|
||||||
@@ -43,9 +43,9 @@ public interface RecoveryKeyComponent {
|
|||||||
stage.show();
|
stage.show();
|
||||||
}
|
}
|
||||||
|
|
||||||
default void showIsHubVaultDialogWindow() {
|
default void showOnboardingDialogWindow() {
|
||||||
Stage stage = window();
|
Stage stage = window();
|
||||||
stage.setScene(recoverIsHubVaultScene().get());
|
stage.setScene(recoverOnboardingScene().get());
|
||||||
stage.sizeToScene();
|
stage.sizeToScene();
|
||||||
stage.show();
|
stage.show();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -107,10 +107,10 @@ abstract class RecoveryKeyModule {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Provides
|
@Provides
|
||||||
@FxmlScene(FxmlFile.RECOVERYKEY_IS_HUB_VAULT)
|
@FxmlScene(FxmlFile.RECOVERYKEY_ONBOARDING)
|
||||||
@RecoveryKeyScoped
|
@RecoveryKeyScoped
|
||||||
static Scene provideRecoveryKeyIsHubVaultScene(@RecoveryKeyWindow FxmlLoaderFactory fxmlLoaders) {
|
static Scene provideRecoveryKeyOnboardingScene(@RecoveryKeyWindow FxmlLoaderFactory fxmlLoaders) {
|
||||||
return fxmlLoaders.createScene(FxmlFile.RECOVERYKEY_IS_HUB_VAULT);
|
return fxmlLoaders.createScene(FxmlFile.RECOVERYKEY_ONBOARDING);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Provides
|
@Provides
|
||||||
@@ -153,11 +153,6 @@ abstract class RecoveryKeyModule {
|
|||||||
@FxControllerKey(RecoveryKeyExpertSettingsController.class)
|
@FxControllerKey(RecoveryKeyExpertSettingsController.class)
|
||||||
abstract FxController provideRecoveryKeyExpertSettingsController(RecoveryKeyExpertSettingsController controller);
|
abstract FxController provideRecoveryKeyExpertSettingsController(RecoveryKeyExpertSettingsController controller);
|
||||||
|
|
||||||
@Binds
|
|
||||||
@IntoMap
|
|
||||||
@FxControllerKey(RecoveryKeyIsHubVaultController.class)
|
|
||||||
abstract FxController provideRecoveryKeyIsHubVaultController(RecoveryKeyIsHubVaultController controller);
|
|
||||||
|
|
||||||
@Binds
|
@Binds
|
||||||
@IntoMap
|
@IntoMap
|
||||||
@FxControllerKey(RecoveryKeyRecoverController.class)
|
@FxControllerKey(RecoveryKeyRecoverController.class)
|
||||||
@@ -173,6 +168,10 @@ abstract class RecoveryKeyModule {
|
|||||||
@FxControllerKey(RecoveryKeyResetPasswordController.class)
|
@FxControllerKey(RecoveryKeyResetPasswordController.class)
|
||||||
abstract FxController bindRecoveryKeyResetPasswordController(RecoveryKeyResetPasswordController controller);
|
abstract FxController bindRecoveryKeyResetPasswordController(RecoveryKeyResetPasswordController controller);
|
||||||
|
|
||||||
|
@Binds
|
||||||
|
@IntoMap
|
||||||
|
@FxControllerKey(RecoveryKeyOnboardingController.class)
|
||||||
|
abstract FxController bindRecoveryKeyOnboardingController(RecoveryKeyOnboardingController controller);
|
||||||
|
|
||||||
@Provides
|
@Provides
|
||||||
@IntoMap
|
@IntoMap
|
||||||
|
|||||||
+3
-3
@@ -15,14 +15,14 @@ import org.cryptomator.ui.common.FxmlFile;
|
|||||||
import org.cryptomator.ui.common.FxmlScene;
|
import org.cryptomator.ui.common.FxmlScene;
|
||||||
|
|
||||||
@RecoveryKeyScoped
|
@RecoveryKeyScoped
|
||||||
public class RecoveryKeyIsHubVaultController implements FxController {
|
public class RecoveryKeyOnboardingController implements FxController {
|
||||||
|
|
||||||
private final Stage window;
|
private final Stage window;
|
||||||
private final Lazy<Scene> recoverykeyRecoverScene;
|
private final Lazy<Scene> recoverykeyRecoverScene;
|
||||||
private final ObjectProperty<RecoveryActionType> recoverType;
|
private final ObjectProperty<RecoveryActionType> recoverType;
|
||||||
|
|
||||||
@Inject
|
@Inject
|
||||||
public RecoveryKeyIsHubVaultController(@RecoveryKeyWindow Stage window, //
|
public RecoveryKeyOnboardingController(@RecoveryKeyWindow Stage window, //
|
||||||
@FxmlScene(FxmlFile.RECOVERYKEY_RECOVER) Lazy<Scene> recoverykeyRecoverScene, //
|
@FxmlScene(FxmlFile.RECOVERYKEY_RECOVER) Lazy<Scene> recoverykeyRecoverScene, //
|
||||||
@Named("recoverType") ObjectProperty<RecoveryActionType> recoverType, //
|
@Named("recoverType") ObjectProperty<RecoveryActionType> recoverType, //
|
||||||
ResourceBundle resourceBundle) {
|
ResourceBundle resourceBundle) {
|
||||||
@@ -39,7 +39,7 @@ public class RecoveryKeyIsHubVaultController implements FxController {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@FXML
|
@FXML
|
||||||
public void recover() {
|
public void next() {
|
||||||
recoverType.set(RecoveryActionType.RESTORE_VAULT_CONFIG);
|
recoverType.set(RecoveryActionType.RESTORE_VAULT_CONFIG);
|
||||||
window.setScene(recoverykeyRecoverScene.get());
|
window.setScene(recoverykeyRecoverScene.get());
|
||||||
}
|
}
|
||||||
@@ -1,57 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
|
|
||||||
<?import javafx.geometry.Insets?>
|
|
||||||
<?import javafx.scene.control.Button?>
|
|
||||||
<?import javafx.scene.control.ButtonBar?>
|
|
||||||
<?import javafx.scene.control.Label?>
|
|
||||||
<?import javafx.scene.Group?>
|
|
||||||
<?import javafx.scene.layout.HBox?>
|
|
||||||
<?import javafx.scene.layout.Region?>
|
|
||||||
<?import javafx.scene.layout.StackPane?>
|
|
||||||
<?import javafx.scene.layout.VBox?>
|
|
||||||
<?import javafx.scene.shape.Circle?>
|
|
||||||
<?import org.cryptomator.ui.controls.FontAwesome5IconView?>
|
|
||||||
<HBox xmlns:fx="http://javafx.com/fxml"
|
|
||||||
xmlns="http://javafx.com/javafx"
|
|
||||||
fx:controller="org.cryptomator.ui.recoverykey.RecoveryKeyIsHubVaultController"
|
|
||||||
minWidth="400"
|
|
||||||
maxWidth="400"
|
|
||||||
minHeight="204"
|
|
||||||
spacing="12"
|
|
||||||
alignment="TOP_CENTER">
|
|
||||||
<padding>
|
|
||||||
<Insets topRightBottomLeft="12"/>
|
|
||||||
</padding>
|
|
||||||
<children>
|
|
||||||
<Group>
|
|
||||||
<StackPane>
|
|
||||||
<padding>
|
|
||||||
<Insets topRightBottomLeft="6"/>
|
|
||||||
</padding>
|
|
||||||
<Circle styleClass="glyph-icon-primary" radius="24"/>
|
|
||||||
<FontAwesome5IconView styleClass="glyph-icon-white" glyph="QUESTION" glyphSize="24"/>
|
|
||||||
</StackPane>
|
|
||||||
</Group>
|
|
||||||
|
|
||||||
<VBox HBox.hgrow="ALWAYS">
|
|
||||||
<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>
|
|
||||||
<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="%recoveryKey.recover.onBoarding.confirm" ButtonBar.buttonData="CANCEL_CLOSE" defaultButton="true" onAction="#recover"/>
|
|
||||||
</buttons>
|
|
||||||
</ButtonBar>
|
|
||||||
</VBox>
|
|
||||||
</children>
|
|
||||||
</HBox>
|
|
||||||
@@ -0,0 +1,72 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
|
||||||
|
<?import javafx.geometry.Insets?>
|
||||||
|
<?import javafx.scene.control.Button?>
|
||||||
|
<?import javafx.scene.control.ButtonBar?>
|
||||||
|
<?import javafx.scene.control.CheckBox?>
|
||||||
|
<?import javafx.scene.control.Label?>
|
||||||
|
<?import javafx.scene.image.Image?>
|
||||||
|
<?import javafx.scene.image.ImageView?>
|
||||||
|
<?import javafx.scene.layout.ColumnConstraints?>
|
||||||
|
<?import javafx.scene.layout.GridPane?>
|
||||||
|
<?import javafx.scene.layout.HBox?>
|
||||||
|
<?import javafx.scene.layout.Region?>
|
||||||
|
<?import javafx.scene.layout.RowConstraints?>
|
||||||
|
<?import javafx.scene.layout.VBox?>
|
||||||
|
<VBox xmlns:fx="http://javafx.com/fxml"
|
||||||
|
xmlns="http://javafx.com/javafx"
|
||||||
|
fx:controller="org.cryptomator.ui.recoverykey.RecoveryKeyOnboardingController"
|
||||||
|
prefWidth="650"
|
||||||
|
prefHeight="400"
|
||||||
|
spacing="12">
|
||||||
|
<padding>
|
||||||
|
<Insets topRightBottomLeft="12"/>
|
||||||
|
</padding>
|
||||||
|
<children>
|
||||||
|
<HBox VBox.vgrow="ALWAYS">
|
||||||
|
<VBox alignment="CENTER" minWidth="175" maxWidth="175">
|
||||||
|
<ImageView VBox.vgrow="ALWAYS" fitHeight="128" preserveRatio="true" cache="true">
|
||||||
|
<Image url="@../img/logo128.png"/>
|
||||||
|
</ImageView>
|
||||||
|
</VBox>
|
||||||
|
<VBox HBox.hgrow="ALWAYS" alignment="CENTER">
|
||||||
|
<padding>
|
||||||
|
<Insets topRightBottomLeft="12"/>
|
||||||
|
</padding>
|
||||||
|
<Label text="%recoveryKey.recoverVaultConfig.title" styleClass="label-extra-large"/>
|
||||||
|
<Region minHeight="15"/>
|
||||||
|
<VBox>
|
||||||
|
<Label text="%recoveryKey.recover.onBoarding.message" wrapText="true"/>
|
||||||
|
<GridPane alignment="CENTER_LEFT" >
|
||||||
|
<padding>
|
||||||
|
<Insets left="6"/>
|
||||||
|
</padding>
|
||||||
|
<columnConstraints>
|
||||||
|
<ColumnConstraints minWidth="20" halignment="LEFT"/>
|
||||||
|
<ColumnConstraints fillWidth="true"/>
|
||||||
|
</columnConstraints>
|
||||||
|
<rowConstraints>
|
||||||
|
<RowConstraints valignment="TOP"/>
|
||||||
|
<RowConstraints valignment="TOP"/>
|
||||||
|
<RowConstraints valignment="TOP"/>
|
||||||
|
</rowConstraints>
|
||||||
|
<Label text="1." GridPane.rowIndex="0" GridPane.columnIndex="0" />
|
||||||
|
<Label text="%recoveryKey.recover.onBoarding.intro1" wrapText="true" GridPane.rowIndex="0" GridPane.columnIndex="1" />
|
||||||
|
<Label text="2." GridPane.rowIndex="1" GridPane.columnIndex="0" />
|
||||||
|
<Label text="%recoveryKey.recover.onBoarding.intro2" wrapText="true" GridPane.rowIndex="1" GridPane.columnIndex="1" />
|
||||||
|
<Label text="3." GridPane.rowIndex="2" GridPane.columnIndex="0" />
|
||||||
|
<Label text="%recoveryKey.recover.onBoarding.intro3" wrapText="true" GridPane.rowIndex="2" GridPane.columnIndex="1" />
|
||||||
|
</GridPane>
|
||||||
|
<Region minHeight="15"/>
|
||||||
|
<CheckBox text="%recoveryKey.recover.onBoarding.affirmation" fx:id="affirmationBox"/>
|
||||||
|
</VBox>
|
||||||
|
</VBox>
|
||||||
|
</HBox>
|
||||||
|
<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" disable="${!affirmationBox.selected}" defaultButton="true" onAction="#next"/>
|
||||||
|
</buttons>
|
||||||
|
</ButtonBar>
|
||||||
|
</children>
|
||||||
|
</VBox>
|
||||||
@@ -537,9 +537,14 @@ recoveryKey.recoverVaultConfig.title=Recover Vault Config
|
|||||||
recoveryKey.recoverMasterkey.title=Recover Masterkey
|
recoveryKey.recoverMasterkey.title=Recover Masterkey
|
||||||
|
|
||||||
recoveryKey.recover.onBoarding.title=Restore your vault.cryptomator file
|
recoveryKey.recover.onBoarding.title=Restore your vault.cryptomator file
|
||||||
recoveryKey.recover.onBoarding.message=If your vault is a hub managed vault, the Hub Admin can restore the file for you.
|
recoveryKey.recover.onBoarding.message=If your vault is a hub managed vault, the Hub Admin can restore the file for you. Otherwise:
|
||||||
recoveryKey.recover.onBoarding.description=Otherwise you will need the Recovery Key of the vault, possible some expert settings, and a new vault password.
|
recoveryKey.recover.onBoarding.description=Otherwise you will need the Recovery Key of the vault, possible some expert settings, and a new vault password.
|
||||||
recoveryKey.recover.onBoarding.confirm=Use RecoveryKey
|
recoveryKey.recover.onBoarding.confirm=Use RecoveryKey
|
||||||
|
recoveryKey.recover.onBoarding.intro1=Ensure all files are completely synced.
|
||||||
|
recoveryKey.recover.onBoarding.intro2=You will need the Recovery Key of the vault.
|
||||||
|
recoveryKey.recover.onBoarding.intro3=A new vault password and possible some expert settings.
|
||||||
|
recoveryKey.recover.onBoarding.affirmation=I have read and understood the above information
|
||||||
|
|
||||||
|
|
||||||
# Convert Vault
|
# Convert Vault
|
||||||
convertVault.title=Convert Vault
|
convertVault.title=Convert Vault
|
||||||
|
|||||||
Reference in New Issue
Block a user