@@ -8,8 +8,8 @@ import { CookieService } from 'ngx-cookie-service';
8
8
import { SystemRole } from 'realtime-server/lib/esm/common/models/system-role' ;
9
9
import { AuthType , getAuthType , User } from 'realtime-server/lib/esm/common/models/user' ;
10
10
import { SFProjectRole } from 'realtime-server/lib/esm/scriptureforge/models/sf-project-role' ;
11
- import { Observable , pipe , Subscription } from 'rxjs' ;
12
- import { debounceTime , distinctUntilChanged , filter , map } from 'rxjs/operators' ;
11
+ import { Observable , Subscription } from 'rxjs' ;
12
+ import { distinctUntilChanged , filter , map } from 'rxjs/operators' ;
13
13
import { ActivatedProjectService } from 'xforge-common/activated-project.service' ;
14
14
import { AuthService } from 'xforge-common/auth.service' ;
15
15
import { DataLoadingComponent } from 'xforge-common/data-loading-component' ;
@@ -36,7 +36,7 @@ import { quietTakeUntilDestroyed } from 'xforge-common/util/rxjs-util';
36
36
import { issuesEmailTemplate , supportedBrowser } from 'xforge-common/utils' ;
37
37
import { ThemeService } from 'xforge-common/theme.service' ;
38
38
import { takeUntilDestroyed } from '@angular/core/rxjs-interop' ;
39
- import { AnalyticsService , PageViewEvent , TagEventType } from 'xforge-common/analytics.service' ;
39
+ import { AnalyticsService , PageViewEvent } from 'xforge-common/analytics.service' ;
40
40
import versionData from '../../../version.json' ;
41
41
import { environment } from '../environments/environment' ;
42
42
import { SFProjectProfileDoc } from './core/models/sf-project-profile-doc' ;
@@ -45,8 +45,6 @@ import { SFProjectUserConfigDoc } from './core/models/sf-project-user-config-doc
45
45
import { SFProjectService } from './core/sf-project.service' ;
46
46
import { checkAppAccess } from './shared/utils' ;
47
47
48
- declare function gtag ( ...args : any ) : void ;
49
-
50
48
@Component ( {
51
49
selector : 'app-root' ,
52
50
templateUrl : './app.component.html' ,
@@ -133,7 +131,6 @@ export class AppComponent extends DataLoadingComponent implements OnInit, OnDest
133
131
distinctUntilChanged ( ( previous , current ) => {
134
132
const previousUrl = new URL ( ( previous as NavigationEnd ) . urlAfterRedirects , location . origin ) ;
135
133
const currentUrl = new URL ( ( current as NavigationEnd ) . urlAfterRedirects , location . origin ) ;
136
- console . log ( previousUrl , currentUrl ) ;
137
134
return previousUrl . pathname === currentUrl . pathname ;
138
135
} ) ,
139
136
map ( e => {
@@ -146,7 +143,9 @@ export class AppComponent extends DataLoadingComponent implements OnInit, OnDest
146
143
} as PageViewEvent ;
147
144
} )
148
145
) ;
149
- this . subscribe ( navEndEvent$ , pageViewEvent => this . analytics . logNavigation ( pageViewEvent ) ) ;
146
+ navEndEvent$
147
+ . pipe ( quietTakeUntilDestroyed ( this . destroyRef ) )
148
+ . subscribe ( pageViewEvent => this . analytics . logNavigation ( pageViewEvent ) ) ;
150
149
}
151
150
152
151
get canInstallOnDevice$ ( ) : Observable < boolean > {
0 commit comments