mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-07-01 15:50:13 +00:00
Move all packages to a types directory
This commit is contained in:
24
types/gridstack/gridstack-tests.ts
Normal file
24
types/gridstack/gridstack-tests.ts
Normal file
@@ -0,0 +1,24 @@
|
||||
/// <reference types="jquery"/>
|
||||
|
||||
|
||||
|
||||
// Type definitions for Gridstack
|
||||
// Project: http://troolee.github.io/gridstack.js/
|
||||
// Definitions by: Pascal Senn <https://github.com/PascalSenn/>, Ricky Blankenaufulland <https://github.com/ZoolWay/>
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
|
||||
var options = <IGridstackOptions> {
|
||||
float: true
|
||||
};
|
||||
var element: JQuery = $(document).gridstack(options);
|
||||
var gridstack: GridStack = $(document).data("gridstack");
|
||||
var gsFromElement: GridStack = element.data("gridstack");
|
||||
|
||||
if (gridstack !== gsFromElement) throw Error('These should match!');
|
||||
|
||||
gridstack.addWidget("test", 1, 2, 3, 4, true);
|
||||
gridstack.batchUpdate();
|
||||
gridstack.cellHeight();;
|
||||
gridstack.cellHeight(2);
|
||||
gridstack.cellWidth();
|
||||
gridstack.getCellFromPixel(<MousePosition>{ left:20, top: 20 });
|
||||
Reference in New Issue
Block a user