File

branding/shared/lazy/apply-branding-to-app-modal/apply-branding-to-app-modal.component.ts

Implements

OnInit

Metadata

Index

Properties
Methods
Inputs

Constructor

constructor(apply: ApplyBrandingToAppService, formBuilder: FormBuilder)
Parameters :
Name Type Optional
apply ApplyBrandingToAppService No
formBuilder FormBuilder No

Inputs

currentTags
Type : string[]

Methods

cancel
cancel()
Returns : void
Async ngOnInit
ngOnInit()
Returns : any
save
save()
Returns : void

Properties

brandableApps
Type : Awaited<ReturnType<>>
Default value : []
form
Type : ReturnType<>
numberOfSelectedApps$
Type : Observable<number>
result
Default value : new Promise<ReturnType<typeof this.initForm>['value']>((resolve, reject) => { this._resovle = resolve; this._reject = reject; })
<c8y-modal
  [title]="'Apply branding to apps' | translate"
  [disabled]="!form || form.invalid || !brandableApps.length"
  [headerClasses]="'dialog-header'"
  (onDismiss)="cancel()"
  (onClose)="save()"
  [labels]="{ cancel: 'Cancel', ok: 'Save' }"
>
  <ng-container c8y-modal-title>
    <span c8yIcon="palette"></span>
  </ng-container>
  <c8y-list-group
    class="m-b-0 no-border-last"
    *ngIf="form"
    [formGroup]="form"
  >
    <c8y-li>
      <p
        class="text-center text-medium"
        *ngIf="numberOfSelectedApps$ | async as numberOfApps; else noapps"
        translate
      >
        {{ numberOfApps }} apps selected for branding
      </p>
      <ng-template #noapps>
        <p
          class="text-center text-medium"
          translate
        >
          No apps selected for branding
        </p>
      </ng-template>
    </c8y-li>
    <c8y-li *ngFor="let app of brandableApps">
      <c8y-li-icon>
        <c8y-app-icon
          class="icon-40"
          [app]="app"
        ></c8y-app-icon>
      </c8y-li-icon>
      <c8y-li-checkbox
        [attr.data-cy]="'branding-apply-branding-to-app-checkbox-' + app.contextPath"
        [formControlName]="app.contextPath"
      ></c8y-li-checkbox>
      <c8y-li-body class="p-t-8 d-block">{{ app | humanizeAppName | async }}</c8y-li-body>
    </c8y-li>
  </c8y-list-group>
</c8y-modal>

results matching ""

    No results matching ""