Initial definitions for 2 new jquery plugins.

This commit is contained in:
Natan Vivo
2013-01-17 13:05:31 -02:00
parent e45cc5aec1
commit 40d9e7bbc2
2 changed files with 60 additions and 0 deletions
+33
View File
@@ -0,0 +1,33 @@
// Type definitions for jQuery contextMenu 1.5.25
// Project: http://medialize.github.com/jQuery-contextMenu/
// Definitions by: Natan Vivo <https://github.com/nvivo/>
// Definitions: https://github.com/borisyankov/DefinitelyTyped
/// <reference path="../jquery/jquery-1.9.d.ts" />
interface JQueryContextMenuOptions {
selector: string;
appendTo?: string;
trigger?: string;
autoHide?: bool;
delay?: number;
determinePosition?: (menu) => void;
position?: (opt, x, y) => void;
positionSubmenu?: (menu) => void;
zIndex?: number;
animation?: {
duration?: number;
show?: string;
hide?: string;
};
events?: {
show?: () => void;
hide?: () => void;
};
callback?: (...args: any[]) => any;
items: any;
};
interface JQueryStatic {
contextMenu(options?: JQueryContextMenuOptions): JQuery;
}
+27
View File
@@ -0,0 +1,27 @@
// Type definitions for jQuery simplePagination.js v1.4
// Project: https://github.com/flaviusmatis/simplePagination.js
// Definitions by: Natan Vivo <https://github.com/nvivo/>
// Definitions: https://github.com/borisyankov/DefinitelyTyped
/// <reference path="../jquery/jquery-1.9.d.ts" />
interface SimplePaginationOptions {
items?: number;
itemsOnPage?: number;
pages?: number;
displayedPages?: number;
edges?: number;
currentPage?: number;
hrefTextPrefix?: string;
hrefTextSuffix?: string;
prevText?: string;
nextText?: string;
cssStyle?: string;
selectOnClick?: bool;
onPageClick?: (interger) => void;
onInit?: () => void;
};
interface JQuery {
pagination(options?: SimplePaginationOptions): JQuery;
}