From 4ef272053bb7c4e3612c0907fb8b4360210465df Mon Sep 17 00:00:00 2001 From: Nilesh Gupta Date: Tue, 19 Mar 2024 16:59:56 +0530 Subject: [PATCH 1/2] Resolved users NFT claiming issue --- src/helpers/AlphaAccessNftHelper.ts | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/src/helpers/AlphaAccessNftHelper.ts b/src/helpers/AlphaAccessNftHelper.ts index 02830e9ad4..8fd6c59222 100644 --- a/src/helpers/AlphaAccessNftHelper.ts +++ b/src/helpers/AlphaAccessNftHelper.ts @@ -1,5 +1,5 @@ -import { MerkleTree } from "merkletreejs"; -import { ethers } from "ethers"; +import { MerkleTree } from 'merkletreejs'; +import { ethers } from 'ethers'; // Internal Configs import whitelistAddressesList from 'config/alphaAccessNft/whitelist.json'; @@ -22,12 +22,12 @@ const AlphaAccessNFTHelper: AlphaAccessNFTHelper = { async getProof(userWalletAddress: string): Promise { let proof: string[] = []; - - if (whitelistAddressesList.includes(userWalletAddress)) { + const userAddress = userWalletAddress.toLowerCase(); + if (whitelistAddressesList.includes(userAddress)) { const { keccak256 } = ethers.utils; let leaves = whitelistAddressesList.map((addr) => keccak256(addr)); const merkleTree = new MerkleTree(leaves, keccak256, { sortPairs: true }); - let hashedAddress = keccak256(userWalletAddress); + let hashedAddress = keccak256(userAddress); proof = merkleTree.getHexProof(hashedAddress); } return proof; @@ -35,9 +35,10 @@ const AlphaAccessNFTHelper: AlphaAccessNFTHelper = { async verify(userWalletAddress: string): Promise { const { keccak256 } = ethers.utils; + const userAddress = userWalletAddress.toLowerCase(); let leaves = whitelistAddressesList.map((addr) => keccak256(addr)); const merkleTree = new MerkleTree(leaves, keccak256, { sortPairs: true }); - let hashedAddress = keccak256(userWalletAddress); + let hashedAddress = keccak256(userAddress); const merkleRootHash = merkleTree.getHexRoot(); let proof = merkleTree.getHexProof(hashedAddress); From af0aefb9a26f72335b46e4563a54b92bff13fb76 Mon Sep 17 00:00:00 2001 From: Nilesh Gupta Date: Tue, 19 Mar 2024 17:01:24 +0530 Subject: [PATCH 2/2] Resolved ios native browser text css issue --- src/config/Themization.js | 25 +++-- src/structure/Navigation.tsx | 195 ++++++++++++++++++++++------------- 2 files changed, 134 insertions(+), 86 deletions(-) diff --git a/src/config/Themization.js b/src/config/Themization.js index 21cfb05225..39defc75ef 100644 --- a/src/config/Themization.js +++ b/src/config/Themization.js @@ -11,7 +11,7 @@ const themeLight = { secondaryColor: '#657795', hover: '#F3F3FF', borderColor: '#dfdee9', - primaryPushThemeTextColor: '#cf1c84' + primaryPushThemeTextColor: '#cf1c84', }, // Login Theme @@ -44,8 +44,8 @@ const themeLight = { }, btn: { - disabledBg: "#E0E3E7", - disabledColor: "#BEC8D8" + disabledBg: '#E0E3E7', + disabledColor: '#BEC8D8', }, // Default Background Theme @@ -182,7 +182,7 @@ const themeLight = { toastSuccessBackground: 'linear-gradient(90.15deg, #30CC8B -125.65%, #30CC8B -125.63%, #F3FFF9 42.81%)', toastErrorBackground: 'linear-gradient(90.15deg, #FF2070 -125.65%, #FF2D79 -125.63%, #FFF9FB 42.81%)', - toastWarningBackground:'linear-gradient(90deg, #FFF2D1 0%, rgba(255, 255, 255, 0.00) 100%)', + toastWarningBackground: 'linear-gradient(90deg, #FFF2D1 0%, rgba(255, 255, 255, 0.00) 100%)', // Profile profileBG: 'linear-gradient(107deg, rgba(226,8,128,1) 30%, rgba(103,76,159,1) 70%, rgba(53,197,243,1) 100%)', @@ -260,13 +260,13 @@ const themeLight = { spaceHostTextColor: '#1e1e1e', spaceTheme: { - titleBg: 'linear-gradient(45deg, #E165EC 0.01%, #A483ED 100%)',//not changed + titleBg: 'linear-gradient(45deg, #E165EC 0.01%, #A483ED 100%)', //not changed titleTextColor: '#FFFFFF', bgColorPrimary: 'red', bgColorSecondary: '#F7F1FB', textColorPrimary: '#000', textColorSecondary: '#657795', - textGradient: 'linear-gradient(45deg, #B6A0F5, #F46EF6, #FFDED3, #FFCFC5)',//not changed + textGradient: 'linear-gradient(45deg, #B6A0F5, #F46EF6, #FFDED3, #FFCFC5)', //not changed btnColorPrimary: '#D53A94', btnOutline: '#D53A94', borderColor: '#FFFF', @@ -296,7 +296,7 @@ const themeLight = { //collapsable sidebar collapsaBg: '#575d737f', - strokeColor: '#FFF' + svgStrokeColor: '#FFF', }; const themeDark = { @@ -311,7 +311,7 @@ const themeDark = { secondaryColor: '#B6BCD6', hover: '#00000033', borderColor: '#4A4F67', - primaryPushThemeTextColor: '#cf1c84' + primaryPushThemeTextColor: '#cf1c84', }, // Login Theme @@ -344,8 +344,8 @@ const themeDark = { }, btn: { - disabledBg: "#383A40", - disabledColor: "#545F74" + disabledBg: '#383A40', + disabledColor: '#545F74', }, // Header Theme @@ -483,8 +483,7 @@ const themeDark = { toastShadowColor: '#00000010', toastSuccessBackground: 'linear-gradient(90.15deg, #30CC8B -125.65%, #30CC8B -125.63%, #2F3137 42.81%)', toastErrorBackground: 'linear-gradient(89.96deg, #FF2070 -101.85%, #2F3137 51.33%)', - toastWarningBackground:'linear-gradient(90deg, #66562D 0.03%, #2F3137 74.67%)', - + toastWarningBackground: 'linear-gradient(90deg, #66562D 0.03%, #2F3137 74.67%)', //Profile profileBG: '#2F3137', @@ -601,7 +600,7 @@ const themeDark = { //collapsable sidebar collapsaBg: '#0000004c', - strokeColor: '#575D73' + svgStrokeColor: '#575D73', }; module.exports = { diff --git a/src/structure/Navigation.tsx b/src/structure/Navigation.tsx index ab88f0a197..83bec6877d 100644 --- a/src/structure/Navigation.tsx +++ b/src/structure/Navigation.tsx @@ -402,9 +402,20 @@ function Navigation() { // dispatch(setDeveloperOpen(false)) // } let innerRendered = ( -
+
{secondaryButton ? ( - + {section.hasItems ? renderChildItems(data.drilldown, section.opened, GLOBALS.CONSTANTS.NAVBAR_SECTIONS.PRIMARY) : null} @@ -418,47 +429,54 @@ function Navigation() { onClick={() => { mutateTransformedList(section, true); }} - id={data.id}> - - + id={data.id} + > + - {data.name == "More" && - {sidebarCollapsed ? 'Expand Sidebar' : 'Minimize Sidebar'} - - } - > - setSidebarCollapsed(!sidebarCollapsed)} + {data.name == 'More' && ( + {sidebarCollapsed ? 'Expand Sidebar' : 'Minimize Sidebar'}} > - {sidebarCollapsed ? : } - - } - + setSidebarCollapsed(!sidebarCollapsed)} + > + {sidebarCollapsed ? : } + + + )} ) : ( - + - + }} + > + {/* { @@ -504,9 +528,8 @@ function Navigation() { : null } */} - ) - } -
+ )} +
); return innerRendered; @@ -531,12 +554,22 @@ function Navigation() { } let rendered = ( - + {Object.keys(drilldown).map(function (key) { const item = drilldown[key]; const data = item.data; return ( - + - + }} + > + ); @@ -572,10 +611,19 @@ function Navigation() { }; return ( - + {!navigationSetup && ( - - + + )} {navigationSetup && Object.keys(navigationSetup).length > 0 && ( @@ -588,14 +636,18 @@ function Navigation() { weight="700" size="11px" margin="20px 0px 0px 0px" - padding={sidebarCollapsed ? "15px 25px" : "15px 30px"} + padding={sidebarCollapsed ? '15px 25px' : '15px 30px'} color="#575D73" - spacing="0.16em"> + spacing="0.16em" + > {sidebarCollapsed ? 'Devs' : 'Developers'} {renderMainItems(navigationSetup.secondary, GLOBALS.CONSTANTS.NAVBAR_SECTIONS.SECONDARY)} -