Skip to content

feat(welcome): show a Black Friday offer to people without a license - #3995

Merged
datlechin merged 2 commits into
mainfrom
feat/black-friday-notice
Nov 2, 2026
Merged

datlechin merged 2 commits into
mainfrom
feat/black-friday-notice

Conversation

@datlechin

Copy link
Copy Markdown
Member

Summary

  • The Welcome window shows "Black Friday: 40% off Pro until Dec 1" under Support TablePro, only for people without a paid license (supportAudience == .prospect), from 2026-11-24 00:00 UTC up to 2026-12-01 08:00 UTC. It opens https://tablepro.app/black-friday?ref=app-black-friday, and the site applies the code.
  • DatedSale holds the two instants, the percentage and the page, with a half-open isLive(at:). The dates are fixed in the build, so the notice comes out in the first release after the sale.
  • A TimelineView redraws the line at exactly those two instants, so it appears and disappears while the window stays open, with no timer. DatedSaleSchedule replaces .explicit([start, end]): measured on macOS 27.0.1, .explicit draws its first frame with its first entry as the date, so the line would show three weeks early, and it never delivers its last entry, so the line would stay after the sale.
  • The timeline wraps both prospect links rather than the sale line alone, because an empty TimelineView still takes the stack's spacing. Outside the sale the Welcome window lays out exactly as before.
  • SupportReferrer.blackFriday and SupportLinks.blackFriday(_:) build the tagged link, the way pricing(_:) does.

Test plan

  • DatedSaleTests: one second before the start, the start, one second before the end and the end; the constants match the decided ISO instants.
  • DatedSaleScheduleTests: the schedule's entries before, at the start of, during and after the sale.
  • SupportLinksTests: the exact /black-friday URL with its ref; the new referrer joins the distinctness and attribution checks.
  • Screenshots below. The live shots come from a local build with the start moved to today, not committed.
Light Dark
Outside the sale (unchanged) Outside the sale, light Outside the sale, dark
During the sale During the sale, light During the sale, dark

The date follows the viewer's region: this Mac writes "1 Dec", en_US reads "Dec 1". A third local build that opened the sale 20 s after launch and closed it 20 s later showed the line appear and then disappear with the window left open.

Notes

  • The release that carries this has to ship before Nov 24 for anyone to see the line. After Dec 1 the line never shows again; DatedSale, DatedSaleSchedule, the row and the referrer can come out in the next release.
  • No docs PR: a dated sale line is not a feature the docs describe.

The Welcome window shows "Black Friday: 40% off Pro until Dec 1" under
Support TablePro for prospects, from 2026-11-24 00:00 UTC up to
2026-12-01 08:00 UTC, linking to the sale page with ref=app-black-friday.

A TimelineView redraws the line at the two instants. DatedSaleSchedule
replaces .explicit, which on macOS 27 draws its first entry as the
current date and never delivers its last entry.
@datlechin
datlechin merged commit 0806ece into main Nov 2, 2026
7 of 9 checks passed
@datlechin
datlechin deleted the feat/black-friday-notice branch November 2, 2026 21:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant