panel-redesign: Help with seventeen topics; every box links to its own

Follows the design commit before it. Written by Sonnet, reviewed by
Opus.

  - view/help.go, templates/help.html: the mockup's topics, texts, ids
    and menu. The page shows the groups the reader's menu shows:
    Overview and Server for the global role, Outbound and Inbound by
    reach (Inbound only with the feature on), Account for everyone;
    boxes are numbered as shown.
  - Box.Help set on the boxes the mockups mark; the inbound MX box has
    its link again.
  - TestEveryHelpLinkLandsOnATopic also fails on a topic that no page
    links to, unless it is listed as menu-only (account) - and on a
    stale exception.

Known until the change that follows: the dns, dmarc and account topics
describe the three-choice report address, which the code does not have
yet; Account's DMARC box still links to #dns.

Not verified by running: three sentences rest on Postfix behaviour
(delivery is deferred when a required TLS session cannot be made; a
milter with default_action=tempfail answers 4xx; with "any recipient"
an address the upstream refuses comes back as a bounce).

Evidence
  - docs/assets/panel-redesign/evidence/help.png (1440x3600) and
    in-domain.png: headless Edge, real templates served locally with
    their fixtures - NOT from the container.
  - go test -count=1 ./internal/web/... ./cmd/panel: ok (six packages).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
mix
2026-10-10 11:58:36 +03:00
co-authored by Claude Opus 5.5
parent ef19c1448e
commit 4ab63d08ae
19 changed files with 474 additions and 136 deletions
+9 -4
View File
@@ -360,9 +360,9 @@ func NewOutDomain(m Meta, id int64, name string, canDelete bool) *OutDomain {
},
id: id, name: name, canDelete: canDelete,
DNS: Box{No: "01", Title: "DNS records", ID: "dns",
Help: &HelpLink{Href: "/help#dns", Title: "What to publish and why"}},
Help: topicLink(HelpDNS, "What to publish and why")},
Apps: Box{No: "02", Title: "Applications", ID: "apps", End: Plain("SASL logins that may send as this domain"),
Help: &HelpLink{Href: "/help#apps", Title: "What an application is"}},
Help: topicLink(HelpApps, "What an application is")},
AppsEmpty: EmptyState{Icon: "ti-apps", Text: Plain("No applications yet. Add one to let a program send as this domain.")},
Connection: Box{No: "03", Title: "Connection", ID: "connection", End: Plain("The same for every domain")},
}
@@ -610,17 +610,22 @@ func NewOutDomainSettings(m Meta, id int64, name string, apps int, canDelete boo
Title: "Domain settings",
Lead: Plain("The things set once and rarely touched: where DMARC reports go, the sending ceiling, moving the domain elsewhere."),
},
Reports: Box{No: "01", Title: "DMARC report address", ID: "reports"},
Reports: Box{No: "01", Title: "DMARC report address", ID: "reports", Help: topicLink(HelpDMARC, "Where DMARC reports go")},
ReportsAction: href + "/settings/reports",
Export: Box{No: "03", Title: "Export domain", ID: "export"},
ExportAction: href + "/settings/export",
Encrypt: true,
Limit: Box{No: "02", Title: "Rate limit", ID: "limit",
Help: &HelpLink{Href: "/help#limits", Title: "Levels 1 and 2"}},
Help: topicLink(HelpLimits, "Levels 1 and 2")},
LimitAction: href + "/settings/ratelimit",
RecalcAction: href + "/settings/ratelimit/recalc",
CanDelete: canDelete,
}
// The topic about exports is in the Server group of Help, which a domain
// administrator is not shown, so the box links to it for the global role only.
if m.IsGlobal {
p.Export.Help = topicLink(HelpBackup, "Moving a domain to another instance")
}
if canDelete {
text := "Removes the DKIM key"
if n := appsPhrase(apps); n != "" {