2017-10-25 01:37:26 +03:00
|
|
|
/*
|
|
|
|
Copyright 2015, 2016 OpenMarket Ltd
|
2019-01-21 21:05:07 +03:00
|
|
|
Copyright 2019 New Vector Ltd
|
2017-10-25 01:37:26 +03:00
|
|
|
|
|
|
|
Licensed under the Apache License, Version 2.0 (the "License");
|
|
|
|
you may not use this file except in compliance with the License.
|
|
|
|
You may obtain a copy of the License at
|
|
|
|
|
|
|
|
http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
|
|
|
|
Unless required by applicable law or agreed to in writing, software
|
|
|
|
distributed under the License is distributed on an "AS IS" BASIS,
|
|
|
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
|
|
See the License for the specific language governing permissions and
|
|
|
|
limitations under the License.
|
|
|
|
*/
|
|
|
|
|
2019-08-30 12:27:51 +03:00
|
|
|
import React from 'react';
|
2019-12-20 04:19:56 +03:00
|
|
|
import * as sdk from '../../../index';
|
2021-06-29 15:11:58 +03:00
|
|
|
import { replaceableComponent } from "../../../utils/replaceableComponent";
|
2017-10-25 01:37:26 +03:00
|
|
|
|
2021-07-15 16:21:33 +03:00
|
|
|
interface IProps {
|
|
|
|
disableLanguageSelector?: boolean;
|
|
|
|
}
|
2020-04-15 16:19:47 +03:00
|
|
|
|
2021-07-15 16:21:33 +03:00
|
|
|
@replaceableComponent("views.auth.AuthHeader")
|
|
|
|
export default class AuthHeader extends React.Component<IProps> {
|
|
|
|
public render(): React.ReactNode {
|
2019-01-23 06:51:42 +03:00
|
|
|
const AuthHeaderLogo = sdk.getComponent('auth.AuthHeaderLogo');
|
2019-01-24 01:10:34 +03:00
|
|
|
const LanguageSelector = sdk.getComponent('views.auth.LanguageSelector');
|
2019-01-23 06:51:42 +03:00
|
|
|
|
2019-01-21 21:05:07 +03:00
|
|
|
return (
|
2019-01-22 03:33:17 +03:00
|
|
|
<div className="mx_AuthHeader">
|
2019-01-23 06:51:42 +03:00
|
|
|
<AuthHeaderLogo />
|
2020-04-15 16:19:47 +03:00
|
|
|
<LanguageSelector disabled={this.props.disableLanguageSelector} />
|
2019-01-21 21:05:07 +03:00
|
|
|
</div>
|
|
|
|
);
|
2020-08-29 14:14:16 +03:00
|
|
|
}
|
|
|
|
}
|