mathlive
mathlive copied to clipboard
Keyboard is not working on Chrome
The MathLive keyboard is not opening when clicking on the keyboard icon in the input field of MathLive. This issue is specific to the Chrome browser, as it works fine on other browsers.
Steps to Reproduce Open a webpage containing MathLive input field with the keyboard icon. Click on the keyboard icon to open the MathLive keyboard. Actual Behavior The MathLive keyboard does not open in the Chrome browser. Instead, an error is thrown in the browser console:
mathlive.min.js:2810 Uncaught TypeError: document.adoptedStyleSheets is not iterable at Be (mathlive.min.js:2810:765) at Af (mathlive.min.js:2855:818) at Pm (mathlive.min.js:2903:48) at t.buildAndAttachElement (mathlive.min.js:2903:19569) at t.show (mathlive.min.js:2903:17726) at d.addEventListener.signal (mathlive.min.js:3056:16269)
Expected Behavior When clicking on the keyboard icon in the MathLive input field, the MathLive keyboard should open, allowing users to input mathematical expressions.
Environment MathLive version: Please provide the version of MathLive you are using.
Operating System: macOS, Windows, iOS, etc. Please include the version.
Browser: Chrome (Version 123.0.6312.107 in this case).
This issue appears to be specific to the Chrome browser version 123.0.6312.107.
I have not been able to reproduce this issue. Can you reproduce this using the demo page: https://cortexjs.io/mathlive/demo/ There might be something specific to the way you are constructing a mathfield, or the page environment in which it is placed. Without access to a reproducible example it's going to be difficult to diagnose.
https://github.com/arnog/mathlive/assets/141804427/6b35c736-a436-49bf-880c-d14c1b0418b0
issue is same for demo page also
The MDN docs talk only about setting .adoptedStyleSheets, not reading it. Is it possible that it can contain a non-iterable object in this version of Chrome? https://developer.mozilla.org/en-US/docs/Web/API/Document/adoptedStyleSheets Relevant code in stylesheet.ts lines 120 and 134
I’ve tried with the same version of Chrome and it works for me. There must be something else in your environment that’s different. A Chrome extension perhaps?
@loveleet-convivity Have you been able to narrow down what caused this issue? Did you have a Chrome extension that interfered?