mirror of
https://github.com/MindWorkAI/AI-Studio.git
synced 2026-03-29 15:51:39 +00:00
Disable MathJax menu
This commit is contained in:
parent
6222a2a17e
commit
2cfbff0923
@ -9,6 +9,12 @@ let mathJaxReadyPromise = null
|
|||||||
let batchScheduled = false
|
let batchScheduled = false
|
||||||
let typesetInProgress = false
|
let typesetInProgress = false
|
||||||
|
|
||||||
|
function applyMathJaxConfiguration() {
|
||||||
|
window.MathJax = window.MathJax ?? {}
|
||||||
|
window.MathJax.options = window.MathJax.options ?? {}
|
||||||
|
window.MathJax.options.enableMenu = false
|
||||||
|
}
|
||||||
|
|
||||||
function isMathJaxReady() {
|
function isMathJaxReady() {
|
||||||
return typeof window.MathJax?.typesetPromise === 'function' || typeof window.MathJax?.typeset === 'function'
|
return typeof window.MathJax?.typesetPromise === 'function' || typeof window.MathJax?.typeset === 'function'
|
||||||
}
|
}
|
||||||
@ -35,6 +41,7 @@ function ensureMathJaxLoaded() {
|
|||||||
return mathJaxReadyPromise
|
return mathJaxReadyPromise
|
||||||
|
|
||||||
mathJaxReadyPromise = new Promise((resolve, reject) => {
|
mathJaxReadyPromise = new Promise((resolve, reject) => {
|
||||||
|
applyMathJaxConfiguration()
|
||||||
let script = document.getElementById(MATH_JAX_SCRIPT_ID)
|
let script = document.getElementById(MATH_JAX_SCRIPT_ID)
|
||||||
|
|
||||||
const onLoad = () => {
|
const onLoad = () => {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user