Github: Github
Download: Minified(5kb) Source
var p = new Popelt({ title: 'Hello World!', content: 'Lorem ipsum dolar sit amet.', }).show();
var p = new Popelt({ title: 'Are you sure you want to do this?', content: '' }); p.addButton('Yes, proceed', function(){ alert('You clicked YES'); }); p.show();
var p = new Popelt({title: 'Testing offset and width', content: 'Lorem ipsum dolar sit amet.', offsetTop: 40, width: 300 }).show();
var p = new Popelt({title: 'A close test', content: "Hover on the close (×) button for tooltip" + "Now click on the below 'Dismiss' link" + "<a href='#' class='btn-close'>Dismiss</a>" + "This is all within the content", closeClass: 'btn-close', closeBtnTooltip: 'Click here for magic' }).show();
var p = new Popelt({ title: 'Overlay', content: "Some content", overlayColor: '#f00', overlayOpacity: 0.5 }).show();
var p = new Popelt({ title: 'Overlay', content: "Some content", fadeSpeed: 2000 }).show();
var p = new Popelt({ contentType: 'ajax', loadUrl: 'ajax.html', focus: true }); p.addCloseButton(); p.show();
var p = new Popelt({ contentType: 'iframe', loadUrl: "//www.youtube.com/embed/tRVC4BKWaP8", iframeWidth: '100%', iframeHeight: '300px' }); p.addCloseButton(); p.show();
var p = new Popelt({ contentType: '#test_id_content' }).show();
var p = new Popelt({ title: 'This is title', contentType: 'ajax', loadUrl: 'ajax.html', maxHeight: 400 }) p.addCloseButton(); p.show();
var p = new Popelt({ title: 'This is title', content: "Some content, responsive: true }) p.addCloseButton(); p.show();