mirror of
https://github.com/balzack/databag.git
synced 2025-02-12 03:29:16 +00:00
adding theme context to modal shortcut
This commit is contained in:
parent
c04cd4c270
commit
f0134493db
@ -6,10 +6,11 @@ import { LogoutOutlined, InfoCircleOutlined, ExclamationCircleOutlined, DownOutl
|
||||
|
||||
export function Identity({ openAccount, openCards, cardUpdated }) {
|
||||
|
||||
const [modal, modalContext] = Modal.useModal();
|
||||
const { state, actions } = useIdentity();
|
||||
|
||||
const logout = () => {
|
||||
Modal.confirm({
|
||||
modal.confirm({
|
||||
title: 'Are you sure you want to logout?',
|
||||
icon: <LogoutOutlined />,
|
||||
onOk() {
|
||||
@ -36,6 +37,7 @@ export function Identity({ openAccount, openCards, cardUpdated }) {
|
||||
return (
|
||||
<Dropdown overlay={menu} overlayStyle={{ minWidth: 0 }} trigger={['click']} placement="bottomRight">
|
||||
<IdentityWrapper>
|
||||
{ modalContext }
|
||||
{ state.init && (
|
||||
<Logo url={state.url} width={40} height={40} radius={4} />
|
||||
)}
|
||||
|
Loading…
Reference in New Issue
Block a user