@mocanvas/mocanvas · interface

TLUiContextProviderProps

interface TLUiContextProviderProps

One provider that mounts every UI context in the right order.

The order is not arbitrary: translations read the editor's locale, the announcer and the toasts are rendered by components that read the breakpoint, and the tooltip layer must be inside the container provider so it portals into the editor rather than the page. Getting this wrong produces failures that only show up in an embedded editor, so it is written down once here instead of at every call site.


Properties · 5

children?: ReactNode
components?: TLUiComponents

The UI chrome map.

forceMobile?: boolean

Pin the layout to its narrowest form.

onUiEvent?: TLUiEventHandler

Reported UI events.

overrides?: TLUiOverrides

Extra UI strings, keyed by locale then id.

mocanvas is built by Symbio. Free for non-commercial, non-profit and development use; commercial use needs an agreement. Not affiliated with or endorsed by tldraw.