architwin 1.10.4 → 1.10.5
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/lib/architwin.js +4 -2
- package/lib/atwinui/components/toolbar/actionSettingsPane.d.ts +27 -0
- package/lib/atwinui/components/toolbar/actionSettingsPane.js +424 -0
- package/lib/atwinui/components/toolbar/i18n.js +28 -2
- package/lib/atwinui/components/toolbar/index.d.ts +2 -1
- package/lib/atwinui/components/toolbar/index.js +6 -2
- package/lib/atwinui/components/toolbar/menuBar.d.ts +1 -0
- package/lib/atwinui/components/toolbar/menuBar.js +11 -2
- package/lib/atwinui/components/toolbar/modelControlsPane.js +87 -2
- package/lib/atwinui/events.js +93 -2
- package/lib/types.d.ts +1 -0
- package/lib/utils.js +1 -1
- package/package.json +1 -1
- package/static/atwinui.css +171 -2
- package/static/bim.png +0 -0
- package/static/utility.css +28 -0
package/lib/architwin.js
CHANGED
|
@@ -3414,8 +3414,9 @@ function getTargetPosition(callback = undefined) {
|
|
|
3414
3414
|
*/
|
|
3415
3415
|
function cancelModelPlacement() {
|
|
3416
3416
|
return __awaiter(this, void 0, void 0, function* () {
|
|
3417
|
-
log.info("cancelModelPlacement()");
|
|
3418
|
-
_pointerSubscription
|
|
3417
|
+
log.info("cancelModelPlacement()", _pointerSubscription);
|
|
3418
|
+
if (_pointerSubscription)
|
|
3419
|
+
_pointerSubscription.cancel();
|
|
3419
3420
|
setElementVisibility(_objectMarker, false);
|
|
3420
3421
|
yield _atwin.Pointer.resetTexture();
|
|
3421
3422
|
if (_onMouseClickInstance !== undefined) {
|
|
@@ -3843,6 +3844,7 @@ function createIShowcaseObjectData(object_data, position = undefined, scale = un
|
|
|
3843
3844
|
showcase_object.position_unit = "m";
|
|
3844
3845
|
showcase_object.object_data = object_data;
|
|
3845
3846
|
showcase_object.showcase_object_name = object_data.name;
|
|
3847
|
+
showcase_object.coordinate_system = 'yup';
|
|
3846
3848
|
if (showcase_object.object_data) {
|
|
3847
3849
|
showcase_object.object_data = newObj;
|
|
3848
3850
|
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { Vector3 } from "three";
|
|
2
|
+
export declare function renderActionSettingsPane(): HTMLDivElement;
|
|
3
|
+
export declare function toggleActionSettings(visible?: boolean): void;
|
|
4
|
+
export declare function toggleActionSettingsDropdown(id: string): void;
|
|
5
|
+
export declare function actionSettingsSelectOption(element: HTMLElement, id: string): void;
|
|
6
|
+
export declare function initSettingsValues(): void;
|
|
7
|
+
export declare function toggleCalibrateBasepoint(): Promise<void>;
|
|
8
|
+
export declare function getCoordinateSystem(): string;
|
|
9
|
+
export declare function setCoordinateSystem(value: string): void;
|
|
10
|
+
export declare function getScaleFactor(): string;
|
|
11
|
+
export declare function setScaleFactor(value: string): void;
|
|
12
|
+
export declare function getMeasurementUnit(): string;
|
|
13
|
+
export declare function setMeasurementUnit(value: string): void;
|
|
14
|
+
export declare function getRotationUnit(): string;
|
|
15
|
+
export declare function setRotationUnit(value: string): void;
|
|
16
|
+
export declare function setTempCoordinateSystem(value: string): void;
|
|
17
|
+
export declare function getTempCoordinateSystem(): string;
|
|
18
|
+
export declare function setTempScaleFactor(value: string): void;
|
|
19
|
+
export declare function getTempScaleFactor(): string;
|
|
20
|
+
export declare function setTempMeasurementUnit(value: string): void;
|
|
21
|
+
export declare function getTempMeasurementUnit(): string;
|
|
22
|
+
export declare function setTempRotationUnit(value: string): void;
|
|
23
|
+
export declare function getTempRotationUnit(): string;
|
|
24
|
+
export declare function setBasepoint(value: Vector3): void;
|
|
25
|
+
export declare function getBasepoint(): Vector3;
|
|
26
|
+
export declare function setTempBasepoint(value: Vector3): void;
|
|
27
|
+
export declare function getTempBasepoint(): Vector3;
|
|
@@ -0,0 +1,424 @@
|
|
|
1
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
2
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
3
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
4
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
5
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
6
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
7
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
8
|
+
});
|
|
9
|
+
};
|
|
10
|
+
import { _3DXObjects, addObjectToSpace, cancelModelPlacement, clearSelectedObject, disposeModel, getTargetPosition, removeTransformControls, setSelectedObject, setTransformControls } from "../../../architwin";
|
|
11
|
+
import { batchAddEventListenerByClassName } from "../../events";
|
|
12
|
+
import i18n from "./i18n";
|
|
13
|
+
import { toggleModelControl } from "./modelControlsPane";
|
|
14
|
+
import { convertYupToZup } from "../../../worldConversion";
|
|
15
|
+
import { getAssetUrl } from "../../../utils";
|
|
16
|
+
let actionSettingsPane;
|
|
17
|
+
let coordinateSystem = "matterport";
|
|
18
|
+
let scaleFactor = "1";
|
|
19
|
+
let measurementUnit = "meter";
|
|
20
|
+
let rotationUnit = "radian";
|
|
21
|
+
let tempCoordinateSystem = "matterport";
|
|
22
|
+
let tempScaleFactor = "1";
|
|
23
|
+
let tempMeasurementUnit = "meter";
|
|
24
|
+
let tempRotationUnit = "radian";
|
|
25
|
+
let tempBasepoint = undefined;
|
|
26
|
+
let basepoint = undefined;
|
|
27
|
+
let isSettingsSaved = false;
|
|
28
|
+
export function renderActionSettingsPane() {
|
|
29
|
+
const element = document.createElement('div');
|
|
30
|
+
element.classList.add('at_container');
|
|
31
|
+
element.classList.add('at_h-full');
|
|
32
|
+
element.classList.add('at_w-12');
|
|
33
|
+
element.setAttribute('id', 'at-settings-pane');
|
|
34
|
+
element.setAttribute('data-cy', 'at-settings-pane');
|
|
35
|
+
element.innerHTML = `
|
|
36
|
+
<div class="at_form_container at_scrollable_container settings">
|
|
37
|
+
<div class="at_flex at_space_between">
|
|
38
|
+
<span class="at_bolder at_text_base" id="at-settings-title">${i18n.t("Settings")}</span>
|
|
39
|
+
</div>
|
|
40
|
+
<div class="at_flex at_flex_column at_gap_2" id="at-settings-coordinate-system">
|
|
41
|
+
<label class="at_text_xs">${i18n.t("CoordinateSystem")}</label>
|
|
42
|
+
<div class="at_flex at_justify_center at_gap_4">
|
|
43
|
+
<label class="at_flex at_align_center at_text_xxs at_gap_1">
|
|
44
|
+
<input type="radio" id="at-settings-radio-matterport" name="coordinate-system" value="matterport" checked />
|
|
45
|
+
${i18n.t("Matterport")}
|
|
46
|
+
</label>
|
|
47
|
+
<label class="at_flex at_align_center at_text_xxs at_gap_1">
|
|
48
|
+
<input type="radio" id="at-settings-radio-bim" name="coordinate-system" value="bim" />
|
|
49
|
+
${i18n.t("Bim")}
|
|
50
|
+
</label>
|
|
51
|
+
</div>
|
|
52
|
+
</div>
|
|
53
|
+
|
|
54
|
+
<div class="at_flex at_flex_column at_gap_2" id="at-settings-coordinate-system">
|
|
55
|
+
<label class="at_text_xs">${i18n.t("ScaleFactor")}</label>
|
|
56
|
+
<div class="at_flex at_gap_1">
|
|
57
|
+
<input class="at_field_input at_w-4 at_disabled" type="text" id="" data-cy="" value="1" disabled>
|
|
58
|
+
<span>:<span>
|
|
59
|
+
<input class="at_field_input at_w-4" type="text" id="at-settings-scale-factor-input" data-cy="at-settings-scale-factor-input" value="1">
|
|
60
|
+
</div>
|
|
61
|
+
</div>
|
|
62
|
+
|
|
63
|
+
<div class="at_flex at_flex_column at_gap_2" id="at-settings-measurement-unit">
|
|
64
|
+
<label class="at_text_xs">${i18n.t("MeasurementUnit")}</label>
|
|
65
|
+
<div id="" data-cy="">
|
|
66
|
+
<div class="at_dropdown at_flex at_flex_row at_space_between" id="at-selected-measurement-unit">
|
|
67
|
+
<div class="at_dropdown_toggle" id="at-selected-measurement-unit-text">${i18n.t('Meter')}</div>
|
|
68
|
+
<span class="mdi mdi-triangle-down at_chevron"></span>
|
|
69
|
+
</div>
|
|
70
|
+
<div class="at_options_container">
|
|
71
|
+
<div class="at_dropdown_options" id="at-measurement-unit-options" data-cy="at-measurement-unit-options">
|
|
72
|
+
<div class="at_option" data-value="meter">${i18n.t("Meter")}</div>
|
|
73
|
+
<div class="at_option" data-value="foot">${i18n.t("Foot")}</div>
|
|
74
|
+
<div class="at_option" data-value="inch">${i18n.t("Inch")}</div>
|
|
75
|
+
</div>
|
|
76
|
+
</div>
|
|
77
|
+
</div>
|
|
78
|
+
</div>
|
|
79
|
+
|
|
80
|
+
<div class="at_flex at_flex_column at_gap_2" id="at-settings-rotation-unit">
|
|
81
|
+
<label class="at_text_xs">${i18n.t("RotationUnit")}</label>
|
|
82
|
+
<div id="" data-cy="">
|
|
83
|
+
<div class="at_dropdown at_flex at_flex_row at_space_between" id="at-selected-rotation-unit">
|
|
84
|
+
<div class="at_dropdown_toggle" id="at-selected-rotation-unit-text">${i18n.t('Radian')}</div>
|
|
85
|
+
<span class="mdi mdi-triangle-down at_chevron"></span>
|
|
86
|
+
</div>
|
|
87
|
+
<div class="at_options_container">
|
|
88
|
+
<div class="at_dropdown_options" id="at-rotation-unit-options" data-cy="at-rotation-unit-options">
|
|
89
|
+
<div class="at_option" data-value="radian">${i18n.t("Radian")}</div>
|
|
90
|
+
<div class="at_option" data-value="degree">${i18n.t("Degree")}</div>
|
|
91
|
+
</div>
|
|
92
|
+
</div>
|
|
93
|
+
</div>
|
|
94
|
+
</div>
|
|
95
|
+
<div class="at_button at_calibrate_basepoint_btn" id="at-calibrate-basepoint-btn" data-cy="at-calibrate-basepoint-btn" data-state="calibrate">
|
|
96
|
+
<span class="mdi mdi-map-marker-radius"></span>${i18n.t('CalibrateBasepoint')}
|
|
97
|
+
</div>
|
|
98
|
+
|
|
99
|
+
<div class="at_converted_coordinates_list_container" style="display: none"id="at-converted-coordiantes-container" data-cy="at-converted-coordiantes-container">
|
|
100
|
+
|
|
101
|
+
<!-- insert at_converted_coordinates_title here -->
|
|
102
|
+
|
|
103
|
+
<!-- insert at_coordinate_list_container here -->
|
|
104
|
+
|
|
105
|
+
</div>
|
|
106
|
+
</div>
|
|
107
|
+
|
|
108
|
+
<div class="at_button at_ghost" id="at-save-settings" data-cy="at-save-settings">
|
|
109
|
+
${i18n.t('Save')}
|
|
110
|
+
<span class="mdi mdi-content-save"></span>
|
|
111
|
+
</div>
|
|
112
|
+
`;
|
|
113
|
+
return element;
|
|
114
|
+
}
|
|
115
|
+
export function toggleActionSettings(visible = true) {
|
|
116
|
+
console.log("toggleActionSettings()");
|
|
117
|
+
if (!actionSettingsPane) {
|
|
118
|
+
actionSettingsPane = document.getElementById('at-settings-pane');
|
|
119
|
+
}
|
|
120
|
+
if (visible) {
|
|
121
|
+
actionSettingsPane.style.display = 'block';
|
|
122
|
+
return;
|
|
123
|
+
}
|
|
124
|
+
actionSettingsPane.style.display = 'none';
|
|
125
|
+
return;
|
|
126
|
+
}
|
|
127
|
+
export function toggleActionSettingsDropdown(id) {
|
|
128
|
+
const optionsContainer = document.getElementById(`${id}`);
|
|
129
|
+
optionsContainer === null || optionsContainer === void 0 ? void 0 : optionsContainer.classList.toggle("open");
|
|
130
|
+
}
|
|
131
|
+
export function actionSettingsSelectOption(element, id) {
|
|
132
|
+
const selectedText = document.getElementById(`at-selected-${id}-text`);
|
|
133
|
+
selectedText.innerText = i18n.t(element.innerText);
|
|
134
|
+
element.parentElement.classList.toggle("open");
|
|
135
|
+
}
|
|
136
|
+
export function initSettingsValues() {
|
|
137
|
+
// set coordinate saystem
|
|
138
|
+
const coordinateSystemvalue = coordinateSystem;
|
|
139
|
+
const radioButton = document.querySelector(`input[name="coordinate-system"][value="${coordinateSystemvalue}"]`);
|
|
140
|
+
if (radioButton) {
|
|
141
|
+
radioButton.checked = true;
|
|
142
|
+
}
|
|
143
|
+
// set scale factor
|
|
144
|
+
const scaleFactorValue = scaleFactor;
|
|
145
|
+
const scaleFactorInput = document.getElementById('at-settings-scale-factor-input');
|
|
146
|
+
if (scaleFactorInput) {
|
|
147
|
+
scaleFactorInput.value = scaleFactorValue;
|
|
148
|
+
}
|
|
149
|
+
// set measurement unit
|
|
150
|
+
const measurementUnitElement = document.getElementById(`at-selected-measurement-unit-text`);
|
|
151
|
+
const measurementUnitValue = measurementUnit.charAt(0).toUpperCase() + measurementUnit.substring(1).toLowerCase();
|
|
152
|
+
measurementUnitElement.innerText = i18n.t(measurementUnitValue);
|
|
153
|
+
// set rotation unit
|
|
154
|
+
const rotationUnitElement = document.getElementById(`at-selected-rotation-unit-text`);
|
|
155
|
+
const rotationUnitValue = rotationUnit.charAt(0).toUpperCase() + rotationUnit.substring(1).toLowerCase();
|
|
156
|
+
rotationUnitElement.innerText = i18n.t(rotationUnitValue);
|
|
157
|
+
if (basepoint) {
|
|
158
|
+
const element = document.getElementById(`at-calibrate-basepoint-btn`);
|
|
159
|
+
element.dataset.state = basepoint ? "adjust" : "calibrate";
|
|
160
|
+
element.innerText = basepoint ? i18n.t("AdjustBasepoint") : i18n.t("CalibrateBasepoint");
|
|
161
|
+
displayConvertedCoordinates(basepoint);
|
|
162
|
+
}
|
|
163
|
+
else {
|
|
164
|
+
const convertedCoordinatesContainer = document.getElementById('at-converted-coordiantes-container');
|
|
165
|
+
convertedCoordinatesContainer.style.display = 'none';
|
|
166
|
+
const element = document.getElementById(`at-calibrate-basepoint-btn`);
|
|
167
|
+
element.classList.remove('active');
|
|
168
|
+
element.dataset.state = basepoint ? "adjust" : "calibrate";
|
|
169
|
+
element.innerText = basepoint ? i18n.t("AdjustBasepoint") : i18n.t("CalibrateBasepoint");
|
|
170
|
+
}
|
|
171
|
+
}
|
|
172
|
+
export function toggleCalibrateBasepoint() {
|
|
173
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
174
|
+
const element = document.getElementById(`at-calibrate-basepoint-btn`);
|
|
175
|
+
const currentState = element.dataset.state;
|
|
176
|
+
console.log("toggleCalibrateBasepoint()", element.innerText);
|
|
177
|
+
console.log(element.innerText === i18n.t("CalibrateBasepoint"));
|
|
178
|
+
console.log(typeof element.innerText, typeof i18n.t("CalibrateBasepoint"));
|
|
179
|
+
switch (currentState) {
|
|
180
|
+
case "cancel":
|
|
181
|
+
element.dataset.state = tempBasepoint || basepoint ? "adjust" : "calibrate";
|
|
182
|
+
element.innerText = tempBasepoint || basepoint ? i18n.t("AdjustBasepoint") : i18n.t("CalibrateBasepoint");
|
|
183
|
+
if (basepoint || tempBasepoint) {
|
|
184
|
+
toggleModelControl(false, 'translate');
|
|
185
|
+
removeTransformControls();
|
|
186
|
+
clearSelectedObject();
|
|
187
|
+
}
|
|
188
|
+
else {
|
|
189
|
+
const target = _3DXObjects.find(obj => obj.type === 'BASEPOINT');
|
|
190
|
+
if (target)
|
|
191
|
+
disposeModel(target);
|
|
192
|
+
cancelModelPlacement();
|
|
193
|
+
}
|
|
194
|
+
break;
|
|
195
|
+
case "calibrate":
|
|
196
|
+
element.dataset.state = "cancel";
|
|
197
|
+
element.innerText = i18n.t("Cancel");
|
|
198
|
+
yield getTargetPosition((coords) => __awaiter(this, void 0, void 0, function* () {
|
|
199
|
+
console.log("coord", coords);
|
|
200
|
+
coords.y = coords.y + 0.01;
|
|
201
|
+
setTempBasepoint(coords);
|
|
202
|
+
const mediaUrl = getAssetUrl('images/basepointmarker.png');
|
|
203
|
+
const objectType = '';
|
|
204
|
+
yield addObjectToSpace(mediaUrl, objectType, {
|
|
205
|
+
position: coords,
|
|
206
|
+
rotation: { x: 1.57079633, y: 0, z: 0 }
|
|
207
|
+
});
|
|
208
|
+
_3DXObjects[_3DXObjects.length - 1].type = 'BASEPOINT';
|
|
209
|
+
displayConvertedCoordinates(coords);
|
|
210
|
+
element.dataset.state = "adjust";
|
|
211
|
+
element.innerText = i18n.t("AdjustBasepoint");
|
|
212
|
+
element.classList.remove("active");
|
|
213
|
+
}));
|
|
214
|
+
break;
|
|
215
|
+
case "adjust":
|
|
216
|
+
element.dataset.state = "cancel";
|
|
217
|
+
element.innerText = i18n.t("Cancel");
|
|
218
|
+
const object = _3DXObjects.find(obj => obj.type == "BASEPOINT");
|
|
219
|
+
console.log("object", object);
|
|
220
|
+
setSelectedObject(object.object, object.node, object.component, object.type);
|
|
221
|
+
const selectedObj = {
|
|
222
|
+
object: object.object,
|
|
223
|
+
node: object.node,
|
|
224
|
+
component: object.component
|
|
225
|
+
};
|
|
226
|
+
setTransformControls(selectedObj);
|
|
227
|
+
toggleModelControl(true, 'translate');
|
|
228
|
+
break;
|
|
229
|
+
default:
|
|
230
|
+
console.error("Something went wrong!");
|
|
231
|
+
}
|
|
232
|
+
element.classList.toggle("active");
|
|
233
|
+
});
|
|
234
|
+
}
|
|
235
|
+
function displayConvertedCoordinates(payload) {
|
|
236
|
+
const convertedCoordinatesContainer = document.getElementById('at-converted-coordiantes-container');
|
|
237
|
+
convertedCoordinatesContainer.style.display = 'flex';
|
|
238
|
+
convertedCoordinatesContainer.innerHTML = ``;
|
|
239
|
+
const title = displayConvertedCoordinatesTitle();
|
|
240
|
+
const coordinateList = displayConvertedCoordinateListContainer(payload);
|
|
241
|
+
convertedCoordinatesContainer.appendChild(title);
|
|
242
|
+
convertedCoordinatesContainer.appendChild(coordinateList);
|
|
243
|
+
batchAddEventListenerByClassName('at_coordinate_title', (event) => {
|
|
244
|
+
console.log("I have been clicked");
|
|
245
|
+
const targetElement = event.target;
|
|
246
|
+
console.log("targetElement", targetElement);
|
|
247
|
+
const idName = targetElement.getAttribute('id').split('-').pop();
|
|
248
|
+
const element = document.getElementById(`at-xyz-coordinate-${idName}`);
|
|
249
|
+
const isHidden = element.style.display === 'block' || element.style.display === '';
|
|
250
|
+
element.style.display = isHidden ? 'none' : 'block';
|
|
251
|
+
// const chevronIcon = document.getElementById(`at-expand-btn-${faceId}`).querySelector(isHidden ? '.mdi-chevron-down' : '.mdi-chevron-up');
|
|
252
|
+
// chevronIcon.classList.toggle('mdi-chevron-down');
|
|
253
|
+
// chevronIcon.classList.toggle('mdi-chevron-up');
|
|
254
|
+
});
|
|
255
|
+
// displayCoordinateList()
|
|
256
|
+
}
|
|
257
|
+
function displayConvertedCoordinatesTitle() {
|
|
258
|
+
const element = document.createElement('div');
|
|
259
|
+
element.classList.add('at_converted_coordinates_title');
|
|
260
|
+
element.innerHTML = `
|
|
261
|
+
<div> </div>
|
|
262
|
+
<label for="">
|
|
263
|
+
<span class="mdi mdi-axis-arrow"></span>
|
|
264
|
+
${i18n.t('ConvertedCoordinates')}
|
|
265
|
+
</label>
|
|
266
|
+
<div> </div>
|
|
267
|
+
`;
|
|
268
|
+
return element;
|
|
269
|
+
}
|
|
270
|
+
function displayConvertedCoordinateListContainer(payload) {
|
|
271
|
+
const element = document.createElement('div');
|
|
272
|
+
element.classList.add('at_coordinate_list_container');
|
|
273
|
+
element.classList.add('at_scrollable_container');
|
|
274
|
+
const origin = displayOrigin();
|
|
275
|
+
element.appendChild(origin);
|
|
276
|
+
const items = ['Bim', 'Matterport'];
|
|
277
|
+
items.forEach(item => {
|
|
278
|
+
const el = displayCoordinatesItem(payload, item);
|
|
279
|
+
element.appendChild(el);
|
|
280
|
+
});
|
|
281
|
+
return element;
|
|
282
|
+
}
|
|
283
|
+
function displayOrigin() {
|
|
284
|
+
const element = document.createElement('div');
|
|
285
|
+
element.classList.add('at_origin_value_container');
|
|
286
|
+
element.classList.add('at_text_xs');
|
|
287
|
+
element.innerHTML = `
|
|
288
|
+
<div>
|
|
289
|
+
${i18n.t('Origin')}:
|
|
290
|
+
</div>
|
|
291
|
+
<div class="at_flex at_align_center at_gap_1">
|
|
292
|
+
x:
|
|
293
|
+
<div class="at_origin_value">0</div>
|
|
294
|
+
y:
|
|
295
|
+
<div class="at_origin_value">0</div>
|
|
296
|
+
z:
|
|
297
|
+
<div class="at_origin_value">0</div>
|
|
298
|
+
</div>
|
|
299
|
+
`;
|
|
300
|
+
return element;
|
|
301
|
+
}
|
|
302
|
+
function displayCoordinatesItem(payload, item) {
|
|
303
|
+
const element = document.createElement('div');
|
|
304
|
+
element.classList.add('at_coordinates_container');
|
|
305
|
+
const title = displayCoordinatesItemTitle(item);
|
|
306
|
+
element.appendChild(title);
|
|
307
|
+
let xyzCoordinates;
|
|
308
|
+
let temp;
|
|
309
|
+
if (item == "Bim") {
|
|
310
|
+
temp = convertYupToZup(payload);
|
|
311
|
+
console.log("Temp BIM", temp);
|
|
312
|
+
xyzCoordinates = displayXyzCoordinates(temp, item);
|
|
313
|
+
element.appendChild(xyzCoordinates);
|
|
314
|
+
return element;
|
|
315
|
+
}
|
|
316
|
+
console.log("Temp Matterport", payload);
|
|
317
|
+
xyzCoordinates = displayXyzCoordinates(payload, item);
|
|
318
|
+
element.appendChild(xyzCoordinates);
|
|
319
|
+
return element;
|
|
320
|
+
}
|
|
321
|
+
function displayCoordinatesItemTitle(title) {
|
|
322
|
+
const element = document.createElement('div');
|
|
323
|
+
element.classList.add('at_coordinate_title_container');
|
|
324
|
+
const idName = title.toLowerCase();
|
|
325
|
+
element.innerHTML = `
|
|
326
|
+
<div class="at_coordinate_title" id="at-coordinate-title-${idName}" data-cy="">
|
|
327
|
+
${i18n.t(title)}
|
|
328
|
+
<span class="mdi mdi-chevron-down" id="" data-cy=""></span>
|
|
329
|
+
</div>
|
|
330
|
+
`;
|
|
331
|
+
return element;
|
|
332
|
+
}
|
|
333
|
+
function displayXyzCoordinates(payload, item) {
|
|
334
|
+
const element = document.createElement('div');
|
|
335
|
+
element.classList.add('at_xyz_coordinate_container');
|
|
336
|
+
const idName = item.toLowerCase();
|
|
337
|
+
element.setAttribute('id', `at-xyz-coordinate-${idName}`);
|
|
338
|
+
element.innerHTML = `
|
|
339
|
+
<div class="at_xyz_coordinate">
|
|
340
|
+
<div class="at_bim_icon_left">x</div>
|
|
341
|
+
<div class="at_coordinate_value">${payload.x}</div>
|
|
342
|
+
<div class="at_bim_icon_right">m</div>
|
|
343
|
+
</div>
|
|
344
|
+
<div class="at_xyz_coordinate">
|
|
345
|
+
<div class="at_bim_icon_left">y</div>
|
|
346
|
+
<div class="at_coordinate_value">${payload.y}</div>
|
|
347
|
+
<div class="at_bim_icon_right">m</div>
|
|
348
|
+
</div>
|
|
349
|
+
<div class="at_xyz_coordinate">
|
|
350
|
+
<div class="at_bim_icon_left">z</div>
|
|
351
|
+
<div class="at_coordinate_value">${payload.z}</div>
|
|
352
|
+
<div class="at_bim_icon_right">m</div>
|
|
353
|
+
</div>
|
|
354
|
+
`;
|
|
355
|
+
return element;
|
|
356
|
+
}
|
|
357
|
+
/* SETTERS AND GETTERS */
|
|
358
|
+
export function getCoordinateSystem() {
|
|
359
|
+
return coordinateSystem;
|
|
360
|
+
}
|
|
361
|
+
export function setCoordinateSystem(value) {
|
|
362
|
+
coordinateSystem = value;
|
|
363
|
+
let text = value;
|
|
364
|
+
text = text.charAt(0).toUpperCase() + text.substring(1).toLowerCase();
|
|
365
|
+
document.getElementById('at-coordinate-system-text').innerText = `${i18n.t("CoordinateSystem")}: ${i18n.t(text)}`;
|
|
366
|
+
console.log("Coordinate System set to:", value);
|
|
367
|
+
}
|
|
368
|
+
export function getScaleFactor() {
|
|
369
|
+
return scaleFactor;
|
|
370
|
+
}
|
|
371
|
+
export function setScaleFactor(value) {
|
|
372
|
+
scaleFactor = value;
|
|
373
|
+
console.log("Scale Factor set to:", value);
|
|
374
|
+
}
|
|
375
|
+
export function getMeasurementUnit() {
|
|
376
|
+
return measurementUnit;
|
|
377
|
+
}
|
|
378
|
+
export function setMeasurementUnit(value) {
|
|
379
|
+
measurementUnit = value;
|
|
380
|
+
console.log("Measurement Unit set to:", value);
|
|
381
|
+
}
|
|
382
|
+
export function getRotationUnit() {
|
|
383
|
+
return rotationUnit;
|
|
384
|
+
}
|
|
385
|
+
export function setRotationUnit(value) {
|
|
386
|
+
rotationUnit = value;
|
|
387
|
+
console.log("Rotation Unit set to:", value);
|
|
388
|
+
}
|
|
389
|
+
export function setTempCoordinateSystem(value) {
|
|
390
|
+
tempCoordinateSystem = value;
|
|
391
|
+
}
|
|
392
|
+
export function getTempCoordinateSystem() {
|
|
393
|
+
return tempCoordinateSystem;
|
|
394
|
+
}
|
|
395
|
+
export function setTempScaleFactor(value) {
|
|
396
|
+
tempScaleFactor = value;
|
|
397
|
+
}
|
|
398
|
+
export function getTempScaleFactor() {
|
|
399
|
+
return tempScaleFactor;
|
|
400
|
+
}
|
|
401
|
+
export function setTempMeasurementUnit(value) {
|
|
402
|
+
tempMeasurementUnit = value;
|
|
403
|
+
}
|
|
404
|
+
export function getTempMeasurementUnit() {
|
|
405
|
+
return tempMeasurementUnit;
|
|
406
|
+
}
|
|
407
|
+
export function setTempRotationUnit(value) {
|
|
408
|
+
tempRotationUnit = value;
|
|
409
|
+
}
|
|
410
|
+
export function getTempRotationUnit() {
|
|
411
|
+
return tempRotationUnit;
|
|
412
|
+
}
|
|
413
|
+
export function setBasepoint(value) {
|
|
414
|
+
basepoint = value;
|
|
415
|
+
}
|
|
416
|
+
export function getBasepoint() {
|
|
417
|
+
return basepoint;
|
|
418
|
+
}
|
|
419
|
+
export function setTempBasepoint(value) {
|
|
420
|
+
tempBasepoint = value;
|
|
421
|
+
}
|
|
422
|
+
export function getTempBasepoint() {
|
|
423
|
+
return tempBasepoint;
|
|
424
|
+
}
|
|
@@ -126,7 +126,21 @@ i18n
|
|
|
126
126
|
"Area": "Area",
|
|
127
127
|
"DeleteWall": "Delete Wall",
|
|
128
128
|
"SuccessWallDelete": "Successfully deleted wall",
|
|
129
|
-
"WarnLowFloor": "The marked area may be lower than the floor of the space"
|
|
129
|
+
"WarnLowFloor": "The marked area may be lower than the floor of the space",
|
|
130
|
+
"Settings": "Settings",
|
|
131
|
+
"CoordinateSystem": "Coordinate System",
|
|
132
|
+
"Matterport": "Matterport (Y-up)",
|
|
133
|
+
"Bim": "BIM/CAD (Z-up)",
|
|
134
|
+
"MeasurementUnit": "Measurement Unit",
|
|
135
|
+
"Meter": "Meter",
|
|
136
|
+
"Foot": "Foot",
|
|
137
|
+
"Inch": "Inch",
|
|
138
|
+
"RotationUnit": "Rotation Unit",
|
|
139
|
+
"Radian": "Radian",
|
|
140
|
+
"Degree": "Degree",
|
|
141
|
+
"CoordinateNote": "The coordinate from your CAD or either BIM tools shall be internally converted to the appropriate coordinate used by the Matterport space.",
|
|
142
|
+
"CalibrateBasepoint": "Calibrate Basepoint",
|
|
143
|
+
"AdjustBasepoint": "Adjust Basepoint",
|
|
130
144
|
}
|
|
131
145
|
},
|
|
132
146
|
ja: {
|
|
@@ -247,7 +261,19 @@ i18n
|
|
|
247
261
|
"Area": "面積",
|
|
248
262
|
"DeleteWall": "ウォール削除",
|
|
249
263
|
"SuccessWallDelete": "削除しました",
|
|
250
|
-
"WarnLowFloor": "Tマークされたエリアは、スペースの床よりも低い場合があります"
|
|
264
|
+
"WarnLowFloor": "Tマークされたエリアは、スペースの床よりも低い場合があります",
|
|
265
|
+
"Settings": "BIM/CAD設定",
|
|
266
|
+
"CoordinateSystem": "設定システム選択",
|
|
267
|
+
"Matterport": "Matterport (Y-up)",
|
|
268
|
+
"Bim": "BIM/CAD (Z-up)",
|
|
269
|
+
"MeasurementUnit": "長さ単位",
|
|
270
|
+
"Meter": "メートル",
|
|
271
|
+
"Foot": "フィート",
|
|
272
|
+
"Inch": "インチ",
|
|
273
|
+
"RotationUnit": "回転単位",
|
|
274
|
+
"Radian": "ラジアン",
|
|
275
|
+
"Degree": "度",
|
|
276
|
+
"CoordinateNote": "CAD または BIM ツールからの座標は、Matterport スペースで使用される適切な座標に内部的に変換される必要があります。",
|
|
251
277
|
}
|
|
252
278
|
}
|
|
253
279
|
},
|
|
@@ -11,6 +11,7 @@ import { renderRecepientOptions, renderTagMessages, createTagMessage, setTagMess
|
|
|
11
11
|
import { clearTagFormDropdown, clearTagFilterDropdown } from "./tagFormPane";
|
|
12
12
|
import { toggleModal, setModalAction } from "./modal";
|
|
13
13
|
import { toggleModelControl } from "./modelControlsPane";
|
|
14
|
+
import { toggleActionSettings } from "./actionSettingsPane";
|
|
14
15
|
import './i18n';
|
|
15
16
|
declare let actionBar: HTMLElement;
|
|
16
17
|
/**
|
|
@@ -20,4 +21,4 @@ declare let actionBar: HTMLElement;
|
|
|
20
21
|
*/
|
|
21
22
|
declare function setPreferredLanguage(): void;
|
|
22
23
|
declare function renderToolbarUI(payload: IToolbarData): void;
|
|
23
|
-
export { actionBar, tagFormMode, selectedTag, selectedCategoryFilterId, selectedSubCategoryFilterId, renderToolbarUI, renderObjectCards, setActiveMenu, clearActiveMenu, setActiveActionBtn, renderLibraryCards, renderTags, getTagFormData, renderTagRow, addClickEventToTagRow, setTagCategoriesOption, setActiveThemeCard, setActiveCard, setActiveLibraryCard, clearActiveCard, clearActiveLibraryCard, removeObjectCard, renderRecepientOptions, renderTagMessages, createTagMessage, renderCategoryDropdownOptions, toggleDropdown, setTagLink, getTagLink, setTagMessagingDetails, clearTagFormDropdown, clearTagFilterDropdown, getObjectListStatus, toggleModal, setModalAction, toggleModelControl, clearActiveActionBtn, toggleActionBarButtons, filterTagList, setPreferredLanguage };
|
|
24
|
+
export { actionBar, tagFormMode, selectedTag, selectedCategoryFilterId, selectedSubCategoryFilterId, renderToolbarUI, renderObjectCards, setActiveMenu, clearActiveMenu, setActiveActionBtn, renderLibraryCards, renderTags, getTagFormData, renderTagRow, addClickEventToTagRow, setTagCategoriesOption, setActiveThemeCard, setActiveCard, setActiveLibraryCard, clearActiveCard, clearActiveLibraryCard, removeObjectCard, renderRecepientOptions, renderTagMessages, createTagMessage, renderCategoryDropdownOptions, toggleDropdown, setTagLink, getTagLink, setTagMessagingDetails, clearTagFormDropdown, clearTagFilterDropdown, getObjectListStatus, toggleModal, setModalAction, toggleModelControl, toggleActionSettings, clearActiveActionBtn, toggleActionBarButtons, filterTagList, setPreferredLanguage };
|
|
@@ -15,13 +15,14 @@ import { renderRecepientOptions, renderTagMessages, createTagMessage, setTagMess
|
|
|
15
15
|
import { clearTagFormDropdown, clearTagFilterDropdown } from "./tagFormPane";
|
|
16
16
|
import { renderModal, toggleModal, setModalAction } from "./modal";
|
|
17
17
|
import { renderModelControlPane, toggleModelControl } from "./modelControlsPane";
|
|
18
|
+
import { renderActionSettingsPane, toggleActionSettings } from "./actionSettingsPane";
|
|
18
19
|
import { getURLParams } from "../../../utils";
|
|
19
20
|
import './i18n';
|
|
20
21
|
import i18n from './i18n';
|
|
21
22
|
import { renderRoomTreePane } from "./spacePartition/roomTreePane";
|
|
22
23
|
import { renderRoomFormPane } from "./spacePartition/roomFormPane";
|
|
23
24
|
let iFrame, sidebarContainer;
|
|
24
|
-
let menuBar, actionBar, objectListPane, addObjectPane, tagListPane, tagFormPane, addMediaScreenForm, libraryPane, tagMessagingPane, themePane, modelControlPane, roomTreePane, roomFormPane;
|
|
25
|
+
let menuBar, actionBar, objectListPane, addObjectPane, tagListPane, tagFormPane, addMediaScreenForm, libraryPane, tagMessagingPane, themePane, modelControlPane, actionSettingsPane, roomTreePane, roomFormPane;
|
|
25
26
|
function getIframeElement(iframeId) {
|
|
26
27
|
if (!iframeId || iframeId === '') {
|
|
27
28
|
console.error("IframeId is empty or undefined");
|
|
@@ -87,9 +88,11 @@ function renderToolbarUI(payload) {
|
|
|
87
88
|
modelControlPane = renderModelControlPane();
|
|
88
89
|
roomTreePane = renderRoomTreePane();
|
|
89
90
|
roomFormPane = renderRoomFormPane();
|
|
91
|
+
actionSettingsPane = renderActionSettingsPane();
|
|
90
92
|
renderModal();
|
|
91
93
|
sidebarContainer.appendChild(modelControlPane);
|
|
92
94
|
sidebarContainer.appendChild(actionBar);
|
|
95
|
+
sidebarContainer.appendChild(actionSettingsPane);
|
|
93
96
|
sidebarContainer.appendChild(roomTreePane);
|
|
94
97
|
sidebarContainer.appendChild(roomFormPane);
|
|
95
98
|
sidebarContainer.appendChild(themePane);
|
|
@@ -117,6 +120,7 @@ function renderToolbarUI(payload) {
|
|
|
117
120
|
themePane.style.display = 'none';
|
|
118
121
|
roomTreePane.style.display = 'none';
|
|
119
122
|
roomFormPane.style.display = 'none';
|
|
123
|
+
actionSettingsPane.style.display = 'none';
|
|
120
124
|
const customTheme = window.localStorage.getItem('customizedTheme');
|
|
121
125
|
if (customTheme && customTheme !== '') {
|
|
122
126
|
console.log("customTheme: ", customTheme);
|
|
@@ -127,4 +131,4 @@ function renderToolbarUI(payload) {
|
|
|
127
131
|
themeManager(config);
|
|
128
132
|
}
|
|
129
133
|
}
|
|
130
|
-
export { actionBar, tagFormMode, selectedTag, selectedCategoryFilterId, selectedSubCategoryFilterId, renderToolbarUI, renderObjectCards, setActiveMenu, clearActiveMenu, setActiveActionBtn, renderLibraryCards, renderTags, getTagFormData, renderTagRow, addClickEventToTagRow, setTagCategoriesOption, setActiveThemeCard, setActiveCard, setActiveLibraryCard, clearActiveCard, clearActiveLibraryCard, removeObjectCard, renderRecepientOptions, renderTagMessages, createTagMessage, renderCategoryDropdownOptions, toggleDropdown, setTagLink, getTagLink, setTagMessagingDetails, clearTagFormDropdown, clearTagFilterDropdown, getObjectListStatus, toggleModal, setModalAction, toggleModelControl, clearActiveActionBtn, toggleActionBarButtons, filterTagList, setPreferredLanguage };
|
|
134
|
+
export { actionBar, tagFormMode, selectedTag, selectedCategoryFilterId, selectedSubCategoryFilterId, renderToolbarUI, renderObjectCards, setActiveMenu, clearActiveMenu, setActiveActionBtn, renderLibraryCards, renderTags, getTagFormData, renderTagRow, addClickEventToTagRow, setTagCategoriesOption, setActiveThemeCard, setActiveCard, setActiveLibraryCard, clearActiveCard, clearActiveLibraryCard, removeObjectCard, renderRecepientOptions, renderTagMessages, createTagMessage, renderCategoryDropdownOptions, toggleDropdown, setTagLink, getTagLink, setTagMessagingDetails, clearTagFormDropdown, clearTagFilterDropdown, getObjectListStatus, toggleModal, setModalAction, toggleModelControl, toggleActionSettings, clearActiveActionBtn, toggleActionBarButtons, filterTagList, setPreferredLanguage };
|
|
@@ -3,6 +3,7 @@ export declare let isObjectListEnabled: boolean;
|
|
|
3
3
|
export declare let isMeetingEnabled: boolean;
|
|
4
4
|
export declare let isThemeEnabled: boolean;
|
|
5
5
|
export declare let isRoomCreationEnabled: boolean;
|
|
6
|
+
export declare let isBIMEnabled: boolean;
|
|
6
7
|
export declare function renderMenuBar(iFrame: HTMLIFrameElement): HTMLDivElement;
|
|
7
8
|
export declare function setActiveMenu(id: string): void;
|
|
8
9
|
export declare function clearActiveMenu(id: string): void;
|
|
@@ -7,7 +7,7 @@ export let isObjectListEnabled = true;
|
|
|
7
7
|
export let isMeetingEnabled = false;
|
|
8
8
|
export let isThemeEnabled = true;
|
|
9
9
|
export let isRoomCreationEnabled = true;
|
|
10
|
-
let isBIMEnabled = true;
|
|
10
|
+
export let isBIMEnabled = true;
|
|
11
11
|
export function renderMenuBar(iFrame) {
|
|
12
12
|
if (!iFrame) {
|
|
13
13
|
log.error(`Could not find target iFrame`);
|
|
@@ -48,6 +48,10 @@ export function renderMenuBar(iFrame) {
|
|
|
48
48
|
<span class="mdi mdi-ruler-square-compass" id="at-room-creation-btn" data-cy="at-room-creation-btn" target-pane="at-room-tree-pane"></span>
|
|
49
49
|
<div class="at_icon_tooltip" data-cy="at-tooltip-theme">${i18n.t('RoomCreation')}</div>
|
|
50
50
|
</div>
|
|
51
|
+
<div class="at_sidebar_button_icon" style="display:${isBIMEnabled ? 'block' : 'none'}">
|
|
52
|
+
<img class="at_bim_settings_img" src="../../node_modules/architwin/static/bim.png" alt="bim" id="at-settings-btn" data-cy="at-settings-btn" target-pane="at-settings-pane"/>
|
|
53
|
+
<div class="at_icon_tooltip" data-cy="at-tooltip-settings">${i18n.t('Settings')}</div>
|
|
54
|
+
</div>
|
|
51
55
|
`;
|
|
52
56
|
return menuBarElement;
|
|
53
57
|
}
|
|
@@ -58,6 +62,7 @@ export function renderMenuBar(iFrame) {
|
|
|
58
62
|
function setMenuItemsStatus() {
|
|
59
63
|
const toolbarConfig = _mpConfig.toolbarConfig;
|
|
60
64
|
const menuItems = _mpConfig.toolbarConfig.menuItems;
|
|
65
|
+
console.log("menuItems", menuItems);
|
|
61
66
|
if (toolbarConfig && menuItems) {
|
|
62
67
|
// MEETING
|
|
63
68
|
if (menuItems.meeting !== undefined) {
|
|
@@ -102,6 +107,7 @@ export function setActiveMenu(id) {
|
|
|
102
107
|
case 'at-minimap-btn':
|
|
103
108
|
case 'at-theme-picker-btn':
|
|
104
109
|
case 'at-room-creation-btn':
|
|
110
|
+
case 'at-settings-btn':
|
|
105
111
|
if (parent.classList.contains('at_sidebar_button_icon_active')) {
|
|
106
112
|
// remove
|
|
107
113
|
log.info("removing active...");
|
|
@@ -136,7 +142,10 @@ export function clearActiveMenu(id) {
|
|
|
136
142
|
log.info("clearActiveMenu: ", id);
|
|
137
143
|
if (id != 'at-minimap-btn' && activeMenu) {
|
|
138
144
|
// get child id
|
|
139
|
-
|
|
145
|
+
let activeChildId = (_b = (_a = activeMenu.querySelector('.mdi')) === null || _a === void 0 ? void 0 : _a.id) !== null && _b !== void 0 ? _b : undefined;
|
|
146
|
+
if (id == 'at-settings-btn') {
|
|
147
|
+
activeChildId = "at-settings-btn";
|
|
148
|
+
}
|
|
140
149
|
log.info("activeChildId: ", activeChildId);
|
|
141
150
|
// check if active menu and target menu id are the same
|
|
142
151
|
// if true do not set inactive otherwise, remove
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { degreesToRadians, radiansToDegrees, useCapitalizeFirstLetter } from "../../../utils";
|
|
2
2
|
import { getSelectedObject } from "../../../architwin";
|
|
3
|
+
import { convertYupToZup } from "../../../worldConversion";
|
|
3
4
|
import { Notyf } from 'notyf';
|
|
4
5
|
import log from 'loglevel';
|
|
5
6
|
import i18n from "./i18n";
|
|
@@ -11,10 +12,11 @@ let inputX;
|
|
|
11
12
|
let inputY;
|
|
12
13
|
let inputZ;
|
|
13
14
|
let isInputEventListenerSet = false;
|
|
15
|
+
// let coordX:string = ""
|
|
14
16
|
export function renderModelControlPane(type = 'Translate') {
|
|
15
17
|
const element = document.createElement('div');
|
|
16
18
|
element.classList.add('at_container');
|
|
17
|
-
element.classList.add('at_h-
|
|
19
|
+
element.classList.add('at_h-full');
|
|
18
20
|
element.setAttribute('id', 'at-model-control-pane');
|
|
19
21
|
element.setAttribute('data-cy', 'at-model-control-pane');
|
|
20
22
|
element.innerHTML = `
|
|
@@ -24,6 +26,7 @@ export function renderModelControlPane(type = 'Translate') {
|
|
|
24
26
|
<span class="at_bolder at_text_base" id="at-transform-type-title">${i18n.t(type)}</span>
|
|
25
27
|
<span class="mdi mdi-close at_text_base" style="cursor:pointer" id="at-close-model-controls" data-cy="at-close-model-controls"></span>
|
|
26
28
|
</div>
|
|
29
|
+
<span id="at-coordinate-system-text" class="at_text_xs">${i18n.t("CoordinateSystem")}: ${i18n.t("Matterport")}</span>
|
|
27
30
|
<div class="at_number_field">
|
|
28
31
|
<span class="at_bolder">X</span>
|
|
29
32
|
<input type="number" id="at-input-x" class="at_rounded_input"/>
|
|
@@ -39,7 +42,19 @@ export function renderModelControlPane(type = 'Translate') {
|
|
|
39
42
|
<input type="number" id="at-input-z" class="at_rounded_input"/>
|
|
40
43
|
<span class="at_bolder at_model_unit">m</span>
|
|
41
44
|
</div>
|
|
42
|
-
<
|
|
45
|
+
<div class="at_mt_static_text at_mt_static_text_container at_inline_block at_rounded">
|
|
46
|
+
<span class="at_text_xxs at_mx-w-16" id="at-transform-note">Matterport</span>
|
|
47
|
+
<span class="at_text_xxs">x:</span>
|
|
48
|
+
<span class="at_text_xxs at_mt_cal_text" id="at-mt-coordx"></span>
|
|
49
|
+
<span class="at_text_xxs">y:</span>
|
|
50
|
+
<span class="at_text_xxs at_mt_cal_text" id="at-mt-coordy"></span>
|
|
51
|
+
<span class="at_text_xxs">z:</span>
|
|
52
|
+
<span class="at_text_xxs at_mt_cal_text" id="at-mt-coordz"></span>
|
|
53
|
+
</div>
|
|
54
|
+
<span class="at_text_xxs at_mx-w-16" id="at-transform-note">
|
|
55
|
+
${i18n.t("CoordinateNote")}
|
|
56
|
+
</span>
|
|
57
|
+
<button class="at_button at_cat_confirm_btn" id="at-confirm-transform" data-cy="at-confirm-transform">${i18n.t('Confirm')}</button>
|
|
43
58
|
</div>
|
|
44
59
|
</div>
|
|
45
60
|
`;
|
|
@@ -54,6 +69,7 @@ export function toggleModelControl(visible = true, type = 'translate') {
|
|
|
54
69
|
modelControlPane.style.display = 'block';
|
|
55
70
|
setTransformType(type);
|
|
56
71
|
showCurrentCoordinateValue();
|
|
72
|
+
log.info("=====test toggle: ", type);
|
|
57
73
|
return;
|
|
58
74
|
}
|
|
59
75
|
modelControlPane.style.display = 'none';
|
|
@@ -159,6 +175,7 @@ export function showCurrentCoordinateValue(payload) {
|
|
|
159
175
|
inputX.value = currentPos.x.toFixed(3).toString();
|
|
160
176
|
inputY.value = currentPos.y.toFixed(3).toString();
|
|
161
177
|
inputZ.value = currentPos.z.toFixed(3).toString();
|
|
178
|
+
updateDisplayedCoordinates();
|
|
162
179
|
}
|
|
163
180
|
else if (transformType == 'rotate') {
|
|
164
181
|
//@ts-expect-error
|
|
@@ -176,12 +193,14 @@ export function showCurrentCoordinateValue(payload) {
|
|
|
176
193
|
inputX.setAttribute('radian-value', rotationDegreeFormat.x.toString());
|
|
177
194
|
inputY.setAttribute('radian-value', rotationDegreeFormat.y.toString());
|
|
178
195
|
inputZ.setAttribute('radian-value', rotationDegreeFormat.z.toString());
|
|
196
|
+
updateDisplayedCoordinates();
|
|
179
197
|
}
|
|
180
198
|
else if (transformType == 'scale') {
|
|
181
199
|
const currentScale = selectedObject.node.scale;
|
|
182
200
|
inputX.value = currentScale.x.toFixed(3).toString();
|
|
183
201
|
inputY.value = currentScale.y.toFixed(3).toString();
|
|
184
202
|
inputZ.value = currentScale.z.toFixed(3).toString();
|
|
203
|
+
updateDisplayedCoordinates();
|
|
185
204
|
}
|
|
186
205
|
}
|
|
187
206
|
function setModelInputUnit(type) {
|
|
@@ -241,4 +260,70 @@ export function handleModelControlInputs() {
|
|
|
241
260
|
inputX.addEventListener('input', onModelControlInput);
|
|
242
261
|
inputY.addEventListener('input', onModelControlInput);
|
|
243
262
|
inputZ.addEventListener('input', onModelControlInput);
|
|
263
|
+
updateDisplayedCoordinates();
|
|
264
|
+
}
|
|
265
|
+
function updateDisplayedCoordinates() {
|
|
266
|
+
log.info("=====updating coordinates: ");
|
|
267
|
+
const selectedObject = getSelectedObject();
|
|
268
|
+
// const scaleFactor = getScaleFactor()
|
|
269
|
+
// const measurementUnit = getMeasurementUnit()
|
|
270
|
+
// const basePoint = getBasepoint()
|
|
271
|
+
// let coordX: string = inputX.value
|
|
272
|
+
// let coordY: string = inputY.value
|
|
273
|
+
// let coordZ: string = inputZ.value
|
|
274
|
+
// if (coordX) {
|
|
275
|
+
// document.getElementById("at-mt-coordx").textContent = coordX;
|
|
276
|
+
// }
|
|
277
|
+
// if (coordY) {
|
|
278
|
+
// document.getElementById("at-mt-coordy").textContent = coordY;
|
|
279
|
+
// }
|
|
280
|
+
// if (coordZ) {
|
|
281
|
+
// document.getElementById("at-mt-coordz").textContent = coordZ;
|
|
282
|
+
// }
|
|
283
|
+
// if (coordX && coordY && coordZ) {
|
|
284
|
+
// const object = {
|
|
285
|
+
// x: Number(inputX.value),
|
|
286
|
+
// y: Number(inputY.value),
|
|
287
|
+
// z: Number(inputZ.value)
|
|
288
|
+
// } as Vector3
|
|
289
|
+
// log.info("=====test Object to update: ", object)
|
|
290
|
+
// const convert = convertYupToZup(object)
|
|
291
|
+
// if (convert) {
|
|
292
|
+
// log.info("=====test Convert Text: ", convert)
|
|
293
|
+
// }
|
|
294
|
+
// }
|
|
295
|
+
if (inputX && inputY && inputZ && selectedObject) {
|
|
296
|
+
const transform = getCoordinateValues();
|
|
297
|
+
// log.info("======Testing from: ", scaleFactor, measurementUnit, basePoint)
|
|
298
|
+
log.info("=====text Selected Object: ", selectedObject);
|
|
299
|
+
const object = {
|
|
300
|
+
x: Number(inputX.value),
|
|
301
|
+
y: Number(inputY.value),
|
|
302
|
+
z: Number(inputZ.value)
|
|
303
|
+
};
|
|
304
|
+
log.info("=====test Object to update: ", object);
|
|
305
|
+
const convert = convertYupToZup(object);
|
|
306
|
+
// when converted value exists
|
|
307
|
+
if (convert) {
|
|
308
|
+
log.info("=====test Convert Text: ", convert);
|
|
309
|
+
document.getElementById("at-mt-coordx").textContent = convert.x.toString();
|
|
310
|
+
document.getElementById("at-mt-coordy").textContent = convert.y.toString();
|
|
311
|
+
document.getElementById("at-mt-coordz").textContent = convert.z.toString();
|
|
312
|
+
// if (selectedObject) {
|
|
313
|
+
// if (transformType == 'translate') {
|
|
314
|
+
// log.info("=====test Translate: ", transform, convert)
|
|
315
|
+
// transform.object_position = convert
|
|
316
|
+
// setObjectTransformation(selectedObject.node, transform)
|
|
317
|
+
// } else if (transformType == 'rotate') {
|
|
318
|
+
// log.info("=====test Rotate: ", transform, convert)
|
|
319
|
+
// transform.object_rotation = convert
|
|
320
|
+
// setObjectTransformation(selectedObject.node, transform)
|
|
321
|
+
// } else if (transformType == 'scale') {
|
|
322
|
+
// log.info("=====test Scale: ", transform, convert)
|
|
323
|
+
// transform.object_scale = convert
|
|
324
|
+
// setObjectTransformation(selectedObject.node, transform)
|
|
325
|
+
// }
|
|
326
|
+
// }
|
|
327
|
+
}
|
|
328
|
+
}
|
|
244
329
|
}
|
package/lib/atwinui/events.js
CHANGED
|
@@ -25,6 +25,7 @@ import * as minimap from '../minimap';
|
|
|
25
25
|
import { clearActiveThemeCard, getSelectedTheme } from "./components/toolbar/themePane";
|
|
26
26
|
import { getCurrentEditRoomData, displayRoomTree, updatePartitionVisibilityUI, getSelectedPartitionId, updatePolygonVisibilityData, toggleVisibilityState, setFilteredDisplay, updateRoomVisibilityUI } from "./components/toolbar/spacePartition/roomTreePane";
|
|
27
27
|
import { toggleDrawPartitionButton, displayPartitionFormMode, setPartitionFormMode, clearPartitionForm, setPolygonData, getPartitionFormData, getPartitionSavingMode, setPartitionSavingMode, getPartitionFormMode, getNewlyAddedPartition, setCurrentPartitionData, getTempCurrentPolygon, clearTempCurrentPolygon } from "./components/toolbar/spacePartition/roomFormPane";
|
|
28
|
+
import { actionSettingsSelectOption, getTempCoordinateSystem, getTempMeasurementUnit, getTempRotationUnit, setCoordinateSystem, setMeasurementUnit, setRotationUnit, initSettingsValues, setTempCoordinateSystem, setTempMeasurementUnit, setTempRotationUnit, toggleActionSettingsDropdown, toggleCalibrateBasepoint, setScaleFactor, getTempScaleFactor, setTempScaleFactor, setBasepoint, getTempBasepoint, setTempBasepoint, getBasepoint } from "./components/toolbar/actionSettingsPane";
|
|
28
29
|
let activeToolbarItem, activeActionItem, activePane, activeActionPane, cancelTagPlacementPrompt, cancelModelPlacementPrompt;
|
|
29
30
|
let notyf = new Notyf({ position: { x: 'left', y: 'bottom' }, duration: 4500, types: [
|
|
30
31
|
{
|
|
@@ -99,7 +100,9 @@ function toggleDisplayPane(targetId) {
|
|
|
99
100
|
return;
|
|
100
101
|
}
|
|
101
102
|
const clickedElement = document.getElementById(targetId);
|
|
103
|
+
console.log("Testing: ", clickedElement);
|
|
102
104
|
const paneId = clickedElement.getAttribute('target-pane');
|
|
105
|
+
console.log("Testing: ", paneId);
|
|
103
106
|
if (paneId != null && paneId != '') {
|
|
104
107
|
log.info("paneElement", paneId);
|
|
105
108
|
_currentPaneId = paneId;
|
|
@@ -136,7 +139,7 @@ function toggleDisplayPane(targetId) {
|
|
|
136
139
|
if (paneId === 'at-object-list-pane') {
|
|
137
140
|
const objectsInSpace = get3DXObjects();
|
|
138
141
|
const objectComponents = objectsInSpace.map(obj => obj.component);
|
|
139
|
-
const spaceObjects = objectsInSpace.filter(obj => obj.type !== 'POLYGON').map(obj => obj.object);
|
|
142
|
+
const spaceObjects = objectsInSpace.filter(obj => obj.type !== 'POLYGON' && obj.type !== 'BASEPOINT').map(obj => obj.object);
|
|
140
143
|
renderObjectCards(spaceObjects, objectComponents);
|
|
141
144
|
if (targetId === 'at-cancel-library-btn') {
|
|
142
145
|
yield cancelModelPlacement();
|
|
@@ -206,15 +209,34 @@ function toggleDisplayPane(targetId) {
|
|
|
206
209
|
log.info("Room Form Pane");
|
|
207
210
|
displayPartitionFormMode();
|
|
208
211
|
}
|
|
212
|
+
if (paneId === 'at-settings-pane') {
|
|
213
|
+
log.info("at-settings-pane");
|
|
214
|
+
setTempBasepoint(undefined);
|
|
215
|
+
initSettingsValues();
|
|
216
|
+
}
|
|
217
|
+
if (!getBasepoint()) {
|
|
218
|
+
const target = _3DXObjects.find(obj => obj.type === 'BASEPOINT');
|
|
219
|
+
if (target)
|
|
220
|
+
disposeModel(target);
|
|
221
|
+
}
|
|
209
222
|
return;
|
|
210
223
|
}
|
|
211
224
|
else {
|
|
212
225
|
activePane = null;
|
|
213
226
|
paneElement.style.display = 'none';
|
|
227
|
+
if (!getBasepoint()) {
|
|
228
|
+
const target = _3DXObjects.find(obj => obj.type === 'BASEPOINT');
|
|
229
|
+
if (target)
|
|
230
|
+
disposeModel(target);
|
|
231
|
+
setTempBasepoint(undefined);
|
|
232
|
+
removeTransformControls();
|
|
233
|
+
clearSelectedObject();
|
|
234
|
+
cancelModelPlacement();
|
|
235
|
+
}
|
|
214
236
|
return;
|
|
215
237
|
}
|
|
216
238
|
}
|
|
217
|
-
log.error('Could not get value of target-
|
|
239
|
+
log.error('Could not get value of target-pane attribute');
|
|
218
240
|
return;
|
|
219
241
|
});
|
|
220
242
|
}
|
|
@@ -271,6 +293,12 @@ function setupIndividualEventListeners() {
|
|
|
271
293
|
handleSpacePartitionReport();
|
|
272
294
|
handleUndoDrawAction();
|
|
273
295
|
handleRedoDrawAction();
|
|
296
|
+
handleMeasurementUnitDropdown();
|
|
297
|
+
handleRotationUnitDropdown();
|
|
298
|
+
handleCoordinateSystem();
|
|
299
|
+
handleScaleFactorSettings();
|
|
300
|
+
handleSaveActionSettings();
|
|
301
|
+
handleCalibrateBasepoint();
|
|
274
302
|
}
|
|
275
303
|
//================ OBJECT EVENT HANDLERS ===============//
|
|
276
304
|
function handleTranslateObject() {
|
|
@@ -1088,6 +1116,8 @@ function handleConfirmTransform() {
|
|
|
1088
1116
|
dispatchSpaceEvent(SPACE_EVENTS.DRAG_END, payload);
|
|
1089
1117
|
removeTransformControls();
|
|
1090
1118
|
}
|
|
1119
|
+
const adjustBasepointBtn = document.getElementById('at-calibrate-basepoint-btn');
|
|
1120
|
+
adjustBasepointBtn.innerText = i18n.t('Close');
|
|
1091
1121
|
});
|
|
1092
1122
|
}
|
|
1093
1123
|
}
|
|
@@ -2005,6 +2035,67 @@ function handleRedoDrawAction() {
|
|
|
2005
2035
|
redoDrawAction();
|
|
2006
2036
|
}));
|
|
2007
2037
|
}
|
|
2038
|
+
function handleMeasurementUnitDropdown() {
|
|
2039
|
+
const dropdownBtn = document.getElementById('at-selected-measurement-unit');
|
|
2040
|
+
const optionsContainer = document.getElementById('at-measurement-unit-options');
|
|
2041
|
+
dropdownBtn === null || dropdownBtn === void 0 ? void 0 : dropdownBtn.addEventListener('click', () => {
|
|
2042
|
+
toggleActionSettingsDropdown('at-measurement-unit-options');
|
|
2043
|
+
});
|
|
2044
|
+
optionsContainer === null || optionsContainer === void 0 ? void 0 : optionsContainer.addEventListener('click', (event) => {
|
|
2045
|
+
const target = event.target;
|
|
2046
|
+
if (target.classList.contains('at_option')) {
|
|
2047
|
+
actionSettingsSelectOption(target, 'measurement-unit');
|
|
2048
|
+
setTempMeasurementUnit(target.dataset.value);
|
|
2049
|
+
}
|
|
2050
|
+
});
|
|
2051
|
+
}
|
|
2052
|
+
function handleRotationUnitDropdown() {
|
|
2053
|
+
const dropdownBtn = document.getElementById('at-selected-rotation-unit');
|
|
2054
|
+
const optionsContainer = document.getElementById('at-rotation-unit-options');
|
|
2055
|
+
dropdownBtn === null || dropdownBtn === void 0 ? void 0 : dropdownBtn.addEventListener('click', () => {
|
|
2056
|
+
toggleActionSettingsDropdown('at-rotation-unit-options');
|
|
2057
|
+
});
|
|
2058
|
+
optionsContainer === null || optionsContainer === void 0 ? void 0 : optionsContainer.addEventListener('click', (event) => {
|
|
2059
|
+
const target = event.target;
|
|
2060
|
+
if (target.classList.contains('at_option')) {
|
|
2061
|
+
actionSettingsSelectOption(target, 'rotation-unit');
|
|
2062
|
+
setTempRotationUnit(target.dataset.value);
|
|
2063
|
+
}
|
|
2064
|
+
});
|
|
2065
|
+
}
|
|
2066
|
+
function handleCoordinateSystem() {
|
|
2067
|
+
document.querySelectorAll('input[name="coordinate-system"]').forEach(input => {
|
|
2068
|
+
input.addEventListener('change', (event) => {
|
|
2069
|
+
const target = event.target;
|
|
2070
|
+
setTempCoordinateSystem(target.value);
|
|
2071
|
+
});
|
|
2072
|
+
});
|
|
2073
|
+
}
|
|
2074
|
+
function handleScaleFactorSettings() {
|
|
2075
|
+
const scaleFactor = document.getElementById('at-settings-scale-factor-input');
|
|
2076
|
+
scaleFactor.addEventListener('change', (event) => {
|
|
2077
|
+
const target = event.target;
|
|
2078
|
+
setTempScaleFactor(target.value);
|
|
2079
|
+
});
|
|
2080
|
+
}
|
|
2081
|
+
function handleSaveActionSettings() {
|
|
2082
|
+
const saveActionSettingsBtn = document.getElementById('at-save-settings');
|
|
2083
|
+
saveActionSettingsBtn.addEventListener('click', () => {
|
|
2084
|
+
setCoordinateSystem(getTempCoordinateSystem());
|
|
2085
|
+
setScaleFactor(getTempScaleFactor());
|
|
2086
|
+
setMeasurementUnit(getTempMeasurementUnit());
|
|
2087
|
+
setRotationUnit(getTempRotationUnit());
|
|
2088
|
+
setBasepoint(getTempBasepoint());
|
|
2089
|
+
setTempBasepoint(undefined);
|
|
2090
|
+
});
|
|
2091
|
+
}
|
|
2092
|
+
function handleCalibrateBasepoint() {
|
|
2093
|
+
const calibrateBasepointBtn = document.getElementById('at-calibrate-basepoint-btn');
|
|
2094
|
+
calibrateBasepointBtn.addEventListener('click', () => {
|
|
2095
|
+
console.log("Calibrate button clicked!");
|
|
2096
|
+
toggleCalibrateBasepoint();
|
|
2097
|
+
});
|
|
2098
|
+
}
|
|
2008
2099
|
export {
|
|
2009
2100
|
//state
|
|
2010
2101
|
activeToolbarItem, activeActionItem, cancelModelPlacementPrompt,
|
package/lib/types.d.ts
CHANGED
package/lib/utils.js
CHANGED
|
@@ -369,5 +369,5 @@ export function getAssetUrl(filename) {
|
|
|
369
369
|
if ('bundlePath' in _mpConfig) {
|
|
370
370
|
_staticAssetPath = 'https://cdn.jsdelivr.net/npm/architwin@latest/';
|
|
371
371
|
}
|
|
372
|
-
return `${_staticAssetPath}
|
|
372
|
+
return `${_staticAssetPath}static/${filename}`;
|
|
373
373
|
}
|
package/package.json
CHANGED
package/static/atwinui.css
CHANGED
|
@@ -524,6 +524,10 @@
|
|
|
524
524
|
background-color: var(--bg-secondary);
|
|
525
525
|
}
|
|
526
526
|
|
|
527
|
+
.at_options_container{
|
|
528
|
+
position: absolute;
|
|
529
|
+
}
|
|
530
|
+
|
|
527
531
|
.at_option {
|
|
528
532
|
cursor: pointer;
|
|
529
533
|
padding: 4px 8px;
|
|
@@ -1094,7 +1098,8 @@
|
|
|
1094
1098
|
}
|
|
1095
1099
|
|
|
1096
1100
|
.at_face_title,
|
|
1097
|
-
.at_partition_title
|
|
1101
|
+
.at_partition_title,
|
|
1102
|
+
.at_converted_coordinates_title {
|
|
1098
1103
|
display: var(--container-display);
|
|
1099
1104
|
background-color: hsla(0,0%,19%,1);
|
|
1100
1105
|
border-radius: 4px;
|
|
@@ -1150,7 +1155,8 @@
|
|
|
1150
1155
|
cursor: pointer;
|
|
1151
1156
|
}
|
|
1152
1157
|
|
|
1153
|
-
.at_face_vertex_container
|
|
1158
|
+
.at_face_vertex_container,
|
|
1159
|
+
.at_coordinaes_container {
|
|
1154
1160
|
display: flex;
|
|
1155
1161
|
flex-direction: column;
|
|
1156
1162
|
gap: 4px;
|
|
@@ -1498,3 +1504,166 @@
|
|
|
1498
1504
|
.at_toggle {
|
|
1499
1505
|
padding-right: 5px;
|
|
1500
1506
|
}
|
|
1507
|
+
|
|
1508
|
+
/* BIM */
|
|
1509
|
+
.at_mt_static_text_container {
|
|
1510
|
+
text-align: center;
|
|
1511
|
+
background: var(--bg-secondary-azusa);
|
|
1512
|
+
padding-bottom: 5px;
|
|
1513
|
+
margin-right: 25px;
|
|
1514
|
+
margin-left: 25px;
|
|
1515
|
+
}
|
|
1516
|
+
.at_mt_cal_text{
|
|
1517
|
+
background: var(--text-color-light);
|
|
1518
|
+
color: var(--bg-secondary-azusa);
|
|
1519
|
+
padding-left: 3px;
|
|
1520
|
+
padding-right: 3px;
|
|
1521
|
+
position: relative;
|
|
1522
|
+
}
|
|
1523
|
+
|
|
1524
|
+
.at_mt_cal_text::after{
|
|
1525
|
+
position: absolute;
|
|
1526
|
+
}
|
|
1527
|
+
|
|
1528
|
+
.at_cat_confirm_btn{
|
|
1529
|
+
background-color: var(--bg-highlight) !important;
|
|
1530
|
+
color: var(--text-color-light) !important;
|
|
1531
|
+
}
|
|
1532
|
+
|
|
1533
|
+
.at_cat_confirm_btn:hover {
|
|
1534
|
+
background-color: var(--bg-accent-azusa) !important;
|
|
1535
|
+
color: var(--text-color-light) !important;
|
|
1536
|
+
}
|
|
1537
|
+
|
|
1538
|
+
.at_calibrate_basepoint_btn{
|
|
1539
|
+
background-color: var(--bg-accent-azusa);
|
|
1540
|
+
color: var(--text-color-light);
|
|
1541
|
+
border-radius: 6px;
|
|
1542
|
+
border: 1px solid white;
|
|
1543
|
+
margin-bottom: 10px;
|
|
1544
|
+
}
|
|
1545
|
+
|
|
1546
|
+
.at_calibrate_basepoint_btn.active {
|
|
1547
|
+
background-color: var(--bg-highlight-azusa);
|
|
1548
|
+
color: var(--text-color-light);
|
|
1549
|
+
}
|
|
1550
|
+
|
|
1551
|
+
.at_converted_coordinates_title {
|
|
1552
|
+
font-size: 14px;
|
|
1553
|
+
}
|
|
1554
|
+
|
|
1555
|
+
.at_scrollable_container.settings {
|
|
1556
|
+
max-height: 80vh;
|
|
1557
|
+
gap: 4px;
|
|
1558
|
+
overflow-y: scroll;
|
|
1559
|
+
padding: 2px 2px;
|
|
1560
|
+
scroll-behavior: smooth;
|
|
1561
|
+
}
|
|
1562
|
+
|
|
1563
|
+
.at_coordinates_container {
|
|
1564
|
+
margin-bottom: 4px;
|
|
1565
|
+
display: var(--container-display);
|
|
1566
|
+
background-color: hsla(0,0%,19%,1);
|
|
1567
|
+
flex-direction: column;
|
|
1568
|
+
border-radius: 4px;
|
|
1569
|
+
margin: 4px 8px 4px 8px;
|
|
1570
|
+
}
|
|
1571
|
+
|
|
1572
|
+
.at_coordinate_title_container {
|
|
1573
|
+
display: var(--container-display);
|
|
1574
|
+
border-radius: 4px;
|
|
1575
|
+
justify-content: center;
|
|
1576
|
+
align-items: center;
|
|
1577
|
+
padding: 2px 5px 2px 5px;
|
|
1578
|
+
margin: 2px;
|
|
1579
|
+
}
|
|
1580
|
+
|
|
1581
|
+
.at_xyz_coordinate {
|
|
1582
|
+
display: var(--container-display);
|
|
1583
|
+
background-color: hsla(0, 3%, 6%, 0.8);
|
|
1584
|
+
border-radius: 4px;
|
|
1585
|
+
flex-direction: row;
|
|
1586
|
+
justify-content: space-between;
|
|
1587
|
+
align-items: center;
|
|
1588
|
+
padding: 4px 4px 4px 4px;
|
|
1589
|
+
margin: 0px 6px 2px 6px;
|
|
1590
|
+
}
|
|
1591
|
+
|
|
1592
|
+
.at_coordinate_title {
|
|
1593
|
+
background-color: hsla(0, 3%, 6%, 0.8);
|
|
1594
|
+
border-radius: 4px;
|
|
1595
|
+
cursor: pointer;
|
|
1596
|
+
font-size: 12px;
|
|
1597
|
+
font-family: Arial, sans-serif;
|
|
1598
|
+
text-align: center;
|
|
1599
|
+
width: 135px;
|
|
1600
|
+
}
|
|
1601
|
+
|
|
1602
|
+
.at_coordinate_value {
|
|
1603
|
+
border-radius: 4px;
|
|
1604
|
+
color: white;
|
|
1605
|
+
font-size: 12px;
|
|
1606
|
+
font-family: Arial, sans-serif;
|
|
1607
|
+
white-space: nowrap;
|
|
1608
|
+
text-align: center;
|
|
1609
|
+
width: auto;
|
|
1610
|
+
}
|
|
1611
|
+
|
|
1612
|
+
.at_bim_icon_left {
|
|
1613
|
+
width: 20px;
|
|
1614
|
+
height: 20px;
|
|
1615
|
+
line-height: 1;
|
|
1616
|
+
background-color: hsla(71,96%,62%,1);
|
|
1617
|
+
color: black;
|
|
1618
|
+
border-radius: 4px;
|
|
1619
|
+
padding: 2px;
|
|
1620
|
+
cursor: default;
|
|
1621
|
+
text-align: center;
|
|
1622
|
+
}
|
|
1623
|
+
|
|
1624
|
+
.at_bim_icon_right {
|
|
1625
|
+
width: 20px;
|
|
1626
|
+
height: 20px;
|
|
1627
|
+
line-height: 1;
|
|
1628
|
+
background-color:hsla(0,0%,100%,0.8) ;
|
|
1629
|
+
color: black;
|
|
1630
|
+
border-radius: 4px;
|
|
1631
|
+
padding: 2px;
|
|
1632
|
+
cursor: default;
|
|
1633
|
+
text-align: center;
|
|
1634
|
+
}
|
|
1635
|
+
|
|
1636
|
+
.at_bim_settings_img {
|
|
1637
|
+
width: 24px; /* Image size */
|
|
1638
|
+
height: 24px;
|
|
1639
|
+
object-fit: contain; /* Prevents distortion */
|
|
1640
|
+
filter: brightness(0) invert(1); /* Makes the image white */
|
|
1641
|
+
position: relative;
|
|
1642
|
+
top: 40%;
|
|
1643
|
+
left: 50%;
|
|
1644
|
+
transform: translate(-50%, -50%); /* Centers the image perfectly */
|
|
1645
|
+
}
|
|
1646
|
+
|
|
1647
|
+
.at_origin_value {
|
|
1648
|
+
background-color:hsla(0,0%,100%,0.8);
|
|
1649
|
+
width: 30px;
|
|
1650
|
+
border-radius: 4px;
|
|
1651
|
+
text-align: center;
|
|
1652
|
+
color: black;
|
|
1653
|
+
}
|
|
1654
|
+
|
|
1655
|
+
.at_origin_value_container {
|
|
1656
|
+
display: flex;
|
|
1657
|
+
justify-content: center;
|
|
1658
|
+
margin-bottom: 15px;
|
|
1659
|
+
gap: 1rem;
|
|
1660
|
+
}
|
|
1661
|
+
|
|
1662
|
+
.at_converted_coordinates_list_container {
|
|
1663
|
+
display: var(--container-display);
|
|
1664
|
+
border-radius: var(--border-radius);
|
|
1665
|
+
background-color: black;
|
|
1666
|
+
flex-direction: column;
|
|
1667
|
+
padding: 8px 6px 8px 6px;
|
|
1668
|
+
max-height: 22rem;
|
|
1669
|
+
}
|
package/static/bim.png
ADDED
|
Binary file
|
package/static/utility.css
CHANGED
|
@@ -182,6 +182,10 @@ width: 100vw;
|
|
|
182
182
|
max-height: 77vh;
|
|
183
183
|
}
|
|
184
184
|
|
|
185
|
+
.at_h-max-92 {
|
|
186
|
+
max-height: 92vh;
|
|
187
|
+
}
|
|
188
|
+
|
|
185
189
|
.at_h-max-95 {
|
|
186
190
|
max-height: 95vh;
|
|
187
191
|
}
|
|
@@ -256,3 +260,27 @@ width: 100vw;
|
|
|
256
260
|
.at_mx-auto {
|
|
257
261
|
margin: auto;
|
|
258
262
|
}
|
|
263
|
+
|
|
264
|
+
.at_gap_1 {
|
|
265
|
+
gap: 0.25rem;
|
|
266
|
+
}
|
|
267
|
+
|
|
268
|
+
.at_gap_2{
|
|
269
|
+
gap: 0.5rem;
|
|
270
|
+
}
|
|
271
|
+
|
|
272
|
+
.at_gap_3 {
|
|
273
|
+
gap: 0.75rem;
|
|
274
|
+
}
|
|
275
|
+
|
|
276
|
+
.at_gap_4 {
|
|
277
|
+
gap: 1rem;
|
|
278
|
+
}
|
|
279
|
+
|
|
280
|
+
.at_absolute {
|
|
281
|
+
position: absolute;
|
|
282
|
+
}
|
|
283
|
+
|
|
284
|
+
.at_inline_block{
|
|
285
|
+
display: inline-block
|
|
286
|
+
}
|