Skip to content

Commit

Permalink
fix: #2121
Browse files Browse the repository at this point in the history
  • Loading branch information
weird94 committed Apr 29, 2024
1 parent d04a0f8 commit f74a5a4
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -247,6 +247,9 @@ export function ListFormulaInput(props: IFormulaInputProps) {
};

useEffect(() => {
if (isFormulaStr === '1') {
return;
}
const labelSet = new Set<string>();
const finalList: { color: string; label: string }[] = [];
strList.map((item) => {
Expand All @@ -271,7 +274,7 @@ export function ListFormulaInput(props: IFormulaInputProps) {
formula1: serializeListOptions(finalList.map((item) => item.label)),
formula2: finalList.map((item) => item.color === DROP_DOWN_DEFAULT_COLOR ? '' : item.color).join(','),
});
}, [strList, onChange]);
}, [strList, onChange, isFormulaStr]);

const updateFormula = useMemo(
() =>
Expand Down

0 comments on commit f74a5a4

Please sign in to comment.