diff --git a/CHANGELOG.md b/CHANGELOG.md index a941ff68e..71bb5b13c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,17 @@ # Release Notes -## [Unreleased](https://github.com/laravel/jetstream/compare/v2.3.6...2.x) +## [Unreleased](https://github.com/laravel/jetstream/compare/v2.3.7...2.x) + + +## [v2.3.7 (2021-06-01)](https://github.com/laravel/jetstream/compare/v2.3.6...v2.3.7) + +### Changed +- Allow Role's `$name` and `$description` to be translated ([#798](https://github.com/laravel/jetstream/pull/798)) + +### Fixed +- Remove dark classes from QR Code ([#788](https://github.com/laravel/jetstream/pull/788)) +- Changed the column type of profile_photo_path ([#794](https://github.com/laravel/jetstream/pull/794)) +- Fix cors policy errors with inertia stack ([#797](https://github.com/laravel/jetstream/pull/797)) ## [v2.3.6 (2021-05-18)](https://github.com/laravel/jetstream/compare/v2.3.5...v2.3.6) diff --git a/database/factories/TeamFactory.php b/database/factories/TeamFactory.php index 0d3cf824b..abfd9d9fc 100644 --- a/database/factories/TeamFactory.php +++ b/database/factories/TeamFactory.php @@ -23,7 +23,7 @@ class TeamFactory extends Factory public function definition() { return [ - 'name' => $this->faker->unique()->company, + 'name' => $this->faker->unique()->company(), 'user_id' => User::factory(), 'personal_team' => true, ]; diff --git a/database/factories/UserFactory.php b/database/factories/UserFactory.php index cb5b70649..87058985d 100644 --- a/database/factories/UserFactory.php +++ b/database/factories/UserFactory.php @@ -25,8 +25,8 @@ class UserFactory extends Factory public function definition() { return [ - 'name' => $this->faker->name, - 'email' => $this->faker->unique()->safeEmail, + 'name' => $this->faker->name(), + 'email' => $this->faker->unique()->safeEmail(), 'email_verified_at' => now(), 'password' => '$2y$10$92IXUNpkjO0rOQ5byMi.Ye4oKoEa3Ro9llC/.og/at2.uheWG/igi', // password 'remember_token' => Str::random(10), diff --git a/database/migrations/2014_10_12_000000_create_users_table.php b/database/migrations/2014_10_12_000000_create_users_table.php index dfad67ba3..259df0939 100644 --- a/database/migrations/2014_10_12_000000_create_users_table.php +++ b/database/migrations/2014_10_12_000000_create_users_table.php @@ -21,7 +21,7 @@ public function up() $table->string('password'); $table->rememberToken(); $table->foreignId('current_team_id')->nullable(); - $table->text('profile_photo_path')->nullable(); + $table->string('profile_photo_path', 2048)->nullable(); $table->timestamps(); }); } diff --git a/src/Role.php b/src/Role.php index 7fcb431a6..462c4864c 100644 --- a/src/Role.php +++ b/src/Role.php @@ -71,8 +71,8 @@ public function jsonSerialize() { return [ 'key' => $this->key, - 'name' => $this->name, - 'description' => $this->description, + 'name' => __($this->name), + 'description' => __($this->description), 'permissions' => $this->permissions, ]; } diff --git a/stubs/inertia/resources/js/Pages/Profile/TwoFactorAuthenticationForm.vue b/stubs/inertia/resources/js/Pages/Profile/TwoFactorAuthenticationForm.vue index c533cca19..54e9f1ce9 100644 --- a/stubs/inertia/resources/js/Pages/Profile/TwoFactorAuthenticationForm.vue +++ b/stubs/inertia/resources/js/Pages/Profile/TwoFactorAuthenticationForm.vue @@ -31,7 +31,7 @@

-
+
diff --git a/stubs/inertia/resources/views/app.blade.php b/stubs/inertia/resources/views/app.blade.php index 8c5f22756..19f1b10f8 100644 --- a/stubs/inertia/resources/views/app.blade.php +++ b/stubs/inertia/resources/views/app.blade.php @@ -19,5 +19,9 @@ @inertia + + @env ('local') + + @endenv diff --git a/stubs/livewire/resources/views/profile/two-factor-authentication-form.blade.php b/stubs/livewire/resources/views/profile/two-factor-authentication-form.blade.php index eafa26446..88d8f3865 100644 --- a/stubs/livewire/resources/views/profile/two-factor-authentication-form.blade.php +++ b/stubs/livewire/resources/views/profile/two-factor-authentication-form.blade.php @@ -30,7 +30,7 @@

-
+
{!! $this->user->twoFactorQrCodeSvg() !!}
@endif diff --git a/stubs/tests/PasswordResetTest.php b/stubs/tests/PasswordResetTest.php index 8e408a174..d09261ccc 100644 --- a/stubs/tests/PasswordResetTest.php +++ b/stubs/tests/PasswordResetTest.php @@ -6,6 +6,7 @@ use Illuminate\Auth\Notifications\ResetPassword; use Illuminate\Foundation\Testing\RefreshDatabase; use Illuminate\Support\Facades\Notification; +use Laravel\Fortify\Features; use Tests\TestCase; class PasswordResetTest extends TestCase @@ -14,6 +15,10 @@ class PasswordResetTest extends TestCase public function test_reset_password_link_screen_can_be_rendered() { + if (! Features::enabled(Features::updatePasswords())) { + return $this->markTestSkipped('Password updates are not enabled.'); + } + $response = $this->get('/forgot-password'); $response->assertStatus(200); @@ -21,6 +26,10 @@ public function test_reset_password_link_screen_can_be_rendered() public function test_reset_password_link_can_be_requested() { + if (! Features::enabled(Features::updatePasswords())) { + return $this->markTestSkipped('Password updates are not enabled.'); + } + Notification::fake(); $user = User::factory()->create(); @@ -34,6 +43,10 @@ public function test_reset_password_link_can_be_requested() public function test_reset_password_screen_can_be_rendered() { + if (! Features::enabled(Features::updatePasswords())) { + return $this->markTestSkipped('Password updates are not enabled.'); + } + Notification::fake(); $user = User::factory()->create(); @@ -53,6 +66,10 @@ public function test_reset_password_screen_can_be_rendered() public function test_password_can_be_reset_with_valid_token() { + if (! Features::enabled(Features::updatePasswords())) { + return $this->markTestSkipped('Password updates are not enabled.'); + } + Notification::fake(); $user = User::factory()->create();