Feature #41927 ยป set_one-time-code_for-twofa-input-fields.patch
| app/views/account/twofa_confirm.html.erb | ||
|---|---|---|
|
<%=l 'twofa_label_code' -%>
|
||
|
<%= link_to l('twofa_resend_code'), { controller: 'account', action: 'twofa_resend' }, method: :post, class: 'lost_password' if @twofa_view[:resendable] -%>
|
||
|
</label>
|
||
|
<%= text_field_tag :twofa_code, nil, tabindex: '1', autocomplete: 'off', autofocus: true -%>
|
||
|
<%= text_field_tag :twofa_code, nil, tabindex: '1', autocomplete: 'one-time-code', autofocus: true -%>
|
||
|
<%= submit_tag l(:button_login), tabindex: '2', id: 'login-submit', name: :submit_otp -%>
|
||
|
<% end %>
|
||
| app/views/twofa/_twofa_code_form.html.erb | ||
|---|---|---|
|
<div class="tabular">
|
||
|
<p>
|
||
|
<label for="twofa_code"><%=l 'twofa_label_code' -%></label>
|
||
|
<%= text_field_tag :twofa_code, nil, autocomplete: 'off' -%>
|
||
|
<%= text_field_tag :twofa_code, nil, autocomplete: 'one-time-code' -%>
|
||
|
</p>
|
||
|
</div>
|
||
|
</div>
|
||
| app/views/twofa/activate_confirm.html.erb | ||
|---|---|---|
|
<%= render partial: "twofa/#{@twofa_view[:scheme_name]}/new", locals: { twofa_view: @twofa_view } -%>
|
||
|
<p>
|
||
|
<label for="twofa_code"><%=l 'twofa_label_code' -%></label>
|
||
|
<%= text_field_tag :twofa_code, nil, autocomplete: 'off', autofocus: true -%>
|
||
|
<%= text_field_tag :twofa_code, nil, autocomplete: 'one-time-code', autofocus: true -%>
|
||
|
</p>
|
||
|
</div>
|
||
|
</div>
|
||