We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
styling > verticalPadding should adjust toast vertical padding. When make it 0, it should be 0.
Toast vertical padding not becoming 0.
OnePlus 7T
Android 10
deviceready
window.onerror
Make styling > verticalPadding 0, see, still you will see some padding. I have checked in Android version 6, it is working fine.
this.toast.showWithOptions({ message, duration: 2000, position: 'bottom', addPixelsY: -160, styling: { opacity: 0.75, cornerRadius: 16, horizontalPadding: 10, verticalPadding: 5 } }).subscribe(() => {});
The text was updated successfully, but these errors were encountered:
GradientDrawable shape = new GradientDrawable(); shape.setCornerRadius(cornerRadius); shape.setAlpha((int)(opacity * 255)); // 0-255, where 0 is an invisible background shape.setColor(Color.parseColor(backgroundColor)); // toast.getView().setBackground(shape); toast.getView().setBackgroundColor(Color.TRANSPARENT); final TextView toastTextView; toastTextView = (TextView) toast.getView().findViewById(android.R.id.message); toastTextView.setTextColor(Color.parseColor(textColor)); if (textSize > -1) { toastTextView.setTextSize(textSize.floatValue()); } toastTextView.setBackground(shape); toastTextView.setPadding(horizontalPadding, verticalPadding, horizontalPadding, verticalPadding); // toast.getView().setPadding(horizontalPadding, verticalPadding, horizontalPadding, verticalPadding); // this gives the toast a very subtle shadow on newer devices if (Build.VERSION.SDK_INT >= 21) { toastTextView.setElevation(6); // toast.getView().setElevation(6); }
Sorry, something went wrong.
No branches or pull requests
Expected behaviour
styling > verticalPadding should adjust toast vertical padding. When make it 0, it should be 0.
Actual behaviour
Toast vertical padding not becoming 0.
I'm seeing this behaviour on
Hardware models
OnePlus 7T
OS versions
Android 10
I'm not a dummy, so I've checked these
deviceready
to fire.window.onerror
catches nothing).So how can we reproduce this?
Make styling > verticalPadding 0, see, still you will see some padding. I have checked in Android version 6, it is working fine.
Sweet ⭐⭐⭐⭐
this.toast.showWithOptions({ message, duration: 2000, position: 'bottom', addPixelsY: -160, styling: { opacity: 0.75, cornerRadius: 16, horizontalPadding: 10, verticalPadding: 5 } }).subscribe(() => {});
The text was updated successfully, but these errors were encountered: