Skip to content

Commit

Permalink
Fix styling
Browse files Browse the repository at this point in the history
  • Loading branch information
lee-to authored and github-actions[bot] committed Sep 18, 2023
1 parent 056de43 commit 6335656
Show file tree
Hide file tree
Showing 8 changed files with 11 additions and 8 deletions.
6 changes: 4 additions & 2 deletions src/Commands/InstallCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,13 @@
namespace MoonShine\Commands;

use Illuminate\Contracts\Filesystem\FileNotFoundException;
use MoonShine\MoonShine;
use MoonShine\Providers\MoonShineServiceProvider;

use function Laravel\Prompts\{confirm, intro, outro, spin, warning};

use MoonShine\MoonShine;

use MoonShine\Providers\MoonShineServiceProvider;

class InstallCommand extends MoonShineCommand
{
protected $signature = 'moonshine:install';
Expand Down
2 changes: 1 addition & 1 deletion src/Fields/Json.php
Original file line number Diff line number Diff line change
Expand Up @@ -342,7 +342,7 @@ protected function resolveOnApply(): ?Closure
)->delete()
);

$items->each(fn($data) => $item->{$this->column()}()->updateOrCreate(
$items->each(fn ($data) => $item->{$this->column()}()->updateOrCreate(
[$localKey => $data[$localKey] ?? null],
$data
));
Expand Down
1 change: 1 addition & 0 deletions src/Traits/Fields/WithAsyncSearch.php
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ public function valuesWithProperties(bool $onlyCustom = false): Collection

return $this->getMemoizeValues()->mapWithKeys(function (Model $item) use ($onlyCustom): array {
$properties = $this->asyncResponseData($item);

return [
$item->getKey() => $onlyCustom
? data_get($properties, 'customProperties')
Expand Down
1 change: 0 additions & 1 deletion src/Traits/Fields/WithSorts.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@

trait WithSorts
{

protected bool $sortable = false;

/**
Expand Down
2 changes: 1 addition & 1 deletion tests/Fixtures/Models/Comment.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ class Comment extends Model
];

protected $casts = [
'data' => 'collection'
'data' => 'collection',
];

public function item(): BelongsTo
Expand Down
2 changes: 1 addition & 1 deletion tests/Fixtures/Models/Item.php
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ class Item extends Model
];

protected $casts = [
'data' => 'collection'
'data' => 'collection',
];

public function category(): BelongsTo
Expand Down
3 changes: 2 additions & 1 deletion tests/Pest.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,11 @@
use MoonShine\Tests\Fixtures\Factories\ItemFactory;
use MoonShine\Tests\TestCase;
use Pest\Expectation;
use Symfony\Component\HttpFoundation\Request as SymfonyRequest;

use function Pest\Laravel\actingAs;

use Symfony\Component\HttpFoundation\Request as SymfonyRequest;

uses(TestCase::class)
->in(__DIR__);

Expand Down
2 changes: 1 addition & 1 deletion tests/Unit/Fields/SwitchBooleanFieldTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
});

it('preview with auto update', function (): void {
expect($this->field->updateOnPreview(fn() => '/')->preview())
expect($this->field->updateOnPreview(fn () => '/')->preview())
->toBe(
view('moonshine::fields.switch', [
'element' => $this->field,
Expand Down

0 comments on commit 6335656

Please sign in to comment.