@better-auth/electron 1.7.0-rc.3 → 1.7.0-rc.5
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/client.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as PACKAGE_VERSION } from "./version-
|
|
1
|
+
import { t as PACKAGE_VERSION } from "./version-CwxXc1Y6.mjs";
|
|
2
2
|
import { n as isProcessType, r as parseProtocolScheme, t as getChannelPrefixWithDelimiter } from "./utils-C5XBRvIU.mjs";
|
|
3
3
|
import { BetterAuthError } from "@better-auth/core/error";
|
|
4
4
|
import { base64, base64Url } from "@better-auth/utils/base64";
|
package/dist/index.d.mts
CHANGED
|
@@ -15,13 +15,10 @@ declare const electron: (options?: ElectronOptions | undefined) => {
|
|
|
15
15
|
hooks: {
|
|
16
16
|
after: ({
|
|
17
17
|
matcher: (ctx: HookEndpointContext) => boolean;
|
|
18
|
-
handler: (inputContext: import("better-call").MiddlewareInputContext<import("better-call").MiddlewareOptions>) => Promise<void
|
|
18
|
+
handler: import("better-call").Middleware<import("better-call").MiddlewareOptions, (inputContext: import("better-call").MiddlewareInputContext<import("better-call").MiddlewareOptions>) => Promise<void>>;
|
|
19
19
|
} | {
|
|
20
20
|
matcher: (ctx: HookEndpointContext) => boolean;
|
|
21
|
-
handler: (inputContext: import("better-call").MiddlewareInputContext<import("better-call").MiddlewareOptions>) => Promise<import("better-call").MiddlewareContext<import("better-call").MiddlewareOptions, {
|
|
22
|
-
returned?: unknown | undefined;
|
|
23
|
-
responseHeaders?: Headers | undefined;
|
|
24
|
-
} & import("better-auth").PluginContext<import("better-auth").BetterAuthOptions> & import("better-auth").InfoContext & {
|
|
21
|
+
handler: import("better-call").Middleware<import("better-call").MiddlewareOptions, (inputContext: import("better-call").MiddlewareInputContext<import("better-call").MiddlewareOptions>) => Promise<import("better-call").MiddlewareContext<import("better-call").MiddlewareOptions, import("better-auth").PluginContext<import("better-auth").BetterAuthOptions> & import("better-auth").InfoContext & {
|
|
25
22
|
options: import("better-auth").BetterAuthOptions;
|
|
26
23
|
trustedOrigins: string[];
|
|
27
24
|
trustedProviders: string[];
|
|
@@ -113,6 +110,7 @@ declare const electron: (options?: ElectronOptions | undefined) => {
|
|
|
113
110
|
updateAge: number;
|
|
114
111
|
expiresIn: number;
|
|
115
112
|
freshAge: number;
|
|
113
|
+
cookieCacheSigner?: import("better-auth").CookieCacheSigner | undefined;
|
|
116
114
|
cookieRefreshCache: false | {
|
|
117
115
|
enabled: true;
|
|
118
116
|
updateAge: number;
|
|
@@ -146,9 +144,12 @@ declare const electron: (options?: ElectronOptions | undefined) => {
|
|
|
146
144
|
skipCSRFCheck: boolean;
|
|
147
145
|
runInBackground: (promise: Promise<unknown>) => void;
|
|
148
146
|
runInBackgroundOrAwait: (promise: Promise<unknown> | void) => import("better-auth").Awaitable<unknown>;
|
|
147
|
+
} & {
|
|
148
|
+
returned?: unknown | undefined;
|
|
149
|
+
responseHeaders?: Headers | undefined;
|
|
149
150
|
}> | {
|
|
150
151
|
electron_authorization_code: string;
|
|
151
|
-
} | undefined
|
|
152
|
+
} | undefined>>;
|
|
152
153
|
})[];
|
|
153
154
|
};
|
|
154
155
|
endpoints: {
|
|
@@ -251,7 +252,7 @@ declare const electron: (options?: ElectronOptions | undefined) => {
|
|
|
251
252
|
body: z.ZodObject<{
|
|
252
253
|
callbackURL: z.ZodOptional<z.ZodString>;
|
|
253
254
|
}, z.core.$strip>;
|
|
254
|
-
use: ((inputContext: import("better-call").MiddlewareInputContext<import("better-call").MiddlewareOptions>) => Promise<{
|
|
255
|
+
use: import("better-call").Middleware<import("better-call").MiddlewareOptions, (inputContext: import("better-call").MiddlewareInputContext<import("better-call").MiddlewareOptions>) => Promise<{
|
|
255
256
|
session: {
|
|
256
257
|
session: Record<string, any> & {
|
|
257
258
|
id: string;
|
|
@@ -273,7 +274,7 @@ declare const electron: (options?: ElectronOptions | undefined) => {
|
|
|
273
274
|
image?: string | null | undefined;
|
|
274
275
|
};
|
|
275
276
|
};
|
|
276
|
-
}
|
|
277
|
+
}>>[];
|
|
277
278
|
requireHeaders: true;
|
|
278
279
|
metadata: {
|
|
279
280
|
openapi: {
|
package/dist/index.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as PACKAGE_VERSION } from "./version-
|
|
1
|
+
import { t as PACKAGE_VERSION } from "./version-CwxXc1Y6.mjs";
|
|
2
2
|
import { createAuthMiddleware } from "@better-auth/core/api";
|
|
3
3
|
import { APIError, BASE_ERROR_CODES } from "@better-auth/core/error";
|
|
4
4
|
import { base64Url } from "@better-auth/utils/base64";
|
package/dist/preload.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import electron, { contextBridge } from "electron";
|
|
2
|
-
//#region ../../node_modules/.pnpm/better-call@1.
|
|
2
|
+
//#region ../../node_modules/.pnpm/better-call@1.4.0_zod@4.3.6/node_modules/better-call/dist/error.mjs
|
|
3
3
|
function isErrorStackTraceLimitWritable() {
|
|
4
4
|
const desc = Object.getOwnPropertyDescriptor(Error, "stackTraceLimit");
|
|
5
5
|
if (desc === void 0) return Object.isExtensible(Error);
|
|
@@ -96,6 +96,10 @@ const statusCodes = {
|
|
|
96
96
|
NETWORK_AUTHENTICATION_REQUIRED: 511
|
|
97
97
|
};
|
|
98
98
|
var InternalAPIError = class extends Error {
|
|
99
|
+
status;
|
|
100
|
+
body;
|
|
101
|
+
headers;
|
|
102
|
+
statusCode;
|
|
99
103
|
constructor(status = "INTERNAL_SERVER_ERROR", body = void 0, headers = {}, statusCode = typeof status === "number" ? status : statusCodes[status]) {
|
|
100
104
|
super(body?.message, body?.cause ? { cause: body.cause } : void 0);
|
|
101
105
|
this.status = status;
|
package/dist/proxy.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as PACKAGE_VERSION } from "./version-
|
|
1
|
+
import { t as PACKAGE_VERSION } from "./version-CwxXc1Y6.mjs";
|
|
2
2
|
import { r as parseProtocolScheme } from "./utils-C5XBRvIU.mjs";
|
|
3
3
|
import { parseCookies } from "better-auth/cookies";
|
|
4
4
|
//#region src/proxy.ts
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@better-auth/electron",
|
|
3
|
-
"version": "1.7.0-rc.
|
|
3
|
+
"version": "1.7.0-rc.5",
|
|
4
4
|
"description": "Better Auth integration for Electron applications.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -80,17 +80,17 @@
|
|
|
80
80
|
"better-sqlite3": "^12.11.1",
|
|
81
81
|
"electron": "^43.1.1",
|
|
82
82
|
"tsdown": "0.22.7",
|
|
83
|
-
"@better-auth/core": "1.7.0-rc.
|
|
84
|
-
"better-auth": "1.7.0-rc.
|
|
83
|
+
"@better-auth/core": "1.7.0-rc.5",
|
|
84
|
+
"better-auth": "1.7.0-rc.5"
|
|
85
85
|
},
|
|
86
86
|
"peerDependencies": {
|
|
87
87
|
"@better-auth/utils": "0.4.2",
|
|
88
88
|
"@better-fetch/fetch": "1.3.1",
|
|
89
|
-
"better-call": "1.
|
|
89
|
+
"better-call": "1.4.0",
|
|
90
90
|
"conf": "^15.0.2",
|
|
91
91
|
"electron": ">=36.0.0",
|
|
92
|
-
"@better-auth/core": "^1.7.0-rc.
|
|
93
|
-
"better-auth": "^1.7.0-rc.
|
|
92
|
+
"@better-auth/core": "^1.7.0-rc.5",
|
|
93
|
+
"better-auth": "^1.7.0-rc.5"
|
|
94
94
|
},
|
|
95
95
|
"peerDependenciesMeta": {
|
|
96
96
|
"electron": {
|