Tag: Angular 17

  • How to translate dynamic data coming from api in Angular?

    How to translate dynamic data coming from api in Angular?

    In Angular, to translate dynamic data—that is, data that might change during the runtime of your application—you often use a library designed for internationalization (i18n) and localization. One of the most popular libraries for this purpose in Angular applications is ngx-translate. ngx-translate provides a straightforward way to translate your app, including dynamic data.

    Here’s a basic guide on how to use ngx-translate to translate dynamic data in Angular:

    Step 1: Install ngx-translate

    First, add ngx-translate to your project by installing the core package and the HTTP loader package, which is used to load translations from external files:

    npm install @ngx-translate/core @ngx-translate/http-loader --save

    Step 2: Configure ngx-translate in Your Angular Module

    Import TranslateModule and TranslateLoader from @ngx-translate/core, and TranslateHttpLoader from @ngx-translate/http-loader in your app module. Then, set up TranslateHttpLoader to load translation files from a specific directory (e.g., /assets/i18n/):

    import {NgModule} from '@angular/core';
    import {BrowserModule} from '@angular/platform-browser';
    import {HttpClientModule, HttpClient} from '@angular/common/http';
    import {TranslateModule, TranslateLoader} from '@ngx-translate/core';
    import {TranslateHttpLoader} from '@ngx-translate/http-loader';
    import {AppComponent} from './app.component';
    
    export function HttpLoaderFactory(http: HttpClient) {
      return new TranslateHttpLoader(http, './assets/i18n/', '.json');
    }
    
    @NgModule({
      declarations: [AppComponent],
      imports: [
        BrowserModule,
        HttpClientModule,
        TranslateModule.forRoot({
          loader: {
            provide: TranslateLoader,
            useFactory: HttpLoaderFactory,
            deps: [HttpClient]
          }
        })
      ],
      bootstrap: [AppComponent]
    })
    export class AppModule {}

    Step 3: Create Translation Files

    Create JSON translation files for each language you want to support. Place these files in the /assets/i18n/ directory (or wherever you chose to store them). For example, you might have en.json for English and fr.json for French:

    // en.json
    {
      "greeting": "Hello, {{name}}!"
    }
    
    // fr.json
    {
      "greeting": "Bonjour, {{name}}!"
    }

    Step 4: Use the TranslateService to Translate Dynamic Data

    Inject TranslateService into your component and use it to translate dynamic data. You can use the translate method to get translations programmatically. For data bindings in your templates, you can use the translate pipe.

    import {Component} from '@angular/core';
    import {TranslateService} from '@ngx-translate/core';
    
    @Component({
      selector: 'app-root',
      template: `<div>{{ 'greeting' | translate:param }}</div>`
    })
    export class AppComponent {
      param = {name: 'John'};
    
      constructor(private translate: TranslateService) {
        translate.setDefaultLang('en');
      }
    
      switchLanguage(language: string) {
        this.translate.use(language);
      }
    }

    In this example, the greeting message is dynamic, including a name that can change. By using the translate pipe and passing a parameter (param), you can easily display translated and dynamic content.

    This is a basic overview. ngx-translate offers much more functionality, such as lazy loading of translation resources, fallback languages, and more. Be sure to check out the official ngx-translate documentation for more detailed information and advanced usage.

  • Angular 17 Bootstrap 5 Ecommerce HR Free Admin Dashboard Template

    Angular 17 Bootstrap 5 Ecommerce HR Free Admin Dashboard Template

    Hello everyone, if you’re in search of a responsive and user-friendly admin dashboard template in Angular 17+, then you’ve come to the right place! Today this blog post I will show you Angular 17 Bootstrap 5 Ecommerce HR Free Admin Dashboard Template.

    Live Demo

    Key Features:

    • Built on Angular 17 + Bootstrap 5
    • CSS3 & HTML5
    • Clean & minimal design
    • Cross-browser tested & optimized
    • Full-width layouts
    • Gulp based workflow
    • Opinionated code formatter Prettier for a consistent codebase
    • Modular markup based on Cards & Utility classes
    • Interactive and functional components and pages
    • FontAwesome 5 + material icons + feather icon
    • ApexCharts
    • W3C validated HTML pages

    Angular 17 came and Bootstrap 5 also. If you are new then you must check below two links:

    Guys now here is the complete code snippet with GitHub link following assets(css, js, fonts and images):

    1. Firstly friends we need fresh angular 17 setup and for this we need to run below commands but if you already have angular 17 setup then you can avoid below commands. Secondly we should also have latest node version installed on our system:

    npm install -g @angular/cli 
    
    ng new angularadmin //Create new Angular Project
    
    cd angularadmin // Go inside the Angular Project Folder

    2. Guys now we need to run below commands to create components to our angular application:

    ng g c dashboard
    
    ng g c userprofile

    3. Now guys we need to add below code into our scr/app/app.component.html file for main output:

    <router-outlet></router-outlet>

    4. Now guys we need to add below code into our scr/app/dashboard/dashboard.component.ts file making routing working:

    import { Component } from '@angular/core';
    import { RouterLink, RouterOutlet } from '@angular/router';
    @Component({
      selector: 'app-dashboard',
      standalone: true,
      imports: [RouterOutlet, RouterLink],
      templateUrl: './dashboard.component.html',
      styleUrl: './dashboard.component.css'
    })
    export class DashboardComponent {
    
    }
    

    5. Now guys we need to add below code into our scr/app/dashboard/dashboard.component.html file:

    <!--wrapper-->
    <div class="wrapper">
        <!--sidebar wrapper -->
        <div class="sidebar-wrapper" data-simplebar="true">
          <div class="sidebar-header">
            <div>
              <img src="assets/images/logo-icon.png" class="logo-icon" alt="logo icon">
            </div>
            <div>
              <h4 class="logo-text">Rocker</h4>
            </div>
            <div class="toggle-icon ms-auto"><i class='bx bx-arrow-back'></i>
            </div>
           </div>
          <!--navigation-->
          <ul class="metismenu" id="menu">
            <li>
              <a href="javascript:;" class="has-arrow">
                <div class="parent-icon"><i class='bx bx-home-alt'></i>
                </div>
                <div class="menu-title">Dashboard</div>
              </a>
              <ul>
                <li> <a routerLink="/"><i class='bx bx-radio-circle'></i>Default</a>
                </li>
                <li> <a href="#"><i class='bx bx-radio-circle'></i>Alternate</a>
                </li>
                <li> <a href="#"><i class='bx bx-radio-circle'></i>Graphical</a>
                </li>
              </ul>
            </li>
            
            
            
            
            
            
            
            
            
            <li class="menu-label">Pages</li>
          
            <li>
              <a routerLink="/userprofile">
                <div class="parent-icon"><i class="bx bx-user-circle"></i>
                </div>
                <div class="menu-title">User Profile</div>
              </a>
            </li>
            
            
            
            
          
            
            
          </ul>
          <!--end navigation-->
        </div>
        <!--end sidebar wrapper -->
        <!--start header -->
        <header>
          <div class="topbar d-flex align-items-center">
            <nav class="navbar navbar-expand gap-3">
              <div class="mobile-toggle-menu"><i class='bx bx-menu'></i>
              </div>
      
                <div class="search-bar d-lg-block d-none" data-bs-toggle="modal" data-bs-target="#SearchModal">
                   <a href="avascript:;" class="btn d-flex align-items-center"><i class='bx bx-search'></i>Search</a>
                </div>
      
                <div class="top-menu ms-auto">
                <ul class="navbar-nav align-items-center gap-1">
                  <li class="nav-item mobile-search-icon d-flex d-lg-none" data-bs-toggle="modal" data-bs-target="#SearchModal">
                    <a class="nav-link" href="avascript:;"><i class='bx bx-search'></i>
                    </a>
                  </li>
                  <li class="nav-item dropdown dropdown-laungauge d-none d-sm-flex">
                    <a class="nav-link dropdown-toggle dropdown-toggle-nocaret" href="avascript:;" data-bs-toggle="dropdown"><img src="assets/images/county/02.png" width="22" alt="">
                    </a>
                    <ul class="dropdown-menu dropdown-menu-end">
                      <li><a class="dropdown-item d-flex align-items-center py-2" href="javascript:;"><img src="assets/images/county/01.png" width="20" alt=""><span class="ms-2">English</span></a>
                      </li>
                      <li><a class="dropdown-item d-flex align-items-center py-2" href="javascript:;"><img src="assets/images/county/02.png" width="20" alt=""><span class="ms-2">Catalan</span></a>
                      </li>
                      <li><a class="dropdown-item d-flex align-items-center py-2" href="javascript:;"><img src="assets/images/county/03.png" width="20" alt=""><span class="ms-2">French</span></a>
                      </li>
                      <li><a class="dropdown-item d-flex align-items-center py-2" href="javascript:;"><img src="assets/images/county/04.png" width="20" alt=""><span class="ms-2">Belize</span></a>
                      </li>
                      <li><a class="dropdown-item d-flex align-items-center py-2" href="javascript:;"><img src="assets/images/county/05.png" width="20" alt=""><span class="ms-2">Colombia</span></a>
                      </li>
                      <li><a class="dropdown-item d-flex align-items-center py-2" href="javascript:;"><img src="assets/images/county/06.png" width="20" alt=""><span class="ms-2">Spanish</span></a>
                      </li>
                      <li><a class="dropdown-item d-flex align-items-center py-2" href="javascript:;"><img src="assets/images/county/07.png" width="20" alt=""><span class="ms-2">Georgian</span></a>
                      </li>
                      <li><a class="dropdown-item d-flex align-items-center py-2" href="javascript:;"><img src="assets/images/county/08.png" width="20" alt=""><span class="ms-2">Hindi</span></a>
                      </li>
                    </ul>
                  </li>
                  <li class="nav-item dark-mode d-none d-sm-flex">
                    <a class="nav-link dark-mode-icon" href="javascript:;"><i class='bx bx-moon'></i>
                    </a>
                  </li>
                  <li class="nav-item dropdown dropdown-app">
                    <a class="nav-link dropdown-toggle dropdown-toggle-nocaret" data-bs-toggle="dropdown" href="javascript:;"><i class='bx bx-grid-alt'></i></a>
                    <div class="dropdown-menu dropdown-menu-end p-0">
                      <div class="app-container p-2 my-2">
                        <div class="row gx-0 gy-2 row-cols-3 justify-content-center p-2">
                         <div class="col">
                          <a href="javascript:;">
                          <div class="app-box text-center">
                            <div class="app-icon">
                              <img src="assets/images/app/slack.png" width="30" alt="">
                            </div>
                            <div class="app-name">
                              <p class="mb-0 mt-1">Slack</p>
                            </div>
                            </div>
                          </a>
                         </div>
                         <div class="col">
                          <a href="javascript:;">
                          <div class="app-box text-center">
                            <div class="app-icon">
                              <img src="assets/images/app/behance.png" width="30" alt="">
                            </div>
                            <div class="app-name">
                              <p class="mb-0 mt-1">Behance</p>
                            </div>
                            </div>
                          </a>
                         </div>
                         <div class="col">
                          <a href="javascript:;">
                          <div class="app-box text-center">
                            <div class="app-icon">
                            <img src="assets/images/app/google-drive.png" width="30" alt="">
                            </div>
                            <div class="app-name">
                              <p class="mb-0 mt-1">Dribble</p>
                            </div>
                            </div>
                          </a>
                         </div>
                         <div class="col">
                          <a href="javascript:;">
                          <div class="app-box text-center">
                            <div class="app-icon">
                              <img src="assets/images/app/outlook.png" width="30" alt="">
                            </div>
                            <div class="app-name">
                              <p class="mb-0 mt-1">Outlook</p>
                            </div>
                            </div>
                          </a>
                         </div>
                         <div class="col">
                          <a href="javascript:;">
                          <div class="app-box text-center">
                            <div class="app-icon">
                              <img src="assets/images/app/github.png" width="30" alt="">
                            </div>
                            <div class="app-name">
                              <p class="mb-0 mt-1">GitHub</p>
                            </div>
                            </div>
                          </a>
                         </div>
                         <div class="col">
                          <a href="javascript:;">
                          <div class="app-box text-center">
                            <div class="app-icon">
                              <img src="assets/images/app/stack-overflow.png" width="30" alt="">
                            </div>
                            <div class="app-name">
                              <p class="mb-0 mt-1">Stack</p>
                            </div>
                            </div>
                          </a>
                         </div>
                         <div class="col">
                          <a href="javascript:;">
                          <div class="app-box text-center">
                            <div class="app-icon">
                              <img src="assets/images/app/figma.png" width="30" alt="">
                            </div>
                            <div class="app-name">
                              <p class="mb-0 mt-1">Stack</p>
                            </div>
                            </div>
                          </a>
                         </div>
                         <div class="col">
                          <a href="javascript:;">
                          <div class="app-box text-center">
                            <div class="app-icon">
                              <img src="assets/images/app/twitter.png" width="30" alt="">
                            </div>
                            <div class="app-name">
                              <p class="mb-0 mt-1">Twitter</p>
                            </div>
                            </div>
                          </a>
                         </div>
                         <div class="col">
                          <a href="javascript:;">
                          <div class="app-box text-center">
                            <div class="app-icon">
                              <img src="assets/images/app/google-calendar.png" width="30" alt="">
                            </div>
                            <div class="app-name">
                              <p class="mb-0 mt-1">Calendar</p>
                            </div>
                            </div>
                          </a>
                         </div>
                         <div class="col">
                          <a href="javascript:;">
                          <div class="app-box text-center">
                            <div class="app-icon">
                              <img src="assets/images/app/spotify.png" width="30" alt="">
                            </div>
                            <div class="app-name">
                              <p class="mb-0 mt-1">Spotify</p>
                            </div>
                            </div>
                          </a>
                         </div>
                         <div class="col">
                          <a href="javascript:;">
                          <div class="app-box text-center">
                            <div class="app-icon">
                              <img src="assets/images/app/google-photos.png" width="30" alt="">
                            </div>
                            <div class="app-name">
                              <p class="mb-0 mt-1">Photos</p>
                            </div>
                            </div>
                          </a>
                         </div>
                         <div class="col">
                          <a href="javascript:;">
                          <div class="app-box text-center">
                            <div class="app-icon">
                              <img src="assets/images/app/pinterest.png" width="30" alt="">
                            </div>
                            <div class="app-name">
                              <p class="mb-0 mt-1">Photos</p>
                            </div>
                            </div>
                          </a>
                         </div>
                         <div class="col">
                          <a href="javascript:;">
                          <div class="app-box text-center">
                            <div class="app-icon">
                              <img src="assets/images/app/linkedin.png" width="30" alt="">
                            </div>
                            <div class="app-name">
                              <p class="mb-0 mt-1">linkedin</p>
                            </div>
                            </div>
                          </a>
                         </div>
                         <div class="col">
                          <a href="javascript:;">
                          <div class="app-box text-center">
                            <div class="app-icon">
                              <img src="assets/images/app/dribble.png" width="30" alt="">
                            </div>
                            <div class="app-name">
                              <p class="mb-0 mt-1">Dribble</p>
                            </div>
                            </div>
                          </a>
                         </div>
                         <div class="col">
                          <a href="javascript:;">
                          <div class="app-box text-center">
                            <div class="app-icon">
                              <img src="assets/images/app/youtube.png" width="30" alt="">
                            </div>
                            <div class="app-name">
                              <p class="mb-0 mt-1">YouTube</p>
                            </div>
                            </div>
                          </a>
                         </div>
                         <div class="col">
                          <a href="javascript:;">
                          <div class="app-box text-center">
                            <div class="app-icon">
                              <img src="assets/images/app/google.png" width="30" alt="">
                            </div>
                            <div class="app-name">
                              <p class="mb-0 mt-1">News</p>
                            </div>
                            </div>
                          </a>
                         </div>
                         <div class="col">
                          <a href="javascript:;">
                          <div class="app-box text-center">
                            <div class="app-icon">
                              <img src="assets/images/app/envato.png" width="30" alt="">
                            </div>
                            <div class="app-name">
                              <p class="mb-0 mt-1">Envato</p>
                            </div>
                            </div>
                          </a>
                         </div>
                         <div class="col">
                          <a href="javascript:;">
                          <div class="app-box text-center">
                            <div class="app-icon">
                              <img src="assets/images/app/safari.png" width="30" alt="">
                            </div>
                            <div class="app-name">
                              <p class="mb-0 mt-1">Safari</p>
                            </div>
                            </div>
                          </a>
                         </div>
            
                        </div><!--end row-->
            
                      </div>
                    </div>
                  </li>
      
                  <li class="nav-item dropdown dropdown-large">
                    <a class="nav-link dropdown-toggle dropdown-toggle-nocaret position-relative" href="#" data-bs-toggle="dropdown"><span class="alert-count">7</span>
                      <i class='bx bx-bell'></i>
                    </a>
                    <div class="dropdown-menu dropdown-menu-end">
                      <a href="javascript:;">
                        <div class="msg-header">
                          <p class="msg-header-title">Notifications</p>
                          <p class="msg-header-badge">8 New</p>
                        </div>
                      </a>
                      <div class="header-notifications-list">
                        <a class="dropdown-item" href="javascript:;">
                          <div class="d-flex align-items-center">
                            <div class="user-online">
                              <img src="assets/images/avatars/avatar-1.png" class="msg-avatar" alt="user avatar">
                            </div>
                            <div class="flex-grow-1">
                              <h6 class="msg-name">Daisy Anderson<span class="msg-time float-end">5 sec
                            ago</span></h6>
                              <p class="msg-info">The standard chunk of lorem</p>
                            </div>
                          </div>
                        </a>
                        <a class="dropdown-item" href="javascript:;">
                          <div class="d-flex align-items-center">
                            <div class="notify bg-light-danger text-danger">dc
                            </div>
                            <div class="flex-grow-1">
                              <h6 class="msg-name">New Orders <span class="msg-time float-end">2 min
                            ago</span></h6>
                              <p class="msg-info">You have recived new orders</p>
                            </div>
                          </div>
                        </a>
                        <a class="dropdown-item" href="javascript:;">
                          <div class="d-flex align-items-center">
                            <div class="user-online">
                              <img src="assets/images/avatars/avatar-2.png" class="msg-avatar" alt="user avatar">
                            </div>
                            <div class="flex-grow-1">
                              <h6 class="msg-name">Althea Cabardo <span class="msg-time float-end">14
                            sec ago</span></h6>
                              <p class="msg-info">Many desktop publishing packages</p>
                            </div>
                          </div>
                        </a>
                        <a class="dropdown-item" href="javascript:;">
                          <div class="d-flex align-items-center">
                            <div class="notify bg-light-success text-success">
                              <img src="assets/images/app/outlook.png" width="25" alt="user avatar">
                            </div>
                            <div class="flex-grow-1">
                              <h6 class="msg-name">Account Created<span class="msg-time float-end">28 min
                            ago</span></h6>
                              <p class="msg-info">Successfully created new email</p>
                            </div>
                          </div>
                        </a>
                        <a class="dropdown-item" href="javascript:;">
                          <div class="d-flex align-items-center">
                            <div class="notify bg-light-info text-info">Ss
                            </div>
                            <div class="flex-grow-1">
                              <h6 class="msg-name">New Product Approved <span
                            class="msg-time float-end">2 hrs ago</span></h6>
                              <p class="msg-info">Your new product has approved</p>
                            </div>
                          </div>
                        </a>
                        <a class="dropdown-item" href="javascript:;">
                          <div class="d-flex align-items-center">
                            <div class="user-online">
                              <img src="assets/images/avatars/avatar-4.png" class="msg-avatar" alt="user avatar">
                            </div>
                            <div class="flex-grow-1">
                              <h6 class="msg-name">Katherine Pechon <span class="msg-time float-end">15
                            min ago</span></h6>
                              <p class="msg-info">Making this the first true generator</p>
                            </div>
                          </div>
                        </a>
                        <a class="dropdown-item" href="javascript:;">
                          <div class="d-flex align-items-center">
                            <div class="notify bg-light-success text-success"><i class='bx bx-check-square'></i>
                            </div>
                            <div class="flex-grow-1">
                              <h6 class="msg-name">Your item is shipped <span class="msg-time float-end">5 hrs
                            ago</span></h6>
                              <p class="msg-info">Successfully shipped your item</p>
                            </div>
                          </div>
                        </a>
                        <a class="dropdown-item" href="javascript:;">
                          <div class="d-flex align-items-center">
                            <div class="notify bg-light-primary">
                              <img src="assets/images/app/github.png" width="25" alt="user avatar">
                            </div>
                            <div class="flex-grow-1">
                              <h6 class="msg-name">New 24 authors<span class="msg-time float-end">1 day
                            ago</span></h6>
                              <p class="msg-info">24 new authors joined last week</p>
                            </div>
                          </div>
                        </a>
                        <a class="dropdown-item" href="javascript:;">
                          <div class="d-flex align-items-center">
                            <div class="user-online">
                              <img src="assets/images/avatars/avatar-8.png" class="msg-avatar" alt="user avatar">
                            </div>
                            <div class="flex-grow-1">
                              <h6 class="msg-name">Peter Costanzo <span class="msg-time float-end">6 hrs
                            ago</span></h6>
                              <p class="msg-info">It was popularised in the 1960s</p>
                            </div>
                          </div>
                        </a>
                      </div>
                      <a href="javascript:;">
                        <div class="text-center msg-footer">
                          <button class="btn btn-primary w-100">View All Notifications</button>
                        </div>
                      </a>
                    </div>
                  </li>
                  <li class="nav-item dropdown dropdown-large">
                    <a class="nav-link dropdown-toggle dropdown-toggle-nocaret position-relative" href="#" role="button" data-bs-toggle="dropdown" aria-expanded="false"> <span class="alert-count">8</span>
                      <i class='bx bx-shopping-bag'></i>
                    </a>
                    <div class="dropdown-menu dropdown-menu-end">
                      <a href="javascript:;">
                        <div class="msg-header">
                          <p class="msg-header-title">My Cart</p>
                          <p class="msg-header-badge">10 Items</p>
                        </div>
                      </a>
                      <div class="header-message-list">
                        <a class="dropdown-item" href="javascript:;">
                          <div class="d-flex align-items-center gap-3">
                            <div class="position-relative">
                              <div class="cart-product rounded-circle bg-light">
                                <img src="assets/images/products/11.png" class="" alt="product image">
                              </div>
                            </div>
                            <div class="flex-grow-1">
                              <h6 class="cart-product-title mb-0">Men White T-Shirt</h6>
                              <p class="cart-product-price mb-0">1 X $29.00</p>
                            </div>
                            <div class="">
                              <p class="cart-price mb-0">$250</p>
                            </div>
                            <div class="cart-product-cancel"><i class="bx bx-x"></i>
                            </div>
                          </div>
                        </a>
                        <a class="dropdown-item" href="javascript:;">
                          <div class="d-flex align-items-center gap-3">
                            <div class="position-relative">
                              <div class="cart-product rounded-circle bg-light">
                                <img src="assets/images/products/02.png" class="" alt="product image">
                              </div>
                            </div>
                            <div class="flex-grow-1">
                              <h6 class="cart-product-title mb-0">Men White T-Shirt</h6>
                              <p class="cart-product-price mb-0">1 X $29.00</p>
                            </div>
                            <div class="">
                              <p class="cart-price mb-0">$250</p>
                            </div>
                            <div class="cart-product-cancel"><i class="bx bx-x"></i>
                            </div>
                          </div>
                        </a>
                        <a class="dropdown-item" href="javascript:;">
                          <div class="d-flex align-items-center gap-3">
                            <div class="position-relative">
                              <div class="cart-product rounded-circle bg-light">
                                <img src="assets/images/products/03.png" class="" alt="product image">
                              </div>
                            </div>
                            <div class="flex-grow-1">
                              <h6 class="cart-product-title mb-0">Men White T-Shirt</h6>
                              <p class="cart-product-price mb-0">1 X $29.00</p>
                            </div>
                            <div class="">
                              <p class="cart-price mb-0">$250</p>
                            </div>
                            <div class="cart-product-cancel"><i class="bx bx-x"></i>
                            </div>
                          </div>
                        </a>
                        <a class="dropdown-item" href="javascript:;">
                          <div class="d-flex align-items-center gap-3">
                            <div class="position-relative">
                              <div class="cart-product rounded-circle bg-light">
                                <img src="assets/images/products/04.png" class="" alt="product image">
                              </div>
                            </div>
                            <div class="flex-grow-1">
                              <h6 class="cart-product-title mb-0">Men White T-Shirt</h6>
                              <p class="cart-product-price mb-0">1 X $29.00</p>
                            </div>
                            <div class="">
                              <p class="cart-price mb-0">$250</p>
                            </div>
                            <div class="cart-product-cancel"><i class="bx bx-x"></i>
                            </div>
                          </div>
                        </a>
                        <a class="dropdown-item" href="javascript:;">
                          <div class="d-flex align-items-center gap-3">
                            <div class="position-relative">
                              <div class="cart-product rounded-circle bg-light">
                                <img src="assets/images/products/05.png" class="" alt="product image">
                              </div>
                            </div>
                            <div class="flex-grow-1">
                              <h6 class="cart-product-title mb-0">Men White T-Shirt</h6>
                              <p class="cart-product-price mb-0">1 X $29.00</p>
                            </div>
                            <div class="">
                              <p class="cart-price mb-0">$250</p>
                            </div>
                            <div class="cart-product-cancel"><i class="bx bx-x"></i>
                            </div>
                          </div>
                        </a>
                        <a class="dropdown-item" href="javascript:;">
                          <div class="d-flex align-items-center gap-3">
                            <div class="position-relative">
                              <div class="cart-product rounded-circle bg-light">
                                <img src="assets/images/products/06.png" class="" alt="product image">
                              </div>
                            </div>
                            <div class="flex-grow-1">
                              <h6 class="cart-product-title mb-0">Men White T-Shirt</h6>
                              <p class="cart-product-price mb-0">1 X $29.00</p>
                            </div>
                            <div class="">
                              <p class="cart-price mb-0">$250</p>
                            </div>
                            <div class="cart-product-cancel"><i class="bx bx-x"></i>
                            </div>
                          </div>
                        </a>
                        <a class="dropdown-item" href="javascript:;">
                          <div class="d-flex align-items-center gap-3">
                            <div class="position-relative">
                              <div class="cart-product rounded-circle bg-light">
                                <img src="assets/images/products/07.png" class="" alt="product image">
                              </div>
                            </div>
                            <div class="flex-grow-1">
                              <h6 class="cart-product-title mb-0">Men White T-Shirt</h6>
                              <p class="cart-product-price mb-0">1 X $29.00</p>
                            </div>
                            <div class="">
                              <p class="cart-price mb-0">$250</p>
                            </div>
                            <div class="cart-product-cancel"><i class="bx bx-x"></i>
                            </div>
                          </div>
                        </a>
                        <a class="dropdown-item" href="javascript:;">
                          <div class="d-flex align-items-center gap-3">
                            <div class="position-relative">
                              <div class="cart-product rounded-circle bg-light">
                                <img src="assets/images/products/08.png" class="" alt="product image">
                              </div>
                            </div>
                            <div class="flex-grow-1">
                              <h6 class="cart-product-title mb-0">Men White T-Shirt</h6>
                              <p class="cart-product-price mb-0">1 X $29.00</p>
                            </div>
                            <div class="">
                              <p class="cart-price mb-0">$250</p>
                            </div>
                            <div class="cart-product-cancel"><i class="bx bx-x"></i>
                            </div>
                          </div>
                        </a>
                        <a class="dropdown-item" href="javascript:;">
                          <div class="d-flex align-items-center gap-3">
                            <div class="position-relative">
                              <div class="cart-product rounded-circle bg-light">
                                <img src="assets/images/products/09.png" class="" alt="product image">
                              </div>
                            </div>
                            <div class="flex-grow-1">
                              <h6 class="cart-product-title mb-0">Men White T-Shirt</h6>
                              <p class="cart-product-price mb-0">1 X $29.00</p>
                            </div>
                            <div class="">
                              <p class="cart-price mb-0">$250</p>
                            </div>
                            <div class="cart-product-cancel"><i class="bx bx-x"></i>
                            </div>
                          </div>
                        </a>
                      </div>
                      <a href="javascript:;">
                        <div class="text-center msg-footer">
                          <div class="d-flex align-items-center justify-content-between mb-3">
                            <h5 class="mb-0">Total</h5>
                            <h5 class="mb-0 ms-auto">$489.00</h5>
                          </div>
                          <button class="btn btn-primary w-100">Checkout</button>
                        </div>
                      </a>
                    </div>
                  </li>
                </ul>
              </div>
              <div class="user-box dropdown px-3">
                <a class="d-flex align-items-center nav-link dropdown-toggle gap-3 dropdown-toggle-nocaret" href="#" role="button" data-bs-toggle="dropdown" aria-expanded="false">
                  <img src="assets/images/avatars/avatar-2.png" class="user-img" alt="user avatar">
                  <div class="user-info">
                    <p class="user-name mb-0">Pauline Seitz</p>
                    <p class="designattion mb-0">Web Designer</p>
                  </div>
                </a>
                <ul class="dropdown-menu dropdown-menu-end">
                  <li><a class="dropdown-item d-flex align-items-center" href="javascript:;"><i class="bx bx-user fs-5"></i><span>Profile</span></a>
                  </li>
                  <li><a class="dropdown-item d-flex align-items-center" href="javascript:;"><i class="bx bx-cog fs-5"></i><span>Settings</span></a>
                  </li>
                  <li><a class="dropdown-item d-flex align-items-center" href="javascript:;"><i class="bx bx-home-circle fs-5"></i><span>Dashboard</span></a>
                  </li>
                  <li><a class="dropdown-item d-flex align-items-center" href="javascript:;"><i class="bx bx-dollar-circle fs-5"></i><span>Earnings</span></a>
                  </li>
                  <li><a class="dropdown-item d-flex align-items-center" href="javascript:;"><i class="bx bx-download fs-5"></i><span>Downloads</span></a>
                  </li>
                  <li>
                    <div class="dropdown-divider mb-0"></div>
                  </li>
                  <li><a class="dropdown-item d-flex align-items-center" href="javascript:;"><i class="bx bx-log-out-circle"></i><span>Logout</span></a>
                  </li>
                </ul>
              </div>
            </nav>
          </div>
        </header>
        <!--end header -->
        <!--start page wrapper -->
        <div class="page-wrapper">
          <div class="page-content">
            <div class="row row-cols-1 row-cols-md-2 row-cols-xl-4">
                       <div class="col">
               <div class="card radius-10 border-start border-0 border-4 border-info">
                <div class="card-body">
                  <div class="d-flex align-items-center">
                    <div>
                      <p class="mb-0 text-secondary">Total Orders</p>
                      <h4 class="my-1 text-info">4805</h4>
                      <p class="mb-0 font-13">+2.5% from last week</p>
                    </div>
                    <div class="widgets-icons-2 rounded-circle bg-gradient-blues text-white ms-auto"><i class='bx bxs-cart'></i>
                    </div>
                  </div>
                </div>
               </div>
               </div>
               <div class="col">
              <div class="card radius-10 border-start border-0 border-4 border-danger">
                 <div class="card-body">
                   <div class="d-flex align-items-center">
                     <div>
                       <p class="mb-0 text-secondary">Total Revenue</p>
                       <h4 class="my-1 text-danger">$84,245</h4>
                       <p class="mb-0 font-13">+5.4% from last week</p>
                     </div>
                     <div class="widgets-icons-2 rounded-circle bg-gradient-burning text-white ms-auto"><i class='bx bxs-wallet'></i>
                     </div>
                   </div>
                 </div>
              </div>
              </div>
              <div class="col">
              <div class="card radius-10 border-start border-0 border-4 border-success">
                 <div class="card-body">
                   <div class="d-flex align-items-center">
                     <div>
                       <p class="mb-0 text-secondary">Bounce Rate</p>
                       <h4 class="my-1 text-success">34.6%</h4>
                       <p class="mb-0 font-13">-4.5% from last week</p>
                     </div>
                     <div class="widgets-icons-2 rounded-circle bg-gradient-ohhappiness text-white ms-auto"><i class='bx bxs-bar-chart-alt-2' ></i>
                     </div>
                   </div>
                 </div>
              </div>
              </div>
              <div class="col">
              <div class="card radius-10 border-start border-0 border-4 border-warning">
                 <div class="card-body">
                   <div class="d-flex align-items-center">
                     <div>
                       <p class="mb-0 text-secondary">Total Customers</p>
                       <h4 class="my-1 text-warning">8.4K</h4>
                       <p class="mb-0 font-13">+8.4% from last week</p>
                     </div>
                     <div class="widgets-icons-2 rounded-circle bg-gradient-orange text-white ms-auto"><i class='bx bxs-group'></i>
                     </div>
                   </div>
                 </div>
              </div>
              </div> 
            </div><!--end row-->
      
            <div class="row">
                       <div class="col-12 col-lg-8 d-flex">
                          <div class="card radius-10 w-100">
                <div class="card-header">
                  <div class="d-flex align-items-center">
                    <div>
                      <h6 class="mb-0">Sales Overview</h6>
                    </div>
                    <div class="dropdown ms-auto">
                      <a class="dropdown-toggle dropdown-toggle-nocaret" href="#" data-bs-toggle="dropdown"><i class='bx bx-dots-horizontal-rounded font-22 text-option'></i>
                      </a>
                      <ul class="dropdown-menu">
                        <li><a class="dropdown-item" href="javascript:;">Action</a>
                        </li>
                        <li><a class="dropdown-item" href="javascript:;">Another action</a>
                        </li>
                        <li>
                          <hr class="dropdown-divider">
                        </li>
                        <li><a class="dropdown-item" href="javascript:;">Something else here</a>
                        </li>
                      </ul>
                    </div>
                  </div>
                </div>
                  <div class="card-body">
                  <div class="d-flex align-items-center ms-auto font-13 gap-2 mb-3">
                    <span class="border px-1 rounded cursor-pointer"><i class="bx bxs-circle me-1" style="color: #14abef"></i>Sales</span>
                    <span class="border px-1 rounded cursor-pointer"><i class="bx bxs-circle me-1" style="color: #ffc107"></i>Visits</span>
                  </div>
                  <div class="chart-container-1">
                    <canvas id="chart1"></canvas>
                    </div>
                  </div>
                  <div class="row row-cols-1 row-cols-md-3 row-cols-xl-3 g-0 row-group text-center border-top">
                  <div class="col">
                    <div class="p-3">
                    <h5 class="mb-0">24.15M</h5>
                    <small class="mb-0">Overall Visitor <span> <i class="bx bx-up-arrow-alt align-middle"></i> 2.43%</span></small>
                    </div>
                  </div>
                  <div class="col">
                    <div class="p-3">
                    <h5 class="mb-0">12:38</h5>
                    <small class="mb-0">Visitor Duration <span> <i class="bx bx-up-arrow-alt align-middle"></i> 12.65%</span></small>
                    </div>
                  </div>
                  <div class="col">
                    <div class="p-3">
                    <h5 class="mb-0">639.82</h5>
                    <small class="mb-0">Pages/Visit <span> <i class="bx bx-up-arrow-alt align-middle"></i> 5.62%</span></small>
                    </div>
                  </div>
                  </div>
                </div>
               </div>
               <div class="col-12 col-lg-4 d-flex">
                           <div class="card radius-10 w-100">
                <div class="card-header">
                  <div class="d-flex align-items-center">
                    <div>
                      <h6 class="mb-0">Trending Products</h6>
                    </div>
                    <div class="dropdown ms-auto">
                      <a class="dropdown-toggle dropdown-toggle-nocaret" href="#" data-bs-toggle="dropdown"><i class='bx bx-dots-horizontal-rounded font-22 text-option'></i>
                      </a>
                      <ul class="dropdown-menu">
                        <li><a class="dropdown-item" href="javascript:;">Action</a>
                        </li>
                        <li><a class="dropdown-item" href="javascript:;">Another action</a>
                        </li>
                        <li>
                          <hr class="dropdown-divider">
                        </li>
                        <li><a class="dropdown-item" href="javascript:;">Something else here</a>
                        </li>
                      </ul>
                    </div>
                  </div>
                </div>
                   <div class="card-body">
                  <div class="chart-container-2">
                    <canvas id="chart2"></canvas>
                    </div>
                   </div>
                   <ul class="list-group list-group-flush">
                  <li class="list-group-item d-flex bg-transparent justify-content-between align-items-center border-top">Jeans <span class="badge bg-success rounded-pill">25</span>
                  </li>
                  <li class="list-group-item d-flex bg-transparent justify-content-between align-items-center">T-Shirts <span class="badge bg-danger rounded-pill">10</span>
                  </li>
                  <li class="list-group-item d-flex bg-transparent justify-content-between align-items-center">Shoes <span class="badge bg-primary rounded-pill">65</span>
                  </li>
                  <li class="list-group-item d-flex bg-transparent justify-content-between align-items-center">Lingerie <span class="badge bg-warning text-dark rounded-pill">14</span>
                  </li>
                </ul>
                 </div>
               </div>
            </div><!--end row-->
      
             <div class="card radius-10">
              <div class="card-header">
                <div class="d-flex align-items-center">
                  <div>
                    <h6 class="mb-0">Recent Orders</h6>
                  </div>
                  <div class="dropdown ms-auto">
                    <a class="dropdown-toggle dropdown-toggle-nocaret" href="#" data-bs-toggle="dropdown"><i class='bx bx-dots-horizontal-rounded font-22 text-option'></i>
                    </a>
                    <ul class="dropdown-menu">
                      <li><a class="dropdown-item" href="javascript:;">Action</a>
                      </li>
                      <li><a class="dropdown-item" href="javascript:;">Another action</a>
                      </li>
                      <li>
                        <hr class="dropdown-divider">
                      </li>
                      <li><a class="dropdown-item" href="javascript:;">Something else here</a>
                      </li>
                    </ul>
                  </div>
                </div>
              </div>
                             <div class="card-body">
                 <div class="table-responsive">
                   <table class="table align-middle mb-0">
                  <thead class="table-light">
                   <tr>
                     <th>Product</th>
                     <th>Photo</th>
                     <th>Product ID</th>
                     <th>Status</th>
                     <th>Amount</th>
                     <th>Date</th>
                     <th>Shipping</th>
                   </tr>
                   </thead>
                   <tbody><tr>
                    <td>Iphone 5</td>
                    <td><img src="assets/images/products/01.png" class="product-img-2" alt="product img"></td>
                    <td>#9405822</td>
                    <td><span class="badge bg-gradient-quepal text-white shadow-sm w-100">Paid</span></td>
                    <td>$1250.00</td>
                    <td>03 Feb 2020</td>
                    <td><div class="progress" style="height: 6px;">
                      <div class="progress-bar bg-gradient-quepal" role="progressbar" style="width: 100%"></div>
                      </div></td>
                   </tr>
          
                   <tr>
                    <td>Earphone GL</td>
                    <td><img src="assets/images/products/02.png" class="product-img-2" alt="product img"></td>
                    <td>#8304620</td>
                    <td><span class="badge bg-gradient-blooker text-white shadow-sm w-100">Pending</span></td>
                    <td>$1500.00</td>
                    <td>05 Feb 2020</td>
                    <td><div class="progress" style="height: 6px;">
                      <div class="progress-bar bg-gradient-blooker" role="progressbar" style="width: 60%"></div>
                      </div></td>
                   </tr>
          
                   <tr>
                    <td>HD Hand Camera</td>
                    <td><img src="assets/images/products/03.png" class="product-img-2" alt="product img"></td>
                    <td>#4736890</td>
                    <td><span class="badge bg-gradient-bloody text-white shadow-sm w-100">Failed</span></td>
                    <td>$1400.00</td>
                    <td>06 Feb 2020</td>
                    <td><div class="progress" style="height: 6px;">
                      <div class="progress-bar bg-gradient-bloody" role="progressbar" style="width: 70%"></div>
                      </div></td>
                   </tr>
          
                   <tr>
                    <td>Clasic Shoes</td>
                    <td><img src="assets/images/products/04.png" class="product-img-2" alt="product img"></td>
                    <td>#8543765</td>
                    <td><span class="badge bg-gradient-quepal text-white shadow-sm w-100">Paid</span></td>
                    <td>$1200.00</td>
                    <td>14 Feb 2020</td>
                    <td><div class="progress" style="height: 6px;">
                      <div class="progress-bar bg-gradient-quepal" role="progressbar" style="width: 100%"></div>
                      </div></td>
                   </tr>
                   <tr>
                    <td>Sitting Chair</td>
                    <td><img src="assets/images/products/06.png" class="product-img-2" alt="product img"></td>
                    <td>#9629240</td>
                    <td><span class="badge bg-gradient-blooker text-white shadow-sm w-100">Pending</span></td>
                    <td>$1500.00</td>
                    <td>18 Feb 2020</td>
                    <td><div class="progress" style="height: 6px;">
                      <div class="progress-bar bg-gradient-blooker" role="progressbar" style="width: 60%"></div>
                      </div></td>
                   </tr>
                   <tr>
                    <td>Hand Watch</td>
                    <td><img src="assets/images/products/05.png" class="product-img-2" alt="product img"></td>
                    <td>#8506790</td>
                    <td><span class="badge bg-gradient-bloody text-white shadow-sm w-100">Failed</span></td>
                    <td>$1800.00</td>
                    <td>21 Feb 2020</td>
                    <td><div class="progress" style="height: 6px;">
                      <div class="progress-bar bg-gradient-bloody" role="progressbar" style="width: 40%"></div>
                      </div></td>
                   </tr>
                    </tbody>
                  </table>
                  </div>
                 </div>
              </div>
      
      
              <div class="row">
                <div class="col-12 col-lg-7 col-xl-8 d-flex">
                  <div class="card radius-10 w-100">
                  <div class="card-header bg-transparent">
                    <div class="d-flex align-items-center">
                      <div>
                        <h6 class="mb-0">Recent Orders</h6>
                      </div>
                      <div class="dropdown ms-auto">
                        <a class="dropdown-toggle dropdown-toggle-nocaret" href="#" data-bs-toggle="dropdown"><i class='bx bx-dots-horizontal-rounded font-22 text-option'></i>
                        </a>
                        <ul class="dropdown-menu">
                          <li><a class="dropdown-item" href="javascript:;">Action</a>
                          </li>
                          <li><a class="dropdown-item" href="javascript:;">Another action</a>
                          </li>
                          <li>
                            <hr class="dropdown-divider">
                          </li>
                          <li><a class="dropdown-item" href="javascript:;">Something else here</a>
                          </li>
                        </ul>
                      </div>
                    </div>
                     </div>
                   <div class="card-body">
                    <div class="row">
                      <div class="col-lg-7 col-xl-8 border-end">
                       <div id="geographic-map-2"></div>
                      </div>
                      <div class="col-lg-5 col-xl-4">
                                 
                      <div class="mb-4">
                      <p class="mb-2"><i class="flag-icon flag-icon-us me-1"></i> USA <span class="float-end">70%</span></p>
                      <div class="progress" style="height: 7px;">
                         <div class="progress-bar bg-primary progress-bar-striped" role="progressbar" style="width: 70%"></div>
                       </div>
                      </div>
             
                      <div class="mb-4">
                       <p class="mb-2"><i class="flag-icon flag-icon-ca me-1"></i> Canada <span class="float-end">65%</span></p>
                       <div class="progress" style="height: 7px;">
                         <div class="progress-bar bg-danger progress-bar-striped" role="progressbar" style="width: 65%"></div>
                       </div>
                      </div>
             
                      <div class="mb-4">
                       <p class="mb-2"><i class="flag-icon flag-icon-gb me-1"></i> England <span class="float-end">60%</span></p>
                       <div class="progress" style="height: 7px;">
                         <div class="progress-bar bg-success progress-bar-striped" role="progressbar" style="width: 60%"></div>
                         </div>
                      </div>
             
                      <div class="mb-4">
                       <p class="mb-2"><i class="flag-icon flag-icon-au me-1"></i> Australia <span class="float-end">55%</span></p>
                       <div class="progress" style="height: 7px;">
                         <div class="progress-bar bg-warning progress-bar-striped" role="progressbar" style="width: 55%"></div>
                         </div>
                      </div>
             
                      <div class="mb-4">
                       <p class="mb-2"><i class="flag-icon flag-icon-in me-1"></i> India <span class="float-end">50%</span></p>
                       <div class="progress" style="height: 7px;">
                         <div class="progress-bar bg-info progress-bar-striped" role="progressbar" style="width: 50%"></div>
                         </div>
                      </div>
      
                      <div class="mb-0">
                         <p class="mb-2"><i class="flag-icon flag-icon-cn me-1"></i> China <span class="float-end">45%</span></p>
                         <div class="progress" style="height: 7px;">
                           <div class="progress-bar bg-dark progress-bar-striped" role="progressbar" style="width: 45%"></div>
                         </div>
                      </div>
      
                      </div>
                    </div>
                   </div>
                   </div>
                </div>
             
                <div class="col-12 col-lg-5 col-xl-4 d-flex">
                  <div class="card w-100 radius-10">
                     <div class="card-body">
                    <div class="card radius-10 border shadow-none">
                    <div class="card-body">
                      <div class="d-flex align-items-center">
                        <div>
                          <p class="mb-0 text-secondary">Total Likes</p>
                          <h4 class="my-1">45.6M</h4>
                          <p class="mb-0 font-13">+6.2% from last week</p>
                        </div>
                        <div class="widgets-icons-2 bg-gradient-cosmic text-white ms-auto"><i class='bx bxs-heart-circle'></i>
                        </div>
                      </div>
                    </div>
                   </div>
                   <div class="card radius-10 border shadow-none">
                    <div class="card-body">
                      <div class="d-flex align-items-center">
                        <div>
                          <p class="mb-0 text-secondary">Comments</p>
                          <h4 class="my-1">25.6K</h4>
                          <p class="mb-0 font-13">+3.7% from last week</p>
                        </div>
                        <div class="widgets-icons-2 bg-gradient-ibiza text-white ms-auto"><i class='bx bxs-comment-detail'></i>
                        </div>
                      </div>
                    </div>
                   </div>
                   <div class="card radius-10 mb-0 border shadow-none">
                    <div class="card-body">
                      <div class="d-flex align-items-center">
                        <div>
                          <p class="mb-0 text-secondary">Total Shares</p>
                          <h4 class="my-1">85.4M</h4>
                          <p class="mb-0 font-13">+4.6% from last week</p>
                        </div>
                        <div class="widgets-icons-2 bg-gradient-kyoto text-dark ms-auto"><i class='bx bxs-share-alt'></i>
                        </div>
                      </div>
                    </div>
                    </div>
                   </div>
      
                  </div>
             
                </div>
               </div><!--end row-->
      
               <div class="row row-cols-1 row-cols-lg-3">
                 <div class="col d-flex">
                               <div class="card radius-10 w-100">
                     <div class="card-body">
                    <p class="font-weight-bold mb-1 text-secondary">Weekly Revenue</p>
                    <div class="d-flex align-items-center mb-4">
                      <div>
                        <h4 class="mb-0">$89,540</h4>
                      </div>
                      <div class="">
                        <p class="mb-0 align-self-center font-weight-bold text-success ms-2">4.4% <i class="bx bxs-up-arrow-alt mr-2"></i>
                        </p>
                      </div>
                    </div>
                    <div class="chart-container-0 mt-5">
                      <canvas id="chart3"></canvas>
                      </div>
                     </div>
                   </div>
                 </div>
                 <div class="col d-flex">
                  <div class="card radius-10 w-100">
                    <div class="card-header bg-transparent">
                      <div class="d-flex align-items-center">
                        <div>
                          <h6 class="mb-0">Orders Summary</h6>
                        </div>
                        <div class="dropdown ms-auto">
                          <a class="dropdown-toggle dropdown-toggle-nocaret" href="#" data-bs-toggle="dropdown"><i class='bx bx-dots-horizontal-rounded font-22 text-option'></i>
                          </a>
                          <ul class="dropdown-menu">
                            <li><a class="dropdown-item" href="javascript:;">Action</a>
                            </li>
                            <li><a class="dropdown-item" href="javascript:;">Another action</a>
                            </li>
                            <li>
                              <hr class="dropdown-divider">
                            </li>
                            <li><a class="dropdown-item" href="javascript:;">Something else here</a>
                            </li>
                          </ul>
                        </div>
                      </div>
                    </div>
                    <div class="card-body">
                      <div class="chart-container-1 mt-3">
                        <canvas id="chart4"></canvas>
                        </div>
                    </div>
                    <ul class="list-group list-group-flush">
                      <li class="list-group-item d-flex bg-transparent justify-content-between align-items-center border-top">Completed <span class="badge bg-gradient-quepal rounded-pill">25</span>
                      </li>
                      <li class="list-group-item d-flex bg-transparent justify-content-between align-items-center">Pending <span class="badge bg-gradient-ibiza rounded-pill">10</span>
                      </li>
                      <li class="list-group-item d-flex bg-transparent justify-content-between align-items-center">Process <span class="badge bg-gradient-deepblue rounded-pill">65</span>
                      </li>
                    </ul>
                  </div>
                  </div>
                  <div class="col d-flex">
                  <div class="card radius-10 w-100">
                     <div class="card-header bg-transparent">
                      <div class="d-flex align-items-center">
                        <div>
                          <h6 class="mb-0">Top Selling Categories</h6>
                        </div>
                        <div class="dropdown ms-auto">
                          <a class="dropdown-toggle dropdown-toggle-nocaret" href="#" data-bs-toggle="dropdown"><i class='bx bx-dots-horizontal-rounded font-22 text-option'></i>
                          </a>
                          <ul class="dropdown-menu">
                            <li><a class="dropdown-item" href="javascript:;">Action</a>
                            </li>
                            <li><a class="dropdown-item" href="javascript:;">Another action</a>
                            </li>
                            <li>
                              <hr class="dropdown-divider">
                            </li>
                            <li><a class="dropdown-item" href="javascript:;">Something else here</a>
                            </li>
                          </ul>
                        </div>
                       </div>
                     </div>
                    <div class="card-body">
                       <div class="chart-container-0">
                       <canvas id="chart5"></canvas>
                       </div>
                    </div>
                    <div class="row row-group border-top g-0">
                      <div class="col">
                        <div class="p-3 text-center">
                          <h4 class="mb-0 text-danger">$45,216</h4>
                          <p class="mb-0">Clothing</p>
                        </div>
                      </div>
                      <div class="col">
                        <div class="p-3 text-center">
                          <h4 class="mb-0 text-success">$68,154</h4>
                          <p class="mb-0">Electronic</p>
                        </div>
                       </div>
                    </div><!--end row-->
                  </div>
                  </div>
               </div><!--end row-->
      
          </div>
        </div>
        <!--end page wrapper -->
        <!--start overlay-->
         <div class="overlay toggle-icon"></div>
        <!--end overlay-->
        <!--Start Back To Top Button-->
          <a href="javaScript:;" class="back-to-top"><i class='bx bxs-up-arrow-alt'></i></a>
        <!--End Back To Top Button-->
        <footer class="page-footer">
          <p class="mb-0">2024. Jassa reserved.</p>
        </footer>
      </div>
      <!--end wrapper-->
      
      
      <!-- search modal -->
        <div class="modal" id="SearchModal" tabindex="-1">
        <div class="modal-dialog modal-dialog-centered modal-dialog-scrollable modal-fullscreen-md-down">
          <div class="modal-content">
          <div class="modal-header gap-2">
            <div class="position-relative popup-search w-100">
            <input class="form-control form-control-lg ps-5 border border-3 border-primary" type="search" placeholder="Search">
            <span class="position-absolute top-50 search-show ms-3 translate-middle-y start-0 top-50 fs-4"><i class='bx bx-search'></i></span>
            </div>
            <button type="button" class="btn-close d-md-none" data-bs-dismiss="modal" aria-label="Close"></button>
          </div>
          <div class="modal-body">
            <div class="search-list">
               <p class="mb-1">Html Templates</p>
               <div class="list-group">
                <a href="javascript:;" class="list-group-item list-group-item-action active align-items-center d-flex gap-2 py-1"><i class='bx bxl-angular fs-4'></i>Best Html Templates</a>
                <a href="javascript:;" class="list-group-item list-group-item-action align-items-center d-flex gap-2 py-1"><i class='bx bxl-vuejs fs-4'></i>Html5 Templates</a>
                <a href="javascript:;" class="list-group-item list-group-item-action align-items-center d-flex gap-2 py-1"><i class='bx bxl-magento fs-4'></i>Responsive Html5 Templates</a>
                <a href="javascript:;" class="list-group-item list-group-item-action align-items-center d-flex gap-2 py-1"><i class='bx bxl-shopify fs-4'></i>eCommerce Html Templates</a>
               </div>
               <p class="mb-1 mt-3">Web Designe Company</p>
               <div class="list-group">
                <a href="javascript:;" class="list-group-item list-group-item-action align-items-center d-flex gap-2 py-1"><i class='bx bxl-windows fs-4'></i>Best Html Templates</a>
                <a href="javascript:;" class="list-group-item list-group-item-action align-items-center d-flex gap-2 py-1"><i class='bx bxl-dropbox fs-4' ></i>Html5 Templates</a>
                <a href="javascript:;" class="list-group-item list-group-item-action align-items-center d-flex gap-2 py-1"><i class='bx bxl-opera fs-4'></i>Responsive Html5 Templates</a>
                <a href="javascript:;" class="list-group-item list-group-item-action align-items-center d-flex gap-2 py-1"><i class='bx bxl-wordpress fs-4'></i>eCommerce Html Templates</a>
               </div>
               <p class="mb-1 mt-3">Software Development</p>
               <div class="list-group">
                <a href="javascript:;" class="list-group-item list-group-item-action align-items-center d-flex gap-2 py-1"><i class='bx bxl-mailchimp fs-4'></i>Best Html Templates</a>
                <a href="javascript:;" class="list-group-item list-group-item-action align-items-center d-flex gap-2 py-1"><i class='bx bxl-zoom fs-4'></i>Html5 Templates</a>
                <a href="javascript:;" class="list-group-item list-group-item-action align-items-center d-flex gap-2 py-1"><i class='bx bxl-sass fs-4'></i>Responsive Html5 Templates</a>
                <a href="javascript:;" class="list-group-item list-group-item-action align-items-center d-flex gap-2 py-1"><i class='bx bxl-vk fs-4'></i>eCommerce Html Templates</a>
               </div>
               <p class="mb-1 mt-3">Online Shoping Portals</p>
               <div class="list-group">
                <a href="javascript:;" class="list-group-item list-group-item-action align-items-center d-flex gap-2 py-1"><i class='bx bxl-slack fs-4'></i>Best Html Templates</a>
                <a href="javascript:;" class="list-group-item list-group-item-action align-items-center d-flex gap-2 py-1"><i class='bx bxl-skype fs-4'></i>Html5 Templates</a>
                <a href="javascript:;" class="list-group-item list-group-item-action align-items-center d-flex gap-2 py-1"><i class='bx bxl-twitter fs-4'></i>Responsive Html5 Templates</a>
                <a href="javascript:;" class="list-group-item list-group-item-action align-items-center d-flex gap-2 py-1"><i class='bx bxl-vimeo fs-4'></i>eCommerce Html Templates</a>
               </div>
            </div>
          </div>
          </div>
        </div>
        </div>
        <!-- end search modal -->
      
      
      <!--start switcher-->
      <div class="switcher-wrapper">
        <div class="switcher-btn"> <i class='bx bx-cog bx-spin'></i>
        </div>
        <div class="switcher-body">
          <div class="d-flex align-items-center">
            <h5 class="mb-0 text-uppercase">Theme Customizer</h5>
            <button type="button" class="btn-close ms-auto close-switcher" aria-label="Close"></button>
          </div>
          <hr/>
          <h6 class="mb-0">Theme Styles</h6>
          <hr/>
          <div class="d-flex align-items-center justify-content-between">
            <div class="form-check">
              <input class="form-check-input" type="radio" name="flexRadioDefault" id="lightmode" checked>
              <label class="form-check-label" for="lightmode">Light</label>
            </div>
            <div class="form-check">
              <input class="form-check-input" type="radio" name="flexRadioDefault" id="darkmode">
              <label class="form-check-label" for="darkmode">Dark</label>
            </div>
            <div class="form-check">
              <input class="form-check-input" type="radio" name="flexRadioDefault" id="semidark">
              <label class="form-check-label" for="semidark">Semi Dark</label>
            </div>
          </div>
          <hr/>
          <div class="form-check">
            <input class="form-check-input" type="radio" id="minimaltheme" name="flexRadioDefault">
            <label class="form-check-label" for="minimaltheme">Minimal Theme</label>
          </div>
          <hr/>
          <h6 class="mb-0">Header Colors</h6>
          <hr/>
          <div class="header-colors-indigators">
            <div class="row row-cols-auto g-3">
              <div class="col">
                <div class="indigator headercolor1" id="headercolor1"></div>
              </div>
              <div class="col">
                <div class="indigator headercolor2" id="headercolor2"></div>
              </div>
              <div class="col">
                <div class="indigator headercolor3" id="headercolor3"></div>
              </div>
              <div class="col">
                <div class="indigator headercolor4" id="headercolor4"></div>
              </div>
              <div class="col">
                <div class="indigator headercolor5" id="headercolor5"></div>
              </div>
              <div class="col">
                <div class="indigator headercolor6" id="headercolor6"></div>
              </div>
              <div class="col">
                <div class="indigator headercolor7" id="headercolor7"></div>
              </div>
              <div class="col">
                <div class="indigator headercolor8" id="headercolor8"></div>
              </div>
            </div>
          </div>
          <hr/>
          <h6 class="mb-0">Sidebar Colors</h6>
          <hr/>
          <div class="header-colors-indigators">
            <div class="row row-cols-auto g-3">
              <div class="col">
                <div class="indigator sidebarcolor1" id="sidebarcolor1"></div>
              </div>
              <div class="col">
                <div class="indigator sidebarcolor2" id="sidebarcolor2"></div>
              </div>
              <div class="col">
                <div class="indigator sidebarcolor3" id="sidebarcolor3"></div>
              </div>
              <div class="col">
                <div class="indigator sidebarcolor4" id="sidebarcolor4"></div>
              </div>
              <div class="col">
                <div class="indigator sidebarcolor5" id="sidebarcolor5"></div>
              </div>
              <div class="col">
                <div class="indigator sidebarcolor6" id="sidebarcolor6"></div>
              </div>
              <div class="col">
                <div class="indigator sidebarcolor7" id="sidebarcolor7"></div>
              </div>
              <div class="col">
                <div class="indigator sidebarcolor8" id="sidebarcolor8"></div>
              </div>
            </div>
          </div>
        </div>
      </div>

    6. Now guys we need to add below code into our scr/app/userprofile/userprofile.component.html file:

    <div class="wrapper">
      <!--sidebar wrapper -->
      <div class="sidebar-wrapper" data-simplebar="true">
        <div class="sidebar-header">
          <div>
            <img src="assets/images/logo-icon.png" class="logo-icon" alt="logo icon">
          </div>
          <div>
            <h4 class="logo-text">Rocker</h4>
          </div>
          <div class="toggle-icon ms-auto"><i class='bx bx-arrow-back'></i>
          </div>
         </div>
        <!--navigation-->
        <ul class="metismenu" id="menu">
          <li>
            <a href="javascript:;" class="has-arrow">
              <div class="parent-icon"><i class='bx bx-home-alt'></i>
              </div>
              <div class="menu-title">Dashboard</div>
            </a>
            <ul>
              <li> <a routerLink="/"><i class='bx bx-radio-circle'></i>Default</a>
              </li>
              <li> <a href="#"><i class='bx bx-radio-circle'></i>Alternate</a>
              </li>
              <li> <a href="#"><i class='bx bx-radio-circle'></i>Graphical</a>
              </li>
            </ul>
          </li>
          
          
          
          
          
          
          
          
          
          <li class="menu-label">Pages</li>
          
          <li>
            <a routerLink="/userprofile">
              <div class="parent-icon"><i class="bx bx-user-circle"></i>
              </div>
              <div class="menu-title">User Profile</div>
            </a>
          </li>
          
          
          
          
        
          
          
        </ul>
        <!--end navigation-->
      </div>
      <!--end sidebar wrapper -->
      <!--start header -->
      <header>
        <div class="topbar d-flex align-items-center">
          <nav class="navbar navbar-expand gap-3">
            <div class="mobile-toggle-menu"><i class='bx bx-menu'></i>
            </div>
    
            <div class="search-bar d-lg-block d-none" data-bs-toggle="modal" data-bs-target="#SearchModal">
              <a href="avascript:;" class="btn d-flex align-items-center"><i class='bx bx-search'></i>Search</a>
             </div>
    
    
              <div class="top-menu ms-auto">
              <ul class="navbar-nav align-items-center gap-1">
                <li class="nav-item mobile-search-icon d-flex d-lg-none" data-bs-toggle="modal" data-bs-target="#SearchModal">
                  <a class="nav-link" href="avascript:;"><i class='bx bx-search'></i>
                  </a>
                </li>
                <li class="nav-item dropdown dropdown-laungauge d-none d-sm-flex">
                  <a class="nav-link dropdown-toggle dropdown-toggle-nocaret" href="avascript:;" data-bs-toggle="dropdown"><img src="assets/images/county/02.png" width="22" alt="">
                  </a>
                  <ul class="dropdown-menu dropdown-menu-end">
                    <li><a class="dropdown-item d-flex align-items-center py-2" href="javascript:;"><img src="assets/images/county/01.png" width="20" alt=""><span class="ms-2">English</span></a>
                    </li>
                    <li><a class="dropdown-item d-flex align-items-center py-2" href="javascript:;"><img src="assets/images/county/02.png" width="20" alt=""><span class="ms-2">Catalan</span></a>
                    </li>
                    <li><a class="dropdown-item d-flex align-items-center py-2" href="javascript:;"><img src="assets/images/county/03.png" width="20" alt=""><span class="ms-2">French</span></a>
                    </li>
                    <li><a class="dropdown-item d-flex align-items-center py-2" href="javascript:;"><img src="assets/images/county/04.png" width="20" alt=""><span class="ms-2">Belize</span></a>
                    </li>
                    <li><a class="dropdown-item d-flex align-items-center py-2" href="javascript:;"><img src="assets/images/county/05.png" width="20" alt=""><span class="ms-2">Colombia</span></a>
                    </li>
                    <li><a class="dropdown-item d-flex align-items-center py-2" href="javascript:;"><img src="assets/images/county/06.png" width="20" alt=""><span class="ms-2">Spanish</span></a>
                    </li>
                    <li><a class="dropdown-item d-flex align-items-center py-2" href="javascript:;"><img src="assets/images/county/07.png" width="20" alt=""><span class="ms-2">Georgian</span></a>
                    </li>
                    <li><a class="dropdown-item d-flex align-items-center py-2" href="javascript:;"><img src="assets/images/county/08.png" width="20" alt=""><span class="ms-2">Hindi</span></a>
                    </li>
                  </ul>
                </li>
                <li class="nav-item dark-mode d-none d-sm-flex">
                  <a class="nav-link dark-mode-icon" href="javascript:;"><i class='bx bx-moon'></i>
                  </a>
                </li>
    
                <li class="nav-item dropdown dropdown-app">
                  <a class="nav-link dropdown-toggle dropdown-toggle-nocaret" data-bs-toggle="dropdown" href="javascript:;"><i class='bx bx-grid-alt'></i></a>
                  <div class="dropdown-menu dropdown-menu-end p-0">
                    <div class="app-container p-2 my-2">
                      <div class="row gx-0 gy-2 row-cols-3 justify-content-center p-2">
                       <div class="col">
                        <a href="javascript:;">
                        <div class="app-box text-center">
                          <div class="app-icon">
                            <img src="assets/images/app/slack.png" width="30" alt="">
                          </div>
                          <div class="app-name">
                            <p class="mb-0 mt-1">Slack</p>
                          </div>
                          </div>
                        </a>
                       </div>
                       <div class="col">
                        <a href="javascript:;">
                        <div class="app-box text-center">
                          <div class="app-icon">
                            <img src="assets/images/app/behance.png" width="30" alt="">
                          </div>
                          <div class="app-name">
                            <p class="mb-0 mt-1">Behance</p>
                          </div>
                          </div>
                        </a>
                       </div>
                       <div class="col">
                        <a href="javascript:;">
                        <div class="app-box text-center">
                          <div class="app-icon">
                          <img src="assets/images/app/google-drive.png" width="30" alt="">
                          </div>
                          <div class="app-name">
                            <p class="mb-0 mt-1">Dribble</p>
                          </div>
                          </div>
                        </a>
                       </div>
                       <div class="col">
                        <a href="javascript:;">
                        <div class="app-box text-center">
                          <div class="app-icon">
                            <img src="assets/images/app/outlook.png" width="30" alt="">
                          </div>
                          <div class="app-name">
                            <p class="mb-0 mt-1">Outlook</p>
                          </div>
                          </div>
                        </a>
                       </div>
                       <div class="col">
                        <a href="javascript:;">
                        <div class="app-box text-center">
                          <div class="app-icon">
                            <img src="assets/images/app/github.png" width="30" alt="">
                          </div>
                          <div class="app-name">
                            <p class="mb-0 mt-1">GitHub</p>
                          </div>
                          </div>
                        </a>
                       </div>
                       <div class="col">
                        <a href="javascript:;">
                        <div class="app-box text-center">
                          <div class="app-icon">
                            <img src="assets/images/app/stack-overflow.png" width="30" alt="">
                          </div>
                          <div class="app-name">
                            <p class="mb-0 mt-1">Stack</p>
                          </div>
                          </div>
                        </a>
                       </div>
                       <div class="col">
                        <a href="javascript:;">
                        <div class="app-box text-center">
                          <div class="app-icon">
                            <img src="assets/images/app/figma.png" width="30" alt="">
                          </div>
                          <div class="app-name">
                            <p class="mb-0 mt-1">Stack</p>
                          </div>
                          </div>
                        </a>
                       </div>
                       <div class="col">
                        <a href="javascript:;">
                        <div class="app-box text-center">
                          <div class="app-icon">
                            <img src="assets/images/app/twitter.png" width="30" alt="">
                          </div>
                          <div class="app-name">
                            <p class="mb-0 mt-1">Twitter</p>
                          </div>
                          </div>
                        </a>
                       </div>
                       <div class="col">
                        <a href="javascript:;">
                        <div class="app-box text-center">
                          <div class="app-icon">
                            <img src="assets/images/app/google-calendar.png" width="30" alt="">
                          </div>
                          <div class="app-name">
                            <p class="mb-0 mt-1">Calendar</p>
                          </div>
                          </div>
                        </a>
                       </div>
                       <div class="col">
                        <a href="javascript:;">
                        <div class="app-box text-center">
                          <div class="app-icon">
                            <img src="assets/images/app/spotify.png" width="30" alt="">
                          </div>
                          <div class="app-name">
                            <p class="mb-0 mt-1">Spotify</p>
                          </div>
                          </div>
                        </a>
                       </div>
                       <div class="col">
                        <a href="javascript:;">
                        <div class="app-box text-center">
                          <div class="app-icon">
                            <img src="assets/images/app/google-photos.png" width="30" alt="">
                          </div>
                          <div class="app-name">
                            <p class="mb-0 mt-1">Photos</p>
                          </div>
                          </div>
                        </a>
                       </div>
                       <div class="col">
                        <a href="javascript:;">
                        <div class="app-box text-center">
                          <div class="app-icon">
                            <img src="assets/images/app/pinterest.png" width="30" alt="">
                          </div>
                          <div class="app-name">
                            <p class="mb-0 mt-1">Photos</p>
                          </div>
                          </div>
                        </a>
                       </div>
                       <div class="col">
                        <a href="javascript:;">
                        <div class="app-box text-center">
                          <div class="app-icon">
                            <img src="assets/images/app/linkedin.png" width="30" alt="">
                          </div>
                          <div class="app-name">
                            <p class="mb-0 mt-1">linkedin</p>
                          </div>
                          </div>
                        </a>
                       </div>
                       <div class="col">
                        <a href="javascript:;">
                        <div class="app-box text-center">
                          <div class="app-icon">
                            <img src="assets/images/app/dribble.png" width="30" alt="">
                          </div>
                          <div class="app-name">
                            <p class="mb-0 mt-1">Dribble</p>
                          </div>
                          </div>
                        </a>
                       </div>
                       <div class="col">
                        <a href="javascript:;">
                        <div class="app-box text-center">
                          <div class="app-icon">
                            <img src="assets/images/app/youtube.png" width="30" alt="">
                          </div>
                          <div class="app-name">
                            <p class="mb-0 mt-1">YouTube</p>
                          </div>
                          </div>
                        </a>
                       </div>
                       <div class="col">
                        <a href="javascript:;">
                        <div class="app-box text-center">
                          <div class="app-icon">
                            <img src="assets/images/app/google.png" width="30" alt="">
                          </div>
                          <div class="app-name">
                            <p class="mb-0 mt-1">News</p>
                          </div>
                          </div>
                        </a>
                       </div>
                       <div class="col">
                        <a href="javascript:;">
                        <div class="app-box text-center">
                          <div class="app-icon">
                            <img src="assets/images/app/envato.png" width="30" alt="">
                          </div>
                          <div class="app-name">
                            <p class="mb-0 mt-1">Envato</p>
                          </div>
                          </div>
                        </a>
                       </div>
                       <div class="col">
                        <a href="javascript:;">
                        <div class="app-box text-center">
                          <div class="app-icon">
                            <img src="assets/images/app/safari.png" width="30" alt="">
                          </div>
                          <div class="app-name">
                            <p class="mb-0 mt-1">Safari</p>
                          </div>
                          </div>
                        </a>
                       </div>
          
                      </div><!--end row-->
          
                    </div>
                  </div>
                </li>
    
                <li class="nav-item dropdown dropdown-large">
                  <a class="nav-link dropdown-toggle dropdown-toggle-nocaret position-relative" href="#" data-bs-toggle="dropdown"><span class="alert-count">7</span>
                    <i class='bx bx-bell'></i>
                  </a>
                  <div class="dropdown-menu dropdown-menu-end">
                    <a href="javascript:;">
                      <div class="msg-header">
                        <p class="msg-header-title">Notifications</p>
                        <p class="msg-header-badge">8 New</p>
                      </div>
                    </a>
                    <div class="header-notifications-list">
                      <a class="dropdown-item" href="javascript:;">
                        <div class="d-flex align-items-center">
                          <div class="user-online">
                            <img src="assets/images/avatars/avatar-1.png" class="msg-avatar" alt="user avatar">
                          </div>
                          <div class="flex-grow-1">
                            <h6 class="msg-name">Daisy Anderson<span class="msg-time float-end">5 sec
                          ago</span></h6>
                            <p class="msg-info">The standard chunk of lorem</p>
                          </div>
                        </div>
                      </a>
                      <a class="dropdown-item" href="javascript:;">
                        <div class="d-flex align-items-center">
                          <div class="notify bg-light-danger text-danger">dc
                          </div>
                          <div class="flex-grow-1">
                            <h6 class="msg-name">New Orders <span class="msg-time float-end">2 min
                          ago</span></h6>
                            <p class="msg-info">You have recived new orders</p>
                          </div>
                        </div>
                      </a>
                      <a class="dropdown-item" href="javascript:;">
                        <div class="d-flex align-items-center">
                          <div class="user-online">
                            <img src="assets/images/avatars/avatar-2.png" class="msg-avatar" alt="user avatar">
                          </div>
                          <div class="flex-grow-1">
                            <h6 class="msg-name">Althea Cabardo <span class="msg-time float-end">14
                          sec ago</span></h6>
                            <p class="msg-info">Many desktop publishing packages</p>
                          </div>
                        </div>
                      </a>
                      <a class="dropdown-item" href="javascript:;">
                        <div class="d-flex align-items-center">
                          <div class="notify bg-light-success text-success">
                            <img src="assets/images/app/outlook.png" width="25" alt="user avatar">
                          </div>
                          <div class="flex-grow-1">
                            <h6 class="msg-name">Account Created<span class="msg-time float-end">28 min
                          ago</span></h6>
                            <p class="msg-info">Successfully created new email</p>
                          </div>
                        </div>
                      </a>
                      <a class="dropdown-item" href="javascript:;">
                        <div class="d-flex align-items-center">
                          <div class="notify bg-light-info text-info">Ss
                          </div>
                          <div class="flex-grow-1">
                            <h6 class="msg-name">New Product Approved <span
                          class="msg-time float-end">2 hrs ago</span></h6>
                            <p class="msg-info">Your new product has approved</p>
                          </div>
                        </div>
                      </a>
                      <a class="dropdown-item" href="javascript:;">
                        <div class="d-flex align-items-center">
                          <div class="user-online">
                            <img src="assets/images/avatars/avatar-4.png" class="msg-avatar" alt="user avatar">
                          </div>
                          <div class="flex-grow-1">
                            <h6 class="msg-name">Katherine Pechon <span class="msg-time float-end">15
                          min ago</span></h6>
                            <p class="msg-info">Making this the first true generator</p>
                          </div>
                        </div>
                      </a>
                      <a class="dropdown-item" href="javascript:;">
                        <div class="d-flex align-items-center">
                          <div class="notify bg-light-success text-success"><i class='bx bx-check-square'></i>
                          </div>
                          <div class="flex-grow-1">
                            <h6 class="msg-name">Your item is shipped <span class="msg-time float-end">5 hrs
                          ago</span></h6>
                            <p class="msg-info">Successfully shipped your item</p>
                          </div>
                        </div>
                      </a>
                      <a class="dropdown-item" href="javascript:;">
                        <div class="d-flex align-items-center">
                          <div class="notify bg-light-primary">
                            <img src="assets/images/app/github.png" width="25" alt="user avatar">
                          </div>
                          <div class="flex-grow-1">
                            <h6 class="msg-name">New 24 authors<span class="msg-time float-end">1 day
                          ago</span></h6>
                            <p class="msg-info">24 new authors joined last week</p>
                          </div>
                        </div>
                      </a>
                      <a class="dropdown-item" href="javascript:;">
                        <div class="d-flex align-items-center">
                          <div class="user-online">
                            <img src="assets/images/avatars/avatar-8.png" class="msg-avatar" alt="user avatar">
                          </div>
                          <div class="flex-grow-1">
                            <h6 class="msg-name">Peter Costanzo <span class="msg-time float-end">6 hrs
                          ago</span></h6>
                            <p class="msg-info">It was popularised in the 1960s</p>
                          </div>
                        </div>
                      </a>
                    </div>
                    <a href="javascript:;">
                      <div class="text-center msg-footer">
                        <button class="btn btn-primary w-100">View All Notifications</button>
                      </div>
                    </a>
                  </div>
                </li>
                <li class="nav-item dropdown dropdown-large">
                  <a class="nav-link dropdown-toggle dropdown-toggle-nocaret position-relative" href="#" role="button" data-bs-toggle="dropdown" aria-expanded="false"> <span class="alert-count">8</span>
                    <i class='bx bx-shopping-bag'></i>
                  </a>
                  <div class="dropdown-menu dropdown-menu-end">
                    <a href="javascript:;">
                      <div class="msg-header">
                        <p class="msg-header-title">My Cart</p>
                        <p class="msg-header-badge">10 Items</p>
                      </div>
                    </a>
                    <div class="header-message-list">
                      <a class="dropdown-item" href="javascript:;">
                        <div class="d-flex align-items-center gap-3">
                          <div class="position-relative">
                            <div class="cart-product rounded-circle bg-light">
                              <img src="assets/images/products/11.png" class="" alt="product image">
                            </div>
                          </div>
                          <div class="flex-grow-1">
                            <h6 class="cart-product-title mb-0">Men White T-Shirt</h6>
                            <p class="cart-product-price mb-0">1 X $29.00</p>
                          </div>
                          <div class="">
                            <p class="cart-price mb-0">$250</p>
                          </div>
                          <div class="cart-product-cancel"><i class="bx bx-x"></i>
                          </div>
                        </div>
                      </a>
                      <a class="dropdown-item" href="javascript:;">
                        <div class="d-flex align-items-center gap-3">
                          <div class="position-relative">
                            <div class="cart-product rounded-circle bg-light">
                              <img src="assets/images/products/02.png" class="" alt="product image">
                            </div>
                          </div>
                          <div class="flex-grow-1">
                            <h6 class="cart-product-title mb-0">Men White T-Shirt</h6>
                            <p class="cart-product-price mb-0">1 X $29.00</p>
                          </div>
                          <div class="">
                            <p class="cart-price mb-0">$250</p>
                          </div>
                          <div class="cart-product-cancel"><i class="bx bx-x"></i>
                          </div>
                        </div>
                      </a>
                      <a class="dropdown-item" href="javascript:;">
                        <div class="d-flex align-items-center gap-3">
                          <div class="position-relative">
                            <div class="cart-product rounded-circle bg-light">
                              <img src="assets/images/products/03.png" class="" alt="product image">
                            </div>
                          </div>
                          <div class="flex-grow-1">
                            <h6 class="cart-product-title mb-0">Men White T-Shirt</h6>
                            <p class="cart-product-price mb-0">1 X $29.00</p>
                          </div>
                          <div class="">
                            <p class="cart-price mb-0">$250</p>
                          </div>
                          <div class="cart-product-cancel"><i class="bx bx-x"></i>
                          </div>
                        </div>
                      </a>
                      <a class="dropdown-item" href="javascript:;">
                        <div class="d-flex align-items-center gap-3">
                          <div class="position-relative">
                            <div class="cart-product rounded-circle bg-light">
                              <img src="assets/images/products/04.png" class="" alt="product image">
                            </div>
                          </div>
                          <div class="flex-grow-1">
                            <h6 class="cart-product-title mb-0">Men White T-Shirt</h6>
                            <p class="cart-product-price mb-0">1 X $29.00</p>
                          </div>
                          <div class="">
                            <p class="cart-price mb-0">$250</p>
                          </div>
                          <div class="cart-product-cancel"><i class="bx bx-x"></i>
                          </div>
                        </div>
                      </a>
                      <a class="dropdown-item" href="javascript:;">
                        <div class="d-flex align-items-center gap-3">
                          <div class="position-relative">
                            <div class="cart-product rounded-circle bg-light">
                              <img src="assets/images/products/05.png" class="" alt="product image">
                            </div>
                          </div>
                          <div class="flex-grow-1">
                            <h6 class="cart-product-title mb-0">Men White T-Shirt</h6>
                            <p class="cart-product-price mb-0">1 X $29.00</p>
                          </div>
                          <div class="">
                            <p class="cart-price mb-0">$250</p>
                          </div>
                          <div class="cart-product-cancel"><i class="bx bx-x"></i>
                          </div>
                        </div>
                      </a>
                      <a class="dropdown-item" href="javascript:;">
                        <div class="d-flex align-items-center gap-3">
                          <div class="position-relative">
                            <div class="cart-product rounded-circle bg-light">
                              <img src="assets/images/products/06.png" class="" alt="product image">
                            </div>
                          </div>
                          <div class="flex-grow-1">
                            <h6 class="cart-product-title mb-0">Men White T-Shirt</h6>
                            <p class="cart-product-price mb-0">1 X $29.00</p>
                          </div>
                          <div class="">
                            <p class="cart-price mb-0">$250</p>
                          </div>
                          <div class="cart-product-cancel"><i class="bx bx-x"></i>
                          </div>
                        </div>
                      </a>
                      <a class="dropdown-item" href="javascript:;">
                        <div class="d-flex align-items-center gap-3">
                          <div class="position-relative">
                            <div class="cart-product rounded-circle bg-light">
                              <img src="assets/images/products/07.png" class="" alt="product image">
                            </div>
                          </div>
                          <div class="flex-grow-1">
                            <h6 class="cart-product-title mb-0">Men White T-Shirt</h6>
                            <p class="cart-product-price mb-0">1 X $29.00</p>
                          </div>
                          <div class="">
                            <p class="cart-price mb-0">$250</p>
                          </div>
                          <div class="cart-product-cancel"><i class="bx bx-x"></i>
                          </div>
                        </div>
                      </a>
                      <a class="dropdown-item" href="javascript:;">
                        <div class="d-flex align-items-center gap-3">
                          <div class="position-relative">
                            <div class="cart-product rounded-circle bg-light">
                              <img src="assets/images/products/08.png" class="" alt="product image">
                            </div>
                          </div>
                          <div class="flex-grow-1">
                            <h6 class="cart-product-title mb-0">Men White T-Shirt</h6>
                            <p class="cart-product-price mb-0">1 X $29.00</p>
                          </div>
                          <div class="">
                            <p class="cart-price mb-0">$250</p>
                          </div>
                          <div class="cart-product-cancel"><i class="bx bx-x"></i>
                          </div>
                        </div>
                      </a>
                      <a class="dropdown-item" href="javascript:;">
                        <div class="d-flex align-items-center gap-3">
                          <div class="position-relative">
                            <div class="cart-product rounded-circle bg-light">
                              <img src="assets/images/products/09.png" class="" alt="product image">
                            </div>
                          </div>
                          <div class="flex-grow-1">
                            <h6 class="cart-product-title mb-0">Men White T-Shirt</h6>
                            <p class="cart-product-price mb-0">1 X $29.00</p>
                          </div>
                          <div class="">
                            <p class="cart-price mb-0">$250</p>
                          </div>
                          <div class="cart-product-cancel"><i class="bx bx-x"></i>
                          </div>
                        </div>
                      </a>
                    </div>
                    <a href="javascript:;">
                      <div class="text-center msg-footer">
                        <div class="d-flex align-items-center justify-content-between mb-3">
                          <h5 class="mb-0">Total</h5>
                          <h5 class="mb-0 ms-auto">$489.00</h5>
                        </div>
                        <button class="btn btn-primary w-100">Checkout</button>
                      </div>
                    </a>
                  </div>
                </li>
              </ul>
            </div>
            <div class="user-box dropdown px-3">
              <a class="d-flex align-items-center nav-link dropdown-toggle gap-3 dropdown-toggle-nocaret" href="#" role="button" data-bs-toggle="dropdown" aria-expanded="false">
                <img src="assets/images/avatars/avatar-2.png" class="user-img" alt="user avatar">
                <div class="user-info">
                  <p class="user-name mb-0">Jassa Rich</p>
                  <p class="designattion mb-0">Web Designer</p>
                </div>
              </a>
              <ul class="dropdown-menu dropdown-menu-end">
                <li><a class="dropdown-item d-flex align-items-center" href="javascript:;"><i class="bx bx-user fs-5"></i><span>Profile</span></a>
                </li>
                <li><a class="dropdown-item d-flex align-items-center" href="javascript:;"><i class="bx bx-cog fs-5"></i><span>Settings</span></a>
                </li>
                <li><a class="dropdown-item d-flex align-items-center" href="javascript:;"><i class="bx bx-home-circle fs-5"></i><span>Dashboard</span></a>
                </li>
                <li><a class="dropdown-item d-flex align-items-center" href="javascript:;"><i class="bx bx-dollar-circle fs-5"></i><span>Earnings</span></a>
                </li>
                <li><a class="dropdown-item d-flex align-items-center" href="javascript:;"><i class="bx bx-download fs-5"></i><span>Downloads</span></a>
                </li>
                <li>
                  <div class="dropdown-divider mb-0"></div>
                </li>
                <li><a class="dropdown-item d-flex align-items-center" href="javascript:;"><i class="bx bx-log-out-circle"></i><span>Logout</span></a>
                </li>
              </ul>
            </div>
          </nav>
        </div>
      </header>
      <!--end header -->
      <!--start page wrapper -->
      <div class="page-wrapper">
        <div class="page-content">
          <!--breadcrumb-->
          <div class="page-breadcrumb d-none d-sm-flex align-items-center mb-3">
            <div class="breadcrumb-title pe-3">User Profile</div>
            <div class="ps-3">
              <nav aria-label="breadcrumb">
                <ol class="breadcrumb mb-0 p-0">
                  <li class="breadcrumb-item"><a href="javascript:;"><i class="bx bx-home-alt"></i></a>
                  </li>
                  <li class="breadcrumb-item active" aria-current="page">User Profilep</li>
                </ol>
              </nav>
            </div>
            <div class="ms-auto">
              <div class="btn-group">
                <button type="button" class="btn btn-primary">Settings</button>
                <button type="button" class="btn btn-primary split-bg-primary dropdown-toggle dropdown-toggle-split" data-bs-toggle="dropdown">	<span class="visually-hidden">Toggle Dropdown</span>
                </button>
                <div class="dropdown-menu dropdown-menu-right dropdown-menu-lg-end">	<a class="dropdown-item" href="javascript:;">Action</a>
                  <a class="dropdown-item" href="javascript:;">Another action</a>
                  <a class="dropdown-item" href="javascript:;">Something else here</a>
                  <div class="dropdown-divider"></div>	<a class="dropdown-item" href="javascript:;">Separated link</a>
                </div>
              </div>
            </div>
          </div>
          <!--end breadcrumb-->
          <div class="container">
            <div class="main-body">
              <div class="row">
                <div class="col-lg-4">
                  <div class="card">
                    <div class="card-body">
                      <div class="d-flex flex-column align-items-center text-center">
                        <img src="assets/images/avatars/avatar-2.png" alt="Admin" class="rounded-circle p-1 bg-primary" width="110">
                        <div class="mt-3">
                          <h4>John Doe</h4>
                          <p class="text-secondary mb-1">Full Stack Developer</p>
                          <p class="text-muted font-size-sm">LDH, PNB, IND</p>
                          <button class="btn btn-primary">Follow</button>
                          <button class="btn btn-outline-primary">Message</button>
                        </div>
                      </div>
                      <hr class="my-4" />
                      <ul class="list-group list-group-flush">
                        
                        <li class="list-group-item d-flex justify-content-between align-items-center flex-wrap">
                          <h6 class="mb-0"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-github me-2 icon-inline"><path d="M9 19c-5 1.5-5-2.5-7-3m14 6v-3.87a3.37 3.37 0 0 0-.94-2.61c3.14-.35 6.44-1.54 6.44-7A5.44 5.44 0 0 0 20 4.77 5.07 5.07 0 0 0 19.91 1S18.73.65 16 2.48a13.38 13.38 0 0 0-7 0C6.27.65 5.09 1 5.09 1A5.07 5.07 0 0 0 5 4.77a5.44 5.44 0 0 0-1.5 3.78c0 5.42 3.3 6.61 6.44 7A3.37 3.37 0 0 0 9 18.13V22"></path></svg>Github</h6>
                          <span class="text-secondary">#</span>
                        </li>
                        <li class="list-group-item d-flex justify-content-between align-items-center flex-wrap">
                          <h6 class="mb-0"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-twitter me-2 icon-inline text-info"><path d="M23 3a10.9 10.9 0 0 1-3.14 1.53 4.48 4.48 0 0 0-7.86 3v1A10.66 10.66 0 0 1 3 4s-4 9 5 13a11.64 11.64 0 0 1-7 2c9 5 20 0 20-11.5a4.5 4.5 0 0 0-.08-.83A7.72 7.72 0 0 0 23 3z"></path></svg>Twitter</h6>
                          <span class="text-secondary">#</span>
                        </li>
                        <li class="list-group-item d-flex justify-content-between align-items-center flex-wrap">
                          <h6 class="mb-0"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-instagram me-2 icon-inline text-danger"><rect x="2" y="2" width="20" height="20" rx="5" ry="5"></rect><path d="M16 11.37A4 4 0 1 1 12.63 8 4 4 0 0 1 16 11.37z"></path><line x1="17.5" y1="6.5" x2="17.51" y2="6.5"></line></svg>Instagram</h6>
                          <span class="text-secondary">#</span>
                        </li>
                        <li class="list-group-item d-flex justify-content-between align-items-center flex-wrap">
                          <h6 class="mb-0"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-facebook me-2 icon-inline text-primary"><path d="M18 2h-3a5 5 0 0 0-5 5v3H7v4h3v8h4v-8h3l1-4h-4V7a1 1 0 0 1 1-1h3z"></path></svg>Facebook</h6>
                          <span class="text-secondary">#</span>
                        </li>
                      </ul>
                    </div>
                  </div>
                </div>
                <div class="col-lg-8">
                  <div class="card">
                    <div class="card-body">
                      <div class="row mb-3">
                        <div class="col-sm-3">
                          <h6 class="mb-0">Full Name</h6>
                        </div>
                        <div class="col-sm-9 text-secondary">
                          <input type="text" class="form-control" value="John Doe" />
                        </div>
                      </div>
                      <div class="row mb-3">
                        <div class="col-sm-3">
                          <h6 class="mb-0">Email</h6>
                        </div>
                        <div class="col-sm-9 text-secondary">
                          <input type="text" class="form-control" value="john@example.com" />
                        </div>
                      </div>
                      <div class="row mb-3">
                        <div class="col-sm-3">
                          <h6 class="mb-0">Phone</h6>
                        </div>
                        <div class="col-sm-9 text-secondary">
                          <input type="text" class="form-control" value="(000) 000-0000" />
                        </div>
                      </div>
                      <div class="row mb-3">
                        <div class="col-sm-3">
                          <h6 class="mb-0">Mobile</h6>
                        </div>
                        <div class="col-sm-9 text-secondary">
                          <input type="text" class="form-control" value="(000) 000-0000" />
                        </div>
                      </div>
                      <div class="row mb-3">
                        <div class="col-sm-3">
                          <h6 class="mb-0">Address</h6>
                        </div>
                        <div class="col-sm-9 text-secondary">
                          <input type="text" class="form-control" value="LDH, PB, IND" />
                        </div>
                      </div>
                      <div class="row">
                        <div class="col-sm-3"></div>
                        <div class="col-sm-9 text-secondary">
                          <input type="button" class="btn btn-primary px-4" value="Save Changes" />
                        </div>
                      </div>
                    </div>
                  </div>
                  <div class="row">
                    <div class="col-sm-12">
                      <div class="card">
                        <div class="card-body">
                          <h5 class="d-flex align-items-center mb-3">Project Status</h5>
                          <p>Web Design</p>
                          <div class="progress mb-3" style="height: 5px">
                            <div class="progress-bar bg-primary" role="progressbar" style="width: 80%" aria-valuenow="80" aria-valuemin="0" aria-valuemax="100"></div>
                          </div>
                          <p>Website Markup</p>
                          <div class="progress mb-3" style="height: 5px">
                            <div class="progress-bar bg-danger" role="progressbar" style="width: 72%" aria-valuenow="72" aria-valuemin="0" aria-valuemax="100"></div>
                          </div>
                          <p>One Page</p>
                          <div class="progress mb-3" style="height: 5px">
                            <div class="progress-bar bg-success" role="progressbar" style="width: 89%" aria-valuenow="89" aria-valuemin="0" aria-valuemax="100"></div>
                          </div>
                          <p>Mobile Template</p>
                          <div class="progress mb-3" style="height: 5px">
                            <div class="progress-bar bg-warning" role="progressbar" style="width: 55%" aria-valuenow="55" aria-valuemin="0" aria-valuemax="100"></div>
                          </div>
                          <p>Backend API</p>
                          <div class="progress" style="height: 5px">
                            <div class="progress-bar bg-info" role="progressbar" style="width: 66%" aria-valuenow="66" aria-valuemin="0" aria-valuemax="100"></div>
                          </div>
                        </div>
                      </div>
                    </div>
                  </div>
                </div>
              </div>
            </div>
          </div>
        </div>
      </div>
      <!--end page wrapper -->
      <!--start overlay-->
      <div class="overlay toggle-icon"></div>
      <!--end overlay-->
      <!--Start Back To Top Button--> <a href="javaScript:;" class="back-to-top"><i class='bx bxs-up-arrow-alt'></i></a>
      <!--End Back To Top Button-->
      <footer class="page-footer">
        <p class="mb-0">Copyright © 2024. All right reserved.</p>
      </footer>
    </div>
    <!--end wrapper-->
    
    <!-- search modal -->
      <div class="modal" id="SearchModal" tabindex="-1">
      <div class="modal-dialog modal-dialog-centered modal-dialog-scrollable modal-fullscreen-md-down">
        <div class="modal-content">
        <div class="modal-header gap-2">
          <div class="position-relative popup-search w-100">
          <input class="form-control form-control-lg ps-5 border border-3 border-primary" type="search" placeholder="Search">
          <span class="position-absolute top-50 search-show ms-3 translate-middle-y start-0 top-50 fs-4"><i class='bx bx-search'></i></span>
          </div>
          <button type="button" class="btn-close d-md-none" data-bs-dismiss="modal" aria-label="Close"></button>
        </div>
        <div class="modal-body">
          <div class="search-list">
             <p class="mb-1">Html Templates</p>
             <div class="list-group">
              <a href="javascript:;" class="list-group-item list-group-item-action active align-items-center d-flex gap-2 py-1"><i class='bx bxl-angular fs-4'></i>Best Html Templates</a>
              <a href="javascript:;" class="list-group-item list-group-item-action align-items-center d-flex gap-2 py-1"><i class='bx bxl-vuejs fs-4'></i>Html5 Templates</a>
              <a href="javascript:;" class="list-group-item list-group-item-action align-items-center d-flex gap-2 py-1"><i class='bx bxl-magento fs-4'></i>Responsive Html5 Templates</a>
              <a href="javascript:;" class="list-group-item list-group-item-action align-items-center d-flex gap-2 py-1"><i class='bx bxl-shopify fs-4'></i>eCommerce Html Templates</a>
             </div>
             <p class="mb-1 mt-3">Web Designe Company</p>
             <div class="list-group">
              <a href="javascript:;" class="list-group-item list-group-item-action align-items-center d-flex gap-2 py-1"><i class='bx bxl-windows fs-4'></i>Best Html Templates</a>
              <a href="javascript:;" class="list-group-item list-group-item-action align-items-center d-flex gap-2 py-1"><i class='bx bxl-dropbox fs-4' ></i>Html5 Templates</a>
              <a href="javascript:;" class="list-group-item list-group-item-action align-items-center d-flex gap-2 py-1"><i class='bx bxl-opera fs-4'></i>Responsive Html5 Templates</a>
              <a href="javascript:;" class="list-group-item list-group-item-action align-items-center d-flex gap-2 py-1"><i class='bx bxl-wordpress fs-4'></i>eCommerce Html Templates</a>
             </div>
             <p class="mb-1 mt-3">Software Development</p>
             <div class="list-group">
              <a href="javascript:;" class="list-group-item list-group-item-action align-items-center d-flex gap-2 py-1"><i class='bx bxl-mailchimp fs-4'></i>Best Html Templates</a>
              <a href="javascript:;" class="list-group-item list-group-item-action align-items-center d-flex gap-2 py-1"><i class='bx bxl-zoom fs-4'></i>Html5 Templates</a>
              <a href="javascript:;" class="list-group-item list-group-item-action align-items-center d-flex gap-2 py-1"><i class='bx bxl-sass fs-4'></i>Responsive Html5 Templates</a>
              <a href="javascript:;" class="list-group-item list-group-item-action align-items-center d-flex gap-2 py-1"><i class='bx bxl-vk fs-4'></i>eCommerce Html Templates</a>
             </div>
             <p class="mb-1 mt-3">Online Shoping Portals</p>
             <div class="list-group">
              <a href="javascript:;" class="list-group-item list-group-item-action align-items-center d-flex gap-2 py-1"><i class='bx bxl-slack fs-4'></i>Best Html Templates</a>
              <a href="javascript:;" class="list-group-item list-group-item-action align-items-center d-flex gap-2 py-1"><i class='bx bxl-skype fs-4'></i>Html5 Templates</a>
              <a href="javascript:;" class="list-group-item list-group-item-action align-items-center d-flex gap-2 py-1"><i class='bx bxl-twitter fs-4'></i>Responsive Html5 Templates</a>
              <a href="javascript:;" class="list-group-item list-group-item-action align-items-center d-flex gap-2 py-1"><i class='bx bxl-vimeo fs-4'></i>eCommerce Html Templates</a>
             </div>
          </div>
        </div>
        </div>
      </div>
      </div>
      <!-- end search modal -->
    
    
    
    <!--start switcher-->
    <div class="switcher-wrapper">
      <div class="switcher-btn"> <i class='bx bx-cog bx-spin'></i>
      </div>
      <div class="switcher-body">
        <div class="d-flex align-items-center">
          <h5 class="mb-0 text-uppercase">Theme Customizer</h5>
          <button type="button" class="btn-close ms-auto close-switcher" aria-label="Close"></button>
        </div>
        <hr/>
        <h6 class="mb-0">Theme Styles</h6>
        <hr/>
        <div class="d-flex align-items-center justify-content-between">
          <div class="form-check">
            <input class="form-check-input" type="radio" name="flexRadioDefault" id="lightmode" checked>
            <label class="form-check-label" for="lightmode">Light</label>
          </div>
          <div class="form-check">
            <input class="form-check-input" type="radio" name="flexRadioDefault" id="darkmode">
            <label class="form-check-label" for="darkmode">Dark</label>
          </div>
          <div class="form-check">
            <input class="form-check-input" type="radio" name="flexRadioDefault" id="semidark">
            <label class="form-check-label" for="semidark">Semi Dark</label>
          </div>
        </div>
        <hr/>
        <div class="form-check">
          <input class="form-check-input" type="radio" id="minimaltheme" name="flexRadioDefault">
          <label class="form-check-label" for="minimaltheme">Minimal Theme</label>
        </div>
        <hr/>
        <h6 class="mb-0">Header Colors</h6>
        <hr/>
        <div class="header-colors-indigators">
          <div class="row row-cols-auto g-3">
            <div class="col">
              <div class="indigator headercolor1" id="headercolor1"></div>
            </div>
            <div class="col">
              <div class="indigator headercolor2" id="headercolor2"></div>
            </div>
            <div class="col">
              <div class="indigator headercolor3" id="headercolor3"></div>
            </div>
            <div class="col">
              <div class="indigator headercolor4" id="headercolor4"></div>
            </div>
            <div class="col">
              <div class="indigator headercolor5" id="headercolor5"></div>
            </div>
            <div class="col">
              <div class="indigator headercolor6" id="headercolor6"></div>
            </div>
            <div class="col">
              <div class="indigator headercolor7" id="headercolor7"></div>
            </div>
            <div class="col">
              <div class="indigator headercolor8" id="headercolor8"></div>
            </div>
          </div>
        </div>
        <hr/>
        <h6 class="mb-0">Sidebar Colors</h6>
        <hr/>
        <div class="header-colors-indigators">
          <div class="row row-cols-auto g-3">
            <div class="col">
              <div class="indigator sidebarcolor1" id="sidebarcolor1"></div>
            </div>
            <div class="col">
              <div class="indigator sidebarcolor2" id="sidebarcolor2"></div>
            </div>
            <div class="col">
              <div class="indigator sidebarcolor3" id="sidebarcolor3"></div>
            </div>
            <div class="col">
              <div class="indigator sidebarcolor4" id="sidebarcolor4"></div>
            </div>
            <div class="col">
              <div class="indigator sidebarcolor5" id="sidebarcolor5"></div>
            </div>
            <div class="col">
              <div class="indigator sidebarcolor6" id="sidebarcolor6"></div>
            </div>
            <div class="col">
              <div class="indigator sidebarcolor7" id="sidebarcolor7"></div>
            </div>
            <div class="col">
              <div class="indigator sidebarcolor8" id="sidebarcolor8"></div>
            </div>
          </div>
        </div>
      </div>
    </div>
    <!--end switcher-->

    7. Now guys we need to add below code into our scr/app/userprofile/userprofile.component.ts file:

    import { Component } from '@angular/core';
    import { RouterLink, RouterOutlet } from '@angular/router';
    @Component({
      selector: 'app-userprofile',
      standalone: true,
      imports: [RouterOutlet, RouterLink],
      templateUrl: './userprofile.component.html',
      styleUrl: './userprofile.component.css'
    })
    export class UserprofileComponent {
    
    }

    8. Now guys we need to add below into src/app/app.routes.ts to links components to routes:

    import { Routes } from '@angular/router';
    import { DashboardComponent } from './dashboard/dashboard.component';
    import { UserprofileComponent } from './userprofile/userprofile.component';
    export const routes: Routes = [
          {
            path: '', title: 'Dashboard Page', component: DashboardComponent,
          },
          {
            path: 'userprofile', title: 'Dashboard Page', component: UserprofileComponent,
          },
    ];
    

    9. Now guys we need to add below code into our project/src/index.html file for styles and scripts or we can also call this styles/scripts inside angular.json file:

    <!doctype html>
    <html lang="en">
    <head>
      <meta charset="utf-8">
      <base href="/">
      <meta name="viewport" content="width=device-width, initial-scale=1">
      <!--favicon-->
      <link rel="icon" href="assets/images/favicon-32x32.png" type="image/png"/>
      <!--plugins-->
      <link href="assets/css/jquery-jvectormap-2.0.2.css" rel="stylesheet"/>
      <link href="assets/css/simplebar.css" rel="stylesheet" />
      <link href="assets/css/perfect-scrollbar.css" rel="stylesheet" />
      <link href="assets/css/metisMenu.min.css" rel="stylesheet"/>
      <!-- loader-->
      <link href="assets/css/pace.min.css" rel="stylesheet"/>
      <script src="assets/js/pace.min.js"></script>
      <!-- Bootstrap CSS -->
      <link href="assets/css/bootstrap.min.css" rel="stylesheet">
      <link href="assets/css/bootstrap-extended.css" rel="stylesheet">
      <link href="https://fonts.googleapis.com/css2?family=Roboto:wght@400;500&display=swap" rel="stylesheet">
      <link href="assets/css/app.css" rel="stylesheet">
      <link href="assets/css/icons.css" rel="stylesheet">
      <!-- Theme Style CSS -->
      <link rel="stylesheet" href="assets/css/dark-theme.css"/>
      <link rel="stylesheet" href="assets/css/semi-dark.css"/>
      <link rel="stylesheet" href="assets/css/header-colors.css"/>
      <title>Rocker - Bootstrap 5 Admin Dashboard Template</title>
    </head>
    <body>
      <app-root></app-root>
      <!-- Bootstrap JS -->
      <script src="assets/js/bootstrap.bundle.min.js"></script>
      <!--plugins-->
      <script src="assets/js/jquery.min.js"></script>
      <script src="assets/js/simplebar.min.js"></script>
      <script src="assets/js/metisMenu.min.js"></script>
      <script src="assets/js/perfect-scrollbar.js"></script>
      <script src="assets/js/jquery-jvectormap-2.0.2.min.js"></script>
        <script src="assets/js/jquery-jvectormap-world-mill-en.js"></script>
      <script src="assets/js/chart.js"></script>
      <script src="assets/js/index.js"></script>
      <!--app JS-->
      <script src="assets/js/app.js"></script>
      <script>
        new PerfectScrollbar(".app-container")
      </script>
    </body>
    </html>
    

    10. Now guys here is the github link and from where we will get the all the assets like images, css, js and fonts:

    GitHub Link

    Friends in the end must run ng serve command into your terminal to run the angular 17 project(localhost:4200).

    Now we are done friends. If you have any kind of query, suggestion and new requirement then feel free to comment below.

    Note: Friends, In this post, I just tell the basic setup and things, you can change the code according to your requirements.

    I will appreciate that if you will tell your views for this post. Nothing matters if your views will be good or bad because with your views, I will make my next posts more good and helpful.

    Jassa

    Thanks

  • Creating a form in Angular using Angular Material

    Creating a form in Angular using Angular Material

    Creating a form in Angular using Angular Material involves several steps, including setting up your Angular project, installing Angular Material, and then building your form with various form controls. Angular Material provides a wide range of UI components that follow Material Design principles, making it easy to create beautiful, responsive, and functional forms. Below is a basic guide on how to create a simple Angular form with Angular Material.

    1. Setting Up Your Angular Project

    If you haven’t already created an Angular project, you can do so by running the following command in your terminal:

    ng new my-angular-project

    Navigate to your project directory:

    cd my-angular-project

    2. Installing Angular Material

    Install Angular Material and Angular CDK (Component Dev Kit) in your project by running:

    ng add @angular/material

    During the installation process, you can choose a prebuilt theme or set up global typography and animations.

    3. Importing Angular Material Modules

    Before using Angular Material components, you need to import the respective modules in your app module (app.module.ts). For a simple form, you might need MatInputModule for input fields and MatButtonModule for buttons. You can also import MatFormFieldModule for form fields.

    Here is how you can import these modules:

    import { BrowserAnimationsModule } from '@angular/platform-browser/animations';
    import { MatFormFieldModule } from '@angular/material/form-field';
    import { MatInputModule } from '@angular/material/input';
    import { MatButtonModule } from '@angular/material/button';
    
    @NgModule({
      declarations: [
        // other components
      ],
      imports: [
        BrowserAnimationsModule,
        MatFormFieldModule,
        MatInputModule,
        MatButtonModule,
        // other modules
      ],
      providers: [],
      bootstrap: [AppComponent]
    })
    export class AppModule { }

    4. Creating a Form

    You can use the Angular Material components to create your form. Here is a simple example using mat-form-field and mat-input for input fields:

    <form>
      <mat-form-field appearance="fill">
        <mat-label>First Name</mat-label>
        <input matInput placeholder="Enter your first name">
      </mat-form-field>
    
      <mat-form-field appearance="fill">
        <mat-label>Last Name</mat-label>
        <input matInput placeholder="Enter your last name">
      </mat-form-field>
    
      <button mat-raised-button color="primary">Submit</button>
    </form>

    5. Adding Form Control and Validation

    For handling form control and validation, you can use Angular’s ReactiveFormsModule or FormsModule. Here is how you might add form control using FormControl:

    1. Import ReactiveFormsModule in your app module (app.module.ts):
    import { ReactiveFormsModule } from '@angular/forms';
    
    @NgModule({
      imports: [
        // other modules
        ReactiveFormsModule
      ],
    })
    export class AppModule { }
    1. Update your component to use FormControl:
    import { Component } from '@angular/core';
    import { FormControl } from '@angular/forms';
    
    @Component({
      selector: 'my-app',
      templateUrl: './app.component.html',
      styleUrls: ['./app.component.css']
    })
    export class AppComponent {
      firstName = new FormControl('');
      lastName = new FormControl('');
    }

    And modify your template to bind the form controls:

    <form>
      <mat-form-field appearance="fill">
        <mat-label>First Name</mat-label>
        <input matInput placeholder="Enter your first name" [formControl]="firstName">
      </mat-form-field>
    
      <mat-form-field appearance="fill">
        <mat-label>Last Name</mat-label>
        <input matInput placeholder="Enter your last name" [formControl]="lastName">
      </mat-form-field>
    
      <button mat-raised-button color="primary">Submit</button>
    </form>

    This guide provides a foundation for creating a form with Angular Material. Depending on your requirements, Angular Material offers many other form controls and functionalities that you can explore and integrate into your forms.

  • Implementing GeoJSON on Google Maps within an Angular application

    Implementing GeoJSON on Google Maps within an Angular application

    Implementing GeoJSON on Google Maps within an Angular application involves a few steps. Firstly, you need to have Google Maps integrated into your Angular application. You can do this by using the @angular/google-maps module which provides a set of Angular components for Google Maps. After setting up Google Maps, you can then add GeoJSON data to your map.

    Here’s a basic guide to get you started:

    Step 1: Setup Angular Project

    If you haven’t already set up an Angular project, you can create one by running:

    ng new your-project-name
    cd your-project-name

    Step 2: Install @angular/google-maps

    Install the Google Maps module for Angular:

    npm install @angular/google-maps

    Step 3: Import GoogleMapsModule

    In your app.module.ts, import GoogleMapsModule:

    import { GoogleMapsModule } from '@angular/google-maps';
    
    @NgModule({
      declarations: [
        // other components
      ],
      imports: [
        // other modules
        GoogleMapsModule
      ],
      providers: [],
      bootstrap: [AppComponent]
    })
    export class AppModule { }

    Step 4: API Key Configuration

    You need a Google Maps API key to use Google Maps services. Once you have your API key, you can add it to your project’s environment files (src/environments/environment.ts and src/environments/environment.prod.ts):

    export const environment = {
      // other environment settings
      googleMapsApiKey: 'YOUR_API_KEY'
    };

    In your app.module.ts or the module where you’re using Google Maps, import environment and configure the API key:

    import { environment } from '../environments/environment';
    
    @NgModule({
      // Other module properties
      providers: [
        { provide: GOOGLE_MAPS_API_KEY, useValue: environment.googleMapsApiKey }
      ],
    })

    Step 5: Add the Map to Your Component

    In your component’s HTML, you can add the map like this:

    <google-map
      [height]="'400px'"
      [width]="'100%'"
      [center]="{lat: 40.730610, lng: -73.935242}"
      [zoom]="12">
    </google-map>

    And in your component’s TypeScript file, ensure you have the center and zoom properties defined:

    @Component({
      selector: 'app-my-map',
      templateUrl: './my-map.component.html',
      styleUrls: ['./my-map.component.css']
    })
    export class MyMapComponent {
      center: google.maps.LatLngLiteral = {lat: 40.730610, lng: -73.935242};
      zoom = 12;
    
      // Other component properties and methods
    }

    Step 6: Adding GeoJSON

    To add GeoJSON data to your map, you can use the mapReady output event of the google-map component to get a reference to the google.maps.Map object and then use the data layer to add GeoJSON:

    <google-map
      [height]="'400px'"
      [width]="'100%'"
      [center]="center"
      [zoom]="zoom"
      (mapReady)="onMapReady($event)">
    </google-map>

    And in your component’s TypeScript:

    onMapReady(map: google.maps.Map) {
      map.data.loadGeoJson('path/to/your/geojson/file.json');
    }

    Or you can add GeoJSON directly:

    onMapReady(map: google.maps.Map) {
      const geoJson = {
        "type": "FeatureCollection",
        "features": [
          {
            "type": "Feature",
            "geometry": {
              "type": "Point",
              "coordinates": [-73.935242, 40.730610]
            },
            "properties": {
              "name": "Location Name"
            }
          }
          // Add more features here
        ]
      };
    
      map.data.addGeoJson(geoJson);
    }

    Make sure to replace 'path/to/your/geojson/file.json' with the actual path to your GeoJSON file or define your GeoJSON data directly in the component as shown.

    This is a basic implementation to get you started with integrating GeoJSON data into Google Maps within an Angular application. Depending on your requirements, you may want to explore additional functionalities such as styling GeoJSON features, responding to user interactions, and dynamically modifying GeoJSON data.

  • Responsive Free Saas Based Bootstrap 5 HTML5 Angular 17 Admin Dashboard Template

    Responsive Free Saas Based Bootstrap 5 HTML5 Angular 17 Admin Dashboard Template

    Hello everyone, if you’re in search of a responsive and user-friendly admin dashboard template in Angular 17+, then you’ve come to the right place! Today this blog post I will show you Responsive Free Saas Based Bootstrap 5 HTML5 Angular 17 Admin Dashboard Template.

    Live Demo

    Key Features:

    • Built on Angular 17 + Bootstrap 5
    • CSS3 & HTML5
    • Clean & minimal design
    • Cross-browser tested & optimized
    • Full-width layouts
    • Gulp based workflow
    • Opinionated code formatter Prettier for a consistent codebase
    • Modular markup based on Cards & Utility classes
    • Interactive and functional components and pages
    • FontAwesome 5 + material icons + feather icon
    • ApexCharts
    • W3C validated HTML pages

    Angular 17 came and Bootstrap 5 also. If you are new then you must check below two links:

    Guys now here is the complete code snippet with GitHub link following assets(css, js, fonts and images):

    1. Firstly friends we need fresh angular 17 setup and for this we need to run below commands but if you already have angular 17 setup then you can avoid below commands. Secondly we should also have latest node version installed on our system:

    npm install -g @angular/cli 
    
    ng new angularadmin //Create new Angular Project
    
    cd angularadmin // Go inside the Angular Project Folder

    2. Guys now we need to run below commands to create components to our angular application:

    ng g c dashboard
    
    ng g c signin
    
    ng g c signup

    3. Now guys we need to add below code into our scr/app/app.component.html file for main output:

    <router-outlet></router-outlet>

    4. Now guys we need to add below code into our scr/app/dashboard/dashboard.component.ts file making routing working:

    import { Component } from '@angular/core';
    import { RouterLink, RouterOutlet } from '@angular/router';
    @Component({
      selector: 'app-dashboard',
      standalone: true,
      imports: [RouterOutlet, RouterLink],
      templateUrl: './dashboard.component.html',
      styleUrl: './dashboard.component.css'
    })
    export class DashboardComponent {
    
    }
    

    5. Now guys we need to add below code into our scr/app/dashboard/dashboard.component.html file:

    <div class="container-xxl position-relative bg-white d-flex p-0">
        <!-- Spinner Start -->
        <div id="spinner" class="show bg-white position-fixed translate-middle w-100 vh-100 top-50 start-50 d-flex align-items-center justify-content-center">
            <div class="spinner-border text-primary" style="width: 3rem; height: 3rem;" role="status">
                <span class="sr-only">Loading...</span>
            </div>
        </div>
        <!-- Spinner End -->
      
      
        <!-- Sidebar Start -->
        <div class="sidebar pe-4 pb-3">
            <nav class="navbar bg-light navbar-light">
                <a routerLink="/" class="navbar-brand mx-4 mb-3">
                    <h3 class="text-primary"><i class="fa fa-hashtag me-2"></i>DASHMIN</h3>
                </a>
                <div class="d-flex align-items-center ms-4 mb-4">
                    <div class="position-relative">
                        <img class="rounded-circle" src="assets/img/user.jpg" alt="" style="width: 40px; height: 40px;">
                        <div class="bg-success rounded-circle border border-2 border-white position-absolute end-0 bottom-0 p-1"></div>
                    </div>
                    <div class="ms-3">
                        <h6 class="mb-0">Jhon Doe</h6>
                        <span>Admin</span>
                    </div>
                </div>
                <div class="navbar-nav w-100">
                    <a routerLink="/" class="nav-item nav-link active"><i class="fa fa-tachometer-alt me-2"></i>Dashboard</a>
                    
                    <a routerLink="/signin" class="nav-item nav-link"><i class="fa fa-th me-2"></i>Sign In</a>
                    <a routerLink="/signup" class="nav-item nav-link"><i class="fa fa-keyboard me-2"></i>Sign Up</a>
                    <a href="https://therichpost.com/category/angular-admin-templates/" target="_blank" class="nav-item nav-link"><i class="fa fa-table me-2"></i>More Free Admins</a>
                    <a href="#" class="nav-item nav-link"><i class="fa fa-chart-bar me-2"></i>Charts</a>
                    
                </div>
            </nav>
        </div>
        <!-- Sidebar End -->
      
      
        <!-- Content Start -->
        <div class="content">
            <!-- Navbar Start -->
            <nav class="navbar navbar-expand bg-light navbar-light sticky-top px-4 py-0">
                <a href="index.html" class="navbar-brand d-flex d-lg-none me-4">
                    <h2 class="text-primary mb-0"><i class="fa fa-hashtag"></i></h2>
                </a>
                <a href="#" class="sidebar-toggler flex-shrink-0">
                    <i class="fa fa-bars"></i>
                </a>
                <form class="d-none d-md-flex ms-4">
                    <input class="form-control border-0" type="search" placeholder="Search">
                </form>
                <div class="navbar-nav align-items-center ms-auto">
                    <div class="nav-item dropdown">
                        <a href="#" class="nav-link dropdown-toggle" data-bs-toggle="dropdown">
                            <i class="fa fa-envelope me-lg-2"></i>
                            <span class="d-none d-lg-inline-flex">Message</span>
                        </a>
                        <div class="dropdown-menu dropdown-menu-end bg-light border-0 rounded-0 rounded-bottom m-0">
                            <a href="#" class="dropdown-item">
                                <div class="d-flex align-items-center">
                                    <img class="rounded-circle" src="assets/img/user.jpg" alt="" style="width: 40px; height: 40px;">
                                    <div class="ms-2">
                                        <h6 class="fw-normal mb-0">Jhon send you a message</h6>
                                        <small>15 minutes ago</small>
                                    </div>
                                </div>
                            </a>
                            <hr class="dropdown-divider">
                            <a href="#" class="dropdown-item">
                                <div class="d-flex align-items-center">
                                    <img class="rounded-circle" src="assets/img/user.jpg" alt="" style="width: 40px; height: 40px;">
                                    <div class="ms-2">
                                        <h6 class="fw-normal mb-0">Jhon send you a message</h6>
                                        <small>15 minutes ago</small>
                                    </div>
                                </div>
                            </a>
                            <hr class="dropdown-divider">
                            <a href="#" class="dropdown-item">
                                <div class="d-flex align-items-center">
                                    <img class="rounded-circle" src="assets/img/user.jpg" alt="" style="width: 40px; height: 40px;">
                                    <div class="ms-2">
                                        <h6 class="fw-normal mb-0">Jhon send you a message</h6>
                                        <small>15 minutes ago</small>
                                    </div>
                                </div>
                            </a>
                            <hr class="dropdown-divider">
                            <a href="#" class="dropdown-item text-center">See all message</a>
                        </div>
                    </div>
                    <div class="nav-item dropdown">
                        <a href="#" class="nav-link dropdown-toggle" data-bs-toggle="dropdown">
                            <i class="fa fa-bell me-lg-2"></i>
                            <span class="d-none d-lg-inline-flex">Notificatin</span>
                        </a>
                        <div class="dropdown-menu dropdown-menu-end bg-light border-0 rounded-0 rounded-bottom m-0">
                            <a href="#" class="dropdown-item">
                                <h6 class="fw-normal mb-0">Profile updated</h6>
                                <small>15 minutes ago</small>
                            </a>
                            <hr class="dropdown-divider">
                            <a href="#" class="dropdown-item">
                                <h6 class="fw-normal mb-0">New user added</h6>
                                <small>15 minutes ago</small>
                            </a>
                            <hr class="dropdown-divider">
                            <a href="#" class="dropdown-item">
                                <h6 class="fw-normal mb-0">Password changed</h6>
                                <small>15 minutes ago</small>
                            </a>
                            <hr class="dropdown-divider">
                            <a href="#" class="dropdown-item text-center">See all notifications</a>
                        </div>
                    </div>
                    <div class="nav-item dropdown">
                        <a href="#" class="nav-link dropdown-toggle" data-bs-toggle="dropdown">
                            <img class="rounded-circle me-lg-2" src="assets/img/user.jpg" alt="" style="width: 40px; height: 40px;">
                            <span class="d-none d-lg-inline-flex">John Doe</span>
                        </a>
                        <div class="dropdown-menu dropdown-menu-end bg-light border-0 rounded-0 rounded-bottom m-0">
                            <a href="#" class="dropdown-item">My Profile</a>
                            <a href="#" class="dropdown-item">Settings</a>
                            <a href="#" class="dropdown-item">Log Out</a>
                        </div>
                    </div>
                </div>
            </nav>
            <!-- Navbar End -->
      
      
            <!-- Sale & Revenue Start -->
            <div class="container-fluid pt-4 px-4">
                <div class="row g-4">
                    <div class="col-sm-6 col-xl-3">
                        <div class="bg-light rounded d-flex align-items-center justify-content-between p-4">
                            <i class="fa fa-chart-line fa-3x text-primary"></i>
                            <div class="ms-3">
                                <p class="mb-2">Today Sale</p>
                                <h6 class="mb-0">$1234</h6>
                            </div>
                        </div>
                    </div>
                    <div class="col-sm-6 col-xl-3">
                        <div class="bg-light rounded d-flex align-items-center justify-content-between p-4">
                            <i class="fa fa-chart-bar fa-3x text-primary"></i>
                            <div class="ms-3">
                                <p class="mb-2">Total Sale</p>
                                <h6 class="mb-0">$1234</h6>
                            </div>
                        </div>
                    </div>
                    <div class="col-sm-6 col-xl-3">
                        <div class="bg-light rounded d-flex align-items-center justify-content-between p-4">
                            <i class="fa fa-chart-area fa-3x text-primary"></i>
                            <div class="ms-3">
                                <p class="mb-2">Today Revenue</p>
                                <h6 class="mb-0">$1234</h6>
                            </div>
                        </div>
                    </div>
                    <div class="col-sm-6 col-xl-3">
                        <div class="bg-light rounded d-flex align-items-center justify-content-between p-4">
                            <i class="fa fa-chart-pie fa-3x text-primary"></i>
                            <div class="ms-3">
                                <p class="mb-2">Total Revenue</p>
                                <h6 class="mb-0">$1234</h6>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
            <!-- Sale & Revenue End -->
      
      
            <!-- Sales Chart Start -->
            <div class="container-fluid pt-4 px-4">
                <div class="row g-4">
                    <div class="col-sm-12 col-xl-6">
                        <div class="bg-light text-center rounded p-4">
                            <div class="d-flex align-items-center justify-content-between mb-4">
                                <h6 class="mb-0">Worldwide Sales</h6>
                                <a href="">Show All</a>
                            </div>
                            <canvas id="worldwide-sales"></canvas>
                        </div>
                    </div>
                    <div class="col-sm-12 col-xl-6">
                        <div class="bg-light text-center rounded p-4">
                            <div class="d-flex align-items-center justify-content-between mb-4">
                                <h6 class="mb-0">Salse & Revenue</h6>
                                <a href="">Show All</a>
                            </div>
                            <canvas id="salse-revenue"></canvas>
                        </div>
                    </div>
                </div>
            </div>
            <!-- Sales Chart End -->
            <!-- Recent Sales Start -->
            <div class="container-fluid pt-4 px-4">
                <div class="bg-light text-center rounded p-4">
                    <div class="d-flex align-items-center justify-content-between mb-4">
                        <h6 class="mb-0">Recent Salse</h6>
                        <a href="">Show All</a>
                    </div>
                    <div class="table-responsive">
                        <table class="table text-start align-middle table-bordered table-hover mb-0">
                            <thead>
                                <tr class="text-dark">
                                    <th scope="col"><input class="form-check-input" type="checkbox"></th>
                                    <th scope="col">Date</th>
                                    <th scope="col">Invoice</th>
                                    <th scope="col">Customer</th>
                                    <th scope="col">Amount</th>
                                    <th scope="col">Status</th>
                                    <th scope="col">Action</th>
                                </tr>
                            </thead>
                            <tbody>
                                <tr>
                                    <td><input class="form-check-input" type="checkbox"></td>
                                    <td>01 Jan 2045</td>
                                    <td>INV-0123</td>
                                    <td>Jhon Doe</td>
                                    <td>$123</td>
                                    <td>Paid</td>
                                    <td><a class="btn btn-sm btn-primary" href="">Detail</a></td>
                                </tr>
                                <tr>
                                    <td><input class="form-check-input" type="checkbox"></td>
                                    <td>01 Jan 2045</td>
                                    <td>INV-0123</td>
                                    <td>Jhon Doe</td>
                                    <td>$123</td>
                                    <td>Paid</td>
                                    <td><a class="btn btn-sm btn-primary" href="">Detail</a></td>
                                </tr>
                                <tr>
                                    <td><input class="form-check-input" type="checkbox"></td>
                                    <td>01 Jan 2045</td>
                                    <td>INV-0123</td>
                                    <td>Jhon Doe</td>
                                    <td>$123</td>
                                    <td>Paid</td>
                                    <td><a class="btn btn-sm btn-primary" href="">Detail</a></td>
                                </tr>
                                <tr>
                                    <td><input class="form-check-input" type="checkbox"></td>
                                    <td>01 Jan 2045</td>
                                    <td>INV-0123</td>
                                    <td>Jhon Doe</td>
                                    <td>$123</td>
                                    <td>Paid</td>
                                    <td><a class="btn btn-sm btn-primary" href="">Detail</a></td>
                                </tr>
                                <tr>
                                    <td><input class="form-check-input" type="checkbox"></td>
                                    <td>01 Jan 2045</td>
                                    <td>INV-0123</td>
                                    <td>Jhon Doe</td>
                                    <td>$123</td>
                                    <td>Paid</td>
                                    <td><a class="btn btn-sm btn-primary" href="">Detail</a></td>
                                </tr>
                            </tbody>
                        </table>
                    </div>
                </div>
            </div>
            <!-- Recent Sales End -->
      
      
            <!-- Widgets Start -->
            <div class="container-fluid pt-4 px-4">
                <div class="row g-4">
                    <div class="col-sm-12 col-md-6 col-xl-4">
                        <div class="h-100 bg-light rounded p-4">
                            <div class="d-flex align-items-center justify-content-between mb-2">
                                <h6 class="mb-0">Messages</h6>
                                <a href="">Show All</a>
                            </div>
                            <div class="d-flex align-items-center border-bottom py-3">
                                <img class="rounded-circle flex-shrink-0" src="assets/img/user.jpg" alt="" style="width: 40px; height: 40px;">
                                <div class="w-100 ms-3">
                                    <div class="d-flex w-100 justify-content-between">
                                        <h6 class="mb-0">Jhon Doe</h6>
                                        <small>15 minutes ago</small>
                                    </div>
                                    <span>Short message goes here...</span>
                                </div>
                            </div>
                            <div class="d-flex align-items-center border-bottom py-3">
                                <img class="rounded-circle flex-shrink-0" src="assets/img/user.jpg" alt="" style="width: 40px; height: 40px;">
                                <div class="w-100 ms-3">
                                    <div class="d-flex w-100 justify-content-between">
                                        <h6 class="mb-0">Jhon Doe</h6>
                                        <small>15 minutes ago</small>
                                    </div>
                                    <span>Short message goes here...</span>
                                </div>
                            </div>
                            <div class="d-flex align-items-center border-bottom py-3">
                                <img class="rounded-circle flex-shrink-0" src="assets/img/user.jpg" alt="" style="width: 40px; height: 40px;">
                                <div class="w-100 ms-3">
                                    <div class="d-flex w-100 justify-content-between">
                                        <h6 class="mb-0">Jhon Doe</h6>
                                        <small>15 minutes ago</small>
                                    </div>
                                    <span>Short message goes here...</span>
                                </div>
                            </div>
                            <div class="d-flex align-items-center pt-3">
                                <img class="rounded-circle flex-shrink-0" src="assets/img/user.jpg" alt="" style="width: 40px; height: 40px;">
                                <div class="w-100 ms-3">
                                    <div class="d-flex w-100 justify-content-between">
                                        <h6 class="mb-0">Jhon Doe</h6>
                                        <small>15 minutes ago</small>
                                    </div>
                                    <span>Short message goes here...</span>
                                </div>
                            </div>
                        </div>
                    </div>
                    <div class="col-sm-12 col-md-6 col-xl-4">
                        <div class="h-100 bg-light rounded p-4">
                            <div class="d-flex align-items-center justify-content-between mb-4">
                                <h6 class="mb-0">Calender</h6>
                                <a href="">Show All</a>
                            </div>
                            <div id="calender"></div>
                        </div>
                    </div>
                    <div class="col-sm-12 col-md-6 col-xl-4">
                        <div class="h-100 bg-light rounded p-4">
                            <div class="d-flex align-items-center justify-content-between mb-4">
                                <h6 class="mb-0">To Do List</h6>
                                <a href="">Show All</a>
                            </div>
                            <div class="d-flex mb-2">
                                <input class="form-control bg-transparent" type="text" placeholder="Enter task">
                                <button type="button" class="btn btn-primary ms-2">Add</button>
                            </div>
                            <div class="d-flex align-items-center border-bottom py-2">
                                <input class="form-check-input m-0" type="checkbox">
                                <div class="w-100 ms-3">
                                    <div class="d-flex w-100 align-items-center justify-content-between">
                                        <span>Short task goes here...</span>
                                        <button class="btn btn-sm"><i class="fa fa-times"></i></button>
                                    </div>
                                </div>
                            </div>
                            <div class="d-flex align-items-center border-bottom py-2">
                                <input class="form-check-input m-0" type="checkbox">
                                <div class="w-100 ms-3">
                                    <div class="d-flex w-100 align-items-center justify-content-between">
                                        <span>Short task goes here...</span>
                                        <button class="btn btn-sm"><i class="fa fa-times"></i></button>
                                    </div>
                                </div>
                            </div>
                            <div class="d-flex align-items-center border-bottom py-2">
                                <input class="form-check-input m-0" type="checkbox" checked>
                                <div class="w-100 ms-3">
                                    <div class="d-flex w-100 align-items-center justify-content-between">
                                        <span><del>Short task goes here...</del></span>
                                        <button class="btn btn-sm text-primary"><i class="fa fa-times"></i></button>
                                    </div>
                                </div>
                            </div>
                            <div class="d-flex align-items-center border-bottom py-2">
                                <input class="form-check-input m-0" type="checkbox">
                                <div class="w-100 ms-3">
                                    <div class="d-flex w-100 align-items-center justify-content-between">
                                        <span>Short task goes here...</span>
                                        <button class="btn btn-sm"><i class="fa fa-times"></i></button>
                                    </div>
                                </div>
                            </div>
                            <div class="d-flex align-items-center pt-2">
                                <input class="form-check-input m-0" type="checkbox">
                                <div class="w-100 ms-3">
                                    <div class="d-flex w-100 align-items-center justify-content-between">
                                        <span>Short task goes here...</span>
                                        <button class="btn btn-sm"><i class="fa fa-times"></i></button>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
            <!-- Widgets End -->
      
      
            <!-- Footer Start -->
            <div class="container-fluid pt-4 px-4">
                <div class="bg-light rounded-top p-4">
                    <div class="row">
                        <div class="col-12 col-sm-6 text-center text-sm-start">
                            &copy; <a href="#">Your Site Name</a>, All Right Reserved. 
                        </div>
                        <div class="col-12 col-sm-6 text-center text-sm-end">
                            <!--/*** This template is free as long as you keep the footer author’s credit link/attribution link/backlink. If you'd like to use the template without the footer author’s credit link/attribution link/backlink, you can purchase the Credit Removal License from "https://therichpost.com/credit-removal". Thank you for your support. ***/-->
                            with love <a href="https://therichpost.com">Jassa</a>
                       
                        </div>
                    </div>
                </div>
            </div>
            <!-- Footer End -->
        </div>
        <!-- Content End -->
      
      
        <!-- Back to Top -->
        <a href="#" class="btn btn-lg btn-primary btn-lg-square back-to-top"><i class="bi bi-arrow-up"></i></a>
      </div>

    6. Now guys we need to add below code into our scr/app/signin/signin.component.html file:

    <div class="container-xxl position-relative bg-white d-flex p-0">
        <!-- Spinner Start -->
        <div id="spinner" class="show bg-white position-fixed translate-middle w-100 vh-100 top-50 start-50 d-flex align-items-center justify-content-center">
            <div class="spinner-border text-primary" style="width: 3rem; height: 3rem;" role="status">
                <span class="sr-only">Loading...</span>
            </div>
        </div>
        <!-- Spinner End -->
    
    
        <!-- Sign In Start -->
        <div class="container-fluid">
            <div class="row h-100 align-items-center justify-content-center" style="min-height: 100vh;">
                <div class="col-12 col-sm-8 col-md-6 col-lg-5 col-xl-4">
                    <div class="bg-light rounded p-4 p-sm-5 my-4 mx-3">
                        <div class="d-flex align-items-center justify-content-between mb-3">
                            <a href="index.html" class="">
                                <h3 class="text-primary"><i class="fa fa-hashtag me-2"></i>DASHMIN</h3>
                            </a>
                            <h3>Sign In</h3>
                        </div>
                        <div class="form-floating mb-3">
                            <input type="email" class="form-control" id="floatingInput" placeholder="name@example.com">
                            <label for="floatingInput">Email address</label>
                        </div>
                        <div class="form-floating mb-4">
                            <input type="password" class="form-control" id="floatingPassword" placeholder="Password">
                            <label for="floatingPassword">Password</label>
                        </div>
                        <div class="d-flex align-items-center justify-content-between mb-4">
                            <div class="form-check">
                                <input type="checkbox" class="form-check-input" id="exampleCheck1">
                                <label class="form-check-label" for="exampleCheck1">Check me out</label>
                            </div>
                            <a href="">Forgot Password</a>
                        </div>
                        <button type="submit" class="btn btn-primary py-3 w-100 mb-4">Sign In</button>
                        <p class="text-center mb-0">Don't have an Account? <a href="">Sign Up</a></p>
                    </div>
                </div>
            </div>
        </div>
        <!-- Sign In End -->
    </div>

    7. Now guys we need to add below code into our scr/app/signup/signup.component.html file:

    <div class="container-xxl position-relative bg-white d-flex p-0">
        <!-- Spinner Start -->
        <div id="spinner" class="show bg-white position-fixed translate-middle w-100 vh-100 top-50 start-50 d-flex align-items-center justify-content-center">
            <div class="spinner-border text-primary" style="width: 3rem; height: 3rem;" role="status">
                <span class="sr-only">Loading...</span>
            </div>
        </div>
        <!-- Spinner End -->
    
    
        <!-- Sign Up Start -->
        <div class="container-fluid">
            <div class="row h-100 align-items-center justify-content-center" style="min-height: 100vh;">
                <div class="col-12 col-sm-8 col-md-6 col-lg-5 col-xl-4">
                    <div class="bg-light rounded p-4 p-sm-5 my-4 mx-3">
                        <div class="d-flex align-items-center justify-content-between mb-3">
                            <a href="#" class="">
                                <h3 class="text-primary"><i class="fa fa-hashtag me-2"></i>DASHMIN</h3>
                            </a>
                            <h3>Sign Up</h3>
                        </div>
                        <div class="form-floating mb-3">
                            <input type="text" class="form-control" id="floatingText" placeholder="jhondoe">
                            <label for="floatingText">Username</label>
                        </div>
                        <div class="form-floating mb-3">
                            <input type="email" class="form-control" id="floatingInput" placeholder="name@example.com">
                            <label for="floatingInput">Email address</label>
                        </div>
                        <div class="form-floating mb-4">
                            <input type="password" class="form-control" id="floatingPassword" placeholder="Password">
                            <label for="floatingPassword">Password</label>
                        </div>
                        <div class="d-flex align-items-center justify-content-between mb-4">
                            <div class="form-check">
                                <input type="checkbox" class="form-check-input" id="exampleCheck1">
                                <label class="form-check-label" for="exampleCheck1">Check me out</label>
                            </div>
                            <a href="">Forgot Password</a>
                        </div>
                        <button type="submit" class="btn btn-primary py-3 w-100 mb-4">Sign Up</button>
                        <p class="text-center mb-0">Already have an Account? <a href="">Sign In</a></p>
                    </div>
                </div>
            </div>
        </div>
        <!-- Sign Up End -->
    </div>

    8. Now guys we need to add below into src/app/app.routes.ts to links components to routes:

    import { Routes } from '@angular/router';
    import { DashboardComponent } from './dashboard/dashboard.component';
    import { SigninComponent } from './signin/signin.component';
    import { SignupComponent } from './signup/signup.component';
    export const routes: Routes = [
          {
            path: '', title: 'Dashboard Page', component: DashboardComponent,
          },
          {
            path: 'signin', title: 'Dashboard Page', component: SigninComponent,
          },
          {
            path: 'signup', title: 'Dashboard Page', component: SignupComponent,
          },
    ];
    

    9. Now guys we need to add below code into our project/src/index.html file for styles and scripts or we can also call this styles/scripts inside angular.json file:

    <!doctype html>
    <html lang="en">
    <head>
      <meta charset="utf-8">
      <title>Angularadmin</title>
      <base href="/">
      <meta name="viewport" content="width=device-width, initial-scale=1">
      <!-- Favicon -->
      <link href="img/user.jpg" rel="icon">
    
      <!-- Google Web Fonts -->
      <link rel="preconnect" href="https://fonts.googleapis.com">
      <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
      <link href="https://fonts.googleapis.com/css2?family=Heebo:wght@400;500;600;700&display=swap" rel="stylesheet">
      
      <!-- Icon Font Stylesheet -->
      <link href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.10.0/css/all.min.css" rel="stylesheet">
      <link href="https://cdn.jsdelivr.net/npm/bootstrap-icons@1.4.1/font/bootstrap-icons.css" rel="stylesheet">
    
      <!-- Libraries Stylesheet -->
      <link href="assets/css/owl.carousel.min.css" rel="stylesheet">
      <link href="assets/css/tempusdominus-bootstrap-4.min.css" rel="stylesheet" />
    
      <!-- Customized Bootstrap Stylesheet -->
      <link href="assets/css/bootstrap.min.css" rel="stylesheet">
    
      <!-- Template Stylesheet -->
      <link href="assets/css/style.css" rel="stylesheet">
    </head>
    <body>
      <app-root></app-root>
      <!-- JavaScript Libraries -->
      <script src="https://code.jquery.com/jquery-3.4.1.min.js"></script>
      <script src="https://cdn.jsdelivr.net/npm/bootstrap@5.0.0/dist/js/bootstrap.bundle.min.js"></script>
      <script src="assets/js/chart.min.js"></script>
      <script src="assets/js/easing.min.js"></script>
      <script src="assets/js/waypoints.min.js"></script>
      <script src="assets/js/owl.carousel.min.js"></script>
      <script src="assets/js/moment.min.js"></script>
      <script src="assets/js/moment-timezone.min.js"></script>
      <script src="assets/js/tempusdominus-bootstrap-4.min.js"></script>
    
      <!-- Template Javascript -->
      <script src="assets/js/main.js"></script>
    </body>
    </html>

    10. Now guys here is the github link and from where we will get the all the assets like images, css, js and fonts:

    GitHub Link

    Friends in the end must run ng serve command into your terminal to run the angular 17 project(localhost:4200).

    Now we are done friends. If you have any kind of query, suggestion and new requirement then feel free to comment below.

    Note: Friends, In this post, I just tell the basic setup and things, you can change the code according to your requirements.

    I will appreciate that if you will tell your views for this post. Nothing matters if your views will be good or bad because with your views, I will make my next posts more good and helpful.

    Jassa

    Thanks

  • Angular 17 child routes route params

    Angular 17 child routes route params

    In Angular 17, child routes allow you to organize your applications into a hierarchical navigation structure. They are defined in the routing configuration of a parent route and help in managing complex routing structures with ease. Route parameters are parts of the URL that you can capture and use to display dynamic content based on the path.

    Angular17 came and if you are new then you must check below two links:

    1. Angular 17 Basic Tutorials
    2. Angular Free Templates

    Here’s how you can work with Angular child routes and route parameters:

    1. Defining Child Routes

    Child routes are defined in the RouterModule of your Angular application, using the RouterModule.forRoot() method for root level routes or RouterModule.forChild() for feature modules. You define them in the children array of a route configuration.

    const routes: Routes = [
      {
        path: 'parent',
        component: ParentComponent,
        children: [
          {
            path: 'child/:id', // :id is a route parameter
            component: ChildComponent
          }
        ]
      }
    ];

    In this example, ParentComponent has a child route that is associated with ChildComponent. The :id in the path child/:id is a route parameter that can be used to pass dynamic values.

    2. Accessing Route Parameters

    To access route parameters within your component, you use the ActivatedRoute service provided by Angular’s Router package. Specifically, you can subscribe to the params observable of ActivatedRoute to get the route parameters.

    In ChildComponent, you can access the id route parameter like this:

    import { Component, OnInit } from '@angular/core';
    import { ActivatedRoute } from '@angular/router';
    
    @Component({
      selector: 'app-child',
      template: '<p>Child Component with ID: {{id}}</p>',
    })
    export class ChildComponent implements OnInit {
      id: string;
    
      constructor(private route: ActivatedRoute) {}
    
      ngOnInit() {
        this.route.params.subscribe(params => {
          this.id = params['id']; // Grab the id route parameter
        });
      }
    }

    3. Navigating to Child Routes with Parameters

    To navigate to a child route with parameters, you can use the Router service’s navigate method or the routerLink directive in your templates.

    Using Router service:

    constructor(private router: Router) {}
    
    navigateToChild() {
      this.router.navigate(['/parent/child', 123]); // Navigates to /parent/child/123
    }

    Using routerLink directive:

    <a [routerLink]="['/parent/child', 123]">Go to Child</a>

    4. Path Matching Strategy

    For routes with parameters, Angular uses a first-match wins strategy. This means the router selects the first route that matches the URL from top to bottom. Ensure your route paths are ordered correctly to avoid unexpected behavior.

    By using child routes and route parameters, Angular applications can implement sophisticated routing structures, making it easier to build complex and hierarchical navigation flows.

  • How to insert the ng-template into dynamically added external element in Angular?

    How to insert the ng-template into dynamically added external element in Angular?

    To insert an ng-template into a dynamically added external element in Angular, you would typically use Angular directives to control where and how the template is rendered. However, for dynamically added external elements (elements that are added to the DOM outside of Angular’s normal rendering process), you will need to interact with Angular’s rendering engine at a lower level. Here’s a step-by-step approach to achieve this:

    Angular17 came and if you are new then you must check below two links:

    1. Angular 17 Basic Tutorials
    2. Angular Free Templates

    1. Define Your ng-template

    First, ensure your ng-template is defined in your component’s template. Use a template reference variable to easily access it from your component class.

    <ng-template #myTemplate>
      <!-- Your template content goes here -->
      <div>Hello from ng-template!</div>
    </ng-template>

    2. Access the Template in Component

    Use ViewChild to access the ng-template in your component class. You’ll also need ViewContainerRef and TemplateRef from @angular/core to manipulate the template.

    import { Component, ViewChild, TemplateRef, ViewContainerRef } from '@angular/core';
    
    @Component({
      selector: 'my-app',
      templateUrl: './app.component.html',
    })
    export class AppComponent {
      @ViewChild('myTemplate') myTemplate!: TemplateRef<any>;
    
      constructor(private viewContainerRef: ViewContainerRef) {}
    
      // Method to dynamically insert the template
      insertTemplateDynamically() {
        // Your logic to insert the template goes here
      }
    }

    3. Dynamically Add the External Element

    Before you can insert the ng-template into the dynamically added element, you must first add this element to the DOM. You can do this by manipulating the DOM directly or by using Angular’s Renderer2 for a more Angular-friendly approach.

    import { Renderer2, ElementRef, OnInit } from '@angular/core';
    
    constructor(private renderer: Renderer2, private el: ElementRef) {}
    
    ngOnInit() {
      const externalElement = this.renderer.createElement('div');
      this.renderer.appendChild(this.el.nativeElement, externalElement);
    }

    4. Insert the ng-template into the External Element

    To insert the ng-template into this dynamically added external element, use the ViewContainerRef associated with the element where you want to insert the template. You might need to create a ViewContainerRef for the external element manually since it’s outside Angular’s component hierarchy.

    insertTemplateIntoExternalElement(externalElement: HTMLElement) {
      const embeddedView = this.viewContainerRef.createEmbeddedView(this.myTemplate);
      this.renderer.appendChild(externalElement, embeddedView.rootNodes[0]);
    }

    Important Note: Direct DOM manipulations like these can lead to security vulnerabilities, such as XSS attacks. Always sanitize any user input or content that gets inserted into your templates or DOM. Angular provides the DomSanitizer service for sanitizing content.

    Final Thoughts

    Manipulating the DOM directly and inserting Angular templates into dynamically added external elements is an advanced technique that should be used judiciously. Always consider Angular’s data-binding and component-based architecture first for manipulating the DOM, as direct DOM access and manipulation can lead to less maintainable code and potential security issues.

    Inserting an ng-template into a dynamically added external element in Angular requires a multi-step approach. You have to first define your template, then use Angular’s rendering and view manipulation APIs to insert it dynamically. Here’s a step-by-step guide:

    1. Define Your ng-template

    First, you’ll need an ng-template that you wish to insert. Define it in your component’s template (HTML file) with a template reference variable that you can refer to in your TypeScript code.

    <ng-template #myTemplate>
      <div>Dynamic content here!</div>
    </ng-template>

    2. Access the Template in Component

    Use ViewChild to access the template within your component’s TypeScript file. You’ll also need to import TemplateRef and ViewContainerRef for manipulating this template.

    import { Component, ViewChild, TemplateRef, ViewContainerRef } from '@angular/core';
    
    @Component({
      selector: 'app-my-component',
      templateUrl: './my-component.component.html',
    })
    export class MyComponent {
      @ViewChild('myTemplate') myTemplate!: TemplateRef<any>;
    
      constructor(private viewContainerRef: ViewContainerRef) {}
    }

    3. Insert the Template Dynamically

    Now, to insert the ng-template dynamically into an external element, you’ll likely need a method that handles the insertion logic. If this external element is part of your component, you can directly access it. However, for truly external elements, you may need a different approach, like using Angular’s Renderer2 or directly manipulating the DOM (which is generally not recommended).

    Here’s an example using Renderer2 to append the template to a body element:

    import { Renderer2, RendererFactory2 } from '@angular/core';
    
    private renderer: Renderer2;
    
    constructor(rendererFactory: RendererFactory2, private viewContainerRef: ViewContainerRef) {
      this.renderer = rendererFactory.createRenderer(null, null);
    }
    
    insertTemplate() {
      const embeddedView = this.myTemplate.createEmbeddedView(null);
      this.viewContainerRef.insert(embeddedView);
      const element = (embeddedView.rootNodes[0] as HTMLElement);
    
      // Assuming you want to append to the body. Replace 'document.body' with your target element.
      this.renderer.appendChild(document.body, element);
    }

    Considerations

    • Direct DOM Manipulation: Direct manipulation of the DOM is not recommended in Angular for most cases because it bypasses Angular’s change detection and sanitization. Prefer Angular’s Renderer2 or similar Angular-approved methods when possible.
    • Dynamic Content Context: If your ng-template needs context (like variables passed into it), you can provide a context object when creating the embedded view. Replace null in createEmbeddedView(null) with your context object.

    This approach uses Angular’s built-in mechanisms for template and view manipulation, ensuring compatibility with Angular’s change detection and security features. Always test these dynamic manipulations thoroughly to ensure they work as expected in your specific application context.

  • Full-Stack Development Project with Angular for the frontend and Node.js for the backend

    Full-Stack Development Project with Angular for the frontend and Node.js for the backend

    Embarking on a full-stack development project with Angular for the frontend and Node.js for the backend can be an exciting venture, offering a blend of performance, scalability, and a rich ecosystem. Here’s a high-level overview of how to start such a project, including considerations for planning, development, and deployment.

    Project Planning

    1. Define Project Scope: Clearly outline the goals, features, and functionalities of your application. Consider creating a Minimum Viable Product (MVP) to start.
    2. Choose a Database: Based on your application’s needs, decide on a database. MongoDB is a popular choice for its flexibility and scalability, fitting well with the JavaScript stack.
    3. Design the Application Architecture: Plan your application’s architecture, including the client-side, server-side, and database. Consider using the Model-View-Controller (MVC) pattern for organization.

    Development Environment Setup

    1. Node.js and npm (Node Package Manager): Ensure Node.js and npm are installed on your development machine. npm will manage your project’s dependencies.
    2. Angular CLI: Install the Angular CLI globally using npm. This tool is essential for creating, managing, and deploying Angular applications.
    3. IDE or Code Editor: Choose an Integrated Development Environment (IDE) or a code editor that supports both Angular and Node.js development, such as Visual Studio Code.

    Backend Development with Node.js

    1. Initialize Your Project: Use npm init to create a package.json file, which will track your project’s dependencies.
    2. Framework: Consider using a framework like Express.js to simplify the development of your backend. It offers robust features for web and mobile applications.
    3. API Development: Design and develop your application’s RESTful API, focusing on creating endpoints that perform CRUD operations on your database.
    4. Authentication and Authorization: Implement security measures, such as JWT (JSON Web Tokens) for secure data exchange.

    Frontend Development with Angular

    1. Create Your Angular Application: Use the Angular CLI to generate a new Angular application.
    2. Component Architecture: Design your application using a component-based architecture, creating reusable components for your UI.
    3. Routing and Services: Implement routing for navigation and services for data communication between the frontend and the backend.
    4. Integrate with the Backend: Use Angular’s HttpClient module to connect your frontend application with the Node.js backend, consuming the RESTful API you’ve developed.

    Testing

    1. Unit Testing: Write unit tests for both the backend and frontend. Use frameworks like Jasmine and Karma for Angular, and Mocha or Jest for Node.js.
    2. End-to-End Testing: Implement end-to-end tests to ensure the application works as expected from a user’s perspective. Tools like Protractor can be used for Angular applications.

    Deployment

    1. Prepare the Application for Production: Build your Angular application for production using the Angular CLI. Optimize your Node.js application for performance and security.
    2. Choose a Hosting Service: Select a hosting service that supports both Node.js and static site hosting for your Angular application. Options include Heroku, AWS, and DigitalOcean.
    3. Continuous Integration/Continuous Deployment (CI/CD): Set up a CI/CD pipeline to automate testing and deployment processes using tools like Jenkins, Travis CI, or GitHub Actions.

    Continuous Learning and Adaptation

    • Stay Updated: Both Angular and Node.js are rapidly evolving platforms. Stay updated with the latest changes and improvements.
    • Feedback Loop: Collect feedback from your users and continuously iterate on your application, adding new features and improving existing ones based on user input.

    This overview provides a starting point for your full-stack development project with Angular and Node.js. Each phase of the project requires careful planning, development, testing, and deployment strategies to ensure a successful application launch and lifecycle.

  • Implementing a Signals Store in an Angular application

    Implementing a Signals Store in an Angular application

    Implementing a Signals Store in an Angular application involves creating a centralized place to manage state and events, enhancing the predictability and maintainability of your app. Angular, by design, does not include a built-in solution for state management akin to Redux in React. However, Angular developers often rely on libraries like NgRx, Akita, or NgXS for these purposes. A “Signals Store” can be akin to using observables to manage state changes and propagate them throughout your application. Here’s a basic approach to creating a Signals Store using RxJS, which is already part of Angular’s ecosystem.

    Step 1: Setting Up Angular Project

    Ensure you have Angular CLI installed. If not, you can install it via npm:

    npm install -g @angular/cli

    Create a new Angular project:

    ng new signals-store-app

    Navigate to your project directory:

    cd signals-store-app

    Step 2: Creating a Signal Store Service

    Generate a service to act as your store:

    ng generate service store

    Open the store.service.ts file and set up a simple signal store using RxJS’s BehaviorSubject and Observable:

    import { Injectable } from '@angular/core';
    import { BehaviorSubject, Observable } from 'rxjs';
    
    @Injectable({
      providedIn: 'root',
    })
    export class StoreService {
      private readonly _signals = new BehaviorSubject<any[]>([]);
    
      get signals$(): Observable<any[]> {
        return this._signals.asObservable();
      }
    
      private get signals(): any[] {
        return this._signals.getValue();
      }
    
      private set signals(val: any[]) {
        this._signals.next(val);
      }
    
      addSignal(signal: any): void {
        this.signals = [
          ...this.signals,
          signal,
        ];
      }
    
      removeSignal(id: number): void {
        this.signals = this.signals.filter(signal => signal.id !== id);
      }
    }

    This service uses BehaviorSubject to keep a private state of signals, which are accessible via the signals$ observable. The addSignal and removeSignal methods modify the state, which automatically updates all subscribers.

    Step 3: Using the Store in Components

    Inject the StoreService in your components to use the store:

    import { Component, OnInit } from '@angular/core';
    import { StoreService } from './store.service';
    import { Observable } from 'rxjs';
    
    @Component({
      selector: 'app-signal-list',
      template: `
        <ul>
          <li *ngFor="let signal of signals$ | async">
            {{ signal.name }} - {{ signal.value }}
          </li>
        </ul>
      `,
    })
    export class SignalListComponent implements OnInit {
      signals$: Observable<any[]>;
    
      constructor(private storeService: StoreService) {}
    
      ngOnInit(): void {
        this.signals$ = this.storeService.signals$;
      }
    }

    In this component, you subscribe to the signals$ observable from the StoreService and use the async pipe in the template to automatically subscribe and unsubscribe, rendering the signals list dynamically.

    Step 4: Modifying Signals

    You can modify signals by calling addSignal or removeSignal from any component or service that injects the StoreService:

    this.storeService.addSignal({ id: 1, name: 'Signal 1', value: 'Value 1' });

    This approach provides a simple, RxJS-based state management solution in Angular without relying on external libraries. It’s a basic implementation and can be extended with more complex state management features as needed, like selectors or effects for handling side-effects.

  • Creating a user registration form in Angular and saving the data to a backend

    Creating a user registration form in Angular and saving the data to a backend

    Creating a user registration form in Angular and saving the data to a backend involves several steps, including setting up the Angular environment, creating the form using Angular Forms, and setting up the backend to receive and store the data. Below is a simplified outline of the process:

    1. Setting up Angular

    First, ensure you have Node.js and the Angular CLI installed. Then, create a new Angular project:

    ng new registration-project
    cd registration-project

    2. Creating the Registration Form

    Use Angular Forms to create the registration form. You can use either Template-driven or Reactive forms; here, we’ll use Reactive forms for their flexibility and scalability.

    Install Angular Forms:

    Ensure @angular/forms is installed and set up in your project (it usually is by default).

    Update app.module.ts:

    Import ReactiveFormsModule:

    import { ReactiveFormsModule } from '@angular/forms';
    
    @NgModule({
      declarations: [
        // other components
      ],
      imports: [
        ReactiveFormsModule,
        // other modules
      ],
      providers: [],
      bootstrap: [AppComponent]
    })
    export class AppModule { }

    Create the Form in a Component:

    Generate a new component for the registration form:

    ng generate component registration-form

    In registration-form.component.ts, set up the form:

    import { Component, OnInit } from '@angular/core';
    import { FormBuilder, FormGroup, Validators } from '@angular/forms';
    
    @Component({
      selector: 'app-registration-form',
      templateUrl: './registration-form.component.html',
      styleUrls: ['./registration-form.component.css']
    })
    export class RegistrationFormComponent implements OnInit {
      registrationForm: FormGroup;
    
      constructor(private fb: FormBuilder) { }
    
      ngOnInit() {
        this.registrationForm = this.fb.group({
          username: ['', [Validators.required, Validators.minLength(4)]],
          email: ['', [Validators.required, Validators.email]],
          password: ['', [Validators.required, Validators.minLength(8)]]
        });
      }
    
      onSubmit() {
        console.log(this.registrationForm.value);
        // Here, you'd typically send the form data to the backend.
      }
    }

    In registration-form.component.html, create the form template:

    <form [formGroup]="registrationForm" (ngSubmit)="onSubmit()">
      <input formControlName="username" placeholder="Username">
      <input formControlName="email" type="email" placeholder="Email">
      <input formControlName="password" type="password" placeholder="Password">
      <button type="submit" [disabled]="!registrationForm.valid">Register</button>
    </form>

    3. Setting up the Backend

    For the backend, you can use Node.js with Express, or any other backend technology. Here’s a simple setup with Node.js and Express:

    Install Dependencies:

    npm install express body-parser

    Create server.js:

    const express = require('express');
    const bodyParser = require('body-parser');
    
    const app = express();
    const port = 3000;
    
    app.use(bodyParser.json());
    
    app.post('/register', (req, res) => {
      console.log(req.body);
      // Here, you'd typically save the data to a database.
      res.status(200).send('User registered successfully');
    });
    
    app.listen(port, () => {
      console.log(`Server running on port ${port}`);
    });

    4. Connecting Angular to the Backend

    In your Angular service (you may need to create a service using ng generate service data), you would use the HttpClientModule from @angular/common/http to send the form data to the backend.

    First, make sure to import HttpClientModule in your app.module.ts and inject HttpClient in your service:

    import { HttpClientModule } from '@angular/common/http';
    // Import HttpClientModule in imports array

    In your service:

    import { HttpClient } from '@angular/common/http';
    
    constructor(private http: HttpClient) { }
    
    registerUser(userData: any) {
      return this.http.post('/register', userData);
    }

    And then call this service method in your onSubmit method in the registration component after importing and injecting the service.

    This guide provides a basic overview. Depending on your project’s complexity, you might need to adjust error handling, form validation feedback, and security considerations (like using HTTPS and sanitizing user input).