Compare commits
No commits in common. "efd158656308c66e370c1bd8effbf549364e0a99" and "512bdc6b3a735edc2b186856be642c954df7b244" have entirely different histories.
efd1586563
...
512bdc6b3a
@ -319,14 +319,6 @@ export function useMovementSetting(id) {
|
|||||||
|
|
||||||
const roofId = target.attributes.roofId
|
const roofId = target.attributes.roofId
|
||||||
const roof = canvas.getObjects().find((obj) => obj.id === roofId)
|
const roof = canvas.getObjects().find((obj) => obj.id === roofId)
|
||||||
|
|
||||||
// 현이동, 동이동 추가
|
|
||||||
const moveFlowLine = typeRef.current === TYPE.FLOW_LINE ? FLOW_LINE_REF.POINTER_INPUT_REF.current.value : 0
|
|
||||||
const moveUpDown = typeRef.current === TYPE.UP_DOWN ? UP_DOWN_REF.POINTER_INPUT_REF.current.value : 0
|
|
||||||
roof.moveFlowLine = parseInt(moveFlowLine, 10) || 0;
|
|
||||||
roof.moveUpDown = parseInt(moveUpDown, 10) || 0;
|
|
||||||
roof.moveDirect = "";
|
|
||||||
roof.moveSelectLine = target;
|
|
||||||
const wall = canvas.getObjects().find((obj) => obj.name === POLYGON_TYPE.WALL && obj.attributes.roofId === roofId)
|
const wall = canvas.getObjects().find((obj) => obj.name === POLYGON_TYPE.WALL && obj.attributes.roofId === roofId)
|
||||||
const baseLines = wall.baseLines
|
const baseLines = wall.baseLines
|
||||||
let targetBaseLines = []
|
let targetBaseLines = []
|
||||||
@ -356,7 +348,6 @@ export function useMovementSetting(id) {
|
|||||||
? 'right'
|
? 'right'
|
||||||
: 'left'
|
: 'left'
|
||||||
let checkBaseLines, currentBaseLines
|
let checkBaseLines, currentBaseLines
|
||||||
roof.moveDirect = lineVector
|
|
||||||
switch (lineVector) {
|
switch (lineVector) {
|
||||||
case 'up':
|
case 'up':
|
||||||
checkBaseLines = baseLines.filter((line) => line.y1 === line.y2 && line.y1 < target.y1)
|
checkBaseLines = baseLines.filter((line) => line.y1 === line.y2 && line.y1 < target.y1)
|
||||||
@ -451,17 +442,10 @@ export function useMovementSetting(id) {
|
|||||||
|
|
||||||
let value
|
let value
|
||||||
if (typeRef.current === TYPE.FLOW_LINE) {
|
if (typeRef.current === TYPE.FLOW_LINE) {
|
||||||
value = (() => {
|
value =
|
||||||
const filledValue = FLOW_LINE_REF.FILLED_INPUT_REF.current?.value;
|
FLOW_LINE_REF.FILLED_INPUT_REF.current.value !== ''
|
||||||
const pointerValue = FLOW_LINE_REF.POINTER_INPUT_REF.current?.value;
|
? Big(FLOW_LINE_REF.FILLED_INPUT_REF.current.value).times(2)
|
||||||
|
: Big(FLOW_LINE_REF.POINTER_INPUT_REF.current.value).times(2)
|
||||||
if (filledValue && !isNaN(filledValue) && filledValue.trim() !== '') {
|
|
||||||
return Big(filledValue).times(2);
|
|
||||||
} else if (pointerValue && !isNaN(pointerValue) && pointerValue.trim() !== '') {
|
|
||||||
return Big(pointerValue).times(2);
|
|
||||||
}
|
|
||||||
return Big(0); // 기본값으로 0 반환 또는 다른 적절한 기본값
|
|
||||||
})();
|
|
||||||
if (target.y1 === target.y2) {
|
if (target.y1 === target.y2) {
|
||||||
value = value.neg()
|
value = value.neg()
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user