bug? in showwhen library
Submitted by papi Jo on Fri, 12/06/2019 - 17:37
Forums:
Bug reported on github at https://github.com/h5p/h5p-editor-show-when/issues/1
This semantics example triggers an error when in edit H5P content mode:
Uncaught Cannot follow field "cold".
"fields": [ { "name": "winter", "type": "boolean", [...] }, { "name": "cold", "type": "boolean", [...] "widget": "showWhen", "showWhen": { "rules": [ { "field": "winter", "equals": true } ] } }, { "name": "wearWarmCap", [...] "widget": "showWhen", "showWhen": { "rules": [ { "field": "cold", "equals": true } ] } } ]
serettig
Sat, 12/07/2019 - 18:59
Permalink
I can confirm that this bug
I can confirm that this bug has been around for a long time. I think what causes this is the dependency of one showWhen widget on another showWhen widget. This doesn't work in the editor. I haven't seen the error when I was working on my library (it failed silently), though.