Uh oh!
There was an error while loading. Please reload this page.
feat(detail): relatedLayout 'tabs' — surface related tables as peer tabs via config - #2051
Merged
Conversation
The latest updates on your projects. Learn more about Vercel for GitHub. |
Contributor
✅ Console Performance Budget
📦 Bundle Size Report
Size Limits
|
…config
Record detail pages can now render each related table as its own top-level
tab instead of stacking them under a single "Related" tab, configured purely
via `detail.relatedLayout: 'tabs'` on the object (no custom page needed).
- buildDefaultPageSchema: new BuildPageOptions.relatedLayout ('stack' | 'tabs'),
threaded through buildDefaultTabs. 'tabs' emits one peer tab per related list
(label = title || objectName, carrying icon); 'stack' (default) preserves the
legacy single "Related" tab — zero regression. Still honours hideRelatedTab.
- RecordDetailView: reads objectDef.detail.relatedLayout per object and forwards
it to the synth.
- Tests: 4 new cases covering tabs layout, default stack, hideRelatedTab, and
Activity/History ordering after the per-table tabs.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for freeto join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Record detail pages can now render each related table as its own top-level tab instead of stacking them all inside a single Related tab — configured purely via
detail.relatedLayout: 'tabs'on the object. No custom page authoring required.Motivation: users with several related tables (e.g. a master plan with multiple child lists) want them surfaced as peer tabs rather than scrolling one long stacked Related tab. Today the only way to get tabbed related lists is to hand-author a
page:tabsrecord page.How
buildDefaultPageSchema(@object-ui/plugin-detail) — newBuildPageOptions.relatedLayout?: 'stack' | 'tabs', threaded throughbuildDefaultTabs(the single choke point for related-tab emission):'tabs'→ fans the related children out into one peer tab each (label = the related list'stitle, falling back toobjectName; carries itsicon), slotted between Details and Activity / History.'stack'(default) → keeps the legacy single Related tab. Zero regression when the option is omitted.hideRelatedTab(no related tabs emitted) in both modes.RecordDetailView(@object-ui/app-shell) — readsobjectDef.detail.relatedLayoutper object and forwards it to the synth (mirrors howhideRelatedTab/showReferenceRailare read).Usage
Tests
4 new cases in
buildDefaultPageSchema.test.ts:relatedLayoutis omittedhideRelatedTabvitest run(54 passed) +turbo type-check(plugin-detail + app-shell) green. The one preexistingno-emptylint error atRecordDetailView.tsx:191is unrelated to this change (present onmain).