* 原始文章地址可能暂时无法访问,仅展示文章的摘要信息

给编辑器添加字符统计功能」的摘要信息

文字已成为人们交流的重要方式,今天给大家分享一个如何在编辑器中添加字符统计功能,帮助您轻松掌握文章长度,提高写作效率。 效果展示 具体操作 1.添加Js方法 将以下Js代码添加到你主题的 functions.php 文件中即可: Typecho_Plugin::factory('admin/write-post.php')->bottom = array('myyodu', 'one'); Typecho_Plugin::factory('admin/write-page.php')->bottom = array('myyodu', 'one'); class myyodu { public static function one() { ?> <style> .field.is-grouped{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-pack:start;-ms-flex-pack:start;justify-content:flex-start; -ms-flex-wrap: wrap;flex-wrap: wrap;}.field.is-grouped>.control{-ms-flex-negative:0;flex-shrink:0}.field.is-grouped>.control:not(:last-child){margin-bottom:.5rem;margin-right:.75rem}.field.is-grouped>.control.is-expanded{-webkit-box-flex:1;-ms-flex-positive:1;flex-grow:1;-ms-flex-negative:1;flex-shrink:1}.fi...