mirror of
https://github.com/zulip/zulip.git
synced 2026-06-30 21:11:04 +08:00
settings_users: Reactivated user should not get un-greyed on sort.
On reactivate or deactivate, we add appropriate class through JQuery. But that class only remains there until sort, on sort any of these added classes will be removed. We did not face the problem of un-greying for active users page, because deactivated_users class was added to the HTML always if `is_active` was false for the user. In this commit, we rename `reactivated_user` to `active-user` and this class will be present for all active users, even on the active users table. For the deactivated users table, we will have scoped css that will grey out the row with `active-user` class.
This commit is contained in:
parent
0dc8402221
commit
2becb41931
@ -97,7 +97,7 @@ export function update_view_on_deactivate(user_id) {
|
||||
$button.addClass("btn-warning reactivate");
|
||||
$button.removeClass("deactivate btn-danger");
|
||||
$button.empty().append($("<i>").addClass(["fa", "fa-user-plus"]).attr("aria-hidden", "true"));
|
||||
$row.removeClass("reactivated_user");
|
||||
$row.removeClass("active-user");
|
||||
$row.addClass("deactivated_user");
|
||||
|
||||
should_redraw_active_users_list = true;
|
||||
@ -116,7 +116,7 @@ export function update_view_on_reactivate(user_id) {
|
||||
$button.removeClass("btn-warning reactivate");
|
||||
$button.empty().append($("<i>").addClass(["fa", "fa-user-times"]).attr("aria-hidden", "true"));
|
||||
$row.removeClass("deactivated_user");
|
||||
$row.addClass("reactivated_user");
|
||||
$row.addClass("active-user");
|
||||
|
||||
should_redraw_active_users_list = true;
|
||||
should_redraw_deactivated_users_list = true;
|
||||
|
||||
@ -1966,7 +1966,7 @@ $option_title_width: 180px;
|
||||
}
|
||||
|
||||
#admin_users_table .deactivated_user,
|
||||
#admin_deactivated_users_table .reactivated_user {
|
||||
#admin_deactivated_users_table .active-user {
|
||||
color: hsl(0deg 0% 64%);
|
||||
|
||||
& a {
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
<tr class="user_row{{#unless is_active}} deactivated_user{{/unless}}" data-user-id="{{user_id}}">
|
||||
<tr class="user_row{{#if is_active}} active-user{{else}} deactivated_user{{/if}}" data-user-id="{{user_id}}">
|
||||
<td>
|
||||
<span class="user_name" >
|
||||
<a data-user-id="{{user_id}}" class="view_user_profile" tabindex="0">{{full_name}}</a>
|
||||
|
||||
Loading…
Reference in New Issue
Block a user