diff --git a/src/container/AddCredential/dataAttributeCardCredentials.tsx b/src/container/AddCredential/dataAttributeCardCredentials.tsx index 1ca27ab..5c74c45 100644 --- a/src/container/AddCredential/dataAttributeCardCredentials.tsx +++ b/src/container/AddCredential/dataAttributeCardCredentials.tsx @@ -23,6 +23,17 @@ interface Props { export const DataAttributeCardForDDA = (props: Props) => { const { selectedData } = props; + const splitByDotAndGetLastWord = (text) => { + const parts = text.split("."); + const lastValue = parts[parts.length - 1]; + return lastValue + } + + const camelCaseToWords = (str) => { + const words = str.match(/[A-Z]*[^A-Z]+/g); + return words.map(word => word.charAt(0).toUpperCase() + word.slice(1)).join(' '); + }; + return ( { }} > - {attribute.attribute} + {camelCaseToWords(splitByDotAndGetLastWord(attribute.attribute))} {attribute.value} diff --git a/src/container/DDAgreements/ddaTable.jsx b/src/container/DDAgreements/ddaTable.jsx index d94e2fb..6212031 100644 --- a/src/container/DDAgreements/ddaTable.jsx +++ b/src/container/DDAgreements/ddaTable.jsx @@ -47,15 +47,15 @@ const DDAtable = ({ const getStatus = (status) => { if (status === "unlisted") { - return "Unlisted"; + return "Unlist"; } else if (status === "awaitingForApproval") { - return "In Review"; + return "Review"; } else if (status === "approved") { - return "Approved"; + return "Approve"; } else if (status === "rejected") { - return "Rejected"; + return "Reject"; } else if (status === "listed") { - return "Listed"; + return "List"; } }; @@ -89,7 +89,7 @@ const DDAtable = ({ }} > diff --git a/src/container/DDAgreements/index.tsx b/src/container/DDAgreements/index.tsx index eefdbb4..e6faae9 100644 --- a/src/container/DDAgreements/index.tsx +++ b/src/container/DDAgreements/index.tsx @@ -141,9 +141,9 @@ const DDAgreements = () => { - Status + Status Action: *