You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
images | array | undefined | Required. An array of objects containing image properties (see Image Options above).
77
77
enableImageSelection | bool | true | Optional. Allow images to be selectable. Setting this option to `false` whilst supplying images with `isSelected: true` will result in those images being permanently selected.
78
-
onSelectImage | func | undefined | Optional. Function to execute when an image is selected. Optional args: index (index of selected image in images array), image (the selected image). This function is only executable when `enableImageSelection: true`.
78
+
onSelectImage | func | undefined | Optional. Function to execute when an image is selected. Access to image using `this` via [Function.prototype.call()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Function/call), Optional args: index (index of selected image in images array), image (the selected image). This function is only executable when `enableImageSelection: true`.
79
79
rowHeight | number | 180 | Optional. The height of each row in the gallery.
80
80
maxRows | number | undefined | Optional. The maximum number of rows to show in the gallery.
81
81
margin | number | 2 | Optional. The margin around each image in the gallery.
82
82
enableLightbox | bool | true | Optional. Enable lightbox display of full size image when thumbnail clicked.
83
-
onClickThumbnail | func | openLightbox | Optional. Function to execute when gallery thumbnail clicked. Optional args: index (index of selected image in images array), event (the click event). Overrides openLightbox.
84
-
lightboxWillOpen | func | undefined | Optional. Function to be called before opening lightbox. Optional arg: index (index of selected image in images array).
85
-
lightboxWillClose | func | undefined | Optional. Function to be called before closing lightbox.
83
+
onClickThumbnail | func | openLightbox | Optional. Function to execute when gallery thumbnail clicked. Allows access to thumbnail using `this` via [Function.prototype.call()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Function/call). Optional args: index (index of selected image in images array), event (the click event). Overrides openLightbox.
84
+
lightboxWillOpen | func | undefined | Optional. Function to be called before opening lightbox. Allows access to gallery using `this` via [Function.prototype.call()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Function/call). Optional arg: index (index of selected image in images array).
85
+
lightboxWillClose | func | undefined | Optional. Function to be called before closing lightbox. Allows access to gallery using `this` via [Function.prototype.call()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Function/call).
86
86
tagStyle | object | tagStyle | Optional. Style to pass to tag elements. Overrides internal tag style.
87
+
tileViewportStyle | func | tileViewportStyle | Optional. Function to style the image tile viewport. Allows access to image tile viewport using `this` via [Function.prototype.call()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Function/call). Overrides internal tileViewportStyle function.
88
+
thumbnailStyle | func | thumbnailStyle | Optional. Function to style the image thumbnail. Allows access to thumbnail using `this` via [Function.prototype.call()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Function/call). Overrides internal thumbnailStyle function.
87
89
88
90
## Lightbox Options
89
91
NOTE: these options are passed inside the Gallery tag.
0 commit comments