CSS for server
This commit is contained in:
@@ -18,62 +18,26 @@ func (s *Server) usersLog(w http.ResponseWriter, r *http.Request) {
|
||||
router.Params(r, &scope)
|
||||
s.limiter.Wait(r.Context())
|
||||
q := r.URL.Query()
|
||||
fmt.Fprintln(w, `
|
||||
<html>
|
||||
<head><title>BOA Log In `+scope+`</title><style>body{
|
||||
filter:invert(80%);
|
||||
background-color: #222;
|
||||
font-size: 5em;
|
||||
zoom: 1.5;
|
||||
-moz-transform: scale(1.5);
|
||||
-moz-transform-origin: 0 0;
|
||||
-o-transform: scale(1.5);
|
||||
-o-transform-origin: 0 0;
|
||||
-webkit-transform: scale(1.5);
|
||||
-webkit-transform-origin: 0 0;
|
||||
transform: scale(1.5);
|
||||
transform-origin: 0 0;
|
||||
}</style></head>
|
||||
<body>
|
||||
<h6 style="margin: 0;">`+scope+`</h6>
|
||||
<form method="post" action="/authorize/`+scope+`?`+q.Encode()+`">
|
||||
<input type="password" name="username" autofocus></input>
|
||||
<input type="submit"></input>
|
||||
</form>
|
||||
</body>
|
||||
</html>
|
||||
`)
|
||||
fmt.Fprintln(w, wrapBody("BOA Log In "+scope, `
|
||||
<h6 style="margin: 0;">`+scope+`</h6>
|
||||
<form method="post" action="/authorize/`+scope+`?`+q.Encode()+`">
|
||||
<input type="password" name="username" autofocus></input>
|
||||
<input type="submit"></input>
|
||||
</form>
|
||||
`))
|
||||
}
|
||||
|
||||
func (s *Server) usersRegister(w http.ResponseWriter, r *http.Request) {
|
||||
scope := ""
|
||||
router.Params(r, &scope)
|
||||
s.limiter.Wait(r.Context())
|
||||
fmt.Fprintln(w, `
|
||||
<html>
|
||||
<head><title>BOA Register `+scope+`</title><style>body{
|
||||
filter:invert(80%);
|
||||
background-color: #222;
|
||||
font-size: 5em;
|
||||
zoom: 1.5;
|
||||
-moz-transform: scale(1.5);
|
||||
-moz-transform-origin: 0 0;
|
||||
-o-transform: scale(1.5);
|
||||
-o-transform-origin: 0 0;
|
||||
-webkit-transform: scale(1.5);
|
||||
-webkit-transform-origin: 0 0;
|
||||
transform: scale(1.5);
|
||||
transform-origin: 0 0;
|
||||
}</style></head>
|
||||
<body>
|
||||
<h6 style="margin: 0;">`+scope+`</h6>
|
||||
<form method="post" action="/users/submit/`+scope+`">
|
||||
<input type="text" name="username" autofocus></input>
|
||||
<input type="submit"></input>
|
||||
</form>
|
||||
</body>
|
||||
</html>
|
||||
`)
|
||||
fmt.Fprintln(w, wrapBody("BOA Register "+scope, `
|
||||
<h6 style="margin: 0;">`+scope+`</h6>
|
||||
<form method="post" action="/users/submit/`+scope+`">
|
||||
<input type="text" name="username" autofocus></input>
|
||||
<input type="submit"></input>
|
||||
</form>
|
||||
`))
|
||||
}
|
||||
|
||||
func (s *Server) usersSubmit(w http.ResponseWriter, r *http.Request) {
|
||||
|
||||
Reference in New Issue
Block a user