new error for no available user (#7609)

* new error for no available user

* Added cursor-pointer & extra whitespace before 'go back.'

---------

Co-authored-by: Alex van Andel <me@alexvanandel.com>
pull/7634/head^2
Peer Richelsen 2023-03-09 14:11:07 +01:00 committed by GitHub
parent c374f4fa20
commit 4cd32fca4a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 16 additions and 4 deletions

View File

@ -615,17 +615,28 @@ export default BookingPage;
function ErrorMessage({ error }: { error: unknown }) {
const { t } = useLocale();
const { query: { rescheduleUid } = {} } = useRouter();
const router = useRouter();
return (
<div data-testid="booking-fail" className="mt-2 border-l-4 border-yellow-400 bg-yellow-50 p-4">
<div data-testid="booking-fail" className="mt-2 border-l-4 border-blue-400 bg-blue-50 p-4">
<div className="flex">
<div className="flex-shrink-0">
<FiAlertTriangle className="h-5 w-5 text-yellow-400" aria-hidden="true" />
<FiAlertTriangle className="h-5 w-5 text-blue-400" aria-hidden="true" />
</div>
<div className="ltr:ml-3 rtl:mr-3">
<p className="text-sm text-yellow-700">
<p className="text-sm text-blue-700">
{rescheduleUid ? t("reschedule_fail") : t("booking_fail")}{" "}
{error instanceof HttpError || error instanceof Error ? t(error.message) : "Unknown error"}
{error instanceof HttpError || error instanceof Error ? (
<>
{t("can_you_try_again")}{" "}
<span className="cursor-pointer underline" onClick={() => router.back()}>
{t("go_back")}
</span>
.
</> /* t(error.message) */
) : (
"Unknown error"
)}
</p>
</div>
</div>

View File

@ -1640,6 +1640,7 @@
"app_is_connected": "{{dependencyName}} is connected",
"requires_app": "Requires {{dependencyName}}",
"verification_code": "Verification code",
"can_you_try_again": "Can you try again with a different time?",
"verify": "Verify",
"select_all": "Select All",
"default_conferencing_bulk_title": "Bulk update existing event types",