Skip to content

Commit

Permalink
Fix blank page (#160)
Browse files Browse the repository at this point in the history
* Hardcode currency locale

* Fix repay notice
  • Loading branch information
noisekit authored Jan 21, 2025
1 parent c17eb86 commit 5e62b3c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 28 deletions.
2 changes: 1 addition & 1 deletion liquidity/lib/format/currency.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ export function currency(

return isNaN(numberValue)
? stringValue
: numberValue.toLocaleString(navigator.language, {
: numberValue.toLocaleString('en-US', {
minimumFractionDigits: 0,
maximumFractionDigits,
...options,
Expand Down
30 changes: 3 additions & 27 deletions liquidity/ui/src/components/Undelegate/Undelegate.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -387,35 +387,11 @@ export function Undelegate() {

{network?.preset === 'andromeda' && liquidityPosition ? (
<Collapse in={liquidityPosition.debt.gt(0)} animateOpacity unmountOnExit>
<Alert status="error" mb="6" borderRadius="6px">
<Alert status="info" mb="6" borderRadius="6px">
<AlertIcon />
<Text>
To unlock this amount, you need to{' '}
<Link
href={`?${makeSearch({
page: 'position',
collateralSymbol: params.collateralSymbol,
manageAction: 'repay',
accountId: params.accountId,
})}`}
onClick={(e) => {
e.preventDefault();
setParams({
page: 'position',
collateralSymbol: params.collateralSymbol,
manageAction: 'repay',
accountId: params.accountId,
});
}}
textDecoration="underline"
>
<Amount
prefix=" repay "
value={liquidityPosition.debt}
suffix={` ${liquidityPosition.collateralType.symbol}`}
/>
</Link>{' '}
to your position
<Amount prefix="You will repay " value={liquidityPosition.debt} suffix=" USDC" /> to
unlock {liquidityPosition.collateralType.displaySymbol}
</Text>
</Alert>
</Collapse>
Expand Down

0 comments on commit 5e62b3c

Please sign in to comment.