Say on the Profile page that drafting from the website needs an AI provider

The Draft button is disabled, with a link to Settings → AI provider,
until one is set up; the Overview lists the AI provider first.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-20 14:54:04 -07:00
co-authored by Claude Opus 5.5
parent cd24f2a06d
commit 434a9093b0
4 changed files with 30 additions and 4 deletions
+2 -1
View File
@@ -5,9 +5,10 @@
<form class="card inline-form" method="post" action="/profile/draft">
<label for="draft_url"><strong>Draft from your website</strong></label>
<p class="help">Reads your home page and a few pages it links to (about, products, pricing), and fills in what's empty below. Nothing is saved until you press Save.</p>
{{if .NoAI}}<p class="warn-text">This uses the AI: first <a href="/settings/ai">choose an AI provider</a> (for Anthropic, add your API key), then come back. Or fill in the form below by hand.</p>{{end}}
<div class="row">
<input id="draft_url" name="draft_url" type="url" placeholder="https://example.com" value="{{.DraftURL}}" required>
<button type="submit" class="secondary">Draft</button>
<button type="submit" class="secondary" {{if .NoAI}}disabled{{end}}>Draft</button>
</div>
<p class="help">Takes up to a minute or two.</p>
</form>