Combine the admin settings into one JS file so we watch less resources

Signed-off-by: Joas Schilling <coding@schilljs.com>
This commit is contained in:
Joas Schilling 2020-03-26 12:04:34 +01:00
Родитель 5aa7998e4f
Коммит 21432cdb86
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: 7076EA9751AACDDA
28 изменённых файлов: 156 добавлений и 655 удалений

Просмотреть файл

@ -16,7 +16,7 @@ And in the works for the [coming versions](https://github.com/nextcloud/spreed/m
]]></description>
<version>9.0.0-dev.1</version>
<version>9.0.0-dev.2</version>
<licence>agpl</licence>
<author>Daniel Calviño Sánchez</author>
@ -85,12 +85,7 @@ And in the works for the [coming versions](https://github.com/nextcloud/spreed/m
</commands>
<settings>
<admin>OCA\Talk\Settings\Admin\GeneralSettings</admin>
<admin>OCA\Talk\Settings\Admin\AllowedGroups</admin>
<admin>OCA\Talk\Settings\Admin\Commands</admin>
<admin>OCA\Talk\Settings\Admin\SignalingServer</admin>
<admin>OCA\Talk\Settings\Admin\StunServer</admin>
<admin>OCA\Talk\Settings\Admin\TurnServer</admin>
<admin>OCA\Talk\Settings\Admin\AdminSettings</admin>
<admin-section>OCA\Talk\Settings\Admin\Section</admin-section>
</settings>

Просмотреть файл

@ -25,30 +25,49 @@ namespace OCA\Talk\Settings\Admin;
use OCA\Talk\Config;
use OCA\Talk\Model\Command;
use OCA\Talk\Participant;
use OCA\Talk\Room;
use OCA\Talk\Service\CommandService;
use OCP\AppFramework\Http\TemplateResponse;
use OCP\IConfig;
use OCP\IInitialStateService;
use OCP\Settings\ISettings;
class Commands implements ISettings {
class AdminSettings implements ISettings {
/** @var Config */
private $talkConfig;
/** @var IConfig */
private $serverConfig;
/** @var CommandService */
private $commandService;
/** @var IInitialStateService */
private $initialStateService;
public function __construct(CommandService $commandService,
public function __construct(Config $talkConfig,
IConfig $serverConfig,
CommandService $commandService,
IInitialStateService $initialStateService) {
$this->talkConfig = $talkConfig;
$this->serverConfig = $serverConfig;
$this->commandService = $commandService;
$this->initialStateService = $initialStateService;
}
/**
* @return TemplateResponse
*/
public function getForm(): TemplateResponse {
// General settings
$this->initialStateService->provideInitialState('talk', 'start_calls', (int) $this->serverConfig->getAppValue('spreed', 'start_calls', Room::START_CALL_EVERYONE));
$this->initialStateService->provideInitialState('talk', 'default_group_notification', (int) $this->serverConfig->getAppValue('spreed', 'default_group_notification', Participant::NOTIFY_MENTION));
$this->initialStateService->provideInitialState('talk', 'conversations_files', (int) $this->serverConfig->getAppValue('spreed', 'conversations_files', '1'));
$this->initialStateService->provideInitialState('talk', 'conversations_files_public_shares', (int) $this->serverConfig->getAppValue('spreed', 'conversations_files_public_shares', '1'));
// Allowed groups
$this->initialStateService->provideInitialState('talk', 'allowed_groups', $this->talkConfig->getAllowedGroupIds());
// Commands
$commands = $this->commandService->findAll();
$result = array_map(function(Command $command) {
@ -57,7 +76,21 @@ class Commands implements ISettings {
$this->initialStateService->provideInitialState('talk', 'commands', $result);
return new TemplateResponse('spreed', 'settings/admin/commands', [], '');
// Stun servers
$this->initialStateService->provideInitialState('talk', 'stun_servers', $this->talkConfig->getStunServers());
$this->initialStateService->provideInitialState('talk', 'has_internet_connection', $this->serverConfig->getSystemValueBool('has_internet_connection', true));
// Turn servers
$this->initialStateService->provideInitialState('talk', 'turn_servers', $this->talkConfig->getTurnServers());
// Signaling servers
$this->initialStateService->provideInitialState('talk', 'signaling_servers', [
'servers' => $this->talkConfig->getSignalingServers(),
'secret' => $this->talkConfig->getSignalingSecret(),
'hideWarning' => $this->talkConfig->getHideSignalingWarning(),
]);
return new TemplateResponse('spreed', 'settings/admin-settings', [], '');
}
/**
@ -75,7 +108,7 @@ class Commands implements ISettings {
* E.g.: 70
*/
public function getPriority(): int {
return 60;
return 0;
}
}

Просмотреть файл

@ -1,70 +0,0 @@
<?php
declare(strict_types=1);
/**
* @copyright Copyright (c) 2019 Joas Schilling <coding@schilljs.com>
*
* @license GNU AGPL version 3 or any later version
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as
* published by the Free Software Foundation, either version 3 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*
*/
namespace OCA\Talk\Settings\Admin;
use OCA\Talk\Config;
use OCP\AppFramework\Http\TemplateResponse;
use OCP\IInitialStateService;
use OCP\Settings\ISettings;
class AllowedGroups implements ISettings {
/** @var Config */
private $config;
/** @var IInitialStateService */
private $initialStateService;
public function __construct(Config $config,
IInitialStateService $initialStateService) {
$this->config = $config;
$this->initialStateService = $initialStateService;
}
/**
* @return TemplateResponse
*/
public function getForm(): TemplateResponse {
$this->initialStateService->provideInitialState('talk', 'allowed_groups', $this->config->getAllowedGroupIds());
return new TemplateResponse('spreed', 'settings/admin/allowed-groups', [], '');
}
/**
* @return string the section ID, e.g. 'sharing'
*/
public function getSection(): string {
return 'talk';
}
/**
* @return int whether the form should be rather on the top or bottom of
* the admin section. The forms are arranged in ascending order of the
* priority values. It is required to return a value between 0 and 100.
*
* E.g.: 70
*/
public function getPriority(): int {
return 10;
}
}

Просмотреть файл

@ -1,76 +0,0 @@
<?php
declare(strict_types=1);
/**
* @copyright Copyright (c) 2019 Joas Schilling <coding@schilljs.com>
*
* @license GNU AGPL version 3 or any later version
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as
* published by the Free Software Foundation, either version 3 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*
*/
namespace OCA\Talk\Settings\Admin;
use OCA\Talk\Config;
use OCA\Talk\Participant;
use OCA\Talk\Room;
use OCP\AppFramework\Http\TemplateResponse;
use OCP\IConfig;
use OCP\IInitialStateService;
use OCP\Settings\ISettings;
class GeneralSettings implements ISettings {
/** @var IConfig */
private $config;
/** @var IInitialStateService */
private $initialStateService;
public function __construct(IConfig $config,
IInitialStateService $initialStateService) {
$this->config = $config;
$this->initialStateService = $initialStateService;
}
/**
* @return TemplateResponse
*/
public function getForm(): TemplateResponse {
$this->initialStateService->provideInitialState('talk', 'start_calls', (int) $this->config->getAppValue('spreed', 'start_calls', Room::START_CALL_EVERYONE));
$this->initialStateService->provideInitialState('talk', 'default_group_notification', (int) $this->config->getAppValue('spreed', 'default_group_notification', Participant::NOTIFY_MENTION));
$this->initialStateService->provideInitialState('talk', 'conversations_files', (int) $this->config->getAppValue('spreed', 'conversations_files', '1'));
$this->initialStateService->provideInitialState('talk', 'conversations_files_public_shares', (int) $this->config->getAppValue('spreed', 'conversations_files_public_shares', '1'));
return new TemplateResponse('spreed', 'settings/admin/general-settings', [], '');
}
/**
* @return string the section ID, e.g. 'sharing'
*/
public function getSection(): string {
return 'talk';
}
/**
* @return int whether the form should be rather on the top or bottom of
* the admin section. The forms are arranged in ascending order of the
* priority values. It is required to return a value between 0 and 100.
*
* E.g.: 70
*/
public function getPriority(): int {
return 0;
}
}

Просмотреть файл

@ -1,73 +0,0 @@
<?php
declare(strict_types=1);
/**
* @author Joachim Bauch <mail@joachim-bauch.de>
*
* @license GNU AGPL version 3 or any later version
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as
* published by the Free Software Foundation, either version 3 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*
*/
namespace OCA\Talk\Settings\Admin;
use OCA\Talk\Config;
use OCP\AppFramework\Http\TemplateResponse;
use OCP\IInitialStateService;
use OCP\Settings\ISettings;
class SignalingServer implements ISettings {
/** @var Config */
private $config;
/** @var IInitialStateService */
private $initialStateService;
public function __construct(Config $config,
IInitialStateService $initialStateService) {
$this->config = $config;
$this->initialStateService = $initialStateService;
}
/**
* @return TemplateResponse
*/
public function getForm(): TemplateResponse {
$this->initialStateService->provideInitialState('talk', 'signaling_servers', [
'servers' => $this->config->getSignalingServers(),
'secret' => $this->config->getSignalingSecret(),
'hideWarning' => $this->config->getHideSignalingWarning(),
]);
return new TemplateResponse('spreed', 'settings/admin/signaling-server', [], '');
}
/**
* @return string the section ID, e.g. 'sharing'
*/
public function getSection(): string {
return 'talk';
}
/**
* @return int whether the form should be rather on the top or bottom of
* the admin section. The forms are arranged in ascending order of the
* priority values. It is required to return a value between 0 and 100.
*
* E.g.: 70
*/
public function getPriority(): int {
return 75;
}
}

Просмотреть файл

@ -1,79 +0,0 @@
<?php
declare(strict_types=1);
/**
* @copyright Copyright (c) 2017 Joas Schilling <coding@schilljs.com>
*
* @author Joas Schilling <coding@schilljs.com>
*
* @license GNU AGPL version 3 or any later version
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as
* published by the Free Software Foundation, either version 3 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*
*/
namespace OCA\Talk\Settings\Admin;
use OCA\Talk\Config;
use OCP\AppFramework\Http\TemplateResponse;
use OCP\IConfig;
use OCP\IInitialStateService;
use OCP\Settings\ISettings;
class StunServer implements ISettings {
/** @var Config */
private $config;
/** @var IConfig */
private $serverConfig;
/** @var IInitialStateService */
private $initialStateService;
public function __construct(Config $config,
IConfig $serverConfig,
IInitialStateService $initialStateService) {
$this->config = $config;
$this->serverConfig = $serverConfig;
$this->initialStateService = $initialStateService;
}
/**
* @return TemplateResponse
*/
public function getForm(): TemplateResponse {
$this->initialStateService->provideInitialState('talk', 'stun_servers', $this->config->getStunServers());
$this->initialStateService->provideInitialState('talk', 'has_internet_connection', $this->serverConfig->getSystemValueBool('has_internet_connection', true));
return new TemplateResponse('spreed', 'settings/admin/stun-server', [], '');
}
/**
* @return string the section ID, e.g. 'sharing'
*/
public function getSection(): string {
return 'talk';
}
/**
* @return int whether the form should be rather on the top or bottom of
* the admin section. The forms are arranged in ascending order of the
* priority values. It is required to return a value between 0 and 100.
*
* E.g.: 70
*/
public function getPriority(): int {
return 65;
}
}

Просмотреть файл

@ -1,70 +0,0 @@
<?php
declare(strict_types=1);
/**
* @author Joachim Bauch <mail@joachim-bauch.de>
*
* @license GNU AGPL version 3 or any later version
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as
* published by the Free Software Foundation, either version 3 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*
*/
namespace OCA\Talk\Settings\Admin;
use OCA\Talk\Config;
use OCP\AppFramework\Http\TemplateResponse;
use OCP\IInitialStateService;
use OCP\Settings\ISettings;
class TurnServer implements ISettings {
/** @var Config */
private $config;
/** @var IInitialStateService */
private $initialStateService;
public function __construct(Config $config,
IInitialStateService $initialStateService) {
$this->config = $config;
$this->initialStateService = $initialStateService;
}
/**
* @return TemplateResponse
*/
public function getForm(): TemplateResponse {
$this->initialStateService->provideInitialState('talk', 'turn_servers', $this->config->getTurnServers());
return new TemplateResponse('spreed', 'settings/admin/turn-server', [], '');
}
/**
* @return string the section ID, e.g. 'sharing'
*/
public function getSection(): string {
return 'talk';
}
/**
* @return int whether the form should be rather on the top or bottom of
* the admin section. The forms are arranged in ascending order of the
* priority values. It is required to return a value between 0 and 100.
*
* E.g.: 70
*/
public function getPriority(): int {
return 70;
}
}

Просмотреть файл

@ -1,36 +0,0 @@
/**
* @copyright Copyright (c) 2018 Joas Schilling <coding@schilljs.com>
*
* @author Joas Schilling <coding@schilljs.com>
*
* @license GNU AGPL version 3 or any later version
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as
* published by the Free Software Foundation, either version 3 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*
*/
import Vue from 'vue'
import Commands from './views/AdminSettings/Commands'
Vue.prototype.t = t
Vue.prototype.n = n
Vue.prototype.OC = OC
Vue.prototype.OCA = OCA
Vue.prototype.OCP = OCP
export default new Vue({
el: '#chat_commands',
name: 'CommandsSettings',
render: h => h(Commands),
})

Просмотреть файл

@ -1,36 +0,0 @@
/**
* @copyright Copyright (c) 2019 Joas Schilling <coding@schilljs.com>
*
* @author Joas Schilling <coding@schilljs.com>
*
* @license GNU AGPL version 3 or any later version
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as
* published by the Free Software Foundation, either version 3 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*
*/
import Vue from 'vue'
import GeneralSettings from './views/AdminSettings/GeneralSettings'
Vue.prototype.t = t
Vue.prototype.n = n
Vue.prototype.OC = OC
Vue.prototype.OCA = OCA
Vue.prototype.OCP = OCP
export default new Vue({
el: '#general_settings',
name: 'GeneralSettings',
render: h => h(GeneralSettings),
})

Просмотреть файл

@ -1,36 +0,0 @@
/**
* @copyright Copyright (c) 2018 Joas Schilling <coding@schilljs.com>
*
* @author Joas Schilling <coding@schilljs.com>
*
* @license GNU AGPL version 3 or any later version
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as
* published by the Free Software Foundation, either version 3 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*
*/
import Vue from 'vue'
import SignalingServers from './views/AdminSettings/SignalingServers'
Vue.prototype.t = t
Vue.prototype.n = n
Vue.prototype.OC = OC
Vue.prototype.OCA = OCA
Vue.prototype.OCP = OCP
export default new Vue({
el: '#signaling_server',
name: 'SignalingServerSettings',
render: h => h(SignalingServers),
})

Просмотреть файл

@ -1,36 +0,0 @@
/**
* @copyright Copyright (c) 2018 Joas Schilling <coding@schilljs.com>
*
* @author Joas Schilling <coding@schilljs.com>
*
* @license GNU AGPL version 3 or any later version
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as
* published by the Free Software Foundation, either version 3 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*
*/
import Vue from 'vue'
import StunServers from './views/AdminSettings/StunServers'
Vue.prototype.t = t
Vue.prototype.n = n
Vue.prototype.OC = OC
Vue.prototype.OCA = OCA
Vue.prototype.OCP = OCP
export default new Vue({
el: '#stun_server',
name: 'StunServerSettings',
render: h => h(StunServers),
})

Просмотреть файл

@ -1,36 +0,0 @@
/**
* @copyright Copyright (c) 2018 Joas Schilling <coding@schilljs.com>
*
* @author Joas Schilling <coding@schilljs.com>
*
* @license GNU AGPL version 3 or any later version
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as
* published by the Free Software Foundation, either version 3 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*
*/
import Vue from 'vue'
import TurnServers from './views/AdminSettings/TurnServers'
Vue.prototype.t = t
Vue.prototype.n = n
Vue.prototype.OC = OC
Vue.prototype.OCA = OCA
Vue.prototype.OCP = OCP
export default new Vue({
el: '#turn_server',
name: 'TurnServerSettings',
render: h => h(TurnServers),
})

Просмотреть файл

@ -21,7 +21,7 @@
*/
import Vue from 'vue'
import AllowedGroups from './views/AdminSettings/AllowedGroups'
import AdminSettings from './views/AdminSettings'
Vue.prototype.t = t
Vue.prototype.n = n
@ -30,7 +30,6 @@ Vue.prototype.OCA = OCA
Vue.prototype.OCP = OCP
export default new Vue({
el: '#allowed_groups',
name: 'AllowedGroupsSettings',
render: h => h(AllowedGroups),
el: '#admin_settings',
render: h => h(AdminSettings),
})

Просмотреть файл

@ -0,0 +1,54 @@
<!--
- @copyright Copyright (c) 2019 Joas Schilling <coding@schilljs.com>
-
- @author Joas Schilling <coding@schilljs.com>
-
- @license GNU AGPL version 3 or any later version
-
- This program is free software: you can redistribute it and/or modify
- it under the terms of the GNU Affero General Public License as
- published by the Free Software Foundation, either version 3 of the
- License, or (at your option) any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU Affero General Public License for more details.
-
- You should have received a copy of the GNU Affero General Public License
- along with this program. If not, see <http://www.gnu.org/licenses/>.
-
-->
<template>
<div>
<GeneralSettings />
<AllowedGroups />
<Commands />
<StunServers />
<TurnServers />
<SignalingServers />
</div>
</template>
<script>
import GeneralSettings from '../components/AdminSettings/GeneralSettings'
import AllowedGroups from '../components/AdminSettings/AllowedGroups'
import Commands from '../components/AdminSettings/Commands'
import StunServers from '../components/AdminSettings/StunServers'
import TurnServers from '../components/AdminSettings/TurnServers'
import SignalingServers from '../components/AdminSettings/SignalingServers'
export default {
name: 'AdminSettings',
components: {
GeneralSettings,
AllowedGroups,
Commands,
StunServers,
TurnServers,
SignalingServers,
},
}
</script>

Просмотреть файл

@ -0,0 +1,58 @@
<?php
/** @var array $_ */
/** @var \OCP\IL10N $l */
script('spreed', ['admin-settings']);
style('spreed', ['settings-admin']);
?>
<div id="admin_settings">
<div class="videocalls section" id="general_settings">
<h2><?php p($l->t('General settings')) ?></h2>
</div>
<div class="videocalls section" id="allowed_groups">
<h2><?php p($l->t('Limit to groups')) ?></h2>
<p class="settings-hint"><?php p($l->t('When at least one group is selected, only people of the listed groups can be part of conversations.')); ?></p>
<p class="settings-hint"><?php p($l->t('Guests can still join public conversations.')); ?></p>
<p class="settings-hint"><?php p($l->t('Users that can not use Talk anymore will still be listed as participants in their previous conversations and also their chat messages will be kept.')); ?></p>
</div>
<div class="videocalls section" id="chat_commands">
<h2><?php p($l->t('Commands')) ?></h2>
<p class="settings-hint"><?php p($l->t('Specify commands the users can use in chats')); ?></p>
<div class="commands">
</div>
</div>
<div id="stun_server" class="videocalls section">
<h2><?php p($l->t('STUN servers')) ?></h2>
<p class="settings-hint"><?php p($l->t('A STUN server is used to determine the public IP address of participants behind a router.')); ?></p>
<div class="stun-servers">
</div>
</div>
<div id="turn_server" class="videocalls section">
<h2><?php p($l->t('TURN server')) ?></h2>
<p class="settings-hint"><?php p($l->t('The TURN server is used to proxy the traffic from participants behind a firewall.')); ?></p>
<div class="turn-servers">
</div>
</div>
<div id="signaling_server" class="videocalls section">
<h2><?php p($l->t('Signaling servers')) ?></h2>
<p class="settings-hint"><?php p($l->t('An external signaling server can optionally be used for larger installations. Leave empty to use the internal signaling server.')) ?></p>
<div class="signaling-servers">
</div>
<div class="signaling-secret">
<h4><?php p($l->t('Shared secret')) ?></h4>
<input type="text" id="signaling_secret"
name="signaling_secret" placeholder="<?php p($l->t('Shared secret')) ?>" aria-label="<?php p($l->t('Shared secret')) ?>"/>
</div>
</div>
</div>

Просмотреть файл

@ -1,13 +0,0 @@
<?php
/** @var array $_ */
/** @var \OCP\IL10N $l */
script('spreed', ['admin/allowed-groups']);
style('spreed', ['settings-admin']);
?>
<div class="videocalls section" id="allowed_groups">
<h2><?php p($l->t('Limit to groups')) ?></h2>
<p class="settings-hint"><?php p($l->t('When at least one group is selected, only people of the listed groups can be part of conversations.')); ?></p>
<p class="settings-hint"><?php p($l->t('Guests can still join public conversations.')); ?></p>
<p class="settings-hint"><?php p($l->t('Users that can not use Talk anymore will still be listed as participants in their previous conversations and also their chat messages will be kept.')); ?></p>
</div>

Просмотреть файл

@ -1,14 +0,0 @@
<?php
/** @var array $_ */
/** @var \OCP\IL10N $l */
script('spreed', ['admin/commands']);
style('spreed', ['settings-admin']);
?>
<div class="videocalls section" id="chat_commands">
<h2><?php p($l->t('Commands')) ?></h2>
<p class="settings-hint"><?php p($l->t('Specify commands the users can use in chats')); ?></p>
<div class="commands">
</div>
</div>

Просмотреть файл

@ -1,10 +0,0 @@
<?php
/** @var array $_ */
/** @var \OCP\IL10N $l */
script('spreed', ['admin/general-settings']);
style('spreed', ['settings-admin']);
?>
<div class="videocalls section" id="general_settings">
<h2><?php p($l->t('General settings')) ?></h2>
</div>

Просмотреть файл

@ -1,20 +0,0 @@
<?php
/** @var array $_ */
/** @var \OCP\IL10N $l */
script('spreed', ['admin/signaling-server']);
style('spreed', ['settings-admin']);
?>
<div id="signaling_server" class="videocalls section">
<h2><?php p($l->t('Signaling servers')) ?></h2>
<p class="settings-hint"><?php p($l->t('An external signaling server can optionally be used for larger installations. Leave empty to use the internal signaling server.')) ?></p>
<div class="signaling-servers">
</div>
<div class="signaling-secret">
<h4><?php p($l->t('Shared secret')) ?></h4>
<input type="text" id="signaling_secret"
name="signaling_secret" placeholder="<?php p($l->t('Shared secret')) ?>" aria-label="<?php p($l->t('Shared secret')) ?>"/>
</div>
</div>

Просмотреть файл

@ -1,14 +0,0 @@
<?php
/** @var array $_ */
/** @var \OCP\IL10N $l */
script('spreed', ['admin/stun-server']);
style('spreed', ['settings-admin']);
?>
<div id="stun_server" class="videocalls section">
<h2><?php p($l->t('STUN servers')) ?></h2>
<p class="settings-hint"><?php p($l->t('A STUN server is used to determine the public IP address of participants behind a router.')); ?></p>
<div class="stun-servers">
</div>
</div>

Просмотреть файл

@ -1,14 +0,0 @@
<?php
/** @var array $_ */
/** @var \OCP\IL10N $l */
script('spreed', ['admin/turn-server']);
style('spreed', ['settings-admin']);
?>
<div id="turn_server" class="videocalls section">
<h2><?php p($l->t('TURN server')) ?></h2>
<p class="settings-hint"><?php p($l->t('The TURN server is used to proxy the traffic from participants behind a firewall.')); ?></p>
<div class="turn-servers">
</div>
</div>

Просмотреть файл

@ -4,12 +4,7 @@ const StyleLintPlugin = require('stylelint-webpack-plugin')
module.exports = {
entry: {
'admin/allowed-groups': path.join(__dirname, 'src', 'AllowedGroupsSettings.js'),
'admin/commands': path.join(__dirname, 'src', 'CommandsSettings.js'),
'admin/general-settings': path.join(__dirname, 'src', 'GeneralSettings.js'),
'admin/signaling-server': path.join(__dirname, 'src', 'SignalingServerSettings.js'),
'admin/stun-server': path.join(__dirname, 'src', 'StunServerSettings.js'),
'admin/turn-server': path.join(__dirname, 'src', 'TurnServerSettings.js'),
'admin-settings': path.join(__dirname, 'src', 'mainAdminSettings.js'),
'collections': path.join(__dirname, 'src', 'collections.js'),
'talk': path.join(__dirname, 'src', 'main.js'),
'talk-files-sidebar': path.join(__dirname, 'src', 'mainFilesSidebar.js'),