@inzombieland/nuxt-common 1.19.20 → 1.19.21
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 +1 -1
- package/dist/module.mjs +6 -6
- package/dist/runtime/composables/use-api-fetch.d.ts +1 -1
- package/dist/runtime/composables/use-api-fetch.js +1 -1
- package/dist/runtime/composables/use-user-actions.d.ts +1 -98
- package/dist/runtime/composables/use-user-actions.js +1 -1
- package/dist/runtime/plugin.js +1 -1
- package/dist/runtime/{api → server/api}/index.d.ts +7 -7
- package/dist/runtime/{api → server/api}/index.js +1 -1
- package/package.json +7 -7
- /package/dist/runtime/{api → server/api}/account/account.get.d.ts +0 -0
- /package/dist/runtime/{api → server/api}/account/account.get.js +0 -0
- /package/dist/runtime/{api → server/api}/account/authcheck.get.d.ts +0 -0
- /package/dist/runtime/{api → server/api}/account/authcheck.get.js +0 -0
- /package/dist/runtime/{api → server/api}/account/default-handler.d.ts +0 -0
- /package/dist/runtime/{api → server/api}/account/default-handler.js +0 -0
- /package/dist/runtime/{api → server/api}/account/middleware.d.ts +0 -0
- /package/dist/runtime/{api → server/api}/account/middleware.js +0 -0
- /package/dist/runtime/{api → server/api}/account/token.get.d.ts +0 -0
- /package/dist/runtime/{api → server/api}/account/token.get.js +0 -0
- /package/dist/runtime/{api → server/api}/user-actions.d.ts +0 -0
- /package/dist/runtime/{api → server/api}/user-actions.js +0 -0
package/dist/module.json
CHANGED
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.19.
|
|
5
|
+
const version = "1.19.21";
|
|
6
6
|
|
|
7
7
|
const module$1 = defineNuxtModule({
|
|
8
8
|
meta: {
|
|
@@ -17,20 +17,20 @@ const module$1 = defineNuxtModule({
|
|
|
17
17
|
const addServerDefaultHandler = (route) => {
|
|
18
18
|
addServerHandler({
|
|
19
19
|
route,
|
|
20
|
-
handler: resolve(runtimeDir, "api/account/default-handler")
|
|
20
|
+
handler: resolve(runtimeDir, "server/api/account/default-handler")
|
|
21
21
|
});
|
|
22
22
|
};
|
|
23
23
|
addServerHandler({
|
|
24
24
|
middleware: true,
|
|
25
|
-
handler: resolve(runtimeDir, "api/account/middleware")
|
|
25
|
+
handler: resolve(runtimeDir, "server/api/account/middleware")
|
|
26
26
|
});
|
|
27
27
|
addServerHandler({
|
|
28
28
|
route: "/account/0/authcheck",
|
|
29
|
-
handler: resolve(runtimeDir, "api/account/authcheck.get")
|
|
29
|
+
handler: resolve(runtimeDir, "server/api/account/authcheck.get")
|
|
30
30
|
});
|
|
31
31
|
addServerHandler({
|
|
32
32
|
route: "/account/0/token",
|
|
33
|
-
handler: resolve(runtimeDir, "api/account/token.get")
|
|
33
|
+
handler: resolve(runtimeDir, "server/api/account/token.get")
|
|
34
34
|
});
|
|
35
35
|
addServerDefaultHandler("/account/0/signin");
|
|
36
36
|
addServerDefaultHandler("/account/0/signinbycode/sendcode");
|
|
@@ -39,7 +39,7 @@ const module$1 = defineNuxtModule({
|
|
|
39
39
|
addServerDefaultHandler("/account/0/recovery");
|
|
40
40
|
addServerHandler({
|
|
41
41
|
route: "/account",
|
|
42
|
-
handler: resolve(runtimeDir, "api/account/account.get")
|
|
42
|
+
handler: resolve(runtimeDir, "server/api/account/account.get")
|
|
43
43
|
});
|
|
44
44
|
addImportsDir(resolve(runtimeDir, "composables"));
|
|
45
45
|
addPlugin(resolve(runtimeDir, "plugin"));
|
|
@@ -1,98 +1 @@
|
|
|
1
|
-
export declare const useUserActions: () =>
|
|
2
|
-
signIn: (body: Record<string, any>) => Promise<import("../packages/core/index.js").GetUserResponse | {
|
|
3
|
-
key: string;
|
|
4
|
-
}>;
|
|
5
|
-
signInByCodeSendCode: (body: Record<string, any>) => Promise<{
|
|
6
|
-
key: string;
|
|
7
|
-
}>;
|
|
8
|
-
signInByCodeVerifyCode: (body: Record<string, any>) => Promise<import("../packages/core/index.js").GetUserResponse>;
|
|
9
|
-
getToken: (body: Record<string, any>) => Promise<import("../packages/core/index.js").GetUserResponse>;
|
|
10
|
-
signUp: (body: Record<string, any>) => Promise<{
|
|
11
|
-
key: string;
|
|
12
|
-
}>;
|
|
13
|
-
confirmEmail: (body: {
|
|
14
|
-
key: string;
|
|
15
|
-
code: string;
|
|
16
|
-
}) => Promise<{}>;
|
|
17
|
-
resendActivationEmail: (body: {
|
|
18
|
-
email: string;
|
|
19
|
-
}) => Promise<{
|
|
20
|
-
key: string;
|
|
21
|
-
}>;
|
|
22
|
-
logout: () => Promise<void>;
|
|
23
|
-
recovery: (body: Record<string, any>) => Promise<{
|
|
24
|
-
key: string;
|
|
25
|
-
}>;
|
|
26
|
-
confirmRecovery: (body: {
|
|
27
|
-
key: string;
|
|
28
|
-
code: string;
|
|
29
|
-
}) => Promise<{
|
|
30
|
-
key: string;
|
|
31
|
-
}>;
|
|
32
|
-
resetPassword: (body: {
|
|
33
|
-
key: string;
|
|
34
|
-
password: string;
|
|
35
|
-
}) => Promise<{}>;
|
|
36
|
-
changeName: (body: {
|
|
37
|
-
firstName: string;
|
|
38
|
-
lastName?: string;
|
|
39
|
-
middleName?: string;
|
|
40
|
-
}) => Promise<void>;
|
|
41
|
-
changeBirthday: (body: {
|
|
42
|
-
day?: number;
|
|
43
|
-
month?: number;
|
|
44
|
-
year?: number;
|
|
45
|
-
}) => Promise<void>;
|
|
46
|
-
changeGender: (body: {
|
|
47
|
-
gender: string;
|
|
48
|
-
}) => Promise<void>;
|
|
49
|
-
changePassword: (body: {
|
|
50
|
-
password: string;
|
|
51
|
-
newPassword: string;
|
|
52
|
-
}) => Promise<{
|
|
53
|
-
key: string;
|
|
54
|
-
}>;
|
|
55
|
-
confirmPasswordChange: (body: {
|
|
56
|
-
key: string;
|
|
57
|
-
code: string;
|
|
58
|
-
newPassword?: string;
|
|
59
|
-
}) => Promise<void>;
|
|
60
|
-
changeEmail: (body: {
|
|
61
|
-
email: string;
|
|
62
|
-
password: string;
|
|
63
|
-
}) => Promise<{
|
|
64
|
-
key: string;
|
|
65
|
-
}>;
|
|
66
|
-
confirmEmailChange: (body: {
|
|
67
|
-
key: string;
|
|
68
|
-
code: string;
|
|
69
|
-
email?: string;
|
|
70
|
-
}) => Promise<void>;
|
|
71
|
-
changePhone: (body: {
|
|
72
|
-
phone: string;
|
|
73
|
-
password: string;
|
|
74
|
-
}) => Promise<void>;
|
|
75
|
-
changeTheme: (body: {
|
|
76
|
-
theme: "light" | "dark";
|
|
77
|
-
}) => Promise<void>;
|
|
78
|
-
changeLocale: (body: {
|
|
79
|
-
locale: string;
|
|
80
|
-
}) => Promise<void>;
|
|
81
|
-
changeAvatar: (body: FormData) => Promise<void>;
|
|
82
|
-
deleteAvatar: () => Promise<void>;
|
|
83
|
-
fetchActiveSessions: () => Promise<{
|
|
84
|
-
sessions: import("../packages/core/index.js").ActiveSession[];
|
|
85
|
-
}>;
|
|
86
|
-
logoutActiveSession: (body: {
|
|
87
|
-
sessionId: string;
|
|
88
|
-
visitorId: string;
|
|
89
|
-
}) => Promise<any>;
|
|
90
|
-
logoutFromAllActiveSessions: () => Promise<any>;
|
|
91
|
-
deleteAccount: () => Promise<{
|
|
92
|
-
key: string;
|
|
93
|
-
}>;
|
|
94
|
-
confirmDeleteAccount: (body: {
|
|
95
|
-
key: string;
|
|
96
|
-
code: string;
|
|
97
|
-
}) => Promise<void>;
|
|
98
|
-
};
|
|
1
|
+
export declare const useUserActions: () => any;
|
package/dist/runtime/plugin.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { addRouteMiddleware, defineNuxtPlugin } from "#app";
|
|
2
2
|
import { useNuxtApp, useRequestHeaders, useRuntimeConfig, useState } from "#imports";
|
|
3
3
|
import { watch } from "vue";
|
|
4
|
-
import { fetch, getUser } from "./api
|
|
4
|
+
import { fetch, getUser } from "./api";
|
|
5
5
|
import { authMiddleware, guestMiddleware, localeMiddleware } from "./middleware/index.js";
|
|
6
6
|
import { defineVuePlugins, useThemeMode } from "./packages/core/index.js";
|
|
7
7
|
import { flush, setToken, setUser } from "./packages/core/api-client.js";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { type Fetch } from "
|
|
1
|
+
import { type Fetch } from "../../packages/core/index.js";
|
|
2
2
|
export declare const config: {
|
|
3
3
|
apiBaseURL: any;
|
|
4
4
|
cometServerURL: any;
|
|
@@ -8,7 +8,7 @@ export declare const config: {
|
|
|
8
8
|
isDesktopApp: any;
|
|
9
9
|
appName: any;
|
|
10
10
|
getHostname: () => string;
|
|
11
|
-
getDevice: () => Promise<
|
|
11
|
+
getDevice: () => Promise<string>;
|
|
12
12
|
useRequestHeaders: (include?: string[]) => {
|
|
13
13
|
baseURL: string;
|
|
14
14
|
headers: {
|
|
@@ -16,15 +16,15 @@ export declare const config: {
|
|
|
16
16
|
};
|
|
17
17
|
};
|
|
18
18
|
};
|
|
19
|
-
declare const fetch: Fetch, getUser: () => Promise<import("
|
|
20
|
-
signIn: (body: Record<string, any>) => Promise<import("
|
|
19
|
+
declare const fetch: Fetch, getUser: () => Promise<import("../../packages/core/index.js").GetUserResponse>, useApiFetch: () => Fetch, userActions: {
|
|
20
|
+
signIn: (body: Record<string, any>) => Promise<import("../../packages/core/index.js").GetUserResponse | {
|
|
21
21
|
key: string;
|
|
22
22
|
}>;
|
|
23
23
|
signInByCodeSendCode: (body: Record<string, any>) => Promise<{
|
|
24
24
|
key: string;
|
|
25
25
|
}>;
|
|
26
|
-
signInByCodeVerifyCode: (body: Record<string, any>) => Promise<import("
|
|
27
|
-
getToken: (body: Record<string, any>) => Promise<import("
|
|
26
|
+
signInByCodeVerifyCode: (body: Record<string, any>) => Promise<import("../../packages/core/index.js").GetUserResponse>;
|
|
27
|
+
getToken: (body: Record<string, any>) => Promise<import("../../packages/core/index.js").GetUserResponse>;
|
|
28
28
|
signUp: (body: Record<string, any>) => Promise<{
|
|
29
29
|
key: string;
|
|
30
30
|
}>;
|
|
@@ -99,7 +99,7 @@ declare const fetch: Fetch, getUser: () => Promise<import("../packages/core/inde
|
|
|
99
99
|
changeAvatar: (body: FormData) => Promise<void>;
|
|
100
100
|
deleteAvatar: () => Promise<void>;
|
|
101
101
|
fetchActiveSessions: () => Promise<{
|
|
102
|
-
sessions: import("
|
|
102
|
+
sessions: import("../../packages/core/index.js").ActiveSession[];
|
|
103
103
|
}>;
|
|
104
104
|
logoutActiveSession: (body: {
|
|
105
105
|
sessionId: string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { useNuxtApp, useRequestHeaders, useRequestURL } from "#imports";
|
|
2
|
-
import { initApiFetch } from "
|
|
2
|
+
import { initApiFetch } from "../../packages/core/index.js";
|
|
3
3
|
export const config = {
|
|
4
4
|
apiBaseURL: import.meta.env.VITE_API_BASE_URL,
|
|
5
5
|
cometServerURL: import.meta.env.VITE_COMET_SERVER_URL,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@inzombieland/nuxt-common",
|
|
3
|
-
"version": "1.19.
|
|
3
|
+
"version": "1.19.21",
|
|
4
4
|
"license": "ISC",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"exports": {
|
|
@@ -49,17 +49,17 @@
|
|
|
49
49
|
"devDependencies": {
|
|
50
50
|
"@braintree/sanitize-url": "^7.1.1",
|
|
51
51
|
"@fingerprintjs/fingerprintjs": "^4.6.2",
|
|
52
|
-
"@inzombieland/nuxt-common": "^1.19.
|
|
52
|
+
"@inzombieland/nuxt-common": "^1.19.20",
|
|
53
53
|
"@nuxt/devtools": "latest",
|
|
54
54
|
"@nuxt/icon": "^1.15.0",
|
|
55
55
|
"@nuxt/kit": "^4.3.0",
|
|
56
56
|
"@nuxt/module-builder": "^1.0.2",
|
|
57
57
|
"@nuxt/schema": "^4.3.0",
|
|
58
|
-
"@nuxtjs/i18n": "^10.1
|
|
58
|
+
"@nuxtjs/i18n": "^10.2.1",
|
|
59
59
|
"@nuxtjs/tailwindcss": "^6.14.0",
|
|
60
60
|
"@pinia/colada": "^0.21.2",
|
|
61
61
|
"@pinia/colada-nuxt": "^0.3.1",
|
|
62
|
-
"@pinia/nuxt": "^0.11.
|
|
62
|
+
"@pinia/nuxt": "^0.11.3",
|
|
63
63
|
"@primeuix/themes": "^1.2.3",
|
|
64
64
|
"@primevue/nuxt-module": "^4.3.9",
|
|
65
65
|
"@rollup/plugin-commonjs": "^26.0.3",
|
|
@@ -72,15 +72,15 @@
|
|
|
72
72
|
"@varlet/ui": "^3.10.5",
|
|
73
73
|
"@vite-pwa/assets-generator": "^1.0.1",
|
|
74
74
|
"@vite-pwa/nuxt": "^1.0.4",
|
|
75
|
-
"@vueuse/nuxt": "^
|
|
75
|
+
"@vueuse/nuxt": "^14.1.0",
|
|
76
76
|
"autoprefixer": "^10.4.20",
|
|
77
77
|
"changelogen": "^0.6.2",
|
|
78
78
|
"config": "^3.3.12",
|
|
79
79
|
"eslint": "^9.36.0",
|
|
80
80
|
"lerna": "^8.2.2",
|
|
81
81
|
"nuxt": "^4.3.0",
|
|
82
|
-
"ofetch": "^1.
|
|
83
|
-
"pinia": "^3.0.
|
|
82
|
+
"ofetch": "^1.5.1",
|
|
83
|
+
"pinia": "^3.0.4",
|
|
84
84
|
"postcss": "^8.5.6",
|
|
85
85
|
"postcss-pxtorem": "^6.1.0",
|
|
86
86
|
"prettier": "^3.6.2",
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|