MCPcopy Index your code
hub / github.com/ReactTooltip/react-tooltip / removeAriaDescribedBy

Function removeAriaDescribedBy

src/components/Tooltip/Tooltip.tsx:154–161  ·  view source on GitHub ↗
(element: Element | null)

Source from the content-addressed store, hash-verified

152 }
153
154 function removeAriaDescribedBy(element: Element | null) {
155 const newDescribedBy = getAriaDescribedBy(element).filter((s) => s !== id)
156 if (newDescribedBy.length) {
157 element?.setAttribute('aria-describedby', newDescribedBy.join(' '))
158 } else {
159 element?.removeAttribute('aria-describedby')
160 }
161 }
162
163 if (show) {
164 removeAriaDescribedBy(previousActiveAnchor)

Callers 1

TooltipFunction · 0.85

Calls 1

getAriaDescribedByFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…