import { Component , ChangeDetectorRef , ViewChild , ElementRef , } from '@angular/core' ; import { Session } from '../../../../services/session' ; @ Component ( { selector : 'm-walletV2__tokens' , templateUrl : './tokens.component.html' , } ) export class WalletV2TokensComponent { @ ViewChild ( 'dashboardViews' ) dashboardView : ElementRef ; phoneVerified : boolean ; hasOnchainAddress : boolean ; tokenOnboardingComplete = false ; constructor ( private session , private cd ) { } ngOnInit ( ) { this . phoneVerified = this . session . getLoggedInUser ( ) . rewards ; this . hasOnchainAddress = this . session . getLoggedInUser ( ) . eth_wallet ; if ( this . phoneVerified && this . hasOnchainAddress ) { this . tokenOnboardingComplete = true ; } } onTokenOnboardingCompleted ( ) { this . tokenOnboardingComplete = true ; this . detectChanges ( ) ; } detectChanges ( ) { this . cd . markForCheck ( ) ; this . cd . detectChanges ( ) ; } }