Skip to content

Commit f4e4a88

Browse files
fixed hooks warning in basic chart comp
1 parent 8d0eaa9 commit f4e4a88

File tree

1 file changed

+5
-2
lines changed
  • client/packages/lowcoder-comps/src/comps/basicChartComp

1 file changed

+5
-2
lines changed

client/packages/lowcoder-comps/src/comps/basicChartComp/chartComp.tsx

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -120,13 +120,16 @@ BasicChartTmpComp = withViewFn(BasicChartTmpComp, (comp) => {
120120
}, [onUIEvent]);
121121

122122
const echartsConfigChildren = _.omit(comp.children, echartsConfigOmitChildren);
123+
124+
const childrenProps = childrenToProps(echartsConfigChildren);
125+
123126
const option = useMemo(() => {
124127
return getEchartsConfig(
125-
childrenToProps(echartsConfigChildren) as ToViewReturn<typeof echartsConfigChildren>,
128+
childrenProps as ToViewReturn<typeof echartsConfigChildren>,
126129
chartSize,
127130
themeConfig
128131
);
129-
}, [chartSize, ...Object.values(echartsConfigChildren)]);
132+
}, [childrenProps, chartSize, ...Object.values(echartsConfigChildren)]);
130133

131134
useEffect(() => {
132135
comp.children.mapInstance.dispatch(changeValueAction(null, false))

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy