@configuratorware/configurator-frontendgui 1.56.2 → 1.56.4

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.
Files changed (155) hide show
  1. package/App/Error/ErrorBoundary.js +8 -6
  2. package/App/Frame.js +8 -6
  3. package/App/Modules/Creator/Components/ConfigurationvariantItem/index.js +10 -8
  4. package/App/Modules/Creator/Components/ConfigurationvariantSelection/index.js +10 -8
  5. package/App/Modules/Creator/Components/CustomTitleEditor/index.js +10 -8
  6. package/App/Modules/Creator/Components/ExternalVisualization/index.js +9 -7
  7. package/App/Modules/Creator/Components/FastConfigurationRow/index.js +8 -6
  8. package/App/Modules/Creator/Components/FastConfigurationSelect/index.js +8 -6
  9. package/App/Modules/Creator/Components/FullScreenView/FullScreenView.js +11 -10
  10. package/App/Modules/Creator/Components/Incompatibility/OptionExclusionRule/index.js +8 -6
  11. package/App/Modules/Creator/Components/Incompatibility/OptionRule/index.js +8 -6
  12. package/App/Modules/Creator/Components/Incompatibility/RuleComponent.js +9 -7
  13. package/App/Modules/Creator/Components/Incompatibility/index.js +9 -8
  14. package/App/Modules/Creator/Components/Option/index.js +1 -0
  15. package/App/Modules/Creator/Components/OptionAmount/index.js +14 -6
  16. package/App/Modules/Creator/Components/Optiondetail/ZoomImage/index.js +7 -6
  17. package/App/Modules/Creator/Components/Optiondetail/index.js +17 -15
  18. package/App/Modules/Creator/Components/OptionsList/index.js +12 -11
  19. package/App/Modules/Creator/Components/Price/index.js +8 -6
  20. package/App/Modules/Creator/Components/ProductPart/index.js +8 -7
  21. package/App/Modules/Creator/Components/Tools/index.js +8 -6
  22. package/App/Modules/Creator/Layouts/DefaultLayout.js +30 -28
  23. package/App/Modules/Designer/Components/AddGalleryImage/index.js +11 -9
  24. package/App/Modules/Designer/Components/AddGalleryImage/index.story.js +4 -4
  25. package/App/Modules/Designer/Components/AddGalleryImage/index.test.js +6 -6
  26. package/App/Modules/Designer/Components/AddVisualElement/index.js +8 -6
  27. package/App/Modules/Designer/Components/AddVisualElement/index.test.js +3 -3
  28. package/App/Modules/Designer/Components/CloseDesignEditor/index.js +8 -6
  29. package/App/Modules/Designer/Components/CloseGraphicsEditorButton/index.js +5 -4
  30. package/App/Modules/Designer/Components/ColorPalettes/index.js +26 -21
  31. package/App/Modules/Designer/Components/ColorPalettes/index.test.js +3 -3
  32. package/App/Modules/Designer/Components/DesignAreaControlbox/index.js +23 -20
  33. package/App/Modules/Designer/Components/DesignAreaControlbox/index.test.js +7 -7
  34. package/App/Modules/Designer/Components/Dialog/index.js +13 -10
  35. package/App/Modules/Designer/Components/FeedbackNotice/index.js +9 -7
  36. package/App/Modules/Designer/Components/FeedbackNotice/index.test.js +1 -1
  37. package/App/Modules/Designer/Components/FullScreenView/FullScreenView.js +7 -6
  38. package/App/Modules/Designer/Components/ImageColorPicker/ImageColorPicker.js +12 -10
  39. package/App/Modules/Designer/Components/ImageColorize/index.js +39 -29
  40. package/App/Modules/Designer/Components/ImageControlbox/index.js +16 -13
  41. package/App/Modules/Designer/Components/ImageEditDialog/ImageThumbnail.js +24 -14
  42. package/App/Modules/Designer/Components/ImageEditDialog/ImageUpload.js +85 -69
  43. package/App/Modules/Designer/Components/ImageEditDialog/index.js +45 -42
  44. package/App/Modules/Designer/Components/ImageLibraryThumbnail/index.js +9 -7
  45. package/App/Modules/Designer/Components/ObjectTools/index.js +8 -6
  46. package/App/Modules/Designer/Components/Select/index.js +8 -6
  47. package/App/Modules/Designer/Components/TextControlbox/index.js +26 -21
  48. package/App/Modules/Designer/Components/TextControlbox/index.test.js +10 -10
  49. package/App/Modules/Designer/Containers/AddVisualElement.js +21 -11
  50. package/App/Modules/Designer/Containers/ImageEditDialog.js +173 -157
  51. package/App/Modules/Designer/Designer.js +7 -6
  52. package/App/Modules/Designer/Layouts/DefaultLayout.js +20 -17
  53. package/App/Modules/Designer/Layouts/PopupAreaProvider.js +18 -15
  54. package/App/Modules/Designer/Utils/Transformers.js +23 -13
  55. package/App/Modules/Designer/setupDesigner.js +27 -16
  56. package/App/Modules/Designer/withActiveCanvas.js +10 -8
  57. package/App/Modules/Visualization/AlignTargetContainer.js +1 -0
  58. package/App/Modules/Visualization/CreatorAlignTarget.js +12 -11
  59. package/App/Modules/Visualization/DefaultVisualizationProvider.js +10 -8
  60. package/App/Modules/Visualization/DesignerAlignTarget.js +10 -9
  61. package/App/Reducers/Actions.js +44 -36
  62. package/App/Reducers/Configurator/Actions.js +92 -78
  63. package/App/Reducers/Configurator/Selectors.js +5 -5
  64. package/App/Reducers/Confirm/Actions.js +16 -6
  65. package/App/Reducers/DesignArea/Selectors.js +2 -1
  66. package/App/Reducers/ImageGallery/Actions.js +31 -18
  67. package/App/Reducers/ImageGallery/Reducer.js +1 -0
  68. package/App/Reducers/ImageGallery/Selectors.js +1 -0
  69. package/App/Reducers/UI/Actions.js +40 -26
  70. package/App/Routing.js +8 -6
  71. package/App/Screens/Configurator/Components/AmountSelection/index.js +11 -9
  72. package/App/Screens/Configurator/Components/CalculationWidget/index.js +19 -17
  73. package/App/Screens/Configurator/Components/CalculationWidget/index.test.js +8 -8
  74. package/App/Screens/Configurator/Components/Confirm/index.js +8 -6
  75. package/App/Screens/Configurator/Components/Error/index.js +9 -7
  76. package/App/Screens/Configurator/Components/FullScreenView/index.js +24 -21
  77. package/App/Screens/Configurator/Components/FullScreenView/index.test.js +2 -2
  78. package/App/Screens/Configurator/Components/ItemTile/ItemTile.js +13 -5
  79. package/App/Screens/Configurator/Components/PreviewPortal/index.js +10 -8
  80. package/App/Screens/Configurator/Components/Thumbnail/index.js +27 -24
  81. package/App/Screens/Configurator/Components/Thumbnail/index.test.js +2 -2
  82. package/App/Screens/Configurator/Containers/AmountPrice.js +6 -5
  83. package/App/Screens/Configurator/Containers/ConfigurationModeSwitch.js +19 -10
  84. package/App/Screens/DesignerProductPreview/DesignerProductPreviewManager.js +88 -73
  85. package/App/Screens/DesignerProductPreview/Screen.js +21 -14
  86. package/App/Screens/ItemOverview/Components/ItemOverview.js +47 -32
  87. package/App/ServiceLocator.js +4 -2
  88. package/App/Services/AdminareaCommunicationService.js +24 -14
  89. package/App/Services/AnalyticsService.js +48 -47
  90. package/App/Services/ConfiguratorService.js +142 -121
  91. package/App/Services/DesignDataService.js +619 -555
  92. package/App/Services/DesignerService.js +100 -79
  93. package/App/Services/InteractionService.js +236 -210
  94. package/App/Services/UIService.js +10 -7
  95. package/App/Services/VisualizationService.js +104 -86
  96. package/App/Shared/Components/AcceptDesign/index.js +19 -16
  97. package/App/Shared/Components/AcceptPrivacy/index.js +8 -6
  98. package/App/Shared/Components/AddToBasket/index.js +8 -6
  99. package/App/Shared/Components/AlertDialog/index.js +9 -7
  100. package/App/Shared/Components/AmountInput/index.js +24 -21
  101. package/App/Shared/Components/AmountPrice/index.js +128 -115
  102. package/App/Shared/Components/AmountPrice/index.test.js +5 -5
  103. package/App/Shared/Components/BulkNames/index.js +8 -6
  104. package/App/Shared/Components/ConfigurationOverview/index.js +8 -6
  105. package/App/Shared/Components/InformationTag/InformationTag.js +11 -9
  106. package/App/Shared/Components/LicenseNotice/LicenseNotice.js +8 -6
  107. package/App/Shared/Components/LoadConfiguration/index.js +9 -7
  108. package/App/Shared/Components/Notification/index.js +8 -6
  109. package/App/Shared/Components/PdfDownload/index.js +25 -15
  110. package/App/Shared/Components/PriceList/index.js +16 -13
  111. package/App/Shared/Components/PriceOverview/index.js +13 -10
  112. package/App/Shared/Components/ProductVariant/index.js +25 -22
  113. package/App/Shared/Components/ProductVariant/index.story.js +1 -0
  114. package/App/Shared/Components/ReceiveOfferForm/index.js +12 -10
  115. package/App/Shared/Components/ReceiveOfferForm/index.test.js +2 -2
  116. package/App/Shared/Components/SaveConfiguration/index.js +32 -22
  117. package/App/Shared/Components/Stepper/index.js +10 -8
  118. package/App/Shared/Components/ToolbarList/index.js +11 -9
  119. package/App/Shared/Components/VariantChooser/index.js +13 -10
  120. package/App/Shared/Containers/BulkNames.js +15 -13
  121. package/App/Shared/Containers/Header/index.js +15 -7
  122. package/App/Shared/Containers/LoadConfiguration/LoadConfiguration.js +22 -15
  123. package/App/Shared/Containers/ProductVariant/ProductVariant.js +23 -15
  124. package/App/Translations.js +56 -40
  125. package/App/Utils/Request/lazyFetch.js +27 -19
  126. package/App/configuration.js +4 -0
  127. package/App/index.js +24 -14
  128. package/Framework/Api.js +2 -1
  129. package/Framework/ComponentContainer.js +14 -11
  130. package/Framework/Components/Carousel/index.js +13 -11
  131. package/Framework/Components/Dialog/index.js +35 -33
  132. package/Framework/Components/DialogSelect/index.js +19 -16
  133. package/Framework/Components/Input/index.js +12 -10
  134. package/Framework/CustomError.js +6 -5
  135. package/Framework/Helpers/TransitionDetect.js +2 -1
  136. package/Framework/Services/AbstractAdminareaCommunicationService.js +2 -1
  137. package/Framework/Services/AbstractAsyncService.js +2 -1
  138. package/Framework/Services/AbstractConfiguratorService.js +2 -1
  139. package/Framework/Services/AbstractInteractionService.js +2 -1
  140. package/Framework/Services/AbstractStoreService.js +2 -1
  141. package/Framework/Services/AbstractUIService.js +2 -1
  142. package/Framework/Services/AbstractVisualizationService.js +2 -1
  143. package/Framework/Services/AsyncService.js +8 -6
  144. package/Framework/Services/StoreService.js +27 -17
  145. package/Framework/bindDecorator.js +7 -6
  146. package/Framework/i18n.js +10 -8
  147. package/Shared/ErrorTypes/DeferredError.js +6 -5
  148. package/Shared/HOCs/ResizeDetect/ResizeDetect.js +11 -9
  149. package/Utils/Async/AsyncManager.js +30 -20
  150. package/Utils/Async/Deferred.js +4 -2
  151. package/Utils/Decorators/Observable.js +2 -1
  152. package/Utils/Dev/HOCs/withFilePicker.js +10 -8
  153. package/Utils/Immutable/set.js +6 -6
  154. package/Utils/Test/mountWithState.js +1 -1
  155. package/package.json +4 -4
@@ -11,8 +11,15 @@ var _configuration = require("../configuration");
11
11
  var _ServiceLocator = require("../ServiceLocator");
12
12
  var _createMessageInterface = _interopRequireDefault(require("../Utils/createMessageInterface"));
13
13
  function _interopRequireDefault(e) { return e && e.__esModule ? e : { "default": e }; }
14
+ function _regeneratorRuntime() { "use strict"; var r = _regenerator(), e = r.m(_regeneratorRuntime), t = (Object.getPrototypeOf ? Object.getPrototypeOf(e) : e.__proto__).constructor; function n(r) { var e = "function" == typeof r && r.constructor; return !!e && (e === t || "GeneratorFunction" === (e.displayName || e.name)); } var o = { "throw": 1, "return": 2, "break": 3, "continue": 3 }; function a(r) { var e, t; return function (n) { e || (e = { stop: function stop() { return t(n.a, 2); }, "catch": function _catch() { return n.v; }, abrupt: function abrupt(r, e) { return t(n.a, o[r], e); }, delegateYield: function delegateYield(r, o, a) { return e.resultName = o, t(n.d, _regeneratorValues(r), a); }, finish: function finish(r) { return t(n.f, r); } }, t = function t(r, _t, o) { n.p = e.prev, n.n = e.next; try { return r(_t, o); } finally { e.next = n.n; } }), e.resultName && (e[e.resultName] = n.v, e.resultName = void 0), e.sent = n.v, e.next = n.n; try { return r.call(this, e); } finally { n.p = e.prev, n.n = e.next; } }; } return (_regeneratorRuntime = function _regeneratorRuntime() { return { wrap: function wrap(e, t, n, o) { return r.w(a(e), t, n, o && o.reverse()); }, isGeneratorFunction: n, mark: r.m, awrap: function awrap(r, e) { return new _OverloadYield(r, e); }, AsyncIterator: _regeneratorAsyncIterator, async: function async(r, e, t, o, u) { return (n(e) ? _regeneratorAsyncGen : _regeneratorAsync)(a(r), e, t, o, u); }, keys: _regeneratorKeys, values: _regeneratorValues }; })(); }
15
+ function _regeneratorValues(e) { if (null != e) { var t = e["function" == typeof Symbol && Symbol.iterator || "@@iterator"], r = 0; if (t) return t.call(e); if ("function" == typeof e.next) return e; if (!isNaN(e.length)) return { next: function next() { return e && r >= e.length && (e = void 0), { value: e && e[r++], done: !e }; } }; } throw new TypeError(_typeof(e) + " is not iterable"); }
16
+ function _regeneratorKeys(e) { var n = Object(e), r = []; for (var t in n) r.unshift(t); return function e() { for (; r.length;) if ((t = r.pop()) in n) return e.value = t, e.done = !1, e; return e.done = !0, e; }; }
17
+ function _regeneratorAsync(n, e, r, t, o) { var a = _regeneratorAsyncGen(n, e, r, t, o); return a.next().then(function (n) { return n.done ? n.value : a.next(); }); }
18
+ function _regeneratorAsyncGen(r, e, t, o, n) { return new _regeneratorAsyncIterator(_regenerator().w(r, e, t, o), n || Promise); }
19
+ function _regeneratorAsyncIterator(t, e) { function n(r, o, i, f) { try { var c = t[r](o), u = c.value; return u instanceof _OverloadYield ? e.resolve(u.v).then(function (t) { n("next", t, i, f); }, function (t) { n("throw", t, i, f); }) : e.resolve(u).then(function (t) { c.value = t, i(c); }, function (t) { return n("throw", t, i, f); }); } catch (t) { f(t); } } var r; this.next || (_regeneratorDefine2(_regeneratorAsyncIterator.prototype), _regeneratorDefine2(_regeneratorAsyncIterator.prototype, "function" == typeof Symbol && Symbol.asyncIterator || "@asyncIterator", function () { return this; })), _regeneratorDefine2(this, "_invoke", function (t, o, i) { function f() { return new e(function (e, r) { n(t, i, e, r); }); } return r = r ? r.then(f, f) : f(); }, !0); }
14
20
  function _regenerator() { /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */ var e, t, r = "function" == typeof Symbol ? Symbol : {}, n = r.iterator || "@@iterator", o = r.toStringTag || "@@toStringTag"; function i(r, n, o, i) { var c = n && n.prototype instanceof Generator ? n : Generator, u = Object.create(c.prototype); return _regeneratorDefine2(u, "_invoke", function (r, n, o) { var i, c, u, f = 0, p = o || [], y = !1, G = { p: 0, n: 0, v: e, a: d, f: d.bind(e, 4), d: function d(t, r) { return i = t, c = 0, u = e, G.n = r, a; } }; function d(r, n) { for (c = r, u = n, t = 0; !y && f && !o && t < p.length; t++) { var o, i = p[t], d = G.p, l = i[2]; r > 3 ? (o = l === n) && (u = i[(c = i[4]) ? 5 : (c = 3, 3)], i[4] = i[5] = e) : i[0] <= d && ((o = r < 2 && d < i[1]) ? (c = 0, G.v = n, G.n = i[1]) : d < l && (o = r < 3 || i[0] > n || n > l) && (i[4] = r, i[5] = n, G.n = l, c = 0)); } if (o || r > 1) return a; throw y = !0, n; } return function (o, p, l) { if (f > 1) throw TypeError("Generator is already running"); for (y && 1 === p && d(p, l), c = p, u = l; (t = c < 2 ? e : u) || !y;) { i || (c ? c < 3 ? (c > 1 && (G.n = -1), d(c, u)) : G.n = u : G.v = u); try { if (f = 2, i) { if (c || (o = "next"), t = i[o]) { if (!(t = t.call(i, u))) throw TypeError("iterator result is not an object"); if (!t.done) return t; u = t.value, c < 2 && (c = 0); } else 1 === c && (t = i["return"]) && t.call(i), c < 2 && (u = TypeError("The iterator does not provide a '" + o + "' method"), c = 1); i = e; } else if ((t = (y = G.n < 0) ? u : r.call(n, G)) !== a) break; } catch (t) { i = e, c = 1, u = t; } finally { f = 1; } } return { value: t, done: y }; }; }(r, o, i), !0), u; } var a = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} t = Object.getPrototypeOf; var c = [][n] ? t(t([][n]())) : (_regeneratorDefine2(t = {}, n, function () { return this; }), t), u = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(c); function f(e) { return Object.setPrototypeOf ? Object.setPrototypeOf(e, GeneratorFunctionPrototype) : (e.__proto__ = GeneratorFunctionPrototype, _regeneratorDefine2(e, o, "GeneratorFunction")), e.prototype = Object.create(u), e; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, _regeneratorDefine2(u, "constructor", GeneratorFunctionPrototype), _regeneratorDefine2(GeneratorFunctionPrototype, "constructor", GeneratorFunction), GeneratorFunction.displayName = "GeneratorFunction", _regeneratorDefine2(GeneratorFunctionPrototype, o, "GeneratorFunction"), _regeneratorDefine2(u), _regeneratorDefine2(u, o, "Generator"), _regeneratorDefine2(u, n, function () { return this; }), _regeneratorDefine2(u, "toString", function () { return "[object Generator]"; }), (_regenerator = function _regenerator() { return { w: i, m: f }; })(); }
15
21
  function _regeneratorDefine2(e, r, n, t) { var i = Object.defineProperty; try { i({}, "", {}); } catch (e) { i = 0; } _regeneratorDefine2 = function _regeneratorDefine(e, r, n, t) { function o(r, n) { _regeneratorDefine2(e, r, function (e) { return this._invoke(r, n, e); }); } r ? i ? i(e, r, { value: n, enumerable: !t, configurable: !t, writable: !t }) : e[r] = n : (o("next", 0), o("throw", 1), o("return", 2)); }, _regeneratorDefine2(e, r, n, t); }
22
+ function _OverloadYield(e, d) { this.v = e, this.k = d; }
16
23
  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; }
17
24
  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; }
18
25
  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; }
@@ -23,46 +30,48 @@ function _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o =
23
30
  function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { writable: !1 }), e; }
24
31
  function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
25
32
  function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
26
- function _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
33
+ function _inherits(t, e) { if ("function" != typeof e && null !== e) throw new TypeError("Super expression must either be null or a function"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, "prototype", { writable: !1 }), e && _setPrototypeOf(t, e); }
34
+ function _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }
35
+ function _createSuper(t) { var r = _isNativeReflectConstruct(); return function () { var e, o = _getPrototypeOf(t); if (r) { var s = _getPrototypeOf(this).constructor; e = Reflect.construct(o, arguments, s); } else e = o.apply(this, arguments); return _possibleConstructorReturn(this, e); }; }
27
36
  function _possibleConstructorReturn(t, e) { if (e && ("object" == _typeof(e) || "function" == typeof e)) return e; if (void 0 !== e) throw new TypeError("Derived constructors may only return object or undefined"); return _assertThisInitialized(t); }
28
37
  function _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); return e; }
29
38
  function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
30
39
  function _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }
31
- function _inherits(t, e) { if ("function" != typeof e && null !== e) throw new TypeError("Super expression must either be null or a function"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, "prototype", { writable: !1 }), e && _setPrototypeOf(t, e); }
32
- function _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }
33
40
  /**
34
41
  * Service that handles the postMessage Communication with the admin area
35
42
  *
36
43
  * The configurator is included into the adminarea as an IFrame at some areas
37
44
  */
38
45
  var AdminareaCommunicationService = exports["default"] = /*#__PURE__*/function (_AbstractAdminareaCom) {
46
+ _inherits(AdminareaCommunicationService, _AbstractAdminareaCom);
47
+ var _super = _createSuper(AdminareaCommunicationService);
39
48
  function AdminareaCommunicationService() {
40
49
  _classCallCheck(this, AdminareaCommunicationService);
41
- return _callSuper(this, AdminareaCommunicationService, arguments);
50
+ return _super.apply(this, arguments);
42
51
  }
43
- _inherits(AdminareaCommunicationService, _AbstractAdminareaCom);
44
- return _createClass(AdminareaCommunicationService, [{
52
+ _createClass(AdminareaCommunicationService, [{
45
53
  key: "init",
46
54
  value: function init() {
47
55
  var adminMode = (0, _configuration.getConf)('adminMode');
48
56
  if (adminMode) {
49
57
  var messageInterface = (0, _createMessageInterface["default"])();
50
58
  messageInterface.addListener('getConfiguration', /*#__PURE__*/function () {
51
- var _ref = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee(event) {
59
+ var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(event) {
52
60
  var configuration;
53
- return _regenerator().w(function (_context) {
54
- while (1) switch (_context.n) {
61
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
62
+ while (1) switch (_context.prev = _context.next) {
55
63
  case 0:
56
- _context.n = 1;
64
+ _context.next = 2;
57
65
  return _ServiceLocator.Services.interaction.adminGetConfiguration();
58
- case 1:
59
- configuration = _context.v;
66
+ case 2:
67
+ configuration = _context.sent;
60
68
  event.source.postMessage(_objectSpread(_objectSpread({}, event.data), {}, {
61
69
  adminMode: adminMode,
62
70
  configuration: configuration
63
71
  }), event.origin);
64
- case 2:
65
- return _context.a(2);
72
+ case 4:
73
+ case "end":
74
+ return _context.stop();
66
75
  }
67
76
  }, _callee);
68
77
  }));
@@ -108,4 +117,5 @@ var AdminareaCommunicationService = exports["default"] = /*#__PURE__*/function (
108
117
  }
109
118
  }
110
119
  }]);
120
+ return AdminareaCommunicationService;
111
121
  }(_AbstractAdminareaCommunicationService["default"]);
@@ -19,73 +19,73 @@ function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r),
19
19
  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; }
20
20
  function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
21
21
  function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
22
- var actionsToTrack = exports.actionsToTrack = (_actionsToTrack = {}, _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_actionsToTrack, _Constant.EventTypes.load, function (action) {
22
+ var actionsToTrack = exports.actionsToTrack = (_actionsToTrack = {}, _defineProperty(_actionsToTrack, _Constant.EventTypes.load, function (action) {
23
23
  return {
24
24
  event: action.type
25
25
  };
26
- }), _Constant.EventTypes.save, function (action) {
26
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.save, function (action) {
27
27
  return {
28
28
  event: action.type
29
29
  };
30
- }), _Constant.EventTypes.save, function (action) {
30
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.save, function (action) {
31
31
  return {
32
32
  event: action.type
33
33
  };
34
- }), _Constant.EventTypes.mail, function (action) {
34
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.mail, function (action) {
35
35
  return {
36
36
  event: action.type
37
37
  };
38
- }), _Constant.EventTypes.load_request, function (action) {
38
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.load_request, function (action) {
39
39
  return {
40
40
  event: action.type,
41
41
  configuration_code: action.data
42
42
  };
43
- }), _Constant.EventTypes.change_variant, function (action) {
43
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.change_variant, function (action) {
44
44
  return {
45
45
  event: action.type,
46
46
  selected_variant_identifier: action.data.key
47
47
  };
48
- }), _Constant.EventTypes.preview_open, function (action) {
48
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.preview_open, function (action) {
49
49
  return {
50
50
  event: action.type
51
51
  };
52
- }), _Constant.EventTypes.preview_close, function (action) {
52
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.preview_close, function (action) {
53
53
  return {
54
54
  event: action.type
55
55
  };
56
- }), _Constant.EventTypes.add_text, function (action) {
56
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.add_text, function (action) {
57
57
  return {
58
58
  event: action.type
59
59
  };
60
- }), _Constant.EventTypes.add_image, function (action) {
60
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.add_image, function (action) {
61
61
  return {
62
62
  event: action.type
63
63
  };
64
- }), _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_actionsToTrack, _Constant.EventTypes.uploaded_file_type, function (action) {
64
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.uploaded_file_type, function (action) {
65
65
  return {
66
66
  event: action.type,
67
67
  file_type: action.data.type
68
68
  };
69
- }), _Constant.EventTypes.edit_image, function (action) {
69
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.edit_image, function (action) {
70
70
  return {
71
71
  event: action.type
72
72
  };
73
- }), _Constant.EventTypes.image_colorize, function (action) {
73
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.image_colorize, function (action) {
74
74
  return {
75
75
  event: action.type,
76
76
  selected_image_edit_colorize: action.data
77
77
  };
78
- }), _Constant.EventTypes.image_edit_colorize_color, function (action) {
78
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.image_edit_colorize_color, function (action) {
79
79
  return {
80
80
  event: action.type,
81
81
  selected_color: action.data
82
82
  };
83
- }), _Constant.EventTypes.image_edit_colorize_found_colors, function (action) {
83
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.image_edit_colorize_found_colors, function (action) {
84
84
  return {
85
85
  event: action.type,
86
86
  color_amount: action.data
87
87
  };
88
- }), _Constant.EventTypes.image_background, function (action) {
88
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.image_background, function (action) {
89
89
  return {
90
90
  event: action.type,
91
91
  image_edit_operation: (0, _i18n.t)('fileUpload.' + ({
@@ -93,77 +93,77 @@ var actionsToTrack = exports.actionsToTrack = (_actionsToTrack = {}, _defineProp
93
93
  flood: 'removeBackgroundFromBorder'
94
94
  }[action.data] || 'notRemoveBackground'))
95
95
  };
96
- }), _Constant.EventTypes.image_edit_options, function (action) {
96
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.image_edit_options, function (action) {
97
97
  return {
98
98
  event: action.data === 0 ? 'image_edit_change_file' : action.data === 1 ? 'image_edit_remove_background' : 'image_edit_colorize'
99
99
  };
100
- }), _Constant.EventTypes.upload_new, function (action) {
100
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.upload_new, function (action) {
101
101
  return {
102
102
  event: action.type
103
103
  };
104
- }), _Constant.EventTypes.image_thumbnail_select, function (action) {
104
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.image_thumbnail_select, function (action) {
105
105
  return {
106
106
  event: action.type,
107
107
  selected_image: action.data
108
108
  };
109
- }), _Constant.EventTypes.text_bold, function (action) {
109
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.text_bold, function (action) {
110
110
  return {
111
111
  event: action.type
112
112
  };
113
- }), _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_actionsToTrack, _Constant.EventTypes.text_font, function (action) {
113
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.text_font, function (action) {
114
114
  return {
115
115
  event: action.type,
116
116
  selected_font_name: action.data.key
117
117
  };
118
- }), _Constant.EventTypes.text_italic, function (action) {
118
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.text_italic, function (action) {
119
119
  return {
120
120
  event: action.type
121
121
  };
122
- }), _Constant.EventTypes.text_align_left, function (action) {
122
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.text_align_left, function (action) {
123
123
  return {
124
124
  event: action.type
125
125
  };
126
- }), _Constant.EventTypes.text_align_center, function (action) {
126
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.text_align_center, function (action) {
127
127
  return {
128
128
  event: action.type
129
129
  };
130
- }), _Constant.EventTypes.text_align_right, function (action) {
130
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.text_align_right, function (action) {
131
131
  return {
132
132
  event: action.type
133
133
  };
134
- }), _Constant.EventTypes.text_align_justify, function (action) {
134
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.text_align_justify, function (action) {
135
135
  return {
136
136
  event: action.type
137
137
  };
138
- }), _Constant.EventTypes.text_color, function (action) {
138
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.text_color, function (action) {
139
139
  return {
140
140
  event: action.type,
141
141
  selected_color: action.data
142
142
  };
143
- }), _Constant.EventTypes.align_horizontal_center, function (action) {
143
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.align_horizontal_center, function (action) {
144
144
  return {
145
145
  event: action.type
146
146
  };
147
- }), _Constant.EventTypes.align_vertical_center, function (action) {
147
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.align_vertical_center, function (action) {
148
148
  return {
149
149
  event: action.type
150
150
  };
151
- }), _Constant.EventTypes.align_move_down, function (action) {
151
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.align_move_down, function (action) {
152
152
  return {
153
153
  event: action.type
154
154
  };
155
- }), _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_actionsToTrack, _Constant.EventTypes.align_move_up, function (action) {
155
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.align_move_up, function (action) {
156
156
  return {
157
157
  event: action.type
158
158
  };
159
- }), _Constant.EventTypes.add_to_cart, function (action, state) {
159
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.add_to_cart, function (action, state) {
160
160
  var selectedMode = state.configurationMode.selectedMode;
161
161
  var event = (0, _Selectors.isDesignerMode)(selectedMode) ? _Constant.EventTypes.add_to_cart : _Constant.EventTypes.configuration_add_to_cart;
162
162
  return {
163
163
  event: event,
164
164
  selected_amounts: state.configurator.configuration.customdata.selectedAmounts
165
165
  };
166
- }), _Constant.EventTypes.selected_amounts, function (action, state) {
166
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.selected_amounts, function (action, state) {
167
167
  var selectedMode = state.configurationMode.selectedMode;
168
168
  var event = (0, _Selectors.isDesignerMode)(selectedMode) ? _Constant.EventTypes.selected_amounts : _Constant.EventTypes.configuration_selected_amounts;
169
169
  return {
@@ -173,21 +173,21 @@ var actionsToTrack = exports.actionsToTrack = (_actionsToTrack = {}, _defineProp
173
173
  selected_design_production_methods: getSelectedDesignProductionMethods(state),
174
174
  selected_options: getSelectedOptions(state)
175
175
  };
176
- }), _Constant.EventTypes.design_area_switch, function (action, state) {
176
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.design_area_switch, function (action, state) {
177
177
  return {
178
178
  event: action.type,
179
179
  selected_design_area_identifier: state.designArea.selectedDesignArea.identifier
180
180
  };
181
- }), _Constant.EventTypes.design_production_switch, function (action) {
181
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.design_production_switch, function (action) {
182
182
  return {
183
183
  event: action.type,
184
184
  selected_design_production_method_identifier: action.data.key
185
185
  };
186
- }), _Constant.EventTypes.widget_print_view, function (action) {
186
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.widget_print_view, function (action) {
187
187
  return {
188
188
  event: action.type
189
189
  };
190
- }), _Constant.EventTypes.widget_open_configurator, function (action, state) {
190
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.widget_open_configurator, function (action, state) {
191
191
  return {
192
192
  event: action.type,
193
193
  selected_design_areas: getSelectedDesignAreas(state),
@@ -195,49 +195,49 @@ var actionsToTrack = exports.actionsToTrack = (_actionsToTrack = {}, _defineProp
195
195
  selected_options: getSelectedWidgetConfigurationOptions(state),
196
196
  selected_amount: state.configurator.configuration.customdata.selectedAmounts
197
197
  };
198
- }), _Constant.EventTypes.widget_change_amount, function (action, state) {
198
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.widget_change_amount, function (action, state) {
199
199
  return {
200
200
  event: action.type,
201
201
  selected_amounts: state.configurator.configuration.customdata.selectedAmounts
202
202
  };
203
- }), _Constant.EventTypes.widget_add_design_area, function (action) {
203
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.widget_add_design_area, function (action) {
204
204
  return {
205
205
  event: action.type,
206
206
  selected_design_area_identifier: action.data
207
207
  };
208
- }), _Constant.EventTypes.widget_remove_design_area, function (action) {
208
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.widget_remove_design_area, function (action) {
209
209
  return {
210
210
  event: action.type,
211
211
  removed_design_area_identifier: action.data
212
212
  };
213
- }), _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_actionsToTrack, _Constant.EventTypes.widget_change_design_production_method, function (action) {
213
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.widget_change_design_production_method, function (action) {
214
214
  return {
215
215
  event: action.type,
216
216
  selected_design_production_method_identifier: action.data.key
217
217
  };
218
- }), _Constant.EventTypes.load_item, function (action) {
218
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.load_item, function (action) {
219
219
  return {
220
220
  event: action.type,
221
221
  item_identifier: action.data
222
222
  };
223
- }), _Constant.EventTypes.switch_option, function (action) {
223
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.switch_option, function (action) {
224
224
  return {
225
225
  event: action.type,
226
226
  selected_component: action.data.component,
227
227
  selected_option: action.data.option
228
228
  };
229
- }), _Constant.EventTypes.select_component, function (action) {
229
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.select_component, function (action) {
230
230
  return {
231
231
  event: action.type,
232
232
  selected_component: action.data
233
233
  };
234
- }), _Constant.EventTypes.configuration_mode_switch, function (action) {
234
+ }), _defineProperty(_actionsToTrack, _Constant.EventTypes.configuration_mode_switch, function (action) {
235
235
  return {
236
236
  event: action.type,
237
237
  switch_from: action.data === 'designer' ? 'creator' : 'designer',
238
238
  switch_to: action.data
239
239
  };
240
- }));
240
+ }), _actionsToTrack);
241
241
  var getSelectedWidgetConfigurationOptions = function getSelectedWidgetConfigurationOptions(state) {
242
242
  var confoptions = [];
243
243
  var calculationObj = state.configurator.calculation.positions;
@@ -294,7 +294,7 @@ var AnalyticsService = exports["default"] = /*#__PURE__*/function () {
294
294
  _classCallCheck(this, AnalyticsService);
295
295
  _defineProperty(this, "EventTypes", _Constant.EventTypes);
296
296
  }
297
- return _createClass(AnalyticsService, [{
297
+ _createClass(AnalyticsService, [{
298
298
  key: "setDataLayer",
299
299
  value: function setDataLayer(dataLayer) {
300
300
  this.dataLayer = dataLayer;
@@ -320,5 +320,6 @@ var AnalyticsService = exports["default"] = /*#__PURE__*/function () {
320
320
  }
321
321
  }
322
322
  }]);
323
+ return AnalyticsService;
323
324
  }();
324
325
  _defineProperty(AnalyticsService, "serviceName", 'AnalyticsService');