editor-mode.php
Resolves Simple or Developer mode and persists authorized user preferences. Mode availability remains distinct from resource permissions.
Responsibility#
Resolves Simple or Developer mode and persists authorized user preferences. Mode availability remains distinct from resource permissions.
This is an implementation reference for the released 0.9.13 module. Internal PHP helpers are not a compatibility promise for third-party callers. Prefer the documented REST, Abilities, theme, and filter contracts.
Related modules#
WordPress hooks#
| Operation | Hook |
|---|---|
apply_filters |
cantata_edit_build_post_types |
add_action |
template_redirect |
add_action |
edit_form_after_title |
add_action |
admin_post_cantata_edit_wordpress |
add_action and add_filter subscribe to a hook; do_action and apply_filters expose a hook. A subscription is not itself a new extension API. Dynamic hook names are not included in this literal inventory.
Function and method reference#
cantata_edit_can_build_post#
function cantata_edit_can_build_post( WP_Post $post ): bool
Themes opt their template-backed records into the same build button as pages.
Source location: includes/editor-mode.php:6.
cantata_edit_wordpress_content#
function cantata_edit_wordpress_content( string $html ): string
Retain the current words, translating live slots back to their registered shortcodes.
Implementation connections: cantata_edit_live_normalize.
Source location: includes/editor-mode.php:12.
cantata_edit_use_wordpress#
function cantata_edit_use_wordpress( int $id, string $base )
The mode change never chooses between unpublished and published words on someone's behalf.
Implementation connections: cantata_edit_is_built, cantata_edit_page_rev, cantata_edit_without_kses, cantata_edit_wordpress_content.
Source location: includes/editor-mode.php:23.