Skip to content

fix(docsite): add examples for DateTimeInput and DateRangeInput (# 2724)#3282

Open
mohitWeb-lab wants to merge 1 commit into
facebook:mainfrom
mohitWeb-lab:docsite/issue-2724-datetime-input-examples
Open

fix(docsite): add examples for DateTimeInput and DateRangeInput (# 2724)#3282
mohitWeb-lab wants to merge 1 commit into
facebook:mainfrom
mohitWeb-lab:docsite/issue-2724-datetime-input-examples

Conversation

@mohitWeb-lab

@mohitWeb-lab mohitWeb-lab commented Jun 30, 2026

Copy link
Copy Markdown

Summary

This PR fixes missing example blocks on the DateTimeInput and DateRangeInput docsite pages, which left both components with empty Examples sections and no "Open in playground" link.

Cause

Both components only had a showcase block (isShowcase: true), which populates the component thumbnail/hero. Showcases are not picked up as Examples — those require separate block files with isShowcase omitted or false. With no example blocks registered under exampleFor: 'DateTimeInput' / exampleFor: 'DateRangeInput', the Examples section on each page was empty and the playground link never appeared.

Fix

Added new example blocks under packages/cli/templates/blocks/components/:

  • DateTimeInputWithValidation — Shows DateTimeInput in all three status states (error, warning, success) with a meeting scheduling scenario.
  • DateRangeInputWithValidation — Shows DateRangeInput in all three status states with a booking conflict scenario.
  • DateRangeInputWithPresets — Shows DateRangeInput with four common analytics presets (Last 7 / 14 / 30 / 90 days) and a live selected-range display.

Closes #2724

…ebook#2724)

Both components had no non-showcase example blocks, leaving their docsite
   pages with empty Examples sections and no playground link. Add a Validation
   example for each (error/warning/success status states), plus a With Presets
   example for DateRangeInput demonstrating quick-select analytics ranges.
@vercel

vercel Bot commented Jun 30, 2026

Copy link
Copy Markdown

@mohitWeb-lab is attempting to deploy a commit to the Meta Open Source Team on Vercel.

A member of the Team first needs to authorize it.

@meta-cla

meta-cla Bot commented Jun 30, 2026

Copy link
Copy Markdown

Hi @mohitWeb-lab!

Thank you for your pull request and welcome to our community.

Action Required

In order to merge any pull request (code, docs, etc.), we require contributors to sign our Contributor License Agreement, and we don't seem to have one on file for you.

Process

In order for us to review and merge your suggested changes, please sign at https://code.facebook.com/cla. If you are contributing on behalf of someone else (eg your employer), the individual CLA may not be sufficient and your employer may need to sign the corporate CLA.

Once the CLA is signed, our tooling will perform checks and validations. Afterwards, the pull request will be tagged with CLA signed. The tagging process may take up to 1 hour after signing. Please give it that time before contacting us about it.

If you have received this in error or have any questions, please contact us at cla@meta.com. Thanks!

@meta-cla meta-cla Bot added the CLA Signed This label is managed by the Meta Open Source bot. label Jul 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Meta Open Source bot.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug] [bug-bash] DateTimeInput: no examples on docsite (no playground link as a result)

1 participant