Why my admin doesn’t work after adding rest_prepare_post filter?

The new block editor uses the REST API and by modifying the rest response through the rest_prepare_post filter you compromise the expected data set. I suspect that’s the case here, since you’re modifying all the responses for the post post type, without any conditional restrictions.

Consider creating your own custom route where you can modify the response to your needs without affecting the core/plugin/app use of the builtin REST API routes. You could also consider e.g. the _embed query parameter to get extra information about the category and the featured image.