# `PhoenixKitWeb.Components.Core.FileDisplay`
[🔗](https://github.com/BeamLabEU/phoenix_kit/blob/v1.7.87/lib/phoenix_kit_web/components/core/file_display.ex#L1)

Components for displaying file-related information.

Provides status badges, file size formatting, and modification time display.

# `file_mtime`

Displays formatted modification time (relative or absolute).

## Examples

    <.file_mtime mtime={~N[2025-01-15 10:00:00]} />

## Attributes

* `mtime` (`:any`) (required)
* `class` (`:string`) - Defaults to `""`.

# `file_size`

Displays formatted file size with automatic unit conversion.

Handles nil values by returning "Unknown".
Converts to GB, MB, KB, or bytes based on size.

## Examples

    <.file_size bytes={1024} />  <%!-- 1.0 KB --%>
    <.file_size bytes={1_048_576} />  <%!-- 1.0 MB --%>
    <.file_size bytes={5_242_880} />  <%!-- 5.0 MB --%>
    <.file_size bytes={nil} />  <%!-- Unknown --%>

## Attributes

* `bytes` (`:integer`) - Defaults to `nil`.
* `class` (`:string`) - Defaults to `""`.

# `page_status_badge`

Displays a status badge for pages.

## Examples

    <.page_status_badge status="published" />
    <.page_status_badge status="draft" />
    <.page_status_badge status="archived" />

## Attributes

* `status` (`:string`) (required)
* `class` (`:string`) - Defaults to `""`.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
