kitchen-simulator 1.1.1-test.49 → 1.1.1-test.50
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.
- package/es/@history.js +2 -0
- package/es/AppContext.js +3 -0
- package/es/KitchenConfigurator.js +645 -0
- package/es/KitchenConfiguratorApp.js +480 -0
- package/es/actions/area-actions.js +14 -0
- package/es/actions/export.js +23 -0
- package/es/actions/groups-actions.js +89 -0
- package/es/actions/holes-actions.js +119 -0
- package/es/actions/items-actions.js +313 -0
- package/es/actions/lines-actions.js +81 -0
- package/es/actions/project-actions.js +281 -0
- package/es/actions/scene-actions.js +33 -0
- package/es/actions/vertices-actions.js +27 -0
- package/es/actions/viewer2d-actions.js +58 -0
- package/es/actions/viewer3d-actions.js +23 -0
- package/es/catalog/areas/area/planner-element.js +40 -0
- package/es/catalog/areas/area/textures/ceramic-tile.jpg +0 -0
- package/es/catalog/areas/area/textures/grass.jpg +0 -0
- package/es/catalog/areas/area/textures/parquet.jpg +0 -0
- package/es/catalog/areas/area/textures/strand-porcelain.jpg +0 -0
- package/es/catalog/areas/area/textures/tile1.jpg +0 -0
- package/es/catalog/catalog.js +277 -0
- package/es/catalog/envMap/nx.hdr +0 -0
- package/es/catalog/envMap/ny.hdr +0 -0
- package/es/catalog/envMap/nz.hdr +0 -0
- package/es/catalog/envMap/px.hdr +0 -0
- package/es/catalog/envMap/py.hdr +0 -0
- package/es/catalog/envMap/pz.hdr +0 -0
- package/es/catalog/factories/area-factory-3d.js +181 -0
- package/es/catalog/factories/area-factory.js +81 -0
- package/es/catalog/factories/export.js +7 -0
- package/es/catalog/factories/wall-factory-3d.js +202 -0
- package/es/catalog/factories/wall-factory.js +268 -0
- package/es/catalog/holes/door-closet/planner-element.js +222 -0
- package/es/catalog/holes/door-double/door_double.png +0 -0
- package/es/catalog/holes/door-double/planner-element.js +315 -0
- package/es/catalog/holes/door-exterior/planner-element.js +215 -0
- package/es/catalog/holes/door-interior/planner-element.js +227 -0
- package/es/catalog/holes/door-panic/panicDoor.png +0 -0
- package/es/catalog/holes/door-panic/planner-element.js +503 -0
- package/es/catalog/holes/door-panic-double/panicDoorDouble.png +0 -0
- package/es/catalog/holes/door-panic-double/planner-element.js +463 -0
- package/es/catalog/holes/door-sliding/planner-element.js +225 -0
- package/es/catalog/holes/doorway-framed/planner-element.js +145 -0
- package/es/catalog/holes/doorway-frameless/planner-element.js +104 -0
- package/es/catalog/holes/export.js +13 -0
- package/es/catalog/holes/gate/gate.jpg +0 -0
- package/es/catalog/holes/window-clear/planner-element.js +166 -0
- package/es/catalog/holes/window-clear/texture.png +0 -0
- package/es/catalog/holes/window-cross/planner-element.js +165 -0
- package/es/catalog/holes/window-cross/texture.png +0 -0
- package/es/catalog/holes/window-double-hung/planner-element.js +303 -0
- package/es/catalog/holes/window-double-hung/texture.png +0 -0
- package/es/catalog/holes/window-vertical/planner-element.js +276 -0
- package/es/catalog/holes/window-vertical/texture.png +0 -0
- package/es/catalog/lines/wall/planner-element.js +70 -0
- package/es/catalog/lines/wall/textures/bricks-normal.jpg +0 -0
- package/es/catalog/lines/wall/textures/bricks-normal2.jpg +0 -0
- package/es/catalog/lines/wall/textures/bricks.jpg +0 -0
- package/es/catalog/lines/wall/textures/bricks2.jpg +0 -0
- package/es/catalog/lines/wall/textures/bricks3.jpg +0 -0
- package/es/catalog/lines/wall/textures/morden-normal.jpg +0 -0
- package/es/catalog/lines/wall/textures/morden.jpg +0 -0
- package/es/catalog/lines/wall/textures/painted-normal.jpg +0 -0
- package/es/catalog/lines/wall/textures/painted.jpg +0 -0
- package/es/catalog/lines/wall/textures/plaster-normal.jpg +0 -0
- package/es/catalog/lines/wall/textures/plaster.jpg +0 -0
- package/es/catalog/lines/wall/wall.png +0 -0
- package/es/catalog/molding/molding-dcm/planner-element.js +28 -0
- package/es/catalog/molding/molding-dcm/texture.png +0 -0
- package/es/catalog/molding/molding-fbm/planner-element.js +28 -0
- package/es/catalog/molding/molding-fbm/texture.png +0 -0
- package/es/catalog/molding/molding-lrm/planner-element.js +28 -0
- package/es/catalog/molding/molding-lrm/texture.png +0 -0
- package/es/catalog/properties/export.js +21 -0
- package/es/catalog/properties/property-checkbox.js +116 -0
- package/es/catalog/properties/property-color.js +39 -0
- package/es/catalog/properties/property-enum.js +97 -0
- package/es/catalog/properties/property-hidden.js +19 -0
- package/es/catalog/properties/property-lenght-measure.js +101 -0
- package/es/catalog/properties/property-length-measure.js +134 -0
- package/es/catalog/properties/property-length-measure_hole.js +101 -0
- package/es/catalog/properties/property-number.js +48 -0
- package/es/catalog/properties/property-read-only.js +26 -0
- package/es/catalog/properties/property-string.js +48 -0
- package/es/catalog/properties/property-toggle.js +39 -0
- package/es/catalog/properties/shared-property-style.js +14 -0
- package/es/catalog/utils/FuseUtils.js +82 -0
- package/es/catalog/utils/exporter.js +148 -0
- package/es/catalog/utils/geom-utils.js +189 -0
- package/es/catalog/utils/item-loader.js +1521 -0
- package/es/catalog/utils/load-obj.js +91 -0
- package/es/catalog/utils/mtl-loader.js +358 -0
- package/es/catalog/utils/obj-loader.js +477 -0
- package/es/class/FuseUtils.js +82 -0
- package/es/class/area.js +145 -0
- package/es/class/export.js +24 -0
- package/es/class/group.js +440 -0
- package/es/class/guide.js +62 -0
- package/es/class/hole.js +929 -0
- package/es/class/item.js +1883 -0
- package/es/class/layer.js +667 -0
- package/es/class/line.js +1180 -0
- package/es/class/project.js +793 -0
- package/es/class/vertex.js +202 -0
- package/es/components/content.js +107 -0
- package/es/components/disclaimer/disclaimer.js +97 -0
- package/es/components/export.js +9 -0
- package/es/components/style/button.js +113 -0
- package/es/components/style/cancel-button.js +22 -0
- package/es/components/style/content-container.js +33 -0
- package/es/components/style/content-title.js +29 -0
- package/es/components/style/delete-button.js +25 -0
- package/es/components/style/export.js +31 -0
- package/es/components/style/form-block.js +24 -0
- package/es/components/style/form-color-input.js +27 -0
- package/es/components/style/form-label.js +26 -0
- package/es/components/style/form-number-input.js +213 -0
- package/es/components/style/form-number-input_2.js +206 -0
- package/es/components/style/form-select.js +68 -0
- package/es/components/style/form-slider.js +61 -0
- package/es/components/style/form-submit-button.js +26 -0
- package/es/components/style/form-text-input.js +95 -0
- package/es/components/viewer2d/area.js +81 -0
- package/es/components/viewer2d/export.js +31 -0
- package/es/components/viewer2d/grids/grid-horizontal-streak.js +37 -0
- package/es/components/viewer2d/grids/grid-streak.js +37 -0
- package/es/components/viewer2d/grids/grid-vertical-streak.js +37 -0
- package/es/components/viewer2d/grids/grids.js +35 -0
- package/es/components/viewer2d/group.js +53 -0
- package/es/components/viewer2d/item.js +513 -0
- package/es/components/viewer2d/layer.js +164 -0
- package/es/components/viewer2d/line.js +882 -0
- package/es/components/viewer2d/ruler.js +100 -0
- package/es/components/viewer2d/rulerDist.js +146 -0
- package/es/components/viewer2d/rulerX.js +151 -0
- package/es/components/viewer2d/rulerY.js +153 -0
- package/es/components/viewer2d/scene.js +140 -0
- package/es/components/viewer2d/snap.js +74 -0
- package/es/components/viewer2d/state.js +78 -0
- package/es/components/viewer2d/utils.js +198 -0
- package/es/components/viewer2d/vertex.js +65 -0
- package/es/components/viewer2d/viewer2d.js +1398 -0
- package/es/components/viewer3d/camera-controls-module/camera-controls.module.js +2592 -0
- package/es/components/viewer3d/dcm.js +401 -0
- package/es/components/viewer3d/fbm.js +414 -0
- package/es/components/viewer3d/front3D.js +66 -0
- package/es/components/viewer3d/grid-creator.js +25 -0
- package/es/components/viewer3d/grids/grid-horizontal-streak.js +36 -0
- package/es/components/viewer3d/grids/grid-streak.js +27 -0
- package/es/components/viewer3d/grids/grid-vertical-streak.js +36 -0
- package/es/components/viewer3d/libs/first-person-controls.js +67 -0
- package/es/components/viewer3d/libs/helvetiker_regular.typeface.js +1281 -0
- package/es/components/viewer3d/libs/mtl-loader.js +357 -0
- package/es/components/viewer3d/libs/obj-loader.js +462 -0
- package/es/components/viewer3d/libs/orbit-controls.js +699 -0
- package/es/components/viewer3d/libs/pointer-lock-controls.js +46 -0
- package/es/components/viewer3d/lrm.js +305 -0
- package/es/components/viewer3d/model.js +708 -0
- package/es/components/viewer3d/pointer-lock-navigation.js +115 -0
- package/es/components/viewer3d/ruler-utils/itemRect.js +61 -0
- package/es/components/viewer3d/ruler-utils/layer3D.js +495 -0
- package/es/components/viewer3d/ruler-utils/ruler3D.js +227 -0
- package/es/components/viewer3d/ruler-utils/scene3D.js +60 -0
- package/es/components/viewer3d/ruler-utils/state3D.js +18 -0
- package/es/components/viewer3d/scene-creator.js +3608 -0
- package/es/components/viewer3d/three-memory-cleaner.js +51 -0
- package/es/components/viewer3d/viewer3d-first-person.js +315 -0
- package/es/components/viewer3d/viewer3d.js +2527 -0
- package/es/constants.js +636 -0
- package/es/index.js +16 -0
- package/es/models.js +510 -0
- package/es/plugins/SVGLoader.js +1412 -0
- package/es/plugins/autosave.js +33 -0
- package/es/plugins/console-debugger.js +37 -0
- package/es/plugins/export.js +9 -0
- package/es/plugins/keyboard.js +101 -0
- package/es/reducers/areas-reducer.js +12 -0
- package/es/reducers/export.js +25 -0
- package/es/reducers/groups-reducer.js +38 -0
- package/es/reducers/holes-reducer.js +62 -0
- package/es/reducers/items-reducer.js +140 -0
- package/es/reducers/lines-reducer.js +45 -0
- package/es/reducers/project-reducer.js +129 -0
- package/es/reducers/reducer.js +19 -0
- package/es/reducers/scene-reducer.js +28 -0
- package/es/reducers/user-reducer.js +40 -0
- package/es/reducers/vertices-reducer.js +19 -0
- package/es/reducers/viewer2d-reducer.js +75 -0
- package/es/reducers/viewer3d-reducer.js +56 -0
- package/es/shared-style.js +66 -0
- package/es/styles/export.js +5 -0
- package/es/styles/tabs.css +40 -0
- package/es/translator/en.js +104 -0
- package/es/translator/it.js +79 -0
- package/es/translator/ru.js +79 -0
- package/es/translator/translator.js +84 -0
- package/es/utils/browser.js +33 -0
- package/es/utils/email-validator.js +4 -0
- package/es/utils/export.js +25 -0
- package/es/utils/geometry.js +2420 -0
- package/es/utils/get-edges-of-subgraphs.js +27 -0
- package/es/utils/graph-cycles.js +237 -0
- package/es/utils/graph-inner-cycles.js +46 -0
- package/es/utils/graph.js +150 -0
- package/es/utils/helper.js +268 -0
- package/es/utils/history.js +29 -0
- package/es/utils/id-broker.js +19 -0
- package/es/utils/logger.js +8 -0
- package/es/utils/math.js +50 -0
- package/es/utils/molding.js +871 -0
- package/es/utils/name-generator.js +18 -0
- package/es/utils/objects-utils.js +50 -0
- package/es/utils/phone-validator.js +4 -0
- package/es/utils/process-black-list.js +18 -0
- package/es/utils/react-if.js +18 -0
- package/es/utils/snap-scene.js +99 -0
- package/es/utils/snap.js +237 -0
- package/es/utils/summarizeCart.js +24 -0
- package/es/utils/threeCSG.es6.js +498 -0
- package/es/version.js +2 -0
- package/lib/catalog/properties/property-string.js +55 -0
- package/lib/catalog/properties/property-toggle.js +46 -0
- package/lib/catalog/properties/shared-property-style.js +20 -0
- package/lib/catalog/utils/FuseUtils.js +88 -0
- package/lib/catalog/utils/exporter.js +155 -0
- package/lib/catalog/utils/geom-utils.js +205 -0
- package/lib/catalog/utils/item-loader.js +1533 -0
- package/lib/catalog/utils/load-obj.js +99 -0
- package/lib/catalog/utils/mtl-loader.js +363 -0
- package/lib/catalog/utils/obj-loader.js +482 -0
- package/lib/class/FuseUtils.js +88 -0
- package/lib/class/area.js +150 -0
- package/lib/class/export.js +96 -0
- package/lib/class/group.js +445 -0
- package/lib/class/guide.js +67 -0
- package/lib/class/hole.js +934 -0
- package/lib/class/item.js +1889 -0
- package/lib/class/layer.js +672 -0
- package/lib/class/line.js +1186 -0
- package/lib/class/project.js +799 -0
- package/lib/class/vertex.js +207 -0
- package/lib/components/content.js +116 -0
- package/lib/components/disclaimer/disclaimer.js +105 -0
- package/lib/components/export.js +33 -0
- package/lib/components/style/button.js +120 -0
- package/lib/components/style/cancel-button.js +29 -0
- package/lib/components/style/content-container.js +40 -0
- package/lib/components/style/content-title.js +37 -0
- package/lib/components/style/delete-button.js +34 -0
- package/lib/components/style/export.js +121 -0
- package/lib/components/style/form-block.js +31 -0
- package/lib/components/style/form-color-input.js +34 -0
- package/lib/components/style/form-label.js +33 -0
- package/lib/components/style/form-number-input.js +220 -0
- package/lib/components/style/form-number-input_2.js +213 -0
- package/lib/components/style/form-select.js +75 -0
- package/lib/components/style/form-slider.js +68 -0
- package/lib/components/style/form-submit-button.js +35 -0
- package/lib/components/style/form-text-input.js +101 -0
- package/lib/components/viewer2d/area.js +88 -0
- package/lib/components/viewer2d/export.js +121 -0
- package/lib/components/viewer2d/grids/grid-horizontal-streak.js +44 -0
- package/lib/components/viewer2d/grids/grid-streak.js +44 -0
- package/lib/components/viewer2d/grids/grid-vertical-streak.js +44 -0
- package/lib/components/viewer2d/grids/grids.js +44 -0
- package/lib/components/viewer2d/group.js +62 -0
- package/lib/components/viewer2d/item.js +521 -0
- package/lib/components/viewer2d/layer.js +171 -0
- package/lib/components/viewer2d/line.js +892 -0
- package/lib/components/viewer2d/ruler.js +107 -0
- package/lib/components/viewer2d/rulerDist.js +153 -0
- package/lib/components/viewer2d/rulerX.js +158 -0
- package/lib/components/viewer2d/rulerY.js +160 -0
- package/lib/components/viewer2d/scene.js +147 -0
- package/lib/components/viewer2d/snap.js +83 -0
- package/lib/components/viewer2d/state.js +87 -0
- package/lib/components/viewer2d/utils.js +210 -0
- package/lib/components/viewer2d/vertex.js +74 -0
- package/lib/components/viewer2d/viewer2d.js +1405 -0
- package/lib/components/viewer3d/camera-controls-module/camera-controls.module.js +2597 -0
- package/lib/components/viewer3d/dcm.js +407 -0
- package/lib/components/viewer3d/fbm.js +420 -0
- package/lib/components/viewer3d/front3D.js +75 -0
- package/lib/components/viewer3d/grid-creator.js +34 -0
- package/lib/components/viewer3d/grids/grid-horizontal-streak.js +44 -0
- package/lib/components/viewer3d/grids/grid-streak.js +35 -0
- package/lib/components/viewer3d/grids/grid-vertical-streak.js +44 -0
- package/lib/components/viewer3d/libs/first-person-controls.js +74 -0
- package/lib/components/viewer3d/libs/helvetiker_regular.typeface.js +1287 -0
- package/lib/components/viewer3d/libs/mtl-loader.js +363 -0
- package/lib/components/viewer3d/libs/obj-loader.js +468 -0
- package/lib/components/viewer3d/libs/orbit-controls.js +705 -0
- package/lib/components/viewer3d/libs/pointer-lock-controls.js +52 -0
- package/lib/components/viewer3d/lrm.js +311 -0
- package/lib/components/viewer3d/model.js +714 -0
- package/lib/components/viewer3d/pointer-lock-navigation.js +122 -0
- package/lib/components/viewer3d/ruler-utils/itemRect.js +68 -0
- package/lib/components/viewer3d/ruler-utils/layer3D.js +502 -0
- package/lib/components/viewer3d/ruler-utils/ruler3D.js +234 -0
- package/lib/components/viewer3d/ruler-utils/scene3D.js +68 -0
- package/lib/components/viewer3d/ruler-utils/state3D.js +25 -0
- package/lib/components/viewer3d/scene-creator.js +3642 -0
- package/lib/components/viewer3d/three-memory-cleaner.js +60 -0
- package/lib/components/viewer3d/viewer3d-first-person.js +320 -0
- package/lib/components/viewer3d/viewer3d.js +2532 -0
- package/lib/constants.js +645 -0
- package/lib/index.js +96 -0
- package/lib/models.js +517 -0
- package/lib/plugins/SVGLoader.js +1417 -0
- package/lib/plugins/autosave.js +39 -0
- package/lib/plugins/console-debugger.js +44 -0
- package/lib/plugins/export.js +33 -0
- package/lib/plugins/keyboard.js +107 -0
- package/lib/reducers/areas-reducer.js +18 -0
- package/lib/reducers/export.js +97 -0
- package/lib/reducers/groups-reducer.js +44 -0
- package/lib/reducers/holes-reducer.js +68 -0
- package/lib/reducers/items-reducer.js +146 -0
- package/lib/reducers/lines-reducer.js +51 -0
- package/lib/reducers/project-reducer.js +135 -0
- package/lib/reducers/reducer.js +26 -0
- package/lib/reducers/scene-reducer.js +34 -0
- package/lib/reducers/user-reducer.js +46 -0
- package/lib/reducers/vertices-reducer.js +25 -0
- package/lib/reducers/viewer2d-reducer.js +82 -0
- package/lib/reducers/viewer3d-reducer.js +63 -0
- package/lib/shared-style.js +72 -0
- package/lib/styles/export.js +13 -0
- package/lib/translator/en.js +110 -0
- package/lib/translator/it.js +85 -0
- package/lib/translator/ru.js +85 -0
- package/lib/translator/translator.js +90 -0
- package/lib/utils/browser.js +40 -0
- package/lib/utils/email-validator.js +10 -0
- package/lib/utils/export.js +56 -0
- package/lib/utils/geometry.js +2516 -0
- package/lib/utils/get-edges-of-subgraphs.js +34 -0
- package/lib/utils/graph-cycles.js +240 -0
- package/lib/utils/graph-inner-cycles.js +54 -0
- package/lib/utils/graph.js +157 -0
- package/lib/utils/helper.js +291 -0
- package/lib/utils/history.js +36 -0
- package/lib/utils/id-broker.js +25 -0
- package/lib/utils/logger.js +14 -0
- package/lib/utils/math.js +57 -0
- package/lib/utils/molding.js +895 -0
- package/lib/utils/name-generator.js +23 -0
- package/lib/utils/objects-utils.js +60 -0
- package/lib/utils/phone-validator.js +10 -0
- package/lib/utils/process-black-list.js +24 -0
- package/lib/utils/react-if.js +24 -0
- package/lib/utils/snap-scene.js +105 -0
- package/lib/utils/snap.js +249 -0
- package/lib/utils/summarizeCart.js +30 -0
- package/lib/utils/threeCSG.es6.js +503 -0
- package/lib/version.js +8 -0
- package/package.json +3 -3
|
@@ -0,0 +1,281 @@
|
|
|
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,
|
|
5
|
+
isHelp: isHelp
|
|
6
|
+
};
|
|
7
|
+
}
|
|
8
|
+
export function setIsCabinetDrawing(isCabinetDrawing) {
|
|
9
|
+
return {
|
|
10
|
+
type: SET_IS_CABINET_DRAWING,
|
|
11
|
+
isCabinetDrawing: isCabinetDrawing
|
|
12
|
+
};
|
|
13
|
+
}
|
|
14
|
+
export function setStateProperties(properties) {
|
|
15
|
+
return {
|
|
16
|
+
type: SET_STATE_PROPERTIES,
|
|
17
|
+
properties: properties
|
|
18
|
+
};
|
|
19
|
+
}
|
|
20
|
+
export function loadProject(sceneJSON, categoryData) {
|
|
21
|
+
return {
|
|
22
|
+
type: LOAD_PROJECT,
|
|
23
|
+
sceneJSON: sceneJSON,
|
|
24
|
+
categoryData: categoryData
|
|
25
|
+
};
|
|
26
|
+
}
|
|
27
|
+
export function newProject() {
|
|
28
|
+
return {
|
|
29
|
+
type: NEW_PROJECT
|
|
30
|
+
};
|
|
31
|
+
}
|
|
32
|
+
export function saveProject() {
|
|
33
|
+
return {
|
|
34
|
+
type: SAVE_PROJECT
|
|
35
|
+
};
|
|
36
|
+
}
|
|
37
|
+
export function openCatalog() {
|
|
38
|
+
return {
|
|
39
|
+
type: OPEN_CATALOG
|
|
40
|
+
};
|
|
41
|
+
}
|
|
42
|
+
export function changeCatalogPage(newPage, oldPage) {
|
|
43
|
+
return {
|
|
44
|
+
type: CHANGE_CATALOG_PAGE,
|
|
45
|
+
newPage: newPage,
|
|
46
|
+
oldPage: oldPage
|
|
47
|
+
};
|
|
48
|
+
}
|
|
49
|
+
export function goBackToCatalogPage(newPage) {
|
|
50
|
+
return {
|
|
51
|
+
type: GO_BACK_TO_CATALOG_PAGE,
|
|
52
|
+
newPage: newPage
|
|
53
|
+
};
|
|
54
|
+
}
|
|
55
|
+
export function selectToolEdit() {
|
|
56
|
+
return {
|
|
57
|
+
type: SELECT_TOOL_EDIT
|
|
58
|
+
};
|
|
59
|
+
}
|
|
60
|
+
export function unselectAll() {
|
|
61
|
+
return {
|
|
62
|
+
type: UNSELECT_ALL
|
|
63
|
+
};
|
|
64
|
+
}
|
|
65
|
+
export function setProperties(properties) {
|
|
66
|
+
return {
|
|
67
|
+
type: SET_PROPERTIES,
|
|
68
|
+
properties: properties
|
|
69
|
+
};
|
|
70
|
+
}
|
|
71
|
+
export function setItemsAttributes(itemsAttributes) {
|
|
72
|
+
itemsAttributes = itemsAttributes.set('rotation', parseFloat(itemsAttributes.get('rotation')));
|
|
73
|
+
return {
|
|
74
|
+
type: SET_ITEMS_ATTRIBUTES,
|
|
75
|
+
itemsAttributes: itemsAttributes
|
|
76
|
+
};
|
|
77
|
+
}
|
|
78
|
+
export function setLinesAttributes(linesAttributes) {
|
|
79
|
+
var isDirect = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
|
|
80
|
+
var directData = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;
|
|
81
|
+
linesAttributes = linesAttributes.withMutations(function (attributes) {
|
|
82
|
+
attributes.setIn(['vertexOne', 'x'], parseFloat(linesAttributes.getIn(['vertexOne', 'x'])));
|
|
83
|
+
attributes.setIn(['vertexOne', 'y'], parseFloat(linesAttributes.getIn(['vertexOne', 'y'])));
|
|
84
|
+
attributes.setIn(['vertexTwo', 'x'], parseFloat(linesAttributes.getIn(['vertexTwo', 'x'])));
|
|
85
|
+
attributes.setIn(['vertexTwo', 'y'], parseFloat(linesAttributes.getIn(['vertexTwo', 'y'])));
|
|
86
|
+
});
|
|
87
|
+
return {
|
|
88
|
+
type: SET_LINES_ATTRIBUTES,
|
|
89
|
+
linesAttributes: linesAttributes,
|
|
90
|
+
isDirect: isDirect,
|
|
91
|
+
directData: directData
|
|
92
|
+
};
|
|
93
|
+
}
|
|
94
|
+
export function setHolesAttributes(holesAttributes) {
|
|
95
|
+
holesAttributes = holesAttributes.set('offset', parseFloat(holesAttributes.get('offset')));
|
|
96
|
+
return {
|
|
97
|
+
type: SET_HOLES_ATTRIBUTES,
|
|
98
|
+
holesAttributes: holesAttributes
|
|
99
|
+
};
|
|
100
|
+
}
|
|
101
|
+
export function remove() {
|
|
102
|
+
return {
|
|
103
|
+
type: REMOVE
|
|
104
|
+
};
|
|
105
|
+
}
|
|
106
|
+
export function undo() {
|
|
107
|
+
return {
|
|
108
|
+
type: UNDO
|
|
109
|
+
};
|
|
110
|
+
}
|
|
111
|
+
export function redo() {
|
|
112
|
+
return {
|
|
113
|
+
type: REDO
|
|
114
|
+
};
|
|
115
|
+
}
|
|
116
|
+
export function uncreate() {
|
|
117
|
+
return {
|
|
118
|
+
type: UNCREATE
|
|
119
|
+
};
|
|
120
|
+
}
|
|
121
|
+
export function rename(name) {
|
|
122
|
+
return {
|
|
123
|
+
type: PROJECT_RE_NAME,
|
|
124
|
+
name: name
|
|
125
|
+
};
|
|
126
|
+
}
|
|
127
|
+
export function recreate() {
|
|
128
|
+
return {
|
|
129
|
+
type: RECREATE
|
|
130
|
+
};
|
|
131
|
+
}
|
|
132
|
+
export function shift2doff() {
|
|
133
|
+
return {
|
|
134
|
+
type: SHIFT2DOFF
|
|
135
|
+
};
|
|
136
|
+
}
|
|
137
|
+
export function shift2don() {
|
|
138
|
+
return {
|
|
139
|
+
type: SHIFT2DON
|
|
140
|
+
};
|
|
141
|
+
}
|
|
142
|
+
export function rollback() {
|
|
143
|
+
return {
|
|
144
|
+
type: ROLLBACK
|
|
145
|
+
};
|
|
146
|
+
}
|
|
147
|
+
export function openProjectConfigurator() {
|
|
148
|
+
return {
|
|
149
|
+
type: OPEN_PROJECT_CONFIGURATOR
|
|
150
|
+
};
|
|
151
|
+
}
|
|
152
|
+
export function setProjectProperties(properties) {
|
|
153
|
+
return {
|
|
154
|
+
type: SET_PROJECT_PROPERTIES,
|
|
155
|
+
properties: properties
|
|
156
|
+
};
|
|
157
|
+
}
|
|
158
|
+
export function setProjectID(id) {
|
|
159
|
+
return {
|
|
160
|
+
type: SET_PROJECT_ID,
|
|
161
|
+
id: id
|
|
162
|
+
};
|
|
163
|
+
}
|
|
164
|
+
export function initCatalog(catalog) {
|
|
165
|
+
return {
|
|
166
|
+
type: INIT_CATALOG,
|
|
167
|
+
catalog: catalog
|
|
168
|
+
};
|
|
169
|
+
}
|
|
170
|
+
export function updateMouseCoord() {
|
|
171
|
+
var coords = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {
|
|
172
|
+
x: x,
|
|
173
|
+
y: y
|
|
174
|
+
};
|
|
175
|
+
return {
|
|
176
|
+
type: UPDATE_MOUSE_COORDS,
|
|
177
|
+
coords: coords
|
|
178
|
+
};
|
|
179
|
+
}
|
|
180
|
+
export function updateZoomScale(scale) {
|
|
181
|
+
return {
|
|
182
|
+
type: UPDATE_ZOOM_SCALE,
|
|
183
|
+
scale: scale
|
|
184
|
+
};
|
|
185
|
+
}
|
|
186
|
+
export function toggleSnap(mask) {
|
|
187
|
+
return {
|
|
188
|
+
type: TOGGLE_SNAP,
|
|
189
|
+
mask: mask
|
|
190
|
+
};
|
|
191
|
+
}
|
|
192
|
+
export function throwError(error) {
|
|
193
|
+
return {
|
|
194
|
+
type: THROW_ERROR,
|
|
195
|
+
error: error
|
|
196
|
+
};
|
|
197
|
+
}
|
|
198
|
+
export function throwWarning(warning) {
|
|
199
|
+
return {
|
|
200
|
+
type: THROW_WARNING,
|
|
201
|
+
warning: warning
|
|
202
|
+
};
|
|
203
|
+
}
|
|
204
|
+
export function copyProperties(properties) {
|
|
205
|
+
return {
|
|
206
|
+
type: COPY_PROPERTIES,
|
|
207
|
+
properties: properties
|
|
208
|
+
};
|
|
209
|
+
}
|
|
210
|
+
export function pasteProperties() {
|
|
211
|
+
return {
|
|
212
|
+
type: PASTE_PROPERTIES
|
|
213
|
+
};
|
|
214
|
+
}
|
|
215
|
+
export function pushLastSelectedCatalogElementToHistory(element) {
|
|
216
|
+
return {
|
|
217
|
+
type: PUSH_LAST_SELECTED_CATALOG_ELEMENT_TO_HISTORY,
|
|
218
|
+
element: element
|
|
219
|
+
};
|
|
220
|
+
}
|
|
221
|
+
export function setAlterateState() {
|
|
222
|
+
return {
|
|
223
|
+
type: ALTERATE_STATE
|
|
224
|
+
};
|
|
225
|
+
}
|
|
226
|
+
export function setMode(mode) {
|
|
227
|
+
return {
|
|
228
|
+
type: SET_MODE,
|
|
229
|
+
mode: mode
|
|
230
|
+
};
|
|
231
|
+
}
|
|
232
|
+
export function addHorizontalGuide(coordinate) {
|
|
233
|
+
return {
|
|
234
|
+
type: ADD_HORIZONTAL_GUIDE,
|
|
235
|
+
coordinate: coordinate
|
|
236
|
+
};
|
|
237
|
+
}
|
|
238
|
+
export function addVerticalGuide(coordinate) {
|
|
239
|
+
return {
|
|
240
|
+
type: ADD_VERTICAL_GUIDE,
|
|
241
|
+
coordinate: coordinate
|
|
242
|
+
};
|
|
243
|
+
}
|
|
244
|
+
export function addCircularGuide(x, y, radius) {
|
|
245
|
+
return {
|
|
246
|
+
type: ADD_CIRCULAR_GUIDE,
|
|
247
|
+
x: x,
|
|
248
|
+
y: y,
|
|
249
|
+
radius: radius
|
|
250
|
+
};
|
|
251
|
+
}
|
|
252
|
+
export function removeHorizontalGuide(guideID) {
|
|
253
|
+
return {
|
|
254
|
+
type: REMOVE_HORIZONTAL_GUIDE,
|
|
255
|
+
guideID: guideID
|
|
256
|
+
};
|
|
257
|
+
}
|
|
258
|
+
export function removeVerticalGuide(guideID) {
|
|
259
|
+
return {
|
|
260
|
+
type: REMOVE_VERTICAL_GUIDE,
|
|
261
|
+
guideID: guideID
|
|
262
|
+
};
|
|
263
|
+
}
|
|
264
|
+
export function removeCircularGuide(guideID) {
|
|
265
|
+
return {
|
|
266
|
+
type: REMOVE_CIRCULAR_GUIDE,
|
|
267
|
+
guideID: guideID
|
|
268
|
+
};
|
|
269
|
+
}
|
|
270
|
+
export function removeDrawingSupport() {
|
|
271
|
+
return {
|
|
272
|
+
type: REMOVE_DRAWING_SUPPORT
|
|
273
|
+
};
|
|
274
|
+
}
|
|
275
|
+
export function selectAll() {
|
|
276
|
+
var value = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null;
|
|
277
|
+
return {
|
|
278
|
+
type: SELECT_ALL,
|
|
279
|
+
value: value
|
|
280
|
+
};
|
|
281
|
+
}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { ADD_LAYER, REMOVE_LAYER, SELECT_LAYER, SET_LAYER_PROPERTIES, UPDATE_MOVING_STATE } from "../constants";
|
|
2
|
+
export function selectLayer(layerID) {
|
|
3
|
+
return {
|
|
4
|
+
type: SELECT_LAYER,
|
|
5
|
+
layerID: layerID
|
|
6
|
+
};
|
|
7
|
+
}
|
|
8
|
+
export function addLayer(name, altitude) {
|
|
9
|
+
return {
|
|
10
|
+
type: ADD_LAYER,
|
|
11
|
+
name: name,
|
|
12
|
+
altitude: altitude
|
|
13
|
+
};
|
|
14
|
+
}
|
|
15
|
+
export function setLayerProperties(layerID, properties) {
|
|
16
|
+
return {
|
|
17
|
+
type: SET_LAYER_PROPERTIES,
|
|
18
|
+
layerID: layerID,
|
|
19
|
+
properties: properties
|
|
20
|
+
};
|
|
21
|
+
}
|
|
22
|
+
export function removeLayer(layerID) {
|
|
23
|
+
return {
|
|
24
|
+
type: REMOVE_LAYER,
|
|
25
|
+
layerID: layerID
|
|
26
|
+
};
|
|
27
|
+
}
|
|
28
|
+
export function updateMovingState(showflag) {
|
|
29
|
+
return {
|
|
30
|
+
type: UPDATE_MOVING_STATE,
|
|
31
|
+
showflag: showflag
|
|
32
|
+
};
|
|
33
|
+
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { BEGIN_DRAGGING_VERTEX, END_DRAGGING_VERTEX, UPDATE_DRAGGING_VERTEX } from "../constants";
|
|
2
|
+
export function beginDraggingVertex(layerID, vertexID, x, y, snapMask) {
|
|
3
|
+
return {
|
|
4
|
+
type: BEGIN_DRAGGING_VERTEX,
|
|
5
|
+
layerID: layerID,
|
|
6
|
+
vertexID: vertexID,
|
|
7
|
+
x: x,
|
|
8
|
+
y: y,
|
|
9
|
+
snapMask: snapMask
|
|
10
|
+
};
|
|
11
|
+
}
|
|
12
|
+
export function updateDraggingVertex(x, y, snapMask) {
|
|
13
|
+
return {
|
|
14
|
+
type: UPDATE_DRAGGING_VERTEX,
|
|
15
|
+
x: x,
|
|
16
|
+
y: y,
|
|
17
|
+
snapMask: snapMask
|
|
18
|
+
};
|
|
19
|
+
}
|
|
20
|
+
export function endDraggingVertex(x, y, snapMask) {
|
|
21
|
+
return {
|
|
22
|
+
type: END_DRAGGING_VERTEX,
|
|
23
|
+
x: x,
|
|
24
|
+
y: y,
|
|
25
|
+
snapMask: snapMask
|
|
26
|
+
};
|
|
27
|
+
}
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import { CHANGE_BASE_CABINET_MEASURE, CHANGE_WALL_CABINET_MEASURE, CHANGE_WALL_LENGTH_MEASURE, CHANGE_WINDOW_DOOR_MEASURE, SELECT_TOOL_PAN, SELECT_TOOL_ZOOM_IN, SELECT_TOOL_ZOOM_OUT, UPDATE_2D_CAMERA, UPDATE_CEIL_HEIGHT, UPDATE_CEIL_HEIGHT_UNIT } from "../constants";
|
|
2
|
+
export function updateCeilHeight(value) {
|
|
3
|
+
return {
|
|
4
|
+
type: UPDATE_CEIL_HEIGHT,
|
|
5
|
+
value: value
|
|
6
|
+
};
|
|
7
|
+
}
|
|
8
|
+
export function updateCeilHeightUnit(value) {
|
|
9
|
+
return {
|
|
10
|
+
type: UPDATE_CEIL_HEIGHT_UNIT,
|
|
11
|
+
value: value
|
|
12
|
+
};
|
|
13
|
+
}
|
|
14
|
+
export function updateCameraView(value) {
|
|
15
|
+
return {
|
|
16
|
+
type: UPDATE_2D_CAMERA,
|
|
17
|
+
value: value
|
|
18
|
+
};
|
|
19
|
+
}
|
|
20
|
+
export function changeWallLengthMeasure(value) {
|
|
21
|
+
return {
|
|
22
|
+
type: CHANGE_WALL_LENGTH_MEASURE,
|
|
23
|
+
value: value
|
|
24
|
+
};
|
|
25
|
+
}
|
|
26
|
+
export function changeBaseCabinetMeasure(value) {
|
|
27
|
+
return {
|
|
28
|
+
type: CHANGE_BASE_CABINET_MEASURE,
|
|
29
|
+
value: value
|
|
30
|
+
};
|
|
31
|
+
}
|
|
32
|
+
export function changeWallCabinetMeasure(value) {
|
|
33
|
+
return {
|
|
34
|
+
type: CHANGE_WALL_CABINET_MEASURE,
|
|
35
|
+
value: value
|
|
36
|
+
};
|
|
37
|
+
}
|
|
38
|
+
export function changeWindowDoorMeasure(value) {
|
|
39
|
+
return {
|
|
40
|
+
type: CHANGE_WINDOW_DOOR_MEASURE,
|
|
41
|
+
value: value
|
|
42
|
+
};
|
|
43
|
+
}
|
|
44
|
+
export function selectToolPan() {
|
|
45
|
+
return {
|
|
46
|
+
type: SELECT_TOOL_PAN
|
|
47
|
+
};
|
|
48
|
+
}
|
|
49
|
+
export function selectToolZoomOut() {
|
|
50
|
+
return {
|
|
51
|
+
type: SELECT_TOOL_ZOOM_OUT
|
|
52
|
+
};
|
|
53
|
+
}
|
|
54
|
+
export function selectToolZoomIn() {
|
|
55
|
+
return {
|
|
56
|
+
type: SELECT_TOOL_ZOOM_IN
|
|
57
|
+
};
|
|
58
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { SELECT_TOOL_3D_FIRST_PERSON, SELECT_TOOL_3D_VIEW, UPDATE_3D_CEIL_HEIGHT, UPDATE_3D_CEIL_HEIGHT_UNIT } from "../constants";
|
|
2
|
+
export function selectTool3DView() {
|
|
3
|
+
return {
|
|
4
|
+
type: SELECT_TOOL_3D_VIEW
|
|
5
|
+
};
|
|
6
|
+
}
|
|
7
|
+
export function selectTool3DFirstPerson() {
|
|
8
|
+
return {
|
|
9
|
+
type: SELECT_TOOL_3D_FIRST_PERSON
|
|
10
|
+
};
|
|
11
|
+
}
|
|
12
|
+
export function update3DCeilHeight(value) {
|
|
13
|
+
return {
|
|
14
|
+
type: UPDATE_3D_CEIL_HEIGHT,
|
|
15
|
+
value: value
|
|
16
|
+
};
|
|
17
|
+
}
|
|
18
|
+
export function update3DCeilHeightUnit(value) {
|
|
19
|
+
return {
|
|
20
|
+
type: UPDATE_3D_CEIL_HEIGHT_UNIT,
|
|
21
|
+
value: value
|
|
22
|
+
};
|
|
23
|
+
}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import { ElementsFactories } from "../../..";
|
|
2
|
+
var info = {
|
|
3
|
+
title: 'area',
|
|
4
|
+
tag: ['area'],
|
|
5
|
+
description: 'Generic Room',
|
|
6
|
+
image: ''
|
|
7
|
+
};
|
|
8
|
+
var textures = {
|
|
9
|
+
parquet: {
|
|
10
|
+
name: 'Parquet',
|
|
11
|
+
uri: require("./textures/parquet.jpg"),
|
|
12
|
+
lengthRepeatScale: 0.004,
|
|
13
|
+
heightRepeatScale: 0.004
|
|
14
|
+
},
|
|
15
|
+
tile1: {
|
|
16
|
+
name: 'Tile1',
|
|
17
|
+
uri: require("./textures/tile1.jpg"),
|
|
18
|
+
lengthRepeatScale: 0.01,
|
|
19
|
+
heightRepeatScale: 0.01
|
|
20
|
+
},
|
|
21
|
+
ceramic: {
|
|
22
|
+
name: 'Ceramic Tile',
|
|
23
|
+
uri: require("./textures/ceramic-tile.jpg"),
|
|
24
|
+
lengthRepeatScale: 0.02,
|
|
25
|
+
heightRepeatScale: 0.02
|
|
26
|
+
},
|
|
27
|
+
strand_porcelain: {
|
|
28
|
+
name: 'Strand Porcelain Tile',
|
|
29
|
+
uri: require("./textures/strand-porcelain.jpg"),
|
|
30
|
+
lengthRepeatScale: 0.02,
|
|
31
|
+
heightRepeatScale: 0.02
|
|
32
|
+
},
|
|
33
|
+
grass: {
|
|
34
|
+
name: 'Grass',
|
|
35
|
+
uri: require("./textures/grass.jpg"),
|
|
36
|
+
lengthRepeatScale: 0.01,
|
|
37
|
+
heightRepeatScale: 0.01
|
|
38
|
+
}
|
|
39
|
+
};
|
|
40
|
+
export default ElementsFactories.AreaFactory('area', info, textures);
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|