immediately apply changes to chat info
This commit is contained in:
@@ -189,7 +189,7 @@ export default class ChatViewModel extends ContextHost<ChatPageTypes> {
|
|||||||
this.messagePageViewModel.handleReaction(reaction);
|
this.messagePageViewModel.handleReaction(reaction);
|
||||||
},
|
},
|
||||||
);
|
);
|
||||||
chatModel.changeHandlerManager.setHandler(this.chatModel.id, this.settingsPageViewModel.preloadData);
|
chatModel.changeHandlerManager.setHandler(this.chatModel.id, this.settingsPageViewModel.updateData);
|
||||||
|
|
||||||
// load
|
// load
|
||||||
this.loadPageSelection();
|
this.loadPageSelection();
|
||||||
|
|||||||
@@ -89,6 +89,12 @@ export default class SettingsPageViewModel extends Context {
|
|||||||
this.color.value = this.chatViewModel.chatModel.color;
|
this.color.value = this.chatViewModel.chatModel.color;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
updateData = (): void => {
|
||||||
|
this.preloadData();
|
||||||
|
this.nameInput.value = this.name.value;
|
||||||
|
this.chatViewModel.resetColor();
|
||||||
|
}
|
||||||
|
|
||||||
loadData = (): void => {
|
loadData = (): void => {
|
||||||
this.nameInput.value = this.name.value;
|
this.nameInput.value = this.name.value;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user