mirror of
https://github.com/lukevella/rallly.git
synced 2025-07-27 05:07:50 +02:00
✨ Add ability to change participant's name (#577)
This commit is contained in:
parent
05d2c7b1d0
commit
cb52adab01
15 changed files with 406 additions and 261 deletions
|
@ -25,3 +25,12 @@ export const useModal = (
|
|||
);
|
||||
return [modal, () => setVisible(true), () => setVisible(false)];
|
||||
};
|
||||
|
||||
export const useModalState = (): [boolean, () => void, () => void] => {
|
||||
const [visible, setVisible] = React.useState(false);
|
||||
|
||||
const hide = React.useCallback(() => setVisible(false), []);
|
||||
const show = React.useCallback(() => setVisible(true), []);
|
||||
|
||||
return [visible, show, hide];
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue