{"id":358612,"date":"2026-08-26T11:53:48","date_gmt":"2026-08-26T11:53:48","guid":{"rendered":"https:\/\/ru.wordpress.org\/plugins\/kda-custom-editor-buttons\/"},"modified":"2026-09-04T07:51:50","modified_gmt":"2026-09-04T07:51:50","slug":"kda-custom-editor-buttons","status":"publish","type":"plugin","link":"https:\/\/ru.wordpress.org\/plugins\/kda-custom-editor-buttons\/","author":23530499,"comment_status":"closed","ping_status":"closed","template":"","meta":{"version":"1.6.3","stable_tag":"1.6.3","tested":"7.1","requires":"5.8","requires_php":"7.4","requires_plugins":null,"header_name":"KDA Custom Editor Buttons","header_author":"KDA","header_description":"Custom TinyMCE toolbar buttons and Formats for Classic Editor \u2014 wrap, insert, add classes, or open a code snippet dialog.","assets_banners_color":"","last_updated":"2026-09-04 07:51:50","external_support_url":"","external_repository_url":"","donate_link":"","header_plugin_uri":"","header_author_uri":"","rating":0,"author_block_rating":0,"active_installs":0,"downloads":186,"num_ratings":0,"support_threads":0,"support_threads_resolved":0,"author_block_count":0,"sections":["description","installation","faq","changelog"],"tags":{"1.5.10":{"tag":"1.5.10","author":"deniskey","date":"2026-09-01 18:59:12","revision":3676695},"1.5.5":{"tag":"1.5.5","author":"deniskey","date":"2026-08-26 11:53:16","revision":3666917},"1.5.9":{"tag":"1.5.9","author":"deniskey","date":"2026-09-01 17:10:07","revision":3676559},"1.6.0":{"tag":"1.6.0","author":"deniskey","date":"2026-09-01 19:58:04","revision":3676778},"1.6.1":{"tag":"1.6.1","author":"deniskey","date":"2026-09-01 20:13:48","revision":3676791},"1.6.2":{"tag":"1.6.2","author":"deniskey","date":"2026-09-02 08:13:10","revision":3677447},"1.6.3":{"tag":"1.6.3","author":"deniskey","date":"2026-09-04 07:51:50","revision":3680822}},"upgrade_notice":[],"ratings":[],"assets_icons":{"icon-128x128.png":{"filename":"icon-128x128.png","revision":3666917,"resolution":"128x128","location":"assets","locale":"","width":128,"height":128},"icon-256x256.png":{"filename":"icon-256x256.png","revision":3666917,"resolution":"256x256","location":"assets","locale":"","width":256,"height":256},"icon.svg":{"filename":"icon.svg","revision":3666917,"resolution":false,"location":"assets","locale":false}},"assets_banners":[],"assets_blueprints":{},"all_blocks":[],"tagged_versions":["1.5.10","1.5.5","1.5.9","1.6.0","1.6.1","1.6.2","1.6.3"],"block_files":[],"assets_screenshots":[],"screenshots":[]},"plugin_section":[],"plugin_tags":[172,155767,5554,53042,1719],"plugin_category":[46],"plugin_contributors":[272649],"plugin_business_model":[],"class_list":["post-358612","plugin","type-plugin","status-publish","hentry","plugin_tags-buttons","plugin_tags-classic-editor","plugin_tags-custom-html","plugin_tags-formats","plugin_tags-tinymce","plugin_category-editor-and-writing","plugin_contributors-deniskey","plugin_committers-deniskey"],"banners":[],"icons":{"svg":"https:\/\/ps.w.org\/kda-custom-editor-buttons\/assets\/icon.svg?rev=3666917","icon":"https:\/\/ps.w.org\/kda-custom-editor-buttons\/assets\/icon.svg?rev=3666917","icon_2x":false,"generated":false},"screenshots":[],"raw_content":"<!--section=description-->\n<p>KDA Custom Editor Buttons lets you define your own Classic Editor controls:<\/p>\n\n<ul>\n<li>Wrap selection in any tag \/ CSS class<\/li>\n<li>Insert HTML templates (e.g. definition lists)<\/li>\n<li>Add a class to the current block (optionally with a tag)<\/li>\n<li>Open a code snippet dialog (language, line numbers, edit in place)<\/li>\n<li>Show each control on the toolbar, in Formats, or both<\/li>\n<li>Limit buttons to selected post types (including custom types such as <code>articles<\/code>)<\/li>\n<\/ul>\n\n<p>Front-end CSS still belongs to your theme if you want a custom look; the plugin ships a neutral snippet window, Copy, line numbers, and token colors. Prism.js and Highlight.js are bundled, so nothing is loaded from a CDN. The admin UI is English and can be translated through translate.wordpress.org.<\/p>\n\n<!--section=installation-->\n<ol>\n<li>Upload the plugin folder to <code>\/wp-content\/plugins\/kda-custom-editor-buttons<\/code><\/li>\n<li>Activate the plugin through the Plugins menu<\/li>\n<li>Go to Settings \u2192 KDA Editor Buttons<\/li>\n<li>Use Classic Editor when editing content<\/li>\n<\/ol>\n\n<!--section=faq-->\n<dl>\n<dt id=\"does%20it%20work%20with%20the%20block%20editor%20%28gutenberg%29%3F\"><h3>Does it work with the block editor (Gutenberg)?<\/h3><\/dt>\n<dd><p>Version 1 targets Classic Editor \/ TinyMCE. A soft admin notice appears if the block editor is the default.<\/p><\/dd>\n<dt id=\"will%20my%20theme%20styles%20apply%3F\"><h3>Will my theme styles apply?<\/h3><\/dt>\n<dd><p>Yes on the front end, if the theme defines the classes you insert. The plugin also ships a default snippet window and token colors (light\/dark). You can replace those stylesheets with the <code>kda_ceb_snippet_css<\/code> and <code>kda_ceb_highlight_css<\/code> filters.<\/p><\/dd>\n<dt id=\"how%20do%20i%20style%20the%20editor%20preview%3F\"><h3>How do I style the editor preview?<\/h3><\/dt>\n<dd><p>Use the standard WordPress <code>mce_css<\/code> filter in your theme, or the plugin filters <code>kda_ceb_snippet_css<\/code> \/ <code>kda_ceb_highlight_css<\/code>. The plugin does not store custom CSS.<\/p><\/dd>\n<dt id=\"can%20i%20use%20my%20own%20prism.js%20%2F%20highlight.js%20files%3F\"><h3>Can I use my own Prism.js \/ Highlight.js files?<\/h3><\/dt>\n<dd><p>Yes, with the PHP filter <code>kda_ceb_asset_base<\/code> in your theme (it works for built-in, Prism.js and Highlight.js). The earlier <code>kda_ceb_prism_base<\/code> and <code>kda_ceb_highlightjs_base<\/code> filters still work and run on top of the universal one. See the Documentation tab in the settings screen or <code>docs\/adding-a-button.en.md<\/code> \/ <code>.ru.md<\/code>.<\/p><\/dd>\n<dt id=\"is%20there%20a%20russian%20translation%3F\"><h3>Is there a Russian translation?<\/h3><\/dt>\n<dd><p>English is the source language. Translations are managed on translate.wordpress.org. The full user guide is in <code>docs\/adding-a-button.en.md<\/code> and <code>docs\/adding-a-button.ru.md<\/code>, and is also rendered inside the plugin under <strong>Settings \u2192 KDA Editor Buttons \u2192 Documentation<\/strong> in the admin language.<\/p><\/dd>\n<dt id=\"can%20i%20copy%20the%20plugin%27s%20js%2Fcss%20into%20my%20theme%3F\"><h3>Can I copy the plugin's JS\/CSS into my theme?<\/h3><\/dt>\n<dd><p>Yes. Open <strong>Settings \u2192 KDA Editor Buttons \u2192 Customization<\/strong>, set a folder path (must start and end with <code>\/<\/code>, relative to the site root). Use the <strong>Copy<\/strong> select to pick Built-in, Prism.js, Highlight.js, or <strong>All libraries<\/strong>, then add one of these snippets to <code>wp-config.php<\/code>:<\/p>\n\n<pre><code>`php\n<\/code><\/pre>\n\n<p>\/\/ short form: path comes from the setting above\ndefine( 'KDA_CEB_CUSTOM_ASSETS', true );<\/p>\n\n<p>\/\/ detailed form: path is also defined in wp-config (the form's path\n\/\/ field becomes read-only when KDA_CEB_CUSTOM_PATH is set)\ndefine( 'KDA_CEB_CUSTOM_ASSETS', true );\ndefine( 'KDA_CEB_CUSTOM_PATH', '\/wp-content\/themes\/your-child\/kda-ceb\/' );\n    `<\/p>\n\n<p>The tab shows a green \"Custom assets: active\" badge when the constant is on. The plugin creates the destination folder if it doesn't exist, and surfaces a clear error when the web server can't write there. The tab reminds you to re-copy after a plugin update.<\/p><\/dd>\n<dt id=\"can%20i%20lock%20the%20highlight%20engine%20and%20theme%20from%20wp-config%3F\"><h3>Can I lock the highlight engine and theme from wp-config?<\/h3><\/dt>\n<dd><p>Yes. Define <code>KDA_CEB_HIGHLIGHT_ENGINE<\/code> (<code>builtin<\/code> | <code>prism<\/code> | <code>highlightjs<\/code>) and <code>KDA_CEB_HIGHLIGHT_THEME<\/code> (<code>light<\/code> | <code>dark<\/code>) in <code>wp-config.php<\/code>. When set, they override the settings screen and the corresponding fields become read-only. Use this together with <code>KDA_CEB_CUSTOM_ASSETS<\/code> to pin the entire asset configuration in code:<\/p>\n\n<pre><code>`php\n<\/code><\/pre>\n\n<p>define( 'KDA_CEB_CUSTOM_ASSETS',      true );\ndefine( 'KDA_CEB_CUSTOM_PATH',        '\/wp-content\/themes\/your-child\/kda-ceb\/' );\ndefine( 'KDA_CEB_HIGHLIGHT_ENGINE',   'prism' );\ndefine( 'KDA_CEB_HIGHLIGHT_THEME',    'dark' );\n    `<\/p><\/dd>\n\n<\/dl>\n\n<!--section=changelog-->\n<h4>1.6.3<\/h4>\n\n<ul>\n<li>Bug fix: Show language checkbox now correctly toggles disabled state when changing the language in the code dialog (was stuck disabled after the first selection)<\/li>\n<\/ul>\n\n<h4>1.6.2<\/h4>\n\n<ul>\n<li>Enhancement: code selector is now configurable in Main tab settings<\/li>\n<li>Enhancement: when using custom folder, config is injected directly into frontend.js (no inline script needed)<\/li>\n<li>Enhancement: KDA_CEB_SCRIPT_VERSION can be set to '' or false to omit version parameter entirely<\/li>\n<li>Bug fix: Show language checkbox is now disabled for auto-detect and plain text languages<\/li>\n<li>Bug fix: fixed duplicate line numbers when re-editing a code block<\/li>\n<li>Bug fix: replaced entire code block wrapper on edit (no stray paragraph added)<\/li>\n<li>Bug fix: padding for code blocks without line numbers<\/li>\n<\/ul>\n\n<h4>1.6.1<\/h4>\n\n<ul>\n<li>Bug fix: prevented duplicate line numbers when re-editing a code block<\/li>\n<li>Bug fix: replaced entire code block wrapper on edit (no stray paragraph added)<\/li>\n<li>Enhancement: code block line numbers use new Variant 3 structure (kda-ceb-nums + kda-ceb-code)<\/li>\n<li>Enhancement: added confirmation dialog before deleting a code block<\/li>\n<\/ul>\n\n<h4>1.5.9<\/h4>\n\n<ul>\n<li>Customization: new <code>KDA_CEB_LIBRARY_MODE<\/code> constant (bundled | individual) forces library loading mode. When set, the corresponding UI option becomes read-only and shows a lock message.<\/li>\n<li>Frontend: fixed 404 error on <code>frontend-config.js<\/code> when <code>KDA_CEB_LIBRARY_MODE<\/code> is set to bundled \u2014 config is now embedded directly into library <code>.min.js<\/code> files instead of loading separately.<\/li>\n<li>Customization: path-aware copy tracking. The plugin now remembers which folder each library was copied to, so the \"Custom folder is empty\" notice no longer fires when copies exist in a different (older) folder. If copies are found elsewhere, the notice lists the previous paths and explains how to recover.<\/li>\n<li>New wp-config constants <code>KDA_CEB_HIGHLIGHT_ENGINE<\/code> (builtin | prism | highlightjs) and <code>KDA_CEB_HIGHLIGHT_THEME<\/code> (light | dark) override the admin settings. When defined, the corresponding fields in the settings screen become read-only.<\/li>\n<li>Public-label example changed to English (<code>'Copy'<\/code> \/ <code>'Copied!'<\/code>) in the admin UI and both user guides.<\/li>\n<\/ul>\n\n<h4>1.5.8<\/h4>\n\n<ul>\n<li>Customization: the path can now be set in <code>wp-config.php<\/code> via the new <code>KDA_CEB_CUSTOM_PATH<\/code> constant. When it's defined, the form's path field is read-only and the wp-config snippet in the tab shows the value. Two wp-config examples are shown side by side (short form and detailed form).<\/li>\n<li>\"Copy\" action: dropped the separate \"Copy everything\" button; the library select now includes an \"All libraries\" option.<\/li>\n<li>Copy action: destination folder is created if missing, and a clear error is shown when it's not writable (instead of a generic failure).<\/li>\n<\/ul>\n\n<h4>1.5.7<\/h4>\n\n<ul>\n<li>Settings screen split into four tabs: Main, Customization, Import \/ Export, Documentation.<\/li>\n<li>Customization tab: custom-folder loading is enabled by the <code>KDA_CEB_CUSTOM_ASSETS<\/code> constant in <code>wp-config.php<\/code>; the tab shows a green \"active\" \/ gray \"inactive\" badge. Path is any subfolder under the site root, must start and end with a forward slash.<\/li>\n<li>Documentation tab: removed the locale-switch hint and added a clickable table of contents with smooth scroll.<\/li>\n<li>New universal filter <code>kda_ceb_asset_base<\/code> for built-in, Prism.js and Highlight.js; the previous per-library filters still work and run on top of it.<\/li>\n<li><code>docs\/<\/code> is shipped to the WordPress.org plugin so the Documentation tab works there too.<\/li>\n<\/ul>\n\n<h4>1.5.6<\/h4>\n\n<ul>\n<li>Internal: tabs and copy flow scaffolding (replaced by 1.5.7).<\/li>\n<li>Remove the Editor preview CSS field \u2014 no arbitrary CSS is stored or served any more (use <code>mce_css<\/code> or the plugin stylesheet filters)<\/li>\n<li>Remove the Prism.js \/ Highlight.js folder settings; libraries load from the plugin folder, with the <code>kda_ceb_prism_base<\/code> \/ <code>kda_ceb_highlightjs_base<\/code> filters for theme developers<\/li>\n<li>Delete values saved by those fields in earlier versions on update<\/li>\n<li>Update bundled Highlight.js to 11.12.0 and Prism.js to 1.30.0<\/li>\n<li>Translations move to translate.wordpress.org (bundled .po\/.mo files removed)<\/li>\n<\/ul>\n\n<h4>1.5.5<\/h4>\n\n<ul>\n<li>Bug fix: copy files to custom folder with correct paths (fixed duplicate folder nesting)<\/li>\n<li>Bug fix: missing frontend-config.js in copied files<\/li>\n<\/ul>\n\n<h4>1.5.4<\/h4>\n\n<ul>\n<li>Escape live HTML\/script tags inside snippets on output so mixed PHP+HTML cannot break the page<\/li>\n<li>Strip leftover highlighter artifacts (<code>tok-kw<\/code>) before highlighting<\/li>\n<\/ul>\n\n<h4>1.5.3<\/h4>\n\n<ul>\n<li>Auto-detect language in the code dialog (mixed PHP\/HTML included); language label is never shown for auto<\/li>\n<\/ul>\n\n<h4>1.5.2<\/h4>\n\n<ul>\n<li>Always remove plugin options on uninstall; remove optional Uninstall checkbox from settings<\/li>\n<\/ul>\n\n<h4>1.5.1<\/h4>\n\n<ul>\n<li>Load Prism.js \/ Highlight.js from a theme folder or URL (settings fields + filters)<\/li>\n<li>Settings links to download pages and docs<\/li>\n<\/ul>\n\n<h4>1.5.0<\/h4>\n\n<ul>\n<li>Front-end highlight engine setting: Built-in, Prism.js, or Highlight.js (vendored, no CDN)<\/li>\n<li>Code dialog beautify uses js-beautify for JS\/JSON\/CSS\/HTML\/XML; built-in fallback for PHP\/SQL\/Bash<\/li>\n<\/ul>\n\n<h4>1.4.6<\/h4>\n\n<ul>\n<li>Reliable XML\/HTML beautify on OK (tokenizer; no external library)<\/li>\n<\/ul>\n\n<h4>1.4.5<\/h4>\n\n<ul>\n<li>Code dialog always beautifies on OK (checkbox removed; TinyMCE was not submitting it)<\/li>\n<\/ul>\n\n<h4>1.4.4<\/h4>\n\n<ul>\n<li>Remove truncated exit hint from the code dialog (hint stays in the visual editor only)<\/li>\n<\/ul>\n\n<h4>1.4.3<\/h4>\n\n<ul>\n<li>Complete Russian translation (admin, editor dialogs, exit hint, Copy)<\/li>\n<li>Full EN\/RU user guides<\/li>\n<\/ul>\n\n<h4>1.4.2<\/h4>\n\n<ul>\n<li>Visible exit hint in the visual editor and the code dialog<\/li>\n<\/ul>\n\n<h4>1.4.1<\/h4>\n\n<ul>\n<li>Reliable leave-block keys (Ctrl+Enter, Escape, empty last line); strip leftover BR<\/li>\n<\/ul>\n\n<h4>1.4.0<\/h4>\n\n<ul>\n<li>Neutral snippet window + kda_ceb_snippet_css<\/li>\n<li>Only plugin <code>&lt;pre&gt;<\/code> blocks are enhanced<\/li>\n<li>Quicktags (Text mode), editor token preview, dark palette, languages in settings<\/li>\n<\/ul>\n\n<h4>1.3.2<\/h4>\n\n<ul>\n<li>Unwrap leftover theme code-wrap chrome so a plugin-only update can restyle snippets<\/li>\n<\/ul>\n\n<h4>1.3.1<\/h4>\n\n<ul>\n<li>Snippet chrome: no empty language bar; Copy overlays the block unless Show language is on<\/li>\n<\/ul>\n\n<h4>1.3.0<\/h4>\n\n<ul>\n<li>Front-end highlight, Copy, and line numbers ship with the plugin (theme-independent)<\/li>\n<li>Filter <code>kda_ceb_highlight_css<\/code> to use a theme stylesheet for token colors<\/li>\n<li>Leave a code block in the editor: empty last line + Enter, or Ctrl+Enter<\/li>\n<\/ul>\n\n<h4>1.2.2<\/h4>\n\n<ul>\n<li>Code dialog: Show language is optional and off by default<\/li>\n<li>Line numbers sit on each code line (no overlay mismatch)<\/li>\n<\/ul>\n\n<h4>1.2.1<\/h4>\n\n<ul>\n<li>Code dialog: Beautify code option (on by default) cleans extra spaces and indentation<\/li>\n<\/ul>\n\n<h4>1.2.0<\/h4>\n\n<ul>\n<li>New action: Code snippet dialog (language, line numbers, edit-in-place)<\/li>\n<li>Demo: CODE wraps a short <code>pre.dk-code<\/code> line; BLOCK opens a large snippet window<\/li>\n<\/ul>\n\n<h4>1.1.0<\/h4>\n\n<ul>\n<li>Dashicons picker, live toolbar preview, fields shown by action<\/li>\n<li>Toggle wrap \/ add class (second click removes the format)<\/li>\n<li>Toolbar row 1\u20133 and grouped menu buttons<\/li>\n<li>Optional delete data on uninstall<\/li>\n<li>Docs: adding a button (EN\/RU)<\/li>\n<\/ul>\n\n<h4>1.0.0<\/h4>\n\n<ul>\n<li>Initial release: configurable buttons, Formats, kses whitelist, import, export\/copy<\/li>\n<\/ul>","raw_excerpt":"Custom TinyMCE toolbar buttons and Formats for the Classic Editor \u2014 wrap, insert templates, add classes, or open a code snippet dialog.","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/ru.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin\/358612","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/ru.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin"}],"about":[{"href":"https:\/\/ru.wordpress.org\/plugins\/wp-json\/wp\/v2\/types\/plugin"}],"replies":[{"embeddable":true,"href":"https:\/\/ru.wordpress.org\/plugins\/wp-json\/wp\/v2\/comments?post=358612"}],"author":[{"embeddable":true,"href":"https:\/\/ru.wordpress.org\/plugins\/wp-json\/wporg\/v1\/users\/deniskey"}],"wp:attachment":[{"href":"https:\/\/ru.wordpress.org\/plugins\/wp-json\/wp\/v2\/media?parent=358612"}],"wp:term":[{"taxonomy":"plugin_section","embeddable":true,"href":"https:\/\/ru.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_section?post=358612"},{"taxonomy":"plugin_tags","embeddable":true,"href":"https:\/\/ru.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_tags?post=358612"},{"taxonomy":"plugin_category","embeddable":true,"href":"https:\/\/ru.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_category?post=358612"},{"taxonomy":"plugin_contributors","embeddable":true,"href":"https:\/\/ru.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_contributors?post=358612"},{"taxonomy":"plugin_business_model","embeddable":true,"href":"https:\/\/ru.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_business_model?post=358612"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}