@onekeyfe/react-native-native-sheet 3.0.133 → 3.0.135

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -18,6 +18,10 @@ Pod::Spec.new do |s|
18
18
  "ios/**/*.{swift}",
19
19
  "ios/**/*.{m,mm}",
20
20
  ]
21
+ s.exclude_files = "ios/tests/**/*"
21
22
  s.swift_version = '5.0'
23
+ s.test_spec "Tests" do |test_spec|
24
+ test_spec.source_files = "ios/tests/**/*.swift"
25
+ end
22
26
  install_modules_dependencies(s)
23
27
  end
@@ -0,0 +1,27 @@
1
+ import XCTest
2
+ import UIKit
3
+ @testable import NativeSheet
4
+
5
+ @MainActor
6
+ final class NativeSheetContainerLifecycleTests: XCTestCase {
7
+ func testStagesAndRemovesTheSameContentViewAcrossPresentationCycles() {
8
+ let host = NativeSheetContainerView(frame: CGRect(x: 0, y: 0, width: 320, height: 240))
9
+ let content = UIView(frame: host.bounds)
10
+ content.autoresizingMask = [.flexibleWidth, .flexibleHeight]
11
+
12
+ host.insertChild(content, atIndex: 0)
13
+
14
+ XCTAssertNotNil(content.superview)
15
+ XCTAssertTrue(content.autoresizingMask.isEmpty)
16
+ if #available(iOS 26.0, *) {
17
+ XCTAssertNil(content.superview?.superview)
18
+ } else {
19
+ XCTAssertIdentical(content.superview?.superview, host)
20
+ }
21
+
22
+ host.removeChild(content)
23
+
24
+ XCTAssertNil(content.superview)
25
+ XCTAssertTrue(content.autoresizingMask.isEmpty)
26
+ }
27
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@onekeyfe/react-native-native-sheet",
3
- "version": "3.0.133",
3
+ "version": "3.0.135",
4
4
  "description": "Native bottom sheet host for arbitrary React Native content",
5
5
  "source": "./src/index.tsx",
6
6
  "main": "./lib/module/index.js",