Skip to content

Build your personal knowledge base with Trilium Notes

fix(client): popup not displayed for existing attributes (closes #5718)

Elian Doranaa8902f5b94d
diff --git a/apps/client/src/widgets/attribute_widgets/attribute_editor.ts b/apps/client/src/widgets/attribute_widgets/attribute_editor.ts
index 08bfefac3a..3e97723a5d 100644
--- a/apps/client/src/widgets/attribute_widgets/attribute_editor.ts
+++ b/apps/client/src/widgets/attribute_widgets/attribute_editor.ts
@@ -426,7 +426,7 @@ export default class AttributeEditorWidget extends NoteContextAwareWidget implem
curNode = curNode.previousSibling;
if ((curNode as ModelElement).name === "reference") {
- clickIndex += (curNode.getAttribute("notePath") as string).length + 1;
+ clickIndex += (curNode.getAttribute("href") as string).length + 1;
} else if ("data" in curNode) {
clickIndex += (curNode.data as string).length;
}