Need details about the modal window

Hi there,

I’m new to Grafana, now I’m building a plugin that needs modal window. All I know to show a modal window is to:

const showModal = (html) => {
appEvents.emit(‘show-modal’, {
src: ‘public/plugins/master-data-reason-codes-crud-panel/partials/’ + html,
modalClass: ‘confirm-modal’,
model: {}
})
}

which works.

But I want more details on the params, what else params can I put into it? I didn’t find any docs regarding this.

Also, I want to know how I can detect if the modal window is fully loaded? I used $(’#modal-div-id’).ready(fn…), which does not work. I don’t want to settimeout BTW.

Many thanks.