Skip to content

Build your personal knowledge base with Trilium Notes

force refresh before activating the attribute detail dialog, fixes #4077

zadam23278f54cb3d
diff --git a/src/public/app/widgets/attribute_widgets/attribute_editor.js b/src/public/app/widgets/attribute_widgets/attribute_editor.js
index 8ded708f84..225ba1f384 100644
--- a/src/public/app/widgets/attribute_widgets/attribute_editor.js
+++ b/src/public/app/widgets/attribute_widgets/attribute_editor.js
@@ -228,15 +228,19 @@ export default class AttributeEditorWidget extends NoteContextAwareWidget {
}
// triggered from keyboard shortcut
- addNewLabelEvent({ntxId}) {
+ async addNewLabelEvent({ntxId}) {
if (this.isNoteContext(ntxId)) {
+ await this.refresh();
+
this.handleAddNewAttributeCommand('addNewLabel');
}
}
// triggered from keyboard shortcut
- addNewRelationEvent({ntxId}) {
+ async addNewRelationEvent({ntxId}) {
if (this.isNoteContext(ntxId)) {
+ await this.refresh();
+
this.handleAddNewAttributeCommand('addNewRelation');
}
}