feat: port reduction (#323)

* move mgmt pkg

* begin package restructure

* rename auth package to authz

* begin start api

* move auth

* move admin

* fix merge

* configs and interceptors

* interceptor

* revert generate-grpc.sh

* some cleanups

* console

* move console

* fix tests and merging

* js linting

* merge

* merging and configs

* change k8s base to current ports

* fixes

* cleanup

* regenerate proto

* remove unnecessary whitespace

* missing param

* go mod tidy

* fix merging

* move login pkg

* cleanup

* move api pkgs again

* fix pkg naming

* fix generate-static.sh for login

* update workflow

* fixes

* logging

* remove duplicate

* comment for optional gateway interfaces

* regenerate protos

* fix proto imports for grpc web

* protos

* grpc web generate

* grpc web generate

* fix changes

* add translation interceptor

* fix merging

* regenerate mgmt proto
This commit is contained in:
Livio Amstutz
2020-07-08 13:56:37 +02:00
committed by GitHub
parent 708652a655
commit 3549a8b64e
330 changed files with 30495 additions and 30809 deletions
+103
View File
@@ -0,0 +1,103 @@
package console
import (
"net/http"
"os"
"path"
"strings"
"time"
"github.com/rakyll/statik/fs"
"github.com/caos/zitadel/internal/api/http/middleware"
_ "github.com/caos/zitadel/internal/ui/console/statik"
)
type Config struct {
Port string
EnvOverwriteDir string
ShortCache middleware.CacheConfig
LongCache middleware.CacheConfig
CSPDomain string
}
type spaHandler struct {
fileSystem http.FileSystem
}
const (
envRequestPath = "/assets/environment.json"
envDefaultDir = "/console/"
)
var (
paths = []string{
"/index.html",
"/manifest.webmanifest",
"/ngsw.json",
"/ngsw-worker.js",
"/safety-worker.js",
"/worker-basic.min.js",
}
)
func (i *spaHandler) Open(name string) (http.File, error) {
ret, err := i.fileSystem.Open(name)
if !os.IsNotExist(err) || path.Ext(name) != "" {
return ret, err
}
return i.fileSystem.Open("/index.html")
}
func Start(config Config) (http.Handler, error) {
statikFS, err := fs.NewWithNamespace("console")
if err != nil {
return nil, err
}
envDir := envDefaultDir
if config.EnvOverwriteDir != "" {
envDir = config.EnvOverwriteDir
}
cache := AssetsCacheInterceptorIgnoreManifest(
config.ShortCache.MaxAge.Duration,
config.ShortCache.SharedMaxAge.Duration,
config.LongCache.MaxAge.Duration,
config.LongCache.SharedMaxAge.Duration,
)
security := middleware.SecurityHeaders(csp(config.CSPDomain), nil)
handler := &http.ServeMux{}
handler.Handle("/", cache(security(http.FileServer(&spaHandler{statikFS}))))
handler.Handle(envRequestPath, cache(security(http.StripPrefix("/assets", http.FileServer(http.Dir(envDir))))))
return handler, nil
}
func csp(zitadelDomain string) *middleware.CSP {
if !strings.HasPrefix(zitadelDomain, "*.") {
zitadelDomain = "*." + zitadelDomain
}
csp := middleware.DefaultSCP
csp.StyleSrc = csp.StyleSrc.AddInline().AddHost("fonts.googleapis.com").AddHost("maxst.icons8.com") //TODO: host it
csp.FontSrc = csp.FontSrc.AddHost("fonts.gstatic.com").AddHost("maxst.icons8.com") //TODO: host it
csp.ScriptSrc = csp.ScriptSrc.AddEval()
csp.ConnectSrc = csp.ConnectSrc.AddHost(zitadelDomain).
AddHost("fonts.googleapis.com").
AddHost("fonts.gstatic.com").
AddHost("maxst.icons8.com") //TODO: host it
return &csp
}
func AssetsCacheInterceptorIgnoreManifest(shortMaxAge, shortSharedMaxAge, longMaxAge, longSharedMaxAge time.Duration) func(http.Handler) http.Handler {
return func(handler http.Handler) http.Handler {
return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
for _, path := range paths {
if r.URL.Path == path {
middleware.AssetsCacheInterceptor(shortMaxAge, shortSharedMaxAge, handler).ServeHTTP(w, r)
return
}
middleware.AssetsCacheInterceptor(longMaxAge, longSharedMaxAge, handler).ServeHTTP(w, r)
return
}
})
}
}
+3
View File
@@ -0,0 +1,3 @@
package statik
//go:generate statik -src=../../../../console/dist/console -dest=.. -ns=console
+28
View File
@@ -0,0 +1,28 @@
package handler
import (
"net/http"
"github.com/caos/zitadel/internal/auth_request/model"
)
const (
queryAuthRequestID = "authRequestID"
)
func (l *Login) getAuthRequest(r *http.Request) (*model.AuthRequest, error) {
authRequestID := r.FormValue(queryAuthRequestID)
if authRequestID == "" {
return nil, nil
}
return l.authRepo.AuthRequestByID(r.Context(), authRequestID)
}
func (l *Login) getAuthRequestAndParseData(r *http.Request, data interface{}) (*model.AuthRequest, error) {
authReq, err := l.getAuthRequest(r)
if err != nil {
return nil, err
}
err = l.parser.Parse(r, data)
return authReq, err
}
@@ -0,0 +1,12 @@
package handler
import (
"net/http"
"github.com/caos/zitadel/internal/auth_request/model"
)
func (l *Login) redirectToCallback(w http.ResponseWriter, r *http.Request, authReq *model.AuthRequest) {
callback := l.oidcAuthCallbackURL + authReq.ID
http.Redirect(w, r, callback, http.StatusFound)
}
@@ -0,0 +1,53 @@
package handler
import (
"net/http"
"github.com/caos/zitadel/internal/auth_request/model"
)
const (
tmplChangePassword = "changepassword"
tmplChangePasswordDone = "changepassworddone"
)
type changePasswordData struct {
OldPassword string `schema:"old_password"`
NewPassword string `schema:"new_password"`
}
func (l *Login) handleChangePassword(w http.ResponseWriter, r *http.Request) {
data := new(changePasswordData)
authReq, err := l.getAuthRequestAndParseData(r, data)
if err != nil {
l.renderError(w, r, authReq, err)
return
}
err = l.authRepo.ChangePassword(setContext(r.Context(), authReq.UserOrgID), authReq.UserID, data.OldPassword, data.NewPassword)
if err != nil {
l.renderChangePassword(w, r, authReq, err)
return
}
l.renderChangePasswordDone(w, r, authReq)
}
func (l *Login) renderChangePassword(w http.ResponseWriter, r *http.Request, authReq *model.AuthRequest, err error) {
var errType, errMessage string
if err != nil {
errMessage = l.getErrorMessage(r, err)
}
data := userData{
baseData: l.getBaseData(r, authReq, "Change Password", errType, errMessage),
LoginName: authReq.LoginName,
}
l.renderer.RenderTemplate(w, r, l.renderer.Templates[tmplChangePassword], data, nil)
}
func (l *Login) renderChangePasswordDone(w http.ResponseWriter, r *http.Request, authReq *model.AuthRequest) {
var errType, errMessage string
data := userData{
baseData: l.getBaseData(r, authReq, "Password Change Done", errType, errMessage),
LoginName: authReq.LoginName,
}
l.renderer.RenderTemplate(w, r, l.renderer.Templates[tmplChangePasswordDone], data, nil)
}
@@ -0,0 +1,18 @@
package handler
import (
"net/http"
)
func (l *Login) handleHealthz(w http.ResponseWriter, r *http.Request) {
w.Write([]byte("OK"))
}
func (l *Login) handleReadiness(w http.ResponseWriter, r *http.Request) {
err := l.authRepo.Health(r.Context())
if err != nil {
http.Error(w, "not ready", http.StatusInternalServerError)
return
}
w.Write([]byte("OK"))
}
@@ -0,0 +1,106 @@
package handler
import (
"net/http"
"github.com/caos/zitadel/internal/auth_request/model"
"github.com/caos/zitadel/internal/errors"
)
const (
queryInitPWCode = "code"
queryInitPWUserID = "userID"
tmplInitPassword = "initpassword"
tmplInitPasswordDone = "initpassworddone"
)
type initPasswordFormData struct {
Code string `schema:"code"`
Password string `schema:"password"`
PasswordConfirm string `schema:"passwordconfirm"`
UserID string `schema:"userID"`
Resend bool `schema:"resend"`
}
type initPasswordData struct {
baseData
Code string
UserID string
}
func (l *Login) handleInitPassword(w http.ResponseWriter, r *http.Request) {
userID := r.FormValue(queryInitPWUserID)
code := r.FormValue(queryInitPWCode)
l.renderInitPassword(w, r, nil, userID, code, nil)
}
func (l *Login) handleInitPasswordCheck(w http.ResponseWriter, r *http.Request) {
data := new(initPasswordFormData)
authReq, err := l.getAuthRequestAndParseData(r, data)
if err != nil {
l.renderError(w, r, authReq, err)
return
}
if data.Resend {
l.resendPasswordSet(w, r, authReq)
return
}
l.checkPWCode(w, r, authReq, data, nil)
}
func (l *Login) checkPWCode(w http.ResponseWriter, r *http.Request, authReq *model.AuthRequest, data *initPasswordFormData, err error) {
if data.Password != data.PasswordConfirm {
err := errors.ThrowInvalidArgument(nil, "VIEW-KaGue", "Errors.User.Password.ConfirmationWrong")
l.renderInitPassword(w, r, authReq, data.UserID, data.Code, err)
return
}
userOrg := login
if authReq != nil {
userOrg = authReq.UserOrgID
}
err = l.authRepo.SetPassword(setContext(r.Context(), userOrg), data.UserID, data.Code, data.Password)
if err != nil {
l.renderInitPassword(w, r, authReq, data.UserID, "", err)
return
}
l.renderInitPasswordDone(w, r, authReq)
}
func (l *Login) resendPasswordSet(w http.ResponseWriter, r *http.Request, authReq *model.AuthRequest) {
userOrg := login
if authReq != nil {
userOrg = authReq.UserOrgID
}
err := l.authRepo.RequestPasswordReset(setContext(r.Context(), userOrg), authReq.LoginName)
l.renderInitPassword(w, r, authReq, authReq.UserID, "", err)
}
func (l *Login) renderInitPassword(w http.ResponseWriter, r *http.Request, authReq *model.AuthRequest, userID, code string, err error) {
var errType, errMessage string
if err != nil {
errMessage = l.getErrorMessage(r, err)
}
if userID == "" && authReq != nil {
userID = authReq.UserID
}
data := initPasswordData{
baseData: l.getBaseData(r, authReq, "Init Password", errType, errMessage),
UserID: userID,
Code: code,
}
l.renderer.RenderTemplate(w, r, l.renderer.Templates[tmplInitPassword], data, nil)
}
func (l *Login) renderInitPasswordDone(w http.ResponseWriter, r *http.Request, authReq *model.AuthRequest) {
loginName := ""
if authReq != nil {
loginName = authReq.LoginName
}
data := userData{
baseData: l.getBaseData(r, authReq, "Password Init Done", "", ""),
LoginName: loginName,
}
l.renderer.RenderTemplate(w, r, l.renderer.Templates[tmplInitPasswordDone], data, nil)
}
@@ -0,0 +1,112 @@
package handler
import (
"net/http"
"strconv"
"github.com/caos/zitadel/internal/auth_request/model"
caos_errs "github.com/caos/zitadel/internal/errors"
)
const (
queryInitUserCode = "code"
queryInitUserUserID = "userID"
queryInitUserPassword = "passwordset"
tmplInitUser = "inituser"
tmplInitUserDone = "inituserdone"
)
type initUserFormData struct {
Code string `schema:"code"`
Password string `schema:"password"`
PasswordConfirm string `schema:"passwordconfirm"`
UserID string `schema:"userID"`
PasswordSet bool `schema:"passwordSet"`
Resend bool `schema:"resend"`
}
type initUserData struct {
baseData
Code string
UserID string
PasswordSet bool
}
func (l *Login) handleInitUser(w http.ResponseWriter, r *http.Request) {
userID := r.FormValue(queryInitUserUserID)
code := r.FormValue(queryInitUserCode)
passwordSet, _ := strconv.ParseBool(r.FormValue(queryInitUserPassword))
l.renderInitUser(w, r, nil, userID, code, passwordSet, nil)
}
func (l *Login) handleInitUserCheck(w http.ResponseWriter, r *http.Request) {
data := new(initUserFormData)
authReq, err := l.getAuthRequestAndParseData(r, data)
if err != nil {
l.renderError(w, r, nil, err)
return
}
if data.Resend {
l.resendUserInit(w, r, authReq, data.UserID, data.PasswordSet)
return
}
l.checkUserInitCode(w, r, authReq, data, nil)
}
func (l *Login) checkUserInitCode(w http.ResponseWriter, r *http.Request, authReq *model.AuthRequest, data *initUserFormData, err error) {
if data.Password != data.PasswordConfirm {
err := caos_errs.ThrowInvalidArgument(nil, "VIEW-fsdfd", "Errors.User.Password.ConfirmationWrong")
l.renderInitUser(w, r, authReq, data.UserID, data.Code, data.PasswordSet, err)
return
}
userOrgID := login
if authReq != nil {
userOrgID = authReq.UserOrgID
}
err = l.authRepo.VerifyInitCode(setContext(r.Context(), userOrgID), data.UserID, data.Code, data.Password)
if err != nil {
l.renderInitUser(w, r, nil, data.UserID, "", data.PasswordSet, err)
return
}
l.renderInitUserDone(w, r, nil)
}
func (l *Login) resendUserInit(w http.ResponseWriter, r *http.Request, authReq *model.AuthRequest, userID string, showPassword bool) {
userOrgID := login
if authReq != nil {
userOrgID = authReq.UserOrgID
}
err := l.authRepo.ResendInitVerificationMail(setContext(r.Context(), userOrgID), userID)
l.renderInitUser(w, r, authReq, userID, "", showPassword, err)
}
func (l *Login) renderInitUser(w http.ResponseWriter, r *http.Request, authReq *model.AuthRequest, userID, code string, passwordSet bool, err error) {
var errType, errMessage string
if err != nil {
errMessage = l.getErrorMessage(r, err)
}
if authReq != nil {
userID = authReq.UserID
}
data := initUserData{
baseData: l.getBaseData(r, nil, "Init User", errType, errMessage),
UserID: userID,
Code: code,
PasswordSet: passwordSet,
}
l.renderer.RenderTemplate(w, r, l.renderer.Templates[tmplInitUser], data, nil)
}
func (l *Login) renderInitUserDone(w http.ResponseWriter, r *http.Request, authReq *model.AuthRequest) {
var loginName string
if authReq != nil {
loginName = authReq.LoginName
}
data := userData{
baseData: l.getBaseData(r, authReq, "User Init Done", "", ""),
LoginName: loginName,
}
l.renderer.RenderTemplate(w, r, l.renderer.Templates[tmplInitUserDone], data, nil)
}
+128
View File
@@ -0,0 +1,128 @@
package handler
import (
"context"
"net"
"net/http"
"github.com/caos/logging"
"github.com/gorilla/csrf"
"github.com/rakyll/statik/fs"
"golang.org/x/text/language"
"github.com/caos/zitadel/internal/api/authz"
"github.com/caos/zitadel/internal/api/http/middleware"
"github.com/caos/zitadel/internal/auth/repository/eventsourcing"
"github.com/caos/zitadel/internal/crypto"
"github.com/caos/zitadel/internal/form"
_ "github.com/caos/zitadel/internal/ui/login/statik"
)
type Login struct {
endpoint string
router http.Handler
renderer *Renderer
parser *form.Parser
authRepo *eventsourcing.EsRepository
zitadelURL string
oidcAuthCallbackURL string
}
type Config struct {
OidcAuthCallbackURL string
ZitadelURL string
LanguageCookieName string
DefaultLanguage language.Tag
CSRF CSRF
Cache middleware.CacheConfig
}
type CSRF struct {
CookieName string
Key *crypto.KeyConfig
Development bool
}
const (
login = "LOGIN"
)
func CreateLogin(config Config, authRepo *eventsourcing.EsRepository, prefix string) *Login {
login := &Login{
oidcAuthCallbackURL: config.OidcAuthCallbackURL,
zitadelURL: config.ZitadelURL,
authRepo: authRepo,
}
statikFS, err := fs.NewWithNamespace("login")
logging.Log("CONFI-Ga21f").OnError(err).Panic("unable to create filesystem")
csrf, err := csrfInterceptor(config.CSRF, login.csrfErrorHandler())
logging.Log("CONFI-dHR2a").OnError(err).Panic("unable to create csrfInterceptor")
cache, err := middleware.DefaultCacheInterceptor(EndpointResources, config.Cache.MaxAge.Duration, config.Cache.SharedMaxAge.Duration)
logging.Log("CONFI-BHq2a").OnError(err).Panic("unable to create cacheInterceptor")
security := middleware.SecurityHeaders(csp(), login.cspErrorHandler)
login.router = CreateRouter(login, statikFS, csrf, cache, security)
login.renderer = CreateRenderer(prefix, statikFS, config.LanguageCookieName, config.DefaultLanguage)
login.parser = form.NewParser()
return login
}
func csp() *middleware.CSP {
csp := middleware.DefaultSCP
csp.ObjectSrc = middleware.CSPSourceOptsSelf()
csp.StyleSrc = csp.StyleSrc.AddNonce()
csp.ScriptSrc = csp.ScriptSrc.AddNonce()
return &csp
}
func csrfInterceptor(config CSRF, errorHandler http.Handler) (func(http.Handler) http.Handler, error) {
csrfKey, err := crypto.LoadKey(config.Key, config.Key.EncryptionKeyID)
if err != nil {
return nil, err
}
return csrf.Protect([]byte(csrfKey),
csrf.Secure(!config.Development),
csrf.CookieName(config.CookieName),
csrf.ErrorHandler(errorHandler),
), nil
}
func (l *Login) Handler() http.Handler {
return l.router
}
func (l *Login) Listen(ctx context.Context) {
if l.endpoint == "" {
l.endpoint = ":80"
} else {
l.endpoint = ":" + l.endpoint
}
defer logging.LogWithFields("APP-xUZof", "port", l.endpoint).Info("html is listening")
httpListener, err := net.Listen("tcp", l.endpoint)
logging.Log("CONFI-W5q2O").OnError(err).Panic("unable to start listener")
httpServer := &http.Server{
Handler: l.router,
}
go func() {
<-ctx.Done()
if err = httpServer.Shutdown(ctx); err != nil {
logging.Log("APP-mJKTv").WithError(err)
}
}()
go func() {
err := httpServer.Serve(httpListener)
logging.Log("APP-oSklt").OnError(err).Panic("unable to start listener")
}()
}
func setContext(ctx context.Context, resourceOwner string) context.Context {
data := authz.CtxData{
UserID: login,
OrgID: resourceOwner,
}
return authz.SetCtxData(ctx, data)
}
@@ -0,0 +1,64 @@
package handler
import (
"net/http"
"github.com/caos/zitadel/internal/auth_request/model"
)
const (
tmplLogin = "login"
)
type loginData struct {
LoginName string `schema:"loginName"`
}
func (l *Login) handleLogin(w http.ResponseWriter, r *http.Request) {
authReq, err := l.getAuthRequest(r)
if err != nil {
l.renderError(w, r, authReq, err)
return
}
if authReq == nil {
http.Redirect(w, r, l.zitadelURL, http.StatusFound)
return
}
l.renderNextStep(w, r, authReq)
}
func (l *Login) handleLoginName(w http.ResponseWriter, r *http.Request) {
authSession, err := l.getAuthRequest(r)
if err != nil {
l.renderError(w, r, authSession, err)
return
}
l.renderLogin(w, r, authSession, nil)
}
func (l *Login) handleLoginNameCheck(w http.ResponseWriter, r *http.Request) {
data := new(loginData)
authReq, err := l.getAuthRequestAndParseData(r, data)
if err != nil {
l.renderError(w, r, authReq, err)
return
}
err = l.authRepo.CheckLoginName(r.Context(), authReq.ID, data.LoginName)
if err != nil {
l.renderLogin(w, r, authReq, err)
return
}
l.renderNextStep(w, r, authReq)
}
func (l *Login) renderLogin(w http.ResponseWriter, r *http.Request, authReq *model.AuthRequest, err error) {
var errType, errMessage string
if err != nil {
errMessage = l.getErrorMessage(r, err)
}
data := userData{
baseData: l.getBaseData(r, authReq, "Login", errType, errMessage),
LoginName: authReq.LoginName,
}
l.renderer.RenderTemplate(w, r, l.renderer.Templates[tmplLogin], data, nil)
}
@@ -0,0 +1,20 @@
package handler
import (
"net/http"
)
const (
tmplLogoutDone = "logoutdone"
)
func (l *Login) handleLogoutDone(w http.ResponseWriter, r *http.Request) {
l.renderLogoutDone(w, r)
}
func (l *Login) renderLogoutDone(w http.ResponseWriter, r *http.Request) {
data := userData{
baseData: l.getBaseData(r, nil, "Logout Done", "", ""),
}
l.renderer.RenderTemplate(w, r, l.renderer.Templates[tmplLogoutDone], data, nil)
}
@@ -0,0 +1,91 @@
package handler
import (
"net/http"
"github.com/caos/zitadel/internal/auth_request/model"
)
const (
queryCode = "code"
queryUserID = "userID"
tmplMailVerification = "mail_verification"
tmplMailVerified = "mail_verified"
)
type mailVerificationFormData struct {
Code string `schema:"code"`
UserID string `schema:"userID"`
Resend bool `schema:"resend"`
}
type mailVerificationData struct {
baseData
UserID string
}
func (l *Login) handleMailVerification(w http.ResponseWriter, r *http.Request) {
userID := r.FormValue(queryUserID)
code := r.FormValue(queryCode)
if code != "" {
l.checkMailCode(w, r, nil, userID, code)
return
}
l.renderMailVerification(w, r, nil, userID, nil)
}
func (l *Login) handleMailVerificationCheck(w http.ResponseWriter, r *http.Request) {
data := new(mailVerificationFormData)
authReq, err := l.getAuthRequestAndParseData(r, data)
if err != nil {
l.renderError(w, r, authReq, err)
return
}
if !data.Resend {
l.checkMailCode(w, r, authReq, data.UserID, data.Code)
return
}
userOrg := login
if authReq != nil {
userOrg = authReq.UserOrgID
}
err = l.authRepo.ResendEmailVerificationMail(setContext(r.Context(), userOrg), data.UserID)
l.renderMailVerification(w, r, authReq, data.UserID, err)
}
func (l *Login) checkMailCode(w http.ResponseWriter, r *http.Request, authReq *model.AuthRequest, userID, code string) {
userOrg := login
if authReq != nil {
userID = authReq.UserID
userOrg = authReq.UserOrgID
}
err := l.authRepo.VerifyEmail(setContext(r.Context(), userOrg), userID, code)
if err != nil {
l.renderMailVerification(w, r, authReq, userID, err)
return
}
l.renderMailVerified(w, r, authReq)
}
func (l *Login) renderMailVerification(w http.ResponseWriter, r *http.Request, authReq *model.AuthRequest, userID string, err error) {
var errType, errMessage string
if err != nil {
errMessage = l.getErrorMessage(r, err)
}
if userID == "" {
userID = authReq.UserID
}
data := mailVerificationData{
baseData: l.getBaseData(r, authReq, "Mail Verification", errType, errMessage),
UserID: userID,
}
l.renderer.RenderTemplate(w, r, l.renderer.Templates[tmplMailVerification], data, nil)
}
func (l *Login) renderMailVerified(w http.ResponseWriter, r *http.Request, authReq *model.AuthRequest) {
data := mailVerificationData{
baseData: l.getBaseData(r, authReq, "Mail Verified", "", ""),
}
l.renderer.RenderTemplate(w, r, l.renderer.Templates[tmplMailVerified], data, nil)
}
@@ -0,0 +1,21 @@
package handler
import (
"net/http"
"github.com/caos/zitadel/internal/auth_request/model"
)
const (
tmplMfaInitDone = "mfainitdone"
)
type mfaInitDoneData struct {
}
func (l *Login) renderMfaInitDone(w http.ResponseWriter, r *http.Request, authReq *model.AuthRequest, data *mfaDoneData) {
var errType, errMessage string
data.baseData = l.getBaseData(r, authReq, "Mfa Init Done", errType, errMessage)
data.LoginName = authReq.LoginName
l.renderer.RenderTemplate(w, r, l.renderer.Templates[tmplMfaInitDone], data, nil)
}
@@ -0,0 +1,96 @@
package handler
import (
"bytes"
"net/http"
svg "github.com/ajstarks/svgo"
"github.com/boombuler/barcode/qr"
"github.com/caos/zitadel/internal/auth_request/model"
"github.com/caos/zitadel/internal/qrcode"
)
const (
tmplMfaInitVerify = "mfainitverify"
)
type mfaInitVerifyData struct {
MfaType model.MfaType `schema:"mfaType"`
Code string `schema:"code"`
URL string `schema:"url"`
Secret string `schema:"secret"`
}
func (l *Login) handleMfaInitVerify(w http.ResponseWriter, r *http.Request) {
data := new(mfaInitVerifyData)
authReq, err := l.getAuthRequestAndParseData(r, data)
if err != nil {
l.renderError(w, r, authReq, err)
return
}
var verifyData *mfaVerifyData
switch data.MfaType {
case model.MfaTypeOTP:
verifyData = l.handleOtpVerify(w, r, authReq, data)
}
if verifyData != nil {
l.renderMfaInitVerify(w, r, authReq, verifyData, err)
return
}
done := &mfaDoneData{
MfaType: data.MfaType,
}
l.renderMfaInitDone(w, r, authReq, done)
}
func (l *Login) handleOtpVerify(w http.ResponseWriter, r *http.Request, authReq *model.AuthRequest, data *mfaInitVerifyData) *mfaVerifyData {
err := l.authRepo.VerifyMfaOTPSetup(setContext(r.Context(), authReq.UserOrgID), authReq.UserID, data.Code)
if err == nil {
return nil
}
mfadata := &mfaVerifyData{
MfaType: data.MfaType,
otpData: otpData{
Secret: data.Secret,
Url: data.URL,
},
}
return mfadata
}
func (l *Login) renderMfaInitVerify(w http.ResponseWriter, r *http.Request, authReq *model.AuthRequest, data *mfaVerifyData, err error) {
var errType, errMessage string
if err != nil {
errMessage = l.getErrorMessage(r, err)
}
data.baseData = l.getBaseData(r, authReq, "Mfa Init Verify", errType, errMessage)
data.LoginName = authReq.LoginName
if data.MfaType == model.MfaTypeOTP {
code, err := generateQrCode(data.otpData.Url)
if err == nil {
data.otpData.QrCode = code
}
}
l.renderer.RenderTemplate(w, r, l.renderer.Templates[tmplMfaInitVerify], data, nil)
}
func generateQrCode(url string) (string, error) {
var b bytes.Buffer
s := svg.New(&b)
qrCode, err := qr.Encode(url, qr.M, qr.Auto)
if err != nil {
return "", err
}
qs := qrcode.NewQrSVG(qrCode, 5)
qs.StartQrSVG(s)
qs.WriteQrSVG(s)
s.End()
return string(b.Bytes()), nil
}
@@ -0,0 +1,89 @@
package handler
import (
"net/http"
"github.com/caos/zitadel/internal/auth_request/model"
caos_errs "github.com/caos/zitadel/internal/errors"
)
const (
tmplMfaPrompt = "mfaprompt"
)
type mfaPromptData struct {
MfaProvider model.MfaType `schema:"provider"`
Skip bool `schema:"skip"`
}
func (l *Login) handleMfaPrompt(w http.ResponseWriter, r *http.Request) {
data := new(mfaPromptData)
authSession, err := l.getAuthRequestAndParseData(r, data)
if err != nil {
l.renderError(w, r, authSession, err)
return
}
if !data.Skip {
mfaVerifyData := new(mfaVerifyData)
mfaVerifyData.MfaType = data.MfaProvider
l.handleMfaCreation(w, r, authSession, mfaVerifyData)
return
}
err = l.authRepo.SkipMfaInit(setContext(r.Context(), authSession.UserOrgID), authSession.UserID)
if err != nil {
l.renderError(w, r, authSession, err)
return
}
l.handleLogin(w, r)
}
func (l *Login) renderMfaPrompt(w http.ResponseWriter, r *http.Request, authSession *model.AuthRequest, mfaPromptData *model.MfaPromptStep, err error) {
var errType, errMessage string
if err != nil {
errMessage = l.getErrorMessage(r, err)
}
data := mfaData{
baseData: l.getBaseData(r, authSession, "Mfa Prompt", errType, errMessage),
LoginName: authSession.LoginName,
}
if mfaPromptData == nil {
l.renderError(w, r, authSession, caos_errs.ThrowPreconditionFailed(nil, "APP-XU0tj", "Errors.User.Mfa.NoProviders"))
return
}
data.MfaProviders = mfaPromptData.MfaProviders
data.MfaRequired = mfaPromptData.Required
if len(mfaPromptData.MfaProviders) == 1 && mfaPromptData.Required {
data := &mfaVerifyData{
MfaType: mfaPromptData.MfaProviders[0],
}
l.handleMfaCreation(w, r, authSession, data)
return
}
l.renderer.RenderTemplate(w, r, l.renderer.Templates[tmplMfaPrompt], data, nil)
}
func (l *Login) handleMfaCreation(w http.ResponseWriter, r *http.Request, authSession *model.AuthRequest, data *mfaVerifyData) {
switch data.MfaType {
case model.MfaTypeOTP:
l.handleOtpCreation(w, r, authSession, data)
return
}
l.renderError(w, r, authSession, caos_errs.ThrowPreconditionFailed(nil, "APP-Or3HO", "Errors.User.Mfa.NoProviders"))
}
func (l *Login) handleOtpCreation(w http.ResponseWriter, r *http.Request, authReq *model.AuthRequest, data *mfaVerifyData) {
otp, err := l.authRepo.AddMfaOTP(setContext(r.Context(), authReq.UserOrgID), authReq.UserID)
if err != nil {
l.renderError(w, r, authReq, err)
return
}
data.otpData = otpData{
Secret: otp.SecretString,
Url: otp.Url,
}
l.renderMfaInitVerify(w, r, authReq, data, nil)
}
@@ -0,0 +1,49 @@
package handler
import (
"net/http"
"github.com/caos/zitadel/internal/auth_request/model"
)
const (
tmplMfaVerify = "mfaverify"
)
type mfaVerifyFormData struct {
MfaType model.MfaType `schema:"mfaType"`
Code string `schema:"code"`
}
func (l *Login) handleMfaVerify(w http.ResponseWriter, r *http.Request) {
data := new(mfaVerifyFormData)
authReq, err := l.getAuthRequestAndParseData(r, data)
if err != nil {
l.renderError(w, r, authReq, err)
return
}
if data.MfaType == model.MfaTypeOTP {
err = l.authRepo.VerifyMfaOTP(setContext(r.Context(), authReq.UserOrgID), authReq.ID, authReq.UserID, data.Code, model.BrowserInfoFromRequest(r))
}
if err != nil {
l.renderError(w, r, authReq, err)
return
}
l.renderNextStep(w, r, authReq)
}
func (l *Login) renderMfaVerify(w http.ResponseWriter, r *http.Request, authReq *model.AuthRequest, verificationStep *model.MfaVerificationStep, err error) {
var errType, errMessage string
if err != nil {
errMessage = l.getErrorMessage(r, err)
}
data := userData{
baseData: l.getBaseData(r, authReq, "Mfa Verify", errType, errMessage),
LoginName: authReq.LoginName,
}
if verificationStep != nil {
data.MfaProviders = verificationStep.MfaProviders
data.SelectedMfaProvider = verificationStep.MfaProviders[0]
}
l.renderer.RenderTemplate(w, r, l.renderer.Templates[tmplMfaVerify], data, nil)
}
@@ -0,0 +1,42 @@
package handler
import (
"net/http"
"github.com/caos/zitadel/internal/auth_request/model"
)
const (
tmplPassword = "password"
)
type passwordData struct {
Password string `schema:"password"`
}
func (l *Login) renderPassword(w http.ResponseWriter, r *http.Request, authReq *model.AuthRequest, err error) {
var errType, errMessage string
if err != nil {
errMessage = l.getErrorMessage(r, err)
}
data := userData{
baseData: l.getBaseData(r, authReq, "Password", errType, errMessage),
LoginName: authReq.LoginName,
}
l.renderer.RenderTemplate(w, r, l.renderer.Templates[tmplPassword], data, nil)
}
func (l *Login) handlePasswordCheck(w http.ResponseWriter, r *http.Request) {
data := new(passwordData)
authReq, err := l.getAuthRequestAndParseData(r, data)
if err != nil {
l.renderError(w, r, authReq, err)
return
}
err = l.authRepo.VerifyPassword(setContext(r.Context(), authReq.UserOrgID), authReq.ID, authReq.UserID, data.Password, model.BrowserInfoFromRequest(r))
if err != nil {
l.renderPassword(w, r, authReq, err)
return
}
l.renderNextStep(w, r, authReq)
}
@@ -0,0 +1,33 @@
package handler
import (
"net/http"
"github.com/caos/zitadel/internal/auth_request/model"
)
const (
tmplPasswordResetDone = "passwordresetdone"
)
func (l *Login) handlePasswordReset(w http.ResponseWriter, r *http.Request) {
authReq, err := l.getAuthRequest(r)
if err != nil {
l.renderError(w, r, authReq, err)
return
}
err = l.authRepo.RequestPasswordReset(setContext(r.Context(), authReq.UserOrgID), authReq.LoginName)
l.renderPasswordResetDone(w, r, authReq, err)
}
func (l *Login) renderPasswordResetDone(w http.ResponseWriter, r *http.Request, authReq *model.AuthRequest, err error) {
var errType, errMessage string
if err != nil {
errMessage = l.getErrorMessage(r, err)
}
data := userData{
baseData: l.getBaseData(r, authReq, "Password Reset Done", errType, errMessage),
LoginName: authReq.LoginName,
}
l.renderer.RenderTemplate(w, r, l.renderer.Templates[tmplPasswordResetDone], data, nil)
}
@@ -0,0 +1,127 @@
package handler
import (
"net/http"
"golang.org/x/text/language"
"github.com/caos/zitadel/internal/auth_request/model"
caos_errs "github.com/caos/zitadel/internal/errors"
"github.com/caos/zitadel/internal/eventstore/models"
org_model "github.com/caos/zitadel/internal/org/model"
usr_model "github.com/caos/zitadel/internal/user/model"
)
const (
tmplRegister = "register"
orgProjectCreatorRole = "ORG_PROJECT_CREATOR"
)
type registerFormData struct {
Email string `schema:"email"`
Firstname string `schema:"firstname"`
Lastname string `schema:"lastname"`
Language string `schema:"language"`
Gender int32 `schema:"gender"`
Password string `schema:"password"`
Password2 string `schema:"password2"`
}
type registerData struct {
baseData
registerFormData
}
func (l *Login) handleRegister(w http.ResponseWriter, r *http.Request) {
data := new(registerFormData)
authRequest, err := l.getAuthRequestAndParseData(r, data)
if err != nil {
l.renderError(w, r, authRequest, err)
return
}
l.renderRegister(w, r, authRequest, data, nil)
}
func (l *Login) handleRegisterCheck(w http.ResponseWriter, r *http.Request) {
data := new(registerFormData)
authRequest, err := l.getAuthRequestAndParseData(r, data)
if err != nil {
l.renderError(w, r, authRequest, err)
return
}
if data.Password != data.Password2 {
err := caos_errs.ThrowInvalidArgument(nil, "VIEW-KaGue", "Errors.User.Password.ConfirmationWrong")
l.renderRegister(w, r, authRequest, data, err)
return
}
iam, err := l.authRepo.GetIam(r.Context())
if err != nil {
l.renderRegister(w, r, authRequest, data, err)
return
}
member := &org_model.OrgMember{
ObjectRoot: models.ObjectRoot{AggregateID: iam.GlobalOrgID},
Roles: []string{orgProjectCreatorRole},
}
user, err := l.authRepo.Register(setContext(r.Context(), iam.GlobalOrgID), data.toUserModel(), member, iam.GlobalOrgID)
if err != nil {
l.renderRegister(w, r, authRequest, data, err)
return
}
if authRequest == nil {
http.Redirect(w, r, l.zitadelURL, http.StatusFound)
return
}
authRequest.LoginName = user.PreferredLoginName
l.renderNextStep(w, r, authRequest)
}
func (l *Login) renderRegister(w http.ResponseWriter, r *http.Request, authRequest *model.AuthRequest, formData *registerFormData, err error) {
var errType, errMessage string
if err != nil {
errMessage = l.getErrorMessage(r, err)
}
if formData == nil {
formData = new(registerFormData)
}
if formData.Language == "" {
formData.Language = l.renderer.Lang(r).String()
}
data := registerData{
baseData: l.getBaseData(r, authRequest, "Register", errType, errMessage),
registerFormData: *formData,
}
funcs := map[string]interface{}{
"selectedLanguage": func(l string) bool {
if formData == nil {
return false
}
return formData.Language == l
},
"selectedGender": func(g int32) bool {
if formData == nil {
return false
}
return formData.Gender == g
},
}
l.renderer.RenderTemplate(w, r, l.renderer.Templates[tmplRegister], data, funcs)
}
func (d registerFormData) toUserModel() *usr_model.User {
return &usr_model.User{
Profile: &usr_model.Profile{
FirstName: d.Firstname,
LastName: d.Lastname,
PreferredLanguage: language.Make(d.Language),
Gender: usr_model.Gender(d.Gender),
},
Password: &usr_model.Password{
SecretString: d.Password,
},
Email: &usr_model.Email{
EmailAddress: d.Email,
},
}
}
+296
View File
@@ -0,0 +1,296 @@
package handler
import (
"errors"
"fmt"
"html/template"
"net/http"
"path"
"github.com/gorilla/csrf"
"github.com/caos/zitadel/internal/api/http/middleware"
"github.com/caos/zitadel/internal/auth_request/model"
caos_errs "github.com/caos/zitadel/internal/errors"
"github.com/caos/zitadel/internal/i18n"
"github.com/caos/zitadel/internal/renderer"
"github.com/caos/logging"
"golang.org/x/text/language"
)
const (
tmplError = "error"
)
type Renderer struct {
*renderer.Renderer
pathPrefix string
}
func CreateRenderer(pathPrefix string, staticDir http.FileSystem, cookieName string, defaultLanguage language.Tag) *Renderer {
r := &Renderer{
pathPrefix: pathPrefix,
}
tmplMapping := map[string]string{
tmplError: "error.html",
tmplLogin: "login.html",
tmplUserSelection: "select_user.html",
tmplPassword: "password.html",
tmplMfaVerify: "mfa_verify.html",
tmplMfaPrompt: "mfa_prompt.html",
tmplMfaInitVerify: "mfa_init_verify.html",
tmplMfaInitDone: "mfa_init_done.html",
tmplMailVerification: "mail_verification.html",
tmplMailVerified: "mail_verified.html",
tmplInitPassword: "init_password.html",
tmplInitPasswordDone: "init_password_done.html",
tmplInitUser: "init_user.html",
tmplInitUserDone: "init_user_done.html",
tmplPasswordResetDone: "password_reset_done.html",
tmplChangePassword: "change_password.html",
tmplChangePasswordDone: "change_password_done.html",
tmplRegister: "register.html",
tmplLogoutDone: "logout_done.html",
}
funcs := map[string]interface{}{
"resourceUrl": func(file string) string {
return path.Join(r.pathPrefix, EndpointResources, file)
},
"resourceThemeUrl": func(file, theme string) string {
return path.Join(r.pathPrefix, EndpointResources, "themes", theme, file)
},
"loginUrl": func() string {
return path.Join(r.pathPrefix, EndpointLogin)
},
"registerUrl": func(id string) string {
return path.Join(r.pathPrefix, fmt.Sprintf("%s?%s=%s", EndpointRegister, queryAuthRequestID, id))
},
"loginNameUrl": func() string {
return path.Join(r.pathPrefix, EndpointLoginName)
},
"loginNameChangeUrl": func(id string) string {
return path.Join(r.pathPrefix, fmt.Sprintf("%s?%s=%s", EndpointLoginName, queryAuthRequestID, id))
},
"userSelectionUrl": func() string {
return path.Join(r.pathPrefix, EndpointUserSelection)
},
"passwordResetUrl": func(id string) string {
return path.Join(r.pathPrefix, fmt.Sprintf("%s?%s=%s", EndpointPasswordReset, queryAuthRequestID, id))
},
"passwordUrl": func() string {
return path.Join(r.pathPrefix, EndpointPassword)
},
"mfaVerifyUrl": func() string {
return path.Join(r.pathPrefix, EndpointMfaVerify)
},
"mfaPromptUrl": func() string {
return path.Join(r.pathPrefix, EndpointMfaPrompt)
},
"mfaInitVerifyUrl": func() string {
return path.Join(r.pathPrefix, EndpointMfaInitVerify)
},
"mailVerificationUrl": func() string {
return path.Join(r.pathPrefix, EndpointMailVerification)
},
"initPasswordUrl": func() string {
return path.Join(r.pathPrefix, EndpointInitPassword)
},
"initUserUrl": func() string {
return path.Join(r.pathPrefix, EndpointInitUser)
},
"changePasswordUrl": func() string {
return path.Join(r.pathPrefix, EndpointChangePassword)
},
"registrationUrl": func() string {
return path.Join(r.pathPrefix, EndpointRegister)
},
"selectedLanguage": func(l string) bool {
return false
},
"selectedGender": func(g int32) bool {
return false
},
}
var err error
r.Renderer, err = renderer.NewRenderer(
staticDir,
tmplMapping, funcs,
i18n.TranslatorConfig{DefaultLanguage: defaultLanguage, CookieName: cookieName},
)
logging.Log("APP-40tSoJ").OnError(err).WithError(err).Panic("error creating renderer")
return r
}
func (l *Login) renderNextStep(w http.ResponseWriter, r *http.Request, authReq *model.AuthRequest) {
authReq, err := l.authRepo.AuthRequestByID(r.Context(), authReq.ID)
if err != nil {
l.renderInternalError(w, r, authReq, caos_errs.ThrowInternal(nil, "APP-sio0W", "could not get authreq"))
}
if len(authReq.PossibleSteps) == 0 {
l.renderInternalError(w, r, authReq, caos_errs.ThrowInternal(nil, "APP-9sdp4", "no possible steps"))
return
}
l.chooseNextStep(w, r, authReq, 0, nil)
}
func (l *Login) renderError(w http.ResponseWriter, r *http.Request, authReq *model.AuthRequest, err error) {
if authReq == nil || len(authReq.PossibleSteps) == 0 {
l.renderInternalError(w, r, authReq, caos_errs.ThrowInternal(err, "APP-OVOiT", "no possible steps"))
return
}
l.chooseNextStep(w, r, authReq, 0, err)
}
func (l *Login) chooseNextStep(w http.ResponseWriter, r *http.Request, authReq *model.AuthRequest, stepNumber int, err error) {
switch step := authReq.PossibleSteps[stepNumber].(type) {
case *model.LoginStep:
if len(authReq.PossibleSteps) > 1 {
l.chooseNextStep(w, r, authReq, 1, err)
return
}
l.renderLogin(w, r, authReq, err)
case *model.SelectUserStep:
l.renderUserSelection(w, r, authReq, step)
case *model.InitPasswordStep:
l.renderInitPassword(w, r, authReq, authReq.UserID, "", err)
case *model.PasswordStep:
l.renderPassword(w, r, authReq, nil)
case *model.MfaVerificationStep:
l.renderMfaVerify(w, r, authReq, step, err)
case *model.RedirectToCallbackStep:
if len(authReq.PossibleSteps) > 1 {
l.chooseNextStep(w, r, authReq, 1, err)
return
}
l.redirectToCallback(w, r, authReq)
case *model.ChangePasswordStep:
l.renderChangePassword(w, r, authReq, err)
case *model.VerifyEMailStep:
l.renderMailVerification(w, r, authReq, "", err)
case *model.MfaPromptStep:
l.renderMfaPrompt(w, r, authReq, step, err)
case *model.InitUserStep:
l.renderInitUser(w, r, authReq, "", "", step.PasswordSet, nil)
default:
l.renderInternalError(w, r, authReq, caos_errs.ThrowInternal(nil, "APP-ds3QF", "step no possible"))
}
}
func (l *Login) renderInternalError(w http.ResponseWriter, r *http.Request, authReq *model.AuthRequest, err error) {
var msg string
if err != nil {
msg = err.Error()
}
data := l.getBaseData(r, authReq, "Error", "Internal", msg)
l.renderer.RenderTemplate(w, r, l.renderer.Templates[tmplError], data, nil)
}
func (l *Login) getBaseData(r *http.Request, authReq *model.AuthRequest, title string, errType, errMessage string) baseData {
return baseData{
errorData: errorData{
ErrType: errType,
ErrMessage: errMessage,
},
Lang: l.renderer.Lang(r).String(),
Title: title,
Theme: l.getTheme(r),
ThemeMode: l.getThemeMode(r),
AuthReqID: getRequestID(authReq, r),
CSRF: csrf.TemplateField(r),
Nonce: middleware.GetNonce(r),
}
}
func (l *Login) getErrorMessage(r *http.Request, err error) (errMsg string) {
caosErr := new(caos_errs.CaosError)
if errors.As(err, &caosErr) {
localized := l.renderer.LocalizeFromRequest(r, caosErr.Message, nil)
return localized + " (" + caosErr.ID + ")"
}
return err.Error()
}
func (l *Login) getTheme(r *http.Request) string {
return "zitadel" //TODO: impl
}
func (l *Login) getThemeMode(r *http.Request) string {
return "" //TODO: impl
}
func getRequestID(authReq *model.AuthRequest, r *http.Request) string {
if authReq != nil {
return authReq.ID
}
return r.FormValue(queryAuthRequestID)
}
func (l *Login) csrfErrorHandler() http.Handler {
return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
err := csrf.FailureReason(r)
l.renderInternalError(w, r, nil, err)
})
}
func (l *Login) cspErrorHandler(err error) http.Handler {
return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
l.renderInternalError(w, r, nil, err)
})
}
type baseData struct {
errorData
Lang string
Title string
Theme string
ThemeMode string
AuthReqID string
CSRF template.HTML
Nonce string
}
type errorData struct {
ErrType string
ErrMessage string
}
type userData struct {
baseData
LoginName string
PasswordChecked string
MfaProviders []model.MfaType
SelectedMfaProvider model.MfaType
}
type userSelectionData struct {
baseData
Users []model.UserSelection
}
type mfaData struct {
baseData
LoginName string
MfaProviders []model.MfaType
MfaRequired bool
}
type mfaVerifyData struct {
baseData
LoginName string
MfaType model.MfaType
otpData
}
type mfaDoneData struct {
baseData
LoginName string
MfaType model.MfaType
}
type otpData struct {
Url string
Secret string
QrCode string
}
@@ -0,0 +1,9 @@
package handler
import (
"net/http"
)
func (l *Login) handleResources(staticDir http.FileSystem) http.Handler {
return http.FileServer(staticDir)
}
+59
View File
@@ -0,0 +1,59 @@
package handler
import (
"net/http"
"github.com/gorilla/mux"
)
const (
EndpointRoot = "/"
EndpointHealthz = "/healthz"
EndpointReadiness = "/ready"
EndpointLogin = "/login"
EndpointLoginName = "/loginname"
EndpointUserSelection = "/userselection"
EndpointPassword = "/password"
EndpointInitPassword = "/password/init"
EndpointChangePassword = "/password/change"
EndpointPasswordReset = "/password/reset"
EndpointInitUser = "/user/init"
EndpointMfaVerify = "/mfa/verify"
EndpointMfaPrompt = "/mfa/prompt"
EndpointMfaInitVerify = "/mfa/init/verify"
EndpointMailVerification = "/mail/verification"
EndpointMailVerified = "/mail/verified"
EndpointRegister = "/register"
EndpointLogoutDone = "/logout/done"
EndpointResources = "/resources"
)
func CreateRouter(login *Login, staticDir http.FileSystem, interceptors ...mux.MiddlewareFunc) *mux.Router {
router := mux.NewRouter()
router.Use(interceptors...)
router.HandleFunc(EndpointRoot, login.handleLogin).Methods(http.MethodGet)
router.HandleFunc(EndpointHealthz, login.handleHealthz).Methods(http.MethodGet)
router.HandleFunc(EndpointReadiness, login.handleReadiness).Methods(http.MethodGet)
router.HandleFunc(EndpointLogin, login.handleLogin).Methods(http.MethodGet, http.MethodPost)
router.HandleFunc(EndpointLoginName, login.handleLoginName).Methods(http.MethodGet)
router.HandleFunc(EndpointLoginName, login.handleLoginNameCheck).Methods(http.MethodPost)
router.HandleFunc(EndpointUserSelection, login.handleSelectUser).Methods(http.MethodPost)
router.HandleFunc(EndpointPassword, login.handlePasswordCheck).Methods(http.MethodPost)
router.HandleFunc(EndpointInitPassword, login.handleInitPassword).Methods(http.MethodGet)
router.HandleFunc(EndpointInitPassword, login.handleInitPasswordCheck).Methods(http.MethodPost)
router.HandleFunc(EndpointPasswordReset, login.handlePasswordReset).Methods(http.MethodGet)
router.HandleFunc(EndpointInitUser, login.handleInitUser).Methods(http.MethodGet)
router.HandleFunc(EndpointInitUser, login.handleInitUserCheck).Methods(http.MethodPost)
router.HandleFunc(EndpointMfaVerify, login.handleMfaVerify).Methods(http.MethodPost)
router.HandleFunc(EndpointMfaPrompt, login.handleMfaPrompt).Methods(http.MethodPost)
router.HandleFunc(EndpointMfaInitVerify, login.handleMfaInitVerify).Methods(http.MethodPost)
router.HandleFunc(EndpointMailVerification, login.handleMailVerification).Methods(http.MethodGet)
router.HandleFunc(EndpointMailVerification, login.handleMailVerificationCheck).Methods(http.MethodPost)
router.HandleFunc(EndpointChangePassword, login.handleChangePassword).Methods(http.MethodPost)
router.HandleFunc(EndpointRegister, login.handleRegister).Methods(http.MethodGet)
router.HandleFunc(EndpointRegister, login.handleRegisterCheck).Methods(http.MethodPost)
router.HandleFunc(EndpointLogoutDone, login.handleLogoutDone).Methods(http.MethodGet)
router.PathPrefix(EndpointResources).Handler(login.handleResources(staticDir)).Methods(http.MethodGet)
return router
}
@@ -0,0 +1,42 @@
package handler
import (
"net/http"
"github.com/caos/zitadel/internal/auth_request/model"
)
const (
tmplUserSelection = "userselection"
)
type userSelectionFormData struct {
UserID string `schema:"userID"`
}
func (l *Login) renderUserSelection(w http.ResponseWriter, r *http.Request, authReq *model.AuthRequest, selectionData *model.SelectUserStep) {
data := userSelectionData{
baseData: l.getBaseData(r, authReq, "Select User", "", ""),
Users: selectionData.Users,
}
l.renderer.RenderTemplate(w, r, l.renderer.Templates[tmplUserSelection], data, nil)
}
func (l *Login) handleSelectUser(w http.ResponseWriter, r *http.Request) {
data := new(userSelectionFormData)
authSession, err := l.getAuthRequestAndParseData(r, data)
if err != nil {
l.renderError(w, r, authSession, err)
return
}
if data.UserID == "0" {
l.renderLogin(w, r, authSession, nil)
return
}
err = l.authRepo.SelectUser(r.Context(), authSession.ID, data.UserID)
if err != nil {
l.renderError(w, r, authSession, err)
return
}
l.renderNextStep(w, r, authSession)
}
+14
View File
@@ -0,0 +1,14 @@
package login
import (
"github.com/caos/zitadel/internal/auth/repository/eventsourcing"
"github.com/caos/zitadel/internal/ui/login/handler"
)
type Config struct {
Handler handler.Config
}
func Start(config Config, authRepo *eventsourcing.EsRepository, pathPrefix string) *handler.Login {
return handler.CreateLogin(config.Handler, authRepo, pathPrefix)
}
+159
View File
@@ -0,0 +1,159 @@
Password:
Title: Passwort
Description: Gib deine Benutzerdaten ein.
Password: Passwort
Login:
Title: Anmeldung
Description: Gib deine Benutzerdaten ein.
Loginname: Loginname
LoginnamePlaceHolder: username@domain
UserSelection:
Title: Account auswählen
Description: Wähle deinen Account aus.
OtherUser: Anderer Benutzer
SessionState0: aktiv
SessionState1: inaktiv
MfaVerify:
Title: Multifaktor verifizieren
Description: Verifiziere deinen Multifaktor
OTP: OTP
Code: Code
InitPassword:
Title: Passwort setzen
Description: Du hast einen Code erhalten, welcher im untenstehenden Formular eingegeben werden muss um ein neues Passwort zu setzen.
Code: Code
NewPassword: Neues Passwort
NewPasswordConfirm: Passwort bestätigen
InitPasswordDone:
Title: Passwort gesetzt
Description: Passwort erfolgreich gesetzt
InitUser:
Title: User aktivieren
Description: Du hast einen Code erhalten, welcher im untenstehenden Formular eingegeben werden muss um deine EMail zu verifizieren und ein neues Passwort zu setzen.
Code: Code
NewPassword: Neues Passwort
NewPasswordConfirm: Passwort bestätigen
InitUserDone:
Title: User aktiviert
Description: EMail verifiziert und Passwort erfolgreich gesetzt
MfaPrompt:
Title: Multifaktor hinzufügen
Description: Möchtest du einen Mulitfaktor hinzufügen?
Provider0: OTP
Provider1: SMS
MfaInitVerify:
Title: Multifaktor Verifizierung
Description: Verifiziere deinen Multifaktor
OtpDescription: Scanne den Code mit einem Authentifizierungs-App (z.B Google Authentificator) oder kopiere das Secret und gib anschliessend den Code ein.
Secret: Secret
Code: Code
MfaInitDone:
Title: Multifaktor Verifizierung erstellt
Description: Multifikator Verifizierung erfolgreich abgeschlossen. Der Multifaktor muss bei jeder Anmeldung eingegeben werden, dies beinhaltet auch den aktuellen Authentifizierungs Prozess.
PasswordChange:
Title: Passwort ändern
Description: Ändere dein Password in dem du dein altes und dann dein neuen Passwort eingibst.
OldPassword: Altes Passwort
NewPassword: Neues Passwort
PasswordChangeDone:
Title: Passwort ändern
Description: Das Passwort wurde erfolgreich geändert.
PasswordResetDone:
Title: Resetlink versendet
Description: Prüfe dein E-Mail Postfach, um ein neues Passwort zu setzen.
PasswordSetDone:
Title: Passwort gesetzt
Description: Das Passwort wurde erfolgreich gesetzt.
EmailVerification:
Title: E-Mail Verifizierung
Description: Du hast ein E-Mail zur Verifizierung deiner E-Mail Adresse bekommen. Gib den Code im untenstehenden Formular ein. Mit erneut versenden, wird dir ein neues E-Mail zugestellt.
Code: Code
EmailVerificationDone:
Title: E-Mail Verifizierung
Description: Deine E-Mail Adresse wurde erfolgreich verifiziert.
Registration:
Title: Registration
Description: Gib deine Benutzerangaben an. Die E-Mail Adresse wird als Benutzernamen verwendet.
Email: E-Mail
Firstname: Vorname
Lastname: Nachname
Language: Sprache
German: Deutsch
English: English
Gender: Geschlecht
Female: weiblich
Male: männlich
Diverse: diverse
Password: Passwort
Password2: Passwort wiederholen
LogoutDone:
Title: Ausgeloggt
Description: Du wurdest erfolgreich ausgeloggt.
Actions:
Login: anmelden
Next: weiter
Back: zurück
Resend: erneut senden
Skip: überspringen
Register: registrieren
ForgotPassword: Password zurücksetzen
Errors:
Internal: Es ist ein interner Fehler aufgetreten
AuthRequest:
NotFound: AuthRequest konnte nicht gefunden werden
User:
NotFound: Benutzer konnte nicht gefunden werden
NotMatchingUserID: User stimm nicht mit User in Auth Request überein
UserIDMissing: UserID ist leer
Invalid: Userdaten sind ungültig
Password:
ConfirmationWrong: Passwort Bestätigung stimmt nicht überein
Empty: Passwort ist leer
Invalid: Passwort ungültig
PasswordComplexityPolicy:
NotFound: Passwort Policy konnte nicht gefunden werden
MinLength: Passwort ist zu kurz
HasLower: Passwort beinhaltet keinen klein Buchstaben
HasUpper: Passwort beinhaltet keinen gross Buchstaben
HasNumber: Passwort beinhaltet keine Nummer
HasSymbol: Passwort beinhaltet kein Symbol
Code:
Expired: Code ist abgelaufen
Invalid: Code ist ungültig
Empty: Code ist leer
CryptoCodeNil: Crypto Code ist nil
NotFound: Code konnte nicht gefunden werden
GeneratorAlgNotSupported: Generator Algorithums wird nicht unterstützt
EmailVerify:
UserIDEmpty: UserID ist leer
Mfa:
NoProviders: Es stehen keine Multifaktorprovider zur Verfügung
Otp:
AlreadyReady: Multifaktor OTP (OneTimePassword) ist bereits eingerichtet
NotExisting: Multifaktor OTP (OneTimePassword) existiert nicht
InvalidCode: Code ist ungültig
NotReady: Multifaktor OTP (OneTimePassword) ist nicht bereit
Locked: Benutzer ist gesperrt
NotActive: Benutzer ist nicht aktiv
optional: (optional)
+161
View File
@@ -0,0 +1,161 @@
Login:
Title: Login
Description: Enter your logindata.
Loginname: Loginname
LoginnamePlaceHolder: username@domain
UserSelection:
Title: Select account
Description: Select your account.
OtherUser: Other User
SessionState0: active
SessionState1: inactive
Password:
Title: Password
Description: Enter your logindata.
Password: Password
MfaVerify:
Title: Verify Multificator
Description: Verify your multifactor
OTP: OTP
Code: Code
InitPassword:
Title: Set Password
Description: You have received a code, which you have to enter in the form below, to set your new password.
Code: Code
NewPassword: New Password
NewPasswordConfirm: Confirm Password
InitPasswordDone:
Title: Passwortd set
Description: Password successfully set
InitUser:
Title: Activate User
Description: You have received a code, which you have to enter in the form below, to verify your email and set your new password.
Code: Code
NewPassword: New Password
NewPasswordConfirm: Confirm Password
InitUserDone:
Title: User activated
Description: Email verified and Password successfully set
MfaPrompt:
Title: Multifactor Setup
Description: Would you like to setup multifactor authentication?
Provider0: OTP
Provider1: SMS
MfaInitVerify:
Title: Multifactor Verification
Description: Verify your multifactor.
OtpDescription: Scan the code with your authenticator app (e.g Google-Authenticator) or copy the secret and insert the generated code below.
Secret: Secret
Code: Code
MfaInitDone:
Title: Multifcator Verification done
Description: Multifactor verification successfully done. The multifactor has to be entered on each login, even in the actual authentification process.
PasswordChange:
Title: Change Password
Description: Change your password. Enter your old and new password.
OldPassword: Old Password
NewPassword: New Password
PasswordChangeDone:
Title: Change Password
Description: Your password was changed successfully.
PasswordResetDone:
Title: Reset link set
Description: Check your email to to reset your password.
PasswordSetDone:
Title: Password set
Description: Your password was set successfully.
EmailVerification:
Title: E-Mail Verification
Description: We have sent you an email to verify your address. Please enter the code in the form below.
Code: Code
EmailVerificationDone:
Title: E-Mail Verification
Description: Your email address has been successfully verified.
Registration:
Title: Registration
Description: Enter your Userdata. Your email address will be used as loginname.
Email: E-Mail
Firstname: Firstname
Lastname: Lastname
Language: Language
German: Deutsch
English: English
Gender: Gender
Female: Female
Male: Male
Diverse: diverse / X
Password: Password
Password2: Password confirmation
LogoutDone:
Title: Logged out
Description: You have logged out successfully.
Actions:
Login: login
Next: next
Back: back
Resend: resend
Skip: skip
Register: register
ForgotPassword: Reset password
Errors:
Internal: An internal error occured
AuthRequest:
NotFound: Could not find authrequest
User:
NotFound: User could not be found
NotMatchingUserID: User and user in authrequest don't match
UserIDMissing: UserID is empty
Invalid: Invalid userdata
Password:
ConfirmationWrong: Passwordconfirmation is wrong
Empty: Password is empty
Invalid: Passwort is invalid
PasswordComplexityPolicy:
NotFound: Password policy not found
MinLength: Password is to short
HasLower: Password must contain lower letter
HasUpper: Password must contain upper letter
HasNumber: Password must contain number
HasSymbol: Password must contain symbol
Code:
Expired: Code is expired
Invalid: Code is invalid
Empty: Code is empty
CryptoCodeNil: Crypto code is nil
NotFound: Could not find code
GeneratorAlgNotSupported: Unsupported generator algorithm
EmailVerify:
UserIDEmpty: UserID is empty
Mfa:
NoProviders: No available multifactor providers
Otp:
AlreadyReady: Multifactor OTP (OneTimePassword) is already setup
NotExisting: Multifactor OTP (OneTimePassword) doesn't exist
InvalidCode: Invalid code
NotReady: Multifactor OTP (OneTimePassword) isn't ready
Locked: User is locked
NotActive: User is not active
optional: (optional)
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
+93
View File
@@ -0,0 +1,93 @@
Copyright (c) 2010-2014 by tyPoland Lukasz Dziedzic ([email protected]) with Reserved Font Name "Lato"
This Font Software is licensed under the SIL Open Font License, Version 1.1.
This license is copied below, and is also available with a FAQ at:
http://scripts.sil.org/OFL
-----------------------------------------------------------
SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
-----------------------------------------------------------
PREAMBLE
The goals of the Open Font License (OFL) are to stimulate worldwide
development of collaborative font projects, to support the font creation
efforts of academic and linguistic communities, and to provide a free and
open framework in which fonts may be shared and improved in partnership
with others.
The OFL allows the licensed fonts to be used, studied, modified and
redistributed freely as long as they are not sold by themselves. The
fonts, including any derivative works, can be bundled, embedded,
redistributed and/or sold with any software provided that any reserved
names are not used by derivative works. The fonts and derivatives,
however, cannot be released under any other type of license. The
requirement for fonts to remain under this license does not apply
to any document created using the fonts or their derivatives.
DEFINITIONS
"Font Software" refers to the set of files released by the Copyright
Holder(s) under this license and clearly marked as such. This may
include source files, build scripts and documentation.
"Reserved Font Name" refers to any names specified as such after the
copyright statement(s).
"Original Version" refers to the collection of Font Software components as
distributed by the Copyright Holder(s).
"Modified Version" refers to any derivative made by adding to, deleting,
or substituting -- in part or in whole -- any of the components of the
Original Version, by changing formats or by porting the Font Software to a
new environment.
"Author" refers to any designer, engineer, programmer, technical
writer or other person who contributed to the Font Software.
PERMISSION & CONDITIONS
Permission is hereby granted, free of charge, to any person obtaining
a copy of the Font Software, to use, study, copy, merge, embed, modify,
redistribute, and sell modified and unmodified copies of the Font
Software, subject to the following conditions:
1) Neither the Font Software nor any of its individual components,
in Original or Modified Versions, may be sold by itself.
2) Original or Modified Versions of the Font Software may be bundled,
redistributed and/or sold with any software, provided that each copy
contains the above copyright notice and this license. These can be
included either as stand-alone text files, human-readable headers or
in the appropriate machine-readable metadata fields within text or
binary files as long as those fields can be easily viewed by the user.
3) No Modified Version of the Font Software may use the Reserved Font
Name(s) unless explicit written permission is granted by the corresponding
Copyright Holder. This restriction only applies to the primary font name as
presented to the users.
4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font
Software shall not be used to promote, endorse or advertise any
Modified Version, except to acknowledge the contribution(s) of the
Copyright Holder(s) and the Author(s) or with their explicit written
permission.
5) The Font Software, modified or unmodified, in part or in whole,
must be distributed entirely under this license, and must not be
distributed under any other license. The requirement for fonts to
remain under this license does not apply to any document created
using the Font Software.
TERMINATION
This license becomes null and void if any of the above conditions are
not met.
DISCLAIMER
THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
OTHER DEALINGS IN THE FONT SOFTWARE.
@@ -0,0 +1,7 @@
package resources
// scss
//go:generate sass themes/scss/zitadel/dark.scss themes/zitadel/css/dark.css
//go:generate sass themes/scss/zitadel/light.scss themes/zitadel/css/light.css
//go:generate sass themes/scss/caos/dark.scss themes/caos/css/dark.css
//go:generate sass themes/scss/caos/light.scss themes/caos/css/light.css
Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.4 KiB

@@ -0,0 +1,6 @@
const copyToClipboard = str => {
navigator.clipboard.writeText(str);
}
let copyButton = document.getElementsByClassName("copy")[0];
copyButton.addEventListener("click", copyToClipboard(copyButton.getAttribute("data-copy")));
@@ -0,0 +1,356 @@
@font-face {
font-family: Aileron;
src: url(../../../fonts/ailerons/ailerons.otf) format("opentype");
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-Thin.ttf) format("truetype");
font-style: normal;
font-weight: 100;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-ThinItalic.ttf) format("truetype");
font-style: italic;
font-weight: 100;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-Light.ttf) format("truetype");
font-style: normal;
font-weight: 200;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-LightItalic.ttf) format("truetype");
font-style: italic;
font-weight: 200;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-Regular.ttf) format("truetype");
font-style: normal;
font-weight: 400;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-Italic.ttf) format("truetype");
font-style: italic;
font-weight: 400;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-Bold.ttf) format("truetype");
font-style: normal;
font-weight: 700;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-BoldItalic.ttf) format("truetype");
font-style: italic;
font-weight: 700;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-Black.ttf) format("truetype");
font-style: normal;
font-weight: 800;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-BlackItalic.ttf) format("truetype");
font-style: italic;
font-weight: 800;
}
@font-face {
font-family: "Material Icons";
font-style: normal;
font-weight: 400;
src: url(../../../fonts/material/MaterialIcons-Regular.eot);
/* For IE6-8 */
src: local("Material Icons"), local("MaterialIcons-Regular"), url(../../../fonts/material/MaterialIcons-Regular.woff2) format("woff2"), url(../../../fonts/material/MaterialIcons-Regular.woff) format("woff"), url(../../../fonts/material/MaterialIcons-Regular.ttf) format("truetype");
}
*, *::before, *::after {
box-sizing: border-box;
font-family: Lato;
font-size: 18px;
font-weight: 400;
}
body {
margin: 0;
}
html {
height: 100%;
width: 100%;
font-weight: 300;
background-color: #282828;
color: white;
background-repeat: no-repeat;
background-position: bottom right;
}
h1 {
color: white;
font-family: Aileron;
font-weight: 300;
font-size: 40px;
}
p {
font-weight: 300;
}
header {
padding: 8px;
}
header .logo {
background-image: url("../logo-dark.png");
background-repeat: no-repeat;
background-size: contain;
height: 80px;
margin: 30px;
}
.content {
margin: auto;
padding: 20px;
width: 100%;
max-width: 500px;
}
a {
color: #760038;
text-decoration: none;
font-weight: 400;
}
a:hover {
color: #f60075;
}
button {
background-color: #282828;
color: #760038;
border: 2px solid #760038;
border-radius: 5px;
width: 100%;
max-width: 600px;
height: 50px;
transition: all 0.3s ease 0s;
cursor: pointer;
outline: none;
}
button:hover {
background-color: #f60075;
border: 2px solid #f60075;
}
button.primary {
background-color: #760038;
color: white;
border: none;
}
button.primary:hover {
background-color: #f60075;
}
input:not([type=radio]), select {
background-color: #252525;
color: white;
height: 50px;
border: 2px solid #505050;
border-radius: 5px;
padding-left: 15px;
}
form .field {
display: grid;
padding: 10px 0;
}
form .field.radio-button {
display: flex;
}
form .field.radio-button input[type=radio] {
height: 20px;
vertical-align: middle;
}
form .field.radio-button label {
height: 20px;
display: inline-block;
padding: 3px 0 0 15px;
width: 100%;
}
form label {
color: #898989;
text-transform: uppercase;
font-size: 0.9rem;
margin-bottom: 3px;
}
form label span.optional {
font-style: italic;
text-transform: none;
}
form .actions {
padding: 20px 0;
}
form .actions .right {
float: right;
}
form .actions button, form .actions a {
margin: 10px 0;
}
form button.clean {
border: none;
height: auto;
color: white;
text-align: left;
text-transform: unset;
display: flex;
padding: 15px;
}
form button.clean:hover {
border: none;
background-color: #252525;
}
form button.clean * {
font-weight: 300;
}
form .user-selection-list {
margin-bottom: 80px;
}
form button.user-selection .profile-image {
width: 100px;
height: 100px;
background-image: url("/resources/images/icon-user-dark.png");
}
@media only screen and (-webkit-min-device-pixel-ratio: 2), only screen and (min--moz-device-pixel-ratio: 2), only screen and (-o-min-device-pixel-ratio: 2/1), only screen and (min-device-pixel-ratio: 2), only screen and (min-resolution: 192dpi), only screen and (min-resolution: 2dppx) {
form button.user-selection .profile-image {
background-image: url("/resources/images/[email protected]");
background-size: 100px 100px;
}
}
form button.user-selection:hover .profile-image {
background-image: url("/resources/images/icon-user-dark-hover.png");
}
@media only screen and (-webkit-min-device-pixel-ratio: 2), only screen and (min--moz-device-pixel-ratio: 2), only screen and (-o-min-device-pixel-ratio: 2/1), only screen and (min-device-pixel-ratio: 2), only screen and (min-resolution: 192dpi), only screen and (min-resolution: 2dppx) {
form button.user-selection:hover .profile-image {
background-image: url("/resources/images/[email protected]");
background-size: 100px 100px;
}
}
form button.user-selection .sessionstate {
display: inline-block;
height: 20px;
width: 20px;
border-radius: 20px;
border-color: #505050;
border-style: solid;
border-width: 1px;
position: absolute;
bottom: 0px;
right: 10px;
}
form button.user-selection .sessionstate.sessionstate-0 {
background-color: #138D00;
}
form button.user-selection .sessionstate.sessionstate-1 {
background-color: #BC372E;
}
form button.user-selection > div {
position: relative;
}
form button.user-selection > div.names {
margin: 15px;
}
form button.user-selection > div.names .displayname {
font-size: 1.4rem;
}
form button.user-selection > div.names .loginname {
color: #898989;
}
.user-selection + form button.other-user {
margin-top: 80px;
}
form button.other-user .other-user-image {
width: 100px;
height: 75px;
background-repeat: no-repeat;
background-position: center;
background-image: url("/resources/images/icon-newuser-dark.png");
}
@media only screen and (-webkit-min-device-pixel-ratio: 2), only screen and (min--moz-device-pixel-ratio: 2), only screen and (-o-min-device-pixel-ratio: 2/1), only screen and (min-device-pixel-ratio: 2), only screen and (min-resolution: 192dpi), only screen and (min-resolution: 2dppx) {
form button.other-user .other-user-image {
background-image: url("/resources/images/[email protected]");
background-size: 100px 75px;
}
}
form button.other-user:hover .other-user-image {
background-repeat: no-repeat;
background-position: center;
background-image: url("/resources/images/icon-newuser-dark-hover.png");
}
@media only screen and (-webkit-min-device-pixel-ratio: 2), only screen and (min--moz-device-pixel-ratio: 2), only screen and (-o-min-device-pixel-ratio: 2/1), only screen and (min-device-pixel-ratio: 2), only screen and (min-resolution: 192dpi), only screen and (min-resolution: 2dppx) {
form button.other-user:hover .other-user-image {
background-image: url("/resources/images/[email protected]");
background-size: 100px 75px;
}
}
form button.other-user > div:nth-of-type(2) {
margin: 15px;
font-size: 1.4rem;
}
#copy-secret {
visibility: hidden;
position: absolute;
}
#qrcode {
text-align: center;
}
#qrcode svg rect.color {
fill: white;
}
#qrcode svg rect.bg-color {
fill: #282828;
}
#secret .copy {
float: right;
cursor: pointer;
}
footer {
background-image: url("../gradientdeco-full.svg");
width: 100%;
background-size: cover;
height: 44vw;
position: fixed;
bottom: 0;
z-index: -1;
}
.material-icons {
font-family: "Material Icons";
font-weight: normal;
font-style: normal;
font-size: 24px;
/* Preferred icon size */
display: inline-block;
line-height: 1;
text-transform: none;
letter-spacing: normal;
word-wrap: normal;
white-space: nowrap;
direction: ltr;
/* Support for all WebKit browsers. */
-webkit-font-smoothing: antialiased;
/* Support for Safari and Chrome. */
text-rendering: optimizeLegibility;
/* Support for Firefox. */
-moz-osx-font-smoothing: grayscale;
/* Support for IE. */
font-feature-settings: "liga";
}
/*# sourceMappingURL=dark.css.map */
@@ -0,0 +1 @@
{"version":3,"sourceRoot":"","sources":["../../scss/fonts.scss","../../scss/main.scss","../../scss/caos/variables.scss","../../scss/variables.scss"],"names":[],"mappings":"AACA;EACI;EACA;;AAIJ;EACI;EACA;EACA;EACA;;AAEJ;EACI;EACA;EACA;EACA;;AAGJ;EACI;EACA;EACA;EACA;;AAEJ;EACI;EACA;EACA;EACA;;AAGJ;EACI;EACA;EACA;EACA;;AAEJ;EACI;EACA;EACA;EACA;;AAGJ;EACI;EACA;EACA;EACA;;AAEJ;EACI;EACA;EACA;EACA;;AAGJ;EACI;EACA;EACA;EACA;;AAEJ;EACI;EACA;EACA;EACA;;AAIJ;EACI;EACA;EACA;EACA;AAA6D;EAC7D;;AC5EJ;EACI;EACA,aCMW;EDLX;EACA;;;AAGJ;EACI;;;AAGJ;EACI;EACA;EACA;EACA,kBCDc;EDEd,OCDQ;EDER;EACA;;;AAMJ;EACI,OCVQ;EDWR,aCjBS;EDkBT;EACA;;;AAGJ;EACI;;;AAGJ;EACI;;AAEA;EACI;EACA;EACA;EACA;EACA;;;AAIR;EACI;EACA;EACA;EACA;;;AAGJ;EACI,OCvCW;EDwCX;EACA;;AAEA;EACI,OC3CY;;;AD+CpB;EACI,kBCnDc;EDoDd,OClDW;EDmDX;EACA;EACA;EACA;EACA,QEpEU;EFqEV;EACA;EACA;;AACA;EACI,kBC3DY;ED4DZ;;AAGJ;EACI,kBCjEO;EDkEP,OCnEI;EDoEJ;;AACA;EACI,kBCpEQ;;;ADyEpB;EACI,kBEjEmB;EFkEnB,OC7EQ;ED8ER,QE1FU;EF2FV;EACA;EACA;;;AAIA;EACI;EACA;;AAGJ;EACI;;AAEA;EACI;EACA;;AAGJ;EACI;EACA;EACA;EACA;;AAIR;EACI,OElGK;EFmGL;EACA;EACA;;AAEA;EACI;EACA;;AAIR;EACI;;AAEA;EACI;;AAGJ;EACI;;AAIR;EACI;EACA;EACA,OCrII;EDsIJ;EACA;EACA;EACA;;AAEA;EACI;EACA,kBElIW;;AFqIf;EACI;;AAIR;EACI;;AAIA;EACI;EACA;EE/JV;;AACA;EF4JM;IE3JJ;IACA;;;AFiKQ;EEpKV;;AACA;EFmKU;IElKR;IACA;;;AFsKI;EACI;EACA;EACA;EACA;EACA,cEjKO;EFkKP;EACA;EACA;EACA;EACA;;AAEA;EACI;;AAGJ;EACI;;AAKR;EACI;;AAEA;EACI;;AAEA;EACI;;AAEJ;EACI,OE7LP;;AFoML;EACI;;AAEJ;EACI;EACA;EACA;EACA;EEvNV;;AACA;EFkNM;IEjNJ;IACA;;;AFyNQ;EACI;EACA;EE9Nd;;AACA;EF2NU;IE1NR;IACA;;;AFgOI;EACI;EACA;;;AAKZ;EACI;EACA;;;AAGJ;EACI;;AAEA;EACI,MChPI;;ADmPR;EACI,MCrPU;;;AD0Pd;EACI;EACA;;;AAIR;EAEQ;EAEJ;EACA;EACA;EACA;EACA;EACA;;;AAGJ;EACI;EACA;EACA;EACA;AAAkB;EAClB;EACA;EACA;EACA;EACA;EACA;EACA;AAEA;EACA;AACA;EACA;AAEA;EACA;AAEA;EACA","file":"dark.css"}
@@ -0,0 +1,440 @@
@font-face {
font-family: Aileron;
src: url(../../../fonts/ailerons/ailerons.otf) format("opentype");
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-Thin.ttf) format("truetype");
font-style: normal;
font-weight: 100;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-ThinItalic.ttf) format("truetype");
font-style: italic;
font-weight: 100;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-Light.ttf) format("truetype");
font-style: normal;
font-weight: 200;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-LightItalic.ttf) format("truetype");
font-style: italic;
font-weight: 200;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-Regular.ttf) format("truetype");
font-style: normal;
font-weight: 400;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-Italic.ttf) format("truetype");
font-style: italic;
font-weight: 400;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-Bold.ttf) format("truetype");
font-style: normal;
font-weight: 700;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-BoldItalic.ttf) format("truetype");
font-style: italic;
font-weight: 700;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-Black.ttf) format("truetype");
font-style: normal;
font-weight: 800;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-BlackItalic.ttf) format("truetype");
font-style: italic;
font-weight: 800;
}
@font-face {
font-family: "Material Icons";
font-style: normal;
font-weight: 400;
src: url(../../../fonts/material/MaterialIcons-Regular.eot);
/* For IE6-8 */
src: local("Material Icons"), local("MaterialIcons-Regular"), url(../../../fonts/material/MaterialIcons-Regular.woff2) format("woff2"), url(../../../fonts/material/MaterialIcons-Regular.woff) format("woff"), url(../../../fonts/material/MaterialIcons-Regular.ttf) format("truetype");
}
*, *::before, *::after {
box-sizing: border-box;
font-family: Lato;
font-size: 18px;
font-weight: 400;
}
body {
margin: 0;
}
html {
height: 100%;
width: 100%;
font-weight: 300;
background-color: #282828;
color: white;
background-repeat: no-repeat;
background-position: bottom right;
}
h1 {
color: white;
font-family: Aileron;
font-weight: 300;
font-size: 40px;
}
p {
font-weight: 300;
}
header {
padding: 8px;
}
header .logo {
background-image: url("../logo-dark.png");
background-repeat: no-repeat;
background-size: contain;
height: 80px;
margin: 30px;
}
.content {
margin: auto;
padding: 20px;
width: 100%;
max-width: 500px;
}
a {
color: #760038;
text-decoration: none;
font-weight: 400;
}
a:hover {
color: #f60075;
}
button {
background-color: #282828;
color: #760038;
border: 2px solid #760038;
border-radius: 5px;
width: 100%;
max-width: 600px;
height: 50px;
transition: all 0.3s ease 0s;
cursor: pointer;
outline: none;
}
button:hover {
background-color: #f60075;
border: 2px solid #f60075;
}
button.primary {
background-color: #760038;
color: white;
border: none;
}
button.primary:hover {
background-color: #f60075;
}
input:not([type=radio]), select {
background-color: #252525;
color: white;
height: 50px;
border: 2px solid #505050;
border-radius: 5px;
padding-left: 15px;
}
form .field {
display: grid;
padding: 10px 0;
}
form .field.radio-button {
display: flex;
}
form .field.radio-button input[type=radio] {
height: 20px;
vertical-align: middle;
}
form .field.radio-button label {
height: 20px;
display: inline-block;
padding: 3px 0 0 15px;
width: 100%;
}
form label {
color: #898989;
text-transform: uppercase;
font-size: 0.9rem;
margin-bottom: 3px;
}
form label span.optional {
font-style: italic;
text-transform: none;
}
form .actions {
padding: 20px 0;
}
form .actions .right {
float: right;
}
form .actions button, form .actions a {
margin: 10px 0;
}
form button.clean {
border: none;
height: auto;
color: white;
text-align: left;
text-transform: unset;
display: flex;
padding: 15px;
}
form button.clean:hover {
border: none;
background-color: #252525;
}
form button.clean * {
font-weight: 300;
}
form .user-selection-list {
margin-bottom: 80px;
}
form button.user-selection .profile-image {
width: 100px;
height: 100px;
background-image: url("/resources/images/icon-user-dark.png");
}
@media only screen and (-webkit-min-device-pixel-ratio: 2), only screen and (min--moz-device-pixel-ratio: 2), only screen and (-o-min-device-pixel-ratio: 2/1), only screen and (min-device-pixel-ratio: 2), only screen and (min-resolution: 192dpi), only screen and (min-resolution: 2dppx) {
form button.user-selection .profile-image {
background-image: url("/resources/images/[email protected]");
background-size: 100px 100px;
}
}
form button.user-selection:hover .profile-image {
background-image: url("/resources/images/icon-user-dark-hover.png");
}
@media only screen and (-webkit-min-device-pixel-ratio: 2), only screen and (min--moz-device-pixel-ratio: 2), only screen and (-o-min-device-pixel-ratio: 2/1), only screen and (min-device-pixel-ratio: 2), only screen and (min-resolution: 192dpi), only screen and (min-resolution: 2dppx) {
form button.user-selection:hover .profile-image {
background-image: url("/resources/images/[email protected]");
background-size: 100px 100px;
}
}
form button.user-selection .sessionstate {
display: inline-block;
height: 20px;
width: 20px;
border-radius: 20px;
border-color: #505050;
border-style: solid;
border-width: 1px;
position: absolute;
bottom: 0px;
right: 10px;
}
form button.user-selection .sessionstate.sessionstate-0 {
background-color: #138D00;
}
form button.user-selection .sessionstate.sessionstate-1 {
background-color: #BC372E;
}
form button.user-selection > div {
position: relative;
}
form button.user-selection > div.names {
margin: 15px;
}
form button.user-selection > div.names .displayname {
font-size: 1.4rem;
}
form button.user-selection > div.names .loginname {
color: #898989;
}
.user-selection + form button.other-user {
margin-top: 80px;
}
form button.other-user .other-user-image {
width: 100px;
height: 75px;
background-repeat: no-repeat;
background-position: center;
background-image: url("/resources/images/icon-newuser-dark.png");
}
@media only screen and (-webkit-min-device-pixel-ratio: 2), only screen and (min--moz-device-pixel-ratio: 2), only screen and (-o-min-device-pixel-ratio: 2/1), only screen and (min-device-pixel-ratio: 2), only screen and (min-resolution: 192dpi), only screen and (min-resolution: 2dppx) {
form button.other-user .other-user-image {
background-image: url("/resources/images/[email protected]");
background-size: 100px 75px;
}
}
form button.other-user:hover .other-user-image {
background-repeat: no-repeat;
background-position: center;
background-image: url("/resources/images/icon-newuser-dark-hover.png");
}
@media only screen and (-webkit-min-device-pixel-ratio: 2), only screen and (min--moz-device-pixel-ratio: 2), only screen and (-o-min-device-pixel-ratio: 2/1), only screen and (min-device-pixel-ratio: 2), only screen and (min-resolution: 192dpi), only screen and (min-resolution: 2dppx) {
form button.other-user:hover .other-user-image {
background-image: url("/resources/images/[email protected]");
background-size: 100px 75px;
}
}
form button.other-user > div:nth-of-type(2) {
margin: 15px;
font-size: 1.4rem;
}
#copy-secret {
visibility: hidden;
position: absolute;
}
#qrcode {
text-align: center;
}
#qrcode svg rect.color {
fill: white;
}
#qrcode svg rect.bg-color {
fill: #282828;
}
#secret .copy {
float: right;
cursor: pointer;
}
footer {
background-image: url("../gradientdeco-full.svg");
width: 100%;
background-size: cover;
height: 44vw;
position: fixed;
bottom: 0;
z-index: -1;
}
.material-icons {
font-family: "Material Icons";
font-weight: normal;
font-style: normal;
font-size: 24px;
/* Preferred icon size */
display: inline-block;
line-height: 1;
text-transform: none;
letter-spacing: normal;
word-wrap: normal;
white-space: nowrap;
direction: ltr;
/* Support for all WebKit browsers. */
-webkit-font-smoothing: antialiased;
/* Support for Safari and Chrome. */
text-rendering: optimizeLegibility;
/* Support for Firefox. */
-moz-osx-font-smoothing: grayscale;
/* Support for IE. */
font-feature-settings: "liga";
}
html {
background-color: white;
color: #282828;
}
html header .logo {
background-image: url("../logo-light.png");
}
html h1 {
color: #282828;
}
html button {
background-color: white;
color: #760038;
border: 2px solid #760038;
}
html button:hover {
background-color: #f60075;
border: 2px solid #f60075;
}
html button.primary {
background-color: #760038;
color: white;
border: none;
box-shadow: 0px 10px 30px #760038;
}
html button.primary:hover {
background-color: #f60075;
}
html button.clean {
color: #282828;
}
html button.user-selection .profile-image {
background-image: url("/resources/images/icon-user-light.png");
}
@media only screen and (-webkit-min-device-pixel-ratio: 2), only screen and (min--moz-device-pixel-ratio: 2), only screen and (-o-min-device-pixel-ratio: 2/1), only screen and (min-device-pixel-ratio: 2), only screen and (min-resolution: 192dpi), only screen and (min-resolution: 2dppx) {
html button.user-selection .profile-image {
background-image: url("/resources/images/[email protected]");
background-size: 100px 100px;
}
}
html button.user-selection:hover {
background-color: #252525;
}
html button.user-selection:hover .profile-image {
background-image: url("/resources/images/icon-user-light-hover.png");
}
@media only screen and (-webkit-min-device-pixel-ratio: 2), only screen and (min--moz-device-pixel-ratio: 2), only screen and (-o-min-device-pixel-ratio: 2/1), only screen and (min-device-pixel-ratio: 2), only screen and (min-resolution: 192dpi), only screen and (min-resolution: 2dppx) {
html button.user-selection:hover .profile-image {
background-image: url("/resources/images/[email protected]");
background-size: 100px 100px;
}
}
html button.other-user .other-user-image {
background-image: url("/resources/images/icon-newuser-light.png");
}
@media only screen and (-webkit-min-device-pixel-ratio: 2), only screen and (min--moz-device-pixel-ratio: 2), only screen and (-o-min-device-pixel-ratio: 2/1), only screen and (min-device-pixel-ratio: 2), only screen and (min-resolution: 192dpi), only screen and (min-resolution: 2dppx) {
html button.other-user .other-user-image {
background-image: url("/resources/images/[email protected]");
background-size: 100px 75px;
}
}
html button.other-user:hover .other-user-image {
background-image: url("/resources/images/icon-newuser-light-hover.png");
}
@media only screen and (-webkit-min-device-pixel-ratio: 2), only screen and (min--moz-device-pixel-ratio: 2), only screen and (-o-min-device-pixel-ratio: 2/1), only screen and (min-device-pixel-ratio: 2), only screen and (min-resolution: 192dpi), only screen and (min-resolution: 2dppx) {
html button.other-user:hover .other-user-image {
background-image: url("/resources/images/[email protected]");
background-size: 100px 75px;
}
}
html input {
background-color: white;
color: #282828;
}
html #qrcode svg rect.color {
fill: #282828;
}
html #qrcode svg rect.bg-color {
fill: white;
}
html footer {
background-image: url("../gradientdeco-full.svg");
}
/*# sourceMappingURL=light.css.map */
@@ -0,0 +1 @@
{"version":3,"sourceRoot":"","sources":["../../scss/fonts.scss","../../scss/main.scss","../../scss/caos/variables.scss","../../scss/variables.scss","../../scss/light.scss"],"names":[],"mappings":"AACA;EACI;EACA;;AAIJ;EACI;EACA;EACA;EACA;;AAEJ;EACI;EACA;EACA;EACA;;AAGJ;EACI;EACA;EACA;EACA;;AAEJ;EACI;EACA;EACA;EACA;;AAGJ;EACI;EACA;EACA;EACA;;AAEJ;EACI;EACA;EACA;EACA;;AAGJ;EACI;EACA;EACA;EACA;;AAEJ;EACI;EACA;EACA;EACA;;AAGJ;EACI;EACA;EACA;EACA;;AAEJ;EACI;EACA;EACA;EACA;;AAIJ;EACI;EACA;EACA;EACA;AAA6D;EAC7D;;AC5EJ;EACI;EACA,aCMW;EDLX;EACA;;;AAGJ;EACI;;;AAGJ;EACI;EACA;EACA;EACA,kBCDc;EDEd,OCDQ;EDER;EACA;;;AAMJ;EACI,OCVQ;EDWR,aCjBS;EDkBT;EACA;;;AAGJ;EACI;;;AAGJ;EACI;;AAEA;EACI;EACA;EACA;EACA;EACA;;;AAIR;EACI;EACA;EACA;EACA;;;AAGJ;EACI,OCvCW;EDwCX;EACA;;AAEA;EACI,OC3CY;;;AD+CpB;EACI,kBCnDc;EDoDd,OClDW;EDmDX;EACA;EACA;EACA;EACA,QEpEU;EFqEV;EACA;EACA;;AACA;EACI,kBC3DY;ED4DZ;;AAGJ;EACI,kBCjEO;EDkEP,OCnEI;EDoEJ;;AACA;EACI,kBCpEQ;;;ADyEpB;EACI,kBEjEmB;EFkEnB,OC7EQ;ED8ER,QE1FU;EF2FV;EACA;EACA;;;AAIA;EACI;EACA;;AAGJ;EACI;;AAEA;EACI;EACA;;AAGJ;EACI;EACA;EACA;EACA;;AAIR;EACI,OElGK;EFmGL;EACA;EACA;;AAEA;EACI;EACA;;AAIR;EACI;;AAEA;EACI;;AAGJ;EACI;;AAIR;EACI;EACA;EACA,OCrII;EDsIJ;EACA;EACA;EACA;;AAEA;EACI;EACA,kBElIW;;AFqIf;EACI;;AAIR;EACI;;AAIA;EACI;EACA;EE/JV;;AACA;EF4JM;IE3JJ;IACA;;;AFiKQ;EEpKV;;AACA;EFmKU;IElKR;IACA;;;AFsKI;EACI;EACA;EACA;EACA;EACA,cEjKO;EFkKP;EACA;EACA;EACA;EACA;;AAEA;EACI;;AAGJ;EACI;;AAKR;EACI;;AAEA;EACI;;AAEA;EACI;;AAEJ;EACI,OE7LP;;AFoML;EACI;;AAEJ;EACI;EACA;EACA;EACA;EEvNV;;AACA;EFkNM;IEjNJ;IACA;;;AFyNQ;EACI;EACA;EE9Nd;;AACA;EF2NU;IE1NR;IACA;;;AFgOI;EACI;EACA;;;AAKZ;EACI;EACA;;;AAGJ;EACI;;AAEA;EACI,MChPI;;ADmPR;EACI,MCrPU;;;AD0Pd;EACI;EACA;;;AAIR;EAEQ;EAEJ;EACA;EACA;EACA;EACA;EACA;;;AAGJ;EACI;EACA;EACA;EACA;AAAkB;EAClB;EACA;EACA;EACA;EACA;EACA;EACA;AAEA;EACA;AACA;EACA;AAEA;EACA;AAEA;EACA;;;AGjTJ;EACI,kBFeQ;EEdR,OFac;;AERd;EACI;;AAGJ;EACI,OFGU;;AEAd;EACI;EACA;EACA;;AAEA;EACI,kBFIa;EEHb;;AAGJ;EACI,kBFTG;EEUH,OFXA;EEYA;EACA;;AACA;EACI,kBFbI;;AEiBZ;EACI,OFrBM;;AEyBN;ED3BV;;AACA;EC0BU;IDzBR;IACA;;;AC4BQ;EACI,kBDlBO;;ACoBP;EDlCd;;AACA;ECiCc;IDhCZ;IACA;;;ACsCQ;EDzCV;;AACA;ECwCU;IDvCR;IACA;;;AC2CY;ED9Cd;;AACA;EC6Cc;ID5CZ;IACA;;;ACkDA;EACI,kBFnDI;EEoDJ,OFrDU;;AEyDV;EACI,MF1DM;;AE6DV;EACI,MF7DA;;AEiER;EAEQ","file":"light.css"}
Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 361 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 32 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 32 KiB

@@ -0,0 +1,3 @@
@import "../variables";
@import "variables";
@import "../main";
@@ -0,0 +1,4 @@
@import "../variables";
@import "variables";
@import "../main";
@import "../light";
@@ -0,0 +1,27 @@
$logoImgDark: "../logo-dark.png";
$logoImgLight: "../logo-light.png";
$footerimgDark: "../gradientdeco-full.svg";
$footerimgLight: "../gradientdeco-full.svg";
$bodyImgDark: "";
$bodyImgLight: "";
// ----- FONTS ------------
$standardFont: Lato;
$headerFont: Aileron;
// ----- COLORS ------------
// ------ DARK-THEME -------
$backgroundColor: #282828;
$fontColor: white;
$primaryColor: #760038;
$primaryColorHover: lighten($primaryColor, 25%);
// ------ LIGHT-THEME -------
$backgroundColorLight: $fontColor;
$fontColorLight: $backgroundColor;
$primaryColorLight: $primaryColor;
$primaryColorHoverLight: lighten($primaryColorLight, 25%);
@@ -0,0 +1,84 @@
//Aileron
@font-face {
font-family: Aileron;
src: url(../../../fonts/ailerons/ailerons.otf ) format('opentype');
}
//Lato
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-Thin.ttf ) format('truetype');
font-style: normal;
font-weight: 100;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-ThinItalic.ttf ) format('truetype');
font-style: italic;
font-weight: 100;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-Light.ttf ) format('truetype');
font-style: normal;
font-weight: 200;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-LightItalic.ttf ) format('truetype');
font-style: italic;
font-weight: 200;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-Regular.ttf ) format('truetype');
font-style: normal;
font-weight: 400;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-Italic.ttf ) format('truetype');
font-style: italic;
font-weight: 400;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-Bold.ttf ) format('truetype');
font-style: normal;
font-weight: 700;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-BoldItalic.ttf ) format('truetype');
font-style: italic;
font-weight: 700;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-Black.ttf ) format('truetype');
font-style: normal;
font-weight: 800;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-BlackItalic.ttf ) format('truetype');
font-style: italic;
font-weight: 800;
}
//Material Icons
@font-face {
font-family: 'Material Icons';
font-style: normal;
font-weight: 400;
src: url(../../../fonts/material/MaterialIcons-Regular.eot); /* For IE6-8 */
src: local('Material Icons'),
local('MaterialIcons-Regular'),
url(../../../fonts/material/MaterialIcons-Regular.woff2) format('woff2'),
url(../../../fonts/material/MaterialIcons-Regular.woff) format('woff'),
url(../../../fonts/material/MaterialIcons-Regular.ttf) format('truetype');
}
@@ -0,0 +1,88 @@
// ---- LIGHT-THEME-------
html {
background-color: $backgroundColorLight;
color: $fontColorLight;
@if($bodyImgLight != "") {
background-image: url($bodyImgLight);
}
header .logo {
background-image: url($logoImgLight);
}
h1 {
color: $fontColorLight;
}
button {
background-color: $backgroundColorLight;
color: $primaryColorLight;
border: 2px solid $primaryColorLight;
&:hover {
background-color: $primaryColorHoverLight;
border: 2px solid $primaryColorHoverLight;
}
&.primary {
background-color: $primaryColor;
color: $fontColor;
border: none;
box-shadow: 0px 10px 30px $primaryColor;
&:hover {
background-color: $primaryColorHover;
}
}
&.clean {
color: $fontColorLight;
}
&.user-selection {
.profile-image {
@include retina-background-image($profileImgLight, "png", false, 100px, 100px);
}
&:hover {
background-color: $buttonBackgroundColorHover;
.profile-image {
@include retina-background-image($profileImgLight, "png", true, 100px, 100px);
}
}
}
&.other-user {
.other-user-image {
@include retina-background-image($otherUserImgLight, "png", false, 100px, 75px);
}
&:hover {
.other-user-image {
@include retina-background-image($otherUserImgLight, "png", true, 100px, 75px);
}
}
}
}
input {
background-color: $backgroundColorLight;
color: $fontColorLight;
}
#qrcode {
svg rect.color {
fill: $fontColorLight;
}
svg rect.bg-color {
fill: $backgroundColorLight;
}
}
footer {
@if($footerimgLight != "") {
background-image: url($footerimgLight);
}
}
}
@@ -0,0 +1,308 @@
@import "fonts";
*, *::before, *::after {
box-sizing: border-box;
font-family: $standardFont;
font-size: 18px;
font-weight: 400;
}
body {
margin: 0;
}
html {
height: 100%;
width: 100%;
font-weight: 300;
background-color: $backgroundColor;
color: $fontColor;
background-repeat: no-repeat;
background-position: bottom right;
@if($bodyImgDark != "") {
background-image: url($bodyImgDark);
}
}
h1 {
color: $fontColor;
font-family: $headerFont;
font-weight: 300;
font-size: 40px;
}
p {
font-weight: 300;
}
header {
padding: 8px;
.logo {
background-image: url($logoImgDark);
background-repeat: no-repeat;
background-size: contain;
height: 80px;
margin: 30px;
}
}
.content {
margin: auto;
padding: 20px;
width: 100%;
max-width: 500px;
}
a {
color: $primaryColor;
text-decoration: none;
font-weight: 400;
&:hover {
color: $primaryColorHover;
}
}
button {
background-color: $backgroundColor;
color: $primaryColor;
border: 2px solid $primaryColor;
border-radius: 5px;
width: 100%;
max-width: 600px;
height: $inputHeight;
transition: all 0.3s ease 0s;
cursor: pointer;
outline: none;
&:hover {
background-color: $primaryColorHover;
border: 2px solid $primaryColorHover;
}
&.primary {
background-color: $primaryColor;
color: $fontColor;
border: none;
&:hover {
background-color: $primaryColorHover;
}
}
}
input:not([type='radio']), select {
background-color: $inputBackgroundColor;
color: $fontColor;
height: $inputHeight;
border: 2px solid $inputBorderColor;
border-radius: 5px;
padding-left: 15px;
}
form {
.field {
display: grid;
padding: 10px 0;
}
.field.radio-button {
display: flex;
input[type='radio'] {
height: 20px;
vertical-align: middle;
}
& label {
height: 20px;
display: inline-block;
padding: 3px 0 0 15px;
width: 100%;
}
}
label {
color: $labelColor;
text-transform: uppercase;
font-size: 0.9rem;
margin-bottom: 3px;
span.optional {
font-style: italic;
text-transform: none;
}
}
.actions {
padding: 20px 0;
.right {
float: right;
}
button, a {
margin: 10px 0;
}
}
button.clean {
border: none;
height: auto;
color: $fontColor;
text-align: left;
text-transform: unset;
display: flex;
padding: 15px;
&:hover {
border: none;
background-color: $buttonBackgroundColorHover;
}
* {
font-weight: 300;
}
}
.user-selection-list {
margin-bottom: 80px;
}
button.user-selection {
.profile-image {
width: 100px;
height: 100px;
@include retina-background-image($profileImgDark, "png", false, 100px, 100px);
}
&:hover {
.profile-image {
@include retina-background-image($profileImgDark, "png", true, 100px, 100px);
}
}
.sessionstate {
display: inline-block;
height: 20px;
width: 20px;
border-radius: 20px;
border-color: $inputBorderColor;
border-style: solid;
border-width: 1px;
position: absolute;
bottom: 0px;
right: 10px;
&.sessionstate-0 {
background-color: #138D00;
}
&.sessionstate-1 {
background-color: #BC372E;
}
}
& > div {
position: relative;
&.names {
margin: 15px;
.displayname {
font-size: 1.4rem;
}
.loginname {
color: $labelColor;
}
}
}
}
button.other-user {
.user-selection+&{
margin-top: 80px;
}
.other-user-image {
width: 100px;
height: 75px;
background-repeat: no-repeat;
background-position: center;
@include retina-background-image($otherUserImgDark, "png", false, 100px, 75px);
}
&:hover {
.other-user-image {
background-repeat: no-repeat;
background-position: center;
@include retina-background-image($otherUserImgDark, "png", true, 100px, 75px);
}
}
& > div:nth-of-type(2) {
margin: 15px;
font-size: 1.4rem;
}
}
}
#copy-secret {
visibility: hidden;
position: absolute;
}
#qrcode {
text-align: center;
svg rect.color {
fill: $fontColor;
}
svg rect.bg-color {
fill: $backgroundColor;
}
}
#secret {
.copy {
float: right;
cursor: pointer;
}
}
footer {
@if($footerimgDark != "") {
background-image: url($footerimgDark);
}
width: 100%;
background-size: cover;
height: 44vw;
position: fixed;
bottom: 0;
z-index: -1;
}
.material-icons {
font-family: 'Material Icons';
font-weight: normal;
font-style: normal;
font-size: 24px; /* Preferred icon size */
display: inline-block;
line-height: 1;
text-transform: none;
letter-spacing: normal;
word-wrap: normal;
white-space: nowrap;
direction: ltr;
/* Support for all WebKit browsers. */
-webkit-font-smoothing: antialiased;
/* Support for Safari and Chrome. */
text-rendering: optimizeLegibility;
/* Support for Firefox. */
-moz-osx-font-smoothing: grayscale;
/* Support for IE. */
font-feature-settings: 'liga';
}
@@ -0,0 +1,42 @@
// ----- FONTS ------------
$standardFont: Lato;
$headerFont: Lato;
// ----- LAYOUT ------------
$inputHeight: 50px;
$retina: "only screen and (-webkit-min-device-pixel-ratio: 2), only screen and (min--moz-device-pixel-ratio: 2), only screen and (-o-min-device-pixel-ratio: 2/1), only screen and (min-device-pixel-ratio: 2), only screen and (min-resolution: 192dpi), only screen and (min-resolution: 2dppx)";
@mixin retina-background-image($file, $type, $hover, $width, $height) {
$hovername: '';
@if $hover {
$hovername: '-hover';
}
$filename :$file + $hovername;
background-image: url($filename + '.' + $type);
@media #{$retina} {
background-image: url($filename + '@2x.' + $type);
background-size: $width $height;
}
}
// ----- DARK-THEME --------
$backgroundColor: #282828;
$fontColor: #BBBBC8;
$primaryColor: #3574C6;
$primaryColorHover: lighten($primaryColor, 10%);
$labelColor: #898989;
$inputBorderColor: #505050;
$inputBackgroundColor: #252525;
$buttonBackgroundColorHover: $inputBackgroundColor;
$profileImgDark: "/resources/images/icon-user-dark";
$otherUserImgDark: "/resources/images/icon-newuser-dark";
// ----- LIGHT-THEME --------
$backgroundColorLight: $fontColor;
$fontColorLight: $backgroundColor;
$primaryColorLight: $primaryColor;
$primaryColorHoverLight: lighten($primaryColorLight, 10%);
$buttonBackgroundColorHoverLight: #EFEFEF;
$profileImgLight: "/resources/images/icon-user-light";
$otherUserImgLight: "/resources/images/icon-newuser-light";
@@ -0,0 +1,3 @@
@import "../variables";
@import "variables";
@import "../main";
@@ -0,0 +1,4 @@
@import "../variables";
@import "variables";
@import "../main";
@import "../light";
@@ -0,0 +1,8 @@
$logoImgDark: "../logo-dark.png";
$logoImgLight: "../logo-light.png";
$footerimgDark: "";
$footerimgLight: "";
$bodyImgDark: "../flavor-spikes01-narrow.png";
$bodyImgLight: "../flavor-spikes01-narrow.png";
@@ -0,0 +1,356 @@
@font-face {
font-family: Aileron;
src: url(../../../fonts/ailerons/ailerons.otf) format("opentype");
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-Thin.ttf) format("truetype");
font-style: normal;
font-weight: 100;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-ThinItalic.ttf) format("truetype");
font-style: italic;
font-weight: 100;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-Light.ttf) format("truetype");
font-style: normal;
font-weight: 200;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-LightItalic.ttf) format("truetype");
font-style: italic;
font-weight: 200;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-Regular.ttf) format("truetype");
font-style: normal;
font-weight: 400;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-Italic.ttf) format("truetype");
font-style: italic;
font-weight: 400;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-Bold.ttf) format("truetype");
font-style: normal;
font-weight: 700;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-BoldItalic.ttf) format("truetype");
font-style: italic;
font-weight: 700;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-Black.ttf) format("truetype");
font-style: normal;
font-weight: 800;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-BlackItalic.ttf) format("truetype");
font-style: italic;
font-weight: 800;
}
@font-face {
font-family: "Material Icons";
font-style: normal;
font-weight: 400;
src: url(../../../fonts/material/MaterialIcons-Regular.eot);
/* For IE6-8 */
src: local("Material Icons"), local("MaterialIcons-Regular"), url(../../../fonts/material/MaterialIcons-Regular.woff2) format("woff2"), url(../../../fonts/material/MaterialIcons-Regular.woff) format("woff"), url(../../../fonts/material/MaterialIcons-Regular.ttf) format("truetype");
}
*, *::before, *::after {
box-sizing: border-box;
font-family: Lato;
font-size: 18px;
font-weight: 400;
}
body {
margin: 0;
}
html {
height: 100%;
width: 100%;
font-weight: 300;
background-color: #282828;
color: #BBBBC8;
background-repeat: no-repeat;
background-position: bottom right;
background-image: url("../flavor-spikes01-narrow.png");
}
h1 {
color: #BBBBC8;
font-family: Lato;
font-weight: 300;
font-size: 40px;
}
p {
font-weight: 300;
}
header {
padding: 8px;
}
header .logo {
background-image: url("../logo-dark.png");
background-repeat: no-repeat;
background-size: contain;
height: 80px;
margin: 30px;
}
.content {
margin: auto;
padding: 20px;
width: 100%;
max-width: 500px;
}
a {
color: #3574C6;
text-decoration: none;
font-weight: 400;
}
a:hover {
color: #5b8fd3;
}
button {
background-color: #282828;
color: #3574C6;
border: 2px solid #3574C6;
border-radius: 5px;
width: 100%;
max-width: 600px;
height: 50px;
transition: all 0.3s ease 0s;
cursor: pointer;
outline: none;
}
button:hover {
background-color: #5b8fd3;
border: 2px solid #5b8fd3;
}
button.primary {
background-color: #3574C6;
color: #BBBBC8;
border: none;
}
button.primary:hover {
background-color: #5b8fd3;
}
input:not([type=radio]), select {
background-color: #252525;
color: #BBBBC8;
height: 50px;
border: 2px solid #505050;
border-radius: 5px;
padding-left: 15px;
}
form .field {
display: grid;
padding: 10px 0;
}
form .field.radio-button {
display: flex;
}
form .field.radio-button input[type=radio] {
height: 20px;
vertical-align: middle;
}
form .field.radio-button label {
height: 20px;
display: inline-block;
padding: 3px 0 0 15px;
width: 100%;
}
form label {
color: #898989;
text-transform: uppercase;
font-size: 0.9rem;
margin-bottom: 3px;
}
form label span.optional {
font-style: italic;
text-transform: none;
}
form .actions {
padding: 20px 0;
}
form .actions .right {
float: right;
}
form .actions button, form .actions a {
margin: 10px 0;
}
form button.clean {
border: none;
height: auto;
color: #BBBBC8;
text-align: left;
text-transform: unset;
display: flex;
padding: 15px;
}
form button.clean:hover {
border: none;
background-color: #252525;
}
form button.clean * {
font-weight: 300;
}
form .user-selection-list {
margin-bottom: 80px;
}
form button.user-selection .profile-image {
width: 100px;
height: 100px;
background-image: url("/resources/images/icon-user-dark.png");
}
@media only screen and (-webkit-min-device-pixel-ratio: 2), only screen and (min--moz-device-pixel-ratio: 2), only screen and (-o-min-device-pixel-ratio: 2/1), only screen and (min-device-pixel-ratio: 2), only screen and (min-resolution: 192dpi), only screen and (min-resolution: 2dppx) {
form button.user-selection .profile-image {
background-image: url("/resources/images/[email protected]");
background-size: 100px 100px;
}
}
form button.user-selection:hover .profile-image {
background-image: url("/resources/images/icon-user-dark-hover.png");
}
@media only screen and (-webkit-min-device-pixel-ratio: 2), only screen and (min--moz-device-pixel-ratio: 2), only screen and (-o-min-device-pixel-ratio: 2/1), only screen and (min-device-pixel-ratio: 2), only screen and (min-resolution: 192dpi), only screen and (min-resolution: 2dppx) {
form button.user-selection:hover .profile-image {
background-image: url("/resources/images/[email protected]");
background-size: 100px 100px;
}
}
form button.user-selection .sessionstate {
display: inline-block;
height: 20px;
width: 20px;
border-radius: 20px;
border-color: #505050;
border-style: solid;
border-width: 1px;
position: absolute;
bottom: 0px;
right: 10px;
}
form button.user-selection .sessionstate.sessionstate-0 {
background-color: #138D00;
}
form button.user-selection .sessionstate.sessionstate-1 {
background-color: #BC372E;
}
form button.user-selection > div {
position: relative;
}
form button.user-selection > div.names {
margin: 15px;
}
form button.user-selection > div.names .displayname {
font-size: 1.4rem;
}
form button.user-selection > div.names .loginname {
color: #898989;
}
.user-selection + form button.other-user {
margin-top: 80px;
}
form button.other-user .other-user-image {
width: 100px;
height: 75px;
background-repeat: no-repeat;
background-position: center;
background-image: url("/resources/images/icon-newuser-dark.png");
}
@media only screen and (-webkit-min-device-pixel-ratio: 2), only screen and (min--moz-device-pixel-ratio: 2), only screen and (-o-min-device-pixel-ratio: 2/1), only screen and (min-device-pixel-ratio: 2), only screen and (min-resolution: 192dpi), only screen and (min-resolution: 2dppx) {
form button.other-user .other-user-image {
background-image: url("/resources/images/[email protected]");
background-size: 100px 75px;
}
}
form button.other-user:hover .other-user-image {
background-repeat: no-repeat;
background-position: center;
background-image: url("/resources/images/icon-newuser-dark-hover.png");
}
@media only screen and (-webkit-min-device-pixel-ratio: 2), only screen and (min--moz-device-pixel-ratio: 2), only screen and (-o-min-device-pixel-ratio: 2/1), only screen and (min-device-pixel-ratio: 2), only screen and (min-resolution: 192dpi), only screen and (min-resolution: 2dppx) {
form button.other-user:hover .other-user-image {
background-image: url("/resources/images/[email protected]");
background-size: 100px 75px;
}
}
form button.other-user > div:nth-of-type(2) {
margin: 15px;
font-size: 1.4rem;
}
#copy-secret {
visibility: hidden;
position: absolute;
}
#qrcode {
text-align: center;
}
#qrcode svg rect.color {
fill: #BBBBC8;
}
#qrcode svg rect.bg-color {
fill: #282828;
}
#secret .copy {
float: right;
cursor: pointer;
}
footer {
width: 100%;
background-size: cover;
height: 44vw;
position: fixed;
bottom: 0;
z-index: -1;
}
.material-icons {
font-family: "Material Icons";
font-weight: normal;
font-style: normal;
font-size: 24px;
/* Preferred icon size */
display: inline-block;
line-height: 1;
text-transform: none;
letter-spacing: normal;
word-wrap: normal;
white-space: nowrap;
direction: ltr;
/* Support for all WebKit browsers. */
-webkit-font-smoothing: antialiased;
/* Support for Safari and Chrome. */
text-rendering: optimizeLegibility;
/* Support for Firefox. */
-moz-osx-font-smoothing: grayscale;
/* Support for IE. */
font-feature-settings: "liga";
}
/*# sourceMappingURL=dark.css.map */
@@ -0,0 +1 @@
{"version":3,"sourceRoot":"","sources":["../../scss/fonts.scss","../../scss/main.scss","../../scss/variables.scss"],"names":[],"mappings":"AACA;EACI;EACA;;AAIJ;EACI;EACA;EACA;EACA;;AAEJ;EACI;EACA;EACA;EACA;;AAGJ;EACI;EACA;EACA;EACA;;AAEJ;EACI;EACA;EACA;EACA;;AAGJ;EACI;EACA;EACA;EACA;;AAEJ;EACI;EACA;EACA;EACA;;AAGJ;EACI;EACA;EACA;EACA;;AAEJ;EACI;EACA;EACA;EACA;;AAGJ;EACI;EACA;EACA;EACA;;AAEJ;EACI;EACA;EACA;EACA;;AAIJ;EACI;EACA;EACA;EACA;AAA6D;EAC7D;;AC5EJ;EACI;EACA,aCHW;EDIX;EACA;;;AAGJ;EACI;;;AAGJ;EACI;EACA;EACA;EACA,kBCKc;EDJd,OCKQ;EDJR;EACA;EAEI;;;AAIR;EACI,OCJQ;EDKR,aC1BS;ED2BT;EACA;;;AAGJ;EACI;;;AAGJ;EACI;;AAEA;EACI;EACA;EACA;EACA;EACA;;;AAIR;EACI;EACA;EACA;EACA;;;AAGJ;EACI,OCjCW;EDkCX;EACA;;AAEA;EACI,OCrCY;;;ADyCpB;EACI,kBC7Cc;ED8Cd,OC5CW;ED6CX;EACA;EACA;EACA;EACA,QCpEU;EDqEV;EACA;EACA;;AACA;EACI,kBCrDY;EDsDZ;;AAGJ;EACI,kBC3DO;ED4DP,OC7DI;ED8DJ;;AACA;EACI,kBC9DQ;;;ADmEpB;EACI,kBCjEmB;EDkEnB,OCvEQ;EDwER,QC1FU;ED2FV;EACA;EACA;;;AAIA;EACI;EACA;;AAGJ;EACI;;AAEA;EACI;EACA;;AAGJ;EACI;EACA;EACA;EACA;;AAIR;EACI,OClGK;EDmGL;EACA;EACA;;AAEA;EACI;EACA;;AAIR;EACI;;AAEA;EACI;;AAGJ;EACI;;AAIR;EACI;EACA;EACA,OC/HI;EDgIJ;EACA;EACA;EACA;;AAEA;EACI;EACA,kBClIW;;ADqIf;EACI;;AAIR;EACI;;AAIA;EACI;EACA;EC/JV;;AACA;ED4JM;IC3JJ;IACA;;;ADiKQ;ECpKV;;AACA;EDmKU;IClKR;IACA;;;ADsKI;EACI;EACA;EACA;EACA;EACA,cCjKO;EDkKP;EACA;EACA;EACA;EACA;;AAEA;EACI;;AAGJ;EACI;;AAKR;EACI;;AAEA;EACI;;AAEA;EACI;;AAEJ;EACI,OC7LP;;ADoML;EACI;;AAEJ;EACI;EACA;EACA;EACA;ECvNV;;AACA;EDkNM;ICjNJ;IACA;;;ADyNQ;EACI;EACA;EC9Nd;;AACA;ED2NU;IC1NR;IACA;;;ADgOI;EACI;EACA;;;AAKZ;EACI;EACA;;;AAGJ;EACI;;AAEA;EACI,MC1OI;;AD6OR;EACI,MC/OU;;;ADoPd;EACI;EACA;;;AAIR;EAII;EACA;EACA;EACA;EACA;EACA;;;AAGJ;EACI;EACA;EACA;EACA;AAAkB;EAClB;EACA;EACA;EACA;EACA;EACA;EACA;AAEA;EACA;AACA;EACA;AAEA;EACA;AAEA;EACA","file":"dark.css"}
@@ -0,0 +1,438 @@
@font-face {
font-family: Aileron;
src: url(../../../fonts/ailerons/ailerons.otf) format("opentype");
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-Thin.ttf) format("truetype");
font-style: normal;
font-weight: 100;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-ThinItalic.ttf) format("truetype");
font-style: italic;
font-weight: 100;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-Light.ttf) format("truetype");
font-style: normal;
font-weight: 200;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-LightItalic.ttf) format("truetype");
font-style: italic;
font-weight: 200;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-Regular.ttf) format("truetype");
font-style: normal;
font-weight: 400;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-Italic.ttf) format("truetype");
font-style: italic;
font-weight: 400;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-Bold.ttf) format("truetype");
font-style: normal;
font-weight: 700;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-BoldItalic.ttf) format("truetype");
font-style: italic;
font-weight: 700;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-Black.ttf) format("truetype");
font-style: normal;
font-weight: 800;
}
@font-face {
font-family: Lato;
src: url(../../../fonts/lato/Lato-BlackItalic.ttf) format("truetype");
font-style: italic;
font-weight: 800;
}
@font-face {
font-family: "Material Icons";
font-style: normal;
font-weight: 400;
src: url(../../../fonts/material/MaterialIcons-Regular.eot);
/* For IE6-8 */
src: local("Material Icons"), local("MaterialIcons-Regular"), url(../../../fonts/material/MaterialIcons-Regular.woff2) format("woff2"), url(../../../fonts/material/MaterialIcons-Regular.woff) format("woff"), url(../../../fonts/material/MaterialIcons-Regular.ttf) format("truetype");
}
*, *::before, *::after {
box-sizing: border-box;
font-family: Lato;
font-size: 18px;
font-weight: 400;
}
body {
margin: 0;
}
html {
height: 100%;
width: 100%;
font-weight: 300;
background-color: #282828;
color: #BBBBC8;
background-repeat: no-repeat;
background-position: bottom right;
background-image: url("../flavor-spikes01-narrow.png");
}
h1 {
color: #BBBBC8;
font-family: Lato;
font-weight: 300;
font-size: 40px;
}
p {
font-weight: 300;
}
header {
padding: 8px;
}
header .logo {
background-image: url("../logo-dark.png");
background-repeat: no-repeat;
background-size: contain;
height: 80px;
margin: 30px;
}
.content {
margin: auto;
padding: 20px;
width: 100%;
max-width: 500px;
}
a {
color: #3574C6;
text-decoration: none;
font-weight: 400;
}
a:hover {
color: #5b8fd3;
}
button {
background-color: #282828;
color: #3574C6;
border: 2px solid #3574C6;
border-radius: 5px;
width: 100%;
max-width: 600px;
height: 50px;
transition: all 0.3s ease 0s;
cursor: pointer;
outline: none;
}
button:hover {
background-color: #5b8fd3;
border: 2px solid #5b8fd3;
}
button.primary {
background-color: #3574C6;
color: #BBBBC8;
border: none;
}
button.primary:hover {
background-color: #5b8fd3;
}
input:not([type=radio]), select {
background-color: #252525;
color: #BBBBC8;
height: 50px;
border: 2px solid #505050;
border-radius: 5px;
padding-left: 15px;
}
form .field {
display: grid;
padding: 10px 0;
}
form .field.radio-button {
display: flex;
}
form .field.radio-button input[type=radio] {
height: 20px;
vertical-align: middle;
}
form .field.radio-button label {
height: 20px;
display: inline-block;
padding: 3px 0 0 15px;
width: 100%;
}
form label {
color: #898989;
text-transform: uppercase;
font-size: 0.9rem;
margin-bottom: 3px;
}
form label span.optional {
font-style: italic;
text-transform: none;
}
form .actions {
padding: 20px 0;
}
form .actions .right {
float: right;
}
form .actions button, form .actions a {
margin: 10px 0;
}
form button.clean {
border: none;
height: auto;
color: #BBBBC8;
text-align: left;
text-transform: unset;
display: flex;
padding: 15px;
}
form button.clean:hover {
border: none;
background-color: #252525;
}
form button.clean * {
font-weight: 300;
}
form .user-selection-list {
margin-bottom: 80px;
}
form button.user-selection .profile-image {
width: 100px;
height: 100px;
background-image: url("/resources/images/icon-user-dark.png");
}
@media only screen and (-webkit-min-device-pixel-ratio: 2), only screen and (min--moz-device-pixel-ratio: 2), only screen and (-o-min-device-pixel-ratio: 2/1), only screen and (min-device-pixel-ratio: 2), only screen and (min-resolution: 192dpi), only screen and (min-resolution: 2dppx) {
form button.user-selection .profile-image {
background-image: url("/resources/images/[email protected]");
background-size: 100px 100px;
}
}
form button.user-selection:hover .profile-image {
background-image: url("/resources/images/icon-user-dark-hover.png");
}
@media only screen and (-webkit-min-device-pixel-ratio: 2), only screen and (min--moz-device-pixel-ratio: 2), only screen and (-o-min-device-pixel-ratio: 2/1), only screen and (min-device-pixel-ratio: 2), only screen and (min-resolution: 192dpi), only screen and (min-resolution: 2dppx) {
form button.user-selection:hover .profile-image {
background-image: url("/resources/images/[email protected]");
background-size: 100px 100px;
}
}
form button.user-selection .sessionstate {
display: inline-block;
height: 20px;
width: 20px;
border-radius: 20px;
border-color: #505050;
border-style: solid;
border-width: 1px;
position: absolute;
bottom: 0px;
right: 10px;
}
form button.user-selection .sessionstate.sessionstate-0 {
background-color: #138D00;
}
form button.user-selection .sessionstate.sessionstate-1 {
background-color: #BC372E;
}
form button.user-selection > div {
position: relative;
}
form button.user-selection > div.names {
margin: 15px;
}
form button.user-selection > div.names .displayname {
font-size: 1.4rem;
}
form button.user-selection > div.names .loginname {
color: #898989;
}
.user-selection + form button.other-user {
margin-top: 80px;
}
form button.other-user .other-user-image {
width: 100px;
height: 75px;
background-repeat: no-repeat;
background-position: center;
background-image: url("/resources/images/icon-newuser-dark.png");
}
@media only screen and (-webkit-min-device-pixel-ratio: 2), only screen and (min--moz-device-pixel-ratio: 2), only screen and (-o-min-device-pixel-ratio: 2/1), only screen and (min-device-pixel-ratio: 2), only screen and (min-resolution: 192dpi), only screen and (min-resolution: 2dppx) {
form button.other-user .other-user-image {
background-image: url("/resources/images/[email protected]");
background-size: 100px 75px;
}
}
form button.other-user:hover .other-user-image {
background-repeat: no-repeat;
background-position: center;
background-image: url("/resources/images/icon-newuser-dark-hover.png");
}
@media only screen and (-webkit-min-device-pixel-ratio: 2), only screen and (min--moz-device-pixel-ratio: 2), only screen and (-o-min-device-pixel-ratio: 2/1), only screen and (min-device-pixel-ratio: 2), only screen and (min-resolution: 192dpi), only screen and (min-resolution: 2dppx) {
form button.other-user:hover .other-user-image {
background-image: url("/resources/images/[email protected]");
background-size: 100px 75px;
}
}
form button.other-user > div:nth-of-type(2) {
margin: 15px;
font-size: 1.4rem;
}
#copy-secret {
visibility: hidden;
position: absolute;
}
#qrcode {
text-align: center;
}
#qrcode svg rect.color {
fill: #BBBBC8;
}
#qrcode svg rect.bg-color {
fill: #282828;
}
#secret .copy {
float: right;
cursor: pointer;
}
footer {
width: 100%;
background-size: cover;
height: 44vw;
position: fixed;
bottom: 0;
z-index: -1;
}
.material-icons {
font-family: "Material Icons";
font-weight: normal;
font-style: normal;
font-size: 24px;
/* Preferred icon size */
display: inline-block;
line-height: 1;
text-transform: none;
letter-spacing: normal;
word-wrap: normal;
white-space: nowrap;
direction: ltr;
/* Support for all WebKit browsers. */
-webkit-font-smoothing: antialiased;
/* Support for Safari and Chrome. */
text-rendering: optimizeLegibility;
/* Support for Firefox. */
-moz-osx-font-smoothing: grayscale;
/* Support for IE. */
font-feature-settings: "liga";
}
html {
background-color: #BBBBC8;
color: #282828;
background-image: url("../flavor-spikes01-narrow.png");
}
html header .logo {
background-image: url("../logo-light.png");
}
html h1 {
color: #282828;
}
html button {
background-color: #BBBBC8;
color: #3574C6;
border: 2px solid #3574C6;
}
html button:hover {
background-color: #5b8fd3;
border: 2px solid #5b8fd3;
}
html button.primary {
background-color: #3574C6;
color: #BBBBC8;
border: none;
box-shadow: 0px 10px 30px #3574C6;
}
html button.primary:hover {
background-color: #5b8fd3;
}
html button.clean {
color: #282828;
}
html button.user-selection .profile-image {
background-image: url("/resources/images/icon-user-light.png");
}
@media only screen and (-webkit-min-device-pixel-ratio: 2), only screen and (min--moz-device-pixel-ratio: 2), only screen and (-o-min-device-pixel-ratio: 2/1), only screen and (min-device-pixel-ratio: 2), only screen and (min-resolution: 192dpi), only screen and (min-resolution: 2dppx) {
html button.user-selection .profile-image {
background-image: url("/resources/images/[email protected]");
background-size: 100px 100px;
}
}
html button.user-selection:hover {
background-color: #252525;
}
html button.user-selection:hover .profile-image {
background-image: url("/resources/images/icon-user-light-hover.png");
}
@media only screen and (-webkit-min-device-pixel-ratio: 2), only screen and (min--moz-device-pixel-ratio: 2), only screen and (-o-min-device-pixel-ratio: 2/1), only screen and (min-device-pixel-ratio: 2), only screen and (min-resolution: 192dpi), only screen and (min-resolution: 2dppx) {
html button.user-selection:hover .profile-image {
background-image: url("/resources/images/[email protected]");
background-size: 100px 100px;
}
}
html button.other-user .other-user-image {
background-image: url("/resources/images/icon-newuser-light.png");
}
@media only screen and (-webkit-min-device-pixel-ratio: 2), only screen and (min--moz-device-pixel-ratio: 2), only screen and (-o-min-device-pixel-ratio: 2/1), only screen and (min-device-pixel-ratio: 2), only screen and (min-resolution: 192dpi), only screen and (min-resolution: 2dppx) {
html button.other-user .other-user-image {
background-image: url("/resources/images/[email protected]");
background-size: 100px 75px;
}
}
html button.other-user:hover .other-user-image {
background-image: url("/resources/images/icon-newuser-light-hover.png");
}
@media only screen and (-webkit-min-device-pixel-ratio: 2), only screen and (min--moz-device-pixel-ratio: 2), only screen and (-o-min-device-pixel-ratio: 2/1), only screen and (min-device-pixel-ratio: 2), only screen and (min-resolution: 192dpi), only screen and (min-resolution: 2dppx) {
html button.other-user:hover .other-user-image {
background-image: url("/resources/images/[email protected]");
background-size: 100px 75px;
}
}
html input {
background-color: #BBBBC8;
color: #282828;
}
html #qrcode svg rect.color {
fill: #282828;
}
html #qrcode svg rect.bg-color {
fill: #BBBBC8;
}
/*# sourceMappingURL=light.css.map */
@@ -0,0 +1 @@
{"version":3,"sourceRoot":"","sources":["../../scss/fonts.scss","../../scss/main.scss","../../scss/variables.scss","../../scss/light.scss"],"names":[],"mappings":"AACA;EACI;EACA;;AAIJ;EACI;EACA;EACA;EACA;;AAEJ;EACI;EACA;EACA;EACA;;AAGJ;EACI;EACA;EACA;EACA;;AAEJ;EACI;EACA;EACA;EACA;;AAGJ;EACI;EACA;EACA;EACA;;AAEJ;EACI;EACA;EACA;EACA;;AAGJ;EACI;EACA;EACA;EACA;;AAEJ;EACI;EACA;EACA;EACA;;AAGJ;EACI;EACA;EACA;EACA;;AAEJ;EACI;EACA;EACA;EACA;;AAIJ;EACI;EACA;EACA;EACA;AAA6D;EAC7D;;AC5EJ;EACI;EACA,aCHW;EDIX;EACA;;;AAGJ;EACI;;;AAGJ;EACI;EACA;EACA;EACA,kBCKc;EDJd,OCKQ;EDJR;EACA;EAEI;;;AAIR;EACI,OCJQ;EDKR,aC1BS;ED2BT;EACA;;;AAGJ;EACI;;;AAGJ;EACI;;AAEA;EACI;EACA;EACA;EACA;EACA;;;AAIR;EACI;EACA;EACA;EACA;;;AAGJ;EACI,OCjCW;EDkCX;EACA;;AAEA;EACI,OCrCY;;;ADyCpB;EACI,kBC7Cc;ED8Cd,OC5CW;ED6CX;EACA;EACA;EACA;EACA,QCpEU;EDqEV;EACA;EACA;;AACA;EACI,kBCrDY;EDsDZ;;AAGJ;EACI,kBC3DO;ED4DP,OC7DI;ED8DJ;;AACA;EACI,kBC9DQ;;;ADmEpB;EACI,kBCjEmB;EDkEnB,OCvEQ;EDwER,QC1FU;ED2FV;EACA;EACA;;;AAIA;EACI;EACA;;AAGJ;EACI;;AAEA;EACI;EACA;;AAGJ;EACI;EACA;EACA;EACA;;AAIR;EACI,OClGK;EDmGL;EACA;EACA;;AAEA;EACI;EACA;;AAIR;EACI;;AAEA;EACI;;AAGJ;EACI;;AAIR;EACI;EACA;EACA,OC/HI;EDgIJ;EACA;EACA;EACA;;AAEA;EACI;EACA,kBClIW;;ADqIf;EACI;;AAIR;EACI;;AAIA;EACI;EACA;EC/JV;;AACA;ED4JM;IC3JJ;IACA;;;ADiKQ;ECpKV;;AACA;EDmKU;IClKR;IACA;;;ADsKI;EACI;EACA;EACA;EACA;EACA,cCjKO;EDkKP;EACA;EACA;EACA;EACA;;AAEA;EACI;;AAGJ;EACI;;AAKR;EACI;;AAEA;EACI;;AAEA;EACI;;AAEJ;EACI,OC7LP;;ADoML;EACI;;AAEJ;EACI;EACA;EACA;EACA;ECvNV;;AACA;EDkNM;ICjNJ;IACA;;;ADyNQ;EACI;EACA;EC9Nd;;AACA;ED2NU;IC1NR;IACA;;;ADgOI;EACI;EACA;;;AAKZ;EACI;EACA;;;AAGJ;EACI;;AAEA;EACI,MC1OI;;AD6OR;EACI,MC/OU;;;ADoPd;EACI;EACA;;;AAIR;EAII;EACA;EACA;EACA;EACA;EACA;;;AAGJ;EACI;EACA;EACA;EACA;AAAkB;EAClB;EACA;EACA;EACA;EACA;EACA;EACA;AAEA;EACA;AACA;EACA;AAEA;EACA;AAEA;EACA;;;AEjTJ;EACI,kBDqBQ;ECpBR,ODmBc;ECjBV;;AAGJ;EACI;;AAGJ;EACI,ODSU;;ACNd;EACI,kBDMI;ECLJ,ODMO;ECLP;;AAEA;EACI,kBDgBa;ECfb;;AAGJ;EACI,kBDHG;ECIH,ODLA;ECMA;EACA;;AACA;EACI,kBDPI;;ACWZ;EACI,ODfM;;ACmBN;ED3BV;;AACA;EC0BU;IDzBR;IACA;;;AC4BQ;EACI,kBDlBO;;ACoBP;EDlCd;;AACA;ECiCc;IDhCZ;IACA;;;ACsCQ;EDzCV;;AACA;ECwCU;IDvCR;IACA;;;AC2CY;ED9Cd;;AACA;EC6Cc;ID5CZ;IACA;;;ACkDA;EACI,kBD7CI;EC8CJ,OD/CU;;ACmDV;EACI,MDpDM;;ACuDV;EACI,MDvDA","file":"light.css"}
Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 361 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 51 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 19 KiB

@@ -0,0 +1,34 @@
{{template "main-top" .}}
<h1>{{t "PasswordChange.Title"}}</h1>
<p>{{t "PasswordChange.Description"}}</p>
<form action="{{ changePasswordUrl }}" method="POST">
{{ .CSRF }}
<input type="hidden" name="authRequestID" value="{{ .AuthReqID }}" />
<div class="fields">
<div class="field">
<label class="label" for="old_password">{{t "PasswordChange.OldPassword"}}</label>
<input class="input" type="password" id="old_password" name="old_password" autocomplete="current-password" autofocus required>
</div>
<div class="field">
<label class="label" for="new_password">{{t "PasswordChange.NewPassword"}}</label>
<input class="input" type="password" id="new-password" name="new_password" autocomplete="new-password" required>
</div>
</div>
{{ template "error-message" .}}
<div class="actions">
<button type="submit" name="resend" value="false" class="primary right" >{{t "Actions.Next"}}</buttontype="submit">
</div>
</form>
{{template "main-bottom" .}}
@@ -0,0 +1,21 @@
{{template "main-top" .}}
<h1>{{t "PasswordChangeDone.Title"}}</h1>
<p>{{t "PasswordChangeDone.Description"}}</p>
<form action="{{ loginUrl }}" method="POST">
{{ .CSRF }}
<input type="hidden" name="authRequestID" value="{{ .AuthReqID }}" />
<div class="actions">
<button class="primary right" type="submit">{{t "Actions.Next"}}</button>
</div>
</form>
{{template "main-bottom" .}}
@@ -0,0 +1,9 @@
{{ define "error-message" }}
{{if .ErrMessage }}
<div class="field">
<div class="error">
{{ if .ErrType }}{{ .ErrType }} - {{end}}{{ .ErrMessage }}
</div>
</div>
{{end}}
{{ end }}
@@ -0,0 +1,9 @@
{{template "main-top" .}}
<div>
{{ .ErrType }}
{{ .ErrMessage }}
</div>
{{template "main-bottom" .}}
@@ -0,0 +1,3 @@
{{define "footer"}}
{{end}}
@@ -0,0 +1,3 @@
{{define "header"}}
<div class="logo"></div>
{{end}}selec
@@ -0,0 +1,39 @@
{{template "main-top" .}}
<h1>{{t "InitPassword.Title" }}</h1>
<p>{{t "InitPassword.Description" }}</p>
<form action="{{ initPasswordUrl }}" method="POST">
{{ .CSRF }}
<input type="hidden" name="authRequestID" value="{{ .AuthReqID }}" />
<input type="hidden" name="userID" value="{{ .UserID }}" />
<div class="fields">
<div class="field">
<label class="label" for="code">{{t "InitPassword.Code"}}</label>
<input class="input" type="text" id="code" name="code" value="{{.Code}}" autocomplete="off" autofocus required>
</div>
<div class="field">
<label class="label" for="password">{{t "InitPassword.NewPassword"}}</label>
<input class="input" type="password" id="password" name="password" autocomplete="new-password" autofocus required>
</div>
<div class="field">
<label class="label" for="passwordconfirm">{{t "InitPassword.NewPasswordConfirm"}}</label>
<input class="input" type="password" id="passwordconfirm" name="passwordconfirm" autocomplete="new-password" autofocus required>
</div>
</div>
{{ template "error-message" .}}
<div class="actions">
<button type="submit" name="resend" value="false" class="primary right" >{{t "Actions.Next"}}</buttontype="submit">
<button type="submit" name="resend" value="true" class="secondary right" formnovalidate>{{t "Actions.Resend" }}</button>
</div>
</form>
{{template "main-bottom" .}}
@@ -0,0 +1,19 @@
{{template "main-top" .}}
<h1>{{t "PasswordSetDone.Title"}}</h1>
<p>{{t "PasswordSetDone.Description"}}</p>
<form action="{{ loginUrl }}" method="POST">
{{ .CSRF }}
<input type="hidden" name="authRequestID" value="{{ .AuthReqID }}" />
<div class="actions">
<button class="primary right" type="submit">{{t "Actions.Next"}}</button>
</div>
</form>
{{template "main-bottom" .}}
@@ -0,0 +1,42 @@
{{template "main-top" .}}
<h1>{{t "InitUser.Title" }}</h1>
<p>{{t "InitUser.Description" }}</p>
<form action="{{ initUserUrl }}" method="POST">
{{ .CSRF }}
<input type="hidden" name="authRequestID" value="{{ .AuthReqID }}" />
<input type="hidden" name="userID" value="{{ .UserID }}" />
<input type="hidden" name="passwordSet" value="{{ .PasswordSet }}" />
<div class="fields">
<div class="field">
<label class="label" for="code">{{t "InitUser.Code"}}</label>
<input class="input" type="text" id="code" name="code" value="{{.Code}}" autocomplete="off" autofocus required>
</div>
{{ if not .PasswordSet }}
<div class="field">
<label class="label" for="password">{{t "InitUser.NewPassword"}}</label>
<input class="input" type="password" id="password" name="password" autocomplete="new-password" autofocus required>
</div>
<div class="field">
<label class="label" for="passwordconfirm">{{t "InitUser.NewPasswordConfirm"}}</label>
<input class="input" type="password" id="passwordconfirm" name="passwordconfirm" autocomplete="new-password" autofocus required>
</div>
{{ end }}
</div>
{{ template "error-message" .}}
<div class="actions">
<button type="submit" name="resend" value="false" class="primary right" >{{t "Actions.Next"}}</button>
<button type="submit" name="resend" value="true" class="secondary right" formnovalidate>{{t "Actions.Resend" }}</button>
</div>
</form>
{{template "main-bottom" .}}
@@ -0,0 +1,19 @@
{{template "main-top" .}}
<h1>{{t "InitUserDone.Title"}}</h1>
<p>{{t "InitUserDone.Description"}}</p>
<form action="{{ loginUrl }}" method="POST">
{{ .CSRF }}
<input type="hidden" name="authRequestID" value="{{ .AuthReqID }}" />
<div class="actions">
<button class="primary right" type="submit">{{t "Actions.Next"}}</button>
</div>
</form>
{{template "main-bottom" .}}
@@ -0,0 +1,30 @@
{{template "main-top" .}}
<h1>{{t "Login.Title"}}</h1>
<p>{{t "Login.Description"}}</p>
<form action="{{ loginNameUrl }}" method="POST">
{{ .CSRF }}
<input type="hidden" name="authRequestID" value="{{ .AuthReqID }}" />
<div class="fields">
<div class="field">
<label class="label" for="loginName">{{t "Login.Loginname"}}</label>
<input class="input" type="text" id="loginName" name="loginName" placeholder="{{t "Login.LoginnamePlaceHolder"}}" value="{{ .LoginName }}" autocomplete="username" autofocus required>
</div>
</div>
{{template "error-message" .}}
<div class="actions">
<button class="primary right" type="submit">{{t "Actions.Next"}}</button>
<a class="default right" href="{{ registerUrl .AuthReqID }}" >{{t "Actions.Register"}}</a>
</div>
</form>
{{template "main-bottom" .}}
@@ -0,0 +1,17 @@
{{template "main-top" .}}
<h1>{{t "LogoutDone.Title"}}</h1>
<p>{{t "LogoutDone.Description"}}</p>
<form action="{{ loginUrl }}" method="POST">
{{ .CSRF }}
<div class="actions">
<button class="primary right" type="submit">{{t "Actions.Login"}}</button>
</div>
</form>
{{template "main-bottom" .}}
@@ -0,0 +1,33 @@
{{template "main-top" .}}
<h1>{{t "EmailVerification.Title"}}</h1>
<p>{{t "EmailVerification.Description"}}</p>
<form action="{{ mailVerificationUrl }}" method="POST">
{{ .CSRF }}
<input type="hidden" name="authRequestID" value="{{ .AuthReqID }}" />
<input type="hidden" name="userID" value="{{ .UserID }}" />
<div class="fields">
<div class="field">
<label class="label" for="code">{{t "EmailVerification.Code"}}</label>
<input class="input" type="text" id="code" name="code" autocomplete="off" autofocus required>
</div>
</div>
{{ template "error-message" .}}
<div class="actions">
<button type="submit" name="resend" value="false" class="primary right" >{{t "Actions.Next"}}</buttontype="submit">
{{ if .UserID }}
<button type="submit" name="resend" value="true" class="secondary right" formnovalidate>{{t "Actions.Resend"}}</button>
{{ end }}
</div>
</form>
{{template "main-bottom" .}}
@@ -0,0 +1,21 @@
{{template "main-top" .}}
<h1>{{t "EmailVerificationDone.Title"}}</h1>
<p>{{t "EmailVerificationDone.Description"}}</p>
<form action="{{ loginUrl }}" method="POST">
{{ .CSRF }}
<input type="hidden" name="authRequestID" value="{{ .AuthReqID }}" />
<div class="actions">
<button class="primary right" type="submit">{{if .AuthReqID }}{{t "Actions.Next"}}{{else}}{{t "Actions.Login"}}{{end}}</button>
</div>
</form>
{{template "main-bottom" .}}

Some files were not shown because too many files have changed in this diff Show More