-
Notifications
You must be signed in to change notification settings - Fork 2k
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
Reader: Convert post comments to use redux state #3528
Reader: Convert post comments to use redux state #3528
Conversation
@jancavan Could you please work up designs for pingbacks and the empty state? |
I'm having trouble checking this branch out, but here's some feedback while I try to resolve this:
Posting an idea I experimented with, others may want to chime in: To make nested comments easier to scan, thought of adding a left border before the indented comments. Although this makes nested comments much easier to scan, it buries the "Show/Hide" links. Using the horizontal bar from the original mockup alongside the left border only adds clutter. So I say let's just stick to the original design: Still working on pingbacks. For empty state, this may be a good opportunity to add something that's more delightful than a plain form field, but for now can we at least have the comment field say: |
On the actual blogs, I think that message is configurable. Maybe we try to grab it and use it here? from http://blog.lostartpress.com/2016/02/26/prelude-to-perfection/#reply-title |
251dade
to
630b1c7
Compare
@jancavan First of all, thanks for the detailed review.
I kinda like the left border, maybe it should be mouse hover/tap kind of thing? Regarding the empty state, except the 'no comments' state I also mean When there are no more comments to load ( no 'view earlier' link ) it kind of looks empty. |
I think we just drop the bar when there's no need for it. |
What about the comments count |
It's fine if there's no "View earlier" link. We shouldn't add something just because it's empty :) How many comments are displayed until this link pops up? |
@jancavan The link displayed as long as there are more comments to load, |
I think 5 "root" comments is a good number to display by default. Then "View earlier comments" loads up the next 10 or so. Couple of issues I have:
These are issues we can tackle later, but just wanted to note it down here. Displaying it in chronological order is great, but displaying most-liked and most-commented-on comments may also help spark or further a discussion. |
What about something like this for empty state comments? Edit: I'm still leaning towards having nothing but the comment field (but wanted to try it out anyway to see how it'd look) as we should eliminate distractions from this page and just let users focus on reading the post. Changing the value of the comment field to "Be the first to leave a comment" if there aren't any comments yet is I think a good addition though. |
86d644a
to
81e109f
Compare
I've adjusted the initial "page" size to 5, and then load "pages" of 10 comments. Regarding the title, in my opinion the one who decides the format is the pingbacking blog, not us, since I've seen it in various formats (blog name first, then last, with | separator and dash separator, etc.) but i'm no really sure about that. I really like drake with the pencil =) But maybe make him a bit smaller? @blowery Any idea if the comments message available anywhere on wpcom api? |
@samuelclemens Don't worry about it for now. The more I think about it, the less I like it, as the user isn't going to attribute that bit of content back to the source site, but to the Reader itself. I'd rather have it consistent and clean, rather than give the site admin a vector for something confusing. |
@samuelclemens Okay, let's just leave them as they are for now if this isn't doable. The reply bars could use some margin and padding needs to be reduced. Reduced the top padding to |
@samuelclemens Can you please rebase this now that the redux pieces have landed? Thanks! |
02af76e
to
0090192
Compare
Let's forego adding anything to the comment field for now and just revisit it later. This is great, but looking at it more, not a big fan of adding pingbacks really as they look messy. Maybe there's a way to make them less highlighted or something, I'll think about it. |
f2529e7
to
fe50312
Compare
fe50312
to
ff5bc65
Compare
The thing with pingbacks, is that they are included in the total comments count, there is currently no easy way of splitting that count. |
I've looked a bit into how pingbacks work here. Author name (what we display as the link text to the pingbacked blog) is the title extracted directly from the remote blog, it may (or may not) contain anything really. |
Yup, that's why I didn't suggest on removing them, I understand they had to be included to make comment count possible. I was just thinking that maybe they can be less prominent, especially when there's a bunch of them in a row. I'll have to think about it. |
a6798b6
to
4385c93
Compare
My bad, I got confused with the comments after they exceeded 3-levels. That said, we're already not indenting after 3-levels now, but because the count still exists at that point, omitting indentation results to lost hierarchy. It's also not a great experience on mobile because they get really narrow. Like in this example, it's difficult to distinguish if I think we should set a max threshold for counts and indenting. We could keep indenting until 2-levels, but stop at anything beyond that and additional replies will be added to the 2nd-level count. /cc @blowery
Yeah, I was thinking to just keep the main comment form on there at all times. I thought of moving "Cancel reply" to the right which makes it slightly better visually. However, the problem with this is type of UI regardless of where we put cancel is if someone accidentally clicks/taps it, then their comment is gone. It's especially not optimal for mobile. So I think the main comment form should always be there. I think adding the left border back in helps tell the two forms apart in instances where they're next to each other. Example: Ideally, the main comment form should be at the very top of the comment listing, but since we order them chronologically, it'll feel disjointed if they type a comment up top and they appear at the bottom after submitting. I also thought of just anchoring them to their comment after submitting, but doesn't make for a great experience either. |
That makes sense but it also makes my head hurt. It's breaking expectations and possibly conversational flow in the original site. Though perhaps it's fine in practice... Just imagine some our p2 threads with only two levels of conversation. :) |
Right, make sense, but the nesting isn't scalable and only solves the problem up to a certain point so we still need to set a limit somehow. I guess indenting up to 3-levels (instead of 2) isn't too bad. And normally, the replies that are several levels deeper are no longer directly relevant to the "root" comment so should be fine. |
I noticed that the native apps already do this condensing of levels and limit it to 3 total (1 main, two nested). |
I'll be continuing this work in a new PR - #4817. |
The required modifications for reader's post comments react components to work with redux state.
WIP,
Dependent on #3143 (it included here meanwhile, for the whole thing to work)Still needs:
CommentStore
CommentLikeStore
to redux stateWill close #967, #2839