Skip to content

Commit

Permalink
Merge pull request #269 from mayuran-deriv/mayuran/new-accout-switche…
Browse files Browse the repository at this point in the history
…r-tools

fix: account switcher
  • Loading branch information
shayan-deriv authored Nov 26, 2024
2 parents 1a6aa3b + 65a97d0 commit f455526
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@
&--mobile {
width: 90vw;
position: unset;
min-height: 400px;
height: auto;
border-radius: 4px;
}
Expand Down
5 changes: 5 additions & 0 deletions src/components/AppLayout/AccountSwitcher/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,9 @@ type AccountSwitcherProps = {
demo: string;
real: string;
};
modalContentStyle?: {
content?: React.CSSProperties;
};
};

export const AccountSwitcher = ({
Expand All @@ -39,6 +42,7 @@ export const AccountSwitcher = ({
isDisabled = false,
buttonClassName,
tabsLabels,
modalContentStyle,
}: AccountSwitcherProps) => {
const [isOpen, setIsOpen] = useState(false);
const ref = useRef(null);
Expand Down Expand Up @@ -110,6 +114,7 @@ export const AccountSwitcher = ({
}}
className="deriv-account-switcher__container--mobile"
isOpen={isOpen}
style={modalContentStyle ?? {}}
>
{children && (
<Tabs
Expand Down

0 comments on commit f455526

Please sign in to comment.