kitchen-simulator 1.1.1-test.75 → 1.1.1-test.77

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 (876) hide show
  1. package/README.md +24 -1
  2. package/es/CrossSignOn.js +84 -0
  3. package/es/KitchenConfigurator.js +811 -48
  4. package/es/LiteKitchenConfigurator.js +631 -0
  5. package/es/{KitchenConfiguratorApp.js → LiteRenderer.js} +4 -4
  6. package/es/actions/export.js +4 -2
  7. package/es/actions/holes-actions.js +1 -1
  8. package/es/actions/items-actions.js +1 -1
  9. package/es/actions/lines-actions.js +1 -1
  10. package/es/actions/project-actions.js +1 -1
  11. package/es/actions/scene-actions.js +1 -1
  12. package/es/actions/user-actions.js +58 -0
  13. package/es/actions/vertices-actions.js +1 -1
  14. package/es/actions/viewer2d-actions.js +1 -1
  15. package/es/actions/viewer3d-actions.js +1 -1
  16. package/es/analytics/ga4.js +188 -0
  17. package/es/analytics/posthog.js +60 -0
  18. package/es/assets/Window.hdr +2100 -0
  19. package/es/assets/brown_photostudio_02_1k.hdr +0 -0
  20. package/es/assets/fonts/Rene Bieder Milliard Black Italic.woff +0 -0
  21. package/es/assets/fonts/Rene Bieder Milliard Black.woff +0 -0
  22. package/es/assets/fonts/Rene Bieder Milliard Bold Italic.woff +0 -0
  23. package/es/assets/fonts/Rene Bieder Milliard Bold.woff +0 -0
  24. package/es/assets/fonts/Rene Bieder Milliard Book Italic.woff +0 -0
  25. package/es/assets/fonts/Rene Bieder Milliard Book.woff +0 -0
  26. package/es/assets/fonts/Rene Bieder Milliard ExtraBold Italic.woff +0 -0
  27. package/es/assets/fonts/Rene Bieder Milliard ExtraBold.woff +0 -0
  28. package/es/assets/fonts/Rene Bieder Milliard ExtraLight Italic.woff +0 -0
  29. package/es/assets/fonts/Rene Bieder Milliard ExtraLight.woff +0 -0
  30. package/es/assets/fonts/Rene Bieder Milliard Hairline Italic.woff +0 -0
  31. package/es/assets/fonts/Rene Bieder Milliard Hairline.woff +0 -0
  32. package/es/assets/fonts/Rene Bieder Milliard Heavy Italic.woff +0 -0
  33. package/es/assets/fonts/Rene Bieder Milliard Heavy.woff +0 -0
  34. package/es/assets/fonts/Rene Bieder Milliard Light Italic.woff +0 -0
  35. package/es/assets/fonts/Rene Bieder Milliard Light.woff +0 -0
  36. package/es/assets/fonts/Rene Bieder Milliard Medium Italic.woff +0 -0
  37. package/es/assets/fonts/Rene Bieder Milliard Medium.woff +0 -0
  38. package/es/assets/fonts/Rene Bieder Milliard SemiBold Italic.woff +0 -0
  39. package/es/assets/fonts/Rene Bieder Milliard SemiBold.woff +0 -0
  40. package/es/assets/fonts/Rene Bieder Milliard Thin Italic.woff +0 -0
  41. package/es/assets/fonts/Rene Bieder Milliard Thin.woff +0 -0
  42. package/es/assets/fonts/style.css +177 -0
  43. package/es/assets/gltf/door_closet.bin +0 -0
  44. package/es/assets/gltf/door_closet.fbx +0 -0
  45. package/es/assets/gltf/door_closet.gltf +1 -0
  46. package/es/assets/gltf/door_exterior.bin +0 -0
  47. package/es/assets/gltf/door_exterior.fbx +0 -0
  48. package/es/assets/gltf/door_exterior.gltf +1 -0
  49. package/es/assets/gltf/door_interior.bin +0 -0
  50. package/es/assets/gltf/door_interior.fbx +0 -0
  51. package/es/assets/gltf/door_interior.gltf +1 -0
  52. package/es/assets/gltf/door_sliding.bin +0 -0
  53. package/es/assets/gltf/door_sliding.fbx +0 -0
  54. package/es/assets/gltf/door_sliding.gltf +1 -0
  55. package/es/assets/gltf/doorway_framed.bin +0 -0
  56. package/es/assets/gltf/doorway_framed.fbx +0 -0
  57. package/es/assets/gltf/doorway_framed.gltf +1 -0
  58. package/es/assets/gltf/window_clear.bin +0 -0
  59. package/es/assets/gltf/window_clear.fbx +0 -0
  60. package/es/assets/gltf/window_clear.gltf +1 -0
  61. package/es/assets/gltf/window_cross.bin +0 -0
  62. package/es/assets/gltf/window_cross.fbx +0 -0
  63. package/es/assets/gltf/window_cross.gltf +1 -0
  64. package/es/assets/gltf/window_double_hung.bin +0 -0
  65. package/es/assets/gltf/window_double_hung.fbx +0 -0
  66. package/es/assets/gltf/window_double_hung.gltf +1 -0
  67. package/es/assets/gltf/window_vertical.bin +0 -0
  68. package/es/assets/gltf/window_vertical.fbx +0 -0
  69. package/es/assets/gltf/window_vertical.gltf +1 -0
  70. package/es/assets/img/1.jpg +0 -0
  71. package/es/assets/img/TKC_thumbnail.png +0 -0
  72. package/es/assets/img/Toggle.png +0 -0
  73. package/es/assets/img/loading/loading.gif +0 -0
  74. package/es/assets/img/loading/loading_1.svg +11 -0
  75. package/es/assets/img/loading_large.gif +0 -0
  76. package/es/assets/img/png/door/closet.png +0 -0
  77. package/es/assets/img/png/door/doorwaysframed.png +0 -0
  78. package/es/assets/img/png/door/doorwaysframeles.png +0 -0
  79. package/es/assets/img/png/door/doorwaysframeless.png +0 -0
  80. package/es/assets/img/png/door/exterior.png +0 -0
  81. package/es/assets/img/png/door/interior.png +0 -0
  82. package/es/assets/img/png/door/sliding.png +0 -0
  83. package/es/assets/img/png/helper/outcome.png +0 -0
  84. package/es/assets/img/png/helper/video_preview_3d.png +0 -0
  85. package/es/assets/img/png/helper/video_preview_start.png +0 -0
  86. package/es/assets/img/project_img.png +0 -0
  87. package/es/assets/img/rta/rta_logo_box_blue.jpg +0 -0
  88. package/es/assets/img/rta/rta_logo_box_blue_ico.jpg +0 -0
  89. package/es/assets/img/rta/rta_logo_box_blue_ico.svg +55 -0
  90. package/es/assets/img/rta/rta_logo_box_darkGray.jpg +0 -0
  91. package/es/assets/img/rta/rta_logo_box_lightblue.png +0 -0
  92. package/es/assets/img/rta/rta_logo_box_lightmaroon.png +0 -0
  93. package/es/assets/img/rta/rta_logo_box_maroon.png +0 -0
  94. package/es/assets/img/rta/rta_logo_box_white.png +0 -0
  95. package/es/assets/img/rta_menu.png +0 -0
  96. package/es/assets/img/step2.jpg +0 -0
  97. package/es/assets/img/step3.jpg +0 -0
  98. package/es/assets/img/step4.jpg +0 -0
  99. package/es/assets/img/step5.jpg +0 -0
  100. package/es/assets/img/step6.jpg +0 -0
  101. package/es/assets/img/step7.jpg +0 -0
  102. package/es/assets/img/step8.jpg +0 -0
  103. package/es/assets/img/svg/2d_delete_object.svg +33 -0
  104. package/es/assets/img/svg/2d_delete_object1.svg +33 -0
  105. package/es/assets/img/svg/2d_lock_object.svg +33 -0
  106. package/es/assets/img/svg/3d_item_move.svg +106 -0
  107. package/es/assets/img/svg/3d_item_rotation.svg +76 -0
  108. package/es/assets/img/svg/3d_item_warning_edit.svg +77 -0
  109. package/es/assets/img/svg/3d_item_warning_info.svg +81 -0
  110. package/es/assets/img/svg/accessories.svg +4 -0
  111. package/es/assets/img/svg/angle_icon.svg +39 -0
  112. package/es/assets/img/svg/blank_div.svg +14 -0
  113. package/es/assets/img/svg/bottombar/2d3d_button.svg +3 -0
  114. package/es/assets/img/svg/bottombar/2d3d_button_active.svg +3 -0
  115. package/es/assets/img/svg/bottombar/2d3d_toggle.svg +4 -0
  116. package/es/assets/img/svg/bottombar/2d3d_toggle_active.svg +4 -0
  117. package/es/assets/img/svg/bottombar/arrow-down.svg +3 -0
  118. package/es/assets/img/svg/bottombar/arrow-left.svg +3 -0
  119. package/es/assets/img/svg/bottombar/arrow-minus.svg +3 -0
  120. package/es/assets/img/svg/bottombar/arrow-plus.svg +11 -0
  121. package/es/assets/img/svg/bottombar/arrow-right.svg +3 -0
  122. package/es/assets/img/svg/bottombar/arrow-up.svg +3 -0
  123. package/es/assets/img/svg/bottombar/collapse.svg +3 -0
  124. package/es/assets/img/svg/bottombar/elevation-back.svg +6 -0
  125. package/es/assets/img/svg/bottombar/elevation-front.svg +6 -0
  126. package/es/assets/img/svg/bottombar/elevation-left.svg +6 -0
  127. package/es/assets/img/svg/bottombar/elevation-right.svg +7 -0
  128. package/es/assets/img/svg/bottombar/elevation.svg +6 -0
  129. package/es/assets/img/svg/bottombar/expand.svg +3 -0
  130. package/es/assets/img/svg/bottombar/help.svg +72 -0
  131. package/es/assets/img/svg/bottombar/incm_toggle.svg +39 -0
  132. package/es/assets/img/svg/bottombar/pan_1.svg +57 -0
  133. package/es/assets/img/svg/bottombar/pan_2.svg +27 -0
  134. package/es/assets/img/svg/bottombar/pan_3.svg +27 -0
  135. package/es/assets/img/svg/bottombar/pan_4.svg +27 -0
  136. package/es/assets/img/svg/bottombar/pan_5.svg +27 -0
  137. package/es/assets/img/svg/bottombar/settings.svg +23 -0
  138. package/es/assets/img/svg/bottombar/spin-down.svg +76 -0
  139. package/es/assets/img/svg/bottombar/spin-left.svg +75 -0
  140. package/es/assets/img/svg/bottombar/spin-right.svg +75 -0
  141. package/es/assets/img/svg/bottombar/spin-up.svg +76 -0
  142. package/es/assets/img/svg/bottombar/spin_1.svg +48 -0
  143. package/es/assets/img/svg/bottombar/spin_2.svg +31 -0
  144. package/es/assets/img/svg/bottombar/spin_3.svg +31 -0
  145. package/es/assets/img/svg/bottombar/spin_4.svg +31 -0
  146. package/es/assets/img/svg/bottombar/spin_5.svg +31 -0
  147. package/es/assets/img/svg/bottombar/zoomin.svg +29 -0
  148. package/es/assets/img/svg/bottombar/zoomout.svg +26 -0
  149. package/es/assets/img/svg/check.svg +10 -0
  150. package/es/assets/img/svg/close.svg +11 -0
  151. package/es/assets/img/svg/color/Black.svg +3 -0
  152. package/es/assets/img/svg/color/Blue.svg +3 -0
  153. package/es/assets/img/svg/color/Brown.svg +9 -0
  154. package/es/assets/img/svg/color/Cream.svg +3 -0
  155. package/es/assets/img/svg/color/Dark.svg +9 -0
  156. package/es/assets/img/svg/color/Gray.svg +3 -0
  157. package/es/assets/img/svg/color/Green.svg +3 -0
  158. package/es/assets/img/svg/color/Light.svg +9 -0
  159. package/es/assets/img/svg/color/Medium.svg +9 -0
  160. package/es/assets/img/svg/color/Unfinished.svg +9 -0
  161. package/es/assets/img/svg/color/White.svg +3 -0
  162. package/es/assets/img/svg/color/White.svg.bak +3 -0
  163. package/es/assets/img/svg/color/stone2.jpg +0 -0
  164. package/es/assets/img/svg/color/wood2.jpg +0 -0
  165. package/es/assets/img/svg/copy.svg +11 -0
  166. package/es/assets/img/svg/delete.svg +3 -0
  167. package/es/assets/img/svg/detail.svg +77 -0
  168. package/es/assets/img/svg/disclaimer/background.svg +758 -0
  169. package/es/assets/img/svg/disclaimer/logo-dots.svg +11 -0
  170. package/es/assets/img/svg/door/Closet.svg +11 -0
  171. package/es/assets/img/svg/door/Exterior.svg +5 -0
  172. package/es/assets/img/svg/door/Framed_dorway.svg +5 -0
  173. package/es/assets/img/svg/door/Frameless_dorway.svg +5 -0
  174. package/es/assets/img/svg/door/Interior.svg +7 -0
  175. package/es/assets/img/svg/door/Sliding.svg +5 -0
  176. package/es/assets/img/svg/doors_closet.svg +47 -0
  177. package/es/assets/img/svg/doors_exterior.svg +25 -0
  178. package/es/assets/img/svg/doors_interior.svg +29 -0
  179. package/es/assets/img/svg/doors_patio.svg +26 -0
  180. package/es/assets/img/svg/duplicate.svg +11 -0
  181. package/es/assets/img/svg/duplicate_object_left.svg +32 -0
  182. package/es/assets/img/svg/duplicate_object_right.svg +32 -0
  183. package/es/assets/img/svg/filtersActive.svg +19 -0
  184. package/es/assets/img/svg/firstsetting/L.svg +3 -0
  185. package/es/assets/img/svg/firstsetting/L2.svg +3 -0
  186. package/es/assets/img/svg/firstsetting/Open.svg +3 -0
  187. package/es/assets/img/svg/firstsetting/Square.svg +3 -0
  188. package/es/assets/img/svg/firstsetting/bar-active.svg +9 -0
  189. package/es/assets/img/svg/firstsetting/bar-normal.svg +3 -0
  190. package/es/assets/img/svg/firstsetting/bullet-current.svg +3 -0
  191. package/es/assets/img/svg/firstsetting/bullet-done.svg +3 -0
  192. package/es/assets/img/svg/firstsetting/bullet-not-done.svg +3 -0
  193. package/es/assets/img/svg/firstsetting/check-active.svg +3 -0
  194. package/es/assets/img/svg/firstsetting/check-normal.svg +3 -0
  195. package/es/assets/img/svg/firstsetting/pencil.svg +11 -0
  196. package/es/assets/img/svg/green_checkmark.svg +27 -0
  197. package/es/assets/img/svg/headerbar/assist.svg +3 -0
  198. package/es/assets/img/svg/headerbar/cart.svg +3 -0
  199. package/es/assets/img/svg/headerbar/check.svg +10 -0
  200. package/es/assets/img/svg/headerbar/consult_designer.svg +45 -0
  201. package/es/assets/img/svg/headerbar/edit_name.svg +26 -0
  202. package/es/assets/img/svg/headerbar/file-dollar.svg +13 -0
  203. package/es/assets/img/svg/headerbar/hamburger_menu.svg +32 -0
  204. package/es/assets/img/svg/headerbar/plus.svg +11 -0
  205. package/es/assets/img/svg/headerbar/review_quote.svg +44 -0
  206. package/es/assets/img/svg/headerbar/ruler-measure.svg +11 -0
  207. package/es/assets/img/svg/headerbar/save.svg +3 -0
  208. package/es/assets/img/svg/headerbar/setting.svg +75 -0
  209. package/es/assets/img/svg/help/check.svg +10 -0
  210. package/es/assets/img/svg/help/search.svg +76 -0
  211. package/es/assets/img/svg/intro/1-start-with-floorplan-whole.svg +27 -0
  212. package/es/assets/img/svg/intro/1-start-with-floorplan.svg +26 -0
  213. package/es/assets/img/svg/intro/2-start-from-scratch-whole.svg +28 -0
  214. package/es/assets/img/svg/intro/2-start-from-scratch.svg +27 -0
  215. package/es/assets/img/svg/intro/3-retrieve-project-whole.svg +19 -0
  216. package/es/assets/img/svg/intro/3-retrieve-project.svg +18 -0
  217. package/es/assets/img/svg/invert.svg +127 -0
  218. package/es/assets/img/svg/lefttoolbar/appliance-active.svg +13 -0
  219. package/es/assets/img/svg/lefttoolbar/appliance.svg +13 -0
  220. package/es/assets/img/svg/lefttoolbar/cabinet-active.svg +10 -0
  221. package/es/assets/img/svg/lefttoolbar/cabinet-category.svg +3 -0
  222. package/es/assets/img/svg/lefttoolbar/cabinet-one.svg +3 -0
  223. package/es/assets/img/svg/lefttoolbar/cabinet.svg +10 -0
  224. package/es/assets/img/svg/lefttoolbar/disigner_assistance.svg +89 -0
  225. package/es/assets/img/svg/lefttoolbar/door-style-active.svg +20 -0
  226. package/es/assets/img/svg/lefttoolbar/door-style.svg +20 -0
  227. package/es/assets/img/svg/lefttoolbar/door.svg +12 -0
  228. package/es/assets/img/svg/lefttoolbar/error_icon.svg +81 -0
  229. package/es/assets/img/svg/lefttoolbar/finishing-active.svg +13 -0
  230. package/es/assets/img/svg/lefttoolbar/finishing.svg +13 -0
  231. package/es/assets/img/svg/lefttoolbar/reviewforquote-active.svg +86 -0
  232. package/es/assets/img/svg/lefttoolbar/reviewforquote.svg +12 -0
  233. package/es/assets/img/svg/lefttoolbar/room-shape-L.svg +3 -0
  234. package/es/assets/img/svg/lefttoolbar/room-shape-active.svg +18 -0
  235. package/es/assets/img/svg/lefttoolbar/room-shape-custom.svg +12 -0
  236. package/es/assets/img/svg/lefttoolbar/room-shape-irregular.svg +3 -0
  237. package/es/assets/img/svg/lefttoolbar/room-shape-open.svg +3 -0
  238. package/es/assets/img/svg/lefttoolbar/room-shape-square.svg +3 -0
  239. package/es/assets/img/svg/lefttoolbar/room-shape.svg +18 -0
  240. package/es/assets/img/svg/lefttoolbar/search.svg +76 -0
  241. package/es/assets/img/svg/lefttoolbar/view_more.svg +86 -0
  242. package/es/assets/img/svg/lefttoolbar/warning_icon.svg +81 -0
  243. package/es/assets/img/svg/lefttoolbar/window.svg +12 -0
  244. package/es/assets/img/svg/menubar/login.svg +84 -0
  245. package/es/assets/img/svg/menubar/my_projects.svg +85 -0
  246. package/es/assets/img/svg/menubar/new_project.svg +110 -0
  247. package/es/assets/img/svg/menubar/save_project.svg +84 -0
  248. package/es/assets/img/svg/options.svg +3 -0
  249. package/es/assets/img/svg/positioning.svg +3 -0
  250. package/es/assets/img/svg/rotate.png +0 -0
  251. package/es/assets/img/svg/rotate.svg +17 -0
  252. package/es/assets/img/svg/rotate_object_clockwise.svg +26 -0
  253. package/es/assets/img/svg/rotate_object_counterclockwise.svg +26 -0
  254. package/es/assets/img/svg/toggleFilters.svg +19 -0
  255. package/es/assets/img/svg/toolbar/add_appliances_active.svg +64 -0
  256. package/es/assets/img/svg/toolbar/add_appliances_inactive.svg +52 -0
  257. package/es/assets/img/svg/toolbar/add_button.svg +36 -0
  258. package/es/assets/img/svg/toolbar/add_cabinets_active.svg +59 -0
  259. package/es/assets/img/svg/toolbar/add_cabinets_inactive.svg +49 -0
  260. package/es/assets/img/svg/toolbar/add_items_doors.svg +25 -0
  261. package/es/assets/img/svg/toolbar/add_items_doorways.svg +24 -0
  262. package/es/assets/img/svg/toolbar/add_items_refrigerator.svg +32 -0
  263. package/es/assets/img/svg/toolbar/add_items_windows.svg +28 -0
  264. package/es/assets/img/svg/toolbar/apply_button.svg +38 -0
  265. package/es/assets/img/svg/toolbar/arrow-plus.svg +11 -0
  266. package/es/assets/img/svg/toolbar/backsplash.svg +8 -0
  267. package/es/assets/img/svg/toolbar/cancel_button.svg +37 -0
  268. package/es/assets/img/svg/toolbar/consult_a_designer_button.svg +47 -0
  269. package/es/assets/img/svg/toolbar/countertop.svg +7 -0
  270. package/es/assets/img/svg/toolbar/dcm.png +0 -0
  271. package/es/assets/img/svg/toolbar/dcm_off.svg +12 -0
  272. package/es/assets/img/svg/toolbar/dcm_on.svg +474 -0
  273. package/es/assets/img/svg/toolbar/delete_button.svg +37 -0
  274. package/es/assets/img/svg/toolbar/download.svg +77 -0
  275. package/es/assets/img/svg/toolbar/draw_custom_floor.svg +31 -0
  276. package/es/assets/img/svg/toolbar/edit_button.svg +75 -0
  277. package/es/assets/img/svg/toolbar/email_quote_button.svg +44 -0
  278. package/es/assets/img/svg/toolbar/fbm.png +0 -0
  279. package/es/assets/img/svg/toolbar/finishing_touches_active.svg +54 -0
  280. package/es/assets/img/svg/toolbar/finishing_touches_inactive.svg +42 -0
  281. package/es/assets/img/svg/toolbar/floorstyle.svg +9 -0
  282. package/es/assets/img/svg/toolbar/fmb.png +0 -0
  283. package/es/assets/img/svg/toolbar/fmb_off.svg +12 -0
  284. package/es/assets/img/svg/toolbar/fmb_on.svg +489 -0
  285. package/es/assets/img/svg/toolbar/furnishings_icon.svg +6 -0
  286. package/es/assets/img/svg/toolbar/get_started_button.svg +41 -0
  287. package/es/assets/img/svg/toolbar/handles.svg +5 -0
  288. package/es/assets/img/svg/toolbar/lighting.svg +7 -0
  289. package/es/assets/img/svg/toolbar/lrm.png +0 -0
  290. package/es/assets/img/svg/toolbar/lrm_off.svg +12 -0
  291. package/es/assets/img/svg/toolbar/lrm_on.svg +470 -0
  292. package/es/assets/img/svg/toolbar/make_floorplan_active.svg +66 -0
  293. package/es/assets/img/svg/toolbar/make_floorplan_inactive.svg +52 -0
  294. package/es/assets/img/svg/toolbar/predefined_room_l_shaped.svg +20 -0
  295. package/es/assets/img/svg/toolbar/predefined_room_layout.svg +20 -0
  296. package/es/assets/img/svg/toolbar/predefined_room_long_narrow.svg +20 -0
  297. package/es/assets/img/svg/toolbar/predefined_room_open_l_shape.svg +20 -0
  298. package/es/assets/img/svg/toolbar/predefined_room_open_pentagon.svg +20 -0
  299. package/es/assets/img/svg/toolbar/predefined_room_open_rectangle.svg +20 -0
  300. package/es/assets/img/svg/toolbar/predefined_room_open_rectangle_2.svg +20 -0
  301. package/es/assets/img/svg/toolbar/predefined_room_pentagon.svg +20 -0
  302. package/es/assets/img/svg/toolbar/predefined_room_rectangle.svg +20 -0
  303. package/es/assets/img/svg/toolbar/predefined_room_rectangle_with_alcove.svg +20 -0
  304. package/es/assets/img/svg/toolbar/redo_button.svg +75 -0
  305. package/es/assets/img/svg/toolbar/redo_button1.svg +75 -0
  306. package/es/assets/img/svg/toolbar/review_quote_active.svg +14 -0
  307. package/es/assets/img/svg/toolbar/review_quote_inactive.svg +44 -0
  308. package/es/assets/img/svg/toolbar/save_project_button.svg +44 -0
  309. package/es/assets/img/svg/toolbar/select_doorstyle_active.svg +67 -0
  310. package/es/assets/img/svg/toolbar/select_doorstyle_inactive.svg +57 -0
  311. package/es/assets/img/svg/toolbar/shopping-cart.svg +13 -0
  312. package/es/assets/img/svg/toolbar/style_change_button.svg +47 -0
  313. package/es/assets/img/svg/toolbar/take_picture.svg +75 -0
  314. package/es/assets/img/svg/toolbar/undo_button.svg +76 -0
  315. package/es/assets/img/svg/toolbar/undo_button1.svg +76 -0
  316. package/es/assets/img/svg/toolbar/use_button.svg +37 -0
  317. package/es/assets/img/svg/toolbar/wall_color_icon.svg +6 -0
  318. package/es/assets/img/svg/topbar/edit_active.svg +10 -0
  319. package/es/assets/img/svg/topbar/edit_inactive.svg +10 -0
  320. package/es/assets/img/svg/topbar/redo_active.svg +42 -0
  321. package/es/assets/img/svg/topbar/redo_inactive.svg +23 -0
  322. package/es/assets/img/svg/topbar/select_all_active.svg +50 -0
  323. package/es/assets/img/svg/topbar/select_all_inactive.svg +32 -0
  324. package/es/assets/img/svg/topbar/take_picture_active.svg +51 -0
  325. package/es/assets/img/svg/topbar/take_picture_inactive.svg +26 -0
  326. package/es/assets/img/svg/topbar/undo_active.svg +42 -0
  327. package/es/assets/img/svg/topbar/undo_inactive.svg +23 -0
  328. package/es/assets/img/svg/warning_info_2d.svg +81 -0
  329. package/es/assets/img/svg/window/Clear.svg +3 -0
  330. package/es/assets/img/svg/window/Cross.svg +5 -0
  331. package/es/assets/img/svg/window/Double_hung.svg +4 -0
  332. package/es/assets/img/svg/window/Vertical.svg +4 -0
  333. package/es/assets/img/svg/windows_clear.svg +23 -0
  334. package/es/assets/img/svg/windows_cross.svg +28 -0
  335. package/es/assets/img/svg/windows_double_hung.svg +24 -0
  336. package/es/assets/img/svg/windows_vertical.svg +24 -0
  337. package/es/assets/img/svg/wizardstep/Custom.svg +3 -0
  338. package/es/assets/img/svg/wizardstep/Dashed_line.svg +3 -0
  339. package/es/assets/img/svg/wizardstep/L.svg +3 -0
  340. package/es/assets/img/svg/wizardstep/L2.svg +3 -0
  341. package/es/assets/img/svg/wizardstep/Open.svg +3 -0
  342. package/es/assets/img/svg/wizardstep/Square.svg +3 -0
  343. package/es/assets/img/svg/wizardstep/bar-active.svg +9 -0
  344. package/es/assets/img/svg/wizardstep/bar-normal.svg +3 -0
  345. package/es/assets/img/svg/wizardstep/bullet-current.svg +3 -0
  346. package/es/assets/img/svg/wizardstep/bullet-done.svg +3 -0
  347. package/es/assets/img/svg/wizardstep/bullet-not-done.svg +3 -0
  348. package/es/assets/img/svg/wizardstep/check-active.svg +3 -0
  349. package/es/assets/img/svg/wizardstep/check-normal.svg +3 -0
  350. package/es/assets/img/svg/wizardstep/detail_view.svg +87 -0
  351. package/es/assets/img/svg/wizardstep/pencil.svg +11 -0
  352. package/es/assets/img/svg/wizardstep/tile_view.svg +95 -0
  353. package/es/assets/img/texture/glass.jpg +0 -0
  354. package/es/assets/img/texture/steel.jpg +0 -0
  355. package/es/assets/img/texture/white1px.jpg +0 -0
  356. package/es/assets/img/texture/wood.jpg +0 -0
  357. package/es/assets/model/DCM.bin +0 -0
  358. package/es/assets/model/DCM.fbx +0 -0
  359. package/es/assets/model/DCM.gltf +1 -0
  360. package/es/assets/model/FBM.bin +0 -0
  361. package/es/assets/model/FBM.fbx +0 -0
  362. package/es/assets/model/FBM.gltf +1 -0
  363. package/es/assets/model/LRM.bin +0 -0
  364. package/es/assets/model/LRM.fbx +0 -0
  365. package/es/assets/model/LRM.gltf +1 -0
  366. package/es/assets/rtastore_logo.png +0 -0
  367. package/es/catalog/areas/area/planner-element.js +8 -11
  368. package/es/catalog/back.png +0 -0
  369. package/es/catalog/doors.png +0 -0
  370. package/es/catalog/doorways.png +0 -0
  371. package/es/catalog/export.js +0 -0
  372. package/es/catalog/factories/wall-factory.js +1 -2
  373. package/es/catalog/lines/wall/planner-element.js +11 -14
  374. package/es/catalog/molding/molding-dcm/planner-element.js +0 -2
  375. package/es/catalog/molding/molding-fbm/planner-element.js +0 -2
  376. package/es/catalog/molding/molding-lrm/planner-element.js +0 -2
  377. package/es/catalog/properties/property-checkbox.js +18 -63
  378. package/es/catalog/properties/property-enum.js +9 -51
  379. package/es/catalog/properties/property-lenght-measure.js +1 -1
  380. package/es/catalog/properties/property-length-measure.js +6 -50
  381. package/es/catalog/utils/item-loader.js +1 -2
  382. package/es/catalog/utils/mtl-loader.js +2 -3
  383. package/es/catalog/utils/obj-loader.js +2 -3
  384. package/es/catalog/windows.png +0 -0
  385. package/es/class/area.js +1 -1
  386. package/es/class/group.js +3 -3
  387. package/es/class/hole.js +6 -5
  388. package/es/class/item.js +8 -3
  389. package/es/class/layer.js +2 -2
  390. package/es/class/line.js +87 -52
  391. package/es/class/project.js +8 -6
  392. package/es/class/vertex.js +1 -1
  393. package/es/components/content.js +16 -1
  394. package/es/components/style/form-number-input.js +7 -31
  395. package/es/components/style/form-select.js +8 -48
  396. package/es/components/style/form-text-input.js +12 -31
  397. package/es/components/viewer2d/area.js +1 -1
  398. package/es/components/viewer2d/line.js +13 -3
  399. package/es/components/viewer2d/scene.js +2 -2
  400. package/es/components/viewer2d/utils.js +0 -6
  401. package/es/components/viewer2d/viewer2d.js +33 -20
  402. package/es/components/viewer3d/libs/mtl-loader.js +2 -2
  403. package/es/components/viewer3d/libs/obj-loader.js +2 -2
  404. package/es/components/viewer3d/libs/orbit-controls.js +5 -6
  405. package/es/components/viewer3d/libs/pointer-lock-controls.js +4 -5
  406. package/es/components/viewer3d/ruler-utils/scene3D.js +0 -1
  407. package/es/components/viewer3d/scene-creator.js +22 -7
  408. package/es/components/viewer3d/viewer3d.js +279 -180
  409. package/es/devLiteRenderer.js +44 -0
  410. package/es/index.js +2 -2
  411. package/es/models.js +1 -2
  412. package/es/plugins/export.js +1 -3
  413. package/es/plugins/keyboard.js +2 -2
  414. package/es/reducers/holes-reducer.js +1 -1
  415. package/es/reducers/items-reducer.js +5 -2
  416. package/es/reducers/lines-reducer.js +1 -1
  417. package/es/reducers/project-reducer.js +1 -1
  418. package/es/reducers/reducer.js +2 -2
  419. package/es/reducers/scene-reducer.js +1 -1
  420. package/es/reducers/user-reducer.js +2 -1
  421. package/es/reducers/vertices-reducer.js +1 -1
  422. package/es/renderer.js +474 -0
  423. package/es/utils/geometry.js +61 -26
  424. package/es/utils/get-edges-of-subgraphs.js +1 -2
  425. package/es/utils/graph-cycles.js +3 -2
  426. package/es/utils/graph.js +1 -2
  427. package/es/utils/helper.js +68 -0
  428. package/es/version.js +1 -2
  429. package/lib/CrossSignOn.js +93 -0
  430. package/lib/KitchenConfigurator.js +817 -54
  431. package/lib/LiteKitchenConfigurator.js +641 -0
  432. package/lib/{KitchenConfiguratorApp.js → LiteRenderer.js} +5 -5
  433. package/lib/actions/export.js +5 -2
  434. package/lib/actions/user-actions.js +68 -0
  435. package/lib/analytics/ga4.js +194 -0
  436. package/lib/analytics/posthog.js +68 -0
  437. package/lib/assets/Window.hdr +2100 -0
  438. package/lib/assets/brown_photostudio_02_1k.hdr +0 -0
  439. package/lib/assets/fonts/Rene Bieder Milliard Black Italic.woff +0 -0
  440. package/lib/assets/fonts/Rene Bieder Milliard Black.woff +0 -0
  441. package/lib/assets/fonts/Rene Bieder Milliard Bold Italic.woff +0 -0
  442. package/lib/assets/fonts/Rene Bieder Milliard Bold.woff +0 -0
  443. package/lib/assets/fonts/Rene Bieder Milliard Book Italic.woff +0 -0
  444. package/lib/assets/fonts/Rene Bieder Milliard Book.woff +0 -0
  445. package/lib/assets/fonts/Rene Bieder Milliard ExtraBold Italic.woff +0 -0
  446. package/lib/assets/fonts/Rene Bieder Milliard ExtraBold.woff +0 -0
  447. package/lib/assets/fonts/Rene Bieder Milliard ExtraLight Italic.woff +0 -0
  448. package/lib/assets/fonts/Rene Bieder Milliard ExtraLight.woff +0 -0
  449. package/lib/assets/fonts/Rene Bieder Milliard Hairline Italic.woff +0 -0
  450. package/lib/assets/fonts/Rene Bieder Milliard Hairline.woff +0 -0
  451. package/lib/assets/fonts/Rene Bieder Milliard Heavy Italic.woff +0 -0
  452. package/lib/assets/fonts/Rene Bieder Milliard Heavy.woff +0 -0
  453. package/lib/assets/fonts/Rene Bieder Milliard Light Italic.woff +0 -0
  454. package/lib/assets/fonts/Rene Bieder Milliard Light.woff +0 -0
  455. package/lib/assets/fonts/Rene Bieder Milliard Medium Italic.woff +0 -0
  456. package/lib/assets/fonts/Rene Bieder Milliard Medium.woff +0 -0
  457. package/lib/assets/fonts/Rene Bieder Milliard SemiBold Italic.woff +0 -0
  458. package/lib/assets/fonts/Rene Bieder Milliard SemiBold.woff +0 -0
  459. package/lib/assets/fonts/Rene Bieder Milliard Thin Italic.woff +0 -0
  460. package/lib/assets/fonts/Rene Bieder Milliard Thin.woff +0 -0
  461. package/lib/assets/fonts/style.css +177 -0
  462. package/lib/assets/gltf/door_closet.bin +0 -0
  463. package/lib/assets/gltf/door_closet.fbx +0 -0
  464. package/lib/assets/gltf/door_closet.gltf +1 -0
  465. package/lib/assets/gltf/door_exterior.bin +0 -0
  466. package/lib/assets/gltf/door_exterior.fbx +0 -0
  467. package/lib/assets/gltf/door_exterior.gltf +1 -0
  468. package/lib/assets/gltf/door_interior.bin +0 -0
  469. package/lib/assets/gltf/door_interior.fbx +0 -0
  470. package/lib/assets/gltf/door_interior.gltf +1 -0
  471. package/lib/assets/gltf/door_sliding.bin +0 -0
  472. package/lib/assets/gltf/door_sliding.fbx +0 -0
  473. package/lib/assets/gltf/door_sliding.gltf +1 -0
  474. package/lib/assets/gltf/doorway_framed.bin +0 -0
  475. package/lib/assets/gltf/doorway_framed.fbx +0 -0
  476. package/lib/assets/gltf/doorway_framed.gltf +1 -0
  477. package/lib/assets/gltf/window_clear.bin +0 -0
  478. package/lib/assets/gltf/window_clear.fbx +0 -0
  479. package/lib/assets/gltf/window_clear.gltf +1 -0
  480. package/lib/assets/gltf/window_cross.bin +0 -0
  481. package/lib/assets/gltf/window_cross.fbx +0 -0
  482. package/lib/assets/gltf/window_cross.gltf +1 -0
  483. package/lib/assets/gltf/window_double_hung.bin +0 -0
  484. package/lib/assets/gltf/window_double_hung.fbx +0 -0
  485. package/lib/assets/gltf/window_double_hung.gltf +1 -0
  486. package/lib/assets/gltf/window_vertical.bin +0 -0
  487. package/lib/assets/gltf/window_vertical.fbx +0 -0
  488. package/lib/assets/gltf/window_vertical.gltf +1 -0
  489. package/lib/assets/img/1.jpg +0 -0
  490. package/lib/assets/img/TKC_thumbnail.png +0 -0
  491. package/lib/assets/img/Toggle.png +0 -0
  492. package/lib/assets/img/loading/loading.gif +0 -0
  493. package/lib/assets/img/loading/loading_1.svg +11 -0
  494. package/lib/assets/img/loading_large.gif +0 -0
  495. package/lib/assets/img/png/door/closet.png +0 -0
  496. package/lib/assets/img/png/door/doorwaysframed.png +0 -0
  497. package/lib/assets/img/png/door/doorwaysframeles.png +0 -0
  498. package/lib/assets/img/png/door/doorwaysframeless.png +0 -0
  499. package/lib/assets/img/png/door/exterior.png +0 -0
  500. package/lib/assets/img/png/door/interior.png +0 -0
  501. package/lib/assets/img/png/door/sliding.png +0 -0
  502. package/lib/assets/img/png/helper/outcome.png +0 -0
  503. package/lib/assets/img/png/helper/video_preview_3d.png +0 -0
  504. package/lib/assets/img/png/helper/video_preview_start.png +0 -0
  505. package/lib/assets/img/project_img.png +0 -0
  506. package/lib/assets/img/rta/rta_logo_box_blue.jpg +0 -0
  507. package/lib/assets/img/rta/rta_logo_box_blue_ico.jpg +0 -0
  508. package/lib/assets/img/rta/rta_logo_box_blue_ico.svg +55 -0
  509. package/lib/assets/img/rta/rta_logo_box_darkGray.jpg +0 -0
  510. package/lib/assets/img/rta/rta_logo_box_lightblue.png +0 -0
  511. package/lib/assets/img/rta/rta_logo_box_lightmaroon.png +0 -0
  512. package/lib/assets/img/rta/rta_logo_box_maroon.png +0 -0
  513. package/lib/assets/img/rta/rta_logo_box_white.png +0 -0
  514. package/lib/assets/img/rta_menu.png +0 -0
  515. package/lib/assets/img/step2.jpg +0 -0
  516. package/lib/assets/img/step3.jpg +0 -0
  517. package/lib/assets/img/step4.jpg +0 -0
  518. package/lib/assets/img/step5.jpg +0 -0
  519. package/lib/assets/img/step6.jpg +0 -0
  520. package/lib/assets/img/step7.jpg +0 -0
  521. package/lib/assets/img/step8.jpg +0 -0
  522. package/lib/assets/img/svg/2d_delete_object.svg +33 -0
  523. package/lib/assets/img/svg/2d_delete_object1.svg +33 -0
  524. package/lib/assets/img/svg/2d_lock_object.svg +33 -0
  525. package/lib/assets/img/svg/3d_item_move.svg +106 -0
  526. package/lib/assets/img/svg/3d_item_rotation.svg +76 -0
  527. package/lib/assets/img/svg/3d_item_warning_edit.svg +77 -0
  528. package/lib/assets/img/svg/3d_item_warning_info.svg +81 -0
  529. package/lib/assets/img/svg/accessories.svg +4 -0
  530. package/lib/assets/img/svg/angle_icon.svg +39 -0
  531. package/lib/assets/img/svg/blank_div.svg +14 -0
  532. package/lib/assets/img/svg/bottombar/2d3d_button.svg +3 -0
  533. package/lib/assets/img/svg/bottombar/2d3d_button_active.svg +3 -0
  534. package/lib/assets/img/svg/bottombar/2d3d_toggle.svg +4 -0
  535. package/lib/assets/img/svg/bottombar/2d3d_toggle_active.svg +4 -0
  536. package/lib/assets/img/svg/bottombar/arrow-down.svg +3 -0
  537. package/lib/assets/img/svg/bottombar/arrow-left.svg +3 -0
  538. package/lib/assets/img/svg/bottombar/arrow-minus.svg +3 -0
  539. package/lib/assets/img/svg/bottombar/arrow-plus.svg +11 -0
  540. package/lib/assets/img/svg/bottombar/arrow-right.svg +3 -0
  541. package/lib/assets/img/svg/bottombar/arrow-up.svg +3 -0
  542. package/lib/assets/img/svg/bottombar/collapse.svg +3 -0
  543. package/lib/assets/img/svg/bottombar/elevation-back.svg +6 -0
  544. package/lib/assets/img/svg/bottombar/elevation-front.svg +6 -0
  545. package/lib/assets/img/svg/bottombar/elevation-left.svg +6 -0
  546. package/lib/assets/img/svg/bottombar/elevation-right.svg +7 -0
  547. package/lib/assets/img/svg/bottombar/elevation.svg +6 -0
  548. package/lib/assets/img/svg/bottombar/expand.svg +3 -0
  549. package/lib/assets/img/svg/bottombar/help.svg +72 -0
  550. package/lib/assets/img/svg/bottombar/incm_toggle.svg +39 -0
  551. package/lib/assets/img/svg/bottombar/pan_1.svg +57 -0
  552. package/lib/assets/img/svg/bottombar/pan_2.svg +27 -0
  553. package/lib/assets/img/svg/bottombar/pan_3.svg +27 -0
  554. package/lib/assets/img/svg/bottombar/pan_4.svg +27 -0
  555. package/lib/assets/img/svg/bottombar/pan_5.svg +27 -0
  556. package/lib/assets/img/svg/bottombar/settings.svg +23 -0
  557. package/lib/assets/img/svg/bottombar/spin-down.svg +76 -0
  558. package/lib/assets/img/svg/bottombar/spin-left.svg +75 -0
  559. package/lib/assets/img/svg/bottombar/spin-right.svg +75 -0
  560. package/lib/assets/img/svg/bottombar/spin-up.svg +76 -0
  561. package/lib/assets/img/svg/bottombar/spin_1.svg +48 -0
  562. package/lib/assets/img/svg/bottombar/spin_2.svg +31 -0
  563. package/lib/assets/img/svg/bottombar/spin_3.svg +31 -0
  564. package/lib/assets/img/svg/bottombar/spin_4.svg +31 -0
  565. package/lib/assets/img/svg/bottombar/spin_5.svg +31 -0
  566. package/lib/assets/img/svg/bottombar/zoomin.svg +29 -0
  567. package/lib/assets/img/svg/bottombar/zoomout.svg +26 -0
  568. package/lib/assets/img/svg/check.svg +10 -0
  569. package/lib/assets/img/svg/close.svg +11 -0
  570. package/lib/assets/img/svg/color/Black.svg +3 -0
  571. package/lib/assets/img/svg/color/Blue.svg +3 -0
  572. package/lib/assets/img/svg/color/Brown.svg +9 -0
  573. package/lib/assets/img/svg/color/Cream.svg +3 -0
  574. package/lib/assets/img/svg/color/Dark.svg +9 -0
  575. package/lib/assets/img/svg/color/Gray.svg +3 -0
  576. package/lib/assets/img/svg/color/Green.svg +3 -0
  577. package/lib/assets/img/svg/color/Light.svg +9 -0
  578. package/lib/assets/img/svg/color/Medium.svg +9 -0
  579. package/lib/assets/img/svg/color/Unfinished.svg +9 -0
  580. package/lib/assets/img/svg/color/White.svg +3 -0
  581. package/lib/assets/img/svg/color/White.svg.bak +3 -0
  582. package/lib/assets/img/svg/color/stone2.jpg +0 -0
  583. package/lib/assets/img/svg/color/wood2.jpg +0 -0
  584. package/lib/assets/img/svg/copy.svg +11 -0
  585. package/lib/assets/img/svg/delete.svg +3 -0
  586. package/lib/assets/img/svg/detail.svg +77 -0
  587. package/lib/assets/img/svg/disclaimer/background.svg +758 -0
  588. package/lib/assets/img/svg/disclaimer/logo-dots.svg +11 -0
  589. package/lib/assets/img/svg/door/Closet.svg +11 -0
  590. package/lib/assets/img/svg/door/Exterior.svg +5 -0
  591. package/lib/assets/img/svg/door/Framed_dorway.svg +5 -0
  592. package/lib/assets/img/svg/door/Frameless_dorway.svg +5 -0
  593. package/lib/assets/img/svg/door/Interior.svg +7 -0
  594. package/lib/assets/img/svg/door/Sliding.svg +5 -0
  595. package/lib/assets/img/svg/doors_closet.svg +47 -0
  596. package/lib/assets/img/svg/doors_exterior.svg +25 -0
  597. package/lib/assets/img/svg/doors_interior.svg +29 -0
  598. package/lib/assets/img/svg/doors_patio.svg +26 -0
  599. package/lib/assets/img/svg/duplicate.svg +11 -0
  600. package/lib/assets/img/svg/duplicate_object_left.svg +32 -0
  601. package/lib/assets/img/svg/duplicate_object_right.svg +32 -0
  602. package/lib/assets/img/svg/filtersActive.svg +19 -0
  603. package/lib/assets/img/svg/firstsetting/L.svg +3 -0
  604. package/lib/assets/img/svg/firstsetting/L2.svg +3 -0
  605. package/lib/assets/img/svg/firstsetting/Open.svg +3 -0
  606. package/lib/assets/img/svg/firstsetting/Square.svg +3 -0
  607. package/lib/assets/img/svg/firstsetting/bar-active.svg +9 -0
  608. package/lib/assets/img/svg/firstsetting/bar-normal.svg +3 -0
  609. package/lib/assets/img/svg/firstsetting/bullet-current.svg +3 -0
  610. package/lib/assets/img/svg/firstsetting/bullet-done.svg +3 -0
  611. package/lib/assets/img/svg/firstsetting/bullet-not-done.svg +3 -0
  612. package/lib/assets/img/svg/firstsetting/check-active.svg +3 -0
  613. package/lib/assets/img/svg/firstsetting/check-normal.svg +3 -0
  614. package/lib/assets/img/svg/firstsetting/pencil.svg +11 -0
  615. package/lib/assets/img/svg/green_checkmark.svg +27 -0
  616. package/lib/assets/img/svg/headerbar/assist.svg +3 -0
  617. package/lib/assets/img/svg/headerbar/cart.svg +3 -0
  618. package/lib/assets/img/svg/headerbar/check.svg +10 -0
  619. package/lib/assets/img/svg/headerbar/consult_designer.svg +45 -0
  620. package/lib/assets/img/svg/headerbar/edit_name.svg +26 -0
  621. package/lib/assets/img/svg/headerbar/file-dollar.svg +13 -0
  622. package/lib/assets/img/svg/headerbar/hamburger_menu.svg +32 -0
  623. package/lib/assets/img/svg/headerbar/plus.svg +11 -0
  624. package/lib/assets/img/svg/headerbar/review_quote.svg +44 -0
  625. package/lib/assets/img/svg/headerbar/ruler-measure.svg +11 -0
  626. package/lib/assets/img/svg/headerbar/save.svg +3 -0
  627. package/lib/assets/img/svg/headerbar/setting.svg +75 -0
  628. package/lib/assets/img/svg/help/check.svg +10 -0
  629. package/lib/assets/img/svg/help/search.svg +76 -0
  630. package/lib/assets/img/svg/intro/1-start-with-floorplan-whole.svg +27 -0
  631. package/lib/assets/img/svg/intro/1-start-with-floorplan.svg +26 -0
  632. package/lib/assets/img/svg/intro/2-start-from-scratch-whole.svg +28 -0
  633. package/lib/assets/img/svg/intro/2-start-from-scratch.svg +27 -0
  634. package/lib/assets/img/svg/intro/3-retrieve-project-whole.svg +19 -0
  635. package/lib/assets/img/svg/intro/3-retrieve-project.svg +18 -0
  636. package/lib/assets/img/svg/invert.svg +127 -0
  637. package/lib/assets/img/svg/lefttoolbar/appliance-active.svg +13 -0
  638. package/lib/assets/img/svg/lefttoolbar/appliance.svg +13 -0
  639. package/lib/assets/img/svg/lefttoolbar/cabinet-active.svg +10 -0
  640. package/lib/assets/img/svg/lefttoolbar/cabinet-category.svg +3 -0
  641. package/lib/assets/img/svg/lefttoolbar/cabinet-one.svg +3 -0
  642. package/lib/assets/img/svg/lefttoolbar/cabinet.svg +10 -0
  643. package/lib/assets/img/svg/lefttoolbar/disigner_assistance.svg +89 -0
  644. package/lib/assets/img/svg/lefttoolbar/door-style-active.svg +20 -0
  645. package/lib/assets/img/svg/lefttoolbar/door-style.svg +20 -0
  646. package/lib/assets/img/svg/lefttoolbar/door.svg +12 -0
  647. package/lib/assets/img/svg/lefttoolbar/error_icon.svg +81 -0
  648. package/lib/assets/img/svg/lefttoolbar/finishing-active.svg +13 -0
  649. package/lib/assets/img/svg/lefttoolbar/finishing.svg +13 -0
  650. package/lib/assets/img/svg/lefttoolbar/reviewforquote-active.svg +86 -0
  651. package/lib/assets/img/svg/lefttoolbar/reviewforquote.svg +12 -0
  652. package/lib/assets/img/svg/lefttoolbar/room-shape-L.svg +3 -0
  653. package/lib/assets/img/svg/lefttoolbar/room-shape-active.svg +18 -0
  654. package/lib/assets/img/svg/lefttoolbar/room-shape-custom.svg +12 -0
  655. package/lib/assets/img/svg/lefttoolbar/room-shape-irregular.svg +3 -0
  656. package/lib/assets/img/svg/lefttoolbar/room-shape-open.svg +3 -0
  657. package/lib/assets/img/svg/lefttoolbar/room-shape-square.svg +3 -0
  658. package/lib/assets/img/svg/lefttoolbar/room-shape.svg +18 -0
  659. package/lib/assets/img/svg/lefttoolbar/search.svg +76 -0
  660. package/lib/assets/img/svg/lefttoolbar/view_more.svg +86 -0
  661. package/lib/assets/img/svg/lefttoolbar/warning_icon.svg +81 -0
  662. package/lib/assets/img/svg/lefttoolbar/window.svg +12 -0
  663. package/lib/assets/img/svg/menubar/login.svg +84 -0
  664. package/lib/assets/img/svg/menubar/my_projects.svg +85 -0
  665. package/lib/assets/img/svg/menubar/new_project.svg +110 -0
  666. package/lib/assets/img/svg/menubar/save_project.svg +84 -0
  667. package/lib/assets/img/svg/options.svg +3 -0
  668. package/lib/assets/img/svg/positioning.svg +3 -0
  669. package/lib/assets/img/svg/rotate.png +0 -0
  670. package/lib/assets/img/svg/rotate.svg +17 -0
  671. package/lib/assets/img/svg/rotate_object_clockwise.svg +26 -0
  672. package/lib/assets/img/svg/rotate_object_counterclockwise.svg +26 -0
  673. package/lib/assets/img/svg/toggleFilters.svg +19 -0
  674. package/lib/assets/img/svg/toolbar/add_appliances_active.svg +64 -0
  675. package/lib/assets/img/svg/toolbar/add_appliances_inactive.svg +52 -0
  676. package/lib/assets/img/svg/toolbar/add_button.svg +36 -0
  677. package/lib/assets/img/svg/toolbar/add_cabinets_active.svg +59 -0
  678. package/lib/assets/img/svg/toolbar/add_cabinets_inactive.svg +49 -0
  679. package/lib/assets/img/svg/toolbar/add_items_doors.svg +25 -0
  680. package/lib/assets/img/svg/toolbar/add_items_doorways.svg +24 -0
  681. package/lib/assets/img/svg/toolbar/add_items_refrigerator.svg +32 -0
  682. package/lib/assets/img/svg/toolbar/add_items_windows.svg +28 -0
  683. package/lib/assets/img/svg/toolbar/apply_button.svg +38 -0
  684. package/lib/assets/img/svg/toolbar/arrow-plus.svg +11 -0
  685. package/lib/assets/img/svg/toolbar/backsplash.svg +8 -0
  686. package/lib/assets/img/svg/toolbar/cancel_button.svg +37 -0
  687. package/lib/assets/img/svg/toolbar/consult_a_designer_button.svg +47 -0
  688. package/lib/assets/img/svg/toolbar/countertop.svg +7 -0
  689. package/lib/assets/img/svg/toolbar/dcm.png +0 -0
  690. package/lib/assets/img/svg/toolbar/dcm_off.svg +12 -0
  691. package/lib/assets/img/svg/toolbar/dcm_on.svg +474 -0
  692. package/lib/assets/img/svg/toolbar/delete_button.svg +37 -0
  693. package/lib/assets/img/svg/toolbar/download.svg +77 -0
  694. package/lib/assets/img/svg/toolbar/draw_custom_floor.svg +31 -0
  695. package/lib/assets/img/svg/toolbar/edit_button.svg +75 -0
  696. package/lib/assets/img/svg/toolbar/email_quote_button.svg +44 -0
  697. package/lib/assets/img/svg/toolbar/fbm.png +0 -0
  698. package/lib/assets/img/svg/toolbar/finishing_touches_active.svg +54 -0
  699. package/lib/assets/img/svg/toolbar/finishing_touches_inactive.svg +42 -0
  700. package/lib/assets/img/svg/toolbar/floorstyle.svg +9 -0
  701. package/lib/assets/img/svg/toolbar/fmb.png +0 -0
  702. package/lib/assets/img/svg/toolbar/fmb_off.svg +12 -0
  703. package/lib/assets/img/svg/toolbar/fmb_on.svg +489 -0
  704. package/lib/assets/img/svg/toolbar/furnishings_icon.svg +6 -0
  705. package/lib/assets/img/svg/toolbar/get_started_button.svg +41 -0
  706. package/lib/assets/img/svg/toolbar/handles.svg +5 -0
  707. package/lib/assets/img/svg/toolbar/lighting.svg +7 -0
  708. package/lib/assets/img/svg/toolbar/lrm.png +0 -0
  709. package/lib/assets/img/svg/toolbar/lrm_off.svg +12 -0
  710. package/lib/assets/img/svg/toolbar/lrm_on.svg +470 -0
  711. package/lib/assets/img/svg/toolbar/make_floorplan_active.svg +66 -0
  712. package/lib/assets/img/svg/toolbar/make_floorplan_inactive.svg +52 -0
  713. package/lib/assets/img/svg/toolbar/predefined_room_l_shaped.svg +20 -0
  714. package/lib/assets/img/svg/toolbar/predefined_room_layout.svg +20 -0
  715. package/lib/assets/img/svg/toolbar/predefined_room_long_narrow.svg +20 -0
  716. package/lib/assets/img/svg/toolbar/predefined_room_open_l_shape.svg +20 -0
  717. package/lib/assets/img/svg/toolbar/predefined_room_open_pentagon.svg +20 -0
  718. package/lib/assets/img/svg/toolbar/predefined_room_open_rectangle.svg +20 -0
  719. package/lib/assets/img/svg/toolbar/predefined_room_open_rectangle_2.svg +20 -0
  720. package/lib/assets/img/svg/toolbar/predefined_room_pentagon.svg +20 -0
  721. package/lib/assets/img/svg/toolbar/predefined_room_rectangle.svg +20 -0
  722. package/lib/assets/img/svg/toolbar/predefined_room_rectangle_with_alcove.svg +20 -0
  723. package/lib/assets/img/svg/toolbar/redo_button.svg +75 -0
  724. package/lib/assets/img/svg/toolbar/redo_button1.svg +75 -0
  725. package/lib/assets/img/svg/toolbar/review_quote_active.svg +14 -0
  726. package/lib/assets/img/svg/toolbar/review_quote_inactive.svg +44 -0
  727. package/lib/assets/img/svg/toolbar/save_project_button.svg +44 -0
  728. package/lib/assets/img/svg/toolbar/select_doorstyle_active.svg +67 -0
  729. package/lib/assets/img/svg/toolbar/select_doorstyle_inactive.svg +57 -0
  730. package/lib/assets/img/svg/toolbar/shopping-cart.svg +13 -0
  731. package/lib/assets/img/svg/toolbar/style_change_button.svg +47 -0
  732. package/lib/assets/img/svg/toolbar/take_picture.svg +75 -0
  733. package/lib/assets/img/svg/toolbar/undo_button.svg +76 -0
  734. package/lib/assets/img/svg/toolbar/undo_button1.svg +76 -0
  735. package/lib/assets/img/svg/toolbar/use_button.svg +37 -0
  736. package/lib/assets/img/svg/toolbar/wall_color_icon.svg +6 -0
  737. package/lib/assets/img/svg/topbar/edit_active.svg +10 -0
  738. package/lib/assets/img/svg/topbar/edit_inactive.svg +10 -0
  739. package/lib/assets/img/svg/topbar/redo_active.svg +42 -0
  740. package/lib/assets/img/svg/topbar/redo_inactive.svg +23 -0
  741. package/lib/assets/img/svg/topbar/select_all_active.svg +50 -0
  742. package/lib/assets/img/svg/topbar/select_all_inactive.svg +32 -0
  743. package/lib/assets/img/svg/topbar/take_picture_active.svg +51 -0
  744. package/lib/assets/img/svg/topbar/take_picture_inactive.svg +26 -0
  745. package/lib/assets/img/svg/topbar/undo_active.svg +42 -0
  746. package/lib/assets/img/svg/topbar/undo_inactive.svg +23 -0
  747. package/lib/assets/img/svg/warning_info_2d.svg +81 -0
  748. package/lib/assets/img/svg/window/Clear.svg +3 -0
  749. package/lib/assets/img/svg/window/Cross.svg +5 -0
  750. package/lib/assets/img/svg/window/Double_hung.svg +4 -0
  751. package/lib/assets/img/svg/window/Vertical.svg +4 -0
  752. package/lib/assets/img/svg/windows_clear.svg +23 -0
  753. package/lib/assets/img/svg/windows_cross.svg +28 -0
  754. package/lib/assets/img/svg/windows_double_hung.svg +24 -0
  755. package/lib/assets/img/svg/windows_vertical.svg +24 -0
  756. package/lib/assets/img/svg/wizardstep/Custom.svg +3 -0
  757. package/lib/assets/img/svg/wizardstep/Dashed_line.svg +3 -0
  758. package/lib/assets/img/svg/wizardstep/L.svg +3 -0
  759. package/lib/assets/img/svg/wizardstep/L2.svg +3 -0
  760. package/lib/assets/img/svg/wizardstep/Open.svg +3 -0
  761. package/lib/assets/img/svg/wizardstep/Square.svg +3 -0
  762. package/lib/assets/img/svg/wizardstep/bar-active.svg +9 -0
  763. package/lib/assets/img/svg/wizardstep/bar-normal.svg +3 -0
  764. package/lib/assets/img/svg/wizardstep/bullet-current.svg +3 -0
  765. package/lib/assets/img/svg/wizardstep/bullet-done.svg +3 -0
  766. package/lib/assets/img/svg/wizardstep/bullet-not-done.svg +3 -0
  767. package/lib/assets/img/svg/wizardstep/check-active.svg +3 -0
  768. package/lib/assets/img/svg/wizardstep/check-normal.svg +3 -0
  769. package/lib/assets/img/svg/wizardstep/detail_view.svg +87 -0
  770. package/lib/assets/img/svg/wizardstep/pencil.svg +11 -0
  771. package/lib/assets/img/svg/wizardstep/tile_view.svg +95 -0
  772. package/lib/assets/img/texture/glass.jpg +0 -0
  773. package/lib/assets/img/texture/steel.jpg +0 -0
  774. package/lib/assets/img/texture/white1px.jpg +0 -0
  775. package/lib/assets/img/texture/wood.jpg +0 -0
  776. package/lib/assets/model/DCM.bin +0 -0
  777. package/lib/assets/model/DCM.fbx +0 -0
  778. package/lib/assets/model/DCM.gltf +1 -0
  779. package/lib/assets/model/FBM.bin +0 -0
  780. package/lib/assets/model/FBM.fbx +0 -0
  781. package/lib/assets/model/FBM.gltf +1 -0
  782. package/lib/assets/model/LRM.bin +0 -0
  783. package/lib/assets/model/LRM.fbx +0 -0
  784. package/lib/assets/model/LRM.gltf +1 -0
  785. package/lib/assets/rtastore_logo.png +0 -0
  786. package/lib/catalog/areas/area/planner-element.js +8 -12
  787. package/lib/catalog/areas/area/textures/ceramic-tile.jpg +0 -0
  788. package/lib/catalog/areas/area/textures/grass.jpg +0 -0
  789. package/lib/catalog/areas/area/textures/parquet.jpg +0 -0
  790. package/lib/catalog/areas/area/textures/strand-porcelain.jpg +0 -0
  791. package/lib/catalog/areas/area/textures/tile1.jpg +0 -0
  792. package/lib/catalog/back.png +0 -0
  793. package/lib/catalog/doors.png +0 -0
  794. package/lib/catalog/doorways.png +0 -0
  795. package/lib/catalog/envMap/nx.hdr +0 -0
  796. package/lib/catalog/envMap/ny.hdr +0 -0
  797. package/lib/catalog/envMap/nz.hdr +0 -0
  798. package/lib/catalog/envMap/px.hdr +0 -0
  799. package/lib/catalog/envMap/py.hdr +0 -0
  800. package/lib/catalog/envMap/pz.hdr +0 -0
  801. package/lib/catalog/export.js +1 -0
  802. package/lib/catalog/holes/door-double/door_double.png +0 -0
  803. package/lib/catalog/holes/door-panic/panicDoor.png +0 -0
  804. package/lib/catalog/holes/door-panic-double/panicDoorDouble.png +0 -0
  805. package/lib/catalog/holes/gate/gate.jpg +0 -0
  806. package/lib/catalog/holes/window-clear/texture.png +0 -0
  807. package/lib/catalog/holes/window-cross/texture.png +0 -0
  808. package/lib/catalog/holes/window-double-hung/texture.png +0 -0
  809. package/lib/catalog/holes/window-vertical/texture.png +0 -0
  810. package/lib/catalog/lines/wall/planner-element.js +11 -15
  811. package/lib/catalog/lines/wall/textures/bricks-normal.jpg +0 -0
  812. package/lib/catalog/lines/wall/textures/bricks-normal2.jpg +0 -0
  813. package/lib/catalog/lines/wall/textures/bricks.jpg +0 -0
  814. package/lib/catalog/lines/wall/textures/bricks2.jpg +0 -0
  815. package/lib/catalog/lines/wall/textures/bricks3.jpg +0 -0
  816. package/lib/catalog/lines/wall/textures/morden-normal.jpg +0 -0
  817. package/lib/catalog/lines/wall/textures/morden.jpg +0 -0
  818. package/lib/catalog/lines/wall/textures/painted-normal.jpg +0 -0
  819. package/lib/catalog/lines/wall/textures/painted.jpg +0 -0
  820. package/lib/catalog/lines/wall/textures/plaster-normal.jpg +0 -0
  821. package/lib/catalog/lines/wall/textures/plaster.jpg +0 -0
  822. package/lib/catalog/lines/wall/wall.png +0 -0
  823. package/lib/catalog/molding/molding-dcm/planner-element.js +0 -5
  824. package/lib/catalog/molding/molding-dcm/texture.png +0 -0
  825. package/lib/catalog/molding/molding-fbm/planner-element.js +0 -5
  826. package/lib/catalog/molding/molding-fbm/texture.png +0 -0
  827. package/lib/catalog/molding/molding-lrm/planner-element.js +0 -5
  828. package/lib/catalog/molding/molding-lrm/texture.png +0 -0
  829. package/lib/catalog/properties/property-checkbox.js +18 -63
  830. package/lib/catalog/properties/property-enum.js +7 -49
  831. package/lib/catalog/properties/property-lenght-measure.js +1 -1
  832. package/lib/catalog/properties/property-length-measure.js +6 -50
  833. package/lib/catalog/utils/item-loader.js +1 -0
  834. package/lib/catalog/utils/mtl-loader.js +3 -7
  835. package/lib/catalog/utils/obj-loader.js +3 -7
  836. package/lib/catalog/windows.png +0 -0
  837. package/lib/class/item.js +8 -3
  838. package/lib/class/line.js +87 -52
  839. package/lib/class/project.js +4 -2
  840. package/lib/class/vertex.js +1 -1
  841. package/lib/components/content.js +16 -1
  842. package/lib/components/style/form-number-input.js +6 -30
  843. package/lib/components/style/form-select.js +9 -47
  844. package/lib/components/style/form-text-input.js +11 -30
  845. package/lib/components/viewer2d/area.js +1 -1
  846. package/lib/components/viewer2d/line.js +13 -3
  847. package/lib/components/viewer2d/scene.js +1 -1
  848. package/lib/components/viewer2d/utils.js +0 -6
  849. package/lib/components/viewer2d/viewer2d.js +32 -19
  850. package/lib/components/viewer3d/libs/mtl-loader.js +2 -7
  851. package/lib/components/viewer3d/libs/obj-loader.js +2 -7
  852. package/lib/components/viewer3d/libs/orbit-controls.js +5 -10
  853. package/lib/components/viewer3d/libs/pointer-lock-controls.js +4 -9
  854. package/lib/components/viewer3d/ruler-utils/scene3D.js +0 -1
  855. package/lib/components/viewer3d/scene-creator.js +22 -7
  856. package/lib/components/viewer3d/viewer3d.js +279 -180
  857. package/lib/devLiteRenderer.js +46 -0
  858. package/lib/index.js +2 -2
  859. package/lib/models.js +2 -3
  860. package/lib/plugins/export.js +0 -8
  861. package/lib/reducers/user-reducer.js +1 -0
  862. package/lib/renderer.js +478 -0
  863. package/lib/styles/tabs.css +40 -0
  864. package/lib/utils/geometry.js +63 -26
  865. package/lib/utils/get-edges-of-subgraphs.js +1 -7
  866. package/lib/utils/graph-cycles.js +9 -9
  867. package/lib/utils/graph.js +3 -9
  868. package/lib/utils/helper.js +69 -1
  869. package/lib/version.js +1 -2
  870. package/package.json +30 -11
  871. package/es/components/disclaimer/disclaimer.js +0 -97
  872. package/es/components/export.js +0 -9
  873. package/es/plugins/autosave.js +0 -33
  874. package/lib/components/disclaimer/disclaimer.js +0 -106
  875. package/lib/components/export.js +0 -33
  876. package/lib/plugins/autosave.js +0 -40
@@ -20,6 +20,7 @@ import { disposeObject, disposeScene } from "./three-memory-cleaner";
20
20
  import diff from 'immutablediff';
21
21
  import * as SharedStyle from "../../shared-style";
22
22
  import { BASE_CABINET_LAYOUTPOS, MODE_3D_VIEW, MODE_DRAGGING_ITEM_3D, MODE_DRAWING_HOLE_3D, MODE_DRAWING_ITEM_3D, MODE_ELEVATION_VIEW, MODE_IDLE_3D, MODE_ROTATING_ITEM_3D, SECONDARY_PURPLE_COLOR, TALL_CABINET_LAYOUTPOS, UNIT_CENTIMETER, WALL_CABINET_LAYOUTPOS } from "../../constants";
23
+ import { isUndefined } from 'util';
23
24
  import { verticesDistance } from "../../utils/geometry";
24
25
  import { convert } from "../../utils/convert-units-lite";
25
26
  import { GeometryUtils } from "../../utils/export";
@@ -270,7 +271,7 @@ var Scene3DViewer = /*#__PURE__*/function (_React$Component) {
270
271
  lines.push(data);
271
272
  });
272
273
  var _loop3 = function _loop3() {
273
- var data = lines[_i17];
274
+ var data = lines[_i15];
274
275
  var realVec = [];
275
276
  data.vertices.forEach(function (vec) {
276
277
  realVec.push(vec);
@@ -281,7 +282,7 @@ var Scene3DViewer = /*#__PURE__*/function (_React$Component) {
281
282
  return 1; // break
282
283
  }
283
284
  };
284
- for (var _i17 = 0; _i17 < lines.length; _i17++) {
285
+ for (var _i15 = 0; _i15 < lines.length; _i15++) {
285
286
  if (_loop3()) break;
286
287
  }
287
288
  var vertices = [];
@@ -291,11 +292,11 @@ var Scene3DViewer = /*#__PURE__*/function (_React$Component) {
291
292
  });
292
293
  vertices.push(vertices[0]);
293
294
  var fLen = vertices.length - 1;
294
- for (var _i18 = 0; _i18 < fLen; _i18++) {
295
- var sX = vertices[_i18].x;
296
- var sY = vertices[_i18].y;
297
- var eX = vertices[_i18 + 1].x;
298
- var eY = vertices[_i18 + 1].y;
295
+ for (var _i16 = 0; _i16 < fLen; _i16++) {
296
+ var sX = vertices[_i16].x;
297
+ var sY = vertices[_i16].y;
298
+ var eX = vertices[_i16 + 1].x;
299
+ var eY = vertices[_i16 + 1].y;
299
300
  var len = Math.sqrt((eX - sX) * (eX - sX) + (eY - sY) * (eY - sY));
300
301
  for (var cLen = 200; cLen < len; cLen += 200) {
301
302
  var cX = sX + (eX - sX) * cLen / len;
@@ -372,6 +373,9 @@ var Scene3DViewer = /*#__PURE__*/function (_React$Component) {
372
373
  var allRect;
373
374
  var allArea;
374
375
 
376
+ // FLAG FOR initial phase of drawing an item
377
+ var isInitialPhase = true;
378
+
375
379
  // end snap function variable///////////////////////
376
380
  var backsplashVisible = false;
377
381
  var holeItems = GeometryUtils.getHoleItems(layer);
@@ -649,7 +653,6 @@ var Scene3DViewer = /*#__PURE__*/function (_React$Component) {
649
653
  item: _item2,
650
654
  cat: ocat
651
655
  };
652
- console.log('currentItem =>', currentItem);
653
656
  if (GeometryUtils.needSnap(currentItem, otherItem) && otherItem.cat.type != 'cabinet') {
654
657
  var tRot = _item2.rotation;
655
658
  var tPos = new Three.Vector2(_item2.x, _item2.y);
@@ -1286,7 +1289,7 @@ var Scene3DViewer = /*#__PURE__*/function (_React$Component) {
1286
1289
  offsetX: event.offsetX - 50,
1287
1290
  offsetY: event.offsetY
1288
1291
  }, alti);
1289
- if (!selectedItem) return;
1292
+ if (isUndefined(selectedItem)) return;
1290
1293
  var selItem = _this2.props.state.scene.layers.get(selectedObject.layerID).items.get(selectedObject.itemID);
1291
1294
  lastAngle = 0;
1292
1295
  angleObj.position.set(planData.plan.position.x + Point.x, selItem.category === 'lighting' ? -planData.plan.position.y - selItem.properties.get('height').get('length') : selItem.properties.get('altitude').get('length') + planData.plan.position.y, planData.plan.position.z - Point.y);
@@ -1351,7 +1354,6 @@ var Scene3DViewer = /*#__PURE__*/function (_React$Component) {
1351
1354
  if (!_this2.props.downloadFlag && !_this2.props.state.mode.includes('ING')) {
1352
1355
  _this2.props.setToolbar('');
1353
1356
  }
1354
- getPoint(event, altitude);
1355
1357
  if (_this2.props.state.mode == MODE_DRAWING_ITEM_3D) {
1356
1358
  if (Point.x > _this2.props.state.scene.width) Point.x = _this2.props.state.width;
1357
1359
  if (Point.y > _this2.props.state.scene.height) Point.y = _this2.props.state.height;
@@ -1361,9 +1363,9 @@ var Scene3DViewer = /*#__PURE__*/function (_React$Component) {
1361
1363
  actions.itemsActions.endDrawingItem(_this2.props.state.scene.selectedLayer, sPoint.x, sPoint.y);
1362
1364
  } else {
1363
1365
  removeSnapBox();
1364
- var polygon = lineRect(layer);
1366
+ var polygon = GeometryUtils.getPoylgonPoints(layer);
1365
1367
  // if cursor is outside of room
1366
- if (!GeometryUtils.ContainsPoint(polygon, Point.x, Point.y)) {
1368
+ if (polygon.length > 0 && !GeometryUtils.ContainsPoint(polygon, Point.x, Point.y)) {
1367
1369
  actions.itemsActions.endDrawingItem(_this2.props.state.scene.selectedLayer, sPoint.x, sPoint.y);
1368
1370
  } else {
1369
1371
  actions.itemsActions.updateDraggingItemChanged(targetPoint.x, -targetPoint.z, selectedObject.layerID, selectedObject.itemID);
@@ -1372,6 +1374,7 @@ var Scene3DViewer = /*#__PURE__*/function (_React$Component) {
1372
1374
  }
1373
1375
  }
1374
1376
  bMove = false;
1377
+ isInitialPhase = true;
1375
1378
  return;
1376
1379
  }
1377
1380
  if (_this2.props.state.mode == MODE_DRAGGING_ITEM_3D) {
@@ -1380,6 +1383,7 @@ var Scene3DViewer = /*#__PURE__*/function (_React$Component) {
1380
1383
  if (_this2.props.state.mode == MODE_ROTATING_ITEM_3D) {
1381
1384
  _this2.context.itemsActions.endRotatingItem3D(sPoint.x, sPoint.y);
1382
1385
  }
1386
+ getPoint(event, altitude);
1383
1387
  if (_this2.props.state.mode == MODE_DRAWING_HOLE_3D) {
1384
1388
  gridPlanOrigin = gridPlane.position;
1385
1389
  gridMatrix.copy(gridPlane.matrixWorld).invert();
@@ -1457,7 +1461,7 @@ var Scene3DViewer = /*#__PURE__*/function (_React$Component) {
1457
1461
  setTimeout(function () {
1458
1462
  getDistances(layer);
1459
1463
  var selectedItem = planData.sceneGraph.layers[selectedObject.layerID].items[selectedObject.itemID];
1460
- if (!selectedItem) return;
1464
+ if (isUndefined(selectedItem)) return;
1461
1465
  var selItem = _this2.props.state.scene.layers.get(selectedObject.layerID).items.get(selectedObject.itemID);
1462
1466
  var itemPos = selectedItem.position.clone();
1463
1467
  if (intersects[_i10].object.parent && intersects[_i10].object.parent.parent.userData.itemId === selectedItem.userData.itemId) {
@@ -1539,7 +1543,7 @@ var Scene3DViewer = /*#__PURE__*/function (_React$Component) {
1539
1543
  if (bRotate) {
1540
1544
  var _intersects$_i;
1541
1545
  var selectedItem = planData.sceneGraph.layers[selectedObject.layerID].items[selectedObject.itemID];
1542
- if (!selectedItem) return;
1546
+ if (isUndefined(selectedItem)) return;
1543
1547
  var selItem = _this2.props.state.scene.layers.get(selectedObject.layerID).items.get(selectedObject.itemID);
1544
1548
  var itemPos = selectedItem.position.clone();
1545
1549
  if (((_intersects$_i = intersects[_i10]) === null || _intersects$_i === void 0 || (_intersects$_i = _intersects$_i.object) === null || _intersects$_i === void 0 || (_intersects$_i = _intersects$_i.parent) === null || _intersects$_i === void 0 || (_intersects$_i = _intersects$_i.parent) === null || _intersects$_i === void 0 || (_intersects$_i = _intersects$_i.userData) === null || _intersects$_i === void 0 ? void 0 : _intersects$_i.itemId) === selectedItem.userData.itemId) {
@@ -1557,7 +1561,7 @@ var Scene3DViewer = /*#__PURE__*/function (_React$Component) {
1557
1561
  if (bMove) {
1558
1562
  bMove = false;
1559
1563
  var _selectedItem = planData.sceneGraph.layers[selectedObject.layerID].items[selectedObject.itemID];
1560
- if (!_selectedItem) return;
1564
+ if (isUndefined(_selectedItem)) return;
1561
1565
  var _selItem = _this2.props.state.scene.layers.get(selectedObject.layerID).items.get(selectedObject.itemID);
1562
1566
  var _itemPos = _selectedItem.position.clone();
1563
1567
  if (intersects[_i10].object.parent.parent.userData.itemId === _selectedItem.userData.itemId) {
@@ -1598,6 +1602,164 @@ var Scene3DViewer = /*#__PURE__*/function (_React$Component) {
1598
1602
  }
1599
1603
  }
1600
1604
  };
1605
+ this.mouseEnterEvent = function (event) {
1606
+ if (_this2.props.state.mode !== MODE_DRAWING_ITEM_3D) return;
1607
+ // if not initial moment of drawing an item
1608
+ if (!isInitialPhase) return;
1609
+ var bNormalFlow = true;
1610
+ _this2.getSelectedObject();
1611
+ var layer = _this2.props.state.scene.getIn(['layers', selectedObject.layerID]);
1612
+ var mX = Point.x - sPoint.x;
1613
+ var mY = Point.y - sPoint.y;
1614
+ var item3D = planData.sceneGraph.layers[selectedObject.layerID].items[selectedObject.itemID];
1615
+ deleteSpecifiedMeshObjects('TransformBox');
1616
+ deleteSpecifiedMeshObjects('WarningBox' + selectedObject.itemID);
1617
+ var item = layer.getIn(['items', selectedObject.itemID]);
1618
+ if (!item3D || !item) return;
1619
+ if (item.counterTop.uri == '') item.counterTop.uri = layer.counterTop.uri;
1620
+ var sRot = item.rotation;
1621
+ var originPos = item3D.position.clone();
1622
+ var tPos = new Three.Vector2(mX + originPos.x, mY - originPos.z);
1623
+ var sBounding = item3D.children[0].userData;
1624
+ var swidth = sBounding.max.x - sBounding.min.x;
1625
+ var sdepth = sBounding.max.z - sBounding.min.z;
1626
+ var sVertices = _this2.getRectPoints(swidth, sdepth, tPos.clone(), sRot % 360 / 180 * Math.PI);
1627
+ prepareSnap(layer);
1628
+
1629
+ // calc altitude
1630
+ var altitude = 0;
1631
+ if (allItemRect && allItemRect.cur && allItemRect.cur.itemInfo !== undefined) {
1632
+ var properties = allItemRect.cur.itemInfo.properties;
1633
+ altitude = properties.getIn(['altitude', '_length']);
1634
+ var unit = properties.getIn(['altitude', '_unit']) || 'in';
1635
+ altitude = convert(altitude).from(unit).to(_this2.props.state.scene.unit);
1636
+ }
1637
+ // We need to set cam position since when MODE_DRAWING_ITEM_3D mouse down event
1638
+ // is not emited so cam position is not valid
1639
+ gridPlanOrigin = gridPlane.position;
1640
+ gridMatrix.copy(gridPlane.matrixWorld).invert();
1641
+ camPos = camera.position;
1642
+
1643
+ // calc cursor position
1644
+ getPoint(event, altitude);
1645
+ var polygon = GeometryUtils.getPoylgonPoints(layer);
1646
+
1647
+ // if no wall (no area)
1648
+ if (!polygon.length) {
1649
+ // place the item at cursor position
1650
+ actions.itemsActions.updateDraggingItemChanged(Point.x, Point.y, selectedObject.layerID, selectedObject.itemID);
1651
+ return;
1652
+ }
1653
+
1654
+ // calc snap
1655
+ var _GeometryUtils$calcCr = GeometryUtils.calcCreateSnap(allItemRect, allItemSnap, allLineRects, allLineSnap, allRect, Point.x, Point.y, polygon),
1656
+ cx = _GeometryUtils$calcCr.cx,
1657
+ cy = _GeometryUtils$calcCr.cy,
1658
+ crot = _GeometryUtils$calcCr.crot,
1659
+ rotRad = _GeometryUtils$calcCr.rotRad;
1660
+ var finalPosition = {
1661
+ x: cx,
1662
+ y: cy,
1663
+ rot: crot,
1664
+ rotRad: rotRad
1665
+ };
1666
+
1667
+ // calc current item rect
1668
+ var itemRect = _objectSpread(_objectSpread({}, allItemRect.cur), {}, {
1669
+ pos: {
1670
+ x: Point.x,
1671
+ y: Point.y
1672
+ }
1673
+ });
1674
+
1675
+ // if cursor position is inside the room
1676
+ if (GeometryUtils.ContainsPoint(polygon, Point.x, Point.y)) {
1677
+ // if cursor position is available to place the item
1678
+ if (GeometryUtils.validRect(itemRect, allRect)) {
1679
+ actions.itemsActions.updateDraggingItemChanged(Point.x, Point.y, selectedObject.layerID, selectedObject.itemID);
1680
+ sPoint.set(Point.x, Point.y);
1681
+ bNormalFlow = false;
1682
+ }
1683
+ } else {
1684
+ // if cursor is outside the room and there is no snap candidate,
1685
+ // then place the item at any free position inside the room.
1686
+ if (!GeometryUtils.ContainsPoint(polygon, cx, cy)) {
1687
+ var points = [];
1688
+ var point = [];
1689
+
1690
+ // rebuild variable to be passed to getCentriodOfPolygon
1691
+ // polygon: [ x0, y0, x1, y1, ... ] ==> points: [[x0, y0], [x1, y1], ...]
1692
+ polygon === null || polygon === void 0 || polygon.forEach(function (value, index) {
1693
+ point.push(value);
1694
+ if (index % 2) {
1695
+ points.push(point);
1696
+ point = [];
1697
+ }
1698
+ });
1699
+
1700
+ // calc center position of the room
1701
+ var centerPos = GeometryUtils.getCentroidOfPolygon(points);
1702
+ var itemRect1 = _objectSpread(_objectSpread({}, allItemRect.cur), {}, {
1703
+ pos: {
1704
+ x: centerPos.x,
1705
+ y: centerPos.y
1706
+ }
1707
+ });
1708
+ var itemRect2 = _objectSpread(_objectSpread({}, allItemRect.cur), {}, {
1709
+ pos: {
1710
+ x: centerPos.x,
1711
+ y: centerPos.y
1712
+ },
1713
+ rotRad: allItemRect.cur.rotRad + Math.PI / 2
1714
+ });
1715
+
1716
+ // find a free position in the room
1717
+ if (GeometryUtils.validRect(itemRect1, allRect)) {
1718
+ actions.itemsActions.updateDraggingItemChanged(centerPos.x, centerPos.y, selectedObject.layerID, selectedObject.itemID);
1719
+ sPoint.set(centerPos.x, centerPos.y);
1720
+ bNormalFlow = false;
1721
+ } else if (GeometryUtils.validRect(itemRect2, allRect)) {
1722
+ finalPosition = {
1723
+ x: centerPos.x,
1724
+ y: centerPos.y,
1725
+ rotRad: itemRect2.rotRad,
1726
+ rot: itemRect2.rotRad / Math.PI * 180
1727
+ };
1728
+ sPoint.set(centerPos.x, centerPos.y);
1729
+ }
1730
+ }
1731
+ }
1732
+ var nPos = new Three.Vector2(cx, cy);
1733
+ if (!_this2.collisionHoleCheck(item3D, nPos, item.rotation, {
1734
+ userData: {
1735
+ itemId: null
1736
+ }
1737
+ }, item, _this2.context.catalog)) {
1738
+ _this2.collisionSlide(item3D, originPos, layer, sVertices, tPos, item);
1739
+ }
1740
+ itemRect = _objectSpread(_objectSpread({}, allItemRect.cur), {}, {
1741
+ pos: {
1742
+ x: finalPosition.x,
1743
+ y: finalPosition.y
1744
+ },
1745
+ rotRad: finalPosition.rotRad
1746
+ });
1747
+
1748
+ // if the room is fullfilled with items or can't calc snap correctly
1749
+ if (!GeometryUtils.validRect(itemRect, allRect)) {
1750
+ // then place the item at cursor position
1751
+ actions.itemsActions.updateDraggingItemChanged(Point.x, Point.y, selectedObject.layerID, selectedObject.itemID);
1752
+ sPoint.set(Point.x, Point.y);
1753
+ bNormalFlow = false;
1754
+ }
1755
+ if (bNormalFlow) {
1756
+ actions.itemsActions.updateDraggingItemChanged(finalPosition.x, finalPosition.y, selectedObject.layerID, selectedObject.itemID);
1757
+ actions.itemsActions.updateRotatingItemChanged(finalPosition.rot, selectedObject.layerID, selectedObject.itemID);
1758
+ sPoint.set(finalPosition.x, finalPosition.y);
1759
+ }
1760
+ isInitialPhase = false;
1761
+ _this2.handleAfterMovingItem();
1762
+ };
1601
1763
  this.mouseMoveEvent = function (event) {
1602
1764
  event.preventDefault();
1603
1765
  backsplashVisible = false;
@@ -1638,49 +1800,22 @@ var Scene3DViewer = /*#__PURE__*/function (_React$Component) {
1638
1800
  camPos = camera.position;
1639
1801
  getPoint(event, altitude);
1640
1802
  if (Point.x > _this2.props.state.scene.width || Point.x < 0 || Point.y > _this2.props.state.scene.height || Point.y < 0) return;
1641
- var _layerID = _this2.props.state.scene.selectedLayer;
1642
- selectedObject = {
1643
- layerID: _layerID
1644
- };
1645
- var _layer = _this2.props.state.scene.getIn(['layers', selectedObject.layerID]);
1646
- var polygon = lineRect(_layer);
1647
- var isCursorInArea = GeometryUtils.ContainsPoint(polygon, Point.x, Point.y);
1803
+ _this2.getSelectedObject();
1648
1804
  var _drawingSupport = _this2.props.state.drawingSupport;
1649
1805
  if (!_drawingSupport.has('currentID')) {
1650
- var initialX = Point.x,
1651
- initialY = Point.y;
1652
-
1653
- // if cursor is outside the room area,
1654
- // place the item at center of room area.
1655
- if (!isCursorInArea && polygon.length > 0) {
1656
- // rebuild polygon variable to be suitable for getCentroid() function
1657
- var points = [];
1658
- var point = [];
1659
- polygon === null || polygon === void 0 || polygon.forEach(function (value, index) {
1660
- point.push(value);
1661
- if (index % 2 === 1) {
1662
- points.push(point);
1663
- point = [];
1664
- }
1665
- });
1666
- var centroid = GeometryUtils.getCentroidOfPolygon(points);
1667
- initialX = centroid[0];
1668
- initialY = centroid[1];
1669
- }
1670
- _this2.context.itemsActions.updateDrawingItem(_this2.props.state.scene.selectedLayer, initialX, initialY);
1671
- sPoint.set(initialX, initialY);
1806
+ _this2.context.itemsActions.updateDrawingItem(selectedObject.layerID, Point.x, Point.y);
1807
+ sPoint.set(Point.x, Point.y);
1672
1808
  } else {
1673
- var itemID = _this2.props.state.drawingSupport.get('currentID');
1674
- selectedObject.itemID = itemID;
1675
1809
  var mX = Point.x - sPoint.x;
1676
1810
  var mY = Point.y - sPoint.y;
1811
+ var _layer = _this2.props.state.scene.getIn(['layers', selectedObject.layerID]);
1677
1812
  var item3D = planData.sceneGraph.layers[selectedObject.layerID].items[selectedObject.itemID];
1678
1813
  deleteSpecifiedMeshObjects('TransformBox');
1679
- deleteSpecifiedMeshObjects('WarningBox' + itemID);
1680
- var item = _layer.items.getIn([selectedObject.itemID]);
1814
+ deleteSpecifiedMeshObjects('WarningBox' + selectedObject.itemID);
1815
+ var item = _layer.getIn(['items', selectedObject.itemID]);
1816
+ if (!item3D || !item) return;
1681
1817
  if (item.counterTop.uri == '') item.counterTop.uri = _layer.counterTop.uri;
1682
1818
  var sRot = item.rotation;
1683
- if (!item3D) return;
1684
1819
  var originPos = item3D.position.clone();
1685
1820
  var tPos = new Three.Vector2(mX + originPos.x, mY - originPos.z);
1686
1821
  var sBounding = item3D.children[0].userData;
@@ -1699,78 +1834,28 @@ var Scene3DViewer = /*#__PURE__*/function (_React$Component) {
1699
1834
  }
1700
1835
  }, item, _this2.context.catalog)) {
1701
1836
  _this2.collisionSlide(item3D, originPos, _layer, sVertices, tPos, item);
1702
- //return;
1703
1837
  }
1704
- if (polygon.length > 0) {
1705
- var PolygonSect = GeometryUtils.ContainsPoint(polygon, _nx, _ny);
1838
+ var polygonPoint = GeometryUtils.getPoylgonPoints(_layer);
1839
+ if (polygonPoint.length > 0) {
1840
+ var PolygonSect = GeometryUtils.ContainsPoint(polygonPoint, _nx, _ny);
1706
1841
  if (!PolygonSect) {
1707
- var _GeometryUtils$calcCr = GeometryUtils.calcCreateSnap(allItemRect, allItemSnap, allLineRects, allLineSnap, allRect, Point.x, Point.y, polygon),
1708
- cx = _GeometryUtils$calcCr.cx,
1709
- cy = _GeometryUtils$calcCr.cy,
1710
- crot = _GeometryUtils$calcCr.crot;
1842
+ var _GeometryUtils$calcCr2 = GeometryUtils.calcCreateSnap(allItemRect, allItemSnap, allLineRects, allLineSnap, allRect, Point.x, Point.y, polygonPoint),
1843
+ cx = _GeometryUtils$calcCr2.cx,
1844
+ cy = _GeometryUtils$calcCr2.cy,
1845
+ crot = _GeometryUtils$calcCr2.crot;
1711
1846
  _nx = cx;
1712
1847
  _ny = cy;
1713
1848
  rot = crot;
1714
1849
  }
1715
1850
  }
1716
- if (polygon.length > 0) {
1717
- var isSnapInArea = GeometryUtils.ContainsPoint(polygon, _nx, _ny);
1718
- if (!isSnapInArea) return;
1851
+ if (polygonPoint.length > 0) {
1852
+ var isSect = GeometryUtils.ContainsPoint(polygonPoint, _nx, _ny);
1853
+ if (!isSect) return;
1719
1854
  }
1720
1855
  actions.itemsActions.updateDraggingItemChanged(_nx, _ny, selectedObject.layerID, selectedObject.itemID);
1721
1856
  actions.itemsActions.updateRotatingItemChanged(rot, selectedObject.layerID, selectedObject.itemID);
1722
1857
  sPoint.set(_nx, _ny);
1723
- getDistances(_layer);
1724
- var pointArray = [],
1725
- cnt = 0;
1726
- pointArray.push([fVLine[0].userData.distance, 90]);
1727
- pointArray.push([fVLine[1].userData.distance, -90]);
1728
- pointArray.push([fVLine[2].userData.distance, 180]);
1729
- pointArray.push([fVLine[3].userData.distance, 0]);
1730
- pointArray.forEach(function (pointElement, index) {
1731
- if (pointElement[0] == undefined) pointArray[index][0] = 0;
1732
- });
1733
- pointArray.forEach(function (pointElement) {
1734
- if (pointElement[0] == 0) cnt++;
1735
- });
1736
- if (cnt == 4 || cnt == 3) {
1737
- pointArray[0][0] = 100;
1738
- pointArray[1][0] = 100;
1739
- }
1740
- actions.itemsActions.storeDistArray(_layer.id, item.id, pointArray);
1741
- var minDis = fVLine[0].userData.distance;
1742
- var snapObj = fVLine[0];
1743
- var iPos = item3D.position.clone();
1744
- var snapDis = Math.sqrt((iPos.x - targetPoint.x) * (iPos.x - targetPoint.x) + (iPos.z - targetPoint.z) * (iPos.z - targetPoint.z));
1745
- if (snapDis >= 100 && snapObj != null) {
1746
- removeSnapBox();
1747
- backsplashVisible = false;
1748
- //console.log('1 snap no');
1749
- }
1750
- for (var _i11 = 1; _i11 < fVLine.length; _i11++) {
1751
- if (minDis > fVLine[_i11].userData.distance) {
1752
- minDis = fVLine[_i11].userData.distance;
1753
- snapObj = fVLine[_i11];
1754
- }
1755
- }
1756
- if (snapBox == null) {
1757
- snapFlag = false;
1758
- }
1759
- actions.sceneActions.updateMovingState(false);
1760
- if (minDis < snapDelta && !snapFlag) {
1761
- _this2.snap(snapObj, _layer);
1762
- snapFlag = true;
1763
- //console.log('1 snap Yes')
1764
- getDistances(_layer, true);
1765
- var _i12 = 0;
1766
- for (_i12 = 0; _i12 < fVLine.length; _i12++) {
1767
- if (fVLine[_i12].userData.distance < snapDelta) {
1768
- break;
1769
- }
1770
- }
1771
- if (_i12 === fVLine.length) backsplashVisible = false;else backsplashVisible = true;
1772
- }
1773
- actions.itemsActions.setBacksplashVisible(selectedObject.itemID, backsplashVisible);
1858
+ _this2.handleAfterMovingItem();
1774
1859
  }
1775
1860
  }
1776
1861
  if (bRotate) {
@@ -1838,78 +1923,28 @@ var Scene3DViewer = /*#__PURE__*/function (_React$Component) {
1838
1923
  _this2.collisionSlide(_item3D2, _originPos, _layer3, _sVertices, _tPos4, _item5);
1839
1924
  //return;
1840
1925
  }
1841
- var polygonPoint = lineRect(_layer3);
1842
- if (polygonPoint.length > 0) {
1843
- var _PolygonSect = GeometryUtils.ContainsPoint(polygonPoint, _nx3, _ny3);
1926
+ var _polygonPoint = GeometryUtils.getPoylgonPoints(_layer3);
1927
+ if (_polygonPoint.length > 0) {
1928
+ var _PolygonSect = GeometryUtils.ContainsPoint(_polygonPoint, _nx3, _ny3);
1844
1929
  if (!_PolygonSect) {
1845
- var _GeometryUtils$calcCr2 = GeometryUtils.calcCreateSnap(allItemRect, allItemSnap, allLineRects, allLineSnap, allRect, Point.x, Point.y, polygonPoint),
1846
- _cx3 = _GeometryUtils$calcCr2.cx,
1847
- _cy = _GeometryUtils$calcCr2.cy,
1848
- _crot = _GeometryUtils$calcCr2.crot;
1930
+ var _GeometryUtils$calcCr3 = GeometryUtils.calcCreateSnap(allItemRect, allItemSnap, allLineRects, allLineSnap, allRect, Point.x, Point.y, _polygonPoint),
1931
+ _cx3 = _GeometryUtils$calcCr3.cx,
1932
+ _cy = _GeometryUtils$calcCr3.cy,
1933
+ _crot = _GeometryUtils$calcCr3.crot;
1849
1934
  _nx3 = _cx3;
1850
1935
  _ny3 = _cy;
1851
1936
  _rot = _crot;
1852
1937
  }
1853
1938
  }
1854
- var _polygon = lineRect(_layer3);
1855
- if (_polygon.length > 0) {
1856
- var Sect = GeometryUtils.ContainsPoint(_polygon, _nx3, _ny3);
1939
+ var polygon = GeometryUtils.getPoylgonPoints(_layer3);
1940
+ if (polygon.length > 0) {
1941
+ var Sect = GeometryUtils.ContainsPoint(polygon, _nx3, _ny3);
1857
1942
  if (!Sect) return;
1858
1943
  }
1859
1944
  actions.itemsActions.updateDraggingItemChanged(_nx3, _ny3, selectedObject.layerID, selectedObject.itemID);
1860
1945
  actions.itemsActions.updateRotatingItemChanged(_rot, selectedObject.layerID, selectedObject.itemID);
1861
1946
  sPoint.set(_nx3, _ny3);
1862
- getDistances(_layer3);
1863
- var _pointArray = [],
1864
- _cnt = 0;
1865
- _pointArray.push([fVLine[0].userData.distance, 90]);
1866
- _pointArray.push([fVLine[1].userData.distance, -90]);
1867
- _pointArray.push([fVLine[2].userData.distance, 180]);
1868
- _pointArray.push([fVLine[3].userData.distance, 0]);
1869
- _pointArray.forEach(function (pointElement, index) {
1870
- if (pointElement[0] == undefined) _pointArray[index][0] = 0;
1871
- });
1872
- _pointArray.forEach(function (pointElement) {
1873
- if (pointElement[0] == 0) _cnt++;
1874
- });
1875
- if (_cnt == 4 || _cnt == 3) {
1876
- _pointArray[0][0] = 100;
1877
- _pointArray[1][0] = 100;
1878
- }
1879
- actions.itemsActions.storeDistArray(_layer3.id, _item5.id, _pointArray);
1880
- var _minDis = fVLine[0].userData.distance;
1881
- var _snapObj = fVLine[0];
1882
- var _iPos = _item3D2.position.clone();
1883
- var _snapDis = Math.sqrt((_iPos.x - targetPoint.x) * (_iPos.x - targetPoint.x) + (_iPos.z - targetPoint.z) * (_iPos.z - targetPoint.z));
1884
- if (_snapDis >= 100 && _snapObj != null) {
1885
- removeSnapBox();
1886
- backsplashVisible = false;
1887
- //console.log('1 snap no');
1888
- }
1889
- for (var _i13 = 1; _i13 < fVLine.length; _i13++) {
1890
- if (_minDis > fVLine[_i13].userData.distance) {
1891
- _minDis = fVLine[_i13].userData.distance;
1892
- _snapObj = fVLine[_i13];
1893
- }
1894
- }
1895
- if (snapBox == null) {
1896
- snapFlag = false;
1897
- }
1898
- actions.sceneActions.updateMovingState(false);
1899
- if (_minDis < snapDelta && !snapFlag) {
1900
- _this2.snap(_snapObj, _layer3);
1901
- snapFlag = true;
1902
- //console.log('1 snap Yes')
1903
- getDistances(_layer3, true);
1904
- var _i14 = 0;
1905
- for (_i14 = 0; _i14 < fVLine.length; _i14++) {
1906
- if (fVLine[_i14].userData.distance < snapDelta) {
1907
- break;
1908
- }
1909
- }
1910
- if (_i14 === fVLine.length) backsplashVisible = false;else backsplashVisible = true;
1911
- }
1912
- actions.itemsActions.setBacksplashVisible(selectedObject.itemID, backsplashVisible);
1947
+ _this2.handleAfterMovingItem();
1913
1948
  }
1914
1949
  }
1915
1950
  if (!bMove && !bRotate && !bMoveUP) {
@@ -1922,13 +1957,13 @@ var Scene3DViewer = /*#__PURE__*/function (_React$Component) {
1922
1957
  rayDirection = rayDirection.normalize();
1923
1958
  var meshes = getAllMeshes(toIntersect);
1924
1959
  var intersects = raycaster.intersectObjects(meshes, true);
1925
- var _i15;
1960
+ var _i11;
1926
1961
  if (intersects.length > 0 && !isNaN(intersects[0].distance)) {
1927
- for (_i15 = 0; _i15 < intersects.length; _i15++) {
1928
- if (intersects[_i15].object.name === 'warningObj') break;
1962
+ for (_i11 = 0; _i11 < intersects.length; _i11++) {
1963
+ if (intersects[_i11].object.name === 'warningObj') break;
1929
1964
  }
1930
- if (intersects[_i15] !== undefined) {
1931
- var distance = Math.sqrt(Math.pow((intersects[_i15].uv.x - 0.5) * 50, 2) + Math.pow((intersects[_i15].uv.y - 0.75) * 100, 2));
1965
+ if (intersects[_i11] !== undefined) {
1966
+ var distance = Math.sqrt(Math.pow((intersects[_i11].uv.x - 0.5) * 50, 2) + Math.pow((intersects[_i11].uv.y - 0.75) * 100, 2));
1932
1967
  if (distance <= 20) {
1933
1968
  var infoPos = {
1934
1969
  x: 0,
@@ -1954,6 +1989,61 @@ var Scene3DViewer = /*#__PURE__*/function (_React$Component) {
1954
1989
  }
1955
1990
  document.getElementById('warning_box_2d').style.display = 'none';
1956
1991
  };
1992
+
1993
+ // handle snapBox, distArray, backsplash
1994
+ this.handleAfterMovingItem = function () {
1995
+ var layer = _this2.props.state.scene.getIn(['layers', selectedObject.layerID]);
1996
+ var item3D = planData.sceneGraph.layers[selectedObject.layerID].items[selectedObject.itemID];
1997
+ getDistances(layer);
1998
+ var pointArray = [],
1999
+ cnt = 0;
2000
+ pointArray.push([fVLine[0].userData.distance, 90]);
2001
+ pointArray.push([fVLine[1].userData.distance, -90]);
2002
+ pointArray.push([fVLine[2].userData.distance, 180]);
2003
+ pointArray.push([fVLine[3].userData.distance, 0]);
2004
+ pointArray.forEach(function (pointElement, index) {
2005
+ if (pointElement[0] == undefined) pointArray[index][0] = 0;
2006
+ });
2007
+ pointArray.forEach(function (pointElement) {
2008
+ if (pointElement[0] == 0) cnt++;
2009
+ });
2010
+ if (cnt == 4 || cnt == 3) {
2011
+ pointArray[0][0] = 100;
2012
+ pointArray[1][0] = 100;
2013
+ }
2014
+ actions.itemsActions.storeDistArray(selectedObject.layerID, selectedObject.itemID, pointArray);
2015
+ var minDis = fVLine[0].userData.distance;
2016
+ var snapObj = fVLine[0];
2017
+ var iPos = item3D.position.clone();
2018
+ var snapDis = Math.sqrt((iPos.x - targetPoint.x) * (iPos.x - targetPoint.x) + (iPos.z - targetPoint.z) * (iPos.z - targetPoint.z));
2019
+ if (snapDis >= 100 && snapObj != null) {
2020
+ removeSnapBox();
2021
+ backsplashVisible = false;
2022
+ }
2023
+ for (var _i12 = 1; _i12 < fVLine.length; _i12++) {
2024
+ if (minDis > fVLine[_i12].userData.distance) {
2025
+ minDis = fVLine[_i12].userData.distance;
2026
+ snapObj = fVLine[_i12];
2027
+ }
2028
+ }
2029
+ if (snapBox == null) {
2030
+ snapFlag = false;
2031
+ }
2032
+ actions.sceneActions.updateMovingState(false);
2033
+ if (minDis < snapDelta && !snapFlag) {
2034
+ _this2.snap(snapObj, layer);
2035
+ snapFlag = true;
2036
+ getDistances(layer, true);
2037
+ var _i13 = 0;
2038
+ for (_i13 = 0; _i13 < fVLine.length; _i13++) {
2039
+ if (fVLine[_i13].userData.distance < snapDelta) {
2040
+ break;
2041
+ }
2042
+ }
2043
+ if (_i13 === fVLine.length) backsplashVisible = false;else backsplashVisible = true;
2044
+ }
2045
+ actions.itemsActions.setBacksplashVisible(selectedObject.itemID, backsplashVisible);
2046
+ };
1957
2047
  this.onkeydown = function (event) {
1958
2048
  if (_this2.props.keyDownEnable && !isElevationView(state.mode)) {
1959
2049
  switch (event.keyCode) {
@@ -2009,6 +2099,14 @@ var Scene3DViewer = /*#__PURE__*/function (_React$Component) {
2009
2099
  this.handleKeyDown = function (event) {
2010
2100
  _this2.onkeydown(event);
2011
2101
  };
2102
+ this.getSelectedObject = function () {
2103
+ var layerID = _this2.props.state.scene.selectedLayer;
2104
+ var itemID = _this2.props.state.drawingSupport.get('currentID');
2105
+ selectedObject = {
2106
+ layerID: layerID,
2107
+ itemID: itemID
2108
+ };
2109
+ };
2012
2110
 
2013
2111
  // Renderer & Event listener
2014
2112
 
@@ -2017,6 +2115,7 @@ var Scene3DViewer = /*#__PURE__*/function (_React$Component) {
2017
2115
  if (!this.props.downloadFlag) {
2018
2116
  this.renderer.domElement.addEventListener('mousedown', this.mouseDownEvent);
2019
2117
  this.renderer.domElement.addEventListener('mouseup', this.mouseUpEvent);
2118
+ this.renderer.domElement.addEventListener('mouseenter', this.mouseEnterEvent);
2020
2119
  this.renderer.domElement.addEventListener('mousemove', this.mouseMoveEvent);
2021
2120
  window.addEventListener('keydown', this.onkeydown);
2022
2121
  window.SPKeyDown = this.handleKeyDown;
@@ -2037,7 +2136,7 @@ var Scene3DViewer = /*#__PURE__*/function (_React$Component) {
2037
2136
  setTimeout(function () {
2038
2137
  try {
2039
2138
  currentObject = planData.sceneGraph.layers[selectedObject.layerID].items[selectedObject.itemID];
2040
- if (!currentObject) return;
2139
+ if (isUndefined(currentObject)) return;
2041
2140
  var selItem = _this2.props.state.scene.layers.get(selectedObject.layerID).items.get(selectedObject.itemID);
2042
2141
  var itemPos = currentObject.position.clone();
2043
2142
  toolObj.position.set(planData.plan.position.x + itemPos.x, selItem.category === 'lighting' ? -planData.plan.position.y - selItem.properties.get('height').get('length') : planData.plan.position.y + currentObject.children[0].position.y, planData.plan.position.z + itemPos.z);
@@ -2157,9 +2256,9 @@ var Scene3DViewer = /*#__PURE__*/function (_React$Component) {
2157
2256
  function render() {
2158
2257
  var delta = clock.getDelta(); // Get time delta for smooth updates
2159
2258
  if (!isElevationView(state.mode)) cameraControls.update(delta);
2160
- for (var _i16 = 0; _i16 < lights.length; _i16++) {
2161
- lights[_i16].light.position.set(planData.plan.position.x + lights[_i16].x, planData.plan.position.y + lights[_i16].height - 10, planData.plan.position.z - lights[_i16].y);
2162
- lights[_i16].target.position.set(planData.plan.position.x + lights[_i16].x, planData.plan.position.y, planData.plan.position.z - lights[_i16].y);
2259
+ for (var _i14 = 0; _i14 < lights.length; _i14++) {
2260
+ lights[_i14].light.position.set(planData.plan.position.x + lights[_i14].x, planData.plan.position.y + lights[_i14].height - 10, planData.plan.position.z - lights[_i14].y);
2261
+ lights[_i14].target.position.set(planData.plan.position.x + lights[_i14].x, planData.plan.position.y, planData.plan.position.z - lights[_i14].y);
2163
2262
  }
2164
2263
  camera.updateMatrix();
2165
2264
  camera.updateMatrixWorld();