Temporal, not Date
A timed event is a Temporal.Instant, an all-day event a Temporal.PlainDate, and a floating event a Temporal.PlainDateTime.
2.0 · React 19 · SolidJS 2
One engine computes time zones, daylight saving time and recurrence. React and SolidJS 2 render it, with views you copy and own. An AI agent can read the calendar and change it, under rules your app sets.
pnpm add @moltenship/calendar @ui-sdk/core @ui-sdk/react react react-domui-sdk is a beta.
The packages that hold events, time and state import no UI framework. The calendar above is that engine with the React views from this site's registry. The packages ship no styles, and those views are one UI on top of them. You can restyle it, edit its files or build your own with MUI or any other library.
A timed event is a Temporal.Instant, an all-day event a Temporal.PlainDate, and a floating event a Temporal.PlainDateTime.
The engine lays out days that are 23 or 25 hours long, and the hours a clock change skips or repeats, in any IANA time zone.
Two more packages expand RRULE series inside the dates on screen and parse ICS feeds into Temporal values.
Week, day, month, year, agenda and resource views are React source files. The shadcn CLI copies them into your app, in Tailwind CSS or StyleX.
One adapter reads an ID, a title and a time range from your records. TypeScript keeps your record and ID types in every hook and callback.
In React, the calendar reads no clock, host time zone or window while it renders on the server, so the server and the browser render the same markup.
A calendar describes itself to an agent as state, events and fourteen named actions, and a fifteenth, deleting, when you allow it. The agent never reads your markup or simulates a pointer. Here is a live calendar and what the bridge lists for it. Each button sends the call a model would send.
One package holds the calendar's state and actions. It imports no framework and is built on ui-sdk. React and Solid each have a package that renders that state. The Solid package has the parts and hooks React has, keyboard navigation, dragging and undo included, and its registry has every view, in Tailwind CSS.
ui-sdk is a beta, so its API can still change.
| React 19 | SolidJS 2 | |
|---|---|---|
| Engine, state and event changes | Yes | Yes |
| Actions an agent can call | Yes | Yes |
| Root, parts and hooks | Yes | Yes |
| Keyboard navigation in a view | Yes | Yes |
| Drag, resize and create | Yes | Yes |
| Undo and redo | A hook and shortcuts | A hook and shortcuts |
| Ready-made views | shadcn/ui or StyleX source | Every view, as Tailwind CSS source |
| Testing package | Yes | No |
"use client";
import { createCalendar, defineEventAdapter } from "@moltenship/calendar";
interface Meeting {
id: string;
title: string;
roomIds: string[];
start: Temporal.Instant;
end: Temporal.Instant;
}
export const Calendar = createCalendar<Meeting, { id: string }>()({
eventAdapter: defineEventAdapter<Meeting>()({
getId: (meeting) => meeting.id,
getTitle: (meeting) => meeting.title,
getResourceIds: (meeting) => meeting.roomIds,
getInterval: ({ start, end }) => ({ kind: "timed", start, end }),
}),
});
A coding agent trained before 2.0 guesses at this API. The docs come as Markdown, on the site and inside the package, and a skill tells the agent where to look first.
Build with a coding agentThe index of every page, with a Markdown version of each at its address plus .md.
The same pages inside the package since 2.0, for the version you installed.
npx skills add Moltenship/time --skill moltenship-timeThe skill has seven reference files. @moltenship/calendar ships it under skills/.