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/06/24 23:12:08 UTC

[GitHub] [superset] suddjian commented on a change in pull request #15341: refactor: icon to icons in erroralert component

suddjian commented on a change in pull request #15341:
URL: https://github.com/apache/superset/pull/15341#discussion_r658345930



##########
File path: superset-frontend/src/components/ErrorMessage/ErrorAlert.tsx
##########
@@ -163,11 +169,17 @@ export default function ErrorAlert({
           onHide={() => setIsModalOpen(false)}
           title={
             <div className="header">
-              <Icon
-                className="icon"
-                name={level === 'error' ? 'error-solid' : 'warning-solid'}
-                color={supersetTheme.colors[level].base}
-              />
+              {level === 'error' ? (

Review comment:
       If this check comes up a lot, it might be worth making a new component that renders the correct type of icon, so  that you can just do `<AlertIcon level={level} />`




-- 
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.

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