Giter Club home page Giter Club logo

nativescript-cfalert-dialog's Introduction

nativescript-cfalert-dialog npm

Twitter URL Twitter URL

NPM

This plugin is a wrapper around CFAlertDialog for Android and CFAlertViewController.

Screenshots

Android

iOS

Installation

tns plugin add nativescript-cfalert-dialog

Configuration

no configuration step involved

Usage

NativeScript Core with { TypeScript } (works on Core, Angular and Vue as well)

import { CFAlertDialog,
         DialogOptions,
         CFAlertGravity,
         CFAlertActionAlignment,
         CFAlertActionStyle,
         CFAlertStyle } from 'nativescript-cfalert-dialog';

let cfalertDialog = new CFAlertDialog();

let options: DialogOptions = {
      // Options go here
      dialogStyle: CFAlertStyle.ALERT,
      title: "This is cool!",
    }

cfalertDialog.show(options); // That's about it ;)

API

show(options): Promise<string>;

Shows the CFAlert Dialog based on the options provided. It returns a promise which can either resolve with a button title (if button was clicked), or it can resolve empty (undefined).

dismiss(animate:boolean): void;

Dismiss the CFAlert Dialog (animate option effective on iOS only)

Options format

// Everything that has '?' is optional
export interface DialogOptions {
    dialogStyle: CFAlertStyle;
    title: string;
    titleColor?: string,
    message?: string;
    messageColor?: string;
    textColor?: string;
    textAlignment?: CFAlertGravity;
    backgroundColor?: string,
    backgroundBlur?: string, // iOS only
    cancellable?: boolean,
    headerView?: any, // nativeView
    footerView?: any, // nativeView
    onDismiss?: Function, // calback for dismiss, function (dialog)
    buttons?: [{
        text: string, // title
        buttonStyle: CFAlertActionStyle,
        buttonAlignment?: CFAlertActionAlignment,
        textColor?: string,
        backgroundColor?: string,
        onClick: Function // function (buttonName)
    }],    
    simpleList?: { // android only
        items: [string],
        onClick: Function // function(dialogInterface, index)
    },
    singleChoiceList?: { // android only
        items: [string],
        selectedItem: number,
        onClick: Function // function(dialogInterface, index)
    },
    multiChoiceList?: { // android only
        items: [string],
        selectedItems: [boolean], // should have same number of elements as 'items'
        onClick: Function // function (dialogInterface, index, b)
    }
}

License

Apache License Version 2.0, January 2004

nativescript-cfalert-dialog's People

Contributors

bradmartin avatar darkmantle avatar dodongphure avatar eddyverbruggen avatar jeremypele avatar maskedspade avatar shiv19 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

nativescript-cfalert-dialog's Issues

Got Error in build iOS project after installing


/Users/mahavirvataliya/Documents/mobile-app/platforms/ios/Pods/Toaster/Sources/ToastWindow.swift:108:16: error: 'dynamic' instance method 'statusBarOrientationWillChange()' must also be '@objc'
  dynamic func statusBarOrientationWillChange() {
  ~~~~~~~      ^
  @objc
/Users/mahavirvataliya/Documents/mobile-app/platforms/ios/Pods/Toaster/Sources/ToastWindow.swift:112:16: error: 'dynamic' instance method 'statusBarOrientationDidChange()' must also be '@objc'
  dynamic func statusBarOrientationDidChange() {
  ~~~~~~~      ^
  @objc
/Users/mahavirvataliya/Documents/mobile-app/platforms/ios/Pods/Toaster/Sources/ToastCenter.swift:69:16: error: 'dynamic' instance method 'deviceOrientationDidChange()' must also be '@objc'
  dynamic func deviceOrientationDidChange() {
  ~~~~~~~      ^
  @objc
/Users/mahavirvataliya/Documents/mobile-app/platforms/ios/Pods/Toaster/Sources/ToastView.swift:41:20: error: 'dynamic' var 'cornerRadius' must also be'@objc'
  open dynamic var cornerRadius: CGFloat {
       ~~~~~~~     ^
  @objc
/Users/mahavirvataliya/Documents/mobile-app/platforms/ios/Pods/Toaster/Sources/ToastView.swift:47:20: error: 'dynamic' var 'textInsets' must also be '@objc'
  open dynamic var textInsets = UIEdgeInsets(top: 6, left: 10, bottom: 6, right: 10)
       ~~~~~~~     ^
  @objc
/Users/mahavirvataliya/Documents/mobile-app/platforms/ios/Pods/Toaster/Sources/ToastView.swift:50:20: error: 'dynamic' var 'textColor' must also be '@objc'
  open dynamic var textColor: UIColor? {
       ~~~~~~~     ^
  @objc
/Users/mahavirvataliya/Documents/mobile-app/platforms/ios/Pods/Toaster/Sources/ToastView.swift:56:20: error: 'dynamic' var 'font' must also be '@objc'
  open dynamic var font: UIFont? {
       ~~~~~~~     ^
  @objc
/Users/mahavirvataliya/Documents/mobile-app/platforms/ios/Pods/Toaster/Sources/ToastView.swift:62:20: error: 'dynamic' var 'bottomOffsetPortrait' mustalso be '@objc'
  open dynamic var bottomOffsetPortrait: CGFloat = {
       ~~~~~~~     ^
  @objc
/Users/mahavirvataliya/Documents/mobile-app/platforms/ios/Pods/Toaster/Sources/ToastView.swift:73:20: error: 'dynamic' var 'bottomOffsetLandscape' must also be '@objc'
  open dynamic var bottomOffsetLandscape: CGFloat = {
       ~~~~~~~     ^
  @objc
/Users/mahavirvataliya/Documents/mobile-app/platforms/ios/Pods/Toaster/Sources/ToastWindow.swift:108:16: error: 'dynamic' instance method 'statusBarOrientationWillChange()' must also be '@objc'
  dynamic func statusBarOrientationWillChange() {
  ~~~~~~~      ^
  @objc
/Users/mahavirvataliya/Documents/mobile-app/platforms/ios/Pods/Toaster/Sources/ToastWindow.swift:112:16: error: 'dynamic' instance method 'statusBarOrientationDidChange()' must also be '@objc'
  dynamic func statusBarOrientationDidChange() {
  ~~~~~~~      ^
  @objc
/Users/mahavirvataliya/Documents/mobile-app/platforms/ios/Pods/Toaster/Sources/ToastWindow.swift:72:17: error: argument of '#selector' refers to instance method 'bringWindowToTop' that is not exposed to Objective-C
      selector: #selector(self.bringWindowToTop),
                ^              ~~~~~~~~~~~~~~~~
/Users/mahavirvataliya/Documents/mobile-app/platforms/ios/Pods/Toaster/Sources/ToastWindow.swift:101:8: note: add '@objc' to expose this instance method to Objective-C
  func bringWindowToTop(_ notification: Notification) {
       ^
  @objc
/Users/mahavirvataliya/Documents/mobile-app/platforms/ios/Pods/Toaster/Sources/ToastWindow.swift:90:17: error: argument of '#selector' refers to instance method 'applicationDidBecomeActive()' that is not exposed to Objective-C
      selector: #selector(self.applicationDidBecomeActive),
                ^              ~~~~~~~~~~~~~~~~~~~~~~~~~~
/Users/mahavirvataliya/Documents/mobile-app/platforms/ios/Pods/Toaster/Sources/ToastWindow.swift:118:8: note: add '@objc' to expose this instance method to Objective-C
  func applicationDidBecomeActive() {
       ^
  @objc

Above Error Occurred after installing plugin in iOS

textColor and backgroundColor of button is not set up for Android

Please apply textColor and backgroundColor of button for Android.
if (options.buttons) { var _loop_1 = function (i) { var button = options.buttons[i] builder.addButton(button.text, -1, -1, actionStyles[button.buttonStyle], alignment[button.buttonAlignment], new android.content.DialogInterface.OnClickListener({ onClick: function (dialog, which) { button.onClick(button.text) dialog.dismiss() } })) } for (var i = 0; i < options.buttons.length; i++) { _loop_1(i) } }

Page can't show notification again after reactivated (navigate to new page then goback)

Make sure to check the demo app(s) for sample usage

Yes

Make sure to check the existing issues in this repository

Yes

If the demo apps cannot help and there is no issue for your problem, tell us about it

See detail

Which platform(s) does your issue occur on?

IOS emulator(haven't tested on Android)

Please, provide the following version numbers that your issue occurs with:

  • CLI: (run tns --version to fetch it)
    tns --version 4.0.0

  • Cross-platform modules: (check the 'version' attribute in the
    node_modules/tns-core-modules/package.json file in your project)
    [email protected]

  • Runtime(s): (look for the "tns-android" and "tns-ios" properties in the package.json file of your project)
    tns-ios 4.0.1

  • Plugin(s): (look for the version numbers in the package.json file of your
    project and paste your dependencies and devDependencies here)
    "nativescript-cfalert-dialog": "^1.0.6",

Please, tell us how to recreate the issue in as much detail as possible.

Describe the steps to reproduce it.

  • the process is like: page1 ->go page2 ->go page3, and in page2, a notification will show.
  • if goes like page1->go page2, show notification, close notification -> go back to page1 -> go page2. Everything works as expected
  • if goes like page1->go page2, show notification, close notification -> go page3 -> go back to page2. Page2 can't show notification again, and in this situation, if go back to page1, you can't go to page2 again

Also, I'm using Nativescript + Angular. Though I doubt it's related.

Is there any code involved?

  • provide a code example to recreate the problem
  • (EVEN BETTER) provide a .zip with application or refer to a repository with application where the problem is reproducible.

Needs to go use version 1.1.0 of CFAlertDialog (or later)

The main problem with this plugin being on version 1.0.1 of CFAlertDialog is that the textColor does not work as expected. This has (apparently) been fixed in version 1.1.0. I can change the include.gradle to use version 1.1.0 and it works fine.

Please update this plugin to use version 1.1.0 (or later) of CFAlertDialog.

Working with Nativescript-Vue

I use Nativescript 6.0.1 and using Nativescript-Vue. Using this alert method:
https://nativescript-vue.org/en/docs/elements/dialogs/alert/

I want to change it with this cool dialog.

I tried code as they said but i get; 'types' can only be used in a .ts file.Vetur(8010) error. I guess because of my files are not .ts they are .vue.

image

How can I use this plugin in Nativescript-Vue. Any sample codes will helps a lot.

ReferenceError: CFAlertStyle is not defined

Make sure to check the demo app(s) for sample usage

Checked

Make sure to check the existing issues in this repository

Checked

If the demo apps cannot help and there is no issue for your problem, tell us about it

Please, ensure your title is less than 63 characters long and starts with a capital
letter.

Which platform(s) does your issue occur on?

  • Android
  • Android versions
  • emulator or device. What type of device?
    Genymotion Emulator

Error - Using Vanilla Js

An uncaught Exception occurred on "main" thread.
com.tns.NativeScriptException:
Calling js method onTouch failed

ReferenceError: CFAlertStyle is not defined
File: "file:///data/data/org.nativescript.E4/files/app/tns_modules/tns-core-modules/ui/gestures/gestures.js, line: 228, column: 40

StackTrace:
Frame: function:'ChangeColor', file:'file:///data/data/org.nativescript.E4/files/app/choose/choose-page.js', line: 40, column: 22
Frame: function:'_executeCallback', file:'file:///data/data/org.nativescript.E4/files/app/tns_modules/tns-core-modules/ui/gestures/gestures.js', line: 282, column: 27
Frame: function:'TapAndDoubleTapGestureListenerImpl.onSingleTapUp', file:'file:///data/data/org.nativescript.E4/files/app/tns_modules/tns-core-modules/ui/gestures/gestures.js', line: 25, column: 17
Frame: function:'GesturesObserver.androidOnTouchEvent', file:'file:///data/data/org.nativescript.E4/files/app/tns_modules/tns-core-modules/ui/gestures/gestures.js', line: 228, column: 41
Frame: function:'', file:'file:///data/data/org.nativescript.E4/files/app/tns_modules/tns-core-modules/ui/core/view/view.js', line: 252, column: 25
Frame: function:'View.handleGestureTouch', file:'file:///data/data/org.nativescript.E4/files/app/tns_modules/tns-core-modules/ui/core/view/view.js', line: 251, column: 18
Frame: function:'TouchListenerImpl.onTouch', file:'file:///data/data/org.nativescript.E4/files/app/tns_modules/tns-core-modules/ui/core/view/view.js', line: 30, column: 19

at com.tns.Runtime.callJSMethodNative(Native Method)
at com.tns.Runtime.dispatchCallJSMethodNative(Runtime.java:1120)
at com.tns.Runtime.callJSMethodImpl(Runtime.java:1000)
at com.tns.Runtime.callJSMethod(Runtime.java:987)
at com.tns.Runtime.callJSMethod(Runtime.java:967)
at com.tns.Runtime.callJSMethod(Runtime.java:959)
at com.tns.gen.java.lang.Object_view_24_32_TouchListenerImpl.onTouch(Object_view_24_32_TouchListenerImpl.java:18)
at android.view.View.dispatchTouchEvent(View.java:11717)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2961)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2650)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2961)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2650)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2961)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2650)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2961)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2650)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2961)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2650)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2961)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2650)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2961)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2650)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2961)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2650)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2961)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2650)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2961)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2650)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2961)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2650)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2961)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2650)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2961)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2650)
at com.android.internal.policy.DecorView.superDispatchTouchEvent(DecorView.java:445)
at com.android.internal.policy.PhoneWindow.superDispatchTouchEvent(PhoneWindow.java:1828)
at android.app.Activity.dispatchTouchEvent(Activity.java:3292)
at android.support.v7.view.WindowCallbackWrapper.dispatchTouchEvent(WindowCallbackWrapper.java:69)
at com.android.internal.policy.DecorView.dispatchTouchEvent(DecorView.java:407)
at android.view.View.dispatchPointerEvent(View.java:11960)
at android.view.ViewRootImpl$ViewPostImeInputStage.processPointerEvent(ViewRootImpl.java:4776)
at android.view.ViewRootImpl$ViewPostImeInputStage.onProcess(ViewRootImpl.java:4590)
at android.view.ViewRootImpl$InputStage.deliver(ViewRootImpl.java:4128)
at android.view.ViewRootImpl$InputStage.onDeliverToNext(ViewRootImpl.java:4181)
at android.view.ViewRootImpl$InputStage.forward(ViewRootImpl.java:4147)
at android.view.ViewRootImpl$AsyncInputStage.forward(ViewRootImpl.java:4274)
at android.view.ViewRootImpl$InputStage.apply(ViewRootImpl.java:4155)
at android.view.ViewRootImpl$AsyncInputStage.apply(ViewRootImpl.java:4331)
at android.view.ViewRootImpl$InputStage.deliver(ViewRootImpl.java:4128)
at android.view.ViewRootImpl$InputStage.onDeliverToNext(ViewRootImpl.java:4181)
at android.view.ViewRootImpl$InputStage.forward(ViewRootImpl.java:4147)
at android.view.ViewRootImpl$InputStage.apply(ViewRootImpl.java:4155)
at android.view.ViewRootImpl$InputStage.deliver(ViewRootImpl.java:4128)
at android.view.ViewRootImpl.deliverInputEvent(ViewRootImpl.java:6642)
at android.view.ViewRootImpl.doProcessInputEvents(ViewRootImpl.java:6616)
at android.view.ViewRootImpl.enqueueInputEvent(ViewRootImpl.java:6577)
at android.view.ViewRootImpl$WindowInputEventReceiver.onInputEvent(ViewRootImpl.java:6745)
at android.view.InputEventReceiver.dispatchInputEvent(InputEventReceiver.java:185)
at android.os.MessageQueue.nativePollOnce(Native Method)
at android.os.MessageQueue.next(MessageQueue.java:325)
at android.os.Looper.loop(Looper.java:142)
at android.app.ActivityThread.main(ActivityThread.java:6541)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.Zygote$MethodAndArgsCaller.run(Zygote.java:240)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:767)

Alert not shown on iOS on top of modal

With Nativescript 6.2 and iOS 13 the dialog will not show if it is opened on top of a modal.

I supect, that it opens behind the modal or not at all, but no error is thrown.

This is works as expected on Android.

[Feature Request] include icon in button text

What would it take to include an icon image next to the text in the buttons? Maybe something like this?:

let options: DialogOptions = {
  dialogStyle: CFAlertStyle.BOTTOM_SHEET,
  title: '',
  buttons: [
    {
      text: 'Edit',
      buttonStyle: CFAlertActionStyle.POSITIVE,
      icon: 'res://edit',
      iconPosition: CFAlertButtonIconPosition.LEFT,
      onClick: (() => console.log('Edit'))
    },
    {
      text: 'Delete',
      buttonStyle: CFAlertActionStyle.NEGATIVE,
      icon: 'res://trash',
      iconPosition: CFAlertButtonIconPosition.RIGHT,
      onClick: (() => console.log('Delete'))
    }
  ]
}

Font awesome

First: This plugin is awesome!
Second: This is not an issue at all, but I can't find any discussion about using a Font Awesome icon instead of string text in a button. ยฟHow could I include a button with an icon?

Thank you @shiv19 for your support.

Font size

is it possible change the font size?

Button textColor does not work correctly on Android

If you specify '#ffffff' for the button textColor property, the dialog will show, but the text color is not white. If you specify something other than '#ffffff', like '#ff0000', the dialog with not show and the following error will be thrown and show in the console:

ERROR Error: Uncaught (in promise): Error: android.content.res.Resources$NotFoundException: Resource ID #0xffff0000

This is easy to reproduce using the provided demo app.

Dialog BackgroundColor?

How to set a background for the dialog it self? The current option "backgroundColor" set the color only to the dialog background content but the dialog background color is not changing and always stays white.

Close all dialogs

Nice plugin. I have been using it for my nativescript-vue project. Am wondering if this is possible to close all the dialogs on screen with a single click of a button. Let's say i have 3 dialogs and clicking a button or triggering an event closes all of them

multi choose error

hi guys . i get error when i choose more than 4 items in multiChoiceList

error : multi select items and boolean array size not equal

var cfalertDialog = new CFAlertDialog();
var itemState = [false, false, false, false, false];
var options = {
dialogStyle: CFAlertStyle.ALERT,
title: 'This is a simple list!',
multiChoiceList: {
items: ['first', 'second', 'third', 'fourth' ,'fifth'],
selectedItems: itemState,
onClick: function(dialogInterface, index, b) {
console.log(dialogInterface);
console.log(index);
console.log(b);
},
},
buttons: [
{
text: 'Okay',
buttonStyle: CFAlertActionStyle.POSITIVE,
buttonAlignment: CFAlertActionAlignment.END,
onClick: function(response) {
console.log(response);
},
},
],
};
cfalertDialog.show(options);

i use 1.0.6 version

.show() to return a Promise

Hey, fantastic plugin! Great work. It is very well written and a delight to use.

I have a feature request. What is the feasibility of the show() function returning a promise, rather than void? For example, if I wanted to show a few dialogs in sequence, but perform async tasks in between them. Maybe the show() function could return whatever is returned in the onClick() callback?

Can I render custom elements in the dialog?

Hi, I have a quick question โ€“ are the dialogs limited to the available form elements (buttons, radio buttons, checkboxes etc.) or can I freely render my own components? Like for example, I'd like to have a pill button, a linear slider etc.

iOS: problem with programmatically close the dialog

Which platform(s) does your issue occur on?

  • iOS 13
  • iPhone 7

I'm using this plugin for iOS. All work fine, except that when I want programmatically close the dialog.

If I call "dismiss" the dialog close, but the app freeze, while if I click on the dialog button close all work fine. Need to declare something else?

Thanks

There are error in callbacks function click button

Clicks button on dialogStyle: CFAlertStyle.BOTTOM_SHEET, never return your repective callback click button, always return the last callback button that was setup.

{
	"text": "Okay",
	"buttonStyle": CFAlertActionStyle.POSITIVE,
	"buttonAlignment": CFAlertActionAlignment.JUSTIFIED,
	"onClick": function(response) {
		console.log(response);
	}
}, {
	"text": "Nope",
	"buttonStyle": CFAlertActionStyle.NEGATIVE,
	"buttonAlignment": CFAlertActionAlignment.JUSTIFIED,
	"onClick": function(response) {
                // always return here, because is the last button in array
		console.log(response);
	}
}

Ex. if I tapping OK, enter into callback of Nope Function.

Update to Nativescript 8.1

I have updated to nativescript.core 8.1.5 and now i receive this error from this plugin:

Error in ./node-modules/nativescript-cfalert-dialog/cfalert-dialog.ios.js 3:12-38

Any chance for a fix?

Error with version 3.1 of the iOS Pods

If the demo apps cannot help and there is no issue for your problem, tell us about it

/my-project/platforms/ios/Pods/CFAlertViewController/CFAlertViewController/Cells/CFAlertActionTableViewCell.swift:170:49: error: 'CellStyle' is not a member type of 'UITableViewCell'
    public override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) {
                                ~~~~~~~~~~~~~~~ ^
/my-project/platforms/ios/Pods/CFAlertViewController/CFAlertViewController/Cells/CFAlertActionTableViewCell.swift:170:21: error: initializer does not override a designated initializer from its superclass
    public override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) {
           ~~~~~~~~ ^
/my-project/platforms/ios/Pods/CFAlertViewController/CFAlertViewController/Cells/CFAlertTitleSubtitleTableViewCell.swift:67:49: error: 'CellStyle' is not a member type of 'UITableViewCell'
    public override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) {
                                ~~~~~~~~~~~~~~~ ^
/Users/fthuin/Documents/tabacstop-nativescript/platforms/ios/Pods/CFAlertViewController/CFAlertViewController/Cells/CFAlertTitleSubtitleTableViewCell.swift:67:21: error: initializer does not override a designated initializer from its superclass
    public override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) {
           ~~~~~~~~ ^
/my-project/platforms/ios/Pods/CFAlertViewController/CFAlertViewController/CFAlertViewController.swift:359:103: error: type 'UIResponder' has no member 'keyboardWillShowNotification'
        NotificationCenter.default.addObserver(self, selector: #selector(keyboardWillShow(_:)), name: UIResponder.keyboardWillShowNotification, object: nil)
                                                                                                      ^~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/my-project/platforms/ios/Pods/CFAlertViewController/CFAlertViewController/CFAlertViewController.swift:360:103: error: type 'UIResponder' has no member 'keyboardWillHideNotification'
        NotificationCenter.default.addObserver(self, selector: #selector(keyboardWillHide(_:)), name: UIResponder.keyboardWillHideNotification, object: nil)
                                                                                                      ^~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/my-project/platforms/ios/Pods/CFAlertViewController/CFAlertViewController/CFAlertViewController.swift:363:121: error: type 'UITextField' has no member 'textDidBeginEditingNotification'
        NotificationCenter.default.addObserver(self, selector: #selector(textViewOrTextFieldDidBeginEditing(_:)), name: UITextField.textDidBeginEditingNotification, object: nil)
                                                                                                                        ^~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/Users/fthuin/Documents/tabacstop-nativescript/platforms/ios/Pods/CFAlertViewController/CFAlertViewController/CFAlertViewController.swift:364:121: error: type 'UITextView' has no member 'textDidBeginEditingNotification'
        NotificationCenter.default.addObserver(self, selector: #selector(textViewOrTextFieldDidBeginEditing(_:)), name: UITextView.textDidBeginEditingNotification, object: nil)
                                                                                                                        ^~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/my-project/platforms/ios/Pods/CFAlertViewController/CFAlertViewController/CFAlertViewController.swift:607:34: error: type 'UIResponder' has no member 'keyboardFrameEndUserInfoKey'
            if let kbRect = info[UIResponder.keyboardFrameEndUserInfoKey] as? CGRect {
                                 ^~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~
/my-project/platforms/ios/Pods/CFAlertViewController/CFAlertViewController/CFAlertViewController.swift:783:16: error: type 'UITableView' has no member 'automaticDimension'
        return UITableView.automaticDimension
               ^~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~
/my-project/platforms/ios/Pods/CFAlertViewController/CFAlertViewController/CFAlertViewController.swift:787:16: error: type 'UITableView' has no member 'automaticDimension'
        return UITableView.automaticDimension
               ^~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~
** ARCHIVE FAILED **

Which platform(s) does your issue occur on?

  • iOS 11.4
  • iPhone SE / any emulators

Please, provide the following version numbers that your issue occurs with:

  • CLI: 4.2
  • Cross-platform modules: 4.2
  • Runtime(s): 4.2
  • Plugin(s): 1.0.11

Please, tell us how to recreate the issue in as much detail as possible.

tns run iOS

Is there any code involved?

It seems to be related to the latest version of the Pod because I can fix it by modifying Podfile

Previous: pod 'CFAlertViewController'

Working: pod 'CFAlertViewController', '3.0'

Vanilla Javascript implementation provided

For whomsoever it may concern, mentioned below is the Vanilla Javascript version implementation of this plugin.

Create 7 button's and assign each with a tap as listed below to view the sample implementation.
### XML Code #######################################################

<GridLayout columns="*, *" rows="40, 50, 50, 50, 50" marginBottom="10">
                            <Label col="0" row="0" colSpan="2" loaded="centerMe" fontWeight="bold" fontSize="20" height="40" text="Android / iOS CFAlerts" width="100%"></Label>
                            <Button col="0" row="1" text="Show Notification" tap="showCfNotification" width="150"></Button>
                            <Button col="1" row="1" text="Show Alert" tap="showCfAlert" width="150"></Button>
                            <Button col="0" row="2" text="Show Bottom Sheet" tap="showCfBottomSheet" width="150"></Button>
                            <Button col="1" row="2" text="Show Simple List (Android only)" tap="showCfSimpleList" width="150"></Button>
                            <Button col="0" row="3" text="Show Single Choice List (Android only)" tap="showCfSingleChoiceList" width="150"></Button>
                            <Button col="1" row="3" text="Show Multi Choice List (Android only)" tap="showCfMultiChoiceList" width="150"></Button>
                            <Button col="0" row="4" text="Show Colored Alert" tap="showCfColoredAlert" width="150"></Button>
                        </GridLayout>

### JS Code #########################################################

exports.showCfNotification = function (args) {
    cfalertDialog.show({
        dialogStyle: CFAlertStyle.NOTIFICATION,
        title: "This is a notification!",
        message: "It is shown at the top of the screen, and the background is blurry (in iOS).",
        backgroundBlur: true,
        onDismiss: function (dialog) {
            console.log("Dialog was dismissed");
        },
        buttons: [{
            text: "Okay",
            buttonStyle: CFAlertActionStyle.POSITIVE,
            buttonAlignment: CFAlertActionAlignment.END,
            textColor: "#FFFFFF",
            backgroundColor: "#000000",
            onClick: function (response) {
                console.log(response);
            }
        }]
    });
};

exports.showCfAlert = function (args) {
    cfalertDialog.show({
        dialogStyle: CFAlertStyle.ALERT,
        title: "This is an alert with a red background and no buttons!",
        backgroundBlur: false,
        backgroundColor: "red",
        message: "It is shown at the center of the screen, and you can tap outside of it to dismiss it."
    });
};

exports.showCfBottomSheet = function (args) {
    cfalertDialog.show({
        dialogStyle: CFAlertStyle.BOTTOM_SHEET,
        title: "This is a bottom sheet!",
        message: "It is shown at the bottom of the screen",
        buttons: [{
                text: "Okay",
                buttonStyle: CFAlertActionStyle.POSITIVE,
                buttonAlignment: CFAlertActionAlignment.JUSTIFIED,
                onClick: function (response) {
                    console.log("Inside OK Response");
                    console.log(response); // Prints Okay
                }
            },
            {
                text: "Nope",
                buttonStyle: CFAlertActionStyle.NEGATIVE,
                buttonAlignment: CFAlertActionAlignment.JUSTIFIED,
                onClick: function (response) {
                    console.log("Inside Nope Response");
                    console.log(response); // Prints Nope
                }
            }
        ]
    });
};

exports.showCfSimpleList = function (args) {
    cfalertDialog.show({
        dialogStyle: CFAlertStyle.ALERT,
        title: "This is a simple list!",
        simpleList: {
            items: ["Tomato", "Potato", "Carrot", "Spinach"],
            onClick: function (dialogInterface, index) {
                console.log(dialogInterface);
                console.log(index);
            }
        }
    });
};

exports.showCfSingleChoiceList = function (args) {
    cfalertDialog.show({
        dialogStyle: CFAlertStyle.ALERT,
        title: "This is a simple list!",
        singleChoiceList: {
            items: ["Tomato", "Potato", "Carrot", "Spinach"],
            selectedItem: 2,
            onClick: function (dialogInterface, index) {
                console.log(dialogInterface);
                console.log(index);
            }
        },
        buttons: [{
            text: "Okay",
            buttonStyle: CFAlertActionStyle.POSITIVE,
            buttonAlignment: CFAlertActionAlignment.END,
            onClick: function (response) {
                console.log(response);
            }
        }]
    });
};

exports.showCfMultiChoiceList = function (args) {
    var itemState = [false, false, false, false];
    cfalertDialog.show({
        dialogStyle: CFAlertStyle.ALERT,
        title: "This is a simple list!",
        multiChoiceList: {
            items: ["Tomato", "Potato", "Carrot", "Spinach"],
            selectedItems: itemState,
            onClick: function (dialogInterface, index, b) {
                console.log(dialogInterface);
                console.log(index);
                console.log(b);
            }
        },
        buttons: [{
            text: "Okay",
            buttonStyle: CFAlertActionStyle.POSITIVE,
            buttonAlignment: CFAlertActionAlignment.END,
            onClick: function (response) {
                console.log(response);
            }
        }]
    });
};

exports.showCfColoredAlert = function (args) {
    cfalertDialog.show({
        dialogStyle: CFAlertStyle.ALERT,
        title: "This is an alert!",
        message: "It is shown at the center of the screen",
        titleColor: "#FF0000",
        messageColor: "#0000FF",
        backgroundColor: "#00FF00"
    });
};

cancellable: false - does not work (Android)

Make sure to check the demo app(s) for sample usage

Make sure to check the existing issues in this repository

If the demo apps cannot help and there is no issue for your problem, tell us about it

Please, ensure your title is less than 63 characters long and starts with a capital
letter.

Which platform(s) does your issue occur on?

  • iOS/Android/Both
  • iOS/Android versions
  • emulator or device. What type of device?

Android 8.0 - OnePlus3 (Oxygen OS 5.0.2)

Please, provide the following version numbers that your issue occurs with:

  • CLI: (run tns --version to fetch it)
  • Cross-platform modules: (check the 'version' attribute in the
    node_modules/tns-core-modules/package.json file in your project)
  • Runtime(s): (look for the "tns-android" and "tns-ios" properties in the package.json file of your project)
  • Plugin(s): (look for the version numbers in the package.json file of your
    project and paste your dependencies and devDependencies here)
nativescript - 3.4.3 - Up to date
tns-core-modules - 3.4.1 - Up to date
tns-android - 3.4.2 - Up to date
tns-ios - 3.4.1 - Not installed
"dependencies": {
    "nativescript-animatecss": "1.0.0",
    "nativescript-appversion": "1.4.1",
    "nativescript-cardview": "2.0.5",
    "nativescript-cfalert-dialog": "1.0.6",
    "nativescript-checkbox": "3.0.3",
    "nativescript-dom": "2.0.0",
    "nativescript-exit": "1.0.1",
    "nativescript-fancyalert": "1.2.0",
    "nativescript-floatingactionbutton": "4.1.3",
    "nativescript-globalevents": "1.2.1",
    "nativescript-loading-indicator": "2.4.0",
    "nativescript-modal-datetimepicker": "1.1.0",
    "nativescript-pro-ui": "3.4.1",
    "nativescript-snackbar": "2.0.1",
    "nativescript-textinputlayout": "2.0.2",
    "nativescript-theme-core": "~1.0.4",
    "nativescript-toasts": "1.0.3",
    "nativescript-toolbox": "3.0.1",
    "nativescript-vibrate": "2.0.1",
    "tns-core-modules": "~3.4.0"
  },
  "devDependencies": {
    "babel-traverse": "6.4.5",
    "babel-types": "6.4.5",
    "babylon": "6.4.5",
    "copy-webpack-plugin": "~4.3.0",
    "css-loader": "~0.28.7",
    "extract-text-webpack-plugin": "~3.0.2",
    "lazy": "1.0.11",
    "nativescript-dev-webpack": "~0.9.1",
    "nativescript-worker-loader": "~0.8.1",
    "raw-loader": "~0.5.1",
    "resolve-url-loader": "~2.2.1",
    "uglifyjs-webpack-plugin": "~1.1.6",
    "webpack": "~3.10.0",
    "webpack-bundle-analyzer": "^2.9.1",
    "webpack-sources": "~1.1.0"
  },

Please, tell us how to recreate the issue in as much detail as possible.

Describe the steps to reproduce it.

Open the following file in your code folder,
<code-folder-path>\node_modules\nativescript-cfalert-dialog\cfalert-dialog.android.js

There is a statement at line no.84 to set whether dialog should be cancelable or not =>
builder.setCancelable(options.cancellable);

Reference Url -> https://developer.android.com/reference/android/app/AlertDialog.Builder.html#setCancelable(boolean)

I am assuming setting a value of 'false' to the parameter 'cancellable' should give the desired result of the dialog being non-dismissable. But the dialog still gets dismissed by tapping elsewhere on the screen or the device back button. Please guide what can be done to achieve the desired result.

Is there any code involved?

  • provide a code example to recreate the problem
  • (EVEN BETTER) provide a .zip with an application or refer to a repository with an application where the problem is reproducible.

Android: Error in nativescript-cfalert-dialog include.js when running nativescript android app

Which platform(s) does your issue occur on?

  • Android
  • Android : 8.4.0
  • emulator

Please, provide the following version numbers that your issue occurs with:

  • CLI: 8.4.0

Please, tell us how to recreate the issue in as much detail as possible.

trying to run nativescript android project produces the following error:

Script 'appFolder/node_modules/nativescript-cfalert-dialog/platforms/android/include.gradle' line: 17
A problem occurred evaluating script.
Could not find method compile() for arguments [com.android.support:appcompat-v7:22.2.0] on object of type org.gradle.api.internal.artifacts.dsl.dependencies.DefaultDependencyHandler.

Command ./gradlew failed with exit code 1

Can anyone assist in fixing this issue

Is linear-gradient supported?

Running on iOS simulator iPhone 8, NS 5.2

I tried to set the options.backgroundColor property on a BottomSheet dialog like this:
dialogStyle: this.$CFAlertStyle.BOTTOM_SHEET,
backgroundColor: linear-gradient(to bottom, #304B99, #FFFFFF)

But it didn't work. The dialog is not shown at all.
No error logs or anything.

Plugin changes my app name

Make sure to check the demo app(s) for sample usage

I did.

Make sure to check the existing issues in this repository

I did.

If the demo apps cannot help and there is no issue for your problem, tell us about it

The plugin changes my app name. On the home screen, everything is fine, but under Settings -> Apps my app is shown as CFAlertDialog. Also when I send a push message using nativescript-push-notifications, the app title is CFAlertDialog.

Which platform(s) does your issue occur on?

  • Android: yes, I don't know about IOS
  • Android 9
  • Real device

Please, provide the following version numbers that your issue occurs with:

  • CLI: 6.0.3
  • Cross-platform modules: 6.0.7
  • Runtime(s): android 6.0.2
  • Plugin(s):
"dependencies": {
        "@angular/animations": "^8.0.0",
        "@angular/cdk": "^8.1.1",
        "@angular/common": "8.0.0",
        "@angular/compiler": "8.0.0",
        "@angular/core": "8.0.0",
        "@angular/forms": "8.0.0",
        "@angular/http": "8.0.0-beta.10",
        "@angular/platform-browser": "8.0.0",
        "@angular/platform-browser-dynamic": "8.0.0",
        "@angular/router": "8.0.0",
        "@ctrl/ngx-emoji-mart": "^0.17.0",
        "@fortawesome/fontawesome-free": "^5.8.2",
        "@ng-bootstrap/ng-bootstrap": "^4.1.3",
        "@nstudio/nativescript-snackbar": "^1.0.0",
        "@syncfusion/ej2-angular-inputs": "^17.1.50",
        "@syncfusion/ej2-angular-layouts": "^17.2.36",
        "@syncfusion/ej2-angular-navigations": "^17.2.36",
        "@syncfusion/ej2-angular-popups": "^17.1.50",
        "@syncfusion/ej2-angular-schedule": "^17.1.51",
        "ajv": "^6.10.0",
        "angularx-flatpickr": "^6.1.0",
        "bootstrap": "^4.3.1",
        "chart.js": "^2.8.0",
        "chartjs-plugin-datalabels": "^0.6.0",
        "cldr-data": "^35.1.0",
        "core-js": "^2.6.5",
        "date-fns": "^1.30.1",
        "fontawesome": "^5.6.3",
        "nativescript-accordion": "^6.0.0-beta.2",
        "nativescript-angular": "8.0.2",
        "nativescript-cache": "^1.0.0",
        "nativescript-cfalert-dialog": "^1.0.15",
        "nativescript-clipboard": "^1.1.7",
        "nativescript-download-progress": "^1.2.0",
        "nativescript-emoji-picker": "^0.1.0",
        "nativescript-feedback": "^1.3.10",
        "nativescript-local-notifications": "^4.0.1",
        "nativescript-localstorage": "^2.0.1",
        "nativescript-modal-datetimepicker": "^1.2.0",
        "nativescript-multi-select": "^1.0.6",
        "nativescript-ngx-fonticon": "^4.2.0",
        "nativescript-pdf-view": "^2.0.1",
        "nativescript-photoviewer": "^2.1.5",
        "nativescript-plugin-firebase": "^9.1.0",
        "nativescript-progress-notifications": "^1.0.1",
        "nativescript-theme-core": "~1.0.6",
        "nativescript-ui-autocomplete": "5.0.0",
        "nativescript-ui-calendar": "5.0.0",
        "nativescript-ui-chart": "5.0.0",
        "nativescript-ui-dataform": "5.0.0",
        "nativescript-ui-gauge": "5.0.0",
        "nativescript-ui-listview": "7.0.2",
        "nativescript-ui-sidedrawer": "7.0.0",
        "nativescript-videoplayer": "^4.2.1",
        "ng2-charts": "^2.2.3",
        "ng2-pdfjs-viewer": "^4.0.5",
        "ngx-avatar": "^3.5.0",
        "ngx-contextmenu": "^5.2.0",
        "ngx-toastr": "^10.0.4",
        "reflect-metadata": "~0.1.13",
        "rxjs": "^6.5.2",
        "rxjs-compat": "^6.5.2",
        "tns-core-modules": "^6.0.1",
        "tns-platform-declarations": "^6.0.5",
        "zone.js": "0.9.1"
    },
    "devDependencies": {
        "@angular-devkit/build-angular": "0.13.4",
        "@angular/cli": "^7.3.9",
        "@angular/compiler-cli": "8.0.0",
        "@nativescript/schematics": "^0.5.2",
        "@types/jasmine": "~3.3.12",
        "@types/jasminewd2": "~2.0.6",
        "@types/node": "~12.0.2",
        "codelyzer": "~5.0.1",
        "jasmine-core": "~3.4.0",
        "jasmine-spec-reporter": "~4.2.1",
        "karma": "~4.1.0",
        "karma-chrome-launcher": "~2.2.0",
        "karma-coverage-istanbul-reporter": "~2.0.5",
        "karma-jasmine": "~2.0.1",
        "karma-jasmine-html-reporter": "^1.4.2",
        "nativescript-dev-webpack": "1.0.1",
        "node-sass": "4.12.0",
        "protractor": "~5.4.2",
        "systemjs-plugin-json": "^0.3.0",
        "ts-node": "~8.1.0",
        "tslint": "~5.16.0",
        "typescript": "3.4.5"
    },

Please, tell us how to recreate the issue in as much detail as possible.

I just installed the plugin and included the module in my app.module.tns.ts and my app name was changed...

Is there any code involved?

I don't think so.

Cannot read property 'Builder' of undefined in version 3.4.0

Which platform(s) does your issue occur on?

  • Android

I added plugin using tns plugin add nativescript-alert-dialog, and added the code var aaa = require("nativescript-cfalert-dialog"); , after shown Cannot read property 'Builder' of undefined. below is my package.json.

{
  "description": "NativeScript Application",
  "license": "SEE LICENSE IN <your-license-filename>",
  "readme": "NativeScript Application",
  "repository": "<fill-your-repository-here>",
  "nativescript": {
    "id": "com.dapaolah.client",
    "tns-android": {
      "version": "3.4.0"
    },
    "tns-ios": {
      "version": "3.4.0"
    }
  },
  "dependencies": {
    "nativescript-barcodescanner": "^2.7.4",
    "nativescript-camera": "^3.1.4",
    "nativescript-cfalert-dialog": "^1.0.5",
    "nativescript-checkbox": "^3.0.3",
    "nativescript-directions": "^1.1.0",
    "nativescript-feedback": "^1.1.0",
    "nativescript-fonticon": "^1.1.1",
    "nativescript-geolocation": "^3.0.0",
    "nativescript-google-maps-sdk": "^2.4.3",
    "nativescript-localize": "^2.0.1",
    "nativescript-localstorage": "^1.1.5",
    "nativescript-phone": "^1.3.1",
    "nativescript-plugin-firebase": "^5.0.1",
    "nativescript-pro-ui": "^3.1.4",
    "nativescript-slideshow-busy-indicator": "^3.0.1",
    "nativescript-social-share": "^1.5.0",
    "nativescript-theme-core": "~1.0.2",
    "nativescript-zxing": "^1.5.2",
    "tns-core-modules": "^3.4.0"
  },
  "devDependencies": {
    "babel-traverse": "6.4.5",
    "babel-types": "6.4.5",
    "babylon": "6.4.5",
    "copy-webpack-plugin": "~4.0.1",
    "css-loader": "~0.28.7",
    "extract-text-webpack-plugin": "~3.0.0",
    "lazy": "1.0.11",
    "nativescript-dev-android-snapshot": "^0.*.*",
    "nativescript-dev-webpack": "^0.9.0",
    "nativescript-worker-loader": "~0.8.1",
    "raw-loader": "~0.5.1",
    "resolve-url-loader": "~2.1.0",
    "webpack": "~3.8.1",
    "webpack-bundle-analyzer": "^2.8.2",
    "webpack-sources": "~1.0.1"
  }
}

Building Demo app in Xcode 10 fails :(

I get the following error when running the demo app (I see the same error in my Picme app that uses this plugin. Perhaps there's some swift code that needs updating. I think the failure has to do with the new use of Xcode 10.

/Users/Looper/Desktop/dialog/demo/platforms/ios/Pods/CFAlertViewController/CFAlertViewController/CFAlertViewController.swift:359:115: error: 'keyboardWillShowNotification' has been renamed to 'NSNotification.Name.UIKeyboardWillShow'
        NotificationCenter.default.addObserver(self, selector: #selector(keyboardWillShow(_:)), name: UIResponder.keyboardWillShowNotification, object: nil)
                                                                                                                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
                                                                                                                  NSNotification.Name.UIKeyboardWillShow
UIKit.UIResponder:3:22: note: 'keyboardWillShowNotification' was introduced in Swift 4.2
    public class let keyboardWillShowNotification: NSNotification.Name
                     ^
/Users/Looper/Desktop/dialog/demo/platforms/ios/Pods/CFAlertViewController/CFAlertViewController/CFAlertViewController.swift:360:115: error: 'keyboardWillHideNotification' has been renamed to 'NSNotification.Name.UIKeyboardWillHide'
        NotificationCenter.default.addObserver(self, selector: #selector(keyboardWillHide(_:)), name: UIResponder.keyboardWillHideNotification, object: nil)
                                                                                                                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
                                                                                                                  NSNotification.Name.UIKeyboardWillHide
UIKit.UIResponder:7:22: note: 'keyboardWillHideNotification' was introduced in Swift 4.2
    public class let keyboardWillHideNotification: NSNotification.Name
                     ^
/Users/Looper/Desktop/dialog/demo/platforms/ios/Pods/CFAlertViewController/CFAlertViewController/CFAlertViewController.swift:363:133: error: 'textDidBeginEditingNotification' has been renamed to 'NSNotification.Name.UITextFieldTextDidBeginEditing'
        NotificationCenter.default.addObserver(self, selector: #selector(textViewOrTextFieldDidBeginEditing(_:)), name: UITextField.textDidBeginEditingNotification, object: nil)
                                                                                                                                    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
                                                                                                                                    NSNotification.Name.UITextFieldTextDidBeginEditing
UIKit.UITextField:3:22: note: 'textDidBeginEditingNotification' was introduced in Swift 4.2
    public class let textDidBeginEditingNotification: NSNotification.Name
                     ^
/Users/Looper/Desktop/dialog/demo/platforms/ios/Pods/CFAlertViewController/CFAlertViewController/CFAlertViewController.swift:364:132: error: 'textDidBeginEditingNotification' has been renamed to 'NSNotification.Name.UITextViewTextDidBeginEditing'
        NotificationCenter.default.addObserver(self, selector: #selector(textViewOrTextFieldDidBeginEditing(_:)), name: UITextView.textDidBeginEditingNotification, object: nil)
                                                                                                                                   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
                                                                                                                                   NSNotification.Name.UITextViewTextDidBeginEditing
UIKit.UITextView:3:22: note: 'textDidBeginEditingNotification' was introduced in Swift 4.2
    public class let textDidBeginEditingNotification: NSNotification.Name
                     ^
/Users/Looper/Desktop/dialog/demo/platforms/ios/Pods/CFAlertViewController/CFAlertViewController/CFAlertViewController.swift:607:46: error: 'keyboardFrameEndUserInfoKey' has been renamed to 'UIKeyboardFrameEndUserInfoKey'
            if let kbRect = info[UIResponder.keyboardFrameEndUserInfoKey] as? CGRect {
                                             ^~~~~~~~~~~~~~~~~~~~~~~~~~~
                                             UIKeyboardFrameEndUserInfoKey
UIKit.UIResponder:15:22: note: 'keyboardFrameEndUserInfoKey' was introduced in Swift 4.2
    public class let keyboardFrameEndUserInfoKey: String
                     ^
/Users/Looper/Desktop/dialog/demo/platforms/ios/Pods/CFAlertViewController/CFAlertViewController/CFAlertViewController.swift:783:28: error: 'automaticDimension' has been renamed to 'UITableViewAutomaticDimension'
        return UITableView.automaticDimension
                           ^~~~~~~~~~~~~~~~~~
                           UITableViewAutomaticDimension
UIKit.UITableView:64:22: note: 'automaticDimension' was introduced in Swift 4.2
    public class let automaticDimension: CGFloat
                     ^
/Users/Looper/Desktop/dialog/demo/platforms/ios/Pods/CFAlertViewController/CFAlertViewController/CFAlertViewController.swift:787:28: error: 'automaticDimension' has been renamed to 'UITableViewAutomaticDimension'
        return UITableView.automaticDimension
                           ^~~~~~~~~~~~~~~~~~
                           UITableViewAutomaticDimension
UIKit.UITableView:64:22: note: 'automaticDimension' was introduced in Swift 4.2
    public class let automaticDimension: CGFloat
                     ^
Command CompileSwift failed with a nonzero exit code
Command CompileSwift failed with a nonzero exit code
Command CompileSwift failed with a nonzero exit code
Command CompileSwift failed with a nonzero exit code
/Users/Looper/Desktop/dialog/demo/platforms/ios/Pods/CFAlertViewController/CFAlertViewController/CFAlertViewController.swift:359:115: error: 'keyboardWillShowNotification' has been renamed to 'NSNotification.Name.UIKeyboardWillShow'
        NotificationCenter.default.addObserver(self, selector: #selector(keyboardWillShow(_:)), name: UIResponder.keyboardWillShowNotification, object: nil)
                                                                                                                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
                                                                                                                  NSNotification.Name.UIKeyboardWillShow
UIKit.UIResponder:3:22: note: 'keyboardWillShowNotification' was introduced in Swift 4.2
    public class let keyboardWillShowNotification: NSNotification.Name
                     ^
/Users/Looper/Desktop/dialog/demo/platforms/ios/Pods/CFAlertViewController/CFAlertViewController/CFAlertViewController.swift:360:115: error: 'keyboardWillHideNotification' has been renamed to 'NSNotification.Name.UIKeyboardWillHide'
        NotificationCenter.default.addObserver(self, selector: #selector(keyboardWillHide(_:)), name: UIResponder.keyboardWillHideNotification, object: nil)
                                                                                                                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
                                                                                                                  NSNotification.Name.UIKeyboardWillHide
UIKit.UIResponder:7:22: note: 'keyboardWillHideNotification' was introduced in Swift 4.2
    public class let keyboardWillHideNotification: NSNotification.Name
                     ^
/Users/Looper/Desktop/dialog/demo/platforms/ios/Pods/CFAlertViewController/CFAlertViewController/CFAlertViewController.swift:363:133: error: 'textDidBeginEditingNotification' has been renamed to 'NSNotification.Name.UITextFieldTextDidBeginEditing'
        NotificationCenter.default.addObserver(self, selector: #selector(textViewOrTextFieldDidBeginEditing(_:)), name: UITextField.textDidBeginEditingNotification, object: nil)
                                                                                                                                    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
                                                                                                                                    NSNotification.Name.UITextFieldTextDidBeginEditing
UIKit.UITextField:3:22: note: 'textDidBeginEditingNotification' was introduced in Swift 4.2
    public class let textDidBeginEditingNotification: NSNotification.Name
                     ^
/Users/Looper/Desktop/dialog/demo/platforms/ios/Pods/CFAlertViewController/CFAlertViewController/CFAlertViewController.swift:364:132: error: 'textDidBeginEditingNotification' has been renamed to 'NSNotification.Name.UITextViewTextDidBeginEditing'
        NotificationCenter.default.addObserver(self, selector: #selector(textViewOrTextFieldDidBeginEditing(_:)), name: UITextView.textDidBeginEditingNotification, object: nil)
                                                                                                                                   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
                                                                                                                                   NSNotification.Name.UITextViewTextDidBeginEditing
UIKit.UITextView:3:22: note: 'textDidBeginEditingNotification' was introduced in Swift 4.2
    public class let textDidBeginEditingNotification: NSNotification.Name
                     ^
/Users/Looper/Desktop/dialog/demo/platforms/ios/Pods/CFAlertViewController/CFAlertViewController/CFAlertViewController.swift:607:46: error: 'keyboardFrameEndUserInfoKey' has been renamed to 'UIKeyboardFrameEndUserInfoKey'
            if let kbRect = info[UIResponder.keyboardFrameEndUserInfoKey] as? CGRect {
                                             ^~~~~~~~~~~~~~~~~~~~~~~~~~~
                                             UIKeyboardFrameEndUserInfoKey
UIKit.UIResponder:15:22: note: 'keyboardFrameEndUserInfoKey' was introduced in Swift 4.2
    public class let keyboardFrameEndUserInfoKey: String
                     ^
/Users/Looper/Desktop/dialog/demo/platforms/ios/Pods/CFAlertViewController/CFAlertViewController/CFAlertViewController.swift:783:28: error: 'automaticDimension' has been renamed to 'UITableViewAutomaticDimension'
        return UITableView.automaticDimension
                           ^~~~~~~~~~~~~~~~~~
                           UITableViewAutomaticDimension
UIKit.UITableView:64:22: note: 'automaticDimension' was introduced in Swift 4.2
    public class let automaticDimension: CGFloat
                     ^
/Users/Looper/Desktop/dialog/demo/platforms/ios/Pods/CFAlertViewController/CFAlertViewController/CFAlertViewController.swift:787:28: error: 'automaticDimension' has been renamed to 'UITableViewAutomaticDimension'
        return UITableView.automaticDimension
                           ^~~~~~~~~~~~~~~~~~
                           UITableViewAutomaticDimension
UIKit.UITableView:64:22: note: 'automaticDimension' was introduced in Swift 4.2
    public class let automaticDimension: CGFloat
                     ^
note: Using new build systemnote: Planning buildnote: Constructing build description
** BUILD FAILED **

Support and comparability with NativeScript 6

Support and comparability with NativeScript version 6, in other words, support for AndroidX, webpack workflow, and NS6 stack (i.e. `tns-core-modules 6, tns-android 6, dev webpack 6, etc.etc)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.