|
@@ -280,6 +280,13 @@ export class Wnd {
|
|
const targetWnd = getInstanceById(targetWndElement.getAttribute("data-id")) as Wnd;
|
|
const targetWnd = getInstanceById(targetWndElement.getAttribute("data-id")) as Wnd;
|
|
const tabId = event.dataTransfer.getData(Constants.SIYUAN_DROP_TAB);
|
|
const tabId = event.dataTransfer.getData(Constants.SIYUAN_DROP_TAB);
|
|
const oldTab = getInstanceById(tabId) as Tab;
|
|
const oldTab = getInstanceById(tabId) as Tab;
|
|
|
|
+ if (oldTab.model instanceof Asset) {
|
|
|
|
+ // https://github.com/siyuan-note/siyuan/issues/6890
|
|
|
|
+ const pdfViewerElement = oldTab.model.element.querySelector("#viewerContainer")
|
|
|
|
+ if (pdfViewerElement) {
|
|
|
|
+ pdfViewerElement.setAttribute("data-scrolltop", pdfViewerElement.scrollTop.toString())
|
|
|
|
+ }
|
|
|
|
+ }
|
|
if (dragElement.style.height === "50%" || dragElement.style.width === "50%") {
|
|
if (dragElement.style.height === "50%" || dragElement.style.width === "50%") {
|
|
// split
|
|
// split
|
|
if (dragElement.style.height === "50%") {
|
|
if (dragElement.style.height === "50%") {
|