This repository was archived by the owner on Sep 15, 2021. It is now read-only.
Adding support for toast.showWithOptions#1273
Open
brickpop wants to merge 1 commit intoionic-team:masterfrom
Open
Adding support for toast.showWithOptions#1273brickpop wants to merge 1 commit intoionic-team:masterfrom
brickpop wants to merge 1 commit intoionic-team:masterfrom
Conversation
Version 2.4 of cordovaplugin-x-toast allows to provide styling for the toast messages.
window.plugins.toast.showWithOptions({
message: "hey there",
duration: "short", // 2000 ms
position: "bottom",
styling: {
opacity: 0.75, // 0.0 (transparent) to 1.0 (opaque). Default 0.8
backgroundColor: '#FF0000', // make sure you use #RRGGBB. Default #333333
textColor: '#FFFF00', // Ditto. Default #FFFFFF
textSize: 20.5, // Default is approx. 13.
cornerRadius: 16, // minimum is 0 (square). iOS default 20, Android default 100
horizontalPadding: 20, // iOS default 16, Android default 50
verticalPadding: 16 // iOS default 12, Android default 30
}
});
Also, the cordova plugin name is updated and some control code is added to prevent runtime errors if the plugin is not yet installed.
Thank you!
Contributor
|
This should be put in dev-next branch; which I believe already has this PR. |
Contributor
|
I love some of these changes; so if you target the dev-next branch and you pull the latest from it to do your additions off of, I'd be happy to add it. |
gortok
suggested changes
Sep 21, 2016
Contributor
gortok
left a comment
There was a problem hiding this comment.
Please base this off of dev-next.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Version 2.4 of cordovaplugin-x-toast allows to provide styling for the toast messages.
Also, the cordova plugin name is updated and some control code is added to prevent runtime errors if the plugin is not yet installed.
Thank you!