Skip to content

Commit d67f199

Browse files
author
Marcus Williams
committed
Revert "update"
This reverts commit a3c75a8.
1 parent a3c75a8 commit d67f199

File tree

4 files changed

+8
-21
lines changed

4 files changed

+8
-21
lines changed

Diff for: nativescript-angular/directives/dialogs.ts

+2-6
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,6 @@ export interface ModalDialogOptions {
2626
stretched?: boolean;
2727
viewContainerRef?: ViewContainerRef;
2828
moduleRef?: NgModuleRef<any>;
29-
ios?: any;
3029
}
3130

3231
export class ModalDialogParams {
@@ -47,7 +46,6 @@ interface ShowDialogOptions {
4746
parentView: ViewBase;
4847
resolver: ComponentFactoryResolver;
4948
type: Type<any>;
50-
ios: any;
5149
}
5250

5351
@Injectable()
@@ -56,7 +54,7 @@ export class ModalDialogService {
5654
}
5755

5856
public showModal(type: Type<any>,
59-
{ viewContainerRef, moduleRef, context, fullscreen, animated, stretched, ios }: ModalDialogOptions
57+
{ viewContainerRef, moduleRef, context, fullscreen, animated, stretched }: ModalDialogOptions
6058
): Promise<any> {
6159
if (!viewContainerRef) {
6260
throw new Error(
@@ -107,7 +105,6 @@ export class ModalDialogService {
107105
parentView,
108106
resolver,
109107
type,
110-
ios
111108
});
112109
} catch (err) {
113110
reject(err);
@@ -127,7 +124,6 @@ export class ModalDialogService {
127124
parentView,
128125
resolver,
129126
type,
130-
ios
131127
}: ShowDialogOptions): void {
132128
let componentView: View;
133129
let detachedLoaderRef: ComponentRef<DetachedLoader>;
@@ -165,7 +161,7 @@ export class ModalDialogService {
165161

166162
// TODO: remove <any> cast after https://github.com/NativeScript/NativeScript/pull/5734
167163
// is in a published version of tns-core-modules.
168-
(<any>parentView).showModal(componentView, context, closeCallback, fullscreen, animated, stretched, ios);
164+
(<any>parentView).showModal(componentView, context, closeCallback, fullscreen, animated, stretched);
169165
});
170166
}
171167
}

Diff for: ng-sample/app/examples/modal/modal-test.ts

+2-9
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ import { ModalContent } from "./modal-content";
1212
<Button text="show component no anim (ios)" (tap)="showModal(false, false)"></Button>
1313
<Button text="show component stretched (android)" (tap)="showModal(false, false, true)"></Button>
1414
<Button text="show component fullscreen" (tap)="showModal(true)"></Button>
15-
<Button text="show component popover" (tap)="showModal(false, true, false, true)"></Button>
1615
1716
<Button text="alert" (tap)="showAlert()"></Button>
1817
<Button text="confirm" (tap)="showConfirm()"></Button>
@@ -36,21 +35,15 @@ export class ModalTest {
3635

3736
static exports = [];
3837

39-
public showModal(fullscreen: boolean, animated = true, stretched = false, popover = false) {
40-
let options: ModalDialogOptions = {
38+
public showModal(fullscreen: boolean, animated = true, stretched = false) {
39+
const options: ModalDialogOptions = {
4140
context: { promptMsg: "This is the prompt message!" },
4241
fullscreen,
4342
animated,
4443
stretched,
4544
viewContainerRef: this.vcRef
4645
};
4746

48-
if (popover) {
49-
options.ios = {
50-
presentationStyle: UIModalPresentationStyle.Popover
51-
};
52-
}
53-
5447
this.modal.showModal(ModalContent, options).then((res: string) => {
5548
this.result = res || "empty result";
5649
});

Diff for: ng-sample/package.json

+3-3
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
"version": "next"
66
},
77
"tns-ios": {
8-
"version": "5.2.0-2019-02-01-153600-01"
8+
"version": "next"
99
}
1010
},
1111
"name": "tns-template-hello-world",
@@ -42,8 +42,9 @@
4242
"@angular/platform-browser-dynamic": "~7.2.0",
4343
"@angular/router": "~7.2.0",
4444
"nativescript-angular": "file:../nativescript-angular",
45-
"rxjs": "^6.3.3",
45+
"rxjs": "~6.3.3",
4646
"tns-core-modules": "next",
47+
"tns-platform-declarations": "next",
4748
"zone.js": "^0.8.4"
4849
},
4950
"devDependencies": {
@@ -54,7 +55,6 @@
5455
"lazy": "1.0.11",
5556
"nativescript-dev-typescript": "next",
5657
"shelljs": "^0.7.0",
57-
"tns-platform-declarations": "^5.1.2",
5858
"tslint": "^4.5.1",
5959
"typescript": "~3.1.1"
6060
},

Diff for: ng-sample/references.d.ts

+1-3
Original file line numberDiff line numberDiff line change
@@ -1,3 +1 @@
1-
/// <reference path="./node_modules/tns-core-modules/tns-core-modules.d.ts" /> Needed for autocompletion and compilation.
2-
/// <reference path="./node_modules/tns-platform-declarations/ios.d.ts" />
3-
/// <reference path="./node_modules/tns-platform-declarations/android.d.ts" />
1+
/// <reference path="./node_modules/tns-core-modules/tns-core-modules.d.ts" /> Needed for autocompletion and compilation.

0 commit comments

Comments
 (0)