feat(branding) allow invite links to be branded
This commit is contained in:
parent
6453ceb048
commit
8a4fb72eae
|
@ -626,6 +626,13 @@ var config = {
|
||||||
tokenAuthUrl
|
tokenAuthUrl
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
/**
|
||||||
|
* This property can be used to alter the generated meeting invite links (in combination with a branding domain
|
||||||
|
* which is retrieved internally by jitsi meet) (e.g. https://meet.jit.si/someMeeting
|
||||||
|
* can become https://brandedDomain/roomAlias)
|
||||||
|
*/
|
||||||
|
// brandingRoomAlias: null,
|
||||||
|
|
||||||
// List of undocumented settings used in lib-jitsi-meet
|
// List of undocumented settings used in lib-jitsi-meet
|
||||||
/**
|
/**
|
||||||
_peerConnStatusOutOfLastNTimeout
|
_peerConnStatusOutOfLastNTimeout
|
||||||
|
|
|
@ -69,6 +69,7 @@ export default [
|
||||||
|
|
||||||
'channelLastN',
|
'channelLastN',
|
||||||
'constraints',
|
'constraints',
|
||||||
|
'brandingRoomAlias',
|
||||||
'debug',
|
'debug',
|
||||||
'debugAudioLevels',
|
'debugAudioLevels',
|
||||||
'defaultLanguage',
|
'defaultLanguage',
|
||||||
|
|
|
@ -54,7 +54,17 @@ export function getInviteURL(stateOrGetState: Function | Object): string {
|
||||||
throw new Error('Can not get invite URL - the app is not ready');
|
throw new Error('Can not get invite URL - the app is not ready');
|
||||||
}
|
}
|
||||||
|
|
||||||
return getURLWithoutParams(locationURL).href;
|
const { inviteDomain } = state['features/dynamic-branding'];
|
||||||
|
const urlWithoutParams = getURLWithoutParams(locationURL);
|
||||||
|
|
||||||
|
if (inviteDomain) {
|
||||||
|
const meetingId
|
||||||
|
= state['features/base/config'].brandingRoomAlias || urlWithoutParams.pathname;
|
||||||
|
|
||||||
|
return `${inviteDomain}/${meetingId}`;
|
||||||
|
}
|
||||||
|
|
||||||
|
return urlWithoutParams.href;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -53,7 +53,6 @@ function setDynamicBrandingData(value) {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Action used to signal the branding elements are ready to be displayed.
|
* Action used to signal the branding elements are ready to be displayed.
|
||||||
*
|
*
|
||||||
|
|
|
@ -14,6 +14,7 @@ const DEFAULT_STATE = {
|
||||||
backgroundColor: '',
|
backgroundColor: '',
|
||||||
backgroundImageUrl: '',
|
backgroundImageUrl: '',
|
||||||
customizationReady: false,
|
customizationReady: false,
|
||||||
|
inviteDomain: '',
|
||||||
logoClickUrl: '',
|
logoClickUrl: '',
|
||||||
logoImageUrl: ''
|
logoImageUrl: ''
|
||||||
};
|
};
|
||||||
|
@ -24,11 +25,12 @@ const DEFAULT_STATE = {
|
||||||
ReducerRegistry.register(STORE_NAME, (state = DEFAULT_STATE, action) => {
|
ReducerRegistry.register(STORE_NAME, (state = DEFAULT_STATE, action) => {
|
||||||
switch (action.type) {
|
switch (action.type) {
|
||||||
case SET_DYNAMIC_BRANDING_DATA: {
|
case SET_DYNAMIC_BRANDING_DATA: {
|
||||||
const { backgroundColor, backgroundImageUrl, logoClickUrl, logoImageUrl } = action.value;
|
const { backgroundColor, backgroundImageUrl, inviteDomain, logoClickUrl, logoImageUrl } = action.value;
|
||||||
|
|
||||||
return {
|
return {
|
||||||
backgroundColor,
|
backgroundColor,
|
||||||
backgroundImageUrl,
|
backgroundImageUrl,
|
||||||
|
inviteDomain,
|
||||||
logoClickUrl,
|
logoClickUrl,
|
||||||
logoImageUrl,
|
logoImageUrl,
|
||||||
customizationReady: true
|
customizationReady: true
|
||||||
|
|
Loading…
Reference in New Issue