obsidian-map-view icon indicating copy to clipboard operation
obsidian-map-view copied to clipboard

Open in New Pane asks to open link

Open TheFibonacciEffect opened this issue 2 years ago • 8 comments

If I click on a geo link (eg: [Cathedral de Santa Maria](geo:40.41580041174021,-3.7153555949265544) ), the map is opened in a new pane, but I also get asked if I want to open a link to geo:40.41580041174021,-3.7153555949265544, which is not intended.

TheFibonacciEffect avatar Sep 03 '23 21:09 TheFibonacciEffect

image Here is what I mean, I get led to the website https://wheelmap.org/search

TheFibonacciEffect avatar Sep 03 '23 21:09 TheFibonacciEffect

I am unable to recreate this, so more details would be helpful.

  1. What Obsidian version?
  2. What OS?
  3. Are you using Editing or Reading view? Overall, if you can make a short video snippet of the issue, it would be helpful, as I might see in it some detail that I didn't think about.

esm7 avatar Sep 05 '23 08:09 esm7

Hi, sure 1.Version : 1.3.7-1 2. Arch Linux 3. I am using editing view but the issue appears with both, I think. output

I am using ctrl+shift+click to open the link

TheFibonacciEffect avatar Sep 07 '23 19:09 TheFibonacciEffect

The issue also appears when I just open liks normally, considering that I have "open in 2nd pane and keep reusing it" set. I am not getting asked if I want to open a link when I open the map view for the first time, but when I reuse the map subsequently I get asked every time.

TheFibonacciEffect avatar Sep 11 '23 21:09 TheFibonacciEffect

That's a very tricky problem to solve. Since there is no Obsidian API to reroute or control links, Map View registers a CodeMirror extension that locates links and adds event handlers that try to override the default behavior. It seems like in some cases the original event handlers are still called, and it's not obvious to me how to stop them. I'll dig deeper into this and hopefully come up with a way.

esm7 avatar Sep 12 '23 10:09 esm7

Hello, I have the very same problem on windows... Makes the all thing unusable... :s But when configured to 'open new tab' instead of 'open new pane', the problem disappears.

nio101 avatar Oct 09 '23 16:10 nio101

Hi all, I was unable to find time to work on Map View in the past weeks (there area where I live is a war zone now :( ) Hopefully things will calm down reasonably soon and I'll be able to work on this and other issues. The "Handle geolinks in notes" feature is not perfect yet, and until I manage to work on it and find a way to improve it, if you find it more harmful than good, note it can be turned off in the settings.

esm7 avatar Oct 15 '23 11:10 esm7

Dont worry, its not something that perticularily restricts my usage of the awesome plugin you made! I also sincerely hope that you and your family and friends go through this unharmed. I dont know what to say as I cant imagine the suffering and pain of going though a war, but I wish you the very best!

TheFibonacciEffect avatar Nov 18 '23 20:11 TheFibonacciEffect

Hopefully finally fixed in 5.1.0!

esm7 avatar Nov 03 '24 09:11 esm7

Thanks a lot : )

TheFibonacciEffect avatar Nov 03 '24 11:11 TheFibonacciEffect