Until a demo organization creator sets an email address, we want to
restrict other users from joining the organization. Therefore, we
disable changing the "invite_required" setting for the organization
until they set their email address. Otherwise, the owner could
share the demo organization URL with someone and they could create
an account via the homepage.
Checks the demo organization owner delivery email address state
on the server-side.
Disables updating the organization setting in the web app UI.
This commit adds code to live update the UI when
can_create_user_groups setting changes.
The elements that are live updated are -
- Icon button at the top left panel
- Button shown in right panel when no group
is selected.
- Text shown in right panel mentioning whether
user has permission.
We do not live update the text shown when left
panel is empty as it is somewhat complex to
handle all conditions correctly for it.
"stream-advanced-configurations" was being used as ID for
advanced configurations section in both stream edit and
creation UI, which is not correct as ID should be unique.
This commit fixes it by removing the ID and instead using
class in selectors. Also, there was some unused CSS, as
we do not have dropdown widget buttons in advanced
configurations section, written using the duplicate ID so
removed that as well.
This commit fixes the use of "stream_permission_settings"
as ID for "Channel permissions" subsection in both
stream edit and creation UI, which was not correct since
ID should be unique.
To fix this ID was removed from the element and following
changes are done -
- $("#stream_settings") element is now used as a container
for live update functions for stream edit UI.
- "stream-permissions" class is used to access the element
instead of ID.
- Advanced configurations container also had "stream-permissions"
class before, and that was removed in this commit so that
"Channel permissions" container can be identified uniquely
and thus some CSS changes were needed.
- Also, fixed "update_stream_privacy_choices" function to
not use ":visible" in selectors.
Fixes#33627
In Move messages and Move topic modals,
Show a warning banner if any of current topic participants
are NOT subscribed to the destination stream.
Inside the banner, Show participant names if
number of conversation participants
is <= 5; otherwise, show only the count.
This commit adds support for unarchiving archived channels
by introducing the `is_archived` parameter to the
`PATCH /streams/{stream_id}` API endpoint. Sending a PATCH
request with `is_archived: false` will unarchive the specified
channel.
This commit fixes the toggleable area of the advanced configurations
subsection in the channel settings, preventing the toggle action from
interfering with the save discard widget.
Work towards #34244.
Now that we're supporting partial subscriber data, we might need
to fetch the full list of subscribers when opening the subscribers
tab of the edit channel modal.
This commit handles a slow load with a loading spinner while we fetch
the data, and also makes sure to ignore the data if it's received after
it stops being relevant (in case the user has another stream's data open).
This commit adds a new personal setting
`resolved_topic_notice_auto_read_policy` which controls how
resolved-topic notices are marked as read for a user.
Fixes#33599.
Match the behavior of the user list for loading avatar images: if the
image does not load, maintain the grey fallback background color.
Before this change, the avatar in the navbar started as a grey box while
it was waiting for the image to load, but it disappeared after it failed
to do so. This is because the grey background was attached to the `img`
element, which is hidden after it fails to load the image.
In this change, we attach the necessary styling, including background
color and size, to a new surrounding `div` tag instead of the `img`.
(The existing surrounding `a` tag has its own size styles that we should
leave alone.)
Fixes part of #19123.
There is no technical reason to block updating the authentication
methods for the demo organization when the owner has not yet set
an email.
If they get locked out of the demo organization when they set an
email address for their account, they can just create another demo
organization. These organizations are primarily intended to be
temporary sandboxes for trying out Zulip.
Co-authored-by: Maneesh Shukla <shuklamaneesh24@gmail.com>
Migrate the demo organization warning that's shown on all the tabs
for organization settings to use the shared banner code.
Updates links in the current warning to be buttons in the banner,
and matches the navbar alert banner for demo organizations.
Fixes#34447.
Work towards #34244.
Note that this doesn't show the right counts when the counts appear, because
yet. We can double check functionality after that change is complete.
This commit
- Replace the blank option with an italicized option that's the current
default language, if there is one selected with "default" label.
- Make the "text" option more informative by adding (no highlighting)
to the label.
- Remove the hint for "text".
- Prioritize as left to right, before start typing:
blank/default language, text, quote, spoiler, math, everything else...
fixes: #33682
Instead of using the "tip" formatting for the note suggesting
updating the name for the owner's account before inviting other
users, to be just normal text at the top of the modal.
Part of #34447.
For the DM conversation with the current user, use "Messages with
yourself" for the message header bar and tooltip.
Fixes#33321.
Co-authored-by: Lauryn Menard <lauryn@zulip.com>
Adds "You" and "Drafts from conversations with yourself" as
labels in the drafts overlay for the DM conversation with
the current user.
Co-authored-by: Lauryn Menard <lauryn@zulip.com>
When the compose box is closed, if the selected message is for the
direct conversation with the current user, then we show "Message
yourself" as the compose reply button text.
Adds `decode_dm_recipients_user_ids_from_url` helper function to
hash_util, which parses a narrow URL for DM recipient user IDs.
Checks that "dm" operand, which should be a string of user emails,
also passes the check for all the email addresses being valid
compose recipients.
Co-Authored-By: Lauryn Menard <lauryn@zulip.com>
Since inbox only has unread topics visible, rows having no
unread counter was not handled. Added that support so that
inbox style channel view can use it.
Instead of adding group as a subgroup, we now provide option
to add direct members and direct subgroups of a group to a
user group by providing an expand button in the group pill.
Fixes#32335.
Until the owner of a demo organization sets an email, the submit
button on the invite user modal is now disabled.
The input div for email addresses is also disabled, which wasn't
disabled before because it's not an input element on the form.
In the invite users modal, if the demo organization owner hasn't
yet added an email to their account, hide the banners with tips
for setting up organization information before inviting users.
This commit removes the `.thinner` class from the
"Play animated images" setting in Preferences > Information,
and from the "Home view" setting in Preferences > Navigation.
The `.setting-next-is-related` class, used in combination with
the `.thinner` class, is also removed as it is not needed.
We no longer use the `.thinner` class.