mirror of
https://github.com/paperless-ngx/paperless-ngx.git
synced 2026-07-28 23:04:56 +00:00
Chorehancement: update to Angular v22, 'zoneless' / 'reactive' (#13114)
This commit is contained in:
@@ -25,11 +25,11 @@ describe('LoadingComponentWithPermissions', () => {
|
||||
})
|
||||
|
||||
it('should have loading set to true by default', () => {
|
||||
expect(component.loading).toBeTruthy()
|
||||
expect(component.loading()).toBeTruthy()
|
||||
})
|
||||
|
||||
it('should have show set to false by default', () => {
|
||||
expect(component.show).toBeFalsy()
|
||||
expect(component.show()).toBeFalsy()
|
||||
})
|
||||
|
||||
it('should call next and complete on unsubscribeNotifier with itself on destroy', () => {
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { Directive, OnDestroy } from '@angular/core'
|
||||
import { Directive, OnDestroy, signal } from '@angular/core'
|
||||
import { Subject } from 'rxjs'
|
||||
import { ComponentWithPermissions } from '../with-permissions/with-permissions.component'
|
||||
|
||||
@@ -7,8 +7,8 @@ export abstract class LoadingComponentWithPermissions
|
||||
extends ComponentWithPermissions
|
||||
implements OnDestroy
|
||||
{
|
||||
public loading: boolean = true
|
||||
public show: boolean = false
|
||||
readonly loading = signal(true)
|
||||
readonly show = signal(false)
|
||||
|
||||
protected unsubscribeNotifier: Subject<any> = new Subject()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user