mirror of
https://github.com/filamentphp/filament.git
synced 2026-08-29 03:09:12 +08:00
11ef6c6a88
* feat: add deferred badge loading for relation manager tabs Extends the deferred tab badge loading introduced in PR #19336 to relation manager tabs, fixing two upstream issues: 1. `RelationManager::getTabComponent()` was evaluating `getBadge()` eagerly before the deferred mechanism could intercept it. 2. `HasRelationManagers::getRelationManagersContentComponent()` built `Tabs::make()` with no key, causing `callSchemaComponentMethod()` to receive null when the async badge fetch fired. Changes: - Add `protected static bool $deferBadge = false` to `RelationManager` with an overrideable `isBadgeDeferred()` method for per-record control - Add fluent `->deferBadge()` and `isBadgeDeferred()` to `RelationGroup` - Add `->key('relationManagerTabs')` to the `Tabs` built in `HasRelationManagers` - Add docs and tests Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> * cleanup --------- Co-authored-by: buzkall <buzkall@users.noreply.github.com> Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com> Co-authored-by: Dan Harrin <git@danharrin.com>