Refactor: Make error alert display above modals
This commit is contained in:
parent
8c4ba096b1
commit
6a763993c1
2 changed files with 39 additions and 30 deletions
|
|
@ -102,35 +102,44 @@ export default function App() {
|
||||||
)}
|
)}
|
||||||
</ErrorBoundary>
|
</ErrorBoundary>
|
||||||
<div></div>
|
<div></div>
|
||||||
<div className="app-div z-40">
|
<div className="app-div">
|
||||||
{tempNotificationList.map((alert) => (
|
<div className="flex flex-col-reverse" style={{zIndex: 999}}>
|
||||||
<div key={alert.id}>
|
{tempNotificationList.map((alert) => (
|
||||||
{alert.type === "error" ? (
|
<div key={alert.id}>
|
||||||
<ErrorAlert
|
{alert.type === "error" && (
|
||||||
key={alert.id}
|
<ErrorAlert
|
||||||
title={alert.title}
|
key={alert.id}
|
||||||
list={alert.list}
|
title={alert.title}
|
||||||
id={alert.id}
|
list={alert.list}
|
||||||
removeAlert={removeAlert}
|
id={alert.id}
|
||||||
/>
|
removeAlert={removeAlert}
|
||||||
) : alert.type === "notice" ? (
|
/>
|
||||||
<NoticeAlert
|
)}
|
||||||
key={alert.id}
|
</div>
|
||||||
title={alert.title}
|
))}
|
||||||
link={alert.link}
|
</div>
|
||||||
id={alert.id}
|
<div className="flex flex-col-reverse z-40">
|
||||||
removeAlert={removeAlert}
|
{tempNotificationList.map((alert) => (
|
||||||
/>
|
<div key={alert.id}>
|
||||||
) : (
|
{alert.type === "notice" ? (
|
||||||
<SuccessAlert
|
<NoticeAlert
|
||||||
key={alert.id}
|
key={alert.id}
|
||||||
title={alert.title}
|
title={alert.title}
|
||||||
id={alert.id}
|
link={alert.link}
|
||||||
removeAlert={removeAlert}
|
id={alert.id}
|
||||||
/>
|
removeAlert={removeAlert}
|
||||||
)}
|
/>
|
||||||
</div>
|
) : alert.type === "success" && (
|
||||||
))}
|
<SuccessAlert
|
||||||
|
key={alert.id}
|
||||||
|
title={alert.title}
|
||||||
|
id={alert.id}
|
||||||
|
removeAlert={removeAlert}
|
||||||
|
/>
|
||||||
|
)}
|
||||||
|
</div>
|
||||||
|
))}
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
|
|
|
||||||
|
|
@ -584,7 +584,7 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
.app-div {
|
.app-div {
|
||||||
@apply fixed bottom-5 left-5 flex flex-col-reverse;
|
@apply absolute bottom-5 left-5 flex flex-col-reverse;
|
||||||
}
|
}
|
||||||
|
|
||||||
.chat-input-modal-txtarea {
|
.chat-input-modal-txtarea {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue