Compare commits

...

5 Commits

Author SHA1 Message Date
zadam
0a0de7312c release 0.40.7 2020-03-28 20:58:20 +01:00
zadam
b4b22d9353 workaround for overflowing component wrapper in landscape mobile frontend, fixes #933 2020-03-28 19:39:14 +01:00
zadam
d3eb640aa2 fix upload image from mobile frontend, closes #931 2020-03-28 19:25:19 +01:00
zadam
8ccc48c25d images in include note should have max 100% width, #922 2020-03-21 09:52:13 +01:00
zadam
9a1a76605a fix OPML export of book notes, closes #919 2020-03-19 09:42:41 +01:00
6 changed files with 16 additions and 6 deletions

View File

@@ -2,7 +2,7 @@
"name": "trilium",
"productName": "Trilium Notes",
"description": "Trilium Notes",
"version": "0.40.6",
"version": "0.40.7",
"license": "AGPL-3.0-only",
"main": "electron.js",
"bin": {

View File

@@ -9,9 +9,16 @@ import utils from "./services/utils.js";
import treeUtils from "./services/tree_utils.js";
import linkService from "./services/link.js";
import noteContentRenderer from "./services/note_content_renderer.js";
import server from "./services/server.js";
window.glob.isDesktop = utils.isDesktop;
window.glob.isMobile = utils.isMobile;
// required for CKEditor image upload plugin
window.glob.getActiveNode = treeService.getActiveNode;
window.glob.getHeaders = server.getHeaders;
window.glob.noteChanged = noteDetailService.noteChanged;
window.glob.refreshTree = treeService.reload;
window.glob.showAddLinkDialog = () => import('./dialogs/add_link.js').then(d => d.showDialog());
window.glob.showIncludeNoteDialog = cb => import('./dialogs/include_note.js').then(d => d.showDialog(cb));
window.glob.loadIncludedNote = async (noteId, el) => {

View File

@@ -20,7 +20,9 @@ async function getRenderedContent(note) {
$rendered = $("<pre>").text(fullNote.content);
}
else if (type === 'image') {
$rendered = $("<img>").attr("src", `api/images/${note.noteId}/${note.title}`);
$rendered = $("<img>")
.attr("src", `api/images/${note.noteId}/${note.title}`)
.css("max-width", "100%");
}
else if (type === 'file') {
function getFileUrl() {

View File

@@ -115,4 +115,5 @@ span.fancytree-expander {
/* large left padding is necessary for ckeditor gutter in detail-only (smartphone) layout */
padding-left: 35px;
padding-top: 10px;
min-height: 150px !important;
}

View File

@@ -1 +1 @@
module.exports = { buildDate:"2020-03-15T11:21:43+01:00", buildRevision: "f5e27278ab2a38484019ee2510781099b60ec2b6" };
module.exports = { buildDate:"2020-03-28T20:58:20+01:00", buildRevision: "b4b22d9353bdc6ad4d3bab7cdb33bd0b844cc36d" };

View File

@@ -16,7 +16,7 @@ async function exportToOpml(taskContext, branch, version, res) {
const branch = await repository.getBranch(branchId);
const note = await branch.getNote();
if (!note.isStringNote() || await note.hasOwnedLabel('excludeFromExport')) {
if (await note.hasOwnedLabel('excludeFromExport')) {
return;
}
@@ -24,13 +24,13 @@ async function exportToOpml(taskContext, branch, version, res) {
if (opmlVersion === 1) {
const preparedTitle = escapeXmlAttribute(title);
const preparedContent = prepareText(await note.getContent());
const preparedContent = note.isStringNote() ? prepareText(await note.getContent()) : '';
res.write(`<outline title="${preparedTitle}" text="${preparedContent}">\n`);
}
else if (opmlVersion === 2) {
const preparedTitle = escapeXmlAttribute(title);
const preparedContent = escapeXmlAttribute(await note.getContent());
const preparedContent = note.isStringNote() ? escapeXmlAttribute(await note.getContent()) : '';
res.write(`<outline text="${preparedTitle}" _note="${preparedContent}">\n`);
}