mirror of
https://github.com/zhigang1992/DefinitelyTyped.git
synced 2026-04-01 09:01:45 +08:00
Account for callbacks in 'fancybox'.
This commit is contained in:
@@ -116,7 +116,7 @@ $(".fancybox").fancybox({
|
||||
}
|
||||
});
|
||||
$(".fancybox").fancybox({
|
||||
beforeLoad: function () {
|
||||
beforeLoad: () => {
|
||||
this.title = 'Image ' + (this.index + 1) + ' of ' + this.group.length + (this.title ? ' - ' + this.title : '');
|
||||
}
|
||||
});
|
||||
|
||||
22
fancybox/fancybox.d.ts
vendored
22
fancybox/fancybox.d.ts
vendored
@@ -6,7 +6,7 @@
|
||||
|
||||
/// <reference path="../jquery/jquery.d.ts" />
|
||||
|
||||
interface FancyboxOptions {
|
||||
interface FancyboxOptions extends FancyboxCallback {
|
||||
padding?: any; // number or []
|
||||
margin?: any; // number or []
|
||||
width?: any; // number or []
|
||||
@@ -96,16 +96,16 @@ interface FancyboxMethods {
|
||||
}
|
||||
|
||||
interface FancyboxCallback {
|
||||
onCancel;
|
||||
beforeLoad;
|
||||
afterLoad;
|
||||
beforeShow;
|
||||
afterShow;
|
||||
beforeClose;
|
||||
afterClose;
|
||||
onUpdate;
|
||||
onPlayStart;
|
||||
onPlayEnd;
|
||||
onCancel?: Function;
|
||||
beforeLoad?: Function;
|
||||
afterLoad?: Function;
|
||||
beforeShow?: Function;
|
||||
afterShow?: Function;
|
||||
beforeClose?: Function;
|
||||
afterClose?: Function;
|
||||
onUpdate?: Function;
|
||||
onPlayStart?: Function;
|
||||
onPlayEnd?: Function;
|
||||
}
|
||||
|
||||
interface FancyboxThumbnailHelperOptions {
|
||||
|
||||
Reference in New Issue
Block a user