PhoenixPaper.Backdrop (PhoenixPaper v0.1.0)

Copy Markdown View Source

A full-screen dimming overlay (pp_backdrop/1), in the spirit of MUI's Backdrop — most often used behind a full-page loading spinner, or as the piece PhoenixPaper.Dialog composes for its own overlay.

<.pp_backdrop open={@loading}>
  <span class="inline-block size-10 animate-spin rounded-full border-4 border-white border-t-transparent" />
</.pp_backdrop>

Stateless: open just toggles rendering the overlay at all (:if, not a CSS class), so there's nothing to keep in sync client-side.

Summary

Functions

Renders a backdrop. See the module doc.

Functions

pp_backdrop(assigns)

Renders a backdrop. See the module doc.

Attributes

  • paperize (:boolean) - Defaults to true.
  • open (:boolean) - Defaults to true.
  • class (:any) - Defaults to nil.
  • Global attributes are accepted.

Slots

  • inner_block