فهرست منبع

use typesetPromise

Yuki Takei 5 سال پیش
والد
کامیت
91e7c0472f
1فایلهای تغییر یافته به همراه2 افزوده شده و 2 حذف شده
  1. 2 2
      src/client/js/components/Page/RevisionBody.jsx

+ 2 - 2
src/client/js/components/Page/RevisionBody.jsx

@@ -42,8 +42,8 @@ export default class RevisionBody extends React.PureComponent {
     //   So, before MathJax is initialized, execute renderMathJaxWithDebounce again.
     //   So, before MathJax is initialized, execute renderMathJaxWithDebounce again.
     //   Avoiding initialization of MathJax of draw.io solves the problem.
     //   Avoiding initialization of MathJax of draw.io solves the problem.
     //   refs: https://github.com/jgraph/drawio/pull/831
     //   refs: https://github.com/jgraph/drawio/pull/831
-    if (MathJax != null && MathJax.Hub != null) {
-      MathJax.Hub.Queue(['Typeset', MathJax.Hub, this.element]);
+    if (MathJax != null) {
+      MathJax.typesetPromise([this.element]);
     }
     }
     else {
     else {
       this.renderMathJaxWithDebounce();
       this.renderMathJaxWithDebounce();