diff options
Diffstat (limited to 'resources/views')
-rw-r--r-- | resources/views/trainer.blade.php | 22 | ||||
-rw-r--r-- | resources/views/user/create.blade.php | 8 | ||||
-rw-r--r-- | resources/views/user/top.blade.php | 10 |
3 files changed, 35 insertions, 5 deletions
diff --git a/resources/views/trainer.blade.php b/resources/views/trainer.blade.php index 861b28f..5085104 100644 --- a/resources/views/trainer.blade.php +++ b/resources/views/trainer.blade.php @@ -66,6 +66,28 @@ use HebrewParseTrainer\Tense; <button type="button" class="btn btn-default btn-xs" id="show-hide-help">Show help</button> </div> +<hr/> + +<div class="row"> + <div class="col-md-6"> + @include('user.top') + </div> + <div class="col-md-6"> + <div class="panel panel-default"> + <div class="panel-heading"> + <h3 class="panel-title">Contribute!</h3> + </div> + <div class="panel-body"> + <p>If this app is useful to you, please consider <a href="{{ env('APP_URL') }}contribute">contributing</a> by adding more verbs to the database!</p> + @if(!Auth::check()) + <a class="btn btn-success" href="{{ env('APP_URL') }}user/create">Sign up</a> + or <a href="{{ env('APP_URL') }}contribute?login=yes">login</a> + @endif + </div> + </div> + </div> +</div> + <script type="text/javascript"> var reload_on_load = true; </script> diff --git a/resources/views/user/create.blade.php b/resources/views/user/create.blade.php index 818a20a..b823451 100644 --- a/resources/views/user/create.blade.php +++ b/resources/views/user/create.blade.php @@ -9,12 +9,14 @@ <form method="post"> <div class="form-group"> - <label for="create-user-email">Email address</label> - <input type="email" class="form-control" id="create-user-email" placeholder="Email" name="email" value="{{{ $form['email'] }}}"/> + <label for="create-user-email">Email address (private)</label> + <input type="email" class="form-control" id="create-user-email" placeholder="Email" name="email" value="{{{ $form['email'] }}}" aria-describedby="create-user-email-help"/> + <span id="create-user-email-help" class="help-block">You will not receive any automated email from us, but we like to have some way of contacting you available. Your email address will not be shared with third parties, and will not be visible to users of the website.</span> </div> <div class="form-group"> <label for="create-user-name">Username</label> - <input type="text" class="form-control" id="create-user-name" placeholder="Username" name="name" value="{{{ $form['name'] }}}"/> + <input type="text" class="form-control" id="create-user-name" placeholder="Username" name="name" value="{{{ $form['name'] }}}" aria-describedby="create-user-name-help"/> + <span id="create-user-name-help" class="help-block">Your name as shown on the site.</span> </div> <div class="form-group"> <label for="create-user-pw1">Password</label> diff --git a/resources/views/user/top.blade.php b/resources/views/user/top.blade.php index 52973e6..4bc71c6 100644 --- a/resources/views/user/top.blade.php +++ b/resources/views/user/top.blade.php @@ -1,9 +1,10 @@ <?php use HebrewParseTrainer\User; ?> +@if(count(User::all()) > 0) <div class="panel panel-default"> <div class="panel-heading"> - <h3 class="panel-title">Top users</h3> + <h3 class="panel-title">Top contributors</h3> </div> <div class="panel-body"> <table class="table table-hover"> @@ -15,7 +16,7 @@ use HebrewParseTrainer\User; </tr> </thead> <tbody> - @foreach(User::orderBy('points', 'desc')->take(10)->get() as $user) + @foreach(User::orderBy('points', 'desc')->take(3)->get() as $user) <tr> <td><img src="https://gravatar.com/avatar/{{ md5(strtolower(trim($user->email))) }}?s=40"/></td> <td>{{{ $user->name }}}</td> @@ -24,5 +25,10 @@ use HebrewParseTrainer\User; @endforeach </tbody> </table> + + @if(Auth::check()) + <p>You have {{ Auth::user()->points }} points.</p> + @endif </div> </div> +@endif |