@meistrari/auth-nuxt 3.5.0 → 3.6.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/module.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@meistrari/auth-nuxt",
3
3
  "configKey": "telaAuth",
4
- "version": "3.5.0",
4
+ "version": "3.6.1",
5
5
  "builder": {
6
6
  "@nuxt/module-builder": "1.0.2",
7
7
  "unbuild": "3.6.1"
@@ -46,8 +46,12 @@ export interface UseTelaOrganizationReturn {
46
46
  /**
47
47
  * Accepts an organization invitation and updates the active organization state.
48
48
  * @param id - The invitation ID to accept
49
+ * @returns Object containing the application's `homeUrl` when the invitation is
50
+ * scoped to an application that defines one; otherwise `null`.
49
51
  */
50
- acceptInvitation: (id: string) => Promise<void>;
52
+ acceptInvitation: (id: string) => Promise<{
53
+ homeUrl: string | null;
54
+ }>;
51
55
  /**
52
56
  * Cancels a pending organization invitation and updates the active organization state.
53
57
  * @param id - The invitation ID to cancel
@@ -58,7 +58,7 @@ export function useTelaOrganization() {
58
58
  return invitation;
59
59
  }
60
60
  async function acceptInvitation(id) {
61
- await authClient.organization.acceptInvitation(id);
61
+ const { homeUrl } = await authClient.organization.acceptInvitation(id);
62
62
  const members = await authClient.organization.listMembers();
63
63
  if (activeOrganization.value) {
64
64
  activeOrganization.value = {
@@ -66,6 +66,7 @@ export function useTelaOrganization() {
66
66
  members
67
67
  };
68
68
  }
69
+ return { homeUrl };
69
70
  }
70
71
  async function cancelInvitation(id) {
71
72
  await authClient.organization.cancelInvitation(id);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@meistrari/auth-nuxt",
3
- "version": "3.5.0",
3
+ "version": "3.6.1",
4
4
  "type": "module",
5
5
  "exports": {
6
6
  ".": {
@@ -36,7 +36,7 @@
36
36
  "docs": "nuxt-module-build prepare && typedoc"
37
37
  },
38
38
  "dependencies": {
39
- "@meistrari/auth-core": "1.16.0",
39
+ "@meistrari/auth-core": "workspace:*",
40
40
  "jose": "6.1.3"
41
41
  },
42
42
  "peerDependencies": {