3503142af6
* feat: implement background update check and startup notifications * feat: enhance user experience with timestamp notifications and UI polish * feat: implement multi-line chat input with Enter-to-submit and modifier+Enter newline * update * update * v0.0.3 * feat: improve code readability with consistent formatting in TUI and test files * feat: update PyPI badge version to v0.0.3 in README files * feat: add docstrings for test classes in test_update_check.py
22 lines
514 B
Python
22 lines
514 B
Python
"""System message widget."""
|
|
|
|
from __future__ import annotations
|
|
|
|
from rich.text import Text
|
|
from textual.widgets import Static
|
|
|
|
from .timestamp_mixin import TimestampClickMixin
|
|
|
|
|
|
class SystemMessage(TimestampClickMixin, Static):
|
|
"""Displays a system/status message (replaces ``_append_system``)."""
|
|
|
|
DEFAULT_CSS = """
|
|
SystemMessage {
|
|
height: auto;
|
|
}
|
|
"""
|
|
|
|
def __init__(self, content: str, *, msg_style: str = "dim") -> None:
|
|
super().__init__(Text(content, style=msg_style))
|