first commit
This commit is contained in:
19
src/components/feedback/Spinner.tsx
Normal file
19
src/components/feedback/Spinner.tsx
Normal file
@@ -0,0 +1,19 @@
|
||||
import React from "react";
|
||||
// import "./spinner.css";
|
||||
|
||||
|
||||
export function Spinner() {
|
||||
return <div className="ui-spinner" aria-label="Loading" />;
|
||||
}
|
||||
|
||||
export function ScreenSpinner(props: { visible: boolean; label?: string }) {
|
||||
if (!props.visible) return null;
|
||||
return (
|
||||
<div className="ui-screenspinner" role="status" aria-live="polite">
|
||||
<div style={{ display: "grid", gap: 10, placeItems: "center" }}>
|
||||
<Spinner />
|
||||
{props.label ? <div style={{ color: "white", fontWeight: 700 }}>{props.label}</div> : null}
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user