Search for items in a big table, cursor isn't positioned correctly when you click on the found text

Steps to reproduce

  • Document with a large table (spanning multiple screenfulls is best, to show how frustrating the behavior is, but the basics of this bug appear with any size table)
  • Live preview mode
  • Ctrl-F in the edit window to find text within that document, search for something that’s in the table
  • You will correctly see the text found and hilighted… BUT… how do you get to the point where you can EDIT the text that was found at that spot in the table?
  • Mouse click on the found text – which when not in a table would just put the cursor there – doesn’t work, it jumps and puts the cursor AFTER the entire table.

I think that what’s happening is that it doesn’t quite understand how to exit the “find” but position both the cursor and the display to be showing you the last thing found, where you clicked. It’s like the fact that the line spacing of how much room the rendered table takes up versus the source of the table is different, is throwing it off.

Actually, now that I try it, this same thing doesn’t work particularly even in “source mode” either. When the item found is in a big table, you can’t easily position the edit cursor on the table cell where the text was found so that you can edit it.

Did you follow the troubleshooting guide? [Y/N]

Yes

Expected result

When I ‘find’ within the current document, and it highlights the matched text, I expect that clicking directly on the highlighted matched text will result in exiting the find task and leaving the cursor on the matched text, still visible on the display.

This works as expected for ordinary text in the document that is not part of any table.

Actual result

But if the found text is in a table, clicking on the found text exits the ‘find’ functionality, but instead of positioning the cursor on that found text where I clicked, the cursor ends up AFTER the end of the table. If the table is long and spans more than a screen-full, then it ends up jumping the whole display past the end of the table so it’s in fact very hard to navigate back to where in the table that found text was.

Note that when not doing a “find”, if I just do an ordinary click on text that is in a rendered table, it does correctly position the cursor there for editing, and it doesn’t navigate the current display view away from the table.

Environment

SYSTEM INFO:
Obsidian version: v1.8.1
Installer version: v1.4.13
Operating system: Darwin Kernel Version 22.6.0: Mon Apr 22 20:54:28 PDT 2024; root:xnu-8796.141.3.705.2~1/RELEASE_X86_64 22.6.0
Login status: logged in
Language: en
Catalyst license: supporter
Insider build toggle: on
Live preview: on
Base theme: dark
Community theme: none
Snippets enabled: 2
Restricted mode: off
Plugins installed: 58
Plugins enabled: 47
1: Advanced Tables v0.22.1
2: Calendar v1.5.10
3: Paste URL into selection v1.7.0
4: Emoji Toolbar v0.4.1
5: Editor Syntax Highlight v0.1.3
6: Convert url to preview (iframe) v0.5.0
7: Consistent Attachments and Links v3.21.7
8: Templater v2.9.1
9: File Tree Alternative v2.6.0
10: Code block from selection v1.0.7
11: Markdown Formatting Assistant v0.4.1
12: Meld Encrypt v2.3.7
13: Highlightr v1.2.2
14: Style Settings v1.0.9
15: Recent Files v1.7.1
16: Rollover Daily Todos v1.1.8
17: Review v1.6.5
18: Code Editor Shortcuts v1.14.0
19: Obsidian Columns v1.5.2
20: Text Format v3.1.0
21: Quick Switcher++ v4.6.2
22: Update time on edit v2.4.0
23: Dynamic Table of Contents v0.0.27
24: Excalidraw v2.6.7
25: Advanced Slides v1.20.0
26: Omnisearch v1.25.1
27: Note Refactor v1.8.2
28: Image Layouts v0.15.5
29: Emoji Shortcodes v2.2.0
30: Paste As Html v1.0.2
31: List Callouts v1.2.9
32: Commander v0.5.2
33: PodNotes v2.13.3
34: Folder Note v0.7.3
35: Image Toolkit v1.4.2
36: Task Marker v0.5.1
37: Colored Text v1.2.0
38: File Color v1.1.0
39: Open In New Tab v1.0.9
40: Importer v1.6.12
41: Sort & Permute lines v0.7.0
42: Markdown Table Editor v0.3.1
43: Cursor Location v0.3.2
44: Periodic Notes v0.0.17
45: Auto Link Title v1.5.4
46: Image in Editor v2.2.6
47: Annotator v0.2.11

RECOMMENDATIONS:
Custom theme and snippets: for cosmetic issues, please first try updating your theme and disabling your snippets. If still not fixed, please try to make the issue happen in the Sandbox Vault or disable community theme and snippets.
Community plugins: for bugs, please first try updating all your plugins to latest. If still not fixed, please try to make the issue happen in the Sandbox Vault or disable community plugins.


Additional information

I did also try this in an empty sandbox vault with no extensions installed, and the symptoms are the same.