lucca-front icon indicating copy to clipboard operation
lucca-front copied to clipboard

Use `_addAriaLabelledBy` in Dialog's `CdkDialogContainer` call once cdk dependency is >= 17.1

Open Supamiu opened this issue 1 year ago • 0 comments

Context

For some reason that we couldn't identify, the CdkDialogContainer._addAriaLabelledBy method is only available in @angular/[email protected] and above while it's present in cdk's index.d.ts file even in 17.0.0. In order to properly build the library, we decided to use _ariaLabelledByQueue.push instead, exposing ourselves to a possible Change Detection issue, as described in https://github.com/angular/components/pull/28329.

Also, updating our dependency to @angular/cdk to something above the current version would be breaking for projects using @lucca-front/ng, which would make them have to update to Angular 17.1 or above, which is not needed except for this small risk.

Task

Once we moved to a version of @angular/cdk that's >= 17.1, ths call in packages/ng/dialog/dialog-header/dialog-header.component.ts that's in ngOnInit should be changed for an _addAriaLabelledBy call instead.

This will probably be done once we moved to Angular 18, somewhere around May 2024.

Supamiu avatar Feb 09 '24 10:02 Supamiu