@inzombieland/nuxt-common 1.18.43 → 1.18.44

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,6 +1,6 @@
1
1
  {
2
2
  "name": "@inzombieland/nuxt-common",
3
- "version": "1.18.43",
3
+ "version": "1.18.44",
4
4
  "configKey": "nuxt-common",
5
5
  "builder": {
6
6
  "@nuxt/module-builder": "0.6.0",
package/dist/module.mjs CHANGED
@@ -2,7 +2,7 @@ import { fileURLToPath } from 'node:url';
2
2
  import { defineNuxtModule, createResolver, addServerHandler, addImportsDir, addPlugin, addComponent } from '@nuxt/kit';
3
3
 
4
4
  const name = "@inzombieland/nuxt-common";
5
- const version = "1.18.43";
5
+ const version = "1.18.44";
6
6
 
7
7
  const module = defineNuxtModule({
8
8
  meta: {
@@ -21,6 +21,18 @@ declare const fetch: Fetch, getUser: () => Promise<import("src/runtime/packages/
21
21
  key: string;
22
22
  }>;
23
23
  signInByCodeVerifyCode: (body: Record<string, any>) => Promise<import("src/runtime/packages/core/types").GetUserResponse>;
24
+ signUp: (body: Record<string, any>) => Promise<{
25
+ key: string;
26
+ }>;
27
+ confirmEmail: (body: {
28
+ key: string;
29
+ code: string;
30
+ }) => Promise<{}>;
31
+ resendActivationEmail: (body: {
32
+ email: string;
33
+ }) => Promise<{
34
+ key: string;
35
+ }>;
24
36
  logout: () => Promise<void>;
25
37
  fetchActiveSessions: () => Promise<{
26
38
  sessions: import("src/runtime/packages/core/types").ActiveSession[];
@@ -3,6 +3,18 @@ export declare const signIn: (body: Record<string, any>) => Promise<import("src/
3
3
  key: string;
4
4
  }>;
5
5
  export declare const signInByCodeVerifyCode: (body: Record<string, any>) => Promise<import("src/runtime/packages/core/types").GetUserResponse>;
6
+ export declare const signUp: (body: Record<string, any>) => Promise<{
7
+ key: string;
8
+ }>;
9
+ export declare const confirmEmail: (body: {
10
+ key: string;
11
+ code: string;
12
+ }) => Promise<{}>;
13
+ export declare const resendActivationEmail: (body: {
14
+ email: string;
15
+ }) => Promise<{
16
+ key: string;
17
+ }>;
6
18
  export declare const logout: () => Promise<void>;
7
19
  export declare const changeName: (body: {
8
20
  firstName: string;
@@ -55,22 +67,6 @@ export declare const signInByCodeSendCode: (body: {
55
67
  }) => Promise<{
56
68
  key: string;
57
69
  }>;
58
- export declare const signUp: (body: {
59
- email: string;
60
- password: string;
61
- passwordConfirm: string;
62
- }) => Promise<{
63
- key: string;
64
- }>;
65
- export declare const confirmEmail: (body: {
66
- key: string;
67
- code: string;
68
- }) => Promise<{}>;
69
- export declare const resendActivationEmail: (body: {
70
- email: string;
71
- }) => Promise<{
72
- key: string;
73
- }>;
74
70
  export declare const recovery: (body: {
75
71
  email: string;
76
72
  }) => Promise<{
@@ -3,6 +3,9 @@ import { flush } from "../packages/core/api-client.mjs";
3
3
  import { fetch, userActions } from "./index.mjs";
4
4
  export const signIn = userActions.signIn;
5
5
  export const signInByCodeVerifyCode = userActions.signInByCodeVerifyCode;
6
+ export const signUp = userActions.signUp;
7
+ export const confirmEmail = userActions.confirmEmail;
8
+ export const resendActivationEmail = userActions.resendActivationEmail;
6
9
  export const logout = userActions.logout;
7
10
  export const changeName = userActions.changeName;
8
11
  export const changeBirthday = userActions.changeBirthday;
@@ -24,30 +27,6 @@ export const signInByCodeSendCode = async (body) => {
24
27
  headers: useRequestHeaders(["cookie"])
25
28
  });
26
29
  };
27
- export const signUp = async (body) => {
28
- return await fetch("/account/0/signup", {
29
- body,
30
- method: "POST",
31
- baseURL: "/",
32
- headers: useRequestHeaders(["cookie"])
33
- });
34
- };
35
- export const confirmEmail = async (body) => {
36
- return await fetch("/account/0/signup", {
37
- body,
38
- method: "PUT",
39
- baseURL: "/",
40
- headers: useRequestHeaders(["cookie"])
41
- });
42
- };
43
- export const resendActivationEmail = async (body) => {
44
- return await fetch("/account/0/signup", {
45
- body,
46
- method: "PATCH",
47
- baseURL: "/",
48
- headers: useRequestHeaders(["cookie"])
49
- });
50
- };
51
30
  export const recovery = async (body) => {
52
31
  return await fetch("/account/0/recovery", {
53
32
  body,
@@ -13,6 +13,18 @@ export declare function initApiFetch($fetch: Fetch, config: FetchConfig): {
13
13
  key: string;
14
14
  }>;
15
15
  signInByCodeVerifyCode: (body: Record<string, any>) => Promise<import("./types").GetUserResponse>;
16
+ signUp: (body: Record<string, any>) => Promise<{
17
+ key: string;
18
+ }>;
19
+ confirmEmail: (body: {
20
+ key: string;
21
+ code: string;
22
+ }) => Promise<{}>;
23
+ resendActivationEmail: (body: {
24
+ email: string;
25
+ }) => Promise<{
26
+ key: string;
27
+ }>;
16
28
  logout: () => Promise<void>;
17
29
  fetchActiveSessions: () => Promise<{
18
30
  sessions: import("./types").ActiveSession[];
@@ -76,6 +88,18 @@ export declare const useUserActions: () => Ref<{
76
88
  key: string;
77
89
  }>;
78
90
  signInByCodeVerifyCode: (body: Record<string, any>) => Promise<import("./types").GetUserResponse>;
91
+ signUp: (body: Record<string, any>) => Promise<{
92
+ key: string;
93
+ }>;
94
+ confirmEmail: (body: {
95
+ key: string;
96
+ code: string;
97
+ }) => Promise<{}>;
98
+ resendActivationEmail: (body: {
99
+ email: string;
100
+ }) => Promise<{
101
+ key: string;
102
+ }>;
79
103
  logout: () => Promise<void>;
80
104
  fetchActiveSessions: () => Promise<{
81
105
  sessions: import("./types").ActiveSession[];
@@ -137,6 +161,18 @@ export declare const useUserActions: () => Ref<{
137
161
  key: string;
138
162
  }>;
139
163
  signInByCodeVerifyCode: (body: Record<string, any>) => Promise<import("./types").GetUserResponse>;
164
+ signUp: (body: Record<string, any>) => Promise<{
165
+ key: string;
166
+ }>;
167
+ confirmEmail: (body: {
168
+ key: string;
169
+ code: string;
170
+ }) => Promise<{}>;
171
+ resendActivationEmail: (body: {
172
+ email: string;
173
+ }) => Promise<{
174
+ key: string;
175
+ }>;
140
176
  logout: () => Promise<void>;
141
177
  fetchActiveSessions: () => Promise<{
142
178
  sessions: import("./types").ActiveSession[];
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@inzombieland/core",
3
- "version": "1.18.43",
3
+ "version": "1.18.44",
4
4
  "type": "module",
5
5
  "license": "ISC",
6
6
  "main": "./index.mjs",
@@ -5,6 +5,18 @@ export declare const createApiUserActions: (fetch: Fetch, config: FetchConfig, g
5
5
  key: string;
6
6
  }>;
7
7
  signInByCodeVerifyCode: (body: Record<string, any>) => Promise<GetUserResponse>;
8
+ signUp: (body: Record<string, any>) => Promise<{
9
+ key: string;
10
+ }>;
11
+ confirmEmail: (body: {
12
+ key: string;
13
+ code: string;
14
+ }) => Promise<{}>;
15
+ resendActivationEmail: (body: {
16
+ email: string;
17
+ }) => Promise<{
18
+ key: string;
19
+ }>;
8
20
  logout: () => Promise<void>;
9
21
  fetchActiveSessions: () => Promise<{
10
22
  sessions: ActiveSession[];
@@ -33,6 +33,27 @@ export const createApiUserActions = once(
33
33
  setToken(accessToken);
34
34
  return await getUser();
35
35
  },
36
+ signUp: async (body) => {
37
+ return await fetch("/account/0/signup", {
38
+ body,
39
+ method: "POST",
40
+ ...config.useRequestHeaders?.(["cookie"]) ?? {}
41
+ });
42
+ },
43
+ confirmEmail: async (body) => {
44
+ return await fetch("/account/0/signup", {
45
+ body,
46
+ method: "PUT",
47
+ ...config.useRequestHeaders?.(["cookie"]) ?? {}
48
+ });
49
+ },
50
+ resendActivationEmail: async (body) => {
51
+ return await fetch("/account/0/signup", {
52
+ body,
53
+ method: "PATCH",
54
+ ...config.useRequestHeaders?.(["cookie"]) ?? {}
55
+ });
56
+ },
36
57
  logout: async () => {
37
58
  const user = useUser();
38
59
  try {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@inzombieland/nuxt-common",
3
- "version": "1.18.43",
3
+ "version": "1.18.44",
4
4
  "license": "ISC",
5
5
  "type": "module",
6
6
  "exports": {