diff --git a/src/commonComponents/SchemaCard.tsx b/src/commonComponents/SchemaCard.tsx index 2daec6cb4..c2a1a0d22 100644 --- a/src/commonComponents/SchemaCard.tsx +++ b/src/commonComponents/SchemaCard.tsx @@ -1,7 +1,7 @@ import { Card } from 'flowbite-react'; import { dateConversion } from '../utils/DateConversion'; -const SchemaCard = (props: { schemaName: string, version: string, schemaId: string, issuerDid: string, attributes: string[], created: string, onClickCallback: (schemaId: string, attributes: string[], issuerDid:string, created:string) => void; },) => { +const SchemaCard = (props: {className:string, schemaName: string, version: string, schemaId: string, issuerDid: string, attributes: string[], created: string, onClickCallback: (schemaId: string, attributes: string[], issuerDid:string, created:string) => void; },) => { return ( { props.onClickCallback(props.schemaId, props.attributes, props.issuerDid, props.created) diff --git a/src/commonComponents/datatable/index.tsx b/src/commonComponents/datatable/index.tsx index a5ea4f3ef..6a1d8afec 100644 --- a/src/commonComponents/datatable/index.tsx +++ b/src/commonComponents/datatable/index.tsx @@ -1,5 +1,5 @@ import type { TableData, TableHeader } from "./interface" -import { Spinner, Tooltip } from "flowbite-react"; +import { Button, Spinner, Tooltip } from "flowbite-react"; interface DataTableProps { header: TableHeader[]; @@ -7,9 +7,10 @@ interface DataTableProps { loading: boolean; callback?: (clickId: string | null | undefined) => void; displaySelect?:boolean; + showBtn?:boolean } -const DataTable: React.FC = ({ header,displaySelect, data, loading, callback }) => { +const DataTable: React.FC = ({ header,displaySelect, data, loading, callback ,showBtn}) => { return (
@@ -43,7 +44,7 @@ const DataTable: React.FC = ({ header,displaySelect, data, loadi {data.length ? data.map((ele, index) => ( - callback ? callback(ele?.clickId) : ''}> + {ele.data.map(subEle => ( @@ -51,9 +52,9 @@ const DataTable: React.FC = ({ header,displaySelect, data, loadi {subEle.subData && subEle.subData} ))} - {displaySelect && + {displaySelect || showBtn && - } + } )) : Empty data} diff --git a/src/components/Issuance/CredDefSelection.tsx b/src/components/Issuance/CredDefSelection.tsx index 7015ea9b7..2dc1634c1 100644 --- a/src/components/Issuance/CredDefSelection.tsx +++ b/src/components/Issuance/CredDefSelection.tsx @@ -114,8 +114,11 @@ const CredDefSelection = () => { color="info" />
- : } + : +
+ +
}
@@ -130,7 +133,7 @@ const CredDefSelection = () => { setError(null) }} /> - +
) }