Build your personal knowledge base with Trilium Notes
TypeScript electronelectron-appknowledge-baseknowledge-graphknowledge-managementknowledge-management-graphlocal-firstnote-managmentnote-takernote-takingnotebooknotesnotes-apppersonal-knowledge-basepersonal-wikiscriptableself-hostedself-hostingwiki
fix(collections): address review findings on the properties dialogs
Elian Doran3a6da99a7156
diff --git a/apps/client/src/translations/en/translation.json b/apps/client/src/translations/en/translation.jsonindex fa618fa7bc..219b4d7205 100644--- a/apps/client/src/translations/en/translation.json+++ b/apps/client/src/translations/en/translation.json@@ -3159,6 +3159,7 @@"coordinates-description": "How positions on the image are measured: in its pixels from the top-left corner, or in coordinates of your own, such as the ones a video game uses.","coordinates-pixels": "Image pixels","coordinates-custom": "Custom",+ "coordinates-inherited": "These corners come from a parent note or a template, so they can only be removed there.","top-left-corner": "Top-left corner","bottom-right-corner": "Bottom-right corner","coordinates-invalid": "The two corners must differ in both x and y, so this change wasn't saved.",diff --git a/apps/client/src/widgets/collections/NoteList.spec.tsx b/apps/client/src/widgets/collections/NoteList.spec.tsxindex d3cab02dcd..5e4e69bddf 100644--- a/apps/client/src/widgets/collections/NoteList.spec.tsx+++ b/apps/client/src/widgets/collections/NoteList.spec.tsx@@ -23,6 +23,15 @@ import { ParentComponent } from "../react/react_utils";import type { ViewTypeOptions } from "./interface";import { CustomNoteList, useNoteIds, useViewModeConfig } from "./NoteList";+const wsHandlers = vi.hoisted(() => new Set<(message: unknown) => void>());+vi.mock("../../services/ws", () => {+ const ws = {+ subscribeToMessages: (handler: (message: unknown) => void) => wsHandlers.add(handler),+ unsubscribeToMessage: (handler: (message: unknown) => void) => wsHandlers.delete(handler)+ };+ return { default: ws, ...ws };+});+let currentNoteIds: string[] = [];// The child ids below stand for real notes: a collection view resolves the ids it is given through@@ -291,6 +300,51 @@ describe("useNoteIds nesting depth", () => {render(null, mountPoint);});});++ it("counts an imported subtree's depth from the collection", async () => {+ const note = buildNote({+ title: "Map",+ type: "book",+ "#maxNestingDepth": "0",+ children: [+ { id: "import-existing", title: "Existing" },+ {+ id: "import-root",+ title: "Imported",+ children: [{ id: "import-child", title: "Imported child" }]+ }+ ]+ });+ const mountPoint = document.createElement("div");+ await act(async () => {+ render(+ <ParentComponent.Provider value={new Component()}>+ <Harness note={note} viewType="geoMap" />+ </ParentComponent.Provider>,+ mountPoint+ );+ });+ await act(async () => {+ await flushMicrotasks();+ });+ expect(currentNoteIds).toEqual([ "import-existing", "import-root" ]);++ await act(async () => {+ for (const handler of wsHandlers) {+ handler({+ type: "taskSucceeded",+ taskType: "importNotes",+ result: { parentNoteId: note.noteId, importedNoteId: "import-root" }+ });+ }+ await flushMicrotasks();+ });+ expect(currentNoteIds).toEqual([ "import-existing", "import-root" ]);++ await act(async () => {+ render(null, mountPoint);+ });+ });});describe("useViewModeConfig view type switch", () => {@@ -340,6 +394,61 @@ describe("useViewModeConfig view type switch", () => {render(null, mountPoint);});});++ it("ignores a restore that resolves after the view type it was for was replaced", async () => {+ const note = buildNote({ title: "Collection", type: "book" });+ const stored: Record<string, object> = {+ "geoMap.json": { view: { center: [ 0, 0 ], zoom: 3 } },+ "table.json": { tableData: { columns: [] } }+ };+ const pending: ReturnType<typeof deferred<void>>[] = [];+ note.getAttachmentsByRole = vi.fn(async () => {+ const gate = deferred<void>();+ pending.push(gate);+ await gate;+ return Object.entries(stored).map(([ title, config ]) => ({+ attachmentId: title,+ title,+ getBlob: async () => ({ content: JSON.stringify(config) })+ }));+ }) as unknown as FNote["getAttachmentsByRole"];++ let latest: object | undefined;+ function ConfigProbe({ viewType }: { viewType: ViewTypeOptions }) {+ latest = useViewModeConfig<object>(note, viewType)?.config;+ return null;+ }++ const mountPoint = document.createElement("div");+ for (const viewType of [ "geoMap", "table" ] as const) {+ await act(async () => {+ render(+ <ParentComponent.Provider value={new Component()}>+ <ConfigProbe viewType={viewType} />+ </ParentComponent.Provider>,+ mountPoint+ );+ });+ }+ const [ geoMapRestore, tableRestore ] = pending;+ if (!geoMapRestore || !tableRestore) throw new Error("expected two pending restores");++ await act(async () => {+ tableRestore.resolve();+ await flushMicrotasks();+ });+ expect(latest).toEqual(stored["table.json"]);++ await act(async () => {+ geoMapRestore.resolve();+ await flushMicrotasks();+ });+ expect(latest).toEqual(stored["table.json"]);++ await act(async () => {+ render(null, mountPoint);+ });+ });});/**diff --git a/apps/client/src/widgets/collections/NoteList.tsx b/apps/client/src/widgets/collections/NoteList.tsxindex 419080e351..3487d1ad01 100644--- a/apps/client/src/widgets/collections/NoteList.tsx+++ b/apps/client/src/widgets/collections/NoteList.tsx@@ -7,7 +7,6 @@ import { useEffect, useRef, useState } from "preact/hooks";import FNote from "../../entities/fnote";import type { PrintReport } from "../../print";-import froca from "../../services/froca";import { subscribeToMessages, unsubscribeToMessage as unsubscribeFromMessage } from "../../services/ws";import { useGetContextDataFrom, useNoteContext, useNoteLabel, useNoteLabelBoolean, useNoteLabelInt, useNoteProperty, useTriliumEvent } from "../react/hooks";import { allViewTypes, ViewModeMedia, ViewModeProps, ViewTypeOptions } from "./interface";@@ -244,24 +243,19 @@ export function useNoteIds(note: FNote | null | undefined, viewType: ViewTypeOpt// Refresh on import.useEffect(() => {- async function onImport(message: WebSocketMessage) {+ function onImport(message: WebSocketMessage) {if (!("taskType" in message) || message.taskType !== "importNotes" || message.type !== "taskSucceeded") return;const { parentNoteId, importedNoteId } = message.result;if (!parentNoteId || !importedNoteId) return;- if (importedNoteId && (parentNoteId === note?.noteId || noteIds.includes(parentNoteId))) {- const importedNote = await froca.getNote(importedNoteId);- if (!importedNote) return;- setNoteIds([- ...noteIds,- ...await getNoteIds(importedNote),- importedNoteId- ]);+ // Walked again from the collection, so that `maxDepth` counts from there.+ if (parentNoteId === note?.noteId || noteIds.includes(parentNoteId)) {+ void refreshNoteIds();}}subscribeToMessages(onImport);return () => unsubscribeFromMessage(onImport);- }, [ note, noteIds, setNoteIds ]);+ }, [ note, noteIds, includeArchived, directChildrenOnly, maxDepth ]);return noteIds;}@@ -288,8 +282,12 @@ export function useViewModeConfig<T extends object>(note: FNote | null | undefinsetViewConfig({ note, viewType, config, storeFn });viewStorage.store(config);};- storageRef.current = { storage: viewStorage, storeFn, note, viewType };+ const current = { storage: viewStorage, storeFn, note, viewType };+ storageRef.current = current;viewStorage.restore().then(config => {+ // A restore that resolves after the note or view type changed would replace the newer+ // config.+ if (storageRef.current !== current) return;setViewConfig({ note, viewType, config, storeFn });});}, [ note, viewType ]);@@ -305,7 +303,7 @@ export function useViewModeConfig<T extends object>(note: FNote | null | undefinreturn;}current.storage.restoreIfChanged().then(config => {- if (config === undefined) return;+ if (config === undefined || storageRef.current !== current) return;setViewConfig({ note: current.note, viewType: current.viewType, config, storeFn: current.storeFn });});});diff --git a/apps/client/src/widgets/collections/geomap/GeoMapProperties.spec.tsx b/apps/client/src/widgets/collections/geomap/GeoMapProperties.spec.tsxindex 18168885ac..82be4dd4f6 100644--- a/apps/client/src/widgets/collections/geomap/GeoMapProperties.spec.tsx+++ b/apps/client/src/widgets/collections/geomap/GeoMapProperties.spec.tsx@@ -371,6 +371,51 @@ describe("GeoMapProperties", () => {expect(mocks.removeOwnedLabelByName).toHaveBeenCalledWith(note, "map:imageBounds");});+ it("offers custom corners only once the image's size is known", () => {+ const unmeasured = [ { status: "loading" }, { status: "error", reason: "unloadable" } ] as const;+ for (const image of unmeasured) {+ draw({ "~map:image": "image1" }, image);+ expect(coordinateButtons()).toHaveLength(2);+ expect(coordinateButtons().every((button) => button.disabled)).toBe(true);+ chooseCoordinateMode("geo-map.coordinates-custom");+ expect(mocks.setLabel).not.toHaveBeenCalled();+ render(null, container);+ }++ // Corners already chosen can still be removed while the image loads.+ draw({ "~map:image": "image1", "#map:imageBounds": "0,0 10,10" }, { status: "loading" });+ expect(coordinateButtons().some((button) => button.disabled)).toBe(false);+ });++ it("keeps inherited corners, which only their owner can remove", () => {+ buildNote({+ title: "Maps",+ "#map:imageBounds(inheritable)": "-512,512 512,-512",+ children: [ { id: "cornersMap", title: "Map", "~map:image": "image1" } ]+ });+ drawNote(froca.notes.cornersMap, LOADED_IMAGE);+ expect(coordinateModes()).toEqual([+ [ "geo-map.coordinates-pixels", false ], [ "geo-map.coordinates-custom", true ]+ ]);+ expect(query(".geo-map-coordinates .tn-card-option-description")?.textContent)+ .toBe("geo-map.coordinates-inherited");+ expect(coordinateButtons().every((button) => button.disabled)).toBe(true);+ chooseCoordinateMode("geo-map.coordinates-pixels");+ expect(mocks.removeOwnedLabelByName).not.toHaveBeenCalled();+ });++ it("keeps drawing the image until a tileset's URL is entered", () => {+ const note = draw({ "~map:image": "image1" }, LOADED_IMAGE);+ choose("geo-map.background-tiles");+ expect(backgroundType()).toBe("geo-map.background-tiles");+ expect(mocks.toggleDangerousAttribute).not.toHaveBeenCalled();++ type(query<HTMLInputElement>(".geo-map-tiles-url"), TILE_URL);+ expect(mocks.setLabel).toHaveBeenCalledWith(note.noteId, "map:style", TILE_URL);+ expect(mocks.toggleDangerousAttribute)+ .toHaveBeenCalledExactlyOnceWith(note, "relation", "map:image", false);+ });+it("says why an image cannot be drawn, or might not be on every device", () => {draw({ "~map:image": "image1" }, { status: "error", reason: "svg" });expect(query(".geo-map-image-notice")?.textContent).toBe("geo-map.image-svg-unsupported");diff --git a/apps/client/src/widgets/collections/geomap/GeoMapProperties.tsx b/apps/client/src/widgets/collections/geomap/GeoMapProperties.tsxindex e93b5c8610..7ce07bdeda 100644--- a/apps/client/src/widgets/collections/geomap/GeoMapProperties.tsx+++ b/apps/client/src/widgets/collections/geomap/GeoMapProperties.tsx@@ -121,8 +121,10 @@ function BackgroundCard({ note, image }: { note: FNote; image: GeoMapImageStatefunction changeKind(newKind: BackgroundKind) {setKind(newKind);- if (newKind !== "image" && note.getOwnedRelation("map:image")) {- void attributes.toggleDangerousAttribute(note, "relation", "map:image", false);+ const hasTileset = !!tileUrl || !!note.getOwnedLabel("disabled:map:style");+ const replacesImage = newKind === "map" || (newKind === "tiles" && hasTileset);+ if (replacesImage && note.getOwnedRelation("map:image")) {+ disableImage();} else if (newKind === "image" && !imageNoteId && note.getOwnedRelation("disabled:map:image")) {void attributes.toggleDangerousAttribute(note, "relation", "map:image", true);}@@ -152,6 +154,13 @@ function BackgroundCard({ note, image }: { note: FNote; image: GeoMapImageStateif (note.getOwnedLabel("disabled:map:style")) {void attributes.removeOwnedLabelByName(note, "disabled:map:style");}+ if (note.getOwnedRelation("map:image")) {+ disableImage();+ }+ }++ function disableImage() {+ void attributes.toggleDangerousAttribute(note, "relation", "map:image", false);}return (@@ -338,6 +347,9 @@ function ImageSettings({ note, image, imageNoteId, onPickImage }: {function ImageCoordinates({ note, size }: { note: FNote; size: ImageSize | undefined }) {const [ boundsValue, setBoundsValue ] = useNoteLabel(note, "map:imageBounds");const isCustom = boundsValue !== null && boundsValue !== undefined;+ const isInherited = isCustom && !note.getOwnedLabel("map:imageBounds");+ // Custom corners start from the image's size, so they cannot be chosen before it is known.+ const isDisabled = isInherited || (!isCustom && !size);const [ corners, setCorners ] = useState(() => cornersOf(boundsValue));const [ isInvalid, setInvalid ] = useState(false);@@ -349,9 +361,10 @@ function ImageCoordinates({ note, size }: { note: FNote; size: ImageSize | undeffunction changeMode(mode: string) {if (mode === "custom") {// Starts from the pixels, so that switching leaves every marker where it is.+ if (!size) return;setBoundsValue(formatImageExtent({topLeft: [ 0, 0 ],- bottomRight: [ size?.width ?? 100, size?.height ?? 100 ]+ bottomRight: [ size.width, size.height ]}));} else {setBoundsValue(null);@@ -374,7 +387,9 @@ function ImageCoordinates({ note, size }: { note: FNote; size: ImageSize | undef<OptionCardSectionclassName="geo-map-coordinates"label={t("geo-map.coordinates")}- description={t("geo-map.coordinates-description")}+ description={isInherited+ ? t("geo-map.coordinates-inherited")+ : t("geo-map.coordinates-description")}subSectionsVisiblesubSections={isCustom ? <><CornerSection@@ -403,6 +418,7 @@ function ImageCoordinates({ note, size }: { note: FNote; size: ImageSize | undef]}currentValue={isCustom ? "custom" : "pixels"}onChange={changeMode}+ disabled={isDisabled}/></OptionCardSection>);diff --git a/apps/client/src/widgets/layout/NoteActions.spec.tsx b/apps/client/src/widgets/layout/NoteActions.spec.tsxindex 664484a77d..cf698021ba 100644--- a/apps/client/src/widgets/layout/NoteActions.spec.tsx+++ b/apps/client/src/widgets/layout/NoteActions.spec.tsx@@ -121,8 +121,10 @@ describe("NoteContextMenu", () => {});it("offers the properties dialog of the collections that have one", async () => {- const hasPropertiesItem = async (viewType: string) => {- const note = buildNote({ title: viewType, type: "book", "#viewType": viewType });+ const hasPropertiesItem = async (viewType: string, labels: Record<string, string> = {}) => {+ const note = buildNote({+ title: viewType, type: "book", "#viewType": viewType, ...labels+ });const noteContext = new NoteContext("ntx-collection");noteContext.noteId = note.noteId;noteContext.viewScope = { viewMode: "default" };@@ -143,6 +145,13 @@ describe("NoteContextMenu", () => {expect(await hasPropertiesItem("table")).toBe(true);expect(await hasPropertiesItem("geoMap")).toBe(true);expect(await hasPropertiesItem("list")).toBe(false);++ // The board opens its dialog on a read-only note; the other views do not.+ for (const viewType of [ "table", "geoMap", "calendar" ]) {+ expect(await hasPropertiesItem(viewType, { "#readOnly": "" })).toBe(false);+ }+ expect(await hasPropertiesItem("calendar")).toBe(true);+ expect(await hasPropertiesItem("board", { "#readOnly": "" })).toBe(true);});it("offers to print a render note only while it has a render target", async () => {diff --git a/apps/client/src/widgets/layout/NoteActions.tsx b/apps/client/src/widgets/layout/NoteActions.tsxindex 722349f22c..09bc321e7c 100644--- a/apps/client/src/widgets/layout/NoteActions.tsx+++ b/apps/client/src/widgets/layout/NoteActions.tsx@@ -23,7 +23,7 @@ import { showImageCompressionDialog } from "../dialogs/image_compression/image_cimport { isAlwaysFullWidthByType } from "../note_wrapper";import Dropdown, { type DropdownHandle } from "../react/Dropdown";import { FormDropdownDivider, FormDropdownSubmenu, FormListHeader, FormListItem, FormListToggleableItem } from "../react/FormList";-import { useIsNoteReadOnly, useNoteContext, useNoteLabel, useNoteLabelBoolean, useNoteLabelOptionalBool, useNoteProperty, useNoteRelation, useSyncedRef, useTriliumEvent, useTriliumOption } from "../react/hooks";+import { useEffectiveReadOnly, useIsNoteReadOnly, useNoteContext, useNoteLabel, useNoteLabelBoolean, useNoteLabelOptionalBool, useNoteProperty, useNoteRelation, useSyncedRef, useTriliumEvent, useTriliumOption } from "../react/hooks";import { ParentComponent, POPUP_EDITOR_NTX_ID, useCommandTrigger } from "../react/react_utils";import NoteActionsCustom from "./NoteActionsCustom";import { useShareState } from "./NoteBadges";@@ -92,6 +92,10 @@ export function NoteContextMenu({ note, noteContext, itemsAtStart, itemsNearNoteconst isHelpPage = note.noteId.startsWith("_help");const [syncServerHost] = useTriliumOption("syncServerHost");const { isReadOnly, enableEditing } = useIsNoteReadOnly(note, noteContext);+ const isViewReadOnly = useEffectiveReadOnly(note, noteContext);+ // The views other than the board open their properties dialog only while they are editable.+ const hasCollectionProperties = isBoard+ || (!isViewReadOnly && (isEventCalendar || isGeoMap || isTable));const isNormalViewMode = noteContext?.viewScope?.viewMode === "default";// The quick edit popup has no find bar, and the note map and a converted attachment open in the tab behind it.const isInPopup = !!noteContext?.ntxId?.startsWith(POPUP_EDITOR_NTX_ID);@@ -179,7 +183,7 @@ export function NoteContextMenu({ note, noteContext, itemsAtStart, itemsNearNote{note.type === "render" && <CommandItem command="renderActiveNote" icon="bx bx-extension" text={t("note_actions.re_render_note")}/>}- {(isBoard || isEventCalendar || isGeoMap || isTable) && <CommandItem icon="bx bx-cog"+ {hasCollectionProperties && <CommandItem icon="bx bx-cog"text={isBoard ? t("board_view.properties"): isGeoMap ? t("geo-map.properties"): isTable ? t("table_view.properties") : t("calendar_view.properties")}diff --git a/apps/server/src/assets/doc_notes/en/User Guide/User Guide/Collections/Geo Map.html b/apps/server/src/assets/doc_notes/en/User Guide/User Guide/Collections/Geo Map.htmlindex db798f4418..b71350d65c 100644--- a/apps/server/src/assets/doc_notes/en/User Guide/User Guide/Collections/Geo Map.html+++ b/apps/server/src/assets/doc_notes/en/User Guide/User Guide/Collections/Geo Map.html@@ -496,6 +496,8 @@ class="admonition note">it on the map. You can still search and click, and you can still look ata place and copy its coordinates.</li><li>Drawing <a href="#root/_help_C2H9HK4BzwG7">shapes</a>.</li>+ <li>The <em>Geo map properties</em> dialog; its entry is hidden from the <a+ class="reference-link" href="#root/_help_8YBEPzcpUgxw">Note menu</a>.</li></ul><p>To set a map as read-only, go to <a class="reference-link" href="#root/_help_8YBEPzcpUgxw">Note menu</a> → <em>Editable</em> → <em>Read-only</em>.</p><h2>Configuration</h2>@@ -554,7 +556,8 @@ class="admonition note">the zoom level and the position of the tile go. For example, to use Esri.NatGeoWorldMap,enter <a href="https://server.arcgisonline.com/ArcGIS/rest/services/NatGeo_World_Map/MapServer/tile/%7Bz%7D/%7By%7D/%7Bx%7D"><code>https://server.arcgisonline.com/ArcGIS/rest/services/NatGeo_World_Map/MapServer/tile/{z}/{y}/{x}</code></a>.The URL is saved once you leave the field; a URL that doesn't start with <code>http://</code> or <code>https://</code>,- or that lacks one of the three placeholders, is not saved.</li>+ or that lacks one of the three placeholders, is not saved. A map drawn+ over an image keeps its image until a URL is saved.</li><li>If the tiles are dark, turn on <em>Dark tileset</em>, which draws the markertitles in a light color so that they remain readable.</li></ol>diff --git a/apps/server/src/assets/doc_notes/en/User Guide/User Guide/Collections/Geo Map/Image maps.html b/apps/server/src/assets/doc_notes/en/User Guide/User Guide/Collections/Geo Map/Image maps.htmlindex 6c1932f5f5..1f6a4c68b1 100644--- a/apps/server/src/assets/doc_notes/en/User Guide/User Guide/Collections/Geo Map/Image maps.html+++ b/apps/server/src/assets/doc_notes/en/User Guide/User Guide/Collections/Geo Map/Image maps.html@@ -74,9 +74,13 @@set <em>Coordinates</em> under <em>Background</em> to <em>Custom</em>, and enterthe coordinates of the image's <em>Top-left corner</em> and <em>Bottom-right corner</em>.Switching to <em>Custom</em> starts from the image's size in pixels, so the- markers stay where they are until the corners are changed. All positions- are then read and written in those coordinates, including the ones shown- in the contextual menu and in the popup view. To go back to pixels, set <em>Coordinates</em> to <em>Image pixels</em>.</p>+ markers stay where they are until the corners are changed; for that reason, <em>Custom</em> can+ only be chosen once the image has loaded. All positions are then read and+ written in those coordinates, including the ones shown in the contextual+ menu and in the popup view. To go back to pixels, set <em>Coordinates</em> to <em>Image pixels</em>.+ Corners that the geo map inherits from a parent note or a template can+ only be removed on the note that holds them; entering other corners on+ this map overrides them.</p><p>The corners are stored in the <code>#map:imageBounds</code> label of thegeo map as <code>x,y x,y</code>, with a space between the two corners, whichcan also be set by hand. For example:</p>diff --git a/apps/server/src/assets/doc_notes/en/User Guide/User Guide/Collections/Table.html b/apps/server/src/assets/doc_notes/en/User Guide/User Guide/Collections/Table.htmlindex d7b12d02b3..e4f8014d57 100644--- a/apps/server/src/assets/doc_notes/en/User Guide/User Guide/Collections/Table.html+++ b/apps/server/src/assets/doc_notes/en/User Guide/User Guide/Collections/Table.html@@ -117,7 +117,8 @@be edited and the rows can't be dragged. The <em>New row</em> and <em>New column</em> buttonsare hidden, and the context menus offer only what leaves the notes as theyare: sorting and hiding columns, and opening the notes. Columns can still- be resized and reordered, but the layout isn't saved.</p>+ be resized and reordered, but the layout isn't saved. The <em>Table properties</em> dialog+ isn't available.</p><h2>Working with the data</h2><h3>Sorting by column</h3><p>By default, the order of the notes matches the order in the <a class="reference-link"diff --git a/docs/User Guide/User Guide/Collections/Geo Map.md b/docs/User Guide/User Guide/Collections/Geo Map.mdindex 661187f734..68d017951f 100644--- a/docs/User Guide/User Guide/Collections/Geo Map.md+++ b/docs/User Guide/User Guide/Collections/Geo Map.md@@ -333,6 +333,7 @@ When a map is [read-only](../Basic%20Concepts%20and%20Features/Notes/Read-Only%2* Editing from the contextual menu (removing locations or adding new items).* Keeping a place as a marker, whether you found it by searching or clicked it on the map. You can still search and click, and you can still look at a place and copy its coordinates.* Drawing [shapes](Geo%20Map/Drawing%20shapes.md).+* The _Geo map properties_ dialog; its entry is hidden from the <a class="reference-link" href="../Basic%20Concepts%20and%20Features/UI%20Elements/Note%20menu.md">Note menu</a>.To set a map as read-only, go to <a class="reference-link" href="../Basic%20Concepts%20and%20Features/UI%20Elements/Note%20menu.md">Note menu</a> → _Editable_ → _Read-only_.@@ -376,7 +377,7 @@ To use one:1. Open the _Geo map properties_ dialog from the <a class="reference-link" href="../Basic%20Concepts%20and%20Features/UI%20Elements/Note%20menu.md">Note menu</a>.2. Under _Background_, set _Type_ to _Custom tileset_.-3. In _Tile URL_, enter the address of the tile set, with `{z}`, `{x}` and `{y}` where the zoom level and the position of the tile go. For example, to use Esri.NatGeoWorldMap, enter [`https://server.arcgisonline.com/ArcGIS/rest/services/NatGeo_World_Map/MapServer/tile/{z}/{y}/{x}`](https://server.arcgisonline.com/ArcGIS/rest/services/NatGeo_World_Map/MapServer/tile/%7Bz%7D/%7By%7D/%7Bx%7D). The URL is saved once you leave the field; a URL that doesn't start with `http://` or `https://`, or that lacks one of the three placeholders, is not saved.+3. In _Tile URL_, enter the address of the tile set, with `{z}`, `{x}` and `{y}` where the zoom level and the position of the tile go. For example, to use Esri.NatGeoWorldMap, enter [`https://server.arcgisonline.com/ArcGIS/rest/services/NatGeo_World_Map/MapServer/tile/{z}/{y}/{x}`](https://server.arcgisonline.com/ArcGIS/rest/services/NatGeo_World_Map/MapServer/tile/%7Bz%7D/%7By%7D/%7Bx%7D). The URL is saved once you leave the field; a URL that doesn't start with `http://` or `https://`, or that lacks one of the three placeholders, is not saved. A map drawn over an image keeps its image until a URL is saved.4. If the tiles are dark, turn on _Dark tileset_, which draws the marker titles in a light color so that they remain readable.Additionally:diff --git a/docs/User Guide/User Guide/Collections/Geo Map/Image maps.md b/docs/User Guide/User Guide/Collections/Geo Map/Image maps.mdindex dba36dff72..081b0c3eec 100644--- a/docs/User Guide/User Guide/Collections/Geo Map/Image maps.md+++ b/docs/User Guide/User Guide/Collections/Geo Map/Image maps.md@@ -44,7 +44,7 @@ The _Map style_ setting doesn't apply to an image map, so it's hidden from the sBy default, positions are measured in pixels of the image at its original size, from its top-left corner, with `x` growing to the right and `y` growing downwards.-To use coordinates of your own instead, open the _Geo map properties_ dialog, set _Coordinates_ under _Background_ to _Custom_, and enter the coordinates of the image's _Top-left corner_ and _Bottom-right corner_. Switching to _Custom_ starts from the image's size in pixels, so the markers stay where they are until the corners are changed. All positions are then read and written in those coordinates, including the ones shown in the contextual menu and in the popup view. To go back to pixels, set _Coordinates_ to _Image pixels_.+To use coordinates of your own instead, open the _Geo map properties_ dialog, set _Coordinates_ under _Background_ to _Custom_, and enter the coordinates of the image's _Top-left corner_ and _Bottom-right corner_. Switching to _Custom_ starts from the image's size in pixels, so the markers stay where they are until the corners are changed; for that reason, _Custom_ can only be chosen once the image has loaded. All positions are then read and written in those coordinates, including the ones shown in the contextual menu and in the popup view. To go back to pixels, set _Coordinates_ to _Image pixels_. Corners that the geo map inherits from a parent note or a template can only be removed on the note that holds them; entering other corners on this map overrides them.The corners are stored in the `#map:imageBounds` label of the geo map as `x,y x,y`, with a space between the two corners, which can also be set by hand. For example:diff --git a/docs/User Guide/User Guide/Collections/Table.md b/docs/User Guide/User Guide/Collections/Table.mdindex 467ea4a2d8..bf570829ad 100644--- a/docs/User Guide/User Guide/Collections/Table.md+++ b/docs/User Guide/User Guide/Collections/Table.md@@ -88,7 +88,7 @@ If the _Name_ field of a column is changed, this will trigger a batch operation### Read-only tables-On a [read-only](../Basic%20Concepts%20and%20Features/Notes/Read-Only%20Notes.md) table, the cells can't be edited and the rows can't be dragged. The _New row_ and _New column_ buttons are hidden, and the context menus offer only what leaves the notes as they are: sorting and hiding columns, and opening the notes. Columns can still be resized and reordered, but the layout isn't saved.+On a [read-only](../Basic%20Concepts%20and%20Features/Notes/Read-Only%20Notes.md) table, the cells can't be edited and the rows can't be dragged. The _New row_ and _New column_ buttons are hidden, and the context menus offer only what leaves the notes as they are: sorting and hiding columns, and opening the notes. Columns can still be resized and reordered, but the layout isn't saved. The _Table properties_ dialog isn't available.## Working with the data