Skip to content

Commit

Permalink
Merge pull request #28273 from nikolaynizruhin/5.8
Browse files Browse the repository at this point in the history
[5.8] Update auth stubs with @error blade directive
  • Loading branch information
taylorotwell authored Apr 20, 2019
2 parents 54401d1 + e83ae1d commit 48adeb6
Show file tree
Hide file tree
Showing 4 changed files with 32 additions and 32 deletions.
16 changes: 8 additions & 8 deletions src/Illuminate/Auth/Console/stubs/make/views/auth/login.stub
Original file line number Diff line number Diff line change
Expand Up @@ -15,27 +15,27 @@
<label for="email" class="col-md-4 col-form-label text-md-right">{{ __('E-Mail Address') }}</label>

<div class="col-md-6">
<input id="email" type="email" class="form-control{{ $errors->has('email') ? ' is-invalid' : '' }}" name="email" value="{{ old('email') }}" required autocomplete="email" autofocus>
<input id="email" type="email" class="form-control @error('email') is-invalid @enderror" name="email" value="{{ old('email') }}" required autocomplete="email" autofocus>

@if ($errors->has('email'))
@error('email')
<span class="invalid-feedback" role="alert">
<strong>{{ $errors->first('email') }}</strong>
<strong>{{ $message }}</strong>
</span>
@endif
@enderror
</div>
</div>

<div class="form-group row">
<label for="password" class="col-md-4 col-form-label text-md-right">{{ __('Password') }}</label>

<div class="col-md-6">
<input id="password" type="password" class="form-control{{ $errors->has('password') ? ' is-invalid' : '' }}" name="password" required autocomplete="current-password">
<input id="password" type="password" class="form-control @error('password') is-invalid @enderror" name="password" required autocomplete="current-password">

@if ($errors->has('password'))
@error('password')
<span class="invalid-feedback" role="alert">
<strong>{{ $errors->first('password') }}</strong>
<strong>{{ $message }}</strong>
</span>
@endif
@enderror
</div>
</div>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,13 @@
<label for="email" class="col-md-4 col-form-label text-md-right">{{ __('E-Mail Address') }}</label>

<div class="col-md-6">
<input id="email" type="email" class="form-control{{ $errors->has('email') ? ' is-invalid' : '' }}" name="email" value="{{ old('email') }}" required autocomplete="email" autofocus>
<input id="email" type="email" class="form-control @error('email') is-invalid @enderror" name="email" value="{{ old('email') }}" required autocomplete="email" autofocus>

@if ($errors->has('email'))
@error('email')
<span class="invalid-feedback" role="alert">
<strong>{{ $errors->first('email') }}</strong>
<strong>{{ $message }}</strong>
</span>
@endif
@enderror
</div>
</div>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,27 +17,27 @@
<label for="email" class="col-md-4 col-form-label text-md-right">{{ __('E-Mail Address') }}</label>

<div class="col-md-6">
<input id="email" type="email" class="form-control{{ $errors->has('email') ? ' is-invalid' : '' }}" name="email" value="{{ $email ?? old('email') }}" required autocomplete="email" autofocus>
<input id="email" type="email" class="form-control @error('email') is-invalid @enderror" name="email" value="{{ $email ?? old('email') }}" required autocomplete="email" autofocus>

@if ($errors->has('email'))
@error('email')
<span class="invalid-feedback" role="alert">
<strong>{{ $errors->first('email') }}</strong>
<strong>{{ $message }}</strong>
</span>
@endif
@enderror
</div>
</div>

<div class="form-group row">
<label for="password" class="col-md-4 col-form-label text-md-right">{{ __('Password') }}</label>

<div class="col-md-6">
<input id="password" type="password" class="form-control{{ $errors->has('password') ? ' is-invalid' : '' }}" name="password" required autocomplete="new-password">
<input id="password" type="password" class="form-control @error('password') is-invalid @enderror" name="password" required autocomplete="new-password">

@if ($errors->has('password'))
@error('password')
<span class="invalid-feedback" role="alert">
<strong>{{ $errors->first('password') }}</strong>
<strong>{{ $message }}</strong>
</span>
@endif
@enderror
</div>
</div>

Expand Down
24 changes: 12 additions & 12 deletions src/Illuminate/Auth/Console/stubs/make/views/auth/register.stub
Original file line number Diff line number Diff line change
Expand Up @@ -15,41 +15,41 @@
<label for="name" class="col-md-4 col-form-label text-md-right">{{ __('Name') }}</label>

<div class="col-md-6">
<input id="name" type="text" class="form-control{{ $errors->has('name') ? ' is-invalid' : '' }}" name="name" value="{{ old('name') }}" required autocomplete="name" autofocus>
<input id="name" type="text" class="form-control @error('name') is-invalid @enderror" name="name" value="{{ old('name') }}" required autocomplete="name" autofocus>

@if ($errors->has('name'))
@error('name')
<span class="invalid-feedback" role="alert">
<strong>{{ $errors->first('name') }}</strong>
<strong>{{ $message }}</strong>
</span>
@endif
@enderror
</div>
</div>

<div class="form-group row">
<label for="email" class="col-md-4 col-form-label text-md-right">{{ __('E-Mail Address') }}</label>

<div class="col-md-6">
<input id="email" type="email" class="form-control{{ $errors->has('email') ? ' is-invalid' : '' }}" name="email" value="{{ old('email') }}" required autocomplete="email">
<input id="email" type="email" class="form-control @error('email') is-invalid @enderror" name="email" value="{{ old('email') }}" required autocomplete="email">

@if ($errors->has('email'))
@error('email')
<span class="invalid-feedback" role="alert">
<strong>{{ $errors->first('email') }}</strong>
<strong>{{ $message }}</strong>
</span>
@endif
@enderror
</div>
</div>

<div class="form-group row">
<label for="password" class="col-md-4 col-form-label text-md-right">{{ __('Password') }}</label>

<div class="col-md-6">
<input id="password" type="password" class="form-control{{ $errors->has('password') ? ' is-invalid' : '' }}" name="password" required autocomplete="new-password">
<input id="password" type="password" class="form-control @error('password') is-invalid @enderror" name="password" required autocomplete="new-password">

@if ($errors->has('password'))
@error('password')
<span class="invalid-feedback" role="alert">
<strong>{{ $errors->first('password') }}</strong>
<strong>{{ $message }}</strong>
</span>
@endif
@enderror
</div>
</div>

Expand Down

0 comments on commit 48adeb6

Please sign in to comment.