Commit Graph

35 Commits

Author SHA1 Message Date
Pratik Chanda
81ca9e1b36 message_list: Hide group DMs where everyone is muted.
This commit hides group DMs where all recipients are muted from
different views.

Fixes: zulip#34886.

Co-authored-by: Aman Agrawal <amanagr@zulip.com>
2025-10-20 15:42:15 -07:00
Evy Kassirer
10a815cae7 stream_data: Rename add_sub to add_sub_for_tests. 2025-09-30 12:52:47 -07:00
Lauryn Menard
d82083ca24 filter: Add title for an unknown user for the "sender" narrow case.
Previously, the message header for the "Messages sent by" view for
an invalid or unknown user was the value of the "sender" operand,
which was not a valid/known user email.

Now we show a standard title in the message header for this case:
"Messages sent by unknown user".
2025-09-26 10:16:19 -07:00
Karl Stolley
a64276c58f media: Replace legacy .message_inline_image class.
This introduces two new replacement classes, depending on
whether the inner content is an image or a video.
2025-09-17 13:25:50 -07:00
Anders Kaseorg
40a022dcc3 zephyr: Remove Zephyr mirroring support.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2025-09-16 11:18:18 -07:00
Pratik Chanda
acc5cffae4 filter: Use encoding for channel/topic narrow for url redirect.
Earlier, when generating redirect url for search exit, we did not
encode the url in case of topic narrows. We expect some characters
to be replaced when generating hash.

This commit encodes the url for channels and topic narrows and
prevents redirecting to broken hashes.
2025-08-29 10:24:34 -07:00
Kislay Verma
67ca49488f tests: Use make_realm to create type-correct realm objects.
Another step in the direction of improving node tests
and using type-correct organic data as much as possible.
2025-08-28 11:35:07 -07:00
Anders Kaseorg
5d13749d26 eslint: Fix @typescript-eslint/no-unnecessary-type-conversion.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2025-08-14 21:37:50 -07:00
Pratik Chanda
40ff1220ef filter: Implement web public channels filter for suggestions.
We already had web-public support in narrow by_channels.

This commit implements the web-public support for actual user
search.
2025-08-12 15:30:11 -07:00
Pratik Chanda
20889b3f78 filter: Enable channels operator for can_apply_locally.
Earlier, validating messages on given narrow skipped for channels
operator.

This commit adds channels operator support for checking if message
corresponds to given search term.
2025-08-12 15:18:11 -07:00
Tim Abbott
0f19fda610 filter: Mark messages as read in -is:dm view.
We avoid doing the more complex composability here, since that's
potentially risky.

Fixes #25113.
2025-07-18 16:35:30 -07:00
opmkumar
722a2cce9d filter: Update title for spectators when using channels:public filter. 2025-07-15 10:48:39 -07:00
Evy Kassirer
404ad6c518 search: Update description string for mentions. 2025-07-08 10:02:34 -07:00
Evy Kassirer
f7af0f0879 search: Update description string for channel terms. 2025-07-08 10:02:34 -07:00
PieterCK
1e4b0bdfea filter: Rename supports_collapsing_recipients.
This renames the function to `contains_no_partial_conversations`. The
function initially was created to determine whether its appropriate to
collapse recipient/sender headings. Since then it has many other use
cases, so it's renamed to clearly describe what it does instead.
2025-07-01 16:14:56 -07:00
Shubham Padia
3dc54a10d7 filter: Do not set anchor as first_unread for starred messages view.
Fixes
https://chat.zulip.org/#narrow/channel/9-issues/topic/Starred.20messages.20view.20performance/near/2184251.
Anchor for starred messages was `first_unread` and the query to find
first_unread in a user's starred messages can turn out to be expensive.
This commit ensures that we default to newest instead since first_unread
is not of important for the starred messages view.
By excluding starred messages from using `first_unread`, it will default
to newest based on the logic in message_view.ts.
2025-06-09 16:21:09 -07:00
Evy Kassirer
fa03c42009 search: Show correct description string for public channels.
Previously, typing "channels: public" would show "Channels public"
in the typeahead, which was especially confusing because we'd show
"All public channels" until the term was completely typed out.
2025-06-06 18:04:48 -07:00
Evy Kassirer
b63b4a26c8 filter: Don't lowercase search operands.
Searching e.g. "NASA" would put "nasa" in the search bar if you
selected "search for NASA" in the typeahead. This probably looks
weird to users, so let's not lowercase search operands.
2025-06-05 16:10:02 -07:00
Harsh
bdf2317b40 filter: Use specific title for DM conversation with self.
For the DM conversation with the current user, show "Messages with
yourself" for the title, which is determined by the filter for the
message list view.

Co-authored-by: Lauryn Menard <lauryn@zulip.com>
2025-04-28 20:50:51 -07:00
Aman Agrawal
c5425a6dab filter: Add more asserts for has_exactly_channel_topic_operators. 2025-04-10 11:52:04 -07:00
Aman Agrawal
1b012f1eb3 filter: Add function to check if narrow has only 'channel' term.
s
2025-04-10 11:51:20 -07:00
evykassirer
08ed639763 filter: Validate and parse sender:me when turning into a pill.
Fixes #31315.

We want to parse sender:me with the email when turning it into
a pill, but not before then so that "Sent by me" is still the
search string in the suggestions.
2025-03-13 13:54:14 -07:00
opmkumar
4f462970e4 search: Add is-muted search operator.
Add the `is:muted` search operator.
`-is:muted` is an alias for the `in:home` operator.

Co-authored-by: Kenneth <Kenneth012004@outlook.com>

Fixes #16943
2025-03-11 23:18:07 -07:00
opmkumar
4becea3993 search: Fix -in:home muting logic.
Previously, mentions from muted channels were incorrectly excluded when
narrowing down to `-in:home`. Additionally, messages from all muted
topics were missing in the results.
This commit solves the above listed issues.

The relevant legacy logic being removed dates to when we didn't
support unmuting or following topics.
2025-03-11 23:18:07 -07:00
Niloth P
6ba3bdc05d filter: Add may_contain_multiple_conversations.
Preparatory commit for #31292.
2025-03-08 17:38:49 -08:00
sanchi-t
423ee27a23 stream_privacy: Add archive icon for archived channels.
Archived channels are now displayed with an archived
icon.
2025-03-07 18:08:41 -08:00
Harsh
411fd9c4fe navbar: Show "Muted user" instead of muted user's name.
This commit shows the string "Muted user" instead of
muted user's name in DM's navbar.

fixes: #33673
2025-03-04 15:43:25 -08:00
opmkumar
1d33214b55 narrow: Allow spectators to use is:resolved.
Fixes #33568.
2025-03-04 11:37:21 -08:00
Maneesh Shukla
d8f609d088 unresolved: Add support for searching for unresolved topics.
Fixes: #31725.
2025-02-24 09:59:30 -08:00
Maneesh Shukla
3f88fe5903 resolved: Rename "Topics marked as resolved" -> "Resolved topics".
Fixes part of #31725.
2025-02-24 09:59:21 -08:00
roanster007
f3fbf314e2 echo: Update channel-topic link to permalink upon new message arrival.
This commit updates the traditional url of a channel-topic narrow
to topic permalink upon arrival of new message in the narrow, by
using the `with` operator on it.

The requirement for this change arises when we navigate to an
empty topic. Since it has no messages yet, we fallback to the
traditional channel-topic links. However, when a new message
arrives to this empty topic, we want the url to live update to
a permalink of the narrow.

This is done as an effort to make sure channel-topic narrows
always contain `with` term.
2025-02-13 12:40:37 -08:00
Prakhar Pratyush
033c706a03 search: Add support for empty string topic.
This commit adds support to display `realm_empty_topic_display_name`
value (in italics) in the search suggestions & search input pills
for topics having the actual value of empty string.
2025-01-22 16:09:46 -08:00
Aman Agrawal
91714b5f1b user_topics: Extract method to check if topic is visible in-home. 2024-12-08 18:34:28 -08:00
Aman Agrawal
e5db6ac557 filter: Fix check for is personal filter. 2024-12-02 16:41:36 -08:00
Anders Kaseorg
687f1b1651 tests: Rename the Node tests to *.cjs.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-11-13 09:18:56 -08:00