Commit Graph

53730 Commits

Author SHA1 Message Date
Anders Kaseorg f99cce91bf middleware: Send got_request_exception signal for JSON 500 errors.
This is ordinarily emitted by Django at
  https://github.com/django/django/blob/4.2.6/django/core/handlers/exception.py#L139
and received by Sentry at
  https://github.com/getsentry/sentry-python/blob/1.31.0/sentry_sdk/integrations/django/__init__.py#L166

Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-04 17:25:20 -07:00
Mateusz Mandera f71e2c8247 support: Add basic support endpoint for remote servers. 2023-10-04 16:55:47 -07:00
Aman Agrawal 2ed1465b04 css: Display status emoji along with overflowing sender names.
Even if sender name overflows the available space, we should
show status emoji along with sender name by hiding the overflowing
part of sender name.
2023-10-04 16:49:39 -07:00
Anders Kaseorg 8d217847db stream_edit: Move can_remove_subscribers_group_widget to settings_org.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-04 16:35:24 -07:00
Anders Kaseorg 278bd52b4e stream_edit: Move get_request_data_for_stream_privacy to settings_data.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-04 16:35:24 -07:00
Anders Kaseorg d17c0dabc8 stream_data: Move stream_*_policy_values to settings_config.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-04 16:35:24 -07:00
Anders Kaseorg 0f0fd3f07d tests: Remove sub_store mock from recent_view test.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-04 16:35:24 -07:00
evykassirer 083062cd11 search: Don't "initiate search" if it's already open.
(or if you're using a hotkey, since then we should select
the searchbar)

Reported here:
https://chat.zulip.org/#narrow/stream/9-issues/topic/search.20bar.3A.20selection.20jumping.20to.20whole.20query/near/1652562
2023-10-04 16:32:19 -07:00
Alex Vandiver 528d0ebcf0 puppet: Serve /etc/zulip/well-known/ in nginx as /.well-known/. 2023-10-04 15:56:42 -07:00
Aman Agrawal 9388db83dd update-prod-static: Generate landing page when updating prod instance. 2023-10-04 15:54:57 -07:00
Aman Agrawal a6fbf570cd provision_inner: Add a reminder to check for production needs.
This script is not run in production. Help developers remind
that.
2023-10-04 15:54:57 -07:00
Aman Agrawal 2ec8273c6e left_sidebar: Move all messages popover to inbox.
Also, renamed files and variables as needed.
2023-10-04 13:10:08 -07:00
Aman Agrawal dd1e06886c popover_menus: Remove unused class added to popover. 2023-10-04 13:10:08 -07:00
Aman Agrawal 4f881ee058 left_sidebar: Move unread count from all messages to inbox. 2023-10-04 13:10:08 -07:00
Aman Agrawal af03b9dd06 left_sidebar: Move `All messages` below `Recent view`. 2023-10-04 13:10:08 -07:00
Aman Agrawal 7da0e09d0a left_sidebar: Remove old comment.
Not sure what this means so removed.
2023-10-04 13:10:08 -07:00
Anders Kaseorg b4878d4f0b stream_edit: Move set_stream_property to new stream_settings_api module.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-04 13:04:50 -07:00
Prakhar Pratyush 28fb5ea24d settings: Add UI for automatically follow and unmute topics settings.
This commit adds two drop-down settings in 'SETTINGS / NOTIFICATIONS'
and 'SETTINGS / DEFAULT USER SETTINGS'.

The new settings lie in a new section named "Topic notifications",
just below the "Noification triggers" section.

Label: "Automatically follow topics"
Options: "Topics I participate in", "Topics I send a message to",
"Topics I start", and "Never".

Label: "Automatically unmute topics in muted streams"
Options: "Topics I participate in", "Topics I send a message to",
"Topics I start", and "Never".

Fixes #25914.
2023-10-04 13:04:29 -07:00
Prakhar Pratyush 58568a60d6 settings: Add automatically follow and unmute topics policy settings.
This commit adds two user settings, named
* `automatically_follow_topics_policy`
* `automatically_unmute_topics_in_muted_streams_policy`

The settings control the user's preference on which topics they
will automatically 'follow' or 'unmute in muted streams'.

The policies offer four options:
1. Topics I participate in
2. Topics I send a message to
3. Topics I start
4. Never (default)

There is no support for configuring the settings through the UI yet.
2023-10-04 13:04:29 -07:00
Prakhar Pratyush c349d1137c sent_by_human: Add "test suite" to the set of Zulip UI-style clients.
Earlier, when we used 'self.send_message()' in the backend tests,
the sent message was not marked as read for the sender.

Reason: To set the read flag, we have to check if
'message.sent_by_human()'. It returns False because the
'sending_client' for tests is "test suite" and the 'sent_by_human'
function doesn't enlist the "test suite" client name as a human client.

This commit adds "test suite" to that list.

Also fixes a bug in when apply_unread_message_event was called that
was revealed by this change.
2023-10-04 13:04:29 -07:00
Prakhar Pratyush 68abc6af21 unread_msgs: Fix 'raw_unread_messages["muted_stream_ids"]' not set.
The raw_unread_messages["muted_stream_ids"] was not properly
updated with the calculated value.

The bug was introduced in 72e0084692.
2023-10-04 13:04:29 -07:00
N-Shar-ma 46b2d6d06a compose: Remove redundant code from scheduled_messages_ui.js.
We remove redundant code when editing a scheduled message in the compose
box, for resetting the compose box, as it anyway gets reset on calling
`compose_actions.start()`.

Besides ending `scheduled_messages_ui.js`'s dependency on `compose.js`
and `compose_ui.js`, this also fixes the bug where on editing a
scheduled message when there was content in the compose box, it would be
irretrievably lost. The old content is now drafted.
2023-10-04 12:54:36 -07:00
Lauryn Menard afc1d2a409 activity: Add separate page for remote server information/table.
Moves the "Remote Zulip servers" tab in the "/activity" page for
an installation to a separate page, "/activity/remote".

Prototype for moving other tabs in "/activity" to separate pages.
2023-10-04 12:48:39 -07:00
Anders Kaseorg 91f81d3962 flatpickr: Fix Tab key handler for 24-hour time.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-04 12:03:10 -07:00
Moazzam Moriani 2789dd4e85 translation: Add Urdu translation guide. 2023-10-04 11:14:01 -07:00
Anders Kaseorg c98622c63a compose: Extract compose_call module.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-03 18:41:42 -07:00
Anders Kaseorg ac38aaad21 scheduled_messages: Move UI to new scheduled_messages_ui module.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-03 17:56:43 -07:00
Anders Kaseorg c7927569bc scheduled_messages_popover: Move selected_send_later_timestamp.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-03 17:56:43 -07:00
Anders Kaseorg b50e500dae scheduled_messages: Move update_send_later_options.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-03 17:56:43 -07:00
Anders Kaseorg 3e4def9c88 narrow: Don’t swallow errors in narrow.activate.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-03 14:52:07 -07:00
Anders Kaseorg 549bae5176 message_edit: Move get_upload_object_from_row to upload module.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-03 14:50:02 -07:00
Anders Kaseorg fb19476c4e compose: Move uppy to upload module.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-03 14:50:02 -07:00
Sayam Samal abece73c5a tooltips: Add hotkey hints and modify edit history tooltip.
This commit consists of the following visual changes:

- Add the hotkey hints in the tooltip of the view edit history option,
the shortcut (Shift + H) for which was added in PR #26245

- Swap "Click to view edit history." and the edit status string
(EDITED/MOVED/SAVING) to make the tooltip consistent with other
tooltips across the web app.

- Rename "Click to view edit history." to "View edit history", since
the "Click to view" part is evident from the icon as well as the the
keyboard shortcut hints.

Fixes #26581.
2023-10-03 14:37:47 -07:00
Sayam Samal 8d3f2baebf tooltips: Use <div> tags inside tooltip's inner content.
By replacing `<span>` tags with `<div>` tags inside the tooltip's inner
content we remove the redundancy of having to use break tags to
separate the tooltip's title and it's content.

We also replace any `<p>` tags with `<div>` tags for the following
reasons:

- Since what we want to achieve are just block elements in order to
avoid the break tags, using `<div>` tags provide use with a wider
scope of use cases.

- We don't want the pause, screen readers often introduce after reading
the contents of a paragraph.

- The `<p>` tag cannot contain tables and other block-level elements.

- The semantic meaning of the <p> tag doesn't apply to the commonly
used tooltip content.
2023-10-03 14:37:47 -07:00
Alya Abbott 456f3a0d94 integrations: Update Zapier documentation. 2023-10-03 14:21:36 -07:00
Anders Kaseorg 1db4174319 docs: Remove long-obsolete REALMS_HAVE_SUBDOMAINS documentation.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-03 14:14:12 -07:00
Anders Kaseorg 9b6301c755 upload: Don’t leak an extra body event handler for each edited message.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-03 14:10:15 -07:00
Anders Kaseorg 4595be29e8 stream_settings_ui: Remove set_muted wrapper.
stream_muting.update_is_muted will be called when the event comes back
from the server.

Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-03 12:49:36 -07:00
ecxtacy 61b9cff89b docs: Fix HTTP methods for /users endpoint.
Correct the `PUT` to `POST` in the
`/docs/tutorial/life-of-a-request.md` to match it with the actual code
in `zproject/urls.py` route: '/users'. (The HTTP method changed at
some point).

Tested by tabbott using:

curl -v -X HEAD https://chat.zulip.org/api/v1/users
2023-10-03 12:43:49 -07:00
Anders Kaseorg 6e3d6f531f web: Fix namespace import names.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-03 12:21:06 -07:00
Anders Kaseorg 4d67bf5605 compose: Delete obsolete comment.
Commit 57340a888c (#19003) separated it
from the variable it was commenting, and commit
8ced075643 (#22754) changed that to a
different variable, so I infer that nobody thought this documentation
was important.

Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-03 12:20:01 -07:00
Anders Kaseorg d4a93aa05a popover_menus: Extract compose_popovers module.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-03 11:58:29 -07:00
Anders Kaseorg d01db0f5a0 popover_menus: Extract left_sidebar_navigation_area_popovers module.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-03 11:58:29 -07:00
Anders Kaseorg dd6676f16e popover_menus: Extract user_topic_popover menus.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-03 11:58:29 -07:00
Anders Kaseorg 825fb8cef5 popover_menus: Extract topic_popover module.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-03 11:58:29 -07:00
Anders Kaseorg 16e2a32c4c popover_menus: Extract message_actions_popover module.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-03 11:58:29 -07:00
Anders Kaseorg 26e34a163e popover_menus: Extract scheduled_messages_popover module.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-03 11:58:22 -07:00
Ujjawal Modi 0e5bb92111 settings: Improve UI for displaying reactivated and deactivated users.
Earlier when a user is deactivated or reactivated from users
table and deactivated_users table the `Role` column was modified.

This commit changes this and now `Role` column is not modified
instead now the corresponding row is greyed out.

Fixes #21653.
2023-10-03 11:15:39 -07:00
Ujjawal Modi ba1405df96 settings: Live update tooltip in users and deactivated users table.
Earlier tooltip shown on hovering to activate and deactivate user
button in users and deactivated_users table does not live update
when user is deactivated or reactivated.

This commit makes changes to do the live update.
2023-10-03 11:15:39 -07:00
Ujjawal Modi 7453ea61bb settings: Remove title from button in users and deactivated_users table.
This commit removes the `Reactivate` and `Deactivate` title on hovering
to activate and deactivate button in users and deactivated_users table.
This was done as we already show tippy tooltip on hover.
2023-10-03 11:15:39 -07:00