Skip to content

feat(posts): schedule posts from both composers#6283

Open
idoshamun wants to merge 1 commit into
mainfrom
feat/schedule-posts
Open

feat(posts): schedule posts from both composers#6283
idoshamun wants to merge 1 commit into
mainfrom
feat/schedule-posts

Conversation

@idoshamun

@idoshamun idoshamun commented Jul 3, 2026

Copy link
Copy Markdown
Member

What

Adds an optional schedule to post creation. A calendar button next to the submit button opens a popover (desktop) / drawer (mobile) with a datetime picker; the submit button label flips to Schedule once a time is set.

Pairs with the daily-api branch codex/schedule-all-post-types.

Scope

  • Single-source, non-moderated only — the schedule button is hidden when more than one source is selected or the target requires moderation.
  • New composer (SmartComposerModal): all post types. scheduledAt is sent on the dedicated single-source mutations (createFreeformPost, createPollPost, submitExternalLink, sharePost). postInMultipleSources never carries scheduledAt.
  • Legacy composer (squads/create): new posts + polls. The schedule control mirrors the submit button — footer on desktop, FormWrapper header on mobile. Share is intentionally left to the new composer (its preview-driven flow makes clean scheduling costly).
  • Validation matches the backend: must be in the future and within 14 days.

Notes

  • Scheduled posts are invisible until published, so success shows a "scheduled" toast and skips navigating to the not-yet-visible post.
  • scheduledAt is stripped on all moderation paths.

Test

  • Unit test for the validation helper (scheduledPost.spec.ts): future + 14-day cap.
  • Manual: in each composer, single non-moderated source → set a schedule → submit → the request carries scheduledAt and the post doesn't appear in the feed immediately.

Preview domain

https://feat-schedule-posts.preview.app.daily.dev

Add an optional schedule to post creation. A calendar button next to the
submit button opens a popover (desktop) / drawer (mobile) with a datetime
picker; the submit label flips to "Schedule".

- Scheduling is single-source and non-moderated only (per the API).
- New composer supports all post types; scheduledAt is sent on the dedicated
  single-source mutations (createFreeformPost, createPollPost, submitExternalLink,
  sharePost). Multi-source never schedules.
- Legacy composer covers new posts and polls; the schedule control mirrors the
  submit button (footer on desktop, FormWrapper header on mobile).
- Validation matches the backend: future and within 14 days.
@vercel

vercel Bot commented Jul 3, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
daily-webapp Ready Ready Preview Jul 3, 2026 11:36am
1 Skipped Deployment
Project Deployment Actions Updated (UTC)
storybook Ignored Ignored Jul 3, 2026 11:36am

Request Review

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