Build your personal knowledge base with Trilium Notes
TypeScript electronelectron-appknowledge-baseknowledge-graphknowledge-managementknowledge-management-graphlocal-firstnote-managmentnote-takernote-takingnotebooknotesnotes-apppersonal-knowledge-basepersonal-wikiscriptableself-hostedself-hostingwiki
Merge remote-tracking branch 'origin/main' into feat/mermaid-highlighting
Elian Doran3e459fb93eaf
diff --cc apps/server/src/assets/help/help_content.jsonindex e71538cc4d,b123049942..d3cafb057e--- a/apps/server/src/assets/help/help_content.json+++ b/apps/server/src/assets/help/help_content.json@@@ -170,7 -170,7 +170,7 @@@"_help_AjqEeiDUOzj4": "<figure class=\"image image-style-align-right image_resized\" style=\"width:61.8%;\"><img style=\"aspect-ratio:953/587;\" src=\"{{helpAssets}}/User%20Guide/Note%20Types/File/Audio%20%26%20Video_image.png\" width=\"953\" height=\"587\"></figure><p>Starting with v0.103.0, Trilium has a custom media player for both video and audio files, which offers more features than the built-in player.</p><p>Versions prior to v0.103.0 also support media, but using the built-in player.</p><p>The file is streamed directly, so when accessing the note from a server it doesn't have to download the entire file to start playing it.</p><h2>Note on large media files</h2><p>Although Trilium offers support for media files, it is generally not meant to be used with very large files. Uploading large media will cause the <a class=\"reference-link\" href=\"#root/_help_wX4HbRucYSDD\">Database</a> to balloon, as well as any <a class=\"reference-link\" href=\"#root/_help_ODY7qQn5m2FT\">Backup</a> of it. In addition, there might be slowdowns when first uploading the files. Otherwise, a large database should not impact the general performance of Trilium significantly.</p><h2>Supported formats</h2><p>Trilium uses the built-in media decoding mechanism of the browser (or Electron/Chromium when running on the desktop). Starting with v0.103.0, a message will be displayed instead when a media format is not supported.</p><h2>Interactions</h2><p>To play/pause, simply click anywhere on the media. For video files, the controls at the bottom will hide automatically after playing, simply move the mouse to show them again.</p><p>The bottom bar has the following features:</p><ul><li>A track bar to seek across the media. Audio files up to 60 MB will display a waveform seekbar, to give a visual overview of the track's structure: silences, pauses, and louder segments.</li><li>On the left of the track bar, the current time is indicated.</li><li>On the right of the track bar, the remaining time is indicated.</li><li>On the left side there are buttons to:<ul><li>Adjust the playback speed (e.g. 0.5x, 1x).</li><li>Play mode (applies to all media from the parent note):<ul><li>Play once — play the media until it ends, then stop.</li><li>Loop — replay the media automatically once it ends.</li><li>Play next — when the current item ends, continue with the next one in the same parent note until the last item finishes.</li></ul></li><li>Rotate the video by 90 degrees (video only).</li></ul></li><li>In the center:<ul><li>Previous media — jumps to the previous media: the nearest media note above the current one in the tree (within the same parent note) in the case of media notes, or the previous media attachment.</li><li>Go back by 10s</li><li>Play/pause</li><li>Go forward by 10s</li><li>Next media — jumps to the next media: the nearest media note below the current one in the tree (within the same parent note) in the case of media notes, or the next media attachment.</li></ul></li><li>On the right side:<ul><li>Mute button</li><li>Volume adjustment</li><li>Full screen (video only)</li><li>Zoom to fill, which will crop the video so that it fills the entire window (video only).</li><li>Picture-in-picture, if the browser supports it (video only).</li></ul></li></ul><h2>Including media in notes</h2><figure class=\"image\"><img style=\"aspect-ratio:1395/145;\" src=\"{{helpAssets}}/User%20Guide/Note%20Types/File/1_Audio%20%26%20Video_image.png\" width=\"1395\" height=\"145\"><figcaption>An audio note include (configured to the \"Small\" size).</figcaption></figure><p><a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> and <a class=\"reference-link\" href=\"#root/_help_6RM1Q7ppFVoj\">Markdown</a> notes can embed an interactive media player directly in the note content. To do so, include the audio or video file:</p><ul><li><strong>Text notes:</strong> in the formatting toolbar, click <em>Insert</em> → <em>Include</em>.</li><li><strong>Markdown notes:</strong> type <code>/include</code> press <kbd>Enter</kbd>.</li></ul><p>Then select the audio/video file note to be included.</p><h2>Keyboard shortcuts</h2><p>The following keyboard shortcuts are supported by the media player:</p><figure class=\"table\"><table><tbody><tr><td><kbd>Space</kbd></td><td>Play/pause</td></tr><tr><td><kbd>Left arrow key</kbd></td><td>Go back by 10s</td></tr><tr><td><kbd>Right arrow key</kbd></td><td>Go forward by 10s</td></tr><tr><td><kbd>Ctrl</kbd> + <kbd>Left arrow key</kbd></td><td>Go back by 1 min</td></tr><tr><td><kbd>Ctrl</kbd> + <kbd>Right arrow key</kbd></td><td>Go right by 1 min</td></tr><tr><td><kbd>Page Up</kbd></td><td>Navigate to the previous media</td></tr><tr><td><kbd>Page Down</kbd></td><td>Navigate to the next media</td></tr><tr><td><kbd>F</kbd></td><td>Toggle full-screen</td></tr><tr><td><kbd>M</kbd></td><td>Mute/unmute</td></tr><tr><td><kbd>Home</kbd></td><td>Go to the beginning of the media</td></tr><tr><td><kbd>End</kbd></td><td>Go to the end of the media</td></tr><tr><td><kbd>Up</kbd></td><td>Increase volume by 5%</td></tr><tr><td><kbd>Down</kbd></td><td>Decrease volume by 5%</td></tr><tr><td><kbd>Alt+F1</kbd> (customizable)</td><td>Show this list of keyboard shortcuts on screen.</td></tr></tbody></table></figure>","_help_KG48zgNY31NW": "<p>Since v0.105.0, office documents stored in Trilium display an inline preview of their content, without the need to download them or open them in an external application.</p><h2>Supported formats</h2><ul><li>Microsoft Office formats: Word (<code>.docx</code>), Excel (<code>.xlsx</code>) and PowerPoint (<code>.pptx</code>).</li><li>The OpenDocument alternatives to the previous formats (Text, Spreadsheet, Presentation), created by editors such as LibreOffice and OpenOffice.</li><li><a href=\"https://en.wikipedia.org/wiki/Rich_Text_Format\">Rich Text Format (RTF)</a>.</li><li><a href=\"https://en.wikipedia.org/wiki/EPUB\">EPUB</a> e-books.</li></ul><aside class=\"admonition note\"><p>Older Microsoft Office formats (<code>.doc</code>, <code>.xls</code>, <code>.ppt</code>) are not supported.</p></aside><h2>How it works</h2><p>The document is converted to a simplified representation on the server and rendered as read-only content, similar to a <a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> note.</p><p>The preview generally preserves:</p><ul><li>Headings, paragraphs and text alignment.</li><li>Text formatting: bold, italic, underline, strikethrough, subscript/superscript, text and highlight colors, fonts and font sizes.</li><li>Bulleted and numbered lists.</li><li>Tables, including merged cells and cell background colors.</li><li>Embedded images.</li><li>Links and footnotes.</li></ul><p>To keep links readable regardless of the theme, the default hyperlink color applied automatically by word processors is ignored; links that were deliberately given a custom color by the author keep it.</p><h2>Limitations</h2><ul><li>The preview is read-only. To edit the document, download it or open it in an external application; the content of the note is not affected by the preview. Alternatively copy and paste it into a text note.</li><li>The preview is a simplified rendering: complex layouts (columns, text boxes, headers and footers), charts and the precise styling of table borders are not reproduced.</li><li>Documents larger than 20 MB are not previewed, to keep the server responsive. The usual download and open actions remain available.</li><li>If the document cannot be converted, a notice is displayed instead and the file can still be downloaded or opened externally.</li></ul><h2>Relation with other features</h2><ul><li>The same preview is used when an office document is displayed in the <a class=\"reference-link\" href=\"#root/_help_0ESUbbAxVnoK\">Note List</a> or embedded in a text note via <a class=\"reference-link\" href=\"#root/_help_nBAXQFj20hS1\">Include Note</a>, as well as for office documents stored as <a class=\"reference-link\" href=\"#root/_help_0vhv7lsOLy82\">Attachments</a>.</li><li>Independently of the preview, the text content of office documents is also extracted in the background so that it can be found with <a class=\"reference-link\" href=\"#root/_help_eIg8jdvaoNNd\">Search</a> via <a class=\"reference-link\" href=\"#root/_help_TiQbQDgP8L5t\">Text Extraction (OCR)</a>.</li><li><code>.csv</code> and <code>.xlsx</code> files can be converted to <a class=\"reference-link\" href=\"#root/_help_GWHEkY4I4OE3\">Spreadsheets</a> via the <a href=\"#root/_help_mHbBMPDPkVV5\">import</a> function.</li></ul>","_help_GWHEkY4I4OE3": "<figure class=\"image\"><img style=\"aspect-ratio:1102/573;\" src=\"{{helpAssets}}/User%20Guide/Note%20Types/Spreadsheets_image.png\" width=\"1102\" height=\"573\"></figure><aside class=\"admonition important\"><p>Spreadsheets are a new type of note introduced in v0.103.0 and are currently considered experimental/beta. As such, expect major changes to occur to this note type.</p></aside><p>Spreadsheets provide a familiar experience to Microsoft Excel or LibreOffice Calc, with support for formulas, data validation and text formatting.</p><h2>Spreadsheets vs. collections</h2><p>There is a slight overlap between spreadsheets and the <a class=\"reference-link\" href=\"#root/_help_2FvYrpmOXm29\">Table</a> collection. In general the table collection is useful to track meta-information about notes (for example a collection of people and their birthdays), whereas spreadsheets are quite useful for calculations since they support formulas.</p><p>Spreadsheets also benefit from a wider range of features such as data validation, formatting and can work on a relatively large dataset.</p><h2>Data intercompatibility (import/export)</h2><p>Starting with v0.104.0, Trilium provides a level of data intercompatibility between the internal format (Univer) and the following formats:</p><ul><li>Microsoft Excel (.xlsx)<ul><li>Preserves basic formatting (fonts, sizes, borders, backgrounds).</li><li>Formulas are preserved, but note that not all Excel functions are supported and vice-versa with Univer.</li><li>Images (cell-bound or floating), without preserving rotation.</li><li>Supports multi-sheets natively.</li></ul></li><li>Comma-Separated Values (.csv)<ul><li>Since it's a text-based format, any formatting is lost.</li><li>Formulas are evaluated and turned into their final value instead.</li><li>Multi-sheets spreadsheets are exported as a single ZIP containing a CSV file per sheet.</li></ul></li></ul><p>Both <a href=\"#root/_help_mHbBMPDPkVV5\">import and export</a> are supported, as follows:</p><ul><li>To import a file, simply drag it into the <a class=\"reference-link\" href=\"#root/_help_oPVyFC7WL2Lp\">Note Tree</a> and it will be converted into a spreadsheet note.<ul><li>To avoid this behavior (e.g. to import a .xlsx file as an actual <a class=\"reference-link\" href=\"#root/_help_W8vYD3Q1zjCR\">File</a>), uncheck the corresponding option in the <a href=\"#root/_help_mHbBMPDPkVV5\">Import dialog</a>.</li><li>Multiple files can be imported at the same time, including a mixture of .csv and .xlsx files. Folder structure can be preserved by using a .zip file.</li></ul></li><li>Unlike importing, exporting is on a per-note basis:<ul><li>In the <a class=\"reference-link\" href=\"#root/_help_8YBEPzcpUgxw\">Note menu</a>, choose the <em>Export to Excel</em> or <em>Export to CSV</em> options.</li><li>If exported as a single file via <a class=\"reference-link\" href=\"#root/_help_mHbBMPDPkVV5\">Import & Export</a>, the resulting file will be a custom <code>.triliumsheet</code> file that preserves the spreadsheet as-is.<ul><li>The export is intentionally a different process than the normal <a class=\"reference-link\" href=\"#root/_help_mHbBMPDPkVV5\">Import & Export</a> functionality because it does conversion to multiple formats with varying degrees of compatibility.</li></ul></li></ul></li></ul><p>Cells pasted from Excel or another application keep their formatting except for the font, so they use the spreadsheet's font like the rest of the cells.</p><aside class=\"admonition important\"><p>Import & export for both .xlsx and .csv files are supported on a best-effort basis. It does not support advanced features (data validation, scripting, etc.). If you notice a particular issue, it can be <a href=\"#root/_help_wy8So3yZZlH9\">reported</a>, however all bug reports must contain a sample file in order to be taken into consideration.</p></aside><h2>Supported features</h2><p>The spreadsheet has support for the following features:</p><ul><li>Since v0.104.0, images that can be either inside a cell or floating above.<ul><li>The images are saved as <a class=\"reference-link\" href=\"#root/_help_0vhv7lsOLy82\">Attachments</a> for performance reasons.</li><li>The image upload respects the same compression settings as text <a class=\"reference-link\" href=\"#root/_help_mT0HEkOsz6i1\">Images</a>.</li></ul></li><li>Filtering</li><li>Sorting</li><li>Data validation</li><li>Conditional formatting</li><li>Notes / annotations</li><li>Find / replace</li></ul><p>We might consider adding <a href=\"https://docs.univer.ai/guides/sheets/features/filter\">other features</a> from Univer at some point. If there is a particular feature that can be added easily, it can be discussed over <a href=\"#root/_help_wy8So3yZZlH9\">GitHub Issues</a>.</p><h3>Share functionality</h3><p>Spreadsheets can be <a href=\"#root/_help_R9pX4DGra2Vt\">shared</a>, case in which a best-effort HTML rendering of the spreadsheet is done:</p><ul><li>Preserves basic formatting.</li><li>Cells with formulas display the precalculated value instead of the formula.</li></ul><p>Since v0.104.0:</p><ul><li>Numbers and dates are properly formatted.</li><li>Images are shown inside a cell or floating above, including rotation.</li></ul><p>For more advanced use cases, this will most likely not work as intended. Feel free to <a href=\"#root/_help_wy8So3yZZlH9\">report issues</a>, but keep in mind that we might not be able to have a complete feature parity with all the features of Univer.</p><h2>Features not supported yet</h2><h3>Regarding Pro features</h3><p>Univer spreadsheets also feature a <a href=\"https://univer.ai/pro\">Pro plan</a> which adds quite a lot of functionality such as charts, printing, pivot tables, export, etc.</p><p>As the Pro plan needs a license, Trilium does not support any of the premium features. Theoretically, pro features can be used in trial mode with some limitations, we might explore this direction at some point.</p><h3>Planned features</h3><p>There are a few features that are already planned but are not supported yet:</p><ul><li>Trilium-specific formulas (e.g. to obtain the title of a note).</li><li>User-defined formulas</li><li>Cross-workbook calculation</li></ul><p>If you would like us to work on these features, consider <a href=\"https://triliumnotes.org/en/support-us\">supporting us</a>.</p><h3>Mobile support</h3><p>Versions prior to v0.104.0 have no dedicated mobile support, which means that the interaction is difficult without a mouse and keyboard. Starting with v0.104.0 we integrate Univer's mobile plugin, which introduces feature such as drag to pan which makes the interface more usable on mobile.</p>",- "_help_6RM1Q7ppFVoj": "<p>Trilium has always supported Markdown through its <a href=\"#root/_help_Oau6X9rCuegd\">import feature</a>, however the file was either transformed to a <a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> note (converted to Trilium's internal HTML format) or saved as a <a class=\"reference-link\" href=\"#root/_help_6f9hih2hXXZk\">Code</a> note with only syntax highlight.</p><p>This note type is a split view, meaning that both the source code and a preview of the document are displayed side-by-side. See <a class=\"reference-link\" href=\"#root/_help_SL5f1Auq7sVN\">Note types with split view</a> for more information.</p><h2>Rationale</h2><p>The goal of this note type is to fill a gap: rendering Markdown but not altering its structure or its whitespace which would inevitably change otherwise through import/export.</p><p>Even if Markdown is now specially treated by having a preview mechanism, Trilium remains at its core a WYSWYG editor so Markdown will not replace text notes.</p><aside class=\"admonition note\"><p>Feature requests regarding the Markdown implementation will be considered, but if they are outside the realm of Trilium, they will not be implemented. One of the core aspects of the Markdown integration is that it reuses components that are already available through other features of the application.</p></aside><h2>Features</h2><h3>Source view pane</h3><ul><li>Syntax highlighting for the Markdown syntax.</li><li>Nested syntax highlighting for code inside code blocks, including <a class=\"reference-link\" href=\"#root/_help_s1aBHPd79XYj\">Mermaid Diagrams</a> in <code>```mermaid</code> blocks.</li><li>When editing larger documents, the preview scrolls along with the source editor.</li></ul><h3>Preview pane</h3><p>The following features are supported by Trilium's Markdown format and will show up in the preview pane:</p><ul><li><p>All standard and GitHub-flavored syntax (basic formatting, tables, blockquotes).</p></li><li><p>Basic HTML is also supported (e.g. collapsible blocks using <code><details></code> and <code><summary></code>).</p></li><li><p>Code blocks with syntax highlight.</p><ul><li>The language must be specified for syntax highlight to be applied (e.g. <code>```js</code>).</li><li>Code blocks will respect the text wrapping from the <a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> section in <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a>.</li></ul></li><li><p><a class=\"reference-link\" href=\"#root/_help_NwBbFdNZ9h7O\">Block quotes & admonitions</a></p></li><li><p><a class=\"reference-link\" href=\"#root/_help_YfYAtQBcfo5V\">Math Equations</a> (both inline and block)</p></li><li><p><a class=\"reference-link\" href=\"#root/_help_s1aBHPd79XYj\">Mermaid Diagrams</a> using <code>```mermaid</code></p></li><li><p><a class=\"reference-link\" href=\"#root/_help_nBAXQFj20hS1\">Include Note</a> (no built-in Markdown syntax, but HTML syntax works just fine):</p><pre><code class=\"language-text-html\"><figure class=\"include-note\" data-note-id=\"vJDjQm0VK8Na\" data-box-size=\"expandable\">\n <figcaption>An optional caption, with <strong>HTML</strong> formatting</figcaption>\n</figure></code></pre><ul><li>The caption is optional. Markdown is not processed inside the HTML block, so format the caption with HTML tags.</li><li>Includes written as <code><section class=\"include-note\"></code>, the syntax of earlier versions, still work.</li><li>These can also be quickly created via the <code>/include</code> command or via a dedicated keyboard shortcut (not assigned by default).</li></ul></li><li><p><a class=\"reference-link\" href=\"#root/_help_hrZ1D00cLbal\">Internal (reference) links</a> via its HTML syntax, or through a <em>Wikilinks</em>-like format (only <a class=\"reference-link\" href=\"#root/_help_m1lbrzyKDaRB\">Note ID</a>):</p><pre><code class=\"language-text-x-trilium-auto\">[[Hg8TS5ZOxti6]]</code></pre></li><li><p>To-do lists with extended task states:</p><figure class=\"table\"><table class=\"ck-table-resized\" style=\"border-style:none;\"><colgroup><col style=\"width:80.6%;\"><col style=\"width:19.4%;\"></colgroup><tbody><tr><td><pre><code class=\"language-text-x-markdown\">- [ ] None\n- [/] Doing\n- [X] Done\n- [?] Maybe\n- [-] Cancelled</code></pre></td><td><figure class=\"image image-style-align-right\"><img style=\"aspect-ratio:218/221;\" src=\"{{helpAssets}}/User%20Guide/Note%20Types/Markdown_image.png\" width=\"218\" height=\"221\"></figure></td></tr></tbody></table></figure><p>Task states are customizable: you can reorder them, create new ones with different colors and symbols, or delete the ones you don't need. See <a class=\"reference-link\" href=\"#root/_help_i16PM6A7GXdU\">Customizing to-do task states</a> for more details.</p><p>Note that to-do items with task states other than \"None\" and \"Done\" are Trilium-specific and may not work well with other Markdown software.</p></li><li><p><a class=\"reference-link\" href=\"#root/_help_AgjCISero73a\">Footnotes</a> are also supported via the corresponding Markdown syntax:</p><pre><code class=\"language-text-x-trilium-auto\">This is [^1], while this is [^2].\n\n[^1]: the first footnote\n[^2]: the second footnote</code></pre><ul><li>These can also be quickly created using the <code>/footnote</code> command.</li></ul></li><li><p>Page breaks for <a class=\"reference-link\" href=\"#root/_help_NRnIZmSMc5sj\">Printing & Exporting as PDF</a>:</p><pre><code class=\"language-text-x-trilium-auto\"><div class=\"page-break\"></div></code></pre></li><li><p>Highlights (background color) are supported both via the <code>==</code> Markdown syntax, as well as the canonical HTML representation in Trilium:</p><pre><code class=\"language-text-x-trilium-auto\">==highlighted==\n<span style=\"background-color:#e5e64d;--tn-background:#e5e64d;\">Highlighted</span></code></pre></li></ul><h3>Links</h3><p>Multiple types of links are supported:</p><ul><li><p>Web URLs can be written with the standard Markdown syntax:</p><pre><code class=\"language-text-x-trilium-auto\">[Wikipedia](https://www.wikipedia.org)</code></pre></li><li><p><a href=\"#root/_help_hrZ1D00cLbal\">Reference link</a> to other notes with dynamic title, either by manually entering the note ID or via the <em>Add link</em> dialog:</p><pre><code class=\"language-text-x-trilium-auto\">[[B9oMG6rFvvfq]]</code></pre></li><li><p><a href=\"#root/_help_hrZ1D00cLbal\">Reference link</a> to other notes with a custom text:</p><pre><code class=\"language-text-x-trilium-auto\">[This is a link](#root/LhtnZxtVsUMp)</code></pre></li></ul><p>To create a link, either:</p><ul><li>Type it manually using the syntax described above.</li><li>Use the <em>Add link</em> dialog by pressing <kbd>Ctrl</kbd>+<kbd>L</kbd> or typing the <code>/link</code> command.</li></ul><p><a class=\"reference-link\" href=\"#root/_help_UmgZAfcltxkS\">Link Previews</a> are also rendered, but there is no mechanism to insert them automatically as of now, they have to be copied from a <a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> note instead.</p><h3>Keyboard shortcuts</h3><p>The Markdown notes share some of the keyboard shortcuts from <a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> notes:</p><ul><li><em>Cut to note</em> (<kbd>Ctrl</kbd>+<kbd>X</kbd>) which cuts the selection into a new child note.</li><li><em>Add link</em> (<kbd>Ctrl</kbd>+<kbd>L</kbd>) which shows the dialog to create external or reference links.</li><li><em>Date/time</em> (<kbd>Alt</kbd>+<kbd>T</kbd>) which respects the same formatting as text notes.</li><li><em>Include note</em> (not assigned by default), which triggers the same dialog to insert notes as the one for text notes.</li></ul><p>In addition, the following formatting keyboard shortcuts are available:</p><ul><li><kbd>Ctrl</kbd>+<kbd>B</kbd> to toggle <strong>bold</strong>.</li><li><kbd>Ctrl</kbd>+<kbd>I</kbd> to toggle <em>italic</em>.</li><li><kbd>Ctrl</kbd>+<kbd>M</kbd> to wrap the current selection in an inline math (<code>$</code>).</li><li><kbd>Ctrl</kbd>+<kbd>Shift</kbd>+<kbd>X</kbd> to toggle <del>strikethrough</del>.</li></ul><h3>Images & attachments</h3><p>Images can be inserted into the document in four different methods:</p><ul><li>Drag & drop directly into the editor area.</li><li>Pasting an image from clipboard.</li><li>Pasting a reference to another <a href=\"#root/_help_0vhv7lsOLy82\">attachment</a> (e.g. <em>Copy reference to clipboard</em> button).</li><li>Use the <code>/image</code> slash command.</li></ul><p>An image reference to an attachment looks like this:</p><pre><code class=\"language-text-x-trilium-auto\"></code></pre><h3>Auto-completion</h3><h4>Slash commands</h4><p>Just like <a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> notes, Markdown notes support a selection of slash commands:</p><ul><li>Inserting the current date & time (<code>/date</code>).</li><li><a href=\"#root/_help_nBAXQFj20hS1\">Including</a> another note (<code>/include</code>).</li><li>Uploading and inserting an image (<code>/image</code>).</li><li>Inserting a note link (<code>/link</code>).</li><li>Inserting a math equation block (<code>/math</code>).</li><li>Inserting a <a href=\"#root/_help_AgjCISero73a\">footnote</a> (<code>/footnote</code>).</li><li>Inserting a <a href=\"#root/_help_s1aBHPd79XYj\">Mermaid</a> diagram (<code>/mermaid</code>), with one variant per sample template (e.g. <code>/mermaid:flowchart</code>).</li><li>Inserting a collapsible block (<code>/collapsible</code>).</li><li>Inserting <a href=\"#root/_help_rJ9grSgoExl9\">tabs</a> (<code>/tabs</code>).</li><li>Inserting a page break for printing (<code>/page-break</code>).</li><li>Inserting a table (<code>/table</code>).</li><li>Creating admonitions (e.g. <code>/tip</code>, <code>/note</code>, <code>/important</code>, <code>/caution</code>, <code>/warning</code>).</li><li>Inserting task items (<code>/todo:<state></code>, e.g. <code>/todo:done</code>), one per configured task state.</li><li>Inserting code snippets (<code>/snippet:<name></code>) from your Markdown/plain-text snippet notes.</li></ul><p>The list shows each command by its title, as in Text notes. Typing a command's title, its keyword (as listed above) or a related word such as <code>latex</code> or <code>grid</code> finds it.</p><p>Note that slash commands only work outside of code blocks and inline code.</p><h4>Linking notes with <code>@</code> or <code>[[</code></h4><p>As in <a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> notes, typing <code>@</code> at the start of a line or after a space opens the note search. Picking a note replaces what was typed with a link to it in the Wikilinks-like format (<code>[[noteId]]</code>), which the preview shows as an <a class=\"reference-link\" href=\"#root/_help_hrZ1D00cLbal\">Internal (reference) links</a> with the note's title.</p><p>The search runs on everything typed after the <code>@</code>, spaces included, so a title such as <code>@My meeting notes</code> can be typed out; press <kbd>Esc</kbd> to close the list and go on writing. If no note fits, the list offers to create one, as a child of the Markdown note or in the inbox; the link is inserted once the note is created.</p><p>You can also start typing the link directly: <code>[[</code> opens the same list, and closing the brackets yourself dismisses it. To change where an existing link points, place the cursor inside it and pick another note.</p><p>Like slash commands, <code>@</code> and <code>[[</code> do nothing inside code blocks and inline code.</p><p>In the editor, a <code>[[noteId]]</code> link shows as the note's icon and title, so you can tell which note it points to without looking up its ID. Clicking it, or moving the cursor next to it, shows the link as written so it can be edited. Links inside code blocks and inline code are left as they are.</p><h4>Code block language auto-completion</h4><p>Starting with v0.104.0, typing ``` to insert a code block will automatically open a list of suggested language types which have syntax highlighting.</p><p>The list of languages matches the one for <a class=\"reference-link\" href=\"#root/_help_6f9hih2hXXZk\">Code</a> notes set in <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a>, it's not the full list of languages supported by Trilium.</p><h3>Other features</h3><ul><li>The <a class=\"reference-link\" href=\"#root/_help_BFvAtE74rbP6\">Table of contents</a> will be displayed in the <a class=\"reference-link\" href=\"#root/_help_RnaPdbciOfeq\">Right Sidebar</a> based on the Markdown-level headings.</li></ul><h3>Shared notes</h3><p>When a Markdown note is <a href=\"#root/_help_R9pX4DGra2Vt\">shared publicly</a>, it will be rendered with extended formatting just like <a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> notes.</p><p>Most of the features described previously should be supported. If you face any issues, feel free to <a href=\"#root/_help_wy8So3yZZlH9\">report it</a> alongside a sample Markdown file.</p><h2>Creating Markdown notes</h2><p>There are two ways to create a Markdown note:</p><ol><li>Create a new note (e.g. in the <a class=\"reference-link\" href=\"#root/_help_oPVyFC7WL2Lp\">Note Tree</a>) and select the type <em>Markdown</em>, just like all the other note types.</li><li>Create a note of type <a class=\"reference-link\" href=\"#root/_help_6f9hih2hXXZk\">Code</a> and select as the language either <em>Markdown</em> or <em>GitHub-Flavored Markdown</em>. This maintains compatibility with your existing notes prior to the introduction of this feature.</li></ol><aside class=\"admonition note\"><p>There is no distinction between the new Markdown note type and code notes of type Markdown; internally both are represented as <a class=\"reference-link\" href=\"#root/_help_6f9hih2hXXZk\">Code</a> notes with one of the following MIME types:</p><ul><li><code>text/markdown</code></li><li><code>text/x-markdown</code></li><li><code>text/x-gfm</code> (GitHub Flavored Markdown)</li></ul></aside><h2>Import/export</h2><h3>Import</h3><p>By default, when importing a single Markdown file it automatically gets converted to a <a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> note. To avoid that and have it imported as a Markdown note instead:</p><ul><li>Right click the <a class=\"reference-link\" href=\"#root/_help_oPVyFC7WL2Lp\">Note Tree</a> and select <em>Import into note</em>.</li><li>Select the file normally.</li><li>Uncheck <em>Import HTML, Markdown and TXT as text notes if it's unclear from the metadata</em>.</li></ul><p>When importing a Trilium ZIP, it will preserve the Markdown type without converting to text notes thanks to the meta-information in it.</p><h3>Exporting</h3><p>When exporting Markdown files, the extension is preserved and the content remains the same as in the source view (with some small exceptions such as handling of attachments).</p><p>When exporting Markdown files as ZIP, choosing HTML or Markdown as the export format makes no difference as that only affects <a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> notes.</p><p>If the Markdown note contains attachments, a ZIP export will rewrite the links to attachments so that they are replaced with a relative path to the attachment. On import, the links are re-written back.</p><h2>Conversion between text notes and Markdown notes</h2><p><a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> notes can be converted into Markdown notes and vice versa. See <a class=\"reference-link\" href=\"#root/_help_jludwdW7N4hg\">Converting between note types</a>.</p><h2>Sync-scrolling & block highlight</h2><p>When scrolling through the editing pane, the preview pane will attempt to synchronize its position to make it easier to see the preview.</p><p>In addition, the block in the preview matching the position of the cursor in the source view will appear slightly highlighted.</p><p>The sync is currently one-way only, scrolling the preview will not synchronize the position of the editor.</p><p>This feature cannot be disabled as of now; if the scrolling feels distracting, consider temporarily switching to the editor mode and then switching to preview mode when ready.</p><aside class=\"admonition note\"><p>This feature of synchronizing the scroll is based on blocks but it's provided on a best-effort basis since our underlying Markdown library doesn't support this feature natively, so we had to implement our own algorithm. Feel free to <a href=\"#root/_help_wy8So3yZZlH9\">report issues</a>, but always provide a sample Markdown file to be able to reproduce it.</p></aside>",- "_help_6RM1Q7ppFVoj": "<p>Trilium has always supported Markdown through its <a href=\"#root/_help_Oau6X9rCuegd\">import feature</a>, however the file was either transformed to a <a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> note (converted to Trilium's internal HTML format) or saved as a <a class=\"reference-link\" href=\"#root/_help_6f9hih2hXXZk\">Code</a> note with only syntax highlight.</p><p>This note type is a split view, meaning that both the source code and a preview of the document are displayed side-by-side. See <a class=\"reference-link\" href=\"#root/_help_SL5f1Auq7sVN\">Note types with split view</a> for more information.</p><h2>Rationale</h2><p>The goal of this note type is to fill a gap: rendering Markdown but not altering its structure or its whitespace which would inevitably change otherwise through import/export.</p><p>Even if Markdown is now specially treated by having a preview mechanism, Trilium remains at its core a WYSWYG editor so Markdown will not replace text notes.</p><aside class=\"admonition note\"><p>Feature requests regarding the Markdown implementation will be considered, but if they are outside the realm of Trilium, they will not be implemented. One of the core aspects of the Markdown integration is that it reuses components that are already available through other features of the application.</p></aside><h2>Features</h2><h3>Source view pane</h3><ul><li>Syntax highlighting for the Markdown syntax.</li><li>Nested syntax highlighting for code inside code blocks.</li><li>When editing larger documents, the preview scrolls along with the source editor.</li></ul><h3>Preview pane</h3><p>The following features are supported by Trilium's Markdown format and will show up in the preview pane:</p><ul><li><p>All standard and GitHub-flavored syntax (basic formatting, tables, blockquotes).</p></li><li><p>Basic HTML is also supported (e.g. collapsible blocks using <code><details></code> and <code><summary></code>).</p></li><li><p>Code blocks with syntax highlight.</p><ul><li>The language must be specified for syntax highlight to be applied (e.g. <code>```js</code>).</li><li>Code blocks will respect the text wrapping from the <a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> section in <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a>.</li></ul></li><li><p><a class=\"reference-link\" href=\"#root/_help_NwBbFdNZ9h7O\">Block quotes & admonitions</a></p></li><li><p><a class=\"reference-link\" href=\"#root/_help_YfYAtQBcfo5V\">Math Equations</a> (both inline and block)</p></li><li><p><a class=\"reference-link\" href=\"#root/_help_s1aBHPd79XYj\">Mermaid Diagrams</a> using <code>```mermaid</code></p></li><li><p><a class=\"reference-link\" href=\"#root/_help_nBAXQFj20hS1\">Include Note</a> (no built-in Markdown syntax, but HTML syntax works just fine):</p><pre><code class=\"language-text-html\"><figure class=\"include-note\" data-note-id=\"vJDjQm0VK8Na\" data-box-size=\"expandable\">\n <figcaption>An optional caption, with <strong>HTML</strong> formatting</figcaption>\n</figure></code></pre><ul><li>The caption is optional. Markdown is not processed inside the HTML block, so format the caption with HTML tags.</li><li>Includes written as <code><section class=\"include-note\"></code>, the syntax of earlier versions, still work.</li><li>These can also be quickly created via the <code>/include</code> command or via a dedicated keyboard shortcut (not assigned by default).</li></ul></li><li><p><a class=\"reference-link\" href=\"#root/_help_hrZ1D00cLbal\">Internal (reference) links</a> via its HTML syntax, or through a <em>Wikilinks</em>-like format (only <a class=\"reference-link\" href=\"#root/_help_m1lbrzyKDaRB\">Note ID</a>):</p><pre><code class=\"language-text-x-trilium-auto\">[[Hg8TS5ZOxti6]]</code></pre></li><li><p>To-do lists with extended task states:</p><figure class=\"table\"><table class=\"ck-table-resized\" style=\"border-style:none;\"><colgroup><col style=\"width:80.6%;\"><col style=\"width:19.4%;\"></colgroup><tbody><tr><td><pre><code class=\"language-text-x-markdown\">- [ ] None\n- [/] Doing\n- [X] Done\n- [?] Maybe\n- [-] Cancelled</code></pre></td><td><figure class=\"image image-style-align-right\"><img style=\"aspect-ratio:218/221;\" src=\"{{helpAssets}}/User%20Guide/Note%20Types/Markdown_image.png\" width=\"218\" height=\"221\"></figure></td></tr></tbody></table></figure><p>Task states are customizable: you can reorder them, create new ones with different colors and symbols, or delete the ones you don't need. See <a class=\"reference-link\" href=\"#root/_help_i16PM6A7GXdU\">Customizing to-do task states</a> for more details.</p><p>Note that to-do items with task states other than \"None\" and \"Done\" are Trilium-specific and may not work well with other Markdown software.</p></li><li><p><a class=\"reference-link\" href=\"#root/_help_AgjCISero73a\">Footnotes</a> are also supported via the corresponding Markdown syntax:</p><pre><code class=\"language-text-x-trilium-auto\">This is [^1], while this is [^2].\n\n[^1]: the first footnote\n[^2]: the second footnote</code></pre><ul><li>These can also be quickly created using the <code>/footnote</code> command.</li></ul></li><li><p>Page breaks for <a class=\"reference-link\" href=\"#root/_help_NRnIZmSMc5sj\">Printing & Exporting as PDF</a>:</p><pre><code class=\"language-text-x-trilium-auto\"><div class=\"page-break\"></div></code></pre></li><li><p>Highlights (background color) are supported both via the <code>==</code> Markdown syntax, as well as the canonical HTML representation in Trilium:</p><pre><code class=\"language-text-x-trilium-auto\">==highlighted==\n<span style=\"background-color:#e5e64d;--tn-background:#e5e64d;\">Highlighted</span></code></pre></li></ul><h3>Links</h3><p>Multiple types of links are supported:</p><ul><li><p>Web URLs can be written with the standard Markdown syntax:</p><pre><code class=\"language-text-x-trilium-auto\">[Wikipedia](https://www.wikipedia.org)</code></pre></li><li><p><a href=\"#root/_help_hrZ1D00cLbal\">Reference link</a> to other notes with dynamic title, either by manually entering the note ID or via the <em>Add link</em> dialog:</p><pre><code class=\"language-text-x-trilium-auto\">[[B9oMG6rFvvfq]]</code></pre></li><li><p><a href=\"#root/_help_hrZ1D00cLbal\">Reference link</a> to other notes with a custom text:</p><pre><code class=\"language-text-x-trilium-auto\">[This is a link](#root/LhtnZxtVsUMp)</code></pre></li></ul><p>To create a link, either:</p><ul><li>Type it manually using the syntax described above.</li><li>Use the <em>Add link</em> dialog by pressing <kbd>Ctrl</kbd>+<kbd>L</kbd> or typing the <code>/link</code> command.</li></ul><p><a class=\"reference-link\" href=\"#root/_help_UmgZAfcltxkS\">Link Previews</a> are also rendered, but there is no mechanism to insert them automatically as of now, they have to be copied from a <a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> note instead.</p><h3>Keyboard shortcuts</h3><p>The Markdown notes share some of the keyboard shortcuts from <a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> notes:</p><ul><li><em>Cut to note</em> (<kbd>Ctrl</kbd>+<kbd>X</kbd>) which cuts the selection into a new child note.</li><li><em>Add link</em> (<kbd>Ctrl</kbd>+<kbd>L</kbd>) which shows the dialog to create external or reference links.</li><li><em>Date/time</em> (<kbd>Alt</kbd>+<kbd>T</kbd>) which respects the same formatting as text notes.</li><li><em>Include note</em> (not assigned by default), which triggers the same dialog to insert notes as the one for text notes.</li></ul><p>In addition, the following formatting keyboard shortcuts are available:</p><ul><li><kbd>Ctrl</kbd>+<kbd>B</kbd> to toggle <strong>bold</strong>.</li><li><kbd>Ctrl</kbd>+<kbd>I</kbd> to toggle <em>italic</em>.</li><li><kbd>Ctrl</kbd>+<kbd>M</kbd> to wrap the current selection in an inline math (<code>$</code>).</li><li><kbd>Ctrl</kbd>+<kbd>Shift</kbd>+<kbd>X</kbd> to toggle <del>strikethrough</del>.</li></ul><h3>Images & attachments</h3><p>Images can be inserted into the document in four different methods:</p><ul><li>Drag & drop directly into the editor area.</li><li>Pasting an image from clipboard.</li><li>Pasting a reference to another <a href=\"#root/_help_0vhv7lsOLy82\">attachment</a> (e.g. <em>Copy reference to clipboard</em> button).</li><li>Use the <code>/image</code> slash command.</li></ul><p>An image reference to an attachment looks like this:</p><pre><code class=\"language-text-x-trilium-auto\"></code></pre><h3>Auto-completion</h3><h4>Slash commands</h4><p>Just like <a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> notes, Markdown notes support a selection of slash commands:</p><ul><li>Inserting the current date & time (<code>/date</code>).</li><li><a href=\"#root/_help_nBAXQFj20hS1\">Including</a> another note (<code>/include</code>).</li><li>Uploading and inserting an image (<code>/image</code>).</li><li>Inserting a note link (<code>/link</code>).</li><li>Inserting a math equation block (<code>/math</code>).</li><li>Inserting a <a href=\"#root/_help_AgjCISero73a\">footnote</a> (<code>/footnote</code>).</li><li>Inserting a <a href=\"#root/_help_s1aBHPd79XYj\">Mermaid</a> diagram (<code>/mermaid</code>), with one variant per sample template (e.g. <code>/mermaid:flowchart</code>).</li><li>Inserting a collapsible block (<code>/collapsible</code>).</li><li>Inserting <a href=\"#root/_help_rJ9grSgoExl9\">tabs</a> (<code>/tabs</code>).</li><li>Inserting a page break for printing (<code>/page-break</code>).</li><li>Inserting a table (<code>/table</code>).</li><li>Creating admonitions (e.g. <code>/tip</code>, <code>/note</code>, <code>/important</code>, <code>/caution</code>, <code>/warning</code>).</li><li>Inserting task items (<code>/todo:<state></code>, e.g. <code>/todo:done</code>), one per configured task state.</li><li>Inserting code snippets (<code>/snippet:<name></code>) from your Markdown/plain-text snippet notes.</li></ul><p>The list shows each command by its title, as in Text notes. Typing a command's title, its keyword (as listed above) or a related word such as <code>latex</code> or <code>grid</code> finds it.</p><p>Note that slash commands only work outside of code blocks and inline code.</p><h4>Linking notes with <code>@</code> or <code>[[</code></h4><p>As in <a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> notes, typing <code>@</code> at the start of a line or after a space opens the note search. Picking a note replaces what was typed with a link to it in the Wikilinks-like format (<code>[[noteId]]</code>), which the preview shows as an <a class=\"reference-link\" href=\"#root/_help_hrZ1D00cLbal\">Internal (reference) links</a> with the note's title.</p><p>The search runs on everything typed after the <code>@</code>, spaces included, so a title such as <code>@My meeting notes</code> can be typed out; press <kbd>Esc</kbd> to close the list and go on writing. If no note fits, the list offers to create one, as a child of the Markdown note or in the inbox; the link is inserted once the note is created.</p><p>You can also start typing the link directly: <code>[[</code> opens the same list, and closing the brackets yourself dismisses it. To change where an existing link points, place the cursor inside it and pick another note.</p><p>Like slash commands, <code>@</code> and <code>[[</code> do nothing inside code blocks and inline code.</p><p>In the editor, a <code>[[noteId]]</code> link shows as the note's icon and title, so you can tell which note it points to without looking up its ID. Clicking it, or moving the cursor next to it, shows the link as written so it can be edited. Links inside code blocks and inline code are left as they are.</p><h4>Code block language auto-completion</h4><p>Starting with v0.104.0, typing ``` to insert a code block will automatically open a list of suggested language types which have syntax highlighting.</p><p>The list of languages matches the one for <a class=\"reference-link\" href=\"#root/_help_6f9hih2hXXZk\">Code</a> notes set in <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a>, it's not the full list of languages supported by Trilium.</p><h3>Other features</h3><ul><li>The <a class=\"reference-link\" href=\"#root/_help_BFvAtE74rbP6\">Table of contents</a> will be displayed in the <a class=\"reference-link\" href=\"#root/_help_RnaPdbciOfeq\">Right Sidebar</a> based on the Markdown-level headings.</li><li>A Markdown note included in a <a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> note shows its source, its preview or both, and can be edited in place. See <em>Included Markdown</em> in <a class=\"reference-link\" href=\"#root/_help_nBAXQFj20hS1\">Include Note</a>.</li></ul><h3>Shared notes</h3><p>When a Markdown note is <a href=\"#root/_help_R9pX4DGra2Vt\">shared publicly</a>, it will be rendered with extended formatting just like <a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> notes.</p><p>Most of the features described previously should be supported. If you face any issues, feel free to <a href=\"#root/_help_wy8So3yZZlH9\">report it</a> alongside a sample Markdown file.</p><h2>Creating Markdown notes</h2><p>There are two ways to create a Markdown note:</p><ol><li>Create a new note (e.g. in the <a class=\"reference-link\" href=\"#root/_help_oPVyFC7WL2Lp\">Note Tree</a>) and select the type <em>Markdown</em>, just like all the other note types.</li><li>Create a note of type <a class=\"reference-link\" href=\"#root/_help_6f9hih2hXXZk\">Code</a> and select as the language either <em>Markdown</em> or <em>GitHub-Flavored Markdown</em>. This maintains compatibility with your existing notes prior to the introduction of this feature.</li></ol><aside class=\"admonition note\"><p>There is no distinction between the new Markdown note type and code notes of type Markdown; internally both are represented as <a class=\"reference-link\" href=\"#root/_help_6f9hih2hXXZk\">Code</a> notes with one of the following MIME types:</p><ul><li><code>text/markdown</code></li><li><code>text/x-markdown</code></li><li><code>text/x-gfm</code> (GitHub Flavored Markdown)</li></ul></aside><h2>Import/export</h2><h3>Import</h3><p>By default, when importing a single Markdown file it automatically gets converted to a <a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> note. To avoid that and have it imported as a Markdown note instead:</p><ul><li>Right click the <a class=\"reference-link\" href=\"#root/_help_oPVyFC7WL2Lp\">Note Tree</a> and select <em>Import into note</em>.</li><li>Select the file normally.</li><li>Uncheck <em>Import HTML, Markdown and TXT as text notes if it's unclear from the metadata</em>.</li></ul><p>When importing a Trilium ZIP, it will preserve the Markdown type without converting to text notes thanks to the meta-information in it.</p><h3>Exporting</h3><p>When exporting Markdown files, the extension is preserved and the content remains the same as in the source view (with some small exceptions such as handling of attachments).</p><p>When exporting Markdown files as ZIP, choosing HTML or Markdown as the export format makes no difference as that only affects <a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> notes.</p><p>If the Markdown note contains attachments, a ZIP export will rewrite the links to attachments so that they are replaced with a relative path to the attachment. On import, the links are re-written back.</p><h2>Conversion between text notes and Markdown notes</h2><p><a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> notes can be converted into Markdown notes and vice versa. See <a class=\"reference-link\" href=\"#root/_help_jludwdW7N4hg\">Converting between note types</a>.</p><h2>Sync-scrolling & block highlight</h2><p>When scrolling through the editing pane, the preview pane will attempt to synchronize its position to make it easier to see the preview.</p><p>In addition, the block in the preview matching the position of the cursor in the source view will appear slightly highlighted.</p><p>The sync is currently one-way only, scrolling the preview will not synchronize the position of the editor.</p><p>This feature cannot be disabled as of now; if the scrolling feels distracting, consider temporarily switching to the editor mode and then switching to preview mode when ready.</p><aside class=\"admonition note\"><p>This feature of synchronizing the scroll is based on blocks but it's provided on a best-effort basis since our underlying Markdown library doesn't support this feature natively, so we had to implement our own algorithm. Feel free to <a href=\"#root/_help_wy8So3yZZlH9\">report issues</a>, but always provide a sample Markdown file to be able to reproduce it.</p></aside>",++ "_help_6RM1Q7ppFVoj": "<p>Trilium has always supported Markdown through its <a href=\"#root/_help_Oau6X9rCuegd\">import feature</a>, however the file was either transformed to a <a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> note (converted to Trilium's internal HTML format) or saved as a <a class=\"reference-link\" href=\"#root/_help_6f9hih2hXXZk\">Code</a> note with only syntax highlight.</p><p>This note type is a split view, meaning that both the source code and a preview of the document are displayed side-by-side. See <a class=\"reference-link\" href=\"#root/_help_SL5f1Auq7sVN\">Note types with split view</a> for more information.</p><h2>Rationale</h2><p>The goal of this note type is to fill a gap: rendering Markdown but not altering its structure or its whitespace which would inevitably change otherwise through import/export.</p><p>Even if Markdown is now specially treated by having a preview mechanism, Trilium remains at its core a WYSWYG editor so Markdown will not replace text notes.</p><aside class=\"admonition note\"><p>Feature requests regarding the Markdown implementation will be considered, but if they are outside the realm of Trilium, they will not be implemented. One of the core aspects of the Markdown integration is that it reuses components that are already available through other features of the application.</p></aside><h2>Features</h2><h3>Source view pane</h3><ul><li>Syntax highlighting for the Markdown syntax.</li><li>Nested syntax highlighting for code inside code blocks, including <a class=\"reference-link\" href=\"#root/_help_s1aBHPd79XYj\">Mermaid Diagrams</a> in <code>```mermaid</code> blocks.</li><li>When editing larger documents, the preview scrolls along with the source editor.</li></ul><h3>Preview pane</h3><p>The following features are supported by Trilium's Markdown format and will show up in the preview pane:</p><ul><li><p>All standard and GitHub-flavored syntax (basic formatting, tables, blockquotes).</p></li><li><p>Basic HTML is also supported (e.g. collapsible blocks using <code><details></code> and <code><summary></code>).</p></li><li><p>Code blocks with syntax highlight.</p><ul><li>The language must be specified for syntax highlight to be applied (e.g. <code>```js</code>).</li><li>Code blocks will respect the text wrapping from the <a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> section in <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a>.</li></ul></li><li><p><a class=\"reference-link\" href=\"#root/_help_NwBbFdNZ9h7O\">Block quotes & admonitions</a></p></li><li><p><a class=\"reference-link\" href=\"#root/_help_YfYAtQBcfo5V\">Math Equations</a> (both inline and block)</p></li><li><p><a class=\"reference-link\" href=\"#root/_help_s1aBHPd79XYj\">Mermaid Diagrams</a> using <code>```mermaid</code></p></li><li><p><a class=\"reference-link\" href=\"#root/_help_nBAXQFj20hS1\">Include Note</a> (no built-in Markdown syntax, but HTML syntax works just fine):</p><pre><code class=\"language-text-html\"><figure class=\"include-note\" data-note-id=\"vJDjQm0VK8Na\" data-box-size=\"expandable\">\n <figcaption>An optional caption, with <strong>HTML</strong> formatting</figcaption>\n</figure></code></pre><ul><li>The caption is optional. Markdown is not processed inside the HTML block, so format the caption with HTML tags.</li><li>Includes written as <code><section class=\"include-note\"></code>, the syntax of earlier versions, still work.</li><li>These can also be quickly created via the <code>/include</code> command or via a dedicated keyboard shortcut (not assigned by default).</li></ul></li><li><p><a class=\"reference-link\" href=\"#root/_help_hrZ1D00cLbal\">Internal (reference) links</a> via its HTML syntax, or through a <em>Wikilinks</em>-like format (only <a class=\"reference-link\" href=\"#root/_help_m1lbrzyKDaRB\">Note ID</a>):</p><pre><code class=\"language-text-x-trilium-auto\">[[Hg8TS5ZOxti6]]</code></pre></li><li><p>To-do lists with extended task states:</p><figure class=\"table\"><table class=\"ck-table-resized\" style=\"border-style:none;\"><colgroup><col style=\"width:80.6%;\"><col style=\"width:19.4%;\"></colgroup><tbody><tr><td><pre><code class=\"language-text-x-markdown\">- [ ] None\n- [/] Doing\n- [X] Done\n- [?] Maybe\n- [-] Cancelled</code></pre></td><td><figure class=\"image image-style-align-right\"><img style=\"aspect-ratio:218/221;\" src=\"{{helpAssets}}/User%20Guide/Note%20Types/Markdown_image.png\" width=\"218\" height=\"221\"></figure></td></tr></tbody></table></figure><p>Task states are customizable: you can reorder them, create new ones with different colors and symbols, or delete the ones you don't need. See <a class=\"reference-link\" href=\"#root/_help_i16PM6A7GXdU\">Customizing to-do task states</a> for more details.</p><p>Note that to-do items with task states other than \"None\" and \"Done\" are Trilium-specific and may not work well with other Markdown software.</p></li><li><p><a class=\"reference-link\" href=\"#root/_help_AgjCISero73a\">Footnotes</a> are also supported via the corresponding Markdown syntax:</p><pre><code class=\"language-text-x-trilium-auto\">This is [^1], while this is [^2].\n\n[^1]: the first footnote\n[^2]: the second footnote</code></pre><ul><li>These can also be quickly created using the <code>/footnote</code> command.</li></ul></li><li><p>Page breaks for <a class=\"reference-link\" href=\"#root/_help_NRnIZmSMc5sj\">Printing & Exporting as PDF</a>:</p><pre><code class=\"language-text-x-trilium-auto\"><div class=\"page-break\"></div></code></pre></li><li><p>Highlights (background color) are supported both via the <code>==</code> Markdown syntax, as well as the canonical HTML representation in Trilium:</p><pre><code class=\"language-text-x-trilium-auto\">==highlighted==\n<span style=\"background-color:#e5e64d;--tn-background:#e5e64d;\">Highlighted</span></code></pre></li></ul><h3>Links</h3><p>Multiple types of links are supported:</p><ul><li><p>Web URLs can be written with the standard Markdown syntax:</p><pre><code class=\"language-text-x-trilium-auto\">[Wikipedia](https://www.wikipedia.org)</code></pre></li><li><p><a href=\"#root/_help_hrZ1D00cLbal\">Reference link</a> to other notes with dynamic title, either by manually entering the note ID or via the <em>Add link</em> dialog:</p><pre><code class=\"language-text-x-trilium-auto\">[[B9oMG6rFvvfq]]</code></pre></li><li><p><a href=\"#root/_help_hrZ1D00cLbal\">Reference link</a> to other notes with a custom text:</p><pre><code class=\"language-text-x-trilium-auto\">[This is a link](#root/LhtnZxtVsUMp)</code></pre></li></ul><p>To create a link, either:</p><ul><li>Type it manually using the syntax described above.</li><li>Use the <em>Add link</em> dialog by pressing <kbd>Ctrl</kbd>+<kbd>L</kbd> or typing the <code>/link</code> command.</li></ul><p><a class=\"reference-link\" href=\"#root/_help_UmgZAfcltxkS\">Link Previews</a> are also rendered, but there is no mechanism to insert them automatically as of now, they have to be copied from a <a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> note instead.</p><h3>Keyboard shortcuts</h3><p>The Markdown notes share some of the keyboard shortcuts from <a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> notes:</p><ul><li><em>Cut to note</em> (<kbd>Ctrl</kbd>+<kbd>X</kbd>) which cuts the selection into a new child note.</li><li><em>Add link</em> (<kbd>Ctrl</kbd>+<kbd>L</kbd>) which shows the dialog to create external or reference links.</li><li><em>Date/time</em> (<kbd>Alt</kbd>+<kbd>T</kbd>) which respects the same formatting as text notes.</li><li><em>Include note</em> (not assigned by default), which triggers the same dialog to insert notes as the one for text notes.</li></ul><p>In addition, the following formatting keyboard shortcuts are available:</p><ul><li><kbd>Ctrl</kbd>+<kbd>B</kbd> to toggle <strong>bold</strong>.</li><li><kbd>Ctrl</kbd>+<kbd>I</kbd> to toggle <em>italic</em>.</li><li><kbd>Ctrl</kbd>+<kbd>M</kbd> to wrap the current selection in an inline math (<code>$</code>).</li><li><kbd>Ctrl</kbd>+<kbd>Shift</kbd>+<kbd>X</kbd> to toggle <del>strikethrough</del>.</li></ul><h3>Images & attachments</h3><p>Images can be inserted into the document in four different methods:</p><ul><li>Drag & drop directly into the editor area.</li><li>Pasting an image from clipboard.</li><li>Pasting a reference to another <a href=\"#root/_help_0vhv7lsOLy82\">attachment</a> (e.g. <em>Copy reference to clipboard</em> button).</li><li>Use the <code>/image</code> slash command.</li></ul><p>An image reference to an attachment looks like this:</p><pre><code class=\"language-text-x-trilium-auto\"></code></pre><h3>Auto-completion</h3><h4>Slash commands</h4><p>Just like <a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> notes, Markdown notes support a selection of slash commands:</p><ul><li>Inserting the current date & time (<code>/date</code>).</li><li><a href=\"#root/_help_nBAXQFj20hS1\">Including</a> another note (<code>/include</code>).</li><li>Uploading and inserting an image (<code>/image</code>).</li><li>Inserting a note link (<code>/link</code>).</li><li>Inserting a math equation block (<code>/math</code>).</li><li>Inserting a <a href=\"#root/_help_AgjCISero73a\">footnote</a> (<code>/footnote</code>).</li><li>Inserting a <a href=\"#root/_help_s1aBHPd79XYj\">Mermaid</a> diagram (<code>/mermaid</code>), with one variant per sample template (e.g. <code>/mermaid:flowchart</code>).</li><li>Inserting a collapsible block (<code>/collapsible</code>).</li><li>Inserting <a href=\"#root/_help_rJ9grSgoExl9\">tabs</a> (<code>/tabs</code>).</li><li>Inserting a page break for printing (<code>/page-break</code>).</li><li>Inserting a table (<code>/table</code>).</li><li>Creating admonitions (e.g. <code>/tip</code>, <code>/note</code>, <code>/important</code>, <code>/caution</code>, <code>/warning</code>).</li><li>Inserting task items (<code>/todo:<state></code>, e.g. <code>/todo:done</code>), one per configured task state.</li><li>Inserting code snippets (<code>/snippet:<name></code>) from your Markdown/plain-text snippet notes.</li></ul><p>The list shows each command by its title, as in Text notes. Typing a command's title, its keyword (as listed above) or a related word such as <code>latex</code> or <code>grid</code> finds it.</p><p>Note that slash commands only work outside of code blocks and inline code.</p><h4>Linking notes with <code>@</code> or <code>[[</code></h4><p>As in <a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> notes, typing <code>@</code> at the start of a line or after a space opens the note search. Picking a note replaces what was typed with a link to it in the Wikilinks-like format (<code>[[noteId]]</code>), which the preview shows as an <a class=\"reference-link\" href=\"#root/_help_hrZ1D00cLbal\">Internal (reference) links</a> with the note's title.</p><p>The search runs on everything typed after the <code>@</code>, spaces included, so a title such as <code>@My meeting notes</code> can be typed out; press <kbd>Esc</kbd> to close the list and go on writing. If no note fits, the list offers to create one, as a child of the Markdown note or in the inbox; the link is inserted once the note is created.</p><p>You can also start typing the link directly: <code>[[</code> opens the same list, and closing the brackets yourself dismisses it. To change where an existing link points, place the cursor inside it and pick another note.</p><p>Like slash commands, <code>@</code> and <code>[[</code> do nothing inside code blocks and inline code.</p><p>In the editor, a <code>[[noteId]]</code> link shows as the note's icon and title, so you can tell which note it points to without looking up its ID. Clicking it, or moving the cursor next to it, shows the link as written so it can be edited. Links inside code blocks and inline code are left as they are.</p><h4>Code block language auto-completion</h4><p>Starting with v0.104.0, typing ``` to insert a code block will automatically open a list of suggested language types which have syntax highlighting.</p><p>The list of languages matches the one for <a class=\"reference-link\" href=\"#root/_help_6f9hih2hXXZk\">Code</a> notes set in <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a>, it's not the full list of languages supported by Trilium.</p><h3>Other features</h3><ul><li>The <a class=\"reference-link\" href=\"#root/_help_BFvAtE74rbP6\">Table of contents</a> will be displayed in the <a class=\"reference-link\" href=\"#root/_help_RnaPdbciOfeq\">Right Sidebar</a> based on the Markdown-level headings.</li><li>A Markdown note included in a <a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> note shows its source, its preview or both, and can be edited in place. See <em>Included Markdown</em> in <a class=\"reference-link\" href=\"#root/_help_nBAXQFj20hS1\">Include Note</a>.</li></ul><h3>Shared notes</h3><p>When a Markdown note is <a href=\"#root/_help_R9pX4DGra2Vt\">shared publicly</a>, it will be rendered with extended formatting just like <a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> notes.</p><p>Most of the features described previously should be supported. If you face any issues, feel free to <a href=\"#root/_help_wy8So3yZZlH9\">report it</a> alongside a sample Markdown file.</p><h2>Creating Markdown notes</h2><p>There are two ways to create a Markdown note:</p><ol><li>Create a new note (e.g. in the <a class=\"reference-link\" href=\"#root/_help_oPVyFC7WL2Lp\">Note Tree</a>) and select the type <em>Markdown</em>, just like all the other note types.</li><li>Create a note of type <a class=\"reference-link\" href=\"#root/_help_6f9hih2hXXZk\">Code</a> and select as the language either <em>Markdown</em> or <em>GitHub-Flavored Markdown</em>. This maintains compatibility with your existing notes prior to the introduction of this feature.</li></ol><aside class=\"admonition note\"><p>There is no distinction between the new Markdown note type and code notes of type Markdown; internally both are represented as <a class=\"reference-link\" href=\"#root/_help_6f9hih2hXXZk\">Code</a> notes with one of the following MIME types:</p><ul><li><code>text/markdown</code></li><li><code>text/x-markdown</code></li><li><code>text/x-gfm</code> (GitHub Flavored Markdown)</li></ul></aside><h2>Import/export</h2><h3>Import</h3><p>By default, when importing a single Markdown file it automatically gets converted to a <a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> note. To avoid that and have it imported as a Markdown note instead:</p><ul><li>Right click the <a class=\"reference-link\" href=\"#root/_help_oPVyFC7WL2Lp\">Note Tree</a> and select <em>Import into note</em>.</li><li>Select the file normally.</li><li>Uncheck <em>Import HTML, Markdown and TXT as text notes if it's unclear from the metadata</em>.</li></ul><p>When importing a Trilium ZIP, it will preserve the Markdown type without converting to text notes thanks to the meta-information in it.</p><h3>Exporting</h3><p>When exporting Markdown files, the extension is preserved and the content remains the same as in the source view (with some small exceptions such as handling of attachments).</p><p>When exporting Markdown files as ZIP, choosing HTML or Markdown as the export format makes no difference as that only affects <a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> notes.</p><p>If the Markdown note contains attachments, a ZIP export will rewrite the links to attachments so that they are replaced with a relative path to the attachment. On import, the links are re-written back.</p><h2>Conversion between text notes and Markdown notes</h2><p><a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> notes can be converted into Markdown notes and vice versa. See <a class=\"reference-link\" href=\"#root/_help_jludwdW7N4hg\">Converting between note types</a>.</p><h2>Sync-scrolling & block highlight</h2><p>When scrolling through the editing pane, the preview pane will attempt to synchronize its position to make it easier to see the preview.</p><p>In addition, the block in the preview matching the position of the cursor in the source view will appear slightly highlighted.</p><p>The sync is currently one-way only, scrolling the preview will not synchronize the position of the editor.</p><p>This feature cannot be disabled as of now; if the scrolling feels distracting, consider temporarily switching to the editor mode and then switching to preview mode when ready.</p><aside class=\"admonition note\"><p>This feature of synchronizing the scroll is based on blocks but it's provided on a best-effort basis since our underlying Markdown library doesn't support this feature natively, so we had to implement our own algorithm. Feel free to <a href=\"#root/_help_wy8So3yZZlH9\">report issues</a>, but always provide a sample Markdown file to be able to reproduce it.</p></aside>","_help_jludwdW7N4hg": "<p>A note's type may be converted to another:</p><ul><li><a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> notes to <a class=\"reference-link\" href=\"#root/_help_6RM1Q7ppFVoj\">Markdown</a> notes</li><li>Markdown notes to Text notes</li></ul><p>Before conversion, a revision is saved automatically, so you can restore the original or recover any missing elements from it if the conversion produces undesired results. Read more about <a class=\"reference-link\" href=\"#root/_help_vZWERwf8U3nx\">Note Revisions</a>.</p><h2>Converting individual notes</h2><h3>Markdown to Text Note</h3><p>Markdown notes can be converted to Text Notes with negligible loss of formatting fidelity.</p><p>To do so, go to the <a class=\"reference-link\" href=\"#root/_help_8YBEPzcpUgxw\">Note menu</a> → <em>Advanced</em> and select <em>Convert to Text Note</em>.</p><h3>Text Note to Markdown</h3><aside class=\"admonition warning\"><p>Since Markdown does not support all the capabilities of Text notes, this conversion is lossy in terms of formatting: some formatting may be lost, and some unsupported elements may even be dropped. It's strongly recommended that you inspect the content for any information that might have gone missing after the conversion.</p></aside><p>To convert a text note to Markdown, go to the <a class=\"reference-link\" href=\"#root/_help_8YBEPzcpUgxw\">Note menu</a> → <em>Advanced</em> and select <em>Convert to Markdown Note</em>.</p><h2>Converting multiple notes</h2><p>A note type conversion can also be performed on an entire subtree or a set of multiple notes using <a class=\"reference-link\" href=\"#root/_help_ivYnonVFBxbQ\">Bulk Actions</a>.</p>","_help_GTwFsgaA0lCt": "<p>Collections are a unique type of note that don't have content, but instead display their child notes in various presentation methods.</p><h2>Main collections</h2><div class=\"trilium-tabs\"><section class=\"trilium-tab\"><p class=\"trilium-tab-title\"><span class=\"tn-icon bx bx-calendar\"></span> Calendar</p><div class=\"trilium-tab-panel\"><p><a class=\"reference-link\" href=\"#root/_help_xWbu3jpNWapp\">Calendar</a> displays a week, month or year calendar with the notes being shown as events. New events can be added easily by dragging across the calendar.</p><figure class=\"image\"><img style=\"aspect-ratio:1651/810;\" src=\"{{helpAssets}}/User%20Guide/Collections_collection_calendar.webp\" width=\"1651\" height=\"810\"></figure></div></section><section class=\"trilium-tab\"><p class=\"trilium-tab-title\"><span class=\"tn-icon bx bx-table\"></span> Table</p><div class=\"trilium-tab-panel\"><p><a class=\"reference-link\" href=\"#root/_help_2FvYrpmOXm29\">Table</a> displays each note as a row in a table, with <a class=\"reference-link\" href=\"#root/_help_OFXdgB2nNk1F\">Promoted Attributes</a> being shown as well. This makes it easy to visualize attributes of notes, as well as making them easily editable.</p><figure class=\"image\"><img style=\"aspect-ratio:1643/647;\" src=\"{{helpAssets}}/User%20Guide/Collections_collection_table.webp\" width=\"1643\" height=\"647\"></figure></div></section><section class=\"trilium-tab\"><p class=\"trilium-tab-title\"><span class=\"tn-icon bx bx-columns\"></span> Kanban Board</p><div class=\"trilium-tab-panel\"><p><a class=\"reference-link\" href=\"#root/_help_CtBQqbwXDx1w\">Kanban Board</a> displays notes in columns, grouped by the value of a label. Items and columns can easily be created or dragged around to change their status.</p><figure class=\"image\"><img style=\"aspect-ratio:1174/850;\" src=\"{{helpAssets}}/User%20Guide/Collections_collection_board.webp\" width=\"1174\" height=\"850\"></figure></div></section><section class=\"trilium-tab\"><p class=\"trilium-tab-title\"><span class=\"tn-icon bx bx-map-alt\"></span> Geo Map</p><div class=\"trilium-tab-panel\"><p><a class=\"reference-link\" href=\"#root/_help_81SGnPGMk7Xc\">Geo Map</a> which displays a geographical map in which the notes are represented as pins on the map. New markers can be easily added by pointing on the map. In addition <a href=\"#root/_help_C2H9HK4BzwG7\">shapes</a> such as paths, rectangles and circles can be added, as well as GPX tracks.</p><figure class=\"image\"><img style=\"aspect-ratio:844/639;\" src=\"{{helpAssets}}/User%20Guide/Collections_collection_geomap.webp\" width=\"844\" height=\"639\"></figure></div></section><section class=\"trilium-tab\"><p class=\"trilium-tab-title\"><span class=\"tn-icon bx bx-slideshow\"></span> Presentation</p><div class=\"trilium-tab-panel\"><p><a class=\"reference-link\" href=\"#root/_help_zP3PMqaG71Ct\">Presentation</a> which shows each note as a slide and can be presented full-screen with smooth transitions or exported to PDF for sharing.</p><figure class=\"image\"><img style=\"aspect-ratio:1120/763;\" src=\"{{helpAssets}}/User%20Guide/Collections_collection_presentation.webp\" width=\"1120\" height=\"763\"></figure></div></section></div><h2>Classic collections</h2><p>Classic collections are read-only mode and compiles the contents of all child notes into one continuous view. This makes it ideal for reading extensive information broken into smaller, manageable segments.</p><ul><li><a class=\"reference-link\" href=\"#root/_help_8QqnMzx393bx\">Grid View</a> which is the default presentation method for child notes (see <a class=\"reference-link\" href=\"#root/_help_0ESUbbAxVnoK\">Note List</a>), where the notes are displayed as tiles with their title and content being visible.</li><li><a class=\"reference-link\" href=\"#root/_help_mULW0Q3VojwY\">List View</a> is similar to <a class=\"reference-link\" href=\"#root/_help_8QqnMzx393bx\">Grid View</a>, but it displays the notes one under the other with the content being expandable/collapsible, but also works recursively.</li></ul><p>Classic collections make use of pagination to support a large number of notes. The size of a page can be customized via <code>pageSize</code>.</p><h2>Creating a new collection</h2><p>To create a new collection, right-click a note in the <a class=\"reference-link\" href=\"#root/_help_oPVyFC7WL2Lp\">Note Tree</a> and select <em>Insert child note</em> → <em>Collection</em> → the desired type.</p><p>By default, collections come with a default configuration and sometimes even sample notes. To create a collection completely from scratch:</p><ol><li>Create a new note of type <em>Text</em> (or any type).</li><li>Change the <a href=\"#root/_help_KSZ04uQ2D1St\">note type</a> to <em>Collection</em>.</li><li>In <a class=\"reference-link\" href=\"#root/_help_CssoWBu8I7jF\">Collection Properties</a>, select the desired view type.</li><li>Consult the help page of the corresponding view type in order to understand how to configure them.</li></ol><h2>Configuration</h2><p>To change the configuration of a collection or even switch to a different collection (e.g. from Kanban Board to a Calendar), see the <a class=\"reference-link\" href=\"#root/_help_CssoWBu8I7jF\">Collection Properties</a> bar at the top of the note.</p><h2>Archived notes</h2><p>By default, <a href=\"#root/_help_MKmLg5x6xkor\">archived notes</a> will not be shown in collections. This behavior can be changed by going to <a class=\"reference-link\" href=\"#root/_help_CssoWBu8I7jF\">Collection Properties</a> and checking <em>Show archived notes</em>.</p><p>Archived notes will be generally indicated by being greyed out as opposed to the normal ones.</p><h2>Hiding the child notes from the note tree</h2><p>For collections with a large number of items, it can be helpful to hide the items from the note tree for performance reasons and to reduce clutter. This is especially useful for standalone collections, such as a geomap or a task board.</p><p>To do so, go to <a class=\"reference-link\" href=\"#root/_help_CssoWBu8I7jF\">Collection Properties</a> and select <em>Hide child notes in tree</em>.</p><h2>Advanced use cases</h2><h3>Adding a description to a collection</h3><p>To add a text before the collection, for example to describe it:</p><ol><li>Create a new collection.</li><li>Change the <a href=\"#root/_help_KSZ04uQ2D1St\">note type</a> from <em>Collection</em> to <em>Text</em>.</li></ol><p>Now the text will be displayed above while still maintaining the collection view.</p><p>The only downside to this method is that <a class=\"reference-link\" href=\"#root/_help_CssoWBu8I7jF\">Collection Properties</a> will not be shown anymore. In this case, modify the attributes manually or switch back temporarily to the <em>Collection</em> type for configuration purposes.</p><h3>Using saved search</h3><p>Collections, by default, only display the child notes. However, it is possible to use the <a class=\"reference-link\" href=\"#root/_help_eIg8jdvaoNNd\">Search</a> functionality to display notes all across the tree, with advanced querying functionality.</p><p>To do so, simply start a <a class=\"reference-link\" href=\"#root/_help_eIg8jdvaoNNd\">Search</a> and go to the <a class=\"reference-link\" href=\"#root/_help_CssoWBu8I7jF\">Collection Properties</a> and select a desired type of collection. To keep the search-based collection, use a <a class=\"reference-link\" href=\"#root/_help_m523cpzocqaD\">Saved Search</a>.</p><aside class=\"admonition important\"><p>While in search, none of the collections will not display the child notes of the search results. The reason is that the search might hit a note multiple times, causing an exponential rise in the number of results.</p></aside><h2>Under the hood</h2><p>Collections by themselves are simply notes with no content that rely on the <a class=\"reference-link\" href=\"#root/_help_0ESUbbAxVnoK\">Note List</a> mechanism (the one that lists the children notes at the bottom of a note) to display information.</p><p>By default, new collections use predefined <a class=\"reference-link\" href=\"#root/_help_KC1HB96bqqHX\">Templates</a> that are stored safely in the <a class=\"reference-link\" href=\"#root/_help_2mUhVmZK8RF3\">Hidden Notes</a> to define some basic configuration such as the type of view, but also some <a class=\"reference-link\" href=\"#root/_help_OFXdgB2nNk1F\">Promoted Attributes</a> to make editing easier.</p><p>Collections don't store their configuration (e.g. the position on the map, the hidden columns in a table) in the content of the note itself, but as attachments.</p>","_help_xWbu3jpNWapp": "<figure class=\"image\"><img style=\"aspect-ratio:2016/1413;\" src=\"{{helpAssets}}/User%20Guide/Collections/1_Calendar_image.png\" width=\"2016\" height=\"1413\"></figure><p>The Calendar view will display each child note in a calendar that has a start date and optionally an end date, as an event.</p><p>The Calendar view has multiple display modes:</p><ul><li>Month view, where the entire month is displayed and all-day events can be inserted. Both time-specific events and all-day events are listed.</li><li>Week view, where all the 7 days of the week (or 5 if the weekends are hidden) are displayed in columns. This mode allows entering and displaying time-specific events, not just all-day events.</li><li>Day view, which views only a single day. Especially useful for heavy agendas or mobile views.</li><li>List view, which displays all the events of a given month in sequence.</li><li>Year view, which displays the entire year for quick reference.</li></ul><p>Unlike other Collection view types, the Calendar view also allows some kind of interaction, such as moving events around as well as creating new ones.</p><h2>Creating a calendar</h2><p>Right click on an existing note in the <a class=\"reference-link\" href=\"#root/_help_oPVyFC7WL2Lp\">Note Tree</a> and select <em>Insert child note</em> → <em>Collection</em> → <em>Calendar</em>.</p><h2>Creating a new event/note</h2><p>To create a new event:</p><ul><li>First, click the desired day (month & year views) or the desired timeslot (day view).</li><li>Alternatively, drag across multiple days (or time slots) to set both the start and end date.</li></ul><p>In either cases, a small popup will show with a prompt for a title and the date & time of the event that will be created. The date and time can be changed there the same way as in the popup view of an existing event (see below).</p><p>At this point, the event hasn't been created yet to protect against accidental clicks. Add a title optionally and press the <em>Create</em> button. If no title is provided, the event will follow the <a class=\"reference-link\" href=\"#root/_help_47ZrP6FNuoG8\">Default Note Title</a> rules.</p><p>The <span class=\"tn-icon bx bx-detail\"></span> template field below the date and time shows the note type or template the event's note is made from. To make the event from another one, press the field and select it from the list; the calendar remembers the choice for the next event. Select <em>More templates…</em> to change which templates are listed (see <a href=\"#event-templates\">Event templates</a>). The date and time entered for the event replace any dates and times the template carries.</p><p>To give the event a time before creating it (for example, after clicking a day in the month view), press <em>Add time</em> and set the start and end time; the duration is shown to the right of them. To make the event all-day again, press the <span class=\"tn-icon bx bx-x\"></span> button at the end of the row. Adding or removing a time keeps the dates, so an event can start at a time on one day and end at a time on another (for example, a night shift). Changing the start date or time moves the end by the same amount, keeping the duration. An empty end date means the event ends on the day it starts; setting the end time before the start time moves the end date to the next day.</p><p>After creating the event, it will show up on the calendar. To edit the content of the event (including recurrence), click on it to bring it into the popup view.</p><aside class=\"admonition note\"><p>Creating new notes from the calendar will respect the <code>~child:template</code> relation if set on the Collection note.</p></aside><h2>Interacting with events</h2><ul><li>Hovering the mouse over an event will display information about the note.<br><img src=\"{{helpAssets}}/User%20Guide/Collections/4_Calendar_image.png\"></li><li>Left clicking the event will open a dedicated popup to quickly configure the event or edit its note content.</li><li>Right click will offer more options including opening the note in a new split or window.</li><li>Drag and drop an event on the calendar to move it to another day.</li><li>The length of an event can be changed by placing the mouse to the right edge of the event and dragging the mouse around.</li></ul><p>On a <a href=\"#root/_help_CoFPLs3dRlXc\">read-only</a> calendar, events can't be dragged, resized or created, their context menu only offers the places to open them in, and the button to pin the current date is hidden. Switching between the month, week and day views still works, but the choice isn't saved.</p><h3>Popup view</h3><p>When an event is clicked, a popup will show near the event which contains the following inforamtion:</p><ul><li>The title and icon of the event, both editable.</li><li>Buttons to interact with the event:<ul><li>Open the event in the same pane, new tab, etc.</li><li>Color picker to change the color of the event.</li><li>Button to remove the event from the calendar, which can optionally delete its corresponding note.</li></ul></li><li>Calendar-specific features:<ul><li>The start date and, for an event spanning several days, the end date.</li><li>The start and end time with the duration to the right of them, and a <span class=\"tn-icon bx bx-x\"></span> button that removes the time, making the event all-day. An all-day event shows an <em>Add time</em> button instead.</li><li>A full recurrence editor, opened from the dropdown below the time, to have the same event show up weekly, monthly, etc.</li></ul></li><li>The <a class=\"reference-link\" href=\"#root/_help_OFXdgB2nNk1F\">Promoted Attributes</a> of the marker, if any.</li><li>The note's content which can be edited directly from the panel.</li></ul><p>To dismiss the popup:</p><ul><li>Press the X button at the top-right of the popup.</li><li>In the calendar, press anywhere outside the popup.</li><li>Or simply press the <kbd>Escape</kbd> key.</li></ul><p>It is possible to switch between events by clicking on them even when the popup view is already open.</p><p>Events can have <a class=\"reference-link\" href=\"#root/_help_hrZ1D00cLbal\">Internal (reference) links</a> between them and clicking on such a link will automatically navigate the calendar to the right date and the popup view to the new note.</p><h2>Interaction on mobile</h2><p>When Trilium is on mobile, the interaction with the calendar is slightly different:</p><ul><li>Clicking on an event displays the popup view, which allows editing the event.</li><li>Long-presing an event triggers the contextual menu, including the option to open in <a class=\"reference-link\" href=\"#root/_help_ZjLYv08Rp3qC\">Quick edit</a>.</li><li>To insert a new event, touch and hold the empty space. When successful, the empty space will become colored to indicate the selection.<ul><li>Before releasing, drag across multiple spaces to create multi-day events.</li><li>When released, a prompt will appear to enter the note title.</li></ul></li><li>To move an existing event, touch and hold the event until the empty space near it will become colored.<ul><li>At this point the event can be dragged across other days on the calendar.</li><li>Or the event can be resized by tapping on the small circle to the right end of the event.</li><li>To exit out of editing mode, simply tap the empty space anywhere on the calendar.</li></ul></li></ul><h2>Configuring the calendar view</h2><p>In the <a class=\"reference-link\" href=\"#root/_help_CssoWBu8I7jF\">Collection Properties</a>, it's possible to:</p><ul><li>Hide weekends from the week view.</li><li>Display week numbers on the calendar.</li><li>Hide routine events from the month, year and list views (see <a href=\"#hiding-routine-events\">Hiding routine events</a>).</li><li>Set the slot duration (the length of each time row in day/week view).</li><li>Set the slot label interval (how often time labels appear on the axis in day/week view).</li></ul><p>The same settings are also listed under <em>General</em> in the <span class=\"tn-icon bx bx-cog\"></span> <em>Calendar properties</em> dialog (see <a href=\"#event-templates\">Event templates</a> for how to open it). The time slots are listed there whichever view the calendar is in. Its <em>Included notes</em> section sets whether archived notes are shown and how deep the calendar looks for events (see <a href=\"#limiting-the-depth\">Limiting the depth</a>).</p><h3>Event templates</h3><p>By default, a new event is a <a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> note. To make events from other note types, or from <a class=\"reference-link\" href=\"#root/_help_KC1HB96bqqHX\">Templates</a> with predefined content and attributes (such as a color), open the <span class=\"tn-icon bx bx-cog\"></span> <em>Calendar properties</em> dialog from the <a class=\"reference-link\" href=\"#root/_help_8YBEPzcpUgxw\">Note menu</a> or from the settings menu of the <a class=\"reference-link\" href=\"#root/_help_CssoWBu8I7jF\">Collection Properties</a>, and find <em>Event templates</em>. Here you can:</p><ul><li>Include a note type or note template already created in your knowledge base by pressing the <span class=\"tn-icon bx bx-list-plus\"></span> <em>Add existing template</em> button and then selecting the desired note type or template.</li><li>Create a new template by pressing the <span class=\"tn-icon bx bx-plus\"></span> <em>Create a new template</em> button. The template is created as a child of the calendar, and is not shown as an event.</li><li>Press the <span class=\"tn-icon bx bx-x\"></span> button to remove a template from the list. The template is removed only from the list, not deleted.</li><li>Press the <span class=\"tn-icon bx bx-dots-vertical-rounded\"></span> button of a custom template to edit, open in a new window, duplicate, or delete it.</li><li>Drag a template by its handle to reorder the list shown when creating an event.</li></ul><p>The dialog is not available on a read-only calendar, or on a calendar marked with <code>#calendarRoot</code> or <code>#workspaceCalendarRoot</code> (see <a href=\"#using-with-the-journal--calendar\">Using with the Journal / calendar</a>).</p><h3>Event attributes</h3><p>Events can show the values of their attributes below their title, in the month view, and in the week and day views for all-day events and for timed ones tall enough to hold them. To choose which attributes are shown, open the <span class=\"tn-icon bx bx-cog\"></span> <em>Calendar properties</em> dialog (see <a href=\"#event-templates\">Event templates</a> for how to open it) and find <em>Event attributes</em>. It lists the <a class=\"reference-link\" href=\"#root/_help_OFXdgB2nNk1F\">Promoted Attributes</a> the calendar defines, and those its events define themselves. Here you can:</p><ul><li>Turn an attribute on to show it on the events. New attributes are hidden until you turn them on, which keeps the calendar from getting cluttered.</li><li>Drag an attribute by its handle to change the order in which the events show them.</li><li>Create a new attribute, which is shown on the events right away, or edit or delete one the calendar defines.</li></ul><p>The dates, times and recurrence of the events are not listed, as the calendar always shows them itself.</p><p>If an event has a <code>#calendar:displayedAttributes</code> label, including one inherited from the calendar, the attributes listed in that label are shown instead.</p><h2>Configuring the calendar using attributes</h2><p>The following attributes can be added to the Collection type:</p><figure class=\"table\"><table><thead><tr><th>Name</th><th>Description</th></tr></thead><tbody><tr><td><code>#calendar:hideWeekends</code></td><td>When present (regardless of value), it will hide Saturday and Sundays from the calendar.</td></tr><tr><td><code>#calendar:weekNumbers</code></td><td>When present (regardless of value), it will show the number of the week on the calendar.</td></tr><tr><td><code>#calendar:hideRoutineEvents</code></td><td>When present (regardless of value), it will hide routine events from the month, year and list views. See <a href=\"#hiding-routine-events\">Hiding routine events</a>.</td></tr><tr><td><code>#calendar:initialDate</code></td><td>Change the date the calendar opens on. When not present, the calendar opens on the current date.</td></tr><tr><td><code>#calendar:view</code></td><td><p>Which view to display in the calendar:</p><ul><li><code>timeGridDay</code> for the <em>day</em> view;</li><li><code>timeGridWeek</code> for the <em>week</em> view;</li><li><code>dayGridMonth</code> for the <em>month</em> view;</li><li><code>multiMonthYear</code> for the <em>year</em> view;</li><li><code>listMonth</code> for the <em>list</em> view.</li></ul><p>Any other value will be dismissed and the default view (month) will be used instead.</p><p>The value of this label is automatically updated when changing the view using the UI buttons.</p></td></tr><tr><td><code>#calendar:slotDuration</code></td><td>Sets how long each timeslot is on the calendar. Defaults to <code>00:15:00</code> (15 minutes). Must have the format \"HH:MM:SS\". For example, to create timeslots for every 10 minutes, you would set <code>#calendar:slotDuration=\"00:10:00\"</code>.</td></tr><tr><td><code>#calendar:slotLabelInterval</code></td><td>Sets how often the timeslots on the calendar should be labeled. Defaults to <code>01:00:00</code> (1 hour). Must have the format \"HH:MM:SS\". For example, to label timeslots every 30 minutes, you would set <code>#calendar:slotLabelInterval=\"00:30:00\"</code>.</td></tr><tr><td><code>~child:template</code></td><td>Defines the template for newly created notes in the calendar (via dragging or clicking).</td></tr></tbody></table></figure><p>In addition, the first day of the week can be either Sunday or Monday and can be adjusted from the application settings.</p><h2>Configuring the calendar events using attributes</h2><p>For each note of the calendar, the following attributes can be used:</p><figure class=\"table\"><table><thead><tr><th>Name</th><th>Description</th></tr></thead><tbody><tr><td><code>#startDate</code></td><td>The date the event starts, which will display it in the calendar. The format is <code>YYYY-MM-DD</code> (year, month and day separated by a minus sign).</td></tr><tr><td><code>#endDate</code></td><td>Similar to <code>startDate</code>, mentions the end date if the event spans across multiple days. The date is inclusive, so the end day is also considered. The attribute can be missing for single-day events.</td></tr><tr><td><code>#startTime</code></td><td>The time the event starts at. If this value is missing, then the event is considered a full-day event. The format is <code>HH:MM</code> (hours in 24-hour format and minutes).</td></tr><tr><td><code>#endTime</code></td><td>Similar to <code>startTime</code>, it mentions the time at which the event ends (in relation with <code>endDate</code> if present, or <code>startDate</code>).</td></tr><tr><td><code>#recurrence</code></td><td>This is an optional CalDAV <code>RRULE</code> string that if present, determines whether a task should repeat or not. Note that it does not include the <code>DTSTART</code> attribute, which is derived from the <code>#startDate</code> and <code>#startTime</code> directly. For examples of valid <code>RRULE</code> strings see <a href=\"https://icalendar.org/rrule-tool.html\">https://icalendar.org/rrule-tool.html</a></td></tr><tr><td><code>#color</code></td><td>Displays the event with a specified color (named such as <code>red</code>, <code>gray</code> or hex such as <code>#FF0000</code>). This will also change the color of the note in other places such as the note tree.</td></tr><tr><td><code>#calendar:color</code></td><td><strong>❌️ Removed since v0.100.0. Use</strong> <code>#color</code> <strong>instead.</strong> <br> <br>Similar to <code>#color</code>, but applies the color only for the event in the calendar and not for other places such as the note tree.</td></tr><tr><td><code>#iconClass</code></td><td>If present, the icon of the note will be displayed to the left of the event title.</td></tr><tr><td><code>#calendar:title</code></td><td>Changes the title of an event to point to an attribute of the note other than the title, can either a label or a relation (without the <code>#</code> or <code>~</code> symbol). See <em>Use-cases</em> for more information.</td></tr><tr><td><code>#calendar:titleTemplate</code></td><td>Changes the title an event is displayed with on the calendar, filled in again for every occurrence of a repeating event. See <em>Use-cases</em> for displaying an age on a birthday.</td></tr><tr><td><code>#calendar:displayedAttributes</code></td><td>Takes precedence over the <a href=\"#event-attributes\">Event attributes</a> chosen in the calendar's properties. Allows displaying the value of one or more attributes in the calendar, in the order given, like this: <br> <br><img src=\"{{helpAssets}}/User%20Guide/Collections/6_Calendar_image.png\"> <br> <br><code>#weight=\"70\" #Mood=\"Good\" #calendar:displayedAttributes=\"weight,Mood\"</code> <br> <br>It can also be used with relations, case in which it will display the title of the target note: <br> <br><code>~assignee=@My assignee #calendar:displayedAttributes=\"assignee\"</code></td></tr><tr><td><code>#calendar:startDate</code></td><td>Allows using a different label to represent the start date, other than <code>startDate</code> (e.g. <code>expiryDate</code>). The label name <strong>must not be</strong> prefixed with <code>#</code>. If the label is not defined for a note, the default will be used instead.</td></tr><tr><td><code>#calendar:endDate</code></td><td>Similar to <code>#calendar:startDate</code>, allows changing the attribute which is being used to read the end date.</td></tr><tr><td><code>#calendar:startTime</code></td><td>Similar to <code>#calendar:startDate</code>, allows changing the attribute which is being used to read the start time.</td></tr><tr><td><code>#calendar:endTime</code></td><td>Similar to <code>#calendar:startDate</code>, allows changing the attribute which is being used to read the end time.</td></tr></tbody></table></figure><h2>How the calendar works</h2><p><img src=\"{{helpAssets}}/User%20Guide/Collections/8_Calendar_image.png\"></p><p>The calendar displays all the child notes of the Collection that have a <code>#startDate</code>. An <code>#endDate</code> can optionally be added.</p><p>A text note with a start date is shown with the <span class=\"tn-icon bx bx-calendar-event\"></span> icon in the note tree and elsewhere, unless it has an icon of its own (set with <code>#iconClass</code>). The start date is read from the label <code>#calendar:startDate</code> names, if any.</p><p>The start date & end date can easily be edited from the calendar collection itself by clicking on the event. To edit the date while in the event note itself, the following attributes can be added to the Collection note:</p><pre><code class=\"language-text-x-trilium-auto\">#viewType=calendar #label:startDate(inheritable)=\"promoted,alias=Start Date,single,date\"\n#label:endDate(inheritable)=\"promoted,alias=End Date,single,date\"\n#hidePromotedAttributes </code></pre><p>This will result in:</p><p><img src=\"{{helpAssets}}/User%20Guide/Collections/7_Calendar_image.png\"></p><p>When not used in a Journal, the calendar is recursive. That is, it will look for events not just in its child notes but also in the children of these child notes.</p><h3>Limiting the depth</h3><p>To limit how deep the calendar looks for events, set <em>Maximum nesting depth</em> under <em>Included notes</em> in the <span class=\"tn-icon bx bx-cog\"></span><em>Calendar properties</em> dialog (see <a href=\"#event-templates\">Event templates</a> for how to open it), or the <code>#maxNestingDepth</code> label: <code>0</code> shows only the child notes, <code>1</code> adds their children, and so on. Without a value, events are looked for at every level. The setting doesn't apply in a Journal.</p><h2>Recurrence</h2><p>The built in calendar view also supports repeating tasks (e.g. every week, every month as well as more complex recurrency rules).</p><p>Starting with v0.105.0, recurrence can be directly edited from the calendar by clicking on an event and then selecting the <em>Repeats</em> option.</p><h3>Custom recurrence using a subset of RRULE</h3><p>If the existing recurrence editor from the event popup is not sufficient, more complex rules can be manually set via the <code>#recurrence</code> label.</p><p>For example, to make a note repeat on the calendar:</p><ul><li>Every Day - <code>#recurrence=\"FREQ=DAILY;INTERVAL=1\"</code></li><li>Every 3 days - <code>#recurrence=\"FREQ=DAILY;INTERVAL=3\"</code></li><li>Every week - <code>#recurrence=\"FREQ=WEEKLY;INTERVAL=1\"</code></li><li>Every 2 weeks on Monday, Wednesday and Friday - <code>#recurrence=\"FREQ=WEEKLY;INTERVAL=2;BYDAY=MO,WE,FR\"</code></li><li>Every 3 months - <code>#recurrence=\"FREQ=MONTHLY;INTERVAL=3\"</code></li><li>Every 2 months on the First Sunday - <code>#recurrence=\"FREQ=MONTHLY;INTERVAL=2;BYDAY=1SU\"</code></li><li>Every month on the Last Friday - <code>#recurrence=\"FREQ=MONTHLY;INTERVAL=1;BYDAY=-1FR\"</code></li></ul><p>For other examples of valid <code>RRULE</code> strings see <a href=\"https://icalendar.org/rrule-tool.html\">https://icalendar.org/rrule-tool.html</a></p><p>Note that the recurrence string does not include the <code>DTSTART</code> attribute as defined in the iCAL specifications. This is derived directly from the <code>startDate</code> and <code>startTime</code> attributes</p><p>If you want to override the label the calendar uses to fetch the recurrence string, you can use the <code>#calendar:recurrence</code> attribute. For example, you can set <code>#calendar:recurrence=taskRepeats</code>. Then you can set your recurrence string like <code>#taskRepeats=\"FREQ=DAILY;INTERVAL=1\"</code></p><p>Also note that the recurrence label can be made promoted as with the start and end dates. </p><aside class=\"admonition warning\"><p>If the recurrence string is not valid, a toast will be shown with the note ID and title of the note with the erroneous recurrence message. This note will not be added to the calendar</p></aside><h3>Hiding routine events</h3><p>Events that repeat on most days of the week, such as sleep or working hours, fill every cell of the month view. To hide them from the views that show many days at once, check <em>Hide routine events</em> in the <a class=\"reference-link\" href=\"#root/_help_CssoWBu8I7jF\">Collection Properties</a> (or set <code>#calendar:hideRoutineEvents</code>).</p><p>An event counts as routine when it has a start time and repeats on 4 or more days a week on average, for example:</p><figure class=\"table\"><table><thead><tr><th>Event</th><th>Days a week</th><th>Hidden from the month, year and list views</th></tr></thead><tbody><tr><td>Every day from 23:00 to 07:00</td><td>7</td><td>Yes</td></tr><tr><td>Monday to Friday from 09:00 to 17:00</td><td>5</td><td>Yes</td></tr><tr><td>Every other day at 07:00</td><td>3.5</td><td>No</td></tr><tr><td>Monday, Wednesday and Friday at 18:00</td><td>3</td><td>No</td></tr><tr><td>Every day, without a start time</td><td>7</td><td>No, as it lasts the whole day</td></tr><tr><td>Every month or every year</td><td>—</td><td>No</td></tr></tbody></table></figure><p>The day and week views always show routine events. To show them everywhere again, uncheck the option.</p><h2>Customizing the slot duration and label interval</h2><p>Time slots in day and week views can be customized from <a class=\"reference-link\" href=\"#root/_help_CssoWBu8I7jF\">Collection Properties</a></p><ul><li><em>Slot duration</em> controls how tall each time slot is on the calendar (essentially the smallest unit of time the grid is divided into).<ul><li>A shorter duration means more rows and finer granularity; a longer one means fewer, chunkier rows.</li><li>The default is one row every 15 minutes.</li></ul></li><li><em>Label interval</em> controls how often a time label appears on the left-hand axis.<ul><li>This is independent of the slot size: you can have very small slots but only label every hour to keep the axis readable.</li><li>The default is a time label shown every hour.</li></ul></li></ul><aside class=\"admonition note\"><p>These values can also be customized directly via the <code>#calendar:slotDuration</code> and <code>#calendar:slotLabelInterval</code> <a href=\"#root/_help_HI6GBBIduIgv\">labels</a>. Both values use <code>HH:mm:ss</code> format. Hours can go up to <code>24</code> (<code>24:00:00</code>), while minutes and seconds must be between <code>00</code> and <code>59</code>. The minimum meaningful duration is 1 minute (<code>00:01:00</code>).</p></aside><h2>Use-cases</h2><h3>Using with the Journal / calendar</h3><p>It is possible to integrate the calendar view into the Journal with day notes. In order to do so change the note type of the Journal note (calendar root) to Collection and then select the Calendar View.</p><p>While in journal mode, the popup editor will not show dates, recurrence, colors or removal, since day notes aren't editable events.</p><p>Based on the <code>#calendarRoot</code> (or <code>#workspaceCalendarRoot</code>) attribute, the calendar will know that it's in a calendar and apply the following:</p><ul><li>The calendar events are now rendered based on their <code>dateNote</code> attribute rather than <code>startDate</code>.</li><li>Interactive editing such as dragging over an empty era or resizing an event is no longer possible.</li><li>Clicking on the empty space on a date will automatically open that day's note or create it if it does not exist.</li><li>Direct children of a day note will be displayed on the calendar despite not having a <code>dateNote</code> attribute. Children of the child notes will not be displayed.</li></ul><img src=\"{{helpAssets}}/User%20Guide/Collections/5_Calendar_image.png\" width=\"1217\" height=\"724\"><h3>Using a different attribute as event title</h3><p><img class=\"image-style-align-right\" src=\"{{helpAssets}}/User%20Guide/Collections/2_Calendar_image.png\" width=\"445\" height=\"124\">By default, events are displayed on the calendar by their note title. However, it is possible to configure a different attribute to be displayed instead.</p><p>To do so, assign <code>#calendar:title</code> to the child note (not the calendar/Collection note), with the value being <code>name</code> where <code>name</code> can be any label (make not to add the <code>#</code> prefix). The attribute can also come through inheritance such as a template attribute. If the note does not have the requested label, the title of the note will be used instead.</p><pre><code class=\"language-text-x-trilium-auto\">#startDate=2025-02-11 #endDate=2025-02-13 #name=\"My vacation\" #calendar:title=\"name\"</code></pre><h3>Using a relation attribute as event title</h3><p><img class=\"image-style-align-right image_resized\" style=\"aspect-ratio:294/151;width:21.22%;\" src=\"{{helpAssets}}/User%20Guide/Collections/3_Calendar_image.png\" width=\"294\" height=\"151\">Similarly to using an attribute, use <code>#calendar:title</code> and set it to <code>name</code> where <code>name</code> is the name of the relation to use.</p><p>Moreover, if there are more relations of the same name, they will be displayed as multiple events coming from the same note.</p><pre><code class=\"language-text-x-trilium-auto\">#startDate=2025-02-14 #endDate=2025-02-15 ~for=@John Smith ~for=@Jane Doe #calendar:title=\"for\"</code></pre><p><img class=\"image-style-align-left\" src=\"{{helpAssets}}/User%20Guide/Collections/Calendar_image.png\" width=\"296\" height=\"150\">Note that it's even possible to have a <code>#calendar:title</code> on the target note (e.g. “John Smith”) which will try to render an attribute of it. Note that it's not possible to use a relation here as well for safety reasons (an accidental recursion of attributes could cause the application to loop infinitely).</p><pre><code class=\"language-text-x-trilium-auto\">#calendar:title=\"shortName\" #shortName=\"John S.\"</code></pre><h3>Displaying an age on a recurring event</h3><p>A birthday or an anniversary repeats every year, and what is interesting about each occurrence is the number of years it marks. To display it:</p><ol><li>Set the event's start date to the original date (for example, the date of birth).</li><li>Click the event, then select the <em>Repeats</em> dropdown.</li><li>Select <em>Yearly</em> and check <em>Show the number of years in the title</em>.</li></ol><p>The event is then displayed as “John Smith (35)” in 2025, “John Smith (36)” in 2026, and so on. Only the calendar is affected; the note keeps its own title.</p><p>The checkbox sets the <code>#calendar:titleTemplate</code> label, which sets the title an event is displayed with and is filled in again for every occurrence the recurrence rule produces:</p><pre><code class=\"language-text-x-trilium-auto\">#startDate=1990-05-12 #recurrence=\"FREQ=YEARLY\" #calendar:titleTemplate=\"${title} (${years})\"</code></pre><p>To word the title differently, edit the label directly. The checkbox is then disabled, as it is when the template is inherited, so that it never overwrites a template of your own.</p><p>The following values can be used in the template:</p><figure class=\"table\"><table><thead><tr><th>Value</th><th>Description</th></tr></thead><tbody><tr><td><code>${title}</code></td><td>The title the event would otherwise be displayed with: the note title, or the attribute <code>#calendar:title</code> points to.</td></tr><tr><td><code>${years}</code></td><td>The whole years between <code>#startDate</code> and the occurrence being displayed. It is <code>0</code> on the first occurrence.</td></tr><tr><td><code>${date}</code></td><td>The date of the occurrence being displayed, as a <a href=\"https://day.js.org/docs/en/display/format\">day.js</a> object. For example, <code>${date.format('YYYY')}</code>.</td></tr><tr><td><code>${startDate}</code></td><td>The date the event starts on, in the same form. For example, <code>${startDate.format('YYYY')}</code>.</td></tr></tbody></table></figure><p>To use the same template for every event of a calendar, make the label inheritable on the Collection note:</p><pre><code class=\"language-text-x-trilium-auto\">#calendar:titleTemplate(inheritable)=\"${title} (${years})\"</code></pre><aside class=\"admonition note\"><p>A template that cannot be read — an unknown value, or an expression other than a value and the <code>format</code> call shown above — leaves the event with its plain title and reports the reason in the browser console.</p></aside>",