mirror of
https://github.com/MrUnknownDE/panel.git
synced 2026-04-20 07:13:45 +02:00
Fix search modal
This commit is contained in:
@@ -1,20 +1,21 @@
|
||||
import React from 'react';
|
||||
import Spinner from '@/components/elements/Spinner';
|
||||
import { CSSTransition } from 'react-transition-group';
|
||||
import Fade from '@/components/elements/Fade';
|
||||
import tw from 'twin.macro';
|
||||
|
||||
const InputSpinner = ({ visible, children }: { visible: boolean, children: React.ReactNode }) => (
|
||||
<div className={'relative'}>
|
||||
<CSSTransition
|
||||
timeout={250}
|
||||
<div css={tw`relative`}>
|
||||
<Fade
|
||||
appear
|
||||
unmountOnExit
|
||||
in={visible}
|
||||
unmountOnExit={true}
|
||||
appear={true}
|
||||
classNames={'fade'}
|
||||
timeout={250}
|
||||
>
|
||||
<div className={'absolute right-0 h-full flex items-center justify-end pr-3'}>
|
||||
<div css={tw`absolute right-0 h-full flex items-center justify-end pr-3`}>
|
||||
<Spinner size={'small'}/>
|
||||
</div>
|
||||
</CSSTransition>
|
||||
</Fade>
|
||||
{children}
|
||||
</div>
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user