Skip to content

fix(devextreme-angular): resolve PivotGrid/FieldChooser texts naming - #34932

Open
ajivanyandev wants to merge 4 commits into
DevExpress:mainfrom
ajivanyandev:fix/pivot-grid-field-chooser-texts-collision
Open

fix(devextreme-angular): resolve PivotGrid/FieldChooser texts naming#34932
ajivanyandev wants to merge 4 commits into
DevExpress:mainfrom
ajivanyandev:fix/pivot-grid-field-chooser-texts-collision

Conversation

@ajivanyandev

@ajivanyandev ajivanyandev commented Aug 26, 2026

Copy link
Copy Markdown
Contributor

fix(devextreme-angular): resolve PivotGrid/FieldChooser texts naming collision

devextreme-angular's wrapper generator produced two different nested options with the identical class name DxoPivotGridFieldChooserTextsComponent and selector dxo-pivot-grid-field-chooser-texts: dxPivotGrid's own fieldChooser.texts, and the standalone dxPivotGridFieldChooser's own texts. The generator names classes as Dxo+parentWidgetName+optionName with no collision detection, and "PivotGrid"+"FieldChooserTexts" === "PivotGridFieldChooser"+"Texts".

This is invisible under a JIT Angular compiler but a hard NG8023 ambiguous-selector error under AOT.

Fixed at the source with a forcedName metadata override in make-integration-metadata.ts — the same mechanism already used for identical collisions elsewhere in that file (e.g. Toolbar.items) — and regenerated the Angular, React, and Vue wrappers.

Breaking change note: the forcedName metadata override is framework-agnostic - it feeds the Angular, React, and Vue generators from one shared layer, with no way to scope a rename to a single framework. So although the underlying bug (NG8023) is Angular-AOT-only, this PR also renames the React export FieldChooserTextsEmbeddedFieldChooserTexts (devextreme-react/pivot-grid) and the Vue export DxFieldChooserTextsDxEmbeddedFieldChooserTexts (devextreme-vue/pivot-grid), even though neither framework had a compile error to fix - React/Vue nested-option exports are per-file scoped and never collided. This matches existing precedent in this file (the Toolbar.items overrides for DataGrid/TreeList have the same cross-framework effect), so it's consistent with how this mechanism already works, but it should be called out explicitly rather than read as an Angular-only fix.

…collision

devextreme-angular's wrapper generator produced two different nested
options with the identical class name DxoPivotGridFieldChooserTextsComponent
and selector dxo-pivot-grid-field-chooser-texts: dxPivotGrid's own
fieldChooser.texts, and the standalone dxPivotGridFieldChooser's own
texts. The generator names classes as Dxo+parentWidgetName+optionName
with no collision detection, and "PivotGrid"+"FieldChooserTexts" ===
"PivotGridFieldChooser"+"Texts".

This is invisible under a JIT Angular compiler but a hard NG8023
ambiguous-selector error under AOT.

Fixed at the source with a forcedName metadata override in
make-integration-metadata.ts — the same mechanism already used for
identical collisions elsewhere in that file (e.g. Toolbar.items) —
and regenerated the Angular, React, and Vue wrappers.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@ajivanyandev ajivanyandev self-assigned this Aug 26, 2026
@ajivanyandev ajivanyandev changed the title fix(devextreme-angular): resolve PivotGrid/FieldChooser texts naming … fix(devextreme-angular): resolve PivotGrid/FieldChooser texts naming Aug 26, 2026
@ajivanyandev
ajivanyandev requested a lite review from Copilot August 26, 2026 12:04

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

Resolves an Angular AOT (NG8023) ambiguous-selector error caused by a naming collision in generated wrapper nested options for PivotGrid/FieldChooser texts, by introducing a metadata forcedName override and regenerating affected framework wrappers.

Changes:

  • Added an integration-metadata forcedName override for dxPivotGridOptions.fieldChooser.texts to avoid class/selector collisions during wrapper generation.
  • Regenerated Vue and React PivotGrid wrappers to expose the renamed nested option (EmbeddedFieldChooserTexts) and updated expected-children mappings.
  • Regenerated Angular PivotGrid wrapper nested option to use a new selector/module for the embedded FieldChooser texts and updated PivotGrid module exports/imports accordingly.

Reviewed changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
packages/devextreme-vue/src/pivot-grid.ts Renames/rewires nested option component for embedded FieldChooser texts and updates exports/expectedChildren.
packages/devextreme-react/src/pivot-grid.ts Adds EmbeddedFieldChooserTexts nested component and updates FieldChooser expected children + exports.
packages/devextreme-metadata/make-integration-metadata.ts Adds forcedName override to prevent generated wrapper name collisions at the metadata source.
packages/devextreme-angular/src/ui/pivot-grid/nested/index.ts Re-exports the newly generated embedded FieldChooser texts nested component.
packages/devextreme-angular/src/ui/pivot-grid/nested/embedded-field-chooser-texts.ts Introduces the renamed Angular nested option component/selector for embedded FieldChooser texts.
packages/devextreme-angular/src/ui/pivot-grid/index.ts Updates PivotGrid Angular module imports/exports to include the new embedded texts nested module.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment on lines +116 to +118
addMetadata('ui/pivot_grid:dxPivotGridOptions.fieldChooser.texts', {
forcedName: 'embeddedFieldChooserTexts',
}),
@ajivanyandev
ajivanyandev marked this pull request as ready for review August 28, 2026 09:27
Copilot AI review requested due to automatic review settings August 28, 2026 09:27

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

Copilot reviewed 6 out of 6 changed files in this pull request and generated no new comments.

Copilot AI review requested due to automatic review settings August 28, 2026 11:10

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

Copilot reviewed 6 out of 6 changed files in this pull request and generated no new comments.

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