use real number of pages on whiteboard mount

This commit is contained in:
Ramón Souza 2023-10-12 15:29:29 -03:00
parent 1962b10919
commit 77275934e2
2 changed files with 2 additions and 3 deletions

View File

@ -82,7 +82,7 @@ export default function Whiteboard(props) {
hasWBAccess,
whiteboardWriters,
} = props;
// TODO: use real number of pages of the presentation when this information gets available from graphQL
const { pages, pageStates } = initDefaultPages(numberOfPages || 1);
const rDocument = React.useRef({
name: 'test',

View File

@ -33,7 +33,6 @@ import Whiteboard from './component';
const ROLE_MODERATOR = Meteor.settings.public.user.role_moderator;
const WHITEBOARD_CONFIG = Meteor.settings.public.whiteboard;
const PRESENTATION_CONFIG = Meteor.settings.public.presentation;
let annotations = [];
let lastUpdatedAt = null;
@ -204,7 +203,7 @@ const WhiteboardContainer = (props) => {
toggleToolsAnimations,
isIphone,
currentPresentationPage,
numberOfPages: PRESENTATION_CONFIG.mirroredFromBBBCore.uploadPagesMax,
numberOfPages: currentPresentationPage?.numPages,
presentationId,
hasWBAccess,
whiteboardWriters,