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
11c1b016
Commit
11c1b016
authored
Mar 14, 2019
by
JC Brand
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add converse-headless.js dist file and recipes
updates #1352
parent
d919e812
Changes
7
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
71092 additions
and
190 deletions
+71092
-190
Makefile
Makefile
+11
-2
dist/converse.js
dist/converse.js
+164
-154
src/converse-muc-views.js
src/converse-muc-views.js
+5
-0
src/headless/converse-core.js
src/headless/converse-core.js
+24
-24
src/headless/converse-muc.js
src/headless/converse-muc.js
+10
-8
src/headless/dist/converse-headless.js
src/headless/dist/converse-headless.js
+70876
-0
src/headless/package.json
src/headless/package.json
+2
-2
No files found.
Makefile
View file @
11c1b016
...
...
@@ -196,6 +196,8 @@ logo/conversejs-filled%.png:: logo/conversejs-filled.svg
BUILDS
=
dist/converse.js
\
dist/converse.min.js
\
dist/converse-headless.js
\
src/headless/dist/converse-headless.js
\
src/headless/dist/converse-headless.min.js
\
dist/converse-headless.min.js
\
dist/converse-no-dependencies.min.js
\
dist/converse-no-dependencies.js
\
...
...
@@ -207,8 +209,12 @@ dist/converse.min.js: src webpack.config.js stamp-npm @converse/headless
$(NPX)
webpack
--mode
=
production
dist/converse-headless.js
:
src webpack.config.js stamp-npm @converse/headless
$(NPX)
webpack
--mode
=
development
--type
=
headless
src/headless/dist/converse-headless.js
:
dist/converse-headless.js
cp
dist/converse-headless.js src/headless/dist/converse-headless.js
dist/converse-headless.min.js
:
src webpack.config.js stamp-npm @converse/headless
$(NPX)
webpack
--mode
=
production
--type
=
headless
src/headless/dist/converse-headless.min.js
:
dist/converse-headless.min.js
cp
dist/converse-headless.min.js src/headless/dist/converse-headless.min.js
dist/converse-no-dependencies.js
:
src webpack.config.js stamp-npm @converse/headless
$(NPX)
webpack
--mode
=
development
--type
=
nodeps
dist/converse-no-dependencies.min.js
:
src webpack.config.js stamp-npm @converse/headless
...
...
@@ -229,11 +235,14 @@ build:: dev css $(BUILDS)
.PHONY
:
eslint
eslint
:
stamp-npm
$(ESLINT)
src/
$(ESLINT)
src/
*
.js
$(ESLINT)
src/utils/
*
.js
$(ESLINT)
src/headless/
*
.js
$(ESLINT)
src/headless/utils/
*
.js
$(ESLINT)
spec/
.PHONY
:
check
check
:
dist/converse.js eslint
check
:
eslint dist/converse.js
LOG_CR_VERBOSITY
=
INFO
$(CHROMIUM)
--disable-gpu
--no-sandbox
http://localhost:
$(HTTPSERVE_PORT)
/tests/index.html
########################################################################
...
...
dist/converse.js
View file @
11c1b016
This diff is collapsed.
Click to expand it.
src/converse-muc-views.js
View file @
11c1b016
...
...
@@ -3,8 +3,13 @@
//
// Copyright (c) 2013-2019, the Converse.js developers
// Licensed under the Mozilla Public License (MPLv2)
//
// XEP-0045 Multi-User Chat Views
import
"
converse-modal
"
;
import
"
backbone.overview/backbone.orderedlistview
"
;
import
"
backbone.overview/backbone.overview
"
;
import
"
backbone.vdomview
"
;
import
Awesomplete
from
"
awesomplete
"
;
import
_FormData
from
"
formdata-polyfill
"
;
import
converse
from
"
@converse/headless/converse-core
"
;
...
...
src/headless/converse-core.js
View file @
11c1b016
...
...
@@ -443,7 +443,9 @@ function cleanup () {
// out or disconnecting in the previous session.
// This happens in tests. We therefore first clean up.
Backbone
.
history
.
stop
();
if
(
_converse
.
chatboxviews
)
{
_converse
.
chatboxviews
.
closeAllChatBoxes
();
}
unregisterGlobalEventHandlers
();
window
.
localStorage
.
clear
();
window
.
sessionStorage
.
clear
();
...
...
@@ -451,8 +453,9 @@ function cleanup () {
_converse
.
bookmarks
.
reset
();
}
delete
_converse
.
controlboxtoggle
;
if
(
_converse
.
chatboxviews
)
{
delete
_converse
.
chatboxviews
;
}
_converse
.
connection
.
reset
();
_converse
.
tearDown
();
_converse
.
stopListening
();
...
...
@@ -1195,9 +1198,6 @@ _converse.initialize = async function (settings, callback) {
};
this
.
tearDown
=
function
()
{
/* Remove those views which are only allowed with a valid
* connection.
*/
_converse
.
emit
(
'
beforeTearDown
'
);
if
(
!
_
.
isUndefined
(
_converse
.
session
))
{
_converse
.
session
.
destroy
();
...
...
src/headless/converse-muc.js
View file @
11c1b016
...
...
@@ -3,13 +3,12 @@
//
// Copyright (c) 2013-2019, the Converse.js developers
// Licensed under the Mozilla Public License (MPLv2)
//
// XEP-0045 Multi-User Chat
import
"
./converse-disco
"
;
import
"
./utils/emoji
"
;
import
"
./utils/muc
"
;
import
"
backbone.overview/backbone.orderedlistview
"
;
import
"
backbone.overview/backbone.overview
"
;
import
"
backbone.vdomview
"
;
import
converse
from
"
./converse-core
"
;
import
u
from
"
./utils/form
"
;
...
...
@@ -1314,11 +1313,15 @@ converse.plugins.add('converse-muc', {
}
}
if
(
result
===
true
)
{
const
chatroom
=
_converse
.
openChatRoom
(
room_jid
,
{
'
password
'
:
x_el
.
getAttribute
(
'
password
'
)
});
const
chatroom
=
_converse
.
openChatRoom
(
room_jid
,
{
'
password
'
:
x_el
.
getAttribute
(
'
password
'
)
});
if
(
chatroom
.
get
(
'
connection_status
'
)
===
converse
.
ROOMSTATUS
.
DISCONNECTED
)
{
// XXX: Leaky abstraction from views here
if
(
_converse
.
chatboxviews
)
{
_converse
.
chatboxviews
.
get
(
room_jid
).
join
();
}
else
{
_converse
.
chatboxes
.
get
(
room_jid
).
join
();
}
}
}
};
...
...
@@ -1445,8 +1448,7 @@ converse.plugins.add('converse-muc', {
* Creates a new MUC chatroom (aka groupchat)
*
* Similar to {@link _converse.api.rooms.open}, but creates
* the chatroom in the background (i.e. doesn't cause a
* view to open).
* the chatroom in the background (i.e. doesn't cause a view to open).
*
* @method _converse.api.rooms.create
* @param {(string[]|string)} jid|jids The JID or array of
...
...
src/headless/dist/converse-headless.js
0 → 100644
View file @
11c1b016
This diff is collapsed.
Click to expand it.
src/headless/package.json
View file @
11c1b016
...
...
@@ -3,9 +3,9 @@
"version"
:
"4.1.2"
,
"description"
:
"Converse.js Headless build"
,
"author"
:
"cmrd Senya <senya@riseup.net>"
,
"homepage"
:
"https://
github.com/conversejs/converse.js
"
,
"homepage"
:
"https://
conversejs.org
"
,
"license"
:
"MPL-2.0"
,
"main"
:
"
converse-core
.js"
,
"main"
:
"
dist/converse-headless
.js"
,
"files"
:
[
"**/*.js"
,
"templates/*"
...
...
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