@studiocms/github 0.1.0-beta.31 → 0.1.0
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/effect/github.d.ts +3 -3
- package/dist/effect/github.js +5 -7
- package/package.json +5 -3
package/dist/effect/github.d.ts
CHANGED
|
@@ -45,11 +45,11 @@ declare const GitHubUser_base: Schema.Class<GitHubUser, {
|
|
|
45
45
|
export declare class GitHubUser extends GitHubUser_base {
|
|
46
46
|
}
|
|
47
47
|
declare const GitHubOAuthAPI_base: Effect.Service.Class<GitHubOAuthAPI, "GitHubOAuthAPI", {
|
|
48
|
-
readonly dependencies: readonly [import("effect/Layer").Layer<import("studiocms/lib/auth/verify-email").VerifyEmail,
|
|
48
|
+
readonly dependencies: readonly [import("effect/Layer").Layer<import("studiocms/lib/auth/verify-email").VerifyEmail, import("studiocms/sdk/base").DBClientInitializationError | import("studiocms/sdk/base").SDKInitializationError | import("@withstudiocms/kysely/client").DBCallbackFailure | import("@withstudiocms/kysely/core/errors").DatabaseError | import("effect/Cause").UnknownException | import("effect/ConfigError").ConfigError | import("@withstudiocms/effect/smtp").SMTPError, never>, import("effect/Layer").Layer<Platform.HttpClient.HttpClient, never, never>];
|
|
49
49
|
readonly effect: Effect.Effect<{
|
|
50
50
|
initSession: (context: APIContext) => Effect.Effect<Response, import("effect/ConfigError").ConfigError | import("@withstudiocms/auth-kit/errors").SessionError, never>;
|
|
51
|
-
initCallback: (context: APIContext) => Effect.Effect<Response,
|
|
52
|
-
}, import("
|
|
51
|
+
initCallback: (context: APIContext) => Effect.Effect<Response, any, never>;
|
|
52
|
+
}, import("studiocms/sdk/base").DBClientInitializationError | import("studiocms/sdk/base").SDKInitializationError | import("effect/ConfigError").ConfigError | import("@withstudiocms/auth-kit/errors").SessionError | import("@withstudiocms/auth-kit/errors").UserError, import("studiocms/lib/auth/verify-email").VerifyEmail | Platform.HttpClient.HttpClient>;
|
|
53
53
|
}>;
|
|
54
54
|
/**
|
|
55
55
|
* Provides GitHub OAuth authentication effects for the StudioCMS API.
|
package/dist/effect/github.js
CHANGED
|
@@ -42,13 +42,11 @@ class GitHubOAuthAPI extends Effect.Service()("GitHubOAuthAPI", {
|
|
|
42
42
|
}
|
|
43
43
|
}).pipe(
|
|
44
44
|
Effect.flatMap(Platform.HttpClientResponse.schemaBodyJson(GitHubUser)),
|
|
45
|
-
Effect.
|
|
46
|
-
(error) =>
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
})
|
|
51
|
-
)
|
|
45
|
+
Effect.mapError(
|
|
46
|
+
(error) => new ValidateAuthCodeError({
|
|
47
|
+
provider: GitHubOAuthAPI.ProviderID,
|
|
48
|
+
message: `Failed to fetch user info: ${error.message}`
|
|
49
|
+
})
|
|
52
50
|
)
|
|
53
51
|
);
|
|
54
52
|
});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@studiocms/github",
|
|
3
|
-
"version": "0.1.0
|
|
3
|
+
"version": "0.1.0",
|
|
4
4
|
"description": "Add GitHub OAuth Support to your StudioCMS project.",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "withstudiocms",
|
|
@@ -55,14 +55,16 @@
|
|
|
55
55
|
},
|
|
56
56
|
"peerDependencies": {
|
|
57
57
|
"astro": "^5.12.9",
|
|
58
|
-
"effect": "^3.19.
|
|
58
|
+
"effect": "^3.19.14",
|
|
59
59
|
"vite": "^6.3.4",
|
|
60
|
-
"studiocms": "0.1.0
|
|
60
|
+
"studiocms": "0.1.0"
|
|
61
61
|
},
|
|
62
62
|
"scripts": {
|
|
63
63
|
"build": "buildkit build 'src/**/*.{ts,astro,css,json,png}'",
|
|
64
64
|
"dev": "buildkit dev 'src/**/*.{ts,astro,css,json,png}'",
|
|
65
65
|
"typecheck": "tspc -p tsconfig.tspc.json",
|
|
66
|
+
"effect-check": "pnpm effect-language-service diagnostics --project tsconfig.tspc.json",
|
|
67
|
+
"ci:effect-check": "pnpm effect-check --format github-actions",
|
|
66
68
|
"test": "vitest"
|
|
67
69
|
}
|
|
68
70
|
}
|