How can my plugin generate a generic modal window in the Control Panel? I'm working on a plugin, and it requires a modal to be displayed when the user interacts with a field of my Field Type. When the user finishes interacting with the modal, they would click "Done".

This is the standard modal that displays when you select Assets...



I basically want a more generic version of this modal, where I can put anything I want into the middle of it.

I would love to have something like this:



What's the best way to pull that off?
Create a div with whatever contents you want in the modal, and with a class "modal". Then create a new Garnish.Modal object with it:

var $div = $('&lt;div class="modal"&gt;...&lt;/div&gt;');
var myModal = new Garnish.Modal($div);