From b319f7d39a715a07a3496c8435bad13f11207456 Mon Sep 17 00:00:00 2001 From: Evan Reichard Date: Thu, 1 Feb 2024 19:00:02 -0500 Subject: [PATCH] fix(graph): fix stretchy text on graph --- Makefile | 10 +++++ templates/pages/home.tmpl | 85 ++++++++++++++------------------------- 2 files changed, 41 insertions(+), 54 deletions(-) diff --git a/Makefile b/Makefile index 82fab31..4d011f1 100644 --- a/Makefile +++ b/Makefile @@ -29,6 +29,16 @@ docker_build_release_latest: build_tailwind build_tailwind: tailwind build -o ./assets/style.css --minify +dev: build_tailwind + GIN_MODE=release \ + CONFIG_PATH=./data \ + DATA_PATH=./data \ + SEARCH_ENABLED=true \ + REGISTRATION_ENABLED=true \ + COOKIE_SECURE=false \ + COOKIE_AUTH_KEY=1234 \ + LOG_LEVEL=debug go run main.go serve + clean: rm -rf ./build diff --git a/templates/pages/home.tmpl b/templates/pages/home.tmpl index 1cc118b..3f5fbb7 100644 --- a/templates/pages/home.tmpl +++ b/templates/pages/home.tmpl @@ -4,63 +4,40 @@ {{ define "content" }}
-
-

+

+

Daily Read Totals

{{ $data := (getSVGGraphData .Data.GraphData 800 70 )}} - - - - - {{ range $index, $item := $data.LinePoints }} - - - - - {{ (index $.Data.GraphData $index).Date }} - - - {{ (index $.Data.GraphData $index).MinutesRead }} minutes - - - {{ end }} - - +
+ + + + + +
+ {{ range $index, $item := $data.LinePoints }} + +
+
+ {{ (index $.Data.GraphData $index).Date }} + {{ (index $.Data.GraphData $index).MinutesRead }} minutes +
+
+ {{ end }} +
+