JSFiddle - React, Tailwind, and code Playground
by bvotcode
HTML
<button id="js-lightbox" class="uk-button uk-button-default" type="button">Dynamic lightbox</button>
<script>
var util = UIkit.util;
util.on('#js-lightbox', 'click', function (e) {
e.preventDefault();
UIkit.lightboxPanel({
items: [
{source: 'images/size1.jpg', caption: '900x600'},
{source: 'images/size2.jpg', caption: '700x500'},
]
}).show();
});
</script>