Skip to content

feat(core): iOS 26 scroll edge effect on ScrollView and ListView - #11447

Merged
NathanWalker merged 1 commit into
mainfrom
feat/ios-scroll-edge-effect
Oct 2, 2026
Merged

NathanWalker merged 1 commit into
mainfrom
feat/ios-scroll-edge-effect

Conversation

@NathanWalker

Copy link
Copy Markdown
Contributor

What

First-class access to the iOS 26 scroll edge effect on ScrollView and ListView.

  • iosScrollEdgeEffect: 'automatic' | 'soft' | 'hard' | 'none' (default automatic), applied to every edge of the native scroll view. soft is the blur-and-fade UIKit draws under system bars.
  • addScrollEdgeContainer(view, edge) / removeScrollEdgeContainer(view): register a view as a bar the content scrolls beneath, so the effect extends under it and follows it as it moves. Registration completes once both native views exist, survives the container being recreated, and works for a bar in another window (a keyboard accessory).
  • CoreTypes.ScrollEdgeEffect and CoreTypes.ScrollEdge for the string unions.

No-ops before iOS 26 and on Android.

Why

Core pins contentInsetAdjustmentBehavior to never and lays content out inside the safe area itself, so UIKit's automatic edge effects never appear on NativeScript scroll views on iOS 26: content that runs under the status bar stays crisp, and a custom top bar or a docked composer gets no fade at all. The result reads as a hard line wherever dark content (a code block, an image) passes under chrome.

Two facts from testing on the iOS 27 simulator with the 27.1 SDK drive the API shape:

  • Setting the soft style on its own already blurs the status-bar band of a scroll view that overflows the safe area; the automatic style draws nothing for these scroll views.
  • UIScrollEdgeElementContainerInteraction extends the region under any view, including one hosted in the keyboard's window. @nativescript/input-accessory registers its docked composer this way (feat(input-accessory): clear bar on iOS 26+, suspend/restore, collapsed inset plugins#686).

Verification

The same UIKit calls run in ns-octane's ChatGPT-style chat screen on the iPhone 18 Pro / iOS 27 simulator: status bar and a floating top bar at the top edge, the docked composer at the bottom, in light and dark mode, with the keyboard open and closed and through a drawer push.

  • tsc on packages/core and apps/automated, eslint and vitest pass.
  • Automated tests: default value on both views, none/soft mapping to the native effects on iOS 26+, and registering an unloaded view.

@nx-cloud

nx-cloud Bot commented Sep 23, 2026 •

Copy link
Copy Markdown

View your CI Pipeline Execution ↗ for commit bcaafbf

Command Status Duration Result
nx run-many --target=test --configuration=ci --... ✅ Succeeded <1s View ↗

💡 Verify your cache is correct by running tasks in a sandbox. Read docs ↗


☁️ Nx Cloud last updated this comment at 2026-10-02 19:40:50 UTC

@pkg-pr-new

pkg-pr-new Bot commented Sep 23, 2026 •

Copy link
Copy Markdown

Open in StackBlitz

npm i https://pkg.pr.new/@nativescript/core@11447
npm i https://pkg.pr.new/@nativescript/vite@11447
npm i https://pkg.pr.new/@nativescript/webpack@11447

commit: bcaafbf

Core pins contentInsetAdjustmentBehavior to never and lays content out
inside the safe area itself, so UIKit's automatic scroll edge effects
never appear on NativeScript scroll views on iOS 26: content under the
status bar stays crisp and a custom bar gets no fade.

- iosScrollEdgeEffect ('automatic' | 'soft' | 'hard' | 'none') styles or
  hides the effect on every edge; soft on its own already blurs the
  status-bar band of a scroll view that overflows the safe area.
- addScrollEdgeContainer(view, edge) / removeScrollEdgeContainer(view)
  register a bar the content scrolls beneath, through
  UIScrollEdgeElementContainerInteraction, so the effect extends under
  it and follows it. Registration completes once both native views
  exist, survives the bar being recreated, and works for a bar in
  another window.
- CoreTypes.ScrollEdgeEffect and CoreTypes.ScrollEdge.

No-ops before iOS 26 and on Android.
@NathanWalker
NathanWalker force-pushed the feat/ios-scroll-edge-effect branch from 20ec874 to bcaafbf Compare October 2, 2026 19:39
@NathanWalker
NathanWalker merged commit e1370f1 into main Oct 2, 2026
8 of 10 checks passed
@NathanWalker
NathanWalker deleted the feat/ios-scroll-edge-effect branch October 2, 2026 19:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant