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

Feat: Add search message tab to the right sidebar #14125

Open
wants to merge 11 commits into
base: main
Choose a base branch
from

Conversation

DorraJaouad
Copy link
Contributor

@DorraJaouad DorraJaouad commented Jan 13, 2025

☑️ Resolves

🖌️ UI Checklist

🖼️ Screenshots / Screencasts

Recording.2025-01-15.091600.mp4

🚧 Tasks

  • Check nexttick effect in MessagesList (scrollToBottom and focusMessage are now at the same time)
  • Remove types

🏁 Checklist

  • 🌏 Tested with different browsers / clients:
    • Chromium (Chrome / Edge / Opera / Brave)
    • Firefox
    • Safari
    • Talk Desktop
    • Not risky to browser differences / client
  • 🖌️ Design was reviewed, approved or inspired by the design team
  • ⛑️ Tests are included or not possible
  • 📗 User documentation in https://github.com/nextcloud/documentation/tree/master/user_manual/talk has been updated or is not required

@DorraJaouad DorraJaouad requested a review from Antreesy January 13, 2025 17:04
@DorraJaouad DorraJaouad self-assigned this Jan 13, 2025
@DorraJaouad DorraJaouad added this to the 🌿 Next Beta (31) milestone Jan 13, 2025
JungleDruid and others added 11 commits January 14, 2025 14:46
Signed-off-by: JungleDruid <3953982+JungleDruid@users.noreply.github.com>
Signed-off-by: JungleDruid <3953982+JungleDruid@users.noreply.github.com>
…ional tab

Signed-off-by: Dorra Jaouad <dorra.jaoued7@gmail.com>
Signed-off-by: Dorra Jaouad <dorra.jaoued7@gmail.com>
… scale instead of time. Change to native component

Signed-off-by: Dorra Jaouad <dorra.jaoued7@gmail.com>
Signed-off-by: Dorra Jaouad <dorra.jaoued7@gmail.com>
Signed-off-by: Dorra Jaouad <dorra.jaoued7@gmail.com>
Signed-off-by: Dorra Jaouad <dorra.jaoued7@gmail.com>
Signed-off-by: Dorra Jaouad <dorra.jaoued7@gmail.com>
@DorraJaouad DorraJaouad force-pushed the feat/11130/search-messages branch from e1a4ae8 to 584b53c Compare January 14, 2025 15:56
@DorraJaouad DorraJaouad changed the title Add search message tab to the right sidebar Feat: Add search message tab to the right sidebar Jan 15, 2025
@DorraJaouad DorraJaouad marked this pull request as ready for review January 15, 2025 08:17
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.

code-wise OK, let's finish the critical things and proceed in follow-ups

src/types/index.ts Show resolved Hide resolved
:title="t('spreed', 'Back')"
@click="showSearchMessagesTab = false">
<template #icon>
<IconArrowLeft :size="20" />
Copy link
Contributor

Choose a reason for hiding this comment

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

nitpick: this would probably look wrong in RTL layout. But we have to reverse all such icons (follow-up)

body[dir="rtl"] .material-design-icon.arrow-left-icon {
    transform: scaleX(-1);
}

src/components/RightSidebar/RightSidebar.vue Show resolved Hide resolved

const token = computed(() => store.getters.getToken())
const participantsInitialised = computed(() => store.getters.participantsInitialised(token.value))
const participants = computed<UserFilterObject>(() => {
Copy link
Contributor

Choose a reason for hiding this comment

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

Person could have left the conversation.
To fix: filter out guests, circles, groups, e.t.c. - they don't work

Follow-up: use /contactsmenu/contacts endpoint as in UnifiedSearch (require loading callback: https://vue-select.org/api/events.html#search)
Then we could get rid of vuex store usage here


try {
cancelSearch.value('canceled')
const { request, cancel } = CancelableRequest(searchMessages)
Copy link
Contributor

Choose a reason for hiding this comment

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

Atm it's not made correctly, but we could use 'as' for requests. Check NewMessageChatSummary.vue for reference

Suggested change
const { request, cancel } = CancelableRequest(searchMessages)
type SearchMessageCancelableRequest = {
request: (payload: SearchMessagePayload) => UnifiedSearchResponse,
cancel: () => void,
}
const { request, cancel } = CancelableRequest(searchMessages) as SearchMessageCancelableRequest

<template v-if="searchResults.length !== 0">
<NcListItem v-for="item of searchResults"
:key="`message_${item.attributes.messageId}`"
:data-nav-id="`message_${item.attributes.messageId}`"
Copy link
Contributor

Choose a reason for hiding this comment

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

Follow-up: this need a composable to make arrow navigation work

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

Successfully merging this pull request may close these issues.

Search inside Talk App doesn't include talk messages
3 participants