Commit Graph

51279 Commits

Author SHA1 Message Date
Lalit 852bfd8d7a style: Add bootstrap link styles in the app's index.html.
We add bootstrap anchor tag styles in our main `index.html` page so
that the link styles are always applied on the reload link and it looks
like a link.

Fixes #25377.
2023-05-02 09:01:37 -07:00
Tim Abbott 1c07756150 scheduled messages: Use data-scheduled-message-id.
This helps make it really clear that these are not message IDs, they
are scheduled message IDs.
2023-05-01 22:45:03 -07:00
Aman Agrawal 12a2e3122f popover_menus: Show last selected time in send later popover. 2023-05-01 22:45:03 -07:00
Aman Agrawal ee354bb007 send_later: Only store timestamp values in `selected_send_later_timestamp`.
This removes any confusion regarding what format of time does
this variable has.
2023-05-01 22:45:03 -07:00
Aman Agrawal 1885ed783a compose: Add new banner for success message scheduled. 2023-05-01 22:45:03 -07:00
Aman Agrawal fe4bfebbdc scheduled_messages_overlay_ui: Show scheduled time in standard format. 2023-05-01 22:45:03 -07:00
Aman Agrawal 7d373c54a9 scheduled_mesages: Use events to update scheduled message data.
This also allows to display scheduled message overlay without
fetching any data.
2023-05-01 22:45:03 -07:00
Aman Agrawal eb5f679121 scheduled_messages_overlay_ui: Use CSS to display no scheduled messages. 2023-05-01 22:45:03 -07:00
Aman Agrawal 1b60019c60 schedule: Remove 'Schedule' state of compose box.
Fixes #25340

This means that we now schedule the message simply after selecting
time if the message is valid.

Also, editing scheduled messages will now delete the scheduled
message and open compose with scheduled message.
2023-05-01 22:45:03 -07:00
Anders Kaseorg 8f2f2654a5 web: Avoid slow jQuery :selected selector.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-05-01 22:39:31 -07:00
Anders Kaseorg ff2a7b775a web: Avoid slow jQuery :input, :checkbox, :radio selectors.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-05-01 22:39:31 -07:00
Lalit 7aa1763d73 typeahead: Delete display mode slash commands.
This commit deletes `/fixed-width` and `/fluid-width` slash commands
from the typeahead and also hides the slash commands `/light` and
`/dark` in production.

Fixes #25374.
2023-05-01 22:31:04 -07:00
Tim Abbott 7425079814 topic_list: Show muted unread counts in muted streams.
When all the unread messages in a muted stream are in specifically
muted topics, this ensures that the total unread count for the stream
that the user sees before clicking "more topics" will match the total
unreads number for the stream itself.

This behavior is limited to muted streams, since in a normal / not
muted stream, we don't display a "muted topics only" faded unread
count by the stream's summary line to avoid distracting the user with
it, we match that behavior for the "more topics" line.

We also now display the `@` , again to ensure the stream's summary
line never displays an `@` without some topic row having one.
2023-05-01 21:13:53 -07:00
Anders Kaseorg ba170b4aee util: Speed up clean_user_content_links by persisting an inert document.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-05-01 20:55:01 -07:00
Anders Kaseorg c951b72884 right_sidebar: Fix use of undefined realm_rendered_description.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-05-01 20:55:01 -07:00
N-Shar-ma 1480eca7d5 hotkey: Update deprecation notices to use Shift for capital letters.
To make the deprecation notices consistent with how we format shortcut
keys, we use "Shift +" prefix for capital letters, and write small
letters as capitals.
2023-05-01 20:32:58 -07:00
N-Shar-ma c6ba33b7b4 hotkey: Repurpose `s` to toggle conversation view and remove `shift+s`.
Earlier, the `s` hotkey just narrowed to the stream of the selected
message (to a topic), while `shift+s` narrowed to the conversation view
(topic / dm) of the selected message.

Now, the `shift+s` hotkey has been removed (but retained for toggling
subscription to a stream when the stream overlay is active), and the `s`
hotkey takes on double duty: if the current view is not topic / dm, it
narrows to that, else when in topic view, it switches to stream view. It
has no effect when in dm view. Documentation has been updated for this
both in the help center, and the in-app `Keyboard shortcuts` menu.

A deprecation notice has been added for `shift+s` as well.

Fixes: #24226.
2023-05-01 20:32:58 -07:00
Hardik Dharmani d7114dc291 left_sidebar: Drop underlined behaviour on focus for <a> elements.
Fixes #25359
2023-05-01 20:32:35 -07:00
Tim Abbott 18e2cee572 typeahead: Do not prioritize exact name matches for users.
As discussed in the comment, this resulted in the many inactive users
in chat.zulip.org with "Tim" as their full display name from being
incorrectly prioritized over me in a stream where I've been active;
and this class of problem seems like it will be common in large open
communities.

This reverts a portion of 4dc1b2f812,
with explanatory comments for why this behavior is preferred.

The stream name changes in the original PR remain very helpful.
2023-05-01 17:10:59 -07:00
Tim Abbott 0b7dd46530 stream settings: Improve label for stream edit modal.
"Change stream info" was very ambigious about what types of
information can be changed in the modal in question.
2023-05-01 17:04:17 -07:00
Tim Abbott 2dd1ff7bfd stream settings: Use tippy-zulip-delayed-tooltip more.
This fixes an issue where the "Change stream info" button would
display a tooltip immediately upon closing the modal to edit the
stream name and description.
2023-05-01 17:04:17 -07:00
Lauryn Menard a5b527f321 onboarding: Specialize Welcome Bot message for education organizations.
Because education organizations and users have slightly specialized
use cases, we update the Welcome Bot message content sent to new
users and new organization owners for these types of organizations
to link to help center articles/guides geared toward these users
and organizations.

Also, updates the demo organization warning to only go to the new
demo organization owner because the 30 day deletion text is only
definitely accurate when the organization is created.

Fixes #21694.
2023-05-01 16:48:48 -07:00
Karl Stolley aa78d9bf26 docs: Make a few surface fixes. 2023-05-01 16:37:27 -07:00
Karl Stolley 7f06baf360 docs: Polish usage assumptions copy. 2023-05-01 16:37:27 -07:00
sbansal1999 323d749189 status-message: Add margin-top to sender info to avoid overlap.
Earlier, the sender info would overlap with the edit compose
area because of another class applying "margin-top" to keep
the sender info properly aligned when the message is not being
edited. However, that "margin-top" had to be changed when the edit
compose is opened.

This commits adds that "margin-top" to sender info to make sure
that it doesn't overlap with the edit compose area.
2023-05-01 16:36:37 -07:00
Alex Vandiver 8a3236638a docs: Update sharding docs for single-org sharding option.
Co-authored-by: Tim Abbott <tabbott@zulip.com>
2023-05-01 11:28:08 -07:00
Alex Vandiver 510b96046a docs: Update production docs for local S3 caching. 2023-05-01 11:28:08 -07:00
Aman Agrawal a02f431036 css: Fix date row overlapping with message header.
When there was an unread message below date row, the date
row overlaps with the message header.

This was a result of #23538 not adjusting the message header
z-index along with the z-index of date row.
2023-05-01 10:56:44 -07:00
sbansal1999 aa33ae4af8 ts: Convert resolved_topic.js to TypeScript. 2023-05-01 10:55:36 -07:00
Daniil Fadeev 914ed51d70 compose: Fix buttons in error banners is not clickable. 2023-05-01 10:37:09 -07:00
sbansal1999 eb56703310 lint: Update line-length for commit message to 72 in gitlint.
This commit updates the line-length for commit message in gitlint
to 72, as recommened in the documentation.
2023-05-01 10:35:52 -07:00
sbansal1999 6b599d521f docs: Update recommended commit summary length to 72 characters.
This commit updates the recommended commit summary length
to 72 characters in the documentation. If the commit message
exceeds this length than GitHub cutoffs the remaining characters.
2023-05-01 10:35:52 -07:00
Lauryn Menard 06dd7a3a68 emails: Add corporate_enabled to context for emails.
In commit fc58c35c0, we added a check in various emails for the
settings.CORPORATE_ENABLED value, but that context is only always
included for views/templates with a request.

Here we add that to common_context, which is often used when there
is not a request (like with emails). And we manually add it to the
email context in various cases when there is not a user account to
call with common_context: new user invitations, registration emails,
and realm reactivation emails.
2023-05-01 10:32:43 -07:00
Steve Howell 663170f0d3 code cleanup: Alphabetize event types in switch statement. 2023-05-01 07:26:51 -07:00
Daniil Fadeev f1db695650 emails: Fix body tag styles being applied in messages template. 2023-05-01 07:13:50 -07:00
Tim Abbott 6fe02e933a timerender: Extract new variant of get_full_datetime.
Separating these concepts allows us to provide a much nicer format for
contexts where ultra-specific clarification is not a priority.

This new variant is currently only used in the scheduled messages UI.
2023-04-30 22:39:52 -07:00
PALASH BADERIA 341f3a1ce2
tippy: Add message_list_tooltip helper to clear tooltips on rerender.
We've had a series of bugs where tooltips get leaked when a message list
is rerendered. For some tooltips, we used a 'mutation observer' to remove the tooltip
in this situation, but this was expensive and messy. We replace this with a Tippy
plugin to keep track of this class of tooltips, with a central hook to remove them
during rendering.

Message lists are rerendered in the background in a variety of situations;
a simple way to trigger it is clicking the mute/unmute topic/stream button in
the topic menu/stream menu and the clickable area overlaps with the
message list tooltips area. If a tooltip was visible at the time, the tooltip loses its
reference due to the re-rendering removing its DOM element, appearing at the top-left corner.

To prevent this behavior for all message list tooltips, we need to
store all instances of the message list tooltips and then destroy
them if the instances does refer to something else then document.body
using the 'destroy_all_message_list_instances' function just
before re-rendering.

Whenever the message list is rendered, all the message list tooltips
will be destroyed if they do not refer to document.body. This
prevents the double appearance of those tooltips if the reference
is removed from the DOM.

This plugin allows us to remove the mutation observers and net delete code
while hopefully fixing this bug for the whole app.
2023-04-30 22:33:14 -07:00
Tim Abbott 368d2aa27d compose: Fix misaligment of compose top right icons.
When composing a private message to a different recipient than the
current view, the go-to-compose-target icon looked vertically
misaligned with these icons. Fix this by removing the CSS rule that
made these other top-corner icons not centered within their row.
2023-04-30 21:02:21 -07:00
Hardik Dharmani 69779688f0 settings: Update disabled state of button in email change modal.
The new update_submit_disabled_state_on_change feature of the
dialog_widget component makes this simple.

Fixes #22683.
2023-04-30 20:56:51 -07:00
Hardik Dharmani 96d6fda2a7 dialog_widget: Add support for managing submit button disabled state.
The new update_submit_disabled_state_on_change parameter configures
the dialog_widget system to disable/enable the confirmation button
depending on whether any of the fields in the modal have values
differing from their initial values.

Fixes #22683.
2023-04-30 20:56:49 -07:00
sbansal1999 33705b6116 tooltips: Remove keyboard shortcuts from View Scheduled Messages modal.
This commit removes the keyboard shortcut from tooltips that
can be seen when hovering over the two buttons in
"View Scheduled Messages" modal.

This is a temporary change as the keyboard shortcut will be
added to the tooltips when the shortcuts are actually working.
2023-04-30 20:34:53 -07:00
Aman Agrawal eeb3ff26e1 css: Fix loading spinner position for messages loading indicator. 2023-04-29 07:21:19 -07:00
Lalit 3e179a2c58 actions_popover: Hide "Add emoji reaction" in action menu in spectator mode.
We should hide the "Add emoji reaction" from the message action menu while a
user is not logged in, that is user is in public access mode.

Fixes #25331.
2023-04-28 20:09:24 -07:00
palashb01 acba8518fb recent: Replace presence dot with bot icon for bots.
This commit replaces the presence dot with a bot icon for
private messages (PMs) with bots in the recent conversations
narrow.
2023-04-28 19:14:00 -07:00
palashb01 8eb90bbc7f left_sidebar: Fix the opacity of group,bot icons.
This commit fixes the opacity of the group-icon and bot-icon
in the left-sidebar direct message section to make them look
 more consistent with the other icons in the left sidebar.
2023-04-28 19:14:00 -07:00
palashb01 cee0cabd8d left_sidebar: Replace the presence dot with bot icon for bots.
This commit replaces the presence dot display with a bot icon
for bots in the left sidebar PM list.
2023-04-28 19:14:00 -07:00
palashb01 29377c7f32 user_card: Fix the padding of bot-icon with name.
This commit fixes the padding of the bot-icon with the name
to make it look consistent with the way it is displayed in
the message feed.
2023-04-28 19:14:00 -07:00
palashb01 bb4d2f5f5b profile_popover: Remove the display presence dot for bots.
This commit removes the presence dot display for bots and fixes
the gap between the bot name and bot icon in the user profile
popover. It also fixes the alignment of the bot icon.

Fixes: #25066
2023-04-28 19:14:00 -07:00
evykassirer 199afbe8eb messagebox: Update background-color for mentions.
This is part of #22059.
2023-04-28 19:06:50 -07:00
Tim Abbott 56c5c8902b scheduled_messages: Disallow dates in the past in the UI.
The server will probably accept them and just send the message
immediately, which seems OK, but we probably want to discourage
scheduling a message to be sent in the past, since that's unlikely to
be intentional and would make it hard to undo.
2023-04-28 19:01:40 -07:00