summaryrefslogtreecommitdiff
path: root/web/templates
diff options
context:
space:
mode:
Diffstat (limited to 'web/templates')
-rw-r--r--web/templates/settings.html33
1 files changed, 33 insertions, 0 deletions
diff --git a/web/templates/settings.html b/web/templates/settings.html
index acee1ee..8a72287 100644
--- a/web/templates/settings.html
+++ b/web/templates/settings.html
@@ -161,6 +161,39 @@
</div>
</section>
+ <!-- Google Tasks Connection Section -->
+ <section class="mb-12">
+ <div class="flex flex-wrap items-center justify-between gap-4 mb-6 pb-2 border-b border-white/10">
+ <h2 class="text-xl font-medium text-white">Google Tasks</h2>
+ </div>
+ {{if .GoogleTasksError}}
+ <div class="card border-red-500/30 text-red-400 text-sm mb-4">
+ Connection failed: {{.GoogleTasksError}}
+ </div>
+ {{end}}
+ {{if not .GoogleTasksOAuthReady}}
+ <div class="card text-slate-500 text-sm italic">
+ Not configured — set GOOGLE_OAUTH_CLIENT_ID and GOOGLE_OAUTH_CLIENT_SECRET in .env and restart.
+ </div>
+ {{else if .GoogleTasksConnected}}
+ <div class="card flex items-center justify-between gap-4">
+ <span class="text-white text-sm">✓ Connected — real task lists syncing via OAuth.</span>
+ <button class="text-sm border border-red-500/30 text-red-400 hover:bg-red-500/10 px-4 py-2 rounded-lg transition-colors"
+ hx-post="/settings/google-tasks/disconnect"
+ hx-confirm="Disconnect Google Tasks? Task sync will stop until you reconnect.">
+ Disconnect
+ </button>
+ </div>
+ {{else}}
+ <div class="card flex items-center justify-between gap-4">
+ <span class="text-slate-400 text-sm">Not connected — service-account auth can't see your real task lists, this needs your own Google sign-in.</span>
+ <a href="/settings/google-tasks/connect" class="text-sm bg-slate-800 hover:bg-slate-700 text-white px-4 py-2 rounded-lg transition-colors">
+ Connect Google Tasks
+ </a>
+ </div>
+ {{end}}
+ </section>
+
<!-- Data Sources Section -->
<section class="mb-12">
<div class="flex flex-wrap items-center justify-between gap-4 mb-6 pb-2 border-b border-white/10">