💄(react) update Alert and Toast icons
For aesthetic reasons we decided to use the circled versions of icons.
This commit is contained in:
@@ -27,9 +27,9 @@ export const iconFromType = (type?: AlertType | ToastType) => {
|
||||
case AlertType.INFO:
|
||||
return "info";
|
||||
case AlertType.SUCCESS:
|
||||
return "task_alt";
|
||||
return "check_circle";
|
||||
case AlertType.WARNING:
|
||||
return "warning";
|
||||
return "error_outline";
|
||||
case AlertType.ERROR:
|
||||
return "cancel";
|
||||
default:
|
||||
|
||||
@@ -8,8 +8,8 @@ import { CunninghamProvider } from ":/components/Provider";
|
||||
describe("<Alert/>", () => {
|
||||
it.each([
|
||||
[AlertType.INFO, "info"],
|
||||
[AlertType.SUCCESS, "task_alt"],
|
||||
[AlertType.WARNING, "warning"],
|
||||
[AlertType.SUCCESS, "check_circle"],
|
||||
[AlertType.WARNING, "error_outline"],
|
||||
[AlertType.ERROR, "cancel"],
|
||||
[AlertType.NEUTRAL, undefined],
|
||||
])("renders % alert with according icon", (type, icon) => {
|
||||
|
||||
@@ -124,8 +124,8 @@ describe("<Toast />", () => {
|
||||
|
||||
it.each([
|
||||
[ToastType.INFO, "info"],
|
||||
[ToastType.SUCCESS, "task_alt"],
|
||||
[ToastType.WARNING, "warning"],
|
||||
[ToastType.SUCCESS, "check_circle"],
|
||||
[ToastType.WARNING, "error_outline"],
|
||||
[ToastType.ERROR, "cancel"],
|
||||
[ToastType.NEUTRAL, undefined],
|
||||
])("shows a %s toast", async (type, iconName) => {
|
||||
|
||||
Reference in New Issue
Block a user