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

Open posts in the user's home instance? #41

Closed
BenDundon opened this issue Jan 2, 2023 · 5 comments
Closed

Open posts in the user's home instance? #41

BenDundon opened this issue Jan 2, 2023 · 5 comments
Labels

Comments

@BenDundon
Copy link

Currently, posts and notifications open in the originating instance, rather than the user's home instance. This puts an unnecessary step between clicking on a post or notification, and interacting with it, as you then have to manually open it on your home instance.

For example, if I am on mymastodon.example, and get a notification for a post from greg@gregshome.space, clicking on the post in my Nextcloud widget will take me to it on gregshome.space when it should really open in mymastodon.example.

To make this happen, the way the URL is interpreted should be changed. A post's URL is formatted as
http[s]://{original.server}/@{user}/{ID}. When the post is not on the same server as it is being viewed from (i.e., when it is being viewed from a user's home instance), it is instead http[s]://{other.server}/@{user}@{original.server}/{ID}. By re-interpreting the URL before the user clicks on it, we can direct them to viewing the post/profile/notification from their own instance, rather than one they don't have an account on.

I'll work on a PR for this myself, but it's going to take me a while so if anyone wants to jump in with their own solution or comments then please do.

julien-nc added a commit that referenced this issue Jan 29, 2023
…eblog content

Signed-off-by: Julien Veyssier <julien-nc@posteo.net>
@julien-nc
Copy link
Member

Thanks for the issue. This should be fixed in v1.0.5. Could you try it?

@kc9jud
Copy link

kc9jud commented Jan 29, 2023

@julien-nc It works for the "home timeline" widget, but not for the "notifications" widget. Clicking on a notification of a reply opens the reply in the reply author's instance, rather than the user's instance.

julien-nc added a commit that referenced this issue Jan 29, 2023
Signed-off-by: Julien Veyssier <julien-nc@posteo.net>
@julien-nc
Copy link
Member

Thanks for the feedback.
v1.0.6 should bring that for the notifications widget as well. Could you try it?

@BenDundon
Copy link
Author

Yes, it seems to be working as intended now. Thank you very much!

@bear454
Copy link

bear454 commented Sep 22, 2023

🤔 the links from the home timeline widget don't work for me; I always get a 404 page if I use any link except the "More..." link at the bottom.

For example, my widget currently links to:
https://social.librem.one/@nextcloud@mastodon.xyz/111109964371257104

... but to see that toot in the web UI of my home server, the link is actually:
https://social.librem.one/web/statuses/111109964371257104

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants