File

remote-access/configurations/remote-access-pick-protocol-modal/remote-access-pick-protocol-modal.component.ts

Metadata

Index

Properties
Methods

Constructor

constructor(remoteAccess: RemoteAccessService, bsModalRef: BsModalRef)
Parameters :
Name Type Optional
remoteAccess RemoteAccessService No
bsModalRef BsModalRef No

Methods

cancel
cancel()
Returns : void
selectProtocol
selectProtocol(protocol: RemoteAccessProtocolProvider)
Parameters :
Name Type Optional
protocol RemoteAccessProtocolProvider No
Returns : void

Properties

protocolProviders
Type : RemoteAccessProtocolProvider[]
Default value : []
result
Default value : new Promise<RemoteAccessProtocolProvider>((resolve, reject) => { this._resolve = resolve; this._reject = reject; })
title
Default value : gettext('Select a protocol')
<c8y-modal
  [title]="title"
  [headerClasses]="'dialog-header'"
  (onDismiss)="cancel()"
  [labels]="{ cancel: 'Cancel' }"
>
  <ng-container c8y-modal-title>
    <span [c8yIcon]="'laptop'"></span>
  </ng-container>
  <div class="p-24">
    <c8y-li *ngFor="let provider of protocolProviders">
      <c8y-li-icon>
        <i [c8yIcon]="provider.protocolIcon"></i>
      </c8y-li-icon>
      <c8y-li-body>
        <div class="d-flex j-c-between">
          <div>
            <p>{{ provider.protocolLabel | translate }}</p>
            <p>
              <small>{{ provider.protocolDescription | translate }}</small>
            </p>
          </div>
          <div>
            <button
              class="btn btn-primary"
              (click)="selectProtocol(provider)"
              [attr.data-cy]="'remoteAccessPickProtocolModal--select-' + provider.protocolName"
            >
              <span translate>Select</span>
            </button>
          </div>
        </div>
      </c8y-li-body>
    </c8y-li>
  </div>
</c8y-modal>

results matching ""

    No results matching ""