MCPcopy Index your code
hub / github.com/UI5/webcomponents / getNormalizedTarget

Function getNormalizedTarget

packages/base/src/util/getNormalizedTarget.ts:6–14  ·  view source on GitHub ↗
(target: HTMLElement)

Source from the content-addressed store, hash-verified

4 * @returns {Object} The normalized target
5 */
6const getNormalizedTarget = (target: HTMLElement) => {
7 let element = target;
8
9 if (target.shadowRoot && target.shadowRoot.activeElement) {
10 element = target.shadowRoot.activeElement as HTMLElement;
11 }
12
13 return element;
14};
15
16export default getNormalizedTarget;

Callers 5

_handleTabMethod · 0.85
_onfocusinMethod · 0.85
_onColumnHeaderClickMethod · 0.85
_handleTabNextMethod · 0.85
_onfocusinMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected