bigbluebutton-Github/bigbluebutton-html5/imports/api/slides/server/helpers.js
germanocaumo d4b8bdce7e fix(tldraw): sync viewed area between presenter/viewers +
- Return to the ResizeAndMoveSlide event to do pan&zoom, respecting the viewed width and height ratio
- Defaults zoom in toolbar to 100% like before to be more consistent
- Fit to width and Reset Zoom is back (fit tho width still has some sync problems)
- Fix to not change to first page when presenter reloads page
2022-08-16 12:12:43 +00:00

19 lines
406 B
JavaScript
Executable File

const calculateSlideData = (slideData) => {
const {
width, height, xOffset, yOffset, widthRatio, heightRatio,
} = slideData;
// calculating viewBox and offsets for the current presentation
return {
width,
height,
x: xOffset,
y: yOffset,
viewBoxWidth: (width * widthRatio) / 100,
viewBoxHeight: (height * heightRatio) / 100,
};
};
export default calculateSlideData;