Skip to content

fix(i18n): Fix setting partial resources not filling the rest per component. - #17546

Open
skrustev wants to merge 4 commits into
22.1.xfrom
skrastev/fix-17540-22.1.x
Open

fix(i18n): Fix setting partial resources not filling the rest per component.#17546
skrustev wants to merge 4 commits into
22.1.xfrom
skrastev/fix-17540-22.1.x

Conversation

@skrustev

Copy link
Copy Markdown
Member

Related #17540

Description

Fix setting partial custom resources per component returning partial resources as well when getting them using the resourceString property instead of getting merged with the default ones.

Type of Change (check all that apply):

  • Bug fix
  • New functionality
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Refactoring (no functional changes)
  • Documentation
  • Demos
  • CI/CD
  • Tests
  • Changelog
  • Skills/Agents

Component(s) / Area(s) Affected:

  • Action Strip
  • Banner
  • Carousel
  • Chip
  • Combo
  • Date Range Picker
  • Grid
  • Pivot Date Dimension
  • Input Group
  • List
  • Paginator
  • Query Builder
  • Tree

How Has This Been Tested?

  • Unit tests
  • Manual testing
  • Automated e2e tests

Checklist:

  • All relevant tags have been applied to this PR
  • This PR includes unit tests covering all the new code (test guidelines)
  • This PR includes API docs for newly added methods/properties (api docs guidelines)
  • This PR includes feature/README.MD updates for the feature docs
  • This PR includes general feature table updates in the root README.MD
  • This PR includes CHANGELOG.MD updates for newly added functionality
  • This PR contains breaking changes
  • This PR includes ng update migrations for the breaking changes (migrations guidelines)
  • This PR includes behavioral changes and the feature specification has been updated with them
  • Accessibility (ARIA, keyboard navigation, focus management) has been verified

@skrustev
skrustev requested a review from ChronosSF August 27, 2026 11:31
Copilot AI lite review requested due to automatic review settings August 27, 2026 11:31
@skrustev skrustev added ❌ status: awaiting-test PRs awaiting manual verification 🔣 i18n squash-merge Merge PR with "Squash and Merge" option version: 22.1.x labels Aug 27, 2026
@skrustev skrustev changed the title fix(i18n): Fix setting partial resources not filling the rest per component.- #17542 fix(i18n): Fix setting partial resources not filling the rest per component. Aug 27, 2026

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 fixes i18n behavior where setting partial per-component resourceStrings returned only the partial object (missing defaults) when later accessed (e.g. via resourceStrings / resourceString), by introducing merged “custom + defaults” resource objects across multiple components and adding unit tests to prevent regressions.

Changes:

  • Update many components to return merged resource strings (defaults overlaid with per-component custom overrides), and refresh merged values on global i18n change events.
  • Refactor several locale/i18n update paths to reuse a shared updateResources(...) helper.
  • Add unit tests validating (1) partial per-component overrides still expose defaults, and (2) global i18n changes update only non-overridden keys.

Reviewed changes

Copilot reviewed 29 out of 29 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
projects/igniteui-angular/tree/src/tree/tree.spec.ts Adds tests validating merged TreeNode resource strings and global i18n updates.
projects/igniteui-angular/tree/src/tree/tree-node/tree-node.component.ts Returns merged default+custom resource strings; updates merged strings on global i18n change.
projects/igniteui-angular/time-picker/src/time-picker/time-picker.component.ts Returns merged default+custom resource strings; recomputes on resource updates.
projects/igniteui-angular/query-builder/src/query-builder/query-builder.component.ts Returns merged default+custom resource strings; recomputes on global i18n change.
projects/igniteui-angular/query-builder/src/query-builder/query-builder.component.spec.ts Adds tests for partial resourceStrings merge and global i18n updates.
projects/igniteui-angular/query-builder/src/query-builder/query-builder-tree.component.ts Uses updateResources(...) helper and merges default+custom resource strings (incl. locale path).
projects/igniteui-angular/query-builder/src/query-builder/query-builder-header.component.ts Returns merged default+custom resource strings; recomputes on global i18n change.
projects/igniteui-angular/paginator/src/paginator/paginator.component.ts Returns merged default+custom resource strings; recomputes on global i18n change.
projects/igniteui-angular/paginator/src/paginator/paginator.component.spec.ts Adds test ensuring global i18n updates affect non-overridden keys.
projects/igniteui-angular/list/src/list/list.component.ts Returns merged default+custom resource strings; recomputes on global i18n change.
projects/igniteui-angular/list/src/list/list.component.spec.ts Adds tests for partial resourceStrings merge and global i18n updates.
projects/igniteui-angular/input-group/src/input-group/input-group.component.ts Returns merged default+custom resource strings; recomputes on global i18n change.
projects/igniteui-angular/input-group/src/input-group/input-group.component.spec.ts Adds tests for partial resourceStrings merge and global i18n updates.
projects/igniteui-angular/grids/grid/src/grid.component.spec.ts Adds tests for partial grid resourceStrings merge and global i18n updates.
projects/igniteui-angular/grids/grid/src/grid-base.directive.ts Returns merged default+custom grid resource strings; adds updateResources(...) for locale/i18n changes.
projects/igniteui-angular/grids/core/src/pivot-grid-dimensions.ts Returns merged default+custom resource strings for pivot date dimension.
projects/igniteui-angular/date-picker/src/date-range-picker/date-range-picker.component.ts Returns merged default+custom resource strings; recomputes on resource updates.
projects/igniteui-angular/date-picker/src/date-range-picker/date-range-picker.component.spec.ts Adds tests for partial resourceStrings merge and global i18n updates.
projects/igniteui-angular/combo/src/combo/combo.component.spec.ts Adds tests for partial combo resourceStrings merge and global i18n updates.
projects/igniteui-angular/combo/src/combo/combo.common.ts Returns merged default+custom resource strings; recomputes on global i18n change.
projects/igniteui-angular/chips/src/chips/chip.spec.ts Adds tests for partial chip resourceStrings merge and global i18n updates.
projects/igniteui-angular/chips/src/chips/chip.component.ts Returns merged default+custom resource strings; recomputes on global i18n change.
projects/igniteui-angular/carousel/src/carousel/carousel.component.ts Returns merged default+custom resource strings; recomputes on global i18n change.
projects/igniteui-angular/carousel/src/carousel/carousel.component.spec.ts Adds tests for partial resourceStrings merge and global i18n updates.
projects/igniteui-angular/calendar/src/calendar/calendar-base.ts Returns merged default+custom resource strings; adds updateResources(...) helper for locale/i18n changes.
projects/igniteui-angular/banner/src/banner/banner.component.ts Returns merged default+custom resource strings; recomputes on global i18n change.
projects/igniteui-angular/banner/src/banner/banner.component.spec.ts Adds tests for partial resourceStrings merge and global i18n updates.
projects/igniteui-angular/action-strip/src/action-strip/action-strip.component.ts Returns merged default+custom resource strings; recomputes on global i18n change.
projects/igniteui-angular/action-strip/src/action-strip/action-strip.component.spec.ts Adds tests ensuring global i18n changes propagate correctly with/without overrides.

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

Comment thread projects/igniteui-angular/chips/src/chips/chip.component.ts
Comment thread projects/igniteui-angular/calendar/src/calendar/calendar-base.ts
Comment thread projects/igniteui-angular/banner/src/banner/banner.component.ts
Comment thread projects/igniteui-angular/grids/grid/src/grid-base.directive.ts
@mddragnev mddragnev added ✅ status: verified Applies to PRs that have passed manual verification and removed ❌ status: awaiting-test PRs awaiting manual verification labels Aug 28, 2026
@mddragnev mddragnev self-assigned this Aug 28, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

squash-merge Merge PR with "Squash and Merge" option 🔣 i18n version: 22.1.x ✅ status: verified Applies to PRs that have passed manual verification

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants