Commit Graph

8 Commits

Author SHA1 Message Date
Evy Kassirer
38bf407c9a compose_actions: Migrate start() to use pm recipient ids. 2025-05-16 10:51:29 -07:00
Aman Agrawal
97c69e3038 inbox: Show inbox channel view based on user setting.
Fixes: #29574
2025-05-09 15:13:56 -07:00
Lauryn Menard
51bb8eff59 narrow-state: Add only_valid_id boolean param to stream_id function.
Updates narrow_state.stream_id to have a boolean parameter, that
defaults to false. When true, the function will return an ID or
undefined based on the stream data that we have. When false, the
function will return the operand of the channel narrow term when
it's a valid number or undefined if it's not.

Replaces all uses of narrow_state.stream_sub()?.stream_id to
instead use the updated stream_id function with only_valid_id set
to true.
2025-03-06 17:47:57 -08:00
Lauryn Menard
61fa5ccbf1 narrow-state: Return undefined for a channel ID that would be NaN.
When the channel operand would return NaN for the ID value, we now
return undefined, so that there is only one invalid value being
returned by narrow_state.stream_id.
2025-03-06 17:42:50 -08:00
Lauryn Menard
c78d5acddd narrow-state: Refactor and rename is_for_stream_id.
Renames is_for_stream_id to narrowed_to_stream_id, and updates it
to use narrow_state.stream_id for the comparison check instead of
getting the full StreamSubscription object.
2025-03-06 17:42:50 -08:00
roanster007
ca2394495e search: Exclude with operator terms from search terms.
This commit excludes terms containing the `with` operator
from the search terms, since `with` operator is not a search
operator.
2025-02-07 13:03:52 -08:00
bedo
bf05694e59 message_list_view: Move "is_search_view" to narrow_state.
This helper function is only ever used to describe the current view,
so it might as well be in the module for such views.

Also added the test coverage for "is_search_view".
2024-11-25 09:47:10 -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