As mentioned in the XEP, don't show error messages for OMEMO messages
that can't be decrypted because they were already decrypted before or
because they weren't encrypted for this device.
This let's us populate the `from_real_jid` attribute for messages in
cases where the user's nickname has changed.
Only save the occupant-id if the MUC supports it
Store all advertised features on the `chatbox.features` model.
This allows us to look up a feature without using the async
`disco.supports` API.
Updates #2241
- Unregister nickname before sending unavailable presence
- Send unavailable presence before destroying state
- Call `leave` after unregistering, otherwise the disco entry for the MUC gets removed in `leave` while it's still necessary to unregister
- Wrap `this.leave` in try/except in `onConnectionStatusChanged` handler
- Add new MUC connection status, `CLOSING` to avoid `this.leave()` being called when `hidden` gets set to `true` while the MUC is in the process of being closed.
I noticed that a marker was sent for an error message (created due to an
unencryptable OMEMO messages), and this caused the user to be kicked
from the MUC.
even if the global configuration is to disallow it.
* When parsing, include all media URLs, not just the ones from allowed domains.
That makes it possible to change allowed domains on-the-fly,
while still allowing media in individual messages to be shown manually
(via the message actions dropdown).
* Merge `embed_audio`, `embed_video` and `show_images_inline` into `render_media`
* Create new config settings for allowable domains for images, video and audio
* Check the URL domain against a whitelist for the message actions dropdown
Add caps element to the MUC join presence, so that the MUC MEP node can
know whether we're interested in receiving MEP messages.
Create info messages for any `conference-info` tags that contain `activity` tags.
Check for both `headline` and `normal` MEP messages (even though the XEP
only show `headline` examples), since `normal` messages can be archived
in MAM, but `headline` ones not.
Update the XEP-0372 reference-parsing code to take the `anchor`
attribute into consideration, specifically to check which text element
the reference applies to.
Add support for rendering XEP-0372 mentions in "info" messages and for
triggering HTML5 Desktop notifications for such mentions.
Background:
-----------
XEP-0316 describes a way for a MUC to send out PEP-like messages to MUC
participants. This feature can be used to describe custom activity happening
in the MUC.
It's the only way I could get a failing test (due to the Jasmine upgrade AFAIK) to pass.
I don't understand why this happens, given that the promise has a
`catch` clause in `retractOwnMessage`, but for some reason the promise
rejection gets caught by Jasmine, causing the test to fail.
The disco entities collection gets recreated and repopulated every time
the connection is re-established or after the user logs in again after
having logged out.
The old disco entities weren't being removed, due to an erroneous
`shouldClearCache` call (not applicable to sessionStorage data).
In addition we need a handler to fire and clear the entities cache when
Converse is going to restart.
This prevents it from being persisted across page loads and makes more
sense logically.
Also move markScrolled to utils and MUC unread messages indicator to bottom panel.
If set to a positive integer, the chat history will be kept to that size
by removing older messages.
This happens as new messages come in (as long as the chat isn't scrolled up)
and when the user scrolls down.
Also add the `pruning_behavior` setting
More work on making bottom panel sub-components declarative
- Handle auto-completion in the converse-muc-message-form element
- Make message limit indicator a component
- Rename template
This causes an empty bookmarks list in the controlbox, because the
collection gets cleared (and then asynchronousy repopulated) while the
`bookmarksInitialized` promise stays `true` (resulting in a race
condition).
Alternative fix could be to clear the bookmarks and recreate the promise
before reconnecting but doesn't seem necessary to do all that work.
Had to make various other changes due to incompatibilities.
- Use the new `lit` package instead of `lit-html` or `lit-element`
- Drop `haunted` since it breaks the rules by specifying `type: module`
but then doesn't import with file extensions
- Use Sass Dart instead of node-sass (fixes#2445)
- Upgrade Karma
- Update to the latest @converse/skeletor (which uses mergebounce to batch writes)
- Flush storage before logging out
- Flush when reloading the tab
- Create initStorage method
when creating occupant from affiliation change stanza.
This means that when a presence for that occupant arrives, a duplicate
occupant is created (presumably because the original can't be find due
to the wrong nick being set).