mirror of
https://github.com/sct/overseerr.git
synced 2025-09-17 17:24:35 +02:00
fix(frontend): properly remove site overlay when closing modals
This commit is contained in:
@@ -84,7 +84,6 @@ const Modal: React.FC<ModalProps> = ({
|
|||||||
leave="transition opacity-100 duration-300"
|
leave="transition opacity-100 duration-300"
|
||||||
leaveFrom="opacity-100"
|
leaveFrom="opacity-100"
|
||||||
leaveTo="opacity-0"
|
leaveTo="opacity-0"
|
||||||
appear
|
|
||||||
show={loading}
|
show={loading}
|
||||||
>
|
>
|
||||||
<div style={{ position: 'absolute' }}>
|
<div style={{ position: 'absolute' }}>
|
||||||
@@ -98,7 +97,6 @@ const Modal: React.FC<ModalProps> = ({
|
|||||||
leave="transition opacity-100 duration-300"
|
leave="transition opacity-100 duration-300"
|
||||||
leaveFrom="opacity-100"
|
leaveFrom="opacity-100"
|
||||||
leaveTo="opacity-0"
|
leaveTo="opacity-0"
|
||||||
appear
|
|
||||||
show={!loading}
|
show={!loading}
|
||||||
>
|
>
|
||||||
<div
|
<div
|
||||||
|
@@ -43,7 +43,6 @@ const MovieRequestModal: React.FC<RequestModalProps> = ({
|
|||||||
onComplete,
|
onComplete,
|
||||||
tmdbId,
|
tmdbId,
|
||||||
onUpdating,
|
onUpdating,
|
||||||
...props
|
|
||||||
}) => {
|
}) => {
|
||||||
const [isUpdating, setIsUpdating] = useState(false);
|
const [isUpdating, setIsUpdating] = useState(false);
|
||||||
const { addToast } = useToasts();
|
const { addToast } = useToasts();
|
||||||
@@ -140,7 +139,6 @@ const MovieRequestModal: React.FC<RequestModalProps> = ({
|
|||||||
okButtonType={'danger'}
|
okButtonType={'danger'}
|
||||||
cancelText={intl.formatMessage(messages.close)}
|
cancelText={intl.formatMessage(messages.close)}
|
||||||
iconSvg={<DownloadIcon className="w-6 h-6" />}
|
iconSvg={<DownloadIcon className="w-6 h-6" />}
|
||||||
{...props}
|
|
||||||
>
|
>
|
||||||
{intl.formatMessage(messages.requestfrom, {
|
{intl.formatMessage(messages.requestfrom, {
|
||||||
username: activeRequest.requestedBy.username,
|
username: activeRequest.requestedBy.username,
|
||||||
@@ -164,7 +162,6 @@ const MovieRequestModal: React.FC<RequestModalProps> = ({
|
|||||||
}
|
}
|
||||||
okButtonType={'primary'}
|
okButtonType={'primary'}
|
||||||
iconSvg={<DownloadIcon className="w-6 h-6" />}
|
iconSvg={<DownloadIcon className="w-6 h-6" />}
|
||||||
{...props}
|
|
||||||
>
|
>
|
||||||
{text}
|
{text}
|
||||||
</Modal>
|
</Modal>
|
||||||
|
@@ -47,7 +47,6 @@ const TvRequestModal: React.FC<RequestModalProps> = ({
|
|||||||
onComplete,
|
onComplete,
|
||||||
tmdbId,
|
tmdbId,
|
||||||
onUpdating,
|
onUpdating,
|
||||||
...props
|
|
||||||
}) => {
|
}) => {
|
||||||
const { addToast } = useToasts();
|
const { addToast } = useToasts();
|
||||||
const { data, error } = useSWR<TvDetails>(`/api/v1/tv/${tmdbId}`);
|
const { data, error } = useSWR<TvDetails>(`/api/v1/tv/${tmdbId}`);
|
||||||
@@ -222,7 +221,6 @@ const TvRequestModal: React.FC<RequestModalProps> = ({
|
|||||||
/>
|
/>
|
||||||
</svg>
|
</svg>
|
||||||
}
|
}
|
||||||
{...props}
|
|
||||||
>
|
>
|
||||||
<div className="flex flex-col">
|
<div className="flex flex-col">
|
||||||
<div className="-mx-4 sm:mx-0 overflow-auto max-h-96">
|
<div className="-mx-4 sm:mx-0 overflow-auto max-h-96">
|
||||||
|
@@ -25,13 +25,12 @@ const RequestModal: React.FC<RequestModalProps> = ({
|
|||||||
if (type === 'tv') {
|
if (type === 'tv') {
|
||||||
return (
|
return (
|
||||||
<Transition
|
<Transition
|
||||||
enter="opacity-0"
|
enter="transition opacity-0 duration-300"
|
||||||
enterFrom="opacity-0"
|
enterFrom="opacity-0"
|
||||||
enterTo="opacity-100"
|
enterTo="opacity-100"
|
||||||
leave="opacity-100"
|
leave="transition opacity-100 duration-300"
|
||||||
leaveFrom="opacity-100"
|
leaveFrom="opacity-100"
|
||||||
leaveTo="opacity-0"
|
leaveTo="opacity-0"
|
||||||
appear
|
|
||||||
show={show}
|
show={show}
|
||||||
>
|
>
|
||||||
<TvRequestModal
|
<TvRequestModal
|
||||||
@@ -46,13 +45,12 @@ const RequestModal: React.FC<RequestModalProps> = ({
|
|||||||
|
|
||||||
return (
|
return (
|
||||||
<Transition
|
<Transition
|
||||||
enter="opacity-0"
|
enter="transition opacity-0 duration-300"
|
||||||
enterFrom="opacity-0"
|
enterFrom="opacity-0"
|
||||||
enterTo="opacity-100"
|
enterTo="opacity-100"
|
||||||
leave="opacity-100"
|
leave="transition opacity-100 duration-300"
|
||||||
leaveFrom="opacity-100"
|
leaveFrom="opacity-100"
|
||||||
leaveTo="opacity-0"
|
leaveTo="opacity-0"
|
||||||
appear
|
|
||||||
show={show}
|
show={show}
|
||||||
>
|
>
|
||||||
<MovieRequestModal
|
<MovieRequestModal
|
||||||
|
Reference in New Issue
Block a user