An input
component for authenticating user with passkey.
It will act as an standard input element if there is no passkey registered yet.
Properties
Name | Format | required | default | Description |
---|
placeholder | text | no | ”enter your email” | The input field placeholder. |
enterkeyhint | text | no | ”Send” | Virtual keyboard action label. |
state | State | no | undefined | The component’s internal state. |
value | text | no | "" | The component’s value. |
lifetime | number | no | ”86400” (24h) | The session maximum duration in seconds |
idletimeout | number | no | lifetime | The session inactivity timeout in seconds |
Methods
Name | Description |
---|
getSession() | Returns the current session (promise). Null if user is not authenticated. |
Custom Events
Name | Description | Type |
---|
np:login | Session created. | Session |
np:error | Something went wrong. | NoPwdError |
The np:login
custom event detail is defined as follow:
The np:error
custom event detail inherites from the NoPwdError
.
There are 6 types of error:
Slots
Name | Description |
---|
(default) | The input’s label. |
busy | waiting or processing authentication. |
authenticated | The user has been authenticated. |
error | An error occured. |
Usage:
Parts
Name | Description |
---|
button | The component’s button wrapper. |
Usage: