add search comp
This commit is contained in:
17
components/Search.js
Normal file
17
components/Search.js
Normal file
@@ -0,0 +1,17 @@
|
||||
import styles from "./Search.module.css";
|
||||
|
||||
const Search = ({ placeHolder, value, onFocus, onChange, onKeyDown }) => {
|
||||
return (
|
||||
<input
|
||||
className={styles.searchInput}
|
||||
type="text"
|
||||
placeholder={placeHolder}
|
||||
value={value}
|
||||
onFocus={onFocus}
|
||||
onChange={onChange}
|
||||
onKeyDown={onKeyDown}
|
||||
/>
|
||||
);
|
||||
};
|
||||
|
||||
export default Search;
|
||||
18
components/Search.module.css
Normal file
18
components/Search.module.css
Normal file
@@ -0,0 +1,18 @@
|
||||
.searchInput {
|
||||
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;
|
||||
}
|
||||
|
||||
@media only screen and (max-width: 520px) {
|
||||
.searchInput {
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user