Skip to content

Commit

Permalink
switch to Roboto everywhere (no Yanone, nor Roboto Condensed) (#172)
Browse files Browse the repository at this point in the history
switch to `Roboto`everywhere (no Yanone, no Roboto Condensed)

Co-authored-by: Konstantin <[email protected]>
  • Loading branch information
hf-kklein and Konstantin authored Jan 27, 2025
1 parent da9e03f commit 174be05
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 49 deletions.
22 changes: 4 additions & 18 deletions cmd/api.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,7 @@ func NewRouter() *gin.Engine {
router.GET("/", generateRandomId)
router.GET("/style", stylesheetHandler)
router.GET("/hfstyle", hochfrequenzStylesheetHandler)
router.GET("/yanone-kaffeesatz-bold", yanoneKaffeesatzBoldHandler)
router.GET("/roboto-condensed-regular", robotoCondensedRegularHandler)
router.GET("/roboto-regular", robotoRegularHandler)
router.GET("/logo", logoHandler)
router.GET("/symbol", symbolHandler)
router.GET("/favicon", faviconHandler)
Expand Down Expand Up @@ -92,12 +91,9 @@ var stylesheet embed.FS
//go:embed static/companystylesheet/css/hochfrequenz.css
var hochfrequenzStylesheet embed.FS

//go:embed static/companystylesheet/fonts/Roboto_Condensed/RobotoCondensed-Regular.ttf
//go:embed static/companystylesheet/fonts/Roboto/Roboto-Regular.ttf
var robotoRegularFont embed.FS

//go:embed static/companystylesheet/fonts/YanoneKaffeesatzTTF/YanoneKaffeesatz-Bold.ttf
var yanoneBoldFont embed.FS

//go:embed static/companystylesheet/logo_weiss.png
var hfLogo embed.FS

Expand Down Expand Up @@ -134,18 +130,8 @@ func hochfrequenzStylesheetHandler(c *gin.Context) {
c.Data(http.StatusOK, "text/css", stylesheetBody)
}

// returns the yanone kaffeesatz (bold) ttf
func yanoneKaffeesatzBoldHandler(c *gin.Context) {
body, err := yanoneBoldFont.ReadFile("static/companystylesheet/fonts/YanoneKaffeesatzTTF/YanoneKaffeesatz-Bold.ttf")
if err != nil {
response := map[string]string{}
c.JSON(http.StatusNotFound, response)
}
c.Data(http.StatusOK, "font/ttf", body)
}

func robotoCondensedRegularHandler(c *gin.Context) {
ttfBody, err := robotoRegularFont.ReadFile("static/companystylesheet/fonts/Roboto_Condensed/RobotoCondensed-Regular.ttf")
func robotoRegularHandler(c *gin.Context) {
ttfBody, err := robotoRegularFont.ReadFile("static/companystylesheet/fonts/Roboto/Roboto-Regular.ttf")
if err != nil {
response := map[string]string{}
c.JSON(http.StatusNotFound, response)
Expand Down
2 changes: 1 addition & 1 deletion cmd/static/companystylesheet
19 changes: 7 additions & 12 deletions cmd/static/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,8 @@
}

@font-face {
font-family: "Roboto, Yanone Kaffeesatz";
src: url(/yanone-kaffeesatz-bold);
}

@font-face {
font-family: "Roboto, Roboto Condensed";
src: url(/roboto-condensed-regular);
font-family: "Roboto";
src: url(/roboto-regular);
}

* {
Expand All @@ -22,8 +17,8 @@
}

body {
font-family: 'Roboto, Roboto Condensed', sans-serif;
background-color: var(--pastel-gruen);
font-family: 'Roboto', sans-serif;
background-color: var(--pastell-gruen);
color: var(--weiches-schwarz);
display: flex;
flex-direction: column;
Expand All @@ -47,7 +42,7 @@ header h2 {
/*font-size: 1.5rem;*/
font-size: xx-large;
/*font-weight: 300;*/
font-family: 'Yanone Kaffeesatz', sans-serif;
font-family: 'Roboto', sans-serif;
}

main {
Expand All @@ -70,12 +65,12 @@ h1 {
font-size: 3rem;
color: var(--weiches-schwarz);
margin-bottom: 1rem;
font-family: 'Roboto Condensed', sans-serif;
font-family: 'Roboto', sans-serif;
}

.malo-id {
letter-spacing: 2px;
font-family: 'Yanone Kaffeesatz', sans-serif;
font-family: 'Roboto', sans-serif;
}

.checksum {
Expand Down
File renamed without changes.
18 changes: 0 additions & 18 deletions yanone-kaffeesatz-bold/function.json

This file was deleted.

0 comments on commit 174be05

Please sign in to comment.