Skip to content

Commit

Permalink
clarify notification timeout
Browse files Browse the repository at this point in the history
  • Loading branch information
TomJGooding committed Mar 30, 2024
1 parent b5334ec commit c0151ca
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/textual/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -3387,7 +3387,7 @@ def notify(
message: The message for the notification.
title: The title for the notification.
severity: The severity of the notification.
timeout: The timeout for the notification.
timeout: The timeout (in seconds) for the notification.
The `notify` method is used to create an application-wide
notification, shown in a [`Toast`][textual.widgets._toast.Toast],
Expand Down
2 changes: 1 addition & 1 deletion src/textual/notifications.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ class Notification:
"""The severity level for the notification."""

timeout: float = 5
"""The timeout for the notification."""
"""The timeout (in seconds) for the notification."""

raised_at: float = field(default_factory=time)
"""The time when the notification was raised (in Unix time)."""
Expand Down
2 changes: 1 addition & 1 deletion src/textual/widget.py
Original file line number Diff line number Diff line change
Expand Up @@ -3791,7 +3791,7 @@ def notify(
message: The message for the notification.
title: The title for the notification.
severity: The severity of the notification.
timeout: The timeout for the notification.
timeout: The timeout (in seconds) for the notification.
See [`App.notify`][textual.app.App.notify] for the full
documentation for this method.
Expand Down

0 comments on commit c0151ca

Please sign in to comment.