Remove useless button in proxiwash modal
This commit is contained in:
parent
b692b6e7f6
commit
5d65d72418
3 changed files with 2 additions and 8 deletions
|
@ -70,7 +70,6 @@
|
||||||
"modal": {
|
"modal": {
|
||||||
"enableNotifications": "Notify me",
|
"enableNotifications": "Notify me",
|
||||||
"disableNotifications": "Stop notifications",
|
"disableNotifications": "Stop notifications",
|
||||||
"ok": "OK",
|
|
||||||
"cancel": "Cancel",
|
"cancel": "Cancel",
|
||||||
"finished": "This machine is finished. If you started it, you can get back your laundry.",
|
"finished": "This machine is finished. If you started it, you can get back your laundry.",
|
||||||
"ready": "This machine is empty and ready to use.",
|
"ready": "This machine is empty and ready to use.",
|
||||||
|
|
|
@ -70,7 +70,6 @@
|
||||||
"modal": {
|
"modal": {
|
||||||
"enableNotifications": "Me Notifier",
|
"enableNotifications": "Me Notifier",
|
||||||
"disableNotifications": "Désactiver les notifications",
|
"disableNotifications": "Désactiver les notifications",
|
||||||
"ok": "OK",
|
|
||||||
"cancel": "Annuler",
|
"cancel": "Annuler",
|
||||||
"finished": "Cette machine est terminée. Si tu l'as démarrée, tu peux récupérer ton linge.",
|
"finished": "Cette machine est terminée. Si tu l'as démarrée, tu peux récupérer ton linge.",
|
||||||
"ready": "Cette machine est vide et prête à être utilisée.",
|
"ready": "Cette machine est vide et prête à être utilisée.",
|
||||||
|
|
|
@ -200,11 +200,7 @@ class ProxiwashScreen extends React.Component<PropsType, StateType> {
|
||||||
*/
|
*/
|
||||||
getModalContent(title: string, item: ProxiwashMachineType, isDryer: boolean) {
|
getModalContent(title: string, item: ProxiwashMachineType, isDryer: boolean) {
|
||||||
const {props, state} = this;
|
const {props, state} = this;
|
||||||
let button: {text: string; icon: string; onPress: () => void} = {
|
let button: {text: string; icon: string; onPress: () => void} | undefined;
|
||||||
text: i18n.t('screens.proxiwash.modal.ok'),
|
|
||||||
icon: '',
|
|
||||||
onPress: () => undefined,
|
|
||||||
};
|
|
||||||
let message = this.modalStateStrings[item.state];
|
let message = this.modalStateStrings[item.state];
|
||||||
const onPress = () => this.onSetupNotificationsPress(item);
|
const onPress = () => this.onSetupNotificationsPress(item);
|
||||||
if (item.state === MachineStates.RUNNING) {
|
if (item.state === MachineStates.RUNNING) {
|
||||||
|
@ -247,7 +243,7 @@ class ProxiwashScreen extends React.Component<PropsType, StateType> {
|
||||||
<Text>{message}</Text>
|
<Text>{message}</Text>
|
||||||
</Card.Content>
|
</Card.Content>
|
||||||
|
|
||||||
{button.onPress ? (
|
{button ? (
|
||||||
<Card.Actions>
|
<Card.Actions>
|
||||||
<Button
|
<Button
|
||||||
icon={button.icon}
|
icon={button.icon}
|
||||||
|
|
Loading…
Reference in a new issue