kitchen-simulator 5.0.0-test.7 → 5.0.0-test.9
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/package.json +12 -3
- package/src/components/export.js +16 -23
- package/src/components/catalog-view/catalog-breadcrumb.jsx +0 -53
- package/src/components/catalog-view/catalog-item.jsx +0 -229
- package/src/components/catalog-view/catalog-list.jsx +0 -173
- package/src/components/catalog-view/catalog-page-item.jsx +0 -110
- package/src/components/catalog-view/catalog-turn-back-page-item.jsx +0 -80
- package/src/components/configurator/custom-configurator.jsx +0 -77
- package/src/components/configurator/project-configurator.jsx +0 -120
- package/src/components/firstsetting/button/styles.js +0 -223
- package/src/components/firstsetting/export.js +0 -9
- package/src/components/firstsetting/firstsetting-content-button.jsx +0 -198
- package/src/components/firstsetting/firstsetting-toggle-button.jsx +0 -101
- package/src/components/firstsetting/firstsetting.jsx +0 -814
- package/src/components/footerbar/button/ControlButton.jsx +0 -43
- package/src/components/footerbar/button/DirectionButton.jsx +0 -54
- package/src/components/footerbar/button/DirectionPanSpinButton.jsx +0 -36
- package/src/components/footerbar/button/ToggleButton.jsx +0 -58
- package/src/components/footerbar/button/ToggleConvertButton.jsx +0 -48
- package/src/components/footerbar/button/ToggleMeasureButton.jsx +0 -33
- package/src/components/footerbar/button/styles.js +0 -217
- package/src/components/footerbar/export.js +0 -9
- package/src/components/footerbar/footer-content-button.jsx +0 -198
- package/src/components/footerbar/footer-toggle-button.jsx +0 -101
- package/src/components/footerbar/footerbar.jsx +0 -1103
- package/src/components/footerbar/styles.js +0 -263
- package/src/components/header/button/MenuButton.jsx +0 -46
- package/src/components/header/button/SaveButton.jsx +0 -54
- package/src/components/header/button/styles.js +0 -181
- package/src/components/header/export.js +0 -5
- package/src/components/header/header.jsx +0 -631
- package/src/components/header/header.style.css +0 -47
- package/src/components/header/styles.js +0 -320
- package/src/components/login/Login.js +0 -77
- package/src/components/login/LoginForm/index.js +0 -108
- package/src/components/login/Register.js +0 -83
- package/src/components/login/RegisterForm/index.js +0 -171
- package/src/components/login/jwtService.js +0 -201
- package/src/components/login/style.css +0 -158
- package/src/components/login/style.scss +0 -260
- package/src/components/myprojects/export.js +0 -5
- package/src/components/myprojects/index.jsx +0 -445
- package/src/components/myprojects/styles.js +0 -241
- package/src/components/sidebar/custom-accordion.jsx +0 -48
- package/src/components/sidebar/export.js +0 -15
- package/src/components/sidebar/panel-element-editor/attributes-editor/attributes-editor.jsx +0 -73
- package/src/components/sidebar/panel-element-editor/attributes-editor/confirm-popup.jsx +0 -101
- package/src/components/sidebar/panel-element-editor/attributes-editor/hole-attributes-editor.jsx +0 -149
- package/src/components/sidebar/panel-element-editor/attributes-editor/item-attributes-editor.jsx +0 -316
- package/src/components/sidebar/panel-element-editor/attributes-editor/line-attributes-editor.jsx +0 -108
- package/src/components/sidebar/panel-element-editor/element-editor.jsx +0 -1070
- package/src/components/sidebar/panel-element-editor/multi-elements-editor.jsx +0 -0
- package/src/components/sidebar/panel-element-editor/panel-element-editor.jsx +0 -104
- package/src/components/sidebar/panel-element-editor/panel-multi-elements-editor.jsx +0 -155
- package/src/components/sidebar/panel-group-editor.jsx +0 -272
- package/src/components/sidebar/panel-groups.jsx +0 -310
- package/src/components/sidebar/panel-guides.jsx +0 -192
- package/src/components/sidebar/panel-layer-elements.jsx +0 -298
- package/src/components/sidebar/panel-layers.jsx +0 -381
- package/src/components/sidebar/panel.jsx +0 -71
- package/src/components/sidebar/sidebar.jsx +0 -106
- package/src/components/sidebar/toolbar-panel.jsx +0 -139
- package/src/components/sign/export.js +0 -7
- package/src/components/sign/main/index.jsx +0 -523
- package/src/components/sign/main/styles.js +0 -163
- package/src/components/toolbar/button/ControlButton.jsx +0 -41
- package/src/components/toolbar/button/DirectionButton.jsx +0 -34
- package/src/components/toolbar/button/RightButton.jsx +0 -103
- package/src/components/toolbar/button/ToggleButton.jsx +0 -41
- package/src/components/toolbar/button/index.jsx +0 -55
- package/src/components/toolbar/button/styles.js +0 -127
- package/src/components/toolbar/components/DoorStyleMenu.jsx +0 -103
- package/src/components/toolbar/components/Pricing.jsx +0 -126
- package/src/components/toolbar/components/ReviewForQuote.jsx +0 -635
- package/src/components/toolbar/export.js +0 -21
- package/src/components/toolbar/main/Alert.js +0 -122
- package/src/components/toolbar/main/TakePictureModal.jsx +0 -104
- package/src/components/toolbar/main/confirm-popup.jsx +0 -99
- package/src/components/toolbar/main/index.jsx +0 -5627
- package/src/components/toolbar/main/lShaped.json +0 -311
- package/src/components/toolbar/main/longNarrow.json +0 -238
- package/src/components/toolbar/main/myComponents.js +0 -123
- package/src/components/toolbar/main/oRectangle.json +0 -220
- package/src/components/toolbar/main/rectangle.json +0 -238
- package/src/components/toolbar/main/style.css +0 -107
- package/src/components/toolbar/main/styles.js +0 -696
- package/src/components/toolbar/plugin-item.jsx +0 -123
- package/src/components/toolbar/popup/appliance/appliance-category/index.jsx +0 -73
- package/src/components/toolbar/popup/appliance/choose-appliance/index.jsx +0 -102
- package/src/components/toolbar/popup/appliance/index.jsx +0 -83
- package/src/components/toolbar/popup/autosaveprompt/index.jsx +0 -150
- package/src/components/toolbar/popup/autosaveprompt/styles.css +0 -64
- package/src/components/toolbar/popup/autosaveprompt/styles.js +0 -40
- package/src/components/toolbar/popup/cabinet/cabinet-category/index.jsx +0 -73
- package/src/components/toolbar/popup/cabinet/choose-product/index.jsx +0 -119
- package/src/components/toolbar/popup/cabinet/index.jsx +0 -85
- package/src/components/toolbar/popup/doorStyle/choose-style/index.jsx +0 -63
- package/src/components/toolbar/popup/doorStyle/index.jsx +0 -71
- package/src/components/toolbar/popup/doorStyle/style-category/index.jsx +0 -139
- package/src/components/toolbar/popup/downloadsummary/downloadSummaryContext.js +0 -2
- package/src/components/toolbar/popup/downloadsummary/downloadSummaryTemp.jsx +0 -157
- package/src/components/toolbar/popup/downloadsummary/index.jsx +0 -643
- package/src/components/toolbar/popup/downloadsummary/show2D/show2DView.jsx +0 -51
- package/src/components/toolbar/popup/downloadsummary/show2D/viewer2DDownLoad.jsx +0 -175
- package/src/components/toolbar/popup/downloadsummary/show3D/show3DView.jsx +0 -283
- package/src/components/toolbar/popup/downloadsummary/show3D/viewer3DDownLoad.jsx +0 -2257
- package/src/components/toolbar/popup/downloadsummary/showCabinetInfo.js +0 -93
- package/src/components/toolbar/popup/downloadsummary/showElevation/showElevationView.jsx +0 -132
- package/src/components/toolbar/popup/downloadsummary/showElevation/viewer3DElevationDownload.jsx +0 -2198
- package/src/components/toolbar/popup/downloadsummary/showElevation/viewerElevationDownload.jsx +0 -152
- package/src/components/toolbar/popup/downloadsummary/showWarranty.jsx +0 -149
- package/src/components/toolbar/popup/downloadsummary/styles.css +0 -177
- package/src/components/toolbar/popup/downloadsummary/styles.js +0 -453
- package/src/components/toolbar/popup/finishingtouch/category/index.jsx +0 -34
- package/src/components/toolbar/popup/finishingtouch/index.jsx +0 -58
- package/src/components/toolbar/popup/finishingtouch/material-edit.jsx +0 -112
- package/src/components/toolbar/popup/finishingtouch/product/index.jsx +0 -116
- package/src/components/toolbar/popup/floorplan/choose-floor/confirm-popup.jsx +0 -101
- package/src/components/toolbar/popup/floorplan/choose-floor/index.jsx +0 -254
- package/src/components/toolbar/popup/floorplan/choose-floor/lShaped.json +0 -311
- package/src/components/toolbar/popup/floorplan/choose-floor/longNarrow.json +0 -238
- package/src/components/toolbar/popup/floorplan/choose-floor/oRectangle.json +0 -220
- package/src/components/toolbar/popup/floorplan/choose-floor/rectangle.json +0 -238
- package/src/components/toolbar/popup/floorplan/choose-floor/styles.js +0 -86
- package/src/components/toolbar/popup/floorplan/floor-category/index.jsx +0 -109
- package/src/components/toolbar/popup/floorplan/index.jsx +0 -60
- package/src/components/toolbar/popup/index.jsx +0 -241
- package/src/components/toolbar/popup/newproject/index.jsx +0 -59
- package/src/components/toolbar/popup/newproject/styles.css +0 -64
- package/src/components/toolbar/popup/newproject/styles.js +0 -41
- package/src/components/toolbar/popup/product/appliance.jsx +0 -54
- package/src/components/toolbar/popup/product/cabinetproduct.jsx +0 -15
- package/src/components/toolbar/popup/product/doorstyle.jsx +0 -58
- package/src/components/toolbar/popup/product/doorstyleproduct.jsx +0 -47
- package/src/components/toolbar/popup/product/floor.jsx +0 -36
- package/src/components/toolbar/popup/product/floorproduct.jsx +0 -42
- package/src/components/toolbar/popup/product/index.jsx +0 -36
- package/src/components/toolbar/popup/product/primary.jsx +0 -77
- package/src/components/toolbar/popup/product/productline.jsx +0 -93
- package/src/components/toolbar/popup/product/reviewItem.jsx +0 -427
- package/src/components/toolbar/popup/product/reviewMolding.jsx +0 -310
- package/src/components/toolbar/popup/product/style.css +0 -54
- package/src/components/toolbar/popup/product/styles.js +0 -260
- package/src/components/toolbar/popup/savedesign/FullPictureForm.jsx +0 -146
- package/src/components/toolbar/popup/savedesign/index.jsx +0 -495
- package/src/components/toolbar/popup/savedesign/savedesign.style.css +0 -16
- package/src/components/toolbar/popup/savedesign/styles.js +0 -151
- package/src/components/toolbar/popup/setDoorStyleOption/index.jsx +0 -87
- package/src/components/toolbar/popup/styles.js +0 -909
- package/src/components/toolbar/popup/submitforquote/AddToCartOptions.jsx +0 -192
- package/src/components/toolbar/popup/submitforquote/CustomerRequestsForm.jsx +0 -96
- package/src/components/toolbar/popup/submitforquote/SkipDesignerReview.jsx +0 -54
- package/src/components/toolbar/popup/submitforquote/StepDots.jsx +0 -25
- package/src/components/toolbar/popup/submitforquote/cart-choice.jsx +0 -116
- package/src/components/toolbar/popup/submitforquote/doorstyle-menus.js +0 -38
- package/src/components/toolbar/popup/submitforquote/index.jsx +0 -698
- package/src/components/toolbar/popup/submitforquote/styles.css +0 -105
- package/src/components/toolbar/popup/submitforquote/styles.js +0 -294
- package/src/components/toolbar/popup/submitprompt/index.jsx +0 -89
- package/src/components/toolbar/popup/submitprompt/styles.css +0 -64
- package/src/components/toolbar/popup/submitprompt/styles.js +0 -42
- package/src/components/toolbar/toolbar-button.jsx +0 -90
- package/src/components/toolbar/toolbar-load-button.jsx +0 -36
- package/src/components/toolbar/toolbar-save-button.jsx +0 -32
- package/src/components/wizardstep/button/styles.js +0 -677
- package/src/components/wizardstep/export.js +0 -5
- package/src/components/wizardstep/index.jsx +0 -1372
- package/src/components/wizardstep/styles.js +0 -688
- package/src/components/wizardstep/wizardstep-content-button.jsx +0 -198
- package/src/components/wizardstep/wizardstep-toggle-button.jsx +0 -101
|
@@ -1,116 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
|
|
3
|
-
import * as S from '../../styles';
|
|
4
|
-
|
|
5
|
-
import Appliance from '../../product/appliance';
|
|
6
|
-
import {
|
|
7
|
-
API_SERVER,
|
|
8
|
-
MODE_IDLE,
|
|
9
|
-
MODE_3D_VIEW,
|
|
10
|
-
MODE_3D_FIRST_PERSON,
|
|
11
|
-
MODE_VIEWING_CATALOG,
|
|
12
|
-
MODE_CONFIGURING_PROJECT,
|
|
13
|
-
MODE_IDLE_3D,
|
|
14
|
-
MODE_ROTATING_ITEM_3D,
|
|
15
|
-
MODE_DRAGGING_ITEM_3D,
|
|
16
|
-
MODE_2D_PAN,
|
|
17
|
-
MODE_DRAWING_ITEM,
|
|
18
|
-
MODE_DRAWING_ITEM_3D
|
|
19
|
-
} from '../../../../../constants';
|
|
20
|
-
|
|
21
|
-
export const FinishingProduct = ({
|
|
22
|
-
props,
|
|
23
|
-
mode,
|
|
24
|
-
chooseAction,
|
|
25
|
-
dataSource,
|
|
26
|
-
isExpand,
|
|
27
|
-
applyMaterial
|
|
28
|
-
}) => {
|
|
29
|
-
let products = [];
|
|
30
|
-
|
|
31
|
-
if (dataSource.length > 0) {
|
|
32
|
-
for (let i = 0; i < dataSource.length; i++) {
|
|
33
|
-
products.push(
|
|
34
|
-
<S.ItemWrapper key={i.toString()} style={{ justifyContent: 'center' }}>
|
|
35
|
-
<Appliance
|
|
36
|
-
name={'finishing'}
|
|
37
|
-
onClick={() => {
|
|
38
|
-
chooseAction(dataSource[i]);
|
|
39
|
-
props.projectActions.unselectAll();
|
|
40
|
-
if (
|
|
41
|
-
dataSource[i].category === 'lighting' ||
|
|
42
|
-
dataSource[i].category === 'furnishing'
|
|
43
|
-
) {
|
|
44
|
-
props.itemsActions.updatePopupOpen(2);
|
|
45
|
-
if (
|
|
46
|
-
dataSource[i].category === 'lighting' &&
|
|
47
|
-
[
|
|
48
|
-
MODE_IDLE_3D,
|
|
49
|
-
MODE_DRAWING_ITEM_3D,
|
|
50
|
-
MODE_DRAGGING_ITEM_3D,
|
|
51
|
-
MODE_ROTATING_ITEM_3D
|
|
52
|
-
].includes(mode)
|
|
53
|
-
)
|
|
54
|
-
// props.itemsActions.selectToolDrawingItem(dataSource[i].name);
|
|
55
|
-
props.itemsActions.selectToolDrawingItem3D(
|
|
56
|
-
dataSource[i].name
|
|
57
|
-
);
|
|
58
|
-
else {
|
|
59
|
-
[
|
|
60
|
-
MODE_IDLE_3D,
|
|
61
|
-
MODE_DRAWING_ITEM_3D,
|
|
62
|
-
MODE_DRAGGING_ITEM_3D,
|
|
63
|
-
MODE_ROTATING_ITEM_3D
|
|
64
|
-
].includes(mode)
|
|
65
|
-
? props.itemsActions.selectToolDrawingItem3D(
|
|
66
|
-
dataSource[i].name
|
|
67
|
-
)
|
|
68
|
-
: props.itemsActions.selectToolDrawingItem(
|
|
69
|
-
dataSource[i].name
|
|
70
|
-
);
|
|
71
|
-
}
|
|
72
|
-
props.projectActions.pushLastSelectedCatalogElementToHistory(
|
|
73
|
-
props.catalog.elements[dataSource[i].name]
|
|
74
|
-
);
|
|
75
|
-
if (document.getElementsByClassName('popup-content').length > 0)
|
|
76
|
-
document.getElementsByClassName(
|
|
77
|
-
'popup-content'
|
|
78
|
-
)[0].style.display = 'none';
|
|
79
|
-
}
|
|
80
|
-
}}
|
|
81
|
-
selected={dataSource[i].selected ? dataSource[i].selected : null}
|
|
82
|
-
url={
|
|
83
|
-
dataSource[i].category != undefined &&
|
|
84
|
-
dataSource[i].category !== 'modelling' &&
|
|
85
|
-
dataSource[i].category !== 'floor_style' &&
|
|
86
|
-
dataSource[i].category !== 'lighting' &&
|
|
87
|
-
dataSource[i].category !== 'counter_top' &&
|
|
88
|
-
dataSource[i].category !== 'backsplash' &&
|
|
89
|
-
dataSource[i].category !== 'furnishing'
|
|
90
|
-
? dataSource[i].color
|
|
91
|
-
: dataSource[i].thumbnail
|
|
92
|
-
}
|
|
93
|
-
title={dataSource[i].name}
|
|
94
|
-
category={
|
|
95
|
-
dataSource[i].category !== 'floor_style' ||
|
|
96
|
-
dataSource[i].category !== 'backsplash' ||
|
|
97
|
-
dataSource[i].category !== 'counter_top'
|
|
98
|
-
? ''
|
|
99
|
-
: dataSource[i].category
|
|
100
|
-
}
|
|
101
|
-
/>
|
|
102
|
-
</S.ItemWrapper>
|
|
103
|
-
);
|
|
104
|
-
}
|
|
105
|
-
}
|
|
106
|
-
let miHeight = 0;
|
|
107
|
-
let nonHeight = 495 - miHeight + 'px';
|
|
108
|
-
let height = window.innerHeight * 0.6 - miHeight + 'px';
|
|
109
|
-
return (
|
|
110
|
-
<S.ProductsContentWrapper
|
|
111
|
-
style={{ width: 220, height: isExpand ? height : nonHeight }}
|
|
112
|
-
>
|
|
113
|
-
{products}
|
|
114
|
-
</S.ProductsContentWrapper>
|
|
115
|
-
);
|
|
116
|
-
};
|
|
@@ -1,101 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import * as S from './styles';
|
|
3
|
-
import * as PS from '../../styles';
|
|
4
|
-
import { FaTimes } from 'react-icons/fa';
|
|
5
|
-
|
|
6
|
-
class ConfirmPopup extends React.Component {
|
|
7
|
-
constructor(props) {
|
|
8
|
-
super(props);
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
_submit() {
|
|
12
|
-
this.props.loadProject();
|
|
13
|
-
this.closePanel();
|
|
14
|
-
}
|
|
15
|
-
closePanel() {
|
|
16
|
-
this.props.handleConfirmLoad(false);
|
|
17
|
-
}
|
|
18
|
-
render() {
|
|
19
|
-
let { visible } = this.props;
|
|
20
|
-
return (
|
|
21
|
-
<div
|
|
22
|
-
style={{
|
|
23
|
-
width: '100%',
|
|
24
|
-
height: '100%',
|
|
25
|
-
display: visible ? 'block' : 'none',
|
|
26
|
-
userSelect: 'none'
|
|
27
|
-
}}
|
|
28
|
-
>
|
|
29
|
-
<S.Div>
|
|
30
|
-
<div
|
|
31
|
-
style={{
|
|
32
|
-
backgroundColor: '#1183B7',
|
|
33
|
-
height: '30px',
|
|
34
|
-
paddingRight: '6px'
|
|
35
|
-
}}
|
|
36
|
-
>
|
|
37
|
-
<div
|
|
38
|
-
style={{ float: 'right', marginTop: '4px' }}
|
|
39
|
-
onClick={() => this.closePanel()}
|
|
40
|
-
>
|
|
41
|
-
<PS.IconButton>
|
|
42
|
-
<FaTimes />
|
|
43
|
-
</PS.IconButton>
|
|
44
|
-
</div>
|
|
45
|
-
</div>
|
|
46
|
-
<div style={{ fontSize: 14, marginTop: 20, marginLeft: 40 }}>
|
|
47
|
-
All items will be removed from the canvas.
|
|
48
|
-
<br />
|
|
49
|
-
Are you sure?
|
|
50
|
-
</div>
|
|
51
|
-
<div
|
|
52
|
-
style={{
|
|
53
|
-
fontSize: 12,
|
|
54
|
-
display: 'flex',
|
|
55
|
-
flexDirection: 'column',
|
|
56
|
-
position: 'relative'
|
|
57
|
-
}}
|
|
58
|
-
></div>
|
|
59
|
-
<div style={{ display: 'flex', position: 'relative' }}>
|
|
60
|
-
<div
|
|
61
|
-
style={{
|
|
62
|
-
width: '70px',
|
|
63
|
-
marginLeft: '90px',
|
|
64
|
-
marginTop: '15px',
|
|
65
|
-
cursor: 'pointer'
|
|
66
|
-
}}
|
|
67
|
-
onClick={() => {
|
|
68
|
-
this._submit() || this.props.closeAction();
|
|
69
|
-
}}
|
|
70
|
-
>
|
|
71
|
-
<img
|
|
72
|
-
width={'80px'}
|
|
73
|
-
style={{ float: 'right' }}
|
|
74
|
-
src={'/assets/img/svg/toolbar/use_button.svg'}
|
|
75
|
-
/>
|
|
76
|
-
<S.ButtonTitle1>{'Yes'}</S.ButtonTitle1>
|
|
77
|
-
</div>
|
|
78
|
-
<div
|
|
79
|
-
style={{
|
|
80
|
-
width: '70px',
|
|
81
|
-
marginLeft: '40px',
|
|
82
|
-
marginTop: '15px',
|
|
83
|
-
cursor: 'pointer'
|
|
84
|
-
}}
|
|
85
|
-
onClick={() => this.closePanel()}
|
|
86
|
-
>
|
|
87
|
-
<img
|
|
88
|
-
width={'80px'}
|
|
89
|
-
style={{ float: 'right' }}
|
|
90
|
-
src={'/assets/img/svg/toolbar/cancel_button.svg'}
|
|
91
|
-
/>
|
|
92
|
-
<S.ButtonTitle2>{'No'}</S.ButtonTitle2>
|
|
93
|
-
</div>
|
|
94
|
-
</div>
|
|
95
|
-
</S.Div>
|
|
96
|
-
</div>
|
|
97
|
-
);
|
|
98
|
-
}
|
|
99
|
-
}
|
|
100
|
-
|
|
101
|
-
export default ConfirmPopup;
|
|
@@ -1,254 +0,0 @@
|
|
|
1
|
-
import React, { useState } from 'react';
|
|
2
|
-
import * as S from '../../styles';
|
|
3
|
-
import * as MS from './styles';
|
|
4
|
-
import FloorProduct from '../../product/floorproduct';
|
|
5
|
-
import * as rectangleData from './rectangle.json';
|
|
6
|
-
import * as lShaped from './lShaped.json';
|
|
7
|
-
import * as oRectangle from './oRectangle.json';
|
|
8
|
-
import * as longNarrow from './longNarrow.json';
|
|
9
|
-
import ConfirmPopup from './confirm-popup';
|
|
10
|
-
import { ARRAY_3D_MODES } from '../../../../../constants';
|
|
11
|
-
|
|
12
|
-
export const FloorChooseProduct = ({
|
|
13
|
-
drawAction,
|
|
14
|
-
props,
|
|
15
|
-
dataSource,
|
|
16
|
-
isExpand,
|
|
17
|
-
closeAction,
|
|
18
|
-
mode
|
|
19
|
-
}) => {
|
|
20
|
-
let [isPopupOpen, setPopupOpen] = useState(false);
|
|
21
|
-
let [selectedProject, setSelectedProject] = useState();
|
|
22
|
-
|
|
23
|
-
let miHeight = 0;
|
|
24
|
-
let nonHeight = 495 - miHeight + 'px';
|
|
25
|
-
let height = window.innerHeight * 0.6 - miHeight + 'px';
|
|
26
|
-
let select = element => {
|
|
27
|
-
switch (element.prototype) {
|
|
28
|
-
case 'lines':
|
|
29
|
-
props.linesActions.selectToolDrawingLine(element.name);
|
|
30
|
-
break;
|
|
31
|
-
case 'items':
|
|
32
|
-
ARRAY_3D_MODES.includes(mode)
|
|
33
|
-
? props.itemsActions.selectToolDrawingItem3D(element.name)
|
|
34
|
-
: props.itemsActions.selectToolDrawingItem(element.name);
|
|
35
|
-
break;
|
|
36
|
-
case 'holes':
|
|
37
|
-
ARRAY_3D_MODES.includes(mode)
|
|
38
|
-
? props.holesActions.selectToolDrawingHole3D(element.name)
|
|
39
|
-
: props.holesActions.selectToolDrawingHole(element.name);
|
|
40
|
-
break;
|
|
41
|
-
}
|
|
42
|
-
props.holesActions.updatePopupOpen(4);
|
|
43
|
-
props.projectActions.pushLastSelectedCatalogElementToHistory(element);
|
|
44
|
-
closeAction && closeAction();
|
|
45
|
-
};
|
|
46
|
-
|
|
47
|
-
let isProjectEmpty = scene => {
|
|
48
|
-
let { layers, selectedLayer } = scene;
|
|
49
|
-
let layer = layers.get(selectedLayer);
|
|
50
|
-
return (
|
|
51
|
-
layer.areas.size +
|
|
52
|
-
layer.lines.size +
|
|
53
|
-
layer.holes.size +
|
|
54
|
-
layer.items.size ===
|
|
55
|
-
0
|
|
56
|
-
);
|
|
57
|
-
};
|
|
58
|
-
|
|
59
|
-
let loadProjectFromData = data => event => {
|
|
60
|
-
event.preventDefault();
|
|
61
|
-
|
|
62
|
-
if (isProjectEmpty(props.state.scene)) {
|
|
63
|
-
loadProject(data);
|
|
64
|
-
closeAction && closeAction();
|
|
65
|
-
} else {
|
|
66
|
-
setSelectedProject(data);
|
|
67
|
-
setPopupOpen(true);
|
|
68
|
-
}
|
|
69
|
-
};
|
|
70
|
-
|
|
71
|
-
let loadProjectFromRetangleLineFile = loadProjectFromData(rectangleData);
|
|
72
|
-
|
|
73
|
-
let loadProjectFromlShapedLineFile = loadProjectFromData(lShaped);
|
|
74
|
-
|
|
75
|
-
let loadProjectFromoRectangleLineFile = loadProjectFromData(oRectangle);
|
|
76
|
-
|
|
77
|
-
let loadProjectFromlongNarrowLineFile = loadProjectFromData(longNarrow);
|
|
78
|
-
|
|
79
|
-
let handleConfirmLoad = value => {
|
|
80
|
-
setPopupOpen(value);
|
|
81
|
-
};
|
|
82
|
-
|
|
83
|
-
let loadProject = data => {
|
|
84
|
-
props.projectActions.loadProject(data || selectedProject);
|
|
85
|
-
document.getElementsByClassName('popup-content')[0].style.display = 'none';
|
|
86
|
-
};
|
|
87
|
-
|
|
88
|
-
let result = <div></div>;
|
|
89
|
-
//Drawer Custom Floor
|
|
90
|
-
if (dataSource === -1) {
|
|
91
|
-
result = (
|
|
92
|
-
<section>
|
|
93
|
-
<div style={{ padding: '12px 20px', fontSize: 11 }}>
|
|
94
|
-
<p style={{ color: '#e2e2e2' }}>
|
|
95
|
-
Using your mouse and the{' '}
|
|
96
|
-
<span style={{ color: 'white' }}>
|
|
97
|
-
<strong>Object Properties</strong>
|
|
98
|
-
</span>{' '}
|
|
99
|
-
Window you can draw your custom space to meet your exact project
|
|
100
|
-
requirements.
|
|
101
|
-
</p>
|
|
102
|
-
<p style={{ color: '#e2e2e2' }}>
|
|
103
|
-
To get professional help, click on the{' '}
|
|
104
|
-
<span style={{ color: 'white' }}>
|
|
105
|
-
<strong>Designer Assistance</strong>
|
|
106
|
-
</span>{' '}
|
|
107
|
-
button
|
|
108
|
-
</p>
|
|
109
|
-
</div>
|
|
110
|
-
<MS.Control
|
|
111
|
-
onClick={() => {
|
|
112
|
-
if (document.getElementsByClassName('popup-content').length > 0)
|
|
113
|
-
document.getElementsByClassName(
|
|
114
|
-
'popup-content'
|
|
115
|
-
)[0].style.display = 'none';
|
|
116
|
-
drawAction();
|
|
117
|
-
}}
|
|
118
|
-
>
|
|
119
|
-
<MS.ControlIcon>
|
|
120
|
-
<img
|
|
121
|
-
width={'160px'}
|
|
122
|
-
src={'/assets/img/svg/toolbar/get_started_button.svg'}
|
|
123
|
-
/>
|
|
124
|
-
<S.ButtonTitle style={{ fontSize: 13 }}>
|
|
125
|
-
{' '}
|
|
126
|
-
Get Started{' '}
|
|
127
|
-
</S.ButtonTitle>
|
|
128
|
-
</MS.ControlIcon>
|
|
129
|
-
</MS.Control>
|
|
130
|
-
</section>
|
|
131
|
-
);
|
|
132
|
-
}
|
|
133
|
-
// Predefined Room Layout
|
|
134
|
-
else if (dataSource === -2) {
|
|
135
|
-
result = (
|
|
136
|
-
<section>
|
|
137
|
-
<ConfirmPopup
|
|
138
|
-
visible={isPopupOpen}
|
|
139
|
-
closeAction={closeAction && closeAction}
|
|
140
|
-
handleConfirmLoad={handleConfirmLoad}
|
|
141
|
-
loadProject={loadProject}
|
|
142
|
-
/>
|
|
143
|
-
<S.ProductsRow
|
|
144
|
-
style={{ width: '100%', justifyContent: 'space-between' }}
|
|
145
|
-
>
|
|
146
|
-
<section
|
|
147
|
-
style={{
|
|
148
|
-
display: 'flex',
|
|
149
|
-
justifyContent: 'space-evenly',
|
|
150
|
-
borderBottom: '2px solid #2f2f2fb3',
|
|
151
|
-
width: '100%',
|
|
152
|
-
backgroundColor: '#3e3e3f'
|
|
153
|
-
}}
|
|
154
|
-
>
|
|
155
|
-
<MS.LineWrapper
|
|
156
|
-
onClick={loadProjectFromRetangleLineFile}
|
|
157
|
-
style={{ padding: '12px 11px 8px' }}
|
|
158
|
-
>
|
|
159
|
-
<div style={{ width: '50px', display: 'grid' }}>
|
|
160
|
-
<img
|
|
161
|
-
width={40}
|
|
162
|
-
src={'/assets/img/svg/toolbar/predefined_room_rectangle.svg'}
|
|
163
|
-
/>
|
|
164
|
-
<span style={{ marginTop: '7px', marginBottom: '9px' }}>
|
|
165
|
-
Square
|
|
166
|
-
</span>
|
|
167
|
-
</div>
|
|
168
|
-
</MS.LineWrapper>
|
|
169
|
-
<MS.LineWrapper
|
|
170
|
-
onClick={loadProjectFromlShapedLineFile}
|
|
171
|
-
style={{ padding: '12px 11px 8px' }}
|
|
172
|
-
>
|
|
173
|
-
<div style={{ width: '50px', display: 'grid' }}>
|
|
174
|
-
<img
|
|
175
|
-
width={40}
|
|
176
|
-
src={'/assets/img/svg/toolbar/predefined_room_l_shaped.svg'}
|
|
177
|
-
/>
|
|
178
|
-
<span style={{ marginTop: '7px', marginBottom: '9px' }}>
|
|
179
|
-
L Shaped
|
|
180
|
-
</span>
|
|
181
|
-
</div>
|
|
182
|
-
</MS.LineWrapper>
|
|
183
|
-
</section>
|
|
184
|
-
<section
|
|
185
|
-
style={{
|
|
186
|
-
display: 'flex',
|
|
187
|
-
justifyContent: 'space-evenly',
|
|
188
|
-
borderBottom: '2px solid #2f2f2fb3',
|
|
189
|
-
width: '100%',
|
|
190
|
-
backgroundColor: '#3e3e3f'
|
|
191
|
-
}}
|
|
192
|
-
>
|
|
193
|
-
<MS.LineWrapper
|
|
194
|
-
onClick={loadProjectFromoRectangleLineFile}
|
|
195
|
-
style={{ padding: '12px 11px 8px' }}
|
|
196
|
-
>
|
|
197
|
-
<div style={{ width: '50px', display: 'grid' }}>
|
|
198
|
-
<img
|
|
199
|
-
width={40}
|
|
200
|
-
src={
|
|
201
|
-
'/assets/img/svg/toolbar/predefined_room_open_rectangle_2.svg'
|
|
202
|
-
}
|
|
203
|
-
/>
|
|
204
|
-
<span style={{ marginTop: '7px', marginBottom: '9px' }}>
|
|
205
|
-
Open Square
|
|
206
|
-
</span>
|
|
207
|
-
</div>
|
|
208
|
-
</MS.LineWrapper>
|
|
209
|
-
<MS.LineWrapper
|
|
210
|
-
onClick={loadProjectFromlongNarrowLineFile}
|
|
211
|
-
style={{ padding: '12px 11px 8px' }}
|
|
212
|
-
>
|
|
213
|
-
<div style={{ width: '50px', display: 'grid' }}>
|
|
214
|
-
<img
|
|
215
|
-
width={40}
|
|
216
|
-
height={40}
|
|
217
|
-
src={
|
|
218
|
-
'/assets/img/svg/toolbar/predefined_room_long_narrow.svg'
|
|
219
|
-
}
|
|
220
|
-
/>
|
|
221
|
-
<span style={{ marginTop: '7px', marginBottom: '9px' }}>
|
|
222
|
-
Long & Narrow
|
|
223
|
-
</span>
|
|
224
|
-
</div>
|
|
225
|
-
</MS.LineWrapper>
|
|
226
|
-
</section>
|
|
227
|
-
</S.ProductsRow>
|
|
228
|
-
</section>
|
|
229
|
-
);
|
|
230
|
-
}
|
|
231
|
-
//Room Elements
|
|
232
|
-
else {
|
|
233
|
-
result = [];
|
|
234
|
-
dataSource.forEach((el, key) => {
|
|
235
|
-
result.push(
|
|
236
|
-
<S.ItemWrapper key={el.name} style={{ justifyContent: 'center' }}>
|
|
237
|
-
<FloorProduct
|
|
238
|
-
url={el.info.image}
|
|
239
|
-
title={el.info.title}
|
|
240
|
-
onClick={() => select(el)}
|
|
241
|
-
/>
|
|
242
|
-
</S.ItemWrapper>
|
|
243
|
-
);
|
|
244
|
-
});
|
|
245
|
-
}
|
|
246
|
-
|
|
247
|
-
return (
|
|
248
|
-
<S.ProductsContentWrapper
|
|
249
|
-
style={{ width: 250, height: isExpand ? height : nonHeight }}
|
|
250
|
-
>
|
|
251
|
-
{result}
|
|
252
|
-
</S.ProductsContentWrapper>
|
|
253
|
-
);
|
|
254
|
-
};
|