From 7f8ad1523e1a924e05ffffb8283e0b213d057a6e Mon Sep 17 00:00:00 2001 From: Aceix Date: Wed, 4 Jan 2023 18:53:55 +0000 Subject: [PATCH] feat(GRA-763): add success and error SSO HTML templates --- auth/templates.go | 154 ++++++++++++++++++++++++++++++---------------- 1 file changed, 101 insertions(+), 53 deletions(-) diff --git a/auth/templates.go b/auth/templates.go index 65f5d124..52b9cd52 100644 --- a/auth/templates.go +++ b/auth/templates.go @@ -10,72 +10,120 @@ type ssoCallbackTemplateConfig struct { var ssoCallbackTemplate = template.Must( template.New("ssocallback").Parse(` + - - - - - Netmaker + + + + Netmaker :: SSO Success + + - + -
-
- - Netmaker - -
-
-
-

{{.User}} has been successfully {{.Verb}}

-
-

You may now close this window.

-
-
-
+ +

Server SSO Success

+

User {{.User}} has been successfully {{.Verb}}.

+

You can close this window now

+ `), ) var ssoErrCallbackTemplate = template.Must( template.New("ssocallback").Parse(` + - - - - - Netmaker + + + + Netmaker :: SSO Error + + - + -
-
- - Netmaker - -
-
-
-

{{.User}} unable to join network: {{.Verb}}

-
-

If you feel this is a mistake, please contact your network administrator.

-
-
-
+ +

Server SSO Error

+

Error reason: {.Verb}

+ Your Netmaker server may not have SSO configured properly. + + Please visit the docs for more information. + +

+ If you feel this is a mistake, please contact your network administrator. +

+ `), )