mirror of
https://gitcode.com/GitHub_Trending/ji/jitsi-meet.git
synced 2025-12-30 03:12:29 +00:00
feat(dynamic-branding): Add etherpadBase
This commit is contained in:
committed by
Дамян Минков
parent
d29a77b15f
commit
462f91f070
@@ -120,7 +120,9 @@ UI.unbindEvents = () => {
|
||||
* @param {string} name etherpad id
|
||||
*/
|
||||
UI.initEtherpad = name => {
|
||||
const etherpadBaseUrl = sanitizeUrl(config.etherpad_base);
|
||||
const { getState, dispatch } = APP.store;
|
||||
const configState = getState()['features/base/config'];
|
||||
const etherpadBaseUrl = sanitizeUrl(configState.etherpad_base);
|
||||
|
||||
if (etherpadManager || !etherpadBaseUrl || !name) {
|
||||
return;
|
||||
@@ -131,9 +133,9 @@ UI.initEtherpad = name => {
|
||||
|
||||
const url = new URL(name, etherpadBaseUrl);
|
||||
|
||||
APP.store.dispatch(setDocumentUrl(url.toString()));
|
||||
dispatch(setDocumentUrl(url.toString()));
|
||||
|
||||
if (config.openSharedDocumentOnJoin) {
|
||||
if (configState.openSharedDocumentOnJoin) {
|
||||
etherpadManager.toggleEtherpad();
|
||||
}
|
||||
};
|
||||
|
||||
@@ -211,7 +211,6 @@ export function initAnalytics(store: IStore, handlers: Array<Object>): boolean {
|
||||
overwritesCustomParticipantButtonsWithURL?: boolean;
|
||||
overwritesDefaultLogoUrl?: boolean;
|
||||
overwritesDeploymentUrls?: boolean;
|
||||
overwritesEtherpadBase?: boolean;
|
||||
overwritesLiveStreamingUrls?: boolean;
|
||||
overwritesSalesforceUrl?: boolean;
|
||||
overwritesSupportUrl?: boolean;
|
||||
@@ -257,7 +256,6 @@ export function initAnalytics(store: IStore, handlers: Array<Object>): boolean {
|
||||
permanentProperties.overwritesSupportUrl = 'interfaceConfig.SUPPORT_URL' in params;
|
||||
permanentProperties.overwritesSalesforceUrl = 'config.salesforceUrl' in params;
|
||||
permanentProperties.overwritesDefaultLogoUrl = 'config.defaultLogoUrl' in params;
|
||||
permanentProperties.overwritesEtherpadBase = 'config.etherpad_base' in params;
|
||||
|
||||
const deploymentUrlsConfig = params['config.deploymentUrls'] ?? {};
|
||||
|
||||
|
||||
@@ -115,6 +115,7 @@ function _setDynamicBrandingData({ dispatch }: IStore, next: Function, action: A
|
||||
const config: IConfig = {};
|
||||
const {
|
||||
downloadAppsUrl,
|
||||
etherpadBase,
|
||||
liveStreamingDialogUrls = {},
|
||||
preCallTest = {},
|
||||
salesforceUrl,
|
||||
@@ -167,6 +168,11 @@ function _setDynamicBrandingData({ dispatch }: IStore, next: Function, action: A
|
||||
};
|
||||
}
|
||||
|
||||
if (etherpadBase) {
|
||||
// eslint-disable-next-line camelcase
|
||||
config.etherpad_base = etherpadBase;
|
||||
}
|
||||
|
||||
if (iceUrl) {
|
||||
config.prejoinConfig = config.prejoinConfig || {};
|
||||
config.prejoinConfig.preCallTestICEUrl = iceUrl;
|
||||
|
||||
@@ -24,6 +24,7 @@ MiddlewareRegistry.register(store => next => action => {
|
||||
brandedIcons,
|
||||
didPageUrl,
|
||||
downloadAppsUrl,
|
||||
etherpadBase,
|
||||
inviteDomain,
|
||||
labels,
|
||||
liveStreamingDialogUrls,
|
||||
@@ -41,6 +42,7 @@ MiddlewareRegistry.register(store => next => action => {
|
||||
brandedIcons,
|
||||
didPageUrl,
|
||||
downloadAppsUrl,
|
||||
etherpadBase,
|
||||
inviteDomain,
|
||||
labels,
|
||||
liveStreamingDialogUrls,
|
||||
|
||||
Reference in New Issue
Block a user