@lodev09/react-native-true-sheet 0.3.0 → 0.3.1

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.
@@ -26,6 +26,7 @@ class DismissEvent(surfaceId: Int, viewId: Int) : Event<PresentEvent>(surfaceId,
26
26
  }
27
27
  }
28
28
 
29
+ // onSizeChange
29
30
  class SizeChangeEvent(surfaceId: Int, viewId: Int, private val sizeInfo: SizeInfo) : Event<SizeChangeEvent>(surfaceId, viewId) {
30
31
  override fun getEventName() = EVENT_NAME
31
32
 
@@ -180,6 +180,8 @@ class TrueSheetView: UIView, RCTInvalidating, TrueSheetViewControllerDelegate {
180
180
  viewController.dismiss(animated: true) {
181
181
  promise.resolve(nil)
182
182
  }
183
+ } else {
184
+ promise.resolve(nil)
183
185
  }
184
186
  }
185
187
 
@@ -233,7 +235,9 @@ class TrueSheetView: UIView, RCTInvalidating, TrueSheetViewControllerDelegate {
233
235
  }
234
236
  }
235
237
 
236
- if !isPresented {
238
+ if isPresented {
239
+ promise.resolve(nil)
240
+ } else {
237
241
  // Keep track of the active index
238
242
  activeIndex = index
239
243
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lodev09/react-native-true-sheet",
3
- "version": "0.3.0",
3
+ "version": "0.3.1",
4
4
  "description": "The true native bottom sheet. 💩",
5
5
  "main": "lib/commonjs/index",
6
6
  "module": "lib/module/index",
@@ -34,7 +34,7 @@
34
34
  "tidy": "yarn typecheck && yarn lint && yarn format && scripts/swiftlint.sh && scripts/ktlint.sh",
35
35
  "clean": "del-cli android/build lib && yarn workspace true-sheet-example clean",
36
36
  "prepare": "bob build",
37
- "release": "release-it"
37
+ "release": "yarn tidy && release-it"
38
38
  },
39
39
  "keywords": [
40
40
  "react-native",