new import options in the dialog, tooltips

This commit is contained in:
zadam 2019-02-24 11:36:01 +01:00
parent d8ba0ccd7d
commit fb5df33ee7
4 changed files with 31 additions and 4 deletions

View file

@ -134,6 +134,10 @@ $("#export-note-button").click(function () {
exportDialog.showDialog('single');
});
$('[data-toggle="tooltip"]').tooltip({
html: true
});
macInit.init();
searchNotesService.init(); // should be in front of treeService since that one manipulates address bar hash

View file

@ -108,4 +108,8 @@ body {
#note-info-table td, #note-info-table th {
padding: 15px;
}
[data-toggle="tooltip"] {
text-decoration: dotted underline;
}

View file

@ -679,6 +679,7 @@ table.promoted-attributes-in-tooltip td, table.promoted-attributes-in-tooltip th
/* height needs to stay small because tooltip has problem when it can't fit to either top or bottom of the cursor */
max-height: 300px;
overflow: hidden;
font-size: var(--main-font-size);
color: var(--main-text-color);
border: 1px solid var(--main-border-color);
border-radius: 5px;

View file

@ -18,17 +18,35 @@
<input type="file" id="import-file-upload-input" class="form-control-file" multiple />
<p>Content of the file will be imported as child note(s) into <strong class="note-title"></strong>. Import file must be of supported type and have correct extension - one of <code>.html</code>, <code>.md</code>, <code>.tar</code>, <code>.enex</code>.</p>
<p>Content of the file will be imported as child note(s) into <strong class="note-title"></strong>.
</div>
<div class="form-group">
<strong>Options:</strong>
<div class="checkbox">
<label data-toggle="tooltip" title="Trilium <code>.tar</code> export files can contain executable scripts which may contain harmful behavior. Safe import will deactivate automatic execution of all imported scripts. Uncheck &quot;Safe import&quot; only if the imported tar archive is supposed to contain executable scripts and you completely trust the contents of the import file.">
<input id="safe-import" value="1" type="checkbox" checked>
Safe import
</label>
</div>
<div class="checkbox">
<label data-toggle="tooltip" title="<p>If you check this option, Trilium will attempt to optimize the imported images for size which may affect the perceived image quality. If unchecked, images will be imported without changes.</p><p>This doesn't apply to <code>.tar</code> imports with metadata since it is assumed these files are already optimized.</p>">
<input id="optimize-images" value="1" type="checkbox" checked> Optimize images
</label>
</div>
<div class="checkbox">
<label>
<input id="safe-import" value="1" type="checkbox" checked> <strong>Safe import</strong>
<input id="text-imported-as-text" value="1" type="checkbox" checked> Import HTML, Markdown and TXT as text notes if it's unclear from metadata
</label>
</div>
<br/>
Trilium <code>.tar</code> export files can contain executable scripts which may contain harmful behavior. Safe import will deactivate automatic execution of all imported scripts. Uncheck "Safe import" only if the imported tar archive is supposed to contain executable scripts and you completely trust the contents of the import file.
<div class="checkbox">
<label>
<input id="code-imported-as-code" value="1" type="checkbox" checked> Import recognized code files (e.g. <code>.json</code>) as code notes if it's unclear from metadata
</label>
</div>
</div>
</div>