Apply prettier formatting

This commit is contained in:
Michael Weimann 2022-12-12 12:24:14 +01:00
parent 1cac306093
commit 526645c791
No known key found for this signature in database
GPG key ID: 53F535A266BB9584
1576 changed files with 65385 additions and 62478 deletions

View file

@ -25,19 +25,23 @@ const TOAST_KEY = "serverlimit";
export const showToast = (limitType: string, onHideToast: () => void, adminContact?: string, syncError?: boolean) => {
const errorText = messageForResourceLimitError(limitType, adminContact, {
'monthly_active_user': _td("Your homeserver has exceeded its user limit."),
'hs_blocked': _td("This homeserver has been blocked by its administrator."),
'': _td("Your homeserver has exceeded one of its resource limits."),
"monthly_active_user": _td("Your homeserver has exceeded its user limit."),
"hs_blocked": _td("This homeserver has been blocked by its administrator."),
"": _td("Your homeserver has exceeded one of its resource limits."),
});
const contactText = messageForResourceLimitError(limitType, adminContact, {
'': _td("Contact your <a>server admin</a>."),
"": _td("Contact your <a>server admin</a>."),
});
ToastStore.sharedInstance().addOrReplaceToast({
key: TOAST_KEY,
title: _t("Warning"),
props: {
description: <React.Fragment>{ errorText } { contactText }</React.Fragment>,
description: (
<React.Fragment>
{errorText} {contactText}
</React.Fragment>
),
acceptLabel: _t("Ok"),
onAccept: () => {
hideToast();