From ff13eebfe17188f1402399dcbe9cf38068843bec Mon Sep 17 00:00:00 2001 From: mrfry Date: Tue, 4 May 2021 10:34:36 +0200 Subject: [PATCH] Added missing searchBar files --- src/components/searchBar.js | 28 ++++++++++++++++++++++++++++ src/components/searchBar.module.css | 18 ++++++++++++++++++ 2 files changed, 46 insertions(+) create mode 100644 src/components/searchBar.js create mode 100644 src/components/searchBar.module.css diff --git a/src/components/searchBar.js b/src/components/searchBar.js new file mode 100644 index 0000000..e9f0a63 --- /dev/null +++ b/src/components/searchBar.js @@ -0,0 +1,28 @@ +import React from 'react' + +import styles from './searchBar.module.css' + +export default function SearchBar({ searchTerm, onChange }) { + return ( +
+
+ { + onChange(event.target.value) + }} + /> + +
+
+ ) +} diff --git a/src/components/searchBar.module.css b/src/components/searchBar.module.css new file mode 100644 index 0000000..983af43 --- /dev/null +++ b/src/components/searchBar.module.css @@ -0,0 +1,18 @@ +.searchContainer { + width: 100%; + display: flex; + justify-content: center; + margin-left: 10px; + padding-top: 10px; + padding-bottom: 2px; +} + +.clearButton { + width: 50px; + background-color: var(--background-color); + color: white; + font-size: 18px; + cursor: pointer; + border: none; + margin-left: 10px; +}