Skip to content

refactor: extract shared UI component changes ahead of analysis-tools feature#1845

Open
paustint wants to merge 1 commit into
mainfrom
refactor/shared-ui-navbar-components
Open

refactor: extract shared UI component changes ahead of analysis-tools feature#1845
paustint wants to merge 1 commit into
mainfrom
refactor/shared-ui-navbar-components

Conversation

@paustint

@paustint paustint commented Jul 1, 2026

Copy link
Copy Markdown
Contributor

Why

Precursor to the analysis-tools feature PR (#1732). That PR modifies a number of shared UI-library components that render/run for every user regardless of the analysis-tools feature flag. A feature flag protects users from the feature's code, but not from regressions in shared components. This PR pulls those unflagged shared changes out so they can be reviewed and shipped independently — and so the feature flag becomes a true safety boundary for the feature itself.

Every file here is byte-identical to #1732 except HeaderNavbarItems.tsx (the analysis-tools nav menu is omitted and re-added, flag-gated, in the feature PR) and the @jetstream/shared/utils barrel (only the shared tooling-name util is exported here).

What's included (all ship to all users, not behind the flag)

  • Navbar — responsive overflow "More" menu + a config-driven items API (Navbar, NavbarMenuItems, HeaderNavbar, useHeaderNavbarItems hook, headerNavbarBillingUserItems). This is the largest universal change — the top nav is reworked for everyone.
  • DataTable — opt-in autoRowHeight prop; the default render path is unchanged (verified byte-for-byte when the prop is off).
  • Card, Popover, ItemSelectionSummary — small backward-compatible tweaks; sobject-list gains an additive disabled prop; ProfileOrPermSetPopover adds setup-URL helpers.
  • useWhereIsThisUsed + Create Fields — shared custom-field tooling-name parsing (custom-field-tooling-names util + tests). Changes the "Where is this used?" SOQL (adds explicit NamespacePrefix = null) and Create Fields namespace detection.
  • regexSFDC_ID 15/18-char fix; polyfillFieldDefinition label tweaks; additive icon registrations.

Verification

  • ESLint on the changed files: no new problems (pre-existing react-hooks/* baseline errors already exist on main).
  • custom-field-tooling-names unit tests pass (9/9).

Follow-up

Once this merges, #1732 rebases onto main and its diff shrinks to gated feature code + additive new files.

🤖 Generated with Claude Code

Copilot AI review requested due to automatic review settings July 1, 2026 15:26
Comment thread libs/ui/src/lib/nav/Navbar.tsx Fixed

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR extracts and ships a set of shared UI-library refactors and additive utilities ahead of the upcoming analysis-tools feature work, so that universal/shared-component changes can be reviewed and released independently from the feature-flagged functionality.

Changes:

  • Refactors the header navbar to a config-driven, responsive overflow (“More”) menu model.
  • Adds an opt-in autoRowHeight mode to the DataTable grid, including DOM-measured row heights and related CSS.
  • Introduces shared custom-field tooling-name parsing utilities (plus tests) and adopts them in “Where is this used?” and Create Fields namespace logic.

Reviewed changes

Copilot reviewed 26 out of 27 changed files in this pull request and generated 7 comments.

Show a summary per file
File Description
libs/ui/src/lib/widgets/ProfileOrPermSetPopover.tsx Adds setup URL helpers for permission set groups and user management pages.
libs/ui/src/lib/widgets/ItemSelectionSummary.tsx Adds disabled handling to prevent clearing items when read-only.
libs/ui/src/lib/sobject-list/SobjectListMultiSelect.tsx Adds disabled plumbing to make multi-select read-only.
libs/ui/src/lib/sobject-list/ConnectedSobjectListMultiSelect.tsx Adds disabled option to prevent refresh/auto-load and selection.
libs/ui/src/lib/sobject-field-list/useWhereIsThisUsed.tsx Switches custom-field Tooling query building to shared parsing util and adds NamespacePrefix = null.
libs/ui/src/lib/popover/Popover.tsx Merges buttonProps.style with internally computed trigger style.
libs/ui/src/lib/nav/NavbarMenuItems.tsx Updates dropdown header divider behavior and adjusts router imports.
libs/ui/src/lib/nav/Navbar.tsx Replaces children-based navbar with config-driven, responsive overflow rendering.
libs/ui/src/lib/data-table/grid/grid-types.ts Extends GROUP colSpan args with optional groupingColumnId.
libs/ui/src/lib/data-table/grid/DataTableV2.tsx Adds autoRowHeight prop and passes it to the grid container.
libs/ui/src/lib/data-table/grid/data-table-grid.css Adds CSS for auto-height rows and new highlighting classes.
libs/ui/src/lib/data-table/grid/components/GridRow.tsx Adds auto-height row rendering + virtualizer measurement ref support.
libs/ui/src/lib/data-table/grid/components/GridGroupRow.tsx Adds auto-height support for group rows and passes grouping column id to colSpan.
libs/ui/src/lib/data-table/grid/components/GridContainer.tsx Disables horizontal virtualization in auto-height mode by rendering all columns.
libs/ui/src/lib/data-table/grid/components/GridBody.tsx Enables virtualizer DOM measurement in auto-height mode and passes refs to rows.
libs/ui/src/lib/data-table/DataTable.tsx Exposes autoRowHeight on the legacy wrapper prop surface.
libs/ui/src/lib/card/Card.tsx Adjusts header layout min-width behavior to avoid overflow/clipping issues.
libs/shared/utils/src/lib/regex.ts Fixes SFDC id regex to allow 15- or 18-character IDs.
libs/shared/utils/src/lib/custom-field-tooling-names.ts Adds shared parser/helpers for Tooling CustomField namespace + developer name.
libs/shared/utils/src/lib/tests/custom-field-tooling-names.spec.ts Adds Vitest coverage for the new tooling-name parser/helpers.
libs/shared/utils/src/index.ts Exports the new custom-field tooling-name utility from the barrel.
libs/shared/ui-utils/src/lib/shared-ui-utils.ts Tweaks polyfillFieldDefinition labeling formatting (spacing before parentheses).
libs/shared/ui-core/src/create-fields/create-fields-load-utils.ts Uses shared tooling-name parser for namespace-prefix detection in Create Fields.
libs/shared/ui-core/src/app/HeaderNavbarReadOnlyUserItems.tsx Converts read-only navbar items into a reusable config array.
libs/shared/ui-core/src/app/HeaderNavbarItems.tsx Converts main navbar items into a memoized config hook.
libs/shared/ui-core/src/app/HeaderNavbar.tsx Switches to the new Navbar items={...} API and updated items sources.
libs/icon-factory/src/lib/icon-factory.tsx Registers additional standard/utility icons for shared availability.

Comment thread libs/ui/src/lib/nav/NavbarMenuItems.tsx
Comment thread libs/shared/ui-core/src/app/HeaderNavbar.tsx
Comment thread libs/shared/utils/src/lib/custom-field-tooling-names.ts
Comment thread libs/ui/src/lib/widgets/ItemSelectionSummary.tsx
Comment thread libs/ui/src/lib/data-table/grid/data-table-grid.css
Comment thread libs/ui/src/lib/data-table/grid/data-table-grid.css
Comment thread libs/ui/src/lib/data-table/grid/data-table-grid.css
… feature

Precursor to the analysis-tools feature PR (#1732). Splits out the shared,
unflagged UI-library changes that ship to ALL users regardless of the
`analysis-tools` feature flag, so they can be reviewed/shipped independently
and the flag becomes a true safety boundary for the feature itself.

Included (all render/run for every user, not behind the flag):
- Navbar: responsive overflow "More" menu + config-driven items API
  (Navbar, NavbarMenuItems, HeaderNavbar, useHeaderNavbarItems hook,
  headerNavbarBillingUserItems) — the analysis-tools nav menu is omitted
  here and re-added flag-gated in the feature PR.
- DataTable: opt-in `autoRowHeight` prop (default render path unchanged).
- Card, Popover, ItemSelectionSummary, sobject-list `disabled` prop,
  ProfileOrPermSetPopover setup-url helpers.
- useWhereIsThisUsed + create-fields: shared custom-field tooling-name
  parsing (custom-field-tooling-names util + tests).
- regex SFDC_ID 15/18-char fix; polyfillFieldDefinition label tweaks;
  additive icon registrations.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@paustint paustint force-pushed the refactor/shared-ui-navbar-components branch from 40b71d2 to 9f98f4e Compare July 1, 2026 22:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants