Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 6 additions & 4 deletions api-reports/NativeScript.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -1884,7 +1884,9 @@ export interface ShowModalOptions {
fullscreen?: boolean;

ios?: {
presentationStyle: any /* UIModalPresentationStyle */
presentationStyle?: any; /* UIModalPresentationStyle */
width?: number;
height?: number;
}

stretched?: boolean;
Expand Down Expand Up @@ -3065,9 +3067,9 @@ export class XmlParser {
// nativescript-core/index.d.ts:117:5 - (ae-forgotten-export) The symbol "layout" needs to be exported by the entry point index.d.ts
// nativescript-core/index.d.ts:118:5 - (ae-forgotten-export) The symbol "ad" needs to be exported by the entry point index.d.ts
// nativescript-core/index.d.ts:119:5 - (ae-forgotten-export) The symbol "ios" needs to be exported by the entry point index.d.ts
// nativescript-core/ui/core/view-base/view-base.d.ts:171:26 - (ae-forgotten-export) The symbol "Property" needs to be exported by the entry point index.d.ts
// nativescript-core/ui/core/view-base/view-base.d.ts:171:26 - (ae-forgotten-export) The symbol "CssProperty" needs to be exported by the entry point index.d.ts
// nativescript-core/ui/core/view-base/view-base.d.ts:171:26 - (ae-forgotten-export) The symbol "CssAnimationProperty" needs to be exported by the entry point index.d.ts
// nativescript-core/ui/core/view-base/view-base.d.ts:179:26 - (ae-forgotten-export) The symbol "Property" needs to be exported by the entry point index.d.ts
// nativescript-core/ui/core/view-base/view-base.d.ts:179:26 - (ae-forgotten-export) The symbol "CssProperty" needs to be exported by the entry point index.d.ts
// nativescript-core/ui/core/view-base/view-base.d.ts:179:26 - (ae-forgotten-export) The symbol "CssAnimationProperty" needs to be exported by the entry point index.d.ts

// (No @packageDocumentation comment for this package)

Expand Down
10 changes: 9 additions & 1 deletion nativescript-core/ui/core/view-base/view-base.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,15 @@ export interface ShowModalOptions {
/**
* The UIModalPresentationStyle to be used when showing the dialog in iOS .
*/
presentationStyle: any /* UIModalPresentationStyle */
presentationStyle?: any; /* UIModalPresentationStyle */
/**
* width of the popup dialog
*/
width?: number;
/**
* height of the popup dialog
*/
height?: number;
}
android?: {
/**
Expand Down
5 changes: 5 additions & 0 deletions nativescript-core/ui/core/view/view.ios.ts
Original file line number Diff line number Diff line change
Expand Up @@ -432,6 +432,11 @@ export class View extends ViewCommon implements ViewDefinition {
controller.modalPresentationStyle = UIModalPresentationStyle.FullScreen;
} else {
controller.modalPresentationStyle = UIModalPresentationStyle.FormSheet;
//check whether both height and width is provided and are positive numbers
// set it has prefered content size to the controller presenting the dialog
if (options.ios && options.ios.width > 0 && options.ios.height > 0) {
controller.preferredContentSize = CGSizeMake(options.ios.width, options.ios.height);
}
}

if (options.ios && options.ios.presentationStyle) {
Expand Down