diff --git a/src/components/ReactTable4/BasicTable.js b/src/components/ReactTable4/BasicTable.js
index 3cfbdc9..c08ce5c 100644
--- a/src/components/ReactTable4/BasicTable.js
+++ b/src/components/ReactTable4/BasicTable.js
@@ -65,7 +65,6 @@ const BasicTable = ({ settingsIcon }) => {
columns,
data,
defaultColumn,
- // initialState: { pageIndex: 2 }
},
useColumnOrder,
useFilters,
@@ -107,18 +106,6 @@ const BasicTable = ({ settingsIcon }) => {
// const firstPageRows = rows.slice(0, 10);
return (
<>
- {/* filter */}
- {/*
- {headerGroups.map((headerGroup) =>
- headerGroup.headers.map((column) =>
- column.Filter ? (
-
- {column.render("Filter")}
-
- ) : null
- )
- )}
-
*/}
{/* toggle columns */}
{/*
@@ -197,15 +184,18 @@ const BasicTable = ({ settingsIcon }) => {
))}
- {/*
{column.canFilter ? column.render("Filter") : null}
*/}
))}
-
+ {/* filters */}
+
{headerGroups.map((headerGroup) => (
{headerGroup.headers.map((column) => (
-
+ |
{column.canFilter ? column.render("Filter") : null}
|
))}
diff --git a/src/components/ReactTable4/ColumnSearch.js b/src/components/ReactTable4/ColumnSearch.js
index 2b14c36..2410238 100644
--- a/src/components/ReactTable4/ColumnSearch.js
+++ b/src/components/ReactTable4/ColumnSearch.js
@@ -1,14 +1,36 @@
-import React from "react";
+import React, { useState } from "react";
+
+import search from "./search-normal.svg";
+import settings from "./settings.svg";
export const ColumnSearch = ({ column }) => {
const { filterValue, setFilter } = column;
+ const [activeSearchBox, setActiveSearchBox] = useState(false);
return (
-
- setFilter(e.target.value)}
- />
-
+
+
+ {activeSearchBox && (
+
setActiveSearchBox(false)}
+ />
+ )}
+
+
setFilter(e.target.value)}
+ onFocus={() => setActiveSearchBox(true)}
+ className={`text-xs text-blue-400 rounded focus:outline-none placeholder-blue-400 border p-1`}
+ style={{ backgroundColor: "#F9FBFF", borderColor: "#B5D6FF" }}
+ />
+
+
);
};