gridstack 12.5.0 → 12.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/angular/esm2020/lib/base-widget.mjs +2 -2
- package/dist/angular/esm2020/lib/gridstack-item.component.mjs +2 -2
- package/dist/angular/esm2020/lib/gridstack.component.mjs +2 -2
- package/dist/angular/esm2020/lib/gridstack.module.mjs +2 -2
- package/dist/angular/esm2020/lib/types.mjs +2 -2
- package/dist/angular/fesm2015/gridstack-angular.mjs +4 -4
- package/dist/angular/fesm2015/gridstack-angular.mjs.map +1 -1
- package/dist/angular/fesm2020/gridstack-angular.mjs +5 -5
- package/dist/angular/fesm2020/gridstack-angular.mjs.map +1 -1
- package/dist/angular/lib/gridstack-item.component.d.ts +1 -1
- package/dist/angular/lib/gridstack.component.d.ts +1 -1
- package/dist/angular/lib/types.d.ts +1 -1
- package/dist/angular/package.json +1 -1
- package/dist/angular/src/base-widget.ts +1 -1
- package/dist/angular/src/gridstack-item.component.ts +1 -1
- package/dist/angular/src/gridstack.component.ts +1 -1
- package/dist/angular/src/gridstack.module.ts +1 -1
- package/dist/angular/src/types.ts +1 -1
- package/dist/dd-base-impl.d.ts +1 -1
- package/dist/dd-base-impl.js +1 -1
- package/dist/dd-base-impl.js.map +1 -1
- package/dist/dd-draggable.d.ts +3 -1
- package/dist/dd-draggable.js +41 -15
- package/dist/dd-draggable.js.map +1 -1
- package/dist/dd-droppable.d.ts +1 -1
- package/dist/dd-droppable.js +1 -1
- package/dist/dd-droppable.js.map +1 -1
- package/dist/dd-element.d.ts +1 -1
- package/dist/dd-element.js +1 -1
- package/dist/dd-element.js.map +1 -1
- package/dist/dd-gridstack.d.ts +2 -1
- package/dist/dd-gridstack.js +6 -3
- package/dist/dd-gridstack.js.map +1 -1
- package/dist/dd-manager.d.ts +1 -1
- package/dist/dd-manager.js +1 -1
- package/dist/dd-manager.js.map +1 -1
- package/dist/dd-resizable-handle.d.ts +1 -1
- package/dist/dd-resizable-handle.js +1 -1
- package/dist/dd-resizable-handle.js.map +1 -1
- package/dist/dd-resizable.d.ts +2 -1
- package/dist/dd-resizable.js +45 -14
- package/dist/dd-resizable.js.map +1 -1
- package/dist/dd-touch.d.ts +1 -1
- package/dist/dd-touch.js +1 -1
- package/dist/dd-touch.js.map +1 -1
- package/dist/gridstack-all.js +1 -1
- package/dist/gridstack-all.js.LICENSE.txt +1 -1
- package/dist/gridstack-all.js.map +1 -1
- package/dist/gridstack-engine.d.ts +1 -1
- package/dist/gridstack-engine.js +1 -1
- package/dist/gridstack-engine.js.map +1 -1
- package/dist/gridstack.css +17 -6
- package/dist/gridstack.d.ts +1 -1
- package/dist/gridstack.js +15 -13
- package/dist/gridstack.js.map +1 -1
- package/dist/gridstack.min.css +1 -1
- package/dist/types.d.ts +9 -1
- package/dist/types.js +1 -1
- package/dist/types.js.map +1 -1
- package/dist/utils.d.ts +1 -1
- package/dist/utils.js +1 -1
- package/dist/utils.js.map +1 -1
- package/doc/API.md +82 -64
- package/package.json +1 -1
package/doc/API.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# gridstack v12.
|
|
1
|
+
# gridstack v12.6.0
|
|
2
2
|
|
|
3
3
|
## Classes
|
|
4
4
|
|
|
@@ -114,7 +114,7 @@ Construct a grid item from the given element and options
|
|
|
114
114
|
protected _updateResizeEvent(forceRemove): GridStack;
|
|
115
115
|
```
|
|
116
116
|
|
|
117
|
-
Defined in: [gridstack.ts:
|
|
117
|
+
Defined in: [gridstack.ts:2088](https://github.com/adumesny/gridstack.js/blob/master/src/gridstack.ts#L2088)
|
|
118
118
|
|
|
119
119
|
add or remove the grid element size event handler
|
|
120
120
|
|
|
@@ -428,7 +428,7 @@ Destroys a grid instance. DO NOT CALL any methods or access any vars after this
|
|
|
428
428
|
disable(recurse): GridStack;
|
|
429
429
|
```
|
|
430
430
|
|
|
431
|
-
Defined in: [gridstack.ts:
|
|
431
|
+
Defined in: [gridstack.ts:2289](https://github.com/adumesny/gridstack.js/blob/master/src/gridstack.ts#L2289)
|
|
432
432
|
|
|
433
433
|
Temporarily disables widgets moving/resizing.
|
|
434
434
|
If you want a more permanent way (which freezes up resources) use `setStatic(true)` instead.
|
|
@@ -469,7 +469,7 @@ grid.disable(false);
|
|
|
469
469
|
enable(recurse): GridStack;
|
|
470
470
|
```
|
|
471
471
|
|
|
472
|
-
Defined in: [gridstack.ts:
|
|
472
|
+
Defined in: [gridstack.ts:2316](https://github.com/adumesny/gridstack.js/blob/master/src/gridstack.ts#L2316)
|
|
473
473
|
|
|
474
474
|
Re-enables widgets moving/resizing - see disable().
|
|
475
475
|
Note: This is a no-op for static grids.
|
|
@@ -508,7 +508,7 @@ grid.enable(false);
|
|
|
508
508
|
enableMove(doEnable, recurse): GridStack;
|
|
509
509
|
```
|
|
510
510
|
|
|
511
|
-
Defined in: [gridstack.ts:
|
|
511
|
+
Defined in: [gridstack.ts:2342](https://github.com/adumesny/gridstack.js/blob/master/src/gridstack.ts#L2342)
|
|
512
512
|
|
|
513
513
|
Enables/disables widget moving for all widgets. No-op for static grids.
|
|
514
514
|
Note: locally defined items (with noMove property) still override this setting.
|
|
@@ -545,7 +545,7 @@ grid.enableMove(true, false);
|
|
|
545
545
|
enableResize(doEnable, recurse): GridStack;
|
|
546
546
|
```
|
|
547
547
|
|
|
548
|
-
Defined in: [gridstack.ts:
|
|
548
|
+
Defined in: [gridstack.ts:2370](https://github.com/adumesny/gridstack.js/blob/master/src/gridstack.ts#L2370)
|
|
549
549
|
|
|
550
550
|
Enables/disables widget resizing for all widgets. No-op for static grids.
|
|
551
551
|
Note: locally defined items (with noResize property) still override this setting.
|
|
@@ -687,7 +687,7 @@ const columnCount = grid.getColumn(); // returns 12 by default
|
|
|
687
687
|
static getDD(): DDGridStack;
|
|
688
688
|
```
|
|
689
689
|
|
|
690
|
-
Defined in: [gridstack.ts:
|
|
690
|
+
Defined in: [gridstack.ts:2186](https://github.com/adumesny/gridstack.js/blob/master/src/gridstack.ts#L2186)
|
|
691
691
|
|
|
692
692
|
Get the global drag & drop implementation instance.
|
|
693
693
|
This provides access to the underlying drag & drop functionality.
|
|
@@ -1095,7 +1095,7 @@ grid.margin('5px 10px 15px 20px'); // Different for each side
|
|
|
1095
1095
|
movable(els, val): GridStack;
|
|
1096
1096
|
```
|
|
1097
1097
|
|
|
1098
|
-
Defined in: [gridstack.ts:
|
|
1098
|
+
Defined in: [gridstack.ts:2230](https://github.com/adumesny/gridstack.js/blob/master/src/gridstack.ts#L2230)
|
|
1099
1099
|
|
|
1100
1100
|
Enables/Disables dragging by the user for specific grid elements.
|
|
1101
1101
|
For all items and future items, use enableMove() instead. No-op for static grids.
|
|
@@ -1431,7 +1431,7 @@ grid.on('added', (event, items) => {
|
|
|
1431
1431
|
onResize(clientWidth): GridStack;
|
|
1432
1432
|
```
|
|
1433
1433
|
|
|
1434
|
-
Defined in: [gridstack.ts:
|
|
1434
|
+
Defined in: [gridstack.ts:2027](https://github.com/adumesny/gridstack.js/blob/master/src/gridstack.ts#L2027)
|
|
1435
1435
|
|
|
1436
1436
|
called when we are being resized - check if the one Column Mode needs to be turned on/off
|
|
1437
1437
|
and remember the prev columns we used, or get our count from parent, as well as check for cellHeight==='auto' (square)
|
|
@@ -1453,7 +1453,7 @@ or `sizeToContent` gridItem options.
|
|
|
1453
1453
|
prepareDragDrop(el, force?): GridStack;
|
|
1454
1454
|
```
|
|
1455
1455
|
|
|
1456
|
-
Defined in: [gridstack.ts:
|
|
1456
|
+
Defined in: [gridstack.ts:2713](https://github.com/adumesny/gridstack.js/blob/master/src/gridstack.ts#L2713)
|
|
1457
1457
|
|
|
1458
1458
|
prepares the element for drag&drop - this is normally called by makeWidget() unless are are delay loading
|
|
1459
1459
|
|
|
@@ -1563,7 +1563,7 @@ Removes widget from the grid.
|
|
|
1563
1563
|
resizable(els, val): GridStack;
|
|
1564
1564
|
```
|
|
1565
1565
|
|
|
1566
|
-
Defined in: [gridstack.ts:
|
|
1566
|
+
Defined in: [gridstack.ts:2256](https://github.com/adumesny/gridstack.js/blob/master/src/gridstack.ts#L2256)
|
|
1567
1567
|
|
|
1568
1568
|
Enables/Disables user resizing for specific grid elements.
|
|
1569
1569
|
For all items and future items, use enableResize() instead. No-op for static grids.
|
|
@@ -1750,7 +1750,7 @@ static setupDragIn(
|
|
|
1750
1750
|
root?): void;
|
|
1751
1751
|
```
|
|
1752
1752
|
|
|
1753
|
-
Defined in: [gridstack.ts:
|
|
1753
|
+
Defined in: [gridstack.ts:2199](https://github.com/adumesny/gridstack.js/blob/master/src/gridstack.ts#L2199)
|
|
1754
1754
|
|
|
1755
1755
|
call to setup dragging in from the outside (say toolbar), by specifying the class selection and options.
|
|
1756
1756
|
Called during GridStack.init() as options, but can also be called directly (last param are used) in case the toolbar
|
|
@@ -1775,7 +1775,7 @@ is dynamically create and needs to be set later.
|
|
|
1775
1775
|
protected triggerEvent(event, target): void;
|
|
1776
1776
|
```
|
|
1777
1777
|
|
|
1778
|
-
Defined in: [gridstack.ts:
|
|
1778
|
+
Defined in: [gridstack.ts:2976](https://github.com/adumesny/gridstack.js/blob/master/src/gridstack.ts#L2976)
|
|
1779
1779
|
|
|
1780
1780
|
call given event callback on our main top-most grid (if we're nested)
|
|
1781
1781
|
|
|
@@ -3763,7 +3763,7 @@ Defines the options for a Grid
|
|
|
3763
3763
|
| <a id="removableoptions"></a> `removableOptions?` | [`DDRemoveOpt`](#ddremoveopt) | allows to override UI removable options. (default?: { accept: '.grid-stack-item' }) | [types.ts:351](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L351) |
|
|
3764
3764
|
| <a id="resizable-4"></a> `resizable?` | [`DDResizeOpt`](#ddresizeopt) | allows to override UI resizable options. default is { handles: 'se', autoHide: true on desktop, false on mobile } | [types.ts:341](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L341) |
|
|
3765
3765
|
| <a id="row"></a> `row?` | `number` | fix grid number of rows. This is a shortcut of writing `minRow:N, maxRow:N`. (default `0` no constrain) | [types.ts:354](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L354) |
|
|
3766
|
-
| <a id="rtl"></a> `rtl?` | `boolean` \| `"auto"` | if true turns grid to RTL. Possible values are true, false, 'auto' (default?: 'auto') See [example](http://gridstack.github.io/gridstack.js/demo/right-to-left(rtl).html) | [types.ts:360](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L360) |
|
|
3766
|
+
| <a id="rtl-2"></a> `rtl?` | `boolean` \| `"auto"` | if true turns grid to RTL. Possible values are true, false, 'auto' (default?: 'auto') See [example](http://gridstack.github.io/gridstack.js/demo/right-to-left(rtl).html) | [types.ts:360](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L360) |
|
|
3767
3767
|
| <a id="sizetocontent-1"></a> `sizeToContent?` | `boolean` | set to true if all grid items (by default, but item can also override) height should be based on content size instead of WidgetItem.h to avoid v-scrollbars. Note: this is still row based, not pixels, so it will use ceil(getBoundingClientRect().height / getCellHeight()) | [types.ts:365](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L365) |
|
|
3768
3768
|
| <a id="staticgrid"></a> `staticGrid?` | `boolean` | makes grid static (default?: false). If `true` widgets are not movable/resizable. You don't even need draggable/resizable. A CSS class 'grid-stack-static' is also added to the element. | [types.ts:372](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L372) |
|
|
3769
3769
|
| <a id="styleinhead"></a> ~~`styleInHead?`~~ | `boolean` | **Deprecated** Not used anymore, styles are now implemented with local CSS variables | [types.ts:377](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L377) |
|
|
@@ -4003,7 +4003,7 @@ Defined in: [dd-draggable.ts:69](https://github.com/adumesny/gridstack.js/blob/m
|
|
|
4003
4003
|
destroy(): void;
|
|
4004
4004
|
```
|
|
4005
4005
|
|
|
4006
|
-
Defined in: [dd-draggable.ts:
|
|
4006
|
+
Defined in: [dd-draggable.ts:131](https://github.com/adumesny/gridstack.js/blob/master/src/dd-draggable.ts#L131)
|
|
4007
4007
|
|
|
4008
4008
|
Destroy this drag & drop implementation and clean up resources.
|
|
4009
4009
|
Removes all event handlers and clears internal state.
|
|
@@ -4022,7 +4022,7 @@ Removes all event handlers and clears internal state.
|
|
|
4022
4022
|
disable(forDestroy): void;
|
|
4023
4023
|
```
|
|
4024
4024
|
|
|
4025
|
-
Defined in: [dd-draggable.ts:
|
|
4025
|
+
Defined in: [dd-draggable.ts:118](https://github.com/adumesny/gridstack.js/blob/master/src/dd-draggable.ts#L118)
|
|
4026
4026
|
|
|
4027
4027
|
Disable this drag & drop implementation.
|
|
4028
4028
|
Subclasses should override to perform additional cleanup.
|
|
@@ -4047,7 +4047,7 @@ Subclasses should override to perform additional cleanup.
|
|
|
4047
4047
|
enable(): void;
|
|
4048
4048
|
```
|
|
4049
4049
|
|
|
4050
|
-
Defined in: [dd-draggable.ts:
|
|
4050
|
+
Defined in: [dd-draggable.ts:104](https://github.com/adumesny/gridstack.js/blob/master/src/dd-draggable.ts#L104)
|
|
4051
4051
|
|
|
4052
4052
|
Enable this drag & drop implementation.
|
|
4053
4053
|
Subclasses should override to perform additional setup.
|
|
@@ -4060,13 +4060,27 @@ Subclasses should override to perform additional setup.
|
|
|
4060
4060
|
|
|
4061
4061
|
[`DDBaseImplement`](#ddbaseimplement).[`enable`](#enable)
|
|
4062
4062
|
|
|
4063
|
+
##### getAllHandles()
|
|
4064
|
+
|
|
4065
|
+
```ts
|
|
4066
|
+
protected getAllHandles(): HTMLElement[];
|
|
4067
|
+
```
|
|
4068
|
+
|
|
4069
|
+
Defined in: [dd-draggable.ts:88](https://github.com/adumesny/gridstack.js/blob/master/src/dd-draggable.ts#L88)
|
|
4070
|
+
|
|
4071
|
+
return all handles omitting other nested `.grid-stack-item` children (in case node.subGrid isn't set for some reason)
|
|
4072
|
+
|
|
4073
|
+
###### Returns
|
|
4074
|
+
|
|
4075
|
+
`HTMLElement`[]
|
|
4076
|
+
|
|
4063
4077
|
##### off()
|
|
4064
4078
|
|
|
4065
4079
|
```ts
|
|
4066
4080
|
off(event): void;
|
|
4067
4081
|
```
|
|
4068
4082
|
|
|
4069
|
-
Defined in: [dd-draggable.ts:
|
|
4083
|
+
Defined in: [dd-draggable.ts:100](https://github.com/adumesny/gridstack.js/blob/master/src/dd-draggable.ts#L100)
|
|
4070
4084
|
|
|
4071
4085
|
Unregister an event callback for the specified event.
|
|
4072
4086
|
|
|
@@ -4090,7 +4104,7 @@ Unregister an event callback for the specified event.
|
|
|
4090
4104
|
on(event, callback): void;
|
|
4091
4105
|
```
|
|
4092
4106
|
|
|
4093
|
-
Defined in: [dd-draggable.ts:
|
|
4107
|
+
Defined in: [dd-draggable.ts:96](https://github.com/adumesny/gridstack.js/blob/master/src/dd-draggable.ts#L96)
|
|
4094
4108
|
|
|
4095
4109
|
Register an event callback for the specified event.
|
|
4096
4110
|
|
|
@@ -4142,7 +4156,7 @@ Result from the callback function, if any
|
|
|
4142
4156
|
updateOption(opts): DDDraggable;
|
|
4143
4157
|
```
|
|
4144
4158
|
|
|
4145
|
-
Defined in: [dd-draggable.ts:
|
|
4159
|
+
Defined in: [dd-draggable.ts:142](https://github.com/adumesny/gridstack.js/blob/master/src/dd-draggable.ts#L142)
|
|
4146
4160
|
|
|
4147
4161
|
Method to update the options and return the DD implementation
|
|
4148
4162
|
|
|
@@ -4649,7 +4663,7 @@ draggable(
|
|
|
4649
4663
|
value?): DDGridStack;
|
|
4650
4664
|
```
|
|
4651
4665
|
|
|
4652
|
-
Defined in: [dd-gridstack.ts:
|
|
4666
|
+
Defined in: [dd-gridstack.ts:122](https://github.com/adumesny/gridstack.js/blob/master/src/dd-gridstack.ts#L122)
|
|
4653
4667
|
|
|
4654
4668
|
Enable/disable/configure dragging for grid elements.
|
|
4655
4669
|
|
|
@@ -4681,7 +4695,7 @@ dd.draggable(element, {handle: '.drag-handle'}); // Configure drag handle
|
|
|
4681
4695
|
dragIn(el, opts): DDGridStack;
|
|
4682
4696
|
```
|
|
4683
4697
|
|
|
4684
|
-
Defined in: [dd-gridstack.ts:
|
|
4698
|
+
Defined in: [dd-gridstack.ts:147](https://github.com/adumesny/gridstack.js/blob/master/src/dd-gridstack.ts#L147)
|
|
4685
4699
|
|
|
4686
4700
|
###### Parameters
|
|
4687
4701
|
|
|
@@ -4704,7 +4718,7 @@ droppable(
|
|
|
4704
4718
|
value?): DDGridStack;
|
|
4705
4719
|
```
|
|
4706
4720
|
|
|
4707
|
-
Defined in: [dd-gridstack.ts:
|
|
4721
|
+
Defined in: [dd-gridstack.ts:152](https://github.com/adumesny/gridstack.js/blob/master/src/dd-gridstack.ts#L152)
|
|
4708
4722
|
|
|
4709
4723
|
###### Parameters
|
|
4710
4724
|
|
|
@@ -4725,7 +4739,7 @@ Defined in: [dd-gridstack.ts:149](https://github.com/adumesny/gridstack.js/blob/
|
|
|
4725
4739
|
isDraggable(el): boolean;
|
|
4726
4740
|
```
|
|
4727
4741
|
|
|
4728
|
-
Defined in: [dd-gridstack.ts:
|
|
4742
|
+
Defined in: [dd-gridstack.ts:177](https://github.com/adumesny/gridstack.js/blob/master/src/dd-gridstack.ts#L177)
|
|
4729
4743
|
|
|
4730
4744
|
true if element is draggable
|
|
4731
4745
|
|
|
@@ -4745,7 +4759,7 @@ true if element is draggable
|
|
|
4745
4759
|
isDroppable(el): boolean;
|
|
4746
4760
|
```
|
|
4747
4761
|
|
|
4748
|
-
Defined in: [dd-gridstack.ts:
|
|
4762
|
+
Defined in: [dd-gridstack.ts:172](https://github.com/adumesny/gridstack.js/blob/master/src/dd-gridstack.ts#L172)
|
|
4749
4763
|
|
|
4750
4764
|
true if element is droppable
|
|
4751
4765
|
|
|
@@ -4765,7 +4779,7 @@ true if element is droppable
|
|
|
4765
4779
|
isResizable(el): boolean;
|
|
4766
4780
|
```
|
|
4767
4781
|
|
|
4768
|
-
Defined in: [dd-gridstack.ts:
|
|
4782
|
+
Defined in: [dd-gridstack.ts:182](https://github.com/adumesny/gridstack.js/blob/master/src/dd-gridstack.ts#L182)
|
|
4769
4783
|
|
|
4770
4784
|
true if element is draggable
|
|
4771
4785
|
|
|
@@ -4785,7 +4799,7 @@ true if element is draggable
|
|
|
4785
4799
|
off(el, name): DDGridStack;
|
|
4786
4800
|
```
|
|
4787
4801
|
|
|
4788
|
-
Defined in: [dd-gridstack.ts:
|
|
4802
|
+
Defined in: [dd-gridstack.ts:198](https://github.com/adumesny/gridstack.js/blob/master/src/dd-gridstack.ts#L198)
|
|
4789
4803
|
|
|
4790
4804
|
###### Parameters
|
|
4791
4805
|
|
|
@@ -4807,7 +4821,7 @@ on(
|
|
|
4807
4821
|
callback): DDGridStack;
|
|
4808
4822
|
```
|
|
4809
4823
|
|
|
4810
|
-
Defined in: [dd-gridstack.ts:
|
|
4824
|
+
Defined in: [dd-gridstack.ts:186](https://github.com/adumesny/gridstack.js/blob/master/src/dd-gridstack.ts#L186)
|
|
4811
4825
|
|
|
4812
4826
|
###### Parameters
|
|
4813
4827
|
|
|
@@ -4897,7 +4911,7 @@ new DDManager(): DDManager;
|
|
|
4897
4911
|
<a id="ddresizable-1"></a>
|
|
4898
4912
|
### DDResizable
|
|
4899
4913
|
|
|
4900
|
-
Defined in: [dd-resizable.ts:
|
|
4914
|
+
Defined in: [dd-resizable.ts:41](https://github.com/adumesny/gridstack.js/blob/master/src/dd-resizable.ts#L41)
|
|
4901
4915
|
|
|
4902
4916
|
Interface for HTML elements extended with drag & drop options.
|
|
4903
4917
|
Used to associate DD configuration with DOM elements.
|
|
@@ -4941,7 +4955,7 @@ Note: Use enable()/disable() methods to change state as other operations need to
|
|
|
4941
4955
|
new DDResizable(el, option): DDResizable;
|
|
4942
4956
|
```
|
|
4943
4957
|
|
|
4944
|
-
Defined in: [dd-resizable.ts:
|
|
4958
|
+
Defined in: [dd-resizable.ts:68](https://github.com/adumesny/gridstack.js/blob/master/src/dd-resizable.ts#L68)
|
|
4945
4959
|
|
|
4946
4960
|
###### Parameters
|
|
4947
4961
|
|
|
@@ -4966,7 +4980,7 @@ Defined in: [dd-resizable.ts:59](https://github.com/adumesny/gridstack.js/blob/m
|
|
|
4966
4980
|
destroy(): void;
|
|
4967
4981
|
```
|
|
4968
4982
|
|
|
4969
|
-
Defined in: [dd-resizable.ts:
|
|
4983
|
+
Defined in: [dd-resizable.ts:98](https://github.com/adumesny/gridstack.js/blob/master/src/dd-resizable.ts#L98)
|
|
4970
4984
|
|
|
4971
4985
|
Destroy this drag & drop implementation and clean up resources.
|
|
4972
4986
|
Removes all event handlers and clears internal state.
|
|
@@ -4985,7 +4999,7 @@ Removes all event handlers and clears internal state.
|
|
|
4985
4999
|
disable(): void;
|
|
4986
5000
|
```
|
|
4987
5001
|
|
|
4988
|
-
Defined in: [dd-resizable.ts:
|
|
5002
|
+
Defined in: [dd-resizable.ts:92](https://github.com/adumesny/gridstack.js/blob/master/src/dd-resizable.ts#L92)
|
|
4989
5003
|
|
|
4990
5004
|
Disable this drag & drop implementation.
|
|
4991
5005
|
Subclasses should override to perform additional cleanup.
|
|
@@ -5004,7 +5018,7 @@ Subclasses should override to perform additional cleanup.
|
|
|
5004
5018
|
enable(): void;
|
|
5005
5019
|
```
|
|
5006
5020
|
|
|
5007
|
-
Defined in: [dd-resizable.ts:
|
|
5021
|
+
Defined in: [dd-resizable.ts:86](https://github.com/adumesny/gridstack.js/blob/master/src/dd-resizable.ts#L86)
|
|
5008
5022
|
|
|
5009
5023
|
Enable this drag & drop implementation.
|
|
5010
5024
|
Subclasses should override to perform additional setup.
|
|
@@ -5023,7 +5037,7 @@ Subclasses should override to perform additional setup.
|
|
|
5023
5037
|
off(event): void;
|
|
5024
5038
|
```
|
|
5025
5039
|
|
|
5026
|
-
Defined in: [dd-resizable.ts:
|
|
5040
|
+
Defined in: [dd-resizable.ts:82](https://github.com/adumesny/gridstack.js/blob/master/src/dd-resizable.ts#L82)
|
|
5027
5041
|
|
|
5028
5042
|
Unregister an event callback for the specified event.
|
|
5029
5043
|
|
|
@@ -5047,7 +5061,7 @@ Unregister an event callback for the specified event.
|
|
|
5047
5061
|
on(event, callback): void;
|
|
5048
5062
|
```
|
|
5049
5063
|
|
|
5050
|
-
Defined in: [dd-resizable.ts:
|
|
5064
|
+
Defined in: [dd-resizable.ts:78](https://github.com/adumesny/gridstack.js/blob/master/src/dd-resizable.ts#L78)
|
|
5051
5065
|
|
|
5052
5066
|
Register an event callback for the specified event.
|
|
5053
5067
|
|
|
@@ -5099,7 +5113,7 @@ Result from the callback function, if any
|
|
|
5099
5113
|
updateOption(opts): DDResizable;
|
|
5100
5114
|
```
|
|
5101
5115
|
|
|
5102
|
-
Defined in: [dd-resizable.ts:
|
|
5116
|
+
Defined in: [dd-resizable.ts:105](https://github.com/adumesny/gridstack.js/blob/master/src/dd-resizable.ts#L105)
|
|
5103
5117
|
|
|
5104
5118
|
Method to update the options and return the DD implementation
|
|
5105
5119
|
|
|
@@ -5121,8 +5135,8 @@ Method to update the options and return the DD implementation
|
|
|
5121
5135
|
|
|
5122
5136
|
| Property | Modifier | Type | Default value | Description | Defined in |
|
|
5123
5137
|
| ------ | ------ | ------ | ------ | ------ | ------ |
|
|
5124
|
-
| <a id="el-3"></a> `el` | `public` | [`GridItemHTMLElement`](#griditemhtmlelement) | `undefined` | The HTML element being extended | [dd-resizable.ts:
|
|
5125
|
-
| <a id="option-2"></a> `option` | `public` | [`DDResizableOpt`](#ddresizableopt) | `{}` | The drag & drop options/configuration | [dd-resizable.ts:
|
|
5138
|
+
| <a id="el-3"></a> `el` | `public` | [`GridItemHTMLElement`](#griditemhtmlelement) | `undefined` | The HTML element being extended | [dd-resizable.ts:68](https://github.com/adumesny/gridstack.js/blob/master/src/dd-resizable.ts#L68) |
|
|
5139
|
+
| <a id="option-2"></a> `option` | `public` | [`DDResizableOpt`](#ddresizableopt) | `{}` | The drag & drop options/configuration | [dd-resizable.ts:68](https://github.com/adumesny/gridstack.js/blob/master/src/dd-resizable.ts#L68) |
|
|
5126
5140
|
|
|
5127
5141
|
***
|
|
5128
5142
|
|
|
@@ -5233,6 +5247,7 @@ Drag&Drop dragging options
|
|
|
5233
5247
|
| <a id="handle"></a> `handle?` | `string` | class selector of items that can be dragged. default to '.grid-stack-item-content' | [types.ts:485](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L485) |
|
|
5234
5248
|
| <a id="helper-1"></a> `helper?` | `"clone"` \| (`el`) => `HTMLElement` | helper function when dropping: 'clone' or your own method | [types.ts:495](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L495) |
|
|
5235
5249
|
| <a id="pause"></a> `pause?` | `number` \| `boolean` | if set (true | msec), dragging placement (collision) will only happen after a pause by the user. Note: this is Global | [types.ts:489](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L489) |
|
|
5250
|
+
| <a id="rtl"></a> `rtl?` | `boolean` | - | [types.ts:500](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L500) |
|
|
5236
5251
|
| <a id="scroll"></a> `scroll?` | `boolean` | default to `true` | [types.ts:491](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L491) |
|
|
5237
5252
|
| <a id="start"></a> `start?` | (`event`, `ui`) => `void` | callbacks | [types.ts:497](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L497) |
|
|
5238
5253
|
| <a id="stop"></a> `stop?` | (`event`) => `void` | - | [types.ts:498](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L498) |
|
|
@@ -5333,6 +5348,7 @@ Drag&Drop resize options
|
|
|
5333
5348
|
| <a id="minheight"></a> `minHeight?` | `number` | - | - | [dd-resizable.ts:20](https://github.com/adumesny/gridstack.js/blob/master/src/dd-resizable.ts#L20) |
|
|
5334
5349
|
| <a id="minwidth"></a> `minWidth?` | `number` | - | - | [dd-resizable.ts:21](https://github.com/adumesny/gridstack.js/blob/master/src/dd-resizable.ts#L21) |
|
|
5335
5350
|
| <a id="resize"></a> `resize?` | (`event`, `ui`) => `void` | - | - | [dd-resizable.ts:24](https://github.com/adumesny/gridstack.js/blob/master/src/dd-resizable.ts#L24) |
|
|
5351
|
+
| <a id="rtl-1"></a> `rtl?` | `boolean` | - | - | [dd-resizable.ts:25](https://github.com/adumesny/gridstack.js/blob/master/src/dd-resizable.ts#L25) |
|
|
5336
5352
|
| <a id="start-2"></a> `start?` | (`event`, `ui`) => `void` | - | - | [dd-resizable.ts:22](https://github.com/adumesny/gridstack.js/blob/master/src/dd-resizable.ts#L22) |
|
|
5337
5353
|
| <a id="stop-2"></a> `stop?` | (`event`) => `void` | - | - | [dd-resizable.ts:23](https://github.com/adumesny/gridstack.js/blob/master/src/dd-resizable.ts#L23) |
|
|
5338
5354
|
|
|
@@ -5362,7 +5378,7 @@ Drag&Drop resize options
|
|
|
5362
5378
|
<a id="dduidata"></a>
|
|
5363
5379
|
### DDUIData
|
|
5364
5380
|
|
|
5365
|
-
Defined in: [types.ts:
|
|
5381
|
+
Defined in: [types.ts:518](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L518)
|
|
5366
5382
|
|
|
5367
5383
|
data that is passed during drag and resizing callbacks
|
|
5368
5384
|
|
|
@@ -5370,9 +5386,9 @@ data that is passed during drag and resizing callbacks
|
|
|
5370
5386
|
|
|
5371
5387
|
| Property | Type | Defined in |
|
|
5372
5388
|
| ------ | ------ | ------ |
|
|
5373
|
-
| <a id="draggable-2"></a> `draggable?` | `HTMLElement` | [types.ts:
|
|
5374
|
-
| <a id="position"></a> `position?` | [`Position`](#position-1) | [types.ts:
|
|
5375
|
-
| <a id="size"></a> `size?` | [`Size`](#size-1) | [types.ts:
|
|
5389
|
+
| <a id="draggable-2"></a> `draggable?` | `HTMLElement` | [types.ts:521](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L521) |
|
|
5390
|
+
| <a id="position"></a> `position?` | [`Position`](#position-1) | [types.ts:519](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L519) |
|
|
5391
|
+
| <a id="size"></a> `size?` | [`Size`](#size-1) | [types.ts:520](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L520) |
|
|
5376
5392
|
|
|
5377
5393
|
***
|
|
5378
5394
|
|
|
@@ -5455,7 +5471,7 @@ options used during creation - similar to GridStackOptions
|
|
|
5455
5471
|
<a id="gridstackmouseevent"></a>
|
|
5456
5472
|
### GridStackMouseEvent
|
|
5457
5473
|
|
|
5458
|
-
Defined in: [types.ts:
|
|
5474
|
+
Defined in: [types.ts:585](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L585)
|
|
5459
5475
|
|
|
5460
5476
|
#### Extends
|
|
5461
5477
|
|
|
@@ -5465,7 +5481,9 @@ Defined in: [types.ts:579](https://github.com/adumesny/gridstack.js/blob/master/
|
|
|
5465
5481
|
|
|
5466
5482
|
| Property | Type | Defined in |
|
|
5467
5483
|
| ------ | ------ | ------ |
|
|
5468
|
-
| <a id="
|
|
5484
|
+
| <a id="hasmovedx"></a> `hasMovedX?` | `boolean` | [types.ts:587](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L587) |
|
|
5485
|
+
| <a id="hasmovedy"></a> `hasMovedY?` | `boolean` | [types.ts:588](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L588) |
|
|
5486
|
+
| <a id="resizedir"></a> `resizeDir?` | `string` | [types.ts:586](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L586) |
|
|
5469
5487
|
|
|
5470
5488
|
***
|
|
5471
5489
|
|
|
@@ -5507,7 +5525,7 @@ options used during GridStackEngine.moveNode()
|
|
|
5507
5525
|
<a id="gridstacknode-2"></a>
|
|
5508
5526
|
### GridStackNode
|
|
5509
5527
|
|
|
5510
|
-
Defined in: [types.ts:
|
|
5528
|
+
Defined in: [types.ts:535](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L535)
|
|
5511
5529
|
|
|
5512
5530
|
internal runtime descriptions describing the widgets in the grid
|
|
5513
5531
|
|
|
@@ -5521,8 +5539,8 @@ internal runtime descriptions describing the widgets in the grid
|
|
|
5521
5539
|
| ------ | ------ | ------ | ------ | ------ |
|
|
5522
5540
|
| <a id="autoposition"></a> `autoPosition?` | `boolean` | if true then x, y parameters will be ignored and widget will be places on the first available position (default?: false) | [`GridStackWidget`](#gridstackwidget).[`autoPosition`](#autoposition-1) | [types.ts:428](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L428) |
|
|
5523
5541
|
| <a id="content"></a> `content?` | `string` | html to append inside as content | [`GridStackWidget`](#gridstackwidget).[`content`](#content-1) | [types.ts:446](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L446) |
|
|
5524
|
-
| <a id="el-5"></a> `el?` | [`GridItemHTMLElement`](#griditemhtmlelement) | pointer back to HTML element | - | [types.ts:
|
|
5525
|
-
| <a id="grid"></a> `grid?` | [`GridStack`](#gridstack-1) | pointer back to parent Grid instance | - | [types.ts:
|
|
5542
|
+
| <a id="el-5"></a> `el?` | [`GridItemHTMLElement`](#griditemhtmlelement) | pointer back to HTML element | - | [types.ts:537](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L537) |
|
|
5543
|
+
| <a id="grid"></a> `grid?` | [`GridStack`](#gridstack-1) | pointer back to parent Grid instance | - | [types.ts:539](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L539) |
|
|
5526
5544
|
| <a id="h-1"></a> `h?` | `number` | widget dimension height (default?: 1) | [`GridStackWidget`](#gridstackwidget).[`h`](#h-3) | [types.ts:420](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L420) |
|
|
5527
5545
|
| <a id="id"></a> `id?` | `string` | value for `gs-id` stored on the widget (default?: undefined) | [`GridStackWidget`](#gridstackwidget).[`id`](#id-1) | [types.ts:444](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L444) |
|
|
5528
5546
|
| <a id="lazyload"></a> `lazyLoad?` | `boolean` | true when widgets are only created when they scroll into view (visible) | [`GridStackWidget`](#gridstackwidget).[`lazyLoad`](#lazyload-2) | [types.ts:448](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L448) |
|
|
@@ -5535,9 +5553,9 @@ internal runtime descriptions describing the widgets in the grid
|
|
|
5535
5553
|
| <a id="noresize"></a> `noResize?` | `boolean` | prevent direct resizing by the user (default?: undefined = un-constrained) | [`GridStackWidget`](#gridstackwidget).[`noResize`](#noresize-1) | [types.ts:438](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L438) |
|
|
5536
5554
|
| <a id="resizetocontentparent-1"></a> `resizeToContentParent?` | `string` | local override of GridStack.resizeToContentParent that specify the class to use for the parent (actual) vs child (wanted) height | [`GridStackWidget`](#gridstackwidget).[`resizeToContentParent`](#resizetocontentparent-2) | [types.ts:453](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L453) |
|
|
5537
5555
|
| <a id="sizetocontent"></a> `sizeToContent?` | `number` \| `boolean` | local (vs grid) override - see GridStackOptions. Note: This also allow you to set a maximum h value (but user changeable during normal resizing) to prevent unlimited content from taking too much space (get scrollbar) | [`GridStackWidget`](#gridstackwidget).[`sizeToContent`](#sizetocontent-2) | [types.ts:451](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L451) |
|
|
5538
|
-
| <a id="subgrid"></a> `subGrid?` | [`GridStack`](#gridstack-1) | actual sub-grid instance | - | [types.ts:
|
|
5556
|
+
| <a id="subgrid"></a> `subGrid?` | [`GridStack`](#gridstack-1) | actual sub-grid instance | - | [types.ts:541](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L541) |
|
|
5539
5557
|
| <a id="subgridopts"></a> `subGridOpts?` | [`GridStackOptions`](#gridstackoptions) | optional nested grid options and list of children, which then turns into actual instance at runtime to get options from | [`GridStackWidget`](#gridstackwidget).[`subGridOpts`](#subgridopts-2) | [types.ts:455](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L455) |
|
|
5540
|
-
| <a id="visibleobservable"></a> `visibleObservable?` | `IntersectionObserver` | allow delay creation when visible | - | [types.ts:
|
|
5558
|
+
| <a id="visibleobservable"></a> `visibleObservable?` | `IntersectionObserver` | allow delay creation when visible | - | [types.ts:543](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L543) |
|
|
5541
5559
|
| <a id="w-2"></a> `w?` | `number` | widget dimension width (default?: 1) | [`GridStackWidget`](#gridstackwidget).[`w`](#w-4) | [types.ts:418](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L418) |
|
|
5542
5560
|
| <a id="x-2"></a> `x?` | `number` | widget position x (default?: 0) | [`GridStackWidget`](#gridstackwidget).[`x`](#x-4) | [types.ts:414](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L414) |
|
|
5543
5561
|
| <a id="y-2"></a> `y?` | `number` | widget position y (default?: 0) | [`GridStackWidget`](#gridstackwidget).[`y`](#y-4) | [types.ts:416](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L416) |
|
|
@@ -5683,7 +5701,7 @@ Defines the coordinates of an object
|
|
|
5683
5701
|
<a id="position-1"></a>
|
|
5684
5702
|
### Position
|
|
5685
5703
|
|
|
5686
|
-
Defined in: [types.ts:
|
|
5704
|
+
Defined in: [types.ts:506](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L506)
|
|
5687
5705
|
|
|
5688
5706
|
#### Extended by
|
|
5689
5707
|
|
|
@@ -5691,17 +5709,17 @@ Defined in: [types.ts:505](https://github.com/adumesny/gridstack.js/blob/master/
|
|
|
5691
5709
|
|
|
5692
5710
|
#### Properties
|
|
5693
5711
|
|
|
5694
|
-
| Property | Type | Defined in |
|
|
5695
|
-
| ------ | ------ | ------ |
|
|
5696
|
-
| <a id="left-1"></a> `left` | `number` | [types.ts:
|
|
5697
|
-
| <a id="top-1"></a> `top` | `number` | [types.ts:
|
|
5712
|
+
| Property | Type | Description | Defined in |
|
|
5713
|
+
| ------ | ------ | ------ | ------ |
|
|
5714
|
+
| <a id="left-1"></a> `left` | `number` | Start position of the element on the X axis. In LTR mode, this is the coordinate from the left side. In RTL mode it's actually the coordinate from the right side. | [types.ts:513](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L513) |
|
|
5715
|
+
| <a id="top-1"></a> `top` | `number` | - | [types.ts:507](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L507) |
|
|
5698
5716
|
|
|
5699
5717
|
***
|
|
5700
5718
|
|
|
5701
5719
|
<a id="rect-1"></a>
|
|
5702
5720
|
### Rect
|
|
5703
5721
|
|
|
5704
|
-
Defined in: [types.ts:
|
|
5722
|
+
Defined in: [types.ts:515](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L515)
|
|
5705
5723
|
|
|
5706
5724
|
#### Extends
|
|
5707
5725
|
|
|
@@ -5709,12 +5727,12 @@ Defined in: [types.ts:509](https://github.com/adumesny/gridstack.js/blob/master/
|
|
|
5709
5727
|
|
|
5710
5728
|
#### Properties
|
|
5711
5729
|
|
|
5712
|
-
| Property | Type | Inherited from | Defined in |
|
|
5713
|
-
| ------ | ------ | ------ | ------ |
|
|
5714
|
-
| <a id="height"></a> `height` | `number` | [`Size`](#size-1).[`height`](#height-1) | [types.ts:
|
|
5715
|
-
| <a id="left-2"></a> `left` | `number` | [`Position`](#position-1).[`left`](#left-1) | [types.ts:
|
|
5716
|
-
| <a id="top-2"></a> `top` | `number` | [`Position`](#position-1).[`top`](#top-1) | [types.ts:
|
|
5717
|
-
| <a id="width"></a> `width` | `number` | [`Size`](#size-1).[`width`](#width-1) | [types.ts:
|
|
5730
|
+
| Property | Type | Description | Inherited from | Defined in |
|
|
5731
|
+
| ------ | ------ | ------ | ------ | ------ |
|
|
5732
|
+
| <a id="height"></a> `height` | `number` | - | [`Size`](#size-1).[`height`](#height-1) | [types.ts:504](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L504) |
|
|
5733
|
+
| <a id="left-2"></a> `left` | `number` | Start position of the element on the X axis. In LTR mode, this is the coordinate from the left side. In RTL mode it's actually the coordinate from the right side. | [`Position`](#position-1).[`left`](#left-1) | [types.ts:513](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L513) |
|
|
5734
|
+
| <a id="top-2"></a> `top` | `number` | - | [`Position`](#position-1).[`top`](#top-1) | [types.ts:507](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L507) |
|
|
5735
|
+
| <a id="width"></a> `width` | `number` | - | [`Size`](#size-1).[`width`](#width-1) | [types.ts:503](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L503) |
|
|
5718
5736
|
|
|
5719
5737
|
***
|
|
5720
5738
|
|
|
@@ -5743,7 +5761,7 @@ NOTE: Make sure to include the appropriate CSS (gridstack-extra.css) to support
|
|
|
5743
5761
|
<a id="size-1"></a>
|
|
5744
5762
|
### Size
|
|
5745
5763
|
|
|
5746
|
-
Defined in: [types.ts:
|
|
5764
|
+
Defined in: [types.ts:502](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L502)
|
|
5747
5765
|
|
|
5748
5766
|
#### Extended by
|
|
5749
5767
|
|
|
@@ -5753,8 +5771,8 @@ Defined in: [types.ts:501](https://github.com/adumesny/gridstack.js/blob/master/
|
|
|
5753
5771
|
|
|
5754
5772
|
| Property | Type | Defined in |
|
|
5755
5773
|
| ------ | ------ | ------ |
|
|
5756
|
-
| <a id="height-1"></a> `height` | `number` | [types.ts:
|
|
5757
|
-
| <a id="width-1"></a> `width` | `number` | [types.ts:
|
|
5774
|
+
| <a id="height-1"></a> `height` | `number` | [types.ts:504](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L504) |
|
|
5775
|
+
| <a id="width-1"></a> `width` | `number` | [types.ts:503](https://github.com/adumesny/gridstack.js/blob/master/src/types.ts#L503) |
|
|
5758
5776
|
|
|
5759
5777
|
## Variables
|
|
5760
5778
|
|