1.0.0
First stable release. SmartForms is a zero-dependency, framework-free client-side manager for static HTML forms: it tracks per-field state, drives toolbar actions from that state, and submits via configurable HTTP tasks. From this release on, the public API follows Semantic Versioning.
Highlights
- State-aware fields � every input is tracked as new, unchanged, changed, invalid, or empty, and the form aggregates a single state that UI reacts to.
- Toolbar driven by state � edit, save, cancel, destroy, back, and toggle roles enable/disable automatically per the current form state.
- HTTP submission via TaskExecutor � synchronous and asynchronous form submissions with verb/mode resolution, Laravel resource-controller defaults, and CSRF support.
- Zero dependencies, any setup � ships as ESM, CJS, and UMD with TypeScript definitions; drop in via autoInit() or instantiate classes directly.
Components
- Forms: SmartForm, SmartFormList, SmartFormRecord
- Inputs: TextInput, EmailInput, UrlInput, NumberInput, DateTimeInput, ColorInput, FileInput, SelectInput, TextAreaInput, CheckBoxInput, RadioInput, DynamicTableInput
- Toolbar: Toolbar, Button, AdminForm
- Constants: Roles, State, Tasks
- HTTP: TaskExecutor
- Entry point: autoInit(), plus data-track-form trackers and a toggleable debug logger
Changes since 0.1.1
Added
- SmartFormList.resource() returning the list's data-resource attribute, mirroring SmartForm.resource(), so TaskExecutor can resolve the resource from either a form or a list body.
Fixed
- README.md now documents EmailInput, the input[type=password] � TextInput mapping, the edit / destroy / back toolbar roles, and the corrected per-state button-enable matrix.
- types/index.d.ts rewritten to match the real public API (dropped the non-existent reordered state and LINK / REORDER roles; added EmailInput, Tasks, TaskExecutor).
- CONTRIBUTING.md no longer references a non-existent .nvmrc.
Install
npm install @hradigital/smartforms
Full Changelog: https://github.com/HRADigital/smartforms/commits/1.0.0