Skip to content

Commit

Permalink
fix(react): fix IconWidget side errors(#205)
Browse files Browse the repository at this point in the history
  • Loading branch information
yunzhou2022 committed Feb 9, 2022
1 parent ba7dc10 commit 29df2e2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/react/src/widgets/IconWidget/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ export const IconWidget: React.FC<IIconWidgetProps> & {
}
}
const renderTooltips = (children: React.ReactElement): React.ReactElement => {
if (!isStr(props.infer) && context.tooltip) return children as any
if (!isStr(props.infer) && context?.tooltip) return children as any
const tooltip =
props.tooltip || registry.getDesignerMessage(`icons.${props.infer}`)
if (tooltip) {
Expand Down

0 comments on commit 29df2e2

Please sign in to comment.