mirror of
https://github.com/Alfresco/alfresco-content-app.git
synced 2025-07-31 17:38:28 +00:00
[AAE-7145] upgrade to Ngrx 10 (#2479)
* upgrade to ngrx 10 * fix auth proxy * migrate effects to newer syntax
This commit is contained in:
@@ -23,7 +23,7 @@
|
||||
* along with Alfresco. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
import { Effect, Actions, ofType } from '@ngrx/effects';
|
||||
import { Actions, ofType, createEffect } from '@ngrx/effects';
|
||||
import { Injectable } from '@angular/core';
|
||||
import { map } from 'rxjs/operators';
|
||||
import { MatDialog } from '@angular/material/dialog';
|
||||
@@ -33,9 +33,12 @@ import { CloseModalDialogsAction, AppActionTypes } from '../actions/app.actions'
|
||||
export class DialogEffects {
|
||||
constructor(private actions$: Actions, private matDialog: MatDialog) {}
|
||||
|
||||
@Effect({ dispatch: false })
|
||||
closeAll$ = this.actions$.pipe(
|
||||
ofType<CloseModalDialogsAction>(AppActionTypes.CloseModalDialogs),
|
||||
map(() => this.matDialog.closeAll())
|
||||
closeAll$ = createEffect(
|
||||
() =>
|
||||
this.actions$.pipe(
|
||||
ofType<CloseModalDialogsAction>(AppActionTypes.CloseModalDialogs),
|
||||
map(() => this.matDialog.closeAll())
|
||||
),
|
||||
{ dispatch: false }
|
||||
);
|
||||
}
|
||||
|
Reference in New Issue
Block a user