Commit Graph

28 Commits

Author SHA1 Message Date
JC Brand
abe21dce66 Include origin-id in outgoing messages 2019-02-08 15:34:16 -07:00
JC Brand
e1f8d53c46 Initial support for chat markers. Updates #324 2019-02-01 15:05:13 +01:00
JC Brand
3c0e3d3fab Refactor out createMessage.
Changes:

* Avoids leaky abstraction of MUC code into converse-chatboxes
* Avoid creating unnecessary message objects (e.g. without <body)
* Add fix for #1369.
* Rename spec/chatroom.js to spec/muc.js
2019-01-28 13:27:25 +01:00
JC Brand
dc07440de8 Bugfix. Don't create chats for messages without body 2019-01-10 21:47:50 +01:00
JC Brand
d051085626 Only clear textarea once message was sent
This now requires `sendMessage` to return a boolean to indicate success.
Disable the textarea while message is being sent.
2018-12-21 05:58:22 +01:00
Christoph Scholz
d2d64952a0 set store hint on receipts and type='chat' 2018-12-17 15:20:21 +01:00
JC Brand
49efe390f9 Fix typo 2018-12-17 11:42:43 +01:00
JC Brand
a389f52adb Fixes #1353 Don't expect delivery receipts to have type chat 2018-12-16 11:22:13 +01:00
Christoph Scholz
216a684904 prevent message delivery receipts for carbons and own 2018-12-15 20:04:31 +01:00
JC Brand
d5485d09ae Always render the OMEMO lock icon
When OMEMO isn't possible, render it as grey.

This change makes OMEMO for MUCs easier, since there I anticipate that
OMEMO support might change dynamically based on who enters/exits the
room.

updates #1180
2018-12-14 11:25:57 +01:00
JC Brand
5dacb96b78 Don't try to create ChatBox from controlbox data in embedded mode
updates #1374
2018-12-12 18:52:41 +01:00
JC Brand
e38daf34f7 Remove coupling between converse-chatboxes and converse-roster
In embedded mode (singleton) we don't need or want the roster, so we
should be able to disable it.

updates #1374
2018-12-12 18:52:40 +01:00
JC Brand
79bfb45639 Use async/await in MAM code and tests 2018-12-06 13:10:33 +01:00
Christoph Scholz
267d91a4f3 don't send receipt requests in MUCs 2018-11-20 17:38:59 +01:00
JC Brand
067d87a73e Fix failing test 2018-11-14 15:15:29 +01:00
JC Brand
7cb889b065 Fixes #1317 Don't show errors for CSI messages 2018-11-14 14:34:23 +01:00
Christoph Scholz
da5ca0b585 implement XEP-0184: Message Delivery Receipts 2018-11-13 17:13:35 +01:00
JC Brand
3f751b3af4 Add guard for non-existing chat_state value 2018-11-12 20:59:43 +01:00
JC Brand
d9093c09ee Fixes #1312 2018-11-07 12:11:22 +01:00
Emmanuel Gil Peyrot
5cd7ccb3ef Correctly display error when HTTP File Upload isn’t supported by the server. 2018-11-03 00:55:18 +01:00
JC Brand
2f9089ee10 Updates #1261 More file upload fixes 2018-10-26 14:45:36 +02:00
JC Brand
6519083414 Revert to explicit Promise-based code.
* src/converse-controlbox.js

    async/await causes many tests here to fail due to the controlbox toggle
    now apparently showing up a little later (and the tests don't wait for
    it to happen).

* src/converse-minimize.js

    We get timeout issues in tests.

* src/headless/converse-chatboxes.js

    We get a stack overflow while running tests.
2018-10-26 12:53:01 +02:00
JC Brand
55fce912df
Merge branch 'master' into async-await 2018-10-25 18:36:04 +02:00
JC Brand
e0f0617629 Don't store the File object in browserStorage
With the recent fixes in backbone.browserStorage, the 'file' attributes
gets persisted to browserStorage before Converse tries to upload the
file.

The File object can't actually be serialized, so an empty map gets
stored and then returned together with a 'change' event.

Instead, store the file as a direct attribute on the message object.

Fixes #1261
2018-10-24 22:59:43 +02:00
Emmanuel Gil Peyrot
35b7dbe389 Convert a few functions to async/await. 2018-10-24 21:23:32 +02:00
JC Brand
7b2d64b066 Use _converse.api.send instead of _converse.connection.send
so that we can emit an event when sending a stanza.
2018-10-23 16:06:43 +02:00
JC Brand
6904f9a897 Use es2015 modules instead of UMD 2018-10-23 12:25:58 +02:00
JC Brand
18024b8bd2 Store lerna packages in the src directory
- Also update versions in package.json
- Update Makefile
2018-10-22 13:29:25 +02:00