mirror of
https://github.com/zulip/zulip.git
synced 2025-10-22 20:42:14 +00:00
left_sidebar: Improve text selection for topic text.
Fixes: #34959. Signed-off-by: apoorvapendse <apoorvavpendse@gmail.com>
This commit is contained in:
committed by
Tim Abbott
parent
622a125ce4
commit
4288734030
@@ -610,6 +610,11 @@ export function initialize({
|
||||
return;
|
||||
}
|
||||
|
||||
if (document.getSelection()?.type === "Range") {
|
||||
// To avoid the click behavior if a topic link is selected.
|
||||
e.preventDefault();
|
||||
return;
|
||||
}
|
||||
const $stream_row = $(e.target).parents(".narrow-filter");
|
||||
const stream_id_string = $stream_row.attr("data-stream-id");
|
||||
assert(stream_id_string !== undefined);
|
||||
|
@@ -1654,6 +1654,10 @@ li.active-sub-filter {
|
||||
}
|
||||
}
|
||||
|
||||
.topic-box {
|
||||
user-select: text;
|
||||
}
|
||||
|
||||
.searching-for-more-topics {
|
||||
margin-left: var(--left-sidebar-toggle-width-offset);
|
||||
height: var(--line-height-sidebar-row-prominent);
|
||||
|
@@ -1,5 +1,5 @@
|
||||
<li class="bottom_left_row {{#if is_active_topic}}active-sub-filter{{/if}} {{#if is_zero}}zero-topic-unreads{{/if}} {{#if is_muted}}muted_topic{{/if}} {{#if is_unmuted_or_followed}}unmuted_or_followed_topic{{/if}} topic-list-item" data-topic-name="{{topic_name}}">
|
||||
<a href="{{url}}" class="topic-box">
|
||||
<a href="{{url}}" class="topic-box" draggable="false">
|
||||
<span class="sidebar-topic-check">
|
||||
{{topic_resolved_prefix}}
|
||||
</span>
|
||||
|
Reference in New Issue
Block a user