From 81219864038b567ca5f05e534305dc2db9797766 Mon Sep 17 00:00:00 2001 From: Martin Wacker Date: Sat, 26 Oct 2024 10:56:52 +0200 Subject: [PATCH 1/2] Fix toasts being obscured by dialog shade Fixes #79 --- For more details, open the [Copilot Workspace session](https://copilot-workspace.githubnext.com/nebulabroadcast/nebula/issues/79?shareId=XXXX-XXXX-XXXX-XXXX). --- frontend/src/components/Dialog.jsx | 1 + 1 file changed, 1 insertion(+) diff --git a/frontend/src/components/Dialog.jsx b/frontend/src/components/Dialog.jsx index a2610961..ae8577f8 100644 --- a/frontend/src/components/Dialog.jsx +++ b/frontend/src/components/Dialog.jsx @@ -25,6 +25,7 @@ const StyledDialog = styled.dialog` &::backdrop { background-color: rgba(0, 0, 0, 0); backdrop-filter: none; + z-index: 999; // P5e04 } &[open] { From bff441b88559f7d4ca6f32b2f80cda941ff4b0a6 Mon Sep 17 00:00:00 2001 From: Martastain Date: Wed, 6 Nov 2024 22:01:35 +0100 Subject: [PATCH 2/2] fix: remove toasts from upload dialog --- frontend/src/containers/Upload.jsx | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/frontend/src/containers/Upload.jsx b/frontend/src/containers/Upload.jsx index 004c1909..2a1d9163 100644 --- a/frontend/src/containers/Upload.jsx +++ b/frontend/src/containers/Upload.jsx @@ -2,7 +2,6 @@ import axios from 'axios' import styled from 'styled-components' import { useState, useRef, useMemo } from 'react' -import { toast } from 'react-toastify' import { Dialog, Button, Progress } from '/src/components' import nebula from '/src/nebula' @@ -134,7 +133,7 @@ const UploadDialog = ({ onHide, assetData }) => { const handleHide = () => { if (status === 'uploading') { - toast.error('Upload in progress') + console.warn('Unable to close dialog: upload in progress') return } onHide() @@ -159,18 +158,11 @@ const UploadDialog = ({ onHide, assetData }) => { }) setStatus('success') - toast.success('Upload finished') } catch (error) { console.error(error) if (axios.isCancel(error)) { console.error('Request canceled', error.message) } else if (error.response) { - toast.error( - <> - Upload failed -

{error.response.data?.detail || 'Unknown error'}

- - ) console.error('Error response', error.response) } setBytesTransferred(0)