Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
converse.js
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
converse.js
Commits
ba6b7201
Commit
ba6b7201
authored
Sep 17, 2014
by
JC Brand
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Show groupchat messages where user is mentioned in bold.
parent
eefce828
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
22 additions
and
3 deletions
+22
-3
converse.js
converse.js
+9
-1
css/converse.css
css/converse.css
+3
-0
docs/CHANGES.rst
docs/CHANGES.rst
+3
-2
docs/source/index.rst
docs/source/index.rst
+3
-0
less/converse.less
less/converse.less
+4
-0
No files found.
converse.js
View file @
ba6b7201
...
...
@@ -1095,6 +1095,7 @@
text
=
msg_dict
.
message
,
match
=
text
.
match
(
/^
\/(
.*
?)(?:
(
.*
))?
$/
),
fullname
=
msg_dict
.
fullname
||
this
.
model
.
get
(
'
fullname
'
),
// XXX Perhaps always use model's?
extra_classes
=
msg_dict
.
delayed
&&
'
delayed
'
||
''
,
template
,
username
;
if
((
match
)
&&
(
match
[
1
]
===
'
me
'
))
{
...
...
@@ -1106,12 +1107,19 @@
username
=
msg_dict
.
sender
===
'
me
'
&&
__
(
'
me
'
)
||
fullname
;
}
$content
.
find
(
'
div.chat-event
'
).
remove
();
if
(
this
.
is_chatroom
&&
msg_dict
.
sender
==
'
them
'
&&
(
new
RegExp
(
"
\\
b
"
+
this
.
model
.
get
(
'
nick
'
)
+
"
\\
b
"
)).
test
(
text
))
{
// Add special class to mark groupchat messages in which we
// are mentioned.
extra_classes
+=
'
mentioned
'
;
}
var
message
=
template
({
'
sender
'
:
msg_dict
.
sender
,
'
time
'
:
msg_time
.
format
(
'
hh:mm
'
),
'
username
'
:
username
,
'
message
'
:
''
,
'
extra_classes
'
:
msg_dict
.
delayed
&&
'
delayed
'
||
''
'
extra_classes
'
:
extra_classes
});
$content
.
append
(
$
(
message
).
children
(
'
.chat-message-content
'
).
first
().
text
(
text
).
addHyperlinks
().
addEmoticons
().
parent
());
this
.
scrollDown
();
...
...
css/converse.css
View file @
ba6b7201
...
...
@@ -706,6 +706,9 @@ span.spinner.hor_centered {
margin-left
:
0.3em
;
color
:
#808080
;
}
#conversejs
div
.mentioned
{
font-weight
:
bold
;
}
#conversejs
div
.delayed
.chat-message-them
{
color
:
#FB5D50
;
}
...
...
docs/CHANGES.rst
View file @
ba6b7201
...
...
@@ -4,8 +4,8 @@ Changelog
0.8.1 (Unreleased)
------------------
* Converse.js now has the ability to maintain sessions across page loads
(previously, the session tokens had to be handled externally and passed in)
.
* Converse.js now has the ability to maintain sessions across page loads
.
Previously, the session tokens had to be handled externally and passed in
.
See the `keepalive <https://conversejs.org/docs/html/index.html#keepalive`_ configuration setting. [jcbrand]
* Allow changing of nickname in a chat room via /nick command. [jcbrand]
* Allow a chat room user to be muted or unmuted with the /mute and /voice commands. [jcbrand]
...
...
@@ -18,6 +18,7 @@ Changelog
* #212 Bugfix. Groups weren't being show again after the live filter was cleared. [jcbrand]
* #215 (and also #75) XEP-0249: Direct MUC Invitations. [jcbrand]
* #216 Contacts tab empty when using xhr_user_search. [hcderaad and jcbrand]
* #219 New contacts added need page refresh to be accepted and become visible [hcderaad and jcbrand]
0.8.1 (2014-08-23)
------------------
...
...
docs/source/index.rst
View file @
ba6b7201
...
...
@@ -940,6 +940,9 @@ Default: ``true``
Determines whether Converse.js will maintain the chat session across page
loads.
*Please be aware*: This is a new still relatively experimental feature and there might be some
unhandled edge-cases.
message_carbons
---------------
...
...
less/converse.less
View file @
ba6b7201
...
...
@@ -775,6 +775,10 @@ span.spinner.hor_centered {
color: #808080;
}
#conversejs div.mentioned {
font-weight: bold;
}
#conversejs div.delayed .chat-message-them {
color: #FB5D50;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment