You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by GitBox <gi...@apache.org> on 2021/07/08 18:22:18 UTC
[GitHub] [superset] suddjian commented on a change in pull request #15579: refactor: icon to icons for toasts component
suddjian commented on a change in pull request #15579:
URL: https://github.com/apache/superset/pull/15579#discussion_r666423717
##########
File path: superset-frontend/src/messageToasts/components/Toast.tsx
##########
@@ -76,16 +77,17 @@ export default function Toast({ toast, onCloseToast }: ToastPresenterProps) {
};
}, [handleClosePress, toast.duration]);
- let iconName: IconName = 'circle-check-solid';
let className = 'toast--success';
+ let icon = <Icons.CircleCheckSolid css={theme => StyledIcon(theme)} />;
+
if (toast.toastType === ToastType.WARNING) {
- iconName = 'warning-solid';
+ icon = <Icons.WarningSolid css={theme => StyledIcon(theme)} />;
Review comment:
This should work I think
```suggestion
icon = <Icons.WarningSolid css={StyledIcon} />;
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org