From 8f6b394149ab78c7efd2472abf43881c18bbd3ef Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cosmin=20P=C3=A2rvulescu?= Date: Wed, 22 Nov 2023 16:15:16 +0200 Subject: [PATCH] fix(console): Group invite account type dropdown doesn't pop over the modal (#2771) --- .../routes/__layout/groups/$groupID/index.tsx | 82 +++++++++++-------- .../src/helpers/get-provider-icons.ts | 1 + .../src/molecules/modal/Modal.tsx | 5 +- 3 files changed, 51 insertions(+), 37 deletions(-) diff --git a/apps/console/app/routes/__layout/groups/$groupID/index.tsx b/apps/console/app/routes/__layout/groups/$groupID/index.tsx index 8f6cdfed88..b35b206a5c 100644 --- a/apps/console/app/routes/__layout/groups/$groupID/index.tsx +++ b/apps/console/app/routes/__layout/groups/$groupID/index.tsx @@ -151,7 +151,11 @@ const InviteMemberModal = ({ }, [invitations, selectedProvider, identifier]) return ( - +
@@ -226,42 +230,48 @@ const InviteMemberModal = ({ className="absolute bg-white p-2 flex flex-col gap-2 mt-1 focus-visible:ring-0 focus-visible:outline-none border shadow" static > - {accountTypes.map((provider) => ( - - classNames( - 'flex flex-row items-center gap-2 hover:bg-gray-100 py-2 px-4 rounded-lg cursor-pointer', - { - 'bg-gray-100': active, - } - ) - } - > - {({ selected }) => ( - <> - - - {_.upperFirst(provider)} - - {selected && ( - + ))}
diff --git a/packages/design-system/src/helpers/get-provider-icons.ts b/packages/design-system/src/helpers/get-provider-icons.ts index 0a261da676..1d2d71dabf 100644 --- a/packages/design-system/src/helpers/get-provider-icons.ts +++ b/packages/design-system/src/helpers/get-provider-icons.ts @@ -21,6 +21,7 @@ export default (provider: string) => { case 'webauthn': return webauthn case 'ethereum': + case 'eth': return ethereum case 'facebook': return facebook diff --git a/packages/design-system/src/molecules/modal/Modal.tsx b/packages/design-system/src/molecules/modal/Modal.tsx index 5cf757d6d2..de811ed216 100644 --- a/packages/design-system/src/molecules/modal/Modal.tsx +++ b/packages/design-system/src/molecules/modal/Modal.tsx @@ -8,11 +8,13 @@ export type ModalProps = { isOpen: boolean handleClose?: (value: boolean) => void fixed?: boolean + overflowAbsolute?: boolean } export const Modal = ({ isOpen = false, fixed = false, + overflowAbsolute = false, handleClose, children, ...rest @@ -52,8 +54,9 @@ export const Modal = ({