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
329746d8
Commit
329746d8
authored
Nov 25, 2014
by
JC Brand
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'register'
parents
e246335b
d690704f
Changes
20
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
20 changed files
with
1015 additions
and
511 deletions
+1015
-511
bower.json
bower.json
+1
-1
converse.js
converse.js
+552
-219
css/converse.css
css/converse.css
+85
-35
css/theme.css
css/theme.css
+1
-0
index.html
index.html
+1
-0
less/converse.less
less/converse.less
+97
-33
main.js
main.js
+27
-5
mockup/controlbox.html
mockup/controlbox.html
+55
-36
src/templates.js
src/templates.js
+33
-25
src/templates/form_captcha.html
src/templates/form_captcha.html
+9
-0
src/templates/form_checkbox.html
src/templates/form_checkbox.html
+2
-1
src/templates/form_input.html
src/templates/form_input.html
+8
-1
src/templates/form_select.html
src/templates/form_select.html
+2
-1
src/templates/form_textarea.html
src/templates/form_textarea.html
+2
-1
src/templates/login_panel.html
src/templates/login_panel.html
+3
-3
src/templates/register_panel.html
src/templates/register_panel.html
+7
-0
src/templates/register_tab.html
src/templates/register_tab.html
+1
-0
src/templates/registration_form.html
src/templates/registration_form.html
+6
-0
src/utils.js
src/utils.js
+123
-1
tests/main.js
tests/main.js
+0
-149
No files found.
bower.json
View file @
329746d8
...
@@ -29,7 +29,7 @@
...
@@ -29,7 +29,7 @@
"bootstrapJS"
:
"https://raw.githubusercontent.com/jcbrand/bootstrap/7d96a5f60d26c67b5348b270a775518b96a702c8/dist/js/bootstrap.js"
,
"bootstrapJS"
:
"https://raw.githubusercontent.com/jcbrand/bootstrap/7d96a5f60d26c67b5348b270a775518b96a702c8/dist/js/bootstrap.js"
,
"fontawesome"
:
"~4.1.0"
,
"fontawesome"
:
"~4.1.0"
,
"typeahead.js"
:
"https://raw.githubusercontent.com/jcbrand/typeahead.js/eedfb10505dd3a20123d1fafc07c1352d83f0ab3/dist/typeahead.jquery.js"
,
"typeahead.js"
:
"https://raw.githubusercontent.com/jcbrand/typeahead.js/eedfb10505dd3a20123d1fafc07c1352d83f0ab3/dist/typeahead.jquery.js"
,
"strophejs-plugins"
:
"https://github.com/strophe/strophejs-plugins.git#
a56421ff4ecf0807113ab48c46728715597df599
"
"strophejs-plugins"
:
"https://github.com/strophe/strophejs-plugins.git#
conversejs
"
},
},
"exportsOverride"
:
{}
"exportsOverride"
:
{}
}
}
converse.js
View file @
329746d8
This diff is collapsed.
Click to expand it.
css/converse.css
View file @
329746d8
...
@@ -481,26 +481,29 @@
...
@@ -481,26 +481,29 @@
transform
:
rotate
(
359deg
);
transform
:
rotate
(
359deg
);
}
}
}
}
span
.spinner
:before
{
#conversejs
.spinner
:before
{
font-size
:
24px
;
font-size
:
24px
;
font-family
:
'Converse-js'
!important
;
font-family
:
'Converse-js'
!important
;
content
:
"\231b"
;
content
:
"\231b"
;
}
}
span
.spinner
{
#conversejs
.spinner
{
-webkit-animation
:
spin
2s
infinite
linear
;
-webkit-animation
:
spin
2s
infinite
linear
;
-moz-animation
:
spin
2s
infinite
linear
;
-moz-animation
:
spin
2s
infinite
linear
;
-o-animation
:
spin
2s
infinite
linear
;
-o-animation
:
spin
2s
infinite
linear
;
animation
:
spin
2s
infinite
linear
;
animation
:
spin
2s
infinite
linear
;
width
:
100%
;
display
:
block
;
display
:
block
;
text-align
:
center
;
text-align
:
center
;
margin
:
5px
;
}
}
span
.spinner
.centered
{
#conversejs
.centered
{
text-align
:
center
;
text-align
:
center
;
padding-top
:
5em
;
display
:
block
;
margin
:
5em
auto
;
}
}
span
.spinner
.hor_centered
{
#conversejs
.hor_centered
{
text-align
:
center
;
text-align
:
center
;
display
:
block
;
margin
:
0
auto
;
}
}
#conversejs
#minimized-chats
.box-flyout
{
#conversejs
#minimized-chats
.box-flyout
{
position
:
absolute
;
position
:
absolute
;
...
@@ -737,12 +740,27 @@ span.spinner.hor_centered {
...
@@ -737,12 +740,27 @@ span.spinner.hor_centered {
#conversejs
div
.delayed
.chat-message-me
{
#conversejs
div
.delayed
.chat-message-me
{
color
:
#7EABBB
;
color
:
#7EABBB
;
}
}
input
.error
{
#conversejs
input
.error
{
border
:
1px
solid
red
;
border
:
1px
solid
red
;
}
}
#conversejs
.
conn-feedback.
error
{
#conversejs
.error
{
color
:
red
;
color
:
red
;
}
}
#converse-register
.provider-title
{
font-size
:
115%
;
}
#converse-register
.provider-score
{
width
:
178px
;
margin-bottom
:
8px
;
}
#converse-register
.form-help
.url
{
font-weight
:
bold
;
color
:
#2D617A
;
}
#conversejs
.reg-feedback
{
font-size
:
85%
;
}
#conversejs
.reg-feedback
,
#converse-login
.conn-feedback
{
#converse-login
.conn-feedback
{
width
:
100%
;
width
:
100%
;
text-align
:
center
;
text-align
:
center
;
...
@@ -807,6 +825,7 @@ dl.add-converse-contact {
...
@@ -807,6 +825,7 @@ dl.add-converse-contact {
#conversejs
.fancy-dropdown
{
#conversejs
.fancy-dropdown
{
border
:
1px
solid
#ddd
;
border
:
1px
solid
#ddd
;
height
:
22px
;
height
:
22px
;
text-align
:
left
;
}
}
#conversejs
.fancy-dropdown
a
.choose-xmpp-status
{
#conversejs
.fancy-dropdown
a
.choose-xmpp-status
{
width
:
155px
;
width
:
155px
;
...
@@ -926,9 +945,6 @@ dl.add-converse-contact {
...
@@ -926,9 +945,6 @@ dl.add-converse-contact {
display
:
block
;
display
:
block
;
clear
:
both
;
clear
:
both
;
}
}
#conversejs
.chatroom-form
label
.label-ta
{
height
:
auto
;
}
#conversejs
.chatroom-form
label
input
,
#conversejs
.chatroom-form
label
input
,
#conversejs
.chatroom-form
label
select
{
#conversejs
.chatroom-form
label
select
{
float
:
right
;
float
:
right
;
...
@@ -965,6 +981,7 @@ dl.add-converse-contact {
...
@@ -965,6 +981,7 @@ dl.add-converse-contact {
padding
:
0
5px
0
0
;
padding
:
0
5px
0
0
;
}
}
#converse-roster
{
#converse-roster
{
text-align
:
left
;
width
:
100%
;
width
:
100%
;
position
:
relative
;
position
:
relative
;
margin
:
0.5em
0
0
0
;
margin
:
0.5em
0
0
0
;
...
@@ -1013,6 +1030,9 @@ dl.add-converse-contact {
...
@@ -1013,6 +1030,9 @@ dl.add-converse-contact {
#conversejs
dd
.available-chatroom
a
.open-room
{
#conversejs
dd
.available-chatroom
a
.open-room
{
width
:
148px
;
width
:
148px
;
}
}
#available-chatrooms
{
text-align
:
left
;
}
#available-chatrooms
dt
,
#available-chatrooms
dt
,
#converse-roster
dt
{
#converse-roster
dt
{
font-weight
:
normal
;
font-weight
:
normal
;
...
@@ -1110,30 +1130,72 @@ dl.add-converse-contact {
...
@@ -1110,30 +1130,72 @@ dl.add-converse-contact {
width
:
300px
;
width
:
300px
;
}
}
#conversejs
.controlbox-pane
{
#conversejs
.controlbox-pane
{
padding
:
0
;
text-align
:
center
;
b
order-bottom-right-radius
:
4px
;
b
ackground-color
:
white
;
border-bottom-left-radius
:
4px
;
border-bottom-left-radius
:
4px
;
border-bottom-right-radius
:
4px
;
border
:
0
;
font-size
:
14px
;
height
:
289px
;
height
:
calc
(
100%
-
35px
);
overflow-y
:
auto
;
padding
:
0
;
position
:
absolute
;
width
:
100%
;
}
}
#conversejs
.controlbox-pane
dd
{
#conversejs
.controlbox-pane
dd
{
margin-left
:
0
;
margin-left
:
0
;
margin-bottom
:
0
;
margin-bottom
:
0
;
padding
:
1em
;
}
}
#conversejs
.controlbox-pane
dd
.odd
{
#conversejs
.controlbox-pane
dd
.odd
{
background-color
:
#DCEAC5
;
background-color
:
#DCEAC5
;
}
}
#conversejs
form
#converse-register
.title
{
font-weight
:
bold
;
}
#conversejs
form
#converse-register
.info
{
font-style
:
italic
;
color
:
green
;
font-size
:
85%
;
margin
:
5px
0
;
}
#conversejs
.form-help
,
#conversejs
form
#converse-register
.instructions
{
color
:
gray
;
font-size
:
85%
;
}
#conversejs
.form-help
:hover
,
#conversejs
form
#converse-register
.instructions
:hover
{
color
:
#4f4f4f
;
}
#conversejs
.form-help
{
padding-top
:
5px
;
}
#conversejs
form
#converse-register
.form-errors
{
color
:
red
;
display
:
none
;
}
#conversejs
form
#converse-register
,
#conversejs
form
#converse-login
{
#conversejs
form
#converse-login
{
background
:
white
;
background
:
white
;
padding
:
2
em
0.5em
;
padding
:
1
em
0.5em
;
}
}
#conversejs
form
#converse-register
input
,
#conversejs
form
#converse-login
input
{
#conversejs
form
#converse-login
input
{
width
:
100%
;
width
:
178px
;
height
:
30px
;
}
}
#conversejs
form
#converse-register
label
,
#conversejs
form
#converse-login
label
{
#conversejs
form
#converse-login
label
{
margin-top
:
0.5em
;
margin-top
:
0.5em
;
font-weight
:
bold
;
}
}
#conversejs
form
#converse-login
.login-submit
{
#conversejs
form
#converse-register
.login-submit
,
#conversejs
form
#converse-login
.login-submit
,
#conversejs
form
#converse-register
.submit
,
#conversejs
form
#converse-login
.submit
{
margin-top
:
1em
;
margin-top
:
1em
;
height
:
30px
;
}
}
#conversejs
form
.set-xmpp-status
{
#conversejs
form
.set-xmpp-status
{
background
:
none
;
background
:
none
;
...
@@ -1182,11 +1244,11 @@ select#select-xmpp-status {
...
@@ -1182,11 +1244,11 @@ select#select-xmpp-status {
text-decoration
:
none
;
text-decoration
:
none
;
border-top-right-radius
:
4px
;
border-top-right-radius
:
4px
;
border-top-left-radius
:
4px
;
border-top-left-radius
:
4px
;
color
:
#
666
;
color
:
#
888
;
text-shadow
:
0
1px
0
#fafafa
;
text-shadow
:
0
1px
0
#fafafa
;
}
}
#conversejs
.chat-head
#controlbox-tabs
li
a
:hover
{
#conversejs
.chat-head
#controlbox-tabs
li
a
:hover
{
color
:
black
;
color
:
#4f4f4f
;
}
}
#conversejs
.chat-head
#controlbox-tabs
li
a
{
#conversejs
.chat-head
#controlbox-tabs
li
a
{
background-color
:
white
;
background-color
:
white
;
...
@@ -1201,21 +1263,6 @@ select#select-xmpp-status {
...
@@ -1201,21 +1263,6 @@ select#select-xmpp-status {
cursor
:
default
;
cursor
:
default
;
color
:
#666666
;
color
:
#666666
;
}
}
#conversejs
div
#users
,
#conversejs
div
#chatrooms
,
#conversejs
div
#login-dialog
,
#conversejs
div
#settings
{
border
:
0
;
font-size
:
14px
;
background-color
:
white
;
border-bottom-right-radius
:
4px
;
border-bottom-left-radius
:
4px
;
width
:
100%
;
height
:
289px
;
height
:
calc
(
100%
-
35px
);
overflow-y
:
hidden
;
position
:
absolute
;
}
#conversejs
div
#chatrooms
{
#conversejs
div
#chatrooms
{
overflow-y
:
auto
;
overflow-y
:
auto
;
}
}
...
@@ -1413,6 +1460,9 @@ input.custom-xmpp-status {
...
@@ -1413,6 +1460,9 @@ input.custom-xmpp-status {
#conversejs
.chatbox
.dropdown
dd
.search-xmpp
ul
li
:hover
{
#conversejs
.chatbox
.dropdown
dd
.search-xmpp
ul
li
:hover
{
background-color
:
#bed6e5
;
background-color
:
#bed6e5
;
}
}
#conversejs
.xmpp-status-menu
{
text-align
:
left
;
}
#conversejs
.xmpp-status-menu
li
a
{
#conversejs
.xmpp-status-menu
li
a
{
width
:
100%
;
width
:
100%
;
}
}
...
@@ -1433,7 +1483,7 @@ input.custom-xmpp-status {
...
@@ -1433,7 +1483,7 @@ input.custom-xmpp-status {
bottom
:
6px
;
bottom
:
6px
;
box-shadow
:
1px
3px
5px
3px
rgba
(
0
,
0
,
0
,
0.4
);
box-shadow
:
1px
3px
5px
3px
rgba
(
0
,
0
,
0
,
0.4
);
display
:
block
;
display
:
block
;
height
:
324
px
;
height
:
400
px
;
position
:
absolute
;
position
:
absolute
;
}
}
#conversejs
.minimized-chats-flyout
{
#conversejs
.minimized-chats-flyout
{
...
...
css/theme.css
View file @
329746d8
...
@@ -16,6 +16,7 @@ h4,
...
@@ -16,6 +16,7 @@ h4,
h5
,
h5
,
h6
{
h6
{
margin
:
0
0
35px
;
margin
:
0
0
35px
;
text-transform
:
uppercase
;
font-family
:
"Montserrat"
,
"Helvetica Neue"
,
Helvetica
,
Arial
,
sans-serif
;
font-family
:
"Montserrat"
,
"Helvetica Neue"
,
Helvetica
,
Arial
,
sans-serif
;
font-weight
:
700
;
font-weight
:
700
;
letter-spacing
:
1px
;
letter-spacing
:
1px
;
...
...
index.html
View file @
329746d8
...
@@ -260,6 +260,7 @@
...
@@ -260,6 +260,7 @@
play_sounds
:
true
,
play_sounds
:
true
,
roster_groups
:
true
,
roster_groups
:
true
,
show_controlbox_by_default
:
true
,
show_controlbox_by_default
:
true
,
debug
:
false
,
xhr_user_search
:
false
xhr_user_search
:
false
});
});
});
});
...
...
less/converse.less
View file @
329746d8
...
@@ -509,29 +509,32 @@
...
@@ -509,29 +509,32 @@
}
}
}
}
span
.spinner:before {
#conversejs
.spinner:before {
font-size: 24px;
font-size: 24px;
font-family: 'Converse-js' !important;
font-family: 'Converse-js' !important;
content: "\231b";
content: "\231b";
}
}
span
.spinner {
#conversejs
.spinner {
-webkit-animation: spin 2s infinite linear;
-webkit-animation: spin 2s infinite linear;
-moz-animation: spin 2s infinite linear;
-moz-animation: spin 2s infinite linear;
-o-animation: spin 2s infinite linear;
-o-animation: spin 2s infinite linear;
animation: spin 2s infinite linear;
animation: spin 2s infinite linear;
width: 100%;
display: block;
display: block;
text-align: center;
text-align: center;
margin: 5px;
}
}
span.spinner
.centered {
#conversejs
.centered {
text-align: center;
text-align: center;
padding-top: 5em;
display: block;
margin: 5em auto;
}
}
span.spinner
.hor_centered {
#conversejs
.hor_centered {
text-align: center;
text-align: center;
display: block;
margin: 0 auto;
}
}
#conversejs #minimized-chats .box-flyout {
#conversejs #minimized-chats .box-flyout {
...
@@ -811,14 +814,33 @@ span.spinner.hor_centered {
...
@@ -811,14 +814,33 @@ span.spinner.hor_centered {
color: #7EABBB;
color: #7EABBB;
}
}
input.error {
#conversejs
input.error {
border: 1px solid red;
border: 1px solid red;
}
}
#conversejs .
conn-feedback.
error {
#conversejs .error {
color: red;
color: red;
}
}
#converse-register .provider-title {
font-size: 115%;
}
#converse-register .provider-score {
width: 178px;
margin-bottom: 8px;
}
#converse-register .form-help .url {
font-weight: bold;
color: #2D617A;
}
#conversejs .reg-feedback {
font-size: 85%;
}
#conversejs .reg-feedback,
#converse-login .conn-feedback {
#converse-login .conn-feedback {
width: 100%;
width: 100%;
text-align: center;
text-align: center;
...
@@ -893,6 +915,7 @@ dl.add-converse-contact {
...
@@ -893,6 +915,7 @@ dl.add-converse-contact {
#conversejs .fancy-dropdown {
#conversejs .fancy-dropdown {
border:1px solid #ddd;
border:1px solid #ddd;
height: 22px;
height: 22px;
text-align: left;
}
}
#conversejs .fancy-dropdown a.choose-xmpp-status {
#conversejs .fancy-dropdown a.choose-xmpp-status {
...
@@ -1074,6 +1097,7 @@ dl.add-converse-contact {
...
@@ -1074,6 +1097,7 @@ dl.add-converse-contact {
}
}
#converse-roster {
#converse-roster {
text-align: left;
width: 100%;
width: 100%;
position: relative;
position: relative;
margin: 0.5em 0 0 0;
margin: 0.5em 0 0 0;
...
@@ -1131,6 +1155,10 @@ dl.add-converse-contact {
...
@@ -1131,6 +1155,10 @@ dl.add-converse-contact {
width: 148px;
width: 148px;
}
}
#available-chatrooms {
text-align: left;
}
#available-chatrooms dt,
#available-chatrooms dt,
#converse-roster dt {
#converse-roster dt {
font-weight: normal;
font-weight: normal;
...
@@ -1247,36 +1275,84 @@ dl.add-converse-contact {
...
@@ -1247,36 +1275,84 @@ dl.add-converse-contact {
}
}
#conversejs .controlbox-pane {
#conversejs .controlbox-pane {
padding: 0
;
text-align: center
;
b
order-bottom-right-radius: 4px
;
b
ackground-color: white
;
border-bottom-left-radius: 4px;
border-bottom-left-radius: 4px;
border-bottom-right-radius: 4px;
border: 0;
font-size: 14px;
height: 289px;
height: ~"calc(100% - 35px)";
overflow-y: auto;
padding: 0;
position: absolute;
width: 100%;
}
}
#conversejs .controlbox-pane dd {
#conversejs .controlbox-pane dd {
margin-left: 0;
margin-left: 0;
margin-bottom: 0;
margin-bottom: 0;
padding: 1em;
}
}
#conversejs .controlbox-pane dd.odd {
#conversejs .controlbox-pane dd.odd {
background-color: #DCEAC5;
background-color: #DCEAC5;
}
}
#conversejs form#converse-register .title {
font-weight: bold;
}
#conversejs form#converse-register .info {
font-style: italic;
color: green;
font-size: 85%;
margin: 5px 0;
}
#conversejs .form-help,
#conversejs form#converse-register .instructions {
color: gray;
font-size: 85%;
}
#conversejs .form-help:hover,
#conversejs form#converse-register .instructions:hover {
color: #4f4f4f;
}
#conversejs .form-help {
padding-top: 5px;
}
#conversejs form#converse-register .form-errors {
color: red;
display: none;
}
#conversejs form#converse-register,
#conversejs form#converse-login {
#conversejs form#converse-login {
background: white;
background: white;
padding:
2
em 0.5em;
padding:
1
em 0.5em;
}
}
#conversejs form#converse-register input,
#conversejs form#converse-login input {
#conversejs form#converse-login input {
width: 100%;
width: 178px;
height: 30px;
}
}
#conversejs form#converse-register label,
#conversejs form#converse-login label {
#conversejs form#converse-login label {
margin-top: 0.5em;
margin-top: 0.5em;
font-weight: bold;
}
}
#conversejs form#converse-login .login-submit {
#conversejs form#converse-register .login-submit,
#conversejs form#converse-login .login-submit,
#conversejs form#converse-register .submit,
#conversejs form#converse-login .submit {
margin-top: 1em;
margin-top: 1em;
height: 30px;
}
}
#conversejs form.set-xmpp-status {
#conversejs form.set-xmpp-status {
...
@@ -1334,12 +1410,12 @@ select#select-xmpp-status {
...
@@ -1334,12 +1410,12 @@ select#select-xmpp-status {
text-decoration: none;
text-decoration: none;
border-top-right-radius: 4px;
border-top-right-radius: 4px;
border-top-left-radius: 4px;
border-top-left-radius: 4px;
color: #
666
;
color: #
888
;
text-shadow: 0 1px 0 rgba(250, 250, 250, 1);
text-shadow: 0 1px 0 rgba(250, 250, 250, 1);
}
}
#conversejs .chat-head #controlbox-tabs li a:hover {
#conversejs .chat-head #controlbox-tabs li a:hover {
color:
black;
color:
#4f4f4f
}
}
#conversejs .chat-head #controlbox-tabs li a {
#conversejs .chat-head #controlbox-tabs li a {
...
@@ -1357,22 +1433,6 @@ select#select-xmpp-status {
...
@@ -1357,22 +1433,6 @@ select#select-xmpp-status {
color: rgb(102,102,102);
color: rgb(102,102,102);
}
}
#conversejs div#users,
#conversejs div#chatrooms,
#conversejs div#login-dialog,
#conversejs div#settings {
border: 0;
font-size: 14px;
background-color: white;
border-bottom-right-radius: 4px;
border-bottom-left-radius: 4px;
width: 100%;
height: 289px;
height: ~"calc(100% - 35px)";
overflow-y: hidden;
position: absolute;
}
#conversejs div#chatrooms {
#conversejs div#chatrooms {
overflow-y: auto;
overflow-y: auto;
}
}
...
@@ -1607,6 +1667,10 @@ input.custom-xmpp-status {
...
@@ -1607,6 +1667,10 @@ input.custom-xmpp-status {
background-color: #bed6e5;
background-color: #bed6e5;
}
}
#conversejs .xmpp-status-menu {
text-align: left;
}
#conversejs .xmpp-status-menu li a {
#conversejs .xmpp-status-menu li a {
width: 100%;
width: 100%;
}
}
...
@@ -1631,7 +1695,7 @@ input.custom-xmpp-status {
...
@@ -1631,7 +1695,7 @@ input.custom-xmpp-status {
bottom: 6px;
bottom: 6px;
box-shadow: 1px 3px 5px 3px rgba(0,0,0,0.4);
box-shadow: 1px 3px 5px 3px rgba(0,0,0,0.4);
display: block;
display: block;
height:
324
px;
height:
400
px;
position: absolute;
position: absolute;
}
}
...
...
main.js
View file @
329746d8
var
config
;
if
(
typeof
(
require
)
===
'
undefined
'
)
{
/* XXX: Hack to work around r.js's stupid parsing.
* We want to save the configuration in a variable so that we can reuse it in
* tests/main.js.
*/
require
=
{
config
:
function
(
c
)
{
config
=
c
;
}
};
}
require
.
config
({
require
.
config
({
baseUrl
:
'
.
'
,
baseUrl
:
'
.
'
,
paths
:
{
paths
:
{
...
@@ -79,9 +92,11 @@ require.config({
...
@@ -79,9 +92,11 @@ require.config({
"
controlbox
"
:
"
src/templates/controlbox
"
,
"
controlbox
"
:
"
src/templates/controlbox
"
,
"
controlbox_toggle
"
:
"
src/templates/controlbox_toggle
"
,
"
controlbox_toggle
"
:
"
src/templates/controlbox_toggle
"
,
"
field
"
:
"
src/templates/field
"
,
"
field
"
:
"
src/templates/field
"
,
"
form_captcha
"
:
"
src/templates/form_captcha
"
,
"
form_checkbox
"
:
"
src/templates/form_checkbox
"
,
"
form_checkbox
"
:
"
src/templates/form_checkbox
"
,
"
form_input
"
:
"
src/templates/form_input
"
,
"
form_input
"
:
"
src/templates/form_input
"
,
"
form_select
"
:
"
src/templates/form_select
"
,
"
form_select
"
:
"
src/templates/form_select
"
,
"
form_textarea
"
:
"
src/templates/form_textarea
"
,
"
group_header
"
:
"
src/templates/group_header
"
,
"
group_header
"
:
"
src/templates/group_header
"
,
"
info
"
:
"
src/templates/info
"
,
"
info
"
:
"
src/templates/info
"
,
"
login_panel
"
:
"
src/templates/login_panel
"
,
"
login_panel
"
:
"
src/templates/login_panel
"
,
...
@@ -91,6 +106,9 @@ require.config({
...
@@ -91,6 +106,9 @@ require.config({
"
occupant
"
:
"
src/templates/occupant
"
,
"
occupant
"
:
"
src/templates/occupant
"
,
"
pending_contact
"
:
"
src/templates/pending_contact
"
,
"
pending_contact
"
:
"
src/templates/pending_contact
"
,
"
pending_contacts
"
:
"
src/templates/pending_contacts
"
,
"
pending_contacts
"
:
"
src/templates/pending_contacts
"
,
"
register_panel
"
:
"
src/templates/register_panel
"
,
"
register_tab
"
:
"
src/templates/register_tab
"
,
"
registration_form
"
:
"
src/templates/registration_form
"
,
"
requesting_contact
"
:
"
src/templates/requesting_contact
"
,
"
requesting_contact
"
:
"
src/templates/requesting_contact
"
,
"
requesting_contacts
"
:
"
src/templates/requesting_contacts
"
,
"
requesting_contacts
"
:
"
src/templates/requesting_contacts
"
,
"
room_description
"
:
"
src/templates/room_description
"
,
"
room_description
"
:
"
src/templates/room_description
"
,
...
@@ -103,8 +121,7 @@ require.config({
...
@@ -103,8 +121,7 @@ require.config({
"
status_option
"
:
"
src/templates/status_option
"
,
"
status_option
"
:
"
src/templates/status_option
"
,
"
toggle_chats
"
:
"
src/templates/toggle_chats
"
,
"
toggle_chats
"
:
"
src/templates/toggle_chats
"
,
"
toolbar
"
:
"
src/templates/toolbar
"
,
"
toolbar
"
:
"
src/templates/toolbar
"
,
"
trimmed_chat
"
:
"
src/templates/trimmed_chat
"
,
"
trimmed_chat
"
:
"
src/templates/trimmed_chat
"
"
form_textarea
"
:
"
src/templates/form_textarea
"
},
},
map
:
{
map
:
{
...
@@ -143,10 +160,15 @@ require.config({
...
@@ -143,10 +160,15 @@ require.config({
'
strophe
'
:
{
exports
:
'
Strophe
'
},
'
strophe
'
:
{
exports
:
'
Strophe
'
},
'
strophe.disco
'
:
{
deps
:
[
'
strophe
'
]
},
'
strophe.disco
'
:
{
deps
:
[
'
strophe
'
]
},
'
strophe.muc
'
:
{
deps
:
[
'
strophe
'
]
},
'
strophe.muc
'
:
{
deps
:
[
'
strophe
'
]
},
'
strophe.register
'
:
{
deps
:
[
'
strophe
'
]
},
'
strophe.roster
'
:
{
deps
:
[
'
strophe
'
]
},
'
strophe.roster
'
:
{
deps
:
[
'
strophe
'
]
},
'
strophe.vcard
'
:
{
deps
:
[
'
strophe
'
]
}
'
strophe.vcard
'
:
{
deps
:
[
'
strophe
'
]
}
}
}
});
});
require
([
"
converse
"
],
function
(
converse
)
{
if
(
typeof
(
require
)
===
'
function
'
)
{
require
(
config
);
require
([
"
converse
"
],
function
(
converse
)
{
window
.
converse
=
converse
;
window
.
converse
=
converse
;
});
});
}
mockup/controlbox.html
View file @
329746d8
...
@@ -31,16 +31,26 @@
...
@@ -31,16 +31,26 @@
<div
class=
"chat-head controlbox-head"
>
<div
class=
"chat-head controlbox-head"
>
<ul
id=
"controlbox-tabs"
>
<ul
id=
"controlbox-tabs"
>
<li><a
class=
"current"
href=
"#login"
>
Sign in
</a></li>
<li><a
class=
"current"
href=
"#login"
>
Sign in
</a></li>
<li><a
href=
"#register"
>
Register
</a></li>
</ul>
</ul>
<a
class=
"close-chatbox-button icon-close"
></a>
<a
class=
"close-chatbox-button icon-close"
></a>
</div>
</div>
<div
id=
"login-dialog"
>
<div
id=
"login-dialog"
class=
"controlbox-pane"
>
<form
id=
"converse-login"
>
<form
id=
"converse-login"
>
<label>
XMPP
/Jabber Username:
</label><input
type=
"text"
id=
"jid
"
>
<label>
XMPP
Username:
</label><input
type=
"text"
id=
"jid"
placeholder=
"name@server
"
>
<label>
Password:
</label><input
type=
"password"
id=
"password"
>
<label>
Password:
</label><input
type=
"password"
id=
"password"
>
<input
class=
"login-submit"
type=
"submit"
value=
"Log In"
>
<input
class=
"submit"
type=
"submit"
value=
"Log In"
>
<span
class=
"conn-feedback"
></span>
</form>
</form>
</div>
<div
id=
"register"
class=
"controlbox-pane"
style=
"display: none"
>
<form
id=
"converse-register"
>
<label>
XMPP Username:
</label><input
type=
"text"
id=
"jid"
placeholder=
"name@server"
>
<label>
Password:
</label><input
type=
"password"
name=
"password"
>
<label>
Confirm Password:
</label><input
type=
"password"
name=
"password_confirm"
>
<input
class=
"submit"
type=
"submit"
value=
"Register"
>
<span
class=
"conn-feedback"
></span>
<span
class=
"conn-feedback"
></span>
</form>
</div>
</div>
</div>
</div>
</div>
</div>
...
@@ -55,6 +65,7 @@
...
@@ -55,6 +65,7 @@
</ul>
</ul>
<a
class=
"close-chatbox-button icon-close"
></a>
<a
class=
"close-chatbox-button icon-close"
></a>
</div>
</div>
<div
id=
"users"
class=
"controlbox-pane"
style=
"display: block;"
>
<div
id=
"users"
class=
"controlbox-pane"
style=
"display: block;"
>
<form
class=
"set-xmpp-status"
action=
""
method=
"post"
>
<form
class=
"set-xmpp-status"
action=
""
method=
"post"
>
<span
id=
"xmpp-status-holder"
>
<span
id=
"xmpp-status-holder"
>
...
@@ -227,7 +238,9 @@
...
@@ -227,7 +238,9 @@
</dd>
</dd>
</dl>
</dl>
</div>
</div>
<div
id=
"chatrooms"
style=
"display: none;"
>
</div>
<div
id=
"chatrooms"
class=
"controlbox-pane"
style=
"display: none;"
>
<form
class=
"add-chatroom"
action=
""
method=
"post"
>
<form
class=
"add-chatroom"
action=
""
method=
"post"
>
<input
type=
"text"
name=
"chatroom"
class=
"new-chatroom-name"
placeholder=
"Room name"
>
<input
type=
"text"
name=
"chatroom"
class=
"new-chatroom-name"
placeholder=
"Room name"
>
<input
type=
"text"
name=
"nick"
class=
"new-chatroom-nick"
placeholder=
"Nickname"
>
<input
type=
"text"
name=
"nick"
class=
"new-chatroom-nick"
placeholder=
"Nickname"
>
...
@@ -259,7 +272,7 @@
...
@@ -259,7 +272,7 @@
</dd>
</dd>
</dl>
</dl>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
...
@@ -272,6 +285,12 @@ $(document).ready(function () {
...
@@ -272,6 +285,12 @@ $(document).ready(function () {
$
(
'
a[href=#users]
'
).
click
(
function
(
ev
)
{
$
(
'
a[href=#users]
'
).
click
(
function
(
ev
)
{
switchTab
(
ev
);
switchTab
(
ev
);
});
});
$
(
'
a[href=#register]
'
).
click
(
function
(
ev
)
{
switchTab
(
ev
);
});
$
(
'
a[href=#login]
'
).
click
(
function
(
ev
)
{
switchTab
(
ev
);
});
$
(
"
a.choose-xmpp-status
"
).
click
(
function
(
ev
)
{
$
(
"
a.choose-xmpp-status
"
).
click
(
function
(
ev
)
{
ev
.
preventDefault
();
ev
.
preventDefault
();
...
...
src/templates.js
View file @
329746d8
...
@@ -18,6 +18,7 @@ define("converse-templates", [
...
@@ -18,6 +18,7 @@ define("converse-templates", [
"
tpl!controlbox_toggle
"
,
"
tpl!controlbox_toggle
"
,
"
tpl!field
"
,
"
tpl!field
"
,
"
tpl!form_checkbox
"
,
"
tpl!form_checkbox
"
,
"
tpl!form_captcha
"
,
"
tpl!form_input
"
,
"
tpl!form_input
"
,
"
tpl!form_select
"
,
"
tpl!form_select
"
,
"
tpl!group_header
"
,
"
tpl!group_header
"
,
...
@@ -29,6 +30,9 @@ define("converse-templates", [
...
@@ -29,6 +30,9 @@ define("converse-templates", [
"
tpl!occupant
"
,
"
tpl!occupant
"
,
"
tpl!pending_contact
"
,
"
tpl!pending_contact
"
,
"
tpl!pending_contacts
"
,
"
tpl!pending_contacts
"
,
"
tpl!register_panel
"
,
"
tpl!register_tab
"
,
"
tpl!registration_form
"
,
"
tpl!requesting_contact
"
,
"
tpl!requesting_contact
"
,
"
tpl!requesting_contacts
"
,
"
tpl!requesting_contacts
"
,
"
tpl!room_description
"
,
"
tpl!room_description
"
,
...
@@ -64,30 +68,34 @@ define("converse-templates", [
...
@@ -64,30 +68,34 @@ define("converse-templates", [
controlbox_toggle
:
arguments
[
16
],
controlbox_toggle
:
arguments
[
16
],
field
:
arguments
[
17
],
field
:
arguments
[
17
],
form_checkbox
:
arguments
[
18
],
form_checkbox
:
arguments
[
18
],
form_input
:
arguments
[
19
],
form_captcha
:
arguments
[
19
],
form_select
:
arguments
[
20
],
form_input
:
arguments
[
20
],
group_header
:
arguments
[
21
],
form_select
:
arguments
[
21
],
info
:
arguments
[
22
],
group_header
:
arguments
[
22
],
login_panel
:
arguments
[
23
],
info
:
arguments
[
23
],
login_tab
:
arguments
[
24
],
login_panel
:
arguments
[
24
],
message
:
arguments
[
25
],
login_tab
:
arguments
[
25
],
new_day
:
arguments
[
26
],
message
:
arguments
[
26
],
occupant
:
arguments
[
27
],
new_day
:
arguments
[
27
],
pending_contact
:
arguments
[
28
],
occupant
:
arguments
[
28
],
pending_contacts
:
arguments
[
29
],
pending_contact
:
arguments
[
29
],
requesting_contact
:
arguments
[
30
],
pending_contacts
:
arguments
[
30
],
requesting_contacts
:
arguments
[
31
],
register_panel
:
arguments
[
31
],
room_description
:
arguments
[
32
],
register_tab
:
arguments
[
32
],
room_item
:
arguments
[
33
],
registration_form
:
arguments
[
33
],
room_panel
:
arguments
[
34
],
requesting_contact
:
arguments
[
34
],
roster
:
arguments
[
35
],
requesting_contacts
:
arguments
[
35
],
roster_item
:
arguments
[
36
],
room_description
:
arguments
[
36
],
select_option
:
arguments
[
37
],
room_item
:
arguments
[
37
],
search_contact
:
arguments
[
38
],
room_panel
:
arguments
[
38
],
status_option
:
arguments
[
39
],
roster
:
arguments
[
39
],
toggle_chats
:
arguments
[
40
],
roster_item
:
arguments
[
40
],
toolbar
:
arguments
[
41
],
select_option
:
arguments
[
41
],
trimmed_chat
:
arguments
[
42
],
search_contact
:
arguments
[
42
],
form_textarea
:
arguments
[
43
]
status_option
:
arguments
[
43
],
toggle_chats
:
arguments
[
44
],
toolbar
:
arguments
[
45
],
trimmed_chat
:
arguments
[
46
],
form_textarea
:
arguments
[
47
]
};
};
});
});
src/templates/form_captcha.html
0 → 100644
View file @
329746d8
{[ if (label) { ]}
<label>
{{label}}
</label>
{[ } ]}
<img
src=
"data:{{type}};base64,{{data}}"
>
<input
name=
"{{name}}"
type=
"text"
{[
if
(
required
)
{
]}
class=
"required"
{[
}
]}
>
src/templates/form_checkbox.html
View file @
329746d8
<label>
{{label}}
<input
name=
"{{name}}"
type=
"{{type}}"
{{
checked
}}
></label>
<label>
{{label}}
</label>
<input
name=
"{{name}}"
type=
"{{type}}"
{{
checked
}}
>
src/templates/form_input.html
View file @
329746d8
<label>
{{label}}
<input
name=
"{{name}}"
type=
"{{type}}"
value=
"{{value}}"
></label>
{[ if (label) { ]}
<label>
{{label}}
</label>
{[ } ]}
<input
name=
"{{name}}"
type=
"{{type}}"
{[
if
(
value
)
{
]}
value=
"{{value}}"
{[
}
]}
{[
if
(
required
)
{
]}
class=
"required"
{[
}
]}
>
src/templates/form_select.html
View file @
329746d8
<label>
{{label}}
<select
name=
"{{name}}"
{[
if
(
multiple
)
{
]}
multiple=
"multiple"
{[
}
]}
>
{{options}}
</select></label>
<label>
{{label}}
</label>
<select
name=
"{{name}}"
{[
if
(
multiple
)
{
]}
multiple=
"multiple"
{[
}
]}
>
{{options}}
</select>
src/templates/form_textarea.html
View file @
329746d8
<label
class=
"label-ta"
>
{{label}}
<textarea
name=
"{{name}}"
>
{{value}}
</textarea></label>
<label
class=
"label-ta"
>
{{label}}
</label>
<textarea
name=
"{{name}}"
>
{{value}}
</textarea>
src/templates/login_panel.html
View file @
329746d8
<form
id=
"converse-login"
method=
"post"
>
<form
id=
"converse-login"
method=
"post"
>
<label>
{{label_username}}
</label>
<label>
{{label_username}}
</label>
<input
type=
"username"
name=
"jid"
placeholder=
"
Username
"
>
<input
type=
"username"
name=
"jid"
placeholder=
"
user@server
"
>
<label>
{{label_password}}
</label>
<label>
{{label_password}}
</label>
<input
type=
"password"
name=
"password"
placeholder=
"
P
assword"
>
<input
type=
"password"
name=
"password"
placeholder=
"
p
assword"
>
<input
class=
"
login-
submit"
type=
"submit"
value=
"{{label_login}}"
>
<input
class=
"submit"
type=
"submit"
value=
"{{label_login}}"
>
<span
class=
"conn-feedback"
></span>
<span
class=
"conn-feedback"
></span>
</form>
</form>
src/templates/register_panel.html
0 → 100644
View file @
329746d8
<form
id=
"converse-register"
>
<span
class=
"reg-feedback"
></span>
<label>
{{label_domain}}
</label>
<input
type=
"text"
name=
"domain"
placeholder=
" e.g. conversejs.org"
>
<p
class=
"form-help"
>
Tip: A list of public XMPP providers is available
<a
href=
"https://xmpp.net/directory.php"
class=
"url"
target=
"_blank"
>
here
</a>
.
</p>
<input
class=
"submit"
type=
"submit"
value=
"{{label_register}}"
>
</form>
src/templates/register_tab.html
0 → 100644
View file @
329746d8
<li><a
class=
"s"
href=
"#register"
>
{{label_register}}
</a></li>
src/templates/registration_form.html
0 → 100644
View file @
329746d8
<p
class=
"provider-title"
>
{{domain}}
</p>
<a
href=
'https://xmpp.net/result.php?domain={{domain}}&type=client'
>
<img
class=
"provider-score"
src=
'https://xmpp.net/badge.php?domain={{domain}}'
alt=
'xmpp.net score'
/>
</a>
<p
class=
"title"
>
{{title}}
</p>
<p
class=
"instructions"
>
{{instructions}}
</p>
src/utils.js
View file @
329746d8
define
([
"
jquery
"
],
function
(
$
)
{
define
([
"
jquery
"
,
"
converse-templates
"
],
function
(
$
,
templates
)
{
"
use strict
"
;
var
XFORM_TYPE_MAP
=
{
'
text-private
'
:
'
password
'
,
'
text-single
'
:
'
textline
'
,
'
fixed
'
:
'
label
'
,
'
boolean
'
:
'
checkbox
'
,
'
hidden
'
:
'
hidden
'
,
'
jid-multi
'
:
'
textarea
'
,
'
list-single
'
:
'
dropdown
'
,
'
list-multi
'
:
'
dropdown
'
};
$
.
expr
[
'
:
'
].
emptyVal
=
function
(
obj
){
return
obj
.
value
===
''
;
};
$
.
fn
.
hasScrollBar
=
function
()
{
$
.
fn
.
hasScrollBar
=
function
()
{
if
(
!
$
.
contains
(
document
,
this
.
get
(
0
)))
{
if
(
!
$
.
contains
(
document
,
this
.
get
(
0
)))
{
return
false
;
return
false
;
...
@@ -52,6 +69,111 @@ define(["jquery"], function ($) {
...
@@ -52,6 +69,111 @@ define(["jquery"], function ($) {
* See actionInfoMessages
* See actionInfoMessages
*/
*/
return
str
;
return
str
;
},
webForm2xForm
:
function
(
field
)
{
/* Takes an HTML DOM and turns it into an XForm field.
*
* Parameters:
* (DOMElement) field - the field to convert
*/
var
$input
=
$
(
field
),
value
;
if
(
$input
.
is
(
'
[type=checkbox]
'
))
{
value
=
$input
.
is
(
'
:checked
'
)
&&
1
||
0
;
}
else
if
(
$input
.
is
(
'
textarea
'
))
{
value
=
[];
var
lines
=
$input
.
val
().
split
(
'
\n
'
);
for
(
var
vk
=
0
;
vk
<
lines
.
length
;
vk
++
)
{
var
val
=
$
.
trim
(
lines
[
vk
]);
if
(
val
===
''
)
continue
;
value
.
push
(
val
);
}
}
else
{
value
=
$input
.
val
();
}
return
$
(
templates
.
field
({
name
:
$input
.
attr
(
'
name
'
),
value
:
value
}))[
0
];
},
xForm2webForm
:
function
(
$field
,
$stanza
)
{
/* Takes a field in XMPP XForm (XEP-004: Data Forms) format
* and turns it into a HTML DOM field.
*
* Parameters:
* (XMLElement) field - the field to convert
*/
// FIXME: take <required> into consideration
var
options
=
[],
j
,
$options
,
$values
,
value
,
values
;
if
(
$field
.
attr
(
'
type
'
)
==
'
list-single
'
||
$field
.
attr
(
'
type
'
)
==
'
list-multi
'
)
{
values
=
[];
$values
=
$field
.
children
(
'
value
'
);
for
(
j
=
0
;
j
<
$values
.
length
;
j
++
)
{
values
.
push
(
$
(
$values
[
j
]).
text
());
}
$options
=
$field
.
children
(
'
option
'
);
for
(
j
=
0
;
j
<
$options
.
length
;
j
++
)
{
value
=
$
(
$options
[
j
]).
find
(
'
value
'
).
text
();
options
.
push
(
templates
.
select_option
({
value
:
value
,
label
:
$
(
$options
[
j
]).
attr
(
'
label
'
),
selected
:
(
values
.
indexOf
(
value
)
>=
0
),
required
:
$field
.
find
(
'
required
'
).
length
}));
}
return
templates
.
form_select
({
name
:
$field
.
attr
(
'
var
'
),
label
:
$field
.
attr
(
'
label
'
),
options
:
options
.
join
(
''
),
multiple
:
(
$field
.
attr
(
'
type
'
)
==
'
list-multi
'
),
required
:
$field
.
find
(
'
required
'
).
length
});
}
else
if
(
$field
.
attr
(
'
type
'
)
==
'
fixed
'
)
{
return
$
(
'
<p class="form-help">
'
).
text
(
$field
.
find
(
'
value
'
).
text
());
}
else
if
(
$field
.
attr
(
'
type
'
)
==
'
jid-multi
'
)
{
return
templates
.
form_textarea
({
name
:
$field
.
attr
(
'
var
'
),
label
:
$field
.
attr
(
'
label
'
)
||
''
,
value
:
$field
.
find
(
'
value
'
).
text
(),
required
:
$field
.
find
(
'
required
'
).
length
});
}
else
if
(
$field
.
attr
(
'
type
'
)
==
'
boolean
'
)
{
return
templates
.
form_checkbox
({
name
:
$field
.
attr
(
'
var
'
),
type
:
XFORM_TYPE_MAP
[
$field
.
attr
(
'
type
'
)],
label
:
$field
.
attr
(
'
label
'
)
||
''
,
checked
:
$field
.
find
(
'
value
'
).
text
()
===
"
1
"
&&
'
checked="1"
'
||
''
,
required
:
$field
.
find
(
'
required
'
).
length
});
}
else
if
(
$field
.
attr
(
'
type
'
))
{
return
templates
.
form_input
({
name
:
$field
.
attr
(
'
var
'
),
type
:
XFORM_TYPE_MAP
[
$field
.
attr
(
'
type
'
)],
label
:
$field
.
attr
(
'
label
'
)
||
''
,
value
:
$field
.
find
(
'
value
'
).
text
(),
required
:
$field
.
find
(
'
required
'
).
length
});
}
else
{
if
(
$field
.
attr
(
'
var
'
)
===
'
ocr
'
)
{
// Captcha
return
_
.
reduce
(
_
.
map
(
$field
.
find
(
'
uri
'
),
$
.
proxy
(
function
(
uri
)
{
return
templates
.
form_captcha
({
label
:
this
.
$field
.
attr
(
'
label
'
),
name
:
this
.
$field
.
attr
(
'
var
'
),
data
:
this
.
$stanza
.
find
(
'
data[cid="
'
+
uri
.
textContent
.
replace
(
/^cid:/
,
''
)
+
'
"]
'
).
text
(),
type
:
uri
.
getAttribute
(
'
type
'
),
required
:
this
.
$field
.
find
(
'
required
'
).
length
});
},
{
'
$stanza
'
:
$stanza
,
'
$field
'
:
$field
})
),
function
(
memo
,
num
)
{
return
memo
+
num
;
},
''
);
}
}
}
}
};
};
return
utils
;
return
utils
;
...
...
tests/main.js
View file @
329746d8
config
=
{
baseUrl
:
'
.
'
,
paths
:
{
"
backbone
"
:
"
components/backbone/backbone
"
,
"
backbone.browserStorage
"
:
"
components/backbone.browserStorage/backbone.browserStorage
"
,
"
backbone.overview
"
:
"
components/backbone.overview/backbone.overview
"
,
"
bootstrap
"
:
"
components/bootstrap/dist/js/bootstrap
"
,
// XXX: Only required for https://conversejs.org website
"
bootstrapJS
"
:
"
components/bootstrapJS/index
"
,
// XXX: Only required for https://conversejs.org website
"
converse-dependencies
"
:
"
src/deps-website
"
,
"
converse-templates
"
:
"
src/templates
"
,
"
eventemitter
"
:
"
components/otr/build/dep/eventemitter
"
,
"
jquery
"
:
"
components/jquery/dist/jquery
"
,
"
jquery-private
"
:
"
src/jquery-private
"
,
"
jquery.browser
"
:
"
components/jquery.browser/index
"
,
"
jquery.easing
"
:
"
components/jquery-easing-original/index
"
,
// XXX: Only required for https://conversejs.org website
"
moment
"
:
"
components/momentjs/moment
"
,
"
strophe
"
:
"
components/strophe/strophe
"
,
"
strophe.disco
"
:
"
components/strophejs-plugins/disco/strophe.disco
"
,
"
strophe.muc
"
:
"
components/strophe.muc/index
"
,
"
strophe.roster
"
:
"
src/strophe.roster
"
,
"
strophe.vcard
"
:
"
components/strophejs-plugins/vcard/strophe.vcard
"
,
"
text
"
:
'
components/requirejs-text/text
'
,
"
tpl
"
:
'
components/requirejs-tpl-jcbrand/tpl
'
,
"
typeahead
"
:
"
components/typeahead.js/index
"
,
"
underscore
"
:
"
components/underscore/underscore
"
,
"
utils
"
:
"
src/utils
"
,
// Off-the-record-encryption
"
bigint
"
:
"
src/bigint
"
,
"
crypto
"
:
"
src/crypto
"
,
"
crypto.aes
"
:
"
components/otr/vendor/cryptojs/aes
"
,
"
crypto.cipher-core
"
:
"
components/otr/vendor/cryptojs/cipher-core
"
,
"
crypto.core
"
:
"
components/otr/vendor/cryptojs/core
"
,
"
crypto.enc-base64
"
:
"
components/otr/vendor/cryptojs/enc-base64
"
,
"
crypto.evpkdf
"
:
"
components/crypto-js-evanvosberg/src/evpkdf
"
,
"
crypto.hmac
"
:
"
components/otr/vendor/cryptojs/hmac
"
,
"
crypto.md5
"
:
"
components/crypto-js-evanvosberg/src/md5
"
,
"
crypto.mode-ctr
"
:
"
components/otr/vendor/cryptojs/mode-ctr
"
,
"
crypto.pad-nopadding
"
:
"
components/otr/vendor/cryptojs/pad-nopadding
"
,
"
crypto.sha1
"
:
"
components/otr/vendor/cryptojs/sha1
"
,
"
crypto.sha256
"
:
"
components/otr/vendor/cryptojs/sha256
"
,
"
salsa20
"
:
"
components/otr/build/dep/salsa20
"
,
"
otr
"
:
"
src/otr
"
,
// Locales paths
"
locales
"
:
"
locale/locales
"
,
"
jed
"
:
"
components/jed/jed
"
,
"
af
"
:
"
locale/af/LC_MESSAGES/af
"
,
"
de
"
:
"
locale/de/LC_MESSAGES/de
"
,
"
en
"
:
"
locale/en/LC_MESSAGES/en
"
,
"
es
"
:
"
locale/es/LC_MESSAGES/es
"
,
"
fr
"
:
"
locale/fr/LC_MESSAGES/fr
"
,
"
he
"
:
"
locale/he/LC_MESSAGES/he
"
,
"
hu
"
:
"
locale/hu/LC_MESSAGES/hu
"
,
"
id
"
:
"
locale/id/LC_MESSAGES/id
"
,
"
it
"
:
"
locale/it/LC_MESSAGES/it
"
,
"
ja
"
:
"
locale/ja/LC_MESSAGES/ja
"
,
"
nl
"
:
"
locale/nl/LC_MESSAGES/nl
"
,
"
pt_BR
"
:
"
locale/pt_BR/LC_MESSAGES/pt_BR
"
,
"
ru
"
:
"
locale/ru/LC_MESSAGES/ru
"
,
"
zh
"
:
"
locale/zh/LC_MESSAGES/zh
"
,
// Templates
"
action
"
:
"
src/templates/action
"
,
"
add_contact_dropdown
"
:
"
src/templates/add_contact_dropdown
"
,
"
add_contact_form
"
:
"
src/templates/add_contact_form
"
,
"
change_status_message
"
:
"
src/templates/change_status_message
"
,
"
chat_status
"
:
"
src/templates/chat_status
"
,
"
chatarea
"
:
"
src/templates/chatarea
"
,
"
chatbox
"
:
"
src/templates/chatbox
"
,
"
chatroom
"
:
"
src/templates/chatroom
"
,
"
chatroom_password_form
"
:
"
src/templates/chatroom_password_form
"
,
"
chatroom_sidebar
"
:
"
src/templates/chatroom_sidebar
"
,
"
chatrooms_tab
"
:
"
src/templates/chatrooms_tab
"
,
"
chats_panel
"
:
"
src/templates/chats_panel
"
,
"
choose_status
"
:
"
src/templates/choose_status
"
,
"
contacts_panel
"
:
"
src/templates/contacts_panel
"
,
"
contacts_tab
"
:
"
src/templates/contacts_tab
"
,
"
controlbox
"
:
"
src/templates/controlbox
"
,
"
controlbox_toggle
"
:
"
src/templates/controlbox_toggle
"
,
"
field
"
:
"
src/templates/field
"
,
"
form_checkbox
"
:
"
src/templates/form_checkbox
"
,
"
form_input
"
:
"
src/templates/form_input
"
,
"
form_select
"
:
"
src/templates/form_select
"
,
"
group_header
"
:
"
src/templates/group_header
"
,
"
info
"
:
"
src/templates/info
"
,
"
login_panel
"
:
"
src/templates/login_panel
"
,
"
login_tab
"
:
"
src/templates/login_tab
"
,
"
message
"
:
"
src/templates/message
"
,
"
new_day
"
:
"
src/templates/new_day
"
,
"
occupant
"
:
"
src/templates/occupant
"
,
"
pending_contact
"
:
"
src/templates/pending_contact
"
,
"
pending_contacts
"
:
"
src/templates/pending_contacts
"
,
"
requesting_contact
"
:
"
src/templates/requesting_contact
"
,
"
requesting_contacts
"
:
"
src/templates/requesting_contacts
"
,
"
room_description
"
:
"
src/templates/room_description
"
,
"
room_item
"
:
"
src/templates/room_item
"
,
"
room_panel
"
:
"
src/templates/room_panel
"
,
"
roster
"
:
"
src/templates/roster
"
,
"
roster_item
"
:
"
src/templates/roster_item
"
,
"
search_contact
"
:
"
src/templates/search_contact
"
,
"
select_option
"
:
"
src/templates/select_option
"
,
"
status_option
"
:
"
src/templates/status_option
"
,
"
toggle_chats
"
:
"
src/templates/toggle_chats
"
,
"
toolbar
"
:
"
src/templates/toolbar
"
,
"
trimmed_chat
"
:
"
src/templates/trimmed_chat
"
},
map
:
{
// '*' means all modules will get 'jquery-private'
// for their 'jquery' dependency.
'
*
'
:
{
'
jquery
'
:
'
jquery-private
'
},
// 'jquery-private' wants the real jQuery module
// though. If this line was not here, there would
// be an unresolvable cyclic dependency.
'
jquery-private
'
:
{
'
jquery
'
:
'
jquery
'
}
},
tpl
:
{
// Configuration for requirejs-tpl
// Use Mustache style syntax for variable interpolation
templateSettings
:
{
evaluate
:
/
\{\[([\s\S]
+
?)\]\}
/g
,
interpolate
:
/
\{\{([\s\S]
+
?)\}\}
/g
}
},
// define module dependencies for modules not using define
shim
:
{
'
underscore
'
:
{
exports
:
'
_
'
},
'
crypto.aes
'
:
{
deps
:
[
'
crypto.cipher-core
'
]
},
'
crypto.cipher-core
'
:
{
deps
:
[
'
crypto.enc-base64
'
,
'
crypto.evpkdf
'
]
},
'
crypto.enc-base64
'
:
{
deps
:
[
'
crypto.core
'
]
},
'
crypto.evpkdf
'
:
{
deps
:
[
'
crypto.md5
'
]
},
'
crypto.hmac
'
:
{
deps
:
[
'
crypto.core
'
]
},
'
crypto.md5
'
:
{
deps
:
[
'
crypto.core
'
]
},
'
crypto.mode-ctr
'
:
{
deps
:
[
'
crypto.cipher-core
'
]
},
'
crypto.pad-nopadding
'
:
{
deps
:
[
'
crypto.cipher-core
'
]
},
'
crypto.sha1
'
:
{
deps
:
[
'
crypto.core
'
]
},
'
crypto.sha256
'
:
{
deps
:
[
'
crypto.core
'
]
},
'
bigint
'
:
{
deps
:
[
'
crypto
'
]
},
'
strophe
'
:
{
exports
:
'
Strophe
'
},
'
strophe.disco
'
:
{
deps
:
[
'
strophe
'
]
},
'
strophe.muc
'
:
{
deps
:
[
'
strophe
'
]
},
'
strophe.roster
'
:
{
deps
:
[
'
strophe
'
]
},
'
strophe.vcard
'
:
{
deps
:
[
'
strophe
'
]
}
}
};
// Extra test dependencies
// Extra test dependencies
config
.
paths
.
mock
=
"
tests/mock
"
;
config
.
paths
.
mock
=
"
tests/mock
"
;
config
.
paths
.
test_utils
=
"
tests/utils
"
;
config
.
paths
.
test_utils
=
"
tests/utils
"
;
...
...
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