@orangecheck/auth-client 2.5.0 → 2.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.mts CHANGED
@@ -98,7 +98,7 @@ declare const OcAddressInput: React.ForwardRefExoticComponent<OcAddressInputProp
98
98
  interface OcSignInProps {
99
99
  audience: string;
100
100
  returnTo?: string;
101
- onSuccess?: (account: OcAccount) => void;
101
+ onSuccess?: (account: OcAccount, token?: string) => void;
102
102
  resolveReturnTo?: (account: OcAccount) => string | Promise<string>;
103
103
  authOrigin?: string;
104
104
  initialPath?: 'wallet' | 'email';
@@ -106,9 +106,25 @@ interface OcSignInProps {
106
106
  wallet?: boolean;
107
107
  email?: boolean;
108
108
  };
109
+ linkPrompt?: boolean;
109
110
  className?: string;
110
111
  }
111
- declare function OcSignIn({ audience, returnTo, onSuccess, resolveReturnTo, authOrigin, initialPath, paths, className, }: OcSignInProps): React.ReactElement;
112
+ declare function OcSignIn({ audience, returnTo, onSuccess, resolveReturnTo, linkPrompt, authOrigin, initialPath, paths, className, }: OcSignInProps): React.ReactElement;
113
+
114
+ interface OcLinkedIdentity {
115
+ id: string;
116
+ kind: 'email' | 'btc';
117
+ value: string | null;
118
+ verified_at: string | null;
119
+ verification_method: 'email-otp' | 'bip322' | null;
120
+ is_primary: boolean;
121
+ }
122
+ interface OcLinkedIdentitiesProps {
123
+ authOrigin?: string;
124
+ className?: string;
125
+ onChange?: () => void;
126
+ }
127
+ declare function OcLinkedIdentities({ authOrigin, className, onChange, }: OcLinkedIdentitiesProps): React.ReactElement;
112
128
 
113
129
  interface WebAuthnCredentialPublic {
114
130
  id: string;
@@ -192,4 +208,4 @@ declare function handleSudoRequired(body: {
192
208
  returnTo?: string;
193
209
  }): boolean;
194
210
 
195
- export { DEFAULT_CONFIG, type OcAccount, OcAccountChip, type OcAccountChipProps, OcAccountPill, type OcAccountPillProps, OcAddressInput, type OcAddressInputProps, type OcAuthConfig, OcSessionProvider, type OcSessionState, type OcSessionStatus, OcSignIn, OcSignInButton, type OcSignInButtonProps, type OcSignInProps, type RedirectToSudoArgs, type UseOcAddressSuggestionOptions, type UseOcAddressSuggestionReturn, type UseStepUpAuthReturn, type UseWebAuthnListReturn, type UseWebAuthnRegisterReturn, type WebAuthnAssertionStatus, type WebAuthnCredentialPublic, type WebAuthnListStatus, type WebAuthnRegisterResult, type WebAuthnRegisterStatus, type WebAuthnRemoveResult, type WebAuthnRenameResult, type WebAuthnStepUpResult, buildSignInUrl, handleSudoRequired, redirectToSudo, useOcAddressSuggestion, useOcSession, useOptionalOcSession, useStepUpAuth, useWebAuthnList, useWebAuthnRegister };
211
+ export { DEFAULT_CONFIG, type OcAccount, OcAccountChip, type OcAccountChipProps, OcAccountPill, type OcAccountPillProps, OcAddressInput, type OcAddressInputProps, type OcAuthConfig, OcLinkedIdentities, type OcLinkedIdentitiesProps, type OcLinkedIdentity, OcSessionProvider, type OcSessionState, type OcSessionStatus, OcSignIn, OcSignInButton, type OcSignInButtonProps, type OcSignInProps, type RedirectToSudoArgs, type UseOcAddressSuggestionOptions, type UseOcAddressSuggestionReturn, type UseStepUpAuthReturn, type UseWebAuthnListReturn, type UseWebAuthnRegisterReturn, type WebAuthnAssertionStatus, type WebAuthnCredentialPublic, type WebAuthnListStatus, type WebAuthnRegisterResult, type WebAuthnRegisterStatus, type WebAuthnRemoveResult, type WebAuthnRenameResult, type WebAuthnStepUpResult, buildSignInUrl, handleSudoRequired, redirectToSudo, useOcAddressSuggestion, useOcSession, useOptionalOcSession, useStepUpAuth, useWebAuthnList, useWebAuthnRegister };
package/dist/index.d.ts CHANGED
@@ -98,7 +98,7 @@ declare const OcAddressInput: React.ForwardRefExoticComponent<OcAddressInputProp
98
98
  interface OcSignInProps {
99
99
  audience: string;
100
100
  returnTo?: string;
101
- onSuccess?: (account: OcAccount) => void;
101
+ onSuccess?: (account: OcAccount, token?: string) => void;
102
102
  resolveReturnTo?: (account: OcAccount) => string | Promise<string>;
103
103
  authOrigin?: string;
104
104
  initialPath?: 'wallet' | 'email';
@@ -106,9 +106,25 @@ interface OcSignInProps {
106
106
  wallet?: boolean;
107
107
  email?: boolean;
108
108
  };
109
+ linkPrompt?: boolean;
109
110
  className?: string;
110
111
  }
111
- declare function OcSignIn({ audience, returnTo, onSuccess, resolveReturnTo, authOrigin, initialPath, paths, className, }: OcSignInProps): React.ReactElement;
112
+ declare function OcSignIn({ audience, returnTo, onSuccess, resolveReturnTo, linkPrompt, authOrigin, initialPath, paths, className, }: OcSignInProps): React.ReactElement;
113
+
114
+ interface OcLinkedIdentity {
115
+ id: string;
116
+ kind: 'email' | 'btc';
117
+ value: string | null;
118
+ verified_at: string | null;
119
+ verification_method: 'email-otp' | 'bip322' | null;
120
+ is_primary: boolean;
121
+ }
122
+ interface OcLinkedIdentitiesProps {
123
+ authOrigin?: string;
124
+ className?: string;
125
+ onChange?: () => void;
126
+ }
127
+ declare function OcLinkedIdentities({ authOrigin, className, onChange, }: OcLinkedIdentitiesProps): React.ReactElement;
112
128
 
113
129
  interface WebAuthnCredentialPublic {
114
130
  id: string;
@@ -192,4 +208,4 @@ declare function handleSudoRequired(body: {
192
208
  returnTo?: string;
193
209
  }): boolean;
194
210
 
195
- export { DEFAULT_CONFIG, type OcAccount, OcAccountChip, type OcAccountChipProps, OcAccountPill, type OcAccountPillProps, OcAddressInput, type OcAddressInputProps, type OcAuthConfig, OcSessionProvider, type OcSessionState, type OcSessionStatus, OcSignIn, OcSignInButton, type OcSignInButtonProps, type OcSignInProps, type RedirectToSudoArgs, type UseOcAddressSuggestionOptions, type UseOcAddressSuggestionReturn, type UseStepUpAuthReturn, type UseWebAuthnListReturn, type UseWebAuthnRegisterReturn, type WebAuthnAssertionStatus, type WebAuthnCredentialPublic, type WebAuthnListStatus, type WebAuthnRegisterResult, type WebAuthnRegisterStatus, type WebAuthnRemoveResult, type WebAuthnRenameResult, type WebAuthnStepUpResult, buildSignInUrl, handleSudoRequired, redirectToSudo, useOcAddressSuggestion, useOcSession, useOptionalOcSession, useStepUpAuth, useWebAuthnList, useWebAuthnRegister };
211
+ export { DEFAULT_CONFIG, type OcAccount, OcAccountChip, type OcAccountChipProps, OcAccountPill, type OcAccountPillProps, OcAddressInput, type OcAddressInputProps, type OcAuthConfig, OcLinkedIdentities, type OcLinkedIdentitiesProps, type OcLinkedIdentity, OcSessionProvider, type OcSessionState, type OcSessionStatus, OcSignIn, OcSignInButton, type OcSignInButtonProps, type OcSignInProps, type RedirectToSudoArgs, type UseOcAddressSuggestionOptions, type UseOcAddressSuggestionReturn, type UseStepUpAuthReturn, type UseWebAuthnListReturn, type UseWebAuthnRegisterReturn, type WebAuthnAssertionStatus, type WebAuthnCredentialPublic, type WebAuthnListStatus, type WebAuthnRegisterResult, type WebAuthnRegisterStatus, type WebAuthnRemoveResult, type WebAuthnRenameResult, type WebAuthnStepUpResult, buildSignInUrl, handleSudoRequired, redirectToSudo, useOcAddressSuggestion, useOcSession, useOptionalOcSession, useStepUpAuth, useWebAuthnList, useWebAuthnRegister };