drachels / moodle-mod_mootyper

4 stars 18 forks source link

Keyboard not showing #98

Closed chris-pratt-olms closed 3 years ago

chris-pratt-olms commented 3 years ago

Hi

We have the latest version installed and since upgrading the keyboard does not show despite the activity having the setting enabled. There are a few JS errors in the browser console which may be related (pasted below). Also once an activity has been added, if the settings are edited, it no longer appears to work again.

Moodle 3.10.4 (Build: 20210510) MooTyper 4.0.0 (Build: 2021041600) 2021041600 PHP: 7.3.28.1.16.04.1.1

(Site URL has been redacted)

English(USV5).js:57 Uncaught TypeError: Cannot set property 'className' of null at keyboardElement.turnOn (https://SITEURL/mod/mootyper/layouts/English(/mod/mootyper/USV5).js:57:67) at inittexttoenter (typer.js:422) at view.php?id=60348:548 turnOn @ English(USV5).js:57 inittexttoenter @ typer.js:422 (anonymous) @ view.php?id=60348:548 English(USV5).js:57 Uncaught TypeError: Cannot set property 'className' of null at keyboardElement.turnOn (https://SITEURL/mod/mootyper/layouts/English(/mod/mootyper/USV5).js:57:67) at focusSet (typer.js:191) at HTMLTextAreaElement.onfocus (view.php?id=60348:540) at HTMLTextAreaElement.handler (jquery.min.js:2) at HTMLTextAreaElement.dispatch (jquery.min.js:2) at HTMLTextAreaElement.v.handle (jquery.min.js:2) at Object.trigger (jquery.min.js:2) at HTMLTextAreaElement. (jquery.min.js:2) at Function.each (jquery.min.js:2) at S.fn.init.each (jquery.min.js:2) turnOn @ English(USV5).js:57 focusSet @ typer.js:191 onfocus @ view.php?id=60348:540 handler @ jquery.min.js:2 dispatch @ jquery.min.js:2 v.handle @ jquery.min.js:2 trigger @ jquery.min.js:2 (anonymous) @ jquery.min.js:2 each @ jquery.min.js:2 each @ jquery.min.js:2 trigger @ jquery.min.js:2 S.fn. @ jquery.min.js:2 (anonymous) @ typer.js:92 e @ jquery.min.js:2 t @ jquery.min.js:2 setTimeout (async) (anonymous) @ jquery.min.js:2 c @ jquery.min.js:2 fireWith @ jquery.min.js:2 fire @ jquery.min.js:2 c @ jquery.min.js:2 fireWith @ jquery.min.js:2 ready @ jquery.min.js:2 B @ jquery.min.js:2 English(USV5).js:57 Uncaught TypeError: Cannot set property 'className' of null at keyboardElement.turnOn (https://SITEURL/mod/mootyper/layouts/English(/mod/mootyper/USV5).js:57:67) at focusSet (typer.js:191) at HTMLTextAreaElement.onfocus (view.php?id=60348:540) at Object.trigger (jquery.min.js:2) at HTMLTextAreaElement.handler (jquery.min.js:2) at HTMLTextAreaElement.dispatch (jquery.min.js:2) at HTMLTextAreaElement.v.handle (jquery.min.js:2) at HTMLTextAreaElement.handler (jquery.min.js:2) at HTMLTextAreaElement.dispatch (jquery.min.js:2) at HTMLTextAreaElement.v.handle (jquery.min.js:2) turnOn @ English(USV5).js:57 focusSet @ typer.js:191 onfocus @ view.php?id=60348:540 trigger @ jquery.min.js:2 handler @ jquery.min.js:2 dispatch @ jquery.min.js:2 v.handle @ jquery.min.js:2 handler @ jquery.min.js:2 dispatch @ jquery.min.js:2 v.handle @ jquery.min.js:2 trigger @ jquery.min.js:2 (anonymous) @ jquery.min.js:2 each @ jquery.min.js:2 each @ jquery.min.js:2 trigger @ jquery.min.js:2 S.fn. @ jquery.min.js:2 (anonymous) @ typer.js:92 e @ jquery.min.js:2 t @ jquery.min.js:2 setTimeout (async) (anonymous) @ jquery.min.js:2 c @ jquery.min.js:2 fireWith @ jquery.min.js:2 fire @ jquery.min.js:2 c @ jquery.min.js:2 fireWith @ jquery.min.js:2 ready @ jquery.min.js:2 B @ jquery.min.js:2 jquery.min.js:2 jQuery.Deferred exception: Cannot set property 'className' of null TypeError: Cannot set property 'className' of null at keyboardElement.turnOn (https://SITEURL/mod/mootyper/layouts/English(USV5).js:57:67) at focusSet (https://SITEURL/mod/mootyper/typer.js:191:20) at HTMLTextAreaElement.onfocus (https://SITEURL/mod/mootyper/view.php?id=60348:540:75) at Object.trigger (https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js:2:71564) at HTMLTextAreaElement. (https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js:2:72108) at Function.each (https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js:2:2976) at S.fn.init.each (https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js:2:1454) at S.fn.init.trigger (https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js:2:72084) at S.fn.init.S.fn. [as focus] (https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js:2:88549) at HTMLDocument. (https://SITEURL/mod/mootyper/typer.js:92:34) undefined S.Deferred.exceptionHook @ jquery.min.js:2 t @ jquery.min.js:2 setTimeout (async) (anonymous) @ jquery.min.js:2 c @ jquery.min.js:2 fireWith @ jquery.min.js:2 fire @ jquery.min.js:2 c @ jquery.min.js:2 fireWith @ jquery.min.js:2 ready @ jquery.min.js:2 B @ jquery.min.js:2 jquery.min.js:2 Uncaught TypeError: Cannot set property 'className' of null at keyboardElement.turnOn (https://SITEURL/mod/mootyper/layouts/English(/mod/mootyper/USV5).js:57:67) at focusSet (typer.js:191) at HTMLTextAreaElement.onfocus (view.php?id=60348:540) at Object.trigger (jquery.min.js:2) at HTMLTextAreaElement. (jquery.min.js:2) at Function.each (jquery.min.js:2) at S.fn.init.each (jquery.min.js:2) at S.fn.init.trigger (jquery.min.js:2) at S.fn.init.S.fn. [as focus] (jquery.min.js:2) at HTMLDocument. (typer.js:92) turnOn @ English(USV5).js:57 focusSet @ typer.js:191 onfocus @ view.php?id=60348:540 trigger @ jquery.min.js:2 (anonymous) @ jquery.min.js:2 each @ jquery.min.js:2 each @ jquery.min.js:2 trigger @ jquery.min.js:2 S.fn. @ jquery.min.js:2 (anonymous) @ typer.js:92 e @ jquery.min.js:2 t @ jquery.min.js:2 setTimeout (async) S.readyException @ jquery.min.js:2 (anonymous) @ jquery.min.js:2 e @ jquery.min.js:2 t @ jquery.min.js:2 setTimeout (async) (anonymous) @ jquery.min.js:2 c @ jquery.min.js:2 fireWith @ jquery.min.js:2 fire @ jquery.min.js:2 c @ jquery.min.js:2 fireWith @ jquery.min.js:2 t @ jquery.min.js:2 setTimeout (async) (anonymous) @ jquery.min.js:2 c @ jquery.min.js:2 fireWith @ jquery.min.js:2 fire @ jquery.min.js:2 c @ jquery.min.js:2 fireWith @ jquery.min.js:2 ready @ jquery.min.js:2 B @ jquery.min.js:2 English(USV5).js:57 Uncaught TypeError: Cannot set property 'className' of null at keyboardElement.turnOn (https://SITEURL/mod/mootyper/layouts/English(/mod/mootyper/USV5).js:57:67) at focusSet (typer.js:191) at HTMLTextAreaElement.onfocus (view.php?id=60348:540) at HTMLTextAreaElement.handler (jquery-3.5.1.min.js:2) at HTMLTextAreaElement.dispatch (jquery-3.5.1.min.js:2) at HTMLTextAreaElement.v.handle (jquery-3.5.1.min.js:2) at Object.trigger (jquery-3.5.1.min.js:2) at HTMLTextAreaElement. (jquery-3.5.1.min.js:2) at Function.each (jquery-3.5.1.min.js:2) at S.fn.init.each (jquery-3.5.1.min.js:2) turnOn @ English(USV5).js:57 focusSet @ typer.js:191 onfocus @ view.php?id=60348:540 handler @ jquery-3.5.1.min.js:2 dispatch @ jquery-3.5.1.min.js:2 v.handle @ jquery-3.5.1.min.js:2 trigger @ jquery-3.5.1.min.js:2 (anonymous) @ jquery-3.5.1.min.js:2 each @ jquery-3.5.1.min.js:2 each @ jquery-3.5.1.min.js:2 trigger @ jquery-3.5.1.min.js:2 S.fn. @ jquery-3.5.1.min.js:2 (anonymous) @ typer.js:90 dispatch @ jquery.min.js:2 v.handle @ jquery.min.js:2 English(USV5).js:57 Uncaught TypeError: Cannot set property 'className' of null at keyboardElement.turnOn (https://SITEURL/mod/mootyper/layouts/English(/mod/mootyper/USV5).js:57:67) at focusSet (typer.js:191) at HTMLTextAreaElement.onfocus (view.php?id=60348:540) at Object.trigger (jquery.min.js:2) at HTMLTextAreaElement.handler (jquery.min.js:2) at HTMLTextAreaElement.dispatch (jquery.min.js:2) at HTMLTextAreaElement.v.handle (jquery.min.js:2) at HTMLTextAreaElement.handler (jquery-3.5.1.min.js:2) at HTMLTextAreaElement.dispatch (jquery-3.5.1.min.js:2) at HTMLTextAreaElement.v.handle (jquery-3.5.1.min.js:2) turnOn @ English(USV5).js:57 focusSet @ typer.js:191 onfocus @ view.php?id=60348:540 trigger @ jquery.min.js:2 handler @ jquery.min.js:2 dispatch @ jquery.min.js:2 v.handle @ jquery.min.js:2 handler @ jquery-3.5.1.min.js:2 dispatch @ jquery-3.5.1.min.js:2 v.handle @ jquery-3.5.1.min.js:2 trigger @ jquery-3.5.1.min.js:2 (anonymous) @ jquery-3.5.1.min.js:2 each @ jquery-3.5.1.min.js:2 each @ jquery-3.5.1.min.js:2 trigger @ jquery-3.5.1.min.js:2 S.fn. @ jquery-3.5.1.min.js:2 (anonymous) @ typer.js:90 dispatch @ jquery.min.js:2 v.handle @ jquery.min.js:2 English(USV5).js:57 Uncaught TypeError: Cannot set property 'className' of null at keyboardElement.turnOn (https://SITEURL/mod/mootyper/layouts/English(/mod/mootyper/USV5).js:57:67) at focusSet (typer.js:191) at HTMLTextAreaElement.onfocus (view.php?id=60348:540) at Object.trigger (jquery-3.5.1.min.js:2) at HTMLTextAreaElement.handler (jquery-3.5.1.min.js:2) at HTMLTextAreaElement.dispatch (jquery-3.5.1.min.js:2) at HTMLTextAreaElement.v.handle (jquery-3.5.1.min.js:2) at HTMLTextAreaElement.handler (jquery-3.5.1.min.js:2) at HTMLTextAreaElement.dispatch (jquery-3.5.1.min.js:2) at HTMLTextAreaElement.v.handle (jquery-3.5.1.min.js:2) turnOn @ English(USV5).js:57 focusSet @ typer.js:191 onfocus @ view.php?id=60348:540 trigger @ jquery-3.5.1.min.js:2 handler @ jquery-3.5.1.min.js:2 dispatch @ jquery-3.5.1.min.js:2 v.handle @ jquery-3.5.1.min.js:2 handler @ jquery-3.5.1.min.js:2 dispatch @ jquery-3.5.1.min.js:2 v.handle @ jquery-3.5.1.min.js:2 trigger @ jquery-3.5.1.min.js:2 (anonymous) @ jquery-3.5.1.min.js:2 each @ jquery-3.5.1.min.js:2 each @ jquery-3.5.1.min.js:2 trigger @ jquery-3.5.1.min.js:2 S.fn. @ jquery-3.5.1.min.js:2 (anonymous) @ typer.js:90 dispatch @ jquery.min.js:2 v.handle @ jquery.min.js:2 English(USV5).js:57 Uncaught TypeError: Cannot set property 'className' of null at keyboardElement.turnOn (https://SITEURL/mod/mootyper/layouts/English(/mod/mootyper/USV5).js:57:67) at focusSet (typer.js:191) at HTMLTextAreaElement.onfocus (view.php?id=60348:540) at Object.trigger (jquery-3.5.1.min.js:2) at HTMLTextAreaElement. (jquery-3.5.1.min.js:2) at Function.each (jquery-3.5.1.min.js:2) at S.fn.init.each (jquery-3.5.1.min.js:2) at S.fn.init.trigger (jquery-3.5.1.min.js:2) at S.fn.init.S.fn. [as focus] (jquery-3.5.1.min.js:2) at HTMLBodyElement. (typer.js:90) turnOn @ English(USV5).js:57 focusSet @ typer.js:191 onfocus @ view.php?id=60348:540 trigger @ jquery-3.5.1.min.js:2 (anonymous) @ jquery-3.5.1.min.js:2 each @ jquery-3.5.1.min.js:2 each @ jquery-3.5.1.min.js:2 trigger @ jquery-3.5.1.min.js:2 S.fn. @ jquery-3.5.1.min.js:2 (anonymous) @ typer.js:90 dispatch @ jquery.min.js:2 v.handle @ jquery.min.js:2 English(USV5).js:57 Uncaught TypeError: Cannot set property 'className' of null at keyboardElement.turnOn (https://SITEURL/mod/mootyper/layouts/English(/mod/mootyper/USV5).js:57:67) at focusSet (typer.js:191) at HTMLTextAreaElement.onfocus (view.php?id=60348:540) at Object.trigger (jquery-3.5.1.min.js:2) at HTMLTextAreaElement. (jquery-3.5.1.min.js:2) at Function.each (jquery-3.5.1.min.js:2) at S.fn.init.each (jquery-3.5.1.min.js:2) at S.fn.init.trigger (jquery-3.5.1.min.js:2) at S.fn.init.S.fn. [as focus] (jquery-3.5.1.min.js:2) at HTMLHtmlElement. (typer.js:90) turnOn @ English(USV5).js:57 focusSet @ typer.js:191 onfocus @ view.php?id=60348:540 trigger @ jquery-3.5.1.min.js:2 (anonymous) @ jquery-3.5.1.min.js:2 each @ jquery-3.5.1.min.js:2 each @ jquery-3.5.1.min.js:2 trigger @ jquery-3.5.1.min.js:2 S.fn. @ jquery-3.5.1.min.js:2 (anonymous) @ typer.js:90 dispatch @ jquery.min.js:2 v.handle @ jquery.min.js:2

drachels commented 3 years ago

Sorry to take so long to reply, but you caught me right in the middle of a three day chemotherapy cycle for my wife so my time has been limited, and will get to be less each day for the next week while she recovers from the drugs. Today, when we went to get her drug pump removed they had to give her two bags of IV fluids with steroids, which has never happened before.

I have a test setup using all the same specifications as you have, except my Moodle has a newer build date: Moodle 3.10.4+ (Build: 20210611). On this setup, MooTyper 4.0.0 works correctly for me.

What steps did you use to do the MooTyper upgrade? Have you tried replacing the MooTyper code?

chris-pratt-olms commented 3 years ago

Hi, I'm not aware of the steps taken but we decided to un-install and re-install the plugin and the keyboard is now showing.

drachels commented 3 years ago

Thanks for the feedback. Sorry that between us we don't have a definite reason for the problem but I'm glad you have got it working.