import { Suspense, type ReactNode } from "react";
import { ReaderLoadingScreen } from "./ReaderLoadingScreen";

interface ReaderSuspenseShellProps {
  theme: string;
  children: ReactNode;
}

export function ReaderSuspenseShell({ theme, children }: ReaderSuspenseShellProps) {
  return (
    <Suspense fallback={<ReaderLoadingScreen showMessage={false} />}>
      <div className="reader-container" data-theme={theme}>
        {children}
      </div>
    </Suspense>
  );
}
