mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-18 15:40:12 +01:00
This commit is contained in:
parent
f54705e151
commit
336eaef000
3 changed files with 35 additions and 7 deletions
|
|
@ -27,17 +27,23 @@ openWindow = () => {
|
|||
};
|
||||
/// #else
|
||||
openWindow = (options: {
|
||||
position?: {
|
||||
x: number,
|
||||
y: number,
|
||||
},
|
||||
height?: number,
|
||||
width?: number,
|
||||
tab?: Tab,
|
||||
doc?: {
|
||||
id: string, // 块 id
|
||||
},
|
||||
}) => {
|
||||
if (options.doc.id) {
|
||||
openNewWindowById(options.doc.id);
|
||||
openNewWindowById(options.doc.id, {position: options.position, width: options.width, height: options.height});
|
||||
return;
|
||||
}
|
||||
if (options.tab) {
|
||||
openNewWindow(options.tab)
|
||||
openNewWindow(options.tab, {position: options.position, width: options.width, height: options.height});
|
||||
return;
|
||||
}
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue