Skip to content

Build your personal knowledge base with Trilium Notes

feat(mobile/text): show the + menu as tiles

Elian Doranb1435cd0a434
diff --git a/apps/client/src/translations/en/translation.json b/apps/client/src/translations/en/translation.json
index 02fd370e0f..508a2baef7 100644
--- a/apps/client/src/translations/en/translation.json
+++ b/apps/client/src/translations/en/translation.json
@@ -4558,7 +4558,6 @@
"insert-titled-tabs-that-show-one-panel-at-a-time": "Insert titled tabs that show one panel at a time.",
"multicolumn-layout": "Multicolumn layout",
"multicolumn-layout-toolbar": "Multicolumn layout toolbar",
- "multiple-column-layout": "Multiple column layout",
"0-columns": "%0 columns",
"column-layout": "Column layout",
"0-columns-layout": "%0 columns layout",
diff --git a/apps/client/src/widgets/react/FormList.tsx b/apps/client/src/widgets/react/FormList.tsx
index df42ef5e6b..a4d1c094c0 100644
--- a/apps/client/src/widgets/react/FormList.tsx
+++ b/apps/client/src/widgets/react/FormList.tsx
@@ -454,6 +454,11 @@ export interface FormDropdownSubmenuProps {
className?: string;
/** Inside a menu, whether typing while the submenu is open filters it. See `MenuCommandItem.filterable`. */
filterable?: boolean;
+ /**
+ * Draws the row as a tile of a `MenuTile` strip, which only opens the submenu: a tile has no
+ * room for the arrow of a split row.
+ */
+ tile?: boolean;
}
/**
@@ -467,7 +472,7 @@ export function FormDropdownSubmenu(props: FormDropdownSubmenuProps) {
return <MenuSubmenu {...props} menu={menu} />;
}
-function MenuSubmenu({ menu, icon, iconSvg, title, description, children, onDropdownToggleClicked, split = !!onDropdownToggleClicked, disabled, className, filterable }: FormDropdownSubmenuProps & { menu: MenuContextValue }) {
+function MenuSubmenu({ menu, icon, iconSvg, title, description, children, onDropdownToggleClicked, split = !!onDropdownToggleClicked, disabled, className, filterable, tile }: FormDropdownSubmenuProps & { menu: MenuContextValue }) {
const level = useContext(MenuLevelContext);
const id = useUniqueName("menu-row");
const openSubmenu = menu.open[level];
@@ -489,6 +494,53 @@ function MenuSubmenu({ menu, icon, iconSvg, title, description, children, onDrop
menu.openSubmenu(level, disabled ? undefined : id, e.currentTarget);
}
+ const layer = isMobile()
+ // A phone has no room beside the menu, so a submenu replaces it as a page of its own.
+ ? (open || pageSlide.from !== undefined) && menu.layerHost && createPortal((
+ <SubmenuPage rowId={id} level={level + 1} title={title} slide={pageSlide}>
+ <MenuFilterContext.Provider value={filter}>{children}</MenuFilterContext.Provider>
+ </SubmenuPage>
+ ), menu.layerHost)
+ : open && openSubmenu && menu.layerHost && createPortal((
+ <SubmenuLayer level={level + 1} submenu={openSubmenu} pinned={!!filter?.text}>
+ <MenuFilterContext.Provider value={filter}>{children}</MenuFilterContext.Provider>
+ </SubmenuLayer>
+ ), menu.layerHost);
+
+ if (tile) {
+ return (
+ <button
+ id={id} type="button"
+ ref={(element) => {
+ menu.registerRow(id, element
+ ? { level, element, custom: false, disabled: !!disabled, hasSubmenu: true, inline: true, filterable, select: () => {} }
+ : undefined);
+ }}
+ className={clsx("tn-menu-action", isActive && "tn-menu-active", className)}
+ role="menuitem" aria-haspopup="menu" aria-expanded={open}
+ disabled={disabled} tabIndex={-1}
+ onPointerMove={(e) => {
+ if (!disabled && !isActive && pointerMoved(e)) menu.setActive(level, id);
+ }}
+ // As any row: the press keeps focus where it was, and the release acts.
+ onMouseDown={(e) => e.preventDefault()}
+ onClick={(e) => {
+ // The dropdown's `closeOnClickInside` would close the whole menu.
+ e.stopPropagation();
+ menu.setActive(level, id);
+ menu.openSubmenu(level, id, e.currentTarget, true);
+ }}
+ >
+ <span className="tn-menu-action-icon" aria-hidden="true">
+ {iconSvg ? <SvgIcon svg={iconSvg} /> : <Icon icon={icon} />}
+ </span>
+ <span id={titleId(id)} className="tn-menu-action-title">{title}</span>
+ <span className="tn-menu-action-more bx bx-chevron-right" aria-hidden="true" />
+ {layer}
+ </button>
+ );
+ }
+
return (
<li
id={id}
@@ -544,18 +596,7 @@ function MenuSubmenu({ menu, icon, iconSvg, title, description, children, onDrop
}}
/>
)}
- {isMobile()
- // A phone has no room beside the menu, so a submenu replaces it as a page of its own.
- ? (open || pageSlide.from !== undefined) && menu.layerHost && createPortal((
- <SubmenuPage rowId={id} level={level + 1} title={title} slide={pageSlide}>
- <MenuFilterContext.Provider value={filter}>{children}</MenuFilterContext.Provider>
- </SubmenuPage>
- ), menu.layerHost)
- : open && openSubmenu && menu.layerHost && createPortal((
- <SubmenuLayer level={level + 1} submenu={openSubmenu} pinned={!!filter?.text}>
- <MenuFilterContext.Provider value={filter}>{children}</MenuFilterContext.Provider>
- </SubmenuLayer>
- ), menu.layerHost)}
+ {layer}
</li>
);
}
diff --git a/apps/client/src/widgets/react/Menu.css b/apps/client/src/widgets/react/Menu.css
index 129d6a0e3b..e8ba8e36a7 100644
--- a/apps/client/src/widgets/react/Menu.css
+++ b/apps/client/src/widgets/react/Menu.css
@@ -322,6 +322,18 @@ body.mobile .tn-menu-actions.tn-menu-actions-cards {
font-size: 0.6em;
}
+.tn-menu-action-more {
+ position: absolute;
+ inset-block-start: 2px;
+ inset-inline-end: 2px;
+ color: var(--menu-item-icon-color);
+ opacity: 0.6;
+
+ &:dir(rtl) {
+ transform: scaleX(-1);
+ }
+}
+
.tn-menu-action-title {
max-width: 100%;
overflow: hidden;
diff --git a/apps/client/src/widgets/type_widgets/text/toolbar.spec.ts b/apps/client/src/widgets/type_widgets/text/toolbar.spec.ts
index e6a6f850e8..74e812f927 100644
--- a/apps/client/src/widgets/type_widgets/text/toolbar.spec.ts
+++ b/apps/client/src/widgets/type_widgets/text/toolbar.spec.ts
@@ -130,19 +130,19 @@ describe("buildMobileToolbar", () => {
expect(groups).toStrictEqual([ {
label: "text-editor.toolbar-groups.insert",
icon: "plus",
- asMenu: true,
+ asMenu: { layout: "tiles" },
items: [
"collapsible", "tabs", "multicolumnLayout",
"|",
- "horizontalLine", "pageBreak",
+ "horizontalLine", "pageBreak", "footnote",
"|",
"math", "drawingCanvas", "mermaid",
"|",
- "footnote", "bookmark", "linkEmbed", "contentEmbed",
+ "bookmark", "linkEmbed", "contentEmbed",
"|",
- "dateTime", "specialCharacters", "emoji", "insertIcon",
+ "specialCharacters", "emoji", "insertIcon",
"|",
- "insertTemplate", "markdownImport"
+ "dateTime", "insertTemplate", "markdownImport"
]
} ]);
expect((textFormattingToolbar as unknown[]).every((item) => typeof item === "string")).toBe(true);
diff --git a/apps/client/src/widgets/type_widgets/text/toolbar.ts b/apps/client/src/widgets/type_widgets/text/toolbar.ts
index c13fcf475d..eec1fc3059 100644
--- a/apps/client/src/widgets/type_widgets/text/toolbar.ts
+++ b/apps/client/src/widgets/type_widgets/text/toolbar.ts
@@ -57,18 +57,20 @@ export function buildMobileToolbar(aiAssistant: boolean) {
"|",
{
...buildInsertGroup(),
+ // Groups of three fill the rows of tiles.
+ asMenu: { layout: "tiles" },
items: [
"collapsible", "tabs", "multicolumnLayout",
"|",
- "horizontalLine", "pageBreak",
+ "horizontalLine", "pageBreak", "footnote",
"|",
"math", "drawingCanvas", "mermaid",
"|",
- "footnote", "bookmark", "linkEmbed", "contentEmbed",
+ "bookmark", "linkEmbed", "contentEmbed",
"|",
- "dateTime", "specialCharacters", "emoji", "insertIcon",
+ "specialCharacters", "emoji", "insertIcon",
"|",
- "insertTemplate", "markdownImport"
+ "dateTime", "insertTemplate", "markdownImport"
]
},
"blockType",
diff --git a/apps/client/src/widgets/type_widgets/text/toolbar_group_menu.css b/apps/client/src/widgets/type_widgets/text/toolbar_group_menu.css
index ffea215629..dda74f6ac0 100644
--- a/apps/client/src/widgets/type_widgets/text/toolbar_group_menu.css
+++ b/apps/client/src/widgets/type_widgets/text/toolbar_group_menu.css
@@ -7,6 +7,16 @@
display: grid;
grid-template-columns: repeat(3, 1fr);
+ & > .tn-menu-action > .tn-menu-action-title {
+ display: -webkit-box;
+ -webkit-box-orient: vertical;
+ -webkit-line-clamp: 2;
+ line-clamp: 2;
+ white-space: normal;
+ text-align: center;
+ text-wrap: balance;
+ }
+
& > .tn-menu-action[aria-checked="true"] {
color: var(--left-pane-item-selected-color, var(--active-item-text-color));
background-image: linear-gradient(
diff --git a/apps/client/src/widgets/type_widgets/text/toolbar_group_menu.spec.tsx b/apps/client/src/widgets/type_widgets/text/toolbar_group_menu.spec.tsx
index 4922170ec5..9098335005 100644
--- a/apps/client/src/widgets/type_widgets/text/toolbar_group_menu.spec.tsx
+++ b/apps/client/src/widgets/type_widgets/text/toolbar_group_menu.spec.tsx
@@ -125,6 +125,103 @@ describe("createToolbarGroupMenuHost", () => {
expect(menu?.isConnected).toBe(false);
});
+ describe("an entry with a submenu, in the tiles layout", () => {
+ afterEach(() => {
+ window.glob.device = "desktop";
+ });
+
+ function showTiles() {
+ const runs: string[] = [];
+ const run = (name: string) => () => {
+ host.hide();
+ runs.push(name);
+ };
+ const items: ToolbarGroupMenuItem[] = [
+ { kind: "entry", label: "Math", icon: ICON, isEnabled: true, run: run("math") },
+ {
+ kind: "entry", label: "Date/time", icon: ICON, isEnabled: true, run: run("date"),
+ children: [ { kind: "entry", label: "2026-10-05", isEnabled: true, run: run("iso") } ]
+ },
+ { kind: "entry", label: "Emoji", icon: ICON, isEnabled: true, run: run("emoji") },
+ {
+ kind: "entry", label: "Columns", isEnabled: false,
+ children: [ { kind: "entry", label: "3 columns", isEnabled: true, run: run("three") } ]
+ }
+ ];
+ host.show({ anchor, items, layout: "tiles", setElement: vi.fn(), onClose: vi.fn() });
+
+ const menu = document.querySelector<HTMLElement>(".tn-popup.tn-menu");
+ const tile = [ ...menu?.querySelectorAll<HTMLElement>(".tn-menu-action") ?? [] ]
+ .find((action) => action.textContent === "Date/time");
+ if (!menu || !tile) throw new Error("expected the menu and its Date/time tile to render");
+ return { menu, tile, runs };
+ }
+
+ it("is a tile among the others, marked as opening a submenu", () => {
+ const { menu, tile } = showTiles();
+
+ const groups = [ ...menu.querySelectorAll(".toolbar-group-menu-tiles") ];
+ expect(groups.map((group) => [ ...group.querySelectorAll(".tn-menu-action") ].map((action) => action.textContent)))
+ .toEqual([ [ "Math", "Date/time", "Emoji", "Columns" ] ]);
+ expect(tile.getAttribute("aria-haspopup")).toBe("menu");
+ expect(tile.getAttribute("aria-expanded")).toBe("false");
+ expect(tile.querySelector(".tn-svg-icon > svg")).not.toBeNull();
+ expect(tile.querySelector(".tn-menu-action-more")).not.toBeNull();
+
+ const columns = [ ...menu.querySelectorAll<HTMLButtonElement>(".tn-menu-action") ].at(-1);
+ expect(columns?.disabled).toBe(true);
+ expect(columns?.querySelector(".tn-menu-action-icon > .tn-icon")).not.toBeNull();
+ });
+
+ it("becomes the active row as the pointer moves over it, and keeps the focus on a press", async () => {
+ const { menu, tile } = showTiles();
+
+ tile.dispatchEvent(new PointerEvent("pointermove", { bubbles: true, movementX: 5 }));
+ await vi.waitFor(() => expect(menu.querySelector(".tn-menu-active")?.textContent).toBe("Date/time"));
+ const pressed = new MouseEvent("mousedown", { bubbles: true, cancelable: true, button: 0 });
+ tile.dispatchEvent(pressed);
+ expect(pressed.defaultPrevented).toBe(true);
+ });
+
+ it("opens its submenu beside it, without running its own action, and runs a row of it", async () => {
+ const { menu, tile, runs } = showTiles();
+
+ tile.click();
+ await vi.waitFor(() => expect(menu.querySelector(":scope > div.dropdown-submenu > .dropdown-menu")?.textContent)
+ .toBe("2026-10-05"));
+ expect(tile.getAttribute("aria-expanded")).toBe("true");
+ expect(runs).toEqual([]);
+
+ press(rowTitled("2026-10-05"));
+ expect(runs).toEqual([ "iso" ]);
+ });
+
+ it("opens its submenu from the keys with Enter, Right moving on to the next tile", async () => {
+ const { menu, runs } = showTiles();
+ const key = (name: string) =>
+ menu.dispatchEvent(new KeyboardEvent("keydown", { key: name, bubbles: true, cancelable: true }));
+ const active = () => menu.querySelector(".tn-menu-active")?.textContent;
+
+ key("ArrowDown");
+ await vi.waitFor(() => expect(active()).toBe("Math"));
+ key("ArrowRight");
+ await vi.waitFor(() => expect(active()).toBe("Date/time"));
+ key("Enter");
+ await vi.waitFor(() => expect(active()).toBe("2026-10-05"));
+ expect(runs).toEqual([]);
+ });
+
+ it("opens its submenu as a page on a phone", async () => {
+ window.glob.device = "mobile";
+ const { menu, tile } = showTiles();
+
+ tile.click();
+ const page = () => menu.querySelector<HTMLElement>(":scope > .tn-menu-page");
+ await vi.waitFor(() => expect(page()?.querySelector(".tn-menu-scroll")?.textContent).toBe("2026-10-05"));
+ expect(page()?.querySelector(".tn-menu-page-header")?.textContent).toContain("Date/time");
+ });
+ });
+
it("runs an entry without closing a second time, and leaves a disabled one alone", () => {
const { menu, runs, setElement, onClose } = show();
diff --git a/apps/client/src/widgets/type_widgets/text/toolbar_group_menu.tsx b/apps/client/src/widgets/type_widgets/text/toolbar_group_menu.tsx
index b72c1cb9b4..a674a8e8a1 100644
--- a/apps/client/src/widgets/type_widgets/text/toolbar_group_menu.tsx
+++ b/apps/client/src/widgets/type_widgets/text/toolbar_group_menu.tsx
@@ -8,7 +8,7 @@ import { render } from "preact";
import { escapeHtml, isMobile, isNarrowLayout } from "../../../services/utils";
import { FormDropdownDivider, FormDropdownSubmenu, FormListItem } from "../../react/FormList";
import Menu, { MenuTile } from "../../react/Menu";
-import { isKeyboardPanelOpen, useKeyboardPanel } from "./mobile_editor_toolbar";
+import { isKeyboardPanelOpen, logMenuHost, useKeyboardPanel } from "./mobile_editor_toolbar";
/** The gap between the group's button and the menu, as a `Dropdown` leaves under its toggle. */
const ANCHOR_GAP = 2;
@@ -27,6 +27,8 @@ export function createToolbarGroupMenuHost(): ToolbarGroupMenuHost {
return {
show(request) {
+ // TEMPORARY: press diagnostics.
+ logMenuHost(`show ${request.anchor.getAttribute("aria-labelledby") ?? ""}`);
shown = request;
// An entry that runs hides the menu first, so a close that follows finds it gone.
const close = (returnFocus: boolean) => {
@@ -36,7 +38,11 @@ export function createToolbarGroupMenuHost(): ToolbarGroupMenuHost {
};
render(<ToolbarGroupMenu request={request} onClose={close} />, container);
},
- hide: unmount,
+ hide: () => {
+ // TEMPORARY: press diagnostics.
+ logMenuHost("hide");
+ unmount();
+ },
destroy: unmount,
isInPlaceOfKeyboard: isKeyboardPanelOpen
};
@@ -101,7 +107,10 @@ function MenuRows({ items }: { items: ToolbarGroupMenuItem[] }) {
);
}
-/** The entries as tiles, a grid of them for each group between separators. */
+/**
+ * The entries as tiles, a grid of them for each group between separators. An entry with a submenu
+ * is a tile that opens it.
+ */
function MenuTileGroups({ items }: { items: ToolbarGroupMenuItem[] }) {
const groups: ToolbarGroupMenuEntry[][] = [ [] ];
for (const item of items) {
@@ -116,11 +125,18 @@ function MenuTileGroups({ items }: { items: ToolbarGroupMenuItem[] }) {
<>
{groups.map((group, index) => (
<li key={index} className="tn-menu-actions tn-menu-actions-cards toolbar-group-menu-tiles" role="group">
- {group.map(({ label, icon, isEnabled, isOn, run }, tileIndex) => (
- <MenuTile
- key={tileIndex} iconSvg={icon} title={escapeHtml(label)} tooltip={label}
- disabled={!isEnabled} checked={isOn} onSelect={() => run?.()}
- />
+ {group.map(({ label, icon, isEnabled, isOn, run, children }, tileIndex) => (children
+ ? (
+ <FormDropdownSubmenu key={tileIndex} tile iconSvg={icon} title={label} disabled={!isEnabled}>
+ <MenuRows items={children} />
+ </FormDropdownSubmenu>
+ )
+ : (
+ <MenuTile
+ key={tileIndex} iconSvg={icon} title={escapeHtml(label)} tooltip={label}
+ disabled={!isEnabled} checked={isOn} onSelect={() => run?.()}
+ />
+ )
))}
</li>
))}
diff --git a/apps/server/src/assets/help/help_content.json b/apps/server/src/assets/help/help_content.json
index d30509e16e..70fa2a04f0 100644
--- a/apps/server/src/assets/help/help_content.json
+++ b/apps/server/src/assets/help/help_content.json
@@ -29,7 +29,7 @@
"_help_yeEaYqosGLSh": "<p>As an alternative to <a href=\"#root/_help_Dgg7bR3b6K9j\">hosting your own Trilium instance</a>, there are two services out there that provide out of the box support for Trilium.</p><aside class=\"admonition important\"><p><strong>Disclaimer</strong>: The Trilium Notes project and maintainers are not directly affiliated with either of the projects.</p><p>PikaPods have gracefully offered us free credits for testing purposes.</p></aside><h2>Cloud instance providers</h2><h3>PikaPods</h3><ol><li>Go to <a href=\"https://www.pikapods.com\">pikapods.com</a> &nbsp;and sign up.</li><li>In the “Available Apps” section, look for \"TriliumNext<br>&nbsp;and select “Run your own”.</li><li>Follow the on-screen instructions to set up your own cloud hosted instance.</li></ol><p>PikaPods generally updates their Trilium instances to the latest version within a two-week interval after a new version is released.</p><h2>Matching your version with the cloud instance</h2><p>Please note that once you set up&nbsp;<a class=\"reference-link\" href=\"#root/_help_cbkrhQjrkKrh\">Synchronization</a>&nbsp;between a cloud instance and <a href=\"#root/_help_poXkQfguuA0U\">desktop</a> clients, it's important that the version of the desktop application and the server match up.</p><p>When setting up a cloud instance, it's best to check the version of the server by accessing it via a web browser and going to the <em>About</em> section. It's best that both the desktop and the server have the same <em>App version</em>; however it's generally OK to update the desktop to a newer version than the server if it has the same <em>Sync version</em>.</p><p>If the <em>Sync version</em> between the server and the desktop application doesn't match, synchronization will not work.</p>",
"_help_iGTnKjubbXkA": "<ul><li>Using Docker, the server can be run on Windows, Linux and macOS devices.</li><li>Native binaries are provided for Linux x64 and ARM (<code>aarch64</code>).</li></ul><h2>Legacy ARM support</h2><p>The Docker builds also provide <code>linux/arm/v7</code> and <code>linux/arm/v8</code> platforms. These platforms are considered legacy since Trilium uses Node.js version 24 which have <a href=\"https://github.com/nodejs/node/commit/6682861d6f\">officially downgraded support</a> for these platforms to “experimental”.</p><p>As a result, Trilium needs to use Node.js 22 for these versions. As soon as soon Node.js 22 will no longer be compatible, support for <code>armv7</code> and <code>armv8</code> will be dropped entirely.</p><p>Regardless of upstream support, these platforms are supported on a best-effort basis and are not officially supported by the Trilium development team. Bug reports are accepted but they will not be treated with priority; contributions are welcome.</p>",
"_help_cbkrhQjrkKrh": "<p>Trilium is an offline-first note-taking application that stores all data locally on the desktop client. However, it also offers the option to set up synchronization with a server instance, allowing multiple desktop clients to sync with a central server. This creates a star-shaped topology:</p><p><img src=\"{{helpAssets}}/User%20Guide/Installation%20%26%20Setup/Synchronization_image.jpg\"></p><p>In this setup, a central server (referred to as the <em>sync server</em>) and multiple <em>client</em> (or <em>desktop</em>) instances synchronize with the sync server. Once configured, synchronization is automatic and ongoing, requiring no manual intervention.</p><h2>Setting Up Synchronization</h2><h3>Security Considerations</h3><p>Setting up the server securely is critical and can be complex. It is crucial to use a valid <a href=\"#root/_help_l2VkvOwUNfZj\">TLS certificate</a> (HTTPS) rather than an unencrypted HTTP connection to ensure security and avoid potential vulnerabilities.</p><h3>Synchronizing a Desktop Instance with a Sync Server</h3><p>This method is used when you already have a desktop instance of Trilium and want to set up a sync server on your web host.</p><ol><li><strong>Server Deployment</strong>: Ensure your server instance is deployed but uninitialized.</li><li><strong>Desktop Configuration</strong>: Open your desktop instance, navigate to&nbsp;<a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a>&nbsp;→ <em>Sync</em> → <em>Sync server</em>, and set the <em>Server address</em> to your sync server's address.<ul><li>Note that the sync server can also be overridden through&nbsp;<a class=\"reference-link\" href=\"#root/_help_Gzjqa934BdH4\">Configuration (config.ini or environment variables)</a>, case in which that value takes precedence. If that's the case, a field called <em>Server in use</em> indicates it.</li></ul></li><li><strong>Testing Sync</strong>: Click the <em>Test sync</em> button to verify the connection to the sync server.<ul><li>If successful, the client will start pushing all data to the server instance.</li><li>This process may take some time, but you can continue using Trilium. Periodically check the server instance to confirm when the sync is complete. Once finished, you should see the login screen on the server.</li></ul></li></ol><h3>Synchronizing a Desktop Instance from a Sync Server</h3><p>This method is used when you already have a sync server and want to configure a new desktop instance to sync with it.</p><ol><li><strong>Desktop Setup</strong>: Follow the <a href=\"#root/_help_poXkQfguuA0U\">desktop installation page</a>.</li><li><strong>Initial Configuration</strong>: When prompted, choose the option to set up sync with a sync server.</li></ol><p><img src=\"{{helpAssets}}/User%20Guide/Installation%20%26%20Setup/Synchronization_sync-init.png\" alt=\"screenshot of the sync from server setup page\"></p><ol><li><strong>Server Details</strong>: Configure the Trilium server address and enter the server's password. If the server has <a class=\"reference-link\" href=\"#root/_help_7DAiwaf8Z7Rz\">Multi-factor authentication with TOTP</a> enabled, also enter a one-time password from your authenticator app, or a recovery code.</li><li><strong>Finish Setup</strong>: Click the \"Finish setup\" button. If successful, you will see the following screen:</li></ol><p><img src=\"{{helpAssets}}/User%20Guide/Installation%20%26%20Setup/Synchronization_sync-in-progress.png\" alt=\"screenshot of the sync page\"></p><p>Once synchronization is complete, you will be automatically redirected to the Trilium application.</p><h3>Desktop-to-desktop sync</h3><p>This method allows two desktop instances to synchronize between each other without requiring a&nbsp;<a class=\"reference-link\" href=\"#root/_help_WOcw2SLH6tbX\">Server Installation</a>.</p><aside class=\"admonition warning\"><p>Since v0.104.0, LAN access needs to be enabled to allow this sync to function. See&nbsp;<a class=\"reference-link\" href=\"#root/_help_swSFivWk6KkA\">Network Access</a>&nbsp;for information on how to do so.</p></aside><h2>Proxy Configuration</h2><p>Two proxy setups are supported:</p><ul><li><strong>Explicit Proxy Configuration</strong>: Set the proxy server in Options / Sync. Only unauthenticated proxy servers are supported.</li><li><strong>System Proxy Settings</strong>: If no proxy server is explicitly configured, Trilium will use the system proxy settings.</li></ul><h2>Troubleshooting</h2><h3>Date/Time Synchronization</h3><p>For successful synchronization, both client and server must have the same date and time, with a tolerance of up to five minutes.</p><h3>Certificate Issues</h3><p>When using TLS, Trilium will verify the server certificate. If verification fails (e.g., due to self-signed certificates or certain corporate proxies), you can run the Trilium client with the <code>NODE_TLS_REJECT_UNAUTHORIZED</code> environment variable set to <code>0</code>:</p><pre><code class=\"language-text-x-trilium-auto\">export NODE_TLS_REJECT_UNAUTHORIZED=0</code></pre><p>This will disable TLS certificate verification, significantly reducing security and exposing the setup to MITM attacks. It is strongly recommended to use a valid signed server certificate. Newer Trilium versions include a script called <code>trilium-no-cert-check.sh</code> for this purpose.</p><h3>Conflict Resolution</h3><p>If you edit the same note on multiple instances before synchronization, Trilium resolves conflicts by retaining the newer change and discarding the older one. The older version remains accessible in <a href=\"#root/_help_vZWERwf8U3nx\">note revisions</a>, allowing data recovery if needed.</p><h3>Hash Check</h3><p>After each synchronization, Trilium computes a hash of all synced data on both the client and the sync server. If there is a discrepancy, Trilium will automatically initiate a recovery mechanism to resolve the issue.</p>",
- "_help_RDslemsQ6gCp": "<figure class=\"image image-style-align-right image_resized\" style=\"width:33.52%;\"><img style=\"aspect-ratio:1242/2688;\" src=\"{{helpAssets}}/User%20Guide/Installation%20%26%20Setup/Mobile%20Frontend_IMG_1765.PNG\" width=\"1242\" height=\"2688\"></figure><p>Trilium has a mobile web frontend which is optimized for touch based devices - smartphones and tablets. It is activated automatically during login process based on browser detection.</p><p>Mobile frontend is limited in features compared to the full desktop version. See below for more details on this.</p><h2>Layout basics</h2><p>Unlike the desktop version, the mobile version has a slightly different UI meant to better fit the constrained screens of a mobile phone.</p><p>Here is a non-exhaustive list of differences between the desktop version and the mobile one:</p><ul><li>The&nbsp;<a class=\"reference-link\" href=\"#root/_help_oPVyFC7WL2Lp\">Note Tree</a>&nbsp;is displayed as a sidebar. To display the sidebar, press the button in the top-left of the screen.<ul><li>There is also a swipe gesture that can be done from the left of the screen, but the browser's navigation gesture interferes with it most of the time (depending on the platform).</li><li>Press and hold a note to display the&nbsp;<a class=\"reference-link\" href=\"#root/_help_YtSN43OrfzaA\">Note tree contextual menu</a>.</li></ul></li><li>The&nbsp;<a class=\"reference-link\" href=\"#root/_help_Ms1nauBra7gq\">Quick search</a>&nbsp;bar is also displayed at the top of the note tree.</li><li>The full&nbsp;<a class=\"reference-link\" href=\"#root/_help_eIg8jdvaoNNd\">Search</a>&nbsp;function can be triggered either from either the&nbsp;<a class=\"reference-link\" href=\"#root/_help_x3i7MxGccDuM\">Global menu</a>&nbsp;or from the&nbsp;<a class=\"reference-link\" href=\"#root/_help_xYmIYSP6wE3F\">Launch Bar</a>, if configured.</li><li>The&nbsp;<a class=\"reference-link\" href=\"#root/_help_x3i7MxGccDuM\">Global menu</a> is shorter: <em>Open new window</em> and <em>Show cheatsheet</em> are left out, and <em>Switch to desktop version</em> is under <em>Advanced</em>.</li><li>The&nbsp;<a class=\"reference-link\" href=\"#root/_help_xYmIYSP6wE3F\">Launch Bar</a>&nbsp;is displayed at the bottom of the screen.<ul><li>The launch bar uses a different configuration for icons than the desktop version. See the dedicated page for more information on how to configure it.</li></ul></li><li>Most of the note-related actions are grouped in the horizontal dots icon on the top-right of the note.</li><li>In a text note, the formatting toolbar sits at the bottom of the screen as a single row that scrolls sideways. It is shown only while you are editing the text, and hides when you hide the keyboard or move to another field, such as the note title. It starts with <em>Undo</em> and <em>Redo</em>, since the on-screen keyboard has no keys for them. The <span class=\"tn-icon cke cke-plus\"></span> button after them opens a menu of the less common insertions: collapsible, tabs, columns, horizontal line, page break, math, drawing canvas, Mermaid diagram, footnote, bookmark, link and content embeds, date/time, special characters, emoji, icon, template and Markdown import. The block type button shows the type of the current block as an icon rather than its name, and opens the block types as tiles at the bottom of the screen, with the current one highlighted: paragraph and heading 2 to 6, then bulleted list, numbered list and to-do list, then code block, block quote and admonition. Picking a paragraph or a heading in a list turns the item back into plain text, and the same goes for a code block. Block quote and admonition wrap the current block rather than replace it, so they are highlighted alongside it; pick one again to remove it. Typing <code>-</code> , <code>1.</code> or <code>[ ]</code> at the start of a line also starts a list. The style of a list (such as roman numerals) and its start number can only be changed on desktop.<ul><li>The formatting applied to text (bold, italic, underline, strikethrough, inline code, superscript and subscript, keyboard shortcut, font size and colors, and removing formatting) is on a row of its own. Tap <span class=\"tn-icon cke cke-text\"></span> next to the block type button to show it, and <span class=\"tn-icon cke cke-previous-arrow\"></span> at its start to return to the main row. Selecting text shows this row on its own, and it goes back to the main row once the selection is gone (for example as you start typing), unless you opened or closed the row yourself in the meantime. The font size button opens the list of sizes as a menu at the bottom of the screen, each drawn at its size, with the current one checked. A single color button replaces the separate text and background color buttons: it opens a menu with a row of colors for the text and one for its background, each with a cell that removes the color and one that opens the device's color picker.</li></ul></li><li>While the on-screen keyboard is open, a <span class=\"tn-icon bx bxs-keyboard\"></span> button in the bottom-right corner, just above the keyboard, hides it. In a text note, the button is at the right end of the formatting toolbar. This works in every note type and in every text field, and is the only way to hide the keyboard in the iOS app, where the keyboard has no <em>Done</em> button.</li><li>The&nbsp;<a class=\"reference-link\" href=\"#root/_help_3seOhtN8uLIY\">Tabs</a>&nbsp;are grouped under a tab switcher in the&nbsp;<a class=\"reference-link\" href=\"#root/_help_xYmIYSP6wE3F\">Launch Bar</a>, where the tabs are displayed in a full-screen grid with preview for easy switching, as well as additional options such as reopening closed tabs.</li><li>Since v0.100.0,&nbsp;<a class=\"reference-link\" href=\"#root/_help_luNhaphA37EO\">Split View</a>&nbsp;can also be used in mobile view, but with a maximum of two panes at once. The splits are displayed vertically instead of horizontally.</li></ul><h2>Installing as a PWA</h2><p>The mobile view can be set up as a PWA. While this does not offer any offline capabilities, it will display the application in full-screen and makes it easy to access via your mobile phone's home screen.</p><div class=\"trilium-tabs\"><section class=\"trilium-tab\"><p class=\"trilium-tab-title\"><span class=\"tn-icon bx bxl-apple\"></span>&nbsp;iOS with Safari</p><div class=\"trilium-tab-panel\"><ol><li>Open your default web browser and access your Trilium instance.</li><li>Login.</li><li>Press the […] button in the bottom-right of the screen and select Share.</li><li>Scroll down to reveal the full list of items and choose <em>Add to Home Screen</em>.</li><li>Press <em>Add</em> and the web app will be available.</li></ol></div></section><section class=\"trilium-tab\"><p class=\"trilium-tab-title\"><span class=\"tn-icon bx bxl-chrome\"></span>&nbsp;Android with Google Chrome</p><div class=\"trilium-tab-panel\"><aside class=\"admonition important\"><p>Google Chrome requires the server to be served over HTTPS in order to display in full-screen. If using HTTP, the app will appear like a normal web page (similar to a bookmark).</p></aside><ol><li>Open your default web browser and access your Trilium instance.</li><li>Login.</li><li>Press the three vertical dots icon in the top-right of the screen and select <em>Add to Home screen.</em></li><li>Select the <em>Install</em> option.</li><li>Select an appropriate name.</li><li>The web app will appear as an application, not on the home screen.</li></ol></div></section><section class=\"trilium-tab\"><p class=\"trilium-tab-title\">Android with Brave</p><div class=\"trilium-tab-panel\"><aside class=\"admonition important\"><p>Brave requires the server to be served over HTTPS in order to display in full-screen. If using HTTP, the app will appear like a normal web page (similar to a bookmark).</p></aside><ol><li>Open your default web browser and access your Trilium instance.</li><li>Login.</li><li>Press the three vertical dots icon in the bottom-right of the screen and select <em>Add to Home screen</em>.</li><li>Press the <em>Install</em> option.</li><li>The web app will appear as an application, not on the home screen.</li></ol></div></section><section class=\"trilium-tab\"><p class=\"trilium-tab-title\">Samsung Browser</p><div class=\"trilium-tab-panel\"><ol><li>Open your default web browser and access your Trilium instance.</li><li>Login.</li><li>Press the hamburger menu in the bottom-right of the screen.</li><li>Select <em>Add to</em>, followed by <em>Home screen</em>.</li><li>Press <em>Add</em> and the web app will appear on the home page.</li></ol></div></section></div><h2>Sharing to Trilium</h2><p>Once installed as a PWA on Android, Trilium appears in the system's share menu, so links, text, images and other files can be sent to it from other apps. Shared content is saved to the&nbsp;<a class=\"reference-link\" href=\"#root/_help_S0Fos78ZfcY7\">Note Inbox</a>, and Trilium opens the note it created:</p><ul><li>Text or a link becomes a text note. A shared link is also stored in the <code>#pageUrl</code> label.</li><li>A single file becomes an image note or a file note, placed directly in the inbox.</li><li>Several files, or files shared together with text, are placed under a new text note that holds the text.</li></ul><p>Every note created this way carries the <code>#clipType=share</code> label, which gives a shared text note the <span class=\"tn-icon bx bx-share\"></span> icon unless the note has an <code>#iconClass</code> of its own. A single share can carry at most 20 files.</p><aside class=\"admonition note\"><p>Sharing requires being logged in. If the session has expired, log in again and share once more.</p></aside><h2>Testing via the desktop application</h2><p>If you are running Trilium without a dedicated <a href=\"#root/_help_WOcw2SLH6tbX\">server installation</a>, you can still test the mobile application using the desktop application. For more information, see&nbsp;<a class=\"reference-link\" href=\"#root/_help_nRqcgfTb97uV\">Using the desktop application as a server</a>. To access it go to <code>http://&lt;ip&gt;:37840/login?mobile</code> .</p><h2>Forcing mobile/desktop frontend</h2><p>Trilium decides automatically whether to use mobile or desktop front-end. If this is not appropriate, you can use <code>?mobile</code> or <code>?desktop</code> query param on <strong>login</strong> page (Note: you might need to log out).</p><p>Alternatively, simply select <em>Switch to mobile version</em> in the&nbsp;<a class=\"reference-link\" href=\"#root/_help_x3i7MxGccDuM\">Global menu</a>. In the mobile version, select <em>Advanced</em> → <em>Switch to desktop version</em> there instead.</p><h2>Scripting</h2><p>You can alter the behavior with&nbsp;<a class=\"reference-link\" href=\"#root/_help_CdNpE2pqjmI6\">Scripting</a>, just like for normal frontend. For script notes to be executed, they need to have labeled <code>#run=mobileStartup</code>.</p><p>Custom&nbsp;<a class=\"reference-link\" href=\"#root/_help_xYmIYSP6wE3F\">Launch Bar</a>&nbsp;widgets are also supported.</p>",
+ "_help_RDslemsQ6gCp": "<figure class=\"image image-style-align-right image_resized\" style=\"width:33.52%;\"><img style=\"aspect-ratio:1242/2688;\" src=\"{{helpAssets}}/User%20Guide/Installation%20%26%20Setup/Mobile%20Frontend_IMG_1765.PNG\" width=\"1242\" height=\"2688\"></figure><p>Trilium has a mobile web frontend which is optimized for touch based devices - smartphones and tablets. It is activated automatically during login process based on browser detection.</p><p>Mobile frontend is limited in features compared to the full desktop version. See below for more details on this.</p><h2>Layout basics</h2><p>Unlike the desktop version, the mobile version has a slightly different UI meant to better fit the constrained screens of a mobile phone.</p><p>Here is a non-exhaustive list of differences between the desktop version and the mobile one:</p><ul><li>The&nbsp;<a class=\"reference-link\" href=\"#root/_help_oPVyFC7WL2Lp\">Note Tree</a>&nbsp;is displayed as a sidebar. To display the sidebar, press the button in the top-left of the screen.<ul><li>There is also a swipe gesture that can be done from the left of the screen, but the browser's navigation gesture interferes with it most of the time (depending on the platform).</li><li>Press and hold a note to display the&nbsp;<a class=\"reference-link\" href=\"#root/_help_YtSN43OrfzaA\">Note tree contextual menu</a>.</li></ul></li><li>The&nbsp;<a class=\"reference-link\" href=\"#root/_help_Ms1nauBra7gq\">Quick search</a>&nbsp;bar is also displayed at the top of the note tree.</li><li>The full&nbsp;<a class=\"reference-link\" href=\"#root/_help_eIg8jdvaoNNd\">Search</a>&nbsp;function can be triggered either from either the&nbsp;<a class=\"reference-link\" href=\"#root/_help_x3i7MxGccDuM\">Global menu</a>&nbsp;or from the&nbsp;<a class=\"reference-link\" href=\"#root/_help_xYmIYSP6wE3F\">Launch Bar</a>, if configured.</li><li>The&nbsp;<a class=\"reference-link\" href=\"#root/_help_x3i7MxGccDuM\">Global menu</a> is shorter: <em>Open new window</em> and <em>Show cheatsheet</em> are left out, and <em>Switch to desktop version</em> is under <em>Advanced</em>.</li><li>The&nbsp;<a class=\"reference-link\" href=\"#root/_help_xYmIYSP6wE3F\">Launch Bar</a>&nbsp;is displayed at the bottom of the screen.<ul><li>The launch bar uses a different configuration for icons than the desktop version. See the dedicated page for more information on how to configure it.</li></ul></li><li>Most of the note-related actions are grouped in the horizontal dots icon on the top-right of the note.</li><li>In a text note, the formatting toolbar sits at the bottom of the screen as a single row that scrolls sideways. It is shown only while you are editing the text, and hides when you hide the keyboard or move to another field, such as the note title. It starts with <em>Undo</em> and <em>Redo</em>, since the on-screen keyboard has no keys for them. The <span class=\"tn-icon cke cke-plus\"></span> button after them opens the less common insertions as tiles at the bottom of the screen: collapsible, tabs, columns, horizontal line, page break, footnote, math, drawing canvas, Mermaid diagram, bookmark, link and content embeds, special characters, emoji, icon, date/time, template and Markdown import. The tiles marked with <span class=\"tn-icon bx bx-chevron-right\"></span>, <em>Columns</em> and <em>Date/time</em>, open a list of choices: the number of columns, and the format of the date and time. The block type button shows the type of the current block as an icon rather than its name, and opens the block types as tiles at the bottom of the screen, with the current one highlighted: paragraph and heading 2 to 6, then bulleted list, numbered list and to-do list, then code block, block quote and admonition. Picking a paragraph or a heading in a list turns the item back into plain text, and the same goes for a code block. Block quote and admonition wrap the current block rather than replace it, so they are highlighted alongside it; pick one again to remove it. Typing <code>-</code> , <code>1.</code> or <code>[ ]</code> at the start of a line also starts a list. The style of a list (such as roman numerals) and its start number can only be changed on desktop.<ul><li>The formatting applied to text (bold, italic, underline, strikethrough, inline code, superscript and subscript, keyboard shortcut, font size and colors, and removing formatting) is on a row of its own. Tap <span class=\"tn-icon cke cke-text\"></span> next to the block type button to show it, and <span class=\"tn-icon cke cke-previous-arrow\"></span> at its start to return to the main row. Selecting text shows this row on its own, and it goes back to the main row once the selection is gone (for example as you start typing), unless you opened or closed the row yourself in the meantime. The font size button opens the list of sizes as a menu at the bottom of the screen, each drawn at its size, with the current one checked. A single color button replaces the separate text and background color buttons: it opens a menu with a row of colors for the text and one for its background, each with a cell that removes the color and one that opens the device's color picker.</li></ul></li><li>While the on-screen keyboard is open, a <span class=\"tn-icon bx bxs-keyboard\"></span> button in the bottom-right corner, just above the keyboard, hides it. In a text note, the button is at the right end of the formatting toolbar. This works in every note type and in every text field, and is the only way to hide the keyboard in the iOS app, where the keyboard has no <em>Done</em> button.</li><li>The&nbsp;<a class=\"reference-link\" href=\"#root/_help_3seOhtN8uLIY\">Tabs</a>&nbsp;are grouped under a tab switcher in the&nbsp;<a class=\"reference-link\" href=\"#root/_help_xYmIYSP6wE3F\">Launch Bar</a>, where the tabs are displayed in a full-screen grid with preview for easy switching, as well as additional options such as reopening closed tabs.</li><li>Since v0.100.0,&nbsp;<a class=\"reference-link\" href=\"#root/_help_luNhaphA37EO\">Split View</a>&nbsp;can also be used in mobile view, but with a maximum of two panes at once. The splits are displayed vertically instead of horizontally.</li></ul><h2>Installing as a PWA</h2><p>The mobile view can be set up as a PWA. While this does not offer any offline capabilities, it will display the application in full-screen and makes it easy to access via your mobile phone's home screen.</p><div class=\"trilium-tabs\"><section class=\"trilium-tab\"><p class=\"trilium-tab-title\"><span class=\"tn-icon bx bxl-apple\"></span>&nbsp;iOS with Safari</p><div class=\"trilium-tab-panel\"><ol><li>Open your default web browser and access your Trilium instance.</li><li>Login.</li><li>Press the […] button in the bottom-right of the screen and select Share.</li><li>Scroll down to reveal the full list of items and choose <em>Add to Home Screen</em>.</li><li>Press <em>Add</em> and the web app will be available.</li></ol></div></section><section class=\"trilium-tab\"><p class=\"trilium-tab-title\"><span class=\"tn-icon bx bxl-chrome\"></span>&nbsp;Android with Google Chrome</p><div class=\"trilium-tab-panel\"><aside class=\"admonition important\"><p>Google Chrome requires the server to be served over HTTPS in order to display in full-screen. If using HTTP, the app will appear like a normal web page (similar to a bookmark).</p></aside><ol><li>Open your default web browser and access your Trilium instance.</li><li>Login.</li><li>Press the three vertical dots icon in the top-right of the screen and select <em>Add to Home screen.</em></li><li>Select the <em>Install</em> option.</li><li>Select an appropriate name.</li><li>The web app will appear as an application, not on the home screen.</li></ol></div></section><section class=\"trilium-tab\"><p class=\"trilium-tab-title\">Android with Brave</p><div class=\"trilium-tab-panel\"><aside class=\"admonition important\"><p>Brave requires the server to be served over HTTPS in order to display in full-screen. If using HTTP, the app will appear like a normal web page (similar to a bookmark).</p></aside><ol><li>Open your default web browser and access your Trilium instance.</li><li>Login.</li><li>Press the three vertical dots icon in the bottom-right of the screen and select <em>Add to Home screen</em>.</li><li>Press the <em>Install</em> option.</li><li>The web app will appear as an application, not on the home screen.</li></ol></div></section><section class=\"trilium-tab\"><p class=\"trilium-tab-title\">Samsung Browser</p><div class=\"trilium-tab-panel\"><ol><li>Open your default web browser and access your Trilium instance.</li><li>Login.</li><li>Press the hamburger menu in the bottom-right of the screen.</li><li>Select <em>Add to</em>, followed by <em>Home screen</em>.</li><li>Press <em>Add</em> and the web app will appear on the home page.</li></ol></div></section></div><h2>Sharing to Trilium</h2><p>Once installed as a PWA on Android, Trilium appears in the system's share menu, so links, text, images and other files can be sent to it from other apps. Shared content is saved to the&nbsp;<a class=\"reference-link\" href=\"#root/_help_S0Fos78ZfcY7\">Note Inbox</a>, and Trilium opens the note it created:</p><ul><li>Text or a link becomes a text note. A shared link is also stored in the <code>#pageUrl</code> label.</li><li>A single file becomes an image note or a file note, placed directly in the inbox.</li><li>Several files, or files shared together with text, are placed under a new text note that holds the text.</li></ul><p>Every note created this way carries the <code>#clipType=share</code> label, which gives a shared text note the <span class=\"tn-icon bx bx-share\"></span> icon unless the note has an <code>#iconClass</code> of its own. A single share can carry at most 20 files.</p><aside class=\"admonition note\"><p>Sharing requires being logged in. If the session has expired, log in again and share once more.</p></aside><h2>Testing via the desktop application</h2><p>If you are running Trilium without a dedicated <a href=\"#root/_help_WOcw2SLH6tbX\">server installation</a>, you can still test the mobile application using the desktop application. For more information, see&nbsp;<a class=\"reference-link\" href=\"#root/_help_nRqcgfTb97uV\">Using the desktop application as a server</a>. To access it go to <code>http://&lt;ip&gt;:37840/login?mobile</code> .</p><h2>Forcing mobile/desktop frontend</h2><p>Trilium decides automatically whether to use mobile or desktop front-end. If this is not appropriate, you can use <code>?mobile</code> or <code>?desktop</code> query param on <strong>login</strong> page (Note: you might need to log out).</p><p>Alternatively, simply select <em>Switch to mobile version</em> in the&nbsp;<a class=\"reference-link\" href=\"#root/_help_x3i7MxGccDuM\">Global menu</a>. In the mobile version, select <em>Advanced</em> → <em>Switch to desktop version</em> there instead.</p><h2>Scripting</h2><p>You can alter the behavior with&nbsp;<a class=\"reference-link\" href=\"#root/_help_CdNpE2pqjmI6\">Scripting</a>, just like for normal frontend. For script notes to be executed, they need to have labeled <code>#run=mobileStartup</code>.</p><p>Custom&nbsp;<a class=\"reference-link\" href=\"#root/_help_xYmIYSP6wE3F\">Launch Bar</a>&nbsp;widgets are also supported.</p>",
"_help_MtPxeAWVAzMg": "<p><img src=\"{{helpAssets}}/User%20Guide/Installation%20%26%20Setup/Web%20Clipper_image.png\"></p><p>Trilium Web Clipper is a web browser extension which allows user to clip text, screenshots, whole pages and short notes and save them directly to Trilium Notes.</p><h2>Supported browsers</h2><p>Trilium Web Clipper officially supports the following web browsers:</p><ul><li>Mozilla Firefox, using Manifest v2.</li><li>Google Chrome, using Manifest v3. Theoretically the extension should work on other Chromium-based browsers as well, but they are not officially supported.</li></ul><h2>Obtaining the extension</h2><p>The extension is available from the official browser web stores:</p><ul><li><strong>Firefox</strong>: <a href=\"https://addons.mozilla.org/firefox/addon/trilium-notes-web-clipper/\">Trilium Web Clipper on Firefox Add-ons</a></li><li><strong>Chrome</strong>: <a href=\"https://chromewebstore.google.com/detail/trilium-web-clipper/ofoiklieachadcaeffficgjaajojpkpi\">Trilium Web Clipper on Chrome Web Store</a></li></ul><h2>Functionality</h2><ul><li>select text and clip it with the right-click context menu</li><li>click on an image or link and save it through context menu</li><li>save whole page from the popup or context menu</li><li>save a PDF that the browser shows, as a file note</li><li>save a screenshot of an area you select, of the visible part of the page or of the whole page, from either popup or context menu</li><li>create short text note from popup</li></ul><h2>The popup</h2><p>Clicking the extension's button in the browser toolbar opens its popup:</p><ul><li><p>The popup shows what will be saved from the current page: the note's title, which can be edited before saving, the website, and below them a preview, which starts with a box for your own note and the page's description. A switch above the preview chooses what to save, among what the page offers:</p><ul><li><em>Selection</em>, when text is selected on the page: <em>Save selection</em> saves it into the note of that page's clippings, as the context menu does.</li><li><em>Page</em>: <em>Save page to Trilium</em> saves the page's text and images. A smaller switch at the top of the preview chooses how much of the page to keep: <em>Article</em> keeps only the page's main text, without its menus, sidebars and footers, and <em>Whole page</em> keeps everything the page shows. <em>Whole page</em> is for pages that are not an article (such as a gallery or a page of cards), where <em>Article</em> can leave out part of the content; the preview shows what each one keeps. <em>Article</em> is unavailable on a page where Trilium finds no article. The author the page names shows under the description, marked by the <span class=\"tn-icon bx bx-user\"></span> icon. It can be edited or cleared before saving, or written in when the page names none, and is saved in the <code>#pageAuthor</code> label of the note. When the page states when it was published, that date shows under the author, marked by the <span class=\"tn-icon bx bx-calendar\"></span> icon, and is saved in the <code>#publishedDate</code> label of the note. When it states when it was last modified, that date shows below, marked by the <span class=\"tn-icon bx bx-history\"></span> icon, and is saved in the <code>#modifiedDate</code> label.</li><li><em>PDF</em>, when the tab shows a PDF in the browser's viewer: <em>Save PDF to Trilium</em> downloads the PDF and saves it as a file note, which Trilium opens in its&nbsp;<a class=\"reference-link\" href=\"#root/_help_XJGJrpu7F9sh\">PDFs</a> viewer. Only the title and the description can be edited, since a file note has no text of its own for your note. The page's address is saved in the note's <code>#pageUrl</code> label and the PDF's file name in <code>#originalFileName</code>. Saving a PDF needs Trilium v0.107.0 or later.</li><li><em>Bookmark</em>, always: there is no preview, and <em>Save bookmark</em> saves a link to the page with your note as the content of the note. Left empty, the title stays the page's title.</li></ul><p>The box for your note, marked by the <span class=\"tn-icon bx bx-info-circle\"></span> icon, has the cursor when the popup opens, so a note (such as why the page is worth keeping) can be typed right away. It grows with its text, and keeps it when switching between <em>Selection</em>, <em>Page</em> and <em>Bookmark</em>. A note on a selection or a page is saved above the clipped content, in a <em>Note</em> admonition. Left empty, nothing is added. <kbd>Ctrl</kbd>+<kbd>Enter</kbd> in any of the popup's fields saves, whichever is chosen.</p><p>The description, marked by the <span class=\"tn-icon bx bx-align-left\"></span> icon, comes from the page's <code>description</code> meta tag, or the one it gives social sites. It can be edited or cleared before saving, or written in when the page has none, and is saved in the <code>#pageDescription</code> label of the note. Clippings saved with the keyboard shortcuts or the context menu, screenshots and images included, get the description as the page gives it. Each clipping that brings a description updates the label. The description, the author and the dates are shown by clicking the <em>Web clip</em> badge next to the title of the note (see <a class=\"reference-link\" href=\"#root/_help_B5dihXRDksTk\">Note badges</a>).</p><p>The popup opens on the selection if there is one, otherwise on <em>Page</em>, showing the article, or the whole page when the page has no article. On a PDF, it opens on <em>PDF</em>. On a page that shows nothing to save, it opens on <em>Bookmark</em> and says so. The keyboard shortcuts and the context menu still save right away, without a preview: saving the whole page that way saves the article, the whole page when the page has no article, or the PDF when the tab shows one.</p></li><li><p>Pages the extension cannot access (the browser's own pages, the extension stores, and pages that were open before the extension was installed until they are reloaded) cannot be saved or captured, so the popup says so in place of the preview, and only <em>All tabs</em> remains available there.</p></li><li><p>Below the preview, a row of buttons offers the other actions: <em>Area</em> (a screenshot of an area you select), <em>Visible</em> (a screenshot of the visible part of the page), <em>Full page</em> (a screenshot of the whole page) and <em>All tabs</em> (saves the links of every tab in the current window as a list of <a class=\"reference-link\" href=\"#root/_help_UmgZAfcltxkS\">Link Previews</a>, or of plain links when <em>Autogenerate link previews</em> is turned off). Hovering over a button shows its full name and, if it has one, its keyboard shortcut.</p></li><li><p><em>Full page</em> scrolls through the page, takes a screenshot of each part and joins them into one image, then scrolls back to where the page was. The scrollbars are hidden while it does, so they do not appear in the image. Stay on the tab until it is saved: switching to another tab stops the screenshot. A header that stays at the top of the window appears once, at the top of the image, and headings that stick while scrolling appear where they are in the page. Other elements that stay in place while scrolling (such as cookie banners and chat buttons) are left out, while a background that fills the whole window repeats on every screen. In Firefox, the page is captured without scrolling through it, which is faster: such a background then appears only at the top, and images that the page loads only once they are scrolled into view can be missing. A long page is saved as several images, one below the other in the note. A page longer than 100 screens is cut off there, and the message after saving says so. Screenshots keep their full height in Trilium: <em>Resize image</em> (under <em>Automatically compress images</em> in Options → Media) limits only their width.</p></li><li><p>The popup stays open while Trilium saves, which can take a few seconds for a long page or a large PDF, and the other actions wait until it is done. The bar at the top of the popup then says, in green, that the clipping was saved (in place of the notice that the page was already clipped), with <em>Open note</em> to open it in Trilium (and, after <em>All tabs</em>, <em>Close saved tabs</em>), or, in red, why it could not be saved. The same clipping cannot be saved twice by accident: the save button stays disabled until another mode is chosen. <em>Crop</em> is the exception: the popup closes so that an area of the page can be selected, and the notification on the page reports the outcome.</p></li><li><p>If the current page was already clipped, a notice at the top offers to open the note in Trilium.</p></li><li><p>If Trilium cannot be found, the popup explains why instead of showing the actions, with buttons to look for Trilium again and to open the options.</p></li><li><p>The bottom of the popup shows whether the extension is connected to Trilium, as a colored dot (green when connected, amber when the versions are not compatible, red when Trilium was not found) next to a description of the connection, followed by the buttons for the extension's options and for this help page. A button to check the connection again appears next to them when hovering over the bar, and stays visible while Trilium cannot be reached or is not compatible.</p></li></ul><h2>Location of clippings</h2><p>Trilium will save these clippings as a new child note under a \"clipper inbox\" note.</p><p>By default, that's the&nbsp;<a class=\"reference-link\" href=\"#root/_help_l0tKav7yLHGF\">Day Notes</a>&nbsp;but you can override that by setting the <a href=\"#root/_help_zEY4DaJG4YT5\">label</a> <code>clipperInbox</code>, on any other note.</p><p>Further clippings of the same kind from the same page are added to the note created by the first one, even on a later day or after that note was moved out of the clipper inbox. The note stays where it is and is not cloned back into the inbox. A PDF is the exception: each save creates a new file note, since the PDF can have changed since it was last saved.</p><p>The icon of a clipped note shows what was saved:</p><ul><li><span class=\"tn-icon bx bx-paperclip\"></span> a selection, a screenshot or a link from the context menu;</li><li><span class=\"tn-icon bx bx-globe\"></span> a page (<em>Article</em> or <em>Whole page</em>);</li><li><span class=\"tn-icon bx bx-bookmark\"></span> a bookmark;</li><li><span class=\"tn-icon bx bx-window-alt\"></span> the tabs of a window.</li></ul><p>The icon is derived from the note's <code>#clipType</code> label, so setting an <code>#iconClass</code> label on the note replaces it. A saved PDF has the icon of a PDF file, like any other PDF in Trilium.</p><h2>Embedded videos</h2><p>A YouTube video embedded in a clipped page is saved as a <a class=\"reference-link\" href=\"#root/_help_UmgZAfcltxkS\">Link Previews</a> embed, with the video's title and thumbnail. As with a link preview added in the editor, the video plays only when clicked. Other embedded content (such as videos from other websites) is not saved.</p><p>The popup's preview shows each such video as a chip with the YouTube icon and the video's short link, and leaves out the embedded content that will not be saved.</p><h2>Keyboard shortcuts</h2><p>Keyboard shortcuts are available for most functions:</p><ul><li>Save selected text: <kbd>Ctrl</kbd>+<kbd>Shift</kbd>+<kbd>S</kbd> (Mac: <kbd>⌘</kbd>+<kbd>⇧</kbd>+<kbd>S</kbd>)</li><li>Save whole page: <kbd>Alt</kbd>+<kbd>Shift</kbd>+<kbd>S</kbd> (Mac: <kbd>⌥</kbd>+<kbd>⇧</kbd>+<kbd>S</kbd>)</li><li>Save a screenshot of an area: <kbd>Ctrl</kbd>+<kbd>Shift</kbd>+<kbd>E</kbd> (Mac: <kbd>⌘</kbd>+<kbd>⇧</kbd>+<kbd>E</kbd>)</li><li>Save all tabs of the current window: no default shortcut, but one can be assigned as described below.</li><li>Save a screenshot of the whole page: no default shortcut, but one can be assigned as described below.</li></ul><p>To set custom shortcuts, follow the directions for your browser.</p><ul><li><strong>Firefox</strong>: <code>about:addons</code> → Gear icon ⚙️ → Manage extension shortcuts</li><li><strong>Chrome</strong>: <code>chrome://extensions/shortcuts</code></li></ul><aside class=\"admonition note\"><p>On Firefox, the default shortcuts interfere with some browser features. As such, the keyboard combinations will not trigger the Web Clipper action. To fix this, simply change the keyboard shortcut to something that works. The defaults will be adjusted in future versions.</p></aside><h2>Configuration</h2><p>The extension needs to connect to a running Trilium instance. By default, it looks for the desktop application on port 37840 of the local computer. If the desktop application runs on a different port (for example because it was started with the <code>TRILIUM_PORT</code> environment variable), enter that port in the extension's options. The extension checks for Trilium again every minute, or right away when pressing the refresh button at the bottom of its popup.</p><p>It's also possible to configure the <a href=\"#root/_help_WOcw2SLH6tbX\">server</a> address if you don't run the desktop application, or want it to work without the desktop application running.</p><p>To connect to a server, enter its address and your password in the extension's options and press <em>Login to the server instance</em>. If the server uses <a href=\"#root/_help_7DAiwaf8Z7Rz\">multi-factor authentication</a>, also fill in <em>Authentication code</em> with the current code from your authenticator app (or one of your recovery codes); otherwise leave it empty. The password and the code are used only once, to obtain a token for the extension, and are not stored.</p><h3>When a clipping fails</h3><p>After each clipping made with a keyboard shortcut or the context menu, a notification in the corner of the page confirms that it was saved, with a link to open the new note in Trilium. A clipping made from the popup reports in the popup instead, unless the popup was closed before it was saved. If the clipping could not be saved, the message says why instead:</p><ul><li>Trilium was not found: start the desktop application, or check the server address and token in the extension's options.</li><li>The versions of Trilium and the extension are not compatible: update the one the message names.</li><li>Trilium rejected the request: the message includes the reason Trilium gave.</li><li>The popup could not reach the extension's background script, or it gave no answer: close the popup and open it again. If the extension was just updated or reloaded, reload the page as well.</li><li>A PDF could not be saved: Trilium is older than v0.107.0, the website refused to send the PDF again, or the PDF is larger than 100 MB. The extension downloads the PDF with the browser's cookies for that website, so a PDF behind a login can be saved while you are logged in.</li></ul><p>The extension downloads the images of a clipping itself, so that they are stored in Trilium together with the note. If some of them cannot be downloaded (for example because the website refuses the request), the clipping is still saved, and the notification says how many images are missing. Those images keep their address on the original website: Trilium tries to download them once more if <em>Download images automatically</em> is enabled in <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → <em>Media</em>, and otherwise the note shows them from the website for as long as it serves them.</p><p>The notification is shown on the page itself, so it does not appear on pages where extensions cannot run (such as the browser's own settings pages, the extension stores and Firefox's PDF viewer). A clipping saved from the popup on such a page still reports in the popup.</p><h2>Testing development versions</h2><p>Development versions are version pre-release versions, generally meant for testing purposes. These are not available in the Google or Firefox web stores, but can be downloaded from either:</p><ul><li><a href=\"https://github.com/TriliumNext/Trilium/releases\">GitHub Releases</a> by looking for releases starting with <em>Web Clipper.</em></li><li>Artifacts in GitHub Actions, by looking for the <a href=\"https://github.com/TriliumNext/Trilium/actions/workflows/web-clipper.yml\"><em>Deploy web clipper extension</em> workflow</a>. Once a workflow run is selected, the ZIP files are available in the <em>Artifacts</em> section, under the name <code>web-clipper-extension</code>.</li></ul><div class=\"trilium-tabs\"><section class=\"trilium-tab\"><p class=\"trilium-tab-title\"><span class=\"tn-icon bx bxl-chrome\"></span>&nbsp;Chrome</p><div class=\"trilium-tab-panel\"><ol><li>Download <code>trilium-web-clipper-[x.y.z]-chrome.zip</code>.</li><li>Extract the archive.</li><li>In Chrome, navigate to <code>chrome://extensions/</code></li><li>Toggle <em>Developer Mode</em> in top-right of the page.</li><li>Press the <em>Load unpacked</em> button near the header.</li><li>Point to the extracted directory from step (2).</li></ol></div></section><section class=\"trilium-tab\"><p class=\"trilium-tab-title\"><span class=\"tn-icon bx bxl-firefox\"></span>&nbsp;Firefox</p><div class=\"trilium-tab-panel\"><aside class=\"admonition warning\"><p>Firefox prevents installation of unsigned packages in the “retail” version. To be able to install extensions from disk, consider using <em>Firefox Developer Edition</em> or a non-branded version of Firefox (e.g. <em>GNU IceCat</em>).</p><p>One time, go to <code>about:config</code> and change <code>xpinstall.signatures.required</code> to <code>false</code>.</p></aside><ol><li>Navigate to <code>about:addons</code>.</li><li>Select <em>Extensions</em> in the left-side navigation.</li><li>Press the <em>Gear</em> icon on the right of the <em>Manage Your Extensions</em> title.</li><li>Select <em>Install Add-on From File…</em></li><li>Point it to <code>trilium-web-clipper-[x.y.z]-firefox.zip</code>.</li><li>Press the <em>Add</em> button to confirm.</li></ol></div></section></div><h2>Credits</h2><p>Some parts of the code are based on the <a href=\"https://github.com/laurent22/joplin/tree/master/Clipper\">Joplin Notes browser extension</a>.</p>",
"_help_n1lujUxCwipy": "<p>This document outlines the steps required to upgrade Trilium to a new release version.</p><h2>How to Upgrade</h2><p>Trilium does not support built-in automatic upgrades; all updates must be performed manually. The upgrade process varies depending on the installation method:</p><ul><li><a href=\"#root/_help_rWX5eY045zbE\"><strong>Docker Server Installation</strong></a>: Pull the new image and restart the container.</li><li><strong>Other Installations</strong>: Download the latest version from the <a href=\"https://github.com/TriliumNext/Trilium/releases/latest\">release page</a> and replace the existing application files.</li></ul><h2>Database Compatibility and Migration</h2><p>Upon startup, Trilium will automatically migrate the <a href=\"#root/_help_wX4HbRucYSDD\">database</a> to the new version. Note that after migration, older versions of Trilium will be unable to read the database. If you need to revert to a previous version of Trilium and its database, you can restore the <a href=\"#root/_help_ODY7qQn5m2FT\">backup</a> that is created prior to migration.</p><h2>Sync Compatibility</h2><p>The <a href=\"#root/_help_cbkrhQjrkKrh\">synchronization</a> protocol used by Trilium is versioned, requiring all members of the sync cluster to use the same protocol version. Therefore, when upgrading to a new version, you may need to upgrade all instances in the sync cluster. Changes to the sync protocol version are typically indicated on the release page.</p>",
"_help_ODY7qQn5m2FT": "<p>Trilium supports simple backup scheme where it saves copy of the&nbsp;<a class=\"reference-link\" href=\"#root/_help_wX4HbRucYSDD\">Database</a>&nbsp;on these events:</p><ul><li>once a day</li><li>once a week</li><li>once a month</li><li>before DB migration to newer version</li></ul><p>So in total you'll have at most 4 backups from different points in time which should protect you from various problems. These backups are stored by default in <code>backup</code> directory placed in the <a href=\"#root/_help_tAassRL4RSQL\">data directory</a>.</p><p>This is only very basic backup solution, and you're encouraged to add some better backup solution - e.g. backing up the&nbsp;<a class=\"reference-link\" href=\"#root/_help_wX4HbRucYSDD\">Database</a>&nbsp;to cloud / different computer etc.</p><p>Note that&nbsp;<a class=\"reference-link\" href=\"#root/_help_cbkrhQjrkKrh\">Synchronization</a>&nbsp;provides also some backup capabilities by its nature of distributing the data to other computers.</p><h2>Creating a backup</h2><div class=\"trilium-tabs\"><section class=\"trilium-tab\"><p class=\"trilium-tab-title\"><span class=\"tn-icon bx bx-desktop\"></span>&nbsp;On the desktop app &amp; web client</p><div class=\"trilium-tab-panel\"><ol><li>Go to&nbsp;<a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → <em>Backup</em> and press the <em>Backup now</em> button.</li><li>The backup creation process may take a few moments, especially for larger databases. A notification will inform you when the backup is complete.</li><li>The backup will be saved as <code>backup-now</code> in the <em>Existing backups</em> list, where you can download it.</li></ol></div></section><section class=\"trilium-tab\"><p class=\"trilium-tab-title\"><span class=\"tn-icon bx bx-globe\"></span>&nbsp;On the standalone client</p><div class=\"trilium-tab-panel\"><ol><li>Go to&nbsp;<a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → <em>Backup</em> and press the <em>Download backup</em> button.</li><li>You will be prompted to restart the app. Confirm, and the app will restart automatically.</li><li>Set a <em>backup name</em> or <em>password</em> (both optional), then press <em>Continue</em>.</li><li>Press the <em>Generate and download</em> button and wait for the download to complete.</li><li>Once you confirm the download is saved on your device, press <em>Finish</em> to complete</li></ol></div></section></div><h2>Downloading a backup</h2><ul><li><strong>Desktop and web client</strong>: to download an existing backup, navigate to&nbsp;<a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → <em>Backup</em> → <em>Existing backups</em> and select <em>Download</em> (<span class=\"tn-icon bx bx-download\"></span>).</li><li><strong>Standalone client</strong>: automatic backups are not supported in this version. You can manually create and download a backup by going to&nbsp;<a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → <em>Backup</em> → <em>Download backup</em>.</li></ul><h2>Restoring a backup</h2><ul><li><strong>For a new Trilium instance</strong>: When setting up a new Trilium instance, use the <em>Restore from backup</em> option in the setup menu to guide you through restoring your existing backup.</li><li><strong>For an existing Trilium instance</strong>: To restore a backup and replace your current database, go to&nbsp;<a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → <em>Backup</em> and click <em>Restore a backup</em>. You will be prompted to restart the app for the restoration process to begin. After restarting, you can choose to back up the existing database before overwriting it. Note: For the web client, use the Start Over feature (&nbsp;<a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → <em>Database</em> → <em>Start over</em> (<span class=\"tn-icon bx bx-reset\"></span>)) to switch to the setup screen and restore a backup.</li></ul><p>Next, select the backup file (.db or .tnbackup) from your device. The web client is optimized for handling large backups and is resilient to unstable network conditions, similar to the desktop application.</p><p>If your database is encrypted, you will be prompted to enter the password used for encrypting the backup file. Without the correct password, decryption and restoration cannot proceed.</p><p>Restoring a backup may take some time, depending on its size. Once it completes, Trilium will open the freshly restored database.</p><h3>The alternative way for restoring a backup</h3><p>Let's assume you want to restore the weekly backup (only in .db format, .tnbackup files are not supported by this method), here's how to do it:</p><ul><li>find <a href=\"#root/_help_tAassRL4RSQL\">data directory</a> Trilium uses - easy way is to open \"About Trilium Notes\" (<span class=\"tn-icon bx bx-info-circle\"></span>) from \"Menu\" in upper left corner and looking at \"data directory\"<ul><li>I'll refer to <code>~/trilium-data</code> as data directory from now on</li></ul></li><li>find <code>~/trilium-data/backup/backup-weekly.db</code> - this is the&nbsp;<a class=\"reference-link\" href=\"#root/_help_wX4HbRucYSDD\">Database</a>&nbsp;backup.</li><li>at this point stop/kill Trilium</li><li>delete <code>~/trilium-data/document.db</code>, <code>~/trilium-data/document.db-wal</code> and <code>~/trilium-data/document.db-shm</code> (latter two files are auto generated)</li><li>copy and rename this <code>~/trilium-data/backup/backup-weekly.db</code> to <code>~/trilium-data/document.db</code></li><li>make sure that the file is writable, e.g. with <code>chmod 600 document.db</code></li><li>start Trilium again</li></ul><aside class=\"admonition warning\"><p>If you have configured sync then you need to do it across all members of the sync cluster, otherwise older version (restored backup) of the document will be detected and synced to the newer version.</p></aside><h2>Changing the backup location in Trilium (desktop only)</h2><p>Starting with version 0.105, the Trilium desktop client allows users to change the directory where backups are stored. Follow these steps to specify a custom backup directory:</p><ol><li>Navigate to&nbsp;<a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → <em>Backup</em> → <em>Backup location</em>.</li><li>Click the <em>Select location</em> button.</li><li>Choose any writable directory on your file system. This could include network shares, depending on your operating system.</li></ol><p>Once you set a custom directory, all manual and automatic backups will be saved there. If the selected directory becomes unavailable, backups may fail or revert to the default location.</p><aside class=\"admonition tip\"><p>For better privacy when using unsafe backup locations, you can enable backup encryption, which makes the backup file unreadable without the correct password.</p></aside><h2>Backup encryption</h2><p>Trilium can secure the entire content of the database backup, ensuring it remains unreadable unless the correct password is provided. This is particularly useful for storing backups in unsecured locations, like network shares, unencrypted external drives, or cloud services.&nbsp;</p><p>Encrypted database backups use the Trilium Backup Container (.tnbackup) format, which relies on AES-256-GCM. This authenticated encryption mode scrambles the data and generates a tag confirming it hasn't been altered. The password itself isn't directly used as the key; it's processed through scrypt, a key derivation function designed to be slow and memory-intensive, making brute-force password guessing difficult even with powerful hardware. Each backup also receives a random 16-byte salt, ensuring that the same password never produces the same encryption key twice. Additionally, critical metadata such as chunk order, length, and header flags are cryptographically bound into the encryption (via \"additional authenticated data\"), preventing undetected tampering like reorder, truncate, or splice operations.</p><h3>Enabling backup encryption</h3><p>To enable encryption for automatic backups in the Desktop application:</p><ol><li>Go to&nbsp;<a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → <em>Backup</em> → <em>Backup options</em>.</li><li>Click on <em>Turn on encryption</em> and set a password.</li></ol><p>Once encryption is enabled, all newly created backups (both automatic and manual) will be encrypted with the specified password. Backups created prior to enabling encryption will remain unsecured.</p><p>You can change the password anytime using the <em>Change password</em> button. The new password will apply to backups created after the change.</p><p>To disable encryption, uncheck&nbsp;<a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → <em>Backup</em> → <em>Enable encryption</em>.</p><aside class=\"admonition note\"><p>On some systems, a keyring may not be available for Trilium to securely store the encryption password. In such cases, the encryption option is disabled.</p></aside><h2>Backup compression</h2><p>Database backups can be optionally compressed to minimize storage footprint. This method is effective primarily when the database consists largely of text content. However, media files (images, videos, audio), along with PDF, ODF, and DOCX files, are already compressed in their original formats and won't benefit from further compression.</p><p>Compressed backups are stored using the Trilium Backup Container (.tnbackup), employing RFC 1952 GZIP compression.</p><aside class=\"admonition warning\"><p><strong>Note:</strong> Compression increases the time required for backup creation and restoration. It may also lead to higher CPU usage during automatic backups, potentially draining the battery faster on battery-powered devices. Enable this option only if necessary.</p></aside><h3>Enabling Backup Compression (Desktop Only)</h3><p>To enable compression for new automatic and manual backups, navigate to&nbsp;<a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → <em>Backup</em> → <em>Backup options</em> and toggle <em>Enable compression</em> to on.</p><h2>Disabling backup</h2><p>Although this is not recommended, it is possible to disable backup in <code>config.ini</code> in the <a href=\"#root/_help_tAassRL4RSQL\">data directory</a>:</p><pre><code class=\"language-text-x-trilium-auto\">[General]\n... some other configs\n# set to true to disable backups (e.g. because of limited space on server)\nnoBackup=true</code></pre><p>You can also review the <a href=\"#root/_help_Gzjqa934BdH4\">configuration</a> file to provide all <code>config.ini</code> values as environment variables instead.</p><p>See <a href=\"https://github.com/TriliumNext/Trilium/blob/master/config-sample.ini\">sample config</a>.</p>",
@@ -146,7 +146,7 @@
"_help_S6Xx8QIWTV66": "<p>There are three types of lists supported by text notes:</p><ul><li><span class=\"tn-icon cke cke-bulleted-list\"></span>&nbsp;Bulleted lists (also known as unordered lists).</li><li><span class=\"tn-icon cke cke-numbered-list\"></span>&nbsp;Numbered lists (or ordered lists).</li><li><span class=\"tn-icon cke cke-todo-list\"></span>&nbsp;To-do lists</li></ul><p>For bulleted and numbered lists, it's possible to configure an alternative marker such as squares or Roman numbering by pressing the&nbsp;<span class=\"tn-icon cke cke-dropdown-arrow\"></span> icon. For numbered lists, it's also possible to specify the number to start at or whether to count in reverse order.</p><h2>Keyboard interaction</h2><ul><li>To create a new list:<ul><li>Bulleted list: Start a line with <code>*</code> or <code>-</code> followed by a space;</li><li>Numbered list: Start a line with <code>1.</code> or <code>1)</code> followed by a space;</li><li>To-do list: Start a line with <code>- [ ]</code> for an unchecked item or <code>[x]</code> for a checked item.</li></ul></li><li>To create a new item in the list, press <kbd>Enter</kbd>.</li><li>To create a blank line within a list item, press <kbd>Shift</kbd>+<kbd>Enter</kbd>.</li><li>To exit out of the list, press <kbd>Enter</kbd> twice.</li><li>To merge two lists, simply delete the gap between them.</li><li>To create nested lists, simply use the&nbsp;<span class=\"tn-icon cke cke-indent\"></span> button (see <em>Indentation</em> in&nbsp;<a class=\"reference-link\" href=\"#root/_help_dEHYtoWWi8ct\">Other features</a>) or the <kbd>Tab</kbd> key. To decrease the nesting level for the current element, press <kbd>Shift</kbd>+<kbd>Tab</kbd>.</li></ul><h2>Headings, code blocks within lists</h2><p>It possible to add content-level blocks such as headings, code blocks, tables within lists, as follows:</p><figure class=\"table\"><table><tbody><tr><td>1</td><td><img src=\"{{helpAssets}}/User%20Guide/Note%20Types/Text/2_Lists_image.jpg\"></td><td>First, create a list.</td></tr><tr><td>2</td><td><img src=\"{{helpAssets}}/User%20Guide/Note%20Types/Text/4_Lists_image.jpg\"></td><td>Press Enter to create a new list item.</td></tr><tr><td>3</td><td><img src=\"{{helpAssets}}/User%20Guide/Note%20Types/Text/1_Lists_image.jpg\"></td><td>Press Backspace to get rid of the bullet point. Notice the cursor position.</td></tr><tr><td>4</td><td><img class=\"image_resized\" style=\"aspect-ratio:676/112;width:98.29%;\" src=\"{{helpAssets}}/User%20Guide/Note%20Types/Text/5_Lists_image.jpg\" width=\"676\" height=\"112\"></td><td>At this point, insert any desired block-level item such as a code block.</td></tr><tr><td>5</td><td><img class=\"image_resized\" style=\"aspect-ratio:675/129;width:94.22%;\" src=\"{{helpAssets}}/User%20Guide/Note%20Types/Text/3_Lists_image.jpg\" width=\"675\" height=\"129\"></td><td>To continue with a new bullet point, press Enter until the cursor moves to a new blank position.</td></tr><tr><td>6</td><td><img class=\"image_resized\" style=\"aspect-ratio:675/129;width:100%;\" src=\"{{helpAssets}}/User%20Guide/Note%20Types/Text/Lists_image.jpg\" width=\"675\" height=\"129\"></td><td>Press Enter once more to create the new bullet.</td></tr></tbody></table></figure><p>The same principle applies to all three list types (bullet, numbered and to-do).</p><h2>To-do lists</h2><p>See&nbsp;<a class=\"reference-link\" href=\"#root/_help_fASfBrYnquKU\">To-do Lists</a>.</p><h2>Collapsible lists</h2><p>Starting with Trilium v0.104.0, it is possible to collapse nested list items. This applies to bullet lists, numbered lists as well as to-do lists.</p><p>To collapse or expand a list item that has nested sub-items:</p><ul><li>Using the mouse, move the cursor over the list item and an arrow will appear to its left. Clicking it will toggle between collapsed and expanded.</li><li>For bullet lists and numbered lists, it's also possible to click directly on the marker (e.g. the bullet or the number) instead of on the arrow to collapse or expand it. This won't work for to-do lists since this would toggle the to-do instead.</li><li>Press <kbd>Ctrl</kbd>+<kbd>Alt</kbd>+<kbd>Enter</kbd> which will toggle the collapse/expand state for the item at the cursor position.</li></ul><p>Of note:</p><ul><li>Collapsed items always show the arrow to indicate its state.</li><li>The collapsed state is saved at note level and synced across instances, which means that it will restore after a refresh or reopening of the application.</li><li>The collapsed state is also persisted in&nbsp;<a class=\"reference-link\" href=\"#root/_help_mHbBMPDPkVV5\">Import &amp; Export</a>, but only for the HTML format. Markdown exports will not preserve the collapse state.</li><li>Collapsible bullets only exist in the context of editable text notes. Read-only lists will always be fully expanded.</li><li>The list items will auto-expand on edit to avoid typing in a hidden area.</li></ul>",
"_help_QrtTYPmdd1qq": "<p>Markdown-like formatting allows inserting some basic formatting by typing the Markdown equivalent. Note that this does not mean that&nbsp;<a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a>&nbsp;notes supports Markdown, these are just some convenience shortcuts.</p><p>To import more complex formatting into text notes, consider using the <a href=\"#root/_help_dEHYtoWWi8ct\"><em>Import from Markdown</em></a> function. For fully-fleged Markdown notes imports, consider using the dedicated <a href=\"#root/_help_Oau6X9rCuegd\">import</a> function.</p><ul><li>For <a href=\"#root/_help_Gr6xFaF6ioJ5\">headings:</a><ul><li><code>##</code> for Heading 2 (the first-level heading is reserved for the note title).</li><li><code>###</code> for Heading 3</li><li><code>####</code> for Heading 4</li><li><code>#####</code> for Heading 5</li><li><code>######</code> for Heading 6</li></ul></li><li>For&nbsp;<a class=\"reference-link\" href=\"#root/_help_Gr6xFaF6ioJ5\">General formatting</a>:<ul><li><strong>Bold</strong>: Type <code>**text**</code> or <code>__text__</code></li><li><em>Italic</em>: Type <code>*text*</code> or <code>_text_</code></li><li><del>Strikethrough</del>: Type <code>~~text~~</code></li></ul></li><li>For&nbsp;<a class=\"reference-link\" href=\"#root/_help_S6Xx8QIWTV66\">Lists</a>:<ul><li>Bulleted list: Start a line with <code>*</code> or <code>-</code> followed by a space;</li><li>Numbered list: Start a line with <code>1.</code> or <code>1)</code> followed by a space;</li><li>To-do list: Start a line with <code>[ ]</code> for an unchecked item or <code>[x]</code> for a checked item.</li></ul></li><li>For <a href=\"#root/_help_NwBbFdNZ9h7O\">block quotes</a>, press <code>&gt;</code>, followed by a space.</li><li>For&nbsp;<a class=\"reference-link\" href=\"#root/_help_QxEyIjRBizuC\">Code blocks</a>, type <code>```</code>.</li><li>For a <a href=\"#root/_help_dEHYtoWWi8ct\">horizontal line</a>, type <code>---</code>.</li><li>For <a href=\"#root/_help_NwBbFdNZ9h7O\">admonitions</a>:<ul><li><code>!!! note</code></li><li><code>!!! tip</code></li><li><code>!!! important</code></li><li><code>!!! caution</code></li><li><code>!!! warning</code></li><li>Starting any other text with <code>!!!</code> will insert a note admonition with the text inside of it.</li></ul></li><li>For <a href=\"#root/_help_CohkqWQC1iBv\">emojis</a>, type <code>:</code> followed by an emoji name to trigger an auto-completion.</li></ul><p>If auto-formatting is not desirable, press <kbd>Ctrl</kbd> + <kbd>Z</kbd> to revert the text to its original form.</p>",
"_help_YfYAtQBcfo5V": "<figure class=\"image image-style-align-right\"><img style=\"aspect-ratio:350/193;\" src=\"{{helpAssets}}/User%20Guide/Note%20Types/Text/Math%20Equations_image.png\" width=\"350\" height=\"193\"></figure><p>Within text notes, it's possible to enter mathematical equations using the&nbsp;<span class=\"tn-icon cke cke-trilium-math\"></span> button from the&nbsp;<a class=\"reference-link\" href=\"#root/_help_nRhnJkTT8cPs\">Formatting toolbar</a>&nbsp;(generally found under the&nbsp;<a class=\"reference-link\" href=\"#root/_help_CohkqWQC1iBv\">Insert buttons</a>).</p><p>By default, the math dialog includes a MathLive visual editor and a TeX field. Disable <em>MathLive visual editor</em> under Options → Text Notes → Features to use only the TeX field and preview.</p><p>Enabling <em>Display mode</em> will render the equation slightly bigger (especially if using big operators such as summation, or fractions) and center it. Display mode equations will act as blocks (i.e. like paragraphs, or tables) and can be inserted for example in lists. Non-display equations can be part of the text.</p><h2>Keyboard shortcuts</h2><p>If inserting equations frequently, using the <kbd>Ctrl</kbd>+<kbd>M</kbd> keyboard shortcut can be more comfortable. Alternatively, type <code>$$</code> or <code>\\[</code> to trigger the popup directly.</p><p>There is currently no quick way to turn an already typed-out equation, such as surrounding it with <code>$</code> or pressing <kbd>Ctrl</kbd>+<kbd>M</kbd>.</p><h2>Supported math features</h2><p>Technically we are using the KaTeX library which allows for a subset of the TeX format. To see the full list of supported features, consult the <a href=\"https://katex.org/docs/supported\">Supported Functions</a> and the <a href=\"https://katex.org/docs/support_table\">Support Table</a> from the official documentation.</p><h2>Markdown support</h2><p>Math equations will be preserved when exporting to or importing from Markdown, surrounded by <code>$</code> characters for inline math expressions, and <code>$$</code> for display mode.</p><p>If you notice any issue with the Markdown import/export for equations, feel free to <a href=\"#root/_help_wy8So3yZZlH9\">report</a> it while providing the equation that causes issues.</p><h2>Formatting the equation</h2><p>It is possible to customize the font size and foreground color for both inline and display-mode equations, just like any other text. For inline equations, the background color/highlight can also be adjusted.</p>",
- "_help_wYDzQ1fBFgfT": "<p>A multicolumn layout arranges content in two to four columns, side by side. A column can hold any kind of content, including tables, images and another multicolumn layout.</p><h2>Inserting a layout</h2><ul><li>In the formatting bar, go to <em>Insert</em> → <span class=\"tn-icon cke cke-trilium-multicolumn\"></span> <em>Multiple column layout</em> to insert a layout with two columns. Its submenu offers <em>2 columns</em>, <em>3 columns</em> and <em>4 columns</em>.</li><li>Alternatively, type <code>/columns</code> and choose <em>2 columns layout</em>, <em>3 columns layout</em> or <em>4 columns layout</em>, as described in&nbsp;<a class=\"reference-link\" href=\"#root/_help_ZlN4nump6EbW\">Slash Commands</a>.</li></ul><p>The columns of a new layout have equal widths. If text is selected when the layout is inserted, the selection moves into the first column.</p><h2>Changing the columns</h2><h3>Changing the layout</h3><p>While the cursor is inside a layout, a toolbar appears above it with a button that shows the current layout. Clicking it opens a row of figures, one for each available layout; hovering over a figure shows its number of columns and their widths:</p><figure class=\"table\"><table><thead><tr><th>Columns</th><th>Widths</th></tr></thead><tbody><tr><td>2</td><td>50%-50%, 25%-75%, 75%-25%</td></tr><tr><td>3</td><td>33%-33%-33%, 25%-50%-25%</td></tr><tr><td>4</td><td>25%-25%-25%-25%</td></tr></tbody></table></figure><ul><li>Choosing a layout with more columns adds empty columns at the end.</li><li>Choosing a layout with fewer columns removes the last columns and moves their content to the end of the last remaining column.</li></ul><h3>Adding columns</h3><p>While the cursor is in a column, you can use these key combinations:</p><ul><li><kbd>Ctrl</kbd> + <kbd>Enter</kbd>: Add a column after the current one.</li><li><kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>Enter</kbd>: Add a column before the current one.</li></ul><p>The new column is empty and the cursor moves into it. All the columns then have equal widths. A layout has at most four columns, so the keys do nothing in a layout that already has four.</p><p><kbd>Ctrl</kbd> + <kbd>Enter</kbd> keeps its usual function on a link, in a to-do item and in the title of a collapsible block, and <kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>Enter</kbd> in a to-do item.</p><h3>Reordering columns</h3><p>While the cursor is anywhere inside a column, you can use these key combinations:</p><ul><li><kbd>Ctrl</kbd> + <kbd>Alt</kbd> + <kbd>Right</kbd>: Move the column to the right.</li><li><kbd>Ctrl</kbd> + <kbd>Alt</kbd> + <kbd>Left</kbd>: Move the column to the left.</li><li><kbd>Ctrl</kbd> + <kbd>Alt</kbd> + <kbd>Home</kbd>: Make it the first column.</li><li><kbd>Ctrl</kbd> + <kbd>Alt</kbd> + <kbd>End</kbd>: Make it the last column.</li></ul><p>In a layout with two columns of different widths, the column keeps its width.</p><h2>Moving content between columns</h2><p>To move content to another column, select it, and then use these key combinations:</p><ul><li><kbd>Ctrl</kbd> + <kbd>Right</kbd>: Move to the column on the right.</li><li><kbd>Ctrl</kbd> + <kbd>Left</kbd>: Move to the column on the left.</li><li><kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>End</kbd>: Move to the last column.</li><li><kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>Home</kbd>: Move to the first column.</li></ul><p>Paragraphs, list items, tables and other blocks move whole, even when only part of them is selected. Content moved to a column on the left goes to the end of that column, and content moved to a column on the right goes to its start, so it keeps its place in the reading order.</p><p>Without a selection, these keys keep their usual function: moving the cursor by word, or selecting up to the start or end of the column.</p><p>When a layout and <a class=\"reference-link\" href=\"#root/_help_EK2ckIZ74tbT\">Content tabs</a> are nested in one another, the key combinations act on the one closest to the cursor.</p><h2>Removing a layout</h2><ul><li>To remove the layout but keep its content, click the <span class=\"tn-icon cke cke-remove\"></span> <em>Remove layout</em> button in the layout's toolbar. The content of the columns is placed one after another where the layout was, and empty columns are left out.</li><li>To delete the layout together with its content, click the handle at its top-left corner to select it, then press <kbd>Delete</kbd>.</li></ul><h2>Narrow screens</h2><p>When a layout has too little room for its columns (narrower than about 500 pixels, such as on a phone), the columns are stacked one below the other. While editing, alternating background colors tell the columns apart. This applies to each layout on its own, so a layout inside a narrow column is stacked while the outer one stays side by side.</p><h2>Printing and exporting</h2><ul><li>When printing or <a href=\"#root/_help_NRnIZmSMc5sj\">exporting to PDF</a>, the columns are printed side by side.</li><li>Markdown has no columns, so Markdown export keeps the layout and each column as HTML <code>&lt;div&gt;</code> tags, with the content of each column written as Markdown between them. Importing the file back restores the layout. Markdown viewers that don't support HTML show the content of the columns one after another.</li></ul>",
+ "_help_wYDzQ1fBFgfT": "<p>A multicolumn layout arranges content in two to four columns, side by side. A column can hold any kind of content, including tables, images and another multicolumn layout.</p><h2>Inserting a layout</h2><ul><li>In the formatting bar, go to <em>Insert</em> → <span class=\"tn-icon cke cke-trilium-multicolumn\"></span> <em>Columns</em> to insert a layout with two columns. Its submenu offers <em>2 columns</em>, <em>3 columns</em> and <em>4 columns</em>.</li><li>Alternatively, type <code>/columns</code> and choose <em>2 columns layout</em>, <em>3 columns layout</em> or <em>4 columns layout</em>, as described in&nbsp;<a class=\"reference-link\" href=\"#root/_help_ZlN4nump6EbW\">Slash Commands</a>.</li></ul><p>The columns of a new layout have equal widths. If text is selected when the layout is inserted, the selection moves into the first column.</p><h2>Changing the columns</h2><h3>Changing the layout</h3><p>While the cursor is inside a layout, a toolbar appears above it with a button that shows the current layout. Clicking it opens a row of figures, one for each available layout; hovering over a figure shows its number of columns and their widths:</p><figure class=\"table\"><table><thead><tr><th>Columns</th><th>Widths</th></tr></thead><tbody><tr><td>2</td><td>50%-50%, 25%-75%, 75%-25%</td></tr><tr><td>3</td><td>33%-33%-33%, 25%-50%-25%</td></tr><tr><td>4</td><td>25%-25%-25%-25%</td></tr></tbody></table></figure><ul><li>Choosing a layout with more columns adds empty columns at the end.</li><li>Choosing a layout with fewer columns removes the last columns and moves their content to the end of the last remaining column.</li></ul><h3>Adding columns</h3><p>While the cursor is in a column, you can use these key combinations:</p><ul><li><kbd>Ctrl</kbd> + <kbd>Enter</kbd>: Add a column after the current one.</li><li><kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>Enter</kbd>: Add a column before the current one.</li></ul><p>The new column is empty and the cursor moves into it. All the columns then have equal widths. A layout has at most four columns, so the keys do nothing in a layout that already has four.</p><p><kbd>Ctrl</kbd> + <kbd>Enter</kbd> keeps its usual function on a link, in a to-do item and in the title of a collapsible block, and <kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>Enter</kbd> in a to-do item.</p><h3>Reordering columns</h3><p>While the cursor is anywhere inside a column, you can use these key combinations:</p><ul><li><kbd>Ctrl</kbd> + <kbd>Alt</kbd> + <kbd>Right</kbd>: Move the column to the right.</li><li><kbd>Ctrl</kbd> + <kbd>Alt</kbd> + <kbd>Left</kbd>: Move the column to the left.</li><li><kbd>Ctrl</kbd> + <kbd>Alt</kbd> + <kbd>Home</kbd>: Make it the first column.</li><li><kbd>Ctrl</kbd> + <kbd>Alt</kbd> + <kbd>End</kbd>: Make it the last column.</li></ul><p>In a layout with two columns of different widths, the column keeps its width.</p><h2>Moving content between columns</h2><p>To move content to another column, select it, and then use these key combinations:</p><ul><li><kbd>Ctrl</kbd> + <kbd>Right</kbd>: Move to the column on the right.</li><li><kbd>Ctrl</kbd> + <kbd>Left</kbd>: Move to the column on the left.</li><li><kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>End</kbd>: Move to the last column.</li><li><kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>Home</kbd>: Move to the first column.</li></ul><p>Paragraphs, list items, tables and other blocks move whole, even when only part of them is selected. Content moved to a column on the left goes to the end of that column, and content moved to a column on the right goes to its start, so it keeps its place in the reading order.</p><p>Without a selection, these keys keep their usual function: moving the cursor by word, or selecting up to the start or end of the column.</p><p>When a layout and <a class=\"reference-link\" href=\"#root/_help_EK2ckIZ74tbT\">Content tabs</a> are nested in one another, the key combinations act on the one closest to the cursor.</p><h2>Removing a layout</h2><ul><li>To remove the layout but keep its content, click the <span class=\"tn-icon cke cke-remove\"></span> <em>Remove layout</em> button in the layout's toolbar. The content of the columns is placed one after another where the layout was, and empty columns are left out.</li><li>To delete the layout together with its content, click the handle at its top-left corner to select it, then press <kbd>Delete</kbd>.</li></ul><h2>Narrow screens</h2><p>When a layout has too little room for its columns (narrower than about 500 pixels, such as on a phone), the columns are stacked one below the other. While editing, alternating background colors tell the columns apart. This applies to each layout on its own, so a layout inside a narrow column is stacked while the outer one stays side by side.</p><h2>Printing and exporting</h2><ul><li>When printing or <a href=\"#root/_help_NRnIZmSMc5sj\">exporting to PDF</a>, the columns are printed side by side.</li><li>Markdown has no columns, so Markdown export keeps the layout and each column as HTML <code>&lt;div&gt;</code> tags, with the content of each column written as Markdown between them. Importing the file back restores the layout. Markdown viewers that don't support HTML show the content of the columns one after another.</li></ul>",
"_help_dEHYtoWWi8ct": "<h2>Indentation</h2><figure class=\"image image-style-align-right\"><img style=\"aspect-ratio:201/124;\" src=\"{{helpAssets}}/User%20Guide/Note%20Types/Text/1_Other%20features_image.png\" width=\"201\" height=\"124\"></figure><p>Paragraphs can be indented using the following buttons from the&nbsp;<a class=\"reference-link\" href=\"#root/_help_nRhnJkTT8cPs\">Formatting toolbar</a>:</p><ul><li>Press&nbsp;<span class=\"tn-icon cke cke-indent\"></span> to increase the indentation of the current paragraph by one. Can be pressed multiple times if needed.</li><li>Press&nbsp;<span class=\"tn-icon cke cke-outdent\"></span> to decrease the indentation of a current paragraph. The button will be disabled if it is already at the minimum indentation level.</li><li>For convenience, keyboard shortcuts are also available. Press <kbd>Tab</kbd> to indent or <kbd>Shift</kbd>+<kbd>Tab</kbd> to decrease the indentation. These shortcuts work even if the cursor is not at the beginning of a paragraph or a list.</li><li>Apart from paragraphs, the indent button is also enabled in&nbsp;<a class=\"reference-link\" href=\"#root/_help_S6Xx8QIWTV66\">Lists</a>&nbsp;(for nesting) and&nbsp;<a class=\"reference-link\" href=\"#root/_help_NdowYOC1GFKS\">Tables</a>.</li></ul><p>When indented paragraphs or headings are copied and pasted as plain text, for example into a <a class=\"reference-link\" href=\"#root/_help_6f9hih2hXXZk\">Code</a> note or another application, each indentation level becomes a tab at the start of the line. A copy that stays within a single paragraph contains only its text, without the indentation.</p><p>The reverse also works: when plain text is pasted into a text note, each paragraph whose lines all start with tabs is indented by one level per tab. Pasting into a code block keeps the tabs as they are.</p><h2>Markdown import</h2><p>If the clipboard contains Markdown text, it can be easily imported into text notes. Simply copy a Markdown-formatted text and press the&nbsp;<span class=\"tn-icon cke cke-trilium-markdown-mark\"></span> to insert its visual representation.</p><p>Note that this only works with raw Markdown (e.g. <code># Heading 1</code> to generate a heading) and not the visual representation of the Markdown (e.g. as in the preview pane of an application). In that case, simply use the paste function which already accepts HTML-formatted content.</p><p>This is mostly useful for snippets of text, for entire Markdown documents use the dedicated&nbsp;<a class=\"reference-link\" href=\"#root/_help_Oau6X9rCuegd\">Markdown</a>&nbsp;import/export function.</p><p>If accessing Trilium with a web browser, the Markdown import action will ask for the content to be inserted into a dedicated screen since it does not have access to the clipboard.</p><h2>Cut to subnote</h2><p>The&nbsp;<span class=\"tn-icon cke cke-trilium-scissors\"></span> button will create a child note with the selected text. For more information, see&nbsp;<a class=\"reference-link\" href=\"#root/_help_2x0ZAX9ePtzV\">Cut to subnote</a>.</p><h2>Find and replace</h2><figure class=\"image image-style-align-right\"><img style=\"aspect-ratio:394/203;\" src=\"{{helpAssets}}/User%20Guide/Note%20Types/Text/Other%20features_image.png\" width=\"394\" height=\"203\"></figure><p>The&nbsp;<span class=\"tn-icon cke cke-find-replace\"></span> button will open the editor's dedicated search and replace functionality.</p><p>Alternatively, the <kbd>Ctrl</kbd>+<kbd>F</kbd> combination can be pressed to show the dialog.</p>",
"_help_gLt3vA97tMcp": "<p>The text editor we are using is called&nbsp;<a class=\"reference-link\" href=\"#root/_help_MI26XDLSAlCD\">CKEditor</a>&nbsp;which has an open-source core, but it's also a commercial product which offers <a href=\"https://ckeditor.com/docs/trial/latest/index.html\">premium features</a>.</p><p>Prior to v0.105.0, Trilium used the following premium features as part of a signed agreement between the CKEditor and the Trilium team:</p><ul><li><a class=\"reference-link\" href=\"#root/_help_ZlN4nump6EbW\">Slash Commands</a></li><li><a class=\"reference-link\" href=\"#root/_help_pwc194wlRzcH\">Text Snippets</a></li><li><a class=\"reference-link\" href=\"#root/_help_5wZallV2Qo1t\">Format Painter</a></li></ul><p>Starting with v0.105.0, those features have been completely rewritten as custom CKEditor plugins, licensed under AGPL-3.0.</p><h2>Lookalikes</h2><p>There are some premium CK features that look like Trilium's built-in functionality but they are completely different:</p><ul><li><a class=\"reference-link\" href=\"#root/_help_VRoP0g1uHHc2\">In-editor AI assistant</a></li><li><a class=\"reference-link\" href=\"#root/_help_YfYAtQBcfo5V\">Math Equations</a>&nbsp;which uses a third-party plugin that has been adapted for Trilium.</li></ul>",
"_help_ZlN4nump6EbW": "<figure class=\"image image-style-align-right\"><img style=\"aspect-ratio:419/571;\" src=\"{{helpAssets}}/User%20Guide/Note%20Types/Text/Slash%20Commands_image.png\" width=\"419\" height=\"571\"></figure><p>Slash commands is a feature of&nbsp;<a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a>&nbsp;notes which allows easily accessing commonly used commands simply by using the keyboard, without having to remember dedicated&nbsp;<a class=\"reference-link\" href=\"#root/_help_A9Oc6YKKc65v\">Keyboard Shortcuts</a>.</p><h2>Interaction</h2><ul><li>As the name suggests, to trigger the slash commands simply press the / key to trigger it. Note that this can be anywhere in a paragraph as long as it's not part of the word, if it doesn't show up simply press a space and press the / key again.</li><li>Use ↑ and ↓ keys to navigate between options.</li><li>By default, the full list of commands is displayed.</li><li>To search, simply start typing: commands are found by their title or by other names they go by (for example <code>h2</code> for <em>Heading 2</em>).</li><li>To trigger the highlighted action, press Enter or Tab.</li></ul><h2>Integration with other features</h2><p>Apart from the common set of commands, some features are specially integrated with the slash commands:</p><ul><li>For <a href=\"#root/_help_NwBbFdNZ9h7O\">admonitions</a>, each admonition type (e.g. note, tip) will be individually displayed.</li><li>Every&nbsp;<a class=\"reference-link\" href=\"#root/_help_pwc194wlRzcH\">Text Snippets</a>&nbsp;will also appear individually, making it easy to insert them.</li><li><a class=\"reference-link\" href=\"#root/_help_VRoP0g1uHHc2\">In-editor AI assistant</a>: dedicated <em>Ask AI</em> item as well as all the predefined and <a href=\"#root/_help_mVEYwt20exhO\">custom quick actions</a>.</li></ul>",
diff --git a/docs/User Guide/User Guide/Installation & Setup/Mobile Frontend.md b/docs/User Guide/User Guide/Installation & Setup/Mobile Frontend.md
index 2a0a2e0898..0fe81f7b77 100644
--- a/docs/User Guide/User Guide/Installation & Setup/Mobile Frontend.md
+++ b/docs/User Guide/User Guide/Installation & Setup/Mobile Frontend.md
@@ -20,7 +20,7 @@ Here is a non-exhaustive list of differences between the desktop version and the
* The <a class="reference-link" href="../Basic%20Concepts%20and%20Features/UI%20Elements/Launch%20Bar.md">Launch Bar</a> is displayed at the bottom of the screen.
* The launch bar uses a different configuration for icons than the desktop version. See the dedicated page for more information on how to configure it.
* Most of the note-related actions are grouped in the horizontal dots icon on the top-right of the note.
-* In a text note, the formatting toolbar sits at the bottom of the screen as a single row that scrolls sideways. It is shown only while you are editing the text, and hides when you hide the keyboard or move to another field, such as the note title. It starts with _Undo_ and _Redo_, since the on-screen keyboard has no keys for them. The <span class="tn-icon cke cke-plus"></span> button after them opens a menu of the less common insertions: collapsible, tabs, columns, horizontal line, page break, math, drawing canvas, Mermaid diagram, footnote, bookmark, link and content embeds, date/time, special characters, emoji, icon, template and Markdown import. The block type button shows the type of the current block as an icon rather than its name, and opens the block types as tiles at the bottom of the screen, with the current one highlighted: paragraph and heading 2 to 6, then bulleted list, numbered list and to-do list, then code block, block quote and admonition. Picking a paragraph or a heading in a list turns the item back into plain text, and the same goes for a code block. Block quote and admonition wrap the current block rather than replace it, so they are highlighted alongside it; pick one again to remove it. Typing `-` , `1.` or `[ ]` at the start of a line also starts a list. The style of a list (such as roman numerals) and its start number can only be changed on desktop.
+* In a text note, the formatting toolbar sits at the bottom of the screen as a single row that scrolls sideways. It is shown only while you are editing the text, and hides when you hide the keyboard or move to another field, such as the note title. It starts with _Undo_ and _Redo_, since the on-screen keyboard has no keys for them. The <span class="tn-icon cke cke-plus"></span> button after them opens the less common insertions as tiles at the bottom of the screen: collapsible, tabs, columns, horizontal line, page break, footnote, math, drawing canvas, Mermaid diagram, bookmark, link and content embeds, special characters, emoji, icon, date/time, template and Markdown import. The tiles marked with <span class="tn-icon bx bx-chevron-right"></span>, _Columns_ and _Date/time_, open a list of choices: the number of columns, and the format of the date and time. The block type button shows the type of the current block as an icon rather than its name, and opens the block types as tiles at the bottom of the screen, with the current one highlighted: paragraph and heading 2 to 6, then bulleted list, numbered list and to-do list, then code block, block quote and admonition. Picking a paragraph or a heading in a list turns the item back into plain text, and the same goes for a code block. Block quote and admonition wrap the current block rather than replace it, so they are highlighted alongside it; pick one again to remove it. Typing `-` , `1.` or `[ ]` at the start of a line also starts a list. The style of a list (such as roman numerals) and its start number can only be changed on desktop.
* The formatting applied to text (bold, italic, underline, strikethrough, inline code, superscript and subscript, keyboard shortcut, font size and colors, and removing formatting) is on a row of its own. Tap <span class="tn-icon cke cke-text"></span> next to the block type button to show it, and <span class="tn-icon cke cke-previous-arrow"></span> at its start to return to the main row. Selecting text shows this row on its own, and it goes back to the main row once the selection is gone (for example as you start typing), unless you opened or closed the row yourself in the meantime. The font size button opens the list of sizes as a menu at the bottom of the screen, each drawn at its size, with the current one checked. A single color button replaces the separate text and background color buttons: it opens a menu with a row of colors for the text and one for its background, each with a cell that removes the color and one that opens the device's color picker.
* While the on-screen keyboard is open, a <span class="tn-icon bx bxs-keyboard"></span> button in the bottom-right corner, just above the keyboard, hides it. In a text note, the button is at the right end of the formatting toolbar. This works in every note type and in every text field, and is the only way to hide the keyboard in the iOS app, where the keyboard has no _Done_ button.
* The <a class="reference-link" href="../Basic%20Concepts%20and%20Features/UI%20Elements/Tabs.md">Tabs</a> are grouped under a tab switcher in the <a class="reference-link" href="../Basic%20Concepts%20and%20Features/UI%20Elements/Launch%20Bar.md">Launch Bar</a>, where the tabs are displayed in a full-screen grid with preview for easy switching, as well as additional options such as reopening closed tabs.
diff --git a/docs/User Guide/User Guide/Note Types/Text/Multicolumn layout.md b/docs/User Guide/User Guide/Note Types/Text/Multicolumn layout.md
index 47c5cf369f..69cd185da4 100644
--- a/docs/User Guide/User Guide/Note Types/Text/Multicolumn layout.md
+++ b/docs/User Guide/User Guide/Note Types/Text/Multicolumn layout.md
@@ -3,7 +3,7 @@ A multicolumn layout arranges content in two to four columns, side by side. A co
## Inserting a layout
-* In the formatting bar, go to _Insert_ → <span class="tn-icon cke cke-trilium-multicolumn"></span> _Multiple column layout_ to insert a layout with two columns. Its submenu offers _2 columns_, _3 columns_ and _4 columns_.
+* In the formatting bar, go to _Insert_ → <span class="tn-icon cke cke-trilium-multicolumn"></span> _Columns_ to insert a layout with two columns. Its submenu offers _2 columns_, _3 columns_ and _4 columns_.
* Alternatively, type `/columns` and choose _2 columns layout_, _3 columns layout_ or _4 columns layout_, as described in <a class="reference-link" href="Slash%20Commands.md">Slash Commands</a>.
The columns of a new layout have equal widths. If text is selected when the layout is inserted, the selection moves into the first column.
diff --git a/packages/ckeditor5/src/plugins/multicolumn/multicolumn_ui.spec.ts b/packages/ckeditor5/src/plugins/multicolumn/multicolumn_ui.spec.ts
index de7ddeba9c..67b294f66b 100644
--- a/packages/ckeditor5/src/plugins/multicolumn/multicolumn_ui.spec.ts
+++ b/packages/ckeditor5/src/plugins/multicolumn/multicolumn_ui.spec.ts
@@ -79,7 +79,7 @@ describe("MulticolumnUI", () => {
const button = dropdown.buttonView;
expect(button).toBeInstanceOf(SplitButtonView);
expect([button.label, button.icon, button.tooltip])
- .toEqual(["Multiple column layout", multicolumnIcon, true]);
+ .toEqual(["Columns", multicolumnIcon, true]);
expect(dropdown.isEnabled).toBe(true);
const focus = vi.spyOn(editor.editing.view, "focus");
@@ -137,7 +137,7 @@ describe("MulticolumnUI", () => {
setModelData(menuEditor.model, "<paragraph>[]</paragraph>");
const entry = openEntry();
- expect(entry.label).toBe("Multiple column layout");
+ expect(entry.label).toBe("Columns");
expect(entry.children?.map(child => entryOf(child).label))
.toEqual(["2 columns", "3 columns", "4 columns"]);
diff --git a/packages/ckeditor5/src/plugins/multicolumn/multicolumn_ui.ts b/packages/ckeditor5/src/plugins/multicolumn/multicolumn_ui.ts
index d8e6257f44..1661812488 100644
--- a/packages/ckeditor5/src/plugins/multicolumn/multicolumn_ui.ts
+++ b/packages/ckeditor5/src/plugins/multicolumn/multicolumn_ui.ts
@@ -80,7 +80,7 @@ export default class MulticolumnUI extends Plugin {
const command = editor.commands.get("multicolumnLayout") as Command;
const dropdown = createDropdown(locale, SplitButtonView);
dropdown.buttonView.set({
- label: editor.t("Multiple column layout"),
+ label: editor.t("Columns"),
icon: multicolumnIcon,
tooltip: true
});
diff --git a/packages/ckeditor5/src/plugins/toolbar_group_menu.spec.ts b/packages/ckeditor5/src/plugins/toolbar_group_menu.spec.ts
index 0df4dfb318..3e1cd2f2d5 100644
--- a/packages/ckeditor5/src/plugins/toolbar_group_menu.spec.ts
+++ b/packages/ckeditor5/src/plugins/toolbar_group_menu.spec.ts
@@ -216,6 +216,18 @@ describe("ToolbarGroupMenu", () => {
expect(host.show).toHaveBeenCalledTimes(2);
});
+ it("hands the host the layout a group asks for in asMenu", async () => {
+ const { config, last } = createHost();
+ const editor = await createTestEditor(PLUGINS, {
+ ...config,
+ toolbar: { items: [{ ...MENU_GROUP, asMenu: { layout: "tiles" } }] }
+ });
+
+ groupDropdown(getToolbar(editor), "Insert").buttonView.fire("open");
+ expect(labels(last().items)).toStrictEqual(["Bold", "—", "Italic", "Insert sample"]);
+ expect(last().layout).toBe("tiles");
+ });
+
it("describes an entry carrying a list of its own as a submenu, read on each open", async () => {
const { config, last } = createHost();
const editor = await createTestEditor(PLUGINS, {
diff --git a/packages/ckeditor5/src/plugins/toolbar_group_menu.ts b/packages/ckeditor5/src/plugins/toolbar_group_menu.ts
index 13ebe5dd37..ecc46d9dd3 100644
--- a/packages/ckeditor5/src/plugins/toolbar_group_menu.ts
+++ b/packages/ckeditor5/src/plugins/toolbar_group_menu.ts
@@ -92,7 +92,8 @@ export function openListAsMenu(dropdown: DropdownView, options: ListMenuOptions
* Opens a toolbar group as a menu drawn by the host application (`toolbarGroupMenu.host`), with a
* row of icon and label per entry, and a submenu for an entry that carries a list of its own.
*
- * A group opts in with `asMenu: true` beside its `label` in the toolbar configuration.
+ * A group opts in with `asMenu: true` beside its `label` in the toolbar configuration, or with the
+ * {@link ListMenuOptions} of its menu, such as `asMenu: { layout: "tiles" }`.
* `ToolbarView#_createNestedToolbarDropdown()` builds those dropdowns and keeps no reference to the
* definition each came from, so the labels of the opted-in groups are read from the configuration
* and matched against the dropdown buttons. The dropdown never opens its own panel: the views
@@ -102,6 +103,8 @@ export function openListAsMenu(dropdown: DropdownView, options: ListMenuOptions
*/
export default class ToolbarGroupMenu extends Plugin {
+ /** The dropdowns of the groups marked `asMenu`, with the options of their menus. */
+ private groupMenuOptions = new WeakMap<DropdownView, ListMenuOptions>();
private watchedDropdowns = new WeakSet<DropdownView>();
private host: ToolbarGroupMenuHost | null = null;
/** The menu the host shows, with the dropdown it stands for, or `null`. */
@@ -115,7 +118,7 @@ export default class ToolbarGroupMenu extends Plugin {
afterInit() {
const editor = this.editor;
- const labels = collectMenuGroupLabels(
+ const groups = collectMenuGroups(
editor.config.get("toolbar"),
editor.config.get("balloonToolbar"),
editor.config.get("blockToolbar"),
@@ -129,11 +132,11 @@ export default class ToolbarGroupMenu extends Plugin {
for (const toolbar of this.getToolbarViews()) {
for (const item of toolbar.items) {
- this.watchGroupDropdown(toolbar, item, labels, createHost);
+ this.watchGroupDropdown(toolbar, item, groups, createHost);
}
this.listenTo(toolbar.items, "add", (evt, item: View) => {
- this.watchGroupDropdown(toolbar, item, labels, createHost);
+ this.watchGroupDropdown(toolbar, item, groups, createHost);
});
}
}
@@ -170,18 +173,23 @@ export default class ToolbarGroupMenu extends Plugin {
}
private watchGroupDropdown(
- toolbar: ToolbarView, item: View, labels: Set<string>, createHost: () => ToolbarGroupMenuHost
+ toolbar: ToolbarView, item: View, groups: Map<string, ListMenuOptions>,
+ createHost: () => ToolbarGroupMenuHost
) {
if (!(item instanceof DropdownView) || this.watchedDropdowns.has(item)) {
return;
}
const label = item.buttonView.label;
- if (!listMenuDropdowns.has(item) && (!label || !labels.has(label))) {
+ const groupOptions = label ? groups.get(label) : undefined;
+ if (!listMenuDropdowns.has(item) && !groupOptions) {
return;
}
this.watchedDropdowns.add(item);
+ if (groupOptions) {
+ this.groupMenuOptions.set(item, groupOptions);
+ }
// Every way of opening the dropdown sets `isOpen`, its button and the ▼ key alike, so the
// value is turned back here and the host's menu toggles instead.
@@ -239,7 +247,7 @@ export default class ToolbarGroupMenu extends Plugin {
items: listOptions
? this.describeList(dropdown, run)
: describeItems(this.sourceItems(dropdown), run),
- ...listOptions,
+ ...listOptions ?? this.groupMenuOptions.get(dropdown),
setElement: (next) => {
if (element) {
untrackElement(element, trackers);
@@ -319,27 +327,29 @@ function untrackElement(element: HTMLElement, trackers: FocusTracker[]) {
}
}
-function collectMenuGroupLabels(...configs: (ToolbarConfig | undefined)[]) {
- const labels = new Set<string>();
+/** The labels of the groups marked `asMenu`, with the options of their menus. */
+function collectMenuGroups(...configs: (ToolbarConfig | undefined)[]) {
+ const groups = new Map<string, ListMenuOptions>();
for (const config of configs) {
- collectFromItems(Array.isArray(config) ? config : config?.items, labels);
+ collectFromItems(Array.isArray(config) ? config : config?.items, groups);
}
- return labels;
+ return groups;
}
-function collectFromItems(items: ToolbarConfigItem[] | undefined, labels: Set<string>) {
+function collectFromItems(items: ToolbarConfigItem[] | undefined, groups: Map<string, ListMenuOptions>) {
for (const item of items ?? []) {
if (typeof item === "string") {
continue;
}
- if ((item as { asMenu?: boolean }).asMenu) {
- labels.add(item.label);
+ const { asMenu } = item as { asMenu?: boolean | ListMenuOptions };
+ if (asMenu) {
+ groups.set(item.label, asMenu === true ? {} : asMenu);
}
- collectFromItems(item.items, labels);
+ collectFromItems(item.items, groups);
}
}