Editor attribute reference
The editor reads data-* attributes on the elements your template produces — it never parses your markup. An attribute on an ancestor element declares, tag-agnostically, what a piece of DOM is in contract terms: which node and property it binds to, its atom type, its position, its state.
The golden rule: these attributes are emitted by helpers, never written by hand. Use the_prop/the_value/the_list/the_list_item/block/form, and the right attributes appear. The tables below are for understanding and debugging the output, not for hand-authoring it.
Node identity and state — data-node-*
Emitted on a node’s root element by block() and form().
| Attribute | Where | Value |
|---|---|---|
data-node-id | node root | the node’s @id |
data-node-type | node root | schema type, e.g. Place |
data-node-is-live | node root | "true" / "false" |
data-node-is-draft | node root | "true" / "false" |
data-node-selected | node root | set at runtime by the node bar (JS only, not emitted by PHP) |
Markers
Self-describing wrapper markers (no prefix).
| Attribute | Where | Meaning |
|---|---|---|
data-block | block wrapper | the block template slug |
data-menu | menu wrapper | menu marker |
data-form | form wrapper | the form template slug |
data-add-item / data-add-label | UI | “add item” hook and its label |
Inline editing — data-inline-*
Emitted by get_prop() (and its wrappers the_prop/the_value/the_richtext).
| Attribute | Where | Value |
|---|---|---|
data-inline-name | inline element | dot-path including prefix, e.g. containedInPlace.name |
data-inline-type | inline element | the atom type (see below) |
data-inline-value | inline element | current value (arrays as JSON) |
data-inline-dirty | inline element | "true" / "false" — whether it’s in the diff |
data-inline-focus | image element | focus point for object-position (set manually) |
data-inline-drop | image element | "true" to accept drag-and-drop upload (set manually) |
Atom types. The inline-editable types are text, name, image, gallery, video, geo, identifier, and itemlist. richtext is edited through the structured form today; its in-place editor is still arriving. The type is usually guessed from the property name; override it with the edit-type option on the helper.
In development: the in-place editor for richtext is still arriving (the form path works today), and further atoms defined in the contract — heading, quote, code, embed, audio, a standalone link, and a divider — are not yet inline-editable. Treat the inline set as growing.
Lists — data-list-*
The container carries data-inline-type="itemlist" plus the list attributes; items carry their own.
| Attribute | Where | Value |
|---|---|---|
data-list-type | <ol> | schema type of the items, e.g. Place |
data-list-orientation | <ol> | vertical (default) / horizontal |
data-list-fields | <ol> | JSON field spec for the list-item dialog |
data-list-item-index | <li> | integer position |
data-list-item-draggable | <li> | "true" (editors only) |
Framework init flags — data-ctxr-*
JS-only guards that prevent double-binding (data-ctxr-init, data-ctxr-block-init, etc.). Kept deliberately separate from the PWA world so a data-ctxr-* sweep never touches PWA attributes.
UI controls and space-owned attributes
Local hooks with no platform meaning — data-action, data-save, data-dialog, data-scope, and so on — live in editor and management modules. Your own templates are free to use any other data-* attributes (e.g. data-map-*); the platform won’t touch them. The Router sets data-path, data-type and data-id on <body>.
PWA hooks & attributes
The runtime data-pwa-* hooks — the geolocation, proximity and notification markup read on live pages — have their own catalogue: PWA hooks & attributes.
The source of truth for these conventions is the platform’s internal attribute register; this page is the public, developer-facing slice of it. If an attribute here doesn’t behave as described in your space, the code is ahead of the docs — tell us.