Commit Graph

63651 Commits

Author SHA1 Message Date
opmkumar
85eb8e554f hash: Fix navigation issue with negated operators.
Previously, for spectators, when a negated search operator was
present, navigating forward or backward triggered the "signup/login"
modal.
This commit fixes this issue.
2025-03-04 11:37:21 -08:00
opmkumar
f7dea36abb narrow: Add helper to check allowed web public narrow.
Adds a helper function to check whether a narrow is an allowed
web public narrow or not.
2025-03-04 11:37:21 -08:00
opmkumar
efafe789be narrow: Rename allowed_web_public_narrows.
Renamed allowed_web_public_narrows to
allowed_web_public_narrow_operators, which will be used
in the future commits.
2025-03-04 11:37:20 -08:00
Shubham Padia
86579c02f3 stream: Send stream create/delete event on group setting change.
Fixes part of #33420.
If a group setting that can grant metadata access is changed, send a
create or delete event accordingly.
2025-03-04 11:34:59 -08:00
Shubham Padia
8481dcedc4 stream: Do not pass user group object when changing group setting.
Passing the user group object in case of named user group is fine for
`do_change_stream_group_based_setting`. But for anonymous groups, if the
code path calling that function is not creating a new anonymous user
group, it has to modify the user group by itself before calling that
function. In that case, if `old_setting_api_value` is not provided,
`old_user_group` is calculated false, since the group id has not changed
for the stream, but the group membership has changed.
old_setting_api_value will be the same as new_setting_api_value in such
a case.
It is better to accept the new setting value as either an int or
UserGroupMembersDict, so that `do_change_stream_group_based_setting` can
decide what to do with that argument.
2025-03-04 11:34:59 -08:00
evykassirer
0c57126104 stream settings: Scale advanced configuration toggle icon with font size. 2025-03-04 11:26:00 -08:00
Joseph Ho
0750c210f7 topic-move: Add warning banner if moving messages to existing topic.
In the move topic modal, when the user would merge messages into an
existing conversation, then we display a warning banner in the modal.
This is similar to the confirmation modal that appears when a user
edits a topic via the message feed header.

We do not show the warning for the empty/general topic for realms
that do not require topics, even if there are messages in the
general topic.

Fixes #31151.

Co-authored-by: Yiming He <heyimingfrog@gmail.com>
Co-authored-by: Lauryn Menard <lauryn@zulip.com>
2025-03-04 11:19:58 -08:00
arthurzengg
bfde6909cc buddy_list: Fix incorrect user count in the right sidebar.
Previously the count was sometimes incorrect because we were
subtracting unsubscribed participants from the subscriber count,
getting values that were too low (and sometimes negative!)

This count is displayed in the hover tooltip and section headers.

Fixes #33452
2025-03-04 11:16:12 -08:00
evykassirer
34d8c8f207 buddy_list: Rename get_formatted_user_count for clarity. 2025-03-04 11:16:12 -08:00
evykassirer
a6c8e0afbc buddy_list: Rename formatted_matching_users_count for clarity. 2025-03-04 11:16:12 -08:00
evykassirer
064533ba37 buddy_list: Don't recalculate total_human_subscribers_count for tippy.
This is still accessible if we make an accessor function in the tooltip
function's scope before the event handler that changes the `this` reference.
2025-03-04 11:16:12 -08:00
evykassirer
52fe67e698 buddy_list: Remove incorrect comment for human subscriber count. 2025-03-04 11:16:12 -08:00
evykassirer
d779498d32 todo_widget: Scale checkboxes with font size. 2025-03-04 11:10:38 -08:00
Prakhar Pratyush
dd181bd03f migrations: Update rename_general_chat_to_empty_string_topic migration.
Earlier, the migration code was replacing the occurrence of "general
 chat" as topic name in the database with `""`. This resulted in an
error which permanently broke `/near/` URL links to existing topics
named "general chat".

This commit updates the migration approach to instead move messages
from "general chat" to `""`. An edit history entry is added.

It results in the same expected behaviour and fixing that bug.
2025-03-04 11:02:08 -08:00
evykassirer
2f8a46ed57 subscriptions: Always show scrollbar for scrollable generate email modal. 2025-03-04 10:50:17 -08:00
evykassirer
181f229dae subscriptions: Scale copy email icon with font size. 2025-03-04 10:50:17 -08:00
Karl Stolley
71dc11189a sidebars: Show overlays full-screen, in proper stacking order.
This takes effect only at narrow viewports.

Fixes: #33713
2025-03-04 10:47:57 -08:00
Alya Abbott
86cd95c35e help: Document marking a whole topic or channel as unread. 2025-03-04 10:45:59 -08:00
Alya Abbott
8d615ebdef help: Give simpler instructions for marking as read from inbox. 2025-03-04 10:45:39 -08:00
Sayam Samal
06abc0bcff saved_snippets: Improve saved snippets UI.
This commit improves the saved snippets UI through the following ways:
- Reduces the space between the saved snippet title and description for
  a more interconnected feel.
- Changes the delete icon from the old font-awesome icons to using the
  new icon button component.
- Adds line-clamping to the saved snippet description to display two
  lines of text instead of one, presenting the user with more context.
2025-03-04 10:36:15 -08:00
evykassirer
27bda4a05d polls: Scale poll votes with info density. 2025-03-04 08:57:50 -08:00
Karl Stolley
e7eae0aa30 modals: Prevent possible native horizontal scrollbar. 2025-03-04 08:57:23 -08:00
Karl Stolley
3d44973640 right_sidebar: Improve grid on list-style menu. 2025-03-04 08:56:45 -08:00
Aman Agrawal
19f9add20e hello: Fix background animation broken for customer logos. 2025-03-03 22:49:20 -08:00
sanchi-t
dabe601015 message_feed: Notify users when skipping unsubscribed channels.
Zulip has an invariant that all unread messages must be in channels the
user is subscribed to. Therefore, in this commit, we add a feedback
widget to notify users when a channel to which they are not subscribed is
skipped while marking messages as unread in an interleaved view.

Fixes #23470.

Co-authored-by: Hemant Umre <hemantumre12@gmail.com>.
2025-03-03 17:43:57 -08:00
ubaidrmn
dd7cf27735 compose: Fix stale preview rendering after exiting preview mode.
If the user exits preview mode before the render response arrives, the
render is still applied to the hidden preview element, causing a stale
preview to appear when switching back to preview mode.

This commit adds a check to ensure the render is only applied if the
user is still in preview mode when the render response is received.
2025-03-03 17:39:14 -08:00
ubaidrmn
1a97fecdb8 compose: Fix preview not being updated when compose textarea is updated.
In preview mode, background updates to the compose box don’t refresh
the preview. For example, canceling an ongoing file upload after
activating preview mode still displays "uploading."

This commit extracts the preview rendering logic from the
show_preview_area function into a new function, `render_preview_area`,
and calls it on the compose textarea’s change event to ensure the
preview updates whenever the textarea is modified.

However, this introduces a race condition where the latest request is
not always reflected in the preview. To resolve this, we introduce a
state variable, `preview_render_count`, which is used to ensure only
the latest preview update is applied.

Fixes #33589.
2025-03-03 17:38:27 -08:00
evykassirer
ddd14a3dc1 buddy_list: Use different spacing for avatar and non-avatar text.
This ensures the link and empty list "None" message text is always
aligned with the text of the user's names.
2025-03-03 17:33:48 -08:00
evykassirer
7a3aa1f920 right_sidebar: Extend sidebar links hover outline left, to full width. 2025-03-03 17:33:48 -08:00
evykassirer
c2e361caea right_sidebar: Extend user row hover outline left, to full width. 2025-03-03 17:33:48 -08:00
evykassirer
0568f9eb1b right_sidebar: Use variable for avatar right margin. 2025-03-03 17:33:48 -08:00
evykassirer
fefd64b56d avatars: Move right margin rule to only selectors where it's relevant.
It isn't being used for `inline_profile_picture` because messages are
displayed with grid.
2025-03-03 17:33:48 -08:00
Karl Stolley
313a04b4a9 thumbnails: Express dimensions in rounded ems. 2025-03-03 17:11:13 -08:00
evykassirer
f44b56a750 subscriptions/user_groups: Remove custom styling for <=500px screens.
This was causing issues with the red icon having the wrong height and
centered buttons looking weird at narrow screens.

Further discussion here:
https://chat.zulip.org/#narrow/channel/9-issues/topic/.F0.9F.8E.AF.20UI.20issues.20in.20channel.20settings.20.28narrow.20windows.29/near/2105436
2025-03-03 17:09:48 -08:00
Aman Agrawal
5c7a774026 typeahead_helper: Place bots under group matches.
Fixes #32987

We separate bots from the users list and place them under group
matches so that typeahead suggestions show more relevant matches.
2025-03-03 16:48:06 -08:00
Aman Agrawal
e163a2f8d3 typeahead_helper: Extract function to split users based on query. 2025-03-03 16:48:06 -08:00
evykassirer
c5c5852964 typeahead: Rename header text as more accurate footer text.
This was moved to the bottom in 3e3deb2, but the naming had
not been updated.

Followup to #33584.
2025-03-03 16:43:33 -08:00
Maneesh Shukla
11e334fa8a presence_data: Fetch presence data when user card is opened.
This commit adds a new function to fetch presence data when the user
card is opened. This data is then used to display the user's presence
status in the card.

Fixes: #31037.
2025-03-03 16:11:30 -08:00
Karl Stolley
060b57470f right_sidebar: Make width easier to reason about. 2025-03-03 16:03:54 -08:00
Karl Stolley
17629c0f9c right_sidebar: Introduce the right sidebar with a narrower width. 2025-03-03 16:03:54 -08:00
Karl Stolley
e9ddd4797f app_layout: Constrain max-width when manually hiding sidebars.
Fixes: #33715.
2025-03-03 16:03:54 -08:00
Karl Stolley
1dad4dcdf7 app_layout: Calculate max-width using variablized values. 2025-03-03 16:03:54 -08:00
Karl Stolley
f8cb569678 app_main: Allow middle column to occupy hidden left sidebar space.
Fixes part of #33715.
2025-03-03 16:03:54 -08:00
Karl Stolley
f70b47878a navbar: Hide view, channel descriptions at small viewports.
This is an attempt to fix somewhat #33685. More finesse can
probably be done in the area, but hiding descriptions on a title-
by-title basis will be non-trivial.
2025-03-03 16:03:54 -08:00
Karl Stolley
e12168935e navbar: Handle offsets for manually hidden navigation.
This brings the offset behavior in line regardless of whether
"Use full width" has been selected.
2025-03-03 16:03:54 -08:00
Aman Agrawal
b60ac90714 fluid_layout: Fix narrow description not aligned with content.
Fixes #30619

We adjust the left margin of middle column to place the header middle
column next the left sidebar to fix the alignment issue.
2025-03-03 16:03:54 -08:00
Aman Agrawal
a3d591b337 css: Extract realm logo max width as a variable. 2025-03-03 16:03:54 -08:00
Harsh
60c6af2ab4 left_sidebar: Show Mark all messages as unread in channel popover.
This commit adds an option to show `Mark all messages as unread`
when all messages in the channel are read.

fixes #33067.
2025-03-03 15:59:16 -08:00
Alya Abbott
8e810aae54 docs: Improve Upgrade Zulip documentation.
- Arrange info more cleanly into sections.
- Avoid duplicating git versions documentation.
2025-03-03 15:37:43 -08:00
Apoorva Pendse
a33d7bacb9 compose_paste: Use katex-mathml for inline math filtering.
This is better than using `.katex` as sometimes
the selection range starts from the `.katex-mathml`
node.

Since `.katex-mathml` is always the immediate child
of `.katex`, this filtering/replacement change will
make copy pasting inline expressions better.

Fixes: https://chat.zulip.org/#narrow/channel/9-issues/topic/.F0.9F.93.82.20pasting.20LaTeX/near/2104904
2025-03-03 14:30:38 -08:00