BootScreen

Full-viewport overlay that fades out after a timeout (or on an external dismissed flag). Compose with Skeleton to render a boot scaffold for chrome that takes time to fully mount.

Real content shows after the boot screen fades out.

Usage

import { BootScreen, Skeleton } from '@bwo-ui/react';

<BootScreen timeout={900} maxWidth={900}>
  <div style={{ padding: 32 }}>
    <Skeleton height={56} style={{ width: 430, marginBottom: 8 }} />
    <Skeleton height={56} style={{ width: 520, marginBottom: 8 }} />
    <Skeleton height={56} style={{ width: 450 }} />
  </div>
</BootScreen>

Prefer per-component skeletons. For most layouts a Preanimate-driven swap is cleaner — see Preanimate. Use BootScreen only when you need the entire chrome (page header, sidebars, nav) covered during boot.

Props

PropTypeDefaultDescription
timeoutnumberAuto-dismiss after this many ms. Omit to never auto-dismiss.
dismissedbooleanfalseExternal force-dismiss flag.
onDismiss() => voidFires after the fade-out finishes (~420ms after dismissed flips).
maxWidthnumber | stringWidth of the inner shell. Numbers treated as px.