Repository navigation
Fixes #6896, #6897: Migrate antd Skeleton and Divider to core components - #34264
Conversation
Replace every antd Skeleton/Divider import in the OSS UI with the ui-core-components Skeleton, SkeletonParagraph and Divider. antd default margins/sizes are reproduced with tw: classes so the light theme stays unchanged, and LESS rules that targeted .ant-divider/.ant-skeleton on the migrated elements are ported or removed.
✅ Playwright Results — workflow succeededValidated commit ✅ 4685 passed · ❌ 0 failed · 🟡 1 flaky · ⏭️ 1 skipped · 🧰 0 lifecycle flaky PerformanceBlocking targets: ✅ met · Optimization targets: 🟡 in progress Shard-job maxima below are not the full workflow wall time; the linked run includes build, fixture, planning, and reporting. 🕒 Full workflow signal wall (to summary) 1h 57m 14s ⏱️ Max setup 5m 1s · max shard execution 19m 21s · max shard-job elapsed before upload 23m 21s · reporting 19s 🌐 222.61 requests/attempt · 2.20 app boots/UI scenario · 34.63% common-shard skew Optimization targets still in progress:
🟡 1 flaky test(s) (passed on retry)
How to debug locally# Download playwright-test-results-<shard> artifact and unzip
npx playwright show-trace path/to/trace.zip # view trace |
|
| Count | Rule |
|---|---|
| 151 | react-hooks/exhaustive-deps |
| 31 | no-restricted-imports |
| 8 | openmetadata-imports/no-lower-layer-page-imports |
| 6 | openmetadata-imports/review-sequential-api-calls |
| 2 | openmetadata-imports/no-circular-imports |
| 1 | openmetadata-imports/no-cross-page-imports |
All findings
| Location | Rule | Message | |
|---|---|---|---|
| 🟡 | src/components/Alerts/AlertDetails/AlertConfigDetails/AlertConfigDetails.tsx:29:1 |
openmetadata-imports/no-lower-layer-page-imports |
Pages are route-level composition modules. Move the shared implementation/type to a lower layer instead of importing a page from here. |
| 🟡 | src/components/Alerts/AlertDetails/AlertConfigDetails/AlertConfigDetails.tsx:108:6 |
react-hooks/exhaustive-deps |
React Hook useCallback has a missing dependency: 't'. Either include it or remove the dependency array. |
| 🟡 | src/components/Alerts/AlertDetails/AlertConfigDetails/AlertConfigDetails.tsx:139:6 |
react-hooks/exhaustive-deps |
React Hook useCallback has missing dependencies: 'getResourcePermission' and 't'. Either include them or remove the dependency array. |
| 🟡 | src/components/Alerts/AlertDetails/AlertConfigDetails/AlertConfigDetails.tsx:145:6 |
react-hooks/exhaustive-deps |
React Hook useEffect has a missing dependency: 'fetchTemplates'. Either include it or remove the dependency array. |
| 🟡 | src/components/Alerts/AlertDetails/AlertConfigDetails/AlertConfigDetails.tsx:149:6 |
react-hooks/exhaustive-deps |
React Hook useEffect has a missing dependency: 'fetchFunctions'. Either include it or remove the dependency array. Outer scope values like 'Fqn' aren't valid de |
| 🟡 | src/components/Alerts/AlertDetails/AlertDiagnosticInfo/AlertDiagnosticInfoTab.tsx:49:6 |
react-hooks/exhaustive-deps |
React Hook useEffect has a missing dependency: 'fetchDiagnosticInfo'. Either include it or remove the dependency array. |
| 🟡 | src/components/Alerts/AlertDetails/AlertRecentEventsTab/AlertRecentEventsTab.tsx:97:5 |
react-hooks/exhaustive-deps |
React Hook useCallback has an unnecessary dependency: 'filter'. Either exclude it or remove the dependency array. |
| 🟡 | src/components/Alerts/AlertDetails/AlertRecentEventsTab/AlertRecentEventsTab.tsx:311:6 |
react-hooks/exhaustive-deps |
React Hook useMemo has missing dependencies: 'paging' and 't'. Either include them or remove the dependency array. |
| 🟡 | src/components/Alerts/AlertDetails/AlertRecentEventsTab/AlertRecentEventsTab.tsx:324:6 |
react-hooks/exhaustive-deps |
React Hook useEffect has a missing dependency: 'getAlertRecentEvents'. Either include it or remove the dependency array. |
| 🟡 | src/components/DataContract/ContractSLACard/ContractSLA.component.tsx:182:6 |
react-hooks/exhaustive-deps |
React Hook useMemo has a missing dependency: 't'. Either include it or remove the dependency array. |
| 🟡 | src/components/DataContract/ContractSecurity/ContractSecurityCard.component.tsx:129:6 |
react-hooks/exhaustive-deps |
React Hook useMemo has missing dependencies: 't' and 'tableColumnNameMap'. Either include them or remove the dependency array. |
| 🟡 | src/components/DataContract/ContractSecurityFormTab/ContractSecurityFormTab.tsx:419:5 |
react-hooks/exhaustive-deps |
React Hook useCallback has missing dependencies: 'dataClassificationFormItem', 'form', and 'onChange'. Either include them or remove the dependency array. If 'o |
| 🟡 | src/components/DataContract/ContractSecurityFormTab/ContractSecurityFormTab.tsx:454:6 |
react-hooks/exhaustive-deps |
React Hook useEffect has a missing dependency: 'form'. Either include it or remove the dependency array. |
| 🟡 | src/components/DataProducts/InputOutputPortsTab/PortsListView/PortsListView.component.tsx:176:8 |
react-hooks/exhaustive-deps |
React Hook useEffect has a missing dependency: 'fetchPorts'. Either include it or remove the dependency array. |
| 🟡 | src/components/DataQuality/AddTestCaseList/AddTestCaseList.component.tsx:290:34 |
react-hooks/exhaustive-deps |
React Hook useCallback received a function whose dependencies are unknown. Pass an inline function instead. |
| 🟡 | src/components/DataQuality/AddTestCaseList/AddTestCaseList.component.tsx:323:35 |
react-hooks/exhaustive-deps |
React Hook useCallback received a function whose dependencies are unknown. Pass an inline function instead. |
| 🟡 | src/components/DataQuality/AddTestCaseList/AddTestCaseList.component.tsx:668:6 |
react-hooks/exhaustive-deps |
React Hook useEffect has a missing dependency: 'fetchTestCases'. Either include it or remove the dependency array. |
| 🟡 | src/components/DataQuality/AddTestCaseList/AddTestCaseList.component.tsx:693:5 |
react-hooks/exhaustive-deps |
React Hook useCallback has an unnecessary dependency: 'fetchColumnOptions'. Either exclude it or remove the dependency array. |
| 🟡 | src/components/DataQuality/AddTestCaseList/AddTestCaseList.component.tsx:792:6 |
react-hooks/exhaustive-deps |
React Hook useMemo has an unnecessary dependency: 'items'. Either exclude it or remove the dependency array. |
| 🟡 | src/components/Entity/EntityVersionTimeLine/EntityVersionTimeLine.tsx:37:6 |
react-hooks/exhaustive-deps |
React Hook useEffect has a missing dependency: 'getResourceLimit'. Either include it or remove the dependency array. |
| 🟡 | src/components/Entity/EntityVersionTimeLine/EntityVersionTimeLine.tsx:95:6 |
react-hooks/exhaustive-deps |
React Hook useMemo has missing dependencies: 'maxVersions' and 't'. Either include them or remove the dependency array. |
| 🟡 | src/components/Entity/Task/TaskTab/TaskTabNew.component.tsx:85:1 |
openmetadata-imports/no-lower-layer-page-imports |
Pages are route-level composition modules. Move the shared implementation/type to a lower layer instead of importing a page from here. |
| 🟡 | src/components/Entity/Task/TaskTab/TaskTabNew.component.tsx:86:1 |
openmetadata-imports/no-lower-layer-page-imports |
Pages are route-level composition modules. Move the shared implementation/type to a lower layer instead of importing a page from here. |
| 🟡 | src/components/Entity/Task/TaskTab/TaskTabNew.component.tsx:604:6 |
react-hooks/exhaustive-deps |
React Hook useMemo has a missing dependency: 't'. Either include it or remove the dependency array. |
| 🟡 | src/components/Entity/Task/TaskTab/TaskTabNew.component.tsx:771:9 |
react-hooks/exhaustive-deps |
The 'handleTaskLinkClick' function makes the dependencies of useMemo Hook (at line 804) change on every render. Move it inside the useMemo callback. Alternative |
| 🟡 | src/components/Entity/Task/TaskTab/TaskTabNew.component.tsx:842:25 |
openmetadata-imports/review-sequential-api-calls |
Review these sequential API requests. If they are independent, start them together with Promise.all/Promise.allSettled; keep sequencing only when data-dependent |
| 🟡 | src/components/Entity/Task/TaskTab/TaskTabNew.component.tsx:925:5 |
react-hooks/exhaustive-deps |
React Hook useCallback has a missing dependency: 'updateTaskData'. Either include it or remove the dependency array. |
| 🟡 | src/components/Entity/Task/TaskTab/TaskTabNew.component.tsx:1055:9 |
react-hooks/exhaustive-deps |
The 'onTaskReject' function makes the dependencies of useMemo Hook (at line 1820) change on every render. To fix this, wrap the definition of 'onTaskReject' in |
| 🟡 | src/components/Entity/Task/TaskTab/TaskTabNew.component.tsx:1145:25 |
openmetadata-imports/review-sequential-api-calls |
Review these sequential API requests. If they are independent, start them together with Promise.all/Promise.allSettled; keep sequencing only when data-dependent |
| 🟡 | src/components/Entity/Task/TaskTab/TaskTabNew.component.tsx:1179:25 |
openmetadata-imports/review-sequential-api-calls |
Review these sequential API requests. If they are independent, start them together with Promise.all/Promise.allSettled; keep sequencing only when data-dependent |
| 🟡 | src/components/Entity/Task/TaskTab/TaskTabNew.component.tsx:1276:6 |
react-hooks/exhaustive-deps |
React Hook useMemo has a missing dependency: 't'. Either include it or remove the dependency array. |
| 🟡 | src/components/Entity/Task/TaskTab/TaskTabNew.component.tsx:1420:6 |
react-hooks/exhaustive-deps |
React Hook useMemo has a missing dependency: 't'. Either include it or remove the dependency array. |
| 🟡 | src/components/Entity/Task/TaskTab/TaskTabNew.component.tsx:1464:6 |
react-hooks/exhaustive-deps |
React Hook useMemo has missing dependencies: 'isActionLoading', 'isCreator', 'onTestCaseTaskDropdownClick', and 'permissions'. Either include them or remove the |
| 🟡 | src/components/Entity/Task/TaskTab/TaskTabNew.component.tsx:1540:6 |
react-hooks/exhaustive-deps |
React Hook useMemo has missing dependencies: 'hasEditAccess', 'noSuggestionTaskMenuOptions', and 't'. Either include them or remove the dependency array. |
| 🟡 | src/components/Entity/Task/TaskTab/TaskTabNew.component.tsx:1591:6 |
react-hooks/exhaustive-deps |
React Hook useEffect has a missing dependency: 'assigneesForm'. Either include it or remove the dependency array. |
| 🟡 | src/components/Entity/Task/TaskTab/TaskTabNew.component.tsx:1792:9 |
react-hooks/exhaustive-deps |
The 'closeFeedEditor' function makes the dependencies of useMemo Hook (at line 1885) change on every render. To fix this, wrap the definition of 'closeFeedEdito |
| 🟡 | src/components/Explore/EntitySummaryPanel/ColumnSummaryList/ColumnsSummaryList.tsx:74:5 |
react-hooks/exhaustive-deps |
React Hook useCallback has a missing dependency: 'columnsPaging.limit'. Either include it or remove the dependency array. |
| 🟡 | src/components/Explore/EntitySummaryPanel/ColumnSummaryList/ColumnsSummaryList.tsx:80:6 |
react-hooks/exhaustive-deps |
React Hook useCallback has a missing dependency: 'fetchPaginatedColumns'. Either include it or remove the dependency array. |
| 🟡 | src/components/Explore/EntitySummaryPanel/ColumnSummaryList/ColumnsSummaryList.tsx:97:6 |
react-hooks/exhaustive-deps |
React Hook useEffect has a missing dependency: 'fetchPaginatedColumns'. Either include it or remove the dependency array. |
| 🟡 | src/components/Explore/EntitySummaryPanel/ColumnSummaryList/ColumnsSummaryList.tsx:113:6 |
react-hooks/exhaustive-deps |
React Hook useMemo has missing dependencies: 'columns.length' and 'columnsPaging.total'. Either include them or remove the dependency array. |
| 🟡 | src/components/GlobalSearchBar/GlobalSearchBar.tsx:123:5 |
react-hooks/exhaustive-deps |
React Hook useMemo has a missing dependency: 'updateSearchCriteria'. Either include it or remove the dependency array. |
| 🟡 | src/components/GlobalSearchBar/GlobalSearchBar.tsx:135:6 |
react-hooks/exhaustive-deps |
React Hook useCallback has a missing dependency: 'navigate'. Either include it or remove the dependency array. |
| 🟡 | src/components/GlobalSearchBar/GlobalSearchBar.tsx:144:28 |
react-hooks/exhaustive-deps |
React Hook useCallback received a function whose dependencies are unknown. Pass an inline function instead. |
| 🟡 | src/components/GlobalSearchBar/GlobalSearchBar.tsx:205:6 |
react-hooks/exhaustive-deps |
React Hook useEffect has a missing dependency: 'initNLP'. Either include it or remove the dependency array. |
| 🟡 | src/components/Glossary/GlossaryTerms/tabs/AssetsTabs.component.tsx:63:1 |
openmetadata-imports/no-lower-layer-page-imports |
Pages are route-level composition modules. Move the shared implementation/type to a lower layer instead of importing a page from here. |
| 🟡 | src/components/Glossary/GlossaryTerms/tabs/AssetsTabs.component.tsx:573:7 |
react-hooks/exhaustive-deps |
React Hook useCallback has a missing dependency: 'handlePagingChange'. Either include it or remove the dependency array. |
| 🟡 | src/components/Glossary/GlossaryTerms/tabs/AssetsTabs.component.tsx:829:7 |
react-hooks/exhaustive-deps |
React Hook useCallback has a missing dependency: 'onRemoveAsset'. Either include it or remove the dependency array. If 'onRemoveAsset' changes too often, find t |
| 🟡 | src/components/Glossary/GlossaryTerms/tabs/AssetsTabs.component.tsx:869:8 |
react-hooks/exhaustive-deps |
React Hook useCallback has a missing dependency: 'onAssetRemove'. Either include it or remove the dependency array. |
| 🟡 | src/components/Glossary/GlossaryTerms/tabs/AssetsTabs.component.tsx:900:8 |
react-hooks/exhaustive-deps |
React Hook useEffect has a missing dependency: 'onAssetClick'. Either include it or remove the dependency array. If 'onAssetClick' changes too often, find the p |
| 🟡 | src/components/Glossary/GlossaryTerms/tabs/AssetsTabs.component.tsx:906:8 |
react-hooks/exhaustive-deps |
React Hook useEffect has a missing dependency: 'fetchCurrentEntity'. Either include it or remove the dependency array. |
… and 149 more. Run make ui-checkstyle-changed locally for the full list.
Fix locally (fast - only checks files changed in this branch):
make ui-checkstyle-changed# Conflicts: # openmetadata-ui/src/main/resources/ui/src/components/ExploreV1/ExploreV1.component.tsx # openmetadata-ui/src/main/resources/ui/src/components/ExploreV1/ExploreV1.test.tsx
- ButtonSkeleton and Skeleton.Button replacements use OM's antd button heights (36/40/44, width 2x) and keep antd's min-width - SkeletonParagraph gains an animation prop; static antd loaders stay static - Avatar skeletons 40px (antd default size large) - Restore vertical divider margins/heights lost with antd/LESS selectors (user profile cards, alert config steps, ML feature rows) - Keep summary-panel dividers hidden, SCIM divider margin, label styling - Point Playwright waits at hooks that still exist after the migration
DataContracts.spec no longer waits on .ant-skeleton-content, so its suppressed violation count drops from 4 to 3.
- Dashed step connectors: the steps-form-container LESS set a 1px border on all sides of antd's zero-width divider, drawing a 2px dashed line; add the right border so the core divider matches. - alert-details-page.less is never imported, so the extra-info-skeleton rule never applied and antd rendered its default 80x40 button skeleton; use that size.
Pruning the DataContracts.spec suppression lowered the no-positional-locator baseline from 1099 to 1098.
Code Review ✅ Approved🟡 Medium risk · The migration changes loading and divider rendering across many UI components. Migrates all antd OptionsDisplay: compact → Counting what did not apply, without listing it. Comment with these commands to change the behavior for this request:
Was this helpful? React with 👍 / 👎 | Powered by Gitar — free for open source |
|



Describe your changes:
Fixes https://github.com/open-metadata/openmetadata-collate/issues/6896
Fixes https://github.com/open-metadata/openmetadata-collate/issues/6897
This migrates every antd
SkeletonandDividerin the OSS UI to theui-core-componentsversions (Skeleton,SkeletonParagraph,Divider). Both tickets belong to the antd → core epic, and they touch many of the same files, so they're done together in one PR.After this change, no file under
openmetadata-ui/.../ui/srcimportsSkeletonorDividerfromantd. There are no intentional exceptions.Type of change:
High-level design:
Skeleton mapping
activebecomes pulse. A skeleton withoutactivebecomesanimation={false}.SkeletonParagraphgets a newanimationprop for this.paragraph/titlebecomeSkeletonParagraph(rows,title). Custom width arrays are written out as explicitSkeletonbars.Skeleton.Button/Input/Avatarbecomerounded/circularvariants, using antd's pixel sizes:@btn-height-*to 36/40/44), with antd'smin-widthkept onButtonSkeletonavatarprop defaults to size large)blockbecomeswidth="100%"loading={x}becomesx ? skeleton : children. With no children it becomesx && skeleton.Skeleton.interfaces.tsnow uses the coreSkeletonProps.ButtonSkeletonandLabelCountSkeletonwere retyped to match, and callers that passed antd-only props were updated.Divider mapping
type="vertical"becomesorientation="vertical".Dividerhas no margins, so antd's defaults are added back:tw:my-6tw:mx-2 tw:h-[0.9em] tw:self-centerlabelprop.#D9D9D9styles were dropped. The line colour now comes from the design token.LESS
.ant-divider*/.ant-skeleton*on the migrated elements were moved onto the element astw:classes, pointed at the element's own class, or removed:Playwright
.ant-skeleton*to detach. Where the skeleton was migrated, that wait now resolves immediately. The next step in each of those specs waits for its own element, so behaviour doesn't change. The 3 that guard a migrated element now wait on a new hook (see Tests). The rest (task.ts,importUtils, and ones that already passed immediately onmain) are left for a follow-up cleanup.Tests:
Use cases covered
main.Test steps performed
mainand resolved conflicts.ExploreV1.component.tsxandExploreV1.test.tsxconflicted becausemainhad already moved Explore to core components. Both files now matchmain..ts/.tsxfile undersrcforSkeletonorDividerimported fromantd, including multi-line imports. None remain.:8585) instead of antd's defaults. This showed that OM overrides antd's button heights to 36/40/44px, soSkeleton.Buttonwas 72×36 / 80×40 / 88×44 in the app. Avatar skeletons default to 40px, the title-to-paragraph gap is 24px, and the row gap is 16px.activeor static);loading/children still behave the same;data-testid,dashed, label styling);.ant-divider/.ant-skeletonon these elements;9ae3a427979):ButtonSkeletonheights and minimum width;Skeleton.Buttonsizes in 5 components;animationprop onSkeletonParagraph;TableDetailsPageSkeletonspacing;AppInstallVerifyCardandFeedListSeparator;d5d59e1a5a6): dashed step connectors keep antd's 2px stroke (tw:border-r), and the alert owner loaders use antd's default 80×40 button size, because theextra-info-skeletonrule inalert-details-page.lessis never imported.openmetadata-ui-core-components(yarn build) after adding theSkeletonParagraphanimationprop.Unit tests
Skeletonor queried.ant-skeleton/.ant-divider. They now userole="separator",aria-hiddenskeleton spans, or core mocks:jest --findRelatedTests <changed files>, after the gap fixes: 787/787 suites and 10161/10161 tests pass.tsc --noEmit: no errors in the changed files. The one hit inUserProfileTeams.component.tsx:153(theTeamsSelectableNewref) is on a line this PR doesn't change and also exists onmain.yarn tw-guardpasses.yarn token-auditis unchanged from baseline.Playwright (UI) tests
Pagination.spec.ts: waits for.total-data-assets-loader, a new class on the widget's loader.DataContracts.spec.ts: useswaitForAllLoadersToDisappear(page, 'skeleton-card-loader').utils/user.ts: waits for.button-skeleton, a new class onButtonSkeleton.DataContracts.spec.tsentry ineslint-suppressions.json(count 4 → 3) so the Playwright lint step passes.UI screen recording / screenshots:
Not attached yet. Visual parity was checked by reading the code, not in a browser.
Checklist:
Fixesabove.