unrhodecode/rhodecode/templates/register.mako
russell@unturf.com 722c3bd369 Prototype: OTP auth, styleguide overhaul, login/session rework
Replace password reset with email OTP verification flow.
Add auth_otp module, OTP templates, and email delivery.
Expand styleguide CSS with full component library.
Rework login, register, and admin views for cookie sessions.
Remove legacy 2FA templates and password reset flow.
Update SSH wrappers, forms, validators, and middleware.
2026-03-04 16:44:40 -05:00

87 lines
3.1 KiB
Mako

<%inherit file="base/root.mako"/>
<%def name="title()">
${_('Create an Account')}
%if c.rhodecode_name:
&middot; ${h.branding(c.rhodecode_name)}
%endif
</%def>
<div class="loginbox">
<div class="header-account">
<div id="header-inner" class="title">
<div id="logo">
<div class="logo-wrapper">
<a href="${h.route_path('home')}"><img src="${h.asset('images/rhodecode-logo-white-60x60.png')}" alt="RhodeCode"/></a>
</div>
% if c.rhodecode_name:
<div class="branding">
<a href="${h.route_path('home')}">${h.branding(c.rhodecode_name)}</a>
</div>
% endif
</div>
</div>
</div>
<rhodecode-toast id="notifications"></rhodecode-toast>
<div class="loginwrapper">
<div class="auth-image-wrapper">
<img class="sign-in-image" src="${h.asset('images/sign-in.png')}" alt="RhodeCode"/>
</div>
<div id="register">
<%block name="above_register_button" />
<div class="sign-in-title">
<h1>${_('Create an account')}</h1>
<h4>${h.link_to(_("Go to the login page to sign in with an existing account."), request.route_path('login'))}</h4>
</div>
<div class="inner form">
${h.form(request.route_path('register'), needs_csrf_token=False)}
<label for="email">${_('Email address')}:</label>
${h.text('email', defaults.get('email'), class_='focus')}
%if 'email' in errors:
<span class="error-message">${errors.get('email')}</span>
<br />
%endif
%if captcha_active:
<div>
<label for="recaptcha">${_('Captcha')}:</label>
${h.hidden('recaptcha_field')}
<div id="recaptcha"></div>
%if 'recaptcha_field' in errors:
<span class="error-message">${errors.get('recaptcha_field')}</span>
<br />
%endif
</div>
%endif
%if not auto_active:
<p class="activation_msg">
${_('Account activation requires admin approval.')}
</p>
%endif
<p class="register_message">
${register_message|n}
</p>
${h.submit('sign_up', _('Send code'), class_="btn sign-in", title=_('Send verification code'))}
${h.end_form()}
</div>
<%block name="below_register_button" />
</div>
</div>
</div>
% if captcha_active:
<script type="text/javascript">
var onloadCallback = function() {
grecaptcha.render('recaptcha', {
'sitekey' : "${captcha_public_key}"
});
};
</script>
<script src="https://www.google.com/recaptcha/api.js?onload=onloadCallback&render=explicit" async defer></script>
% endif