text icon indicating copy to clipboard operation
text copied to clipboard

Hovering over a link no longer shows the native link preview in the browser

Open provokateurin opened this issue 1 year ago • 2 comments

Describe the bug Normally when you hover over a link in the browser it will display the URL the link points to in the bottom left corner. This no longer happens with the new link bubbles.

To Reproduce Steps to reproduce the behavior:

  1. Create a link in a document
  2. Hover over the link with the mouse

Expected behavior The URL should be displayed by the browser.

Server details:

  • Nextcloud version: c.nc.c
  • PHP Version: c.nc.c
  • Database: c.nc.c

Client details:

  • OS: Arch Linux
  • Browser: Firefox
  • Browser version: 125.0.2
  • Device: Desktop

provokateurin avatar Apr 24 '24 13:04 provokateurin

This actually never happened in edit mode. Only in view mode, the described behaviour existed, and it still exists. Given that this is a browser thing and the browser just doesn't do it in editablecontent fields, I'm not sure we can do anything about it.

mejo- avatar Jun 14 '24 10:06 mejo-

Ok I thought this was something that worked before. Then this is probably a feature request instead :)

provokateurin avatar Jun 14 '24 11:06 provokateurin

So the idea is to always show a tooltip with the URL when hovering an URL?

I wonder whether we want this behaviour, given that we open the link popover box now when clicking on the link.

@nextcloud/designers what do you think?

mejo- avatar Sep 11 '24 10:09 mejo-

Well no a tooltip, but the browser shows the full URL at the bottom left when hovering over a link. This behavior is prevented in text which is not great as users rely on this feature. It blocks a feature that is natively provided by the browser.

provokateurin avatar Sep 11 '24 11:09 provokateurin

@provokateurin well I checked again and we don't change anything from the default browser behaviour:

  • In edit mode the page content is inside a contenteditable element, and there browsers (at least Firefox) don't show the native link preview.
  • In view mode the native link preview is still displayed.

So I guess there's nothing we can do about it.

mejo- avatar Sep 11 '24 13:09 mejo-

I see, but for me the confusing thing is that the cursor changes to the hover icon while the preview is not shown. I would expect an highlighted link to always show the browser preview. I also checked with Github and the difference there is that the link is not highlighted in edit mode. So for me the discrepancy is that the link is highlighted link in view mode, but doesn't behave the same way. If there is really nothing to make this behavior work then feel free to just close this.

provokateurin avatar Sep 11 '24 13:09 provokateurin

I fear there's nothing we can do about it. For sure we want the link to be highlighted in edit mode as we aim for WYSIWYG, with all its downsides :upside_down_face:

mejo- avatar Sep 11 '24 13:09 mejo-