add toasts keys i18n

This commit is contained in:
SimonOriginal
2024-06-24 18:09:45 +02:00
parent 3d1de6144e
commit 665f87e84a
41 changed files with 191 additions and 6 deletions

View File

@@ -32,7 +32,7 @@
saveSettings({ notificationEnabled: notificationEnabled });
} else {
toast.error(
'Response notifications cannot be activated as the website permissions have been denied. Please visit your browser settings to grant the necessary access.'
$i18n.t('Response notifications cannot be activated as the website permissions have been denied. Please visit your browser settings to grant the necessary access.')
);
}
};

View File

@@ -75,7 +75,7 @@
if (position) {
await updateUserInfo(localStorage.token, { location: position });
toast.success('User location successfully retrieved.');
toast.success($i18n.t('User location successfully retrieved.'));
} else {
userLocation = false;
}
@@ -111,7 +111,7 @@
saveSettings({ responseAutoCopy: responseAutoCopy });
} else {
toast.error(
'Clipboard write permission denied. Please check your browser settings to grant the necessary access.'
$i18n.t('Clipboard write permission denied. Please check your browser settings to grant the necessary access.')
);
}
};

View File

@@ -73,7 +73,7 @@
);
if (res) {
toast.success('Valves updated');
toast.success($i18n.t('Valves updated'));
valves = res;
}
} else if (tab === 'functions') {
@@ -87,7 +87,7 @@
});
if (res) {
toast.success('Valves updated');
toast.success($i18n.t('Valves updated'));
valves = res;
}
}

View File

@@ -37,7 +37,7 @@
changes: [{ from: 0, to: codeEditor.state.doc.length, insert: formattedCode }]
});
toast.success('Code formatted successfully');
toast.success($i18n.t('Code formatted successfully'));
return true;
}
return false;