<div class="channels__channel"
     ng-class="{'channels__channel--active': active && !isError(),
                'channels__channel--error': active && isError()}">
  <div class="channels-protocol-about">
    <div class="channels-protocol-image">
      <div class="channels-protocol-image-wrap">
        <img ng-if="sim.state == 'READY'"
             ng-src="{[ operatorImg(utils.operatorImageId(sim.plmn)) ]}">
        <img ng-if="sim.state != 'READY'"
             ng-src="{[ operatorImg('empty') ]}">
        <div class="channels-protocol-number">{[ index + 1 ]}</div>
      </div>
    </div>
    <div class="channels-protocol-status-list">
      <channel-status-item ng-show="showSimStatus()" active="active" error="isError()"
                           no-indicator="hideStatusMarker()">
        <div class="channels-protocol-status-list__item-title"
             ng-switch="sim.state">
          <span ng-switch-when="NONE" translate>Инициализаця модема</span>
          <span ng-switch-when="INIT" translate>Инициализация SIM</span>
          <span ng-switch-when="CHECK_REG" translate>Регистрация в сети</span>
          <span ng-switch-when="INIT_FAILED" translate>Ошибка инициализации SIM</span>
          <span ng-switch-when="REG_FAILED" translate>Ошибка регистрации в сети</span>
        </div>
        <div ng-if="sim.state == 'READY'"
            class="channels-protocol-status-list__item-subtitle">{[ utils.operatorName(sim.plmn) ]} ({[ utils.cutPLMN(sim.plmn) ]})</div>
        <div ng-if="sim.state == 'READY'"
            class="channels-protocol-status-list__item-subtitle">
          RSSI: {[ sim.rssi ]}
          <span ng-if="sim.rssi < 10">
            (<translate translate-context="(уровень сигнала сотовой связи)">плохой</translate>)
          </span>
          <span ng-if="sim.rssi >= 10">
            (<translate translate-context="(уровень сигнала сотовой связи)">хороший</translate>)
          </span>
        </div>
      </channel-status-item>
    </div>
  </div>

  <div class="channels-protocol-list">
    <gsm-channel ng-if="sim.channels.gprs"
                 channel-type="gprs"
                 channel-name="{[ 'GPRS' | translate: '(названия каналов связи через SIM-карту)' ]}"
                 sim="index"
                 sim-ready="isReady"
                 channel="sim.channels.gprs">
    </gsm-channel>
    <gsm-channel only-desktop ng-if="sim.channels.csd"
                 channel-type="csd"
                 channel-name="{[ 'CSD' | translate: '(названия каналов связи через SIM-карту)' ]}"
                 sim="index"
                 sim-ready="isReady"
                 channel="sim.channels.csd">
    </gsm-channel>
    <gsm-channel only-desktop ng-if="sim.channels.voice"
                 channel-type="voice"
                 channel-name="{[ 'ГОЛОС' | translate: '(названия каналов связи через SIM-карту)' ]}"
                 sim="index"
                 sim-ready="isReady"
                 channel="sim.channels.voice">
    </gsm-channel>
    <gsm-channel only-desktop ng-if="sim.channels.sms"
                 channel-type="sms"
                 channel-name="{[ 'SMS' | translate: '(названия каналов связи через SIM-карту)' ]}"
                 sim="index"
                 sim-ready="isReady"
                 channel="sim.channels.sms">
    </gsm-channel>
  </div>
</div>
