Skip to content
New issue

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

Allow to define custom dialog titles using javascript API #15

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

andreyliventsev
Copy link

I would like to customize and localize dialog messages for .save and .verify methods.
So this changes allow to provide second argument as string (as in previous versions) or object with custom titles:

/**

  • @param {(string|Object)} options - string with password or object with properties: [password (requried), dialogTitle, dialogMessage, dialogHint, dialogCancel, dialogStatusSuccess, dialogStatusNotRecognized]
    */
    save: function(key, options, successCallback, errorCallback)

/**

  • @param {(string|Object)} options - string with dialog message or object with properties: [password (requried), dialogTitle, dialogMessage, dialogHint, dialogCancel, dialogStatusSuccess, dialogStatusNotRecognized]
    */
    verify: function(key,options,successCallback, errorCallback)

If some properties are not defined then default messages will be using.
Fully compatible with previous version

Second argument of .save and .verify functions could be string (as in previous version) or object contains custom titles
Fully compatible with previous version
@Armanio
Copy link

Armanio commented Apr 4, 2017

@andreyliventsev great job!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants