mirror of
				https://github.com/zulip/zulip.git
				synced 2025-11-04 05:53:43 +00:00 
			
		
		
		
	emoji-reactions: Fix reactions to not break inline-block display.
This fixes the reactions to not break a new line by changing them from a weird combination of “float: left” and “display: block” (inlined), to just “display: inline-block”. With fixes from Harshit Bansal for an issue with using the hotkeys in a filtered popover. Fixes: #4818.
This commit is contained in:
		
				
					committed by
					
						
						Tim Abbott
					
				
			
			
				
	
			
			
			
						parent
						
							bc15085098
						
					
				
				
					commit
					a88ca9fafc
				
			@@ -97,7 +97,7 @@ var reaction_show_list = []; // local reaction_show_list
 | 
			
		||||
exports.render_reaction_show_list = function () {
 | 
			
		||||
    var reaction_list = $(".emoji-popover-emoji");
 | 
			
		||||
    reaction_show_list = reaction_list.filter(function () {
 | 
			
		||||
        return this.style.display === "block" || this.style.display === "";
 | 
			
		||||
        return $(this).css('display') === "inline-block";
 | 
			
		||||
    }).toArray();
 | 
			
		||||
};
 | 
			
		||||
 | 
			
		||||
@@ -106,14 +106,15 @@ function filter_emojis() {
 | 
			
		||||
    var search_term = elt.val().trim().toLowerCase();
 | 
			
		||||
    var reaction_list = $(".emoji-popover-emoji");
 | 
			
		||||
    if (search_term !== '') {
 | 
			
		||||
        reaction_list.filter(function () {
 | 
			
		||||
            return this.title.indexOf(search_term) === -1;
 | 
			
		||||
        }).css("display", "none");
 | 
			
		||||
        reaction_list.filter(function () {
 | 
			
		||||
            return this.title.indexOf(search_term) !== -1;
 | 
			
		||||
        }).css("display", "block");
 | 
			
		||||
        reaction_list.each(function () {
 | 
			
		||||
            if (this.title.indexOf(search_term) === -1) {
 | 
			
		||||
                this.classList.add("hide");
 | 
			
		||||
            } else {
 | 
			
		||||
                this.classList.remove("hide");
 | 
			
		||||
            }
 | 
			
		||||
        });
 | 
			
		||||
    } else {
 | 
			
		||||
        reaction_list.css("display", "block");
 | 
			
		||||
        reaction_list.removeClass("hide");
 | 
			
		||||
    }
 | 
			
		||||
    exports.render_reaction_show_list();
 | 
			
		||||
}
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user