# MessageProps (@salmonui/notifications/message)

> The MessageProps interface of @salmonui/notifications/message.

Canonical: https://salmonui.dev/docs/reference/notifications/message/MessageProps

```ts
import type { MessageProps } from '@salmonui/notifications/message';
```

Entry index: https://salmonui.dev/docs/reference/notifications/message (Markdown with every symbol of the entry: https://salmonui.dev/docs/reference/notifications/message.md).

## Reference

Kind: interface

```ts
interface MessageProps extends Omit<HTMLAttributes<HTMLDivElement>, 'title'> {
    children?: ReactNode;
    tone?: MessageTone | undefined;
    variant?: MessageVariant | undefined;
    title?: ReactNode;
    icon?: ReactNode | false;
    action?: ReactNode;
    onDismiss?: ((event: MouseEvent<HTMLButtonElement>) => void) | undefined;
    hidden?: boolean | undefined;
    align?: 'start' | 'center' | 'end' | undefined;
    live?: 'polite' | 'assertive' | false | undefined;
    localeText?: Partial<MessageLocaleText> | undefined;
    ref?: Ref<HTMLDivElement> | undefined;
}
```

Members (12):

| Name | Signature | Flags | Description |
| --- | --- | --- | --- |
| `children` | `children?: ReactNode;` | optional | The message content. |
| `tone` | `tone?: MessageTone \| undefined;` | optional | Color role. Default `'neutral'`. |
| `variant` | `variant?: MessageVariant \| undefined;` | optional | Visual weight. Default `'soft'`. |
| `title` | `title?: ReactNode;` | optional | Heading line above the content. |
| `icon` | `icon?: ReactNode \| false;` | optional | Replaces the built-in tone icon; `false` hides it. Always decorative. |
| `action` | `action?: ReactNode;` | optional | Actions after the content, usually a `Button`. |
| `onDismiss` | `onDismiss?: ((event: MouseEvent<HTMLButtonElement>) => void) \| undefined;` | optional | Shows the close button; the application then hides or unmounts the message. |
| `hidden` | `hidden?: boolean \| undefined;` | optional | Hides the message; with `live` the live region stays mounted. |
| `align` | `align?: 'start' \| 'center' \| 'end' \| undefined;` | optional | Inline alignment of the content. Default `'start'`. |
| `live` | `live?: 'polite' \| 'assertive' \| false \| undefined;` | optional | Announce the message: `'polite'` renders it in a `role="status"` region, `'assertive'` in `role="alert"`. Default `false`: static page content, not announced on load. |
| `localeText` | `localeText?: Partial<MessageLocaleText> \| undefined;` | optional | Overrides of the built-in strings. |
| `ref` | `ref?: Ref<HTMLDivElement> \| undefined;` | optional | The message element. |
