|
|
@@ -22,9 +22,11 @@ import LoginForm from "@src/components/modules/LoginModule/LoginForm";
|
|
|
|
|
|
import userStore from "@src/stores/UserStore";
|
|
|
import configStore from "@src/utils/Config";
|
|
|
+import disclaimerStore from "@src/stores/DisclaimerStore";
|
|
|
|
|
|
import backgroundImage from "@src/components/ui/Images/star-bg.jpg";
|
|
|
import cbsImage from "./images/cbsl-logo.svg";
|
|
|
+import { ThemeProps } from "@src/components/Theme";
|
|
|
|
|
|
const Wrapper = styled.div<any>`
|
|
|
background-image: url("${backgroundImage}");
|
|
|
@@ -80,6 +82,23 @@ const CbsLogo = styled.a`
|
|
|
cursor: pointer;
|
|
|
`;
|
|
|
|
|
|
+const Disclaimer = styled.div<any>`
|
|
|
+ background: rgba(27, 39, 51, 0.7);
|
|
|
+ border-radius: ${ThemeProps.borderRadius};
|
|
|
+ position: relative;
|
|
|
+ padding: 8px;
|
|
|
+ margin-top: 16px;
|
|
|
+ overflow-wrap: break-word;
|
|
|
+ overflow-y: auto;
|
|
|
+ overflow-x: hidden;
|
|
|
+ white-space: pre-wrap;
|
|
|
+ color: white;
|
|
|
+ width: fit-content;
|
|
|
+ height: fit-content;
|
|
|
+ max-width: 50%;
|
|
|
+ max-height: 25%;
|
|
|
+`;
|
|
|
+
|
|
|
type Props = {
|
|
|
history: any;
|
|
|
};
|
|
|
@@ -102,6 +121,15 @@ class LoginPage extends React.Component<Props, State> {
|
|
|
|
|
|
componentDidMount() {
|
|
|
document.title = "Log In";
|
|
|
+
|
|
|
+ disclaimerStore.loadDisclaimer();
|
|
|
+ }
|
|
|
+
|
|
|
+ renderDisclaimer() {
|
|
|
+ if (!disclaimerStore.disclaimer) {
|
|
|
+ return null;
|
|
|
+ }
|
|
|
+ return <Disclaimer>{disclaimerStore.disclaimer}</Disclaimer>;
|
|
|
}
|
|
|
|
|
|
async handleFormSubmit(data: { username: string; password: string }) {
|
|
|
@@ -139,6 +167,7 @@ class LoginPage extends React.Component<Props, State> {
|
|
|
loginFailedResponse={userStore.loginFailedResponse}
|
|
|
showUserDomainInput={configStore.config.showUserDomainInput}
|
|
|
/>
|
|
|
+ {this.renderDisclaimer()}
|
|
|
</Top>
|
|
|
<Footer>
|
|
|
<FooterText>Coriolis® is a service created by</FooterText>
|