Trigger disconnect modal via URL hash

This commit is contained in:
Philipp Stracker 2025-02-13 16:32:18 +01:00
parent 12316b1022
commit 3a096b832d
No known key found for this signature in database

View file

@ -3,10 +3,11 @@ import { Button, Modal, ToggleControl } from '@wordpress/components';
import { useCallback, useState } from '@wordpress/element';
import { CommonHooks } from '../../../../../../data';
import { useToggleState } from '../../../../../../hooks/useToggleState';
import { HStack } from '../../../../../ReusableComponents/Stack';
const DisconnectButton = () => {
const [ isOpen, setIsOpen ] = useState( false );
const { isOpen, setIsOpen } = useToggleState( 'disconnect-merchant' );
const [ resetFlag, setResetFlag ] = useState( false );
const { disconnectMerchant } = CommonHooks.useDisconnectMerchant();