move variable definition
This commit is contained in:
parent
7ade8a0d7d
commit
48cc57dbaf
@ -205,6 +205,8 @@ export default function Whiteboard(props) {
|
||||
}
|
||||
}, [curPageId, slidePosition]);
|
||||
|
||||
const hasWBAccess = props?.hasMultiUserAccess(props.whiteboardId, props.currentUser.userId);
|
||||
|
||||
React.useEffect(() => {
|
||||
if (hasWBAccess || isPresenter) {
|
||||
const tdTools = document.getElementById("TD-Tools");
|
||||
@ -238,8 +240,6 @@ export default function Whiteboard(props) {
|
||||
}
|
||||
});
|
||||
|
||||
const hasWBAccess = props?.hasMultiUserAccess(props.whiteboardId, props.currentUser.userId);
|
||||
|
||||
const onMount = (app) => {
|
||||
setTLDrawAPI(app);
|
||||
props.setTldrawAPI(app);
|
||||
@ -329,7 +329,6 @@ export default function Whiteboard(props) {
|
||||
showZoom={false}
|
||||
showUI={curPres ? (isPresenter || hasWBAccess) : true}
|
||||
showMenu={curPres ? false : true}
|
||||
|
||||
showMultiplayerMenu={false}
|
||||
readOnly={false}
|
||||
onPatch={onPatch}
|
||||
|
Loading…
Reference in New Issue
Block a user