Skip to content

Commit

Permalink
Merge pull request #2426 from Giveth/develop
Browse files Browse the repository at this point in the history
HOTFIX: xDAI token balance not appearing
  • Loading branch information
MohammadPCh authored Mar 28, 2023
2 parents 0dec243 + 7ec7e8e commit 42ed104
Show file tree
Hide file tree
Showing 6 changed files with 15 additions and 13 deletions.
4 changes: 2 additions & 2 deletions lang/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -987,7 +987,7 @@
"label.get_giv_token": "Get GIV Token",
"label.use_your_giv": "Use your GIV",
"label.explore_by": "Explore by",
"label.by_category": "by category",
"label.category": "category",
"label.proud_of_our_partners": "Proud of our partners",
"label.awesome_project_updates": "Awesome Project Updates",
"label.amount_to_stake": "Amount to stake",
Expand Down Expand Up @@ -1058,7 +1058,7 @@
"label.oldest": "Oldest",
"label.most_liked": "Most liked",
"label.most_funded": "Most funded",
"label.recently_updated": "RecentlyUpdated",
"label.recently_updated": "Recently Updated",
"label.sort_by": "Sort by",
"label.an_economy_of_giving": "An Economy of Giving",
"label.governance": "Governance",
Expand Down
2 changes: 1 addition & 1 deletion lang/es.json
Original file line number Diff line number Diff line change
Expand Up @@ -994,7 +994,7 @@
"label.get_giv_token": "Obtén GIV Tokens",
"label.use_your_giv": "Utiliza tu GIV",
"label.explore_by": "Explorar por",
"label.by_category": "Por Categoría",
"label.category": "Categoría",
"label.proud_of_our_partners": "Orgullosos de nuestros socios",
"label.awesome_project_updates": "Actualizaciones Geniales de Proyectos",
"label.amount_to_stake": "Monto para stake",
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "givethdapp",
"version": "2.12.1",
"version": "2.12.2",
"private": true,
"scripts": {
"build": "next build",
Expand Down
6 changes: 2 additions & 4 deletions src/components/menu/ProjectsItems.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ import Routes from '@/lib/constants/Routes';
const projectsItems = {
explore: [
// { name: 'Trending', query: '?q=?q=trending' },
{ name: 'All Projects', query: '', label: 'label.all_projects' },
{
name: 'Recently Updated',
query: '?sort=' + EProjectsSortBy.RECENTLY_UPDATED,
Expand All @@ -24,7 +25,6 @@ const projectsItems = {
label: 'label.just_launched',
},
// { name: 'Popular', query: '?q=popular' },
{ name: 'All Projects', query: '', label: 'label.all_projects' },
],
};

Expand Down Expand Up @@ -59,9 +59,7 @@ export const ProjectsItems: FC<IProjectsItems> = ({ inSidebar = false }) => {
</ExploreByRow>
</HighlightSection>
<NormalSection inSidebar={inSidebar}>
<Label medium>
{formatMessage({ id: 'label.by_category' })}
</Label>
<Label medium>{formatMessage({ id: 'label.category' })}</Label>
<CategoriesGrid inSidebar={inSidebar}>
{mainCategories.map((category, idx) => (
<Link
Expand Down
12 changes: 8 additions & 4 deletions src/components/views/donate/CryptoDonation.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -192,11 +192,15 @@ const CryptoDonation: FC = () => {
return setSelectedTokenBalance(undefined);
}
// Native token balance is provided by the Web3Provider
const _selectedTokenSymbol = selectedToken.symbol.toUpperCase();
if (
selectedToken.symbol === ethereumChain.nativeCurrency.symbol ||
selectedToken.symbol === gnosisChain.nativeCurrency.symbol ||
selectedToken.symbol === polygonChain.nativeCurrency.symbol
// TODO:Optimism || selectedToken.symbol === optimismChain.nativeCurrency.symbol
_selectedTokenSymbol ===
ethereumChain.nativeCurrency.symbol.toUpperCase() ||
_selectedTokenSymbol ===
gnosisChain.nativeCurrency.symbol.toUpperCase() ||
_selectedTokenSymbol ===
polygonChain.nativeCurrency.symbol.toUpperCase()
// TODO:Optimism || _selectedTokenSymbol === optimismChain.nativeCurrency.symbol
) {
return setSelectedTokenBalance(balance);
}
Expand Down
2 changes: 1 addition & 1 deletion src/helpers/blockchain.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ export const networksParams: {
],
nativeCurrency: {
name: 'xDAI',
symbol: 'xDAI',
symbol: 'XDAI',
decimals: 18,
},
blockExplorerUrls: ['https://blockscout.com/xdai/mainnet'],
Expand Down

1 comment on commit 42ed104

@vercel
Copy link

@vercel vercel bot commented on 42ed104 Mar 28, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

giveth-dapps-v2 – ./

giveth-dapps-v2-givethio.vercel.app
giveth-dapps-v2-git-main-givethio.vercel.app
giveth.io
www.giveth.io

Please sign in to comment.