]> BookStack Code Mirror - bookstack/blobdiff - resources/js/markdown/actions.js
OIDC Userinfo: Fixed issues with validation logic from changes
[bookstack] / resources / js / markdown / actions.js
index 4909a59d066f9627b3756e951be2079940369083..73040a57b1eb016e51abe2e80176561815befa89 100644 (file)
@@ -73,7 +73,12 @@ export class Actions {
             const selectedText = selectionText || entity.name;
             const newText = `[${selectedText}](${entity.link})`;
             this.#replaceSelection(newText, newText.length, selectionRange);
-        }, selectionText);
+        }, {
+            initialValue: selectionText,
+            searchEndpoint: '/search/entity-selector',
+            entityTypes: 'page,book,chapter,bookshelf',
+            entityPermission: 'view',
+        });
     }
 
     // Show draw.io if enabled and handle save.