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

Function clickToolbarButton

src/test/test_helpers/toolbar_helpers.js:5–10  ·  view source on GitHub ↗
(selector)

Source from the content-addressed store, hash-verified

3import { delay, nextFrame } from "./timing_helpers"
4
5export const clickToolbarButton = async (selector) => {
6 selectionChangeObserver.update()
7 const button = getToolbarButton(selector)
8 triggerEvent(button, "mousedown")
9 await delay(5)
10}
11
12export const typeToolbarKeyCommand = async (selector) => {
13 const button = getToolbarButton(selector)

Calls 4

triggerEventFunction · 0.90
delayFunction · 0.90
getToolbarButtonFunction · 0.85
updateMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…