@cedros/login-react 0.0.12 → 0.0.13
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/README.md +68 -0
- package/dist/AdminDepositList-Cx0xRwES.js +305 -0
- package/dist/AdminDepositList-Cx0xRwES.js.map +1 -0
- package/dist/AdminDepositList-UEcyRZkA.cjs +1 -0
- package/dist/AdminDepositList-UEcyRZkA.cjs.map +1 -0
- package/dist/AdminUserDetail-BzEIdNJh.cjs +1 -0
- package/dist/AdminUserDetail-BzEIdNJh.cjs.map +1 -0
- package/dist/AdminUserDetail-DHFDzY8B.js +1195 -0
- package/dist/AdminUserDetail-DHFDzY8B.js.map +1 -0
- package/dist/AdminWithdrawalHistory-0yxtMh6q.cjs +1 -0
- package/dist/AdminWithdrawalHistory-0yxtMh6q.cjs.map +1 -0
- package/dist/AdminWithdrawalHistory-BGjfrIe3.js +904 -0
- package/dist/AdminWithdrawalHistory-BGjfrIe3.js.map +1 -0
- package/dist/AuthenticationSettings-5Vi7Ib_A.cjs +1 -0
- package/dist/AuthenticationSettings-5Vi7Ib_A.cjs.map +1 -0
- package/dist/AuthenticationSettings-BPAh1my6.cjs +1 -0
- package/dist/AuthenticationSettings-BPAh1my6.cjs.map +1 -0
- package/dist/AuthenticationSettings-CJg8CJY9.js +9 -0
- package/dist/AuthenticationSettings-CJg8CJY9.js.map +1 -0
- package/dist/AuthenticationSettings-CR_i6TTS.js +495 -0
- package/dist/AuthenticationSettings-CR_i6TTS.js.map +1 -0
- package/dist/AutosaveStatus-CYkC2aI_.cjs +1 -0
- package/dist/AutosaveStatus-CYkC2aI_.cjs.map +1 -0
- package/dist/AutosaveStatus-N4uNS6-2.js +1497 -0
- package/dist/AutosaveStatus-N4uNS6-2.js.map +1 -0
- package/dist/CreditSystemSettings-BnAOK_tT.cjs +1 -0
- package/dist/CreditSystemSettings-BnAOK_tT.cjs.map +1 -0
- package/dist/CreditSystemSettings-CIf_SfJq.js +210 -0
- package/dist/CreditSystemSettings-CIf_SfJq.js.map +1 -0
- package/dist/CreditSystemSettings-CePYGgev.js +9 -0
- package/dist/CreditSystemSettings-CePYGgev.js.map +1 -0
- package/dist/CreditSystemSettings-Ck5WIMp3.cjs +1 -0
- package/dist/CreditSystemSettings-Ck5WIMp3.cjs.map +1 -0
- package/dist/{DepositsSection-0Hqr0yDm.js → DepositsSection-DA89uR9A.js} +5 -5
- package/dist/{DepositsSection-0Hqr0yDm.js.map → DepositsSection-DA89uR9A.js.map} +1 -1
- package/dist/DepositsSection-i6XdhLNs.cjs +1 -0
- package/dist/{DepositsSection-CGKCzM-H.cjs.map → DepositsSection-i6XdhLNs.cjs.map} +1 -1
- package/dist/EmailRegisterForm-BrDL3BZy.js +927 -0
- package/dist/EmailRegisterForm-BrDL3BZy.js.map +1 -0
- package/dist/EmailRegisterForm-CxktR-4J.cjs +1 -0
- package/dist/EmailRegisterForm-CxktR-4J.cjs.map +1 -0
- package/dist/EmailSettings-B8xwgd6_.cjs +1 -0
- package/dist/EmailSettings-B8xwgd6_.cjs.map +1 -0
- package/dist/{AuthenticationSettings-BSoIQ58T.js → EmailSettings-Bna7Z53E.js} +3 -3
- package/dist/EmailSettings-Bna7Z53E.js.map +1 -0
- package/dist/EmailSettings-DZywTTRq.cjs +1 -0
- package/dist/EmailSettings-DZywTTRq.cjs.map +1 -0
- package/dist/EmailSettings-DbMDfVaM.js +17 -0
- package/dist/EmailSettings-DbMDfVaM.js.map +1 -0
- package/dist/{EmbeddedWalletSettings-iVf_3pn3.js → EmbeddedWalletSettings-ANbhj3Lt.js} +3 -3
- package/dist/EmbeddedWalletSettings-ANbhj3Lt.js.map +1 -0
- package/dist/EmbeddedWalletSettings-BEztqO19.js +79 -0
- package/dist/EmbeddedWalletSettings-BEztqO19.js.map +1 -0
- package/dist/EmbeddedWalletSettings-D6M7pwgk.cjs +1 -0
- package/dist/EmbeddedWalletSettings-D6M7pwgk.cjs.map +1 -0
- package/dist/EmbeddedWalletSettings-DivEPn39.cjs +1 -0
- package/dist/EmbeddedWalletSettings-DivEPn39.cjs.map +1 -0
- package/dist/ErrorMessage-CHbYbVi2.cjs +1 -0
- package/dist/ErrorMessage-CHbYbVi2.cjs.map +1 -0
- package/dist/ErrorMessage-CcEK0pYO.js +64 -0
- package/dist/ErrorMessage-CcEK0pYO.js.map +1 -0
- package/dist/{GoogleLoginButton-BzHr545L.js → GoogleLoginButton-B3uRMJ_n.js} +4 -3
- package/dist/{GoogleLoginButton-BzHr545L.js.map → GoogleLoginButton-B3uRMJ_n.js.map} +1 -1
- package/dist/GoogleLoginButton-BydKswn4.cjs +1 -0
- package/dist/{GoogleLoginButton-DoAdOqb3.cjs.map → GoogleLoginButton-BydKswn4.cjs.map} +1 -1
- package/dist/LoadingSpinner-6vml-zwr.js +79 -0
- package/dist/LoadingSpinner-6vml-zwr.js.map +1 -0
- package/dist/LoadingSpinner-d6sSxgQN.cjs +1 -0
- package/dist/LoadingSpinner-d6sSxgQN.cjs.map +1 -0
- package/dist/PermissionsSection-BGaj_sI7.js +1026 -0
- package/dist/PermissionsSection-BGaj_sI7.js.map +1 -0
- package/dist/PermissionsSection-CKXXDfqi.cjs +1 -0
- package/dist/PermissionsSection-CKXXDfqi.cjs.map +1 -0
- package/dist/ServerSettings-B2RKhJtZ.js +84 -0
- package/dist/ServerSettings-B2RKhJtZ.js.map +1 -0
- package/dist/ServerSettings-BZXlm1BX.cjs +1 -0
- package/dist/ServerSettings-BZXlm1BX.cjs.map +1 -0
- package/dist/{ServerSettings-C_osdbiX.js → ServerSettings-Bqm4-bt2.js} +3 -3
- package/dist/ServerSettings-Bqm4-bt2.js.map +1 -0
- package/dist/ServerSettings-DZUKo6By.cjs +1 -0
- package/dist/ServerSettings-DZUKo6By.cjs.map +1 -0
- package/dist/SettingsPageLayout-COSYLMu7.cjs +1 -0
- package/dist/SettingsPageLayout-COSYLMu7.cjs.map +1 -0
- package/dist/SettingsPageLayout-DpgNEkuu.js +50 -0
- package/dist/SettingsPageLayout-DpgNEkuu.js.map +1 -0
- package/dist/{SolanaLoginButton-C-CfZxAZ.js → SolanaLoginButton-C_u9OppS.js} +5 -4
- package/dist/{SolanaLoginButton-C-CfZxAZ.js.map → SolanaLoginButton-C_u9OppS.js.map} +1 -1
- package/dist/SolanaLoginButton-fAW7kRUu.cjs +1 -0
- package/dist/{SolanaLoginButton-CPzms0kf.cjs.map → SolanaLoginButton-fAW7kRUu.cjs.map} +1 -1
- package/dist/StatsBar-BX-hHtTq.js +66 -0
- package/dist/StatsBar-BX-hHtTq.js.map +1 -0
- package/dist/StatsBar-DTUZCwDD.cjs +1 -0
- package/dist/StatsBar-DTUZCwDD.cjs.map +1 -0
- package/dist/{TeamSection-Bjt72upx.js → TeamSection-CvrCoa9D.js} +27 -26
- package/dist/TeamSection-CvrCoa9D.js.map +1 -0
- package/dist/TeamSection-DlUD5kp5.cjs +1 -0
- package/dist/TeamSection-DlUD5kp5.cjs.map +1 -0
- package/dist/UsersSection-C2U8Tb7V.cjs +1 -0
- package/dist/{UsersSection-DU86czWP.cjs.map → UsersSection-C2U8Tb7V.cjs.map} +1 -1
- package/dist/{UsersSection-hAcyfSZk.js → UsersSection-Dbh9PTSA.js} +17 -15
- package/dist/{UsersSection-hAcyfSZk.js.map → UsersSection-Dbh9PTSA.js.map} +1 -1
- package/dist/WebhookSettings-BT5q6AZ8.js +17 -0
- package/dist/WebhookSettings-BT5q6AZ8.js.map +1 -0
- package/dist/WebhookSettings-BWl_wsvg.cjs +1 -0
- package/dist/WebhookSettings-BWl_wsvg.cjs.map +1 -0
- package/dist/WebhookSettings-DXNH5bal.cjs +1 -0
- package/dist/WebhookSettings-DXNH5bal.cjs.map +1 -0
- package/dist/{WebhookSettings-IyhyTFes.js → WebhookSettings-bUg2u_p0.js} +4 -4
- package/dist/WebhookSettings-bUg2u_p0.js.map +1 -0
- package/dist/WithdrawalsSection-BL_LOUq8.cjs +1 -0
- package/dist/{WithdrawalsSection-iZJBuZ7O.cjs.map → WithdrawalsSection-BL_LOUq8.cjs.map} +1 -1
- package/dist/WithdrawalsSection-CN-lLnqX.js +20 -0
- package/dist/{WithdrawalsSection-B1415d-G.js.map → WithdrawalsSection-CN-lLnqX.js.map} +1 -1
- package/dist/admin-only.cjs +1 -0
- package/dist/admin-only.cjs.map +1 -0
- package/dist/{admin/types.d.ts → admin-only.d.ts} +228 -167
- package/dist/admin-only.js +8 -0
- package/dist/admin-only.js.map +1 -0
- package/dist/apiClient-B2JxVPlH.js +216 -0
- package/dist/apiClient-B2JxVPlH.js.map +1 -0
- package/dist/apiClient-CTTKhsYb.cjs +1 -0
- package/dist/apiClient-CTTKhsYb.cjs.map +1 -0
- package/dist/assets/argon2Worker-Bi5TuQvD.js.map +1 -1
- package/dist/email-only.cjs +1 -1
- package/dist/email-only.d.ts +634 -16
- package/dist/email-only.js +16 -13
- package/dist/email-only.js.map +1 -1
- package/dist/google-only.cjs +1 -1
- package/dist/google-only.d.ts +543 -13
- package/dist/google-only.js +11 -8
- package/dist/google-only.js.map +1 -1
- package/dist/index.cjs +2061 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +5007 -144
- package/dist/index.js +13507 -116
- package/dist/index.js.map +1 -1
- package/dist/login-react.css +1 -1
- package/dist/plugin-5qRh-YhX.js +596 -0
- package/dist/plugin-5qRh-YhX.js.map +1 -0
- package/dist/plugin-BtYBW6JY.cjs +1 -0
- package/dist/plugin-BtYBW6JY.cjs.map +1 -0
- package/dist/sanitization-Bo_tn-L2.cjs +1 -0
- package/dist/sanitization-Bo_tn-L2.cjs.map +1 -0
- package/dist/sanitization-CQ-H1MSg.js +39 -0
- package/dist/sanitization-CQ-H1MSg.js.map +1 -0
- package/dist/shamir-AeLLfw0p.cjs +1 -0
- package/dist/shamir-AeLLfw0p.cjs.map +1 -0
- package/dist/{solanaKeypair-BlXol3nh.js → shamir-B0wConeK.js} +765 -757
- package/dist/shamir-B0wConeK.js.map +1 -0
- package/dist/silentWalletEnroll-B8pgdKZO.cjs +1 -0
- package/dist/silentWalletEnroll-B8pgdKZO.cjs.map +1 -0
- package/dist/silentWalletEnroll-DR2kPw7W.js +41 -0
- package/dist/silentWalletEnroll-DR2kPw7W.js.map +1 -0
- package/dist/solana-only.cjs +1 -1
- package/dist/solana-only.d.ts +594 -13
- package/dist/solana-only.js +12 -9
- package/dist/solana-only.js.map +1 -1
- package/dist/style.d.ts +1 -0
- package/dist/useAdminDeposits-BDY5KJ0-.js +151 -0
- package/dist/useAdminDeposits-BDY5KJ0-.js.map +1 -0
- package/dist/useAdminDeposits-Dvx3_UUE.cjs +1 -0
- package/dist/useAdminDeposits-Dvx3_UUE.cjs.map +1 -0
- package/dist/{ErrorMessage-DU2VBb85.js → useAuth-Bge6KaWN.js} +954 -1226
- package/dist/useAuth-Bge6KaWN.js.map +1 -0
- package/dist/useAuth-DhIDTLRd.cjs +1 -0
- package/dist/useAuth-DhIDTLRd.cjs.map +1 -0
- package/dist/useOrgs-Be3KH4ib.js +215 -0
- package/dist/useOrgs-Be3KH4ib.js.map +1 -0
- package/dist/useOrgs-CVbacmaQ.cjs +1 -0
- package/dist/useOrgs-CVbacmaQ.cjs.map +1 -0
- package/dist/useSystemSettings-D9Cr7ZTl.cjs +1 -0
- package/dist/useSystemSettings-D9Cr7ZTl.cjs.map +1 -0
- package/dist/useSystemSettings-DN5YqfNq.js +97 -0
- package/dist/useSystemSettings-DN5YqfNq.js.map +1 -0
- package/dist/{validation-BebL7hMF.js → validation-B8kMV3BL.js} +1 -1
- package/dist/{validation-BebL7hMF.js.map → validation-B8kMV3BL.js.map} +1 -1
- package/dist/{validation-BeXIfuHB.cjs → validation-BuGQrA-K.cjs} +1 -1
- package/dist/{validation-BeXIfuHB.cjs.map → validation-BuGQrA-K.cjs.map} +1 -1
- package/package.json +11 -1
- package/dist/AuthenticationSettings-BSoIQ58T.js.map +0 -1
- package/dist/AuthenticationSettings-CNmWEPFV.cjs +0 -1
- package/dist/AuthenticationSettings-CNmWEPFV.cjs.map +0 -1
- package/dist/CreditSystemSettings-BYxoFwaP.js +0 -9
- package/dist/CreditSystemSettings-BYxoFwaP.js.map +0 -1
- package/dist/CreditSystemSettings-D2fLorNx.cjs +0 -1
- package/dist/CreditSystemSettings-D2fLorNx.cjs.map +0 -1
- package/dist/DepositsSection-CGKCzM-H.cjs +0 -1
- package/dist/EmailRegisterForm-C0PStlj5.js +0 -961
- package/dist/EmailRegisterForm-C0PStlj5.js.map +0 -1
- package/dist/EmailRegisterForm-DaPLGws2.cjs +0 -1
- package/dist/EmailRegisterForm-DaPLGws2.cjs.map +0 -1
- package/dist/EmailSettings-CiLDwzNb.cjs +0 -1
- package/dist/EmailSettings-CiLDwzNb.cjs.map +0 -1
- package/dist/EmailSettings-DTjpO65J.js +0 -9
- package/dist/EmailSettings-DTjpO65J.js.map +0 -1
- package/dist/EmbeddedWalletSettings-CX7sYiPy.cjs +0 -1
- package/dist/EmbeddedWalletSettings-CX7sYiPy.cjs.map +0 -1
- package/dist/EmbeddedWalletSettings-iVf_3pn3.js.map +0 -1
- package/dist/ErrorMessage-BXHiYibN.cjs +0 -1
- package/dist/ErrorMessage-BXHiYibN.cjs.map +0 -1
- package/dist/ErrorMessage-DU2VBb85.js.map +0 -1
- package/dist/GoogleLoginButton-DoAdOqb3.cjs +0 -1
- package/dist/ServerSettings-C_osdbiX.js.map +0 -1
- package/dist/ServerSettings-HqSb_VDj.cjs +0 -1
- package/dist/ServerSettings-HqSb_VDj.cjs.map +0 -1
- package/dist/SolanaLoginButton-CPzms0kf.cjs +0 -1
- package/dist/TeamSection-Bjt72upx.js.map +0 -1
- package/dist/TeamSection-DZeWHkLd.cjs +0 -1
- package/dist/TeamSection-DZeWHkLd.cjs.map +0 -1
- package/dist/UsersSection-DU86czWP.cjs +0 -1
- package/dist/WebhookSettings-Br9bakAL.cjs +0 -1
- package/dist/WebhookSettings-Br9bakAL.cjs.map +0 -1
- package/dist/WebhookSettings-IyhyTFes.js.map +0 -1
- package/dist/WithdrawalsSection-B1415d-G.js +0 -20
- package/dist/WithdrawalsSection-iZJBuZ7O.cjs +0 -1
- package/dist/admin/AdminShell.d.ts +0 -38
- package/dist/admin/icons.d.ts +0 -2
- package/dist/admin/index.d.ts +0 -10
- package/dist/admin/plugin.d.ts +0 -3
- package/dist/admin/sections/AuthenticationSettings.d.ts +0 -3
- package/dist/admin/sections/CreditSystemSettings.d.ts +0 -3
- package/dist/admin/sections/DepositsSection.d.ts +0 -3
- package/dist/admin/sections/EmailSettings.d.ts +0 -3
- package/dist/admin/sections/EmbeddedWalletSettings.d.ts +0 -3
- package/dist/admin/sections/FeatureSettings.d.ts +0 -3
- package/dist/admin/sections/InvitesSection.d.ts +0 -3
- package/dist/admin/sections/MembersSection.d.ts +0 -3
- package/dist/admin/sections/ServerSettings.d.ts +0 -3
- package/dist/admin/sections/SettingsSections.d.ts +0 -7
- package/dist/admin/sections/TeamSection.d.ts +0 -3
- package/dist/admin/sections/UsersSection.d.ts +0 -3
- package/dist/admin/sections/WebhookSettings.d.ts +0 -3
- package/dist/admin/sections/WithdrawalsSection.d.ts +0 -3
- package/dist/components/LoginButton.d.ts +0 -23
- package/dist/components/LoginForm.d.ts +0 -9
- package/dist/components/LoginModal.d.ts +0 -9
- package/dist/components/admin/AdminUserDetail.d.ts +0 -23
- package/dist/components/admin/AdminUserList.d.ts +0 -21
- package/dist/components/admin/CedrosAdminDashboard.d.ts +0 -52
- package/dist/components/admin/PermissionsSection.d.ts +0 -7
- package/dist/components/admin/ProfileDropdown.d.ts +0 -34
- package/dist/components/admin/SetupWizard.d.ts +0 -30
- package/dist/components/admin/StatsBar.d.ts +0 -17
- package/dist/components/admin/SystemSettings.d.ts +0 -19
- package/dist/components/admin/settings/AuthenticationSettings.d.ts +0 -4
- package/dist/components/admin/settings/AutosaveStatus.d.ts +0 -6
- package/dist/components/admin/settings/CreditSystemSettings.d.ts +0 -6
- package/dist/components/admin/settings/EmailSettings.d.ts +0 -4
- package/dist/components/admin/settings/EmbeddedWalletSettings.d.ts +0 -4
- package/dist/components/admin/settings/FeatureSettings.d.ts +0 -4
- package/dist/components/admin/settings/MessagingSettings.d.ts +0 -4
- package/dist/components/admin/settings/SecuritySettings.d.ts +0 -4
- package/dist/components/admin/settings/ServerSettings.d.ts +0 -4
- package/dist/components/admin/settings/SettingsPageLayout.d.ts +0 -16
- package/dist/components/admin/settings/SsoProvidersSettings.d.ts +0 -4
- package/dist/components/admin/settings/WebhookSettings.d.ts +0 -4
- package/dist/components/admin/settings/index.d.ts +0 -31
- package/dist/components/admin/settings/settingsInputs.d.ts +0 -79
- package/dist/components/admin/settings/settingsMetadata.d.ts +0 -18
- package/dist/components/apple/AppleLoginButton.d.ts +0 -29
- package/dist/components/deposit/CreditBalance.d.ts +0 -19
- package/dist/components/deposit/DepositFlow.d.ts +0 -118
- package/dist/components/deposit/FeeConfigDisplay.d.ts +0 -15
- package/dist/components/deposit/History.d.ts +0 -21
- package/dist/components/deposit/TieredAmountSlider.d.ts +0 -19
- package/dist/components/deposit/TokenSelector.d.ts +0 -23
- package/dist/components/deposit/admin/AdminDepositList.d.ts +0 -21
- package/dist/components/deposit/admin/AdminDepositStats.d.ts +0 -15
- package/dist/components/deposit/admin/AdminPrivacyPeriodDeposits.d.ts +0 -19
- package/dist/components/deposit/admin/AdminWithdrawalHistory.d.ts +0 -19
- package/dist/components/deposit/admin/AdminWithdrawalQueue.d.ts +0 -23
- package/dist/components/deposit/admin/AdminWithdrawalStats.d.ts +0 -10
- package/dist/components/deposit/admin/FeatureDisabledMessage.d.ts +0 -15
- package/dist/components/deposit/admin/PrivacySystemStatus.d.ts +0 -15
- package/dist/components/deposit/admin/featureDisabled.d.ts +0 -14
- package/dist/components/deposit/admin/index.d.ts +0 -22
- package/dist/components/deposit/index.d.ts +0 -12
- package/dist/components/deposit/tierUtils.d.ts +0 -8
- package/dist/components/deposit/tokens.d.ts +0 -19
- package/dist/components/email/EmailLoginForm.d.ts +0 -11
- package/dist/components/email/EmailRegisterForm.d.ts +0 -14
- package/dist/components/email/ForgotPasswordForm.d.ts +0 -17
- package/dist/components/email/PasswordInput.d.ts +0 -14
- package/dist/components/email/ResetPasswordForm.d.ts +0 -22
- package/dist/components/google/GoogleLoginButton.d.ts +0 -12
- package/dist/components/invites/InviteForm.d.ts +0 -38
- package/dist/components/invites/InviteList.d.ts +0 -40
- package/dist/components/members/MemberList.d.ts +0 -47
- package/dist/components/org/CreateOrgForm.d.ts +0 -7
- package/dist/components/org/OrgAvatar.d.ts +0 -7
- package/dist/components/org/OrgListView.d.ts +0 -9
- package/dist/components/org/OrgSelector.d.ts +0 -52
- package/dist/components/org/OrgSwitcher.d.ts +0 -47
- package/dist/components/org/icons.d.ts +0 -8
- package/dist/components/profile/UserProfileSettings.d.ts +0 -35
- package/dist/components/profile/index.d.ts +0 -2
- package/dist/components/sessions/SessionList.d.ts +0 -33
- package/dist/components/shared/ErrorBoundary.d.ts +0 -38
- package/dist/components/shared/ErrorMessage.d.ts +0 -14
- package/dist/components/shared/LoadingSpinner.d.ts +0 -16
- package/dist/components/solana/SolanaLoginButton.d.ts +0 -49
- package/dist/components/templates/FullPageLayout.d.ts +0 -40
- package/dist/components/templates/SplitPageLayout.d.ts +0 -44
- package/dist/components/templates/index.d.ts +0 -4
- package/dist/components/totp/OtpInput.d.ts +0 -32
- package/dist/components/totp/QrCode.d.ts +0 -21
- package/dist/components/totp/TotpSettings.d.ts +0 -38
- package/dist/components/totp/TotpSetup.d.ts +0 -23
- package/dist/components/totp/TotpVerify.d.ts +0 -25
- package/dist/components/totp/index.d.ts +0 -10
- package/dist/components/wallet/CapabilityWarning.d.ts +0 -11
- package/dist/components/wallet/PasskeyPrompt.d.ts +0 -34
- package/dist/components/wallet/RecoveryPhraseDisplay.d.ts +0 -18
- package/dist/components/wallet/RecoveryPhraseInput.d.ts +0 -21
- package/dist/components/wallet/WalletAddressRow.d.ts +0 -10
- package/dist/components/wallet/WalletEnrollment.d.ts +0 -15
- package/dist/components/wallet/WalletManager.d.ts +0 -9
- package/dist/components/wallet/WalletRecovery.d.ts +0 -19
- package/dist/components/wallet/WalletStatus.d.ts +0 -28
- package/dist/components/wallet/WalletUnlock.d.ts +0 -23
- package/dist/components/wallet/index.d.ts +0 -23
- package/dist/components/webauthn/PasskeyLoginButton.d.ts +0 -8
- package/dist/context/CedrosLoginContext.d.ts +0 -24
- package/dist/context/CedrosLoginProvider.d.ts +0 -17
- package/dist/context/EmbeddedWalletExposure.d.ts +0 -19
- package/dist/context/useCedrosLogin.d.ts +0 -12
- package/dist/crypto/aesGcm.d.ts +0 -89
- package/dist/crypto/argon2.d.ts +0 -65
- package/dist/crypto/argon2Worker.d.ts +0 -1
- package/dist/crypto/argon2WorkerClient.d.ts +0 -28
- package/dist/crypto/bip39.d.ts +0 -106
- package/dist/crypto/capabilities.d.ts +0 -35
- package/dist/crypto/entropy.d.ts +0 -56
- package/dist/crypto/hkdf.d.ts +0 -38
- package/dist/crypto/index.d.ts +0 -30
- package/dist/crypto/secureWipe.d.ts +0 -71
- package/dist/crypto/shamir.d.ts +0 -52
- package/dist/crypto/solanaKeypair.d.ts +0 -63
- package/dist/crypto/types.d.ts +0 -134
- package/dist/crypto/webauthnPrf.d.ts +0 -108
- package/dist/hooks/useAdminDeposits.d.ts +0 -10
- package/dist/hooks/useAdminUsers.d.ts +0 -28
- package/dist/hooks/useAppleAuth.d.ts +0 -52
- package/dist/hooks/useAuth.d.ts +0 -34
- package/dist/hooks/useAuthSession.d.ts +0 -19
- package/dist/hooks/useAuthorize.d.ts +0 -62
- package/dist/hooks/useCredits.d.ts +0 -11
- package/dist/hooks/useDashboardPermissions.d.ts +0 -45
- package/dist/hooks/useDeposit.d.ts +0 -16
- package/dist/hooks/useEmailAuth.d.ts +0 -60
- package/dist/hooks/useGoogleAuth.d.ts +0 -67
- package/dist/hooks/useInstantLink.d.ts +0 -42
- package/dist/hooks/useInvites.d.ts +0 -57
- package/dist/hooks/useMembers.d.ts +0 -52
- package/dist/hooks/useOrgs.d.ts +0 -49
- package/dist/hooks/usePasswordReset.d.ts +0 -32
- package/dist/hooks/usePendingRecovery.d.ts +0 -34
- package/dist/hooks/useProfile.d.ts +0 -35
- package/dist/hooks/useRateLimiter.d.ts +0 -58
- package/dist/hooks/useServerFeatures.d.ts +0 -55
- package/dist/hooks/useSessions.d.ts +0 -45
- package/dist/hooks/useSettingsAutosave.d.ts +0 -29
- package/dist/hooks/useSetup.d.ts +0 -25
- package/dist/hooks/useSolanaAuth.d.ts +0 -30
- package/dist/hooks/useSsoProviders.d.ts +0 -52
- package/dist/hooks/useSystemSettings.d.ts +0 -47
- package/dist/hooks/useThemeManager.d.ts +0 -11
- package/dist/hooks/useTotp.d.ts +0 -52
- package/dist/hooks/useTotpVerify.d.ts +0 -38
- package/dist/hooks/useTransactionSigning.d.ts +0 -45
- package/dist/hooks/useWallet.d.ts +0 -10
- package/dist/hooks/useWalletDiscovery.d.ts +0 -24
- package/dist/hooks/useWalletEnrollment.d.ts +0 -9
- package/dist/hooks/useWalletMaterial.d.ts +0 -10
- package/dist/hooks/useWalletRecovery.d.ts +0 -9
- package/dist/hooks/useWalletSigning.d.ts +0 -31
- package/dist/hooks/useWebAuthn.d.ts +0 -25
- package/dist/i18n/I18nProvider.d.ts +0 -16
- package/dist/i18n/context.d.ts +0 -6
- package/dist/i18n/index.d.ts +0 -5
- package/dist/i18n/translations.d.ts +0 -66
- package/dist/i18n/useI18n.d.ts +0 -9
- package/dist/index-ZS9AwAal.cjs +0 -2061
- package/dist/index-ZS9AwAal.cjs.map +0 -1
- package/dist/index-dgg5tlO7.js +0 -19650
- package/dist/index-dgg5tlO7.js.map +0 -1
- package/dist/silentWalletEnroll-C3JRAD9_.js +0 -42
- package/dist/silentWalletEnroll-C3JRAD9_.js.map +0 -1
- package/dist/silentWalletEnroll-DRYQAQfg.cjs +0 -1
- package/dist/silentWalletEnroll-DRYQAQfg.cjs.map +0 -1
- package/dist/solanaKeypair-BlXol3nh.js.map +0 -1
- package/dist/solanaKeypair-C-lIR1JY.cjs +0 -1
- package/dist/solanaKeypair-C-lIR1JY.cjs.map +0 -1
- package/dist/types/adminUser.d.ts +0 -168
- package/dist/types/auth.d.ts +0 -122
- package/dist/types/config.d.ts +0 -266
- package/dist/types/deposit.d.ts +0 -490
- package/dist/types/index.d.ts +0 -13
- package/dist/types/invite.d.ts +0 -71
- package/dist/types/member.d.ts +0 -45
- package/dist/types/org.d.ts +0 -133
- package/dist/types/profile.d.ts +0 -56
- package/dist/types/session.d.ts +0 -28
- package/dist/types/setup.d.ts +0 -47
- package/dist/types/systemSettings.d.ts +0 -85
- package/dist/types/totp.d.ts +0 -52
- package/dist/types/wallet.d.ts +0 -309
- package/dist/utils/adminUserApi.d.ts +0 -60
- package/dist/utils/apiClient.d.ts +0 -78
- package/dist/utils/cryptoShim.d.ts +0 -17
- package/dist/utils/csrf.d.ts +0 -1
- package/dist/utils/deviceDetection.d.ts +0 -17
- package/dist/utils/embeddedWallet.d.ts +0 -75
- package/dist/utils/inviteApi.d.ts +0 -31
- package/dist/utils/memberApi.d.ts +0 -23
- package/dist/utils/orgApi.d.ts +0 -36
- package/dist/utils/profileApi.d.ts +0 -26
- package/dist/utils/sanitization.d.ts +0 -66
- package/dist/utils/sessionApi.d.ts +0 -16
- package/dist/utils/setupApi.d.ts +0 -21
- package/dist/utils/silentWalletEnroll.d.ts +0 -41
- package/dist/utils/systemSettingsApi.d.ts +0 -18
- package/dist/utils/tabSync.d.ts +0 -46
- package/dist/utils/tokenManager.d.ts +0 -107
- package/dist/utils/unlockCredential.d.ts +0 -5
- package/dist/utils/validation.d.ts +0 -48
- package/dist/utils/walletDetection.d.ts +0 -23
- package/dist/utils/webauthnJson.d.ts +0 -21
package/dist/types/wallet.d.ts
DELETED
|
@@ -1,309 +0,0 @@
|
|
|
1
|
-
import { WalletStatus, CryptoCapabilities, EnrollmentState, RecoveryState, KdfParams } from '../crypto';
|
|
2
|
-
export type { WalletStatus, CryptoCapabilities, EnrollmentState, RecoveryState, KdfParams };
|
|
3
|
-
/**
|
|
4
|
-
* Wallet recovery mode (configured server-side via WALLET_RECOVERY_MODE)
|
|
5
|
-
* - share_c_only: User gets Share C only. Recovery within app, not portable.
|
|
6
|
-
* - full_seed: User gets full seed. Can use wallet elsewhere (portable).
|
|
7
|
-
* - none: No recovery option. Used for Privacy Cash deposits to prevent front-running.
|
|
8
|
-
*/
|
|
9
|
-
export type WalletRecoveryMode = 'share_c_only' | 'full_seed' | 'none';
|
|
10
|
-
/**
|
|
11
|
-
* Wallet discovery config from server
|
|
12
|
-
*/
|
|
13
|
-
export interface WalletDiscoveryConfig {
|
|
14
|
-
/** Whether wallet feature is enabled */
|
|
15
|
-
enabled: boolean;
|
|
16
|
-
/** Recovery mode: share_c_only or full_seed */
|
|
17
|
-
recoveryMode: WalletRecoveryMode;
|
|
18
|
-
/** Session unlock TTL in seconds */
|
|
19
|
-
unlockTtlSeconds: number;
|
|
20
|
-
}
|
|
21
|
-
/**
|
|
22
|
-
* Authentication method for Share A encryption
|
|
23
|
-
* - password: Email users use their login password (Argon2id KDF)
|
|
24
|
-
* - passkey: Users with passkey login use PRF extension (HKDF)
|
|
25
|
-
*/
|
|
26
|
-
export type ShareAAuthMethod = 'password' | 'passkey';
|
|
27
|
-
/**
|
|
28
|
-
* Wallet material response from server
|
|
29
|
-
* Note: Server no longer returns share ciphertexts - shares stay on server
|
|
30
|
-
*/
|
|
31
|
-
export interface WalletMaterialResponse {
|
|
32
|
-
solanaPubkey: string;
|
|
33
|
-
schemeVersion: number;
|
|
34
|
-
shareAAuthMethod: ShareAAuthMethod;
|
|
35
|
-
/** PRF salt for passkey auth method (base64, 32 bytes) */
|
|
36
|
-
prfSalt?: string;
|
|
37
|
-
createdAt: string;
|
|
38
|
-
updatedAt: string;
|
|
39
|
-
}
|
|
40
|
-
/** Request to enroll wallet */
|
|
41
|
-
export interface WalletEnrollRequest {
|
|
42
|
-
solanaPubkey: string;
|
|
43
|
-
/** Auth method for Share A encryption */
|
|
44
|
-
shareAAuthMethod: ShareAAuthMethod;
|
|
45
|
-
/** Encrypted Share A (base64) */
|
|
46
|
-
shareACiphertext: string;
|
|
47
|
-
/** Nonce for Share A encryption (base64, 12 bytes) */
|
|
48
|
-
shareANonce: string;
|
|
49
|
-
/** KDF salt for password/PIN method (base64) */
|
|
50
|
-
shareAKdfSalt?: string;
|
|
51
|
-
/** KDF params for password/PIN method */
|
|
52
|
-
shareAKdfParams?: KdfParams;
|
|
53
|
-
/** PRF salt for passkey method (base64, 32 bytes) */
|
|
54
|
-
prfSalt?: string;
|
|
55
|
-
/** Plaintext Share B (base64) - SSS math protects it */
|
|
56
|
-
shareB: string;
|
|
57
|
-
/**
|
|
58
|
-
* Recovery data (base64) - sent when recovery mode is enabled
|
|
59
|
-
* Contains the full seed for server-side storage until user acknowledges
|
|
60
|
-
*/
|
|
61
|
-
recoveryData?: string;
|
|
62
|
-
}
|
|
63
|
-
/** Request to get Share B for Share C recovery mode */
|
|
64
|
-
export interface ShareCRecoveryRequest {
|
|
65
|
-
/** Share C data (base64, 32 bytes decoded from mnemonic) */
|
|
66
|
-
shareC: string;
|
|
67
|
-
}
|
|
68
|
-
/** Response from Share C recovery endpoint */
|
|
69
|
-
export interface ShareCRecoveryResponse {
|
|
70
|
-
/** Share B (base64) */
|
|
71
|
-
shareB: string;
|
|
72
|
-
/** Solana pubkey (for verification) */
|
|
73
|
-
solanaPubkey: string;
|
|
74
|
-
}
|
|
75
|
-
/** Request to recover wallet (replace existing with new credentials) */
|
|
76
|
-
export interface WalletRecoverRequest {
|
|
77
|
-
/** Solana pubkey (must match existing wallet to prove ownership) */
|
|
78
|
-
solanaPubkey: string;
|
|
79
|
-
/** Auth method for Share A encryption */
|
|
80
|
-
shareAAuthMethod: ShareAAuthMethod;
|
|
81
|
-
/** Encrypted Share A (base64) */
|
|
82
|
-
shareACiphertext: string;
|
|
83
|
-
/** Nonce for Share A encryption (base64, 12 bytes) */
|
|
84
|
-
shareANonce: string;
|
|
85
|
-
/** KDF salt for password/PIN method (base64) */
|
|
86
|
-
shareAKdfSalt?: string;
|
|
87
|
-
/** KDF params for password/PIN method */
|
|
88
|
-
shareAKdfParams?: KdfParams;
|
|
89
|
-
/** PRF salt for passkey method (base64, 32 bytes) */
|
|
90
|
-
prfSalt?: string;
|
|
91
|
-
/** Plaintext Share B (base64) */
|
|
92
|
-
shareB: string;
|
|
93
|
-
}
|
|
94
|
-
/**
|
|
95
|
-
* Credential for unlocking wallet / signing transactions (frontend internal use)
|
|
96
|
-
*
|
|
97
|
-
* TYPE-02: This type uses explicit `type` discriminator for TypeScript narrowing.
|
|
98
|
-
* When sending to server API, convert to `UnlockCredentialRequest` which uses
|
|
99
|
-
* the flattened format expected by the backend (`{ password: '...' }` not
|
|
100
|
-
* `{ type: 'password', password: '...' }`).
|
|
101
|
-
*
|
|
102
|
-
* @see UnlockCredentialRequest for API request format
|
|
103
|
-
*/
|
|
104
|
-
export type UnlockCredential = {
|
|
105
|
-
type: 'password';
|
|
106
|
-
password: string;
|
|
107
|
-
} | {
|
|
108
|
-
type: 'prfOutput';
|
|
109
|
-
prfOutput: string;
|
|
110
|
-
};
|
|
111
|
-
/** Request to sign a transaction */
|
|
112
|
-
export interface SignTransactionRequest {
|
|
113
|
-
/** Transaction bytes (base64) */
|
|
114
|
-
transaction: string;
|
|
115
|
-
/** Unlock credential */
|
|
116
|
-
credential?: UnlockCredentialRequest;
|
|
117
|
-
}
|
|
118
|
-
/**
|
|
119
|
-
* Credential for API request (flattened format matching server)
|
|
120
|
-
*
|
|
121
|
-
* TYPE-02: Server uses Serde's flattened enum format, so only ONE of these
|
|
122
|
-
* fields should be present in the request object. Do NOT include `type` field.
|
|
123
|
-
*
|
|
124
|
-
* @example { password: 'secret' }
|
|
125
|
-
* @example { prfOutput: 'base64...' }
|
|
126
|
-
*/
|
|
127
|
-
export type UnlockCredentialRequest = {
|
|
128
|
-
password: string;
|
|
129
|
-
} | {
|
|
130
|
-
prfOutput: string;
|
|
131
|
-
};
|
|
132
|
-
/** Response from transaction signing */
|
|
133
|
-
export interface SignTransactionResponse {
|
|
134
|
-
/** Ed25519 signature (base64, 64 bytes) */
|
|
135
|
-
signature: string;
|
|
136
|
-
/** Solana pubkey that signed */
|
|
137
|
-
pubkey: string;
|
|
138
|
-
}
|
|
139
|
-
/**
|
|
140
|
-
* Request to rotate user secret (re-encrypt Share A)
|
|
141
|
-
*
|
|
142
|
-
* TYPE-04: Current credential fields are FLATTENED into this struct (not nested).
|
|
143
|
-
* The server uses `#[serde(flatten)]` so credential fields appear at root level.
|
|
144
|
-
* E.g., send `{ password: "xxx", newAuthMethod: "passkey", ... }` not `{ currentCredential: {...} }`
|
|
145
|
-
*
|
|
146
|
-
* BUILD-01: Uses intersection type instead of interface-extends because
|
|
147
|
-
* UnlockCredentialRequest is a union type (TypeScript doesn't allow interfaces
|
|
148
|
-
* to extend union types).
|
|
149
|
-
*/
|
|
150
|
-
export type RotateUserSecretRequest = UnlockCredentialRequest & {
|
|
151
|
-
/** New auth method */
|
|
152
|
-
newAuthMethod: ShareAAuthMethod;
|
|
153
|
-
/** New encrypted Share A (base64) */
|
|
154
|
-
shareACiphertext: string;
|
|
155
|
-
/** New nonce (base64, 12 bytes) */
|
|
156
|
-
shareANonce: string;
|
|
157
|
-
/** New KDF salt for password/PIN (base64) */
|
|
158
|
-
shareAKdfSalt?: string;
|
|
159
|
-
/** New KDF params for password/PIN */
|
|
160
|
-
shareAKdfParams?: KdfParams;
|
|
161
|
-
/** New PRF salt for passkey (base64, 32 bytes) */
|
|
162
|
-
prfSalt?: string;
|
|
163
|
-
};
|
|
164
|
-
/** Message response from server */
|
|
165
|
-
export interface MessageResponse {
|
|
166
|
-
message: string;
|
|
167
|
-
}
|
|
168
|
-
/** Request to unlock wallet for session-based signing */
|
|
169
|
-
export interface WalletUnlockRequest {
|
|
170
|
-
/** Unlock credential (flattened format) */
|
|
171
|
-
credential: UnlockCredentialRequest;
|
|
172
|
-
}
|
|
173
|
-
/** Response from wallet unlock */
|
|
174
|
-
export interface WalletUnlockResponse {
|
|
175
|
-
/** Whether wallet is now unlocked */
|
|
176
|
-
unlocked: boolean;
|
|
177
|
-
/** TTL in seconds until auto-lock */
|
|
178
|
-
ttlSeconds: number;
|
|
179
|
-
}
|
|
180
|
-
/** Wallet status response from server */
|
|
181
|
-
export interface WalletStatusApiResponse {
|
|
182
|
-
/** Whether SSS embedded wallet is enrolled */
|
|
183
|
-
enrolled: boolean;
|
|
184
|
-
/** Whether wallet is currently unlocked for signing */
|
|
185
|
-
unlocked: boolean;
|
|
186
|
-
/** Solana public key (from SSS wallet if enrolled, or external wallet if connected) */
|
|
187
|
-
solanaPubkey?: string;
|
|
188
|
-
/** Auth method for SSS wallet (if enrolled) */
|
|
189
|
-
authMethod?: ShareAAuthMethod;
|
|
190
|
-
/** Whether user signed in with external Solana wallet (not SSS) */
|
|
191
|
-
hasExternalWallet: boolean;
|
|
192
|
-
}
|
|
193
|
-
/** Wallet context value */
|
|
194
|
-
export interface WalletContextValue {
|
|
195
|
-
/** Current wallet status */
|
|
196
|
-
status: WalletStatus;
|
|
197
|
-
/** Solana public key (from SSS wallet if enrolled, or external wallet) */
|
|
198
|
-
solanaPubkey: string | null;
|
|
199
|
-
/** Auth method for Share A (if enrolled in SSS wallet) */
|
|
200
|
-
authMethod: ShareAAuthMethod | null;
|
|
201
|
-
/** Whether user signed in with external Solana wallet (not SSS) */
|
|
202
|
-
hasExternalWallet: boolean;
|
|
203
|
-
/** Whether SSS wallet is unlocked for signing */
|
|
204
|
-
isUnlocked: boolean;
|
|
205
|
-
/** Crypto capabilities */
|
|
206
|
-
capabilities: CryptoCapabilities | null;
|
|
207
|
-
/** Whether all required capabilities are available */
|
|
208
|
-
isSupported: boolean;
|
|
209
|
-
/** Error message if any */
|
|
210
|
-
error: string | null;
|
|
211
|
-
/** Refresh wallet status */
|
|
212
|
-
refresh: () => Promise<void>;
|
|
213
|
-
/** Clear error */
|
|
214
|
-
clearError: () => void;
|
|
215
|
-
}
|
|
216
|
-
/** Enrollment hook return value */
|
|
217
|
-
export interface UseWalletEnrollmentReturn {
|
|
218
|
-
/** Current enrollment state */
|
|
219
|
-
state: EnrollmentState;
|
|
220
|
-
/** Start enrollment with password (email users) */
|
|
221
|
-
startEnrollmentWithPassword: (password: string) => Promise<void>;
|
|
222
|
-
/** Start enrollment with passkey PRF */
|
|
223
|
-
startEnrollmentWithPasskey: () => Promise<void>;
|
|
224
|
-
/** Confirm user has saved recovery phrase */
|
|
225
|
-
confirmRecoveryPhrase: () => void;
|
|
226
|
-
/** Cancel enrollment */
|
|
227
|
-
cancel: () => void;
|
|
228
|
-
/** Whether enrollment is in progress */
|
|
229
|
-
isEnrolling: boolean;
|
|
230
|
-
}
|
|
231
|
-
/**
|
|
232
|
-
* Signing hook return value
|
|
233
|
-
* Signing is server-side. Client just provides credential.
|
|
234
|
-
*/
|
|
235
|
-
export interface UseWalletSigningReturn {
|
|
236
|
-
/** Sign a transaction */
|
|
237
|
-
signTransaction: (transaction: Uint8Array, credential?: UnlockCredential) => Promise<Uint8Array>;
|
|
238
|
-
/** Whether signing is in progress */
|
|
239
|
-
isSigning: boolean;
|
|
240
|
-
/** Error from last signing attempt */
|
|
241
|
-
error: string | null;
|
|
242
|
-
/** Clear error */
|
|
243
|
-
clearError: () => void;
|
|
244
|
-
}
|
|
245
|
-
/** Recovery hook return value */
|
|
246
|
-
export interface UseWalletRecoveryReturn {
|
|
247
|
-
/** Current recovery state */
|
|
248
|
-
state: RecoveryState;
|
|
249
|
-
/** Start recovery: validate phrase, then set new credential */
|
|
250
|
-
startRecovery: (words: string[], method: ShareAAuthMethod, credential: string) => Promise<void>;
|
|
251
|
-
/** Cancel recovery */
|
|
252
|
-
cancel: () => void;
|
|
253
|
-
/** Whether recovery is in progress */
|
|
254
|
-
isRecovering: boolean;
|
|
255
|
-
}
|
|
256
|
-
/** Wallet material hook return value */
|
|
257
|
-
export interface UseWalletMaterialReturn {
|
|
258
|
-
/** Fetch wallet status (enrolled, unlocked, external wallet) */
|
|
259
|
-
getStatus: () => Promise<WalletStatusApiResponse>;
|
|
260
|
-
/** Fetch wallet material (for SSS wallet details) */
|
|
261
|
-
getMaterial: () => Promise<WalletMaterialResponse | null>;
|
|
262
|
-
/** Enroll new SSS wallet */
|
|
263
|
-
enroll: (request: WalletEnrollRequest) => Promise<void>;
|
|
264
|
-
/** Recover wallet (replace existing with new credentials) */
|
|
265
|
-
recover: (request: WalletRecoverRequest) => Promise<void>;
|
|
266
|
-
/** Sign a transaction (SSS wallet) */
|
|
267
|
-
signTransaction: (request: SignTransactionRequest) => Promise<SignTransactionResponse>;
|
|
268
|
-
/** Rotate user secret */
|
|
269
|
-
rotateUserSecret: (request: RotateUserSecretRequest) => Promise<void>;
|
|
270
|
-
/** Unlock wallet for session-based signing (credential cached server-side) */
|
|
271
|
-
unlock: (credential: UnlockCredential) => Promise<WalletUnlockResponse>;
|
|
272
|
-
/** Lock wallet (clear cached credential) */
|
|
273
|
-
lock: () => Promise<void>;
|
|
274
|
-
/** Get Share B for Share C recovery mode (proves ownership via Share C) */
|
|
275
|
-
getShareBForRecovery: (request: ShareCRecoveryRequest) => Promise<ShareCRecoveryResponse>;
|
|
276
|
-
/** Whether request is in progress */
|
|
277
|
-
isLoading: boolean;
|
|
278
|
-
/** Error from last request */
|
|
279
|
-
error: string | null;
|
|
280
|
-
/** Clear error */
|
|
281
|
-
clearError: () => void;
|
|
282
|
-
}
|
|
283
|
-
/** PRF capability hook return value */
|
|
284
|
-
export interface UsePrfCapabilityReturn {
|
|
285
|
-
/** Whether PRF is supported */
|
|
286
|
-
isSupported: boolean;
|
|
287
|
-
/** Whether check is in progress */
|
|
288
|
-
isChecking: boolean;
|
|
289
|
-
/** Error message if check failed */
|
|
290
|
-
error: string | null;
|
|
291
|
-
/** Recheck PRF support */
|
|
292
|
-
recheck: () => Promise<void>;
|
|
293
|
-
}
|
|
294
|
-
/** Response from pending wallet recovery check */
|
|
295
|
-
export interface PendingWalletRecoveryResponse {
|
|
296
|
-
/** Whether there is pending recovery data to acknowledge */
|
|
297
|
-
hasPendingRecovery: boolean;
|
|
298
|
-
/** Type of recovery data: "share_c" or "full_seed" */
|
|
299
|
-
recoveryType?: string;
|
|
300
|
-
/** Recovery phrase (BIP-39 mnemonic or base64 seed) */
|
|
301
|
-
recoveryPhrase?: string;
|
|
302
|
-
/** When the recovery data expires */
|
|
303
|
-
expiresAt?: string;
|
|
304
|
-
}
|
|
305
|
-
/** Request to acknowledge receipt of recovery phrase */
|
|
306
|
-
export interface AcknowledgeRecoveryRequest {
|
|
307
|
-
/** Confirmation that user has saved the recovery phrase */
|
|
308
|
-
confirmed: boolean;
|
|
309
|
-
}
|
|
@@ -1,60 +0,0 @@
|
|
|
1
|
-
import { AdminUser, AdminUserChatsResponse, AdminUserCreditsResponse, AdminUserStatsResponse, AdjustCreditsRequest, ListAdminUsersResponse, ListUsersParams, UpdateUserRequest } from '../types';
|
|
2
|
-
import { AdminDepositListResponse, AdminUserWithdrawalHistoryResponse } from '../types/deposit';
|
|
3
|
-
/**
|
|
4
|
-
* API client for admin user operations
|
|
5
|
-
*
|
|
6
|
-
* Requires system admin privileges.
|
|
7
|
-
*/
|
|
8
|
-
export declare class AdminUserApiClient {
|
|
9
|
-
private client;
|
|
10
|
-
constructor(baseUrl: string, timeoutMs?: number, retryAttempts?: number, getAccessToken?: () => string | null);
|
|
11
|
-
/**
|
|
12
|
-
* List all users in the system
|
|
13
|
-
*/
|
|
14
|
-
listUsers(params?: ListUsersParams): Promise<ListAdminUsersResponse>;
|
|
15
|
-
/**
|
|
16
|
-
* Get a specific user by ID
|
|
17
|
-
*/
|
|
18
|
-
getUser(userId: string): Promise<AdminUser>;
|
|
19
|
-
/**
|
|
20
|
-
* Set a user's system admin status
|
|
21
|
-
*/
|
|
22
|
-
setSystemAdmin(userId: string, isAdmin: boolean): Promise<void>;
|
|
23
|
-
/**
|
|
24
|
-
* Update a user's profile
|
|
25
|
-
*/
|
|
26
|
-
updateUser(userId: string, data: UpdateUserRequest): Promise<AdminUser>;
|
|
27
|
-
/**
|
|
28
|
-
* Delete a user
|
|
29
|
-
*/
|
|
30
|
-
deleteUser(userId: string): Promise<void>;
|
|
31
|
-
/**
|
|
32
|
-
* Send a password reset email to a user
|
|
33
|
-
*/
|
|
34
|
-
forcePasswordReset(userId: string): Promise<void>;
|
|
35
|
-
/**
|
|
36
|
-
* Adjust a user's credits
|
|
37
|
-
*/
|
|
38
|
-
adjustCredits(userId: string, data: AdjustCreditsRequest): Promise<void>;
|
|
39
|
-
/**
|
|
40
|
-
* Get a user's deposit history
|
|
41
|
-
*/
|
|
42
|
-
getUserDeposits(userId: string, params?: ListUsersParams): Promise<AdminDepositListResponse>;
|
|
43
|
-
/**
|
|
44
|
-
* Get a user's credit stats and transaction history
|
|
45
|
-
*/
|
|
46
|
-
getUserCredits(userId: string, params?: ListUsersParams): Promise<AdminUserCreditsResponse>;
|
|
47
|
-
/**
|
|
48
|
-
* Get a user's withdrawal history
|
|
49
|
-
*/
|
|
50
|
-
getUserWithdrawalHistory(userId: string, params?: ListUsersParams): Promise<AdminUserWithdrawalHistoryResponse>;
|
|
51
|
-
/**
|
|
52
|
-
* Get a user's chat history (from cedros-pay)
|
|
53
|
-
* Only available when cedros-pay is enabled.
|
|
54
|
-
*/
|
|
55
|
-
getUserChats(userId: string, params?: ListUsersParams): Promise<AdminUserChatsResponse>;
|
|
56
|
-
/**
|
|
57
|
-
* Get user statistics by auth method
|
|
58
|
-
*/
|
|
59
|
-
getStats(): Promise<AdminUserStatsResponse>;
|
|
60
|
-
}
|
|
@@ -1,78 +0,0 @@
|
|
|
1
|
-
import { AuthError } from '../types';
|
|
2
|
-
export interface ApiClientConfig {
|
|
3
|
-
baseUrl: string;
|
|
4
|
-
timeoutMs?: number;
|
|
5
|
-
retryAttempts?: number;
|
|
6
|
-
getAccessToken?: () => string | null;
|
|
7
|
-
}
|
|
8
|
-
/**
|
|
9
|
-
* M-02: Response validator function type.
|
|
10
|
-
* Returns the validated data or throws on invalid shape.
|
|
11
|
-
*/
|
|
12
|
-
export type ResponseValidator<T> = (data: unknown) => T;
|
|
13
|
-
export interface RequestOptions<T = unknown> {
|
|
14
|
-
method: 'GET' | 'HEAD' | 'POST' | 'PUT' | 'PATCH' | 'DELETE';
|
|
15
|
-
path: string;
|
|
16
|
-
body?: unknown;
|
|
17
|
-
credentials?: RequestCredentials;
|
|
18
|
-
skipRetry?: boolean;
|
|
19
|
-
/** M-02: Optional validator to verify response shape at runtime */
|
|
20
|
-
validator?: ResponseValidator<T>;
|
|
21
|
-
}
|
|
22
|
-
/**
|
|
23
|
-
* Creates an authentication error from response data
|
|
24
|
-
*/
|
|
25
|
-
export declare function createAuthError(data: {
|
|
26
|
-
code?: string;
|
|
27
|
-
message?: string;
|
|
28
|
-
details?: Record<string, unknown>;
|
|
29
|
-
}, fallbackMessage: string): AuthError;
|
|
30
|
-
/**
|
|
31
|
-
* Creates a network error
|
|
32
|
-
*/
|
|
33
|
-
export declare function createNetworkError(): AuthError;
|
|
34
|
-
/**
|
|
35
|
-
* API client for making authenticated requests with timeout and retry support
|
|
36
|
-
*/
|
|
37
|
-
export declare class ApiClient {
|
|
38
|
-
private baseUrl;
|
|
39
|
-
private timeoutMs;
|
|
40
|
-
private retryAttempts;
|
|
41
|
-
private getAccessToken?;
|
|
42
|
-
constructor(config: ApiClientConfig);
|
|
43
|
-
/**
|
|
44
|
-
* Make an API request with timeout and optional retry
|
|
45
|
-
*/
|
|
46
|
-
request<T>(options: RequestOptions<T>): Promise<T>;
|
|
47
|
-
/**
|
|
48
|
-
* POST request helper
|
|
49
|
-
*/
|
|
50
|
-
post<T>(path: string, body: unknown, options?: Partial<RequestOptions<T>>): Promise<T>;
|
|
51
|
-
/**
|
|
52
|
-
* GET request helper
|
|
53
|
-
*/
|
|
54
|
-
get<T>(path: string, options?: Partial<RequestOptions<T>>): Promise<T>;
|
|
55
|
-
/**
|
|
56
|
-
* PATCH request helper
|
|
57
|
-
*/
|
|
58
|
-
patch<T>(path: string, body: unknown, options?: Partial<RequestOptions<T>>): Promise<T>;
|
|
59
|
-
/**
|
|
60
|
-
* DELETE request helper
|
|
61
|
-
*/
|
|
62
|
-
delete<T>(path: string, options?: Partial<RequestOptions<T>>): Promise<T>;
|
|
63
|
-
}
|
|
64
|
-
/**
|
|
65
|
-
* M-02: Helper to create a basic object shape validator.
|
|
66
|
-
* Checks that required keys exist and are of expected types.
|
|
67
|
-
* @example
|
|
68
|
-
* const validateUser = createValidator<User>({
|
|
69
|
-
* id: 'string',
|
|
70
|
-
* email: 'string',
|
|
71
|
-
* role: 'string',
|
|
72
|
-
* });
|
|
73
|
-
*/
|
|
74
|
-
export declare function createValidator<T>(shape: Record<keyof T & string, 'string' | 'number' | 'boolean' | 'object'>): ResponseValidator<T>;
|
|
75
|
-
/**
|
|
76
|
-
* Converts API errors to AuthError format
|
|
77
|
-
*/
|
|
78
|
-
export declare function handleApiError(err: unknown, fallbackMessage: string): AuthError;
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Shim for Node's `crypto` module.
|
|
3
|
-
* Maps `require('crypto')` / `import 'crypto'` to Web Crypto API in the browser.
|
|
4
|
-
* Used by vite.config.ts alias to support CJS dependencies that expect Node crypto.
|
|
5
|
-
*/
|
|
6
|
-
declare const _default: Crypto;
|
|
7
|
-
export default _default;
|
|
8
|
-
export declare const webcrypto: Crypto;
|
|
9
|
-
export declare const subtle: SubtleCrypto;
|
|
10
|
-
export declare const getRandomValues: {
|
|
11
|
-
<T extends ArrayBufferView>(array: T): T;
|
|
12
|
-
<T extends ArrayBufferView>(array: T): T;
|
|
13
|
-
};
|
|
14
|
-
export declare const randomUUID: {
|
|
15
|
-
(): `${string}-${string}-${string}-${string}-${string}`;
|
|
16
|
-
(): `${string}-${string}-${string}-${string}-${string}`;
|
|
17
|
-
};
|
package/dist/utils/csrf.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function getCsrfToken(): string | null;
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Device detection utilities
|
|
3
|
-
*/
|
|
4
|
-
/**
|
|
5
|
-
* Detects if the current device is an Apple device (macOS, iOS, iPadOS).
|
|
6
|
-
* Apple Sign In is most useful on Apple devices where users have Apple ID readily available.
|
|
7
|
-
*
|
|
8
|
-
* @returns true if running on an Apple device
|
|
9
|
-
*
|
|
10
|
-
* @example
|
|
11
|
-
* ```tsx
|
|
12
|
-
* if (isAppleDevice()) {
|
|
13
|
-
* // Show Apple Sign In button
|
|
14
|
-
* }
|
|
15
|
-
* ```
|
|
16
|
-
*/
|
|
17
|
-
export declare function isAppleDevice(): boolean;
|
|
@@ -1,75 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Embedded wallet detection utilities
|
|
3
|
-
*
|
|
4
|
-
* Allows other Cedros modules (like cedros-pay) to detect if an embedded
|
|
5
|
-
* wallet is available in the current application.
|
|
6
|
-
*
|
|
7
|
-
* @security The window global only exposes availability info, NOT the signing
|
|
8
|
-
* function. Signing must go through React context to prevent unauthorized access.
|
|
9
|
-
*/
|
|
10
|
-
/** Window global name for embedded wallet detection */
|
|
11
|
-
declare const GLOBAL_KEY = "__CEDROS_EMBEDDED_WALLET__";
|
|
12
|
-
/**
|
|
13
|
-
* Embedded wallet info exposed via window global
|
|
14
|
-
*/
|
|
15
|
-
export interface EmbeddedWalletInfo {
|
|
16
|
-
/** Whether user has enrolled SSS embedded wallet */
|
|
17
|
-
available: boolean;
|
|
18
|
-
/** Solana public key (base58) if available */
|
|
19
|
-
publicKey: string | null;
|
|
20
|
-
}
|
|
21
|
-
declare global {
|
|
22
|
-
interface Window {
|
|
23
|
-
[GLOBAL_KEY]?: EmbeddedWalletInfo;
|
|
24
|
-
}
|
|
25
|
-
}
|
|
26
|
-
/**
|
|
27
|
-
* Set embedded wallet availability on window global
|
|
28
|
-
*
|
|
29
|
-
* Called by CedrosLoginProvider when wallet.exposeAvailability is true.
|
|
30
|
-
*
|
|
31
|
-
* @internal
|
|
32
|
-
*/
|
|
33
|
-
export declare function setEmbeddedWalletGlobal(info: EmbeddedWalletInfo): void;
|
|
34
|
-
/**
|
|
35
|
-
* Clear embedded wallet availability from window global
|
|
36
|
-
*
|
|
37
|
-
* Called when user logs out or config changes.
|
|
38
|
-
*
|
|
39
|
-
* @internal
|
|
40
|
-
*/
|
|
41
|
-
export declare function clearEmbeddedWalletGlobal(): void;
|
|
42
|
-
/**
|
|
43
|
-
* Check if embedded wallet is available
|
|
44
|
-
*
|
|
45
|
-
* Use this in other Cedros modules (like cedros-pay) to detect
|
|
46
|
-
* if an embedded wallet is available for signing.
|
|
47
|
-
*
|
|
48
|
-
* @example
|
|
49
|
-
* ```tsx
|
|
50
|
-
* import { isEmbeddedWalletAvailable, getEmbeddedWalletInfo } from '@cedros/login-react';
|
|
51
|
-
*
|
|
52
|
-
* // Simple check
|
|
53
|
-
* if (isEmbeddedWalletAvailable()) {
|
|
54
|
-
* // Show "Pay with Crypto" button
|
|
55
|
-
* }
|
|
56
|
-
*
|
|
57
|
-
* // Get full info
|
|
58
|
-
* const walletInfo = getEmbeddedWalletInfo();
|
|
59
|
-
* if (walletInfo?.available && walletInfo.publicKey) {
|
|
60
|
-
* console.log('User wallet:', walletInfo.publicKey);
|
|
61
|
-
* }
|
|
62
|
-
* ```
|
|
63
|
-
*
|
|
64
|
-
* @returns true if embedded wallet is enrolled and available
|
|
65
|
-
*/
|
|
66
|
-
export declare function isEmbeddedWalletAvailable(): boolean;
|
|
67
|
-
/**
|
|
68
|
-
* Get embedded wallet info
|
|
69
|
-
*
|
|
70
|
-
* Returns the full wallet info object if available.
|
|
71
|
-
*
|
|
72
|
-
* @returns Wallet info or null if not exposed
|
|
73
|
-
*/
|
|
74
|
-
export declare function getEmbeddedWalletInfo(): EmbeddedWalletInfo | null;
|
|
75
|
-
export {};
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
import { Invite, CreateInviteRequest, AcceptInviteRequest, CreateInviteResponse, AcceptInviteResponse } from '../types';
|
|
2
|
-
/**
|
|
3
|
-
* API client for invite operations
|
|
4
|
-
*/
|
|
5
|
-
export declare class InviteApiClient {
|
|
6
|
-
private client;
|
|
7
|
-
constructor(baseUrl: string, timeoutMs?: number, retryAttempts?: number, getAccessToken?: () => string | null);
|
|
8
|
-
/**
|
|
9
|
-
* List all pending invites for an organization
|
|
10
|
-
*/
|
|
11
|
-
listInvites(orgId: string, limit?: number, offset?: number): Promise<{
|
|
12
|
-
invites: Invite[];
|
|
13
|
-
total: number;
|
|
14
|
-
}>;
|
|
15
|
-
/**
|
|
16
|
-
* Create a new invite
|
|
17
|
-
*/
|
|
18
|
-
createInvite(orgId: string, data: CreateInviteRequest): Promise<CreateInviteResponse>;
|
|
19
|
-
/**
|
|
20
|
-
* Cancel a pending invite
|
|
21
|
-
*/
|
|
22
|
-
cancelInvite(orgId: string, inviteId: string): Promise<void>;
|
|
23
|
-
/**
|
|
24
|
-
* Resend an invite email
|
|
25
|
-
*/
|
|
26
|
-
resendInvite(orgId: string, inviteId: string): Promise<void>;
|
|
27
|
-
/**
|
|
28
|
-
* Accept an invite (public endpoint)
|
|
29
|
-
*/
|
|
30
|
-
acceptInvite(data: AcceptInviteRequest): Promise<AcceptInviteResponse>;
|
|
31
|
-
}
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
import { Member, UpdateMemberRoleRequest } from '../types';
|
|
2
|
-
/**
|
|
3
|
-
* API client for member operations within an organization
|
|
4
|
-
*/
|
|
5
|
-
export declare class MemberApiClient {
|
|
6
|
-
private client;
|
|
7
|
-
constructor(baseUrl: string, timeoutMs?: number, retryAttempts?: number, getAccessToken?: () => string | null);
|
|
8
|
-
/**
|
|
9
|
-
* List all members of an organization
|
|
10
|
-
*/
|
|
11
|
-
listMembers(orgId: string, limit?: number, offset?: number): Promise<{
|
|
12
|
-
members: Member[];
|
|
13
|
-
total: number;
|
|
14
|
-
}>;
|
|
15
|
-
/**
|
|
16
|
-
* Update a member's role
|
|
17
|
-
*/
|
|
18
|
-
updateMemberRole(orgId: string, userId: string, data: UpdateMemberRoleRequest): Promise<Member>;
|
|
19
|
-
/**
|
|
20
|
-
* Remove a member from the organization
|
|
21
|
-
*/
|
|
22
|
-
removeMember(orgId: string, userId: string): Promise<void>;
|
|
23
|
-
}
|
package/dist/utils/orgApi.d.ts
DELETED
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
import { Organization, OrgWithMembership, CreateOrgRequest, UpdateOrgRequest, AuthorizeRequest, AuthorizeResponse, PermissionsResponse } from '../types';
|
|
2
|
-
/**
|
|
3
|
-
* API client for organization operations
|
|
4
|
-
*/
|
|
5
|
-
export declare class OrgApiClient {
|
|
6
|
-
private client;
|
|
7
|
-
constructor(baseUrl: string, timeoutMs?: number, retryAttempts?: number, getAccessToken?: () => string | null);
|
|
8
|
-
/**
|
|
9
|
-
* List all organizations the current user belongs to
|
|
10
|
-
*/
|
|
11
|
-
listOrgs(): Promise<OrgWithMembership[]>;
|
|
12
|
-
/**
|
|
13
|
-
* Get a single organization by ID
|
|
14
|
-
*/
|
|
15
|
-
getOrg(orgId: string): Promise<Organization>;
|
|
16
|
-
/**
|
|
17
|
-
* Create a new organization
|
|
18
|
-
*/
|
|
19
|
-
createOrg(data: CreateOrgRequest): Promise<Organization>;
|
|
20
|
-
/**
|
|
21
|
-
* Update an organization
|
|
22
|
-
*/
|
|
23
|
-
updateOrg(orgId: string, data: UpdateOrgRequest): Promise<Organization>;
|
|
24
|
-
/**
|
|
25
|
-
* Delete an organization
|
|
26
|
-
*/
|
|
27
|
-
deleteOrg(orgId: string): Promise<void>;
|
|
28
|
-
/**
|
|
29
|
-
* Check authorization for an action
|
|
30
|
-
*/
|
|
31
|
-
authorize(data: AuthorizeRequest): Promise<AuthorizeResponse>;
|
|
32
|
-
/**
|
|
33
|
-
* Get current user's permissions in an organization
|
|
34
|
-
*/
|
|
35
|
-
getPermissions(orgId: string): Promise<PermissionsResponse>;
|
|
36
|
-
}
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import { ChangePasswordRequest, ChangePasswordResponse, UpdateProfileRequest, UpdateProfileResponse } from '../types';
|
|
2
|
-
/**
|
|
3
|
-
* API client for user profile operations
|
|
4
|
-
*
|
|
5
|
-
* Supports:
|
|
6
|
-
* - POST /auth/change-password - Change user password
|
|
7
|
-
* - PATCH /auth/me - Update profile (name, picture) [requires backend support]
|
|
8
|
-
*/
|
|
9
|
-
export declare class ProfileApiClient {
|
|
10
|
-
private client;
|
|
11
|
-
constructor(baseUrl: string, timeoutMs?: number, retryAttempts?: number, getAccessToken?: () => string | null);
|
|
12
|
-
/**
|
|
13
|
-
* Change the user's password
|
|
14
|
-
*
|
|
15
|
-
* Requires the current password for verification. Also revokes all other sessions
|
|
16
|
-
* and re-encrypts wallet Share A if using password-based wallet protection.
|
|
17
|
-
*/
|
|
18
|
-
changePassword(data: ChangePasswordRequest): Promise<ChangePasswordResponse>;
|
|
19
|
-
/**
|
|
20
|
-
* Update user profile (name, picture)
|
|
21
|
-
*
|
|
22
|
-
* NOTE: Requires PATCH /auth/me endpoint on the backend.
|
|
23
|
-
* If not implemented, returns a rejection.
|
|
24
|
-
*/
|
|
25
|
-
updateProfile(data: UpdateProfileRequest): Promise<UpdateProfileResponse>;
|
|
26
|
-
}
|