mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2025-10-16 12:05:41 +00:00
[jquery-match-height] Add static members.
This commit is contained in:
parent
f858c2af73
commit
2da880babc
29
types/jquery-match-height/index.d.ts
vendored
29
types/jquery-match-height/index.d.ts
vendored
@ -5,9 +5,24 @@
|
||||
|
||||
/// <reference types="jquery"/>
|
||||
|
||||
// We cannot add the jQuery.fn definitions of the plugin until this
|
||||
// issue is resolved
|
||||
// https://github.com/DefinitelyTyped/DefinitelyTyped/issues/12685
|
||||
interface JQueryMatchHeight {
|
||||
_throttle: number;
|
||||
_maintainScroll: boolean;
|
||||
_groups: any[];
|
||||
|
||||
/**
|
||||
* Set all selected elements to the height of the tallest.
|
||||
* If the items are on multiple rows, the items of each row will be set to the tallest of that row.
|
||||
*
|
||||
* @param options
|
||||
*/
|
||||
(options?: JQueryMatchHeight.Options): JQuery;
|
||||
_update(): void;
|
||||
_rows($item: JQuery): any[];
|
||||
_beforeUpdate(event: JQueryEventObject, groups: any[]): any;
|
||||
_afterUpdate(event: JQueryEventObject, groups: any[]): any;
|
||||
_apply(elements: any, options: any): void;
|
||||
}
|
||||
|
||||
declare namespace JQueryMatchHeight {
|
||||
interface Options {
|
||||
@ -19,11 +34,5 @@ declare namespace JQueryMatchHeight {
|
||||
}
|
||||
|
||||
interface JQuery {
|
||||
/**
|
||||
* Set all selected elements to the height of the tallest.
|
||||
* If the items are on multiple rows, the items of each row will be set to the tallest of that row.
|
||||
*
|
||||
* @param options
|
||||
*/
|
||||
matchHeight(options?: JQueryMatchHeight.Options): JQuery;
|
||||
matchHeight: JQueryMatchHeight;
|
||||
}
|
||||
|
||||
@ -16,12 +16,12 @@ $.fn.matchHeight._rows($('.containers'));
|
||||
$('.containers').matchHeight({ remove: true });
|
||||
|
||||
// tslint:disable-next-line no-used-variable
|
||||
$.fn.matchHeight._beforeUpdate = (event: any, groups: any) => {
|
||||
$.fn.matchHeight._beforeUpdate = (event, groups) => {
|
||||
// do something before any updates are applied
|
||||
};
|
||||
|
||||
// tslint:disable-next-line no-used-variable
|
||||
$.fn.matchHeight._afterUpdate = (event: any, groups: any) => {
|
||||
$.fn.matchHeight._afterUpdate = (event, groups) => {
|
||||
// do something after all updates are applied
|
||||
};
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user