Commit Graph

62954 Commits

Author SHA1 Message Date
Mateusz Mandera
0de58860dc install: Configure services during installation. 2025-02-05 17:47:28 -08:00
Tim Abbott
68c3e86ffa stream_data: Fix parsing of slugs for inaccessible channels.
Previously, if we had syntax in a URL slug that looked like a channel
ID, but we couldn't find the channel (say, beacuse it's a link to a
channel we're not subscribed to), parse_narrow would fail to parse it,
resulting in incorrect error handling.

This could break rendering of topic links that we want to process via
rendered_markdown.ts. I've confirmed that the web app's logic for
processing message_view.show does not require its caller to check the
channel ID is accessible.

The updated logic matches what we do in the mobile apps.
2025-02-05 14:01:11 -08:00
crab
c26cd25a4b user_profile: Invalidate user group state after closing the user modal.
A regression was introduced in #33075 where user groups are only
rendered on the user profile modal once per page load since
user_groups_list_widget was not getting cleaned upon closing the modal.
2025-02-05 13:42:54 -08:00
Tim Abbott
b249830715 rocketchat: Harden parsing of custom emoji exports.
Apparently some exports have a weird `ObjectId("idstring")` typed
value here, that stringify to the actual string.
2025-02-05 13:41:19 -08:00
Lauryn Menard
4d0448f7c6 zoom: Extract user authentication helper for current oauth integration.
Prep for adding a server to server oauth zoom integration.
2025-02-05 13:36:25 -08:00
Lauryn Menard
901141e297 zoom: Create shared TypedDict for zoom call payloads.
Prep for adding a server to server oauth zoom integration.
2025-02-05 13:36:25 -08:00
Lauryn Menard
cb68d11ee3 tests: Create subclasses for create video call tests.
Separates tests for Zoom and Big Blue Button video call
intgrations into separate sublcasses, ZoomVideoCallTest
and BigBlueButtonVideoCallTest respectively.
2025-02-05 13:36:25 -08:00
Lauryn Menard
f13a1a48f7 realm: Refactor VIDEO_CHAT_PROVIDERS to have all possible options.
Refactors Realm.VIDEO_CHAT_PROIVDERS to have all the possible options
for video chat integrations, and use get_enabled_video_chat_providers
to compute the enabled options for the realm.

Prep for adding Zoom server to server video chat integration.
2025-02-05 13:36:25 -08:00
Pratik Chanda
ef2f8c0796 recent_conversations: Show unread @-mention indicator for DMs.
Earlier, in recent conversation, only streams had unread @-mention
indicators and DMs in recent conversation lacked them.

This commit introduces unread @-mention indicators for DM rows in recent
conversations using `unread_mention_dms` which stores `user_ids_string`
mapped to `message_id`s having mention.

Fixes: zulip#28849.
2025-02-05 13:27:57 -08:00
Pratik Chanda
d3f4d0dfa2 left_sidebar: Show unread @-mention indicators for DMs in left sidebar.
Earlier, in left sidebar, only streams had unread @-mention indicators
in individual streams and topics. DMs lacked unread @-mention
indicators.

This commit introduces unread @-mention indicators for DM rows in left
sidebar using `unread_mention_dms` which stores `user_ids_string` mapped
to `message_id`s having mention.

Fixes part of zulip#28849.
2025-02-05 13:27:57 -08:00
Pratik Chanda
05fbee9f5a inbox_ui: Show unread @-mention indicator for DMs in inbox view.
Earlier, only unread @-mentions in streams were shown in inbox view
while DMs lacked this indicators.

This commit introduces unread @-mention indicators for DM rows in inbox
view using `unread_mention_dms` which stores `user_ids_string` mapped to
`message_id`s having mention.

Fixes part of zulip#28849.
2025-02-05 13:27:57 -08:00
Pratik Chanda
224024e683 unread: Track unread mentions for private messages.
Earlier, unread mentions in messages were handled to ignore if the
message was from a dm instead of stream.

This commit changes the behaviour by tracking the unread mentions
in all private messages and storing them to be easily retrieved.

Fixes part of zulip#28849.
2025-02-05 13:27:57 -08:00
Pratik Chanda
c14135ded5 tooltips: Change tooltip string for unread mention info.
This commit changes the tooltip string for unread mentions across
different views for streams.
2025-02-05 13:27:57 -08:00
Greg Price
2ce4fad39f contributor docs: Update GSoC mobile project for 2025. 2025-02-05 13:25:09 -08:00
Pratik Chanda
2a26f34983 hotkey: Focus visible input filter field on query streams hotkey.
Earlier, if pm_list or stream_list was zoomed in and hitting `q`
hotkey would seemingly do nothing but in the background would add
highlighted class to `stream_row` and toggle stream-list-filter.

This commit fixes this behaviour by bringing focus to currently
visible input filter field.
2025-02-05 13:23:15 -08:00
Pratik Chanda
c071d952e1 left_sidebar: Refactor display left sidebar for stream list filter.
This commit refactors show left sidebar display logic when initiating
stream search to sidebar_ui.
2025-02-05 13:23:15 -08:00
Pratik Chanda
1545a75645 tooltips: Refactor left sidebar tooltips to its own module.
This commit refactors tooltip targeting left sidebar elements
into its separate module in `left_sidebar_tooltips`.
2025-02-05 13:21:54 -08:00
evykassirer
56ba72c0b7 user_status: Remove fixed px height of status input.
It looks fine without the height explicitly set,
and the fixed height only works at 14px info
density.
2025-02-05 13:16:57 -08:00
Anders Kaseorg
432ebd9a36 tests: Consume more streaming responses.
Fixes warnings like “ResourceWarning: unclosed file <_io.FileIO
name='/srv/zulip/var/4fc6d348-ccfe-43fa-8a2e-5b4ff5a15a66/test-backend/run_2304691/worker_7/test_uploads/files/2/d9/KYUsAKJ_g45NA7CojVbRW0C4/zulip.jpeg'
mode='rb' closefd=True>” with warnings enabled.

Signed-off-by: Anders Kaseorg <anders@zulip.com>
2025-02-05 13:16:12 -08:00
evykassirer
753edc4b1a navbar: Scale navbar with app font size, using em. 2025-02-05 12:33:50 -08:00
evykassirer
bc4ee9a4d0 input_pill: Scale close button with app font-size. 2025-02-05 12:33:50 -08:00
Aman Agrawal
5d4adcc2d7 emoji_picker: Show popover as overlay if reference is not visible. 2025-02-05 12:30:50 -08:00
Prakhar Pratyush
25a0d97a2b zulip_updates: Raise error to explicitly log deactivated channel case.
`zulip_update_announcements_stream` should be set to None when its
channel is deactivated. This commit adds a safeguard to explicitly
raise an error if it is found in a deactivated state, indicating a
potential bug that needs investigation.

Without this commit, we won't face any runtime error but the error
raised would be at a much later stage i.e. while sending message,
with a generic error message i.e. "Not authorized to send to channel "
which would require further investigation to determine the root cause.

This commit helps with an early return and better error message
to debug.
2025-02-05 12:22:39 -08:00
Prakhar Pratyush
fe3199b954 zulip_updates: Add test to verify deactivated channel case.
This commit adds test to verify that we skip the update messages
and directly update the `zulip_update_announcements_level` to the
latest level when the configured `zulip_update_announcements_stream`
is deactivated.
2025-02-05 12:21:55 -08:00
Prakhar Pratyush
77baa05aa9 streams: Set realm stream fields to NULL when streams are deactivated.
When a stream configured for any of these settings is deactivated,
the corresponding realm settings should be set to NULL:
* new_stream_announcements_stream
* signup_announcements_stream
* zulip_update_announcements_stream
* moderation_request_channel

Earlier, we were not updating those realm settings to NULL.
We had helper functions like 'get_new_stream_announcements_stream'
to return None if the configured stream was deactivated.
But it makes more sense to just set them to NULL in DB.

This commit also includes a migration to clear those fields
if the configured channels are deactivated.
2025-02-05 12:21:55 -08:00
Prakhar Pratyush
4063aa4a00 zulip_updates: Replace 'stream' with 'channel' in group DM content.
This commit updates the initial group DM content sent to admins
to use the word 'channel' replacing 'stream'.

We used to call channel as stream.
2025-02-05 12:21:55 -08:00
Prakhar Pratyush
46f518fdbf api_docs: Improve topic parameter docs to list restricted values.
This commit updates the docs to specify that when topics are
required in an organization, the `topic` parameter in
`POST /messages` and `PATCH /messages/{message_id}` cannot be
* "(no topic)"
* an empty string
* `realm_empty_topic_display_name`.
2025-02-05 12:04:39 -08:00
Prakhar Pratyush
d4ae480985 api_docs: Update scheduled_message docs to specify empty string topic.
We missed to update this section of the docs while working
on feature level 334.
2025-02-05 12:04:39 -08:00
Aman Agrawal
5f709245c0 inbox: Allow user to select empty view text.
We likely added this logic to allow links to be opened in new tab
on ctrl + click and not trigger text selection.

We retain this behaviour but allow selection of empty view text.
2025-02-05 05:59:12 -08:00
Prakhar Pratyush
3b279d38a0 api_docs: Improve topic-permalink docs in /api/message-formatting.
This commit updates the wording related to topic-permalink in
`/api/message-formatting` to clarify that the condition applies
when a topic has no messages, not when the topic name is empty.

Also, it reorders examples so that similar input formats are
grouped together, improving readability.
2025-02-05 05:56:46 -08:00
Prakhar Pratyush
23f16885d5 push_notifications: Show EMPTY_TOPIC_FALLBACK_NAME for topic="".
This commit adds support to display `Message.EMPTY_TOPIC_FALLBACK_NAME`
value (translated) in the push notifications for topics having the
actual value of empty string.

Fixes part of #32996.
2025-02-05 05:56:07 -08:00
apoorvapendse
d3b601ef3b copy_and_paste: Support inline tags with katex siblings. 2025-02-04 21:53:44 -08:00
evykassirer
774e981487 settings: Redesign of remove date button.
This fixes placement for larger font sizes and
also updates the button to the newer style.
2025-02-04 16:16:11 -08:00
apoorvapendse
ac8614caf8 copy_and_paste: Fix regression caused by quoting math.
We now do a more precise check to decide whether
to perform the span conversion for intermediate
text nodes.

Fixes: https://chat.zulip.org/#narrow/channel/9-issues/topic/HTML.20paragraphs.20misconverted.20by.20copy.20and.20paste.
2025-02-04 16:10:49 -08:00
Sahil Batra
fbbd36b306 group-settings: Live update permissions panel.
This commit adds code to live update permissions panel when
a group gains permission.
2025-02-04 16:08:58 -08:00
Sahil Batra
69437c5bc8 group-settings: Refactor code to fix live update of permissions panel.
This commit refactors the code so that we can correctly update the
permissions panel when a group gains permission. The changes done are-

- Extracted templates for subsection for stream and group settings
because we might need to add complete subsection to DOM if group has
no existing permission for a particular stream or group.

- Also, updated get_group_assigned_realm_permissions to return all
subsection objects even when group has no assigned permission for
a subsection because we now have headers for all the subsection
in DOM but just hide them so that order can be maintained when
a setting of a subsection is added during live update.
2025-02-04 16:08:58 -08:00
Sahil Batra
38b785cf9b settings_config: Extract common list of owner editable group settings. 2025-02-04 16:08:58 -08:00
Alya Abbott
0430a4bd0a contributor docs: Add link to GSoC 2024 blog post. 2025-02-04 15:58:54 -08:00
Alya Abbott
b080ebb140 contributor docs: Drop outdated GSoC projects. 2025-02-04 14:35:02 -08:00
Alya Abbott
8a0e9b87ad integrations: Update documentation on the Zoom integration.
- Duplicate admin instructions on /integrations (with context).
- Move end user instructions to /help.
2025-02-04 12:41:53 -08:00
Mateusz Mandera
a352d35660 retention: Add flag to ArchiveTransaction to prevent automatic deletion.
This adds an index non-concurrently, but the table should be small
enough for this to be fine.
2025-02-04 11:31:13 -08:00
Sahil Batra
bec0326776 group_permission_settings: Use set instead of list.
check_group_permission_settings_data now uses set for the
list of settings defined in data structures in settings_config
which makes the code little efficient when checking if the
data structure contains all the setting names or not.
2025-02-04 11:21:01 -08:00
Sahil Batra
0f1621c88f tests: Add test for default setting values when creating streams.
This test helps in making sure we send the correct setting
value in stream creation events as well especially after
changes in fd70e83980.
2025-02-04 11:21:01 -08:00
whilstsomebody
c4a3b69f5c user_card_popover: Make user name selectable.
The 'user-select: none' property was originally added to
prevent users from highlighting images and menu option text
in popovers. However, applying it to the entire
'.popover-menu' unintentionally blocks text selection in
cases where it's useful, such as usernames in user cards.

This commit refines the approach by restricting by adding
'text-select' class to the username in user cards without
affecting the other elements of the popovers.
2025-02-04 11:19:58 -08:00
Sahil Batra
7bfaf45bcf stream-settings: Fix clicking on "?" in group setting label.
This commit fixes the bug when clicking on "?" icon in group
setting label by making sure that click handler returns early.

Also, updated the handler to use e.currentTarget instead of
e.target when opening the typeahead and focusing the input
as that is more correct and prevents future unexpected bugs.
2025-02-04 11:13:22 -08:00
whilstsomebody
8a64940868 message_edit: Fix "(deleted)" not showing for empty edited DMs.
This commit fixes a bug introduced in commit `37f2c5bc788`,
where a message in DM is not updated to "(deleted)" when
left empty after editing.

Fixes: #33305
2025-02-04 11:02:30 -08:00
Aditya Kumar Kasaudhan
21412b9f79 channels: Auto-mark channel archival event messages as read.
Previously, channel archival event messages were unread in
archived channels, which makes the archived channel accessible
from the inbox view.
This commit fixes this issue by auto-marking the channel archival
event message as read.

Fixes: zulip#33258.
2025-02-04 11:01:20 -08:00
Aditya Kumar Kasaudhan
cbc72fe491 subs: Split test_deactivate_stream_backend test by permission source.
This commit splits the existing deactivation test into two separate
tests — one for realm administrators and one for user group-based
permissions to improve clarity.
2025-02-04 11:01:20 -08:00
Aman Agrawal
0313435b8d inbox_ui: Avoid AssertionError when starting new compose message.
This is hard to debug but likely not a critical UX bug.
2025-02-04 10:44:46 -08:00
Alex Vandiver
59dde93a47 run_hooks: Diff to "last" instead of "current" during post-deploy. 2025-02-04 10:44:17 -08:00