From 6d764fc1fb0a689edda9d7cccbe042e90b5479e3 Mon Sep 17 00:00:00 2001 From: Adarsh Kumar Singh Date: Sun, 3 Mar 2024 23:57:02 +0530 Subject: [PATCH] Add files via upload Implemented search functionality in dashboard page --- Dashboard.jsx | 39 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100644 Dashboard.jsx diff --git a/Dashboard.jsx b/Dashboard.jsx new file mode 100644 index 0000000..60b69d2 --- /dev/null +++ b/Dashboard.jsx @@ -0,0 +1,39 @@ +import Userbar from "./Userbar" +import imgPath from "../assets/user-dp.jpg" +import { useState } from "react"; + +function Dashboard(){ + const [searchText,setSearchText]=useState(''); + const users=["Ajeet","Ajay","Karn","Priya","Neha"]; + + const searchResult=users.filter(e=>e.toLowerCase().includes(searchText.toLowerCase())); + return ( +
+
+

IndiaPay

+
+

Namaste, User

+ +
+
+
+

Your Balance

+

{`₹1500`}

+
+

Users

+ +
+ { + searchResult.map((e,index)=>( + + )) + } +
+
+ + ); +} + +export default Dashboard; \ No newline at end of file