/** * Mounts the redesigned Site Identity control into core's own * `title_tagline` section — see `override_site_identity()` in * `Aureon\Customizer\Customizer`. * * Same pattern as `static-front-page.tsx`: a one-off root inside a *core* * section, backed directly by core `wp.customize` settings the Aureon tree * knows nothing about — see `SiteIdentitySection`. */ import { createRoot } from '@wordpress/element'; import { onControlEmbedded, onReady } from '../customize-bridge'; import SiteIdentitySection from '../sections/site-identity'; // Must match the ids `Customizer::override_site_identity()` registers the // Mount_Control with. const MOUNT_ID = 'aureon-title_tagline-root'; const CONTROL_ID = 'aureon_title_tagline_mount'; export default function mountSiteIdentity(): void { onReady( () => { onControlEmbedded( CONTROL_ID, () => { const node = document.getElementById( MOUNT_ID ); if ( ! node ) { return; } createRoot( node ).render( ); } ); } ); }