Room list: assign room to section when section is created (#33240)
* feat(rls): return section tag when created * feat(vm): assign section tag to room when section created * test: update exisiting tests * test(e2e): check that room is in section
This commit is contained in:
@@ -400,8 +400,12 @@ export class RoomListItemViewModel
|
||||
echoChamber.notificationVolume = elementNotifState;
|
||||
};
|
||||
|
||||
public onCreateSection = (): void => {
|
||||
RoomListStoreV3.instance.createSection();
|
||||
public onCreateSection = async (): Promise<void> => {
|
||||
const newTag = await RoomListStoreV3.instance.createSection();
|
||||
// Add the room to the section
|
||||
if (newTag) {
|
||||
tagRoom(this.props.room, newTag);
|
||||
}
|
||||
};
|
||||
|
||||
public onToggleSection = (tag: string): void => {
|
||||
|
||||
Reference in New Issue
Block a user