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

Fix Button Interface Typings #774

Merged
merged 6 commits into from
Dec 14, 2017
Merged

Fix Button Interface Typings #774

merged 6 commits into from
Dec 14, 2017

Conversation

alex-osman
Copy link
Contributor

@alex-osman alex-osman commented Nov 20, 2017

Issue

Fixes #763: Button typings were not full

Solution

Added typings for all valid combinations.

Allows for variations of the following:

swal({
  buttons: [true, true],                              // booleans
  buttons: ['Stay on this page', 'Continue'],         // strings
  buttons: [true, 'Delete'],                          // both

  buttons: {                                          // ButtonList
    cancel: true,                                     // boolean
    confirm: {                                        // ButtonOptions
      ....
    }
  }
})

@alex-osman alex-osman changed the title Fix typings Fix typings [WIP] Nov 20, 2017
@alex-osman alex-osman closed this Nov 20, 2017
@alex-osman alex-osman reopened this Nov 20, 2017
@alex-osman alex-osman changed the title Fix typings [WIP] Fix Button Interface Typings Nov 20, 2017
@Klerith
Copy link

Klerith commented Dec 4, 2017

Please made this changes I am getting the same issue on TypeScript
screen shot 2017-12-04 at 1 43 49 pm

@alex-osman
Copy link
Contributor Author

bump @t4t5

@t4t5 t4t5 merged commit ea032a7 into t4t5:master Dec 14, 2017
@t4t5
Copy link
Owner

t4t5 commented Dec 14, 2017

Thx!

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.

3 participants