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
fb11cfe7
Commit
fb11cfe7
authored
Apr 24, 2018
by
JC Brand
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add `converse-embedded` class without requiring an override
parent
76a47829
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
18 deletions
+4
-18
src/converse-chatboxes.js
src/converse-chatboxes.js
+1
-0
src/converse-muc-embedded.js
src/converse-muc-embedded.js
+3
-18
No files found.
src/converse-chatboxes.js
View file @
fb11cfe7
...
...
@@ -653,6 +653,7 @@
initialize
()
{
this
.
model
.
on
(
"
add
"
,
this
.
onChatBoxAdded
,
this
);
this
.
model
.
on
(
"
destroy
"
,
this
.
removeChat
,
this
);
this
.
el
.
classList
.
add
(
`converse-
${
_converse
.
view_mode
}
`
);
this
.
render
();
},
...
...
src/converse-muc-embedded.js
View file @
fb11cfe7
// Converse.js
(A browser based XMPP chat client)
// Converse.js
// http://conversejs.org
//
// Copyright (c) 2012-201
7, Jan-Carel Brand <jc@opkode.com>
// Copyright (c) 2012-201
8, the Converse.js developers
// Licensed under the Mozilla Public License (MPLv2)
//
(
function
(
root
,
factory
)
{
define
([
"
converse-core
"
,
"
converse-muc
"
],
factory
);
}(
this
,
function
(
converse
)
{
...
...
@@ -16,21 +16,6 @@
return
_converse
.
view_mode
===
'
embedded
'
;
},
overrides
:
{
// Overrides mentioned here will be picked up by converse.js's
// plugin architecture they will replace existing methods on the
// relevant objects or classes.
//
// New functions which don't exist yet can also be added.
ChatBoxViews
:
{
initialize
()
{
this
.
__super__
.
initialize
.
apply
(
this
,
arguments
);
this
.
el
.
classList
.
add
(
'
converse-embedded
'
);
}
}
},
initialize
()
{
/* The initialize function gets called as soon as the plugin is
* loaded by converse.js's plugin machinery.
...
...
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