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

Function updateComposition

src/test/test_helpers/input_helpers.js:135–144  ·  view source on GitHub ↗
(data)

Source from the content-addressed store, hash-verified

133}
134
135export const updateComposition = async (data) => {
136 const element = document.activeElement
137 triggerInputEvent(element, "beforeinput", { inputType: "insertCompositionText", data })
138 triggerEvent(element, "compositionupdate", { data })
139 triggerEvent(element, "input")
140
141 const node = document.createTextNode(data)
142 insertNode(node)
143 await selectNode(node)
144}
145
146export const endComposition = async (data) => {
147 const element = document.activeElement

Callers 1

Calls 4

triggerEventFunction · 0.90
insertNodeFunction · 0.90
selectNodeFunction · 0.90
triggerInputEventFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…