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 custom intentsApi prop to TriggerManager #1663

Merged
merged 6 commits into from
Jun 14, 2022

Conversation

doubleface
Copy link
Contributor

To allow custom call to :

  • fetch session code
  • show inApp browser
  • close inApp browser

For cases outside of flagship app

@doubleface doubleface requested a review from Crash-- June 10, 2022 07:32
@doubleface doubleface requested a review from trollepierre as a code owner June 10, 2022 07:32
Copy link
Contributor

@Crash-- Crash-- left a comment

Choose a reason for hiding this comment

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

see comment

Copy link
Contributor

@Crash-- Crash-- left a comment

Choose a reason for hiding this comment

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

see comment

packages/cozy-harvest-lib/src/components/InAppBrowser.jsx Outdated Show resolved Hide resolved
Base automatically changed from feat/sessionCodeInOauthflagship to master June 13, 2022 07:56
@doubleface doubleface force-pushed the feat/HarvestInAppBrowserCustomIntentApi branch from 672e4a3 to eb232a0 Compare June 13, 2022 07:58
@doubleface doubleface requested a review from Crash-- June 13, 2022 15:07
doubleface added 4 commits June 13, 2022 17:08
To allow custom call to :
 - fetch session code
 - show inApp browser
 - close inApp browser

For cases outside of flagship app
This attribute will allow to customize the name of the param with
session code.

For example, with oidc, it will be id_token
@doubleface doubleface force-pushed the feat/HarvestInAppBrowserCustomIntentApi branch from 1305cf4 to 9f99f44 Compare June 13, 2022 15:10
@doubleface doubleface requested a review from JF-Cozy June 14, 2022 07:10
Copy link
Contributor

@Crash-- Crash-- left a comment

Choose a reason for hiding this comment

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

I would have use a context instead of passing props everywhere. Something like:

const { fetchSessionCode, showInAppBrowser, closeInAppBrowser, tokenParamName } = useIntentsApi()

but we're already late on this subject so... let's approve.

@doubleface doubleface merged commit 3ca44b9 into master Jun 14, 2022
@doubleface doubleface deleted the feat/HarvestInAppBrowserCustomIntentApi branch June 14, 2022 07:47
doubleface pushed a commit to cozy/cozy-home that referenced this pull request Jun 14, 2022
To get custom intentsApi prop for TriggerManager [PR](cozy/cozy-libs#1663)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants