Skip to content
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

New mention UI eats the text of the link #1261

Closed
MightyCreak opened this issue Aug 2, 2017 · 10 comments
Closed

New mention UI eats the text of the link #1261

MightyCreak opened this issue Aug 2, 2017 · 10 comments
Labels
A-Composer A-Pills P2 S-Minor Impairs non-critical functionality or suitable workarounds exist T-Defect T-Enhancement

Comments

@MightyCreak
Copy link

MightyCreak commented Aug 2, 2017

Description

Can't make a link to a room with a text.

Steps to reproduce

If you write something like that:

Meet me [here](https://riot.im/develop/#/room/#test:matrix.org)

here isn't shown. Instead it's the room name that is.

Describe how what happens differs from what you expected.

riot_issue_mention_link

The best solution would be to show the room icon but keep the link text instead of the room name.

Version information

Dev

  • Platform: web

For the web app:

  • Browser: Firefox 54
  • OS: macOS
  • URL: riot.im/develop
@t3chguy
Copy link
Member

t3chguy commented Aug 2, 2017

Please use the Issue template properly and open a new issue with it filled.

@t3chguy t3chguy closed this as completed Aug 2, 2017
@MightyCreak
Copy link
Author

MightyCreak commented Aug 2, 2017

Sorry, I messed up with my fingers, but I was editing it... (can't reopen the issue)

@lampholder
Copy link
Member

I've tagged this as a bug and a feature... it's hard to know exactly the right thing to do with these, but it doesn't seem wholly unreasonable to just dictate that, within riot.im, links to rooms render as room pills, and for people's habits to change accordingly.

Though at the moment the alternative of typing Meet me here: [](https://riot.im/develop/#/room/#test:matrix.org) is fairly clunky.

@lukebarnard1 have we considered whether room URLs should automatically become pills, so people could type Meet me here: https://riot.im/develop/#/room/#test:matrix.org we'd still see a pill?

@lampholder lampholder added the S-Minor Impairs non-critical functionality or suitable workarounds exist label Aug 3, 2017
@lukebarnard1
Copy link

I think a better solution would be to only render a pill if the sending user has sent a [#alias](https://matrix.to/#/#alias) link where the text matches the URL.

Anything else could be rendered as a normal link, including @MightyCreak's here.

@lukebarnard1
Copy link

have we considered whether room URLs should automatically become pills

This feels unrelated here, but yes it has been considered. There's a comment in the code saying "move this up one line if we decide to make plain URLs pill-ified" 🙂 The other change would be to require the message composer to do the same of course.

@MightyCreak
Copy link
Author

MightyCreak commented Aug 3, 2017

I don't understand how this (the bug I brought up) could be a feature.

I think that direct links like https://riot.im/develop/#/room/#test:matrix.org or its simpler form #test:matrix.org should be "pill-ified". Maybe even [](https://riot.im/develop/#/room/#test:matrix.org) could be pill-ified.

But when there's text in the square brackets, like that [this room](https://riot.im/develop/#/room/#test:matrix.org), the text is definitely more important than the link. But in this case we could show both the text and that it links to a room, like in this mockup I made (imagine the pointer is on the link, that's why the tooltip is showing):

link_with_text_mockup

Edit: I really like that because we also have a hint of which room it is thanks to the icon. Of course here, a mere "T" is not enough, but most of the rooms I follow do have a specific icon, which makes them easy recognizable.

@lukebarnard1
Copy link

@MightyCreak the problem with this is that it allows easy abuse because someone might put something other than "test". Also, it's not quite in-line with the design for this.

@MightyCreak
Copy link
Author

I personally don't see it as a real threat. On the web, if you're unsure of the site you're browsing, you verify the links. It's the same here but with rooms.

And it's quite easy to detect a fishing here: if there is a room link in the text and it's different than the real room link.

But I get devs don't want to go that way. Thereby I propose to have a different UI for links to room with text. There is already the fact that the text is underlined when there is a text (in my mockup), which remembers that it's a texted link. Maybe the pill could only be on the left. Leave a regular link on the right, but still saying that this link points to a room.

@lampholder
Copy link
Member

Pills exist to:

  • help users discover/share new rooms
  • help users have confidence that the link they're clicking is taking them somewhere they expect to go

We might experiment with more flexible pills in future, but let's stay simple for now - let's not let users replace the pill text with their own text.

However, to support @MightyCreak's usecase, lets render matrix.to links with custom link text as plain ol' regular links, without any pillification.

@jryans jryans added the A-Pills label Jun 23, 2020
@t3chguy t3chguy transferred this issue from element-hq/element-web Mar 29, 2023
@daniellekirkwood
Copy link
Contributor

We've taken a look at this feedback as we're again working on Pills. The solution that we've landed at should now be live in all our public test environments (Nightly builds for example).

I will close this issue as we've made and committed the product decisions on how to handle this use case.

If there's more feedback once playing with the new implementation, please go ahead and open another issue. You're welcome to tag me in it also :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-Composer A-Pills P2 S-Minor Impairs non-critical functionality or suitable workarounds exist T-Defect T-Enhancement
Projects
None yet
Development

No branches or pull requests

7 participants