-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Showing
4 changed files
with
127 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
package template | ||
|
||
import ( | ||
"embed" | ||
"html/template" | ||
) | ||
|
||
//go:embed * | ||
var files embed.FS | ||
|
||
type Template string | ||
|
||
const ( | ||
TemplateSuccessPage Template = "success.gohtml" | ||
) | ||
|
||
func GetTemplate(t Template) *template.Template { | ||
return template.Must(template.New(string(t)). | ||
ParseFS(files, string(t))) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,81 @@ | ||
<!doctype html> | ||
<head> | ||
<!-- Required meta tags --> | ||
<meta charset="utf-8"> | ||
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no"> | ||
<!-- Bulma CSS --> | ||
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/[email protected]/css/bulma.min.css"> | ||
<title>Success!</title> | ||
|
||
<style> | ||
:root { | ||
--color-heading: hsl(196, 10%, 10%); | ||
--color-text: hsl(192, 10%, 20%); | ||
--color-primary: hsl(149, 100%, 30%); | ||
--color-primary-hover: hsl(149, 100%, 28%); | ||
} | ||
.message-wrapper { | ||
height: 100vh; | ||
width: 100%; | ||
display: flex; | ||
align-items: center; | ||
justify-content: center; | ||
.message-inner { | ||
max-width: 800px; | ||
margin: 30px; | ||
&.has-text-centered { | ||
max-width: 600px; | ||
.icon { | ||
margin: 0 auto; | ||
} | ||
p { | ||
text-wrap: balance; | ||
} | ||
} | ||
.icon { | ||
width: 96px; | ||
height: auto; | ||
display: flex; | ||
align-items: center; | ||
margin-bottom: 8px; | ||
} | ||
h1 { | ||
font-size: 64px; | ||
margin-bottom: 8px; | ||
color: var(--color-heading); | ||
line-height: 1; | ||
font-weight: 700; | ||
} | ||
p { | ||
font-size: 16px; | ||
margin-bottom: 16px; | ||
color: var(--color-text); | ||
} | ||
} | ||
} | ||
.button{ | ||
font-weight: 500; | ||
border-radius: 2px; | ||
&.is-primary { | ||
background-color: var(--color-primary); | ||
&:hover { | ||
background-color: var(--color-primary-hover); | ||
} | ||
} | ||
} | ||
</style> | ||
</head> | ||
<body> | ||
<div class="message-wrapper"> | ||
<div class="message-inner has-text-centered"> | ||
<div class="icon"> | ||
<!-- Why it's not working? ./icons/checked.png --> | ||
<img src="https://img.icons8.com/tiny-color/128/000000/ok.png" alt="ok"/> | ||
</div> | ||
<h1>Success!</h1> | ||
<p>Now you can create selected resources to your consumer cluster. <br><b>Please head back to the command line.</b></p> | ||
<a href="{{.RedirectURL}}" class="button is-primary">Go to Provider</a> | ||
</div> | ||
</div> | ||
</body> | ||
</html> |