Reusable polls and voting for Statamic: answers from any collection or plain text, one vote per visitor, static-cache safe.

0.2.0

December 1st, 2026

Added

  • Per-poll "When closed, show" setting (closed_display): the ranking with counts (results, the default — nothing changes for existing polls) or only the winner (winner). Winner-only polls never publish counts — neither in the markup nor through the state endpoint — and show an image uploaded in the control panel (winner_image, with its alternative text in winner_image_alt), or the winning answer when there is none yet. Useful when publishing how many votes each nominee got would embarrass the runners-up.
  • The poll tag exposes closed_display, shows_results, shows_winner, winners, winner, winner_image and winner_image_alt. {{ polls:winner }} works in both modes: with votes and percent as before for polls that show results, without counts for winner-only polls.

Upgrading

  • Add the closed_display, winner_image and winner_image_alt fields to existing poll blueprints (copy them from resources/stubs/poll.yaml, setting the asset container). Without them every poll keeps showing its results. Published poll views need the new {{ elseif shows_winner }} branch to show the winner; until then winner-only polls show the "Voting closed" notice with no ranking.

0.1.2

November 6th, 2026

Fixed

  • Cloudflare Turnstile now works as documented: polls.js loads Cloudflare's script (or waits for the site's own copy) and renders the widget in each open poll. Before, nothing loaded the script, so with both keys set every vote was turned away. After a failed vote the widget is reset, so the visitor can try again; a vote sent before the check finishes asks the visitor to wait, and if the script or the widget fails the visitor is told so and it is retried.
  • A vote sent without JavaScript now shows its outcome ("Thanks for voting!") when the visitor comes back to the page, through the new polls:outcome tag inside {{ nocache }}. Left out with full static caching, where voting needs JavaScript.

Changed

  • The Turnstile placeholder in the default view is now <div data-poll-turnstile data-sitekey="…">, and the error element carries data-poll-error-verifying and data-poll-error-unverified. Published views with the old .cf-turnstile placeholder keep working; without the new attributes they show the generic error message.

Added

  • README: setting up Turnstile, what it sends to Cloudflare, a privacy section and control panel screenshots.