add translations and informations

This commit is contained in:
Mario Pesch 2021-11-03 12:22:51 +01:00
parent 0e33361ee8
commit d67cb74401
6 changed files with 50 additions and 12 deletions

View File

@ -44,7 +44,3 @@ Blockly.Blocks["variables_get_dynamic"] = {
} }
}, },
}; };
/**
* new comment
*/

View File

@ -83,6 +83,16 @@ export const UI = {
messages_LOGIN_FAIL: "Der Benutzername oder das Passwort ist nicht korrekt.", messages_LOGIN_FAIL: "Der Benutzername oder das Passwort ist nicht korrekt.",
messages_copy_code: "Code wurde in die Zwischenablage kopiert", messages_copy_code: "Code wurde in die Zwischenablage kopiert",
/**
* Tablet Dialog
*/
tabletDialog_headline: "Tablet Modus ist aktiviert!",
tabletDialog_text:
"Der Tablet Modus wurde aktiviert. Du kannst nun Programmcodes über die senseBox Connect App auf deine senseBox kopieren. Der Tablet Modus kann in den Einstellungen deaktiviert werden",
tabletDialog_more:
"Weitere Informationen und den Link zum Download der App findest du unter: ",
/** /**
* Reset Dialog * Reset Dialog
*/ */
@ -154,6 +164,11 @@ export const UI = {
"Die Anzeige von Statistiken zur Nutzung der Blöcke oberhalb der Arbeitsfläche kann ein- oder ausgeblendet werden.", "Die Anzeige von Statistiken zur Nutzung der Blöcke oberhalb der Arbeitsfläche kann ein- oder ausgeblendet werden.",
settings_statistics_on: "An", settings_statistics_on: "An",
settings_statistics_off: "Aus", settings_statistics_off: "Aus",
settings_ota_head: "Tablet Modus",
settings_ota_text:
"Der Tablet Modus deaktiviert die Code anzeige und aktiviert die Möglichkeit den Programmcode über die senseBox Connect App zu übertragen. Weitere Informationen dazu findest du unter: ",
settings_ota_on: "Aktiviert",
settings_ota_off: "Deaktiviert",
/** /**
* 404 * 404

View File

@ -80,6 +80,15 @@ export const UI = {
messages_login_error: "Enter both a username and a password.", messages_login_error: "Enter both a username and a password.",
messages_copy_code: "Copy code to clipboard succesfull", messages_copy_code: "Copy code to clipboard succesfull",
/**
* Tablet Dialog
*/
tabletDialog_headline: "Tablet mode is enabled!",
tabletDialog_text:
"Tablet mode has been activated. You can now copy program codes to your senseBox via the senseBox Connect app. Tablet mode can be deactivated in the settings",
tabletDialog_more:
"For more information and the link to download the app, please visit: ",
/** /**
* Reset Dialog * Reset Dialog
*/ */
@ -149,6 +158,11 @@ export const UI = {
"The display of statistics on the usage of the blocks above the workspace can be shown or hidden.", "The display of statistics on the usage of the blocks above the workspace can be shown or hidden.",
settings_statistics_on: "On", settings_statistics_on: "On",
settings_statistics_off: "Off", settings_statistics_off: "Off",
settings_ota_head: "tablet mode",
settings_ota_text:
"Tablet mode disables the code display and enables the possibility to transfer the program code via the senseBox Connect app. You can find more information on: ",
settings_ota_on: "Activated",
settings_ota_off: "Deactivated",
/** /**
* 404 * 404

View File

@ -183,14 +183,23 @@ class Home extends Component {
fullWidth fullWidth
maxWidth={"sm"} maxWidth={"sm"}
open={this.state.open} open={this.state.open}
title="" title={Blockly.Msg.tabletDialog_headline}
content={""} content={""}
onClose={this.toggleDialog} onClose={this.toggleDialog}
onClick={this.toggleDialog} onClick={this.toggleDialog}
button={Blockly.Msg.button_close} button={Blockly.Msg.button_close}
> >
<div>OTA Modus aktiviert.</div> <div>{Blockly.Msg.tabletDialog_text}</div>
<div>Lade die App hier herunter: </div> <div>
{Blockly.Msg.tabletDialog_more}{" "}
<a
href="https://sensebox.de/app"
target="_blank"
rel="noreferrer"
>
https://sensebox.de/app
</a>
</div>
</Dialog> </Dialog>
) : null} ) : null}
</div> </div>

View File

@ -22,11 +22,16 @@ class OtaSelector extends Component {
render() { render() {
return ( return (
<div> <div>
<Typography style={{ fontWeight: "bold" }}>OTA</Typography> <Typography style={{ fontWeight: "bold" }}>
{Blockly.Msg.settings_ota_head}
</Typography>
<FormHelperText <FormHelperText
style={{ color: "black", lineHeight: 1.3, marginBottom: "8px" }} style={{ color: "black", lineHeight: 1.3, marginBottom: "8px" }}
> >
Aktiviere OTA Modus{" "} {Blockly.Msg.settings_ota_text}
<a href="https://sensebox.de/app" target="_blank" rel="noreferrer">
https://sensebox.de/app
</a>
</FormHelperText> </FormHelperText>
<FormControl> <FormControl>
<InputLabel id="demo-simple-select-label"> <InputLabel id="demo-simple-select-label">
@ -38,8 +43,8 @@ class OtaSelector extends Component {
value={this.props.platform} value={this.props.platform}
onChange={(e) => this.props.setPlatform(e.target.value)} onChange={(e) => this.props.setPlatform(e.target.value)}
> >
<MenuItem value={true}>true</MenuItem> <MenuItem value={true}>{Blockly.Msg.settings_ota_on}</MenuItem>
<MenuItem value={false}>false</MenuItem> <MenuItem value={false}>{Blockly.Msg.settings_ota_off}</MenuItem>
</Select> </Select>
</FormControl> </FormControl>
</div> </div>

View File

@ -22,7 +22,6 @@ import "prismjs/plugins/line-numbers/prism-line-numbers";
import "prismjs/plugins/line-numbers/prism-line-numbers.css"; import "prismjs/plugins/line-numbers/prism-line-numbers.css";
import MuiDrawer from "@material-ui/core/Drawer"; import MuiDrawer from "@material-ui/core/Drawer";
import Dialog from "../Dialog"; import Dialog from "../Dialog";
import { Link } from "react-router-dom";
const styles = (theme) => ({ const styles = (theme) => ({
backdrop: { backdrop: {