Editor architecture
How PuckEditor gets its config, what it handles for you, and how the Payload admin view wraps it.
The plugin has one editor component, PuckEditor, used for every editing case.
- It takes a
configprop directly, or reads it fromPuckConfigProvidercontext. - It has built-in page-tree support through the
hasPageTreeprop. - It loads Puck with a dynamic import internally, to prevent hydration mismatches.
- It handles save and publish, unsaved-changes tracking and viewport switching (Mobile, Tablet, Desktop and Full Width previews).
- It shows a drag handle in the component action bar for moving blocks in nested layouts. Pass
dnd={{ enableDragHandle: false }}to hide it; otherdndoptions are passed through to Puck.
PuckEditor is exported from @delmaredigital/payload-puck/client and @delmaredigital/payload-puck/editor. Its props are listed in the editor props reference.
Inside the Payload admin
In the Payload admin the plugin registers a server component, PuckEditorView, at /admin/puck-editor/:collection/:id. It:
- Reads the page as the signed-in user, so the collection's
readaccess applies. - Detects page-tree by looking for the
pageSegmentfield on the collection, and passeshasPageTree={true}when it finds it. - Passes the plugin's
editorStylesheets, layouts, preview URL and AI settings toPuckEditor. - Takes the Puck config from
PuckConfigProvidercontext.
The editor fills the viewport rather than rendering inside Payload's nav and header. The canvas iframe gets exactly your editorStylesheets and editorCss, not the admin page's CSS.
Plugins
Puck plugins run in this order: the bundled heading analyzer, plugins from the plugins prop, plugins from PuckConfigProvider, then integration plugins. Pass plugins={false} to disable all of them.

