MCPcopy Create free account
hub / github.com/cutedCha/noteBoook / updateContinueReadingModal

Function updateContinueReadingModal

js/app.js:1097–1106  ·  view source on GitHub ↗

* 更新继续阅读弹窗中的章节信息 * @param {Object} chapter - 章节信息对象 * @param {number} pageNumber - 页码 * Requirements: 7.2

(chapter, pageNumber)

Source from the content-addressed store, hash-verified

1095 * Requirements: 7.2
1096 */
1097function updateContinueReadingModal(chapter, pageNumber) {
1098 const modalChapter = document.querySelector('.continue-reading-modal .modal-chapter');
1099 if (modalChapter) {
1100 let text = `第${chapter.number}章:${chapter.title}`;
1101 if (pageNumber && pageNumber > 1) {
1102 text += ` (第${pageNumber}页)`;
1103 }
1104 modalChapter.textContent = text;
1105 }
1106}
1107
1108/**
1109 * 显示继续阅读弹窗

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected