mirror of
https://github.com/freedombox/FreedomBox.git
synced 2026-05-27 10:44:33 +00:00
jsxc: Remove inline javascript
Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org> Reviewed-by: Veiko Aasa <veiko17@disroot.org>
This commit is contained in:
parent
3efff2fa42
commit
c865a1cd89
@ -44,9 +44,12 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
$(function() {
|
$(function() {
|
||||||
|
const body = document.querySelector('body');
|
||||||
|
const root = body.getAttribute('data-jsxc-root');
|
||||||
|
const domain = body.getAttribute('data-domain');
|
||||||
var settings = {
|
var settings = {
|
||||||
url: '/bosh/',
|
url: '/bosh/',
|
||||||
domain: plinth_settings.domainname
|
domain: domain
|
||||||
};
|
};
|
||||||
|
|
||||||
jsxc.init({
|
jsxc.init({
|
||||||
@ -58,7 +61,7 @@ $(function() {
|
|||||||
},
|
},
|
||||||
checkFlash: false,
|
checkFlash: false,
|
||||||
rosterAppend: 'body',
|
rosterAppend: 'body',
|
||||||
root: plinth_settings.jsxc_root,
|
root: root,
|
||||||
otr: {
|
otr: {
|
||||||
debug: true,
|
debug: true,
|
||||||
SEND_WHITESPACE_TAG: true,
|
SEND_WHITESPACE_TAG: true,
|
||||||
|
|||||||
@ -54,18 +54,11 @@
|
|||||||
<script src="/javascript/jsxc/lib/jsxc.dep.js"></script>
|
<script src="/javascript/jsxc/lib/jsxc.dep.js"></script>
|
||||||
<script src="/javascript/jsxc/jsxc.js"></script>
|
<script src="/javascript/jsxc/jsxc.js"></script>
|
||||||
|
|
||||||
<script lang="text/javascript">
|
|
||||||
// @license magnet:?xt=urn:btih:0b31508aeb0634b347b8270c7bee4d411b5d4109&dn=agpl-3.0.txt AGPL v3.0 or later
|
|
||||||
var plinth_settings = {
|
|
||||||
"domainname": "{{ domainname }}",
|
|
||||||
"jsxc_root": "{% static 'jsxc/libjs-jsxc' %}"
|
|
||||||
};
|
|
||||||
// @license-end
|
|
||||||
</script>
|
|
||||||
<script src="{% static 'jsxc/jsxc-plinth.js' %}"></script>
|
<script src="{% static 'jsxc/jsxc-plinth.js' %}"></script>
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
<body>
|
<body data-domain="{{ domainname }}"
|
||||||
|
data-jsxc-root="{% static 'jsxc/libjs-jsxc' %}">
|
||||||
<div class="container" id="content" role="main">
|
<div class="container" id="content" role="main">
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-md-6 col-md-offset-3 col-xs-8 col-xs-offset-2">
|
<div class="col-md-6 col-md-offset-3 col-xs-8 col-xs-offset-2">
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user