MCPcopy
hub / github.com/basecamp/trix / clickElement

Function clickElement

src/test/test_helpers/input_helpers.js:162–172  ·  view source on GitHub ↗
(element)

Source from the content-addressed store, hash-verified

160}
161
162export const clickElement = async (element) => {
163 if (triggerEvent(element, "mousedown")) {
164 await nextFrame()
165
166 if (triggerEvent(element, "mouseup")) {
167 await nextFrame()
168 triggerEvent(element, "click")
169 await nextFrame()
170 }
171 }
172}
173
174export const dragToCoordinates = async (coordinates) => {
175 const element = document.activeElement

Callers 3

attachment_test.jsFile · 0.90

Calls 2

triggerEventFunction · 0.90
nextFrameFunction · 0.90

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…