Zebra_Dialog icon indicating copy to clipboard operation
Zebra_Dialog copied to clipboard

Provide a way to know when a dialog is opening

Open LukeSavefrogs opened this issue 4 years ago • 0 comments

Similar to the onClose event it would be useful to have an onOpen event.

It would be even better in my opinion if they were properties of the config object. Example:

$.Zebra_Dialog("Test onOpen", {
    title: "Test Title",
    onOpen: function () {
          console.log("Dialog has opened")
    },
    onClose: function () {
          console.log("Dialog has closed")
    }
});

The onClose event could still be present to add retrocompatibility.


This way i think it would be less polluted with "anonymous" events (an onClose event could be from any library or framework)

What do you think?

LukeSavefrogs avatar Aug 26 '20 05:08 LukeSavefrogs