mirror of https://github.com/zulip/zulip.git
Hide/Show Optimization with #group-pm-list.
The #group-pm-list now only should change state from hidden to displayed once, which removes time spent recalculating styles in the DOM.
This commit is contained in:
parent
a2ebb066b4
commit
e7687bff6f
|
@ -330,11 +330,11 @@ function actually_update_users_for_search() {
|
|||
var update_users_for_search = _.throttle(actually_update_users_for_search, 50);
|
||||
|
||||
function show_huddles() {
|
||||
$('#group-pm-list').expectOne().show();
|
||||
$('#group-pm-list').addClass("show");
|
||||
}
|
||||
|
||||
function hide_huddles() {
|
||||
$('#group-pm-list').expectOne().hide();
|
||||
$('#group-pm-list').removeClass("show");
|
||||
}
|
||||
|
||||
exports.update_huddles = function () {
|
||||
|
|
|
@ -191,6 +191,10 @@
|
|||
display: none;
|
||||
}
|
||||
|
||||
#group-pm-list.show {
|
||||
display: block;
|
||||
}
|
||||
|
||||
#userlist-header,
|
||||
#group-pm-header {
|
||||
border-top: 1px solid #e2e2e2;
|
||||
|
|
Loading…
Reference in New Issue