diff --git a/simplebar/simplebar-tests.ts b/simplebar/simplebar-tests.ts new file mode 100755 index 0000000000..abf906a089 --- /dev/null +++ b/simplebar/simplebar-tests.ts @@ -0,0 +1,5 @@ +/// +/// + +var simplebar = $.fn.simplebar.noConflict(); +$.fn.simplebar = simplebar; diff --git a/simplebar/simplebar.d.ts b/simplebar/simplebar.d.ts new file mode 100755 index 0000000000..63173f4322 --- /dev/null +++ b/simplebar/simplebar.d.ts @@ -0,0 +1,37 @@ +// Type definitions for simplebar.js 1.1.7 +// Project: https://github.com/Grsmto/simplebar +// Definitions by: Gregor Woiwode +// Definitions: https://github.com/borisyankov/DefinitelyTyped + +interface SimplebarOpions { + autoHide?: boolean; + wrapContent?: boolean +} + +interface JQuery { + /** + * Enables simplebar on calling element. + */ + simplebar: { + /** + * Define if scrollbar should be faded out automatically + * + * @param indicator if scrollbar should be faded out automatically. + */ + (options?: SimplebarOpions): JQuery; + }; +} + +interface JQueryStatic { + /** + * Enables simplebar on calling element. + */ + simplebar: { + /** + * Define if scrollbar should be faded out automatically + * + * @param indicator if scrollbar should be faded out automatically. + */ + (options?: SimplebarOpions): JQuery; + }; +}