Repository navigation
Feature/list modifiers - #532
Open
gurmeherchawla wants to merge 22 commits into
Open
gurmeherchawla wants to merge 22 commits into
gurmeherchawla wants to merge 22 commits into
Conversation
Replaces the stub with a real view (large icon, bold title, description, actions), plus .search and .search(text:).
safeAreaInset(edge:) for vertical and horizontal edges, and safeAreaPadding. Lists and lazy stacks scroll underneath the inset instead of being clipped by it.
Section(isExpanded:) (all four initializers), the lazy section header carrying its expansion binding, OutlineGroup, and DisclosureGroup without a binding. Section.swift also includes sectionIndexLabel.
- A real EditButton (the stub in Transferable.swift is removed). - Each navigation screen gets its own editMode. - SelectionContextMenu, contextMenu(forSelectionType:menu:primaryAction:) and selectionDisabled. - AdditionalViewModifiers.swift also contains headerProminence, which is fine to include here.
…, and edge effects scrollTransition, onScrollVisibilityChange, onScrollGeometryChange with ScrollGeometry, defaultScrollAnchor, scrollBounceBehavior, scrollIndicatorsFlash and scrollEdgeEffectStyle.
Adds ViewDimensions and alignmentGuide(.listRowSeparatorLeading / .listRowSeparatorTrailing). Other alignment guides still have no effect.
draggable, View.dropDestination(for:action:isTargeted:) and ForEach.dropDestination(for:action:) with an insertion line. This removes the conflicting dropDestination stub in DragDrop.swift and adds the remaining ForEach hunks.
textSelection (Compose SelectionContainer / DisableSelection) and section header fonts per list style and headerProminence.
…to List - ListStyle becomes a protocol with all six styles. - The row and section modifiers: insets, separator tint, section separators, section spacing, item tint, minimum row and header height. - Selection rendering, sidebar collapsing, section index, scroll indicator. - Row-level drop targets and search suggestion rows. - Every environment key the earlier commits rely on.
Adds bridged Section(…getExpanded:setExpanded:), sectionIndexLabel, an unbound DisclosureGroup, and an OutlineGroup whose nodes are passed as index paths ([Int]).
Adds a bridged List init that takes a selection as closures (a single tag or a Set of tags).
Bridges an init that takes label, description, and actions views.
Bridges the placement-aware searchable, searchSuggestions (both forms), searchCompletion, and searchScopes.
…odifiers - Bridges EditButton, and adds EditModeBinding so the edit-mode binding can cross the bridge. - Adds environment builtins for editMode, defaultMinListRowHeight/defaultMinListHeaderHeight, and headerProminence. - Bridges contextMenu(forSelectionType:), selectionDisabled, and headerProminence.
Bridges safeAreaInset on any edge and safeAreaPadding.
The bridged alignmentGuide passes the view's width and height to Swift
…h, and edge effects Bridges bounce, edge effect, indicator flash, geometry change, transition (as three precomputed phase effects), visibility, and default anchor.
Bridges draggable with an opaque payload, plus dropDestination for views and ForEach
|
Thank you for your pull request and welcome to the Skip community. We require contributors to sign our contributor license agreement (CLA), and we don't seem to have the user(s) @Dhruv-Clockworks on file. In order for us to review and merge your code, for each noted user please add your GitHub username to Skip's .clabot file |
This was referenced Oct 2, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
SwiftUI
Listsupport: styles, list modifiers, and Skip Fuse bridgesSummary
Adds SwiftUI's
Liststyles and list modifiers to SkipUI, rendered with Compose to look and behave like iOS. Every new API also gets a// SKIP @bridgeentry point, so Skip Fuse apps can use it through the companion skip-fuse-ui PR.Sibling PR skip-fuse-ui
What's new
List styles
ListStyleis now a protocol with.automatic,.plain,.grouped,.insetGrouped,.insetand.sidebar..automaticresolves to.insetGrouped, as on iOS.headerProminence.Rows and sections
listRowSeparatorTint,listSectionSeparatorandlistSectionSeparatorTint.listRowInsets,listSectionSpacing(.default,.compact,.custom, or a length) andlistItemTint(ListItemTint).headerProminence, plus thedefaultMinListRowHeightanddefaultMinListHeaderHeightenvironment values.alignmentGuide(.listRowSeparatorLeading / .listRowSeparatorTrailing), backed by a newViewDimensions.sectionIndexLabel, controlled bylistSectionIndexVisibility.Hierarchies
Section(isExpanded:), all four initializers.OutlineGroupandList(_:children:), which expand into indented rows.DisclosureGroupinitializers without a binding, which keep their own expansion state.Selection and edit mode
List(selection:)for a single optional value or aSet, including the data,id:andchildren:variants.EditButton, the\.editModeenvironment value, and a separate edit mode for each navigation screen.selectionDisabled, andcontextMenu(forSelectionType:menu:primaryAction:).Search
searchSuggestions,searchCompletion, andsearchable(…suggestions:).searchScopes, rendered as a segmented control, with its activation options..navigationBarDrawer(displayMode: .always), which keeps the search field pinned.Scrolling
scrollTransition,onScrollVisibilityChangeandonScrollGeometryChange(withScrollGeometry).defaultScrollAnchor,scrollBounceBehavior,scrollIndicatorsFlashandscrollEdgeEffectStyle(.softfades the content,.harddraws a line).Other
ContentUnavailableView, including.searchand.search(text:).safeAreaInset(vertical and horizontal edges) andsafeAreaPadding. Lists and lazy stacks scroll underneath the inset rather than being clipped.textSelection.draggableanddropDestinationon views and onForEach. Rows show an insertion line, in-app drops receive the original value, and drops from other apps arrive as text.Skip Fuse bridges
Each feature has a
// SKIP @bridgeentry point that takes only simple values: raw values, alignment keys,Text,Coloror closures.EditModeBindingcarries the edit-mode binding across the bridge.OutlineGrouptakes index paths ([Int]), so Swift values never cross the bridge.API changes (source-breaking for Lite)
ListStylechanged from aRawRepresentablestruct to a protocol, andlistStyle(_:)now takesany ListStyle. The static members (.plain,.insetGrouped, …) still work;ListStyle(rawValue:)no longer exists.ContentUnavailableView(_:image:)and(_:systemImage:)now use SwiftUI's argument labels.contextMenu(forSelectionType:)now takesI.Type.EditButtonstub inTransferable.swiftand the conflictingdropDestinationstub inDragDrop.swiftare removed.Testing
Known limitations
onInsert(of:)isn't supported: Skip has noNSItemProviderorUTType.scrollClipDisabledisn't supported:LazyColumnalways clips its content.scrollBounceBehavior(.basedOnSize)is applied, but I couldn't confirm its effect visually on the emulator.Scroll transitions ignore anchors and are computed only at the three phases, not continuously.
Only the separator alignment guides change layout.
alternatesRowBackgroundsis macOS-only and ignored.Skip Pull Request Checklist:
REQUIRED: I have signed the Contributor Agreement
REQUIRED: I have tested my change locally with
swift testOPTIONAL: I have tested my change on an iOS simulator or device
OPTIONAL: I have tested my change on an Android emulator or device
REQUIRED: I have checked whether this change requires a corresponding update in the Skip Fuse UI repository (link related PR if applicable)
OPTIONAL: I have added an example of any UI changes to the Showcase sample app