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

Fix(LeftSidebar): Show hint when no filtered results #10679

Merged
merged 1 commit into from
Oct 19, 2023

Conversation

DorraJaouad
Copy link
Contributor

@DorraJaouad DorraJaouad commented Oct 11, 2023

☑️ Resolves

Hint component was at the bottom of the LeftSidebar because the ConversationListVirtual is always present at full height.

  • Added utility for conversation
  • Refactored filter handling in leftSidebar
  • Added captions for unread messages and unread mentions filter
  • Add the empty content when there are no results

The filtering logic :
"Standard Condition" : if conversation has call , mentions / unread message and is currently active in the chat view.
"Special Condition" : if conversation is currently active, the only one in the list and has no flag.

  • At the moment the filter is first applied:

    • Apply Standard Condition.
    • Check Special Condition:
      • If yes, hide the current conversation by returning an empty list. This handles the case of clicking the filter initially and showing empty content if there are 0 unread conversations
      • If no, show the filtered list
  • After filters are applied (during subsequent filter navigation):

    • Apply Standard Condition.

🖌️ UI Checklist

🖼️ Screenshots / Screencasts

🏚️ Before 🏡 After Rare but possible ( empty list)
image image image

🚧 Tasks

  • Code review

🏁 Checklist

@DorraJaouad DorraJaouad force-pushed the fix/noid/show-hint-when-no-matches-found branch from 0a32442 to 5587b00 Compare October 11, 2023 20:08
src/views/Dashboard.vue Outdated Show resolved Hide resolved
src/mixins/conversation.js Outdated Show resolved Hide resolved
src/components/LeftSidebar/LeftSidebar.vue Outdated Show resolved Hide resolved
src/components/LeftSidebar/LeftSidebar.vue Outdated Show resolved Hide resolved
src/components/LeftSidebar/LeftSidebar.vue Outdated Show resolved Hide resolved
@DorraJaouad DorraJaouad force-pushed the fix/noid/show-hint-when-no-matches-found branch from 5587b00 to 98c799d Compare October 12, 2023 13:14
src/utils/conversation.js Outdated Show resolved Hide resolved
src/utils/conversation.js Outdated Show resolved Hide resolved
src/components/LeftSidebar/LeftSidebar.vue Outdated Show resolved Hide resolved
src/components/LeftSidebar/LeftSidebar.vue Outdated Show resolved Hide resolved
src/components/LeftSidebar/LeftSidebar.vue Outdated Show resolved Hide resolved
src/components/LeftSidebar/LeftSidebar.vue Outdated Show resolved Hide resolved
src/components/LeftSidebar/LeftSidebar.vue Outdated Show resolved Hide resolved
src/components/LeftSidebar/LeftSidebar.vue Outdated Show resolved Hide resolved
src/components/LeftSidebar/LeftSidebar.vue Outdated Show resolved Hide resolved
@DorraJaouad DorraJaouad force-pushed the fix/noid/show-hint-when-no-matches-found branch from 407deb0 to 79eec40 Compare October 18, 2023 18:51
Copy link
Contributor

@Antreesy Antreesy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't forget to sqash commit, your first one was completely overwritten

src/components/LeftSidebar/LeftSidebar.vue Outdated Show resolved Hide resolved
src/utils/conversation.js Show resolved Hide resolved
src/components/LeftSidebar/LeftSidebar.vue Outdated Show resolved Hide resolved
@DorraJaouad DorraJaouad force-pushed the fix/noid/show-hint-when-no-matches-found branch from 79eec40 to 5ee5aa7 Compare October 19, 2023 13:30
Copy link
Contributor

@Antreesy Antreesy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Left a last note (promise), how we can avoid going through the conversation list twice
Apart from that, looks and works nice!

src/components/LeftSidebar/LeftSidebar.vue Outdated Show resolved Hide resolved
@DorraJaouad DorraJaouad force-pushed the fix/noid/show-hint-when-no-matches-found branch from 5ee5aa7 to fa9a200 Compare October 19, 2023 15:52
@DorraJaouad DorraJaouad enabled auto-merge October 19, 2023 16:12
…ogic.

Signed-off-by: DorraJaouad <dorra.jaoued7@gmail.com>
@DorraJaouad DorraJaouad force-pushed the fix/noid/show-hint-when-no-matches-found branch from fa9a200 to 427c636 Compare October 19, 2023 16:12
@DorraJaouad DorraJaouad merged commit 3f6748f into master Oct 19, 2023
34 checks passed
@DorraJaouad DorraJaouad deleted the fix/noid/show-hint-when-no-matches-found branch October 19, 2023 17:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants