From 454ae2afd2411c6517c45c20584bfe0b6ca7b34c Mon Sep 17 00:00:00 2001 From: Ian Gulliver Date: Tue, 30 Dec 2025 09:33:29 -0800 Subject: [PATCH] Remove debug logs and fix Google button dark mode MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 --- main.go | 7 +------ static/app.js | 3 ++- 2 files changed, 3 insertions(+), 7 deletions(-) diff --git a/main.go b/main.go index 5ecae0e..6a42097 100644 --- a/main.go +++ b/main.go @@ -28,16 +28,11 @@ var ( ) func init() { - log.Println("starting up") - templates = template.Must(template.New("").ParseGlob("static/*.html")) template.Must(templates.ParseGlob("static/*.js")) - pgconn := os.Getenv("PGCONN") - log.Println("connecting to database:", pgconn[:min(len(pgconn), 30)]+"...") - var err error - db, err = sql.Open("postgres", pgconn) + db, err = sql.Open("postgres", os.Getenv("PGCONN")) if err != nil { log.Fatal("[ERROR] failed to open database: ", err) } diff --git a/static/app.js b/static/app.js index 6ccfeb4..614a845 100644 --- a/static/app.js +++ b/static/app.js @@ -81,10 +81,11 @@ export async function auth() { } }); + const isDark = window.matchMedia('(prefers-color-scheme: dark)').matches; google.accounts.id.renderButton(signin, { type: 'standard', size: 'large', - theme: 'outline', + theme: isDark ? 'filled_black' : 'outline', text: 'sign_in_with', shape: 'rectangular', logo_alignment: 'left'