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

Add API to show error messages from failed token fetches #498

Open
wants to merge 17 commits into
base: main
Choose a base branch
from
Prev Previous commit
Next Next commit
nits
npm1 committed Jul 31, 2024
commit ef6cb65973c0fabcf41a6fd34770f229fec9ce7e
12 changes: 7 additions & 5 deletions spec/index.bs
Original file line number Diff line number Diff line change
@@ -691,8 +691,8 @@ dictionary DisconnectedAccount {
<!-- ============================================================ -->

This specification introduces a new type of {{DOMException}}, the {{IdentityCredentialError}}. It
is used when the [=IDP=] cannot create an {{IdentityCredential}} after the user has requested to use
a federated account.
is used when the [=user agent=] does not receive an identity assertion after the user has requested
to use a federated account.

<pre class="idl">
[Exposed=Window, SecureContext]
@@ -707,8 +707,10 @@ a federated account.
The {{IdentityCredentialError/constructor()}}, given a |realm|, a {{DOMString}} |message| and a
{{IdentityCredentialErrorInit}} |options| must run the following steps:
1. Invoke the {{DOMException}}'s {{DOMException/constructor()}}, passing |realm| and |message|.
1. Set <a>this</a>.{{IdentityCredentialError/code}} to |options|.{{IdentityCredentialError/code}}.
1. Set <a>this</a>.{{IdentityCredentialError/url}} to |options.{{IdentityCredentialError/url}}.
1. Set <a>this</a>.{{IdentityCredentialError/code}} to |options|.{{IdentityCredentialError/code}}
if it is present in |options|, or to "" otherwise.
1. Set <a>this</a>.{{IdentityCredentialError/url}} to |options|.{{IdentityCredentialError/url}}
if it is present in |options|, or to "" otherwise.
npm1 marked this conversation as resolved.
Show resolved Hide resolved
</div>

<dl>
@@ -1055,7 +1057,7 @@ throwing the exception.
1. Wait until the UI is acknowledged or dismissed by the user.

Note: this wait means the [=user agent=] rejects the call only after the UI has been
dismissed by the user.
closed by the user.
1. Return |credential|.
</div>