converse.js icon indicating copy to clipboard operation
converse.js copied to clipboard

Web link for XMPP address via xmpp.link

Open yurtpage opened this issue 3 months ago • 11 comments

The biggest problem of the xmpp: links is that they won't work without installed client. So here is web based https://xmpp.link/ similar to Matrix.to or t.me for Telegram. In the PR I added the web link that can be copied by a user shared.

  • [x] Add a changelog entry for your change in CHANGES.md
  • [ ] When adding a configuration variable, please make sure to document it in docs/source/configuration.rst
  • [ ] Please add a test for your change. Tests can be run in the commandline with make check or you can run them in the browser by running make serve and then opening http://localhost:8000/tests.html.

yurtpage avatar Sep 20 '25 22:09 yurtpage

Thank you @yurtpage

What happens if this domain name is not renewed in a few years?

marclaporte avatar Sep 22 '25 00:09 marclaporte

In 99% this won't be a problem because a typical usage is a short living invitations. For the long standing links it's more likely that a user or channel disappear than the domain expires. The service provided by Modern XMPP which is same people as Prosody and Snikket, so it can be trusted to some extent. Sources are here https://github.com/modernxmpp/easy-xmpp-invitation The Kaidan client has own instance of the service on own domain https://i.kaidan.im/ The Conversations client also has "HTTP link" to share your account but it uses own service that is not open sourced.

Sorry, I had to make it configurable and translatable but I can do this only later.

yurtpage avatar Sep 22 '25 19:09 yurtpage

Thanks @yurtpage, but I think a better approach would be to open those links inside Converse (which AFAIK is doable), given that the user is already seeing them inside an instance of Converse.

It doesn't make sense to me to be inside Converse, click an XMPP link and then be taken somewhere else...

jcbrand avatar Sep 24 '25 06:09 jcbrand

Ok then, perhaps material for a "Good first issue"?

marclaporte avatar Sep 24 '25 10:09 marclaporte

@marclaporte There is actually an old ticket for this: https://github.com/conversejs/converse.js/issues/1247

I've added the Good first issue label, although I'm not sure the complexity involved.

jcbrand avatar Sep 24 '25 13:09 jcbrand

This a link to share so you can send to a friend or publish in internet. The Converse.js have nothing to do with them

yurtpage avatar Sep 25 '25 07:09 yurtpage

This a link to share so you can send to a friend or publish in internet. The Converse.js have nothing to do with them

Ok, but the fields that you modified in this PR don't say that, they say "XMPP Address" and with your PR's change the value that is shown for that field is not an XMPP address anymore but a web URL.

If we want to add these links, then I think they should go in a new field, called something like "Shareable link", so that it's clear that this is a URL meant to be shared with others.

This option would also have to be configurable, since Converse can be used in setups where other clients cannot be used, in which case such a link is not usable and confusing.

jcbrand avatar Sep 25 '25 08:09 jcbrand

Let's make two buttons instead "Copy address" and "Copy invitation web link".

yurtpage avatar Sep 26 '25 10:09 yurtpage

Let's make two buttons instead "Copy address" and "Copy invitation web link".

I don't think the buttons should have these labels, instead we can just use normal labels and then have a small button with a copy icon next to the value.

For example: :point_down:

image

jcbrand avatar Oct 07 '25 06:10 jcbrand

I agree, two buttons with copy icon and the "web copy" with 🔗 or 🌐 as an icon or maybe even it should be a "Share ➤" dialog with other IMs (TG, WhatsApp), but not sure if this is possible with web app. The important thing is that links to the https://xmpp.link/#[email protected] should be replaced with xmpp:[email protected] in chat window, so that a user can click and and open chat directly in the Converse without leaving to the xmpp.link

yurtpage avatar Oct 09 '25 17:10 yurtpage

but not sure if this is possible with web app.

See https://developer.mozilla.org/en-US/docs/Web/API/Web_Share_API

deleolajide avatar Oct 10 '25 10:10 deleolajide