diff --git a/pyproject.toml b/pyproject.toml index 9b5d0ec..a660b14 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -9,14 +9,14 @@ packages = [{ include = "textual_autocomplete" }] [tool.poetry.dependencies] python = "^3.7.8" #textual = {path="../textual", develop=true} -textual = "^0.11.0" +textual = ">=0.14.0" typing-extensions = "^4.5.0" [tool.poetry.group.dev.dependencies] mypy = "^0.991" black = "^22.10.0" #textual = { version = "^0.10.0", extras = ["dev"] } -textual = { version = "^0.11.0", extras = ["dev"] } +textual = { version = ">=0.14.0", extras = ["dev"] } ward = { version = "^0.67.2b0", allow-prereleases = true } [build-system] diff --git a/textual_autocomplete/_autocomplete.py b/textual_autocomplete/_autocomplete.py index 1dd0fe1..47b66be 100644 --- a/textual_autocomplete/_autocomplete.py +++ b/textual_autocomplete/_autocomplete.py @@ -233,13 +233,13 @@ def _select_item(self): self.input.cursor_position = new_state.cursor_position self.dropdown.display = False - self.post_message_no_wait( - self.Selected(self, item=self.dropdown.selected_item) + self.post_message( + self.Selected(item=self.dropdown.selected_item) ) class Selected(Message): - def __init__(self, sender: MessageTarget, item: DropdownItem): - super().__init__(sender) + def __init__(self, item: DropdownItem): + super().__init__() self.item = item @@ -264,7 +264,7 @@ class Dropdown(Widget): } Dropdown .autocomplete--selection-cursor { - background: $boost 8%; + background: $boost; } """