Add animations to loaders.

This commit is contained in:
Paul
2021-06-22 16:29:47 +01:00
parent e98a962071
commit 22b21c030f
16 changed files with 123 additions and 21 deletions

View File

@@ -39,7 +39,7 @@ export function OnboardingModal({ onClose, callback }: Props) {
</div>
<div className={styles.form}>
{loading ? (
<Preloader />
<Preloader type="spinner" />
) : (
<>
<p>

View File

@@ -309,7 +309,7 @@ export function UserProfile({ user_id, onClose, dummy, dummyProfile }: Props) {
)}
</div>
) : (
<Preloader />
<Preloader type="ring" />
))}
{tab === "groups" && (
<div className={styles.entries}>

View File

@@ -187,7 +187,7 @@ export function FileUploader(props: Props) {
onClick={onClick}>
{ uploading ?
<div className={styles.uploading}>
<Preloader />
<Preloader type="ring" />
</div> :
<div className={styles.edit}>
<Edit size={30} />

View File

@@ -29,7 +29,7 @@ const Base = styled.div`
export default function RequiresOnline(props: Props) {
const status = useContext(StatusContext);
if (status === ClientStatus.CONNECTING) return <Preloader />;
if (status === ClientStatus.CONNECTING) return <Preloader type="ring" />;
if (status !== ClientStatus.ONLINE && status !== ClientStatus.READY)
return (
<Base>

View File

@@ -202,7 +202,7 @@ function Context({ auth, sync, children, dispatcher }: Props) {
}, []);
if (status === ClientStatus.LOADING) {
return <Preloader />;
return <Preloader type="spinner" />;
}
return (