# Fancybox / Lightbox
Fancybox accepts the following data attributes:
data-fancybox-aspect-ratio="true"- Boolean that indicates whether the aspect ratio needs to be kept. Must be used in conjunction with width/height attributesdata-fancybox-close-button="false"- Boolean that determines whether or not a close button should be displayeddata-fancybox-close-click="true"- Boolean that determines if the fancybox will be closed when user clicks the contentdata-fancybox-height="500"- Number or String indicating the height of the containerdata-fancybox-max-height="500"- Number or String indicating the maximum height of the containerdata-fancybox-max-width="500"- Number or String indicating the maximum width of the containerdata-fancybox-min-height="500"- Number or String indicating the minimum height of the containerdata-fancybox-min-width="500"- Number or String indicating the minimum width of the containerdata-fancybox-padding="0"- Removed padding from lightbox, can also be set to the desired valuedata-fancybox-tpl="{closeBtn : '<a title="Close" class="fancybox-close pop-up__close--teal" href="javascript:;"></a>',}"- Set custom template on the renderend fancyboxdata-fancybox-type="iframe"- String, overrides type for content. Supported types are 'image', 'inline', 'ajax', 'iframe', 'swf' and 'html'data-fancybox-width="500"- Number or String indicating the width of the containerdata-fancybox-wrap-css="pop-up--teal"- A class to be assigned to the.fancybox-wrapcontainer
There are 3 global variables in JS that capture all these settings:
fancyboxSettings, tealFancyboxSettings, plumFancyboxSettings.
Triggering a fancybox opening with JS:
$.fancybox.open($helpPopUp, fancyboxSettings);
$.fancybox.open($helpPopUp, tealFancyboxSettings);
$.fancybox.open($helpPopUp, plumFancyboxSettings);