telva
v1.1.6
Published
A little drawing app (editor)
Maintainers
Readme
telva
Embeddable React whiteboard editor for teams that want fast integration and deep customization.
Install
npm i telvaPeer dependencies
react >= 16.8react-dom >= 16.8
Why teams use telva
- Single-component integration (
<Telva />) for full editor experiences. - Production-ready shape system: draw, pen, text, sticky, arrows, media, geometry shapes, and groups.
- Flexible UI presentation: standard interface or minimal variant, with toolbar at top or bottom.
- Rich style controls with fill, border, typography, and gradient-capable rendering.
- Extensible runtime through callbacks, external persistence hooks, and React component registry.
Quick start
import { Telva } from 'telva'
export function App() {
return (
<div style={{ width: '100vw', height: '100vh' }}>
<Telva />
</div>
)
}Next.js (client-only)
import dynamic from 'next/dynamic'
;('use client')
const Telva = dynamic(() => import('telva').then((m) => m.Telva), {
ssr: false,
})
export default function Page() {
return <Telva uiVariant="minimal" toolbarPosition="top" />
}Core API highlights
Telva exposes high-level integration props for product teams:
document,currentPageIdfor controlled state bootstrap.onChange,onPersist,onPatch,onCommandfor persistence/event pipelines.showUI,showMenu,showPages,showStyles,showTools,showZoomfor UI composition.uiVariant(normal|minimal) andtoolbarPosition(top|bottom) for layout strategy.reactComponentsfor custom, app-defined blocks rendered inside the editor.
Internal architecture (how it works)
Telva.tsxcomposes UI panels, renderer bindings, internationalization, and editor lifecycle.TelvaAppis the orchestration engine (tool state, commands, undo/redo, events, sessions).TVDRcentralizes state reads/selectors for fast and predictable data access.state/shapes/*provides shape-specific behavior through util classes (render, bounds, hit tests, transforms).- Rendering and pointer plumbing are delegated to
telva-core, while geometry math comes fromtelva-vecandtelva-intersect.
Package scripts
yarn dev
yarn build
yarn test
yarn lintLicense
AGPL-3.0-only
