kitchen-simulator 4.2.6 → 4.2.8

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.
@@ -123,7 +123,6 @@ export function render2DItem(element, layer, scene, sizeinfo, layoutpos, is_corn
123
123
  var rowCount = 0; //parseInt((element.type.length / lineCount - 0.51).toFixed(), 10);
124
124
 
125
125
  // Get type
126
- var type = element.type;
127
126
  var objSKU = this.obj.sku_number;
128
127
  if (objSKU.length !== 0) {
129
128
  var dcId,
@@ -137,15 +136,15 @@ export function render2DItem(element, layer, scene, sizeinfo, layoutpos, is_corn
137
136
  return el.door_color_id === dcId;
138
137
  });
139
138
  if (skuItem !== undefined) {
140
- type = skuItem.sku;
139
+ objSKU = skuItem.sku;
141
140
  }
142
141
  }
143
142
  if (rowCount > 0) {
144
143
  for (var _x = 0; _x < rowCount; _x++) {
145
- splitStr.push(type.slice(lineCount * _x, lineCount * (_x + 1)));
144
+ splitStr.push(objSKU.slice(lineCount * _x, lineCount * (_x + 1)));
146
145
  }
147
146
  }
148
- splitStr.push(type.slice(lineCount * rowCount));
147
+ splitStr.push(objSKU.slice(lineCount * rowCount));
149
148
  splitStr.forEach(function (el, key) {
150
149
  txtContent.push(/*#__PURE__*/React.createElement("text", {
151
150
  key: 'text' + key,
@@ -854,7 +854,7 @@ function replaceObject(modifiedPath, layer, planData, actions, sceneData, oldSce
854
854
  item = layer.getIn(['items', modifiedPath[4]]);
855
855
  addCountertop(planData.sceneGraph.layers[layer.id].countertops, item, planData, layer);
856
856
  // Toggle selection should not update molding
857
- if (item.category === 'cabinet' && modifiedPath[modifiedPath.length - 1] !== 'selected') {
857
+ if (item.category === 'cabinet' && modifiedPath[modifiedPath.length - 1] !== 'selected' && !modifiedPath[modifiedPath.length - 1].includes('handle')) {
858
858
  planData.sceneGraph.layers[layer.id].moldingGroups = addMolding(tmpMoldings, item, planData, layer, actions.itemsActions, mode) || _toConsumableArray(tmpMoldings);
859
859
  }
860
860
  break;
@@ -137,7 +137,6 @@ function render2DItem(element, layer, scene, sizeinfo, layoutpos, is_corner, sha
137
137
  var rowCount = 0; //parseInt((element.type.length / lineCount - 0.51).toFixed(), 10);
138
138
 
139
139
  // Get type
140
- var type = element.type;
141
140
  var objSKU = this.obj.sku_number;
142
141
  if (objSKU.length !== 0) {
143
142
  var dcId,
@@ -151,15 +150,15 @@ function render2DItem(element, layer, scene, sizeinfo, layoutpos, is_corner, sha
151
150
  return el.door_color_id === dcId;
152
151
  });
153
152
  if (skuItem !== undefined) {
154
- type = skuItem.sku;
153
+ objSKU = skuItem.sku;
155
154
  }
156
155
  }
157
156
  if (rowCount > 0) {
158
157
  for (var _x = 0; _x < rowCount; _x++) {
159
- splitStr.push(type.slice(lineCount * _x, lineCount * (_x + 1)));
158
+ splitStr.push(objSKU.slice(lineCount * _x, lineCount * (_x + 1)));
160
159
  }
161
160
  }
162
- splitStr.push(type.slice(lineCount * rowCount));
161
+ splitStr.push(objSKU.slice(lineCount * rowCount));
163
162
  splitStr.forEach(function (el, key) {
164
163
  txtContent.push(/*#__PURE__*/_react["default"].createElement("text", {
165
164
  key: 'text' + key,
@@ -889,7 +889,7 @@ function replaceObject(modifiedPath, layer, planData, actions, sceneData, oldSce
889
889
  item = layer.getIn(['items', modifiedPath[4]]);
890
890
  addCountertop(planData.sceneGraph.layers[layer.id].countertops, item, planData, layer);
891
891
  // Toggle selection should not update molding
892
- if (item.category === 'cabinet' && modifiedPath[modifiedPath.length - 1] !== 'selected') {
892
+ if (item.category === 'cabinet' && modifiedPath[modifiedPath.length - 1] !== 'selected' && !modifiedPath[modifiedPath.length - 1].includes('handle')) {
893
893
  planData.sceneGraph.layers[layer.id].moldingGroups = addMolding(tmpMoldings, item, planData, layer, actions.itemsActions, mode) || (0, _toConsumableArray2["default"])(tmpMoldings);
894
894
  }
895
895
  break;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "kitchen-simulator",
3
- "version": "4.2.6",
3
+ "version": "4.2.8",
4
4
  "description": "It is a kitchen simulator (self-contained micro-frontend).",
5
5
  "license": "MIT",
6
6
  "main": "lib/index.js",