Commit Graph

1438 Commits

Author SHA1 Message Date
David Rosa 707fa87c74 help: Document `=` keyboard shortcut.
Documents the new shortcut in the `?` menu, Keyboard Shortcuts page,
and Emoji Reactions page.
2023-03-24 12:58:35 -07:00
Anders Kaseorg 39b48e85a4 recent_topics_row: Remove unused dataset attributes from template.
Commit 084cbd4ff7 (#15064) removed the
.data() calls that inspected these.

Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-03-23 13:34:59 -07:00
Anders Kaseorg 36475daba7 templates: Remove references to undefined fields.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-03-22 17:10:28 -07:00
Anders Kaseorg 5d7da7e537 settings_bots: Avoid Handlebars iteration with block parameters.
The fix at https://github.com/handlebars-lang/handlebars.js/pull/1855
is not released yet.

Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-03-22 17:10:28 -07:00
Lauryn Menard 90205a490d account-settings: Pass delivery email to change email modal.
When we converted the change email form to a dialog widget modal,
in commit f43d3b9986, the page_params value for delivery email
that was being referenced in the handlebars template
`change_email_modal.hbs` was not set, so instead an empty string
was the initial input value. Because the email change dialog
widget post_render callback sets the input value to the same
delivery email, the fact that the email was not being set when
the template was initially rendered was not noticable.

Passes the page_params.delivery_email to the html parameter in
dialog_widget.launch so that the template has the initial value
set when the form is initially rendered. Removes the now redundant
post_render callback, which resets the initial input value to the
same delivery email.
2023-03-22 11:18:49 -07:00
Lauryn Menard 25fb810d81 account-settings: Pass password page params to dialog widget.
When the password change form was converted to a dialog widget
modal, in commit f5fbf5f0e0, the page_params values for
password_min_length and password_min_guesses that were referenced
in the handlebars template `dialog_change_password.hbs` had no
value to set, which meant the password quality bar was no longer
checking the input value against those organization settings.

Passes the page_params values for password_min_length and
password_min_guesses to the html parameter in dialog_widet.launch
for the password change modal so that those values are available
and set when the template is rendered.
2023-03-22 11:18:49 -07:00
Tim Abbott 35440672a7 message_list: Rename confusing hide-date CSS class.
The previous hide-date CSS class had a semantic meaning of "this
recipient row has the same date as the previous one"; since we're now
having logic read that value, it's worth giving it a semantic name
that makes that code easier to understand.
2023-03-21 12:55:13 -07:00
Aman Agrawal 05674f3ab5 pm_list_item: Convert pm_user_status to a class.
Since there are multiple elements that use pm_user_status, it
makes sense to have it as a class.
2023-03-21 10:53:25 -07:00
Joelute 4d55192e21 compose_typeahead: Add hint text to topic typeahead dropdown.
With the autocomplete dropdown, some users face trouble or uncertainty
while selecting topics. The autocomplete dropdown may encourage users
to find and select an existing topic rather than starting a new topic.
The changes adds a hint text to the topic typeahead dropdown to
encourage users to either start a new topic or select an existing
topic.

Fixes #23295.
2023-03-20 16:28:28 -07:00
Aman Agrawal c4903fe85a message_row: Fix rewrapping message lines after receiving ack.
Since the message time of locally echoed messages were not displayed
and their width was restricted by `notvisible` CSS class, it
resulted in width available to message text changing after the message
was successfully sent and the time was displayed.

To fix this, we just try to set opacity of the message time to 0
for locally echoed messages.
2023-03-17 08:10:13 -07:00
Anders Kaseorg 83b6866018 templates: Replace unnecessary {{#tr}} blocks with {{t}} helper.
`{{#tr}}` supports HTML and allows translators to accidentally
introduce HTML, so it’s safer to use the `{{t}}` helper unless HTML is
needed.

Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-03-16 11:26:45 -07:00
Anders Kaseorg d693b53aa6 templates: Fix &nbsp; syntax.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-03-15 16:34:32 -07:00
Palash Baderia bf51277226 popovers: Add confirmation modal for marking all messages as read.
This commit adds a confirmation modal with loading spinner for
marking all messages as read.

New file: confirm_mark_all_as_read.hbs
Fixes: #24624
2023-03-15 08:17:41 -07:00
Prakhar Pratyush ae72777c77 user_settings: Automate 'Include realm name in message email subject'.
Currently, there is a checkbox setting for whether to
"Include realm name in subject of message notification emails".

This commit replaces the checkbox setting with a dropdown
having values: Automatic [default], Always, Never.

The Automatic option includes the realm name if, and only if,
there are multiple Zulip realms associated with the user's email.

Tests are added and(or) modified.

Fixes: #19905.
2023-03-14 17:48:57 -07:00
Ujjawal Modi 0eca9cb319 bots: Improve bots permission banner.
Added a separate template file for banner
messages in bots panel under personal and organisation
settings.

Banners for bots panel under personal
settings are shown only when user cannot add bots.
Banners for bots panel under organisation settings are shown
only when user cannot add bots or user is administrator.

Fixes #24155
2023-03-09 17:52:31 -08:00
palashb01 189ceee8f0 display_settings: Move the 'user-list-style' out of Emoji section.
Move the 'user-list-style' checkbox from the 'Emoji' section to the
'Advanced' section, and update the 'settings_display.js' file by
replacing the 'theme-settings' classname with 'advanced-settings'
classname to display the success banner of 'user-list-style' checkbox
with the 'Advanced' title.
2023-03-09 16:12:45 -08:00
palashb01 3dd84910f4 display_settings: Rename and reorder the theme dropdown menu.
Rename 'Sync with computer' to 'Automatic (follows system settings)',
'Light Theme' to 'Light' and 'Dark Theme' to 'Dark', and rename the
color scheme label to 'Theme'.

Reorder the dropdown menu to have light theme before dark theme.
2023-03-09 16:12:45 -08:00
palashb01 af07db7971 display_settings: Rename 'Theme' section to 'Emoji'.
Rename the 'Theme' section to 'Emoji'. Since there is no 'Theme' section
anymore, replace the 'theme-settings' classname with
'emoji-display-settings' in the 'settings_display.js' file.

The existing "Theme" selector dropdown is moved from the now the
'Emoji' section to the 'General' section.
2023-03-09 16:12:45 -08:00
palashb01 2067c71a93 display_settings: Rename and update the 'language-time' section.
Rename the 'language-time' title to 'General'. As the 'language-time'
section no longer exists, replace the 'lang-time-settings' classname
with the 'general-settings' classname in the 'settings_display.js' file.

Updated the 'change-the-time-format.md' and 'change-your-language.md'
documentation files to reflect these changes.

To pass the puppeteer_test Replaced the 'lang-time-settings-status'
classname to 'general-settings-status' inside 'settings.test.ts' file.
2023-03-09 16:12:45 -08:00
Manas Jayaswal 3e24a05e66
settings: Improve wording of "Show API key" modal.
This commit changes the "Show API key" modal to use a more intuitive
description of the user's password field, and also to put the reset password
option, which should be the less common case, at the end.

Fixes: #24506.
2023-03-08 18:48:37 -08:00
evykassirer 1df3b4f86f search: Rename .search_button to more correct .search_close_button. 2023-03-07 15:38:11 -08:00
Pranav Joglekar 2c316ce1ac
gear_menu: Update 'Support Zulip' link.
Previously the 'Support Zulip' option linked to Github Sponsors.
We now link to our own https://zulip.com/help/support-zulip-project,
which describes more options for how to support the project.

Fixes #24230.
2023-03-06 08:01:56 -08:00
Lauryn Menard 69e224cd87 templates: Add `rendered_markdown` class to confirm emoji warning.
Adds a `div` wrapper with the `rendered_markdown` class to the
content in `confirm_emoji_settings_warning.hbs`, so that the
inline code element has the intended CSS rules applied.

Because the `p` element also has the `rendered_markdown` class,
the margins for this element in the modal are slightly changed
(3px on top/bottom). Previously, the margins for this element were
being set from a bootstrap rule (10px on bottom).
2023-03-03 14:08:08 -08:00
Sahil Batra 8a0b99cb39 streams: Align stream type icons in "Archive stream" modal.
This commit adds inline_decorated_stream_name component
which is used to show stream name along with its privacy
type icon. This component is added such that we can align
the icon and stream name properly as there are many
instances where the icon and name are not aligned in the
current UI.

This component is only used in "Archive stream" modal for
now and will be used for other UIs as well in future.
2023-03-03 11:10:45 -08:00
Ujjawal Modi 18059e132d user groups: Enabled sorting of subscribers.
The new `#groups` overlay does not allow sorting of subscribers.
This commit adds support for sorting of subscribers.
2023-03-03 11:03:12 -08:00
Lauryn Menard bfa8a2438b templates: Revise explanatory text in code playground org settings.
Revises descriptive text and examples at the top of the code
playgrounds tab in the organization settings overlay to be shorter,
have only one example that includes the name field.

Also, adds the `rendered_markdown` class to the HTML code elements,
via an HTML span element so that the specific CSS rules for code
elements with that class will be applied to these examples.
2023-03-02 18:14:35 -08:00
Lauryn Menard 23bac34f08 templates: Revise explanatory text/example in linkifiers org settings.
Revises descriptive text and examples at the top of the linkifiers
tab in the organization settings overlay to be shorter, have only
one example and updates help center link text for capitalization.

Adds a link to the help center in the form/input area for adding
a new linkifier, which is consitent with the code playgrounds tab,
and means the link would be there if the form was converted to a
modal.

Also, adds the `rendered_markdown` class to the HTML code elements,
via an HTML span element so that the specific CSS rules for code
elements with that class will be applied to these examples.
2023-03-02 18:14:35 -08:00
Ujjawal Modi 5cf98d8653 streams: Allow sorting of stream members.
Stream members table in Create stream and stream subscribers UI
can now be sorted.
Fixes #21341
2023-03-01 17:29:01 -08:00
Sahil Batra f9c739ab9d modals: Update checkbox in deactivate user modal to be same as others.
This commit changes the design of checkbox in deactivate user modal
to be same as others in the app. We have added parent element with
".new-style" class for now, since we have this for all other checkbox
in the app and this seems to be the simplest solution.

In future, we plan to remove the "new-style" class and instead add
CSS based on a component for checkbox elements.
2023-03-01 16:34:12 -08:00
Palash Baderia c1009bc051 settings: Drop column from tables on narrow screen.
Drop the "last_active" column in the users section of the
organization settings, and the "Bot_type" column in the bots
section on sm_min (576px or less). Also, drop the "Date_muted"
column in the muted topics section of the personal settings
on ml_min (425px or less).

Added new className "topic_date_muted" for the date_muted
column, and "bot_type" for the bot_type column, to hide them
using display none when the viewport is small.

Fixes: #24320
2023-03-01 15:42:15 -08:00
Ganesh Pawar 5a5203144d modal: Make the modal content scrollable instead of the whole modal.
Earlier, if the content of the modal (apart from the header and footer)
overflowed, the whole modal would become scrollable which would hide
the modal header and footer on scrolling. This commit makes only
the modal content scrollable and keeps the modal header and
footer static.
2023-03-01 15:36:29 -08:00
David Rosa 15fd5299af help: Update filenames "private message" -> "direct message".
Renames files, updates references, and adds URL redirects.
2023-02-28 16:55:13 -08:00
Ganesh Pawar 537617b46d invite_user: Convert overlay to `dialog_widget`.
Fixes #22957.
2023-02-26 18:37:05 -08:00
Lauryn Menard 42775219b3 private-messages: Update frontend strings to use "direct message" or "DM".
Updates frontend user-facing strings with "private message" or "PM" to
use "direct message" or "DM" respectively instead.

Note that this updates translated strings as well as a few that
are not translated like search suggestions.

Updates `tools/lib/capitalization.py` for some specific strings
that are impacted by these changes, and removes "PM" and "PMs"
from checked strings.
2023-02-24 11:47:26 -08:00
Sahil Batra 0620d2ac1b settings: Add "modal_select" to select element for custom user field.
Same template fike is used to show user custom profile fields in
both profile page in settings and in manage user modal. For select
elements in modals, the CSS is handled using modal_select class.
This commit adds modal_select class to the select element used for
custom user field, which already has settings_select class, so that
the CSS are also applied to the select element in manage user modal.
2023-02-24 09:13:09 -08:00
Palash Baderia d8adc6de1c personal_settings: Add deactivate organization button for organization.
Added a 'Deactivate Organization' button inside the
'Personal Settings > Account & Privacy'. This button only appears
when the organization owner is the only user present. To verify this,
I used the 'get_active_human_count' function from the 'people.js'.

To remove duplication, a function has been created inside settings_org
file to handle the click event for the two buttons present inside
personal_settings and organization_settings that perform the same
action of deactivating organization. The click handler is defined in
the click_handlers.js file, which calls the dialog for deactivating
the organization. Previously, the error used to appear at the top of
the organization_settings, but now it appears inside the dialog box
itself.

To remove the duplication of two buttons having the same IDs,changed
the Id `deactivate_realm_button` to a className.

Fixes: #24105
2023-02-23 18:17:28 -08:00
N-Shar-ma 599a32bee9 hotkey: Add `z` shortcut to zoom to message `near` view.
A new hotkey, lowercase `z` (for `zoom`) has been implemented to allow
the user to go to the near view of the selected message with 1 keypress.
Documentation has been added for this both in the help center, and the
in-app `Keyboard shortcuts` menu.

The effect is identical to clicking on a message's timestamp, which
links to that message's near view.

Fixes: #24227.
2023-02-23 17:47:45 -08:00
Anders Kaseorg c1675913a2 web: Move web app to ‘web’ directory.
Ever since we started bundling the app with webpack, there’s been less
and less overlap between our ‘static’ directory (files belonging to
the frontend app) and Django’s interpretation of the ‘static’
directory (files served directly to the web).

Split the app out to its own ‘web’ directory outside of ‘static’, and
remove all the custom collectstatic --ignore rules.  This makes it
much clearer what’s actually being served to the web, and what’s being
bundled by webpack.  It also shrinks the release tarball by 3%.

Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-02-23 16:04:17 -08:00