Commit 11a009fc authored by Venkaiah Naidu Singamchetty's avatar Venkaiah Naidu Singamchetty

Merge branch 'apiserver' into 'master'

table if no data available added message'

See merge request !40
parents c4a1b6f3 18eef4c1
......@@ -3,6 +3,7 @@ import Loading from "../loading Component/Loading";
function Table({headers, data,loading, maxHeight}) {
if(loading) return <Loading/>
if(data?.length)
return (
<div className={` overflow-x-auto sm:rounded-lg p-4 max-h-[${maxHeight}vh]`}>
<table className="w-full text-sm text-left rtl:text-right text-gray-500 dark:text-gray-400 bg-transparent justify-center border-separate border-spacing-y-2">
......@@ -34,6 +35,10 @@ function Table({headers, data,loading, maxHeight}) {
</div>
</div>
);
else
return <div className="w-full h-full">
<p className="text-center align-middle mt-28 text-blue-500">No records to display</p>
</div>
}
export default Table;
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment