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: doc/CHANGES.md
+2-1Lines changed: 2 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -44,7 +44,8 @@ Change log
44
44
45
45
## 3.3.0-dev
46
46
47
-
- TBD
47
+
- add new `addGrid(parent, opts)` to create a grid and load children, which is used by `load()` to supports nested grids creation. see [nested.html](https://github.com/gridstack/gridstack.js/blob/develop/demo/nested.html) demo.
48
+
48
49
## 3.3.0 (2020-11-29)
49
50
50
51
- the big news is we finally have a native HTML5 drag&drop plugin (zero jquery)! Huge thanks to [@rhlin](https://github.com/rhlin) for creating this in stealth mode. Read all about it in main doc.
Copy file name to clipboardExpand all lines: doc/README.md
+3Lines changed: 3 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -74,7 +74,9 @@ gridstack.js API
74
74
* a string (ex: '100px', '10em', '10rem', '10%', `10vh')
75
75
* 0 or null, in which case the library will not generate styles for rows. Everything must be defined in CSS files.
76
76
*`'auto'` - height will be square cells initially.
77
+
-`children`?: GridStackWidget[] - list of children item to create when calling load() or addGrid()
77
78
-`column` - number of columns (default: `12`) which can change on the fly with `column(N)` as well. See [example](http://gridstackjs.com/demo/column.html)
79
+
-`class`?: string - additional class on top of '.grid-stack' (which is required for our CSS) to differentiate this instance
78
80
-`disableDrag` - disallows dragging of widgets (default: `false`).
79
81
-`disableOneColumnMode` - disables the onColumnMode when the grid width is less than minW (default: 'false')
80
82
-`disableResize` - disallows resizing of widgets (default: `false`).
@@ -130,6 +132,7 @@ You need to add `noResize` and `noMove` attributes to completely lock the widget
130
132
-`resizeHandles` - sets resize handles for a specific widget.
131
133
-`id`- (number | string) good for quick identification (for example in change event)
132
134
-`content` - (string) html content to be added when calling `grid.load()/addWidget()` as content inside the item
135
+
-`subGrid`: GridStackOptions - optional nested grid options and list of children
/** (internal) unit for cellHeight (default? 'px') which is set when a string cellHeight with a unit is passed (ex: '10rem') */
60
60
cellHeightUnit?: string;
61
61
62
+
/** list of children item to create when calling load() or addGrid() */
63
+
children?: GridStackWidget[];
64
+
62
65
/** number of columns (default?: 12). Note: IF you change this, CSS also have to change. See https://github.com/gridstack/gridstack.js#change-grid-columns */
63
66
column?: number;
64
67
68
+
/** additional class on top of '.grid-stack' (which is required for our CSS) to differentiate this instance */
69
+
class?: string;
70
+
65
71
/** disallows dragging of widgets (default?: false) */
0 commit comments