mirror of https://github.com/zulip/zulip.git
communities: Copy code from integrations to toggle_categories_dropdown.
This is used on mobile widths to toggle categories dropdown.
This commit is contained in:
parent
7c0edf356c
commit
9d6dcb9a9d
|
@ -14,10 +14,19 @@ function sync_open_organizations_page_with_current_hash(): void {
|
|||
}
|
||||
}
|
||||
|
||||
function toggle_categories_dropdown(): void {
|
||||
const $dropdown_list = $(".integration-categories-dropdown .dropdown-list");
|
||||
$dropdown_list.slideToggle(250);
|
||||
}
|
||||
|
||||
// init
|
||||
$(() => {
|
||||
sync_open_organizations_page_with_current_hash();
|
||||
$(window).on("hashchange", () => {
|
||||
sync_open_organizations_page_with_current_hash();
|
||||
});
|
||||
|
||||
$(".integration-categories-dropdown .dropdown-toggle").on("click", () => {
|
||||
toggle_categories_dropdown();
|
||||
});
|
||||
});
|
||||
|
|
Loading…
Reference in New Issue