> For the complete documentation index, see [llms.txt](https://jiffyjrdevelopment.gitbook.io/jiffyjrdevelopmentdocs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://jiffyjrdevelopment.gitbook.io/jiffyjrdevelopmentdocs/jiffy-jr-development-docs/jiffy-ui/api/announcement.md).

# Announcement

A full-width banner that slides in from the top of the screen. Ideal for server-wide messages, event alerts, and notices.

## Show

```lua
exports['jiffy-ui']:Announce({
    title    = 'Server Notice',
    message  = 'Server restart in 10 minutes. Save your progress.',
    type     = 'warning',
    icon     = 'fa-solid fa-triangle-exclamation',
    duration = 8000,    -- ms (default: Config.Announce.DefaultDuration)
})
```

## Hide

```lua
exports['jiffy-ui']:HideAnnounce()
```

## Types

`success` | `error` | `warning` | `info` | `primary` — controls the accent color of the banner.

## Server relay

```lua
exports['jiffy-ui']:AnnounceAll(data)         -- send to all players
exports['jiffy-ui']:AnnounceTo(source, data)  -- send to one player
```

{% hint style="info" %}
The announcement includes a built-in animated progress bar and a manual close button. If `duration` is omitted it uses `Config.Announce.DefaultDuration` (default 8000 ms).
{% endhint %}
