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: two-step login and improved UI APIs for Ory Elements v1 #3934

Merged
merged 34 commits into from
Jul 11, 2024

Conversation

aeneasr
Copy link
Member

@aeneasr aeneasr commented May 24, 2024

Related issue(s)

Checklist

  • I have read the contributing guidelines.
  • I have referenced an issue containing the design document if my change
    introduces a new feature.
  • I am following the
    contributing code guidelines.
  • I have read the security policy.
  • I confirm that this pull request does not address a security
    vulnerability. If this pull request addresses a security vulnerability, I
    confirm that I got the approval (please contact
    security@ory.sh) from the maintainers to push
    the changes.
  • I have added tests that prove my fix is effective or that my feature
    works.
  • I have added or changed the documentation.

Further Comments

text/message_system.go Outdated Show resolved Hide resolved
@aeneasr
Copy link
Member Author

aeneasr commented May 24, 2024 via email

@zepatrik
Copy link
Member

Previously we used inline definitions, e.g. https://github.com/ory/elements/blob/a93569f94b252ba193658199559f944162f9b6ab/src/react-components/ory/user-auth-card.tsx#L131-L134
This is convenient for developing, as everything is in-place. For IDs we used kind of a namespace approach, but the main mechanism to ensure uniqueness of IDs is the tooling that comes with react-intl.
It extracts all messages from the code and generates the "default" translation, from witch you then create all other translations.

Copy link

codecov bot commented Jun 11, 2024

Codecov Report

Attention: Patch coverage is 81.44499% with 113 lines in your changes missing coverage. Please review.

Project coverage is 78.35%. Comparing base (b5a66e0) to head (0da0c9b).

Files Patch % Lines
selfservice/strategy/passkey/passkey_login.go 82.22% 12 Missing and 12 partials ⚠️
selfservice/strategy/webauthn/login.go 67.12% 13 Missing and 11 partials ⚠️
selfservice/strategy/idfirst/strategy_login.go 73.86% 11 Missing and 12 partials ⚠️
ui/node/attributes.go 69.38% 13 Missing and 2 partials ⚠️
selfservice/strategy/password/login.go 76.36% 7 Missing and 6 partials ⚠️
selfservice/strategy/oidc/strategy_login.go 78.43% 6 Missing and 5 partials ⚠️
selfservice/flow/login/handler.go 91.66% 2 Missing ⚠️
driver/config/config.go 90.90% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #3934      +/-   ##
==========================================
+ Coverage   78.23%   78.35%   +0.11%     
==========================================
  Files         365      369       +4     
  Lines       25586    25967     +381     
==========================================
+ Hits        20018    20347     +329     
- Misses       4039     4073      +34     
- Partials     1529     1547      +18     

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

embedx/config.schema.json Show resolved Hide resolved
internal/driver.go Outdated Show resolved Hide resolved
selfservice/flow/continue_with.go Outdated Show resolved Hide resolved
@aeneasr aeneasr force-pushed the two-step-login branch 8 times, most recently from 2976ede to 50f72a4 Compare June 20, 2024 04:59
This patch adds the new `continue_with` action `redirect_browser_to`, which contains the redirect URL the app should redirect to. It is only supported for SPA (not server-side browser apps, not native apps) flows at this point in time.
Using `OnLoadTrigger` and `OnClickTrigger` one can now map the trigger to the corresponding JavaScript function.

For example, trigger `{"on_click_trigger":"oryWebAuthnRegistration"}` should be translated to `window.oryWebAuthnRegistration()`:

```
if (attrs.onClickTrigger) {
  window[attrs.onClickTrigger]()
}
```
@aeneasr aeneasr marked this pull request as ready for review July 8, 2024 09:50
@aeneasr aeneasr requested a review from hperl as a code owner July 8, 2024 09:50
@aeneasr aeneasr changed the title feat: APIs for Ory Elements v1 feat: two-step login and improved UI APIs for Ory Elements v1 Jul 8, 2024
.github/workflows/ci.yaml Outdated Show resolved Hide resolved
Copy link
Member Author

@aeneasr aeneasr left a comment

Choose a reason for hiding this comment

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

In my view this is good to go.

jonas-jonas and others added 2 commits July 9, 2024 10:38
Co-authored-by: hackerman <3372410+aeneasr@users.noreply.github.com>
jonas-jonas
jonas-jonas previously approved these changes Jul 9, 2024
Copy link
Contributor

@jonas-jonas jonas-jonas left a comment

Choose a reason for hiding this comment

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

Let's go 🚀

@aeneasr aeneasr merged commit 2ad0ed9 into master Jul 11, 2024
27 checks passed
@aeneasr aeneasr deleted the two-step-login branch July 11, 2024 14:08
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.

None yet

3 participants