@rxap/oauth 19.0.1 → 19.0.2-dev.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +4 -0
- package/README.md +25 -23
- package/compodoc/changelog.html +2 -0
- package/compodoc/dependencies.html +2 -2
- package/compodoc/index.html +15 -21
- package/compodoc/js/search/search_index.js +2 -2
- package/compodoc/properties.html +1 -1
- package/docs/documentation.json +27 -27
- package/docs/html/assets/highlight.css +6 -13
- package/docs/html/classes/AuthenticationService.html +2 -2
- package/docs/html/functions/AuthenticationGuard.html +1 -1
- package/docs/html/functions/ProvideAuth.html +1 -1
- package/docs/html/functions/withAuthConfig.html +1 -1
- package/docs/html/index.html +22 -21
- package/docs/markdown/README.md +25 -23
- package/docs/markdown/classes/AuthenticationService.md +8 -8
- package/docs/markdown/functions/AuthenticationGuard.md +1 -1
- package/docs/markdown/functions/ProvideAuth.md +1 -1
- package/docs/markdown/functions/withAuthConfig.md +1 -1
- package/docs/wiki/Class.AuthenticationService.md +8 -8
- package/docs/wiki/Function.AuthenticationGuard.md +1 -1
- package/docs/wiki/Function.ProvideAuth.md +1 -1
- package/docs/wiki/Function.withAuthConfig.md +1 -1
- package/docs/wiki/Home.md +25 -23
- package/package.json +7 -7
package/docs/html/index.html
CHANGED
|
@@ -1,33 +1,34 @@
|
|
|
1
1
|
<!DOCTYPE html><html class="default" lang="en" data-base="."><head><meta charset="utf-8"/><meta http-equiv="x-ua-compatible" content="IE=edge"/><title>@rxap/oauth</title><meta name="description" content="Documentation for @rxap/oauth"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="assets/style.css"/><link rel="stylesheet" href="assets/highlight.css"/><script defer src="assets/main.js"></script><script async src="assets/icons.js" id="tsd-icons-script"></script><script async src="assets/search.js" id="tsd-search-script"></script><script async src="assets/navigation.js" id="tsd-nav-script"></script></head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os";document.body.style.display="none";setTimeout(() => app?app.showPage():document.body.style.removeProperty("display"),500)</script><header class="tsd-page-toolbar"><div class="tsd-toolbar-contents container"><div class="table-cell" id="tsd-search"><div class="field"><label for="tsd-search-field" class="tsd-widget tsd-toolbar-icon search no-caption"><svg width="16" height="16" viewBox="0 0 16 16" fill="none" aria-hidden="true"><use href="assets/icons.svg#icon-search"></use></svg></label><input type="text" id="tsd-search-field" aria-label="Search"/></div><div class="field"><div id="tsd-toolbar-links"></div></div><ul class="results"><li class="state loading">Preparing search index...</li><li class="state failure">The search index is not available</li></ul><a href="index.html" class="title">@rxap/oauth</a></div><div class="table-cell" id="tsd-widgets"><a href="#" class="tsd-widget tsd-toolbar-icon menu no-caption" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none" aria-hidden="true"><use href="assets/icons.svg#icon-menu"></use></svg></a></div></div></header><div class="container container-main"><div class="col-content"><div class="tsd-page-title"><h1>@rxap/oauth</h1></div><div class="tsd-panel tsd-typography"><p>This package provides an authentication guard and service for Angular applications using OAuth 2.0 and OpenID Connect. It simplifies the integration of authentication flows, including sign-in, sign-out, and token management, with support for disabled authentication scenarios. The package also includes a provider function to streamline configuration.</p>
|
|
2
2
|
<p><a href="https://www.npmjs.com/package/@rxap/oauth"><img src="https://img.shields.io/npm/v/@rxap/oauth?style=flat-square" alt="npm version"></a>
|
|
3
|
-
<a href="https://commitizen.github.io/cz-cli/"><img src="https://img.shields.io/badge/commitizen-friendly-brightgreen.svg?style=flat-square" alt="commitizen
|
|
4
|
-
|
|
5
|
-
<
|
|
6
|
-
prettier"></a>
|
|
7
|
-
<img src="https://img.shields.io/librariesio/release/npm/@rxap/oauth" alt="Libraries.io dependency status for latest release, scoped npm
|
|
8
|
-
package">
|
|
3
|
+
<a href="https://commitizen.github.io/cz-cli/"><img src="https://img.shields.io/badge/commitizen-friendly-brightgreen.svg?style=flat-square" alt="commitizen friendly"></a>
|
|
4
|
+
<a href="https://github.com/prettier/prettier"><img src="https://img.shields.io/badge/styled_with-prettier-ff69b4.svg?style=flat-square" alt="styled with prettier"></a>
|
|
5
|
+
<img src="https://img.shields.io/librariesio/release/npm/@rxap/oauth" alt="Libraries.io dependency status for latest release, scoped npm package">
|
|
9
6
|
<img src="https://img.shields.io/npm/dm/@rxap/oauth" alt="npm">
|
|
10
|
-
<img src="https://img.shields.io/npm/l/@rxap/oauth" alt="NPM">
|
|
11
|
-
<a href="#installation">Installation</a></p>
|
|
7
|
+
<img src="https://img.shields.io/npm/l/@rxap/oauth" alt="NPM"></p>
|
|
12
8
|
<ul>
|
|
9
|
+
<li><a href="#installation">Installation</a></li>
|
|
13
10
|
<li><a href="#generators">Generators</a>
|
|
14
11
|
<ul>
|
|
15
12
|
<li><a href="#init">init</a></li>
|
|
16
13
|
</ul>
|
|
17
14
|
</li>
|
|
18
15
|
</ul>
|
|
19
|
-
<a id="installation
|
|
20
|
-
<pre><code
|
|
21
|
-
</code><button>Copy</button></pre>
|
|
16
|
+
<a id="installation" class="tsd-anchor"></a><h1 class="tsd-anchor-link">Installation<a href="#installation" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></h1><p><strong>Add the package to your workspace:</strong></p>
|
|
17
|
+
<pre><code class="bash"><span class="hl-0">yarn</span><span class="hl-1"> </span><span class="hl-2">add</span><span class="hl-1"> </span><span class="hl-2">@rxap/oauth</span>
|
|
18
|
+
</code><button type="button">Copy</button></pre>
|
|
22
19
|
|
|
23
|
-
<p><strong>
|
|
24
|
-
<
|
|
25
|
-
|
|
26
|
-
>
|
|
27
|
-
Initialize the package in the workspace
|
|
20
|
+
<p><strong>Install peer dependencies:</strong></p>
|
|
21
|
+
<pre><code class="bash"><span class="hl-0">yarn</span><span class="hl-1"> </span><span class="hl-2">add</span><span class="hl-1"> </span><span class="hl-2">@angular/core@^19.1.3</span><span class="hl-1"> </span><span class="hl-2">@angular/router@^19.1.3</span><span class="hl-1"> </span><span class="hl-2">@rxap/authentication@^19.0.1</span><span class="hl-1"> </span><span class="hl-2">@rxap/rxjs@^1.1.12</span><span class="hl-1"> </span><span class="hl-2">angular-oauth2-oidc@^15.0.1</span><span class="hl-1"> </span><span class="hl-2">angular-oauth2-oidc-jwks@^15.0.1</span><span class="hl-1"> </span><span class="hl-2">rxjs@^7.8.1</span><span class="hl-1"> </span>
|
|
22
|
+
</code><button type="button">Copy</button></pre>
|
|
28
23
|
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
24
|
+
<p><strong>Execute the init generator:</strong></p>
|
|
25
|
+
<pre><code class="bash"><span class="hl-0">yarn</span><span class="hl-1"> </span><span class="hl-2">nx</span><span class="hl-1"> </span><span class="hl-2">g</span><span class="hl-1"> </span><span class="hl-2">@rxap/oauth:init</span>
|
|
26
|
+
</code><button type="button">Copy</button></pre>
|
|
27
|
+
|
|
28
|
+
<a id="generators" class="tsd-anchor"></a><h1 class="tsd-anchor-link">Generators<a href="#generators" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></h1><a id="init" class="tsd-anchor"></a><h2 class="tsd-anchor-link">init<a href="#init" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="assets/icons.svg#icon-anchor"></use></svg></a></h2><blockquote>
|
|
29
|
+
<p>Initialize the package in the workspace</p>
|
|
30
|
+
</blockquote>
|
|
31
|
+
<pre><code class="bash"><span class="hl-0">nx</span><span class="hl-1"> </span><span class="hl-2">g</span><span class="hl-1"> </span><span class="hl-2">@rxap/oauth:init</span>
|
|
32
|
+
</code><button type="button">Copy</button></pre>
|
|
33
|
+
|
|
34
|
+
</div></div><div class="col-sidebar"><div class="page-menu"><div class="tsd-navigation settings"><details class="tsd-accordion"><summary class="tsd-accordion-summary"><h3><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="assets/icons.svg#icon-chevronDown"></use></svg>Settings</h3></summary><div class="tsd-accordion-details"><div class="tsd-filter-visibility"><span class="settings-label">Member Visibility</span><ul id="tsd-filter-options"><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-protected" name="protected"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Protected</span></label></li><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-inherited" name="inherited" checked/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Inherited</span></label></li><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-external" name="external"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>External</span></label></li></ul></div><div class="tsd-theme-toggle"><label class="settings-label" for="tsd-theme">Theme</label><select id="tsd-theme"><option value="os">OS</option><option value="light">Light</option><option value="dark">Dark</option></select></div></div></details></div><details open class="tsd-accordion tsd-page-navigation"><summary class="tsd-accordion-summary"><h3><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="assets/icons.svg#icon-chevronDown"></use></svg>On This Page</h3></summary><div class="tsd-accordion-details"><a href="#installation"><span>Installation</span></a><a href="#generators"><span>Generators</span></a><ul><li><a href="#init"><span>init</span></a></li></ul></div></details></div><div class="site-menu"><nav class="tsd-navigation"><a href="modules.html">@rxap/oauth</a><ul class="tsd-small-nested-navigation" id="tsd-nav-container"><li>Loading...</li></ul></nav></div></div></div><footer><p class="tsd-generator">Generated using <a href="https://typedoc.org/" target="_blank">TypeDoc</a></p></footer><div class="overlay"></div></body></html>
|
package/docs/markdown/README.md
CHANGED
|
@@ -5,33 +5,35 @@
|
|
|
5
5
|
This package provides an authentication guard and service for Angular applications using OAuth 2.0 and OpenID Connect. It simplifies the integration of authentication flows, including sign-in, sign-out, and token management, with support for disabled authentication scenarios. The package also includes a provider function to streamline configuration.
|
|
6
6
|
|
|
7
7
|
[](https://www.npmjs.com/package/@rxap/oauth)
|
|
8
|
-
[](https://github.com/prettier/prettier)
|
|
12
|
-

|
|
8
|
+
[](https://commitizen.github.io/cz-cli/)
|
|
9
|
+
[](https://github.com/prettier/prettier)
|
|
10
|
+

|
|
14
11
|

|
|
15
|
-

|
|
16
|
-
|
|
12
|
+

|
|
13
|
+
|
|
14
|
+
- [Installation](#installation)
|
|
17
15
|
- [Generators](#generators)
|
|
18
|
-
|
|
16
|
+
- [init](#init)
|
|
17
|
+
|
|
18
|
+
# Installation
|
|
19
19
|
|
|
20
|
-
|
|
21
|
-
|
|
20
|
+
**Add the package to your workspace:**
|
|
21
|
+
```bash
|
|
22
|
+
yarn add @rxap/oauth
|
|
23
|
+
```
|
|
24
|
+
**Install peer dependencies:**
|
|
25
|
+
```bash
|
|
26
|
+
yarn add @angular/core@^19.1.3 @angular/router@^19.1.3 @rxap/authentication@^19.0.1 @rxap/rxjs@^1.1.12 angular-oauth2-oidc@^15.0.1 angular-oauth2-oidc-jwks@^15.0.1 rxjs@^7.8.1
|
|
27
|
+
```
|
|
28
|
+
**Execute the init generator:**
|
|
29
|
+
```bash
|
|
30
|
+
yarn nx g @rxap/oauth:init
|
|
22
31
|
```
|
|
23
|
-
**Install peer dependencies:** ```bash yarn add
|
|
24
|
-
@angular/core@^19.1.3 @angular/router@^19.1.3 @rxap/authentication@^19.0.1-dev.5 @rxap/rxjs@^1.1.12-dev.5 angular-oauth2-oidc@^15.0.1 angular-oauth2-oidc-jwks@^15.0.1 rxjs@^7.8.1
|
|
25
|
-
```
|
|
26
|
-
**Execute the init generator:** ```bash yarn nx g
|
|
27
|
-
@rxap/oauth:init ```
|
|
28
32
|
# Generators
|
|
29
33
|
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
>
|
|
33
|
-
Initialize the package in the workspace
|
|
34
|
+
## init
|
|
35
|
+
> Initialize the package in the workspace
|
|
34
36
|
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
37
|
+
```bash
|
|
38
|
+
nx g @rxap/oauth:init
|
|
39
|
+
```
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
|
|
7
7
|
# Class: AuthenticationService
|
|
8
8
|
|
|
9
|
-
Defined in: [authentication.service.ts:35](https://gitlab.com/rxap/packages/-/blob/
|
|
9
|
+
Defined in: [authentication.service.ts:35](https://gitlab.com/rxap/packages/-/blob/9978b20018f781a5952245bfe2db15ab7612611c/packages/angular/oauth/src/lib/authentication.service.ts#L35)
|
|
10
10
|
|
|
11
11
|
## Implements
|
|
12
12
|
|
|
@@ -18,7 +18,7 @@ Defined in: [authentication.service.ts:35](https://gitlab.com/rxap/packages/-/bl
|
|
|
18
18
|
|
|
19
19
|
> **new AuthenticationService**(`oauthService`, `authConfig`, `authenticationAccessToken`, `isAuthDisabled`): [`AuthenticationService`](AuthenticationService.md)
|
|
20
20
|
|
|
21
|
-
Defined in: [authentication.service.ts:45](https://gitlab.com/rxap/packages/-/blob/
|
|
21
|
+
Defined in: [authentication.service.ts:45](https://gitlab.com/rxap/packages/-/blob/9978b20018f781a5952245bfe2db15ab7612611c/packages/angular/oauth/src/lib/authentication.service.ts#L45)
|
|
22
22
|
|
|
23
23
|
#### Parameters
|
|
24
24
|
|
|
@@ -48,7 +48,7 @@ Defined in: [authentication.service.ts:45](https://gitlab.com/rxap/packages/-/bl
|
|
|
48
48
|
|
|
49
49
|
> **events$**: `Observable`\<`AuthenticationEvent`\> = `EMPTY`
|
|
50
50
|
|
|
51
|
-
Defined in: [authentication.service.ts:36](https://gitlab.com/rxap/packages/-/blob/
|
|
51
|
+
Defined in: [authentication.service.ts:36](https://gitlab.com/rxap/packages/-/blob/9978b20018f781a5952245bfe2db15ab7612611c/packages/angular/oauth/src/lib/authentication.service.ts#L36)
|
|
52
52
|
|
|
53
53
|
#### Implementation of
|
|
54
54
|
|
|
@@ -60,7 +60,7 @@ Defined in: [authentication.service.ts:36](https://gitlab.com/rxap/packages/-/bl
|
|
|
60
60
|
|
|
61
61
|
> `readonly` **isAuthenticated$**: `BehaviorSubject`\<`null` \| `boolean`\>
|
|
62
62
|
|
|
63
|
-
Defined in: [authentication.service.ts:37](https://gitlab.com/rxap/packages/-/blob/
|
|
63
|
+
Defined in: [authentication.service.ts:37](https://gitlab.com/rxap/packages/-/blob/9978b20018f781a5952245bfe2db15ab7612611c/packages/angular/oauth/src/lib/authentication.service.ts#L37)
|
|
64
64
|
|
|
65
65
|
#### Implementation of
|
|
66
66
|
|
|
@@ -72,7 +72,7 @@ Defined in: [authentication.service.ts:37](https://gitlab.com/rxap/packages/-/bl
|
|
|
72
72
|
|
|
73
73
|
> **init**(): `void`
|
|
74
74
|
|
|
75
|
-
Defined in: [authentication.service.ts:71](https://gitlab.com/rxap/packages/-/blob/
|
|
75
|
+
Defined in: [authentication.service.ts:71](https://gitlab.com/rxap/packages/-/blob/9978b20018f781a5952245bfe2db15ab7612611c/packages/angular/oauth/src/lib/authentication.service.ts#L71)
|
|
76
76
|
|
|
77
77
|
#### Returns
|
|
78
78
|
|
|
@@ -84,7 +84,7 @@ Defined in: [authentication.service.ts:71](https://gitlab.com/rxap/packages/-/bl
|
|
|
84
84
|
|
|
85
85
|
> **isAuthenticated**(): `Promise`\<`boolean`\>
|
|
86
86
|
|
|
87
|
-
Defined in: [authentication.service.ts:153](https://gitlab.com/rxap/packages/-/blob/
|
|
87
|
+
Defined in: [authentication.service.ts:153](https://gitlab.com/rxap/packages/-/blob/9978b20018f781a5952245bfe2db15ab7612611c/packages/angular/oauth/src/lib/authentication.service.ts#L153)
|
|
88
88
|
|
|
89
89
|
#### Returns
|
|
90
90
|
|
|
@@ -100,7 +100,7 @@ Defined in: [authentication.service.ts:153](https://gitlab.com/rxap/packages/-/b
|
|
|
100
100
|
|
|
101
101
|
> **signIn**(): `void`
|
|
102
102
|
|
|
103
|
-
Defined in: [authentication.service.ts:134](https://gitlab.com/rxap/packages/-/blob/
|
|
103
|
+
Defined in: [authentication.service.ts:134](https://gitlab.com/rxap/packages/-/blob/9978b20018f781a5952245bfe2db15ab7612611c/packages/angular/oauth/src/lib/authentication.service.ts#L134)
|
|
104
104
|
|
|
105
105
|
#### Returns
|
|
106
106
|
|
|
@@ -112,7 +112,7 @@ Defined in: [authentication.service.ts:134](https://gitlab.com/rxap/packages/-/b
|
|
|
112
112
|
|
|
113
113
|
> **signOut**(): `Promise`\<`void`\>
|
|
114
114
|
|
|
115
|
-
Defined in: [authentication.service.ts:123](https://gitlab.com/rxap/packages/-/blob/
|
|
115
|
+
Defined in: [authentication.service.ts:123](https://gitlab.com/rxap/packages/-/blob/9978b20018f781a5952245bfe2db15ab7612611c/packages/angular/oauth/src/lib/authentication.service.ts#L123)
|
|
116
116
|
|
|
117
117
|
#### Returns
|
|
118
118
|
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
|
|
9
9
|
> **AuthenticationGuard**(`route`, `state`): `Promise`\<`boolean`\>
|
|
10
10
|
|
|
11
|
-
Defined in: [authentication-guard.ts:12](https://gitlab.com/rxap/packages/-/blob/
|
|
11
|
+
Defined in: [authentication-guard.ts:12](https://gitlab.com/rxap/packages/-/blob/9978b20018f781a5952245bfe2db15ab7612611c/packages/angular/oauth/src/lib/authentication-guard.ts#L12)
|
|
12
12
|
|
|
13
13
|
## Parameters
|
|
14
14
|
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
|
|
9
9
|
> **ProvideAuth**(...`withConfigs`): `Provider`[]
|
|
10
10
|
|
|
11
|
-
Defined in: [provide-auth.ts:9](https://gitlab.com/rxap/packages/-/blob/
|
|
11
|
+
Defined in: [provide-auth.ts:9](https://gitlab.com/rxap/packages/-/blob/9978b20018f781a5952245bfe2db15ab7612611c/packages/angular/oauth/src/lib/provide-auth.ts#L9)
|
|
12
12
|
|
|
13
13
|
## Parameters
|
|
14
14
|
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
|
|
9
9
|
> **withAuthConfig**(`config`): `Provider`
|
|
10
10
|
|
|
11
|
-
Defined in: [provide-auth.ts:20](https://gitlab.com/rxap/packages/-/blob/
|
|
11
|
+
Defined in: [provide-auth.ts:20](https://gitlab.com/rxap/packages/-/blob/9978b20018f781a5952245bfe2db15ab7612611c/packages/angular/oauth/src/lib/provide-auth.ts#L20)
|
|
12
12
|
|
|
13
13
|
## Parameters
|
|
14
14
|
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
# Class: AuthenticationService
|
|
4
4
|
|
|
5
|
-
Defined in: [authentication.service.ts:35](https://gitlab.com/rxap/packages/-/blob/
|
|
5
|
+
Defined in: [authentication.service.ts:35](https://gitlab.com/rxap/packages/-/blob/9978b20018f781a5952245bfe2db15ab7612611c/packages/angular/oauth/src/lib/authentication.service.ts#L35)
|
|
6
6
|
|
|
7
7
|
## Implements
|
|
8
8
|
|
|
@@ -14,7 +14,7 @@ Defined in: [authentication.service.ts:35](https://gitlab.com/rxap/packages/-/bl
|
|
|
14
14
|
|
|
15
15
|
> **new AuthenticationService**(`oauthService`, `authConfig`, `authenticationAccessToken`, `isAuthDisabled`): [`AuthenticationService`](../wiki/Class.AuthenticationService)
|
|
16
16
|
|
|
17
|
-
Defined in: [authentication.service.ts:45](https://gitlab.com/rxap/packages/-/blob/
|
|
17
|
+
Defined in: [authentication.service.ts:45](https://gitlab.com/rxap/packages/-/blob/9978b20018f781a5952245bfe2db15ab7612611c/packages/angular/oauth/src/lib/authentication.service.ts#L45)
|
|
18
18
|
|
|
19
19
|
#### Parameters
|
|
20
20
|
|
|
@@ -44,7 +44,7 @@ Defined in: [authentication.service.ts:45](https://gitlab.com/rxap/packages/-/bl
|
|
|
44
44
|
|
|
45
45
|
> **events$**: `Observable`\<`AuthenticationEvent`\> = `EMPTY`
|
|
46
46
|
|
|
47
|
-
Defined in: [authentication.service.ts:36](https://gitlab.com/rxap/packages/-/blob/
|
|
47
|
+
Defined in: [authentication.service.ts:36](https://gitlab.com/rxap/packages/-/blob/9978b20018f781a5952245bfe2db15ab7612611c/packages/angular/oauth/src/lib/authentication.service.ts#L36)
|
|
48
48
|
|
|
49
49
|
#### Implementation of
|
|
50
50
|
|
|
@@ -56,7 +56,7 @@ Defined in: [authentication.service.ts:36](https://gitlab.com/rxap/packages/-/bl
|
|
|
56
56
|
|
|
57
57
|
> `readonly` **isAuthenticated$**: `BehaviorSubject`\<`null` \| `boolean`\>
|
|
58
58
|
|
|
59
|
-
Defined in: [authentication.service.ts:37](https://gitlab.com/rxap/packages/-/blob/
|
|
59
|
+
Defined in: [authentication.service.ts:37](https://gitlab.com/rxap/packages/-/blob/9978b20018f781a5952245bfe2db15ab7612611c/packages/angular/oauth/src/lib/authentication.service.ts#L37)
|
|
60
60
|
|
|
61
61
|
#### Implementation of
|
|
62
62
|
|
|
@@ -68,7 +68,7 @@ Defined in: [authentication.service.ts:37](https://gitlab.com/rxap/packages/-/bl
|
|
|
68
68
|
|
|
69
69
|
> **init**(): `void`
|
|
70
70
|
|
|
71
|
-
Defined in: [authentication.service.ts:71](https://gitlab.com/rxap/packages/-/blob/
|
|
71
|
+
Defined in: [authentication.service.ts:71](https://gitlab.com/rxap/packages/-/blob/9978b20018f781a5952245bfe2db15ab7612611c/packages/angular/oauth/src/lib/authentication.service.ts#L71)
|
|
72
72
|
|
|
73
73
|
#### Returns
|
|
74
74
|
|
|
@@ -80,7 +80,7 @@ Defined in: [authentication.service.ts:71](https://gitlab.com/rxap/packages/-/bl
|
|
|
80
80
|
|
|
81
81
|
> **isAuthenticated**(): `Promise`\<`boolean`\>
|
|
82
82
|
|
|
83
|
-
Defined in: [authentication.service.ts:153](https://gitlab.com/rxap/packages/-/blob/
|
|
83
|
+
Defined in: [authentication.service.ts:153](https://gitlab.com/rxap/packages/-/blob/9978b20018f781a5952245bfe2db15ab7612611c/packages/angular/oauth/src/lib/authentication.service.ts#L153)
|
|
84
84
|
|
|
85
85
|
#### Returns
|
|
86
86
|
|
|
@@ -96,7 +96,7 @@ Defined in: [authentication.service.ts:153](https://gitlab.com/rxap/packages/-/b
|
|
|
96
96
|
|
|
97
97
|
> **signIn**(): `void`
|
|
98
98
|
|
|
99
|
-
Defined in: [authentication.service.ts:134](https://gitlab.com/rxap/packages/-/blob/
|
|
99
|
+
Defined in: [authentication.service.ts:134](https://gitlab.com/rxap/packages/-/blob/9978b20018f781a5952245bfe2db15ab7612611c/packages/angular/oauth/src/lib/authentication.service.ts#L134)
|
|
100
100
|
|
|
101
101
|
#### Returns
|
|
102
102
|
|
|
@@ -108,7 +108,7 @@ Defined in: [authentication.service.ts:134](https://gitlab.com/rxap/packages/-/b
|
|
|
108
108
|
|
|
109
109
|
> **signOut**(): `Promise`\<`void`\>
|
|
110
110
|
|
|
111
|
-
Defined in: [authentication.service.ts:123](https://gitlab.com/rxap/packages/-/blob/
|
|
111
|
+
Defined in: [authentication.service.ts:123](https://gitlab.com/rxap/packages/-/blob/9978b20018f781a5952245bfe2db15ab7612611c/packages/angular/oauth/src/lib/authentication.service.ts#L123)
|
|
112
112
|
|
|
113
113
|
#### Returns
|
|
114
114
|
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
> **AuthenticationGuard**(`route`, `state`): `Promise`\<`boolean`\>
|
|
6
6
|
|
|
7
|
-
Defined in: [authentication-guard.ts:12](https://gitlab.com/rxap/packages/-/blob/
|
|
7
|
+
Defined in: [authentication-guard.ts:12](https://gitlab.com/rxap/packages/-/blob/9978b20018f781a5952245bfe2db15ab7612611c/packages/angular/oauth/src/lib/authentication-guard.ts#L12)
|
|
8
8
|
|
|
9
9
|
## Parameters
|
|
10
10
|
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
> **ProvideAuth**(...`withConfigs`): `Provider`[]
|
|
6
6
|
|
|
7
|
-
Defined in: [provide-auth.ts:9](https://gitlab.com/rxap/packages/-/blob/
|
|
7
|
+
Defined in: [provide-auth.ts:9](https://gitlab.com/rxap/packages/-/blob/9978b20018f781a5952245bfe2db15ab7612611c/packages/angular/oauth/src/lib/provide-auth.ts#L9)
|
|
8
8
|
|
|
9
9
|
## Parameters
|
|
10
10
|
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
> **withAuthConfig**(`config`): `Provider`
|
|
6
6
|
|
|
7
|
-
Defined in: [provide-auth.ts:20](https://gitlab.com/rxap/packages/-/blob/
|
|
7
|
+
Defined in: [provide-auth.ts:20](https://gitlab.com/rxap/packages/-/blob/9978b20018f781a5952245bfe2db15ab7612611c/packages/angular/oauth/src/lib/provide-auth.ts#L20)
|
|
8
8
|
|
|
9
9
|
## Parameters
|
|
10
10
|
|
package/docs/wiki/Home.md
CHANGED
|
@@ -1,33 +1,35 @@
|
|
|
1
1
|
This package provides an authentication guard and service for Angular applications using OAuth 2.0 and OpenID Connect. It simplifies the integration of authentication flows, including sign-in, sign-out, and token management, with support for disabled authentication scenarios. The package also includes a provider function to streamline configuration.
|
|
2
2
|
|
|
3
3
|
[](https://www.npmjs.com/package/@rxap/oauth)
|
|
4
|
-
[](https://github.com/prettier/prettier)
|
|
8
|
-

|
|
4
|
+
[](https://commitizen.github.io/cz-cli/)
|
|
5
|
+
[](https://github.com/prettier/prettier)
|
|
6
|
+

|
|
10
7
|

|
|
11
|
-

|
|
12
|
-
|
|
8
|
+

|
|
9
|
+
|
|
10
|
+
- [Installation](../wiki/#installation)
|
|
13
11
|
- [Generators](../wiki/#generators)
|
|
14
|
-
|
|
12
|
+
- [init](../wiki/#init)
|
|
13
|
+
|
|
14
|
+
# Installation
|
|
15
15
|
|
|
16
|
-
|
|
17
|
-
|
|
16
|
+
**Add the package to your workspace:**
|
|
17
|
+
```bash
|
|
18
|
+
yarn add @rxap/oauth
|
|
19
|
+
```
|
|
20
|
+
**Install peer dependencies:**
|
|
21
|
+
```bash
|
|
22
|
+
yarn add @angular/core@^19.1.3 @angular/router@^19.1.3 @rxap/authentication@^19.0.1 @rxap/rxjs@^1.1.12 angular-oauth2-oidc@^15.0.1 angular-oauth2-oidc-jwks@^15.0.1 rxjs@^7.8.1
|
|
23
|
+
```
|
|
24
|
+
**Execute the init generator:**
|
|
25
|
+
```bash
|
|
26
|
+
yarn nx g @rxap/oauth:init
|
|
18
27
|
```
|
|
19
|
-
**Install peer dependencies:** ```bash yarn add
|
|
20
|
-
@angular/core@^19.1.3 @angular/router@^19.1.3 @rxap/authentication@^19.0.1-dev.5 @rxap/rxjs@^1.1.12-dev.5 angular-oauth2-oidc@^15.0.1 angular-oauth2-oidc-jwks@^15.0.1 rxjs@^7.8.1
|
|
21
|
-
```
|
|
22
|
-
**Execute the init generator:** ```bash yarn nx g
|
|
23
|
-
@rxap/oauth:init ```
|
|
24
28
|
# Generators
|
|
25
29
|
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
>
|
|
29
|
-
Initialize the package in the workspace
|
|
30
|
+
## init
|
|
31
|
+
> Initialize the package in the workspace
|
|
30
32
|
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
33
|
+
```bash
|
|
34
|
+
nx g @rxap/oauth:init
|
|
35
|
+
```
|
package/package.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
{
|
|
2
|
-
"version": "19.0.
|
|
2
|
+
"version": "19.0.2-dev.0",
|
|
3
3
|
"name": "@rxap/oauth",
|
|
4
4
|
"description": "This package provides an authentication guard and service for Angular applications using OAuth 2.0 and OpenID Connect. It simplifies the integration of authentication flows, including sign-in, sign-out, and token management, with support for disabled authentication scenarios. The package also includes a provider function to streamline configuration.\n",
|
|
5
5
|
"license": "GPL-3.0-or-later",
|
|
@@ -10,8 +10,8 @@
|
|
|
10
10
|
"peerDependencies": {
|
|
11
11
|
"@angular/core": "^19.1.3",
|
|
12
12
|
"@angular/router": "^19.1.3",
|
|
13
|
-
"@rxap/authentication": "^19.0.1
|
|
14
|
-
"@rxap/rxjs": "^1.1.12
|
|
13
|
+
"@rxap/authentication": "^19.0.1",
|
|
14
|
+
"@rxap/rxjs": "^1.1.12",
|
|
15
15
|
"angular-oauth2-oidc": "^15.0.1",
|
|
16
16
|
"angular-oauth2-oidc-jwks": "^15.0.1",
|
|
17
17
|
"rxjs": "^7.8.1"
|
|
@@ -55,15 +55,15 @@
|
|
|
55
55
|
},
|
|
56
56
|
{
|
|
57
57
|
"package": "@rxap/authentication",
|
|
58
|
-
"version": "19.0.1
|
|
58
|
+
"version": "19.0.1"
|
|
59
59
|
},
|
|
60
60
|
{
|
|
61
61
|
"package": "@rxap/rxjs",
|
|
62
|
-
"version": "1.1.12
|
|
62
|
+
"version": "1.1.12"
|
|
63
63
|
},
|
|
64
64
|
{
|
|
65
65
|
"package": "@rxap/utilities",
|
|
66
|
-
"version": "16.4.2
|
|
66
|
+
"version": "16.4.2"
|
|
67
67
|
}
|
|
68
68
|
]
|
|
69
69
|
},
|
|
@@ -78,7 +78,7 @@
|
|
|
78
78
|
},
|
|
79
79
|
"schematics": "./generators.json",
|
|
80
80
|
"sideEffects": false,
|
|
81
|
-
"gitHead": "
|
|
81
|
+
"gitHead": "9978b20018f781a5952245bfe2db15ab7612611c",
|
|
82
82
|
"module": "fesm2022/rxap-oauth.mjs",
|
|
83
83
|
"typings": "index.d.ts",
|
|
84
84
|
"exports": {
|