mkraska / meclib

JSXGraph-based dynamic and interactive images in Moodle STACK questions without even touching JavaScript
9 stars 3 forks source link

Active force vectors cannot be removed #34

Closed lassikor closed 1 year ago

lassikor commented 1 year ago

Hi, I have been testing this very interesting "toolbox" now a while. I have made some Stack questions with meclib (and imported directly the Meclib_demo.xml, as well) and I found an issue that I could not solve. If I create an active force vector (with force generator), this vector can not be removed. I suppose that a double click should do that but nothing happens. This same issue is present also in the jsfiddle tryout https://jsfiddle.net/vtmeq12x/33/. However, the tryout https://jsfiddle.net/qyw45jLs/10/ seems to work properly and vectors created can be removed by a double click. Is there something that I am missing or is this a real issue? I am using STACK 4.3.11 and Moodle 3.9. Trying different browsers made no difference. BR Lassi Korhonen University of Oulu, Finland

mkraska commented 1 year ago

This may be a matter of Meclib version. Note that in JSfiddle, the meclib code is static (local). Your example works with the current version: https://jsfiddle.net/r3x15heu/ What version of JSXGraph are you using?

lassikor commented 1 year ago

The JSXGraph version I am using (via STACK) is 1.4.4. and yes, that jsfiddle example works fine.

mkraska commented 1 year ago

Does the problem persist even with up to date meclib code? Otherwise I'd close the issue.

lassikor commented 1 year ago

Ok, now I was able to find the solution and yes, it was a version issue. Obviously the Meclib_demo.xml uses older meclib version and that didn't work in my setup. I didn't pay attention to the date of the question. I replaced the meclib part in that code with the newest one and now it works. Thank you for a very quick answer! This issue can be closed.

mkraska commented 1 year ago

Ok I close it once I updated that demo question

mkraska commented 1 year ago

Old demo question removed, replaced by new ones.