mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-23 18:10:12 +01:00
Merge remote-tracking branch 'origin/dev' into dev
This commit is contained in:
commit
d59c131170
16 changed files with 264 additions and 69 deletions
|
|
@ -199,9 +199,10 @@
|
|||
"exportPDF1": "Landscape page",
|
||||
"exportPDF2": "Page margins",
|
||||
"exportPDF3": "Page Scale",
|
||||
"exportPDF4": "Remove assets directory",
|
||||
"exportPDF4": "Embed assets",
|
||||
"exportPDF5": "Keep folded",
|
||||
"exportPDF6": "Merge subdocuments",
|
||||
"mergeSubdocs": "Merge subdocuments",
|
||||
"removeAssetsFolder": "Remove assets directory",
|
||||
"upload": "Upload",
|
||||
"reminderTip": "The reminder time cannot be less than the current time",
|
||||
"wechatTip": "The content block will be sent to the cloud in clear text, and pushed through the WeChat MP template message when it expires",
|
||||
|
|
|
|||
|
|
@ -199,9 +199,10 @@
|
|||
"exportPDF1": "Página apaisada",
|
||||
"exportPDF2": "Márgenes de la página",
|
||||
"exportPDF3": "Escala de la página",
|
||||
"exportPDF4": "Eliminar directorio de activos",
|
||||
"exportPDF4": "Activos incrustados",
|
||||
"exportPDF5": "Mantener doblado",
|
||||
"exportPDF6": "Fusionar subdocumentos",
|
||||
"mergeSubdocs": "Fusionar subdocumentos",
|
||||
"removeAssetsFolder": "Eliminar directorio de activos",
|
||||
"upload": "Subir",
|
||||
"reminderTip": "La hora del recordatorio no puede ser inferior a la hora actual",
|
||||
"wechatTip": "El bloque de contenido se enviará a la nube en texto claro, y se empujará a través del mensaje de plantilla de WeChat MP cuando caduque",
|
||||
|
|
|
|||
|
|
@ -199,9 +199,10 @@
|
|||
"exportPDF1": "Page paysage",
|
||||
"exportPDF2": "Marges de page",
|
||||
"exportPDF3": "Échelle de page",
|
||||
"exportPDF4": "Supprimer le répertoire des actifs",
|
||||
"exportPDF4": "Incorporer des ressources",
|
||||
"exportPDF5": "Garder plié",
|
||||
"exportPDF6": "Fusionner les sous-documents",
|
||||
"mergeSubdocs": "Fusionner les sous-documents",
|
||||
"removeAssetsFolder": "Supprimer le répertoire des actifs",
|
||||
"upload": "Télécharger",
|
||||
"reminderTip": "The reminder time cannot be less than the current time",
|
||||
"wechatTip": "Le bloc de contenu sera envoyé au cloud en texte clair et transmis au message du modèle de compte officiel WeChat à son expiration.",
|
||||
|
|
|
|||
|
|
@ -199,9 +199,10 @@
|
|||
"exportPDF1": "橫向頁面",
|
||||
"exportPDF2": "頁面邊距",
|
||||
"exportPDF3": "頁面縮放",
|
||||
"exportPDF4": "移除 assets 目錄",
|
||||
"exportPDF4": "嵌入資源文件",
|
||||
"exportPDF5": "保持折疊狀態",
|
||||
"exportPDF6": "合併子文檔",
|
||||
"mergeSubdocs": "合併子文檔",
|
||||
"removeAssetsFolder": "移除 assets 目錄",
|
||||
"upload": "上傳",
|
||||
"reminderTip": "提醒時間不能小於當前時間",
|
||||
"wechatTip": "該內容塊將以明文形式發送到雲端,到期時通過微信公眾號模板消息進行推送",
|
||||
|
|
|
|||
|
|
@ -199,9 +199,10 @@
|
|||
"exportPDF1": "横向页面",
|
||||
"exportPDF2": "页面边距",
|
||||
"exportPDF3": "页面缩放",
|
||||
"exportPDF4": "移除 assets 目录",
|
||||
"exportPDF4": "嵌入资源文件",
|
||||
"exportPDF5": "保持折叠状态",
|
||||
"exportPDF6": "合并子文档",
|
||||
"mergeSubdocs": "合并子文档",
|
||||
"removeAssetsFolder": "移除 assets 目录",
|
||||
"upload": "上传",
|
||||
"reminderTip": "提醒时间不能小于当前时间",
|
||||
"wechatTip": "该内容块将以明文形式发送到云端,到期时通过微信公众号模板消息进行推送",
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
import {hideMessage, showMessage} from "../../dialog/message";
|
||||
import {Constants} from "../../constants";
|
||||
/// #if !BROWSER
|
||||
import {OpenDialogReturnValue, ipcRenderer} from "electron";
|
||||
import {ipcRenderer, OpenDialogReturnValue} from "electron";
|
||||
import {app, BrowserWindow, dialog, getCurrentWindow} from "@electron/remote";
|
||||
import * as fs from "fs";
|
||||
import * as path from "path";
|
||||
|
|
@ -33,14 +33,14 @@ export const saveExport = (option: { type: string, id: string }) => {
|
|||
content: `<div class="b3-dialog__content">
|
||||
<label class="fn__flex b3-label">
|
||||
<div class="fn__flex-1">
|
||||
${window.siyuan.languages.exportPDF4}
|
||||
${window.siyuan.languages.removeAssetsFolder}
|
||||
</div>
|
||||
<span class="fn__space"></span>
|
||||
<input id="removeAssets" class="b3-switch" type="checkbox" ${localData.removeAssets ? "checked" : ""}>
|
||||
</label>
|
||||
<label class="fn__flex b3-label">
|
||||
<div class="fn__flex-1">
|
||||
${window.siyuan.languages.exportPDF6}
|
||||
${window.siyuan.languages.mergeSubdocs}
|
||||
</div>
|
||||
<span class="fn__space"></span>
|
||||
<input id="mergeSubdocs" class="b3-switch" type="checkbox" ${localData.mergeSubdocs ? "checked" : ""}>
|
||||
|
|
@ -215,7 +215,7 @@ const renderPDF = (id: string) => {
|
|||
</label>
|
||||
<label class="b3-label">
|
||||
<div>
|
||||
${window.siyuan.languages.exportPDF6}
|
||||
${window.siyuan.languages.mergeSubdocs}
|
||||
</div>
|
||||
<span class="fn__hr"></span>
|
||||
<input id="mergeSubdocs" class="b3-switch" type="checkbox" ${localData.mergeSubdocs ? "checked" : ""}>
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@ import {exportLayout, getInstanceById, JSONToLayout, resetLayout, resizeDrag, re
|
|||
import {hotKey2Electron, setStorageVal, updateHotkeyTip} from "../protyle/util/compatibility";
|
||||
/// #if !BROWSER
|
||||
import {dialog, getCurrentWindow} from "@electron/remote";
|
||||
import {webFrame, ipcRenderer, OpenDialogReturnValue} from "electron";
|
||||
import {ipcRenderer, OpenDialogReturnValue, webFrame} from "electron";
|
||||
import * as fs from "fs";
|
||||
import * as path from "path";
|
||||
import {afterExport} from "../protyle/export/util";
|
||||
|
|
@ -418,10 +418,11 @@ export const initWindow = () => {
|
|||
const pdfFilePath = path.join(result.filePaths[0], replaceLocalPath(ipcData.rootTitle) + ".pdf");
|
||||
fs.writeFileSync(pdfFilePath, pdfData);
|
||||
window.siyuan.printWin.destroy();
|
||||
fetchPost("/api/export/addPDFOutline", {
|
||||
fetchPost("/api/export/processPDF", {
|
||||
id: ipcData.rootId,
|
||||
merge: ipcData.mergeSubdocs,
|
||||
path: pdfFilePath
|
||||
path: pdfFilePath,
|
||||
removeAssets: ipcData.removeAssets,
|
||||
}, () => {
|
||||
afterExport(pdfFilePath, msgId);
|
||||
if (ipcData.removeAssets) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue