zulip icon indicating copy to clipboard operation
zulip copied to clipboard

recent_topics: Add Private message to recent_topics.

Open madrix01 opened this issue 4 years ago • 63 comments

We add Private message to the Recent topics to make it an all-encompassing overview of everything that's happening for a user.

image Fixes #19449

madrix01 avatar Jan 23 '22 13:01 madrix01

@madrix01 thanks for working on this! Left some comments.

amanagr avatar Feb 04 '22 09:02 amanagr

@amanagr I have made most of the changes. I'm facing problem with keyboard navigation. Recent topics - Zulip Dev - Zulip

madrix01 avatar Feb 04 '22 16:02 madrix01

It got solved!!

madrix01 avatar Feb 06 '22 09:02 madrix01

@amanagr I have update the commit with private tests as well, can you please have a look at it?

madrix01 avatar Feb 11 '22 12:02 madrix01

@madrix01 did you lose all your changes 😅 ? I only see some relevant code here. git reflog can help you recover those changes.

amanagr avatar Feb 12 '22 08:02 amanagr

@amanagr no, they are all present in this commit as time asked me to break the commit into small changes, so it would be easy to review the code and add tests. Discussed here, all the changes you have suggested are present in the above mentioned commit.

madrix01 avatar Feb 12 '22 08:02 madrix01

Why is that commit not part of this PR?

amanagr avatar Feb 12 '22 08:02 amanagr

@amanagr It was the part of the pr. I rebased this pr, as i was to break single commit into small commits.

madrix01 avatar Feb 12 '22 09:02 madrix01

So, did you open a PR for the rest of the code? I should be able to test the complete thing. :) It fine to just push remaining commits in this PR too if you haven't done so.

amanagr avatar Feb 14 '22 04:02 amanagr

@amanagr @timabbott apologies for the delay. I have update all the code here including the ui.

madrix01 avatar Feb 14 '22 13:02 madrix01

@madrix01 you'll need to debug the node tests for this before we can merge it.

timabbott avatar Feb 26 '22 00:02 timabbott

@timabbott I have tweaked the tests current tests, they work with full coverage, but special tests for private messages are yet to be added.

madrix01 avatar Feb 26 '22 16:02 madrix01

This needs a rebase for our recent topics PRs merged recently, but should otherwise be good to test-deploy on chat.zulip.org.

timabbott avatar Mar 03 '22 00:03 timabbott

Also, is the first commit something we could merge independently of the second one to reduce the size of this PR and thus merge conflict risk? I think we might need some checks to prevent trying to display those without type="stream" in order to do that.

timabbott avatar Mar 03 '22 00:03 timabbott

@timabbott

Also, is the first commit something we could merge independently of the second one to reduce the size of this PR and thus merge conflict risk? I think we might need some checks to prevent trying to display those without type="stream" in order to do that.

Yes this commit will only allow message with all the type to pass in process_messages() in recent_topics_data.js but PMs will not be rendered in the UI, there is a check for filtering out messages with only type === "stream"

madrix01 avatar Mar 03 '22 17:03 madrix01

I just pulled down the PR, and it's not quite ready for test deployment. I'll post my comments here.

alya avatar Mar 08 '22 20:03 alya

The unread counts need to be aligned properly: Screen Shot 2022-03-08 at 12 00 04 PM

alya avatar Mar 08 '22 20:03 alya

The icons (envelope and people) are too dark in light mode; I think they'd look good matching the background of the unread counts.

In dark mode, let's try having the icons match the colors for the envelope/people icons in the left sidebar.

alya avatar Mar 08 '22 20:03 alya

I'm also getting this error if I click around: Screen Shot 2022-03-08 at 12 13 28 PM

alya avatar Mar 08 '22 20:03 alya

Otherwise looks good so far; I can test more when the error is no longer popping up. Thanks!

alya avatar Mar 08 '22 20:03 alya

@alya I'll try to solve it and update the PR ASAP. Thank you!

madrix01 avatar Mar 09 '22 04:03 madrix01

The unread counts need to be aligned properly: Screen Shot 2022-03-08 at 12 00 04 PM

Absence of mark as read and mute topic icon was causing this UI bugs, I have added margin to the right to match the unread in the topics. image

madrix01 avatar Mar 09 '22 11:03 madrix01

I'm also getting this error if I click around: Screen Shot 2022-03-08 at 12 13 28 PM

Can you show me the steps to generate this error?

madrix01 avatar Mar 09 '22 12:03 madrix01

Hm, I'm not getting the error anymore, so maybe my dev environment somehow got into a weird state. Could you push your other fixes? Thanks!

alya avatar Mar 10 '22 07:03 alya

@alya @timabbott I have pushed the following changes

  • made pm row unread counts align with topic row
  • fixed bugs with keyboard navigation as there are only 2 columns with PM row and 4 with columns row
  • added function to differentiate between Pm and topic row.

Will add more ui changes soon.

Thank you!

madrix01 avatar Mar 10 '22 16:03 madrix01

@alya image Icons in light mode

image Icons in dark mode

madrix01 avatar Mar 11 '22 09:03 madrix01

@alya I have updated the PR with the changes you suggested can you please have a look at it? Thank you !!

madrix01 avatar Mar 11 '22 09:03 madrix01

Thanks! I'm still seeing bad unread counter alignment in narrow screen mode: Screen Shot 2022-03-15 at 10 43 30 PM

alya avatar Mar 16 '22 05:03 alya

@madrix01 Could you please go through the manual review checklist at https://zulip.readthedocs.io/en/latest/contributing/code-reviewing.html#manual-testing, as there are a lot of opportunities for UI glitches on this one?

alya avatar Mar 16 '22 05:03 alya

Ok, I'll fix that, Are you facing any bug or glitches with the keyboard navigation ?

madrix01 avatar Mar 16 '22 05:03 madrix01