Skip to content

Commit

Permalink
删除禁用块编辑器的代码
Browse files Browse the repository at this point in the history
主题目前支持古登堡编辑器,但是一些功能须在经典编辑器中才能使用(古登堡编辑器中可以添加经典编辑器块)
后续将会增强对其的支持
  • Loading branch information
syfxlin authored Feb 17, 2019
1 parent 90efde0 commit 1f12595
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions functions.php
Original file line number Diff line number Diff line change
Expand Up @@ -172,15 +172,15 @@ function origami_async_script($tag, $handle, $src)
/**
* 块编辑器
*/
// 去除 Wordpress5.0 块编辑器样式
function fanly_remove_block_library_css()
{
wp_dequeue_style('wp-block-library');
}
add_action('wp_enqueue_scripts', 'fanly_remove_block_library_css', 100);
// 禁用块编辑器
add_filter('use_block_editor_for_post', '__return_false');
remove_action('wp_enqueue_scripts', 'wp_common_block_scripts_and_styles');
// // 去除 Wordpress5.0 块编辑器样式
// function fanly_remove_block_library_css()
// {
// wp_dequeue_style('wp-block-library');
// }
// add_action('wp_enqueue_scripts', 'fanly_remove_block_library_css', 100);
// // 禁用块编辑器
// add_filter('use_block_editor_for_post', '__return_false');
// remove_action('wp_enqueue_scripts', 'wp_common_block_scripts_and_styles');

/**
* 使评论支持图片
Expand Down

0 comments on commit 1f12595

Please sign in to comment.