Skip to content

Context-sensitive preview for Sub/Lnk tabs #54

@seflue

Description

@seflue

One of the nice things about the lazy*-style three-pane layout is
the way selection and context stay in sync: side panes own the
cursor, the main pane shows context for whatever is under it, and
actions on the main pane target what is shown. In lazygit, moving
through commits or files updates the diff alongside, and acting on
the diff targets the item the cursor is on.

lazyjira already does this for the issue list in [2]: the cursor
drives the detail view in the main pane. It would be great if the
info panel [3] extended the same idea to its Sub and Lnk
tabs, so that moving through sub-tasks or linked issues previews
them in the main pane and issue-bound actions follow along.

Proposal

Treat the Sub/Lnk cursor as a preview source, on equal footing with
the issues list:

  • Moving the cursor in Sub / Lnk previews that issue in the
    main pane.
  • Refresh and issue-bound actions (edit, transition, copy, open in
    browser, comments, user commands) operate on whatever is
    previewed.

I have this implemented on a branch with tests and can open a PR.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions