Add a 'click' event listener to the user pills in
stream and group settings which toggles the
user_card_popover.
Co-authored-by: PieterCK <pieterceka123@gmail.com>.
While rendering input pills in input_pills.create function,
pass in the user_id or group_id accordingly.
Display the id as an html attribute in input_pill.hbs.
Co-authored-by: Pieter CK <pieterceka123@gmail.com>.
When input pills are hovered, the 'x' button is highlighted.
This commit ensures that 'x' button is highlighted only if the
'x' button is hovered, not anywhere else on the pill.
Author: ecxtacy <dc.dhruvchouhan@gmail.com>.
Added new utility function to hash_parser to dynamically
detect the hash category of an URL. This is intended to
reduce the need of adding more adhoc hash_parser utility
functions.
Since #private_message_recipient is a <div contenteditable>,
not an <input> or <textarea>, it doesn’t make sense to call
.val() (it will always give the empty string).
It looks like this line is from over 10 years ago
(09deef9611 (diff-f2b22549dc2fb4824b37e787d964a2c9f4f580e767f86b6d7ded1d0ff37d5a62R291))
and probably before we had pills here. We can just remove this
whole block.
Reproducer:
* Start with empty hash and combined feed as home view.
* Go to any narrow.
* Keep pressing escape key.
You will keep switching between narrow view and home view while
you should just stop at home view. This was due to
`set_hash_to_home_view` not considering empty hash as a valid
home view hash.
This commit refines word wrapping in user profile popovers. It implements 'overflow-wrap: break-word;' for category ‘name’ items (e.g., ‘Email’, ‘User ID’) and 'overflow-wrap: anywhere;' for category ‘value’ segments, ensuring proper line breaks and preventing overflow issues. Additionally, addressed prettier problems to maintain code consistency.
Fixes#22865
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.
Since we were trying to close dialog widget regardless of caller
after marking messages as read, it results in an error if the dialog
widget is not open especially since there was no dialog widget
involved in the process.
So, track the id of the dialog widget which called the `read` `op`
and operate on it based on it's status if there was a dialog
widget involved.
This commit fixes the margins around banner for default stream
subscriptions, shown to users who cannot subscribe others, to
be same as that for other banners like the one shown when
description is not set for the organization.
The bug was due to the element being accessed when not present
in the DOM. This function fixes it by calling the function to
setup streams UI only when the concerned elements are present
in DOM, i.e. when user can subscribe others.
The bug was introduced in 016917679e.
Fixed 2 bugs in the detection of the last message row copied. This fixes
the issue where when the mouse was released on the message header after
copying multiple messages, the pasted text was not formatted correctly.
Follow up to #30091.
This commit adds code to use include_default_realm_subscriptions
when user selects "Subscribe to default streams" checkbox
in the invite modal instead of passing the stream ids of
default streams.
To avoid event handlers being lost when we restore a message edit
form we go through the process of creating the edit form for the
message again. This has the additional benefit of updating the
status of buttons based on org settings like GIF or upload button.
Fixes#30083.
We have used the dark theme color for the left sidebar row hover:
`--color-background-active-narrow-filter`. We are not using that variable
directly since we don't want a change in that color affecting the color in
recent conversations.
We've also used a single color on hover compared to 2 different colors
for unread and read row before. Light mode also uses a single color on
hover.
Relevant CZO conversation:
https://chat.zulip.org/#narrow/stream/101-design/topic/Hover.20color.20in.20Recent.20conversations.20dark.20mode.2E/near/1797727
Adds description in views styled like stream descriptions also adds a
help center link to the appropriate page at the end of each
description.
Fixes#29769.
Change type annotations of get_user_ids and create_item_from_group_name
to accept CombinedPillContainer and InputPillItem<CombinedPillItem>
respectively.
Change type annotations of get_user_ids and create_item_from_stream_name
to accept CombinedPillContainer and InputPillItem<CombinedPillItem>
respectively.
Earlier, the compose textarea and the preview (container) occupied the
same grid area, 1 at a time. Now, they are both children of a common div
which is assigned the same grid area. This allows adding more elements
to the same grid area in the future.
This is purely a code change and should have no visible effects.
This is a prep commit for relocating the compose expand / collapse
buttons to the top right inside corner of the textarea / preview.
Reproducer:
* Go to a stream narrow.
* Scroll up to select a previous message.
* Click on a different stream in the left sidebar.
* Click browser back button, you land at first unread message instead
of your selected message.
Fixed by updating the hash before we render the new message list.
With combined feed no longer cached, this test became flaky as
it took longer for combined feed to load.
Verified that other tests waiting on `.message-list` don't need
this change.
When the request to mark a thread as unread fails, we should use the
value of include_anchor that was sent in the request, not false.
Modified handle_mark_unread_from_here_error to take an object instead of
parameters.
Since there are no rows to set focus in recent view before initial
fetch, we were falling back to set focus on input filter after
rendering recent view.
Waiting for initial fetch to complete helps us set focus on the
table easily while recent view is also open for user to play with
if the load takes longer.
The `margin-bottom` was removed for the last element in the preview in
e55f5a1b59 to remove vertical shifts when
toggling preview mode, but it is not needed for image / video previews,
so now `margin-bottom` is not set to 0 for the last inline preview.
In 61b3c698af we stopped restoring widgets
from the cache, so the only purpose of the cache remaining was to access
the event handler patched onto the widget jquery.
Now instead of the entire jquery object, we cache just the event handler
since that's the only thing we need from the cache, and do not patch it
onto the widget jquery object.
Use the "/json/messages/flags" instead of "/json/messages/flags/narrow"
when we have fully fetched the current view.
Update messages on the basis of id instead of updating the entire
narrow.
Fixes#28945.
Since the reference for these typeaheads is has a fixed position
unlike say message controls which move on scroll and need to be
repositioned, we can use `fixed` position for typeaheads too so
there is no jumps when user is trying to scroll when a typeahead
is active.
This basically replaces the commit where where we remove `fixed`
as an argument to `Typeahead` library. We can add it later if
any of our typeaheads don't need to be fixed positioned.
When compose box is expanded, typeahead overlfows the top of the window.
We move the typeahead to the bottom of the screen and let
preventOverflow shift it into the visible area.
To better make use of server load when fetching message history for
users, we limit how much history we fetch in the initial loading
experience based on how much time in the organization's message
history it corresponds to.
Co-authored-by: Tim Abbott <tabbott@zulip.com>