mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-02-16 20:18:06 +01:00
🎨 Remove the footer Export by SiYuan when exporting image and PDF Fix https://github.com/siyuan-note/siyuan/issues/7838
This commit is contained in:
parent
1f7fc4cc8f
commit
8a2a724341
10 changed files with 1 additions and 29 deletions
|
|
@ -27,14 +27,6 @@ export const exportConfig = {
|
|||
<span class="fn__space"></span>
|
||||
<input class="b3-switch fn__flex-center" id="addTitle" type="checkbox"${window.siyuan.config.export.addTitle ? " checked" : ""}/>
|
||||
</label>
|
||||
<label class="fn__flex b3-label">
|
||||
<div class="fn__flex-1">
|
||||
${window.siyuan.languages.export21}
|
||||
<div class="b3-label__text">${window.siyuan.languages.export22}</div>
|
||||
</div>
|
||||
<span class="fn__space"></span>
|
||||
<input class="b3-switch fn__flex-center" id="addFooter" type="checkbox"${window.siyuan.config.export.addFooter ? " checked" : ""}/>
|
||||
</label>
|
||||
<label class="fn__flex b3-label">
|
||||
<div class="fn__flex-1">
|
||||
${window.siyuan.languages.export23}
|
||||
|
|
@ -137,7 +129,6 @@ export const exportConfig = {
|
|||
fetchPost("/api/setting/setExport", {
|
||||
paragraphBeginningSpace: (exportConfig.element.querySelector("#paragraphBeginningSpace") as HTMLInputElement).checked,
|
||||
addTitle: (exportConfig.element.querySelector("#addTitle") as HTMLInputElement).checked,
|
||||
addFooter: (exportConfig.element.querySelector("#addFooter") as HTMLInputElement).checked,
|
||||
markdownYFM: (exportConfig.element.querySelector("#markdownYFM") as HTMLInputElement).checked,
|
||||
blockRefMode: parseInt((exportConfig.element.querySelector("#blockRefMode") as HTMLSelectElement).value, 10),
|
||||
blockEmbedMode: parseInt((exportConfig.element.querySelector("#blockEmbedMode") as HTMLSelectElement).value, 10),
|
||||
|
|
|
|||
|
|
@ -39,7 +39,6 @@ export const exportImage = (id: string) => {
|
|||
`,
|
||||
content: `<div class="b3-dialog__content" style="max-height: 70vh;overflow: auto;${isMobile() ? "padding:8px;" : ""};background-color: var(--b3-theme-background)">
|
||||
<div style="${isMobile() ? "padding: 16px;margin: 16px 0" : "padding: 48px;margin: 8px 0 24px"};border: 1px solid var(--b3-border-color);border-radius: 10px;" class="export-img protyle-wysiwyg${window.siyuan.config.editor.displayBookmarkIcon ? " protyle-wysiwyg--attr" : ""}" id="preview"></div>
|
||||
<div class="ft__smaller ft__on-surface fn__flex"><img style="height: 18px;margin: 0 8px" src="stage/icon.png">${window.siyuan.languages.exportBySiYuan}</div>
|
||||
<div class="fn__hr--b"></div>
|
||||
<div class="fn__hr--b"></div>
|
||||
</div>
|
||||
|
|
|
|||
1
app/src/types/index.d.ts
vendored
1
app/src/types/index.d.ts
vendored
|
|
@ -310,7 +310,6 @@ declare interface IExport {
|
|||
pandocBin: string
|
||||
paragraphBeginningSpace: boolean;
|
||||
addTitle: boolean;
|
||||
addFooter: boolean;
|
||||
markdownYFM: boolean;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -275,7 +275,7 @@ export const initWindow = () => {
|
|||
};
|
||||
setStorageVal(Constants.LOCAL_EXPORTPDF, window.siyuan.storage[Constants.LOCAL_EXPORTPDF]);
|
||||
try {
|
||||
if (window.siyuan.config.export.addFooter) {
|
||||
if (false) { // TODO 已经移除了之前的“由思源笔记导出”页脚(https://github.com/siyuan-note/siyuan/issues/7838),后面如果需要的话换成自定义页脚
|
||||
ipcData.pdfOptions.displayHeaderFooter = true;
|
||||
ipcData.pdfOptions.headerTemplate = "<span></span>";
|
||||
ipcData.pdfOptions.footerTemplate = `<div style="width:100%;margin-right:${ipcData.pdfOptions.margins.right}in;display: flex;line-height:12px;">
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue