field-datetime
Date and time The four fields datetime.js enhances, each keeping its native input underneath, so a reader with no script gets the plain control and not a broken one.
A date and a time in one input, one value.
Each example is live, but its links go nowhere. HTML shows the markup to copy.
Enhanced input: type "tomorrow", or "in 3 weeks"
The words it parses are on data-rst-date-words, here in the page's language. i18n/<lang>.json has them in twelve languages, so the field can parse whichever language the page is in.
Put this inside <section rst-box><form rst-form>.
<div rst-field >
<label rst-field-label for ="field-datetime_live" >Publish on</label >
<input rst-input id ="field-datetime_live" name ="field-datetime_live" type ="datetime-local" value ="2026-09-04T19:30" aria-describedby ="field-datetime_live-hint" data-rst-date data-rst-date-words ="{"ago":"ago","am":"am|a.m.","at":"at","day":"day|days","hour":"hour|hours|h","in":"in","last":"last","midnight":"midnight","minute":"minute|minutes|min|mins|m","month":"month|months","next":"next","noon":"noon|midday","pm":"pm|p.m.","today":"today","tomorrow":"tomorrow","week":"week|weeks","yesterday":"yesterday"}" data-rst-date-set ="Set" data-rst-date-hint ="Try: {example}" data-rst-date-pick ="Open the calendar" data-rst-date-calendar ="Calendar" data-rst-date-prev-month ="Previous month" data-rst-date-next-month ="Next month" data-rst-date-results ="{n} suggestions" data-rst-date-result-one ="1 suggestion" data-rst-date-quick-today ="Today" data-rst-date-quick-tomorrow ="Tomorrow" data-rst-date-quick-next-week ="In a week" data-rst-date-quick-plus-1h ="An hour later" data-rst-date-quick-plus-2h ="Two hours later" data-rst-date-quick-end-of-day ="End of that day" data-rst-date-quick-next-day ="Same time next day" >
<small rst-field-hint id ="field-datetime_live-hint" >When it goes live.</small >
</div >
Required, with an error
Put this inside <section rst-box><form rst-form>.
<div rst-field >
<label rst-field-label for ="field-datetime_error" >Publish on <span rst-field-required aria-hidden ="true" >*</span ></label >
<input rst-input id ="field-datetime_error" name ="field-datetime_error" type ="datetime-local" required aria-invalid ="true" aria-describedby ="field-datetime_error-error" data-rst-date data-rst-date-words ="{"ago":"ago","am":"am|a.m.","at":"at","day":"day|days","hour":"hour|hours|h","in":"in","last":"last","midnight":"midnight","minute":"minute|minutes|min|mins|m","month":"month|months","next":"next","noon":"noon|midday","pm":"pm|p.m.","today":"today","tomorrow":"tomorrow","week":"week|weeks","yesterday":"yesterday"}" data-rst-date-set ="Set" data-rst-date-hint ="Try: {example}" data-rst-date-pick ="Open the calendar" data-rst-date-calendar ="Calendar" data-rst-date-prev-month ="Previous month" data-rst-date-next-month ="Next month" data-rst-date-results ="{n} suggestions" data-rst-date-result-one ="1 suggestion" data-rst-date-quick-today ="Today" data-rst-date-quick-tomorrow ="Tomorrow" data-rst-date-quick-next-week ="In a week" data-rst-date-quick-plus-1h ="An hour later" data-rst-date-quick-plus-2h ="Two hours later" data-rst-date-quick-end-of-day ="End of that day" data-rst-date-quick-next-day ="Same time next day" >
<small rst-field-error id ="field-datetime_error-error" >Pick a date after today.</small >
</div >
Bounded
Put this inside <section rst-box><form rst-form>.
<div rst-field >
<label rst-field-label for ="field-datetime_bounded" >Within this year</label >
<input rst-input id ="field-datetime_bounded" name ="field-datetime_bounded" type ="datetime-local" value ="2026-09-04T19:30" min ="2026-01-01T00:00" max ="2026-12-31T23:59" data-rst-date data-rst-date-words ="{"ago":"ago","am":"am|a.m.","at":"at","day":"day|days","hour":"hour|hours|h","in":"in","last":"last","midnight":"midnight","minute":"minute|minutes|min|mins|m","month":"month|months","next":"next","noon":"noon|midday","pm":"pm|p.m.","today":"today","tomorrow":"tomorrow","week":"week|weeks","yesterday":"yesterday"}" data-rst-date-set ="Set" data-rst-date-hint ="Try: {example}" data-rst-date-pick ="Open the calendar" data-rst-date-calendar ="Calendar" data-rst-date-prev-month ="Previous month" data-rst-date-next-month ="Next month" data-rst-date-results ="{n} suggestions" data-rst-date-result-one ="1 suggestion" data-rst-date-quick-today ="Today" data-rst-date-quick-tomorrow ="Tomorrow" data-rst-date-quick-next-week ="In a week" data-rst-date-quick-plus-1h ="An hour later" data-rst-date-quick-plus-2h ="Two hours later" data-rst-date-quick-end-of-day ="End of that day" data-rst-date-quick-next-day ="Same time next day" >
</div >
Plain: the bare native input
No enhancement attributes at all, so datetime.js has nothing to find. The native picker still opens.
Put this inside <section rst-box><form rst-form>.
<div rst-field >
<label rst-field-label for ="field-datetime_plain" >Publish on</label >
<input rst-input id ="field-datetime_plain" name ="field-datetime_plain" type ="datetime-local" value ="2026-09-04T19:30" >
</div >