starred_messages_ui: Add initialize method for this module.

We need to call `rerender_ui` once on the initial page load, hence we
need to initialize `starred_message` module and call `rerender_ui`
together.

Fixes #25935.
This commit is contained in:
Lalit 2023-06-08 16:15:14 +05:30 committed by Tim Abbott
parent 2b2866b9e6
commit cabd0106f3
2 changed files with 7 additions and 2 deletions

View File

@ -99,3 +99,8 @@ export function confirm_unstar_all_messages_in_topic(stream_id, topic) {
on_click,
});
}
export function initialize() {
starred_messages.initialize();
rerender_ui();
}

View File

@ -91,7 +91,7 @@ import * as settings_realm_user_settings_defaults from "./settings_realm_user_se
import * as settings_sections from "./settings_sections";
import * as settings_toggle from "./settings_toggle";
import * as spoilers from "./spoilers";
import * as starred_messages from "./starred_messages";
import * as starred_messages_ui from "./starred_messages_ui";
import * as stream_data from "./stream_data";
import * as stream_edit from "./stream_edit";
import * as stream_edit_subscribers from "./stream_edit_subscribers";
@ -725,7 +725,7 @@ export function initialize_everything() {
sent_messages.initialize();
hotspots.initialize();
typing.initialize();
starred_messages.initialize();
starred_messages_ui.initialize();
user_status_ui.initialize();
fenced_code.initialize(generated_pygments_data);
message_edit_history.initialize();