welcome.html 8.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151
  1. <div id="welcome">
  2. <div class="center-block text-center welcome">
  3. <div ng-if="(ctrl.state === 'connecting' || ctrl.state === 'waiting') && ctrl.mode === 'scan'" class="scan">
  4. <div class="ios-only-warning" ng-if="ctrl.browser.safari">
  5. <img src="img/safari.svg" alt="Safari">
  6. <p><strong translate>common.NOTE</strong> <span translate>welcome.SAFARI</span></p>
  7. </div>
  8. <p class="instructions" translate>welcome.PLEASE_SCAN</p>
  9. <qrcode version="{{ ctrl.qrCode.version }}"
  10. id="connecting-code"
  11. error-correction-level="{{ ctrl.qrCode.errorCorrectionLevel }}"
  12. size="{{ ctrl.qrCode.size }}" data="{{ ctrl.qrCode.data }}"></qrcode>
  13. <div class="password-entry">
  14. <label>
  15. <p translate id="aria-label-password-create">welcome.CHOOSE_PASSWORD</p>
  16. <form autocomplete="off">
  17. <md-input-container md-no-float class="md-block">
  18. <input type="password"
  19. ng-model="ctrl.password"
  20. aria-labelledby="aria-label-password-create"
  21. translate-attr="{'placeholder': 'welcome.PASSWORD', 'aria-label': 'welcome.PASSWORD'}"
  22. autocomplete="new-password">
  23. </md-input-container>
  24. </form>
  25. </label>
  26. </div>
  27. </div>
  28. <div ng-if="(ctrl.state === 'new' || ctrl.state === 'connecting') && ctrl.mode === 'unlock'" class="unlock">
  29. <h2 class="instructions" translate>welcome.PLEASE_UNLOCK</h2>
  30. <div class="password-entry">
  31. <label>
  32. <p translate id="aria-label-password-reconnecte">welcome.ENTER_PASSWORD</p>
  33. <form ng-submit="ctrl.unlockConfirm()">
  34. <md-input-container md-no-float class="md-block">
  35. <input type="password"
  36. ng-model="ctrl.password"
  37. ng-disabled="ctrl.formLocked"
  38. autofocus
  39. aria-labelledby="aria-label-password-reconnect"
  40. translate-attr="{'placeholder': 'welcome.PASSWORD'}"
  41. autocomplete="current-password">
  42. </md-input-container>
  43. <md-button type="submit" class="md-raised md-primary" translate translate-attr-aria-label="welcome.BTN_RECONNECT">
  44. <span translate aria-hidden="true">welcome.BTN_RECONNECT</span>
  45. </md-button>
  46. </form>
  47. <p>
  48. <span translate>welcome.ALTERNATIVELY</span>
  49. <a href="#" ng-click="ctrl.deleteSession()" translate>welcome.FORGET_SESSION</a>.
  50. </p>
  51. </label>
  52. </div>
  53. </div>
  54. <div ng-if="ctrl.showLoadingIndicator">
  55. <h2 class="instructions" translate>welcome.CONNECTING</h2>
  56. <div class="loading">
  57. <md-progress-circular md-mode="determinate" value="{{ ctrl.progress }}" md-diameter="250" ng-aria-disable>
  58. </md-progress-circular>
  59. <div class="info" aria-live="polite" ng-aria-disable>
  60. <p class="percentage">{{ ctrl.progress }}%</p>
  61. <p ng-if="ctrl.state === 'push'" translate>welcome.WAITING_FOR_PUSH</p>
  62. <p ng-if="ctrl.state === 'peer_handshake'" translate>welcome.CONNECTING_TO_APP</p>
  63. <p ng-if="ctrl.state === 'loading' || ctrl.state === 'done'" translate>welcome.LOADING_INITIAL_DATA</p>
  64. <div class="troubleshoot" ng-if="ctrl.slowConnect">
  65. <h3 translate>troubleshooting.SLOW_CONNECT</h3>
  66. <ul>
  67. <li>
  68. <i class="material-icons md-dark md-14">help</i>
  69. <span translate>troubleshooting.PHONE_ONLINE</span>
  70. </li>
  71. <li ng-if="ctrl.state === 'push'">
  72. <i class="material-icons md-dark md-14">help</i>
  73. <span translate>troubleshooting.APP_STARTED</span>
  74. </li>
  75. <li ng-if="ctrl.state === 'push'">
  76. <i class="material-icons md-dark md-14">help</i>
  77. <span translate>troubleshooting.WEBCLIENT_ENABLED</span>
  78. </li>
  79. <li ng-if="ctrl.state === 'push'">
  80. <i class="material-icons md-dark md-14">help</i>
  81. <span translate>troubleshooting.SESSION_DELETED</span>
  82. </li>
  83. <li ng-if="ctrl.state === 'peer_handshake' && ctrl.showWebrtcTroubleshooting">
  84. <i class="material-icons md-dark md-14">help</i>
  85. <span translate>troubleshooting.PLUGIN</span>
  86. </li>
  87. <li ng-if="ctrl.state === 'peer_handshake' && ctrl.showWebrtcTroubleshooting">
  88. <i class="material-icons md-dark md-14">help</i>
  89. <span translate>troubleshooting.ADBLOCKER</span>
  90. </li>
  91. </ul>
  92. <md-button role="button" class="md-raised md-primary reload-btn" ng-click="ctrl.deleteSession()" ng-if="ctrl.state === 'push'" aria-labelledby="aria-label-forget">
  93. <span translate id="aria-label-forget">welcome.FORGET_SESSION_BTN</span>
  94. </md-button>
  95. <md-button role="button" class="md-raised md-primary reload-btn" ng-click="ctrl.reload()" aria-labelledby="aria-label-reload">
  96. <i class="material-icons">refresh</i> <span translate id="aria-label-reload">welcome.RELOAD</span>
  97. </md-button>
  98. </div>
  99. </div>
  100. </div>
  101. </div>
  102. <div class="manual-start" ng-if="ctrl.state === 'manual_start'">
  103. <h2 class="instructions" translate>welcome.MANUAL_START</h2>
  104. <p translate>welcome.MANUAL_START_TEXT1</p>
  105. <i class="illustration material-icons md-dark md-96">phone_android</i>
  106. <p translate>welcome.MANUAL_START_TEXT2</p>
  107. <ol>
  108. <li translate>welcome.MANUAL_START_STEP1</li>
  109. <li translate>welcome.MANUAL_START_STEP2</li>
  110. <li translate>welcome.MANUAL_START_STEP3</li>
  111. </ol>
  112. </div>
  113. <div class="already-connected" ng-if="ctrl.state === 'already_connected'">
  114. <h2 class="instructions" translate>welcome.ALREADY_CONNECTED</h2>
  115. <i class="illustration material-icons md-dark md-96">phonelink_ring</i>
  116. <p translate>welcome.ALREADY_CONNECTED_DETAILS</p>
  117. <br>
  118. <md-button class="md-raised md-primary" ng-click="ctrl.reload()">
  119. <i class="material-icons">refresh</i> <span translate>welcome.RELOAD</span>
  120. </md-button>
  121. </div>
  122. <div ng-if="ctrl.state === 'closed'">
  123. <p class="state error">
  124. <strong><span translate>common.ERROR</span>:</strong> <span translate>connecting.CONNECTION_CLOSED</span><br>
  125. <span translate>welcome.PLEASE_RELOAD</span>
  126. </p>
  127. <br>
  128. <md-button class="md-raised md-primary" ng-click="ctrl.reload()">
  129. <i class="material-icons">refresh</i> <span translate>welcome.RELOAD</span>
  130. </md-button>
  131. </div>
  132. <div ng-if="ctrl.state === 'reconnect_failed'">
  133. <p class="state error">
  134. <strong><span translate>common.ERROR</span>:</strong> <span translate>connecting.RECONNECT_FAILED</span><br>
  135. <span translate>welcome.PLEASE_RELOAD</span>
  136. </p>
  137. <br>
  138. <md-button class="md-raised md-primary" ng-click="ctrl.reload()">
  139. <i class="material-icons">refresh</i> <span translate>welcome.RELOAD</span>
  140. </md-button>
  141. </div>
  142. </div>
  143. </div>