diff --git a/src/Home.jsx b/src/Home.jsx index 600cc62..255e901 100644 --- a/src/Home.jsx +++ b/src/Home.jsx @@ -97,7 +97,7 @@ function UnregisteredView({ }) { return (
-
+
@@ -197,8 +197,8 @@ function RegisteredView({ [styles.fullWidth]: hideCallList, })} > -
- +
+ diff --git a/src/Home.module.css b/src/Home.module.css index 669702b..dcf1ce2 100644 --- a/src/Home.module.css +++ b/src/Home.module.css @@ -22,6 +22,10 @@ background-color: var(--bgColor1); } +.fullWidth .header { + background-color: var(--bgColor1); +} + .centered { display: flex; flex-direction: column; @@ -112,7 +116,7 @@ background-color: var(--bgColor2); } - .leftNav:not(.fullWidth) { + .home:not(.fullWidth) .leftNav { background-color: var(--bgColor2); } @@ -121,7 +125,8 @@ } .fullWidth .content hr:after, - .left .content hr:after { + .left .content hr:after, + .fullWidth .header { background-color: var(--bgColor2); } } diff --git a/src/LoginPage.jsx b/src/LoginPage.jsx index 6c92c18..67493cd 100644 --- a/src/LoginPage.jsx +++ b/src/LoginPage.jsx @@ -16,11 +16,11 @@ limitations under the License. import React, { useCallback, useRef, useState } from "react"; import { useHistory, useLocation, Link } from "react-router-dom"; -import { Header, HeaderLogo, LeftNav } from "./Header"; +import { ReactComponent as Logo } from "./icons/LogoLarge.svg"; import { FieldRow, InputField, ErrorMessage } from "./Input"; -import { Center, Content, Info, Modal } from "./Layout"; import { Button } from "./button"; import { useClient } from "./ConferenceCallManagerHooks"; +import styles from "./LoginPage.module.css"; export function LoginPage() { const { login } = useClient(); @@ -59,72 +59,65 @@ export function LoginPage() { return ( <> -
- - - -
- -
- {loading ? ( -
Loading...
- ) : ( - -

Login

-
+
+
+
+ + +

Log In

+

To continue to Element

+ + + setHomeServer(e.target.value)} + placeholder="Homeserver" + label="Homeserver" + autoCorrect="off" + autoCapitalize="none" + /> + + + + + + + + {error && ( - setHomeServer(e.target.value)} - placeholder="Homeserver" - label="Homeserver" - autoCorrect="off" - autoCapitalize="none" - /> + {error.message} - - - - - - - {error && ( - - {error.message} - - )} - - - - - - New?{" "} - - Create account - - - - )} -
-
+ )} + + + + +
+
+

Not registered yet?

+

+ Create an account + {" Or "} + Access as a guest +

+
+ + ); } diff --git a/src/LoginPage.module.css b/src/LoginPage.module.css new file mode 100644 index 0000000..5507db5 --- /dev/null +++ b/src/LoginPage.module.css @@ -0,0 +1,72 @@ +.logo { + max-width: 300px; + margin: 80px 0; +} + +.container { + display: flex; + flex-direction: column; + align-items: center; + padding: 0 20px; +} + +.content { + display: flex; + flex-direction: column; + max-width: 400px; + width: 100%; + height: 100vh; +} + +.formContainer { + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; + flex: 1; + width: 100%; +} + +.formContainer h2, +.formContainer h4 { + margin-top: 0; +} + +.formContainer h4 { + font-weight: normal; + font-size: 18px; + margin-bottom: 0; +} + +.formContainer form { + width: 100%; +} + +.formContainer form > * { + margin-top: 32px; +} + +.formContainer button { + height: 48px; + width: 100%; + font-size: 15px; + font-weight: 600; +} + +.authLinks { + display: flex; + flex-direction: column; + justify-content: flex-end; + align-items: center; +} + +.authLinks { + margin-bottom: 100px; + font-weight: normal; + font-size: 15px; +} + +.authLinks a { + color: #0dbd8b; + text-decoration: none; +} diff --git a/src/RegisterPage.jsx b/src/RegisterPage.jsx index 434df33..4209bc5 100644 --- a/src/RegisterPage.jsx +++ b/src/RegisterPage.jsx @@ -16,11 +16,11 @@ limitations under the License. import React, { useCallback, useRef, useState } from "react"; import { useHistory, useLocation, Link } from "react-router-dom"; -import { Header, LeftNav, HeaderLogo } from "./Header"; import { FieldRow, InputField, ErrorMessage } from "./Input"; -import { Center, Content, Info, Modal } from "./Layout"; import { Button } from "./button"; import { useClient } from "./ConferenceCallManagerHooks"; +import styles from "./LoginPage.module.css"; +import { ReactComponent as Logo } from "./icons/LogoLarge.svg"; export function RegisterPage() { // TODO: Handle hitting login page with authenticated client @@ -57,61 +57,52 @@ export function RegisterPage() { return ( <> -
- - - -
- -
- {loading ? ( -
Loading...
- ) : ( - -

Register

-
+
+
+
+ +

Create your account

+ + + + + + + + {error && ( - + {error.message} - - - - {error && ( - - {error.message} - - )} - - - - - - Already have an account?{" "} - - Sign in here - - - - )} -
-
+ )} + + + + + +
+

Already have an account?

+

+ Log in + {" Or "} + Access as a guest +

+
+ + ); } diff --git a/src/icons/LogoLarge.svg b/src/icons/LogoLarge.svg new file mode 100644 index 0000000..f7bfbd1 --- /dev/null +++ b/src/icons/LogoLarge.svg @@ -0,0 +1,11 @@ + + + + + + + + + + +