Skip to content

fix: [KD-17979] replace absoluteFillObject for RN 0.85 WebView overlay - #133

Merged
ethanpschoen merged 2 commits into
mainfrom
ethanpschoen/fix/KD-17979-rn-085-absolute-fill
Jul 27, 2026
Merged

fix: [KD-17979] replace absoluteFillObject for RN 0.85 WebView overlay#133
ethanpschoen merged 2 commits into
mainfrom
ethanpschoen/fix/KD-17979-rn-085-absolute-fill

Conversation

@ethanpschoen

@ethanpschoen ethanpschoen commented Jul 27, 2026

Copy link
Copy Markdown
Contributor

Description of this change

React Native 0.85 removed StyleSheet.absoluteFillObject. The Ketch WebView overlay container in KetchServiceProvider spread that API for full-screen positioning, so on RN 0.85+ the spread is a no-op and showPreferenceExperience / showConsentExperience can appear not to render. Replaced it with explicit absolute inset styles (position, top, left, right, bottom) and added unit tests that assert the layout and simulate the removed API.

Why is this change being made?

  • Chore (non-functional changes)
  • Bug fix (non-breaking change that fixes an issue)
  • New feature (non-breaking change that adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)

How was this tested? How can the reviewer verify your testing?

  • cd package && npm test — 6/6 Jest tests pass, including new styles.test.ts coverage for full-screen container layout and RN 0.85 absoluteFillObject removal simulation.
  • iOS example app (run-sample-app.sh ios local on iPhone 17 Pro): ReloadPreferences and Consent — WebView overlay covers the full screen.

Reviewer can repeat with the example app linked to file:../package on this branch.

Related issues

Jira: https://ketch-com.atlassian.net/browse/KD-17979

Checklist

  • I have added tests to cover my changes.
  • All new and existing tests passed.
  • I have evaluated the security impact of this change, and OWASP Secure Coding Practices have been observed.
  • I have informed stakeholders of my changes.

Note

Low Risk
Localized styling change with unit tests; no auth, data, or API behavior changes.

Overview
Fixes full-screen Ketch consent/preference WebView overlays on React Native 0.85+, where StyleSheet.absoluteFillObject was removed so spreading it into KetchServiceProvider container styles no longer applied inset positioning.

The overlay container style now uses explicit position: 'absolute' with top/left/right/bottom: 0 instead of ...StyleSheet.absoluteFillObject. New Jest tests in styles.test.ts lock in the expected layout and document the regression when the old spread is a no-op.

Reviewed by Cursor Bugbot for commit 93e72ad. Configure here.

React Native 0.85 removed StyleSheet.absoluteFillObject, so spreading it
was a no-op and the preference/consent WebView container lost full-screen
positioning. Use explicit absolute inset styles and add layout tests.
@ethanpschoen
ethanpschoen requested review from a team as code owners July 27, 2026 16:50
Omit the removed absoluteFillObject spread instead of casting undefined,
which is equivalent runtime behavior and avoids TS2352.
@ethanpschoen
ethanpschoen enabled auto-merge (squash) July 27, 2026 16:53
@ethanpschoen
ethanpschoen merged commit b403727 into main Jul 27, 2026
11 checks passed
@ethanpschoen
ethanpschoen deleted the ethanpschoen/fix/KD-17979-rn-085-absolute-fill branch July 27, 2026 16:54
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.

2 participants