Empty space on image pages is now clickable, and returns a new random image

This commit is contained in:
Seednode 2022-10-28 19:52:53 -05:00
parent 97e3b47b19
commit ad6d7e2cd3
2 changed files with 6 additions and 3 deletions

View File

@ -10,7 +10,7 @@ import (
"github.com/spf13/cobra"
)
var Version = "0.20.3"
var Version = "0.20.4"
func init() {
rootCmd.AddCommand(versionCmd)

View File

@ -162,7 +162,10 @@ func serveHtml(w http.ResponseWriter, r *http.Request, filePath, dimensions stri
htmlBody := `<html lang="en">
<head>
<style>img{max-width:100%;max-height:97vh;height:auto;}</style>
<style>
a{display:block;height:100%;width:100%;text-decoration:none}
img{max-width:100%;max-height:97vh;height:auto;}
</style>
<title>`
htmlBody += fmt.Sprintf("%v (%v)", fileName, dimensions)
htmlBody += `</title>