You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

readme.txt 29KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789
  1. === Prismatic ===
  2. Plugin Name: Prismatic
  3. Plugin URI: https://perishablepress.com/prismatic/
  4. Description: Display beautiful syntax-highlighted code snippets with Prism.js or Highlight.js
  5. Tags: code, snippets, syntax, highlight, language, snippet, pre, prettify, prism, css, fence
  6. Author: Jeff Starr
  7. Contributors: specialk
  8. Author URI: https://plugin-planet.com/
  9. Donate link: https://monzillamedia.com/donate.html
  10. Requires at least: 4.1
  11. Tested up to: 5.7
  12. Stable tag: 2.7
  13. Version: 2.7
  14. Requires PHP: 5.6.20
  15. Text Domain: prismatic
  16. Domain Path: /languages
  17. License: GPL v2 or later
  18. Display beautiful syntax-highlighted code snippets with Prism.js or Highlight.js
  19. == Description ==
  20. __The only 3-in-1 syntax highlighter!__
  21. Display beautiful code snippets with Prism.js, Highlight.js, or plain code escaping:
  22. * __Prism.js__ - Code escape + syntax highlight using [Prism.js](https://prismjs.com/)
  23. * __Highlight.js__ - Code escape + syntax highlight using [Highlight.js](https://highlightjs.org/)
  24. * __Plain Flavor__ - Code escape without syntax highlight
  25. Check out a [demo post using Highlight.js](https://dev-tricks.com/favorite-highlight-js-styles/). I also use this plugin at [WP-Mix](https://wp-mix.com/) for all code snippets.
  26. **Prism.js Features**
  27. * Supports __50+__ coding languages
  28. * Choose from all __8__ available Prism themes
  29. * Provides a Gutenberg block for adding code snippets
  30. * Provides TinyMCE/Visual buttons for adding code snippets
  31. * Enable Prism plugin [Line Numbers](https://prismjs.com/plugins/line-numbers/)
  32. * Enable Prism plugin [Line Highlight](https://prismjs.com/plugins/line-highlight/)
  33. * Enable Prism plugin [Show Language](https://prismjs.com/plugins/show-language/)
  34. * Enable Prism plugin [Copy Code Button](https://prismjs.com/plugins/copy-to-clipboard/)
  35. * Highlights code in post content, excerpts, and comments
  36. * Detects `language-` and `lang-` class prefixes
  37. * Limit syntax highlighting to Posts and Pages
  38. * Highlight single-line and multi-line code
  39. * Granular control over code escaping
  40. * Smart loading of CSS & JS assets
  41. * Support for ACF on single post views
  42. **Highlight.js Features**
  43. * Supports __50+__ coding languages
  44. * Choose from all __98__ available Highlight themes
  45. * Provides a Gutenberg block for adding code snippets
  46. * Provides TinyMCE/Visual buttons for adding code snippets
  47. * Customize the Highlight.js init JavaScript
  48. * Highlights code in post content, excerpts, and comments
  49. * Limit syntax highlighting to Posts and Pages
  50. * Highlight multi-line blocks of code
  51. * Detects `language-` and `lang-` class prefixes
  52. * Enable support for no-prefix class names
  53. * Granular control over code escaping
  54. * Smart loading of CSS & JS assets
  55. **Plain Flavor Features**
  56. * Enable code escaping for post content, excerpts, and/or comments
  57. * Enable code escaping on the frontend, Admin Area, or both
  58. * Provides a Gutenberg block for adding code snippets
  59. * Provides TinyMCE/Visual buttons for adding code snippets
  60. * Escapes single-line and multi-line code snippets
  61. * Escapes `<code>` tags (based on configuration)
  62. **General Features**
  63. * Easy to set up &amp; configure
  64. * Built with the WordPress API
  65. * Squeaky clean, error-free code
  66. * Born of simplicity, no frills
  67. * Lightweight, fast and flexible
  68. * Focused on performance and security
  69. * Loads CSS/JS assets only when required
  70. * Adheres to HTML coding best practices
  71. * Works with the Gutenberg Block Editor
  72. * Regularly updated and "future proof"
  73. _Prismatic escapes only the essentials to keep your code clean._
  74. [Check out the screenshots](https://wordpress.org/plugins/prismatic/screenshots/) for more details!
  75. **Privacy**
  76. This plugin does not collect or store any user data. It does not set any cookies, and it does not connect to any third-party locations. Thus, this plugin does not affect user privacy in any way.
  77. == Screenshots ==
  78. 1. Prismatic General Settings
  79. 2. Prismatic Prism.js Settings
  80. 3. Prismatic Highlight.js Settings
  81. 4. Prismatic Plain Flavor Settings
  82. 5. Prism.js : Twilight theme (choose from 7 Prism.js themes!)
  83. 6. Highlight.js : Arduino Light theme (choose from 77 Highlight.js themes!)
  84. 7. Highlight.js : Gruvbox Dark theme (choose from 77 Highlight.js themes!)
  85. 8. Cleanly escaped code without syntax highlighting (Plain Flavor)
  86. 9. Gutenberg Prismatic block (under Formatting menu)
  87. 10. Prismatic block showing added code and language select
  88. 11. Prismatic TinyMCE/Visual button for adding code snippets
  89. 12. Prismatic TinyMCE panel showing added code and selected language
  90. == Installation ==
  91. **Installing Prismatic**
  92. 1. Make a backup of your database
  93. 2. Upload the plugin to your blog and activate
  94. 3. Visit the plugin settings to configure options
  95. _[More info on installing WP plugins](https://wordpress.org/support/article/managing-plugins/#installing-plugins)_
  96. **Quick Start Guide**
  97. Here is a quick guide to get started with Prismatic:
  98. 1. Activate the plugin and visit the Prismatic settings page
  99. 2. Choose Prism.js or Highlight.js for syntax highlighting
  100. 3. Optionally visit the Prism.js or Highlight.js tab to customize options
  101. You are now ready to go. To add a code snippet to any WP Post or Page:
  102. * If using Gutenberg Block Editor, click on the Prismatic block
  103. * If using Classic Editor, click on the Prismatic TinyMCE button
  104. To get a better idea, view the screenshots on the [Prismatic homepage](https://wordpress.org/plugins/prismatic/).
  105. The Prismatic block or button makes it easy to add your code snippet and choose a language. The plugin automatically will output the correct markup to display your code with syntax highlighting. No code editing required! Note: Advanced usage information provided further down on this page.
  106. **Like the plugin?**
  107. If you like Prismatic, please take a moment to [give a 5-star rating](https://wordpress.org/support/plugin/prismatic/reviews/?rate=5#new-post). It helps to keep development and support going strong. Thank you!
  108. **Uninstalling**
  109. Prismatic cleans up after itself. All plugin settings will be removed from your database when the plugin is uninstalled via the Plugins screen. NOTE that uninstalling the plugin will NOT touch any of your post content. Only the plugin options are removed when the plugin is uninstalled via the Plugins screen.
  110. **Restore Default Options**
  111. To restore default plugin options, either uninstall/reinstall the plugin or visit the Prismatic General Settings &gt; Restore default plugin options.
  112. **Usage: Syntax Highlighting**
  113. The Prismatic plugin follows the same conventions used by [Prism.js](https://prismjs.com/) and [Highlight.js](https://highlightjs.org/). Here are the basic steps:
  114. 1. Visit the Prismatic General Settings and choose your library
  115. 2. Visit the settings tab for your chosen library
  116. 3. Choose a theme and configure your options
  117. Once the settings are configured, you can enable syntax highlighting for any code snippet by doing one of the following:
  118. * Wrap multi-line code with pre &amp; code tags: &lt;pre&gt;&lt;code&gt;...&lt;/code&gt;&lt;/pre&gt;
  119. * Wrap single-line code with code tags: &lt;code&gt;...&lt;/code&gt;
  120. The plugin also provides a Prismatic Gutenberg block and TinyMCE buttons. So you can add code snippets with a few clicks easily.
  121. __Note:__ Prism.js highlights both multi-line and single-line code snippets. Highlight.js only supports multi-line code snippets.
  122. With the proper markup in place, you can indicate a specific language by adding a class of `language-abc` or `lang-abc` to the &lt;code&gt; tag (where "abc" is the language identifier). For example, to indicate PHP as the language for a single-line code snippet:
  123. <code class="language-php"><?php echo 'Hello world'; ?></code>
  124. Likewise, to indicate HTML as the language for a multi-line code snippet:
  125. <pre><code class="language-html">
  126. <table>
  127. <tr>
  128. <th>Name</th>
  129. <th>Side</th>
  130. <th>Role</th>
  131. <tr>
  132. <td>Darth</td>
  133. <td>Dark</td>
  134. <td>Sith</td>
  135. </tr>
  136. </table>
  137. </code></pre>
  138. Alternately, the language class may be placed on the &lt;pre&gt; tag, for example:
  139. <pre class="language-html"><code class="optional">
  140. <table>
  141. <tr>
  142. <th>Name</th>
  143. <th>Side</th>
  144. <th>Role</th>
  145. <tr>
  146. <td>Darth</td>
  147. <td>Dark</td>
  148. <td>Sith</td>
  149. </tr>
  150. </table>
  151. </code></pre>
  152. Note: in the previous example, ignore the `class="optional"` added to the code tag; it is used to prevent markdown from mangling the code example on this web page.
  153. Basically, the prefix of the class names (i.e., "lang-" or "language-") are the same for Prism.js and Highlight.js. The difference is the language identifier (e.g., "css" or "html") used to specify each language. Check out the following "About Prism.js" and "About Highlight.js" sections for more information.
  154. __Note:__ In addition to detecting the `language-` and `lang-` prefixes, Highlight.js also will try to auto-detect the language without it being specified. Plus as an option, you can enable the Highlight.js setting, "Support no-prefix class names" to enable use of language identifiers without any `language-` or `lang-` prefix.
  155. > Pro Tip: Language class names work when added to the &lt;pre&gt; tag for both Prism.js and Highlight.js.
  156. **Usage: Code escaping**
  157. Just like Prism.js and Highlight.js, the Prismatic plugin follows HTML coding standards. To enable code escaping:
  158. 1. Visit the Prismatic General Settings and choose your library
  159. 2. Enable "Code Escaping" via the settings tab of your chosen library
  160. 3. Do one of the following:
  161. * Wrap multi-line code with pre &amp; code tags: &lt;pre&gt;&lt;code&gt;...&lt;/code&gt;&lt;/pre&gt;
  162. * Wrap single-line code with code tags: &lt;code&gt;...&lt;/code&gt;
  163. For example, the code snippets included in either of the following markup examples would be escaped (note that the class attribute is not required for code escaping).
  164. This is a single-line example:
  165. <code class="language-php"><?php echo 'Hello world'; ?></code>
  166. This is a multi-line code example:
  167. <pre><code class="language-html">
  168. <table>
  169. <tr>
  170. <th>Name</th>
  171. <th>Side</th>
  172. <th>Role</th>
  173. <tr>
  174. <td>Darth</td>
  175. <td>Dark</td>
  176. <td>Sith</td>
  177. </tr>
  178. </table>
  179. </code></pre>
  180. So what exactly happens when the "Code Escaping" options are enabled? Here is a summary that applies to each section (post content, excerpts, and comments):
  181. * __Frontend only__ - code snippets are escaped at runtime (no changes made to content in the database)
  182. * __Admin Area only__ - code snippets are escaped when viewed via the Admin Area (changes will be saved to database if the "Update" or "Publish" button is clicked)
  183. * __Frontend &amp; Admin Area__ - both of the previous are applied
  184. * __None__ - all code escaping is disabled
  185. Note that each library &mdash; Prism.js, Highlight.js, and Plain Flavor &mdash; features its own code-escape settings. So the code-escape settings that are applied depends on the currently active library. Visit the plugin's General Settings to choose your library. Then visit that library's tab to configure its code-escape settings.
  186. When code escaping is enabled for either/both the frontend or Admin Area, the plugin makes the following changes to any code contained within &lt;code&gt;&lt;/code&gt; tags:
  187. \r removed
  188. & replaced with &amp;
  189. < replaced with &lt;
  190. > replaced with &gt;
  191. trailing whitespace removed
  192. These are the _only_ changes made to your code, no other changes are made.
  193. As mentioned, the difference between code escaping on the frontend vs. the Admin Area is that, on the frontend, the above changes are made at runtime and not saved to the database; whereas in the Admin Area, the changes are made when the code is viewed via a content editor, such that any changes made will be saved to the database when the user clicks the "Update" or "Publish" button. Please keep this in mind when choosing your code-escape settings.
  194. __Important!__ As explained, enabling code escaping in the Admin Area may result in the escaped code getting saved in the database. This is fine in most cases, but there may be situations where escaping should only happen at runtime. If that is the case, or if you are unsure, choose the "Frontend only" option for the "Code Escaping" setting. The "Frontend only" option only modifies code when displayed on the frontend and does not save any changes to the database.
  195. **Usage: Gutenberg Block Editor**
  196. To highlight a code block using Gutenberg:
  197. 1. Select the Prismatic block
  198. 2. Select a code language (via sidebar options)
  199. 3. Add your code and done.
  200. **Usage: Classic TinyMCE Editor**
  201. To highlight code using the TinyMCE/Visual/Rich-Text Editor:
  202. 1. Click the Prismatic button (looks like `<>`)
  203. 2. Choose a code language
  204. 3. Add your code and click "OK" button
  205. There also is a Prismatic Quicktag button ("pre") for those using the Plain-Text editor.
  206. **Usage: Prism.js Plugins**
  207. Currently the Prismatic plugin provides four plugins for Prism.js.
  208. * [Line Highlight](https://prismjs.com/plugins/line-highlight/) - Requires adding `data-line` attribute to the pre element
  209. * [Line Numbers](https://prismjs.com/plugins/line-numbers/) - Requires adding `line-numbers` attribute to the pre element
  210. * [Show Language](https://prismjs.com/plugins/show-language/) - No additional steps required
  211. * [Copy to Clipboard](https://prismjs.com/plugins/copy-to-clipboard/) - No additional steps required
  212. Any/all of these plugins can be enabled in the Prism.js settings. To learn more about usage and options, visit the plugin links in the above list.
  213. **About Prism.js**
  214. Prism.js version used in Prismatic plugin: __1.23.0__
  215. __Prism.js resources__
  216. * [Homepage](https://prismjs.com/)
  217. * [GitHub](https://github.com/PrismJS/prism)
  218. * [Changelog](https://github.com/PrismJS/prism/blob/gh-pages/CHANGELOG.md)
  219. __License &amp; Info__
  220. /*
  221. Prism: Lightweight, robust, elegant syntax highlighting
  222. MIT license https://www.opensource.org/licenses/mit-license.php/
  223. @author Lea Verou https://lea.verou.me
  224. */
  225. __Supported Languages__
  226. Language Class
  227. Apache = apacheconf
  228. AppleScript = applescript
  229. Arduino = arduino
  230. Bash = bash
  231. Batch = batch
  232. C = c
  233. C# = csharp
  234. C++ = cpp
  235. C-like = clike
  236. CoffeeScript = coffeescript
  237. CSS = css
  238. D = d
  239. Dart = dart
  240. Diff = diff
  241. Elixir = elixir
  242. G-code = gcode
  243. Git = git
  244. Go = go
  245. GraphQL = graphql
  246. Groovy = groovy
  247. HCL = hcl
  248. HTML/XML/Etc. = markup, html, xml, svg, mathml, ssml, atom, rss
  249. HTTP = http
  250. Ini = ini
  251. Java = java
  252. JavaScript = javascript
  253. JSON = json
  254. JSX = jsx
  255. Kotlin = kotlin
  256. LaTeX = latex
  257. Liquid = liquid
  258. Lua = lua
  259. Makefile = makefile
  260. Markdown = markdown
  261. Markup = markup
  262. NGINX = nginx
  263. Objective-C = objectivec
  264. Pascal = pascal
  265. Perl = perl
  266. PHP = php
  267. PowerQuery = powerquery, pq, mscript
  268. PowerShell = powershell
  269. Python = python
  270. R = r
  271. Ruby = ruby
  272. Rust = rust
  273. SASS = sass
  274. Scala = scala
  275. SCSS = scss
  276. Shell Session = shell-session
  277. Solidity = solidity
  278. Splunk SPL = splunk-spl
  279. SQL = sql
  280. Swift = swift
  281. TSX = tsx
  282. Twig = twig
  283. TypeScript = typescript
  284. Visual Basic = visual-basic
  285. YAML = yaml
  286. So for example, to specify a code block as C++, you would write:
  287. Single line: <code class="language-cpp">...</code>
  288. Multi-line: <pre><code class="language-cpp">...</code></pre>
  289. Alternate: <pre class="language-cpp"><code class="optional">...</code></pre>
  290. Note: in the previous example, ignore the `class="optional"` added to the code tag (for the "Alternate" syntax); it is used to prevent markdown from mangling the code example on this web page.
  291. To disable Prism.js syntax highlighting for any snippet, simply omit the language class. Or, to disable syntax highlighting for a code snippet while also loading the Prism.js stylesheet, add a class of `language-none`, for example:
  292. <code class="language-none">...</code>
  293. _I'm glad to add more languages, [make a suggestion](https://perishablepress.com/contact/)_
  294. **About Highlight.js**
  295. Highlight.js version used in Prismatic plugin: __10.5.0__
  296. __Highlight.js resources__
  297. * [Homepage](https://highlightjs.org/)
  298. * [GitHub](https://github.com/isagalaev/highlight.js)
  299. * [Changelog](https://github.com/isagalaev/highlight.js/blob/master/CHANGES.md)
  300. __License &amp; Info__
  301. /*
  302. Syntax highlighting with language autodetection.
  303. Copyright (c) 2006, Ivan Sagalaev https://highlightjs.org/
  304. All rights reserved. BSD3 License @ https://git.io/hljslicense
  305. */
  306. __Supported Languages__
  307. Language Class
  308. Apache = apache, apacheconf
  309. AppleScript = applescript, osascript
  310. Arduino = arduino
  311. Bash = bash, sh, zsh
  312. C = c, h
  313. C# = cs, csharp
  314. C++ = cpp, c, cc, h, c++, h++, hpp
  315. CSS = css
  316. CoffeeScript = coffeescript, coffee, cson, iced
  317. D = d
  318. Dart = dart
  319. Diff = diff, patch
  320. Elixir = elixir
  321. G-code = gcode, nc
  322. GML = gml
  323. Go = go, golang
  324. Groovy = groovy
  325. HTML/XML/Etc. = xml, html, xhtml, rss, atom, xjb, xsd, xsl, plist
  326. HTTP = http, https
  327. Ini/TOML = ini, toml
  328. JSON = json
  329. Java = java, jsp
  330. JavaScript = javascript, js, jsx
  331. Kotlin = kotlin
  332. Less = less
  333. Lua = lua
  334. Makefile = makefile, mk, mak
  335. Markdown = markdown, md, mkdown, mkd
  336. Nginx = nginx, nginxconf
  337. Objective-C = objectivec, mm, objc, obj-c
  338. PHP = php, php3, php4, php5, php6
  339. Perl = perl, pl, pm
  340. Plaintext = plaintext, txt, text
  341. PowerShell = powershell, ps
  342. Properties = properties
  343. Python = python, py, gyp
  344. Python REPL = python-repl, pycon
  345. R = r
  346. Ruby = ruby, rb, gemspec, podspec, thor, irb
  347. Rust = rust
  348. Scala = scala
  349. SCSS = scss
  350. Shell Session = shell
  351. SQL = sql
  352. Swift = swift
  353. TypeScript = typescript, ts
  354. VB.Net = vbnet, vb
  355. YAML = yaml
  356. So for example, to specify a code block as C++, you would write:
  357. Single line: <code class="language-cpp">...</code>
  358. Multi-line: <pre><code class="language-cpp">...</code></pre>
  359. Alternate: <pre class="language-cpp"><code class="optional">...</code></pre>
  360. Note: in the previous example, ignore the `class="optional"` added to the code tag (for the "Alternate" syntax); it is used to prevent markdown from mangling the code example on this web page.
  361. To disable Highlight.js syntax highlighting for any code block, add a class of `nohighlight`, like so:
  362. <code class="nohighlight">...</code>
  363. Similarly, you can add a class of `plaintext` to make arbitrary text look like code, but without highlighting:
  364. <code class="plaintext">...</code>
  365. _I'm glad to add more languages, [make a suggestion](https://perishablepress.com/contact/)_
  366. == Upgrade Notice ==
  367. To upgrade Prismatic, remove the old version and replace with the new version. Or just click "Update" from the Plugins screen and let WordPress do it for you automatically.
  368. __Note:__ uninstalling the plugin from the WP Plugins screen results in the removal of all settings from the WP database.
  369. == Frequently Asked Questions ==
  370. **Can you add another language for Prism.js or Highlight.js?**
  371. Yes, feel free to [suggest a language](https://perishablepress.com/contact/)
  372. **Does this work with Gutenberg Block Editor?**
  373. Yes, the plugin provides a "Prismatic" block that makes it easy to add code snippets that will be highlighted on the front-end. Also provides "add code" buttons for the Classic TinyMCE (Visual/Text) Editor. Add code, choose a language, done!
  374. **Display syntax-highlighted code inside Block Editor?**
  375. If for some reason you want to view syntax-highlighted code inside of the Block Editor, you can do it with the Classic Block:
  376. 1. Select the Classic Block
  377. 2. Click on the Prismatic TinyMCE button
  378. 3. Enter your code and save changes
  379. The code won't be highlighted initially, but if you refresh the page after making changes, or visit the page again in the future, the code will be displayed with syntax highlighting applied.
  380. **How to syntax highlight code inside of ACF field?**
  381. As of Prismatic version 2.3, code snippets inside of ACF fields are highlighted automatically. Simply add the required class (e.g., `language-php`) just like any other code snippet, and the plugin will detect and highlight the code. To also escape the highlighted code, enable escaping for post content via the setting, Prism &gt; Code Escaping &gt; Content. Note: ACF is supported only on single post views.
  382. **How to make highlighting work with Autoptimize?**
  383. For Prismatic plugin to work with Autoptimize, a script needs to be excluded. For details, check out [this post](https://ncoughlin.com/prismatic-syntax-highlighter-compatibility-autoptimize-plugin/) by Nick Coughlin.
  384. **How to disable block styles on frontend?**
  385. If you are not using Gutenberg Block Editor, you can disable the plugin's block stylesheet. Simply enable the plugin setting, "Block Styles". Save changes and done.
  386. FYI: the Prismatic block styles are included via: `/prismatic/css/styles-blocks.css`
  387. **How to escape nested code tags?**
  388. Currently the only way to display nested `<code>` tags is to use the following shortcode:
  389. `[prismatic_code][/prismatic_code]`
  390. Currently this works only for **inline** `<code>` tags. More details [here](https://wordpress.org/support/topic/sourcecode-with-tags-i-e-nested-tags/#post-13651551).
  391. **Got a question?**
  392. Send any questions or feedback via my [contact form](https://perishablepress.com/contact/)
  393. == Support development of this plugin ==
  394. I develop and maintain this free plugin with love for the WordPress community. To show support, you can [make a donation](https://monzillamedia.com/donate.html) or purchase one of my books:
  395. * [The Tao of WordPress](https://wp-tao.com/)
  396. * [Digging into WordPress](https://digwp.com/)
  397. * [.htaccess made easy](https://htaccessbook.com/)
  398. * [WordPress Themes In Depth](https://wp-tao.com/wordpress-themes-book/)
  399. And/or purchase one of my premium WordPress plugins:
  400. * [BBQ Pro](https://plugin-planet.com/bbq-pro/) - Super fast WordPress firewall
  401. * [Blackhole Pro](https://plugin-planet.com/blackhole-pro/) - Automatically block bad bots
  402. * [Banhammer Pro](https://plugin-planet.com/banhammer-pro/) - Monitor traffic and ban the bad guys
  403. * [GA Google Analytics Pro](https://plugin-planet.com/ga-google-analytics-pro/) - Connect WordPress to Google Analytics
  404. * [USP Pro](https://plugin-planet.com/usp-pro/) - Unlimited front-end forms
  405. Links, tweets and likes also appreciated. Thank you! :)
  406. == Changelog ==
  407. Thank you to everyone providing feedback! If you like Prismatic, please take a moment to [give a 5-star rating](https://wordpress.org/support/plugin/prismatic/reviews/?rate=5#new-post). It helps to keep development and support going strong. Thank you!
  408. **2.7 (2021/02/09)**
  409. * Updates Highlight.js to version 10.5.0
  410. * Adds several new Highlight.js themes
  411. * Adds Highlight.js langauges: C, Less, Properties, Python REPL, SCSS, VB.Net
  412. * Updates Prism.js to version 1.23.0
  413. * Adds Prism.js plugin, [Command Line](https://prismjs.com/plugins/command-line/)
  414. * Adds Prism.js languages: Splunk SPL, PowerQuery
  415. * Improves loading of `prismatic-blocks` stylesheet (Thanks [@hwk-fr](https://wordpress.org/support/topic/missing-style-dependency-primatic-blocks/))
  416. * Fixes bug with Visual Editor and code escaping
  417. * Fixes bug with jQuery modal styles
  418. * Updates default translation template
  419. * Tests on WordPress 5.7
  420. **2.6 (2020/11/10)**
  421. * Adds option to disable the Prismatic block stylesheet
  422. * Adds `[prismatic_code]` shortcode for [nested code tags](https://wordpress.org/support/topic/sourcecode-with-tags-i-e-nested-tags/)
  423. * Updates plugin script to account for changes in jQuery UI
  424. * Fixes PHP Warnings re: `preg_split()` and `count()`
  425. * Fixes bug with Visual Editor button and contributors
  426. * Fixes bug with Visual Editor and code escaping (Thanks [@mgongee](https://wordpress.org/support/topic/html-tags-are-stripped-out-instead-of-being-escaped/))
  427. * Improves the appearance of the plugin settings page
  428. * Updates default translation template
  429. * Tests on PHP 7.4 and 8.0
  430. * Tests on WordPress 5.6
  431. **2.5 (2020/08/07)**
  432. Prism.js
  433. * Updates Prism.js to version 1.21.0
  434. * Updates all Prism plugins and themes
  435. * Adds languages: Elixir, G-code, HCL, Liquid, R, Solidity
  436. * Adds markup aliases (html, xml, svg, mathml, ssml, atom, rss)
  437. Highlight.js
  438. * Updates Highlight.js to version 10.1.2
  439. * Updates all Highlight.js styles
  440. * Adds languages: Elixir, G-code, R
  441. * Removes `darkula` stylesheet and option
  442. * Adds styles `lioshi`, `nnfx`, `nnfx-dark`, `srcery`
  443. * Bugfix: Adds missing style options to settings menu
  444. * Bugfix: Adds missing `plaintext` to code block options
  445. General
  446. * Refines readme/documentation
  447. * Tests on WordPress 5.5
  448. **2.4 (2020/03/13)**
  449. * Upgrades Prism.js library to version 1.19.0
  450. * Upgrades Highlight.js library to version 9.18.1
  451. * Adds Shell Session, Batch, Rust languages to Prism.js
  452. * Adds Rust language to Highlight.js
  453. * Fixes PHP warnings about `strpos()` and `preg_split()`
  454. * Adds version number to enqueued scripts and styles
  455. * Fine tunes language and copy code button styles
  456. * Tests on WordPress 5.4
  457. **2.3 (2019/10/27)**
  458. * Updates styles for plugin settings page
  459. * Fixes bug with older versions of WordPress
  460. * Adds "copy code to clipboard" button for Prism.js
  461. * Adds support for Prism.js highlighting in ACF fields
  462. * Adds support for `language-none` for Prism.js
  463. * Generates new default translation template
  464. * Updates documentation with further infos
  465. * Tests on WordPress 5.3
  466. **2.2 (2019/08/16)**
  467. * Resolves several warnings in PHP 7+
  468. * Adds `prismatic_get_default_options()`
  469. * Adds Quicktag button for plain-text editor
  470. * Adds TinyMCE buttons for Prism.js and Highlight.js
  471. * Adds Blocks for Prism.js, Highlight.js, and Plain Flavor
  472. * Changes priority of content filter in `prismatic_add_filters()`
  473. * Updates Highlight.js core to version 9.15.9
  474. * Adds YAML language for Highlight.js
  475. * Updates Prism.js core to version 1.17.1
  476. * Adds TSX language for Prism.js
  477. * Updates some links to https
  478. * Generates new default translation template
  479. * Tests on WordPress 5.3 (alpha)
  480. **2.1 (2019/04/28)**
  481. * Bumps [minimum PHP version](https://codex.wordpress.org/Template:Server_requirements) to 5.6.20
  482. * Adds Arduino language for Prism.js
  483. * Updates Prism.js to latest version 1.16.0
  484. * Updates Prism.js script for Java langauge
  485. * Updates Prism.js themes and plugins
  486. * Adds Arduino language for Highlight.js
  487. * Adds GML language for Highlight.js
  488. * Updates all Highlight.js stylesheets
  489. * Updates default translation template
  490. * Tests on WordPress 5.2
  491. **2.0 (2019/03/06)**
  492. * Updates Highlight.js to latest version 9.15.6
  493. * Adds Highlight.js languages: D, Dart, Scala
  494. * Adds 10 new Highlight.js themes
  495. * Updates Prism.js to latest version 1.15.0
  496. * Adds Prism.js languages: D, JSX, Dart, Scala
  497. * Adds check for admin user for settings shortcut link
  498. * Tweaks plugin settings screen UI
  499. * Generates new default translation template
  500. * Tests on WordPress 5.1 and 5.2 (alpha)
  501. **1.9 (2019/02/02)**
  502. * Just a version bump for compat with WP 5.1
  503. * Full update coming soon :)
  504. **1.8 (2018/11/14)**
  505. * Fixes bug: Invalid argument foreach() resources-enqueue.php line 267
  506. * Adds homepage link to Plugins screen
  507. * Updates default translation template
  508. * Tests on WordPress 5.0 (beta)
  509. **1.7 (2018/08/17)**
  510. * Adds `rel="noopener noreferrer"` to all [blank-target links](https://perishablepress.com/wordpress-blank-target-vulnerability/)
  511. * Updates GDPR blurb and donate link
  512. * Tweaks appearance of plugin settings page
  513. * Generates new default translation template
  514. * Further tests on WP versions 4.9 and 5.0 (alpha)
  515. **1.6/1.6.1 (2018/05/07)**
  516. * Updates Prism.js from 1.11 to 1.14
  517. * Adds new Prism theme: "Tomorrow Night"
  518. * Adds Prism language support for Go `go`, VBA `visual-basic`, Pascal `pascal`
  519. * Adds Highlight language support for Go `go`
  520. * Improves support for Gutenberg Editor
  521. * Removes unused font file, `FontAwesome.otf`
  522. * Tests on WordPress 5.0 (alpha)
  523. **1.5 (2017/10/22)**
  524. * Adds "Requires PHP" to plugin file headers
  525. * Tests on WordPress 4.9
  526. **1.4 (2017/07/31)**
  527. * Fixes several PHP Warnings
  528. * Updates Highlight.js to version 9.12.0
  529. * Adds new languages for Highlight.js and Prism.js
  530. * Adds GPL license text file
  531. * Tests on WordPress 4.9 (alpha)
  532. **1.3 (2017/03/24)**
  533. * Updates some URLs to HTTPS
  534. * Updates Prism.js to version 1.6
  535. * Updates Highlight.js to version 9.11.0
  536. * Adds new languages for Highlight.js and Prism.js
  537. * Tweaks plugin settings styles
  538. * Replaces global `$wp_version` with `get_bloginfo('version')`
  539. * Tests on WordPress version 4.8
  540. **1.2 (2016/11/16)**
  541. * Adds support for AppleScript in Highlight.js
  542. * Updates plugin URL in core files and readme.txt
  543. * Changes stable tag from trunk to latest version
  544. * Adds `&raquo;` to rate this link on Plugins screen
  545. * Adds strong tags to admin notices on settings page
  546. * Refines styles for popup dialog on settings page
  547. * Tests on WordPress version 4.7 (beta)
  548. **1.1 (2016/10/24)**
  549. * Updates/adds some links
  550. * Updates default language file
  551. * Tests on WordPress version 4.7 (alpha)
  552. **1.0 (2016/10/21)**
  553. * Initial release