@gravity-ui/dashkit 8.8.1-beta.5 → 8.9.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.
@@ -249,7 +249,10 @@ class GridLayout extends react_1.default.PureComponent {
249
249
  }, temporaryItem ? { [temporaryItem.i]: temporaryItem } : {});
250
250
  const newItemsLayoutById = newLayout.reduce((memo, item) => {
251
251
  const parent = itemsByGroup[item.i].parent;
252
- memo[item.i] = Object.assign(Object.assign({}, item), (parent ? { parent } : {}));
252
+ memo[item.i] = Object.assign({}, item);
253
+ if (parent) {
254
+ memo[item.i].parent = parent;
255
+ }
253
256
  return memo;
254
257
  }, {});
255
258
  return renderLayout.map((currentItem) => {
@@ -246,7 +246,10 @@ class GridLayout extends React.PureComponent {
246
246
  }, temporaryItem ? { [temporaryItem.i]: temporaryItem } : {});
247
247
  const newItemsLayoutById = newLayout.reduce((memo, item) => {
248
248
  const parent = itemsByGroup[item.i].parent;
249
- memo[item.i] = Object.assign(Object.assign({}, item), (parent ? { parent } : {}));
249
+ memo[item.i] = Object.assign({}, item);
250
+ if (parent) {
251
+ memo[item.i].parent = parent;
252
+ }
250
253
  return memo;
251
254
  }, {});
252
255
  return renderLayout.map((currentItem) => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gravity-ui/dashkit",
3
- "version": "8.8.1-beta.5",
3
+ "version": "8.9.0",
4
4
  "description": "Library for rendering dashboard grid layout",
5
5
  "license": "MIT",
6
6
  "repository": {