Commit Graph

37 Commits

Author SHA1 Message Date
Lauryn Menard 1dc7ad13a9 invite-modal: Move "invite_as" name attribute to select element. 2024-11-05 08:49:28 -08:00
Lauryn Menard 15f010d6c9 invite-modal: Update custom time input element.
Adds "custom-expiration-time-input" name to input element and orders
attributes in template for readability.
2024-11-05 08:49:28 -08:00
Lauryn Menard 62b365cb31 invite-modal: Add name attribute to custom time unit select element.
Reorders the select element attributes to be more readable.
2024-11-05 08:49:28 -08:00
Lauryn Menard 8d79adceed invite-modal: Remove unused "custom_time_choice" name and class.
In HTML, option elements do not use/have the "name" attribute, so
the custom time choice select options do not need it to be set.

The "custom_time_choice" class is not referenced anywhere else in
the codebase, so it can be removed to make this template more
readable.
2024-11-05 08:49:28 -08:00
Lauryn Menard 8c900ff0fb invite-modal: Move "expires_in" name attribute to select element.
The "name" attribute should be on the select element and not on
the nested option elements.
2024-11-05 08:49:28 -08:00
Lauryn Menard 3d5c72f762 invite-modal: Remove "expires_in" for attribute for custom time input.
The "for" attribute on this label meant that clicking the label moved
the focus to the select element above the custom time input element.
2024-11-05 08:49:28 -08:00
opmkumar d6aae75f04 invites: Use shared helper function for setting expiration text.
Moves and renames `set_expires_on_text` to settings_components.ts,
so that it can be used in other modals with user set time inputs
that show a formatted string of that time input.

Updates invite_user_modal.hbs for the class names used in the new
shared helper function.

Co-authored-by: Ujjawal Modi <umodi2003@gmail.com>
Co-authored-by: Lauryn Menard <lauryn@zulip.com>
2024-11-01 09:55:05 -07:00
opmkumar 789a47fb6b invites: Use shared custom time helper function.
Moves `set_custom_time_inputs_visibility` function to
settings_components.ts so that it can be reused in
other modals with user set custom time inputs.

Updates user_invite_modal.hbs to use the class name
in the new shared helper function.

Co-authored-by: Ujjawal Modi <umodi2003@gmail.com>
Co-authored-by: Lauryn Menard <lauryn@zulip.com>
2024-11-01 09:55:05 -07:00
opmkumar 523dc7e2be invite-user-modal: Add general class names for improved extensibility.
Adds general class names in invite_user_modal.hbs for custom time
the input and unit so that these elements more easily be extended
for use in other modals with a user specified custom time.

Updates the listener in invite.ts that was using the removed
"custom-expiration-time" class to instead use the id for the
input and unit div, "custom-invite-expiration-time".

Corresponding updates have been made to the relevant CSS files to
ensure consistent styling and future scalability.

Co-authored-by: Ujjawal Modi <umodi2003@gmail.com>
Co-authored-by: Lauryn Menard <lauryn@zulip.com>
2024-11-01 09:55:05 -07:00
Lauryn Menard cc1a3eeec1 invite-user-modal: Internationalize custom time unit options.
Prep for using these values other modals, specifically the
deactivate realm modal.
2024-10-16 15:21:40 -07:00
Aditya Kumar Kasaudhan 3b1877ea99 invite: Add guest visibility note with live-updating user count.
Previously, when the guest role was selected in the Invite modal and
guests were restricted from viewing all other users, there was no
indication of how many users the invited guests would be able to see
once they joined.

This commit resolves that issue by adding a note in the Invite modal
that dynamically informs users of the number of visible users.

Fixes #31159.
2024-10-15 16:19:00 -07:00
Karl Stolley 554221e3c8 cleanup: Remove structural .new-style references. 2024-09-11 14:22:45 -07:00
Karl Stolley d91321a2c4 cleanup: Remove singleton .new-style class refs. 2024-09-11 14:22:45 -07:00
Karl Stolley 8c984f68ec checkboxes: Decouple label.checkbox from .new-style tangle. 2024-09-11 14:22:45 -07:00
Karl Stolley 99111a90d7 invite_modal: Simplify Administrator, Owner role labels. 2024-07-23 13:54:11 -07:00
Tim Abbott f7c9c0753b invite_user: Streams => Channels in placeholder.
The PR adding this stream was written before the streams/channels
transition.
2024-07-09 16:42:23 -07:00
Shashank Singh 4cce94b667 invites: Add option to receive notification on accepted invitations.
Previously, when a referrer's invitation to Zulip was accepted,
they got a notification from notification-bot indicating
their invitation has been accepted.

This commit adds an option for referrer to decide
whether he wants to receive the direct notification
from the notification-bot.

Fixes: #20398
2024-07-05 17:14:45 -07:00
sanchi-t 2d79ce2e93 invite: Replace stream checkboxes list with stream pills.
Introduce an input field with typeahead functionality, initially
populated with the default streams for the organization.

Fixes #26871.
2024-06-22 20:04:28 -07:00
Ujjawal Modi cdbc20d304 invite-user-modal: Remove duplicate CSS rules.
Removes some CSS rules used in the invite user modal that were
already being applied via the shared `modal_select` class.

Co-authored-by: Lauryn Menard <lauryn@zulip.com>
2024-06-20 12:26:29 -07:00
Lauryn Menard 7a61044a03 org-settings: Update tab for default channel settings.
Updates instances of default-streams-list to instead be
default-channels-list as the data-section for the organization
settings overlay is part of the URL hash.
2024-05-15 12:18:36 -07:00
Sahil Batra f73f27b45f invite: Replace "streams" with "channels" in default subs banner.
This commit replaces "streams" with "channels" in the banner for
default channel subscriptions shown to user user who cannot
subscribe others.
2024-05-15 10:59:05 -07:00
Sahil Batra 016917679e invites: Do not show streams if user cannot subscribe others.
We do not show the streams list in invite modal if the user
does not have permission to subscribe others to stream and
show a notice mentioning it.
2024-05-14 14:20:07 -07:00
Sahil Batra 040486776c modals: Add bottom margin to label elements.
This commit adds bottom margin to label elements of
different inputs by adding "modal-field-label" class
to the label elements. Some of them already have the
margin due to having dropdown-title class.
2024-05-03 09:51:36 -07:00
Lauryn Menard 4dcb0258a5 web-i18n: Update frontend translated strings for stream rename channel.
Updates translated strings in web/ that do not need updates to any
tests. The majority of these strings are also unique to the file/
template that they are in. A few have overlap with one other file.

Some changes here update placeholders/variables in these strings to
no longer use stream so that all the translation updates for this
rename happen at the same time.

The exception to this are cases of "<z-stream>" placeholders in
these translated strings.

Part of the stream to channel rename project.
2024-04-24 14:35:04 -07:00
Kislay Verma 505d66afeb user_invite: Convert invite modal to tabbed format.
This commit converts the radio buttons (for
selecting email/link) to tab
components in the user invite modal.

The selected tab is in focus by default and arrow keys
can be used to toggle the selected tab.

Appropriate tooltips are shown when a tab is disabled.

Fixes #29392.
2024-04-12 08:23:00 -07:00
adnan-td 87dee7a9b2 invite_user_modal: Replaced email text_area with input_pill.
This makes the widget considerably more attractive, and probably a bit
more usable.

Fixes #29391.
2024-03-29 11:13:03 -07:00
Prakhar Pratyush ab453fbe20 settings: Rename notifications_stream to new_stream_announce..._stream.
This commit renames the realm-level setting 'notifications_stream'
to 'new_stream_announcements_stream'.

The new name reflects better what the setting does.
2024-02-21 09:04:23 -08:00
Sahil Batra 6b459c0ea4 invite: Re-add bootstrap CSS rules for btn-link elements.
This commit re-adds the bootstrap CSS rules for the specific
btn-link elements in invite modal to zulip.css. This is part
of the bootstrap removal project.
2024-01-26 09:10:09 -08:00
Sahil Batra 78440033dc invite: Fix label for new user's role dropdown.
This commit updates label for new user's role dropdown to use
"Users" instead of "User(s)" because that caused some problems
in translating the text.

We should ideally be using the ICU plural syntax for such cases,
but since it is used as label, we cannot use the plural syntax
there. So we instead just change it to always have "Users"
plural like we do at some other places in that modal.
2023-11-27 22:18:04 -08:00
Sayam Samal 2cb4210319 invite: Add setup tips to user invite modal.
We include setup tips to the user invite modal for the following
cases:

At the top of the invite modal
- If the org description is missing.
- If the org profile picture is missing.
- If the custom profile fields have not been added, where we also
  provide a link to the default user settings for the time being,
  until we have a better way to compare if the default user settings
  have been changed.

We also use the new banner ui to display these tips. In doing so, we
extract the banner component from `compose_banner.hbs` to
`popover_banner.hbs`, removing any compose specific code from the
banner component.

Fixes: #24262

Co-authored-by: Lalit <lalitkumarsingh3716@gmail.com>
2023-11-22 09:03:19 -08:00
Lauryn Menard b4f02a336d demo-orgs: Add section on configuring email address to help article.
Adds a section to the demo organizations help center article about
configuring an email and password for demo organization owners.

For demo organization warning banners about needing to configure
an email, add a link to the new section in the help article.

Also, adds a related articles section to the help center article,
and updates the current draft text for changes in how the demo
organization feature is being implemented.
2023-09-08 15:17:23 -07:00
Lauryn Menard 3ef2c9e0cf demo-orgs: Update invite users warning to be same as auth methods.
To reduce extra work for translators, make text for warning banners
and tooltips in demo organizations when the organization owner has
not configured an email address consistent.
2023-09-08 15:17:23 -07:00
Lauryn Menard 2e00ca4197 demo-orgs: Disable invite_user_modal if email not configured.
Because demo organization owners do not initially have an email
set, some of the personal and organization settings in the web-app
UI should be disabled/hidden until the owner configures an email
address for their account.

Disables the form input elements in the invite user modal if the
user's email is not configured. Also displays a tip at the top of
the modal to let the user know why the form is disabled.
2023-08-31 15:02:16 -07:00
Akarsh Jain e20e7482ca invite: Restructure "Invite user" modal for improved user experience.
This commit revamps the invite type section of the "Invite user" modal
to provide a more intuitive user experience. The section now includes a
radio button option with two choices: "Send an email" and "Generate an
invite link." The email input box is hidden when the "Generate an invite
link" option is selected.

Fixes #24692.
2023-06-06 17:48:29 -07:00
Sahil Batra 0ec16407ba invite: Add checkbox to select all default streams.
We now add a checkbox in "Steams they should join" to directly
select all default streams in the realm for the invite.
We hide the stream list if that option is selected.
2023-05-09 17:05:18 -07:00
Lauryn Menard af0b450817 templates: Update `invite_users_modal.hbs` for undefined variables.
Removes undefined `time_input` from  `invite_users_modal.hbs`.
The default input value for the expiration custom time limit is
not set until the "custom" option is selected from the dropdown.

Removes the undefined `csrf_input` from the same template. And
imports `csrf.ts` into `invite.js` to get the csrf token and
add it to the request data, which is the current pattern used
in other `/web/src` modules.
2023-04-10 09:07:11 -07:00
Ganesh Pawar 537617b46d invite_user: Convert overlay to `dialog_widget`.
Fixes #22957.
2023-02-26 18:37:05 -08:00