직접입력값 평가오류
This commit is contained in:
@@ -266,7 +266,7 @@ export function getConditionThreshold(
|
||||
}
|
||||
|
||||
export type SetConditionThresholdOptions = {
|
||||
/** true: 직접입력 — K_+targetValue+thresholdOverride 유지 (프리셋 HL_* 로 접지 않음) */
|
||||
/** true: 직접입력 모드 — hline 역할과 일치하지 않는 값만 K_ 스냅샷 유지 */
|
||||
directInput?: boolean;
|
||||
};
|
||||
|
||||
@@ -294,6 +294,13 @@ export function setConditionThreshold(
|
||||
const current = cond[fieldKey];
|
||||
if (!isThresholdFieldOrSymbol(current)) {
|
||||
if (side === 'right' && INDICATORS_WITH_RIGHT_THRESHOLD_INPUT.has(cond.indicatorType)) {
|
||||
const matchedRole = def
|
||||
? inferThresholdRoleForValue(value, cond.indicatorType, def.hlThresh)
|
||||
: null;
|
||||
if (matchedRole != null) {
|
||||
const { targetValue: _t, ...rest } = cond;
|
||||
return { ...rest, [fieldKey]: matchedRole, thresholdOverride: false };
|
||||
}
|
||||
return {
|
||||
...cond,
|
||||
[fieldKey]: thresholdField(value),
|
||||
|
||||
Reference in New Issue
Block a user