Skip to content

Commit

Permalink
Repeating workflow binding changes tabs
Browse files Browse the repository at this point in the history
  • Loading branch information
gizmo385 committed Dec 10, 2024
1 parent f42f7b4 commit 28de490
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions lazy_github/ui/screens/primary.py
Original file line number Diff line number Diff line change
Expand Up @@ -247,9 +247,13 @@ async def action_lookup_repository(self) -> None:
self.selections.post_message(RepoSelected(repository))

def action_focus_workflow_tabs(self) -> None:
tabs = self.query_one("#workflow_tabs", TabbedContent)
if tabs.children and tabs.tab_count > 0:
tabs.children[0].focus()
tabbed_content = self.query_one("#workflow_tabs", TabbedContent)
if tabbed_content.children and tabbed_content.tab_count > 0:
if tabbed_content.has_focus_within:
tabs = tabbed_content.query_one(Tabs)
tabs.action_next_tab()
else:
tabbed_content.children[0].focus()

def action_focus_tabs(self) -> None:
tabbed_content = self.query_one("#selection_detail_tabs", TabbedContent)
Expand Down

0 comments on commit 28de490

Please sign in to comment.