From 71eef69b96dd964a928e482ee0a8674305e44a2e Mon Sep 17 00:00:00 2001 From: Peter Zimon Date: Wed, 24 May 2023 17:05:21 +0200 Subject: [PATCH] Added static user detail modal in AdminX settings refs. https://github.com/TryGhost/Team/issues/3150 --- .../src/components/modals/UserDetailModal.tsx | 20 +++++++++++++++++++ .../src/components/settings/general/Users.tsx | 11 +++++++--- 2 files changed, 28 insertions(+), 3 deletions(-) create mode 100644 ghost/admin-x-settings/src/components/modals/UserDetailModal.tsx diff --git a/ghost/admin-x-settings/src/components/modals/UserDetailModal.tsx b/ghost/admin-x-settings/src/components/modals/UserDetailModal.tsx new file mode 100644 index 0000000000..9d0d4ace68 --- /dev/null +++ b/ghost/admin-x-settings/src/components/modals/UserDetailModal.tsx @@ -0,0 +1,20 @@ +import Modal from '../../admin-x-ds/global/Modal'; +import NiceModal from '@ebay/nice-modal-react'; + +const UserDetailModal = NiceModal.create(() => { + return ( + { + alert('Clicked OK'); + }} + > +
+ Some user details +
+
+ ); +}); + +export default UserDetailModal; \ No newline at end of file diff --git a/ghost/admin-x-settings/src/components/settings/general/Users.tsx b/ghost/admin-x-settings/src/components/settings/general/Users.tsx index 87447ccfbe..4c5c4563e7 100644 --- a/ghost/admin-x-settings/src/components/settings/general/Users.tsx +++ b/ghost/admin-x-settings/src/components/settings/general/Users.tsx @@ -6,15 +6,20 @@ import NiceModal from '@ebay/nice-modal-react'; import React from 'react'; import SettingGroup from '../../../admin-x-ds/settings/SettingGroup'; import TabView from '../../../admin-x-ds/global/TabView'; +import UserDetailModal from '../../modals/UserDetailModal'; const Users: React.FC = () => { - const showAddModal = () => { + const showInviteModal = () => { NiceModal.show(InviteUserModal); }; + const showDetailModal = () => { + NiceModal.show(UserDetailModal); + }; + const buttons = (