You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+1-3Lines changed: 1 addition & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -264,13 +264,11 @@ you can init gridstack like:
264
264
```js
265
265
GridStack.init({
266
266
resizable: {
267
-
handles:'e,se, s, sw,w'
267
+
handles:'e,se,s,sw,w'
268
268
}
269
269
});
270
270
```
271
271
272
-
Note: It's not recommended to enable `nw`, `n`, `ne` resizing handles. Their behavior may be unexpected.
273
-
274
272
## Touch devices support
275
273
276
274
gridstack v3.2 jq version compiles touch support (html5 version does not yet support `touchmove` events. This will be added in a future release), so it works out of the box, no need for anything.
Copy file name to clipboardExpand all lines: doc/CHANGES.md
+1Lines changed: 1 addition & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -59,6 +59,7 @@ Change log
59
59
- fix [#1700](https://github.com/gridstack/gridstack.js/issues/1700) JQ nested grid drag fix broken in 4.0.3 (but much older underlying issue)
60
60
- fix [#1678](https://github.com/gridstack/gridstack.js/issues/1678) item gs-x:0 not animating fix
61
61
- fix [#1678](https://github.com/gridstack/gridstack.js/pull/1678) resize-scroll issue when grid is not at top of page. Thanks [@Manfred-on-github](https://github.com/Manfred-on-github)
62
+
- fix [#1728](https://github.com/gridstack/gridstack.js/issues/1728) fix sizing from top/left sides
-`oneColumnModeDomSort` - set to `true` if you want oneColumnMode to use the DOM order and ignore x,y from normal multi column layouts during sorting. This enables you to have custom 1 column layout that differ from the rest. (default?: `false`)
117
117
-`placeholderClass` - class for placeholder (default: `'grid-stack-placeholder'`)
-`removable` - if `true` widgets could be removed by dragging outside of the grid. It could also be a jQuery selector string, in this case widgets will be removed by dropping them there (default: `false`) See [example](http://gridstackjs.com/demo/two.html)
119
+
-`resizable` - allows to override resizable options. (default: `{autoHide: true, handles: 'se'}`). `handles` can be any combo of `n,ne,e,se,s,sw,w,nw` or `all`.
120
+
-`removable` - if `true` widgets could be removed by dragging outside of the grid. It could also be a selector string, in this case widgets will be removed by dropping them there (default: `false`) See [example](http://gridstackjs.com/demo/two.html)
121
121
-`removeTimeout` - time in milliseconds before widget is being removed while dragging outside of the grid. (default: `2000`)
122
122
-`row` - fix grid number of rows. This is a shortcut of writing `minRow:N, maxRow:N`. (default `0` no constrain)
123
123
-`rtl` - if `true` turns grid to RTL. Possible values are `true`, `false`, `'auto'` (default: `'auto'`) See [example](http://gridstackjs.com/demo/rtl.html)
124
-
-`staticGrid` - removes drag&drop&resize (default `false`). If `true` widgets are not movable/resizable by the user, but code can still move and oneColumnMode will still work. You don't even need jQueryUI draggable/resizable. A CSS class `grid-stack-static` is also added to the container.
124
+
-`staticGrid` - removes drag|drop|resize (default `false`). If `true` widgets are not movable/resizable by the user, but code can still move and oneColumnMode will still work. You can use the smaller gridstack-static.js lib. A CSS class `grid-stack-static` is also added to the container.
125
125
-`styleInHead` - if `true` will add style element to `<head>` otherwise will add it to element's parent node (default `false`).
126
126
127
127
## Grid attributes
@@ -144,7 +144,7 @@ The widget can still be dragged or resized by the user.
144
144
You need to add `noResize` and `noMove` attributes to completely lock the widget.
145
145
-`noResize` - disable element resizing
146
146
-`noMove` - disable element moving
147
-
-`resizeHandles` - sets resize handles for a specific widget.
147
+
-`resizeHandles` - widgets can have their own custom resize handles. For example 'e,w' will make that particular widget only resize east and west. See `resizable: {handles: string}` option
148
148
-`id`- (number | string) good for quick identification (for example in change event)
149
149
-`content` - (string) html content to be added when calling `grid.load()/addWidget()` as content inside the item
150
150
-`subGrid`: GridStackOptions - optional nested grid options and list of children
@@ -161,7 +161,7 @@ that is affected.
161
161
You can call it on a single event name, or space separated list like:
162
162
`grid.on('added removed change', ...)`
163
163
164
-
The Typescript `GridStackEvent` list all possible values, and nothing else is supported by the `grid.on()` method, though it's possible to register directly for other events generated by the drag&drop plugging implementation detail (currently jquery-ui based so you can still use `$(".grid-stack").on(...)`).
164
+
The Typescript `GridStackEvent` list all possible values, and nothing else is supported by the `grid.on()` method, though it's possible to register directly for other events generated by the drag&drop plugging implementation detail (if jquery-ui based you can still use `$(".grid-stack").on(...)`).
/** prevents moving and resizing (default?: undefined = un-constrained) */
245
245
locked?: boolean;
246
-
/** widgets can have their own resize handles. For example 'e,w' will make the particular widget only resize east and west. */
246
+
/** widgets can have their own custom resize handles. For example 'e,w' will make that particular widget only resize east and west. See `resizable: {handles: string}` option */
247
247
resizeHandles?: string;
248
248
/** value for `gs-id` stored on the widget (default?: undefined) */
0 commit comments