Skip to content

Commit

Permalink
Removal of Chain Selection Option in Withdrawal Flow on Destination I…
Browse files Browse the repository at this point in the history
…nput (#1747)
  • Loading branch information
vutuanlinh2k2 authored Oct 6, 2023
1 parent 31e0ed6 commit 0ae283c
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 6 deletions.
5 changes: 4 additions & 1 deletion apps/bridge-dapp/src/pages/Hubble/Bridge/Withdraw/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,10 @@ const Withdraw = () => {
onIsFixedAmountChange={() => setCustomAmount(!isCustom)}
>
<TransactionInputCard.Header>
<TransactionInputCard.ChainSelector onClick={handleChainClick} />
<TransactionInputCard.ChainSelector
onClick={handleChainClick}
disabled
/>
<TransactionInputCard.Button
Icon={<SettingsFillIcon />}
onClick={() => navigate(SELECT_RELAYER_PATH)}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ TransactionInputCardRoot.displayName = 'TransactionInputCardRoot';
const TransactionChainSelector = forwardRef<
React.ElementRef<'button'>,
TransactionChainSelectorProps
>(({ typedChainId: typedChainIdProps, className, ...props }, ref) => {
>(({ typedChainId: typedChainIdProps, className, disabled, ...props }, ref) => {
const context = useContext(TransactionInputCardContext);

const typedChainId = typedChainIdProps ?? context.typedChainId;
Expand All @@ -101,6 +101,7 @@ const TransactionChainSelector = forwardRef<
return (
<button
{...props}
disabled={disabled}
ref={ref}
className={twMerge('flex items-center gap-1 p-2 group', className)}
>
Expand All @@ -117,10 +118,12 @@ const TransactionChainSelector = forwardRef<
</Typography>
</p>

<ChevronDown
size="lg"
className="rounded-lg group-hover:bg-mono-40 dark:group-hover:bg-mono-160"
/>
{!disabled && (
<ChevronDown
size="lg"
className="rounded-lg group-hover:bg-mono-40 dark:group-hover:bg-mono-160"
/>
)}
</button>
);
});
Expand Down

0 comments on commit 0ae283c

Please sign in to comment.