Could we get the link to post replies in mobile view?

AI-generated summary

Users are discussing the lack of visibility for replies in mobile view on Discourse, specifically the absence of a notification or link indicating when a post has been replied to. 1101010 highlights the difficulty of tracking replies in long threads on mobile, noting that while desktop shows this information, mobile does not. jopes supports this, showing a desktop example. awesomerobot explains that mobile’s space constraints make nested replies challenging, suggesting alternatives like a “jump to first reply” button or a toggle to hide non-direct replies. mcwumbly proposes a modal dialog for replies, similar to user cards, which could work on both mobile and desktop. Ellibereth explores implementing this via a plugin, asking for guidance on modifying the toggleReplyAbove action in the post widget, as current attempts with attachWidgetAction have failed 12.

Or if we can’t get that, can we maybe get a notification that someone HAS replied to a post?

I mean this thing at the bottom of posts
image

When you’re scrolling through a large post on mobile you can come across someone asking a question or making a statement that you could respond to but you don’t want to if it’s already been addressed. But if there are 100+ posts to scroll through it’s not that easy and in the course of doing that you can lose track of the original post you wanted to reply to.

If we could see in mobile view that there’d been replies that would be helpful.

Thanks

1 Like

You do get notified of post replies, if you’re the post author. Do you mean notifications when you are not the post author?

1 Like

Yeah, if I’m browsing the thread and there are 100+ replies below it and I don’t want to post a reply answering the question or addressing the post’s points if someone else already did.

The only way to know in mobile is to read the entire thread which isn’t always convenient and then scroll all the way back.

We can link back to what a post replies to just not the replies to it.

It’s not about my posts because I don’t usually need to answer my own questions! :grin:

Also I think the link forward to replies from a post is one of Discourse’s best features, retaining threading in a linear format. So it’s a shame this aspect is missing in mobile view.

hello

I would like to second this request. on desktop it shows when a post has a reply, like so:

however on mobile, it does not show this information.

7 Likes

We don’t do nested posts at all on mobile, we’re constrained on space so it’s much harder to indent the replies so they appear to be children as we do on desktop.

We do a “jump-to” link on the in-reply-to button because it’s always referencing a single post:

12%20PM

Since there can be multiple replies to a post (maybe there are 100!), we can’t really have a single “jump-to” link there.

It might be possible to jump to the first reply, and have a floating “jump to next reply” button? You could then use the in-reply-to button on any of those replies to get back to where you were…

Another idea that’s come up before, is having the “X replies” button hide the other posts that aren’t direct replies (similar to our “summarize this topic” filter within the topic map on long topics). You could then toggle replies to a specific post quickly.

4 Likes

I wonder if it’d be worth exploring having the replies and “in reply to” posts show up in a dialog like the user cards rather than in the post stream. That could potentially work on mobile and on desktop as an alternative to the current UX. Could something like that be done as a theme component if someone wanted to experiment with that idea?

6 Likes

That is a very good idea, would the pop up panel be scrollable?

3 Likes

Hmm… yeah, I hadn’t thought that far ahead, but it would probably have to be or you’d have to scroll the whole page to read multiple posts.

If someone gets to the point of trying it out we could see where the rough edges are.

Honestly I think just a link to first reply and then maybe (x other replies) after if that’s a simple one? This is as much about improving site feedback and if you come back to a thread with lots of replies this info would help.

1 Like

Is this doable with a theme component or would it have to be a plugin? A simple version 1 would probably just take the post content and show it in a modal without any styling?

1 Like

Started trying to work on a plugin for this.

I’m looking to modify the “toggleReplyAbove” action. It looks to be in the post widget, but if I use the following code to try and replace the action I don’t see any effect - nothing is printed to console and it behaves as normal:

api.attachWidgetAction('post', 'toggleReplyAbove', () => {
    console.log('toggle triggered');
  });

In the post widget code, it looks like the toggleReplyAbove function is defined inside the created widget post-article , but that doesn’t seem to be modifiable with attachWidgetAction since the following code trying to modify that widget results in the error Uncaught TypeError: Cannot read property 'class' of undefined :

api.attachWidgetAction('post-article', 'toggleReplyAbove', () => {
    console.log('toggle triggered');
  });

I’m able to overwrite the “like” action on post-menu fine as described here Updating Discourse Plugins, taking the first step - #9 by eviltrout. Where should I be attaching the widget action to overwrite the toggleReplyAbove action?

1 Like