@configuratorware/configurator-frontendgui 1.55.5 → 1.55.7
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.
|
@@ -21,6 +21,10 @@ function _toConsumableArray(r) { return _arrayWithoutHoles(r) || _iterableToArra
|
|
|
21
21
|
function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
22
22
|
function _iterableToArray(r) { if ("undefined" != typeof Symbol && null != r[Symbol.iterator] || null != r["@@iterator"]) return Array.from(r); }
|
|
23
23
|
function _arrayWithoutHoles(r) { if (Array.isArray(r)) return _arrayLikeToArray(r); }
|
|
24
|
+
function _slicedToArray(r, e) { return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest(); }
|
|
25
|
+
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
26
|
+
function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t["return"] && (u = t["return"](), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
|
|
27
|
+
function _arrayWithHoles(r) { if (Array.isArray(r)) return r; }
|
|
24
28
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
25
29
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
26
30
|
function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
|
|
@@ -136,6 +140,20 @@ var createDesignAreaPatch = function createDesignAreaPatch(designArea, sizeRatio
|
|
|
136
140
|
baseShape.height = Math.round(designArea.baseShape.height * bbHeightRatio);
|
|
137
141
|
position.x = position.x * bbWidthRatio;
|
|
138
142
|
position.y = position.y * bbHeightRatio;
|
|
143
|
+
|
|
144
|
+
// recalculate control points if they are being used
|
|
145
|
+
if (baseShape.useControlPoints && designArea.baseShape.points) {
|
|
146
|
+
baseShape.points = {};
|
|
147
|
+
for (var _i = 0, _Object$entries = Object.entries(designArea.baseShape.points); _i < _Object$entries.length; _i++) {
|
|
148
|
+
var _Object$entries$_i = _slicedToArray(_Object$entries[_i], 2),
|
|
149
|
+
pointKey = _Object$entries$_i[0],
|
|
150
|
+
pointCoords = _Object$entries$_i[1];
|
|
151
|
+
baseShape.points[pointKey] = {
|
|
152
|
+
x: pointCoords.x * bbWidthRatio,
|
|
153
|
+
y: pointCoords.y * bbHeightRatio
|
|
154
|
+
};
|
|
155
|
+
}
|
|
156
|
+
}
|
|
139
157
|
}
|
|
140
158
|
return {
|
|
141
159
|
position: position,
|
package/package.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@configuratorware/configurator-frontendgui",
|
|
3
|
-
"version": "1.55.
|
|
3
|
+
"version": "1.55.7",
|
|
4
4
|
"license": "UNLICENSED",
|
|
5
5
|
"private": false,
|
|
6
6
|
"main": "./index.js",
|
|
7
7
|
"dependencies": {
|
|
8
8
|
"@babel/polyfill": "^7.12.1",
|
|
9
|
-
"@configuratorware/scripts": "1.55.
|
|
9
|
+
"@configuratorware/scripts": "1.55.7",
|
|
10
10
|
"@material-ui/core": "^4.12.4",
|
|
11
11
|
"@material-ui/icons": "^4.11.3",
|
|
12
12
|
"@material-ui/lab": "^4.0.0-alpha.61",
|
|
@@ -36,8 +36,8 @@
|
|
|
36
36
|
"react-router-dom": "^5.3.4",
|
|
37
37
|
"react-swipeable": "^5.5.1",
|
|
38
38
|
"react-zoom-pan-pinch": "^2.1.3",
|
|
39
|
-
"redhotmagma-graphics-editor": "1.55.
|
|
40
|
-
"redhotmagma-visualization": "1.55.
|
|
39
|
+
"redhotmagma-graphics-editor": "1.55.7",
|
|
40
|
+
"redhotmagma-visualization": "1.55.7",
|
|
41
41
|
"redux": "^4.1.0",
|
|
42
42
|
"redux-logger": "^3.0.6",
|
|
43
43
|
"redux-persist": "^5.10.0",
|
|
@@ -102,6 +102,17 @@ const createDesignAreaPatch = (designArea, sizeRatio, visualMode) => {
|
|
|
102
102
|
baseShape.height = Math.round(designArea.baseShape.height * bbHeightRatio);
|
|
103
103
|
position.x = position.x * bbWidthRatio;
|
|
104
104
|
position.y = position.y * bbHeightRatio;
|
|
105
|
+
|
|
106
|
+
// recalculate control points if they are being used
|
|
107
|
+
if (baseShape.useControlPoints && designArea.baseShape.points) {
|
|
108
|
+
baseShape.points = {};
|
|
109
|
+
for (const [pointKey, pointCoords] of Object.entries(designArea.baseShape.points)) {
|
|
110
|
+
baseShape.points[pointKey] = {
|
|
111
|
+
x: pointCoords.x * bbWidthRatio,
|
|
112
|
+
y: pointCoords.y * bbHeightRatio,
|
|
113
|
+
};
|
|
114
|
+
}
|
|
115
|
+
}
|
|
105
116
|
}
|
|
106
117
|
|
|
107
118
|
return { position, baseShape };
|