@thunderid/react 0.0.1
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/LICENSE +201 -0
- package/dist/ThunderIDReactClient.d.ts +87 -0
- package/dist/ThunderIDReactClient.d.ts.map +1 -0
- package/dist/__temp__/api.d.ts +258 -0
- package/dist/__temp__/api.d.ts.map +1 -0
- package/dist/__temp__/models.d.ts +98 -0
- package/dist/__temp__/models.d.ts.map +1 -0
- package/dist/api/createOrganization.d.ts +86 -0
- package/dist/api/createOrganization.d.ts.map +1 -0
- package/dist/api/getAllOrganizations.d.ts +78 -0
- package/dist/api/getAllOrganizations.d.ts.map +1 -0
- package/dist/api/getMeOrganizations.d.ts +82 -0
- package/dist/api/getMeOrganizations.d.ts.map +1 -0
- package/dist/api/getOrganization.d.ts +74 -0
- package/dist/api/getOrganization.d.ts.map +1 -0
- package/dist/api/getSchemas.d.ts +72 -0
- package/dist/api/getSchemas.d.ts.map +1 -0
- package/dist/api/getScim2Me.d.ts +72 -0
- package/dist/api/getScim2Me.d.ts.map +1 -0
- package/dist/api/updateMeProfile.d.ts +60 -0
- package/dist/api/updateMeProfile.d.ts.map +1 -0
- package/dist/api/updateOrganization.d.ts +81 -0
- package/dist/api/updateOrganization.d.ts.map +1 -0
- package/dist/cjs/index.js +20320 -0
- package/dist/cjs/index.js.map +1 -0
- package/dist/components/actions/SignInButton/BaseSignInButton.d.ts +71 -0
- package/dist/components/actions/SignInButton/BaseSignInButton.d.ts.map +1 -0
- package/dist/components/actions/SignInButton/SignInButton.d.ts +71 -0
- package/dist/components/actions/SignInButton/SignInButton.d.ts.map +1 -0
- package/dist/components/actions/SignOutButton/BaseSignOutButton.d.ts +71 -0
- package/dist/components/actions/SignOutButton/BaseSignOutButton.d.ts.map +1 -0
- package/dist/components/actions/SignOutButton/SignOutButton.d.ts +66 -0
- package/dist/components/actions/SignOutButton/SignOutButton.d.ts.map +1 -0
- package/dist/components/actions/SignUpButton/BaseSignUpButton.d.ts +71 -0
- package/dist/components/actions/SignUpButton/BaseSignUpButton.d.ts.map +1 -0
- package/dist/components/actions/SignUpButton/SignUpButton.d.ts +67 -0
- package/dist/components/actions/SignUpButton/SignUpButton.d.ts.map +1 -0
- package/dist/components/adapters/CheckboxInput.d.ts +25 -0
- package/dist/components/adapters/CheckboxInput.d.ts.map +1 -0
- package/dist/components/adapters/Consent.d.ts +80 -0
- package/dist/components/adapters/Consent.d.ts.map +1 -0
- package/dist/components/adapters/ConsentCheckboxList.d.ts +95 -0
- package/dist/components/adapters/ConsentCheckboxList.d.ts.map +1 -0
- package/dist/components/adapters/ConsentCheckboxList.styles.d.ts +21 -0
- package/dist/components/adapters/ConsentCheckboxList.styles.d.ts.map +1 -0
- package/dist/components/adapters/DateInput.d.ts +25 -0
- package/dist/components/adapters/DateInput.d.ts.map +1 -0
- package/dist/components/adapters/DividerComponent.d.ts +25 -0
- package/dist/components/adapters/DividerComponent.d.ts.map +1 -0
- package/dist/components/adapters/EmailInput.d.ts +25 -0
- package/dist/components/adapters/EmailInput.d.ts.map +1 -0
- package/dist/components/adapters/FacebookButton.d.ts +32 -0
- package/dist/components/adapters/FacebookButton.d.ts.map +1 -0
- package/dist/components/adapters/FlowTimer.d.ts +63 -0
- package/dist/components/adapters/FlowTimer.d.ts.map +1 -0
- package/dist/components/adapters/FormContainer.d.ts +25 -0
- package/dist/components/adapters/FormContainer.d.ts.map +1 -0
- package/dist/components/adapters/GitHubButton.d.ts +32 -0
- package/dist/components/adapters/GitHubButton.d.ts.map +1 -0
- package/dist/components/adapters/GoogleButton.d.ts +32 -0
- package/dist/components/adapters/GoogleButton.d.ts.map +1 -0
- package/dist/components/adapters/ImageComponent.d.ts +25 -0
- package/dist/components/adapters/ImageComponent.d.ts.map +1 -0
- package/dist/components/adapters/LinkedInButton.d.ts +32 -0
- package/dist/components/adapters/LinkedInButton.d.ts.map +1 -0
- package/dist/components/adapters/MicrosoftButton.d.ts +32 -0
- package/dist/components/adapters/MicrosoftButton.d.ts.map +1 -0
- package/dist/components/adapters/NumberInput.d.ts +25 -0
- package/dist/components/adapters/NumberInput.d.ts.map +1 -0
- package/dist/components/adapters/PasswordInput.d.ts +25 -0
- package/dist/components/adapters/PasswordInput.d.ts.map +1 -0
- package/dist/components/adapters/SelectInput.d.ts +25 -0
- package/dist/components/adapters/SelectInput.d.ts.map +1 -0
- package/dist/components/adapters/SignInWithEthereumButton.d.ts +32 -0
- package/dist/components/adapters/SignInWithEthereumButton.d.ts.map +1 -0
- package/dist/components/adapters/SmsOtpButton.d.ts +32 -0
- package/dist/components/adapters/SmsOtpButton.d.ts.map +1 -0
- package/dist/components/adapters/SocialButton.d.ts +25 -0
- package/dist/components/adapters/SocialButton.d.ts.map +1 -0
- package/dist/components/adapters/SubmitButton.d.ts +25 -0
- package/dist/components/adapters/SubmitButton.d.ts.map +1 -0
- package/dist/components/adapters/TelephoneInput.d.ts +25 -0
- package/dist/components/adapters/TelephoneInput.d.ts.map +1 -0
- package/dist/components/adapters/TextInput.d.ts +25 -0
- package/dist/components/adapters/TextInput.d.ts.map +1 -0
- package/dist/components/adapters/Typography.d.ts +25 -0
- package/dist/components/adapters/Typography.d.ts.map +1 -0
- package/dist/components/auth/Callback/Callback.d.ts +52 -0
- package/dist/components/auth/Callback/Callback.d.ts.map +1 -0
- package/dist/components/control/Loading.d.ts +48 -0
- package/dist/components/control/Loading.d.ts.map +1 -0
- package/dist/components/control/OrganizationContext/OrganizationContext.d.ts +40 -0
- package/dist/components/control/OrganizationContext/OrganizationContext.d.ts.map +1 -0
- package/dist/components/control/OrganizationContext/OrganizationContextController.d.ts +35 -0
- package/dist/components/control/OrganizationContext/OrganizationContextController.d.ts.map +1 -0
- package/dist/components/control/SignedIn.d.ts +48 -0
- package/dist/components/control/SignedIn.d.ts.map +1 -0
- package/dist/components/control/SignedOut.d.ts +48 -0
- package/dist/components/control/SignedOut.d.ts.map +1 -0
- package/dist/components/factories/FieldFactory.d.ts +107 -0
- package/dist/components/factories/FieldFactory.d.ts.map +1 -0
- package/dist/components/presentation/CreateOrganization/BaseCreateOrganization.d.ts +60 -0
- package/dist/components/presentation/CreateOrganization/BaseCreateOrganization.d.ts.map +1 -0
- package/dist/components/presentation/CreateOrganization/BaseCreateOrganization.styles.d.ts +27 -0
- package/dist/components/presentation/CreateOrganization/BaseCreateOrganization.styles.d.ts.map +1 -0
- package/dist/components/presentation/CreateOrganization/CreateOrganization.d.ts +68 -0
- package/dist/components/presentation/CreateOrganization/CreateOrganization.d.ts.map +1 -0
- package/dist/components/presentation/LanguageSwitcher/BaseLanguageSwitcher.d.ts +80 -0
- package/dist/components/presentation/LanguageSwitcher/BaseLanguageSwitcher.d.ts.map +1 -0
- package/dist/components/presentation/LanguageSwitcher/BaseLanguageSwitcher.styles.d.ts +21 -0
- package/dist/components/presentation/LanguageSwitcher/BaseLanguageSwitcher.styles.d.ts.map +1 -0
- package/dist/components/presentation/LanguageSwitcher/LanguageSwitcher.d.ts +78 -0
- package/dist/components/presentation/LanguageSwitcher/LanguageSwitcher.d.ts.map +1 -0
- package/dist/components/presentation/Organization/BaseOrganization.d.ts +67 -0
- package/dist/components/presentation/Organization/BaseOrganization.d.ts.map +1 -0
- package/dist/components/presentation/Organization/Organization.d.ts +67 -0
- package/dist/components/presentation/Organization/Organization.d.ts.map +1 -0
- package/dist/components/presentation/OrganizationList/BaseOrganizationList.d.ts +135 -0
- package/dist/components/presentation/OrganizationList/BaseOrganizationList.d.ts.map +1 -0
- package/dist/components/presentation/OrganizationList/BaseOrganizationList.styles.d.ts +27 -0
- package/dist/components/presentation/OrganizationList/BaseOrganizationList.styles.d.ts.map +1 -0
- package/dist/components/presentation/OrganizationList/OrganizationList.d.ts +93 -0
- package/dist/components/presentation/OrganizationList/OrganizationList.d.ts.map +1 -0
- package/dist/components/presentation/OrganizationList/OrganizationList.styles.d.ts +27 -0
- package/dist/components/presentation/OrganizationList/OrganizationList.styles.d.ts.map +1 -0
- package/dist/components/presentation/OrganizationProfile/BaseOrganizationProfile.d.ts +160 -0
- package/dist/components/presentation/OrganizationProfile/BaseOrganizationProfile.d.ts.map +1 -0
- package/dist/components/presentation/OrganizationProfile/BaseOrganizationProfile.styles.d.ts +27 -0
- package/dist/components/presentation/OrganizationProfile/BaseOrganizationProfile.styles.d.ts.map +1 -0
- package/dist/components/presentation/OrganizationProfile/OrganizationProfile.d.ts +120 -0
- package/dist/components/presentation/OrganizationProfile/OrganizationProfile.d.ts.map +1 -0
- package/dist/components/presentation/OrganizationSwitcher/BaseOrganizationSwitcher.d.ts +149 -0
- package/dist/components/presentation/OrganizationSwitcher/BaseOrganizationSwitcher.d.ts.map +1 -0
- package/dist/components/presentation/OrganizationSwitcher/BaseOrganizationSwitcher.styles.d.ts +27 -0
- package/dist/components/presentation/OrganizationSwitcher/BaseOrganizationSwitcher.styles.d.ts.map +1 -0
- package/dist/components/presentation/OrganizationSwitcher/OrganizationSwitcher.d.ts +71 -0
- package/dist/components/presentation/OrganizationSwitcher/OrganizationSwitcher.d.ts.map +1 -0
- package/dist/components/presentation/User/BaseUser.d.ts +67 -0
- package/dist/components/presentation/User/BaseUser.d.ts.map +1 -0
- package/dist/components/presentation/User/User.d.ts +63 -0
- package/dist/components/presentation/User/User.d.ts.map +1 -0
- package/dist/components/presentation/UserDropdown/BaseUserDropdown.d.ts +89 -0
- package/dist/components/presentation/UserDropdown/BaseUserDropdown.d.ts.map +1 -0
- package/dist/components/presentation/UserDropdown/BaseUserDropdown.styles.d.ts +27 -0
- package/dist/components/presentation/UserDropdown/BaseUserDropdown.styles.d.ts.map +1 -0
- package/dist/components/presentation/UserDropdown/UserDropdown.d.ts +109 -0
- package/dist/components/presentation/UserDropdown/UserDropdown.d.ts.map +1 -0
- package/dist/components/presentation/UserProfile/BaseUserProfile.d.ts +73 -0
- package/dist/components/presentation/UserProfile/BaseUserProfile.d.ts.map +1 -0
- package/dist/components/presentation/UserProfile/BaseUserProfile.styles.d.ts +27 -0
- package/dist/components/presentation/UserProfile/BaseUserProfile.styles.d.ts.map +1 -0
- package/dist/components/presentation/UserProfile/UserProfile.d.ts +60 -0
- package/dist/components/presentation/UserProfile/UserProfile.d.ts.map +1 -0
- package/dist/components/presentation/auth/AcceptInvite/index.d.ts +22 -0
- package/dist/components/presentation/auth/AcceptInvite/index.d.ts.map +1 -0
- package/dist/components/presentation/auth/AcceptInvite/v2/AcceptInvite.d.ts +125 -0
- package/dist/components/presentation/auth/AcceptInvite/v2/AcceptInvite.d.ts.map +1 -0
- package/dist/components/presentation/auth/AcceptInvite/v2/BaseAcceptInvite.d.ts +202 -0
- package/dist/components/presentation/auth/AcceptInvite/v2/BaseAcceptInvite.d.ts.map +1 -0
- package/dist/components/presentation/auth/AcceptInvite/v2/BaseAcceptInvite.styles.d.ts +27 -0
- package/dist/components/presentation/auth/AcceptInvite/v2/BaseAcceptInvite.styles.d.ts.map +1 -0
- package/dist/components/presentation/auth/AuthOptionFactory.d.ts +114 -0
- package/dist/components/presentation/auth/AuthOptionFactory.d.ts.map +1 -0
- package/dist/components/presentation/auth/InviteUser/index.d.ts +22 -0
- package/dist/components/presentation/auth/InviteUser/index.d.ts.map +1 -0
- package/dist/components/presentation/auth/InviteUser/v2/BaseInviteUser.d.ts +191 -0
- package/dist/components/presentation/auth/InviteUser/v2/BaseInviteUser.d.ts.map +1 -0
- package/dist/components/presentation/auth/InviteUser/v2/BaseInviteUser.styles.d.ts +27 -0
- package/dist/components/presentation/auth/InviteUser/v2/BaseInviteUser.styles.d.ts.map +1 -0
- package/dist/components/presentation/auth/InviteUser/v2/InviteUser.d.ts +104 -0
- package/dist/components/presentation/auth/InviteUser/v2/InviteUser.d.ts.map +1 -0
- package/dist/components/presentation/auth/OrganizationUnitPicker/index.d.ts +20 -0
- package/dist/components/presentation/auth/OrganizationUnitPicker/index.d.ts.map +1 -0
- package/dist/components/presentation/auth/OrganizationUnitPicker/v2/OrganizationUnitPicker.d.ts +30 -0
- package/dist/components/presentation/auth/OrganizationUnitPicker/v2/OrganizationUnitPicker.d.ts.map +1 -0
- package/dist/components/presentation/auth/OrganizationUnitPicker/v2/OrganizationUnitPicker.styles.d.ts +21 -0
- package/dist/components/presentation/auth/OrganizationUnitPicker/v2/OrganizationUnitPicker.styles.d.ts.map +1 -0
- package/dist/components/presentation/auth/Recovery/BaseRecovery.d.ts +24 -0
- package/dist/components/presentation/auth/Recovery/BaseRecovery.d.ts.map +1 -0
- package/dist/components/presentation/auth/Recovery/Recovery.d.ts +57 -0
- package/dist/components/presentation/auth/Recovery/Recovery.d.ts.map +1 -0
- package/dist/components/presentation/auth/Recovery/v1/BaseRecovery.d.ts +74 -0
- package/dist/components/presentation/auth/Recovery/v1/BaseRecovery.d.ts.map +1 -0
- package/dist/components/presentation/auth/Recovery/v1/Recovery.d.ts +26 -0
- package/dist/components/presentation/auth/Recovery/v1/Recovery.d.ts.map +1 -0
- package/dist/components/presentation/auth/Recovery/v1/RecoveryOptionFactory.d.ts +46 -0
- package/dist/components/presentation/auth/Recovery/v1/RecoveryOptionFactory.d.ts.map +1 -0
- package/dist/components/presentation/auth/Recovery/v2/BaseRecovery.d.ts +83 -0
- package/dist/components/presentation/auth/Recovery/v2/BaseRecovery.d.ts.map +1 -0
- package/dist/components/presentation/auth/Recovery/v2/Recovery.d.ts +56 -0
- package/dist/components/presentation/auth/Recovery/v2/Recovery.d.ts.map +1 -0
- package/dist/components/presentation/auth/SignIn/BaseSignIn.d.ts +28 -0
- package/dist/components/presentation/auth/SignIn/BaseSignIn.d.ts.map +1 -0
- package/dist/components/presentation/auth/SignIn/BaseSignIn.styles.d.ts +27 -0
- package/dist/components/presentation/auth/SignIn/BaseSignIn.styles.d.ts.map +1 -0
- package/dist/components/presentation/auth/SignIn/SignIn.d.ts +63 -0
- package/dist/components/presentation/auth/SignIn/SignIn.d.ts.map +1 -0
- package/dist/components/presentation/auth/SignIn/v1/BaseSignIn.d.ts +131 -0
- package/dist/components/presentation/auth/SignIn/v1/BaseSignIn.d.ts.map +1 -0
- package/dist/components/presentation/auth/SignIn/v1/options/EmailOtp.d.ts +26 -0
- package/dist/components/presentation/auth/SignIn/v1/options/EmailOtp.d.ts.map +1 -0
- package/dist/components/presentation/auth/SignIn/v1/options/IdentifierFirst.d.ts +26 -0
- package/dist/components/presentation/auth/SignIn/v1/options/IdentifierFirst.d.ts.map +1 -0
- package/dist/components/presentation/auth/SignIn/v1/options/MultiOptionButton.d.ts +27 -0
- package/dist/components/presentation/auth/SignIn/v1/options/MultiOptionButton.d.ts.map +1 -0
- package/dist/components/presentation/auth/SignIn/v1/options/SignInOptionFactory.d.ts +77 -0
- package/dist/components/presentation/auth/SignIn/v1/options/SignInOptionFactory.d.ts.map +1 -0
- package/dist/components/presentation/auth/SignIn/v1/options/SmsOtp.d.ts +26 -0
- package/dist/components/presentation/auth/SignIn/v1/options/SmsOtp.d.ts.map +1 -0
- package/dist/components/presentation/auth/SignIn/v1/options/SocialButton.d.ts +26 -0
- package/dist/components/presentation/auth/SignIn/v1/options/SocialButton.d.ts.map +1 -0
- package/dist/components/presentation/auth/SignIn/v1/options/Totp.d.ts +26 -0
- package/dist/components/presentation/auth/SignIn/v1/options/Totp.d.ts.map +1 -0
- package/dist/components/presentation/auth/SignIn/v1/options/UsernamePassword.d.ts +26 -0
- package/dist/components/presentation/auth/SignIn/v1/options/UsernamePassword.d.ts.map +1 -0
- package/dist/components/presentation/auth/SignIn/v1/types.d.ts +125 -0
- package/dist/components/presentation/auth/SignIn/v1/types.d.ts.map +1 -0
- package/dist/components/presentation/auth/SignIn/v2/BaseSignIn.d.ts +222 -0
- package/dist/components/presentation/auth/SignIn/v2/BaseSignIn.d.ts.map +1 -0
- package/dist/components/presentation/auth/SignIn/v2/SignIn.d.ts +165 -0
- package/dist/components/presentation/auth/SignIn/v2/SignIn.d.ts.map +1 -0
- package/dist/components/presentation/auth/SignUp/BaseSignUp.d.ts +28 -0
- package/dist/components/presentation/auth/SignUp/BaseSignUp.d.ts.map +1 -0
- package/dist/components/presentation/auth/SignUp/BaseSignUp.styles.d.ts +27 -0
- package/dist/components/presentation/auth/SignUp/BaseSignUp.styles.d.ts.map +1 -0
- package/dist/components/presentation/auth/SignUp/SignUp.d.ts +98 -0
- package/dist/components/presentation/auth/SignUp/SignUp.d.ts.map +1 -0
- package/dist/components/presentation/auth/SignUp/v1/BaseSignUp.d.ts +174 -0
- package/dist/components/presentation/auth/SignUp/v1/BaseSignUp.d.ts.map +1 -0
- package/dist/components/presentation/auth/SignUp/v1/SignUp.d.ts +39 -0
- package/dist/components/presentation/auth/SignUp/v1/SignUp.d.ts.map +1 -0
- package/dist/components/presentation/auth/SignUp/v1/SignUpOptionFactory.d.ts +46 -0
- package/dist/components/presentation/auth/SignUp/v1/SignUpOptionFactory.d.ts.map +1 -0
- package/dist/components/presentation/auth/SignUp/v2/BaseSignUp.d.ts +186 -0
- package/dist/components/presentation/auth/SignUp/v2/BaseSignUp.d.ts.map +1 -0
- package/dist/components/presentation/auth/SignUp/v2/SignUp.d.ts +39 -0
- package/dist/components/presentation/auth/SignUp/v2/SignUp.d.ts.map +1 -0
- package/dist/components/primitives/Alert/Alert.d.ts +76 -0
- package/dist/components/primitives/Alert/Alert.d.ts.map +1 -0
- package/dist/components/primitives/Alert/Alert.styles.d.ts +29 -0
- package/dist/components/primitives/Alert/Alert.styles.d.ts.map +1 -0
- package/dist/components/primitives/Avatar/Avatar.d.ts +60 -0
- package/dist/components/primitives/Avatar/Avatar.d.ts.map +1 -0
- package/dist/components/primitives/Avatar/Avatar.styles.d.ts +31 -0
- package/dist/components/primitives/Avatar/Avatar.styles.d.ts.map +1 -0
- package/dist/components/primitives/Button/Button.d.ts +88 -0
- package/dist/components/primitives/Button/Button.d.ts.map +1 -0
- package/dist/components/primitives/Button/Button.styles.d.ts +36 -0
- package/dist/components/primitives/Button/Button.styles.d.ts.map +1 -0
- package/dist/components/primitives/Card/Card.d.ts +133 -0
- package/dist/components/primitives/Card/Card.d.ts.map +1 -0
- package/dist/components/primitives/Card/Card.styles.d.ts +30 -0
- package/dist/components/primitives/Card/Card.styles.d.ts.map +1 -0
- package/dist/components/primitives/Checkbox/Checkbox.d.ts +43 -0
- package/dist/components/primitives/Checkbox/Checkbox.d.ts.map +1 -0
- package/dist/components/primitives/Checkbox/Checkbox.styles.d.ts +29 -0
- package/dist/components/primitives/Checkbox/Checkbox.styles.d.ts.map +1 -0
- package/dist/components/primitives/CopyableText/CopyableText.d.ts +37 -0
- package/dist/components/primitives/CopyableText/CopyableText.d.ts.map +1 -0
- package/dist/components/primitives/CopyableText/CopyableText.styles.d.ts +21 -0
- package/dist/components/primitives/CopyableText/CopyableText.styles.d.ts.map +1 -0
- package/dist/components/primitives/CopyableText/index.d.ts +20 -0
- package/dist/components/primitives/CopyableText/index.d.ts.map +1 -0
- package/dist/components/primitives/DatePicker/DatePicker.d.ts +51 -0
- package/dist/components/primitives/DatePicker/DatePicker.d.ts.map +1 -0
- package/dist/components/primitives/DatePicker/DatePicker.styles.d.ts +29 -0
- package/dist/components/primitives/DatePicker/DatePicker.styles.d.ts.map +1 -0
- package/dist/components/primitives/Dialog/Dialog.d.ts +62 -0
- package/dist/components/primitives/Dialog/Dialog.d.ts.map +1 -0
- package/dist/components/primitives/Dialog/Dialog.styles.d.ts +27 -0
- package/dist/components/primitives/Dialog/Dialog.styles.d.ts.map +1 -0
- package/dist/components/primitives/Divider/Divider.d.ts +59 -0
- package/dist/components/primitives/Divider/Divider.d.ts.map +1 -0
- package/dist/components/primitives/Divider/Divider.styles.d.ts +33 -0
- package/dist/components/primitives/Divider/Divider.styles.d.ts.map +1 -0
- package/dist/components/primitives/FormControl/FormControl.d.ts +52 -0
- package/dist/components/primitives/FormControl/FormControl.d.ts.map +1 -0
- package/dist/components/primitives/FormControl/FormControl.styles.d.ts +31 -0
- package/dist/components/primitives/FormControl/FormControl.styles.d.ts.map +1 -0
- package/dist/components/primitives/Icons/ArrowLeftRight.d.ts +30 -0
- package/dist/components/primitives/Icons/ArrowLeftRight.d.ts.map +1 -0
- package/dist/components/primitives/Icons/ArrowRightLeft.d.ts +30 -0
- package/dist/components/primitives/Icons/ArrowRightLeft.d.ts.map +1 -0
- package/dist/components/primitives/Icons/Building.d.ts +41 -0
- package/dist/components/primitives/Icons/Building.d.ts.map +1 -0
- package/dist/components/primitives/Icons/BuildingAlt.d.ts +41 -0
- package/dist/components/primitives/Icons/BuildingAlt.d.ts.map +1 -0
- package/dist/components/primitives/Icons/Check.d.ts +41 -0
- package/dist/components/primitives/Icons/Check.d.ts.map +1 -0
- package/dist/components/primitives/Icons/ChevronDown.d.ts +41 -0
- package/dist/components/primitives/Icons/ChevronDown.d.ts.map +1 -0
- package/dist/components/primitives/Icons/CircleAlert.d.ts +24 -0
- package/dist/components/primitives/Icons/CircleAlert.d.ts.map +1 -0
- package/dist/components/primitives/Icons/CircleCheck.d.ts +24 -0
- package/dist/components/primitives/Icons/CircleCheck.d.ts.map +1 -0
- package/dist/components/primitives/Icons/Eye.d.ts +24 -0
- package/dist/components/primitives/Icons/Eye.d.ts.map +1 -0
- package/dist/components/primitives/Icons/EyeOff.d.ts +24 -0
- package/dist/components/primitives/Icons/EyeOff.d.ts.map +1 -0
- package/dist/components/primitives/Icons/Info.d.ts +24 -0
- package/dist/components/primitives/Icons/Info.d.ts.map +1 -0
- package/dist/components/primitives/Icons/LogOut.d.ts +24 -0
- package/dist/components/primitives/Icons/LogOut.d.ts.map +1 -0
- package/dist/components/primitives/Icons/Plus.d.ts +24 -0
- package/dist/components/primitives/Icons/Plus.d.ts.map +1 -0
- package/dist/components/primitives/Icons/Settings.d.ts +1 -0
- package/dist/components/primitives/Icons/Settings.d.ts.map +1 -0
- package/dist/components/primitives/Icons/TriangleAlert.d.ts +24 -0
- package/dist/components/primitives/Icons/TriangleAlert.d.ts.map +1 -0
- package/dist/components/primitives/Icons/User.d.ts +24 -0
- package/dist/components/primitives/Icons/User.d.ts.map +1 -0
- package/dist/components/primitives/Icons/X.d.ts +24 -0
- package/dist/components/primitives/Icons/X.d.ts.map +1 -0
- package/dist/components/primitives/Icons/flowIconRegistry.d.ts +29 -0
- package/dist/components/primitives/Icons/flowIconRegistry.d.ts.map +1 -0
- package/dist/components/primitives/Icons/index.d.ts +29 -0
- package/dist/components/primitives/Icons/index.d.ts.map +1 -0
- package/dist/components/primitives/InputLabel/InputLabel.d.ts +52 -0
- package/dist/components/primitives/InputLabel/InputLabel.d.ts.map +1 -0
- package/dist/components/primitives/InputLabel/InputLabel.styles.d.ts +31 -0
- package/dist/components/primitives/InputLabel/InputLabel.styles.d.ts.map +1 -0
- package/dist/components/primitives/KeyValueInput/KeyValueInput.d.ts +124 -0
- package/dist/components/primitives/KeyValueInput/KeyValueInput.d.ts.map +1 -0
- package/dist/components/primitives/KeyValueInput/KeyValueInput.styles.d.ts +30 -0
- package/dist/components/primitives/KeyValueInput/KeyValueInput.styles.d.ts.map +1 -0
- package/dist/components/primitives/Logo/Logo.d.ts +53 -0
- package/dist/components/primitives/Logo/Logo.d.ts.map +1 -0
- package/dist/components/primitives/Logo/Logo.styles.d.ts +29 -0
- package/dist/components/primitives/Logo/Logo.styles.d.ts.map +1 -0
- package/dist/components/primitives/MultiInput/MultiInput.d.ts +89 -0
- package/dist/components/primitives/MultiInput/MultiInput.d.ts.map +1 -0
- package/dist/components/primitives/MultiInput/MultiInput.styles.d.ts +33 -0
- package/dist/components/primitives/MultiInput/MultiInput.styles.d.ts.map +1 -0
- package/dist/components/primitives/OtpField/OtpField.d.ts +88 -0
- package/dist/components/primitives/OtpField/OtpField.d.ts.map +1 -0
- package/dist/components/primitives/OtpField/OtpField.styles.d.ts +31 -0
- package/dist/components/primitives/OtpField/OtpField.styles.d.ts.map +1 -0
- package/dist/components/primitives/PasswordField/PasswordField.d.ts +32 -0
- package/dist/components/primitives/PasswordField/PasswordField.d.ts.map +1 -0
- package/dist/components/primitives/PasswordField/PasswordField.styles.d.ts +30 -0
- package/dist/components/primitives/PasswordField/PasswordField.styles.d.ts.map +1 -0
- package/dist/components/primitives/Select/Select.d.ts +65 -0
- package/dist/components/primitives/Select/Select.d.ts.map +1 -0
- package/dist/components/primitives/Select/Select.styles.d.ts +29 -0
- package/dist/components/primitives/Select/Select.styles.d.ts.map +1 -0
- package/dist/components/primitives/Spinner/Spinner.d.ts +55 -0
- package/dist/components/primitives/Spinner/Spinner.d.ts.map +1 -0
- package/dist/components/primitives/Spinner/Spinner.styles.d.ts +30 -0
- package/dist/components/primitives/Spinner/Spinner.styles.d.ts.map +1 -0
- package/dist/components/primitives/TextField/TextField.d.ts +63 -0
- package/dist/components/primitives/TextField/TextField.d.ts.map +1 -0
- package/dist/components/primitives/TextField/TextField.styles.d.ts +31 -0
- package/dist/components/primitives/TextField/TextField.styles.d.ts.map +1 -0
- package/dist/components/primitives/Toggle/Toggle.d.ts +41 -0
- package/dist/components/primitives/Toggle/Toggle.d.ts.map +1 -0
- package/dist/components/primitives/Toggle/Toggle.styles.d.ts +21 -0
- package/dist/components/primitives/Toggle/Toggle.styles.d.ts.map +1 -0
- package/dist/components/primitives/Typography/Typography.d.ts +80 -0
- package/dist/components/primitives/Typography/Typography.d.ts.map +1 -0
- package/dist/components/primitives/Typography/Typography.styles.d.ts +39 -0
- package/dist/components/primitives/Typography/Typography.styles.d.ts.map +1 -0
- package/dist/contexts/Branding/BrandingContext.d.ts +53 -0
- package/dist/contexts/Branding/BrandingContext.d.ts.map +1 -0
- package/dist/contexts/Branding/BrandingProvider.d.ts +89 -0
- package/dist/contexts/Branding/BrandingProvider.d.ts.map +1 -0
- package/dist/contexts/Branding/useBrandingContext.d.ts +45 -0
- package/dist/contexts/Branding/useBrandingContext.d.ts.map +1 -0
- package/dist/contexts/ComponentRenderer/ComponentRendererContext.d.ts +37 -0
- package/dist/contexts/ComponentRenderer/ComponentRendererContext.d.ts.map +1 -0
- package/dist/contexts/ComponentRenderer/ComponentRendererProvider.d.ts +25 -0
- package/dist/contexts/ComponentRenderer/ComponentRendererProvider.d.ts.map +1 -0
- package/dist/contexts/Flow/FlowContext.d.ts +75 -0
- package/dist/contexts/Flow/FlowContext.d.ts.map +1 -0
- package/dist/contexts/Flow/FlowProvider.d.ts +47 -0
- package/dist/contexts/Flow/FlowProvider.d.ts.map +1 -0
- package/dist/contexts/Flow/useFlow.d.ts +49 -0
- package/dist/contexts/Flow/useFlow.d.ts.map +1 -0
- package/dist/contexts/FlowMeta/FlowMetaContext.d.ts +45 -0
- package/dist/contexts/FlowMeta/FlowMetaContext.d.ts.map +1 -0
- package/dist/contexts/FlowMeta/FlowMetaProvider.d.ts +51 -0
- package/dist/contexts/FlowMeta/FlowMetaProvider.d.ts.map +1 -0
- package/dist/contexts/FlowMeta/useFlowMeta.d.ts +21 -0
- package/dist/contexts/FlowMeta/useFlowMeta.d.ts.map +1 -0
- package/dist/contexts/I18n/ComponentPreferencesContext.d.ts +27 -0
- package/dist/contexts/I18n/ComponentPreferencesContext.d.ts.map +1 -0
- package/dist/contexts/I18n/I18nContext.d.ts +49 -0
- package/dist/contexts/I18n/I18nContext.d.ts.map +1 -0
- package/dist/contexts/I18n/I18nProvider.d.ts +32 -0
- package/dist/contexts/I18n/I18nProvider.d.ts.map +1 -0
- package/dist/contexts/I18n/useI18n.d.ts +28 -0
- package/dist/contexts/I18n/useI18n.d.ts.map +1 -0
- package/dist/contexts/Organization/OrganizationContext.d.ts +41 -0
- package/dist/contexts/Organization/OrganizationContext.d.ts.map +1 -0
- package/dist/contexts/Organization/OrganizationProvider.d.ts +94 -0
- package/dist/contexts/Organization/OrganizationProvider.d.ts.map +1 -0
- package/dist/contexts/Organization/useOrganization.d.ts +105 -0
- package/dist/contexts/Organization/useOrganization.d.ts.map +1 -0
- package/dist/contexts/Theme/ThemeContext.d.ts +43 -0
- package/dist/contexts/Theme/ThemeContext.d.ts.map +1 -0
- package/dist/contexts/Theme/ThemeProvider.d.ts +86 -0
- package/dist/contexts/Theme/ThemeProvider.d.ts.map +1 -0
- package/dist/contexts/Theme/types.d.ts +131 -0
- package/dist/contexts/Theme/types.d.ts.map +1 -0
- package/dist/contexts/Theme/useTheme.d.ts +21 -0
- package/dist/contexts/Theme/useTheme.d.ts.map +1 -0
- package/dist/contexts/Theme/v1/ThemeProvider.d.ts +89 -0
- package/dist/contexts/Theme/v1/ThemeProvider.d.ts.map +1 -0
- package/dist/contexts/Theme/v2/ThemeProvider.d.ts +58 -0
- package/dist/contexts/Theme/v2/ThemeProvider.d.ts.map +1 -0
- package/dist/contexts/ThunderID/ThunderIDContext.d.ts +184 -0
- package/dist/contexts/ThunderID/ThunderIDContext.d.ts.map +1 -0
- package/dist/contexts/ThunderID/ThunderIDProvider.d.ts +26 -0
- package/dist/contexts/ThunderID/ThunderIDProvider.d.ts.map +1 -0
- package/dist/contexts/ThunderID/useThunderID.d.ts +21 -0
- package/dist/contexts/ThunderID/useThunderID.d.ts.map +1 -0
- package/dist/contexts/User/UserContext.d.ts +42 -0
- package/dist/contexts/User/UserContext.d.ts.map +1 -0
- package/dist/contexts/User/UserProvider.d.ts +65 -0
- package/dist/contexts/User/UserProvider.d.ts.map +1 -0
- package/dist/contexts/User/useUser.d.ts +95 -0
- package/dist/contexts/User/useUser.d.ts.map +1 -0
- package/dist/hooks/useBranding.d.ts +128 -0
- package/dist/hooks/useBranding.d.ts.map +1 -0
- package/dist/hooks/useBrowserUrl.d.ts +56 -0
- package/dist/hooks/useBrowserUrl.d.ts.map +1 -0
- package/dist/hooks/useForm.d.ts +194 -0
- package/dist/hooks/useForm.d.ts.map +1 -0
- package/dist/hooks/useTranslation.d.ts +53 -0
- package/dist/hooks/useTranslation.d.ts.map +1 -0
- package/dist/hooks/v2/useOAuthCallback.d.ts +83 -0
- package/dist/hooks/v2/useOAuthCallback.d.ts.map +1 -0
- package/dist/index.d.ts +206 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +20044 -0
- package/dist/index.js.map +1 -0
- package/dist/models/adapters.d.ts +69 -0
- package/dist/models/adapters.d.ts.map +1 -0
- package/dist/models/config.d.ts +20 -0
- package/dist/models/config.d.ts.map +1 -0
- package/dist/utils/applyThemeToDOM.d.ts +25 -0
- package/dist/utils/applyThemeToDOM.d.ts.map +1 -0
- package/dist/utils/getDisplayName.d.ts +44 -0
- package/dist/utils/getDisplayName.d.ts.map +1 -0
- package/dist/utils/getMappedUserProfileValue.d.ts +52 -0
- package/dist/utils/getMappedUserProfileValue.d.ts.map +1 -0
- package/dist/utils/normalizeThemeConfig.d.ts +31 -0
- package/dist/utils/normalizeThemeConfig.d.ts.map +1 -0
- package/dist/utils/oauth.d.ts +25 -0
- package/dist/utils/oauth.d.ts.map +1 -0
- package/dist/utils/v2/buildThemeConfigFromFlowMeta.d.ts +34 -0
- package/dist/utils/v2/buildThemeConfigFromFlowMeta.d.ts.map +1 -0
- package/dist/utils/v2/flowTransformer.d.ts +121 -0
- package/dist/utils/v2/flowTransformer.d.ts.map +1 -0
- package/dist/utils/v2/getAuthComponentHeadings.d.ts +70 -0
- package/dist/utils/v2/getAuthComponentHeadings.d.ts.map +1 -0
- package/dist/utils/v2/passkey.d.ts +32 -0
- package/dist/utils/v2/passkey.d.ts.map +1 -0
- package/dist/utils/v2/resolveTranslationsInArray.d.ts +30 -0
- package/dist/utils/v2/resolveTranslationsInArray.d.ts.map +1 -0
- package/dist/utils/v2/resolveTranslationsInObject.d.ts +30 -0
- package/dist/utils/v2/resolveTranslationsInObject.d.ts.map +1 -0
- package/package.json +75 -0
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) 2025, WSO2 LLC. (https://www.wso2.com).
|
|
3
|
+
*
|
|
4
|
+
* WSO2 LLC. licenses this file to you under the Apache License,
|
|
5
|
+
* Version 2.0 (the "License"); you may not use this file except
|
|
6
|
+
* in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing,
|
|
12
|
+
* software distributed under the License is distributed on an
|
|
13
|
+
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
14
|
+
* KIND, either express or implied. See the License for the
|
|
15
|
+
* specific language governing permissions and limitations
|
|
16
|
+
* under the License.
|
|
17
|
+
*/
|
|
18
|
+
import { FC, ReactElement } from 'react';
|
|
19
|
+
import { BaseOrganizationSwitcherProps, Organization } from './BaseOrganizationSwitcher';
|
|
20
|
+
/**
|
|
21
|
+
* Props interface for the OrganizationSwitcher component.
|
|
22
|
+
* Makes organizations optional since they'll be retrieved from OrganizationContext.
|
|
23
|
+
*/
|
|
24
|
+
export interface OrganizationSwitcherProps extends Omit<BaseOrganizationSwitcherProps, 'organizations' | 'currentOrganization' | 'onOrganizationSwitch'> {
|
|
25
|
+
/**
|
|
26
|
+
* Optional override for current organization (will use context if not provided)
|
|
27
|
+
*/
|
|
28
|
+
currentOrganization?: Organization;
|
|
29
|
+
/**
|
|
30
|
+
* Fallback element to render when the user is not signed in.
|
|
31
|
+
*/
|
|
32
|
+
fallback?: ReactElement;
|
|
33
|
+
/**
|
|
34
|
+
* Optional callback for organization switch (will use context if not provided)
|
|
35
|
+
*/
|
|
36
|
+
onOrganizationSwitch?: (organization: Organization) => Promise<void> | void;
|
|
37
|
+
/**
|
|
38
|
+
* Optional override for organizations list (will use context if not provided)
|
|
39
|
+
*/
|
|
40
|
+
organizations?: Organization[];
|
|
41
|
+
}
|
|
42
|
+
/**
|
|
43
|
+
* OrganizationSwitcher component that provides organization switching functionality.
|
|
44
|
+
* This component automatically retrieves organizations from the OrganizationContext.
|
|
45
|
+
* You can also override the organizations, currentOrganization, and onOrganizationSwitch
|
|
46
|
+
* by passing them as props.
|
|
47
|
+
*
|
|
48
|
+
* @example
|
|
49
|
+
* ```tsx
|
|
50
|
+
* import { OrganizationSwitcher } from '@thunderid/react';
|
|
51
|
+
*
|
|
52
|
+
* // Basic usage - uses OrganizationContext
|
|
53
|
+
* <OrganizationSwitcher />
|
|
54
|
+
*
|
|
55
|
+
* // With custom organization switch handler
|
|
56
|
+
* <OrganizationSwitcher
|
|
57
|
+
* onOrganizationSwitch={(org) => {
|
|
58
|
+
* console.log('Switching to:', org.name);
|
|
59
|
+
* // Custom logic here
|
|
60
|
+
* }}
|
|
61
|
+
* />
|
|
62
|
+
*
|
|
63
|
+
* // With fallback for unauthenticated users
|
|
64
|
+
* <OrganizationSwitcher
|
|
65
|
+
* fallback={<div>Please sign in to view organizations</div>}
|
|
66
|
+
* />
|
|
67
|
+
* ```
|
|
68
|
+
*/
|
|
69
|
+
export declare const OrganizationSwitcher: FC<OrganizationSwitcherProps>;
|
|
70
|
+
export default OrganizationSwitcher;
|
|
71
|
+
//# sourceMappingURL=OrganizationSwitcher.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"OrganizationSwitcher.d.ts","sourceRoot":"","sources":["../../../../src/components/presentation/OrganizationSwitcher/OrganizationSwitcher.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,EAAC,EAAE,EAAE,YAAY,EAAW,MAAM,OAAO,CAAC;AAEjD,OAAO,EAEL,6BAA6B,EAC7B,YAAY,EACb,MAAM,4BAA4B,CAAC;AASpC;;;GAGG;AACH,MAAM,WAAW,yBACf,SAAQ,IAAI,CAAC,6BAA6B,EAAE,eAAe,GAAG,qBAAqB,GAAG,sBAAsB,CAAC;IAC7G;;OAEG;IACH,mBAAmB,CAAC,EAAE,YAAY,CAAC;IACnC;;OAEG;IACH,QAAQ,CAAC,EAAE,YAAY,CAAC;IACxB;;OAEG;IACH,oBAAoB,CAAC,EAAE,CAAC,YAAY,EAAE,YAAY,KAAK,OAAO,CAAC,IAAI,CAAC,GAAG,IAAI,CAAC;IAC5E;;OAEG;IACH,aAAa,CAAC,EAAE,YAAY,EAAE,CAAC;CAChC;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AACH,eAAO,MAAM,oBAAoB,EAAE,EAAE,CAAC,yBAAyB,CAiH9D,CAAC;AAEF,eAAe,oBAAoB,CAAC"}
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) 2025, WSO2 LLC. (https://www.wso2.com).
|
|
3
|
+
*
|
|
4
|
+
* WSO2 LLC. licenses this file to you under the Apache License,
|
|
5
|
+
* Version 2.0 (the "License"); you may not use this file except
|
|
6
|
+
* in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing,
|
|
12
|
+
* software distributed under the License is distributed on an
|
|
13
|
+
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
14
|
+
* KIND, either express or implied. See the License for the
|
|
15
|
+
* specific language governing permissions and limitations
|
|
16
|
+
* under the License.
|
|
17
|
+
*/
|
|
18
|
+
import { User as IUser } from '@thunderid/browser';
|
|
19
|
+
import { FC, ReactNode } from 'react';
|
|
20
|
+
/**
|
|
21
|
+
* Props for the BaseUser component.
|
|
22
|
+
*/
|
|
23
|
+
export interface BaseUserProps {
|
|
24
|
+
/**
|
|
25
|
+
* Render prop that takes the user object and returns a ReactNode.
|
|
26
|
+
* @param user - The authenticated user object from ThunderID.
|
|
27
|
+
* @returns A ReactNode to render.
|
|
28
|
+
*/
|
|
29
|
+
children: (user: IUser | null) => ReactNode;
|
|
30
|
+
/**
|
|
31
|
+
* Optional element to render when no user is provided.
|
|
32
|
+
*/
|
|
33
|
+
fallback?: ReactNode;
|
|
34
|
+
/**
|
|
35
|
+
* The user object to display. If not provided, the component will render the fallback.
|
|
36
|
+
*/
|
|
37
|
+
user: IUser | null;
|
|
38
|
+
}
|
|
39
|
+
/**
|
|
40
|
+
* Base User component that provides the core functionality for displaying user information.
|
|
41
|
+
* This component takes a user object as a prop and uses render props to expose it.
|
|
42
|
+
*
|
|
43
|
+
* @remarks This is the base component that can be used in any context where you have
|
|
44
|
+
* a user object available. For React applications, use the User component which
|
|
45
|
+
* automatically retrieves the user from ThunderID context.
|
|
46
|
+
*
|
|
47
|
+
* @example
|
|
48
|
+
* ```tsx
|
|
49
|
+
* import { BaseUser } from '@thunderid/auth-react';
|
|
50
|
+
*
|
|
51
|
+
* const MyComponent = ({ user }) => {
|
|
52
|
+
* return (
|
|
53
|
+
* <BaseUser user={user} fallback={<p>No user data</p>}>
|
|
54
|
+
* {(user) => (
|
|
55
|
+
* <div>
|
|
56
|
+
* <h1>Welcome, {user.displayName}!</h1>
|
|
57
|
+
* <p>Email: {user.email}</p>
|
|
58
|
+
* </div>
|
|
59
|
+
* )}
|
|
60
|
+
* </BaseUser>
|
|
61
|
+
* );
|
|
62
|
+
* }
|
|
63
|
+
* ```
|
|
64
|
+
*/
|
|
65
|
+
declare const BaseUser: FC<BaseUserProps>;
|
|
66
|
+
export default BaseUser;
|
|
67
|
+
//# sourceMappingURL=BaseUser.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"BaseUser.d.ts","sourceRoot":"","sources":["../../../../src/components/presentation/User/BaseUser.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,EAAC,IAAI,IAAI,KAAK,EAAC,MAAM,oBAAoB,CAAC;AACjD,OAAO,EAAC,EAAE,EAAgB,SAAS,EAAC,MAAM,OAAO,CAAC;AAElD;;GAEG;AACH,MAAM,WAAW,aAAa;IAC5B;;;;OAIG;IACH,QAAQ,EAAE,CAAC,IAAI,EAAE,KAAK,GAAG,IAAI,KAAK,SAAS,CAAC;IAE5C;;OAEG;IACH,QAAQ,CAAC,EAAE,SAAS,CAAC;IAErB;;OAEG;IACH,IAAI,EAAE,KAAK,GAAG,IAAI,CAAC;CACpB;AAED;;;;;;;;;;;;;;;;;;;;;;;;;GAyBG;AACH,QAAA,MAAM,QAAQ,EAAE,EAAE,CAAC,aAAa,CAM/B,CAAC;AAIF,eAAe,QAAQ,CAAC"}
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) 2025, WSO2 LLC. (https://www.wso2.com).
|
|
3
|
+
*
|
|
4
|
+
* WSO2 LLC. licenses this file to you under the Apache License,
|
|
5
|
+
* Version 2.0 (the "License"); you may not use this file except
|
|
6
|
+
* in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing,
|
|
12
|
+
* software distributed under the License is distributed on an
|
|
13
|
+
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
14
|
+
* KIND, either express or implied. See the License for the
|
|
15
|
+
* specific language governing permissions and limitations
|
|
16
|
+
* under the License.
|
|
17
|
+
*/
|
|
18
|
+
import { User as IUser } from '@thunderid/browser';
|
|
19
|
+
import { FC, ReactNode } from 'react';
|
|
20
|
+
import { BaseUserProps } from './BaseUser';
|
|
21
|
+
/**
|
|
22
|
+
* Props for the User component.
|
|
23
|
+
* Extends BaseUserProps but makes the user prop optional since it will be obtained from useThunderID
|
|
24
|
+
*/
|
|
25
|
+
export interface UserProps extends Omit<BaseUserProps, 'user'> {
|
|
26
|
+
/**
|
|
27
|
+
* Render prop that takes the user object and returns a ReactNode.
|
|
28
|
+
* @param user - The authenticated user object from ThunderID.
|
|
29
|
+
* @returns A ReactNode to render.
|
|
30
|
+
*/
|
|
31
|
+
children: (user: IUser | null) => ReactNode;
|
|
32
|
+
/**
|
|
33
|
+
* Optional element to render when no user is signed in.
|
|
34
|
+
*/
|
|
35
|
+
fallback?: ReactNode;
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* A component that uses render props to expose the authenticated user object.
|
|
39
|
+
* This component automatically retrieves the user from ThunderID context.
|
|
40
|
+
*
|
|
41
|
+
* @remarks This component is only supported in browser based React applications (CSR).
|
|
42
|
+
*
|
|
43
|
+
* @example
|
|
44
|
+
* ```tsx
|
|
45
|
+
* import { IUser } from '@thunderid/auth-react';
|
|
46
|
+
*
|
|
47
|
+
* const App = () => {
|
|
48
|
+
* return (
|
|
49
|
+
* <User fallback={<p>Please sign in</p>}>
|
|
50
|
+
* {(user) => (
|
|
51
|
+
* <div>
|
|
52
|
+
* <h1>Welcome, {user.displayName}!</h1>
|
|
53
|
+
* <p>Email: {user.email}</p>
|
|
54
|
+
* </div>
|
|
55
|
+
* )}
|
|
56
|
+
* </User>
|
|
57
|
+
* );
|
|
58
|
+
* }
|
|
59
|
+
* ```
|
|
60
|
+
*/
|
|
61
|
+
declare const User: FC<UserProps>;
|
|
62
|
+
export default User;
|
|
63
|
+
//# sourceMappingURL=User.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"User.d.ts","sourceRoot":"","sources":["../../../../src/components/presentation/User/User.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,EAAC,IAAI,IAAI,KAAK,EAAC,MAAM,oBAAoB,CAAC;AACjD,OAAO,EAAC,EAAE,EAAgB,SAAS,EAAC,MAAM,OAAO,CAAC;AAClD,OAAiB,EAAC,aAAa,EAAC,MAAM,YAAY,CAAC;AAGnD;;;GAGG;AACH,MAAM,WAAW,SAAU,SAAQ,IAAI,CAAC,aAAa,EAAE,MAAM,CAAC;IAC5D;;;;OAIG;IACH,QAAQ,EAAE,CAAC,IAAI,EAAE,KAAK,GAAG,IAAI,KAAK,SAAS,CAAC;IAE5C;;OAEG;IACH,QAAQ,CAAC,EAAE,SAAS,CAAC;CACtB;AAED;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AACH,QAAA,MAAM,IAAI,EAAE,EAAE,CAAC,SAAS,CAQvB,CAAC;AAIF,eAAe,IAAI,CAAC"}
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) 2025, WSO2 LLC. (https://www.wso2.com).
|
|
3
|
+
*
|
|
4
|
+
* WSO2 LLC. licenses this file to you under the Apache License,
|
|
5
|
+
* Version 2.0 (the "License"); you may not use this file except
|
|
6
|
+
* in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing,
|
|
12
|
+
* software distributed under the License is distributed on an
|
|
13
|
+
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
14
|
+
* KIND, either express or implied. See the License for the
|
|
15
|
+
* specific language governing permissions and limitations
|
|
16
|
+
* under the License.
|
|
17
|
+
*/
|
|
18
|
+
import { FC, ReactElement, ReactNode } from 'react';
|
|
19
|
+
interface MenuItem {
|
|
20
|
+
href?: string;
|
|
21
|
+
icon?: ReactNode;
|
|
22
|
+
label: ReactNode;
|
|
23
|
+
onClick?: () => void;
|
|
24
|
+
}
|
|
25
|
+
export interface BaseUserDropdownProps {
|
|
26
|
+
/**
|
|
27
|
+
* Mapping of component attribute names to identity provider field names.
|
|
28
|
+
* Allows customizing which user profile fields should be used for each attribute.
|
|
29
|
+
*/
|
|
30
|
+
attributeMapping?: {
|
|
31
|
+
[key: string]: string | string[] | undefined;
|
|
32
|
+
firstName?: string | string[];
|
|
33
|
+
lastName?: string | string[];
|
|
34
|
+
picture?: string | string[];
|
|
35
|
+
username?: string | string[];
|
|
36
|
+
};
|
|
37
|
+
/**
|
|
38
|
+
* Optional size for the avatar
|
|
39
|
+
*/
|
|
40
|
+
avatarSize?: number;
|
|
41
|
+
/**
|
|
42
|
+
* Optional className for the dropdown container.
|
|
43
|
+
*/
|
|
44
|
+
className?: string;
|
|
45
|
+
/**
|
|
46
|
+
* Optional element to render when no user is signed in.
|
|
47
|
+
*/
|
|
48
|
+
fallback?: ReactElement;
|
|
49
|
+
/**
|
|
50
|
+
* Whether the user data is currently loading
|
|
51
|
+
*/
|
|
52
|
+
isLoading?: boolean;
|
|
53
|
+
/**
|
|
54
|
+
* Menu items to display in the dropdown
|
|
55
|
+
*/
|
|
56
|
+
menuItems?: MenuItem[];
|
|
57
|
+
/**
|
|
58
|
+
* Callback function for "Manage Profile" action
|
|
59
|
+
*/
|
|
60
|
+
onManageProfile?: () => void;
|
|
61
|
+
/**
|
|
62
|
+
* Callback function for "Sign Out" action
|
|
63
|
+
*/
|
|
64
|
+
onSignOut?: () => void;
|
|
65
|
+
/**
|
|
66
|
+
* The HTML element ID where the portal should be mounted
|
|
67
|
+
*/
|
|
68
|
+
portalId?: string;
|
|
69
|
+
/**
|
|
70
|
+
* Show dropdown header with user information
|
|
71
|
+
*/
|
|
72
|
+
showDropdownHeader?: boolean;
|
|
73
|
+
/**
|
|
74
|
+
* Show user's display name next to avatar in the trigger button
|
|
75
|
+
*/
|
|
76
|
+
showTriggerLabel?: boolean;
|
|
77
|
+
/**
|
|
78
|
+
* The user object containing profile information
|
|
79
|
+
*/
|
|
80
|
+
user: any;
|
|
81
|
+
}
|
|
82
|
+
/**
|
|
83
|
+
* BaseUserDropdown component displays a user avatar with a dropdown menu.
|
|
84
|
+
* When clicked, it shows a popover with customizable menu items.
|
|
85
|
+
* This component serves as the base for framework-specific implementations.
|
|
86
|
+
*/
|
|
87
|
+
export declare const BaseUserDropdown: FC<BaseUserDropdownProps>;
|
|
88
|
+
export default BaseUserDropdown;
|
|
89
|
+
//# sourceMappingURL=BaseUserDropdown.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"BaseUserDropdown.d.ts","sourceRoot":"","sources":["../../../../src/components/presentation/UserDropdown/BaseUserDropdown.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAiBH,OAAO,EAAC,EAAE,EAAE,YAAY,EAAE,SAAS,EAAW,MAAM,OAAO,CAAC;AAW5D,UAAU,QAAQ;IAChB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,IAAI,CAAC,EAAE,SAAS,CAAC;IACjB,KAAK,EAAE,SAAS,CAAC;IACjB,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;CACtB;AAED,MAAM,WAAW,qBAAqB;IACpC;;;OAGG;IACH,gBAAgB,CAAC,EAAE;QACjB,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,GAAG,MAAM,EAAE,GAAG,SAAS,CAAC;QAC7C,SAAS,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC;QAC9B,QAAQ,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC;QAC7B,OAAO,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC;QAC5B,QAAQ,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC;KAC9B,CAAC;IACF;;OAEG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;;OAEG;IACH,QAAQ,CAAC,EAAE,YAAY,CAAC;IACxB;;OAEG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB;;OAEG;IACH,SAAS,CAAC,EAAE,QAAQ,EAAE,CAAC;IACvB;;OAEG;IACH,eAAe,CAAC,EAAE,MAAM,IAAI,CAAC;IAC7B;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,IAAI,CAAC;IACvB;;OAEG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB;;OAEG;IACH,kBAAkB,CAAC,EAAE,OAAO,CAAC;IAC7B;;OAEG;IACH,gBAAgB,CAAC,EAAE,OAAO,CAAC;IAC3B;;OAEG;IACH,IAAI,EAAE,GAAG,CAAC;CACX;AAED;;;;GAIG;AACH,eAAO,MAAM,gBAAgB,EAAE,EAAE,CAAC,qBAAqB,CAqNtD,CAAC;AAEF,eAAe,gBAAgB,CAAC"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) 2025, WSO2 LLC. (https://www.wso2.com).
|
|
3
|
+
*
|
|
4
|
+
* WSO2 LLC. licenses this file to you under the Apache License,
|
|
5
|
+
* Version 2.0 (the "License"); you may not use this file except
|
|
6
|
+
* in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing,
|
|
12
|
+
* software distributed under the License is distributed on an
|
|
13
|
+
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
14
|
+
* KIND, either express or implied. See the License for the
|
|
15
|
+
* specific language governing permissions and limitations
|
|
16
|
+
* under the License.
|
|
17
|
+
*/
|
|
18
|
+
import { Theme } from '@thunderid/browser';
|
|
19
|
+
/**
|
|
20
|
+
* Creates styles for the BaseUserDropdown component
|
|
21
|
+
* @param theme - The theme object containing design tokens
|
|
22
|
+
* @param colorScheme - The current color scheme (used for memoization)
|
|
23
|
+
* @returns Object containing CSS class names for component styling
|
|
24
|
+
*/
|
|
25
|
+
declare const useStyles: (theme: Theme, colorScheme: string) => Record<string, string>;
|
|
26
|
+
export default useStyles;
|
|
27
|
+
//# sourceMappingURL=BaseUserDropdown.styles.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"BaseUserDropdown.styles.d.ts","sourceRoot":"","sources":["../../../../src/components/presentation/UserDropdown/BaseUserDropdown.styles.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAGH,OAAO,EAAC,KAAK,EAAC,MAAM,oBAAoB,CAAC;AAGzC;;;;;GAKG;AACH,QAAA,MAAM,SAAS,GAAI,OAAO,KAAK,EAAE,aAAa,MAAM,KAAG,MAAM,CAAC,MAAM,EAAE,MAAM,CAuMxE,CAAC;AAEL,eAAe,SAAS,CAAC"}
|
|
@@ -0,0 +1,109 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) 2025, WSO2 LLC. (https://www.wso2.com).
|
|
3
|
+
*
|
|
4
|
+
* WSO2 LLC. licenses this file to you under the Apache License,
|
|
5
|
+
* Version 2.0 (the "License"); you may not use this file except
|
|
6
|
+
* in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing,
|
|
12
|
+
* software distributed under the License is distributed on an
|
|
13
|
+
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
14
|
+
* KIND, either express or implied. See the License for the
|
|
15
|
+
* specific language governing permissions and limitations
|
|
16
|
+
* under the License.
|
|
17
|
+
*/
|
|
18
|
+
import { FlowMetadataResponse } from '@thunderid/browser';
|
|
19
|
+
import { FC, ReactNode } from 'react';
|
|
20
|
+
import { BaseUserDropdownProps } from './BaseUserDropdown';
|
|
21
|
+
/**
|
|
22
|
+
* Render props data passed to the children function
|
|
23
|
+
*/
|
|
24
|
+
export interface UserDropdownRenderProps {
|
|
25
|
+
/** Function to close the profile dialog */
|
|
26
|
+
closeProfile: () => void;
|
|
27
|
+
/** Whether user data is currently loading */
|
|
28
|
+
isLoading: boolean;
|
|
29
|
+
/** Whether the profile dialog is currently open */
|
|
30
|
+
isProfileOpen: boolean;
|
|
31
|
+
/** Flow metadata returned by the platform (v2 only). `null` while loading or unavailable. */
|
|
32
|
+
meta: FlowMetadataResponse | null;
|
|
33
|
+
/** Function to open the user profile dialog */
|
|
34
|
+
openProfile: () => void;
|
|
35
|
+
/** Function to sign out the user */
|
|
36
|
+
signOut: () => void;
|
|
37
|
+
/** The authenticated user object */
|
|
38
|
+
user: any;
|
|
39
|
+
}
|
|
40
|
+
/**
|
|
41
|
+
* Props for the UserDropdown component.
|
|
42
|
+
* Extends BaseUserDropdownProps but excludes user, onManageProfile, and onSignOut since they're handled internally
|
|
43
|
+
*/
|
|
44
|
+
export type UserDropdownProps = Omit<BaseUserDropdownProps, 'user' | 'onManageProfile'> & {
|
|
45
|
+
/**
|
|
46
|
+
* Render prop function that receives user state and actions.
|
|
47
|
+
* When provided, this completely replaces the default dropdown rendering.
|
|
48
|
+
*/
|
|
49
|
+
children?: (props: UserDropdownRenderProps) => ReactNode;
|
|
50
|
+
/**
|
|
51
|
+
* Custom render function for the dropdown content.
|
|
52
|
+
* When provided, this replaces just the dropdown content while keeping the trigger.
|
|
53
|
+
*/
|
|
54
|
+
renderDropdown?: (props: UserDropdownRenderProps) => ReactNode;
|
|
55
|
+
/**
|
|
56
|
+
* Custom render function for the trigger button.
|
|
57
|
+
* When provided, this replaces just the trigger button while keeping the dropdown.
|
|
58
|
+
*/
|
|
59
|
+
renderTrigger?: (props: UserDropdownRenderProps) => ReactNode;
|
|
60
|
+
};
|
|
61
|
+
/**
|
|
62
|
+
* UserDropdown component displays a user avatar with a dropdown menu.
|
|
63
|
+
* When clicked, it shows a popover with customizable menu items.
|
|
64
|
+
* This component is the React-specific implementation that uses the BaseUserDropdown
|
|
65
|
+
* and automatically retrieves the user data from ThunderID context.
|
|
66
|
+
*
|
|
67
|
+
* Supports render props for complete customization of the dropdown appearance and behavior.
|
|
68
|
+
*
|
|
69
|
+
* @example
|
|
70
|
+
* ```tsx
|
|
71
|
+
* // Basic usage - will use user from ThunderID context
|
|
72
|
+
* <UserDropdown menuItems={[
|
|
73
|
+
* { label: 'Profile', onClick: () => {} },
|
|
74
|
+
* { label: 'Settings', href: '/settings' },
|
|
75
|
+
* { label: 'Sign Out', onClick: () => {} }
|
|
76
|
+
* ]} />
|
|
77
|
+
*
|
|
78
|
+
* // With custom configuration
|
|
79
|
+
* <UserDropdown
|
|
80
|
+
* showTriggerLabel={true}
|
|
81
|
+
* avatarSize={40}
|
|
82
|
+
* fallback={<div>Please sign in</div>}
|
|
83
|
+
* />
|
|
84
|
+
*
|
|
85
|
+
* // Using render props for complete customization
|
|
86
|
+
* <UserDropdown>
|
|
87
|
+
* {({ user, isLoading, openProfile, signOut }) => (
|
|
88
|
+
* <div>
|
|
89
|
+
* <button onClick={openProfile}>
|
|
90
|
+
* {user?.name || 'Loading...'}
|
|
91
|
+
* </button>
|
|
92
|
+
* <button onClick={signOut}>Logout</button>
|
|
93
|
+
* </div>
|
|
94
|
+
* )}
|
|
95
|
+
* </UserDropdown>
|
|
96
|
+
*
|
|
97
|
+
* // Using partial render props
|
|
98
|
+
* <UserDropdown
|
|
99
|
+
* renderTrigger={({ user, openProfile }) => (
|
|
100
|
+
* <button onClick={openProfile} className="custom-trigger">
|
|
101
|
+
* Welcome, {user?.name}!
|
|
102
|
+
* </button>
|
|
103
|
+
* )}
|
|
104
|
+
* />
|
|
105
|
+
* ```
|
|
106
|
+
*/
|
|
107
|
+
declare const UserDropdown: FC<UserDropdownProps>;
|
|
108
|
+
export default UserDropdown;
|
|
109
|
+
//# sourceMappingURL=UserDropdown.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"UserDropdown.d.ts","sourceRoot":"","sources":["../../../../src/components/presentation/UserDropdown/UserDropdown.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,EAAC,oBAAoB,EAAC,MAAM,oBAAoB,CAAC;AACxD,OAAO,EAAC,EAAE,EAAgB,SAAS,EAAW,MAAM,OAAO,CAAC;AAC5D,OAAO,EAAgD,qBAAqB,EAAC,MAAM,oBAAoB,CAAC;AAIxG;;GAEG;AACH,MAAM,WAAW,uBAAuB;IACtC,2CAA2C;IAC3C,YAAY,EAAE,MAAM,IAAI,CAAC;IACzB,6CAA6C;IAC7C,SAAS,EAAE,OAAO,CAAC;IACnB,mDAAmD;IACnD,aAAa,EAAE,OAAO,CAAC;IACvB,6FAA6F;IAC7F,IAAI,EAAE,oBAAoB,GAAG,IAAI,CAAC;IAClC,+CAA+C;IAC/C,WAAW,EAAE,MAAM,IAAI,CAAC;IACxB,oCAAoC;IACpC,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,oCAAoC;IACpC,IAAI,EAAE,GAAG,CAAC;CACX;AAED;;;GAGG;AACH,MAAM,MAAM,iBAAiB,GAAG,IAAI,CAAC,qBAAqB,EAAE,MAAM,GAAG,iBAAiB,CAAC,GAAG;IACxF;;;OAGG;IACH,QAAQ,CAAC,EAAE,CAAC,KAAK,EAAE,uBAAuB,KAAK,SAAS,CAAC;IACzD;;;OAGG;IACH,cAAc,CAAC,EAAE,CAAC,KAAK,EAAE,uBAAuB,KAAK,SAAS,CAAC;IAC/D;;;OAGG;IACH,aAAa,CAAC,EAAE,CAAC,KAAK,EAAE,uBAAuB,KAAK,SAAS,CAAC;CAC/D,CAAC;AAEF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6CG;AACH,QAAA,MAAM,YAAY,EAAE,EAAE,CAAC,iBAAiB,CAkFvC,CAAC;AAEF,eAAe,YAAY,CAAC"}
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) 2025, WSO2 LLC. (https://www.wso2.com).
|
|
3
|
+
*
|
|
4
|
+
* WSO2 LLC. licenses this file to you under the Apache License,
|
|
5
|
+
* Version 2.0 (the "License"); you may not use this file except
|
|
6
|
+
* in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing,
|
|
12
|
+
* software distributed under the License is distributed on an
|
|
13
|
+
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
14
|
+
* KIND, either express or implied. See the License for the
|
|
15
|
+
* specific language governing permissions and limitations
|
|
16
|
+
* under the License.
|
|
17
|
+
*/
|
|
18
|
+
import { User, Preferences } from '@thunderid/browser';
|
|
19
|
+
import { FC, ReactElement } from 'react';
|
|
20
|
+
interface ExtendedFlatSchema {
|
|
21
|
+
path?: string;
|
|
22
|
+
schemaId?: string;
|
|
23
|
+
}
|
|
24
|
+
interface Schema extends ExtendedFlatSchema {
|
|
25
|
+
caseExact?: boolean;
|
|
26
|
+
description?: string;
|
|
27
|
+
displayName?: string;
|
|
28
|
+
displayOrder?: string;
|
|
29
|
+
multiValued?: boolean;
|
|
30
|
+
mutability?: string;
|
|
31
|
+
name?: string;
|
|
32
|
+
required?: boolean;
|
|
33
|
+
returned?: string;
|
|
34
|
+
subAttributes?: Schema[];
|
|
35
|
+
type?: string;
|
|
36
|
+
uniqueness?: string;
|
|
37
|
+
value?: any;
|
|
38
|
+
}
|
|
39
|
+
export interface BaseUserProfileProps {
|
|
40
|
+
attributeMapping?: {
|
|
41
|
+
[key: string]: string | string[] | undefined;
|
|
42
|
+
firstName?: string | string[];
|
|
43
|
+
lastName?: string | string[];
|
|
44
|
+
picture?: string | string[];
|
|
45
|
+
username?: string | string[];
|
|
46
|
+
};
|
|
47
|
+
cardLayout?: boolean;
|
|
48
|
+
className?: string;
|
|
49
|
+
displayNameAttributes?: string[];
|
|
50
|
+
editable?: boolean;
|
|
51
|
+
error?: string | null;
|
|
52
|
+
fallback?: ReactElement;
|
|
53
|
+
flattenedProfile?: User;
|
|
54
|
+
hideFields?: string[];
|
|
55
|
+
isLoading?: boolean;
|
|
56
|
+
mode?: 'inline' | 'popup';
|
|
57
|
+
onOpenChange?: (open: boolean) => void;
|
|
58
|
+
onUpdate?: (payload: any) => Promise<void>;
|
|
59
|
+
open?: boolean;
|
|
60
|
+
/**
|
|
61
|
+
* Component-level preferences to override global i18n and theme settings.
|
|
62
|
+
* Preferences are deep-merged with global ones, with component preferences
|
|
63
|
+
* taking precedence. Affects this component and all its descendants.
|
|
64
|
+
*/
|
|
65
|
+
preferences?: Preferences;
|
|
66
|
+
profile?: User;
|
|
67
|
+
schemas?: Schema[];
|
|
68
|
+
showFields?: string[];
|
|
69
|
+
title?: string;
|
|
70
|
+
}
|
|
71
|
+
declare const BaseUserProfile: FC<BaseUserProfileProps>;
|
|
72
|
+
export default BaseUserProfile;
|
|
73
|
+
//# sourceMappingURL=BaseUserProfile.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"BaseUserProfile.d.ts","sourceRoot":"","sources":["../../../../src/components/presentation/UserProfile/BaseUserProfile.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAGH,OAAO,EAAC,IAAI,EAAqD,WAAW,EAAC,MAAM,oBAAoB,CAAC;AACxG,OAAO,EAAC,EAAE,EAAE,YAAY,EAAwB,MAAM,OAAO,CAAC;AAkB9D,UAAU,kBAAkB;IAC1B,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB;AAED,UAAU,MAAO,SAAQ,kBAAkB;IACzC,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,aAAa,CAAC,EAAE,MAAM,EAAE,CAAC;IACzB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,KAAK,CAAC,EAAE,GAAG,CAAC;CACb;AAED,MAAM,WAAW,oBAAoB;IACnC,gBAAgB,CAAC,EAAE;QACjB,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,GAAG,MAAM,EAAE,GAAG,SAAS,CAAC;QAC7C,SAAS,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC;QAC9B,QAAQ,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC;QAC7B,OAAO,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC;QAC5B,QAAQ,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC;KAC9B,CAAC;IACF,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,qBAAqB,CAAC,EAAE,MAAM,EAAE,CAAC;IACjC,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,KAAK,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACtB,QAAQ,CAAC,EAAE,YAAY,CAAC;IACxB,gBAAgB,CAAC,EAAE,IAAI,CAAC;IACxB,UAAU,CAAC,EAAE,MAAM,EAAE,CAAC;IACtB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,IAAI,CAAC,EAAE,QAAQ,GAAG,OAAO,CAAC;IAC1B,YAAY,CAAC,EAAE,CAAC,IAAI,EAAE,OAAO,KAAK,IAAI,CAAC;IACvC,QAAQ,CAAC,EAAE,CAAC,OAAO,EAAE,GAAG,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;IAC3C,IAAI,CAAC,EAAE,OAAO,CAAC;IACf;;;;OAIG;IACH,WAAW,CAAC,EAAE,WAAW,CAAC;IAC1B,OAAO,CAAC,EAAE,IAAI,CAAC;IACf,OAAO,CAAC,EAAE,MAAM,EAAE,CAAC;IACnB,UAAU,CAAC,EAAE,MAAM,EAAE,CAAC;IAEtB,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AA2BD,QAAA,MAAM,eAAe,EAAE,EAAE,CAAC,oBAAoB,CAmnB7C,CAAC;AAEF,eAAe,eAAe,CAAC"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) 2025, WSO2 LLC. (https://www.wso2.com).
|
|
3
|
+
*
|
|
4
|
+
* WSO2 LLC. licenses this file to you under the Apache License,
|
|
5
|
+
* Version 2.0 (the "License"); you may not use this file except
|
|
6
|
+
* in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing,
|
|
12
|
+
* software distributed under the License is distributed on an
|
|
13
|
+
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
14
|
+
* KIND, either express or implied. See the License for the
|
|
15
|
+
* specific language governing permissions and limitations
|
|
16
|
+
* under the License.
|
|
17
|
+
*/
|
|
18
|
+
import { Theme } from '@thunderid/browser';
|
|
19
|
+
/**
|
|
20
|
+
* Creates styles for the BaseUserProfile component
|
|
21
|
+
* @param theme - The theme object containing design tokens
|
|
22
|
+
* @param colorScheme - The current color scheme (used for memoization)
|
|
23
|
+
* @returns Object containing CSS class names for component styling
|
|
24
|
+
*/
|
|
25
|
+
declare const useStyles: (theme: Theme, colorScheme: string) => Record<string, string>;
|
|
26
|
+
export default useStyles;
|
|
27
|
+
//# sourceMappingURL=BaseUserProfile.styles.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"BaseUserProfile.styles.d.ts","sourceRoot":"","sources":["../../../../src/components/presentation/UserProfile/BaseUserProfile.styles.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAGH,OAAO,EAAC,KAAK,EAA2B,MAAM,oBAAoB,CAAC;AAGnE;;;;;GAKG;AACH,QAAA,MAAM,SAAS,GAAI,OAAO,KAAK,EAAE,aAAa,MAAM,KAAG,MAAM,CAAC,MAAM,EAAE,MAAM,CA6N3E,CAAC;AAEF,eAAe,SAAS,CAAC"}
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) 2025, WSO2 LLC. (https://www.wso2.com).
|
|
3
|
+
*
|
|
4
|
+
* WSO2 LLC. licenses this file to you under the Apache License,
|
|
5
|
+
* Version 2.0 (the "License"); you may not use this file except
|
|
6
|
+
* in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing,
|
|
12
|
+
* software distributed under the License is distributed on an
|
|
13
|
+
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
14
|
+
* KIND, either express or implied. See the License for the
|
|
15
|
+
* specific language governing permissions and limitations
|
|
16
|
+
* under the License.
|
|
17
|
+
*/
|
|
18
|
+
import { FC } from 'react';
|
|
19
|
+
import { BaseUserProfileProps } from './BaseUserProfile';
|
|
20
|
+
/**
|
|
21
|
+
* Props for the UserProfile component.
|
|
22
|
+
* Extends BaseUserProfileProps but makes the user prop optional since it will be obtained from useThunderID
|
|
23
|
+
*/
|
|
24
|
+
export type UserProfileProps = Omit<BaseUserProfileProps, 'user' | 'profile' | 'flattenedProfile' | 'schemas'>;
|
|
25
|
+
/**
|
|
26
|
+
* UserProfile component displays the authenticated user's profile information in a
|
|
27
|
+
* structured and styled format. It shows user details such as display name, email,
|
|
28
|
+
* username, and other available profile information from ThunderID.
|
|
29
|
+
*
|
|
30
|
+
* This component is the React-specific implementation that uses the BaseUserProfile
|
|
31
|
+
* and automatically retrieves the user data from ThunderID context if not provided.
|
|
32
|
+
*
|
|
33
|
+
* @example
|
|
34
|
+
* ```tsx
|
|
35
|
+
* // Basic usage - will use user from ThunderID context
|
|
36
|
+
* <UserProfile />
|
|
37
|
+
*
|
|
38
|
+
* // With explicit user data
|
|
39
|
+
* <UserProfile user={specificUser} />
|
|
40
|
+
*
|
|
41
|
+
* // With card layout and custom fallback
|
|
42
|
+
* <UserProfile
|
|
43
|
+
* cardLayout={true}
|
|
44
|
+
* fallback={<div>Please sign in to view your profile</div>}
|
|
45
|
+
* />
|
|
46
|
+
*
|
|
47
|
+
* // With field filtering - only show specific fields
|
|
48
|
+
* <UserProfile
|
|
49
|
+
* showFields={['name.givenName', 'name.familyName', 'emails']}
|
|
50
|
+
* />
|
|
51
|
+
*
|
|
52
|
+
* // With field hiding - hide specific fields
|
|
53
|
+
* <UserProfile
|
|
54
|
+
* hideFields={['phoneNumbers', 'addresses']}
|
|
55
|
+
* />
|
|
56
|
+
* ```
|
|
57
|
+
*/
|
|
58
|
+
declare const UserProfile: FC<UserProfileProps>;
|
|
59
|
+
export default UserProfile;
|
|
60
|
+
//# sourceMappingURL=UserProfile.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"UserProfile.d.ts","sourceRoot":"","sources":["../../../../src/components/presentation/UserProfile/UserProfile.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAGH,OAAO,EAAC,EAAE,EAAyB,MAAM,OAAO,CAAC;AAEjD,OAAwB,EAAC,oBAAoB,EAAC,MAAM,mBAAmB,CAAC;AAMxE;;;GAGG;AACH,MAAM,MAAM,gBAAgB,GAAG,IAAI,CAAC,oBAAoB,EAAE,MAAM,GAAG,SAAS,GAAG,kBAAkB,GAAG,SAAS,CAAC,CAAC;AAE/G;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgCG;AACH,QAAA,MAAM,WAAW,EAAE,EAAE,CAAC,gBAAgB,CAmCrC,CAAC;AAEF,eAAe,WAAW,CAAC"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) 2025, WSO2 LLC. (https://www.wso2.com).
|
|
3
|
+
*
|
|
4
|
+
* WSO2 LLC. licenses this file to you under the Apache License,
|
|
5
|
+
* Version 2.0 (the "License"); you may not use this file except
|
|
6
|
+
* in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing,
|
|
12
|
+
* software distributed under the License is distributed on an
|
|
13
|
+
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
14
|
+
* KIND, either express or implied. See the License for the
|
|
15
|
+
* specific language governing permissions and limitations
|
|
16
|
+
* under the License.
|
|
17
|
+
*/
|
|
18
|
+
export { default as AcceptInvite } from './v2/AcceptInvite';
|
|
19
|
+
export type { AcceptInviteProps, AcceptInviteRenderProps } from './v2/AcceptInvite';
|
|
20
|
+
export { default as BaseAcceptInvite } from './v2/BaseAcceptInvite';
|
|
21
|
+
export type { BaseAcceptInviteProps, BaseAcceptInviteRenderProps, AcceptInviteFlowResponse } from './v2/BaseAcceptInvite';
|
|
22
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/components/presentation/auth/AcceptInvite/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAGH,OAAO,EAAC,OAAO,IAAI,YAAY,EAAC,MAAM,mBAAmB,CAAC;AAC1D,YAAY,EAAC,iBAAiB,EAAE,uBAAuB,EAAC,MAAM,mBAAmB,CAAC;AAClF,OAAO,EAAC,OAAO,IAAI,gBAAgB,EAAC,MAAM,uBAAuB,CAAC;AAClE,YAAY,EAAC,qBAAqB,EAAE,2BAA2B,EAAE,wBAAwB,EAAC,MAAM,uBAAuB,CAAC"}
|