davecoffin / nativescript-modal-datetimepicker

Apache License 2.0
59 stars 36 forks source link

Consider removing the toast showing Min/Max time #75

Open fpaaske opened 3 years ago

fpaaske commented 3 years ago

This is not really a bug, but more a suggestion/change request.

I'm currently using version 1.2.4 of this plugin in a NativeScript 6 app. When I'm opening a time picker dialog with max or min time set in PickerOptions, a toast is shown with this information

image

Unfortunately, this text is not translatable and it looks weird to show this one message in English when the rest of the app is in a different language.

Please consider removing the toast.

Edit: I also see that 1.2.4 is not in any commit in this repo? Where is that release coming from?

shiv19 commented 3 years ago

Good suggestion! We can add an option to turn off the toast and also to configure the text on it.

fpaaske commented 3 years ago

Yes, that sounds great! Hopefully it can be done on both version 1.x and 2.x :)

fpaaske commented 3 years ago

@shiv19 @davecoffin did you get time to look at this?

syahnur197 commented 3 years ago

quick and dirty way is to comment out line 120-122 in node_modules/nativescript-modal-datetimepicker/modal-datetimepicker.android.js in your node_modules

// if (toastMsg !== "") {
//    android.widget.Toast.makeText(Application.android.foregroundActivity, toastMsg, android.widget.Toast.LENGTH_LONG).show();
// }