chore: fix 'Deamon' typo

---
Reviewed-by: schowdhuri
This commit is contained in:
Ahmed Bouhuolia 2022-05-17 22:08:17 +02:00 committed by GitHub
parent 71bbc7e3f5
commit 7ada7f17db
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
7 changed files with 40 additions and 40 deletions

View File

@ -35,14 +35,14 @@ export enum LangKeys {
AccountNodeSettingsLocal = "account.nodeSecurity.local.title", AccountNodeSettingsLocal = "account.nodeSecurity.local.title",
AccountNodeSettingsRemote = "account.nodeSecurity.remote.title", AccountNodeSettingsRemote = "account.nodeSecurity.remote.title",
AccountNodeFieldBlockchainLocation = "account.nodeSecurity.blockchainLocation", AccountNodeFieldBlockchainLocation = "account.nodeSecurity.blockchainLocation",
AccountNodeFieldDeamonAddress = "account.nodeSecurity.deamonAddress", AccountNodeFieldDaemonAddress = "account.nodeSecurity.daemonAddress",
AccountNodeFieldDeamonFlags = "account.nodeSecurity.deamonFlags", AccountNodeFieldDaemonFlags = "account.nodeSecurity.daemonFlags",
AccountNodeFieldPort = "account.nodeSecurity.port", AccountNodeFieldPort = "account.nodeSecurity.port",
AccountNodeStopDeamon = "account.nodeSecurity.stopDeamon", AccountNodeStopDaemon = "account.nodeSecurity.stopDaemon",
AccountNodeStartDeamon = "account.nodeSecurity.startDeamon", AccountNodeStartDaemon = "account.nodeSecurity.startDaemon",
AccountNodeLocalSaveNotification = "account.nodeSecurity.saveNotification", AccountNodeLocalSaveNotification = "account.nodeSecurity.saveNotification",
AccountNodeDeamonStoppedNotif = "account.nodeSecurity.stoppedNotification", AccountNodeDaemonStoppedNotif = "account.nodeSecurity.stoppedNotification",
AccountNodeDeamonStartedNotif = "account.nodeSecurity.startedNotification", AccountNodeDaemonStartedNotif = "account.nodeSecurity.startedNotification",
AccountSettingsAddNode = "account.settings.addNewNode", AccountSettingsAddNode = "account.settings.addNewNode",
AccountSettingsCurrent = "account.settings.current", AccountSettingsCurrent = "account.settings.current",
AccountSecurityFieldPassword = "account.security.field.password", AccountSecurityFieldPassword = "account.security.field.password",

View File

@ -39,15 +39,15 @@ const LangPackEN: { [key in LangKeys]: string } = {
[LangKeys.AccountNodeSettingsLocal]: "Local Node", [LangKeys.AccountNodeSettingsLocal]: "Local Node",
[LangKeys.AccountNodeSettingsRemote]: "Remote Node", [LangKeys.AccountNodeSettingsRemote]: "Remote Node",
[LangKeys.AccountNodeFieldBlockchainLocation]: "Blockchain location", [LangKeys.AccountNodeFieldBlockchainLocation]: "Blockchain location",
[LangKeys.AccountNodeFieldDeamonAddress]: "Deamon Address", [LangKeys.AccountNodeFieldDaemonAddress]: "Daemon Address",
[LangKeys.AccountNodeFieldPort]: "Port", [LangKeys.AccountNodeFieldPort]: "Port",
[LangKeys.AccountNodeFieldDeamonFlags]: "Deamon startup flags", [LangKeys.AccountNodeFieldDaemonFlags]: "Daemon startup flags",
[LangKeys.AccountNodeStopDeamon]: "Stop deamon", [LangKeys.AccountNodeStopDaemon]: "Stop daemon",
[LangKeys.AccountNodeStartDeamon]: "Start deamon", [LangKeys.AccountNodeStartDaemon]: "Start daemon",
[LangKeys.AccountNodeLocalSaveNotification]: [LangKeys.AccountNodeLocalSaveNotification]:
"Local node settings updated successfully", "Local node settings updated successfully",
[LangKeys.AccountNodeDeamonStoppedNotif]: "Deamon stopped successfully", [LangKeys.AccountNodeDaemonStoppedNotif]: "Daemon stopped successfully",
[LangKeys.AccountNodeDeamonStartedNotif]: "Deamon started successfully", [LangKeys.AccountNodeDaemonStartedNotif]: "Daemon started successfully",
[LangKeys.AccountSettingsAddNode]: "Add a new node", [LangKeys.AccountSettingsAddNode]: "Add a new node",
[LangKeys.AccountSettingsCurrent]: "Current", [LangKeys.AccountSettingsCurrent]: "Current",
[LangKeys.AccountSecurityFieldPassword]: "Update account password", [LangKeys.AccountSecurityFieldPassword]: "Update account password",

View File

@ -40,15 +40,15 @@ const LangPackES: { [key in LangKeys]: string } = {
[LangKeys.AccountNodeSettingsRemote]: "Nodo Remoto", [LangKeys.AccountNodeSettingsRemote]: "Nodo Remoto",
[LangKeys.AccountNodeFieldBlockchainLocation]: [LangKeys.AccountNodeFieldBlockchainLocation]:
"Ubicación de cadena de bloques", "Ubicación de cadena de bloques",
[LangKeys.AccountNodeFieldDeamonAddress]: "Dirección del demonio", [LangKeys.AccountNodeFieldDaemonAddress]: "Dirección del demonio",
[LangKeys.AccountNodeFieldPort]: "Puerto", [LangKeys.AccountNodeFieldPort]: "Puerto",
[LangKeys.AccountNodeFieldDeamonFlags]: "Indicadores de inicio de daemon", [LangKeys.AccountNodeFieldDaemonFlags]: "Indicadores de inicio de daemon",
[LangKeys.AccountNodeStopDeamon]: "Detener demonio", [LangKeys.AccountNodeStopDaemon]: "Detener demonio",
[LangKeys.AccountNodeStartDeamon]: "Comienzo demonio", [LangKeys.AccountNodeStartDaemon]: "Comienzo demonio",
[LangKeys.AccountNodeLocalSaveNotification]: [LangKeys.AccountNodeLocalSaveNotification]:
"La configuración del nodo local se actualizó correctamente.", "La configuración del nodo local se actualizó correctamente.",
[LangKeys.AccountNodeDeamonStoppedNotif]: "Daemon se detuvo con éxito", [LangKeys.AccountNodeDaemonStoppedNotif]: "Daemon se detuvo con éxito",
[LangKeys.AccountNodeDeamonStartedNotif]: "Daemon se inició con éxito", [LangKeys.AccountNodeDaemonStartedNotif]: "Daemon se inició con éxito",
[LangKeys.AccountSettingsAddNode]: "Agregar un nuevo nodo", [LangKeys.AccountSettingsAddNode]: "Agregar un nuevo nodo",
[LangKeys.AccountSettingsCurrent]: "Actual", [LangKeys.AccountSettingsCurrent]: "Actual",
[LangKeys.AccountSecurityFieldPassword]: "Clave", [LangKeys.AccountSecurityFieldPassword]: "Clave",

View File

@ -23,7 +23,7 @@ import { LangKeys } from "@constants/lang";
import { TextInput } from "@atoms/TextInput"; import { TextInput } from "@atoms/TextInput";
import { useMoneroNodeSettings } from "@hooks/haveno/useMoneroNodeSettings"; import { useMoneroNodeSettings } from "@hooks/haveno/useMoneroNodeSettings";
import { useSetMoneroNodeSettings } from "@hooks/haveno/useSetMoneroNodeSettings"; import { useSetMoneroNodeSettings } from "@hooks/haveno/useSetMoneroNodeSettings";
import { NodeLocalStopDeamon } from "./NodeLocalStopDeamon"; import { NodeLocalStopDaemon } from "./NodeLocalStopDaemon";
import type { NodeLocalFormValues } from "./_hooks"; import type { NodeLocalFormValues } from "./_hooks";
import { useNodeLocalFormValidation } from "./_hooks"; import { useNodeLocalFormValidation } from "./_hooks";
import { transformSettingsRequestToForm } from "./_utils"; import { transformSettingsRequestToForm } from "./_utils";
@ -39,7 +39,7 @@ export function NodeLocalForm() {
initialValues: { initialValues: {
blockchainLocation: "", blockchainLocation: "",
startupFlags: "", startupFlags: "",
deamonAddress: "", daemonAddress: "",
port: "", port: "",
...(nodeSettings ...(nodeSettings
? transformSettingsRequestToForm(nodeSettings.toObject()) ? transformSettingsRequestToForm(nodeSettings.toObject())
@ -52,7 +52,7 @@ export function NodeLocalForm() {
updateNodeSettings({ updateNodeSettings({
blockchainPath: values.blockchainLocation, blockchainPath: values.blockchainLocation,
startupFlags: values.startupFlags.split(", "), startupFlags: values.startupFlags.split(", "),
bootstrapUrl: `${values.deamonAddress}:${values.port}`, bootstrapUrl: `${values.daemonAddress}:${values.port}`,
}) })
.then(() => { .then(() => {
showNotification({ showNotification({
@ -75,7 +75,7 @@ export function NodeLocalForm() {
return ( return (
<Box> <Box>
<NodeLocalStopDeamon /> <NodeLocalStopDaemon />
<form onSubmit={form.onSubmit(handleFormSubmit)}> <form onSubmit={form.onSubmit(handleFormSubmit)}>
<Stack spacing="lg"> <Stack spacing="lg">
@ -93,8 +93,8 @@ export function NodeLocalForm() {
id="startupFlags" id="startupFlags"
label={ label={
<FormattedMessage <FormattedMessage
id={LangKeys.AccountNodeFieldDeamonFlags} id={LangKeys.AccountNodeFieldDaemonFlags}
defaultMessage="Deamon startup flags" defaultMessage="Daemon startup flags"
/> />
} }
{...form.getInputProps("startupFlags")} {...form.getInputProps("startupFlags")}
@ -102,15 +102,15 @@ export function NodeLocalForm() {
<Grid> <Grid>
<Grid.Col span={9}> <Grid.Col span={9}>
<TextInput <TextInput
id="deamonAddress" id="daemonAddress"
label={ label={
<FormattedMessage <FormattedMessage
id={LangKeys.AccountNodeFieldDeamonAddress} id={LangKeys.AccountNodeFieldDaemonAddress}
defaultMessage="Deamon Address" defaultMessage="Daemon Address"
/> />
} }
required required
{...form.getInputProps("deamonAddress")} {...form.getInputProps("daemonAddress")}
/> />
</Grid.Col> </Grid.Col>
<Grid.Col span={3}> <Grid.Col span={3}>

View File

@ -24,7 +24,7 @@ import { useStopMoneroNode } from "@hooks/haveno/useStopMoneroNode";
import { useIsMoneroNodeRunning } from "@hooks/haveno/useIsMoneroNodeRunning"; import { useIsMoneroNodeRunning } from "@hooks/haveno/useIsMoneroNodeRunning";
import { useStartMoneroNode } from "@hooks/haveno/useStartMoneroNode"; import { useStartMoneroNode } from "@hooks/haveno/useStartMoneroNode";
export function NodeLocalStopDeamon() { export function NodeLocalStopDaemon() {
const { classes } = useStyles(); const { classes } = useStyles();
const intl = useIntl(); const intl = useIntl();
@ -41,8 +41,8 @@ export function NodeLocalStopDeamon() {
showNotification({ showNotification({
color: "green", color: "green",
message: intl.formatMessage({ message: intl.formatMessage({
id: LangKeys.AccountNodeDeamonStoppedNotif, id: LangKeys.AccountNodeDaemonStoppedNotif,
defaultMessage: "Deamon stopped successfully", defaultMessage: "Daemon stopped successfully",
}), }),
}); });
}) })
@ -65,8 +65,8 @@ export function NodeLocalStopDeamon() {
showNotification({ showNotification({
color: "green", color: "green",
message: intl.formatMessage({ message: intl.formatMessage({
id: LangKeys.AccountNodeDeamonStartedNotif, id: LangKeys.AccountNodeDaemonStartedNotif,
defaultMessage: "Deamon started successfully", defaultMessage: "Daemon started successfully",
}), }),
}); });
}) })
@ -85,8 +85,8 @@ export function NodeLocalStopDeamon() {
{isMoneroNodeRunning ? ( {isMoneroNodeRunning ? (
<Button flavor="neutral" onClick={handleStopBtnClick}> <Button flavor="neutral" onClick={handleStopBtnClick}>
<FormattedMessage <FormattedMessage
id={LangKeys.AccountNodeStopDeamon} id={LangKeys.AccountNodeStopDaemon}
defaultMessage="Stop deamon" defaultMessage="Stop daemon"
/> />
</Button> </Button>
) : ( ) : (
@ -96,8 +96,8 @@ export function NodeLocalStopDeamon() {
disabled={Boolean(isNodeSettingsLoading || !nodeSettings)} disabled={Boolean(isNodeSettingsLoading || !nodeSettings)}
> >
<FormattedMessage <FormattedMessage
id={LangKeys.AccountNodeStopDeamon} id={LangKeys.AccountNodeStopDaemon}
defaultMessage="Start deamon" defaultMessage="Start daemon"
/> />
</Button> </Button>
)} )}

View File

@ -19,7 +19,7 @@ import * as Joi from "joi";
export interface NodeLocalFormValues { export interface NodeLocalFormValues {
blockchainLocation: string; blockchainLocation: string;
startupFlags: string; startupFlags: string;
deamonAddress: string; daemonAddress: string;
port: string; port: string;
} }
@ -27,7 +27,7 @@ export function useNodeLocalFormValidation() {
return Joi.object<NodeLocalFormValues>({ return Joi.object<NodeLocalFormValues>({
blockchainLocation: Joi.string().empty("").uri({ relativeOnly: true }), blockchainLocation: Joi.string().empty("").uri({ relativeOnly: true }),
startupFlags: Joi.string().empty(""), startupFlags: Joi.string().empty(""),
deamonAddress: Joi.string().uri({ allowRelative: false }), daemonAddress: Joi.string().uri({ allowRelative: false }),
port: Joi.number().port(), port: Joi.number().port(),
}); });
} }

View File

@ -28,7 +28,7 @@ export function transformSettingsRequestToForm(
return { return {
blockchainLocation: nodeSettings?.blockchainPath || "", blockchainLocation: nodeSettings?.blockchainPath || "",
startupFlags: nodeSettings?.startupFlagsList.join(", ") || "", startupFlags: nodeSettings?.startupFlagsList.join(", ") || "",
deamonAddress: transfromBootstrapUrl(nodeSettings?.bootstrapUrl || ""), daemonAddress: transfromBootstrapUrl(nodeSettings?.bootstrapUrl || ""),
port: transformPort(nodeSettings?.bootstrapUrl || ""), port: transformPort(nodeSettings?.bootstrapUrl || ""),
}; };
} }