Skip to content

Feature/password code type props#29

Merged
swalker326 merged 3 commits intokagii-dev:masterfrom
shpaw415:feature/passwordUI-code-type-props
Apr 1, 2026
Merged

Feature/password code type props#29
swalker326 merged 3 commits intokagii-dev:masterfrom
shpaw415:feature/passwordUI-code-type-props

Conversation

@shpaw415
Copy link
Copy Markdown

This PR introduce the Password Code type props in the sendCode callback

Problem it solves : the callback unaware of the type of action.

Usecase : sending a email to a user that can be modified depending on the action type ( register or change )

// Before
issuer({
    providers: {
      password: PasswordUI({
        sendCode(email: string, code: string) {
            // send code to user
        },
      }),
    }
})

// Now
issuer({
    providers: {
      password: PasswordUI({
        sendCode(email: string, code: string, type: "register" | "change") {
            // send code to user aware of the action
        },
      }),
    }
})

This PR introduces regression proof test and proof-of-concept test as well.

@swalker326 swalker326 merged commit c0de6fe into kagii-dev:master Apr 1, 2026
2 checks passed
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