From 6f2fb3900eda0406ab9bf09a7ad4a675b0de29d7 Mon Sep 17 00:00:00 2001 From: Keannu Bernasol Date: Sun, 17 Dec 2023 23:29:10 +0800 Subject: [PATCH] Center search bar and replace filter text with search icon --- .../EquipmentInstancesListPage.tsx | 71 +++++++++++-------- 1 file changed, 42 insertions(+), 29 deletions(-) diff --git a/src/Pages/EquipmentInstancesListPage/EquipmentInstancesListPage.tsx b/src/Pages/EquipmentInstancesListPage/EquipmentInstancesListPage.tsx index e3b0ee8..b08d26b 100644 --- a/src/Pages/EquipmentInstancesListPage/EquipmentInstancesListPage.tsx +++ b/src/Pages/EquipmentInstancesListPage/EquipmentInstancesListPage.tsx @@ -15,6 +15,7 @@ import EditItemModal from "../../Components/EditItemInstanceModal/EditItemInstan import { useState } from "react"; import Popup from "reactjs-popup"; import Autocomplete from "@mui/material/Autocomplete"; +import SearchIcon from "@mui/icons-material/Search"; export default function EquipmentInstancesListPage() { const [editmodalOpen, SetEditModalOpen] = useState(false); @@ -67,36 +68,48 @@ export default function EquipmentInstancesListPage() { flexWrap: "wrap", }} > -
-

Filter:

- - theme.palette.getContrastText(theme.palette.background.paper), - }, +
+
{ - setFilter(newValue); - }} - freeSolo - id="custom-input-demo" - options={["Available", "Broken", "Glassware", "Miscellaneous"]} - renderInput={(params) => ( -
- -
- )} - /> + > + + + theme.palette.getContrastText( + theme.palette.background.paper + ), + }, + }} + value={filter} + onChange={(_event, newValue) => { + setFilter(newValue); + }} + freeSolo + id="custom-input-demo" + options={["Available", "Broken", "Glassware", "Miscellaneous"]} + renderInput={(params) => ( +
+ +
+ )} + /> +