Commit Graph

61509 Commits

Author SHA1 Message Date
sanchi-t fa268877d3 stream: Show `(archived)` at the end of deactivated stream names.
When a stream is deactivated the title area and messages are
re-rendered to update the stream name with `(archived)` suffix.
2024-10-25 16:06:42 -07:00
sanchi-t 616e39c290 stream_data: Make `Subscribe` button not visible for archived streams. 2024-10-25 16:06:42 -07:00
sanchi-t a917215292 get_subs_for_settings: Exclude archived streams from `All Streams` menu.
Don't display stream settings for archived channels.
2024-10-25 16:06:42 -07:00
sanchi-t ca9ac293f3 sub_store: Add `is_archived` field to `Stream` type. 2024-10-25 16:06:42 -07:00
sanchi-t af7ebde9e4 subscription: Include archived channels in streams list.
`is_archived` field is added to the stream and types.

Include a new `archived_channeels` client capability, to allow clients
to access data on archived channels, without breaking
backwards-compatibility for existing clients that don't know how to
handle these.

Also, included `exclude_archived` parameter to `/get-streams`,
which defaults to `true` as basic clients may not be interested
in archived streams.
2024-10-25 16:06:40 -07:00
sanchi-t c6fc25e5df do_deactivate_stream: Do not rename streams during archiving.
Functions related to archived streams are also updated.
2024-10-25 15:56:04 -07:00
sanchi-t e25bbe1005 migration: Rename previously archived streams to their original names.
As several archived streams may have the same new name,
it is essential to verify whether any stream, regardless
of its current status (active or archived), already has that name
before executing any renaming operation.
2024-10-25 15:56:04 -07:00
Karl Stolley 40da0e44fb squash: Experiment with less intense modal border colors. 2024-10-25 15:39:13 -07:00
Karl Stolley 2c78efc3c5 settings: Improve layout and appearance of Organization logo area. 2024-10-25 15:39:13 -07:00
Karl Stolley 8c90c9d68d modals: Set new background, border colors. 2024-10-25 15:39:13 -07:00
Karl Stolley cd1f58080b left_sidebar: Put the New DM button to the right of All DMs. 2024-10-25 15:24:20 -07:00
Karl Stolley 9e8d908a37 left_sidebar: Show Direct Messages controls on DM area hover. 2024-10-25 15:24:20 -07:00
Pratik Chanda 34ff1de338 left_sidebar: Hide new topic button on restricted compose permission.
Earlier, in left stream sidebar, new topic button was shown for all
stream rows irrespective of compose permission of the user for
individual streams.

This commit changes the behaviour by hiding the new topic button if
user doesn't have appropriate compose permission for individual
streams.

Fixes: zulip#31800.
2024-10-25 16:32:44 -05:00
Tim Abbott d8cf3ff2e9 ci: Run production suite when changing storage.py. 2024-10-25 10:59:57 -07:00
Tim Abbott 71d81484ad storage: Simplify system bot avatar logic. 2024-10-25 10:59:57 -07:00
PieterCK c3017e55d2 storage: Rework static avatar files hashing logic.
Previously, the hashing logic for static avatar files hashed the default
and medium files separately, which didn’t match how user-uploaded
avatars work—where you just add the "-medium.png" suffix to get the
medium version. Since we don’t have clear documentation for avatars yet,
this caused some issues for the mobile apps.

This commit makes sure the default and its medium variation share the
same hash.
2024-10-25 09:36:52 -07:00
Sahil Batra 2109d3d1ab user_group_popover: Remove period after members count. 2024-10-25 08:23:14 -07:00
Shubham Padia fe9952eab5 groups: Rename test to state that it checks allow_system_group.
We also remove the default group check which is already being checked in
do_set_realm_permission_group_setting_to_anonymous_groups_test.
2024-10-24 14:42:21 -07:00
Shubham Padia 1f0906aef7 groups: Remove list specifying group settings with new API format.
All the groups are now following the new API format, making the list
redundant.
2024-10-24 14:42:21 -07:00
Shubham Padia 9f9d5b2f98 groups: Accept anonymous groups for can_access_all_users_group.
On the frontend, the selection is still a dropdown of system groups but
on the API level, we have started accepting anonymous groups similar to
other settings
We've kept require system groups true for now until we switch to group
picker on the frontend.
2024-10-24 14:42:19 -07:00
Shubham Padia ceb0197c1b groups: Accept anonymous groups for create_multiuse_invite_group.
On the frontend, the selection is still a dropdown of system groups but
on the API level, we have started accepting anonymous groups similar to
other settings.
We've kept require system groups true for now until we switch to group
picker on the frontend.
2024-10-24 14:41:09 -07:00
Tim Abbott 3310aed462 send_custom_email: Support specifying sender email address. 2024-10-24 14:36:48 -07:00
Mateusz Mandera 481ef24b53 auth: Tweak invalid credentials error message.
We decided this is the better string to use.
2024-10-24 14:35:31 -07:00
Shubham Padia 94a86d4ac2 help: Use an emoji that does not vary in design.
The octopus emoji varies in design based on the user's device/browser,
while thumbs up emoji is more consistent in that regards.
2024-10-24 13:01:50 -07:00
Shubham Padia d98446491d help-beta: Add support for images.
Partially fixes #31255. We'll need to copy images to src/ at the time of
cutover. See
https://chat.zulip.org/#narrow/stream/6-frontend/topic/Handling.20images.20in.20help.20center.20starlight.20migration.2E/near/1915130
for more details.

We've also copied over css relevant to markdown images, while making
some small changes to it so that it works better with existing
starlight styling.
2024-10-24 13:01:50 -07:00
Shubham Padia a4d9c2e2c9 help: Convert emoji images to unicode emoji.
We had inconsistencies in the documentation where we were using emojis
directly in help documentations and sometimes we were using an img tag
for it. This commit aims to standardise it to just using emojis
directly.
See https://chat.zulip.org/#narrow/stream/19-documentation/topic/help.20center.20-.20emojis.20in.20markdown.20files/near/1954272
on more details on the decision.
2024-10-24 13:01:50 -07:00
Lauryn Menard 44a25e00b7 remote-activity: Show remote realm mobile user and push data.
Updates the main query and logic for building the remote activity
table to use remote server mobile user/push data for server rows
and remote realm mobile user/push data for realm rows.
2024-10-24 12:51:53 -07:00
Niloth P bd83dbfb42 git webhooks: Handle assignment events better.
With the introduction of `assignee_updated` parameter in the library,
- Github, Gitea, Gogs can display the assignee in assignment events.
- Github can display the user unassigned in unassignment events.

Fixes https://chat.zulip.org/#narrow/channel/127-integrations/near/1965136
2024-10-24 12:46:39 -07:00
Karl Stolley 8e85972a03 empty_titles: Set line-height to match font size. 2024-10-24 12:40:43 -07:00
Karl Stolley 5b96769739 right_sidebar: Correct line-height by decoupling .filters class. 2024-10-24 12:39:49 -07:00
sanchi-t aa48a0e3ee css: Refactor theme colors for `input_pill`.
This change moves the light and dark theme colors for
`input_pill` to CSS variables.
2024-10-24 11:09:39 -07:00
sanchi-t 9b5accdb43 css: Refactor theme color for kbd. 2024-10-24 11:09:39 -07:00
Kislay Udbhav Verma 327647f4f8 copy_and_paste: Paste fallback md link if syntax link will be broken.
If we paste a stream-topic URL that can be formatted as per #29302,
we now generate a normal markdown link if the stream topic syntax
could result in a broken link.

Fixes #31904
2024-10-24 11:07:31 -07:00
Mateusz Mandera da4443f392 thumbnail: Make thumbnailing work with data import.
We didn't have thumbnailing for images coming from data import and this
commit adds the functionality.

There are a few fundamental issues that the implementation needs to
solve.

1. The images come from an untrusted source and therefore we don't want
   to just pass them through to thumbnailing without checking. For that
   reason, we cannot just import ImageAttachment rows from the export
   data, even for zulip=>zulip imports.
   The right way to process images is to pass them to maybe_thumbail(),
   which runs libvips_check_image() on them to verify we're okay with
   thumbnailing, creates ImageAttachment rows for them and sends them
   to the thumbnailing queue worker. This approach lets us handle both
   zulip=>zulip and 3rd party=>zulip imports in the same way,

2. There is a somewhat circular dependency between the Message,
   Attachment and ImageAttachment import process:

- ImageAttachments would ideally be created after importing
  Attachments, but they need to already exist at the time of Message
  import. Otherwise, the markdown processor doesn't know it has to add
  HTML for image previews to messages that reference images. This would
  mean that messages imported from 3rd party tools don't get image
  previews.
- Attachments only get created after Message import however, due to the
  many-to-many relationship between Message and Attachment.

This is solved by fixing up some data of Attachments pre-emptively, such
as the path_ids. This gives us the necessary information for creating
ImageAttachments before importing Messages.

While we generate ImageAttachment rows synchronously, the actual
thumbnailing job is sent to the queue worker. Theoretically, the worker
could be very backlogged and not process the thumbnails anytime soon.
This is fine - if the app is loaded and tries to display a message with
such a not-yet-generated thumbnail, the code in `serve_file` will
generate the thumbnails synchronously on the fly and the user will see
the image preview displayed normally. See:

1b47134d0d/zerver/views/upload.py (L333-L342)
2024-10-24 10:32:51 -07:00
Mateusz Mandera a6b0385229 tests: Extract upload_image helpers from test_markdown_thumbnail.
These are pretty general and can be useful utils for other tests.
2024-10-24 10:32:51 -07:00
Sahil Batra b593f6a881 user_group_popover: Fix icon alignment.
This commit fixes alignment of icons for the group members
and subgroups list shown in the popover.
2024-10-24 08:24:14 -07:00
Sahil Batra 7fe927c61b user_group: Show subgroups in popover.
Previously, all members of the group, including members of
recursive groups, were shown in the the popover. Now only
direct members are shown along with the direct subgroups
of the group.

Fixes #32088.
2024-10-24 08:24:14 -07:00
Sahil Batra f6db00bfb5 user_group_popover: Show members count in popover.
This count includes direct members as well as members of
all the recursive subgroups.
2024-10-24 08:24:14 -07:00
Mateusz Mandera af9b44ed02 auth: Fix invalid credentials message in login form.
Email is not case-sensitive. And password is obviously case-sensitive,
so no point mentioning that.
2024-10-24 08:23:16 -07:00
Prakhar Pratyush 30ada20ece dialog_widget: Fix stale comment.
The 'settings_user_groups' file which the comment refers
to no longer exists.

This commit updates the comment.
2024-10-24 08:22:08 -07:00
Prakhar Pratyush fd66c08221 onboarding_steps: Fix blueslip error message.
This commit fixes the blueslip error message displayed
when marking an onboarding step as read fails.
2024-10-24 08:22:08 -07:00
Prakhar Pratyush 3e13914f4a attachments_ui: Remove unused 'id' from 'Delete file' dialog widget.
The 'id' field in a dialog widget is used to add custom id to
the container element to modify styles.

We were not using this id anywhere, so this commit removes it.
2024-10-24 08:22:08 -07:00
klarabratteby ab03c74314 user_topic_popover: Convert module to TypeScript. 2024-10-23 15:26:46 -07:00
klarabratteby a601715e37 user_topic_popover: Remove all occurrences of instance.context. 2024-10-23 15:26:46 -07:00
Aditya Chaudhary ac652ffab6
stream_settings: Place the cursor automatically in channel name.
When the user opens channel create settings from left sidebar, now the focus
is set on the channel name input.

The logic was already there, but not properly placed inside the overlay code path.

Fixes #32034.
2024-10-23 15:06:21 -07:00
Aditya Chaudhary c1fc8e6331 channel_feed: Configure click event for channel name.
This commit configures the click event on the channel name so that
when the user is narrowed to a topic within a channel, clicking the
same channel will navigate the user to the general channel feed. This
improves the user experience by allowing easy access to the full
channel feed when a user is focused on a specific topic.

Fixes #32032.
2024-10-23 15:03:39 -07:00
Anders Kaseorg 2671a5c32c stylelint: Enable stylelint-high-performance-animation.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-10-23 14:56:39 -07:00
Anders Kaseorg f023fa6fc0 styles: Be specific about which properties are transitioned.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-10-23 14:56:39 -07:00
Anders Kaseorg 7878b80934 comparison_table: Remove dead CSS for th.sticky.
We do not have a "sticky" class.

Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-10-23 14:56:39 -07:00
Anders Kaseorg f8f511aded footer: Remove unused CSS transition for #footer li.
This doesn’t transition anything.

Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-10-23 14:56:39 -07:00