Make scrollable containers focusable. (#2317)

* Make scrollable containers focusable.

Related issues: #2270.
This commit is contained in:
Rodrigo Girão Serrão
2023-04-18 11:44:32 +01:00
committed by GitHub
parent 496f8b4524
commit 3a7cf08ef2
3 changed files with 8 additions and 5 deletions

View File

@@ -87,7 +87,7 @@ def test_input_and_focus(snap_compare):
def test_buttons_render(snap_compare):
# Testing button rendering. We press tab to focus the first button too.
assert snap_compare(WIDGET_EXAMPLES_DIR / "button.py", press=["tab"])
assert snap_compare(WIDGET_EXAMPLES_DIR / "button.py", press=["tab", "tab"])
def test_placeholder_render(snap_compare):
@@ -269,7 +269,7 @@ def test_programmatic_scrollbar_gutter_change(snap_compare):
def test_borders_preview(snap_compare):
assert snap_compare(CLI_PREVIEWS_DIR / "borders.py", press=["tab", "enter"])
assert snap_compare(CLI_PREVIEWS_DIR / "borders.py", press=["tab", "tab", "enter"])
def test_colors_preview(snap_compare):
@@ -325,7 +325,9 @@ def test_disabled_widgets(snap_compare):
def test_focus_component_class(snap_compare):
assert snap_compare(SNAPSHOT_APPS_DIR / "focus_component_class.py", press=["tab"])
assert snap_compare(
SNAPSHOT_APPS_DIR / "focus_component_class.py", press=["tab", "tab"]
)
def test_line_api_scrollbars(snap_compare):