@rxap/ngx-error 19.3.0 → 21.0.1-dev.1
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 +40 -0
- package/compodoc/changelog.html +38 -0
- package/compodoc/components/AngularErrorComponent.html +56 -41
- package/compodoc/components/AnyHttpErrorComponent.html +75 -57
- package/compodoc/components/CodeHttpErrorComponent.html +19 -19
- package/compodoc/components/ErrorDialogComponent.html +98 -79
- package/compodoc/components/MessageHttpErrorComponent.html +19 -19
- package/compodoc/components/OpenApiHttpResponseErrorComponent.html +50 -34
- package/compodoc/dependencies.html +11 -11
- package/compodoc/injectables/ErrorCaptureDialogService.html +9 -7
- package/compodoc/interfaces/IErrorCaptureDialogService.html +6 -4
- package/compodoc/interfaces/IErrorDialogComponent.html +14 -23
- package/compodoc/js/search/search_index.js +2 -2
- package/compodoc/properties.html +1 -1
- package/docs/documentation.json +1007 -1043
- package/docs/html/assets/hierarchy.js +1 -1
- package/docs/html/assets/search.js +1 -1
- package/docs/html/classes/AngularErrorComponent.html +2 -2
- package/docs/html/classes/AngularErrorService.html +2 -2
- package/docs/html/classes/AnyHttpErrorComponent.html +2 -2
- package/docs/html/classes/AnyHttpErrorService.html +2 -2
- package/docs/html/classes/CodeHttpErrorComponent.html +2 -2
- package/docs/html/classes/CodeHttpErrorService.html +2 -2
- package/docs/html/classes/ErrorCaptureDialogService.html +2 -2
- package/docs/html/classes/ErrorCaptureService.html +2 -2
- package/docs/html/classes/ErrorDialogComponent.html +2 -6
- package/docs/html/classes/MessageHttpErrorComponent.html +2 -2
- package/docs/html/classes/MessageHttpErrorService.html +2 -2
- package/docs/html/classes/OpenApiHttpResponseErrorComponent.html +2 -2
- package/docs/html/classes/OpenApiHttpResponseErrorService.html +2 -2
- package/docs/html/classes/RxapErrorHandler.html +3 -3
- package/docs/html/functions/DefaultErrorCodeExtractor.html +1 -1
- package/docs/html/functions/DefaultErrorFilter.html +1 -1
- package/docs/html/functions/ExtractContextFromError.html +1 -1
- package/docs/html/functions/ExtractError.html +1 -1
- package/docs/html/functions/ExtractExtraFromError.html +1 -1
- package/docs/html/functions/ExtractTagsFromError.html +1 -1
- package/docs/html/functions/HttpErrorInterceptor.html +1 -1
- package/docs/html/functions/PrintError.html +1 -1
- package/docs/html/functions/ProvideErrorHandler.html +2 -2
- package/docs/html/functions/SimplifyHttpErrorResponse.html +1 -1
- package/docs/html/functions/provideAutoErrorInterception.html +1 -1
- package/docs/html/functions/withErrorCaptureDialogDisabledIf.html +1 -1
- package/docs/html/functions/withErrorCaptureDialogService.html +1 -1
- package/docs/html/hierarchy.html +1 -1
- package/docs/html/index.html +2 -2
- package/docs/html/interfaces/AngularErrorDialogData.html +2 -2
- package/docs/html/interfaces/AnyHttpErrorDialogData.html +8 -8
- package/docs/html/interfaces/CodeHttpErrorDialogData.html +8 -8
- package/docs/html/interfaces/ErrorHandlerOptions.html +2 -2
- package/docs/html/interfaces/ErrorInterceptorOptions.html +2 -2
- package/docs/html/interfaces/IErrorCaptureDialogService.html +2 -2
- package/docs/html/interfaces/IErrorDialogComponent.html +2 -2
- package/docs/html/interfaces/MessageHttpErrorDialogData.html +8 -8
- package/docs/html/interfaces/OpenApiHttpResponseErrorDialogData.html +8 -8
- package/docs/html/interfaces/SimplifiedHttpErrorResponse.html +2 -2
- package/docs/html/modules.html +1 -1
- package/docs/html/variables/RXAP_ERROR_CAPTURE_DIALOG_SERVICE.html +1 -1
- package/docs/html/variables/RXAP_ERROR_DIALOG_COMPONENT.html +1 -1
- package/docs/html/variables/RXAP_ERROR_DIALOG_DATA.html +1 -1
- package/docs/html/variables/RXAP_ERROR_DIALOG_DISABLED.html +1 -1
- package/docs/html/variables/RXAP_ERROR_DIALOG_ERROR.html +1 -1
- package/docs/html/variables/RXAP_ERROR_HANDLER_OPTIONS.html +1 -1
- package/docs/html/variables/RXAP_ERROR_INTERCEPTOR_OPTIONS.html +1 -1
- package/docs/markdown/README.md +1 -1
- package/docs/markdown/classes/AngularErrorComponent.md +6 -6
- package/docs/markdown/classes/AngularErrorService.md +5 -5
- package/docs/markdown/classes/AnyHttpErrorComponent.md +4 -4
- package/docs/markdown/classes/AnyHttpErrorService.md +5 -5
- package/docs/markdown/classes/CodeHttpErrorComponent.md +5 -5
- package/docs/markdown/classes/CodeHttpErrorService.md +5 -5
- package/docs/markdown/classes/ErrorCaptureDialogService.md +6 -6
- package/docs/markdown/classes/ErrorCaptureService.md +5 -5
- package/docs/markdown/classes/ErrorDialogComponent.md +13 -35
- package/docs/markdown/classes/MessageHttpErrorComponent.md +5 -5
- package/docs/markdown/classes/MessageHttpErrorService.md +5 -5
- package/docs/markdown/classes/OpenApiHttpResponseErrorComponent.md +4 -4
- package/docs/markdown/classes/OpenApiHttpResponseErrorService.md +5 -5
- package/docs/markdown/classes/RxapErrorHandler.md +7 -7
- package/docs/markdown/functions/DefaultErrorCodeExtractor.md +2 -2
- package/docs/markdown/functions/DefaultErrorFilter.md +2 -2
- package/docs/markdown/functions/ExtractContextFromError.md +2 -2
- package/docs/markdown/functions/ExtractError.md +2 -2
- package/docs/markdown/functions/ExtractExtraFromError.md +2 -2
- package/docs/markdown/functions/ExtractTagsFromError.md +2 -2
- package/docs/markdown/functions/HttpErrorInterceptor.md +2 -2
- package/docs/markdown/functions/PrintError.md +2 -2
- package/docs/markdown/functions/ProvideErrorHandler.md +2 -2
- package/docs/markdown/functions/SimplifyHttpErrorResponse.md +2 -2
- package/docs/markdown/functions/provideAutoErrorInterception.md +2 -2
- package/docs/markdown/functions/withErrorCaptureDialogDisabledIf.md +2 -2
- package/docs/markdown/functions/withErrorCaptureDialogService.md +2 -2
- package/docs/markdown/globals.md +2 -2
- package/docs/markdown/interfaces/AngularErrorDialogData.md +8 -8
- package/docs/markdown/interfaces/AnyHttpErrorDialogData.md +15 -15
- package/docs/markdown/interfaces/CodeHttpErrorDialogData.md +16 -16
- package/docs/markdown/interfaces/ErrorHandlerOptions.md +5 -5
- package/docs/markdown/interfaces/ErrorInterceptorOptions.md +4 -4
- package/docs/markdown/interfaces/IErrorCaptureDialogService.md +3 -3
- package/docs/markdown/interfaces/IErrorDialogComponent.md +3 -3
- package/docs/markdown/interfaces/MessageHttpErrorDialogData.md +15 -15
- package/docs/markdown/interfaces/OpenApiHttpResponseErrorDialogData.md +18 -18
- package/docs/markdown/interfaces/SimplifiedHttpErrorResponse.md +12 -12
- package/docs/markdown/variables/RXAP_ERROR_CAPTURE_DIALOG_SERVICE.md +2 -2
- package/docs/markdown/variables/RXAP_ERROR_DIALOG_COMPONENT.md +2 -2
- package/docs/markdown/variables/RXAP_ERROR_DIALOG_DATA.md +2 -2
- package/docs/markdown/variables/RXAP_ERROR_DIALOG_DISABLED.md +2 -2
- package/docs/markdown/variables/RXAP_ERROR_DIALOG_ERROR.md +2 -2
- package/docs/markdown/variables/RXAP_ERROR_HANDLER_OPTIONS.md +2 -2
- package/docs/markdown/variables/RXAP_ERROR_INTERCEPTOR_OPTIONS.md +2 -2
- package/docs/wiki/Class.AngularErrorComponent.md +5 -5
- package/docs/wiki/Class.AngularErrorService.md +4 -4
- package/docs/wiki/Class.AnyHttpErrorComponent.md +3 -3
- package/docs/wiki/Class.AnyHttpErrorService.md +4 -4
- package/docs/wiki/Class.CodeHttpErrorComponent.md +4 -4
- package/docs/wiki/Class.CodeHttpErrorService.md +4 -4
- package/docs/wiki/Class.ErrorCaptureDialogService.md +5 -5
- package/docs/wiki/Class.ErrorCaptureService.md +4 -4
- package/docs/wiki/Class.ErrorDialogComponent.md +12 -34
- package/docs/wiki/Class.MessageHttpErrorComponent.md +4 -4
- package/docs/wiki/Class.MessageHttpErrorService.md +4 -4
- package/docs/wiki/Class.OpenApiHttpResponseErrorComponent.md +3 -3
- package/docs/wiki/Class.OpenApiHttpResponseErrorService.md +4 -4
- package/docs/wiki/Class.RxapErrorHandler.md +6 -6
- package/docs/wiki/Function.DefaultErrorCodeExtractor.md +1 -1
- package/docs/wiki/Function.DefaultErrorFilter.md +1 -1
- package/docs/wiki/Function.ExtractContextFromError.md +1 -1
- package/docs/wiki/Function.ExtractError.md +1 -1
- package/docs/wiki/Function.ExtractExtraFromError.md +1 -1
- package/docs/wiki/Function.ExtractTagsFromError.md +1 -1
- package/docs/wiki/Function.HttpErrorInterceptor.md +1 -1
- package/docs/wiki/Function.PrintError.md +1 -1
- package/docs/wiki/Function.ProvideErrorHandler.md +1 -1
- package/docs/wiki/Function.SimplifyHttpErrorResponse.md +1 -1
- package/docs/wiki/Function.provideAutoErrorInterception.md +1 -1
- package/docs/wiki/Function.withErrorCaptureDialogDisabledIf.md +1 -1
- package/docs/wiki/Function.withErrorCaptureDialogService.md +1 -1
- package/docs/wiki/Interface.AngularErrorDialogData.md +7 -7
- package/docs/wiki/Interface.AnyHttpErrorDialogData.md +14 -14
- package/docs/wiki/Interface.CodeHttpErrorDialogData.md +15 -15
- package/docs/wiki/Interface.ErrorHandlerOptions.md +4 -4
- package/docs/wiki/Interface.ErrorInterceptorOptions.md +3 -3
- package/docs/wiki/Interface.IErrorCaptureDialogService.md +2 -2
- package/docs/wiki/Interface.IErrorDialogComponent.md +2 -2
- package/docs/wiki/Interface.MessageHttpErrorDialogData.md +14 -14
- package/docs/wiki/Interface.OpenApiHttpResponseErrorDialogData.md +17 -17
- package/docs/wiki/Interface.SimplifiedHttpErrorResponse.md +11 -11
- package/docs/wiki/Variable.RXAP_ERROR_CAPTURE_DIALOG_SERVICE.md +1 -1
- package/docs/wiki/Variable.RXAP_ERROR_DIALOG_COMPONENT.md +1 -1
- package/docs/wiki/Variable.RXAP_ERROR_DIALOG_DATA.md +1 -1
- package/docs/wiki/Variable.RXAP_ERROR_DIALOG_DISABLED.md +1 -1
- package/docs/wiki/Variable.RXAP_ERROR_DIALOG_ERROR.md +1 -1
- package/docs/wiki/Variable.RXAP_ERROR_HANDLER_OPTIONS.md +1 -1
- package/docs/wiki/Variable.RXAP_ERROR_INTERCEPTOR_OPTIONS.md +1 -1
- package/docs/wiki/globals.md +1 -1
- package/fesm2022/rxap-ngx-error.mjs +75 -109
- package/fesm2022/rxap-ngx-error.mjs.map +1 -1
- package/package.json +42 -41
- package/types/rxap-ngx-error.d.ts +256 -0
- package/index.d.ts +0 -24
- package/lib/any-http-error/any-http-error-dialog-data.d.ts +0 -36
- package/lib/any-http-error/any-http-error.component.d.ts +0 -9
- package/lib/any-http-error/any-http-error.service.d.ts +0 -11
- package/lib/code-http-error/code-http-error-dialog-data.d.ts +0 -7
- package/lib/code-http-error/code-http-error.component.d.ts +0 -10
- package/lib/code-http-error/code-http-error.service.d.ts +0 -10
- package/lib/error/angular-error-dialog-data.d.ts +0 -8
- package/lib/error/angular-error.component.d.ts +0 -11
- package/lib/error/angular-error.service.d.ts +0 -10
- package/lib/error-capture-dialog.service.d.ts +0 -16
- package/lib/error-capture.service.d.ts +0 -12
- package/lib/error-dialog/error-dialog.component.d.ts +0 -20
- package/lib/error-handler.d.ts +0 -27
- package/lib/error-interceptor-options.d.ts +0 -7
- package/lib/http-error-interceptor.d.ts +0 -3
- package/lib/message-http-error/message-http-error-dialog-data.d.ts +0 -6
- package/lib/message-http-error/message-http-error.component.d.ts +0 -10
- package/lib/message-http-error/message-http-error.service.d.ts +0 -10
- package/lib/open-api-http-response-error/open-api-http-response-error-dialog-data.d.ts +0 -7
- package/lib/open-api-http-response-error/open-api-http-response-error.component.d.ts +0 -9
- package/lib/open-api-http-response-error/open-api-http-response-error.service.d.ts +0 -10
- package/lib/provide.d.ts +0 -10
- package/lib/tokens.d.ts +0 -11
- package/lib/utilities.d.ts +0 -19
|
@@ -202,8 +202,8 @@
|
|
|
202
202
|
|
|
203
203
|
<tr>
|
|
204
204
|
<td class="col-md-4">
|
|
205
|
-
<div class="io-line">Defined in <a href="" data-line="
|
|
206
|
-
class="link-to-prism">src/lib/error-capture-dialog.service.ts:
|
|
205
|
+
<div class="io-line">Defined in <a href="" data-line="41"
|
|
206
|
+
class="link-to-prism">src/lib/error-capture-dialog.service.ts:41</a></div>
|
|
207
207
|
</td>
|
|
208
208
|
</tr>
|
|
209
209
|
|
|
@@ -287,7 +287,7 @@
|
|
|
287
287
|
</tr>
|
|
288
288
|
<tr>
|
|
289
289
|
<td class="col-md-4">
|
|
290
|
-
<div class="io-line">Defined in <a href="" data-line="
|
|
290
|
+
<div class="io-line">Defined in <a href="" data-line="37" class="link-to-prism">src/lib/error-capture-dialog.service.ts:37</a></div>
|
|
291
291
|
</td>
|
|
292
292
|
</tr>
|
|
293
293
|
|
|
@@ -314,7 +314,7 @@
|
|
|
314
314
|
</tr>
|
|
315
315
|
<tr>
|
|
316
316
|
<td class="col-md-4">
|
|
317
|
-
<div class="io-line">Defined in <a href="" data-line="
|
|
317
|
+
<div class="io-line">Defined in <a href="" data-line="39" class="link-to-prism">src/lib/error-capture-dialog.service.ts:39</a></div>
|
|
318
318
|
</td>
|
|
319
319
|
</tr>
|
|
320
320
|
|
|
@@ -341,7 +341,7 @@
|
|
|
341
341
|
</tr>
|
|
342
342
|
<tr>
|
|
343
343
|
<td class="col-md-4">
|
|
344
|
-
<div class="io-line">Defined in <a href="" data-line="
|
|
344
|
+
<div class="io-line">Defined in <a href="" data-line="38" class="link-to-prism">src/lib/error-capture-dialog.service.ts:38</a></div>
|
|
345
345
|
</td>
|
|
346
346
|
</tr>
|
|
347
347
|
|
|
@@ -355,7 +355,8 @@
|
|
|
355
355
|
|
|
356
356
|
<div class="tab-pane fade tab-source-code" id="source">
|
|
357
357
|
<pre class="line-numbers compodoc-sourcecode"><code class="language-typescript">import { ComponentType } from '@angular/cdk/overlay';
|
|
358
|
-
import {
|
|
358
|
+
import { outputToObservable } from '@angular/core/rxjs-interop';
|
|
359
|
+
|
|
359
360
|
import {
|
|
360
361
|
ApplicationRef,
|
|
361
362
|
createComponent,
|
|
@@ -363,6 +364,7 @@ import {
|
|
|
363
364
|
Injectable,
|
|
364
365
|
Injector,
|
|
365
366
|
WritableSignal,
|
|
367
|
+
DOCUMENT
|
|
366
368
|
} from '@angular/core';
|
|
367
369
|
import {
|
|
368
370
|
EMPTY,
|
|
@@ -418,7 +420,7 @@ export class ErrorCaptureDialogService<Error = any> implements IError
|
|
|
418
420
|
});
|
|
419
421
|
this.applicationRef.attachView(componentRef.hostView);
|
|
420
422
|
return new Observable<void>(subscriber => {
|
|
421
|
-
const subscription = componentRef.instance.closeDialog.pipe(
|
|
423
|
+
const subscription = outputToObservable(componentRef.instance.closeDialog).pipe(
|
|
422
424
|
take(1),
|
|
423
425
|
tap(() => {
|
|
424
426
|
subscriber.next();
|
|
@@ -178,8 +178,8 @@
|
|
|
178
178
|
|
|
179
179
|
<tr>
|
|
180
180
|
<td class="col-md-4">
|
|
181
|
-
<div class="io-line">Defined in <a href="" data-line="
|
|
182
|
-
class="link-to-prism">src/lib/error-capture-dialog.service.ts:
|
|
181
|
+
<div class="io-line">Defined in <a href="" data-line="31"
|
|
182
|
+
class="link-to-prism">src/lib/error-capture-dialog.service.ts:31</a></div>
|
|
183
183
|
</td>
|
|
184
184
|
</tr>
|
|
185
185
|
|
|
@@ -244,7 +244,8 @@
|
|
|
244
244
|
|
|
245
245
|
<div class="tab-pane fade tab-source-code" id="source">
|
|
246
246
|
<pre class="line-numbers compodoc-sourcecode"><code class="language-typescript">import { ComponentType } from '@angular/cdk/overlay';
|
|
247
|
-
import {
|
|
247
|
+
import { outputToObservable } from '@angular/core/rxjs-interop';
|
|
248
|
+
|
|
248
249
|
import {
|
|
249
250
|
ApplicationRef,
|
|
250
251
|
createComponent,
|
|
@@ -252,6 +253,7 @@ import {
|
|
|
252
253
|
Injectable,
|
|
253
254
|
Injector,
|
|
254
255
|
WritableSignal,
|
|
256
|
+
DOCUMENT
|
|
255
257
|
} from '@angular/core';
|
|
256
258
|
import {
|
|
257
259
|
EMPTY,
|
|
@@ -307,7 +309,7 @@ export class ErrorCaptureDialogService<Error = any> implements IError
|
|
|
307
309
|
});
|
|
308
310
|
this.applicationRef.attachView(componentRef.hostView);
|
|
309
311
|
return new Observable<void>(subscriber => {
|
|
310
|
-
const subscription = componentRef.instance.closeDialog.pipe(
|
|
312
|
+
const subscription = outputToObservable(componentRef.instance.closeDialog).pipe(
|
|
311
313
|
take(1),
|
|
312
314
|
tap(() => {
|
|
313
315
|
subscriber.next();
|
|
@@ -199,25 +199,20 @@
|
|
|
199
199
|
ComponentPortal,
|
|
200
200
|
PortalModule,
|
|
201
201
|
} from '@angular/cdk/portal';
|
|
202
|
+
import { NgClass } from '@angular/common';
|
|
202
203
|
import {
|
|
203
|
-
|
|
204
|
-
NgForOf,
|
|
205
|
-
NgIf,
|
|
206
|
-
} from '@angular/common';
|
|
207
|
-
import {
|
|
208
|
-
AfterViewInit,
|
|
204
|
+
afterNextRender,
|
|
209
205
|
ChangeDetectionStrategy,
|
|
210
206
|
Component,
|
|
211
207
|
computed,
|
|
212
208
|
ElementRef,
|
|
213
|
-
EventEmitter,
|
|
214
209
|
inject,
|
|
215
210
|
INJECTOR,
|
|
216
211
|
Injector,
|
|
217
|
-
|
|
212
|
+
output,
|
|
218
213
|
signal,
|
|
219
214
|
Signal,
|
|
220
|
-
|
|
215
|
+
viewChild
|
|
221
216
|
} from '@angular/core';
|
|
222
217
|
import {
|
|
223
218
|
RXAP_ERROR_DIALOG_COMPONENT,
|
|
@@ -233,18 +228,15 @@ export interface IErrorDialogComponent<Error = any> {
|
|
|
233
228
|
selector: 'rxap-error-dialog',
|
|
234
229
|
templateUrl: './error-dialog.component.html',
|
|
235
230
|
styleUrls: ['./error-dialog.component.scss'],
|
|
236
|
-
changeDetection: ChangeDetectionStrategy.
|
|
231
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
237
232
|
imports: [
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
PortalModule,
|
|
242
|
-
]
|
|
233
|
+
NgClass,
|
|
234
|
+
PortalModule
|
|
235
|
+
]
|
|
243
236
|
})
|
|
244
|
-
export class ErrorDialogComponent
|
|
237
|
+
export class ErrorDialogComponent {
|
|
245
238
|
|
|
246
|
-
|
|
247
|
-
public dialog!: ElementRef<HTMLDialogElement>;
|
|
239
|
+
public readonly dialog = viewChild.required<ElementRef<HTMLDialogElement>>('dialog');
|
|
248
240
|
|
|
249
241
|
public readonly data: Signal<any[]> = inject(RXAP_ERROR_DIALOG_DATA);
|
|
250
242
|
|
|
@@ -254,8 +246,7 @@ export class ErrorDialogComponent implements AfterViewInit {
|
|
|
254
246
|
const end = Math.min(this.data().length, start + 5);
|
|
255
247
|
return Array.from({ length: end - start }, (_, i) => start + i);
|
|
256
248
|
});
|
|
257
|
-
|
|
258
|
-
public closeDialog = new EventEmitter<void>();
|
|
249
|
+
public readonly closeDialog = output<void>();
|
|
259
250
|
private readonly component = inject(RXAP_ERROR_DIALOG_COMPONENT);
|
|
260
251
|
private readonly injector = inject(INJECTOR);
|
|
261
252
|
public readonly componentPortal = computed(() => {
|
|
@@ -273,12 +264,12 @@ export class ErrorDialogComponent implements AfterViewInit {
|
|
|
273
264
|
return new ComponentPortal(this.component, null, injector);
|
|
274
265
|
});
|
|
275
266
|
|
|
276
|
-
|
|
277
|
-
this.dialog.nativeElement.showModal();
|
|
267
|
+
constructor() {
|
|
268
|
+
afterNextRender(() => this.dialog().nativeElement.showModal());
|
|
278
269
|
}
|
|
279
270
|
|
|
280
271
|
close() {
|
|
281
|
-
this.dialog.nativeElement.close();
|
|
272
|
+
this.dialog().nativeElement.close();
|
|
282
273
|
this.closeDialog.emit();
|
|
283
274
|
}
|
|
284
275
|
|