support icon indicating copy to clipboard operation
support copied to clipboard

`propagate` suspends `add` event on the store

Open bmblb opened this issue 6 months ago • 0 comments

Reported here: https://forum.bryntum.com/viewtopic.php?f=52&t=30061&p=152547#p152547

Reproducible on advanced Gantt demo.

  1. Replace on add task click handler
async onAddTaskClick() {
    const
        { gantt } = this,
        added     = gantt.taskStore.rootNode.appendChild({ name : this.L('New task'), duration : 1 });

    // run propagation to calculate new task fields
    // await gantt.project.commitAsync();

    await gantt.project.propagate();

    // scroll to the added task
    await gantt.scrollRowIntoView(added);

    gantt.features.cellEdit.startEditing({
        record : added,
        field  : 'name'
    });
}
  1. add beforeAdd and add event listeners to the task store
  2. run the demo, click add button

Note, only beforeAdd is triggered. If you call commitAsync() add event will be unblocked.

This method is not used anywhere but it is public. It should probably just become an alias to commitAsync(), deprecated and then removed altogether.

bmblb avatar Aug 12 '24 10:08 bmblb