Z3d0X / filament-fabricator

Block-Based Page Builder Skeleton for your Filament Apps
https://filamentphp.com/plugins/fabricator
MIT License
251 stars 48 forks source link

Undefined array key "type" when removing blocks from the page #144

Closed webspilka closed 3 months ago

webspilka commented 4 months ago

hi my stacktrace: https://flareapp.io/share/v5pba3lP

I use filament v3.2.44 livewire/liveire v3.4.7 spatie/laravel-translatable v.6.6.2 z3d0x/filament-fabricator v2.1.1 filament/spatie-laravel-translatable-plugin v3.2.44

I was so happy when I connected everything and the translation worked. But after a while I found the problem. Unfortunately, removing blocks from the page does not work

When I delete block and push save, I get error

Undefined array key "type"
Screenshot 2024-03-07 at 13 27 47
webspilka commented 3 months ago

At first, I thought the issue arose due to the plugin "filament/spatie-laravel-translatable-plugin": "^3.2", being connected. However, upon disconnecting thtis plugin, I encountered the same problem.

I began testing different scenarios and found that everything hinges on the Filament\Forms\Components\RichEditor. If the RichEditor field contains text, then upon deleting the block and saving the page, I receive an error. If I first clear the RichEditor of text and then delete the block, everything works without issues.

https://github.com/Z3d0X/filament-fabricator/assets/1138069/e0527034-bb33-489c-a8ba-88d27ffa7e59

I see that a similar issue was present before: https://github.com/filamentphp/filament/issues/7957

zepfietje commented 3 months ago

https://github.com/filamentphp/filament/pull/11833

Z3d0X commented 3 months ago

Issue addressed in filament core