Spice up your native android Toast library and make new cool animated Toasts in Android Studio. This custom made library helps you to design cool animated Toasts easily with minimal lines of code.
Add this in your root build.gradle file (not your module build.gradle file):
allprojects {
repositories {
...
maven { url "https://jitpack.io" }
}
}
dependencies {
implementation 'com.github.saksham1211:AnimatedToast:1.0.1'
}
Each method always returns a Toast object, so you can customize the Toast much more.
To display a Toast:-
(This is the syntax)
ToastAnim.makeText(context, "message", duration,animation,
background).show();
ToastAnim.makeText(MainActivity.this, "FAIL", ToastAnim.LENGTH_LONG, R.raw.error,
R.drawable.fail_shape).show();
(Success Toast) (Failure Toast)
Please fork this repository and contribute back using pull requests.
Any contributions, large or small, major features, bug fixes, are welcomed and appreciated but will be thoroughly reviewed .
Made with ❤️ for the community