Commit Graph

1323 Commits

Author SHA1 Message Date
Senya
2b8f6c4363 Add backbone.overview as a dependency for chatboxes (#1016) 2018-02-14 00:39:56 +01:00
JC Brand
2d746d2a1e Make converse-muc-embedded a core plugin.
1. Add a new `view_mode` value: `embedded`.

   This value is used to determine wether the `converse-muc-embedded`
   plugin is active or not.

2. Remove the need for the #converse-embedded-chat element.

   Instead we reuse the #conversejs element and embed inside that.

3. Removed the need to manually blacklist core plugins

   This is now done automatically if `view_mode` is set to `embedded`.
   Perhaps eventually we don't blacklist at all and instead use the
   `enable` plugin method. For some that probably won't work, like
   `converse-chatview`, which we still need to be active.
2018-02-09 16:37:55 +01:00
JC Brand
56aa45b1d3 Set auto_reconnect to true by default. 2018-02-09 16:37:55 +01:00
JC Brand
ba9c3b01ed Set converse on the window and trigger an event after loaded.
Setting it on `window` is necessary to have it available inside a
webcomponent.

Triggering an event is necessary so that we don't call
`converse.initialize` too early.
2018-02-09 16:37:55 +01:00
JC Brand
5517e3554c Add a new configuration setting: root 2018-02-09 16:08:39 +01:00
JC Brand
03b9447f1d Asynchronously render spoiler button only if all clients support it 2018-02-08 17:48:15 +01:00
JC Brand
680f30412a Bugfix. Object values for defaults passed-by-reference 2018-02-08 17:06:36 +01:00
JC Brand
055c4d2104 New config setting allow_public_bookmarks 2018-02-08 15:39:27 +01:00
JC Brand
ba09996998 Don't allow PEP bookmarks if #publish-options is not advertised 2018-02-08 09:49:05 +01:00
JC Brand
fbef370b65 Listen for new room bookmarks pushed from the user's PEP service 2018-02-07 21:59:45 +01:00
JC Brand
5f3761dc7f Only initialize bookmarks and show icon if PEP is supported
which we check by checking if the PEP identity is provided.
https://xmpp.org/extensions/xep-0163.html#support
2018-02-07 21:05:38 +01:00
JC Brand
bbe47b465d Looks like this ain't necessary
Also, the condition was the opposite of what it should have been.
2018-02-07 17:26:09 +01:00
JC Brand
1759cc1672 Advertise support for spoilers 2018-02-07 17:25:49 +01:00
JC Brand
d4ceb6d340 Add the ability to query for a disco identity 2018-02-07 17:24:25 +01:00
JC Brand
4732f315ed Use "hidden message" instead of spoiler 2018-02-07 14:39:45 +01:00
JC Brand
f267ee5ae0 Looks like new messages can have an archive_id 2018-02-07 14:28:35 +01:00
JC Brand
4742e66b69 Fix linting errors and failing tests 2018-02-07 14:21:46 +01:00
JC Brand
9c3e9233e4 Test that the spoiler button is hidden when OTR is active 2018-02-07 13:16:34 +01:00
JC Brand
aab957b0b8 Show only icon for OTR button 2018-02-07 11:16:24 +01:00
JC Brand
86a962bee2 Don't render message form via separate Backbone.View
Appeared to only complicate things...
2018-02-07 11:16:24 +01:00
JC Brand
cc4d4a6f40 Properly configure visibility of spoiler toolbar button 2018-02-07 10:32:21 +01:00
JC Brand
e34fa5d635 Style the spoiler 2018-02-07 10:30:06 +01:00
JC Brand
20706cb617 Expand the spoiler tests 2018-02-06 21:21:21 +01:00
JC Brand
f6db2a9167 Use template to render the spoiler message. 2018-02-06 18:58:06 +01:00
JC Brand
3b850c77ea Move focus method into ChatBoxMessageForm 2018-02-06 18:05:12 +01:00
JC Brand
7ee0b19409 Move code to chatview 2018-02-06 18:05:12 +01:00
JC Brand
253c4d736e Focus the textarea after toggling between spoiler or not 2018-02-06 18:05:12 +01:00
JC Brand
19d9e281ae Update css and keep input and textarea values across toggles 2018-02-06 18:05:12 +01:00
JC Brand
d5348ea899 Render the message form via VDOMView 2018-02-06 18:05:12 +01:00
JC Brand
4e077aac08 Start moving code from the plugin to converse-chatview 2018-02-06 18:05:12 +01:00
JC Brand
400bdf775d More refactoring of spoilers code 2018-02-06 18:05:12 +01:00
JC Brand
fa06b528e1 Also show spoiler for sent messages. 2018-02-06 18:05:12 +01:00
JC Brand
d6da643a7f Add an (incomplete) test for a received spoiler message 2018-02-06 18:05:12 +01:00
JC Brand
b1ffb34b76 Add docstrings 2018-02-06 18:05:12 +01:00
JC Brand
7870fc53ca Refactor adding of spoiler stanza element into separate method 2018-02-06 18:05:12 +01:00
JC Brand
293ca2c75c Let the OTR code for adding a button mirror the spoiler way 2018-02-06 18:05:12 +01:00
JC Brand
7bf157d9b2 Refactor code that adds button into new method. 2018-02-06 18:05:12 +01:00
JC Brand
7f9f62476d Render spoiler button as a template 2018-02-06 18:05:12 +01:00
JC Brand
ed33d4e53d Add spec for spoilers, clean up linting errors 2018-02-06 18:05:12 +01:00
Seve
be8b9edf2a Remove tabs 2018-02-06 18:05:12 +01:00
Seve
41bbf653b9 Handle cases where hint is not supplied. 2018-02-06 18:05:12 +01:00
Seve
934e5ad421 Display images inside spoilers. Emojis not handled properly 2018-02-06 18:05:12 +01:00
Seve
1a1a7a4b27 Add event and logic to display spoiler messages 2018-02-06 18:05:12 +01:00
Seve
808cc385a5 Refactor to remove jQuery syntax 2018-02-06 18:05:12 +01:00
Seve
093fd7a283 Start overriding renderMessage() properly 2018-02-06 18:05:12 +01:00
Seve
226df674ae Start message rendering 2018-02-06 18:05:12 +01:00
Seve
4451a7c813 Use events in a less obscure manner 2018-02-06 18:05:12 +01:00
Seve
affd08bdaa Send user's hint if any 2018-02-06 18:05:12 +01:00
Seve
98fe606222 Send hints 2018-02-06 18:05:12 +01:00
Seve
26c579e326 Start with sending stanza with spoiler 2018-02-06 18:05:12 +01:00
Seve
a2b2291ef6 Initial concept for spoilers editor 2018-02-06 18:05:12 +01:00
JC Brand
3eb3668bef Small fixes 2018-02-06 18:05:12 +01:00
Seve
94830c8520 Setting up plugin development 2018-02-06 18:05:12 +01:00
Seve
a866c17414 Initial example plugin 2018-02-06 18:05:12 +01:00
ChaosKid42
1da20577e1 make locales_url relative (#1012) 2018-02-04 09:19:08 +01:00
JC Brand
62ad605bec Bugfix. Attribute error when empty IQ stanza is returned for vCard query 2018-01-30 10:25:08 +01:00
JC Brand
6b644d6d11 Release 3.3.2 2018-01-29 16:48:54 +01:00
JC Brand
585a182145 Bugfix in the URL regex 2018-01-29 15:35:36 +01:00
JC Brand
34b592be09 Fixes #921 2018-01-29 15:16:44 +01:00
JC Brand
edc4c1f158 Fixes #878. Ending slash in link not recognized 2018-01-29 15:12:49 +01:00
JC Brand
37e4ed6fe8 Avoid false headline message positive for node-less MUC JIDs 2018-01-29 15:00:11 +01:00
JC Brand
479d657001 Fixes #999 2018-01-29 15:00:02 +01:00
JC Brand
852e9b5c85 Updates #1003. Handle bare MUC room JIDs 2018-01-29 14:51:49 +01:00
JC Brand
476e1d79cd IE11 fixes 2018-01-29 14:40:45 +01:00
JC Brand
f724f49087 Add ability to run tests for transpiled code 2018-01-29 14:14:56 +01:00
JC Brand
e5006b0004 Fixes #1000. Scroll down when maximizing a chat room 2018-01-29 11:40:42 +01:00
JC Brand
d2a44c4c18 Fixes #1003 Don't list MUC domain in rooms list. 2018-01-29 11:17:54 +01:00
JC Brand
3d32f69548 console.trace is only shown when showing VERBOSEly
So use `console.error` instead, which is shown when the console settings
is set to something less verbose.
2018-01-29 11:17:54 +01:00
linkmauve
4dc5e01d76 Replace tabs with spaces in source files. (#1005) 2018-01-27 16:20:35 +01:00
JC Brand
834866bd84 Add fullscreen class when applicable 2018-01-23 14:47:46 +01:00
JC Brand
e6d5631452 Start moving css from mockup.css into the core sass files 2018-01-23 14:34:05 +01:00
JC Brand
4b64522c18 Fixes #993. 2018-01-22 12:41:45 +01:00
JC Brand
c012351df2 Updates #994. may not be defined 2018-01-22 12:37:29 +01:00
JC Brand
c1322f3c92 or should be and 2018-01-22 10:41:13 +01:00
JC Brand
12af9d5cbd Tying some loose ends 2018-01-22 09:53:35 +01:00
JC Brand
4c76370819 Bugfix. Could not register on Ejabberd 18 2018-01-22 09:50:24 +01:00
JC Brand
bf97ffd381 Check JIDs of archived MAM messages 2018-01-21 22:02:12 +01:00
JC Brand
ccf5ce2ae5 New release 3.3.1 2018-01-18 14:48:32 +01:00
JC Brand
db8fd5c018 Turn off message animations by default 2018-01-18 11:41:47 +01:00
JC Brand
db1c9c38d7 Add a link to weblate on inverse landing page 2018-01-18 11:14:06 +01:00
JC Brand
026cce3ada Rename zh to zh_TW and add Simplified Chinese as zh_CN 2018-01-18 11:02:44 +01:00
JC Brand
bc7b70732e Add support for simplified Chinese 2018-01-18 10:44:24 +01:00
JC Brand
8f455cf902 Release 3.3.0 2018-01-17 19:45:33 +01:00
JC Brand
210a75b02f Scroll down again after all images have been loaded. 2018-01-17 19:29:11 +01:00
ChaosKid42
115b887802 Send emojis as unicode (#977)
* render the shortnames as unicode when sending a message

* updated CHANGES.md
2018-01-17 17:03:23 +01:00
linkmauve
561bdbba35 Always use formatting inside translatable strings (#983)
This helps translators reorder words in the string.
2018-01-17 17:02:51 +01:00
JC Brand
e2a545a849 No need for animations during testing 2018-01-16 16:55:38 +01:00
JC Brand
8997af7890 Updates #984 Add color-fadein animation for messages 2018-01-16 16:36:23 +01:00
JC Brand
2cb4a36a6b Updates #984: Remember scroll position when using infinite scroll. 2018-01-16 15:38:08 +01:00
JC Brand
95bf69b8a9 Maintain simplicity by using only one variable instead of two 2018-01-16 14:56:58 +01:00
JC Brand
f1c8de15d1 Make DOM traversal methods more generic and move to utils. 2018-01-16 14:56:23 +01:00
JC Brand
93da96ad91 converse-mam: Use API internally 2018-01-16 12:20:18 +01:00
JC Brand
a1767ffecd Make sure rooms and bookmarks lists are recreated and shown after reconnect 2018-01-15 22:03:31 +01:00
JC Brand
c389b50044 Remove unused/dead code 2018-01-15 22:03:31 +01:00
JC Brand
9b3c6d1a3a Fixes #985 Give help messages a "message" class and isodate data attr. 2018-01-15 20:32:24 +01:00
JC Brand
e9bba77b36 Add test for /help command in private chats 2018-01-15 18:41:04 +01:00
JC Brand
35275c8add Lazily show spinner at the last moment 2018-01-15 18:40:35 +01:00
JC Brand
fdf1a977eb Bugfix. Fall back to normal query when no messages 2018-01-11 22:48:18 +00:00
JC Brand
76170427ec Bugfix. Exclude chat events when looking for first/last/prev message
Also, don't clear events in `renderMessage`, try to keep it free from
side-effects.
2018-01-11 22:47:37 +00:00
JC Brand
8d999b2802 Explicit plugin dependencies. Make hide_open_bookmarks false by default 2018-01-10 13:26:50 +00:00