Browse Source

Change localized text and tweak ui

Armin Schrenk 3 years ago
parent
commit
c868ac32cc

+ 1 - 0
main/ui/src/main/resources/fxml/health_check_details.fxml

@@ -7,6 +7,7 @@
 <VBox xmlns:fx="http://javafx.com/fxml"
 	  xmlns="http://javafx.com/javafx"
 	  fx:controller="org.cryptomator.ui.health.CheckDetailController"
+	  prefWidth="500"
 	  spacing="6">
 	<FormattedLabel fx:id="checkTitle" styleClass="label-large" format="%health.check.detail.header" arg1="${controller.taskName}"/>
 

+ 4 - 4
main/ui/src/main/resources/fxml/health_result_listcell.fxml

@@ -2,9 +2,9 @@
 
 <?import org.cryptomator.ui.controls.FontAwesome5IconView?>
 <?import javafx.geometry.Insets?>
+<?import javafx.scene.control.Button?>
 <?import javafx.scene.control.Label?>
 <?import javafx.scene.layout.HBox?>
-<?import javafx.scene.control.Button?>
 <?import javafx.scene.layout.Region?>
 <HBox xmlns:fx="http://javafx.com/fxml"
 	  xmlns="http://javafx.com/javafx"
@@ -13,17 +13,17 @@
 	  prefWidth="200"
 	  spacing="6"
 	  alignment="CENTER_LEFT">
-	<!-- Remark Check the containing list view for a fixed cell size before editing height properties -->
+	<!-- Remark: Check the containing list view for a fixed cell size before editing height properties -->
 	<padding>
 		<Insets topRightBottomLeft="6"/>
 	</padding>
 	<children>
 		<FontAwesome5IconView fx:id="iconView" HBox.hgrow="NEVER" glyphSize="16"/>
-		<Label text="${controller.description}" wrapText="true"/>
+		<Label text="${controller.description}"/>
 		<Region HBox.hgrow="ALWAYS"/>
 		<!-- TODO: setting the minWidth of the button is just a workaround.
 		           What we actually want to do is to prevent shrinking the button more than the text
 		           -> own subclass of HBox is needed -->
-		<Button fx:id="actionButton" text="%health.check.fixBtn" onAction="#runResultAction" alignment="CENTER" visible="false" minWidth="50"/>
+		<Button fx:id="actionButton" text="%health.check.fixBtn" onAction="#runResultAction" alignment="CENTER" visible="false" minWidth="-Infinity"/>
 	</children>
 </HBox>

+ 12 - 3
main/ui/src/main/resources/fxml/health_start.fxml

@@ -1,5 +1,6 @@
 <?xml version="1.0" encoding="UTF-8"?>
 
+<?import org.cryptomator.ui.controls.FontAwesome5IconView?>
 <?import javafx.geometry.Insets?>
 <?import javafx.scene.control.Button?>
 <?import javafx.scene.control.ButtonBar?>
@@ -18,9 +19,17 @@
 	<children>
 		<Label text="%health.start.introduction" wrapText="true"/>
 
-		<Label text="%health.start.configInvalid" visible="${controller.invalidConfig}" managed="${controller.invalidConfig}" wrapText="true"/>
-		<Label text="%health.start.configValid" visible="${!controller.invalidConfig}" managed="${!controller.invalidConfig}" wrapText="true"/>
-
+		<!-- TODO: combine the two below labels to one and bind the properties accordingly or, preferably think about a new flow -->
+		<Label text="%health.start.configInvalid" visible="${controller.invalidConfig}" managed="${controller.invalidConfig}" wrapText="true" contentDisplay="LEFT">
+			<graphic>
+				<FontAwesome5IconView glyph="TIMES" styleClass="glyph-icon-red" />
+			</graphic>
+		</Label>
+		<Label text="%health.start.configValid" visible="${!controller.invalidConfig}" managed="${!controller.invalidConfig}" wrapText="true" contentDisplay="LEFT">
+			<graphic>
+				<FontAwesome5IconView glyph="CHECK" styleClass="glyph-icon-primary" />
+			</graphic>
+		</Label>
 		<ButtonBar buttonMinWidth="120" buttonOrder="+CX">
 			<buttons>
 				<Button text="%generic.button.cancel" ButtonBar.buttonData="CANCEL_CLOSE" cancelButton="true" onAction="#close"/>

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

@@ -147,23 +147,23 @@ migration.impossible.reason=The vault cannot be automatically migrated because i
 migration.impossible.moreInfo=The vault can still be opened with an older version. For instructions on how to manually migrate a vault, visit
 
 # Health Check
-health.title=Vault Check
+health.title=Vault Health Check
 health.start.introduction=The Vault Health Check is a collection of checks to detect and possilby fix problems in the internal structure of your vault. Please note, that not all problems are fixable. You need the vault password to perform the checks.
 health.start.configValid=Reading and parsing vault configuration file was successful. Proceed to select checks.
 health.start.configInvalid=Error while reading and parsing the vault configuration file.
-health.checkList.header=Available Checks
+health.checkList.header=Available Health Checks
 health.checkList.selectAllBox=Select All
 health.check.runBatchBtn=Run selected Checks
 ## Detail view
-health.check.detail.noSelectedCheck=For results select a finished check in the left list.
+health.check.detail.noSelectedCheck=For results select a finished health check in the left list.
 health.check.detail.header=Results of %s
 health.check.detail.taskNotStarted=The check was not selected to run.
 health.check.detail.taskScheduled=The check is scheduled.
 health.check.detail.taskRunning=The check is currently running…
 health.check.detail.taskSucceeded=The check finished successfully after %d milliseconds.
-health.check.detail.taskFailed=The check exited with errors.
+health.check.detail.taskFailed=The check exited due to an error.
 health.check.detail.taskCancelled=The check was cancelled.
-health.check.detail.problemCount=Found %d Problems and %d unfixable Errors.
+health.check.detail.problemCount=Found %d problems and %d unfixable errors.
 health.check.exportBtn=Export Report
 health.check.fixBtn=Fix
 ## Checks
@@ -310,7 +310,7 @@ vaultOptions.general.actionAfterUnlock=After successful unlock
 vaultOptions.general.actionAfterUnlock.ignore=Do nothing
 vaultOptions.general.actionAfterUnlock.reveal=Reveal Drive
 vaultOptions.general.actionAfterUnlock.ask=Ask
-vaultOptions.general.healthBtn=Health Check
+vaultOptions.general.healthBtn=Start Health Check
 ## Mount
 vaultOptions.mount=Mounting
 vaultOptions.mount.readonly=Read-Only