This commit is contained in:
parent
01dff7eb5d
commit
46e5e78176
6 changed files with 10 additions and 0 deletions
|
@ -1,4 +1,5 @@
|
|||
{
|
||||
"scrollGetMore": "Don't panic... scroll up and down to load more",
|
||||
"flashcardNewCard": "New",
|
||||
"flashcardReviewCard": "Review",
|
||||
"flashcardCard": "Total",
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
{
|
||||
"scrollGetMore": "No se asuste... desplácese hacia arriba y hacia abajo para cargar más",
|
||||
"flashcardNewCard": "Nueva Tarjeta",
|
||||
"flashcardReviewCard": "Revisar Tarjeta",
|
||||
"flashcardCard": "Todos",
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
{
|
||||
"scrollGetMore": "Ne paniquez pas... faites défiler de haut en bas pour en charger plus",
|
||||
"flashcardNewCard": "Nouvelle carte",
|
||||
"flashcardReviewCard": "Revoir la carte",
|
||||
"flashcardCard": "Tous",
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
{
|
||||
"scrollGetMore": "不要驚慌...,上下滾動即可加載更多內容",
|
||||
"flashcardNewCard": "新卡",
|
||||
"flashcardReviewCard": "複習卡",
|
||||
"flashcardCard": "所有",
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
{
|
||||
"scrollGetMore": "不要惊慌...,上下滚动即可加载更多内容",
|
||||
"flashcardNewCard": "新卡",
|
||||
"flashcardReviewCard": "复习卡",
|
||||
"flashcardCard": "所有",
|
||||
|
|
|
@ -8,6 +8,7 @@ import {processRender} from "../util/processCode";
|
|||
import {highlightRender} from "../markdown/highlightRender";
|
||||
import {blockRender} from "../markdown/blockRender";
|
||||
import {disabledForeverProtyle, disabledProtyle, enableProtyle} from "../util/onGet";
|
||||
import {showMessage} from "../../dialog/message";
|
||||
|
||||
export const saveScroll = (protyle: IProtyle, getObject = false) => {
|
||||
if (!protyle.wysiwyg.element.firstElementChild || window.siyuan.config.readonly) {
|
||||
|
@ -102,6 +103,10 @@ export const restoreScroll = (protyle: IProtyle, scrollAttr: IScrollAttr) => {
|
|||
}
|
||||
// 使用动态滚动条定位到最后一个块,重启后无法触发滚动事件,需要再次更新 index
|
||||
protyle.scroll.updateIndex(protyle, scrollAttr.startId);
|
||||
// https://github.com/siyuan-note/siyuan/issues/8224
|
||||
if (protyle.wysiwyg.element.clientHeight - parseInt(protyle.wysiwyg.element.style.paddingBottom) < protyle.contentElement.clientHeight) {
|
||||
showMessage(window.siyuan.languages.scrollGetMore);
|
||||
}
|
||||
});
|
||||
} else if (scrollAttr.scrollTop) {
|
||||
protyle.contentElement.scrollTop = scrollAttr.scrollTop;
|
||||
|
|
Loading…
Add table
Reference in a new issue