mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-02-22 23:14:07 +01:00
This commit is contained in:
parent
3127ff1e52
commit
c1e0b4ff60
3 changed files with 91 additions and 95 deletions
|
|
@ -461,15 +461,14 @@ const renderPDF = (id: string) => {
|
|||
actionElement.querySelector("#landscape").addEventListener('change', () => {
|
||||
setPadding();
|
||||
});
|
||||
const currentWindowId = ${getCurrentWindow().id};
|
||||
actionElement.querySelector('.b3-button--cancel').addEventListener('click', () => {
|
||||
const {ipcRenderer} = require("electron");
|
||||
ipcRenderer.send("${Constants.SIYUAN_EXPORT_CLOSE}", currentWindowId)
|
||||
ipcRenderer.send("${Constants.SIYUAN_EXPORT_CLOSE}")
|
||||
});
|
||||
actionElement.querySelector('.b3-button--text').addEventListener('click', () => {
|
||||
const {ipcRenderer} = require("electron");
|
||||
ipcRenderer.send("${Constants.SIYUAN_EXPORT_PDF}", {
|
||||
id: currentWindowId,
|
||||
title: "${window.siyuan.languages.export} PDF",
|
||||
pdfOptions:{
|
||||
printBackground: true,
|
||||
landscape: actionElement.querySelector("#landscape").checked,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue