From fc2d42cf857f695a8c23785d9f3cd2ef6d7e0d6d Mon Sep 17 00:00:00 2001 From: prasadgkalamkar Date: Tue, 3 Dec 2024 19:11:44 +0530 Subject: [PATCH 01/10] Fix for orgDid missing value (#831) * Fix for orgDid missing value Signed-off-by: prasadgkalamkar * CREDEBL-176: optional chaining added Signed-off-by: prasadgkalamkar * optional chaining corrected Signed-off-by: prasadgkalamkar * refactored logic for orgAgentList and orgDid Signed-off-by: prasadgkalamkar --------- Signed-off-by: prasadgkalamkar --- src/components/User/UserDashBoard.tsx | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/src/components/User/UserDashBoard.tsx b/src/components/User/UserDashBoard.tsx index 5c6f5b547..ee3b53c97 100644 --- a/src/components/User/UserDashBoard.tsx +++ b/src/components/User/UserDashBoard.tsx @@ -273,15 +273,17 @@ const UserDashBoard = () => { const response = await getOrganizationById(orgId); const { data } = response as AxiosResponse; if (data?.statusCode === apiStatusCodes.API_STATUS_SUCCESS) { - const orgDid = data?.data?.org_agents[0].orgDid - if (data?.data?.org_agents) { + const orgAgentsList = data?.data?.org_agents; + if (orgAgentsList && orgAgentsList.length > 0) { + const orgDid = orgAgentsList[0].orgDid; setWalletData(data?.data?.org_agents); + + if(orgDid?.includes(DidMethod.INDY)){ + setIsW3C(false); + } } else { setWalletData([]); } - if(orgDid.includes(DidMethod.INDY)){ - setIsW3C(false); - } } setWalletLoading(false); }; From 4fee41708e491f38ac2f4b11fb3278eda19c1b83 Mon Sep 17 00:00:00 2001 From: bhavanakarwade Date: Wed, 4 Dec 2024 16:52:19 +0530 Subject: [PATCH 02/10] fix: solved react minified error (#833) Signed-off-by: bhavanakarwade --- src/components/Profile/DisplayProfileImg.tsx | 7 +++++-- src/components/Profile/DisplayUser.tsx | 11 +++++++---- 2 files changed, 12 insertions(+), 6 deletions(-) diff --git a/src/components/Profile/DisplayProfileImg.tsx b/src/components/Profile/DisplayProfileImg.tsx index bebfd4d53..36e80fef8 100644 --- a/src/components/Profile/DisplayProfileImg.tsx +++ b/src/components/Profile/DisplayProfileImg.tsx @@ -11,8 +11,11 @@ const DisplayProfileImg = () => { const userProfile = await getFromLocalStorage(storageKeys.USER_PROFILE) const orgRoles = await getFromLocalStorage(storageKeys.ORG_ROLES) const parsedUser = userProfile ? JSON.parse(userProfile) : null; - parsedUser.roles = orgRoles - setUserObj(parsedUser) + + if (parsedUser) { + parsedUser.roles = orgRoles; + setUserObj(parsedUser); + } } useEffect(() => { diff --git a/src/components/Profile/DisplayUser.tsx b/src/components/Profile/DisplayUser.tsx index 83a704006..fbc238f09 100644 --- a/src/components/Profile/DisplayUser.tsx +++ b/src/components/Profile/DisplayUser.tsx @@ -13,8 +13,11 @@ const DisplayUser = () => { const userProfile = await getFromLocalStorage(storageKeys.USER_PROFILE) const orgRoles = await getFromLocalStorage(storageKeys.ORG_ROLES) const parsedUser = userProfile ? JSON.parse(userProfile) : null - parsedUser.roles = orgRoles - setUserObj(parsedUser) + + if (parsedUser) { + parsedUser.roles = orgRoles; + setUserObj(parsedUser); + } } useEffect(() => { const fetchData = async () => { @@ -39,10 +42,10 @@ const DisplayUser = () => { className="text-xl font-medium text-gray-900 truncate dark:text-gray-300 mb-1" role="none" > - {userObj['firstName']} + {userObj?.['firstName']}

- {userObj['email']} + {userObj?.['email']}

Date: Thu, 5 Dec 2024 06:12:20 +0000 Subject: [PATCH 03/10] [Deno Deploy] Update .github/workflows/deploy.yml From d016727c19eb3c130c5fbee264f96c93c37df984 Mon Sep 17 00:00:00 2001 From: "deno-deploy[bot]" <75045203+deno-deploy[bot]@users.noreply.github.com> Date: Thu, 5 Dec 2024 13:42:34 +0000 Subject: [PATCH 04/10] [Deno Deploy] Update .github/workflows/deploy.yml From 34e0065376f9f4ca166d089edfb15d0ea32c6b41 Mon Sep 17 00:00:00 2001 From: "deno-deploy[bot]" <75045203+deno-deploy[bot]@users.noreply.github.com> Date: Mon, 9 Dec 2024 11:46:05 +0000 Subject: [PATCH 05/10] [Deno Deploy] Update .github/workflows/deploy.yml From c3f25bc141fb887ac9f4da2dd3e291a24960e6fd Mon Sep 17 00:00:00 2001 From: prasadgkalamkar Date: Mon, 9 Dec 2024 17:54:39 +0530 Subject: [PATCH 06/10] fix:org did not found issue resolved in issuance flow (#835) * org did not foud issue resolved in issuance flow Signed-off-by: prasadgkalamkar * org did not found check Signed-off-by: prasadgkalamkar --------- Signed-off-by: prasadgkalamkar --- src/components/Issuance/IssuedCrdentials.tsx | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/src/components/Issuance/IssuedCrdentials.tsx b/src/components/Issuance/IssuedCrdentials.tsx index 95ebd77c0..b10b846d6 100644 --- a/src/components/Issuance/IssuedCrdentials.tsx +++ b/src/components/Issuance/IssuedCrdentials.tsx @@ -170,14 +170,15 @@ const CredentialList = () => { const response = await getOrganizationById(orgId); const { data } = response as AxiosResponse; if (data?.statusCode === apiStatusCodes.API_STATUS_SUCCESS) { - const did = data?.data?.org_agents?.[0]?.orgDid; - - await setToLocalStorage(storageKeys.ORG_DID, did) - if (did.includes(DidMethod.POLYGON) || did.includes(DidMethod.KEY) || did.includes(DidMethod.WEB)) { - setW3CSchema(true); - } - if (did.includes(DidMethod.INDY)) { - setW3CSchema(false); + const did = data?.data?.org_agents[0]?.orgDid; + if (did) { + await setToLocalStorage(storageKeys.ORG_DID, did) + if (did.includes(DidMethod.POLYGON) || did.includes(DidMethod.KEY) || did.includes(DidMethod.WEB)) { + setW3CSchema(true); + } + if (did.includes(DidMethod.INDY)) { + setW3CSchema(false); + } } } setLoading(false); From 0a915ef39a601e843d8619ab9ce9ffd7ff9c1a6a Mon Sep 17 00:00:00 2001 From: "deno-deploy[bot]" <75045203+deno-deploy[bot]@users.noreply.github.com> Date: Thu, 12 Dec 2024 13:29:30 +0000 Subject: [PATCH 07/10] [Deno Deploy] Update .github/workflows/deploy.yml From ca8e274d0867c1b1d307dbed6764d4352cf261e8 Mon Sep 17 00:00:00 2001 From: "deno-deploy[bot]" <75045203+deno-deploy[bot]@users.noreply.github.com> Date: Tue, 17 Dec 2024 08:18:51 +0000 Subject: [PATCH 08/10] [Deno Deploy] Update .github/workflows/deploy.yml From 96358e246a16a0771681031e68eead3cfdd64cdd Mon Sep 17 00:00:00 2001 From: "deno-deploy[bot]" <75045203+deno-deploy[bot]@users.noreply.github.com> Date: Wed, 18 Dec 2024 09:37:05 +0000 Subject: [PATCH 09/10] [Deno Deploy] Update .github/workflows/deploy.yml From a90f0f8653b3ade5821c34162f8f18c996c57afa Mon Sep 17 00:00:00 2001 From: prasadgkalamkar Date: Thu, 19 Dec 2024 16:53:12 +0530 Subject: [PATCH 10/10] fix: Added fix for qr code download link mismatch data type (#837) * org did not foud issue resolved in issuance flow Signed-off-by: prasadgkalamkar * Removed unwanted files Signed-off-by: prasadgkalamkar * Added fix for qr code download link mismatch data type Signed-off-by: prasadgkalamkar --------- Signed-off-by: prasadgkalamkar --- src/commonComponents/QRcode.tsx | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/commonComponents/QRcode.tsx b/src/commonComponents/QRcode.tsx index 4d51e1099..3bf1864d4 100644 --- a/src/commonComponents/QRcode.tsx +++ b/src/commonComponents/QRcode.tsx @@ -4,7 +4,8 @@ import domtoimage from 'dom-to-image'; const CustomQRCode = ({ value, size }: { value: string, size: number }) => { - const inputRef = useRef(null); + const node = document.createTextNode(''); + const inputRef = useRef(node); const [isCopied, setIsCopied] = useState(false); function copyTextVal(e: React.MouseEvent) { @@ -24,7 +25,7 @@ const CustomQRCode = ({ value, size }: { value: string, size: number }) => { } const drawHtmlToCanvas = () => { - domtoimage.toJpeg(inputRef.current, { quality: 0.95 }) + domtoimage.toJpeg(inputRef.current, { quality: 0.95 }) .then(function (dataUrl) { var link = document.createElement('a'); link.download = 'my-image-name.jpeg';