diff --git a/app/appearance/langs/en_US.json b/app/appearance/langs/en_US.json index ceef89e39..41a035290 100644 --- a/app/appearance/langs/en_US.json +++ b/app/appearance/langs/en_US.json @@ -459,7 +459,7 @@ "newNameFile": "The name of the new document is", "newContentFile": "The content of the new document is", "exporting": "Exporting, please wait...", - "exported": "Export complete: ", + "exported": "Export complete", "refExpired": "Search content block does not exist", "emptyContent": "No related content", "useBrowserView": "View in the browser", diff --git a/app/appearance/langs/es_ES.json b/app/appearance/langs/es_ES.json index 2110493af..137a02e4c 100644 --- a/app/appearance/langs/es_ES.json +++ b/app/appearance/langs/es_ES.json @@ -458,7 +458,7 @@ "newNameFile": "El nombre del nuevo documento es", "newContentFile": "El contenido del nuevo documento es", "exporting": "Exportando, por favor espere...", - "exported": "Exportación completada: ", + "exported": "Exportación completada", "refExpired": "El bloque de contenido de búsqueda no existe", "emptyContent": "No hay contenido relacionado", "useBrowserView": "Ver en el navegador", diff --git a/app/appearance/langs/fr_FR.json b/app/appearance/langs/fr_FR.json index 7b8e41671..d881cc0b6 100644 --- a/app/appearance/langs/fr_FR.json +++ b/app/appearance/langs/fr_FR.json @@ -459,7 +459,7 @@ "newNameFile": "Le nom du nouveau document est", "newContentFile": "Le contenu du nouveau document est", "exporting": "En cours d'exportation, veuillez patienter...", - "exported": "Exportation terminée: ", + "exported": "Exportation terminée", "refExpired": "Le bloc de contenu de recherche n'existe pas", "emptyContent": "Aucun contenu pertinent pour le moment", "useBrowserView": "Afficher dans le navigateur", diff --git a/app/appearance/langs/zh_CHT.json b/app/appearance/langs/zh_CHT.json index 38951d1fa..4d2ff6d99 100644 --- a/app/appearance/langs/zh_CHT.json +++ b/app/appearance/langs/zh_CHT.json @@ -459,7 +459,7 @@ "newNameFile": "新建文檔名為", "newContentFile": "新建文檔內容為", "exporting": "正在匯出,請稍等...", - "exported": "匯出完成:", + "exported": "匯出完成", "refExpired": "不存在符合條件的內容塊", "emptyContent": "暫無相關內容", "useBrowserView": "在瀏覽器中查看", diff --git a/app/appearance/langs/zh_CN.json b/app/appearance/langs/zh_CN.json index 55773d451..36cc7ccab 100644 --- a/app/appearance/langs/zh_CN.json +++ b/app/appearance/langs/zh_CN.json @@ -459,7 +459,7 @@ "newNameFile": "新建文档名为", "newContentFile": "新建文档内容为", "exporting": "正在导出,请稍等...", - "exported": "导出完成:", + "exported": "导出完成", "refExpired": "不存在符合条件的内容块", "emptyContent": "暂无相关内容", "useBrowserView": "在浏览器中查看", diff --git a/app/src/protyle/export/util.ts b/app/src/protyle/export/util.ts index 935bb92ef..69e264a83 100644 --- a/app/src/protyle/export/util.ts +++ b/app/src/protyle/export/util.ts @@ -15,7 +15,7 @@ import {openByMobile} from "../util/compatibility"; export const afterExport = (exportPath: string, msgId: string) => { /// #if !BROWSER - showMessage(`${window.siyuan.languages.exported}${escapeHtml(exportPath)} + showMessage(`${window.siyuan.languages.exported} ${escapeHtml(exportPath)}
`, 6000, "info", msgId); document.querySelector(`#message [data-id="${msgId}"] button`).addEventListener("click", () => { diff --git a/kernel/model/export.go b/kernel/model/export.go index 35910b8b9..debfedbcc 100644 --- a/kernel/model/export.go +++ b/kernel/model/export.go @@ -504,8 +504,12 @@ func AddPDFOutline(id, p string) (err error) { footnotes := map[string]*pdfcpu.Bookmark{} for _, link := range links { linkID := link.URI[strings.LastIndex(link.URI, "/")+1:] - - title := sql.GetBlock(linkID).Content + b := sql.GetBlock(linkID) + if nil == b { + logging.LogWarnf("pdf outline block [%s] not found", linkID) + continue + } + title := b.Content title, _ = url.QueryUnescape(title) bm := &pdfcpu.Bookmark{ Title: title,