@lodev09/react-native-true-sheet 0.5.1 → 0.5.2

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.
@@ -57,8 +57,6 @@ class TrueSheetView: UIView, RCTInvalidating, TrueSheetViewControllerDelegate {
57
57
  self.bridge = bridge
58
58
 
59
59
  viewController = TrueSheetViewController()
60
- viewController.view.autoresizingMask = [.flexibleHeight, .flexibleWidth]
61
-
62
60
  touchHandler = RCTTouchHandler(bridge: bridge)
63
61
 
64
62
  super.init(frame: .zero)
@@ -166,11 +164,11 @@ class TrueSheetView: UIView, RCTInvalidating, TrueSheetViewControllerDelegate {
166
164
  @objc
167
165
  func setBlurStyle(_ style: NSString?) {
168
166
  guard let style else {
169
- viewController.setBlurStyle(nil)
167
+ viewController.blurView.effect = nil
170
168
  return
171
169
  }
172
170
 
173
- viewController.setBlurStyle(style as String)
171
+ viewController.blurView.effect = UIBlurEffect(with: style as String)
174
172
  }
175
173
 
176
174
  @objc
@@ -75,6 +75,8 @@ class TrueSheetViewController: UIViewController, UISheetPresentationControllerDe
75
75
 
76
76
  blurView.autoresizingMask = [.flexibleWidth, .flexibleHeight]
77
77
  blurView.frame = view.bounds
78
+
79
+ view.autoresizingMask = [.flexibleHeight, .flexibleWidth]
78
80
  view.insertSubview(blurView, at: 0)
79
81
  }
80
82
 
@@ -112,15 +114,6 @@ class TrueSheetViewController: UIViewController, UISheetPresentationControllerDe
112
114
  }
113
115
  }
114
116
 
115
- func setBlurStyle(_ style: String?) {
116
- guard let style else {
117
- blurView.effect = nil
118
- return
119
- }
120
-
121
- blurView.effect = UIBlurEffect(with: style)
122
- }
123
-
124
117
  /// Prepares the view controller for sheet presentation
125
118
  /// Do nothing on IOS 14 and below... sad
126
119
  @available(iOS 15.0, *)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lodev09/react-native-true-sheet",
3
- "version": "0.5.1",
3
+ "version": "0.5.2",
4
4
  "description": "The true native bottom sheet. 💩",
5
5
  "main": "lib/commonjs/index",
6
6
  "module": "lib/module/index",