<% # Copyright (C) 2011 - present Instructure, Inc. # # This file is part of Canvas. # # Canvas is free software: you can redistribute it and/or modify it under # the terms of the GNU Affero General Public License as published by the Free # Software Foundation, version 3 of the License. # # Canvas is distributed in the hope that it will be useful, but WITHOUT ANY # WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR # A PARTICULAR PURPOSE. See the GNU Affero General Public License for more # details. # # You should have received a copy of the GNU Affero General Public License along # with this program. If not, see . %> <% js_bundle :mobile_login %> <% extend Api::V1::Account %> <% unique_id = begin params[:login_hint]&.to_s || params.dig(:pseudonym_session, :unique_id)&.to_s rescue TypeError nil end %>
<%= t 'Canvas by Instructure' %>
<%= form_for :pseudonym_session, :url => url_for({ action: :create }.merge(params.slice(:id).to_unsafe_h)), :html => {:id => "login_form", :class => "front face", :novalidate => 'novalidate', :autocomplete => "off" } do |f| %>
" />
<% if request.post? && flash[:error] %> <% end %>
<% if url = params[:canvas_login].blank? && @domain_root_account.try(:forgot_password_external_url) %> <%= link_to t('dont_know_password', "Forgot Password?"), url, :class => 'forgot-password' %> <% else %> <%= t('dont_know_password', "Forgot Password?") %> <% end %>
<% end %> <%= form_for :pseudonym_session, :url => forgot_password_path, :html => {:id => "forgot_password_form", :class => 'back face', :autocomplete => "off" } do |f| %>
<%= t('back_to_login', "Back to Login") %>
<% end %> <% if @domain_root_account && @domain_root_account.self_registration? %> <% if @domain_root_account.self_registration_type == 'observer' %> <% js_env :ACCOUNT => account_json(@domain_root_account, nil, session, ['registration_settings']), :PASSWORD_POLICY => @domain_root_account.password_policy %> <% else %> <% end %> <% end %>