Changeset 2602711
- Timestamp:
- 09/22/2021 01:28:05 AM (5 years ago)
- Location:
- awesome-code-highlighting/trunk
- Files:
-
- 2 edited
-
index.php (modified) (2 diffs)
-
readme.txt (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
awesome-code-highlighting/trunk/index.php
r2485627 r2602711 10 10 Tags: code highlight, syntax 11 11 */ 12 13 require_once(__DIR__ . '/customizer.php'); 14 12 15 class RBK_Code_Highlight { 13 16 public function __construct() { … … 15 18 add_action('wp_footer', array($this, 'rbk_remove_pre_style')); 16 19 } 20 21 public $options = array( 22 23 ); 24 17 25 public function rbk_code_highlights(){ 18 26 wp_enqueue_script('rbk-code-highlights-js', plugin_dir_url( __FILE__ ).'highlight.pack.js', array()); 19 27 wp_enqueue_script('rbk-code-highlights-js-2', plugin_dir_url( __FILE__ ).'init-highlight.js', array('rbk-code-highlights-js')); 20 wp_enqueue_style('rbk-code-highlights-css', plugin_dir_url( __FILE__ ).'styles/ atom-one-dark.css');28 wp_enqueue_style('rbk-code-highlights-css', plugin_dir_url( __FILE__ ).'styles/'.get_option('code_highlighting_theme').'.css'); 21 29 } 22 30 public function rbk_remove_pre_style() { -
awesome-code-highlighting/trunk/readme.txt
r2485627 r2602711 4 4 Tags: code 5 5 Requires at least: 3.0.1 6 Tested up to: 5. 6.27 Stable tag: 0.0. 26 Tested up to: 5.7.0 7 Stable tag: 0.0.3 8 8 License: GPLv2 or later 9 9 License URI: http://www.gnu.org/licenses/gpl-2.0.html … … 15 15 This plugin uses highlight.js to detect and highlight "pre" HTML tags. 16 16 17 To c ustomize the color scheme update change the wp_enqueue_style called in the index.php to match a file name in the styles directory.17 To color theme use the customizer: Appearance -> Customize -> Code Highlighting Theme 18 18 19 19 == Installation ==
Note: See TracChangeset
for help on using the changeset viewer.