Added Device Detection and conditional formatting for Mobile
This commit is contained in:
1 parent
166e2503ee
commit
97217cb149
31 files changed
+261
-453
No files matched your search
@@ -1,14 +1,22 @@
|
||||
import { Component } from '@angular/core';
|
||||
import { RouterOutlet, provideRouter } from '@angular/router';
|
||||
import {NgIf} from '@angular/common';
|
||||
import { DeviceDetectorService } from 'ngx-device-detector';
|
||||
import {RouterOutlet, provideRouter, Router} from '@angular/router';
|
||||
import {NavbarComponent} from './navbar/navbar.component';
|
||||
import {MobileNavbarComponent} from './mobile-navbar/mobile-navbar.component';
|
||||
import {FooterComponent} from './footer/footer.component';
|
||||
|
||||
@Component({
|
||||
selector: 'app-root',
|
||||
imports: [RouterOutlet, NavbarComponent, FooterComponent],
|
||||
imports: [RouterOutlet, NavbarComponent, FooterComponent, MobileNavbarComponent, NgIf],
|
||||
templateUrl: './app.component.html',
|
||||
styleUrl: './app.component.css'
|
||||
})
|
||||
export class AppComponent {
|
||||
title = 'itzmineydev';
|
||||
isMobile: boolean;
|
||||
|
||||
constructor(private deviceService: DeviceDetectorService) {
|
||||
this.isMobile = this.deviceService.isMobile();
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user