UI kit reference
zidane-ui/ auth
import { … } from 'zidane-ui/auth'ui/src/auth/index.ts
Functions#
useSignInFunction#
zidane-ui/auth: useSignIn, which runs a host's browser sign-in for a
component and follows it for BrowserSignIn. The SignInFlow a host
returns is zidane-ui/auth/headless.
function useSignIn(onDone?: (account?: string) => void): SignInHandleParameters
| Name | Type | Description |
|---|---|---|
| onDone? | (account?: string) => void | Called once when a sign-in ends signed in. |
Returns
Interfaces#
SignInHandleInterface#
A sign-in a component runs.
interface SignInHandleProperties
| Name | Type | Description |
|---|---|---|
| cancel | () => void | Stops the sign-in and forgets it. |
| start | (begin: () => SignInFlow) => void | Starts a sign-in, replacing one in progress. |
| state | OnboardingSignInState | null | Where the sign-in is. It is |
| submit? | (text: string) => void | Answers a question or passes a pasted code. Absent: the flow takes no input. |