MCPcopy Create free account
hub / github.com/testing-library/user-event / prepareRangeTextInterceptor

Function prepareRangeTextInterceptor

src/document/interceptor.ts:208–224  ·  view source on GitHub ↗
(
  element: HTMLInputElement | HTMLTextAreaElement,
)

Source from the content-addressed store, hash-verified

206}
207
208export function prepareRangeTextInterceptor(
209 element: HTMLInputElement | HTMLTextAreaElement,
210) {
211 prepareInterceptor(
212 element,
213 'setRangeText',
214 function interceptorImpl(...realArgs) {
215 return {
216 realArgs,
217 then: () => {
218 setUIValueClean(element)
219 setUISelectionClean(element)
220 },
221 }
222 },
223 )
224}

Callers 1

prepareElementFunction · 0.90

Calls 3

setUIValueCleanFunction · 0.90
setUISelectionCleanFunction · 0.90
prepareInterceptorFunction · 0.85

Tested by

no test coverage detected