edit error scr
This commit is contained in:
@@ -1,16 +1,10 @@
|
||||
import styles from "./ErrorScreen.module.css";
|
||||
|
||||
const ErrorScreen = ({ onFocus, onChange, onKeyDown }) => {
|
||||
const ErrorScreen = ({ errorMessage, children }) => {
|
||||
return (
|
||||
<div className={styles.wrapper}>
|
||||
<h1 className={styles.message}>City not found, try again!</h1>
|
||||
<input
|
||||
type="text"
|
||||
className={styles.input}
|
||||
onFocus={onFocus}
|
||||
onChange={onChange}
|
||||
onKeyDown={onKeyDown}
|
||||
/>
|
||||
<h1 className={styles.message}>{errorMessage}</h1>
|
||||
{children}
|
||||
</div>
|
||||
);
|
||||
};
|
||||
|
||||
@@ -8,17 +8,3 @@
|
||||
.message {
|
||||
margin-bottom: 30px;
|
||||
}
|
||||
|
||||
.input {
|
||||
max-width: 100%;
|
||||
margin-bottom: 20px;
|
||||
height: 40px;
|
||||
border: none;
|
||||
padding: 0 10px;
|
||||
color: #303030;
|
||||
font-size: 20px;
|
||||
text-align: right;
|
||||
border-radius: 10px;
|
||||
font-family: "Varela Round", sans-serif;
|
||||
font-size: 18px;
|
||||
}
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
import styles from "./LoadingScreen.module.css";
|
||||
|
||||
const LoadingScreen = () => {
|
||||
const LoadingScreen = ({ loadingMessage }) => {
|
||||
return (
|
||||
<div className={styles.wrapper}>
|
||||
<h1>Loading data...</h1>
|
||||
<h1>{loadingMessage}</h1>
|
||||
</div>
|
||||
);
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user