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
c392a4e5
Commit
c392a4e5
authored
May 11, 2013
by
JC Brand
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Show all available room features
when clicking the info icon next to a room's name
parent
ee47b031
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
81 additions
and
18 deletions
+81
-18
CHANGES.rst
CHANGES.rst
+14
-9
converse.css
converse.css
+6
-3
converse.js
converse.js
+61
-6
No files found.
CHANGES.rst
View file @
c392a4e5
...
...
@@ -4,22 +4,27 @@ Changelog
0.3 (unreleased)
----------------
- Add vCard support [jcbrand]
- Remember custom status messages upon reload. [jcbrand]
- Remove jquery-ui dependency. [jcbrand]
- Add vCard support
[jcbrand]
- Remember custom status messages upon reload.
[jcbrand]
- Remove jquery-ui dependency.
[jcbrand]
- Use backbone.localStorage to store the contacts roster, open chatboxes and
chat messages. [jcbrand]
- Fixed user status handling, which wasn't 100% according to the
spec. [jcbrand]
- Separate messages according to day in chats. [jcbrand]
chat messages.
[jcbrand]
- Fixed user status handling, which wasn't 100% according to the spec.
[jcbrand]
- Separate messages according to day in chats.
[jcbrand]
- Add support for specifying the BOSH bind URL as configuration setting.
[jcbrand]
- Improve the message counter to only increment when the window is not focused
[witekdev]
- Make fetching of list of chatrooms on a server a configuration option.
[jcbrand]
- Use service discovery to show
whether a chatroom is password protected as
well as its number of occupents.
[jcbrand]
- Use service discovery to show
all available features on a room.
[jcbrand]
0.2 (2013-03-28)
...
...
converse.css
View file @
c392a4e5
...
...
@@ -468,12 +468,15 @@ dd.available-chatroom,
text-shadow
:
0
1px
0
rgba
(
250
,
250
,
250
,
1
);
}
p
.room-info
{
margin
:
0
;
padding
:
0
;
.room-info
{
font-size
:
11px
;
font-style
:
normal
;
font-weight
:
normal
;
}
p
.room-info
{
margin
:
0
;
padding
:
0
;
display
:
block
;
white-space
:
normal
;
}
...
...
converse.js
View file @
c392a4e5
...
...
@@ -697,9 +697,41 @@
'
<div class="room-info">
'
+
'
<p class="room-info"><strong>Description:</strong> {{desc}}</p>
'
+
'
<p class="room-info"><strong>Occupants:</strong> {{occ}}</p>
'
+
'
{[ if (locked) { ]}
'
+
'
<p class="room-info locked">Requires authentication</p>
'
+
'
<p class="room-info"><strong>Features:</strong> <ul>
'
+
'
{[ if (passwordprotected) { ]}
'
+
'
<li class="room-info locked">Requires authentication</li>
'
+
'
{[ } ]}
'
+
'
{[ if (hidden) { ]}
'
+
'
<li class="room-info">Hidden</li>
'
+
'
{[ } ]}
'
+
'
{[ if (membersonly) { ]}
'
+
'
<li class="room-info">Requires an invitation</li>
'
+
'
{[ } ]}
'
+
'
{[ if (moderated) { ]}
'
+
'
<li class="room-info">Moderated</li>
'
+
'
{[ } ]}
'
+
'
{[ if (nonanonymous) { ]}
'
+
'
<li class="room-info">Non-anonymous</li>
'
+
'
{[ } ]}
'
+
'
{[ if (open) { ]}
'
+
'
<li class="room-info">Open room</li>
'
+
'
{[ } ]}
'
+
'
{[ if (persistent) { ]}
'
+
'
<li class="room-info">Permanent room</li>
'
+
'
{[ } ]}
'
+
'
{[ if (publicroom) { ]}
'
+
'
<li class="room-info">Public</li>
'
+
'
{[ } ]}
'
+
'
{[ if (semianonymous) { ]}
'
+
'
<li class="room-info">Semi-anonymous</li>
'
+
'
{[ } ]}
'
+
'
{[ if (temporary) { ]}
'
+
'
<li class="room-info">Temporary room</li>
'
+
'
{[ } ]}
'
+
'
{[ if (unmoderated) { ]}
'
+
'
<li class="room-info">Unmoderated</li>
'
+
'
{[ } ]}
'
+
'
</p>
'
+
'
</div>
'
),
...
...
@@ -788,14 +820,36 @@
$
(
target
).
attr
(
'
data-room-jid
'
),
null
,
$
.
proxy
(
function
(
stanza
)
{
var
desc
=
$
(
stanza
).
find
(
'
field[var="muc#roominfo_description"] value
'
).
text
();
var
occ
=
$
(
stanza
).
find
(
'
field[var="muc#roominfo_occupants"] value
'
).
text
();
var
locked
=
$
(
stanza
).
find
(
'
feature[var="muc_passwordprotected"]
'
).
length
;
var
$stanza
=
$
(
stanza
);
// All MUC features shown here: http://xmpp.org/registrar/disco-features.html
var
desc
=
$stanza
.
find
(
'
field[var="muc#roominfo_description"] value
'
).
text
();
var
occ
=
$stanza
.
find
(
'
field[var="muc#roominfo_occupants"] value
'
).
text
();
var
hidden
=
$stanza
.
find
(
'
feature[var="muc_hidden"]
'
).
length
;
var
membersonly
=
$stanza
.
find
(
'
feature[var="muc_membersonly"]
'
).
length
;
var
moderated
=
$stanza
.
find
(
'
feature[var="muc_moderated"]
'
).
length
;
var
nonanonymous
=
$stanza
.
find
(
'
feature[var="muc_nonanonymous"]
'
).
length
;
var
open
=
$stanza
.
find
(
'
feature[var="muc_open"]
'
).
length
;
var
passwordprotected
=
$stanza
.
find
(
'
feature[var="muc_passwordprotected"]
'
).
length
;
var
persistent
=
$stanza
.
find
(
'
feature[var="muc_persistent"]
'
).
length
;
var
publicroom
=
$stanza
.
find
(
'
feature[var="muc_public"]
'
).
length
;
var
semianonymous
=
$stanza
.
find
(
'
feature[var="muc_semianonymous"]
'
).
length
;
var
temporary
=
$stanza
.
find
(
'
feature[var="muc_temporary"]
'
).
length
;
var
unmoderated
=
$stanza
.
find
(
'
feature[var="muc_unmoderated"]
'
).
length
;
$dd
.
find
(
'
img.spinner
'
).
replaceWith
(
this
.
room_description_template
({
'
desc
'
:
desc
,
'
occ
'
:
occ
,
'
locked
'
:
locked
'
hidden
'
:
hidden
,
'
membersonly
'
:
membersonly
,
'
moderated
'
:
moderated
,
'
nonanonymous
'
:
nonanonymous
,
'
open
'
:
open
,
'
passwordprotected
'
:
passwordprotected
,
'
persistent
'
:
persistent
,
'
publicroom
'
:
publicroom
,
'
semianonymous
'
:
semianonymous
,
'
temporary
'
:
temporary
,
'
unmoderated
'
:
unmoderated
}));
},
this
));
}
...
...
@@ -1958,6 +2012,7 @@
* This collection stores Feature Models, representing features
* provided by available XMPP entities (e.g. servers)
* See XEP-0030 for more details: http://xmpp.org/extensions/xep-0030.html
* All features are shown here: http://xmpp.org/registrar/disco-features.html
*/
model
:
converse
.
Feature
,
initialize
:
function
()
{
...
...
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