import { APIKeysContext, useAPIKeysContext } from "./components/APIKeys.js";
import { CheckoutContext, useCheckoutContext } from "./components/Checkout.js";
import { CreateOrganizationContext, useCreateOrganizationContext } from "./components/CreateOrganization.js";
import { GoogleOneTapContext, useGoogleOneTapContext } from "./components/GoogleOneTap.js";
import { OAuthConsentContext, useOAuthConsentContext } from "./components/OAuthConsent.js";
import { OrganizationListContext, useOrganizationListContext } from "./components/OrganizationList.js";
import { SubscriberTypeContext, useSubscriberTypeContext, useSubscriberTypeLocalizationRoot } from "./components/SubscriberType.js";
import { normalizeFormatted, usePaymentAttempts, usePaymentMethods, usePlans, usePlansContext, useStatements, useSubscription } from "./components/Plans.js";
import { OrganizationProfileContext, useOrganizationProfileContext } from "./components/OrganizationProfile.js";
import { OrganizationSwitcherContext, useOrganizationSwitcherContext } from "./components/OrganizationSwitcher.js";
import { PricingTableContext, usePricingTableContext } from "./components/PricingTable.js";
import { SignInContext, useSignInContext } from "./components/SignIn.js";
import { useSignOutContext } from "./components/SignOut.js";
import { SignUpContext, useSignUpContext } from "./components/SignUp.js";
import { SubscriptionDetailsContext, useSubscriptionDetailsContext } from "./components/SubscriptionDetails.js";
import { UserAvatarContext, useUserAvatarContext } from "./components/UserAvatar.js";
import { UserButtonContext, useUserButtonContext } from "./components/UserButton.js";
import { UserProfileContext, useUserProfileContext } from "./components/UserProfile.js";
import { UserVerificationContext, useUserVerification } from "./components/UserVerification.js";
import { WaitlistContext, useWaitlistContext } from "./components/Waitlist.js";
import { SessionTasksContext, TaskChooseOrganizationContext, TaskResetPasswordContext, TaskSetupMFAContext } from "./components/SessionTasks.js";
import { jsx } from "@emotion/react/jsx-runtime";

//#region src/contexts/ClerkUIComponentsContext.tsx
function ComponentContextProvider({ componentName, props, children }) {
	switch (componentName) {
		case "SignIn": return /* @__PURE__ */ jsx(SignInContext.Provider, {
			value: {
				componentName,
				...props
			},
			children
		});
		case "SignUp": return /* @__PURE__ */ jsx(SignUpContext.Provider, {
			value: {
				componentName,
				...props
			},
			children
		});
		case "UserProfile": return /* @__PURE__ */ jsx(UserProfileContext.Provider, {
			value: {
				componentName,
				...props
			},
			children
		});
		case "UserVerification": return /* @__PURE__ */ jsx(UserVerificationContext.Provider, {
			value: {
				componentName,
				...props
			},
			children
		});
		case "UserAvatar": return /* @__PURE__ */ jsx(UserAvatarContext.Provider, {
			value: {
				componentName,
				...props
			},
			children
		});
		case "UserButton": return /* @__PURE__ */ jsx(UserButtonContext.Provider, {
			value: {
				componentName,
				...props
			},
			children
		});
		case "OrganizationSwitcher": return /* @__PURE__ */ jsx(OrganizationSwitcherContext.Provider, {
			value: {
				componentName,
				...props
			},
			children
		});
		case "OrganizationList": return /* @__PURE__ */ jsx(OrganizationListContext.Provider, {
			value: {
				componentName,
				...props
			},
			children
		});
		case "OrganizationProfile": return /* @__PURE__ */ jsx(OrganizationProfileContext.Provider, {
			value: {
				componentName,
				...props
			},
			children
		});
		case "CreateOrganization": return /* @__PURE__ */ jsx(CreateOrganizationContext.Provider, {
			value: {
				componentName,
				...props
			},
			children
		});
		case "GoogleOneTap": return /* @__PURE__ */ jsx(GoogleOneTapContext.Provider, {
			value: {
				componentName,
				...props
			},
			children
		});
		case "Waitlist": return /* @__PURE__ */ jsx(WaitlistContext.Provider, {
			value: {
				componentName,
				...props
			},
			children
		});
		case "PricingTable": return /* @__PURE__ */ jsx(SubscriberTypeContext.Provider, {
			value: props.for || "user",
			children: /* @__PURE__ */ jsx(PricingTableContext.Provider, {
				value: {
					componentName,
					...props
				},
				children
			})
		});
		case "APIKeys": return /* @__PURE__ */ jsx(APIKeysContext.Provider, {
			value: {
				componentName,
				...props
			},
			children
		});
		case "OAuthConsent": {
			const p = props;
			return /* @__PURE__ */ jsx(OAuthConsentContext.Provider, {
				value: {
					componentName,
					oauthClientId: p.oauthClientId,
					scope: p.scope,
					scopes: p.scopes,
					oauthApplicationName: p.oAuthApplicationName,
					oauthApplicationLogoUrl: p.oAuthApplicationLogoUrl,
					oauthApplicationUrl: p.oAuthApplicationUrl,
					redirectUrl: p.redirectUrl,
					onAllow: p.onAllow,
					onDeny: p.onDeny,
					appearance: p.appearance,
					enableOrgSelection: p.__internal_enableOrgSelection === true
				},
				children
			});
		}
		case "TaskChooseOrganization": return /* @__PURE__ */ jsx(TaskChooseOrganizationContext.Provider, {
			value: {
				componentName: "TaskChooseOrganization",
				...props
			},
			children: /* @__PURE__ */ jsx(SessionTasksContext.Provider, {
				value: { ...props },
				children
			})
		});
		case "TaskResetPassword": return /* @__PURE__ */ jsx(TaskResetPasswordContext.Provider, {
			value: {
				componentName: "TaskResetPassword",
				...props
			},
			children: /* @__PURE__ */ jsx(SessionTasksContext.Provider, {
				value: { ...props },
				children
			})
		});
		case "TaskSetupMFA": return /* @__PURE__ */ jsx(TaskSetupMFAContext.Provider, {
			value: {
				componentName: "TaskSetupMFA",
				...props
			},
			children: /* @__PURE__ */ jsx(SessionTasksContext.Provider, {
				value: { ...props },
				children
			})
		});
		default: throw new Error(`Unknown component context: ${componentName}`);
	}
}

//#endregion
export { ComponentContextProvider };
//# sourceMappingURL=ClerkUIComponentsContext.js.map