MCPcopy
hub / github.com/ollm/OpenComic / getPreviusContentSize

Function getPreviusContentSize

scripts/reading.js:786–797  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

784var previousScrollTop = 0, previousScrollHeight = 0, previousContentHeight = 0, stayInLineData = {scrollTop: false, scrollHeight: false, heigth: false, position: {}, setTimeout: false};
785
786function getPreviusContentSize()
787{
788 if(!readingViewIs('scroll')) return;
789
790 let contentRight = template._contentRight();
791 let content = contentRight.firstElementChild;
792 let rect = content.getBoundingClientRect();
793
794 previousContentHeight = rect.height;
795 previousScrollHeight = content.scrollHeight;
796 previousScrollTop = content.scrollTop;
797}
798
799function stayInLine(resize = false)
800{

Callers 3

disableOnScrollFunction · 0.85
generateEbookPagesFunction · 0.85
readFunction · 0.85

Calls 1

readingViewIsFunction · 0.85

Tested by

no test coverage detected