Javascript modal quick reference

Considering the example below:

<script src=""></script>
<link rel="stylesheet" href="" type="text/css" />

<div id="modal"></div>

var myModal = jSuites.modal(document.getElementById('modal'));

Available Methods

Method Description Open the modal
myModal.close() Close the modal

Initialiation properties

Property Description
url: string Open the content from a remote URL.
closed: boolean Create the modal but keep it closed.
width: number The width size of your modal
height: number The height size of your modal
title: string The title shown of your modal
backdrop: boolean Don't show the backdrop


Event Description
onopen A method is execute when the modal is opened.
(element: HTMLElement, instance: JSON) => void
onclose A method is execute when the modal is closed.
(element: HTMLElement, instance: JSON) => void