Files
jcoffey-dev 5d628689c1
ci / editor-ui (pull_request) Successful in 30s
ci / go (pull_request) Successful in 1m56s
Three packs: contact forms, tables and a changelog
contact-forms brings a quote request, a booking request and a mailing list
sign-up, and a Contact form section that shows any form beside an email,
phone, address and a note. tables shows a table from a spreadsheet saved as
CSV (or YAML or JSON) in data/, with a caption, row headings, numbers on the
right, and sideways scrolling on phones. changelog gives a page per release,
every release on one page, a feed, a What's new section and a latest-release
partial; notes grouped under Keep a Changelog headings show as labels.

To make them possible:
- data/*.csv files load as rows of cells, for the data function and the
  editor's data picker.
- Packs can bring forms (forms/<name>.yaml). A form is copied once and is the
  site's own from then on: upgrades and removal leave it, and a site's own
  form of that name is kept. A pack's form must send to a placeholder address
  (example.org and the other RFC 2606 names) and can't set Turnstile, so a
  pack can't route a site's submissions or add another site's script.
- A new check warning, form-placeholder, for forms that still send to or show
  a placeholder address (the starter's contact form does until it's set).
- A form's success path can no longer start with // or /\, which browsers
  treat as another site.
2026-10-14 12:58:23 -07:00

1.2 KiB

Contact forms pack

Ready-made forms for a HotDog CMS site, and a section to put them on a page.

hotdog-cms pack add contact-forms
  • forms/quote.yaml: a quote request (what, by when, budget, details).
  • forms/booking.yaml: a booking request (day, time of day, how many). It asks; you confirm by email.
  • forms/signup.yaml: a mailing list sign-up, with a required "yes, email me" box.
  • The Contact form section shows any form in forms/ beside your email, phone, address and a note, such as your opening hours or how soon you answer. It works with the contact form every site starts with, too.

The forms are copied into the site once and are the site's own from then on: upgrading or removing the pack leaves them alone. They send to [email protected] until you set to: and mailto: to your own address, and hotdog-cms check warns until you do. Forms are sent by the endpoint (hotdog-cms endpoint), with its spam checks; see HotDog's docs/forms.md.

A pack's forms always send to a placeholder address like that one, never to an address the pack's author chose, and can't load another site's script, so adding a pack can't send your visitors' messages anywhere you didn't pick.