Version
Google Translate

FermionX Angular UI

To add FermionX into your existing projects, follow the steps below.

  • Firstly, install @vertosoft/vcp.ng.theme.fermion-x using the command below. yarn add @vertosoft/vcp.ng.theme.fermion-x
  • Then, edit angular.json as follows:

Add theme-specific styles into the styles array of the file. Check the Theme Configurations documentation for more information.

Importing a CSS file as an ECMA module is not supported in Angular 14. Therefore, we need to add the styles in the angular.json file.

  • At last, remove ThemeFermionModule from app.module.ts and shared.module.ts, and import the following modules in app.module.ts
import {
  HttpErrorComponent,
  ThemeFermionXModule,
} from "@vertosoft/vcp.ng.theme.fermion-x";
import { SideMenuLayoutModule } from "@vertosoft/vcp.ng.theme.fermion-x/layouts";

@NgModule({
  // ...
  imports: [
    // ...
    // ThemeFermionModule.forRoot(), -> remove this line.
    ThemeFermionXModule.forRoot(),
    SideMenuLayoutModule.forRoot(), // depends on which layout you choose
    // ...
  ],
  // ...
})
export class AppModule {}

If you want to use the Top Menu instead of the Side Menu, add TopMenuLayoutModule as below,and this style imports

import {
  HttpErrorComponent,
  ThemeFermionXModule,
} from "@vertosoft/vcp.ng.theme.fermion-x";
import { TopMenuLayoutModule } from "@vertosoft/vcp.ng.theme.fermion-x/layouts";

@NgModule({
  // ...
  imports: [
    // ...
    // ThemeFermionModule.forRoot(), -> remove this line.
    ThemeFermionXModule.forRoot(),
    TopMenuLayoutModule.forRoot(),
  ],
  // ...
})
export class AppModule {}
  • At this point, FermionX theme should be up and running within your application. However, you may need to overwrite some css variables based your needs for every theme available as follows:
:root {
  .lpx-theme-dark {
    --lpx-logo: url("/assets/images/logo/logo-light.svg");
    --lpx-logo-icon: url("/assets/images/logo/logo-light-icon.svg");
    --lpx-brand: #edae53;
  }

  .lpx-theme-dim {
    --lpx-logo: url("/assets/images/logo/logo-light.svg");
    --lpx-logo-icon: url("/assets/images/logo/logo-light-icon.svg");
    --lpx-brand: #f15835;
  }

  .lpx-theme-light {
    --lpx-logo: url("/assets/images/logo/logo-dark.svg");
    --lpx-logo-icon: url("/assets/images/logo/logo-dark-icon.svg");
    --lpx-brand: #69aada;
  }
}

If everything is ok, you can remove the @verto/vcp.ng.theme.fermion in package.json

Server Side

In order to migrate to FermionX on your server side projects (Host and/or IdentityServer projects), please follow Server Side Migration document.

In this document