diff --git a/web/src/settings_users.js b/web/src/settings_users.js index edf5ed09c8..39017565b2 100644 --- a/web/src/settings_users.js +++ b/web/src/settings_users.js @@ -70,37 +70,25 @@ export function update_view_on_deactivate(user_id) { } const $button = $row.find("button.deactivate"); - const $user_role = $row.find(".user_role"); $button.prop("disabled", false); $row.find("button.open-user-form").hide(); $row.find("i.deactivated-user-icon").show(); $button.addClass("btn-warning reactivate"); $button.removeClass("deactivate btn-danger"); $button.empty().append($("").addClass(["fa", "fa-user-plus"]).attr("aria-hidden", "true")); + $row.removeClass("reactivated_user"); $row.addClass("deactivated_user"); - - if ($user_role) { - const user_id = $row.data("user-id"); - $user_role.text( - `${$t({defaultMessage: "Deactivated"})} (${people.get_user_type(user_id)})`, - ); - } } function update_view_on_reactivate($row) { const $button = $row.find("button.reactivate"); - const $user_role = $row.find(".user_role"); $row.find("button.open-user-form").show(); $row.find("i.deactivated-user-icon").hide(); $button.addClass("btn-danger deactivate"); $button.removeClass("btn-warning reactivate"); $button.empty().append($("").addClass(["fa", "fa-user-times"]).attr("aria-hidden", "true")); $row.removeClass("deactivated_user"); - - if ($user_role) { - const user_id = $row.data("user-id"); - $user_role.text(people.get_user_type(user_id)); - } + $row.addClass("reactivated_user"); } function get_status_field() { diff --git a/web/styles/settings.css b/web/styles/settings.css index 91af685898..6bff22d3ce 100644 --- a/web/styles/settings.css +++ b/web/styles/settings.css @@ -2050,6 +2050,15 @@ $option_title_width: 180px; } } +#admin_users_table .deactivated_user, +#admin_deactivated_users_table .reactivated_user { + color: hsl(0deg 0% 64%); + + & a { + color: inherit; + } +} + .settings_url_input, .settings_text_input { padding: 4px 6px;