@asgardeo/react 0.25.6 → 0.25.8

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.
Files changed (24) hide show
  1. package/dist/cjs/index.js +527 -356
  2. package/dist/cjs/index.js.map +4 -4
  3. package/dist/components/adapters/FormContainer.d.ts.map +1 -1
  4. package/dist/components/presentation/CreateOrganization/BaseCreateOrganization.d.ts.map +1 -1
  5. package/dist/components/presentation/CreateOrganization/BaseCreateOrganization.styles.d.ts.map +1 -1
  6. package/dist/components/presentation/OrganizationList/BaseOrganizationList.d.ts +4 -0
  7. package/dist/components/presentation/OrganizationList/BaseOrganizationList.d.ts.map +1 -1
  8. package/dist/components/presentation/OrganizationList/BaseOrganizationList.styles.d.ts.map +1 -1
  9. package/dist/components/presentation/OrganizationProfile/BaseOrganizationProfile.d.ts +4 -0
  10. package/dist/components/presentation/OrganizationProfile/BaseOrganizationProfile.d.ts.map +1 -1
  11. package/dist/components/presentation/OrganizationProfile/BaseOrganizationProfile.styles.d.ts.map +1 -1
  12. package/dist/components/presentation/UserProfile/BaseUserProfile.d.ts.map +1 -1
  13. package/dist/components/presentation/auth/Recovery/v1/RecoveryOptionFactory.d.ts +7 -2
  14. package/dist/components/presentation/auth/Recovery/v1/RecoveryOptionFactory.d.ts.map +1 -1
  15. package/dist/components/presentation/auth/SignIn/v1/BaseSignIn.d.ts.map +1 -1
  16. package/dist/components/presentation/auth/SignUp/v1/BaseSignUp.d.ts.map +1 -1
  17. package/dist/components/presentation/auth/SignUp/v1/SignUpOptionFactory.d.ts +7 -2
  18. package/dist/components/presentation/auth/SignUp/v1/SignUpOptionFactory.d.ts.map +1 -1
  19. package/dist/components/presentation/auth/SignUp/v2/BaseSignUp.d.ts.map +1 -1
  20. package/dist/index.js +258 -88
  21. package/dist/index.js.map +4 -4
  22. package/dist/utils/resolveFlowErrorMessage.d.ts +35 -0
  23. package/dist/utils/resolveFlowErrorMessage.d.ts.map +1 -0
  24. package/package.json +4 -4
@@ -0,0 +1,35 @@
1
+ /**
2
+ * Copyright (c) 2026, 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
+ /**
19
+ * Extracts a human-readable message from an error raised by an embedded flow call.
20
+ *
21
+ * Handles:
22
+ * - `AsgardeoAPIError` (and any `Error`) whose message embeds the server's JSON error payload,
23
+ * e.g. `Authorization request failed: {"code":"ABA-60007","message":"...","description":"..."}`.
24
+ * - Errors that crossed a serialization boundary (such as a Next.js server action) and arrive as a plain
25
+ * `Error` whose message is the stringified API error:
26
+ * `[AsgardeoAPIError] (code="...") (HTTP 400 - Bad Request)\nMessage: ...`.
27
+ * - Plain objects carrying `description` / `message` fields, and raw strings.
28
+ *
29
+ * @param error - The caught error.
30
+ * @param fallback - Message to use when nothing meaningful can be extracted.
31
+ * @returns A message suitable for showing to the user.
32
+ */
33
+ declare const resolveFlowErrorMessage: (error: unknown, fallback: string) => string;
34
+ export default resolveFlowErrorMessage;
35
+ //# sourceMappingURL=resolveFlowErrorMessage.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"resolveFlowErrorMessage.d.ts","sourceRoot":"","sources":["../../src/utils/resolveFlowErrorMessage.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH;;;;;;;;;;;;;;GAcG;AACH,QAAA,MAAM,uBAAuB,UAAW,OAAO,YAAY,MAAM,KAAG,MA0CnE,CAAC;AAEF,eAAe,uBAAuB,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@asgardeo/react",
3
- "version": "0.25.6",
3
+ "version": "0.25.8",
4
4
  "description": "React implementation of Asgardeo JavaScript SDK.",
5
5
  "keywords": [
6
6
  "asgardeo",
@@ -53,14 +53,14 @@
53
53
  "react": ">=16.8.0"
54
54
  },
55
55
  "dependencies": {
56
+ "@asgardeo/browser": "0.7.12",
57
+ "@asgardeo/i18n": "0.4.7",
56
58
  "@emotion/css": "11.13.5",
57
59
  "@floating-ui/react": "0.27.12",
58
60
  "@types/react-dom": "19.2.3",
59
61
  "dompurify": "3.3.1",
60
62
  "react-dom": "19.2.4",
61
- "tslib": "2.8.1",
62
- "@asgardeo/browser": "0.7.10",
63
- "@asgardeo/i18n": "0.4.5"
63
+ "tslib": "2.8.1"
64
64
  },
65
65
  "publishConfig": {
66
66
  "access": "public"