academe-kit 0.7.7 → 0.8.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/dist/index.cjs CHANGED
@@ -6039,11 +6039,12 @@ const setCookie = (name, value, domain) => {
6039
6039
  }
6040
6040
  document.cookie = cookieParts.join("; ");
6041
6041
  };
6042
- const AcademeAuthProvider = ({ realm, hubUrl, children, clientId, keycloakUrl, apiBaseUrl, skipApiUserFetch, }) => {
6042
+ const AcademeAuthProvider = ({ realm, hubUrl, children, clientId, keycloakUrl, apiBaseUrl, redirectUri, skipApiUserFetch, }) => {
6043
6043
  const oidcConfig = {
6044
6044
  authority: `${keycloakUrl}/realms/${realm}`,
6045
6045
  client_id: clientId,
6046
- redirect_uri: typeof window !== "undefined"
6046
+ redirect_uri: redirectUri ||
6047
+ typeof window !== "undefined"
6047
6048
  ? window.location.origin
6048
6049
  : process.env.NEXT_PUBLIC_REDIRECT_URI,
6049
6050
  scope: "openid profile email",
@@ -6346,7 +6347,7 @@ const SecurityProvider = ({ apiBaseUrl = "https://stg-api.academe.com.br", skipA
6346
6347
  }, []);
6347
6348
  // Memoizar o value do context para evitar re-renders desnecessários
6348
6349
  const contextValue = React2.useMemo(() => ({
6349
- isInitialized: !isLoading || isRefreshing || !!accessToken,
6350
+ isInitialized: !isLoading || isRefreshing,
6350
6351
  isTokenReady,
6351
6352
  user: currentUser,
6352
6353
  refreshUserData,