First working frontend for the login
This commit is contained in:
parent
9c0b57dbf8
commit
514de0e4ae
5 changed files with 64 additions and 0 deletions
|
@ -45,3 +45,12 @@
|
||||||
color: #fff;
|
color: #fff;
|
||||||
font-size: 100px;
|
font-size: 100px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.sitePage {
|
||||||
|
height: 90vh;
|
||||||
|
display: flex;
|
||||||
|
justify-content: center;
|
||||||
|
}
|
||||||
|
.sitePage h1 {
|
||||||
|
font-size: 80px;
|
||||||
|
}
|
||||||
|
|
|
@ -7,6 +7,7 @@ import SignUp from "./components/pages/SignUp";
|
||||||
import Ueber from "./components/pages/Ueber";
|
import Ueber from "./components/pages/Ueber";
|
||||||
import Lizenzen from "./components/pages/lizenzen";
|
import Lizenzen from "./components/pages/lizenzen";
|
||||||
import Privacy from "./components/pages/Privacy";
|
import Privacy from "./components/pages/Privacy";
|
||||||
|
import Login from "./components/pages/Login";
|
||||||
|
|
||||||
function App() {
|
function App() {
|
||||||
return (
|
return (
|
||||||
|
@ -19,6 +20,7 @@ function App() {
|
||||||
<Route path="/sign-up" component={SignUp} />
|
<Route path="/sign-up" component={SignUp} />
|
||||||
<Route path="/lizenzen" component={Lizenzen} />
|
<Route path="/lizenzen" component={Lizenzen} />
|
||||||
<Route path="/privacy" component={Privacy} />
|
<Route path="/privacy" component={Privacy} />
|
||||||
|
<Route path="/login" component={Login} />
|
||||||
</Switch>
|
</Switch>
|
||||||
</Router>
|
</Router>
|
||||||
</>
|
</>
|
||||||
|
|
12
frontend/src/components/InputField.js
Normal file
12
frontend/src/components/InputField.js
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
import React from "react";
|
||||||
|
|
||||||
|
function InputField(props) {
|
||||||
|
return (
|
||||||
|
<label>
|
||||||
|
<p>{props.LabelName}</p>
|
||||||
|
<input name={props.InputName} type={props.InputType} />
|
||||||
|
</label>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
export default InputField;
|
12
frontend/src/components/SubmitField.js
Normal file
12
frontend/src/components/SubmitField.js
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
import React from "react";
|
||||||
|
|
||||||
|
function SubmitField(props) {
|
||||||
|
const InputValue = props.LabelName;
|
||||||
|
return (
|
||||||
|
<label>
|
||||||
|
<input type="submit" value={InputValue} />
|
||||||
|
</label>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
export default SubmitField;
|
29
frontend/src/components/pages/Login.js
Normal file
29
frontend/src/components/pages/Login.js
Normal file
|
@ -0,0 +1,29 @@
|
||||||
|
import React from "react";
|
||||||
|
import "../../App.css";
|
||||||
|
import Footer from "../../Footer";
|
||||||
|
import InputField from "../InputField";
|
||||||
|
import SubmitField from "../SubmitField";
|
||||||
|
|
||||||
|
export default function Login() {
|
||||||
|
return (
|
||||||
|
<>
|
||||||
|
<div className="sitePage">
|
||||||
|
<h1>Login</h1>
|
||||||
|
<form>
|
||||||
|
<InputField
|
||||||
|
LabelName="Benutzername / Kennung"
|
||||||
|
InputType=""
|
||||||
|
InputName="username"
|
||||||
|
/>
|
||||||
|
<InputField
|
||||||
|
LabelName="Passwort"
|
||||||
|
InputType="password"
|
||||||
|
InputName="password"
|
||||||
|
/>
|
||||||
|
<SubmitField LabelName="Einloggen" />
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
<Footer />
|
||||||
|
</>
|
||||||
|
);
|
||||||
|
}
|
Loading…
Reference in a new issue