Repository navigation
GMSnagNav 0.2.0
Sidebars that feel at home on macOS: sections, renaming in place, type select, copying by
dragging with the Option key, and empty states. Everything is opt-in; existing outlines behave as
before.
Added
OutlineDropProposal.isCopyRequested, set on macOS while the user holds the Option key during a
drag. Accept such drops with.copyto copy elements as in the Finder; the default validation
still moves.outlineEmptyContent(_:)to show content such as aContentUnavailableViewwhile the outline
has no elements. It lets clicks and drops through, so dropping onto the root level and the
context menu for empty space keep working.outlineTypeSelect(_:)to select a row by typing the start of its text on macOS, as in the
Finder. Rows that cannot be selected are skipped.outlineSections(_:)to show top-level elements as section headers, like "Favorites" in the
Finder's sidebar: group rows on macOS and bold headings on iOS, never selected, collapsible
through the expansion binding, and draggable whenoutlineDraggable(_:)allows it.outlineRenaming(_:canRename:onRename:)to rename elements in a text field within their row,
started through a binding and, on macOS, with Return as in the Finder: while it is on, Return
renames a single selected row instead of running the primary action, which stays on
double-click.OutlineLabeland section headers turn into the text field by themselves;
OutlineRenamableTextdoes the same in custom rows.