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: add Figma provider #1139

Merged
merged 1 commit into from Jun 23, 2023
Merged

Conversation

bnjmnt4n
Copy link
Contributor

What kind of change does this PR introduce?

Feature

What is the current behavior?

No provider for Figma.

What is the new behavior?

This PR adds a new provider for Figma.

Additional context

The Figma OAuth2 API only provides a single scope ("file_read"), so there isn't a more restrictive scope solely for getting user metadata.

Figma developer reference: https://www.figma.com/developers/api#oauth2

@bnjmnt4n
Copy link
Contributor Author

Wanted to add a suggestion for the provider tests: it would be helpful to have an explicit checklist of things to test for each provider (in CONTRIBUTING.md or elsewhere). My process was to copy the tests from another provider (GitHub in this case), then modify to suit the Figma provider. Since there are lots of differences between each provider (eg. GitHub returns multiple emails whereas Figma only returns one), it's easy to miss out on tests if you're just copying and modifying from another provider's tests (which is what I presume most would do).

Copy link
Member

@kangmingtay kangmingtay left a comment

Choose a reason for hiding this comment

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

lgtm - once you've finished adding the docs to https://github.com/supabase/supabase/tree/master/apps/docs/pages/guides/auth/social-login we can merge this one in! let us know if you need any help with that.

@bnjmnt4n
Copy link
Contributor Author

Oops, forgot to update: made a PR for the docs + adding the Figma provider to the Studio settings at supabase/supabase#15083. Let me know if there's any tweaks required.

@kangmingtay
Copy link
Member

@bnjmnt4n yup a checklist does sound good, we actually have plans to refactor the oauth test suite to use gock for mocking the requests and have an interface to clearly define the testing methods that need to be implemented. It's just not high on the priority list since the current tests are already functional.

@kangmingtay kangmingtay merged commit 007324c into supabase:master Jun 23, 2023
2 checks passed
@github-actions
Copy link
Contributor

🎉 This PR is included in version 2.75.0 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

@bnjmnt4n bnjmnt4n deleted the providers/figma branch June 23, 2023 07:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants