* Only update the room list after shown.bs.modal * add changes to CHANGES.md * Move shown listener to initialize
This commit is contained in:
parent
f68eb65cd7
commit
15aef10d5d
|
@ -34,6 +34,7 @@ Soon we'll deprecate the latter, so prepare now.
|
|||
- #2201: added html to converse.env
|
||||
- #2213: added CustomElement to converse.env
|
||||
- #2220: fix rendering of emojis in case `use_system_emojis == false` (again).
|
||||
- #2092: fixes room list update loop when having the `locked_muc_domain` truthy or `'hidden'`
|
||||
- The `api.archive.query` method no longer accepts an RSM instance as argument.
|
||||
- The plugin `converse-uniview` has been removed and its functionality merged into `converse-chatboxviews`
|
||||
- Removed the mockups from the project. Recommended to use tests instead.
|
||||
|
|
|
@ -93,6 +93,11 @@ export default BootstrapModal.extend({
|
|||
this.model.save('muc_domain', api.settings.get('muc_domain'));
|
||||
}
|
||||
this.listenTo(this.model, 'change:muc_domain', this.onDomainChange);
|
||||
|
||||
this.el.addEventListener('shown.bs.modal', () => api.settings.get('locked_muc_domain')
|
||||
? this.updateRoomsList()
|
||||
: this.el.querySelector('input[name="server"]').focus()
|
||||
);
|
||||
},
|
||||
|
||||
toHTML () {
|
||||
|
@ -110,17 +115,6 @@ export default BootstrapModal.extend({
|
|||
}));
|
||||
},
|
||||
|
||||
afterRender () {
|
||||
if (api.settings.get('locked_muc_domain')) {
|
||||
this.updateRoomsList();
|
||||
} else {
|
||||
this.el.addEventListener('shown.bs.modal',
|
||||
() => this.el.querySelector('input[name="server"]').focus(),
|
||||
false
|
||||
);
|
||||
}
|
||||
},
|
||||
|
||||
openRoom (ev) {
|
||||
ev.preventDefault();
|
||||
const jid = ev.target.getAttribute('data-room-jid');
|
||||
|
|
Loading…
Reference in New Issue