-
Notifications
You must be signed in to change notification settings - Fork 355
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Show nice error message on network time out (#3036)
Shows "Network error. Please refresh your page and try again." when the retry middleware times out from too many attempts on failed/timed out requests. CORL-1199 Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
- Loading branch information
1 parent
7f98f13
commit fe19ffd
Showing
4 changed files
with
45 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
.root { | ||
background-color: var(--palette-error-300); | ||
|
||
font-family: var(--font-family-primary); | ||
font-weight: var(--font-weight-primary-semi-bold); | ||
font-size: var(--font-size-3); | ||
line-height: var(--line-height-3); | ||
color: var(--palette-text-500); | ||
|
||
border-radius: var(--round-corners); | ||
|
||
padding: var(--spacing-3); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
import { Localized } from "@fluent/react/compat"; | ||
import React, { FunctionComponent } from "react"; | ||
|
||
import styles from "./NetworkError.css"; | ||
|
||
const NetworkError: FunctionComponent = () => { | ||
return ( | ||
<div className={styles.root}> | ||
<Localized id="common-networkError"> | ||
<div>Network error. Please refresh your page and try again.</div> | ||
</Localized> | ||
</div> | ||
); | ||
}; | ||
|
||
export default NetworkError; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters