File

core/bootstrap/bootstrap.component.ts

Implements

OnDestroy OnInit

Metadata

Index

Properties
Methods

Constructor

constructor(tabs: TabsService, ui: AppStateService, navigator: NavigatorService, actionBar: ActionBarService, headerService: HeaderService, options: OptionsService, pluginsResolve: PluginsResolveService, setupService: SetupService)
Parameters :
Name Type Optional
tabs TabsService No
ui AppStateService No
navigator NavigatorService No
actionBar ActionBarService No
headerService HeaderService No
options OptionsService No
pluginsResolve PluginsResolveService No
setupService SetupService No

Methods

ngOnDestroy
ngOnDestroy()
Returns : void
Async ngOnInit
ngOnInit()
Returns : any

Properties

Public actionBar
Type : ActionBarService
Public headerService
Type : HeaderService
Public navigator
Type : NavigatorService
navigatorOpen$
Type : Observable<boolean>
noAppsMargin$
Type : Observable<boolean>
noLogin
Type : boolean
Default value : false
Public setupService
Type : SetupService
showPoweredBy
Type : boolean
Default value : true
Public tabs
Type : TabsService
tabsOrientation
Type : string
Public ui
Type : AppStateService
<c8y-login *ngIf="!noLogin && !(ui.currentUser | async)"></c8y-login>

<div
  *ngIf="noLogin || ((ui.currentUser | async) && !(setupService.isSetupNeeded$ | async))"
  [class.head-open]="headerService.headerOpen"
>
  <c8y-header-bar #header></c8y-header-bar>
  <c8y-navigator-outlet
    [nodes]="navigator.items$ | async"
    [open]="headerService.navigatorOpen$ | async"
  >
    <header class="title navigator-slot-top">
      <div class="tenant-brand"></div>
      <c8y-app-icon
        [name]="(ui.state$ | async).app.name"
        [contextPath]="(ui.state$ | async).app.contextPath"
      ></c8y-app-icon>
      <span>{{ (ui.state$ | async).app | humanizeAppName | async }}</span>
    </header>
    <div class="powered-by navigator-slot-bottom" *ngIf="showPoweredBy">
      <p translate>powered by Cumulocity</p>
    </div>
  </c8y-navigator-outlet>

  <div class="alerts">
    <c8y-alert-outlet></c8y-alert-outlet>
  </div>
  <c8y-tabs-outlet
    #tabsComponent
    [tabs]="tabs.items$ | async"
    [navigatorOpen]="headerService.navigatorOpen$ | async"
    [orientation]="tabs.orientation$ | async"
  >
  </c8y-tabs-outlet>
  <c8y-action-bar
    #actionBarComponent
    [navigatorOpen]="headerService.navigatorOpen$ | async"
    [hasTabs]="tabsComponent.hasTabs"
    [isTabsHorizontal]="tabsComponent?.isHorizontal"
    [items$]="actionBar.items$"
  >
  </c8y-action-bar>

  <div
    class="mcontainer"
    [ngClass]="{
      open: headerService.navigatorOpen$ | async,
      'no-apps-margin': noAppsMargin$ | async,
      'horizontal-tabs': tabsComponent.isHorizontal,
      'vertical-tabs': !tabsComponent.isHorizontal,
      'has-tabs': tabsComponent.hasTabs,
      'has-action-bar': !actionBarComponent?.hidden
    }"
  >
    <div class="container-fluid">
      <router-outlet></router-outlet>
      <ng-content select="#c8y-legacy-view"></ng-content>
      <!-- legacy ng-view, will not be migrated atm -->
    </div>
  </div>
</div>

<div *ngIf="(ui.currentUser | async) && (setupService.isSetupNeeded$ | async)">
  <c8y-header-bar [simple]="true"></c8y-header-bar>
  <div class="mcontainer">
    <div class="container-fluid">
      <c8y-setup></c8y-setup>
    </div>
  </div>
</div>

<c8y-cookie-banner></c8y-cookie-banner>

results matching ""

    No results matching ""