1{{--
2 Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the GNU Affero General Public License v3.0.
3 See the LICENCE file in the repository root for full licence text.
4--}}
5@php
6 $params = get_params(request()->all(), null, [
7 'username',
8 'email',
9 ], ['null_missing' => true]);
10 $focus = $params['username'] === null ? 'username' : 'password';
11@endphp
12
13@extends('master')
14
15@section('content')
16 @include('layout._page_header_v4')
17 <div class="osu-page osu-page--generic">
18 <form
19 action="{{ route('users.store-web') }}"
20 class="simple-form simple-form--user-create js-form-error js-captcha--reset-on-error"
21 data-remote="1"
22 data-skip-ajax-error-popup="1"
23 method="POST"
24 >
25 <label class="simple-form__row js-form-error--field">
26 <div class="simple-form__label">
27 {{ osu_trans('users.create.form.username') }}
28 </div>
29
30 <input
31 class="simple-form__input"
32 name="user[username]"
33 required
34 value="{{ $params['username'] }}"
35 {{ $focus === 'username' ? 'autofocus' : '' }}
36 >
37 <div class="simple-form__error js-form-error--error"></div>
38 </label>
39
40 <label class="simple-form__row js-form-error--field">
41 <div class="simple-form__label">
42 {{ osu_trans('users.create.form.password') }}
43 </div>
44
45 <input
46 class="simple-form__input js-form-confirmation"
47 name="user[password]"
48 type="password"
49 required
50 {{ $focus === 'password' ? 'autofocus' : '' }}
51 >
52 <div class="simple-form__error js-form-error--error"></div>
53 </label>
54
55 <label class="simple-form__row js-form-error--field">
56 <div class="simple-form__label">
57 {{ osu_trans('users.create.form.password_confirmation') }}
58 </div>
59
60 <input
61 class="simple-form__input js-form-confirmation"
62 name="user[password_confirmation]"
63 type="password"
64 required
65 >
66 <div class="simple-form__error js-form-error--error"></div>
67 </label>
68
69 <label class="simple-form__row js-form-error--field">
70 <div class="simple-form__label">
71 {{ osu_trans('users.create.form.user_email') }}
72 </div>
73
74 <input
75 class="simple-form__input js-form-confirmation"
76 name="user[user_email]"
77 required
78 type="email"
79 value="{{ $params['email'] }}"
80 >
81 <div class="simple-form__error js-form-error--error"></div>
82 </label>
83
84 <label class="simple-form__row js-form-error--field">
85 <div class="simple-form__label">
86 {{ osu_trans('users.create.form.user_email_confirmation') }}
87 </div>
88
89 <input
90 class="simple-form__input js-form-confirmation"
91 name="user[user_email_confirmation]"
92 required
93 type="email"
94 value="{{ $params['email'] }}"
95 >
96 <div class="simple-form__error js-form-error--error"></div>
97 </label>
98
99 @if (captcha_enabled())
100 <div
101 class="simple-form__row simple-form__row--no-label"
102 >
103 <div
104 class="simple-form__captcha js-captcha--container"
105 data-captcha-triggered="1"
106 ></div>
107 </div>
108 @include('objects._captcha_script')
109 @endif
110
111 <div class="simple-form__row simple-form__row--no-label">
112 <div class="simple-form__buttons">
113 <div class="simple-form__button">
114 <button
115 class="btn-osu-big btn-osu-big--rounded-thin js-captcha--submit-button"
116 type="submit"
117 >
118 {{ osu_trans('users.create.form.submit') }}
119 </button>
120 </div>
121 </div>
122 </div>
123 <div class="simple-form__row simple-form__row--no-label">
124 <p>
125 {!! osu_trans('users.create.form.tos_notice._', [
126 'link' => link_to(
127 route('legal', ['locale' => app()->getLocale(), 'path' => 'Terms']),
128 osu_trans('users.create.form.tos_notice.link'),
129 ['target' => '_blank']
130 ),
131 ]) !!}
132 </p>
133 </div>
134 </form>
135 </div>
136@endsection