Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(providers): add SimpleLogin oidc #10491

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

alexaka1
Copy link

@alexaka1 alexaka1 commented Apr 6, 2024

☕️ Reasoning

Adds Sign in with SimpleLogin support.

SimpleLogin is built for privacy-conscious site owners and protects your users identity. Open-source, Developer-first, SimpleLogin can be integrated in minutes.

🧢 Checklist

  • Documentation
  • Tests
  • Ready to be merged

🎫 Affected issues

📌 Resources

Copy link

vercel bot commented Apr 6, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
auth-docs ❌ Failed (Inspect) May 26, 2024 4:55pm
1 Ignored Deployment
Name Status Preview Comments Updated (UTC)
next-auth-docs ⬜️ Ignored (Inspect) Visit Preview May 26, 2024 4:55pm

Copy link

vercel bot commented Apr 6, 2024

@alexaka1 is attempting to deploy a commit to the authjs Team on Vercel.

A member of the Team first needs to authorize it.

@alexaka1
Copy link
Author

alexaka1 commented Apr 6, 2024

I am not sure what tests are necessary. I have tested the code with my own website, and users are able to log in with SimpleLogin. I would love some input from a maintainer about tests.

@ndom91
Copy link
Member

ndom91 commented May 12, 2024

This looks pretty good already! Can you add a docs page at /docs/pages/getting-started/providers/simplelogin.mdx?

Thanks 🙏

@alexaka1
Copy link
Author

I have included an mdx.

@ndom91
Copy link
Member

ndom91 commented May 19, 2024

Two minor nit picks,

  1. Is the brand color really #fff? Maybe lets go with their pink-ish color from the logo
  2. There seems to be a prettier issue in your mdx file (docs/pages/getting-started/providers/simplelogin.mdx)

@alexaka1
Copy link
Author

Tbh, I couldn't figure out what the brand color does. But will get them fixed.

Copy link

codecov bot commented May 19, 2024

Codecov Report

Attention: Patch coverage is 0% with 103 lines in your changes are missing coverage. Please review.

Project coverage is 38.59%. Comparing base (2a9eb3b) to head (309b584).

Files Patch % Lines
packages/core/src/providers/simplelogin.ts 0.00% 103 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main   #10491      +/-   ##
==========================================
- Coverage   38.74%   38.59%   -0.15%     
==========================================
  Files         176      177       +1     
  Lines       27887    27990     +103     
  Branches     1223     1224       +1     
==========================================
  Hits        10804    10804              
- Misses      17083    17186     +103     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

* By default, Auth.js assumes that the SimpleLogin provider is
* based on the [Open ID Connect](https://openid.net/specs/openid-connect-core-1_0.html) specification.
*
*
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

New line duplicated

Suggested change
*

Comment on lines +39 to +41
* const response = await Auth(request, {
* providers: [SimpleLogin({ clientId: SIMPLELOGIN_CLIENT_ID, clientSecret: SIMPLELOGIN_CLIENT_SECRET })],
* })
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

pnpm format

Suggested change
* const response = await Auth(request, {
* providers: [SimpleLogin({ clientId: SIMPLELOGIN_CLIENT_ID, clientSecret: SIMPLELOGIN_CLIENT_SECRET })],
* })
* const response = await Auth(request, {
* providers: [
* SimpleLogin({
* clientId: SIMPLELOGIN_CLIENT_ID,
* clientSecret: SIMPLELOGIN_CLIENT_SECRET,
* }),
* ],
* })

* ```
*
* #### Configuration
*```js
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

js to ts

Suggested change
*```js
*```ts

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
core Refers to `@auth/core` providers
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants