fix(core): inherit aria attributes on host elements (#25156)

Resolves #20127
This commit is contained in:
Sean Perkins
2022-04-21 10:50:56 -04:00
committed by GitHub
parent c6afacbb7d
commit 611832b0d5
11 changed files with 119 additions and 19 deletions

View File

@ -14,7 +14,7 @@ import type {
StyleEventDetail,
} from '../../interface';
import type { Attributes } from '../../utils/helpers';
import { clamp, debounceEvent, getAriaLabel, inheritAttributes, renderHiddenInput } from '../../utils/helpers';
import { inheritAriaAttributes, clamp, debounceEvent, getAriaLabel, renderHiddenInput } from '../../utils/helpers';
import { isRTL } from '../../utils/rtl';
import { createColorClasses, hostContext } from '../../utils/theme';
@ -237,7 +237,7 @@ export class Range implements ComponentInterface {
*/
this.rangeId = this.el.hasAttribute('id') ? this.el.getAttribute('id')! : `ion-r-${rangeIds++}`;
this.inheritedAttributes = inheritAttributes(this.el, ['aria-label']);
this.inheritedAttributes = inheritAriaAttributes(this.el);
}
componentDidLoad() {