Typing of getOwnerRecord and Filament::getTenant()

I'm currently using larastan to make sure my code is clean and fully typed, but i find myself to have to do a lot of code comments to make sure the code is properly typed both for my editor and larastan. I'm talking about stuff like this:
             ->hidden(function (RelationManager $livewire) {
                        /** @var Product $product */
                        $product = $livewire->getOwnerRecord();
                        return $product->packages->count() < 2;
                    })


and
            Actions\CreateAction::make()
                ->hidden(function () {
                    /** @var Organization $organization */
                    $organization = Filament::getTenant();

is there any way to improve this, and be able to directly used Filament::getTenant and have it typed?
Was this page helpful?