initial commit

This commit is contained in:
2025-06-25 10:06:01 -05:00
commit 4d669317c4
17 changed files with 706 additions and 0 deletions

View File

@@ -0,0 +1,18 @@
<!doctype html>
<html>
<head>
<title>Approve Image</title>
<link rel="stylesheet" href="/assets/css/main.css" />
<script src="/assets/js/main.js"></script>
</head>
<body>
<div>{{.SVG | safeHTML}}</div>
<form action="/approve-icon" method="post">
<select name="approved">
<option value="yes">Yes</option>
<option value="no">No</option>
</select>
<input type="submit" value="Submit" />
</form>
</body>
</html>

View File

@@ -0,0 +1,20 @@
<!DOCTYPE >
<html>
<head>
<title>Create Icons</title>
<script src="/assets/tailwind.js"></script>
</head>
<body>
<h1>Create Icons</h1>
<form action="/prompt-icon" method="post">
<textarea
name="prompt"
rows="10"
cols="20"
placeholder="Icon Prompt"
required
></textarea>
<input type="submit" name="Submit" />
</form>
</body>
</html>

6
templates/embedded.go Normal file
View File

@@ -0,0 +1,6 @@
package templates
import "embed"
//go:embed *
var TemplateFS embed.FS

15
templates/home.html Normal file
View File

@@ -0,0 +1,15 @@
<!doctype html>
<html lang="en">
<head>
<title>Home</title>
<link rel="stylesheet" href="/assets/css/main.css" />
<script src="/assets/js/main.js"></script>
</head>
<body>
<div id="pages">
<h2>Pages</h2>
<a href="view-all-icons">View Icons</a>
<a href="create-icon">Create Icons</a>
</div>
</body>
</html>

View File

@@ -0,0 +1,25 @@
<!doctype html>
<html lang="en">
<head>
<title>nKode Icon Manager</title>
<link rel="stylesheet" href="/assets/css/main.css" />
<script src="/assets/js/main.js"></script>
</head>
<body>
<h1>Number of SVGs: {{.SVGCount}}</h1>
<div id="svg-grid">
{{ range .SVGs }}
<div class="grid-item">
<div id="{{.Name}}" onclick="iconClick('{{.Name}}')" o>
{{.SVG | safeHTML}}
</div>
<div>{{.Name}}</div>
</div>
{{else}}
<h1>No SVGs Found</h1>
<p>no svgs in: {{.Path}}</p>
{{end}}
</div>
<button type="button" onclick="deleteSelected()">Delete Selected</button>
</body>
</html>