eat-js-sdk 2.5.10 → 2.5.12

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -5429,7 +5429,7 @@ const interactionUtils = {
5429
5429
  const EAT_EQ_OPEN = "[eat-eq]";
5430
5430
  const EAT_EQ_BLOCK_RE = /\[eat-eq\]([\s\S]*?)\[\/eat-eq\]/g;
5431
5431
  function hasMathJax(html2) {
5432
- return html2.includes(EAT_EQ_OPEN) || html2.includes("\\(") || html2.includes("\\[");
5432
+ return html2.includes(EAT_EQ_OPEN) || html2.includes("\\(") || html2.includes("\\[") || html2.includes("$$");
5433
5433
  }
5434
5434
  const ALREADY_DELIMITED_RE = /^(\\[(]|\\[[]|\$\$|\$[^$])/;
5435
5435
  function processMathJax(html2) {
@@ -5461,8 +5461,9 @@ async function getMathJaxSpeechText(html2) {
5461
5461
  try {
5462
5462
  await typesetMathJax(staging);
5463
5463
  staging.querySelectorAll("mjx-container").forEach((container) => {
5464
- const speechText = container.getAttribute("aria-label") ?? container.querySelector("mjx-assistive-mml")?.textContent?.trim() ?? "";
5465
- container.replaceWith(document.createTextNode(speechText));
5464
+ const assistive = container.querySelector("mjx-assistive-mml");
5465
+ const text2 = assistive?.textContent?.trim() ?? "";
5466
+ container.replaceWith(document.createTextNode(text2));
5466
5467
  });
5467
5468
  return staging.textContent?.trim() ?? "";
5468
5469
  } finally {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "eat-js-sdk",
3
- "version": "2.5.10",
3
+ "version": "2.5.12",
4
4
  "change version": "2.5.0",
5
5
  "description": "Authoring tool frontend SDK",
6
6
  "contributors": [