kitchen-simulator 1.1.1-test.70 → 1.1.1-test.71

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 (188) hide show
  1. package/es/@history.js +2 -8
  2. package/es/AppContext.js +3 -8
  3. package/es/KitchenConfigurator.js +70 -77
  4. package/es/KitchenConfiguratorApp.js +98 -105
  5. package/es/actions/area-actions.js +5 -10
  6. package/es/actions/export.js +12 -27
  7. package/es/actions/groups-actions.js +27 -43
  8. package/es/actions/holes-actions.js +34 -53
  9. package/es/actions/items-actions.js +94 -143
  10. package/es/actions/lines-actions.js +21 -34
  11. package/es/actions/project-actions.js +94 -143
  12. package/es/actions/scene-actions.js +11 -19
  13. package/es/actions/vertices-actions.js +7 -13
  14. package/es/actions/viewer2d-actions.js +21 -34
  15. package/es/actions/viewer3d-actions.js +9 -16
  16. package/es/catalog/areas/area/planner-element.js +2 -7
  17. package/es/catalog/catalog.js +15 -19
  18. package/es/catalog/factories/area-factory-3d.js +22 -29
  19. package/es/catalog/factories/area-factory.js +11 -18
  20. package/es/catalog/factories/export.js +6 -12
  21. package/es/catalog/factories/wall-factory-3d.js +31 -39
  22. package/es/catalog/factories/wall-factory.js +21 -29
  23. package/es/catalog/holes/door-closet/planner-element.js +15 -22
  24. package/es/catalog/holes/door-double/planner-element.js +15 -22
  25. package/es/catalog/holes/door-exterior/planner-element.js +16 -23
  26. package/es/catalog/holes/door-interior/planner-element.js +16 -23
  27. package/es/catalog/holes/door-panic/planner-element.js +7 -14
  28. package/es/catalog/holes/door-panic-double/planner-element.js +15 -22
  29. package/es/catalog/holes/door-sliding/planner-element.js +16 -23
  30. package/es/catalog/holes/doorway-framed/planner-element.js +11 -18
  31. package/es/catalog/holes/doorway-frameless/planner-element.js +7 -14
  32. package/es/catalog/holes/export.js +13 -31
  33. package/es/catalog/holes/window-clear/planner-element.js +10 -17
  34. package/es/catalog/holes/window-cross/planner-element.js +10 -17
  35. package/es/catalog/holes/window-double-hung/planner-element.js +10 -17
  36. package/es/catalog/holes/window-vertical/planner-element.js +10 -17
  37. package/es/catalog/lines/wall/planner-element.js +2 -7
  38. package/es/catalog/molding/molding-dcm/planner-element.js +5 -12
  39. package/es/catalog/molding/molding-fbm/planner-element.js +5 -12
  40. package/es/catalog/molding/molding-lrm/planner-element.js +5 -12
  41. package/es/catalog/properties/export.js +20 -33
  42. package/es/catalog/properties/property-checkbox.js +24 -29
  43. package/es/catalog/properties/property-color.js +16 -21
  44. package/es/catalog/properties/property-enum.js +24 -29
  45. package/es/catalog/properties/property-hidden.js +9 -14
  46. package/es/catalog/properties/property-lenght-measure.js +38 -43
  47. package/es/catalog/properties/property-length-measure.js +36 -41
  48. package/es/catalog/properties/property-length-measure_hole.js +38 -43
  49. package/es/catalog/properties/property-number.js +17 -22
  50. package/es/catalog/properties/property-read-only.js +16 -21
  51. package/es/catalog/properties/property-string.js +16 -21
  52. package/es/catalog/properties/property-toggle.js +16 -21
  53. package/es/catalog/properties/shared-property-style.js +1 -5
  54. package/es/catalog/utils/FuseUtils.js +8 -13
  55. package/es/catalog/utils/exporter.js +8 -13
  56. package/es/catalog/utils/geom-utils.js +13 -27
  57. package/es/catalog/utils/item-loader.js +84 -95
  58. package/es/catalog/utils/load-obj.js +20 -26
  59. package/es/catalog/utils/mtl-loader.js +3 -6
  60. package/es/catalog/utils/obj-loader.js +3 -6
  61. package/es/class/FuseUtils.js +8 -13
  62. package/es/class/area.js +22 -26
  63. package/es/class/export.js +23 -38
  64. package/es/class/group.js +53 -57
  65. package/es/class/guide.js +15 -19
  66. package/es/class/hole.js +83 -87
  67. package/es/class/item.js +141 -145
  68. package/es/class/layer.js +59 -63
  69. package/es/class/line.js +135 -141
  70. package/es/class/project.js +90 -96
  71. package/es/class/vertex.js +29 -33
  72. package/es/components/content.js +19 -26
  73. package/es/components/disclaimer/disclaimer.js +10 -16
  74. package/es/components/export.js +8 -15
  75. package/es/components/style/button.js +23 -29
  76. package/es/components/style/cancel-button.js +7 -12
  77. package/es/components/style/content-container.js +9 -14
  78. package/es/components/style/content-title.js +11 -18
  79. package/es/components/style/delete-button.js +8 -15
  80. package/es/components/style/export.js +30 -48
  81. package/es/components/style/form-block.js +8 -13
  82. package/es/components/style/form-color-input.js +7 -12
  83. package/es/components/style/form-label.js +8 -13
  84. package/es/components/style/form-number-input.js +41 -47
  85. package/es/components/style/form-number-input_2.js +36 -42
  86. package/es/components/style/form-select.js +17 -22
  87. package/es/components/style/form-slider.js +10 -15
  88. package/es/components/style/form-submit-button.js +8 -15
  89. package/es/components/style/form-text-input.js +26 -32
  90. package/es/components/viewer2d/area.js +17 -22
  91. package/es/components/viewer2d/export.js +30 -48
  92. package/es/components/viewer2d/grids/grid-horizontal-streak.js +10 -15
  93. package/es/components/viewer2d/grids/grid-streak.js +10 -15
  94. package/es/components/viewer2d/grids/grid-vertical-streak.js +10 -15
  95. package/es/components/viewer2d/grids/grids.js +10 -17
  96. package/es/components/viewer2d/group.js +15 -22
  97. package/es/components/viewer2d/item.js +61 -68
  98. package/es/components/viewer2d/layer.js +23 -28
  99. package/es/components/viewer2d/line.js +101 -109
  100. package/es/components/viewer2d/ruler.js +22 -27
  101. package/es/components/viewer2d/rulerDist.js +21 -26
  102. package/es/components/viewer2d/rulerX.js +39 -45
  103. package/es/components/viewer2d/rulerY.js +37 -43
  104. package/es/components/viewer2d/scene.js +30 -36
  105. package/es/components/viewer2d/snap.js +13 -20
  106. package/es/components/viewer2d/state.js +18 -25
  107. package/es/components/viewer2d/utils.js +24 -35
  108. package/es/components/viewer2d/vertex.js +8 -15
  109. package/es/components/viewer2d/viewer2d.js +153 -161
  110. package/es/components/viewer3d/camera-controls-module/camera-controls.module.js +17 -21
  111. package/es/components/viewer3d/dcm.js +1 -5
  112. package/es/components/viewer3d/fbm.js +1 -5
  113. package/es/components/viewer3d/front3D.js +12 -19
  114. package/es/components/viewer3d/grid-creator.js +8 -15
  115. package/es/components/viewer3d/grids/grid-horizontal-streak.js +6 -12
  116. package/es/components/viewer3d/grids/grid-streak.js +5 -11
  117. package/es/components/viewer3d/grids/grid-vertical-streak.js +6 -12
  118. package/es/components/viewer3d/libs/first-person-controls.js +2 -7
  119. package/es/components/viewer3d/libs/helvetiker_regular.typeface.js +1 -5
  120. package/es/components/viewer3d/libs/mtl-loader.js +1 -5
  121. package/es/components/viewer3d/libs/obj-loader.js +1 -5
  122. package/es/components/viewer3d/libs/orbit-controls.js +2 -6
  123. package/es/components/viewer3d/libs/pointer-lock-controls.js +2 -6
  124. package/es/components/viewer3d/lrm.js +1 -5
  125. package/es/components/viewer3d/model.js +1 -5
  126. package/es/components/viewer3d/pointer-lock-navigation.js +3 -8
  127. package/es/components/viewer3d/ruler-utils/itemRect.js +18 -23
  128. package/es/components/viewer3d/ruler-utils/layer3D.js +59 -64
  129. package/es/components/viewer3d/ruler-utils/ruler3D.js +39 -44
  130. package/es/components/viewer3d/ruler-utils/scene3D.js +9 -15
  131. package/es/components/viewer3d/ruler-utils/state3D.js +4 -9
  132. package/es/components/viewer3d/scene-creator.js +191 -224
  133. package/es/components/viewer3d/three-memory-cleaner.js +3 -10
  134. package/es/components/viewer3d/viewer3d-first-person.js +40 -44
  135. package/es/components/viewer3d/viewer3d.js +196 -200
  136. package/es/constants.js +349 -356
  137. package/es/index.js +7 -13
  138. package/es/models.js +177 -182
  139. package/es/plugins/SVGLoader.js +48 -51
  140. package/es/plugins/autosave.js +3 -7
  141. package/es/plugins/console-debugger.js +5 -10
  142. package/es/plugins/export.js +8 -15
  143. package/es/plugins/keyboard.js +29 -33
  144. package/es/reducers/areas-reducer.js +7 -11
  145. package/es/reducers/export.js +24 -39
  146. package/es/reducers/groups-reducer.js +31 -35
  147. package/es/reducers/holes-reducer.js +43 -47
  148. package/es/reducers/items-reducer.js +106 -110
  149. package/es/reducers/lines-reducer.js +28 -32
  150. package/es/reducers/project-reducer.js +105 -109
  151. package/es/reducers/reducer.js +16 -21
  152. package/es/reducers/scene-reducer.js +15 -19
  153. package/es/reducers/user-reducer.js +5 -9
  154. package/es/reducers/vertices-reducer.js +11 -15
  155. package/es/reducers/viewer2d-reducer.js +18 -22
  156. package/es/reducers/viewer3d-reducer.js +16 -20
  157. package/es/shared-style.js +10 -14
  158. package/es/styles/export.js +3 -9
  159. package/es/translator/en.js +1 -5
  160. package/es/translator/it.js +1 -5
  161. package/es/translator/ru.js +1 -5
  162. package/es/translator/translator.js +13 -17
  163. package/es/utils/browser.js +2 -7
  164. package/es/utils/convert-units-lite.js +1 -5
  165. package/es/utils/email-validator.js +1 -5
  166. package/es/utils/export.js +15 -32
  167. package/es/utils/geometry.js +181 -276
  168. package/es/utils/get-edges-of-subgraphs.js +2 -7
  169. package/es/utils/graph-cycles.js +8 -9
  170. package/es/utils/graph-inner-cycles.js +10 -16
  171. package/es/utils/graph.js +9 -15
  172. package/es/utils/helper.js +39 -61
  173. package/es/utils/history.js +8 -13
  174. package/es/utils/id-broker.js +8 -13
  175. package/es/utils/logger.js +1 -5
  176. package/es/utils/math.js +5 -10
  177. package/es/utils/molding.js +119 -142
  178. package/es/utils/name-generator.js +7 -11
  179. package/es/utils/objects-utils.js +7 -17
  180. package/es/utils/phone-validator.js +1 -5
  181. package/es/utils/process-black-list.js +3 -8
  182. package/es/utils/react-if.js +6 -10
  183. package/es/utils/snap-scene.js +27 -32
  184. package/es/utils/snap.js +45 -57
  185. package/es/utils/summarizeCart.js +1 -5
  186. package/es/utils/threeCSG.es6.js +13 -20
  187. package/es/version.js +1 -5
  188. package/package.json +1 -1
@@ -1,64 +1,51 @@
1
- "use strict";
2
-
3
- exports.__esModule = true;
4
- exports.beginDraggingLine = beginDraggingLine;
5
- exports.beginDrawingLine = beginDrawingLine;
6
- exports.endDraggingLine = endDraggingLine;
7
- exports.endDrawingLine = endDrawingLine;
8
- exports.selectLine = selectLine;
9
- exports.selectToolDrawingLine = selectToolDrawingLine;
10
- exports.setRelatedLine = setRelatedLine;
11
- exports.stopDrawingLine = stopDrawingLine;
12
- exports.updateDraggingLine = updateDraggingLine;
13
- exports.updateDrawingLine = updateDrawingLine;
14
- var _constants = require("../constants");
15
- function selectLine(layerID, lineID) {
1
+ import { BEGIN_DRAGGING_LINE, BEGIN_DRAWING_LINE, END_DRAGGING_LINE, END_DRAWING_LINE, SELECT_LINE, SELECT_TOOL_DRAWING_LINE, SET_RELATED_LINE, STOP_DRAWING_LINE, UPDATE_DRAGGING_LINE, UPDATE_DRAWING_LINE } from "../constants";
2
+ export function selectLine(layerID, lineID) {
16
3
  return {
17
- type: _constants.SELECT_LINE,
4
+ type: SELECT_LINE,
18
5
  layerID: layerID,
19
6
  lineID: lineID
20
7
  };
21
8
  }
22
- function selectToolDrawingLine(sceneComponentType) {
9
+ export function selectToolDrawingLine(sceneComponentType) {
23
10
  return {
24
- type: _constants.SELECT_TOOL_DRAWING_LINE,
11
+ type: SELECT_TOOL_DRAWING_LINE,
25
12
  sceneComponentType: sceneComponentType
26
13
  };
27
14
  }
28
- function beginDrawingLine(layerID, x, y, snapMask) {
15
+ export function beginDrawingLine(layerID, x, y, snapMask) {
29
16
  return {
30
- type: _constants.BEGIN_DRAWING_LINE,
17
+ type: BEGIN_DRAWING_LINE,
31
18
  layerID: layerID,
32
19
  x: x,
33
20
  y: y,
34
21
  snapMask: snapMask
35
22
  };
36
23
  }
37
- function updateDrawingLine(x, y, relatedLines, snapMask) {
24
+ export function updateDrawingLine(x, y, relatedLines, snapMask) {
38
25
  return {
39
- type: _constants.UPDATE_DRAWING_LINE,
26
+ type: UPDATE_DRAWING_LINE,
40
27
  x: x,
41
28
  y: y,
42
29
  relatedLines: relatedLines,
43
30
  snapMask: snapMask
44
31
  };
45
32
  }
46
- function stopDrawingLine() {
33
+ export function stopDrawingLine() {
47
34
  return {
48
- type: _constants.STOP_DRAWING_LINE
35
+ type: STOP_DRAWING_LINE
49
36
  };
50
37
  }
51
- function endDrawingLine(x, y, snapMask) {
38
+ export function endDrawingLine(x, y, snapMask) {
52
39
  return {
53
- type: _constants.END_DRAWING_LINE,
40
+ type: END_DRAWING_LINE,
54
41
  x: x,
55
42
  y: y,
56
43
  snapMask: snapMask
57
44
  };
58
45
  }
59
- function beginDraggingLine(layerID, lineID, x, y, snapMask) {
46
+ export function beginDraggingLine(layerID, lineID, x, y, snapMask) {
60
47
  return {
61
- type: _constants.BEGIN_DRAGGING_LINE,
48
+ type: BEGIN_DRAGGING_LINE,
62
49
  layerID: layerID,
63
50
  lineID: lineID,
64
51
  x: x,
@@ -66,27 +53,27 @@ function beginDraggingLine(layerID, lineID, x, y, snapMask) {
66
53
  snapMask: snapMask
67
54
  };
68
55
  }
69
- function updateDraggingLine(x, y, relatedLines, snapMask) {
56
+ export function updateDraggingLine(x, y, relatedLines, snapMask) {
70
57
  return {
71
- type: _constants.UPDATE_DRAGGING_LINE,
58
+ type: UPDATE_DRAGGING_LINE,
72
59
  x: x,
73
60
  y: y,
74
61
  relatedLines: relatedLines,
75
62
  snapMask: snapMask
76
63
  };
77
64
  }
78
- function endDraggingLine(x, y, relatedLines, snapMask) {
65
+ export function endDraggingLine(x, y, relatedLines, snapMask) {
79
66
  return {
80
- type: _constants.END_DRAGGING_LINE,
67
+ type: END_DRAGGING_LINE,
81
68
  x: x,
82
69
  y: y,
83
70
  relatedLines: relatedLines,
84
71
  snapMask: snapMask
85
72
  };
86
73
  }
87
- function setRelatedLine(layerID, lineID, intersection) {
74
+ export function setRelatedLine(layerID, lineID, intersection) {
88
75
  return {
89
- type: _constants.SET_RELATED_LINE,
76
+ type: SET_RELATED_LINE,
90
77
  layerID: layerID,
91
78
  lineID: lineID,
92
79
  intersection: intersection
@@ -1,130 +1,81 @@
1
- "use strict";
2
-
3
- exports.__esModule = true;
4
- exports.addCircularGuide = addCircularGuide;
5
- exports.addHorizontalGuide = addHorizontalGuide;
6
- exports.addVerticalGuide = addVerticalGuide;
7
- exports.changeCatalogPage = changeCatalogPage;
8
- exports.copyProperties = copyProperties;
9
- exports.goBackToCatalogPage = goBackToCatalogPage;
10
- exports.initCatalog = initCatalog;
11
- exports.loadProject = loadProject;
12
- exports.newProject = newProject;
13
- exports.openCatalog = openCatalog;
14
- exports.openProjectConfigurator = openProjectConfigurator;
15
- exports.pasteProperties = pasteProperties;
16
- exports.pushLastSelectedCatalogElementToHistory = pushLastSelectedCatalogElementToHistory;
17
- exports.recreate = recreate;
18
- exports.redo = redo;
19
- exports.remove = remove;
20
- exports.removeCircularGuide = removeCircularGuide;
21
- exports.removeDrawingSupport = removeDrawingSupport;
22
- exports.removeHorizontalGuide = removeHorizontalGuide;
23
- exports.removeVerticalGuide = removeVerticalGuide;
24
- exports.rename = rename;
25
- exports.rollback = rollback;
26
- exports.saveProject = saveProject;
27
- exports.selectAll = selectAll;
28
- exports.selectToolEdit = selectToolEdit;
29
- exports.setAlterateState = setAlterateState;
30
- exports.setHolesAttributes = setHolesAttributes;
31
- exports.setIsCabinetDrawing = setIsCabinetDrawing;
32
- exports.setIsHelp = setIsHelp;
33
- exports.setItemsAttributes = setItemsAttributes;
34
- exports.setLinesAttributes = setLinesAttributes;
35
- exports.setMode = setMode;
36
- exports.setProjectID = setProjectID;
37
- exports.setProjectProperties = setProjectProperties;
38
- exports.setProperties = setProperties;
39
- exports.setStateProperties = setStateProperties;
40
- exports.shift2doff = shift2doff;
41
- exports.shift2don = shift2don;
42
- exports.throwError = throwError;
43
- exports.throwWarning = throwWarning;
44
- exports.toggleSnap = toggleSnap;
45
- exports.uncreate = uncreate;
46
- exports.undo = undo;
47
- exports.unselectAll = unselectAll;
48
- exports.updateMouseCoord = updateMouseCoord;
49
- exports.updateZoomScale = updateZoomScale;
50
- var _constants = require("../constants");
51
- function setIsHelp(isHelp) {
52
- return {
53
- type: _constants.SET_IS_HELP,
1
+ import { ADD_CIRCULAR_GUIDE, ADD_HORIZONTAL_GUIDE, ADD_VERTICAL_GUIDE, ALTERATE_STATE, CHANGE_CATALOG_PAGE, COPY_PROPERTIES, GO_BACK_TO_CATALOG_PAGE, INIT_CATALOG, LOAD_PROJECT, NEW_PROJECT, OPEN_CATALOG, OPEN_PROJECT_CONFIGURATOR, PASTE_PROPERTIES, PROJECT_RE_NAME, PUSH_LAST_SELECTED_CATALOG_ELEMENT_TO_HISTORY, RECREATE, REDO, REMOVE, REMOVE_CIRCULAR_GUIDE, REMOVE_DRAWING_SUPPORT, REMOVE_HORIZONTAL_GUIDE, REMOVE_VERTICAL_GUIDE, ROLLBACK, SAVE_PROJECT, SELECT_ALL, SELECT_TOOL_EDIT, SET_HOLES_ATTRIBUTES, SET_IS_CABINET_DRAWING, SET_IS_HELP, SET_ITEMS_ATTRIBUTES, SET_LINES_ATTRIBUTES, SET_MODE, SET_PROJECT_ID, SET_PROJECT_PROPERTIES, SET_PROPERTIES, SET_STATE_PROPERTIES, SHIFT2DOFF, SHIFT2DON, THROW_ERROR, THROW_WARNING, TOGGLE_SNAP, UNCREATE, UNDO, UNSELECT_ALL, UPDATE_MOUSE_COORDS, UPDATE_ZOOM_SCALE } from "../constants";
2
+ export function setIsHelp(isHelp) {
3
+ return {
4
+ type: SET_IS_HELP,
54
5
  isHelp: isHelp
55
6
  };
56
7
  }
57
- function setIsCabinetDrawing(isCabinetDrawing) {
8
+ export function setIsCabinetDrawing(isCabinetDrawing) {
58
9
  return {
59
- type: _constants.SET_IS_CABINET_DRAWING,
10
+ type: SET_IS_CABINET_DRAWING,
60
11
  isCabinetDrawing: isCabinetDrawing
61
12
  };
62
13
  }
63
- function setStateProperties(properties) {
14
+ export function setStateProperties(properties) {
64
15
  return {
65
- type: _constants.SET_STATE_PROPERTIES,
16
+ type: SET_STATE_PROPERTIES,
66
17
  properties: properties
67
18
  };
68
19
  }
69
- function loadProject(sceneJSON, categoryData) {
20
+ export function loadProject(sceneJSON, categoryData) {
70
21
  return {
71
- type: _constants.LOAD_PROJECT,
22
+ type: LOAD_PROJECT,
72
23
  sceneJSON: sceneJSON,
73
24
  categoryData: categoryData
74
25
  };
75
26
  }
76
- function newProject() {
27
+ export function newProject() {
77
28
  return {
78
- type: _constants.NEW_PROJECT
29
+ type: NEW_PROJECT
79
30
  };
80
31
  }
81
- function saveProject() {
32
+ export function saveProject() {
82
33
  return {
83
- type: _constants.SAVE_PROJECT
34
+ type: SAVE_PROJECT
84
35
  };
85
36
  }
86
- function openCatalog() {
37
+ export function openCatalog() {
87
38
  return {
88
- type: _constants.OPEN_CATALOG
39
+ type: OPEN_CATALOG
89
40
  };
90
41
  }
91
- function changeCatalogPage(newPage, oldPage) {
42
+ export function changeCatalogPage(newPage, oldPage) {
92
43
  return {
93
- type: _constants.CHANGE_CATALOG_PAGE,
44
+ type: CHANGE_CATALOG_PAGE,
94
45
  newPage: newPage,
95
46
  oldPage: oldPage
96
47
  };
97
48
  }
98
- function goBackToCatalogPage(newPage) {
49
+ export function goBackToCatalogPage(newPage) {
99
50
  return {
100
- type: _constants.GO_BACK_TO_CATALOG_PAGE,
51
+ type: GO_BACK_TO_CATALOG_PAGE,
101
52
  newPage: newPage
102
53
  };
103
54
  }
104
- function selectToolEdit() {
55
+ export function selectToolEdit() {
105
56
  return {
106
- type: _constants.SELECT_TOOL_EDIT
57
+ type: SELECT_TOOL_EDIT
107
58
  };
108
59
  }
109
- function unselectAll() {
60
+ export function unselectAll() {
110
61
  return {
111
- type: _constants.UNSELECT_ALL
62
+ type: UNSELECT_ALL
112
63
  };
113
64
  }
114
- function setProperties(properties) {
65
+ export function setProperties(properties) {
115
66
  return {
116
- type: _constants.SET_PROPERTIES,
67
+ type: SET_PROPERTIES,
117
68
  properties: properties
118
69
  };
119
70
  }
120
- function setItemsAttributes(itemsAttributes) {
71
+ export function setItemsAttributes(itemsAttributes) {
121
72
  itemsAttributes = itemsAttributes.set('rotation', parseFloat(itemsAttributes.get('rotation')));
122
73
  return {
123
- type: _constants.SET_ITEMS_ATTRIBUTES,
74
+ type: SET_ITEMS_ATTRIBUTES,
124
75
  itemsAttributes: itemsAttributes
125
76
  };
126
77
  }
127
- function setLinesAttributes(linesAttributes) {
78
+ export function setLinesAttributes(linesAttributes) {
128
79
  var isDirect = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
129
80
  var directData = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;
130
81
  linesAttributes = linesAttributes.withMutations(function (attributes) {
@@ -134,197 +85,197 @@ function setLinesAttributes(linesAttributes) {
134
85
  attributes.setIn(['vertexTwo', 'y'], parseFloat(linesAttributes.getIn(['vertexTwo', 'y'])));
135
86
  });
136
87
  return {
137
- type: _constants.SET_LINES_ATTRIBUTES,
88
+ type: SET_LINES_ATTRIBUTES,
138
89
  linesAttributes: linesAttributes,
139
90
  isDirect: isDirect,
140
91
  directData: directData
141
92
  };
142
93
  }
143
- function setHolesAttributes(holesAttributes) {
94
+ export function setHolesAttributes(holesAttributes) {
144
95
  holesAttributes = holesAttributes.set('offset', parseFloat(holesAttributes.get('offset')));
145
96
  return {
146
- type: _constants.SET_HOLES_ATTRIBUTES,
97
+ type: SET_HOLES_ATTRIBUTES,
147
98
  holesAttributes: holesAttributes
148
99
  };
149
100
  }
150
- function remove() {
101
+ export function remove() {
151
102
  return {
152
- type: _constants.REMOVE
103
+ type: REMOVE
153
104
  };
154
105
  }
155
- function undo() {
106
+ export function undo() {
156
107
  return {
157
- type: _constants.UNDO
108
+ type: UNDO
158
109
  };
159
110
  }
160
- function redo() {
111
+ export function redo() {
161
112
  return {
162
- type: _constants.REDO
113
+ type: REDO
163
114
  };
164
115
  }
165
- function uncreate() {
116
+ export function uncreate() {
166
117
  return {
167
- type: _constants.UNCREATE
118
+ type: UNCREATE
168
119
  };
169
120
  }
170
- function rename(name) {
121
+ export function rename(name) {
171
122
  return {
172
- type: _constants.PROJECT_RE_NAME,
123
+ type: PROJECT_RE_NAME,
173
124
  name: name
174
125
  };
175
126
  }
176
- function recreate() {
127
+ export function recreate() {
177
128
  return {
178
- type: _constants.RECREATE
129
+ type: RECREATE
179
130
  };
180
131
  }
181
- function shift2doff() {
132
+ export function shift2doff() {
182
133
  return {
183
- type: _constants.SHIFT2DOFF
134
+ type: SHIFT2DOFF
184
135
  };
185
136
  }
186
- function shift2don() {
137
+ export function shift2don() {
187
138
  return {
188
- type: _constants.SHIFT2DON
139
+ type: SHIFT2DON
189
140
  };
190
141
  }
191
- function rollback() {
142
+ export function rollback() {
192
143
  return {
193
- type: _constants.ROLLBACK
144
+ type: ROLLBACK
194
145
  };
195
146
  }
196
- function openProjectConfigurator() {
147
+ export function openProjectConfigurator() {
197
148
  return {
198
- type: _constants.OPEN_PROJECT_CONFIGURATOR
149
+ type: OPEN_PROJECT_CONFIGURATOR
199
150
  };
200
151
  }
201
- function setProjectProperties(properties) {
152
+ export function setProjectProperties(properties) {
202
153
  return {
203
- type: _constants.SET_PROJECT_PROPERTIES,
154
+ type: SET_PROJECT_PROPERTIES,
204
155
  properties: properties
205
156
  };
206
157
  }
207
- function setProjectID(id) {
158
+ export function setProjectID(id) {
208
159
  return {
209
- type: _constants.SET_PROJECT_ID,
160
+ type: SET_PROJECT_ID,
210
161
  id: id
211
162
  };
212
163
  }
213
- function initCatalog(catalog) {
164
+ export function initCatalog(catalog) {
214
165
  return {
215
- type: _constants.INIT_CATALOG,
166
+ type: INIT_CATALOG,
216
167
  catalog: catalog
217
168
  };
218
169
  }
219
- function updateMouseCoord() {
170
+ export function updateMouseCoord() {
220
171
  var coords = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {
221
172
  x: x,
222
173
  y: y
223
174
  };
224
175
  return {
225
- type: _constants.UPDATE_MOUSE_COORDS,
176
+ type: UPDATE_MOUSE_COORDS,
226
177
  coords: coords
227
178
  };
228
179
  }
229
- function updateZoomScale(scale) {
180
+ export function updateZoomScale(scale) {
230
181
  return {
231
- type: _constants.UPDATE_ZOOM_SCALE,
182
+ type: UPDATE_ZOOM_SCALE,
232
183
  scale: scale
233
184
  };
234
185
  }
235
- function toggleSnap(mask) {
186
+ export function toggleSnap(mask) {
236
187
  return {
237
- type: _constants.TOGGLE_SNAP,
188
+ type: TOGGLE_SNAP,
238
189
  mask: mask
239
190
  };
240
191
  }
241
- function throwError(error) {
192
+ export function throwError(error) {
242
193
  return {
243
- type: _constants.THROW_ERROR,
194
+ type: THROW_ERROR,
244
195
  error: error
245
196
  };
246
197
  }
247
- function throwWarning(warning) {
198
+ export function throwWarning(warning) {
248
199
  return {
249
- type: _constants.THROW_WARNING,
200
+ type: THROW_WARNING,
250
201
  warning: warning
251
202
  };
252
203
  }
253
- function copyProperties(properties) {
204
+ export function copyProperties(properties) {
254
205
  return {
255
- type: _constants.COPY_PROPERTIES,
206
+ type: COPY_PROPERTIES,
256
207
  properties: properties
257
208
  };
258
209
  }
259
- function pasteProperties() {
210
+ export function pasteProperties() {
260
211
  return {
261
- type: _constants.PASTE_PROPERTIES
212
+ type: PASTE_PROPERTIES
262
213
  };
263
214
  }
264
- function pushLastSelectedCatalogElementToHistory(element) {
215
+ export function pushLastSelectedCatalogElementToHistory(element) {
265
216
  return {
266
- type: _constants.PUSH_LAST_SELECTED_CATALOG_ELEMENT_TO_HISTORY,
217
+ type: PUSH_LAST_SELECTED_CATALOG_ELEMENT_TO_HISTORY,
267
218
  element: element
268
219
  };
269
220
  }
270
- function setAlterateState() {
221
+ export function setAlterateState() {
271
222
  return {
272
- type: _constants.ALTERATE_STATE
223
+ type: ALTERATE_STATE
273
224
  };
274
225
  }
275
- function setMode(mode) {
226
+ export function setMode(mode) {
276
227
  return {
277
- type: _constants.SET_MODE,
228
+ type: SET_MODE,
278
229
  mode: mode
279
230
  };
280
231
  }
281
- function addHorizontalGuide(coordinate) {
232
+ export function addHorizontalGuide(coordinate) {
282
233
  return {
283
- type: _constants.ADD_HORIZONTAL_GUIDE,
234
+ type: ADD_HORIZONTAL_GUIDE,
284
235
  coordinate: coordinate
285
236
  };
286
237
  }
287
- function addVerticalGuide(coordinate) {
238
+ export function addVerticalGuide(coordinate) {
288
239
  return {
289
- type: _constants.ADD_VERTICAL_GUIDE,
240
+ type: ADD_VERTICAL_GUIDE,
290
241
  coordinate: coordinate
291
242
  };
292
243
  }
293
- function addCircularGuide(x, y, radius) {
244
+ export function addCircularGuide(x, y, radius) {
294
245
  return {
295
- type: _constants.ADD_CIRCULAR_GUIDE,
246
+ type: ADD_CIRCULAR_GUIDE,
296
247
  x: x,
297
248
  y: y,
298
249
  radius: radius
299
250
  };
300
251
  }
301
- function removeHorizontalGuide(guideID) {
252
+ export function removeHorizontalGuide(guideID) {
302
253
  return {
303
- type: _constants.REMOVE_HORIZONTAL_GUIDE,
254
+ type: REMOVE_HORIZONTAL_GUIDE,
304
255
  guideID: guideID
305
256
  };
306
257
  }
307
- function removeVerticalGuide(guideID) {
258
+ export function removeVerticalGuide(guideID) {
308
259
  return {
309
- type: _constants.REMOVE_VERTICAL_GUIDE,
260
+ type: REMOVE_VERTICAL_GUIDE,
310
261
  guideID: guideID
311
262
  };
312
263
  }
313
- function removeCircularGuide(guideID) {
264
+ export function removeCircularGuide(guideID) {
314
265
  return {
315
- type: _constants.REMOVE_CIRCULAR_GUIDE,
266
+ type: REMOVE_CIRCULAR_GUIDE,
316
267
  guideID: guideID
317
268
  };
318
269
  }
319
- function removeDrawingSupport() {
270
+ export function removeDrawingSupport() {
320
271
  return {
321
- type: _constants.REMOVE_DRAWING_SUPPORT
272
+ type: REMOVE_DRAWING_SUPPORT
322
273
  };
323
274
  }
324
- function selectAll() {
275
+ export function selectAll() {
325
276
  var value = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null;
326
277
  return {
327
- type: _constants.SELECT_ALL,
278
+ type: SELECT_ALL,
328
279
  value: value
329
280
  };
330
281
  }
@@ -1,41 +1,33 @@
1
- "use strict";
2
-
3
- exports.__esModule = true;
4
- exports.addLayer = addLayer;
5
- exports.removeLayer = removeLayer;
6
- exports.selectLayer = selectLayer;
7
- exports.setLayerProperties = setLayerProperties;
8
- exports.updateMovingState = updateMovingState;
9
- var _constants = require("../constants");
10
- function selectLayer(layerID) {
1
+ import { ADD_LAYER, REMOVE_LAYER, SELECT_LAYER, SET_LAYER_PROPERTIES, UPDATE_MOVING_STATE } from "../constants";
2
+ export function selectLayer(layerID) {
11
3
  return {
12
- type: _constants.SELECT_LAYER,
4
+ type: SELECT_LAYER,
13
5
  layerID: layerID
14
6
  };
15
7
  }
16
- function addLayer(name, altitude) {
8
+ export function addLayer(name, altitude) {
17
9
  return {
18
- type: _constants.ADD_LAYER,
10
+ type: ADD_LAYER,
19
11
  name: name,
20
12
  altitude: altitude
21
13
  };
22
14
  }
23
- function setLayerProperties(layerID, properties) {
15
+ export function setLayerProperties(layerID, properties) {
24
16
  return {
25
- type: _constants.SET_LAYER_PROPERTIES,
17
+ type: SET_LAYER_PROPERTIES,
26
18
  layerID: layerID,
27
19
  properties: properties
28
20
  };
29
21
  }
30
- function removeLayer(layerID) {
22
+ export function removeLayer(layerID) {
31
23
  return {
32
- type: _constants.REMOVE_LAYER,
24
+ type: REMOVE_LAYER,
33
25
  layerID: layerID
34
26
  };
35
27
  }
36
- function updateMovingState(showflag) {
28
+ export function updateMovingState(showflag) {
37
29
  return {
38
- type: _constants.UPDATE_MOVING_STATE,
30
+ type: UPDATE_MOVING_STATE,
39
31
  showflag: showflag
40
32
  };
41
33
  }
@@ -1,13 +1,7 @@
1
- "use strict";
2
-
3
- exports.__esModule = true;
4
- exports.beginDraggingVertex = beginDraggingVertex;
5
- exports.endDraggingVertex = endDraggingVertex;
6
- exports.updateDraggingVertex = updateDraggingVertex;
7
- var _constants = require("../constants");
8
- function beginDraggingVertex(layerID, vertexID, x, y, snapMask) {
1
+ import { BEGIN_DRAGGING_VERTEX, END_DRAGGING_VERTEX, UPDATE_DRAGGING_VERTEX } from "../constants";
2
+ export function beginDraggingVertex(layerID, vertexID, x, y, snapMask) {
9
3
  return {
10
- type: _constants.BEGIN_DRAGGING_VERTEX,
4
+ type: BEGIN_DRAGGING_VERTEX,
11
5
  layerID: layerID,
12
6
  vertexID: vertexID,
13
7
  x: x,
@@ -15,17 +9,17 @@ function beginDraggingVertex(layerID, vertexID, x, y, snapMask) {
15
9
  snapMask: snapMask
16
10
  };
17
11
  }
18
- function updateDraggingVertex(x, y, snapMask) {
12
+ export function updateDraggingVertex(x, y, snapMask) {
19
13
  return {
20
- type: _constants.UPDATE_DRAGGING_VERTEX,
14
+ type: UPDATE_DRAGGING_VERTEX,
21
15
  x: x,
22
16
  y: y,
23
17
  snapMask: snapMask
24
18
  };
25
19
  }
26
- function endDraggingVertex(x, y, snapMask) {
20
+ export function endDraggingVertex(x, y, snapMask) {
27
21
  return {
28
- type: _constants.END_DRAGGING_VERTEX,
22
+ type: END_DRAGGING_VERTEX,
29
23
  x: x,
30
24
  y: y,
31
25
  snapMask: snapMask