Skip to content

Backport tab and heavy component lazy loading to 1.13 - #31037

Merged
shah-harshit merged 1 commit into
1.13from
ui/backport-28830-lazy-load-tabs-1.13
Aug 5, 2026
Merged

Backport tab and heavy component lazy loading to 1.13#31037
shah-harshit merged 1 commit into
1.13from
ui/backport-28830-lazy-load-tabs-1.13

Conversation

@shah-harshit

Copy link
Copy Markdown
Contributor

Summary

Tracking

Testing

  • git diff --check HEAD~1..HEAD

* feat(ui): split CustomizePageUtils.ts into 3 focused modules (#28937)

* feat(ui): split CustomizePageUtils.ts into 3 focused modules

Closes open-metadata/openmetadata-collate#4230

Splits 830-line CustomizePageUtils.ts (with 25 eager ClassBase imports)
into three focused files to eliminate unnecessary bundle weight on every
entity detail page:

- CustomizePageEntityTabUtils.ts  — tab display helpers (no ClassBase deps)
  sortTabs, getTabDisplayName, getTabLabelMapFromTabs,
  checkIfExpandViewSupported, getDetailsTabWithNewLabel

- CustomizePageDispatchUtils.ts   — dispatch/admin flow helpers (keeps all
  25 ClassBase singletons; only imported by admin/customize pages)
  getDefaultTabs, getDefaultWidgetForTab, getCustomizableWidgetByPage,
  getDummyDataByPage, getWidgetsFromKey, getWidgetHeight,
  getGlossaryTermDefaultTabs, getGlossaryDefaultTabs

- CustomizePageWidgetUtils.ts     — widget/layout helpers (no ClassBase deps)
  getAddWidgetHandler, updateWidgetHeightRecursively,
  getLayoutFromCustomizedPage, asyncNoop

CustomizePageUtils.ts deleted; all ~50 consumer files updated to import
directly from the correct split module. No re-export facade.

Test mocks updated: removed stale mock blocks on wrong paths (previously
mocking CustomizePageUtils which had no effect once consumers moved to
CustomizePagePureUtils); added correct mocks on CustomizePagePureUtils
for FileClassBase and DirectoryClassBase tests.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* fix checkstyle

---------

Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>

* feat(ui): lazy-load tab-level and heavy components with withSuspenseFallback (#28830)

* feat(ui): lazy-load tab-level and heavy components with withSuspenseFallback

Convert 105 component/util files from eager imports to React.lazy() +
withSuspenseFallback() for heavy components: SchemaEditor, ActivityFeedTab,
ContractTab, CustomPropertyTable, TaskTabNew, EntitySummaryPanel,
ModalWithMarkdownEditor, BlockEditor, CodeEditor, and others.

Lazy constants are placed after all traditional imports. Removed eager
component imports are replaced with import type for props interfaces where
applicable. Zero TypeScript errors introduced.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* fix failing test

* fix failing test

* improve performance

* update

* address comments

* fix failing e2e tests

* fix failing tests

* Fix failing tests

* fix failing test

* address comments

* fix ui checkstyle

* fix query page import

* fix checkstyle

---------

Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>

* fix(ui): use reachable my data loading state

---------

Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
(cherry picked from commit 159cee8)
@shah-harshit
shah-harshit requested a review from a team as a code owner August 5, 2026 12:38
@shah-harshit shah-harshit added UI UI specific issues safe to test Add this label to run secure Github workflows on PRs skip-pr-checks Bypass PR metadata validation check labels Aug 5, 2026
@shah-harshit shah-harshit self-assigned this Aug 5, 2026
@greptile-apps

greptile-apps Bot commented Aug 5, 2026

Copy link
Copy Markdown
Contributor

Too many files changed for review (134 files, 100 file limit).

Bypass the limit by tagging @greptile-apps to review.

@gitar-bot

gitar-bot Bot commented Aug 5, 2026

Copy link
Copy Markdown
Code Review ✅ Approved

Backports tab and heavy component lazy loading to branch 1.13 to improve UI performance. No issues found.

Options

Display: compact → Showing less information.

Comment with these commands to change the behavior for this request:

Compact
gitar display:verbose         

Was this helpful? React with 👍 / 👎 | Gitar | Powered by Gitar — free for open source

@shah-harshit
shah-harshit merged commit ca2b762 into 1.13 Aug 5, 2026
76 of 137 checks passed
@shah-harshit
shah-harshit deleted the ui/backport-28830-lazy-load-tabs-1.13 branch August 5, 2026 15:00
aniketkatkar97 added a commit that referenced this pull request Aug 6, 2026
Resolves the conflict in RightPanelPageObject.navigateToTab: ca2b762
(#31037) fixed the same strict-mode violation upstream with
`expect(this.pageLoader).toHaveCount(0, { timeout: 10000 })`, which is
equivalent to the waitForAllLoadersToDisappear() call this branch added.
Take upstream's file verbatim so the branch no longer touches it.

Also defers to upstream on the IntakeFormCustomPropertyFields race:
40d31ce (#30910) isolated that spec in its own post-chromium project.
Restore the file and keep that project, so this branch only converts it to
read the shared fixtures instead of creating custom properties, rather than
merging it away.

Adopt the same pattern for the one test that must create and delete custom
properties AND a singleton intake form. Extracted from CustomProperties.spec.ts
into CustomPropertyIntakeFormCascade.spec.ts with its own post-chromium
project: no single spec file serialises both resources, but running after
chromium makes it the sole writer of either.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

safe to test Add this label to run secure Github workflows on PRs skip-pr-checks Bypass PR metadata validation check UI UI specific issues

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant