Skip to content

Commit

Permalink
disable dropdown in update flow
Browse files Browse the repository at this point in the history
  • Loading branch information
jackie2111 committed Sep 6, 2024
1 parent 5a4470c commit ca7f0cd
Showing 1 changed file with 7 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,12 @@ const NetworkDropdown = ({}: Props) => {
setIsOpenDropdown(false);
};

const handleOpenDropdown = () => {
if (isUpdateFlow) return;

setIsOpenDropdown(!isOpenDropdown);
};

const _icon = React.useMemo(
() => getIcon(currentValue?.icon),
[currentValue?.icon],
Expand Down Expand Up @@ -100,7 +106,7 @@ const NetworkDropdown = ({}: Props) => {
<div className={styles.dropdown__inner}>
<div
className={styles.dropdown__inner__content}
onClick={() => setIsOpenDropdown(!isOpenDropdown)}
onClick={() => handleOpenDropdown()}
>
{_icon && <Image src={_icon} width={16} height={16} alt="icon" />}

Expand Down

0 comments on commit ca7f0cd

Please sign in to comment.