Commit Graph

470 Commits

Author SHA1 Message Date
JC Brand
c14ef3bb75 Bugfix. Can't expect fullname to be set anymore. 2018-05-01 15:21:20 +02:00
JC Brand
f9aa75b69e Refactored message attributes and rendering.
- set `username` on the message object,
  instead of always using `fullname` with fallback to `jid`.
- Distinguish better between `groupchat` messages and normal
  messages in `getMessageAttributesFromStanza`
2018-05-01 12:30:58 +02:00
JC Brand
097d992d13 Bugfix, /me message wrongly marked as followup message. 2018-04-30 16:23:52 +02:00
JC Brand
eaf65f4d24 Add missing items-list class (as per mockup) 2018-04-30 15:37:37 +02:00
JC Brand
4bcf8e7bc3 Mark followup messags so that they can be styled differently 2018-04-30 15:37:37 +02:00
JC Brand
876a07b3de Fix the failing tests 2018-04-30 15:37:37 +02:00
JC Brand
1405d9cb49 Also style file upload and action messages. 2018-04-30 15:37:37 +02:00
JC Brand
36ccb4618f Tweak chatroom headings 2018-04-30 15:37:36 +02:00
JC Brand
56e4e8b8ee Fix rendering of headline messages.
Also, add urijs to more intelligently handle URIs
2018-04-30 15:37:36 +02:00
JC Brand
3d42425083 Some UI improvements
- Render images as thumbnails
- Use the image.html template when rendering images from pasted URLs
- Update message and spoiler markup to render avatars
- Use the default avatar as fallback when user doesn't have one
- Instead of 'me' render own name or JID
2018-04-30 15:37:36 +02:00
JC Brand
57f7e31aa1 Add a spoiler message to the mockups 2018-04-30 15:37:36 +02:00
JC Brand
aa6a739cfa Initial work on showing avatars in messages.
- Update the mockups to show avatars.
2018-04-30 15:37:36 +02:00
JC Brand
e0aaeb66ea updates #161
* Fix typo which broke MUC file upload
* Remove unused method
* Move file input into li element
2018-04-24 07:49:37 +02:00
JC Brand
a19e7aeffe Add support for XEP-0066 Out of band data 2018-04-18 16:58:52 +02:00
JC Brand
d048cff9a8 Provide metadata of file being uploaded.
updates #161
2018-04-18 11:49:53 +02:00
JC Brand
c01e9f8265 Move methods from chatbox view to message view
Specifically the methods related to requesting an upload slot and uploading a file.
Also show a progress indicator while a file is being uploaded.

Updates #161
2018-04-17 15:21:38 +02:00
JC Brand
de6ecbf07a Render messages via a new MessageView view
updates #161
2018-04-17 15:21:26 +02:00
JC Brand
584f293d05 Updated and refactored the work from @worlword
* Use Promises instead of callbacks
* Update to latest (Last Call) version of XEP-0363
* Move non-view specific methods to models instead
* Add more tests

updates #161
2018-04-17 15:21:09 +02:00
JC Brand
9c2a5bd3b8 Merge branch 'worlword-httpFileUpload' into http-file-upload 2018-04-14 07:50:29 +02:00
JC Brand
042c1947ed Add file-upload button 2018-04-14 07:40:07 +02:00
worlword
3b1d27636d problem fixed, that file-upload would not start. Also did some code cleanup 2018-04-13 11:45:43 +02:00
worlword
ca40cf6541 removed EmptyLines in ChatView.js and Change Lineendings to LF in toolbar_fileUpload.html 2018-04-12 09:37:58 +02:00
worlword
7660dbfb31 merge httpFileUpload-Branch with master 2018-04-12 07:43:39 +02:00
worlword
c9a9d01112 used code from 'http-file-upload' branch. Buttons are now added to the toolbars through converse-http-file-upload.js. 2018-04-11 17:09:32 +02:00
Kim Alvefur
a82f950e3c Put timestamp in a <time> tag for better semantics and easier styling 2018-04-07 21:47:22 +02:00
JC Brand
9a526d4194 Refactoring of the XEP-0085 Chat State Notifications code
* Distinguish between CSN messages and other types of messages
* Properly clear previous notifications
* Better handling of notifications from multiple users (in MUC)
* Rename methods to make clarify intent
2018-04-06 17:02:28 +02:00
worlword
b23712aec3 added httpFileUpload to converse.js 2018-04-03 11:20:57 +02:00
JC Brand
2705ec8193 Let the chatarea expand when the occupants sidebar is collapsed. 2018-03-30 14:23:39 +02:00
JC Brand
4f2b040f22 Allow setting a nickname when adding a roster contact 2018-03-30 14:22:51 +02:00
JC Brand
95406a149d Re-add xhr_user_search_url and autocomplete when adding contacts 2018-03-30 14:22:51 +02:00
JC Brand
ea4337da51 Set column width for chatbox buttons in the sass file 2018-03-30 14:16:07 +02:00
JC Brand
2580cafa76 Bugfix. Fix selector 2018-03-30 14:16:07 +02:00
JC Brand
deff6e071c Remove the clear button. It was pretty useless
because it didn't actually clear anything permanently and upon page
reload the messages were there again.
2018-03-30 14:16:06 +02:00
JC Brand
8fda25c997 Honor the allow_logout setting 2018-03-30 14:16:05 +02:00
JC Brand
11f02f78fe Fix more failing tests 2018-03-17 18:54:19 +00:00
JC Brand
cb0b99ac37 Bugfix. Show message author in spoiler messages 2018-03-17 14:39:30 +00:00
JC Brand
f0ae8c44ff Show caret for room, bookmark and group toggles 2018-03-17 11:42:17 +00:00
JC Brand
850c6aa2bd Fix more failing tests 2018-03-16 23:37:52 +00:00
JC Brand
7b8a244163 Fix failing bookmarks tests 2018-03-16 11:49:39 +00:00
JC Brand
2f46bb8ce7 Fix failing tests 2018-03-14 23:10:31 +00:00
JC Brand
1565decfc0 Add identifiable class name 2018-03-14 18:25:33 +00:00
JC Brand
ca141401a0 Fix failing tests 2018-03-13 13:42:00 +01:00
JC Brand
9c80ab5d43 Use bootstrap button markup 2018-03-11 12:07:36 +01:00
JC Brand
d7de739001 Add close button for controlbox in overlay view mode 2018-03-09 23:53:05 +01:00
JC Brand
a1145140c3 Various small tweaks
- Style room invite
- Remove old border-radius
- Show close icon for minimized chats
2018-03-09 23:27:12 +01:00
JC Brand
591e794f69 chat head: Show minimize icon and hide for now the vcard icon 2018-03-09 23:20:14 +01:00
JC Brand
986921c630 Small fixes for minimized chats toggle 2018-03-09 23:14:08 +01:00
JC Brand
392a7e8ab3 Don't use the bootstrap responsive grid for chats in overlay mode 2018-03-09 23:06:41 +01:00
JC Brand
849d6b2612 Update the minimized chats widget 2018-03-09 18:14:18 +01:00
JC Brand
9c0b7c71cd Render OTR menu as a bootstrap dropdown 2018-03-09 17:30:42 +01:00
JC Brand
9825d6e777 Use bootstrap dropdown to render the emoji picker 2018-03-09 14:51:24 +01:00
JC Brand
8bddd0d7f4 Some work on showing emoji in a dropdown 2018-03-09 11:46:50 +01:00
JC Brand
40f4555419 Only show controlbox head when logging in, in overlayed view mode 2018-03-09 11:46:23 +01:00
JC Brand
db44a4f44d Update the login form for the overlayed view mode 2018-03-07 21:40:55 +01:00
JC Brand
d72463c939 Make more semantic by putting login/register column info in css 2018-03-07 18:06:02 +01:00
JC Brand
b3f2fafeea Various smaller fixes and improvements 2018-03-07 14:36:19 +01:00
JC Brand
2db4550b13 Update chat events markup. 2018-03-07 11:02:12 +01:00
JC Brand
e3350ab79f Update chat head markup 2018-03-06 19:03:32 +01:00
JC Brand
d04a7df295 Update room features markup to use font awesome 2018-03-06 18:33:59 +01:00
JC Brand
181b1836b0 Update and further style toolbars 2018-03-06 15:26:05 +01:00
JC Brand
6bdf204be4 Show occupants sidebar again 2018-03-05 16:58:31 +01:00
JC Brand
d4d3d4c838 Merge branch 'split-muc' into bootstrap4 2018-03-05 16:51:33 +01:00
JC Brand
dcc6244fc2 Don't overwrite default avatar with undefined 2018-03-04 07:29:24 +01:00
JC Brand
860befcab9 Fixes #1025
Rename icon to avoid confusion. Add back the OTR status text.
2018-03-02 12:11:47 +01:00
JC Brand
c655781bc9 More login form improvements and also update registration form 2018-02-24 19:59:25 +01:00
JC Brand
e1d1bac790 Update the login form with markup from bootstrap mockup 2018-02-24 18:43:32 +01:00
JC Brand
3b22f918fa More work on the user profile modal 2018-02-23 23:10:46 +01:00
JC Brand
5278e4fe79 Add outline for a user profile modal 2018-02-23 16:33:10 +01:00
JC Brand
e344bf769a New modal for adding contacts.
Remove the xhr_user_search and xhr_user_search_url options
Lazily create modals
2018-02-23 16:33:09 +01:00
JC Brand
4e508cfe88 Add a modal to list rooms 2018-02-22 17:40:01 +01:00
JC Brand
e143c88475 More work on the "add chatroom" modal. Working now. 2018-02-22 15:58:23 +01:00
JC Brand
1ce46a84ae Make sure that statusInitialized is always called
regardless of wether it's a connection or reconnection event.

We can then only listen for `statusInitialized` to handle both cases.
2018-02-22 11:20:26 +01:00
JC Brand
47aad31899 Tricky refactoring.
Removed `_converse.chatboxviews.showChat` and trying to simplify how
chats are created and when they're shown.

Prompted by the work to split the MUC views into a separate plugin
2018-02-21 23:47:02 +01:00
JC Brand
d9709af7cf Initial work on the new chatroom modal 2018-02-21 16:59:16 +01:00
JC Brand
b5812e257d Work on the status modal 2018-02-21 16:17:57 +01:00
JC Brand
ad01ab3041 Add status modal 2018-02-21 14:03:07 +01:00
JC Brand
1470b86896 Fix logout 2018-02-20 16:51:59 +01:00
JC Brand
21556832f8 Update chatbox headers and buttons 2018-02-20 16:48:01 +01:00
JC Brand
6b89a6c106 Only show img tag if we have image data 2018-02-20 15:56:58 +01:00
JC Brand
5e6860754f Update chatbox head with new markup 2018-02-19 22:36:37 +01:00
JC Brand
c4367e7a0a Show own avatar 2018-02-19 22:12:50 +01:00
JC Brand
08c016da0e Get ancestor element via selector 2018-02-19 20:54:58 +01:00
JC Brand
658c27730c Fix showing of room info in rooms list 2018-02-19 18:11:02 +01:00
JC Brand
6cdaa47493 Fix roster filter functionality 2018-02-19 17:37:47 +01:00
JC Brand
493ecb2e4f Update markup for the roster filter 2018-02-19 16:08:54 +01:00
JC Brand
2fa8304945 Improve and update roster markup 2018-02-19 15:01:02 +01:00
JC Brand
650ed22da7 Update requesting contacts and tweak bookmark icons 2018-02-16 15:24:17 +01:00
JC Brand
c4a99c7f29 Render rooms and bookmarks lists according to mockups 2018-02-16 15:08:16 +01:00
JC Brand
ede21e7c32 Remove controlbox tabs and show rooms and contacts panels together 2018-02-16 14:16:55 +01:00
JC Brand
b6501bcf09 Render .row inside #conversejs element 2018-02-15 15:50:37 +01:00
JC Brand
617019af0e Merge remote-tracking branch 'origin' into bootstrap4 2018-02-15 14:15:04 +01:00
linkmauve
af6867e638 improve @title on roster item (#1013) 2018-02-14 00:43:33 +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
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
f6db2a9167 Use template to render the spoiler message. 2018-02-06 18:58:06 +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
7f9f62476d Render spoiler button as a template 2018-02-06 18:05:12 +01:00
linkmauve
4dc5e01d76 Replace tabs with spaces in source files. (#1005) 2018-01-27 16:20:35 +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
db1c9c38d7 Add a link to weblate on inverse landing page 2018-01-18 11:14:06 +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
4f227b467b Take all messages except chat events into consideration
when determining where to insert new messages
2018-01-10 12:45:12 +00:00
JC Brand
5a7ce787c3 Renaming of template 2018-01-09 14:02:01 +00:00
JC Brand
5ea1b07b6b Use an OrderedListView to render the bookmarks list 2018-01-04 21:51:42 +00:00
JC Brand
6739b508c3 Small css and text fixes 2018-01-04 16:27:56 +00:00
JC Brand
334a24c938 Use template to render .chat-info messages
Also did some work on removing jQuery from converse-chatview
2017-12-24 17:09:49 +00:00
JC Brand
a6d4419c04 Remove jQuery from converse-bookmarks 2017-12-23 20:56:20 +00:00
JC Brand
3cf7fefaa8 Make the :last-child selector more specific
otherwise deeper leaf-nodes get returned
2017-12-22 20:49:10 +00:00
JC Brand
6c6ef1f1f9 Refactoring of the roster view.
* Removed the dependency on jQuery
* Contacts are now shown inside a group element, simplifying the code
2017-12-19 18:44:31 +00:00
JC Brand
f9343594bf Collapse multiple, consecutive join/leave messages 2017-12-15 16:24:30 +00:00
JC Brand
5eabf4008e Render "create account" link via a VDOMView and hide when connecting 2017-12-14 12:30:50 +00:00
JC Brand
031d640438 Don't render avatar for headlines chatbox 2017-12-06 22:10:21 +01:00
JC Brand
a4a1c80b5b Bugfix. In a MUC the /help command didn't render properly 2017-12-06 17:01:17 +01:00
JC Brand
85bea60066 Some of refactoring to avoid code duplication and jQuery 2017-12-06 16:26:53 +01:00
Stefano Boldrin
f953df9621 Fixed error building DOM toggle_chats.html span.unread-message-count class attribute (#960)
* Added missing " on class attribute

* Added changelog for prev commit "Added missing " on class attribute"
2017-12-04 20:44:54 +01:00
JC Brand
e701305d05 Bugfix. Avatar wasn't being shown 2017-12-02 18:07:31 +01:00
JC Brand
141eaa6a39 Fix rendering of heading for headlines boxes 2017-11-17 14:41:54 +01:00
JC Brand
ca0cbb1c31 Use an img tag instead of canvas for rendering avatars 2017-11-17 13:19:21 +01:00
JC Brand
bac1d22205 Fix: In chatbox heading two avatars sometimes get rendered 2017-11-17 12:50:16 +01:00
JC Brand
250b06475e Bugfix. Disappearing contacts filter when changing the type 2017-11-17 11:30:50 +01:00
JC Brand
691c48468f Hide the roster filter by default. Updates #949
- Also, use a virtual-dom view for rendering the roster filter.
2017-11-11 09:16:45 +01:00
JC Brand
cfd5dad9c5 Use [backbone.vdomview](https://github.com/jcbrand/backbone.vdomview)
For the MUCJoinView and the LoginPanel
2017-11-10 22:01:36 +01:00
JC Brand
ed4c393a9d Create separate view for the MUC join form 2017-11-10 21:37:35 +01:00
JC Brand
8a4aa4efdd Use a named variable for _.template
This removes the need for `switch (obj)` in the template which is not
allowed in strict mode.

Additionally using a named variable speeds up rendering.
2017-11-05 18:59:29 +01:00
JC Brand
61ed55dbaa Rename login and register urls 2017-10-31 20:39:44 +01:00
JC Brand
74b91faf9a Use browser-based "constraint validation"
to validate required fields, instead of doing it manually.

All supported browsers have this feature.
2017-09-25 13:55:17 +02:00
JC Brand
9a8db618d3 More user-friendly phrasing 2017-09-24 11:03:27 +02:00
JC Brand
3d53943f49 Generate pot file from the converse-no-dependencies build
This is a workaround for the fact that getttext doesn't support ES2015 template
literals and it also allows us to scan for translateable strings in our HTML
templates.
2017-09-24 00:30:43 +02:00
JC Brand
92af05d510 Some more refactoring now that we use a vdom for the login panel
We can now simply call `render` whenever we want to show an error or
notification message.

The flip side is that the template is now larger and contains more login.
2017-09-24 00:30:43 +02:00
JC Brand
2203e9505a Set autofocus on inputs 2017-09-24 00:30:43 +02:00
JC Brand
937b310733 Refactor login form to make it more reactive. 2017-09-24 00:30:43 +02:00
JC Brand
f827979000 converse-register: render the buttons as part of the template
instead of manually
2017-09-24 00:30:43 +02:00
JC Brand
4063bbfc1c converse-register: Consolidate validation and error reporting 2017-09-24 00:30:43 +02:00
JC Brand
a9b74ca9b5 converse-register: refactor in order to simplify. 2017-09-24 00:30:43 +02:00
JC Brand
9cdb0dde8c Various changes
* In certain places, use native methods instead of jQuery
* Nicer rendering of registration forms
* Use CSS3 fade-in animations.
2017-09-24 00:30:43 +02:00
JC Brand
57d2f9bce8 Add validation message for an invalid JID in the login form 2017-09-24 00:30:43 +02:00
JC Brand
158acbf1d7 Fixes #828 Add routing for login and register URL fragments 2017-09-24 00:30:43 +02:00
JC Brand
7e4fb52f8d Render register and login forms via links 2017-09-24 00:30:43 +02:00
JC Brand
140946a34b Add brand headings 2017-09-24 00:30:43 +02:00
JC Brand
1613c0d7de Styling changes now that we don't have tabs. 2017-09-24 00:30:43 +02:00
JC Brand
196a42dc50 Make sure strings get translated and that interpolation is safe 2017-09-24 00:30:43 +02:00