-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Atto Multilang 2 Plugin Button breaks JavaScript in Quiz for role teacher and above #18
Comments
Many thanks @lucaboesch for notifying about the issue, is much appreciated. Just in case, please, provide also the Moodle version this error is being generated for. Thanks again and regards, |
Thanks, Julen. Best regards, |
Thanks Luca, I'll keep you informed. |
Possibly similar to #17. Check how it was fixed. |
I'm using your newest release 'master - Release v1.6 (Build 2016052600) for Moodle 2.9, 3.0 and 3.1' so the supposedly fixing code is there... |
Don't worry @lucaboesch, it was an annotation to keep it mind, I use to express my thoughts in these issues, so if I'm using the imperative don't think that I'm ordering you hehe ;) |
The previous approach had some assumptions (e.g., it assumed there was a singe instance of the editor on the same page) that lead to some bugs and corner cases. Now the plugin hooks on the form submit event and clean the highlighting <span> tags there. The cleaning doesn't use any regexes any longer. Instead it uses DOM operations that are more robust and potentially faster. Also multilang tag highlighting <span>'s are now removed/added when switching to/from HTML view, reducing clutter when editing the HTML code. Some initial coding style cleanup work has been carried out. More to follow. Tested in Firefox 56 and Chromium 61.0.3163.100. Closes eljulians#2 eljulians#18 eljulians#21
Hi @lucaboesch I have revamped the editor plugin and fixed the issue you are having (and also issues #21 and #18). I've tried to contact Julen about it, but have been unsuccessful so far. If you want to try my modified plugin, you can get it at https://github.com/iarenaza/moodle-atto_multilang2 |
Hi Julen, given that you have already merged the changes that fix this issue, you can close it now. Best regards. |
In a Moodle instance having the atto multilang 2 plugin button:
The file picker won't load and inspector shows a JavaScript error
TypeError: r.match(...) is null
As student everything works out fine.
The text was updated successfully, but these errors were encountered: