diff --git a/src/components/views/auth/Welcome.tsx b/src/components/views/auth/Welcome.tsx index 29294f70a60..97ff8db5155 100644 --- a/src/components/views/auth/Welcome.tsx +++ b/src/components/views/auth/Welcome.tsx @@ -38,7 +38,19 @@ export default class Welcome extends React.PureComponent { if (pagesConfig) { pageUrl = pagesConfig.get("welcome_url"); } + + const replaceMap: Record = { + "$riot:ssoUrl": "#/start_sso", + "$riot:casUrl": "#/start_cas", + "$matrixLogo": MATRIX_LOGO_HTML, + "[matrix]": MATRIX_LOGO_HTML, + }; + if (!pageUrl) { + // Fall back to default and replace $logoUrl in welcome.html + const brandingConfig = SdkConfig.getObject("branding"); + const logoUrl = brandingConfig?.get("auth_header_logo_url") ?? "themes/element/img/logos/element-logo.svg"; + replaceMap["$logoUrl"] = logoUrl; pageUrl = "welcome.html"; } @@ -49,16 +61,7 @@ export default class Welcome extends React.PureComponent { mx_WelcomePage_registrationDisabled: !SettingsStore.getValue(UIFeature.Registration), })} > - +