Hi
my goal is to add a default attribute when elements are added and people should be able to choose from a popup menu the values.
I thought the "onAdd" event would be the good way to go, so that I could add the attribute to it and the given values.
However I tried the following code (the demo.js file is intact besides this change):
events: { onUpdate: console.log, onSave: console.log, onAdd: (evt)=>{alert("something is added")} },
but the onAdd is never called... the same code for onUpdate works, but is of course triggered way to much.
Am I misunderstanding this, or is this a bug?
thanks!
kind regards
Andries
Hi
my goal is to add a default attribute when elements are added and people should be able to choose from a popup menu the values.
I thought the "onAdd" event would be the good way to go, so that I could add the attribute to it and the given values.
However I tried the following code (the demo.js file is intact besides this change):
events: { onUpdate: console.log, onSave: console.log, onAdd: (evt)=>{alert("something is added")} },but the onAdd is never called... the same code for onUpdate works, but is of course triggered way to much.
Am I misunderstanding this, or is this a bug?
thanks!
kind regards
Andries