mirror of
https://github.com/Qortal/Qortal-Hub.git
synced 2025-07-30 13:41:45 +00:00
optimize global states
This commit is contained in:
@@ -34,6 +34,8 @@ import { subscribeToEvent, unsubscribeFromEvent } from '../utils/events';
|
||||
import { BarSpinner } from '../common/Spinners/BarSpinner/BarSpinner';
|
||||
import CheckIcon from '@mui/icons-material/Check';
|
||||
import ErrorIcon from '@mui/icons-material/Error';
|
||||
import { useSetAtom } from 'jotai';
|
||||
import { txListAtom } from '../atoms/global';
|
||||
|
||||
enum Availability {
|
||||
NULL = 'null',
|
||||
@@ -46,9 +48,10 @@ export const RegisterName = ({
|
||||
setInfoSnack,
|
||||
userInfo,
|
||||
show,
|
||||
setTxList,
|
||||
balance,
|
||||
}) => {
|
||||
const setTxList = useSetAtom(txListAtom);
|
||||
|
||||
const [isOpen, setIsOpen] = useState(false);
|
||||
const [registerNameValue, setRegisterNameValue] = useState('');
|
||||
const [isLoadingRegisterName, setIsLoadingRegisterName] = useState(false);
|
||||
|
Reference in New Issue
Block a user