Skip to content
This repository has been archived by the owner on Apr 4, 2023. It is now read-only.

Commit

Permalink
remove space in logo, add logo to http root endpoint response
Browse files Browse the repository at this point in the history
  • Loading branch information
farshidtz committed Mar 19, 2021
1 parent 771d329 commit f630e81
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
6 changes: 3 additions & 3 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,9 @@ import (
)

const LINKSMART = `
╦ ╦ ╔╗╔ ╦╔═ ╔═╗ ╔╦╗ ╔═╗ ╦═╗ ╔╦╗
║ ║ ║║║ ╠╩╗ ╚═╗ ║║║ ╠═╣ ╠╦╝ ║
╩═╝ ╩ ╝╚╝ ╩ ╩ ╚═╝ ╩ ╩ ╩ ╩ ╩╚═ ╩
╦ ╦ ╔╗╔ ╦╔═ ╔═╗ ╔╦╗ ╔═╗ ╦═╗ ╔╦╗
║ ║ ║║║ ╠╩╗ ╚═╗ ║║║ ╠═╣ ╠╦╝ ║
╩═╝ ╩ ╝╚╝ ╩ ╩ ╚═╝ ╩ ╩ ╩ ╩ ╩╚═ ╩
`

const (
Expand Down
7 changes: 4 additions & 3 deletions router.go
Original file line number Diff line number Diff line change
Expand Up @@ -73,11 +73,12 @@ func indexHandler(w http.ResponseWriter, _ *http.Request) {
w.Header().Set("Content-Type", "text/html")

data := struct {
Version, SourceRepo, Spec, SwaggerUIRelativeScheme, SwaggerUISecure string
}{version, SourceCodeRepo, spec, swaggerUIRelativeScheme, swaggerUISecure}
Logo, Version, SourceRepo, Spec, SwaggerUIRelativeScheme, SwaggerUISecure string
}{LINKSMART, version, SourceCodeRepo, spec, swaggerUIRelativeScheme, swaggerUISecure}

tmpl := `
<h1>LinkSmart Thing Directory</h1>
<pre>{{.Logo}}</pre>
<h1>Thing Directory</h1>
<p>Version: {{.Version}}</p>
<p><a href="{{.SourceRepo}}">{{.SourceRepo}}</a></p>
<p>API Documentation: <a href="{{.SwaggerUISecure}}/?url={{.Spec}}">Swagger UI</a></p>
Expand Down

0 comments on commit f630e81

Please sign in to comment.