This commit is contained in:
2024-10-14 19:31:26 +05:30
parent 80cc0d8df3
commit a0fa2ea4a7

View File

@@ -17,7 +17,7 @@ import LineChart from "../components/Doughnut/LineChart";
import AmountCard from "../components/AmountCard/AmountCard";
import SwitchCharts from "../components/SwitchBtn/SwitchCharts";
import LatestTransactions from "../components/LatestTransactions/LatestTransactions";
import { Link } from "react-router-dom";
import { Link, useNavigate } from "react-router-dom";
import Pagination from "../components/Pagination";
import bannerImage from "../assets/images/bannerImg.png";
import { BiSearchAlt } from "react-icons/bi";
@@ -25,6 +25,8 @@ import { BiSearchAlt } from "react-icons/bi";
const Home = () => {
const [isSwitchOn, setIsSwitchOn] = useState(true);
const { colorMode, toggleColorMode } = useColorMode();
const [ searchTerm, setSearchTerm] = useState("")
const navigate = useNavigate()
return (
<Box
@@ -105,6 +107,7 @@ const Home = () => {
fontSize={"sm"}
rounded={0}
border="none"
// borderLeft={0}
// borderRight={0}
@@ -122,7 +125,7 @@ const Home = () => {
</Button>
<Box
pointerEvents="none"
// pointerEvents="none"
position={"inherit"}
right={"0"}
h={"42px"}
@@ -134,9 +137,10 @@ const Home = () => {
bg={colorMode === "light" ? "#DEDBEB" : "#393939"}
color={colorMode === "light" ? "#230A79" : "#fff"}
cursor={'pointer'}
// border={`1px solid ${
// colorMode === "light" ? "#230A79" : "#393939"
// }`}
onClick={()=>navigate(`/transaction/${searchTerm}`)}
border={`1px solid ${
colorMode === "light" ? "#230A79" : "#565252"
}`}
>
{/* <IoSearch fontSize={"20px"} /> */}
<BiSearchAlt fontSize={"20px"} />