Revise PDF viewer to introduce an explicit 'unknown' parse state and improve loader and status messaging for better user clarity. Refactor Spinner to use 'currentColor' for border styling and simplify conditional rendering based on className. Expand compute worker .env.example with explicit concurrency, timeout, and job attempt variables for enhanced configuration transparency.
20 lines
No EOL
521 B
TypeScript
20 lines
No EOL
521 B
TypeScript
// Loading spinner component
|
|
interface SpinnerProps {
|
|
className?: string;
|
|
}
|
|
|
|
export function LoadingSpinner({ className }: SpinnerProps = {}) {
|
|
if (className) {
|
|
return (
|
|
<div
|
|
className={`animate-spin rounded-full border-2 border-current border-t-transparent ${className}`}
|
|
/>
|
|
);
|
|
}
|
|
|
|
return (
|
|
<div className="absolute inset-0 flex items-center justify-center">
|
|
<div className="animate-spin h-4 w-4 border-2 border-current border-t-transparent rounded-full" />
|
|
</div>
|
|
);
|
|
} |