CronAI Widget Builder

A plain-English schedule picker for any website. Use it yourself to get cron lines, or give it to your visitors so they pick how often something happens and your site runs it. The CronLex model works in the browser, so there's no server and no API key.

Full build 107 KB gzip Lite build 31 KB gzip (no typo correction) Model CronLex, 75k params Dependencies 0

Configure

Who types the schedule?

Size
Theme
Show these parts
All texts (translate or re-word)

Served from this site. jsDelivr works too: https://cdn.jsdelivr.net/gh/abozaralizadeh/cronai@master/widget/dist/cronai-widget.js.

Live preview, running the real widget
What your page receives

Copy the code

Sizes, for developers and for visitors

Minivisitor mode, one line
Compactdeveloper mode
Fullvisitor mode

Reference

Attribute / APIValuesWhat it does
modedeveloper · useruser is for your visitors: no cron, tiles or crontab lines, friendlier text, 3 upcoming runs.
sizemini · compact · fullLayout.
show, hidebadge title input status chips tiles cron copy guard description confidence notes runs timezone trigger examples zone, or allAdd or remove parts on top of the mode/size defaults. show="only runs description" starts from nothing.
stringsJSONRe-word or translate any text. Also the el.strings property.
themeauto · aurora · paper · terminal · sunset · glacier · forest · candyauto follows the visitor's light or dark setting.
timezoneIANA name or autoZone the times are meant in. Saved with the schedule, so your server runs "9am" at the visitor's 9am.
value / scheduletext / saved JSONStarting text, or restore a saved choice (text, zone and every-N-weeks) in edit forms. Both are also properties.
name, form-valuecron · json · text · descriptionWorks in a <form>; also sends <name>-text (always, what was typed) and <name>-json (when understood).
required, must-understandflagsrequired: filled in and understood. must-understand: may stay empty, but typed text must be understood.
show="zone"sectionBuilt-in time-zone picker; defaults to the visitor's zone and goes into the schedule JSON.
armed, arm(), disarm()flagFires crontrigger on schedule while the page is open, in any size, even with the trigger part hidden.
cronchange eventdetail.schedule, cron, crons, description, nextRuns, timezone, okFires on every new interpretation, and once on load.
CronAI.createTrigger(schedule, fn)browser / NodeRun your code at the times a visitor picked. Node: cronai-engine.esm.js.
CronAI.parse(text, {timezone}), scheduleNextRuns(schedule, n)JSEngine without UI.
CSS variables, ::part()--cai-accent, --cai-surface, --cai-text, --cai-font, --cai-rad-xl, … · parts named like the sectionscron-ai { --cai-accent: #e11d48 }, cron-ai::part(description) { font-size: 20px }.