From 5f43efd8f90dc1b5baf5142ea9619cdd2dcab497 Mon Sep 17 00:00:00 2001 From: Michael Prentice Date: Sat, 6 Mar 2021 23:28:59 -0500 Subject: [PATCH] fix(cdk/a11y): FocusTrap deprecation docs don't render correctly - fix invalid usage of `@breaking-change` - update breaking change dgeni template to add 'or later' - fix a couple of API doc typos Relates to #18201. Relates to #22136. --- src/cdk/a11y/focus-trap/focus-trap.ts | 8 ++++---- tools/dgeni/templates/macros.html | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/cdk/a11y/focus-trap/focus-trap.ts b/src/cdk/a11y/focus-trap/focus-trap.ts index 788c0e2cd716..d7432b33a9ae 100644 --- a/src/cdk/a11y/focus-trap/focus-trap.ts +++ b/src/cdk/a11y/focus-trap/focus-trap.ts @@ -30,10 +30,10 @@ import {InteractivityChecker} from '../interactivity-checker/interactivity-check * * This class currently uses a relatively simple approach to focus trapping. * It assumes that the tab order is the same as DOM order, which is not necessarily true. - * Things like `tabIndex > 0`, flex `order`, and shadow roots can cause the two to misalign. + * Things like `tabIndex > 0`, flex `order`, and shadow roots can cause the two to be misaligned. * * @deprecated Use `ConfigurableFocusTrap` instead. - * @breaking-change for 11.0.0 Remove this class. + * @breaking-change 11.0.0 */ export class FocusTrap { private _startAnchor: HTMLElement | null; @@ -96,7 +96,7 @@ export class FocusTrap { /** * Inserts the anchors into the DOM. This is usually done automatically * in the constructor, but can be deferred for cases like directives with `*ngIf`. - * @returns Whether the focus trap managed to attach successfuly. This may not be the case + * @returns Whether the focus trap managed to attach successfully. This may not be the case * if the target element isn't currently in the DOM. */ attachAnchors(): boolean { @@ -355,7 +355,7 @@ export class FocusTrap { /** * Factory that allows easy instantiation of focus traps. * @deprecated Use `ConfigurableFocusTrapFactory` instead. - * @breaking-change for 11.0.0 Remove this class. + * @breaking-change 11.0.0 */ @Injectable({providedIn: 'root'}) export class FocusTrapFactory { diff --git a/tools/dgeni/templates/macros.html b/tools/dgeni/templates/macros.html index f7369e1bb1b7..55242db57a7d 100644 --- a/tools/dgeni/templates/macros.html +++ b/tools/dgeni/templates/macros.html @@ -1,5 +1,5 @@ {% macro deprecationTitle(doc) %} {%- if doc.breakingChange -%} - title="Will be deleted in v{$ doc.breakingChange $}" + title="Will be removed in v{$ doc.breakingChange $} or later" {%- endif -%} {% endmacro %}