zulip/frontend_tests/node_tests
Yash Rathore 345616ad02
user_sidebar: Set personal presence dot based on the user's settings. (#20376)
If a user chooses to not broadcast their presence status to others, we
still show the user as available in their own user sidebar. Instead, one's
own availability should appear the same as it does for other users.

With tweaks from YashRE42: rebasing to use user_settings instead of
page_params, as introduced in the series of commits ending with
8755a76cf6, adding code comments and
moving the redraw call to `server_events_dispatch.js`.

Fixes part of #18846.  Further work is required to display the user's own idle
status properly to complete #18846.

Co-authored-by: YashRE42 <33805964+YashRE42@users.noreply.github.com>

Co-authored-by: Ganeshprasad Biradar <biradarganesh25@gmail.com>
2021-12-03 16:20:20 -08:00
..
lib events: Live update stream-privacy choices on changing enable_spectator_access. 2021-12-01 13:01:19 -08:00
templates Revert "templates: Add {{#let}} block helper." 2021-04-13 17:41:10 -07:00
activity.js user_sidebar: Set personal presence dot based on the user's settings. (#20376) 2021-12-03 16:20:20 -08:00
alert_words.js people: Stop queries about current user in web_public_view. 2021-06-22 16:56:34 -07:00
alert_words_ui.js node tests: Only expose mock_template via run_test. 2021-06-27 23:00:34 -04:00
billing.js billing: Migrate to Stripe hosted checkout page. 2021-11-05 17:23:10 -07:00
billing_helpers.js billing: Migrate to Stripe hosted checkout page. 2021-11-05 17:23:10 -07:00
blueslip_stacktrace.js dependencies: Upgrade JavaScript dependencies. 2021-05-10 18:07:13 -07:00
bot_data.js node tests: Use {override} in run_test. 2021-06-16 12:55:53 -04:00
browser_history.js node_tests: Mock window.location with JSDOM. 2021-10-14 12:47:43 -07:00
buddy_data.js user_sidebar: Set personal presence dot based on the user's settings. (#20376) 2021-12-03 16:20:20 -08:00
buddy_list.js zjsunit: Wire $ to zjquery by default. 2021-06-16 12:55:53 -04:00
channel.js lint: Fix typos found by codespell. 2021-10-19 16:51:13 -07:00
color_data.js js: Convert static/js/color_data.js to ES6 module. 2021-02-28 14:23:00 -08:00
colorspace.js colorspace: Remove unused methods. 2021-05-21 16:53:30 -07:00
common.js refactor: Use variables to get TypeScript type narrowing. 2021-06-22 09:09:36 -07:00
components.js ts: Convert components module to TypeScript. 2021-07-05 17:04:06 -07:00
compose.js compose: Stop propagating clicks for compose control buttons. 2021-12-03 14:29:26 -08:00
compose_actions.js compose: Add missing translation tag to quoting placeholder. 2021-11-28 07:00:46 -08:00
compose_closed_ui.js zjsunit: Wire $ to zjquery by default. 2021-06-16 12:55:53 -04:00
compose_error.js compose: Use loading spinner as loading indicator. 2021-12-02 15:11:15 -08:00
compose_fade.js zjsunit: Wire $ to zjquery by default. 2021-06-16 12:55:53 -04:00
compose_pm_pill.js input_pill: Customize pills for deactivated users. 2021-06-25 18:06:42 -07:00
compose_state.js node tests: Use {override} in run_test. 2021-06-16 12:55:53 -04:00
compose_ui.js compose: Add missing translation tag to quoting placeholder. 2021-11-28 07:00:46 -08:00
compose_validate.js compose: Use loading spinner as loading indicator. 2021-12-02 15:11:15 -08:00
compose_video.js compose: Stop propagating clicks for compose control buttons. 2021-12-03 14:29:26 -08:00
composebox_typeahead.js eslint: Fix unicorn/prefer-code-point. 2021-12-03 14:33:53 -08:00
copy_and_paste.js zjsunit: Optionally exercise template code. 2021-06-15 12:33:26 -04:00
deprecated_feature_notice.js deprecated_feature_notice: Migrate modal to dialog_widget. 2021-10-29 16:09:39 -07:00
dispatch.js user_sidebar: Set personal presence dot based on the user's settings. (#20376) 2021-12-03 16:20:20 -08:00
dispatch_subs.js subs: Rename subs.js to stream_settings_ui.js. 2021-07-09 09:38:58 -07:00
drafts.js drafts: Don't notify if contents of draft have not been changed. 2021-12-01 12:03:17 -08:00
dropdown_list_widget.js MDLW: Render tippy tooltip once the selected items surpasses the limit. 2021-07-29 10:09:03 -07:00
echo.js compose: Make the route of message sending through drafts. 2021-09-07 14:36:05 -07:00
emoji.js buddy_list: Show still image for animated emojis. 2021-09-12 16:24:29 -07:00
emoji_picker.js emoji: Enable Japanese characters in the symbol section. 2021-08-31 06:42:36 -07:00
event_status.js frontend_tests: Skip broken event_status test. 2021-11-05 21:04:47 -07:00
example1.js custom_check: Avoid use of assert to avoid confusion with assert.equal. 2021-06-10 09:15:57 -07:00
example2.js refactor: Extract message_helper.process_new_message. 2021-03-29 14:53:57 -07:00
example3.js node_tests: Replace `set_global` with `mock_esm` in example4.js. 2021-07-22 09:47:47 -04:00
example4.js node_tests: Replace `set_global` with `mock_esm` in example4.js. 2021-07-22 09:47:47 -04:00
example5.js node tests: Use {override} in run_test. 2021-06-16 12:55:53 -04:00
example6.js node tests: Use {override} in run_test. 2021-06-16 12:55:53 -04:00
example7.js node tests: Use {override} in run_test. 2021-06-16 12:55:53 -04:00
example8.js lint: Fix typos found by codespell. 2021-10-19 16:51:13 -07:00
fenced_code.js node tests: Move test to fenced_code.js. 2021-03-12 11:18:44 -05:00
fetch_status.js zjsunit: Lift restriction against mocking third party modules. 2021-03-12 10:06:30 -08:00
filter.js filter: Show typeahead suggestions if search query has search filters. 2021-11-29 16:20:29 -08:00
fold_dict.js node_tests: Fix incorrect usage of assert.throws. 2021-08-10 13:18:53 -07:00
hash_util.js hash_util: Remove dependency on narrow_state module. 2021-11-29 13:30:18 -08:00
hashchange.js node_tests: Mock window.location with JSDOM. 2021-10-14 12:47:43 -07:00
hotkey.js eslint: Fix unicorn/prefer-code-point. 2021-12-03 14:33:53 -08:00
i18n.js node_tests: Import templates.js only once for all tests. 2021-10-13 09:49:32 -07:00
input_pill.js node tests: Only expose mock_template via run_test. 2021-06-27 23:00:34 -04:00
keydown_util.js keydown_util: Use Event.key instead of deprecated properties. 2021-05-27 23:33:17 -07:00
lazy_set.js custom_check: Avoid use of assert to avoid confusion with assert.equal. 2021-06-10 09:15:57 -07:00
lightbox.js zjsunit: Wire $ to zjquery by default. 2021-06-16 12:55:53 -04:00
linkifiers.js refactor: Extract linkifier non-settings logic from `markdown.js`. 2021-05-19 11:59:28 -07:00
list_cursor.js node tests: Use {override} in run_test. 2021-06-16 12:55:53 -04:00
list_widget.js dropdown_list_widget: Add support for Multiselect dropdown list widget (MDLW). 2021-07-29 10:09:03 -07:00
markdown.js node_tests: Mock window.location with JSDOM. 2021-10-14 12:47:43 -07:00
message_edit.js settings: Add moderators and members option to msg-delete dropdown. 2021-09-30 14:59:31 -07:00
message_events.js message_edit_history: Migrate modal to dialog_widget. 2021-11-08 17:24:31 -08:00
message_fetch.js zjsunit: Wire $ to zjquery by default. 2021-06-16 12:55:53 -04:00
message_flags.js node tests: Use {override} in run_test. 2021-06-16 12:55:53 -04:00
message_list.js stream_data: Rename is_subscribed to is_subscribed_by_name. 2021-11-22 15:44:30 -08:00
message_list_data.js js: Rename muting module to muted_topics. 2021-06-30 16:32:55 -07:00
message_list_view.js lint: Fix typos found by codespell. 2021-10-19 16:51:13 -07:00
message_store.js node tests: Use {override} in run_test. 2021-06-16 12:55:53 -04:00
muting.js js: Rename muting module to muted_topics. 2021-06-30 16:32:55 -07:00
narrow.js narrow_banner: Add banner for no resolved topics found search. 2021-07-13 23:36:24 -07:00
narrow_activate.js narrow: Call reset_ui_state at start of narrowing process. 2021-11-27 20:18:32 -08:00
narrow_local.js resolve topic: Add frontend support for `is:resolved` search keyword/filtering. 2021-07-13 23:18:41 -07:00
narrow_state.js node tests: Use {override} in run_test. 2021-06-16 12:55:53 -04:00
narrow_unread.js resolve topic: Add frontend support for `is:resolved` search keyword/filtering. 2021-07-13 23:18:41 -07:00
navbar_alerts.js navbar_alerts: Add alerts for demo org deadlines. 2021-09-10 16:31:54 -07:00
notifications.js frontend: Add new user_settings module for user's settings. 2021-08-01 15:30:17 -07:00
password.js custom_check: Avoid use of assert to avoid confusion with assert.equal. 2021-06-10 09:15:57 -07:00
peer_data.js stream_data: Rename is_subscribed to is_subscribed_by_name. 2021-11-22 15:44:30 -08:00
people.js people: Extract helper functions for medium avatar urls. 2021-12-02 14:56:34 -08:00
people_errors.js node tests: Use {override} in run_test. 2021-06-16 12:55:53 -04:00
pill_typeahead.js node tests: Only expose mock_template via run_test. 2021-06-27 23:00:34 -04:00
pm_conversations.js js: Rename muting module to muted_topics. 2021-06-30 16:32:55 -07:00
pm_list.js zjsunit: Wire $ to zjquery by default. 2021-06-16 12:55:53 -04:00
poll_widget.js node tests: Only expose mock_template via run_test. 2021-06-27 23:00:34 -04:00
popovers.js people: Extract helper functions for medium avatar urls. 2021-12-02 14:56:34 -08:00
presence.js user_sidebar: Set personal presence dot based on the user's settings. (#20376) 2021-12-03 16:20:20 -08:00
reactions.js refactor: Remove duplication from reactions.add_clean_reaction. 2021-11-20 20:57:54 -08:00
recent_senders.js node tests: Use {override} in run_test. 2021-06-16 12:55:53 -04:00
recent_topics.js stream_data: Rename id_is_subscribed to is_subscribed. 2021-11-22 15:44:30 -08:00
reload_state.js node tests: Use {override} in run_test. 2021-06-16 12:55:53 -04:00
rendered_markdown.js frontend: Add new user_settings module for user's settings. 2021-08-01 15:30:17 -07:00
rtl.js custom_check: Avoid use of assert to avoid confusion with assert.equal. 2021-06-10 09:15:57 -07:00
schema.js node_tests: Don’t read from most deprecated global variables. 2021-02-10 07:40:22 -08:00
scroll_util.js zjsunit: Lift restriction against mocking third party modules. 2021-03-12 10:06:30 -08:00
search.js zjsunit: Wire $ to zjquery by default. 2021-06-16 12:55:53 -04:00
search_legacy.js zjsunit: Wire $ to zjquery by default. 2021-06-16 12:55:53 -04:00
search_pill.js node tests: Use {override} in run_test. 2021-06-16 12:55:53 -04:00
search_suggestion.js filter: Show typeahead suggestions if search query has search filters. 2021-11-29 16:20:29 -08:00
search_suggestion_legacy.js search_suggestion: Add suggestion support for `is:resolved` keyword. 2021-07-13 23:35:41 -07:00
server_events.js zjsunit: Wire $ to zjquery by default. 2021-06-16 12:55:53 -04:00
settings_bots.js zjsunit: Wire $ to zjquery by default. 2021-06-16 12:55:53 -04:00
settings_config.js settings_config: Pass settings object as parameter to all_notifications. 2021-09-16 15:46:41 -07:00
settings_data.js settings: Add user_can_create_web_public_streams function. 2021-11-23 10:48:20 -08:00
settings_emoji.js zjsunit: Wire $ to zjquery by default. 2021-06-16 12:55:53 -04:00
settings_muted_topics.js js: Rename muting_ui module to muted_topics_ui. 2021-07-09 10:00:45 -07:00
settings_muted_users.js js: Split out muted_users_ui from muting_ui module. 2021-07-09 10:00:45 -07:00
settings_org.js settings: Add frontend part for create_web_public_stream_policy. 2021-11-23 13:48:43 -08:00
settings_profile_fields.js node tests: Only expose mock_template via run_test. 2021-06-27 23:00:34 -04:00
settings_user_groups.js settings: Add moderators and full members options in user-group setting. 2021-07-14 14:38:44 -07:00
spoilers.js zjsunit: Wire $ to zjquery by default. 2021-06-16 12:55:53 -04:00
starred_messages.js frontend: Add new user_settings module for user's settings. 2021-08-01 15:30:17 -07:00
stream_data.js stream_data: Rename is_subscribed to is_subscribed_by_name. 2021-11-22 15:44:30 -08:00
stream_edit.js frontend: Add new user_settings module for user's settings. 2021-08-01 15:30:17 -07:00
stream_events.js stream_data: Rename is_subscribed to is_subscribed_by_name. 2021-11-22 15:44:30 -08:00
stream_list.js frontend: Add new user_settings module for user's settings. 2021-08-01 15:30:17 -07:00
stream_pill.js refactor: Add type field to pill items. 2021-04-27 12:07:57 -07:00
stream_search.js zjsunit: Wire $ to zjquery by default. 2021-06-16 12:55:53 -04:00
stream_settings_ui.js stream settings: Move stream list templates to stream_settings. 2021-07-19 10:54:11 -07:00
stream_sort.js node tests: Use {override} in run_test. 2021-06-16 12:55:53 -04:00
stream_topic_history.js message_edit: Fix live update bug in left sidebar. 2021-06-29 10:00:52 -07:00
submessage.js node tests: Use {override} in run_test. 2021-06-16 12:55:53 -04:00
support.js zjsunit: Wire $ to zjquery by default. 2021-06-16 12:55:53 -04:00
templates.js zjsunit: Optionally exercise template code. 2021-06-15 12:33:26 -04:00
timerender.js ts: Convert timerender module to TypeScript. 2021-09-15 17:19:39 -07:00
top_left_corner.js people: Allow deactivated users pills in compose box. 2021-06-25 18:01:15 -07:00
topic_generator.js js: Rename muting module to muted_topics. 2021-06-30 16:32:55 -07:00
topic_list_data.js left-sidebar: Add support for showing resolve-topic-prefix. 2021-07-05 18:02:40 -07:00
transmit.js node tests: Use {override} in run_test. 2021-06-16 12:55:53 -04:00
typeahead.js minor: Check if typeahead query exists. 2021-03-25 02:08:51 -07:00
typeahead_helper.js node tests: Only expose mock_template via run_test. 2021-06-27 23:00:34 -04:00
typing_data.js js: Split out muted_users module from muting. 2021-06-30 16:32:55 -07:00
typing_events.js typing_events.js: Add test for render_notifications_for_narrow(). 2021-10-07 16:32:08 -07:00
typing_status.js node tests: Use {override} in run_test. 2021-06-16 12:55:53 -04:00
unread.js stream_data: Rename id_is_subscribed to is_subscribed. 2021-11-22 15:44:30 -08:00
upgrade.js billing: Migrate to Stripe hosted checkout page. 2021-11-05 17:23:10 -07:00
upload.js upload: Return single elem for get_item(drag_drop_container) w/ edit. 2021-11-10 12:06:15 -08:00
user_events.js settings: Disable realm-level defaults of user settings for non-admins. 2021-09-16 15:46:40 -07:00
user_group_pill.js refactor: Add type field to pill items. 2021-04-27 12:07:57 -07:00
user_groups.js user_groups: Hide system user groups from UI. 2021-09-16 13:11:03 -07:00
user_pill.js people: Fix small avatar URL generation. 2021-10-14 12:47:43 -07:00
user_search.js js: Split out muted_users module from muting. 2021-06-30 16:32:55 -07:00
user_status.js user_status: Fix status emoji handling of deactivated custom emoji. 2021-11-20 20:57:54 -08:00
util.js node_tests: Mock window.location with JSDOM. 2021-10-14 12:47:43 -07:00
vdom.js custom_check: Avoid use of assert to avoid confusion with assert.equal. 2021-06-10 09:15:57 -07:00
watchdog.js custom_check: Avoid use of assert to avoid confusion with assert.equal. 2021-06-10 09:15:57 -07:00
widgetize.js widgets: Avoid adding the widget_elem if it already exists. 2021-07-24 09:52:14 -07:00
zblueslip.js Rename default branch to ‘main’. 2021-09-06 12:56:35 -07:00
zjquery.js Rename default branch to ‘main’. 2021-09-06 12:56:35 -07:00