Skip to content

Commit

Permalink
Merge pull request #345 from BloomBooks/SlimDownCore
Browse files Browse the repository at this point in the history
Core is obese. Extract some static functions to their own files (#345)
  • Loading branch information
andrew-polk authored Dec 2, 2024
2 parents fb18ab6 + 6abc8c1 commit db5bdae
Show file tree
Hide file tree
Showing 5 changed files with 590 additions and 579 deletions.
3 changes: 2 additions & 1 deletion src/bloom-player-controls.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ import DragBar from "@material-ui/core/Slider";
import { bloomRed } from "./bloomPlayerTheme";
import { setDurationOfPagesWithoutNarration } from "./narration";
import { roundToNearestK, normalizeDigits } from "./utilities/mathUtils";
import { fixNiceScrollOffsets } from "./scrolling";

// This component is designed to wrap a BloomPlayer with some controls
// for things like pausing audio and motion, hiding and showing
Expand Down Expand Up @@ -603,7 +604,7 @@ export const BloomPlayerControls: React.FunctionComponent<BloomPlayerProps> = (
actualPageHeight / scaleFactor
}px; overflow: hidden;}`;
//alert("scale page to window completed");
BloomPlayerCore.fixNiceScrollOffsets(page, scaleFactor);
fixNiceScrollOffsets(page, scaleFactor);
if (!pageScaled) {
setPageScaled(true);
}
Expand Down
Loading

0 comments on commit db5bdae

Please sign in to comment.