答案 0 :(得分:1)
这些被称为'可见编辑快捷方式'在Customizer Preview中。你应该在这里阅读更多相关信息:
https://make.wordpress.org/core/2016/11/10/visible-edit-shortcuts-in-the-customizer-preview/
它是选择性刷新的延伸:
$wp_customize->get_setting( 'blogname' )->transport = 'postMessage';
$wp_customize->get_setting( 'blogdescription' )->transport = 'postMessage';
$wp_customize->selective_refresh->add_partial( 'blogname', array(
'selector' => '.site-title a',
'render_callback' => 'twentyfifteen_customize_partial_blogname',
) );
$wp_customize->selective_refresh->add_partial( 'blogdescription', array(
'selector' => '.site-description',
'render_callback' => 'twentyfifteen_customize_partial_blogdescription',
) );
渲染回调调用bloginfo( 'name' );
和bloginfo( 'description' );
https://make.wordpress.org/core/2016/02/16/selective-refresh-in-the-customizer/
另请查看官方Customizer documentation
所以基本上如果您在自定义程序中进行了选择性刷新,默认情况下会出现这些选项;)