Skip to content

Commit e38c99c

Browse files
committed
feat: provide standalone api
1 parent 0feeaf0 commit e38c99c

38 files changed

+3961
-609
lines changed

angular.json

Lines changed: 92 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -179,6 +179,7 @@
179179
"builder": "@angular-devkit/build-angular:dev-server",
180180
"options": {
181181
"browserTarget": "quickstart-demo:build"
182+
182183
},
183184
"configurations": {
184185
"production": {
@@ -244,6 +245,97 @@
244245
}
245246
}
246247
}
248+
},
249+
"quickstart-standalone": {
250+
"projectType": "application",
251+
"schematics": {},
252+
"root": "projects/quickstart-standalone",
253+
"sourceRoot": "projects/quickstart-standalone/src",
254+
"prefix": "app",
255+
"architect": {
256+
"build": {
257+
"builder": "@angular-devkit/build-angular:browser",
258+
"options": {
259+
"outputPath": "dist/quickstart-standalone",
260+
"index": "projects/quickstart-standalone/src/index.html",
261+
"main": "projects/quickstart-standalone/src/main.ts",
262+
"polyfills": [
263+
"zone.js"
264+
],
265+
"tsConfig": "projects/quickstart-standalone/tsconfig.app.json",
266+
"assets": [
267+
"projects/quickstart-standalone/src/favicon.ico",
268+
"projects/quickstart-standalone/src/assets"
269+
],
270+
"styles": [
271+
"projects/quickstart-standalone/src/styles.css"
272+
],
273+
"scripts": []
274+
},
275+
"configurations": {
276+
"production": {
277+
"budgets": [
278+
{
279+
"type": "initial",
280+
"maximumWarning": "500kb",
281+
"maximumError": "1mb"
282+
},
283+
{
284+
"type": "anyComponentStyle",
285+
"maximumWarning": "2kb",
286+
"maximumError": "4kb"
287+
}
288+
],
289+
"outputHashing": "all"
290+
},
291+
"development": {
292+
"buildOptimizer": false,
293+
"optimization": false,
294+
"vendorChunk": true,
295+
"extractLicenses": false,
296+
"sourceMap": true,
297+
"namedChunks": true
298+
}
299+
},
300+
"defaultConfiguration": "production"
301+
},
302+
"serve": {
303+
"builder": "@angular-devkit/build-angular:dev-server",
304+
"configurations": {
305+
"production": {
306+
"browserTarget": "quickstart-standalone:build:production"
307+
},
308+
"development": {
309+
"browserTarget": "quickstart-standalone:build:development"
310+
}
311+
},
312+
"defaultConfiguration": "development"
313+
},
314+
"extract-i18n": {
315+
"builder": "@angular-devkit/build-angular:extract-i18n",
316+
"options": {
317+
"browserTarget": "quickstart-standalone:build"
318+
}
319+
},
320+
"test": {
321+
"builder": "@angular-devkit/build-angular:karma",
322+
"options": {
323+
"polyfills": [
324+
"zone.js",
325+
"zone.js/testing"
326+
],
327+
"tsConfig": "projects/quickstart-standalone/tsconfig.spec.json",
328+
"assets": [
329+
"projects/quickstart-standalone/src/favicon.ico",
330+
"projects/quickstart-standalone/src/assets"
331+
],
332+
"styles": [
333+
"projects/quickstart-standalone/src/styles.css"
334+
],
335+
"scripts": []
336+
}
337+
}
338+
}
247339
}
248340
},
249341
"schematics": {

docs/classes/AuthConfig.html

Lines changed: 92 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,11 @@ <h6><b>Properties</b></h6>
8181
<tr>
8282
<td class="col-md-4">
8383
<ul class="index-list">
84+
<li>
85+
<span class="modifier">Public</span>
86+
<span class="modifier">Optional</span>
87+
<a href="#checkOrigin" >checkOrigin</a>
88+
</li>
8489
<li>
8590
<span class="modifier">Public</span>
8691
<span class="modifier">Optional</span>
@@ -111,6 +116,11 @@ <h6><b>Properties</b></h6>
111116
<span class="modifier">Optional</span>
112117
<a href="#disableAtHashCheck" >disableAtHashCheck</a>
113118
</li>
119+
<li>
120+
<span class="modifier">Public</span>
121+
<span class="modifier">Optional</span>
122+
<a href="#disableIdTokenTimer" >disableIdTokenTimer</a>
123+
</li>
114124
<li>
115125
<span class="modifier">Public</span>
116126
<span class="modifier">Optional</span>
@@ -345,7 +355,7 @@ <h3 id="constructor">Constructor</h3>
345355
</tr>
346356
<tr>
347357
<td class="col-md-4">
348-
<div class="io-line">Defined in <a href="" data-line="264" class="link-to-prism">projects/lib/src/auth.config.ts:264</a></div>
358+
<div class="io-line">Defined in <a href="" data-line="275" class="link-to-prism">projects/lib/src/auth.config.ts:275</a></div>
349359
</td>
350360
</tr>
351361

@@ -388,6 +398,39 @@ <h3 id="constructor">Constructor</h3>
388398
<h3 id="inputs">
389399
Properties
390400
</h3>
401+
<table class="table table-sm table-bordered">
402+
<tbody>
403+
<tr>
404+
<td class="col-md-4">
405+
<a name="checkOrigin"></a>
406+
<span class="name">
407+
<span class="modifier">Public</span>
408+
<span class="modifier">Optional</span>
409+
<span ><b>checkOrigin</b></span>
410+
<a href="#checkOrigin"><span class="icon ion-ios-link"></span></a>
411+
</span>
412+
</td>
413+
</tr>
414+
<tr>
415+
<td class="col-md-4">
416+
<i>Default value : </i><code>false</code>
417+
</td>
418+
</tr>
419+
<tr>
420+
<td class="col-md-4">
421+
<div class="io-line">Defined in <a href="" data-line="275" class="link-to-prism">projects/lib/src/auth.config.ts:275</a></div>
422+
</td>
423+
</tr>
424+
425+
<tr>
426+
<td class="col-md-4">
427+
<div class="io-description"><p>Blocks other origins requesting a silent refresh</p>
428+
</div>
429+
</td>
430+
</tr>
431+
432+
</tbody>
433+
</table>
391434
<table class="table table-sm table-bordered">
392435
<tbody>
393436
<tr>
@@ -604,6 +647,40 @@ <h3 id="inputs">
604647
an at_hash EVEN THOUGH its recommended by the OIDC specs.
605648
Of course, when disabling these checks then we are bypassing
606649
a security check which means we are more vulnerable.</p>
650+
</div>
651+
</td>
652+
</tr>
653+
654+
</tbody>
655+
</table>
656+
<table class="table table-sm table-bordered">
657+
<tbody>
658+
<tr>
659+
<td class="col-md-4">
660+
<a name="disableIdTokenTimer"></a>
661+
<span class="name">
662+
<span class="modifier">Public</span>
663+
<span class="modifier">Optional</span>
664+
<span ><b>disableIdTokenTimer</b></span>
665+
<a href="#disableIdTokenTimer"><span class="icon ion-ios-link"></span></a>
666+
</span>
667+
</td>
668+
</tr>
669+
<tr>
670+
<td class="col-md-4">
671+
<i>Default value : </i><code>false</code>
672+
</td>
673+
</tr>
674+
<tr>
675+
<td class="col-md-4">
676+
<div class="io-line">Defined in <a href="" data-line="270" class="link-to-prism">projects/lib/src/auth.config.ts:270</a></div>
677+
</td>
678+
</tr>
679+
680+
<tr>
681+
<td class="col-md-4">
682+
<div class="io-description"><p>Allows to disable the timer for the id_token used
683+
for token refresh</p>
607684
</div>
608685
</td>
609686
</tr>
@@ -666,7 +743,7 @@ <h3 id="inputs">
666743
</tr>
667744
<tr>
668745
<td class="col-md-4">
669-
<i>Default value : </i><code>null</code>
746+
<i>Default value : </i><code>&#x27;&#x27;</code>
670747
</td>
671748
</tr>
672749
<tr>
@@ -986,7 +1063,7 @@ <h3 id="inputs">
9861063
</tr>
9871064
<tr>
9881065
<td class="col-md-4">
989-
<div class="io-line">Defined in <a href="" data-line="277" class="link-to-prism">projects/lib/src/auth.config.ts:277</a></div>
1066+
<div class="io-line">Defined in <a href="" data-line="288" class="link-to-prism">projects/lib/src/auth.config.ts:288</a></div>
9901067
</td>
9911068
</tr>
9921069

@@ -2288,7 +2365,7 @@ <h3 id="inputs">
22882365
* it does not bring additional security and is therefore
22892366
* as good as using no password.
22902367
*/
2291-
public dummyClientSecret?: string &#x3D; null;
2368+
public dummyClientSecret?: string &#x3D; &#x27;&#x27;;
22922369

22932370
/**
22942371
* Defines whether https is required.
@@ -2423,6 +2500,17 @@ <h3 id="inputs">
24232500
*/
24242501
public preserveRequestedRoute? &#x3D; false;
24252502

2503+
/**
2504+
* Allows to disable the timer for the id_token used
2505+
* for token refresh
2506+
*/
2507+
public disableIdTokenTimer? &#x3D; false;
2508+
2509+
/**
2510+
* Blocks other origins requesting a silent refresh
2511+
*/
2512+
public checkOrigin? &#x3D; false;
2513+
24262514
constructor(json?: Partial&lt;AuthConfig&gt;) {
24272515
if (json) {
24282516
Object.assign(this, json);

0 commit comments

Comments
 (0)