Skip to content

Commit

Permalink
Fix modalpresentationstyle (#6077)
Browse files Browse the repository at this point in the history
* Fix invalid popover enum value for modal presentation style

The correct enum value as defined in lib/ios/RNNConvert.m is "popover" not "popOver", in line with UIModalPresentationPopover.

* Add to documentation on modal presentation styles

Add popover value and link to iOS documentation.

Co-authored-by: Yogev Ben David <yogev132@gmail.com>
  • Loading branch information
adatadien and yogevbd authored Mar 31, 2020
1 parent 287d23a commit 951a07b
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 3 deletions.
2 changes: 1 addition & 1 deletion docs/api/OptionsModalPresentationStyle.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@
- overCurrentContext
- overFullScreen
- pageSheet
- popOver
- popover
5 changes: 4 additions & 1 deletion docs/docs/options-migration.md
Original file line number Diff line number Diff line change
Expand Up @@ -374,11 +374,14 @@ topBar: {
Controls the behavior of screens displayed modally.

### Options supported on iOS
* overCurrentContext - Content is displayed over the previous screen. Useful for **transparent modals**
* `overCurrentContext` - Content is displayed over the previous screen. Useful for **transparent modals**
* `formSheet` - Content is centered in the screen
* `pageSheet` -Content partially covers the underlying content
* `overFullScreen` - Content covers the screen, without detaching previous content.
* `fullScreen` - Content covers the screen, previous content is detached.
* `popover` - Content is displayed in a popover view.

More information on the different styles for iOS can be found on https://developer.apple.com/documentation/uikit/uimodalpresentationstyle

### Options supported on Android
* `overCurrentContext` - Content is displayed over the previous screen. Useful for **transparent modals**
Expand Down
2 changes: 1 addition & 1 deletion lib/src/interfaces/Options.ts
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ export enum OptionsModalPresentationStyle {
overFullScreen = 'overFullScreen',
overCurrentContext = 'overCurrentContext',
currentContext = 'currentContext',
popOver = 'popOver',
popover = 'popover',
fullScreen = 'fullScreen',
none = 'none'
}
Expand Down

0 comments on commit 951a07b

Please sign in to comment.