From ecc82b20417806b6780877a8dbb8efc578fc95aa Mon Sep 17 00:00:00 2001 From: Paul Schreiber Date: Thu, 12 Jul 2018 00:05:10 -0400 Subject: [PATCH 1/8] use short array syntax --- mathjax-latex-admin.php | 46 +++++++-------- mathjax-latex.php | 126 ++++++++++++++++++++-------------------- 2 files changed, 86 insertions(+), 86 deletions(-) diff --git a/mathjax-latex-admin.php b/mathjax-latex-admin.php index e4b839e..7574639 100644 --- a/mathjax-latex-admin.php +++ b/mathjax-latex-admin.php @@ -21,31 +21,31 @@ class MathJax_Latex_Admin { - public static $admin_tags = array( - 'input' => array( - 'type' => array(), - 'name' => array(), - 'id' => array(), - 'disabled' => array(), - 'value' => array(), - 'checked' => array(), - ), - 'select' => array( - 'name' => array(), - 'id' => array(), - ), - 'option' => array( - 'value' => array(), - 'selected' => array(), - ), - ); + public static $admin_tags = [ + 'input' => [ + 'type' => [], + 'name' => [], + 'id' => [], + 'disabled' => [], + 'value' => [], + 'checked' => [], + ], + 'select' => [ + 'name' => [], + 'id' => [], + ], + 'option' => [ + 'value' => [], + 'selected' => [], + ], + ]; public function __construct() { - add_action( 'admin_menu', array( $this, 'admin_page_init' ) ); + add_action( 'admin_menu', [ $this, 'admin_page_init' ] ); } public function admin_page_init() { - add_options_page( 'MathJax-LaTeX', 'MathJax-LaTeX', 'manage_options', 'kblog-mathjax-latex', array( $this, 'plugin_options_menu' ) ); + add_options_page( 'MathJax-LaTeX', 'MathJax-LaTeX', 'manage_options', 'kblog-mathjax-latex', [ $this, 'plugin_options_menu' ] ); } public function plugin_options_menu() { @@ -146,12 +146,12 @@ public function plugin_options_menu() { } public function config_options() { - $options = array( + $options = [ 'default', 'Accessible', 'TeX-AMS_HTML', 'TeX-AMS-MML_HTMLorMML', - ); + ]; return $options; } @@ -164,7 +164,7 @@ public function admin_save() { update_option( 'kblog_mathjax_force_load', array_key_exists( 'kblog_mathjax_force_load', $_POST ) ); // input var okay if ( array_key_exists( 'kblog_mathjax_latex_inline', $_POST ) && isset( $_POST['kblog_mathjax_latex_inline'] ) && // input var okay - in_array( sanitize_text_field( wp_unslash( $_POST['kblog_mathjax_latex_inline'] ) ), array( 'inline', 'display' ), true ) // input var okay + in_array( sanitize_text_field( wp_unslash( $_POST['kblog_mathjax_latex_inline'] ) ), [ 'inline', 'display' ], true ) // input var okay ) { update_option( 'kblog_mathjax_latex_inline', sanitize_text_field( wp_unslash( $_POST['kblog_mathjax_latex_inline'] ) ) ); // input var okay } diff --git a/mathjax-latex.php b/mathjax-latex.php index 9c07c0a..f6fb554 100644 --- a/mathjax-latex.php +++ b/mathjax-latex.php @@ -39,75 +39,75 @@ class MathJax { public static $add_script; public static $block_script; - public static $mathml_tags = array( - 'math' => array( 'class', 'id', 'style', 'dir', 'href', 'mathbackground', 'mathcolor', 'display', 'overflow', 'xmlns' ), - 'maction' => array( 'actiontype', 'class', 'id', 'style', 'href', 'mathbackground', 'mathcolor', 'selection' ), - 'maligngroup' => array(), - 'malignmark' => array(), - 'menclose' => array( 'class', 'id', 'style', 'href', 'mathbackground', 'mathcolor', 'notation' ), - 'merror' => array( 'class', 'id', 'style', 'href', 'mathbackground', 'mathcolor' ), - 'mfenced' => array( 'class', 'id', 'style', 'close', 'href', 'mathbackground', 'mathcolor', 'open', 'separators' ), - 'mfrac' => array( 'bevelled', 'class', 'id', 'style', 'denomalign', 'href', 'linethickness', 'mathbackground', 'mathcolor', 'numalign' ), - 'mglyph' => array( 'alt', 'class', 'id', 'style', 'height', 'href', 'mathbackground', 'src', 'valign', 'width' ), - 'mi' => array( 'class', 'id', 'style', 'href', 'mathbackground', 'mathcolor', 'mathsize', 'mathvariant' ), - 'mlabeledtr' => array( 'class', 'id', 'style', 'columnalign', 'groupalign', 'href', 'mathbackground', 'mathcolor', 'rowalign' ), - 'mlongdiv' => array(), - 'mmultiscripts' => array( 'class', 'id', 'style', 'href', 'mathbackground', 'mathcolor', 'subscriptshift', 'superscriptshift' ), - 'mn' => array( 'class', 'id', 'style', 'dir', 'href', 'mathbackground', 'mathcolor', 'mathsize', 'mathvariant' ), - 'mo' => array( 'accent', 'class', 'id', 'style', 'dir', 'fence', 'form', 'href', 'largeop', 'lspace', 'mathbackground', 'mathcolor', 'mathsize', 'mathvariant', 'maxsize', 'minsize', 'moveablelimits', 'rspace', 'separator', 'stretchy', 'symmetric' ), - 'mover' => array( 'accent', 'align', 'class', 'id', 'style', 'href', 'mathbackground', 'mathcolor' ), - 'mpadded' => array( 'class', 'id', 'style', 'depth', 'height', 'href', 'lspace', 'mathbackground', 'mathcolor', 'voffset', 'width' ), - 'mphantom' => array( 'class', 'id', 'style', 'mathbackground' ), - 'mroot' => array( 'class', 'id', 'style', 'href', 'mathbackground', 'mathcolor' ), - 'mrow' => array( 'class', 'id', 'style', 'dir', 'href', 'mathbackground', 'mathcolor' ), - 'ms' => array( 'class', 'id', 'style', 'dir', 'lquote', 'href', 'mathbackground', 'mathcolor', 'mathsize', 'mathvariant', 'rquote' ), - 'mscarries' => array(), - 'mscarry' => array(), - 'msgroup' => array(), - 'msline' => array(), - 'mspace' => array( 'class', 'id', 'style', 'depth', 'height', 'linebreak', 'mathbackground', 'width' ), - 'msqrt' => array( 'class', 'id', 'style', 'href', 'mathbackground', 'mathcolor' ), - 'msrow' => array(), - 'mstack' => array(), - 'mstyle' => array( 'dir', 'decimalpoint', 'displaystyle', 'infixlinebreakstyle', 'scriptlevel', 'scriptminsize', 'scriptsizemultiplier' ), - 'msub' => array( 'class', 'id', 'style', 'mathbackground', 'mathcolor', 'subscriptshift' ), - 'msubsup' => array( 'class', 'id', 'style', 'href', 'mathbackground', 'mathcolor', 'subscriptshift', 'superscriptshift' ), - 'msup' => array( 'class', 'id', 'style', 'href', 'mathbackground', 'mathcolor', 'superscriptshift' ), - 'mtable' => array( 'class', 'id', 'style', 'align', 'alignmentscope', 'columnalign', 'columnlines', 'columnspacing', 'columnwidth', 'displaystyle', 'equalcolumns', 'equalrows', 'frame', 'framespacing', 'groupalign', 'href', 'mathbackground', 'mathcolor', 'minlabelspacing', 'rowalign', 'rowlines', 'rowspacing', 'side', 'width' ), - 'mtd' => array( 'class', 'id', 'style', 'columnalign', 'columnspan', 'groupalign', 'href', 'mathbackground', 'mathcolor', 'rowalign', 'rowspan' ), - 'mtext' => array( 'class', 'id', 'style', 'dir', 'href', 'mathbackground', 'mathcolor', 'mathsize', 'mathvariant' ), - 'mtr' => array( 'class', 'id', 'style', 'columnalign', 'groupalign', 'href', 'mathbackground', 'mathcolor', 'rowalign' ), - 'munder' => array( 'accentunder', 'align', 'class', 'id', 'style', 'mathbackground', 'mathcolor' ), - 'munderover' => array( 'accent', 'accentunder', 'align', 'class', 'id', 'style', 'href', 'mathbackground', 'mathcolor' ), - 'semantics' => array( 'definitionURL', 'encoding', 'cd', 'name', 'src' ), - 'annotation' => array( 'definitionURL', 'encoding', 'cd', 'name', 'src' ), - 'annotation-xml' => array( 'definitionURL', 'encoding', 'cd', 'name', 'src' ), - ); + public static $mathml_tags = [ + 'math' => [ 'class', 'id', 'style', 'dir', 'href', 'mathbackground', 'mathcolor', 'display', 'overflow', 'xmlns' ], + 'maction' => [ 'actiontype', 'class', 'id', 'style', 'href', 'mathbackground', 'mathcolor', 'selection' ], + 'maligngroup' => [], + 'malignmark' => [], + 'menclose' => [ 'class', 'id', 'style', 'href', 'mathbackground', 'mathcolor', 'notation' ], + 'merror' => [ 'class', 'id', 'style', 'href', 'mathbackground', 'mathcolor' ], + 'mfenced' => [ 'class', 'id', 'style', 'close', 'href', 'mathbackground', 'mathcolor', 'open', 'separators' ], + 'mfrac' => [ 'bevelled', 'class', 'id', 'style', 'denomalign', 'href', 'linethickness', 'mathbackground', 'mathcolor', 'numalign' ], + 'mglyph' => [ 'alt', 'class', 'id', 'style', 'height', 'href', 'mathbackground', 'src', 'valign', 'width' ], + 'mi' => [ 'class', 'id', 'style', 'href', 'mathbackground', 'mathcolor', 'mathsize', 'mathvariant' ], + 'mlabeledtr' => [ 'class', 'id', 'style', 'columnalign', 'groupalign', 'href', 'mathbackground', 'mathcolor', 'rowalign' ], + 'mlongdiv' => [], + 'mmultiscripts' => [ 'class', 'id', 'style', 'href', 'mathbackground', 'mathcolor', 'subscriptshift', 'superscriptshift' ], + 'mn' => [ 'class', 'id', 'style', 'dir', 'href', 'mathbackground', 'mathcolor', 'mathsize', 'mathvariant' ], + 'mo' => [ 'accent', 'class', 'id', 'style', 'dir', 'fence', 'form', 'href', 'largeop', 'lspace', 'mathbackground', 'mathcolor', 'mathsize', 'mathvariant', 'maxsize', 'minsize', 'moveablelimits', 'rspace', 'separator', 'stretchy', 'symmetric' ], + 'mover' => [ 'accent', 'align', 'class', 'id', 'style', 'href', 'mathbackground', 'mathcolor' ], + 'mpadded' => [ 'class', 'id', 'style', 'depth', 'height', 'href', 'lspace', 'mathbackground', 'mathcolor', 'voffset', 'width' ], + 'mphantom' => [ 'class', 'id', 'style', 'mathbackground' ], + 'mroot' => [ 'class', 'id', 'style', 'href', 'mathbackground', 'mathcolor' ], + 'mrow' => [ 'class', 'id', 'style', 'dir', 'href', 'mathbackground', 'mathcolor' ], + 'ms' => [ 'class', 'id', 'style', 'dir', 'lquote', 'href', 'mathbackground', 'mathcolor', 'mathsize', 'mathvariant', 'rquote' ], + 'mscarries' => [], + 'mscarry' => [], + 'msgroup' => [], + 'msline' => [], + 'mspace' => [ 'class', 'id', 'style', 'depth', 'height', 'linebreak', 'mathbackground', 'width' ], + 'msqrt' => [ 'class', 'id', 'style', 'href', 'mathbackground', 'mathcolor' ], + 'msrow' => [], + 'mstack' => [], + 'mstyle' => [ 'dir', 'decimalpoint', 'displaystyle', 'infixlinebreakstyle', 'scriptlevel', 'scriptminsize', 'scriptsizemultiplier' ], + 'msub' => [ 'class', 'id', 'style', 'mathbackground', 'mathcolor', 'subscriptshift' ], + 'msubsup' => [ 'class', 'id', 'style', 'href', 'mathbackground', 'mathcolor', 'subscriptshift', 'superscriptshift' ], + 'msup' => [ 'class', 'id', 'style', 'href', 'mathbackground', 'mathcolor', 'superscriptshift' ], + 'mtable' => [ 'class', 'id', 'style', 'align', 'alignmentscope', 'columnalign', 'columnlines', 'columnspacing', 'columnwidth', 'displaystyle', 'equalcolumns', 'equalrows', 'frame', 'framespacing', 'groupalign', 'href', 'mathbackground', 'mathcolor', 'minlabelspacing', 'rowalign', 'rowlines', 'rowspacing', 'side', 'width' ], + 'mtd' => [ 'class', 'id', 'style', 'columnalign', 'columnspan', 'groupalign', 'href', 'mathbackground', 'mathcolor', 'rowalign', 'rowspan' ], + 'mtext' => [ 'class', 'id', 'style', 'dir', 'href', 'mathbackground', 'mathcolor', 'mathsize', 'mathvariant' ], + 'mtr' => [ 'class', 'id', 'style', 'columnalign', 'groupalign', 'href', 'mathbackground', 'mathcolor', 'rowalign' ], + 'munder' => [ 'accentunder', 'align', 'class', 'id', 'style', 'mathbackground', 'mathcolor' ], + 'munderover' => [ 'accent', 'accentunder', 'align', 'class', 'id', 'style', 'href', 'mathbackground', 'mathcolor' ], + 'semantics' => [ 'definitionURL', 'encoding', 'cd', 'name', 'src' ], + 'annotation' => [ 'definitionURL', 'encoding', 'cd', 'name', 'src' ], + 'annotation-xml' => [ 'definitionURL', 'encoding', 'cd', 'name', 'src' ], + ]; public static function init() { - register_activation_hook( __FILE__, array( __CLASS__, 'mathjax_install' ) ); - register_deactivation_hook( __FILE__, array( __CLASS__, 'mathjax_uninstall' ) ); + register_activation_hook( __FILE__, [ __CLASS__, 'mathjax_install' ] ); + register_deactivation_hook( __FILE__, [ __CLASS__, 'mathjax_uninstall' ] ); if ( get_option( 'kblog_mathjax_force_load' ) ) { self::$add_script = true; } - add_shortcode( 'mathjax', array( __CLASS__, 'mathjax_shortcode' ) ); - add_shortcode( 'nomathjax', array( __CLASS__, 'nomathjax_shortcode' ) ); - add_shortcode( 'latex', array( __CLASS__, 'latex_shortcode' ) ); - add_action( 'wp_footer', array( __CLASS__, 'add_script' ) ); - add_filter( 'script_loader_tag', array( __CLASS__, 'script_loader_tag' ), 10, 3 ); + add_shortcode( 'mathjax', [ __CLASS__, 'mathjax_shortcode' ] ); + add_shortcode( 'nomathjax', [ __CLASS__, 'nomathjax_shortcode' ] ); + add_shortcode( 'latex', [ __CLASS__, 'latex_shortcode' ] ); + add_action( 'wp_footer', [ __CLASS__, 'add_script' ] ); + add_filter( 'script_loader_tag', [ __CLASS__, 'script_loader_tag' ], 10, 3 ); if ( get_option( 'kblog_mathjax_use_wplatex_syntax' ) ) { - add_filter( 'the_content', array( __CLASS__, 'inline_to_shortcode' ) ); + add_filter( 'the_content', [ __CLASS__, 'inline_to_shortcode' ] ); } - add_filter( 'plugin_action_links', array( __CLASS__, 'mathjax_settings_link' ), 9, 2 ); + add_filter( 'plugin_action_links', [ __CLASS__, 'mathjax_settings_link' ], 9, 2 ); - add_filter( 'the_content', array( __CLASS__, 'filter_br_tags_on_math' ) ); + add_filter( 'the_content', [ __CLASS__, 'filter_br_tags_on_math' ] ); - add_action( 'init', array( __CLASS__, 'allow_mathml_tags' ) ); - add_filter( 'tiny_mce_before_init', array( __CLASS__, 'allow_mathml_tags_in_tinymce' ) ); + add_action( 'init', [ __CLASS__, 'allow_mathml_tags' ] ); + add_filter( 'tiny_mce_before_init', [ __CLASS__, 'allow_mathml_tags_in_tinymce' ] ); } // registers default options @@ -142,9 +142,9 @@ public static function latex_shortcode( $atts, $content ) { // this gives us an optional "syntax" attribute, which defaults to "inline", but can also be "display" $shortcode_atts = shortcode_atts( - array( + [ 'syntax' => get_option( 'kblog_mathjax_latex_inline' ), - ), $atts + ], $atts ); if ( 'inline' === $shortcode_atts['syntax'] ) { @@ -174,7 +174,7 @@ public static function add_script() { wp_enqueue_script( 'mathjax', $mathjax_url, false, MATHJAX_VERSION, false ); - $mathjax_config = apply_filters( 'mathjax_config', array() ); + $mathjax_config = apply_filters( 'mathjax_config', [] ); if ( $mathjax_config ) { wp_add_inline_script( 'mathjax', 'MathJax.Hub.Config(' . wp_json_encode( $mathjax_config ) . ');' ); } @@ -206,7 +206,7 @@ public static function inline_to_shortcode( $content ) { self::$add_script = true; - return preg_replace_callback( '#\$latex[= ](.*?[^\\\\])\$#', array( __CLASS__, 'inline_to_shortcode_callback' ), $content ); + return preg_replace_callback( '#\$latex[= ](.*?[^\\\\])\$#', [ __CLASS__, 'inline_to_shortcode_callback' ], $content ); } public static function inline_to_shortcode_callback( $matches ) { @@ -250,7 +250,7 @@ public static function filter_br_tags_on_math( $content ) { return preg_replace_callback( '/(.*<\/math>)/isU', function( $matches ) { - return str_replace( array( '
', '
', '
' ), '', $matches[0] ); + return str_replace( [ '
', '
', '
' ], '', $matches[0] ); }, $content ); @@ -265,7 +265,7 @@ public static function allow_mathml_tags() { global $allowedposttags; foreach ( self::$mathml_tags as $tag => $attributes ) { - $allowedposttags[ $tag ] = array(); + $allowedposttags[ $tag ] = []; foreach ( $attributes as $a ) { $allowedposttags[ $tag ][ $a ] = true; @@ -279,7 +279,7 @@ public static function allow_mathml_tags() { */ public static function allow_mathml_tags_in_tinymce( $options ) { - $extended_tags = array(); + $extended_tags = []; foreach ( self::$mathml_tags as $tag => $attributes ) { if ( ! empty( $attributes ) ) { From 2860e4906f6ccc0b3c6e7d8f67a6c4daf9cc82ba Mon Sep 17 00:00:00 2001 From: Yang Liu Date: Wed, 25 Jul 2018 17:06:55 +1000 Subject: [PATCH 2/8] Add null check in filter_br_tags_on_math --- mathjax-latex.php | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/mathjax-latex.php b/mathjax-latex.php index a8bf0f5..70f8ed0 100644 --- a/mathjax-latex.php +++ b/mathjax-latex.php @@ -243,13 +243,14 @@ public static function mathjax_settings_link( $links, $file ) { * @return string without
tags */ public static function filter_br_tags_on_math( $content ) { - return preg_replace_callback( - '/(.*<\/math>)/isU', - function( $matches ) { - return str_replace( array( '
', '
', '
' ) , '' , $matches[0] ); - }, - $content - ); + $filteredContent = preg_replace_callback( + '/(.*<\/math>)/isU', + function( $matches ) { + return str_replace( array( '
', '
', '
' ) , '' , $matches[0] ); + }, + $content + ); + return $filteredContent === null ? $content : $filteredContent; } /** From 1e2415a00497d8dc1689c3e6691c3a2a0baa38ef Mon Sep 17 00:00:00 2001 From: Paul Schreiber Date: Wed, 25 Jul 2018 11:01:38 -0400 Subject: [PATCH 3/8] rename MathJax class to MathJax_Latex --- mathjax-latex.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mathjax-latex.php b/mathjax-latex.php index f6fb554..59a1fb1 100644 --- a/mathjax-latex.php +++ b/mathjax-latex.php @@ -36,7 +36,7 @@ require_once dirname( __FILE__ ) . '/mathjax-latex-admin.php'; -class MathJax { +class MathJax_Latex { public static $add_script; public static $block_script; public static $mathml_tags = [ From ad208c3bba94d40dd541bd2379648b5bfde803f6 Mon Sep 17 00:00:00 2001 From: Paul Schreiber Date: Wed, 25 Jul 2018 11:02:15 -0400 Subject: [PATCH 4/8] prepend class- to class file names --- mathjax-latex-admin.php => class-mathjax-latex-admin.php | 0 mathjax-latex.php => class-mathjax-latex.php | 0 2 files changed, 0 insertions(+), 0 deletions(-) rename mathjax-latex-admin.php => class-mathjax-latex-admin.php (100%) rename mathjax-latex.php => class-mathjax-latex.php (100%) diff --git a/mathjax-latex-admin.php b/class-mathjax-latex-admin.php similarity index 100% rename from mathjax-latex-admin.php rename to class-mathjax-latex-admin.php diff --git a/mathjax-latex.php b/class-mathjax-latex.php similarity index 100% rename from mathjax-latex.php rename to class-mathjax-latex.php From f3652836d4d79d2c6f49036764cec7e41d0a8946 Mon Sep 17 00:00:00 2001 From: Paul Schreiber Date: Wed, 25 Jul 2018 11:29:23 -0400 Subject: [PATCH 5/8] add mathjax-latex.php stub --- class-mathjax-latex.php | 13 ------------- mathjax-latex.php | 15 +++++++++++++++ 2 files changed, 15 insertions(+), 13 deletions(-) create mode 100644 mathjax-latex.php diff --git a/class-mathjax-latex.php b/class-mathjax-latex.php index 59a1fb1..ccb6c4a 100644 --- a/class-mathjax-latex.php +++ b/class-mathjax-latex.php @@ -1,17 +1,4 @@ Date: Wed, 25 Jul 2018 11:30:00 -0400 Subject: [PATCH 6/8] update require_once call for admin class --- class-mathjax-latex.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/class-mathjax-latex.php b/class-mathjax-latex.php index ccb6c4a..863b1cd 100644 --- a/class-mathjax-latex.php +++ b/class-mathjax-latex.php @@ -21,7 +21,7 @@ define( 'MATHJAX_VERSION', '1.3.9' ); -require_once dirname( __FILE__ ) . '/mathjax-latex-admin.php'; +require_once __DIR__ . '/class-mathjax-latex-admin.php'; class MathJax_Latex { public static $add_script; From c5346ca7afdae063f69ffee2259cfa7b27179071 Mon Sep 17 00:00:00 2001 From: Paul Schreiber Date: Wed, 25 Jul 2018 11:30:05 -0400 Subject: [PATCH 7/8] update init() call --- class-mathjax-latex.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/class-mathjax-latex.php b/class-mathjax-latex.php index 863b1cd..1af5aa8 100644 --- a/class-mathjax-latex.php +++ b/class-mathjax-latex.php @@ -287,4 +287,4 @@ public static function allow_mathml_tags_in_tinymce( $options ) { } } -MathJax::init(); +MathJax_Latex::init(); From 5d15f50a895b47f26930de2f286e6e8e2f6f21f9 Mon Sep 17 00:00:00 2001 From: Paul Schreiber Date: Wed, 25 Jul 2018 11:35:27 -0400 Subject: [PATCH 8/8] bump version to 1.3.10 --- class-mathjax-latex.php | 2 +- mathjax-latex.php | 2 +- readme.txt | 7 ++++++- 3 files changed, 8 insertions(+), 3 deletions(-) diff --git a/class-mathjax-latex.php b/class-mathjax-latex.php index cee2011..29a1da0 100644 --- a/class-mathjax-latex.php +++ b/class-mathjax-latex.php @@ -19,7 +19,7 @@ * along with this program. If not, see http://www.gnu.org/licenses/. */ -define( 'MATHJAX_VERSION', '1.3.9' ); +define( 'MATHJAX_VERSION', '1.3.10' ); require_once __DIR__ . '/class-mathjax-latex-admin.php'; diff --git a/mathjax-latex.php b/mathjax-latex.php index ff52981..143d1e2 100644 --- a/mathjax-latex.php +++ b/mathjax-latex.php @@ -2,7 +2,7 @@ /** * Plugin Name: MathJax-LaTeX * Description: Transform latex equations in JavaScript using mathjax - * Version: 1.3.9 + * Version: 1.3.10 * Author: Phillip Lord, Simon Cockell, Paul Schreiber * Author URI: http://knowledgeblog.org * diff --git a/readme.txt b/readme.txt index e84f670..3224a75 100644 --- a/readme.txt +++ b/readme.txt @@ -4,7 +4,7 @@ Contributors: philliplord, sjcockell, knowledgeblog, d_swan, paulschreiber, jwen Tags: mathematics, math, latex, mathml, mathjax, science, res-comms, scholar, academic Requires at least: 3.0 Tested up to: 4.9.1 -Stable tag: 1.3.9 +Stable tag: 1.3.10 Requires PHP: 7.0.0 License: GPLv2 @@ -34,6 +34,11 @@ MathJax-LaTeX is developed on [GitHub](https://github.com/phillord/mathjax-latex == Changelog == += 1.3.10 = + +1. Rename class filex, per PHPCS +2. Gracefully handle null values in filter_br_tags_on_math. Thanks to Yang Liu. + = 1.3.9 = 1. Code style changes, per PHPCS 3.3.0 and WPCS 0.14.1