zulip/web/tests
apoorvapendse ee104ab141 compose: Prompt topic typeahead after selecting stream.
Enable a consecutive topic typeahead after a user selects a stream via the
typeahead menu. Previously, users had to manually enter ">" after selecting
a stream.

Before, encountering ">" returned "topic_jump," which prevented the
topic list from triggering since "topic_jump" indicated the topic was
selected. The implementation is changed to slice the token and process it
in get_candidates to trigger the appropriate typeahead.

Adjustments include changes to regexes for accurate triggering of stream or
topic typeaheads based on the presence of ">" in the current token.

Removes hint for stream mentioning use of ">"
for topic suggestions, although that feature is
still functional.

The hideAfterSelect() function in composebox_typeahead.ts was modified.
This prevents closing the typeahead when a stream is completed.

The TopicSuggestion type is updated to show stream typeahead suggestion
as the first option in the topic list with a privacy icon and no description
in case when no character follows the '>' i.e. when the token ends with '>'.

The edge where stream and topic have the same name is also handled with
the help of a flag.

Add stream as the prefix to topic suggestions in the typeahead.
To make this happen, changes are made in the related handlebars
template.

Update topic list stream option label.
This changes the option label for stream in the topic
list from (mention channel) to (link to channel) as per
https://zulip.com/help/link-to-a-message-or-conversation.

Tests are updated, and a new test is added to validate the behavior.
Test coverage is added for the new `render_stream_topic` method.

Fixes: #32184.
2025-01-29 17:25:19 -08:00
..
lib settings: Show assigned group permissions in permissions panel. 2025-01-27 15:32:15 -08:00
templates popovers: Add hotkey hints support via a new handlebar template. 2024-04-11 15:57:24 -07:00
activity.test.cjs user_circles: Introduce status-based hyphenated classes. 2024-12-13 14:33:23 -08:00
alert_words_ui.test.cjs alert_words_ui test: Excercise the template. 2025-01-07 09:32:52 -08:00
alert_words.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
blueslip_stacktrace.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
bot_data.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
browser_history.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
buddy_data.test.cjs message_list: Avoid rerender of user sidebar when adding msgs. 2025-01-10 11:23:23 -08:00
buddy_list.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
channel.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
color_data.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
common.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
components.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
compose_actions.test.cjs compose: Open the compose box with channel picker. 2024-12-16 10:50:12 -08:00
compose_closed_ui.test.cjs compose_closed_ui: Unify translation strings for reply button label. 2025-01-22 15:55:23 -08:00
compose_fade.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
compose_pm_pill.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
compose_state.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
compose_ui.test.cjs compose: Remove extra blank line before lists. 2025-01-07 14:20:33 -08:00
compose_validate.test.cjs compose: Use can_subscribe_others to check permissions. 2025-01-22 14:27:06 -08:00
compose_video.test.cjs compose_reply_label: Show realm_empty_topic_display_name for topic="". 2025-01-14 13:52:55 -08:00
compose.test.cjs node tests: Extract compose_helpers lib. 2025-01-09 15:08:17 -08:00
composebox_typeahead.test.cjs compose: Prompt topic typeahead after selecting stream. 2025-01-29 17:25:19 -08:00
conversation_participants.test.cjs buddy_list: Use participants data from current message list. 2025-01-10 11:17:46 -08:00
copy_and_paste.test.cjs copy_and_paste: Don't add code syntax if backtick is already present. 2025-01-27 15:30:15 -08:00
deprecated_feature_notice.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
dispatch_subs.test.cjs stream_delete_event: Include only stream IDs in the event. 2025-01-24 17:58:32 -08:00
dispatch.test.cjs settings: Show realm permissions that group has in permissions panel. 2025-01-27 15:32:15 -08:00
drafts.test.cjs drafts_table: Show realm_empty_topic_display_name for topic="". 2025-01-10 14:32:55 -08:00
echo.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
emoji_picker.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
emoji.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
example1.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
example2.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
example3.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
example4.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
example5.test.cjs message_list: Fix message list missing messages. 2024-12-18 10:21:48 -08:00
example6.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
example7.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
example8.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
fenced_code.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
fetch_status.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
filter.test.cjs search: Add support for empty string topic. 2025-01-22 16:09:46 -08:00
fold_dict.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
gear_menu_util.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
hash_util.test.cjs narrow: Handle narrow links with empty topic names. 2025-01-10 14:32:55 -08:00
hashchange.test.cjs hashchange: Convert module to TypeScript. (#32670) 2024-12-11 09:15:18 -08:00
hotkey.test.cjs stream_color: Replace spectrum color picker with native color picker. 2025-01-07 17:27:23 -08:00
i18n.test.cjs node test runner: Prevent Handlebars quirks. 2025-01-07 09:43:33 -08:00
input_pill.test.cjs input_pill: Add disabled flag to make a pill disabled. 2025-01-29 12:36:10 -08:00
internal_url.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
keydown_util.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
lazy_set.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
left_sidebar_navigation_area.test.cjs left_sidebar: Rewrite left sidebar navigation area library. 2025-01-24 17:26:40 -08:00
linkifiers.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
list_cursor.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
list_widget.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
markdown_parse.test.cjs mention: Mentions via subgroup should be highlighted. 2025-01-06 16:53:21 -08:00
markdown.test.cjs markdown: Support message link syntax in local echo. 2024-12-03 10:41:37 -08:00
message_edit.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
message_events.test.cjs message_events tests: Avoid top-level override. 2025-01-07 09:43:33 -08:00
message_flags.test.cjs web: Add parameters to API requests for empty topic name support. 2025-01-10 14:32:55 -08:00
message_list_data.test.cjs message_list: Fix message list missing messages. 2024-12-18 10:21:48 -08:00
message_list_view.test.cjs message_list: Fix message list missing messages. 2024-12-18 10:21:48 -08:00
message_list.test.cjs message_list: Avoid rerender of user sidebar when adding msgs. 2025-01-10 11:23:23 -08:00
message_store.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
message_view.test.cjs empty_feed_notice: Update “stream” to “channel”. 2024-12-05 16:54:38 -08:00
muted_users.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
narrow_local.test.cjs narrow_local test: Introduce test_fixture helper. 2025-01-07 09:43:33 -08:00
narrow_state.test.cjs message_list_view: Move "is_search_view" to narrow_state. 2024-11-25 09:47:10 -08:00
narrow_unread.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
navbar_alerts.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
notifications.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
password.test.cjs password: Add password limit inidcator to form. 2025-01-13 11:53:40 -08:00
peer_data.test.cjs stream_types: Remove email_address from ApiStreamSubscription. 2024-12-30 09:42:26 -08:00
people_errors.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
people.test.cjs user_events: Convert module to TypeScript (#32658) 2024-12-11 09:18:52 -08:00
pill_typeahead.test.cjs group-settings: Move functions used for group settings. 2025-01-24 14:51:51 -08:00
pm_conversations.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
pm_list_data.test.cjs user_circles: Introduce status-based hyphenated classes. 2024-12-13 14:33:23 -08:00
pm_list.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
poll_widget.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
popover_menus_data.test.cjs message_quoting: Rename 'quote_and_reply' to 'quote_message'. 2024-12-04 22:25:14 -08:00
postprocess_content.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
presence.test.cjs popover: Fix misleading time description in right side-bar. 2024-12-11 12:17:41 -08:00
reactions.test.cjs reactions: Remove emoji container when reaction count is 0. 2025-01-24 13:32:35 -08:00
realm_playground.test.cjs requirements: Upgrade Python requirements. 2025-01-14 09:42:16 -08:00
recent_senders.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
recent_view.test.cjs recent_view_search: Add support to search for empty string topics. 2025-01-22 16:09:46 -08:00
reload_state.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
reload.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
rendered_markdown.test.cjs mention: Mentions via subgroup should be highlighted. 2025-01-06 16:53:21 -08:00
resolved_topic.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
rtl.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
saved_snippets.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
scheduled_messages.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
scroll_util.test.cjs scroll_util: Account for $elem not direct child of scroll container. 2025-01-23 15:53:09 -08:00
search_suggestion.test.cjs search: Add support for empty string topic. 2025-01-22 16:09:46 -08:00
search.test.cjs search test: Use override_rewire for is_using_input_method. 2025-01-07 09:43:33 -08:00
server_events.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
settings_bots.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
settings_config.test.cjs notifications: Add help link for "Followed topics" in triggers table. 2024-11-19 13:36:12 -08:00
settings_data.test.cjs stream: Rename can_subscribe_others_to_all_streams. 2025-01-27 11:26:06 -08:00
settings_emoji.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
settings_muted_users.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
settings_org.test.cjs settings: Use can_add_subscribers_group instead of realm policy. 2025-01-22 12:33:58 -08:00
settings_profile_fields.test.cjs settings_profile_fields test: Add mocking helper. 2025-01-07 09:32:52 -08:00
settings_realm_domains.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
settings_user_topics.test.cjs settings_user_topics test: Use explicit override for sorting. 2025-01-07 09:32:52 -08:00
spoilers.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
starred_messages.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
stream_create_subscribers_data.test.cjs stream: Allow non-admins to create channel without subscribing to it. 2025-01-29 12:36:10 -08:00
stream_data.test.cjs stream_data: Use can_add_subscribers_group to check permissions. 2025-01-22 14:27:06 -08:00
stream_edit.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
stream_events.test.cjs settings: Show assigned stream permissions in group permissions panel. 2025-01-27 15:32:15 -08:00
stream_list_sort.test.cjs stream: Use is_recently_active to check active status. 2024-11-27 17:31:06 -08:00
stream_list.test.cjs stream-settings: Use new "can_send_message_group" setting. 2025-01-07 12:17:36 -08:00
stream_pill.test.cjs settings: Use can_add_subscribers_group instead of realm policy. 2025-01-22 12:33:58 -08:00
stream_search.test.cjs stream_search test: Avoid leaky mocking. 2025-01-07 09:43:33 -08:00
stream_settings_ui.test.cjs stream_data: Use can_add_subscribers_group to check permissions. 2025-01-22 14:27:06 -08:00
stream_topic_history.test.cjs get_stream_topics: Add support for empty topic name. 2025-01-22 15:54:11 -08:00
submessage.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
support.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
templates.test.cjs compose: Use an icon for the mac command hotkey hint. 2025-01-06 11:29:38 -08:00
time_zone_util.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
timerender.test.cjs bug fix: Check offsets when browser doesn't canonicalize. 2025-01-22 09:16:50 -08:00
topic_generator.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
topic_link_util.test.cjs topic_link_util: Add [ and ] as characters to escape. 2025-01-25 11:41:25 -08:00
topic_list_data.test.cjs topic-list-item: Show realm_empty_topic_display_name for topic="". 2025-01-10 14:32:55 -08:00
transmit.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
typeahead_helper.test.cjs compose: Prompt topic typeahead after selecting stream. 2025-01-29 17:25:19 -08:00
typeahead.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
typing_data.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
typing_events.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
typing_status.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
ui_util.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
unread.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
upload.test.cjs upload: Use the returned JSON from the server for filename and URL. 2025-01-06 15:25:32 -08:00
user_events.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
user_group_pill.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
user_groups.test.cjs node-tests: Add tests for functions used to check group permissions. 2025-01-28 10:06:31 -08:00
user_pill.test.cjs compose_pill: Show bot icon after bot name. 2025-01-09 11:58:20 -08:00
user_search.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
user_status.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
user_topics_ui.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
user_topics.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
util.test.cjs util: Extract helper function for backoff of retries on error response. 2025-01-29 15:00:23 -08:00
vdom.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
watchdog.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
widgetize.test.cjs blueslip: Require record for more_info. 2025-01-02 17:30:40 -08:00
zblueslip.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00
zjquery.test.cjs tests: Rename the Node tests to *.cjs. 2024-11-13 09:18:56 -08:00