-
-
Notifications
You must be signed in to change notification settings - Fork 7.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Full-text search in whiteboard #6066
Comments
I have implemented temporary solution for myself by syncing all the elements from all my documents into local database, then using LyraSearch to find relevant elements and then loading chosen document at needed position from database into active canvas. |
@7flash Sounds interesting, but I'm afraid that your current workaround is too complicated for the use case of a normal Excalidraw user. |
@zsviczian from https://github.com/zsviczian/obsidian-excalidraw-plugin did an awesome work implementing basic search functionality by means of custom tools. Huge thanks for that! I wonder if this feature could be transferred to Excalidraw as well, since on large whiteboards you might easily forget where you've mentioned certain things and a search function would come very handy in such situations. The current search implementation in the Obsidian plugin shows all results at once, which can be overwhelming on bigger whiteboards, because all the results are so zoomed out to fit on the whole screen, so you can't really see the search results in detail. This could be solved by having a button and/or keyboard shortcut to jump to the next search result, like "ctrl+g" (which is commonly used in other apps for that), which will show only one search result zoomed in (like "shift+2" does now when an object is selected). Another press of "ctrl+g" should jump to the next search result and so on, while "shift+ctrl+g" would jump to the previous search result. Ideally, a pop-up should show the count of all search results, and when jumping from one result to another this count should change, like from 1/8 to 2/8 and so on. |
Indeed, when switching in between search results, it should zoom into each one. Also particular result might be a very long text, and in this case it's important highlight the exact match line and column. In my implementation, it's actually adding two temporary text elements ">" and "<" at the position of match. What do you think could be better highlighing solution? Also, in my case, search is triggered by selecting any text element and pressing search hotkey, that triggers search across elements content of selected element as a search phrase. Do you think it's viable alternative to normally entering search phrase to input field? |
Yeah that makes. In my implementation though there is no search text field at all. Just type a search query as a new text element, select it and press hotkey. |
Which makes sense in the context of another feature I was building, - Command Palletes, inspired by AoE4 hotkeys. I found it convenient to apply different commands such as search or OpenAI query directly to selected elements with hotkeys. |
Currently, I am doing vector search over OCR texts of all images on the canvas, saved in sqlite-vss |
With huge and text-heavy whiteboards, you sometimes forget where a certain piece of text is located. In such situations, a full-text search would come to the rescue.
To initiate the text search, we could use the default keyboard shortcut in browsers (ctrl+f) or a dedicated button near the zoom and undo/redo buttons. When the text is found, the corresponding text field on the whiteboard should be centred (like shift+2 does).
To be sure, I'm not proposing to have a search function to search for saved whiteboards (by their title and description) in Excalidraw Plus, rather I'm speaking about the ability to search for text within an individual whiteboard, when editing it. Although, a global text search in the Excalidraw Plus interface for all saved whiteboards, showing the found text as a snippet for context, would be handy as well.
Edit: Somehow I overlooked similar requests, linking them here for the sake of overview:
#5435
#3826
The text was updated successfully, but these errors were encountered: