Skip to content

feat: Added related term section in term details page#26804

Merged
anuj-kumary merged 9 commits intomainfrom
glossary-term
Mar 27, 2026
Merged

feat: Added related term section in term details page#26804
anuj-kumary merged 9 commits intomainfrom
glossary-term

Conversation

@anuj-kumary
Copy link
Copy Markdown
Contributor

Describe your changes:

Revamped the related terms section in term details page

Screen.Recording.2026-03-26.at.6.38.38.PM.mov

Type of change:

  • Bug fix
  • Improvement
  • New feature
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation

Checklist:

  • I have read the CONTRIBUTING document.
  • My PR title is Fixes <issue-number>: <short explanation>
  • I have commented on my code, particularly in hard-to-understand areas.
  • For JSON Schema changes: I updated the migration scripts or explained why it is not needed.

@anuj-kumary anuj-kumary self-assigned this Mar 26, 2026
@anuj-kumary anuj-kumary requested a review from a team as a code owner March 26, 2026 13:14
@anuj-kumary anuj-kumary added UI UI specific issues safe to test Add this label to run secure Github workflows on PRs labels Mar 26, 2026
@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Mar 26, 2026

Jest test Coverage

UI tests summary

Lines Statements Branches Functions
Coverage: 64%
64.83% (58203/89774) 44.66% (30745/68836) 47.65% (9211/19330)

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Mar 26, 2026

🟡 Playwright Results — all passed (17 flaky)

✅ 3399 passed · ❌ 0 failed · 🟡 17 flaky · ⏭️ 216 skipped

Shard Passed Failed Flaky Skipped
🟡 Shard 1 454 0 1 2
🟡 Shard 2 603 0 1 32
🟡 Shard 3 606 0 3 27
🟡 Shard 4 599 0 4 47
🟡 Shard 5 585 0 2 67
🟡 Shard 6 552 0 6 41
🟡 17 flaky test(s) (passed on retry)
  • Pages/UserCreationWithPersona.spec.ts › Create user with persona and verify on profile (shard 1, 1 retry)
  • Features/BulkEditEntity.spec.ts › Glossary (shard 2, 1 retry)
  • Features/Permissions/GlossaryPermissions.spec.ts › Team-based permissions work correctly (shard 3, 1 retry)
  • Features/Table.spec.ts › Tags term should be consistent for search (shard 3, 1 retry)
  • Flow/ExploreDiscovery.spec.ts › Should display deleted assets when showDeleted is checked and deleted is not present in queryFilter (shard 3, 1 retry)
  • Pages/Customproperties-part2.spec.ts › entityReferenceList shows item count, scrollable list, no expand toggle (shard 4, 1 retry)
  • Pages/DataProductAndSubdomains.spec.ts › Add assets to data product and verify count (shard 4, 1 retry)
  • Pages/Domains.spec.ts › Verify domain tags and glossary terms (shard 4, 1 retry)
  • Pages/Domains.spec.ts › Multiple consecutive domain renames preserve all associations (shard 4, 1 retry)
  • Pages/EntityDataSteward.spec.ts › Update displayName (shard 5, 1 retry)
  • Pages/ExplorePageRightPanel.spec.ts › Should allow Data Steward to edit tier for container (shard 5, 1 retry)
  • Pages/HyperlinkCustomProperty.spec.ts › should display URL when no display text is provided (shard 6, 1 retry)
  • Pages/InputOutputPorts.spec.ts › Tab renders with empty state when no ports exist (shard 6, 1 retry)
  • Pages/Login.spec.ts › Refresh should work (shard 6, 1 retry)
  • Pages/ODCSImportExport.spec.ts › Multi-object ODCS contract - object selector shows all schema objects (shard 6, 1 retry)
  • Pages/ServiceEntity.spec.ts › Inactive Announcement create & delete (shard 6, 1 retry)
  • Pages/Users.spec.ts › Permissions for table details page for Data Consumer (shard 6, 1 retry)

📦 Download artifacts

How to debug locally
# Download playwright-test-results-<shard> artifact and unzip
npx playwright show-trace path/to/trace.zip    # view trace

@gitar-bot
Copy link
Copy Markdown

gitar-bot bot commented Mar 27, 2026

Code Review 👍 Approved with suggestions 2 resolved / 3 findings

Adds a related terms section to the glossary term details page with autocomplete functionality limited to 25 terms and proper Apache license headers. Consider fixing the mismatched color hex codes and labels in COLOR_META_BY_HEX to ensure consistency.

💡 Bug: COLOR_META_BY_HEX has mismatched color hex codes and names

📄 openmetadata-ui/src/main/resources/ui/src/components/OntologyExplorer/OntologyExplorer.constants.ts:256 📄 openmetadata-ui/src/main/resources/ui/src/components/OntologyExplorer/OntologyExplorer.constants.ts:259 📄 openmetadata-ui/src/main/resources/ui/src/components/OntologyExplorer/OntologyExplorer.constants.ts:258

Several entries in the new COLOR_META_BY_HEX map have label keys that don't match the actual hex color:

  • #107569 (teal/green) → label.color-rose
  • #7839ee (purple) → label.color-teal
  • #e31b54 (red/pink) → label.color-violet

These mismatches are inherited from the pre-existing RELATION_META, but the new COLOR_META_BY_HEX lookup table propagates them to the settings page badge display via renderColorBadge, so users will see incorrect color names.

Suggested fix
Fix the label keys to match the actual colors:
  '#107569': { ..., labelKey: 'label.color-teal' },
  '#e31b54': { ..., labelKey: 'label.color-rose' },
  '#7839ee': { ..., labelKey: 'label.color-purple' },
Also consider fixing the source mappings in RELATION_META.
✅ 2 resolved
Bug: Autocomplete limited to 25 terms, not "all" terms

📄 openmetadata-ui/src/main/resources/ui/src/components/Glossary/GlossaryTerms/tabs/RelatedTerms.tsx:393-403 📄 openmetadata-ui/src/main/resources/ui/src/components/Glossary/GlossaryTerms/tabs/RelatedTerms.tsx:220-229 📄 openmetadata-ui/src/main/resources/ui/src/components/Glossary/GlossaryTerms/tabs/RelatedTerms.tsx:289-302
The fetchAllTerms function fetches only the first 25 glossary terms (PAGE_SIZE_MEDIUM = 25) but is named and used as if it loads all available terms. The Autocomplete dropdown in TermsRow is populated exclusively from preloadedTerms, so any glossary with more than 25 terms will have missing options that users cannot select. There's also no search-as-you-type filtering against the API — the Autocomplete only filters within the preloaded 25 items.

This silently degrades the UX for larger glossaries where users won't find the term they're looking for.

Quality: Missing Apache license header in new interface file

📄 openmetadata-ui/src/main/resources/ui/src/components/Glossary/GlossaryTerms/tabs/RelatedTerms.interface.ts:1
The new RelatedTerms.interface.ts file is missing the standard Apache 2.0 license header that is present in all other files in the project, including the sibling TermsRowEditor.component.tsx added in the same PR.

🤖 Prompt for agents
Code Review: Adds a related terms section to the glossary term details page with autocomplete functionality limited to 25 terms and proper Apache license headers. Consider fixing the mismatched color hex codes and labels in COLOR_META_BY_HEX to ensure consistency.

1. 💡 Bug: COLOR_META_BY_HEX has mismatched color hex codes and names
   Files: openmetadata-ui/src/main/resources/ui/src/components/OntologyExplorer/OntologyExplorer.constants.ts:256, openmetadata-ui/src/main/resources/ui/src/components/OntologyExplorer/OntologyExplorer.constants.ts:259, openmetadata-ui/src/main/resources/ui/src/components/OntologyExplorer/OntologyExplorer.constants.ts:258

   Several entries in the new `COLOR_META_BY_HEX` map have label keys that don't match the actual hex color:
   - `#107569` (teal/green) → `label.color-rose`
   - `#7839ee` (purple) → `label.color-teal`
   - `#e31b54` (red/pink) → `label.color-violet`
   
   These mismatches are inherited from the pre-existing `RELATION_META`, but the new `COLOR_META_BY_HEX` lookup table propagates them to the settings page badge display via `renderColorBadge`, so users will see incorrect color names.

   Suggested fix:
   Fix the label keys to match the actual colors:
     '#107569': { ..., labelKey: 'label.color-teal' },
     '#e31b54': { ..., labelKey: 'label.color-rose' },
     '#7839ee': { ..., labelKey: 'label.color-purple' },
   Also consider fixing the source mappings in RELATION_META.

Options

Auto-apply is off → Gitar will not commit updates to this branch.
Display: compact → Showing less information.

Comment with these commands to change:

Auto-apply Compact
gitar auto-apply:on         
gitar display:verbose         

Was this helpful? React with 👍 / 👎 | Gitar

@sonarqubecloud
Copy link
Copy Markdown

@anuj-kumary anuj-kumary enabled auto-merge (squash) March 27, 2026 16:37
@anuj-kumary anuj-kumary merged commit 25faf7b into main Mar 27, 2026
47 checks passed
@anuj-kumary anuj-kumary deleted the glossary-term branch March 27, 2026 16:59
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 UI UI specific issues

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants